Skip to content

Commit b0a79ab

Browse files
fix(components): update number input styles for focus and hover (#10043)
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
1 parent d9445e1 commit b0a79ab

1 file changed

Lines changed: 6 additions & 2 deletions

File tree

packages/components/src/components/number-input/_number-input.scss

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -371,9 +371,13 @@
371371
background-color: transparent;
372372
}
373373

374+
// We include `:not(:focus)` here because the pseudo elements will overlap the
375+
// focus outline on the button if we set their background-color on focus
374376
.#{$prefix}--number--light .#{$prefix}--number__control-btn:hover,
375-
.#{$prefix}--number--light .#{$prefix}--number__control-btn:hover::before,
376-
.#{$prefix}--number--light .#{$prefix}--number__control-btn:hover::after {
377+
.#{$prefix}--number--light
378+
.#{$prefix}--number__control-btn:not(:focus):hover::before,
379+
.#{$prefix}--number--light
380+
.#{$prefix}--number__control-btn:not(:focus):hover::after {
377381
background-color: $hover-light-ui;
378382
}
379383

0 commit comments

Comments
 (0)