@imfusion/web-ui 0.10.1-dev.6.gf715361a → 0.10.1-dev.60.g7891a716
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/CHANGELOG.md +159 -0
- package/README.md +8 -32
- package/THIRD_PARTY_NOTICES.md +110 -0
- package/dist/code-NTcddiYk.js +139 -0
- package/dist/components/account-card/account-card.d.ts +9 -26
- package/dist/components/app-shell/app-shell.d.ts +48 -26
- package/dist/components/callout/callout.d.ts +1 -1
- package/dist/components/chip/chip.d.ts +1 -1
- package/dist/components/color-scheme-toggle/color-scheme-preference.d.ts +3 -0
- package/dist/components/color-scheme-toggle/color-scheme-toggle.d.ts +17 -0
- package/dist/components/color-scheme-toggle/color-scheme-toggle.meta.d.ts +2 -0
- package/dist/components/color-scheme-toggle/index.d.ts +2 -0
- package/dist/components/dialog/dialog.d.ts +151 -0
- package/dist/components/dialog/dialog.meta.d.ts +2 -0
- package/dist/components/dialog/index.d.ts +2 -0
- package/dist/components/drawer/drawer.d.ts +1 -1
- package/dist/components/logo/index.d.ts +1 -0
- package/dist/components/logo/product/index.d.ts +1 -0
- package/dist/components/logo/product/marks.d.ts +11 -0
- package/dist/components/logo/product/product.d.ts +17 -0
- package/dist/components/scroll-area/index.d.ts +2 -0
- package/dist/components/scroll-area/scroll-area.d.ts +49 -0
- package/dist/components/scroll-area/scroll-area.meta.d.ts +2 -0
- package/dist/components/select/select.d.ts +18 -4
- package/dist/components/separator/separator.d.ts +4 -2
- package/dist/components/skeleton/skeleton.d.ts +17 -2
- package/dist/components/table/table.d.ts +12 -4
- package/dist/components/toggle/toggle.d.ts +8 -2
- package/dist/components/toggle-group/toggle-group-size.d.ts +3 -0
- package/dist/components/toggle-group/toggle-group.d.ts +7 -3
- package/dist/hooks/index.d.ts +2 -0
- package/dist/hooks/use-disclosure.d.ts +17 -0
- package/dist/icons.js +1 -2
- package/dist/index.d.ts +7 -3
- package/dist/index.js +2705 -2093
- package/dist/integrations/code-highlight.js +2 -2
- package/dist/integrations/frame-selection.js +2 -2
- package/dist/integrations/image-display-options.js +123 -113
- package/dist/{rolldown-runtime-Dy4uBu1J.js → resolve-state-props-DQf9WiGv.js} +12 -1
- package/dist/scroll-area-z9Lf9uIk.js +89 -0
- package/dist/{separator-lzz4A3x_.js → separator-BV2TR8U0.js} +16 -8
- package/dist/slider-Bf274cMe.js +106 -0
- package/dist/style.css +1 -1
- package/dist/{tabs-DRyqtS04.js → tabs-CU46aGud.js} +106 -88
- package/dist/vite/local-web-ui-link.d.ts +17 -4
- package/dist/vite.js +25 -20
- package/dist/web-ui-cli.js +11 -11
- package/docs/user-guide/UsagePatterns.mdx +4 -0
- package/package.json +11 -9
- package/src/docgen/doc.gen.json +2292 -1071
- package/src/llms/install-templates/hooks/baseline-staleness.sh +2 -0
- package/src/llms/install-templates/hooks/stop.sh +7 -2
- package/src/llms/llms.gen.txt +18 -1
- package/src/llms/skills/imf-web-ui-audit/SKILL.md +24 -11
- package/src/llms/skills/imf-web-ui-conventions/templates/AUDIT_CHECKLIST.md +4 -2
- package/src/llms/skills/imf-web-ui-conventions/topics/data.md +17 -2
- package/src/llms/skills/imf-web-ui-conventions/topics/git.md +5 -2
- package/src/llms/skills/imf-web-ui-conventions/topics/library-setup.md +3 -0
- package/src/llms/skills/imf-web-ui-conventions/topics/project-structure.md +5 -2
- package/src/llms/skills/imf-web-ui-conventions/topics/styling.md +3 -1
- package/src/llms/skills/imf-web-ui-conventions/topics/tooling.md +47 -8
- package/src/llms/skills/imf-web-ui-conventions/topics/typescript.md +2 -0
- package/src/llms/skills/imf-web-ui-setup/SKILL.md +10 -1
- package/src/llms/skills/imf-web-ui-update/SKILL.md +7 -0
- package/src/llms/skills/imf-web-ui-ux/SKILL.md +47 -26
- package/src/llms/skills/imf-web-ui-ux/references/forms.md +6 -6
- package/src/llms/skills/imf-web-ui-ux/references/usability-heuristics.md +3 -3
- package/src/llms/skills/imf-web-ui-ux/references/visual-design.md +3 -3
- package/src/llms/tokens.gen.json +13 -5
- package/dist/code-BYkr5k55.js +0 -134
- package/dist/slider-Cqpreglu.js +0 -116
|
@@ -1,50 +1,49 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { mh as
|
|
3
|
-
import { t as
|
|
4
|
-
import { l as i, u as a } from "./slider-Cqpreglu.js";
|
|
1
|
+
import { n as e, r as t, t as n } from "./resolve-state-props-DQf9WiGv.js";
|
|
2
|
+
import { mh as r, pM as i } from "./icons-BsK_o-Cb.js";
|
|
3
|
+
import { t as a } from "./meta-V_KyLeGn.js";
|
|
5
4
|
import { cva as o } from "class-variance-authority";
|
|
6
5
|
import { jsx as s, jsxs as c } from "react/jsx-runtime";
|
|
7
|
-
import { Children as l,
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import { Tabs as
|
|
12
|
-
var
|
|
6
|
+
import { Children as l, createContext as u, useCallback as d, useContext as f } from "react";
|
|
7
|
+
import { Toggle as p } from "@base-ui/react/toggle";
|
|
8
|
+
import { ToggleGroup as ee } from "@base-ui/react/toggle-group";
|
|
9
|
+
import { Switch as m } from "@base-ui/react/switch";
|
|
10
|
+
import { Tabs as h } from "@base-ui/react/tabs";
|
|
11
|
+
var g = {
|
|
13
12
|
flat: "imf-ui-kbd-module-flat",
|
|
14
13
|
icon: "imf-ui-kbd-module-icon",
|
|
15
14
|
primary: "imf-ui-kbd-module-primary",
|
|
16
15
|
root: "imf-ui-kbd-module-root"
|
|
17
|
-
},
|
|
16
|
+
}, _ = o(g.root, { variants: { variant: {
|
|
18
17
|
default: null,
|
|
19
|
-
primary:
|
|
20
|
-
flat:
|
|
18
|
+
primary: g.primary,
|
|
19
|
+
flat: g.flat
|
|
21
20
|
} } });
|
|
22
|
-
function
|
|
21
|
+
function v({ variant: e = "default", icon: t = !1, children: n, ...a }) {
|
|
23
22
|
return /* @__PURE__ */ c("kbd", {
|
|
24
23
|
...a,
|
|
25
24
|
"data-imf-ui-component": "Kbd",
|
|
26
|
-
className:
|
|
25
|
+
className: _({
|
|
27
26
|
variant: e,
|
|
28
27
|
className: a.className
|
|
29
28
|
}),
|
|
30
|
-
children: [
|
|
31
|
-
glyph:
|
|
29
|
+
children: [t && /* @__PURE__ */ s(i, {
|
|
30
|
+
glyph: r,
|
|
32
31
|
strokeWidth: 2,
|
|
33
32
|
"aria-hidden": !0,
|
|
34
|
-
className:
|
|
35
|
-
}),
|
|
33
|
+
className: g.icon
|
|
34
|
+
}), n]
|
|
36
35
|
});
|
|
37
36
|
}
|
|
38
37
|
//#endregion
|
|
39
38
|
//#region src/components/kbd/kbd.meta.ts
|
|
40
|
-
var
|
|
39
|
+
var te = {
|
|
41
40
|
name: "Kbd",
|
|
42
|
-
category:
|
|
41
|
+
category: a.display,
|
|
43
42
|
status: "experimental",
|
|
44
43
|
description: "Shows a keyboard key or shortcut, such as the letter that activates a button. Also called a key hint; Button and Toggle render it through their `shortcut` prop.",
|
|
45
44
|
origin: "native",
|
|
46
45
|
internalDependencies: ["Icon"]
|
|
47
|
-
},
|
|
46
|
+
}, y = {
|
|
48
47
|
ctrl: "Control",
|
|
49
48
|
control: "Control",
|
|
50
49
|
cmd: "Meta",
|
|
@@ -59,75 +58,94 @@ var ee = {
|
|
|
59
58
|
esc: "Escape",
|
|
60
59
|
escape: "Escape"
|
|
61
60
|
};
|
|
62
|
-
function
|
|
61
|
+
function b(e) {
|
|
63
62
|
let t = e.trim().split(/\s+/).filter(Boolean);
|
|
64
|
-
if (t.length !== 0) return t.map((e) =>
|
|
63
|
+
if (t.length !== 0) return t.map((e) => y[e.toLowerCase()] ?? (e.length === 1 ? e.toUpperCase() : e)).join("+");
|
|
65
64
|
}
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
}, x = /* @__PURE__ */ e({
|
|
70
|
-
Root: () => w,
|
|
71
|
-
Thumb: () => T
|
|
72
|
-
}), S = o(b.root), C = o(b.thumb);
|
|
73
|
-
function w(e) {
|
|
74
|
-
return /* @__PURE__ */ s(d.Root, {
|
|
75
|
-
...e,
|
|
76
|
-
"data-imf-ui-component": "Switch.Root",
|
|
77
|
-
className: (t) => S({ className: i(e.className, t) })
|
|
78
|
-
});
|
|
79
|
-
}
|
|
80
|
-
w.displayName = "Switch.Root";
|
|
81
|
-
function T(e) {
|
|
82
|
-
return /* @__PURE__ */ s(d.Thumb, {
|
|
83
|
-
...e,
|
|
84
|
-
"data-imf-ui-component": "Switch.Thumb",
|
|
85
|
-
className: (t) => C({ className: i(e.className, t) })
|
|
86
|
-
});
|
|
87
|
-
}
|
|
88
|
-
T.displayName = "Switch.Thumb";
|
|
89
|
-
var E = {
|
|
65
|
+
//#endregion
|
|
66
|
+
//#region src/components/toggle-group/toggle-group-size.ts
|
|
67
|
+
var x = u("md"), S = {
|
|
90
68
|
root: "imf-ui-toggle-module-root",
|
|
91
|
-
shortcut: "imf-ui-toggle-module-shortcut"
|
|
92
|
-
|
|
93
|
-
|
|
69
|
+
shortcut: "imf-ui-toggle-module-shortcut",
|
|
70
|
+
sizeSm: "imf-ui-toggle-module-sizeSm"
|
|
71
|
+
}, C = o(S.root, { variants: { size: {
|
|
72
|
+
sm: S.sizeSm,
|
|
73
|
+
md: null
|
|
74
|
+
} } }), w = 2;
|
|
75
|
+
function T(e) {
|
|
94
76
|
let t = 0;
|
|
95
77
|
return l.forEach(e, (e) => {
|
|
96
|
-
typeof e == "string" || typeof e == "number" ? t += String(e).trim().length : e != null && typeof e != "boolean" && (t +=
|
|
78
|
+
typeof e == "string" || typeof e == "number" ? t += String(e).trim().length : e != null && typeof e != "boolean" && (t += w);
|
|
97
79
|
}), t;
|
|
98
80
|
}
|
|
99
|
-
function
|
|
100
|
-
let
|
|
101
|
-
"--glyph-count":
|
|
102
|
-
"--max-glyphs":
|
|
81
|
+
function ne({ style: t, shortcut: r, size: i, children: a, ...o }) {
|
|
82
|
+
let l = f(x), u = {
|
|
83
|
+
"--glyph-count": T(a),
|
|
84
|
+
"--max-glyphs": w
|
|
103
85
|
};
|
|
104
|
-
return /* @__PURE__ */ c(
|
|
105
|
-
"aria-keyshortcuts":
|
|
106
|
-
...
|
|
86
|
+
return /* @__PURE__ */ c(p, {
|
|
87
|
+
"aria-keyshortcuts": r ? b(r) : void 0,
|
|
88
|
+
...o,
|
|
107
89
|
"data-imf-ui-component": "Toggle",
|
|
108
|
-
style: (
|
|
109
|
-
...
|
|
110
|
-
...
|
|
90
|
+
style: (n) => ({
|
|
91
|
+
...u,
|
|
92
|
+
...e(t, n)
|
|
93
|
+
}),
|
|
94
|
+
className: (e) => C({
|
|
95
|
+
size: i ?? l,
|
|
96
|
+
className: n(o.className, e)
|
|
111
97
|
}),
|
|
112
|
-
|
|
113
|
-
children: [n, t && /* @__PURE__ */ s(_, {
|
|
98
|
+
children: [a, r && /* @__PURE__ */ s(v, {
|
|
114
99
|
variant: "flat",
|
|
115
|
-
className:
|
|
100
|
+
className: S.shortcut,
|
|
116
101
|
"aria-hidden": !0,
|
|
117
|
-
children:
|
|
102
|
+
children: r
|
|
118
103
|
})]
|
|
119
104
|
});
|
|
120
105
|
}
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
106
|
+
var E = {
|
|
107
|
+
root: "imf-ui-toggle-group-module-root",
|
|
108
|
+
sizeSm: "imf-ui-toggle-group-module-sizeSm"
|
|
109
|
+
}, re = o(E.root, { variants: { size: {
|
|
110
|
+
sm: E.sizeSm,
|
|
111
|
+
md: null
|
|
112
|
+
} } });
|
|
113
|
+
function ie({ size: e = "md", ...t }) {
|
|
114
|
+
return /* @__PURE__ */ s(x.Provider, {
|
|
115
|
+
value: e ?? "md",
|
|
116
|
+
children: /* @__PURE__ */ s(ee, {
|
|
117
|
+
...t,
|
|
118
|
+
"data-imf-ui-component": "ToggleGroup",
|
|
119
|
+
className: (r) => re({
|
|
120
|
+
size: e,
|
|
121
|
+
className: n(t.className, r)
|
|
122
|
+
})
|
|
123
|
+
})
|
|
124
|
+
});
|
|
125
|
+
}
|
|
126
|
+
var D = {
|
|
127
|
+
root: "imf-ui-switch-module-root",
|
|
128
|
+
thumb: "imf-ui-switch-module-thumb"
|
|
129
|
+
}, ae = /* @__PURE__ */ t({
|
|
130
|
+
Root: () => A,
|
|
131
|
+
Thumb: () => j
|
|
132
|
+
}), O = o(D.root), k = o(D.thumb);
|
|
133
|
+
function A(e) {
|
|
134
|
+
return /* @__PURE__ */ s(m.Root, {
|
|
135
|
+
...e,
|
|
136
|
+
"data-imf-ui-component": "Switch.Root",
|
|
137
|
+
className: (t) => O({ className: n(e.className, t) })
|
|
138
|
+
});
|
|
139
|
+
}
|
|
140
|
+
A.displayName = "Switch.Root";
|
|
124
141
|
function j(e) {
|
|
125
|
-
return /* @__PURE__ */ s(
|
|
142
|
+
return /* @__PURE__ */ s(m.Thumb, {
|
|
126
143
|
...e,
|
|
127
|
-
"data-imf-ui-component": "
|
|
128
|
-
className: (t) =>
|
|
144
|
+
"data-imf-ui-component": "Switch.Thumb",
|
|
145
|
+
className: (t) => k({ className: n(e.className, t) })
|
|
129
146
|
});
|
|
130
147
|
}
|
|
148
|
+
j.displayName = "Switch.Thumb";
|
|
131
149
|
var M = {
|
|
132
150
|
alignCenter: "imf-ui-row-module-alignCenter",
|
|
133
151
|
alignEnd: "imf-ui-row-module-alignEnd",
|
|
@@ -268,7 +286,7 @@ var R = {
|
|
|
268
286
|
panelViewport: "imf-ui-tabs-module-panelViewport",
|
|
269
287
|
root: "imf-ui-tabs-module-root",
|
|
270
288
|
tab: "imf-ui-tabs-module-tab"
|
|
271
|
-
}, z = /* @__PURE__ */
|
|
289
|
+
}, z = /* @__PURE__ */ t({
|
|
272
290
|
Indicator: () => Z,
|
|
273
291
|
List: () => Y,
|
|
274
292
|
Panel: () => $,
|
|
@@ -295,15 +313,15 @@ function q(e) {
|
|
|
295
313
|
};
|
|
296
314
|
}
|
|
297
315
|
function J(e) {
|
|
298
|
-
return /* @__PURE__ */ s(
|
|
316
|
+
return /* @__PURE__ */ s(h.Root, {
|
|
299
317
|
...e,
|
|
300
318
|
"data-imf-ui-component": "Tabs.Root",
|
|
301
|
-
className: (t) => V({ className:
|
|
319
|
+
className: (t) => V({ className: n(e.className, t) })
|
|
302
320
|
});
|
|
303
321
|
}
|
|
304
322
|
J.displayName = "Tabs.Root";
|
|
305
|
-
function Y({ fill: e = !1, ref: t, ...
|
|
306
|
-
let
|
|
323
|
+
function Y({ fill: e = !1, ref: t, ...r }) {
|
|
324
|
+
let i = d((e) => {
|
|
307
325
|
if (!e) return;
|
|
308
326
|
K(t, e);
|
|
309
327
|
let n = q(e);
|
|
@@ -311,30 +329,30 @@ function Y({ fill: e = !1, ref: t, ...n }) {
|
|
|
311
329
|
n(), K(t, null);
|
|
312
330
|
};
|
|
313
331
|
}, [t]);
|
|
314
|
-
return /* @__PURE__ */ s(
|
|
315
|
-
...
|
|
316
|
-
ref:
|
|
332
|
+
return /* @__PURE__ */ s(h.List, {
|
|
333
|
+
...r,
|
|
334
|
+
ref: i,
|
|
317
335
|
"data-imf-ui-component": "Tabs.List",
|
|
318
336
|
className: (t) => B({
|
|
319
337
|
fill: e,
|
|
320
|
-
className:
|
|
338
|
+
className: n(r.className, t)
|
|
321
339
|
})
|
|
322
340
|
});
|
|
323
341
|
}
|
|
324
342
|
Y.displayName = "Tabs.List";
|
|
325
343
|
function X(e) {
|
|
326
|
-
return /* @__PURE__ */ s(
|
|
344
|
+
return /* @__PURE__ */ s(h.Tab, {
|
|
327
345
|
...e,
|
|
328
346
|
"data-imf-ui-component": "Tabs.Tab",
|
|
329
|
-
className: (t) => H({ className:
|
|
347
|
+
className: (t) => H({ className: n(e.className, t) })
|
|
330
348
|
});
|
|
331
349
|
}
|
|
332
350
|
X.displayName = "Tabs.Tab";
|
|
333
351
|
function Z(e) {
|
|
334
|
-
return /* @__PURE__ */ s(
|
|
352
|
+
return /* @__PURE__ */ s(h.Indicator, {
|
|
335
353
|
...e,
|
|
336
354
|
"data-imf-ui-component": "Tabs.Indicator",
|
|
337
|
-
className: (t) => U({ className:
|
|
355
|
+
className: (t) => U({ className: n(e.className, t) })
|
|
338
356
|
});
|
|
339
357
|
}
|
|
340
358
|
Z.displayName = "Tabs.Indicator";
|
|
@@ -347,12 +365,12 @@ function Q(e) {
|
|
|
347
365
|
}
|
|
348
366
|
Q.displayName = "Tabs.PanelViewport";
|
|
349
367
|
function $(e) {
|
|
350
|
-
return /* @__PURE__ */ s(
|
|
368
|
+
return /* @__PURE__ */ s(h.Panel, {
|
|
351
369
|
...e,
|
|
352
370
|
"data-imf-ui-component": "Tabs.Panel",
|
|
353
|
-
className: (t) => G({ className:
|
|
371
|
+
className: (t) => G({ className: n(e.className, t) })
|
|
354
372
|
});
|
|
355
373
|
}
|
|
356
374
|
$.displayName = "Tabs.Panel";
|
|
357
375
|
//#endregion
|
|
358
|
-
export { _, J as a, L as c,
|
|
376
|
+
export { v as _, J as a, L as c, j as d, ae as f, te as g, b as h, Q as i, P as l, ne as m, Y as n, X as o, ie as p, $ as r, z as s, Z as t, A as u };
|
|
@@ -1,8 +1,21 @@
|
|
|
1
1
|
import { Plugin, UserConfig } from 'vite';
|
|
2
|
-
|
|
3
|
-
|
|
2
|
+
interface LinkConfig extends UserConfig {
|
|
3
|
+
test?: {
|
|
4
|
+
server?: {
|
|
5
|
+
deps?: {
|
|
6
|
+
inline?: (string | RegExp)[];
|
|
7
|
+
};
|
|
8
|
+
};
|
|
9
|
+
};
|
|
10
|
+
}
|
|
4
11
|
/**
|
|
5
|
-
*
|
|
6
|
-
*
|
|
12
|
+
* Returns `undefined` unless `node_modules/@imfusion/web-ui` under `root` is a symlink. A symlinked checkout resolves its
|
|
13
|
+
* own copy of every peer, so the peers are deduped for Vite and the checkout's dependencies are inlined for Vitest.
|
|
14
|
+
*/
|
|
15
|
+
export declare function localWebUILinkConfig(root: string): LinkConfig | undefined;
|
|
16
|
+
/**
|
|
17
|
+
* Lets a consumer keep `localWebUILink()` registered for good. It does nothing for an installed package. With a
|
|
18
|
+
* `file:` dependency on a Web UI checkout it makes the checkout share the app's React.
|
|
7
19
|
*/
|
|
8
20
|
export declare function localWebUILink(): Plugin;
|
|
21
|
+
export {};
|
package/dist/vite.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { n as e } from "./paths-B5Ht3ETc.js";
|
|
2
|
-
import {
|
|
3
|
-
import { dirname as
|
|
2
|
+
import { existsSync as t, readFileSync as n, readdirSync as r, realpathSync as i } from "node:fs";
|
|
3
|
+
import { dirname as a, join as o, resolve as s } from "node:path";
|
|
4
4
|
import { fileURLToPath as c } from "node:url";
|
|
5
5
|
//#region src/vite/brand-assets.ts
|
|
6
|
-
var l =
|
|
6
|
+
var l = a(c(import.meta.resolve("@imfusion/web-ui/assets/favicon/favicon.svg"))), u = r(l).map((e) => ({
|
|
7
7
|
name: e,
|
|
8
|
-
source:
|
|
8
|
+
source: n(o(l, e))
|
|
9
9
|
})), d = {
|
|
10
10
|
".ico": "image/x-icon",
|
|
11
11
|
".png": "image/png",
|
|
@@ -20,11 +20,7 @@ function p() {
|
|
|
20
20
|
configureServer(e) {
|
|
21
21
|
e.middlewares.use((e, t, n) => {
|
|
22
22
|
let r = u.find(({ name: t }) => e.url?.split("?")[0] === `/${t}`);
|
|
23
|
-
|
|
24
|
-
n();
|
|
25
|
-
return;
|
|
26
|
-
}
|
|
27
|
-
t.setHeader("Content-Type", f(r.name)), t.end(r.source);
|
|
23
|
+
r ? (t.setHeader("Content-Type", f(r.name)), t.end(r.source)) : n();
|
|
28
24
|
});
|
|
29
25
|
},
|
|
30
26
|
generateBundle() {
|
|
@@ -38,33 +34,42 @@ function p() {
|
|
|
38
34
|
}
|
|
39
35
|
//#endregion
|
|
40
36
|
//#region src/vite/local-web-ui-link.ts
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
37
|
+
var m = [
|
|
38
|
+
"/@base-ui/",
|
|
39
|
+
"/@floating-ui/",
|
|
40
|
+
"/use-sync-external-store/"
|
|
41
|
+
];
|
|
42
|
+
function h(r) {
|
|
43
|
+
let a = s(i(r), "node_modules", "@imfusion", "web-ui");
|
|
44
|
+
if (!t(a) || i(a) === a) return;
|
|
45
|
+
let o = JSON.parse(n(s(e, "package.json"), "utf-8")), c = typeof o == "object" && o ? Reflect.get(o, "peerDependencies") : {};
|
|
46
|
+
if (typeof c != "object" || !c) throw Error(`${e}/package.json has no peerDependencies`);
|
|
47
|
+
return {
|
|
48
|
+
resolve: { dedupe: Object.keys(c) },
|
|
49
|
+
test: { server: { deps: { inline: m.map((e) => new RegExp(e)) } } }
|
|
50
|
+
};
|
|
46
51
|
}
|
|
47
|
-
function
|
|
52
|
+
function g() {
|
|
48
53
|
return {
|
|
49
54
|
name: "imf-ui:local-web-ui-link",
|
|
50
|
-
config: () =>
|
|
55
|
+
config: (e) => h(s(e.root ?? process.cwd()))
|
|
51
56
|
};
|
|
52
57
|
}
|
|
53
58
|
//#endregion
|
|
54
59
|
//#region src/vite/readable-css-module-names.ts
|
|
55
|
-
function
|
|
60
|
+
function _(e, t) {
|
|
56
61
|
let { lightningcss: n, modules: r, transformer: i } = e.css ?? {}, a = n?.cssModules;
|
|
57
62
|
if (typeof a != "boolean" && r !== !1 && !a?.pattern && !(typeof r == "object" && r.generateScopedName)) return i === "postcss" ? { css: { modules: { generateScopedName: t } } } : { css: {
|
|
58
63
|
transformer: "lightningcss",
|
|
59
64
|
lightningcss: { cssModules: { pattern: t } }
|
|
60
65
|
} };
|
|
61
66
|
}
|
|
62
|
-
function
|
|
67
|
+
function v({ prefix: e }) {
|
|
63
68
|
let t = `${e}-[name]-[local]`;
|
|
64
69
|
return {
|
|
65
70
|
name: "imf-ui:readable-css-module-names",
|
|
66
|
-
config: (e) =>
|
|
71
|
+
config: (e) => _(e, t)
|
|
67
72
|
};
|
|
68
73
|
}
|
|
69
74
|
//#endregion
|
|
70
|
-
export { p as imfusionBrandAssets,
|
|
75
|
+
export { p as imfusionBrandAssets, g as localWebUILink, v as readableCssModuleNames };
|
package/dist/web-ui-cli.js
CHANGED
|
@@ -278,19 +278,19 @@ function me(e) {
|
|
|
278
278
|
if (i.length > 0) {
|
|
279
279
|
for (let e of i) console.error(`No skills installed for ${e}. Run \`npx web-ui install skills --harness=${e}\` first.`);
|
|
280
280
|
process.exitCode = 1;
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
281
|
+
} else {
|
|
282
|
+
v.intro("@imfusion/web-ui install hooks");
|
|
283
|
+
try {
|
|
284
|
+
de(r);
|
|
285
|
+
} catch (e) {
|
|
286
|
+
if (e instanceof U) {
|
|
287
|
+
console.error(e.message), process.exitCode = 1;
|
|
288
|
+
return;
|
|
289
|
+
}
|
|
290
|
+
throw e;
|
|
290
291
|
}
|
|
291
|
-
|
|
292
|
+
v.outro("Done — agent hooks installed.");
|
|
292
293
|
}
|
|
293
|
-
v.outro("Done — agent hooks installed.");
|
|
294
294
|
}
|
|
295
295
|
var Q = new ee();
|
|
296
296
|
Q.name("web-ui").description("Command-line tools for @imfusion/web-ui").version(P);
|
|
@@ -120,4 +120,8 @@ component colors cannot disagree with them:
|
|
|
120
120
|
<WebUIProvider colorScheme="dark">{children}</WebUIProvider>
|
|
121
121
|
```
|
|
122
122
|
|
|
123
|
+
To let the user pick Light, System, or Dark, place a
|
|
124
|
+
[`ColorSchemeToggle`](?path=/docs/primitives-inputs-colorschemetoggle--docs). It stores the choice and works only while
|
|
125
|
+
the provider's `colorScheme` is unset.
|
|
126
|
+
|
|
123
127
|
<PageNav />
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@imfusion/web-ui",
|
|
3
|
-
"version": "0.10.1-dev.
|
|
3
|
+
"version": "0.10.1-dev.60.g7891a716",
|
|
4
4
|
"description": "The official Web UI component library for ImFusion web apps",
|
|
5
5
|
"author": "ImFusion GmbH",
|
|
6
6
|
"homepage": "https://imfusion.com",
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
},
|
|
12
12
|
"type": "module",
|
|
13
13
|
"engines": {
|
|
14
|
-
"node": ">=
|
|
14
|
+
"node": "^22.22.1 || ^24.11 || >=26"
|
|
15
15
|
},
|
|
16
16
|
"imports": {
|
|
17
17
|
"#/*": "./src/*",
|
|
@@ -95,7 +95,7 @@
|
|
|
95
95
|
"skills:eval:compare": "tsx src/llms/evals/runner/compare.ts",
|
|
96
96
|
"skills:eval:affected": "tsx src/llms/evals/runner/affected.ts",
|
|
97
97
|
"skills:eval:report": "tsx src/llms/evals/runner/report.ts",
|
|
98
|
-
"git:config": "git config core.hooksPath .
|
|
98
|
+
"git:config": "git config core.hooksPath .vite-hooks/_ && vp config --no-agent && git config pull.rebase true && git config merge.ff only"
|
|
99
99
|
},
|
|
100
100
|
"peerDependencies": {
|
|
101
101
|
"@imfusion/sdk": "*",
|
|
@@ -138,7 +138,7 @@
|
|
|
138
138
|
"@types/react": "19.2.14",
|
|
139
139
|
"@types/react-dom": "19.2.3",
|
|
140
140
|
"@vitejs/plugin-react": "6.0.1",
|
|
141
|
-
"@vitest/browser-playwright": "5.0.
|
|
141
|
+
"@vitest/browser-playwright": "5.0.4",
|
|
142
142
|
"concurrently": "9.2.1",
|
|
143
143
|
"culori": "4.0.2",
|
|
144
144
|
"fast-xml-parser": "5.11.2",
|
|
@@ -148,19 +148,21 @@
|
|
|
148
148
|
"mermaid": "12.0.0",
|
|
149
149
|
"playwright": "1.60.0",
|
|
150
150
|
"prettier": "3.8.3",
|
|
151
|
+
"react": "19.2.5",
|
|
151
152
|
"react-docgen-typescript": "2.4.0",
|
|
153
|
+
"react-dom": "19.2.5",
|
|
152
154
|
"remark-gfm": "4.0.1",
|
|
153
155
|
"storybook": "10.6.2",
|
|
154
156
|
"tsx": "4.21.0",
|
|
155
157
|
"typescript": "6.0.3",
|
|
156
|
-
"vite": "npm:@voidzero-dev/vite-plus-core@1.
|
|
158
|
+
"vite": "npm:@voidzero-dev/vite-plus-core@1.2.0",
|
|
157
159
|
"vite-plugin-dts": "5.0.0",
|
|
158
|
-
"vite-plus": "1.
|
|
159
|
-
"vitest": "5.0.
|
|
160
|
+
"vite-plus": "1.2.0",
|
|
161
|
+
"vitest": "5.0.4"
|
|
160
162
|
},
|
|
161
163
|
"overrides": {
|
|
162
|
-
"vite": "npm:@voidzero-dev/vite-plus-core@1.
|
|
163
|
-
"vitest": "5.0.
|
|
164
|
+
"vite": "npm:@voidzero-dev/vite-plus-core@1.2.0",
|
|
165
|
+
"vitest": "5.0.4",
|
|
164
166
|
"storybook": {
|
|
165
167
|
".": "$storybook",
|
|
166
168
|
"vite-plus": "$vite-plus"
|