@dwelle/excalidraw 0.4.0-c863147 → 0.4.0-c8d325d
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/CHANGELOG.md +22 -1
- package/README.md +4 -0
- package/dist/excalidraw-assets/{vendor-2002fe1b8862917b36c1.js → vendor-d415b28e9024dee4bb1b.js} +2 -2
- package/dist/excalidraw-assets-dev/{vendor-e6df8519da951026ff69.js → vendor-a14cd58fa2db417e42b2.js} +6 -6
- package/dist/excalidraw.development.js +2103 -1697
- package/dist/excalidraw.production.min.js +1 -1
- package/dist/excalidraw.production.min.js.LICENSE.txt +15 -0
- package/package.json +7 -2
- package/types/actions/actionAddToLibrary.d.ts +63 -22
- package/types/actions/actionAlign.d.ts +25 -20
- package/types/actions/actionBoundText.d.ts +46 -18
- package/types/actions/actionCanvas.d.ts +350 -78
- package/types/actions/actionClipboard.d.ts +101 -35
- package/types/actions/actionDeleteSelected.d.ts +57 -19
- package/types/actions/actionDistribute.d.ts +7 -8
- package/types/actions/actionDuplicateSelection.d.ts +0 -1
- package/types/actions/actionElementLock.d.ts +44 -16
- package/types/actions/actionExport.d.ts +198 -72
- package/types/actions/actionFinalize.d.ts +40 -16
- package/types/actions/actionFlip.d.ts +4 -5
- package/types/actions/actionFrame.d.ts +423 -0
- package/types/actions/actionGroup.d.ts +246 -9
- package/types/actions/actionLinearEditor.d.ts +23 -10
- package/types/actions/actionMenu.d.ts +64 -24
- package/types/actions/actionNavigate.d.ts +1 -1
- package/types/actions/actionProperties.d.ts +273 -92
- package/types/actions/actionSelectAll.d.ts +121 -2
- package/types/actions/actionStyles.d.ts +21 -8
- package/types/actions/actionToggleGridMode.d.ts +21 -8
- package/types/actions/actionToggleStats.d.ts +21 -8
- package/types/actions/actionToggleViewMode.d.ts +21 -8
- package/types/actions/actionToggleZenMode.d.ts +21 -8
- package/types/actions/actionZindex.d.ts +4 -4
- package/types/actions/manager.d.ts +1 -1
- package/types/actions/types.d.ts +4 -3
- package/types/appState.d.ts +9 -9
- package/types/clients.d.ts +1 -5
- package/types/clipboard.d.ts +1 -0
- package/types/colors.d.ts +10 -9
- package/types/components/Actions.d.ts +2 -2
- package/types/components/ActiveConfirmDialog.d.ts +1 -21
- package/types/components/App.d.ts +48 -13
- package/types/components/Avatar.d.ts +0 -1
- package/types/components/Button.d.ts +0 -1
- package/types/components/Card.d.ts +0 -1
- package/types/components/ColorPicker/ColorInput.d.ts +1 -1
- package/types/components/ColorPicker/ColorPicker.d.ts +3 -2
- package/types/components/ColorPicker/CustomColorList.d.ts +1 -1
- package/types/components/ColorPicker/Picker.d.ts +4 -2
- package/types/components/ColorPicker/PickerColorList.d.ts +1 -1
- package/types/components/ColorPicker/ShadeList.d.ts +1 -1
- package/types/components/ColorPicker/TopPicks.d.ts +1 -1
- package/types/components/ColorPicker/colorPickerUtils.d.ts +4 -24
- package/types/components/ColorPicker/keyboardNavHandlers.d.ts +8 -4
- package/types/components/DefaultSidebar.d.ts +0 -1
- package/types/components/Dialog.d.ts +3 -4
- package/types/components/EyeDropper.d.ts +17 -0
- package/types/components/FilledButton.d.ts +17 -0
- package/types/components/HintViewer.d.ts +3 -4
- package/types/components/ImageExportDialog.d.ts +3 -4
- package/types/components/JSONExportDialog.d.ts +1 -1
- package/types/components/LayerUI.d.ts +4 -2
- package/types/components/LibraryMenu.d.ts +5 -23
- package/types/components/LibraryMenuHeaderContent.d.ts +0 -1
- package/types/components/LibraryMenuItems.d.ts +3 -1
- package/types/components/LibraryMenuSection.d.ts +9 -3
- package/types/components/LibraryUnit.d.ts +5 -2
- package/types/components/LoadingMessage.d.ts +0 -1
- package/types/components/MobileMenu.d.ts +4 -3
- package/types/components/OverwriteConfirm/OverwriteConfirm.d.ts +17 -0
- package/types/components/OverwriteConfirm/OverwriteConfirmActions.d.ts +17 -0
- package/types/components/OverwriteConfirm/OverwriteConfirmState.d.ts +22 -0
- package/types/components/ProjectName.d.ts +1 -0
- package/types/components/RadioGroup.d.ts +12 -0
- package/types/components/Section.d.ts +1 -1
- package/types/components/Sidebar/Sidebar.d.ts +1 -21
- package/types/components/Sidebar/SidebarTab.d.ts +0 -1
- package/types/components/Sidebar/SidebarTabTrigger.d.ts +0 -1
- package/types/components/Sidebar/SidebarTabTriggers.d.ts +0 -1
- package/types/components/Sidebar/SidebarTabs.d.ts +0 -1
- package/types/components/Stack.d.ts +3 -2
- package/types/components/Switch.d.ts +9 -0
- package/types/components/ToolButton.d.ts +2 -1
- package/types/components/Trans.d.ts +2 -1
- package/types/components/canvases/InteractiveCanvas.d.ts +26 -0
- package/types/components/canvases/StaticCanvas.d.ts +18 -0
- package/types/components/canvases/index.d.ts +3 -0
- package/types/components/dropdownMenu/DropdownMenu.d.ts +3 -2
- package/types/components/dropdownMenu/DropdownMenuTrigger.d.ts +3 -2
- package/types/components/icons.d.ts +11 -0
- package/types/components/live-collaboration/LiveCollaborationTrigger.d.ts +0 -1
- package/types/components/main-menu/MainMenu.d.ts +3 -2
- package/types/components/welcome-screen/WelcomeScreen.Center.d.ts +0 -1
- package/types/components/welcome-screen/WelcomeScreen.d.ts +0 -1
- package/types/constants.d.ts +32 -8
- package/types/context/tunnels.d.ts +1 -0
- package/types/data/index.d.ts +1 -1
- package/types/data/library.d.ts +3 -45
- package/types/data/transform.d.ts +71 -0
- package/types/data/url.d.ts +7 -0
- package/types/element/Hyperlink.d.ts +31 -14
- package/types/element/binding.d.ts +2 -1
- package/types/element/bounds.d.ts +31 -6
- package/types/element/collision.d.ts +7 -7
- package/types/element/dragElements.d.ts +2 -1
- package/types/element/embeddable.d.ts +153 -0
- package/types/element/index.d.ts +3 -2
- package/types/element/linearElementEditor.d.ts +25 -12
- package/types/element/newElement.d.ts +15 -6
- package/types/element/sizeHelpers.d.ts +8 -1
- package/types/element/textElement.d.ts +5 -7
- package/types/element/textWysiwyg.d.ts +1 -1
- package/types/element/transformHandles.d.ts +10 -3
- package/types/element/typeChecks.d.ts +3 -1
- package/types/element/types.d.ts +19 -3
- package/types/frame.d.ts +40 -0
- package/types/groups.d.ts +14 -11
- package/types/history.d.ts +3 -3
- package/types/hooks/useCreatePortalContainer.d.ts +4 -0
- package/types/hooks/useLibraryItemSvg.d.ts +9 -23
- package/types/hooks/useOutsideClick.d.ts +19 -2
- package/types/hooks/useScrollPosition.d.ts +1 -0
- package/types/i18n.d.ts +5 -2
- package/types/jotai.d.ts +16 -104
- package/types/keys.d.ts +3 -0
- package/types/math.d.ts +1 -0
- package/types/packages/excalidraw/example/initialData.d.ts +182 -64
- package/types/packages/excalidraw/index.d.ts +2 -0
- package/types/packages/excalidraw/webpack.dev.config.d.ts +5 -2
- package/types/packages/excalidraw/webpack.prod.config.d.ts +3 -0
- package/types/packages/utils.d.ts +26 -26
- package/types/renderer/renderElement.d.ts +15 -19
- package/types/renderer/renderScene.d.ts +19 -27
- package/types/renderer/roundRect.d.ts +1 -1
- package/types/scene/Renderer.d.ts +25 -0
- package/types/scene/Scene.d.ts +23 -1
- package/types/scene/ShapeCache.d.ts +24 -0
- package/types/scene/export.d.ts +11 -152
- package/types/scene/scroll.d.ts +1 -1
- package/types/scene/scrollbars.d.ts +2 -6
- package/types/scene/selection.d.ts +25 -5
- package/types/scene/types.d.ts +43 -32
- package/types/types.d.ts +89 -11
- package/types/utility-types.d.ts +3 -1
- package/types/utils.d.ts +58 -20
- package/types/zindex.d.ts +4 -4
- /package/dist/excalidraw-assets/{vendor-2002fe1b8862917b36c1.js.LICENSE.txt → vendor-d415b28e9024dee4bb1b.js.LICENSE.txt} +0 -0
- /package/types/packages/excalidraw/dist/excalidraw-assets/{vendor-2002fe1b8862917b36c1.d.ts → vendor-d415b28e9024dee4bb1b.d.ts} +0 -0
- /package/types/packages/excalidraw/dist/excalidraw-assets-dev/{vendor-e6df8519da951026ff69.d.ts → vendor-a14cd58fa2db417e42b2.d.ts} +0 -0
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
1
|
import { ExcalidrawElement } from "../element/types";
|
|
3
2
|
import { AppState, NormalizedZoomValue } from "../types";
|
|
4
3
|
export declare const actionChangeViewBackgroundColor: {
|
|
@@ -23,7 +22,7 @@ export declare const actionClearCanvas: {
|
|
|
23
22
|
elements: ExcalidrawElement[];
|
|
24
23
|
appState: {
|
|
25
24
|
files: {};
|
|
26
|
-
theme:
|
|
25
|
+
theme: import("../element/types").Theme;
|
|
27
26
|
penMode: boolean;
|
|
28
27
|
penDetected: boolean;
|
|
29
28
|
exportBackground: boolean;
|
|
@@ -41,13 +40,19 @@ export declare const actionClearCanvas: {
|
|
|
41
40
|
lastActiveTool: import("../types").LastActiveTool;
|
|
42
41
|
locked: boolean;
|
|
43
42
|
} & ({
|
|
44
|
-
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser" | "hand";
|
|
43
|
+
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "embeddable" | "image" | "frame" | "freedraw" | "eraser" | "hand";
|
|
45
44
|
customType: null;
|
|
46
45
|
} | {
|
|
47
46
|
type: "custom";
|
|
48
47
|
customType: string;
|
|
49
48
|
});
|
|
50
49
|
name: string;
|
|
50
|
+
toast: {
|
|
51
|
+
message: string;
|
|
52
|
+
closable?: boolean | undefined;
|
|
53
|
+
duration?: number | undefined;
|
|
54
|
+
} | null;
|
|
55
|
+
collaborators: Map<string, import("../types").Collaborator>;
|
|
51
56
|
contextMenu: {
|
|
52
57
|
items: import("../components/ContextMenu").ContextMenuItems;
|
|
53
58
|
top: number;
|
|
@@ -56,6 +61,10 @@ export declare const actionClearCanvas: {
|
|
|
56
61
|
showWelcomeScreen: boolean;
|
|
57
62
|
isLoading: boolean;
|
|
58
63
|
errorMessage: import("react").ReactNode;
|
|
64
|
+
activeEmbeddable: {
|
|
65
|
+
element: import("../element/types").NonDeletedExcalidrawElement;
|
|
66
|
+
state: "active" | "hover";
|
|
67
|
+
} | null;
|
|
59
68
|
draggingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
60
69
|
resizingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
61
70
|
multiElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawLinearElement> | null;
|
|
@@ -63,6 +72,15 @@ export declare const actionClearCanvas: {
|
|
|
63
72
|
isBindingEnabled: boolean;
|
|
64
73
|
startBoundElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawBindableElement> | null;
|
|
65
74
|
suggestedBindings: import("../element/binding").SuggestedBinding[];
|
|
75
|
+
frameToHighlight: import("../element/types").NonDeleted<import("../element/types").ExcalidrawFrameElement> | null;
|
|
76
|
+
frameRendering: {
|
|
77
|
+
enabled: boolean;
|
|
78
|
+
name: boolean;
|
|
79
|
+
outline: boolean;
|
|
80
|
+
clip: boolean;
|
|
81
|
+
};
|
|
82
|
+
editingFrame: string | null;
|
|
83
|
+
elementsToHighlight: import("../element/types").NonDeleted<ExcalidrawElement>[] | null;
|
|
66
84
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
67
85
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
68
86
|
exportWithDarkMode: boolean;
|
|
@@ -99,18 +117,14 @@ export declare const actionClearCanvas: {
|
|
|
99
117
|
openDialog: "imageExport" | "help" | "jsonExport" | null;
|
|
100
118
|
defaultSidebarDockedPreference: boolean;
|
|
101
119
|
lastPointerDownWith: import("../element/types").PointerType;
|
|
102
|
-
selectedElementIds: {
|
|
103
|
-
[id: string]:
|
|
104
|
-
}
|
|
120
|
+
selectedElementIds: Readonly<{
|
|
121
|
+
[id: string]: true;
|
|
122
|
+
}>;
|
|
105
123
|
previousSelectedElementIds: {
|
|
106
|
-
[id: string]:
|
|
124
|
+
[id: string]: true;
|
|
107
125
|
};
|
|
126
|
+
selectedElementsAreBeingDragged: boolean;
|
|
108
127
|
shouldCacheIgnoreZoom: boolean;
|
|
109
|
-
toast: {
|
|
110
|
-
message: string;
|
|
111
|
-
closable?: boolean | undefined;
|
|
112
|
-
duration?: number | undefined;
|
|
113
|
-
} | null;
|
|
114
128
|
zenModeEnabled: boolean;
|
|
115
129
|
viewModeEnabled: boolean;
|
|
116
130
|
selectedGroupIds: {
|
|
@@ -118,10 +132,9 @@ export declare const actionClearCanvas: {
|
|
|
118
132
|
};
|
|
119
133
|
editingGroupId: string | null;
|
|
120
134
|
fileHandle: import("browser-fs-access").FileSystemHandle | null;
|
|
121
|
-
collaborators: Map<string, import("../types").Collaborator>;
|
|
122
135
|
currentChartType: import("../element/types").ChartType;
|
|
123
136
|
pendingImageElementId: string | null;
|
|
124
|
-
showHyperlinkPopup: false | "
|
|
137
|
+
showHyperlinkPopup: false | "editor" | "info";
|
|
125
138
|
selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
126
139
|
};
|
|
127
140
|
commitToHistory: true;
|
|
@@ -150,6 +163,10 @@ export declare const actionZoomIn: {
|
|
|
150
163
|
showWelcomeScreen: boolean;
|
|
151
164
|
isLoading: boolean;
|
|
152
165
|
errorMessage: import("react").ReactNode;
|
|
166
|
+
activeEmbeddable: {
|
|
167
|
+
element: import("../element/types").NonDeletedExcalidrawElement;
|
|
168
|
+
state: "active" | "hover";
|
|
169
|
+
} | null;
|
|
153
170
|
draggingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
154
171
|
resizingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
155
172
|
multiElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawLinearElement> | null;
|
|
@@ -157,13 +174,22 @@ export declare const actionZoomIn: {
|
|
|
157
174
|
isBindingEnabled: boolean;
|
|
158
175
|
startBoundElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawBindableElement> | null;
|
|
159
176
|
suggestedBindings: import("../element/binding").SuggestedBinding[];
|
|
177
|
+
frameToHighlight: import("../element/types").NonDeleted<import("../element/types").ExcalidrawFrameElement> | null;
|
|
178
|
+
frameRendering: {
|
|
179
|
+
enabled: boolean;
|
|
180
|
+
name: boolean;
|
|
181
|
+
outline: boolean;
|
|
182
|
+
clip: boolean;
|
|
183
|
+
};
|
|
184
|
+
editingFrame: string | null;
|
|
185
|
+
elementsToHighlight: import("../element/types").NonDeleted<ExcalidrawElement>[] | null;
|
|
160
186
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
161
187
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
162
188
|
activeTool: {
|
|
163
189
|
lastActiveTool: import("../types").LastActiveTool;
|
|
164
190
|
locked: boolean;
|
|
165
191
|
} & ({
|
|
166
|
-
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser" | "hand";
|
|
192
|
+
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "embeddable" | "image" | "frame" | "freedraw" | "eraser" | "hand";
|
|
167
193
|
customType: null;
|
|
168
194
|
} | {
|
|
169
195
|
type: "custom";
|
|
@@ -203,12 +229,13 @@ export declare const actionZoomIn: {
|
|
|
203
229
|
openDialog: "imageExport" | "help" | "jsonExport" | null;
|
|
204
230
|
defaultSidebarDockedPreference: boolean;
|
|
205
231
|
lastPointerDownWith: import("../element/types").PointerType;
|
|
206
|
-
selectedElementIds: {
|
|
207
|
-
[id: string]:
|
|
208
|
-
}
|
|
232
|
+
selectedElementIds: Readonly<{
|
|
233
|
+
[id: string]: true;
|
|
234
|
+
}>;
|
|
209
235
|
previousSelectedElementIds: {
|
|
210
|
-
[id: string]:
|
|
236
|
+
[id: string]: true;
|
|
211
237
|
};
|
|
238
|
+
selectedElementsAreBeingDragged: boolean;
|
|
212
239
|
shouldCacheIgnoreZoom: boolean;
|
|
213
240
|
toast: {
|
|
214
241
|
message: string;
|
|
@@ -216,7 +243,7 @@ export declare const actionZoomIn: {
|
|
|
216
243
|
duration?: number | undefined;
|
|
217
244
|
} | null;
|
|
218
245
|
zenModeEnabled: boolean;
|
|
219
|
-
theme:
|
|
246
|
+
theme: import("../element/types").Theme;
|
|
220
247
|
gridSize: number | null;
|
|
221
248
|
viewModeEnabled: boolean;
|
|
222
249
|
selectedGroupIds: {
|
|
@@ -239,7 +266,7 @@ export declare const actionZoomIn: {
|
|
|
239
266
|
data: import("../charts").Spreadsheet;
|
|
240
267
|
};
|
|
241
268
|
pendingImageElementId: string | null;
|
|
242
|
-
showHyperlinkPopup: false | "
|
|
269
|
+
showHyperlinkPopup: false | "editor" | "info";
|
|
243
270
|
selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
244
271
|
};
|
|
245
272
|
commitToHistory: false;
|
|
@@ -270,6 +297,10 @@ export declare const actionZoomOut: {
|
|
|
270
297
|
showWelcomeScreen: boolean;
|
|
271
298
|
isLoading: boolean;
|
|
272
299
|
errorMessage: import("react").ReactNode;
|
|
300
|
+
activeEmbeddable: {
|
|
301
|
+
element: import("../element/types").NonDeletedExcalidrawElement;
|
|
302
|
+
state: "active" | "hover";
|
|
303
|
+
} | null;
|
|
273
304
|
draggingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
274
305
|
resizingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
275
306
|
multiElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawLinearElement> | null;
|
|
@@ -277,13 +308,22 @@ export declare const actionZoomOut: {
|
|
|
277
308
|
isBindingEnabled: boolean;
|
|
278
309
|
startBoundElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawBindableElement> | null;
|
|
279
310
|
suggestedBindings: import("../element/binding").SuggestedBinding[];
|
|
311
|
+
frameToHighlight: import("../element/types").NonDeleted<import("../element/types").ExcalidrawFrameElement> | null;
|
|
312
|
+
frameRendering: {
|
|
313
|
+
enabled: boolean;
|
|
314
|
+
name: boolean;
|
|
315
|
+
outline: boolean;
|
|
316
|
+
clip: boolean;
|
|
317
|
+
};
|
|
318
|
+
editingFrame: string | null;
|
|
319
|
+
elementsToHighlight: import("../element/types").NonDeleted<ExcalidrawElement>[] | null;
|
|
280
320
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
281
321
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
282
322
|
activeTool: {
|
|
283
323
|
lastActiveTool: import("../types").LastActiveTool;
|
|
284
324
|
locked: boolean;
|
|
285
325
|
} & ({
|
|
286
|
-
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser" | "hand";
|
|
326
|
+
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "embeddable" | "image" | "frame" | "freedraw" | "eraser" | "hand";
|
|
287
327
|
customType: null;
|
|
288
328
|
} | {
|
|
289
329
|
type: "custom";
|
|
@@ -323,12 +363,13 @@ export declare const actionZoomOut: {
|
|
|
323
363
|
openDialog: "imageExport" | "help" | "jsonExport" | null;
|
|
324
364
|
defaultSidebarDockedPreference: boolean;
|
|
325
365
|
lastPointerDownWith: import("../element/types").PointerType;
|
|
326
|
-
selectedElementIds: {
|
|
327
|
-
[id: string]:
|
|
328
|
-
}
|
|
366
|
+
selectedElementIds: Readonly<{
|
|
367
|
+
[id: string]: true;
|
|
368
|
+
}>;
|
|
329
369
|
previousSelectedElementIds: {
|
|
330
|
-
[id: string]:
|
|
370
|
+
[id: string]: true;
|
|
331
371
|
};
|
|
372
|
+
selectedElementsAreBeingDragged: boolean;
|
|
332
373
|
shouldCacheIgnoreZoom: boolean;
|
|
333
374
|
toast: {
|
|
334
375
|
message: string;
|
|
@@ -336,7 +377,7 @@ export declare const actionZoomOut: {
|
|
|
336
377
|
duration?: number | undefined;
|
|
337
378
|
} | null;
|
|
338
379
|
zenModeEnabled: boolean;
|
|
339
|
-
theme:
|
|
380
|
+
theme: import("../element/types").Theme;
|
|
340
381
|
gridSize: number | null;
|
|
341
382
|
viewModeEnabled: boolean;
|
|
342
383
|
selectedGroupIds: {
|
|
@@ -359,7 +400,7 @@ export declare const actionZoomOut: {
|
|
|
359
400
|
data: import("../charts").Spreadsheet;
|
|
360
401
|
};
|
|
361
402
|
pendingImageElementId: string | null;
|
|
362
|
-
showHyperlinkPopup: false | "
|
|
403
|
+
showHyperlinkPopup: false | "editor" | "info";
|
|
363
404
|
selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
364
405
|
};
|
|
365
406
|
commitToHistory: false;
|
|
@@ -390,6 +431,10 @@ export declare const actionResetZoom: {
|
|
|
390
431
|
showWelcomeScreen: boolean;
|
|
391
432
|
isLoading: boolean;
|
|
392
433
|
errorMessage: import("react").ReactNode;
|
|
434
|
+
activeEmbeddable: {
|
|
435
|
+
element: import("../element/types").NonDeletedExcalidrawElement;
|
|
436
|
+
state: "active" | "hover";
|
|
437
|
+
} | null;
|
|
393
438
|
draggingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
394
439
|
resizingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
395
440
|
multiElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawLinearElement> | null;
|
|
@@ -397,13 +442,22 @@ export declare const actionResetZoom: {
|
|
|
397
442
|
isBindingEnabled: boolean;
|
|
398
443
|
startBoundElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawBindableElement> | null;
|
|
399
444
|
suggestedBindings: import("../element/binding").SuggestedBinding[];
|
|
445
|
+
frameToHighlight: import("../element/types").NonDeleted<import("../element/types").ExcalidrawFrameElement> | null;
|
|
446
|
+
frameRendering: {
|
|
447
|
+
enabled: boolean;
|
|
448
|
+
name: boolean;
|
|
449
|
+
outline: boolean;
|
|
450
|
+
clip: boolean;
|
|
451
|
+
};
|
|
452
|
+
editingFrame: string | null;
|
|
453
|
+
elementsToHighlight: import("../element/types").NonDeleted<ExcalidrawElement>[] | null;
|
|
400
454
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
401
455
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
402
456
|
activeTool: {
|
|
403
457
|
lastActiveTool: import("../types").LastActiveTool;
|
|
404
458
|
locked: boolean;
|
|
405
459
|
} & ({
|
|
406
|
-
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser" | "hand";
|
|
460
|
+
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "embeddable" | "image" | "frame" | "freedraw" | "eraser" | "hand";
|
|
407
461
|
customType: null;
|
|
408
462
|
} | {
|
|
409
463
|
type: "custom";
|
|
@@ -443,12 +497,13 @@ export declare const actionResetZoom: {
|
|
|
443
497
|
openDialog: "imageExport" | "help" | "jsonExport" | null;
|
|
444
498
|
defaultSidebarDockedPreference: boolean;
|
|
445
499
|
lastPointerDownWith: import("../element/types").PointerType;
|
|
446
|
-
selectedElementIds: {
|
|
447
|
-
[id: string]:
|
|
448
|
-
}
|
|
500
|
+
selectedElementIds: Readonly<{
|
|
501
|
+
[id: string]: true;
|
|
502
|
+
}>;
|
|
449
503
|
previousSelectedElementIds: {
|
|
450
|
-
[id: string]:
|
|
504
|
+
[id: string]: true;
|
|
451
505
|
};
|
|
506
|
+
selectedElementsAreBeingDragged: boolean;
|
|
452
507
|
shouldCacheIgnoreZoom: boolean;
|
|
453
508
|
toast: {
|
|
454
509
|
message: string;
|
|
@@ -456,7 +511,7 @@ export declare const actionResetZoom: {
|
|
|
456
511
|
duration?: number | undefined;
|
|
457
512
|
} | null;
|
|
458
513
|
zenModeEnabled: boolean;
|
|
459
|
-
theme:
|
|
514
|
+
theme: import("../element/types").Theme;
|
|
460
515
|
gridSize: number | null;
|
|
461
516
|
viewModeEnabled: boolean;
|
|
462
517
|
selectedGroupIds: {
|
|
@@ -479,7 +534,7 @@ export declare const actionResetZoom: {
|
|
|
479
534
|
data: import("../charts").Spreadsheet;
|
|
480
535
|
};
|
|
481
536
|
pendingImageElementId: string | null;
|
|
482
|
-
showHyperlinkPopup: false | "
|
|
537
|
+
showHyperlinkPopup: false | "editor" | "info";
|
|
483
538
|
selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
484
539
|
};
|
|
485
540
|
commitToHistory: false;
|
|
@@ -489,13 +544,20 @@ export declare const actionResetZoom: {
|
|
|
489
544
|
} & {
|
|
490
545
|
keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean) | undefined;
|
|
491
546
|
};
|
|
492
|
-
export declare const
|
|
547
|
+
export declare const zoomToFit: ({ targetElements, appState, fitToViewport, viewportZoomFactor, }: {
|
|
548
|
+
targetElements: readonly ExcalidrawElement[];
|
|
549
|
+
appState: Readonly<AppState>;
|
|
550
|
+
/** whether to fit content to viewport (beyond >100%) */
|
|
551
|
+
fitToViewport: boolean;
|
|
552
|
+
/** zoom content to cover X of the viewport, when fitToViewport=true */
|
|
553
|
+
viewportZoomFactor?: number | undefined;
|
|
554
|
+
}) => {
|
|
493
555
|
appState: {
|
|
556
|
+
scrollX: number;
|
|
557
|
+
scrollY: number;
|
|
494
558
|
zoom: {
|
|
495
559
|
value: NormalizedZoomValue;
|
|
496
560
|
};
|
|
497
|
-
scrollX: number;
|
|
498
|
-
scrollY: number;
|
|
499
561
|
contextMenu: {
|
|
500
562
|
items: import("../components/ContextMenu").ContextMenuItems;
|
|
501
563
|
top: number;
|
|
@@ -504,6 +566,10 @@ export declare const zoomToFitElements: (elements: readonly ExcalidrawElement[],
|
|
|
504
566
|
showWelcomeScreen: boolean;
|
|
505
567
|
isLoading: boolean;
|
|
506
568
|
errorMessage: import("react").ReactNode;
|
|
569
|
+
activeEmbeddable: {
|
|
570
|
+
element: import("../element/types").NonDeletedExcalidrawElement;
|
|
571
|
+
state: "active" | "hover";
|
|
572
|
+
} | null;
|
|
507
573
|
draggingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
508
574
|
resizingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
509
575
|
multiElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawLinearElement> | null;
|
|
@@ -511,13 +577,22 @@ export declare const zoomToFitElements: (elements: readonly ExcalidrawElement[],
|
|
|
511
577
|
isBindingEnabled: boolean;
|
|
512
578
|
startBoundElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawBindableElement> | null;
|
|
513
579
|
suggestedBindings: import("../element/binding").SuggestedBinding[];
|
|
580
|
+
frameToHighlight: import("../element/types").NonDeleted<import("../element/types").ExcalidrawFrameElement> | null;
|
|
581
|
+
frameRendering: {
|
|
582
|
+
enabled: boolean;
|
|
583
|
+
name: boolean;
|
|
584
|
+
outline: boolean;
|
|
585
|
+
clip: boolean;
|
|
586
|
+
};
|
|
587
|
+
editingFrame: string | null;
|
|
588
|
+
elementsToHighlight: import("../element/types").NonDeleted<ExcalidrawElement>[] | null;
|
|
514
589
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
515
590
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
516
591
|
activeTool: {
|
|
517
592
|
lastActiveTool: import("../types").LastActiveTool;
|
|
518
593
|
locked: boolean;
|
|
519
594
|
} & ({
|
|
520
|
-
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser" | "hand";
|
|
595
|
+
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "embeddable" | "image" | "frame" | "freedraw" | "eraser" | "hand";
|
|
521
596
|
customType: null;
|
|
522
597
|
} | {
|
|
523
598
|
type: "custom";
|
|
@@ -557,12 +632,13 @@ export declare const zoomToFitElements: (elements: readonly ExcalidrawElement[],
|
|
|
557
632
|
openDialog: "imageExport" | "help" | "jsonExport" | null;
|
|
558
633
|
defaultSidebarDockedPreference: boolean;
|
|
559
634
|
lastPointerDownWith: import("../element/types").PointerType;
|
|
560
|
-
selectedElementIds: {
|
|
561
|
-
[id: string]:
|
|
562
|
-
}
|
|
635
|
+
selectedElementIds: Readonly<{
|
|
636
|
+
[id: string]: true;
|
|
637
|
+
}>;
|
|
563
638
|
previousSelectedElementIds: {
|
|
564
|
-
[id: string]:
|
|
639
|
+
[id: string]: true;
|
|
565
640
|
};
|
|
641
|
+
selectedElementsAreBeingDragged: boolean;
|
|
566
642
|
shouldCacheIgnoreZoom: boolean;
|
|
567
643
|
toast: {
|
|
568
644
|
message: string;
|
|
@@ -570,7 +646,7 @@ export declare const zoomToFitElements: (elements: readonly ExcalidrawElement[],
|
|
|
570
646
|
duration?: number | undefined;
|
|
571
647
|
} | null;
|
|
572
648
|
zenModeEnabled: boolean;
|
|
573
|
-
theme:
|
|
649
|
+
theme: import("../element/types").Theme;
|
|
574
650
|
gridSize: number | null;
|
|
575
651
|
viewModeEnabled: boolean;
|
|
576
652
|
selectedGroupIds: {
|
|
@@ -593,23 +669,155 @@ export declare const zoomToFitElements: (elements: readonly ExcalidrawElement[],
|
|
|
593
669
|
data: import("../charts").Spreadsheet;
|
|
594
670
|
};
|
|
595
671
|
pendingImageElementId: string | null;
|
|
596
|
-
showHyperlinkPopup: false | "
|
|
672
|
+
showHyperlinkPopup: false | "editor" | "info";
|
|
597
673
|
selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
598
674
|
};
|
|
599
675
|
commitToHistory: boolean;
|
|
600
676
|
};
|
|
601
|
-
export declare const
|
|
602
|
-
name: "
|
|
677
|
+
export declare const actionZoomToFitSelectionInViewport: {
|
|
678
|
+
name: "zoomToFitSelectionInViewport";
|
|
603
679
|
trackEvent: {
|
|
604
680
|
category: "canvas";
|
|
605
681
|
};
|
|
606
|
-
perform: (elements: readonly ExcalidrawElement[], appState: Readonly<AppState
|
|
682
|
+
perform: (elements: readonly ExcalidrawElement[], appState: Readonly<AppState>, _: any, app: import("../types").AppClassProperties) => {
|
|
607
683
|
appState: {
|
|
684
|
+
scrollX: number;
|
|
685
|
+
scrollY: number;
|
|
608
686
|
zoom: {
|
|
609
687
|
value: NormalizedZoomValue;
|
|
610
688
|
};
|
|
689
|
+
contextMenu: {
|
|
690
|
+
items: import("../components/ContextMenu").ContextMenuItems;
|
|
691
|
+
top: number;
|
|
692
|
+
left: number;
|
|
693
|
+
} | null;
|
|
694
|
+
showWelcomeScreen: boolean;
|
|
695
|
+
isLoading: boolean;
|
|
696
|
+
errorMessage: import("react").ReactNode;
|
|
697
|
+
activeEmbeddable: {
|
|
698
|
+
element: import("../element/types").NonDeletedExcalidrawElement;
|
|
699
|
+
state: "active" | "hover";
|
|
700
|
+
} | null;
|
|
701
|
+
draggingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
702
|
+
resizingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
703
|
+
multiElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawLinearElement> | null;
|
|
704
|
+
selectionElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
705
|
+
isBindingEnabled: boolean;
|
|
706
|
+
startBoundElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawBindableElement> | null;
|
|
707
|
+
suggestedBindings: import("../element/binding").SuggestedBinding[];
|
|
708
|
+
frameToHighlight: import("../element/types").NonDeleted<import("../element/types").ExcalidrawFrameElement> | null;
|
|
709
|
+
frameRendering: {
|
|
710
|
+
enabled: boolean;
|
|
711
|
+
name: boolean;
|
|
712
|
+
outline: boolean;
|
|
713
|
+
clip: boolean;
|
|
714
|
+
};
|
|
715
|
+
editingFrame: string | null;
|
|
716
|
+
elementsToHighlight: import("../element/types").NonDeleted<ExcalidrawElement>[] | null;
|
|
717
|
+
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
718
|
+
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
719
|
+
activeTool: {
|
|
720
|
+
lastActiveTool: import("../types").LastActiveTool;
|
|
721
|
+
locked: boolean;
|
|
722
|
+
} & ({
|
|
723
|
+
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "embeddable" | "image" | "frame" | "freedraw" | "eraser" | "hand";
|
|
724
|
+
customType: null;
|
|
725
|
+
} | {
|
|
726
|
+
type: "custom";
|
|
727
|
+
customType: string;
|
|
728
|
+
});
|
|
729
|
+
penMode: boolean;
|
|
730
|
+
penDetected: boolean;
|
|
731
|
+
exportBackground: boolean;
|
|
732
|
+
exportEmbedScene: boolean;
|
|
733
|
+
exportWithDarkMode: boolean;
|
|
734
|
+
exportScale: number;
|
|
735
|
+
currentItemStrokeColor: string;
|
|
736
|
+
currentItemBackgroundColor: string;
|
|
737
|
+
currentItemFillStyle: import("../element/types").FillStyle;
|
|
738
|
+
currentItemStrokeWidth: number;
|
|
739
|
+
currentItemStrokeStyle: import("../element/types").StrokeStyle;
|
|
740
|
+
currentItemRoughness: number;
|
|
741
|
+
currentItemOpacity: number;
|
|
742
|
+
currentItemFontFamily: number;
|
|
743
|
+
currentItemFontSize: number;
|
|
744
|
+
currentItemTextAlign: string;
|
|
745
|
+
currentItemStartArrowhead: import("../element/types").Arrowhead | null;
|
|
746
|
+
currentItemEndArrowhead: import("../element/types").Arrowhead | null;
|
|
747
|
+
currentItemRoundness: import("../element/types").StrokeRoundness;
|
|
748
|
+
viewBackgroundColor: string;
|
|
749
|
+
cursorButton: "up" | "down";
|
|
750
|
+
scrolledOutside: boolean;
|
|
751
|
+
name: string;
|
|
752
|
+
isResizing: boolean;
|
|
753
|
+
isRotating: boolean;
|
|
754
|
+
openMenu: "canvas" | "shape" | null;
|
|
755
|
+
openPopup: "canvasBackground" | "elementBackground" | "elementStroke" | null;
|
|
756
|
+
openSidebar: {
|
|
757
|
+
name: string;
|
|
758
|
+
tab?: string | undefined;
|
|
759
|
+
} | null;
|
|
760
|
+
openDialog: "imageExport" | "help" | "jsonExport" | null;
|
|
761
|
+
defaultSidebarDockedPreference: boolean;
|
|
762
|
+
lastPointerDownWith: import("../element/types").PointerType;
|
|
763
|
+
selectedElementIds: Readonly<{
|
|
764
|
+
[id: string]: true;
|
|
765
|
+
}>;
|
|
766
|
+
previousSelectedElementIds: {
|
|
767
|
+
[id: string]: true;
|
|
768
|
+
};
|
|
769
|
+
selectedElementsAreBeingDragged: boolean;
|
|
770
|
+
shouldCacheIgnoreZoom: boolean;
|
|
771
|
+
toast: {
|
|
772
|
+
message: string;
|
|
773
|
+
closable?: boolean | undefined;
|
|
774
|
+
duration?: number | undefined;
|
|
775
|
+
} | null;
|
|
776
|
+
zenModeEnabled: boolean;
|
|
777
|
+
theme: import("../element/types").Theme;
|
|
778
|
+
gridSize: number | null;
|
|
779
|
+
viewModeEnabled: boolean;
|
|
780
|
+
selectedGroupIds: {
|
|
781
|
+
[groupId: string]: boolean;
|
|
782
|
+
};
|
|
783
|
+
editingGroupId: string | null;
|
|
784
|
+
width: number;
|
|
785
|
+
height: number;
|
|
786
|
+
offsetTop: number;
|
|
787
|
+
offsetLeft: number;
|
|
788
|
+
fileHandle: import("browser-fs-access").FileSystemHandle | null;
|
|
789
|
+
collaborators: Map<string, import("../types").Collaborator>;
|
|
790
|
+
showStats: boolean;
|
|
791
|
+
currentChartType: import("../element/types").ChartType;
|
|
792
|
+
pasteDialog: {
|
|
793
|
+
shown: false;
|
|
794
|
+
data: null;
|
|
795
|
+
} | {
|
|
796
|
+
shown: true;
|
|
797
|
+
data: import("../charts").Spreadsheet;
|
|
798
|
+
};
|
|
799
|
+
pendingImageElementId: string | null;
|
|
800
|
+
showHyperlinkPopup: false | "editor" | "info";
|
|
801
|
+
selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
802
|
+
};
|
|
803
|
+
commitToHistory: boolean;
|
|
804
|
+
};
|
|
805
|
+
keyTest: (event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean;
|
|
806
|
+
} & {
|
|
807
|
+
keyTest?: ((event: KeyboardEvent | import("react").KeyboardEvent<Element>) => boolean) | undefined;
|
|
808
|
+
};
|
|
809
|
+
export declare const actionZoomToFitSelection: {
|
|
810
|
+
name: "zoomToFitSelection";
|
|
811
|
+
trackEvent: {
|
|
812
|
+
category: "canvas";
|
|
813
|
+
};
|
|
814
|
+
perform: (elements: readonly ExcalidrawElement[], appState: Readonly<AppState>, _: any, app: import("../types").AppClassProperties) => {
|
|
815
|
+
appState: {
|
|
611
816
|
scrollX: number;
|
|
612
817
|
scrollY: number;
|
|
818
|
+
zoom: {
|
|
819
|
+
value: NormalizedZoomValue;
|
|
820
|
+
};
|
|
613
821
|
contextMenu: {
|
|
614
822
|
items: import("../components/ContextMenu").ContextMenuItems;
|
|
615
823
|
top: number;
|
|
@@ -618,6 +826,10 @@ export declare const actionZoomToSelected: {
|
|
|
618
826
|
showWelcomeScreen: boolean;
|
|
619
827
|
isLoading: boolean;
|
|
620
828
|
errorMessage: import("react").ReactNode;
|
|
829
|
+
activeEmbeddable: {
|
|
830
|
+
element: import("../element/types").NonDeletedExcalidrawElement;
|
|
831
|
+
state: "active" | "hover";
|
|
832
|
+
} | null;
|
|
621
833
|
draggingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
622
834
|
resizingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
623
835
|
multiElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawLinearElement> | null;
|
|
@@ -625,13 +837,22 @@ export declare const actionZoomToSelected: {
|
|
|
625
837
|
isBindingEnabled: boolean;
|
|
626
838
|
startBoundElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawBindableElement> | null;
|
|
627
839
|
suggestedBindings: import("../element/binding").SuggestedBinding[];
|
|
840
|
+
frameToHighlight: import("../element/types").NonDeleted<import("../element/types").ExcalidrawFrameElement> | null;
|
|
841
|
+
frameRendering: {
|
|
842
|
+
enabled: boolean;
|
|
843
|
+
name: boolean;
|
|
844
|
+
outline: boolean;
|
|
845
|
+
clip: boolean;
|
|
846
|
+
};
|
|
847
|
+
editingFrame: string | null;
|
|
848
|
+
elementsToHighlight: import("../element/types").NonDeleted<ExcalidrawElement>[] | null;
|
|
628
849
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
629
850
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
630
851
|
activeTool: {
|
|
631
852
|
lastActiveTool: import("../types").LastActiveTool;
|
|
632
853
|
locked: boolean;
|
|
633
854
|
} & ({
|
|
634
|
-
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser" | "hand";
|
|
855
|
+
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "embeddable" | "image" | "frame" | "freedraw" | "eraser" | "hand";
|
|
635
856
|
customType: null;
|
|
636
857
|
} | {
|
|
637
858
|
type: "custom";
|
|
@@ -671,12 +892,13 @@ export declare const actionZoomToSelected: {
|
|
|
671
892
|
openDialog: "imageExport" | "help" | "jsonExport" | null;
|
|
672
893
|
defaultSidebarDockedPreference: boolean;
|
|
673
894
|
lastPointerDownWith: import("../element/types").PointerType;
|
|
674
|
-
selectedElementIds: {
|
|
675
|
-
[id: string]:
|
|
676
|
-
}
|
|
895
|
+
selectedElementIds: Readonly<{
|
|
896
|
+
[id: string]: true;
|
|
897
|
+
}>;
|
|
677
898
|
previousSelectedElementIds: {
|
|
678
|
-
[id: string]:
|
|
899
|
+
[id: string]: true;
|
|
679
900
|
};
|
|
901
|
+
selectedElementsAreBeingDragged: boolean;
|
|
680
902
|
shouldCacheIgnoreZoom: boolean;
|
|
681
903
|
toast: {
|
|
682
904
|
message: string;
|
|
@@ -684,7 +906,7 @@ export declare const actionZoomToSelected: {
|
|
|
684
906
|
duration?: number | undefined;
|
|
685
907
|
} | null;
|
|
686
908
|
zenModeEnabled: boolean;
|
|
687
|
-
theme:
|
|
909
|
+
theme: import("../element/types").Theme;
|
|
688
910
|
gridSize: number | null;
|
|
689
911
|
viewModeEnabled: boolean;
|
|
690
912
|
selectedGroupIds: {
|
|
@@ -707,7 +929,7 @@ export declare const actionZoomToSelected: {
|
|
|
707
929
|
data: import("../charts").Spreadsheet;
|
|
708
930
|
};
|
|
709
931
|
pendingImageElementId: string | null;
|
|
710
|
-
showHyperlinkPopup: false | "
|
|
932
|
+
showHyperlinkPopup: false | "editor" | "info";
|
|
711
933
|
selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
712
934
|
};
|
|
713
935
|
commitToHistory: boolean;
|
|
@@ -724,11 +946,11 @@ export declare const actionZoomToFit: {
|
|
|
724
946
|
};
|
|
725
947
|
perform: (elements: readonly ExcalidrawElement[], appState: Readonly<AppState>) => {
|
|
726
948
|
appState: {
|
|
949
|
+
scrollX: number;
|
|
950
|
+
scrollY: number;
|
|
727
951
|
zoom: {
|
|
728
952
|
value: NormalizedZoomValue;
|
|
729
953
|
};
|
|
730
|
-
scrollX: number;
|
|
731
|
-
scrollY: number;
|
|
732
954
|
contextMenu: {
|
|
733
955
|
items: import("../components/ContextMenu").ContextMenuItems;
|
|
734
956
|
top: number;
|
|
@@ -737,6 +959,10 @@ export declare const actionZoomToFit: {
|
|
|
737
959
|
showWelcomeScreen: boolean;
|
|
738
960
|
isLoading: boolean;
|
|
739
961
|
errorMessage: import("react").ReactNode;
|
|
962
|
+
activeEmbeddable: {
|
|
963
|
+
element: import("../element/types").NonDeletedExcalidrawElement;
|
|
964
|
+
state: "active" | "hover";
|
|
965
|
+
} | null;
|
|
740
966
|
draggingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
741
967
|
resizingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
742
968
|
multiElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawLinearElement> | null;
|
|
@@ -744,13 +970,22 @@ export declare const actionZoomToFit: {
|
|
|
744
970
|
isBindingEnabled: boolean;
|
|
745
971
|
startBoundElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawBindableElement> | null;
|
|
746
972
|
suggestedBindings: import("../element/binding").SuggestedBinding[];
|
|
973
|
+
frameToHighlight: import("../element/types").NonDeleted<import("../element/types").ExcalidrawFrameElement> | null;
|
|
974
|
+
frameRendering: {
|
|
975
|
+
enabled: boolean;
|
|
976
|
+
name: boolean;
|
|
977
|
+
outline: boolean;
|
|
978
|
+
clip: boolean;
|
|
979
|
+
};
|
|
980
|
+
editingFrame: string | null;
|
|
981
|
+
elementsToHighlight: import("../element/types").NonDeleted<ExcalidrawElement>[] | null;
|
|
747
982
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
748
983
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
749
984
|
activeTool: {
|
|
750
985
|
lastActiveTool: import("../types").LastActiveTool;
|
|
751
986
|
locked: boolean;
|
|
752
987
|
} & ({
|
|
753
|
-
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser" | "hand";
|
|
988
|
+
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "embeddable" | "image" | "frame" | "freedraw" | "eraser" | "hand";
|
|
754
989
|
customType: null;
|
|
755
990
|
} | {
|
|
756
991
|
type: "custom";
|
|
@@ -790,12 +1025,13 @@ export declare const actionZoomToFit: {
|
|
|
790
1025
|
openDialog: "imageExport" | "help" | "jsonExport" | null;
|
|
791
1026
|
defaultSidebarDockedPreference: boolean;
|
|
792
1027
|
lastPointerDownWith: import("../element/types").PointerType;
|
|
793
|
-
selectedElementIds: {
|
|
794
|
-
[id: string]:
|
|
795
|
-
}
|
|
1028
|
+
selectedElementIds: Readonly<{
|
|
1029
|
+
[id: string]: true;
|
|
1030
|
+
}>;
|
|
796
1031
|
previousSelectedElementIds: {
|
|
797
|
-
[id: string]:
|
|
1032
|
+
[id: string]: true;
|
|
798
1033
|
};
|
|
1034
|
+
selectedElementsAreBeingDragged: boolean;
|
|
799
1035
|
shouldCacheIgnoreZoom: boolean;
|
|
800
1036
|
toast: {
|
|
801
1037
|
message: string;
|
|
@@ -803,7 +1039,7 @@ export declare const actionZoomToFit: {
|
|
|
803
1039
|
duration?: number | undefined;
|
|
804
1040
|
} | null;
|
|
805
1041
|
zenModeEnabled: boolean;
|
|
806
|
-
theme:
|
|
1042
|
+
theme: import("../element/types").Theme;
|
|
807
1043
|
gridSize: number | null;
|
|
808
1044
|
viewModeEnabled: boolean;
|
|
809
1045
|
selectedGroupIds: {
|
|
@@ -826,7 +1062,7 @@ export declare const actionZoomToFit: {
|
|
|
826
1062
|
data: import("../charts").Spreadsheet;
|
|
827
1063
|
};
|
|
828
1064
|
pendingImageElementId: string | null;
|
|
829
|
-
showHyperlinkPopup: false | "
|
|
1065
|
+
showHyperlinkPopup: false | "editor" | "info";
|
|
830
1066
|
selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
831
1067
|
};
|
|
832
1068
|
commitToHistory: boolean;
|
|
@@ -852,6 +1088,10 @@ export declare const actionToggleTheme: {
|
|
|
852
1088
|
showWelcomeScreen: boolean;
|
|
853
1089
|
isLoading: boolean;
|
|
854
1090
|
errorMessage: import("react").ReactNode;
|
|
1091
|
+
activeEmbeddable: {
|
|
1092
|
+
element: import("../element/types").NonDeletedExcalidrawElement;
|
|
1093
|
+
state: "active" | "hover";
|
|
1094
|
+
} | null;
|
|
855
1095
|
draggingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
856
1096
|
resizingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
857
1097
|
multiElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawLinearElement> | null;
|
|
@@ -859,13 +1099,22 @@ export declare const actionToggleTheme: {
|
|
|
859
1099
|
isBindingEnabled: boolean;
|
|
860
1100
|
startBoundElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawBindableElement> | null;
|
|
861
1101
|
suggestedBindings: import("../element/binding").SuggestedBinding[];
|
|
1102
|
+
frameToHighlight: import("../element/types").NonDeleted<import("../element/types").ExcalidrawFrameElement> | null;
|
|
1103
|
+
frameRendering: {
|
|
1104
|
+
enabled: boolean;
|
|
1105
|
+
name: boolean;
|
|
1106
|
+
outline: boolean;
|
|
1107
|
+
clip: boolean;
|
|
1108
|
+
};
|
|
1109
|
+
editingFrame: string | null;
|
|
1110
|
+
elementsToHighlight: import("../element/types").NonDeleted<ExcalidrawElement>[] | null;
|
|
862
1111
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
863
1112
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
864
1113
|
activeTool: {
|
|
865
1114
|
lastActiveTool: import("../types").LastActiveTool;
|
|
866
1115
|
locked: boolean;
|
|
867
1116
|
} & ({
|
|
868
|
-
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser" | "hand";
|
|
1117
|
+
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "embeddable" | "image" | "frame" | "freedraw" | "eraser" | "hand";
|
|
869
1118
|
customType: null;
|
|
870
1119
|
} | {
|
|
871
1120
|
type: "custom";
|
|
@@ -910,12 +1159,13 @@ export declare const actionToggleTheme: {
|
|
|
910
1159
|
openDialog: "imageExport" | "help" | "jsonExport" | null;
|
|
911
1160
|
defaultSidebarDockedPreference: boolean;
|
|
912
1161
|
lastPointerDownWith: import("../element/types").PointerType;
|
|
913
|
-
selectedElementIds: {
|
|
914
|
-
[id: string]:
|
|
915
|
-
}
|
|
1162
|
+
selectedElementIds: Readonly<{
|
|
1163
|
+
[id: string]: true;
|
|
1164
|
+
}>;
|
|
916
1165
|
previousSelectedElementIds: {
|
|
917
|
-
[id: string]:
|
|
1166
|
+
[id: string]: true;
|
|
918
1167
|
};
|
|
1168
|
+
selectedElementsAreBeingDragged: boolean;
|
|
919
1169
|
shouldCacheIgnoreZoom: boolean;
|
|
920
1170
|
toast: {
|
|
921
1171
|
message: string;
|
|
@@ -945,7 +1195,7 @@ export declare const actionToggleTheme: {
|
|
|
945
1195
|
data: import("../charts").Spreadsheet;
|
|
946
1196
|
};
|
|
947
1197
|
pendingImageElementId: string | null;
|
|
948
|
-
showHyperlinkPopup: false | "
|
|
1198
|
+
showHyperlinkPopup: false | "editor" | "info";
|
|
949
1199
|
selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
950
1200
|
};
|
|
951
1201
|
commitToHistory: false;
|
|
@@ -964,11 +1214,12 @@ export declare const actionToggleEraserTool: {
|
|
|
964
1214
|
appState: {
|
|
965
1215
|
selectedElementIds: {};
|
|
966
1216
|
selectedGroupIds: {};
|
|
1217
|
+
activeEmbeddable: null;
|
|
967
1218
|
activeTool: {
|
|
968
1219
|
lastActiveTool: import("../types").LastActiveTool;
|
|
969
1220
|
locked: boolean;
|
|
970
1221
|
} & ({
|
|
971
|
-
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser" | "hand";
|
|
1222
|
+
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "embeddable" | "image" | "frame" | "freedraw" | "eraser" | "hand";
|
|
972
1223
|
customType: null;
|
|
973
1224
|
} | {
|
|
974
1225
|
type: "custom";
|
|
@@ -989,6 +1240,15 @@ export declare const actionToggleEraserTool: {
|
|
|
989
1240
|
isBindingEnabled: boolean;
|
|
990
1241
|
startBoundElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawBindableElement> | null;
|
|
991
1242
|
suggestedBindings: import("../element/binding").SuggestedBinding[];
|
|
1243
|
+
frameToHighlight: import("../element/types").NonDeleted<import("../element/types").ExcalidrawFrameElement> | null;
|
|
1244
|
+
frameRendering: {
|
|
1245
|
+
enabled: boolean;
|
|
1246
|
+
name: boolean;
|
|
1247
|
+
outline: boolean;
|
|
1248
|
+
clip: boolean;
|
|
1249
|
+
};
|
|
1250
|
+
editingFrame: string | null;
|
|
1251
|
+
elementsToHighlight: import("../element/types").NonDeleted<ExcalidrawElement>[] | null;
|
|
992
1252
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
993
1253
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
994
1254
|
penMode: boolean;
|
|
@@ -1031,8 +1291,9 @@ export declare const actionToggleEraserTool: {
|
|
|
1031
1291
|
defaultSidebarDockedPreference: boolean;
|
|
1032
1292
|
lastPointerDownWith: import("../element/types").PointerType;
|
|
1033
1293
|
previousSelectedElementIds: {
|
|
1034
|
-
[id: string]:
|
|
1294
|
+
[id: string]: true;
|
|
1035
1295
|
};
|
|
1296
|
+
selectedElementsAreBeingDragged: boolean;
|
|
1036
1297
|
shouldCacheIgnoreZoom: boolean;
|
|
1037
1298
|
toast: {
|
|
1038
1299
|
message: string;
|
|
@@ -1040,7 +1301,7 @@ export declare const actionToggleEraserTool: {
|
|
|
1040
1301
|
duration?: number | undefined;
|
|
1041
1302
|
} | null;
|
|
1042
1303
|
zenModeEnabled: boolean;
|
|
1043
|
-
theme:
|
|
1304
|
+
theme: import("../element/types").Theme;
|
|
1044
1305
|
gridSize: number | null;
|
|
1045
1306
|
viewModeEnabled: boolean;
|
|
1046
1307
|
editingGroupId: string | null;
|
|
@@ -1060,7 +1321,7 @@ export declare const actionToggleEraserTool: {
|
|
|
1060
1321
|
data: import("../charts").Spreadsheet;
|
|
1061
1322
|
};
|
|
1062
1323
|
pendingImageElementId: string | null;
|
|
1063
|
-
showHyperlinkPopup: false | "
|
|
1324
|
+
showHyperlinkPopup: false | "editor" | "info";
|
|
1064
1325
|
selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
1065
1326
|
};
|
|
1066
1327
|
commitToHistory: true;
|
|
@@ -1078,11 +1339,12 @@ export declare const actionToggleHandTool: {
|
|
|
1078
1339
|
appState: {
|
|
1079
1340
|
selectedElementIds: {};
|
|
1080
1341
|
selectedGroupIds: {};
|
|
1342
|
+
activeEmbeddable: null;
|
|
1081
1343
|
activeTool: {
|
|
1082
1344
|
lastActiveTool: import("../types").LastActiveTool;
|
|
1083
1345
|
locked: boolean;
|
|
1084
1346
|
} & ({
|
|
1085
|
-
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser" | "hand";
|
|
1347
|
+
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "embeddable" | "image" | "frame" | "freedraw" | "eraser" | "hand";
|
|
1086
1348
|
customType: null;
|
|
1087
1349
|
} | {
|
|
1088
1350
|
type: "custom";
|
|
@@ -1103,6 +1365,15 @@ export declare const actionToggleHandTool: {
|
|
|
1103
1365
|
isBindingEnabled: boolean;
|
|
1104
1366
|
startBoundElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawBindableElement> | null;
|
|
1105
1367
|
suggestedBindings: import("../element/binding").SuggestedBinding[];
|
|
1368
|
+
frameToHighlight: import("../element/types").NonDeleted<import("../element/types").ExcalidrawFrameElement> | null;
|
|
1369
|
+
frameRendering: {
|
|
1370
|
+
enabled: boolean;
|
|
1371
|
+
name: boolean;
|
|
1372
|
+
outline: boolean;
|
|
1373
|
+
clip: boolean;
|
|
1374
|
+
};
|
|
1375
|
+
editingFrame: string | null;
|
|
1376
|
+
elementsToHighlight: import("../element/types").NonDeleted<ExcalidrawElement>[] | null;
|
|
1106
1377
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
1107
1378
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
1108
1379
|
penMode: boolean;
|
|
@@ -1145,8 +1416,9 @@ export declare const actionToggleHandTool: {
|
|
|
1145
1416
|
defaultSidebarDockedPreference: boolean;
|
|
1146
1417
|
lastPointerDownWith: import("../element/types").PointerType;
|
|
1147
1418
|
previousSelectedElementIds: {
|
|
1148
|
-
[id: string]:
|
|
1419
|
+
[id: string]: true;
|
|
1149
1420
|
};
|
|
1421
|
+
selectedElementsAreBeingDragged: boolean;
|
|
1150
1422
|
shouldCacheIgnoreZoom: boolean;
|
|
1151
1423
|
toast: {
|
|
1152
1424
|
message: string;
|
|
@@ -1154,7 +1426,7 @@ export declare const actionToggleHandTool: {
|
|
|
1154
1426
|
duration?: number | undefined;
|
|
1155
1427
|
} | null;
|
|
1156
1428
|
zenModeEnabled: boolean;
|
|
1157
|
-
theme:
|
|
1429
|
+
theme: import("../element/types").Theme;
|
|
1158
1430
|
gridSize: number | null;
|
|
1159
1431
|
viewModeEnabled: boolean;
|
|
1160
1432
|
editingGroupId: string | null;
|
|
@@ -1174,7 +1446,7 @@ export declare const actionToggleHandTool: {
|
|
|
1174
1446
|
data: import("../charts").Spreadsheet;
|
|
1175
1447
|
};
|
|
1176
1448
|
pendingImageElementId: string | null;
|
|
1177
|
-
showHyperlinkPopup: false | "
|
|
1449
|
+
showHyperlinkPopup: false | "editor" | "info";
|
|
1178
1450
|
selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
1179
1451
|
};
|
|
1180
1452
|
commitToHistory: true;
|