ui8kit 1.3.5 → 1.4.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 +88 -0
- package/dist/index.js +1006 -235
- package/dist/index.js.map +1 -1
- package/package.json +2 -1
package/README.md
CHANGED
|
@@ -35,13 +35,19 @@ Options:
|
|
|
35
35
|
|
|
36
36
|
- `-y, --yes` Skip prompts and use defaults
|
|
37
37
|
- `-r, --registry <type>` Registry type (default: `ui`)
|
|
38
|
+
- `--registry-url <url>` Override registry CDN base URL
|
|
39
|
+
- `--registry-version <version>` Replace `@latest` in default URLs with a pinned version
|
|
40
|
+
- `--strict-cdn` Disable fallback CDN providers when an explicit URL is set
|
|
41
|
+
- `--import-style <alias|package>` Choose installed component import style (`alias` or package barrel `@ui8kit/core`; default: `alias`)
|
|
38
42
|
|
|
39
43
|
When running without `--yes`, `init` now asks for:
|
|
40
44
|
|
|
41
45
|
- Global CSS file path (default: `src/index.css`)
|
|
42
46
|
- Import alias for components (default: `@/components`)
|
|
47
|
+
- Import style for installed components (`alias` or `package`)
|
|
43
48
|
|
|
44
49
|
`typescript` is always set to `true` and `framework` is fixed to `vite-react`.
|
|
50
|
+
`init` now writes configuration and core utilities/variants. Empty category folders are created during bulk install (`add --all`).
|
|
45
51
|
|
|
46
52
|
### `add`
|
|
47
53
|
|
|
@@ -72,8 +78,18 @@ Options:
|
|
|
72
78
|
- `-f, --force` Overwrite existing files
|
|
73
79
|
- `-r, --registry <type>` Registry type (default: `ui`)
|
|
74
80
|
- `--dry-run` Show planned actions without writing files
|
|
81
|
+
- `--all` also creates base install directories before fetching and writing components:
|
|
82
|
+
- `src/lib`
|
|
83
|
+
- `src/components`
|
|
84
|
+
- `src/components/ui`
|
|
85
|
+
- `src/blocks`
|
|
86
|
+
- `src/layouts`
|
|
87
|
+
- `src/variants`
|
|
75
88
|
- `--retry` Enable retry logic for unstable connections
|
|
76
89
|
- `--no-cache` (root option) bypasses cache for this run.
|
|
90
|
+
- `--registry-url <url>` Override registry CDN base URL
|
|
91
|
+
- `--registry-version <version>` Replace `@latest` in default URLs with a pinned version
|
|
92
|
+
- `--strict-cdn` Disable fallback CDN providers when an explicit URL is set
|
|
77
93
|
|
|
78
94
|
### `list`
|
|
79
95
|
|
|
@@ -90,6 +106,9 @@ Options:
|
|
|
90
106
|
|
|
91
107
|
- `-r, --registry <type>` Registry type (default: `ui`)
|
|
92
108
|
- `--json` Print JSON output instead of table
|
|
109
|
+
- `--registry-url <url>` Override registry CDN base URL
|
|
110
|
+
- `--registry-version <version>` Replace `@latest` in default URLs with a pinned version
|
|
111
|
+
- `--strict-cdn` Disable fallback CDN providers when an explicit URL is set
|
|
93
112
|
|
|
94
113
|
### `diff`
|
|
95
114
|
|
|
@@ -107,6 +126,9 @@ Options:
|
|
|
107
126
|
- `[component]` Optional component name
|
|
108
127
|
- `-r, --registry <type>` Registry type (default: `ui`)
|
|
109
128
|
- `--json` Print diff summary as JSON
|
|
129
|
+
- `--registry-url <url>` Override registry CDN base URL
|
|
130
|
+
- `--registry-version <version>` Replace `@latest` in default URLs with a pinned version
|
|
131
|
+
- `--strict-cdn` Disable fallback CDN providers when an explicit URL is set
|
|
110
132
|
|
|
111
133
|
Examples:
|
|
112
134
|
|
|
@@ -133,11 +155,62 @@ bunx ui8kit@latest --no-cache info
|
|
|
133
155
|
|
|
134
156
|
Use `--no-cache` in any command to skip reading cached registry data.
|
|
135
157
|
|
|
158
|
+
```bash
|
|
159
|
+
bunx ui8kit@latest info --cdn
|
|
160
|
+
```
|
|
161
|
+
|
|
162
|
+
Use `--cdn` to print resolved CDN URL order, active cache override, and registry override settings.
|
|
163
|
+
|
|
136
164
|
```bash
|
|
137
165
|
bunx ui8kit@latest --no-cache diff
|
|
138
166
|
bunx ui8kit@latest --no-cache list --json
|
|
139
167
|
```
|
|
140
168
|
|
|
169
|
+
### `registry` (utility)
|
|
170
|
+
|
|
171
|
+
Commands to maintain local CLI artifacts.
|
|
172
|
+
|
|
173
|
+
```bash
|
|
174
|
+
bunx ui8kit@latest registry clean
|
|
175
|
+
bunx ui8kit@latest registry clean --all --dry-run
|
|
176
|
+
```
|
|
177
|
+
|
|
178
|
+
### `reset`
|
|
179
|
+
|
|
180
|
+
Remove local UI8Kit-generated project state for a full clean re-install.
|
|
181
|
+
|
|
182
|
+
```bash
|
|
183
|
+
bunx ui8kit@latest reset
|
|
184
|
+
bunx ui8kit@latest reset --yes
|
|
185
|
+
bunx ui8kit@latest reset --dry-run
|
|
186
|
+
```
|
|
187
|
+
|
|
188
|
+
Options:
|
|
189
|
+
|
|
190
|
+
- `--dry-run` Show what will be removed
|
|
191
|
+
- `-y, --yes` Skip prompts
|
|
192
|
+
- `-f, --force` Skip confirmation prompt
|
|
193
|
+
- `--with-cache` Also clear local cache
|
|
194
|
+
|
|
195
|
+
Reset removes:
|
|
196
|
+
|
|
197
|
+
- `ui8kit.config.json` (project config)
|
|
198
|
+
- `src/registry.json` manifest if present
|
|
199
|
+
- Component install directories (`src/components`, `src/lib`, `src/variants`, `src/layouts`, `src/blocks`)
|
|
200
|
+
- Generated registry artifacts (`packages/registry/...`, `ui8kit.map.json`)
|
|
201
|
+
|
|
202
|
+
### `get-cdn` (diagnostics utility)
|
|
203
|
+
|
|
204
|
+
Check registry availability for each CDN source and compare payload metadata without touching installed project files.
|
|
205
|
+
|
|
206
|
+
```bash
|
|
207
|
+
npm run get-cdn
|
|
208
|
+
npm run get-cdn -- --url https://raw.githubusercontent.com/buildy-ui/ui/main/packages/@ui8kit/registry/r
|
|
209
|
+
npm run get-cdn -- --path components/variants/index.json --url https://cdn.jsdelivr.net/npm/@ui8kit/registry@latest/r
|
|
210
|
+
```
|
|
211
|
+
|
|
212
|
+
Use this before `init`/`add` when you suspect CDN propagation lag, stale `@latest` caches, or provider-specific outages.
|
|
213
|
+
|
|
141
214
|
### `scan`
|
|
142
215
|
|
|
143
216
|
Scan source files and generate a registry manifest.
|
|
@@ -168,6 +241,21 @@ Options:
|
|
|
168
241
|
- `[registry]` Path to registry JSON (default: `./src/registry.json`)
|
|
169
242
|
- `-o, --output <path>` Output directory (default: `./packages/registry/r`)
|
|
170
243
|
|
|
244
|
+
The build command also generates `packages/registry/ui8kit.map.json` when `src/lib/utility-props.map.ts` is available.
|
|
245
|
+
|
|
246
|
+
Generated map shape:
|
|
247
|
+
|
|
248
|
+
```json
|
|
249
|
+
{
|
|
250
|
+
"version": "1.0.0",
|
|
251
|
+
"generatedAt": "2026-03-06T12:00:00.000Z",
|
|
252
|
+
"map": {
|
|
253
|
+
"display": ["block", "flex"],
|
|
254
|
+
"spacing": ["m-2", "m-4"]
|
|
255
|
+
}
|
|
256
|
+
}
|
|
257
|
+
```
|
|
258
|
+
|
|
171
259
|
### Global options
|
|
172
260
|
|
|
173
261
|
These options work for all commands and are defined at the CLI root:
|