Skip to content

Commit

Permalink
fix(VSlider): add missing aria-label (#19887)
Browse files Browse the repository at this point in the history
Co-authored-by: John Leider <john@vuetifyjs.com>
  • Loading branch information
tilenpirih and johnleider authored May 24, 2024
1 parent c3b2d29 commit e46a98d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions packages/vuetify/src/components/VSlider/VSlider.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -168,6 +168,7 @@ export const VSlider = genericComponent<VSliderSlots>()({
onFocus={ focus }
onBlur={ blur }
ripple={ props.ripple }
name={ props.name }
>
{{ 'thumb-label': slots['thumb-label'] }}
</VSliderThumb>
Expand Down
2 changes: 2 additions & 0 deletions packages/vuetify/src/components/VSlider/VSliderThumb.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ export const makeVSliderThumbProps = propsFactory({
type: [Boolean, Object] as PropType<RippleDirectiveBinding['value']>,
default: true,
},
name: String,

...makeComponentProps(),
}, 'VSliderThumb')
Expand Down Expand Up @@ -152,6 +153,7 @@ export const VSliderThumb = genericComponent<VSliderThumbSlots>()({
]}
role="slider"
tabindex={ disabled.value ? -1 : 0 }
aria-label={ props.name }
aria-valuemin={ props.min }
aria-valuemax={ props.max }
aria-valuenow={ props.modelValue }
Expand Down

0 comments on commit e46a98d

Please sign in to comment.