@floegence/floe-webapp-core 0.50.6 → 0.52.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.
- package/dist/components/chat/input/ChatInput.js +8 -8
- package/dist/components/ui/Button.js +16 -13
- package/dist/components/ui/Card.js +125 -119
- package/dist/components/ui/Checkbox.js +178 -132
- package/dist/components/ui/CommandPalette.js +10 -10
- package/dist/components/ui/Dialog.d.ts +7 -0
- package/dist/components/ui/Dialog.js +160 -114
- package/dist/components/ui/DirectoryInput.js +5 -5
- package/dist/components/ui/Dropdown.d.ts +2 -0
- package/dist/components/ui/Dropdown.js +183 -160
- package/dist/components/ui/FloatingWindow.js +211 -199
- package/dist/components/ui/HighlightBlock.js +8 -8
- package/dist/components/ui/Input.js +40 -40
- package/dist/components/ui/Pagination.js +90 -88
- package/dist/components/ui/ProcessingIndicator.js +1 -1
- package/dist/components/ui/Progress.js +99 -88
- package/dist/components/ui/QuoteBlock.js +9 -9
- package/dist/components/ui/Radio.js +151 -127
- package/dist/components/ui/SegmentedControl.js +26 -25
- package/dist/components/ui/Stepper.js +114 -112
- package/dist/components/ui/Switch.js +34 -33
- package/dist/components/ui/Tabs.js +153 -150
- package/dist/components/ui/Tag.js +24 -21
- package/dist/components/ui/Tooltip.js +10 -10
- package/dist/components/ui/floatingPresence.js +40 -30
- package/dist/components/workbench/WorkbenchHud.js +9 -9
- package/dist/components/workbench/WorkbenchLockButton.js +4 -4
- package/dist/components/workbench/WorkbenchWidget.js +46 -43
- package/dist/context/FloeConfigContext.d.ts +5 -1
- package/dist/context/FloeConfigContext.js +10 -9
- package/dist/context/ThemeContext.d.ts +3 -1
- package/dist/context/ThemeContext.js +78 -71
- package/dist/floe.css +32 -0
- package/dist/full.js +839 -836
- package/dist/hooks/useOverlayMask.js +95 -83
- package/dist/index.js +150 -147
- package/dist/input-focus.css +0 -1
- package/dist/styles/themes/index.d.ts +3 -0
- package/dist/styles/themes/index.js +40 -31
- package/dist/styles/tokens.d.ts +36 -0
- package/dist/styles/tokens.js +12 -5
- package/dist/styles.css +1 -1
- package/dist/surface.css +467 -0
- package/dist/themes.d.ts +1 -1
- package/dist/ui.css +9 -0
- package/package.json +1 -1
|
@@ -1,11 +1,18 @@
|
|
|
1
|
-
|
|
1
|
+
function m(e) {
|
|
2
|
+
return e === "standard" || e === "soft-neumorphic";
|
|
3
|
+
}
|
|
4
|
+
function d(e, r) {
|
|
5
|
+
const t = i(r);
|
|
6
|
+
e ? t?.setAttribute?.("data-floe-surface-style", e) : t?.removeAttribute?.("data-floe-surface-style");
|
|
7
|
+
}
|
|
8
|
+
const h = [
|
|
2
9
|
{ name: "light", displayName: "Light", type: "light" },
|
|
3
10
|
{ name: "dark", displayName: "Dark", type: "dark" }
|
|
4
11
|
];
|
|
5
|
-
function
|
|
12
|
+
function y(e) {
|
|
6
13
|
return e === "light" || e === "dark" || e === "system";
|
|
7
14
|
}
|
|
8
|
-
function
|
|
15
|
+
function u() {
|
|
9
16
|
return typeof window > "u" ? "light" : window.matchMedia("(prefers-color-scheme: dark)").matches ? "dark" : "light";
|
|
10
17
|
}
|
|
11
18
|
function i(e) {
|
|
@@ -13,51 +20,53 @@ function i(e) {
|
|
|
13
20
|
if (!(typeof document > "u"))
|
|
14
21
|
return document.documentElement;
|
|
15
22
|
}
|
|
16
|
-
function c(e,
|
|
23
|
+
function c(e, r) {
|
|
17
24
|
return {
|
|
18
25
|
...e?.shared ?? {},
|
|
19
|
-
...
|
|
26
|
+
...r === "light" ? e?.light ?? {} : e?.dark ?? {}
|
|
20
27
|
};
|
|
21
28
|
}
|
|
22
|
-
function
|
|
29
|
+
function f(...e) {
|
|
23
30
|
return Object.assign({}, ...e.filter(Boolean));
|
|
24
31
|
}
|
|
25
|
-
function
|
|
26
|
-
return
|
|
27
|
-
...
|
|
32
|
+
function p(e, ...r) {
|
|
33
|
+
return f(
|
|
34
|
+
...r.map((t) => c(t, e))
|
|
28
35
|
);
|
|
29
36
|
}
|
|
30
|
-
function
|
|
31
|
-
const t = i(
|
|
37
|
+
function T(e, r) {
|
|
38
|
+
const t = i(r);
|
|
32
39
|
if (!t) return;
|
|
33
|
-
const o = e === "system" ?
|
|
40
|
+
const o = e === "system" ? u() : e;
|
|
34
41
|
t.classList.remove("light", "dark"), t.classList.add(o), t.style.colorScheme = o;
|
|
35
42
|
}
|
|
36
|
-
function
|
|
37
|
-
const t = i(
|
|
43
|
+
function g(e, r) {
|
|
44
|
+
const t = i(r);
|
|
38
45
|
t && (e ? t.setAttribute?.("data-floe-shell-theme", e) : t.removeAttribute?.("data-floe-shell-theme"));
|
|
39
46
|
}
|
|
40
|
-
function
|
|
47
|
+
function k(e, r = [], t) {
|
|
41
48
|
const o = i(t);
|
|
42
49
|
if (!o) return [];
|
|
43
|
-
const
|
|
44
|
-
const [, s] =
|
|
50
|
+
const a = Object.entries(e ?? {}).filter((n) => {
|
|
51
|
+
const [, s] = n;
|
|
45
52
|
return typeof s == "string" && s.length > 0;
|
|
46
|
-
}),
|
|
47
|
-
for (const
|
|
48
|
-
|
|
49
|
-
for (const [
|
|
50
|
-
o.style.setProperty(
|
|
51
|
-
return [...
|
|
53
|
+
}), l = new Set(a.map(([n]) => n));
|
|
54
|
+
for (const n of r)
|
|
55
|
+
l.has(n) || o.style.removeProperty(n);
|
|
56
|
+
for (const [n, s] of a)
|
|
57
|
+
o.style.setProperty(n, s);
|
|
58
|
+
return [...l];
|
|
52
59
|
}
|
|
53
60
|
export {
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
61
|
+
g as applyShellThemeAttribute,
|
|
62
|
+
d as applySurfaceStyleAttribute,
|
|
63
|
+
T as applyTheme,
|
|
64
|
+
h as builtInThemes,
|
|
65
|
+
u as getSystemTheme,
|
|
66
|
+
m as isFloeSurfaceStyle,
|
|
67
|
+
y as isThemeType,
|
|
68
|
+
f as mergeThemeTokenMaps,
|
|
60
69
|
c as resolveThemeTokenOverrides,
|
|
61
|
-
|
|
62
|
-
|
|
70
|
+
p as resolveThemeTokens,
|
|
71
|
+
k as syncThemeTokenOverrides
|
|
63
72
|
};
|
package/dist/styles/tokens.d.ts
CHANGED
|
@@ -637,6 +637,25 @@ export declare const floeThemeColorVariables: {
|
|
|
637
637
|
readonly dark: Record<`--${string}`, string>;
|
|
638
638
|
};
|
|
639
639
|
export declare function getFloeColorTokenValue(variable: FloeCssVariableName, theme: FloeResolvedTheme): string | undefined;
|
|
640
|
+
/** Optional shadow overrides. Defaults resolve at each role so local palettes
|
|
641
|
+
* participate without masking overrides supplied by the theme service. */
|
|
642
|
+
export declare const floeSurfaceTokens: readonly [{
|
|
643
|
+
readonly variable: "--floe-surface-shadow-raised";
|
|
644
|
+
readonly role: "raised";
|
|
645
|
+
readonly fallback: "0 2px 5px -2px var(--floe-surface-shade), inset 0 1px 1px var(--floe-surface-highlight)";
|
|
646
|
+
}, {
|
|
647
|
+
readonly variable: "--floe-surface-shadow-inset";
|
|
648
|
+
readonly role: "inset";
|
|
649
|
+
readonly fallback: "inset 0 1px 2px var(--floe-surface-shade), inset 0 -1px 1px var(--floe-surface-highlight)";
|
|
650
|
+
}, {
|
|
651
|
+
readonly variable: "--floe-surface-shadow-floating";
|
|
652
|
+
readonly role: "floating";
|
|
653
|
+
readonly fallback: "0 8px 20px -6px var(--floe-surface-shade), inset 0 1px 1px var(--floe-surface-highlight)";
|
|
654
|
+
}, {
|
|
655
|
+
readonly variable: "--floe-surface-shadow-interacting";
|
|
656
|
+
readonly role: "interacting";
|
|
657
|
+
readonly fallback: "0 1px 2px var(--floe-surface-shade)";
|
|
658
|
+
}];
|
|
640
659
|
export declare const floeDesignTokens: {
|
|
641
660
|
readonly colors: readonly [{
|
|
642
661
|
readonly name: "Base Colors";
|
|
@@ -1227,4 +1246,21 @@ export declare const floeDesignTokens: {
|
|
|
1227
1246
|
readonly '--font-sans': "'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif";
|
|
1228
1247
|
readonly '--font-mono': "'JetBrains Mono', 'Fira Code', 'SF Mono', Menlo, Monaco, Consolas, monospace";
|
|
1229
1248
|
};
|
|
1249
|
+
readonly surface: readonly [{
|
|
1250
|
+
readonly variable: "--floe-surface-shadow-raised";
|
|
1251
|
+
readonly role: "raised";
|
|
1252
|
+
readonly fallback: "0 2px 5px -2px var(--floe-surface-shade), inset 0 1px 1px var(--floe-surface-highlight)";
|
|
1253
|
+
}, {
|
|
1254
|
+
readonly variable: "--floe-surface-shadow-inset";
|
|
1255
|
+
readonly role: "inset";
|
|
1256
|
+
readonly fallback: "inset 0 1px 2px var(--floe-surface-shade), inset 0 -1px 1px var(--floe-surface-highlight)";
|
|
1257
|
+
}, {
|
|
1258
|
+
readonly variable: "--floe-surface-shadow-floating";
|
|
1259
|
+
readonly role: "floating";
|
|
1260
|
+
readonly fallback: "0 8px 20px -6px var(--floe-surface-shade), inset 0 1px 1px var(--floe-surface-highlight)";
|
|
1261
|
+
}, {
|
|
1262
|
+
readonly variable: "--floe-surface-shadow-interacting";
|
|
1263
|
+
readonly role: "interacting";
|
|
1264
|
+
readonly fallback: "0 1px 2px var(--floe-surface-shade)";
|
|
1265
|
+
}];
|
|
1230
1266
|
};
|
package/dist/styles/tokens.js
CHANGED
|
@@ -628,27 +628,34 @@ const u = {
|
|
|
628
628
|
light: o("light"),
|
|
629
629
|
dark: o("dark")
|
|
630
630
|
};
|
|
631
|
-
function
|
|
631
|
+
function g(a, e) {
|
|
632
632
|
return u[e][a];
|
|
633
633
|
}
|
|
634
|
-
const
|
|
634
|
+
const h = [
|
|
635
|
+
{ variable: "--floe-surface-shadow-raised", role: "raised", fallback: "0 2px 5px -2px var(--floe-surface-shade), inset 0 1px 1px var(--floe-surface-highlight)" },
|
|
636
|
+
{ variable: "--floe-surface-shadow-inset", role: "inset", fallback: "inset 0 1px 2px var(--floe-surface-shade), inset 0 -1px 1px var(--floe-surface-highlight)" },
|
|
637
|
+
{ variable: "--floe-surface-shadow-floating", role: "floating", fallback: "0 8px 20px -6px var(--floe-surface-shade), inset 0 1px 1px var(--floe-surface-highlight)" },
|
|
638
|
+
{ variable: "--floe-surface-shadow-interacting", role: "interacting", fallback: "0 1px 2px var(--floe-surface-shade)" }
|
|
639
|
+
], m = {
|
|
635
640
|
colors: l,
|
|
636
641
|
typography: i,
|
|
637
642
|
fonts: n,
|
|
638
643
|
spacing: s,
|
|
639
644
|
radius: t,
|
|
640
645
|
motion: c,
|
|
641
|
-
shared: r
|
|
646
|
+
shared: r,
|
|
647
|
+
surface: h
|
|
642
648
|
};
|
|
643
649
|
export {
|
|
644
650
|
l as floeColorTokenCategories,
|
|
645
|
-
|
|
651
|
+
m as floeDesignTokens,
|
|
646
652
|
n as floeFontFamilyTokens,
|
|
647
653
|
c as floeMotionTokens,
|
|
648
654
|
t as floeRadiusTokens,
|
|
649
655
|
r as floeSharedCssVariables,
|
|
650
656
|
s as floeSpacingTokens,
|
|
657
|
+
h as floeSurfaceTokens,
|
|
651
658
|
u as floeThemeColorVariables,
|
|
652
659
|
i as floeTypographyTokens,
|
|
653
|
-
|
|
660
|
+
g as getFloeColorTokenValue
|
|
654
661
|
};
|