-
-
Notifications
You must be signed in to change notification settings - Fork 32.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Tabs] Initial migration of component #5604
Conversation
@oliviertassinari @newoga thanks for taking this massive component on! This is looking really awesome. I have some initial feedback though regarding accessibility. 1. There needs to be properties for the relevant roles: <div role="tablist">
<button role="tab">tab 1</button>
<button role="tab">tab 2</button>
</div> 2. The tabs should have <div role="tablist">
<button role="tab" tabindex="0" aria-selected="true">tab 1</button>
<button role="tab" tabindex="-1" aria-selected="false">tab 2</button>
</div> 3. A tablist widget needs to implement specific keyboard navigation techniques:
You can see an example of similar functionality in these components (including resetting the (not 💯 perfect yet. specifically, have a couple of SR issues to address on the demos but the keyboard accessibility + focus management is there). BTW I'm more than happy to help implement this. Also, I'm wondering if now is time to abstract some of this functionality away from these components? There are some small differences in how they need to behave so the abstraction would definitely take a bit of thinking. Let me know if you want to discuss this abstraction or if you think we should just add the functionality to the component. You can see a real world example of all of these accessibility features here: |
@nathanmarks Thanks for the feedback regarding accessibility.
We would also need to address this issue at the BottomNavigation level. We have 4 components with a similar needs. I'm gonna look at how we could share some logic. I believe react-bootstrap is handling correctly this aspect. |
I have updated #4795. I'm gonna merge this PR, the migration isn't finished yet. |
@oliviertassinari Before we jump head first into the logic sharing, I want to make sure that we're handling the slightly different use cases properly. |
@newoga That was more challenging than I though. Your initial work was quite useful!
Close #5097.
Close #5534.
Close #5391.
Close #5370.
Close #5094.
Close #4528.
Close #4420.