Repository navigation
Docs: the design system, and the rules for changing it - #2164
Merged
Merged
Conversation
A page for people and coding agents to read before they change a token or a primitive, add a font, an icon set or a picture, or build a screen from a design made outside the code. It says what the system is built on: it stays compatible with shadcn, surfaces come in levels, and light and dark are always both drawn. Then the rules that follow from those for tokens, primitives, pictures and animation, building from a Figma design, and how a change to the system lands. AGENTS.md and the app guidelines link to it.
guidovizoso
requested review from
MikeRyanDev,
davidmckayv,
dustywusty,
mxmzb,
samjulien and
tylerslaton
as code owners
November 24, 2026 22:00
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 this changes
A new page,
docs/design-system.md, for people and coding agents to read before they change a token or a primitive, add a font, an icon set or a picture, or build a screen from a design made outside the code.The app guidelines and "The look" say what the design system looks like today. Nothing said what must stay true when it changes, and a redesign can keep every existing rule about screens and still replace the system under them. This page is that missing part.
What the system is built on
The rules that follow
successandwarning. No token for a component or a state, wherever it is declared. The shared scales keep their meaning, and names are never removed.It ends with the tests that hold each rule and a checklist to run before asking for a review.
AGENTS.mdnow tells agents to read it before touchingtokens/,app/src/components/uiortheme.css, anddocs/app-guidelines.mdlinks to it.Not in this PR
app/tests/design-tokens.test.tsreads only:rootand.dark, so a token declared in@themepasses unseen. The page says the rule is wider than the test. Closing that is a follow-up, and that sentence goes with it.AGENTS.mdis what points agents here for now.How it was checked
Docs only, no code. Every link and anchor in the page resolves, and every test it names exists on
main. The surface table was read against the primitives (dialog,sheet,popover,toast,tooltip).