Skip to main content

← Design System Proving Ground · Prompt Deck · Pictures

Design System Proving Ground Spec

How do we turn a component museum into a proving ground where forms ship with a standard?

Intent Contract

Agent autonomy boundary. Not parsed by engineering — governance instrument for humans and agents.

DimensionStatement
ObjectiveUnify forms navigation, document THE standard process, rewrite CRM patterns to use lib atoms, and stress-test composition depth with a meeting agenda form — turning stackmat.es from component museum to proving ground.
Outcomes1. Single /forms index replaces 3 nav locations. 2. Standard process page (Zod -> Server Action -> FormShell -> Name Attrs -> TanStack) discoverable in <30s. 3. CRM pattern pages L:R ratio improves from 1:15 to 1:3 or better.
Health MetricsExisting form atom Storybook tests stay green. Anti-pattern documentation preserved. Accessibility annotations on form atoms undamaged.
Counter-metricsPage count must not increase — consolidate, don't proliferate. Build time must not regress. Navigation depth must not exceed 3 clicks from homepage to any form page.
ConstraintsHard: Every page built from lib imports only (Prime Directive). No _components/ local directory. No real data wiring — console.log or alert only. Steering: Tailwind v4.1 with @theme bridge. L:R ratio target 1:3 or better.
AutonomyAllowed: page layout, content ordering, example data shapes. Escalate: new lib atoms, new organisms, nav hierarchy changes. Never: raw HTML form elements, inline styles bypassing design system, real API connections.
Blast RadiusDesign system app only. No production app changes. No lib changes (unless DS-05 reveals gaps, which triggers a stop). Existing pattern pages restructured, not deleted.
RollbackRevert nav changes in sidebar config. Restored pages from git history. CRM patterns revert to raw HTML (worse but functional). Zero data at risk — no data layer.
Stop RulesComplete when: all 5 feature IDs at L2+ and meeting agenda form composes from lib atoms. Halt when: DS-05 requires >3 new lib atoms — stop and fill lib first.

Story Contract

Stories are test contracts. Each row converts to test files. Tests must be RED before implementation starts. Tests going GREEN = value delivered.

#WHEN (Trigger + Precondition)THEN (Exact Assertion)ARTIFACTTest TypeFORBIDDEN (Must not happen)OUTCOME (Performance Number)
S1Engineer navigates to /forms (page exists in sidebar, forms content scattered across 3 locations)Single index page renders with links to all form content: atoms, patterns, anti-patterns, checklist. Sidebar shows one "Forms" entry. document.querySelectorAll('[data-section="forms"]') returns exactly 1 sidebar item.BLOCKER: design system app test infrastructure TBDe2eForms still appear in 3+ sidebar locations. Index page is a stub with "contribute this section."Navigation to any form page in <2 clicks vs current 3+ locations with dead ends
S2Engineer opens standard process page (form atoms exist in lib, no standard process documented in one place)Page renders THE chain: Zod schema -> Server Action -> FormShell -> Name Attrs -> TanStack binding. Each step links to the relevant lib source. Code example is copy-pasteable.BLOCKER: design system app test infrastructure TBDe2ePage describes the process in prose without runnable code. Page links to external docs instead of showing the chain.Standard process discoverable in <30s vs tribal knowledge taking days to acquire
S3Engineer opens form shipping checklist (standard process page exists, no pre-ship verification)10-point checklist renders with pass/fail criteria for each gate. Every gate references a specific lib atom or pattern. Checklist is printable.BLOCKER: design system app test infrastructure TBDe2eChecklist has vague items like "looks good" or "works correctly." Checklist references components that don't exist in lib.10-point gate checked in <5 min vs ad-hoc review missing issues
S4Engineer opens CRM contact form pattern (CRM pages currently use raw HTML with L:R 1:15)Page renders contact form using only @stackmates/ui imports. Zero raw <input>, <select>, or <form> elements. L:R ratio 1:3 or better.BLOCKER: design system app test infrastructure TBDintegrationAny raw HTML form element in the page source. L:R ratio worse than 1:5.L:R ratio 1:3 vs current 1:15 — 5x improvement in lib composition
S5Engineer opens meeting agenda form (lib atoms exist, FormShell is the only organism, Tight Five schema maps to 5 form fields)MeetingAgenda form renders 5 labeled fields (one per Tight Five question) composed from lib atoms. FormShell wraps the form. No _components/ directory exists. Form submits to console.log.BLOCKER: design system app test infrastructure TBDintegrationMeetingAgenda requires local _components/ directory. Form uses raw HTML. More than 3 new atoms needed that don't exist in lib.Organism composed from existing atoms in <2 hours vs "lib can't handle this"

Tight Five coverage check:

