primitiv-ui 0.1.2 → 0.1.3
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 +39 -15
- package/package.json +23 -11
package/README.md
CHANGED
|
@@ -4,34 +4,58 @@ The **Primitiv UI** design-system CLI. Add headless, accessible,
|
|
|
4
4
|
fully-styled components — and their design tokens — to any Vite or
|
|
5
5
|
Next.js project from the command line.
|
|
6
6
|
|
|
7
|
-
##
|
|
7
|
+
## Quick start
|
|
8
|
+
|
|
9
|
+
Run inside an existing Vite or Next.js project:
|
|
8
10
|
|
|
9
11
|
```sh
|
|
10
|
-
|
|
11
|
-
|
|
12
|
+
# pnpm
|
|
13
|
+
pnpm create primitiv-ui
|
|
14
|
+
|
|
15
|
+
# npm
|
|
16
|
+
npm create primitiv-ui@latest
|
|
17
|
+
|
|
18
|
+
# yarn / bun
|
|
19
|
+
yarn create primitiv-ui
|
|
20
|
+
bun create primitiv-ui
|
|
12
21
|
```
|
|
13
22
|
|
|
14
|
-
This
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
23
|
+
This scaffolds `primitiv.json` and generates the token layer. Then add
|
|
24
|
+
components with:
|
|
25
|
+
|
|
26
|
+
```sh
|
|
27
|
+
pnpm dlx primitiv-ui@latest add button
|
|
28
|
+
# or: npx primitiv-ui@latest add button
|
|
29
|
+
```
|
|
18
30
|
|
|
19
|
-
##
|
|
31
|
+
## Commands
|
|
20
32
|
|
|
21
33
|
```sh
|
|
22
|
-
primitiv init # scaffold primitiv.json
|
|
23
|
-
primitiv add button # add a component:
|
|
24
|
-
primitiv tokens #
|
|
25
|
-
primitiv theme #
|
|
34
|
+
primitiv init # scaffold primitiv.json + generate the token layer
|
|
35
|
+
primitiv add button # add a component: stylesheet + React surface + contract
|
|
36
|
+
primitiv tokens # (re)generate the design-token layer
|
|
37
|
+
primitiv theme # generate a brand-palette override layer
|
|
26
38
|
primitiv list # list available components and what's installed
|
|
27
39
|
```
|
|
28
40
|
|
|
29
|
-
|
|
41
|
+
## How it works
|
|
42
|
+
|
|
43
|
+
`primitiv-ui` is a thin JS launcher. It resolves the matching native binary
|
|
44
|
+
for your platform via `optionalDependencies` and runs it — so you only
|
|
45
|
+
download the one binary your machine needs.
|
|
46
|
+
|
|
47
|
+
You don't need to install it as a project dependency. Use `npx` or your
|
|
48
|
+
package manager's `dlx` / `create` command to invoke it on demand:
|
|
49
|
+
|
|
50
|
+
```sh
|
|
51
|
+
npx primitiv-ui@latest add switch
|
|
52
|
+
pnpm dlx primitiv-ui@latest add switch
|
|
53
|
+
```
|
|
30
54
|
|
|
31
55
|
## Supported platforms
|
|
32
56
|
|
|
33
|
-
macOS (arm64, x64), Linux (x64, arm64 — glibc),
|
|
34
|
-
other target, install
|
|
57
|
+
macOS (arm64, x64), Linux (x64, arm64 — glibc), Windows (x64). On any
|
|
58
|
+
other target, install from source:
|
|
35
59
|
|
|
36
60
|
```sh
|
|
37
61
|
cargo install primitiv-cli
|
package/package.json
CHANGED
|
@@ -1,19 +1,29 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "primitiv-ui",
|
|
3
|
-
"version": "0.1.
|
|
4
|
-
"description": "Primitiv UI
|
|
5
|
-
"keywords": [
|
|
3
|
+
"version": "0.1.3",
|
|
4
|
+
"description": "Primitiv UI \u2014 the design system CLI. Run `primitiv add button` in any Vite or Next.js project.",
|
|
5
|
+
"keywords": [
|
|
6
|
+
"primitiv",
|
|
7
|
+
"design-system",
|
|
8
|
+
"cli",
|
|
9
|
+
"react",
|
|
10
|
+
"tailwind"
|
|
11
|
+
],
|
|
6
12
|
"bin": {
|
|
7
13
|
"primitiv": "./bin/primitiv.mjs"
|
|
8
14
|
},
|
|
9
|
-
"files": [
|
|
10
|
-
|
|
15
|
+
"files": [
|
|
16
|
+
"bin"
|
|
17
|
+
],
|
|
18
|
+
"engines": {
|
|
19
|
+
"node": ">=18"
|
|
20
|
+
},
|
|
11
21
|
"optionalDependencies": {
|
|
12
|
-
"@primitiv-ui/cli-darwin-arm64": "0.1.
|
|
13
|
-
"@primitiv-ui/cli-darwin-x64": "0.1.
|
|
14
|
-
"@primitiv-ui/cli-linux-x64-gnu": "0.1.
|
|
15
|
-
"@primitiv-ui/cli-linux-arm64-gnu": "0.1.
|
|
16
|
-
"@primitiv-ui/cli-win32-x64": "0.1.
|
|
22
|
+
"@primitiv-ui/cli-darwin-arm64": "0.1.3",
|
|
23
|
+
"@primitiv-ui/cli-darwin-x64": "0.1.3",
|
|
24
|
+
"@primitiv-ui/cli-linux-x64-gnu": "0.1.3",
|
|
25
|
+
"@primitiv-ui/cli-linux-arm64-gnu": "0.1.3",
|
|
26
|
+
"@primitiv-ui/cli-win32-x64": "0.1.3"
|
|
17
27
|
},
|
|
18
28
|
"repository": {
|
|
19
29
|
"type": "git",
|
|
@@ -21,5 +31,7 @@
|
|
|
21
31
|
"directory": "npm/cli-wrapper"
|
|
22
32
|
},
|
|
23
33
|
"license": "MIT",
|
|
24
|
-
"publishConfig": {
|
|
34
|
+
"publishConfig": {
|
|
35
|
+
"access": "public"
|
|
36
|
+
}
|
|
25
37
|
}
|