Archived
Accessibility pass, WCAG 2.2 AA (1.50.0)
Public pages, auth, registration, payment, My Events and the kiosk: skip link, focus ring, labels tied to fields, named quantity buttons, announced errors, ModalOverlay popups (focus trap, Escape, focus return), contrast and underlined in-text links, reduced motion. Branding warns about a primary colour too light for white text and offers a darker shade. axe-core and keyboard checks in e2e/accessibility.spec.ts. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -68,8 +68,10 @@ export function RegisterForm() {
|
||||
return (
|
||||
<form onSubmit={onSubmit} className="space-y-4 max-w-sm w-full">
|
||||
<div>
|
||||
<label className="block text-sm font-medium mb-1">Full Name</label>
|
||||
<label htmlFor="signup-full-name" className="block text-sm font-medium mb-1">Full Name</label>
|
||||
<input
|
||||
id="signup-full-name"
|
||||
autoComplete="name"
|
||||
value={name}
|
||||
onChange={(e) => setName(e.target.value)}
|
||||
className="w-full border rounded px-3 py-2"
|
||||
@@ -78,8 +80,10 @@ export function RegisterForm() {
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<label className="block text-sm font-medium mb-1">Email</label>
|
||||
<label htmlFor="signup-email" className="block text-sm font-medium mb-1">Email</label>
|
||||
<input
|
||||
id="signup-email"
|
||||
autoComplete="email"
|
||||
type="email"
|
||||
value={email}
|
||||
onChange={(e) => setEmail(e.target.value)}
|
||||
@@ -89,8 +93,10 @@ export function RegisterForm() {
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<label className="block text-sm font-medium mb-1">Password</label>
|
||||
<label htmlFor="signup-password" className="block text-sm font-medium mb-1">Password</label>
|
||||
<input
|
||||
id="signup-password"
|
||||
autoComplete="new-password"
|
||||
type="password"
|
||||
value={password}
|
||||
onChange={(e) => setPassword(e.target.value)}
|
||||
@@ -100,8 +106,11 @@ export function RegisterForm() {
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<label className="block text-sm font-medium mb-1">Phone Number (optional)</label>
|
||||
<label htmlFor="signup-phone-number" className="block text-sm font-medium mb-1">Phone Number (optional)</label>
|
||||
<input
|
||||
id="signup-phone-number"
|
||||
type="tel"
|
||||
autoComplete="tel"
|
||||
value={phoneNumber}
|
||||
onChange={(e) => setPhoneNumber(e.target.value)}
|
||||
placeholder="e.g. 082 123 4567"
|
||||
@@ -111,8 +120,9 @@ export function RegisterForm() {
|
||||
|
||||
{hasValidPhone && (
|
||||
<div>
|
||||
<label className="block text-sm font-medium mb-1">Notification Preference</label>
|
||||
<label htmlFor="signup-notification-preference" className="block text-sm font-medium mb-1">Notification Preference</label>
|
||||
<select
|
||||
id="signup-notification-preference"
|
||||
value={notificationPreference}
|
||||
onChange={(e) => setNotificationPreference(e.target.value as "email" | "whatsapp" | "both")}
|
||||
className="w-full border rounded px-3 py-2"
|
||||
@@ -138,7 +148,7 @@ export function RegisterForm() {
|
||||
<Link
|
||||
href="/legal/terms"
|
||||
target="_blank"
|
||||
className="text-brand-600 hover:underline"
|
||||
className="text-brand-700 underline hover:no-underline"
|
||||
>
|
||||
Terms of Use
|
||||
</Link>{" "}
|
||||
@@ -146,7 +156,7 @@ export function RegisterForm() {
|
||||
<Link
|
||||
href="/legal/privacy"
|
||||
target="_blank"
|
||||
className="text-brand-600 hover:underline"
|
||||
className="text-brand-700 underline hover:no-underline"
|
||||
>
|
||||
Privacy Policy
|
||||
</Link>.
|
||||
@@ -175,7 +185,7 @@ export function RegisterForm() {
|
||||
</a>
|
||||
</div>
|
||||
|
||||
{error && <p className="text-sm text-red-600">{error}</p>}
|
||||
{error && <p role="alert" className="text-sm text-red-600">{error}</p>}
|
||||
|
||||
<button
|
||||
type="submit"
|
||||
|
||||
Reference in New Issue
Block a user