@floegence/floe-webapp-core 0.52.12 → 0.52.13

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,18 +1,18 @@
1
- import { createComponent as l, Portal as Ve, spread as pe, mergeProps as $e, memo as J, insert as c, effect as f, setAttribute as Ge, addEventListener as y, className as w, template as s, use as _e, delegateEvents as Je } from "solid-js/web";
2
- import { createSignal as g, createUniqueId as Ze, onCleanup as C, onMount as Ke, createEffect as P, Show as x, batch as Ie, untrack as Qe } from "solid-js";
3
- import { cn as D } from "../../utils/cn.js";
1
+ import { createComponent as l, Portal as Ve, spread as pe, mergeProps as $e, memo as J, insert as u, effect as f, setAttribute as Ge, addEventListener as b, className as w, template as s, use as _e, delegateEvents as Je } from "solid-js/web";
2
+ import { createSignal as g, createUniqueId as Ze, onCleanup as C, onMount as Ke, createEffect as R, Show as z, batch as Se, untrack as Qe } from "solid-js";
3
+ import { cn as B } from "../../utils/cn.js";
4
4
  import { useLayout as et } from "../../context/LayoutContext.js";
5
- import { Button as Se } from "./Button.js";
5
+ import { Button as Ie } from "./Button.js";
6
6
  import { Restore as tt, Maximize as nt, X as it } from "../icons/index.js";
7
7
  import { startHotInteraction as ot } from "../../utils/hotInteraction.js";
8
8
  import { startPointerSession as rt } from "./pointerSession.js";
9
9
  import { resolveFloatingWindowViewport as Z, normalizeFloatingWindowRect as lt, resolveFloatingWindowRect as at } from "./floatingWindowGeometry.js";
10
10
  import { createFloatingPresence as st } from "./floatingPresence.js";
11
11
  import { LOCAL_INTERACTION_SURFACE_ATTR as Pe } from "./localInteractionSurface.js";
