Skip to content

docs(db): sync v2 diagrams with live schema - #326

Merged
Flapjacck merged 1 commit into
mainfrom
codex/docs-v2-live-schema-diagrams
Nov 30, 2026
Merged

Flapjacck merged 1 commit into
mainfrom
codex/docs-v2-live-schema-diagrams

Conversation

@Flapjacck

Copy link
Copy Markdown
Member

Summary

Rebuilds the v2 README schema and storage diagrams from read-only queries against the live LCS-Site database. Regenerates the admin database types where they had drifted.

Type of change

  • 📝 Docs / chore (README, CI, dependencies, cleanup)

What changed

  • Replaced the ER diagram with all 11 live v2 tables, all columns, PK/FK/UK markers, nullability, enum-like checks, and relationships.
  • Added a storage flowchart covering all six live buckets, their visibility, limits, MIME types, and code-backed path patterns.
  • Regenerated apps/admin/src/types/database.types.ts with --schema public,v2; this adds v2.companies.link and v2.site_data_versions.
  • Stamped the diagrams with the live-database date and the required update reminder.

Data changes

  • No Supabase changes

Only read-only metadata and storage-layout queries were run against the live project.

How to test

  1. Open supabase/v2/README.md on GitHub and confirm both Mermaid diagrams render.
  2. Compare the tables/buckets with the live database metadata.
  3. Run pnpm --dir apps/admin build.

Checklist

  • pnpm build passes locally
  • PR is small and focused on one issue
  • I understand every line of this code (AI-assisted is fine, AI-authored without review is not)
  • No secrets, keys, or .env files committed (anon key only on the client, never the service role key)
  • Docs/README updated if setup, routes, or env vars changed

Diagram verification

Both Mermaid blocks were rendered locally with Mermaid CLI and Chrome before this PR was opened.

@vercel

vercel Bot commented Nov 30, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
admin_page Ready Ready Preview Nov 30, 2026 6:49pm UTC
better-website Ready Ready Preview Nov 30, 2026 6:49pm UTC

@Flapjacck
Flapjacck merged commit 47b18a5 into main Nov 30, 2026
5 checks passed
@Flapjacck
Flapjacck deleted the codex/docs-v2-live-schema-diagrams branch November 30, 2026 18:53

This branch was successfully deployed

1 active deployment
Preview – better-website — e720d069 Deployed Nov 30, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant