aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--doc/ref/javascript/components/tab_group_element.texi12
-rw-r--r--static/components/tab-group-element.ts4
2 files changed, 8 insertions, 8 deletions
diff --git a/doc/ref/javascript/components/tab_group_element.texi b/doc/ref/javascript/components/tab_group_element.texi
index 67f3a359..7e0b190a 100644
--- a/doc/ref/javascript/components/tab_group_element.texi
+++ b/doc/ref/javascript/components/tab_group_element.texi
@@ -14,12 +14,12 @@ it, and a tab-element, which contains the actual content. These two
should refer to each other as follows:
@example
-+---------------+ +----------------+
-| TabLabel | | Tab |
-+---------------+ +----------------+
-| id |<----| aria-labeledby |
-| aria-controls |---->| id |
-+---------------+ +----------------+
++---------------+ +-----------------+
+| TabLabel | | Tab |
++---------------+ +-----------------+
+| id |<----| aria-labelledby |
+| aria-controls |---->| id |
++---------------+ +-----------------+
@end example
Further information about tabs in HTML can be found here:
diff --git a/static/components/tab-group-element.ts b/static/components/tab-group-element.ts
index 8a65964d..1c58b0fb 100644
--- a/static/components/tab-group-element.ts
+++ b/static/components/tab-group-element.ts
@@ -113,7 +113,7 @@ class TabGroupElement extends ComponentVEvent {
role: 'tabpanel',
tabindex: 0,
hidden: 'hidden',
- 'aria-labeledby': label_id,
+ 'aria-labelledby': label_id,
})
tabContainer.replaceChildren(child);
@@ -129,7 +129,7 @@ class TabGroupElement extends ComponentVEvent {
}
removeTab(tab: HTMLElement) {
- let id = tab.getAttribute('aria-labeledby')!
+ let id = tab.getAttribute('aria-labelledby')!
let label = document.getElementById(id)
if (label) {
if (label.ariaSelected === 'true') {