Skip to content

Commit 1cd1833

Browse files
authored
FIX Issue 4082: ComboBox wrong border and background colors for dropdown button with forced-colors: active (#4453)
* Disabled combobox HCM button border color fix
1 parent 2d434db commit 1cd1833

File tree

1 file changed

+38
-15
lines changed
  • packages/@adobe/spectrum-css-temp/components/inputgroup

1 file changed

+38
-15
lines changed

packages/@adobe/spectrum-css-temp/components/inputgroup/skin.css

Lines changed: 38 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,9 @@ governing permissions and limitations under the License.
2626
}
2727

2828
.spectrum-FieldButton {
29-
border-color: var(--spectrum-textfield-border-color-key-focus);
29+
&:before {
30+
border-color: var(--spectrum-textfield-border-color-key-focus);
31+
}
3032
}
3133
}
3234
}
@@ -116,7 +118,9 @@ governing permissions and limitations under the License.
116118
&:active,
117119
&.is-selected,
118120
&.spectrum-FieldButton--invalid {
119-
border-color: var(--spectrum-textfield-quiet-border-color);
121+
&:before {
122+
border-color: var(--spectrum-textfield-quiet-border-color);
123+
}
120124
}
121125

122126
&:disabled,
@@ -127,7 +131,9 @@ governing permissions and limitations under the License.
127131

128132
&:hover:not(.spectrum-InputGroup--invalid):not(.is-focused):not(.is-disabled) {
129133
.spectrum-FieldButton {
130-
border-color: var(--spectrum-textfield-quiet-border-color-hover);
134+
&:before {
135+
border-color: var(--spectrum-textfield-quiet-border-color-hover);
136+
}
131137
}
132138
}
133139

@@ -139,14 +145,14 @@ governing permissions and limitations under the License.
139145
}
140146

141147
&:hover {
142-
.spectrum-FieldButton,
148+
.spectrum-FieldButton:before,
143149
.spectrum-InputGroup-input {
144150
border-color: var(--spectrum-textfield-border-color-error-hover);
145151
}
146152
}
147153

148154
&:active {
149-
.spectrum-FieldButton,
155+
.spectrum-FieldButton:before,
150156
.spectrum-InputGroup-input {
151157
border-color: var(--spectrum-textfield-border-color-error-down);
152158
}
@@ -202,12 +208,16 @@ governing permissions and limitations under the License.
202208
/* Focus ring: When one of the inputs or the button has keyboard focus, render the focus ring border around the entire input group by styling an adjacent descendant element. */
203209
&:focus-ring {
204210
.spectrum-FieldButton {
205-
border-color: var(--spectrum-dropdown-border-color-key-focus);
211+
&:before {
212+
border-color: var(--spectrum-dropdown-border-color-key-focus);
213+
}
206214
box-shadow: 0 0 0 1px var(--spectrum-dropdown-border-color-key-focus);
207215
}
208216
}
209217
.spectrum-FieldButton {
210-
border-color: var(--spectrum-dropdown-border-color-error);
218+
&:before {
219+
border-color: var(--spectrum-dropdown-border-color-error);
220+
}
211221
&.spectrum-FieldButton--invalid {
212222
&:focus-ring {
213223
border-color: var(--spectrum-dropdown-border-color-key-focus);
@@ -223,7 +233,9 @@ governing permissions and limitations under the License.
223233
&.spectrum-InputGroup--invalid {
224234
.spectrum-FieldButton {
225235
box-shadow: none;
226-
border-color: var(--spectrum-dropdown-border-color-key-focus);
236+
&:before {
237+
border-color: var(--spectrum-dropdown-border-color-key-focus);
238+
}
227239
&.spectrum-FieldButton--invalid {
228240
&:focus-ring {
229241
box-shadow: 0 2px 0 0 var(--spectrum-dropdown-border-color-key-focus);
@@ -258,8 +270,9 @@ governing permissions and limitations under the License.
258270
}
259271

260272
&.is-disabled:not(.spectrum-InputGroup--invalid):not(.spectrum-InputGroup--quiet) .spectrum-FieldButton {
261-
border-color: GrayText;
262-
border-width: 1px;
273+
&:before {
274+
border-color: GrayText;
275+
}
263276
}
264277
}
265278

@@ -272,19 +285,25 @@ governing permissions and limitations under the License.
272285
.spectrum-FieldButton {
273286
&:disabled,
274287
&:disabled:hover {
275-
border-color: var(--spectrum-textfield-quiet-border-color);
288+
&:before {
289+
border-color: var(--spectrum-textfield-quiet-border-color);
290+
}
276291
}
277292
}
278293
}
279294
&.is-disabled {
280295
.spectrum-FieldButton {
281-
border-color: GrayText;
296+
&:before {
297+
border-color: GrayText;
298+
}
282299
}
283300
}
284301
}
285302
.spectrum-InputGroup--invalid {
286303
.spectrum-FieldButton {
287-
border-color: Highlight;
304+
&:before {
305+
border-color: Highlight;
306+
}
288307
}
289308
&.is-disabled:not(.spectrum-InputGroup--quiet) .spectrum-InputGroup-input {
290309
border-color: GrayText;
@@ -294,11 +313,15 @@ governing permissions and limitations under the License.
294313
border-color: GrayText;
295314
}
296315
&.spectrum-InputGroup--quiet .spectrum-FieldButton {
297-
border-color: GrayText;
316+
&:before {
317+
border-color: GrayText;
318+
}
298319
}
299320
}
300321
&.is-disabled:not(.spectrum-InputGroup--quiet) .spectrum-FieldButton {
301-
border-color: GrayText;
322+
&:before {
323+
border-color: GrayText;
324+
}
302325
}
303326
}
304327

0 commit comments

Comments
 (0)