@aivex/ui 1.2.0-dev.49 → 1.2.0-dev.50
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/components/Avatar/Avatar.cjs +1 -1
- package/dist/components/Avatar/Avatar.cjs.map +1 -1
- package/dist/components/Avatar/Avatar.d.ts +2 -4
- package/dist/components/Avatar/Avatar.js +31 -29
- package/dist/components/Avatar/Avatar.js.map +1 -1
- package/dist/components/Calendar/Calendar.cjs +1 -1
- package/dist/components/Calendar/Calendar.js +25 -25
- package/dist/components/Checkbox/Checkbox.cjs +1 -1
- package/dist/components/Checkbox/Checkbox.js +10 -10
- package/dist/components/Comment/MentionInput.cjs +1 -1
- package/dist/components/Comment/MentionInput.js +8 -8
- package/dist/components/Comment/MentionList.cjs +1 -1
- package/dist/components/Comment/MentionList.js +36 -36
- package/dist/components/DataGrid/DataGrid.cjs +1 -1
- package/dist/components/DataGrid/DataGrid.js +108 -108
- package/dist/components/DataGrid/DataGrid.js.map +1 -1
- package/dist/components/DataGrid/DataGridColumnSettings.cjs +1 -1
- package/dist/components/DataGrid/DataGridColumnSettings.js +36 -36
- package/dist/components/DataGrid/DataGridPrimitives.cjs +1 -1
- package/dist/components/DataGrid/DataGridPrimitives.js +48 -48
- package/dist/components/DataGrid/DataGridRows.cjs +1 -1
- package/dist/components/DataGrid/DataGridRows.js +24 -24
- package/dist/components/DraggableScroll/DraggableScroll.cjs +1 -1
- package/dist/components/DraggableScroll/DraggableScroll.js +5 -5
- package/dist/components/Field/Field.cjs +1 -1
- package/dist/components/Field/Field.js +34 -34
- package/dist/components/FilterModal/FilterModal.cjs +1 -1
- package/dist/components/FilterModal/FilterModal.js +24 -24
- package/dist/components/Modal/Modal.cjs +1 -1
- package/dist/components/Modal/Modal.js +51 -51
- package/dist/components/Pagination/Pagination.cjs +1 -1
- package/dist/components/Pagination/Pagination.js +24 -24
- package/dist/components/Radio/Radio.cjs +1 -1
- package/dist/components/Radio/Radio.js +9 -9
- package/dist/components/Segmented/Segmented.cjs +1 -1
- package/dist/components/Segmented/Segmented.js +12 -12
- package/dist/components/SelectBox/SelectBox.cjs +1 -1
- package/dist/components/SelectBox/SelectBox.js +12 -12
- package/dist/components/ShapeEditor/ShapeEditor.cjs +1 -1
- package/dist/components/ShapeEditor/ShapeEditor.js +367 -367
- package/dist/components/ShapeEditor/ShapeEditor.js.map +1 -1
- package/dist/components/ShapeEditor/ShapeViewer.cjs +1 -1
- package/dist/components/ShapeEditor/ShapeViewer.js +17 -17
- package/dist/components/ShapeEditor/_components/CursorGuide.cjs +1 -1
- package/dist/components/ShapeEditor/_components/CursorGuide.js +7 -7
- package/dist/components/ShapeEditor/_components/Minimap.cjs +1 -1
- package/dist/components/ShapeEditor/_components/Minimap.js +29 -29
- package/dist/components/ShapeEditor/_components/MinimapShape.cjs +1 -1
- package/dist/components/ShapeEditor/_components/MinimapShape.cjs.map +1 -1
- package/dist/components/ShapeEditor/_components/MinimapShape.js +9 -9
- package/dist/components/Slider/Slider.cjs +1 -1
- package/dist/components/Slider/Slider.js +10 -10
- package/dist/components/Switch/Switch.cjs +1 -1
- package/dist/components/Switch/Switch.js +7 -7
- package/dist/components/Tagbox/Tagbox.cjs +1 -1
- package/dist/components/Tagbox/Tagbox.js +7 -7
- package/dist/components/Textarea/Textarea.cjs +1 -1
- package/dist/components/Textarea/Textarea.js +9 -9
- package/dist/components/Textbox/Textbox.cjs +1 -1
- package/dist/components/Textbox/Textbox.js +7 -7
- package/dist/components/UploadArea/UploadArea.cjs +1 -1
- package/dist/components/UploadArea/UploadArea.js +19 -19
- package/package.json +1 -1
|
@@ -2,226 +2,226 @@
|
|
|
2
2
|
"use client";
|
|
3
3
|
import { SHAPE_TYPE as e, canEditVertices as t, generateId as n, isShapeVisible as r } from "./_model/geometry.js";
|
|
4
4
|
import { mergeEditorStrings as i } from "./_model/strings.js";
|
|
5
|
-
import { TOOL as
|
|
6
|
-
import { AssistantOverlay as
|
|
7
|
-
import { ContextMenu as
|
|
8
|
-
import { CursorGuide as
|
|
9
|
-
import { ImageStateOverlay as
|
|
10
|
-
import { Minimap as
|
|
11
|
-
import { SelectionInfo as
|
|
12
|
-
import { createClipboardDocumentId as
|
|
13
|
-
import { resolveEditorCursor as
|
|
14
|
-
import { buildRegionOverlayData as
|
|
15
|
-
import { buildContextMenuItems as
|
|
16
|
-
import { buildHotkeyActions as
|
|
17
|
-
import { createInteractionController as
|
|
18
|
-
import { useAssistant as
|
|
19
|
-
import { useLatestRef as
|
|
20
|
-
import { useDrawSession as
|
|
21
|
-
import { useEditorDocument as
|
|
22
|
-
import { useEditorHandle as
|
|
23
|
-
import { useEditorHotkeys as
|
|
24
|
-
import { useEditorView as
|
|
25
|
-
import { useEngineLifecycle as
|
|
26
|
-
import { useMinimapNavigation as
|
|
27
|
-
import { useMinimapSync as
|
|
28
|
-
import { useSelectionActions as
|
|
29
|
-
import { useSelectionInfoOverlay as
|
|
30
|
-
import { useSelectionModel as
|
|
31
|
-
import { useViewportControls as
|
|
32
|
-
import {
|
|
33
|
-
import {
|
|
5
|
+
import { TOOL as ee } from "./_model/tools.js";
|
|
6
|
+
import { AssistantOverlay as te } from "./_components/AssistantOverlay.js";
|
|
7
|
+
import { ContextMenu as ne } from "./_components/ContextMenu.js";
|
|
8
|
+
import { CursorGuide as re } from "./_components/CursorGuide.js";
|
|
9
|
+
import { ImageStateOverlay as ie } from "./_components/ImageStateOverlay.js";
|
|
10
|
+
import { Minimap as ae } from "./_components/Minimap.js";
|
|
11
|
+
import { SelectionInfo as oe } from "./_components/SelectionInfo.js";
|
|
12
|
+
import { createClipboardDocumentId as se } from "./_model/clipboard.js";
|
|
13
|
+
import { resolveEditorCursor as ce } from "./_model/cursors.js";
|
|
14
|
+
import { buildRegionOverlayData as le } from "./_model/overlays.js";
|
|
15
|
+
import { buildContextMenuItems as ue } from "./_state/buildContextMenuItems.js";
|
|
16
|
+
import { buildHotkeyActions as de } from "./_state/buildHotkeyActions.js";
|
|
17
|
+
import { createInteractionController as fe } from "./_state/createInteractionController.js";
|
|
18
|
+
import { useAssistant as pe } from "./_state/useAssistant.js";
|
|
19
|
+
import { useLatestRef as a } from "./_state/useLatestRef.js";
|
|
20
|
+
import { useDrawSession as me } from "./_state/useDrawSession.js";
|
|
21
|
+
import { useEditorDocument as he } from "./_state/useEditorDocument.js";
|
|
22
|
+
import { useEditorHandle as ge } from "./_state/useEditorHandle.js";
|
|
23
|
+
import { useEditorHotkeys as _e } from "./_state/useEditorHotkeys.js";
|
|
24
|
+
import { useEditorView as ve } from "./_state/useEditorView.js";
|
|
25
|
+
import { useEngineLifecycle as ye } from "./_state/useEngineLifecycle.js";
|
|
26
|
+
import { useMinimapNavigation as be } from "./_state/useMinimapNavigation.js";
|
|
27
|
+
import { useMinimapSync as xe } from "./_state/useMinimapSync.js";
|
|
28
|
+
import { useSelectionActions as Se } from "./_state/useSelectionActions.js";
|
|
29
|
+
import { useSelectionInfoOverlay as Ce } from "./_state/useSelectionInfoOverlay.js";
|
|
30
|
+
import { useSelectionModel as we } from "./_state/useSelectionModel.js";
|
|
31
|
+
import { useViewportControls as Te } from "./_state/useViewportControls.js";
|
|
32
|
+
import { useCallback as o, useEffect as s, useId as Ee, useLayoutEffect as c, useMemo as l, useRef as u, useState as d } from "react";
|
|
33
|
+
import { jsx as f, jsxs as De } from "react/jsx-runtime";
|
|
34
34
|
//#region src/components/ShapeEditor/ShapeEditor.tsx
|
|
35
35
|
function p({ document: p, clipboardScope: Oe, renderImageState: ke, dimmed: Ae = !1, selectedIds: je, activeTool: m, draftStyle: Me, draftMeta: h, readOnly: Ne, disableMarquee: Pe, locked: g, onLockedInteraction: Fe, onDrawAttemptWithoutDraft: Ie, onIdleEscape: Le, overrideShapeInteraction: _, defaultViewSettings: Re, viewSettings: ze, onViewSettingsChange: Be, showMinimap: Ve = !0, minimapPosition: He = "bottom-left", showViewSettings: Ue = !0, getContextMenuItems: We, strings: Ge, viewSettingItems: Ke, canMergeSelection: qe, brushSize: Je = 20, zoomBound: Ye, zoomAnimationDuration: Xe = 300, decorationShapes: Ze, regionMask: v, overlayMarkers: Qe, renderOverlayMarker: $e, onOverlayMarkerClick: et, renderImageOverlay: tt, getSelectionLabel: nt, hideSelectionLabelDot: rt, formatSelectionInfo: it, externalTools: at, assistant: ot, keymap: st, handleRef: ct, onActiveToolChange: lt, onSelectionChange: ut, onEditingChange: dt, onShapesCreated: ft, onShapesUpdated: pt, onShapesDeleted: mt, onDrawSessionChange: ht, onDraftShapeChange: gt, onViewportChange: _t, onShapesTransformPreview: vt }) {
|
|
36
|
-
let
|
|
36
|
+
let y = u(null), b = u(null), yt = u(null), bt = u(null), xt = u(null), St = `${Ee()}-minimap`, [x, Ct] = d(null), [wt, Tt] = d(!1), [S, Et] = d(!1), [C, w] = d(null), [Dt, Ot] = d({
|
|
37
37
|
active: !1,
|
|
38
38
|
kind: "none",
|
|
39
39
|
canUndo: !1,
|
|
40
40
|
canRedo: !1
|
|
41
|
-
}), [
|
|
42
|
-
|
|
43
|
-
}, []),
|
|
41
|
+
}), [kt, At] = d(!0), [jt, Mt] = d(!1), T = p?.id ?? "", Nt = p?.imageUrl ?? "", Pt = p?.displayImageUrl, Ft = p?.coordinateSize, It = p?.initialShapes, Lt = p?.initialSelectedIds, Rt = Pt ?? Nt, [zt, Bt] = d("loading"), Vt = zt === "loading" && p !== null && !Rt ? "missing" : zt, [Ht, Ut] = d(null), Wt = o((e, t) => {
|
|
42
|
+
Bt(e), Ut(e === "error" ? t ?? null : null);
|
|
43
|
+
}, []), E = he({
|
|
44
44
|
onShapesCreated: ft,
|
|
45
45
|
onShapesUpdated: pt,
|
|
46
46
|
onShapesDeleted: mt
|
|
47
|
-
}),
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
}, [
|
|
51
|
-
let
|
|
47
|
+
}), D = l(() => new Map((at ?? []).map((e) => [e.id, e])), [at]), O = u(D);
|
|
48
|
+
c(() => {
|
|
49
|
+
O.current = D;
|
|
50
|
+
}, [D]);
|
|
51
|
+
let Gt = a(Dt), k = l(() => i(Ge), [Ge]), { seededDefaults: Kt, view: A, setView: qt, updateView: Jt } = ve({
|
|
52
52
|
defaultViewSettings: Re,
|
|
53
53
|
viewSettings: ze,
|
|
54
54
|
onViewSettingsChange: Be
|
|
55
|
-
}),
|
|
55
|
+
}), j = l(() => !x || !v ? null : le(v, x.w, x.h), [x, v]), Yt = a(j), Xt = a(Ae), Zt = a(x), Qt = a(Ft), $t = a(Ft?.imageSize), M = a(m), N = a(Me), en = a(h), tn = a(Je), nn = a(A.simplifyStrength), P = !!Ne || !!g, F = a(P), rn = a(Pe), an = a(g), on = a(Fe), sn = a(Ne), cn = o((e = !0) => sn.current || !an.current || !e ? !1 : (on.current?.(), !0), []), ln = a(Ie), un = a(_), I = a(E), L = u(null), { selectedIds: R, selRef: z, changeSelection: B } = we({
|
|
56
56
|
controlledSelectedIds: je,
|
|
57
57
|
onSelectionChange: ut,
|
|
58
|
-
docShapes:
|
|
59
|
-
docRef:
|
|
60
|
-
overrideInteractionRef:
|
|
61
|
-
interactionControllerRef:
|
|
62
|
-
engineRef:
|
|
63
|
-
}),
|
|
64
|
-
let e =
|
|
58
|
+
docShapes: E.shapes,
|
|
59
|
+
docRef: I,
|
|
60
|
+
overrideInteractionRef: un,
|
|
61
|
+
interactionControllerRef: L,
|
|
62
|
+
engineRef: b
|
|
63
|
+
}), dn = u(!1), V = u("idle"), H = u(null), U = o(() => {
|
|
64
|
+
let e = b.current;
|
|
65
65
|
if (!e) return;
|
|
66
|
-
let t =
|
|
67
|
-
e.setCursor(
|
|
66
|
+
let t = M.current, n = O.current.get(t), r = Gt.current;
|
|
67
|
+
e.setCursor(ce({
|
|
68
68
|
tool: t,
|
|
69
69
|
externalToolCursor: n?.cursor,
|
|
70
|
-
isSpacePressed:
|
|
71
|
-
interactionMode:
|
|
72
|
-
rendererCursorHint:
|
|
70
|
+
isSpacePressed: dn.current,
|
|
71
|
+
interactionMode: V.current,
|
|
72
|
+
rendererCursorHint: H.current,
|
|
73
73
|
isPolygonDrawing: r.kind === "polygon" && r.active
|
|
74
74
|
}));
|
|
75
|
-
}, []),
|
|
76
|
-
|
|
77
|
-
}, [
|
|
78
|
-
|
|
79
|
-
}, [
|
|
80
|
-
engineRef:
|
|
81
|
-
docRef:
|
|
82
|
-
overlayRef:
|
|
83
|
-
zoomLabelRef:
|
|
84
|
-
minimapRectRef:
|
|
75
|
+
}, []), fn = o((e) => {
|
|
76
|
+
V.current !== e && (V.current = e, U());
|
|
77
|
+
}, [U]), pn = o((e) => {
|
|
78
|
+
H.current !== e && (H.current = e, U());
|
|
79
|
+
}, [U]), mn = a(B), [W, G] = d(null), hn = a(o((e) => G(e), [])), gn = a(W), _n = a(_t), vn = u(null), { registerMinimapShape: yn, applyMinimapPreview: bn, syncMinimap: K } = xe({
|
|
80
|
+
engineRef: b,
|
|
81
|
+
docRef: I,
|
|
82
|
+
overlayRef: bt,
|
|
83
|
+
zoomLabelRef: xt,
|
|
84
|
+
minimapRectRef: yt,
|
|
85
85
|
minimapSize: 204,
|
|
86
|
-
onViewportChangeRef:
|
|
87
|
-
onScreenOverlaySyncRef:
|
|
88
|
-
}),
|
|
89
|
-
engineRef:
|
|
90
|
-
docRef:
|
|
91
|
-
draftRef:
|
|
92
|
-
draftMetaRef:
|
|
93
|
-
screenOverlaySyncRef:
|
|
86
|
+
onViewportChangeRef: _n,
|
|
87
|
+
onScreenOverlaySyncRef: vn
|
|
88
|
+
}), q = Ce({
|
|
89
|
+
engineRef: b,
|
|
90
|
+
docRef: I,
|
|
91
|
+
draftRef: N,
|
|
92
|
+
draftMetaRef: en,
|
|
93
|
+
screenOverlaySyncRef: vn,
|
|
94
94
|
formatSelectionInfo: it,
|
|
95
95
|
onDraftShapeChange: gt
|
|
96
|
-
}),
|
|
97
|
-
|
|
96
|
+
}), xn = q.applyPreview, Sn = a(o((e) => {
|
|
97
|
+
bn(e), xn(e), vt?.(e);
|
|
98
98
|
}, [
|
|
99
|
+
bn,
|
|
99
100
|
xn,
|
|
100
|
-
Sn,
|
|
101
101
|
vt
|
|
102
|
-
])),
|
|
103
|
-
let r =
|
|
104
|
-
if (!r ||
|
|
102
|
+
])), Cn = a(q.onDrawPreview), wn = o((e, t) => {
|
|
103
|
+
let r = N.current;
|
|
104
|
+
if (!r || F.current) return;
|
|
105
105
|
let i = n();
|
|
106
|
-
|
|
106
|
+
I.current.create({
|
|
107
107
|
id: i,
|
|
108
108
|
type: e,
|
|
109
109
|
points: t,
|
|
110
110
|
style: r,
|
|
111
111
|
meta: h
|
|
112
|
-
}),
|
|
113
|
-
}, [h]),
|
|
114
|
-
toolRef:
|
|
115
|
-
selRef:
|
|
116
|
-
docRef:
|
|
117
|
-
readOnlyRef:
|
|
118
|
-
draftRef:
|
|
119
|
-
brushSizeRef:
|
|
120
|
-
simplifyEpsilonRef:
|
|
112
|
+
}), mn.current([i]);
|
|
113
|
+
}, [h]), Tn = a(wn), J = me({
|
|
114
|
+
toolRef: M,
|
|
115
|
+
selRef: z,
|
|
116
|
+
docRef: I,
|
|
117
|
+
readOnlyRef: F,
|
|
118
|
+
draftRef: N,
|
|
119
|
+
brushSizeRef: tn,
|
|
120
|
+
simplifyEpsilonRef: nn,
|
|
121
121
|
draftMeta: h,
|
|
122
|
-
engineRef:
|
|
123
|
-
onDrawSessionChange:
|
|
124
|
-
|
|
122
|
+
engineRef: b,
|
|
123
|
+
onDrawSessionChange: o((e) => {
|
|
124
|
+
Ot(e), ht?.(e);
|
|
125
125
|
}, [ht]),
|
|
126
126
|
onDraftShapeChange: gt,
|
|
127
|
-
changeSelection:
|
|
128
|
-
createShape:
|
|
129
|
-
}),
|
|
130
|
-
docRef:
|
|
131
|
-
draftRef:
|
|
127
|
+
changeSelection: B,
|
|
128
|
+
createShape: wn
|
|
129
|
+
}), En = a(J), { reset: Dn, undoSession: On, redoSession: kn, canUndoSession: An, canRedoSession: jn, handleToolChange: Mn, handleBrushSelectionChange: Nn } = J, Y = pe({
|
|
130
|
+
docRef: I,
|
|
131
|
+
draftRef: N,
|
|
132
132
|
draftMeta: h,
|
|
133
|
-
changeSelection:
|
|
134
|
-
assistantRef:
|
|
135
|
-
}),
|
|
136
|
-
doc:
|
|
137
|
-
selRef:
|
|
138
|
-
effectiveReadOnly:
|
|
139
|
-
changeSelection:
|
|
133
|
+
changeSelection: B,
|
|
134
|
+
assistantRef: a(ot)
|
|
135
|
+
}), Pn = a(Y), Fn = l(() => se(T), [T]), X = Se({
|
|
136
|
+
doc: E,
|
|
137
|
+
selRef: z,
|
|
138
|
+
effectiveReadOnly: P,
|
|
139
|
+
changeSelection: B,
|
|
140
140
|
canMergeSelection: qe,
|
|
141
|
-
clipboardDocumentId:
|
|
142
|
-
clipboardScope: Oe ??
|
|
143
|
-
}),
|
|
141
|
+
clipboardDocumentId: Fn,
|
|
142
|
+
clipboardScope: Oe ?? Fn
|
|
143
|
+
}), In = l(() => ({
|
|
144
144
|
undo: () => {
|
|
145
|
-
|
|
145
|
+
F.current || On() || E.undo();
|
|
146
146
|
},
|
|
147
147
|
redo: () => {
|
|
148
|
-
|
|
148
|
+
F.current || kn() || E.redo();
|
|
149
149
|
},
|
|
150
|
-
canUndo: () =>
|
|
151
|
-
canRedo: () =>
|
|
150
|
+
canUndo: () => An() || E.canUndo(),
|
|
151
|
+
canRedo: () => jn() || E.canRedo()
|
|
152
152
|
}), [
|
|
153
|
-
|
|
153
|
+
E,
|
|
154
|
+
On,
|
|
154
155
|
kn,
|
|
155
156
|
An,
|
|
156
|
-
jn
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
selRef: R,
|
|
157
|
+
jn
|
|
158
|
+
]), { zoomToBounds: Ln, zoomToShapes: Rn, zoomToSelection: zn, zoomAtCenter: Bn } = Te({
|
|
159
|
+
engineRef: b,
|
|
160
|
+
doc: E,
|
|
161
|
+
selRef: z,
|
|
162
162
|
zoomAnimationDuration: Xe,
|
|
163
163
|
zoomBound: Ye,
|
|
164
164
|
ready: S
|
|
165
|
-
}),
|
|
166
|
-
|
|
165
|
+
}), Vn = a(A);
|
|
166
|
+
ge({
|
|
167
167
|
handleRef: ct,
|
|
168
|
-
engineRef:
|
|
169
|
-
loadedImageRef:
|
|
170
|
-
regionOverlayRef:
|
|
171
|
-
viewRef:
|
|
172
|
-
doc:
|
|
173
|
-
history:
|
|
174
|
-
drawSession:
|
|
175
|
-
selection:
|
|
176
|
-
changeSelection:
|
|
177
|
-
rejectLockedEdit:
|
|
168
|
+
engineRef: b,
|
|
169
|
+
loadedImageRef: Zt,
|
|
170
|
+
regionOverlayRef: Yt,
|
|
171
|
+
viewRef: Vn,
|
|
172
|
+
doc: E,
|
|
173
|
+
history: In,
|
|
174
|
+
drawSession: J,
|
|
175
|
+
selection: X,
|
|
176
|
+
changeSelection: B,
|
|
177
|
+
rejectLockedEdit: cn,
|
|
178
178
|
viewport: {
|
|
179
|
-
zoomToBounds:
|
|
180
|
-
zoomToShapes:
|
|
181
|
-
zoomToSelection:
|
|
182
|
-
zoomAtCenter:
|
|
179
|
+
zoomToBounds: Ln,
|
|
180
|
+
zoomToShapes: Rn,
|
|
181
|
+
zoomToSelection: zn,
|
|
182
|
+
zoomAtCenter: Bn
|
|
183
183
|
}
|
|
184
184
|
});
|
|
185
|
-
let
|
|
186
|
-
let e =
|
|
187
|
-
engineRef:
|
|
188
|
-
toolRef:
|
|
189
|
-
externalToolMapRef:
|
|
190
|
-
spaceRef:
|
|
191
|
-
docRef:
|
|
192
|
-
renderShapesRef:
|
|
193
|
-
renderDefaultsRef:
|
|
194
|
-
selRef:
|
|
195
|
-
draftRef:
|
|
196
|
-
readOnlyRef:
|
|
197
|
-
disableMarqueeRef:
|
|
198
|
-
lockedRef:
|
|
199
|
-
onLockedInteraction: () =>
|
|
200
|
-
onDrawAttemptWithoutDraft: () =>
|
|
201
|
-
createRef:
|
|
202
|
-
selectRef:
|
|
203
|
-
enterEditRef:
|
|
204
|
-
editingIdRef:
|
|
205
|
-
drawSessionRef:
|
|
206
|
-
assistantRef:
|
|
207
|
-
setCursorHint:
|
|
208
|
-
setInteractionMode:
|
|
209
|
-
syncMinimap:
|
|
210
|
-
onTransformPreview: (e) =>
|
|
211
|
-
onDrawPreview: (e) =>
|
|
185
|
+
let Hn = a({ strokeWidth: A.strokeSize }), Un = o(() => {
|
|
186
|
+
let e = fe({
|
|
187
|
+
engineRef: b,
|
|
188
|
+
toolRef: M,
|
|
189
|
+
externalToolMapRef: O,
|
|
190
|
+
spaceRef: dn,
|
|
191
|
+
docRef: I,
|
|
192
|
+
renderShapesRef: Wn,
|
|
193
|
+
renderDefaultsRef: Hn,
|
|
194
|
+
selRef: z,
|
|
195
|
+
draftRef: N,
|
|
196
|
+
readOnlyRef: F,
|
|
197
|
+
disableMarqueeRef: rn,
|
|
198
|
+
lockedRef: an,
|
|
199
|
+
onLockedInteraction: () => on.current?.(),
|
|
200
|
+
onDrawAttemptWithoutDraft: () => ln.current?.(),
|
|
201
|
+
createRef: Tn,
|
|
202
|
+
selectRef: mn,
|
|
203
|
+
enterEditRef: hn,
|
|
204
|
+
editingIdRef: gn,
|
|
205
|
+
drawSessionRef: En,
|
|
206
|
+
assistantRef: Pn,
|
|
207
|
+
setCursorHint: pn,
|
|
208
|
+
setInteractionMode: fn,
|
|
209
|
+
syncMinimap: K,
|
|
210
|
+
onTransformPreview: (e) => Sn.current(e),
|
|
211
|
+
onDrawPreview: (e) => Cn.current(e)
|
|
212
212
|
});
|
|
213
|
-
return
|
|
213
|
+
return L.current = e, e;
|
|
214
214
|
}, [
|
|
215
|
-
|
|
216
|
-
mn,
|
|
215
|
+
z,
|
|
217
216
|
pn,
|
|
218
|
-
|
|
217
|
+
fn,
|
|
218
|
+
K
|
|
219
219
|
]);
|
|
220
|
-
|
|
221
|
-
|
|
220
|
+
s(() => () => {
|
|
221
|
+
L.current = null;
|
|
222
222
|
}, []);
|
|
223
|
-
let
|
|
224
|
-
let e = _ ?
|
|
223
|
+
let Z = l(() => {
|
|
224
|
+
let e = _ ? E.shapes.map((e) => {
|
|
225
225
|
let t = _(e);
|
|
226
226
|
return t ? {
|
|
227
227
|
...e,
|
|
@@ -230,7 +230,7 @@ function p({ document: p, clipboardScope: Oe, renderImageState: ke, dimmed: Ae =
|
|
|
230
230
|
...t
|
|
231
231
|
}
|
|
232
232
|
} : e;
|
|
233
|
-
}) :
|
|
233
|
+
}) : E.shapes;
|
|
234
234
|
return Ze?.length ? [...Ze.map((e) => ({
|
|
235
235
|
...e,
|
|
236
236
|
interaction: {
|
|
@@ -242,267 +242,267 @@ function p({ document: p, clipboardScope: Oe, renderImageState: ke, dimmed: Ae =
|
|
|
242
242
|
}
|
|
243
243
|
})), ...e] : e;
|
|
244
244
|
}, [
|
|
245
|
-
|
|
245
|
+
E.shapes,
|
|
246
246
|
_,
|
|
247
247
|
Ze
|
|
248
|
-
]),
|
|
249
|
-
|
|
250
|
-
hostRef:
|
|
251
|
-
engineRef:
|
|
252
|
-
documentId:
|
|
253
|
-
renderedImageUrl:
|
|
254
|
-
makeCallbacks:
|
|
255
|
-
viewRef:
|
|
256
|
-
readOnlyRef:
|
|
257
|
-
toolRef:
|
|
258
|
-
renderShapesRef:
|
|
259
|
-
coordinateSizeRef:
|
|
260
|
-
imageSizeRef:
|
|
261
|
-
selRef:
|
|
262
|
-
regionOverlayRef:
|
|
263
|
-
dimmedRef:
|
|
264
|
-
syncMinimap:
|
|
265
|
-
setImage:
|
|
248
|
+
]), Wn = a(Z);
|
|
249
|
+
ye({
|
|
250
|
+
hostRef: y,
|
|
251
|
+
engineRef: b,
|
|
252
|
+
documentId: T,
|
|
253
|
+
renderedImageUrl: Rt,
|
|
254
|
+
makeCallbacks: Un,
|
|
255
|
+
viewRef: Vn,
|
|
256
|
+
readOnlyRef: F,
|
|
257
|
+
toolRef: M,
|
|
258
|
+
renderShapesRef: Wn,
|
|
259
|
+
coordinateSizeRef: Qt,
|
|
260
|
+
imageSizeRef: $t,
|
|
261
|
+
selRef: z,
|
|
262
|
+
regionOverlayRef: Yt,
|
|
263
|
+
dimmedRef: Xt,
|
|
264
|
+
syncMinimap: K,
|
|
265
|
+
setImage: Ct,
|
|
266
266
|
setImageVisible: Tt,
|
|
267
267
|
setReady: Et,
|
|
268
|
-
setImageStatus:
|
|
269
|
-
onContextMenuRequest:
|
|
270
|
-
}),
|
|
271
|
-
|
|
268
|
+
setImageStatus: Wt,
|
|
269
|
+
onContextMenuRequest: w
|
|
270
|
+
}), s(() => {
|
|
271
|
+
b.current?.setShapes(Z, z.current), K();
|
|
272
272
|
}, [
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
]),
|
|
277
|
-
|
|
278
|
-
}, [
|
|
279
|
-
|
|
280
|
-
}, [
|
|
281
|
-
let
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
}, [
|
|
285
|
-
|
|
286
|
-
}, [m,
|
|
287
|
-
|
|
288
|
-
}, [
|
|
289
|
-
let e =
|
|
290
|
-
e && (e.setFilter(
|
|
273
|
+
Z,
|
|
274
|
+
z,
|
|
275
|
+
K
|
|
276
|
+
]), s(() => {
|
|
277
|
+
b.current?.setSelection(R);
|
|
278
|
+
}, [R]), s(() => {
|
|
279
|
+
b.current?.setEditing(W);
|
|
280
|
+
}, [W, S]);
|
|
281
|
+
let Gn = a(dt);
|
|
282
|
+
s(() => {
|
|
283
|
+
Gn.current?.(W);
|
|
284
|
+
}, [W]), c(() => {
|
|
285
|
+
L.current?.cancelGesture(), G(null);
|
|
286
|
+
}, [m, T]), s(() => {
|
|
287
|
+
W && (R.length !== 1 || R[0] !== W) && G(null);
|
|
288
|
+
}, [R, W]), s(() => {
|
|
289
|
+
let e = b.current;
|
|
290
|
+
e && (e.setFilter(A.brightness, A.contrast), e.setRenderDefaults({ strokeWidth: A.strokeSize }), e.setImageSmoothing(A.imageSmoothing), K());
|
|
291
291
|
}, [
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
]),
|
|
298
|
-
S &&
|
|
292
|
+
A.brightness,
|
|
293
|
+
A.contrast,
|
|
294
|
+
A.strokeSize,
|
|
295
|
+
A.imageSmoothing,
|
|
296
|
+
K
|
|
297
|
+
]), c(() => {
|
|
298
|
+
S && b.current?.setOverlays(A.showRegionMask ? j : null, Ae);
|
|
299
299
|
}, [
|
|
300
300
|
S,
|
|
301
|
-
|
|
302
|
-
|
|
301
|
+
j,
|
|
302
|
+
A.showRegionMask,
|
|
303
303
|
Ae
|
|
304
|
-
]),
|
|
305
|
-
!S || !
|
|
304
|
+
]), s(() => {
|
|
305
|
+
!S || !x || K();
|
|
306
306
|
}, [
|
|
307
307
|
S,
|
|
308
|
-
|
|
309
|
-
|
|
308
|
+
x,
|
|
309
|
+
A.showRegionMask,
|
|
310
310
|
v,
|
|
311
|
-
|
|
312
|
-
]),
|
|
313
|
-
S &&
|
|
311
|
+
K
|
|
312
|
+
]), s(() => {
|
|
313
|
+
S && b.current?.setTransformEnabled(!P && m !== ee.BRUSH);
|
|
314
314
|
}, [
|
|
315
|
-
|
|
315
|
+
P,
|
|
316
316
|
S,
|
|
317
317
|
m
|
|
318
|
-
]),
|
|
319
|
-
g &&
|
|
320
|
-
}, [g]),
|
|
321
|
-
|
|
322
|
-
}, [m,
|
|
323
|
-
let
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
}, [m,
|
|
327
|
-
|
|
328
|
-
}, [m,
|
|
329
|
-
|
|
318
|
+
]), s(() => {
|
|
319
|
+
g && G(null);
|
|
320
|
+
}, [g]), s(() => {
|
|
321
|
+
Mn(m, O.current.has(m));
|
|
322
|
+
}, [m, Mn]);
|
|
323
|
+
let Q = Y.finalize;
|
|
324
|
+
s(() => {
|
|
325
|
+
Q();
|
|
326
|
+
}, [m, Q]), s(() => {
|
|
327
|
+
V.current = "idle", H.current = null, U();
|
|
328
|
+
}, [m, U]), s(() => {
|
|
329
|
+
Nn(R, P);
|
|
330
330
|
}, [
|
|
331
|
-
|
|
331
|
+
R,
|
|
332
332
|
m,
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
]),
|
|
336
|
-
S &&
|
|
333
|
+
P,
|
|
334
|
+
Nn
|
|
335
|
+
]), s(() => {
|
|
336
|
+
S && U();
|
|
337
337
|
}, [
|
|
338
338
|
m,
|
|
339
|
-
|
|
340
|
-
|
|
339
|
+
Dt,
|
|
340
|
+
D,
|
|
341
341
|
S,
|
|
342
|
-
|
|
342
|
+
U
|
|
343
343
|
]);
|
|
344
|
-
let
|
|
345
|
-
|
|
346
|
-
let e =
|
|
347
|
-
|
|
344
|
+
let Kn = a(Lt), $ = p !== null, qn = u(null);
|
|
345
|
+
s(() => {
|
|
346
|
+
let e = $ ? T : null;
|
|
347
|
+
qn.current !== e && (qn.current = e, w(null), G(null), V.current = "idle", H.current = null, E.reset($ ? It ?? [] : []), B($ ? Kn.current ?? [] : []), Dn(), Q(), U());
|
|
348
348
|
}, [
|
|
349
|
+
$,
|
|
350
|
+
T,
|
|
351
|
+
It,
|
|
352
|
+
E.reset,
|
|
353
|
+
B,
|
|
354
|
+
Dn,
|
|
349
355
|
Q,
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
T.reset,
|
|
353
|
-
z,
|
|
354
|
-
On,
|
|
355
|
-
Z,
|
|
356
|
-
H
|
|
357
|
-
]), ge({
|
|
356
|
+
U
|
|
357
|
+
]), _e({
|
|
358
358
|
keymap: st,
|
|
359
|
-
hostRef:
|
|
360
|
-
actions:
|
|
361
|
-
history:
|
|
362
|
-
selection:
|
|
363
|
-
drawSession:
|
|
364
|
-
assistant:
|
|
365
|
-
controller: () =>
|
|
366
|
-
externalTool: () =>
|
|
367
|
-
hasSelection: () =>
|
|
368
|
-
rejectLockedEdit:
|
|
369
|
-
editLocked:
|
|
370
|
-
editingId:
|
|
371
|
-
setEditingId:
|
|
359
|
+
hostRef: y,
|
|
360
|
+
actions: de({
|
|
361
|
+
history: In,
|
|
362
|
+
selection: X,
|
|
363
|
+
drawSession: J,
|
|
364
|
+
assistant: Y,
|
|
365
|
+
controller: () => L.current,
|
|
366
|
+
externalTool: () => O.current.get(M.current),
|
|
367
|
+
hasSelection: () => z.current.length > 0,
|
|
368
|
+
rejectLockedEdit: cn,
|
|
369
|
+
editLocked: P,
|
|
370
|
+
editingId: W,
|
|
371
|
+
setEditingId: G,
|
|
372
372
|
vertexEditTarget: () => {
|
|
373
|
-
let e =
|
|
373
|
+
let e = z.current;
|
|
374
374
|
if (e.length !== 1) return null;
|
|
375
|
-
let n =
|
|
375
|
+
let n = I.current.getShapes().find((t) => t.id === e[0]);
|
|
376
376
|
return n && t(n) ? n.id : null;
|
|
377
377
|
},
|
|
378
|
-
deleteEditingVertices:
|
|
379
|
-
let t =
|
|
380
|
-
if (!t ||
|
|
381
|
-
let n =
|
|
378
|
+
deleteEditingVertices: o(() => {
|
|
379
|
+
let t = gn.current;
|
|
380
|
+
if (!t || P) return !1;
|
|
381
|
+
let n = b.current, r = new Set(n?.getVertexSelection() ?? []);
|
|
382
382
|
if (!r.size) return !1;
|
|
383
|
-
let i =
|
|
383
|
+
let i = I.current.getShapes().find((e) => e.id === t);
|
|
384
384
|
if (!i) return !1;
|
|
385
|
-
let
|
|
386
|
-
return
|
|
385
|
+
let ee = i.points.filter((e, t) => !r.has(t)), te = i.type === e.LINE ? 2 : 3;
|
|
386
|
+
return ee.length < te ? !1 : (I.current.update([{
|
|
387
387
|
...i,
|
|
388
|
-
points:
|
|
388
|
+
points: ee
|
|
389
389
|
}]), n?.setVertexSelection([]), !0);
|
|
390
|
-
}, [
|
|
391
|
-
zoomAtCenter:
|
|
392
|
-
zoom100: () =>
|
|
393
|
-
zoomFit: () =>
|
|
394
|
-
toggleMinimap: () =>
|
|
395
|
-
toggleCursorGuide: () =>
|
|
390
|
+
}, [P]),
|
|
391
|
+
zoomAtCenter: Bn,
|
|
392
|
+
zoom100: () => b.current?.zoom100(),
|
|
393
|
+
zoomFit: () => b.current?.fit(),
|
|
394
|
+
toggleMinimap: () => At((e) => !e),
|
|
395
|
+
toggleCursorGuide: () => qt((e) => ({
|
|
396
396
|
...e,
|
|
397
397
|
showCursorGuide: !e.showCursorGuide
|
|
398
398
|
})),
|
|
399
|
-
togglePixelation: () =>
|
|
399
|
+
togglePixelation: () => qt((e) => ({
|
|
400
400
|
...e,
|
|
401
401
|
imageSmoothing: !e.imageSmoothing
|
|
402
402
|
})),
|
|
403
403
|
selectTool: (e) => lt?.(e),
|
|
404
404
|
onIdleEscape: Le
|
|
405
405
|
}),
|
|
406
|
-
spaceRef:
|
|
406
|
+
spaceRef: dn,
|
|
407
407
|
onSpaceDown: () => {
|
|
408
|
-
|
|
408
|
+
b.current?.setPanMode(!0), U();
|
|
409
409
|
},
|
|
410
410
|
onSpaceUp: () => {
|
|
411
|
-
|
|
411
|
+
b.current?.setPanMode(!1), V.current === "panning" ? fn("idle") : U();
|
|
412
412
|
},
|
|
413
|
-
nudge: (e, t) =>
|
|
413
|
+
nudge: (e, t) => cn(X.getEditableSelection().length > 0) || X.nudgeSelection(e, t)
|
|
414
414
|
});
|
|
415
|
-
let
|
|
416
|
-
strings:
|
|
415
|
+
let Jn = l(() => Z.filter((e) => R.includes(e.id) && r(e)), [Z, R]), Yn = l(() => q.drawPreviewShape ? [...Jn, q.drawPreviewShape] : Jn, [Jn, q.drawPreviewShape]), Xn = C ? ue({
|
|
416
|
+
strings: k.contextMenu,
|
|
417
417
|
point: C.img,
|
|
418
|
-
shapes:
|
|
419
|
-
selectedIds:
|
|
418
|
+
shapes: E.shapes,
|
|
419
|
+
selectedIds: R,
|
|
420
420
|
hostReadOnly: !!Ne,
|
|
421
|
-
editLocked:
|
|
422
|
-
selection:
|
|
421
|
+
editLocked: P,
|
|
422
|
+
selection: X,
|
|
423
423
|
canMergeSelection: qe,
|
|
424
|
-
history:
|
|
425
|
-
enterVertexEdit:
|
|
426
|
-
zoomToSelection:
|
|
427
|
-
refineShape: ot ?
|
|
424
|
+
history: In,
|
|
425
|
+
enterVertexEdit: G,
|
|
426
|
+
zoomToSelection: zn,
|
|
427
|
+
refineShape: ot ? Y.refineShape : void 0
|
|
428
428
|
}) : [], Zn = C && We ? We(Xn, {
|
|
429
|
-
selectedIds:
|
|
430
|
-
readOnly:
|
|
431
|
-
}) : Xn, Qn =
|
|
432
|
-
engineRef:
|
|
433
|
-
image:
|
|
434
|
-
wheelZoom:
|
|
429
|
+
selectedIds: R,
|
|
430
|
+
readOnly: P
|
|
431
|
+
}) : Xn, Qn = be({
|
|
432
|
+
engineRef: b,
|
|
433
|
+
image: x,
|
|
434
|
+
wheelZoom: A.wheelZoom,
|
|
435
435
|
minimapSize: 204
|
|
436
|
-
}), $n =
|
|
437
|
-
|
|
438
|
-
}, []), er =
|
|
439
|
-
|
|
440
|
-
}, []), tr =
|
|
441
|
-
|
|
442
|
-
}, []), nr =
|
|
443
|
-
|
|
436
|
+
}), $n = o(() => {
|
|
437
|
+
b.current?.zoom100();
|
|
438
|
+
}, []), er = o(() => {
|
|
439
|
+
At((e) => !e);
|
|
440
|
+
}, []), tr = o(() => {
|
|
441
|
+
Mt((e) => !e);
|
|
442
|
+
}, []), nr = o(() => {
|
|
443
|
+
Mt(!1);
|
|
444
444
|
}, []);
|
|
445
|
-
return /* @__PURE__ */
|
|
445
|
+
return /* @__PURE__ */ De("div", {
|
|
446
446
|
className: "aivex:relative aivex:h-full aivex:w-full aivex:overflow-hidden aivex:bg-black",
|
|
447
447
|
children: [
|
|
448
|
-
/* @__PURE__ */
|
|
449
|
-
ref:
|
|
448
|
+
/* @__PURE__ */ f("div", {
|
|
449
|
+
ref: y,
|
|
450
450
|
role: "application",
|
|
451
|
-
"aria-label":
|
|
451
|
+
"aria-label": k.canvasLabel,
|
|
452
452
|
tabIndex: 0,
|
|
453
453
|
onPointerDownCapture: (e) => e.currentTarget.focus({ preventScroll: !0 }),
|
|
454
454
|
className: "aivex:h-full aivex:w-full",
|
|
455
455
|
style: {
|
|
456
|
-
opacity: +!!
|
|
457
|
-
transition:
|
|
456
|
+
opacity: +!!wt,
|
|
457
|
+
transition: wt ? "opacity 0.3s ease" : "none"
|
|
458
458
|
}
|
|
459
459
|
}),
|
|
460
|
-
|
|
461
|
-
status:
|
|
462
|
-
error:
|
|
460
|
+
Vt !== "ready" && /* @__PURE__ */ f(ie, {
|
|
461
|
+
status: Vt,
|
|
462
|
+
error: Ht,
|
|
463
463
|
render: ke,
|
|
464
|
-
loadingLabel:
|
|
465
|
-
missingLabel:
|
|
466
|
-
errorLabel:
|
|
467
|
-
errorHints:
|
|
464
|
+
loadingLabel: k.imageLoading,
|
|
465
|
+
missingLabel: k.imageMissing,
|
|
466
|
+
errorLabel: k.imageLoadError,
|
|
467
|
+
errorHints: k.imageErrorHints
|
|
468
468
|
}),
|
|
469
|
-
S &&
|
|
469
|
+
S && x && /* @__PURE__ */ De("div", {
|
|
470
470
|
className: "aivex:pointer-events-none aivex:absolute aivex:inset-0 aivex:overflow-hidden",
|
|
471
|
-
children: [Yn.length > 0 && /* @__PURE__ */
|
|
471
|
+
children: [Yn.length > 0 && /* @__PURE__ */ f("div", {
|
|
472
472
|
className: "aivex:absolute aivex:inset-0",
|
|
473
|
-
children: /* @__PURE__ */
|
|
473
|
+
children: /* @__PURE__ */ f(oe, {
|
|
474
474
|
shapes: Yn,
|
|
475
475
|
getLabel: nt,
|
|
476
476
|
hideDot: rt,
|
|
477
477
|
formatInfo: it,
|
|
478
|
-
register:
|
|
479
|
-
viewport:
|
|
478
|
+
register: q.register,
|
|
479
|
+
viewport: b.current?.viewport ?? {
|
|
480
480
|
scale: 1,
|
|
481
481
|
x: 0,
|
|
482
482
|
y: 0
|
|
483
483
|
}
|
|
484
484
|
})
|
|
485
|
-
}), /* @__PURE__ */
|
|
486
|
-
ref:
|
|
485
|
+
}), /* @__PURE__ */ De("div", {
|
|
486
|
+
ref: bt,
|
|
487
487
|
style: {
|
|
488
488
|
position: "absolute",
|
|
489
489
|
top: 0,
|
|
490
490
|
left: 0,
|
|
491
|
-
width:
|
|
492
|
-
height:
|
|
491
|
+
width: x.w,
|
|
492
|
+
height: x.h,
|
|
493
493
|
transformOrigin: "0 0"
|
|
494
494
|
},
|
|
495
495
|
children: [
|
|
496
|
-
!!Qe?.length && $e && /* @__PURE__ */
|
|
496
|
+
!!Qe?.length && $e && /* @__PURE__ */ f("div", {
|
|
497
497
|
style: {
|
|
498
498
|
position: "absolute",
|
|
499
499
|
left: 0,
|
|
500
500
|
top: 0,
|
|
501
|
-
width:
|
|
502
|
-
height:
|
|
501
|
+
width: x.w,
|
|
502
|
+
height: x.h,
|
|
503
503
|
pointerEvents: "none"
|
|
504
504
|
},
|
|
505
|
-
children: Qe.map((e) => /* @__PURE__ */
|
|
505
|
+
children: Qe.map((e) => /* @__PURE__ */ f("div", {
|
|
506
506
|
role: e.disabled ? void 0 : "button",
|
|
507
507
|
tabIndex: e.disabled ? void 0 : 0,
|
|
508
508
|
"aria-pressed": e.selected || void 0,
|
|
@@ -526,55 +526,55 @@ function p({ document: p, clipboardScope: Oe, renderImageState: ke, dimmed: Ae =
|
|
|
526
526
|
}, e.id))
|
|
527
527
|
}),
|
|
528
528
|
tt?.({
|
|
529
|
-
image:
|
|
530
|
-
viewport:
|
|
529
|
+
image: x,
|
|
530
|
+
viewport: b.current?.viewport ?? {
|
|
531
531
|
scale: 1,
|
|
532
532
|
x: 0,
|
|
533
533
|
y: 0
|
|
534
534
|
}
|
|
535
535
|
}),
|
|
536
|
-
ot && (
|
|
537
|
-
image:
|
|
538
|
-
points:
|
|
539
|
-
boxes:
|
|
540
|
-
status:
|
|
536
|
+
ot && (Y.status === "loading" || Y.boxes.length > 0) && /* @__PURE__ */ f(te, {
|
|
537
|
+
image: x,
|
|
538
|
+
points: Y.points,
|
|
539
|
+
boxes: Y.boxes,
|
|
540
|
+
status: Y.status
|
|
541
541
|
})
|
|
542
542
|
]
|
|
543
543
|
})]
|
|
544
544
|
}),
|
|
545
|
-
S &&
|
|
546
|
-
|
|
547
|
-
image:
|
|
548
|
-
imageUrl:
|
|
549
|
-
imageVisible:
|
|
545
|
+
S && A.showCursorGuide && /* @__PURE__ */ f(re, { color: "#1e88e5" }),
|
|
546
|
+
x && Ve && /* @__PURE__ */ f(ae, {
|
|
547
|
+
image: x,
|
|
548
|
+
imageUrl: Rt,
|
|
549
|
+
imageVisible: wt,
|
|
550
550
|
loading: !S,
|
|
551
|
-
region:
|
|
552
|
-
roiMaskId:
|
|
553
|
-
shapes:
|
|
554
|
-
view:
|
|
555
|
-
viewDefaults:
|
|
556
|
-
onChangeView:
|
|
551
|
+
region: j,
|
|
552
|
+
roiMaskId: St,
|
|
553
|
+
shapes: Z,
|
|
554
|
+
view: A,
|
|
555
|
+
viewDefaults: Kt,
|
|
556
|
+
onChangeView: Jt,
|
|
557
557
|
nav: Qn,
|
|
558
|
-
registerShape:
|
|
559
|
-
rectRef:
|
|
560
|
-
zoomLabelRef:
|
|
558
|
+
registerShape: yn,
|
|
559
|
+
rectRef: yt,
|
|
560
|
+
zoomLabelRef: xt,
|
|
561
561
|
onZoom100: $n,
|
|
562
|
-
open:
|
|
562
|
+
open: kt,
|
|
563
563
|
onToggleOpen: er,
|
|
564
564
|
position: He,
|
|
565
|
-
labels:
|
|
566
|
-
settingsLabels:
|
|
565
|
+
labels: k.minimap,
|
|
566
|
+
settingsLabels: k.viewSettings,
|
|
567
567
|
settingsItems: Ke,
|
|
568
568
|
showSettings: Ue,
|
|
569
|
-
settingsOpen:
|
|
569
|
+
settingsOpen: jt,
|
|
570
570
|
onToggleSettings: tr,
|
|
571
571
|
onCloseSettings: nr
|
|
572
572
|
}),
|
|
573
|
-
C && /* @__PURE__ */
|
|
573
|
+
C && /* @__PURE__ */ f(ne, {
|
|
574
574
|
x: C.x,
|
|
575
575
|
y: C.y,
|
|
576
576
|
items: Zn,
|
|
577
|
-
onClose: () =>
|
|
577
|
+
onClose: () => w(null)
|
|
578
578
|
})
|
|
579
579
|
]
|
|
580
580
|
});
|