@floegence/floe-webapp-core 0.39.3 → 0.39.5

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,29 +1,29 @@
1
- import { createComponent as s, Portal as Le, spread as de, mergeProps as ue, memo as ce, insert as g, effect as u, setAttribute as Me, addEventListener as m, className as c, template as a, use as De, delegateEvents as ke } from "solid-js/web";
2
- import { createUniqueId as Te, createSignal as v, onMount as We, onCleanup as q, createEffect as b, Show as P, batch as Oe, untrack as He } from "solid-js";
1
+ import { createComponent as s, Portal as Me, spread as de, mergeProps as ue, memo as ce, insert as g, effect as c, setAttribute as Te, addEventListener as m, className as f, template as d, use as De, delegateEvents as ke } from "solid-js/web";
2
+ import { createUniqueId as We, createSignal as v, onMount as Oe, onCleanup as X, createEffect as b, Show as P, batch as He, untrack as Ue } from "solid-js";
3
3
  import { cn as E } from "../../utils/cn.js";
4
- import { useLayout as Ue } from "../../context/LayoutContext.js";
4
+ import { useLayout as Ye } from "../../context/LayoutContext.js";
5
5
  import { Button as fe } from "./Button.js";
6
- import { Restore as Xe, Maximize as Ye, X as qe } from "../icons/index.js";
7
- import { startHotInteraction as Ne } from "../../utils/hotInteraction.js";
8
- import { resolveFloatingWindowViewport as he, normalizeFloatingWindowRect as we, resolveFloatingWindowRect as Be } from "./floatingWindowGeometry.js";
6
+ import { Restore as Ne, Maximize as Xe, X as qe } from "../icons/index.js";
7
+ import { startHotInteraction as Be } from "../../utils/hotInteraction.js";
8
+ import { resolveFloatingWindowViewport as he, normalizeFloatingWindowRect as we, resolveFloatingWindowRect as Ge } from "./floatingWindowGeometry.js";
9
9
  import { createFloatingPresence as je } from "./floatingPresence.js";
10
10
  import { LOCAL_INTERACTION_SURFACE_ATTR as ge } from "./localInteractionSurface.js";
