Fix issue/comment menus
Closes https://codeberg.org/forgejo/forgejo/issues/1120
- Adds labels to reaction and context menu.
- Fixes taborder in markdown combobox buttons. They are now only one
"tab" stop and can be navigated with arrow buttons and in the right
order (previously, it would skip the table button).
- Generates more verbose output for the reactio selectors to provide
content for users who cannot identify the meaning of these buttons
visually. Explicit aria-labels are now preferred over auto-generated
ones.
(cherry picked from commit c67d63d88a
)
This commit is contained in:
parent
8d353ad258
commit
3496c819da
7 changed files with 39 additions and 8 deletions
|
@ -103,7 +103,10 @@ function switchTitleToTooltip(target) {
|
|||
}
|
||||
}
|
||||
target.setAttribute('data-tooltip-content', title);
|
||||
target.setAttribute('aria-label', title);
|
||||
// only replace if not explicitly set
|
||||
if (target.getAttribute('aria-label') !== null) {
|
||||
target.setAttribute('aria-label', title);
|
||||
}
|
||||
// keep the attribute, in case there are some other "[title]" selectors
|
||||
// and to prevent infinite loop with <relative-time> which will re-add
|
||||
// title if it is absent
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue