Commit 0475eec
Uniquely label Reason/Follow-up toggles for screen readers
Every question row in Institution / Privacy analyst views has its
own "+ Reason / Follow-up" button, and until now they all shared
identical accessible names — a WCAG-failing "ambiguous link/button
purpose" for screen-reader users trying to orient among dozens of
identical toggles.
Fix by giving each question row's .qmeta div an id (e.g.
"aqmeta-inst-eval-AAAI-01") and wrapping the button's own text in
a span with its own id, then setting aria-labelledby on the button
to reference both. The browser concatenates the two, so AT now
announces something like "Plus Reason / Follow-up, AAAI-01 Critical,
button, collapsed" — unambiguous per question.
The click handler still updates the span's textContent to toggle
the + / − prefix; aria-labelledby picks up the new string on the
next read.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>1 parent 8346395 commit 0475eec
1 file changed
Lines changed: 19 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2145 | 2145 | | |
2146 | 2146 | | |
2147 | 2147 | | |
2148 | | - | |
| 2148 | + | |
| 2149 | + | |
| 2150 | + | |
| 2151 | + | |
| 2152 | + | |
| 2153 | + | |
| 2154 | + | |
2149 | 2155 | | |
2150 | 2156 | | |
2151 | 2157 | | |
| |||
2163 | 2169 | | |
2164 | 2170 | | |
2165 | 2171 | | |
2166 | | - | |
| 2172 | + | |
| 2173 | + | |
| 2174 | + | |
| 2175 | + | |
| 2176 | + | |
| 2177 | + | |
| 2178 | + | |
| 2179 | + | |
| 2180 | + | |
| 2181 | + | |
| 2182 | + | |
| 2183 | + | |
2167 | 2184 | | |
2168 | 2185 | | |
2169 | 2186 | | |
| |||
0 commit comments