Write the site in US English

color, center, canceled, labeled, recognize and the rest, in UI
text, help text, comments, docs and names (ColorInput, QrCenter).
Migration 053 renames the two Site settings color CHECKs, whose
names are the messages the admin shows. Kept: events.status's
stored value 'cancelled' (shown as canceled), aria-labelledby,
schema.org's EventCancelled, and old migrations as they ran.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Zaldimmar 2026-09-30 13:23:56 -05:00
parent 38aff34c97
commit 2ad65cdc15
60 changed files with 182 additions and 148 deletions

View file

@ -3,7 +3,7 @@
A QR code as an <svg>, sized by its container.
`centre` puts something on a badge over the middle: the NGU dove,
`center` puts something on a badge over the middle: the NGU dove,
or an image (an SVG from src/assets/qr, passed as a data: URL).
With anything there, the code switches to high error correction
so the modules under the badge are recovered when it's scanned
@ -17,7 +17,7 @@
doesn't, this just draws what it's given.
Everything is drawn in the SVG itself (no CSS, and an image is
embedded rather than linked), so the element serialises to a
embedded rather than linked), so the element serializes to a
file that looks the same outside the page. `ref` reaches the
<svg> for exactly that.
═══════════════════════════════════════════════════════════════ */
@ -42,11 +42,11 @@ const BADGE = 0.24
/* DoveMark's own viewBox is 72.87 × 48.57. */
const DOVE_ASPECT = 72.867699 / 48.568241
export type QrCentre = { kind: 'dove'; color?: string } | { kind: 'image'; src: string } | null
export type QrCenter = { kind: 'dove'; color?: string } | { kind: 'image'; src: string } | null
export default function QrCode({
value,
centre = null,
center = null,
ink = QR_INK,
paper = QR_PAPER,
label,
@ -54,7 +54,7 @@ export default function QrCode({
className,
}: {
value: string
centre?: QrCentre
center?: QrCenter
ink?: string
paper?: string
/** Accessible name for the image, e.g. "QR code for /retreats". */
@ -62,7 +62,7 @@ export default function QrCode({
ref?: Ref<SVGSVGElement>
className?: string
}) {
const level = centre ? 'H' : 'M'
const level = center ? 'H' : 'M'
const matrix = useMemo(() => qrMatrix(value, level), [value, level])
const path = useMemo(() => qrPath(matrix, MARGIN), [matrix])
@ -86,7 +86,7 @@ export default function QrCode({
<rect width={total} height={total} fill={paper} />
<path d={path} fill={ink} />
{centre && (
{center && (
<g shapeRendering="auto">
<rect
x={badgeAt}
@ -98,17 +98,17 @@ export default function QrCode({
stroke={ink}
strokeWidth={0.35}
/>
{centre.kind === 'dove' ? (
{center.kind === 'dove' ? (
<DoveMark
x={(total - doveWidth) / 2}
y={(total - doveHeight) / 2}
width={doveWidth}
height={doveHeight}
style={{ color: centre.color ?? QR_DOVE }}
style={{ color: center.color ?? QR_DOVE }}
/>
) : (
<image
href={centre.src}
href={center.src}
x={(total - imageSize) / 2}
y={(total - imageSize) / 2}
width={imageSize}