@floegence/floe-webapp-core 0.81.3 → 0.81.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.
package/dist/icons.js CHANGED
@@ -1,8 +1,10 @@
1
- import { Activity as n, ActivityIcon as c, AlertCircle as r, AlertTriangle as a, ArchiveIcon as I, ArrowDown as i, ArrowLeft as l, ArrowRight as t, ArrowRightLeft as s, ArrowUp as C, AtSign as d, AwardIcon as h, BarChart as k, BatteryIcon as p, Bell as u, BellIcon as g, Bookmark as D, BookmarkIcon as S, Bot as P, BotIcon as f, BugIcon as m, Calendar as y, CalendarIcon as M, Camera as T, CameraIcon as w, ChartIcon as F, Check as L, CheckCircle as A, CheckIcon as B, ChevronDown as v, ChevronLeft as H, ChevronRight as U, ChevronUp as b, ChevronsUpDown as G, CircleStop as R, Clock as x, ClockIcon as V, CloseIcon as E, Cloud as O, CloudIcon as W, Code as q, CodeIcon as z, CompassIcon as K, Copy as X, CopyCheck as Z, CopyCheckIcon as Q, CopyIcon as j, Cpu as J, CreditCardIcon as N, Database as Y, DatabaseIcon as _, DollarIcon as $, Download as oo, DownloadIcon as eo, EditIcon as no, ErrorIcon as co, ExternalLink as ro, Eye as ao, EyeIcon as Io, EyeOff as io, FileCode as lo, FilePlus as to, FilePlusIcon as so, FileText as Co, Files as ho, Filter as ko, FilterIcon as po, FireIcon as uo, Folder as go, FolderOpen as Do, FolderPlus as So, FolderPlusIcon as Po, GiftIcon as fo, GitBranch as mo, GitBranchIcon as yo, Globe as Mo, GlobeIcon as To, Grid as wo, Grid3x3 as Fo, GripVertical as Lo, Hash as Ao, HeadphonesIcon as Bo, Heart as vo, HeartIcon as Ho, HelpIcon as Uo, Highlighter as bo, History as Go, Home as Ro, HomeIcon as xo, Image as Vo, ImageIcon as Eo, Info as Oo, InfoIcon as Wo, Key as qo, KeyIcon as zo, Layers as Ko, LayersIcon as Xo, LayoutDashboard as Zo, Link as Qo, LinkIcon as jo, Loader2 as Jo, LoadingIcon as No, Lock as Yo, LockIcon as _o, MagicIcon as $o, Mail as oe, MailIcon as ee, MapPinIcon as ne, Maximize as ce, Menu as re, MessageIcon as ae, MessageSquare as Ie, Mic as ie, MicIcon as le, MicOff as te, Minus as se, MinusIcon as Ce, MonitorPointer as de, Moon as he, MoonIcon as ke, MoreHorizontal as pe, MoreVertical as ue, MuteIcon as ge, Package as De, PackageIcon as Se, Paperclip as Pe, Paste as fe, PasteIcon as me, Pause as ye, PauseIcon as Me, Pencil as Te, Phone as we, PieChart as Fe, Pin as Le, PinIcon as Ae, Play as Be, PlayIcon as ve, Plus as He, PlusIcon as Ue, PowerIcon as be, PrinterIcon as Ge, Quote as Re, Refresh as xe, RefreshIcon as Ve, Region as Ee, Restore as Oe, RocketIcon as We, Save as qe, SaveIcon as ze, Search as Ke, SearchIcon as Xe, Send as Ze, SendIcon as Qe, Settings as je, SettingsIcon as Je, ShareIcon as Ne, Shield as Ye, ShieldCheck as _e, ShieldIcon as $e, SparkleIcon as on, Sparkles as en, Star as nn, StarIcon as cn, Stop as rn, StopFilled as an, SuccessIcon as In, Sun as ln, SunIcon as tn, Tag as sn, TagIcon as Cn, TargetIcon as dn, Terminal as hn, TerminalIcon as kn, TextTool as pn, ThumbsDownIcon as un, ThumbsUpIcon as gn, Timer as Dn, Trash as Sn, TrashIcon as Pn, TrendingDown as fn, TrendingUp as mn, Unlock as yn, Upload as Mn, UploadIcon as Tn, User as wn, UserIcon as Fn, Video as Ln, VideoIcon as An, Volume as Bn, VolumeIcon as vn, VolumeOff as Hn, Wand as Un, WarningIcon as bn, WifiIcon as Gn, WifiOffIcon as Rn, Workflow as xn, X as Vn, XCircle as En, Zap as On, ZapIcon as Wn } from "./components/icons/index.js";
2
- import { DockActivity as zn, DockBot as Kn, DockCode as Xn, DockCpu as Zn, DockFileCode as Qn, DockFolder as jn, DockGlobe as Jn, DockLayers as Nn, DockLayoutDashboard as Yn, DockMessageSquare as _n, DockRegion as $n, DockSearch as oc, DockSparkles as ec, DockTerminal as nc, DockText as cc } from "./components/icons/DockIcons.js";
1
+ import { Activity as n, ActivityIcon as c, AlertCircle as r, AlertTriangle as a, ArchiveIcon as I, ArrowDown as i, ArrowLeft as l, ArrowRight as t, ArrowRightLeft as s, ArrowUp as d, AtSign as C, AwardIcon as h, BarChart as k, BatteryIcon as p, Bell as u, BellIcon as S, Bookmark as g, BookmarkIcon as D, Bot as P, BotIcon as f, BugIcon as m, Calendar as y, CalendarIcon as M, Camera as T, CameraIcon as F, ChartIcon as w, Check as L, CheckCircle as A, CheckIcon as B, ChevronDown as b, ChevronLeft as v, ChevronRight as H, ChevronUp as U, ChevronsUpDown as x, CircleStop as G, Clock as R, ClockIcon as E, CloseIcon as V, Cloud as O, CloudIcon as W, Code as z, CodeIcon as K, CompassIcon as q, Copy as X, CopyCheck as Z, CopyCheckIcon as Q, CopyIcon as j, Cpu as J, CreditCardIcon as N, Database as Y, DatabaseIcon as _, DollarIcon as $, Download as oo, DownloadIcon as eo, EditIcon as no, ErrorIcon as co, ExternalLink as ro, Eye as ao, EyeIcon as Io, EyeOff as io, FileCode as lo, FilePlus as to, FilePlusIcon as so, FileText as Co, Files as ho, Filter as ko, FilterIcon as po, FireIcon as uo, Folder as So, FolderOpen as go, FolderPlus as Do, FolderPlusIcon as Po, GiftIcon as fo, GitBranch as mo, GitBranchIcon as yo, Globe as Mo, GlobeIcon as To, Grid as Fo, Grid3x3 as wo, GripVertical as Lo, Hash as Ao, HeadphonesIcon as Bo, Heart as bo, HeartIcon as vo, HelpIcon as Ho, Highlighter as Uo, History as xo, Home as Go, HomeIcon as Ro, Image as Eo, ImageIcon as Vo, Info as Oo, InfoIcon as Wo, Key as zo, KeyIcon as Ko, Layers as qo, LayersIcon as Xo, LayoutDashboard as Zo, Link as Qo, LinkIcon as jo, Loader2 as Jo, LoadingIcon as No, Lock as Yo, LockIcon as _o, MagicIcon as $o, Mail as oe, MailIcon as ee, MapPinIcon as ne, Maximize as ce, Menu as re, MessageIcon as ae, MessageSquare as Ie, Mic as ie, MicIcon as le, MicOff as te, Minus as se, MinusIcon as de, MonitorPointer as Ce, Moon as he, MoonIcon as ke, MoreHorizontal as pe, MoreVertical as ue, MuteIcon as Se, Package as ge, PackageIcon as De, Paperclip as Pe, Paste as fe, PasteIcon as me, Pause as ye, PauseIcon as Me, Pencil as Te, Phone as Fe, PieChart as we, Pin as Le, PinIcon as Ae, Play as Be, PlayIcon as be, Plus as ve, PlusIcon as He, PowerIcon as Ue, PrinterIcon as xe, Quote as Ge, Refresh as Re, RefreshIcon as Ee, Region as Ve, Restore as Oe, RocketIcon as We, Save as ze, SaveIcon as Ke, Search as qe, SearchIcon as Xe, Send as Ze, SendIcon as Qe, Settings as je, SettingsIcon as Je, ShareIcon as Ne, Shield as Ye, ShieldCheck as _e, ShieldIcon as $e, SparkleIcon as on, Sparkles as en, Star as nn, StarIcon as cn, Stop as rn, StopFilled as an, SuccessIcon as In, Sun as ln, SunIcon as tn, Tag as sn, TagIcon as dn, TargetIcon as Cn, Terminal as hn, TerminalIcon as kn, TextTool as pn, ThumbsDownIcon as un, ThumbsUpIcon as Sn, Timer as gn, Trash as Dn, TrashIcon as Pn, TrendingDown as fn, TrendingUp as mn, Unlock as yn, Upload as Mn, UploadIcon as Tn, User as Fn, UserIcon as wn, Video as Ln, VideoIcon as An, Volume as Bn, VolumeIcon as bn, VolumeOff as vn, Wand as Hn, WarningIcon as Un, WifiIcon as xn, WifiOffIcon as Gn, Workflow as Rn, X as En, XCircle as Vn, Zap as On, ZapIcon as Wn } from "./components/icons/index.js";
2
+ import { ActualSize as Kn, Clipboard as qn, ExitFullscreen as Xn, Fullscreen as Zn, Keyboard as Qn, Monitor as jn, Scan as Jn, SlidersHorizontal as Nn, Unplug as Yn } from "./components/icons/RemoteControlIcons.js";
3
+ import { DockActivity as $n, DockBot as oc, DockCode as ec, DockCpu as nc, DockFileCode as cc, DockFolder as rc, DockGlobe as ac, DockLayers as Ic, DockLayoutDashboard as ic, DockMessageSquare as lc, DockRegion as tc, DockSearch as sc, DockSparkles as dc, DockTerminal as Cc, DockText as hc } from "./components/icons/DockIcons.js";
3
4
  export {
4
5
  n as Activity,
5
6
  c as ActivityIcon,
7
+ Kn as ActualSize,
6
8
  r as AlertCircle,
7
9
  a as AlertTriangle,
8
10
  I as ArchiveIcon,
@@ -10,40 +12,41 @@ export {
10
12
  l as ArrowLeft,
11
13
  t as ArrowRight,
12
14
  s as ArrowRightLeft,
13
- C as ArrowUp,
14
- d as AtSign,
15
+ d as ArrowUp,
16
+ C as AtSign,
15
17
  h as AwardIcon,
16
18
  k as BarChart,
17
19
  p as BatteryIcon,
18
20
  u as Bell,
19
- g as BellIcon,
20
- D as Bookmark,
21
- S as BookmarkIcon,
21
+ S as BellIcon,
22
+ g as Bookmark,
23
+ D as BookmarkIcon,
22
24
  P as Bot,
23
25
  f as BotIcon,
24
26
  m as BugIcon,
25
27
  y as Calendar,
26
28
  M as CalendarIcon,
27
29
  T as Camera,
28
- w as CameraIcon,
29
- F as ChartIcon,
30
+ F as CameraIcon,
31
+ w as ChartIcon,
30
32
  L as Check,
31
33
  A as CheckCircle,
32
34
  B as CheckIcon,
33
- v as ChevronDown,
34
- H as ChevronLeft,
35
- U as ChevronRight,
36
- b as ChevronUp,
37
- G as ChevronsUpDown,
38
- R as CircleStop,
39
- x as Clock,
40
- V as ClockIcon,
41
- E as CloseIcon,
35
+ b as ChevronDown,
36
+ v as ChevronLeft,
37
+ H as ChevronRight,
38
+ U as ChevronUp,
39
+ x as ChevronsUpDown,
40
+ G as CircleStop,
41
+ qn as Clipboard,
42
+ R as Clock,
43
+ E as ClockIcon,
44
+ V as CloseIcon,
42
45
  O as Cloud,
43
46
  W as CloudIcon,
44
- q as Code,
45
- z as CodeIcon,
46
- K as CompassIcon,
47
+ z as Code,
48
+ K as CodeIcon,
49
+ q as CompassIcon,
47
50
  X as Copy,
48
51
  Z as CopyCheck,
49
52
  Q as CopyCheckIcon,
@@ -52,26 +55,27 @@ export {
52
55
  N as CreditCardIcon,
53
56
  Y as Database,
54
57
  _ as DatabaseIcon,
55
- zn as DockActivity,
56
- Kn as DockBot,
57
- Xn as DockCode,
58
- Zn as DockCpu,
59
- Qn as DockFileCode,
60
- jn as DockFolder,
61
- Jn as DockGlobe,
62
- Nn as DockLayers,
63
- Yn as DockLayoutDashboard,
64
- _n as DockMessageSquare,
65
- $n as DockRegion,
66
- oc as DockSearch,
67
- ec as DockSparkles,
68
- nc as DockTerminal,
69
- cc as DockText,
58
+ $n as DockActivity,
59
+ oc as DockBot,
60
+ ec as DockCode,
61
+ nc as DockCpu,
62
+ cc as DockFileCode,
63
+ rc as DockFolder,
64
+ ac as DockGlobe,
65
+ Ic as DockLayers,
66
+ ic as DockLayoutDashboard,
67
+ lc as DockMessageSquare,
68
+ tc as DockRegion,
69
+ sc as DockSearch,
70
+ dc as DockSparkles,
71
+ Cc as DockTerminal,
72
+ hc as DockText,
70
73
  $ as DollarIcon,
71
74
  oo as Download,
72
75
  eo as DownloadIcon,
73
76
  no as EditIcon,
74
77
  co as ErrorIcon,
78
+ Xn as ExitFullscreen,
75
79
  ro as ExternalLink,
76
80
  ao as Eye,
77
81
  Io as EyeIcon,
@@ -84,34 +88,36 @@ export {
84
88
  ko as Filter,
85
89
  po as FilterIcon,
86
90
  uo as FireIcon,
87
- go as Folder,
88
- Do as FolderOpen,
89
- So as FolderPlus,
91
+ So as Folder,
92
+ go as FolderOpen,
93
+ Do as FolderPlus,
90
94
  Po as FolderPlusIcon,
95
+ Zn as Fullscreen,
91
96
  fo as GiftIcon,
92
97
  mo as GitBranch,
93
98
  yo as GitBranchIcon,
94
99
  Mo as Globe,
95
100
  To as GlobeIcon,
96
- wo as Grid,
97
- Fo as Grid3x3,
101
+ Fo as Grid,
102
+ wo as Grid3x3,
98
103
  Lo as GripVertical,
99
104
  Ao as Hash,
100
105
  Bo as HeadphonesIcon,
101
- vo as Heart,
102
- Ho as HeartIcon,
103
- Uo as HelpIcon,
104
- bo as Highlighter,
105
- Go as History,
106
- Ro as Home,
107
- xo as HomeIcon,
108
- Vo as Image,
109
- Eo as ImageIcon,
106
+ bo as Heart,
107
+ vo as HeartIcon,
108
+ Ho as HelpIcon,
109
+ Uo as Highlighter,
110
+ xo as History,
111
+ Go as Home,
112
+ Ro as HomeIcon,
113
+ Eo as Image,
114
+ Vo as ImageIcon,
110
115
  Oo as Info,
111
116
  Wo as InfoIcon,
112
- qo as Key,
113
- zo as KeyIcon,
114
- Ko as Layers,
117
+ zo as Key,
118
+ Ko as KeyIcon,
119
+ Qn as Keyboard,
120
+ qo as Layers,
115
121
  Xo as LayersIcon,
116
122
  Zo as LayoutDashboard,
117
123
  Qo as Link,
@@ -132,40 +138,42 @@ export {
132
138
  le as MicIcon,
133
139
  te as MicOff,
134
140
  se as Minus,
135
- Ce as MinusIcon,
136
- de as MonitorPointer,
141
+ de as MinusIcon,
142
+ jn as Monitor,
143
+ Ce as MonitorPointer,
137
144
  he as Moon,
138
145
  ke as MoonIcon,
139
146
  pe as MoreHorizontal,
140
147
  ue as MoreVertical,
141
- ge as MuteIcon,
142
- De as Package,
143
- Se as PackageIcon,
148
+ Se as MuteIcon,
149
+ ge as Package,
150
+ De as PackageIcon,
144
151
  Pe as Paperclip,
145
152
  fe as Paste,
146
153
  me as PasteIcon,
147
154
  ye as Pause,
148
155
  Me as PauseIcon,
149
156
  Te as Pencil,
150
- we as Phone,
151
- Fe as PieChart,
157
+ Fe as Phone,
158
+ we as PieChart,
152
159
  Le as Pin,
153
160
  Ae as PinIcon,
154
161
  Be as Play,
155
- ve as PlayIcon,
156
- He as Plus,
157
- Ue as PlusIcon,
158
- be as PowerIcon,
159
- Ge as PrinterIcon,
160
- Re as Quote,
161
- xe as Refresh,
162
- Ve as RefreshIcon,
163
- Ee as Region,
162
+ be as PlayIcon,
163
+ ve as Plus,
164
+ He as PlusIcon,
165
+ Ue as PowerIcon,
166
+ xe as PrinterIcon,
167
+ Ge as Quote,
168
+ Re as Refresh,
169
+ Ee as RefreshIcon,
170
+ Ve as Region,
164
171
  Oe as Restore,
165
172
  We as RocketIcon,
166
- qe as Save,
167
- ze as SaveIcon,
168
- Ke as Search,
173
+ ze as Save,
174
+ Ke as SaveIcon,
175
+ Jn as Scan,
176
+ qe as Search,
169
177
  Xe as SearchIcon,
170
178
  Ze as Send,
171
179
  Qe as SendIcon,
@@ -175,6 +183,7 @@ export {
175
183
  Ye as Shield,
176
184
  _e as ShieldCheck,
177
185
  $e as ShieldIcon,
186
+ Nn as SlidersHorizontal,
178
187
  on as SparkleIcon,
179
188
  en as Sparkles,
180
189
  nn as Star,
@@ -185,35 +194,36 @@ export {
185
194
  ln as Sun,
186
195
  tn as SunIcon,
187
196
  sn as Tag,
188
- Cn as TagIcon,
189
- dn as TargetIcon,
197
+ dn as TagIcon,
198
+ Cn as TargetIcon,
190
199
  hn as Terminal,
191
200
  kn as TerminalIcon,
192
201
  pn as TextTool,
193
202
  un as ThumbsDownIcon,
194
- gn as ThumbsUpIcon,
195
- Dn as Timer,
196
- Sn as Trash,
203
+ Sn as ThumbsUpIcon,
204
+ gn as Timer,
205
+ Dn as Trash,
197
206
  Pn as TrashIcon,
198
207
  fn as TrendingDown,
199
208
  mn as TrendingUp,
200
209
  yn as Unlock,
210
+ Yn as Unplug,
201
211
  Mn as Upload,
202
212
  Tn as UploadIcon,
203
- wn as User,
204
- Fn as UserIcon,
213
+ Fn as User,
214
+ wn as UserIcon,
205
215
  Ln as Video,
206
216
  An as VideoIcon,
207
217
  Bn as Volume,
208
- vn as VolumeIcon,
209
- Hn as VolumeOff,
210
- Un as Wand,
211
- bn as WarningIcon,
212
- Gn as WifiIcon,
213
- Rn as WifiOffIcon,
214
- xn as Workflow,
215
- Vn as X,
216
- En as XCircle,
218
+ bn as VolumeIcon,
219
+ vn as VolumeOff,
220
+ Hn as Wand,
221
+ Un as WarningIcon,
222
+ xn as WifiIcon,
223
+ Gn as WifiOffIcon,
224
+ Rn as Workflow,
225
+ En as X,
226
+ Vn as XCircle,
217
227
  On as Zap,
218
228
  Wn as ZapIcon
219
229
  };
@@ -1,8 +1,8 @@
1
- function U(a) {
2
- const { surface: l } = a, I = l.ownerDocument, c = I.defaultView;
3
- if (!c) throw new Error("Remote pointer requires an attached document");
4
- let o = null, f = null, u = null, p = null, y = 0, z = 0, M = !1, x = !1, D = 0, b = !1;
5
- const g = /* @__PURE__ */ new Set(), L = /* @__PURE__ */ new Set(), h = /* @__PURE__ */ new Map(), C = [], w = (e) => !x && a.isTargetValid(e), O = (e, t) => Math.hypot(e.clientX - t.clientX, e.clientY - t.clientY), v = (e) => ({
1
+ function F(a) {
2
+ const { surface: l } = a, I = l.ownerDocument, s = I.defaultView;
3
+ if (!s) throw new Error("Remote pointer requires an attached document");
4
+ let o = null, f = null, u = null, p = null, k = 0, z = !1, L = 0, M = 0, C = !1, H = !1, D = 0, b = !1;
5
+ const g = /* @__PURE__ */ new Set(), O = /* @__PURE__ */ new Set(), h = /* @__PURE__ */ new Map(), K = [], w = (e) => !H && a.isTargetValid(e), E = (e, t) => Math.hypot(e.clientX - t.clientX, e.clientY - t.clientY), v = (e) => ({
6
6
  clientX: e.clientX,
7
7
  clientY: e.clientY,
8
8
  shiftKey: e.shiftKey,
@@ -12,64 +12,76 @@ function U(a) {
12
12
  pointerType: "pointerType" in e ? String(e.pointerType) : "mouse"
13
13
  });
14
14
  function d(e, t, n, i = !1) {
15
- const s = n;
16
- e.addEventListener(t, s, { capture: i, passive: !1 }), C.push(() => e.removeEventListener(t, s, i));
15
+ const c = n;
16
+ e.addEventListener(t, c, { capture: i, passive: !1 }), K.push(() => e.removeEventListener(t, c, i));
17
17
  }
18
- function P(e, t) {
18
+ function Y(e, t) {
19
19
  const n = w(t) && a.sendPointer(e, t) !== !1;
20
20
  if (n && e.kind === "move")
21
21
  for (const i of h.values()) i.target === t && (i.command = { ...i.command, ...v(e) });
22
22
  return n;
23
23
  }
24
- function H() {
25
- c.clearTimeout(z), z = 0, M && (M = !1, a.onHoldChange?.(null));
24
+ function P() {
25
+ s.clearTimeout(M), M = 0, C && (C = !1, a.onHoldChange?.(null));
26
26
  }
27
- function X(e) {
28
- L.delete(e), l.hasPointerCapture?.(e) && l.releasePointerCapture(e);
27
+ function _(e) {
28
+ O.delete(e), l.hasPointerCapture?.(e) && l.releasePointerCapture(e);
29
29
  }
30
- function B(e) {
31
- l.setPointerCapture?.(e), L.add(e);
30
+ function q(e) {
31
+ l.setPointerCapture?.(e), O.add(e);
32
32
  }
33
- function k() {
34
- y && c.cancelAnimationFrame(y), y = 0;
33
+ function y() {
34
+ L++, z = !1, k && s.cancelAnimationFrame(k), k = 0;
35
35
  const e = f;
36
- f = null, e && !P(e.command, e.target) && r();
36
+ f = null, e && !Y(e.command, e.target) && r();
37
37
  }
38
- function E(e, t) {
39
- if (f && (f.target !== t || f.command.kind !== e.kind) && k(), !!w(t) && (e.kind === "scroll" && f?.command.kind === "scroll" && (e = { ...e, dx: f.command.dx + e.dx, dy: f.command.dy + e.dy }), f = { target: t, command: e }, !y)) {
40
- const n = D, i = c.requestAnimationFrame(() => {
41
- n === D && y === i && k();
42
- });
43
- y = i;
38
+ function x(e, t) {
39
+ if (f && (f.target !== t || f.command.kind !== e.kind) && y(), !!w(t)) {
40
+ if (e.kind === "scroll" && f?.command.kind === "scroll" && (e = { ...e, dx: f.command.dx + e.dx, dy: f.command.dy + e.dy }), f = { target: t, command: e }, e.kind === "move") {
41
+ if (!z) {
42
+ z = !0;
43
+ const n = L;
44
+ s.queueMicrotask(() => {
45
+ n === L && y();
46
+ });
47
+ }
48
+ return;
49
+ }
50
+ if (!k) {
51
+ const n = D, i = s.requestAnimationFrame(() => {
52
+ n === D && k === i && y();
53
+ });
54
+ k = i;
55
+ }
44
56
  }
45
57
  }
46
- function T(e, t, n, i, s = 1) {
58
+ function T(e, t, n, i, c = 1) {
47
59
  const m = h.get(i);
48
60
  if (!e && !m) return;
49
61
  e || h.delete(i);
50
- const A = { ...t, kind: e ? "down" : "up", button: i, clicks: s };
51
- P(A, n) && e && h.set(i, { target: n, command: A });
62
+ const U = { ...t, kind: e ? "down" : "up", button: i, clicks: c };
63
+ Y(U, n) && e && h.set(i, { target: n, command: U });
52
64
  }
53
- function K(e, t) {
65
+ function X(e, t) {
54
66
  const n = D;
55
67
  return a.onActivate?.(e, t), n === D && w(t);
56
68
  }
57
- function Y(e, t, n, i = 1) {
58
- K(e, t) && (T(!0, e, t, n, i), T(!1, e, t, n, i));
69
+ function A(e, t, n, i = 1) {
70
+ X(e, t) && (T(!0, e, t, n, i), T(!1, e, t, n, i));
59
71
  }
60
72
  function r() {
61
- D++, H(), y && c.cancelAnimationFrame(y), y = 0;
73
+ D++, L++, z = !1, P(), k && s.cancelAnimationFrame(k), k = 0;
62
74
  const e = /* @__PURE__ */ new Set();
63
75
  o && e.add(o.target), f && e.add(f.target), u !== null && e.add(u), f = null, o = null, u = null, p = null, b = g.size > 0;
64
76
  for (const [t, n] of h)
65
77
  e.add(n.target), T(!1, n.command, n.target, t);
66
78
  for (const t of e) a.release(t);
67
- for (const t of [...L]) X(t);
79
+ for (const t of [...O]) _(t);
68
80
  }
69
81
  function S(e) {
70
- g.delete(e), X(e), g.size || (b = !1);
82
+ g.delete(e), _(e), g.size || (b = !1);
71
83
  }
72
- function _(e) {
84
+ function B(e) {
73
85
  const t = o;
74
86
  if (!t || t.id !== e.pointerId) return;
75
87
  if (!w(t.target)) {
@@ -77,14 +89,14 @@ function U(a) {
77
89
  return;
78
90
  }
79
91
  const n = v(e);
80
- if ((t.mode === "pending" || t.mode === "hold") && O(t.origin, n) > 8) {
92
+ if ((t.mode === "pending" || t.mode === "hold") && E(t.origin, n) > 8) {
81
93
  const i = t.mode === "hold";
82
- if (H(), p = null, t.mode = i ? "drag" : "scroll", i && K(t.origin, t.target) && T(!0, t.origin, t.target, 0), o !== t) return;
94
+ if (P(), p = null, t.mode = i ? "drag" : "scroll", i && X(t.origin, t.target) && T(!0, t.origin, t.target, 0), o !== t) return;
83
95
  }
84
96
  if (t.mode === "scroll") {
85
- const i = t.last, s = i.clientX - n.clientX, m = i.clientY - n.clientY;
86
- (s || m) && E({ ...t.origin, kind: "scroll", dx: s, dy: m }, t.target), t.last = n;
87
- } else t.mode === "drag" && (E({ ...n, kind: "move" }, t.target), t.last = n);
97
+ const i = t.last, c = i.clientX - n.clientX, m = i.clientY - n.clientY;
98
+ (c || m) && x({ ...t.origin, kind: "scroll", dx: c, dy: m }, t.target), t.last = n;
99
+ } else t.mode === "drag" && (x({ ...n, kind: "move" }, t.target), t.last = n);
88
100
  }
89
101
  d(l, "pointerdown", (e) => {
90
102
  const t = a.resolveTarget(e);
@@ -95,15 +107,15 @@ function U(a) {
95
107
  r();
96
108
  return;
97
109
  }
98
- (o || h.size) && r(), k(), u !== null && (a.release(u), u = null), b = !1, o = { id: e.pointerId, target: t, origin: n, last: n, mode: "pending" };
110
+ (o || h.size) && r(), y(), u !== null && (a.release(u), u = null), b = !1, o = { id: e.pointerId, target: t, origin: n, last: n, mode: "pending" };
99
111
  const i = o;
100
- z = c.setTimeout(() => {
101
- if (z = 0, o === i) {
112
+ M = s.setTimeout(() => {
113
+ if (M = 0, o === i) {
102
114
  if (!w(t)) {
103
115
  r();
104
116
  return;
105
117
  }
106
- i.mode = "hold", M = !0, a.onHoldChange?.({ ...n, target: t });
118
+ i.mode = "hold", C = !0, a.onHoldChange?.({ ...n, target: t });
107
119
  }
108
120
  }, 450);
109
121
  } else {
@@ -111,14 +123,14 @@ function U(a) {
111
123
  r();
112
124
  return;
113
125
  }
114
- o && (o.id !== e.pointerId || o.target !== t) && r(), k(), u !== null && (a.release(u), u = null), o = { id: e.pointerId, target: t, origin: n, last: n, mode: "direct" };
115
- const i = e.button === 0 && p?.target === t && c.performance.now() - p.time <= 350 && O(p.position, n) <= 16;
116
- K(n, t) && T(!0, n, t, e.button, Math.max(1, e.detail, i ? 2 : 1));
126
+ o && (o.id !== e.pointerId || o.target !== t) && r(), y(), u !== null && (a.release(u), u = null), o = { id: e.pointerId, target: t, origin: n, last: n, mode: "direct" };
127
+ const i = e.button === 0 && p?.target === t && s.performance.now() - p.time <= 350 && E(p.position, n) <= 16;
128
+ X(n, t) && T(!0, n, t, e.button, Math.max(1, e.detail, i ? 2 : 1));
117
129
  }
118
- B(e.pointerId), e.pointerType === "touch" && e.preventDefault();
130
+ q(e.pointerId), e.pointerType === "touch" && e.preventDefault();
119
131
  }), d(l, "pointermove", (e) => {
120
132
  if (e.pointerType === "touch") {
121
- _(e);
133
+ B(e);
122
134
  return;
123
135
  }
124
136
  if (b || g.size) return;
@@ -130,35 +142,35 @@ function U(a) {
130
142
  const n = v(e);
131
143
  if (o) {
132
144
  o.last = n;
133
- for (const [i, s] of [[0, 1], [1, 4], [2, 2], [3, 8], [4, 16]]) {
134
- const m = !!(e.buttons & s);
135
- m !== h.has(i) && (k(), T(m, n, t, i));
145
+ for (const [i, c] of [[0, 1], [1, 4], [2, 2], [3, 8], [4, 16]]) {
146
+ const m = !!(e.buttons & c);
147
+ m !== h.has(i) && (y(), T(m, n, t, i));
136
148
  }
137
149
  }
138
- E({ ...n, kind: "move" }, t);
150
+ x({ ...n, kind: "move" }, t);
139
151
  }), d(l, "pointerup", (e) => {
140
152
  const t = o;
141
153
  if (t?.id === e.pointerId && !b)
142
154
  if (!w(t.target)) r();
143
155
  else if (e.pointerType === "touch") {
144
- _(e), H();
156
+ B(e), P();
145
157
  const n = v(e);
146
158
  if (t.mode === "pending") {
147
- const i = c.performance.now(), s = p?.target === t.target && i - p.time <= 350 && O(p.position, n) <= 16;
148
- Y(n, t.target, 0, s ? 2 : 1), p = s ? null : { target: t.target, position: n, time: i };
149
- } else t.mode === "hold" ? (p = null, Y(n, t.target, 2)) : (k(), t.mode === "drag" && T(!1, n, t.target, 0));
159
+ const i = s.performance.now(), c = p?.target === t.target && i - p.time <= 350 && E(p.position, n) <= 16;
160
+ A(n, t.target, 0, c ? 2 : 1), p = c ? null : { target: t.target, position: n, time: i };
161
+ } else t.mode === "hold" ? (p = null, A(n, t.target, 2)) : (y(), t.mode === "drag" && T(!1, n, t.target, 0));
150
162
  a.release(t.target), o = null;
151
163
  } else {
152
- f?.command.kind === "move" && (f.command = { ...v(e), kind: "move" }), k();
164
+ f?.command.kind === "move" && (f.command = { ...v(e), kind: "move" }), y();
153
165
  const n = h.get(e.button)?.command;
154
166
  for (const i of [...h.keys()]) T(!1, v(e), t.target, i, n && "clicks" in n ? n.clicks : 1);
155
- p = e.button === 0 && n && "clicks" in n && n.clicks === 1 && O(t.origin, v(e)) <= 8 ? { target: t.target, position: v(e), time: c.performance.now() } : null, h.size || (o = null);
167
+ p = e.button === 0 && n && "clicks" in n && n.clicks === 1 && E(t.origin, v(e)) <= 8 ? { target: t.target, position: v(e), time: s.performance.now() } : null, h.size || (o = null);
156
168
  }
157
169
  (!o || o.id !== e.pointerId) && S(e.pointerId);
158
170
  }), d(l, "pointercancel", (e) => {
159
171
  r(), S(e.pointerId);
160
172
  }), d(l, "lostpointercapture", (e) => {
161
- L.has(e.pointerId) && (r(), S(e.pointerId));
173
+ O.has(e.pointerId) && (r(), S(e.pointerId));
162
174
  }), d(I, "pointerup", (e) => {
163
175
  o?.id !== e.pointerId && S(e.pointerId);
164
176
  }), d(I, "pointercancel", (e) => S(e.pointerId)), d(I, "pointerdown", (e) => {
@@ -166,33 +178,33 @@ function U(a) {
166
178
  }, !0), d(l, "wheel", (e) => {
167
179
  const t = a.resolveTarget(e);
168
180
  if (t === null || !w(t) || (e.preventDefault(), o || g.size)) return;
169
- p = null, u !== null && u !== t && (k(), a.release(u)), u = t;
170
- const n = e.deltaMode === 1 ? 16 : e.deltaMode === 2 ? l.clientWidth || c.innerWidth : 1, i = e.deltaMode === 1 ? 16 : e.deltaMode === 2 ? l.clientHeight || c.innerHeight : 1, s = e.deltaX * n, m = e.deltaY * i;
171
- Number.isFinite(s) && Number.isFinite(m) && (s || m) && E({ ...v(e), kind: "scroll", dx: s, dy: m }, t);
181
+ p = null, u !== null && u !== t && (y(), a.release(u)), u = t;
182
+ const n = e.deltaMode === 1 ? 16 : e.deltaMode === 2 ? l.clientWidth || s.innerWidth : 1, i = e.deltaMode === 1 ? 16 : e.deltaMode === 2 ? l.clientHeight || s.innerHeight : 1, c = e.deltaX * n, m = e.deltaY * i;
183
+ Number.isFinite(c) && Number.isFinite(m) && (c || m) && x({ ...v(e), kind: "scroll", dx: c, dy: m }, t);
172
184
  });
173
185
  for (const e of ["mousedown", "mouseup", "click", "dblclick", "contextmenu", "dragstart", "selectstart"])
174
186
  d(l, e, (t) => {
175
187
  a.resolveTarget(t) !== null && t.preventDefault();
176
188
  });
177
- for (const e of ["blur", "pagehide", "resize", "orientationchange"]) d(c, e, r);
189
+ for (const e of ["blur", "pagehide", "resize", "orientationchange"]) d(s, e, r);
178
190
  if (d(I, "visibilitychange", () => {
179
191
  I.hidden && r();
180
- }), d(c, "scroll", r, !0), c.visualViewport && (d(c.visualViewport, "resize", r), d(c.visualViewport, "scroll", r)), typeof ResizeObserver < "u") {
192
+ }), d(s, "scroll", r, !0), s.visualViewport && (d(s.visualViewport, "resize", r), d(s.visualViewport, "scroll", r)), typeof ResizeObserver < "u") {
181
193
  let e = `${l.clientWidth}:${l.clientHeight}`;
182
194
  const t = new ResizeObserver(() => {
183
195
  const n = `${l.clientWidth}:${l.clientHeight}`;
184
196
  n !== e && (e = n, r());
185
197
  });
186
- t.observe(l), C.push(() => t.disconnect());
198
+ t.observe(l), K.push(() => t.disconnect());
187
199
  }
188
- return { flush: k, reset: r, dispose() {
189
- if (!x) {
190
- r(), x = !0;
191
- for (const e of C) e();
200
+ return { flush: y, reset: r, dispose() {
201
+ if (!H) {
202
+ r(), H = !0;
203
+ for (const e of K) e();
192
204
  g.clear();
193
205
  }
194
206
  } };
195
207
  }
196
208
  export {
197
- U as createRemotePointer
209
+ F as createRemotePointer
198
210
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@floegence/floe-webapp-core",
3
- "version": "0.81.3",
3
+ "version": "0.81.5",
4
4
  "license": "MIT",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -152,7 +152,7 @@
152
152
  "dependencies": {
153
153
  "clsx": "^2.1.1",
154
154
  "diff": "^8.0.4",
155
- "dompurify": "^3.4.15",
155
+ "dompurify": "^3.4.16",
156
156
  "marked": "^17.0.6",
157
157
  "mermaid": "^11.17.2",
158
158
  "monaco-editor": "^0.57.0",