Accessibility
This page aligns with the MkDocs POC accessibility page, adapted for this Roq layout (navbar, sidebar, TOC, Prism).
Configuration
Layout
- Keyboard navigation — Focusable nav links, sidebar, and copy buttons (with
aria-labelon copy). - Semantic structure — One main heading per page; Markdown renders as paragraphs, lists, and tables.
- Table of contents — Right-hand TOC links to in-page headings (
h2–h4); supports keyboard activation after click (smooth scroll).
Color and contrast
The custom CSS uses a green primary palette and dark code blocks (Prism tomorrow). For stricter WCAG tuning, adjust variables in public/css/layout.css and public/css/docusaurus-style.css.
MkDocs Material offers a built-in light/dark toggle; this POC uses a single scheme. You can add a theme toggle via extra CSS/JS if needed.
Best practices
- Heading hierarchy — Use H1 once per page (title), then H2 → H3; do not skip levels.
- Link text — Prefer descriptive text, e.g. Getting Started guide instead of “click here”.
- Images — Provide
alttext for meaningful images in Markdown or templates. - Tables — Use header rows for data tables.
- Code blocks — Use language tags (
java,yaml,bash) for highlighting and context.
Linkable headers
Anchor IDs are generated for headings. Examples:
Responsive design
- Desktop — Sidebar, main column, and TOC column.
- Tablet / narrow — TOC hidden; sidebar remains or toggles via menu button on small screens.
- Mobile — Sidebar can be toggled; touch-friendly tap targets on nav.