@bison-lab/payload-core 4.14.0 → 4.15.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.
Files changed (35) hide show
  1. package/README.md +88 -2
  2. package/dist/admin.d.mts +14 -1
  3. package/dist/admin.d.mts.map +1 -1
  4. package/dist/admin.mjs +149 -20
  5. package/dist/admin.mjs.map +1 -1
  6. package/dist/block-library.d.mts +1 -1
  7. package/dist/{catalogue-9MO2jy69.d.mts → catalogue-CFXM1yAZ.d.mts} +8 -1
  8. package/dist/catalogue-CFXM1yAZ.d.mts.map +1 -0
  9. package/dist/{facet-field-DHpNdS_u.d.mts → facet-field-_8bYI1i0.d.mts} +1 -1
  10. package/dist/{facet-field-DHpNdS_u.d.mts.map → facet-field-_8bYI1i0.d.mts.map} +1 -1
  11. package/dist/index.d.mts +53 -6
  12. package/dist/index.d.mts.map +1 -1
  13. package/dist/index.mjs +199 -2
  14. package/dist/index.mjs.map +1 -1
  15. package/dist/metadata.d.mts +1 -1
  16. package/dist/navigation.d.mts +1 -1
  17. package/dist/{preview-D-Psltpf.d.mts → preview-Vaa1KXJP.d.mts} +1 -1
  18. package/dist/{preview-D-Psltpf.d.mts.map → preview-Vaa1KXJP.d.mts.map} +1 -1
  19. package/dist/published-BjmUCpdY.mjs.map +1 -1
  20. package/dist/{published-DhARD4W8.d.mts → published-FUgC5Mc8.d.mts} +1 -1
  21. package/dist/{published-DhARD4W8.d.mts.map → published-FUgC5Mc8.d.mts.map} +1 -1
  22. package/dist/taxonomy.d.mts +1 -1
  23. package/dist/theme.d.mts +1 -1
  24. package/dist/{title-7VASfaFO.d.mts → title-ImlifZ_6.d.mts} +1 -1
  25. package/dist/{title-7VASfaFO.d.mts.map → title-ImlifZ_6.d.mts.map} +1 -1
  26. package/dist/wireframe-BTocmmyY.mjs +298 -0
  27. package/dist/wireframe-BTocmmyY.mjs.map +1 -0
  28. package/dist/wireframe-cli.d.mts +1 -0
  29. package/dist/wireframe-cli.mjs +110 -0
  30. package/dist/wireframe-cli.mjs.map +1 -0
  31. package/dist/wireframe.d.mts +119 -0
  32. package/dist/wireframe.d.mts.map +1 -0
  33. package/dist/wireframe.mjs +2 -0
  34. package/package.json +11 -4
  35. package/dist/catalogue-9MO2jy69.d.mts.map +0 -1
