Skip to content

Commit 2c66a87

Browse files
authored
fix(slider): adjust label width (#3444)
1 parent 1b3c5b1 commit 2c66a87

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

.changeset/itchy-poets-battle.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@spectrum-css/slider": patch
3+
---
4+
5+
fix(slider): Limit the slider label width to its intrinsic size instead of taking up full-width to prevent accidental activation on mobile.

components/slider/index.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -404,6 +404,7 @@
404404
.spectrum-Slider-labelContainer {
405405
display: flex;
406406
align-items: center;
407+
justify-content: space-between;
407408
position: relative;
408409
inline-size: auto;
409410

@@ -423,7 +424,6 @@
423424

424425
.spectrum-Slider-label {
425426
padding-inline-start: 0;
426-
flex-grow: 1;
427427
font-size: var(--mod-slider-font-size, var(--spectrum-slider-font-size));
428428
}
429429

0 commit comments

Comments
 (0)