File tree Expand file tree Collapse file tree 1 file changed +1
-14
lines changed Expand file tree Collapse file tree 1 file changed +1
-14
lines changed Original file line number Diff line number Diff line change 1
- @use ' ../core/theming/inspection' ;
2
1
@use ' ../core/tokens/m2-utils' ;
3
2
@use ' sass:map' ;
4
- @use ' sass:meta' ;
5
3
6
4
@function get-tokens ($theme ) {
7
5
$system : m2-utils .get-system ($theme );
8
6
9
- // TODO: Use system colors instead of checking theme type and using primary hues
10
- $snack-bar-button-color : map .get ($system , inverse-primary );
11
- @if (meta .type-of ($theme ) == map and map .get ($theme , color )) {
12
- $is-dark : inspection .get-theme-type ($theme ) == dark ;
13
- $snack-bar-button-color : if (
14
- $is-dark ,
15
- inspection .get-theme-color ($theme , primary , 500 ),
16
- inspection .get-theme-color ($theme , primary , 100 )
17
- );
18
- }
19
-
20
7
@return (
21
8
base: (
22
9
snack- bar- container- shape: 4px ,
23
10
),
24
11
color : (
25
12
snack- bar- container- color: map .get ($system , inverse-surface ),
26
13
snack- bar- supporting- text- color: map .get ($system , inverse-on-surface ),
27
- snack- bar- button- color: $snack-bar-button-color
14
+ snack- bar- button- color: map . get ( $system , inverse-primary )
28
15
),
29
16
typography: (
30
17
snack- bar- supporting- text- font: map .get ($system , body-medium-font ),
You can’t perform that action at this time.
0 commit comments