fix(ui): reconcile shared accessibility and read recovery

This commit is contained in:
cesnimda
2026-10-20 20:26:48 +02:00
parent bba52af4b8
commit d8c0187305
25 changed files with 802 additions and 25 deletions
@@ -44,7 +44,8 @@ test("notification bell exposes its unread count and keyboard-accessible action"
expect(open.mock.calls[0][0]).toBeInstanceOf(HTMLElement);
});
test("shows build metadata only when the caller supplies the admin-only badge", () => {
test.each([["en", "Application version 2.4.1, commit abc1234"], ["nb", "Applikasjonsversjon 2.4.1, revisjon abc1234"]])("shows localized %s build metadata only when the caller supplies the admin-only badge", (language, label) => {
localStorage.setItem("uiLanguage", language);
const commonProps = {
pageTitle: "Dashboard",
breadcrumbs: ["Home"],
@@ -67,7 +68,8 @@ test("shows build metadata only when the caller supplies the admin-only badge",
);
expect(screen.getByTestId("admin-version-badge")).toHaveTextContent("v2.4.1");
expect(screen.getByLabelText("Application version 2.4.1, commit abc1234")).toBeInTheDocument();
expect(screen.getByLabelText(label)).toBeInTheDocument();
expect(screen.getByRole("img", { name: label })).toBe(screen.getByTestId("admin-version-badge"));
rerender(
<CssVarsProvider theme={getTheme("light") as any} defaultMode="light">