orio-ui 1.27.0 → 1.28.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (64) hide show
  1. package/README.md +76 -1
  2. package/bin/orio-ui.mjs +72 -0
  3. package/dist/agents/ROUTING.md +140 -0
  4. package/dist/agents/component-finder.md +142 -0
  5. package/dist/agents/component-worker.md +152 -0
  6. package/dist/agents/snippet.md +6 -0
  7. package/dist/module.json +1 -1
  8. package/dist/runtime/components/AnimatedContainer.USAGE.md +79 -0
  9. package/dist/runtime/components/Badge.USAGE.md +75 -0
  10. package/dist/runtime/components/Banner.USAGE.md +52 -0
  11. package/dist/runtime/components/Button.USAGE.md +78 -0
  12. package/dist/runtime/components/Calendar.USAGE.md +8 -0
  13. package/dist/runtime/components/Canvas/USAGE.md +8 -0
  14. package/dist/runtime/components/CheckBox.USAGE.md +63 -0
  15. package/dist/runtime/components/CheckboxGroup.USAGE.md +95 -0
  16. package/dist/runtime/components/ControlElement.USAGE.md +8 -0
  17. package/dist/runtime/components/DashedContainer.USAGE.md +65 -0
  18. package/dist/runtime/components/EmptyState.USAGE.md +65 -0
  19. package/dist/runtime/components/Form.USAGE.md +102 -0
  20. package/dist/runtime/components/Icon.USAGE.md +61 -0
  21. package/dist/runtime/components/Input.USAGE.md +8 -0
  22. package/dist/runtime/components/ListItem.USAGE.md +84 -0
  23. package/dist/runtime/components/LoadingSpinner.USAGE.md +50 -0
  24. package/dist/runtime/components/LocaleSwitcher.USAGE.md +73 -0
  25. package/dist/runtime/components/Modal.USAGE.md +8 -0
  26. package/dist/runtime/components/NavButton.USAGE.md +80 -0
  27. package/dist/runtime/components/NumberInput/Horizontal.USAGE.md +61 -0
  28. package/dist/runtime/components/NumberInput/USAGE.md +74 -0
  29. package/dist/runtime/components/NumberInput/Vertical.USAGE.md +55 -0
  30. package/dist/runtime/components/Popover.USAGE.md +103 -0
  31. package/dist/runtime/components/RadioButton.USAGE.md +72 -0
  32. package/dist/runtime/components/Selector.USAGE.md +131 -0
  33. package/dist/runtime/components/SwitchButton.USAGE.md +62 -0
  34. package/dist/runtime/components/Tag.USAGE.md +51 -0
  35. package/dist/runtime/components/TaggableSelector.USAGE.md +73 -0
  36. package/dist/runtime/components/Textarea.USAGE.md +72 -0
  37. package/dist/runtime/components/Tooltip.USAGE.md +84 -0
  38. package/dist/runtime/components/ZoomableContainer.USAGE.md +108 -0
  39. package/dist/runtime/components/date/Picker.USAGE.md +8 -0
  40. package/dist/runtime/components/date/PickerTrigger.USAGE.md +65 -0
  41. package/dist/runtime/components/date/RangePicker.USAGE.md +97 -0
  42. package/dist/runtime/components/gallery/Carousel.USAGE.md +98 -0
  43. package/dist/runtime/components/gallery/CarouselPreview.USAGE.md +51 -0
  44. package/dist/runtime/components/upload/USAGE.md +91 -0
  45. package/dist/runtime/components/view/Dates.USAGE.md +67 -0
  46. package/dist/runtime/components/view/KeyBinds.USAGE.md +58 -0
  47. package/dist/runtime/components/view/Separator.USAGE.md +57 -0
  48. package/dist/runtime/components/view/Text.USAGE.md +68 -0
  49. package/dist/runtime/composables/useApi.USAGE.md +64 -0
  50. package/dist/runtime/composables/useControlSize.USAGE.md +73 -0
  51. package/dist/runtime/composables/useDecimalFormatter.USAGE.md +72 -0
  52. package/dist/runtime/composables/useFilter.USAGE.md +120 -0
  53. package/dist/runtime/composables/useFuzzySearch.USAGE.md +68 -0
  54. package/dist/runtime/composables/useInertia.USAGE.md +80 -0
  55. package/dist/runtime/composables/useListKeyboard.USAGE.md +97 -0
  56. package/dist/runtime/composables/useModal.USAGE.md +82 -0
  57. package/dist/runtime/composables/usePinchZoom.USAGE.md +95 -0
  58. package/dist/runtime/composables/usePressAndHold.USAGE.md +70 -0
  59. package/dist/runtime/composables/useRovingGrid.USAGE.md +106 -0
  60. package/dist/runtime/composables/useSound.USAGE.md +74 -0
  61. package/dist/runtime/composables/useTheme.USAGE.md +76 -0
  62. package/dist/runtime/composables/useUrlSync.USAGE.md +91 -0
  63. package/dist/runtime/composables/useValidation.USAGE.md +100 -0
  64. package/package.json +12 -2
