BillTracker/client
null d53a64b604 feat(data): "Erase my data" danger zone (Batch 5)
New services/userDataService.js eraseUserData() permanently wipes a user's
financial + imported data in one transaction (child → parent order for FK
safety): bills (+ cascading payments/monthly_bill_state/bill_history_ranges),
transactions/accounts/data_sources, categories/groups, templates, snowball,
spending rules/budgets, merchant rules, imports, and per-user hint tables. It
PRESERVES the account, sessions, 2FA/WebAuthn, login history and preferences —
this resets your data, not your account — then re-seeds default categories and
writes an audit row to import_history.

- POST /api/user/erase-data — rate-limited (demoDataLimiter), requires a
  type-to-confirm token ("ERASE"), structured errors.
- UI: EraseDataSection danger-zone card (Export & backups pane) — red-accented,
  "download a backup first" nudge, type-to-confirm AlertDialog, toasts; on
  success DataPage reloads all state.

Tests: tests/eraseUserData.test.js — wipes user A only, preserves user B +
account + session, re-seeds categories, audited. Server 139 pass.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-03 15:21:07 -05:00
..
components feat(data): "Erase my data" danger zone (Batch 5) 2026-07-03 15:21:07 -05:00
contexts theme correctness 2026-05-28 01:30:40 -05:00
hooks feat(settings): auto-save preferences with live save status (batch 0.39.0) 2026-06-12 02:08:42 -05:00
lib refactor(client): single source of truth for money formatting (IMP-CODE-01) 2026-07-03 12:46:22 -05:00
pages feat(data): "Erase my data" danger zone (Batch 5) 2026-07-03 15:21:07 -05:00
public/img refactor: component splits, PWA support, CommandPalette 2026-05-28 20:53:22 -05:00
App.jsx feat(banking): bank transactions ledger page with route, sidebar link, and API endpoint 2026-06-12 03:59:42 -05:00
api.js feat(data): "Erase my data" danger zone (Batch 5) 2026-07-03 15:21:07 -05:00
index.css feat(settings): safe-to-spend toggle, move notifications from Profile to Settings, fix dark-mode readability 2026-06-12 01:52:48 -05:00
main.jsx v0.24.3: Session fixes, activity log corrections, UI polish 2026-05-11 13:39:48 -05:00