fix: announce tab count and position in settings tab bar

This commit is contained in:
Matt Van Horn
2026-06-08 00:49:43 -07:00
parent 33e847c1a3
commit 9a2fc883b6
2 changed files with 127 additions and 1 deletions

View File

@@ -34,10 +34,12 @@ export function TabContainer<K extends Key>({
return (
<div className={styles.tabContainer}>
<NavBar role="tablist" aria-label={label} className={styles.tabList}>
{tabs.map(({ key, name }) => (
{tabs.map(({ key, name }, index) => (
<NavItem
key={key}
aria-controls={`${idPrefix}[${key}]`}
aria-posinset={index + 1}
aria-setsize={tabs.length}
onClick={() => onTabChange(key)}
active={key === tab}
>