From b13da2bc4bbc3e802532f5b1f104aec07b36f157 Mon Sep 17 00:00:00 2001 From: Petra Kubesova <133044666+kubeska@users.noreply.github.com> Date: Tue, 11 Aug 2026 10:00:57 +0200 Subject: [PATCH 01/12] fix(bits): NUI-6283 - link tabs and tab panels with ARIA IDs --- docs/CHANGELOG.md | 4 +++ .../repeat-test/repeat-test.component.html | 14 ++++++++-- ...ading-group-dynamic.example.component.html | 8 +++++- ...-group-with-content.example.component.html | 8 +++++- .../bits/src/constants/tabgroup.constants.ts | 22 +++++++++++++++ .../tab-group/tab-group.component.html | 2 +- .../tab-heading/tab-heading.component.html | 3 ++- .../tab-heading/tab-heading.component.ts | 27 +++++++++++++++++-- .../src/lib/tabgroup/tab/tab.component.ts | 21 +++++++++++---- 9 files changed, 96 insertions(+), 13 deletions(-) create mode 100644 packages/bits/src/constants/tabgroup.constants.ts diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index 53543de7c..7eafbda22 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -1,5 +1,9 @@ # Changelog +## [Unreleased] +### Fixes +- `@nova-ui/bits` | Align tab and tab-panel IDs with the accessible `tab-{id}` / `panel-{id}` relationship. + ## [20.0.9] 📅 2026-08-05 ### Fixes - Essentional A11y fixies diff --git a/packages/bits/demo/src/components/demo/repeat/repeat-test/repeat-test.component.html b/packages/bits/demo/src/components/demo/repeat/repeat-test/repeat-test.component.html index 8679d44de..c453c8c88 100644 --- a/packages/bits/demo/src/components/demo/repeat/repeat-test/repeat-test.component.html +++ b/packages/bits/demo/src/components/demo/repeat/repeat-test/repeat-test.component.html @@ -9,10 +9,20 @@ >{{ tab.title }} -
+
No content in this tab. See other tab(s) for content.
-
+

diff --git a/packages/bits/demo/src/components/demo/tabgroup/tab-heading-group-dynamic/tab-heading-group-dynamic.example.component.html b/packages/bits/demo/src/components/demo/tabgroup/tab-heading-group-dynamic/tab-heading-group-dynamic.example.component.html index fd7fd52e6..90046e9cf 100644 --- a/packages/bits/demo/src/components/demo/tabgroup/tab-heading-group-dynamic/tab-heading-group-dynamic.example.component.html +++ b/packages/bits/demo/src/components/demo/tabgroup/tab-heading-group-dynamic/tab-heading-group-dynamic.example.component.html @@ -15,7 +15,13 @@ -
+

Tab titeled {{ tab.title }} with id diff --git a/packages/bits/demo/src/components/demo/tabgroup/tab-heading-group-with-content/tab-heading-group-with-content.example.component.html b/packages/bits/demo/src/components/demo/tabgroup/tab-heading-group-with-content/tab-heading-group-with-content.example.component.html index a763273f5..15dfdbc05 100644 --- a/packages/bits/demo/src/components/demo/tabgroup/tab-heading-group-with-content/tab-heading-group-with-content.example.component.html +++ b/packages/bits/demo/src/components/demo/tabgroup/tab-heading-group-with-content/tab-heading-group-with-content.example.component.html @@ -27,7 +27,13 @@ -

+

Tab titeled {{ tab.title }} with id diff --git a/packages/bits/src/constants/tabgroup.constants.ts b/packages/bits/src/constants/tabgroup.constants.ts new file mode 100644 index 000000000..27ae11b7a --- /dev/null +++ b/packages/bits/src/constants/tabgroup.constants.ts @@ -0,0 +1,22 @@ +// © 2026 SolarWinds Worldwide, LLC. All rights reserved. +// +// Permission is hereby granted, free of charge, to any person obtaining a copy +// of this software and associated documentation files (the "Software"), to +// deal in the Software without restriction, including without limitation the +// rights to use, copy, modify, merge, publish, distribute, sublicense, and/or +// sell copies of the Software, and to permit persons to whom the Software is +// furnished to do so, subject to the following conditions: +// +// The above copyright notice and this permission notice shall be included in +// all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +// THE SOFTWARE. + +export const TAB_ID_PREFIX = "tab-"; +export const TAB_PANEL_ID_PREFIX = "panel-"; diff --git a/packages/bits/src/lib/tabgroup/tab-group/tab-group.component.html b/packages/bits/src/lib/tabgroup/tab-group/tab-group.component.html index 488f2acf1..a09363639 100644 --- a/packages/bits/src/lib/tabgroup/tab-group/tab-group.component.html +++ b/packages/bits/src/lib/tabgroup/tab-group/tab-group.component.html @@ -32,7 +32,7 @@