Skip to content

Commit d568003

Browse files
committed
updated docs
1 parent 247685b commit d568003

4 files changed

Lines changed: 1497 additions & 1507 deletions

docs/AITrainingData/Excalidraw Automate library and related type definitions.md

Lines changed: 12 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -2283,6 +2283,7 @@ export interface AppState {
22832283
};
22842284
allowWheelZoom?: boolean;
22852285
allowPinchZoom?: boolean;
2286+
disableContextMenu: boolean;
22862287
pinnedScripts?: string[];
22872288
customPens?: any[];
22882289
currentStrokeOptions?: any;
@@ -2329,8 +2330,6 @@ export interface AppState {
23292330
lockedMultiSelections: {
23302331
[groupId: string]: true;
23312332
};
2332-
/** properties sidebar mode - determines whether to show compact or complete sidebar */
2333-
stylesPanelMode: "compact" | "full" | "mobile" | "tray";
23342333
}
23352334
export type SearchMatch = {
23362335
id: string;
@@ -2495,6 +2494,12 @@ export type UIOptions = Partial<{
24952494
tools: {
24962495
image: boolean;
24972496
};
2497+
/**
2498+
* Optionally control the editor form factor and desktop UI mode from the host app.
2499+
* If not provided, we will take care of it internally.
2500+
*/
2501+
formFactor?: EditorInterface["formFactor"];
2502+
desktopUIMode?: EditorInterface["desktopUIMode"];
24982503
/** @deprecated does nothing. Will be removed in 0.15 */
24992504
welcomeScreen?: boolean;
25002505
}>;
@@ -2525,7 +2530,7 @@ export type AppClassProperties = {
25252530
mimeType: ValueOf<typeof IMAGE_MIME_TYPES>;
25262531
}>;
25272532
files: BinaryFiles;
2528-
device: App["device"];
2533+
editorInterface: App["editorInterface"];
25292534
scene: App["scene"];
25302535
syncActionResult: App["syncActionResult"];
25312536
fonts: App["fonts"];
@@ -2629,8 +2634,10 @@ export interface ExcalidrawImperativeAPI {
26292634
};
26302635
setForceRenderAllEmbeddables: InstanceType<typeof App>["setForceRenderAllEmbeddables"];
26312636
zoomToFit: InstanceType<typeof App>["zoomToFit"];
2632-
refreshEditorBreakpoints: InstanceType<typeof App>["refreshEditorBreakpoints"];
2637+
refreshEditorInterface: InstanceType<typeof App>["refreshEditorInterface"];
2638+
isTouchScreen: InstanceType<typeof App>["isTouchScreen"];
26332639
setTrayModeEnabled: InstanceType<typeof App>["setTrayModeEnabled"];
2640+
setDesktopUIMode: InstanceType<typeof App>["setDesktopUIMode"];
26342641
isTrayModeEnabled: InstanceType<typeof App>["isTrayModeEnabled"];
26352642
getColorAtScenePoint: InstanceType<typeof App>["getColorAtScenePoint"];
26362643
startLineEditor: InstanceType<typeof App>["startLineEditor"];
@@ -2650,12 +2657,12 @@ export interface ExcalidrawImperativeAPI {
26502657
bringForward: (elements: readonly ExcalidrawElement[]) => void;
26512658
sendToBack: (elements: readonly ExcalidrawElement[]) => void;
26522659
bringToFront: (elements: readonly ExcalidrawElement[]) => void;
2653-
setMobileModeAllowed: (allow: boolean) => void;
26542660
setActiveTool: InstanceType<typeof App>["setActiveTool"];
26552661
setCursor: InstanceType<typeof App>["setCursor"];
26562662
resetCursor: InstanceType<typeof App>["resetCursor"];
26572663
toggleSidebar: InstanceType<typeof App>["toggleSidebar"];
26582664
getHTMLIFrameElement: InstanceType<typeof App>["getHTMLIFrameElement"];
2665+
getEditorInterface: () => EditorInterface;
26592666
/**
26602667
* Disables rendering of frames (including element clipping), but currently
26612668
* the frames are still interactive in edit mode. As such, this API should be
@@ -2669,18 +2676,6 @@ export interface ExcalidrawImperativeAPI {
26692676
onScrollChange: (callback: (scrollX: number, scrollY: number, zoom: Zoom) => void) => UnsubscribeCallback;
26702677
onUserFollow: (callback: (payload: OnUserFollowedPayload) => void) => UnsubscribeCallback;
26712678
}
2672-
export type Device = Readonly<{
2673-
viewport: {
2674-
isMobile: boolean;
2675-
isLandscape: boolean;
2676-
};
2677-
editor: {
2678-
isMobile: boolean;
2679-
canFitSidebar: boolean;
2680-
};
2681-
isTouchScreen: boolean;
2682-
isTrayMode: boolean;
2683-
}>;
26842679
export type FrameNameBounds = {
26852680
x: number;
26862681
y: number;

0 commit comments

Comments
 (0)