matcha-theme 1.0.25 → 18.0.27
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/core.scss +1210 -0
- package/matcha-core.css +62385 -0
- package/matcha-core.min.css +1 -0
- package/package.json +1 -1
- package/README.md +0 -304
- package/abstracts/_breakpoints.scss +0 -33
- package/abstracts/_colors.scss +0 -469
- package/abstracts/_elevation.scss +0 -102
- package/abstracts/_functions.scss +0 -398
- package/abstracts/_grid.scss +0 -159
- package/abstracts/_order.scss +0 -46
- package/abstracts/_position.scss +0 -51
- package/abstracts/_sizes.scss +0 -166
- package/abstracts/_spacings.scss +0 -216
- package/abstracts/_typography.scss +0 -124
- package/base/_helpers.scss +0 -2183
- package/base/_reset.scss +0 -9
- package/base/_typography.scss +0 -244
- package/components/matcha-audio-player.scss +0 -37
- package/components/matcha-buttons.scss +0 -199
- package/components/matcha-cards.scss +0 -93
- package/components/matcha-color-pick.scss +0 -32
- package/components/matcha-draggable.scss +0 -25
- package/components/matcha-header.scss +0 -327
- package/components/matcha-horizontal-tree.scss +0 -277
- package/components/matcha-progress-bar.scss +0 -107
- package/components/matcha-scrollbar.scss +0 -36
- package/components/matcha-scrollbox-shadow.scss +0 -127
- package/components/matcha-table.scss +0 -279
- package/fonts/CircularStd-Black.eot +0 -0
- package/fonts/CircularStd-Black.svg +0 -3426
- package/fonts/CircularStd-Black.ttf +0 -0
- package/fonts/CircularStd-Black.woff +0 -0
- package/fonts/CircularStd-Black.woff2 +0 -0
- package/fonts/CircularStd-Bold.eot +0 -0
- package/fonts/CircularStd-Bold.otf +0 -0
- package/fonts/CircularStd-Bold.svg +0 -13532
- package/fonts/CircularStd-Bold.ttf +0 -0
- package/fonts/CircularStd-Bold.woff +0 -0
- package/fonts/CircularStd-Bold.woff2 +0 -0
- package/fonts/CircularStd-Medium.eot +0 -0
- package/fonts/CircularStd-Medium.otf +0 -0
- package/fonts/CircularStd-Medium.svg +0 -13511
- package/fonts/CircularStd-Medium.ttf +0 -0
- package/fonts/CircularStd-Medium.woff +0 -0
- package/fonts/CircularStd-Medium.woff2 +0 -0
- package/fonts/CircularStd-Regular.eot +0 -0
- package/fonts/CircularStd-Regular.otf +0 -0
- package/fonts/CircularStd-Regular.svg +0 -2378
- package/fonts/CircularStd-Regular.ttf +0 -0
- package/fonts/CircularStd-Regular.woff +0 -0
- package/fonts/CircularStd-Regular.woff2 +0 -0
- package/main.scss +0 -133
- package/tokens/_animations.scss +0 -37
- package/tokens/_breakpoints.scss +0 -38
- package/tokens/_color-tokens.scss +0 -1391
- package/tokens/_elevation-tokens.scss +0 -14
- package/tokens/_spacing-tokens.scss +0 -96
- package/tokens/_typography-tokens.scss +0 -25
- package/vendors/angular-editor.scss +0 -56
- package/vendors/angular-material-fixes.scss +0 -261
- package/vendors/calendar.scss +0 -2880
- package/vendors/charts.scss +0 -92
- package/vendors/ng5-slider.scss +0 -56
- package/vendors/ngx-material-timepicker.scss +0 -50
package/abstracts/_colors.scss
DELETED
|
@@ -1,469 +0,0 @@
|
|
|
1
|
-
// Saturation Levels
|
|
2
|
-
$saturationLevels: 50, 100, 200, 300, 400, 500, 600, 700, 800, 900, A100, A200, A400, A700;
|
|
3
|
-
|
|
4
|
-
// Hues Palette Colors
|
|
5
|
-
$index: 0;
|
|
6
|
-
// -------------------------------------------------------------------------------------------------------------------
|
|
7
|
-
// @ Text color levels generator
|
|
8
|
-
// -------------------------------------------------------------------------------------------------------------------
|
|
9
|
-
@mixin _generate-text-color-levels($classes, $contrast) {
|
|
10
|
-
@if ($contrast == "dark") {
|
|
11
|
-
#{$classes} {
|
|
12
|
-
&.secondary-text,
|
|
13
|
-
.secondary-text {
|
|
14
|
-
color: rgba(0, 0, 0, 0.54) !important;
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
&.hint-text,
|
|
18
|
-
.hint-text,
|
|
19
|
-
&.disabled-text,
|
|
20
|
-
.disabled-text {
|
|
21
|
-
color: rgba(0, 0, 0, 0.38) !important;
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
&.divider,
|
|
25
|
-
.divider {
|
|
26
|
-
color: rgba(0, 0, 0, 0.12) !important;
|
|
27
|
-
}
|
|
28
|
-
}
|
|
29
|
-
} @else {
|
|
30
|
-
#{$classes} {
|
|
31
|
-
&.secondary-text,
|
|
32
|
-
.secondary-text {
|
|
33
|
-
color: rgba(255, 255, 255, 0.7) !important;
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
&.hint-text,
|
|
37
|
-
.hint-text,
|
|
38
|
-
&.disabled-text,
|
|
39
|
-
.disabled-text {
|
|
40
|
-
color: rgba(255, 255, 255, 0.5) !important;
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
&.divider,
|
|
44
|
-
.divider {
|
|
45
|
-
color: rgba(255, 255, 255, 0.12) !important;
|
|
46
|
-
}
|
|
47
|
-
}
|
|
48
|
-
}
|
|
49
|
-
}
|
|
50
|
-
// @mixin _generate-classes($prefix, $color-map, $saturation) {
|
|
51
|
-
// // .primary-500
|
|
52
|
-
// // .primary-600-bg
|
|
53
|
-
// // .primary-700-fg
|
|
54
|
-
// $background: map-get($color-map, $saturation);
|
|
55
|
-
// $contrast: map-get($color-map, #{$saturation}-contrast);
|
|
56
|
-
|
|
57
|
-
// .#{$prefix}-#{$saturation} {
|
|
58
|
-
// background: $background;
|
|
59
|
-
// color: $contrast;
|
|
60
|
-
// }
|
|
61
|
-
// .#{$prefix}-#{$saturation}-bg {
|
|
62
|
-
// background: $background;
|
|
63
|
-
// }
|
|
64
|
-
// .#{$prefix}-#{$saturation}-fg {
|
|
65
|
-
// color: $background;
|
|
66
|
-
// }
|
|
67
|
-
// }
|
|
68
|
-
|
|
69
|
-
// -------------------------------------------------------------------------------------------------------------------
|
|
70
|
-
// @ Static color classes generator
|
|
71
|
-
// -------------------------------------------------------------------------------------------------------------------
|
|
72
|
-
@mixin _generate-static-color-classes($colorName, $color, $contrastColor, $saturation) {
|
|
73
|
-
$colorSelector: unquote(".#{$colorName}#{$saturation}");
|
|
74
|
-
|
|
75
|
-
#{$colorSelector} {
|
|
76
|
-
background-color: $color !important;
|
|
77
|
-
color: $contrastColor !important;
|
|
78
|
-
|
|
79
|
-
&[disabled] {
|
|
80
|
-
background-color: rgba($color, 0.12) !important;
|
|
81
|
-
color: rgba($contrastColor, 0.26) !important;
|
|
82
|
-
}
|
|
83
|
-
}
|
|
84
|
-
|
|
85
|
-
#{$colorSelector}-bg {
|
|
86
|
-
background-color: $color !important;
|
|
87
|
-
}
|
|
88
|
-
|
|
89
|
-
#{$colorSelector}-fg {
|
|
90
|
-
color: $color !important;
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
@if ($saturation == "-500") {
|
|
94
|
-
$colorSelectorDefault: unquote(".#{$colorName}");
|
|
95
|
-
|
|
96
|
-
#{$colorSelectorDefault}-bg {
|
|
97
|
-
background-color: $color !important;
|
|
98
|
-
}
|
|
99
|
-
|
|
100
|
-
#{$colorSelectorDefault}-fg {
|
|
101
|
-
color: $color !important;
|
|
102
|
-
}
|
|
103
|
-
}
|
|
104
|
-
|
|
105
|
-
// #{$colorSelector}-border,
|
|
106
|
-
// #{$colorSelector}-border-top,
|
|
107
|
-
// #{$colorSelector}-border-right,
|
|
108
|
-
// #{$colorSelector}-border-bottom,
|
|
109
|
-
// #{$colorSelector}-border-left {
|
|
110
|
-
// border-color: $color !important;
|
|
111
|
-
// }
|
|
112
|
-
|
|
113
|
-
// #{$colorSelector}-fill {
|
|
114
|
-
// fill: $color !important;
|
|
115
|
-
// }
|
|
116
|
-
}
|
|
117
|
-
|
|
118
|
-
@mixin colors-classes-static($theme) {
|
|
119
|
-
$palettes: getAllPalettes($theme);
|
|
120
|
-
$light-contrasting-classes: ();
|
|
121
|
-
$dark-contrasting-classes: ();
|
|
122
|
-
|
|
123
|
-
@each $paletteName, $palette in $palettes {
|
|
124
|
-
// $contrasts: map-get($red, "contrast");
|
|
125
|
-
// $contrasts = all contrast colors of $red palette
|
|
126
|
-
$contrasts: map-get($palette, "contrast");
|
|
127
|
-
|
|
128
|
-
@each $saturation in $saturationLevels {
|
|
129
|
-
// $color: map-get($red, 500)
|
|
130
|
-
// $contrast: map-get($contrasts, 500); 500 contrast color of $red palette
|
|
131
|
-
$color: map-get($palette, $saturation);
|
|
132
|
-
$contrast: map-get($contrasts, $saturation);
|
|
133
|
-
|
|
134
|
-
@if ($color != null and $contrast != null) {
|
|
135
|
-
@include _generate-static-color-classes($paletteName, $color, $contrast, "-#{$saturation}");
|
|
136
|
-
|
|
137
|
-
// If the contrast color is dark
|
|
138
|
-
@if (rgba(black, 1) ==rgba($contrast, 1)) {
|
|
139
|
-
$dark-contrasting-classes: append(
|
|
140
|
-
$dark-contrasting-classes,
|
|
141
|
-
unquote(".#{$paletteName}-#{$saturation}"),
|
|
142
|
-
"comma"
|
|
143
|
-
);
|
|
144
|
-
}
|
|
145
|
-
|
|
146
|
-
// if the contrast color is light
|
|
147
|
-
@else {
|
|
148
|
-
$light-contrasting-classes: append(
|
|
149
|
-
$light-contrasting-classes,
|
|
150
|
-
unquote(".#{$paletteName}-#{$saturation}"),
|
|
151
|
-
"comma"
|
|
152
|
-
);
|
|
153
|
-
}
|
|
154
|
-
}
|
|
155
|
-
// Run the generator one more time for default values (500)
|
|
156
|
-
// if we are not working with primary, accent or warn palettes
|
|
157
|
-
// @if ($saturation == 500) {
|
|
158
|
-
// // Generate color classes
|
|
159
|
-
// @include _generate-static-color-classes($paletteName, $color, $contrast, "");
|
|
160
|
-
|
|
161
|
-
// // Add color to the correct list depending on the contrasting color
|
|
162
|
-
|
|
163
|
-
// // If the contrast color is dark
|
|
164
|
-
// @if (rgba(black, 1) ==rgba($contrast, 1)) {
|
|
165
|
-
// $dark-contrasting-classes: append($dark-contrasting-classes, unquote(".#{$paletteName}"), "comma");
|
|
166
|
-
// }
|
|
167
|
-
|
|
168
|
-
// // if the contrast color is light
|
|
169
|
-
// @else {
|
|
170
|
-
// $light-contrasting-classes: append(
|
|
171
|
-
// $light-contrasting-classes,
|
|
172
|
-
// unquote(".#{$paletteName}"),
|
|
173
|
-
// "comma"
|
|
174
|
-
// );
|
|
175
|
-
// }
|
|
176
|
-
// }
|
|
177
|
-
}
|
|
178
|
-
}
|
|
179
|
-
|
|
180
|
-
// Generate contrasting colors
|
|
181
|
-
@include _generate-text-color-levels($dark-contrasting-classes, "dark");
|
|
182
|
-
@include _generate-text-color-levels($light-contrasting-classes, "light");
|
|
183
|
-
}
|
|
184
|
-
|
|
185
|
-
// -------------------------------------------------------------------------------------------------------------------
|
|
186
|
-
// @ Dynamic color classes generator
|
|
187
|
-
// -------------------------------------------------------------------------------------------------------------------
|
|
188
|
-
@mixin _generate-dynamic-color-classes($attributes, $palette, $paletteName, $background, $foreground) {
|
|
189
|
-
$color: unquote(#{$paletteName});
|
|
190
|
-
$baseClassName: (".background-#{$paletteName}"); // .base-yellow
|
|
191
|
-
// $baseClassNameDefault: (".#{$paletteName}"); // .amber
|
|
192
|
-
|
|
193
|
-
// $paletteClassNameDefault: "#{$paletteName}"; // .amber
|
|
194
|
-
@each $attribute, $attribute-palette in $attributes {
|
|
195
|
-
$withPrefixSelector: ".#{$attribute}-#{$color}"; // .background-amber
|
|
196
|
-
$nonPrefixSelector: ".#{$color}"; // .amber
|
|
197
|
-
|
|
198
|
-
// generate classes for color-amber, background-amber, fill-amber, stroke-amber and border-color-amber
|
|
199
|
-
#{$withPrefixSelector} {
|
|
200
|
-
#{$attribute}: map-get($attribute-palette, $paletteName);
|
|
201
|
-
@if ($attribute != "color") {
|
|
202
|
-
&-alpha {
|
|
203
|
-
#{$attribute}: map-get($attribute-palette, ("#{$paletteName}-alpha")) !important;
|
|
204
|
-
}
|
|
205
|
-
}
|
|
206
|
-
}
|
|
207
|
-
// generate classes red blue green pink
|
|
208
|
-
@if ($attribute == "background") {
|
|
209
|
-
#{$nonPrefixSelector} {
|
|
210
|
-
background: map-get($attribute-palette, $paletteName) !important;
|
|
211
|
-
}
|
|
212
|
-
}
|
|
213
|
-
|
|
214
|
-
@if ($attribute == "color") {
|
|
215
|
-
@if ($color == "yellow" or $color == "amber") {
|
|
216
|
-
#{$nonPrefixSelector} {
|
|
217
|
-
color: map-get($foreground, static-dark-text);
|
|
218
|
-
}
|
|
219
|
-
}
|
|
220
|
-
@if ($color != "yellow" and $color != "amber") {
|
|
221
|
-
#{$nonPrefixSelector} {
|
|
222
|
-
color: map-get($foreground, text-inverse);
|
|
223
|
-
}
|
|
224
|
-
}
|
|
225
|
-
}
|
|
226
|
-
// $selector: ".#{$attribute}-#{$color}"; // .background-yellow
|
|
227
|
-
// @if ($attribute != "color") {
|
|
228
|
-
// #{$selector} {
|
|
229
|
-
// #{$attribute}: map-get($background, $color) !important;
|
|
230
|
-
// &-alpha {
|
|
231
|
-
// #{$attribute}: map-get($background, ("#{$paletteName}-alpha")) !important;
|
|
232
|
-
// }
|
|
233
|
-
// }
|
|
234
|
-
// }
|
|
235
|
-
// @if ($attribute == "color") {
|
|
236
|
-
// }
|
|
237
|
-
}
|
|
238
|
-
|
|
239
|
-
// #{$baseClassName} {
|
|
240
|
-
// // background: map-get($background, ("#{$paletteName}")) !important;
|
|
241
|
-
// &-alpha {
|
|
242
|
-
// background: map-get($background, ("#{$paletteName}-alpha")) !important;
|
|
243
|
-
// }
|
|
244
|
-
// }
|
|
245
|
-
|
|
246
|
-
// #{$baseClassNameDefault} {
|
|
247
|
-
// background: map-get($background, ("#{$paletteName}")) !important;
|
|
248
|
-
// }
|
|
249
|
-
|
|
250
|
-
// @if ($color != yellow or $color != amber) {
|
|
251
|
-
// #{$baseClassNameDefault} {
|
|
252
|
-
// color: map-get($foreground, text-inverse);
|
|
253
|
-
// }
|
|
254
|
-
// }
|
|
255
|
-
|
|
256
|
-
// @if ($color == yellow or $color == amber) {
|
|
257
|
-
// #{$baseClassNameDefault} {
|
|
258
|
-
// color: map-get($foreground, static-dark-text);
|
|
259
|
-
// }
|
|
260
|
-
// }
|
|
261
|
-
}
|
|
262
|
-
|
|
263
|
-
@mixin colors-classes-dynamic($theme) {
|
|
264
|
-
$palettes: getAllPalettes($theme);
|
|
265
|
-
|
|
266
|
-
$is-dark: map-get($theme, isdark);
|
|
267
|
-
$primary: map-get($theme, primary);
|
|
268
|
-
$accent: map-get($theme, accent);
|
|
269
|
-
$warn: map-get($theme, warn);
|
|
270
|
-
$background: map-get($theme, background);
|
|
271
|
-
$foreground: map-get($theme, foreground);
|
|
272
|
-
|
|
273
|
-
$colorNames: red, pink, purple, deep-purple, indigo, blue, light-blue, cyan, teal, green, light-green, lime, yellow,
|
|
274
|
-
amber, orange, deep-orange, primary, accent, warn;
|
|
275
|
-
|
|
276
|
-
$attributes: (
|
|
277
|
-
color: $foreground,
|
|
278
|
-
border-color: $foreground,
|
|
279
|
-
background: $background,
|
|
280
|
-
fill: $background,
|
|
281
|
-
stroke: $background
|
|
282
|
-
);
|
|
283
|
-
|
|
284
|
-
// @each $saturation in $saturationLevels {
|
|
285
|
-
// // generate classes for all saturation levels of primary, accent and warn palettes
|
|
286
|
-
// @include _generate-classes("primary", $primary, $saturation);
|
|
287
|
-
// @include _generate-classes("accent", $accent, $saturation);
|
|
288
|
-
// @include _generate-classes("warn", $warn, $saturation);
|
|
289
|
-
// }
|
|
290
|
-
|
|
291
|
-
// // primary accent e warn
|
|
292
|
-
// @each $paletteName, $palette in $palettes {
|
|
293
|
-
// // generate
|
|
294
|
-
// // .background-primary
|
|
295
|
-
// // .background-primary-alpha
|
|
296
|
-
// // .base-primary
|
|
297
|
-
// // .base-primary-alpha
|
|
298
|
-
// // .primary
|
|
299
|
-
// // .primary-alpha
|
|
300
|
-
|
|
301
|
-
// // .primary-bg
|
|
302
|
-
// // .primary-fg
|
|
303
|
-
// .background-#{$paletteName},
|
|
304
|
-
// .base-#{$paletteName},
|
|
305
|
-
// .#{$paletteName} {
|
|
306
|
-
// background: map-get($palette, default);
|
|
307
|
-
// color: map-get($palette, default-contrast);
|
|
308
|
-
// &-alpha {
|
|
309
|
-
// background: rgba(map-get($background, background), 0.5) !important;
|
|
310
|
-
// }
|
|
311
|
-
// }
|
|
312
|
-
// .#{$paletteName}-bg {
|
|
313
|
-
// background: map-get($palette, default) !important;
|
|
314
|
-
// }
|
|
315
|
-
// .#{$paletteName}-fg {
|
|
316
|
-
// color: map-get($palette, default) !important;
|
|
317
|
-
// }
|
|
318
|
-
// // .background-#{$paletteName}-alpha,
|
|
319
|
-
// // .base-#{$paletteName}-alpha {
|
|
320
|
-
// // }
|
|
321
|
-
// }
|
|
322
|
-
|
|
323
|
-
.base-surface {
|
|
324
|
-
background: map-get($background, card);
|
|
325
|
-
color: map-get($foreground, text);
|
|
326
|
-
&-alpha {
|
|
327
|
-
background: rgba(map-get($background, card), 0.5) !important;
|
|
328
|
-
}
|
|
329
|
-
}
|
|
330
|
-
.base-fg {
|
|
331
|
-
background: map-get($foreground, text);
|
|
332
|
-
color: map-get($foreground, text-inverse);
|
|
333
|
-
&-alpha {
|
|
334
|
-
background: rgba(map-get($foreground, text), 0.2) !important;
|
|
335
|
-
}
|
|
336
|
-
}
|
|
337
|
-
.base-bg {
|
|
338
|
-
background: map-get($background, background);
|
|
339
|
-
color: map-get($foreground, text);
|
|
340
|
-
&-alpha {
|
|
341
|
-
background: map-get($background, background-alpha) !important;
|
|
342
|
-
}
|
|
343
|
-
}
|
|
344
|
-
|
|
345
|
-
.background-transparent,
|
|
346
|
-
.matcha-background-transparent {
|
|
347
|
-
background: transparent;
|
|
348
|
-
}
|
|
349
|
-
|
|
350
|
-
@each $attribute, $colorLevel in $attributes {
|
|
351
|
-
@if ($attribute != "color") {
|
|
352
|
-
.#{$attribute}-bg {
|
|
353
|
-
#{$attribute}: map-get($background, background) !important;
|
|
354
|
-
}
|
|
355
|
-
.#{$attribute}-bg-alpha {
|
|
356
|
-
#{$attribute}: map-get($background, background-alpha) !important;
|
|
357
|
-
}
|
|
358
|
-
.#{$attribute}-bg-inverse {
|
|
359
|
-
#{$attribute}: map-get($background, background-inverse) !important;
|
|
360
|
-
}
|
|
361
|
-
.#{$attribute}-bg-alpha-inverse {
|
|
362
|
-
#{$attribute}: map-get($background, background-alpha-inverse) !important;
|
|
363
|
-
}
|
|
364
|
-
.#{$attribute}-surface-inverse {
|
|
365
|
-
#{$attribute}: map-get($background, card-inverse) !important;
|
|
366
|
-
}
|
|
367
|
-
.#{$attribute}-surface-alpha-inverse {
|
|
368
|
-
#{$attribute}: map-get($background, card-alpha-inverse) !important;
|
|
369
|
-
}
|
|
370
|
-
.primary {
|
|
371
|
-
#{$attribute}: map-get($primary, default) !important;
|
|
372
|
-
}
|
|
373
|
-
.accent {
|
|
374
|
-
#{$attribute}: map-get($accent, default) !important;
|
|
375
|
-
}
|
|
376
|
-
.warn {
|
|
377
|
-
#{$attribute}: map-get($warn, default) !important;
|
|
378
|
-
}
|
|
379
|
-
}
|
|
380
|
-
|
|
381
|
-
@if ($attribute == "color") {
|
|
382
|
-
.primary {
|
|
383
|
-
#{$attribute}: map-get($primary, default-contrast) !important;
|
|
384
|
-
}
|
|
385
|
-
.accent {
|
|
386
|
-
#{$attribute}: map-get($accent, default-contrast) !important;
|
|
387
|
-
}
|
|
388
|
-
.warn {
|
|
389
|
-
#{$attribute}: map-get($warn, default-contrast) !important;
|
|
390
|
-
}
|
|
391
|
-
}
|
|
392
|
-
|
|
393
|
-
.#{$attribute}-primary {
|
|
394
|
-
#{$attribute}: map-get($primary, default) !important;
|
|
395
|
-
&-alpha {
|
|
396
|
-
background: rgba(map-get($primary, default), 0.2) !important;
|
|
397
|
-
}
|
|
398
|
-
}
|
|
399
|
-
.#{$attribute}-accent {
|
|
400
|
-
#{$attribute}: map-get($accent, default) !important;
|
|
401
|
-
&-alpha {
|
|
402
|
-
background: rgba(map-get($accent, default), 0.2) !important;
|
|
403
|
-
}
|
|
404
|
-
}
|
|
405
|
-
.#{$attribute}-warn {
|
|
406
|
-
#{$attribute}: map-get($warn, default) !important;
|
|
407
|
-
&-alpha {
|
|
408
|
-
background: rgba(map-get($warn, default), 0.2) !important;
|
|
409
|
-
}
|
|
410
|
-
}
|
|
411
|
-
.#{$attribute}-error {
|
|
412
|
-
#{$attribute}: map-get($background, error) !important;
|
|
413
|
-
}
|
|
414
|
-
.#{$attribute}-info {
|
|
415
|
-
#{$attribute}: map-get($background, info) !important;
|
|
416
|
-
}
|
|
417
|
-
.#{$attribute}-success {
|
|
418
|
-
#{$attribute}: map-get($background, success) !important;
|
|
419
|
-
}
|
|
420
|
-
.#{$attribute}-warning {
|
|
421
|
-
#{$attribute}: map-get($background, warning) !important;
|
|
422
|
-
}
|
|
423
|
-
.#{$attribute}-fg,
|
|
424
|
-
.#{$attribute}-base,
|
|
425
|
-
.#{$attribute}-text {
|
|
426
|
-
#{$attribute}: map-get($foreground, text) !important;
|
|
427
|
-
}
|
|
428
|
-
|
|
429
|
-
.#{$attribute}-fg-inverse,
|
|
430
|
-
.#{$attribute}-base-inverse,
|
|
431
|
-
.#{$attribute}-text-inverse {
|
|
432
|
-
#{$attribute}: map-get($foreground, text-inverse) !important;
|
|
433
|
-
}
|
|
434
|
-
|
|
435
|
-
.#{$attribute}-surface {
|
|
436
|
-
#{$attribute}: map-get($background, card) !important;
|
|
437
|
-
}
|
|
438
|
-
|
|
439
|
-
.#{$attribute}-surface-alpha {
|
|
440
|
-
#{$attribute}: map-get($background, card-alpha) !important;
|
|
441
|
-
}
|
|
442
|
-
|
|
443
|
-
.#{$attribute}-placeholder {
|
|
444
|
-
#{$attribute}: map-get($foreground, placeholder) !important;
|
|
445
|
-
&-alpha {
|
|
446
|
-
background: rgba(map-get($foreground, placeholder), 0.2) !important;
|
|
447
|
-
}
|
|
448
|
-
}
|
|
449
|
-
|
|
450
|
-
.#{$attribute}-label {
|
|
451
|
-
#{$attribute}: map-get($foreground, label) !important;
|
|
452
|
-
}
|
|
453
|
-
|
|
454
|
-
.#{$attribute}-disabled {
|
|
455
|
-
#{$attribute}: map-get($background, disabled) !important;
|
|
456
|
-
}
|
|
457
|
-
|
|
458
|
-
.#{$attribute}-disabled-icon {
|
|
459
|
-
#{$attribute}: map-get($foreground, disabled-icon) !important;
|
|
460
|
-
}
|
|
461
|
-
|
|
462
|
-
.#{$attribute}-selected {
|
|
463
|
-
#{$attribute}: map-get($background, selected-button) !important;
|
|
464
|
-
}
|
|
465
|
-
}
|
|
466
|
-
@each $paletteName, $palette in $palettes {
|
|
467
|
-
@include _generate-dynamic-color-classes($attributes, $palette, $paletteName, $background, $foreground);
|
|
468
|
-
}
|
|
469
|
-
}
|
|
@@ -1,102 +0,0 @@
|
|
|
1
|
-
// -------------------------------------------------------------------------------------------------------------------
|
|
2
|
-
// @ Elevations Mixins
|
|
3
|
-
//
|
|
4
|
-
// A collection of mixins and CSS classes that can be used to apply elevation to a material
|
|
5
|
-
// element.
|
|
6
|
-
// See: https://material.io/design/environment/elevation.html
|
|
7
|
-
// Examples:
|
|
8
|
-
//
|
|
9
|
-
//
|
|
10
|
-
// .matcha-foo {
|
|
11
|
-
// @include $elevation(2);
|
|
12
|
-
//
|
|
13
|
-
// &:active {
|
|
14
|
-
// @include $elevation(8);
|
|
15
|
-
// }
|
|
16
|
-
// }
|
|
17
|
-
//
|
|
18
|
-
// <div id="external-card" class="elevation-z2"><p>Some content</p></div>
|
|
19
|
-
//
|
|
20
|
-
// For an explanation of the design behind how elevation is implemented, see the design doc at
|
|
21
|
-
// https://goo.gl/Kq0k9Z.
|
|
22
|
-
|
|
23
|
-
// Colors for umbra, penumbra, and ambient shadows. As described in the design doc, each elevation
|
|
24
|
-
// level is created using a set of 3 shadow values, one for umbra (the shadow representing the
|
|
25
|
-
// space completely obscured by an object relative to its light source), one for penumbra (the
|
|
26
|
-
// space partially obscured by an object), and one for ambient (the space which contains the object
|
|
27
|
-
// itself). For a further explanation of these terms and their meanings, see
|
|
28
|
-
// https://en.wikipedia.org/wiki/Umbra,_penumbra_and_antumbra.
|
|
29
|
-
|
|
30
|
-
// Maps for the different shadow sets and their values within each z-space. These values were
|
|
31
|
-
// created by taking a few reference shadow sets created by Google's Designers and interpolating
|
|
32
|
-
// all of the values between them.
|
|
33
|
-
//
|
|
34
|
-
// -----------------------------------------------------------------------------------------------------
|
|
35
|
-
|
|
36
|
-
// Applies the correct css rules to an element to give it the elevation specified by $zValue.
|
|
37
|
-
// The $zValue must be between 0 and 24.
|
|
38
|
-
@mixin elevation($zValue, $color: $elevation-color, $opacity: $elevation-opacity) {
|
|
39
|
-
@if type-of($zValue) !=number or not unitless($zValue) {
|
|
40
|
-
@error '$zValue must be a unitless number';
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
@if $zValue < 0 or $zValue >24 {
|
|
44
|
-
@error '$zValue must be between 0 and 24';
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
box-shadow: #{map-get(_get-umbra-map($color, $opacity), $zValue)},
|
|
48
|
-
#{map-get(_get-penumbra-map($color, $opacity), $zValue)},
|
|
49
|
-
#{map-get(_get-ambient-map($color, $opacity), $zValue)};
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
@mixin _theme-elevation($zValue, $theme, $opacity: $elevation-opacity) {
|
|
53
|
-
$foreground: map-get($theme, foreground);
|
|
54
|
-
$elevation-color: map-get($foreground, elevation);
|
|
55
|
-
$elevation-color-or-default: if($elevation-color ==null, $elevation-color, $elevation-color);
|
|
56
|
-
|
|
57
|
-
@include elevation($zValue, $elevation-color-or-default, $opacity);
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
// Applies the elevation to an element in a manner that allows
|
|
61
|
-
// consumers to override it via the Material elevation classes.
|
|
62
|
-
@mixin overridable-elevation($zValue, $color: $elevation-color, $opacity: $elevation-opacity) {
|
|
63
|
-
&:not([class*="#{$_elevation-prefix}"]) {
|
|
64
|
-
@include elevation($zValue, $color, $opacity);
|
|
65
|
-
}
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
@mixin _theme-overridable-elevation($zValue, $theme, $opacity: $elevation-opacity) {
|
|
69
|
-
$foreground: map-get($theme, foreground);
|
|
70
|
-
$elevation-color: map-get($foreground, elevation);
|
|
71
|
-
$elevation-color-or-default: if($elevation-color ==null, $elevation-color, $elevation-color);
|
|
72
|
-
|
|
73
|
-
@include overridable-elevation($zValue, $elevation-color-or-default, $opacity);
|
|
74
|
-
}
|
|
75
|
-
|
|
76
|
-
// Applies the correct css rules needed to have an element transition between elevations.
|
|
77
|
-
// This mixin should be applied to elements whose elevation values will change depending on their
|
|
78
|
-
// context (e.g. when active or disabled).
|
|
79
|
-
//
|
|
80
|
-
// NOTE(traviskaufman): Both this mixin and the above function use default parameters so they can
|
|
81
|
-
// be used in the same way by clients.
|
|
82
|
-
@mixin elevation-transition($duration: $elevation-transition-duration,
|
|
83
|
-
$easing: $elevation-transition-timing-function) {
|
|
84
|
-
// Returns a string that can be used as the value for a transition property for elevation.
|
|
85
|
-
// Calling this function directly is useful in situations where a component needs to transition
|
|
86
|
-
// more than one property.
|
|
87
|
-
//
|
|
88
|
-
// .foo {
|
|
89
|
-
// transition: elevation-transition-property-value(), opacity 100ms ease;
|
|
90
|
-
// }
|
|
91
|
-
transition: elevation-transition-property-value($duration, $easing);
|
|
92
|
-
}
|
|
93
|
-
|
|
94
|
-
// Css class generator for shadows
|
|
95
|
-
// $_elevation-prefix: "matcha-elevation-z";
|
|
96
|
-
@mixin elevation-theme($theme) {
|
|
97
|
-
@for $zValue from 0 through 24 {
|
|
98
|
-
.#{$_elevation-prefix}#{$zValue} {
|
|
99
|
-
@include _theme-elevation($zValue, $theme);
|
|
100
|
-
}
|
|
101
|
-
}
|
|
102
|
-
}
|