Skip to content

Commit 6681986

Browse files
committed
Slack: Make options for each message (Start a thread, Share message, etc.) accessible.
To access these, move the mouse to the text of a message. They then appear above the author's name as buttons.
1 parent a0fdb18 commit 6681986

File tree

2 files changed

+9
-0
lines changed

2 files changed

+9
-0
lines changed

SlackA11yFixes.user.js

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,12 @@ function message(text) {
3939
}
4040

4141
function onNodeAdded(target) {
42+
if (target.classList.contains("ts_icon")) {
43+
// Icon with tooltip such as the options which appear when you mouse over a message.
44+
target.setAttribute("role", "button");
45+
target.setAttribute("aria-label", target.getAttribute("title"));
46+
return;
47+
}
4248
if (target.matches(".offscreen[contenteditable]")) {
4349
// Hidden contentEditable near the bottom which doesn't seem to be relevant to the user.
4450
target.setAttribute("role", "presentation");

readme.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,9 @@ It does the following:
6868
- Makes messages accessible as list items.
6969
- Makes message timestamps appear on a single line instead of crossing several lines.
7070
- Makes star controls (and their statuses) accessible.
71+
- Makes options for each message (Start a thread, Share message, etc.) accessible.
72+
To access these, move the mouse to the text of a message.
73+
They then appear above the author's name as buttons.
7174
- Makes the close link for the about channel pane accessible.
7275
- Makes day separators in the message history and the about channel pane heading accessible as headings.
7376
- Reports incoming messages automatically (using a live region).

0 commit comments

Comments
 (0)