docs(studio): decompose the draft/preview/admin report into per-subsystem docs - #11
Open
martyy-code wants to merge 3 commits into
Open
docs(studio): decompose the draft/preview/admin report into per-subsystem docs#11martyy-code wants to merge 3 commits into
martyy-code wants to merge 3 commits into
Conversation
…stem docs The 2026-07-30 architecture report was one 653-line file covering seven subsystems, so answering any single question meant loading all of it. It is now docs/reports/studio/ — 21 documents across admin/, agent/, preview/, publish/ and repo/, following the docs/learnings/ convention (README index table, numbered reading order, per-document Sources with verification dates). The original file becomes a stub with a section-to-file map, so old links land somewhere useful. This is not a copy. Every factual claim was re-measured against the repo on 2026-07-30 and several did not survive: - The dual-tree arbitration was too broad. "The showcase file is a re-export with no design content to lose" holds for 4 items of 9; five carry real implementation, and for input, textarea, colored-badge and icon-button there is no @ui/ primitive to re-export at all. Arbitration is now per item, and for icon-button and colored-badge the workspace copy wins — the consumer copies are the degraded ones (icon-button inlines a strict subset of the button base string). - The drift apparatus was not guarding "one import specifier". Its per-item assertions cover 3 of 9 items; three items get zero assertions and the run still reports green, which is why a real divergence in ds-icon-button has been sitting in a passing build. - "All nine items begin with use client" is true of the showcase tree and false of the shipped one, where it is 5 of 9. - contract-test.mjs already derives its item list dynamically (9/9). Only its npm install list is hardcoded, and that list is currently complete — a latent coupling, not a stale list. - The v16.2.6 release page does not carry the CVE-2026-44576 fix; that ships in v16.2.5 and v16.2.6 is a Turbopack follow-up. The recommendation to move to 16.2.12 is unchanged. - The button cva has 8 sizes, not nine. Two additions the decomposition surfaced: the validator set grows from six to eight (manifest-versus-imports agreement, and category in the closed set of 13 — both currently maintained by hand and losing their maintainer under decision 2), and the publish step has to write apps/web/lib/registry/index.tsx, a hand-maintained aggregator with 18 hardcoded imports that the original file list omitted. Also amends the shadcn-registry-adoption addendum, which repeated the first two corrections above, and fixes .gitignore: inline comments are not supported, so the .contract-test/ rule never matched. temp/saas-template is now ignored — it is a vendored checkout with its own .git. No code touched. Co-Authored-By: Claude <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Re-verified all claims against the repo (2026-07-30). Factual corrections: - 02-single-tree.md: button cva base is 602 chars, not 607 - 02-single-tree.md, repo/01-decoupling.md: drift apparatus NOT yet deleted (script, audit files, drift CI job, CONTRIBUTING/skill references all still present) - publish/README.md: 6 CI jobs exist today (not 5), drift job still present at ci.yml:100-113 - repo/02-pnpm-and-versions.md: step 1 sits inside apps/web's build script (not a separate manual step) - repo/02-pnpm-and-versions.md, repo/03-nextjs-16.md: next.config.ts is 7 physical lines (not 3) — substance (only transpilePackages) unchanged - repo/04-template-reuse.md: Better Auth ^1.6.25 (verified latest, not ^1.6.23) - preview/01-transpile-and-imports.md: lucide-react ^1.28.0 (verified latest, not ^1.27.0) - repo/03-nextjs-16.md: ~300ms Runtime Cache propagation is not documented at that number; treat as empirical estimate, measure under real load Co-Authored-By: Claude <noreply@anthropic.com>
Adds the structural content flagged in the principal-level review:
cost model, second-order effects, exit paths, deferral triggers,
organizational shape, runbooks, contracts.
99-frictions-and-costs.md:
- Maintenance quantified (~20-35h/month) with per-surface breakdown
- Expected incident frequency per class
- When this becomes the wrong design (5 trip-wires)
- Tailwind exit path (5 levels, ordered by implementation cost)
- Second-rendering-path drift handling
- Decision 8 revisit trigger (30% UNPUBLISHED_DEPENDENCY, etc.)
- Studio org-shape trigger (second maintainer)
- Each deferred item now carries an explicit revisit trigger
README.md:
- Topology status: apps/studio and apps/preview are to-build, not extant
- Cost model, in numbers (headline figures)
- What "success" looks like and the second-order effects
- The property to preserve under change
admin/README.md:
- Organizational shape section: ownership today, costs of the singleton,
triggers for re-derivation, what does not change
admin/01-auth.md:
- Runbook: locked out without email transport (database surgery procedure
with SQL, options for password reset, prevention, "if this runbook is
wrong" clause)
agent/README.md:
- Skills contract: agent-owned vs system-owned vs neither-owned
- Manifest ownership: agent provides, validator verifies (with reasoning)
preview/README.md:
- Caching model section: confirms cacheComponents: true in apps/preview
next.config.ts, cacheLife('max') applicability
Co-Authored-By: Claude <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
The 2026-07-30 architecture report was one 653-line file covering seven subsystems. It becomes
docs/reports/studio/— 21 documents, following thedocs/learnings/convention (README index table, numbered reading order, per-documentSourceswith verification dates).The original file becomes a stub with a section-to-file map, so old links land somewhere useful.
No code touched. 132 relative links and 29 anchors verified to resolve.
Why not just split the file
Every factual claim was re-measured against the repo on 2026-07-30. Several did not survive, and two of them were load-bearing for a locked decision.
input,textarea,colored-badge,icon-buttonthere is nopackages/uiprimitive to re-export at allds-icon-buttonsits in a passing builduse client"contract-test.mjsinstall list → derive from catalog"The consequence that matters: the dual-tree arbitration is now per item, not blanket. "The consumer version wins" would publish
ds-icon-button's trimmed base string — missinggroup/button,text-sm, the active translate, everyaria-invalid:*and every[&_svg]rule — as the single source of truth. Foricon-buttonandcolored-badgethe workspace copy wins, and both need rewriting into self-contained form before they can become the source. That is real work the "one import specifier" framing hid.Two additions the decomposition surfaced
Validators go from six to eight. Added:
manifestagreement against the imports actually present in source, and category membership in the closed set of 13. Both agreements hold today across all nine items and are maintained by hand — under decision 2 they lose their maintainer. TheregistryDependencieshalf is load-bearing: decision 8 resolves those against published items, so a missing entry becomes a blank preview frame the agent cannot diagnose fromerrors[]rather than a validation error.Publishing has to write
apps/web/lib/registry/index.tsx— a hand-maintained aggregator with 18 hardcoded imports, keyed by short ids whileregistry.jsonis keyed byds-names, with nothing cross-validating the mapping. The report's generated-file list omitted it. This moves decoupling from hygiene to a publishing prerequisite.Also in this PR
shadcn-registry-adoptionaddendum, which repeated the first two corrections above and pointed at the now-stubbed report..gitignore: inline comments are not supported, so the existing.contract-test/rule never matched anything. Also ignorestemp/saas-template— a vendored reference checkout with its own.git, onegit add -Aaway from being committed.project_studio_decisions.md, and its decision 5 entry now records that arbitration is per item.Review path
Reading the whole thing is not the point. Start with
docs/reports/studio/02-single-tree.mdandrepo/01-decoupling.md— those two carry the corrections and describe work that has to land before anything else.agent/01-validators.mdis the one to disagree with if you are going to disagree with something: it argues that with no PR in the authoring loop, those eight checks are the entire enforcement surface of the project's anti-slop thesis.🤖 Generated with Claude Code