@floegence/floe-webapp-core 0.52.0 → 0.52.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.
@@ -1,9 +1,9 @@
1
- import { setAttribute as f, insert as g, createComponent as l, Portal as W, use as O, spread as G, mergeProps as J, effect as F, className as p, template as P, memo as z, delegateEvents as te } from "solid-js/web";
1
+ import { setAttribute as f, insert as g, createComponent as l, Portal as W, use as I, spread as G, mergeProps as J, effect as F, className as O, template as P, memo as z, delegateEvents as te } from "solid-js/web";
2
2
  import { createSignal as _, createMemo as ne, createEffect as Q, onCleanup as re, Show as y, Index as V } from "solid-js";
3
3
  import { cn as M } from "../../utils/cn.js";
4
4
  import { deferNonBlocking as oe } from "../../utils/defer.js";
5
5
  import { ChevronDown as ae, Check as ie, ChevronRight as ue } from "../icons/index.js";
6
- import { focusMenuItem as I, MENU_ITEM_SELECTOR as le, moveMenuFocus as U, calculateMenuPosition as se, calculateSubmenuPosition as de } from "./menuUtils.js";
6
+ import { focusMenuItem as p, MENU_ITEM_SELECTOR as le, moveMenuFocus as U, calculateMenuPosition as se, calculateSubmenuPosition as de } from "./menuUtils.js";
7
7
  import { LOCAL_INTERACTION_SURFACE_ATTR as X } from "./localInteractionSurface.js";
8
8
  import { createFloatingPresence as Y } from "./floatingPresence.js";
9
9
  import { useOverlayMask as ce } from "../../hooks/useOverlayMask.js";
@@ -42,9 +42,9 @@ function $e(e) {
42
42
  x: -9999,
43
43
  y: -9999
44
44
  });
