fix(web): make the check chip's word reachable

This commit is contained in:
Miguel Palhas
2026-08-25 18:32:02 +01:00
parent e446da5858
commit c9e44b9c03
2 changed files with 9 additions and 7 deletions
+3
View File
@@ -757,6 +757,9 @@ function mediaStateChip(state: string, wanted: boolean): HTMLSpanElement {
if (state === "available") {
return chip("", (span) => {
span.replaceChildren(icon("check"));
// a bare span's aria-label is not reliably exposed; role="img" is what
// makes the word reachable once the glyph replaced it
span.setAttribute("role", "img");
span.setAttribute("aria-label", state);
span.dataset.movieState = state;
span.dataset.wanted = String(wanted);