diff options
| author | Moritz Strohm <strohm@data-quest.de> | 2024-05-28 15:22:18 +0000 |
|---|---|---|
| committer | Moritz Strohm <strohm@data-quest.de> | 2024-05-28 15:22:18 +0000 |
| commit | 062a7f9a03ae39ed083f42d89681318fb0cd6321 (patch) | |
| tree | 5b34b8475474a87862dc26e6d65a1adddd4679e5 /templates/shared/tooltip.php | |
| parent | d28f3aff4a6cf4e55e070015106948b720076bef (diff) | |
fixed screen reader output for tooltips, fixes #3962issue-4224-2issue-4224
Closes #3962
Merge request studip/studip!2859
Diffstat (limited to 'templates/shared/tooltip.php')
| -rw-r--r-- | templates/shared/tooltip.php | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/templates/shared/tooltip.php b/templates/shared/tooltip.php index a97c73f..8dbcd38 100644 --- a/templates/shared/tooltip.php +++ b/templates/shared/tooltip.php @@ -1,5 +1,4 @@ -<span class="tooltip tooltip-icon <? if ($important) echo 'tooltip-important'; ?>" data-tooltip <? if (!$html) printf('title="%s"', htmlReady($text)) ?> tabindex="0"> -<? if ($html): ?> - <span class="tooltip-content"><?= $text ?></span> -<? endif; ?> +<span class="tooltip tooltip-icon <? if ($important) echo 'tooltip-important'; ?>" + tabindex="0" aria-label="<?= $html ? kill_format($text) : htmlReady($text) ?>"> + <span class="tooltip-content"><?= $html ? $text : htmlReady($text) ?></span> </span> |
