@zsviczian/excalidraw 0.17.6-21 → 0.17.6-23
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/excalidraw.development.js +14 -14
- package/dist/excalidraw.production.min.js +1 -1
- package/package.json +1 -1
- package/types/excalidraw/components/App.d.ts +1 -1
- package/types/excalidraw/components/TTDDialog/MermaidToExcalidrawLib.d.ts +4 -3
- package/types/excalidraw/fonts/Fonts.d.ts +1 -2
- package/types/excalidraw/index.d.ts +2 -1
- package/types/excalidraw/obsidianUtils.d.ts +5 -2
- package/types/utils/export.d.ts +1 -1
package/package.json
CHANGED
|
@@ -356,7 +356,7 @@ declare class App extends React.Component<AppProps, AppState> {
|
|
|
356
356
|
/** use when changing scrollX/scrollY/zoom based on user interaction */
|
|
357
357
|
private translateCanvas;
|
|
358
358
|
zoomToFit: (target?: readonly ExcalidrawElement[], maxZoom?: number, margin?: number) => void;
|
|
359
|
-
getColorAtScenePoint: ({ sceneX, sceneY }: {
|
|
359
|
+
getColorAtScenePoint: ({ sceneX, sceneY, }: {
|
|
360
360
|
sceneX: number;
|
|
361
361
|
sceneY: number;
|
|
362
362
|
}) => string | null;
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
import { MermaidConfig } from "@zsviczian/mermaid-to-excalidraw";
|
|
2
|
-
import { ExcalidrawElement } from "../../element/types";
|
|
3
|
-
import { MermaidToExcalidrawLibProps } from "./common";
|
|
1
|
+
import type { MermaidConfig } from "@zsviczian/mermaid-to-excalidraw";
|
|
2
|
+
import type { ExcalidrawElement } from "../../element/types";
|
|
3
|
+
import type { MermaidToExcalidrawLibProps } from "./common";
|
|
4
4
|
export declare const loadMermaidToExcalidrawLib: () => Promise<MermaidToExcalidrawLibProps>;
|
|
5
|
+
export declare const loadMermaidLib: () => Promise<MermaidToExcalidrawLibProps>;
|
|
5
6
|
export declare const mermaidToExcalidraw: (mermaidDefinition: string, opts: MermaidConfig, forceSVG?: boolean) => Promise<{
|
|
6
7
|
elements?: ExcalidrawElement[];
|
|
7
8
|
files?: any;
|
|
@@ -67,8 +67,7 @@ export declare class Fonts {
|
|
|
67
67
|
* @param metadata font metadata
|
|
68
68
|
* @param fontFacesDecriptors font faces descriptors
|
|
69
69
|
*/
|
|
70
|
-
static register(
|
|
71
|
-
this: Fonts | {
|
|
70
|
+
static register(this: Fonts | {
|
|
72
71
|
registered: Map<number, {
|
|
73
72
|
metadata: FontMetadata;
|
|
74
73
|
fontFaces: ExcalidrawFontFace[];
|
|
@@ -28,7 +28,8 @@ getFontFamilies, //zsviczian
|
|
|
28
28
|
getFontFamilyString, //zsviczian
|
|
29
29
|
registerFontsInCSS, //zsviczian
|
|
30
30
|
getCSSFontDefinition, //zsviczian
|
|
31
|
-
loadSceneFonts,
|
|
31
|
+
loadSceneFonts, //zsviczian
|
|
32
|
+
loadMermaid, } from "../utils/export";
|
|
32
33
|
export { refreshTextDimensions } from "./element/newElement";
|
|
33
34
|
export { getContainerElement } from "./element/textElement";
|
|
34
35
|
export { serializeAsJSON, serializeLibraryAsJSON } from "./data/json";
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import type { MermaidToExcalidrawLibProps } from "./components/TTDDialog/common";
|
|
2
|
+
import type { NonDeletedExcalidrawElement } from "./element/types";
|
|
2
3
|
import type { FontMetadata } from "./fonts/FontMetadata";
|
|
3
|
-
import { AppState } from "./types";
|
|
4
|
+
import type { AppState } from "./types";
|
|
4
5
|
export declare let hostPlugin: any;
|
|
5
6
|
export declare function destroyObsidianUtils(): void;
|
|
6
7
|
export declare function initializeObsidianUtils(): void;
|
|
@@ -21,3 +22,5 @@ export declare function getCSSFontDefinition(fontFamily: number): Promise<string
|
|
|
21
22
|
export declare function loadSceneFonts(elements: NonDeletedExcalidrawElement[]): Promise<FontFace[]>;
|
|
22
23
|
export declare function fetchFontFromVault(url: string | URL): Promise<ArrayBuffer | undefined>;
|
|
23
24
|
export declare function isTouchInPenMode(appState: AppState, event: React.PointerEvent<HTMLElement> | MouseEvent): boolean;
|
|
25
|
+
export declare function getSharedMermaidInstance(): Promise<MermaidToExcalidrawLibProps>;
|
|
26
|
+
export declare function loadMermaid(): Promise<MermaidToExcalidrawLibProps>;
|
package/types/utils/export.d.ts
CHANGED
|
@@ -43,4 +43,4 @@ export { getLineHeight } from "../excalidraw/fonts/index";
|
|
|
43
43
|
export { getFontString, getFontFamilyString } from "../excalidraw/utils";
|
|
44
44
|
export { getBoundTextMaxWidth } from "../excalidraw/element/textElement";
|
|
45
45
|
export { mermaidToExcalidraw } from "../excalidraw/components/TTDDialog/MermaidToExcalidrawLib";
|
|
46
|
-
export { destroyObsidianUtils, registerLocalFont, getFontFamilies, registerFontsInCSS, getCSSFontDefinition, loadSceneFonts, } from "../excalidraw/obsidianUtils";
|
|
46
|
+
export { destroyObsidianUtils, registerLocalFont, getFontFamilies, registerFontsInCSS, getCSSFontDefinition, loadSceneFonts, getSharedMermaidInstance, loadMermaid, } from "../excalidraw/obsidianUtils";
|