2026-05-22frontend

`music_url` column and audio playback added to posts

  • Change: music_url TEXT column added to the posts table (via ALTER TABLE … ADD COLUMN IF NOT EXISTS). Post type extended. Waveform seekbar (waveform-seekbar.tsx) and in-viewer audio playback added to the fullscreen viewer.
  • Why: Support music posts alongside image posts.
  • Affected Modules: app/lib/actions.ts, app/_component/fullscreen-viewer.tsx, app/_component/waveform-seekbar.tsx
  • Trade-offs:
    • Pro: Single posts table covers both image and music post types with nullable columns.
    • Con: Schema changes are still managed with hand-written ALTER TABLE … ADD COLUMN IF NOT EXISTS inside ensurePostsTable() rather than Prisma migrations; the posts Prisma model does not include music_url, creating a schema drift between Prisma and the raw SQL layer.