P DimensionStories covering it
Pain (can't find the standard)S1 (unified nav), S2 (standard process)
Demand (builders need to ship forms)S3 (shipping checklist), S4 (CRM rewrite proves demand)
Edge (three-mode architecture)S5 (meeting form = composition stress test)
Trend (design systems + AI code gen)S2 (standard process as AI-readable reference)
Conversion (can we ship it)S4 (CRM rewrite = existing content improved), S1 (nav consolidation)

Build Contract

The deliverable. Engineering builds from this. Commissioning reads this.

Find the Standard

#FeatureIDFunctionArtifactSuccess TestSafety TestRegression TestValueState
1DS-01Unify forms navigation into single sidebar entry/forms index page + sidebar configSingle "Forms" entry in sidebar; index links all form content (S1)Forms must not appear in 3+ nav locations after change (S1 FORBIDDEN)Existing form atom and pattern pages must remain accessibleOne place for all form contentGap
2DS-02Document THE standard form process chainStandard process reference pagePage shows Zod -> Server Action -> FormShell -> Name Attrs -> TanStack with copy-pasteable code (S2)Process must not be prose-only without runnable code (S2 FORBIDDEN)Existing anti-pattern documentation must not be removedEngineer knows THE chain in 30 secondsGap
3DS-03Create 10-point form shipping checklistForm shipping gate page10 pass/fail criteria, each referencing specific lib atom or pattern (S3)Checklist must not have vague items like "looks good" (S3 FORBIDDEN)N/A — new pageForms ship with verified qualityGap

Prove It Works

#FeatureIDFunctionArtifactSuccess TestSafety TestRegression TestValueState
4DS-04Rewrite CRM patterns using lib atoms onlyRewritten CRM contact, deal, company form pagesZero raw HTML form elements; L:R 1:3 or better (S4)Must not introduce raw <input>, <select>, <form> (S4 FORBIDDEN)Existing CRM page URLs must not changeCRM forms prove the standard works at L:R 1:3Gap
5DS-05Build meeting agenda form from existing atomsMeetingAgenda organism (Tight Five as form fields)5 labeled fields from lib atoms, FormShell wrapper, console.log submit (S5)Must not require _components/ local dir or >3 new lib atoms (S5 FORBIDDEN)Existing FormShell behavior must not changeComposition depth proven for real domain complexityGap

Screen Contracts

Commissioning checklist. Each row is pass/fail. Walk the list after engineering ships.

Forms Index (/forms)

The entry point. Everything about forms starts here.

#CheckPass whenBuild refFeature ID
F1Single sidebar entry"Forms" appears once in sidebar navigation. No other form-related entries elsewhere.#1DS-01
F2Links to atomsIndex page links to form atom documentation (Input, Select, Textarea, Checkbox). Links resolve.#1DS-01
F3Links to patternsIndex page links to form pattern pages (CRM contact, CRM deal, anti-patterns). Links resolve.#1DS-01
F4Links to standard processIndex page links to standard process reference page. Link resolves.#1DS-01
F5Links to checklistIndex page links to form shipping checklist. Link resolves.#1DS-01
F6No stubsZero "contribute this section" placeholders. Every link resolves to real content.#1DS-01

Standard Process (/forms/standard-process)

THE reference. One page. One chain.

#CheckPass whenBuild refFeature ID
P1Chain visibleZod -> Server Action -> FormShell -> Name Attrs -> TanStack shown as numbered steps with code.#2DS-02
P2Code copyableCode example can be copied and pasted into a new form page. Syntax highlighted.#2DS-02
P3Links to libEach step links to the relevant lib source file or Storybook story.#2DS-02
P4Anti-patterns linkedPage links to existing anti-patterns documentation.#2DS-02

Form Shipping Checklist (/forms/checklist)

The gate. 10 points. Pass or fail.

#CheckPass whenBuild refFeature ID
C110 gate itemsExactly 10 checklist items render.#3DS-03
C2Each item specificEvery item references a specific lib atom, pattern, or threshold — no vague "looks good."#3DS-03
C3Pass/fail formatEach item has a binary pass/fail criterion, not a subjective scale.#3DS-03

CRM Contact Pattern (/patterns/crm/contact-form)

The rewrite proof. Raw HTML -> lib composition.

#CheckPass whenBuild refFeature ID
R1Zero raw HTMLPage source contains no raw <input>, <select>, <form> elements.#4DS-04
R2Lib imports onlyAll form elements import from @stackmates/ui.#4DS-04
R3L:R ratioComposition ratio 1:3 or better (measured by lib imports vs local code lines).#4DS-04
R4URL preservedPage URL unchanged from current pattern page.#4DS-04

Meeting Agenda Form (/patterns/meetings/agenda)

The stress test. Composition depth for real domain complexity.

#CheckPass whenBuild refFeature ID
M1Five fields renderFive labeled form fields visible, one per Tight Five question.#5DS-05
M2Lib atoms onlyAll form fields use lib atoms (Input, Select, Textarea from @stackmates/ui).#5DS-05
M3FormShell wrapsFormShell organism wraps the entire form.#5DS-05
M4No local componentsNo _components/ directory exists under the pattern page.#5DS-05
M5Submit logsForm submit calls console.log with structured field data. No API call.#5DS-05
M6AccessibilityAll fields have associated labels. Form is keyboard navigable. Error states visible.#5DS-05

How does the user move from pain to the standard?

Pain-to-Perform Journey

StageUser StateWhat navigation must doCurrent StateTarget State
Pain"Where's the form standard?"Show the cost: 3 nav locations, dead ends, raw HTMLForms in 3 sidebar sections, /forms 404sSingle /forms entry
AwarenessFinds the Forms sectionSurface standard process link prominently on indexNo index page existsIndex page with curated links
First ValueReads the standard processDeliver THE chain on one page with copyable codeProcess is tribal knowledgeStandard process page renders the chain
HabitUses checklist before shippingLink checklist from standard process page and form atom pagesNo checklist existsChecklist linked from all form pages
MasteryContributes new patternsMeeting agenda form demonstrates how to add an organismOnly 1 organism (FormShell) existsMeetingAgenda proves the path
EffortlessPatterns auto-scaffoldTemplate generator creates form pages pre-wired to lib atomsCopy-paste from existing patternsFuture: CLI scaffolding (out of scope)
StateSidebarForms IndexPattern PagesStandard Process
Flag OFFForms in 3 locations404Raw HTML CRM pagesDoes not exist
Flag ON (S0)Single "Forms" entryLinks to atoms + patternsCRM pages rewritten with lib atomsTHE chain documented
Flag ON (S1)Same+ checklist link+ meeting agenda pattern+ linked from checklist

Cross-Cutting Navigation

FromToTriggerWhat Happens
Homepage/forms"Forms" in sidebarRoutes to forms index
Forms index/forms/standard-process"Standard Process" linkRoutes to THE chain
Forms index/forms/checklist"Shipping Checklist" linkRoutes to 10-point gate
Forms index/patterns/crm/contact-form"CRM Contact" linkRoutes to rewritten CRM pattern
Forms index/patterns/meetings/agenda"Meeting Agenda" linkRoutes to organism stress test
Standard process/forms/checklist"Pre-ship checklist" link at bottomRoutes to shipping gate
Any form atom page/formsBreadcrumbRoutes back to forms index
Meeting agendaMeetings PRD"Full meeting spec" linkRoutes to backburner PRD (context)
Components
Atoms
Form ← existing, links to atom stories
Organisms
FormShell ← existing
MeetingAgenda ← DS-05 adds this
Forms ← DS-01 creates this section
Standard Process ← DS-02
Shipping Checklist ← DS-03
Patterns
CRM ← DS-04 rewrites these
Contact Form
Deal Form
Company Form
Meetings ← DS-05 adds this
Meeting Agenda

Wiring Coordinates

ElementFileAction
Sidebar configBLOCKER: stackmat.es sidebar config location TBDAdd "Forms" section, restructure pattern entries
Forms index pageBLOCKER: stackmat.es page creation pattern TBDNew page at /forms route
Standard process pageBLOCKER: stackmat.es page creation pattern TBDNew page at /forms/standard-process route
Checklist pageBLOCKER: stackmat.es page creation pattern TBDNew page at /forms/checklist route
CRM pattern pagesBLOCKER: exact CRM page paths in stackmat.es TBDRewrite existing pages
Meeting agenda pageBLOCKER: stackmat.es pattern page creation TBDNew page at /patterns/meetings/agenda route

Performance

Priority Score

PRIORITY = Pain x Demand x Edge x Trend x Conversion

DimensionScore (1-5)Evidence
Pain4Dogfood report: 10 issues (1 critical, 3 high). /forms 404. CRM pages bypass lib atoms (L:R 1:15). 3 nav locations. Marketing section dead.
Demand3Internal builders use forms daily. Dogfood found 3/8 pattern pages unreachable. Pattern seekers have shadcn as alternative. No external demand signal.
Edge4Three-mode architecture (IMPORT -> COPY -> USE) is novel. Anti-pattern docs rare in design systems. Meeting form as domain stress test unique.
Trend4Design systems mainstream. AI code generation increases need for machine-readable standard references. Component-driven development accelerating.
Conversion3Form atoms built (L:R 1.4:1). FormShell exists. TanStack integration solid. Missing: unified nav, standard process page, CRM rewrite. ~60% built.
Composite5764 x 3 x 4 x 4 x 3

Quality Targets

MetricTargetNow
Form nav locations13
CRM pattern L:R ratio1:31:15
Shipping checklist existsYesNo
Standard process page existsYesNo
Meeting agenda composes from libYesN/A

Failure Budget

Failure TypeBudgetResponse
New lib atom needed for DS-05<3If >3 new atoms needed, stop DS-05 and fill lib first
CRM rewrite breaks page URL0%URLs preserved — redirects if absolutely necessary
Checklist item is vague0%Every item must reference a specific lib atom or threshold

Kill signal: If teams don't use meeting instrument within 30 days of ship, demote to Explorations. If MeetingAgenda requires >3 new lib atoms, the lib has fundamental gaps — stop and fill lib first.

Kill date: 2026-06-30.

Platform

Current State

ComponentBuiltWiredWorkingNotes
Form atoms (Input, Select, Textarea, Checkbox)YesYesYesL:R 1.4:1, well-composed
FormShell organismYesYesYesOnly organism in tier
TanStack Form integrationYesYesYesDocumented
Anti-pattern documentationYesYesYesRare, valuable
Accessibility annotationsYesYesYesThorough on form atoms
CRM pattern pagesYesYesBrokenRaw HTML, L:R 1:15, violates Prime Directive
Marketing sectionYesNoBrokenHomepage CTA 404s
Advanced Form pageYesNoStub"Coming Soon" placeholder
Forms navigationPartialPartialBroken3 separate locations, confusing

~60% built. Atoms healthy. CRM patterns, navigation, and stubs need work.

Build Ratio

~50% composition (form atoms, FormShell, TanStack integration, anti-patterns — all built). ~50% new work (nav unification, standard process page, checklist, CRM rewrite, meeting form).

Protocols

Build Order

SprintFeaturesWhatEffortAcceptance
S0DS-01, DS-02, DS-03Foundation: unified nav + standard process + checklist3dSingle sidebar entry. Standard process page. 10-point checklist.
S1DS-04Proof: CRM pattern rewrite3dZero raw HTML. L:R 1:3. URLs preserved.
S2DS-05Stress test: meeting agenda form2d5 fields from lib atoms. FormShell wraps. No local components.

Total: ~8 days. S0 unblocks everything. S1 proves the standard. S2 stress-tests composition depth.

Commissioning

#FeatureInstallTestOperationalOptimize
1Forms nav unification (DS-01)--------
2Standard process page (DS-02)--------
3Form shipping checklist (DS-03)--------
4CRM pattern rewrite (DS-04)--------
5Meeting agenda form (DS-05)--------

Players

Demand-Side Jobs

Job 1: Ship Forms

Situation: Engineer assigned to build a form for a new feature.

ElementDetail
Struggling momentCan't find THE standard. Finds 3 nav locations. Reads raw HTML patterns. Copies the wrong thing.
Current workaroundInspect element on production app. Ask a teammate. Read source code.
What progress looks likeOpen /forms, read standard process, copy the chain, check against checklist, ship.
Hidden objection"I don't trust the design system page reflects what's in the lib."
Switch triggerThird form built by cargo-culting, each with different patterns.

Features that serve this job: DS-01, DS-02, DS-03

Job 2: Team Credibility

Situation: Venture evaluator visits stackmat.es to assess capability.

ElementDetail
Struggling momentSees 404s, stubs, and raw HTML. Concludes the team isn't serious.
Current workaroundLook at GitHub repos directly.
What progress looks likeWorking forms, composition proof, no dead ends.
Hidden objection"This looks like a template."
Switch triggerSecond visit to a design system that has more stubs than working examples.

Features that serve this job: DS-01, DS-04, DS-05

Job 3: Copy Patterns

Situation: External developer looking for form patterns to adopt.

ElementDetail
Struggling momentshadcn has individual components but no composition patterns. Needs the chain, not atoms.
Current workaroundshadcn/ui or v0.dev for atoms. Build composition patterns from scratch.
What progress looks likeCopy a complete form pattern with validation, server action, and error handling.
Hidden objection"shadcn already has this."
Switch triggerBuilt the same validation-to-server-action chain three times.

Features that serve this job: DS-02, DS-04

Job 4: Meeting Prep

Situation: Meeting participant needs to fill in Tight Five agenda before the meeting.

ElementDetail
Struggling momentNo structured form. Uses Google Doc or wings it.
Current workaroundBlank Notion page. Google Doc. Skip preparation entirely.
What progress looks likeOpen meeting agenda form, fill 5 fields, submit. Done.
Hidden objection"This is overhead. I'll wing it."
Switch triggerThird meeting where nobody prepared and the hour was wasted.

Features that serve this job: DS-05

PRD Relationships

PRDRelationshipData Flow
Meetingsdepends-onThis PRD proves the form patterns that Meetings PRD consumes. DS-05 is the bridge.
Prompt DeckComplementaryDesign system already showcases PromptDeck. No conflict.
Sales CRMComplementaryDS-04 (CRM pattern rewrite) improves the design system showcase of CRM forms.

Context