Skip to content

Commit 9d195ba

Browse files
author
Tom Bertrand
authored
LSR-14376: Add a few Flame icons (#153)
* LSR-14376: Add align-left, align-center, align-right, rotate-left and rotate-right icons * Update snapshots * Fix changelog * Fix base-1 on rotate-right icon
1 parent ff79a86 commit 9d195ba

11 files changed

Lines changed: 68 additions & 0 deletions

File tree

packages/flame/CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
77

88
Refer to the [CONTRIBUTING guide](https://github.com/lightspeed/flame/blob/master/.github/CONTRIBUTING.md) for more info.
99

10+
## [Unreleased]
11+
12+
### Added
13+
14+
- `align-left`, `align-center`, `align-right`, `rotate-left` and `rotate-right` icons ([#153](https://github.com/lightspeed/flame/pull/153))
15+
1016
## 2.1.0 - 2021-05-19
1117

1218
### Changed

packages/flame/src/Autocomplete/__snapshots__/Autocomplete.test.tsx.snap

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -241,6 +241,7 @@ exports[`Autocomplete renders as disabled 1`] = `
241241
<path
242242
className="cr-icon__base cr-icon__base-1"
243243
d="M7.299 10.641c.388.475 1.012.482 1.406 0L11.8 6.86c.389-.475.194-.86-.418-.86H4.623c-.62 0-.812.378-.418.86l3.094 3.781z"
244+
fill="#232429"
244245
/>
245246
</svg>
246247
</div>
@@ -495,6 +496,7 @@ exports[`Autocomplete renders correctly 1`] = `
495496
<path
496497
className="cr-icon__base cr-icon__base-1"
497498
d="M7.299 10.641c.388.475 1.012.482 1.406 0L11.8 6.86c.389-.475.194-.86-.418-.86H4.623c-.62 0-.812.378-.418.86l3.094 3.781z"
499+
fill="#232429"
498500
/>
499501
</svg>
500502
</div>
@@ -759,6 +761,7 @@ exports[`Autocomplete renders in loading mode 1`] = `
759761
<path
760762
className="cr-icon__base cr-icon__base-1"
761763
d="M8 13a1.5 1.5 0 0 1 0 3A8 8 0 0 1 .323 5.742a1.5 1.5 0 1 1 2.879.846A5 5 0 0 0 8 13z"
764+
fill="#232429"
762765
/>
763766
</svg>
764767
<div
@@ -794,6 +797,7 @@ exports[`Autocomplete renders in loading mode 1`] = `
794797
<path
795798
className="cr-icon__base cr-icon__base-1"
796799
d="M7.299 10.641c.388.475 1.012.482 1.406 0L11.8 6.86c.389-.475.194-.86-.418-.86H4.623c-.62 0-.812.378-.418.86l3.094 3.781z"
800+
fill="#232429"
797801
/>
798802
</svg>
799803
</div>
@@ -1052,6 +1056,7 @@ exports[`Autocomplete renders with an initial value 1`] = `
10521056
<path
10531057
className="cr-icon__base cr-icon__base-1"
10541058
d="M10.216 8l3.325-3.325a1.567 1.567 0 1 0-2.216-2.216L8 5.784 4.675 2.459A1.567 1.567 0 0 0 2.46 4.675L5.784 8l-3.325 3.325a1.567 1.567 0 1 0 2.216 2.216L8 10.216l3.325 3.325a1.567 1.567 0 1 0 2.216-2.216L10.216 8z"
1059+
fill="#232429"
10551060
/>
10561061
</svg>
10571062
</div>
@@ -1088,6 +1093,7 @@ exports[`Autocomplete renders with an initial value 1`] = `
10881093
<path
10891094
className="cr-icon__base cr-icon__base-1"
10901095
d="M7.299 10.641c.388.475 1.012.482 1.406 0L11.8 6.86c.389-.475.194-.86-.418-.86H4.623c-.62 0-.812.378-.418.86l3.094 3.781z"
1096+
fill="#232429"
10911097
/>
10921098
</svg>
10931099
</div>

packages/flame/src/Checkbox/__snapshots__/Checkbox.test.tsx.snap

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,7 @@ exports[`<Checkbox /> Snapshots when all props and label/description with html s
129129
<path
130130
className="cr-icon__base cr-icon__base-1"
131131
d="M5.662 12.508c.656.686 1.735.65 2.345-.079l5.6-6.68c.58-.692.51-1.74-.157-2.342a1.561 1.561 0 0 0-2.259.164L6.802 8.81 4.738 6.822a1.56 1.56 0 0 0-2.264-.01 1.704 1.704 0 0 0-.01 2.347l3.198 3.348z"
132+
fill="#232429"
132133
/>
133134
</svg>
134135
</div>
@@ -277,6 +278,7 @@ exports[`<Checkbox /> Snapshots when all props should render correctly 1`] = `
277278
<path
278279
className="cr-icon__base cr-icon__base-1"
279280
d="M5.662 12.508c.656.686 1.735.65 2.345-.079l5.6-6.68c.58-.692.51-1.74-.157-2.342a1.561 1.561 0 0 0-2.259.164L6.802 8.81 4.738 6.822a1.56 1.56 0 0 0-2.264-.01 1.704 1.704 0 0 0-.01 2.347l3.198 3.348z"
281+
fill="#232429"
280282
/>
281283
</svg>
282284
</div>
@@ -413,6 +415,7 @@ exports[`<Checkbox /> Snapshots when checked should render correctly 1`] = `
413415
<path
414416
className="cr-icon__base cr-icon__base-1"
415417
d="M5.662 12.508c.656.686 1.735.65 2.345-.079l5.6-6.68c.58-.692.51-1.74-.157-2.342a1.561 1.561 0 0 0-2.259.164L6.802 8.81 4.738 6.822a1.56 1.56 0 0 0-2.264-.01 1.704 1.704 0 0 0-.01 2.347l3.198 3.348z"
418+
fill="#232429"
416419
/>
417420
</svg>
418421
</div>
@@ -541,6 +544,7 @@ exports[`<Checkbox /> Snapshots when disabled should render correctly 1`] = `
541544
<path
542545
className="cr-icon__base cr-icon__base-1"
543546
d="M5.662 12.508c.656.686 1.735.65 2.345-.079l5.6-6.68c.58-.692.51-1.74-.157-2.342a1.561 1.561 0 0 0-2.259.164L6.802 8.81 4.738 6.822a1.56 1.56 0 0 0-2.264-.01 1.704 1.704 0 0 0-.01 2.347l3.198 3.348z"
547+
fill="#232429"
544548
/>
545549
</svg>
546550
</div>
@@ -668,6 +672,7 @@ exports[`<Checkbox /> Snapshots when empty props should render correctly 1`] = `
668672
<path
669673
className="cr-icon__base cr-icon__base-1"
670674
d="M5.662 12.508c.656.686 1.735.65 2.345-.079l5.6-6.68c.58-.692.51-1.74-.157-2.342a1.561 1.561 0 0 0-2.259.164L6.802 8.81 4.738 6.822a1.56 1.56 0 0 0-2.264-.01 1.704 1.704 0 0 0-.01 2.347l3.198 3.348z"
675+
fill="#232429"
671676
/>
672677
</svg>
673678
</div>
@@ -809,6 +814,7 @@ exports[`<Checkbox /> Snapshots when indeterminate should render correctly 1`] =
809814
<path
810815
className="cr-icon__base cr-icon__base-1"
811816
d="M5.662 12.508c.656.686 1.735.65 2.345-.079l5.6-6.68c.58-.692.51-1.74-.157-2.342a1.561 1.561 0 0 0-2.259.164L6.802 8.81 4.738 6.822a1.56 1.56 0 0 0-2.264-.01 1.704 1.704 0 0 0-.01 2.347l3.198 3.348z"
817+
fill="#232429"
812818
/>
813819
</svg>
814820
<div
@@ -940,6 +946,7 @@ exports[`<Checkbox /> Snapshots when not checked should render correctly 1`] = `
940946
<path
941947
className="cr-icon__base cr-icon__base-1"
942948
d="M5.662 12.508c.656.686 1.735.65 2.345-.079l5.6-6.68c.58-.692.51-1.74-.157-2.342a1.561 1.561 0 0 0-2.259.164L6.802 8.81 4.738 6.822a1.56 1.56 0 0 0-2.264-.01 1.704 1.704 0 0 0-.01 2.347l3.198 3.348z"
949+
fill="#232429"
943950
/>
944951
</svg>
945952
</div>

packages/flame/src/Icon/__tests__/__snapshots__/Icon.test.tsx.snap

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,12 @@ exports[`Icon renders correctly 1`] = `
2121
<path
2222
className="cr-icon__base cr-icon__base-1"
2323
d="M12.058 2.82c.489.381.914.826 1.269 1.316l1.729-.077a.367.367 0 0 1 .332.219l.593 1.545a.369.369 0 0 1-.1.385l-1.337 1.099a6.538 6.538 0 0 1-.064 1.842l1.146 1.051c.101.093.14.268.083.396l-.622 1.396a.363.363 0 0 1-.35.202l-1.545-.15a6.539 6.539 0 0 1-1.328 1.283l.077 1.729a.369.369 0 0 1-.219.332l-1.545.593a.367.367 0 0 1-.385-.1l-1.099-1.337a6.539 6.539 0 0 1-1.846-.065L5.8 15.624a.367.367 0 0 1-.396.084l-1.396-.621a.363.363 0 0 1-.202-.351l.15-1.544a6.538 6.538 0 0 1-1.283-1.328l-1.729.077a.367.367 0 0 1-.332-.219l-.593-1.545a.369.369 0 0 1 .1-.385l1.337-1.099a6.538 6.538 0 0 1 .065-1.846L.376 5.801a.367.367 0 0 1-.085-.397l.622-1.396a.363.363 0 0 1 .35-.202l1.546.15a6.539 6.539 0 0 1 1.327-1.283L4.06.944a.369.369 0 0 1 .219-.332L5.823.02a.367.367 0 0 1 .385.1l1.099 1.337a6.539 6.539 0 0 1 1.843.064L10.2.375a.367.367 0 0 1 .396-.083l1.396.621a.362.362 0 0 1 .205.345l-.139 1.561zm-5.705 8.879A4.05 4.05 0 1 0 9.647 4.3a4.05 4.05 0 0 0-3.294 7.398z"
24+
fill="#232429"
2425
/>
2526
<path
2627
className="cr-icon__base cr-icon__base-2"
2728
d="M8 6l1.732 1v2L8 10 6.268 9V7z"
29+
fill="#232429"
2830
opacity=".7"
2931
/>
3032
</svg>
@@ -90,6 +92,7 @@ exports[`Icon renders with color 1`] = `
9092
<path
9193
className="cr-icon__base cr-icon__base-1"
9294
d="M1.614 14.39a5.495 5.495 0 0 1 0-7.775l.353-.353 5.11-5.086a4.001 4.001 0 0 1 5.657 0 3.996 3.996 0 0 1 0 5.654l-5.11 5.086-.353.354a2.5 2.5 0 0 1-3.536-3.534l.354-.354 5.11-5.086a1 1 0 0 1 1.414 1.413l-5.11 5.087-.354.354a.5.5 0 1 0 .707.706l.354-.354 5.11-5.087a1.998 1.998 0 0 0 0-2.827 2.001 2.001 0 0 0-2.829 0l-5.11 5.088-.353.353a3.497 3.497 0 0 0 0 4.947 3.502 3.502 0 0 0 4.95 0l.354-.353 5.964-5.93a1 1 0 0 1 1.414 1.414l-5.964 5.93-.354.353a5.502 5.502 0 0 1-7.778 0z"
95+
fill="#232429"
9396
/>
9497
</svg>
9598
`;

packages/flame/src/Spinner/__snapshots__/Spinner.test.tsx.snap

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,11 +38,13 @@ exports[`<Spinner /> Snapshots when color is cr-blue should render correctly 1`]
3838
<path
3939
className="cr-icon__base cr-icon__base-2"
4040
d="M8 16A8 8 0 1 1 8 0a8 8 0 0 1 0 16zm0-3A5 5 0 1 0 8 3a5 5 0 0 0 0 10z"
41+
fill="#232429"
4142
opacity=".3"
4243
/>
4344
<path
4445
className="cr-icon__base cr-icon__base-1"
4546
d="M8 13a1.5 1.5 0 0 1 0 3A8 8 0 0 1 .323 5.742a1.5 1.5 0 1 1 2.879.846A5 5 0 0 0 8 13z"
47+
fill="#232429"
4648
/>
4749
</svg>
4850
`;
@@ -84,11 +86,13 @@ exports[`<Spinner /> Snapshots when empty props should render correctly 1`] = `
8486
<path
8587
className="cr-icon__base cr-icon__base-2"
8688
d="M8 16A8 8 0 1 1 8 0a8 8 0 0 1 0 16zm0-3A5 5 0 1 0 8 3a5 5 0 0 0 0 10z"
89+
fill="#232429"
8790
opacity=".3"
8891
/>
8992
<path
9093
className="cr-icon__base cr-icon__base-1"
9194
d="M8 13a1.5 1.5 0 0 1 0 3A8 8 0 0 1 .323 5.742a1.5 1.5 0 1 1 2.879.846A5 5 0 0 0 8 13z"
95+
fill="#232429"
9296
/>
9397
</svg>
9498
`;
@@ -130,11 +134,13 @@ exports[`<Spinner /> Snapshots when size is xlarge should render correctly 1`] =
130134
<path
131135
className="cr-icon__base cr-icon__base-2"
132136
d="M8 16A8 8 0 1 1 8 0a8 8 0 0 1 0 16zm0-3A5 5 0 1 0 8 3a5 5 0 0 0 0 10z"
137+
fill="#232429"
133138
opacity=".3"
134139
/>
135140
<path
136141
className="cr-icon__base cr-icon__base-1"
137142
d="M8 13a1.5 1.5 0 0 1 0 3A8 8 0 0 1 .323 5.742a1.5 1.5 0 1 1 2.879.846A5 5 0 0 0 8 13z"
143+
fill="#232429"
138144
/>
139145
</svg>
140146
`;

packages/flame/src/Switch/__snapshots__/Switch.test.tsx.snap

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -178,6 +178,7 @@ exports[`<Switch /> when autoFocus should render correctly 1`] = `
178178
<path
179179
className="cr-icon__base cr-icon__base-1"
180180
d="M5.662 12.508c.656.686 1.735.65 2.345-.079l5.6-6.68c.58-.692.51-1.74-.157-2.342a1.561 1.561 0 0 0-2.259.164L6.802 8.81 4.738 6.822a1.56 1.56 0 0 0-2.264-.01 1.704 1.704 0 0 0-.01 2.347l3.198 3.348z"
181+
fill="#232429"
181182
/>
182183
</svg>
183184
<svg
@@ -194,6 +195,7 @@ exports[`<Switch /> when autoFocus should render correctly 1`] = `
194195
<path
195196
className="cr-icon__base cr-icon__base-1"
196197
d="M10.216 8l3.325-3.325a1.567 1.567 0 1 0-2.216-2.216L8 5.784 4.675 2.459A1.567 1.567 0 0 0 2.46 4.675L5.784 8l-3.325 3.325a1.567 1.567 0 1 0 2.216 2.216L8 10.216l3.325 3.325a1.567 1.567 0 1 0 2.216-2.216L10.216 8z"
198+
fill="#232429"
197199
/>
198200
</svg>
199201
</span>
@@ -379,6 +381,7 @@ exports[`<Switch /> when checked should render correctly 1`] = `
379381
<path
380382
className="cr-icon__base cr-icon__base-1"
381383
d="M5.662 12.508c.656.686 1.735.65 2.345-.079l5.6-6.68c.58-.692.51-1.74-.157-2.342a1.561 1.561 0 0 0-2.259.164L6.802 8.81 4.738 6.822a1.56 1.56 0 0 0-2.264-.01 1.704 1.704 0 0 0-.01 2.347l3.198 3.348z"
384+
fill="#232429"
382385
/>
383386
</svg>
384387
<svg
@@ -395,6 +398,7 @@ exports[`<Switch /> when checked should render correctly 1`] = `
395398
<path
396399
className="cr-icon__base cr-icon__base-1"
397400
d="M10.216 8l3.325-3.325a1.567 1.567 0 1 0-2.216-2.216L8 5.784 4.675 2.459A1.567 1.567 0 0 0 2.46 4.675L5.784 8l-3.325 3.325a1.567 1.567 0 1 0 2.216 2.216L8 10.216l3.325 3.325a1.567 1.567 0 1 0 2.216-2.216L10.216 8z"
401+
fill="#232429"
398402
/>
399403
</svg>
400404
</span>
@@ -580,6 +584,7 @@ exports[`<Switch /> when disabled should render correctly 1`] = `
580584
<path
581585
className="cr-icon__base cr-icon__base-1"
582586
d="M5.662 12.508c.656.686 1.735.65 2.345-.079l5.6-6.68c.58-.692.51-1.74-.157-2.342a1.561 1.561 0 0 0-2.259.164L6.802 8.81 4.738 6.822a1.56 1.56 0 0 0-2.264-.01 1.704 1.704 0 0 0-.01 2.347l3.198 3.348z"
587+
fill="#232429"
583588
/>
584589
</svg>
585590
<svg
@@ -596,6 +601,7 @@ exports[`<Switch /> when disabled should render correctly 1`] = `
596601
<path
597602
className="cr-icon__base cr-icon__base-1"
598603
d="M10.216 8l3.325-3.325a1.567 1.567 0 1 0-2.216-2.216L8 5.784 4.675 2.459A1.567 1.567 0 0 0 2.46 4.675L5.784 8l-3.325 3.325a1.567 1.567 0 1 0 2.216 2.216L8 10.216l3.325 3.325a1.567 1.567 0 1 0 2.216-2.216L10.216 8z"
604+
fill="#232429"
599605
/>
600606
</svg>
601607
</span>
@@ -780,6 +786,7 @@ exports[`<Switch /> when empty props should render correctly 1`] = `
780786
<path
781787
className="cr-icon__base cr-icon__base-1"
782788
d="M5.662 12.508c.656.686 1.735.65 2.345-.079l5.6-6.68c.58-.692.51-1.74-.157-2.342a1.561 1.561 0 0 0-2.259.164L6.802 8.81 4.738 6.822a1.56 1.56 0 0 0-2.264-.01 1.704 1.704 0 0 0-.01 2.347l3.198 3.348z"
789+
fill="#232429"
783790
/>
784791
</svg>
785792
<svg
@@ -796,6 +803,7 @@ exports[`<Switch /> when empty props should render correctly 1`] = `
796803
<path
797804
className="cr-icon__base cr-icon__base-1"
798805
d="M10.216 8l3.325-3.325a1.567 1.567 0 1 0-2.216-2.216L8 5.784 4.675 2.459A1.567 1.567 0 0 0 2.46 4.675L5.784 8l-3.325 3.325a1.567 1.567 0 1 0 2.216 2.216L8 10.216l3.325 3.325a1.567 1.567 0 1 0 2.216-2.216L10.216 8z"
806+
fill="#232429"
799807
/>
800808
</svg>
801809
</span>
@@ -982,6 +990,7 @@ exports[`<Switch /> when id, name should render correctly 1`] = `
982990
<path
983991
className="cr-icon__base cr-icon__base-1"
984992
d="M5.662 12.508c.656.686 1.735.65 2.345-.079l5.6-6.68c.58-.692.51-1.74-.157-2.342a1.561 1.561 0 0 0-2.259.164L6.802 8.81 4.738 6.822a1.56 1.56 0 0 0-2.264-.01 1.704 1.704 0 0 0-.01 2.347l3.198 3.348z"
993+
fill="#232429"
985994
/>
986995
</svg>
987996
<svg
@@ -998,6 +1007,7 @@ exports[`<Switch /> when id, name should render correctly 1`] = `
9981007
<path
9991008
className="cr-icon__base cr-icon__base-1"
10001009
d="M10.216 8l3.325-3.325a1.567 1.567 0 1 0-2.216-2.216L8 5.784 4.675 2.459A1.567 1.567 0 0 0 2.46 4.675L5.784 8l-3.325 3.325a1.567 1.567 0 1 0 2.216 2.216L8 10.216l3.325 3.325a1.567 1.567 0 1 0 2.216-2.216L10.216 8z"
1010+
fill="#232429"
10011011
/>
10021012
</svg>
10031013
</span>
@@ -1183,6 +1193,7 @@ exports[`<Switch /> when passing data-props should render correctly 1`] = `
11831193
<path
11841194
className="cr-icon__base cr-icon__base-1"
11851195
d="M5.662 12.508c.656.686 1.735.65 2.345-.079l5.6-6.68c.58-.692.51-1.74-.157-2.342a1.561 1.561 0 0 0-2.259.164L6.802 8.81 4.738 6.822a1.56 1.56 0 0 0-2.264-.01 1.704 1.704 0 0 0-.01 2.347l3.198 3.348z"
1196+
fill="#232429"
11861197
/>
11871198
</svg>
11881199
<svg
@@ -1199,6 +1210,7 @@ exports[`<Switch /> when passing data-props should render correctly 1`] = `
11991210
<path
12001211
className="cr-icon__base cr-icon__base-1"
12011212
d="M10.216 8l3.325-3.325a1.567 1.567 0 1 0-2.216-2.216L8 5.784 4.675 2.459A1.567 1.567 0 0 0 2.46 4.675L5.784 8l-3.325 3.325a1.567 1.567 0 1 0 2.216 2.216L8 10.216l3.325 3.325a1.567 1.567 0 1 0 2.216-2.216L10.216 8z"
1213+
fill="#232429"
12021214
/>
12031215
</svg>
12041216
</span>
Lines changed: 6 additions & 0 deletions
Loading
Lines changed: 6 additions & 0 deletions
Loading
Lines changed: 6 additions & 0 deletions
Loading
Lines changed: 5 additions & 0 deletions
Loading

0 commit comments

Comments
 (0)