Accessibility: reading and color blind modes, audit fixes, calendar window

- Accessibility panel: the switch knob stays in its track; the panel
  follows its button in the Tab order and opens on its first switch.
- Reading mode is the page as plain text: one column, no colors,
  pictures, cards or motion; descriptions stay in place.
- Color blind mode (protanopia, deuteranopia, tritanopia, monochrome):
  palette swaps chosen by simulation, applied to code, data and CSS
  colors on public pages only. The newsletter uses the stored palette.
- Audit fixes: focus not hidden by the header, focus on page change
  and in-page jumps, focus return for the menu, day list and people
  details, labelled admin fields and dialogs, keyboard map tiles,
  scrollable tables, and more.
- Calendar asks /events for its six weeks only (?from=&to=); carousels
  take their 12 most recent past events (?past=12).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Zaldimmar 2026-10-02 14:33:09 -05:00
parent d067c02d33
commit b816203c0c
45 changed files with 760 additions and 208 deletions

View file

@ -22,6 +22,7 @@ import { PAGE_LINKS } from "../../navConfig.ts";
import { useNavSections, type NavSection } from "../../lib/navSections.ts";
import { DATA_REQUEST, FEEDBACK_TYPES } from "../../data/feedbackTypes.ts";
import { accentText, BRAND } from '../../lib/color.ts'
import { focusOnMount } from '../../lib/focus.ts'
const MUTED = "var(--color-muted)";
const MAX_CHARS = 1500;
@ -112,6 +113,7 @@ export function TilePicker({
options,
value,
onChange,
error,
}: {
legend: string;
blurb: string;
@ -119,9 +121,12 @@ export function TilePicker({
options: { id: string; label: string; hint: string }[];
value: string | null;
onChange: (id: string) => void;
/** Shown under the tiles and read with each one. */
error?: string;
}) {
const errorId = `${name}-error`;
return (
<fieldset>
<fieldset aria-describedby={error ? errorId : undefined}>
<legend className="text-base font-semibold text-body">{legend}</legend>
<p className="mt-1 text-sm" style={{ color: MUTED }}>
{blurb}
@ -138,6 +143,8 @@ export function TilePicker({
value={type.id}
checked={selected}
onChange={() => onChange(type.id)}
aria-invalid={Boolean(error)}
aria-describedby={error ? errorId : undefined}
className="peer sr-only"
/>
<span
@ -169,6 +176,7 @@ export function TilePicker({
);
})}
</div>
<FieldError id={errorId}>{error}</FieldError>
</fieldset>
);
}
@ -318,7 +326,12 @@ export default function FeedbackForm({ fixedType }: { fixedType?: string } = {})
aria-live="polite"
className="border border-brand/20 bg-surface p-8 sm:p-10"
>
<h3 className="text-2xl font-bold" style={{ color: accentText(BRAND) }}>
<h3
ref={focusOnMount}
tabIndex={-1}
className="text-2xl font-bold outline-none"
style={{ color: accentText(BRAND) }}
>
Thanks, we've got it
</h3>
{where && (