@lumx/core 2.1.8 → 2.1.9-alpha-thumbnail4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/css/design-tokens.css +82 -27
- package/js/constants/design-tokens.js +21 -21
- package/js/constants/design-tokens.min.js +1 -1
- package/js/constants/design-tokens.min.js.map +1 -1
- package/js/constants/design-tokens.ts +21 -21
- package/js/custom-colors.min.js.map +1 -1
- package/js/date-picker.min.js.map +1 -1
- package/js/utils.min.js.map +1 -1
- package/lumx.css +1 -1
- package/lumx.min.css +1 -1
- package/package.json +2 -2
- package/scss/_components.scss +1 -0
- package/scss/_design-tokens.scss +87 -27
- package/scss/components/chip/_index.scss +6 -0
- package/scss/components/flag/_index.scss +8 -3
- package/scss/components/icon/_mixins.scss +5 -1
- package/scss/components/image-block/_index.scss +2 -0
- package/scss/components/list/_mixins.scss +2 -1
- package/scss/components/side-navigation/_mixins.scss +0 -1
- package/scss/components/skeleton/_index.scss +4 -7
- package/scss/components/skeleton/_mixins.scss +10 -0
- package/scss/components/thumbnail/_index.scss +100 -60
- package/scss/components/thumbnail/_variables.scss +1 -1
- package/scss/components/uploader/_index.scss +2 -2
- package/scss/components/user-block/_index.scss +1 -1
- package/scss/core/state/_mixins.scss +0 -4
package/package.json
CHANGED
|
@@ -42,7 +42,7 @@
|
|
|
42
42
|
"version": "yarn version-changelog ../../CHANGELOG.md && yarn changelog-verify ../../CHANGELOG.md && git add ../../CHANGELOG.md"
|
|
43
43
|
},
|
|
44
44
|
"sideEffects": false,
|
|
45
|
-
"version": "2.1.
|
|
45
|
+
"version": "2.1.9-alpha-thumbnail4",
|
|
46
46
|
"devDependencies": {
|
|
47
47
|
"@babel/core": "^7.8.3",
|
|
48
48
|
"@babel/plugin-proposal-class-properties": "^7.8.3",
|
|
@@ -82,5 +82,5 @@
|
|
|
82
82
|
"moment": "^2.24.0",
|
|
83
83
|
"moment-range": "^4.0.2"
|
|
84
84
|
},
|
|
85
|
-
"gitHead": "
|
|
85
|
+
"gitHead": "fa5191f099b3ac41f36405aeb23d0f6d254d4d39"
|
|
86
86
|
}
|
package/scss/_components.scss
CHANGED
|
@@ -23,6 +23,7 @@
|
|
|
23
23
|
@import './components/radio-button/mixins';
|
|
24
24
|
@import './components/select/mixins';
|
|
25
25
|
@import './components/side-navigation/mixins';
|
|
26
|
+
@import './components/skeleton/mixins';
|
|
26
27
|
@import './components/slideshow/variables';
|
|
27
28
|
@import './components/switch/mixins';
|
|
28
29
|
@import './components/table/mixins';
|
package/scss/_design-tokens.scss
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Do not edit directly
|
|
3
|
-
* Generated on Tue,
|
|
3
|
+
* Generated on Tue, 30 Nov 2021 09:20:09 GMT
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
6
|
$lumx-button-height: 36px !default;
|
|
@@ -47,7 +47,12 @@ $lumx-button-emphasis-medium-state-default-theme-light-background-color: rgba(
|
|
|
47
47
|
0,
|
|
48
48
|
0.12
|
|
49
49
|
) !default; // Base dark color with 12% opacity
|
|
50
|
-
$lumx-button-emphasis-medium-state-default-theme-light-color: rgba(
|
|
50
|
+
$lumx-button-emphasis-medium-state-default-theme-light-color: rgba(
|
|
51
|
+
0,
|
|
52
|
+
0,
|
|
53
|
+
0,
|
|
54
|
+
0.7
|
|
55
|
+
) !default; // Base dark color with 70% opacity
|
|
51
56
|
$lumx-button-emphasis-medium-state-default-theme-light-border-color: transparent !default;
|
|
52
57
|
$lumx-button-emphasis-medium-state-default-theme-dark-background-color: rgba(
|
|
53
58
|
255,
|
|
@@ -65,7 +70,12 @@ $lumx-button-emphasis-medium-state-hover-theme-light-background-color: rgba(
|
|
|
65
70
|
0,
|
|
66
71
|
0.2
|
|
67
72
|
) !default; // Base dark color with 20% opacity
|
|
68
|
-
$lumx-button-emphasis-medium-state-hover-theme-light-color: rgba(
|
|
73
|
+
$lumx-button-emphasis-medium-state-hover-theme-light-color: rgba(
|
|
74
|
+
0,
|
|
75
|
+
0,
|
|
76
|
+
0,
|
|
77
|
+
0.7
|
|
78
|
+
) !default; // Base dark color with 70% opacity
|
|
69
79
|
$lumx-button-emphasis-medium-state-hover-theme-light-border-color: transparent !default;
|
|
70
80
|
$lumx-button-emphasis-medium-state-hover-theme-dark-background-color: rgba(
|
|
71
81
|
255,
|
|
@@ -83,7 +93,12 @@ $lumx-button-emphasis-medium-state-active-theme-light-background-color: rgba(
|
|
|
83
93
|
0,
|
|
84
94
|
0.38
|
|
85
95
|
) !default; // Base dark color with 38% opacity
|
|
86
|
-
$lumx-button-emphasis-medium-state-active-theme-light-color: rgba(
|
|
96
|
+
$lumx-button-emphasis-medium-state-active-theme-light-color: rgba(
|
|
97
|
+
0,
|
|
98
|
+
0,
|
|
99
|
+
0,
|
|
100
|
+
0.7
|
|
101
|
+
) !default; // Base dark color with 70% opacity
|
|
87
102
|
$lumx-button-emphasis-medium-state-active-theme-light-border-color: transparent !default;
|
|
88
103
|
$lumx-button-emphasis-medium-state-active-theme-dark-background-color: rgba(
|
|
89
104
|
255,
|
|
@@ -96,7 +111,12 @@ $lumx-button-emphasis-medium-state-active-theme-dark-border-color: transparent !
|
|
|
96
111
|
$lumx-button-emphasis-low-state-default-padding-horizontal: 8px !default;
|
|
97
112
|
$lumx-button-emphasis-low-state-default-border-width: 0 !default;
|
|
98
113
|
$lumx-button-emphasis-low-state-default-theme-light-background-color: transparent !default;
|
|
99
|
-
$lumx-button-emphasis-low-state-default-theme-light-color: rgba(
|
|
114
|
+
$lumx-button-emphasis-low-state-default-theme-light-color: rgba(
|
|
115
|
+
0,
|
|
116
|
+
0,
|
|
117
|
+
0,
|
|
118
|
+
0.7
|
|
119
|
+
) !default; // Base dark color with 70% opacity
|
|
100
120
|
$lumx-button-emphasis-low-state-default-theme-light-border-color: transparent !default;
|
|
101
121
|
$lumx-button-emphasis-low-state-default-theme-dark-background-color: transparent !default;
|
|
102
122
|
$lumx-button-emphasis-low-state-default-theme-dark-color: #fff !default; // Neutral light color
|
|
@@ -109,7 +129,12 @@ $lumx-button-emphasis-low-state-hover-theme-light-background-color: rgba(
|
|
|
109
129
|
0,
|
|
110
130
|
0.12
|
|
111
131
|
) !default; // Base dark color with 12% opacity
|
|
112
|
-
$lumx-button-emphasis-low-state-hover-theme-light-color: rgba(
|
|
132
|
+
$lumx-button-emphasis-low-state-hover-theme-light-color: rgba(
|
|
133
|
+
0,
|
|
134
|
+
0,
|
|
135
|
+
0,
|
|
136
|
+
0.7
|
|
137
|
+
) !default; // Base dark color with 70% opacity
|
|
113
138
|
$lumx-button-emphasis-low-state-hover-theme-light-border-color: transparent !default;
|
|
114
139
|
$lumx-button-emphasis-low-state-hover-theme-dark-background-color: rgba(
|
|
115
140
|
255,
|
|
@@ -127,7 +152,12 @@ $lumx-button-emphasis-low-state-active-theme-light-background-color: rgba(
|
|
|
127
152
|
0,
|
|
128
153
|
0.2
|
|
129
154
|
) !default; // Base dark color with 20% opacity
|
|
130
|
-
$lumx-button-emphasis-low-state-active-theme-light-color: rgba(
|
|
155
|
+
$lumx-button-emphasis-low-state-active-theme-light-color: rgba(
|
|
156
|
+
0,
|
|
157
|
+
0,
|
|
158
|
+
0,
|
|
159
|
+
0.7
|
|
160
|
+
) !default; // Base dark color with 70% opacity
|
|
131
161
|
$lumx-button-emphasis-low-state-active-theme-light-border-color: transparent !default;
|
|
132
162
|
$lumx-button-emphasis-low-state-active-theme-dark-background-color: rgba(
|
|
133
163
|
255,
|
|
@@ -229,8 +259,8 @@ $lumx-navigation-item-emphasis-low-state-default-theme-light-icon-color: rgba(
|
|
|
229
259
|
0,
|
|
230
260
|
0,
|
|
231
261
|
0,
|
|
232
|
-
0.
|
|
233
|
-
) !default; //
|
|
262
|
+
0.7
|
|
263
|
+
) !default; // Base dark color with 70% opacity
|
|
234
264
|
$lumx-navigation-item-emphasis-low-state-default-theme-light-label-color: rgba(
|
|
235
265
|
0,
|
|
236
266
|
0,
|
|
@@ -242,8 +272,8 @@ $lumx-navigation-item-emphasis-low-state-default-theme-light-chevron-color: rgba
|
|
|
242
272
|
0,
|
|
243
273
|
0,
|
|
244
274
|
0,
|
|
245
|
-
0.
|
|
246
|
-
) !default; //
|
|
275
|
+
0.7
|
|
276
|
+
) !default; // Base dark color with 70% opacity
|
|
247
277
|
$lumx-navigation-item-emphasis-low-state-default-theme-dark-background-color: transparent !default;
|
|
248
278
|
$lumx-navigation-item-emphasis-low-state-default-theme-dark-border-color: rgba(
|
|
249
279
|
255,
|
|
@@ -275,8 +305,8 @@ $lumx-navigation-item-emphasis-low-state-hover-theme-light-icon-color: rgba(
|
|
|
275
305
|
0,
|
|
276
306
|
0,
|
|
277
307
|
0,
|
|
278
|
-
0.
|
|
279
|
-
) !default; //
|
|
308
|
+
0.7
|
|
309
|
+
) !default; // Base dark color with 70% opacity
|
|
280
310
|
$lumx-navigation-item-emphasis-low-state-hover-theme-light-label-color: rgba(
|
|
281
311
|
0,
|
|
282
312
|
0,
|
|
@@ -293,8 +323,8 @@ $lumx-navigation-item-emphasis-low-state-hover-theme-light-chevron-color: rgba(
|
|
|
293
323
|
0,
|
|
294
324
|
0,
|
|
295
325
|
0,
|
|
296
|
-
0.
|
|
297
|
-
) !default; //
|
|
326
|
+
0.7
|
|
327
|
+
) !default; // Base dark color with 70% opacity
|
|
298
328
|
$lumx-navigation-item-emphasis-low-state-hover-theme-dark-background-color: rgba(
|
|
299
329
|
255,
|
|
300
330
|
255,
|
|
@@ -336,8 +366,8 @@ $lumx-navigation-item-emphasis-low-state-active-theme-light-icon-color: rgba(
|
|
|
336
366
|
0,
|
|
337
367
|
0,
|
|
338
368
|
0,
|
|
339
|
-
0.
|
|
340
|
-
) !default; //
|
|
369
|
+
0.7
|
|
370
|
+
) !default; // Base dark color with 70% opacity
|
|
341
371
|
$lumx-navigation-item-emphasis-low-state-active-theme-light-label-color: rgba(
|
|
342
372
|
0,
|
|
343
373
|
0,
|
|
@@ -354,8 +384,8 @@ $lumx-navigation-item-emphasis-low-state-active-theme-light-chevron-color: rgba(
|
|
|
354
384
|
0,
|
|
355
385
|
0,
|
|
356
386
|
0,
|
|
357
|
-
0.
|
|
358
|
-
) !default; //
|
|
387
|
+
0.7
|
|
388
|
+
) !default; // Base dark color with 70% opacity
|
|
359
389
|
$lumx-navigation-item-emphasis-low-state-active-theme-dark-background-color: rgba(
|
|
360
390
|
255,
|
|
361
391
|
255,
|
|
@@ -480,7 +510,12 @@ $lumx-tabs-link-emphasis-low-state-default-border-right-width: 0 !default;
|
|
|
480
510
|
$lumx-tabs-link-emphasis-low-state-default-border-bottom-width: 2px !default;
|
|
481
511
|
$lumx-tabs-link-emphasis-low-state-default-border-left-width: 0 !default;
|
|
482
512
|
$lumx-tabs-link-emphasis-low-state-default-theme-light-background-color: transparent !default;
|
|
483
|
-
$lumx-tabs-link-emphasis-low-state-default-theme-light-color: rgba(
|
|
513
|
+
$lumx-tabs-link-emphasis-low-state-default-theme-light-color: rgba(
|
|
514
|
+
0,
|
|
515
|
+
0,
|
|
516
|
+
0,
|
|
517
|
+
0.7
|
|
518
|
+
) !default; // Base dark color with 70% opacity
|
|
484
519
|
$lumx-tabs-link-emphasis-low-state-default-theme-light-border-color: rgba(
|
|
485
520
|
0,
|
|
486
521
|
0,
|
|
@@ -505,7 +540,12 @@ $lumx-tabs-link-emphasis-low-state-hover-theme-light-background-color: rgba(
|
|
|
505
540
|
0,
|
|
506
541
|
0.12
|
|
507
542
|
) !default; // Base dark color with 12% opacity
|
|
508
|
-
$lumx-tabs-link-emphasis-low-state-hover-theme-light-color: rgba(
|
|
543
|
+
$lumx-tabs-link-emphasis-low-state-hover-theme-light-color: rgba(
|
|
544
|
+
0,
|
|
545
|
+
0,
|
|
546
|
+
0,
|
|
547
|
+
0.7
|
|
548
|
+
) !default; // Base dark color with 70% opacity
|
|
509
549
|
$lumx-tabs-link-emphasis-low-state-hover-theme-light-border-color: rgba(
|
|
510
550
|
0,
|
|
511
551
|
0,
|
|
@@ -535,7 +575,12 @@ $lumx-tabs-link-emphasis-low-state-active-theme-light-background-color: rgba(
|
|
|
535
575
|
0,
|
|
536
576
|
0.2
|
|
537
577
|
) !default; // Base dark color with 20% opacity
|
|
538
|
-
$lumx-tabs-link-emphasis-low-state-active-theme-light-color: rgba(
|
|
578
|
+
$lumx-tabs-link-emphasis-low-state-active-theme-light-color: rgba(
|
|
579
|
+
0,
|
|
580
|
+
0,
|
|
581
|
+
0,
|
|
582
|
+
0.7
|
|
583
|
+
) !default; // Base dark color with 70% opacity
|
|
539
584
|
$lumx-tabs-link-emphasis-low-state-active-theme-light-border-color: rgba(
|
|
540
585
|
0,
|
|
541
586
|
0,
|
|
@@ -560,7 +605,12 @@ $lumx-tabs-link-emphasis-selected-state-default-border-right-width: 0 !default;
|
|
|
560
605
|
$lumx-tabs-link-emphasis-selected-state-default-border-bottom-width: 2px !default;
|
|
561
606
|
$lumx-tabs-link-emphasis-selected-state-default-border-left-width: 0 !default;
|
|
562
607
|
$lumx-tabs-link-emphasis-selected-state-default-theme-light-background-color: transparent !default;
|
|
563
|
-
$lumx-tabs-link-emphasis-selected-state-default-theme-light-color: rgba(
|
|
608
|
+
$lumx-tabs-link-emphasis-selected-state-default-theme-light-color: rgba(
|
|
609
|
+
0,
|
|
610
|
+
0,
|
|
611
|
+
0,
|
|
612
|
+
0.7
|
|
613
|
+
) !default; // Base dark color with 70% opacity
|
|
564
614
|
$lumx-tabs-link-emphasis-selected-state-default-theme-light-border-color: var(--lumx-color-primary-N) !default;
|
|
565
615
|
$lumx-tabs-link-emphasis-selected-state-default-theme-dark-background-color: transparent !default;
|
|
566
616
|
$lumx-tabs-link-emphasis-selected-state-default-theme-dark-color: #fff !default; // Neutral light color
|
|
@@ -575,7 +625,12 @@ $lumx-tabs-link-emphasis-selected-state-hover-theme-light-background-color: rgba
|
|
|
575
625
|
0,
|
|
576
626
|
0.12
|
|
577
627
|
) !default; // Base dark color with 12% opacity
|
|
578
|
-
$lumx-tabs-link-emphasis-selected-state-hover-theme-light-color: rgba(
|
|
628
|
+
$lumx-tabs-link-emphasis-selected-state-hover-theme-light-color: rgba(
|
|
629
|
+
0,
|
|
630
|
+
0,
|
|
631
|
+
0,
|
|
632
|
+
0.7
|
|
633
|
+
) !default; // Base dark color with 70% opacity
|
|
579
634
|
$lumx-tabs-link-emphasis-selected-state-hover-theme-light-border-color: var(--lumx-color-primary-N) !default;
|
|
580
635
|
$lumx-tabs-link-emphasis-selected-state-hover-theme-dark-background-color: rgba(
|
|
581
636
|
255,
|
|
@@ -595,7 +650,12 @@ $lumx-tabs-link-emphasis-selected-state-active-theme-light-background-color: rgb
|
|
|
595
650
|
0,
|
|
596
651
|
0.2
|
|
597
652
|
) !default; // Base dark color with 20% opacity
|
|
598
|
-
$lumx-tabs-link-emphasis-selected-state-active-theme-light-color: rgba(
|
|
653
|
+
$lumx-tabs-link-emphasis-selected-state-active-theme-light-color: rgba(
|
|
654
|
+
0,
|
|
655
|
+
0,
|
|
656
|
+
0,
|
|
657
|
+
0.7
|
|
658
|
+
) !default; // Base dark color with 70% opacity
|
|
599
659
|
$lumx-tabs-link-emphasis-selected-state-active-theme-light-border-color: var(--lumx-color-primary-N) !default;
|
|
600
660
|
$lumx-tabs-link-emphasis-selected-state-active-theme-dark-background-color: rgba(
|
|
601
661
|
255,
|
|
@@ -730,7 +790,7 @@ $lumx-text-field-state-focus-theme-dark-input-placeholder-color: rgba(
|
|
|
730
790
|
) !default; // Base light color with 80% opacity
|
|
731
791
|
$lumx-border-radius: 4px !default;
|
|
732
792
|
$lumx-color-dark-N: rgba(0, 0, 0, 0.87) !default; // Neutral dark color
|
|
733
|
-
$lumx-color-dark-L1: rgba(0, 0, 0, 0.
|
|
793
|
+
$lumx-color-dark-L1: rgba(0, 0, 0, 0.7) !default; // Base dark color with 70% opacity
|
|
734
794
|
$lumx-color-dark-L2: rgba(0, 0, 0, 0.54) !default; // Base dark color with 54% opacity
|
|
735
795
|
$lumx-color-dark-L3: rgba(0, 0, 0, 0.38) !default; // Base dark color with 38% opacity
|
|
736
796
|
$lumx-color-dark-L4: rgba(0, 0, 0, 0.2) !default; // Base dark color with 20% opacity
|
|
@@ -814,7 +874,7 @@ $lumx-color-accent-L4: rgba(76, 175, 80, 0.2) !default; // Base green color with
|
|
|
814
874
|
$lumx-color-accent-L5: rgba(76, 175, 80, 0.1) !default; // Base green color with 10% opacity
|
|
815
875
|
$lumx-color-accent-L6: rgba(76, 175, 80, 0.05) !default; // Base green color with 5% opacity
|
|
816
876
|
$lumx-color-black-N: rgba(0, 0, 0, 0.87) !default; // Neutral dark color
|
|
817
|
-
$lumx-color-black-L1: rgba(0, 0, 0, 0.
|
|
877
|
+
$lumx-color-black-L1: rgba(0, 0, 0, 0.7) !default; // Base dark color with 70% opacity
|
|
818
878
|
$lumx-color-black-L2: rgba(0, 0, 0, 0.54) !default; // Base dark color with 54% opacity
|
|
819
879
|
$lumx-color-black-L3: rgba(0, 0, 0, 0.38) !default; // Base dark color with 38% opacity
|
|
820
880
|
$lumx-color-black-L4: rgba(0, 0, 0, 0.2) !default; // Base dark color with 20% opacity
|
|
@@ -82,6 +82,12 @@
|
|
|
82
82
|
&.#{$lumx-base-prefix}-chip--is-highlighted {
|
|
83
83
|
@include lumx-state(lumx-base-const('state', 'FOCUS'), lumx-base-const('emphasis', 'MEDIUM'), $key);
|
|
84
84
|
}
|
|
85
|
+
|
|
86
|
+
@if $key == 'dark' {
|
|
87
|
+
.#{$lumx-base-prefix}-chip__label {
|
|
88
|
+
color: lumx-color-variant('dark', 'L1');
|
|
89
|
+
}
|
|
90
|
+
}
|
|
85
91
|
}
|
|
86
92
|
}
|
|
87
93
|
|
|
@@ -25,9 +25,14 @@
|
|
|
25
25
|
@each $key, $color in $lumx-color-palette {
|
|
26
26
|
.#{$lumx-base-prefix}-flag--color-#{$key} {
|
|
27
27
|
border: 2px solid lumx-color-variant($key, 'L4');
|
|
28
|
-
}
|
|
29
28
|
|
|
30
|
-
|
|
31
|
-
|
|
29
|
+
.#{$lumx-base-prefix}-flag__label,
|
|
30
|
+
.#{$lumx-base-prefix}-flag__icon {
|
|
31
|
+
@if $key == 'dark' {
|
|
32
|
+
color: lumx-color-variant($key, 'L1');
|
|
33
|
+
} @else {
|
|
34
|
+
color: lumx-color-variant($key, 'D2');
|
|
35
|
+
}
|
|
36
|
+
}
|
|
32
37
|
}
|
|
33
38
|
}
|
|
@@ -16,6 +16,10 @@
|
|
|
16
16
|
background-color: lumx-color-variant($color, 'L5');
|
|
17
17
|
color: lumx-color-variant($color, 'L2');
|
|
18
18
|
} @else if $has-shape == false {
|
|
19
|
-
|
|
19
|
+
@if $color == 'dark' {
|
|
20
|
+
color: lumx-color-variant('dark', 'L1');
|
|
21
|
+
} @else {
|
|
22
|
+
color: lumx-color-variant($color, 'N');
|
|
23
|
+
}
|
|
20
24
|
}
|
|
21
25
|
}
|
|
@@ -18,15 +18,14 @@
|
|
|
18
18
|
========================================================================== */
|
|
19
19
|
|
|
20
20
|
.#{$lumx-base-prefix}-skeleton-circle {
|
|
21
|
-
animation: skeleton-loading 1s ease-in-out 0s infinite;
|
|
22
21
|
border-radius: 50%;
|
|
23
22
|
|
|
24
23
|
&--theme-light {
|
|
25
|
-
|
|
24
|
+
@include lumx-skeleton('light');
|
|
26
25
|
}
|
|
27
26
|
|
|
28
27
|
&--theme-dark {
|
|
29
|
-
|
|
28
|
+
@include lumx-skeleton('dark');
|
|
30
29
|
}
|
|
31
30
|
}
|
|
32
31
|
|
|
@@ -47,18 +46,16 @@
|
|
|
47
46
|
========================================================================== */
|
|
48
47
|
|
|
49
48
|
.#{$lumx-base-prefix}-skeleton-rectangle {
|
|
50
|
-
animation: skeleton-loading 1s ease-in-out 0s infinite;
|
|
51
|
-
|
|
52
49
|
&--variant-rounded {
|
|
53
50
|
border-radius: var(--lumx-border-radius);
|
|
54
51
|
}
|
|
55
52
|
|
|
56
53
|
&--theme-light {
|
|
57
|
-
|
|
54
|
+
@include lumx-skeleton('light');
|
|
58
55
|
}
|
|
59
56
|
|
|
60
57
|
&--theme-dark {
|
|
61
|
-
|
|
58
|
+
@include lumx-skeleton('dark');
|
|
62
59
|
}
|
|
63
60
|
}
|
|
64
61
|
|
|
@@ -12,44 +12,10 @@
|
|
|
12
12
|
background: none;
|
|
13
13
|
outline: none;
|
|
14
14
|
|
|
15
|
-
&--fill-height,
|
|
16
|
-
&--fill-height &__background {
|
|
17
|
-
display: flex;
|
|
18
|
-
/* Safari hack to force the image ratio */
|
|
19
|
-
height: fit-content;
|
|
20
|
-
min-height: 100%;
|
|
21
|
-
flex: 1 1 auto;
|
|
22
|
-
flex-direction: column;
|
|
23
|
-
justify-content: center;
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
&--variant-rounded {
|
|
27
|
-
border-radius: var(--lumx-border-radius);
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
&__background {
|
|
31
|
-
position: relative;
|
|
32
|
-
width: 100%;
|
|
33
|
-
background-position: center;
|
|
34
|
-
background-repeat: no-repeat;
|
|
35
|
-
background-size: cover;
|
|
36
|
-
|
|
37
|
-
#{$self}--variant-rounded & {
|
|
38
|
-
border-radius: var(--lumx-border-radius);
|
|
39
|
-
}
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
&__focused-image {
|
|
43
|
-
max-width: none;
|
|
44
|
-
}
|
|
45
|
-
|
|
46
15
|
&__background,
|
|
47
16
|
&__image {
|
|
48
17
|
display: block;
|
|
49
|
-
|
|
50
|
-
/* IE11 hack related to a bug with IE flexbox implementation (cf. https://stackoverflow.com/a/54054592) */
|
|
51
|
-
min-height: 1px;
|
|
52
|
-
max-height: 100%;
|
|
18
|
+
overflow: hidden;
|
|
53
19
|
|
|
54
20
|
#{$self}--align-left & {
|
|
55
21
|
margin-right: auto;
|
|
@@ -62,16 +28,6 @@
|
|
|
62
28
|
#{$self}--align-right & {
|
|
63
29
|
margin-left: auto;
|
|
64
30
|
}
|
|
65
|
-
|
|
66
|
-
#{$self}--variant-rounded & {
|
|
67
|
-
border-radius: var(--lumx-border-radius);
|
|
68
|
-
}
|
|
69
|
-
}
|
|
70
|
-
|
|
71
|
-
&__fallback {
|
|
72
|
-
width: fit-content;
|
|
73
|
-
/* Center fallback icon when using fill-height prop */
|
|
74
|
-
margin: 0 auto;
|
|
75
31
|
}
|
|
76
32
|
|
|
77
33
|
&__badge {
|
|
@@ -79,6 +35,54 @@
|
|
|
79
35
|
right: -$lumx-spacing-unit / 2;
|
|
80
36
|
bottom: -$lumx-spacing-unit / 2;
|
|
81
37
|
}
|
|
38
|
+
|
|
39
|
+
/* Rounded variant */
|
|
40
|
+
&--variant-rounded &__background {
|
|
41
|
+
border-radius: var(--lumx-border-radius);
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
&--fill-height,
|
|
45
|
+
&--fill-height &__background,
|
|
46
|
+
&--fill-height &__image {
|
|
47
|
+
flex: 1 1 auto;
|
|
48
|
+
height: 100%;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
/* Thumbnail original ratio */
|
|
52
|
+
&--aspect-ratio-original {
|
|
53
|
+
&:not(#{$self}--fill-height) {
|
|
54
|
+
width: fit-content;
|
|
55
|
+
height: fit-content;
|
|
56
|
+
|
|
57
|
+
#{$self}__image:not(#{$self}__image--is-loading)
|
|
58
|
+
{
|
|
59
|
+
width: fit-content;
|
|
60
|
+
height: fit-content;
|
|
61
|
+
max-width: 100%;
|
|
62
|
+
max-height: 100%;
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
&#{$self}--fill-height {
|
|
67
|
+
#{$self}__background,
|
|
68
|
+
#{$self}__image
|
|
69
|
+
{
|
|
70
|
+
max-height: unset;
|
|
71
|
+
max-width: unset;
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
/* Thumbnail error fallback */
|
|
77
|
+
&--has-error &__fallback {
|
|
78
|
+
position: absolute;
|
|
79
|
+
inset: 0;
|
|
80
|
+
display: flex;
|
|
81
|
+
align-items: center;
|
|
82
|
+
justify-content: center;
|
|
83
|
+
background-color: lumx-color-variant('dark', 'L6');
|
|
84
|
+
}
|
|
85
|
+
|
|
82
86
|
}
|
|
83
87
|
|
|
84
88
|
/* Thumbnail sizes
|
|
@@ -86,17 +90,41 @@
|
|
|
86
90
|
|
|
87
91
|
@each $key, $size in $lumx-sizes {
|
|
88
92
|
.#{$lumx-base-prefix}-thumbnail--size-#{$key} {
|
|
89
|
-
width: $size;
|
|
93
|
+
max-width: $size;
|
|
94
|
+
width: 100%;
|
|
95
|
+
|
|
96
|
+
.#{$lumx-base-prefix}-thumbnail__background,
|
|
97
|
+
.#{$lumx-base-prefix}-thumbnail__image {
|
|
98
|
+
width: 100%;
|
|
99
|
+
}
|
|
90
100
|
}
|
|
91
101
|
}
|
|
92
102
|
|
|
93
103
|
/* Thumbnail aspect ratio
|
|
94
104
|
========================================================================== */
|
|
95
105
|
|
|
106
|
+
.#{$lumx-base-prefix}-thumbnail:not(.#{$lumx-base-prefix}-thumbnail--aspect-ratio-original) {
|
|
107
|
+
|
|
108
|
+
.#{$lumx-base-prefix}-thumbnail__background {
|
|
109
|
+
width: 100%;
|
|
110
|
+
position: relative;
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
.#{$lumx-base-prefix}-thumbnail__image {
|
|
114
|
+
position: absolute;
|
|
115
|
+
inset: 0;
|
|
116
|
+
width: 100%;
|
|
117
|
+
height: 100%;
|
|
118
|
+
object-fit: cover;
|
|
119
|
+
object-position: center;
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
|
|
96
123
|
@each $key, $aspect-ratio in $lumx-thumbnail-aspect-ratio {
|
|
97
|
-
.#{$lumx-base-prefix}-thumbnail--aspect-ratio-#{$key}
|
|
124
|
+
.#{$lumx-base-prefix}-thumbnail--aspect-ratio-#{$key} {
|
|
98
125
|
.#{$lumx-base-prefix}-thumbnail__background {
|
|
99
|
-
|
|
126
|
+
padding-top: $aspect-ratio;
|
|
127
|
+
}
|
|
100
128
|
}
|
|
101
129
|
}
|
|
102
130
|
|
|
@@ -120,49 +148,61 @@
|
|
|
120
148
|
pointer-events: none;
|
|
121
149
|
}
|
|
122
150
|
|
|
151
|
+
/* Hover */
|
|
123
152
|
&:hover::after,
|
|
124
153
|
&:focus::after {
|
|
125
154
|
@include lumx-state(lumx-base-const('state', 'HOVER'), lumx-base-const('emphasis', 'LOW'), 'dark');
|
|
126
155
|
}
|
|
127
156
|
|
|
157
|
+
/* Active */
|
|
128
158
|
&:active::after {
|
|
129
159
|
@include lumx-state(lumx-base-const('state', 'ACTIVE'), lumx-base-const('emphasis', 'LOW'), 'dark');
|
|
130
160
|
}
|
|
131
161
|
}
|
|
132
162
|
|
|
163
|
+
/* Focused (variant rounded) */
|
|
133
164
|
.#{$lumx-base-prefix}-thumbnail--variant-rounded.#{$lumx-base-prefix}-thumbnail--is-clickable {
|
|
134
165
|
&[data-focus-visible-added]::after {
|
|
135
166
|
border-radius: var(--lumx-border-radius);
|
|
136
167
|
}
|
|
137
168
|
}
|
|
138
169
|
|
|
170
|
+
/* Focused (light theme) */
|
|
139
171
|
.#{$lumx-base-prefix}-thumbnail--theme-light.#{$lumx-base-prefix}-thumbnail--is-clickable {
|
|
140
172
|
&[data-focus-visible-added]::after {
|
|
141
173
|
@include lumx-state(lumx-base-const('state', 'FOCUS'), lumx-base-const('emphasis', 'LOW'), 'dark');
|
|
142
174
|
}
|
|
143
175
|
}
|
|
144
176
|
|
|
177
|
+
/* Focused (dark theme) */
|
|
145
178
|
.#{$lumx-base-prefix}-thumbnail--theme-dark.#{$lumx-base-prefix}-thumbnail--is-clickable {
|
|
146
179
|
&[data-focus-visible-added]::after {
|
|
147
180
|
@include lumx-state(lumx-base-const('state', 'FOCUS'), lumx-base-const('emphasis', 'LOW'), 'light');
|
|
148
181
|
}
|
|
149
182
|
}
|
|
150
183
|
|
|
184
|
+
/* Loading */
|
|
185
|
+
.#{$lumx-base-prefix}-thumbnail--is-loading {
|
|
186
|
+
&.#{$lumx-base-prefix}-thumbnail--theme-dark .#{$lumx-base-prefix}-thumbnail__background {
|
|
187
|
+
@include lumx-skeleton('dark');
|
|
188
|
+
}
|
|
189
|
+
&.#{$lumx-base-prefix}-thumbnail--theme-light .#{$lumx-base-prefix}-thumbnail__background {
|
|
190
|
+
@include lumx-skeleton('light');
|
|
191
|
+
}
|
|
192
|
+
}
|
|
193
|
+
|
|
151
194
|
/* Thumbnail badge mask
|
|
152
195
|
========================================================================== */
|
|
153
196
|
|
|
154
|
-
|
|
155
|
-
$mask-size: map-get($lumx-sizes, lumx-base-const('size', 'XS')) - $lumx-spacing-unit;
|
|
156
|
-
$mask-offset: $size - 6;
|
|
197
|
+
$badge-radius-size: map-get($lumx-sizes, lumx-base-const('size', 'XS')) / 2 + 2;
|
|
157
198
|
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
}
|
|
199
|
+
.#{$lumx-base-prefix}-thumbnail--has-badge {
|
|
200
|
+
.#{$lumx-base-prefix}-thumbnail__background,
|
|
201
|
+
.#{$lumx-base-prefix}-thumbnail__fallback {
|
|
202
|
+
mask-image: radial-gradient(
|
|
203
|
+
circle at calc(100% - #{$badge-radius-size - 6}) calc(100% - #{$badge-radius-size - 6}),
|
|
204
|
+
transparent $badge-radius-size,
|
|
205
|
+
/* offset circle size (+1) to soften the edge */ black $badge-radius-size + 1
|
|
206
|
+
);
|
|
167
207
|
}
|
|
168
208
|
}
|
|
@@ -73,7 +73,7 @@
|
|
|
73
73
|
margin-bottom: $lumx-spacing-unit;
|
|
74
74
|
|
|
75
75
|
#{$self}--theme-light & {
|
|
76
|
-
color: lumx-color-variant('dark', '
|
|
76
|
+
color: lumx-color-variant('dark', 'L1');
|
|
77
77
|
}
|
|
78
78
|
|
|
79
79
|
#{$self}--theme-dark & {
|
|
@@ -87,7 +87,7 @@
|
|
|
87
87
|
text-align: center;
|
|
88
88
|
|
|
89
89
|
#{$self}--theme-light & {
|
|
90
|
-
color: lumx-color-variant('dark', '
|
|
90
|
+
color: lumx-color-variant('dark', 'L1');
|
|
91
91
|
}
|
|
92
92
|
|
|
93
93
|
#{$self}--theme-dark & {
|