@excalidraw/excalidraw 0.14.2-a8e6028 → 0.14.2-b9ba407
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/package.json
CHANGED
package/types/data/restore.d.ts
CHANGED
|
@@ -8,8 +8,14 @@ export declare type RestoredDataState = {
|
|
|
8
8
|
appState: RestoredAppState;
|
|
9
9
|
files: BinaryFiles;
|
|
10
10
|
};
|
|
11
|
-
export declare const restoreElements: (elements: ImportedDataState["elements"], localElements: readonly ExcalidrawElement[] | null | undefined,
|
|
11
|
+
export declare const restoreElements: (elements: ImportedDataState["elements"], localElements: readonly ExcalidrawElement[] | null | undefined, opts?: {
|
|
12
|
+
refreshDimensions?: boolean;
|
|
13
|
+
repairBindings?: boolean;
|
|
14
|
+
} | undefined) => ExcalidrawElement[];
|
|
12
15
|
export declare const restoreAppState: (appState: ImportedDataState["appState"], localAppState: Partial<AppState> | null | undefined) => RestoredAppState;
|
|
13
|
-
export declare const restore: (data: Pick<ImportedDataState, "appState" | "elements" | "files"> | null, localAppState: Partial<AppState> | null | undefined, localElements: readonly ExcalidrawElement[] | null | undefined
|
|
16
|
+
export declare const restore: (data: Pick<ImportedDataState, "appState" | "elements" | "files"> | null, localAppState: Partial<AppState> | null | undefined, localElements: readonly ExcalidrawElement[] | null | undefined, elementsConfig?: {
|
|
17
|
+
refreshDimensions?: boolean;
|
|
18
|
+
repairBindings?: boolean;
|
|
19
|
+
}) => RestoredDataState;
|
|
14
20
|
export declare const restoreLibraryItems: (libraryItems: ImportedDataState["libraryItems"], defaultStatus: LibraryItem["status"]) => LibraryItem[];
|
|
15
21
|
export {};
|
|
@@ -14,7 +14,7 @@ export declare const isBindingElementType: (elementType: AppState["activeTool"][
|
|
|
14
14
|
export declare const isBindableElement: (element: ExcalidrawElement | null, includeLocked?: boolean) => element is ExcalidrawBindableElement;
|
|
15
15
|
export declare const isTextBindableContainer: (element: ExcalidrawElement | null, includeLocked?: boolean) => element is ExcalidrawTextContainer;
|
|
16
16
|
export declare const isExcalidrawElement: (element: any) => boolean;
|
|
17
|
-
export declare const hasBoundTextElement: (element: ExcalidrawElement | null) => element is ExcalidrawBindableElement
|
|
17
|
+
export declare const hasBoundTextElement: (element: ExcalidrawElement | null) => element is MarkNonNullable<ExcalidrawBindableElement, "boundElements">;
|
|
18
18
|
export declare const isBoundToContainer: (element: ExcalidrawElement | null) => element is ExcalidrawTextElementWithContainer;
|
|
19
19
|
export declare const isUsingAdaptiveRadius: (type: string) => boolean;
|
|
20
20
|
export declare const isUsingProportionalRadius: (type: string) => boolean;
|
|
@@ -1,8 +1,14 @@
|
|
|
1
1
|
import type * as TExcalidraw from "../index";
|
|
2
2
|
import "./App.scss";
|
|
3
|
+
import { ExcalidrawImperativeAPI } from "../../../types";
|
|
3
4
|
declare global {
|
|
4
5
|
interface Window {
|
|
5
6
|
ExcalidrawLib: typeof TExcalidraw;
|
|
6
7
|
}
|
|
7
8
|
}
|
|
8
|
-
export
|
|
9
|
+
export interface AppProps {
|
|
10
|
+
appTitle: string;
|
|
11
|
+
useCustom: (api: ExcalidrawImperativeAPI | null, customArgs?: any[]) => void;
|
|
12
|
+
customArgs?: any[];
|
|
13
|
+
}
|
|
14
|
+
export default function App({ appTitle, useCustom, customArgs }: AppProps): JSX.Element;
|