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
{{ message }}
Repository navigation
[Bug] Children with aria role="tab" cause parent tabs to reset #345
I was trying to use rc-collapse which is an accessible collapse component, when you have the accordion mode enabled then it correctly sets the components to have the aria-roles to tablist/tab/tabpanel unfortunately this causes the react-tabs component to think that clicks to open the accordion are a trigger for the tabs.
We were having the exact same issue. Our accordion component when used within tabs would break as this package assumed all role="tab*" attributes were for it.
A surprisingly small fix we were able to make was to add a data-tabs attribute to our Accordion component to make use of this functionality:
Activity
lauriejones commentedon Nov 19, 2020
We were having the exact same issue. Our accordion component when used within tabs would break as this package assumed all
role="tab*"attributes were for it.A surprisingly small fix we were able to make was to add a
data-tabsattribute to our Accordion component to make use of this functionality:react-tabs/src/components/UncontrolledTabs.js
Lines 318 to 339 in a37ca85
SaayanBiswas98 commentedon May 25, 2023
SaayanBiswas98 commentedon May 25, 2023
this will not reset the tabs