mirror of
https://github.com/go-gitea/gitea
synced 2024-12-26 13:44:33 +01:00
Add aria attributes to interactive time tooltips. (#23661)
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.
This commit is contained in:
parent
d02e83a2c3
commit
87f0f7e670
1 changed files with 1 additions and 1 deletions
|
@ -44,7 +44,7 @@ function attachTooltip(target, content = null) {
|
||||||
delay: 100,
|
delay: 100,
|
||||||
role: 'tooltip',
|
role: 'tooltip',
|
||||||
placement: target.getAttribute('data-tooltip-placement') || 'top-start',
|
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) {
|
if (!target._tippy) {
|
||||||
|
|
Loading…
Reference in a new issue