45
- let b, h;
46
- const v = `floe-dropdown-${Me += 1}`, $ = `${v}-menu`, w = ne(() => o.mounted() ? fe({
47
- owner: b
45
+ let v, h;
46
+ const b = `floe-dropdown-${Me += 1}`, $ = `${b}-menu`, w = ne(() => o.mounted() ? fe({
47
+ owner: v
48
48
  }) : {
49
49
  host: null,
50
50
  boundaryHost: null,
@@ -56,12 +56,12 @@ function $e(e) {
56
56
  boundaryRect: () => ge(w()),
57
57
  projectPosition: (r) => me(r, w())
58
58
  }, A = () => {
59
- d(!1), requestAnimationFrame(() => b?.focus());
59
+ d(!1), requestAnimationFrame(() => v?.focus());
60
60
  };
61
61
  ce({
62
62
  open: o.mounted,
63
63
  root: () => h,
64
- containsTarget: (r) => !!(r instanceof Element ? r : document.activeElement)?.closest(`[data-floe-dropdown="${v}"]`),
64
+ containsTarget: (r) => !!(r instanceof Element ? r : document.activeElement)?.closest(`[data-floe-dropdown="${b}"]`),
65
65
  onClose: A,
66
66
  onEscapeOutside: A,
67
67
  lockBodyScroll: !1,
@@ -73,8 +73,8 @@ function $e(e) {
73
73
  escapeKeyPhase: "bubble"
74
74
  });
75
75
  const C = () => {
76
- if (!b || !h) return;
77
- const r = b.getBoundingClientRect(), n = h.getBoundingClientRect(), i = se(r, n, e.align ?? "start", m.boundaryRect());
76
+ if (!v || !h) return;
77
+ const r = v.getBoundingClientRect(), n = h.getBoundingClientRect(), i = se(r, n, e.align ?? "start", m.boundaryRect());
78
78
  k(i);
79
79
  };
80
80
  Q(() => {
@@ -88,20 +88,22 @@ function $e(e) {
88
88
  if (!c()) return;
89
89
  const r = (n) => {
90
90
  const i = n.target;
91
- i && typeof i.closest == "function" && i.closest(`[data-floe-dropdown="${v}"]`) || d(!1);
91
+ i && typeof i.closest == "function" && i.closest(`[data-floe-dropdown="${b}"]`) || d(!1);
92
92
  };
93
93
  document.addEventListener("pointerdown", r, !0), requestAnimationFrame(() => {
94
- C(), I(h, e.value ? "selected" : "first");
94
+ C(), p(h, e.value ? "selected" : "first");
95
95
  }), re(() => {
96
96
  document.removeEventListener("pointerdown", r, !0);
97
97
  });
98
98
  });
99
99
  const j = (r) => {
100
100
  const n = e.onSelect;
101
- r.keepOpen || d(!1), oe(() => n(r.id));
101
+ r.keepOpen || (d(!1), v?.focus({
102
+ preventScroll: !0
103
+ })), oe(() => n(r.id));
102
104
  }, R = (r, n = "first") => {
103
105
  e.disabled || (d(r), requestAnimationFrame(() => {
104
- C(), I(h, n);
106
+ C(), p(h, n);
105
107
  }));
106
108
  }, T = (r) => {
107
109
  if (e.disabled) return;
@@ -126,13 +128,13 @@ function $e(e) {
126
128
  r.preventDefault(), U(i, t, -1);
127
129
  return;
128
130
  case "Home":
129
- r.preventDefault(), I(i, "first");
131
+ r.preventDefault(), p(i, "first");
130
132
  return;
131
133
  case "End":
132
- r.preventDefault(), I(i, "last");
134
+ r.preventDefault(), p(i, "last");
133
135
  return;
134
136
  case "Tab":
135
- r.preventDefault(), d(!1), b?.focus();
137
+ r.preventDefault(), d(!1), v?.focus();
136
138
  return;
137
139
  default:
138
140
  return;
@@ -140,7 +142,7 @@ function $e(e) {
140
142
  };
141
143
  return (() => {
142
144
  var r = he(), n = r.firstChild;
143
- f(r, "data-floe-dropdown", v), n.$$keydown = T, n.$$click = () => {
145
+ f(r, "data-floe-dropdown", b), n.$$keydown = T, n.$$click = () => {
144
146
  if (!e.disabled) {
145
147
  if (c()) {
146
148
  d(!1);
@@ -149,8 +151,8 @@ function $e(e) {
149
151
  R(!0, e.value ? "selected" : "first");
150
152
  }
151
153
  };
152
- var i = b;
153
- return typeof i == "function" ? O(i, n) : b = n, f(n, "aria-controls", $), g(n, () => e.trigger), g(r, l(y, {
154
+ var i = v;
155
+ return typeof i == "function" ? I(i, n) : v = n, f(n, "aria-controls", $), g(n, () => e.trigger), g(r, l(y, {
154
156
  get when() {
155
157
  return o.mounted();
156
158
  },
@@ -161,7 +163,7 @@ function $e(e) {
161
163
  },
162
164
  get children() {
163
165
  var t = H(), s = h;
164
- return typeof s == "function" ? O(s, t) : h = t, f(t, "data-floe-dropdown", v), G(t, J({
166
+ return typeof s == "function" ? I(s, t) : h = t, f(t, "data-floe-dropdown", b), G(t, J({
165
167
  get class() {
166
168
  return M(m.isSurfaceMode() ? "absolute z-20 min-w-36 py-0.5" : "fixed z-50 min-w-36 py-0.5", "bg-popover text-popover-foreground", "rounded border border-border shadow-md", "floe-floating-presence floe-floating-menu");
167
169
  },
@@ -205,7 +207,7 @@ function $e(e) {
205
207
  },
206
208
  onSelect: j,
207
209
  onCloseMenu: () => d(!1),
208
- dropdownId: v,
210
+ dropdownId: b,
209
211
  portalLayout: m
210
212
  });
211
213
  }
@@ -216,7 +218,7 @@ function $e(e) {
216
218
  }
217
219
  }), null), F((t) => {
218
220
  var s = M("relative inline-block", e.class), u = M("cursor-pointer", e.triggerClass, e.disabled && "pointer-events-none opacity-50"), x = e.disabled ? -1 : 0, a = c(), S = e.triggerAriaLabel, E = e.disabled ? "true" : void 0, D = e.triggerInputSurface ? "true" : void 0, L = e.triggerInputSurface ? "inset" : void 0;
219
- return s !== t.e && p(r, t.e = s), u !== t.t && p(n, t.t = u), x !== t.a && f(n, "tabindex", t.a = x), a !== t.o && f(n, "aria-expanded", t.o = a), S !== t.i && f(n, "aria-label", t.i = S), E !== t.n && f(n, "aria-disabled", t.n = E), D !== t.s && f(n, "data-floe-input-surface", t.s = D), L !== t.h && f(n, "data-floe-surface", t.h = L), t;
221
+ return s !== t.e && O(r, t.e = s), u !== t.t && O(n, t.t = u), x !== t.a && f(n, "tabindex", t.a = x), a !== t.o && f(n, "aria-expanded", t.o = a), S !== t.i && f(n, "aria-label", t.i = S), E !== t.n && f(n, "aria-disabled", t.n = E), D !== t.s && f(n, "data-floe-input-surface", t.s = D), L !== t.h && f(n, "data-floe-surface", t.h = L), t;
220
222
  }, {
221
223
  e: void 0,
222
224
  t: void 0,
@@ -233,11 +235,11 @@ function ee(e) {
233
235
  const [c, d] = _(!1), o = () => e.item.children && e.item.children.length > 0, k = Y({
234
236
  open: () => !!(c() && o()),
235
237
  exitDurationMs: 100
236
- }), [b, h] = _({
238
+ }), [v, h] = _({
237
239
  x: -9999,
238
240
  y: -9999
239
241
  });
240
- let v, $, w, m;
242
+ let b, $, w, m;
241
243
  const A = `floe-dropdown-item-${ke += 1}`;
242
244
  Q(() => {
243
245
  k.mounted() || h({
@@ -246,8 +248,8 @@ function ee(e) {
246
248
  });
247
249
  });
248
250
  const C = () => {
249
- if (!v || !w) return;
250
- const n = v.getBoundingClientRect(), i = w.getBoundingClientRect(), t = de(n, i, e.portalLayout.boundaryRect());
251
+ if (!b || !w) return;
252
+ const n = b.getBoundingClientRect(), i = w.getBoundingClientRect(), t = de(n, i, e.portalLayout.boundaryRect());
251
253
  h(t);
252
254
  }, j = () => {
253
255
  o() && (clearTimeout(m), m = setTimeout(() => {
@@ -267,7 +269,7 @@ function ee(e) {
267
269
  }
268
270
  }, q = (n = "first") => {
269
271
  o() && (d(!0), requestAnimationFrame(() => {
270
- C(), I(w, n);
272
+ C(), p(w, n);
271
273
  }));
272
274
  }, r = () => {
273
275
  d(!1), requestAnimationFrame(() => $?.focus());
@@ -275,8 +277,8 @@ function ee(e) {
275
277
  return (() => {
276
278
  var n = ye();
277
279
  n.addEventListener("mouseleave", R), n.addEventListener("mouseenter", j);
278
- var i = v;
279
- return typeof i == "function" ? O(i, n) : v = n, g(n, l(y, {
280
+ var i = b;
281
+ return typeof i == "function" ? I(i, n) : b = n, g(n, l(y, {
280
282
  get when() {
281
283
  return e.item.content;
282
284
  },
@@ -284,7 +286,7 @@ function ee(e) {
284
286
  var t = H();
285
287
  return t.$$click = T, g(t, e.item.content), F((s) => {
286
288
  var u = M("w-full px-2 py-1.5", e.item.tone === "danger" && "text-destructive", e.item.disabled && "opacity-50 pointer-events-none"), x = e.item.tone ?? "default";
287
- return u !== s.e && p(t, s.e = u), x !== s.t && f(t, "data-tone", s.t = x), s;
289
+ return u !== s.e && O(t, s.e = u), x !== s.t && f(t, "data-tone", s.t = x), s;
288
290
  }, {
289
291
  e: void 0,
290
292
  t: void 0
@@ -300,7 +302,7 @@ function ee(e) {
300
302
  e.item.disabled || o() && ((a.key === "ArrowRight" || a.key === "Enter" || a.key === " ") && (a.preventDefault(), q("first")), a.key === "ArrowLeft" && (a.preventDefault(), r()));
301
303
  }, t.$$click = T;
302
304
  var x = $;
303
- return typeof x == "function" ? O(x, t) : $ = t, f(t, "id", A), g(s, l(y, {
305
+ return typeof x == "function" ? I(x, t) : $ = t, f(t, "id", A), g(s, l(y, {
304
306
  get when() {
305
307
  return z(() => !!e.selected)() && !o();
306
308
  },
@@ -329,7 +331,7 @@ function ee(e) {
329
331
  }
330
332
  }), null), F((a) => {
331
333
  var S = M("w-full flex items-center gap-1.5 px-2 py-1 text-xs", "transition-colors duration-75", "focus:outline-none focus:bg-accent", e.item.tone === "danger" && "text-destructive", e.item.disabled ? "opacity-50 cursor-not-allowed" : "hover:bg-accent cursor-pointer"), E = e.item.disabled, D = o() ? "menu" : void 0, L = o() ? c() : void 0, K = e.selected && !o() ? "true" : void 0, N = e.item.tone ?? "default";
332
- return S !== a.e && p(t, a.e = S), E !== a.t && (t.disabled = a.t = E), D !== a.a && f(t, "aria-haspopup", a.a = D), L !== a.o && f(t, "aria-expanded", a.o = L), K !== a.i && f(t, "data-floe-selected", a.i = K), N !== a.n && f(t, "data-tone", a.n = N), a;
334
+ return S !== a.e && O(t, a.e = S), E !== a.t && (t.disabled = a.t = E), D !== a.a && f(t, "aria-haspopup", a.a = D), L !== a.o && f(t, "aria-expanded", a.o = L), K !== a.i && f(t, "data-floe-selected", a.i = K), N !== a.n && f(t, "data-tone", a.n = N), a;
333
335
  }, {
334
336
  e: void 0,
335
337
  t: void 0,
@@ -350,7 +352,7 @@ function ee(e) {
350
352
  },
351
353
  get children() {
352
354
  var t = H(), s = w;
353
- return typeof s == "function" ? O(s, t) : w = t, G(t, J({
355
+ return typeof s == "function" ? I(s, t) : w = t, G(t, J({
354
356
  get class() {
355
357
  return M(e.portalLayout.isSurfaceMode() ? "absolute z-20 min-w-36 py-0.5" : "fixed z-50 min-w-36 py-0.5", "bg-popover text-popover-foreground", "rounded border border-border shadow-md", "floe-floating-presence floe-floating-menu floe-floating-submenu");
356
358
  },
@@ -368,8 +370,8 @@ function ee(e) {
368
370
  }), {
369
371
  get style() {
370
372
  return {
371
- left: `${e.portalLayout.projectPosition(b()).x}px`,
372
- top: `${e.portalLayout.projectPosition(b()).y}px`
373
+ left: `${e.portalLayout.projectPosition(v()).x}px`,
374
+ top: `${e.portalLayout.projectPosition(v()).y}px`
373
375
  };
374
376
  },
375
377
  role: "menu",
@@ -434,7 +436,7 @@ function Fe(e) {
434
436
  get trigger() {
435
437
  return [(() => {
436
438
  var o = Se();
437
- return g(o, () => c()?.label ?? e.placeholder ?? "Select..."), F(() => p(o, M("truncate", !c() && "text-muted-foreground"))), o;
439
+ return g(o, () => c()?.label ?? e.placeholder ?? "Select..."), F(() => O(o, M("truncate", !c() && "text-muted-foreground"))), o;
438
440
  })(), l(ae, {
439
441
  class: "w-3.5 h-3.5 text-muted-foreground"
440
442
  })];
@@ -1,3 +1,4 @@
1
+ import { LIGHT_WINDOW_TOKENS as n, DARK_WINDOW_TOKENS as i } from "./windowTokens.js";
1
2
  function a(h) {
2
3
  const l = {}, c = (r, e = /* @__PURE__ */ new Set()) => {
3
4
  const o = h[r];
@@ -9,7 +10,8 @@ function a(h) {
9
10
  l[r] = c(r);
10
11
  return Object.freeze(l);
11
12
  }
12
- const n = {
13
+ const t = {
14
+ ...n,
13
15
  "--background": "hsl(34 24% 94%)",
14
16
  "--foreground": "hsl(214 26% 17%)",
15
17
  "--primary": "hsl(214 26% 17%)",
@@ -73,7 +75,8 @@ const n = {
73
75
  "--selection-code-bg": "hsl(212 100% 67%)",
74
76
  "--selection-code-fg": "hsl(220 20% 8%)",
75
77
  "--glow": "hsl(214 26% 17%)"
76
- }, i = {
78
+ }, d = {
79
+ ...i,
77
80
  "--background": "hsl(222 30% 8%)",
78
81
  "--foreground": "hsl(210 20% 98%)",
79
82
  "--primary": "hsl(210 20% 98%)",
@@ -137,8 +140,8 @@ const n = {
137
140
  "--selection-code-bg": "hsl(212 100% 67%)",
138
141
  "--selection-code-fg": "hsl(220 20% 8%)",
139
142
  "--glow": "hsl(217 65% 52%)"
140
- }, t = a(n), d = a(i);
143
+ }, b = a(t), u = a(d);
141
144
  export {
142
- d as CLASSIC_DARK_SEMANTIC_TOKENS,
143
- t as CLASSIC_LIGHT_SEMANTIC_TOKENS
145
+ u as CLASSIC_DARK_SEMANTIC_TOKENS,
146
+ b as CLASSIC_LIGHT_SEMANTIC_TOKENS
144
147
  };
@@ -6,7 +6,7 @@ export interface FloeShellThemeSelection {
6
6
  dark?: string;
7
7
  }
8
8
  export type FloeShellThemeDefaults = Partial<Record<FloeShellThemeMode, string>>;
9
- type ShellThemeTokenName = '--background' | '--foreground' | '--primary' | '--primary-foreground' | '--secondary' | '--secondary-foreground' | '--muted' | '--muted-foreground' | '--accent' | '--accent-foreground' | '--border' | '--input' | '--ring' | '--chrome-border' | '--top-bar-border' | '--activity-bar-border' | '--bottom-bar-border' | '--terminal-panel-border' | '--card' | '--card-foreground' | '--popover' | '--popover-foreground' | '--success' | '--success-foreground' | '--warning' | '--warning-foreground' | '--error' | '--error-foreground' | '--info' | '--info-foreground' | '--highlight-block-info-accent' | '--highlight-block-warning-accent' | '--highlight-block-success-accent' | '--highlight-block-error-accent' | '--highlight-block-note-accent' | '--highlight-block-tip-accent' | '--sidebar' | '--sidebar-foreground' | '--sidebar-primary' | '--sidebar-primary-foreground' | '--sidebar-accent' | '--sidebar-accent-foreground' | '--sidebar-border' | '--sidebar-ring' | '--activity-bar' | '--activity-bar-foreground' | '--activity-bar-foreground-active' | '--activity-bar-badge' | '--activity-bar-badge-foreground' | '--terminal-background' | '--terminal-foreground' | '--chart-1' | '--chart-2' | '--chart-3' | '--chart-4' | '--chart-5' | '--selection-bg' | '--selection-fg' | '--selection-on-primary-bg' | '--selection-on-primary-fg' | '--selection-code-bg' | '--selection-code-fg' | '--glow';
9
+ type ShellThemeTokenName = '--floe-window-background' | '--floe-window-foreground' | '--floe-window-muted-foreground' | '--floe-window-titlebar-background' | '--floe-window-border' | '--floe-window-shadow' | '--background' | '--foreground' | '--primary' | '--primary-foreground' | '--secondary' | '--secondary-foreground' | '--muted' | '--muted-foreground' | '--accent' | '--accent-foreground' | '--border' | '--input' | '--ring' | '--chrome-border' | '--top-bar-border' | '--activity-bar-border' | '--bottom-bar-border' | '--terminal-panel-border' | '--card' | '--card-foreground' | '--popover' | '--popover-foreground' | '--success' | '--success-foreground' | '--warning' | '--warning-foreground' | '--error' | '--error-foreground' | '--info' | '--info-foreground' | '--highlight-block-info-accent' | '--highlight-block-warning-accent' | '--highlight-block-success-accent' | '--highlight-block-error-accent' | '--highlight-block-note-accent' | '--highlight-block-tip-accent' | '--sidebar' | '--sidebar-foreground' | '--sidebar-primary' | '--sidebar-primary-foreground' | '--sidebar-accent' | '--sidebar-accent-foreground' | '--sidebar-border' | '--sidebar-ring' | '--activity-bar' | '--activity-bar-foreground' | '--activity-bar-foreground-active' | '--activity-bar-badge' | '--activity-bar-badge-foreground' | '--terminal-background' | '--terminal-foreground' | '--chart-1' | '--chart-2' | '--chart-3' | '--chart-4' | '--chart-5' | '--selection-bg' | '--selection-fg' | '--selection-on-primary-bg' | '--selection-on-primary-fg' | '--selection-code-bg' | '--selection-code-fg' | '--glow';
10
10
  export declare const REQUIRED_SHELL_THEME_TOKENS: readonly ShellThemeTokenName[];
11
11
  interface ShellThemePaletteDefinition {
12
12
  name: string;
@@ -1,5 +1,12 @@
1
- import { CLASSIC_LIGHT_SEMANTIC_TOKENS as s, CLASSIC_DARK_SEMANTIC_TOKENS as m } from "./classicSemanticTokens.js";
2
- const C = [
1
+ import { DARK_WINDOW_TOKENS as s, LIGHT_WINDOW_TOKENS as m } from "./windowTokens.js";
2
+ import { CLASSIC_LIGHT_SEMANTIC_TOKENS as l, CLASSIC_DARK_SEMANTIC_TOKENS as b } from "./classicSemanticTokens.js";
3
+ const w = [
4
+ "--floe-window-background",
5
+ "--floe-window-foreground",
6
+ "--floe-window-muted-foreground",
7
+ "--floe-window-titlebar-background",
8
+ "--floe-window-border",
9
+ "--floe-window-shadow",
3
10
  "--background",
4
11
  "--foreground",
5
12
  "--primary",
@@ -63,7 +70,7 @@ const C = [
63
70
  "--selection-code-bg",
64
71
  "--selection-code-fg",
65
72
  "--glow"
66
- ], l = {
73
+ ], p = {
67
74
  success: "#287A4B",
68
75
  successForeground: "#FFFFFF",
69
76
  warning: "#835800",
@@ -74,7 +81,7 @@ const C = [
74
81
  infoForeground: "#FFFFFF",
75
82
  note: "#6847A0",
76
83
  tip: "#1E6F73"
77
- }, b = {
84
+ }, B = {
78
85
  success: "#72D39C",
79
86
  successForeground: "#07160E",
80
87
  warning: "#F0C36A",
@@ -87,7 +94,7 @@ const C = [
87
94
  tip: "#71C8C0"
88
95
  };
89
96
  function o(r) {
90
- const e = r.mode === "light" ? l : b, n = r.mode === "light" ? { background: "#F4C95D", foreground: "#243447" } : {
97
+ const e = r.mode === "light" ? p : B, n = r.mode === "light" ? { background: "#F4C95D", foreground: "#243447" } : {
91
98
  background: r.background,
92
99
  foreground: r.foreground
93
100
  }, [t, d, F, c, g] = r.chart, a = r.syntax ?? {
@@ -99,6 +106,7 @@ function o(r) {
99
106
  function: g,
100
107
  constant: c
101
108
  }, u = {
109
+ ...r.mode === "dark" ? s : m,
102
110
  "--background": r.background,
103
111
  "--foreground": r.foreground,
104
112
  "--primary": r.primary,
@@ -241,7 +249,7 @@ function o(r) {
241
249
  tokens: r.mode === "light" ? { light: u } : { dark: u }
242
250
  };
243
251
  }
244
- const p = {
252
+ const E = {
245
253
  ...o({
246
254
  name: "classic-light",
247
255
  displayName: "Classic Light",
@@ -273,9 +281,9 @@ const p = {
273
281
  }
274
282
  }),
275
283
  inheritsBaseTokens: !0,
276
- semanticTokens: s,
284
+ semanticTokens: l,
277
285
  tokens: void 0
278
- }, B = {
286
+ }, k = {
279
287
  ...o({
280
288
  name: "classic-dark",
281
289
  displayName: "Classic Dark",
@@ -307,10 +315,10 @@ const p = {
307
315
  }
308
316
  }),
309
317
  inheritsBaseTokens: !0,
310
- semanticTokens: m,
318
+ semanticTokens: b,
311
319
  tokens: void 0
312
- }, E = [
313
- p,
320
+ }, A = [
321
+ E,
314
322
  o({
315
323
  name: "paper",
316
324
  displayName: "Paper",
@@ -566,7 +574,7 @@ const p = {
566
574
  constant: "#745500"
567
575
  }
568
576
  }),
569
- B,
577
+ k,
570
578
  o({
571
579
  name: "ink",
572
580
  displayName: "Ink",
@@ -882,18 +890,18 @@ const p = {
882
890
  constant: "#BF5AF2"
883
891
  }
884
892
  })
885
- ], D = {
893
+ ], v = {
886
894
  light: "classic-light",
887
895
  dark: "classic-dark"
888
896
  };
889
- function A(r, e) {
897
+ function y(r, e) {
890
898
  const n = r.mode ?? "both";
891
899
  return n === "both" || n === e;
892
900
  }
893
- function k(r, e) {
894
- return r.filter((n) => A(n, e));
901
+ function h(r, e) {
902
+ return r.filter((n) => y(n, e));
895
903
  }
896
- function y(r) {
904
+ function C(r) {
897
905
  const e = /* @__PURE__ */ new Set();
898
906
  for (const n of r) {
899
907
  if (e.has(n.name))
@@ -902,10 +910,10 @@ function y(r) {
902
910
  }
903
911
  }
904
912
  function i(r, e, n, t) {
905
- const d = k(r, e);
913
+ const d = h(r, e);
906
914
  return n && d.some((F) => F.name === n) ? n : t && d.some((F) => F.name === t) ? t : d[0]?.name;
907
915
  }
908
- function f(r, e, n = {}) {
916
+ function S(r, e, n = {}) {
909
917
  const t = typeof r == "object" && r !== null && !Array.isArray(r) ? r : void 0, d = t?.version === 1, F = d && typeof t.light == "string" ? t.light : void 0, c = d && typeof t.dark == "string" ? t.dark : void 0;
910
918
  return {
911
919
  version: 1,
@@ -913,15 +921,15 @@ function f(r, e, n = {}) {
913
921
  dark: i(e, "dark", c, n.dark)
914
922
  };
915
923
  }
916
- y(E);
924
+ C(A);
917
925
  export {
918
- D as BUILT_IN_SHELL_THEME_DEFAULTS,
919
- C as REQUIRED_SHELL_THEME_TOKENS,
920
- y as assertUniqueThemePresetNames,
921
- E as builtInShellThemePresets,
926
+ v as BUILT_IN_SHELL_THEME_DEFAULTS,
927
+ w as REQUIRED_SHELL_THEME_TOKENS,
928
+ C as assertUniqueThemePresetNames,
929
+ A as builtInShellThemePresets,
922
930
  o as createShellThemePreset,
923
- k as getShellThemePresetsForMode,
924
- f as normalizeShellThemeSelection,
925
- A as presetSupportsMode,
931
+ h as getShellThemePresetsForMode,
932
+ S as normalizeShellThemeSelection,
933
+ y as presetSupportsMode,
926
934
  i as resolveShellThemePresetName
927
935
  };
@@ -0,0 +1,17 @@
1
+ /** Palette-relative, opaque window material; resolved by CSS only when the theme changes. */
2
+ export declare const LIGHT_WINDOW_TOKENS: {
3
+ readonly '--floe-window-background': "color-mix(in srgb, var(--card) 35%, white)";
4
+ readonly '--floe-window-foreground': "var(--foreground)";
5
+ readonly '--floe-window-muted-foreground': "var(--muted-foreground)";
6
+ readonly '--floe-window-titlebar-background': "color-mix(in srgb, var(--floe-window-background) 92%, var(--foreground))";
7
+ readonly '--floe-window-border': "color-mix(in srgb, var(--floe-window-background) 88%, var(--foreground))";
8
+ readonly '--floe-window-shadow': "0 1px 3px rgb(0 0 0 / 14%), 0 12px 28px -8px rgb(0 0 0 / 18%)";
9
+ };
10
+ export declare const DARK_WINDOW_TOKENS: {
11
+ readonly '--floe-window-background': "color-mix(in srgb, var(--card) 90%, white)";
12
+ readonly '--floe-window-foreground': "var(--foreground)";
13
+ readonly '--floe-window-muted-foreground': "color-mix(in srgb, var(--muted-foreground) 72%, var(--foreground))";
14
+ readonly '--floe-window-titlebar-background': "color-mix(in srgb, var(--floe-window-background) 95%, white)";
15
+ readonly '--floe-window-border': "color-mix(in srgb, var(--floe-window-background) 88%, var(--foreground))";
16
+ readonly '--floe-window-shadow': "0 1px 3px rgb(0 0 0 / 30%), 0 12px 28px -8px rgb(0 0 0 / 32%)";
17
+ };
@@ -0,0 +1,19 @@
1
+ const o = {
2
+ "--floe-window-background": "color-mix(in srgb, var(--card) 35%, white)",
3
+ "--floe-window-foreground": "var(--foreground)",
4
+ "--floe-window-muted-foreground": "var(--muted-foreground)",
5
+ "--floe-window-titlebar-background": "color-mix(in srgb, var(--floe-window-background) 92%, var(--foreground))",
6
+ "--floe-window-border": "color-mix(in srgb, var(--floe-window-background) 88%, var(--foreground))",
7
+ "--floe-window-shadow": "0 1px 3px rgb(0 0 0 / 14%), 0 12px 28px -8px rgb(0 0 0 / 18%)"
8
+ }, r = {
9
+ "--floe-window-background": "color-mix(in srgb, var(--card) 90%, white)",
10
+ "--floe-window-foreground": "var(--foreground)",
11
+ "--floe-window-muted-foreground": "color-mix(in srgb, var(--muted-foreground) 72%, var(--foreground))",
12
+ "--floe-window-titlebar-background": "color-mix(in srgb, var(--floe-window-background) 95%, white)",
13
+ "--floe-window-border": "color-mix(in srgb, var(--floe-window-background) 88%, var(--foreground))",
14
+ "--floe-window-shadow": "0 1px 3px rgb(0 0 0 / 30%), 0 12px 28px -8px rgb(0 0 0 / 32%)"
15
+ };
16
+ export {
17
+ r as DARK_WINDOW_TOKENS,
18
+ o as LIGHT_WINDOW_TOKENS
19
+ };