You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It's possible to set an aria-label (or use aria-labelledby) on an HTML select option, but that doesn't not appear to be possible for an option in react-select. I've tried replacing the Option component as well as using the formatOptionLabel prop, but neither work. In fact, if I manually set an aria-label on all option nodes, the label is never announced by a screen reader.
An example use-case is if I want a label to visually appear as "= (Equals)" or "- (Subtract)", but want to set an aria-label so a screen reader won't read out "equals equals" or "minus subtract" respectively.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
It's possible to set an
aria-label
(or usearia-labelledby
) on an HTML select option, but that doesn't not appear to be possible for an option in react-select. I've tried replacing theOption
component as well as using theformatOptionLabel
prop, but neither work. In fact, if I manually set anaria-label
on all option nodes, the label is never announced by a screen reader.An example use-case is if I want a label to visually appear as "= (Equals)" or "- (Subtract)", but want to set an
aria-label
so a screen reader won't read out "equals equals" or "minus subtract" respectively.Beta Was this translation helpful? Give feedback.
All reactions