@floegence/floe-webapp-core 0.36.60 → 0.36.62

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,5 +1,5 @@
1
- import { use as z, spread as V, mergeProps as H, insert as f, createComponent as s, Portal as $, addEventListener as U, template as T, delegateEvents as K } from "solid-js/web";
2
- import { createSignal as A, createMemo as g, untrack as h, createEffect as v, onCleanup as y, Show as j } from "solid-js";
1
+ import { use as V, spread as z, mergeProps as H, insert as f, createComponent as s, Portal as $, addEventListener as U, template as T, delegateEvents as K } from "solid-js/web";
2
+ import { createSignal as p, createMemo as g, untrack as C, createEffect as v, onCleanup as y, Show as j } from "solid-js";
3
3
  import { clientToCanvasWorld as L } from "../ui/canvasGeometry.js";
4
4
  import { WorkbenchCanvas as Z } from "./WorkbenchCanvas.js";
5
5
  import { WorkbenchContextMenu as G } from "./WorkbenchContextMenu.js";
@@ -32,7 +32,7 @@ function Ie(a) {
32
32
  backgroundLayerDefaults: () => a.backgroundLayerDefaults,
33
33
  onClose: () => {
34
34
  }
35
- }), [u, N] = A(null), [R, O] = A(null), d = g(() => de(a.interactionAdapter)), [C, l] = A(h(() => d().createInitialInputOwner())), W = g(() => {
35
+ }), [u, N] = p(null), [O, R] = p(null), d = g(() => de(a.interactionAdapter)), [h, l] = p(C(() => d().createInitialInputOwner())), W = g(() => {
36
36
  const e = a.launcherWidgetTypes;
37
37
  return !e || e.length <= 0 ? null : new Set(e);
38
38
  }), E = g(() => {
@@ -96,7 +96,7 @@ function Ie(a) {
96
96
  worldY: i > 0 ? (i / 2 - n.y) / n.scale : 180
97
97
  };
98
98
  }, w = (e) => {
99
- const n = h(d), o = h(u);
99
+ const n = C(d), o = C(u);
100
100
  queueMicrotask(() => {
101
101
  n.focusWidgetElement(o, e), l(n.createWidgetInputOwner(e, "activation"));
102
102
  });
@@ -173,7 +173,7 @@ function Ie(a) {
173
173
  });
174
174
  y(() => e());
175
175
  }), v(() => {
176
- const e = C();
176
+ const e = h();
177
177
  if (e.kind !== "widget") return;
178
178
  t.widgets().some((o) => o.id === e.widgetId) || l(d().createCanvasInputOwner("widget_removed"));
179
179
  }), v(() => {
@@ -198,7 +198,7 @@ function Ie(a) {
198
198
  if (!d().shouldBypassGlobalHotkeys({
199
199
  root: u(),
200
200
  target: o.target,
201
- owner: C(),
201
+ owner: h(),
202
202
  interactiveSelector: d().interactiveSelector
203
203
  }))
204
204
  switch (o.key) {
@@ -223,7 +223,7 @@ function Ie(a) {
223
223
  };
224
224
  document.addEventListener("keydown", n, !0), y(() => document.removeEventListener("keydown", n, !0));
225
225
  });
226
- const p = (e, n, o) => {
226
+ const A = (e, n, o) => {
227
227
  if (o?.canvasFrame)
228
228
  return L(o.canvasFrame, t.viewport(), {
229
229
  clientX: e,
@@ -237,10 +237,10 @@ function Ie(a) {
237
237
  clientY: n
238
238
  });
239
239
  }, _ = (e, n, o, r) => {
240
- const i = p(n, o, r);
240
+ const i = A(n, o, r);
241
241
  i && t.widgetActions.addWidgetAtWorldCenter(e, i.worldX, i.worldY);
242
242
  }, Y = (e, n, o, r) => {
243
- const i = p(n, o, r);
243
+ const i = A(n, o, r);
244
244
  if (i) {
245
245
  if (e === "sticky-note") {
246
246
  t.widgetActions.addStickyNoteAtCursor(i.worldX, i.worldY);
@@ -255,9 +255,9 @@ function Ie(a) {
255
255
  }, P = (e) => {
256
256
  e.button === 0 && x("background_pointer");
257
257
  }, q = g(() => {
258
- const e = R();
258
+ const e = O();
259
259
  if (!e) return null;
260
- const n = p(e.clientX, e.clientY, e);
260
+ const n = A(e.clientX, e.clientY, e);
261
261
  return n ? e.kind === "widget" ? ie({
262
262
  type: e.id,
263
263
  widgetDefinitions: t.widgetDefinitions(),
@@ -276,7 +276,7 @@ function Ie(a) {
276
276
  });
277
277
  return (() => {
278
278
  var e = se(), n = e.firstChild;
279
- return z(N, e), V(e, H({
279
+ return V(N, e), z(e, H({
280
280
  get class() {
281
281
  return `workbench-surface${a.class ? ` ${a.class}` : ""}`;
282
282
  }
@@ -324,8 +324,8 @@ function Ie(a) {
324
324
  get mode() {
325
325
  return t.mode();
326
326
  },
327
- get optimisticFrontWidgetId() {
328
- return t.optimisticFrontWidgetId();
327
+ get visualFrontOwnerId() {
328
+ return t.visualFrontOwnerId();
329
329
  },
330
330
  get locked() {
331
331
  return t.locked();
@@ -355,8 +355,8 @@ function Ie(a) {
355
355
  get onWidgetContextMenu() {
356
356
  return t.canvas.openWidgetContextMenu;
357
357
  },
358
- get onStartOptimisticFront() {
359
- return t.canvas.startOptimisticFront;
358
+ get onClaimVisualFrontOwner() {
359
+ return t.canvas.claimVisualFrontOwner;
360
360
  },
361
361
  get onCommitFront() {
362
362
  return t.canvas.commitFront;
@@ -373,8 +373,8 @@ function Ie(a) {
373
373
  get onStickyNoteContextMenu() {
374
374
  return t.canvas.openStickyNoteContextMenu;
375
375
  },
376
- get onStartStickyOptimisticFront() {
377
- return t.canvas.startOptimisticFront;
376
+ get onClaimStickyVisualFrontOwner() {
377
+ return t.canvas.claimVisualFrontOwner;
378
378
  },
379
379
  get onCommitStickyFront() {
380
380
  return t.canvas.commitStickyFront;
@@ -476,7 +476,7 @@ function Ie(a) {
476
476
  onViewportInteractionStart: () => t.canvas.cancelViewportNavigation(),
477
477
  onCreateAt: _,
478
478
  onCreateToolAt: Y,
479
- onDragPreviewChange: O
479
+ onDragPreviewChange: R
480
480
  }), null), f(e, s(Q, {
481
481
  get scaleLabel() {
482
482
  return t.scaleLabel();
@@ -13,7 +13,7 @@ export interface WorkbenchWidgetProps {
13
13
  renderLayer: number;
14
14
  itemSnapshot: () => WorkbenchWidgetItem;
15
15
  selected: boolean;
16
- optimisticFront: boolean;
16
+ visualFront: boolean;
17
17
  motion?: WorkbenchWidgetMotionIntent | null;
18
18
  topRenderLayer: number;
19
19
  viewportScale: number;
@@ -26,7 +26,7 @@ export interface WorkbenchWidgetProps {
26
26
  viewport?: WorkbenchViewport;
27
27
  onSelect: (widgetId: string) => void;
28
28
  onContextMenu: (event: MouseEvent, item: WorkbenchWidgetItem) => void;
29
- onStartOptimisticFront: (widgetId: string) => void;
29
+ onClaimVisualFrontOwner: (widgetId: string) => void;
30
30
  onCommitFront: (widgetId: string) => void;
31
31
  onCommitMove: (widgetId: string, position: {
32
32
  x: number;