@voltui/agent 0.5.0 → 0.6.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.
package/README.md CHANGED
@@ -1,26 +1,50 @@
1
1
  # @voltui/agent
2
2
 
3
- Connects your AI coding agent to the [Volt UI](https://volt-ui.andersseen.dev) MCP server and
4
- installs the Volt UI context files it needs (skill, rules, snippets) into your project.
3
+ Connects your AI coding agent to the [Volt UI](https://voltui.dev) MCP server and
4
+ installs the Volt UI context it needs (skills, rules, snippets) into your project.
5
+
6
+ **The MCP server says what Volt contains; the skills teach your agent when and how to use it.**
7
+ Exact selectors, inputs and status come from the server (`find_components`, `get_component`,
8
+ `get_usage_example`); the skills are short playbooks that never copy that API.
5
9
 
6
10
  ```bash
7
11
  npx @voltui/agent # interactive
8
12
  npx @voltui/agent claude # one agent
9
13
  npx @voltui/agent cursor copilot # several
10
14
  npx @voltui/agent --all --yes # every agent, no prompts
15
+ npx @voltui/agent doctor # check what is installed
11
16
  ```
12
17
 
13
18
  Requires Node 20 or newer. No dependencies.
14
19
 
15
20
  ## What each agent gets
16
21
 
17
- | Agent | Files written |
18
- | ---------- | -------------------------------------------------------------------------------------------- |
19
- | `claude` | `.mcp.json` (`http` transport), `.claude/skills/volt-ui/SKILL.md` |
20
- | `cursor` | `.cursor/mcp.json`, `.cursorrules` |
21
- | `windsurf` | `.codeium/windsurf/mcp_config.json` |
22
- | `copilot` | `.vscode/mcp.json`, `.github/copilot-instructions.md`, `.vscode/volt-snippets.code-snippets` |
23
- | `vscode` | `.vscode/volt-snippets.code-snippets` |
22
+ | Agent | Files written |
23
+ | ---------- | ------------------------------------------------------------------------------------------------------ |
24
+ | `claude` | `.mcp.json` (`http` transport), `.claude/skills/<skill>/SKILL.md` for each skill |
25
+ | `cursor` | `.cursor/mcp.json`, `.cursorrules` (a block) |
26
+ | `windsurf` | `.codeium/windsurf/mcp_config.json`, `.windsurfrules` (a block) |
27
+ | `copilot` | `.vscode/mcp.json`, `.github/copilot-instructions.md` (a block), `.vscode/volt-snippets.code-snippets` |
28
+ | `codex` | `.codex/config.toml` (a `# volt-ui:begin` block), `.agents/skills/<skill>/SKILL.md` |
29
+ | `gemini` | `.gemini/settings.json` (`httpUrl`), `GEMINI.md` (a block) |
30
+ | `opencode` | `opencode.json` (`mcp`, remote), `.agents/skills/<skill>/SKILL.md` |
31
+ | `vscode` | `.vscode/volt-snippets.code-snippets` |
32
+
33
+ ## The skills
34
+
35
+ | Skill | Responsibility |
36
+ | ----------------------------- | -------------------------------------------------------------------------------- |
37
+ | `volt-ui` | Entry point: Volt-first policy, MCP is the source of facts, routes to the rest |
38
+ | `volt-ui-adoption` | Reuse an existing atom before hand-building equivalent UI |
39
+ | `volt-ui-component-selection` | Which component for which responsibility (Button vs link, Dialog vs Drawer, …) |
40
+ | `volt-ui-forms` | Forms, validation, Combobox (local and server-backed), disabled vs aria-disabled |
41
+ | `volt-ui-overlays` | Dialog, Drawer, Popover, Tooltip, Dropdown Menu, Toast: choice, focus, dismissal |
42
+ | `volt-ui-styling` | Tokens, presets, the `class` contract: customise without rebuilding |
43
+ | `volt-ui-distribution` | Package vs copy-and-own, the CLI, matching selectors and imports |
44
+
45
+ Only Claude Code, Codex and OpenCode discover skills, so they get the full set. Cursor, Windsurf,
46
+ Copilot and Gemini CLI read a rules file: they get a short block holding the digest of each skill
47
+ instead of the playbooks themselves. Every skill and every digest comes from the same file.
24
48
 
25
49
  Claude Desktop is not configured by files: add the server under Settings → Connectors.
26
50
 
@@ -30,27 +54,43 @@ Running it again is safe, and `--dry-run` shows what would change first.
30
54
 
31
55
  - **JSON configs** are merged: your other servers and keys stay. A file that is not valid JSON
32
56
  (comments, trailing commas) is left untouched and the run fails with a message.
33
- - **`.cursorrules`, `copilot-instructions.md`** get one block between
57
+ - **`.cursorrules`, `.windsurfrules`, `copilot-instructions.md`, `GEMINI.md`, `.codex/config.toml`** get one block between
34
58
  `<!-- volt-ui:begin … -->` and `<!-- volt-ui:end -->`. Your own text outside it is never touched;
35
59
  the block is replaced in place on re-runs, so upgrading the package updates it.
36
- - **Skill and snippets files** belong entirely to Volt UI and are rewritten.
60
+ - **A `[mcp_servers.volt-ui]` table you wrote in `.codex/config.toml`** is left alone (`kept`); a
61
+ second copy would be invalid TOML.
62
+ - **Skill and snippets files** belong entirely to Volt UI and are rewritten. Skills you wrote yourself,
63
+ in other directories under `.claude/skills` or `.agents/skills`, are never touched.
37
64
 
38
65
  ## Options
39
66
 
40
- | Option | Meaning |
41
- | ---------------------------------- | -------------------------------------------------------------------- |
42
- | `--all` | set up every agent |
43
- | `--dir <path>` | project directory (default: the current directory) |
44
- | `--url <url>` | MCP endpoint to write (default: `https://volt-ui.pages.dev/api/mcp`) |
45
- | `--dry-run` | print what would change, write nothing |
46
- | `--uninstall` | remove what this installer wrote; your other config is kept |
47
- | `-y`, `--yes` | never prompt; with no agent given, set up every agent |
48
- | `-v`, `--version` / `-h`, `--help` | |
67
+ | Option | Meaning |
68
+ | ---------------------------------- | ------------------------------------------------------------- |
69
+ | `--all` | set up every agent |
70
+ | `--dir <path>` | project directory (default: the current directory) |
71
+ | `--url <url>` | MCP endpoint to write (default: `https://voltui.dev/api/mcp`) |
72
+ | `--dry-run` | print what would change, write nothing |
73
+ | `--uninstall` | remove what this installer wrote; your other config is kept |
74
+ | `-y`, `--yes` | never prompt; with no agent given, set up every agent |
75
+ | `-v`, `--version` / `-h`, `--help` | |
49
76
 
50
77
  Without a terminal (CI, scripts) and without an agent or `--all`, it fails instead of waiting for input.
51
78
 
52
79
  Exit codes: `0` ok · `1` failed (for example an unparseable config) · `2` bad usage.
53
80
 
81
+ ## Checking it: `doctor`
82
+
83
+ ```bash
84
+ npx @voltui/agent doctor # every agent that has files in this project
85
+ npx @voltui/agent doctor claude # one agent
86
+ npx @voltui/agent doctor --offline # files only, skip the network check
87
+ ```
88
+
89
+ For each file it reports `ok`, `outdated` (differs from what this version of the package would
90
+ write — re-run the installer to update it), `missing` or `invalid`, then sends the MCP endpoint an
91
+ `initialize` request the way a client does. It only reads. Exit `0` when everything is fine, `1`
92
+ when a problem was found.
93
+
54
94
  ## Removing it
55
95
 
56
96
  ```bash
@@ -59,5 +99,5 @@ npx @voltui/agent claude --uninstall
59
99
 
60
100
  ## Links
61
101
 
62
- [Documentation](https://volt-ui.andersseen.dev/docs/ai-mcp) ·
102
+ [Documentation](https://voltui.dev/docs/ai-mcp) ·
63
103
  [Source](https://github.com/Andersseen/volt-ui/tree/main/cli/agent) · MIT