+ {mode === 'default' &&
{[...tabs.map(tab => (
)),
]}
}
@@ -101,11 +125,13 @@ export const TabbedPaneTab: React.FunctionComponent<{
selected?: boolean,
onSelect?: (id: string) => void,
ariaControls?: string,
-}> = ({ id, title, count, errorCount, selected, onSelect, ariaControls }) => {
+ tabIndex?: number,
+}> = ({ id, title, count, errorCount, selected, onSelect, ariaControls, tabIndex }) => {
return
onSelect?.(id)}
role='tab'
title={title}
+ tabIndex={tabIndex ?? (selected ? 0 : -1)}
aria-controls={ariaControls}
aria-selected={selected}>
{title}