12
- import { readSurfaceSafeArea as dt, resolveFloatingBoundary as ut } from "./surfaceFloatingBoundary.js";
13
- import { SURFACE_PORTAL_LAYER_ATTR as ct, resolveSurfacePortalHost as ft, SURFACE_FLOATING_LAYER_ATTR as ht } from "./dialogSurfaceScope.js";
14
- var wt = /* @__PURE__ */ s("<span hidden>"), gt = /* @__PURE__ */ s('<h2 class="text-xs leading-none font-medium truncate select-none">'), mt = /* @__PURE__ */ s('<div data-floe-floating-window-header-actions=true class="flex shrink-0 cursor-default items-center gap-1"><span aria-hidden=true class="mx-2 h-4 w-px shrink-0 bg-border">'), vt = /* @__PURE__ */ s('<div data-floe-floating-window-footer=true class="flex items-center justify-end gap-2 p-3 border-t border-border">'), yt = /* @__PURE__ */ s("<div data-floe-floating-window-resize-handle=n style=touch-action:none>"), xt = /* @__PURE__ */ s("<div data-floe-floating-window-resize-handle=s style=touch-action:none>"), bt = /* @__PURE__ */ s("<div data-floe-floating-window-resize-handle=e style=touch-action:none>"), zt = /* @__PURE__ */ s("<div data-floe-floating-window-resize-handle=w style=touch-action:none>"), pt = /* @__PURE__ */ s("<div data-floe-floating-window-resize-handle=ne style=touch-action:none>"), $t = /* @__PURE__ */ s("<div data-floe-floating-window-resize-handle=nw style=touch-action:none>"), _t = /* @__PURE__ */ s("<div data-floe-floating-window-resize-handle=se style=touch-action:none>"), It = /* @__PURE__ */ s("<div data-floe-floating-window-resize-handle=sw style=touch-action:none>"), St = /* @__PURE__ */ s('<div data-floe-geometry-surface=floating-window><div data-floe-dialog-surface-host=true><div data-floe-floating-window-titlebar=true style=touch-action:none><div class="flex-1 min-w-0 px-2"></div><div class="flex h-full shrink-0 items-stretch"></div></div><div data-floe-floating-window-content=true class="flex-1 overflow-auto p-3">');
15
- function Ot(n) {
12
+ import { readSurfaceSafeArea as dt, resolveFloatingBoundary as ct } from "./surfaceFloatingBoundary.js";
13
+ import { SURFACE_PORTAL_LAYER_ATTR as ut, resolveSurfacePortalHost as ft, SURFACE_FLOATING_LAYER_ATTR as ht } from "./dialogSurfaceScope.js";
14
+ var wt = /* @__PURE__ */ s("<span hidden>"), gt = /* @__PURE__ */ s('<h2 class="text-xs leading-none font-medium truncate select-none">'), mt = /* @__PURE__ */ s('<div data-floe-floating-window-header-actions=true class="flex shrink-0 cursor-default items-center gap-1"><span aria-hidden=true class="mx-2 h-4 w-px shrink-0 bg-border">'), vt = /* @__PURE__ */ s('<div data-floe-floating-window-footer=true class="flex items-center justify-end gap-2 p-3 border-t border-border">'), yt = /* @__PURE__ */ s("<div data-floe-floating-window-resize-handle=n style=touch-action:none>"), xt = /* @__PURE__ */ s("<div data-floe-floating-window-resize-handle=s style=touch-action:none>"), bt = /* @__PURE__ */ s("<div data-floe-floating-window-resize-handle=e style=touch-action:none>"), zt = /* @__PURE__ */ s("<div data-floe-floating-window-resize-handle=w style=touch-action:none>"), pt = /* @__PURE__ */ s("<div data-floe-floating-window-resize-handle=ne style=touch-action:none>"), $t = /* @__PURE__ */ s("<div data-floe-floating-window-resize-handle=nw style=touch-action:none>"), _t = /* @__PURE__ */ s("<div data-floe-floating-window-resize-handle=se style=touch-action:none>"), St = /* @__PURE__ */ s("<div data-floe-floating-window-resize-handle=sw style=touch-action:none>"), It = /* @__PURE__ */ s('<div data-floe-geometry-surface=floating-window><div data-floe-dialog-surface-host=true><div data-floe-floating-window-titlebar=true style=touch-action:none><div class="flex-1 min-w-0 px-2"></div><div class="flex h-full shrink-0 items-stretch"></div></div><div data-floe-floating-window-content=true class="flex-1 overflow-auto p-3">');
15
+ function Dt(n) {
16
16
  const K = () => n.resizable ?? !0, Q = () => n.draggable ?? !0, ee = () => n.minSize ?? {
17
17
  width: 200,
18
18
  height: 150
@@ -20,8 +20,8 @@ function Ot(n) {
20
20
  width: 1 / 0,
21
21
  height: 1 / 0
22
22
  };
23
- let O;
24
- const Re = dt(), [F, ne] = g({}), [Ae, ie] = g(1 / 0), [H, oe] = g(!0), h = () => !!(n.compactBelow && Ae() < n.compactBelow), $ = () => ({
23
+ let D;
24
+ const Re = dt(), [F, ne] = g({}), [Ae, ie] = g(1 / 0), [H, oe] = g(!0), h = () => !!(n.compactBelow && Ae() < n.compactBelow), _ = () => ({
25
25
  top: (F().top ?? 0) + (n.viewportInsets?.top ?? 0),
26
26
  right: (F().right ?? 0) + (n.viewportInsets?.right ?? 0),
27
27
  bottom: (F().bottom ?? 0) + (n.viewportInsets?.bottom ?? 0),
@@ -32,19 +32,19 @@ function Ot(n) {
32
32
  }), [Y, ke] = g(n.defaultSize ?? {
33
33
  width: 400,
34
34
  height: 300
35
- }), [u, Me] = g(!1), [k, ae] = g(!1), [M, se] = g(!1), [Te, q] = g(!1), _ = st({
35
+ }), [c, Me] = g(!1), [k, ae] = g(!1), [M, se] = g(!1), [Te, q] = g(!1), S = st({
36
36
  open: () => n.open,
37
37
  exitDurationMs: 120
38
38
  });
39
39
  let de = {
40
40
  x: 0,
41
41
  y: 0
42
- }, ue = {
42
+ }, ce = {
43
43
  x: 0,
44
44
  y: 0,
45
45
  width: 0,
46
46
  height: 0
47
- }, ce = {
47
+ }, ue = {
48
48
  x: 0,
49
49
  y: 0
50
50
  }, fe = {
@@ -52,28 +52,28 @@ function Ot(n) {
52
52
  y: 0,
53
53
  width: 0,
54
54
  height: 0
55
- }, he = "se", a, d = null, T, b = null, R = {
55
+ }, he = "se", a, d = null, T, m = null, A = {
56
56
  x: 0,
57
57
  y: 0
58
- }, I = null, W = null, X = !1, z = {
58
+ }, I = null, W = null, X = !1, p = {
59
59
  x: n.defaultPosition?.x ?? 0,
60
60
  y: n.defaultPosition?.y ?? 0,
61
61
  width: n.defaultSize?.width ?? 400,
62
62
  height: n.defaultSize?.height ?? 300
63
- }, A = {
64
- ...z
65
- }, p;
63
+ }, v = {
64
+ ...p
65
+ }, $;
66
66
  const we = (e) => {
67
- A = {
67
+ v = {
68
68
  ...e
69
69
  };
70
70
  const t = Z({
71
71
  width: window.innerWidth,
72
72
  height: window.innerHeight
73
- }, $());
74
- p = {
75
- x: t.width > e.width ? (e.x - t.x) / (t.width - e.width) : p?.x ?? 0.5,
76
- y: t.height > e.height ? (e.y - t.y) / (t.height - e.height) : p?.y ?? 0.5
73
+ }, _());
74
+ $ = {
75
+ x: t.width > e.width ? (e.x - t.x) / (t.width - e.width) : $?.x ?? 0.5,
76
+ y: t.height > e.height ? (e.y - t.y) / (t.height - e.height) : $?.y ?? 0.5
77
77
  };
78
78
  }, We = {
79
79
  n: "ns-resize",
@@ -90,13 +90,13 @@ function Ot(n) {
90
90
  return;
91
91
  }
92
92
  W?.(), W = ot({
93
- kind: b === "resize" ? "resize" : "drag",
93
+ kind: m === "resize" ? "resize" : "drag",
94
94
  cursor: t,
95
95
  lockUserSelect: !0
96
96
  });
97
97
  }, ge = (e) => {
98
- z = e, a && (a.style.transform = `translate3d(${e.x}px, ${e.y}px, 0)`, a.style.width = `${e.width}px`, a.style.height = `${e.height}px`);
99
- }, Be = () => {
98
+ p = e, a && (a.style.transform = `translate3d(${e.x}px, ${e.y}px, 0)`, a.style.width = `${e.width}px`, a.style.height = `${e.height}px`);
99
+ }, Oe = () => {
100
100
  const e = N(), t = Y();
101
101
  return {
102
102
  x: e.x,
@@ -105,21 +105,21 @@ function Ot(n) {
105
105
  height: t.height
106
106
  };
107
107
  }, j = (e) => {
108
- z = e, Le((t) => t.x === e.x && t.y === e.y ? t : {
108
+ p = e, Le((t) => t.x === e.x && t.y === e.y ? t : {
109
109
  x: e.x,
110
110
  y: e.y
111
111
  }), ke((t) => t.width === e.width && t.height === e.height ? t : {
112
112
  width: e.width,
113
113
  height: e.height
114
114
  });
115
- }, De = () => {
115
+ }, Be = () => {
116
116
  try {
117
117
  a?.focus({
118
118
  preventScroll: !0
119
119
  });
120
120
  } catch {
121
121
  }
122
- }, Oe = (e) => {
122
+ }, De = (e) => {
123
123
  const t = e instanceof Element ? e : null;
124
124
  return t ? t.closest('button, input, select, textarea, a, [role="button"], [tabindex]:not([tabindex="-1"])') === null : !0;
125
125
  }, V = (e) => !!a && e instanceof Node && a.contains(e), He = (e) => {
@@ -135,12 +135,12 @@ function Ot(n) {
135
135
  height: e.height
136
136
  };
137
137
  }, me = () => {
138
- n.open && (d === null || b === null || typeof window > "u" || ge(at({
139
- mode: b,
140
- pointer: R,
138
+ n.open && (d === null || m === null || typeof window > "u" || ge(at({
139
+ mode: m,
140
+ pointer: A,
141
141
  dragStartPos: de,
142
- dragStartRect: ue,
143
- resizeStartPos: ce,
142
+ dragStartRect: ce,
143
+ resizeStartPos: ue,
144
144
  resizeStartRect: fe,
145
145
  resizeHandle: he,
146
146
  minSize: ee(),
@@ -149,7 +149,7 @@ function Ot(n) {
149
149
  width: window.innerWidth,
150
150
  height: window.innerHeight
151
151
  },
152
- viewportInsets: $(),
152
+ viewportInsets: _(),
153
153
  mobile: L(),
154
154
  mobilePadding: re
155
155
  })));
@@ -159,40 +159,48 @@ function Ot(n) {
159
159
  width: window.innerWidth,
160
160
  height: window.innerHeight
161
161
  };
162
- if (u() || h()) {
163
- j(Z(t, $()));
162
+ if (c() || h()) {
163
+ j(Z(t, _()));
164
164
  return;
165
165
  }
166
166
  let r = lt({
167
- rect: A,
167
+ rect: v,
168
168
  minSize: ee(),
169
169
  maxSize: te(),
170
170
  viewport: t,
171
- viewportInsets: $(),
171
+ viewportInsets: _(),
172
172
  mobile: n.boundary === void 0 && L(),
173
173
  mobilePadding: re,
174
174
  center: e?.center ?? !1
175
175
  });
176
- if (n.boundary !== void 0 && p && !e?.center) {
177
- const o = Z(t, $());
176
+ if (n.boundary !== void 0 && $ && !e?.center) {
177
+ const o = Z(t, _());
178
178
  r = {
179
179
  ...r,
180
- x: o.x + p.x * Math.max(0, o.width - r.width),
181
- y: o.y + p.y * Math.max(0, o.height - r.height)
180
+ x: o.x + $.x * Math.max(0, o.width - r.width),
181
+ y: o.y + $.y * Math.max(0, o.height - r.height)
182
182
  };
183
183
  }
184
- if (j(r), !p) {
184
+ if (j(r), !$) {
185
185
  const o = {
186
- width: A.width,
187
- height: A.height
186
+ width: v.width,
187
+ height: v.height
188
188
  };
189
- we(r), Object.assign(A, o);
189
+ we(r), Object.assign(v, o);
190
190
  }
191
191
  }, ve = (e) => {
192
192
  I !== null && typeof cancelAnimationFrame < "u" && (cancelAnimationFrame(I), I = null), e && me();
193
- const t = e ? Ne() ?? z : null;
194
- Ie(() => {
195
- t && (j(t), we(t)), d = null, b = null, ae(!1), se(!1);
193
+ const t = e ? Ne() ?? p : null;
194
+ Se(() => {
195
+ if (t) {
196
+ j(t);
197
+ const r = {
198
+ width: v.width,
199
+ height: v.height
200
+ };
201
+ we(t), m === "drag" && Object.assign(v, r);
202
+ }
203
+ d = null, m = null, ae(!1), se(!1);
196
204
  }), U(!1, ""), T = void 0;
197
205
  }, G = (e = !1) => {
198
206
  T ? T.stop({
@@ -203,16 +211,16 @@ function Ot(n) {
203
211
  let e = 0;
204
212
  const t = () => {
205
213
  if (n.boundary !== void 0) {
206
- const o = ut(ft({
207
- owner: O
208
- }), n.boundary, Re), S = o ? {
214
+ const o = ct(ft({
215
+ owner: D
216
+ }), n.boundary, Re), P = o ? {
209
217
  top: o.top,
210
218
  left: o.left,
211
219
  right: window.innerWidth - o.right,
212
220
  bottom: window.innerHeight - o.bottom
213
221
  } : {};
214
- Ie(() => {
215
- oe(!!(o && o.width > 16 && o.height > 16)), ie(o?.width ?? 0), ne((B) => JSON.stringify(B) === JSON.stringify(S) ? B : S);
222
+ Se(() => {
223
+ oe(!!(o && o.width > 16 && o.height > 16)), ie(o?.width ?? 0), ne((O) => JSON.stringify(O) === JSON.stringify(P) ? O : P);
216
224
  });
217
225
  } else
218
226
  oe(!0), ie(window.innerWidth), ne((o) => Object.keys(o).length ? {} : o);
@@ -227,7 +235,7 @@ function Ot(n) {
227
235
  });
228
236
  };
229
237
  window.addEventListener("resize", r), C(() => window.removeEventListener("resize", r));
230
- }), P(() => {
238
+ }), R(() => {
231
239
  if (!n.open) return;
232
240
  L();
233
241
  const e = !X && !n.defaultPosition, t = () => {
@@ -240,11 +248,11 @@ function Ot(n) {
240
248
  return;
241
249
  }
242
250
  requestAnimationFrame(t);
243
- }), P(() => {
244
- $(), h(), !(!n.open || !X || d !== null) && Qe(() => E({
251
+ }), R(() => {
252
+ _(), h(), !(!n.open || !X || d !== null) && Qe(() => E({
245
253
  center: !1
246
254
  }));
247
- }), P(() => {
255
+ }), R(() => {
248
256
  if (!n.open) return;
249
257
  const e = (t) => {
250
258
  if (t.key !== "Escape") return;
@@ -252,13 +260,13 @@ function Ot(n) {
252
260
  !V(t.target) && !V(r) || He(t.target) || (t.preventDefault(), typeof t.stopImmediatePropagation == "function" ? t.stopImmediatePropagation() : t.stopPropagation(), n.onOpenChange(!1));
253
261
  };
254
262
  document.addEventListener("keydown", e, !0), C(() => document.removeEventListener("keydown", e, !0));
255
- }), P(() => {
263
+ }), R(() => {
256
264
  if (!n.open) {
257
265
  q(!1), G(!1);
258
266
  return;
259
267
  }
260
268
  q(!0);
261
- }), P(() => {
269
+ }), R(() => {
262
270
  if (!n.open) return;
263
271
  const e = (o) => {
264
272
  q(V(o));
@@ -270,35 +278,35 @@ function Ot(n) {
270
278
  document.addEventListener("pointerdown", t), document.addEventListener("focusin", r), C(() => {
271
279
  document.removeEventListener("pointerdown", t), document.removeEventListener("focusin", r);
272
280
  });
273
- }), P(() => {
281
+ }), R(() => {
274
282
  if (!n.open) return;
275
- const e = Be();
276
- d === null ? ge(e) : z = e;
283
+ const e = Oe();
284
+ d === null ? ge(e) : p = e;
277
285
  });
278
286
  const Ye = (e) => {
279
- !Q() || u() || h() || d !== null || e.pointerType === "mouse" && e.button !== 0 || e.target?.closest('button, input, select, textarea, a, [role="button"], [data-floe-floating-window-header-actions]') || (e.preventDefault(), d = e.pointerId, b = "drag", ae(!0), de = {
287
+ !Q() || c() || h() || d !== null || e.pointerType === "mouse" && e.button !== 0 || e.target?.closest('button, input, select, textarea, a, [role="button"], [data-floe-floating-window-header-actions]') || (e.preventDefault(), d = e.pointerId, m = "drag", ae(!0), de = {
280
288
  x: e.clientX,
281
289
  y: e.clientY
282
- }, ue = {
283
- ...z
284
- }, R = {
290
+ }, ce = {
291
+ ...p
292
+ }, A = {
285
293
  x: e.clientX,
286
294
  y: e.clientY
287
295
  }, U(!0, "grabbing"), xe(e));
288
- }, m = (e) => (t) => {
289
- !K() || u() || h() || d !== null || t.pointerType === "mouse" && t.button !== 0 || (t.preventDefault(), t.stopPropagation(), d = t.pointerId, b = "resize", se(!0), he = e, ce = {
296
+ }, y = (e) => (t) => {
297
+ !K() || c() || h() || d !== null || t.pointerType === "mouse" && t.button !== 0 || (t.preventDefault(), t.stopPropagation(), d = t.pointerId, m = "resize", se(!0), he = e, ue = {
290
298
  x: t.clientX,
291
299
  y: t.clientY
292
300
  }, fe = {
293
- ...z
294
- }, R = {
301
+ ...p
302
+ }, A = {
295
303
  x: t.clientX,
296
304
  y: t.clientY
297
305
  }, U(!0, We[e]), xe(t));
298
306
  }, ye = () => {
299
307
  I = null, me();
300
308
  }, qe = (e) => {
301
- if (!(d === null || e.pointerId !== d) && b !== null && (R = {
309
+ if (!(d === null || e.pointerId !== d) && m !== null && (A = {
302
310
  x: e.clientX,
303
311
  y: e.clientY
304
312
  }, I === null)) {
@@ -318,19 +326,19 @@ function Ot(n) {
318
326
  reason: r,
319
327
  snapshot: o
320
328
  }) => {
321
- R = {
329
+ A = {
322
330
  x: o.latestClientX,
323
331
  y: o.latestClientY
324
332
  }, ve(t || r === "pointer_cancel");
325
333
  }
326
334
  });
327
335
  }, be = () => {
328
- d !== null && G(!0), !h() && (Me(!u()), E());
336
+ d !== null && G(!0), !h() && (Me(!c()), E());
329
337
  }, Xe = (e) => {
330
338
  e.target?.closest("button, [data-floe-floating-window-header-actions]") || be();
331
339
  }, Ue = (e) => {
332
- Oe(e.target) && De();
333
- }, v = (e) => D("absolute z-10", {
340
+ De(e.target) && Be();
341
+ }, x = (e) => B("absolute z-10", {
334
342
  n: "cursor-ns-resize top-0 left-2 right-2 h-1",
335
343
  s: "cursor-ns-resize bottom-0 left-2 right-2 h-1",
336
344
  e: "cursor-ew-resize right-0 top-2 bottom-2 w-1",
@@ -341,25 +349,25 @@ function Ot(n) {
341
349
  sw: "cursor-nesw-resize bottom-0 left-0 w-2 h-2"
342
350
  }[e]);
343
351
  return [(() => {
344
- var e = wt(), t = O;
345
- return typeof t == "function" ? _e(t, e) : O = e, e;
346
- })(), l(x, {
352
+ var e = wt(), t = D;
353
+ return typeof t == "function" ? _e(t, e) : D = e, e;
354
+ })(), l(z, {
347
355
  get when() {
348
- return _.mounted();
356
+ return S.mounted();
349
357
  },
350
358
  get children() {
351
359
  return l(Ve, {
352
360
  get children() {
353
- var e = St(), t = e.firstChild, r = t.firstChild, o = r.firstChild, S = o.nextSibling, B = r.nextSibling, ze = a;
361
+ var e = It(), t = e.firstChild, r = t.firstChild, o = r.firstChild, P = o.nextSibling, O = r.nextSibling, ze = a;
354
362
  return typeof ze == "function" ? _e(ze, e) : a = e, pe(e, $e({
355
363
  get "data-floating-presence"() {
356
- return _.state();
364
+ return S.state();
357
365
  },
358
366
  get "aria-hidden"() {
359
- return _.exiting() || !H() ? "true" : void 0;
367
+ return S.exiting() || !H() ? "true" : void 0;
360
368
  },
361
369
  get inert() {
362
- return _.exiting() || !H();
370
+ return S.exiting() || !H();
363
371
  },
364
372
  get "data-floe-floating-window-compact"() {
365
373
  return h() ? "true" : void 0;
@@ -368,7 +376,7 @@ function Ot(n) {
368
376
  [Pe]: "true"
369
377
  }, {
370
378
  get class() {
371
- return D("fixed left-0 top-0 z-[100] flex flex-col", (k() || M()) && "select-none", _.exiting() && "pointer-events-none");
379
+ return B("fixed left-0 top-0 z-[100] flex flex-col", (k() || M()) && "select-none", S.exiting() && "pointer-events-none");
372
380
  },
373
381
  get style() {
374
382
  return {
@@ -387,7 +395,7 @@ function Ot(n) {
387
395
  tabIndex: -1,
388
396
  onPointerDown: Ue
389
397
  }), !1, !0), pe(t, $e({
390
- [ct]: "true"
398
+ [ut]: "true"
391
399
  }, {
392
400
  "data-floe-floating-window-surface": "true",
393
401
  "data-floe-surface": "floating",
@@ -401,38 +409,38 @@ function Ot(n) {
401
409
  [Pe]: "true"
402
410
  }, {
403
411
  get class() {
404
- return D("relative flex h-full w-full flex-col overflow-hidden", "text-card-foreground rounded-md", "border", "floe-floating-presence floe-floating-window-motion", (k() || M()) && "floe-floating-presence--suspended", u() && "rounded-none", n.class);
412
+ return B("relative flex h-full w-full flex-col overflow-hidden", "text-card-foreground rounded-md", "border", "floe-floating-presence floe-floating-window-motion", (k() || M()) && "floe-floating-presence--suspended", c() && "rounded-none", n.class);
405
413
  },
406
414
  get style() {
407
415
  return {
408
- "border-radius": u() ? "0" : "10px"
416
+ "border-radius": c() ? "0" : "10px"
409
417
  };
410
418
  },
411
419
  get "data-floating-presence"() {
412
- return _.state();
420
+ return S.state();
413
421
  }
414
- }), !1, !0), r.$$dblclick = Xe, r.$$pointerdown = Ye, c(o, l(x, {
422
+ }), !1, !0), r.$$dblclick = Xe, r.$$pointerdown = Ye, u(o, l(z, {
415
423
  get when() {
416
424
  return n.title;
417
425
  },
418
426
  get children() {
419
427
  var i = gt();
420
- return c(i, () => n.title), f(() => Ge(i, "id", le())), i;
428
+ return u(i, () => n.title), f(() => Ge(i, "id", le())), i;
421
429
  }
422
- })), c(r, l(x, {
430
+ })), u(r, l(z, {
423
431
  get when() {
424
432
  return n.headerActions;
425
433
  },
426
434
  get children() {
427
435
  var i = mt(), je = i.firstChild;
428
- return c(i, () => n.headerActions, je), i;
436
+ return u(i, () => n.headerActions, je), i;
429
437
  }
430
- }), S), c(S, l(x, {
438
+ }), P), u(P, l(z, {
431
439
  get when() {
432
440
  return !h();
433
441
  },
434
442
  get children() {
435
- return l(Se, {
443
+ return l(Ie, {
436
444
  variant: "ghost",
437
445
  size: "icon",
438
446
  "data-floe-floating-window-control": "maximize",
@@ -441,12 +449,12 @@ function Ot(n) {
441
449
  i.stopPropagation(), be();
442
450
  },
443
451
  get "aria-label"() {
444
- return J(() => !!u())() ? n.labels?.restore ?? "Restore" : n.labels?.maximize ?? "Maximize";
452
+ return J(() => !!c())() ? n.labels?.restore ?? "Restore" : n.labels?.maximize ?? "Maximize";
445
453
  },
446
454
  get children() {
447
- return l(x, {
455
+ return l(z, {
448
456
  get when() {
449
- return u();
457
+ return c();
450
458
  },
451
459
  get fallback() {
452
460
  return l(nt, {
@@ -462,7 +470,7 @@ function Ot(n) {
462
470
  }
463
471
  });
464
472
  }
465
- }), null), c(S, l(Se, {
473
+ }), null), u(P, l(Ie, {
466
474
  variant: "ghost-destructive",
467
475
  size: "icon",
468
476
  "data-floe-floating-window-control": "close",
@@ -478,53 +486,53 @@ function Ot(n) {
478
486
  class: "w-3.5 h-3.5"
479
487
  });
480
488
  }
481
- }), null), c(B, () => n.children), c(t, l(x, {
489
+ }), null), u(O, () => n.children), u(t, l(z, {
482
490
  get when() {
483
491
  return n.footer;
484
492
  },
485
493
  get children() {
486
494
  var i = vt();
487
- return c(i, () => n.footer), i;
495
+ return u(i, () => n.footer), i;
488
496
  }
489
- }), null), c(t, l(x, {
497
+ }), null), u(t, l(z, {
490
498
  get when() {
491
- return J(() => !!(K() && !u()))() && !h();
499
+ return J(() => !!(K() && !c()))() && !h();
492
500
  },
493
501
  get children() {
494
502
  return [(() => {
495
503
  var i = yt();
496
- return y(i, "pointerdown", m("n"), !0), f(() => w(i, v("n"))), i;
504
+ return b(i, "pointerdown", y("n"), !0), f(() => w(i, x("n"))), i;
497
505
  })(), (() => {
498
506
  var i = xt();
499
- return y(i, "pointerdown", m("s"), !0), f(() => w(i, v("s"))), i;
500
- })(), l(x, {
507
+ return b(i, "pointerdown", y("s"), !0), f(() => w(i, x("s"))), i;
508
+ })(), l(z, {
501
509
  get when() {
502
510
  return !L();
503
511
  },
504
512
  get children() {
505
513
  return [(() => {
506
514
  var i = bt();
507
- return y(i, "pointerdown", m("e"), !0), f(() => w(i, v("e"))), i;
515
+ return b(i, "pointerdown", y("e"), !0), f(() => w(i, x("e"))), i;
508
516
  })(), (() => {
509
517
  var i = zt();
510
- return y(i, "pointerdown", m("w"), !0), f(() => w(i, v("w"))), i;
518
+ return b(i, "pointerdown", y("w"), !0), f(() => w(i, x("w"))), i;
511
519
  })(), (() => {
512
520
  var i = pt();
513
- return y(i, "pointerdown", m("ne"), !0), f(() => w(i, v("ne"))), i;
521
+ return b(i, "pointerdown", y("ne"), !0), f(() => w(i, x("ne"))), i;
514
522
  })(), (() => {
515
523
  var i = $t();
516
- return y(i, "pointerdown", m("nw"), !0), f(() => w(i, v("nw"))), i;
524
+ return b(i, "pointerdown", y("nw"), !0), f(() => w(i, x("nw"))), i;
517
525
  })(), (() => {
518
526
  var i = _t();
519
- return y(i, "pointerdown", m("se"), !0), f(() => w(i, v("se"))), i;
527
+ return b(i, "pointerdown", y("se"), !0), f(() => w(i, x("se"))), i;
520
528
  })(), (() => {
521
- var i = It();
522
- return y(i, "pointerdown", m("sw"), !0), f(() => w(i, v("sw"))), i;
529
+ var i = St();
530
+ return b(i, "pointerdown", y("sw"), !0), f(() => w(i, x("sw"))), i;
523
531
  })()];
524
532
  }
525
533
  })];
526
534
  }
527
- }), null), f(() => w(r, D("flex shrink-0 items-center justify-between h-8", "border-b", u() ? "rounded-none" : "rounded-t-md", Q() && !u() && !h() && "cursor-move"))), e;
535
+ }), null), f(() => w(r, B("flex shrink-0 items-center justify-between h-8", "border-b", c() ? "rounded-none" : "rounded-t-md", Q() && !c() && !h() && "cursor-move"))), e;
528
536
  }
529
537
  });
530
538
  }
@@ -532,5 +540,5 @@ function Ot(n) {
532
540
  }
533
541
  Je(["pointerdown", "dblclick"]);
534
542
  export {
535
- Ot as FloatingWindow
543
+ Dt as FloatingWindow
536
544
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@floegence/floe-webapp-core",
3
- "version": "0.52.12",
3
+ "version": "0.52.13",
4
4
  "license": "MIT",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",