ux-component

ux-component is a command for coding agents from Laith0003/ux-skill. It costs 105 tokens per session (2,762 once invoked), scanned A, original, MIT.

A command for creating one complete interface element, such as a button, modal window, navigation bar, sidebar, card, table, form, or chart, from a specification.

In plain words
What is it for?
Use it when you need a single component embedded in a larger product. For a full page or several sections, another page-design command is more suitable.
Why use it?
It provides a focused way to build one reusable part of an interface instead of generating a whole page. The component includes its interaction states and accessibility details.

Command

Part of the ux-skill plugin — 25 commands, 5 agents shipped together

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.

agentmods
npx agentmods add commands/laith0003/ux-skill/ux-component
Clone the repo
git clone --depth 1 https://github.com/Laith0003/ux-skill

Or install ux-skill, the plugin that ships this one along with the rest of its 25 commands, 5 agents.

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 ux-component

README.md
[![agentmods](https://agentmods.dev/badge/commands/laith0003/ux-skill/ux-component.svg)](https://agentmods.dev/commands/laith0003/ux-skill/ux-component)
Your own site
<a href="https://agentmods.dev/commands/laith0003/ux-skill/ux-component"><img src="https://agentmods.dev/badge/commands/laith0003/ux-skill/ux-component.svg" alt="Measured on agentmods" height="20"></a>
Per session 105 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 2,762 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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 $0.00105 $0.02762
Opus 5 $0.00053 $0.01381
Sonnet 5 $0.00021 $0.00552
Haiku 4.5 $0.00011 $0.00276

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

Security

Grade A, and why

ux-component 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.

commands/ux-component.md · 219 lines

How it starts

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

/ux-component

You are running the /ux-component command from the ux plugin. The job is to produce a single, production-grade component that avoids generic AI aesthetics. One component, fully realized — all four interaction states, accessible, on-brand.

When to use

Triggers: "build a button", "create a pricing card", "make a modal", "add a navbar", "design a sidebar", "I need a data table", "build a form", "make a chart component", or any single-element request.

If the user is asking for a full page or multi-section surface, hand off to /ux-design instead.

Process

0. Discovery protocol (MANDATORY)

Before anything else, read references/process/discovery-protocol.md and run its intake on the user. For components, focus on: brand identity, 2–3 references for the component type, audience, style direction, voice, stack, imagery (if applicable), must-have-patterns, avoid-list, and the wow moment for THIS component specifically. Group into one or two messages. Skip only on --skip-discovery or if the spec already covers every field. Without the wow moment, push back.

1. Capture the spec

Required:

  • Component type: button / modal / navbar / sidebar / card / table / form / chart / other
  • Stack: React + Tailwind / Vue / Svelte / Blade + Alpine / vanilla HTML / etc.
  • Brand voice: pull from .ux/last-frame.json if it exists, otherwise ask one-line: "What's the voice — minimal / brutalist / editorial / playful / dark? Or 'your call'?"

Optional but useful: specific behavior (auto-sort, multi-step, infinite scroll, drag-reorder), data shape, density target.

Do not ask three questions. One question that surfaces everything missing.

2. Read the references

Read both before writing:

  • references/styles/anti-slop.md — the ban list
  • references/styles/arsenal.md — the high-end pattern library

Pick 1-2 arsenal patterns that fit. For a button: live status with overshoot, optimistic update. For a modal: contextual focus mode. For a navbar: command input, intelligent list. For a card: hairline-separated metric blocks. For a table: intelligent list, monospace tabular. For a form: inline validation with field-level @error, multi-step wizard. For a chart: monochrome + semantic state colors only.

Read the full file on GitHub · 219 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 · 219 lines · 105 tokens per session scan A dad00866b05a

Subscribe to this mod's changes

ux-component is a command published in the GitHub repository Laith0003/ux-skill (65 stars, last pushed 1mo ago), licensed MIT. It adds 105 tokens to every session and 2,762 once invoked, about $0.0005 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-08-30.