Skip to content

Concepts · design

Design with Pen ​

Pen handles static sites; CMS/framework, complex states and cross-browser work need separate coding approval. The .pen is the source.

Prepare the project ​

Install Pen.app; devkit sync supplies pen and pencil MCP. pen login needs Node ^22.22.3 || >=24.8.0 and agent-browser or Playwright. Chat login.

/index fills missing context and .agents/context/DESIGN.md. Open design/*.pen in Pen.app; its chat loads repository instructions and design/AGENTS.md.

Install per clone: devkit design merge --install; devkit doctor checks it. Resolve conflicting node edits.

Rules and decisions ​

Record rules in design/RULES.md and decisions in design/DECISIONS.md for both sessions. Drawing invariants stay in the compact channel; handoff procedures load on demand. Add project checks via the project criteria contract.

Draw and approve in Pen ​

Include loading/error states. /pen-design loads anti-slop before drawing (websites: Hallmark) and checks previews.

Import before redesigning. Reuse tokens, fonts, icons and masters; draw components first. Review real content/states; approve Mobile 390, derive Desktop 1280 unless the adapter specifies another focus.

Before final approval, run devkit design content-check --contracts design/app.pen --ids <nr|id,...> for owned masters, with direct Min/Max examples and named Limits: slots. --help lists all contract rules. Excluded masters are not certified.

Approve the shown frame number, e.g. “Frame 1201 is approved”. Content changes invalidate approval; approval neither starts coding nor grants project writes.

Say “Abnahme starten”. devkit design status --review lists canvas, frame id/name and order. Use Pen's Slides / Present or exact-name search in queue order; document order may differ. The agent never moves the viewport or reorders frames. Answer “weiter” (approve), a change request, or “weg” (remove).

Pen commits the canvas inside design/ and parks code todos; separately approved Orca coding returns uncommitted code.

Choose the implementation route ​

The design channel blocks project code writes, including native coding. Approve a separate code handoff; never bypass the guard.

Integration handoff to Claude Code or Codex ​

Request approved frame ids and Pen handoff todos; reuse project components.

Check adapter, token drift and design verdict; settle data sources, types and fallbacks. Build tokens → components → sections → views. Single-mode adapter: mode dark/light.

Delegates read only. CANVAS_STALE: reconcile with owner or choose a fresh worktree.

From canvas to shipped code in seven steps

Canvas/token handoff todos require coding approval. Sync and marking.

Storyblok: configure cms_schema/cms_stories, then rerun devkit design adapter-check after corrections. Copy limits.

Verify and finish ​

Verify frame widths and above max-width using project tokens and the frame theme (--color-scheme light|dark overrides it).

Before review, devkit design proof must pass: current canvas/code comparison, browser evidence and core E2E flows.

Login: proof uses --storage-state <file>; browser evidence needs its own login. Keep credential-bearing state private. URLs, thresholds, masks and recovery: proof reference.

After proof, commit code and fold approved drafts into masters; Git keeps history. Stamp both frames with devkit design stamp <id> --target <path> --commit <sha> and commit canvas markers separately; use the commit that last changed the first Code: target, not necessarily HEAD. · shipped refers to verified, committed code.

Correct a shipped page ​

Copy-only edits need no canvas changes or design receipts. Appearance changes still require verification.

Appearance corrections: draw beside the shipped frame, approve, implement, verify both widths, commit and stamp. Code missing the approved frame: fix directly; strict verify must pass.

Owner accepted code as the reference? Use the native canvas-follow recipe.

When a gate blocks ​

Commentable mapped targets require @frame <numbers>, without override. Preview repairs with devkit design sync --fix-markers <target> --dry-run; omit --dry-run to apply. DESIGN_CODE_AHEAD blocks changes, including refactors, ahead of unchanged shipped frames. Recovery and owner-approved hash-bound exceptions: marking reference.

Commands ​

CommandWhen to use it
devkit design fontsRead-only audit of missing weight/style cuts for declared custom families.
devkit design content-checkMeasure explicit Limits: against rendered content in Vue dev builds.
devkit design proof --shippedStrict Accept verify/compare; supports --base, --storage-state and --restamp (stamp passing units only).
devkit design verify / compare with --press <chord>Open keyboard-driven states after settling, before --open; checks key delivery.
devkit design saveSave/sort frames; auto-commit only, never with --no-commit.

Canvas check exit 4: retry with --frames <ids>. Command reference.

Internal docs — onedot-devkit · devkit

devkitdevkit syncdevkit statusdevkit doctordevkit helpInternal docs · ONEDOT digital crew