Reorganize repo structure and standards references

This commit is contained in:
david committed 2026-06-29 05:03:42 +02:00
1 parent 3cb93a81be
commit be2054274d
5885 files changed
+2588 -195

No files matched your search

@@ -0,0 +1,33 @@
import "@testing-library/jest-dom";
import * as React from "react";
import { describe, it } from "vitest";
import { Button } from "./button";
import BackButtonWithTitle from "./buttons/BackButtonWithTitle";
import { expectNoAxeViolations } from "@toolctrl/ui-app/test-setup/axe";
/**
* Complementary to button.a11y.test.tsx (which uses the static helper at
* apps/web/app/utils/test/a11y.tsx). This file runs the full axe-core engine
* via @toolctrl/ui-app/test-setup/axe to catch issues the static heuristic
* can't (e.g. aria-disabled vs disabled, redundant roles).
*/
describe("Button axe-core a11y", () => {
it("text button has no axe violations", async () => {
await expectNoAxeViolations(<Button>Save changes</Button>);
});
it("icon-only button with aria-label has no axe violations", async () => {
await expectNoAxeViolations(
<Button aria-label="Close dialog" size="icon">
<svg viewBox="0 0 24 24" aria-hidden="true">
<path d="M6 6l12 12M6 18L18 6" />
</svg>
</Button>,
);
});
it("arrow-only back button has a translated accessible name", async () => {
await expectNoAxeViolations(<BackButtonWithTitle href="/settings">Settings</BackButtonWithTitle>);
});
});