The check
design check finds anything on your screens that is not in your guide.
On this page
npx @sypnia/design checksrc/app/order/page.tsx:42 raw-color #F5D76E is not a colour of the guide (closest: color.accent)
src/app/order/page.tsx:57 unknown-piece <Badge> is not in gallery.yaml
cases/orders/place-order missing-state failure.Closed has no design
design check: 2 errors, 1 warningWhat it checks
| Code | Finds |
|---|---|
raw-color, raw-size, raw-font | a colour, size or font written by hand instead of a token |
unknown-piece | a piece that does not come from src/design/ or is not in gallery.yaml |
base-import | a screen importing @sypnia/base directly |
unknown-icon, icon-rules | an icon from outside design/icons/, or one that breaks the construction rules |
missing-screen | a case with a where and no screen file |
missing-state | an outcome or failure of a case with no designed state |
screen-out-of-date | a screen designed with an older guide or an older version of its case |
contrast | text or controls under the guide’s contrast minimums, measured on the render |
focus | a piece with no visible keyboard focus |
touch-target | something pressable smaller than size.touch on the phone render |
first-screen | the main content of a first_screen screen does not fit at 1366 × 700 or on a phone |
voice | a message that is too long, shows a code, or uses a word the guide avoids |
guide-drift | guide.md, tokens.json and tokens.css disagree |
components-out-of-date | pieces generated from an older guide |
Each finding is an error or a warning. The command exits with 1 when there are errors, so a pipeline stops; --json prints the findings for tools.
Where it runs
- Before the agent proposes a change. The Design skills run it and fix what they can.
- On every pull request, in Sypnia Git or any CI.
- In the console and App, next to each screen.
The checks that need a picture (contrast in context, touch-target, first-screen) use a browser: Chromium on your machine, or the renderer in Sypnia Cloud.
Waivers
Sometimes a rule must bend, for a while. A waiver needs a reason and an end date:
[[design.checks.waive]]
code = "raw-color"
path = "src/app/legacy/receipt.tsx"
reason = "Old receipt screen, replaced by place-order's outcome"
until = 2027-01-31