ChronicStone/nuxt-ui-tools / .agents/skills/nuxt-ui-tools-maintainer
nuxt-ui-tools-maintainer
VerifiedUse this skill for internal maintenance and feature work in the nuxt-ui-tools repository. It explains the repository operating model, exact placement rules, how runtime domains relate, how features should be structured and extended, how consumer skills must be maintained, and what to keep in sync when changing the library.
| File | Kind | Size |
|---|---|---|
| SKILL.md | skill md | 4.3 KB |
| references/change-workflow.md | markdown | 2.2 KB |
| references/consumer-skills.md | markdown | 2.2 KB |
| references/core-approach.md | markdown | 3.8 KB |
| references/dashboard-runtime.md | markdown | 27.8 KB |
| references/display-runtime.md | markdown | 3.5 KB |
| references/file-preview-runtime.md | markdown | 4.4 KB |
| references/form-runtime.md | markdown | 14.9 KB |
| references/placement-rules.md | markdown | 3.6 KB |
| references/query-state.md | markdown | 1.8 KB |
| references/shared-runtime.md | markdown | 809 B |
| references/spreadsheet-runtime.md | markdown | 6.0 KB |
| references/table-runtime.md | markdown | 8.0 KB |
references/display-runtime.md
View on GitHub# Display Runtime
`src/runtime/display` draws read-only content blocks. The form `info` field and the public
`UiDisplay` component both render through it.
## Layout
```txt
src/runtime/display/
types/shared.ts tones (DisplayBuiltinTone, the augmentable DisplayToneRegistry), content, actions, chips, DisplayUrl
types/blocks/<kind>.ts props and slot names of one kind
types/registry.ts DisplayPropsMap (kind → props), DisplayKind, DisplaySpec, DisplayUiMap
types/config.ts appConfig.nuxtUiTools.display: presets, tones, ui
components/display.vue the dispatcher (UiDisplay): applies the preset, renders DISPLAY_BLOCKS[display]
components/blocks/ one component per kind
components/parts/ render, chip, actions, copy, skeleton, more, empty line, load error, fact value, record media
directives/ reveal-truncated: a `title` with the full text of clipped text, on hover and focus
composables/ app config and slot classes, icons, locale, number format, reveal, file preview, lazy URLs
utils/ classes, content, dates, meter, json tokens, tone classes, tone CSS, URLs, presets, registry
plugins/display-tones injects the CSS of tones set in appConfig.nuxtUiTools.display.tones
```
## Rules
- A kind is one entry of `DisplayPropsMap`, one `types/blocks/<kind>.ts`, one component, one entry of
`DISPLAY_BLOCKS` and `DISPLAY_SKELETON_LAYOUTS`, plus its tests, playground examples and consumer
docs (`skills/consumer/display/references/kinds.md`). Variants are props of that kind, not new kinds.
- Every rendered element takes a slot class: each component builds its defaults per slot and merges
them with `resolveDisplayClasses(defaults, appUi, ui)`. Combine conditional classes with
`twMerge`, never by concatenating two color utilities.
- Colors go through tones only. A toned element carries `displayToneClass(tone)` and its parts read
`--nut-tone`, `--nut-tone-ink`, `--nut-tone-soft`, `--nut-tone-line`, `--nut-tone-contrast`. Built-in
tone classes live in `shared/styles/tokens.css`; registered ones come from `buildDisplayToneCss`.
Chips keep `UBadge` with a Nuxt UI `color` for built-in tones and switch to tone variables for
registered ones (`isBuiltinTone`).
- Every text slot carries `v-reveal-truncated`, so text cut by a block or by an app `ui` class
shows in full on hover. Chips go through `DisplayChip`, which merges `display.ui.chip` over
each chip's `ui`; never render a bare `UBadge` in a block.
- Collections fold with `useDisplayReveal`; loading draws `DisplaySkeleton`; empty draws
`DisplayEmptyLine`; words come from the `display` messages of the ui-tools locale.
- File links (`DisplayUrl`) may be functions. Previews pass them to the file preview as lazy
sources; open and download go through `useDisplayUrlActions` and `utils/urls.ts`, which open the
tab during the click so popup blockers allow it.
- Display props are opaque payloads: hold them in `shallowRef`, never `ref`, or Vue's deep unwrap
types recurse through VNode types.
## Form integration
`form/fields/info` owns the field: `types.ts` (notice field | display field, typed per kind with
`FormInfoDisplaySource`), `use-info-display.ts` (static, callback, promise with a run counter, or
query options through `useQuery`, plus retry), and `component.vue` (label shell through
`FormFieldShell` when the field has a label or supporting copy; skeleton, load error, block).
`api.form.close()` reaches the root's cancel through `runtime.bindCancel`.
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| brainstormingobra/superpowersYou MUST use this before any creative work - creating features, building components, adding functionality, modifying behavior, or planning anything new, in software or out of it (a talk, a business, a renovation). | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| brand-guidelinesanthropics/skillsApplies Anthropic's official brand colors and typography to any sort of artifact that may benefit from having Anthropic's look-and-feel. Use it when brand colors or style guidelines, visual formatting, or company design standards apply. | Stars: 198k | Updated | Claude CodeCodex | Verified | Install |
| frontend-designanthropics/skillsGuidance for distinctive, intentional visual design when building new UI or reshaping an existing one. Helps with aesthetic direction, typography, and making choices that don't read as templated defaults. | Stars: 198k | Updated | Claude CodeCodex | Verified | Install |
| mcp-builderanthropics/skillsGuide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when building MCP servers to integrate external APIs or services, whether in Python (FastMCP) or Node/TypeScript (MCP SDK). | Stars: 198k | Updated | Claude CodeCodex | Verified | Install |