@ecsplico/editor 0.0.0-stage → 2.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +19 -0
- package/LICENSE +21 -0
- package/README.md +232 -2
- package/dist/code/CodeSurface.d.ts +24 -0
- package/dist/code/CodeSurface.js +57 -0
- package/dist/code/CodeSurface.js.map +1 -0
- package/dist/code/CodeSurface.vue.d.ts +29 -0
- package/dist/code/CodeSurface2.js +75 -0
- package/dist/code/CodeSurface2.js.map +1 -0
- package/dist/code/chrome-theme.js +76 -0
- package/dist/code/chrome-theme.js.map +1 -0
- package/dist/code/compartments.js +19 -0
- package/dist/code/compartments.js.map +1 -0
- package/dist/code/editor-factory.d.ts +41 -0
- package/dist/code/editor-factory.js +126 -0
- package/dist/code/editor-factory.js.map +1 -0
- package/dist/code/format-json.d.ts +27 -0
- package/dist/code/format-json.js +94 -0
- package/dist/code/format-json.js.map +1 -0
- package/dist/code/highlight-style.js +118 -0
- package/dist/code/highlight-style.js.map +1 -0
- package/dist/code/index.d.ts +6 -0
- package/dist/code/index.js +6 -0
- package/dist/code/jsonl-language.d.ts +6 -0
- package/dist/code/jsonl-language.js +33 -0
- package/dist/code/jsonl-language.js.map +1 -0
- package/dist/code/kind.d.ts +15 -0
- package/dist/code/kind.js +142 -0
- package/dist/code/kind.js.map +1 -0
- package/dist/code/lang-registry.d.ts +31 -0
- package/dist/code/lang-registry.js +54 -0
- package/dist/code/lang-registry.js.map +1 -0
- package/dist/code/react.d.ts +2 -0
- package/dist/code/react.js +1 -0
- package/dist/code/vue.d.ts +2 -0
- package/dist/code/vue.js +1 -0
- package/dist/core/abilities.d.ts +32 -0
- package/dist/core/abilities.js +160 -0
- package/dist/core/abilities.js.map +1 -0
- package/dist/core/block-convert.d.ts +59 -0
- package/dist/core/block-convert.js +164 -0
- package/dist/core/block-convert.js.map +1 -0
- package/dist/core/block-drag.d.ts +12 -0
- package/dist/core/block-drag.js +62 -0
- package/dist/core/block-drag.js.map +1 -0
- package/dist/core/block-flash.d.ts +19 -0
- package/dist/core/block-flash.js +66 -0
- package/dist/core/block-flash.js.map +1 -0
- package/dist/core/context.d.ts +63 -0
- package/dist/core/context.js +108 -0
- package/dist/core/context.js.map +1 -0
- package/dist/core/convert.d.ts +96 -0
- package/dist/core/convert.js +241 -0
- package/dist/core/convert.js.map +1 -0
- package/dist/core/core-feature.d.ts +17 -0
- package/dist/core/core-feature.js +100 -0
- package/dist/core/core-feature.js.map +1 -0
- package/dist/core/define-editor.d.ts +23 -0
- package/dist/core/define-editor.js +110 -0
- package/dist/core/define-editor.js.map +1 -0
- package/dist/core/doc-anchors.d.ts +67 -0
- package/dist/core/doc-anchors.js +112 -0
- package/dist/core/doc-anchors.js.map +1 -0
- package/dist/core/document-markdown.d.ts +13 -0
- package/dist/core/document-markdown.js +31 -0
- package/dist/core/document-markdown.js.map +1 -0
- package/dist/core/download.d.ts +5 -0
- package/dist/core/download.js +16 -0
- package/dist/core/download.js.map +1 -0
- package/dist/core/editor-ui.d.ts +45 -0
- package/dist/core/editor-ui.js +38 -0
- package/dist/core/editor-ui.js.map +1 -0
- package/dist/core/extension-points.d.ts +64 -0
- package/dist/core/feature-context.d.ts +32 -0
- package/dist/core/feature-context.js +46 -0
- package/dist/core/feature-context.js.map +1 -0
- package/dist/core/feature.d.ts +234 -0
- package/dist/core/feature.js +13 -0
- package/dist/core/feature.js.map +1 -0
- package/dist/core/fences.d.ts +16 -0
- package/dist/core/fences.js +105 -0
- package/dist/core/fences.js.map +1 -0
- package/dist/core/fetch-error.d.ts +5 -0
- package/dist/core/fetch-error.js +11 -0
- package/dist/core/fetch-error.js.map +1 -0
- package/dist/core/index.d.ts +28 -0
- package/dist/core/index.js +27 -0
- package/dist/core/metadata-types.d.ts +27 -0
- package/dist/core/metadata-types.js +10 -0
- package/dist/core/metadata-types.js.map +1 -0
- package/dist/core/metadata.d.ts +39 -0
- package/dist/core/metadata.js +76 -0
- package/dist/core/metadata.js.map +1 -0
- package/dist/core/notify.d.ts +31 -0
- package/dist/core/notify.js +7 -0
- package/dist/core/notify.js.map +1 -0
- package/dist/core/pipeline.d.ts +52 -0
- package/dist/core/pipeline.js +78 -0
- package/dist/core/pipeline.js.map +1 -0
- package/dist/core/schema/abilities.d.ts +55 -0
- package/dist/core/schema/abilities.js +113 -0
- package/dist/core/schema/abilities.js.map +1 -0
- package/dist/core/schema/block-ids.d.ts +29 -0
- package/dist/core/schema/block-ids.js +134 -0
- package/dist/core/schema/block-ids.js.map +1 -0
- package/dist/core/schema/hex-color.d.ts +5 -0
- package/dist/core/schema/hex-color.js +7 -0
- package/dist/core/schema/hex-color.js.map +1 -0
- package/dist/core/schema/index.d.ts +21 -0
- package/dist/core/schema/index.js +33 -0
- package/dist/core/schema/index.js.map +1 -0
- package/dist/core/schema/mark-flags.d.ts +12 -0
- package/dist/core/schema/node-flags.d.ts +23 -0
- package/dist/core/schema/node-flags.js +34 -0
- package/dist/core/schema/node-flags.js.map +1 -0
- package/dist/core/schema/opaque-fence.d.ts +11 -0
- package/dist/core/schema/opaque-fence.js +57 -0
- package/dist/core/schema/opaque-fence.js.map +1 -0
- package/dist/core/schema/strike.d.ts +4 -0
- package/dist/core/schema/strike.js +9 -0
- package/dist/core/schema/strike.js.map +1 -0
- package/dist/core/selection-range.d.ts +13 -0
- package/dist/core/selection-range.js +28 -0
- package/dist/core/selection-range.js.map +1 -0
- package/dist/core/slash.d.ts +24 -0
- package/dist/core/slash.js +60 -0
- package/dist/core/slash.js.map +1 -0
- package/dist/core/store.d.ts +22 -0
- package/dist/core/store.js +61 -0
- package/dist/core/store.js.map +1 -0
- package/dist/core/suggestion-popup.d.ts +63 -0
- package/dist/core/suggestion-popup.js +57 -0
- package/dist/core/suggestion-popup.js.map +1 -0
- package/dist/core/tag-name.js +11 -0
- package/dist/core/tag-name.js.map +1 -0
- package/dist/core/toolbar-items.d.ts +10 -0
- package/dist/core/toolbar-items.js +206 -0
- package/dist/core/toolbar-items.js.map +1 -0
- package/dist/core/toolbar.d.ts +74 -0
- package/dist/core/toolbar.js +45 -0
- package/dist/core/toolbar.js.map +1 -0
- package/dist/document/DocumentSurface.d.ts +38 -0
- package/dist/document/DocumentSurface.js +44 -0
- package/dist/document/DocumentSurface.js.map +1 -0
- package/dist/document/DocumentSurface.vue.d.ts +56 -0
- package/dist/document/DocumentSurface2.js +71 -0
- package/dist/document/DocumentSurface2.js.map +1 -0
- package/dist/document/react.d.ts +2 -0
- package/dist/document/react.js +1 -0
- package/dist/document/vue.d.ts +2 -0
- package/dist/document/vue.js +1 -0
- package/dist/features/ai/agent-op-review.d.ts +69 -0
- package/dist/features/ai/agent-op-review.js +182 -0
- package/dist/features/ai/agent-op-review.js.map +1 -0
- package/dist/features/ai/agent-ops.d.ts +15 -0
- package/dist/features/ai/agent-ops.js +228 -0
- package/dist/features/ai/agent-ops.js.map +1 -0
- package/dist/features/ai/ai-apply.d.ts +76 -0
- package/dist/features/ai/ai-apply.js +193 -0
- package/dist/features/ai/ai-apply.js.map +1 -0
- package/dist/features/ai/ai-menu.d.ts +38 -0
- package/dist/features/ai/ai-menu.js +20 -0
- package/dist/features/ai/ai-menu.js.map +1 -0
- package/dist/features/ai/ai-review.d.ts +136 -0
- package/dist/features/ai/ai-review.js +543 -0
- package/dist/features/ai/ai-review.js.map +1 -0
- package/dist/features/ai/ai-selection-highlight.d.ts +21 -0
- package/dist/features/ai/ai-selection-highlight.js +44 -0
- package/dist/features/ai/ai-selection-highlight.js.map +1 -0
- package/dist/features/ai/ai-sse.d.ts +28 -0
- package/dist/features/ai/ai-sse.js +82 -0
- package/dist/features/ai/ai-sse.js.map +1 -0
- package/dist/features/ai/assistant.d.ts +53 -0
- package/dist/features/ai/assistant.js +82 -0
- package/dist/features/ai/assistant.js.map +1 -0
- package/dist/features/ai/block-actions.d.ts +20 -0
- package/dist/features/ai/block-actions.js +55 -0
- package/dist/features/ai/block-actions.js.map +1 -0
- package/dist/features/ai/components/AiReviewBar.js +145 -0
- package/dist/features/ai/components/AiReviewBar.js.map +1 -0
- package/dist/features/ai/components/AiReviewBar.vue.d.ts +15 -0
- package/dist/features/ai/components/AiSelectionMenu.js +519 -0
- package/dist/features/ai/components/AiSelectionMenu.js.map +1 -0
- package/dist/features/ai/components/AiSelectionMenu.vue.d.ts +17 -0
- package/dist/features/ai/components/AiSidebar.js +378 -0
- package/dist/features/ai/components/AiSidebar.js.map +1 -0
- package/dist/features/ai/components/AiSidebar.vue.d.ts +26 -0
- package/dist/features/ai/components/DocumentChatAnswer.js +67 -0
- package/dist/features/ai/components/DocumentChatAnswer.js.map +1 -0
- package/dist/features/ai/components/DocumentChatAnswer.vue.d.ts +13 -0
- package/dist/features/ai/components/DocumentChatOps.js +113 -0
- package/dist/features/ai/components/DocumentChatOps.js.map +1 -0
- package/dist/features/ai/components/DocumentChatOps.vue.d.ts +27 -0
- package/dist/features/ai/components/ModelQuickSwitch.js +84 -0
- package/dist/features/ai/components/ModelQuickSwitch.js.map +1 -0
- package/dist/features/ai/components/ModelQuickSwitch.vue.d.ts +23 -0
- package/dist/features/ai/components/SettingsAiTab.js +88 -0
- package/dist/features/ai/components/SettingsAiTab.js.map +1 -0
- package/dist/features/ai/components/SettingsAiTab.vue.d.ts +6 -0
- package/dist/features/ai/components/SettingsModelProfiles.js +260 -0
- package/dist/features/ai/components/SettingsModelProfiles.js.map +1 -0
- package/dist/features/ai/components/SettingsModelProfiles.vue.d.ts +6 -0
- package/dist/features/ai/document-chat-model.d.ts +88 -0
- package/dist/features/ai/document-chat-model.js +190 -0
- package/dist/features/ai/document-chat-model.js.map +1 -0
- package/dist/features/ai/document-chat.d.ts +17 -0
- package/dist/features/ai/document-chat.js +112 -0
- package/dist/features/ai/document-chat.js.map +1 -0
- package/dist/features/ai/feature.d.ts +25 -0
- package/dist/features/ai/feature.js +89 -0
- package/dist/features/ai/feature.js.map +1 -0
- package/dist/features/ai/ghost-autocomplete.d.ts +47 -0
- package/dist/features/ai/ghost-autocomplete.js +204 -0
- package/dist/features/ai/ghost-autocomplete.js.map +1 -0
- package/dist/features/ai/index.d.ts +24 -0
- package/dist/features/ai/index.js +23 -0
- package/dist/features/ai/model-profiles.d.ts +36 -0
- package/dist/features/ai/model-profiles.js +111 -0
- package/dist/features/ai/model-profiles.js.map +1 -0
- package/dist/features/ai/preview-extensions.js +14 -0
- package/dist/features/ai/preview-extensions.js.map +1 -0
- package/dist/features/ai/protocol/agent-ops.d.ts +120 -0
- package/dist/features/ai/protocol/agent-ops.js +298 -0
- package/dist/features/ai/protocol/agent-ops.js.map +1 -0
- package/dist/features/ai/protocol/chat.d.ts +57 -0
- package/dist/features/ai/protocol/chat.js +146 -0
- package/dist/features/ai/protocol/chat.js.map +1 -0
- package/dist/features/ai/protocol/complete.d.ts +21 -0
- package/dist/features/ai/protocol/complete.js +81 -0
- package/dist/features/ai/protocol/complete.js.map +1 -0
- package/dist/features/ai/protocol/index.d.ts +7 -0
- package/dist/features/ai/protocol/index.js +7 -0
- package/dist/features/ai/protocol/models.d.ts +48 -0
- package/dist/features/ai/protocol/models.js +41 -0
- package/dist/features/ai/protocol/models.js.map +1 -0
- package/dist/features/ai/protocol/schemas.d.ts +36 -0
- package/dist/features/ai/protocol/schemas.js +40 -0
- package/dist/features/ai/protocol/schemas.js.map +1 -0
- package/dist/features/ai/protocol/tasks.d.ts +107 -0
- package/dist/features/ai/protocol/tasks.js +227 -0
- package/dist/features/ai/protocol/tasks.js.map +1 -0
- package/dist/features/ai/rate-limit.d.ts +9 -0
- package/dist/features/ai/rate-limit.js +20 -0
- package/dist/features/ai/rate-limit.js.map +1 -0
- package/dist/features/ai/react/AiReviewBar.d.ts +12 -0
- package/dist/features/ai/react/AiReviewBar.js +156 -0
- package/dist/features/ai/react/AiReviewBar.js.map +1 -0
- package/dist/features/ai/react/AiSelectionMenu.d.ts +14 -0
- package/dist/features/ai/react/AiSelectionMenu.js +513 -0
- package/dist/features/ai/react/AiSelectionMenu.js.map +1 -0
- package/dist/features/ai/react/AiSidebar.d.ts +19 -0
- package/dist/features/ai/react/AiSidebar.js +339 -0
- package/dist/features/ai/react/AiSidebar.js.map +1 -0
- package/dist/features/ai/react/DocumentChatAnswer.d.ts +10 -0
- package/dist/features/ai/react/DocumentChatAnswer.js +70 -0
- package/dist/features/ai/react/DocumentChatAnswer.js.map +1 -0
- package/dist/features/ai/react/DocumentChatOps.d.ts +19 -0
- package/dist/features/ai/react/DocumentChatOps.js +111 -0
- package/dist/features/ai/react/DocumentChatOps.js.map +1 -0
- package/dist/features/ai/react/ModelQuickSwitch.d.ts +19 -0
- package/dist/features/ai/react/ModelQuickSwitch.js +89 -0
- package/dist/features/ai/react/ModelQuickSwitch.js.map +1 -0
- package/dist/features/ai/react/SettingsAiTab.d.ts +5 -0
- package/dist/features/ai/react/SettingsAiTab.js +103 -0
- package/dist/features/ai/react/SettingsAiTab.js.map +1 -0
- package/dist/features/ai/react/SettingsModelProfiles.d.ts +8 -0
- package/dist/features/ai/react/SettingsModelProfiles.js +318 -0
- package/dist/features/ai/react/SettingsModelProfiles.js.map +1 -0
- package/dist/features/ai/react/use-ai-assistant.d.ts +22 -0
- package/dist/features/ai/react/use-ai-assistant.js +36 -0
- package/dist/features/ai/react/use-ai-assistant.js.map +1 -0
- package/dist/features/ai/react/use-document-chat.d.ts +32 -0
- package/dist/features/ai/react/use-document-chat.js +43 -0
- package/dist/features/ai/react/use-document-chat.js.map +1 -0
- package/dist/features/ai/react/use-model-profiles.d.ts +20 -0
- package/dist/features/ai/react/use-model-profiles.js +33 -0
- package/dist/features/ai/react/use-model-profiles.js.map +1 -0
- package/dist/features/ai/react.d.ts +23 -0
- package/dist/features/ai/react.js +28 -0
- package/dist/features/ai/react.js.map +1 -0
- package/dist/features/ai/sidebar-flow.d.ts +61 -0
- package/dist/features/ai/sidebar-flow.js +125 -0
- package/dist/features/ai/sidebar-flow.js.map +1 -0
- package/dist/features/ai/use-ai-assistant.d.ts +22 -0
- package/dist/features/ai/use-ai-assistant.js +39 -0
- package/dist/features/ai/use-ai-assistant.js.map +1 -0
- package/dist/features/ai/use-document-chat.d.ts +33 -0
- package/dist/features/ai/use-document-chat.js +45 -0
- package/dist/features/ai/use-document-chat.js.map +1 -0
- package/dist/features/ai/use-model-profiles.d.ts +23 -0
- package/dist/features/ai/use-model-profiles.js +50 -0
- package/dist/features/ai/use-model-profiles.js.map +1 -0
- package/dist/features/ai/vue.d.ts +21 -0
- package/dist/features/ai/vue.js +28 -0
- package/dist/features/ai/vue.js.map +1 -0
- package/dist/features/authors/attribution.d.ts +36 -0
- package/dist/features/authors/attribution.js +94 -0
- package/dist/features/authors/attribution.js.map +1 -0
- package/dist/features/authors/author-color-styles.d.ts +12 -0
- package/dist/features/authors/author-color-styles.js +24 -0
- package/dist/features/authors/author-color-styles.js.map +1 -0
- package/dist/features/authors/components/AuthorColorsButton.js +50 -0
- package/dist/features/authors/components/AuthorColorsButton.js.map +1 -0
- package/dist/features/authors/components/AuthorColorsButton.vue.d.ts +11 -0
- package/dist/features/authors/components/AuthorColorsPanel.js +72 -0
- package/dist/features/authors/components/AuthorColorsPanel.js.map +1 -0
- package/dist/features/authors/components/AuthorColorsPanel.vue.d.ts +11 -0
- package/dist/features/authors/components/SettingsAuthorsTab.js +49 -0
- package/dist/features/authors/components/SettingsAuthorsTab.js.map +1 -0
- package/dist/features/authors/components/SettingsAuthorsTab.vue.d.ts +6 -0
- package/dist/features/authors/feature.d.ts +22 -0
- package/dist/features/authors/feature.js +47 -0
- package/dist/features/authors/feature.js.map +1 -0
- package/dist/features/authors/index.d.ts +7 -0
- package/dist/features/authors/index.js +6 -0
- package/dist/features/authors/react/AuthorColorsButton.d.ts +8 -0
- package/dist/features/authors/react/AuthorColorsButton.js +41 -0
- package/dist/features/authors/react/AuthorColorsButton.js.map +1 -0
- package/dist/features/authors/react/AuthorColorsPanel.d.ts +8 -0
- package/dist/features/authors/react/AuthorColorsPanel.js +125 -0
- package/dist/features/authors/react/AuthorColorsPanel.js.map +1 -0
- package/dist/features/authors/react/SettingsAuthorsTab.d.ts +5 -0
- package/dist/features/authors/react/SettingsAuthorsTab.js +92 -0
- package/dist/features/authors/react/SettingsAuthorsTab.js.map +1 -0
- package/dist/features/authors/react.d.ts +11 -0
- package/dist/features/authors/react.js +16 -0
- package/dist/features/authors/react.js.map +1 -0
- package/dist/features/authors/schema.d.ts +22 -0
- package/dist/features/authors/schema.js +70 -0
- package/dist/features/authors/schema.js.map +1 -0
- package/dist/features/authors/vue.d.ts +10 -0
- package/dist/features/authors/vue.js +16 -0
- package/dist/features/authors/vue.js.map +1 -0
- package/dist/features/block-ui/block-actions.d.ts +17 -0
- package/dist/features/block-ui/block-actions.js +37 -0
- package/dist/features/block-ui/block-actions.js.map +1 -0
- package/dist/features/block-ui/components/BlockActionsOverlay.js +142 -0
- package/dist/features/block-ui/components/BlockActionsOverlay.js.map +1 -0
- package/dist/features/block-ui/components/BlockActionsOverlay.vue.d.ts +25 -0
- package/dist/features/block-ui/components/BlockHandles.js +113 -0
- package/dist/features/block-ui/components/BlockHandles.js.map +1 -0
- package/dist/features/block-ui/components/BlockUi.js +181 -0
- package/dist/features/block-ui/components/BlockUi.js.map +1 -0
- package/dist/features/block-ui/components/BlockUi.vue.d.ts +17 -0
- package/dist/features/block-ui/feature.d.ts +21 -0
- package/dist/features/block-ui/feature.js +23 -0
- package/dist/features/block-ui/feature.js.map +1 -0
- package/dist/features/block-ui/handle-geometry.js +52 -0
- package/dist/features/block-ui/handle-geometry.js.map +1 -0
- package/dist/features/block-ui/index.d.ts +3 -0
- package/dist/features/block-ui/index.js +3 -0
- package/dist/features/block-ui/react/BlockActionsOverlay.d.ts +19 -0
- package/dist/features/block-ui/react/BlockActionsOverlay.js +142 -0
- package/dist/features/block-ui/react/BlockActionsOverlay.js.map +1 -0
- package/dist/features/block-ui/react/BlockHandles.d.ts +15 -0
- package/dist/features/block-ui/react/BlockHandles.js +104 -0
- package/dist/features/block-ui/react/BlockHandles.js.map +1 -0
- package/dist/features/block-ui/react/BlockUi.d.ts +14 -0
- package/dist/features/block-ui/react/BlockUi.js +174 -0
- package/dist/features/block-ui/react/BlockUi.js.map +1 -0
- package/dist/features/block-ui/react.d.ts +11 -0
- package/dist/features/block-ui/react.js +13 -0
- package/dist/features/block-ui/react.js.map +1 -0
- package/dist/features/block-ui/vue.d.ts +9 -0
- package/dist/features/block-ui/vue.js +12 -0
- package/dist/features/block-ui/vue.js.map +1 -0
- package/dist/features/collab/anchor-resolver.d.ts +7 -0
- package/dist/features/collab/anchor-resolver.js +92 -0
- package/dist/features/collab/anchor-resolver.js.map +1 -0
- package/dist/features/collab/feature.d.ts +22 -0
- package/dist/features/collab/feature.js +36 -0
- package/dist/features/collab/feature.js.map +1 -0
- package/dist/features/collab/index.d.ts +3 -0
- package/dist/features/collab/index.js +3 -0
- package/dist/features/collab/react.d.ts +7 -0
- package/dist/features/collab/react.js +10 -0
- package/dist/features/collab/react.js.map +1 -0
- package/dist/features/collab/vue.d.ts +6 -0
- package/dist/features/collab/vue.js +37 -0
- package/dist/features/collab/vue.js.map +1 -0
- package/dist/features/comments/comments-plugin.d.ts +71 -0
- package/dist/features/comments/comments-plugin.js +185 -0
- package/dist/features/comments/comments-plugin.js.map +1 -0
- package/dist/features/comments/components/CommentBubble.js +54 -0
- package/dist/features/comments/components/CommentBubble.js.map +1 -0
- package/dist/features/comments/components/CommentBubble.vue.d.ts +14 -0
- package/dist/features/comments/components/CommentComposer.js +87 -0
- package/dist/features/comments/components/CommentComposer.js.map +1 -0
- package/dist/features/comments/components/CommentComposer.vue.d.ts +21 -0
- package/dist/features/comments/components/CommentThreadView.js +255 -0
- package/dist/features/comments/components/CommentThreadView.js.map +1 -0
- package/dist/features/comments/components/CommentThreadView.vue.d.ts +29 -0
- package/dist/features/comments/components/CommentsListMenu.js +134 -0
- package/dist/features/comments/components/CommentsListMenu.js.map +1 -0
- package/dist/features/comments/components/CommentsListMenu.vue.d.ts +10 -0
- package/dist/features/comments/components/CommentsMargin.js +291 -0
- package/dist/features/comments/components/CommentsMargin.js.map +1 -0
- package/dist/features/comments/components/CommentsMargin.vue.d.ts +16 -0
- package/dist/features/comments/components/CommentsOverlay.js +39 -0
- package/dist/features/comments/components/CommentsOverlay.js.map +1 -0
- package/dist/features/comments/components/CommentsPopover.js +124 -0
- package/dist/features/comments/components/CommentsPopover.js.map +1 -0
- package/dist/features/comments/components/CommentsPopover.vue.d.ts +10 -0
- package/dist/features/comments/components/CommentsToolbarButton.js +61 -0
- package/dist/features/comments/components/CommentsToolbarButton.js.map +1 -0
- package/dist/features/comments/components/SettingsCommentsTab.js +46 -0
- package/dist/features/comments/components/SettingsCommentsTab.js.map +1 -0
- package/dist/features/comments/components/SettingsCommentsTab.vue.d.ts +6 -0
- package/dist/features/comments/feature.d.ts +39 -0
- package/dist/features/comments/feature.js +128 -0
- package/dist/features/comments/feature.js.map +1 -0
- package/dist/features/comments/index.d.ts +6 -0
- package/dist/features/comments/index.js +6 -0
- package/dist/features/comments/model.d.ts +87 -0
- package/dist/features/comments/model.js +390 -0
- package/dist/features/comments/model.js.map +1 -0
- package/dist/features/comments/react/CommentAvatar.js +24 -0
- package/dist/features/comments/react/CommentAvatar.js.map +1 -0
- package/dist/features/comments/react/CommentBubble.d.ts +11 -0
- package/dist/features/comments/react/CommentBubble.js +43 -0
- package/dist/features/comments/react/CommentBubble.js.map +1 -0
- package/dist/features/comments/react/CommentComposer.d.ts +15 -0
- package/dist/features/comments/react/CommentComposer.js +69 -0
- package/dist/features/comments/react/CommentComposer.js.map +1 -0
- package/dist/features/comments/react/CommentThreadView.d.ts +24 -0
- package/dist/features/comments/react/CommentThreadView.js +249 -0
- package/dist/features/comments/react/CommentThreadView.js.map +1 -0
- package/dist/features/comments/react/CommentsListMenu.d.ts +8 -0
- package/dist/features/comments/react/CommentsListMenu.js +115 -0
- package/dist/features/comments/react/CommentsListMenu.js.map +1 -0
- package/dist/features/comments/react/CommentsMargin.d.ts +16 -0
- package/dist/features/comments/react/CommentsMargin.js +294 -0
- package/dist/features/comments/react/CommentsMargin.js.map +1 -0
- package/dist/features/comments/react/CommentsOverlay.d.ts +11 -0
- package/dist/features/comments/react/CommentsOverlay.js +52 -0
- package/dist/features/comments/react/CommentsOverlay.js.map +1 -0
- package/dist/features/comments/react/CommentsPopover.d.ts +15 -0
- package/dist/features/comments/react/CommentsPopover.js +107 -0
- package/dist/features/comments/react/CommentsPopover.js.map +1 -0
- package/dist/features/comments/react/CommentsToolbarButton.d.ts +12 -0
- package/dist/features/comments/react/CommentsToolbarButton.js +52 -0
- package/dist/features/comments/react/CommentsToolbarButton.js.map +1 -0
- package/dist/features/comments/react/SettingsCommentsTab.d.ts +5 -0
- package/dist/features/comments/react/SettingsCommentsTab.js +77 -0
- package/dist/features/comments/react/SettingsCommentsTab.js.map +1 -0
- package/dist/features/comments/react/use-comments.d.ts +17 -0
- package/dist/features/comments/react/use-comments.js +37 -0
- package/dist/features/comments/react/use-comments.js.map +1 -0
- package/dist/features/comments/react.d.ts +23 -0
- package/dist/features/comments/react.js +28 -0
- package/dist/features/comments/react.js.map +1 -0
- package/dist/features/comments/schema.d.ts +51 -0
- package/dist/features/comments/schema.js +41 -0
- package/dist/features/comments/schema.js.map +1 -0
- package/dist/features/comments/shortcuts.js +34 -0
- package/dist/features/comments/shortcuts.js.map +1 -0
- package/dist/features/comments/use-comments.d.ts +37 -0
- package/dist/features/comments/use-comments.js +45 -0
- package/dist/features/comments/use-comments.js.map +1 -0
- package/dist/features/comments/vue.d.ts +20 -0
- package/dist/features/comments/vue.js +28 -0
- package/dist/features/comments/vue.js.map +1 -0
- package/dist/features/composites/ai-brief.d.ts +31 -0
- package/dist/features/composites/ai-brief.js +56 -0
- package/dist/features/composites/ai-brief.js.map +1 -0
- package/dist/features/composites/anchors.d.ts +47 -0
- package/dist/features/composites/anchors.js +137 -0
- package/dist/features/composites/anchors.js.map +1 -0
- package/dist/features/composites/components/CompositeChrome.js +243 -0
- package/dist/features/composites/components/CompositeChrome.js.map +1 -0
- package/dist/features/composites/components/CompositeChrome.vue.d.ts +19 -0
- package/dist/features/composites/components/CompositeDetails.js +158 -0
- package/dist/features/composites/components/CompositeDetails.js.map +1 -0
- package/dist/features/composites/components/CompositeDetails.vue.d.ts +19 -0
- package/dist/features/composites/components/CompositeFieldEditor.js +114 -0
- package/dist/features/composites/components/CompositeFieldEditor.js.map +1 -0
- package/dist/features/composites/components/CompositeFieldEditor.vue.d.ts +23 -0
- package/dist/features/composites/components/CompositeInspector.js +439 -0
- package/dist/features/composites/components/CompositeInspector.js.map +1 -0
- package/dist/features/composites/components/CompositeInspector.vue.d.ts +32 -0
- package/dist/features/composites/components/CompositeStatusMenu.js +51 -0
- package/dist/features/composites/components/CompositeStatusMenu.js.map +1 -0
- package/dist/features/composites/components/CompositeStatusMenu.vue.d.ts +28 -0
- package/dist/features/composites/components/CompositeSummaryEditor.js +79 -0
- package/dist/features/composites/components/CompositeSummaryEditor.js.map +1 -0
- package/dist/features/composites/components/CompositeSummaryEditor.vue.d.ts +18 -0
- package/dist/features/composites/components/CompositeTable.js +348 -0
- package/dist/features/composites/components/CompositeTable.js.map +1 -0
- package/dist/features/composites/components/CompositeTable.vue.d.ts +15 -0
- package/dist/features/composites/components/CompositeTagsEditor.js +95 -0
- package/dist/features/composites/components/CompositeTagsEditor.js.map +1 -0
- package/dist/features/composites/components/CompositeTagsEditor.vue.d.ts +13 -0
- package/dist/features/composites/components/CompositeView.js +46 -0
- package/dist/features/composites/components/CompositeView.js.map +1 -0
- package/dist/features/composites/components/CompositeView.vue.d.ts +96 -0
- package/dist/features/composites/components/SettingsEditingTab.js +119 -0
- package/dist/features/composites/components/SettingsEditingTab.js.map +1 -0
- package/dist/features/composites/components/SettingsEditingTab.vue.d.ts +11 -0
- package/dist/features/composites/convert.d.ts +24 -0
- package/dist/features/composites/convert.js +145 -0
- package/dist/features/composites/convert.js.map +1 -0
- package/dist/features/composites/editing-settings-keys.js +47 -0
- package/dist/features/composites/editing-settings-keys.js.map +1 -0
- package/dist/features/composites/feature.d.ts +30 -0
- package/dist/features/composites/feature.js +305 -0
- package/dist/features/composites/feature.js.map +1 -0
- package/dist/features/composites/fences.d.ts +20 -0
- package/dist/features/composites/fences.js +86 -0
- package/dist/features/composites/fences.js.map +1 -0
- package/dist/features/composites/heading-composites.d.ts +36 -0
- package/dist/features/composites/heading-composites.js +140 -0
- package/dist/features/composites/heading-composites.js.map +1 -0
- package/dist/features/composites/index.d.ts +20 -0
- package/dist/features/composites/index.js +20 -0
- package/dist/features/composites/kinds.d.ts +49 -0
- package/dist/features/composites/kinds.js +131 -0
- package/dist/features/composites/kinds.js.map +1 -0
- package/dist/features/composites/legacy.d.ts +8 -0
- package/dist/features/composites/legacy.js +25 -0
- package/dist/features/composites/legacy.js.map +1 -0
- package/dist/features/composites/markdown-export.d.ts +17 -0
- package/dist/features/composites/markdown-export.js +49 -0
- package/dist/features/composites/markdown-export.js.map +1 -0
- package/dist/features/composites/meta-display.js +46 -0
- package/dist/features/composites/meta-display.js.map +1 -0
- package/dist/features/composites/node-views.d.ts +17 -0
- package/dist/features/composites/node-views.js +18 -0
- package/dist/features/composites/node-views.js.map +1 -0
- package/dist/features/composites/nodes.d.ts +56 -0
- package/dist/features/composites/nodes.js +480 -0
- package/dist/features/composites/nodes.js.map +1 -0
- package/dist/features/composites/outline.d.ts +35 -0
- package/dist/features/composites/outline.js +69 -0
- package/dist/features/composites/outline.js.map +1 -0
- package/dist/features/composites/react/CompositeChrome.d.ts +16 -0
- package/dist/features/composites/react/CompositeChrome.js +234 -0
- package/dist/features/composites/react/CompositeChrome.js.map +1 -0
- package/dist/features/composites/react/CompositeDetails.d.ts +16 -0
- package/dist/features/composites/react/CompositeDetails.js +149 -0
- package/dist/features/composites/react/CompositeDetails.js.map +1 -0
- package/dist/features/composites/react/CompositeFieldEditor.d.ts +18 -0
- package/dist/features/composites/react/CompositeFieldEditor.js +131 -0
- package/dist/features/composites/react/CompositeFieldEditor.js.map +1 -0
- package/dist/features/composites/react/CompositeInspector.d.ts +23 -0
- package/dist/features/composites/react/CompositeInspector.js +506 -0
- package/dist/features/composites/react/CompositeInspector.js.map +1 -0
- package/dist/features/composites/react/CompositeStatusMenu.d.ts +15 -0
- package/dist/features/composites/react/CompositeStatusMenu.js +36 -0
- package/dist/features/composites/react/CompositeStatusMenu.js.map +1 -0
- package/dist/features/composites/react/CompositeSummaryEditor.d.ts +15 -0
- package/dist/features/composites/react/CompositeSummaryEditor.js +85 -0
- package/dist/features/composites/react/CompositeSummaryEditor.js.map +1 -0
- package/dist/features/composites/react/CompositeTable.d.ts +11 -0
- package/dist/features/composites/react/CompositeTable.js +342 -0
- package/dist/features/composites/react/CompositeTable.js.map +1 -0
- package/dist/features/composites/react/CompositeTagsEditor.d.ts +10 -0
- package/dist/features/composites/react/CompositeTagsEditor.js +122 -0
- package/dist/features/composites/react/CompositeTagsEditor.js.map +1 -0
- package/dist/features/composites/react/CompositeView.d.ts +6 -0
- package/dist/features/composites/react/CompositeView.js +30 -0
- package/dist/features/composites/react/CompositeView.js.map +1 -0
- package/dist/features/composites/react/SettingsEditingTab.d.ts +8 -0
- package/dist/features/composites/react/SettingsEditingTab.js +153 -0
- package/dist/features/composites/react/SettingsEditingTab.js.map +1 -0
- package/dist/features/composites/react/use-composite-anchors.d.ts +17 -0
- package/dist/features/composites/react/use-composite-anchors.js +46 -0
- package/dist/features/composites/react/use-composite-anchors.js.map +1 -0
- package/dist/features/composites/react/use-composite-rows.d.ts +11 -0
- package/dist/features/composites/react/use-composite-rows.js +26 -0
- package/dist/features/composites/react/use-composite-rows.js.map +1 -0
- package/dist/features/composites/react.d.ts +24 -0
- package/dist/features/composites/react.js +30 -0
- package/dist/features/composites/react.js.map +1 -0
- package/dist/features/composites/rows-model.d.ts +38 -0
- package/dist/features/composites/rows-model.js +92 -0
- package/dist/features/composites/rows-model.js.map +1 -0
- package/dist/features/composites/rows.d.ts +76 -0
- package/dist/features/composites/rows.js +159 -0
- package/dist/features/composites/rows.js.map +1 -0
- package/dist/features/composites/schema.d.ts +21 -0
- package/dist/features/composites/schema.js +26 -0
- package/dist/features/composites/schema.js.map +1 -0
- package/dist/features/composites/structure-mode.d.ts +11 -0
- package/dist/features/composites/structure-mode.js +16 -0
- package/dist/features/composites/structure-mode.js.map +1 -0
- package/dist/features/composites/structure.d.ts +19 -0
- package/dist/features/composites/structure.js +19 -0
- package/dist/features/composites/structure.js.map +1 -0
- package/dist/features/composites/table-model.js +117 -0
- package/dist/features/composites/table-model.js.map +1 -0
- package/dist/features/composites/tree-root.d.ts +11 -0
- package/dist/features/composites/tree-root.js +16 -0
- package/dist/features/composites/tree-root.js.map +1 -0
- package/dist/features/composites/use-composite-anchors.d.ts +18 -0
- package/dist/features/composites/use-composite-anchors.js +42 -0
- package/dist/features/composites/use-composite-anchors.js.map +1 -0
- package/dist/features/composites/use-composite-rows.d.ts +25 -0
- package/dist/features/composites/use-composite-rows.js +28 -0
- package/dist/features/composites/use-composite-rows.js.map +1 -0
- package/dist/features/composites/vue.d.ts +23 -0
- package/dist/features/composites/vue.js +30 -0
- package/dist/features/composites/vue.js.map +1 -0
- package/dist/features/media/assets.d.ts +30 -0
- package/dist/features/media/assets.js +26 -0
- package/dist/features/media/assets.js.map +1 -0
- package/dist/features/media/audio-recorder.d.ts +25 -0
- package/dist/features/media/audio-recorder.js +123 -0
- package/dist/features/media/audio-recorder.js.map +1 -0
- package/dist/features/media/components/AudioRecorderModal.js +152 -0
- package/dist/features/media/components/AudioRecorderModal.js.map +1 -0
- package/dist/features/media/components/AudioRecorderModal.vue.d.ts +15 -0
- package/dist/features/media/components/AudioView.js +46 -0
- package/dist/features/media/components/AudioView.js.map +1 -0
- package/dist/features/media/components/FileView.js +73 -0
- package/dist/features/media/components/FileView.js.map +1 -0
- package/dist/features/media/components/VideoView.js +47 -0
- package/dist/features/media/components/VideoView.js.map +1 -0
- package/dist/features/media/feature.d.ts +22 -0
- package/dist/features/media/feature.js +101 -0
- package/dist/features/media/feature.js.map +1 -0
- package/dist/features/media/file-import.d.ts +21 -0
- package/dist/features/media/file-import.js +76 -0
- package/dist/features/media/file-import.js.map +1 -0
- package/dist/features/media/index.d.ts +7 -0
- package/dist/features/media/index.js +7 -0
- package/dist/features/media/node-views.d.ts +28 -0
- package/dist/features/media/node-views.js +28 -0
- package/dist/features/media/node-views.js.map +1 -0
- package/dist/features/media/react/AudioRecorderModal.d.ts +12 -0
- package/dist/features/media/react/AudioRecorderModal.js +147 -0
- package/dist/features/media/react/AudioRecorderModal.js.map +1 -0
- package/dist/features/media/react/AudioView.js +32 -0
- package/dist/features/media/react/AudioView.js.map +1 -0
- package/dist/features/media/react/FileView.js +61 -0
- package/dist/features/media/react/FileView.js.map +1 -0
- package/dist/features/media/react/TitleField.js +30 -0
- package/dist/features/media/react/TitleField.js.map +1 -0
- package/dist/features/media/react/VideoView.js +33 -0
- package/dist/features/media/react/VideoView.js.map +1 -0
- package/dist/features/media/react/use-audio-recorder.d.ts +11 -0
- package/dist/features/media/react/use-audio-recorder.js +21 -0
- package/dist/features/media/react/use-audio-recorder.js.map +1 -0
- package/dist/features/media/react.d.ts +19 -0
- package/dist/features/media/react.js +37 -0
- package/dist/features/media/react.js.map +1 -0
- package/dist/features/media/schema.d.ts +59 -0
- package/dist/features/media/schema.js +194 -0
- package/dist/features/media/schema.js.map +1 -0
- package/dist/features/media/upload.d.ts +41 -0
- package/dist/features/media/upload.js +106 -0
- package/dist/features/media/upload.js.map +1 -0
- package/dist/features/media/use-audio-recorder.d.ts +12 -0
- package/dist/features/media/use-audio-recorder.js +21 -0
- package/dist/features/media/use-audio-recorder.js.map +1 -0
- package/dist/features/media/vue.d.ts +19 -0
- package/dist/features/media/vue.js +35 -0
- package/dist/features/media/vue.js.map +1 -0
- package/dist/features/mentions/index.d.ts +22 -0
- package/dist/features/mentions/index.js +34 -0
- package/dist/features/mentions/index.js.map +1 -0
- package/dist/features/mentions/mention-suggestion.d.ts +11 -0
- package/dist/features/mentions/mention-suggestion.js +34 -0
- package/dist/features/mentions/mention-suggestion.js.map +1 -0
- package/dist/features/mentions/mention-text.d.ts +18 -0
- package/dist/features/mentions/mention-text.js +75 -0
- package/dist/features/mentions/mention-text.js.map +1 -0
- package/dist/features/mentions/mention.d.ts +20 -0
- package/dist/features/mentions/mention.js +33 -0
- package/dist/features/mentions/mention.js.map +1 -0
- package/dist/features/mentions/metadata-defaults.d.ts +8 -0
- package/dist/features/mentions/metadata-defaults.js +30 -0
- package/dist/features/mentions/metadata-defaults.js.map +1 -0
- package/dist/features/mentions/normalize.d.ts +10 -0
- package/dist/features/mentions/normalize.js +31 -0
- package/dist/features/mentions/normalize.js.map +1 -0
- package/dist/features/mentions/schema.d.ts +10 -0
- package/dist/features/mentions/schema.js +10 -0
- package/dist/features/mentions/schema.js.map +1 -0
- package/dist/features/mentions/tag-suggestion.d.ts +11 -0
- package/dist/features/mentions/tag-suggestion.js +45 -0
- package/dist/features/mentions/tag-suggestion.js.map +1 -0
- package/dist/features/mentions/tag.d.ts +43 -0
- package/dist/features/mentions/tag.js +155 -0
- package/dist/features/mentions/tag.js.map +1 -0
- package/dist/features/tables/feature.d.ts +14 -0
- package/dist/features/tables/feature.js +100 -0
- package/dist/features/tables/feature.js.map +1 -0
- package/dist/features/tables/index.d.ts +3 -0
- package/dist/features/tables/index.js +3 -0
- package/dist/features/tables/schema.d.ts +6 -0
- package/dist/features/tables/schema.js +27 -0
- package/dist/features/tables/schema.js.map +1 -0
- package/dist/features/themes/components/SettingsAppearanceTab.js +227 -0
- package/dist/features/themes/components/SettingsAppearanceTab.js.map +1 -0
- package/dist/features/themes/components/SettingsAppearanceTab.vue.d.ts +6 -0
- package/dist/features/themes/feature.d.ts +24 -0
- package/dist/features/themes/feature.js +25 -0
- package/dist/features/themes/feature.js.map +1 -0
- package/dist/features/themes/index.d.ts +6 -0
- package/dist/features/themes/index.js +6 -0
- package/dist/features/themes/react/SettingsAppearanceTab.d.ts +5 -0
- package/dist/features/themes/react/SettingsAppearanceTab.js +221 -0
- package/dist/features/themes/react/SettingsAppearanceTab.js.map +1 -0
- package/dist/features/themes/react.d.ts +13 -0
- package/dist/features/themes/react.js +15 -0
- package/dist/features/themes/react.js.map +1 -0
- package/dist/features/themes/schema.d.ts +21 -0
- package/dist/features/themes/schema.js +16 -0
- package/dist/features/themes/schema.js.map +1 -0
- package/dist/features/themes/scope-css.d.ts +5 -0
- package/dist/features/themes/scope-css.js +142 -0
- package/dist/features/themes/scope-css.js.map +1 -0
- package/dist/features/themes/theme-runtime.d.ts +14 -0
- package/dist/features/themes/theme-runtime.js +147 -0
- package/dist/features/themes/theme-runtime.js.map +1 -0
- package/dist/features/themes/vue.d.ts +13 -0
- package/dist/features/themes/vue.js +29 -0
- package/dist/features/themes/vue.js.map +1 -0
- package/dist/features/transcript/TranscriptSegmentView.js +169 -0
- package/dist/features/transcript/TranscriptSegmentView.js.map +1 -0
- package/dist/features/transcript/TranscriptSegmentView.vue.d.ts +96 -0
- package/dist/features/transcript/convert.d.ts +11 -0
- package/dist/features/transcript/convert.js +40 -0
- package/dist/features/transcript/convert.js.map +1 -0
- package/dist/features/transcript/feature.d.ts +25 -0
- package/dist/features/transcript/feature.js +59 -0
- package/dist/features/transcript/feature.js.map +1 -0
- package/dist/features/transcript/index.d.ts +7 -0
- package/dist/features/transcript/index.js +7 -0
- package/dist/features/transcript/react/TranscriptSegmentView.d.ts +6 -0
- package/dist/features/transcript/react/TranscriptSegmentView.js +155 -0
- package/dist/features/transcript/react/TranscriptSegmentView.js.map +1 -0
- package/dist/features/transcript/react.d.ts +9 -0
- package/dist/features/transcript/react.js +12 -0
- package/dist/features/transcript/react.js.map +1 -0
- package/dist/features/transcript/schema.d.ts +9 -0
- package/dist/features/transcript/schema.js +9 -0
- package/dist/features/transcript/schema.js.map +1 -0
- package/dist/features/transcript/segment-node.d.ts +21 -0
- package/dist/features/transcript/segment-node.js +113 -0
- package/dist/features/transcript/segment-node.js.map +1 -0
- package/dist/features/transcript/segment.d.ts +10 -0
- package/dist/features/transcript/segment.js +26 -0
- package/dist/features/transcript/segment.js.map +1 -0
- package/dist/features/transcript/speakers.d.ts +8 -0
- package/dist/features/transcript/speakers.js +22 -0
- package/dist/features/transcript/speakers.js.map +1 -0
- package/dist/features/transcript/vue.d.ts +8 -0
- package/dist/features/transcript/vue.js +12 -0
- package/dist/features/transcript/vue.js.map +1 -0
- package/dist/i18n/de/ai.js +168 -0
- package/dist/i18n/de/ai.js.map +1 -0
- package/dist/i18n/de/authors.js +21 -0
- package/dist/i18n/de/authors.js.map +1 -0
- package/dist/i18n/de/block.js +16 -0
- package/dist/i18n/de/block.js.map +1 -0
- package/dist/i18n/de/comments.js +35 -0
- package/dist/i18n/de/comments.js.map +1 -0
- package/dist/i18n/de/common.js +10 -0
- package/dist/i18n/de/common.js.map +1 -0
- package/dist/i18n/de/composites.js +147 -0
- package/dist/i18n/de/composites.js.map +1 -0
- package/dist/i18n/de/integrations.js +42 -0
- package/dist/i18n/de/integrations.js.map +1 -0
- package/dist/i18n/de/markdown.js +16 -0
- package/dist/i18n/de/markdown.js.map +1 -0
- package/dist/i18n/de/media.js +27 -0
- package/dist/i18n/de/media.js.map +1 -0
- package/dist/i18n/de/mentions.js +10 -0
- package/dist/i18n/de/mentions.js.map +1 -0
- package/dist/i18n/de/outline.js +9 -0
- package/dist/i18n/de/outline.js.map +1 -0
- package/dist/i18n/de/settings.js +12 -0
- package/dist/i18n/de/settings.js.map +1 -0
- package/dist/i18n/de/tables.js +15 -0
- package/dist/i18n/de/tables.js.map +1 -0
- package/dist/i18n/de/themes.js +26 -0
- package/dist/i18n/de/themes.js.map +1 -0
- package/dist/i18n/de/toolbar.js +22 -0
- package/dist/i18n/de/toolbar.js.map +1 -0
- package/dist/i18n/de/transcript.js +10 -0
- package/dist/i18n/de/transcript.js.map +1 -0
- package/dist/i18n/de/tree.js +31 -0
- package/dist/i18n/de/tree.js.map +1 -0
- package/dist/i18n/de.d.ts +502 -0
- package/dist/i18n/de.js +42 -0
- package/dist/i18n/de.js.map +1 -0
- package/dist/i18n/en/ai.js +168 -0
- package/dist/i18n/en/ai.js.map +1 -0
- package/dist/i18n/en/authors.js +21 -0
- package/dist/i18n/en/authors.js.map +1 -0
- package/dist/i18n/en/block.js +16 -0
- package/dist/i18n/en/block.js.map +1 -0
- package/dist/i18n/en/comments.js +35 -0
- package/dist/i18n/en/comments.js.map +1 -0
- package/dist/i18n/en/common.js +10 -0
- package/dist/i18n/en/common.js.map +1 -0
- package/dist/i18n/en/composites.js +145 -0
- package/dist/i18n/en/composites.js.map +1 -0
- package/dist/i18n/en/integrations.js +42 -0
- package/dist/i18n/en/integrations.js.map +1 -0
- package/dist/i18n/en/markdown.js +16 -0
- package/dist/i18n/en/markdown.js.map +1 -0
- package/dist/i18n/en/media.js +27 -0
- package/dist/i18n/en/media.js.map +1 -0
- package/dist/i18n/en/mentions.js +10 -0
- package/dist/i18n/en/mentions.js.map +1 -0
- package/dist/i18n/en/outline.js +9 -0
- package/dist/i18n/en/outline.js.map +1 -0
- package/dist/i18n/en/settings.js +12 -0
- package/dist/i18n/en/settings.js.map +1 -0
- package/dist/i18n/en/tables.js +15 -0
- package/dist/i18n/en/tables.js.map +1 -0
- package/dist/i18n/en/themes.js +26 -0
- package/dist/i18n/en/themes.js.map +1 -0
- package/dist/i18n/en/toolbar.js +22 -0
- package/dist/i18n/en/toolbar.js.map +1 -0
- package/dist/i18n/en/transcript.js +10 -0
- package/dist/i18n/en/transcript.js.map +1 -0
- package/dist/i18n/en/tree.js +31 -0
- package/dist/i18n/en/tree.js.map +1 -0
- package/dist/i18n/en.js +42 -0
- package/dist/i18n/en.js.map +1 -0
- package/dist/i18n/index.d.ts +24 -0
- package/dist/i18n/index.js +31 -0
- package/dist/i18n/index.js.map +1 -0
- package/dist/index.d.ts +6 -0
- package/dist/index.js +0 -0
- package/dist/integrations/composite-ai/composite-fill.d.ts +17 -0
- package/dist/integrations/composite-ai/composite-fill.js +129 -0
- package/dist/integrations/composite-ai/composite-fill.js.map +1 -0
- package/dist/integrations/composite-ai/composite-summary.d.ts +28 -0
- package/dist/integrations/composite-ai/composite-summary.js +143 -0
- package/dist/integrations/composite-ai/composite-summary.js.map +1 -0
- package/dist/integrations/composite-ai/document-transcribe.d.ts +14 -0
- package/dist/integrations/composite-ai/document-transcribe.js +89 -0
- package/dist/integrations/composite-ai/document-transcribe.js.map +1 -0
- package/dist/integrations/composite-ai/index.d.ts +22 -0
- package/dist/integrations/composite-ai/index.js +80 -0
- package/dist/integrations/composite-ai/index.js.map +1 -0
- package/dist/integrations/composite-media/index.d.ts +19 -0
- package/dist/integrations/composite-media/index.js +72 -0
- package/dist/integrations/composite-media/index.js.map +1 -0
- package/dist/integrations/transcript-ai/index.d.ts +16 -0
- package/dist/integrations/transcript-ai/index.js +63 -0
- package/dist/integrations/transcript-ai/index.js.map +1 -0
- package/dist/integrations/transcript-ai/protocol.d.ts +68 -0
- package/dist/integrations/transcript-ai/protocol.js +132 -0
- package/dist/integrations/transcript-ai/protocol.js.map +1 -0
- package/dist/integrations/transcript-ai/transcript-cleanup.d.ts +35 -0
- package/dist/integrations/transcript-ai/transcript-cleanup.js +169 -0
- package/dist/integrations/transcript-ai/transcript-cleanup.js.map +1 -0
- package/dist/markdown/MarkdownSurface.d.ts +25 -0
- package/dist/markdown/MarkdownSurface.js +93 -0
- package/dist/markdown/MarkdownSurface.js.map +1 -0
- package/dist/markdown/MarkdownSurface.vue.d.ts +76 -0
- package/dist/markdown/MarkdownSurface2.js +237 -0
- package/dist/markdown/MarkdownSurface2.js.map +1 -0
- package/dist/markdown/clipboard.d.ts +17 -0
- package/dist/markdown/clipboard.js +125 -0
- package/dist/markdown/clipboard.js.map +1 -0
- package/dist/markdown/document.d.ts +36 -0
- package/dist/markdown/document.js +100 -0
- package/dist/markdown/document.js.map +1 -0
- package/dist/markdown/frontmatter.d.ts +18 -0
- package/dist/markdown/frontmatter.js +32 -0
- package/dist/markdown/frontmatter.js.map +1 -0
- package/dist/markdown/index.d.ts +6 -0
- package/dist/markdown/index.js +6 -0
- package/dist/markdown/policy.d.ts +34 -0
- package/dist/markdown/policy.js +78 -0
- package/dist/markdown/policy.js.map +1 -0
- package/dist/markdown/react.d.ts +2 -0
- package/dist/markdown/react.js +1 -0
- package/dist/markdown/source-mode.d.ts +49 -0
- package/dist/markdown/source-mode.js +86 -0
- package/dist/markdown/source-mode.js.map +1 -0
- package/dist/markdown/vue.d.ts +2 -0
- package/dist/markdown/vue.js +1 -0
- package/dist/nuxt/module.d.ts +62 -0
- package/dist/nuxt/module.js +101 -0
- package/dist/nuxt/module.js.map +1 -0
- package/dist/nuxt/runtime/install-context.d.ts +16 -0
- package/dist/nuxt/runtime/install-context.js +25 -0
- package/dist/nuxt/runtime/install-context.js.map +1 -0
- package/dist/nuxt/runtime/plugins/editor-context-nuxt-ui.client.ts +8 -0
- package/dist/nuxt/runtime/server/api/ai/chat.post.d.ts +5 -0
- package/dist/nuxt/runtime/server/api/ai/chat.post.js +8 -0
- package/dist/nuxt/runtime/server/api/ai/chat.post.js.map +1 -0
- package/dist/nuxt/runtime/server/api/ai/complete.post.d.ts +5 -0
- package/dist/nuxt/runtime/server/api/ai/complete.post.js +8 -0
- package/dist/nuxt/runtime/server/api/ai/complete.post.js.map +1 -0
- package/dist/nuxt/runtime/server/api/ai/generate.post.d.ts +5 -0
- package/dist/nuxt/runtime/server/api/ai/generate.post.js +8 -0
- package/dist/nuxt/runtime/server/api/ai/generate.post.js.map +1 -0
- package/dist/nuxt/runtime/server/api/ai/models.get.d.ts +5 -0
- package/dist/nuxt/runtime/server/api/ai/models.get.js +8 -0
- package/dist/nuxt/runtime/server/api/ai/models.get.js.map +1 -0
- package/dist/nuxt/runtime/server/api/ai/transcribe.post.d.ts +5 -0
- package/dist/nuxt/runtime/server/api/ai/transcribe.post.js +8 -0
- package/dist/nuxt/runtime/server/api/ai/transcribe.post.js.map +1 -0
- package/dist/nuxt/runtime/server/api/ai/transcript-cleanup.post.d.ts +5 -0
- package/dist/nuxt/runtime/server/api/ai/transcript-cleanup.post.js +8 -0
- package/dist/nuxt/runtime/server/api/ai/transcript-cleanup.post.js.map +1 -0
- package/dist/nuxt/runtime/server/api/editor/assets/[id]/[name].get.d.ts +5 -0
- package/dist/nuxt/runtime/server/api/editor/assets/[id]/[name].get.js +8 -0
- package/dist/nuxt/runtime/server/api/editor/assets/[id]/[name].get.js.map +1 -0
- package/dist/nuxt/runtime/server/api/editor/assets/[id].post.d.ts +5 -0
- package/dist/nuxt/runtime/server/api/editor/assets/[id].post.js +8 -0
- package/dist/nuxt/runtime/server/api/editor/assets/[id].post.js.map +1 -0
- package/dist/nuxt/runtime/server/api/editor/settings.get.d.ts +5 -0
- package/dist/nuxt/runtime/server/api/editor/settings.get.js +8 -0
- package/dist/nuxt/runtime/server/api/editor/settings.get.js.map +1 -0
- package/dist/nuxt/runtime/server/api/editor/settings.put.d.ts +5 -0
- package/dist/nuxt/runtime/server/api/editor/settings.put.js +8 -0
- package/dist/nuxt/runtime/server/api/editor/settings.put.js.map +1 -0
- package/dist/nuxt/runtime/server/api/editor/tags.get.d.ts +5 -0
- package/dist/nuxt/runtime/server/api/editor/tags.get.js +8 -0
- package/dist/nuxt/runtime/server/api/editor/tags.get.js.map +1 -0
- package/dist/nuxt/runtime/server/api/editor/themes/[id].delete.d.ts +5 -0
- package/dist/nuxt/runtime/server/api/editor/themes/[id].delete.js +8 -0
- package/dist/nuxt/runtime/server/api/editor/themes/[id].delete.js.map +1 -0
- package/dist/nuxt/runtime/server/api/editor/themes/[id].get.d.ts +5 -0
- package/dist/nuxt/runtime/server/api/editor/themes/[id].get.js +8 -0
- package/dist/nuxt/runtime/server/api/editor/themes/[id].get.js.map +1 -0
- package/dist/nuxt/runtime/server/api/editor/themes/index.get.d.ts +5 -0
- package/dist/nuxt/runtime/server/api/editor/themes/index.get.js +8 -0
- package/dist/nuxt/runtime/server/api/editor/themes/index.get.js.map +1 -0
- package/dist/nuxt/runtime/server/api/editor/themes/index.post.d.ts +5 -0
- package/dist/nuxt/runtime/server/api/editor/themes/index.post.js +8 -0
- package/dist/nuxt/runtime/server/api/editor/themes/index.post.js.map +1 -0
- package/dist/nuxt/runtime/server/api/editor/users.get.d.ts +5 -0
- package/dist/nuxt/runtime/server/api/editor/users.get.js +8 -0
- package/dist/nuxt/runtime/server/api/editor/users.get.js.map +1 -0
- package/dist/nuxt/runtime/server/plugins/collab.d.ts +5 -0
- package/dist/nuxt/runtime/server/plugins/collab.js +10 -0
- package/dist/nuxt/runtime/server/plugins/collab.js.map +1 -0
- package/dist/nuxt/runtime/server/plugins/editor-server.d.ts +5 -0
- package/dist/nuxt/runtime/server/plugins/editor-server.js +20 -0
- package/dist/nuxt/runtime/server/plugins/editor-server.js.map +1 -0
- package/dist/nuxt/runtime/server/routes/collab/[id].d.ts +5 -0
- package/dist/nuxt/runtime/server/routes/collab/[id].js +35 -0
- package/dist/nuxt/runtime/server/routes/collab/[id].js.map +1 -0
- package/dist/nuxt/runtime/server/utils/editor-route.d.ts +11 -0
- package/dist/nuxt/runtime/server/utils/editor-route.js +49 -0
- package/dist/nuxt/runtime/server/utils/editor-route.js.map +1 -0
- package/dist/outline/EditorOutline.js +124 -0
- package/dist/outline/EditorOutline.js.map +1 -0
- package/dist/outline/EditorOutline.vue.d.ts +15 -0
- package/dist/outline/heading-outline.d.ts +26 -0
- package/dist/outline/heading-outline.js +46 -0
- package/dist/outline/heading-outline.js.map +1 -0
- package/dist/outline/index.d.ts +2 -0
- package/dist/outline/index.js +1 -0
- package/dist/outline/react/EditorOutline.d.ts +12 -0
- package/dist/outline/react/EditorOutline.js +112 -0
- package/dist/outline/react/EditorOutline.js.map +1 -0
- package/dist/outline/react.d.ts +2 -0
- package/dist/outline/react.js +1 -0
- package/dist/outline/vue.d.ts +2 -0
- package/dist/outline/vue.js +1 -0
- package/dist/presets/advanced.d.ts +33 -0
- package/dist/presets/advanced.js +50 -0
- package/dist/presets/advanced.js.map +1 -0
- package/dist/presets/simple.d.ts +9 -0
- package/dist/presets/simple.js +12 -0
- package/dist/presets/simple.js.map +1 -0
- package/dist/react/AdvancedEditor.d.ts +23 -0
- package/dist/react/AdvancedEditor.js +24 -0
- package/dist/react/AdvancedEditor.js.map +1 -0
- package/dist/react/EditorSettingsModal.d.ts +14 -0
- package/dist/react/EditorSettingsModal.js +40 -0
- package/dist/react/EditorSettingsModal.js.map +1 -0
- package/dist/react/EditorSettingsPanel.d.ts +18 -0
- package/dist/react/EditorSettingsPanel.js +40 -0
- package/dist/react/EditorSettingsPanel.js.map +1 -0
- package/dist/react/EditorSurface.d.ts +61 -0
- package/dist/react/EditorSurface.js +277 -0
- package/dist/react/EditorSurface.js.map +1 -0
- package/dist/react/EditorToolbar.d.ts +15 -0
- package/dist/react/EditorToolbar.js +182 -0
- package/dist/react/EditorToolbar.js.map +1 -0
- package/dist/react/Icon.d.ts +13 -0
- package/dist/react/Icon.js +19 -0
- package/dist/react/Icon.js.map +1 -0
- package/dist/react/SettingsSection.d.ts +10 -0
- package/dist/react/SettingsSection.js +22 -0
- package/dist/react/SettingsSection.js.map +1 -0
- package/dist/react/SimpleEditor.d.ts +27 -0
- package/dist/react/SimpleEditor.js +22 -0
- package/dist/react/SimpleEditor.js.map +1 -0
- package/dist/react/advanced-preset.d.ts +11 -0
- package/dist/react/advanced-preset.js +31 -0
- package/dist/react/advanced-preset.js.map +1 -0
- package/dist/react/advanced.d.ts +4 -0
- package/dist/react/advanced.js +3 -0
- package/dist/react/context.d.ts +12 -0
- package/dist/react/context.js +21 -0
- package/dist/react/context.js.map +1 -0
- package/dist/react/editor-ui.d.ts +14 -0
- package/dist/react/editor-ui.js +20 -0
- package/dist/react/editor-ui.js.map +1 -0
- package/dist/react/index.d.ts +17 -0
- package/dist/react/index.js +17 -0
- package/dist/react/notify.d.ts +6 -0
- package/dist/react/notify.js +25 -0
- package/dist/react/notify.js.map +1 -0
- package/dist/react/settings.d.ts +17 -0
- package/dist/react/settings.js +27 -0
- package/dist/react/settings.js.map +1 -0
- package/dist/react/simple.d.ts +2 -0
- package/dist/react/simple.js +1 -0
- package/dist/react/styles/advanced.css +18 -0
- package/dist/react/styles/themes-bridge.css +26 -0
- package/dist/react/styles/ui-vars.css +20 -0
- package/dist/react/suggestion-renderer.d.ts +12 -0
- package/dist/react/suggestion-renderer.js +90 -0
- package/dist/react/suggestion-renderer.js.map +1 -0
- package/dist/react/ui/alert.js +38 -0
- package/dist/react/ui/alert.js.map +1 -0
- package/dist/react/ui/avatar.js +24 -0
- package/dist/react/ui/avatar.js.map +1 -0
- package/dist/react/ui/badge.js +30 -0
- package/dist/react/ui/badge.js.map +1 -0
- package/dist/react/ui/button.js +50 -0
- package/dist/react/ui/button.js.map +1 -0
- package/dist/react/ui/collapsible.js +19 -0
- package/dist/react/ui/collapsible.js.map +1 -0
- package/dist/react/ui/command.js +47 -0
- package/dist/react/ui/command.js.map +1 -0
- package/dist/react/ui/dialog.js +88 -0
- package/dist/react/ui/dialog.js.map +1 -0
- package/dist/react/ui/dropdown-menu.js +70 -0
- package/dist/react/ui/dropdown-menu.js.map +1 -0
- package/dist/react/ui/input-group.js +57 -0
- package/dist/react/ui/input-group.js.map +1 -0
- package/dist/react/ui/input.js +16 -0
- package/dist/react/ui/input.js.map +1 -0
- package/dist/react/ui/label.js +17 -0
- package/dist/react/ui/label.js.map +1 -0
- package/dist/react/ui/popover.js +36 -0
- package/dist/react/ui/popover.js.map +1 -0
- package/dist/react/ui/radio-group.js +29 -0
- package/dist/react/ui/radio-group.js.map +1 -0
- package/dist/react/ui/select.js +88 -0
- package/dist/react/ui/select.js.map +1 -0
- package/dist/react/ui/separator.js +18 -0
- package/dist/react/ui/separator.js.map +1 -0
- package/dist/react/ui/switch.js +21 -0
- package/dist/react/ui/switch.js.map +1 -0
- package/dist/react/ui/table.js +44 -0
- package/dist/react/ui/table.js.map +1 -0
- package/dist/react/ui/tabs.js +41 -0
- package/dist/react/ui/tabs.js.map +1 -0
- package/dist/react/ui/textarea.js +15 -0
- package/dist/react/ui/textarea.js.map +1 -0
- package/dist/react/ui/tooltip.js +37 -0
- package/dist/react/ui/tooltip.js.map +1 -0
- package/dist/react/ui/utils.d.ts +5 -0
- package/dist/react/ui/utils.js +10 -0
- package/dist/react/ui/utils.js.map +1 -0
- package/dist/react/use-editor-i18n.d.ts +12 -0
- package/dist/react/use-editor-i18n.js +17 -0
- package/dist/react/use-editor-i18n.js.map +1 -0
- package/dist/react/use-notifier.d.ts +11 -0
- package/dist/react/use-notifier.js +25 -0
- package/dist/react/use-notifier.js.map +1 -0
- package/dist/react/use-store.d.ts +6 -0
- package/dist/react/use-store.js +10 -0
- package/dist/react/use-store.js.map +1 -0
- package/dist/schema/advanced.d.ts +14 -0
- package/dist/schema/advanced.js +43 -0
- package/dist/schema/advanced.js.map +1 -0
- package/dist/schema/simple.d.ts +10 -0
- package/dist/schema/simple.js +13 -0
- package/dist/schema/simple.js.map +1 -0
- package/dist/server/adapter.d.ts +101 -0
- package/dist/server/ai.d.ts +101 -0
- package/dist/server/ai.js +105 -0
- package/dist/server/ai.js.map +1 -0
- package/dist/server/collab-state.d.ts +16 -0
- package/dist/server/collab-state.js +43 -0
- package/dist/server/collab-state.js.map +1 -0
- package/dist/server/collab.d.ts +68 -0
- package/dist/server/collab.js +187 -0
- package/dist/server/collab.js.map +1 -0
- package/dist/server/errors.d.ts +17 -0
- package/dist/server/errors.js +26 -0
- package/dist/server/errors.js.map +1 -0
- package/dist/server/handlers/ai.d.ts +223 -0
- package/dist/server/handlers/ai.js +422 -0
- package/dist/server/handlers/ai.js.map +1 -0
- package/dist/server/handlers/context.d.ts +64 -0
- package/dist/server/handlers/context.js +85 -0
- package/dist/server/handlers/context.js.map +1 -0
- package/dist/server/handlers/editor.d.ts +107 -0
- package/dist/server/handlers/editor.js +241 -0
- package/dist/server/handlers/editor.js.map +1 -0
- package/dist/server/handlers/index.d.ts +4 -0
- package/dist/server/handlers/index.js +4 -0
- package/dist/server/host.d.ts +61 -0
- package/dist/server/host.js +105 -0
- package/dist/server/host.js.map +1 -0
- package/dist/server/index.d.ts +8 -0
- package/dist/server/index.js +7 -0
- package/dist/server/node.d.ts +24 -0
- package/dist/server/node.js +54 -0
- package/dist/server/node.js.map +1 -0
- package/dist/server/rate-limit.d.ts +22 -0
- package/dist/server/rate-limit.js +34 -0
- package/dist/server/rate-limit.js.map +1 -0
- package/dist/settings/index.d.ts +110 -0
- package/dist/settings/index.js +114 -0
- package/dist/settings/index.js.map +1 -0
- package/dist/settings/values.d.ts +35 -0
- package/dist/settings/values.js +41 -0
- package/dist/settings/values.js.map +1 -0
- package/dist/styles/ai.css +77 -0
- package/dist/styles/authors.css +18 -0
- package/dist/styles/block-ui.css +16 -0
- package/dist/styles/collab.css +26 -0
- package/dist/styles/comments.css +11 -0
- package/dist/styles/composites.css +56 -0
- package/dist/styles/core.css +99 -0
- package/dist/styles/media.css +8 -0
- package/dist/styles/mentions.css +24 -0
- package/dist/styles/tables.css +25 -0
- package/dist/styles/themes.css +622 -0
- package/dist/styles/tokens.css +29 -0
- package/dist/styles/transcript.css +13 -0
- package/dist/tree/DocumentTree.js +595 -0
- package/dist/tree/DocumentTree.js.map +1 -0
- package/dist/tree/DocumentTree.vue.d.ts +36 -0
- package/dist/tree/folder-paths.js +11 -0
- package/dist/tree/folder-paths.js.map +1 -0
- package/dist/tree/index.d.ts +4 -0
- package/dist/tree/index.js +1 -0
- package/dist/tree/react/DocumentTree.d.ts +24 -0
- package/dist/tree/react/DocumentTree.js +579 -0
- package/dist/tree/react/DocumentTree.js.map +1 -0
- package/dist/tree/react/use-tree-view.d.ts +14 -0
- package/dist/tree/react/use-tree-view.js +21 -0
- package/dist/tree/react/use-tree-view.js.map +1 -0
- package/dist/tree/react.d.ts +3 -0
- package/dist/tree/react.js +3 -0
- package/dist/tree/store.d.ts +45 -0
- package/dist/tree/tree-items.js +221 -0
- package/dist/tree/tree-items.js.map +1 -0
- package/dist/tree/tree-view-model.d.ts +29 -0
- package/dist/tree/tree-view-model.js +71 -0
- package/dist/tree/tree-view-model.js.map +1 -0
- package/dist/tree/tree-view.d.ts +15 -0
- package/dist/tree/tree-view.js +21 -0
- package/dist/tree/tree-view.js.map +1 -0
- package/dist/tree/types.d.ts +23 -0
- package/dist/tree/types.js +0 -0
- package/dist/tree/vue.d.ts +3 -0
- package/dist/tree/vue.js +3 -0
- package/dist/vue/AdvancedEditor.js +100 -0
- package/dist/vue/AdvancedEditor.js.map +1 -0
- package/dist/vue/AdvancedEditor.vue.d.ts +71 -0
- package/dist/vue/SimpleEditor.js +61 -0
- package/dist/vue/SimpleEditor.js.map +1 -0
- package/dist/vue/SimpleEditor.vue.d.ts +36 -0
- package/dist/vue/advanced-preset.d.ts +13 -0
- package/dist/vue/advanced-preset.js +33 -0
- package/dist/vue/advanced-preset.js.map +1 -0
- package/dist/vue/advanced.d.ts +3 -0
- package/dist/vue/advanced.js +3 -0
- package/dist/vue/components/EditorSettingsModal.js +69 -0
- package/dist/vue/components/EditorSettingsModal.js.map +1 -0
- package/dist/vue/components/EditorSettingsModal.vue.d.ts +24 -0
- package/dist/vue/components/EditorSettingsPanel.js +58 -0
- package/dist/vue/components/EditorSettingsPanel.js.map +1 -0
- package/dist/vue/components/EditorSettingsPanel.vue.d.ts +29 -0
- package/dist/vue/components/EditorSurface.js +229 -0
- package/dist/vue/components/EditorSurface.js.map +1 -0
- package/dist/vue/components/EditorSurface.vue.d.ts +68 -0
- package/dist/vue/components/EditorToolbar.js +189 -0
- package/dist/vue/components/EditorToolbar.js.map +1 -0
- package/dist/vue/components/EditorToolbar.vue.d.ts +17 -0
- package/dist/vue/components/SettingsSection.js +26 -0
- package/dist/vue/components/SettingsSection.js.map +1 -0
- package/dist/vue/components/SettingsSection.vue.d.ts +21 -0
- package/dist/vue/components/SuggestionList.js +91 -0
- package/dist/vue/components/SuggestionList.js.map +1 -0
- package/dist/vue/components/SuggestionList.vue.d.ts +19 -0
- package/dist/vue/context.d.ts +24 -0
- package/dist/vue/context.js +42 -0
- package/dist/vue/context.js.map +1 -0
- package/dist/vue/index.d.ts +26 -0
- package/dist/vue/index.js +16 -0
- package/dist/vue/kit/index.d.ts +3 -0
- package/dist/vue/kit/index.js +1 -0
- package/dist/vue/kit/nuxt-ui.css +24 -0
- package/dist/vue/kit/nuxt-ui.d.ts +31 -0
- package/dist/vue/kit/nuxt-ui.js +101 -0
- package/dist/vue/kit/nuxt-ui.js.map +1 -0
- package/dist/vue/kit/types.d.ts +370 -0
- package/dist/vue/kit/use-ui-kit.d.ts +12 -0
- package/dist/vue/kit/use-ui-kit.js +17 -0
- package/dist/vue/kit/use-ui-kit.js.map +1 -0
- package/dist/vue/notify.d.ts +12 -0
- package/dist/vue/notify.js +27 -0
- package/dist/vue/notify.js.map +1 -0
- package/dist/vue/settings.d.ts +16 -0
- package/dist/vue/settings.js +64 -0
- package/dist/vue/settings.js.map +1 -0
- package/dist/vue/simple.d.ts +2 -0
- package/dist/vue/simple.js +1 -0
- package/dist/vue/store-ref.d.ts +20 -0
- package/dist/vue/store-ref.js +59 -0
- package/dist/vue/store-ref.js.map +1 -0
- package/dist/vue/suggestion-renderer.d.ts +6 -0
- package/dist/vue/suggestion-renderer.js +20 -0
- package/dist/vue/suggestion-renderer.js.map +1 -0
- package/dist/vue/use-editor-i18n.d.ts +12 -0
- package/dist/vue/use-editor-i18n.js +17 -0
- package/dist/vue/use-editor-i18n.js.map +1 -0
- package/dist/vue/use-editor-ui.d.ts +15 -0
- package/dist/vue/use-editor-ui.js +23 -0
- package/dist/vue/use-editor-ui.js.map +1 -0
- package/dist/vue/use-notifier.d.ts +11 -0
- package/dist/vue/use-notifier.js +19 -0
- package/dist/vue/use-notifier.js.map +1 -0
- package/docs/extending.md +538 -0
- package/docs/integration.md +537 -0
- package/docs/llms.md +375 -0
- package/docs/usage.md +1071 -0
- package/package.json +619 -4
|
@@ -0,0 +1,142 @@
|
|
|
1
|
+
import { useUiKit } from "../../../vue/kit/use-ui-kit.js";
|
|
2
|
+
import { blockActionsFor, effectiveTarget } from "../block-actions.js";
|
|
3
|
+
import { Fragment, computed, createBlock, createCommentVNode, createElementBlock, createVNode, defineComponent, normalizeStyle, onBeforeUnmount, onMounted, openBlock, ref, renderList, unref, useTemplateRef, watch, withCtx, withModifiers } from "vue";
|
|
4
|
+
//#region src/features/block-ui/components/BlockActionsOverlay.vue
|
|
5
|
+
/** Gap between the bar and the editor's right edge. */
|
|
6
|
+
const EDGE_GUTTER = 8;
|
|
7
|
+
/**
|
|
8
|
+
* The hover actions of a block, right-aligned at the editor's text column (the drag handle sits on the block's left and
|
|
9
|
+
* targets the same block). Positioned absolutely inside `host`, a `relative` element around the editor; the composite
|
|
10
|
+
* chrome (title, description, tags) addresses the composite (`effectiveTarget`). The bar is hidden while the editor is
|
|
11
|
+
* read-only. `menu` actions open a dropdown of their items instead of running on click.
|
|
12
|
+
*/
|
|
13
|
+
const _sfc_main = /*@__PURE__*/ defineComponent({
|
|
14
|
+
__name: "BlockActionsOverlay",
|
|
15
|
+
props: {
|
|
16
|
+
editor: {},
|
|
17
|
+
target: {},
|
|
18
|
+
actions: {},
|
|
19
|
+
host: {}
|
|
20
|
+
},
|
|
21
|
+
emits: ["hover"],
|
|
22
|
+
setup(__props, { emit: __emit }) {
|
|
23
|
+
const props = __props;
|
|
24
|
+
const { Button: UButton, DropdownMenu: UDropdownMenu, Tooltip: UTooltip } = useUiKit();
|
|
25
|
+
const emit = __emit;
|
|
26
|
+
/** The target in the current document; null once its position holds something else (deleted, replaced). */
|
|
27
|
+
const block = computed(() => {
|
|
28
|
+
const { editor, target } = props;
|
|
29
|
+
if (!target || editor.isDestroyed) return null;
|
|
30
|
+
const { doc } = editor.state;
|
|
31
|
+
if (target.pos < 0 || target.pos >= doc.content.size) return null;
|
|
32
|
+
const node = doc.nodeAt(target.pos);
|
|
33
|
+
if (!node || node.type !== target.node.type) return null;
|
|
34
|
+
return effectiveTarget(editor, {
|
|
35
|
+
node,
|
|
36
|
+
pos: target.pos
|
|
37
|
+
});
|
|
38
|
+
});
|
|
39
|
+
const editable = computed(() => {
|
|
40
|
+
props.editor.state;
|
|
41
|
+
return props.editor.isEditable;
|
|
42
|
+
});
|
|
43
|
+
const items = computed(() => block.value ? blockActionsFor(props.editor, block.value, props.actions) : []);
|
|
44
|
+
const top = ref(0);
|
|
45
|
+
const right = ref(0);
|
|
46
|
+
const measured = ref(false);
|
|
47
|
+
function measure() {
|
|
48
|
+
const { editor, host } = props;
|
|
49
|
+
const dom = block.value && host && !editor.isDestroyed ? editor.view.nodeDOM(block.value.pos) : null;
|
|
50
|
+
measured.value = dom instanceof HTMLElement;
|
|
51
|
+
if (!(dom instanceof HTMLElement) || !host) return;
|
|
52
|
+
const hostRect = host.getBoundingClientRect();
|
|
53
|
+
const rect = dom.getBoundingClientRect();
|
|
54
|
+
top.value = rect.top - hostRect.top + 2;
|
|
55
|
+
right.value = hostRect.right - editor.view.dom.getBoundingClientRect().right + EDGE_GUTTER;
|
|
56
|
+
}
|
|
57
|
+
watch([block, () => props.editor.state], measure, { flush: "post" });
|
|
58
|
+
const visible = computed(() => editable.value && items.value.length > 0 && measured.value);
|
|
59
|
+
const root = useTemplateRef("root");
|
|
60
|
+
const menuOpen = ref(false);
|
|
61
|
+
function onMenuOpen(open) {
|
|
62
|
+
menuOpen.value = open;
|
|
63
|
+
emit("hover", open || !!root.value?.matches(":hover"));
|
|
64
|
+
}
|
|
65
|
+
function onMouseLeave() {
|
|
66
|
+
if (!menuOpen.value) emit("hover", false);
|
|
67
|
+
}
|
|
68
|
+
watch(visible, (value) => {
|
|
69
|
+
if (value) return;
|
|
70
|
+
menuOpen.value = false;
|
|
71
|
+
emit("hover", false);
|
|
72
|
+
});
|
|
73
|
+
let resizeObserver;
|
|
74
|
+
onMounted(() => {
|
|
75
|
+
window.addEventListener("resize", measure);
|
|
76
|
+
window.addEventListener("scroll", measure, true);
|
|
77
|
+
resizeObserver = new ResizeObserver(measure);
|
|
78
|
+
resizeObserver.observe(props.editor.view.dom);
|
|
79
|
+
});
|
|
80
|
+
onBeforeUnmount(() => {
|
|
81
|
+
window.removeEventListener("resize", measure);
|
|
82
|
+
window.removeEventListener("scroll", measure, true);
|
|
83
|
+
resizeObserver?.disconnect();
|
|
84
|
+
});
|
|
85
|
+
return (_ctx, _cache) => {
|
|
86
|
+
return visible.value ? (openBlock(), createElementBlock("div", {
|
|
87
|
+
key: 0,
|
|
88
|
+
ref_key: "root",
|
|
89
|
+
ref: root,
|
|
90
|
+
class: "block-actions absolute z-10 flex gap-0.5 rounded-md border border-[var(--sk-border)] bg-[var(--sk-bg)] p-0.5 shadow-sm",
|
|
91
|
+
style: normalizeStyle({
|
|
92
|
+
top: `${top.value}px`,
|
|
93
|
+
right: `${right.value}px`
|
|
94
|
+
}),
|
|
95
|
+
onMouseenter: _cache[2] || (_cache[2] = ($event) => emit("hover", true)),
|
|
96
|
+
onMouseleave: onMouseLeave
|
|
97
|
+
}, [(openBlock(true), createElementBlock(Fragment, null, renderList(items.value, (entry) => {
|
|
98
|
+
return openBlock(), createElementBlock(Fragment, { key: entry.action.id }, [entry.menu ? (openBlock(), createBlock(unref(UDropdownMenu), {
|
|
99
|
+
key: 0,
|
|
100
|
+
items: entry.menu,
|
|
101
|
+
content: { align: "end" },
|
|
102
|
+
"onUpdate:open": onMenuOpen
|
|
103
|
+
}, {
|
|
104
|
+
default: withCtx(() => [createVNode(unref(UTooltip), { text: entry.action.label }, {
|
|
105
|
+
default: withCtx(() => [createVNode(unref(UButton), {
|
|
106
|
+
size: "xs",
|
|
107
|
+
color: "neutral",
|
|
108
|
+
variant: "ghost",
|
|
109
|
+
icon: entry.action.icon,
|
|
110
|
+
"aria-label": entry.action.label,
|
|
111
|
+
onMousedown: _cache[0] || (_cache[0] = withModifiers(() => {}, ["prevent"]))
|
|
112
|
+
}, null, 8, ["icon", "aria-label"])]),
|
|
113
|
+
_: 2
|
|
114
|
+
}, 1032, ["text"])]),
|
|
115
|
+
_: 2
|
|
116
|
+
}, 1032, ["items"])) : (openBlock(), createBlock(unref(UTooltip), {
|
|
117
|
+
key: 1,
|
|
118
|
+
text: entry.action.label
|
|
119
|
+
}, {
|
|
120
|
+
default: withCtx(() => [createVNode(unref(UButton), {
|
|
121
|
+
size: "xs",
|
|
122
|
+
color: "neutral",
|
|
123
|
+
variant: "ghost",
|
|
124
|
+
icon: entry.action.icon,
|
|
125
|
+
"aria-label": entry.action.label,
|
|
126
|
+
onMousedown: _cache[1] || (_cache[1] = withModifiers(() => {}, ["prevent"])),
|
|
127
|
+
onClick: ($event) => entry.action.run?.(entry.ctx)
|
|
128
|
+
}, null, 8, [
|
|
129
|
+
"icon",
|
|
130
|
+
"aria-label",
|
|
131
|
+
"onClick"
|
|
132
|
+
])]),
|
|
133
|
+
_: 2
|
|
134
|
+
}, 1032, ["text"]))], 64);
|
|
135
|
+
}), 128))], 36)) : createCommentVNode("v-if", true);
|
|
136
|
+
};
|
|
137
|
+
}
|
|
138
|
+
});
|
|
139
|
+
//#endregion
|
|
140
|
+
export { _sfc_main as default };
|
|
141
|
+
|
|
142
|
+
//# sourceMappingURL=BlockActionsOverlay.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"BlockActionsOverlay.js","names":["_openBlock","_createElementBlock","_normalizeStyle","_Fragment","_renderList","_createBlock","_unref","_withCtx","_createVNode","_withModifiers","_createCommentVNode"],"sources":["../../../../src/features/block-ui/components/BlockActionsOverlay.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport { useUiKit } from '../../../vue/kit/use-ui-kit'\nimport type { Editor } from '@tiptap/vue-3'\nimport { computed, onBeforeUnmount, onMounted, ref, useTemplateRef, watch } from 'vue'\nimport type { BlockAction, BlockTarget } from '../../../core'\nimport { blockActionsFor, effectiveTarget } from '../block-actions'\n\n/** Gap between the bar and the editor's right edge. */\nconst EDGE_GUTTER = 8\n\n/**\n * The hover actions of a block, right-aligned at the editor's text column (the drag handle sits on the block's left and\n * targets the same block). Positioned absolutely inside `host`, a `relative` element around the editor; the composite\n * chrome (title, description, tags) addresses the composite (`effectiveTarget`). The bar is hidden while the editor is\n * read-only. `menu` actions open a dropdown of their items instead of running on click.\n */\nconst props = defineProps<{\n editor: Editor\n target: BlockTarget | null\n actions: readonly BlockAction[]\n host: HTMLElement | null\n}>()\n\nconst { Button: UButton, DropdownMenu: UDropdownMenu, Tooltip: UTooltip } = useUiKit()\n\nconst emit = defineEmits<{ hover: [hovered: boolean] }>()\n\n/** The target in the current document; null once its position holds something else (deleted, replaced). */\nconst block = computed<BlockTarget | null>(() => {\n const { editor, target } = props\n if (!target || editor.isDestroyed) return null\n const { doc } = editor.state\n if (target.pos < 0 || target.pos >= doc.content.size) return null\n const node = doc.nodeAt(target.pos)\n if (!node || node.type !== target.node.type) return null\n return effectiveTarget(editor, { node, pos: target.pos })\n})\n\n// Reading `state` makes the flag follow `setEditable` (which dispatches a transaction).\nconst editable = computed(() => {\n void props.editor.state\n return props.editor.isEditable\n})\n\nconst items = computed(() => (block.value ? blockActionsFor(props.editor, block.value, props.actions) : []))\n\nconst top = ref(0)\nconst right = ref(0)\nconst measured = ref(false)\n\nfunction measure() {\n const { editor, host } = props\n const dom = block.value && host && !editor.isDestroyed ? editor.view.nodeDOM(block.value.pos) : null\n measured.value = dom instanceof HTMLElement\n if (!(dom instanceof HTMLElement) || !host) return\n const hostRect = host.getBoundingClientRect()\n const rect = dom.getBoundingClientRect()\n top.value = rect.top - hostRect.top + 2\n right.value = hostRect.right - editor.view.dom.getBoundingClientRect().right + EDGE_GUTTER\n}\n\nwatch([block, () => props.editor.state], measure, { flush: 'post' })\n\nconst visible = computed(() => editable.value && items.value.length > 0 && measured.value)\n\n// An open action menu is rendered outside the overlay (portal): the overlay counts as hovered until the menu closes.\nconst root = useTemplateRef<HTMLElement>('root')\nconst menuOpen = ref(false)\nfunction onMenuOpen(open: boolean) {\n menuOpen.value = open\n emit('hover', open || !!root.value?.matches(':hover'))\n}\nfunction onMouseLeave() {\n if (!menuOpen.value) emit('hover', false)\n}\n\n// A vanishing overlay sends no mouseleave: report it, so the host does not keep waiting for one.\nwatch(visible, (value) => {\n if (value) return\n menuOpen.value = false\n emit('hover', false)\n})\n\n// The bar follows the editor's right edge when the column resizes without the window doing so.\nlet resizeObserver: ResizeObserver | undefined\nonMounted(() => {\n window.addEventListener('resize', measure)\n window.addEventListener('scroll', measure, true)\n resizeObserver = new ResizeObserver(measure)\n resizeObserver.observe(props.editor.view.dom)\n})\n\nonBeforeUnmount(() => {\n window.removeEventListener('resize', measure)\n window.removeEventListener('scroll', measure, true)\n resizeObserver?.disconnect()\n})\n</script>\n\n<template>\n <div\n v-if=\"visible\"\n ref=\"root\"\n class=\"block-actions absolute z-10 flex gap-0.5 rounded-md border border-[var(--sk-border)] bg-[var(--sk-bg)] p-0.5 shadow-sm\"\n :style=\"{ top: `${top}px`, right: `${right}px` }\"\n @mouseenter=\"emit('hover', true)\"\n @mouseleave=\"onMouseLeave\"\n >\n <template v-for=\"entry in items\" :key=\"entry.action.id\">\n <UDropdownMenu v-if=\"entry.menu\" :items=\"entry.menu\" :content=\"{ align: 'end' }\" @update:open=\"onMenuOpen\">\n <UTooltip :text=\"entry.action.label\">\n <UButton\n size=\"xs\"\n color=\"neutral\"\n variant=\"ghost\"\n :icon=\"entry.action.icon\"\n :aria-label=\"entry.action.label\"\n @mousedown.prevent\n />\n </UTooltip>\n </UDropdownMenu>\n <UTooltip v-else :text=\"entry.action.label\">\n <UButton\n size=\"xs\"\n color=\"neutral\"\n variant=\"ghost\"\n :icon=\"entry.action.icon\"\n :aria-label=\"entry.action.label\"\n @mousedown.prevent\n @click=\"entry.action.run?.(entry.ctx)\"\n />\n </UTooltip>\n </template>\n </div>\n</template>\n"],"mappings":"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"}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { BlockAction, BlockTarget } from "../../../core/extension-points.js";
|
|
2
|
+
import "../../../core/index.js";
|
|
3
|
+
import { Editor } from "@tiptap/vue-3";
|
|
4
|
+
//#region src/features/block-ui/components/BlockActionsOverlay.vue.d.ts
|
|
5
|
+
/**
|
|
6
|
+
* The hover actions of a block, right-aligned at the editor's text column (the drag handle sits on the block's left and
|
|
7
|
+
* targets the same block). Positioned absolutely inside `host`, a `relative` element around the editor; the composite
|
|
8
|
+
* chrome (title, description, tags) addresses the composite (`effectiveTarget`). The bar is hidden while the editor is
|
|
9
|
+
* read-only. `menu` actions open a dropdown of their items instead of running on click.
|
|
10
|
+
*/
|
|
11
|
+
type __VLS_Props = {
|
|
12
|
+
editor: Editor;
|
|
13
|
+
target: BlockTarget | null;
|
|
14
|
+
actions: readonly BlockAction[];
|
|
15
|
+
host: HTMLElement | null;
|
|
16
|
+
};
|
|
17
|
+
declare const __VLS_export: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
18
|
+
hover: (hovered: boolean) => any;
|
|
19
|
+
}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
20
|
+
onHover?: ((hovered: boolean) => any) | undefined;
|
|
21
|
+
}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
22
|
+
declare const _default: typeof __VLS_export;
|
|
23
|
+
//#endregion
|
|
24
|
+
export { _default as default };
|
|
25
|
+
//# sourceMappingURL=BlockActionsOverlay.vue.d.ts.map
|
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
import { startBlockDrag } from "../../../core/block-drag.js";
|
|
2
|
+
import { useUiKit } from "../../../vue/kit/use-ui-kit.js";
|
|
3
|
+
import { firstLineCenterShift, gutterShiftOf, handleBlocksOf } from "../handle-geometry.js";
|
|
4
|
+
import { Fragment, createElementBlock, createVNode, defineComponent, normalizeClass, normalizeStyle, onBeforeUnmount, onMounted, openBlock, renderList, shallowRef, unref } from "vue";
|
|
5
|
+
//#region src/features/block-ui/components/BlockHandles.vue
|
|
6
|
+
const _hoisted_1 = { class: "absolute left-0 top-0 z-10 h-0 w-0" };
|
|
7
|
+
const _hoisted_2 = ["onDragstart"];
|
|
8
|
+
const _sfc_main = /*@__PURE__*/ defineComponent({
|
|
9
|
+
__name: "BlockHandles",
|
|
10
|
+
props: {
|
|
11
|
+
editor: {},
|
|
12
|
+
host: {}
|
|
13
|
+
},
|
|
14
|
+
setup(__props) {
|
|
15
|
+
const props = __props;
|
|
16
|
+
const { Icon: UIcon } = useUiKit();
|
|
17
|
+
const handles = shallowRef([]);
|
|
18
|
+
const dragging = shallowRef(false);
|
|
19
|
+
let raf = 0;
|
|
20
|
+
let wasEditable = false;
|
|
21
|
+
function schedule() {
|
|
22
|
+
if (!raf) raf = requestAnimationFrame(measure);
|
|
23
|
+
}
|
|
24
|
+
function measure() {
|
|
25
|
+
raf = 0;
|
|
26
|
+
const { editor, host } = props;
|
|
27
|
+
wasEditable = !editor.isDestroyed && editor.isEditable;
|
|
28
|
+
if (!wasEditable || !editor.view.dom.getClientRects().length) {
|
|
29
|
+
if (handles.value.length) handles.value = [];
|
|
30
|
+
return;
|
|
31
|
+
}
|
|
32
|
+
const hostRect = host.getBoundingClientRect();
|
|
33
|
+
const originX = hostRect.left + host.clientLeft;
|
|
34
|
+
const originY = hostRect.top + host.clientTop;
|
|
35
|
+
const next = [];
|
|
36
|
+
for (const { node, pos, dom } of handleBlocksOf(editor.view)) {
|
|
37
|
+
const rect = dom.getBoundingClientRect();
|
|
38
|
+
if (!rect.height || rect.bottom < -window.innerHeight || rect.top > 2 * window.innerHeight) continue;
|
|
39
|
+
const left = rect.left - 24 - gutterShiftOf(node, dom) - originX;
|
|
40
|
+
const top = rect.top + firstLineCenterShift(dom, rect.top, 24) - originY;
|
|
41
|
+
if (!next.some((other) => Math.abs(top - other.top) < 12 && left < other.left + 24 && other.left < left + 24)) next.push({
|
|
42
|
+
pos,
|
|
43
|
+
left,
|
|
44
|
+
top
|
|
45
|
+
});
|
|
46
|
+
}
|
|
47
|
+
const prev = handles.value;
|
|
48
|
+
if (prev.length !== next.length || next.some((h, i) => {
|
|
49
|
+
const before = prev[i];
|
|
50
|
+
return !before || h.pos !== before.pos || h.left !== before.left || h.top !== before.top;
|
|
51
|
+
})) handles.value = next;
|
|
52
|
+
}
|
|
53
|
+
function onTransaction({ transaction }) {
|
|
54
|
+
if (transaction.docChanged || props.editor.isEditable !== wasEditable) schedule();
|
|
55
|
+
}
|
|
56
|
+
let resizeObserver;
|
|
57
|
+
onMounted(() => {
|
|
58
|
+
props.editor.on("transaction", onTransaction);
|
|
59
|
+
window.addEventListener("resize", schedule);
|
|
60
|
+
window.addEventListener("scroll", schedule, true);
|
|
61
|
+
resizeObserver = new ResizeObserver(schedule);
|
|
62
|
+
resizeObserver.observe(props.editor.view.dom);
|
|
63
|
+
schedule();
|
|
64
|
+
});
|
|
65
|
+
onBeforeUnmount(() => {
|
|
66
|
+
props.editor.off("transaction", onTransaction);
|
|
67
|
+
window.removeEventListener("resize", schedule);
|
|
68
|
+
window.removeEventListener("scroll", schedule, true);
|
|
69
|
+
resizeObserver?.disconnect();
|
|
70
|
+
if (raf) cancelAnimationFrame(raf);
|
|
71
|
+
});
|
|
72
|
+
function onDragStart(event, pos) {
|
|
73
|
+
if (!startBlockDrag(props.editor, event, pos)) {
|
|
74
|
+
event.preventDefault();
|
|
75
|
+
return;
|
|
76
|
+
}
|
|
77
|
+
setTimeout(() => {
|
|
78
|
+
dragging.value = true;
|
|
79
|
+
});
|
|
80
|
+
const abort = new AbortController();
|
|
81
|
+
const end = () => {
|
|
82
|
+
dragging.value = false;
|
|
83
|
+
abort.abort();
|
|
84
|
+
};
|
|
85
|
+
document.addEventListener("drop", end, { signal: abort.signal });
|
|
86
|
+
document.addEventListener("dragend", end, { signal: abort.signal });
|
|
87
|
+
}
|
|
88
|
+
return (_ctx, _cache) => {
|
|
89
|
+
return openBlock(), createElementBlock("div", _hoisted_1, [(openBlock(true), createElementBlock(Fragment, null, renderList(handles.value, (handle) => {
|
|
90
|
+
return openBlock(), createElementBlock("div", {
|
|
91
|
+
key: handle.pos,
|
|
92
|
+
draggable: "true",
|
|
93
|
+
"aria-hidden": "true",
|
|
94
|
+
class: normalizeClass(["absolute flex cursor-grab items-center justify-center rounded text-[var(--sk-muted)] hover:bg-[var(--sk-bg-elevated)] hover:text-[var(--sk-fg-highlighted)]", dragging.value ? "pointer-events-none" : "pointer-events-auto"]),
|
|
95
|
+
style: normalizeStyle({
|
|
96
|
+
left: `${handle.left}px`,
|
|
97
|
+
top: `${handle.top}px`,
|
|
98
|
+
width: `${unref(24)}px`,
|
|
99
|
+
height: `${unref(24)}px`
|
|
100
|
+
}),
|
|
101
|
+
onDragstart: ($event) => onDragStart($event, handle.pos)
|
|
102
|
+
}, [createVNode(unref(UIcon), {
|
|
103
|
+
name: "i-lucide-grip-vertical",
|
|
104
|
+
class: "size-4"
|
|
105
|
+
})], 46, _hoisted_2);
|
|
106
|
+
}), 128))]);
|
|
107
|
+
};
|
|
108
|
+
}
|
|
109
|
+
});
|
|
110
|
+
//#endregion
|
|
111
|
+
export { _sfc_main as default };
|
|
112
|
+
|
|
113
|
+
//# sourceMappingURL=BlockHandles.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"BlockHandles.js","names":["_openBlock","_createElementBlock","_Fragment","_renderList","_normalizeClass","_normalizeStyle","_unref","_createVNode"],"sources":["../../../../src/features/block-ui/components/BlockHandles.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport { useUiKit } from '../../../vue/kit/use-ui-kit'\nimport type { Editor } from '@tiptap/vue-3'\nimport { onBeforeUnmount, onMounted, shallowRef } from 'vue'\nimport { startBlockDrag } from '../../../core'\nimport { firstLineCenterShift, gutterShiftOf, HANDLE_SIZE, handleBlocksOf } from '../handle-geometry'\n\n/**\n * The permanent drag handles (`blocks.dragHandle: 'always'`): one handle per block that the hover handle can target\n * (`handleBlocksOf`), each where the hover handle would sit for that block, dragging the block like the hover handle\n * does (`startBlockDrag`). Only blocks within a screen of the viewport get one. A nested block whose handle would cover\n * another handle on the same line (the first block of a quote, say) has none: its container's handle moves it. Hidden\n * while the editor is read-only. Positioned absolutely inside `host`, the `relative` element around the editor.\n */\nconst props = defineProps<{ editor: Editor, host: HTMLElement }>()\n\nconst { Icon: UIcon } = useUiKit()\n\ninterface Handle { pos: number, left: number, top: number }\n\nconst handles = shallowRef<readonly Handle[]>([])\n// While a drag runs the handles let events through, so a drop over a handle's gutter still reaches the editor.\nconst dragging = shallowRef(false)\n\nlet raf = 0\nlet wasEditable = false\nfunction schedule() {\n if (!raf) raf = requestAnimationFrame(measure)\n}\n\nfunction measure() {\n raf = 0\n const { editor, host } = props\n wasEditable = !editor.isDestroyed && editor.isEditable\n if (!wasEditable || !editor.view.dom.getClientRects().length) {\n if (handles.value.length) handles.value = []\n return\n }\n const hostRect = host.getBoundingClientRect()\n const originX = hostRect.left + host.clientLeft\n const originY = hostRect.top + host.clientTop\n const next: Handle[] = []\n for (const { node, pos, dom } of handleBlocksOf(editor.view)) {\n const rect = dom.getBoundingClientRect()\n if (!rect.height || rect.bottom < -window.innerHeight || rect.top > 2 * window.innerHeight) continue\n const left = rect.left - HANDLE_SIZE - gutterShiftOf(node, dom) - originX\n const top = rect.top + firstLineCenterShift(dom, rect.top, HANDLE_SIZE) - originY\n const covered = next.some(other => Math.abs(top - other.top) < HANDLE_SIZE / 2 && left < other.left + HANDLE_SIZE && other.left < left + HANDLE_SIZE)\n if (!covered) next.push({ pos, left, top })\n }\n const prev = handles.value\n const changed = prev.length !== next.length || next.some((h, i) => {\n const before = prev[i]\n return !before || h.pos !== before.pos || h.left !== before.left || h.top !== before.top\n })\n if (changed) handles.value = next\n}\n\n// Documents change layout through edits, the column through resizes; `EditorSurface` dispatches a transaction after\n// `setEditable`.\nfunction onTransaction({ transaction }: { transaction: { docChanged: boolean } }) {\n if (transaction.docChanged || props.editor.isEditable !== wasEditable) schedule()\n}\n\nlet resizeObserver: ResizeObserver | undefined\nonMounted(() => {\n props.editor.on('transaction', onTransaction)\n window.addEventListener('resize', schedule)\n window.addEventListener('scroll', schedule, true)\n resizeObserver = new ResizeObserver(schedule)\n resizeObserver.observe(props.editor.view.dom)\n schedule()\n})\n\nonBeforeUnmount(() => {\n props.editor.off('transaction', onTransaction)\n window.removeEventListener('resize', schedule)\n window.removeEventListener('scroll', schedule, true)\n resizeObserver?.disconnect()\n if (raf) cancelAnimationFrame(raf)\n})\n\nfunction onDragStart(event: DragEvent, pos: number) {\n if (!startBlockDrag(props.editor, event, pos)) {\n event.preventDefault()\n return\n }\n // Not inside `dragstart`: changing the source's styles there cancels the drag. The dropped block's handle may be\n // gone afterwards and send no `dragend`, so the document ends the drag.\n setTimeout(() => { dragging.value = true })\n const abort = new AbortController()\n const end = () => {\n dragging.value = false\n abort.abort()\n }\n document.addEventListener('drop', end, { signal: abort.signal })\n document.addEventListener('dragend', end, { signal: abort.signal })\n}\n</script>\n\n<template>\n <div class=\"absolute left-0 top-0 z-10 h-0 w-0\">\n <div\n v-for=\"handle in handles\"\n :key=\"handle.pos\"\n draggable=\"true\"\n aria-hidden=\"true\"\n :class=\"['absolute flex cursor-grab items-center justify-center rounded text-[var(--sk-muted)] hover:bg-[var(--sk-bg-elevated)] hover:text-[var(--sk-fg-highlighted)]', dragging ? 'pointer-events-none' : 'pointer-events-auto']\"\n :style=\"{ left: `${handle.left}px`, top: `${handle.top}px`, width: `${HANDLE_SIZE}px`, height: `${HANDLE_SIZE}px` }\"\n @dragstart=\"onDragStart($event, handle.pos)\"\n >\n <UIcon name=\"i-lucide-grip-vertical\" class=\"size-4\" />\n </div>\n </div>\n</template>\n"],"mappings":"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"}
|
|
@@ -0,0 +1,181 @@
|
|
|
1
|
+
import { isChromeNode } from "../../../core/schema/node-flags.js";
|
|
2
|
+
import { editorEntryOf } from "../../../core/editor-ui.js";
|
|
3
|
+
import { useUiKit } from "../../../vue/kit/use-ui-kit.js";
|
|
4
|
+
import { useEditorSettings } from "../../../vue/settings.js";
|
|
5
|
+
import { firstLineCenterShift, gutterShiftOf, handleLeftOf, hasKindIcon } from "../handle-geometry.js";
|
|
6
|
+
import _sfc_main$1 from "./BlockActionsOverlay.js";
|
|
7
|
+
import _sfc_main$2 from "./BlockHandles.js";
|
|
8
|
+
import { Fragment, Teleport, computed, createBlock, createCommentVNode, createElementBlock, createVNode, defineComponent, nextTick, normalizeClass, onBeforeUnmount, onMounted, openBlock, shallowRef, toRaw, unref, useTemplateRef, withCtx } from "vue";
|
|
9
|
+
import { DragHandle } from "@tiptap/extension-drag-handle-vue-3";
|
|
10
|
+
//#region src/features/block-ui/components/BlockUi.vue
|
|
11
|
+
/**
|
|
12
|
+
* Block UI of an editor: the drag handle on the left of the hovered block (hidden while the editor is read-only) and the
|
|
13
|
+
* hover actions (`BlockActionsOverlay`) at the editor's right edge, both targeting the same block. The actions are those
|
|
14
|
+
* the surface registered for `editor` (features' block actions, then the host's). A block with a kind icon (a composite)
|
|
15
|
+
* gets no handle: its icon drags it. With `blocks.dragHandle: 'always'` the hover handle is replaced by permanent
|
|
16
|
+
* handles on every eligible block (`BlockHandles`). Mounted by the block-ui feature beside the editor.
|
|
17
|
+
*/
|
|
18
|
+
const _sfc_main = /*@__PURE__*/ defineComponent({
|
|
19
|
+
__name: "BlockUi",
|
|
20
|
+
props: { editor: {} },
|
|
21
|
+
setup(__props) {
|
|
22
|
+
const props = __props;
|
|
23
|
+
const { Icon: UIcon } = useUiKit();
|
|
24
|
+
const host = shallowRef(null);
|
|
25
|
+
const hoverTarget = shallowRef(null);
|
|
26
|
+
const actions = computed(() => editorEntryOf(toRaw(props.editor))?.blockActions ?? []);
|
|
27
|
+
let overlayHovered = false;
|
|
28
|
+
let hoverClearTimer;
|
|
29
|
+
onMounted(async () => {
|
|
30
|
+
await nextTick();
|
|
31
|
+
const dom = props.editor.isDestroyed ? null : props.editor.view.dom;
|
|
32
|
+
host.value = dom?.isConnected ? dom.parentElement : null;
|
|
33
|
+
dom?.addEventListener("keydown", onEditorKeydown);
|
|
34
|
+
dom?.addEventListener("mousemove", onEditorMousemove);
|
|
35
|
+
});
|
|
36
|
+
onBeforeUnmount(() => {
|
|
37
|
+
clearTimeout(hoverClearTimer);
|
|
38
|
+
if (props.editor.isDestroyed) return;
|
|
39
|
+
props.editor.view.dom.removeEventListener("keydown", onEditorKeydown);
|
|
40
|
+
props.editor.view.dom.removeEventListener("mousemove", onEditorMousemove);
|
|
41
|
+
});
|
|
42
|
+
let pointer = null;
|
|
43
|
+
function onEditorMousemove(e) {
|
|
44
|
+
pointer = {
|
|
45
|
+
x: e.clientX,
|
|
46
|
+
y: e.clientY
|
|
47
|
+
};
|
|
48
|
+
}
|
|
49
|
+
function onEditorKeydown() {
|
|
50
|
+
clearTimeout(hoverClearTimer);
|
|
51
|
+
hoverTarget.value = null;
|
|
52
|
+
}
|
|
53
|
+
function scheduleHoverClear() {
|
|
54
|
+
clearTimeout(hoverClearTimer);
|
|
55
|
+
hoverClearTimer = setTimeout(() => {
|
|
56
|
+
if (!overlayHovered) hoverTarget.value = null;
|
|
57
|
+
}, 200);
|
|
58
|
+
}
|
|
59
|
+
function onOverlayHover(hovered) {
|
|
60
|
+
overlayHovered = hovered;
|
|
61
|
+
if (!hovered) scheduleHoverClear();
|
|
62
|
+
}
|
|
63
|
+
function resetDragHandle() {
|
|
64
|
+
const { editor } = props;
|
|
65
|
+
if (editor.isDestroyed) return;
|
|
66
|
+
editor.view.dispatch(editor.state.tr.setMeta("hideDragHandle", true).setMeta("addToHistory", false));
|
|
67
|
+
}
|
|
68
|
+
const { settings } = useEditorSettings();
|
|
69
|
+
const alwaysHandles = computed(() => settings.value.blocks.dragHandle === "always");
|
|
70
|
+
const handle = useTemplateRef("handle");
|
|
71
|
+
const targetHasKindIcon = shallowRef(false);
|
|
72
|
+
const hoverHandleHidden = computed(() => alwaysHandles.value || targetHasKindIcon.value);
|
|
73
|
+
let handleGutterShift = 0;
|
|
74
|
+
let dragTargetDom = null;
|
|
75
|
+
let dragTargetNode = null;
|
|
76
|
+
function trackDragTarget({ node, pos }) {
|
|
77
|
+
if (node) {
|
|
78
|
+
clearTimeout(hoverClearTimer);
|
|
79
|
+
hoverTarget.value = {
|
|
80
|
+
node,
|
|
81
|
+
pos
|
|
82
|
+
};
|
|
83
|
+
} else scheduleHoverClear();
|
|
84
|
+
const dom = node ? props.editor.view.nodeDOM(pos) : null;
|
|
85
|
+
dragTargetDom = dom instanceof HTMLElement ? dom : null;
|
|
86
|
+
dragTargetNode = dragTargetDom ? node : null;
|
|
87
|
+
handleGutterShift = dragTargetDom && dragTargetNode ? gutterShiftOf(dragTargetNode, dragTargetDom) : 0;
|
|
88
|
+
targetHasKindIcon.value = dragTargetDom ? hasKindIcon(dragTargetDom) : false;
|
|
89
|
+
}
|
|
90
|
+
function pointerReachesTarget() {
|
|
91
|
+
if (!pointer || !dragTargetNode || !dragTargetDom?.isConnected) return false;
|
|
92
|
+
const rect = dragTargetDom.getBoundingClientRect();
|
|
93
|
+
const { x, y } = pointer;
|
|
94
|
+
if (x < handleLeftOf(dragTargetNode, dragTargetDom, handle.value?.$el.offsetWidth ?? 0) || x >= rect.right) return false;
|
|
95
|
+
if (y < (laidOutSibling(dragTargetDom, "previous")?.bottom ?? rect.top)) return false;
|
|
96
|
+
if (y >= (laidOutSibling(dragTargetDom, "next")?.top ?? rect.bottom)) return false;
|
|
97
|
+
return x < rect.left || y < rect.top || y >= rect.bottom;
|
|
98
|
+
}
|
|
99
|
+
function laidOutSibling(dom, side) {
|
|
100
|
+
for (let el = dom[`${side}ElementSibling`]; el; el = el[`${side}ElementSibling`]) {
|
|
101
|
+
const rect = el.getBoundingClientRect();
|
|
102
|
+
if (rect.height > 0) return rect;
|
|
103
|
+
}
|
|
104
|
+
return null;
|
|
105
|
+
}
|
|
106
|
+
const dragHandlePosition = { middleware: [{
|
|
107
|
+
name: "gutterShift",
|
|
108
|
+
fn: ({ x, y }) => ({
|
|
109
|
+
x: x - handleGutterShift,
|
|
110
|
+
y
|
|
111
|
+
})
|
|
112
|
+
}, {
|
|
113
|
+
name: "firstLineCenter",
|
|
114
|
+
fn: ({ x, y, elements, rects }) => ({
|
|
115
|
+
x,
|
|
116
|
+
y: dragTargetDom ? y + firstLineCenterShift(dragTargetDom, elements.reference.getBoundingClientRect().top, rects.floating.height) : y
|
|
117
|
+
})
|
|
118
|
+
}] };
|
|
119
|
+
const dragHandleNested = {
|
|
120
|
+
edgeDetection: "none",
|
|
121
|
+
rules: [
|
|
122
|
+
{
|
|
123
|
+
id: "compositeChrome",
|
|
124
|
+
evaluate: ({ node }) => isChromeNode(node) ? 1e3 : 0
|
|
125
|
+
},
|
|
126
|
+
{
|
|
127
|
+
id: "reachTarget",
|
|
128
|
+
evaluate: () => pointerReachesTarget() ? 1e3 : 0
|
|
129
|
+
},
|
|
130
|
+
{
|
|
131
|
+
id: "ownGutter",
|
|
132
|
+
evaluate: ({ node, pos, depth, view }) => {
|
|
133
|
+
if (depth < 2 || !pointer) return 0;
|
|
134
|
+
const dom = view.nodeDOM(pos);
|
|
135
|
+
return dom instanceof HTMLElement && pointer.x < handleLeftOf(node, dom, handle.value?.$el.offsetWidth ?? 0) ? 1e3 : 0;
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
]
|
|
139
|
+
};
|
|
140
|
+
return (_ctx, _cache) => {
|
|
141
|
+
return openBlock(), createElementBlock(Fragment, null, [host.value ? (openBlock(), createBlock(Teleport, {
|
|
142
|
+
key: 0,
|
|
143
|
+
to: host.value
|
|
144
|
+
}, [createVNode(_sfc_main$1, {
|
|
145
|
+
editor: __props.editor,
|
|
146
|
+
target: hoverTarget.value,
|
|
147
|
+
host: host.value,
|
|
148
|
+
actions: actions.value,
|
|
149
|
+
onHover: onOverlayHover
|
|
150
|
+
}, null, 8, [
|
|
151
|
+
"editor",
|
|
152
|
+
"target",
|
|
153
|
+
"host",
|
|
154
|
+
"actions"
|
|
155
|
+
]), alwaysHandles.value ? (openBlock(), createBlock(_sfc_main$2, {
|
|
156
|
+
key: 0,
|
|
157
|
+
editor: __props.editor,
|
|
158
|
+
host: host.value
|
|
159
|
+
}, null, 8, ["editor", "host"])) : createCommentVNode("v-if", true)], 8, ["to"])) : createCommentVNode("v-if", true), createVNode(unref(DragHandle), {
|
|
160
|
+
ref_key: "handle",
|
|
161
|
+
ref: handle,
|
|
162
|
+
editor: __props.editor,
|
|
163
|
+
"on-element-drag-end": resetDragHandle,
|
|
164
|
+
"on-node-change": trackDragTarget,
|
|
165
|
+
"compute-position-config": dragHandlePosition,
|
|
166
|
+
nested: dragHandleNested,
|
|
167
|
+
class: normalizeClass([{ "invisible! pointer-events-none!": hoverHandleHidden.value }, "flex size-6 cursor-grab items-center justify-center rounded text-[var(--sk-muted)] hover:bg-[var(--sk-bg-elevated)] hover:text-[var(--sk-fg-highlighted)] data-[dragging=true]:cursor-grabbing"])
|
|
168
|
+
}, {
|
|
169
|
+
default: withCtx(() => [createVNode(unref(UIcon), {
|
|
170
|
+
name: "i-lucide-grip-vertical",
|
|
171
|
+
class: "size-4"
|
|
172
|
+
})]),
|
|
173
|
+
_: 1
|
|
174
|
+
}, 8, ["editor", "class"])], 64);
|
|
175
|
+
};
|
|
176
|
+
}
|
|
177
|
+
});
|
|
178
|
+
//#endregion
|
|
179
|
+
export { _sfc_main as default };
|
|
180
|
+
|
|
181
|
+
//# sourceMappingURL=BlockUi.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"BlockUi.js","names":["_openBlock","_createElementBlock","_Fragment","_createBlock","_Teleport","_createVNode","BlockActionsOverlay","BlockHandles","_createCommentVNode","_unref","_normalizeClass","_withCtx"],"sources":["../../../../src/features/block-ui/components/BlockUi.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport { useUiKit } from '../../../vue/kit/use-ui-kit'\nimport { DragHandle, type DragHandleProps } from '@tiptap/extension-drag-handle-vue-3'\nimport type { Node } from '@tiptap/pm/model'\nimport type { Editor } from '@tiptap/vue-3'\nimport { type ComponentPublicInstance, computed, nextTick, onBeforeUnmount, onMounted, shallowRef, toRaw, useTemplateRef } from 'vue'\nimport { type BlockTarget, editorEntryOf } from '../../../core'\nimport { useEditorSettings } from '../../../vue/settings'\nimport { isChromeNode } from '../../../core/schema'\nimport { firstLineCenterShift, gutterShiftOf, handleLeftOf, hasKindIcon } from '../handle-geometry'\nimport BlockActionsOverlay from './BlockActionsOverlay.vue'\nimport BlockHandles from './BlockHandles.vue'\n\n/**\n * Block UI of an editor: the drag handle on the left of the hovered block (hidden while the editor is read-only) and the\n * hover actions (`BlockActionsOverlay`) at the editor's right edge, both targeting the same block. The actions are those\n * the surface registered for `editor` (features' block actions, then the host's). A block with a kind icon (a composite)\n * gets no handle: its icon drags it. With `blocks.dragHandle: 'always'` the hover handle is replaced by permanent\n * handles on every eligible block (`BlockHandles`). Mounted by the block-ui feature beside the editor.\n */\nconst props = defineProps<{ editor: Editor }>()\n\nconst { Icon: UIcon } = useUiKit()\n\n// Hover actions target the drag handle's block. The plugin drops its target when the pointer leaves the editor (also\n// onto the overlay, which sits outside it) and on keydown; a short grace keeps the overlay while the pointer moves\n// onto it, and typing hides it at once.\nconst host = shallowRef<HTMLElement | null>(null)\nconst hoverTarget = shallowRef<BlockTarget | null>(null)\nconst actions = computed(() => editorEntryOf(toRaw(props.editor))?.blockActions ?? [])\nlet overlayHovered = false\nlet hoverClearTimer: ReturnType<typeof setTimeout> | undefined\n\n// The overlay is positioned inside the element that holds the editor content (`relative`). Tiptap's content component\n// moves the editor DOM into it on the tick after it mounted, so look it up after that one.\nonMounted(async () => {\n await nextTick()\n const dom = props.editor.isDestroyed ? null : props.editor.view.dom\n host.value = dom?.isConnected ? dom.parentElement : null\n dom?.addEventListener('keydown', onEditorKeydown)\n dom?.addEventListener('mousemove', onEditorMousemove)\n})\n\nonBeforeUnmount(() => {\n clearTimeout(hoverClearTimer)\n if (props.editor.isDestroyed) return\n props.editor.view.dom.removeEventListener('keydown', onEditorKeydown)\n props.editor.view.dom.removeEventListener('mousemove', onEditorMousemove)\n})\n\n// Pointer position for the targeting rules below. The plugin evaluates them in a frame callback after the mousemove,\n// so this is the position they see.\nlet pointer: { x: number, y: number } | null = null\nfunction onEditorMousemove(e: MouseEvent) {\n pointer = { x: e.clientX, y: e.clientY }\n}\n\n// Like the drag-handle plugin: a key pressed in the focused editor hides the actions.\nfunction onEditorKeydown() {\n clearTimeout(hoverClearTimer)\n hoverTarget.value = null\n}\n\nfunction scheduleHoverClear() {\n clearTimeout(hoverClearTimer)\n hoverClearTimer = setTimeout(() => {\n if (!overlayHovered) hoverTarget.value = null\n }, 200)\n}\n\nfunction onOverlayHover(hovered: boolean) {\n overlayHovered = hovered\n if (!hovered) scheduleHoverClear()\n}\n\n// The drag-handle plugin hides the handle on dragend but keeps its current target. A dropped\n// nested node is the same node object, so hovering it again would not re-show the handle.\n// The plugin's `hideDragHandle` meta clears the target.\nfunction resetDragHandle() {\n const { editor } = props\n if (editor.isDestroyed) return\n editor.view.dispatch(editor.state.tr.setMeta('hideDragHandle', true).setMeta('addToHistory', false))\n}\n\n// The plugin puts the handle's right edge on the target block's left edge (`gutterShiftOf`: list items move further\n// left). The hover handle is hidden where the block has a handle of its own: the kind icon of a composite, or, with\n// `blocks.dragHandle: 'always'`, the permanent handles. Hiding keeps its layout, which the targeting rules below measure.\nconst { settings } = useEditorSettings()\nconst alwaysHandles = computed(() => settings.value.blocks.dragHandle === 'always')\nconst handle = useTemplateRef<ComponentPublicInstance>('handle')\nconst targetHasKindIcon = shallowRef(false)\nconst hoverHandleHidden = computed(() => alwaysHandles.value || targetHasKindIcon.value)\nlet handleGutterShift = 0\nlet dragTargetDom: HTMLElement | null = null\nlet dragTargetNode: Node | null = null\nfunction trackDragTarget({ node, pos }: { node: Node | null, pos: number }) {\n if (node) {\n clearTimeout(hoverClearTimer)\n hoverTarget.value = { node, pos }\n }\n else {\n scheduleHoverClear()\n }\n const dom = node ? props.editor.view.nodeDOM(pos) : null\n dragTargetDom = dom instanceof HTMLElement ? dom : null\n dragTargetNode = dragTargetDom ? node : null\n handleGutterShift = dragTargetDom && dragTargetNode ? gutterShiftOf(dragTargetNode, dragTargetDom) : 0\n targetHasKindIcon.value = dragTargetDom ? hasKindIcon(dragTargetDom) : false\n}\n\n// Left of a block, ProseMirror resolves the pointer to the position before the block, so the plugin only considers\n// the block's ancestors there: the target's own handle column would hand the handle to its parent before the pointer\n// reaches it. This keeps the target while the pointer is between its handle and its box, over its whole height\n// including the gaps to its neighbours, and in those gaps themselves (which resolve to the parent as well). The rule\n// then excludes every candidate, and the plugin keeps its target when the detection yields none. Inside the target's\n// own box the rule is off, so its descendants are still targeted.\nfunction pointerReachesTarget(): boolean {\n if (!pointer || !dragTargetNode || !dragTargetDom?.isConnected) return false\n const rect = dragTargetDom.getBoundingClientRect()\n const { x, y } = pointer\n if (x < handleLeftOf(dragTargetNode, dragTargetDom, handle.value?.$el.offsetWidth ?? 0) || x >= rect.right) return false\n if (y < (laidOutSibling(dragTargetDom, 'previous')?.bottom ?? rect.top)) return false\n if (y >= (laidOutSibling(dragTargetDom, 'next')?.top ?? rect.bottom)) return false\n return x < rect.left || y < rect.top || y >= rect.bottom\n}\n\n// Nearest sibling with a layout box (a composite's hidden description/tags rows have none).\nfunction laidOutSibling(dom: Element, side: 'previous' | 'next'): DOMRect | null {\n for (let el = dom[`${side}ElementSibling`]; el; el = el[`${side}ElementSibling`]) {\n const rect = el.getBoundingClientRect()\n if (rect.height > 0) return rect\n }\n return null\n}\n\n// The plugin aligns the handle's top with the block's top, which sits above the middle of the\n// block's first text line: `firstLineCenterShift` moves the handle's centre to that line's centre.\nconst dragHandlePosition: DragHandleProps['computePositionConfig'] = {\n middleware: [\n { name: 'gutterShift', fn: ({ x, y }) => ({ x: x - handleGutterShift, y }) },\n {\n name: 'firstLineCenter',\n fn: ({ x, y, elements, rects }) => ({\n x,\n y: dragTargetDom ? y + firstLineCenterShift(dragTargetDom, elements.reference.getBoundingClientRect().top, rects.floating.height) : y,\n }),\n },\n ],\n}\n\n// Targeting among nested blocks. `compositeChrome`: hovering a composite's title, description or tags row targets the\n// composite itself (a deduction of 1000, the base score, excludes a node). `reachTarget`: see `pointerReachesTarget`.\n// `ownGutter`: a nested block is targeted only from its handle column rightwards; further left its ancestors are, so\n// on any row the gutter is partitioned by the handle columns of the blocks nested there. The plugin's edge detection\n// is off: its left strip is this partition, its top strip would hand the handle to the parent on the block's first\n// line, where the handle sits.\nconst dragHandleNested: DragHandleProps['nested'] = {\n edgeDetection: 'none',\n rules: [\n { id: 'compositeChrome', evaluate: ({ node }) => isChromeNode(node) ? 1000 : 0 },\n { id: 'reachTarget', evaluate: () => pointerReachesTarget() ? 1000 : 0 },\n {\n id: 'ownGutter',\n evaluate: ({ node, pos, depth, view }) => {\n if (depth < 2 || !pointer) return 0\n const dom = view.nodeDOM(pos)\n return dom instanceof HTMLElement && pointer.x < handleLeftOf(node, dom, handle.value?.$el.offsetWidth ?? 0) ? 1000 : 0\n },\n },\n ],\n}\n</script>\n\n<template>\n <Teleport v-if=\"host\" :to=\"host\">\n <BlockActionsOverlay\n :editor=\"editor\"\n :target=\"hoverTarget\"\n :host=\"host\"\n :actions=\"actions\"\n @hover=\"onOverlayHover\"\n />\n <BlockHandles v-if=\"alwaysHandles\" :editor=\"editor\" :host=\"host\" />\n </Teleport>\n <DragHandle\n ref=\"handle\"\n :editor=\"editor\"\n :on-element-drag-end=\"resetDragHandle\"\n :on-node-change=\"trackDragTarget\"\n :compute-position-config=\"dragHandlePosition\"\n :nested=\"dragHandleNested\"\n :class=\"{ 'invisible! pointer-events-none!': hoverHandleHidden }\"\n class=\"flex size-6 cursor-grab items-center justify-center rounded text-[var(--sk-muted)] hover:bg-[var(--sk-bg-elevated)] hover:text-[var(--sk-fg-highlighted)] data-[dragging=true]:cursor-grabbing\"\n >\n <UIcon name=\"i-lucide-grip-vertical\" class=\"size-4\" />\n </DragHandle>\n</template>\n"],"mappings":"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"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { Editor } from "@tiptap/vue-3";
|
|
2
|
+
//#region src/features/block-ui/components/BlockUi.vue.d.ts
|
|
3
|
+
/**
|
|
4
|
+
* Block UI of an editor: the drag handle on the left of the hovered block (hidden while the editor is read-only) and the
|
|
5
|
+
* hover actions (`BlockActionsOverlay`) at the editor's right edge, both targeting the same block. The actions are those
|
|
6
|
+
* the surface registered for `editor` (features' block actions, then the host's). A block with a kind icon (a composite)
|
|
7
|
+
* gets no handle: its icon drags it. With `blocks.dragHandle: 'always'` the hover handle is replaced by permanent
|
|
8
|
+
* handles on every eligible block (`BlockHandles`). Mounted by the block-ui feature beside the editor.
|
|
9
|
+
*/
|
|
10
|
+
type __VLS_Props = {
|
|
11
|
+
editor: Editor;
|
|
12
|
+
};
|
|
13
|
+
declare const __VLS_export: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
14
|
+
declare const _default: typeof __VLS_export;
|
|
15
|
+
//#endregion
|
|
16
|
+
export { _default as default };
|
|
17
|
+
//# sourceMappingURL=BlockUi.vue.d.ts.map
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { EditorFeature } from "../../core/feature.js";
|
|
2
|
+
import "../../core/index.js";
|
|
3
|
+
//#region src/features/block-ui/feature.d.ts
|
|
4
|
+
/** What a framework binding supplies to the block-ui feature. */
|
|
5
|
+
export interface BlockUiUi<C> {
|
|
6
|
+
/** The block UI of an editor (drag handle, permanent handles, hover actions); mounted beside the editor content. */
|
|
7
|
+
overlay: C;
|
|
8
|
+
}
|
|
9
|
+
/**
|
|
10
|
+
* Block-level UI beside the editor content: the drag handle (upstream `@tiptap/extension-drag-handle`) with hover
|
|
11
|
+
* targeting, and the hover actions of the targeted block (features' and host block actions, `BlockActionsOverlay`).
|
|
12
|
+
* Also adds block-range selection (`NodeRange`: Mod+drag, Shift+↑/↓). Composite chrome (`editorChrome` nodes) targets its
|
|
13
|
+
* parent block.
|
|
14
|
+
*
|
|
15
|
+
* Opt-in: the simple editor has none of it. Installing a binding also bundles the drag handle's transitive collaboration
|
|
16
|
+
* support code (its upstream package imports `@tiptap/extension-collaboration` and `y-tiptap`), even without a live
|
|
17
|
+
* collaboration session.
|
|
18
|
+
*/
|
|
19
|
+
export declare function blockUiFeatureCore<C>(ui: BlockUiUi<C>): EditorFeature<C>;
|
|
20
|
+
//#endregion
|
|
21
|
+
//# sourceMappingURL=feature.d.ts.map
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { NodeRange } from "@tiptap/extension-node-range";
|
|
2
|
+
//#region src/features/block-ui/feature.ts
|
|
3
|
+
/**
|
|
4
|
+
* Block-level UI beside the editor content: the drag handle (upstream `@tiptap/extension-drag-handle`) with hover
|
|
5
|
+
* targeting, and the hover actions of the targeted block (features' and host block actions, `BlockActionsOverlay`).
|
|
6
|
+
* Also adds block-range selection (`NodeRange`: Mod+drag, Shift+↑/↓). Composite chrome (`editorChrome` nodes) targets its
|
|
7
|
+
* parent block.
|
|
8
|
+
*
|
|
9
|
+
* Opt-in: the simple editor has none of it. Installing a binding also bundles the drag handle's transitive collaboration
|
|
10
|
+
* support code (its upstream package imports `@tiptap/extension-collaboration` and `y-tiptap`), even without a live
|
|
11
|
+
* collaboration session.
|
|
12
|
+
*/
|
|
13
|
+
function blockUiFeatureCore(ui) {
|
|
14
|
+
return {
|
|
15
|
+
id: "block-ui",
|
|
16
|
+
extensions: () => [NodeRange],
|
|
17
|
+
overlays: [ui.overlay]
|
|
18
|
+
};
|
|
19
|
+
}
|
|
20
|
+
//#endregion
|
|
21
|
+
export { blockUiFeatureCore };
|
|
22
|
+
|
|
23
|
+
//# sourceMappingURL=feature.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"feature.js","names":[],"sources":["../../../src/features/block-ui/feature.ts"],"sourcesContent":["import { NodeRange } from '@tiptap/extension-node-range'\nimport type { EditorFeature } from '../../core'\n\n/** What a framework binding supplies to the block-ui feature. */\nexport interface BlockUiUi<C> {\n /** The block UI of an editor (drag handle, permanent handles, hover actions); mounted beside the editor content. */\n overlay: C\n}\n\n/**\n * Block-level UI beside the editor content: the drag handle (upstream `@tiptap/extension-drag-handle`) with hover\n * targeting, and the hover actions of the targeted block (features' and host block actions, `BlockActionsOverlay`).\n * Also adds block-range selection (`NodeRange`: Mod+drag, Shift+↑/↓). Composite chrome (`editorChrome` nodes) targets its\n * parent block.\n *\n * Opt-in: the simple editor has none of it. Installing a binding also bundles the drag handle's transitive collaboration\n * support code (its upstream package imports `@tiptap/extension-collaboration` and `y-tiptap`), even without a live\n * collaboration session.\n */\nexport function blockUiFeatureCore<C>(ui: BlockUiUi<C>): EditorFeature<C> {\n return {\n id: 'block-ui',\n extensions: () => [NodeRange],\n overlays: [ui.overlay],\n }\n}\n"],"mappings":";;;;;;;;;;;;AAmBA,SAAgB,mBAAsB,IAAoC;CACxE,OAAO;EACL,IAAI;EACJ,kBAAkB,CAAC,SAAS;EAC5B,UAAU,CAAC,GAAG,OAAO;CACvB;AACF"}
|