@floegence/floe-webapp-core 0.101.10 → 0.101.12

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,6 +1,6 @@
1
1
  import { effect as V, className as q, style as U, template as $, use as k } from "solid-js/web";
2
2
  import { useContextMenuActions as B } from "../ui/ContextMenuActions.js";
3
- import { onMount as N, onCleanup as P, createEffect as M } from "solid-js";
3
+ import { onMount as N, onCleanup as P, createEffect as C } from "solid-js";
4
4
  import { useTheme as _ } from "../../context/ThemeContext.js";
5
5
  import { useResizeObserver as H } from "../../hooks/useResizeObserver.js";
6
6
  import { resolveCodeEditorLanguageSpec as K } from "./languages.js";
@@ -9,7 +9,7 @@ import { ensureMonacoEnvironment as X } from "./monacoEnvironment.js";
9
9
  import { loadMonacoEditorApi as Y } from "./monacoStandaloneRuntime.js";
10
10
  import { ensureFloeMonacoHover as j } from "./monacoHover.js";
11
11
  var J = /* @__PURE__ */ $("<div>");
12
- const A = {
12
+ const w = {
13
13
  readOnly: !0,
14
14
  automaticLayout: !1,
15
15
  minimap: {
@@ -22,69 +22,69 @@ const A = {
22
22
  fontFamily: "var(--font-mono)"
23
23
  };
24
24
  let Q = 0;
25
- function W(t, f, c) {
26
- return t.Uri.parse(`inmemory://model/${f}/${encodeURIComponent(c)}`);
25
+ function W(t, f, s) {
26
+ return t.Uri.parse(`inmemory://model/${f}/${encodeURIComponent(s)}`);
27
27
  }
28
- function R(t, f) {
28
+ function A(t, f) {
29
29
  if (!t || !f) return "";
30
- const c = t.getSelection();
31
- return !c || c.isEmpty() ? "" : f.getValueInRange(c);
30
+ const s = t.getSelection();
31
+ return !s || s.isEmpty() ? "" : f.getValueInRange(s);
32
32
  }
33
33
  function ue(t) {
34
- const f = _(), c = B();
34
+ const f = _(), s = B();
35
35
  let m;
36
- const F = ++Q;
37
- let s, o, i, h, S = null, E = 0;
38
- const O = H(() => m), p = () => {
36
+ const R = ++Q;
37
+ let d, o, i, h, x = null, M = 0;
38
+ const F = H(() => m), S = () => {
39
39
  const e = f.resolvedTheme(), a = f.shellPreset();
40
- s && G(s.editor, e, a);
40
+ d && G(d.editor, e, a);
41
41
  }, y = () => !o || !i ? null : {
42
42
  editor: o,
43
43
  model: i,
44
44
  getValue: () => o.getValue(),
45
- getSelectedText: () => R(o, i),
45
+ getSelectedText: () => A(o, i),
46
46
  focus: () => o.focus()
47
- }, L = () => {
47
+ }, p = () => {
48
48
  const e = y();
49
49
  if (!e) return;
50
50
  const a = e.model.uri.toString();
51
- a !== S && (S = a, t.onReady?.(e));
52
- }, b = () => {
51
+ a !== x && (x = a, t.onReady?.(e));
52
+ }, L = () => {
53
53
  const e = y();
54
54
  e && t.onSelectionChange?.(e.getSelectedText(), e);
55
- }, I = async () => {
56
- if (!o || !s) return;
57
- const e = ++E, a = K(t.language);
55
+ }, b = async () => {
56
+ if (!o || !d) return;
57
+ const e = ++M, a = K(t.language);
58
58
  let l = a.id;
59
59
  try {
60
60
  await a.load?.();
61
61
  } catch {
62
- if (e !== E) return;
62
+ if (e !== M) return;
63
63
  l = "plaintext";
64
64
  }
65
- if (!o || e !== E) return;
66
- const u = W(s, F, t.path);
65
+ if (!o || e !== M) return;
66
+ const u = W(d, R, t.path);
67
67
  if (i && i.uri.toString() === u.toString()) {
68
- i.getLanguageId() !== l && s.editor.setModelLanguage(i, l), i.getValue() !== t.value && i.setValue(t.value), L(), b();
68
+ i.getLanguageId() !== l && d.editor.setModelLanguage(i, l), i.getValue() !== t.value && i.setValue(t.value), p(), L();
69
69
  return;
70
70
  }
71
- const g = s.editor.createModel(t.value, l, u);
72
- i?.dispose(), i = g, o.setModel(i), L(), b();
71
+ const g = d.editor.createModel(t.value, l, u);
72
+ i?.dispose(), i = g, o.setModel(i), p(), L();
73
73
  };
74
74
  return N(() => {
75
- let e = !1, a, l, u, g = [], x = [];
75
+ let e = !1, a, l, u, g = [], E = [];
76
76
  (async () => {
77
- if (!m || (X(), j(), s = await Y(t.runtimeOptions), e || !m)) return;
78
- o = s.editor.create(m, {
77
+ if (!m || (X(), j(), d = await Y(t.runtimeOptions), e || !m)) return;
78
+ o = d.editor.create(m, {
79
79
  model: null,
80
- ...A,
80
+ ...w,
81
81
  ...t.options ?? {}
82
82
  });
83
- const r = m, T = r.getBoundingClientRect();
84
- g = (c?.resolve({
83
+ const r = m, I = r.getBoundingClientRect();
84
+ g = (s?.resolve({
85
85
  target: r,
86
- x: T.left,
87
- y: T.top,
86
+ x: I.left,
87
+ y: I.top,
88
88
  selection: ""
89
89
  }) ?? []).map((n) => o.addAction({
90
90
  id: n.id,
@@ -92,47 +92,48 @@ function ue(t) {
92
92
  contextMenuGroupId: "navigation",
93
93
  contextMenuOrder: 0,
94
94
  run: () => {
95
- const d = x.find((C) => C.id === n.id);
96
- d && !d.disabled && d.onSelect();
95
+ const c = E.find((D) => D.id === n.id);
96
+ c && !c.disabled && c.onSelect();
97
97
  }
98
98
  }));
99
99
  const v = (n) => {
100
100
  if (n instanceof KeyboardEvent && n.key !== "ContextMenu" && !(n.shiftKey && n.key === "F10") || n instanceof MouseEvent && n.type === "pointerdown" && n.button !== 2) return;
101
- const d = c?.claim(), C = r.getBoundingClientRect();
102
- x = d?.actions ?? c?.resolve({
101
+ s?.claim();
102
+ const c = r.getBoundingClientRect();
103
+ E = s?.resolve({
103
104
  target: r,
104
- x: n instanceof MouseEvent ? n.clientX : C.left + 8,
105
- y: n instanceof MouseEvent ? n.clientY : C.top + 24,
106
- selection: R(o, i)
105
+ x: n instanceof MouseEvent ? n.clientX : c.left + 8,
106
+ y: n instanceof MouseEvent ? n.clientY : c.top + 24,
107
+ selection: A(o, i)
107
108
  }) ?? [];
108
109
  };
109
110
  if (r.addEventListener("pointerdown", v, !0), r.addEventListener("contextmenu", v, !0), r.addEventListener("keydown", v, !0), u = () => {
110
- x = [], r.removeEventListener("pointerdown", v, !0), r.removeEventListener("contextmenu", v, !0), r.removeEventListener("keydown", v, !0);
111
- }, p(), await I(), e || !o) return;
112
- const z = t.onContentChange, w = t.onChange, D = t.onSelectionChange;
111
+ E = [], r.removeEventListener("pointerdown", v, !0), r.removeEventListener("contextmenu", v, !0), r.removeEventListener("keydown", v, !0);
112
+ }, S(), await b(), e || !o) return;
113
+ const O = t.onContentChange, T = t.onChange, z = t.onSelectionChange;
113
114
  a = o.onDidChangeModelContent((n) => {
114
- const d = y();
115
- d && (z?.(n, d), w && w(d.getValue()));
115
+ const c = y();
116
+ c && (O?.(n, c), T && T(c.getValue()));
116
117
  }), l = o.onDidChangeCursorSelection(() => {
117
118
  const n = y();
118
- n && D?.(n.getSelectedText(), n);
119
+ n && z?.(n.getSelectedText(), n);
119
120
  });
120
121
  })().catch((r) => {
121
122
  console.error("Failed to initialize Monaco editor runtime", r);
122
123
  }), P(() => {
123
- e = !0, a?.dispose(), l?.dispose(), u?.(), g.forEach((r) => r.dispose()), h && cancelAnimationFrame(h), o?.dispose(), i?.dispose(), s = void 0, o = void 0, i = void 0;
124
+ e = !0, a?.dispose(), l?.dispose(), u?.(), g.forEach((r) => r.dispose()), h && cancelAnimationFrame(h), o?.dispose(), i?.dispose(), d = void 0, o = void 0, i = void 0;
124
125
  });
125
- }), M(() => {
126
- p();
127
- }), M(() => {
126
+ }), C(() => {
127
+ S();
128
+ }), C(() => {
128
129
  o && o.updateOptions({
129
- ...A,
130
+ ...w,
130
131
  ...t.options ?? {}
131
132
  });
132
- }), M(() => {
133
- t.path, t.language, t.value, I();
134
- }), M(() => {
135
- const e = O();
133
+ }), C(() => {
134
+ t.path, t.language, t.value, b();
135
+ }), C(() => {
136
+ const e = F();
136
137
  !e || !o || (h && cancelAnimationFrame(h), h = requestAnimationFrame(() => {
137
138
  o?.layout({
138
139
  width: e.width,
@@ -71,6 +71,8 @@ export interface TabsProps extends Omit<JSX.HTMLAttributes<HTMLDivElement>, 'onC
71
71
  * Alias for onChange (consistent naming with Radix/shadcn patterns).
72
72
  */
73
73
  onActiveIdChange?: (id: string) => void;
74
+ /** Use immediate only when the host already owns a UI-first selection transaction. */
75
+ activationTiming?: 'after-paint' | 'immediate';
74
76
  /** Callback when tab is closed */
75
77
  onClose?: (id: string) => void;
76
78
  /** Enable pointer sorting and Alt+Shift+Left/Right. Receives the complete ordered IDs. */
@@ -1,14 +1,14 @@
1
- import { createComponent as g, spread as Ce, mergeProps as ke, insert as h, effect as x, className as S, setAttribute as f, setStyleProperty as J, memo as ge, use as me, template as I, delegateEvents as Fe } from "solid-js/web";
2
- import { splitProps as ye, Show as A, createSignal as N, untrack as Q, createEffect as W, onCleanup as we } from "solid-js";
1
+ import { createComponent as g, spread as Ce, mergeProps as ke, insert as h, effect as x, className as S, setAttribute as f, setStyleProperty as Q, memo as ge, use as me, template as I, delegateEvents as Fe } from "solid-js/web";
2
+ import { splitProps as ye, Show as A, createSignal as N, untrack as Z, createEffect as W, onCleanup as we } from "solid-js";
3
3
  import { cn as b } from "../../utils/cn.js";
4
- import { deferAfterPaint as T } from "../../utils/defer.js";
4
+ import { deferAfterPaint as M } from "../../utils/defer.js";
5
5
  import { KeyedFor as Oe } from "./KeyedFor.js";
6
6
  import { createUIFirstSelection as We } from "../../utils/uiFirstSelection.js";
7
7
  import { useViewActivation as qe } from "../../context/ViewActivationContext.js";
8
8
  import { X as je, Plus as Ge, ChevronRight as Ue } from "../icons/index.js";
9
9
  import { createTabReorder as Ve } from "./tabReorder.js";
10
- var Xe = /* @__PURE__ */ I('<svg xmlns=http://www.w3.org/2000/svg width=24 height=24 viewBox="0 0 24 24"fill=none stroke=currentColor stroke-width=2 stroke-linecap=round stroke-linejoin=round><path d="m15 18-6-6 6-6">'), Z = /* @__PURE__ */ I("<button type=button data-floe-interactive=icon>"), Ke = /* @__PURE__ */ I("<div>"), Ye = /* @__PURE__ */ I('<button type=button data-floe-interactive=icon aria-label="Add new tab">'), Je = /* @__PURE__ */ I("<div><div role=tablist data-floe-surface=inset data-floe-surface-part=tab-rail aria-orientation=horizontal>"), Qe = /* @__PURE__ */ I("<span class=flex-shrink-0>"), Ze = /* @__PURE__ */ I('<div role=tab data-floe-surface-part=tab data-floe-interactive=item style=user-select:none;-webkit-user-select:none><span class="min-w-0 truncate max-w-32">'), _e = /* @__PURE__ */ I("<div role=tabpanel>");
11
- const _ = {
10
+ var Xe = /* @__PURE__ */ I('<svg xmlns=http://www.w3.org/2000/svg width=24 height=24 viewBox="0 0 24 24"fill=none stroke=currentColor stroke-width=2 stroke-linecap=round stroke-linejoin=round><path d="m15 18-6-6 6-6">'), _ = /* @__PURE__ */ I("<button type=button data-floe-interactive=icon>"), Ke = /* @__PURE__ */ I("<div>"), Ye = /* @__PURE__ */ I('<button type=button data-floe-interactive=icon aria-label="Add new tab">'), Je = /* @__PURE__ */ I("<div><div role=tablist data-floe-surface=inset data-floe-surface-part=tab-rail aria-orientation=horizontal>"), Qe = /* @__PURE__ */ I("<span class=flex-shrink-0>"), Ze = /* @__PURE__ */ I('<div role=tab data-floe-surface-part=tab data-floe-interactive=item style=user-select:none;-webkit-user-select:none><span class="min-w-0 truncate max-w-32">'), _e = /* @__PURE__ */ I("<div role=tabpanel>");
11
+ const ee = {
12
12
  x: 0,
13
13
  width: 0,
14
14
  visible: !1
@@ -108,24 +108,24 @@ function at(i) {
108
108
  };
109
109
  }
110
110
  function bt(i) {
111
- const [t, m] = ye(i, ["items", "activeId", "defaultActiveId", "onChange", "onActiveIdChange", "onClose", "onAdd", "onReorder", "showAdd", "closable", "size", "features", "slotClassNames", "ariaLabel", "labels", "class"]), d = () => t.features?.indicator?.mode ?? "activeBorder", k = () => tt(t.features?.indicator?.thicknessPx), w = () => t.features?.indicator?.colorToken ?? "primary", y = () => t.features?.indicator?.animated ?? !0, z = () => t.features?.containerBorder ?? !0, R = () => t.features?.scrollButtons ?? "auto", E = () => t.features?.closeButton?.dangerHover ?? !0, D = () => t.features?.closeButton?.enabledByDefault ?? t.closable ?? !1, pe = () => t.features?.addButton?.enabled ?? t.showAdd ?? !1, ee = () => rt(k()), te = () => ot(w());
111
+ const [t, m] = ye(i, ["items", "activeId", "defaultActiveId", "onChange", "onActiveIdChange", "activationTiming", "onClose", "onAdd", "onReorder", "showAdd", "closable", "size", "features", "slotClassNames", "ariaLabel", "labels", "class"]), d = () => t.features?.indicator?.mode ?? "activeBorder", k = () => tt(t.features?.indicator?.thicknessPx), w = () => t.features?.indicator?.colorToken ?? "primary", y = () => t.features?.indicator?.animated ?? !0, z = () => t.features?.containerBorder ?? !0, R = () => t.features?.scrollButtons ?? "auto", E = () => t.features?.closeButton?.dangerHover ?? !0, D = () => t.features?.closeButton?.enabledByDefault ?? t.closable ?? !1, pe = () => t.features?.addButton?.enabled ?? t.showAdd ?? !1, te = () => rt(k()), re = () => ot(w());
112
112
  let u;
113
- const re = (() => {
113
+ const oe = (() => {
114
114
  try {
115
115
  return qe();
116
116
  } catch {
117
117
  return null;
118
118
  }
119
- })(), B = () => re ? re.active() : !0;
119
+ })(), B = () => oe ? oe.active() : !0;
120
120
  let q = !1;
121
- const [$, j] = N(_), p = /* @__PURE__ */ new Map(), H = Ve({
121
+ const [$, j] = N(ee), p = /* @__PURE__ */ new Map(), H = Ve({
122
122
  items: () => t.items,
123
123
  onReorder: () => t.onReorder,
124
124
  container: () => u,
125
125
  elements: p
126
126
  });
127
127
  let G = !1;
128
- const P = () => d() === "slider", oe = (n) => {
128
+ const P = () => d() === "slider", ne = (n) => {
129
129
  if (!u || !P()) return !1;
130
130
  const a = p.get(n);
131
131
  if (!a) return !1;
@@ -136,38 +136,38 @@ function bt(i) {
136
136
  return j(l), l.visible;
137
137
  }, xe = () => {
138
138
  if (!P()) {
139
- j(_);
139
+ j(ee);
140
140
  return;
141
141
  }
142
- oe(V()) || j(_);
142
+ ne(X()) || j(ee);
143
143
  }, F = () => {
144
- G || (G = !0, T(() => {
145
- G = !1, Q(() => {
144
+ G || (G = !0, M(() => {
145
+ G = !1, Z(() => {
146
146
  B() && xe();
147
147
  });
148
148
  }));
149
- }, ne = () => t.activeId !== void 0, Ie = () => t.onChange ?? t.onActiveIdChange, [Se, Ae] = N(Q(() => t.defaultActiveId ?? t.items[0]?.id ?? "")), U = () => ne() ? t.activeId : Se(), ae = We({
149
+ }, ae = () => t.activeId !== void 0, Ie = () => t.onChange ?? t.onActiveIdChange, [Se, Ae] = N(Z(() => t.defaultActiveId ?? t.items[0]?.id ?? "")), U = () => ae() ? t.activeId : Se(), V = We({
150
150
  committed: U,
151
151
  commit: (n) => {
152
- ne() || Ae(n), Ie()?.(n);
152
+ ae() || Ae(n), Ie()?.(n);
153
153
  }
154
- }), V = ae.visual;
154
+ }), X = V.visual;
155
155
  W(() => {
156
- B() && (d(), V(), F());
156
+ B() && (d(), X(), F());
157
157
  });
158
- const [X, Be] = N(!1), [K, Re] = N(!1), [Le, Me] = N(!1), se = () => R() === "auto" && Le(), Ne = () => {
158
+ const [K, Be] = N(!1), [Y, Re] = N(!1), [Le, Te] = N(!1), se = () => R() === "auto" && Le(), Ne = () => {
159
159
  if (!u) return;
160
160
  const {
161
161
  scrollLeft: n,
162
162
  scrollWidth: a,
163
163
  clientWidth: l
164
164
  } = u, e = a > l;
165
- Me(e), Be(n > 0), Re(n + l < a - 1);
165
+ Te(e), Be(n > 0), Re(n + l < a - 1);
166
166
  }, O = () => {
167
- q || (q = !0, T(() => {
167
+ q || (q = !0, M(() => {
168
168
  q = !1, B() && Ne();
169
169
  }));
170
- }, Te = () => {
170
+ }, Me = () => {
171
171
  u && u.scrollBy({
172
172
  left: -150,
173
173
  behavior: "smooth"
@@ -192,7 +192,7 @@ function bt(i) {
192
192
  });
193
193
  }), W(() => {
194
194
  const n = U();
195
- T(() => {
195
+ M(() => {
196
196
  B() && p.get(n)?.scrollIntoView?.({
197
197
  block: "nearest",
198
198
  inline: "nearest"
@@ -201,12 +201,12 @@ function bt(i) {
201
201
  }), W(() => {
202
202
  B() && (t.items.length, O(), F());
203
203
  });
204
- const Y = (n, a) => {
205
- a || (ae.request(n), P() && oe(n));
204
+ const J = (n, a) => {
205
+ a || (t.activationTiming === "immediate" ? V.commitNow(n) : V.request(n), P() && ne(n));
206
206
  }, Ee = (n) => {
207
207
  const a = t.items.find((e) => e.id === n);
208
208
  if (!a) return;
209
- Y(a.id, a.disabled);
209
+ J(a.id, a.disabled);
210
210
  const l = p.get(a.id);
211
211
  l?.focus({
212
212
  preventScroll: !0
@@ -228,14 +228,14 @@ function bt(i) {
228
228
  }, $e = (n, a) => {
229
229
  if (n.stopPropagation(), !t.onClose) return;
230
230
  const e = a;
231
- T(() => Q(() => le(e)));
231
+ M(() => Z(() => le(e)));
232
232
  }, He = {
233
233
  sm: "h-[var(--floe-control-height-sm)] px-[var(--floe-control-padding-sm)]",
234
234
  md: "h-[var(--floe-control-height-md)] px-[var(--floe-control-padding-md)]"
235
235
  }, Pe = (n, a) => {
236
236
  const l = b("relative inline-flex items-center gap-1.5 whitespace-nowrap select-none", "text-[length:var(--floe-type-control)] leading-[var(--floe-line-control)]"), e = a ? "cursor-not-allowed opacity-50" : "cursor-pointer", o = () => {
237
237
  const c = d();
238
- return c === "none" || c === "slider" && $().visible ? "" : b("after:pointer-events-none after:absolute after:bottom-0 after:inset-x-2 after:rounded-full after:content-['']", ee().tabMarkerClass, te().tabMarkerClass);
238
+ return c === "none" || c === "slider" && $().visible ? "" : b("after:pointer-events-none after:absolute after:bottom-0 after:inset-x-2 after:rounded-full after:content-['']", te().tabMarkerClass, re().tabMarkerClass);
239
239
  };
240
240
  return b(
241
241
  l,
@@ -273,11 +273,11 @@ function bt(i) {
273
273
  return se();
274
274
  },
275
275
  get children() {
276
- var e = Z();
277
- return e.$$click = Te, h(e, g(nt, {
276
+ var e = _();
277
+ return e.$$click = Me, h(e, g(nt, {
278
278
  class: "w-4 h-4"
279
279
  })), x((o) => {
280
- var c = !X(), s = b("flex-shrink-0 flex items-center justify-center", "w-6 rounded-control cursor-pointer bg-[var(--floe-well)] border border-[var(--floe-line)]", "transition-opacity duration-[var(--floe-duration-fast)] ease-[var(--floe-ease-out)]", X() ? "text-[var(--floe-ink-quiet)] hover:bg-[var(--floe-state-hover)] opacity-100" : "opacity-0 pointer-events-none", t.slotClassNames?.scrollButton), v = t.labels?.scrollLeft ?? "Scroll left";
280
+ var c = !K(), s = b("flex-shrink-0 flex items-center justify-center", "w-6 rounded-control cursor-pointer bg-[var(--floe-well)] border border-[var(--floe-line)]", "transition-opacity duration-[var(--floe-duration-fast)] ease-[var(--floe-ease-out)]", K() ? "text-[var(--floe-ink-quiet)] hover:bg-[var(--floe-state-hover)] opacity-100" : "opacity-0 pointer-events-none", t.slotClassNames?.scrollButton), v = t.labels?.scrollLeft ?? "Scroll left";
281
281
  return c !== o.e && (e.disabled = o.e = c), s !== o.t && S(e, o.t = s), v !== o.a && f(e, "aria-label", o.a = v), o;
282
282
  }, {
283
283
  e: void 0,
@@ -294,8 +294,8 @@ function bt(i) {
294
294
  get children() {
295
295
  var e = Ke();
296
296
  return x((o) => {
297
- var c = b("pointer-events-none absolute bottom-0 left-0 z-10", ee().sliderHeightClass, te().sliderBgClass, y() ? "transition-[transform,width] duration-[var(--floe-duration-base)] ease-out motion-reduce:transition-none" : "transition-none", "will-change-transform", t.slotClassNames?.indicator), s = `translate3d(${$().x}px, 0, 0)`, v = `${$().width}px`;
298
- return c !== o.e && S(e, o.e = c), s !== o.t && J(e, "transform", o.t = s), v !== o.a && J(e, "width", o.a = v), o;
297
+ var c = b("pointer-events-none absolute bottom-0 left-0 z-10", te().sliderHeightClass, re().sliderBgClass, y() ? "transition-[transform,width] duration-[var(--floe-duration-base)] ease-out motion-reduce:transition-none" : "transition-none", "will-change-transform", t.slotClassNames?.indicator), s = `translate3d(${$().x}px, 0, 0)`, v = `${$().width}px`;
298
+ return c !== o.e && S(e, o.e = c), s !== o.t && Q(e, "transform", o.t = s), v !== o.a && Q(e, "width", o.a = v), o;
299
299
  }, {
300
300
  e: void 0,
301
301
  t: void 0,
@@ -308,7 +308,7 @@ function bt(i) {
308
308
  },
309
309
  by: (e) => e.id,
310
310
  children: (e) => {
311
- const o = () => e().id === V(), c = () => e().closable ?? D();
311
+ const o = () => e().id === X(), c = () => e().closable ?? D();
312
312
  return (() => {
313
313
  var s = Ze(), v = s.firstChild;
314
314
  return s.$$keydown = (r) => {
@@ -318,7 +318,7 @@ function bt(i) {
318
318
  return;
319
319
  }
320
320
  if (r.key === "Enter" || r.key === " ") {
321
- r.preventDefault(), Y(e().id, e().disabled);
321
+ r.preventDefault(), J(e().id, e().disabled);
322
322
  return;
323
323
  }
324
324
  De(r, e());
@@ -328,7 +328,7 @@ function bt(i) {
328
328
  r.preventDefault(), r.stopPropagation();
329
329
  return;
330
330
  }
331
- Y(e().id, e().disabled);
331
+ J(e().id, e().disabled);
332
332
  }, me((r) => {
333
333
  p.set(e().id, r), we(() => p.delete(e().id));
334
334
  }, s), h(s, g(A, {
@@ -344,20 +344,20 @@ function bt(i) {
344
344
  return ge(() => !!c())() && !e().disabled;
345
345
  },
346
346
  get children() {
347
- var r = Z();
347
+ var r = _();
348
348
  return r.$$click = (C) => $e(C, e().id), h(r, g(je, {
349
349
  class: "w-3 h-3"
350
350
  })), x((C) => {
351
- var L = b("flex-shrink-0 flex items-center justify-center", "w-5 h-5 rounded-control cursor-pointer", "bg-transparent text-[var(--floe-ink-quiet)]", E() ? "hover:bg-error hover:text-error-foreground" : "hover:bg-[var(--floe-state-hover)]", "ml-1.5", t.slotClassNames?.closeButton), M = e().closeLabel ?? `Close ${e().label}`;
352
- return L !== C.e && S(r, C.e = L), M !== C.t && f(r, "aria-label", C.t = M), C;
351
+ var L = b("flex-shrink-0 flex items-center justify-center", "w-5 h-5 rounded-control cursor-pointer", "bg-transparent text-[var(--floe-ink-quiet)]", E() ? "hover:bg-error hover:text-error-foreground" : "hover:bg-[var(--floe-state-hover)]", "ml-1.5", t.slotClassNames?.closeButton), T = e().closeLabel ?? `Close ${e().label}`;
352
+ return L !== C.e && S(r, C.e = L), T !== C.t && f(r, "aria-label", C.t = T), C;
353
353
  }, {
354
354
  e: void 0,
355
355
  t: void 0
356
356
  }), r;
357
357
  }
358
358
  }), null), x((r) => {
359
- var C = Pe(o(), e().disabled), L = e().id, M = H.dragging() === e().id ? "true" : void 0, ie = t.onReorder ? "none" : "pan-x", ce = e().domId, de = e().panelId, fe = e().title, ue = o() ? "raised" : "flat", ve = o(), he = e().disabled, be = e().disabled ? -1 : o() ? 0 : -1;
360
- return C !== r.e && S(s, r.e = C), L !== r.t && f(s, "data-floe-tab-id", r.t = L), M !== r.a && f(s, "data-floe-tab-dragging", r.a = M), ie !== r.o && J(s, "touch-action", r.o = ie), ce !== r.i && f(s, "id", r.i = ce), de !== r.n && f(s, "aria-controls", r.n = de), fe !== r.s && f(s, "title", r.s = fe), ue !== r.h && f(s, "data-floe-surface", r.h = ue), ve !== r.r && f(s, "aria-selected", r.r = ve), he !== r.d && f(s, "aria-disabled", r.d = he), be !== r.l && f(s, "tabindex", r.l = be), r;
359
+ var C = Pe(o(), e().disabled), L = e().id, T = H.dragging() === e().id ? "true" : void 0, ie = t.onReorder ? "none" : "pan-x", ce = e().domId, de = e().panelId, fe = e().title, ue = o() ? "raised" : "flat", ve = o(), he = e().disabled, be = e().disabled ? -1 : o() ? 0 : -1;
360
+ return C !== r.e && S(s, r.e = C), L !== r.t && f(s, "data-floe-tab-id", r.t = L), T !== r.a && f(s, "data-floe-tab-dragging", r.a = T), ie !== r.o && Q(s, "touch-action", r.o = ie), ce !== r.i && f(s, "id", r.i = ce), de !== r.n && f(s, "aria-controls", r.n = de), fe !== r.s && f(s, "title", r.s = fe), ue !== r.h && f(s, "data-floe-surface", r.h = ue), ve !== r.r && f(s, "aria-selected", r.r = ve), he !== r.d && f(s, "aria-disabled", r.d = he), be !== r.l && f(s, "tabindex", r.l = be), r;
361
361
  }, {
362
362
  e: void 0,
363
363
  t: void 0,
@@ -381,7 +381,7 @@ function bt(i) {
381
381
  var e = Ye();
382
382
  return e.$$click = () => {
383
383
  const o = t.onAdd;
384
- o && T(() => o());
384
+ o && M(() => o());
385
385
  }, h(e, g(Ge, {
386
386
  get class() {
387
387
  return t.size === "sm" ? "w-3.5 h-3.5" : "w-4 h-4";
@@ -393,11 +393,11 @@ function bt(i) {
393
393
  return se();
394
394
  },
395
395
  get children() {
396
- var e = Z();
396
+ var e = _();
397
397
  return e.$$click = ze, h(e, g(Ue, {
398
398
  class: "w-4 h-4"
399
399
  })), x((o) => {
400
- var c = !K(), s = b("flex-shrink-0 flex items-center justify-center", "w-6 rounded-control cursor-pointer bg-[var(--floe-well)] border border-[var(--floe-line)]", "transition-opacity duration-[var(--floe-duration-fast)] ease-[var(--floe-ease-out)]", K() ? "text-[var(--floe-ink-quiet)] hover:bg-[var(--floe-state-hover)] opacity-100" : "opacity-0 pointer-events-none", t.slotClassNames?.scrollButton), v = t.labels?.scrollRight ?? "Scroll right";
400
+ var c = !Y(), s = b("flex-shrink-0 flex items-center justify-center", "w-6 rounded-control cursor-pointer bg-[var(--floe-well)] border border-[var(--floe-line)]", "transition-opacity duration-[var(--floe-duration-fast)] ease-[var(--floe-ease-out)]", Y() ? "text-[var(--floe-ink-quiet)] hover:bg-[var(--floe-state-hover)] opacity-100" : "opacity-0 pointer-events-none", t.slotClassNames?.scrollButton), v = t.labels?.scrollRight ?? "Scroll right";
401
401
  return c !== o.e && (e.disabled = o.e = c), s !== o.t && S(e, o.t = s), v !== o.a && f(e, "aria-label", o.a = v), o;
402
402
  }, {
403
403
  e: void 0,
@@ -412,7 +412,7 @@ function bt(i) {
412
412
  // Hide scrollbar for all browsers
413
413
  "[&::-webkit-scrollbar]:hidden [-ms-overflow-style:none] [scrollbar-width:none]",
414
414
  t.slotClassNames?.scrollContainer
415
- ), c = X() ? "" : void 0, s = K() ? "" : void 0, v = t.ariaLabel;
415
+ ), c = K() ? "" : void 0, s = Y() ? "" : void 0, v = t.ariaLabel;
416
416
  return o !== e.e && S(a, e.e = o), c !== e.t && f(a, "data-floe-overflow-start", e.t = c), s !== e.a && f(a, "data-floe-overflow-end", e.a = s), v !== e.o && f(a, "aria-label", e.o = v), e;
417
417
  }, {
418
418
  e: void 0,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@floegence/floe-webapp-core",
3
- "version": "0.101.10",
3
+ "version": "0.101.12",
4
4
  "license": "MIT",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",