@kritzel/editor 0.4.31
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/LICENSE.md +50 -0
- package/README.md +5 -0
- package/dist/cjs/app-globals-V2Kpy_OQ.js +5 -0
- package/dist/cjs/index-B92VHWr4.js +1834 -0
- package/dist/cjs/index.cjs.js +2 -0
- package/dist/cjs/kritzel-active-users_46.cjs.entry.js +75271 -0
- package/dist/cjs/kritzel-brush-style.cjs.entry.js +31 -0
- package/dist/cjs/kritzel-editor.cjs.js +25 -0
- package/dist/cjs/loader.cjs.js +13 -0
- package/dist/collection/collection-manifest.json +65 -0
- package/dist/collection/components/kritzel-active-users/kritzel-active-users.css +65 -0
- package/dist/collection/components/kritzel-active-users/kritzel-active-users.js +134 -0
- package/dist/collection/components/kritzel-avatar/kritzel-avatar.css +58 -0
- package/dist/collection/components/kritzel-avatar/kritzel-avatar.js +207 -0
- package/dist/collection/components/kritzel-back-to-content/kritzel-back-to-content.css +42 -0
- package/dist/collection/components/kritzel-back-to-content/kritzel-back-to-content.js +95 -0
- package/dist/collection/components/kritzel-brush-style/kritzel-brush-style.css +43 -0
- package/dist/collection/components/kritzel-brush-style/kritzel-brush-style.js +97 -0
- package/dist/collection/components/kritzel-button/kritzel-button.css +73 -0
- package/dist/collection/components/kritzel-button/kritzel-button.js +118 -0
- package/dist/collection/components/kritzel-color/kritzel-color.css +25 -0
- package/dist/collection/components/kritzel-color/kritzel-color.js +149 -0
- package/dist/collection/components/kritzel-color-palette/kritzel-color-palette.css +46 -0
- package/dist/collection/components/kritzel-color-palette/kritzel-color-palette.js +225 -0
- package/dist/collection/components/kritzel-context-menu/kritzel-context-menu.css +112 -0
- package/dist/collection/components/kritzel-context-menu/kritzel-context-menu.js +368 -0
- package/dist/collection/components/kritzel-current-user/kritzel-current-user.css +11 -0
- package/dist/collection/components/kritzel-current-user/kritzel-current-user.js +109 -0
- package/dist/collection/components/kritzel-current-user-dialog/kritzel-current-user-dialog.css +39 -0
- package/dist/collection/components/kritzel-current-user-dialog/kritzel-current-user-dialog.js +169 -0
- package/dist/collection/components/kritzel-dialog/kritzel-dialog.css +209 -0
- package/dist/collection/components/kritzel-dialog/kritzel-dialog.js +787 -0
- package/dist/collection/components/kritzel-dropdown/kritzel-dropdown.css +190 -0
- package/dist/collection/components/kritzel-dropdown/kritzel-dropdown.js +418 -0
- package/dist/collection/components/kritzel-editor/kritzel-editor.css +161 -0
- package/dist/collection/components/kritzel-editor/kritzel-editor.js +4678 -0
- package/dist/collection/components/kritzel-export/kritzel-export.css +89 -0
- package/dist/collection/components/kritzel-export/kritzel-export.js +246 -0
- package/dist/collection/components/kritzel-font/kritzel-font.css +10 -0
- package/dist/collection/components/kritzel-font/kritzel-font.js +89 -0
- package/dist/collection/components/kritzel-font-family/kritzel-font-family.css +48 -0
- package/dist/collection/components/kritzel-font-family/kritzel-font-family.js +122 -0
- package/dist/collection/components/kritzel-font-size/kritzel-font-size.css +30 -0
- package/dist/collection/components/kritzel-font-size/kritzel-font-size.js +117 -0
- package/dist/collection/components/kritzel-input/kritzel-input.css +69 -0
- package/dist/collection/components/kritzel-input/kritzel-input.js +198 -0
- package/dist/collection/components/kritzel-line-endings/kritzel-line-endings.css +60 -0
- package/dist/collection/components/kritzel-line-endings/kritzel-line-endings.js +165 -0
- package/dist/collection/components/kritzel-loading-overlay/kritzel-loading-overlay.css +54 -0
- package/dist/collection/components/kritzel-loading-overlay/kritzel-loading-overlay.js +70 -0
- package/dist/collection/components/kritzel-login-dialog/kritzel-login-dialog.css +98 -0
- package/dist/collection/components/kritzel-login-dialog/kritzel-login-dialog.js +239 -0
- package/dist/collection/components/kritzel-master-detail/kritzel-master-detail.css +190 -0
- package/dist/collection/components/kritzel-master-detail/kritzel-master-detail.js +201 -0
- package/dist/collection/components/kritzel-menu/kritzel-menu.css +34 -0
- package/dist/collection/components/kritzel-menu/kritzel-menu.js +297 -0
- package/dist/collection/components/kritzel-menu-item/kritzel-menu-item.css +167 -0
- package/dist/collection/components/kritzel-menu-item/kritzel-menu-item.js +298 -0
- package/dist/collection/components/kritzel-more-menu/kritzel-more-menu.css +58 -0
- package/dist/collection/components/kritzel-more-menu/kritzel-more-menu.js +381 -0
- package/dist/collection/components/kritzel-notification-card/kritzel-notification-card.css +101 -0
- package/dist/collection/components/kritzel-notification-card/kritzel-notification-card.js +173 -0
- package/dist/collection/components/kritzel-numeric-input/kritzel-numeric-input.css +102 -0
- package/dist/collection/components/kritzel-numeric-input/kritzel-numeric-input.js +255 -0
- package/dist/collection/components/kritzel-opacity-slider/kritzel-opacity-slider.css +85 -0
- package/dist/collection/components/kritzel-opacity-slider/kritzel-opacity-slider.js +164 -0
- package/dist/collection/components/kritzel-pill-tabs/kritzel-pill-tabs.css +68 -0
- package/dist/collection/components/kritzel-pill-tabs/kritzel-pill-tabs.js +135 -0
- package/dist/collection/components/kritzel-portal/kritzel-portal.js +432 -0
- package/dist/collection/components/kritzel-settings/kritzel-settings.css +137 -0
- package/dist/collection/components/kritzel-settings/kritzel-settings.js +448 -0
- package/dist/collection/components/kritzel-shape-fill/kritzel-shape-fill.css +47 -0
- package/dist/collection/components/kritzel-shape-fill/kritzel-shape-fill.js +93 -0
- package/dist/collection/components/kritzel-share-dialog/kritzel-share-dialog.css +150 -0
- package/dist/collection/components/kritzel-share-dialog/kritzel-share-dialog.js +308 -0
- package/dist/collection/components/kritzel-slide-toggle/kritzel-slide-toggle.css +48 -0
- package/dist/collection/components/kritzel-slide-toggle/kritzel-slide-toggle.js +119 -0
- package/dist/collection/components/kritzel-split-button/kritzel-split-button.css +78 -0
- package/dist/collection/components/kritzel-split-button/kritzel-split-button.js +433 -0
- package/dist/collection/components/kritzel-stroke-size/kritzel-stroke-size.css +37 -0
- package/dist/collection/components/kritzel-stroke-size/kritzel-stroke-size.js +89 -0
- package/dist/collection/components/kritzel-tool-config/kritzel-tool-config.css +38 -0
- package/dist/collection/components/kritzel-tool-config/kritzel-tool-config.js +467 -0
- package/dist/collection/components/kritzel-toolbar/kritzel-toolbar.css +348 -0
- package/dist/collection/components/kritzel-toolbar/kritzel-toolbar.js +588 -0
- package/dist/collection/components/kritzel-tooltip/kritzel-tooltip.css +18 -0
- package/dist/collection/components/kritzel-tooltip/kritzel-tooltip.js +388 -0
- package/dist/collection/components/kritzel-utility-panel/kritzel-utility-panel.css +46 -0
- package/dist/collection/components/kritzel-utility-panel/kritzel-utility-panel.js +146 -0
- package/dist/collection/components/kritzel-workspace-manager/kritzel-workspace-manager.css +16 -0
- package/dist/collection/components/kritzel-workspace-manager/kritzel-workspace-manager.js +365 -0
- package/dist/collection/components/kritzel-zoom-panel/kritzel-zoom-panel.css +72 -0
- package/dist/collection/components/kritzel-zoom-panel/kritzel-zoom-panel.js +173 -0
- package/dist/collection/index.js +1 -0
- package/dist/components/index.d.ts +121 -0
- package/dist/components/index.js +48 -0
- package/dist/components/kritzel-active-users.d.ts +11 -0
- package/dist/components/kritzel-active-users.js +6 -0
- package/dist/components/kritzel-avatar.d.ts +11 -0
- package/dist/components/kritzel-avatar.js +6 -0
- package/dist/components/kritzel-awareness-cursors.js +6 -0
- package/dist/components/kritzel-back-to-content.d.ts +11 -0
- package/dist/components/kritzel-back-to-content.js +6 -0
- package/dist/components/kritzel-brush-style.d.ts +11 -0
- package/dist/components/kritzel-brush-style.js +64 -0
- package/dist/components/kritzel-button.d.ts +11 -0
- package/dist/components/kritzel-button.js +6 -0
- package/dist/components/kritzel-color-palette.d.ts +11 -0
- package/dist/components/kritzel-color-palette.js +6 -0
- package/dist/components/kritzel-color.d.ts +11 -0
- package/dist/components/kritzel-color.js +6 -0
- package/dist/components/kritzel-context-menu.d.ts +11 -0
- package/dist/components/kritzel-context-menu.js +6 -0
- package/dist/components/kritzel-current-user-dialog.d.ts +11 -0
- package/dist/components/kritzel-current-user-dialog.js +6 -0
- package/dist/components/kritzel-current-user.d.ts +11 -0
- package/dist/components/kritzel-current-user.js +6 -0
- package/dist/components/kritzel-cursor-trail.js +6 -0
- package/dist/components/kritzel-dialog.d.ts +11 -0
- package/dist/components/kritzel-dialog.js +6 -0
- package/dist/components/kritzel-dropdown.d.ts +11 -0
- package/dist/components/kritzel-dropdown.js +6 -0
- package/dist/components/kritzel-editor.d.ts +11 -0
- package/dist/components/kritzel-editor.js +1792 -0
- package/dist/components/kritzel-engine.js +6 -0
- package/dist/components/kritzel-export.d.ts +11 -0
- package/dist/components/kritzel-export.js +6 -0
- package/dist/components/kritzel-font-family.d.ts +11 -0
- package/dist/components/kritzel-font-family.js +6 -0
- package/dist/components/kritzel-font-size.d.ts +11 -0
- package/dist/components/kritzel-font-size.js +6 -0
- package/dist/components/kritzel-font.d.ts +11 -0
- package/dist/components/kritzel-font.js +6 -0
- package/dist/components/kritzel-icon.js +6 -0
- package/dist/components/kritzel-input.d.ts +11 -0
- package/dist/components/kritzel-input.js +6 -0
- package/dist/components/kritzel-line-endings.d.ts +11 -0
- package/dist/components/kritzel-line-endings.js +6 -0
- package/dist/components/kritzel-loading-overlay.d.ts +11 -0
- package/dist/components/kritzel-loading-overlay.js +6 -0
- package/dist/components/kritzel-login-dialog.d.ts +11 -0
- package/dist/components/kritzel-login-dialog.js +6 -0
- package/dist/components/kritzel-master-detail.d.ts +11 -0
- package/dist/components/kritzel-master-detail.js +6 -0
- package/dist/components/kritzel-menu-item.d.ts +11 -0
- package/dist/components/kritzel-menu-item.js +6 -0
- package/dist/components/kritzel-menu.d.ts +11 -0
- package/dist/components/kritzel-menu.js +6 -0
- package/dist/components/kritzel-more-menu.d.ts +11 -0
- package/dist/components/kritzel-more-menu.js +6 -0
- package/dist/components/kritzel-notification-card.d.ts +11 -0
- package/dist/components/kritzel-notification-card.js +6 -0
- package/dist/components/kritzel-numeric-input.d.ts +11 -0
- package/dist/components/kritzel-numeric-input.js +6 -0
- package/dist/components/kritzel-opacity-slider.d.ts +11 -0
- package/dist/components/kritzel-opacity-slider.js +6 -0
- package/dist/components/kritzel-pill-tabs.d.ts +11 -0
- package/dist/components/kritzel-pill-tabs.js +6 -0
- package/dist/components/kritzel-portal.d.ts +11 -0
- package/dist/components/kritzel-portal.js +6 -0
- package/dist/components/kritzel-settings.d.ts +11 -0
- package/dist/components/kritzel-settings.js +6 -0
- package/dist/components/kritzel-shape-fill.d.ts +11 -0
- package/dist/components/kritzel-shape-fill.js +6 -0
- package/dist/components/kritzel-share-dialog.d.ts +11 -0
- package/dist/components/kritzel-share-dialog.js +6 -0
- package/dist/components/kritzel-slide-toggle.d.ts +11 -0
- package/dist/components/kritzel-slide-toggle.js +6 -0
- package/dist/components/kritzel-split-button.d.ts +11 -0
- package/dist/components/kritzel-split-button.js +6 -0
- package/dist/components/kritzel-stroke-size.d.ts +11 -0
- package/dist/components/kritzel-stroke-size.js +6 -0
- package/dist/components/kritzel-tool-config.d.ts +11 -0
- package/dist/components/kritzel-tool-config.js +6 -0
- package/dist/components/kritzel-toolbar.d.ts +11 -0
- package/dist/components/kritzel-toolbar.js +6 -0
- package/dist/components/kritzel-tooltip.d.ts +11 -0
- package/dist/components/kritzel-tooltip.js +6 -0
- package/dist/components/kritzel-utility-panel.d.ts +11 -0
- package/dist/components/kritzel-utility-panel.js +6 -0
- package/dist/components/kritzel-watermark.js +6 -0
- package/dist/components/kritzel-workspace-manager.d.ts +11 -0
- package/dist/components/kritzel-workspace-manager.js +6 -0
- package/dist/components/kritzel-zoom-panel.d.ts +11 -0
- package/dist/components/kritzel-zoom-panel.js +6 -0
- package/dist/components/p-4-qLegHb.js +142 -0
- package/dist/components/p-5qkOM1RJ.js +1557 -0
- package/dist/components/p-B3Tqoyl9.js +43 -0
- package/dist/components/p-B5xYV1o3.js +77 -0
- package/dist/components/p-B6UJztrf.js +290 -0
- package/dist/components/p-BDjRSoAc.js +43 -0
- package/dist/components/p-BFTU3MAI.js +7 -0
- package/dist/components/p-BGmTmdLe.js +167 -0
- package/dist/components/p-BN8VWPlq.js +164 -0
- package/dist/components/p-BZ_KnHdR.js +222 -0
- package/dist/components/p-B_gT0lCn.js +94 -0
- package/dist/components/p-BfMlwIcG.js +62 -0
- package/dist/components/p-BjFrt1q0.js +62 -0
- package/dist/components/p-Blq9a1ni.js +3267 -0
- package/dist/components/p-BrGJIoGK.js +52 -0
- package/dist/components/p-BvG3JO85.js +56 -0
- package/dist/components/p-CS3YZVYE.js +319 -0
- package/dist/components/p-CVxGF4bJ.js +150 -0
- package/dist/components/p-Ckqh1tqY.js +468 -0
- package/dist/components/p-ClfOtiNp.js +84 -0
- package/dist/components/p-CmjXRLdr.js +220 -0
- package/dist/components/p-CoNexfpB.js +106 -0
- package/dist/components/p-Cp4e4oTE.js +122 -0
- package/dist/components/p-CrIEmItB.js +85 -0
- package/dist/components/p-CvaxFYS0.js +304 -0
- package/dist/components/p-CwBxnzYu.js +57 -0
- package/dist/components/p-Cy_cLtOP.js +3456 -0
- package/dist/components/p-CzUeIini.js +381 -0
- package/dist/components/p-D0tPTPkR.js +99 -0
- package/dist/components/p-DJxgPPfs.js +194 -0
- package/dist/components/p-DOJCDPVD.js +55 -0
- package/dist/components/p-DVv8ChhE.js +91 -0
- package/dist/components/p-DXZBWJBt.js +70 -0
- package/dist/components/p-DXuf225S.js +53 -0
- package/dist/components/p-DZsSiMnA.js +63037 -0
- package/dist/components/p-DqOC_Yck.js +112 -0
- package/dist/components/p-Ds0uNtwQ.js +97 -0
- package/dist/components/p-DyRJFg4w.js +57 -0
- package/dist/components/p-GbCxpbQ6.js +88 -0
- package/dist/components/p-McY5wZ0h.js +135 -0
- package/dist/components/p-QEue33R5.js +70 -0
- package/dist/components/p-R1D8Sr0l.js +299 -0
- package/dist/components/p-SLnqczCS.js +49 -0
- package/dist/components/p-hQwVRh0t.js +147 -0
- package/dist/components/p-h_uh_Njf.js +63 -0
- package/dist/components/p-kOINnzaR.js +161 -0
- package/dist/components/p-peZjvnkK.js +486 -0
- package/dist/esm/app-globals-DQuL1Twl.js +3 -0
- package/dist/esm/index-OjbYJz-P.js +1807 -0
- package/dist/esm/index.js +1 -0
- package/dist/esm/kritzel-active-users_46.entry.js +75224 -0
- package/dist/esm/kritzel-brush-style.entry.js +29 -0
- package/dist/esm/kritzel-editor.js +21 -0
- package/dist/esm/loader.js +11 -0
- package/dist/index.cjs.js +1 -0
- package/dist/index.js +1 -0
- package/dist/kritzel-editor/index.esm.js +1 -0
- package/dist/kritzel-editor/kritzel-editor.esm.js +21 -0
- package/dist/kritzel-editor/p-501047d8.entry.js +29 -0
- package/dist/kritzel-editor/p-60319edb.entry.js +75224 -0
- package/dist/kritzel-editor/p-DQuL1Twl.js +3 -0
- package/dist/kritzel-editor/p-OjbYJz-P.js +1790 -0
- package/dist/types/components/kritzel-active-users/kritzel-active-users.d.ts +21 -0
- package/dist/types/components/kritzel-avatar/kritzel-avatar.d.ts +27 -0
- package/dist/types/components/kritzel-back-to-content/kritzel-back-to-content.d.ts +17 -0
- package/dist/types/components/kritzel-brush-style/kritzel-brush-style.d.ts +11 -0
- package/dist/types/components/kritzel-button/kritzel-button.d.ts +13 -0
- package/dist/types/components/kritzel-color/kritzel-color.d.ts +10 -0
- package/dist/types/components/kritzel-color-palette/kritzel-color-palette.d.ts +17 -0
- package/dist/types/components/kritzel-context-menu/kritzel-context-menu.d.ts +40 -0
- package/dist/types/components/kritzel-current-user/kritzel-current-user.d.ts +15 -0
- package/dist/types/components/kritzel-current-user-dialog/kritzel-current-user-dialog.d.ts +18 -0
- package/dist/types/components/kritzel-dialog/kritzel-dialog.d.ts +85 -0
- package/dist/types/components/kritzel-dropdown/kritzel-dropdown.d.ts +48 -0
- package/dist/types/components/kritzel-editor/kritzel-editor.d.ts +356 -0
- package/dist/types/components/kritzel-export/kritzel-export.d.ts +35 -0
- package/dist/types/components/kritzel-font/kritzel-font.d.ts +6 -0
- package/dist/types/components/kritzel-font-family/kritzel-font-family.d.ts +17 -0
- package/dist/types/components/kritzel-font-size/kritzel-font-size.d.ts +10 -0
- package/dist/types/components/kritzel-input/kritzel-input.d.ts +22 -0
- package/dist/types/components/kritzel-line-endings/kritzel-line-endings.d.ts +21 -0
- package/dist/types/components/kritzel-loading-overlay/kritzel-loading-overlay.d.ts +11 -0
- package/dist/types/components/kritzel-login-dialog/kritzel-login-dialog.d.ts +32 -0
- package/dist/types/components/kritzel-master-detail/kritzel-master-detail.d.ts +25 -0
- package/dist/types/components/kritzel-menu/kritzel-menu.d.ts +25 -0
- package/dist/types/components/kritzel-menu-item/kritzel-menu-item.d.ts +28 -0
- package/dist/types/components/kritzel-more-menu/kritzel-more-menu.d.ts +55 -0
- package/dist/types/components/kritzel-notification-card/kritzel-notification-card.d.ts +22 -0
- package/dist/types/components/kritzel-numeric-input/kritzel-numeric-input.d.ts +32 -0
- package/dist/types/components/kritzel-opacity-slider/kritzel-opacity-slider.d.ts +17 -0
- package/dist/types/components/kritzel-pill-tabs/kritzel-pill-tabs.d.ts +26 -0
- package/dist/types/components/kritzel-portal/kritzel-portal.d.ts +33 -0
- package/dist/types/components/kritzel-settings/kritzel-settings.d.ts +64 -0
- package/dist/types/components/kritzel-shape-fill/kritzel-shape-fill.d.ts +10 -0
- package/dist/types/components/kritzel-share-dialog/kritzel-share-dialog.d.ts +49 -0
- package/dist/types/components/kritzel-slide-toggle/kritzel-slide-toggle.d.ts +14 -0
- package/dist/types/components/kritzel-split-button/kritzel-split-button.d.ts +38 -0
- package/dist/types/components/kritzel-stroke-size/kritzel-stroke-size.d.ts +8 -0
- package/dist/types/components/kritzel-tool-config/kritzel-tool-config.d.ts +39 -0
- package/dist/types/components/kritzel-toolbar/kritzel-toolbar.d.ts +76 -0
- package/dist/types/components/kritzel-tooltip/kritzel-tooltip.d.ts +30 -0
- package/dist/types/components/kritzel-utility-panel/kritzel-utility-panel.d.ts +14 -0
- package/dist/types/components/kritzel-workspace-manager/kritzel-workspace-manager.d.ts +40 -0
- package/dist/types/components/kritzel-zoom-panel/kritzel-zoom-panel.d.ts +20 -0
- package/dist/types/components.d.ts +3166 -0
- package/dist/types/index.d.ts +8 -0
- package/dist/types/stencil-public-runtime.d.ts +1873 -0
- package/loader/cdn.js +1 -0
- package/loader/index.cjs.js +1 -0
- package/loader/index.d.ts +24 -0
- package/loader/index.es2017.js +1 -0
- package/loader/index.js +2 -0
- package/package.json +83 -0
|
@@ -0,0 +1,4678 @@
|
|
|
1
|
+
import { Host, h } from "@stencil/core";
|
|
2
|
+
import { KritzelIconRegistry } from "@kritzel/engine";
|
|
3
|
+
import { ShapeType } from "@kritzel/engine";
|
|
4
|
+
import { KritzelAlignment } from "@kritzel/engine";
|
|
5
|
+
import { KritzelSelectionTool } from "@kritzel/engine";
|
|
6
|
+
import { KritzelEraserTool } from "@kritzel/engine";
|
|
7
|
+
import { KritzelImageTool } from "@kritzel/engine";
|
|
8
|
+
import { KritzelBrushTool } from "@kritzel/engine";
|
|
9
|
+
import { KritzelLineTool } from "@kritzel/engine";
|
|
10
|
+
import { KritzelTextTool } from "@kritzel/engine";
|
|
11
|
+
import { KritzelShapeTool } from "@kritzel/engine";
|
|
12
|
+
import { DEFAULT_BRUSH_CONFIG } from "@kritzel/engine";
|
|
13
|
+
import { DEFAULT_LINE_TOOL_CONFIG } from "@kritzel/engine";
|
|
14
|
+
import { DEFAULT_TEXT_CONFIG } from "@kritzel/engine";
|
|
15
|
+
import { DEFAULT_SHAPE_CONFIG } from "@kritzel/engine";
|
|
16
|
+
import { ABSOLUTE_SCALE_MAX, ABSOLUTE_SCALE_MIN } from "@kritzel/engine";
|
|
17
|
+
import { KritzelKeyboardHelper } from "@kritzel/engine";
|
|
18
|
+
import { KritzelDevicesHelper } from "@kritzel/engine";
|
|
19
|
+
import { hasRemoteSyncProvider } from "@kritzel/engine";
|
|
20
|
+
import { DEFAULT_ASSET_STORAGE_CONFIG } from "@kritzel/engine";
|
|
21
|
+
import { DEFAULT_SYNC_CONFIG } from "@kritzel/engine";
|
|
22
|
+
import { ThemeHelper } from "@kritzel/engine";
|
|
23
|
+
import { lightTheme } from "@kritzel/engine";
|
|
24
|
+
import { darkTheme } from "@kritzel/engine";
|
|
25
|
+
import { KritzelSelectionGroup } from "@kritzel/engine";
|
|
26
|
+
import { KritzelSelectionBox } from "@kritzel/engine";
|
|
27
|
+
import { ObjectHelper } from "@kritzel/engine";
|
|
28
|
+
import { KritzelFontRegistry } from "@kritzel/engine";
|
|
29
|
+
import { resolveTextToolAvailableFonts } from "@kritzel/engine";
|
|
30
|
+
export class KritzelEditor {
|
|
31
|
+
host;
|
|
32
|
+
scaleMax = ABSOLUTE_SCALE_MAX;
|
|
33
|
+
scaleMin = ABSOLUTE_SCALE_MIN;
|
|
34
|
+
lockDrawingScale = true;
|
|
35
|
+
viewportBoundaryLeft = -Infinity;
|
|
36
|
+
viewportBoundaryRight = Infinity;
|
|
37
|
+
viewportBoundaryTop = -Infinity;
|
|
38
|
+
viewportBoundaryBottom = Infinity;
|
|
39
|
+
debugInfo = {
|
|
40
|
+
showViewportInfo: false,
|
|
41
|
+
showObjectInfo: false,
|
|
42
|
+
showSyncProviderInfo: true,
|
|
43
|
+
showMigrationInfo: true,
|
|
44
|
+
showAssetResolverInfo: false,
|
|
45
|
+
};
|
|
46
|
+
user;
|
|
47
|
+
activeUsers;
|
|
48
|
+
toolbarItems = [
|
|
49
|
+
{
|
|
50
|
+
name: 'selection',
|
|
51
|
+
type: 'tool',
|
|
52
|
+
isDefault: true,
|
|
53
|
+
tool: KritzelSelectionTool,
|
|
54
|
+
icon: 'cursor',
|
|
55
|
+
},
|
|
56
|
+
{
|
|
57
|
+
name: 'brush',
|
|
58
|
+
type: 'tool',
|
|
59
|
+
tool: KritzelBrushTool,
|
|
60
|
+
icon: 'pen',
|
|
61
|
+
config: DEFAULT_BRUSH_CONFIG,
|
|
62
|
+
},
|
|
63
|
+
{
|
|
64
|
+
name: 'eraser',
|
|
65
|
+
type: 'tool',
|
|
66
|
+
tool: KritzelEraserTool,
|
|
67
|
+
icon: 'eraser',
|
|
68
|
+
},
|
|
69
|
+
{
|
|
70
|
+
name: 'line',
|
|
71
|
+
type: 'tool',
|
|
72
|
+
tool: KritzelLineTool,
|
|
73
|
+
icon: 'arrow',
|
|
74
|
+
config: DEFAULT_LINE_TOOL_CONFIG,
|
|
75
|
+
},
|
|
76
|
+
{
|
|
77
|
+
name: 'shape',
|
|
78
|
+
type: 'tool',
|
|
79
|
+
tool: KritzelShapeTool,
|
|
80
|
+
icon: 'shape-rectangle',
|
|
81
|
+
config: DEFAULT_SHAPE_CONFIG,
|
|
82
|
+
subOptions: [
|
|
83
|
+
{ id: 'rectangle', icon: 'shape-rectangle', label: 'Rectangle', value: ShapeType.Rectangle, toolProperty: 'shapeType' },
|
|
84
|
+
{ id: 'ellipse', icon: 'shape-ellipse', label: 'Ellipse', value: ShapeType.Ellipse, toolProperty: 'shapeType' },
|
|
85
|
+
{ id: 'triangle', icon: 'shape-triangle', label: 'Triangle', value: ShapeType.Triangle, toolProperty: 'shapeType' },
|
|
86
|
+
],
|
|
87
|
+
},
|
|
88
|
+
{
|
|
89
|
+
name: 'text',
|
|
90
|
+
type: 'tool',
|
|
91
|
+
tool: KritzelTextTool,
|
|
92
|
+
icon: 'type',
|
|
93
|
+
config: DEFAULT_TEXT_CONFIG,
|
|
94
|
+
},
|
|
95
|
+
{
|
|
96
|
+
name: 'image',
|
|
97
|
+
type: 'tool',
|
|
98
|
+
tool: KritzelImageTool,
|
|
99
|
+
icon: 'image',
|
|
100
|
+
},
|
|
101
|
+
{
|
|
102
|
+
name: 'config',
|
|
103
|
+
type: 'config',
|
|
104
|
+
},
|
|
105
|
+
];
|
|
106
|
+
globalContextMenuItems = [
|
|
107
|
+
{
|
|
108
|
+
label: 'menu.paste',
|
|
109
|
+
icon: 'paste',
|
|
110
|
+
action: menu => this.engineRef.paste(menu.x, menu.y),
|
|
111
|
+
},
|
|
112
|
+
{
|
|
113
|
+
label: 'menu.selectAll',
|
|
114
|
+
icon: 'select-all',
|
|
115
|
+
action: () => this.selectAllObjectsInViewport(),
|
|
116
|
+
},
|
|
117
|
+
];
|
|
118
|
+
objectContextMenuItems = [
|
|
119
|
+
{ label: 'menu.copy', icon: 'copy', group: 'clipboard', action: () => this.engineRef.copy() },
|
|
120
|
+
{ label: 'menu.cut', icon: 'cut', group: 'clipboard', action: () => this.engineRef.cut() },
|
|
121
|
+
{
|
|
122
|
+
label: 'menu.paste',
|
|
123
|
+
icon: 'paste',
|
|
124
|
+
group: 'clipboard',
|
|
125
|
+
action: (menu, _) => this.engineRef.paste(menu.x, menu.y),
|
|
126
|
+
},
|
|
127
|
+
{
|
|
128
|
+
label: 'menu.export',
|
|
129
|
+
icon: 'upload',
|
|
130
|
+
group: 'clipboard',
|
|
131
|
+
isVisible: (_, objects) => this.canExportObjects(objects),
|
|
132
|
+
action: (_, objects) => {
|
|
133
|
+
const format = this.getPreferredExportFormat(objects);
|
|
134
|
+
if (!format) {
|
|
135
|
+
return;
|
|
136
|
+
}
|
|
137
|
+
void this.engineRef.exportSelectedObject(format);
|
|
138
|
+
},
|
|
139
|
+
},
|
|
140
|
+
{
|
|
141
|
+
label: 'menu.order',
|
|
142
|
+
icon: 'ordering',
|
|
143
|
+
group: 'other',
|
|
144
|
+
children: [
|
|
145
|
+
{ label: 'menu.bringToFront', icon: 'bring-to-front', action: () => this.engineRef.bringToFront() },
|
|
146
|
+
{ label: 'menu.sendToBack', icon: 'send-to-back', action: () => this.engineRef.sendToBack() },
|
|
147
|
+
{ label: 'menu.moveUp', icon: 'arrow-up-from-dot', action: () => this.engineRef.bringForward() },
|
|
148
|
+
{ label: 'menu.moveDown', icon: 'arrow-down-from-dot', action: () => this.engineRef.sendBackward() },
|
|
149
|
+
],
|
|
150
|
+
},
|
|
151
|
+
{
|
|
152
|
+
label: 'menu.align',
|
|
153
|
+
icon: 'align',
|
|
154
|
+
group: 'other',
|
|
155
|
+
children: [
|
|
156
|
+
{ label: 'menu.alignLeft', icon: 'align-start-vertical', action: () => this.engineRef.alignObjects(KritzelAlignment.StartHorizontal) },
|
|
157
|
+
{ label: 'menu.alignCenterHorizontal', icon: 'align-center-horizontal', action: () => this.engineRef.alignObjects(KritzelAlignment.CenterHorizontal) },
|
|
158
|
+
{ label: 'menu.alignRight', icon: 'align-end-vertical', action: () => this.engineRef.alignObjects(KritzelAlignment.EndHorizontal) },
|
|
159
|
+
{ label: 'menu.alignTop', icon: 'align-start-horizontal', action: () => this.engineRef.alignObjects(KritzelAlignment.StartVertical) },
|
|
160
|
+
{ label: 'menu.alignCenterVertical', icon: 'align-center-vertical', action: () => this.engineRef.alignObjects(KritzelAlignment.CenterVertical) },
|
|
161
|
+
{ label: 'menu.alignBottom', icon: 'align-end-horizontal', action: () => this.engineRef.alignObjects(KritzelAlignment.EndVertical) },
|
|
162
|
+
],
|
|
163
|
+
},
|
|
164
|
+
{
|
|
165
|
+
label: 'menu.group',
|
|
166
|
+
icon: 'group',
|
|
167
|
+
group: 'other',
|
|
168
|
+
children: [
|
|
169
|
+
{
|
|
170
|
+
label: 'menu.group',
|
|
171
|
+
icon: 'group',
|
|
172
|
+
action: () => this.engineRef.group(),
|
|
173
|
+
},
|
|
174
|
+
{
|
|
175
|
+
label: 'menu.ungroup',
|
|
176
|
+
icon: 'ungroup',
|
|
177
|
+
action: () => this.engineRef.ungroup(),
|
|
178
|
+
},
|
|
179
|
+
],
|
|
180
|
+
},
|
|
181
|
+
{ label: 'menu.delete', icon: 'delete', group: 'edit', action: () => this.engineRef.delete() },
|
|
182
|
+
];
|
|
183
|
+
moreMenuItems = [
|
|
184
|
+
{
|
|
185
|
+
id: 'share',
|
|
186
|
+
label: 'menu.share',
|
|
187
|
+
icon: 'share',
|
|
188
|
+
isVisible: async () => hasRemoteSyncProvider(this.syncConfig),
|
|
189
|
+
action: () => {
|
|
190
|
+
if (!this.isLoggedIn && this.loginConfig) {
|
|
191
|
+
this.openLoginDialog();
|
|
192
|
+
return;
|
|
193
|
+
}
|
|
194
|
+
this.shareDialogRef.open();
|
|
195
|
+
},
|
|
196
|
+
},
|
|
197
|
+
{
|
|
198
|
+
id: 'export',
|
|
199
|
+
label: 'menu.export',
|
|
200
|
+
icon: 'upload',
|
|
201
|
+
action: async () => {
|
|
202
|
+
const preview = await this.engineRef.getScreenshot('png');
|
|
203
|
+
this.exportRef.open(preview ?? undefined);
|
|
204
|
+
},
|
|
205
|
+
},
|
|
206
|
+
{
|
|
207
|
+
id: 'import',
|
|
208
|
+
label: 'menu.import',
|
|
209
|
+
icon: 'download',
|
|
210
|
+
action: () => this.engineRef.importFromFile(),
|
|
211
|
+
},
|
|
212
|
+
{
|
|
213
|
+
id: 'settings',
|
|
214
|
+
label: 'menu.settings',
|
|
215
|
+
icon: 'settings',
|
|
216
|
+
action: () => this.settingsRef.open(),
|
|
217
|
+
},
|
|
218
|
+
];
|
|
219
|
+
themes;
|
|
220
|
+
theme = 'light';
|
|
221
|
+
/** License key that, when valid, removes the "Powered by Kritzel" watermark. */
|
|
222
|
+
licenseKey;
|
|
223
|
+
/** The current locale (language) code applied to the editor, e.g. 'en', 'de', 'fr'. */
|
|
224
|
+
locale = 'en';
|
|
225
|
+
/** An array of available locale definitions (with optional partial term overrides). */
|
|
226
|
+
locales;
|
|
227
|
+
/** The locale used to resolve terms missing from the active locale. */
|
|
228
|
+
fallbackLocale = 'en';
|
|
229
|
+
customSvgIcons = {};
|
|
230
|
+
/**
|
|
231
|
+
* Registers fonts for runtime usage (for example custom object rendering).
|
|
232
|
+
* Text-tool config tooltip options are controlled via toolbarItems[].config.availableFonts.
|
|
233
|
+
*/
|
|
234
|
+
customFonts = {};
|
|
235
|
+
isPanningEnabled = true;
|
|
236
|
+
isZoomingEnabled = true;
|
|
237
|
+
isToolbarVisible = true;
|
|
238
|
+
isUtilityPanelVisible = true;
|
|
239
|
+
isWorkspaceManagerVisible = true;
|
|
240
|
+
isMoreMenuVisible = true;
|
|
241
|
+
isZoomPanelVisible = true;
|
|
242
|
+
syncConfig = DEFAULT_SYNC_CONFIG;
|
|
243
|
+
assetStorageConfig = DEFAULT_ASSET_STORAGE_CONFIG;
|
|
244
|
+
/** The element to use as the target for the cursor. Defaults to the editor container if not set. */
|
|
245
|
+
cursorTarget;
|
|
246
|
+
/** Optional login configuration. When provided, a "Sign in" button is shown that opens a login dialog with the configured providers. */
|
|
247
|
+
loginConfig;
|
|
248
|
+
/** Optional unique identifier for namespacing storage keys across multiple editor instances. */
|
|
249
|
+
editorId;
|
|
250
|
+
/** Optional workspace ID to set as active. If provided, the editor will automatically activate the workspace with this ID. */
|
|
251
|
+
activeWorkspaceId;
|
|
252
|
+
/** Authoritative workspace catalog for this editor instance. When provided, provider-only workspaces are hidden but not deleted. */
|
|
253
|
+
workspaces;
|
|
254
|
+
isReady;
|
|
255
|
+
activeWorkspaceChange;
|
|
256
|
+
objectsChange;
|
|
257
|
+
objectsAdded;
|
|
258
|
+
objectsRemoved;
|
|
259
|
+
objectsUpdated;
|
|
260
|
+
objectsSelectionChange;
|
|
261
|
+
undoStateChange;
|
|
262
|
+
themeChange;
|
|
263
|
+
localeChange;
|
|
264
|
+
viewportChange;
|
|
265
|
+
logout;
|
|
266
|
+
login;
|
|
267
|
+
isPublicChange;
|
|
268
|
+
awarenessChange;
|
|
269
|
+
isEngineReady = false;
|
|
270
|
+
isToolbarReady = false;
|
|
271
|
+
isWorkspaceManagerReady = false;
|
|
272
|
+
availableWorkspaces = [];
|
|
273
|
+
activeWorkspace;
|
|
274
|
+
isVirtualKeyboardOpen = false;
|
|
275
|
+
undoState = null;
|
|
276
|
+
isBackToContentButtonVisible = false;
|
|
277
|
+
/** Localized strings for editor-owned UI (e.g. the more menu), resolved from the active locale. */
|
|
278
|
+
resolvedTerms = {};
|
|
279
|
+
/** Available locales as `{ code, label }` options for the settings language selector. */
|
|
280
|
+
availableLocaleOptions = [];
|
|
281
|
+
currentZoomPercent = 100;
|
|
282
|
+
shortcuts = [];
|
|
283
|
+
currentIsPublic = false;
|
|
284
|
+
isEditorVisible = false;
|
|
285
|
+
activeNotification;
|
|
286
|
+
isNotificationDismissing = false;
|
|
287
|
+
contextMenuState;
|
|
288
|
+
resolvedMoreMenuItems = [];
|
|
289
|
+
isLoadingOverlayVisible = false;
|
|
290
|
+
loadingOverlayShowTimeout;
|
|
291
|
+
loadingOverlayHideTimeout;
|
|
292
|
+
loadingOverlayShownTimestamp;
|
|
293
|
+
loadingOverlayDelayMs = 300;
|
|
294
|
+
loadingOverlayMinDisplayDurationMs = 400;
|
|
295
|
+
notificationDismissTimeout;
|
|
296
|
+
notificationDismissAnimationTimeout;
|
|
297
|
+
notificationDisplayDurationMs = 5000;
|
|
298
|
+
notificationDismissAnimationDurationMs = 180;
|
|
299
|
+
isNotificationHovered = false;
|
|
300
|
+
customFontsLoadVersion = 0;
|
|
301
|
+
customFontsReady = Promise.resolve();
|
|
302
|
+
onIsEngineReady(newValue) {
|
|
303
|
+
if (newValue && this.isToolbarReady) {
|
|
304
|
+
this.checkIsReady();
|
|
305
|
+
}
|
|
306
|
+
}
|
|
307
|
+
onIsToolbarReady(newValue) {
|
|
308
|
+
if (newValue && this.isEngineReady) {
|
|
309
|
+
this.checkIsReady();
|
|
310
|
+
}
|
|
311
|
+
}
|
|
312
|
+
onAvailableWorkspacesChange(newWorkspaces) {
|
|
313
|
+
const activeWorkspace = this.activeWorkspace;
|
|
314
|
+
if (activeWorkspace) {
|
|
315
|
+
const updatedActiveWorkspace = newWorkspaces.find(ws => ws.id === activeWorkspace.id);
|
|
316
|
+
if (updatedActiveWorkspace && updatedActiveWorkspace !== activeWorkspace) {
|
|
317
|
+
this.activeWorkspace = updatedActiveWorkspace;
|
|
318
|
+
}
|
|
319
|
+
}
|
|
320
|
+
// If activeWorkspaceId is set, try to keep it in sync with the updated workspaces list
|
|
321
|
+
if (this.activeWorkspaceId) {
|
|
322
|
+
const workspaceWithId = newWorkspaces.find(ws => ws.id === this.activeWorkspaceId);
|
|
323
|
+
if (workspaceWithId && workspaceWithId !== this.activeWorkspace) {
|
|
324
|
+
this.activeWorkspace = workspaceWithId;
|
|
325
|
+
}
|
|
326
|
+
}
|
|
327
|
+
}
|
|
328
|
+
onActiveWorkspaceChange() {
|
|
329
|
+
this.updateCurrentIsPublic();
|
|
330
|
+
}
|
|
331
|
+
onCustomFontsChange(newValue) {
|
|
332
|
+
void this.registerCustomFonts(newValue);
|
|
333
|
+
}
|
|
334
|
+
onMoreMenuItemsChange() {
|
|
335
|
+
this.recomputeMoreMenuItems();
|
|
336
|
+
}
|
|
337
|
+
onSyncConfigChange() {
|
|
338
|
+
this.recomputeMoreMenuItems();
|
|
339
|
+
}
|
|
340
|
+
onLoginConfigChange() {
|
|
341
|
+
this.recomputeMoreMenuItems();
|
|
342
|
+
}
|
|
343
|
+
onUserChange() {
|
|
344
|
+
this.recomputeMoreMenuItems();
|
|
345
|
+
}
|
|
346
|
+
onActiveWorkspaceIdChange(newId) {
|
|
347
|
+
// If no ID is provided, do nothing (allows other logic to control activeWorkspace)
|
|
348
|
+
if (!newId) {
|
|
349
|
+
return;
|
|
350
|
+
}
|
|
351
|
+
// If workspaces are not loaded yet, the watch will fire again once they are
|
|
352
|
+
if (this.availableWorkspaces.length === 0) {
|
|
353
|
+
return;
|
|
354
|
+
}
|
|
355
|
+
// Find the workspace with the matching ID
|
|
356
|
+
const workspace = this.availableWorkspaces.find(ws => ws.id === newId);
|
|
357
|
+
if (workspace) {
|
|
358
|
+
// Only update if it's different from the current activeWorkspace
|
|
359
|
+
if (workspace !== this.activeWorkspace) {
|
|
360
|
+
this.activeWorkspace = workspace;
|
|
361
|
+
}
|
|
362
|
+
}
|
|
363
|
+
else {
|
|
364
|
+
console.warn(`[KritzelEditor] No workspace found with ID: ${newId}`);
|
|
365
|
+
}
|
|
366
|
+
}
|
|
367
|
+
onCurrentThemeChange() {
|
|
368
|
+
this.applyTheme();
|
|
369
|
+
setTimeout(() => this.setOsSpecificCssVariables(), 0);
|
|
370
|
+
if (this.engineRef) {
|
|
371
|
+
this.engineRef.saveSettings(this.currentSettingsConfig);
|
|
372
|
+
}
|
|
373
|
+
}
|
|
374
|
+
onThemesChange() {
|
|
375
|
+
this.applyTheme();
|
|
376
|
+
}
|
|
377
|
+
onLocaleChange(newValue) {
|
|
378
|
+
if (this.engineRef) {
|
|
379
|
+
this.engineRef.setLocale(newValue);
|
|
380
|
+
this.engineRef.saveSettings(this.currentSettingsConfig);
|
|
381
|
+
void this.refreshLocalizedTerms();
|
|
382
|
+
}
|
|
383
|
+
}
|
|
384
|
+
onLocalesChange(newValue) {
|
|
385
|
+
if (this.engineRef) {
|
|
386
|
+
void this.engineRef.configureLocales(newValue).then(() => this.refreshLocalizedTerms());
|
|
387
|
+
}
|
|
388
|
+
}
|
|
389
|
+
/**
|
|
390
|
+
* Refreshes the editor-owned localized strings (e.g. the more menu and the
|
|
391
|
+
* strings forwarded to child UI components) from the engine's localization
|
|
392
|
+
* manager for the active locale.
|
|
393
|
+
*/
|
|
394
|
+
async refreshLocalizedTerms() {
|
|
395
|
+
if (!this.engineRef) {
|
|
396
|
+
return;
|
|
397
|
+
}
|
|
398
|
+
const resolvedLocale = await this.engineRef.getLocale();
|
|
399
|
+
if (resolvedLocale !== this.locale) {
|
|
400
|
+
// Auto-selected because the previous locale isn't in the (possibly replaced) available set.
|
|
401
|
+
this.locale = resolvedLocale;
|
|
402
|
+
this.localeChange.emit(resolvedLocale);
|
|
403
|
+
}
|
|
404
|
+
this.resolvedTerms = await this.engineRef.getResolvedTerms();
|
|
405
|
+
this.availableLocaleOptions = await this.engineRef.getAvailableLocaleOptions();
|
|
406
|
+
this.recomputeMoreMenuItems();
|
|
407
|
+
}
|
|
408
|
+
onTouchStart(event) {
|
|
409
|
+
if (event.cancelable) {
|
|
410
|
+
event.preventDefault();
|
|
411
|
+
}
|
|
412
|
+
}
|
|
413
|
+
async getObjectById(id) {
|
|
414
|
+
return this.engineRef.getObjectById(id);
|
|
415
|
+
}
|
|
416
|
+
async addObject(object) {
|
|
417
|
+
return this.engineRef.addObject(object);
|
|
418
|
+
}
|
|
419
|
+
async addObjects(objects) {
|
|
420
|
+
return this.engineRef.addObjects(objects);
|
|
421
|
+
}
|
|
422
|
+
async updateObject(object, updatedProperties) {
|
|
423
|
+
return this.engineRef.updateObject(object, updatedProperties);
|
|
424
|
+
}
|
|
425
|
+
async removeObject(object) {
|
|
426
|
+
return this.engineRef.removeObject(object);
|
|
427
|
+
}
|
|
428
|
+
async removeObjects(objects) {
|
|
429
|
+
return this.engineRef.removeObjects(objects);
|
|
430
|
+
}
|
|
431
|
+
async getSelectedObjects() {
|
|
432
|
+
return this.engineRef.getSelectedObjects();
|
|
433
|
+
}
|
|
434
|
+
async selectObjects(objects) {
|
|
435
|
+
return this.engineRef.selectObjects(objects);
|
|
436
|
+
}
|
|
437
|
+
async selectAllObjectsInViewport() {
|
|
438
|
+
return this.engineRef.selectAllObjectsInViewport();
|
|
439
|
+
}
|
|
440
|
+
async clearSelection() {
|
|
441
|
+
this.engineRef.clearSelection();
|
|
442
|
+
}
|
|
443
|
+
async centerObjectInViewport(object) {
|
|
444
|
+
return this.engineRef.centerObjectInViewport(object);
|
|
445
|
+
}
|
|
446
|
+
async panToObject(object) {
|
|
447
|
+
return this.engineRef.panToObject(object);
|
|
448
|
+
}
|
|
449
|
+
async backToContent() {
|
|
450
|
+
return this.engineRef.backToContent();
|
|
451
|
+
}
|
|
452
|
+
async centerAllObjects(animate = true) {
|
|
453
|
+
return this.engineRef.centerAllObjects(animate);
|
|
454
|
+
}
|
|
455
|
+
async centerObjects(objects, animate = true) {
|
|
456
|
+
return this.engineRef.centerObjects(objects, animate);
|
|
457
|
+
}
|
|
458
|
+
async setViewport(x, y, scale) {
|
|
459
|
+
return this.engineRef.setViewport(x, y, scale);
|
|
460
|
+
}
|
|
461
|
+
async panTo(x, y) {
|
|
462
|
+
return this.engineRef.panTo(x, y);
|
|
463
|
+
}
|
|
464
|
+
async zoomTo(scale, worldX, worldY) {
|
|
465
|
+
return this.engineRef.zoomTo(scale, worldX, worldY);
|
|
466
|
+
}
|
|
467
|
+
async zoomIn(factor = 1.6, duration = 200) {
|
|
468
|
+
return this.engineRef.zoomIn(factor, duration);
|
|
469
|
+
}
|
|
470
|
+
async zoomOut(factor = 1.6, duration = 200) {
|
|
471
|
+
return this.engineRef.zoomOut(factor, duration);
|
|
472
|
+
}
|
|
473
|
+
async getViewport() {
|
|
474
|
+
return this.engineRef.getViewport();
|
|
475
|
+
}
|
|
476
|
+
async screenToWorld(x, y) {
|
|
477
|
+
return this.engineRef.screenToWorld(x, y);
|
|
478
|
+
}
|
|
479
|
+
async worldToScreen(x, y) {
|
|
480
|
+
return this.engineRef.worldToScreen(x, y);
|
|
481
|
+
}
|
|
482
|
+
async setActiveWorkspace(id) {
|
|
483
|
+
return this.engineRef.setActiveWorkspace(id);
|
|
484
|
+
}
|
|
485
|
+
async createWorkspace(workspace) {
|
|
486
|
+
return this.engineRef.createWorkspace(workspace);
|
|
487
|
+
}
|
|
488
|
+
async updateWorkspace(workspace) {
|
|
489
|
+
return this.engineRef.updateWorkspace(workspace);
|
|
490
|
+
}
|
|
491
|
+
async deleteWorkspace(workspace) {
|
|
492
|
+
return this.engineRef.deleteWorkspace(workspace);
|
|
493
|
+
}
|
|
494
|
+
async getWorkspaces() {
|
|
495
|
+
return this.engineRef.getWorkspaces();
|
|
496
|
+
}
|
|
497
|
+
async getActiveWorkspace() {
|
|
498
|
+
return this.engineRef.getActiveWorkspace();
|
|
499
|
+
}
|
|
500
|
+
async loadSharedWorkspace(token) {
|
|
501
|
+
return this.engineRef.loadSharedWorkspace(token);
|
|
502
|
+
}
|
|
503
|
+
async reinitSync() {
|
|
504
|
+
return this.engineRef.reinitSync();
|
|
505
|
+
}
|
|
506
|
+
// ── Tool management ─────────────────────────────────────────────────
|
|
507
|
+
async registerTool(toolName, toolClass, toolConfig) {
|
|
508
|
+
return this.engineRef.registerTool(toolName, toolClass, toolConfig);
|
|
509
|
+
}
|
|
510
|
+
async changeActiveTool(toolName) {
|
|
511
|
+
return this.engineRef.changeActiveTool(toolName);
|
|
512
|
+
}
|
|
513
|
+
async disable() {
|
|
514
|
+
return this.engineRef.disable();
|
|
515
|
+
}
|
|
516
|
+
async enable() {
|
|
517
|
+
return this.engineRef.enable();
|
|
518
|
+
}
|
|
519
|
+
async copy() {
|
|
520
|
+
return this.engineRef.copy();
|
|
521
|
+
}
|
|
522
|
+
async cut() {
|
|
523
|
+
return this.engineRef.cut();
|
|
524
|
+
}
|
|
525
|
+
async paste(x, y) {
|
|
526
|
+
return this.engineRef.paste(x, y);
|
|
527
|
+
}
|
|
528
|
+
async delete() {
|
|
529
|
+
return this.engineRef.delete();
|
|
530
|
+
}
|
|
531
|
+
async bringForward(object) {
|
|
532
|
+
return this.engineRef.bringForward(object);
|
|
533
|
+
}
|
|
534
|
+
async sendBackward(object) {
|
|
535
|
+
return this.engineRef.sendBackward(object);
|
|
536
|
+
}
|
|
537
|
+
async bringToFront(object) {
|
|
538
|
+
return this.engineRef.bringToFront(object);
|
|
539
|
+
}
|
|
540
|
+
async sendToBack(object) {
|
|
541
|
+
return this.engineRef.sendToBack(object);
|
|
542
|
+
}
|
|
543
|
+
async alignObjects(alignment) {
|
|
544
|
+
return this.engineRef.alignObjects(alignment);
|
|
545
|
+
}
|
|
546
|
+
async group() {
|
|
547
|
+
return this.engineRef.group();
|
|
548
|
+
}
|
|
549
|
+
async ungroup() {
|
|
550
|
+
return this.engineRef.ungroup();
|
|
551
|
+
}
|
|
552
|
+
async undo() {
|
|
553
|
+
return this.engineRef.undo();
|
|
554
|
+
}
|
|
555
|
+
async redo() {
|
|
556
|
+
return this.engineRef.redo();
|
|
557
|
+
}
|
|
558
|
+
async getScreenshot(format = 'png') {
|
|
559
|
+
return this.engineRef.getScreenshot(format);
|
|
560
|
+
}
|
|
561
|
+
async exportViewportAsPng() {
|
|
562
|
+
return this.engineRef.exportViewportAsPng();
|
|
563
|
+
}
|
|
564
|
+
async exportViewportAsSvg() {
|
|
565
|
+
return this.engineRef.exportViewportAsSvg();
|
|
566
|
+
}
|
|
567
|
+
async getSelectedObjectSupportedExportFormats() {
|
|
568
|
+
return this.engineRef.getSelectedObjectSupportedExportFormats();
|
|
569
|
+
}
|
|
570
|
+
async canExportSelectedObjectAs(format) {
|
|
571
|
+
return this.engineRef.canExportSelectedObjectAs(format);
|
|
572
|
+
}
|
|
573
|
+
async exportSelectedObject(format) {
|
|
574
|
+
return this.engineRef.exportSelectedObject(format);
|
|
575
|
+
}
|
|
576
|
+
async exportAsJson() {
|
|
577
|
+
return this.engineRef.exportAsJson();
|
|
578
|
+
}
|
|
579
|
+
async importFromJson(json) {
|
|
580
|
+
return this.engineRef.importFromJson(json);
|
|
581
|
+
}
|
|
582
|
+
async downloadAsJson(filename) {
|
|
583
|
+
return this.engineRef.downloadAsJson(filename);
|
|
584
|
+
}
|
|
585
|
+
async importFromFile() {
|
|
586
|
+
return this.engineRef.importFromFile();
|
|
587
|
+
}
|
|
588
|
+
async loadObjectsFromJson(json) {
|
|
589
|
+
return this.engineRef.loadObjectsFromJson(json);
|
|
590
|
+
}
|
|
591
|
+
async getObjectsTotalCount() {
|
|
592
|
+
return this.engineRef.getObjectsTotalCount();
|
|
593
|
+
}
|
|
594
|
+
async getAllObjects() {
|
|
595
|
+
return this.engineRef.getAllObjects();
|
|
596
|
+
}
|
|
597
|
+
async findObjects(predicate) {
|
|
598
|
+
return this.engineRef.findObjects(predicate);
|
|
599
|
+
}
|
|
600
|
+
async getObjectsInViewport() {
|
|
601
|
+
return this.engineRef.getObjectsInViewport();
|
|
602
|
+
}
|
|
603
|
+
async hideContextMenu() {
|
|
604
|
+
return this.engineRef.hideContextMenu();
|
|
605
|
+
}
|
|
606
|
+
async openContextMenu(options) {
|
|
607
|
+
return this.engineRef.openContextMenu(options);
|
|
608
|
+
}
|
|
609
|
+
async openWorkspaceManagerMenu() {
|
|
610
|
+
if (!this.isWorkspaceManagerVisible) {
|
|
611
|
+
return;
|
|
612
|
+
}
|
|
613
|
+
await this.workspaceManagerRef?.open();
|
|
614
|
+
}
|
|
615
|
+
async closeWorkspaceManagerMenu() {
|
|
616
|
+
await this.workspaceManagerRef?.close();
|
|
617
|
+
}
|
|
618
|
+
async openMoreMenu() {
|
|
619
|
+
if (!this.isMoreMenuVisible) {
|
|
620
|
+
return;
|
|
621
|
+
}
|
|
622
|
+
await this.moreMenuRef?.open();
|
|
623
|
+
}
|
|
624
|
+
async closeMoreMenu() {
|
|
625
|
+
await this.moreMenuRef?.close();
|
|
626
|
+
}
|
|
627
|
+
async openUserDialog() {
|
|
628
|
+
await this.currentUserDialogRef?.open();
|
|
629
|
+
}
|
|
630
|
+
async closeUserDialog() {
|
|
631
|
+
await this.currentUserDialogRef?.close();
|
|
632
|
+
}
|
|
633
|
+
async openExportDialog() {
|
|
634
|
+
const preview = await this.engineRef.getScreenshot('png');
|
|
635
|
+
await this.exportRef?.open(preview ?? undefined);
|
|
636
|
+
}
|
|
637
|
+
async closeExportDialog() {
|
|
638
|
+
await this.exportRef?.close();
|
|
639
|
+
}
|
|
640
|
+
async openImportDialog() {
|
|
641
|
+
await this.engineRef.importFromFile();
|
|
642
|
+
}
|
|
643
|
+
async closeImportDialog() {
|
|
644
|
+
await this.engineRef.cancelImportFromFile();
|
|
645
|
+
}
|
|
646
|
+
async openSettingsDialog() {
|
|
647
|
+
await this.settingsRef?.open();
|
|
648
|
+
}
|
|
649
|
+
async closeSettingsDialog() {
|
|
650
|
+
await this.settingsRef?.close();
|
|
651
|
+
}
|
|
652
|
+
async openShareDialog() {
|
|
653
|
+
await this.shareDialogRef?.open();
|
|
654
|
+
}
|
|
655
|
+
async closeShareDialog() {
|
|
656
|
+
await this.shareDialogRef?.close();
|
|
657
|
+
}
|
|
658
|
+
async triggerSelectionChange() {
|
|
659
|
+
return this.engineRef.triggerSelectionChange();
|
|
660
|
+
}
|
|
661
|
+
async beginSceneBootstrap() {
|
|
662
|
+
return this.engineRef.beginSceneBootstrap();
|
|
663
|
+
}
|
|
664
|
+
async endSceneBootstrap() {
|
|
665
|
+
return this.engineRef.endSceneBootstrap();
|
|
666
|
+
}
|
|
667
|
+
async getDisplayableShortcuts() {
|
|
668
|
+
return this.engineRef.getDisplayableShortcuts();
|
|
669
|
+
}
|
|
670
|
+
async openLoginDialog() {
|
|
671
|
+
this.loginDialogRef?.open();
|
|
672
|
+
}
|
|
673
|
+
async closeLoginDialog() {
|
|
674
|
+
this.loginDialogRef?.close();
|
|
675
|
+
}
|
|
676
|
+
async setLoginLoading(provider) {
|
|
677
|
+
this.loginDialogRef?.setLoading(provider);
|
|
678
|
+
}
|
|
679
|
+
/**
|
|
680
|
+
* Sets the active locale (language) and re-renders the UI.
|
|
681
|
+
* @param code - The locale code to activate, e.g. 'de'.
|
|
682
|
+
*/
|
|
683
|
+
async setLocale(code) {
|
|
684
|
+
this.locale = code;
|
|
685
|
+
await this.engineRef?.setLocale(code);
|
|
686
|
+
}
|
|
687
|
+
/**
|
|
688
|
+
* Gets the currently active locale code.
|
|
689
|
+
*/
|
|
690
|
+
async getLocale() {
|
|
691
|
+
return this.engineRef ? this.engineRef.getLocale() : this.locale;
|
|
692
|
+
}
|
|
693
|
+
/**
|
|
694
|
+
* Gets the list of available locale codes (built-in and registered).
|
|
695
|
+
*/
|
|
696
|
+
async getAvailableLocales() {
|
|
697
|
+
return this.engineRef ? this.engineRef.getAvailableLocales() : [];
|
|
698
|
+
}
|
|
699
|
+
/**
|
|
700
|
+
* Registers additional locale definitions (with optional partial term overrides).
|
|
701
|
+
* @param locales - The locale definitions to register.
|
|
702
|
+
*/
|
|
703
|
+
async registerLocales(locales) {
|
|
704
|
+
await this.engineRef?.registerLocales(locales);
|
|
705
|
+
}
|
|
706
|
+
/**
|
|
707
|
+
* Registers custom fonts for the editor runtime.
|
|
708
|
+
* @param fonts - Mapping from font keys to family names or font definitions.
|
|
709
|
+
* @remarks This no longer controls the text-tool config tooltip font options.
|
|
710
|
+
* Configure tooltip fonts via toolbarItems[].config.availableFonts.
|
|
711
|
+
*/
|
|
712
|
+
async registerFonts(fonts) {
|
|
713
|
+
await this.registerCustomFonts(fonts);
|
|
714
|
+
}
|
|
715
|
+
/**
|
|
716
|
+
* Resolves a term key to its translated string for the active locale.
|
|
717
|
+
* @param key - The term key to resolve.
|
|
718
|
+
* @param vars - Optional values for `{placeholder}` interpolation.
|
|
719
|
+
*/
|
|
720
|
+
async t(key, vars) {
|
|
721
|
+
return this.engineRef ? this.engineRef.t(key, vars) : key;
|
|
722
|
+
}
|
|
723
|
+
/**
|
|
724
|
+
* Triggers a UI notification programmatically.
|
|
725
|
+
* @param notification - Notification payload. `id` and `timestamp` are optional.
|
|
726
|
+
*/
|
|
727
|
+
async triggerNotification(notification) {
|
|
728
|
+
const normalizedNotification = {
|
|
729
|
+
...notification,
|
|
730
|
+
id: notification.id ?? ObjectHelper.generateUUID(),
|
|
731
|
+
timestamp: notification.timestamp ?? new Date(),
|
|
732
|
+
};
|
|
733
|
+
this.clearNotificationDismissAnimationTimer();
|
|
734
|
+
this.isNotificationDismissing = false;
|
|
735
|
+
this.isNotificationHovered = false;
|
|
736
|
+
this.activeNotification = normalizedNotification;
|
|
737
|
+
this.scheduleNotificationDismiss();
|
|
738
|
+
}
|
|
739
|
+
engineRef;
|
|
740
|
+
toolbarRef;
|
|
741
|
+
settingsRef;
|
|
742
|
+
exportRef;
|
|
743
|
+
splitButtonRef;
|
|
744
|
+
workspaceManagerRef;
|
|
745
|
+
moreMenuRef;
|
|
746
|
+
shareDialogRef;
|
|
747
|
+
loginDialogRef;
|
|
748
|
+
currentUserDialogRef;
|
|
749
|
+
componentWillLoad() {
|
|
750
|
+
this.recomputeMoreMenuItems();
|
|
751
|
+
this.loadSettingsFromStorage();
|
|
752
|
+
this.applyTheme();
|
|
753
|
+
}
|
|
754
|
+
isTextToolConfig(config) {
|
|
755
|
+
return !!config && 'fontFamily' in config && 'size' in config && 'color' in config;
|
|
756
|
+
}
|
|
757
|
+
lastToolbarItemsRef = null;
|
|
758
|
+
lastNormalizedToolbarItems = [];
|
|
759
|
+
getNormalizedToolbarItems() {
|
|
760
|
+
if (this.toolbarItems !== this.lastToolbarItemsRef) {
|
|
761
|
+
this.lastToolbarItemsRef = this.toolbarItems;
|
|
762
|
+
this.lastNormalizedToolbarItems = this.normalizeToolbar(this.toolbarItems);
|
|
763
|
+
}
|
|
764
|
+
return this.lastNormalizedToolbarItems;
|
|
765
|
+
}
|
|
766
|
+
normalizeToolbar(toolbarItems) {
|
|
767
|
+
return toolbarItems.map(control => {
|
|
768
|
+
if (!this.isTextToolConfig(control.config)) {
|
|
769
|
+
return control;
|
|
770
|
+
}
|
|
771
|
+
return {
|
|
772
|
+
...control,
|
|
773
|
+
config: {
|
|
774
|
+
...control.config,
|
|
775
|
+
availableFonts: resolveTextToolAvailableFonts(control.config.availableFonts),
|
|
776
|
+
},
|
|
777
|
+
};
|
|
778
|
+
});
|
|
779
|
+
}
|
|
780
|
+
recomputeMoreMenuItems() {
|
|
781
|
+
if (this.moreMenuItems) {
|
|
782
|
+
this.resolvedMoreMenuItems = this.moreMenuItems;
|
|
783
|
+
return;
|
|
784
|
+
}
|
|
785
|
+
}
|
|
786
|
+
applyTheme() {
|
|
787
|
+
const themeObj = this.resolveThemeObject();
|
|
788
|
+
ThemeHelper.applyThemeToElement(this.host, themeObj);
|
|
789
|
+
}
|
|
790
|
+
resolveThemeObject() {
|
|
791
|
+
return this.themes?.find(t => t.name === this.theme) ?? (this.theme === 'dark' ? darkTheme : lightTheme);
|
|
792
|
+
}
|
|
793
|
+
componentDidLoad() {
|
|
794
|
+
this.registerCustomSvgIcons();
|
|
795
|
+
this.registerCustomFonts();
|
|
796
|
+
this.listenForMobileKeyboard();
|
|
797
|
+
this.setOsSpecificCssVariables();
|
|
798
|
+
}
|
|
799
|
+
disconnectedCallback() {
|
|
800
|
+
this.clearLoadingOverlayShowTimer();
|
|
801
|
+
this.clearLoadingOverlayHideTimer();
|
|
802
|
+
this.clearNotificationDismissTimer();
|
|
803
|
+
this.clearNotificationDismissAnimationTimer();
|
|
804
|
+
}
|
|
805
|
+
async checkIsReady() {
|
|
806
|
+
await customElements.whenDefined('kritzel-editor');
|
|
807
|
+
await customElements.whenDefined('kritzel-workspace-manager');
|
|
808
|
+
await customElements.whenDefined('kritzel-toolbar');
|
|
809
|
+
await customElements.whenDefined('kritzel-engine');
|
|
810
|
+
await this.waitForCustomFontsReady();
|
|
811
|
+
if (!this.isEngineReady || !this.isToolbarReady || !this.isWorkspaceManagerReady || !this.activeWorkspace) {
|
|
812
|
+
return;
|
|
813
|
+
}
|
|
814
|
+
this.isEditorVisible = true;
|
|
815
|
+
const { id, name, isPublic, createdAt, updatedAt } = this.activeWorkspace;
|
|
816
|
+
this.isReady.emit({
|
|
817
|
+
host: this.host,
|
|
818
|
+
activeWorkspace: {
|
|
819
|
+
id,
|
|
820
|
+
name,
|
|
821
|
+
isPublic,
|
|
822
|
+
createdAt,
|
|
823
|
+
updatedAt,
|
|
824
|
+
},
|
|
825
|
+
syncConfig: this.syncConfig,
|
|
826
|
+
assetStorageConfig: this.assetStorageConfig,
|
|
827
|
+
loginConfig: this.loginConfig,
|
|
828
|
+
theme: this.theme,
|
|
829
|
+
});
|
|
830
|
+
}
|
|
831
|
+
async onEngineReady(event) {
|
|
832
|
+
this.isEngineReady = true;
|
|
833
|
+
if (!event.detail.activeWorkspace) {
|
|
834
|
+
return;
|
|
835
|
+
}
|
|
836
|
+
this.activeWorkspace = event.detail.activeWorkspace;
|
|
837
|
+
this.availableWorkspaces = event.detail.workspaces;
|
|
838
|
+
this.currentIsPublic = await this.engineRef.getIsPublic();
|
|
839
|
+
await this.refreshLocalizedTerms();
|
|
840
|
+
const viewport = await this.engineRef.getViewport();
|
|
841
|
+
this.currentZoomPercent = this.getZoomPercentFromScale(viewport.scale);
|
|
842
|
+
this.loadShortcuts();
|
|
843
|
+
}
|
|
844
|
+
handleWorkspacesChange(event) {
|
|
845
|
+
event.stopPropagation();
|
|
846
|
+
this.availableWorkspaces = event.detail;
|
|
847
|
+
}
|
|
848
|
+
async handleWorkspaceManagerChange(event) {
|
|
849
|
+
event.stopPropagation();
|
|
850
|
+
const workspace = event.detail;
|
|
851
|
+
this.activeWorkspace = workspace ?? undefined;
|
|
852
|
+
if (!workspace) {
|
|
853
|
+
return;
|
|
854
|
+
}
|
|
855
|
+
await this.engineRef.setActiveWorkspace(workspace.id);
|
|
856
|
+
}
|
|
857
|
+
handleActiveWorkspaceChange(event) {
|
|
858
|
+
event.stopPropagation();
|
|
859
|
+
this.activeWorkspace = event.detail;
|
|
860
|
+
if (!this.isEngineReady) {
|
|
861
|
+
return;
|
|
862
|
+
}
|
|
863
|
+
const { id, name, isPublic, createdAt, updatedAt } = this.activeWorkspace;
|
|
864
|
+
this.activeWorkspaceChange.emit({
|
|
865
|
+
id,
|
|
866
|
+
name,
|
|
867
|
+
isPublic,
|
|
868
|
+
createdAt,
|
|
869
|
+
updatedAt,
|
|
870
|
+
});
|
|
871
|
+
}
|
|
872
|
+
handleObjectsChange(event) {
|
|
873
|
+
event.stopPropagation();
|
|
874
|
+
this.objectsChange.emit(event.detail);
|
|
875
|
+
}
|
|
876
|
+
handleObjectsAdded(event) {
|
|
877
|
+
event.stopPropagation();
|
|
878
|
+
this.objectsAdded.emit(event.detail);
|
|
879
|
+
}
|
|
880
|
+
handleObjectsRemoved(event) {
|
|
881
|
+
event.stopPropagation();
|
|
882
|
+
this.objectsRemoved.emit(event.detail);
|
|
883
|
+
}
|
|
884
|
+
handleObjectsUpdated(event) {
|
|
885
|
+
event.stopPropagation();
|
|
886
|
+
this.objectsUpdated.emit(event.detail);
|
|
887
|
+
}
|
|
888
|
+
handleObjectsSelectionChange(event) {
|
|
889
|
+
console.log(event.detail);
|
|
890
|
+
event.stopPropagation();
|
|
891
|
+
this.objectsSelectionChange.emit(event.detail);
|
|
892
|
+
}
|
|
893
|
+
handleUndoStateChange(event) {
|
|
894
|
+
event.stopPropagation();
|
|
895
|
+
this.undoStateChange.emit(event.detail);
|
|
896
|
+
this.undoState = event.detail;
|
|
897
|
+
}
|
|
898
|
+
async handleObjectsInViewportChange(event) {
|
|
899
|
+
event.stopPropagation();
|
|
900
|
+
const hasVisibleObjects = this.getContentObjects(event.detail).length > 0;
|
|
901
|
+
const hasAnyObjectsAtAll = this.getContentObjects(await this.engineRef.getAllObjects()).length > 0;
|
|
902
|
+
this.isBackToContentButtonVisible = !hasVisibleObjects && hasAnyObjectsAtAll;
|
|
903
|
+
}
|
|
904
|
+
handleViewportChange(event) {
|
|
905
|
+
event.stopPropagation();
|
|
906
|
+
this.currentZoomPercent = this.getZoomPercentFromScale(event.detail.scale);
|
|
907
|
+
this.viewportChange.emit(event.detail);
|
|
908
|
+
}
|
|
909
|
+
getZoomPercentFromScale(scale) {
|
|
910
|
+
if (!Number.isFinite(scale) || scale <= 0) {
|
|
911
|
+
return 100;
|
|
912
|
+
}
|
|
913
|
+
return Math.round(scale * 100);
|
|
914
|
+
}
|
|
915
|
+
handleAwarenessChange(event) {
|
|
916
|
+
event.stopPropagation();
|
|
917
|
+
this.awarenessChange.emit(event.detail);
|
|
918
|
+
}
|
|
919
|
+
handleNotificationsChange(event) {
|
|
920
|
+
event.stopPropagation();
|
|
921
|
+
this.clearNotificationDismissAnimationTimer();
|
|
922
|
+
this.isNotificationDismissing = false;
|
|
923
|
+
this.isNotificationHovered = false;
|
|
924
|
+
this.activeNotification = event.detail;
|
|
925
|
+
this.scheduleNotificationDismiss();
|
|
926
|
+
}
|
|
927
|
+
handleContextMenuStateChange(event) {
|
|
928
|
+
event.stopPropagation();
|
|
929
|
+
this.contextMenuState = event.detail.isVisible ? event.detail : undefined;
|
|
930
|
+
}
|
|
931
|
+
handleIsLoadingChange(event) {
|
|
932
|
+
console.log('isLoadingChange event:', event.detail);
|
|
933
|
+
event.stopPropagation();
|
|
934
|
+
this.clearLoadingOverlayShowTimer();
|
|
935
|
+
this.clearLoadingOverlayHideTimer();
|
|
936
|
+
if (event.detail) {
|
|
937
|
+
this.loadingOverlayShowTimeout = setTimeout(() => {
|
|
938
|
+
this.isLoadingOverlayVisible = true;
|
|
939
|
+
this.loadingOverlayShownTimestamp = Date.now();
|
|
940
|
+
this.loadingOverlayShowTimeout = undefined;
|
|
941
|
+
}, this.loadingOverlayDelayMs);
|
|
942
|
+
return;
|
|
943
|
+
}
|
|
944
|
+
if (this.isLoadingOverlayVisible && this.loadingOverlayShownTimestamp !== undefined) {
|
|
945
|
+
const elapsed = Date.now() - this.loadingOverlayShownTimestamp;
|
|
946
|
+
const remaining = this.loadingOverlayMinDisplayDurationMs - elapsed;
|
|
947
|
+
if (remaining > 0) {
|
|
948
|
+
this.loadingOverlayHideTimeout = setTimeout(() => {
|
|
949
|
+
this.isLoadingOverlayVisible = false;
|
|
950
|
+
this.loadingOverlayShownTimestamp = undefined;
|
|
951
|
+
this.loadingOverlayHideTimeout = undefined;
|
|
952
|
+
}, remaining);
|
|
953
|
+
return;
|
|
954
|
+
}
|
|
955
|
+
}
|
|
956
|
+
this.isLoadingOverlayVisible = false;
|
|
957
|
+
this.loadingOverlayShownTimestamp = undefined;
|
|
958
|
+
}
|
|
959
|
+
clearLoadingOverlayShowTimer() {
|
|
960
|
+
if (this.loadingOverlayShowTimeout) {
|
|
961
|
+
clearTimeout(this.loadingOverlayShowTimeout);
|
|
962
|
+
this.loadingOverlayShowTimeout = undefined;
|
|
963
|
+
}
|
|
964
|
+
}
|
|
965
|
+
clearLoadingOverlayHideTimer() {
|
|
966
|
+
if (this.loadingOverlayHideTimeout) {
|
|
967
|
+
clearTimeout(this.loadingOverlayHideTimeout);
|
|
968
|
+
this.loadingOverlayHideTimeout = undefined;
|
|
969
|
+
}
|
|
970
|
+
}
|
|
971
|
+
handleContextMenuActionSelected(event) {
|
|
972
|
+
const contextMenuState = this.contextMenuState;
|
|
973
|
+
if (!contextMenuState || !event.detail.action) {
|
|
974
|
+
void this.hideContextMenu();
|
|
975
|
+
return;
|
|
976
|
+
}
|
|
977
|
+
event.detail.action({
|
|
978
|
+
x: contextMenuState.worldPosition.x,
|
|
979
|
+
y: contextMenuState.worldPosition.y,
|
|
980
|
+
}, contextMenuState.objects);
|
|
981
|
+
void this.hideContextMenu();
|
|
982
|
+
}
|
|
983
|
+
handleNotificationHoverChange(event) {
|
|
984
|
+
event.stopPropagation();
|
|
985
|
+
this.isNotificationHovered = event.detail;
|
|
986
|
+
if (this.isNotificationHovered) {
|
|
987
|
+
this.clearNotificationDismissTimer();
|
|
988
|
+
return;
|
|
989
|
+
}
|
|
990
|
+
if (this.activeNotification && !this.isNotificationDismissing) {
|
|
991
|
+
this.scheduleNotificationDismiss();
|
|
992
|
+
}
|
|
993
|
+
}
|
|
994
|
+
scheduleNotificationDismiss() {
|
|
995
|
+
this.clearNotificationDismissTimer();
|
|
996
|
+
this.notificationDismissTimeout = setTimeout(() => {
|
|
997
|
+
this.dismissNotification();
|
|
998
|
+
}, this.notificationDisplayDurationMs);
|
|
999
|
+
}
|
|
1000
|
+
clearNotificationDismissTimer() {
|
|
1001
|
+
if (this.notificationDismissTimeout) {
|
|
1002
|
+
clearTimeout(this.notificationDismissTimeout);
|
|
1003
|
+
this.notificationDismissTimeout = undefined;
|
|
1004
|
+
}
|
|
1005
|
+
}
|
|
1006
|
+
clearNotificationDismissAnimationTimer() {
|
|
1007
|
+
if (this.notificationDismissAnimationTimeout) {
|
|
1008
|
+
clearTimeout(this.notificationDismissAnimationTimeout);
|
|
1009
|
+
this.notificationDismissAnimationTimeout = undefined;
|
|
1010
|
+
}
|
|
1011
|
+
}
|
|
1012
|
+
dismissNotification = () => {
|
|
1013
|
+
this.clearNotificationDismissTimer();
|
|
1014
|
+
this.isNotificationHovered = false;
|
|
1015
|
+
if (!this.activeNotification || this.isNotificationDismissing) {
|
|
1016
|
+
return;
|
|
1017
|
+
}
|
|
1018
|
+
this.isNotificationDismissing = true;
|
|
1019
|
+
this.clearNotificationDismissAnimationTimer();
|
|
1020
|
+
this.notificationDismissAnimationTimeout = setTimeout(() => {
|
|
1021
|
+
this.activeNotification = undefined;
|
|
1022
|
+
this.isNotificationDismissing = false;
|
|
1023
|
+
this.notificationDismissAnimationTimeout = undefined;
|
|
1024
|
+
}, this.notificationDismissAnimationDurationMs);
|
|
1025
|
+
};
|
|
1026
|
+
handleSettingsChange(event) {
|
|
1027
|
+
this.scaleMin = event.detail.scaleMin;
|
|
1028
|
+
this.scaleMax = event.detail.scaleMax;
|
|
1029
|
+
this.lockDrawingScale = event.detail.lockDrawingScale;
|
|
1030
|
+
this.theme = event.detail.theme;
|
|
1031
|
+
if (typeof event.detail.locale === 'string' && event.detail.locale !== this.locale) {
|
|
1032
|
+
this.locale = event.detail.locale;
|
|
1033
|
+
this.localeChange.emit(event.detail.locale);
|
|
1034
|
+
}
|
|
1035
|
+
this.viewportBoundaryLeft = event.detail.viewportBoundaryLeft ?? -Infinity;
|
|
1036
|
+
this.viewportBoundaryRight = event.detail.viewportBoundaryRight ?? Infinity;
|
|
1037
|
+
this.viewportBoundaryTop = event.detail.viewportBoundaryTop ?? -Infinity;
|
|
1038
|
+
this.viewportBoundaryBottom = event.detail.viewportBoundaryBottom ?? Infinity;
|
|
1039
|
+
this.debugInfo = event.detail.debugInfo;
|
|
1040
|
+
if (this.engineRef) {
|
|
1041
|
+
this.engineRef.saveSettings(event.detail);
|
|
1042
|
+
}
|
|
1043
|
+
this.themeChange.emit(event.detail.theme);
|
|
1044
|
+
}
|
|
1045
|
+
handleToggleIsPublic = async (event) => {
|
|
1046
|
+
const isPublic = event.detail;
|
|
1047
|
+
const activeWorkspace = await this.engineRef.getActiveWorkspace();
|
|
1048
|
+
activeWorkspace.isPublic = isPublic;
|
|
1049
|
+
await this.engineRef.updateWorkspace(activeWorkspace);
|
|
1050
|
+
this.activeWorkspace = activeWorkspace.clone();
|
|
1051
|
+
this.isPublicChange.emit({ isPublic, workspaceId: activeWorkspace.id });
|
|
1052
|
+
};
|
|
1053
|
+
/**
|
|
1054
|
+
* Updates the currentIsPublic state from the active workspace and emits the isPublicChange event.
|
|
1055
|
+
*/
|
|
1056
|
+
updateCurrentIsPublic() {
|
|
1057
|
+
const isPublic = this.activeWorkspace?.isPublic ?? false;
|
|
1058
|
+
const workspaceId = this.activeWorkspace?.id;
|
|
1059
|
+
this.currentIsPublic = isPublic;
|
|
1060
|
+
if (!workspaceId) {
|
|
1061
|
+
return;
|
|
1062
|
+
}
|
|
1063
|
+
this.isPublicChange.emit({ isPublic, workspaceId });
|
|
1064
|
+
}
|
|
1065
|
+
handleProviderLogin = (event) => {
|
|
1066
|
+
this.login.emit(event.detail);
|
|
1067
|
+
};
|
|
1068
|
+
handleCurrentUserLogout = () => {
|
|
1069
|
+
this.logout.emit();
|
|
1070
|
+
};
|
|
1071
|
+
get isLoggedIn() {
|
|
1072
|
+
return !!this.user && !this.user.isGuest;
|
|
1073
|
+
}
|
|
1074
|
+
canExportObjectsAs(objects, format) {
|
|
1075
|
+
if (!objects || objects.length !== 1) {
|
|
1076
|
+
return false;
|
|
1077
|
+
}
|
|
1078
|
+
const [selected] = objects;
|
|
1079
|
+
if (!ObjectHelper.isKritzelExportable(selected)) {
|
|
1080
|
+
return false;
|
|
1081
|
+
}
|
|
1082
|
+
return selected.getSupportedExportFormats().includes(format);
|
|
1083
|
+
}
|
|
1084
|
+
canExportObjects(objects) {
|
|
1085
|
+
return this.canExportObjectsAs(objects, 'png') || this.canExportObjectsAs(objects, 'svg');
|
|
1086
|
+
}
|
|
1087
|
+
getPreferredExportFormat(objects) {
|
|
1088
|
+
if (this.canExportObjectsAs(objects, 'png')) {
|
|
1089
|
+
return 'png';
|
|
1090
|
+
}
|
|
1091
|
+
if (this.canExportObjectsAs(objects, 'svg')) {
|
|
1092
|
+
return 'svg';
|
|
1093
|
+
}
|
|
1094
|
+
return null;
|
|
1095
|
+
}
|
|
1096
|
+
getSettingsStorageKey() {
|
|
1097
|
+
return this.editorId ? `kritzel-settings-${this.editorId}` : 'kritzel-settings';
|
|
1098
|
+
}
|
|
1099
|
+
loadSettingsFromStorage() {
|
|
1100
|
+
const stored = localStorage.getItem(this.getSettingsStorageKey());
|
|
1101
|
+
if (stored) {
|
|
1102
|
+
try {
|
|
1103
|
+
const parsed = JSON.parse(stored);
|
|
1104
|
+
if (typeof parsed.scaleMin === 'number') {
|
|
1105
|
+
this.scaleMin = parsed.scaleMin;
|
|
1106
|
+
}
|
|
1107
|
+
if (typeof parsed.scaleMax === 'number') {
|
|
1108
|
+
this.scaleMax = parsed.scaleMax;
|
|
1109
|
+
}
|
|
1110
|
+
if (typeof parsed.lockDrawingScale === 'boolean') {
|
|
1111
|
+
this.lockDrawingScale = parsed.lockDrawingScale;
|
|
1112
|
+
}
|
|
1113
|
+
if (typeof parsed.theme === 'string') {
|
|
1114
|
+
this.theme = parsed.theme;
|
|
1115
|
+
}
|
|
1116
|
+
if (typeof parsed.locale === 'string') {
|
|
1117
|
+
this.locale = parsed.locale;
|
|
1118
|
+
}
|
|
1119
|
+
if (typeof parsed.viewportBoundaryLeft === 'number') {
|
|
1120
|
+
this.viewportBoundaryLeft = parsed.viewportBoundaryLeft;
|
|
1121
|
+
}
|
|
1122
|
+
if (typeof parsed.viewportBoundaryRight === 'number') {
|
|
1123
|
+
this.viewportBoundaryRight = parsed.viewportBoundaryRight;
|
|
1124
|
+
}
|
|
1125
|
+
if (typeof parsed.viewportBoundaryTop === 'number') {
|
|
1126
|
+
this.viewportBoundaryTop = parsed.viewportBoundaryTop;
|
|
1127
|
+
}
|
|
1128
|
+
if (typeof parsed.viewportBoundaryBottom === 'number') {
|
|
1129
|
+
this.viewportBoundaryBottom = parsed.viewportBoundaryBottom;
|
|
1130
|
+
}
|
|
1131
|
+
if (parsed.debugInfo) {
|
|
1132
|
+
this.debugInfo = { ...this.debugInfo, ...parsed.debugInfo };
|
|
1133
|
+
}
|
|
1134
|
+
}
|
|
1135
|
+
catch {
|
|
1136
|
+
// Invalid JSON, use prop defaults
|
|
1137
|
+
}
|
|
1138
|
+
}
|
|
1139
|
+
}
|
|
1140
|
+
async loadShortcuts() {
|
|
1141
|
+
this.shortcuts = await this.engineRef.getDisplayableShortcuts();
|
|
1142
|
+
}
|
|
1143
|
+
get currentSettingsConfig() {
|
|
1144
|
+
return {
|
|
1145
|
+
scaleMin: this.scaleMin,
|
|
1146
|
+
scaleMax: this.scaleMax,
|
|
1147
|
+
lockDrawingScale: this.lockDrawingScale,
|
|
1148
|
+
theme: this.theme,
|
|
1149
|
+
locale: this.locale,
|
|
1150
|
+
viewportBoundaryLeft: this.viewportBoundaryLeft,
|
|
1151
|
+
viewportBoundaryRight: this.viewportBoundaryRight,
|
|
1152
|
+
viewportBoundaryTop: this.viewportBoundaryTop,
|
|
1153
|
+
viewportBoundaryBottom: this.viewportBoundaryBottom,
|
|
1154
|
+
debugInfo: this.debugInfo,
|
|
1155
|
+
};
|
|
1156
|
+
}
|
|
1157
|
+
getContentObjects(objects) {
|
|
1158
|
+
return objects.filter(obj => !(obj instanceof KritzelSelectionGroup) && !(obj instanceof KritzelSelectionBox));
|
|
1159
|
+
}
|
|
1160
|
+
registerCustomSvgIcons() {
|
|
1161
|
+
for (const [name, svg] of Object.entries(this.customSvgIcons)) {
|
|
1162
|
+
KritzelIconRegistry.register(name, svg);
|
|
1163
|
+
}
|
|
1164
|
+
}
|
|
1165
|
+
async registerCustomFonts(fonts = this.customFonts) {
|
|
1166
|
+
KritzelFontRegistry.registerFonts(fonts);
|
|
1167
|
+
const currentVersion = ++this.customFontsLoadVersion;
|
|
1168
|
+
const loadPromise = KritzelFontRegistry.waitForFonts(fonts);
|
|
1169
|
+
this.customFontsReady = loadPromise;
|
|
1170
|
+
await loadPromise;
|
|
1171
|
+
if (currentVersion !== this.customFontsLoadVersion) {
|
|
1172
|
+
await this.waitForCustomFontsReady();
|
|
1173
|
+
}
|
|
1174
|
+
}
|
|
1175
|
+
async waitForCustomFontsReady() {
|
|
1176
|
+
while (true) {
|
|
1177
|
+
const version = this.customFontsLoadVersion;
|
|
1178
|
+
await this.customFontsReady;
|
|
1179
|
+
if (version === this.customFontsLoadVersion) {
|
|
1180
|
+
return;
|
|
1181
|
+
}
|
|
1182
|
+
}
|
|
1183
|
+
}
|
|
1184
|
+
listenForMobileKeyboard() {
|
|
1185
|
+
KritzelKeyboardHelper.onKeyboardVisibleChanged(isOpen => {
|
|
1186
|
+
this.isVirtualKeyboardOpen = isOpen;
|
|
1187
|
+
});
|
|
1188
|
+
}
|
|
1189
|
+
setOsSpecificCssVariables() {
|
|
1190
|
+
const os = KritzelDevicesHelper.detectOS();
|
|
1191
|
+
switch (os) {
|
|
1192
|
+
case 'iOS':
|
|
1193
|
+
// iOS specific adjustments
|
|
1194
|
+
this.host.style.setProperty('--kritzel-editor-top-left-buttons-top', '14px');
|
|
1195
|
+
this.host.style.setProperty('--kritzel-editor-top-left-buttons-left', '14px');
|
|
1196
|
+
this.host.style.setProperty('--kritzel-editor-toolbar-bottom', '14px');
|
|
1197
|
+
this.host.style.setProperty('--kritzel-editor-toolbar-transition', 'cubic-bezier(0.25, 0.1, 0.25, 1.0)');
|
|
1198
|
+
this.host.style.setProperty('--kritzel-editor-toolbar-transform', 'translateY(200%)');
|
|
1199
|
+
this.host.style.setProperty('--kritzel-editor-toolbar-transition-duration', '0.25s');
|
|
1200
|
+
break;
|
|
1201
|
+
case 'Android':
|
|
1202
|
+
// Android specific adjustments
|
|
1203
|
+
this.host.style.setProperty('--kritzel-editor-top-left-buttons-top', '14px');
|
|
1204
|
+
this.host.style.setProperty('--kritzel-editor-top-left-buttons-left', '14px');
|
|
1205
|
+
this.host.style.setProperty('--kritzel-editor-toolbar-bottom', '24px');
|
|
1206
|
+
this.host.style.setProperty('--kritzel-editor-toolbar-transition', 'cubic-bezier(0.25, 0.1, 0.25, 1.0)');
|
|
1207
|
+
this.host.style.setProperty('--kritzel-editor-toolbar-transform', 'translateY(200%)');
|
|
1208
|
+
this.host.style.setProperty('--kritzel-editor-toolbar-transition-duration', '0.25s');
|
|
1209
|
+
break;
|
|
1210
|
+
default:
|
|
1211
|
+
// Default for Windows/Linux
|
|
1212
|
+
this.host.style.setProperty('--kritzel-editor-top-left-buttons-top', '14px');
|
|
1213
|
+
this.host.style.setProperty('--kritzel-editor-top-left-buttons-left', '14px');
|
|
1214
|
+
this.host.style.setProperty('--kritzel-editor-toolbar-bottom', '14px');
|
|
1215
|
+
break;
|
|
1216
|
+
}
|
|
1217
|
+
}
|
|
1218
|
+
render() {
|
|
1219
|
+
const isLoggedIn = this.isLoggedIn;
|
|
1220
|
+
const shouldShowCurrentUser = isLoggedIn;
|
|
1221
|
+
const shouldShowLoginButton = this.isReady && !!this.loginConfig && !isLoggedIn;
|
|
1222
|
+
const normalizedToolbarItems = this.getNormalizedToolbarItems();
|
|
1223
|
+
return (h(Host, { key: '34f8001fb3d6ac1f52a51aa57eef893a41fb1c8c' }, h("div", { key: '61ae20a731ee495361bdd9cb0ed334cde2b3af42', class: "editor-content", style: {
|
|
1224
|
+
opacity: this.isEditorVisible ? '1' : '0',
|
|
1225
|
+
visibility: this.isEditorVisible ? 'visible' : 'hidden',
|
|
1226
|
+
transition: 'opacity 0.2s ease-in-out, visibility 0.2s ease-in-out',
|
|
1227
|
+
} }, h("div", { key: '760c5f02ae80fba30fff328f307fa78e45531f13', class: "top-left-buttons" }, h("kritzel-workspace-manager", { key: '4daf1b5fbc6523c46ce3c0b4bec206f1905cf1b7', ref: el => {
|
|
1228
|
+
if (el) {
|
|
1229
|
+
this.workspaceManagerRef = el;
|
|
1230
|
+
}
|
|
1231
|
+
}, visible: this.isWorkspaceManagerVisible, workspaces: this.availableWorkspaces, activeWorkspace: this.activeWorkspace, terms: this.resolvedTerms, onWorkspaceChange: event => this.handleWorkspaceManagerChange(event), onIsWorkspaceManagerReady: () => (this.isWorkspaceManagerReady = true) }), h("kritzel-back-to-content", { key: '72e7649d13e3f03bcb7cd7c0507d1bd15e2f4cb3', visible: this.isBackToContentButtonVisible, text: this.resolvedTerms['backToContent.label'] ?? 'Back to content', onBackToContent: () => this.backToContent() })), this.activeNotification && (h("div", { key: '0651bba45fabb7342ea28e120bc930be5ee45de6', class: "top-center-notification-layer", role: "presentation" }, h("div", { key: 'b4b0bf29824b7cb025ef168a7c7be31d5054c0ff', class: { 'top-center-notification-container': true, 'is-dismissing': this.isNotificationDismissing }, role: "presentation" }, h("kritzel-notification-card", { key: '93c6f6b313a082f155eca9c60e623bcfbdd4119f', notification: this.activeNotification, locale: this.locale, onDismiss: this.dismissNotification, onHoverChange: event => this.handleNotificationHoverChange(event) })))), this.contextMenuState && this.contextMenuState.items.length > 0 && (h("kritzel-context-menu", { key: '0ad85b0ee5e85fffa081f88cdc991b3233ddd5ad', class: "context-menu", items: this.contextMenuState.items, objects: this.contextMenuState.objects, style: {
|
|
1232
|
+
position: 'absolute',
|
|
1233
|
+
left: `${this.contextMenuState.position.x}px`,
|
|
1234
|
+
top: `${this.contextMenuState.position.y}px`,
|
|
1235
|
+
zIndex: '10002',
|
|
1236
|
+
}, onActionSelected: event => this.handleContextMenuActionSelected(event), onClose: () => this.hideContextMenu() })), h("kritzel-loading-overlay", { key: 'bf4a9e25c3f78633831bcfdaf580a45171b67fff', visible: this.isLoadingOverlayVisible, text: this.resolvedTerms['editor.loading'] ?? 'Loading...' }), h("kritzel-engine", { key: '46bdfb77cddd106b7c6e8f7767520a331608592f', ref: el => {
|
|
1237
|
+
if (el) {
|
|
1238
|
+
this.engineRef = el;
|
|
1239
|
+
}
|
|
1240
|
+
}, workspaces: this.workspaces, activeWorkspaceId: this.activeWorkspaceId, editorId: this.editorId, syncConfig: this.syncConfig, assetStorageConfig: this.assetStorageConfig, user: this.user, scaleMax: this.scaleMax, lockDrawingScale: this.lockDrawingScale, scaleMin: this.scaleMin, cursorTarget: this.cursorTarget, viewportBoundaryLeft: this.viewportBoundaryLeft, viewportBoundaryRight: this.viewportBoundaryRight, viewportBoundaryTop: this.viewportBoundaryTop, viewportBoundaryBottom: this.viewportBoundaryBottom, isPanningEnabled: this.isPanningEnabled, isZoomingEnabled: this.isZoomingEnabled, theme: this.theme, themes: this.themes, licenseKey: this.licenseKey, locale: this.locale, locales: this.locales, fallbackLocale: this.fallbackLocale, debugInfo: this.debugInfo, globalContextMenuItems: this.globalContextMenuItems, objectContextMenuItems: this.objectContextMenuItems, onIsEngineReady: event => this.onEngineReady(event), onWorkspacesChange: event => this.handleWorkspacesChange(event), onActiveWorkspaceChange: event => this.handleActiveWorkspaceChange(event), onObjectsChange: event => this.handleObjectsChange(event), onObjectsAdded: event => this.handleObjectsAdded(event), onObjectsRemoved: event => this.handleObjectsRemoved(event), onObjectsUpdated: event => this.handleObjectsUpdated(event), onObjectsSelectionChange: event => this.handleObjectsSelectionChange(event), onUndoStateChange: event => this.handleUndoStateChange(event), onObjectsInViewportChange: event => this.handleObjectsInViewportChange(event), onViewportChange: event => this.handleViewportChange(event), onAwarenessChange: event => this.handleAwarenessChange(event), onNotificationsChange: event => this.handleNotificationsChange(event), onContextMenuStateChange: event => this.handleContextMenuStateChange(event), onIsLoadingChange: event => this.handleIsLoadingChange(event) }), h("kritzel-toolbar", { key: 'f19449a3b6aa08c51eb58ba53a37e133a6d1d1d5', visible: this.isToolbarVisible, class: { 'keyboard-open': this.isVirtualKeyboardOpen }, ref: el => {
|
|
1241
|
+
if (el) {
|
|
1242
|
+
this.toolbarRef = el;
|
|
1243
|
+
}
|
|
1244
|
+
}, toolbarItems: normalizedToolbarItems, isUtilityPanelVisible: this.isUtilityPanelVisible, undoState: this.undoState ?? undefined, theme: this.theme, terms: this.resolvedTerms, onIsToolbarReady: () => (this.isToolbarReady = true) }), h("div", { key: '3d7b417b286f9e003137d02a7520ef1d9b5563f2', class: "bottom-left-buttons" }, h("kritzel-zoom-panel", { key: '1d366c23cb68e5e345a8cb8833cdc61c9a0c607b', visible: this.isZoomPanelVisible, zoomPercent: this.currentZoomPercent, terms: this.resolvedTerms, onZoomIn: () => this.zoomIn(), onZoomOut: () => this.zoomOut() })), h("div", { key: '1c27cd556dea88b7dcf1fb6960157cff37210260', class: "top-right-buttons" }, h("kritzel-settings", { key: '61be74fbd336e64236a618bc40c5a68c9e4ba2a9', ref: el => {
|
|
1245
|
+
if (el) {
|
|
1246
|
+
this.settingsRef = el;
|
|
1247
|
+
}
|
|
1248
|
+
}, shortcuts: this.shortcuts, availableThemes: this.themes && this.themes.length > 0 ? this.themes.map(t => t.name) : ['light', 'dark'], availableLocales: this.availableLocaleOptions, settings: this.currentSettingsConfig, terms: this.resolvedTerms, onSettingsChange: event => this.handleSettingsChange(event) }), h("kritzel-export", { key: '4e84be18db6d1c1982bd6420d034f80876b22651', ref: el => {
|
|
1249
|
+
if (el) {
|
|
1250
|
+
this.exportRef = el;
|
|
1251
|
+
}
|
|
1252
|
+
}, workspaceName: this.activeWorkspace?.name || 'workspace', terms: this.resolvedTerms, onExportPng: () => this.engineRef.exportViewportAsPng(), onExportSvg: () => this.engineRef.exportViewportAsSvg(), onExportJson: event => this.engineRef.downloadAsJson(event.detail) }), h("kritzel-active-users", { key: 'a5c1b3de7e67ecddbac0a581a00585f796cd3dc3', users: this.activeUsers }), shouldShowCurrentUser && h("kritzel-current-user", { key: 'ff5f5668cb662f7275f714b3bad7ae7baff89eb4', user: this.user, terms: this.resolvedTerms, onClick: () => this.currentUserDialogRef?.open() }), shouldShowCurrentUser && (h("kritzel-current-user-dialog", { key: '18139a2382c60adec64fcb093e05904d3f37a639', ref: el => {
|
|
1253
|
+
if (el) {
|
|
1254
|
+
this.currentUserDialogRef = el;
|
|
1255
|
+
}
|
|
1256
|
+
}, user: this.user, terms: this.resolvedTerms, onLogoutRequest: this.handleCurrentUserLogout })), shouldShowLoginButton && h("kritzel-button", { key: 'c1d72827c6416efda9ba1f5576390135c8161665', onButtonClick: () => this.loginDialogRef?.open() }, this.resolvedTerms['login.dialogTitle'] ?? 'Sign in'), h("kritzel-more-menu", { key: '6cf3f77fd2a1c5f9e04e3cf415e775dd60e94927', ref: el => {
|
|
1257
|
+
if (el) {
|
|
1258
|
+
this.moreMenuRef = el;
|
|
1259
|
+
}
|
|
1260
|
+
}, items: this.resolvedMoreMenuItems, visible: this.isMoreMenuVisible, terms: this.resolvedTerms }), h("kritzel-share-dialog", { key: '60de09f78488162b0739f0494cc52706ba0df58d', ref: el => {
|
|
1261
|
+
if (el) {
|
|
1262
|
+
this.shareDialogRef = el;
|
|
1263
|
+
}
|
|
1264
|
+
}, isPublic: this.currentIsPublic, workspaceId: this.activeWorkspace?.id, terms: this.resolvedTerms, onToggleIsPublic: this.handleToggleIsPublic }), this.loginConfig && (h("kritzel-login-dialog", { key: 'ab05733b8c6985f3b3a3d327c4effd58e57b0a8f', ref: el => {
|
|
1265
|
+
if (el) {
|
|
1266
|
+
this.loginDialogRef = el;
|
|
1267
|
+
}
|
|
1268
|
+
}, providers: this.loginConfig.providers, dialogTitle: this.loginConfig.title ?? this.resolvedTerms['login.dialogTitle'] ?? 'Sign in', subtitle: this.loginConfig.subtitle, onProviderLogin: this.handleProviderLogin }))))));
|
|
1269
|
+
}
|
|
1270
|
+
static get is() { return "kritzel-editor"; }
|
|
1271
|
+
static get originalStyleUrls() {
|
|
1272
|
+
return {
|
|
1273
|
+
"$": ["kritzel-editor.css"]
|
|
1274
|
+
};
|
|
1275
|
+
}
|
|
1276
|
+
static get styleUrls() {
|
|
1277
|
+
return {
|
|
1278
|
+
"$": ["kritzel-editor.css"]
|
|
1279
|
+
};
|
|
1280
|
+
}
|
|
1281
|
+
static get properties() {
|
|
1282
|
+
return {
|
|
1283
|
+
"scaleMax": {
|
|
1284
|
+
"type": "number",
|
|
1285
|
+
"mutable": true,
|
|
1286
|
+
"complexType": {
|
|
1287
|
+
"original": "number",
|
|
1288
|
+
"resolved": "number",
|
|
1289
|
+
"references": {}
|
|
1290
|
+
},
|
|
1291
|
+
"required": false,
|
|
1292
|
+
"optional": false,
|
|
1293
|
+
"docs": {
|
|
1294
|
+
"tags": [],
|
|
1295
|
+
"text": ""
|
|
1296
|
+
},
|
|
1297
|
+
"getter": false,
|
|
1298
|
+
"setter": false,
|
|
1299
|
+
"reflect": false,
|
|
1300
|
+
"attribute": "scale-max",
|
|
1301
|
+
"defaultValue": "1000"
|
|
1302
|
+
},
|
|
1303
|
+
"scaleMin": {
|
|
1304
|
+
"type": "number",
|
|
1305
|
+
"mutable": true,
|
|
1306
|
+
"complexType": {
|
|
1307
|
+
"original": "number",
|
|
1308
|
+
"resolved": "number",
|
|
1309
|
+
"references": {}
|
|
1310
|
+
},
|
|
1311
|
+
"required": false,
|
|
1312
|
+
"optional": false,
|
|
1313
|
+
"docs": {
|
|
1314
|
+
"tags": [],
|
|
1315
|
+
"text": ""
|
|
1316
|
+
},
|
|
1317
|
+
"getter": false,
|
|
1318
|
+
"setter": false,
|
|
1319
|
+
"reflect": false,
|
|
1320
|
+
"attribute": "scale-min",
|
|
1321
|
+
"defaultValue": "0.0001"
|
|
1322
|
+
},
|
|
1323
|
+
"lockDrawingScale": {
|
|
1324
|
+
"type": "boolean",
|
|
1325
|
+
"mutable": true,
|
|
1326
|
+
"complexType": {
|
|
1327
|
+
"original": "boolean",
|
|
1328
|
+
"resolved": "boolean",
|
|
1329
|
+
"references": {}
|
|
1330
|
+
},
|
|
1331
|
+
"required": false,
|
|
1332
|
+
"optional": false,
|
|
1333
|
+
"docs": {
|
|
1334
|
+
"tags": [],
|
|
1335
|
+
"text": ""
|
|
1336
|
+
},
|
|
1337
|
+
"getter": false,
|
|
1338
|
+
"setter": false,
|
|
1339
|
+
"reflect": false,
|
|
1340
|
+
"attribute": "lock-drawing-scale",
|
|
1341
|
+
"defaultValue": "true"
|
|
1342
|
+
},
|
|
1343
|
+
"viewportBoundaryLeft": {
|
|
1344
|
+
"type": "number",
|
|
1345
|
+
"mutable": true,
|
|
1346
|
+
"complexType": {
|
|
1347
|
+
"original": "number",
|
|
1348
|
+
"resolved": "number",
|
|
1349
|
+
"references": {}
|
|
1350
|
+
},
|
|
1351
|
+
"required": false,
|
|
1352
|
+
"optional": false,
|
|
1353
|
+
"docs": {
|
|
1354
|
+
"tags": [],
|
|
1355
|
+
"text": ""
|
|
1356
|
+
},
|
|
1357
|
+
"getter": false,
|
|
1358
|
+
"setter": false,
|
|
1359
|
+
"reflect": false,
|
|
1360
|
+
"attribute": "viewport-boundary-left",
|
|
1361
|
+
"defaultValue": "-Infinity"
|
|
1362
|
+
},
|
|
1363
|
+
"viewportBoundaryRight": {
|
|
1364
|
+
"type": "number",
|
|
1365
|
+
"mutable": true,
|
|
1366
|
+
"complexType": {
|
|
1367
|
+
"original": "number",
|
|
1368
|
+
"resolved": "number",
|
|
1369
|
+
"references": {}
|
|
1370
|
+
},
|
|
1371
|
+
"required": false,
|
|
1372
|
+
"optional": false,
|
|
1373
|
+
"docs": {
|
|
1374
|
+
"tags": [],
|
|
1375
|
+
"text": ""
|
|
1376
|
+
},
|
|
1377
|
+
"getter": false,
|
|
1378
|
+
"setter": false,
|
|
1379
|
+
"reflect": false,
|
|
1380
|
+
"attribute": "viewport-boundary-right",
|
|
1381
|
+
"defaultValue": "Infinity"
|
|
1382
|
+
},
|
|
1383
|
+
"viewportBoundaryTop": {
|
|
1384
|
+
"type": "number",
|
|
1385
|
+
"mutable": true,
|
|
1386
|
+
"complexType": {
|
|
1387
|
+
"original": "number",
|
|
1388
|
+
"resolved": "number",
|
|
1389
|
+
"references": {}
|
|
1390
|
+
},
|
|
1391
|
+
"required": false,
|
|
1392
|
+
"optional": false,
|
|
1393
|
+
"docs": {
|
|
1394
|
+
"tags": [],
|
|
1395
|
+
"text": ""
|
|
1396
|
+
},
|
|
1397
|
+
"getter": false,
|
|
1398
|
+
"setter": false,
|
|
1399
|
+
"reflect": false,
|
|
1400
|
+
"attribute": "viewport-boundary-top",
|
|
1401
|
+
"defaultValue": "-Infinity"
|
|
1402
|
+
},
|
|
1403
|
+
"viewportBoundaryBottom": {
|
|
1404
|
+
"type": "number",
|
|
1405
|
+
"mutable": true,
|
|
1406
|
+
"complexType": {
|
|
1407
|
+
"original": "number",
|
|
1408
|
+
"resolved": "number",
|
|
1409
|
+
"references": {}
|
|
1410
|
+
},
|
|
1411
|
+
"required": false,
|
|
1412
|
+
"optional": false,
|
|
1413
|
+
"docs": {
|
|
1414
|
+
"tags": [],
|
|
1415
|
+
"text": ""
|
|
1416
|
+
},
|
|
1417
|
+
"getter": false,
|
|
1418
|
+
"setter": false,
|
|
1419
|
+
"reflect": false,
|
|
1420
|
+
"attribute": "viewport-boundary-bottom",
|
|
1421
|
+
"defaultValue": "Infinity"
|
|
1422
|
+
},
|
|
1423
|
+
"debugInfo": {
|
|
1424
|
+
"type": "unknown",
|
|
1425
|
+
"mutable": true,
|
|
1426
|
+
"complexType": {
|
|
1427
|
+
"original": "KritzelDebugInfo",
|
|
1428
|
+
"resolved": "KritzelDebugInfo",
|
|
1429
|
+
"references": {
|
|
1430
|
+
"KritzelDebugInfo": {
|
|
1431
|
+
"location": "import",
|
|
1432
|
+
"path": "@kritzel/engine",
|
|
1433
|
+
"id": "../../engine/core/dist/types/index.d.ts::KritzelDebugInfo",
|
|
1434
|
+
"referenceLocation": "KritzelDebugInfo"
|
|
1435
|
+
}
|
|
1436
|
+
}
|
|
1437
|
+
},
|
|
1438
|
+
"required": false,
|
|
1439
|
+
"optional": false,
|
|
1440
|
+
"docs": {
|
|
1441
|
+
"tags": [],
|
|
1442
|
+
"text": ""
|
|
1443
|
+
},
|
|
1444
|
+
"getter": false,
|
|
1445
|
+
"setter": false,
|
|
1446
|
+
"defaultValue": "{\r\n showViewportInfo: false,\r\n showObjectInfo: false,\r\n showSyncProviderInfo: true,\r\n showMigrationInfo: true,\r\n showAssetResolverInfo: false,\r\n }"
|
|
1447
|
+
},
|
|
1448
|
+
"user": {
|
|
1449
|
+
"type": "unknown",
|
|
1450
|
+
"mutable": false,
|
|
1451
|
+
"complexType": {
|
|
1452
|
+
"original": "IKritzelUser",
|
|
1453
|
+
"resolved": "IKritzelUser",
|
|
1454
|
+
"references": {
|
|
1455
|
+
"IKritzelUser": {
|
|
1456
|
+
"location": "import",
|
|
1457
|
+
"path": "@kritzel/engine",
|
|
1458
|
+
"id": "../../engine/core/dist/types/index.d.ts::IKritzelUser",
|
|
1459
|
+
"referenceLocation": "IKritzelUser"
|
|
1460
|
+
}
|
|
1461
|
+
}
|
|
1462
|
+
},
|
|
1463
|
+
"required": false,
|
|
1464
|
+
"optional": true,
|
|
1465
|
+
"docs": {
|
|
1466
|
+
"tags": [],
|
|
1467
|
+
"text": ""
|
|
1468
|
+
},
|
|
1469
|
+
"getter": false,
|
|
1470
|
+
"setter": false
|
|
1471
|
+
},
|
|
1472
|
+
"activeUsers": {
|
|
1473
|
+
"type": "unknown",
|
|
1474
|
+
"mutable": false,
|
|
1475
|
+
"complexType": {
|
|
1476
|
+
"original": "IKritzelUser[]",
|
|
1477
|
+
"resolved": "IKritzelUser[]",
|
|
1478
|
+
"references": {
|
|
1479
|
+
"IKritzelUser": {
|
|
1480
|
+
"location": "import",
|
|
1481
|
+
"path": "@kritzel/engine",
|
|
1482
|
+
"id": "../../engine/core/dist/types/index.d.ts::IKritzelUser",
|
|
1483
|
+
"referenceLocation": "IKritzelUser"
|
|
1484
|
+
}
|
|
1485
|
+
}
|
|
1486
|
+
},
|
|
1487
|
+
"required": false,
|
|
1488
|
+
"optional": true,
|
|
1489
|
+
"docs": {
|
|
1490
|
+
"tags": [],
|
|
1491
|
+
"text": ""
|
|
1492
|
+
},
|
|
1493
|
+
"getter": false,
|
|
1494
|
+
"setter": false
|
|
1495
|
+
},
|
|
1496
|
+
"toolbarItems": {
|
|
1497
|
+
"type": "unknown",
|
|
1498
|
+
"mutable": false,
|
|
1499
|
+
"complexType": {
|
|
1500
|
+
"original": "KritzelToolbarItem[]",
|
|
1501
|
+
"resolved": "KritzelToolbarItem[]",
|
|
1502
|
+
"references": {
|
|
1503
|
+
"KritzelToolbarItem": {
|
|
1504
|
+
"location": "import",
|
|
1505
|
+
"path": "@kritzel/engine",
|
|
1506
|
+
"id": "../../engine/core/dist/types/index.d.ts::KritzelToolbarItem",
|
|
1507
|
+
"referenceLocation": "KritzelToolbarItem"
|
|
1508
|
+
}
|
|
1509
|
+
}
|
|
1510
|
+
},
|
|
1511
|
+
"required": false,
|
|
1512
|
+
"optional": false,
|
|
1513
|
+
"docs": {
|
|
1514
|
+
"tags": [],
|
|
1515
|
+
"text": ""
|
|
1516
|
+
},
|
|
1517
|
+
"getter": false,
|
|
1518
|
+
"setter": false,
|
|
1519
|
+
"defaultValue": "[\r\n {\r\n name: 'selection',\r\n type: 'tool',\r\n isDefault: true,\r\n tool: KritzelSelectionTool,\r\n icon: 'cursor',\r\n },\r\n {\r\n name: 'brush',\r\n type: 'tool',\r\n tool: KritzelBrushTool,\r\n icon: 'pen',\r\n config: DEFAULT_BRUSH_CONFIG,\r\n },\r\n {\r\n name: 'eraser',\r\n type: 'tool',\r\n tool: KritzelEraserTool,\r\n icon: 'eraser',\r\n },\r\n {\r\n name: 'line',\r\n type: 'tool',\r\n tool: KritzelLineTool,\r\n icon: 'arrow',\r\n config: DEFAULT_LINE_TOOL_CONFIG,\r\n },\r\n {\r\n name: 'shape',\r\n type: 'tool',\r\n tool: KritzelShapeTool,\r\n icon: 'shape-rectangle',\r\n config: DEFAULT_SHAPE_CONFIG,\r\n subOptions: [\r\n { id: 'rectangle', icon: 'shape-rectangle', label: 'Rectangle', value: ShapeType.Rectangle, toolProperty: 'shapeType' },\r\n { id: 'ellipse', icon: 'shape-ellipse', label: 'Ellipse', value: ShapeType.Ellipse, toolProperty: 'shapeType' },\r\n { id: 'triangle', icon: 'shape-triangle', label: 'Triangle', value: ShapeType.Triangle, toolProperty: 'shapeType' },\r\n ],\r\n },\r\n {\r\n name: 'text',\r\n type: 'tool',\r\n tool: KritzelTextTool,\r\n icon: 'type',\r\n config: DEFAULT_TEXT_CONFIG,\r\n },\r\n {\r\n name: 'image',\r\n type: 'tool',\r\n tool: KritzelImageTool,\r\n icon: 'image',\r\n },\r\n {\r\n name: 'config',\r\n type: 'config',\r\n },\r\n ]"
|
|
1520
|
+
},
|
|
1521
|
+
"globalContextMenuItems": {
|
|
1522
|
+
"type": "unknown",
|
|
1523
|
+
"mutable": false,
|
|
1524
|
+
"complexType": {
|
|
1525
|
+
"original": "ContextMenuItem[]",
|
|
1526
|
+
"resolved": "ContextMenuItem[]",
|
|
1527
|
+
"references": {
|
|
1528
|
+
"ContextMenuItem": {
|
|
1529
|
+
"location": "import",
|
|
1530
|
+
"path": "@kritzel/engine",
|
|
1531
|
+
"id": "../../engine/core/dist/types/index.d.ts::ContextMenuItem",
|
|
1532
|
+
"referenceLocation": "ContextMenuItem"
|
|
1533
|
+
}
|
|
1534
|
+
}
|
|
1535
|
+
},
|
|
1536
|
+
"required": false,
|
|
1537
|
+
"optional": false,
|
|
1538
|
+
"docs": {
|
|
1539
|
+
"tags": [],
|
|
1540
|
+
"text": ""
|
|
1541
|
+
},
|
|
1542
|
+
"getter": false,
|
|
1543
|
+
"setter": false,
|
|
1544
|
+
"defaultValue": "[\r\n {\r\n label: 'menu.paste',\r\n icon: 'paste',\r\n action: menu => this.engineRef.paste(menu.x, menu.y),\r\n },\r\n {\r\n label: 'menu.selectAll',\r\n icon: 'select-all',\r\n action: () => this.selectAllObjectsInViewport(),\r\n },\r\n ]"
|
|
1545
|
+
},
|
|
1546
|
+
"objectContextMenuItems": {
|
|
1547
|
+
"type": "unknown",
|
|
1548
|
+
"mutable": false,
|
|
1549
|
+
"complexType": {
|
|
1550
|
+
"original": "ContextMenuItem[]",
|
|
1551
|
+
"resolved": "ContextMenuItem[]",
|
|
1552
|
+
"references": {
|
|
1553
|
+
"ContextMenuItem": {
|
|
1554
|
+
"location": "import",
|
|
1555
|
+
"path": "@kritzel/engine",
|
|
1556
|
+
"id": "../../engine/core/dist/types/index.d.ts::ContextMenuItem",
|
|
1557
|
+
"referenceLocation": "ContextMenuItem"
|
|
1558
|
+
}
|
|
1559
|
+
}
|
|
1560
|
+
},
|
|
1561
|
+
"required": false,
|
|
1562
|
+
"optional": false,
|
|
1563
|
+
"docs": {
|
|
1564
|
+
"tags": [],
|
|
1565
|
+
"text": ""
|
|
1566
|
+
},
|
|
1567
|
+
"getter": false,
|
|
1568
|
+
"setter": false,
|
|
1569
|
+
"defaultValue": "[\r\n { label: 'menu.copy', icon: 'copy', group: 'clipboard', action: () => this.engineRef.copy() },\r\n { label: 'menu.cut', icon: 'cut', group: 'clipboard', action: () => this.engineRef.cut() },\r\n {\r\n label: 'menu.paste',\r\n icon: 'paste',\r\n group: 'clipboard',\r\n action: (menu, _) => this.engineRef.paste(menu.x, menu.y),\r\n },\r\n {\r\n label: 'menu.export',\r\n icon: 'upload',\r\n group: 'clipboard',\r\n isVisible: (_, objects) => this.canExportObjects(objects),\r\n action: (_, objects) => {\r\n const format = this.getPreferredExportFormat(objects);\r\n if (!format) {\r\n return;\r\n }\r\n\r\n void this.engineRef.exportSelectedObject(format);\r\n },\r\n },\r\n {\r\n label: 'menu.order',\r\n icon: 'ordering',\r\n group: 'other',\r\n children: [\r\n { label: 'menu.bringToFront', icon: 'bring-to-front', action: () => this.engineRef.bringToFront() },\r\n { label: 'menu.sendToBack', icon: 'send-to-back', action: () => this.engineRef.sendToBack() },\r\n { label: 'menu.moveUp', icon: 'arrow-up-from-dot', action: () => this.engineRef.bringForward() },\r\n { label: 'menu.moveDown', icon: 'arrow-down-from-dot', action: () => this.engineRef.sendBackward() },\r\n ],\r\n },\r\n {\r\n label: 'menu.align',\r\n icon: 'align',\r\n group: 'other',\r\n children: [\r\n { label: 'menu.alignLeft', icon: 'align-start-vertical', action: () => this.engineRef.alignObjects(KritzelAlignment.StartHorizontal) },\r\n { label: 'menu.alignCenterHorizontal', icon: 'align-center-horizontal', action: () => this.engineRef.alignObjects(KritzelAlignment.CenterHorizontal) },\r\n { label: 'menu.alignRight', icon: 'align-end-vertical', action: () => this.engineRef.alignObjects(KritzelAlignment.EndHorizontal) },\r\n { label: 'menu.alignTop', icon: 'align-start-horizontal', action: () => this.engineRef.alignObjects(KritzelAlignment.StartVertical) },\r\n { label: 'menu.alignCenterVertical', icon: 'align-center-vertical', action: () => this.engineRef.alignObjects(KritzelAlignment.CenterVertical) },\r\n { label: 'menu.alignBottom', icon: 'align-end-horizontal', action: () => this.engineRef.alignObjects(KritzelAlignment.EndVertical) },\r\n ],\r\n },\r\n {\r\n label: 'menu.group',\r\n icon: 'group',\r\n group: 'other',\r\n children: [\r\n {\r\n label: 'menu.group',\r\n icon: 'group',\r\n action: () => this.engineRef.group(),\r\n },\r\n {\r\n label: 'menu.ungroup',\r\n icon: 'ungroup',\r\n action: () => this.engineRef.ungroup(),\r\n },\r\n ],\r\n },\r\n { label: 'menu.delete', icon: 'delete', group: 'edit', action: () => this.engineRef.delete() },\r\n ]"
|
|
1570
|
+
},
|
|
1571
|
+
"moreMenuItems": {
|
|
1572
|
+
"type": "unknown",
|
|
1573
|
+
"mutable": false,
|
|
1574
|
+
"complexType": {
|
|
1575
|
+
"original": "IKritzelMenuItem[]",
|
|
1576
|
+
"resolved": "IKritzelMenuItem<any>[]",
|
|
1577
|
+
"references": {
|
|
1578
|
+
"IKritzelMenuItem": {
|
|
1579
|
+
"location": "import",
|
|
1580
|
+
"path": "@kritzel/engine",
|
|
1581
|
+
"id": "../../engine/core/dist/types/index.d.ts::IKritzelMenuItem",
|
|
1582
|
+
"referenceLocation": "IKritzelMenuItem"
|
|
1583
|
+
}
|
|
1584
|
+
}
|
|
1585
|
+
},
|
|
1586
|
+
"required": false,
|
|
1587
|
+
"optional": true,
|
|
1588
|
+
"docs": {
|
|
1589
|
+
"tags": [],
|
|
1590
|
+
"text": ""
|
|
1591
|
+
},
|
|
1592
|
+
"getter": false,
|
|
1593
|
+
"setter": false,
|
|
1594
|
+
"defaultValue": "[\r\n {\r\n id: 'share',\r\n label: 'menu.share',\r\n icon: 'share',\r\n isVisible: async () => hasRemoteSyncProvider(this.syncConfig),\r\n action: () => {\r\n if (!this.isLoggedIn && this.loginConfig) {\r\n this.openLoginDialog();\r\n return;\r\n }\r\n this.shareDialogRef.open();\r\n },\r\n },\r\n {\r\n id: 'export',\r\n label: 'menu.export',\r\n icon: 'upload',\r\n action: async () => {\r\n const preview = await this.engineRef.getScreenshot('png');\r\n this.exportRef.open(preview ?? undefined);\r\n },\r\n },\r\n {\r\n id: 'import',\r\n label: 'menu.import',\r\n icon: 'download',\r\n action: () => this.engineRef.importFromFile(),\r\n },\r\n {\r\n id: 'settings',\r\n label: 'menu.settings',\r\n icon: 'settings',\r\n action: () => this.settingsRef.open(),\r\n },\r\n ]"
|
|
1595
|
+
},
|
|
1596
|
+
"themes": {
|
|
1597
|
+
"type": "unknown",
|
|
1598
|
+
"mutable": false,
|
|
1599
|
+
"complexType": {
|
|
1600
|
+
"original": "KritzelTheme[]",
|
|
1601
|
+
"resolved": "KritzelTheme[]",
|
|
1602
|
+
"references": {
|
|
1603
|
+
"KritzelTheme": {
|
|
1604
|
+
"location": "import",
|
|
1605
|
+
"path": "@kritzel/engine",
|
|
1606
|
+
"id": "../../engine/core/dist/types/index.d.ts::KritzelTheme",
|
|
1607
|
+
"referenceLocation": "KritzelTheme"
|
|
1608
|
+
}
|
|
1609
|
+
}
|
|
1610
|
+
},
|
|
1611
|
+
"required": false,
|
|
1612
|
+
"optional": true,
|
|
1613
|
+
"docs": {
|
|
1614
|
+
"tags": [],
|
|
1615
|
+
"text": ""
|
|
1616
|
+
},
|
|
1617
|
+
"getter": false,
|
|
1618
|
+
"setter": false
|
|
1619
|
+
},
|
|
1620
|
+
"theme": {
|
|
1621
|
+
"type": "string",
|
|
1622
|
+
"mutable": true,
|
|
1623
|
+
"complexType": {
|
|
1624
|
+
"original": "ThemeName",
|
|
1625
|
+
"resolved": "\"dark\" | \"light\" | string & {}",
|
|
1626
|
+
"references": {
|
|
1627
|
+
"ThemeName": {
|
|
1628
|
+
"location": "import",
|
|
1629
|
+
"path": "@kritzel/engine",
|
|
1630
|
+
"id": "../../engine/core/dist/types/index.d.ts::ThemeName",
|
|
1631
|
+
"referenceLocation": "ThemeName"
|
|
1632
|
+
}
|
|
1633
|
+
}
|
|
1634
|
+
},
|
|
1635
|
+
"required": false,
|
|
1636
|
+
"optional": false,
|
|
1637
|
+
"docs": {
|
|
1638
|
+
"tags": [],
|
|
1639
|
+
"text": ""
|
|
1640
|
+
},
|
|
1641
|
+
"getter": false,
|
|
1642
|
+
"setter": false,
|
|
1643
|
+
"reflect": false,
|
|
1644
|
+
"attribute": "theme",
|
|
1645
|
+
"defaultValue": "'light'"
|
|
1646
|
+
},
|
|
1647
|
+
"licenseKey": {
|
|
1648
|
+
"type": "string",
|
|
1649
|
+
"mutable": false,
|
|
1650
|
+
"complexType": {
|
|
1651
|
+
"original": "string",
|
|
1652
|
+
"resolved": "string",
|
|
1653
|
+
"references": {}
|
|
1654
|
+
},
|
|
1655
|
+
"required": false,
|
|
1656
|
+
"optional": true,
|
|
1657
|
+
"docs": {
|
|
1658
|
+
"tags": [],
|
|
1659
|
+
"text": "License key that, when valid, removes the \"Powered by Kritzel\" watermark."
|
|
1660
|
+
},
|
|
1661
|
+
"getter": false,
|
|
1662
|
+
"setter": false,
|
|
1663
|
+
"reflect": false,
|
|
1664
|
+
"attribute": "license-key"
|
|
1665
|
+
},
|
|
1666
|
+
"locale": {
|
|
1667
|
+
"type": "string",
|
|
1668
|
+
"mutable": true,
|
|
1669
|
+
"complexType": {
|
|
1670
|
+
"original": "LocaleCode",
|
|
1671
|
+
"resolved": "\"de\" | \"en\" | \"fr\" | string & {}",
|
|
1672
|
+
"references": {
|
|
1673
|
+
"LocaleCode": {
|
|
1674
|
+
"location": "import",
|
|
1675
|
+
"path": "@kritzel/engine",
|
|
1676
|
+
"id": "../../engine/core/dist/types/index.d.ts::LocaleCode",
|
|
1677
|
+
"referenceLocation": "LocaleCode"
|
|
1678
|
+
}
|
|
1679
|
+
}
|
|
1680
|
+
},
|
|
1681
|
+
"required": false,
|
|
1682
|
+
"optional": false,
|
|
1683
|
+
"docs": {
|
|
1684
|
+
"tags": [],
|
|
1685
|
+
"text": "The current locale (language) code applied to the editor, e.g. 'en', 'de', 'fr'."
|
|
1686
|
+
},
|
|
1687
|
+
"getter": false,
|
|
1688
|
+
"setter": false,
|
|
1689
|
+
"reflect": false,
|
|
1690
|
+
"attribute": "locale",
|
|
1691
|
+
"defaultValue": "'en'"
|
|
1692
|
+
},
|
|
1693
|
+
"locales": {
|
|
1694
|
+
"type": "unknown",
|
|
1695
|
+
"mutable": false,
|
|
1696
|
+
"complexType": {
|
|
1697
|
+
"original": "KritzelLocale[]",
|
|
1698
|
+
"resolved": "KritzelLocale[]",
|
|
1699
|
+
"references": {
|
|
1700
|
+
"KritzelLocale": {
|
|
1701
|
+
"location": "import",
|
|
1702
|
+
"path": "@kritzel/engine",
|
|
1703
|
+
"id": "../../engine/core/dist/types/index.d.ts::KritzelLocale",
|
|
1704
|
+
"referenceLocation": "KritzelLocale"
|
|
1705
|
+
}
|
|
1706
|
+
}
|
|
1707
|
+
},
|
|
1708
|
+
"required": false,
|
|
1709
|
+
"optional": true,
|
|
1710
|
+
"docs": {
|
|
1711
|
+
"tags": [],
|
|
1712
|
+
"text": "An array of available locale definitions (with optional partial term overrides)."
|
|
1713
|
+
},
|
|
1714
|
+
"getter": false,
|
|
1715
|
+
"setter": false
|
|
1716
|
+
},
|
|
1717
|
+
"fallbackLocale": {
|
|
1718
|
+
"type": "string",
|
|
1719
|
+
"mutable": false,
|
|
1720
|
+
"complexType": {
|
|
1721
|
+
"original": "LocaleCode",
|
|
1722
|
+
"resolved": "\"de\" | \"en\" | \"fr\" | string & {}",
|
|
1723
|
+
"references": {
|
|
1724
|
+
"LocaleCode": {
|
|
1725
|
+
"location": "import",
|
|
1726
|
+
"path": "@kritzel/engine",
|
|
1727
|
+
"id": "../../engine/core/dist/types/index.d.ts::LocaleCode",
|
|
1728
|
+
"referenceLocation": "LocaleCode"
|
|
1729
|
+
}
|
|
1730
|
+
}
|
|
1731
|
+
},
|
|
1732
|
+
"required": false,
|
|
1733
|
+
"optional": false,
|
|
1734
|
+
"docs": {
|
|
1735
|
+
"tags": [],
|
|
1736
|
+
"text": "The locale used to resolve terms missing from the active locale."
|
|
1737
|
+
},
|
|
1738
|
+
"getter": false,
|
|
1739
|
+
"setter": false,
|
|
1740
|
+
"reflect": false,
|
|
1741
|
+
"attribute": "fallback-locale",
|
|
1742
|
+
"defaultValue": "'en'"
|
|
1743
|
+
},
|
|
1744
|
+
"customSvgIcons": {
|
|
1745
|
+
"type": "unknown",
|
|
1746
|
+
"mutable": false,
|
|
1747
|
+
"complexType": {
|
|
1748
|
+
"original": "Record<string, string>",
|
|
1749
|
+
"resolved": "string",
|
|
1750
|
+
"references": {
|
|
1751
|
+
"Record": {
|
|
1752
|
+
"location": "global",
|
|
1753
|
+
"id": "global::Record"
|
|
1754
|
+
}
|
|
1755
|
+
}
|
|
1756
|
+
},
|
|
1757
|
+
"required": false,
|
|
1758
|
+
"optional": false,
|
|
1759
|
+
"docs": {
|
|
1760
|
+
"tags": [],
|
|
1761
|
+
"text": ""
|
|
1762
|
+
},
|
|
1763
|
+
"getter": false,
|
|
1764
|
+
"setter": false,
|
|
1765
|
+
"defaultValue": "{}"
|
|
1766
|
+
},
|
|
1767
|
+
"customFonts": {
|
|
1768
|
+
"type": "unknown",
|
|
1769
|
+
"mutable": false,
|
|
1770
|
+
"complexType": {
|
|
1771
|
+
"original": "KritzelFontMap",
|
|
1772
|
+
"resolved": "{ [x: string]: KritzelFontRegistration; }",
|
|
1773
|
+
"references": {
|
|
1774
|
+
"KritzelFontMap": {
|
|
1775
|
+
"location": "import",
|
|
1776
|
+
"path": "@kritzel/engine",
|
|
1777
|
+
"id": "../../engine/core/dist/types/index.d.ts::KritzelFontMap",
|
|
1778
|
+
"referenceLocation": "KritzelFontMap"
|
|
1779
|
+
}
|
|
1780
|
+
}
|
|
1781
|
+
},
|
|
1782
|
+
"required": false,
|
|
1783
|
+
"optional": false,
|
|
1784
|
+
"docs": {
|
|
1785
|
+
"tags": [],
|
|
1786
|
+
"text": "Registers fonts for runtime usage (for example custom object rendering).\r\nText-tool config tooltip options are controlled via toolbarItems[].config.availableFonts."
|
|
1787
|
+
},
|
|
1788
|
+
"getter": false,
|
|
1789
|
+
"setter": false,
|
|
1790
|
+
"defaultValue": "{}"
|
|
1791
|
+
},
|
|
1792
|
+
"isPanningEnabled": {
|
|
1793
|
+
"type": "boolean",
|
|
1794
|
+
"mutable": true,
|
|
1795
|
+
"complexType": {
|
|
1796
|
+
"original": "boolean",
|
|
1797
|
+
"resolved": "boolean",
|
|
1798
|
+
"references": {}
|
|
1799
|
+
},
|
|
1800
|
+
"required": false,
|
|
1801
|
+
"optional": false,
|
|
1802
|
+
"docs": {
|
|
1803
|
+
"tags": [],
|
|
1804
|
+
"text": ""
|
|
1805
|
+
},
|
|
1806
|
+
"getter": false,
|
|
1807
|
+
"setter": false,
|
|
1808
|
+
"reflect": false,
|
|
1809
|
+
"attribute": "is-panning-enabled",
|
|
1810
|
+
"defaultValue": "true"
|
|
1811
|
+
},
|
|
1812
|
+
"isZoomingEnabled": {
|
|
1813
|
+
"type": "boolean",
|
|
1814
|
+
"mutable": true,
|
|
1815
|
+
"complexType": {
|
|
1816
|
+
"original": "boolean",
|
|
1817
|
+
"resolved": "boolean",
|
|
1818
|
+
"references": {}
|
|
1819
|
+
},
|
|
1820
|
+
"required": false,
|
|
1821
|
+
"optional": false,
|
|
1822
|
+
"docs": {
|
|
1823
|
+
"tags": [],
|
|
1824
|
+
"text": ""
|
|
1825
|
+
},
|
|
1826
|
+
"getter": false,
|
|
1827
|
+
"setter": false,
|
|
1828
|
+
"reflect": false,
|
|
1829
|
+
"attribute": "is-zooming-enabled",
|
|
1830
|
+
"defaultValue": "true"
|
|
1831
|
+
},
|
|
1832
|
+
"isToolbarVisible": {
|
|
1833
|
+
"type": "boolean",
|
|
1834
|
+
"mutable": false,
|
|
1835
|
+
"complexType": {
|
|
1836
|
+
"original": "boolean",
|
|
1837
|
+
"resolved": "boolean",
|
|
1838
|
+
"references": {}
|
|
1839
|
+
},
|
|
1840
|
+
"required": false,
|
|
1841
|
+
"optional": false,
|
|
1842
|
+
"docs": {
|
|
1843
|
+
"tags": [],
|
|
1844
|
+
"text": ""
|
|
1845
|
+
},
|
|
1846
|
+
"getter": false,
|
|
1847
|
+
"setter": false,
|
|
1848
|
+
"reflect": false,
|
|
1849
|
+
"attribute": "is-toolbar-visible",
|
|
1850
|
+
"defaultValue": "true"
|
|
1851
|
+
},
|
|
1852
|
+
"isUtilityPanelVisible": {
|
|
1853
|
+
"type": "boolean",
|
|
1854
|
+
"mutable": false,
|
|
1855
|
+
"complexType": {
|
|
1856
|
+
"original": "boolean",
|
|
1857
|
+
"resolved": "boolean",
|
|
1858
|
+
"references": {}
|
|
1859
|
+
},
|
|
1860
|
+
"required": false,
|
|
1861
|
+
"optional": false,
|
|
1862
|
+
"docs": {
|
|
1863
|
+
"tags": [],
|
|
1864
|
+
"text": ""
|
|
1865
|
+
},
|
|
1866
|
+
"getter": false,
|
|
1867
|
+
"setter": false,
|
|
1868
|
+
"reflect": false,
|
|
1869
|
+
"attribute": "is-utility-panel-visible",
|
|
1870
|
+
"defaultValue": "true"
|
|
1871
|
+
},
|
|
1872
|
+
"isWorkspaceManagerVisible": {
|
|
1873
|
+
"type": "boolean",
|
|
1874
|
+
"mutable": false,
|
|
1875
|
+
"complexType": {
|
|
1876
|
+
"original": "boolean",
|
|
1877
|
+
"resolved": "boolean",
|
|
1878
|
+
"references": {}
|
|
1879
|
+
},
|
|
1880
|
+
"required": false,
|
|
1881
|
+
"optional": false,
|
|
1882
|
+
"docs": {
|
|
1883
|
+
"tags": [],
|
|
1884
|
+
"text": ""
|
|
1885
|
+
},
|
|
1886
|
+
"getter": false,
|
|
1887
|
+
"setter": false,
|
|
1888
|
+
"reflect": false,
|
|
1889
|
+
"attribute": "is-workspace-manager-visible",
|
|
1890
|
+
"defaultValue": "true"
|
|
1891
|
+
},
|
|
1892
|
+
"isMoreMenuVisible": {
|
|
1893
|
+
"type": "boolean",
|
|
1894
|
+
"mutable": false,
|
|
1895
|
+
"complexType": {
|
|
1896
|
+
"original": "boolean",
|
|
1897
|
+
"resolved": "boolean",
|
|
1898
|
+
"references": {}
|
|
1899
|
+
},
|
|
1900
|
+
"required": false,
|
|
1901
|
+
"optional": false,
|
|
1902
|
+
"docs": {
|
|
1903
|
+
"tags": [],
|
|
1904
|
+
"text": ""
|
|
1905
|
+
},
|
|
1906
|
+
"getter": false,
|
|
1907
|
+
"setter": false,
|
|
1908
|
+
"reflect": false,
|
|
1909
|
+
"attribute": "is-more-menu-visible",
|
|
1910
|
+
"defaultValue": "true"
|
|
1911
|
+
},
|
|
1912
|
+
"isZoomPanelVisible": {
|
|
1913
|
+
"type": "boolean",
|
|
1914
|
+
"mutable": false,
|
|
1915
|
+
"complexType": {
|
|
1916
|
+
"original": "boolean",
|
|
1917
|
+
"resolved": "boolean",
|
|
1918
|
+
"references": {}
|
|
1919
|
+
},
|
|
1920
|
+
"required": false,
|
|
1921
|
+
"optional": false,
|
|
1922
|
+
"docs": {
|
|
1923
|
+
"tags": [],
|
|
1924
|
+
"text": ""
|
|
1925
|
+
},
|
|
1926
|
+
"getter": false,
|
|
1927
|
+
"setter": false,
|
|
1928
|
+
"reflect": false,
|
|
1929
|
+
"attribute": "is-zoom-panel-visible",
|
|
1930
|
+
"defaultValue": "true"
|
|
1931
|
+
},
|
|
1932
|
+
"syncConfig": {
|
|
1933
|
+
"type": "unknown",
|
|
1934
|
+
"mutable": false,
|
|
1935
|
+
"complexType": {
|
|
1936
|
+
"original": "KritzelSyncConfig",
|
|
1937
|
+
"resolved": "KritzelSyncConfig",
|
|
1938
|
+
"references": {
|
|
1939
|
+
"KritzelSyncConfig": {
|
|
1940
|
+
"location": "import",
|
|
1941
|
+
"path": "@kritzel/engine",
|
|
1942
|
+
"id": "../../engine/core/dist/types/index.d.ts::KritzelSyncConfig",
|
|
1943
|
+
"referenceLocation": "KritzelSyncConfig"
|
|
1944
|
+
}
|
|
1945
|
+
}
|
|
1946
|
+
},
|
|
1947
|
+
"required": false,
|
|
1948
|
+
"optional": true,
|
|
1949
|
+
"docs": {
|
|
1950
|
+
"tags": [],
|
|
1951
|
+
"text": ""
|
|
1952
|
+
},
|
|
1953
|
+
"getter": false,
|
|
1954
|
+
"setter": false,
|
|
1955
|
+
"defaultValue": "DEFAULT_SYNC_CONFIG"
|
|
1956
|
+
},
|
|
1957
|
+
"assetStorageConfig": {
|
|
1958
|
+
"type": "unknown",
|
|
1959
|
+
"mutable": false,
|
|
1960
|
+
"complexType": {
|
|
1961
|
+
"original": "KritzelAssetStorageConfig",
|
|
1962
|
+
"resolved": "KritzelAssetStorageConfig",
|
|
1963
|
+
"references": {
|
|
1964
|
+
"KritzelAssetStorageConfig": {
|
|
1965
|
+
"location": "import",
|
|
1966
|
+
"path": "@kritzel/engine",
|
|
1967
|
+
"id": "../../engine/core/dist/types/index.d.ts::KritzelAssetStorageConfig",
|
|
1968
|
+
"referenceLocation": "KritzelAssetStorageConfig"
|
|
1969
|
+
}
|
|
1970
|
+
}
|
|
1971
|
+
},
|
|
1972
|
+
"required": false,
|
|
1973
|
+
"optional": true,
|
|
1974
|
+
"docs": {
|
|
1975
|
+
"tags": [],
|
|
1976
|
+
"text": ""
|
|
1977
|
+
},
|
|
1978
|
+
"getter": false,
|
|
1979
|
+
"setter": false,
|
|
1980
|
+
"defaultValue": "DEFAULT_ASSET_STORAGE_CONFIG"
|
|
1981
|
+
},
|
|
1982
|
+
"cursorTarget": {
|
|
1983
|
+
"type": "unknown",
|
|
1984
|
+
"mutable": false,
|
|
1985
|
+
"complexType": {
|
|
1986
|
+
"original": "HTMLElement",
|
|
1987
|
+
"resolved": "HTMLElement",
|
|
1988
|
+
"references": {
|
|
1989
|
+
"HTMLElement": {
|
|
1990
|
+
"location": "global",
|
|
1991
|
+
"id": "global::HTMLElement"
|
|
1992
|
+
}
|
|
1993
|
+
}
|
|
1994
|
+
},
|
|
1995
|
+
"required": false,
|
|
1996
|
+
"optional": true,
|
|
1997
|
+
"docs": {
|
|
1998
|
+
"tags": [],
|
|
1999
|
+
"text": "The element to use as the target for the cursor. Defaults to the editor container if not set."
|
|
2000
|
+
},
|
|
2001
|
+
"getter": false,
|
|
2002
|
+
"setter": false
|
|
2003
|
+
},
|
|
2004
|
+
"loginConfig": {
|
|
2005
|
+
"type": "unknown",
|
|
2006
|
+
"mutable": false,
|
|
2007
|
+
"complexType": {
|
|
2008
|
+
"original": "KritzelLoginConfig",
|
|
2009
|
+
"resolved": "KritzelLoginConfig",
|
|
2010
|
+
"references": {
|
|
2011
|
+
"KritzelLoginConfig": {
|
|
2012
|
+
"location": "import",
|
|
2013
|
+
"path": "@kritzel/engine",
|
|
2014
|
+
"id": "../../engine/core/dist/types/index.d.ts::KritzelLoginConfig",
|
|
2015
|
+
"referenceLocation": "KritzelLoginConfig"
|
|
2016
|
+
}
|
|
2017
|
+
}
|
|
2018
|
+
},
|
|
2019
|
+
"required": false,
|
|
2020
|
+
"optional": true,
|
|
2021
|
+
"docs": {
|
|
2022
|
+
"tags": [],
|
|
2023
|
+
"text": "Optional login configuration. When provided, a \"Sign in\" button is shown that opens a login dialog with the configured providers."
|
|
2024
|
+
},
|
|
2025
|
+
"getter": false,
|
|
2026
|
+
"setter": false
|
|
2027
|
+
},
|
|
2028
|
+
"editorId": {
|
|
2029
|
+
"type": "string",
|
|
2030
|
+
"mutable": false,
|
|
2031
|
+
"complexType": {
|
|
2032
|
+
"original": "string",
|
|
2033
|
+
"resolved": "string",
|
|
2034
|
+
"references": {}
|
|
2035
|
+
},
|
|
2036
|
+
"required": false,
|
|
2037
|
+
"optional": true,
|
|
2038
|
+
"docs": {
|
|
2039
|
+
"tags": [],
|
|
2040
|
+
"text": "Optional unique identifier for namespacing storage keys across multiple editor instances."
|
|
2041
|
+
},
|
|
2042
|
+
"getter": false,
|
|
2043
|
+
"setter": false,
|
|
2044
|
+
"reflect": false,
|
|
2045
|
+
"attribute": "editor-id"
|
|
2046
|
+
},
|
|
2047
|
+
"activeWorkspaceId": {
|
|
2048
|
+
"type": "string",
|
|
2049
|
+
"mutable": false,
|
|
2050
|
+
"complexType": {
|
|
2051
|
+
"original": "string",
|
|
2052
|
+
"resolved": "string",
|
|
2053
|
+
"references": {}
|
|
2054
|
+
},
|
|
2055
|
+
"required": false,
|
|
2056
|
+
"optional": true,
|
|
2057
|
+
"docs": {
|
|
2058
|
+
"tags": [],
|
|
2059
|
+
"text": "Optional workspace ID to set as active. If provided, the editor will automatically activate the workspace with this ID."
|
|
2060
|
+
},
|
|
2061
|
+
"getter": false,
|
|
2062
|
+
"setter": false,
|
|
2063
|
+
"reflect": false,
|
|
2064
|
+
"attribute": "active-workspace-id"
|
|
2065
|
+
},
|
|
2066
|
+
"workspaces": {
|
|
2067
|
+
"type": "unknown",
|
|
2068
|
+
"mutable": false,
|
|
2069
|
+
"complexType": {
|
|
2070
|
+
"original": "KritzelWorkspace[]",
|
|
2071
|
+
"resolved": "KritzelWorkspace[]",
|
|
2072
|
+
"references": {
|
|
2073
|
+
"KritzelWorkspace": {
|
|
2074
|
+
"location": "import",
|
|
2075
|
+
"path": "@kritzel/engine",
|
|
2076
|
+
"id": "../../engine/core/dist/types/classes/core/workspace.class.d.ts::KritzelWorkspace",
|
|
2077
|
+
"referenceLocation": "KritzelWorkspace"
|
|
2078
|
+
}
|
|
2079
|
+
}
|
|
2080
|
+
},
|
|
2081
|
+
"required": false,
|
|
2082
|
+
"optional": true,
|
|
2083
|
+
"docs": {
|
|
2084
|
+
"tags": [],
|
|
2085
|
+
"text": "Authoritative workspace catalog for this editor instance. When provided, provider-only workspaces are hidden but not deleted."
|
|
2086
|
+
},
|
|
2087
|
+
"getter": false,
|
|
2088
|
+
"setter": false
|
|
2089
|
+
}
|
|
2090
|
+
};
|
|
2091
|
+
}
|
|
2092
|
+
static get states() {
|
|
2093
|
+
return {
|
|
2094
|
+
"isEngineReady": {},
|
|
2095
|
+
"isToolbarReady": {},
|
|
2096
|
+
"isWorkspaceManagerReady": {},
|
|
2097
|
+
"availableWorkspaces": {},
|
|
2098
|
+
"activeWorkspace": {},
|
|
2099
|
+
"isVirtualKeyboardOpen": {},
|
|
2100
|
+
"undoState": {},
|
|
2101
|
+
"isBackToContentButtonVisible": {},
|
|
2102
|
+
"resolvedTerms": {},
|
|
2103
|
+
"availableLocaleOptions": {},
|
|
2104
|
+
"currentZoomPercent": {},
|
|
2105
|
+
"shortcuts": {},
|
|
2106
|
+
"currentIsPublic": {},
|
|
2107
|
+
"isEditorVisible": {},
|
|
2108
|
+
"activeNotification": {},
|
|
2109
|
+
"isNotificationDismissing": {},
|
|
2110
|
+
"contextMenuState": {},
|
|
2111
|
+
"resolvedMoreMenuItems": {},
|
|
2112
|
+
"isLoadingOverlayVisible": {}
|
|
2113
|
+
};
|
|
2114
|
+
}
|
|
2115
|
+
static get events() {
|
|
2116
|
+
return [{
|
|
2117
|
+
"method": "isReady",
|
|
2118
|
+
"name": "isReady",
|
|
2119
|
+
"bubbles": true,
|
|
2120
|
+
"cancelable": true,
|
|
2121
|
+
"composed": true,
|
|
2122
|
+
"docs": {
|
|
2123
|
+
"tags": [],
|
|
2124
|
+
"text": ""
|
|
2125
|
+
},
|
|
2126
|
+
"complexType": {
|
|
2127
|
+
"original": "EditorIsReadyEvent",
|
|
2128
|
+
"resolved": "EditorIsReadyEvent",
|
|
2129
|
+
"references": {
|
|
2130
|
+
"EditorIsReadyEvent": {
|
|
2131
|
+
"location": "import",
|
|
2132
|
+
"path": "@kritzel/engine",
|
|
2133
|
+
"id": "../../engine/core/dist/types/index.d.ts::EditorIsReadyEvent",
|
|
2134
|
+
"referenceLocation": "EditorIsReadyEvent"
|
|
2135
|
+
}
|
|
2136
|
+
}
|
|
2137
|
+
}
|
|
2138
|
+
}, {
|
|
2139
|
+
"method": "activeWorkspaceChange",
|
|
2140
|
+
"name": "activeWorkspaceChange",
|
|
2141
|
+
"bubbles": true,
|
|
2142
|
+
"cancelable": true,
|
|
2143
|
+
"composed": true,
|
|
2144
|
+
"docs": {
|
|
2145
|
+
"tags": [],
|
|
2146
|
+
"text": ""
|
|
2147
|
+
},
|
|
2148
|
+
"complexType": {
|
|
2149
|
+
"original": "ActiveWorkspaceChangeEvent",
|
|
2150
|
+
"resolved": "ActiveWorkspaceChangeEvent",
|
|
2151
|
+
"references": {
|
|
2152
|
+
"ActiveWorkspaceChangeEvent": {
|
|
2153
|
+
"location": "import",
|
|
2154
|
+
"path": "@kritzel/engine",
|
|
2155
|
+
"id": "../../engine/core/dist/types/index.d.ts::ActiveWorkspaceChangeEvent",
|
|
2156
|
+
"referenceLocation": "ActiveWorkspaceChangeEvent"
|
|
2157
|
+
}
|
|
2158
|
+
}
|
|
2159
|
+
}
|
|
2160
|
+
}, {
|
|
2161
|
+
"method": "objectsChange",
|
|
2162
|
+
"name": "objectsChange",
|
|
2163
|
+
"bubbles": true,
|
|
2164
|
+
"cancelable": true,
|
|
2165
|
+
"composed": true,
|
|
2166
|
+
"docs": {
|
|
2167
|
+
"tags": [],
|
|
2168
|
+
"text": ""
|
|
2169
|
+
},
|
|
2170
|
+
"complexType": {
|
|
2171
|
+
"original": "KritzelBaseObject[]",
|
|
2172
|
+
"resolved": "KritzelBaseObject<HTMLElement | SVGElement>[]",
|
|
2173
|
+
"references": {
|
|
2174
|
+
"KritzelBaseObject": {
|
|
2175
|
+
"location": "import",
|
|
2176
|
+
"path": "@kritzel/engine",
|
|
2177
|
+
"id": "../../engine/core/dist/types/classes/objects/base-object.class.d.ts::KritzelBaseObject",
|
|
2178
|
+
"referenceLocation": "KritzelBaseObject"
|
|
2179
|
+
}
|
|
2180
|
+
}
|
|
2181
|
+
}
|
|
2182
|
+
}, {
|
|
2183
|
+
"method": "objectsAdded",
|
|
2184
|
+
"name": "objectsAdded",
|
|
2185
|
+
"bubbles": true,
|
|
2186
|
+
"cancelable": true,
|
|
2187
|
+
"composed": true,
|
|
2188
|
+
"docs": {
|
|
2189
|
+
"tags": [],
|
|
2190
|
+
"text": ""
|
|
2191
|
+
},
|
|
2192
|
+
"complexType": {
|
|
2193
|
+
"original": "ObjectsAddedEvent",
|
|
2194
|
+
"resolved": "ObjectsAddedEvent",
|
|
2195
|
+
"references": {
|
|
2196
|
+
"ObjectsAddedEvent": {
|
|
2197
|
+
"location": "import",
|
|
2198
|
+
"path": "@kritzel/engine",
|
|
2199
|
+
"id": "../../engine/core/dist/types/index.d.ts::ObjectsAddedEvent",
|
|
2200
|
+
"referenceLocation": "ObjectsAddedEvent"
|
|
2201
|
+
}
|
|
2202
|
+
}
|
|
2203
|
+
}
|
|
2204
|
+
}, {
|
|
2205
|
+
"method": "objectsRemoved",
|
|
2206
|
+
"name": "objectsRemoved",
|
|
2207
|
+
"bubbles": true,
|
|
2208
|
+
"cancelable": true,
|
|
2209
|
+
"composed": true,
|
|
2210
|
+
"docs": {
|
|
2211
|
+
"tags": [],
|
|
2212
|
+
"text": ""
|
|
2213
|
+
},
|
|
2214
|
+
"complexType": {
|
|
2215
|
+
"original": "ObjectsRemovedEvent",
|
|
2216
|
+
"resolved": "ObjectsRemovedEvent",
|
|
2217
|
+
"references": {
|
|
2218
|
+
"ObjectsRemovedEvent": {
|
|
2219
|
+
"location": "import",
|
|
2220
|
+
"path": "@kritzel/engine",
|
|
2221
|
+
"id": "../../engine/core/dist/types/index.d.ts::ObjectsRemovedEvent",
|
|
2222
|
+
"referenceLocation": "ObjectsRemovedEvent"
|
|
2223
|
+
}
|
|
2224
|
+
}
|
|
2225
|
+
}
|
|
2226
|
+
}, {
|
|
2227
|
+
"method": "objectsUpdated",
|
|
2228
|
+
"name": "objectsUpdated",
|
|
2229
|
+
"bubbles": true,
|
|
2230
|
+
"cancelable": true,
|
|
2231
|
+
"composed": true,
|
|
2232
|
+
"docs": {
|
|
2233
|
+
"tags": [],
|
|
2234
|
+
"text": ""
|
|
2235
|
+
},
|
|
2236
|
+
"complexType": {
|
|
2237
|
+
"original": "ObjectsUpdatedEvent",
|
|
2238
|
+
"resolved": "ObjectsUpdatedEvent",
|
|
2239
|
+
"references": {
|
|
2240
|
+
"ObjectsUpdatedEvent": {
|
|
2241
|
+
"location": "import",
|
|
2242
|
+
"path": "@kritzel/engine",
|
|
2243
|
+
"id": "../../engine/core/dist/types/index.d.ts::ObjectsUpdatedEvent",
|
|
2244
|
+
"referenceLocation": "ObjectsUpdatedEvent"
|
|
2245
|
+
}
|
|
2246
|
+
}
|
|
2247
|
+
}
|
|
2248
|
+
}, {
|
|
2249
|
+
"method": "objectsSelectionChange",
|
|
2250
|
+
"name": "objectsSelectionChange",
|
|
2251
|
+
"bubbles": true,
|
|
2252
|
+
"cancelable": true,
|
|
2253
|
+
"composed": true,
|
|
2254
|
+
"docs": {
|
|
2255
|
+
"tags": [],
|
|
2256
|
+
"text": ""
|
|
2257
|
+
},
|
|
2258
|
+
"complexType": {
|
|
2259
|
+
"original": "KritzelBaseObject[]",
|
|
2260
|
+
"resolved": "KritzelBaseObject<HTMLElement | SVGElement>[]",
|
|
2261
|
+
"references": {
|
|
2262
|
+
"KritzelBaseObject": {
|
|
2263
|
+
"location": "import",
|
|
2264
|
+
"path": "@kritzel/engine",
|
|
2265
|
+
"id": "../../engine/core/dist/types/classes/objects/base-object.class.d.ts::KritzelBaseObject",
|
|
2266
|
+
"referenceLocation": "KritzelBaseObject"
|
|
2267
|
+
}
|
|
2268
|
+
}
|
|
2269
|
+
}
|
|
2270
|
+
}, {
|
|
2271
|
+
"method": "undoStateChange",
|
|
2272
|
+
"name": "undoStateChange",
|
|
2273
|
+
"bubbles": true,
|
|
2274
|
+
"cancelable": true,
|
|
2275
|
+
"composed": true,
|
|
2276
|
+
"docs": {
|
|
2277
|
+
"tags": [],
|
|
2278
|
+
"text": ""
|
|
2279
|
+
},
|
|
2280
|
+
"complexType": {
|
|
2281
|
+
"original": "KritzelUndoState",
|
|
2282
|
+
"resolved": "KritzelUndoState",
|
|
2283
|
+
"references": {
|
|
2284
|
+
"KritzelUndoState": {
|
|
2285
|
+
"location": "import",
|
|
2286
|
+
"path": "@kritzel/engine",
|
|
2287
|
+
"id": "../../engine/core/dist/types/index.d.ts::KritzelUndoState",
|
|
2288
|
+
"referenceLocation": "KritzelUndoState"
|
|
2289
|
+
}
|
|
2290
|
+
}
|
|
2291
|
+
}
|
|
2292
|
+
}, {
|
|
2293
|
+
"method": "themeChange",
|
|
2294
|
+
"name": "themeChange",
|
|
2295
|
+
"bubbles": true,
|
|
2296
|
+
"cancelable": true,
|
|
2297
|
+
"composed": true,
|
|
2298
|
+
"docs": {
|
|
2299
|
+
"tags": [],
|
|
2300
|
+
"text": ""
|
|
2301
|
+
},
|
|
2302
|
+
"complexType": {
|
|
2303
|
+
"original": "ThemeName",
|
|
2304
|
+
"resolved": "\"dark\" | \"light\" | string & {}",
|
|
2305
|
+
"references": {
|
|
2306
|
+
"ThemeName": {
|
|
2307
|
+
"location": "import",
|
|
2308
|
+
"path": "@kritzel/engine",
|
|
2309
|
+
"id": "../../engine/core/dist/types/index.d.ts::ThemeName",
|
|
2310
|
+
"referenceLocation": "ThemeName"
|
|
2311
|
+
}
|
|
2312
|
+
}
|
|
2313
|
+
}
|
|
2314
|
+
}, {
|
|
2315
|
+
"method": "localeChange",
|
|
2316
|
+
"name": "localeChange",
|
|
2317
|
+
"bubbles": true,
|
|
2318
|
+
"cancelable": true,
|
|
2319
|
+
"composed": true,
|
|
2320
|
+
"docs": {
|
|
2321
|
+
"tags": [],
|
|
2322
|
+
"text": ""
|
|
2323
|
+
},
|
|
2324
|
+
"complexType": {
|
|
2325
|
+
"original": "LocaleCode",
|
|
2326
|
+
"resolved": "\"de\" | \"en\" | \"fr\" | string & {}",
|
|
2327
|
+
"references": {
|
|
2328
|
+
"LocaleCode": {
|
|
2329
|
+
"location": "import",
|
|
2330
|
+
"path": "@kritzel/engine",
|
|
2331
|
+
"id": "../../engine/core/dist/types/index.d.ts::LocaleCode",
|
|
2332
|
+
"referenceLocation": "LocaleCode"
|
|
2333
|
+
}
|
|
2334
|
+
}
|
|
2335
|
+
}
|
|
2336
|
+
}, {
|
|
2337
|
+
"method": "viewportChange",
|
|
2338
|
+
"name": "viewportChange",
|
|
2339
|
+
"bubbles": true,
|
|
2340
|
+
"cancelable": true,
|
|
2341
|
+
"composed": true,
|
|
2342
|
+
"docs": {
|
|
2343
|
+
"tags": [],
|
|
2344
|
+
"text": ""
|
|
2345
|
+
},
|
|
2346
|
+
"complexType": {
|
|
2347
|
+
"original": "KritzelViewportState",
|
|
2348
|
+
"resolved": "KritzelViewportState",
|
|
2349
|
+
"references": {
|
|
2350
|
+
"KritzelViewportState": {
|
|
2351
|
+
"location": "import",
|
|
2352
|
+
"path": "@kritzel/engine",
|
|
2353
|
+
"id": "../../engine/core/dist/types/index.d.ts::KritzelViewportState",
|
|
2354
|
+
"referenceLocation": "KritzelViewportState"
|
|
2355
|
+
}
|
|
2356
|
+
}
|
|
2357
|
+
}
|
|
2358
|
+
}, {
|
|
2359
|
+
"method": "logout",
|
|
2360
|
+
"name": "logout",
|
|
2361
|
+
"bubbles": true,
|
|
2362
|
+
"cancelable": true,
|
|
2363
|
+
"composed": true,
|
|
2364
|
+
"docs": {
|
|
2365
|
+
"tags": [],
|
|
2366
|
+
"text": ""
|
|
2367
|
+
},
|
|
2368
|
+
"complexType": {
|
|
2369
|
+
"original": "void",
|
|
2370
|
+
"resolved": "void",
|
|
2371
|
+
"references": {}
|
|
2372
|
+
}
|
|
2373
|
+
}, {
|
|
2374
|
+
"method": "login",
|
|
2375
|
+
"name": "login",
|
|
2376
|
+
"bubbles": true,
|
|
2377
|
+
"cancelable": true,
|
|
2378
|
+
"composed": true,
|
|
2379
|
+
"docs": {
|
|
2380
|
+
"tags": [],
|
|
2381
|
+
"text": ""
|
|
2382
|
+
},
|
|
2383
|
+
"complexType": {
|
|
2384
|
+
"original": "LoginEvent",
|
|
2385
|
+
"resolved": "LoginEvent",
|
|
2386
|
+
"references": {
|
|
2387
|
+
"LoginEvent": {
|
|
2388
|
+
"location": "import",
|
|
2389
|
+
"path": "@kritzel/engine",
|
|
2390
|
+
"id": "../../engine/core/dist/types/index.d.ts::LoginEvent",
|
|
2391
|
+
"referenceLocation": "LoginEvent"
|
|
2392
|
+
}
|
|
2393
|
+
}
|
|
2394
|
+
}
|
|
2395
|
+
}, {
|
|
2396
|
+
"method": "isPublicChange",
|
|
2397
|
+
"name": "isPublicChange",
|
|
2398
|
+
"bubbles": true,
|
|
2399
|
+
"cancelable": true,
|
|
2400
|
+
"composed": true,
|
|
2401
|
+
"docs": {
|
|
2402
|
+
"tags": [],
|
|
2403
|
+
"text": ""
|
|
2404
|
+
},
|
|
2405
|
+
"complexType": {
|
|
2406
|
+
"original": "IKritzelIsPublicChangeEvent",
|
|
2407
|
+
"resolved": "IKritzelIsPublicChangeEvent",
|
|
2408
|
+
"references": {
|
|
2409
|
+
"IKritzelIsPublicChangeEvent": {
|
|
2410
|
+
"location": "import",
|
|
2411
|
+
"path": "@kritzel/engine",
|
|
2412
|
+
"id": "../../engine/core/dist/types/index.d.ts::IKritzelIsPublicChangeEvent",
|
|
2413
|
+
"referenceLocation": "IKritzelIsPublicChangeEvent"
|
|
2414
|
+
}
|
|
2415
|
+
}
|
|
2416
|
+
}
|
|
2417
|
+
}, {
|
|
2418
|
+
"method": "awarenessChange",
|
|
2419
|
+
"name": "awarenessChange",
|
|
2420
|
+
"bubbles": true,
|
|
2421
|
+
"cancelable": true,
|
|
2422
|
+
"composed": true,
|
|
2423
|
+
"docs": {
|
|
2424
|
+
"tags": [],
|
|
2425
|
+
"text": ""
|
|
2426
|
+
},
|
|
2427
|
+
"complexType": {
|
|
2428
|
+
"original": "Map<number, Record<string, any>>",
|
|
2429
|
+
"resolved": "Map<number, Record<string, any>>",
|
|
2430
|
+
"references": {
|
|
2431
|
+
"Map": {
|
|
2432
|
+
"location": "global",
|
|
2433
|
+
"id": "global::Map"
|
|
2434
|
+
},
|
|
2435
|
+
"Record": {
|
|
2436
|
+
"location": "global",
|
|
2437
|
+
"id": "global::Record"
|
|
2438
|
+
}
|
|
2439
|
+
}
|
|
2440
|
+
}
|
|
2441
|
+
}];
|
|
2442
|
+
}
|
|
2443
|
+
static get methods() {
|
|
2444
|
+
return {
|
|
2445
|
+
"getObjectById": {
|
|
2446
|
+
"complexType": {
|
|
2447
|
+
"signature": "<T extends KritzelBaseObject>(id: string) => Promise<T | null>",
|
|
2448
|
+
"parameters": [{
|
|
2449
|
+
"name": "id",
|
|
2450
|
+
"type": "string",
|
|
2451
|
+
"docs": ""
|
|
2452
|
+
}],
|
|
2453
|
+
"references": {
|
|
2454
|
+
"Promise": {
|
|
2455
|
+
"location": "global",
|
|
2456
|
+
"id": "global::Promise"
|
|
2457
|
+
},
|
|
2458
|
+
"T": {
|
|
2459
|
+
"location": "global",
|
|
2460
|
+
"id": "global::T"
|
|
2461
|
+
},
|
|
2462
|
+
"KritzelBaseObject": {
|
|
2463
|
+
"location": "import",
|
|
2464
|
+
"path": "@kritzel/engine",
|
|
2465
|
+
"id": "../../engine/core/dist/types/classes/objects/base-object.class.d.ts::KritzelBaseObject",
|
|
2466
|
+
"referenceLocation": "KritzelBaseObject"
|
|
2467
|
+
}
|
|
2468
|
+
},
|
|
2469
|
+
"return": "Promise<T>"
|
|
2470
|
+
},
|
|
2471
|
+
"docs": {
|
|
2472
|
+
"text": "",
|
|
2473
|
+
"tags": []
|
|
2474
|
+
}
|
|
2475
|
+
},
|
|
2476
|
+
"addObject": {
|
|
2477
|
+
"complexType": {
|
|
2478
|
+
"signature": "<T extends KritzelBaseObject>(object: T) => Promise<T | null>",
|
|
2479
|
+
"parameters": [{
|
|
2480
|
+
"name": "object",
|
|
2481
|
+
"type": "T",
|
|
2482
|
+
"docs": ""
|
|
2483
|
+
}],
|
|
2484
|
+
"references": {
|
|
2485
|
+
"Promise": {
|
|
2486
|
+
"location": "global",
|
|
2487
|
+
"id": "global::Promise"
|
|
2488
|
+
},
|
|
2489
|
+
"T": {
|
|
2490
|
+
"location": "global",
|
|
2491
|
+
"id": "global::T"
|
|
2492
|
+
},
|
|
2493
|
+
"KritzelBaseObject": {
|
|
2494
|
+
"location": "import",
|
|
2495
|
+
"path": "@kritzel/engine",
|
|
2496
|
+
"id": "../../engine/core/dist/types/classes/objects/base-object.class.d.ts::KritzelBaseObject",
|
|
2497
|
+
"referenceLocation": "KritzelBaseObject"
|
|
2498
|
+
}
|
|
2499
|
+
},
|
|
2500
|
+
"return": "Promise<T>"
|
|
2501
|
+
},
|
|
2502
|
+
"docs": {
|
|
2503
|
+
"text": "",
|
|
2504
|
+
"tags": []
|
|
2505
|
+
}
|
|
2506
|
+
},
|
|
2507
|
+
"addObjects": {
|
|
2508
|
+
"complexType": {
|
|
2509
|
+
"signature": "<T extends KritzelBaseObject>(objects: T[]) => Promise<T[]>",
|
|
2510
|
+
"parameters": [{
|
|
2511
|
+
"name": "objects",
|
|
2512
|
+
"type": "T[]",
|
|
2513
|
+
"docs": ""
|
|
2514
|
+
}],
|
|
2515
|
+
"references": {
|
|
2516
|
+
"Promise": {
|
|
2517
|
+
"location": "global",
|
|
2518
|
+
"id": "global::Promise"
|
|
2519
|
+
},
|
|
2520
|
+
"T": {
|
|
2521
|
+
"location": "global",
|
|
2522
|
+
"id": "global::T"
|
|
2523
|
+
},
|
|
2524
|
+
"KritzelBaseObject": {
|
|
2525
|
+
"location": "import",
|
|
2526
|
+
"path": "@kritzel/engine",
|
|
2527
|
+
"id": "../../engine/core/dist/types/classes/objects/base-object.class.d.ts::KritzelBaseObject",
|
|
2528
|
+
"referenceLocation": "KritzelBaseObject"
|
|
2529
|
+
}
|
|
2530
|
+
},
|
|
2531
|
+
"return": "Promise<T[]>"
|
|
2532
|
+
},
|
|
2533
|
+
"docs": {
|
|
2534
|
+
"text": "",
|
|
2535
|
+
"tags": []
|
|
2536
|
+
}
|
|
2537
|
+
},
|
|
2538
|
+
"updateObject": {
|
|
2539
|
+
"complexType": {
|
|
2540
|
+
"signature": "<T extends KritzelBaseObject>(object: T, updatedProperties: Partial<T>) => Promise<T | null>",
|
|
2541
|
+
"parameters": [{
|
|
2542
|
+
"name": "object",
|
|
2543
|
+
"type": "T",
|
|
2544
|
+
"docs": ""
|
|
2545
|
+
}, {
|
|
2546
|
+
"name": "updatedProperties",
|
|
2547
|
+
"type": "{ [P in keyof T]?: T[P]; }",
|
|
2548
|
+
"docs": ""
|
|
2549
|
+
}],
|
|
2550
|
+
"references": {
|
|
2551
|
+
"Promise": {
|
|
2552
|
+
"location": "global",
|
|
2553
|
+
"id": "global::Promise"
|
|
2554
|
+
},
|
|
2555
|
+
"T": {
|
|
2556
|
+
"location": "global",
|
|
2557
|
+
"id": "global::T"
|
|
2558
|
+
},
|
|
2559
|
+
"KritzelBaseObject": {
|
|
2560
|
+
"location": "import",
|
|
2561
|
+
"path": "@kritzel/engine",
|
|
2562
|
+
"id": "../../engine/core/dist/types/classes/objects/base-object.class.d.ts::KritzelBaseObject",
|
|
2563
|
+
"referenceLocation": "KritzelBaseObject"
|
|
2564
|
+
},
|
|
2565
|
+
"Partial": {
|
|
2566
|
+
"location": "global",
|
|
2567
|
+
"id": "global::Partial"
|
|
2568
|
+
}
|
|
2569
|
+
},
|
|
2570
|
+
"return": "Promise<T>"
|
|
2571
|
+
},
|
|
2572
|
+
"docs": {
|
|
2573
|
+
"text": "",
|
|
2574
|
+
"tags": []
|
|
2575
|
+
}
|
|
2576
|
+
},
|
|
2577
|
+
"removeObject": {
|
|
2578
|
+
"complexType": {
|
|
2579
|
+
"signature": "<T extends KritzelBaseObject>(object: T) => Promise<T | null>",
|
|
2580
|
+
"parameters": [{
|
|
2581
|
+
"name": "object",
|
|
2582
|
+
"type": "T",
|
|
2583
|
+
"docs": ""
|
|
2584
|
+
}],
|
|
2585
|
+
"references": {
|
|
2586
|
+
"Promise": {
|
|
2587
|
+
"location": "global",
|
|
2588
|
+
"id": "global::Promise"
|
|
2589
|
+
},
|
|
2590
|
+
"T": {
|
|
2591
|
+
"location": "global",
|
|
2592
|
+
"id": "global::T"
|
|
2593
|
+
},
|
|
2594
|
+
"KritzelBaseObject": {
|
|
2595
|
+
"location": "import",
|
|
2596
|
+
"path": "@kritzel/engine",
|
|
2597
|
+
"id": "../../engine/core/dist/types/classes/objects/base-object.class.d.ts::KritzelBaseObject",
|
|
2598
|
+
"referenceLocation": "KritzelBaseObject"
|
|
2599
|
+
}
|
|
2600
|
+
},
|
|
2601
|
+
"return": "Promise<T>"
|
|
2602
|
+
},
|
|
2603
|
+
"docs": {
|
|
2604
|
+
"text": "",
|
|
2605
|
+
"tags": []
|
|
2606
|
+
}
|
|
2607
|
+
},
|
|
2608
|
+
"removeObjects": {
|
|
2609
|
+
"complexType": {
|
|
2610
|
+
"signature": "<T extends KritzelBaseObject>(objects: T[]) => Promise<T[]>",
|
|
2611
|
+
"parameters": [{
|
|
2612
|
+
"name": "objects",
|
|
2613
|
+
"type": "T[]",
|
|
2614
|
+
"docs": ""
|
|
2615
|
+
}],
|
|
2616
|
+
"references": {
|
|
2617
|
+
"Promise": {
|
|
2618
|
+
"location": "global",
|
|
2619
|
+
"id": "global::Promise"
|
|
2620
|
+
},
|
|
2621
|
+
"T": {
|
|
2622
|
+
"location": "global",
|
|
2623
|
+
"id": "global::T"
|
|
2624
|
+
},
|
|
2625
|
+
"KritzelBaseObject": {
|
|
2626
|
+
"location": "import",
|
|
2627
|
+
"path": "@kritzel/engine",
|
|
2628
|
+
"id": "../../engine/core/dist/types/classes/objects/base-object.class.d.ts::KritzelBaseObject",
|
|
2629
|
+
"referenceLocation": "KritzelBaseObject"
|
|
2630
|
+
}
|
|
2631
|
+
},
|
|
2632
|
+
"return": "Promise<T[]>"
|
|
2633
|
+
},
|
|
2634
|
+
"docs": {
|
|
2635
|
+
"text": "",
|
|
2636
|
+
"tags": []
|
|
2637
|
+
}
|
|
2638
|
+
},
|
|
2639
|
+
"getSelectedObjects": {
|
|
2640
|
+
"complexType": {
|
|
2641
|
+
"signature": "() => Promise<KritzelBaseObject[]>",
|
|
2642
|
+
"parameters": [],
|
|
2643
|
+
"references": {
|
|
2644
|
+
"Promise": {
|
|
2645
|
+
"location": "global",
|
|
2646
|
+
"id": "global::Promise"
|
|
2647
|
+
},
|
|
2648
|
+
"KritzelBaseObject": {
|
|
2649
|
+
"location": "import",
|
|
2650
|
+
"path": "@kritzel/engine",
|
|
2651
|
+
"id": "../../engine/core/dist/types/classes/objects/base-object.class.d.ts::KritzelBaseObject",
|
|
2652
|
+
"referenceLocation": "KritzelBaseObject"
|
|
2653
|
+
},
|
|
2654
|
+
"HTMLElement": {
|
|
2655
|
+
"location": "global",
|
|
2656
|
+
"id": "global::HTMLElement"
|
|
2657
|
+
},
|
|
2658
|
+
"SVGElement": {
|
|
2659
|
+
"location": "global",
|
|
2660
|
+
"id": "global::SVGElement"
|
|
2661
|
+
}
|
|
2662
|
+
},
|
|
2663
|
+
"return": "Promise<KritzelBaseObject<HTMLElement | SVGElement>[]>"
|
|
2664
|
+
},
|
|
2665
|
+
"docs": {
|
|
2666
|
+
"text": "",
|
|
2667
|
+
"tags": []
|
|
2668
|
+
}
|
|
2669
|
+
},
|
|
2670
|
+
"selectObjects": {
|
|
2671
|
+
"complexType": {
|
|
2672
|
+
"signature": "(objects: KritzelBaseObject[]) => Promise<void>",
|
|
2673
|
+
"parameters": [{
|
|
2674
|
+
"name": "objects",
|
|
2675
|
+
"type": "KritzelBaseObject<HTMLElement | SVGElement>[]",
|
|
2676
|
+
"docs": ""
|
|
2677
|
+
}],
|
|
2678
|
+
"references": {
|
|
2679
|
+
"Promise": {
|
|
2680
|
+
"location": "global",
|
|
2681
|
+
"id": "global::Promise"
|
|
2682
|
+
},
|
|
2683
|
+
"KritzelBaseObject": {
|
|
2684
|
+
"location": "import",
|
|
2685
|
+
"path": "@kritzel/engine",
|
|
2686
|
+
"id": "../../engine/core/dist/types/classes/objects/base-object.class.d.ts::KritzelBaseObject",
|
|
2687
|
+
"referenceLocation": "KritzelBaseObject"
|
|
2688
|
+
}
|
|
2689
|
+
},
|
|
2690
|
+
"return": "Promise<void>"
|
|
2691
|
+
},
|
|
2692
|
+
"docs": {
|
|
2693
|
+
"text": "",
|
|
2694
|
+
"tags": []
|
|
2695
|
+
}
|
|
2696
|
+
},
|
|
2697
|
+
"selectAllObjectsInViewport": {
|
|
2698
|
+
"complexType": {
|
|
2699
|
+
"signature": "() => Promise<void>",
|
|
2700
|
+
"parameters": [],
|
|
2701
|
+
"references": {
|
|
2702
|
+
"Promise": {
|
|
2703
|
+
"location": "global",
|
|
2704
|
+
"id": "global::Promise"
|
|
2705
|
+
}
|
|
2706
|
+
},
|
|
2707
|
+
"return": "Promise<void>"
|
|
2708
|
+
},
|
|
2709
|
+
"docs": {
|
|
2710
|
+
"text": "",
|
|
2711
|
+
"tags": []
|
|
2712
|
+
}
|
|
2713
|
+
},
|
|
2714
|
+
"clearSelection": {
|
|
2715
|
+
"complexType": {
|
|
2716
|
+
"signature": "() => Promise<void>",
|
|
2717
|
+
"parameters": [],
|
|
2718
|
+
"references": {
|
|
2719
|
+
"Promise": {
|
|
2720
|
+
"location": "global",
|
|
2721
|
+
"id": "global::Promise"
|
|
2722
|
+
}
|
|
2723
|
+
},
|
|
2724
|
+
"return": "Promise<void>"
|
|
2725
|
+
},
|
|
2726
|
+
"docs": {
|
|
2727
|
+
"text": "",
|
|
2728
|
+
"tags": []
|
|
2729
|
+
}
|
|
2730
|
+
},
|
|
2731
|
+
"centerObjectInViewport": {
|
|
2732
|
+
"complexType": {
|
|
2733
|
+
"signature": "(object: KritzelBaseObject) => Promise<KritzelBaseObject<HTMLElement | SVGElement>>",
|
|
2734
|
+
"parameters": [{
|
|
2735
|
+
"name": "object",
|
|
2736
|
+
"type": "KritzelBaseObject<HTMLElement | SVGElement>",
|
|
2737
|
+
"docs": ""
|
|
2738
|
+
}],
|
|
2739
|
+
"references": {
|
|
2740
|
+
"Promise": {
|
|
2741
|
+
"location": "global",
|
|
2742
|
+
"id": "global::Promise"
|
|
2743
|
+
},
|
|
2744
|
+
"KritzelBaseObject": {
|
|
2745
|
+
"location": "import",
|
|
2746
|
+
"path": "@kritzel/engine",
|
|
2747
|
+
"id": "../../engine/core/dist/types/classes/objects/base-object.class.d.ts::KritzelBaseObject",
|
|
2748
|
+
"referenceLocation": "KritzelBaseObject"
|
|
2749
|
+
},
|
|
2750
|
+
"HTMLElement": {
|
|
2751
|
+
"location": "global",
|
|
2752
|
+
"id": "global::HTMLElement"
|
|
2753
|
+
},
|
|
2754
|
+
"SVGElement": {
|
|
2755
|
+
"location": "global",
|
|
2756
|
+
"id": "global::SVGElement"
|
|
2757
|
+
}
|
|
2758
|
+
},
|
|
2759
|
+
"return": "Promise<KritzelBaseObject<HTMLElement | SVGElement>>"
|
|
2760
|
+
},
|
|
2761
|
+
"docs": {
|
|
2762
|
+
"text": "",
|
|
2763
|
+
"tags": []
|
|
2764
|
+
}
|
|
2765
|
+
},
|
|
2766
|
+
"panToObject": {
|
|
2767
|
+
"complexType": {
|
|
2768
|
+
"signature": "(object: KritzelBaseObject) => Promise<void>",
|
|
2769
|
+
"parameters": [{
|
|
2770
|
+
"name": "object",
|
|
2771
|
+
"type": "KritzelBaseObject<HTMLElement | SVGElement>",
|
|
2772
|
+
"docs": ""
|
|
2773
|
+
}],
|
|
2774
|
+
"references": {
|
|
2775
|
+
"Promise": {
|
|
2776
|
+
"location": "global",
|
|
2777
|
+
"id": "global::Promise"
|
|
2778
|
+
},
|
|
2779
|
+
"KritzelBaseObject": {
|
|
2780
|
+
"location": "import",
|
|
2781
|
+
"path": "@kritzel/engine",
|
|
2782
|
+
"id": "../../engine/core/dist/types/classes/objects/base-object.class.d.ts::KritzelBaseObject",
|
|
2783
|
+
"referenceLocation": "KritzelBaseObject"
|
|
2784
|
+
}
|
|
2785
|
+
},
|
|
2786
|
+
"return": "Promise<void>"
|
|
2787
|
+
},
|
|
2788
|
+
"docs": {
|
|
2789
|
+
"text": "",
|
|
2790
|
+
"tags": []
|
|
2791
|
+
}
|
|
2792
|
+
},
|
|
2793
|
+
"backToContent": {
|
|
2794
|
+
"complexType": {
|
|
2795
|
+
"signature": "() => Promise<boolean>",
|
|
2796
|
+
"parameters": [],
|
|
2797
|
+
"references": {
|
|
2798
|
+
"Promise": {
|
|
2799
|
+
"location": "global",
|
|
2800
|
+
"id": "global::Promise"
|
|
2801
|
+
}
|
|
2802
|
+
},
|
|
2803
|
+
"return": "Promise<boolean>"
|
|
2804
|
+
},
|
|
2805
|
+
"docs": {
|
|
2806
|
+
"text": "",
|
|
2807
|
+
"tags": []
|
|
2808
|
+
}
|
|
2809
|
+
},
|
|
2810
|
+
"centerAllObjects": {
|
|
2811
|
+
"complexType": {
|
|
2812
|
+
"signature": "(animate?: boolean) => Promise<boolean>",
|
|
2813
|
+
"parameters": [{
|
|
2814
|
+
"name": "animate",
|
|
2815
|
+
"type": "boolean",
|
|
2816
|
+
"docs": ""
|
|
2817
|
+
}],
|
|
2818
|
+
"references": {
|
|
2819
|
+
"Promise": {
|
|
2820
|
+
"location": "global",
|
|
2821
|
+
"id": "global::Promise"
|
|
2822
|
+
}
|
|
2823
|
+
},
|
|
2824
|
+
"return": "Promise<boolean>"
|
|
2825
|
+
},
|
|
2826
|
+
"docs": {
|
|
2827
|
+
"text": "",
|
|
2828
|
+
"tags": []
|
|
2829
|
+
}
|
|
2830
|
+
},
|
|
2831
|
+
"centerObjects": {
|
|
2832
|
+
"complexType": {
|
|
2833
|
+
"signature": "(objects: KritzelBaseObject[], animate?: boolean) => Promise<boolean>",
|
|
2834
|
+
"parameters": [{
|
|
2835
|
+
"name": "objects",
|
|
2836
|
+
"type": "KritzelBaseObject<HTMLElement | SVGElement>[]",
|
|
2837
|
+
"docs": ""
|
|
2838
|
+
}, {
|
|
2839
|
+
"name": "animate",
|
|
2840
|
+
"type": "boolean",
|
|
2841
|
+
"docs": ""
|
|
2842
|
+
}],
|
|
2843
|
+
"references": {
|
|
2844
|
+
"Promise": {
|
|
2845
|
+
"location": "global",
|
|
2846
|
+
"id": "global::Promise"
|
|
2847
|
+
},
|
|
2848
|
+
"KritzelBaseObject": {
|
|
2849
|
+
"location": "import",
|
|
2850
|
+
"path": "@kritzel/engine",
|
|
2851
|
+
"id": "../../engine/core/dist/types/classes/objects/base-object.class.d.ts::KritzelBaseObject",
|
|
2852
|
+
"referenceLocation": "KritzelBaseObject"
|
|
2853
|
+
}
|
|
2854
|
+
},
|
|
2855
|
+
"return": "Promise<boolean>"
|
|
2856
|
+
},
|
|
2857
|
+
"docs": {
|
|
2858
|
+
"text": "",
|
|
2859
|
+
"tags": []
|
|
2860
|
+
}
|
|
2861
|
+
},
|
|
2862
|
+
"setViewport": {
|
|
2863
|
+
"complexType": {
|
|
2864
|
+
"signature": "(x: number, y: number, scale: number) => Promise<void>",
|
|
2865
|
+
"parameters": [{
|
|
2866
|
+
"name": "x",
|
|
2867
|
+
"type": "number",
|
|
2868
|
+
"docs": ""
|
|
2869
|
+
}, {
|
|
2870
|
+
"name": "y",
|
|
2871
|
+
"type": "number",
|
|
2872
|
+
"docs": ""
|
|
2873
|
+
}, {
|
|
2874
|
+
"name": "scale",
|
|
2875
|
+
"type": "number",
|
|
2876
|
+
"docs": ""
|
|
2877
|
+
}],
|
|
2878
|
+
"references": {
|
|
2879
|
+
"Promise": {
|
|
2880
|
+
"location": "global",
|
|
2881
|
+
"id": "global::Promise"
|
|
2882
|
+
}
|
|
2883
|
+
},
|
|
2884
|
+
"return": "Promise<void>"
|
|
2885
|
+
},
|
|
2886
|
+
"docs": {
|
|
2887
|
+
"text": "",
|
|
2888
|
+
"tags": []
|
|
2889
|
+
}
|
|
2890
|
+
},
|
|
2891
|
+
"panTo": {
|
|
2892
|
+
"complexType": {
|
|
2893
|
+
"signature": "(x: number, y: number) => Promise<void>",
|
|
2894
|
+
"parameters": [{
|
|
2895
|
+
"name": "x",
|
|
2896
|
+
"type": "number",
|
|
2897
|
+
"docs": ""
|
|
2898
|
+
}, {
|
|
2899
|
+
"name": "y",
|
|
2900
|
+
"type": "number",
|
|
2901
|
+
"docs": ""
|
|
2902
|
+
}],
|
|
2903
|
+
"references": {
|
|
2904
|
+
"Promise": {
|
|
2905
|
+
"location": "global",
|
|
2906
|
+
"id": "global::Promise"
|
|
2907
|
+
}
|
|
2908
|
+
},
|
|
2909
|
+
"return": "Promise<void>"
|
|
2910
|
+
},
|
|
2911
|
+
"docs": {
|
|
2912
|
+
"text": "",
|
|
2913
|
+
"tags": []
|
|
2914
|
+
}
|
|
2915
|
+
},
|
|
2916
|
+
"zoomTo": {
|
|
2917
|
+
"complexType": {
|
|
2918
|
+
"signature": "(scale: number, worldX?: number, worldY?: number) => Promise<void>",
|
|
2919
|
+
"parameters": [{
|
|
2920
|
+
"name": "scale",
|
|
2921
|
+
"type": "number",
|
|
2922
|
+
"docs": ""
|
|
2923
|
+
}, {
|
|
2924
|
+
"name": "worldX",
|
|
2925
|
+
"type": "number",
|
|
2926
|
+
"docs": ""
|
|
2927
|
+
}, {
|
|
2928
|
+
"name": "worldY",
|
|
2929
|
+
"type": "number",
|
|
2930
|
+
"docs": ""
|
|
2931
|
+
}],
|
|
2932
|
+
"references": {
|
|
2933
|
+
"Promise": {
|
|
2934
|
+
"location": "global",
|
|
2935
|
+
"id": "global::Promise"
|
|
2936
|
+
}
|
|
2937
|
+
},
|
|
2938
|
+
"return": "Promise<void>"
|
|
2939
|
+
},
|
|
2940
|
+
"docs": {
|
|
2941
|
+
"text": "",
|
|
2942
|
+
"tags": []
|
|
2943
|
+
}
|
|
2944
|
+
},
|
|
2945
|
+
"zoomIn": {
|
|
2946
|
+
"complexType": {
|
|
2947
|
+
"signature": "(factor?: number, duration?: number) => Promise<void>",
|
|
2948
|
+
"parameters": [{
|
|
2949
|
+
"name": "factor",
|
|
2950
|
+
"type": "number",
|
|
2951
|
+
"docs": ""
|
|
2952
|
+
}, {
|
|
2953
|
+
"name": "duration",
|
|
2954
|
+
"type": "number",
|
|
2955
|
+
"docs": ""
|
|
2956
|
+
}],
|
|
2957
|
+
"references": {
|
|
2958
|
+
"Promise": {
|
|
2959
|
+
"location": "global",
|
|
2960
|
+
"id": "global::Promise"
|
|
2961
|
+
}
|
|
2962
|
+
},
|
|
2963
|
+
"return": "Promise<void>"
|
|
2964
|
+
},
|
|
2965
|
+
"docs": {
|
|
2966
|
+
"text": "",
|
|
2967
|
+
"tags": []
|
|
2968
|
+
}
|
|
2969
|
+
},
|
|
2970
|
+
"zoomOut": {
|
|
2971
|
+
"complexType": {
|
|
2972
|
+
"signature": "(factor?: number, duration?: number) => Promise<void>",
|
|
2973
|
+
"parameters": [{
|
|
2974
|
+
"name": "factor",
|
|
2975
|
+
"type": "number",
|
|
2976
|
+
"docs": ""
|
|
2977
|
+
}, {
|
|
2978
|
+
"name": "duration",
|
|
2979
|
+
"type": "number",
|
|
2980
|
+
"docs": ""
|
|
2981
|
+
}],
|
|
2982
|
+
"references": {
|
|
2983
|
+
"Promise": {
|
|
2984
|
+
"location": "global",
|
|
2985
|
+
"id": "global::Promise"
|
|
2986
|
+
}
|
|
2987
|
+
},
|
|
2988
|
+
"return": "Promise<void>"
|
|
2989
|
+
},
|
|
2990
|
+
"docs": {
|
|
2991
|
+
"text": "",
|
|
2992
|
+
"tags": []
|
|
2993
|
+
}
|
|
2994
|
+
},
|
|
2995
|
+
"getViewport": {
|
|
2996
|
+
"complexType": {
|
|
2997
|
+
"signature": "() => Promise<KritzelViewportState>",
|
|
2998
|
+
"parameters": [],
|
|
2999
|
+
"references": {
|
|
3000
|
+
"Promise": {
|
|
3001
|
+
"location": "global",
|
|
3002
|
+
"id": "global::Promise"
|
|
3003
|
+
},
|
|
3004
|
+
"KritzelViewportState": {
|
|
3005
|
+
"location": "import",
|
|
3006
|
+
"path": "@kritzel/engine",
|
|
3007
|
+
"id": "../../engine/core/dist/types/index.d.ts::KritzelViewportState",
|
|
3008
|
+
"referenceLocation": "KritzelViewportState"
|
|
3009
|
+
}
|
|
3010
|
+
},
|
|
3011
|
+
"return": "Promise<KritzelViewportState>"
|
|
3012
|
+
},
|
|
3013
|
+
"docs": {
|
|
3014
|
+
"text": "",
|
|
3015
|
+
"tags": []
|
|
3016
|
+
}
|
|
3017
|
+
},
|
|
3018
|
+
"screenToWorld": {
|
|
3019
|
+
"complexType": {
|
|
3020
|
+
"signature": "(x: number, y: number) => Promise<{ x: number; y: number; }>",
|
|
3021
|
+
"parameters": [{
|
|
3022
|
+
"name": "x",
|
|
3023
|
+
"type": "number",
|
|
3024
|
+
"docs": ""
|
|
3025
|
+
}, {
|
|
3026
|
+
"name": "y",
|
|
3027
|
+
"type": "number",
|
|
3028
|
+
"docs": ""
|
|
3029
|
+
}],
|
|
3030
|
+
"references": {
|
|
3031
|
+
"Promise": {
|
|
3032
|
+
"location": "global",
|
|
3033
|
+
"id": "global::Promise"
|
|
3034
|
+
}
|
|
3035
|
+
},
|
|
3036
|
+
"return": "Promise<{ x: number; y: number; }>"
|
|
3037
|
+
},
|
|
3038
|
+
"docs": {
|
|
3039
|
+
"text": "",
|
|
3040
|
+
"tags": []
|
|
3041
|
+
}
|
|
3042
|
+
},
|
|
3043
|
+
"worldToScreen": {
|
|
3044
|
+
"complexType": {
|
|
3045
|
+
"signature": "(x: number, y: number) => Promise<{ x: number; y: number; }>",
|
|
3046
|
+
"parameters": [{
|
|
3047
|
+
"name": "x",
|
|
3048
|
+
"type": "number",
|
|
3049
|
+
"docs": ""
|
|
3050
|
+
}, {
|
|
3051
|
+
"name": "y",
|
|
3052
|
+
"type": "number",
|
|
3053
|
+
"docs": ""
|
|
3054
|
+
}],
|
|
3055
|
+
"references": {
|
|
3056
|
+
"Promise": {
|
|
3057
|
+
"location": "global",
|
|
3058
|
+
"id": "global::Promise"
|
|
3059
|
+
}
|
|
3060
|
+
},
|
|
3061
|
+
"return": "Promise<{ x: number; y: number; }>"
|
|
3062
|
+
},
|
|
3063
|
+
"docs": {
|
|
3064
|
+
"text": "",
|
|
3065
|
+
"tags": []
|
|
3066
|
+
}
|
|
3067
|
+
},
|
|
3068
|
+
"setActiveWorkspace": {
|
|
3069
|
+
"complexType": {
|
|
3070
|
+
"signature": "(id: string) => Promise<void>",
|
|
3071
|
+
"parameters": [{
|
|
3072
|
+
"name": "id",
|
|
3073
|
+
"type": "string",
|
|
3074
|
+
"docs": ""
|
|
3075
|
+
}],
|
|
3076
|
+
"references": {
|
|
3077
|
+
"Promise": {
|
|
3078
|
+
"location": "global",
|
|
3079
|
+
"id": "global::Promise"
|
|
3080
|
+
}
|
|
3081
|
+
},
|
|
3082
|
+
"return": "Promise<void>"
|
|
3083
|
+
},
|
|
3084
|
+
"docs": {
|
|
3085
|
+
"text": "",
|
|
3086
|
+
"tags": []
|
|
3087
|
+
}
|
|
3088
|
+
},
|
|
3089
|
+
"createWorkspace": {
|
|
3090
|
+
"complexType": {
|
|
3091
|
+
"signature": "(workspace: KritzelWorkspace) => Promise<KritzelWorkspace | null>",
|
|
3092
|
+
"parameters": [{
|
|
3093
|
+
"name": "workspace",
|
|
3094
|
+
"type": "KritzelWorkspace",
|
|
3095
|
+
"docs": ""
|
|
3096
|
+
}],
|
|
3097
|
+
"references": {
|
|
3098
|
+
"Promise": {
|
|
3099
|
+
"location": "global",
|
|
3100
|
+
"id": "global::Promise"
|
|
3101
|
+
},
|
|
3102
|
+
"KritzelWorkspace": {
|
|
3103
|
+
"location": "import",
|
|
3104
|
+
"path": "@kritzel/engine",
|
|
3105
|
+
"id": "../../engine/core/dist/types/classes/core/workspace.class.d.ts::KritzelWorkspace",
|
|
3106
|
+
"referenceLocation": "KritzelWorkspace"
|
|
3107
|
+
}
|
|
3108
|
+
},
|
|
3109
|
+
"return": "Promise<KritzelWorkspace>"
|
|
3110
|
+
},
|
|
3111
|
+
"docs": {
|
|
3112
|
+
"text": "",
|
|
3113
|
+
"tags": []
|
|
3114
|
+
}
|
|
3115
|
+
},
|
|
3116
|
+
"updateWorkspace": {
|
|
3117
|
+
"complexType": {
|
|
3118
|
+
"signature": "(workspace: KritzelWorkspace) => Promise<void>",
|
|
3119
|
+
"parameters": [{
|
|
3120
|
+
"name": "workspace",
|
|
3121
|
+
"type": "KritzelWorkspace",
|
|
3122
|
+
"docs": ""
|
|
3123
|
+
}],
|
|
3124
|
+
"references": {
|
|
3125
|
+
"Promise": {
|
|
3126
|
+
"location": "global",
|
|
3127
|
+
"id": "global::Promise"
|
|
3128
|
+
},
|
|
3129
|
+
"KritzelWorkspace": {
|
|
3130
|
+
"location": "import",
|
|
3131
|
+
"path": "@kritzel/engine",
|
|
3132
|
+
"id": "../../engine/core/dist/types/classes/core/workspace.class.d.ts::KritzelWorkspace",
|
|
3133
|
+
"referenceLocation": "KritzelWorkspace"
|
|
3134
|
+
}
|
|
3135
|
+
},
|
|
3136
|
+
"return": "Promise<void>"
|
|
3137
|
+
},
|
|
3138
|
+
"docs": {
|
|
3139
|
+
"text": "",
|
|
3140
|
+
"tags": []
|
|
3141
|
+
}
|
|
3142
|
+
},
|
|
3143
|
+
"deleteWorkspace": {
|
|
3144
|
+
"complexType": {
|
|
3145
|
+
"signature": "(workspace: KritzelWorkspace) => Promise<void>",
|
|
3146
|
+
"parameters": [{
|
|
3147
|
+
"name": "workspace",
|
|
3148
|
+
"type": "KritzelWorkspace",
|
|
3149
|
+
"docs": ""
|
|
3150
|
+
}],
|
|
3151
|
+
"references": {
|
|
3152
|
+
"Promise": {
|
|
3153
|
+
"location": "global",
|
|
3154
|
+
"id": "global::Promise"
|
|
3155
|
+
},
|
|
3156
|
+
"KritzelWorkspace": {
|
|
3157
|
+
"location": "import",
|
|
3158
|
+
"path": "@kritzel/engine",
|
|
3159
|
+
"id": "../../engine/core/dist/types/classes/core/workspace.class.d.ts::KritzelWorkspace",
|
|
3160
|
+
"referenceLocation": "KritzelWorkspace"
|
|
3161
|
+
}
|
|
3162
|
+
},
|
|
3163
|
+
"return": "Promise<void>"
|
|
3164
|
+
},
|
|
3165
|
+
"docs": {
|
|
3166
|
+
"text": "",
|
|
3167
|
+
"tags": []
|
|
3168
|
+
}
|
|
3169
|
+
},
|
|
3170
|
+
"getWorkspaces": {
|
|
3171
|
+
"complexType": {
|
|
3172
|
+
"signature": "() => Promise<KritzelWorkspace[]>",
|
|
3173
|
+
"parameters": [],
|
|
3174
|
+
"references": {
|
|
3175
|
+
"Promise": {
|
|
3176
|
+
"location": "global",
|
|
3177
|
+
"id": "global::Promise"
|
|
3178
|
+
},
|
|
3179
|
+
"KritzelWorkspace": {
|
|
3180
|
+
"location": "import",
|
|
3181
|
+
"path": "@kritzel/engine",
|
|
3182
|
+
"id": "../../engine/core/dist/types/classes/core/workspace.class.d.ts::KritzelWorkspace",
|
|
3183
|
+
"referenceLocation": "KritzelWorkspace"
|
|
3184
|
+
}
|
|
3185
|
+
},
|
|
3186
|
+
"return": "Promise<KritzelWorkspace[]>"
|
|
3187
|
+
},
|
|
3188
|
+
"docs": {
|
|
3189
|
+
"text": "",
|
|
3190
|
+
"tags": []
|
|
3191
|
+
}
|
|
3192
|
+
},
|
|
3193
|
+
"getActiveWorkspace": {
|
|
3194
|
+
"complexType": {
|
|
3195
|
+
"signature": "() => Promise<KritzelWorkspace>",
|
|
3196
|
+
"parameters": [],
|
|
3197
|
+
"references": {
|
|
3198
|
+
"Promise": {
|
|
3199
|
+
"location": "global",
|
|
3200
|
+
"id": "global::Promise"
|
|
3201
|
+
},
|
|
3202
|
+
"KritzelWorkspace": {
|
|
3203
|
+
"location": "import",
|
|
3204
|
+
"path": "@kritzel/engine",
|
|
3205
|
+
"id": "../../engine/core/dist/types/classes/core/workspace.class.d.ts::KritzelWorkspace",
|
|
3206
|
+
"referenceLocation": "KritzelWorkspace"
|
|
3207
|
+
}
|
|
3208
|
+
},
|
|
3209
|
+
"return": "Promise<KritzelWorkspace>"
|
|
3210
|
+
},
|
|
3211
|
+
"docs": {
|
|
3212
|
+
"text": "",
|
|
3213
|
+
"tags": []
|
|
3214
|
+
}
|
|
3215
|
+
},
|
|
3216
|
+
"loadSharedWorkspace": {
|
|
3217
|
+
"complexType": {
|
|
3218
|
+
"signature": "(token: string) => Promise<void>",
|
|
3219
|
+
"parameters": [{
|
|
3220
|
+
"name": "token",
|
|
3221
|
+
"type": "string",
|
|
3222
|
+
"docs": ""
|
|
3223
|
+
}],
|
|
3224
|
+
"references": {
|
|
3225
|
+
"Promise": {
|
|
3226
|
+
"location": "global",
|
|
3227
|
+
"id": "global::Promise"
|
|
3228
|
+
}
|
|
3229
|
+
},
|
|
3230
|
+
"return": "Promise<void>"
|
|
3231
|
+
},
|
|
3232
|
+
"docs": {
|
|
3233
|
+
"text": "",
|
|
3234
|
+
"tags": []
|
|
3235
|
+
}
|
|
3236
|
+
},
|
|
3237
|
+
"reinitSync": {
|
|
3238
|
+
"complexType": {
|
|
3239
|
+
"signature": "() => Promise<void>",
|
|
3240
|
+
"parameters": [],
|
|
3241
|
+
"references": {
|
|
3242
|
+
"Promise": {
|
|
3243
|
+
"location": "global",
|
|
3244
|
+
"id": "global::Promise"
|
|
3245
|
+
}
|
|
3246
|
+
},
|
|
3247
|
+
"return": "Promise<void>"
|
|
3248
|
+
},
|
|
3249
|
+
"docs": {
|
|
3250
|
+
"text": "",
|
|
3251
|
+
"tags": []
|
|
3252
|
+
}
|
|
3253
|
+
},
|
|
3254
|
+
"registerTool": {
|
|
3255
|
+
"complexType": {
|
|
3256
|
+
"signature": "(toolName: string, toolClass: any, toolConfig?: KritzelTextToolConfig | KritzelBrushToolConfig | KritzelLineToolConfig | KritzelShapeToolConfig) => Promise<KritzelBaseTool | null>",
|
|
3257
|
+
"parameters": [{
|
|
3258
|
+
"name": "toolName",
|
|
3259
|
+
"type": "string",
|
|
3260
|
+
"docs": ""
|
|
3261
|
+
}, {
|
|
3262
|
+
"name": "toolClass",
|
|
3263
|
+
"type": "any",
|
|
3264
|
+
"docs": ""
|
|
3265
|
+
}, {
|
|
3266
|
+
"name": "toolConfig",
|
|
3267
|
+
"type": "KritzelTextToolConfig | KritzelBrushToolConfig | KritzelLineToolConfig | KritzelShapeToolConfig",
|
|
3268
|
+
"docs": ""
|
|
3269
|
+
}],
|
|
3270
|
+
"references": {
|
|
3271
|
+
"Promise": {
|
|
3272
|
+
"location": "global",
|
|
3273
|
+
"id": "global::Promise"
|
|
3274
|
+
},
|
|
3275
|
+
"KritzelBaseTool": {
|
|
3276
|
+
"location": "import",
|
|
3277
|
+
"path": "@kritzel/engine",
|
|
3278
|
+
"id": "../../engine/core/dist/types/classes/tools/base-tool.class.d.ts::KritzelBaseTool",
|
|
3279
|
+
"referenceLocation": "KritzelBaseTool"
|
|
3280
|
+
},
|
|
3281
|
+
"KritzelTextToolConfig": {
|
|
3282
|
+
"location": "import",
|
|
3283
|
+
"path": "@kritzel/engine",
|
|
3284
|
+
"id": "../../engine/core/dist/types/index.d.ts::KritzelTextToolConfig",
|
|
3285
|
+
"referenceLocation": "KritzelTextToolConfig"
|
|
3286
|
+
},
|
|
3287
|
+
"KritzelBrushToolConfig": {
|
|
3288
|
+
"location": "import",
|
|
3289
|
+
"path": "@kritzel/engine",
|
|
3290
|
+
"id": "../../engine/core/dist/types/index.d.ts::KritzelBrushToolConfig",
|
|
3291
|
+
"referenceLocation": "KritzelBrushToolConfig"
|
|
3292
|
+
},
|
|
3293
|
+
"KritzelLineToolConfig": {
|
|
3294
|
+
"location": "import",
|
|
3295
|
+
"path": "@kritzel/engine",
|
|
3296
|
+
"id": "../../engine/core/dist/types/index.d.ts::KritzelLineToolConfig",
|
|
3297
|
+
"referenceLocation": "KritzelLineToolConfig"
|
|
3298
|
+
},
|
|
3299
|
+
"KritzelShapeToolConfig": {
|
|
3300
|
+
"location": "import",
|
|
3301
|
+
"path": "@kritzel/engine",
|
|
3302
|
+
"id": "../../engine/core/dist/types/index.d.ts::KritzelShapeToolConfig",
|
|
3303
|
+
"referenceLocation": "KritzelShapeToolConfig"
|
|
3304
|
+
}
|
|
3305
|
+
},
|
|
3306
|
+
"return": "Promise<KritzelBaseTool>"
|
|
3307
|
+
},
|
|
3308
|
+
"docs": {
|
|
3309
|
+
"text": "",
|
|
3310
|
+
"tags": []
|
|
3311
|
+
}
|
|
3312
|
+
},
|
|
3313
|
+
"changeActiveTool": {
|
|
3314
|
+
"complexType": {
|
|
3315
|
+
"signature": "(toolName: string) => Promise<void>",
|
|
3316
|
+
"parameters": [{
|
|
3317
|
+
"name": "toolName",
|
|
3318
|
+
"type": "string",
|
|
3319
|
+
"docs": ""
|
|
3320
|
+
}],
|
|
3321
|
+
"references": {
|
|
3322
|
+
"Promise": {
|
|
3323
|
+
"location": "global",
|
|
3324
|
+
"id": "global::Promise"
|
|
3325
|
+
}
|
|
3326
|
+
},
|
|
3327
|
+
"return": "Promise<void>"
|
|
3328
|
+
},
|
|
3329
|
+
"docs": {
|
|
3330
|
+
"text": "",
|
|
3331
|
+
"tags": []
|
|
3332
|
+
}
|
|
3333
|
+
},
|
|
3334
|
+
"disable": {
|
|
3335
|
+
"complexType": {
|
|
3336
|
+
"signature": "() => Promise<void>",
|
|
3337
|
+
"parameters": [],
|
|
3338
|
+
"references": {
|
|
3339
|
+
"Promise": {
|
|
3340
|
+
"location": "global",
|
|
3341
|
+
"id": "global::Promise"
|
|
3342
|
+
}
|
|
3343
|
+
},
|
|
3344
|
+
"return": "Promise<void>"
|
|
3345
|
+
},
|
|
3346
|
+
"docs": {
|
|
3347
|
+
"text": "",
|
|
3348
|
+
"tags": []
|
|
3349
|
+
}
|
|
3350
|
+
},
|
|
3351
|
+
"enable": {
|
|
3352
|
+
"complexType": {
|
|
3353
|
+
"signature": "() => Promise<void>",
|
|
3354
|
+
"parameters": [],
|
|
3355
|
+
"references": {
|
|
3356
|
+
"Promise": {
|
|
3357
|
+
"location": "global",
|
|
3358
|
+
"id": "global::Promise"
|
|
3359
|
+
}
|
|
3360
|
+
},
|
|
3361
|
+
"return": "Promise<void>"
|
|
3362
|
+
},
|
|
3363
|
+
"docs": {
|
|
3364
|
+
"text": "",
|
|
3365
|
+
"tags": []
|
|
3366
|
+
}
|
|
3367
|
+
},
|
|
3368
|
+
"copy": {
|
|
3369
|
+
"complexType": {
|
|
3370
|
+
"signature": "() => Promise<void>",
|
|
3371
|
+
"parameters": [],
|
|
3372
|
+
"references": {
|
|
3373
|
+
"Promise": {
|
|
3374
|
+
"location": "global",
|
|
3375
|
+
"id": "global::Promise"
|
|
3376
|
+
}
|
|
3377
|
+
},
|
|
3378
|
+
"return": "Promise<void>"
|
|
3379
|
+
},
|
|
3380
|
+
"docs": {
|
|
3381
|
+
"text": "",
|
|
3382
|
+
"tags": []
|
|
3383
|
+
}
|
|
3384
|
+
},
|
|
3385
|
+
"cut": {
|
|
3386
|
+
"complexType": {
|
|
3387
|
+
"signature": "() => Promise<void>",
|
|
3388
|
+
"parameters": [],
|
|
3389
|
+
"references": {
|
|
3390
|
+
"Promise": {
|
|
3391
|
+
"location": "global",
|
|
3392
|
+
"id": "global::Promise"
|
|
3393
|
+
}
|
|
3394
|
+
},
|
|
3395
|
+
"return": "Promise<void>"
|
|
3396
|
+
},
|
|
3397
|
+
"docs": {
|
|
3398
|
+
"text": "",
|
|
3399
|
+
"tags": []
|
|
3400
|
+
}
|
|
3401
|
+
},
|
|
3402
|
+
"paste": {
|
|
3403
|
+
"complexType": {
|
|
3404
|
+
"signature": "(x: number, y: number) => Promise<void>",
|
|
3405
|
+
"parameters": [{
|
|
3406
|
+
"name": "x",
|
|
3407
|
+
"type": "number",
|
|
3408
|
+
"docs": ""
|
|
3409
|
+
}, {
|
|
3410
|
+
"name": "y",
|
|
3411
|
+
"type": "number",
|
|
3412
|
+
"docs": ""
|
|
3413
|
+
}],
|
|
3414
|
+
"references": {
|
|
3415
|
+
"Promise": {
|
|
3416
|
+
"location": "global",
|
|
3417
|
+
"id": "global::Promise"
|
|
3418
|
+
}
|
|
3419
|
+
},
|
|
3420
|
+
"return": "Promise<void>"
|
|
3421
|
+
},
|
|
3422
|
+
"docs": {
|
|
3423
|
+
"text": "",
|
|
3424
|
+
"tags": []
|
|
3425
|
+
}
|
|
3426
|
+
},
|
|
3427
|
+
"delete": {
|
|
3428
|
+
"complexType": {
|
|
3429
|
+
"signature": "() => Promise<void>",
|
|
3430
|
+
"parameters": [],
|
|
3431
|
+
"references": {
|
|
3432
|
+
"Promise": {
|
|
3433
|
+
"location": "global",
|
|
3434
|
+
"id": "global::Promise"
|
|
3435
|
+
}
|
|
3436
|
+
},
|
|
3437
|
+
"return": "Promise<void>"
|
|
3438
|
+
},
|
|
3439
|
+
"docs": {
|
|
3440
|
+
"text": "",
|
|
3441
|
+
"tags": []
|
|
3442
|
+
}
|
|
3443
|
+
},
|
|
3444
|
+
"bringForward": {
|
|
3445
|
+
"complexType": {
|
|
3446
|
+
"signature": "(object?: KritzelBaseObject<any>) => Promise<void>",
|
|
3447
|
+
"parameters": [{
|
|
3448
|
+
"name": "object",
|
|
3449
|
+
"type": "KritzelBaseObject<any>",
|
|
3450
|
+
"docs": ""
|
|
3451
|
+
}],
|
|
3452
|
+
"references": {
|
|
3453
|
+
"Promise": {
|
|
3454
|
+
"location": "global",
|
|
3455
|
+
"id": "global::Promise"
|
|
3456
|
+
},
|
|
3457
|
+
"KritzelBaseObject": {
|
|
3458
|
+
"location": "import",
|
|
3459
|
+
"path": "@kritzel/engine",
|
|
3460
|
+
"id": "../../engine/core/dist/types/classes/objects/base-object.class.d.ts::KritzelBaseObject",
|
|
3461
|
+
"referenceLocation": "KritzelBaseObject"
|
|
3462
|
+
}
|
|
3463
|
+
},
|
|
3464
|
+
"return": "Promise<void>"
|
|
3465
|
+
},
|
|
3466
|
+
"docs": {
|
|
3467
|
+
"text": "",
|
|
3468
|
+
"tags": []
|
|
3469
|
+
}
|
|
3470
|
+
},
|
|
3471
|
+
"sendBackward": {
|
|
3472
|
+
"complexType": {
|
|
3473
|
+
"signature": "(object?: KritzelBaseObject<any>) => Promise<void>",
|
|
3474
|
+
"parameters": [{
|
|
3475
|
+
"name": "object",
|
|
3476
|
+
"type": "KritzelBaseObject<any>",
|
|
3477
|
+
"docs": ""
|
|
3478
|
+
}],
|
|
3479
|
+
"references": {
|
|
3480
|
+
"Promise": {
|
|
3481
|
+
"location": "global",
|
|
3482
|
+
"id": "global::Promise"
|
|
3483
|
+
},
|
|
3484
|
+
"KritzelBaseObject": {
|
|
3485
|
+
"location": "import",
|
|
3486
|
+
"path": "@kritzel/engine",
|
|
3487
|
+
"id": "../../engine/core/dist/types/classes/objects/base-object.class.d.ts::KritzelBaseObject",
|
|
3488
|
+
"referenceLocation": "KritzelBaseObject"
|
|
3489
|
+
}
|
|
3490
|
+
},
|
|
3491
|
+
"return": "Promise<void>"
|
|
3492
|
+
},
|
|
3493
|
+
"docs": {
|
|
3494
|
+
"text": "",
|
|
3495
|
+
"tags": []
|
|
3496
|
+
}
|
|
3497
|
+
},
|
|
3498
|
+
"bringToFront": {
|
|
3499
|
+
"complexType": {
|
|
3500
|
+
"signature": "(object?: KritzelBaseObject<any>) => Promise<void>",
|
|
3501
|
+
"parameters": [{
|
|
3502
|
+
"name": "object",
|
|
3503
|
+
"type": "KritzelBaseObject<any>",
|
|
3504
|
+
"docs": ""
|
|
3505
|
+
}],
|
|
3506
|
+
"references": {
|
|
3507
|
+
"Promise": {
|
|
3508
|
+
"location": "global",
|
|
3509
|
+
"id": "global::Promise"
|
|
3510
|
+
},
|
|
3511
|
+
"KritzelBaseObject": {
|
|
3512
|
+
"location": "import",
|
|
3513
|
+
"path": "@kritzel/engine",
|
|
3514
|
+
"id": "../../engine/core/dist/types/classes/objects/base-object.class.d.ts::KritzelBaseObject",
|
|
3515
|
+
"referenceLocation": "KritzelBaseObject"
|
|
3516
|
+
}
|
|
3517
|
+
},
|
|
3518
|
+
"return": "Promise<void>"
|
|
3519
|
+
},
|
|
3520
|
+
"docs": {
|
|
3521
|
+
"text": "",
|
|
3522
|
+
"tags": []
|
|
3523
|
+
}
|
|
3524
|
+
},
|
|
3525
|
+
"sendToBack": {
|
|
3526
|
+
"complexType": {
|
|
3527
|
+
"signature": "(object?: KritzelBaseObject<any>) => Promise<void>",
|
|
3528
|
+
"parameters": [{
|
|
3529
|
+
"name": "object",
|
|
3530
|
+
"type": "KritzelBaseObject<any>",
|
|
3531
|
+
"docs": ""
|
|
3532
|
+
}],
|
|
3533
|
+
"references": {
|
|
3534
|
+
"Promise": {
|
|
3535
|
+
"location": "global",
|
|
3536
|
+
"id": "global::Promise"
|
|
3537
|
+
},
|
|
3538
|
+
"KritzelBaseObject": {
|
|
3539
|
+
"location": "import",
|
|
3540
|
+
"path": "@kritzel/engine",
|
|
3541
|
+
"id": "../../engine/core/dist/types/classes/objects/base-object.class.d.ts::KritzelBaseObject",
|
|
3542
|
+
"referenceLocation": "KritzelBaseObject"
|
|
3543
|
+
}
|
|
3544
|
+
},
|
|
3545
|
+
"return": "Promise<void>"
|
|
3546
|
+
},
|
|
3547
|
+
"docs": {
|
|
3548
|
+
"text": "",
|
|
3549
|
+
"tags": []
|
|
3550
|
+
}
|
|
3551
|
+
},
|
|
3552
|
+
"alignObjects": {
|
|
3553
|
+
"complexType": {
|
|
3554
|
+
"signature": "(alignment: KritzelAlignment) => Promise<void>",
|
|
3555
|
+
"parameters": [{
|
|
3556
|
+
"name": "alignment",
|
|
3557
|
+
"type": "KritzelAlignment",
|
|
3558
|
+
"docs": ""
|
|
3559
|
+
}],
|
|
3560
|
+
"references": {
|
|
3561
|
+
"Promise": {
|
|
3562
|
+
"location": "global",
|
|
3563
|
+
"id": "global::Promise"
|
|
3564
|
+
},
|
|
3565
|
+
"KritzelAlignment": {
|
|
3566
|
+
"location": "import",
|
|
3567
|
+
"path": "@kritzel/engine",
|
|
3568
|
+
"id": "../../engine/core/dist/types/enums/alignment.enum.d.ts::KritzelAlignment",
|
|
3569
|
+
"referenceLocation": "KritzelAlignment"
|
|
3570
|
+
}
|
|
3571
|
+
},
|
|
3572
|
+
"return": "Promise<void>"
|
|
3573
|
+
},
|
|
3574
|
+
"docs": {
|
|
3575
|
+
"text": "",
|
|
3576
|
+
"tags": []
|
|
3577
|
+
}
|
|
3578
|
+
},
|
|
3579
|
+
"group": {
|
|
3580
|
+
"complexType": {
|
|
3581
|
+
"signature": "() => Promise<void>",
|
|
3582
|
+
"parameters": [],
|
|
3583
|
+
"references": {
|
|
3584
|
+
"Promise": {
|
|
3585
|
+
"location": "global",
|
|
3586
|
+
"id": "global::Promise"
|
|
3587
|
+
}
|
|
3588
|
+
},
|
|
3589
|
+
"return": "Promise<void>"
|
|
3590
|
+
},
|
|
3591
|
+
"docs": {
|
|
3592
|
+
"text": "",
|
|
3593
|
+
"tags": []
|
|
3594
|
+
}
|
|
3595
|
+
},
|
|
3596
|
+
"ungroup": {
|
|
3597
|
+
"complexType": {
|
|
3598
|
+
"signature": "() => Promise<void>",
|
|
3599
|
+
"parameters": [],
|
|
3600
|
+
"references": {
|
|
3601
|
+
"Promise": {
|
|
3602
|
+
"location": "global",
|
|
3603
|
+
"id": "global::Promise"
|
|
3604
|
+
}
|
|
3605
|
+
},
|
|
3606
|
+
"return": "Promise<void>"
|
|
3607
|
+
},
|
|
3608
|
+
"docs": {
|
|
3609
|
+
"text": "",
|
|
3610
|
+
"tags": []
|
|
3611
|
+
}
|
|
3612
|
+
},
|
|
3613
|
+
"undo": {
|
|
3614
|
+
"complexType": {
|
|
3615
|
+
"signature": "() => Promise<void>",
|
|
3616
|
+
"parameters": [],
|
|
3617
|
+
"references": {
|
|
3618
|
+
"Promise": {
|
|
3619
|
+
"location": "global",
|
|
3620
|
+
"id": "global::Promise"
|
|
3621
|
+
}
|
|
3622
|
+
},
|
|
3623
|
+
"return": "Promise<void>"
|
|
3624
|
+
},
|
|
3625
|
+
"docs": {
|
|
3626
|
+
"text": "",
|
|
3627
|
+
"tags": []
|
|
3628
|
+
}
|
|
3629
|
+
},
|
|
3630
|
+
"redo": {
|
|
3631
|
+
"complexType": {
|
|
3632
|
+
"signature": "() => Promise<void>",
|
|
3633
|
+
"parameters": [],
|
|
3634
|
+
"references": {
|
|
3635
|
+
"Promise": {
|
|
3636
|
+
"location": "global",
|
|
3637
|
+
"id": "global::Promise"
|
|
3638
|
+
}
|
|
3639
|
+
},
|
|
3640
|
+
"return": "Promise<void>"
|
|
3641
|
+
},
|
|
3642
|
+
"docs": {
|
|
3643
|
+
"text": "",
|
|
3644
|
+
"tags": []
|
|
3645
|
+
}
|
|
3646
|
+
},
|
|
3647
|
+
"getScreenshot": {
|
|
3648
|
+
"complexType": {
|
|
3649
|
+
"signature": "(format?: \"png\" | \"svg\") => Promise<string | null>",
|
|
3650
|
+
"parameters": [{
|
|
3651
|
+
"name": "format",
|
|
3652
|
+
"type": "\"svg\" | \"png\"",
|
|
3653
|
+
"docs": ""
|
|
3654
|
+
}],
|
|
3655
|
+
"references": {
|
|
3656
|
+
"Promise": {
|
|
3657
|
+
"location": "global",
|
|
3658
|
+
"id": "global::Promise"
|
|
3659
|
+
}
|
|
3660
|
+
},
|
|
3661
|
+
"return": "Promise<string>"
|
|
3662
|
+
},
|
|
3663
|
+
"docs": {
|
|
3664
|
+
"text": "",
|
|
3665
|
+
"tags": []
|
|
3666
|
+
}
|
|
3667
|
+
},
|
|
3668
|
+
"exportViewportAsPng": {
|
|
3669
|
+
"complexType": {
|
|
3670
|
+
"signature": "() => Promise<void>",
|
|
3671
|
+
"parameters": [],
|
|
3672
|
+
"references": {
|
|
3673
|
+
"Promise": {
|
|
3674
|
+
"location": "global",
|
|
3675
|
+
"id": "global::Promise"
|
|
3676
|
+
}
|
|
3677
|
+
},
|
|
3678
|
+
"return": "Promise<void>"
|
|
3679
|
+
},
|
|
3680
|
+
"docs": {
|
|
3681
|
+
"text": "",
|
|
3682
|
+
"tags": []
|
|
3683
|
+
}
|
|
3684
|
+
},
|
|
3685
|
+
"exportViewportAsSvg": {
|
|
3686
|
+
"complexType": {
|
|
3687
|
+
"signature": "() => Promise<void>",
|
|
3688
|
+
"parameters": [],
|
|
3689
|
+
"references": {
|
|
3690
|
+
"Promise": {
|
|
3691
|
+
"location": "global",
|
|
3692
|
+
"id": "global::Promise"
|
|
3693
|
+
}
|
|
3694
|
+
},
|
|
3695
|
+
"return": "Promise<void>"
|
|
3696
|
+
},
|
|
3697
|
+
"docs": {
|
|
3698
|
+
"text": "",
|
|
3699
|
+
"tags": []
|
|
3700
|
+
}
|
|
3701
|
+
},
|
|
3702
|
+
"getSelectedObjectSupportedExportFormats": {
|
|
3703
|
+
"complexType": {
|
|
3704
|
+
"signature": "() => Promise<KritzelObjectExportFormat[]>",
|
|
3705
|
+
"parameters": [],
|
|
3706
|
+
"references": {
|
|
3707
|
+
"Promise": {
|
|
3708
|
+
"location": "global",
|
|
3709
|
+
"id": "global::Promise"
|
|
3710
|
+
},
|
|
3711
|
+
"KritzelObjectExportFormat": {
|
|
3712
|
+
"location": "import",
|
|
3713
|
+
"path": "@kritzel/engine",
|
|
3714
|
+
"id": "../../engine/core/dist/types/index.d.ts::KritzelObjectExportFormat",
|
|
3715
|
+
"referenceLocation": "KritzelObjectExportFormat"
|
|
3716
|
+
}
|
|
3717
|
+
},
|
|
3718
|
+
"return": "Promise<KritzelObjectExportFormat[]>"
|
|
3719
|
+
},
|
|
3720
|
+
"docs": {
|
|
3721
|
+
"text": "",
|
|
3722
|
+
"tags": []
|
|
3723
|
+
}
|
|
3724
|
+
},
|
|
3725
|
+
"canExportSelectedObjectAs": {
|
|
3726
|
+
"complexType": {
|
|
3727
|
+
"signature": "(format: KritzelObjectExportFormat) => Promise<boolean>",
|
|
3728
|
+
"parameters": [{
|
|
3729
|
+
"name": "format",
|
|
3730
|
+
"type": "\"svg\" | \"png\"",
|
|
3731
|
+
"docs": ""
|
|
3732
|
+
}],
|
|
3733
|
+
"references": {
|
|
3734
|
+
"Promise": {
|
|
3735
|
+
"location": "global",
|
|
3736
|
+
"id": "global::Promise"
|
|
3737
|
+
},
|
|
3738
|
+
"KritzelObjectExportFormat": {
|
|
3739
|
+
"location": "import",
|
|
3740
|
+
"path": "@kritzel/engine",
|
|
3741
|
+
"id": "../../engine/core/dist/types/index.d.ts::KritzelObjectExportFormat",
|
|
3742
|
+
"referenceLocation": "KritzelObjectExportFormat"
|
|
3743
|
+
}
|
|
3744
|
+
},
|
|
3745
|
+
"return": "Promise<boolean>"
|
|
3746
|
+
},
|
|
3747
|
+
"docs": {
|
|
3748
|
+
"text": "",
|
|
3749
|
+
"tags": []
|
|
3750
|
+
}
|
|
3751
|
+
},
|
|
3752
|
+
"exportSelectedObject": {
|
|
3753
|
+
"complexType": {
|
|
3754
|
+
"signature": "(format: KritzelObjectExportFormat) => Promise<void>",
|
|
3755
|
+
"parameters": [{
|
|
3756
|
+
"name": "format",
|
|
3757
|
+
"type": "\"svg\" | \"png\"",
|
|
3758
|
+
"docs": ""
|
|
3759
|
+
}],
|
|
3760
|
+
"references": {
|
|
3761
|
+
"Promise": {
|
|
3762
|
+
"location": "global",
|
|
3763
|
+
"id": "global::Promise"
|
|
3764
|
+
},
|
|
3765
|
+
"KritzelObjectExportFormat": {
|
|
3766
|
+
"location": "import",
|
|
3767
|
+
"path": "@kritzel/engine",
|
|
3768
|
+
"id": "../../engine/core/dist/types/index.d.ts::KritzelObjectExportFormat",
|
|
3769
|
+
"referenceLocation": "KritzelObjectExportFormat"
|
|
3770
|
+
}
|
|
3771
|
+
},
|
|
3772
|
+
"return": "Promise<void>"
|
|
3773
|
+
},
|
|
3774
|
+
"docs": {
|
|
3775
|
+
"text": "",
|
|
3776
|
+
"tags": []
|
|
3777
|
+
}
|
|
3778
|
+
},
|
|
3779
|
+
"exportAsJson": {
|
|
3780
|
+
"complexType": {
|
|
3781
|
+
"signature": "() => Promise<string>",
|
|
3782
|
+
"parameters": [],
|
|
3783
|
+
"references": {
|
|
3784
|
+
"Promise": {
|
|
3785
|
+
"location": "global",
|
|
3786
|
+
"id": "global::Promise"
|
|
3787
|
+
}
|
|
3788
|
+
},
|
|
3789
|
+
"return": "Promise<string>"
|
|
3790
|
+
},
|
|
3791
|
+
"docs": {
|
|
3792
|
+
"text": "",
|
|
3793
|
+
"tags": []
|
|
3794
|
+
}
|
|
3795
|
+
},
|
|
3796
|
+
"importFromJson": {
|
|
3797
|
+
"complexType": {
|
|
3798
|
+
"signature": "(json: string) => Promise<void>",
|
|
3799
|
+
"parameters": [{
|
|
3800
|
+
"name": "json",
|
|
3801
|
+
"type": "string",
|
|
3802
|
+
"docs": ""
|
|
3803
|
+
}],
|
|
3804
|
+
"references": {
|
|
3805
|
+
"Promise": {
|
|
3806
|
+
"location": "global",
|
|
3807
|
+
"id": "global::Promise"
|
|
3808
|
+
}
|
|
3809
|
+
},
|
|
3810
|
+
"return": "Promise<void>"
|
|
3811
|
+
},
|
|
3812
|
+
"docs": {
|
|
3813
|
+
"text": "",
|
|
3814
|
+
"tags": []
|
|
3815
|
+
}
|
|
3816
|
+
},
|
|
3817
|
+
"downloadAsJson": {
|
|
3818
|
+
"complexType": {
|
|
3819
|
+
"signature": "(filename?: string) => Promise<void>",
|
|
3820
|
+
"parameters": [{
|
|
3821
|
+
"name": "filename",
|
|
3822
|
+
"type": "string",
|
|
3823
|
+
"docs": ""
|
|
3824
|
+
}],
|
|
3825
|
+
"references": {
|
|
3826
|
+
"Promise": {
|
|
3827
|
+
"location": "global",
|
|
3828
|
+
"id": "global::Promise"
|
|
3829
|
+
}
|
|
3830
|
+
},
|
|
3831
|
+
"return": "Promise<void>"
|
|
3832
|
+
},
|
|
3833
|
+
"docs": {
|
|
3834
|
+
"text": "",
|
|
3835
|
+
"tags": []
|
|
3836
|
+
}
|
|
3837
|
+
},
|
|
3838
|
+
"importFromFile": {
|
|
3839
|
+
"complexType": {
|
|
3840
|
+
"signature": "() => Promise<void>",
|
|
3841
|
+
"parameters": [],
|
|
3842
|
+
"references": {
|
|
3843
|
+
"Promise": {
|
|
3844
|
+
"location": "global",
|
|
3845
|
+
"id": "global::Promise"
|
|
3846
|
+
}
|
|
3847
|
+
},
|
|
3848
|
+
"return": "Promise<void>"
|
|
3849
|
+
},
|
|
3850
|
+
"docs": {
|
|
3851
|
+
"text": "",
|
|
3852
|
+
"tags": []
|
|
3853
|
+
}
|
|
3854
|
+
},
|
|
3855
|
+
"loadObjectsFromJson": {
|
|
3856
|
+
"complexType": {
|
|
3857
|
+
"signature": "(json: string) => Promise<number>",
|
|
3858
|
+
"parameters": [{
|
|
3859
|
+
"name": "json",
|
|
3860
|
+
"type": "string",
|
|
3861
|
+
"docs": ""
|
|
3862
|
+
}],
|
|
3863
|
+
"references": {
|
|
3864
|
+
"Promise": {
|
|
3865
|
+
"location": "global",
|
|
3866
|
+
"id": "global::Promise"
|
|
3867
|
+
}
|
|
3868
|
+
},
|
|
3869
|
+
"return": "Promise<number>"
|
|
3870
|
+
},
|
|
3871
|
+
"docs": {
|
|
3872
|
+
"text": "",
|
|
3873
|
+
"tags": []
|
|
3874
|
+
}
|
|
3875
|
+
},
|
|
3876
|
+
"getObjectsTotalCount": {
|
|
3877
|
+
"complexType": {
|
|
3878
|
+
"signature": "() => Promise<number>",
|
|
3879
|
+
"parameters": [],
|
|
3880
|
+
"references": {
|
|
3881
|
+
"Promise": {
|
|
3882
|
+
"location": "global",
|
|
3883
|
+
"id": "global::Promise"
|
|
3884
|
+
}
|
|
3885
|
+
},
|
|
3886
|
+
"return": "Promise<number>"
|
|
3887
|
+
},
|
|
3888
|
+
"docs": {
|
|
3889
|
+
"text": "",
|
|
3890
|
+
"tags": []
|
|
3891
|
+
}
|
|
3892
|
+
},
|
|
3893
|
+
"getAllObjects": {
|
|
3894
|
+
"complexType": {
|
|
3895
|
+
"signature": "<T extends KritzelBaseObject>() => Promise<T[]>",
|
|
3896
|
+
"parameters": [],
|
|
3897
|
+
"references": {
|
|
3898
|
+
"Promise": {
|
|
3899
|
+
"location": "global",
|
|
3900
|
+
"id": "global::Promise"
|
|
3901
|
+
},
|
|
3902
|
+
"T": {
|
|
3903
|
+
"location": "global",
|
|
3904
|
+
"id": "global::T"
|
|
3905
|
+
},
|
|
3906
|
+
"KritzelBaseObject": {
|
|
3907
|
+
"location": "import",
|
|
3908
|
+
"path": "@kritzel/engine",
|
|
3909
|
+
"id": "../../engine/core/dist/types/classes/objects/base-object.class.d.ts::KritzelBaseObject",
|
|
3910
|
+
"referenceLocation": "KritzelBaseObject"
|
|
3911
|
+
}
|
|
3912
|
+
},
|
|
3913
|
+
"return": "Promise<T[]>"
|
|
3914
|
+
},
|
|
3915
|
+
"docs": {
|
|
3916
|
+
"text": "",
|
|
3917
|
+
"tags": []
|
|
3918
|
+
}
|
|
3919
|
+
},
|
|
3920
|
+
"findObjects": {
|
|
3921
|
+
"complexType": {
|
|
3922
|
+
"signature": "<T extends KritzelBaseObject>(predicate: (obj: KritzelBaseObject<Element>) => boolean) => Promise<T[]>",
|
|
3923
|
+
"parameters": [{
|
|
3924
|
+
"name": "predicate",
|
|
3925
|
+
"type": "(obj: KritzelBaseObject<Element>) => boolean",
|
|
3926
|
+
"docs": ""
|
|
3927
|
+
}],
|
|
3928
|
+
"references": {
|
|
3929
|
+
"Promise": {
|
|
3930
|
+
"location": "global",
|
|
3931
|
+
"id": "global::Promise"
|
|
3932
|
+
},
|
|
3933
|
+
"T": {
|
|
3934
|
+
"location": "global",
|
|
3935
|
+
"id": "global::T"
|
|
3936
|
+
},
|
|
3937
|
+
"KritzelBaseObject": {
|
|
3938
|
+
"location": "import",
|
|
3939
|
+
"path": "@kritzel/engine",
|
|
3940
|
+
"id": "../../engine/core/dist/types/classes/objects/base-object.class.d.ts::KritzelBaseObject",
|
|
3941
|
+
"referenceLocation": "KritzelBaseObject"
|
|
3942
|
+
},
|
|
3943
|
+
"Element": {
|
|
3944
|
+
"location": "import",
|
|
3945
|
+
"path": "@stencil/core",
|
|
3946
|
+
"id": "../../../node_modules/@stencil/core/internal/stencil-core/index.d.ts::Element",
|
|
3947
|
+
"referenceLocation": "Element"
|
|
3948
|
+
}
|
|
3949
|
+
},
|
|
3950
|
+
"return": "Promise<T[]>"
|
|
3951
|
+
},
|
|
3952
|
+
"docs": {
|
|
3953
|
+
"text": "",
|
|
3954
|
+
"tags": []
|
|
3955
|
+
}
|
|
3956
|
+
},
|
|
3957
|
+
"getObjectsInViewport": {
|
|
3958
|
+
"complexType": {
|
|
3959
|
+
"signature": "() => Promise<KritzelBaseObject[]>",
|
|
3960
|
+
"parameters": [],
|
|
3961
|
+
"references": {
|
|
3962
|
+
"Promise": {
|
|
3963
|
+
"location": "global",
|
|
3964
|
+
"id": "global::Promise"
|
|
3965
|
+
},
|
|
3966
|
+
"KritzelBaseObject": {
|
|
3967
|
+
"location": "import",
|
|
3968
|
+
"path": "@kritzel/engine",
|
|
3969
|
+
"id": "../../engine/core/dist/types/classes/objects/base-object.class.d.ts::KritzelBaseObject",
|
|
3970
|
+
"referenceLocation": "KritzelBaseObject"
|
|
3971
|
+
},
|
|
3972
|
+
"HTMLElement": {
|
|
3973
|
+
"location": "global",
|
|
3974
|
+
"id": "global::HTMLElement"
|
|
3975
|
+
},
|
|
3976
|
+
"SVGElement": {
|
|
3977
|
+
"location": "global",
|
|
3978
|
+
"id": "global::SVGElement"
|
|
3979
|
+
}
|
|
3980
|
+
},
|
|
3981
|
+
"return": "Promise<KritzelBaseObject<HTMLElement | SVGElement>[]>"
|
|
3982
|
+
},
|
|
3983
|
+
"docs": {
|
|
3984
|
+
"text": "",
|
|
3985
|
+
"tags": []
|
|
3986
|
+
}
|
|
3987
|
+
},
|
|
3988
|
+
"hideContextMenu": {
|
|
3989
|
+
"complexType": {
|
|
3990
|
+
"signature": "() => Promise<void>",
|
|
3991
|
+
"parameters": [],
|
|
3992
|
+
"references": {
|
|
3993
|
+
"Promise": {
|
|
3994
|
+
"location": "global",
|
|
3995
|
+
"id": "global::Promise"
|
|
3996
|
+
}
|
|
3997
|
+
},
|
|
3998
|
+
"return": "Promise<void>"
|
|
3999
|
+
},
|
|
4000
|
+
"docs": {
|
|
4001
|
+
"text": "",
|
|
4002
|
+
"tags": []
|
|
4003
|
+
}
|
|
4004
|
+
},
|
|
4005
|
+
"openContextMenu": {
|
|
4006
|
+
"complexType": {
|
|
4007
|
+
"signature": "(options: { x: number; y: number; objectId?: string; }) => Promise<void>",
|
|
4008
|
+
"parameters": [{
|
|
4009
|
+
"name": "options",
|
|
4010
|
+
"type": "{ x: number; y: number; objectId?: string; }",
|
|
4011
|
+
"docs": ""
|
|
4012
|
+
}],
|
|
4013
|
+
"references": {
|
|
4014
|
+
"Promise": {
|
|
4015
|
+
"location": "global",
|
|
4016
|
+
"id": "global::Promise"
|
|
4017
|
+
}
|
|
4018
|
+
},
|
|
4019
|
+
"return": "Promise<void>"
|
|
4020
|
+
},
|
|
4021
|
+
"docs": {
|
|
4022
|
+
"text": "",
|
|
4023
|
+
"tags": []
|
|
4024
|
+
}
|
|
4025
|
+
},
|
|
4026
|
+
"openWorkspaceManagerMenu": {
|
|
4027
|
+
"complexType": {
|
|
4028
|
+
"signature": "() => Promise<void>",
|
|
4029
|
+
"parameters": [],
|
|
4030
|
+
"references": {
|
|
4031
|
+
"Promise": {
|
|
4032
|
+
"location": "global",
|
|
4033
|
+
"id": "global::Promise"
|
|
4034
|
+
}
|
|
4035
|
+
},
|
|
4036
|
+
"return": "Promise<void>"
|
|
4037
|
+
},
|
|
4038
|
+
"docs": {
|
|
4039
|
+
"text": "",
|
|
4040
|
+
"tags": []
|
|
4041
|
+
}
|
|
4042
|
+
},
|
|
4043
|
+
"closeWorkspaceManagerMenu": {
|
|
4044
|
+
"complexType": {
|
|
4045
|
+
"signature": "() => Promise<void>",
|
|
4046
|
+
"parameters": [],
|
|
4047
|
+
"references": {
|
|
4048
|
+
"Promise": {
|
|
4049
|
+
"location": "global",
|
|
4050
|
+
"id": "global::Promise"
|
|
4051
|
+
}
|
|
4052
|
+
},
|
|
4053
|
+
"return": "Promise<void>"
|
|
4054
|
+
},
|
|
4055
|
+
"docs": {
|
|
4056
|
+
"text": "",
|
|
4057
|
+
"tags": []
|
|
4058
|
+
}
|
|
4059
|
+
},
|
|
4060
|
+
"openMoreMenu": {
|
|
4061
|
+
"complexType": {
|
|
4062
|
+
"signature": "() => Promise<void>",
|
|
4063
|
+
"parameters": [],
|
|
4064
|
+
"references": {
|
|
4065
|
+
"Promise": {
|
|
4066
|
+
"location": "global",
|
|
4067
|
+
"id": "global::Promise"
|
|
4068
|
+
}
|
|
4069
|
+
},
|
|
4070
|
+
"return": "Promise<void>"
|
|
4071
|
+
},
|
|
4072
|
+
"docs": {
|
|
4073
|
+
"text": "",
|
|
4074
|
+
"tags": []
|
|
4075
|
+
}
|
|
4076
|
+
},
|
|
4077
|
+
"closeMoreMenu": {
|
|
4078
|
+
"complexType": {
|
|
4079
|
+
"signature": "() => Promise<void>",
|
|
4080
|
+
"parameters": [],
|
|
4081
|
+
"references": {
|
|
4082
|
+
"Promise": {
|
|
4083
|
+
"location": "global",
|
|
4084
|
+
"id": "global::Promise"
|
|
4085
|
+
}
|
|
4086
|
+
},
|
|
4087
|
+
"return": "Promise<void>"
|
|
4088
|
+
},
|
|
4089
|
+
"docs": {
|
|
4090
|
+
"text": "",
|
|
4091
|
+
"tags": []
|
|
4092
|
+
}
|
|
4093
|
+
},
|
|
4094
|
+
"openUserDialog": {
|
|
4095
|
+
"complexType": {
|
|
4096
|
+
"signature": "() => Promise<void>",
|
|
4097
|
+
"parameters": [],
|
|
4098
|
+
"references": {
|
|
4099
|
+
"Promise": {
|
|
4100
|
+
"location": "global",
|
|
4101
|
+
"id": "global::Promise"
|
|
4102
|
+
}
|
|
4103
|
+
},
|
|
4104
|
+
"return": "Promise<void>"
|
|
4105
|
+
},
|
|
4106
|
+
"docs": {
|
|
4107
|
+
"text": "",
|
|
4108
|
+
"tags": []
|
|
4109
|
+
}
|
|
4110
|
+
},
|
|
4111
|
+
"closeUserDialog": {
|
|
4112
|
+
"complexType": {
|
|
4113
|
+
"signature": "() => Promise<void>",
|
|
4114
|
+
"parameters": [],
|
|
4115
|
+
"references": {
|
|
4116
|
+
"Promise": {
|
|
4117
|
+
"location": "global",
|
|
4118
|
+
"id": "global::Promise"
|
|
4119
|
+
}
|
|
4120
|
+
},
|
|
4121
|
+
"return": "Promise<void>"
|
|
4122
|
+
},
|
|
4123
|
+
"docs": {
|
|
4124
|
+
"text": "",
|
|
4125
|
+
"tags": []
|
|
4126
|
+
}
|
|
4127
|
+
},
|
|
4128
|
+
"openExportDialog": {
|
|
4129
|
+
"complexType": {
|
|
4130
|
+
"signature": "() => Promise<void>",
|
|
4131
|
+
"parameters": [],
|
|
4132
|
+
"references": {
|
|
4133
|
+
"Promise": {
|
|
4134
|
+
"location": "global",
|
|
4135
|
+
"id": "global::Promise"
|
|
4136
|
+
}
|
|
4137
|
+
},
|
|
4138
|
+
"return": "Promise<void>"
|
|
4139
|
+
},
|
|
4140
|
+
"docs": {
|
|
4141
|
+
"text": "",
|
|
4142
|
+
"tags": []
|
|
4143
|
+
}
|
|
4144
|
+
},
|
|
4145
|
+
"closeExportDialog": {
|
|
4146
|
+
"complexType": {
|
|
4147
|
+
"signature": "() => Promise<void>",
|
|
4148
|
+
"parameters": [],
|
|
4149
|
+
"references": {
|
|
4150
|
+
"Promise": {
|
|
4151
|
+
"location": "global",
|
|
4152
|
+
"id": "global::Promise"
|
|
4153
|
+
}
|
|
4154
|
+
},
|
|
4155
|
+
"return": "Promise<void>"
|
|
4156
|
+
},
|
|
4157
|
+
"docs": {
|
|
4158
|
+
"text": "",
|
|
4159
|
+
"tags": []
|
|
4160
|
+
}
|
|
4161
|
+
},
|
|
4162
|
+
"openImportDialog": {
|
|
4163
|
+
"complexType": {
|
|
4164
|
+
"signature": "() => Promise<void>",
|
|
4165
|
+
"parameters": [],
|
|
4166
|
+
"references": {
|
|
4167
|
+
"Promise": {
|
|
4168
|
+
"location": "global",
|
|
4169
|
+
"id": "global::Promise"
|
|
4170
|
+
}
|
|
4171
|
+
},
|
|
4172
|
+
"return": "Promise<void>"
|
|
4173
|
+
},
|
|
4174
|
+
"docs": {
|
|
4175
|
+
"text": "",
|
|
4176
|
+
"tags": []
|
|
4177
|
+
}
|
|
4178
|
+
},
|
|
4179
|
+
"closeImportDialog": {
|
|
4180
|
+
"complexType": {
|
|
4181
|
+
"signature": "() => Promise<void>",
|
|
4182
|
+
"parameters": [],
|
|
4183
|
+
"references": {
|
|
4184
|
+
"Promise": {
|
|
4185
|
+
"location": "global",
|
|
4186
|
+
"id": "global::Promise"
|
|
4187
|
+
}
|
|
4188
|
+
},
|
|
4189
|
+
"return": "Promise<void>"
|
|
4190
|
+
},
|
|
4191
|
+
"docs": {
|
|
4192
|
+
"text": "",
|
|
4193
|
+
"tags": []
|
|
4194
|
+
}
|
|
4195
|
+
},
|
|
4196
|
+
"openSettingsDialog": {
|
|
4197
|
+
"complexType": {
|
|
4198
|
+
"signature": "() => Promise<void>",
|
|
4199
|
+
"parameters": [],
|
|
4200
|
+
"references": {
|
|
4201
|
+
"Promise": {
|
|
4202
|
+
"location": "global",
|
|
4203
|
+
"id": "global::Promise"
|
|
4204
|
+
}
|
|
4205
|
+
},
|
|
4206
|
+
"return": "Promise<void>"
|
|
4207
|
+
},
|
|
4208
|
+
"docs": {
|
|
4209
|
+
"text": "",
|
|
4210
|
+
"tags": []
|
|
4211
|
+
}
|
|
4212
|
+
},
|
|
4213
|
+
"closeSettingsDialog": {
|
|
4214
|
+
"complexType": {
|
|
4215
|
+
"signature": "() => Promise<void>",
|
|
4216
|
+
"parameters": [],
|
|
4217
|
+
"references": {
|
|
4218
|
+
"Promise": {
|
|
4219
|
+
"location": "global",
|
|
4220
|
+
"id": "global::Promise"
|
|
4221
|
+
}
|
|
4222
|
+
},
|
|
4223
|
+
"return": "Promise<void>"
|
|
4224
|
+
},
|
|
4225
|
+
"docs": {
|
|
4226
|
+
"text": "",
|
|
4227
|
+
"tags": []
|
|
4228
|
+
}
|
|
4229
|
+
},
|
|
4230
|
+
"openShareDialog": {
|
|
4231
|
+
"complexType": {
|
|
4232
|
+
"signature": "() => Promise<void>",
|
|
4233
|
+
"parameters": [],
|
|
4234
|
+
"references": {
|
|
4235
|
+
"Promise": {
|
|
4236
|
+
"location": "global",
|
|
4237
|
+
"id": "global::Promise"
|
|
4238
|
+
}
|
|
4239
|
+
},
|
|
4240
|
+
"return": "Promise<void>"
|
|
4241
|
+
},
|
|
4242
|
+
"docs": {
|
|
4243
|
+
"text": "",
|
|
4244
|
+
"tags": []
|
|
4245
|
+
}
|
|
4246
|
+
},
|
|
4247
|
+
"closeShareDialog": {
|
|
4248
|
+
"complexType": {
|
|
4249
|
+
"signature": "() => Promise<void>",
|
|
4250
|
+
"parameters": [],
|
|
4251
|
+
"references": {
|
|
4252
|
+
"Promise": {
|
|
4253
|
+
"location": "global",
|
|
4254
|
+
"id": "global::Promise"
|
|
4255
|
+
}
|
|
4256
|
+
},
|
|
4257
|
+
"return": "Promise<void>"
|
|
4258
|
+
},
|
|
4259
|
+
"docs": {
|
|
4260
|
+
"text": "",
|
|
4261
|
+
"tags": []
|
|
4262
|
+
}
|
|
4263
|
+
},
|
|
4264
|
+
"triggerSelectionChange": {
|
|
4265
|
+
"complexType": {
|
|
4266
|
+
"signature": "() => Promise<void>",
|
|
4267
|
+
"parameters": [],
|
|
4268
|
+
"references": {
|
|
4269
|
+
"Promise": {
|
|
4270
|
+
"location": "global",
|
|
4271
|
+
"id": "global::Promise"
|
|
4272
|
+
}
|
|
4273
|
+
},
|
|
4274
|
+
"return": "Promise<void>"
|
|
4275
|
+
},
|
|
4276
|
+
"docs": {
|
|
4277
|
+
"text": "",
|
|
4278
|
+
"tags": []
|
|
4279
|
+
}
|
|
4280
|
+
},
|
|
4281
|
+
"beginSceneBootstrap": {
|
|
4282
|
+
"complexType": {
|
|
4283
|
+
"signature": "() => Promise<void>",
|
|
4284
|
+
"parameters": [],
|
|
4285
|
+
"references": {
|
|
4286
|
+
"Promise": {
|
|
4287
|
+
"location": "global",
|
|
4288
|
+
"id": "global::Promise"
|
|
4289
|
+
}
|
|
4290
|
+
},
|
|
4291
|
+
"return": "Promise<void>"
|
|
4292
|
+
},
|
|
4293
|
+
"docs": {
|
|
4294
|
+
"text": "",
|
|
4295
|
+
"tags": []
|
|
4296
|
+
}
|
|
4297
|
+
},
|
|
4298
|
+
"endSceneBootstrap": {
|
|
4299
|
+
"complexType": {
|
|
4300
|
+
"signature": "() => Promise<void>",
|
|
4301
|
+
"parameters": [],
|
|
4302
|
+
"references": {
|
|
4303
|
+
"Promise": {
|
|
4304
|
+
"location": "global",
|
|
4305
|
+
"id": "global::Promise"
|
|
4306
|
+
}
|
|
4307
|
+
},
|
|
4308
|
+
"return": "Promise<void>"
|
|
4309
|
+
},
|
|
4310
|
+
"docs": {
|
|
4311
|
+
"text": "",
|
|
4312
|
+
"tags": []
|
|
4313
|
+
}
|
|
4314
|
+
},
|
|
4315
|
+
"getDisplayableShortcuts": {
|
|
4316
|
+
"complexType": {
|
|
4317
|
+
"signature": "() => Promise<Omit<KritzelShortcut, \"action\" | \"condition\">[]>",
|
|
4318
|
+
"parameters": [],
|
|
4319
|
+
"references": {
|
|
4320
|
+
"Promise": {
|
|
4321
|
+
"location": "global",
|
|
4322
|
+
"id": "global::Promise"
|
|
4323
|
+
},
|
|
4324
|
+
"Omit": {
|
|
4325
|
+
"location": "global",
|
|
4326
|
+
"id": "global::Omit"
|
|
4327
|
+
},
|
|
4328
|
+
"KritzelShortcut": {
|
|
4329
|
+
"location": "import",
|
|
4330
|
+
"path": "@kritzel/engine",
|
|
4331
|
+
"id": "../../engine/core/dist/types/index.d.ts::KritzelShortcut",
|
|
4332
|
+
"referenceLocation": "KritzelShortcut"
|
|
4333
|
+
}
|
|
4334
|
+
},
|
|
4335
|
+
"return": "Promise<Omit<KritzelShortcut, \"action\" | \"condition\">[]>"
|
|
4336
|
+
},
|
|
4337
|
+
"docs": {
|
|
4338
|
+
"text": "",
|
|
4339
|
+
"tags": []
|
|
4340
|
+
}
|
|
4341
|
+
},
|
|
4342
|
+
"openLoginDialog": {
|
|
4343
|
+
"complexType": {
|
|
4344
|
+
"signature": "() => Promise<void>",
|
|
4345
|
+
"parameters": [],
|
|
4346
|
+
"references": {
|
|
4347
|
+
"Promise": {
|
|
4348
|
+
"location": "global",
|
|
4349
|
+
"id": "global::Promise"
|
|
4350
|
+
}
|
|
4351
|
+
},
|
|
4352
|
+
"return": "Promise<void>"
|
|
4353
|
+
},
|
|
4354
|
+
"docs": {
|
|
4355
|
+
"text": "",
|
|
4356
|
+
"tags": []
|
|
4357
|
+
}
|
|
4358
|
+
},
|
|
4359
|
+
"closeLoginDialog": {
|
|
4360
|
+
"complexType": {
|
|
4361
|
+
"signature": "() => Promise<void>",
|
|
4362
|
+
"parameters": [],
|
|
4363
|
+
"references": {
|
|
4364
|
+
"Promise": {
|
|
4365
|
+
"location": "global",
|
|
4366
|
+
"id": "global::Promise"
|
|
4367
|
+
}
|
|
4368
|
+
},
|
|
4369
|
+
"return": "Promise<void>"
|
|
4370
|
+
},
|
|
4371
|
+
"docs": {
|
|
4372
|
+
"text": "",
|
|
4373
|
+
"tags": []
|
|
4374
|
+
}
|
|
4375
|
+
},
|
|
4376
|
+
"setLoginLoading": {
|
|
4377
|
+
"complexType": {
|
|
4378
|
+
"signature": "(provider: string | null) => Promise<void>",
|
|
4379
|
+
"parameters": [{
|
|
4380
|
+
"name": "provider",
|
|
4381
|
+
"type": "string",
|
|
4382
|
+
"docs": ""
|
|
4383
|
+
}],
|
|
4384
|
+
"references": {
|
|
4385
|
+
"Promise": {
|
|
4386
|
+
"location": "global",
|
|
4387
|
+
"id": "global::Promise"
|
|
4388
|
+
}
|
|
4389
|
+
},
|
|
4390
|
+
"return": "Promise<void>"
|
|
4391
|
+
},
|
|
4392
|
+
"docs": {
|
|
4393
|
+
"text": "",
|
|
4394
|
+
"tags": []
|
|
4395
|
+
}
|
|
4396
|
+
},
|
|
4397
|
+
"setLocale": {
|
|
4398
|
+
"complexType": {
|
|
4399
|
+
"signature": "(code: LocaleCode) => Promise<void>",
|
|
4400
|
+
"parameters": [{
|
|
4401
|
+
"name": "code",
|
|
4402
|
+
"type": "(string & {}) | \"en\" | \"de\" | \"fr\"",
|
|
4403
|
+
"docs": "- The locale code to activate, e.g. 'de'."
|
|
4404
|
+
}],
|
|
4405
|
+
"references": {
|
|
4406
|
+
"Promise": {
|
|
4407
|
+
"location": "global",
|
|
4408
|
+
"id": "global::Promise"
|
|
4409
|
+
},
|
|
4410
|
+
"LocaleCode": {
|
|
4411
|
+
"location": "import",
|
|
4412
|
+
"path": "@kritzel/engine",
|
|
4413
|
+
"id": "../../engine/core/dist/types/index.d.ts::LocaleCode",
|
|
4414
|
+
"referenceLocation": "LocaleCode"
|
|
4415
|
+
}
|
|
4416
|
+
},
|
|
4417
|
+
"return": "Promise<void>"
|
|
4418
|
+
},
|
|
4419
|
+
"docs": {
|
|
4420
|
+
"text": "Sets the active locale (language) and re-renders the UI.",
|
|
4421
|
+
"tags": [{
|
|
4422
|
+
"name": "param",
|
|
4423
|
+
"text": "code - The locale code to activate, e.g. 'de'."
|
|
4424
|
+
}]
|
|
4425
|
+
}
|
|
4426
|
+
},
|
|
4427
|
+
"getLocale": {
|
|
4428
|
+
"complexType": {
|
|
4429
|
+
"signature": "() => Promise<LocaleCode>",
|
|
4430
|
+
"parameters": [],
|
|
4431
|
+
"references": {
|
|
4432
|
+
"Promise": {
|
|
4433
|
+
"location": "global",
|
|
4434
|
+
"id": "global::Promise"
|
|
4435
|
+
},
|
|
4436
|
+
"LocaleCode": {
|
|
4437
|
+
"location": "import",
|
|
4438
|
+
"path": "@kritzel/engine",
|
|
4439
|
+
"id": "../../engine/core/dist/types/index.d.ts::LocaleCode",
|
|
4440
|
+
"referenceLocation": "LocaleCode"
|
|
4441
|
+
}
|
|
4442
|
+
},
|
|
4443
|
+
"return": "Promise<LocaleCode>"
|
|
4444
|
+
},
|
|
4445
|
+
"docs": {
|
|
4446
|
+
"text": "Gets the currently active locale code.",
|
|
4447
|
+
"tags": []
|
|
4448
|
+
}
|
|
4449
|
+
},
|
|
4450
|
+
"getAvailableLocales": {
|
|
4451
|
+
"complexType": {
|
|
4452
|
+
"signature": "() => Promise<LocaleCode[]>",
|
|
4453
|
+
"parameters": [],
|
|
4454
|
+
"references": {
|
|
4455
|
+
"Promise": {
|
|
4456
|
+
"location": "global",
|
|
4457
|
+
"id": "global::Promise"
|
|
4458
|
+
},
|
|
4459
|
+
"LocaleCode": {
|
|
4460
|
+
"location": "import",
|
|
4461
|
+
"path": "@kritzel/engine",
|
|
4462
|
+
"id": "../../engine/core/dist/types/index.d.ts::LocaleCode",
|
|
4463
|
+
"referenceLocation": "LocaleCode"
|
|
4464
|
+
}
|
|
4465
|
+
},
|
|
4466
|
+
"return": "Promise<LocaleCode[]>"
|
|
4467
|
+
},
|
|
4468
|
+
"docs": {
|
|
4469
|
+
"text": "Gets the list of available locale codes (built-in and registered).",
|
|
4470
|
+
"tags": []
|
|
4471
|
+
}
|
|
4472
|
+
},
|
|
4473
|
+
"registerLocales": {
|
|
4474
|
+
"complexType": {
|
|
4475
|
+
"signature": "(locales: KritzelLocale[]) => Promise<void>",
|
|
4476
|
+
"parameters": [{
|
|
4477
|
+
"name": "locales",
|
|
4478
|
+
"type": "KritzelLocale[]",
|
|
4479
|
+
"docs": "- The locale definitions to register."
|
|
4480
|
+
}],
|
|
4481
|
+
"references": {
|
|
4482
|
+
"Promise": {
|
|
4483
|
+
"location": "global",
|
|
4484
|
+
"id": "global::Promise"
|
|
4485
|
+
},
|
|
4486
|
+
"KritzelLocale": {
|
|
4487
|
+
"location": "import",
|
|
4488
|
+
"path": "@kritzel/engine",
|
|
4489
|
+
"id": "../../engine/core/dist/types/index.d.ts::KritzelLocale",
|
|
4490
|
+
"referenceLocation": "KritzelLocale"
|
|
4491
|
+
}
|
|
4492
|
+
},
|
|
4493
|
+
"return": "Promise<void>"
|
|
4494
|
+
},
|
|
4495
|
+
"docs": {
|
|
4496
|
+
"text": "Registers additional locale definitions (with optional partial term overrides).",
|
|
4497
|
+
"tags": [{
|
|
4498
|
+
"name": "param",
|
|
4499
|
+
"text": "locales - The locale definitions to register."
|
|
4500
|
+
}]
|
|
4501
|
+
}
|
|
4502
|
+
},
|
|
4503
|
+
"registerFonts": {
|
|
4504
|
+
"complexType": {
|
|
4505
|
+
"signature": "(fonts: KritzelFontMap) => Promise<void>",
|
|
4506
|
+
"parameters": [{
|
|
4507
|
+
"name": "fonts",
|
|
4508
|
+
"type": "{ [x: string]: KritzelFontRegistration; }",
|
|
4509
|
+
"docs": "- Mapping from font keys to family names or font definitions."
|
|
4510
|
+
}],
|
|
4511
|
+
"references": {
|
|
4512
|
+
"Promise": {
|
|
4513
|
+
"location": "global",
|
|
4514
|
+
"id": "global::Promise"
|
|
4515
|
+
},
|
|
4516
|
+
"KritzelFontMap": {
|
|
4517
|
+
"location": "import",
|
|
4518
|
+
"path": "@kritzel/engine",
|
|
4519
|
+
"id": "../../engine/core/dist/types/index.d.ts::KritzelFontMap",
|
|
4520
|
+
"referenceLocation": "KritzelFontMap"
|
|
4521
|
+
}
|
|
4522
|
+
},
|
|
4523
|
+
"return": "Promise<void>"
|
|
4524
|
+
},
|
|
4525
|
+
"docs": {
|
|
4526
|
+
"text": "Registers custom fonts for the editor runtime.",
|
|
4527
|
+
"tags": [{
|
|
4528
|
+
"name": "param",
|
|
4529
|
+
"text": "fonts - Mapping from font keys to family names or font definitions."
|
|
4530
|
+
}, {
|
|
4531
|
+
"name": "remarks",
|
|
4532
|
+
"text": "This no longer controls the text-tool config tooltip font options.\r\nConfigure tooltip fonts via toolbarItems[].config.availableFonts."
|
|
4533
|
+
}]
|
|
4534
|
+
}
|
|
4535
|
+
},
|
|
4536
|
+
"t": {
|
|
4537
|
+
"complexType": {
|
|
4538
|
+
"signature": "(key: KritzelTermKey, vars?: KritzelTermVars) => Promise<string>",
|
|
4539
|
+
"parameters": [{
|
|
4540
|
+
"name": "key",
|
|
4541
|
+
"type": "keyof KritzelTerms",
|
|
4542
|
+
"docs": "- The term key to resolve."
|
|
4543
|
+
}, {
|
|
4544
|
+
"name": "vars",
|
|
4545
|
+
"type": "{ [x: string]: string | number; }",
|
|
4546
|
+
"docs": "- Optional values for `{placeholder}` interpolation."
|
|
4547
|
+
}],
|
|
4548
|
+
"references": {
|
|
4549
|
+
"Promise": {
|
|
4550
|
+
"location": "global",
|
|
4551
|
+
"id": "global::Promise"
|
|
4552
|
+
},
|
|
4553
|
+
"KritzelTermKey": {
|
|
4554
|
+
"location": "import",
|
|
4555
|
+
"path": "@kritzel/engine",
|
|
4556
|
+
"id": "../../engine/core/dist/types/index.d.ts::KritzelTermKey",
|
|
4557
|
+
"referenceLocation": "KritzelTermKey"
|
|
4558
|
+
},
|
|
4559
|
+
"KritzelTermVars": {
|
|
4560
|
+
"location": "import",
|
|
4561
|
+
"path": "@kritzel/engine",
|
|
4562
|
+
"id": "../../engine/core/dist/types/index.d.ts::KritzelTermVars",
|
|
4563
|
+
"referenceLocation": "KritzelTermVars"
|
|
4564
|
+
}
|
|
4565
|
+
},
|
|
4566
|
+
"return": "Promise<string>"
|
|
4567
|
+
},
|
|
4568
|
+
"docs": {
|
|
4569
|
+
"text": "Resolves a term key to its translated string for the active locale.",
|
|
4570
|
+
"tags": [{
|
|
4571
|
+
"name": "param",
|
|
4572
|
+
"text": "key - The term key to resolve."
|
|
4573
|
+
}, {
|
|
4574
|
+
"name": "param",
|
|
4575
|
+
"text": "vars - Optional values for `{placeholder}` interpolation."
|
|
4576
|
+
}]
|
|
4577
|
+
}
|
|
4578
|
+
},
|
|
4579
|
+
"triggerNotification": {
|
|
4580
|
+
"complexType": {
|
|
4581
|
+
"signature": "(notification: Omit<KritzelNotification, \"id\"> & Partial<Pick<KritzelNotification, \"id\" | \"timestamp\">>) => Promise<void>",
|
|
4582
|
+
"parameters": [{
|
|
4583
|
+
"name": "notification",
|
|
4584
|
+
"type": "Omit<KritzelNotification, \"id\"> & Partial<Pick<KritzelNotification, \"id\" | \"timestamp\">>",
|
|
4585
|
+
"docs": "- Notification payload. `id` and `timestamp` are optional."
|
|
4586
|
+
}],
|
|
4587
|
+
"references": {
|
|
4588
|
+
"Promise": {
|
|
4589
|
+
"location": "global",
|
|
4590
|
+
"id": "global::Promise"
|
|
4591
|
+
},
|
|
4592
|
+
"Omit": {
|
|
4593
|
+
"location": "global",
|
|
4594
|
+
"id": "global::Omit"
|
|
4595
|
+
},
|
|
4596
|
+
"KritzelNotification": {
|
|
4597
|
+
"location": "import",
|
|
4598
|
+
"path": "@kritzel/engine",
|
|
4599
|
+
"id": "../../engine/core/dist/types/index.d.ts::KritzelNotification",
|
|
4600
|
+
"referenceLocation": "KritzelNotification"
|
|
4601
|
+
},
|
|
4602
|
+
"Partial": {
|
|
4603
|
+
"location": "global",
|
|
4604
|
+
"id": "global::Partial"
|
|
4605
|
+
},
|
|
4606
|
+
"Pick": {
|
|
4607
|
+
"location": "global",
|
|
4608
|
+
"id": "global::Pick"
|
|
4609
|
+
}
|
|
4610
|
+
},
|
|
4611
|
+
"return": "Promise<void>"
|
|
4612
|
+
},
|
|
4613
|
+
"docs": {
|
|
4614
|
+
"text": "Triggers a UI notification programmatically.",
|
|
4615
|
+
"tags": [{
|
|
4616
|
+
"name": "param",
|
|
4617
|
+
"text": "notification - Notification payload. `id` and `timestamp` are optional."
|
|
4618
|
+
}]
|
|
4619
|
+
}
|
|
4620
|
+
}
|
|
4621
|
+
};
|
|
4622
|
+
}
|
|
4623
|
+
static get elementRef() { return "host"; }
|
|
4624
|
+
static get watchers() {
|
|
4625
|
+
return [{
|
|
4626
|
+
"propName": "isEngineReady",
|
|
4627
|
+
"methodName": "onIsEngineReady"
|
|
4628
|
+
}, {
|
|
4629
|
+
"propName": "isToolbarReady",
|
|
4630
|
+
"methodName": "onIsToolbarReady"
|
|
4631
|
+
}, {
|
|
4632
|
+
"propName": "availableWorkspaces",
|
|
4633
|
+
"methodName": "onAvailableWorkspacesChange"
|
|
4634
|
+
}, {
|
|
4635
|
+
"propName": "activeWorkspace",
|
|
4636
|
+
"methodName": "onActiveWorkspaceChange"
|
|
4637
|
+
}, {
|
|
4638
|
+
"propName": "customFonts",
|
|
4639
|
+
"methodName": "onCustomFontsChange"
|
|
4640
|
+
}, {
|
|
4641
|
+
"propName": "moreMenuItems",
|
|
4642
|
+
"methodName": "onMoreMenuItemsChange"
|
|
4643
|
+
}, {
|
|
4644
|
+
"propName": "syncConfig",
|
|
4645
|
+
"methodName": "onSyncConfigChange"
|
|
4646
|
+
}, {
|
|
4647
|
+
"propName": "loginConfig",
|
|
4648
|
+
"methodName": "onLoginConfigChange"
|
|
4649
|
+
}, {
|
|
4650
|
+
"propName": "user",
|
|
4651
|
+
"methodName": "onUserChange"
|
|
4652
|
+
}, {
|
|
4653
|
+
"propName": "activeWorkspaceId",
|
|
4654
|
+
"methodName": "onActiveWorkspaceIdChange"
|
|
4655
|
+
}, {
|
|
4656
|
+
"propName": "theme",
|
|
4657
|
+
"methodName": "onCurrentThemeChange"
|
|
4658
|
+
}, {
|
|
4659
|
+
"propName": "themes",
|
|
4660
|
+
"methodName": "onThemesChange"
|
|
4661
|
+
}, {
|
|
4662
|
+
"propName": "locale",
|
|
4663
|
+
"methodName": "onLocaleChange"
|
|
4664
|
+
}, {
|
|
4665
|
+
"propName": "locales",
|
|
4666
|
+
"methodName": "onLocalesChange"
|
|
4667
|
+
}];
|
|
4668
|
+
}
|
|
4669
|
+
static get listeners() {
|
|
4670
|
+
return [{
|
|
4671
|
+
"name": "dblclick",
|
|
4672
|
+
"method": "onTouchStart",
|
|
4673
|
+
"target": undefined,
|
|
4674
|
+
"capture": false,
|
|
4675
|
+
"passive": false
|
|
4676
|
+
}];
|
|
4677
|
+
}
|
|
4678
|
+
}
|