trails/apps/journal/app
Ullrich Schäfer 079c3de90c
Modernise zod idioms to v4
Replace the deprecated v3 string-method forms with the top-level
validator helpers zod 4 prefers:

- z.string().url()      → z.url()      (3 sites)
- z.string().uuid()     → z.uuid()     (5 sites)
- z.string().datetime() → z.iso.datetime() (9 sites)

Also swap the ZodIssueCode.custom compat-shim reference in
demo-bot.server.ts's superRefine for the bare string literal "custom",
which is v4's idiomatic form. No runtime change.

All 147 tests still pass.

The `parsed.error.issues.map(i => ({field, message}))` pattern in the
five journal API route handlers stays as-is — the fields we read are
unchanged in v4, and zod's new error helpers (z.treeifyError,
z.prettifyError) produce different shapes that would change our
public API error contract.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-19 11:41:03 +02:00
..
components Stop Sentry on logout; fix E2E + Dockerfile for merged consolidation 2026-04-18 00:40:36 +02:00
jobs Fix demo-bot cron + cadence math 2026-04-19 11:25:06 +02:00
lib Modernise zod idioms to v4 2026-04-19 11:41:03 +02:00
routes Route journal BRouter calls through the planner 2026-04-19 11:11:10 +02:00
entry.client.tsx Add legal pages, ToS acceptance, and alpha banner 2026-04-18 00:08:48 +02:00
entry.server.tsx Consolidate Sentry config into shared package; fix inconsistencies 2026-04-18 00:30:09 +02:00
root.tsx Prompt users with stale terms_version to re-accept 2026-04-19 08:06:16 +02:00
routes.ts Prompt users with stale terms_version to re-accept 2026-04-19 08:06:16 +02:00