@dwelle/excalidraw 0.4.0-9e2b706 → 0.4.0-9fa56da
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 +456 -0
- package/README.md +6 -2
- 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 +2908 -1612
- package/dist/excalidraw.production.min.js +1 -1
- package/package.json +9 -4
- package/types/actions/actionAddToLibrary.d.ts +103 -52
- package/types/actions/actionAlign.d.ts +33 -28
- package/types/actions/actionBoundText.d.ts +176 -22
- package/types/actions/actionCanvas.d.ts +592 -184
- package/types/actions/actionClipboard.d.ts +173 -92
- package/types/actions/actionDeleteSelected.d.ts +101 -54
- package/types/actions/actionDistribute.d.ts +11 -12
- package/types/actions/actionDuplicateSelection.d.ts +3 -4
- package/types/actions/actionElementLock.d.ts +271 -0
- package/types/actions/actionExport.d.ts +366 -213
- package/types/actions/actionFinalize.d.ts +70 -40
- package/types/actions/actionFlip.d.ts +8 -11
- package/types/actions/actionFrame.d.ts +423 -0
- package/types/actions/actionGroup.d.ts +250 -13
- package/types/actions/actionHistory.d.ts +1 -1
- package/types/actions/actionLinearEditor.d.ts +37 -20
- package/types/actions/actionMenu.d.ts +108 -59
- package/types/actions/actionNavigate.d.ts +1 -1
- package/types/actions/actionProperties.d.ts +464 -242
- package/types/actions/actionSelectAll.d.ts +123 -4
- package/types/actions/actionStyles.d.ts +39 -23
- package/types/actions/actionToggleGridMode.d.ts +37 -21
- package/types/actions/{actionToggleLock.d.ts → actionToggleObjectsSnapMode.d.ts} +49 -31
- package/types/actions/actionToggleStats.d.ts +37 -21
- package/types/actions/actionToggleViewMode.d.ts +37 -21
- package/types/actions/actionToggleZenMode.d.ts +37 -21
- package/types/actions/actionZindex.d.ts +12 -12
- package/types/actions/index.d.ts +2 -1
- package/types/actions/manager.d.ts +1 -1
- package/types/actions/shortcuts.d.ts +2 -1
- package/types/actions/types.d.ts +11 -9
- package/types/appState.d.ts +17 -19
- package/types/charts.d.ts +2 -2
- package/types/clients.d.ts +5 -6
- package/types/clipboard.d.ts +3 -2
- package/types/colors.d.ts +60 -5
- package/types/components/Actions.d.ts +7 -8
- package/types/components/ActiveConfirmDialog.d.ts +1 -21
- package/types/components/App.d.ts +88 -33
- package/types/components/Avatar.d.ts +1 -2
- package/types/components/BraveMeasureTextError.d.ts +2 -0
- package/types/components/Button.d.ts +3 -2
- package/types/components/ButtonIconSelect.d.ts +11 -3
- package/types/components/Card.d.ts +0 -1
- package/types/components/ColorPicker/ColorInput.d.ts +9 -0
- package/types/components/ColorPicker/ColorPicker.d.ts +19 -0
- package/types/components/ColorPicker/CustomColorList.d.ts +8 -0
- package/types/components/ColorPicker/HotkeyLabel.d.ts +8 -0
- package/types/components/ColorPicker/Picker.d.ts +18 -0
- package/types/components/ColorPicker/PickerColorList.d.ts +10 -0
- package/types/components/ColorPicker/PickerHeading.d.ts +5 -0
- package/types/components/ColorPicker/ShadeList.d.ts +8 -0
- package/types/components/ColorPicker/TopPicks.d.ts +9 -0
- package/types/components/ColorPicker/colorPickerUtils.d.ts +21 -0
- package/types/components/ColorPicker/keyboardNavHandlers.d.ts +20 -0
- package/types/components/ContextMenu.d.ts +3 -3
- package/types/components/DefaultSidebar.d.ts +29 -0
- package/types/components/Dialog.d.ts +3 -4
- package/types/components/ErrorDialog.d.ts +3 -2
- package/types/components/ExcalidrawLogo.d.ts +15 -0
- package/types/components/EyeDropper.d.ts +28 -0
- package/types/components/FilledButton.d.ts +17 -0
- package/types/components/FixedSideContainer.d.ts +1 -1
- package/types/components/HandButton.d.ts +1 -1
- package/types/components/HelpButton.d.ts +1 -2
- package/types/components/HintViewer.d.ts +4 -5
- package/types/components/HomeButton.d.ts +1 -1
- package/types/components/ImageExportDialog.d.ts +8 -13
- package/types/components/Island.d.ts +1 -1
- package/types/components/JSONExportDialog.d.ts +5 -5
- package/types/components/LaserTool/LaserPathManager.d.ts +28 -0
- package/types/components/LaserTool/LaserPointerButton.d.ts +10 -0
- package/types/components/LaserTool/LaserTool.d.ts +7 -0
- package/types/components/LayerUI.d.ts +9 -11
- package/types/components/LibraryMenu.d.ts +13 -14
- package/types/components/LibraryMenuBrowseButton.d.ts +2 -2
- package/types/components/LibraryMenuControlButtons.d.ts +9 -0
- package/types/components/LibraryMenuHeaderContent.d.ts +10 -28
- package/types/components/LibraryMenuItems.d.ts +6 -7
- package/types/components/LibraryMenuSection.d.ts +22 -0
- package/types/components/LibraryUnit.d.ts +6 -3
- package/types/components/LoadingMessage.d.ts +0 -1
- package/types/components/LockButton.d.ts +1 -1
- package/types/components/MobileMenu.d.ts +7 -6
- 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/PasteChartDialog.d.ts +4 -5
- package/types/components/PenModeButton.d.ts +1 -1
- package/types/components/Popover.d.ts +1 -1
- package/types/components/ProjectName.d.ts +2 -1
- package/types/components/PublishLibrary.d.ts +2 -2
- package/types/components/RadioGroup.d.ts +12 -0
- package/types/components/Section.d.ts +1 -1
- package/types/components/Sidebar/Sidebar.d.ts +66 -63
- package/types/components/Sidebar/SidebarHeader.d.ts +6 -19
- package/types/components/Sidebar/SidebarTab.d.ts +8 -0
- package/types/components/Sidebar/SidebarTabTrigger.d.ts +9 -0
- package/types/components/Sidebar/SidebarTabTriggers.d.ts +6 -0
- package/types/components/Sidebar/SidebarTabs.d.ts +6 -0
- package/types/components/Sidebar/SidebarTrigger.d.ts +6 -0
- package/types/components/Sidebar/common.d.ts +24 -7
- package/types/components/Spinner.d.ts +2 -1
- package/types/components/Stack.d.ts +4 -3
- package/types/components/Stats.d.ts +3 -3
- package/types/components/Switch.d.ts +9 -0
- package/types/components/ToolButton.d.ts +5 -4
- package/types/components/Tooltip.d.ts +1 -1
- package/types/components/Trans.d.ts +9 -0
- package/types/components/canvases/InteractiveCanvas.d.ts +27 -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 +9 -5
- package/types/components/dropdownMenu/DropdownMenuItem.d.ts +2 -1
- package/types/components/dropdownMenu/DropdownMenuItemCustom.d.ts +2 -1
- package/types/components/dropdownMenu/DropdownMenuItemLink.d.ts +2 -1
- package/types/components/dropdownMenu/DropdownMenuTrigger.d.ts +3 -2
- package/types/components/dropdownMenu/common.d.ts +1 -1
- package/types/components/footer/Footer.d.ts +2 -2
- package/types/components/icons.d.ts +15 -1
- package/types/components/live-collaboration/LiveCollaborationTrigger.d.ts +0 -1
- package/types/components/main-menu/MainMenu.d.ts +9 -5
- 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 +81 -11
- package/types/context/tunnels.d.ts +19 -0
- package/types/context/ui-appState.d.ts +4 -0
- package/types/data/blob.d.ts +3 -2
- package/types/data/encode.d.ts +1 -1
- package/types/data/filesystem.d.ts +2 -1
- package/types/data/index.d.ts +1 -1
- package/types/data/library.d.ts +3 -45
- package/types/data/restore.d.ts +2 -2
- package/types/data/transform.d.ts +71 -0
- package/types/data/types.d.ts +3 -5
- package/types/data/url.d.ts +7 -0
- package/types/element/Hyperlink.d.ts +48 -28
- package/types/element/binding.d.ts +4 -3
- package/types/element/bounds.d.ts +30 -6
- package/types/element/collision.d.ts +7 -7
- package/types/element/dragElements.d.ts +12 -2
- package/types/element/embeddable.d.ts +153 -0
- package/types/element/image.d.ts +11 -1
- package/types/element/index.d.ts +3 -2
- package/types/element/linearElementEditor.d.ts +40 -24
- package/types/element/mutateElement.d.ts +2 -1
- package/types/element/newElement.d.ts +49 -13
- package/types/element/resizeElements.d.ts +3 -2
- package/types/element/showSelectedShapeActions.d.ts +2 -2
- package/types/element/sizeHelpers.d.ts +8 -1
- package/types/element/textElement.d.ts +40 -15
- package/types/element/textWysiwyg.d.ts +1 -1
- package/types/element/transformHandles.d.ts +15 -8
- package/types/element/typeChecks.d.ts +4 -1
- package/types/element/types.d.ts +60 -35
- package/types/emitter.d.ts +1 -1
- package/types/errors.d.ts +1 -1
- package/types/frame.d.ts +40 -0
- package/types/ga.d.ts +5 -5
- package/types/groups.d.ts +15 -11
- package/types/history.d.ts +3 -3
- package/types/hooks/useCreatePortalContainer.d.ts +4 -0
- package/types/hooks/useLibraryItemSvg.d.ts +11 -0
- package/types/hooks/useOutsideClick.d.ts +19 -2
- package/types/hooks/useScrollPosition.d.ts +1 -0
- package/types/hooks/useStable.d.ts +1 -0
- package/types/hooks/useTransition.d.ts +2 -0
- package/types/i18n.d.ts +7 -4
- package/types/jotai.d.ts +16 -104
- package/types/keys.d.ts +5 -1
- package/types/math.d.ts +3 -0
- package/types/packages/excalidraw/example/initialData.d.ts +182 -64
- package/types/packages/excalidraw/index.d.ts +6 -2
- 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 +28 -24
- package/types/renderer/renderElement.d.ts +12 -22
- package/types/renderer/renderScene.d.ts +19 -29
- package/types/renderer/renderSnaps.d.ts +2 -0
- package/types/renderer/roundRect.d.ts +1 -1
- package/types/scene/Renderer.d.ts +25 -0
- package/types/scene/Scene.d.ts +27 -5
- package/types/scene/Shape.d.ts +12 -0
- package/types/scene/ShapeCache.d.ts +20 -0
- package/types/scene/export.d.ts +182 -10
- package/types/scene/scroll.d.ts +1 -1
- package/types/scene/scrollbars.d.ts +2 -6
- package/types/scene/selection.d.ts +27 -6
- package/types/scene/types.d.ts +69 -26
- package/types/snapping.d.ts +108 -0
- package/types/types.d.ts +189 -69
- package/types/utility-types.d.ts +24 -0
- package/types/utils.d.ts +72 -14
- package/types/zindex.d.ts +4 -4
- package/types/components/ColorPicker.d.ts +0 -14
- package/types/components/LibraryButton.d.ts +0 -8
- package/types/components/SingleLibraryItem.d.ts +0 -10
- package/types/components/context/tunnels.d.ts +0 -16
- package/types/components/hoc/withUpstreamOverride.d.ts +0 -10
- /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: {
|
|
@@ -9,7 +8,7 @@ export declare const actionChangeViewBackgroundColor: {
|
|
|
9
8
|
appState: any;
|
|
10
9
|
commitToHistory: boolean;
|
|
11
10
|
};
|
|
12
|
-
PanelComponent: ({ elements, appState, updateData }: import("./types").PanelComponentProps) => JSX.Element;
|
|
11
|
+
PanelComponent: ({ elements, appState, updateData, appProps }: import("./types").PanelComponentProps) => JSX.Element;
|
|
13
12
|
} & {
|
|
14
13
|
keyTest?: undefined;
|
|
15
14
|
};
|
|
@@ -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;
|
|
@@ -38,16 +37,16 @@ export declare const actionClearCanvas: {
|
|
|
38
37
|
data: import("../charts").Spreadsheet;
|
|
39
38
|
};
|
|
40
39
|
activeTool: {
|
|
41
|
-
lastActiveTool: import("../types").
|
|
40
|
+
lastActiveTool: import("../types").ActiveTool | null;
|
|
42
41
|
locked: boolean;
|
|
43
|
-
} & (
|
|
44
|
-
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser" | "hand";
|
|
45
|
-
customType: null;
|
|
46
|
-
} | {
|
|
47
|
-
type: "custom";
|
|
48
|
-
customType: string;
|
|
49
|
-
});
|
|
42
|
+
} & import("../types").ActiveTool;
|
|
50
43
|
name: string;
|
|
44
|
+
toast: {
|
|
45
|
+
message: string;
|
|
46
|
+
closable?: boolean | undefined;
|
|
47
|
+
duration?: number | undefined;
|
|
48
|
+
} | null;
|
|
49
|
+
collaborators: Map<string, import("../types").Collaborator>;
|
|
51
50
|
contextMenu: {
|
|
52
51
|
items: import("../components/ContextMenu").ContextMenuItems;
|
|
53
52
|
top: number;
|
|
@@ -55,7 +54,11 @@ export declare const actionClearCanvas: {
|
|
|
55
54
|
} | null;
|
|
56
55
|
showWelcomeScreen: boolean;
|
|
57
56
|
isLoading: boolean;
|
|
58
|
-
errorMessage:
|
|
57
|
+
errorMessage: import("react").ReactNode;
|
|
58
|
+
activeEmbeddable: {
|
|
59
|
+
element: import("../element/types").NonDeletedExcalidrawElement;
|
|
60
|
+
state: "active" | "hover";
|
|
61
|
+
} | null;
|
|
59
62
|
draggingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
60
63
|
resizingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
61
64
|
multiElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawLinearElement> | null;
|
|
@@ -63,6 +66,15 @@ export declare const actionClearCanvas: {
|
|
|
63
66
|
isBindingEnabled: boolean;
|
|
64
67
|
startBoundElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawBindableElement> | null;
|
|
65
68
|
suggestedBindings: import("../element/binding").SuggestedBinding[];
|
|
69
|
+
frameToHighlight: import("../element/types").NonDeleted<import("../element/types").ExcalidrawFrameElement> | null;
|
|
70
|
+
frameRendering: {
|
|
71
|
+
enabled: boolean;
|
|
72
|
+
name: boolean;
|
|
73
|
+
outline: boolean;
|
|
74
|
+
clip: boolean;
|
|
75
|
+
};
|
|
76
|
+
editingFrame: string | null;
|
|
77
|
+
elementsToHighlight: import("../element/types").NonDeleted<ExcalidrawElement>[] | null;
|
|
66
78
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
67
79
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
68
80
|
exportWithDarkMode: boolean;
|
|
@@ -91,23 +103,22 @@ export declare const actionClearCanvas: {
|
|
|
91
103
|
value: NormalizedZoomValue;
|
|
92
104
|
}>;
|
|
93
105
|
openMenu: "canvas" | "shape" | null;
|
|
94
|
-
openPopup: "
|
|
95
|
-
openSidebar:
|
|
106
|
+
openPopup: "canvasBackground" | "elementBackground" | "elementStroke" | null;
|
|
107
|
+
openSidebar: {
|
|
108
|
+
name: string;
|
|
109
|
+
tab?: string | undefined;
|
|
110
|
+
} | null;
|
|
96
111
|
openDialog: "imageExport" | "help" | "jsonExport" | null;
|
|
97
|
-
|
|
112
|
+
defaultSidebarDockedPreference: boolean;
|
|
98
113
|
lastPointerDownWith: import("../element/types").PointerType;
|
|
99
|
-
selectedElementIds: {
|
|
100
|
-
[id: string]:
|
|
101
|
-
}
|
|
114
|
+
selectedElementIds: Readonly<{
|
|
115
|
+
[id: string]: true;
|
|
116
|
+
}>;
|
|
102
117
|
previousSelectedElementIds: {
|
|
103
|
-
[id: string]:
|
|
118
|
+
[id: string]: true;
|
|
104
119
|
};
|
|
120
|
+
selectedElementsAreBeingDragged: boolean;
|
|
105
121
|
shouldCacheIgnoreZoom: boolean;
|
|
106
|
-
toast: {
|
|
107
|
-
message: string;
|
|
108
|
-
closable?: boolean | undefined;
|
|
109
|
-
duration?: number | undefined;
|
|
110
|
-
} | null;
|
|
111
122
|
zenModeEnabled: boolean;
|
|
112
123
|
viewModeEnabled: boolean;
|
|
113
124
|
selectedGroupIds: {
|
|
@@ -115,11 +126,16 @@ export declare const actionClearCanvas: {
|
|
|
115
126
|
};
|
|
116
127
|
editingGroupId: string | null;
|
|
117
128
|
fileHandle: import("browser-fs-access").FileSystemHandle | null;
|
|
118
|
-
collaborators: Map<string, import("../types").Collaborator>;
|
|
119
129
|
currentChartType: import("../element/types").ChartType;
|
|
120
130
|
pendingImageElementId: string | null;
|
|
121
|
-
showHyperlinkPopup: false | "
|
|
131
|
+
showHyperlinkPopup: false | "editor" | "info";
|
|
122
132
|
selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
133
|
+
snapLines: readonly import("../snapping").SnapLine[];
|
|
134
|
+
originSnapOffset: {
|
|
135
|
+
x: number;
|
|
136
|
+
y: number;
|
|
137
|
+
} | null;
|
|
138
|
+
objectsSnapModeEnabled: boolean;
|
|
123
139
|
};
|
|
124
140
|
commitToHistory: true;
|
|
125
141
|
};
|
|
@@ -146,7 +162,11 @@ export declare const actionZoomIn: {
|
|
|
146
162
|
} | null;
|
|
147
163
|
showWelcomeScreen: boolean;
|
|
148
164
|
isLoading: boolean;
|
|
149
|
-
errorMessage:
|
|
165
|
+
errorMessage: import("react").ReactNode;
|
|
166
|
+
activeEmbeddable: {
|
|
167
|
+
element: import("../element/types").NonDeletedExcalidrawElement;
|
|
168
|
+
state: "active" | "hover";
|
|
169
|
+
} | null;
|
|
150
170
|
draggingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
151
171
|
resizingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
152
172
|
multiElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawLinearElement> | null;
|
|
@@ -154,18 +174,21 @@ export declare const actionZoomIn: {
|
|
|
154
174
|
isBindingEnabled: boolean;
|
|
155
175
|
startBoundElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawBindableElement> | null;
|
|
156
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;
|
|
157
186
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
158
187
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
159
188
|
activeTool: {
|
|
160
|
-
lastActiveTool: import("../types").
|
|
189
|
+
lastActiveTool: import("../types").ActiveTool | null;
|
|
161
190
|
locked: boolean;
|
|
162
|
-
} & (
|
|
163
|
-
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser" | "hand";
|
|
164
|
-
customType: null;
|
|
165
|
-
} | {
|
|
166
|
-
type: "custom";
|
|
167
|
-
customType: string;
|
|
168
|
-
});
|
|
191
|
+
} & import("../types").ActiveTool;
|
|
169
192
|
penMode: boolean;
|
|
170
193
|
penDetected: boolean;
|
|
171
194
|
exportBackground: boolean;
|
|
@@ -192,17 +215,21 @@ export declare const actionZoomIn: {
|
|
|
192
215
|
isResizing: boolean;
|
|
193
216
|
isRotating: boolean;
|
|
194
217
|
openMenu: "canvas" | "shape" | null;
|
|
195
|
-
openPopup: "
|
|
196
|
-
openSidebar:
|
|
218
|
+
openPopup: "canvasBackground" | "elementBackground" | "elementStroke" | null;
|
|
219
|
+
openSidebar: {
|
|
220
|
+
name: string;
|
|
221
|
+
tab?: string | undefined;
|
|
222
|
+
} | null;
|
|
197
223
|
openDialog: "imageExport" | "help" | "jsonExport" | null;
|
|
198
|
-
|
|
224
|
+
defaultSidebarDockedPreference: boolean;
|
|
199
225
|
lastPointerDownWith: import("../element/types").PointerType;
|
|
200
|
-
selectedElementIds: {
|
|
201
|
-
[id: string]:
|
|
202
|
-
}
|
|
226
|
+
selectedElementIds: Readonly<{
|
|
227
|
+
[id: string]: true;
|
|
228
|
+
}>;
|
|
203
229
|
previousSelectedElementIds: {
|
|
204
|
-
[id: string]:
|
|
230
|
+
[id: string]: true;
|
|
205
231
|
};
|
|
232
|
+
selectedElementsAreBeingDragged: boolean;
|
|
206
233
|
shouldCacheIgnoreZoom: boolean;
|
|
207
234
|
toast: {
|
|
208
235
|
message: string;
|
|
@@ -210,7 +237,7 @@ export declare const actionZoomIn: {
|
|
|
210
237
|
duration?: number | undefined;
|
|
211
238
|
} | null;
|
|
212
239
|
zenModeEnabled: boolean;
|
|
213
|
-
theme:
|
|
240
|
+
theme: import("../element/types").Theme;
|
|
214
241
|
gridSize: number | null;
|
|
215
242
|
viewModeEnabled: boolean;
|
|
216
243
|
selectedGroupIds: {
|
|
@@ -233,15 +260,21 @@ export declare const actionZoomIn: {
|
|
|
233
260
|
data: import("../charts").Spreadsheet;
|
|
234
261
|
};
|
|
235
262
|
pendingImageElementId: string | null;
|
|
236
|
-
showHyperlinkPopup: false | "
|
|
263
|
+
showHyperlinkPopup: false | "editor" | "info";
|
|
237
264
|
selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
265
|
+
snapLines: readonly import("../snapping").SnapLine[];
|
|
266
|
+
originSnapOffset: {
|
|
267
|
+
x: number;
|
|
268
|
+
y: number;
|
|
269
|
+
} | null;
|
|
270
|
+
objectsSnapModeEnabled: boolean;
|
|
238
271
|
};
|
|
239
272
|
commitToHistory: false;
|
|
240
273
|
};
|
|
241
274
|
PanelComponent: ({ updateData }: import("./types").PanelComponentProps) => JSX.Element;
|
|
242
|
-
keyTest: (event:
|
|
275
|
+
keyTest: (event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean;
|
|
243
276
|
} & {
|
|
244
|
-
keyTest?: ((event:
|
|
277
|
+
keyTest?: ((event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean) | undefined;
|
|
245
278
|
};
|
|
246
279
|
export declare const actionZoomOut: {
|
|
247
280
|
name: "zoomOut";
|
|
@@ -263,7 +296,11 @@ export declare const actionZoomOut: {
|
|
|
263
296
|
} | null;
|
|
264
297
|
showWelcomeScreen: boolean;
|
|
265
298
|
isLoading: boolean;
|
|
266
|
-
errorMessage:
|
|
299
|
+
errorMessage: import("react").ReactNode;
|
|
300
|
+
activeEmbeddable: {
|
|
301
|
+
element: import("../element/types").NonDeletedExcalidrawElement;
|
|
302
|
+
state: "active" | "hover";
|
|
303
|
+
} | null;
|
|
267
304
|
draggingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
268
305
|
resizingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
269
306
|
multiElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawLinearElement> | null;
|
|
@@ -271,18 +308,21 @@ export declare const actionZoomOut: {
|
|
|
271
308
|
isBindingEnabled: boolean;
|
|
272
309
|
startBoundElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawBindableElement> | null;
|
|
273
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;
|
|
274
320
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
275
321
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
276
322
|
activeTool: {
|
|
277
|
-
lastActiveTool: import("../types").
|
|
323
|
+
lastActiveTool: import("../types").ActiveTool | null;
|
|
278
324
|
locked: boolean;
|
|
279
|
-
} & (
|
|
280
|
-
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser" | "hand";
|
|
281
|
-
customType: null;
|
|
282
|
-
} | {
|
|
283
|
-
type: "custom";
|
|
284
|
-
customType: string;
|
|
285
|
-
});
|
|
325
|
+
} & import("../types").ActiveTool;
|
|
286
326
|
penMode: boolean;
|
|
287
327
|
penDetected: boolean;
|
|
288
328
|
exportBackground: boolean;
|
|
@@ -309,17 +349,21 @@ export declare const actionZoomOut: {
|
|
|
309
349
|
isResizing: boolean;
|
|
310
350
|
isRotating: boolean;
|
|
311
351
|
openMenu: "canvas" | "shape" | null;
|
|
312
|
-
openPopup: "
|
|
313
|
-
openSidebar:
|
|
352
|
+
openPopup: "canvasBackground" | "elementBackground" | "elementStroke" | null;
|
|
353
|
+
openSidebar: {
|
|
354
|
+
name: string;
|
|
355
|
+
tab?: string | undefined;
|
|
356
|
+
} | null;
|
|
314
357
|
openDialog: "imageExport" | "help" | "jsonExport" | null;
|
|
315
|
-
|
|
358
|
+
defaultSidebarDockedPreference: boolean;
|
|
316
359
|
lastPointerDownWith: import("../element/types").PointerType;
|
|
317
|
-
selectedElementIds: {
|
|
318
|
-
[id: string]:
|
|
319
|
-
}
|
|
360
|
+
selectedElementIds: Readonly<{
|
|
361
|
+
[id: string]: true;
|
|
362
|
+
}>;
|
|
320
363
|
previousSelectedElementIds: {
|
|
321
|
-
[id: string]:
|
|
364
|
+
[id: string]: true;
|
|
322
365
|
};
|
|
366
|
+
selectedElementsAreBeingDragged: boolean;
|
|
323
367
|
shouldCacheIgnoreZoom: boolean;
|
|
324
368
|
toast: {
|
|
325
369
|
message: string;
|
|
@@ -327,7 +371,7 @@ export declare const actionZoomOut: {
|
|
|
327
371
|
duration?: number | undefined;
|
|
328
372
|
} | null;
|
|
329
373
|
zenModeEnabled: boolean;
|
|
330
|
-
theme:
|
|
374
|
+
theme: import("../element/types").Theme;
|
|
331
375
|
gridSize: number | null;
|
|
332
376
|
viewModeEnabled: boolean;
|
|
333
377
|
selectedGroupIds: {
|
|
@@ -350,15 +394,21 @@ export declare const actionZoomOut: {
|
|
|
350
394
|
data: import("../charts").Spreadsheet;
|
|
351
395
|
};
|
|
352
396
|
pendingImageElementId: string | null;
|
|
353
|
-
showHyperlinkPopup: false | "
|
|
397
|
+
showHyperlinkPopup: false | "editor" | "info";
|
|
354
398
|
selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
399
|
+
snapLines: readonly import("../snapping").SnapLine[];
|
|
400
|
+
originSnapOffset: {
|
|
401
|
+
x: number;
|
|
402
|
+
y: number;
|
|
403
|
+
} | null;
|
|
404
|
+
objectsSnapModeEnabled: boolean;
|
|
355
405
|
};
|
|
356
406
|
commitToHistory: false;
|
|
357
407
|
};
|
|
358
408
|
PanelComponent: ({ updateData }: import("./types").PanelComponentProps) => JSX.Element;
|
|
359
|
-
keyTest: (event:
|
|
409
|
+
keyTest: (event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean;
|
|
360
410
|
} & {
|
|
361
|
-
keyTest?: ((event:
|
|
411
|
+
keyTest?: ((event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean) | undefined;
|
|
362
412
|
};
|
|
363
413
|
export declare const actionResetZoom: {
|
|
364
414
|
name: "resetZoom";
|
|
@@ -380,7 +430,11 @@ export declare const actionResetZoom: {
|
|
|
380
430
|
} | null;
|
|
381
431
|
showWelcomeScreen: boolean;
|
|
382
432
|
isLoading: boolean;
|
|
383
|
-
errorMessage:
|
|
433
|
+
errorMessage: import("react").ReactNode;
|
|
434
|
+
activeEmbeddable: {
|
|
435
|
+
element: import("../element/types").NonDeletedExcalidrawElement;
|
|
436
|
+
state: "active" | "hover";
|
|
437
|
+
} | null;
|
|
384
438
|
draggingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
385
439
|
resizingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
386
440
|
multiElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawLinearElement> | null;
|
|
@@ -388,18 +442,21 @@ export declare const actionResetZoom: {
|
|
|
388
442
|
isBindingEnabled: boolean;
|
|
389
443
|
startBoundElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawBindableElement> | null;
|
|
390
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;
|
|
391
454
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
392
455
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
393
456
|
activeTool: {
|
|
394
|
-
lastActiveTool: import("../types").
|
|
457
|
+
lastActiveTool: import("../types").ActiveTool | null;
|
|
395
458
|
locked: boolean;
|
|
396
|
-
} & (
|
|
397
|
-
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser" | "hand";
|
|
398
|
-
customType: null;
|
|
399
|
-
} | {
|
|
400
|
-
type: "custom";
|
|
401
|
-
customType: string;
|
|
402
|
-
});
|
|
459
|
+
} & import("../types").ActiveTool;
|
|
403
460
|
penMode: boolean;
|
|
404
461
|
penDetected: boolean;
|
|
405
462
|
exportBackground: boolean;
|
|
@@ -426,17 +483,21 @@ export declare const actionResetZoom: {
|
|
|
426
483
|
isResizing: boolean;
|
|
427
484
|
isRotating: boolean;
|
|
428
485
|
openMenu: "canvas" | "shape" | null;
|
|
429
|
-
openPopup: "
|
|
430
|
-
openSidebar:
|
|
486
|
+
openPopup: "canvasBackground" | "elementBackground" | "elementStroke" | null;
|
|
487
|
+
openSidebar: {
|
|
488
|
+
name: string;
|
|
489
|
+
tab?: string | undefined;
|
|
490
|
+
} | null;
|
|
431
491
|
openDialog: "imageExport" | "help" | "jsonExport" | null;
|
|
432
|
-
|
|
492
|
+
defaultSidebarDockedPreference: boolean;
|
|
433
493
|
lastPointerDownWith: import("../element/types").PointerType;
|
|
434
|
-
selectedElementIds: {
|
|
435
|
-
[id: string]:
|
|
436
|
-
}
|
|
494
|
+
selectedElementIds: Readonly<{
|
|
495
|
+
[id: string]: true;
|
|
496
|
+
}>;
|
|
437
497
|
previousSelectedElementIds: {
|
|
438
|
-
[id: string]:
|
|
498
|
+
[id: string]: true;
|
|
439
499
|
};
|
|
500
|
+
selectedElementsAreBeingDragged: boolean;
|
|
440
501
|
shouldCacheIgnoreZoom: boolean;
|
|
441
502
|
toast: {
|
|
442
503
|
message: string;
|
|
@@ -444,7 +505,7 @@ export declare const actionResetZoom: {
|
|
|
444
505
|
duration?: number | undefined;
|
|
445
506
|
} | null;
|
|
446
507
|
zenModeEnabled: boolean;
|
|
447
|
-
theme:
|
|
508
|
+
theme: import("../element/types").Theme;
|
|
448
509
|
gridSize: number | null;
|
|
449
510
|
viewModeEnabled: boolean;
|
|
450
511
|
selectedGroupIds: {
|
|
@@ -467,28 +528,296 @@ export declare const actionResetZoom: {
|
|
|
467
528
|
data: import("../charts").Spreadsheet;
|
|
468
529
|
};
|
|
469
530
|
pendingImageElementId: string | null;
|
|
470
|
-
showHyperlinkPopup: false | "
|
|
531
|
+
showHyperlinkPopup: false | "editor" | "info";
|
|
471
532
|
selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
533
|
+
snapLines: readonly import("../snapping").SnapLine[];
|
|
534
|
+
originSnapOffset: {
|
|
535
|
+
x: number;
|
|
536
|
+
y: number;
|
|
537
|
+
} | null;
|
|
538
|
+
objectsSnapModeEnabled: boolean;
|
|
472
539
|
};
|
|
473
540
|
commitToHistory: false;
|
|
474
541
|
};
|
|
475
542
|
PanelComponent: ({ updateData, appState }: import("./types").PanelComponentProps) => JSX.Element;
|
|
476
|
-
keyTest: (event:
|
|
543
|
+
keyTest: (event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean;
|
|
477
544
|
} & {
|
|
478
|
-
keyTest?: ((event:
|
|
545
|
+
keyTest?: ((event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean) | undefined;
|
|
479
546
|
};
|
|
480
|
-
export declare const
|
|
481
|
-
|
|
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
|
+
}) => {
|
|
555
|
+
appState: {
|
|
556
|
+
scrollX: number;
|
|
557
|
+
scrollY: number;
|
|
558
|
+
zoom: {
|
|
559
|
+
value: NormalizedZoomValue;
|
|
560
|
+
};
|
|
561
|
+
contextMenu: {
|
|
562
|
+
items: import("../components/ContextMenu").ContextMenuItems;
|
|
563
|
+
top: number;
|
|
564
|
+
left: number;
|
|
565
|
+
} | null;
|
|
566
|
+
showWelcomeScreen: boolean;
|
|
567
|
+
isLoading: boolean;
|
|
568
|
+
errorMessage: import("react").ReactNode;
|
|
569
|
+
activeEmbeddable: {
|
|
570
|
+
element: import("../element/types").NonDeletedExcalidrawElement;
|
|
571
|
+
state: "active" | "hover";
|
|
572
|
+
} | null;
|
|
573
|
+
draggingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
574
|
+
resizingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
575
|
+
multiElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawLinearElement> | null;
|
|
576
|
+
selectionElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
577
|
+
isBindingEnabled: boolean;
|
|
578
|
+
startBoundElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawBindableElement> | null;
|
|
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;
|
|
589
|
+
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
590
|
+
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
591
|
+
activeTool: {
|
|
592
|
+
lastActiveTool: import("../types").ActiveTool | null;
|
|
593
|
+
locked: boolean;
|
|
594
|
+
} & import("../types").ActiveTool;
|
|
595
|
+
penMode: boolean;
|
|
596
|
+
penDetected: boolean;
|
|
597
|
+
exportBackground: boolean;
|
|
598
|
+
exportEmbedScene: boolean;
|
|
599
|
+
exportWithDarkMode: boolean;
|
|
600
|
+
exportScale: number;
|
|
601
|
+
currentItemStrokeColor: string;
|
|
602
|
+
currentItemBackgroundColor: string;
|
|
603
|
+
currentItemFillStyle: import("../element/types").FillStyle;
|
|
604
|
+
currentItemStrokeWidth: number;
|
|
605
|
+
currentItemStrokeStyle: import("../element/types").StrokeStyle;
|
|
606
|
+
currentItemRoughness: number;
|
|
607
|
+
currentItemOpacity: number;
|
|
608
|
+
currentItemFontFamily: number;
|
|
609
|
+
currentItemFontSize: number;
|
|
610
|
+
currentItemTextAlign: string;
|
|
611
|
+
currentItemStartArrowhead: import("../element/types").Arrowhead | null;
|
|
612
|
+
currentItemEndArrowhead: import("../element/types").Arrowhead | null;
|
|
613
|
+
currentItemRoundness: import("../element/types").StrokeRoundness;
|
|
614
|
+
viewBackgroundColor: string;
|
|
615
|
+
cursorButton: "up" | "down";
|
|
616
|
+
scrolledOutside: boolean;
|
|
617
|
+
name: string;
|
|
618
|
+
isResizing: boolean;
|
|
619
|
+
isRotating: boolean;
|
|
620
|
+
openMenu: "canvas" | "shape" | null;
|
|
621
|
+
openPopup: "canvasBackground" | "elementBackground" | "elementStroke" | null;
|
|
622
|
+
openSidebar: {
|
|
623
|
+
name: string;
|
|
624
|
+
tab?: string | undefined;
|
|
625
|
+
} | null;
|
|
626
|
+
openDialog: "imageExport" | "help" | "jsonExport" | null;
|
|
627
|
+
defaultSidebarDockedPreference: boolean;
|
|
628
|
+
lastPointerDownWith: import("../element/types").PointerType;
|
|
629
|
+
selectedElementIds: Readonly<{
|
|
630
|
+
[id: string]: true;
|
|
631
|
+
}>;
|
|
632
|
+
previousSelectedElementIds: {
|
|
633
|
+
[id: string]: true;
|
|
634
|
+
};
|
|
635
|
+
selectedElementsAreBeingDragged: boolean;
|
|
636
|
+
shouldCacheIgnoreZoom: boolean;
|
|
637
|
+
toast: {
|
|
638
|
+
message: string;
|
|
639
|
+
closable?: boolean | undefined;
|
|
640
|
+
duration?: number | undefined;
|
|
641
|
+
} | null;
|
|
642
|
+
zenModeEnabled: boolean;
|
|
643
|
+
theme: import("../element/types").Theme;
|
|
644
|
+
gridSize: number | null;
|
|
645
|
+
viewModeEnabled: boolean;
|
|
646
|
+
selectedGroupIds: {
|
|
647
|
+
[groupId: string]: boolean;
|
|
648
|
+
};
|
|
649
|
+
editingGroupId: string | null;
|
|
650
|
+
width: number;
|
|
651
|
+
height: number;
|
|
652
|
+
offsetTop: number;
|
|
653
|
+
offsetLeft: number;
|
|
654
|
+
fileHandle: import("browser-fs-access").FileSystemHandle | null;
|
|
655
|
+
collaborators: Map<string, import("../types").Collaborator>;
|
|
656
|
+
showStats: boolean;
|
|
657
|
+
currentChartType: import("../element/types").ChartType;
|
|
658
|
+
pasteDialog: {
|
|
659
|
+
shown: false;
|
|
660
|
+
data: null;
|
|
661
|
+
} | {
|
|
662
|
+
shown: true;
|
|
663
|
+
data: import("../charts").Spreadsheet;
|
|
664
|
+
};
|
|
665
|
+
pendingImageElementId: string | null;
|
|
666
|
+
showHyperlinkPopup: false | "editor" | "info";
|
|
667
|
+
selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
668
|
+
snapLines: readonly import("../snapping").SnapLine[];
|
|
669
|
+
originSnapOffset: {
|
|
670
|
+
x: number;
|
|
671
|
+
y: number;
|
|
672
|
+
} | null;
|
|
673
|
+
objectsSnapModeEnabled: boolean;
|
|
674
|
+
};
|
|
675
|
+
commitToHistory: boolean;
|
|
676
|
+
};
|
|
677
|
+
export declare const actionZoomToFitSelectionInViewport: {
|
|
678
|
+
name: "zoomToFitSelectionInViewport";
|
|
482
679
|
trackEvent: {
|
|
483
680
|
category: "canvas";
|
|
484
681
|
};
|
|
485
|
-
perform: (elements: readonly ExcalidrawElement[], appState: Readonly<AppState
|
|
682
|
+
perform: (elements: readonly ExcalidrawElement[], appState: Readonly<AppState>, _: any, app: import("../types").AppClassProperties) => {
|
|
486
683
|
appState: {
|
|
684
|
+
scrollX: number;
|
|
685
|
+
scrollY: number;
|
|
487
686
|
zoom: {
|
|
488
687
|
value: NormalizedZoomValue;
|
|
489
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").ActiveTool | null;
|
|
721
|
+
locked: boolean;
|
|
722
|
+
} & import("../types").ActiveTool;
|
|
723
|
+
penMode: boolean;
|
|
724
|
+
penDetected: boolean;
|
|
725
|
+
exportBackground: boolean;
|
|
726
|
+
exportEmbedScene: boolean;
|
|
727
|
+
exportWithDarkMode: boolean;
|
|
728
|
+
exportScale: number;
|
|
729
|
+
currentItemStrokeColor: string;
|
|
730
|
+
currentItemBackgroundColor: string;
|
|
731
|
+
currentItemFillStyle: import("../element/types").FillStyle;
|
|
732
|
+
currentItemStrokeWidth: number;
|
|
733
|
+
currentItemStrokeStyle: import("../element/types").StrokeStyle;
|
|
734
|
+
currentItemRoughness: number;
|
|
735
|
+
currentItemOpacity: number;
|
|
736
|
+
currentItemFontFamily: number;
|
|
737
|
+
currentItemFontSize: number;
|
|
738
|
+
currentItemTextAlign: string;
|
|
739
|
+
currentItemStartArrowhead: import("../element/types").Arrowhead | null;
|
|
740
|
+
currentItemEndArrowhead: import("../element/types").Arrowhead | null;
|
|
741
|
+
currentItemRoundness: import("../element/types").StrokeRoundness;
|
|
742
|
+
viewBackgroundColor: string;
|
|
743
|
+
cursorButton: "up" | "down";
|
|
744
|
+
scrolledOutside: boolean;
|
|
745
|
+
name: string;
|
|
746
|
+
isResizing: boolean;
|
|
747
|
+
isRotating: boolean;
|
|
748
|
+
openMenu: "canvas" | "shape" | null;
|
|
749
|
+
openPopup: "canvasBackground" | "elementBackground" | "elementStroke" | null;
|
|
750
|
+
openSidebar: {
|
|
751
|
+
name: string;
|
|
752
|
+
tab?: string | undefined;
|
|
753
|
+
} | null;
|
|
754
|
+
openDialog: "imageExport" | "help" | "jsonExport" | null;
|
|
755
|
+
defaultSidebarDockedPreference: boolean;
|
|
756
|
+
lastPointerDownWith: import("../element/types").PointerType;
|
|
757
|
+
selectedElementIds: Readonly<{
|
|
758
|
+
[id: string]: true;
|
|
759
|
+
}>;
|
|
760
|
+
previousSelectedElementIds: {
|
|
761
|
+
[id: string]: true;
|
|
762
|
+
};
|
|
763
|
+
selectedElementsAreBeingDragged: boolean;
|
|
764
|
+
shouldCacheIgnoreZoom: boolean;
|
|
765
|
+
toast: {
|
|
766
|
+
message: string;
|
|
767
|
+
closable?: boolean | undefined;
|
|
768
|
+
duration?: number | undefined;
|
|
769
|
+
} | null;
|
|
770
|
+
zenModeEnabled: boolean;
|
|
771
|
+
theme: import("../element/types").Theme;
|
|
772
|
+
gridSize: number | null;
|
|
773
|
+
viewModeEnabled: boolean;
|
|
774
|
+
selectedGroupIds: {
|
|
775
|
+
[groupId: string]: boolean;
|
|
776
|
+
};
|
|
777
|
+
editingGroupId: string | null;
|
|
778
|
+
width: number;
|
|
779
|
+
height: number;
|
|
780
|
+
offsetTop: number;
|
|
781
|
+
offsetLeft: number;
|
|
782
|
+
fileHandle: import("browser-fs-access").FileSystemHandle | null;
|
|
783
|
+
collaborators: Map<string, import("../types").Collaborator>;
|
|
784
|
+
showStats: boolean;
|
|
785
|
+
currentChartType: import("../element/types").ChartType;
|
|
786
|
+
pasteDialog: {
|
|
787
|
+
shown: false;
|
|
788
|
+
data: null;
|
|
789
|
+
} | {
|
|
790
|
+
shown: true;
|
|
791
|
+
data: import("../charts").Spreadsheet;
|
|
792
|
+
};
|
|
793
|
+
pendingImageElementId: string | null;
|
|
794
|
+
showHyperlinkPopup: false | "editor" | "info";
|
|
795
|
+
selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
796
|
+
snapLines: readonly import("../snapping").SnapLine[];
|
|
797
|
+
originSnapOffset: {
|
|
798
|
+
x: number;
|
|
799
|
+
y: number;
|
|
800
|
+
} | null;
|
|
801
|
+
objectsSnapModeEnabled: boolean;
|
|
802
|
+
};
|
|
803
|
+
commitToHistory: boolean;
|
|
804
|
+
};
|
|
805
|
+
keyTest: (event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean;
|
|
806
|
+
} & {
|
|
807
|
+
keyTest?: ((event: import("react").KeyboardEvent<Element> | KeyboardEvent) => 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: {
|
|
490
816
|
scrollX: number;
|
|
491
817
|
scrollY: number;
|
|
818
|
+
zoom: {
|
|
819
|
+
value: NormalizedZoomValue;
|
|
820
|
+
};
|
|
492
821
|
contextMenu: {
|
|
493
822
|
items: import("../components/ContextMenu").ContextMenuItems;
|
|
494
823
|
top: number;
|
|
@@ -496,7 +825,11 @@ export declare const actionZoomToSelected: {
|
|
|
496
825
|
} | null;
|
|
497
826
|
showWelcomeScreen: boolean;
|
|
498
827
|
isLoading: boolean;
|
|
499
|
-
errorMessage:
|
|
828
|
+
errorMessage: import("react").ReactNode;
|
|
829
|
+
activeEmbeddable: {
|
|
830
|
+
element: import("../element/types").NonDeletedExcalidrawElement;
|
|
831
|
+
state: "active" | "hover";
|
|
832
|
+
} | null;
|
|
500
833
|
draggingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
501
834
|
resizingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
502
835
|
multiElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawLinearElement> | null;
|
|
@@ -504,18 +837,21 @@ export declare const actionZoomToSelected: {
|
|
|
504
837
|
isBindingEnabled: boolean;
|
|
505
838
|
startBoundElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawBindableElement> | null;
|
|
506
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;
|
|
507
849
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
508
850
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
509
851
|
activeTool: {
|
|
510
|
-
lastActiveTool: import("../types").
|
|
852
|
+
lastActiveTool: import("../types").ActiveTool | null;
|
|
511
853
|
locked: boolean;
|
|
512
|
-
} & (
|
|
513
|
-
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser" | "hand";
|
|
514
|
-
customType: null;
|
|
515
|
-
} | {
|
|
516
|
-
type: "custom";
|
|
517
|
-
customType: string;
|
|
518
|
-
});
|
|
854
|
+
} & import("../types").ActiveTool;
|
|
519
855
|
penMode: boolean;
|
|
520
856
|
penDetected: boolean;
|
|
521
857
|
exportBackground: boolean;
|
|
@@ -542,17 +878,21 @@ export declare const actionZoomToSelected: {
|
|
|
542
878
|
isResizing: boolean;
|
|
543
879
|
isRotating: boolean;
|
|
544
880
|
openMenu: "canvas" | "shape" | null;
|
|
545
|
-
openPopup: "
|
|
546
|
-
openSidebar:
|
|
881
|
+
openPopup: "canvasBackground" | "elementBackground" | "elementStroke" | null;
|
|
882
|
+
openSidebar: {
|
|
883
|
+
name: string;
|
|
884
|
+
tab?: string | undefined;
|
|
885
|
+
} | null;
|
|
547
886
|
openDialog: "imageExport" | "help" | "jsonExport" | null;
|
|
548
|
-
|
|
887
|
+
defaultSidebarDockedPreference: boolean;
|
|
549
888
|
lastPointerDownWith: import("../element/types").PointerType;
|
|
550
|
-
selectedElementIds: {
|
|
551
|
-
[id: string]:
|
|
552
|
-
}
|
|
889
|
+
selectedElementIds: Readonly<{
|
|
890
|
+
[id: string]: true;
|
|
891
|
+
}>;
|
|
553
892
|
previousSelectedElementIds: {
|
|
554
|
-
[id: string]:
|
|
893
|
+
[id: string]: true;
|
|
555
894
|
};
|
|
895
|
+
selectedElementsAreBeingDragged: boolean;
|
|
556
896
|
shouldCacheIgnoreZoom: boolean;
|
|
557
897
|
toast: {
|
|
558
898
|
message: string;
|
|
@@ -560,7 +900,7 @@ export declare const actionZoomToSelected: {
|
|
|
560
900
|
duration?: number | undefined;
|
|
561
901
|
} | null;
|
|
562
902
|
zenModeEnabled: boolean;
|
|
563
|
-
theme:
|
|
903
|
+
theme: import("../element/types").Theme;
|
|
564
904
|
gridSize: number | null;
|
|
565
905
|
viewModeEnabled: boolean;
|
|
566
906
|
selectedGroupIds: {
|
|
@@ -583,14 +923,20 @@ export declare const actionZoomToSelected: {
|
|
|
583
923
|
data: import("../charts").Spreadsheet;
|
|
584
924
|
};
|
|
585
925
|
pendingImageElementId: string | null;
|
|
586
|
-
showHyperlinkPopup: false | "
|
|
926
|
+
showHyperlinkPopup: false | "editor" | "info";
|
|
587
927
|
selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
928
|
+
snapLines: readonly import("../snapping").SnapLine[];
|
|
929
|
+
originSnapOffset: {
|
|
930
|
+
x: number;
|
|
931
|
+
y: number;
|
|
932
|
+
} | null;
|
|
933
|
+
objectsSnapModeEnabled: boolean;
|
|
588
934
|
};
|
|
589
935
|
commitToHistory: boolean;
|
|
590
936
|
};
|
|
591
|
-
keyTest: (event:
|
|
937
|
+
keyTest: (event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean;
|
|
592
938
|
} & {
|
|
593
|
-
keyTest?: ((event:
|
|
939
|
+
keyTest?: ((event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean) | undefined;
|
|
594
940
|
};
|
|
595
941
|
export declare const actionZoomToFit: {
|
|
596
942
|
name: "zoomToFit";
|
|
@@ -600,11 +946,11 @@ export declare const actionZoomToFit: {
|
|
|
600
946
|
};
|
|
601
947
|
perform: (elements: readonly ExcalidrawElement[], appState: Readonly<AppState>) => {
|
|
602
948
|
appState: {
|
|
949
|
+
scrollX: number;
|
|
950
|
+
scrollY: number;
|
|
603
951
|
zoom: {
|
|
604
952
|
value: NormalizedZoomValue;
|
|
605
953
|
};
|
|
606
|
-
scrollX: number;
|
|
607
|
-
scrollY: number;
|
|
608
954
|
contextMenu: {
|
|
609
955
|
items: import("../components/ContextMenu").ContextMenuItems;
|
|
610
956
|
top: number;
|
|
@@ -612,7 +958,11 @@ export declare const actionZoomToFit: {
|
|
|
612
958
|
} | null;
|
|
613
959
|
showWelcomeScreen: boolean;
|
|
614
960
|
isLoading: boolean;
|
|
615
|
-
errorMessage:
|
|
961
|
+
errorMessage: import("react").ReactNode;
|
|
962
|
+
activeEmbeddable: {
|
|
963
|
+
element: import("../element/types").NonDeletedExcalidrawElement;
|
|
964
|
+
state: "active" | "hover";
|
|
965
|
+
} | null;
|
|
616
966
|
draggingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
617
967
|
resizingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
618
968
|
multiElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawLinearElement> | null;
|
|
@@ -620,18 +970,21 @@ export declare const actionZoomToFit: {
|
|
|
620
970
|
isBindingEnabled: boolean;
|
|
621
971
|
startBoundElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawBindableElement> | null;
|
|
622
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;
|
|
623
982
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
624
983
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
625
984
|
activeTool: {
|
|
626
|
-
lastActiveTool: import("../types").
|
|
985
|
+
lastActiveTool: import("../types").ActiveTool | null;
|
|
627
986
|
locked: boolean;
|
|
628
|
-
} & (
|
|
629
|
-
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser" | "hand";
|
|
630
|
-
customType: null;
|
|
631
|
-
} | {
|
|
632
|
-
type: "custom";
|
|
633
|
-
customType: string;
|
|
634
|
-
});
|
|
987
|
+
} & import("../types").ActiveTool;
|
|
635
988
|
penMode: boolean;
|
|
636
989
|
penDetected: boolean;
|
|
637
990
|
exportBackground: boolean;
|
|
@@ -658,17 +1011,21 @@ export declare const actionZoomToFit: {
|
|
|
658
1011
|
isResizing: boolean;
|
|
659
1012
|
isRotating: boolean;
|
|
660
1013
|
openMenu: "canvas" | "shape" | null;
|
|
661
|
-
openPopup: "
|
|
662
|
-
openSidebar:
|
|
1014
|
+
openPopup: "canvasBackground" | "elementBackground" | "elementStroke" | null;
|
|
1015
|
+
openSidebar: {
|
|
1016
|
+
name: string;
|
|
1017
|
+
tab?: string | undefined;
|
|
1018
|
+
} | null;
|
|
663
1019
|
openDialog: "imageExport" | "help" | "jsonExport" | null;
|
|
664
|
-
|
|
1020
|
+
defaultSidebarDockedPreference: boolean;
|
|
665
1021
|
lastPointerDownWith: import("../element/types").PointerType;
|
|
666
|
-
selectedElementIds: {
|
|
667
|
-
[id: string]:
|
|
668
|
-
}
|
|
1022
|
+
selectedElementIds: Readonly<{
|
|
1023
|
+
[id: string]: true;
|
|
1024
|
+
}>;
|
|
669
1025
|
previousSelectedElementIds: {
|
|
670
|
-
[id: string]:
|
|
1026
|
+
[id: string]: true;
|
|
671
1027
|
};
|
|
1028
|
+
selectedElementsAreBeingDragged: boolean;
|
|
672
1029
|
shouldCacheIgnoreZoom: boolean;
|
|
673
1030
|
toast: {
|
|
674
1031
|
message: string;
|
|
@@ -676,7 +1033,7 @@ export declare const actionZoomToFit: {
|
|
|
676
1033
|
duration?: number | undefined;
|
|
677
1034
|
} | null;
|
|
678
1035
|
zenModeEnabled: boolean;
|
|
679
|
-
theme:
|
|
1036
|
+
theme: import("../element/types").Theme;
|
|
680
1037
|
gridSize: number | null;
|
|
681
1038
|
viewModeEnabled: boolean;
|
|
682
1039
|
selectedGroupIds: {
|
|
@@ -699,14 +1056,20 @@ export declare const actionZoomToFit: {
|
|
|
699
1056
|
data: import("../charts").Spreadsheet;
|
|
700
1057
|
};
|
|
701
1058
|
pendingImageElementId: string | null;
|
|
702
|
-
showHyperlinkPopup: false | "
|
|
1059
|
+
showHyperlinkPopup: false | "editor" | "info";
|
|
703
1060
|
selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
1061
|
+
snapLines: readonly import("../snapping").SnapLine[];
|
|
1062
|
+
originSnapOffset: {
|
|
1063
|
+
x: number;
|
|
1064
|
+
y: number;
|
|
1065
|
+
} | null;
|
|
1066
|
+
objectsSnapModeEnabled: boolean;
|
|
704
1067
|
};
|
|
705
1068
|
commitToHistory: boolean;
|
|
706
1069
|
};
|
|
707
|
-
keyTest: (event:
|
|
1070
|
+
keyTest: (event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean;
|
|
708
1071
|
} & {
|
|
709
|
-
keyTest?: ((event:
|
|
1072
|
+
keyTest?: ((event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean) | undefined;
|
|
710
1073
|
};
|
|
711
1074
|
export declare const actionToggleTheme: {
|
|
712
1075
|
name: "toggleTheme";
|
|
@@ -724,7 +1087,11 @@ export declare const actionToggleTheme: {
|
|
|
724
1087
|
} | null;
|
|
725
1088
|
showWelcomeScreen: boolean;
|
|
726
1089
|
isLoading: boolean;
|
|
727
|
-
errorMessage:
|
|
1090
|
+
errorMessage: import("react").ReactNode;
|
|
1091
|
+
activeEmbeddable: {
|
|
1092
|
+
element: import("../element/types").NonDeletedExcalidrawElement;
|
|
1093
|
+
state: "active" | "hover";
|
|
1094
|
+
} | null;
|
|
728
1095
|
draggingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
729
1096
|
resizingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
730
1097
|
multiElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawLinearElement> | null;
|
|
@@ -732,18 +1099,21 @@ export declare const actionToggleTheme: {
|
|
|
732
1099
|
isBindingEnabled: boolean;
|
|
733
1100
|
startBoundElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawBindableElement> | null;
|
|
734
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;
|
|
735
1111
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
736
1112
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
737
1113
|
activeTool: {
|
|
738
|
-
lastActiveTool: import("../types").
|
|
1114
|
+
lastActiveTool: import("../types").ActiveTool | null;
|
|
739
1115
|
locked: boolean;
|
|
740
|
-
} & (
|
|
741
|
-
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser" | "hand";
|
|
742
|
-
customType: null;
|
|
743
|
-
} | {
|
|
744
|
-
type: "custom";
|
|
745
|
-
customType: string;
|
|
746
|
-
});
|
|
1116
|
+
} & import("../types").ActiveTool;
|
|
747
1117
|
penMode: boolean;
|
|
748
1118
|
penDetected: boolean;
|
|
749
1119
|
exportBackground: boolean;
|
|
@@ -775,17 +1145,21 @@ export declare const actionToggleTheme: {
|
|
|
775
1145
|
value: NormalizedZoomValue;
|
|
776
1146
|
}>;
|
|
777
1147
|
openMenu: "canvas" | "shape" | null;
|
|
778
|
-
openPopup: "
|
|
779
|
-
openSidebar:
|
|
1148
|
+
openPopup: "canvasBackground" | "elementBackground" | "elementStroke" | null;
|
|
1149
|
+
openSidebar: {
|
|
1150
|
+
name: string;
|
|
1151
|
+
tab?: string | undefined;
|
|
1152
|
+
} | null;
|
|
780
1153
|
openDialog: "imageExport" | "help" | "jsonExport" | null;
|
|
781
|
-
|
|
1154
|
+
defaultSidebarDockedPreference: boolean;
|
|
782
1155
|
lastPointerDownWith: import("../element/types").PointerType;
|
|
783
|
-
selectedElementIds: {
|
|
784
|
-
[id: string]:
|
|
785
|
-
}
|
|
1156
|
+
selectedElementIds: Readonly<{
|
|
1157
|
+
[id: string]: true;
|
|
1158
|
+
}>;
|
|
786
1159
|
previousSelectedElementIds: {
|
|
787
|
-
[id: string]:
|
|
1160
|
+
[id: string]: true;
|
|
788
1161
|
};
|
|
1162
|
+
selectedElementsAreBeingDragged: boolean;
|
|
789
1163
|
shouldCacheIgnoreZoom: boolean;
|
|
790
1164
|
toast: {
|
|
791
1165
|
message: string;
|
|
@@ -815,15 +1189,21 @@ export declare const actionToggleTheme: {
|
|
|
815
1189
|
data: import("../charts").Spreadsheet;
|
|
816
1190
|
};
|
|
817
1191
|
pendingImageElementId: string | null;
|
|
818
|
-
showHyperlinkPopup: false | "
|
|
1192
|
+
showHyperlinkPopup: false | "editor" | "info";
|
|
819
1193
|
selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
1194
|
+
snapLines: readonly import("../snapping").SnapLine[];
|
|
1195
|
+
originSnapOffset: {
|
|
1196
|
+
x: number;
|
|
1197
|
+
y: number;
|
|
1198
|
+
} | null;
|
|
1199
|
+
objectsSnapModeEnabled: boolean;
|
|
820
1200
|
};
|
|
821
1201
|
commitToHistory: false;
|
|
822
1202
|
};
|
|
823
|
-
keyTest: (event:
|
|
1203
|
+
keyTest: (event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean;
|
|
824
1204
|
predicate: (elements: readonly ExcalidrawElement[], appState: AppState, props: import("../types").ExcalidrawProps, app: import("../types").AppClassProperties) => boolean;
|
|
825
1205
|
} & {
|
|
826
|
-
keyTest?: ((event:
|
|
1206
|
+
keyTest?: ((event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean) | undefined;
|
|
827
1207
|
};
|
|
828
1208
|
export declare const actionToggleEraserTool: {
|
|
829
1209
|
name: "toggleEraserTool";
|
|
@@ -834,16 +1214,11 @@ export declare const actionToggleEraserTool: {
|
|
|
834
1214
|
appState: {
|
|
835
1215
|
selectedElementIds: {};
|
|
836
1216
|
selectedGroupIds: {};
|
|
1217
|
+
activeEmbeddable: null;
|
|
837
1218
|
activeTool: {
|
|
838
|
-
lastActiveTool: import("../types").
|
|
1219
|
+
lastActiveTool: import("../types").ActiveTool | null;
|
|
839
1220
|
locked: boolean;
|
|
840
|
-
} & (
|
|
841
|
-
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser" | "hand";
|
|
842
|
-
customType: null;
|
|
843
|
-
} | {
|
|
844
|
-
type: "custom";
|
|
845
|
-
customType: string;
|
|
846
|
-
});
|
|
1221
|
+
} & import("../types").ActiveTool;
|
|
847
1222
|
contextMenu: {
|
|
848
1223
|
items: import("../components/ContextMenu").ContextMenuItems;
|
|
849
1224
|
top: number;
|
|
@@ -851,7 +1226,7 @@ export declare const actionToggleEraserTool: {
|
|
|
851
1226
|
} | null;
|
|
852
1227
|
showWelcomeScreen: boolean;
|
|
853
1228
|
isLoading: boolean;
|
|
854
|
-
errorMessage:
|
|
1229
|
+
errorMessage: import("react").ReactNode;
|
|
855
1230
|
draggingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
856
1231
|
resizingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
857
1232
|
multiElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawLinearElement> | null;
|
|
@@ -859,6 +1234,15 @@ export declare const actionToggleEraserTool: {
|
|
|
859
1234
|
isBindingEnabled: boolean;
|
|
860
1235
|
startBoundElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawBindableElement> | null;
|
|
861
1236
|
suggestedBindings: import("../element/binding").SuggestedBinding[];
|
|
1237
|
+
frameToHighlight: import("../element/types").NonDeleted<import("../element/types").ExcalidrawFrameElement> | null;
|
|
1238
|
+
frameRendering: {
|
|
1239
|
+
enabled: boolean;
|
|
1240
|
+
name: boolean;
|
|
1241
|
+
outline: boolean;
|
|
1242
|
+
clip: boolean;
|
|
1243
|
+
};
|
|
1244
|
+
editingFrame: string | null;
|
|
1245
|
+
elementsToHighlight: import("../element/types").NonDeleted<ExcalidrawElement>[] | null;
|
|
862
1246
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
863
1247
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
864
1248
|
penMode: boolean;
|
|
@@ -892,14 +1276,18 @@ export declare const actionToggleEraserTool: {
|
|
|
892
1276
|
value: NormalizedZoomValue;
|
|
893
1277
|
}>;
|
|
894
1278
|
openMenu: "canvas" | "shape" | null;
|
|
895
|
-
openPopup: "
|
|
896
|
-
openSidebar:
|
|
1279
|
+
openPopup: "canvasBackground" | "elementBackground" | "elementStroke" | null;
|
|
1280
|
+
openSidebar: {
|
|
1281
|
+
name: string;
|
|
1282
|
+
tab?: string | undefined;
|
|
1283
|
+
} | null;
|
|
897
1284
|
openDialog: "imageExport" | "help" | "jsonExport" | null;
|
|
898
|
-
|
|
1285
|
+
defaultSidebarDockedPreference: boolean;
|
|
899
1286
|
lastPointerDownWith: import("../element/types").PointerType;
|
|
900
1287
|
previousSelectedElementIds: {
|
|
901
|
-
[id: string]:
|
|
1288
|
+
[id: string]: true;
|
|
902
1289
|
};
|
|
1290
|
+
selectedElementsAreBeingDragged: boolean;
|
|
903
1291
|
shouldCacheIgnoreZoom: boolean;
|
|
904
1292
|
toast: {
|
|
905
1293
|
message: string;
|
|
@@ -907,7 +1295,7 @@ export declare const actionToggleEraserTool: {
|
|
|
907
1295
|
duration?: number | undefined;
|
|
908
1296
|
} | null;
|
|
909
1297
|
zenModeEnabled: boolean;
|
|
910
|
-
theme:
|
|
1298
|
+
theme: import("../element/types").Theme;
|
|
911
1299
|
gridSize: number | null;
|
|
912
1300
|
viewModeEnabled: boolean;
|
|
913
1301
|
editingGroupId: string | null;
|
|
@@ -927,14 +1315,20 @@ export declare const actionToggleEraserTool: {
|
|
|
927
1315
|
data: import("../charts").Spreadsheet;
|
|
928
1316
|
};
|
|
929
1317
|
pendingImageElementId: string | null;
|
|
930
|
-
showHyperlinkPopup: false | "
|
|
1318
|
+
showHyperlinkPopup: false | "editor" | "info";
|
|
931
1319
|
selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
1320
|
+
snapLines: readonly import("../snapping").SnapLine[];
|
|
1321
|
+
originSnapOffset: {
|
|
1322
|
+
x: number;
|
|
1323
|
+
y: number;
|
|
1324
|
+
} | null;
|
|
1325
|
+
objectsSnapModeEnabled: boolean;
|
|
932
1326
|
};
|
|
933
1327
|
commitToHistory: true;
|
|
934
1328
|
};
|
|
935
|
-
keyTest: (event:
|
|
1329
|
+
keyTest: (event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean;
|
|
936
1330
|
} & {
|
|
937
|
-
keyTest?: ((event:
|
|
1331
|
+
keyTest?: ((event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean) | undefined;
|
|
938
1332
|
};
|
|
939
1333
|
export declare const actionToggleHandTool: {
|
|
940
1334
|
name: "toggleHandTool";
|
|
@@ -945,16 +1339,11 @@ export declare const actionToggleHandTool: {
|
|
|
945
1339
|
appState: {
|
|
946
1340
|
selectedElementIds: {};
|
|
947
1341
|
selectedGroupIds: {};
|
|
1342
|
+
activeEmbeddable: null;
|
|
948
1343
|
activeTool: {
|
|
949
|
-
lastActiveTool: import("../types").
|
|
1344
|
+
lastActiveTool: import("../types").ActiveTool | null;
|
|
950
1345
|
locked: boolean;
|
|
951
|
-
} & (
|
|
952
|
-
type: "line" | "arrow" | "text" | "selection" | "rectangle" | "diamond" | "ellipse" | "image" | "freedraw" | "eraser" | "hand";
|
|
953
|
-
customType: null;
|
|
954
|
-
} | {
|
|
955
|
-
type: "custom";
|
|
956
|
-
customType: string;
|
|
957
|
-
});
|
|
1346
|
+
} & import("../types").ActiveTool;
|
|
958
1347
|
contextMenu: {
|
|
959
1348
|
items: import("../components/ContextMenu").ContextMenuItems;
|
|
960
1349
|
top: number;
|
|
@@ -962,7 +1351,7 @@ export declare const actionToggleHandTool: {
|
|
|
962
1351
|
} | null;
|
|
963
1352
|
showWelcomeScreen: boolean;
|
|
964
1353
|
isLoading: boolean;
|
|
965
|
-
errorMessage:
|
|
1354
|
+
errorMessage: import("react").ReactNode;
|
|
966
1355
|
draggingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
967
1356
|
resizingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
968
1357
|
multiElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawLinearElement> | null;
|
|
@@ -970,6 +1359,15 @@ export declare const actionToggleHandTool: {
|
|
|
970
1359
|
isBindingEnabled: boolean;
|
|
971
1360
|
startBoundElement: import("../element/types").NonDeleted<import("../element/types").ExcalidrawBindableElement> | null;
|
|
972
1361
|
suggestedBindings: import("../element/binding").SuggestedBinding[];
|
|
1362
|
+
frameToHighlight: import("../element/types").NonDeleted<import("../element/types").ExcalidrawFrameElement> | null;
|
|
1363
|
+
frameRendering: {
|
|
1364
|
+
enabled: boolean;
|
|
1365
|
+
name: boolean;
|
|
1366
|
+
outline: boolean;
|
|
1367
|
+
clip: boolean;
|
|
1368
|
+
};
|
|
1369
|
+
editingFrame: string | null;
|
|
1370
|
+
elementsToHighlight: import("../element/types").NonDeleted<ExcalidrawElement>[] | null;
|
|
973
1371
|
editingElement: import("../element/types").NonDeletedExcalidrawElement | null;
|
|
974
1372
|
editingLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
975
1373
|
penMode: boolean;
|
|
@@ -1003,14 +1401,18 @@ export declare const actionToggleHandTool: {
|
|
|
1003
1401
|
value: NormalizedZoomValue;
|
|
1004
1402
|
}>;
|
|
1005
1403
|
openMenu: "canvas" | "shape" | null;
|
|
1006
|
-
openPopup: "
|
|
1007
|
-
openSidebar:
|
|
1404
|
+
openPopup: "canvasBackground" | "elementBackground" | "elementStroke" | null;
|
|
1405
|
+
openSidebar: {
|
|
1406
|
+
name: string;
|
|
1407
|
+
tab?: string | undefined;
|
|
1408
|
+
} | null;
|
|
1008
1409
|
openDialog: "imageExport" | "help" | "jsonExport" | null;
|
|
1009
|
-
|
|
1410
|
+
defaultSidebarDockedPreference: boolean;
|
|
1010
1411
|
lastPointerDownWith: import("../element/types").PointerType;
|
|
1011
1412
|
previousSelectedElementIds: {
|
|
1012
|
-
[id: string]:
|
|
1413
|
+
[id: string]: true;
|
|
1013
1414
|
};
|
|
1415
|
+
selectedElementsAreBeingDragged: boolean;
|
|
1014
1416
|
shouldCacheIgnoreZoom: boolean;
|
|
1015
1417
|
toast: {
|
|
1016
1418
|
message: string;
|
|
@@ -1018,7 +1420,7 @@ export declare const actionToggleHandTool: {
|
|
|
1018
1420
|
duration?: number | undefined;
|
|
1019
1421
|
} | null;
|
|
1020
1422
|
zenModeEnabled: boolean;
|
|
1021
|
-
theme:
|
|
1423
|
+
theme: import("../element/types").Theme;
|
|
1022
1424
|
gridSize: number | null;
|
|
1023
1425
|
viewModeEnabled: boolean;
|
|
1024
1426
|
editingGroupId: string | null;
|
|
@@ -1038,12 +1440,18 @@ export declare const actionToggleHandTool: {
|
|
|
1038
1440
|
data: import("../charts").Spreadsheet;
|
|
1039
1441
|
};
|
|
1040
1442
|
pendingImageElementId: string | null;
|
|
1041
|
-
showHyperlinkPopup: false | "
|
|
1443
|
+
showHyperlinkPopup: false | "editor" | "info";
|
|
1042
1444
|
selectedLinearElement: import("../element/linearElementEditor").LinearElementEditor | null;
|
|
1445
|
+
snapLines: readonly import("../snapping").SnapLine[];
|
|
1446
|
+
originSnapOffset: {
|
|
1447
|
+
x: number;
|
|
1448
|
+
y: number;
|
|
1449
|
+
} | null;
|
|
1450
|
+
objectsSnapModeEnabled: boolean;
|
|
1043
1451
|
};
|
|
1044
1452
|
commitToHistory: true;
|
|
1045
1453
|
};
|
|
1046
|
-
keyTest: (event:
|
|
1454
|
+
keyTest: (event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean;
|
|
1047
1455
|
} & {
|
|
1048
|
-
keyTest?: ((event:
|
|
1456
|
+
keyTest?: ((event: import("react").KeyboardEvent<Element> | KeyboardEvent) => boolean) | undefined;
|
|
1049
1457
|
};
|