Skip to content

Commit 9cce63d

Browse files
authored
fix(inputs): wrong colors in material theme (#386)
1 parent 12e4a71 commit 9cce63d

File tree

7 files changed

+398
-297
lines changed

7 files changed

+398
-297
lines changed

sass/themes/schemas/components/dark/_combo.scss

Lines changed: 26 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,33 @@
1212

1313
/// Generates a dark material combo schema.
1414
/// @type {Map}
15+
/// @prop {Map} toggle-button-background [color: ('gray', 100)] - The combo toggle button background color.
16+
/// @prop {Map} toggle-button-background-focus [color: ('gray', 200)] - The combo toggle button background color when the combo is focused.
17+
/// @prop {Map} toggle-button-background-focus--border [color: ('gray', 100)] The combo toggle button background color when the combo is focused in border and line variants.
1518
/// @requires $material-combo
16-
$dark-material-combo: $material-combo;
19+
$dark-material-combo: extend(
20+
$material-combo,
21+
(
22+
toggle-button-background: (
23+
color: (
24+
'gray',
25+
100,
26+
),
27+
),
28+
toggle-button-background-focus: (
29+
color: (
30+
'gray',
31+
200,
32+
),
33+
),
34+
toggle-button-background-focus--border: (
35+
color: (
36+
'gray',
37+
100,
38+
),
39+
),
40+
)
41+
);
1742

1843
/// Generates a dark fluent combo schema.
1944
/// @type {Map}

sass/themes/schemas/components/dark/_input-group.scss

Lines changed: 19 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,16 +11,33 @@
1111

1212
/// Generates a dark material input-group schema.
1313
/// @type {Map}
14-
/// @prop {Map} box-background-focus [color: ('gray', 100)] - The background color of an input group of type box on focus.
14+
/// @prop {Map} box-background [color: ('gray', 200, .38)] - The background color of an input group of type box.
15+
/// @prop {Map} box-background-hover [color: ('gray', 200, .38)] - The background color of an input group of type box on hover.
16+
/// @prop {Map} box-background-focus [color: ('gray', 300, .38)] - The background color of an input group of type box on focus.
1517
/// @prop {Map} hover-bottom-line-color [color: ('gray', 800)] - The bottom line and border colors in the hover state.
1618
/// @requires $material-input-group
1719
$dark-material-input-group: extend(
1820
$material-input-group,
1921
(
22+
box-background: (
23+
color: (
24+
'gray',
25+
200,
26+
0.38,
27+
),
28+
),
29+
box-background-hover: (
30+
color: (
31+
'gray',
32+
200,
33+
0.38,
34+
),
35+
),
2036
box-background-focus: (
2137
color: (
2238
'gray',
23-
100,
39+
300,
40+
0.38,
2441
),
2542
),
2643
hover-bottom-line-color: (

sass/themes/schemas/components/dark/_select.scss

Lines changed: 26 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,33 @@
1212

1313
/// Generates a dark material select schema.
1414
/// @type {Map}
15+
/// @prop {Map} toggle-button-background [color: ('gray', 100)] - The select toggle button background color.
16+
/// @prop {Map} toggle-button-background-focus [color: ('gray', 200)] - The select toggle button background color when the select is focused.
17+
/// @prop {Map} toggle-button-background-focus--border [color: ('gray', 100)] - The select toggle button background color when the select is focused in material border and line variants.
1518
/// @requires $material-select
16-
$dark-material-select: $material-select;
19+
$dark-material-select: extend(
20+
$material-select,
21+
(
22+
toggle-button-background: (
23+
color: (
24+
'gray',
25+
100,
26+
),
27+
),
28+
toggle-button-background-focus: (
29+
color: (
30+
'gray',
31+
200,
32+
),
33+
),
34+
toggle-button-background-focus--border: (
35+
color: (
36+
'gray',
37+
100,
38+
),
39+
),
40+
)
41+
);
1742

1843
/// Generates a dark fluent select schema.
1944
/// @type {Map}

sass/themes/schemas/components/elevation/_input-group.scss

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,20 @@
99
/// @type Map
1010
/// @prop {Number} search-resting-elevation [1] - The elevation level, between 0-24, to be used for the resting state of the search input.
1111
/// @prop {Number} search-hover-elevation [2] - The elevation level, between 0-24, to be used for the hover state of the search input.
12-
/// @prop {Number} search-disabled-elevation [0] - The elevation level, between 0-24, to be used for the disabled state of the search input.
12+
/// @prop {Number} search-disabled-elevation [1] - The elevation level, between 0-24, to be used for the disabled state of the search input.
1313
$default-elevation-input-group: (
1414
search-resting-elevation: 1,
1515
search-hover-elevation: 2,
16+
search-disabled-elevation: 1,
17+
);
18+
19+
/// @type Map
20+
/// @prop {Number} search-resting-elevation [0] - The elevation level, between 0-24, to be used for the resting state of the search input.
21+
/// @prop {Number} search-hover-elevation [0] - The elevation level, between 0-24, to be used for the hover state of the search input.
22+
/// @prop {Number} search-disabled-elevation [0] - The elevation level, between 0-24, to be used for the disabled state of the search input.
23+
$bootstrap-elevation-input-group: (
24+
search-resting-elevation: 0,
25+
search-hover-elevation: 0,
1626
search-disabled-elevation: 0,
1727
);
1828

sass/themes/schemas/components/light/_combo.scss

Lines changed: 17 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -17,14 +17,14 @@
1717
/// @prop {Map} toggle-button-background [color: ('gray', 300)] - The combo toggle button background color.
1818
/// @prop {Map} toggle-button-background-focus [color: ('gray', 300)] - The combo toggle button background color when the combo is focused.
1919
/// @prop {Map} toggle-button-foreground [color: ('gray', 700)] - The combo toggle button foreground color.
20-
/// @prop {Map} toggle-button-foreground-focus [color: ('gray', 700)] - The combo toggle button foreground color when the combo is focused.
20+
/// @prop {Map} toggle-button-foreground-focus [color: ('gray', 900)] - The combo toggle button foreground color when the combo is focused.
2121
/// @prop {Map} toggle-button-foreground-filled [color: ('gray', 900)] - The combo toggle button foreground color when the combo is focused.
2222
/// @prop {Map} toggle-button-background-disabled [color: ('gray', 100)] - The combo toggle button background color when the combo is disabled.
2323
/// @prop {Map} toggle-button-foreground-disabled [color: ('gray', 400)] - The combo toggle button foreground color when the combo is disabled.
2424
/// @prop {Map} toggle-button-background-focus--border [color: ('gray', 300)] The combo toggle button background color when the combo is focused in border and line variants.
2525
/// @prop {Color} clear-button-background [transparent] - The combo clear button background color.
26-
/// @prop {Map} clear-button-foreground [contrast-color: ('gray', 100)] - The combo toggle clear foreground color.
27-
/// @prop {Map} clear-button-foreground-focus [contrast-color: ('gray', 100)] - The combo clear button foreground color when the combo is focused.
26+
/// @prop {Map} clear-button-foreground [color: ('gray', 900)] - The combo toggle clear foreground color.
27+
/// @prop {Map} clear-button-foreground-focus [color: ('gray', 900)] - The combo clear button foreground color when the combo is focused.
2828
/// @prop {Map} case-icon-color [color: ('gray', 400)] - The case sensitive icon color in inactive state for combo search input
2929
/// @prop {Map} case-icon-color--active [color: ('primary', 500)] - The case sensitive icon color in active state for combo search input
3030
/// @prop {Number} default-size [2] - The default size used for the combo component.
@@ -83,7 +83,7 @@ $light-combo: (
8383
toggle-button-foreground-focus: (
8484
color: (
8585
'gray',
86-
700,
86+
900,
8787
),
8888
),
8989
toggle-button-foreground-filled: (
@@ -94,15 +94,15 @@ $light-combo: (
9494
),
9595
clear-button-background: transparent,
9696
clear-button-foreground: (
97-
contrast-color: (
97+
color: (
9898
'gray',
99-
100,
99+
900,
100100
),
101101
),
102102
clear-button-foreground-focus: (
103-
contrast-color: (
103+
color: (
104104
'gray',
105-
100,
105+
900,
106106
),
107107
),
108108
toggle-button-background-disabled: (
@@ -122,7 +122,7 @@ $light-combo: (
122122

123123
/// Generates a material combo schema.
124124
/// @type {Map}
125-
/// @prop {Map} toggle-button-background-focus [color: ('gray', 400, .3)] - The combo toggle button background color when the combo is focused.
125+
/// @prop {Map} toggle-button-background-focus [color: ('gray', 400)] - The combo toggle button background color when the combo is focused.
126126
/// @prop {Color} clear-button-background-focus [transparent] - The combo clear button background color when the combo is focused.
127127
/// @prop {Map} toggle-button-foreground-disabled [color: ('gray', 500)] - The combo toggle button foreground color when the combo is disabled.
128128
/// @requires {Map} $light-combo
@@ -133,7 +133,6 @@ $material-combo: extend(
133133
color: (
134134
'gray',
135135
400,
136-
0.3,
137136
),
138137
),
139138
clear-button-background-focus: transparent,
@@ -152,6 +151,7 @@ $material-combo: extend(
152151
/// @prop {Map} toggle-button-background-focus [color: ('gray', 100)] - The combo toggle button background color when the combo is focused.
153152
/// @prop {Color} clear-button-background [color: ('gray', 100)] - The combo clear button background color.
154153
/// @prop {Color} clear-button-background-focus [color: ('gray', 100)] - The combo clear button background color when the combo is focused.
154+
/// @prop {Map} toggle-button-foreground-focus [color: ('gray', 700)] - The combo toggle button foreground color when the combo is focused.
155155
/// @prop {Map} toggle-button-foreground-filled [color: ('gray', 700)] - The combo toggle button foreground color when the combo is focused.
156156
/// @prop {Map} toggle-button-background-disabled [color: ('gray', 100)] - The combo toggle button background color when the combo is disabled.
157157
/// @requires {Map} $light-combo
@@ -170,6 +170,12 @@ $fluent-combo: extend(
170170
100,
171171
),
172172
),
173+
toggle-button-foreground-focus: (
174+
color: (
175+
'gray',
176+
700,
177+
),
178+
),
173179
toggle-button-foreground-filled: (
174180
color: (
175181
'gray',
@@ -200,6 +206,7 @@ $fluent-combo: extend(
200206
/// Generates a bootstrap combo schema.
201207
/// @type {Map}
202208
/// @prop {Map} toggle-button-foreground [color: ('gray', 800)] - The combo toggle button foreground color.
209+
/// @prop {Map} toggle-button-foreground-focus [color: ('gray', 800)] - The combo toggle button foreground color when the combo is focused.
203210
/// @prop {Map} toggle-button-foreground-filled [color: ('gray', 800)] - The combo toggle button foreground color when the combo is focused.
204211
/// @prop {Map} empty-list-background [color: ('surface')] - The combo list background color.
205212
/// @prop {Map} search-separator-border-color [color: ('gray', 400)] - The combo search box separator color.

0 commit comments

Comments
 (0)