.DayPicker-wrapper tabIndex and aria-label
#1133
Replies: 4 comments
-
|
To make this calendar more accessible I think you need to add ARIA-* props to the wrapper because as a developer I need to control all these features. |
Beta Was this translation helpful? Give feedback.
-
|
Well, it varies from case to case. |
Beta Was this translation helpful? Give feedback.
-
|
Seconding this as well, we have this daypicker in a modal and it requires 2 tabs to get to the first interactable element instead of one, i don't see why the wrapper would need a tabIndex? |
Beta Was this translation helpful? Give feedback.
-
|
@gpbl and team It will be of great help if we can prioritise this one as this is raising accessibility concerns. Agree with @aitchkhan @Dervisevic |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
By default the "wrapper" div is focusable via Tab because it has
tabIndex = 0.And also the first day of the month is focusable due to it also having
tabIndex = 0.If
tabIndex = -1property is passed then neither the wrapper is focusable via Tab nor the first day of the month is, because both of them gettabIndex = -1.A finer level of granularity would be more appropriate.
For example, having two separate properties for "tab index".
Or maybe, better having
tabIndex = 0on the first day of the month always because otherwise keyboard-only users would be unable to choose a date.One more thing is that the
wrapperdiv doesn't have anyaria-labelproperty.So if it has
tabIndex = 0and is focused then the narrator is silent and the user will be confused in such case and won't know where the focus is.An
aria-labelconsisting of active month and year would be appropriate.Also, there's no
tabIndexsetting for prev/next month buttons.You might add a separate property for that.
Beta Was this translation helpful? Give feedback.
All reactions