@@ -0,0 +1,110 @@
1
+ #!/usr/bin/env node
2
+ import { a as captureWireframes, s as svgDataUri } from "./wireframe-BTocmmyY.mjs";
3
+ import { createRequire } from "node:module";
4
+ import { mkdirSync, writeFileSync } from "node:fs";
5
+ import { dirname, join, resolve } from "node:path";
6
+ import { parseArgs } from "node:util";
7
+ //#region src/wireframe-cli.ts
8
+ /**
9
+ * `bison-wireframes`: writes a module of Add Block drawer thumbnails, one
10
+ * black-and-white wireframe per block, from a running site's Block library
11
+ * preview route. Run it from the site, which supplies Playwright and its
12
+ * browser; this package does not depend on either.
13
+ *
14
+ * WIREFRAME_EMAIL=… WIREFRAME_PASSWORD=… bison-wireframes \
15
+ * --base http://localhost:3039 \
16
+ * --slugs ctaBand,productMap \
17
+ * --out src/blocks/wireframes.generated.ts
18
+ *
19
+ * `--preview /block-library/{slug}` is the route (the default), `--selector`
20
+ * the element that holds the sample (default: `BlockLibraryIsland`'s), and
21
+ * `--users users` the auth collection to sign in to. The login is read from the
22
+ * environment, never from arguments, so it stays out of shell history, and
23
+ * is required unless `--no-login` names a public route. A preview that
24
+ * answers an error or renders no sample fails the run; nothing is written.
25
+ */
26
+ const { values } = parseArgs({ options: {
27
+ base: { type: "string" },
28
+ preview: {
29
+ type: "string",
30
+ default: "/block-library/{slug}"
31
+ },
32
+ selector: { type: "string" },
33
+ slugs: { type: "string" },
34
+ out: { type: "string" },
35
+ "svg-dir": { type: "string" },
36
+ users: {
37
+ type: "string",
38
+ default: "users"
39
+ },
40
+ export: {
41
+ type: "string",
42
+ default: "BLOCK_WIREFRAMES"
43
+ },
44
+ "no-login": {
45
+ type: "boolean",
46
+ default: false
47
+ }
48
+ } });
49
+ function fail(message) {
50
+ console.error(`bison-wireframes: ${message}`);
51
+ process.exit(1);
52
+ }
53
+ const base = values.base?.replace(/\/$/, "") ?? fail("--base is required");
54
+ const slugs = (values.slugs ?? fail("--slugs is required")).split(",").map((slug) => slug.trim()).filter(Boolean);
55
+ const out = values.out ?? fail("--out is required");
56
+ const email = process.env.WIREFRAME_EMAIL;
57
+ const password = process.env.WIREFRAME_PASSWORD;
58
+ if (!values["no-login"] && !(email && password)) fail("set WIREFRAME_EMAIL and WIREFRAME_PASSWORD, or pass --no-login for a public preview route");
59
+ const require = createRequire(join(process.cwd(), "package.json"));
60
+ let chromium;
61
+ try {
62
+ ({chromium} = require("playwright"));
63
+ } catch {
64
+ try {
65
+ ({chromium} = require("@playwright/test"));
66
+ } catch {
67
+ fail("needs playwright (or @playwright/test) installed in the project it runs from");
68
+ }
69
+ }
70
+ const browser = await chromium.launch();
71
+ try {
72
+ const context = await browser.newContext();
73
+ if (!values["no-login"]) {
74
+ const login = await context.request.post(`${base}/api/${values.users}/login`, { data: {
75
+ email,
76
+ password
77
+ } });
78
+ if (!login.ok()) fail(`sign-in to ${base} failed (${login.status()})`);
79
+ }
80
+ const svgs = await captureWireframes(await context.newPage(), slugs.map((slug) => ({
81
+ slug,
82
+ url: `${base}${values.preview.replace("{slug}", slug)}`
83
+ })), values.selector ? { selector: values.selector } : {});
84
+ if (values["svg-dir"]) {
85
+ mkdirSync(values["svg-dir"], { recursive: true });
86
+ for (const [slug, svg] of Object.entries(svgs)) writeFileSync(join(values["svg-dir"], `${slug}.svg`), svg);
87
+ }
88
+ const lines = Object.entries(svgs).map(([slug, svg]) => ` ${JSON.stringify(slug)}: ${JSON.stringify(svgDataUri(svg))},`);
89
+ const module = [
90
+ "// Generated by `bison-wireframes` (@bison-lab/payload-core) from each block's",
91
+ "// Block library preview. Do not edit by hand: rerun it when a layout changes.",
92
+ `export const ${values.export}: Record<string, string> = {`,
93
+ ...lines,
94
+ "};",
95
+ ""
96
+ ].join("\n");
97
+ const target = resolve(out);
98
+ mkdirSync(dirname(target), { recursive: true });
99
+ writeFileSync(target, module);
100
+ console.log(`bison-wireframes: wrote ${slugs.length} wireframes to ${out}`);
101
+ } catch (error) {
102
+ await browser.close();
103
+ fail(error instanceof Error ? error.message : String(error));
104
+ } finally {
105
+ await browser.close();
106
+ }
107
+ //#endregion
108
+ export {};
109
+
110
+ //# sourceMappingURL=wireframe-cli.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"wireframe-cli.mjs","names":[],"sources":["../src/wireframe-cli.ts"],"sourcesContent":["#!/usr/bin/env node\n/**\n * `bison-wireframes`: writes a module of Add Block drawer thumbnails, one\n * black-and-white wireframe per block, from a running site's Block library\n * preview route. Run it from the site, which supplies Playwright and its\n * browser; this package does not depend on either.\n *\n * WIREFRAME_EMAIL=… WIREFRAME_PASSWORD=… bison-wireframes \\\n * --base http://localhost:3039 \\\n * --slugs ctaBand,productMap \\\n * --out src/blocks/wireframes.generated.ts\n *\n * `--preview /block-library/{slug}` is the route (the default), `--selector`\n * the element that holds the sample (default: `BlockLibraryIsland`'s), and\n * `--users users` the auth collection to sign in to. The login is read from the\n * environment, never from arguments, so it stays out of shell history, and\n * is required unless `--no-login` names a public route. A preview that\n * answers an error or renders no sample fails the run; nothing is written.\n */\nimport { mkdirSync, writeFileSync } from \"node:fs\";\nimport { createRequire } from \"node:module\";\nimport { dirname, join, resolve } from \"node:path\";\nimport { parseArgs } from \"node:util\";\n\nimport { captureWireframes, svgDataUri, type WireframePage } from \"./wireframe\";\n\ntype Browser = {\n newContext(): Promise<{\n newPage(): Promise<WireframePage>;\n request: { post(url: string, options: { data: unknown }): Promise<{ ok(): boolean; status(): number }> };\n }>;\n close(): Promise<void>;\n};\n\nconst { values } = parseArgs({\n options: {\n base: { type: \"string\" },\n preview: { type: \"string\", default: \"/block-library/{slug}\" },\n selector: { type: \"string\" },\n slugs: { type: \"string\" },\n out: { type: \"string\" },\n \"svg-dir\": { type: \"string\" },\n users: { type: \"string\", default: \"users\" },\n export: { type: \"string\", default: \"BLOCK_WIREFRAMES\" },\n \"no-login\": { type: \"boolean\", default: false },\n },\n});\n\nfunction fail(message: string): never {\n console.error(`bison-wireframes: ${message}`);\n process.exit(1);\n}\n\nconst base = values.base?.replace(/\\/$/, \"\") ?? fail(\"--base is required\");\nconst slugs = (values.slugs ?? fail(\"--slugs is required\")).split(\",\").map((slug) => slug.trim()).filter(Boolean);\nconst out = values.out ?? fail(\"--out is required\");\nconst email = process.env.WIREFRAME_EMAIL;\nconst password = process.env.WIREFRAME_PASSWORD;\n// The Block library preview refuses a logged-out request, so a missing\n// login is an error unless the route is public (`--no-login`).\nif (!values[\"no-login\"] && !(email && password)) {\n fail(\"set WIREFRAME_EMAIL and WIREFRAME_PASSWORD, or pass --no-login for a public preview route\");\n}\n\n// Playwright from the site running this, not from this package.\nconst require = createRequire(join(process.cwd(), \"package.json\"));\nlet chromium: { launch(): Promise<Browser> };\ntry {\n ({ chromium } = require(\"playwright\") as { chromium: typeof chromium });\n} catch {\n try {\n ({ chromium } = require(\"@playwright/test\") as { chromium: typeof chromium });\n } catch {\n fail(\"needs playwright (or @playwright/test) installed in the project it runs from\");\n }\n}\n\nconst browser = await chromium.launch();\ntry {\n const context = await browser.newContext();\n if (!values[\"no-login\"]) {\n const login = await context.request.post(`${base}/api/${values.users}/login`, { data: { email, password } });\n if (!login.ok()) fail(`sign-in to ${base} failed (${login.status()})`);\n }\n const page = await context.newPage();\n const previews = slugs.map((slug) => ({ slug, url: `${base}${values.preview!.replace(\"{slug}\", slug)}` }));\n const svgs = await captureWireframes(page, previews, values.selector ? { selector: values.selector } : {});\n\n if (values[\"svg-dir\"]) {\n mkdirSync(values[\"svg-dir\"], { recursive: true });\n for (const [slug, svg] of Object.entries(svgs)) writeFileSync(join(values[\"svg-dir\"], `${slug}.svg`), svg);\n }\n\n const lines = Object.entries(svgs).map(([slug, svg]) => ` ${JSON.stringify(slug)}: ${JSON.stringify(svgDataUri(svg))},`);\n const module = [\n \"// Generated by `bison-wireframes` (@bison-lab/payload-core) from each block's\",\n \"// Block library preview. Do not edit by hand: rerun it when a layout changes.\",\n `export const ${values.export}: Record<string, string> = {`,\n ...lines,\n \"};\",\n \"\",\n ].join(\"\\n\");\n const target = resolve(out);\n mkdirSync(dirname(target), { recursive: true });\n writeFileSync(target, module);\n console.log(`bison-wireframes: wrote ${slugs.length} wireframes to ${out}`);\n} catch (error) {\n await browser.close();\n fail(error instanceof Error ? error.message : String(error));\n} finally {\n await browser.close();\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;AAkCA,MAAM,EAAE,WAAW,UAAU,EAC3B,SAAS;CACP,MAAM,EAAE,MAAM,UAAU;CACxB,SAAS;EAAE,MAAM;EAAU,SAAS;EAAyB;CAC7D,UAAU,EAAE,MAAM,UAAU;CAC5B,OAAO,EAAE,MAAM,UAAU;CACzB,KAAK,EAAE,MAAM,UAAU;CACvB,WAAW,EAAE,MAAM,UAAU;CAC7B,OAAO;EAAE,MAAM;EAAU,SAAS;EAAS;CAC3C,QAAQ;EAAE,MAAM;EAAU,SAAS;EAAoB;CACvD,YAAY;EAAE,MAAM;EAAW,SAAS;EAAO;CAChD,EACF,CAAC;AAEF,SAAS,KAAK,SAAwB;AACpC,SAAQ,MAAM,qBAAqB,UAAU;AAC7C,SAAQ,KAAK,EAAE;;AAGjB,MAAM,OAAO,OAAO,MAAM,QAAQ,OAAO,GAAG,IAAI,KAAK,qBAAqB;AAC1E,MAAM,SAAS,OAAO,SAAS,KAAK,sBAAsB,EAAE,MAAM,IAAI,CAAC,KAAK,SAAS,KAAK,MAAM,CAAC,CAAC,OAAO,QAAQ;AACjH,MAAM,MAAM,OAAO,OAAO,KAAK,oBAAoB;AACnD,MAAM,QAAQ,QAAQ,IAAI;AAC1B,MAAM,WAAW,QAAQ,IAAI;AAG7B,IAAI,CAAC,OAAO,eAAe,EAAE,SAAS,UACpC,MAAK,4FAA4F;AAInG,MAAM,UAAU,cAAc,KAAK,QAAQ,KA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AC/C,eAAc,QAAQ,OAAO;AAC7B,SAAQ,IAAI,2BAA2B,MAAM,OAAO,iBAAiB,MAAM;SACpE,OAAO;AACd,OAAM,QAAQ,OAAO;AACrB,MAAK,iBAAiB,QAAQ,MAAM,UAAU,OAAO,MAAM,CAAC;UACpD;AACR,OAAM,QAAQ,OAAO"}
@@ -0,0 +1,119 @@
1
+ //#region src/wireframe.d.ts
2
+ /**
3
+ * Black-and-white wireframes of Block library samples, for Payload's Add
4
+ * Block drawer (`admin.images.thumbnail`). React-free and Payload-free: a
5
+ * script drives a browser to each block's preview (`previewPath(slug)`),
6
+ * `extractWireframe` reads where the headings, text, images, buttons and
7
+ * surfaces sit, and `wireframeSvg` draws those boxes as greyscale shapes.
8
+ * No copy and no brand color reach the picture, so it does not go stale
9
+ * when Theme changes; rerun it when a block's layout does.
10
+ */
11
+ /** Payload's drawer card is 3:2; 480 × 320 is the size its docs suggest. */
12
+ declare const WIREFRAME_WIDTH = 480;
13
+ declare const WIREFRAME_HEIGHT = 320;
14
+ /** Desktop width, so the picture is the layout most visitors see. */
15
+ declare const WIREFRAME_VIEWPORT: {
16
+ readonly width: 1280;
17
+ readonly height: 900;
18
+ };
19
+ /** The element the Block library preview wraps each sample in (`BlockLibraryIsland`). */
20
+ declare const WIREFRAME_ROOT = "[data-block-library-island]";
21
+ /** `light` draws light marks (they sit on a dark surface); `dark` draws dark ones (on paper). */
22
+ type WireframeTone = "light" | "dark";
23
+ type WireframeShape = /** A band or panel the block paints. `dark` is a dark fill; `light` a pale tint. */{
24
+ kind: "surface";
25
+ x: number;
26
+ y: number;
27
+ w: number;
28
+ h: number;
29
+ tone: WireframeTone;
30
+ } /** A bordered card with no fill of its own. */ | {
31
+ kind: "frame";
32
+ x: number;
33
+ y: number;
34
+ w: number;
35
+ h: number;
36
+ tone: WireframeTone;
37
+ } | {
38
+ kind: "image";
39
+ x: number;
40
+ y: number;
41
+ w: number;
42
+ h: number;
43
+ } | {
44
+ kind: "heading" | "text" | "icon";
45
+ x: number;
46
+ y: number;
47
+ w: number;
48
+ h: number;
49
+ tone: WireframeTone;
50
+ } | {
51
+ kind: "button";
52
+ x: number;
53
+ y: number;
54
+ w: number;
55
+ h: number;
56
+ filled: boolean;
57
+ tone: WireframeTone;
58
+ } | {
59
+ kind: "field";
60
+ x: number;
61
+ y: number;
62
+ w: number;
63
+ h: number;
64
+ };
65
+ type WireframeCapture = {
66
+ width: number;
67
+ height: number;
68
+ shapes: WireframeShape[];
69
+ };
70
+ /**
71
+ * Runs in the page (Playwright's `page.evaluate`), so it closes over
72
+ * nothing: every helper is declared inside. Boxes are relative to the
73
+ * element `selector` names (the preview's island), in CSS pixels.
74
+ */
75
+ declare function extractWireframe(selector: string): WireframeCapture;
76
+ /**
77
+ * A capture as a 480 × 320 greyscale SVG. The block is scaled to the
78
+ * width; a short block is centered, a tall one keeps its top and is clipped.
79
+ * Surfaces first, text last, so marks sit on what they sit on in the page.
80
+ */
81
+ declare function wireframeSvg(capture: WireframeCapture): string;
82
+ /**
83
+ * An SVG as a `data:` URI for `admin.images.thumbnail`. Only the characters
84
+ * a URI cannot carry are escaped, so the string stays close to the SVG's
85
+ * own size; the SVG must use single quotes.
86
+ */
87
+ declare function svgDataUri(svg: string): string;
88
+ /** The slice of Playwright's `Page` this needs; a site passes its own. */
89
+ interface WireframePage {
90
+ setViewportSize(size: {
91
+ width: number;
92
+ height: number;
93
+ }): Promise<void>;
94
+ /** Playwright's `Response` (or `null`); a status of 400 or more refuses the capture. */
95
+ goto(url: string, options?: {
96
+ waitUntil?: "load" | "domcontentloaded" | "networkidle";
97
+ }): Promise<{
98
+ status(): number;
99
+ } | null | void>;
100
+ evaluate<R, A>(fn: (arg: A) => R | Promise<R>, arg: A): Promise<R>;
101
+ }
102
+ /**
103
+ * Opens each preview at desktop width, waits for its fonts, and returns
104
+ * one SVG per slug. The page must already be signed in when the preview
105
+ * route needs it (the Block library's does). A preview that answers 400 or
106
+ * more, or renders no element `selector` matches, throws: nothing is
107
+ * written for a page that did not draw its sample.
108
+ */
109
+ declare function captureWireframes(page: WireframePage, previews: readonly {
110
+ slug: string;
111
+ url: string;
112
+ }[], {
113
+ selector
114
+ }?: {
115
+ selector?: string;
116
+ }): Promise<Record<string, string>>;
117
+ //#endregion
118
+ export { WIREFRAME_HEIGHT, WIREFRAME_ROOT, WIREFRAME_VIEWPORT, WIREFRAME_WIDTH, WireframeCapture, WireframePage, WireframeShape, WireframeTone, captureWireframes, extractWireframe, svgDataUri, wireframeSvg };
119
+ //# sourceMappingURL=wireframe.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"wireframe.d.mts","names":[],"sources":["../src/wireframe.ts"],"mappings":";;AAWA;;;;;AACA;;;;cADa,eAAA;AAAA,cACA,gBAAA;;cAGA,kBAAA;EAAA,SAA0D,KAAA;EAAA,SAAA,MAAA;AAAA;;cAG1D,cAAA;;KAGD,aAAA;AAAA,KAEA,cAAA;EAEN,IAAA;EAAiB,CAAA;EAAW,CAAA;EAAW,CAAA;EAAW,CAAA;EAAW,IAAA,EAAM,aAAA;AAAA;EAEnE,IAAA;EAAe,CAAA;EAAW,CAAA;EAAW,CAAA;EAAW,CAAA;EAAW,IAAA,EAAM,aAAA;AAAA;EACjE,IAAA;EAAe,CAAA;EAAW,CAAA;EAAW,CAAA;EAAW,CAAA;AAAA;EAChD,IAAA;EAAmC,CAAA;EAAW,CAAA;EAAW,CAAA;EAAW,CAAA;EAAW,IAAA,EAAM,aAAA;AAAA;EACrF,IAAA;EAAgB,CAAA;EAAW,CAAA;EAAW,CAAA;EAAW,CAAA;EAAW,MAAA;EAAiB,IAAA,EAAM,aAAA;AAAA;EACnF,IAAA;EAAe,CAAA;EAAW,CAAA;EAAW,CAAA;EAAW,CAAA;AAAA;AAAA,KAE1C,gBAAA;EAAqB,KAAA;EAAe,MAAA;EAAgB,MAAA,EAAQ,cAAA;AAAA;;;;;AAAxE;iBAOgB,gBAAA,CAAiB,QAAA,WAAmB,gBAAA;;;;;;iBAiLpC,YAAA,CAAa,OAAA,EAAS,gBAAA;;;AAjLtC;;;iBA8OgB,UAAA,CAAW,GAAA;;UASV,aAAA;EACf,eAAA,CAAgB,IAAA;IAAQ,KAAA;IAAe,MAAA;EAAA,IAAmB,OAAA;EAV5C;EAYd,IAAA,CACE,GAAA,UACA,OAAA;IAAY,SAAA;EAAA,IACX,OAAA;IAAU,MAAA;EAAA;EACb,QAAA,OAAe,EAAA,GAAK,GAAA,EAAK,CAAA,KAAM,CAAA,GAAI,OAAA,CAAQ,CAAA,GAAI,GAAA,EAAK,CAAA,GAAI,OAAA,CAAQ,CAAA;AAAA;;;;;;;;iBAU5C,iBAAA,CACpB,IAAA,EAAM,aAAA,EACN,QAAA;EAAqB,IAAA;EAAc,GAAA;AAAA;EACjC;AAAA;EAA+B,QAAA;AAAA,IAChC,OAAA,CAAQ,MAAA"}
@@ -0,0 +1,2 @@
1
+ import { a as captureWireframes, c as wireframeSvg, i as WIREFRAME_WIDTH, n as WIREFRAME_ROOT, o as extractWireframe, r as WIREFRAME_VIEWPORT, s as svgDataUri, t as WIREFRAME_HEIGHT } from "./wireframe-BTocmmyY.mjs";
2
+ export { WIREFRAME_HEIGHT, WIREFRAME_ROOT, WIREFRAME_VIEWPORT, WIREFRAME_WIDTH, captureWireframes, extractWireframe, svgDataUri, wireframeSvg };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bison-lab/payload-core",
3
- "version": "4.14.0",
3
+ "version": "4.15.0",
4
4
  "description": "Site-agnostic Payload CMS configuration for Bison Lab sites: the SEO tab, the Theme global, the Roles Global, the brand-assets cupboard, and the metadata and theme readers for the pages they describe",
