Skip to content

Commit

Permalink
Add aria attributes to interactive time tooltips. (#23661)
Browse files Browse the repository at this point in the history
Fixes #23645
* Added `describedby` attribute to the reference element.
* Eliminated `aria-expanded` attribute to the reference element in order
to conform strictly with WCAG 2.1 rules.
  • Loading branch information
fsologureng authored Mar 24, 2023
1 parent d02e83a commit 87f0f7e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion web_src/js/modules/tippy.js
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ function attachTooltip(target, content = null) {
delay: 100,
role: 'tooltip',
placement: target.getAttribute('data-tooltip-placement') || 'top-start',
...(target.getAttribute('data-tooltip-interactive') === 'true' ? {interactive: true} : {}),
...(target.getAttribute('data-tooltip-interactive') === 'true' ? {interactive: true, aria: {content: 'describedby', expanded: false}} : {}),
};

if (!target._tippy) {
Expand Down

0 comments on commit 87f0f7e

Please sign in to comment.