Commit Graph

12 Commits

Author SHA1 Message Date
Codex b7221f2f70 feat(subscription): separate selection from payment and add issue feedback
(cherry picked from commit fe9d31146b)
2026-07-27 16:12:12 +08:00
admin b22db6d147 feat(payment): share payment method selector 2026-07-17 18:27:24 +08:00
admin b4904e738b perf: defer heavy modules and add performance baselines
Lazy-load Stripe and the chat reply animation, remove the unused Lottie runtime, and add repeatable bundle and Web Vitals baseline tooling.
2026-07-14 10:55:08 +08:00
admin 34c6f5523c refactor(app): remove unused components 2026-07-13 14:02:27 +08:00
admin 49b67064f7 feat(subscription): load vip and credit plans from api 2026-06-26 15:09:27 +08:00
admin bfbf7ee91a feat(app): improve payment and paywall UX 2026-06-24 10:02:22 +08:00
admin 5ed43a37ce feat(subscription): add payment channel selector 2026-06-22 16:14:34 +08:00
admin 5bf98e9452 feat(subscription): support Stripe payment element 2026-06-18 18:03:36 +08:00
admin a347b39001 feat(payment): connect payment service flow 2026-06-18 15:40:59 +08:00
admin 287affa34a refactor(app): move route screens out of components
Exclude test and spec files from generated barrels so page imports do not load test modules at runtime.
2026-06-17 14:13:42 +08:00
admin d41b3c4473 refactor(schemas): extract nullable-default helpers to shared file
The three defensive Zod helpers (stringOrEmpty, numberOrZero,
booleanOrFalse) used by user.ts are general-purpose Zod utilities
that any schema may need — they're not user-specific. The original
inline declaration in user.ts had two downsides:

1. Any new schema (chat, auth, metrics, etc.) that needs the same
   'null | undefined → default scalar' pattern would have to
   duplicate the helper.

2. The long defensive-parse comment block (11 lines) lived inside
   user.ts and didn't explain the helpers' general purpose.

Move them to src/data/schemas/nullable-defaults.ts (top-level
sibling of auth/, chat/, metrics/, user/ subdirs) so any schema
can import them. Keep the original explanation verbatim at the
top of the new file.

Bundled in this commit:
- user.ts imports the helpers from the new file (drops 11 lines
  of comment + 3 const declarations)
- 3 auto-generated barrel index files regenerated by barrelsby
  to pick up the new exports (chat/, subscription/, stores/user/)
2026-06-17 12:05:09 +08:00
Claude e88a99626d feat(subscription): add VIP subscription page
Add a new /subscription route showing three VIP membership plans (Monthly,
Quarterly, Annual) with a pink→peach banner, per-plan gradient price bars,
a benefits card, a mock activate CTA, and an agreement checkbox.

- New reusable <Checkbox /> in src/app/_components/core for the legal
  agreement toggle
- Hardcoded SUBSCRIPTION_PLANS constant in src/data/constants
- New SubscriptionScreen composed of 7 colocated components (back link,
  user row, banner, plan card, benefits card, CTA button) with CSS
  Modules matching the existing design-token system
- Route registered as protected and reached from /sidebar "Membership"
- Mock CTA: window.alert + router.push(/chat) — no payment calls

Co-Authored-By: Claude <noreply@anthropic.com>
2026-06-15 17:49:15 +08:00