@polyxd/ds-kit 0.2.0 → 0.2.2
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/dist/polyxd.js +14 -5
- package/dist/polyxd.js.map +1 -1
- package/dist/studio.d.ts +45 -0
- package/dist/studio.js +121 -0
- package/dist/studio.js.map +1 -0
- package/package.json +3 -3
package/dist/polyxd.js
CHANGED
|
@@ -2,11 +2,12 @@
|
|
|
2
2
|
/**
|
|
3
3
|
* The `polyxd` command.
|
|
4
4
|
*
|
|
5
|
-
* polyxd pack ./tokens.css
|
|
6
|
-
* polyxd check ./manifest.json
|
|
5
|
+
* polyxd pack ./tokens.css make a design-system pack out of your own tokens
|
|
6
|
+
* polyxd check ./manifest.json check a pack against the semantic token contract
|
|
7
|
+
* polyxd studio push ./ --to … send your tokens to Polyxd Studio (from CI, with an API key)
|
|
7
8
|
*
|
|
8
|
-
*
|
|
9
|
-
* Polyxd at their design system,
|
|
9
|
+
* Three commands, because those are the things a team does before anything else works: point
|
|
10
|
+
* Polyxd at their design system, find out what it still needs, and keep Studio in step with it.
|
|
10
11
|
*/
|
|
11
12
|
const [command, ...rest] = process.argv.slice(2);
|
|
12
13
|
process.argv = [process.argv[0], process.argv[1], ...rest];
|
|
@@ -29,6 +30,10 @@ switch (command) {
|
|
|
29
30
|
console.log(issues.length ? `\n${issues.length} issue(s)` : "Design system satisfies the semantic token contract.");
|
|
30
31
|
process.exit(issues.length ? 1 : 0);
|
|
31
32
|
}
|
|
33
|
+
case "studio": {
|
|
34
|
+
const { main } = await import("./studio.js");
|
|
35
|
+
process.exit(await main(rest));
|
|
36
|
+
}
|
|
32
37
|
default:
|
|
33
38
|
console.log(`polyxd <command>
|
|
34
39
|
|
|
@@ -38,7 +43,11 @@ switch (command) {
|
|
|
38
43
|
|
|
39
44
|
check <manifest.json>
|
|
40
45
|
Checks a pack against the semantic token contract: every token present and correctly
|
|
41
|
-
typed, every contrast pair measured, every constraint met
|
|
46
|
+
typed, every contrast pair measured, every constraint met.
|
|
47
|
+
|
|
48
|
+
studio push <package dir | tarball | token file> --to <studio>/api/w/<workspace>
|
|
49
|
+
Sends your tokens to Polyxd Studio as a new version of your design system, using an
|
|
50
|
+
API key from POLYXD_STUDIO_KEY. Made for a CI step on every release.`);
|
|
42
51
|
process.exit(command ? 1 : 0);
|
|
43
52
|
}
|
|
44
53
|
export {};
|
package/dist/polyxd.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"polyxd.js","sourceRoot":"","sources":["../src/polyxd.ts"],"names":[],"mappings":";AACA
|
|
1
|
+
{"version":3,"file":"polyxd.js","sourceRoot":"","sources":["../src/polyxd.ts"],"names":[],"mappings":";AACA;;;;;;;;;GASG;AACH,MAAM,CAAC,OAAO,EAAE,GAAG,IAAI,CAAC,GAAG,OAAO,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;AACjD,OAAO,CAAC,IAAI,GAAG,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,GAAG,IAAI,CAAC,CAAC;AAE3D,QAAQ,OAAO,EAAE,CAAC;IAChB,KAAK,MAAM;QACT,MAAM,MAAM,CAAC,UAAU,CAAC,CAAC;QACzB,MAAM;IACR,KAAK,OAAO,EAAE,CAAC;QACb,sFAAsF;QACtF,6BAA6B;QAC7B,MAAM,EAAE,iBAAiB,EAAE,GAAG,MAAM,MAAM,CAAC,cAAc,CAAC,CAAC;QAC3D,MAAM,QAAQ,GAAG,IAAI,CAAC,CAAC,CAAC,CAAC;QACzB,IAAI,CAAC,QAAQ,EAAE,CAAC;YACd,OAAO,CAAC,GAAG,CAAC,qCAAqC,CAAC,CAAC;YACnD,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;QAClB,CAAC;QACD,MAAM,MAAM,GAAG,MAAM,iBAAiB,CAAC,QAAQ,CAAC,CAAC;QACjD,KAAK,MAAM,CAAC,IAAI,MAAM;YAAE,OAAO,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,IAAI,IAAI,CAAC,CAAC,CAAC,EAAE,GAAG,CAAC,CAAC,KAAK,KAAK,CAAC,CAAC,OAAO,EAAE,CAAC,CAAC;QAC/F,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,KAAK,MAAM,CAAC,MAAM,WAAW,CAAC,CAAC,CAAC,sDAAsD,CAAC,CAAC;QACpH,OAAO,CAAC,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;IACtC,CAAC;IACD,KAAK,QAAQ,EAAE,CAAC;QACd,MAAM,EAAE,IAAI,EAAE,GAAG,MAAM,MAAM,CAAC,aAAa,CAAC,CAAC;QAC7C,OAAO,CAAC,IAAI,CAAC,MAAM,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC;IACjC,CAAC;IACD;QACE,OAAO,CAAC,GAAG,CAAC;;;;;;;;;;;;2EAY2D,CAAC,CAAC;QACzE,OAAO,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;AAClC,CAAC"}
|
package/dist/studio.d.ts
ADDED
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
export interface PushOptions {
|
|
2
|
+
/** Directory, tarball or token file. */
|
|
3
|
+
path: string;
|
|
4
|
+
/** The workspace's API base, e.g. https://studio.polyxd.com/api/w/acme */
|
|
5
|
+
to: string;
|
|
6
|
+
key: string;
|
|
7
|
+
/** Add a version to this design system instead of matching by package name. */
|
|
8
|
+
into?: string;
|
|
9
|
+
/** Name for a new design system (defaults to the package name or the file name). */
|
|
10
|
+
name?: string;
|
|
11
|
+
/** Override fetch, for tests. */
|
|
12
|
+
fetch?: typeof fetch;
|
|
13
|
+
}
|
|
14
|
+
export interface PushResult {
|
|
15
|
+
designSystemId: string;
|
|
16
|
+
versionId: string;
|
|
17
|
+
number: number;
|
|
18
|
+
/** Where to review the mapping in Studio. */
|
|
19
|
+
url: string;
|
|
20
|
+
scan: {
|
|
21
|
+
format: string;
|
|
22
|
+
total: number;
|
|
23
|
+
byTier: Record<string, number>;
|
|
24
|
+
modes: {
|
|
25
|
+
name: string;
|
|
26
|
+
}[];
|
|
27
|
+
issues: {
|
|
28
|
+
kind: string;
|
|
29
|
+
count: number;
|
|
30
|
+
}[];
|
|
31
|
+
picked?: string[];
|
|
32
|
+
};
|
|
33
|
+
}
|
|
34
|
+
/** What gets uploaded: the bytes, the file name, and the package identity when there is one. */
|
|
35
|
+
export declare function prepare(path: string): Promise<{
|
|
36
|
+
bytes: Uint8Array;
|
|
37
|
+
fileName: string;
|
|
38
|
+
packageName?: string;
|
|
39
|
+
packageVersion?: string;
|
|
40
|
+
cleanup: () => Promise<void>;
|
|
41
|
+
}>;
|
|
42
|
+
export declare function push(opts: PushOptions): Promise<PushResult>;
|
|
43
|
+
/** One line per fact, the way the pack command reports. */
|
|
44
|
+
export declare function describe(r: PushResult, fileName: string): string;
|
|
45
|
+
export declare function main(argv: string[]): Promise<number>;
|
package/dist/studio.js
ADDED
|
@@ -0,0 +1,121 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* `polyxd studio push`: send a design system's tokens to Polyxd Studio from wherever the tokens
|
|
3
|
+
* live: a package directory (packed with npm, so private dependencies and registries never
|
|
4
|
+
* matter), a tarball, or one token file (DTCG or Tokens Studio JSON, or CSS custom properties).
|
|
5
|
+
*
|
|
6
|
+
* POLYXD_STUDIO_KEY=… npx polyxd studio push ./ --to https://studio.polyxd.com/api/w/acme
|
|
7
|
+
* npx polyxd studio push ./tokens.css --to … --name "Acme tokens"
|
|
8
|
+
* npx polyxd studio push ./dist/tokens-2.4.0.tgz --to … --into <designSystemId>
|
|
9
|
+
*
|
|
10
|
+
* Studio scans the tokens (tiers, modes, aliases, issues) and answers with a link to review the
|
|
11
|
+
* mapping. A push with the same package name lands as a new version of the same design system,
|
|
12
|
+
* so a CI step can run it on every release.
|
|
13
|
+
*/
|
|
14
|
+
import { execFile } from "node:child_process";
|
|
15
|
+
import { mkdtemp, readFile, rm, stat } from "node:fs/promises";
|
|
16
|
+
import { tmpdir } from "node:os";
|
|
17
|
+
import { basename, join, resolve } from "node:path";
|
|
18
|
+
import { promisify } from "node:util";
|
|
19
|
+
const exec = promisify(execFile);
|
|
20
|
+
/** What gets uploaded: the bytes, the file name, and the package identity when there is one. */
|
|
21
|
+
export async function prepare(path) {
|
|
22
|
+
const target = resolve(path);
|
|
23
|
+
const info = await stat(target).catch(() => null);
|
|
24
|
+
if (!info)
|
|
25
|
+
throw new Error(`${path} does not exist`);
|
|
26
|
+
if (info.isDirectory()) {
|
|
27
|
+
const pkgFile = join(target, "package.json");
|
|
28
|
+
const pkg = JSON.parse(await readFile(pkgFile, "utf8").catch(() => {
|
|
29
|
+
throw new Error(`${path} has no package.json; point at a token file instead`);
|
|
30
|
+
}));
|
|
31
|
+
// npm pack honours "files", .npmignore and prepack, so the tarball is what a release would be.
|
|
32
|
+
const dir = await mkdtemp(join(tmpdir(), "polyxd-push-"));
|
|
33
|
+
const { stdout } = await exec("npm", ["pack", "--json", "--pack-destination", dir, "--ignore-scripts"], { cwd: target, maxBuffer: 16 * 1024 * 1024 });
|
|
34
|
+
const [packed] = JSON.parse(stdout);
|
|
35
|
+
const bytes = new Uint8Array(await readFile(join(dir, packed.filename)));
|
|
36
|
+
return { bytes, fileName: packed.filename, packageName: packed.name ?? pkg.name, packageVersion: packed.version ?? pkg.version, cleanup: () => rm(dir, { recursive: true, force: true }) };
|
|
37
|
+
}
|
|
38
|
+
const bytes = new Uint8Array(await readFile(target));
|
|
39
|
+
return { bytes, fileName: basename(target), cleanup: async () => undefined };
|
|
40
|
+
}
|
|
41
|
+
export async function push(opts) {
|
|
42
|
+
const to = opts.to.replace(/\/+$/, "");
|
|
43
|
+
if (!/^https?:\/\/.+\/api\/w\/[a-z0-9-]+$/i.test(to))
|
|
44
|
+
throw new Error(`--to should look like https://studio.example.com/api/w/<workspace>, not ${opts.to}`);
|
|
45
|
+
if (!opts.key)
|
|
46
|
+
throw new Error("No key: set POLYXD_STUDIO_KEY or pass --key (Team → API keys in Studio)");
|
|
47
|
+
const prepared = await prepare(opts.path);
|
|
48
|
+
try {
|
|
49
|
+
const form = new FormData();
|
|
50
|
+
form.set("file", new Blob([prepared.bytes.slice().buffer]), prepared.fileName);
|
|
51
|
+
if (opts.name)
|
|
52
|
+
form.set("name", opts.name);
|
|
53
|
+
if (opts.into)
|
|
54
|
+
form.set("designSystemId", opts.into);
|
|
55
|
+
if (prepared.packageName)
|
|
56
|
+
form.set("packageName", prepared.packageName);
|
|
57
|
+
if (prepared.packageVersion)
|
|
58
|
+
form.set("packageVersion", prepared.packageVersion);
|
|
59
|
+
const res = await (opts.fetch ?? fetch)(`${to}/design-systems/import`, { method: "POST", headers: { authorization: `Bearer ${opts.key}` }, body: form });
|
|
60
|
+
const text = await res.text();
|
|
61
|
+
let data = {};
|
|
62
|
+
try {
|
|
63
|
+
data = text ? JSON.parse(text) : {};
|
|
64
|
+
}
|
|
65
|
+
catch {
|
|
66
|
+
/* an HTML error page from a proxy: the status line says enough */
|
|
67
|
+
}
|
|
68
|
+
if (!res.ok)
|
|
69
|
+
throw new Error(data.error ?? `Studio answered ${res.status} ${res.statusText}`);
|
|
70
|
+
const app = new URL(to);
|
|
71
|
+
const slug = to.split("/").pop();
|
|
72
|
+
return { ...data, url: data.url ?? `${app.origin}/w/${slug}/design-systems/${data.designSystemId}/versions/${data.versionId}/scan` };
|
|
73
|
+
}
|
|
74
|
+
finally {
|
|
75
|
+
await prepared.cleanup();
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
/** One line per fact, the way the pack command reports. */
|
|
79
|
+
export function describe(r, fileName) {
|
|
80
|
+
const tiers = Object.entries(r.scan.byTier ?? {})
|
|
81
|
+
.filter(([, n]) => n)
|
|
82
|
+
.map(([t, n]) => `${n} ${t}`)
|
|
83
|
+
.join(", ");
|
|
84
|
+
const modes = (r.scan.modes ?? []).map((m) => m.name).join(", ");
|
|
85
|
+
const issues = (r.scan.issues ?? []).reduce((s, i) => s + i.count, 0);
|
|
86
|
+
return [
|
|
87
|
+
`Pushed ${fileName} as version ${r.number}.`,
|
|
88
|
+
`${r.scan.total} tokens (${r.scan.format}${tiers ? `; ${tiers}` : ""})${modes ? ` · modes: ${modes}` : ""}${issues ? ` · ${issues} thing${issues === 1 ? "" : "s"} to look at` : ""}`,
|
|
89
|
+
`Review the mapping: ${r.url}`,
|
|
90
|
+
].join("\n");
|
|
91
|
+
}
|
|
92
|
+
export async function main(argv) {
|
|
93
|
+
const [sub, ...rest] = argv;
|
|
94
|
+
if (sub !== "push") {
|
|
95
|
+
console.log(`polyxd studio push <package dir | tarball | token file> --to <studio>/api/w/<workspace> [--into <designSystemId>] [--name <name>] [--key <key>]
|
|
96
|
+
|
|
97
|
+
Sends your tokens to Polyxd Studio. A directory is packed with npm (so it's what a release would
|
|
98
|
+
be); the key comes from POLYXD_STUDIO_KEY or --key (Team → API keys). The same package name lands
|
|
99
|
+
as a new version of the same design system each time.`);
|
|
100
|
+
return sub ? 1 : 0;
|
|
101
|
+
}
|
|
102
|
+
const flag = (name) => {
|
|
103
|
+
const i = rest.indexOf(`--${name}`);
|
|
104
|
+
return i > -1 ? rest[i + 1] : undefined;
|
|
105
|
+
};
|
|
106
|
+
const path = rest.find((a, i) => !a.startsWith("--") && (i === 0 || !rest[i - 1].startsWith("--")));
|
|
107
|
+
if (!path || !flag("to")) {
|
|
108
|
+
console.log("usage: polyxd studio push <path> --to <studio>/api/w/<workspace> [--into <id>] [--name <name>] [--key <key>]");
|
|
109
|
+
return 2;
|
|
110
|
+
}
|
|
111
|
+
try {
|
|
112
|
+
const r = await push({ path, to: flag("to"), key: flag("key") ?? process.env.POLYXD_STUDIO_KEY ?? "", into: flag("into"), name: flag("name") });
|
|
113
|
+
console.log(describe(r, basename(path)));
|
|
114
|
+
return 0;
|
|
115
|
+
}
|
|
116
|
+
catch (e) {
|
|
117
|
+
console.error(e.message);
|
|
118
|
+
return 1;
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
//# sourceMappingURL=studio.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"studio.js","sourceRoot":"","sources":["../src/studio.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AACH,OAAO,EAAE,QAAQ,EAAE,MAAM,oBAAoB,CAAC;AAC9C,OAAO,EAAE,OAAO,EAAE,QAAQ,EAAE,EAAE,EAAE,IAAI,EAAE,MAAM,kBAAkB,CAAC;AAC/D,OAAO,EAAE,MAAM,EAAE,MAAM,SAAS,CAAC;AACjC,OAAO,EAAE,QAAQ,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpD,OAAO,EAAE,SAAS,EAAE,MAAM,WAAW,CAAC;AAEtC,MAAM,IAAI,GAAG,SAAS,CAAC,QAAQ,CAAC,CAAC;AAyBjC,gGAAgG;AAChG,MAAM,CAAC,KAAK,UAAU,OAAO,CAAC,IAAY;IACxC,MAAM,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAC7B,MAAM,IAAI,GAAG,MAAM,IAAI,CAAC,MAAM,CAAC,CAAC,KAAK,CAAC,GAAG,EAAE,CAAC,IAAI,CAAC,CAAC;IAClD,IAAI,CAAC,IAAI;QAAE,MAAM,IAAI,KAAK,CAAC,GAAG,IAAI,iBAAiB,CAAC,CAAC;IACrD,IAAI,IAAI,CAAC,WAAW,EAAE,EAAE,CAAC;QACvB,MAAM,OAAO,GAAG,IAAI,CAAC,MAAM,EAAE,cAAc,CAAC,CAAC;QAC7C,MAAM,GAAG,GAAG,IAAI,CAAC,KAAK,CAAC,MAAM,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC,CAAC,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OAAO,CAAC,KAAK,CAAE,CAAW,CAAC,OAAO,CAAC,CAAC;QACpC,OAAO,CAAC,CAAC;IACX,CAAC;AACH,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@polyxd/ds-kit",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.2",
|
|
4
4
|
"description": "Shared parts of building a Polyxd design-system pack: CSS variable reading, DTCG conversion, manifest writing",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"type": "module",
|
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
}
|
|
25
25
|
},
|
|
26
26
|
"devDependencies": {
|
|
27
|
-
"@polyxd/spec": "^0.2.
|
|
27
|
+
"@polyxd/spec": "^0.2.2"
|
|
28
28
|
},
|
|
29
29
|
"bin": {
|
|
30
30
|
"polyxd": "dist/polyxd.js"
|
|
@@ -41,7 +41,7 @@
|
|
|
41
41
|
"NOTICE"
|
|
42
42
|
],
|
|
43
43
|
"dependencies": {
|
|
44
|
-
"@polyxd/spec": "^0.2.
|
|
44
|
+
"@polyxd/spec": "^0.2.2"
|
|
45
45
|
},
|
|
46
46
|
"repository": {
|
|
47
47
|
"type": "git",
|