[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M72TQG2THG1665YMKA8R9JHF":3,"skill-same:01M72TQG2THG1665YMKA8R9JHF":64},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":24,"commitSha":25,"skillDirectory":26,"forksCount":27,"repositoryHtmlUrl":28,"repositoryHomepageUrl":6,"ownerHtmlUrl":29,"ownerBlogUrl":30,"ownerDescription":6,"updatedAt":31,"install":32,"resources":45},"01M72TQG2THG1665YMKA8R9JHF","boceto",null,"Author hand-drawn wireframe mockups in the Boceto DSL — a compact fenced-code-block-friendly grammar that renders to sketchy SVG \u002F canvas. Use this skill whenever the user asks to \"sketch a wireframe\", \"mock up a screen\", \"show a UI for X\", \"wireframe Y\", design a login \u002F dashboard \u002F mobile \u002F settings \u002F marketing layout, or any mention of @boceto, boceto-view, boceto-edit, .boceto files, or fenced ```boceto blocks. Also use it when the user asks Claude to add to or edit an existing Boceto mockup, even when they only describe the change (\"add a search bar at the top\"). If the `boceto` MCP server is connected, prefer its tools (`boceto_lint`, `boceto_describe_element`, `boceto_list_recipes`, `boceto_read_recipe`, `boceto_render_svg`) over reading the local references — it's the fastest path to verified output.","maravilla-labs\u002Fboceto","maravilla-labs","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F227340211?v=4","01M72TQC4EWR6ZJP7FP9ZDVW68","Maravilla Labs","01M72TQC5MC89T0GP7TWDWMC5C",1,"MIT","https:\u002F\u002Fgithub.com\u002Fmaravilla-labs\u002Fboceto\u002Fblob\u002Fmain\u002Fskill\u002Fboceto\u002FSKILL.md",[],[],"2026-11-10 22:39:42",false,"---\nname: boceto\ndescription: Author hand-drawn wireframe mockups in the Boceto DSL — a compact fenced-code-block-friendly grammar that renders to sketchy SVG \u002F canvas. Use this skill whenever the user asks to \"sketch a wireframe\", \"mock up a screen\", \"show a UI for X\", \"wireframe Y\", design a login \u002F dashboard \u002F mobile \u002F settings \u002F marketing layout, or any mention of @boceto, boceto-view, boceto-edit, .boceto files, or fenced ```boceto blocks. Also use it when the user asks Claude to add to or edit an existing Boceto mockup, even when they only describe the change (\"add a search bar at the top\"). If the `boceto` MCP server is connected, prefer its tools (`boceto_lint`, `boceto_describe_element`, `boceto_list_recipes`, `boceto_read_recipe`, `boceto_render_svg`) over reading the local references — it's the fastest path to verified output.\n---\n\n# Boceto — wireframe mockup DSL\n\nBoceto is a tiny grammar for hand-drawn wireframes. One line per element, integer coordinates, sketchy SVG \u002F canvas output. Designed to live inside fenced markdown code blocks so PRs, docs, and design reviews can carry wireframes as plain text.\n\n## What this skill teaches\n\nThis skill is the **authoring philosophy** layer — the rules, do's & don'ts, and the literate output pattern. The data (element catalog, per-element attrs, recipes you can pattern-match against) lives in the `boceto` MCP server when it's connected, or in the bundled references otherwise. Don't memorise the catalog; fetch it on demand.\n\n## Output contract\n\nWhen asked for a mockup, return a single fenced `​```boceto:PageName` block. Use `​```boceto` (no page name) if it's a snippet rather than a full page. Coords are non-negative integers (pixels). Typical sizes: 600–1100 wide for desktop, 320–420 wide for mobile.\n\n```boceto:Login\nelement navbar       0   0 600 44 \"MyApp\"\nelement heading    100  90 400 32 \"Welcome back\"\nelement input      100 170 400 36 \"Email address\"\nelement input      100 216 400 36 \"Password\"\nelement primary-button 100 264 400 36 \"Sign In\"\n```\n\nDon't wrap the block in extra prose unless the user asked for narration.\n\n**Per-fence viewport hints.** When the mockup targets a non-default canvas size, append `width=N height=N` (and optionally `fit=fixed`) to the fence info — e.g. ` ```boceto:Mobile width=320 height=640 ` for a phone screen or ` ```boceto:Showcase fit=fixed width=1280 height=800 ` for a pinned desktop showcase. These are SVG-only render hints consumed by the remark \u002F markdown-it plugins; they don't change the parsed doc. Default is `fit=content` (auto-size), so most mockups need no hints at all. See `references\u002Fgrammar.md` for the full list of recognised keys.\n\n**When the output includes a `component` definition**, follow the literate component-doc pattern — heading, description, definition block, example usage block, \"Used in\" line. See `references\u002Fcomponent-doc-pattern.md`. Skipping this is fine for one-off mockups; reach for it whenever you're producing reusable components.\n\n## The non-negotiables\n\nThese are the failure modes the parser is strictest about — guard against them up front.\n\n### 1. Six positional slots on every `element` line\n\n```\nelement TYPE[#id]   X   Y   W   H   \"Label\"   [key=value …]\n```\n\nThe label slot is **always required**, even when the element shows no visible text — use `\"\"` for chrome:\n\n```\nelement chart-bar       232 110 600 260 \"\"\nelement status-bar       20  12 320  24 \"\"\nelement home-indicator   20 700 320   8 \"\"\nelement divider           0  40 600   1 \"\"\nelement fab             288 632  56  56 \"+\"\nelement spinner           0   0  32  32 \"\"\nelement table            10  10 320 180 \"\"        headers=\"A|B|C\"\n```\n\nDrop the label slot and the parser rejects the line with `'element' requires: TYPE X Y W H \"label\" (got 5 args)`. **This is the #1 reason AI-generated Boceto fails to render.** The same applies to composite call sites: `element my-card 0 0 200 60 \"\" title=\"X\"`.\n\n### 2. Use only canonical element types — never invent\n\nElement types are **always lowercase, kebab-cased** (`primary-button`, `chart-bar`, `phone-frame`). The full list is the catalog. To look something up:\n\n- **With MCP**: `boceto_list_elements()` returns every type by category; `boceto_describe_element(type)` returns one's defaults and attribute schema.\n- **Without MCP**: read the local `references\u002Felements.md` if it's bundled, otherwise reach for the closest type from the hallucination map below.\n\nCommon AI hallucinations map to canonical types:\n\n| If you'd write… | Use this instead |\n|---|---|\n| `Frame`, `Container`, `Section` | `box` (generic) or `card` |\n| `Stack`, `VStack`, `HStack`, `Group` | `row` or `col` |\n| `Heading2`, `H1`, `H2`, `Subheading` | `heading` (vary via `fontSize=`) |\n| `Header`, `PageHeader` | `box` at top, or `navbar` for global nav |\n| `NavBar`, `TopBar`, `AppBar`, `MenuBar`, `nav` | `navbar` |\n| `Tab`, `TabBar` | `tabs` |\n| `Icon`, `IconButton`, `icon-button` | `button` (small, e.g. 32×32) |\n| `Pill`, `Tag` | `chip` or `badge` |\n| `Link`, `TextLink` | small `button`, or styled `label` |\n| `Card`, `Panel` (capitalised) | `card`, `panel` (lower-case) |\n| `PhoneFrame`, `StatusBar`, `HomeIndicator` | `phone-frame`, `status-bar`, `home-indicator` |\n| `FAB`, `FloatingButton` | `fab` |\n| `Spacer`, `Divider` | `divider` |\n\nIf a name isn't here and isn't in the catalog, **don't emit it.** Either pick the closest canonical primitive or — better — define a composite `component` named after what the user asked for.\n\n### 3. Integers, quoted labels, balanced blocks\n\n- **Coords are non-negative integers.** No decimals, no negatives. Round before emitting.\n- **Labels are double-quoted.** Inside: `\\\"`, `\\\\`, `\\n`, `\\t` are the only escapes. `\\n` is a real newline (used by `textarea`, `alert`, `chat-bubble`).\n- **`row` \u002F `col` \u002F `component`** open with `:` and close with `end`. Don't leave a block dangling.\n- **Use `textAlign=`, not `align=`,** for text alignment. `align=` is the flex container attr (`start|middle|end|stretch`) and gets misparsed on non-container elements.\n\n### 4. `row` \u002F `col` need four positional slots\n\nContainers have the **same arity as elements minus the label**:\n\n```\nrow[#id]   X Y W|auto H|auto   [attrs] :\ncol[#id]   X Y W|auto H|auto   [attrs] :\n```\n\n`row padding=20 gap=12` alone fails — `row` needs `X Y W H` *before* any attrs. Use `0` or `auto` when you don't care about a coordinate (`auto` for W\u002FH means \"size to children\"; `0` for X\u002FY means \"no preferred position, defer to parent layout\").\n\n### 5. Components — defined once per page\n\nInside a page, the same `component foo(…) … end` definition appears in **exactly one fenced block**. Every other block (example usage, downstream mockup) calls it by name. Re-pasting the definition across blocks fails with `Duplicate component definition`.\n\n## Authoring philosophy — components-first\n\nBoceto is small but expressive. Before placing raw boxes, ask:\n\n1. **Is what they want already an element type?** Check the catalog (MCP `boceto_list_elements` or `references\u002Felements.md` if bundled). If yes, use it directly.\n2. **Is it an obvious composition of 2–4 primitives?** A \"metric tile\" is a `card` + small `label` + big `heading`. A \"feature card\" is a `card` + `heading` + `label`. Define these as `component`s and the page-level DSL stays short. **Never invent a type** — composing primitives under a new component name is always the right move.\n3. **Is it a category of screen** (\"a dashboard\", \"a settings page\", \"a mobile app\") rather than a one-off layout? Define a shell `component` (`appshell`, `phoneshell`, `auth-shell`) and place concrete content inside it via slots.\n\nRule of thumb: if the same shape appears 3+ times, or the user is sketching a \"category of screen\" rather than a one-off page, **componentize**. The result is shorter DSL, easier diffs, and a vocabulary the user can extend (\"add another metric card\" not \"add another 6-line block\").\n\n### Params vs slots\n\nComposite components have two ways to vary content per call site:\n\n- **Params** (`component foo(title, value)` + `$title`) — for scalar inputs: titles, values, item lists (pipe-separated). The call site sets them as `key=value` attrs.\n- **Slots** (`slot` or `slot NAME` in the body) — for DSL-shaped inputs: a body, a row of actions, anything that's multiple `element` lines. The call site supplies the fill via a children block at its trailing `:`.\n\nA reusable shell typically uses **both** — params for chrome strings, slots for body content. If a shell has more than one fill region (body + footer, header actions + content), use **named slots**; templates that only support one fill point feel cramped fast.\n\n```boceto\ncomponent dialog(title)\n  element box     0   0 400 220 \"\"\n  element heading 20  16 360  28 \"$title\"\n  element divider 20  50 360   1 \"\"\n  slot                                  # default — dialog body\n  element divider 20 168 360   1 \"\"\n  slot actions                          # named — bottom-right button row\nend\n\nelement dialog 100 80 400 220 \"\" title=\"Confirm delete\" :\n  element label 20 64 360 90 \"This will permanently delete the project. Are you sure?\"\n  slot actions\n    element button         200 180 80 28 \"Cancel\"\n    element primary-button 290 180 80 28 \"Delete\"\n  end\nend\n```\n\n### Three parser limitations worth knowing\n\n- **`slot` markers must be top-level in a component body** — never nested inside `row` \u002F `col`. (Workaround: place the slot statement at the body's top level, position via absolute coords.)\n- **Element-as-container (`element foo 0 0 W H \"\" :`) can't be used inside a component body** — only at the page level. Inside components, use `row` \u002F `col` or absolute positioning.\n- **Component param names follow JS identifier rules** — no hyphens. Use `navItems` not `nav-items`.\n\n## Flex layout — the 80% rules inline\n\nThe agent shouldn't need to load `references\u002Flayout.md` for the common cases — here are the high-leverage flex rules:\n\n**Containers** (`row` \u002F `col`) — flow children left→right or top→bottom. Both accept these attrs after `X Y W H`:\n\n| Attr | Values | Default | What it does |\n|---|---|---|---|\n| `gap` | integer | `0` | pixels between adjacent children |\n| `padding` | integer | `0` | inner padding on all four edges |\n| `justify` | `start` · `middle` · `end` · `between` · `around` · `evenly` | `start` | main-axis distribution |\n| `align` | `start` · `middle` · `end` · `stretch` | row: `middle`, col: `start` | cross-axis alignment |\n| `wrap` | `nowrap` · `wrap` · `wrap-reverse` | `nowrap` | line-wrapping behaviour |\n\n**Children** inside a flex container — set these on the children, not the container:\n\n| Attr | Values | Default | What it does |\n|---|---|---|---|\n| `grow` | number | `0` | share of remaining space the child claims |\n| `shrink` | number | `1` | how much the child shrinks under tight space |\n| `basis` | integer · `auto` | `auto` | preferred main-axis size before grow\u002Fshrink |\n| `align-self` | `auto` · `start` · `middle` · `end` · `stretch` | `auto` | overrides container's `align` for this one child |\n| `min-w` \u002F `min-h` \u002F `max-w` \u002F `max-h` | integer | unset | bounds on the child's final box |\n\n**Sizing semantics:**\n\n- Use `auto` in W or H when the container should size to its children (`row 20 20 auto auto …`).\n- A child's `X` slot is its preferred main-axis size when inside a flex container. `0` means \"no preference — defer to basis \u002F grow \u002F stretch\".\n- Common pattern: a row with one input that fills the gap — set the input's W to `0` (no preference) and `grow=1`:\n\n```boceto\nrow 20 80 600 36 gap=8 align=middle\n  element label  0 0  80 22 \"Email\"\n  element input  0 0   0 36 \"\" grow=1\n  element button 0 0  80 36 \"Send\"\nend\n```\n\n**Element-as-container**: any element can host children via a trailing `:` (e.g. `element card 0 0 400 280 \"Sign in\" :`). Without `direction=`, the children's `(x, y)` are absolute inside the card's content rect. With `direction=col gap=8 padding=12`, the element becomes a flex container while keeping its chrome.\n\nReach for `references\u002Flayout.md` only when you need wrap-as-grid behaviour, deep flex nesting, or the full alignment reference table — the above is enough for 80% of mockups.\n\n## When the `boceto` MCP server is connected\n\nThese tools are the fastest path to verified output — call them instead of guessing or reading the local refs:\n\n| Tool | When |\n|---|---|\n| `boceto_list_recipes` | Starting a new mockup. Returns every recipe + summary. Skim the list, pick the closest match. |\n| `boceto_read_recipe(slug)` | Once you've picked a recipe — returns the full source block to adapt from. |\n| `boceto_list_elements` | Picking an element type. Returns the catalog grouped by category. |\n| `boceto_describe_element(type)` | Choosing per-element attrs (table headers, chart data, dropdown items). |\n| `boceto_lint(source)` | Before returning your output. Reports line + column for every issue and an autofixed copy of the source. Run this on what you produced — if the linter found errors, ship the `fixed` source instead. |\n| `boceto_render_svg(source)` | When the user wants to see the result inline — produces a self-contained SVG. |\n\nRecipe slugs follow the catalog: full-page mockups (`login`, `signup`, `dashboard`, `chat`, `pricing-comparison`, …) and reusable shells (`appshell`, `dialog`, `kanban-column`, `metric-card`, `panel`, …). The `index` recipe contains the decision guide and adaptation patterns.\n\nThe lint-before-ship cycle is non-negotiable when MCP is available — it costs one tool call and catches the six-slot rule, invented types, fractional coords, and unclosed blocks before the user sees the output.\n\n## When MCP is not connected\n\nThe skill ships with two reference files:\n\n- **`references\u002Fgrammar.md`** — formal tokens, escape sequences, IDs, attribute syntax, multi-page docs, component header attributes.\n- **`references\u002Flayout.md`** — `row` \u002F `col` flex semantics, `auto` sizing, `grow` \u002F `shrink`, alignment, wrap-as-grid, element-as-container.\n\nFor the **element catalog** and **recipes**, you'll need to rely on your training knowledge of the spec — the canonical types listed in the hallucination map above cover the most common needs. When in doubt, fall back to primitives: `box`, `card`, `heading`, `label`, `input`, `button`, `primary-button`, `divider`, `navbar`, `sidebar`. These cover ~70% of mockups.\n\n## Iterating on an existing mockup\n\nWhen the user asks to *edit* a mockup rather than create one, return the full updated `​```boceto…​```` block — not a diff, not a partial. Preserve their IDs, attributes, and layout patterns. Only change what's needed. If the input block had any defects (missing labels, invented types, fractional coords), fix them in the output — don't propagate the bug.\n\nIf MCP is connected, run `boceto_lint` on the result before returning.\n\n## Quick checklist before you commit your output\n\n1. **Six positional slots on every `element` line** — `element TYPE X Y W H \"Label\"`. Empty `\"\"` for chrome.\n2. **Four positional slots on every `row` \u002F `col` line** — `row X Y W H` (or `auto` for W\u002FH). Attrs follow.\n3. Every line starts with `element`, `text`, `arrow`, `row`, `col`, `end`, `component`, or `slot`.\n4. Coords are integers ≥ 0.\n5. Labels are quoted; multi-line labels use `\\n` inside the quotes.\n6. Element types are canonical (lowercase, kebab-case, from the catalog).\n7. `row` \u002F `col` \u002F `component` blocks closed with `end`.\n8. The block opens with `​```boceto` or `​```boceto:PageName`.\n9. **If you defined a `component`, the definition appears in exactly one fenced block**. Subsequent blocks call it by name — they do NOT re-paste the definition.\n10. If the output includes a `component` definition, the surrounding markdown uses the literate component-doc pattern (`references\u002Fcomponent-doc-pattern.md`).\n11. If MCP is connected, you ran `boceto_lint` and shipped the `fixed` source if it found anything.\n","# Boceto — wireframe mockup DSL\n\nBoceto is a tiny grammar for hand-drawn wireframes. One line per element, integer coordinates, sketchy SVG \u002F canvas output. Designed to live inside fenced markdown code blocks so PRs, docs, and design reviews can carry wireframes as plain text.\n\n## What this skill teaches\n\nThis skill is the **authoring philosophy** layer — the rules, do's & don'ts, and the literate output pattern. The data (element catalog, per-element attrs, recipes you can pattern-match against) lives in the `boceto` MCP server when it's connected, or in the bundled references otherwise. Don't memorise the catalog; fetch it on demand.\n\n## Output contract\n\nWhen asked for a mockup, return a single fenced `​```boceto:PageName` block. Use `​```boceto` (no page name) if it's a snippet rather than a full page. Coords are non-negative integers (pixels). Typical sizes: 600–1100 wide for desktop, 320–420 wide for mobile.\n\n```boceto:Login\nelement navbar       0   0 600 44 \"MyApp\"\nelement heading    100  90 400 32 \"Welcome back\"\nelement input      100 170 400 36 \"Email address\"\nelement input      100 216 400 36 \"Password\"\nelement primary-button 100 264 400 36 \"Sign In\"\n```\n\nDon't wrap the block in extra prose unless the user asked for narration.\n\n**Per-fence viewport hints.** When the mockup targets a non-default canvas size, append `width=N height=N` (and optionally `fit=fixed`) to the fence info — e.g. ` ```boceto:Mobile width=320 height=640 ` for a phone screen or ` ```boceto:Showcase fit=fixed width=1280 height=800 ` for a pinned desktop showcase. These are SVG-only render hints consumed by the remark \u002F markdown-it plugins; they don't change the parsed doc. Default is `fit=content` (auto-size), so most mockups need no hints at all. See `references\u002Fgrammar.md` for the full list of recognised keys.\n\n**When the output includes a `component` definition**, follow the literate component-doc pattern — heading, description, definition block, example usage block, \"Used in\" line. See `references\u002Fcomponent-doc-pattern.md`. Skipping this is fine for one-off mockups; reach for it whenever you're producing reusable components.\n\n## The non-negotiables\n\nThese are the failure modes the parser is strictest about — guard against them up front.\n\n### 1. Six positional slots on every `element` line\n\n```\nelement TYPE[#id]   X   Y   W   H   \"Label\"   [key=value …]\n```\n\nThe label slot is **always required**, even when the element shows no visible text — use `\"\"` for chrome:\n\n```\nelement chart-bar       232 110 600 260 \"\"\nelement status-bar       20  12 320  24 \"\"\nelement home-indicator   20 700 320   8 \"\"\nelement divider           0  40 600   1 \"\"\nelement fab             288 632  56  56 \"+\"\nelement spinner           0   0  32  32 \"\"\nelement table            10  10 320 180 \"\"        headers=\"A|B|C\"\n```\n\nDrop the label slot and the parser rejects the line with `'element' requires: TYPE X Y W H \"label\" (got 5 args)`. **This is the #1 reason AI-generated Boceto fails to render.** The same applies to composite call sites: `element my-card 0 0 200 60 \"\" title=\"X\"`.\n\n### 2. Use only canonical element types — never invent\n\nElement types are **always lowercase, kebab-cased** (`primary-button`, `chart-bar`, `phone-frame`). The full list is the catalog. To look something up:\n\n- **With MCP**: `boceto_list_elements()` returns every type by category; `boceto_describe_element(type)` returns one's defaults and attribute schema.\n- **Without MCP**: read the local `references\u002Felements.md` if it's bundled, otherwise reach for the closest type from the hallucination map below.\n\nCommon AI hallucinations map to canonical types:\n\n| If you'd write… | Use this instead |\n|---|---|\n| `Frame`, `Container`, `Section` | `box` (generic) or `card` |\n| `Stack`, `VStack`, `HStack`, `Group` | `row` or `col` |\n| `Heading2`, `H1`, `H2`, `Subheading` | `heading` (vary via `fontSize=`) |\n| `Header`, `PageHeader` | `box` at top, or `navbar` for global nav |\n| `NavBar`, `TopBar`, `AppBar`, `MenuBar`, `nav` | `navbar` |\n| `Tab`, `TabBar` | `tabs` |\n| `Icon`, `IconButton`, `icon-button` | `button` (small, e.g. 32×32) |\n| `Pill`, `Tag` | `chip` or `badge` |\n| `Link`, `TextLink` | small `button`, or styled `label` |\n| `Card`, `Panel` (capitalised) | `card`, `panel` (lower-case) |\n| `PhoneFrame`, `StatusBar`, `HomeIndicator` | `phone-frame`, `status-bar`, `home-indicator` |\n| `FAB`, `FloatingButton` | `fab` |\n| `Spacer`, `Divider` | `divider` |\n\nIf a name isn't here and isn't in the catalog, **don't emit it.** Either pick the closest canonical primitive or — better — define a composite `component` named after what the user asked for.\n\n### 3. Integers, quoted labels, balanced blocks\n\n- **Coords are non-negative integers.** No decimals, no negatives. Round before emitting.\n- **Labels are double-quoted.** Inside: `\\\"`, `\\\\`, `\\n`, `\\t` are the only escapes. `\\n` is a real newline (used by `textarea`, `alert`, `chat-bubble`).\n- **`row` \u002F `col` \u002F `component`** open with `:` and close with `end`. Don't leave a block dangling.\n- **Use `textAlign=`, not `align=`,** for text alignment. `align=` is the flex container attr (`start|middle|end|stretch`) and gets misparsed on non-container elements.\n\n### 4. `row` \u002F `col` need four positional slots\n\nContainers have the **same arity as elements minus the label**:\n\n```\nrow[#id]   X Y W|auto H|auto   [attrs] :\ncol[#id]   X Y W|auto H|auto   [attrs] :\n```\n\n`row padding=20 gap=12` alone fails — `row` needs `X Y W H` *before* any attrs. Use `0` or `auto` when you don't care about a coordinate (`auto` for W\u002FH means \"size to children\"; `0` for X\u002FY means \"no preferred position, defer to parent layout\").\n\n### 5. Components — defined once per page\n\nInside a page, the same `component foo(…) … end` definition appears in **exactly one fenced block**. Every other block (example usage, downstream mockup) calls it by name. Re-pasting the definition across blocks fails with `Duplicate component definition`.\n\n## Authoring philosophy — components-first\n\nBoceto is small but expressive. Before placing raw boxes, ask:\n\n1. **Is what they want already an element type?** Check the catalog (MCP `boceto_list_elements` or `references\u002Felements.md` if bundled). If yes, use it directly.\n2. **Is it an obvious composition of 2–4 primitives?** A \"metric tile\" is a `card` + small `label` + big `heading`. A \"feature card\" is a `card` + `heading` + `label`. Define these as `component`s and the page-level DSL stays short. **Never invent a type** — composing primitives under a new component name is always the right move.\n3. **Is it a category of screen** (\"a dashboard\", \"a settings page\", \"a mobile app\") rather than a one-off layout? Define a shell `component` (`appshell`, `phoneshell`, `auth-shell`) and place concrete content inside it via slots.\n\nRule of thumb: if the same shape appears 3+ times, or the user is sketching a \"category of screen\" rather than a one-off page, **componentize**. The result is shorter DSL, easier diffs, and a vocabulary the user can extend (\"add another metric card\" not \"add another 6-line block\").\n\n### Params vs slots\n\nComposite components have two ways to vary content per call site:\n\n- **Params** (`component foo(title, value)` + `$title`) — for scalar inputs: titles, values, item lists (pipe-separated). The call site sets them as `key=value` attrs.\n- **Slots** (`slot` or `slot NAME` in the body) — for DSL-shaped inputs: a body, a row of actions, anything that's multiple `element` lines. The call site supplies the fill via a children block at its trailing `:`.\n\nA reusable shell typically uses **both** — params for chrome strings, slots for body content. If a shell has more than one fill region (body + footer, header actions + content), use **named slots**; templates that only support one fill point feel cramped fast.\n\n```boceto\ncomponent dialog(title)\n  element box     0   0 400 220 \"\"\n  element heading 20  16 360  28 \"$title\"\n  element divider 20  50 360   1 \"\"\n  slot                                  # default — dialog body\n  element divider 20 168 360   1 \"\"\n  slot actions                          # named — bottom-right button row\nend\n\nelement dialog 100 80 400 220 \"\" title=\"Confirm delete\" :\n  element label 20 64 360 90 \"This will permanently delete the project. Are you sure?\"\n  slot actions\n    element button         200 180 80 28 \"Cancel\"\n    element primary-button 290 180 80 28 \"Delete\"\n  end\nend\n```\n\n### Three parser limitations worth knowing\n\n- **`slot` markers must be top-level in a component body** — never nested inside `row` \u002F `col`. (Workaround: place the slot statement at the body's top level, position via absolute coords.)\n- **Element-as-container (`element foo 0 0 W H \"\" :`) can't be used inside a component body** — only at the page level. Inside components, use `row` \u002F `col` or absolute positioning.\n- **Component param names follow JS identifier rules** — no hyphens. Use `navItems` not `nav-items`.\n\n## Flex layout — the 80% rules inline\n\nThe agent shouldn't need to load `references\u002Flayout.md` for the common cases — here are the high-leverage flex rules:\n\n**Containers** (`row` \u002F `col`) — flow children left→right or top→bottom. Both accept these attrs after `X Y W H`:\n\n| Attr | Values | Default | What it does |\n|---|---|---|---|\n| `gap` | integer | `0` | pixels between adjacent children |\n| `padding` | integer | `0` | inner padding on all four edges |\n| `justify` | `start` · `middle` · `end` · `between` · `around` · `evenly` | `start` | main-axis distribution |\n| `align` | `start` · `middle` · `end` · `stretch` | row: `middle`, col: `start` | cross-axis alignment |\n| `wrap` | `nowrap` · `wrap` · `wrap-reverse` | `nowrap` | line-wrapping behaviour |\n\n**Children** inside a flex container — set these on the children, not the container:\n\n| Attr | Values | Default | What it does |\n|---|---|---|---|\n| `grow` | number | `0` | share of remaining space the child claims |\n| `shrink` | number | `1` | how much the child shrinks under tight space |\n| `basis` | integer · `auto` | `auto` | preferred main-axis size before grow\u002Fshrink |\n| `align-self` | `auto` · `start` · `middle` · `end` · `stretch` | `auto` | overrides container's `align` for this one child |\n| `min-w` \u002F `min-h` \u002F `max-w` \u002F `max-h` | integer | unset | bounds on the child's final box |\n\n**Sizing semantics:**\n\n- Use `auto` in W or H when the container should size to its children (`row 20 20 auto auto …`).\n- A child's `X` slot is its preferred main-axis size when inside a flex container. `0` means \"no preference — defer to basis \u002F grow \u002F stretch\".\n- Common pattern: a row with one input that fills the gap — set the input's W to `0` (no preference) and `grow=1`:\n\n```boceto\nrow 20 80 600 36 gap=8 align=middle\n  element label  0 0  80 22 \"Email\"\n  element input  0 0   0 36 \"\" grow=1\n  element button 0 0  80 36 \"Send\"\nend\n```\n\n**Element-as-container**: any element can host children via a trailing `:` (e.g. `element card 0 0 400 280 \"Sign in\" :`). Without `direction=`, the children's `(x, y)` are absolute inside the card's content rect. With `direction=col gap=8 padding=12`, the element becomes a flex container while keeping its chrome.\n\nReach for `references\u002Flayout.md` only when you need wrap-as-grid behaviour, deep flex nesting, or the full alignment reference table — the above is enough for 80% of mockups.\n\n## When the `boceto` MCP server is connected\n\nThese tools are the fastest path to verified output — call them instead of guessing or reading the local refs:\n\n| Tool | When |\n|---|---|\n| `boceto_list_recipes` | Starting a new mockup. Returns every recipe + summary. Skim the list, pick the closest match. |\n| `boceto_read_recipe(slug)` | Once you've picked a recipe — returns the full source block to adapt from. |\n| `boceto_list_elements` | Picking an element type. Returns the catalog grouped by category. |\n| `boceto_describe_element(type)` | Choosing per-element attrs (table headers, chart data, dropdown items). |\n| `boceto_lint(source)` | Before returning your output. Reports line + column for every issue and an autofixed copy of the source. Run this on what you produced — if the linter found errors, ship the `fixed` source instead. |\n| `boceto_render_svg(source)` | When the user wants to see the result inline — produces a self-contained SVG. |\n\nRecipe slugs follow the catalog: full-page mockups (`login`, `signup`, `dashboard`, `chat`, `pricing-comparison`, …) and reusable shells (`appshell`, `dialog`, `kanban-column`, `metric-card`, `panel`, …). The `index` recipe contains the decision guide and adaptation patterns.\n\nThe lint-before-ship cycle is non-negotiable when MCP is available — it costs one tool call and catches the six-slot rule, invented types, fractional coords, and unclosed blocks before the user sees the output.\n\n## When MCP is not connected\n\nThe skill ships with two reference files:\n\n- **`references\u002Fgrammar.md`** — formal tokens, escape sequences, IDs, attribute syntax, multi-page docs, component header attributes.\n- **`references\u002Flayout.md`** — `row` \u002F `col` flex semantics, `auto` sizing, `grow` \u002F `shrink`, alignment, wrap-as-grid, element-as-container.\n\nFor the **element catalog** and **recipes**, you'll need to rely on your training knowledge of the spec — the canonical types listed in the hallucination map above cover the most common needs. When in doubt, fall back to primitives: `box`, `card`, `heading`, `label`, `input`, `button`, `primary-button`, `divider`, `navbar`, `sidebar`. These cover ~70% of mockups.\n\n## Iterating on an existing mockup\n\nWhen the user asks to *edit* a mockup rather than create one, return the full updated `​```boceto…​```` block — not a diff, not a partial. Preserve their IDs, attributes, and layout patterns. Only change what's needed. If the input block had any defects (missing labels, invented types, fractional coords), fix them in the output — don't propagate the bug.\n\nIf MCP is connected, run `boceto_lint` on the result before returning.\n\n## Quick checklist before you commit your output\n\n1. **Six positional slots on every `element` line** — `element TYPE X Y W H \"Label\"`. Empty `\"\"` for chrome.\n2. **Four positional slots on every `row` \u002F `col` line** — `row X Y W H` (or `auto` for W\u002FH). Attrs follow.\n3. Every line starts with `element`, `text`, `arrow`, `row`, `col`, `end`, `component`, or `slot`.\n4. Coords are integers ≥ 0.\n5. Labels are quoted; multi-line labels use `\\n` inside the quotes.\n6. Element types are canonical (lowercase, kebab-case, from the catalog).\n7. `row` \u002F `col` \u002F `component` blocks closed with `end`.\n8. The block opens with `​```boceto` or `​```boceto:PageName`.\n9. **If you defined a `component`, the definition appears in exactly one fenced block**. Subsequent blocks call it by name — they do NOT re-paste the definition.\n10. If the output includes a `component` definition, the surrounding markdown uses the literate component-doc pattern (`references\u002Fcomponent-doc-pattern.md`).\n11. If MCP is connected, you ran `boceto_lint` and shipped the `fixed` source if it found anything.\n",{"name":5,"description":7},"main","06f13b3ca276fdc579d940185e104b030c9c0b5f","skill\u002Fboceto",0,"https:\u002F\u002Fgithub.com\u002Fmaravilla-labs\u002Fboceto","https:\u002F\u002Fgithub.com\u002Fmaravilla-labs","https:\u002F\u002Fwww.maravillalabs.com","2026-05-19 04:08:49",{"source":8,"skillName":5,"commands":33,"prompt":43,"zipAvailable":44},[34,37,40],{"tool":35,"command":36},"npx","npx skills add maravilla-labs\u002Fboceto --skill boceto",{"tool":38,"command":39},"bunx","bunx skills add maravilla-labs\u002Fboceto --skill boceto",{"tool":41,"command":42},"pnpm","pnpm dlx skills add maravilla-labs\u002Fboceto --skill boceto","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fmaravilla-labs\u002Fboceto\u002Fblob\u002Fmain\u002Fskill\u002Fboceto\u002FSKILL.md",true,[46,52,56,60],{"path":47,"resourceType":48,"resourceTypeDesc":49,"sizeBytes":50,"sourceHtmlUrl":51},"evals\u002Fevals.json","REFERENCE","参考文档",2340,"https:\u002F\u002Fgithub.com\u002Fmaravilla-labs\u002Fboceto\u002Fblob\u002Fmain\u002Fskill\u002Fboceto\u002Fevals\u002Fevals.json",{"path":53,"resourceType":48,"resourceTypeDesc":49,"sizeBytes":54,"sourceHtmlUrl":55},"references\u002Fcomponent-doc-pattern.md",5396,"https:\u002F\u002Fgithub.com\u002Fmaravilla-labs\u002Fboceto\u002Fblob\u002Fmain\u002Fskill\u002Fboceto\u002Freferences\u002Fcomponent-doc-pattern.md",{"path":57,"resourceType":48,"resourceTypeDesc":49,"sizeBytes":58,"sourceHtmlUrl":59},"references\u002Fgrammar.md",9110,"https:\u002F\u002Fgithub.com\u002Fmaravilla-labs\u002Fboceto\u002Fblob\u002Fmain\u002Fskill\u002Fboceto\u002Freferences\u002Fgrammar.md",{"path":61,"resourceType":48,"resourceTypeDesc":49,"sizeBytes":62,"sourceHtmlUrl":63},"references\u002Flayout.md",6304,"https:\u002F\u002Fgithub.com\u002Fmaravilla-labs\u002Fboceto\u002Fblob\u002Fmain\u002Fskill\u002Fboceto\u002Freferences\u002Flayout.md",[65],{"skillNo":66,"name":67,"nameZh":6,"description":68,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":69,"categories":70,"keywords":71,"publishedAt":19},"01M72TQENVAVB51J10PWD09CN9","boceto-test","fixture skill content for cli unit tests","https:\u002F\u002Fgithub.com\u002Fmaravilla-labs\u002Fboceto\u002Fblob\u002Fmain\u002Fpackages\u002Fcli\u002Ftest\u002Ffixtures\u002Fskill\u002FSKILL.md",[],[]]