POPIA toolkit part 1: privacy page, unsubscribe, WhatsApp STOP, data requests
- Privacy page: news opt-in per channel with history, download my data (JSON + PDF), correction and deletion requests - Bulk messages are an Event update or News & announcements; news only reaches people who opted in, with unsubscribe links, one-click List-Unsubscribe headers and "Reply STOP" on WhatsApp - WhatsApp STOP via WAWP's message webhook, checked against a secret in the webhook URL - Sign-up opt-in box; existing accounts kept opted in and asked once - Admin -> Data requests with 30-day due dates and a daily reminder job - Deleting an account is a request; anonymising now covers attendees, form answers, consent details, payer details in provider payloads, etc. - Unit tests (privacy.test.js) and e2e (privacy.spec.ts); docs Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_012mt6TCv85T9VKRq3cV7rXq
This commit is contained in:
@@ -19,6 +19,8 @@ export function RegisterForm() {
|
||||
const [phoneNumber, setPhoneNumber] = useState("");
|
||||
const [notificationPreference, setNotificationPreference] = useState<"email" | "whatsapp" | "both">("email");
|
||||
const [accepted, setAccepted] = useState(false);
|
||||
// POPIA: marketing needs an opt-in, so this starts unticked.
|
||||
const [newsOptIn, setNewsOptIn] = useState(false);
|
||||
const [loading, setLoading] = useState(false);
|
||||
const [error, setError] = useState<string | null>(null);
|
||||
|
||||
@@ -53,6 +55,7 @@ export function RegisterForm() {
|
||||
password,
|
||||
phoneNumber: phoneNumber || undefined,
|
||||
notificationPreference: hasValidPhone ? notificationPreference : "email",
|
||||
newsOptIn,
|
||||
});
|
||||
window.location.href = redirectTo;
|
||||
} catch (err) {
|
||||
@@ -150,6 +153,19 @@ export function RegisterForm() {
|
||||
</label>
|
||||
</div>
|
||||
|
||||
<div className="flex items-start gap-2">
|
||||
<input
|
||||
id="news"
|
||||
type="checkbox"
|
||||
checked={newsOptIn}
|
||||
onChange={(e) => setNewsOptIn(e.target.checked)}
|
||||
className="mt-1 h-4 w-4 border-gray-300 rounded accent-brand-600"
|
||||
/>
|
||||
<label htmlFor="news" className="text-sm text-gray-700 leading-snug">
|
||||
Send me news and announcements about upcoming events (optional — you can unsubscribe at any time).
|
||||
</label>
|
||||
</div>
|
||||
|
||||
<div className="mt-1">
|
||||
<a
|
||||
href={loginHref}
|
||||
|
||||
Reference in New Issue
Block a user