From e3c5a7e35ded8d33c47250ac2e019517dceae63e Mon Sep 17 00:00:00 2001 From: Jim Rice Date: Mon, 31 Jan 2022 15:48:25 -0600 Subject: [PATCH] feat(card-cluster, tabs, table): better ARIA support (#305) - screen reader reads card cluster selection and optionally also the longform description - possible aria fix by adding optional param for tablist, which allows use of + + + + + diff --git a/src/app/modules/tabs/tabs.component.scss b/src/app/modules/tabs/tabs.component.scss index 4bec0a29..17e12445 100644 --- a/src/app/modules/tabs/tabs.component.scss +++ b/src/app/modules/tabs/tabs.component.scss @@ -1,4 +1,12 @@ +$tab-border-color: #d6d7d9; + .ds-c-tabs__item { color: #323A45; font-weight: normal; -} \ No newline at end of file + border-left: 1px solid $tab-border-color; + border-right: 0px; +} + +.ds-c-tabs__item:last-child { + border-right: 1px solid $tab-border-color +} diff --git a/src/app/modules/tabs/tabs.component.ts b/src/app/modules/tabs/tabs.component.ts index 85805bf6..17787364 100644 --- a/src/app/modules/tabs/tabs.component.ts +++ b/src/app/modules/tabs/tabs.component.ts @@ -16,10 +16,15 @@ export class AppTabsComponent implements OnInit { @Input() tabs: TabModel[]; @Input() defaultSelectedId: string; @Input() tablistClassName: string; + // Setting to true should let screen reader properly read when a tab is selected + @Input() tabsAsButtons?: boolean; @Output() onChange = new EventEmitter(); /* * ngOnInit is used to select a default tab when the component loads + * NOTE: We offer the option to use