Skip to content

Commit

Permalink
conditional added to aria-valuetext
Browse files Browse the repository at this point in the history
  • Loading branch information
joe-allen-89 committed Jul 12, 2024
1 parent 11ea8af commit 96809de
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion templates/slider.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ export default function Slider (props) {
<input className='slider__item-input js-slider-item-input'
type='range'
aria-label={ariaScaleName}
aria-valuetext={`${scaleStepPrefix} ${selectedValue} ${scaleStepSuffix}`}
aria-valuetext={(scaleStepPrefix || scaleStepSuffix) && `${scaleStepPrefix} ${selectedValue} ${scaleStepSuffix}`}
value={selectedValue}
min={_scaleStart}
max={_scaleEnd}
Expand Down

0 comments on commit 96809de

Please sign in to comment.