1
0
mirror of https://github.com/bitwarden/browser.git synced 2025-03-01 03:31:15 +01:00

focus toast after showing to ensure voiceover announcement

This commit is contained in:
jaasen-livefront 2025-02-28 17:18:43 -08:00
parent f12456bd3e
commit 583521b266
No known key found for this signature in database

View File

@ -34,6 +34,14 @@ export class ToastService {
};
this.toastrService.show(null, options.title, toastrConfig);
requestAnimationFrame(() => {
const toastElement = document.querySelector("#toast-container") as HTMLElement;
if (toastElement) {
toastElement.setAttribute("tabindex", "-1");
toastElement.focus();
}
});
}
/**