zeroclaw/web/src
Chris Hengge 4f9d817ddb
fix(memory): serialize MemoryCategory as plain string and guard dashboard render crashes (#3051)
The /memory dashboard page rendered a black screen when MemoryCategory::Custom
was serialized by serde's derived impl as a tagged object {"custom":"..."} but
the frontend expected a plain string. No navigation was possible without using
the browser Back button.

Changes:
- src/memory/traits.rs: replace derived serde impls with custom serialize
  (delegates to Display, emits plain snake_case string) and deserialize
  (parses known variants by name, falls through to Custom(s) for unknown).
  Adds memory_category_serde_uses_snake_case and memory_category_custom_roundtrip
  tests. No persistent storage migration needed — all backends (SQLite, Markdown,
  Postgres) use their own category_to_str/str_to_category helpers and never
  read serde-serialized category values back from disk.
- web/src/App.tsx: export ErrorBoundary class so render crashes surface a
  recoverable UI instead of a black screen. Adds aria-live="polite" to the
  pairing error paragraph for screen reader accessibility.
- web/src/components/layout/Layout.tsx: wrap Outlet in ErrorBoundary keyed
  by pathname so the navigation shell stays mounted during a page crash and
  the boundary resets on route change.

Co-authored-by: Argenis <theonlyhennygod@gmail.com>
2026-03-16 18:23:03 -04:00
..
components/layout fix(memory): serialize MemoryCategory as plain string and guard dashboard render crashes (#3051) 2026-03-16 18:23:03 -04:00
hooks feat(web): preserve message draft in agent chat across view switches (#3443) 2026-03-13 17:40:23 -04:00
lib fix(gateway): pass bearer token in WebSocket subprotocol for dashboard auth 2026-03-15 16:37:41 -04:00
pages feat(web): preserve message draft in agent chat across view switches (#3443) 2026-03-13 17:40:23 -04:00
types feat(gateway): add cron run history API and dashboard panel (#3440) 2026-03-13 17:06:44 -04:00
App.tsx fix(memory): serialize MemoryCategory as plain string and guard dashboard render crashes (#3051) 2026-03-16 18:23:03 -04:00
index.css feat(web): electric blue dashboard restyle with animations and logo (#3445) 2026-03-13 17:27:41 -04:00
main.tsx fix(gateway): align dashboard API client and embed built web assets 2026-02-21 16:14:01 +08:00
vite-env.d.ts feat(gateway): add embedded web dashboard with React frontend 2026-02-21 16:14:01 +08:00