write-ui

write-ui is a skill for Claude Code from leifericf/agentic-sdk. It costs 46 tokens per session (2,686 once invoked), scanned A, original, MIT.

A guide for building user interfaces as structured data, including layout, interaction handling, widgets, and rendering. It treats the UI logic separately from the code that draws it on screen.

In plain words
What is it for?
Use it when adding or changing screens, layouts, widgets, hit testing, or rendering behavior.
Why use it?
It keeps interface behavior predictable and makes layout and interaction logic easier to test and change.

Skill for Claude Code

Written for Claude Code: user-invocable in frontmatter.

Good fit Use it when adding or changing screens, layouts, widgets, hit testing, or rendering behavior.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/leifericf/agentic-sdk/write-ui
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add leifericf/agentic-sdk --skill write-ui
Clone the repo
git clone --depth 1 https://github.com/leifericf/agentic-sdk

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for write-ui

README.md
[![agentmods](https://agentmods.dev/badge/skills/leifericf/agentic-sdk/write-ui.svg)](https://agentmods.dev/skills/leifericf/agentic-sdk/write-ui)
Your own site
<a href="https://agentmods.dev/skills/leifericf/agentic-sdk/write-ui"><img src="https://agentmods.dev/badge/skills/leifericf/agentic-sdk/write-ui.svg" alt="Measured on agentmods" height="20"></a>
Per session 46 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,686 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00046 $0.02686
Opus 5 $0.00023 $0.01343
Sonnet 5 $0.00009 $0.00537
Haiku 4.5 $0.00005 $0.00269

Measured 4d ago against content hash 9195b4a1cd2c, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-08, from the pricing page.

Security

Grade A, and why

write-ui scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 4d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/write-ui/SKILL.md · 226 lines

How it starts

The opening of the file, as written. The whole thing — 226 lines — stays where its author put it; the contents beside it link to each section on GitHub.

write-ui

Write the UI for the project. The UI core is pure data transformation: it takes the application state and returns a view-spec, lays it out, and resolves hits, all as data. The renderer sits at the edge and consumes the positioned view-spec. Read first:

  • the project's view-spec reference (the widget vocabulary, data shapes, event format, layout model, hit-testing). This is the concrete spec; this skill is the recipe for authoring against it.
  • the project's design-language reference (the principles, the token system, the component template, the state design every view must cover, and the design-review checklist).
  • the project's token catalog (spacing, type, color, depth, motion). The vocabulary the view-spec references; never inline a raw value.
  • skills/shared/references/architecture.md for the Functional Core / Imperative Shell split. The whole UI core lives in its pure core.
  • design-ui (sibling), the design-first recipe that produces the surface's design spec before this recipe implements it. Implement against the design spec; do not re-decide the design here.

Where UI code lives

The whole UI core is pure functions under the UI module. None do IO, hold an atom, read a clock, call native, or transact. Input arrives as data from the shell; the view-spec leaves as data for the shell to render. If you reach for a side effect in this module, the design is wrong: move the effect to the shell and keep the decision here.

The contract: view-spec is description, not instruction

The view-spec is the UI's intermediate representation. It describes what the UI is right now; it never tells the renderer how to draw. Hold to this:

  • Every widget is a plain map with a type and type-specific keys. No functions, no closures, no objects. A view-spec is serializable data: printable, diffable, testable, scriptable.
  • Events are data, not callbacks. Handlers are vectors of action data under an :on key. Late-binding values the UI cannot know yet use placeholder keys; the shell substitutes them when the event fires.
  • Re-derive the whole tree from the root each frame. No component-local state, no subtree subscriptions. All UI logic lives in one entry point; given the same state it returns the same view-spec.
  • Persistent structures, deliberately. Build the new view-spec by transforming the old state's data, so unchanged subtrees stay identical objects. The renderer's diff exploits this structural sharing; a rebuild that copies unchanged subtrees defeats it.

Read the full file on GitHub · 226 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 4d ago First seen · 226 lines · 46 tokens per session scan A 9195b4a1cd2c

Subscribe to this mod's changes

write-ui is a skill published in the GitHub repository leifericf/agentic-sdk (5 stars, last pushed 6d ago), licensed MIT. It adds 46 tokens to every session and 2,686 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

Other skills, from other repositories

chakra-ui-builder

Build responsive, accessible UI components and layouts using Chakra UI v3, install or configure Chakra UI in new and existing projects, and design scalable themes using tokens, semantic tokens, recipes, and slot recipes. Use this skill whenever a user asks to build, create, or generate any UI component, page, form…

chakra-ui/chakra-ui · 214 tokens

visual-ralph

Visual Ralph orchestration for frontend UI from generated references, static references, or live URL targets, using $ralph with built-in visual verdict and pixel-diff evidence until the implementation matches and leaves a reproducible design system.

Yeachan-Heo/oh-my-codex · 50 tokens

frontend-visual-qa

Audits already-rendered web, landing-page, HTML deck/slide, browser tool/game, dashboard/admin, design-system, and desktop UIs using real-browser or native-app journeys, inspected screenshots, DOM geometry, responsive or projection viewports, and a bundled Playwright sweep. Use after UI implementation to find…

daymade/claude-code-skills · 145 tokens

prototype-web

A clickable, high-fidelity web product prototype with navigation, a hero section, feature cards, steps, social proof, and optional pricing. It is designed to resemble a finished landing page while remaining a prototype.

nexu-io/html-anything · 24 tokens

animation-principles

Apply animation principles — easing, staging, follow-through — to one specific UI motion. Use when tuning how an animation feels. For product-wide duration and easing tokens use motion-system (design-systems); for a full interaction spec use micro-interaction-spec.

Owl-Listener/designer-skills · 59 tokens

refactoring-ui

Audit and fix visual hierarchy, spacing, color, and depth in web UIs. Use when the user mentions "my UI looks off" (or amateur/unprofessional), "fix the design", "Tailwind styling", "color palette", "visual hierarchy", "design system", "spacing scale", or "component styling". Also trigger when building consistent…

wondelai/skills · 132 tokens