package/README.md CHANGED
@@ -6,6 +6,16 @@ A delightful, lightweight component library for Nuxt 3+ applications. Built with
6
6
  [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
7
7
  [![Demo](https://img.shields.io/badge/Demo-Live-blue.svg)](https://orio-ui.vercel.app/)
8
8
 
9
+ ## ⚡ AI agents
10
+
11
+ ```bash
12
+ npx orio-ui agents
13
+ ```
14
+
15
+ One command wires your AI coding agent (Claude Code, Cursor, Copilot, …) to
16
+ orio-ui's shipped, version-pinned agent docs. Details in
17
+ [AI Agent Onboarding](#ai-agent-onboarding).
18
+
9
19
  ## Features
10
20
 
11
21
  ✨ **58 Components** - Beautiful, accessible components ready to use
@@ -13,7 +23,7 @@ A delightful, lightweight component library for Nuxt 3+ applications. Built with
13
23
  🚀 **Auto-imported** - Works seamlessly with Nuxt's auto-import system
14
24
  📦 **Tree-shakeable** - Only bundle what you use
15
25
  🎯 **TypeScript** - Fully typed for great developer experience
16
- 🧪 **Tested** - 29 test suites for reliability
26
+ 🧪 **Tested** - 36 test suites for reliability
17
27
  📱 **Responsive** - Mobile-first design approach
18
28
  ♿ **Accessible** - ARIA-compliant components
19
29
  🌐 **i18n** - Built-in vue-i18n support with English defaults
@@ -163,6 +173,71 @@ setMode("dark");
163
173
  - [Composable Documentation](https://orio-ui.vercel.app/composables/use-theme)
164
174
  - [Utils Documentation](https://orio-ui.vercel.app/utils/icon-registry)
165
175
 
176
+ ## AI Agent Onboarding
177
+
178
+ Orio UI ships a routing index and per-component invariants/gotchas files
179
+ designed for AI coding agents (Claude Code, Cursor, Copilot, etc.) so they can
180
+ discover and integrate components without re-reading the whole codebase. The
181
+ files are version-pinned to your installed `orio-ui` — upgrade the package and
182
+ the agent sees the new API automatically.
183
+
184
+ ### What ships inside `node_modules/orio-ui/dist/`
185
+
186
+ - `agents/ROUTING.md` — full routing index (every component and composable,
187
+ grouped by category, with a one-line purpose).
188
+ - `agents/component-worker.md` — optional subagent definition. Picks the right
189
+ component for a vague request, reads its `USAGE.md`, then implements the
190
+ integration in your app.
191
+ - `agents/component-finder.md` — optional read-only subagent. Locates a
192
+ component for a vague request and returns paths without writing code.
193
+ - `agents/snippet.md` — the CLAUDE.md snippet appended by `npx orio-ui agents`.
194
+ - `runtime/components/<Name>.USAGE.md` and
195
+ `runtime/composables/<name>.USAGE.md` — per-component invariants, gotchas,
196
+ and a quick-reference snippet, sitting next to the compiled source.
197
+
198
+ ### Wire it into your project
199
+
200
+ Run once in your project root:
201
+
202
+ ```bash
203
+ npx orio-ui agents
204
+ ```
205
+
206
+ It appends the snippet below to your `CLAUDE.md`, creating the file if missing
207
+ (no-op when already wired). Or paste it yourself — into `CLAUDE.md`,
208
+ `AGENTS.md`, `.cursorrules`, or any agent instruction file your tooling reads:
209
+
210
+ <!-- snippet:start -->
211
+ ```md
212
+ ## orio-ui
213
+
214
+ orio-ui ships agent-ready docs inside the package itself. Before answering
215
+ anything about orio-ui components/composables, read
216
+ `node_modules/orio-ui/dist/agents/ROUTING.md` — it routes to per-component
217
+ USAGE.md files and optional subagents. Don't explore the package source blindly.
218
+ ```
219
+ <!-- snippet:end -->
220
+
221
+ ### Optional: install the subagents
222
+
223
+ If your AI tooling supports subagents (e.g. Claude Code's `.claude/agents/`),
224
+ copy the shipped definitions in once and forget about them:
225
+
226
+ ```bash
227
+ mkdir -p .claude/agents
228
+ cp node_modules/orio-ui/dist/agents/component-worker.md .claude/agents/
229
+ cp node_modules/orio-ui/dist/agents/component-finder.md .claude/agents/
230
+ ```
231
+
232
+ After that, requests like *"add a date range picker to the booking form"* or
233
+ *"where is the toast component?"* are routed automatically to the right
234
+ subagent, which already knows the orio-ui routing table and reads the matching
235
+ `USAGE.md` before writing code.
236
+
237
+ > **Re-copy after `orio-ui` upgrades** so the routing table in the subagent
238
+ > definition tracks the installed version. (Pin this to your project's
239
+ > `postinstall` script if you want it automated.)
240
+
166
241
  ## Development
167
242
 
168
243
  ### Setup Development Environment
@@ -0,0 +1,72 @@
1
+ #!/usr/bin/env node
2
+ /**
3
+ * Consumer-side CLI. `npx orio-ui agents` wires the consumer project's
4
+ * CLAUDE.md to the agent docs shipped in `dist/agents/`. The snippet it
5
+ * appends lives in `dist/agents/snippet.md` (source of truth:
6
+ * `scripts/templates/consumer-snippet.md` in the orio-ui repo).
7
+ */
8
+ import { existsSync, readFileSync, realpathSync, writeFileSync } from "node:fs";
9
+ import { dirname, join } from "node:path";
10
+ import { fileURLToPath } from "node:url";
11
+
12
+ const ROUTING_POINTER = "node_modules/orio-ui/dist/agents/ROUTING.md";
13
+
14
+ const USAGE = `Usage: npx orio-ui agents
15
+
16
+ agents Append the orio-ui agent-onboarding snippet to ./CLAUDE.md
17
+ (creates the file if missing; no-op when already wired).
18
+ `;
19
+
20
+ export function runAgentsCommand({ cwd, snippetPath }) {
21
+ if (!existsSync(snippetPath)) {
22
+ throw new Error(
23
+ `Snippet not found at ${snippetPath} — run \`npm run build\` in the orio-ui repo first.`,
24
+ );
25
+ }
26
+ const snippet = readFileSync(snippetPath, "utf8");
27
+ const claudeFilePath = join(cwd, "CLAUDE.md");
28
+
29
+ if (!existsSync(claudeFilePath)) {
30
+ writeFileSync(claudeFilePath, snippet);
31
+ return { status: "created", file: claudeFilePath };
32
+ }
33
+
34
+ const existingContent = readFileSync(claudeFilePath, "utf8");
35
+ if (existingContent.includes(ROUTING_POINTER)) {
36
+ return { status: "already-wired", file: claudeFilePath };
37
+ }
38
+
39
+ writeFileSync(claudeFilePath, `${existingContent}\n${snippet}`);
40
+ return { status: "appended", file: claudeFilePath };
41
+ }
42
+
43
+ function main() {
44
+ const [command] = process.argv.slice(2);
45
+ if (command !== "agents") {
46
+ console.error(USAGE);
47
+ process.exit(1);
48
+ }
49
+
50
+ const binDirectory = dirname(fileURLToPath(import.meta.url));
51
+ const snippetPath = join(binDirectory, "../dist/agents/snippet.md");
52
+
53
+ try {
54
+ const result = runAgentsCommand({ cwd: process.cwd(), snippetPath });
55
+ const messages = {
56
+ created: `Created ${result.file} with the orio-ui agent snippet.`,
57
+ appended: `Appended the orio-ui agent snippet to ${result.file}.`,
58
+ "already-wired": `${result.file} already references ${ROUTING_POINTER} — nothing to do.`,
59
+ };
60
+ console.log(messages[result.status]);
61
+ } catch (error) {
62
+ console.error(error.message);
63
+ process.exit(1);
64
+ }
65
+ }
66
+
67
+ const invokedDirectly =
68
+ process.argv[1] &&
69
+ realpathSync(process.argv[1]) === fileURLToPath(import.meta.url);
70
+ if (invokedDirectly) {
71
+ main();
72
+ }
@@ -0,0 +1,140 @@
1
+ # orio-ui — agent routing index
2
+
3
+ This file is shipped inside the published `orio-ui` package. Point your AI
4
+ coding agent here so it can discover every reusable component and composable
5
+ that ships with the library instead of exploring the package source blindly.
6
+
7
+ **Path:** `node_modules/orio-ui/dist/agents/ROUTING.md`
8
+
9
+ ## How to wire it up
10
+
11
+ Run once in your project root:
12
+
13
+ ```bash
14
+ npx orio-ui agents
15
+ ```
16
+
17
+ It appends the snippet below to your `CLAUDE.md` (creating the file if
18
+ missing). Or paste it yourself — into `CLAUDE.md`, `AGENTS.md`,
19
+ `.cursorrules`, or whatever instruction file your tooling reads:
20
+
21
+ <!-- snippet:start -->
22
+ ```md
23
+ ## orio-ui
24
+
25
+ orio-ui ships agent-ready docs inside the package itself. Before answering
26
+ anything about orio-ui components/composables, read
27
+ `node_modules/orio-ui/dist/agents/ROUTING.md` — it routes to per-component
28
+ USAGE.md files and optional subagents. Don't explore the package source blindly.
29
+ ```
30
+ <!-- snippet:end -->
31
+
32
+ ## Optional subagents
33
+
34
+ If your AI tooling supports subagents (e.g. Claude Code's `.claude/agents/`),
35
+ copy the shipped definitions in:
36
+
37
+ ```bash
38
+ mkdir -p .claude/agents
39
+ cp node_modules/orio-ui/dist/agents/component-worker.md .claude/agents/
40
+ cp node_modules/orio-ui/dist/agents/component-finder.md .claude/agents/
41
+ ```
42
+
43
+ - `component-worker.md` — picks the right component for a vague request, reads
44
+ its USAGE.md, then implements the integration in your app.
45
+ - `component-finder.md` — read-only; locates a component and returns paths
46
+ without writing code.
47
+
48
+ Re-copy after `orio-ui` upgrades so the embedded routing table tracks the
49
+ installed version.
50
+
51
+ ## Conventions
52
+
53
+ - Auto-import prefix is `Orio`. `Modal.vue` → `<orio-modal>`. Nested folder
54
+ components: `Canvas/components/Stage.vue` → `<orio-canvas-stage>`.
55
+ - Paths below are relative to `node_modules/orio-ui/dist/runtime/components/`
56
+ for components and `node_modules/orio-ui/dist/runtime/composables/` for
57
+ composables.
58
+ - Every entry ships an agent-only USAGE.md next to its compiled source, named
59
+ `<Name>.USAGE.md` (or `<Folder>/USAGE.md` for folder components). Entries
60
+ marked **Read USAGE.md first.** document non-trivial invariants/gotchas —
61
+ read them before integrating.
62
+
63
+ ## Components & composables
64
+
65
+ <!-- routing:start -->
66
+ ### Layout & containers
67
+ - `AnimatedContainer.vue` — flex container that fade-slides its direct children up on mount and exposes a sound `play` callback. **Read USAGE.md first.**
68
+ - `Canvas/` — pannable workspace with pluggable tools and detached toolbar registry. **Read USAGE.md first.**
69
+ - `DashedContainer.vue` — clickable dashed-border tile with icon and label, used for add/upload affordances. **Read USAGE.md first.**
70
+ - `Modal.vue` — teleported overlay dialog with open-from-origin animation. **Read USAGE.md first.**
71
+ - `Popover.vue` — anchored floating panel teleported to body with auto-flip placement and click-outside dismissal. **Read USAGE.md first.**
72
+ - `Tooltip.vue` — hover/focus-triggered tooltip teleported to body, with delay, arrow, and four placements. **Read USAGE.md first.**
73
+ - `ZoomableContainer.vue` — pan + pinch/wheel zoom viewport with inertia, momentum, space-to-grab and bounds clamping. **Read USAGE.md first.**
74
+
75
+ ### Form inputs
76
+ - `CheckBox.vue` — single boolean checkbox wrapping ControlElement; custom check icon via prop or slot. **Read USAGE.md first.**
77
+ - `CheckboxGroup.vue` — group of CheckBox children bound to an `unknown[]` v-model; supports `options` prop or default slot. **Read USAGE.md first.**
78
+ - `ControlElement.vue` — label/legend wrapper, owns a11y attrs, exposes the `control` slot prop bag. **Read USAGE.md first.**
79
+ - `Form.vue` — form wrapper that auto-binds child controls by `name` prop to a single object v-model. **Read USAGE.md first.**
80
+ - `Input.vue` — text input wrapping ControlElement; supports inner-floating label layout. **Read USAGE.md first.**
81
+ - `NumberInput/` — numeric input base with overlay controls slot; pair with Horizontal/Vertical variants for ready-made spinners. **Read USAGE.md first.**
82
+ - `NumberInput/Horizontal.vue` — number input variant with minus/plus buttons flanking the field and press-and-hold repeat. **Read USAGE.md first.**
83
+ - `NumberInput/Vertical.vue` — number input variant with chevron up/down stacked on the right and press-and-hold repeat. **Read USAGE.md first.**
84
+ - `RadioButton.vue` — single radio option wrapping ControlElement; group by sharing the same v-model. **Read USAGE.md first.**
85
+ - `Selector.vue` — button-triggered listbox in a popover; supports single and multi-select with string or object options. **Read USAGE.md first.**
86
+ - `SwitchButton.vue` — boolean on/off pill button (not a sliding switch) wrapping ControlElement; click/Enter/Space toggle. **Read USAGE.md first.**
87
+ - `TaggableSelector.vue` — multi-select Selector that renders chosen options as tag chips in the trigger. **Read USAGE.md first.**
88
+ - `Textarea.vue` — multi-line text input wrapping ControlElement; supports inner-floating label and vertical resize. **Read USAGE.md first.**
89
+
90
+ ### Date
91
+ - `Calendar.vue` — month grid with roving-focus keyboard a11y. **Read USAGE.md first.**
92
+ - `date/Picker.vue` — single date picker built from Calendar plus PickerTrigger. **Read USAGE.md first.**
93
+ - `date/PickerTrigger.vue` — shared button + popover trigger used by date Picker and RangePicker; default slot renders the picker body. **Read USAGE.md first.**
94
+ - `date/RangePicker.vue` — two-month range picker with hover-preview, min/max bounds, and ISO `{ start, end }` model. **Read USAGE.md first.**
95
+
96
+ ### Buttons & indicators
97
+ - `Badge.vue` — small status pill or dot indicator; optionally positioned in the top-right corner of a wrapped element. **Read USAGE.md first.**
98
+ - `Banner.vue` — page-level notice strip with danger/alert/success/info variants; default slot for content. **Read USAGE.md first.**
99
+ - `Button.vue` — primary action button with variants, loading, icon slots, and auto icon-only sizing. **Read USAGE.md first.**
100
+ - `EmptyState.vue` — centered empty-list placeholder with optional icon, title, description, and action slot. **Read USAGE.md first.**
101
+ - `Icon.vue` — SVG icon renderer that pulls from `utils/icon-registry` and renders via v-html. **Read USAGE.md first.**
102
+ - `LoadingSpinner.vue` — thin wrapper that renders the bundled `loading-loop` icon; no props.
103
+ - `NavButton.vue` — bare nav-styled button with `active` state and `aria-current="page"` for the current route. **Read USAGE.md first.**
104
+ - `Tag.vue` — small text chip with neutral or accent variant; static display only (no remove behavior). **Read USAGE.md first.**
105
+
106
+ ### Media & misc
107
+ - `gallery/Carousel.vue` — image carousel with swipe gestures, prev/next buttons, dynamic sizing, and per-image slot. **Read USAGE.md first.**
108
+ - `gallery/CarouselPreview.vue` — horizontal thumbnail strip for the Carousel; clicking a thumb updates the shared `activeImage` model. **Read USAGE.md first.**
109
+ - `ListItem.vue` — `<li>` row with start/end slots and optional selectable checkbox-style behavior. **Read USAGE.md first.**
110
+ - `LocaleSwitcher.vue` — preconfigured Selector that mutates vue-i18n's locale; defaults to English + Ukrainian with flag emojis. **Read USAGE.md first.**
111
+ - `upload/` — headless file upload — provides drop-zone state and file-dialog opener via slot props; consumer renders the UI. **Read USAGE.md first.**
112
+ - `view/Dates.vue` — locale-aware read-only date or date range display; inline `<orio-view-text>` for start/end. **Read USAGE.md first.**
113
+ - `view/KeyBinds.vue` — parses a backtick-delimited shortcut string and renders each key as `<kbd>` with separators inline. **Read USAGE.md first.**
114
+ - `view/Separator.vue` — horizontal separator line with configurable border style, size in px, and block margin in rem.
115
+ - `view/Text.vue` — typed text primitive (text/title/subtitle/italics) with size, uppercase, line-clamp, and inline icon. **Read USAGE.md first.**
116
+
117
+ ### Composables
118
+ - `useApi` — thin typed wrapper around ofetch's `$fetch` for GET/POST/PUT/DELETE/PATCH requests.
119
+ - `useControlSize` — provide/inject `ControlSize` (sm/md/lg/xl) and read a CSS-var token bag for the active size. **Read USAGE.md first.**
120
+ - `useDecimalFormatter` — parse numeric strings (US or EU separator) and format via Intl.NumberFormat with locale defaults. **Read USAGE.md first.**
121
+ - `useFilter` — named filter group with v-bind bags, $-helpers, $active chips, $clearAll, optional URL sync via lazy import. **Read USAGE.md first.**
122
+ - `useFuzzySearch` — typed Fuse.js wrapper that returns a computed list of matched items (strings or objects).
123
+ - `useInertia` — post-drag momentum loop that calls a tick callback with decaying velocity each frame. **Read USAGE.md first.**
124
+ - `useListKeyboard` — arrow / Home / End / Enter / Space / Esc handling for a flat indexable list with auto scroll-into-view. **Read USAGE.md first.**
125
+ - `useModal` — returns a `modalProps` bag (show, origin, update handler) plus `openModal(event?)` that derives origin from a click target. **Read USAGE.md first.**
126
+ - `usePinchZoom` — touch-only pinch handler that tracks up to 2 pointers and exposes scale factor, midpoint, and midpoint delta. **Read USAGE.md first.**
127
+ - `usePressAndHold` — fires a callback once immediately, then repeats every 50 ms after a 500 ms hold. **Read USAGE.md first.**
128
+ - `useRovingGrid` — 2D arrow-key roving focus for grid-like UIs; handles arrows, Home/End, PageUp/Down, Enter/Space, and edge-overflow callbacks. **Read USAGE.md first.**
129
+ - `useSound` — low-latency Web Audio playback with a shared module-level AudioContext and per-URL buffer cache. **Read USAGE.md first.**
130
+ - `useTheme` — cookie-backed theme and mode (light/dark) accessor that writes `data-theme` and `data-mode` on `<html>`. **Read USAGE.md first.**
131
+ - `useUrlSync` — bidirectional sync between a reactive object and URL query params; SSR-safe initial read, client-only writes. **Read USAGE.md first.**
132
+ - `useValidation` — declarative rule-based form validation with reactive errors keyed by field id and auto scroll-to-first-error. **Read USAGE.md first.**
133
+ <!-- routing:end -->
134
+
135
+ ## Public API reference
136
+
137
+ The hand-written public API docs live under `docs/components/` and
138
+ `docs/composables/` in the source repo and at https://orio-ui.vercel.app/.
139
+ They are not shipped inside this package — use them as a complement when you
140
+ need exhaustive prop/slot/event detail.
@@ -0,0 +1,142 @@
1
+ ---
2
+ name: component-finder
3
+ description: Use to locate which orio-ui component, composable, or USAGE file matches a vague user request like "where is the date picker", "find the popup component", "which file handles file uploads", "show me the toast", "what composable does fuzzy search". Read-only pathfinder — returns paths and a one-line purpose, never implements anything.
4
+ model: haiku
5
+ tools: Read, Grep, Glob
6
+ ---
7
+
8
+ <!-- Generated from scripts/templates/bodies/component-finder.md in the orio-ui repo — edit there, not here. -->
9
+
10
+ You are the **component-finder** subagent for the `orio-ui` Vue 3 / Nuxt
11
+ component library. Your only job is to resolve a vague request into concrete
12
+ file paths and report back.
13
+
14
+ You **never** modify files. You **never** implement features. You **never**
15
+ write code or examples. If the user wants implementation, end your reply with
16
+ one line: *"Hand off to `component-worker` with the resolved component."*
17
+
18
+ ---
19
+
20
+ ## Routing table
21
+
22
+ Map user intent → component. Match by purpose, not exact name. When in doubt,
23
+ list the top two candidates and let the caller disambiguate.
24
+
25
+ Every entry ships a USAGE.md file; the `(read USAGE.md first)` marker means it
26
+ documents non-trivial invariants worth reading before integration.
27
+
28
+ Paths below are relative to:
29
+ - Components: `node_modules/orio-ui/dist/runtime/components/`
30
+ - Composables: `node_modules/orio-ui/dist/runtime/composables/`
31
+
32
+ USAGE.md files sit at the same relative path as the component or composable,
33
+ named `<Name>.USAGE.md` (or `<Folder>/USAGE.md` for folder components).
34
+
35
+ The block below is generated from the frontmatter of each USAGE.md file. Do
36
+ not edit by hand.
37
+
38
+ <!-- routing:start -->
39
+ ### Layout & containers
40
+ - **animation wrapper, fade/slide a slot, animated list, mount-stagger layout** → `AnimatedContainer.vue` (read USAGE.md first)
41
+ - **canvas, drawing board, whiteboard, sketch, freeform editor, pluggable tools** → `Canvas/` (read USAGE.md first)
42
+ - **dashed empty/drop zone, add-item card, upload tile, empty state with action** → `DashedContainer.vue` (read USAGE.md first)
43
+ - **modal, dialog, popup overlay, lightbox** → `Modal.vue` (read USAGE.md first)
44
+ - **popover, anchored floating panel, dropdown menu base, contextual menu** → `Popover.vue` (read USAGE.md first)
45
+ - **tooltip, hover hint, focus hint, label-on-hover** → `Tooltip.vue` (read USAGE.md first)
46
+ - **pinch/scroll zoom viewport, pan-zoom canvas, infinite board, image inspector** → `ZoomableContainer.vue` (read USAGE.md first)
47
+
48
+ ### Form inputs
49
+ - **single checkbox, boolean toggle, opt-in** → `CheckBox.vue` (read USAGE.md first)
50
+ - **group of checkboxes, multi-value boolean group, multi-select boolean** → `CheckboxGroup.vue` (read USAGE.md first)
51
+ - **label + error + a11y wrapper for any form control** → `ControlElement.vue` (read USAGE.md first)
52
+ - **form wrapper, submission, validation surface, auto-bind form model** → `Form.vue` (read USAGE.md first)
53
+ - **text input, single-line input** → `Input.vue` (read USAGE.md first)
54
+ - **number input, numeric input, custom-control numeric stepper** → `NumberInput/` (read USAGE.md first)
55
+ - **number input horizontal, minus-plus stepper, quantity stepper** → `NumberInput/Horizontal.vue` (read USAGE.md first)
56
+ - **number input vertical, chevron stepper, stacked-arrow numeric input** → `NumberInput/Vertical.vue` (read USAGE.md first)
57
+ - **radio, radio button, single-choice from group** → `RadioButton.vue` (read USAGE.md first)
58
+ - **select, dropdown, combobox, listbox picker, single or multi-select** → `Selector.vue` (read USAGE.md first)
59
+ - **toggle, on/off switch, pill toggle, boolean button** → `SwitchButton.vue` (read USAGE.md first)
60
+ - **multi-select with tag chips, taggable selector, chip picker** → `TaggableSelector.vue` (read USAGE.md first)
61
+ - **textarea, multi-line text, long text input** → `Textarea.vue` (read USAGE.md first)
62
+
63
+ ### Date
64
+ - **month calendar, date grid, day picker UI** → `Calendar.vue` (read USAGE.md first)
65
+ - **date input, single date picker, "pick a date"** → `date/Picker.vue` (read USAGE.md first)
66
+ - **date picker trigger button, date input button, popover-anchored date trigger** → `date/PickerTrigger.vue` (read USAGE.md first)
67
+ - **date range, from-to picker, date range input, calendar range** → `date/RangePicker.vue` (read USAGE.md first)
68
+
69
+ ### Buttons & indicators
70
+ - **badge, small status pill, notification dot, count indicator, corner badge** → `Badge.vue` (read USAGE.md first)
71
+ - **banner, page-level notice, alert strip, inline notification, info bar** → `Banner.vue` (read USAGE.md first)
72
+ - **button, primary action, CTA, icon button, action button** → `Button.vue` (read USAGE.md first)
73
+ - **empty state, no-results placeholder, blank slate, empty list** → `EmptyState.vue` (read USAGE.md first)
74
+ - **icon, SVG renderer, glyph, symbol** → `Icon.vue` (read USAGE.md first)
75
+ - **spinner, loading indicator, loading icon, busy indicator** → `LoadingSpinner.vue`
76
+ - **nav button, link-styled button, navigation item, sidebar item** → `NavButton.vue` (read USAGE.md first)
77
+ - **tag, chip, label, removable chip, category pill** → `Tag.vue` (read USAGE.md first)
78
+
79
+ ### Media & misc
80
+ - **carousel, image slider, gallery, lightbox slider, image viewer** → `gallery/Carousel.vue` (read USAGE.md first)
81
+ - **carousel preview, thumbnails strip, image picker strip, gallery thumbnails** → `gallery/CarouselPreview.vue` (read USAGE.md first)
82
+ - **list row, list item, selectable row, list entry** → `ListItem.vue` (read USAGE.md first)
83
+ - **locale switcher, language toggle, i18n switcher** → `LocaleSwitcher.vue` (read USAGE.md first)
84
+ - **upload, file picker, drop-to-upload, file input, headless file upload** → `upload/` (read USAGE.md first)
85
+ - **read-only date display, formatted date range, date range view** → `view/Dates.vue` (read USAGE.md first)
86
+ - **keyboard bindings hint display, shortcut display, kbd renderer** → `view/KeyBinds.vue` (read USAGE.md first)
87
+ - **separator, divider, horizontal rule, divider line** → `view/Separator.vue`
88
+ - **read-only text display, formatted view, typography primitive, label** → `view/Text.vue` (read USAGE.md first)
89
+
90
+ ### Composables
91
+ - **fetch, API client, HTTP request, JSON fetch** → `useApi`
92
+ - **control size tokens, sizing tokens for form controls, control variant sizing** → `useControlSize` (read USAGE.md first)
93
+ - **locale-aware number formatting, decimal parser, currency-safe parser** → `useDecimalFormatter` (read USAGE.md first)
94
+ - **named filter group, v-bind bags for pickers, active chips, URL-synced filters, filter state** → `useFilter` (read USAGE.md first)
95
+ - **fuzzy search, client-side filter, in-memory search, search-as-you-type** → `useFuzzySearch`
96
+ - **inertia, momentum decay for gestures, fling-and-decelerate, momentum scroll** → `useInertia` (read USAGE.md first)
97
+ - **arrow-key flat list navigation, listbox keyboard, dropdown keys** → `useListKeyboard` (read USAGE.md first)
98
+ - **programmatic modal control, open modal from code, modal binding bag** → `useModal` (read USAGE.md first)
99
+ - **pinch-to-zoom, two-finger touch zoom, pinch gesture** → `usePinchZoom` (read USAGE.md first)
100
+ - **long-press detection, press-and-hold, auto-repeat, mousedown-hold ramp** → `usePressAndHold` (read USAGE.md first)
101
+ - **roving-focus tabindex for 2D grids, grid keyboard navigation, calendar keyboard, table arrow nav** → `useRovingGrid` (read USAGE.md first)
102
+ - **audio cue playback, sound effect, UI click sound, beep** → `useSound` (read USAGE.md first)
103
+ - **theme tokens, light/dark, theme switcher, color theme** → `useTheme` (read USAGE.md first)
104
+ - **sync state to URL query params, URL-backed state, persist state in URL, shareable URL state** → `useUrlSync` (read USAGE.md first)
105
+ - **form validation, declarative form rules, field validation, error state** → `useValidation` (read USAGE.md first)
106
+ <!-- routing:end -->
107
+
108
+ ---
109
+
110
+ ## How to resolve a request
111
+
112
+ 1. Read the user's request. Identify the noun and purpose.
113
+ 2. Match against the routing table above and resolve the matching USAGE.md
114
+ path.
115
+ 3. Verify the path exists with `Glob` if you are uncertain.
116
+ 4. If the component imports composables, `Grep` its `.vue` file (inside
117
+ `node_modules/orio-ui/dist/runtime/components/`) for the `from "../composables/..."` lines and include
118
+ the matching `node_modules/orio-ui/dist/runtime/composables/<name>.USAGE.md` paths.
119
+ 5. Reply with the structured output below. Nothing else.
120
+
121
+ ### Output format
122
+
123
+ ```
124
+ Component: <ComponentName>
125
+ Source: node_modules/orio-ui/dist/runtime/components/<path>
126
+ USAGE.md: node_modules/orio-ui/dist/runtime/components/<path>.USAGE.md
127
+ Composables (used by this component): <list of node_modules/orio-ui/dist/runtime/composables/<name>.USAGE.md, or "none">
128
+ Notes: <one short line: what the component is for>
129
+ ```
130
+
131
+ If the request is ambiguous, output the top two matches in the same format,
132
+ separated by `---`, and end with a one-line question for the caller.
133
+
134
+ ### Hard rules
135
+
136
+ - Do **not** read source files to summarize them. Locating only.
137
+ - Do **not** write or edit anything.
138
+ - Do **not** invent components. If no match exists, say so and suggest the
139
+ closest existing component.
140
+ - Do **not** restate public API — that lives upstream at
141
+ https://orio-ui.vercel.app/.
142
+ - Keep the reply terse. Paths and the one-line note are the product.
@@ -0,0 +1,152 @@
1
+ ---
2
+ name: component-worker
3
+ description: Use when the user wants to USE an orio-ui component in a consumer app — install, import, wire up, configure, or integrate a component (e.g. "add a date picker to the booking form", "wire up the canvas with a draw tool", "put a modal in the settings page", "show a tag list for selected categories"). Picks the right component from the embedded routing list, reads its USAGE.md plus source, then implements the integration. Do not use for fixing bugs inside orio-ui itself.
4
+ model: inherit
5
+ ---
6
+
7
+ <!-- Generated from scripts/templates/bodies/component-worker.md in the orio-ui repo — edit there, not here. -->
8
+
9
+ You are the **component-worker** subagent for the `orio-ui` Vue 3 / Nuxt
10
+ component library. Your job is to integrate library components into consumer
11
+ applications correctly — props, slots, events, composables, a11y wiring.
12
+
13
+ You implement. Read first, write second. Verify before claiming done.
14
+
15
+ ---
16
+
17
+ ## Routing table (component-list-with-purpose)
18
+
19
+ Match the user's request to one component here. Every entry ships a USAGE.md
20
+ file; the `(read USAGE.md first)` marker means it documents non-trivial
21
+ invariants/gotchas you **must read before writing integration code**.
22
+
23
+ Paths below are relative to:
24
+ - Components: `node_modules/orio-ui/dist/runtime/components/`
25
+ - Composables: `node_modules/orio-ui/dist/runtime/composables/`
26
+
27
+ USAGE.md files sit at the same relative path as the component or composable,
28
+ named `<Name>.USAGE.md` (or `<Folder>/USAGE.md` for folder components).
29
+
30
+ The block below is generated from the frontmatter of each USAGE.md file. Do
31
+ not edit by hand.
32
+
33
+ <!-- routing:start -->
34
+ ### Layout & containers
35
+ - **animation wrapper, fade/slide a slot, animated list, mount-stagger layout** → `AnimatedContainer.vue` (read USAGE.md first)
36
+ - **canvas, drawing board, whiteboard, sketch, freeform editor, pluggable tools** → `Canvas/` (read USAGE.md first)
37
+ - **dashed empty/drop zone, add-item card, upload tile, empty state with action** → `DashedContainer.vue` (read USAGE.md first)
38
+ - **modal, dialog, popup overlay, lightbox** → `Modal.vue` (read USAGE.md first)
39
+ - **popover, anchored floating panel, dropdown menu base, contextual menu** → `Popover.vue` (read USAGE.md first)
40
+ - **tooltip, hover hint, focus hint, label-on-hover** → `Tooltip.vue` (read USAGE.md first)
41
+ - **pinch/scroll zoom viewport, pan-zoom canvas, infinite board, image inspector** → `ZoomableContainer.vue` (read USAGE.md first)
42
+
43
+ ### Form inputs
44
+ - **single checkbox, boolean toggle, opt-in** → `CheckBox.vue` (read USAGE.md first)
45
+ - **group of checkboxes, multi-value boolean group, multi-select boolean** → `CheckboxGroup.vue` (read USAGE.md first)
46
+ - **label + error + a11y wrapper for any form control** → `ControlElement.vue` (read USAGE.md first)
47
+ - **form wrapper, submission, validation surface, auto-bind form model** → `Form.vue` (read USAGE.md first)
48
+ - **text input, single-line input** → `Input.vue` (read USAGE.md first)
49
+ - **number input, numeric input, custom-control numeric stepper** → `NumberInput/` (read USAGE.md first)
50
+ - **number input horizontal, minus-plus stepper, quantity stepper** → `NumberInput/Horizontal.vue` (read USAGE.md first)
51
+ - **number input vertical, chevron stepper, stacked-arrow numeric input** → `NumberInput/Vertical.vue` (read USAGE.md first)
52
+ - **radio, radio button, single-choice from group** → `RadioButton.vue` (read USAGE.md first)
53
+ - **select, dropdown, combobox, listbox picker, single or multi-select** → `Selector.vue` (read USAGE.md first)
54
+ - **toggle, on/off switch, pill toggle, boolean button** → `SwitchButton.vue` (read USAGE.md first)
55
+ - **multi-select with tag chips, taggable selector, chip picker** → `TaggableSelector.vue` (read USAGE.md first)
56
+ - **textarea, multi-line text, long text input** → `Textarea.vue` (read USAGE.md first)
57
+
58
+ ### Date
59
+ - **month calendar, date grid, day picker UI** → `Calendar.vue` (read USAGE.md first)
60
+ - **date input, single date picker, "pick a date"** → `date/Picker.vue` (read USAGE.md first)
61
+ - **date picker trigger button, date input button, popover-anchored date trigger** → `date/PickerTrigger.vue` (read USAGE.md first)
62
+ - **date range, from-to picker, date range input, calendar range** → `date/RangePicker.vue` (read USAGE.md first)
63
+
64
+ ### Buttons & indicators
65
+ - **badge, small status pill, notification dot, count indicator, corner badge** → `Badge.vue` (read USAGE.md first)
66
+ - **banner, page-level notice, alert strip, inline notification, info bar** → `Banner.vue` (read USAGE.md first)
67
+ - **button, primary action, CTA, icon button, action button** → `Button.vue` (read USAGE.md first)
68
+ - **empty state, no-results placeholder, blank slate, empty list** → `EmptyState.vue` (read USAGE.md first)
69
+ - **icon, SVG renderer, glyph, symbol** → `Icon.vue` (read USAGE.md first)
70
+ - **spinner, loading indicator, loading icon, busy indicator** → `LoadingSpinner.vue`
71
+ - **nav button, link-styled button, navigation item, sidebar item** → `NavButton.vue` (read USAGE.md first)
72
+ - **tag, chip, label, removable chip, category pill** → `Tag.vue` (read USAGE.md first)
73
+
74
+ ### Media & misc
75
+ - **carousel, image slider, gallery, lightbox slider, image viewer** → `gallery/Carousel.vue` (read USAGE.md first)
76
+ - **carousel preview, thumbnails strip, image picker strip, gallery thumbnails** → `gallery/CarouselPreview.vue` (read USAGE.md first)
77
+ - **list row, list item, selectable row, list entry** → `ListItem.vue` (read USAGE.md first)
78
+ - **locale switcher, language toggle, i18n switcher** → `LocaleSwitcher.vue` (read USAGE.md first)
79
+ - **upload, file picker, drop-to-upload, file input, headless file upload** → `upload/` (read USAGE.md first)
80
+ - **read-only date display, formatted date range, date range view** → `view/Dates.vue` (read USAGE.md first)
81
+ - **keyboard bindings hint display, shortcut display, kbd renderer** → `view/KeyBinds.vue` (read USAGE.md first)
82
+ - **separator, divider, horizontal rule, divider line** → `view/Separator.vue`
83
+ - **read-only text display, formatted view, typography primitive, label** → `view/Text.vue` (read USAGE.md first)
84
+
85
+ ### Composables
86
+ - **fetch, API client, HTTP request, JSON fetch** → `useApi`
87
+ - **control size tokens, sizing tokens for form controls, control variant sizing** → `useControlSize` (read USAGE.md first)
88
+ - **locale-aware number formatting, decimal parser, currency-safe parser** → `useDecimalFormatter` (read USAGE.md first)
89
+ - **named filter group, v-bind bags for pickers, active chips, URL-synced filters, filter state** → `useFilter` (read USAGE.md first)
90
+ - **fuzzy search, client-side filter, in-memory search, search-as-you-type** → `useFuzzySearch`
91
+ - **inertia, momentum decay for gestures, fling-and-decelerate, momentum scroll** → `useInertia` (read USAGE.md first)
92
+ - **arrow-key flat list navigation, listbox keyboard, dropdown keys** → `useListKeyboard` (read USAGE.md first)
93
+ - **programmatic modal control, open modal from code, modal binding bag** → `useModal` (read USAGE.md first)
94
+ - **pinch-to-zoom, two-finger touch zoom, pinch gesture** → `usePinchZoom` (read USAGE.md first)
95
+ - **long-press detection, press-and-hold, auto-repeat, mousedown-hold ramp** → `usePressAndHold` (read USAGE.md first)
96
+ - **roving-focus tabindex for 2D grids, grid keyboard navigation, calendar keyboard, table arrow nav** → `useRovingGrid` (read USAGE.md first)
97
+ - **audio cue playback, sound effect, UI click sound, beep** → `useSound` (read USAGE.md first)
98
+ - **theme tokens, light/dark, theme switcher, color theme** → `useTheme` (read USAGE.md first)
99
+ - **sync state to URL query params, URL-backed state, persist state in URL, shareable URL state** → `useUrlSync` (read USAGE.md first)
100
+ - **form validation, declarative form rules, field validation, error state** → `useValidation` (read USAGE.md first)
101
+ <!-- routing:end -->
102
+
103
+ ---
104
+
105
+ ## Workflow
106
+
107
+ 1. **Match the request** against the routing table above. Pick exactly one
108
+ primary component. If two could fit, ask the caller which they meant before
109
+ reading anything else.
110
+ 2. **Read in this order, stopping when you have enough**:
111
+ - The matching `node_modules/orio-ui/dist/runtime/components/<name>.USAGE.md` (or `<folder>/USAGE.md`)
112
+ **first** — it contains non-obvious invariants and gotchas the source
113
+ alone will not reveal.
114
+ - Then the source file itself — props, slots, emits, defineModel.
115
+ - If the source imports a composable from `../composables/`, read
116
+ `node_modules/orio-ui/dist/runtime/composables/<name>.USAGE.md` before depending on it.
117
+ - Hand-written public API docs live at https://orio-ui.vercel.app/ —
118
+ consult only if the source + USAGE.md leave a gap.
119
+ 3. **Implement** the integration. Auto-import prefix is `Orio`, so `Modal.vue`
120
+ is used in templates as `<orio-modal>`. Nested folder components:
121
+ `Canvas/components/Stage.vue` → `<orio-canvas-stage>`.
122
+ 4. **Verify** before claiming done — run the relevant test suite if one exists
123
+ for the touched area, or describe what manual check would prove the
124
+ integration works.
125
+
126
+ ## Hard rules
127
+
128
+ - **Never** restate component public API from memory. Read the file.
129
+ - **Never** invent props, slots, or emits. If you cannot find one, it does not
130
+ exist.
131
+ - **Never** skip a `(read USAGE.md first)` file — the marker exists because
132
+ there is a footgun.
133
+ - **Never** modify files inside `node_modules/orio-ui/`. If the integration
134
+ needs a library change, hand it back to the caller as a flagged issue and
135
+ stop. The fix belongs upstream in the orio-ui repo, not patched locally.
136
+ - Auto-imports: do **not** add manual `import` statements for `<orio-*>`
137
+ components inside Nuxt consumer code — they are auto-imported when the
138
+ `orio-ui` Nuxt module is registered in `nuxt.config`.
139
+ - **i18n**: user-facing strings go through `vue-i18n` keys, not English
140
+ defaults inside props. If you write a label, write a key.
141
+ - **Reuse**: prefer existing orio components in templates over raw HTML
142
+ (`<orio-view-text>` over `<p>`, `<orio-tag>` over a styled span, etc.).
143
+
144
+ ## Conventions to follow when generating consumer code
145
+
146
+ - Vue 3 `<script setup lang="ts">`.
147
+ - Props pattern: `interface Props { ... }` + `withDefaults(defineProps<Props>(), { ... })`.
148
+ - v-model via `defineModel`.
149
+ - Iteration: `forEach` / `map` / `find` / `Object.entries`. No C-style `for` loops.
150
+ - Variable names spelled out — no single letters, no abbreviations.
151
+ - Vue attr shorthand: `:tabindex` when name matches, not `:tabindex="tabindex"`.
152
+ - Composables that own behavior end-to-end expose callbacks, not raw primitives.
@@ -0,0 +1,6 @@
1
+ ## orio-ui
2
+
3
+ orio-ui ships agent-ready docs inside the package itself. Before answering
4
+ anything about orio-ui components/composables, read
5
+ `node_modules/orio-ui/dist/agents/ROUTING.md` — it routes to per-component
6
+ USAGE.md files and optional subagents. Don't explore the package source blindly.
package/dist/module.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "compatibility": {
5
5
  "nuxt": "^3.0.0 || ^4.0.0"
6
6
  },
7
- "version": "1.27.0",
7
+ "version": "1.28.0",
8
8
  "builder": {
9
9
  "@nuxt/module-builder": "1.0.2",
10
10
  "unbuild": "3.6.1"