@haklex/rich-editor 0.68.0 → 0.69.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{theme-DH4xzxU-.js → ColorSchemeContext-DLWz8vFw.js} +1349 -92
- package/dist/{thumbhash-GjK8OYAb.js → LinkCardRenderer-D4mQbUQo.js} +109 -31
- package/dist/NestedEditorPluginsContext-DKFdozOE.js +8 -0
- package/dist/{ExtraNodesContext-xQ2RNsqH.js → RendererConfigProvider-BPYO0Ip0.js} +37 -7
- package/dist/{RubyRenderer-8HMSMaZz.js → RubyRenderer-BuFWY87e.js} +2 -1
- package/dist/SpoilerNode-D7Tgdo2K.js +82 -0
- package/dist/{VirtualizationPlugin-nD_x-4yR.js → VirtualizationPlugin-CkNi6FW2.js} +85 -53
- package/dist/{VirtualizationPlugin-Bqv4MkJH.js → VirtualizationPlugin-DbAHlGBL.js} +358 -172
- package/dist/{VirtualizedEditor-uWe43zaI.js → VirtualizedEditor-D099IYqN.js} +54 -41
- package/dist/block-id-state-DfN32rR_.js +5 -0
- package/dist/command-registry-entry.d.ts.map +1 -1
- package/dist/commands/registry.d.ts +2 -2
- package/dist/commands/registry.d.ts.map +1 -1
- package/dist/commands-entry.d.ts +1 -4
- package/dist/commands-entry.d.ts.map +1 -1
- package/dist/commands-entry.mjs +2 -2
- package/dist/components/ContentEditable.css.d.ts.map +1 -1
- package/dist/components/ContentEditable.d.ts +1 -1
- package/dist/components/ContentEditable.d.ts.map +1 -1
- package/dist/components/CorePlugins.d.ts +1 -1
- package/dist/components/CorePlugins.d.ts.map +1 -1
- package/dist/components/EditorSurfaceHost.d.ts +2 -2
- package/dist/components/EditorSurfaceHost.d.ts.map +1 -1
- package/dist/components/LinkFavicon.d.ts +1 -1
- package/dist/components/LinkFavicon.d.ts.map +1 -1
- package/dist/components/RendererWrapper.d.ts +5 -16
- package/dist/components/RendererWrapper.d.ts.map +1 -1
- package/dist/components/RichEditor.d.ts +2 -2
- package/dist/components/RichEditor.d.ts.map +1 -1
- package/dist/components/RichEditorShell.d.ts +7 -7
- package/dist/components/RichEditorShell.d.ts.map +1 -1
- package/dist/components/VirtualizationFromProps.d.ts +2 -2
- package/dist/components/VirtualizationFromProps.d.ts.map +1 -1
- package/dist/components/decorators/AlertEditDecorator.d.ts +3 -3
- package/dist/components/decorators/AlertEditDecorator.d.ts.map +1 -1
- package/dist/components/decorators/BannerEditDecorator.d.ts +3 -3
- package/dist/components/decorators/BannerEditDecorator.d.ts.map +1 -1
- package/dist/components/decorators/CodeBlockEditDecorator.d.ts +1 -1
- package/dist/components/decorators/CodeBlockEditDecorator.d.ts.map +1 -1
- package/dist/components/decorators/GridEditDecorator.d.ts +2 -2
- package/dist/components/decorators/GridEditDecorator.d.ts.map +1 -1
- package/dist/components/decorators/NestedEditorCorePlugins.d.ts +1 -1
- package/dist/components/decorators/NestedEditorCorePlugins.d.ts.map +1 -1
- package/dist/components/decorators/gridAutoFocus.d.ts +1 -1
- package/dist/components/decorators/gridAutoFocus.d.ts.map +1 -1
- package/dist/components/decorators/useNestedEditorSync.d.ts +1 -1
- package/dist/components/decorators/useNestedEditorSync.d.ts.map +1 -1
- package/dist/components/renderer-decoration.d.ts +13 -0
- package/dist/components/renderer-decoration.d.ts.map +1 -0
- package/dist/components/renderers/AlertRenderer.d.ts +2 -2
- package/dist/components/renderers/AlertRenderer.d.ts.map +1 -1
- package/dist/components/renderers/AlertStaticDecorator.d.ts +3 -3
- package/dist/components/renderers/AlertStaticDecorator.d.ts.map +1 -1
- package/dist/components/renderers/BannerRenderer.d.ts +2 -2
- package/dist/components/renderers/BannerRenderer.d.ts.map +1 -1
- package/dist/components/renderers/BannerStaticDecorator.d.ts +3 -3
- package/dist/components/renderers/BannerStaticDecorator.d.ts.map +1 -1
- package/dist/components/renderers/CodeBlockRenderer.d.ts +1 -1
- package/dist/components/renderers/CodeBlockRenderer.d.ts.map +1 -1
- package/dist/components/renderers/FileRenderer.d.ts +1 -4
- package/dist/components/renderers/FileRenderer.d.ts.map +1 -1
- package/dist/components/renderers/FootnoteRenderer.d.ts +1 -1
- package/dist/components/renderers/FootnoteRenderer.d.ts.map +1 -1
- package/dist/components/renderers/FootnoteSectionEditRenderer.d.ts +1 -1
- package/dist/components/renderers/FootnoteSectionEditRenderer.d.ts.map +1 -1
- package/dist/components/renderers/FootnoteSectionRenderer.d.ts +1 -1
- package/dist/components/renderers/FootnoteSectionRenderer.d.ts.map +1 -1
- package/dist/components/renderers/FootnoteStaticRenderer.d.ts +1 -1
- package/dist/components/renderers/FootnoteStaticRenderer.d.ts.map +1 -1
- package/dist/components/renderers/GridStaticDecorator.d.ts +2 -2
- package/dist/components/renderers/GridStaticDecorator.d.ts.map +1 -1
- package/dist/components/renderers/ImageRenderer.d.ts +2 -2
- package/dist/components/renderers/ImageRenderer.d.ts.map +1 -1
- package/dist/components/renderers/KaTeXRenderer.d.ts +1 -1
- package/dist/components/renderers/KaTeXRenderer.d.ts.map +1 -1
- package/dist/components/renderers/LinkCardRenderer.d.ts +1 -1
- package/dist/components/renderers/LinkCardRenderer.d.ts.map +1 -1
- package/dist/components/renderers/MentionRenderer.d.ts +1 -1
- package/dist/components/renderers/MentionRenderer.d.ts.map +1 -1
- package/dist/components/renderers/MermaidRenderer.d.ts +1 -1
- package/dist/components/renderers/MermaidRenderer.d.ts.map +1 -1
- package/dist/components/renderers/RubyRenderer.d.ts +2 -2
- package/dist/components/renderers/RubyRenderer.d.ts.map +1 -1
- package/dist/components/renderers/TagRenderer.d.ts +1 -2
- package/dist/components/renderers/TagRenderer.d.ts.map +1 -1
- package/dist/components/renderers/VideoRenderer.d.ts +1 -1
- package/dist/components/renderers/VideoRenderer.d.ts.map +1 -1
- package/dist/components/utils.d.ts +1 -1
- package/dist/components/utils.d.ts.map +1 -1
- package/dist/config-edit.d.ts +1 -1
- package/dist/config-edit.d.ts.map +1 -1
- package/dist/config.d.ts +1 -1
- package/dist/config.d.ts.map +1 -1
- package/dist/context/ColorSchemeContext.d.ts +1 -5
- package/dist/context/ColorSchemeContext.d.ts.map +1 -1
- package/dist/context/ColorSchemeProvider.d.ts +7 -0
- package/dist/context/ColorSchemeProvider.d.ts.map +1 -0
- package/dist/context/EditorBlockContext.d.ts +2 -2
- package/dist/context/EditorBlockContext.d.ts.map +1 -1
- package/dist/context/EditorSurface.d.ts +19 -0
- package/dist/context/EditorSurface.d.ts.map +1 -0
- package/dist/context/EditorSurfaceContext.d.ts +7 -22
- package/dist/context/EditorSurfaceContext.d.ts.map +1 -1
- package/dist/context/ExtraNodesContext.d.ts +2 -6
- package/dist/context/ExtraNodesContext.d.ts.map +1 -1
- package/dist/context/ExtraNodesProvider.d.ts +7 -0
- package/dist/context/ExtraNodesProvider.d.ts.map +1 -0
- package/dist/context/FileUploadContext.d.ts +2 -6
- package/dist/context/FileUploadContext.d.ts.map +1 -1
- package/dist/context/FileUploadProvider.d.ts +7 -0
- package/dist/context/FileUploadProvider.d.ts.map +1 -0
- package/dist/context/FootnoteDefinitionsContext.d.ts +1 -4
- package/dist/context/FootnoteDefinitionsContext.d.ts.map +1 -1
- package/dist/context/FootnoteDefinitionsProvider.d.ts +6 -0
- package/dist/context/FootnoteDefinitionsProvider.d.ts.map +1 -0
- package/dist/context/ImagePreprocessContext.d.ts +2 -4
- package/dist/context/ImagePreprocessContext.d.ts.map +1 -1
- package/dist/context/ImagePreprocessProvider.d.ts +5 -0
- package/dist/context/ImagePreprocessProvider.d.ts.map +1 -0
- package/dist/context/ImageUploadContext.d.ts +2 -6
- package/dist/context/ImageUploadContext.d.ts.map +1 -1
- package/dist/context/ImageUploadProvider.d.ts +7 -0
- package/dist/context/ImageUploadProvider.d.ts.map +1 -0
- package/dist/context/NestedContentRendererContext.d.ts +4 -4
- package/dist/context/NestedContentRendererContext.d.ts.map +1 -1
- package/dist/context/NestedEditorPluginsContext.d.ts +5 -2
- package/dist/context/NestedEditorPluginsContext.d.ts.map +1 -1
- package/dist/context/NestedEditorPluginsProvider.d.ts +3 -0
- package/dist/context/NestedEditorPluginsProvider.d.ts.map +1 -0
- package/dist/context/RendererConfigContext.d.ts +9 -4
- package/dist/context/RendererConfigContext.d.ts.map +1 -1
- package/dist/context/RendererConfigProvider.d.ts +3 -0
- package/dist/context/RendererConfigProvider.d.ts.map +1 -0
- package/dist/context/TextSelectionContext.d.ts +2 -5
- package/dist/context/TextSelectionContext.d.ts.map +1 -1
- package/dist/context/TextSelectionStoreProvider.d.ts +5 -0
- package/dist/context/TextSelectionStoreProvider.d.ts.map +1 -0
- package/dist/context/VideoUploadContext.d.ts +2 -6
- package/dist/context/VideoUploadContext.d.ts.map +1 -1
- package/dist/context/VideoUploadProvider.d.ts +7 -0
- package/dist/context/VideoUploadProvider.d.ts.map +1 -0
- package/dist/{grid.css-DJWKdYpz.js → grid.css-DAMDDTZh.js} +2 -1
- package/dist/index.d.ts +15 -8
- package/dist/index.d.ts.map +1 -1
- package/dist/index.mjs +34 -22
- package/dist/insert-commands-CtLGoIz0.js +9 -0
- package/dist/{katex.css-9crOcnIa.js → katex.css-DJbW49pH.js} +1 -1
- package/dist/{node-registry-DRd8ZbeC.js → node-registry-PtbiwsVu.js} +416 -42
- package/dist/node-registry.d.ts +1 -1
- package/dist/node-registry.d.ts.map +1 -1
- package/dist/nodes/AlertQuoteEditNode.d.ts +4 -4
- package/dist/nodes/AlertQuoteEditNode.d.ts.map +1 -1
- package/dist/nodes/AlertQuoteNode.d.ts +3 -2
- package/dist/nodes/AlertQuoteNode.d.ts.map +1 -1
- package/dist/nodes/BannerEditNode.d.ts +4 -4
- package/dist/nodes/BannerEditNode.d.ts.map +1 -1
- package/dist/nodes/BannerNode.d.ts +3 -2
- package/dist/nodes/BannerNode.d.ts.map +1 -1
- package/dist/nodes/CodeBlockEditNode.d.ts +6 -6
- package/dist/nodes/CodeBlockEditNode.d.ts.map +1 -1
- package/dist/nodes/CodeBlockNode.d.ts +4 -3
- package/dist/nodes/CodeBlockNode.d.ts.map +1 -1
- package/dist/nodes/CommentNode.d.ts +3 -2
- package/dist/nodes/CommentNode.d.ts.map +1 -1
- package/dist/nodes/DetailsNode.d.ts +4 -3
- package/dist/nodes/DetailsNode.d.ts.map +1 -1
- package/dist/nodes/FileNode.d.ts +4 -3
- package/dist/nodes/FileNode.d.ts.map +1 -1
- package/dist/nodes/FootnoteNode.d.ts +3 -2
- package/dist/nodes/FootnoteNode.d.ts.map +1 -1
- package/dist/nodes/FootnoteSectionEditNode.d.ts +2 -2
- package/dist/nodes/FootnoteSectionEditNode.d.ts.map +1 -1
- package/dist/nodes/FootnoteSectionNode.d.ts +3 -2
- package/dist/nodes/FootnoteSectionNode.d.ts.map +1 -1
- package/dist/nodes/GridContainerNode.d.ts +3 -2
- package/dist/nodes/GridContainerNode.d.ts.map +1 -1
- package/dist/nodes/GridEditNode.d.ts +4 -4
- package/dist/nodes/GridEditNode.d.ts.map +1 -1
- package/dist/nodes/ImageNode.d.ts +5 -4
- package/dist/nodes/ImageNode.d.ts.map +1 -1
- package/dist/nodes/KaTeXBlockNode.d.ts +4 -3
- package/dist/nodes/KaTeXBlockNode.d.ts.map +1 -1
- package/dist/nodes/KaTeXInlineNode.d.ts +3 -2
- package/dist/nodes/KaTeXInlineNode.d.ts.map +1 -1
- package/dist/nodes/LinkCardNode.d.ts +4 -3
- package/dist/nodes/LinkCardNode.d.ts.map +1 -1
- package/dist/nodes/MentionNode.d.ts +4 -3
- package/dist/nodes/MentionNode.d.ts.map +1 -1
- package/dist/nodes/MermaidNode.d.ts +4 -3
- package/dist/nodes/MermaidNode.d.ts.map +1 -1
- package/dist/nodes/RichQuoteNode.d.ts +2 -2
- package/dist/nodes/RichQuoteNode.d.ts.map +1 -1
- package/dist/nodes/RubyNode.d.ts +2 -1
- package/dist/nodes/RubyNode.d.ts.map +1 -1
- package/dist/nodes/SpoilerNode.d.ts +2 -1
- package/dist/nodes/SpoilerNode.d.ts.map +1 -1
- package/dist/nodes/TagNode.d.ts +3 -2
- package/dist/nodes/TagNode.d.ts.map +1 -1
- package/dist/nodes/VideoNode.d.ts +4 -3
- package/dist/nodes/VideoNode.d.ts.map +1 -1
- package/dist/nodes/shared.d.ts +1 -1
- package/dist/nodes/shared.d.ts.map +1 -1
- package/dist/nodes-entry.d.ts.map +1 -1
- package/dist/nodes-entry.mjs +2 -4
- package/dist/{normalizeSerializedEditorState-VaI73T09.js → normalizeSerializedEditorState-CNUAQd3l.js} +16 -1
- package/dist/plugins/AlertPlugin.d.ts +0 -2
- package/dist/plugins/AlertPlugin.d.ts.map +1 -1
- package/dist/plugins/AutoFocusPlugin.d.ts.map +1 -1
- package/dist/plugins/AutoLinkPlugin.d.ts +1 -1
- package/dist/plugins/AutoLinkPlugin.d.ts.map +1 -1
- package/dist/plugins/BlockExitPlugin.d.ts +0 -2
- package/dist/plugins/BlockExitPlugin.d.ts.map +1 -1
- package/dist/plugins/BlockIdPlugin.d.ts +0 -1
- package/dist/plugins/BlockIdPlugin.d.ts.map +1 -1
- package/dist/plugins/ClickBelowPlugin.d.ts +0 -2
- package/dist/plugins/ClickBelowPlugin.d.ts.map +1 -1
- package/dist/plugins/EditorRefPlugin.d.ts +1 -1
- package/dist/plugins/EditorRefPlugin.d.ts.map +1 -1
- package/dist/plugins/FileUploadPlugin.d.ts +1 -1
- package/dist/plugins/FileUploadPlugin.d.ts.map +1 -1
- package/dist/plugins/FootnotePlugin.d.ts +1 -1
- package/dist/plugins/FootnotePlugin.d.ts.map +1 -1
- package/dist/plugins/HorizontalRulePlugin.d.ts.map +1 -1
- package/dist/plugins/ImageDialog.d.ts +2 -2
- package/dist/plugins/ImageDialog.d.ts.map +1 -1
- package/dist/plugins/ImageDialogReview.d.ts +2 -2
- package/dist/plugins/ImageDialogReview.d.ts.map +1 -1
- package/dist/plugins/ImageDialogSource.d.ts +1 -1
- package/dist/plugins/ImageDialogSource.d.ts.map +1 -1
- package/dist/plugins/ImagePlugin.d.ts +0 -3
- package/dist/plugins/ImagePlugin.d.ts.map +1 -1
- package/dist/plugins/ImageUploadPlugin.d.ts +1 -13
- package/dist/plugins/ImageUploadPlugin.d.ts.map +1 -1
- package/dist/plugins/InlineDndPlugin.d.ts +1 -3
- package/dist/plugins/InlineDndPlugin.d.ts.map +1 -1
- package/dist/plugins/KaTeXPlugin.d.ts +0 -2
- package/dist/plugins/KaTeXPlugin.d.ts.map +1 -1
- package/dist/plugins/LinkFaviconPlugin.d.ts.map +1 -1
- package/dist/plugins/MarkdownPastePlugin.d.ts.map +1 -1
- package/dist/plugins/MarkdownShortcutsPlugin.d.ts +1 -1
- package/dist/plugins/MarkdownShortcutsPlugin.d.ts.map +1 -1
- package/dist/plugins/MermaidPlugin.d.ts +0 -1
- package/dist/plugins/MermaidPlugin.d.ts.map +1 -1
- package/dist/plugins/OnChangePlugin.d.ts +1 -1
- package/dist/plugins/OnChangePlugin.d.ts.map +1 -1
- package/dist/plugins/PasteLinkPlugin.d.ts.map +1 -1
- package/dist/plugins/SubmitShortcutPlugin.d.ts.map +1 -1
- package/dist/plugins/TextSelectionPlugin.d.ts.map +1 -1
- package/dist/plugins/VideoUploadPlugin.d.ts.map +1 -1
- package/dist/plugins/VirtualizationPlugin.d.ts.map +1 -1
- package/dist/plugins/block-exit-commands.d.ts +3 -0
- package/dist/plugins/block-exit-commands.d.ts.map +1 -0
- package/dist/plugins/block-id-state.d.ts +2 -0
- package/dist/plugins/block-id-state.d.ts.map +1 -0
- package/dist/plugins/click-below-command.d.ts +3 -0
- package/dist/plugins/click-below-command.d.ts.map +1 -0
- package/dist/plugins/file-upload-command.d.ts +1 -1
- package/dist/plugins/file-upload-command.d.ts.map +1 -1
- package/dist/plugins/file-upload-store.d.ts +1 -1
- package/dist/plugins/file-upload-store.d.ts.map +1 -1
- package/dist/plugins/image-dialog-model.d.ts +1 -1
- package/dist/plugins/image-dialog-model.d.ts.map +1 -1
- package/dist/plugins/image-dialog.css.d.ts.map +1 -1
- package/dist/plugins/image-upload-command.d.ts +1 -1
- package/dist/plugins/image-upload-command.d.ts.map +1 -1
- package/dist/plugins/image-upload-fn.d.ts +14 -0
- package/dist/plugins/image-upload-fn.d.ts.map +1 -0
- package/dist/plugins/image-upload-toast.d.ts.map +1 -1
- package/dist/plugins/image-upload.css.d.ts.map +1 -1
- package/dist/plugins/inline-dnd-move.d.ts +4 -0
- package/dist/plugins/inline-dnd-move.d.ts.map +1 -0
- package/dist/plugins/inline-dnd-shared.d.ts.map +1 -1
- package/dist/plugins/inline-dnd.css.d.ts.map +1 -1
- package/dist/plugins/insert-commands.d.ts +9 -0
- package/dist/plugins/insert-commands.d.ts.map +1 -0
- package/dist/plugins/insertion-cursor.d.ts +1 -1
- package/dist/plugins/insertion-cursor.d.ts.map +1 -1
- package/dist/plugins/present-image-dialog.d.ts +1 -1
- package/dist/plugins/present-image-dialog.d.ts.map +1 -1
- package/dist/plugins/text-selection.css.d.ts.map +1 -1
- package/dist/plugins-entry.d.ts +15 -8
- package/dist/plugins-entry.d.ts.map +1 -1
- package/dist/plugins-entry.mjs +5 -6
- package/dist/recycler-entry.d.ts.map +1 -1
- package/dist/renderers-entry.d.ts +4 -2
- package/dist/renderers-entry.d.ts.map +1 -1
- package/dist/renderers-entry.mjs +5 -5
- package/dist/{utils-E6qVk-NR.js → shared.css-DRoqE_U-.js} +1 -24
- package/dist/static-entry.d.ts +12 -6
- package/dist/static-entry.d.ts.map +1 -1
- package/dist/static-entry.mjs +10 -9
- package/dist/styles/article.css.d.ts.map +1 -1
- package/dist/styles/chat.css.d.ts.map +1 -1
- package/dist/styles/comment.css.d.ts.map +1 -1
- package/dist/styles/details.css.d.ts +5 -5
- package/dist/styles/details.css.d.ts.map +1 -1
- package/dist/styles/grid.css.d.ts +10 -10
- package/dist/styles/grid.css.d.ts.map +1 -1
- package/dist/styles/index.d.ts +3 -0
- package/dist/styles/index.d.ts.map +1 -1
- package/dist/styles/katex.css.d.ts +3 -3
- package/dist/styles/katex.css.d.ts.map +1 -1
- package/dist/styles/note.css.d.ts.map +1 -1
- package/dist/styles/shared.css.d.ts +54 -54
- package/dist/styles/shared.css.d.ts.map +1 -1
- package/dist/styles/theme.d.ts +1 -1
- package/dist/styles/theme.d.ts.map +1 -1
- package/dist/styles-entry.d.ts.map +1 -1
- package/dist/styles-entry.mjs +4 -3
- package/dist/transformers/alert.d.ts +1 -1
- package/dist/transformers/alert.d.ts.map +1 -1
- package/dist/transformers/code-block.d.ts +1 -1
- package/dist/transformers/code-block.d.ts.map +1 -1
- package/dist/transformers/comment.d.ts +1 -1
- package/dist/transformers/comment.d.ts.map +1 -1
- package/dist/transformers/container.d.ts +1 -1
- package/dist/transformers/container.d.ts.map +1 -1
- package/dist/transformers/footnote.d.ts +1 -1
- package/dist/transformers/footnote.d.ts.map +1 -1
- package/dist/transformers/grid-container.d.ts +1 -1
- package/dist/transformers/grid-container.d.ts.map +1 -1
- package/dist/transformers/horizontal-rule.d.ts +1 -1
- package/dist/transformers/horizontal-rule.d.ts.map +1 -1
- package/dist/transformers/index.d.ts +1 -1
- package/dist/transformers/index.d.ts.map +1 -1
- package/dist/transformers/insert.d.ts.map +1 -1
- package/dist/transformers/katex.d.ts +1 -1
- package/dist/transformers/katex.d.ts.map +1 -1
- package/dist/transformers/mention.d.ts +1 -1
- package/dist/transformers/mention.d.ts.map +1 -1
- package/dist/transformers/quote.d.ts +1 -1
- package/dist/transformers/quote.d.ts.map +1 -1
- package/dist/transformers/rich-blocks.d.ts.map +1 -1
- package/dist/transformers/ruby.d.ts +1 -1
- package/dist/transformers/ruby.d.ts.map +1 -1
- package/dist/transformers/spoiler.d.ts +1 -1
- package/dist/transformers/spoiler.d.ts.map +1 -1
- package/dist/transformers/superscript-subscript.d.ts.map +1 -1
- package/dist/transformers/table.d.ts +1 -1
- package/dist/transformers/table.d.ts.map +1 -1
- package/dist/types/renderer-config.d.ts +15 -15
- package/dist/types/renderer-config.d.ts.map +1 -1
- package/dist/types/renderer-keys.d.ts +14 -14
- package/dist/types/renderer-keys.d.ts.map +1 -1
- package/dist/types/slash-menu.d.ts +2 -2
- package/dist/types/slash-menu.d.ts.map +1 -1
- package/dist/types.d.ts +5 -5
- package/dist/types.d.ts.map +1 -1
- package/dist/utils/codeBlockSelectionIntent.d.ts +1 -0
- package/dist/utils/codeBlockSelectionIntent.d.ts.map +1 -1
- package/dist/utils/collect-command-items.d.ts +2 -2
- package/dist/utils/collect-command-items.d.ts.map +1 -1
- package/dist/utils/comment-anchor.d.ts +1 -1
- package/dist/utils/comment-anchor.d.ts.map +1 -1
- package/dist/utils/extractTextContent.d.ts +1 -1
- package/dist/utils/extractTextContent.d.ts.map +1 -1
- package/dist/utils/favicon.d.ts.map +1 -1
- package/dist/utils/file-meta.d.ts +4 -0
- package/dist/utils/file-meta.d.ts.map +1 -0
- package/dist/utils/getRegisteredNodeKlass.d.ts +1 -1
- package/dist/utils/getRegisteredNodeKlass.d.ts.map +1 -1
- package/dist/utils/image-display-size.d.ts.map +1 -1
- package/dist/utils/image-insertion.d.ts +1 -1
- package/dist/utils/image-insertion.d.ts.map +1 -1
- package/dist/utils/image-preprocess.d.ts +1 -1
- package/dist/utils/image-preprocess.d.ts.map +1 -1
- package/dist/utils/katex-defaults.d.ts.map +1 -1
- package/dist/utils/lucide-dom.d.ts.map +1 -1
- package/dist/utils/nested-editor-sync.d.ts +1 -1
- package/dist/utils/nested-editor-sync.d.ts.map +1 -1
- package/dist/utils/normalizeSerializedEditorState.d.ts +1 -1
- package/dist/utils/normalizeSerializedEditorState.d.ts.map +1 -1
- package/dist/utils/occurrence-keys.d.ts +7 -0
- package/dist/utils/occurrence-keys.d.ts.map +1 -0
- package/dist/utils/tag-color.d.ts.map +1 -1
- package/dist/utils/text-selection-constants.d.ts.map +1 -1
- package/dist/utils/text-selection.d.ts +1 -1
- package/dist/utils/text-selection.d.ts.map +1 -1
- package/dist/utils/thumbhash.d.ts.map +1 -1
- package/dist/utils/toggle-spoiler.d.ts +1 -1
- package/dist/utils/toggle-spoiler.d.ts.map +1 -1
- package/dist/utils-i78C9io3.js +26 -0
- package/dist/virtualization/VirtualizationPlugin.d.ts +2 -2
- package/dist/virtualization/VirtualizationPlugin.d.ts.map +1 -1
- package/dist/virtualization/VirtualizedEditor.d.ts +3 -3
- package/dist/virtualization/VirtualizedEditor.d.ts.map +1 -1
- package/dist/virtualization/blocks.d.ts +3 -3
- package/dist/virtualization/blocks.d.ts.map +1 -1
- package/dist/virtualization/controller.d.ts +8 -4
- package/dist/virtualization/controller.d.ts.map +1 -1
- package/dist/virtualization/document.d.ts +1 -1
- package/dist/virtualization/document.d.ts.map +1 -1
- package/dist/virtualization/layout.d.ts +1 -1
- package/dist/virtualization/layout.d.ts.map +1 -1
- package/dist/virtualization/preserve.d.ts.map +1 -1
- package/dist/virtualization/style.css.d.ts.map +1 -1
- package/dist/virtualization/sync.d.ts +2 -2
- package/dist/virtualization/sync.d.ts.map +1 -1
- package/dist/virtualization/types.d.ts +2 -2
- package/dist/virtualization/types.d.ts.map +1 -1
- package/dist/virtualization/viewport.d.ts +1 -1
- package/dist/virtualization/viewport.d.ts.map +1 -1
- package/dist/virtualization-entry.d.ts.map +1 -1
- package/dist/virtualization-entry.mjs +1 -1
- package/package.json +4 -6
- package/dist/AlertQuoteEditNode-DFg-xOND.js +0 -372
- package/dist/BlockIdPlugin-Cwv8aV9g.js +0 -106
- package/dist/ColorSchemeContext-Dc_HebHd.js +0 -1336
- package/dist/LinkCardRenderer-BT8P5aJC.js +0 -100
- package/dist/MermaidPlugin-D0Z2_YAe.js +0 -71
- package/dist/NestedEditorPluginsContext-D78UZkmx.js +0 -16
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NestedContentRendererContext.d.ts","
|
|
1
|
+
{"version":3,"file":"NestedContentRendererContext.d.ts","sources":["../../src/context/NestedContentRendererContext.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,SAAS,CAAC;AACrD,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAGvC,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,UAAU,CAAC;AAElD,MAAM,MAAM,mBAAmB,GAAG,CAChC,KAAK,EAAE,qBAAqB,EAC5B,OAAO,CAAC,EAAE,iBAAiB,KACxB,SAAS,CAAC;AAIf,eAAO,MAAM,6BAA6B,qDAA+B,CAAC;AAE1E,wBAAgB,gCAAgC,IAAI,mBAAmB,GAAG,IAAI,CAE7E;AAED,wBAAgB,wBAAwB,IAAI,mBAAmB,CAM9D"}
|
|
@@ -1,8 +1,11 @@
|
|
|
1
|
-
import { ReactNode } from 'react';
|
|
1
|
+
import type { ReactNode } from 'react';
|
|
2
|
+
export interface NestedEditorPluginsContextValue {
|
|
3
|
+
plugins?: ReactNode;
|
|
4
|
+
}
|
|
2
5
|
export interface NestedEditorPluginsProviderProps {
|
|
3
6
|
children: ReactNode;
|
|
4
7
|
plugins?: ReactNode;
|
|
5
8
|
}
|
|
6
|
-
export declare
|
|
9
|
+
export declare const NestedEditorPluginsContext: import("react").Context<NestedEditorPluginsContextValue | null>;
|
|
7
10
|
export declare function useNestedEditorPlugins(): ReactNode;
|
|
8
11
|
//# sourceMappingURL=NestedEditorPluginsContext.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NestedEditorPluginsContext.d.ts","
|
|
1
|
+
{"version":3,"file":"NestedEditorPluginsContext.d.ts","sources":["../../src/context/NestedEditorPluginsContext.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAGvC,MAAM,WAAW,+BAA+B;IAC9C,OAAO,CAAC,EAAE,SAAS,CAAC;CACrB;AAED,MAAM,WAAW,gCAAgC;IAC/C,QAAQ,EAAE,SAAS,CAAC;IACpB,OAAO,CAAC,EAAE,SAAS,CAAC;CACrB;AAED,eAAO,MAAM,0BAA0B,iEAEtC,CAAC;AAEF,wBAAgB,sBAAsB,IAAI,SAAS,CAElD"}
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import type { NestedEditorPluginsProviderProps } from './NestedEditorPluginsContext';
|
|
2
|
+
export declare function NestedEditorPluginsProvider({ children, plugins, }: NestedEditorPluginsProviderProps): import("react").JSX.Element;
|
|
3
|
+
//# sourceMappingURL=NestedEditorPluginsProvider.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"NestedEditorPluginsProvider.d.ts","sources":["../../src/context/NestedEditorPluginsProvider.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,gCAAgC,EAAE,MAAM,8BAA8B,CAAC;AAGrF,wBAAgB,2BAA2B,CAAC,EAC1C,QAAQ,EACR,OAAO,GACR,EAAE,gCAAgC,+BAGlC"}
|
|
@@ -1,14 +1,19 @@
|
|
|
1
|
-
import { ReactNode } from 'react';
|
|
2
|
-
import { RichEditorVariant } from '../types';
|
|
3
|
-
import { RendererConfig } from '../types/renderer-config';
|
|
1
|
+
import type { ReactNode } from 'react';
|
|
2
|
+
import type { RichEditorVariant } from '../types';
|
|
3
|
+
import type { RendererConfig } from '../types/renderer-config';
|
|
4
4
|
export type RendererMode = 'editor' | 'renderer';
|
|
5
|
+
export interface RendererConfigContextValue {
|
|
6
|
+
config?: RendererConfig;
|
|
7
|
+
mode: RendererMode;
|
|
8
|
+
variant: RichEditorVariant;
|
|
9
|
+
}
|
|
10
|
+
export declare const RendererConfigContext: import("react").Context<RendererConfigContextValue>;
|
|
5
11
|
export interface RendererConfigProviderProps {
|
|
6
12
|
children: ReactNode;
|
|
7
13
|
config?: RendererConfig;
|
|
8
14
|
mode: RendererMode;
|
|
9
15
|
variant: RichEditorVariant;
|
|
10
16
|
}
|
|
11
|
-
export declare function RendererConfigProvider({ config, mode, variant, children, }: RendererConfigProviderProps): import('react').JSX.Element;
|
|
12
17
|
export declare function useRendererConfig(): RendererConfig | undefined;
|
|
13
18
|
export declare function useRendererMode(): RendererMode;
|
|
14
19
|
export declare function useVariant(): RichEditorVariant;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RendererConfigContext.d.ts","
|
|
1
|
+
{"version":3,"file":"RendererConfigContext.d.ts","sources":["../../src/context/RendererConfigContext.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAGvC,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,UAAU,CAAC;AAClD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAE/D,MAAM,MAAM,YAAY,GAAG,QAAQ,GAAG,UAAU,CAAC;AAEjD,MAAM,WAAW,0BAA0B;IACzC,MAAM,CAAC,EAAE,cAAc,CAAC;IACxB,IAAI,EAAE,YAAY,CAAC;IACnB,OAAO,EAAE,iBAAiB,CAAC;CAC5B;AAED,eAAO,MAAM,qBAAqB,qDAIhC,CAAC;AAEH,MAAM,WAAW,2BAA2B;IAC1C,QAAQ,EAAE,SAAS,CAAC;IACpB,MAAM,CAAC,EAAE,cAAc,CAAC;IACxB,IAAI,EAAE,YAAY,CAAC;IACnB,OAAO,EAAE,iBAAiB,CAAC;CAC5B;AAED,wBAAgB,iBAAiB,IAAI,cAAc,GAAG,SAAS,CAE9D;AAED,wBAAgB,eAAe,IAAI,YAAY,CAE9C;AAED,wBAAgB,UAAU,IAAI,iBAAiB,CAE9C"}
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import type { RendererConfigProviderProps } from './RendererConfigContext';
|
|
2
|
+
export declare function RendererConfigProvider({ config, mode, variant, children, }: RendererConfigProviderProps): import("react").JSX.Element;
|
|
3
|
+
//# sourceMappingURL=RendererConfigProvider.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"RendererConfigProvider.d.ts","sources":["../../src/context/RendererConfigProvider.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,2BAA2B,EAAE,MAAM,yBAAyB,CAAC;AAG3E,wBAAgB,sBAAsB,CAAC,EACrC,MAAM,EACN,IAAI,EACJ,OAAO,EACP,QAAQ,GACT,EAAE,2BAA2B,+BAG7B"}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { TextSelectionSnapshot } from '../utils/text-selection';
|
|
1
|
+
import type { TextSelectionSnapshot } from '../utils/text-selection';
|
|
3
2
|
export interface TextSelectionStoreState {
|
|
4
3
|
snapshot: TextSelectionSnapshot | null;
|
|
5
4
|
}
|
|
@@ -10,9 +9,7 @@ export interface TextSelectionStore {
|
|
|
10
9
|
subscribe: (listener: () => void) => () => void;
|
|
11
10
|
}
|
|
12
11
|
export declare function createTextSelectionStore(initialState?: TextSelectionStoreState): TextSelectionStore;
|
|
13
|
-
export declare
|
|
14
|
-
children: ReactNode;
|
|
15
|
-
}): import('react').JSX.Element;
|
|
12
|
+
export declare const TextSelectionStoreContext: import("react").Context<TextSelectionStore | null>;
|
|
16
13
|
export declare function useTextSelectionStore(): TextSelectionStore;
|
|
17
14
|
export declare function useTextSelectionSnapshot(): TextSelectionSnapshot | null;
|
|
18
15
|
//# sourceMappingURL=TextSelectionContext.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TextSelectionContext.d.ts","
|
|
1
|
+
{"version":3,"file":"TextSelectionContext.d.ts","sources":["../../src/context/TextSelectionContext.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,yBAAyB,CAAC;AAErE,MAAM,WAAW,uBAAuB;IACtC,QAAQ,EAAE,qBAAqB,GAAG,IAAI,CAAC;CACxC;AAED,MAAM,WAAW,kBAAkB;IACjC,aAAa,EAAE,MAAM,IAAI,CAAC;IAC1B,QAAQ,EAAE,MAAM,uBAAuB,CAAC;IACxC,WAAW,EAAE,CAAC,QAAQ,EAAE,qBAAqB,GAAG,IAAI,KAAK,IAAI,CAAC;IAC9D,SAAS,EAAE,CAAC,QAAQ,EAAE,MAAM,IAAI,KAAK,MAAM,IAAI,CAAC;CACjD;AAkBD,wBAAgB,wBAAwB,CACtC,YAAY,GAAE,uBAA4C,GACzD,kBAAkB,CAmCpB;AAED,eAAO,MAAM,yBAAyB,oDAAiD,CAAC;AAExF,wBAAgB,qBAAqB,IAAI,kBAAkB,CAM1D;AAED,wBAAgB,wBAAwB,IAAI,qBAAqB,GAAG,IAAI,CAOvE"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TextSelectionStoreProvider.d.ts","sources":["../../src/context/TextSelectionStoreProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAKvC,wBAAgB,0BAA0B,CAAC,EAAE,QAAQ,EAAE,EAAE;IAAE,QAAQ,EAAE,SAAS,CAAA;CAAE,+BAI/E"}
|
|
@@ -1,8 +1,4 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
export declare function VideoUploadProvider({ upload, children, }: {
|
|
4
|
-
upload: VideoUploadFn | null;
|
|
5
|
-
children: ReactNode;
|
|
6
|
-
}): import('react').JSX.Element;
|
|
1
|
+
import type { VideoUploadFn } from '../plugins/VideoUploadPlugin';
|
|
2
|
+
export declare const VideoUploadContext: import("react").Context<VideoUploadFn | null>;
|
|
7
3
|
export declare function useVideoUpload(): VideoUploadFn | null;
|
|
8
4
|
//# sourceMappingURL=VideoUploadContext.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"VideoUploadContext.d.ts","
|
|
1
|
+
{"version":3,"file":"VideoUploadContext.d.ts","sources":["../../src/context/VideoUploadContext.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,8BAA8B,CAAC;AAElE,eAAO,MAAM,kBAAkB,+CAA4C,CAAC;AAE5E,wBAAgB,cAAc,IAAI,aAAa,GAAG,IAAI,CAErD"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { ReactNode } from 'react';
|
|
2
|
+
import type { VideoUploadFn } from '../plugins/VideoUploadPlugin';
|
|
3
|
+
export declare function VideoUploadProvider({ upload, children, }: {
|
|
4
|
+
upload: VideoUploadFn | null;
|
|
5
|
+
children: ReactNode;
|
|
6
|
+
}): import("react").JSX.Element;
|
|
7
|
+
//# sourceMappingURL=VideoUploadProvider.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"VideoUploadProvider.d.ts","sources":["../../src/context/VideoUploadProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEvC,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,8BAA8B,CAAC;AAGlE,wBAAgB,mBAAmB,CAAC,EAClC,MAAM,EACN,QAAQ,GACT,EAAE;IACD,MAAM,EAAE,aAAa,GAAG,IAAI,CAAC;IAC7B,QAAQ,EAAE,SAAS,CAAC;CACrB,+BAEA"}
|
package/dist/index.d.ts
CHANGED
|
@@ -8,24 +8,31 @@ export type { RichEditorShellProps } from './components/RichEditorShell';
|
|
|
8
8
|
export { RichEditorShell } from './components/RichEditorShell';
|
|
9
9
|
export { getVariantClass } from './components/utils';
|
|
10
10
|
export type { ColorScheme } from './context/ColorSchemeContext';
|
|
11
|
-
export {
|
|
11
|
+
export { useColorScheme } from './context/ColorSchemeContext';
|
|
12
|
+
export { ColorSchemeProvider } from './context/ColorSchemeProvider';
|
|
12
13
|
export type { DocumentBlocks } from './context/EditorBlockContext';
|
|
13
14
|
export { useEditorBlock, useEditorBlock as useVirtualizedBlock, } from './context/EditorBlockContext';
|
|
15
|
+
export { ActiveEditorScope, EditorSurfacePlugin, EditorSurfacePlugins, } from './context/EditorSurface';
|
|
14
16
|
export type { EditorSurfaceProps } from './context/EditorSurfaceContext';
|
|
15
|
-
export {
|
|
16
|
-
export {
|
|
17
|
+
export { useActiveEditor } from './context/EditorSurfaceContext';
|
|
18
|
+
export { useExtraNodes } from './context/ExtraNodesContext';
|
|
19
|
+
export { ExtraNodesProvider } from './context/ExtraNodesProvider';
|
|
17
20
|
export type { FootnoteDefinitionsContextValue } from './context/FootnoteDefinitionsContext';
|
|
18
|
-
export {
|
|
21
|
+
export { useFootnoteContent, useFootnoteDefinitions, useFootnoteDisplayNumber, } from './context/FootnoteDefinitionsContext';
|
|
22
|
+
export { FootnoteDefinitionsProvider } from './context/FootnoteDefinitionsProvider';
|
|
19
23
|
export type { RenderEditorStateFn } from './context/NestedContentRendererContext';
|
|
20
24
|
export { NestedContentRendererProvider, useNestedContentRenderer, useOptionalNestedContentRenderer, } from './context/NestedContentRendererContext';
|
|
21
25
|
export type { NestedEditorPluginsProviderProps } from './context/NestedEditorPluginsContext';
|
|
22
|
-
export {
|
|
26
|
+
export { useNestedEditorPlugins } from './context/NestedEditorPluginsContext';
|
|
27
|
+
export { NestedEditorPluginsProvider } from './context/NestedEditorPluginsProvider';
|
|
23
28
|
export type { RendererMode } from './context/RendererConfigContext';
|
|
24
|
-
export {
|
|
29
|
+
export { useRendererConfig, useRendererMode, useVariant } from './context/RendererConfigContext';
|
|
30
|
+
export { RendererConfigProvider } from './context/RendererConfigProvider';
|
|
25
31
|
export type { TextSelectionStore, TextSelectionStoreState } from './context/TextSelectionContext';
|
|
26
|
-
export { createTextSelectionStore,
|
|
32
|
+
export { createTextSelectionStore, useTextSelectionSnapshot, useTextSelectionStore, } from './context/TextSelectionContext';
|
|
33
|
+
export { TextSelectionStoreProvider } from './context/TextSelectionStoreProvider';
|
|
27
34
|
export { createNestedEditor, NESTED_EDITOR_NODES } from './nodes/shared';
|
|
28
|
-
export { blockIdState } from './plugins/
|
|
35
|
+
export { blockIdState } from './plugins/block-id-state';
|
|
29
36
|
export { VirtualizationPlugin } from './plugins/VirtualizationPlugin';
|
|
30
37
|
export * from './styles';
|
|
31
38
|
export type { RichEditorProps, RichEditorVariant } from './types';
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","
|
|
1
|
+
{"version":3,"file":"index.d.ts","sources":["../src/index.ts"],"names":[],"mappings":"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"}
|
package/dist/index.mjs
CHANGED
|
@@ -1,22 +1,20 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { n as setResolvedEditNodes, r as allEditNodes } from "./node-registry-
|
|
1
|
+
import { $ as CorePlugins, B as FileUploadPlugin, C as createTextSelectionStore, D as LinkFaviconPlugin, E as MermaidPlugin, G as VideoUploadProvider, N as ImagePlugin, O as KaTeXPlugin, P as defaultImageUpload, S as TextSelectionStoreContext, T as useTextSelectionStore, U as BlockIdPlugin, W as AlertPlugin, Y as ImagePreprocessProvider, Z as FileUploadProvider, _ as $getRootBlock, a as EditorRefPlugin, b as buildBlockAnchor, c as $captureTextSelection, d as createDOMRangeFromTextSelection, f as findDOMPointByTextOffset, g as TEXT_SELECTION_HIGHLIGHT_NAME, h as getTextOffsetFromDOMPoint, i as FootnotePlugin, k as ImageUploadPlugin, l as $captureTextSelectionFromRangeSelection, m as getDOMRectFromTextSelection, n as SubmitShortcutPlugin, o as VideoUploadPlugin, p as getBlockElementById, q as ImageUploadProvider, r as OnChangePlugin, s as TextSelectionPlugin, t as AutoFocusPlugin, u as $restoreTextSelection, v as $getTextOffsetInBlock, w as useTextSelectionSnapshot, x as buildRangeAnchor, y as $resolveSelectionPoint } from "./VirtualizationPlugin-DbAHlGBL.js";
|
|
2
|
+
import { d as useNestedEditorSync, f as registerNestedEditorSync, l as NESTED_EDITOR_NODES, n as setResolvedEditNodes, p as NestedEditorCorePlugins, r as allEditNodes, u as createNestedEditor } from "./node-registry-PtbiwsVu.js";
|
|
3
3
|
import { n as useEditorBlock } from "./EditorBlockContext-DytAx9Tg.js";
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import { n as
|
|
8
|
-
import { i as detailsStyles, n as gridStyles, r as detailsClassNames, t as gridClassNames } from "./grid.css-
|
|
9
|
-
import { n as useNestedEditorPlugins, t as
|
|
10
|
-
import {
|
|
11
|
-
import { t as
|
|
12
|
-
import { n as
|
|
13
|
-
import {
|
|
14
|
-
import { a as KaTeXPlugin, c as AlertPlugin, n as MermaidPlugin, s as ImagePlugin } from "./MermaidPlugin-D0Z2_YAe.js";
|
|
15
|
-
import { n as blockIdState, t as BlockIdPlugin } from "./BlockIdPlugin-Cwv8aV9g.js";
|
|
4
|
+
import { Dt as useNestedContentRenderer, Et as NestedContentRendererProvider, Ot as useOptionalNestedContentRenderer, n as useColorScheme, r as editorTheme } from "./ColorSchemeContext-DLWz8vFw.js";
|
|
5
|
+
import { A as RUBY_NODE_KEY, C as FOOTNOTE_NODE_KEY, D as LINK_CARD_NODE_KEY, E as KATEX_NODE_KEY, M as VIDEO_NODE_KEY, O as MENTION_NODE_KEY, S as FILE_NODE_KEY, T as IMAGE_NODE_KEY, _ as useRendererMode, b as BANNER_NODE_KEY, c as useFootnoteDisplayNumber, g as useRendererConfig, j as TAG_NODE_KEY, k as MERMAID_NODE_KEY, o as useFootnoteContent, s as useFootnoteDefinitions, v as useVariant, w as FOOTNOTE_SECTION_NODE_KEY, x as CODE_BLOCK_NODE_KEY, y as ALERT_NODE_KEY } from "./LinkCardRenderer-D4mQbUQo.js";
|
|
6
|
+
import { n as semanticClassNames, r as sharedStyles, t as richContent } from "./shared.css-DRoqE_U-.js";
|
|
7
|
+
import { a as chatVariant, i as commentVariant, n as getVariantClass, o as articleVariant, r as noteVariant, t as clsx } from "./utils-i78C9io3.js";
|
|
8
|
+
import { i as detailsStyles, n as gridStyles, r as detailsClassNames, t as gridClassNames } from "./grid.css-DAMDDTZh.js";
|
|
9
|
+
import { n as useNestedEditorPlugins, t as NestedEditorPluginsContext } from "./NestedEditorPluginsContext-DKFdozOE.js";
|
|
10
|
+
import { n as FootnoteDefinitionsProvider, t as normalizeSerializedEditorState } from "./normalizeSerializedEditorState-CNUAQd3l.js";
|
|
11
|
+
import { a as LinkFavicon, i as useExtraNodes, n as ColorSchemeProvider, r as ExtraNodesProvider, t as RendererConfigProvider } from "./RendererConfigProvider-BPYO0Ip0.js";
|
|
12
|
+
import { a as EditorSurfaceProvider, i as EditorSurfacePlugins, n as ActiveEditorScope, o as useActiveEditor, r as EditorSurfacePlugin, s as useEditorSurface, t as VirtualizationPlugin } from "./VirtualizationPlugin-CkNi6FW2.js";
|
|
13
|
+
import { t as blockIdState } from "./block-id-state-DfN32rR_.js";
|
|
16
14
|
import { n as contentWrapper, r as placeholder, t as content } from "./ContentEditable.css--lQ6ekTS.js";
|
|
17
|
-
import { n as katexStyles, t as katexClassNames } from "./katex.css-
|
|
15
|
+
import { n as katexStyles, t as katexClassNames } from "./katex.css-DJbW49pH.js";
|
|
18
16
|
import { useLexicalComposerContext } from "@lexical/react/LexicalComposerContext";
|
|
19
|
-
import { useCallback, useLayoutEffect, useMemo,
|
|
17
|
+
import { useCallback, useLayoutEffect, useMemo, useState } from "react";
|
|
20
18
|
import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
|
|
21
19
|
import { ContentEditable } from "@lexical/react/LexicalContentEditable";
|
|
22
20
|
import { LexicalErrorBoundary } from "@lexical/react/LexicalErrorBoundary";
|
|
@@ -26,6 +24,15 @@ import { PortalThemeProvider } from "@haklex/rich-style-token";
|
|
|
26
24
|
import { LexicalComposer } from "@lexical/react/LexicalComposer";
|
|
27
25
|
import { HistoryPlugin } from "@lexical/react/LexicalHistoryPlugin";
|
|
28
26
|
import { articleTheme, chatTheme, commentTheme, noteTheme, vars } from "@haklex/rich-style-token/styles";
|
|
27
|
+
//#region src/context/TextSelectionStoreProvider.tsx
|
|
28
|
+
function TextSelectionStoreProvider({ children }) {
|
|
29
|
+
const [store] = useState(createTextSelectionStore);
|
|
30
|
+
return /* @__PURE__ */ jsx(TextSelectionStoreContext, {
|
|
31
|
+
value: store,
|
|
32
|
+
children
|
|
33
|
+
});
|
|
34
|
+
}
|
|
35
|
+
//#endregion
|
|
29
36
|
//#region src/components/ContentEditable.tsx
|
|
30
37
|
function ContentEditable$1({ className, placeholder: placeholder$1, hasHeader }) {
|
|
31
38
|
const paddingTop = hasHeader ? 40 : 12;
|
|
@@ -65,12 +72,8 @@ function StandardSurface({ className, hasHeader, placeholder, plugins, autoFocus
|
|
|
65
72
|
] });
|
|
66
73
|
}
|
|
67
74
|
function EditorSurfaceHost(props) {
|
|
68
|
-
const { surface, plugins,
|
|
69
|
-
const
|
|
70
|
-
current.current = surface;
|
|
71
|
-
const onActiveEditorChange = useCallback((editor) => {
|
|
72
|
-
if (current.current === surface) setActiveEditor(editor);
|
|
73
|
-
}, [setActiveEditor, surface]);
|
|
75
|
+
const { surface, plugins, activateEditor, retainSurface } = useEditorSurface();
|
|
76
|
+
const onActiveEditorChange = useCallback((editor) => activateEditor(surface, editor), [activateEditor, surface]);
|
|
74
77
|
const [ready, setReady] = useState(false);
|
|
75
78
|
useLayoutEffect(() => setReady(true), []);
|
|
76
79
|
if (!ready) return null;
|
|
@@ -196,4 +199,13 @@ function RichEditor({ extraNodes, imageUpload, videoUpload, fileUpload, children
|
|
|
196
199
|
}) });
|
|
197
200
|
}
|
|
198
201
|
//#endregion
|
|
202
|
+
//#region src/context/NestedEditorPluginsProvider.tsx
|
|
203
|
+
function NestedEditorPluginsProvider({ children, plugins }) {
|
|
204
|
+
const value = useMemo(() => ({ plugins }), [plugins]);
|
|
205
|
+
return /* @__PURE__ */ jsx(NestedEditorPluginsContext, {
|
|
206
|
+
value,
|
|
207
|
+
children
|
|
208
|
+
});
|
|
209
|
+
}
|
|
210
|
+
//#endregion
|
|
199
211
|
export { $captureTextSelection, $captureTextSelectionFromRangeSelection, $getRootBlock, $getTextOffsetInBlock, $resolveSelectionPoint, $restoreTextSelection, ALERT_NODE_KEY, ActiveEditorScope, BANNER_NODE_KEY, CODE_BLOCK_NODE_KEY, ColorSchemeProvider, CorePlugins, EditorSurfacePlugin, EditorSurfacePlugins, ExtraNodesProvider, FILE_NODE_KEY, FOOTNOTE_NODE_KEY, FOOTNOTE_SECTION_NODE_KEY, FootnoteDefinitionsProvider, IMAGE_NODE_KEY, KATEX_NODE_KEY, LINK_CARD_NODE_KEY, LinkFavicon, MENTION_NODE_KEY, MERMAID_NODE_KEY, NESTED_EDITOR_NODES, NestedContentRendererProvider, NestedEditorCorePlugins, NestedEditorPluginsProvider, RUBY_NODE_KEY, RendererConfigProvider, RichEditor, RichEditorShell, TAG_NODE_KEY, TEXT_SELECTION_HIGHLIGHT_NAME, TextSelectionStoreProvider, VIDEO_NODE_KEY, VirtualizationPlugin, articleTheme, articleVariant, blockIdState, buildBlockAnchor, buildRangeAnchor, chatTheme, chatVariant, commentTheme, commentVariant, createDOMRangeFromTextSelection, createNestedEditor, createTextSelectionStore, detailsClassNames, detailsStyles, editorTheme, findDOMPointByTextOffset, getBlockElementById, getDOMRectFromTextSelection, getTextOffsetFromDOMPoint, getVariantClass, gridClassNames, gridStyles, katexClassNames, katexStyles, noteTheme, noteVariant, registerNestedEditorSync, richContent, semanticClassNames, sharedStyles, useActiveEditor, useColorScheme, useEditorBlock, useEditorBlock as useVirtualizedBlock, useExtraNodes, useFootnoteContent, useFootnoteDefinitions, useFootnoteDisplayNumber, useNestedContentRenderer, useNestedEditorPlugins, useNestedEditorSync, useOptionalNestedContentRenderer, useRendererConfig, useRendererMode, useTextSelectionSnapshot, useTextSelectionStore, useVariant, vars };
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { createCommand } from "lexical";
|
|
2
|
+
//#region src/plugins/insert-commands.ts
|
|
3
|
+
var INSERT_ALERT_COMMAND = createCommand("INSERT_ALERT");
|
|
4
|
+
var INSERT_IMAGE_COMMAND = createCommand("INSERT_IMAGE_COMMAND");
|
|
5
|
+
var INSERT_KATEX_INLINE_COMMAND = createCommand("INSERT_KATEX_INLINE");
|
|
6
|
+
var INSERT_KATEX_BLOCK_COMMAND = createCommand("INSERT_KATEX_BLOCK");
|
|
7
|
+
var INSERT_MERMAID_COMMAND = createCommand("INSERT_MERMAID");
|
|
8
|
+
//#endregion
|
|
9
|
+
export { INSERT_MERMAID_COMMAND as a, INSERT_KATEX_INLINE_COMMAND as i, INSERT_IMAGE_COMMAND as n, INSERT_KATEX_BLOCK_COMMAND as r, INSERT_ALERT_COMMAND as t };
|