11
- import { SURFACE_PORTAL_LAYER_ATTR as Ge } from "./dialogSurfaceScope.js";
12
- var Ve = /* @__PURE__ */ a('<h2 class="text-sm font-medium truncate select-none">'), Ze = /* @__PURE__ */ a('<div class="flex items-center justify-end gap-2 p-3 border-t border-border">'), Je = /* @__PURE__ */ a("<div data-floe-floating-window-resize-handle=n style=touch-action:none>"), Ke = /* @__PURE__ */ a("<div data-floe-floating-window-resize-handle=s style=touch-action:none>"), Qe = /* @__PURE__ */ a("<div data-floe-floating-window-resize-handle=e style=touch-action:none>"), et = /* @__PURE__ */ a("<div data-floe-floating-window-resize-handle=w style=touch-action:none>"), tt = /* @__PURE__ */ a("<div data-floe-floating-window-resize-handle=ne style=touch-action:none>"), nt = /* @__PURE__ */ a("<div data-floe-floating-window-resize-handle=nw style=touch-action:none>"), it = /* @__PURE__ */ a("<div data-floe-floating-window-resize-handle=se style=touch-action:none>"), ot = /* @__PURE__ */ a("<div data-floe-floating-window-resize-handle=sw style=touch-action:none>"), rt = /* @__PURE__ */ a('<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"></div><div class="flex items-center gap-0.5 -mr-1"></div></div><div class="flex-1 overflow-auto p-3">');
13
- function pt(i) {
14
- const N = () => i.resizable ?? !0, B = () => i.draggable ?? !0, A = () => i.minSize ?? {
11
+ import { SURFACE_PORTAL_LAYER_ATTR as Ve, SURFACE_FLOATING_LAYER_ATTR as Ze } from "./dialogSurfaceScope.js";
12
+ var Je = /* @__PURE__ */ d('<h2 class="text-sm font-medium truncate select-none">'), Ke = /* @__PURE__ */ d('<div class="flex items-center justify-end gap-2 p-3 border-t border-border">'), Qe = /* @__PURE__ */ d("<div data-floe-floating-window-resize-handle=n style=touch-action:none>"), et = /* @__PURE__ */ d("<div data-floe-floating-window-resize-handle=s style=touch-action:none>"), tt = /* @__PURE__ */ d("<div data-floe-floating-window-resize-handle=e style=touch-action:none>"), nt = /* @__PURE__ */ d("<div data-floe-floating-window-resize-handle=w style=touch-action:none>"), it = /* @__PURE__ */ d("<div data-floe-floating-window-resize-handle=ne style=touch-action:none>"), ot = /* @__PURE__ */ d("<div data-floe-floating-window-resize-handle=nw style=touch-action:none>"), rt = /* @__PURE__ */ d("<div data-floe-floating-window-resize-handle=se style=touch-action:none>"), lt = /* @__PURE__ */ d("<div data-floe-floating-window-resize-handle=sw style=touch-action:none>"), st = /* @__PURE__ */ d('<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"></div><div class="flex items-center gap-0.5 -mr-1"></div></div><div class="flex-1 overflow-auto p-3">');
13
+ function xt(i) {
14
+ const q = () => i.resizable ?? !0, B = () => i.draggable ?? !0, A = () => i.minSize ?? {
15
15
  width: 200,
16
16
  height: 150
17
17
  }, F = () => i.maxSize ?? {
18
18
  width: 1 / 0,
19
19
  height: 1 / 0
20
- }, x = () => i.viewportInsets ?? {}, me = () => i.zIndex ?? 100, pe = Te(), ve = Ue(), $ = () => ve.isMobile(), L = 16, j = () => `floating-window-${pe}-title`, [M, xe] = v(i.defaultPosition ?? {
20
+ }, x = () => i.viewportInsets ?? {}, me = () => i.zIndex ?? 100, pe = We(), ve = Ye(), $ = () => ve.isMobile(), L = 16, G = () => `floating-window-${pe}-title`, [M, xe] = v(i.defaultPosition ?? {
21
21
  x: 0,
22
22
  y: 0
23
- }), [D, ze] = v(i.defaultSize ?? {
23
+ }), [T, ye] = v(i.defaultSize ?? {
24
24
  width: 400,
25
25
  height: 300
26
- }), [d, G] = v(!1), [k, V] = v(!1), [T, Z] = v(!1), [ye, W] = v(!1), I = je({
26
+ }), [u, j] = v(!1), [D, V] = v(!1), [k, Z] = v(!1), [ze, W] = v(!1), I = je({
27
27
  open: () => i.open,
28
28
  exitDurationMs: 120
29
29
  }), [be, Pe] = v(null);
@@ -43,10 +43,10 @@ function pt(i) {
43
43
  y: 0,
44
44
  width: 0,
45
45
  height: 0
46
- }, te = "se", o, r = null, p = null, S = {
46
+ }, te = "se", o, l = null, p = null, S = {
47
47
  x: 0,
48
48
  y: 0
49
- }, z = null, R = null, O = !1, y = {
49
+ }, y = null, R = null, O = !1, z = {
50
50
  x: i.defaultPosition?.x ?? 0,
51
51
  y: i.defaultPosition?.y ?? 0,
52
52
  width: i.defaultSize?.width ?? 400,
@@ -66,15 +66,15 @@ function pt(i) {
66
66
  R?.(), R = null;
67
67
  return;
68
68
  }
69
- R?.(), R = Ne({
69
+ R?.(), R = Be({
70
70
  kind: p === "resize" ? "resize" : "drag",
71
71
  cursor: t,
72
72
  lockUserSelect: !0
73
73
  });
74
74
  }, ne = (e) => {
75
- y = e, o && (o.style.transform = `translate3d(${e.x}px, ${e.y}px, 0)`, o.style.width = `${e.width}px`, o.style.height = `${e.height}px`);
75
+ z = e, o && (o.style.transform = `translate3d(${e.x}px, ${e.y}px, 0)`, o.style.width = `${e.width}px`, o.style.height = `${e.height}px`);
76
76
  }, U = () => {
77
- const e = M(), t = D();
77
+ const e = M(), t = T();
78
78
  return {
79
79
  x: e.x,
80
80
  y: e.y,
@@ -82,10 +82,10 @@ function pt(i) {
82
82
  height: t.height
83
83
  };
84
84
  }, _ = (e) => {
85
- y = e, xe((t) => t.x === e.x && t.y === e.y ? t : {
85
+ z = e, xe((t) => t.x === e.x && t.y === e.y ? t : {
86
86
  x: e.x,
87
87
  y: e.y
88
- }), ze((t) => t.width === e.width && t.height === e.height ? t : {
88
+ }), ye((t) => t.width === e.width && t.height === e.height ? t : {
89
89
  width: e.width,
90
90
  height: e.height
91
91
  });
@@ -99,7 +99,10 @@ function pt(i) {
99
99
  }, Se = (e) => {
100
100
  const t = e instanceof Element ? e : null;
101
101
  return t ? t.closest('button, input, select, textarea, a, [role="button"], [tabindex]:not([tabindex="-1"])') === null : !0;
102
- }, X = (e) => !!o && e instanceof Node && o.contains(e), _e = () => {
102
+ }, Y = (e) => !!o && e instanceof Node && o.contains(e), _e = (e) => {
103
+ const a = (e instanceof Element ? e : null)?.closest('[role="menu"]')?.closest(`[${Ze}="true"]`);
104
+ return !!(a && o?.contains(a));
105
+ }, Re = () => {
103
106
  if (!o) return null;
104
107
  const e = o.getBoundingClientRect();
105
108
  return {
@@ -109,7 +112,7 @@ function pt(i) {
109
112
  height: e.height
110
113
  };
111
114
  }, ie = () => {
112
- i.open && (r === null || p === null || typeof window > "u" || ne(Be({
115
+ i.open && (l === null || p === null || typeof window > "u" || ne(Ge({
113
116
  mode: p,
114
117
  pointer: S,
115
118
  dragStartPos: J,
@@ -133,7 +136,7 @@ function pt(i) {
133
136
  width: window.innerWidth,
134
137
  height: window.innerHeight
135
138
  };
136
- if (d()) {
139
+ if (u()) {
137
140
  _(he(t, x()));
138
141
  return;
139
142
  }
@@ -147,28 +150,28 @@ function pt(i) {
147
150
  mobilePadding: L,
148
151
  center: e?.center ?? !1
149
152
  }));
150
- }, Y = (e, t = !0) => {
151
- z !== null && typeof cancelAnimationFrame < "u" && (cancelAnimationFrame(z), z = null), t && ie();
152
- const l = t ? _e() ?? y : null;
153
+ }, N = (e, t = !0) => {
154
+ y !== null && typeof cancelAnimationFrame < "u" && (cancelAnimationFrame(y), y = null), t && ie();
155
+ const r = t ? Re() ?? z : null;
153
156
  if (e !== void 0)
154
157
  try {
155
158
  typeof o?.releasePointerCapture == "function" && o.releasePointerCapture(e);
156
159
  } catch {
157
160
  }
158
- Oe(() => {
159
- l && _(l), r = null, p = null, V(!1), Z(!1);
161
+ He(() => {
162
+ r && _(r), l = null, p = null, V(!1), Z(!1);
160
163
  }), H(!1, "");
161
164
  };
162
- We(() => {
165
+ Oe(() => {
163
166
  i.open || C({
164
167
  center: !i.defaultPosition
165
168
  });
166
169
  const e = () => {
167
- r === null && C({
170
+ l === null && C({
168
171
  center: !1
169
172
  });
170
173
  };
171
- window.addEventListener("resize", e), q(() => window.removeEventListener("resize", e));
174
+ window.addEventListener("resize", e), X(() => window.removeEventListener("resize", e));
172
175
  }), b(() => {
173
176
  if (!i.open) return;
174
177
  $();
@@ -183,80 +186,80 @@ function pt(i) {
183
186
  }
184
187
  requestAnimationFrame(t);
185
188
  }), b(() => {
186
- !i.open || !O || r !== null || (x(), He(() => C({
189
+ !i.open || !O || l !== null || (x(), Ue(() => C({
187
190
  center: !1
188
191
  })));
189
192
  }), b(() => {
190
193
  if (!i.open) return;
191
194
  const e = (t) => {
192
195
  if (t.key !== "Escape") return;
193
- const l = typeof document < "u" ? document.activeElement : null;
194
- !X(t.target) && !X(l) || (t.preventDefault(), typeof t.stopImmediatePropagation == "function" ? t.stopImmediatePropagation() : t.stopPropagation(), i.onOpenChange(!1));
196
+ const r = typeof document < "u" ? document.activeElement : null;
197
+ !Y(t.target) && !Y(r) || _e(t.target) || (t.preventDefault(), typeof t.stopImmediatePropagation == "function" ? t.stopImmediatePropagation() : t.stopPropagation(), i.onOpenChange(!1));
195
198
  };
196
- document.addEventListener("keydown", e, !0), q(() => document.removeEventListener("keydown", e, !0));
199
+ document.addEventListener("keydown", e, !0), X(() => document.removeEventListener("keydown", e, !0));
197
200
  }), b(() => {
198
201
  if (!i.open) {
199
- W(!1), Y(r ?? void 0, !1);
202
+ W(!1), N(l ?? void 0, !1);
200
203
  return;
201
204
  }
202
205
  W(!0);
203
206
  }), b(() => {
204
207
  if (!i.open) return;
205
- const e = (w) => {
206
- W(X(w));
207
- }, t = (w) => {
208
- e(w.target);
209
- }, l = (w) => {
210
- e(w.target);
208
+ const e = (a) => {
209
+ W(Y(a));
210
+ }, t = (a) => {
211
+ e(a.target);
212
+ }, r = (a) => {
213
+ e(a.target);
211
214
  };
212
- document.addEventListener("pointerdown", t), document.addEventListener("focusin", l), q(() => {
213
- document.removeEventListener("pointerdown", t), document.removeEventListener("focusin", l);
215
+ document.addEventListener("pointerdown", t), document.addEventListener("focusin", r), X(() => {
216
+ document.removeEventListener("pointerdown", t), document.removeEventListener("focusin", r);
214
217
  });
215
218
  }), b(() => {
216
219
  if (!i.open) return;
217
220
  const e = U();
218
- r === null ? ne(e) : y = e;
221
+ l === null ? ne(e) : z = e;
219
222
  });
220
- const Re = (e) => {
221
- !B() || d() || e.pointerType === "mouse" && e.button !== 0 || e.target?.closest('button, input, select, textarea, a, [role="button"]') || (e.preventDefault(), r = e.pointerId, p = "drag", V(!0), J = {
223
+ const Ce = (e) => {
224
+ !B() || u() || e.pointerType === "mouse" && e.button !== 0 || e.target?.closest('button, input, select, textarea, a, [role="button"]') || (e.preventDefault(), l = e.pointerId, p = "drag", V(!0), J = {
222
225
  x: e.clientX,
223
226
  y: e.clientY
224
227
  }, K = {
225
- ...y
228
+ ...z
226
229
  }, S = {
227
230
  x: e.clientX,
228
231
  y: e.clientY
229
232
  }, H(!0, "grabbing"), typeof o?.setPointerCapture == "function" && o.setPointerCapture(e.pointerId));
230
- }, f = (e) => (t) => {
231
- !N() || d() || t.pointerType === "mouse" && t.button !== 0 || (t.preventDefault(), t.stopPropagation(), r = t.pointerId, p = "resize", Z(!0), te = e, Q = {
233
+ }, h = (e) => (t) => {
234
+ !q() || u() || t.pointerType === "mouse" && t.button !== 0 || (t.preventDefault(), t.stopPropagation(), l = t.pointerId, p = "resize", Z(!0), te = e, Q = {
232
235
  x: t.clientX,
233
236
  y: t.clientY
234
237
  }, ee = {
235
- ...y
238
+ ...z
236
239
  }, S = {
237
240
  x: t.clientX,
238
241
  y: t.clientY
239
242
  }, H(!0, $e[e]), typeof o?.setPointerCapture == "function" && o.setPointerCapture(t.pointerId));
240
243
  }, oe = () => {
241
- z = null, ie();
242
- }, Ce = (e) => {
243
- if (!(r === null || e.pointerId !== r) && p !== null && (S = {
244
+ y = null, ie();
245
+ }, Ee = (e) => {
246
+ if (!(l === null || e.pointerId !== l) && p !== null && (S = {
244
247
  x: e.clientX,
245
248
  y: e.clientY
246
- }, z === null)) {
249
+ }, y === null)) {
247
250
  if (typeof requestAnimationFrame > "u") {
248
251
  oe();
249
252
  return;
250
253
  }
251
- z = requestAnimationFrame(oe);
254
+ y = requestAnimationFrame(oe);
252
255
  }
253
256
  }, re = (e) => {
254
- r === null || e.pointerId !== r || (S = {
257
+ l === null || e.pointerId !== l || (S = {
255
258
  x: e.clientX,
256
259
  y: e.clientY
257
- }, Y(e.pointerId));
260
+ }, N(e.pointerId));
258
261
  }, le = () => {
259
- if (r !== null && Y(r, !0), d()) {
262
+ if (l !== null && N(l, !0), u()) {
260
263
  const t = be();
261
264
  t && _(we({
262
265
  rect: {
@@ -275,7 +278,7 @@ function pt(i) {
275
278
  mobile: $(),
276
279
  mobilePadding: L,
277
280
  center: !1
278
- })), G(!1);
281
+ })), j(!1);
279
282
  return;
280
283
  }
281
284
  const e = U();
@@ -291,12 +294,12 @@ function pt(i) {
291
294
  }), _(he({
292
295
  width: window.innerWidth,
293
296
  height: window.innerHeight
294
- }, x())), G(!0);
295
- }, Ee = () => {
297
+ }, x())), j(!0);
298
+ }, Ae = () => {
296
299
  le();
297
- }, Ae = (e) => {
300
+ }, Fe = (e) => {
298
301
  Se(e.target) && Ie();
299
- }, h = (e) => E("absolute z-10", {
302
+ }, w = (e) => E("absolute z-10", {
300
303
  n: "cursor-ns-resize top-0 left-2 right-2 h-1",
301
304
  s: "cursor-ns-resize bottom-0 left-2 right-2 h-1",
302
305
  e: "cursor-ew-resize right-0 top-2 bottom-2 w-1",
@@ -311,9 +314,9 @@ function pt(i) {
311
314
  return I.mounted();
312
315
  },
313
316
  get children() {
314
- return s(Le, {
317
+ return s(Me, {
315
318
  get children() {
316
- var e = rt(), t = e.firstChild, l = t.firstChild, w = l.firstChild, se = w.nextSibling, Fe = l.nextSibling, ae = o;
319
+ var e = st(), t = e.firstChild, r = t.firstChild, a = r.firstChild, se = a.nextSibling, Le = r.nextSibling, ae = o;
317
320
  return typeof ae == "function" ? De(ae, e) : o = e, de(e, ue({
318
321
  get "data-floating-presence"() {
319
322
  return I.state();
@@ -325,49 +328,49 @@ function pt(i) {
325
328
  [ge]: "true"
326
329
  }, {
327
330
  get class() {
328
- return E("fixed left-0 top-0 z-[100] flex flex-col", (k() || T()) && "select-none", I.exiting() && "pointer-events-none");
331
+ return E("fixed left-0 top-0 z-[100] flex flex-col", (D() || k()) && "select-none", I.exiting() && "pointer-events-none");
329
332
  },
330
333
  get style() {
331
334
  return {
332
- width: `${D().width}px`,
333
- height: `${D().height}px`,
335
+ width: `${T().width}px`,
336
+ height: `${T().height}px`,
334
337
  transform: `translate3d(${M().x}px, ${M().y}px, 0)`,
335
338
  "z-index": me(),
336
- "will-change": k() ? "transform" : T() ? "transform, width, height" : void 0
339
+ "will-change": D() ? "transform" : k() ? "transform, width, height" : void 0
337
340
  };
338
341
  },
339
- onPointerMove: Ce,
342
+ onPointerMove: Ee,
340
343
  onPointerUp: re,
341
344
  onPointerCancel: re,
342
345
  role: "dialog",
343
346
  get "aria-labelledby"() {
344
- return ce(() => !!i.title)() ? j() : void 0;
347
+ return ce(() => !!i.title)() ? G() : void 0;
345
348
  },
346
349
  tabIndex: -1,
347
- onPointerDown: Ae
350
+ onPointerDown: Fe
348
351
  }), !1, !0), de(t, ue({
349
- [Ge]: "true"
352
+ [Ve]: "true"
350
353
  }, {
351
354
  "data-floe-floating-window-surface": "true",
352
355
  get "data-floe-floating-window-state"() {
353
- return ye() ? "active" : "inactive";
356
+ return ze() ? "active" : "inactive";
354
357
  }
355
358
  }, {
356
359
  [ge]: "true"
357
360
  }, {
358
361
  get class() {
359
- return E("relative flex h-full w-full flex-col overflow-hidden", "text-card-foreground rounded-md", "border", "floe-floating-presence floe-floating-window-motion", (k() || T()) && "floe-floating-presence--suspended", d() && "rounded-none", i.class);
362
+ return E("relative flex h-full w-full flex-col overflow-hidden", "text-card-foreground rounded-md", "border", "floe-floating-presence floe-floating-window-motion", (D() || k()) && "floe-floating-presence--suspended", u() && "rounded-none", i.class);
360
363
  },
361
364
  get "data-floating-presence"() {
362
365
  return I.state();
363
366
  }
364
- }), !1, !0), l.$$dblclick = Ee, l.$$pointerdown = Re, g(w, s(P, {
367
+ }), !1, !0), r.$$dblclick = Ae, r.$$pointerdown = Ce, g(a, s(P, {
365
368
  get when() {
366
369
  return i.title;
367
370
  },
368
371
  get children() {
369
- var n = Ve();
370
- return g(n, () => i.title), u(() => Me(n, "id", j())), n;
372
+ var n = Je();
373
+ return g(n, () => i.title), c(() => Te(n, "id", G())), n;
371
374
  }
372
375
  })), g(se, s(fe, {
373
376
  variant: "ghost",
@@ -377,20 +380,20 @@ function pt(i) {
377
380
  n.stopPropagation(), le();
378
381
  },
379
382
  get "aria-label"() {
380
- return d() ? "Restore" : "Maximize";
383
+ return u() ? "Restore" : "Maximize";
381
384
  },
382
385
  get children() {
383
386
  return s(P, {
384
387
  get when() {
385
- return d();
388
+ return u();
386
389
  },
387
390
  get fallback() {
388
- return s(Ye, {
391
+ return s(Xe, {
389
392
  class: "w-3 h-3"
390
393
  });
391
394
  },
392
395
  get children() {
393
- return s(Xe, {
396
+ return s(Ne, {
394
397
  class: "w-3 h-3"
395
398
  });
396
399
  }
@@ -409,53 +412,53 @@ function pt(i) {
409
412
  class: "w-3.5 h-3.5"
410
413
  });
411
414
  }
412
- }), null), g(Fe, () => i.children), g(t, s(P, {
415
+ }), null), g(Le, () => i.children), g(t, s(P, {
413
416
  get when() {
414
417
  return i.footer;
415
418
  },
416
419
  get children() {
417
- var n = Ze();
420
+ var n = Ke();
418
421
  return g(n, () => i.footer), n;
419
422
  }
420
423
  }), null), g(t, s(P, {
421
424
  get when() {
422
- return ce(() => !!N())() && !d();
425
+ return ce(() => !!q())() && !u();
423
426
  },
424
427
  get children() {
425
428
  return [(() => {
426
- var n = Je();
427
- return m(n, "pointerdown", f("n"), !0), u(() => c(n, h("n"))), n;
429
+ var n = Qe();
430
+ return m(n, "pointerdown", h("n"), !0), c(() => f(n, w("n"))), n;
428
431
  })(), (() => {
429
- var n = Ke();
430
- return m(n, "pointerdown", f("s"), !0), u(() => c(n, h("s"))), n;
432
+ var n = et();
433
+ return m(n, "pointerdown", h("s"), !0), c(() => f(n, w("s"))), n;
431
434
  })(), s(P, {
432
435
  get when() {
433
436
  return !$();
434
437
  },
435
438
  get children() {
436
439
  return [(() => {
437
- var n = Qe();
438
- return m(n, "pointerdown", f("e"), !0), u(() => c(n, h("e"))), n;
439
- })(), (() => {
440
- var n = et();
441
- return m(n, "pointerdown", f("w"), !0), u(() => c(n, h("w"))), n;
442
- })(), (() => {
443
440
  var n = tt();
444
- return m(n, "pointerdown", f("ne"), !0), u(() => c(n, h("ne"))), n;
441
+ return m(n, "pointerdown", h("e"), !0), c(() => f(n, w("e"))), n;
445
442
  })(), (() => {
446
443
  var n = nt();
447
- return m(n, "pointerdown", f("nw"), !0), u(() => c(n, h("nw"))), n;
444
+ return m(n, "pointerdown", h("w"), !0), c(() => f(n, w("w"))), n;
448
445
  })(), (() => {
449
446
  var n = it();
450
- return m(n, "pointerdown", f("se"), !0), u(() => c(n, h("se"))), n;
447
+ return m(n, "pointerdown", h("ne"), !0), c(() => f(n, w("ne"))), n;
451
448
  })(), (() => {
452
449
  var n = ot();
453
- return m(n, "pointerdown", f("sw"), !0), u(() => c(n, h("sw"))), n;
450
+ return m(n, "pointerdown", h("nw"), !0), c(() => f(n, w("nw"))), n;
451
+ })(), (() => {
452
+ var n = rt();
453
+ return m(n, "pointerdown", h("se"), !0), c(() => f(n, w("se"))), n;
454
+ })(), (() => {
455
+ var n = lt();
456
+ return m(n, "pointerdown", h("sw"), !0), c(() => f(n, w("sw"))), n;
454
457
  })()];
455
458
  }
456
459
  })];
457
460
  }
458
- }), null), u(() => c(l, E("flex items-center justify-between h-9 px-3", "border-b", d() ? "rounded-none" : "rounded-t-md", B() && !d() && "cursor-move"))), e;
461
+ }), null), c(() => f(r, E("flex items-center justify-between h-9 px-3", "border-b", u() ? "rounded-none" : "rounded-t-md", B() && !u() && "cursor-move"))), e;
459
462
  }
460
463
  });
461
464
  }
@@ -463,5 +466,5 @@ function pt(i) {
463
466
  }
464
467
  ke(["pointerdown", "dblclick"]);
465
468
  export {
466
- pt as FloatingWindow
469
+ xt as FloatingWindow
467
470
  };
@@ -1,11 +1,11 @@
1
- import { createComponent as m, Portal as d, use as y, spread as S, mergeProps as P, insert as v, template as R } from "solid-js/web";
2
- import { splitProps as g, createMemo as i } from "solid-js";
3
- import { cn as h } from "../../utils/cn.js";
4
- import { LOCAL_INTERACTION_SURFACE_ATTR as z } from "./localInteractionSurface.js";
5
- import { clampMenuPosition as _ } from "./menuUtils.js";
6
- import { resolveSurfacePortalHost as x, resolveSurfacePortalMount as C, resolveSurfacePortalBoundaryRect as M, isSurfacePortalMode as $, projectSurfacePortalPosition as A } from "./dialogSurfaceScope.js";
7
- var T = /* @__PURE__ */ R("<div>");
8
- function b() {
1
+ import { createComponent as m, Portal as d, use as y, spread as S, mergeProps as P, insert as R, template as v } from "solid-js/web";
2
+ import { splitProps as _, createMemo as i } from "solid-js";
3
+ import { cn as g } from "../../utils/cn.js";
4
+ import { LOCAL_INTERACTION_SURFACE_ATTR as h } from "./localInteractionSurface.js";
5
+ import { clampMenuPosition as A } from "./menuUtils.js";
6
+ import { resolveSurfacePortalHost as T, SURFACE_FLOATING_LAYER_ATTR as z, resolveSurfacePortalMount as C, resolveSurfacePortalBoundaryRect as x, isSurfacePortalMode as L, projectSurfacePortalPosition as M } from "./dialogSurfaceScope.js";
7
+ var $ = /* @__PURE__ */ v("<div>");
8
+ function E() {
9
9
  return {
10
10
  left: 0,
11
11
  top: 0,
@@ -15,11 +15,11 @@ function b() {
15
15
  height: 0
16
16
  };
17
17
  }
18
- function I(n) {
19
- const [e, l] = g(n, ["position", "estimatedSize", "clamp", "class", "style", "children", "layerRef"]), o = i(() => x()), r = () => $(o()), c = () => M(o()) ?? b(), u = () => e.clamp !== !1 && !!e.estimatedSize, p = i(() => {
18
+ function j(n) {
19
+ const [e, l] = _(n, ["position", "estimatedSize", "clamp", "class", "style", "children", "layerRef"]), o = i(() => T()), r = () => L(o()), c = () => x(o()) ?? E(), u = () => e.clamp !== !1 && !!e.estimatedSize, p = i(() => {
20
20
  const t = e.position;
21
- return !u() || !e.estimatedSize ? t : _(t, e.estimatedSize, c());
22
- }), s = () => A(p(), o()), f = () => ({
21
+ return !u() || !e.estimatedSize ? t : A(t, e.estimatedSize, c());
22
+ }), s = () => M(p(), o()), f = () => ({
23
23
  ...e.style ?? {},
24
24
  left: `${s().x}px`,
25
25
  top: `${s().y}px`
@@ -29,20 +29,22 @@ function I(n) {
29
29
  return C(o());
30
30
  },
31
31
  get children() {
32
- var t = T(), a = e.layerRef;
32
+ var t = $(), a = e.layerRef;
33
33
  return typeof a == "function" ? y(a, t) : e.layerRef = t, S(t, P(l, {
34
34
  get class() {
35
- return h(r() ? "absolute z-20" : "fixed z-50", e.class);
35
+ return g(r() ? "absolute z-20" : "fixed z-50", e.class);
36
36
  },
37
37
  get style() {
38
38
  return f();
39
39
  }
40
+ }, {
41
+ [z]: "true"
40
42
  }, () => ({
41
- [z]: r() ? "true" : void 0
42
- })), !1, !0), v(t, () => e.children), t;
43
+ [h]: r() ? "true" : void 0
44
+ })), !1, !0), R(t, () => e.children), t;
43
45
  }
44
46
  });
45
47
  }
46
48
  export {
47
- I as SurfaceFloatingLayer
49
+ j as SurfaceFloatingLayer
48
50
  };
@@ -2,6 +2,7 @@ import type { SurfacePortalRect } from './surfacePortalTypes';
2
2
  export declare const DIALOG_SURFACE_HOST_ATTR = "data-floe-dialog-surface-host";
3
3
  export declare const SURFACE_PORTAL_HOST_ATTR = "data-floe-dialog-surface-host";
4
4
  export declare const SURFACE_PORTAL_LAYER_ATTR = "data-floe-surface-portal-layer";
5
+ export declare const SURFACE_FLOATING_LAYER_ATTR = "data-floe-surface-floating-layer";
5
6
  export declare const DIALOG_SURFACE_BOUNDARY_ATTR = "data-floe-dialog-surface-boundary";
6
7
  export type DialogSurfaceInteractionSnapshot = Readonly<{
7
8
  target: Element | null;
@@ -1,9 +1,9 @@
1
- const a = "data-floe-dialog-surface-host", y = a, p = "data-floe-surface-portal-layer", A = "data-floe-dialog-surface-boundary", g = 1600;
1
+ const d = "data-floe-dialog-surface-host", y = d, p = "data-floe-surface-portal-layer", v = "data-floe-surface-floating-layer", _ = "data-floe-dialog-surface-boundary", g = 1600;
2
2
  let r = null, o = null;
3
3
  function E(t) {
4
4
  return typeof Element < "u" && t instanceof Element ? t : typeof Node < "u" && t instanceof Node ? t.parentElement : null;
5
5
  }
6
- function w(t) {
6
+ function T(t) {
7
7
  const e = t?.activeElement;
8
8
  return e instanceof Element ? e : null;
9
9
  }
@@ -11,7 +11,7 @@ function l(t) {
11
11
  const e = typeof document < "u" ? document : null;
12
12
  r = {
13
13
  target: E(t),
14
- activeElement: w(e),
14
+ activeElement: T(e),
15
15
  recordedAt: Date.now()
16
16
  };
17
17
  }
@@ -21,41 +21,41 @@ function c(t) {
21
21
  function f(t) {
22
22
  l(t.target);
23
23
  }
24
- function d(t) {
24
+ function a(t) {
25
25
  l(t.target);
26
26
  }
27
27
  function s() {
28
- T();
29
- }
30
- function T() {
31
- typeof document > "u" || o !== document && (o && (o.removeEventListener("pointerdown", c, !0), o.removeEventListener("focusin", f, !0), o.removeEventListener("contextmenu", d, !0)), document.addEventListener("pointerdown", c, !0), document.addEventListener("focusin", f, !0), document.addEventListener("contextmenu", d, !0), o = document);
28
+ R();
32
29
  }
33
30
  function R() {
31
+ typeof document > "u" || o !== document && (o && (o.removeEventListener("pointerdown", c, !0), o.removeEventListener("focusin", f, !0), o.removeEventListener("contextmenu", a, !0)), document.addEventListener("pointerdown", c, !0), document.addEventListener("focusin", f, !0), document.addEventListener("contextmenu", a, !0), o = document);
32
+ }
33
+ function w() {
34
34
  return !r || Date.now() - r.recordedAt > g ? null : r;
35
35
  }
36
36
  function i(t) {
37
- const e = t?.closest(`[${a}="true"]`);
37
+ const e = t?.closest(`[${d}="true"]`);
38
38
  return typeof HTMLElement > "u" ? null : e instanceof HTMLElement ? e : null;
39
39
  }
40
- function S(t) {
40
+ function A(t) {
41
41
  if (!t) return null;
42
42
  const e = t.closest(`[${p}="true"]`);
43
43
  return typeof HTMLElement > "u" ? null : e instanceof HTMLElement ? e : null;
44
44
  }
45
45
  function L(t = {}) {
46
46
  s();
47
- const e = R(), n = i(t.owner ?? null) ?? i(e?.target ?? null) ?? i(e?.activeElement ?? null);
47
+ const e = w(), n = i(t.owner ?? null) ?? i(e?.target ?? null) ?? i(e?.activeElement ?? null);
48
48
  return n ? {
49
49
  host: n,
50
50
  boundaryHost: n,
51
- mountHost: S(n) ?? n,
51
+ mountHost: A(n) ?? n,
52
52
  mode: "surface"
53
53
  } : { host: null, boundaryHost: null, mountHost: null, mode: "global" };
54
54
  }
55
55
  function u(t) {
56
56
  return t.mode === "surface" && !!t.boundaryHost?.isConnected;
57
57
  }
58
- function v(t) {
58
+ function S(t) {
59
59
  if (u(t))
60
60
  return t.mountHost ?? t.boundaryHost ?? void 0;
61
61
  }
@@ -76,7 +76,7 @@ function m() {
76
76
  height: window.innerHeight
77
77
  };
78
78
  }
79
- function _(t) {
79
+ function b(t) {
80
80
  if (!u(t) || !t.boundaryHost)
81
81
  return m();
82
82
  const e = t.boundaryHost.getBoundingClientRect();
@@ -90,7 +90,7 @@ function _(t) {
90
90
  };
91
91
  }
92
92
  function h(t) {
93
- const e = v(t);
93
+ const e = S(t);
94
94
  if (!e)
95
95
  return m();
96
96
  const n = e.getBoundingClientRect();
@@ -103,7 +103,7 @@ function h(t) {
103
103
  height: n.height
104
104
  };
105
105
  }
106
- function b(t, e) {
106
+ function P(t, e) {
107
107
  if (!u(e))
108
108
  return t;
109
109
  const n = h(e);
@@ -112,7 +112,7 @@ function b(t, e) {
112
112
  y: t.y - n.top
113
113
  };
114
114
  }
115
- function P(t, e) {
115
+ function C(t, e) {
116
116
  if (!u(e))
117
117
  return t;
118
118
  const n = h(e);
@@ -125,23 +125,24 @@ function P(t, e) {
125
125
  height: t.height
126
126
  };
127
127
  }
128
- function C() {
128
+ function H() {
129
129
  r = null;
130
130
  }
131
131
  typeof document < "u" && s();
132
132
  export {
133
- A as DIALOG_SURFACE_BOUNDARY_ATTR,
134
- a as DIALOG_SURFACE_HOST_ATTR,
133
+ _ as DIALOG_SURFACE_BOUNDARY_ATTR,
134
+ d as DIALOG_SURFACE_HOST_ATTR,
135
+ v as SURFACE_FLOATING_LAYER_ATTR,
135
136
  y as SURFACE_PORTAL_HOST_ATTR,
136
137
  p as SURFACE_PORTAL_LAYER_ATTR,
137
- C as __resetSurfacePortalScopeForTests,
138
+ H as __resetSurfacePortalScopeForTests,
138
139
  s as ensureDialogSurfaceInteractionTracking,
139
- T as ensureSurfacePortalInteractionTracking,
140
+ R as ensureSurfacePortalInteractionTracking,
140
141
  u as isSurfacePortalMode,
141
- b as projectSurfacePortalPosition,
142
- P as projectSurfacePortalRect,
143
- _ as resolveSurfacePortalBoundaryRect,
142
+ P as projectSurfacePortalPosition,
143
+ C as projectSurfacePortalRect,
144
+ b as resolveSurfacePortalBoundaryRect,
144
145
  L as resolveSurfacePortalHost,
145
- v as resolveSurfacePortalMount,
146
+ S as resolveSurfacePortalMount,
146
147
  h as resolveSurfacePortalMountRect
147
148
  };
@@ -4,7 +4,7 @@ export { Input, Textarea, NumberInput, AffixInput, type InputProps, type InputSi
4
4
  export { Dialog, ConfirmDialog, type DialogProps, type ConfirmDialogProps } from './Dialog';
5
5
  export { FloatingWindow, type FloatingWindowProps } from './FloatingWindow';
6
6
  export { createFloatingPresence, type FloatingPresence, type FloatingPresenceOptions, type FloatingPresenceState, } from './floatingPresence';
7
- export { MENU_ITEM_SELECTOR, focusMenuItem, getMenuItems, handleMenuKeyboardNavigation, moveMenuFocus, type MenuDismissReason, type MenuFocusMode, type MenuKeyboardNavigationOptions, } from './menuUtils';
7
+ export { MENU_ITEM_SELECTOR, focusMenuItem, getMenuItems, handleMenuKeyboardNavigation, moveMenuFocus, type MenuDismissReason, type MenuFocusMode, type MenuItemNavigationOptions, type MenuKeyboardNavigationOptions, } from './menuUtils';
8
8
  export { resolveFloatingWindowViewport, type FloatingWindowRect, type FloatingWindowViewport, type FloatingWindowViewportInsets, } from './floatingWindowGeometry';
9
9
  export { Dropdown, Select, type DropdownProps, type DropdownItem, type SelectProps, } from './Dropdown';
10
10
  export { SurfaceFloatingLayer, type SurfaceFloatingLayerPosition, type SurfaceFloatingLayerProps, type SurfaceFloatingLayerSize, } from './SurfaceFloatingLayer';
@@ -10,8 +10,13 @@ export type MenuBoundaryRect = Readonly<{
10
10
  }>;
11
11
  export type MenuFocusMode = 'first' | 'last' | 'selected';
12
12
  export type MenuDismissReason = 'escape' | 'tab' | 'shift-tab';
13
- export type MenuKeyboardNavigationOptions = Readonly<{
13
+ export type MenuItemNavigationOptions = Readonly<{
14
+ includeAriaDisabledItems?: boolean;
15
+ }>;
16
+ export type MenuKeyboardNavigationOptions = MenuItemNavigationOptions & Readonly<{
14
17
  onDismiss: (reason: MenuDismissReason) => void;
18
+ onActivate?: (item: HTMLElement) => void;
19
+ preventDefaultOnTab?: boolean;
15
20
  }>;
16
21
  export declare function resolveViewportMenuBoundaryRect(): MenuBoundaryRect;
17
22
  export declare function clampMenuPosition(anchor: Readonly<{
@@ -33,7 +38,7 @@ export declare function calculateSubmenuPosition(parentRect: DOMRect, submenuRec
33
38
  y: number;
34
39
  };
35
40
  export declare function getWrappedMenuItemIndex(length: number, currentIndex: number, delta: 1 | -1): number | null;
36
- export declare function getMenuItems(root: ParentNode | null | undefined): HTMLElement[];
37
- export declare function focusMenuItem(root: ParentNode | null | undefined, mode?: MenuFocusMode): boolean;
38
- export declare function moveMenuFocus(root: ParentNode | null | undefined, current: HTMLElement | null, delta: 1 | -1): boolean;
41
+ export declare function getMenuItems(root: ParentNode | null | undefined, options?: MenuItemNavigationOptions): HTMLElement[];
42
+ export declare function focusMenuItem(root: ParentNode | null | undefined, mode?: MenuFocusMode, options?: MenuItemNavigationOptions): boolean;
43
+ export declare function moveMenuFocus(root: ParentNode | null | undefined, current: HTMLElement | null, delta: 1 | -1, options?: MenuItemNavigationOptions): boolean;
39
44
  export declare function handleMenuKeyboardNavigation(event: KeyboardEvent, options: MenuKeyboardNavigationOptions): boolean;
@@ -1,5 +1,5 @@
1
- const E = 8, h = '[role="menuitem"]:not([disabled]):not([aria-disabled="true"])';
2
- function M() {
1
+ const E = 8, I = '[role="menuitem"]:not([disabled]):not([aria-disabled="true"])';
2
+ function c() {
3
3
  return typeof window > "u" ? {
4
4
  left: 0,
5
5
  top: 0,
@@ -16,97 +16,102 @@ function M() {
16
16
  height: window.innerHeight
17
17
  };
18
18
  }
19
- function f(t) {
20
- return t ?? M();
19
+ function l(t) {
20
+ return t ?? c();
21
21
  }
22
- function w(t, e, r) {
23
- const n = f(r);
24
- let o = t.x, i = t.y;
25
- return o + e.width > n.right - 8 && (o = n.right - e.width - 8), i + e.height > n.bottom - 8 && (i = n.bottom - e.height - 8), {
26
- x: Math.max(n.left + 8, o),
27
- y: Math.max(n.top + 8, i)
22
+ function A(t, e, a) {
23
+ const n = l(a);
24
+ let i = t.x, r = t.y;
25
+ return i + e.width > n.right - 8 && (i = n.right - e.width - 8), r + e.height > n.bottom - 8 && (r = n.bottom - e.height - 8), {
26
+ x: Math.max(n.left + 8, i),
27
+ y: Math.max(n.top + 8, r)
28
28
  };
29
29
  }
30
- function T(t, e, r, n) {
31
- const o = f(n);
32
- let i;
33
- switch (r) {
30
+ function T(t, e, a, n) {
31
+ const i = l(n);
32
+ let r;
33
+ switch (a) {
34
34
  case "center":
35
- i = t.left + t.width / 2 - e.width / 2;
35
+ r = t.left + t.width / 2 - e.width / 2;
36
36
  break;
37
37
  case "end":
38
- i = t.right - e.width;
38
+ r = t.right - e.width;
39
39
  break;
40
40
  default:
41
- i = t.left;
41
+ r = t.left;
42
42
  }
43
- let a = t.bottom + 4;
44
- if (i + e.width > o.right - 8 && (i = o.right - e.width - 8), i = Math.max(o.left + 8, i), a + e.height > o.bottom - 8) {
45
- const s = t.top - o.top - 8, d = o.bottom - t.bottom - 8;
46
- s > d && s >= e.height ? a = t.top - e.height - 4 : a = o.bottom - e.height - 8;
43
+ let o = t.bottom + 4;
44
+ if (r + e.width > i.right - 8 && (r = i.right - e.width - 8), r = Math.max(i.left + 8, r), o + e.height > i.bottom - 8) {
45
+ const f = t.top - i.top - 8, d = i.bottom - t.bottom - 8;
46
+ f > d && f >= e.height ? o = t.top - e.height - 4 : o = i.bottom - e.height - 8;
47
47
  }
48
- return a = Math.max(o.top + 8, a), { x: i, y: a };
48
+ return o = Math.max(i.top + 8, o), { x: r, y: o };
49
49
  }
50
- function A(t, e, r) {
51
- const n = f(r);
52
- let o = t.right, i = t.top;
53
- if (o + e.width > n.right - 8) {
54
- const a = t.left - e.width;
55
- a >= n.left + 8 ? o = a : o = n.right - e.width - 8;
50
+ function m(t, e, a) {
51
+ const n = l(a);
52
+ let i = t.right, r = t.top;
53
+ if (i + e.width > n.right - 8) {
54
+ const o = t.left - e.width;
55
+ o >= n.left + 8 ? i = o : i = n.right - e.width - 8;
56
56
  }
57
- return i + e.height > n.bottom - 8 && (i = n.bottom - e.height - 8), o = Math.max(n.left + 8, o), i = Math.max(n.top + 8, i), { x: o, y: i };
57
+ return r + e.height > n.bottom - 8 && (r = n.bottom - e.height - 8), i = Math.max(n.left + 8, i), r = Math.max(n.top + 8, r), { x: i, y: r };
58
58
  }
59
- function c(t, e, r) {
60
- return t <= 0 ? null : e < 0 ? r > 0 ? 0 : t - 1 : (e + r + t) % t;
59
+ function M(t, e, a) {
60
+ return t <= 0 ? null : e < 0 ? a > 0 ? 0 : t - 1 : (e + a + t) % t;
61
61
  }
62
- function I(t) {
63
- return !t || typeof HTMLElement > "u" ? [] : Array.from(t.querySelectorAll(h)).filter(
64
- (e) => e instanceof HTMLElement
62
+ function u(t, e = {}) {
63
+ if (!t || typeof HTMLElement > "u") return [];
64
+ const a = e.includeAriaDisabledItems ? '[role="menuitem"]:not([disabled])' : I;
65
+ return Array.from(t.querySelectorAll(a)).filter(
66
+ (n) => n instanceof HTMLElement
65
67
  );
66
68
  }
67
- function l(t, e = "first") {
68
- const r = I(t);
69
- if (!r.length) return !1;
70
- let n = r[0];
71
- return e === "last" ? n = r[r.length - 1] : e === "selected" && (n = r.find((o) => o.getAttribute("data-floe-selected") === "true") ?? r[0]), n.focus(), !0;
72
- }
73
- function u(t, e, r) {
74
- const n = I(t);
69
+ function s(t, e = "first", a = {}) {
70
+ const n = u(t, a);
75
71
  if (!n.length) return !1;
76
- const o = e ? n.indexOf(e) : -1, i = c(n.length, o, r);
77
- return i === null ? !1 : (n[i]?.focus(), !0);
72
+ let i = n[0];
73
+ return e === "last" ? i = n[n.length - 1] : e === "selected" && (i = n.find((r) => r.getAttribute("data-floe-selected") === "true") ?? n[0]), i.focus(), !0;
74
+ }
75
+ function h(t, e, a, n = {}) {
76
+ const i = u(t, n);
77
+ if (!i.length) return !1;
78
+ const r = e ? i.indexOf(e) : -1, o = M(i.length, r, a);
79
+ return o === null ? !1 : (i[o]?.focus(), !0);
78
80
  }
79
- function P(t, e) {
80
- const r = typeof HTMLElement < "u" && t.target instanceof HTMLElement ? t.target : null, n = r?.closest('[role="menu"]');
81
+ function w(t, e) {
82
+ const a = typeof HTMLElement < "u" && t.target instanceof HTMLElement ? t.target : null, n = a?.closest('[role="menu"]');
81
83
  if (!n) return !1;
82
- const o = r?.closest(h);
84
+ const i = u(n, e), r = a?.closest('[role="menuitem"]'), o = r && i.includes(r) ? r : null;
83
85
  switch (t.key) {
84
86
  case "ArrowDown":
85
- return t.preventDefault(), u(n, o, 1), !0;
87
+ return t.preventDefault(), h(n, o, 1, e), !0;
86
88
  case "ArrowUp":
87
- return t.preventDefault(), u(n, o, -1), !0;
89
+ return t.preventDefault(), h(n, o, -1, e), !0;
88
90
  case "Home":
89
- return t.preventDefault(), l(n, "first"), !0;
91
+ return t.preventDefault(), s(n, "first", e), !0;
90
92
  case "End":
91
- return t.preventDefault(), l(n, "last"), !0;
93
+ return t.preventDefault(), s(n, "last", e), !0;
94
+ case "Enter":
95
+ case " ":
96
+ return o ? o.getAttribute("aria-disabled") === "true" ? (t.preventDefault(), !0) : e.onActivate ? (t.preventDefault(), e.onActivate(o), !0) : !1 : !1;
92
97
  case "Escape":
93
98
  return t.preventDefault(), t.stopPropagation(), e.onDismiss("escape"), !0;
94
99
  case "Tab":
95
- return e.onDismiss(t.shiftKey ? "shift-tab" : "tab"), !0;
100
+ return e.preventDefaultOnTab && t.preventDefault(), e.onDismiss(t.shiftKey ? "shift-tab" : "tab"), !0;
96
101
  default:
97
102
  return !1;
98
103
  }
99
104
  }
100
105
  export {
101
- h as MENU_ITEM_SELECTOR,
106
+ I as MENU_ITEM_SELECTOR,
102
107
  E as VIEWPORT_MARGIN,
103
108
  T as calculateMenuPosition,
104
- A as calculateSubmenuPosition,
105
- w as clampMenuPosition,
106
- l as focusMenuItem,
107
- I as getMenuItems,
108
- c as getWrappedMenuItemIndex,
109
- P as handleMenuKeyboardNavigation,
110
- u as moveMenuFocus,
111
- M as resolveViewportMenuBoundaryRect
109
+ m as calculateSubmenuPosition,
110
+ A as clampMenuPosition,
111
+ s as focusMenuItem,
112
+ u as getMenuItems,
113
+ M as getWrappedMenuItemIndex,
114
+ w as handleMenuKeyboardNavigation,
115
+ h as moveMenuFocus,
116
+ c as resolveViewportMenuBoundaryRect
112
117
  };
@@ -1 +1 @@
1
- export { DIALOG_SURFACE_HOST_ATTR, SURFACE_PORTAL_HOST_ATTR, SURFACE_PORTAL_LAYER_ATTR, DIALOG_SURFACE_BOUNDARY_ATTR, ensureSurfacePortalInteractionTracking, resolveSurfacePortalHost, isSurfacePortalMode, resolveSurfacePortalMount, resolveSurfacePortalBoundaryRect, resolveSurfacePortalMountRect, projectSurfacePortalPosition, projectSurfacePortalRect, __resetSurfacePortalScopeForTests, type SurfacePortalInteractionSnapshot, type SurfacePortalHostResolutionOptions, type SurfacePortalMode, type ResolvedSurfacePortalHost, type SurfacePortalBoundaryRect, type SurfacePortalRect, } from './dialogSurfaceScope';
1
+ export { DIALOG_SURFACE_HOST_ATTR, SURFACE_PORTAL_HOST_ATTR, SURFACE_PORTAL_LAYER_ATTR, SURFACE_FLOATING_LAYER_ATTR, DIALOG_SURFACE_BOUNDARY_ATTR, ensureSurfacePortalInteractionTracking, resolveSurfacePortalHost, isSurfacePortalMode, resolveSurfacePortalMount, resolveSurfacePortalBoundaryRect, resolveSurfacePortalMountRect, projectSurfacePortalPosition, projectSurfacePortalRect, __resetSurfacePortalScopeForTests, type SurfacePortalInteractionSnapshot, type SurfacePortalHostResolutionOptions, type SurfacePortalMode, type ResolvedSurfacePortalHost, type SurfacePortalBoundaryRect, type SurfacePortalRect, } from './dialogSurfaceScope';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@floegence/floe-webapp-core",
3
- "version": "0.39.3",
3
+ "version": "0.39.5",
4
4
  "type": "module",
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/index.js",