werewolf-ui 0.1.0-alpha.4 → 0.1.0-beta.1
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 +16 -8
- package/data/manifest.json +1305 -424
- package/dist/cli.mjs +3822 -3147
- package/dist/core.mjs +85 -31
- package/dist/lint.mjs +55 -13
- package/dist/package-manager.mjs +55 -10
- package/dist/project.mjs +471 -49
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
# Werewolf CLI (
|
|
1
|
+
# Werewolf CLI (beta)
|
|
2
2
|
|
|
3
|
-
Published on npm as `werewolf-ui` (dist tags `latest` and `
|
|
3
|
+
Published on npm as `werewolf-ui` (dist tags `latest` and `beta`; run `npx werewolf-ui --version` to see which version you have). Run it with `npx werewolf-ui` from a supported app. Component APIs remain draft.
|
|
4
4
|
|
|
5
5
|
## Platform token export (E1, shipped in PR #134)
|
|
6
6
|
|
|
@@ -159,9 +159,17 @@ runs the same write plan, import mapping and rollback as any other add. `login`
|
|
|
159
159
|
signs in with the OAuth device flow, saves the key in the user config folder
|
|
160
160
|
(never in the app) and adds the registry to `werewolf.json`, with the key read
|
|
161
161
|
from an environment variable for CI. Only names with a namespace other than
|
|
162
|
-
`@werewolf
|
|
162
|
+
`@werewolf`, and item URLs, touch the network. Full protocol and limits:
|
|
163
163
|
[docs/cli.md](../../docs/cli.md#remote-registries).
|
|
164
164
|
|
|
165
|
+
`add <url>` installs one registry item JSON by its full URL, for example
|
|
166
|
+
`npx werewolf-ui add https://www.werewolf-ui.dev/r/button.json`. The URL must
|
|
167
|
+
use https (http only on localhost). It is sent no headers and no saved key, and
|
|
168
|
+
a redirect is refused. Its dependencies may be names or URLs; a URL on the
|
|
169
|
+
Werewolf site of an item this CLI bundles installs the bundled item, so the
|
|
170
|
+
theme init wrote stays. Files keep to the same allowed directories as any
|
|
171
|
+
remote item, and dependencies install without package scripts.
|
|
172
|
+
|
|
165
173
|
From any directory:
|
|
166
174
|
|
|
167
175
|
```bash
|
|
@@ -352,7 +360,7 @@ B3 add requires an initialized app. Missing config, seed or ownership record ret
|
|
|
352
360
|
WW_NOT_INITIALIZED with the npx werewolf-ui init action. It resolves one or more
|
|
353
361
|
component names and their registry dependencies in topological order, once per
|
|
354
362
|
item. Utility and token registry items are local files, never external packages.
|
|
355
|
-
Component APIs remain draft. C3 lint and D2 MCP launch ship on main and in the published
|
|
363
|
+
Component APIs remain draft. C3 lint and D2 MCP launch ship on main and in the published beta.
|
|
356
364
|
|
|
357
365
|
Add maps UI, lib and hooks source into the configured compiler aliases and
|
|
358
366
|
directories. It parses source and edits only module specifiers under the known
|
|
@@ -434,10 +442,10 @@ npm ci
|
|
|
434
442
|
npm run build:cli
|
|
435
443
|
npm pack --workspace werewolf-ui --pack-destination /absolute/path/to/output
|
|
436
444
|
cd /absolute/path/to/consumer
|
|
437
|
-
npm install /absolute/path/to/output/werewolf-ui-0.1.0-
|
|
445
|
+
npm install /absolute/path/to/output/werewolf-ui-0.1.0-beta.1.tgz --engine-strict
|
|
438
446
|
```
|
|
439
447
|
|
|
440
|
-
The supported
|
|
448
|
+
The supported layouts are Next.js app-router (app or src/app), Vite React
|
|
441
449
|
TypeScript and any other React TypeScript project, with Node 20+, React 19,
|
|
442
450
|
Tailwind CSS v4 and existing compiler aliases. Framework `react` is covered by
|
|
443
451
|
project detection tests only. The E3 consumer gate builds and packs locally,
|
|
@@ -475,6 +483,6 @@ To launch the published package without installing it in the app, use the versio
|
|
|
475
483
|
|
|
476
484
|
The client must have Node 20+ and npx on its PATH. If it cannot set cwd, launch node with the absolute installed node_modules/werewolf-ui/dist/cli.mjs path, mcp, --cwd and the app path as separate arguments. Wrappers vary by client. Init never changes client settings. This local config does not fetch a public release; publication remains planned.
|
|
477
485
|
|
|
478
|
-
The
|
|
486
|
+
The six names are list_components, search, get_component, generate_theme, lint and check_page. Successful tools return matching JSON text and structuredContent with schemaVersion, dataVersion, ok, data and diagnostics. Lint findings live in data.diagnostics; ok means the tool ran, rather than that the source is clean. Check coverage for dynamic or unread source. Theme returns artifacts without writing them.
|
|
479
487
|
|
|
480
|
-
The server exposes
|
|
488
|
+
The server exposes six read-only tools. check_page opens only pages on this computer and writes screenshots to a temporary folder, never to the project; it needs playwright-core and Chromium, or CHROME_PATH (see `check` in [docs/cli.md](../../docs/cli.md)). Lint accepts submitted content or explicit source files under the canonical root, with the same file, byte and diagnostic limits as core lint. Directory/glob inputs and symlinks are rejected. No installation, fixes or consumer config execution occurs. EOF drains responses; signals and broken input close with bounded cleanup. See [local MCP connection and tool documentation](../../docs/mcp.md) for the local tarball process config, illustrative future published config, tool examples, result envelopes and troubleshooting. D2 ships in PR #132. D3 packed comparisons and configured CLI-client evidence shipped in PR #133; desktop application registration remains untested. MCP lint uses the packaged default seed, while CLI lint reads the consumer seed for color suggestions.
|