5
5
  "keywords": [
6
6
  "bison-lab",
@@ -23,6 +23,9 @@
23
23
  "url": "https://github.com/Bison-Lab-LLC/bisonlab-component-library/issues"
24
24
  },
25
25
  "type": "module",
26
+ "bin": {
27
+ "bison-wireframes": "./dist/wireframe-cli.mjs"
28
+ },
26
29
  "main": "./dist/index.mjs",
27
30
  "types": "./dist/index.d.mts",
28
31
  "exports": {
@@ -50,6 +53,10 @@
50
53
  "import": "./dist/taxonomy.mjs",
51
54
  "types": "./dist/taxonomy.d.mts"
52
55
  },
56
+ "./wireframe": {
57
+ "import": "./dist/wireframe.mjs",
58
+ "types": "./dist/wireframe.d.mts"
59
+ },
53
60
  "./admin": {
54
61
  "import": "./dist/admin.mjs",
55
62
  "types": "./dist/admin.d.mts"
@@ -64,7 +71,7 @@
64
71
  ],
65
72
  "dependencies": {
66
73
  "react-colorful": "^5.8.1",
67
- "@bison-lab/admin-ui": "4.9.2"
74
+ "@bison-lab/admin-ui": "4.15.0"
68
75
  },
69
76
  "peerDependencies": {
70
77
  "@bison-lab/fonts": "^3.0.0 || ^4.0.0",
@@ -123,9 +130,9 @@
123
130
  "tsdown": "^0.21.0",
124
131
  "typescript": "^5.9.3",
125
132
  "vitest": "^4.1.2",
126
- "@bison-lab/fonts": "3.27.1",
127
133
  "@bison-lab/tokens": "4.5.0",
128
- "@bison-lab/ui": "4.13.0"
134
+ "@bison-lab/ui": "4.13.0",
135
+ "@bison-lab/fonts": "3.27.1"
129
136
  },
130
137
  "publishConfig": {
131
138
  "access": "public"
@@ -1 +0,0 @@
1
- {"version":3,"file":"catalogue-9MO2jy69.d.mts","names":[],"sources":["../src/block-library/types.ts","../src/block-library/controls.ts","../src/block-library/published.ts","../src/block-library/catalogue.ts"],"mappings":";;;cAEa,kBAAA;AAAA,cAEA,wBAAA;EAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAaD,sBAAA,WAAiC,wBAAA;AAAA,KAEjC,gBAAA;;;;;AAAZ;cAOa,mBAAA;AAAA,KAcD,gBAAA,WAA2B,mBAAA;AAAA,UAEtB,iBAAA;EACf,IAAA;EACA,KAAA;EACA,QAAA;;EAEA,IAAA,GAAO,gBAAA;EACP,YAAA;EACA,MAAA;EAT0B;;;;AAE5B;;EAcE,eAAA,GAAkB,OAAA,CAAQ,eAAA;AAAA;AAAA,UAGX,eAA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