@delali/web-editor 0.0.0-stage → 0.4.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/CHANGELOG.md +39 -0
- package/LICENSE +201 -0
- package/README.md +167 -2
- package/dist/components/editor/chat-comment-effects.d.ts +2 -0
- package/dist/components/editor/chat-types.d.ts +20 -0
- package/dist/components/editor/collaboration/base-collaboration-plugin.d.ts +14 -0
- package/dist/components/editor/collaboration/collaboration-plugin.d.ts +6 -0
- package/dist/components/editor/collaboration/collaboration-session.d.ts +30 -0
- package/dist/components/editor/collaboration/collaboration-starter.d.ts +9 -0
- package/dist/components/editor/collaboration/editor-collaboration.d.ts +16 -0
- package/dist/components/editor/collaboration/editor-collaboration.js +293 -0
- package/dist/components/editor/collaboration/remote-cursor-overlay.d.ts +1 -0
- package/dist/components/editor/collaboration/shared-document.d.ts +18 -0
- package/dist/components/editor/create-editor-plugins.d.ts +3 -0
- package/dist/components/editor/create-editor-plugins.js +25204 -0
- package/dist/components/editor/create-viewer-plugins.d.ts +3 -0
- package/dist/components/editor/editor-base-kit.d.ts +329 -0
- package/dist/components/editor/editor-base-kit.js +3136 -0
- package/dist/components/editor/editor-config.d.ts +14 -0
- package/dist/components/editor/editor-config.js +145 -0
- package/dist/components/editor/editor-kit.d.ts +3978 -0
- package/dist/components/editor/editor-kit.js +18781 -0
- package/dist/components/editor/plate-types.d.ts +99 -0
- package/dist/components/editor/plugins/accordion-group-base-kit.d.ts +2 -0
- package/dist/components/editor/plugins/accordion-group-kit.d.ts +3 -0
- package/dist/components/editor/plugins/accordion-types.d.ts +14 -0
- package/dist/components/editor/plugins/ai-kit.d.ts +248 -0
- package/dist/components/editor/plugins/align-base-kit.d.ts +3 -0
- package/dist/components/editor/plugins/api-doc/expandable-base-kit.d.ts +24 -0
- package/dist/components/editor/plugins/api-doc/expandable-kit.d.ts +29 -0
- package/dist/components/editor/plugins/api-doc/expandable-types.d.ts +7 -0
- package/dist/components/editor/plugins/api-doc/panel-base-kit.d.ts +2 -0
- package/dist/components/editor/plugins/api-doc/panel-kit.d.ts +3 -0
- package/dist/components/editor/plugins/api-doc/panel-types.d.ts +7 -0
- package/dist/components/editor/plugins/api-doc/response-field-base-kit.d.ts +3 -0
- package/dist/components/editor/plugins/api-doc/response-field-kit.d.ts +4 -0
- package/dist/components/editor/plugins/api-doc/response-field-types.d.ts +17 -0
- package/dist/components/editor/plugins/autoformat-kit.d.ts +1 -0
- package/dist/components/editor/plugins/badge-base-kit.d.ts +2 -0
- package/dist/components/editor/plugins/badge-kit.d.ts +3 -0
- package/dist/components/editor/plugins/badge-types.d.ts +24 -0
- package/dist/components/editor/plugins/banner-base-kit.d.ts +2 -0
- package/dist/components/editor/plugins/banner-kit.d.ts +3 -0
- package/dist/components/editor/plugins/banner-types.d.ts +15 -0
- package/dist/components/editor/plugins/basic-blocks-base-kit.d.ts +5 -0
- package/dist/components/editor/plugins/basic-blocks-kit.d.ts +5 -0
- package/dist/components/editor/plugins/basic-marks-base-kit.d.ts +19 -0
- package/dist/components/editor/plugins/basic-marks-kit.d.ts +35 -0
- package/dist/components/editor/plugins/basic-nodes-kit.d.ts +21 -0
- package/dist/components/editor/plugins/block-menu-kit.d.ts +165 -0
- package/dist/components/editor/plugins/block-placeholder-kit.d.ts +14 -0
- package/dist/components/editor/plugins/block-selection-kit.d.ts +137 -0
- package/dist/components/editor/plugins/callout-base-kit.d.ts +20 -0
- package/dist/components/editor/plugins/callout-kit.d.ts +20 -0
- package/dist/components/editor/plugins/callout-types.d.ts +18 -0
- package/dist/components/editor/plugins/card-base-kit.d.ts +2 -0
- package/dist/components/editor/plugins/card-kit.d.ts +3 -0
- package/dist/components/editor/plugins/card-types.d.ts +14 -0
- package/dist/components/editor/plugins/caret-placement-kit.d.ts +8 -0
- package/dist/components/editor/plugins/code-block-base-kit.d.ts +7 -0
- package/dist/components/editor/plugins/code-block-input-rule-gate.d.ts +4 -0
- package/dist/components/editor/plugins/code-block-kit.d.ts +7 -0
- package/dist/components/editor/plugins/color-base-kit.d.ts +2 -0
- package/dist/components/editor/plugins/color-kit.d.ts +3 -0
- package/dist/components/editor/plugins/color-types.d.ts +18 -0
- package/dist/components/editor/plugins/column-base-kit.d.ts +1 -0
- package/dist/components/editor/plugins/column-kit.d.ts +1 -0
- package/dist/components/editor/plugins/comment-base-kit.d.ts +47 -0
- package/dist/components/editor/plugins/comment-kit.d.ts +71 -0
- package/dist/components/editor/plugins/copilot-kit.d.ts +72 -0
- package/dist/components/editor/plugins/cursor-overlay-kit.d.ts +11 -0
- package/dist/components/editor/plugins/date-base-kit.d.ts +19 -0
- package/dist/components/editor/plugins/date-kit.d.ts +19 -0
- package/dist/components/editor/plugins/discussion-kit.d.ts +31 -0
- package/dist/components/editor/plugins/dnd-kit.d.ts +20 -0
- package/dist/components/editor/plugins/docx-kit.d.ts +1 -0
- package/dist/components/editor/plugins/emoji-kit.d.ts +9 -0
- package/dist/components/editor/plugins/exit-break-kit.d.ts +4 -0
- package/dist/components/editor/plugins/floating-toolbar-kit.d.ts +1 -0
- package/dist/components/editor/plugins/font-base-kit.d.ts +9 -0
- package/dist/components/editor/plugins/font-kit.d.ts +9 -0
- package/dist/components/editor/plugins/fraction-input-rule.d.ts +12 -0
- package/dist/components/editor/plugins/frame-base-kit.d.ts +2 -0
- package/dist/components/editor/plugins/frame-kit.d.ts +3 -0
- package/dist/components/editor/plugins/frame-types.d.ts +10 -0
- package/dist/components/editor/plugins/icon-base-kit.d.ts +2 -0
- package/dist/components/editor/plugins/icon-kit.d.ts +3 -0
- package/dist/components/editor/plugins/icon-types.d.ts +15 -0
- package/dist/components/editor/plugins/indent-base-kit.d.ts +1 -0
- package/dist/components/editor/plugins/indent-kit.d.ts +5 -0
- package/dist/components/editor/plugins/input-rule-gate.d.ts +8 -0
- package/dist/components/editor/plugins/line-height-base-kit.d.ts +3 -0
- package/dist/components/editor/plugins/link-base-kit.d.ts +2 -0
- package/dist/components/editor/plugins/link-kit.d.ts +89 -0
- package/dist/components/editor/plugins/list-base-kit.d.ts +1 -0
- package/dist/components/editor/plugins/list-kit.d.ts +16 -0
- package/dist/components/editor/plugins/mark-input-rule-gate.d.ts +2 -0
- package/dist/components/editor/plugins/markdown-kit.d.ts +19 -0
- package/dist/components/editor/plugins/math-base-kit.d.ts +9 -0
- package/dist/components/editor/plugins/math-kit.d.ts +9 -0
- package/dist/components/editor/plugins/media-base-kit.d.ts +25 -0
- package/dist/components/editor/plugins/media-kit.d.ts +38 -0
- package/dist/components/editor/plugins/mention-base-kit.d.ts +11 -0
- package/dist/components/editor/plugins/mention-kit.d.ts +11 -0
- package/dist/components/editor/plugins/mermaid-base-kit.d.ts +2 -0
- package/dist/components/editor/plugins/mermaid-kit.d.ts +3 -0
- package/dist/components/editor/plugins/mermaid-types.d.ts +14 -0
- package/dist/components/editor/plugins/shared/color-selector.d.ts +9 -0
- package/dist/components/editor/plugins/shared/component-popover.d.ts +12 -0
- package/dist/components/editor/plugins/slash-kit.d.ts +1 -0
- package/dist/components/editor/plugins/steps-base-kit.d.ts +3 -0
- package/dist/components/editor/plugins/steps-kit.d.ts +4 -0
- package/dist/components/editor/plugins/steps-types.d.ts +18 -0
- package/dist/components/editor/plugins/suggestion-base-kit.d.ts +32 -0
- package/dist/components/editor/plugins/suggestion-kit.d.ts +53 -0
- package/dist/components/editor/plugins/tabbed-code-block-base-kit.d.ts +32 -0
- package/dist/components/editor/plugins/tabbed-code-block-kit.d.ts +33 -0
- package/dist/components/editor/plugins/tabbed-code-block-types.d.ts +29 -0
- package/dist/components/editor/plugins/table-base-kit.d.ts +94 -0
- package/dist/components/editor/plugins/table-kit.d.ts +162 -0
- package/dist/components/editor/plugins/tabs-base-kit.d.ts +2 -0
- package/dist/components/editor/plugins/tabs-kit.d.ts +3 -0
- package/dist/components/editor/plugins/tabs-types.d.ts +14 -0
- package/dist/components/editor/plugins/text-substitution-input-rule-gate.d.ts +4 -0
- package/dist/components/editor/plugins/tiles-base-kit.d.ts +3 -0
- package/dist/components/editor/plugins/tiles-kit.d.ts +4 -0
- package/dist/components/editor/plugins/tiles-types.d.ts +16 -0
- package/dist/components/editor/plugins/toc-base-kit.d.ts +1 -0
- package/dist/components/editor/plugins/toc-kit.d.ts +5 -0
- package/dist/components/editor/plugins/todo-to-bullet-kit.d.ts +7 -0
- package/dist/components/editor/plugins/toggle-base-kit.d.ts +12 -0
- package/dist/components/editor/plugins/toggle-kit.d.ts +16 -0
- package/dist/components/editor/plugins/tooltip-base-kit.d.ts +2 -0
- package/dist/components/editor/plugins/tooltip-html.d.ts +27 -0
- package/dist/components/editor/plugins/tooltip-kit.d.ts +3 -0
- package/dist/components/editor/plugins/tooltip-types.d.ts +10 -0
- package/dist/components/editor/plugins/tree-base-kit.d.ts +2 -0
- package/dist/components/editor/plugins/tree-kit.d.ts +3 -0
- package/dist/components/editor/plugins/tree-types.d.ts +26 -0
- package/dist/components/editor/plugins/typed-conversion-options.d.ts +13 -0
- package/dist/components/editor/plugins/update-base-kit.d.ts +1 -0
- package/dist/components/editor/plugins/update-kit.d.ts +4 -0
- package/dist/components/editor/plugins/update-types.d.ts +19 -0
- package/dist/components/editor/plugins/web-address-text.d.ts +1 -0
- package/dist/components/editor/transforms.d.ts +8 -0
- package/dist/components/editor/use-chat.d.ts +3 -0
- package/dist/components/editor/use-chat.js +3315 -0
- package/dist/components/editor/use-typed-conversion-options.d.ts +3 -0
- package/dist/components/editor/version-history/chunk-node.d.ts +7 -0
- package/dist/components/editor/version-history/chunk-plugin.d.ts +6 -0
- package/dist/components/editor/version-history/collapse-blocks-without-diff.d.ts +4 -0
- package/dist/components/editor/version-history/diff-node.d.ts +9 -0
- package/dist/components/editor/version-history/diff-plate.d.ts +7 -0
- package/dist/components/editor/version-history/diff-plugin.d.ts +8 -0
- package/dist/components/editor/version-history/index.d.ts +9 -0
- package/dist/components/editor/version-history/index.js +19179 -0
- package/dist/components/editor/version-history/use-object-version.d.ts +1 -0
- package/dist/components/editor/version-history/use-reset-editor-on-change.d.ts +7 -0
- package/dist/components/editor/version-history/version-plate.d.ts +7 -0
- package/dist/components/editor/web-editor.d.ts +6 -0
- package/dist/components/editor/web-editor.js +27295 -0
- package/dist/context/editor-adapter-context.d.ts +13 -0
- package/dist/context/editor-adapter-context.js +124 -0
- package/dist/context/editor-adapter.d.ts +262 -0
- package/dist/context/editor-toc-context.d.ts +16 -0
- package/dist/context/heading-slug-context.d.ts +11 -0
- package/dist/context/link-resolution-context.d.ts +24 -0
- package/dist/context/link-resolution-store.d.ts +20 -0
- package/dist/context/portal-container.d.ts +7 -0
- package/dist/hooks/use-copy-to-clipboard.d.ts +10 -0
- package/dist/hooks/use-dark-mode.d.ts +1 -0
- package/dist/hooks/use-debounce-callback.d.ts +108 -0
- package/dist/hooks/use-debounce.d.ts +1 -0
- package/dist/hooks/use-is-touch-device.d.ts +1 -0
- package/dist/hooks/use-lock-scroll.d.ts +1 -0
- package/dist/hooks/use-media-query.d.ts +2 -0
- package/dist/hooks/use-mounted.d.ts +6 -0
- package/dist/hooks/use-on-click-outside.d.ts +26 -0
- package/dist/hooks/use-shield-input-selection-from-editor.d.ts +3 -0
- package/dist/hooks/use-upload-file.d.ts +25 -0
- package/dist/hooks/use-upload-file.js +129 -0
- package/dist/lib/accepted-file-types.d.ts +1 -0
- package/dist/lib/block-features.d.ts +11 -0
- package/dist/lib/comment-mark-strip.d.ts +24 -0
- package/dist/lib/comment-mark-strip.js +56 -0
- package/dist/lib/download-file.d.ts +1 -0
- package/dist/lib/editor-element-path.d.ts +8 -0
- package/dist/lib/extract-headings.d.ts +13 -0
- package/dist/lib/extract-headings.js +79 -0
- package/dist/lib/file-size-limit.d.ts +7 -0
- package/dist/lib/html-serialize-hast.d.ts +18 -0
- package/dist/lib/html-serialize-rules.d.ts +15 -0
- package/dist/lib/html-serialize-utils.d.ts +24 -0
- package/dist/lib/html-serialize-utils.js +392 -0
- package/dist/lib/line-marking-context.d.ts +13 -0
- package/dist/lib/line-marking.d.ts +47 -0
- package/dist/lib/list-html.d.ts +30 -0
- package/dist/lib/markdown-joiner-transform.d.ts +31 -0
- package/dist/lib/markdown-utils.d.ts +4 -0
- package/dist/lib/markdown-utils.js +25275 -0
- package/dist/lib/mdx/mdx-archetype-rules.d.ts +2 -0
- package/dist/lib/mdx/mdx-attribute-codec.d.ts +23 -0
- package/dist/lib/mdx/mdx-color-rules.d.ts +2 -0
- package/dist/lib/mdx/mdx-component-rules.d.ts +2 -0
- package/dist/lib/mdx/mdx-mermaid-rules.d.ts +10 -0
- package/dist/lib/mdx/mdx-reference-rules.d.ts +11 -0
- package/dist/lib/mdx/mdx-round-trip.d.ts +3 -0
- package/dist/lib/mdx/mdx-round-trip.js +1397 -0
- package/dist/lib/mdx/mdx-rule-builder.d.ts +45 -0
- package/dist/lib/mdx/mdx-server-plugins.d.ts +8 -0
- package/dist/lib/mdx/mdx-tabbed-code-rules.d.ts +2 -0
- package/dist/lib/mdx/mdx-tabs-rules.d.ts +2 -0
- package/dist/lib/mdx/mdx-toggle-rules.d.ts +9 -0
- package/dist/lib/mdx/mdx-tree-rules.d.ts +2 -0
- package/dist/lib/media-html.d.ts +121 -0
- package/dist/lib/paragraph-html.d.ts +26 -0
- package/dist/lib/server-plugins.d.ts +199 -0
- package/dist/lib/utils.d.ts +3 -0
- package/dist/lib/utils.js +25 -0
- package/dist/lib/video-embeds.d.ts +9 -0
- package/dist/styles.css +6726 -0
- package/dist/types/editor.d.ts +161 -0
- package/dist/types/editor.js +77 -0
- package/dist/ui/accordion-group-node-static.d.ts +11 -0
- package/dist/ui/accordion-group-node.d.ts +10 -0
- package/dist/ui/ai-chat-editor.d.ts +4 -0
- package/dist/ui/ai-menu.d.ts +2 -0
- package/dist/ui/ai-node.d.ts +3 -0
- package/dist/ui/ai-toolbar-button.d.ts +3 -0
- package/dist/ui/alert-dialog.d.ts +20 -0
- package/dist/ui/api-doc/expandable-node-static.d.ts +4 -0
- package/dist/ui/api-doc/expandable-node.d.ts +3 -0
- package/dist/ui/api-doc/expandable-settings.d.ts +17 -0
- package/dist/ui/api-doc/panel-node-static.d.ts +3 -0
- package/dist/ui/api-doc/panel-node.d.ts +3 -0
- package/dist/ui/api-doc/response-field-item-node-static.d.ts +3 -0
- package/dist/ui/api-doc/response-field-item-node.d.ts +3 -0
- package/dist/ui/api-doc/response-field-node-static.d.ts +9 -0
- package/dist/ui/api-doc/response-field-node.d.ts +9 -0
- package/dist/ui/avatar.d.ts +16 -0
- package/dist/ui/badge-node-static.d.ts +3 -0
- package/dist/ui/badge-node.d.ts +3 -0
- package/dist/ui/badge-settings-options.d.ts +24 -0
- package/dist/ui/badge-settings.d.ts +19 -0
- package/dist/ui/badge.d.ts +9 -0
- package/dist/ui/banner-node-static.d.ts +4 -0
- package/dist/ui/banner-node.d.ts +3 -0
- package/dist/ui/block-context-menu.d.ts +8 -0
- package/dist/ui/block-discussion.d.ts +3 -0
- package/dist/ui/block-draggable.d.ts +2 -0
- package/dist/ui/block-list-static.d.ts +2 -0
- package/dist/ui/block-list.d.ts +2 -0
- package/dist/ui/block-menu.d.ts +167 -0
- package/dist/ui/block-selection.d.ts +5 -0
- package/dist/ui/block-suggestion.d.ts +17 -0
- package/dist/ui/blockquote-node-static.d.ts +2 -0
- package/dist/ui/blockquote-node.d.ts +2 -0
- package/dist/ui/button.d.ts +81 -0
- package/dist/ui/calendar.d.ts +5 -0
- package/dist/ui/callout-detail-settings.d.ts +15 -0
- package/dist/ui/callout-icon.d.ts +9 -0
- package/dist/ui/callout-node-static.d.ts +2 -0
- package/dist/ui/callout-node.d.ts +3 -0
- package/dist/ui/callout-settings.d.ts +19 -0
- package/dist/ui/callout-type-button.d.ts +9 -0
- package/dist/ui/caption.d.ts +72 -0
- package/dist/ui/card-element-actions.d.ts +7 -0
- package/dist/ui/card-icon-settings.d.ts +11 -0
- package/dist/ui/card-node-static.d.ts +3 -0
- package/dist/ui/card-node.d.ts +3 -0
- package/dist/ui/card-settings.d.ts +24 -0
- package/dist/ui/card-title-row.d.ts +14 -0
- package/dist/ui/checkbox.d.ts +4 -0
- package/dist/ui/code-block-line-marking-form.d.ts +9 -0
- package/dist/ui/code-block-line-marking-input.d.ts +8 -0
- package/dist/ui/code-block-line-marking-popover.d.ts +12 -0
- package/dist/ui/code-block-line-marking-state.d.ts +11 -0
- package/dist/ui/code-block-node-static.d.ts +10 -0
- package/dist/ui/code-block-node.d.ts +5 -0
- package/dist/ui/code-line-selection-toolbar.d.ts +10 -0
- package/dist/ui/code-line-wrapper.d.ts +22 -0
- package/dist/ui/code-node-static.d.ts +2 -0
- package/dist/ui/code-node.d.ts +2 -0
- package/dist/ui/collapsible.d.ts +6 -0
- package/dist/ui/color-copy-icon.d.ts +9 -0
- package/dist/ui/color-element-actions.d.ts +7 -0
- package/dist/ui/color-item-settings.d.ts +11 -0
- package/dist/ui/color-node-static.d.ts +3 -0
- package/dist/ui/color-node.d.ts +3 -0
- package/dist/ui/color-settings.d.ts +18 -0
- package/dist/ui/color-swatch-editable.d.ts +12 -0
- package/dist/ui/color-table-row-editable.d.ts +10 -0
- package/dist/ui/column-node-static.d.ts +4 -0
- package/dist/ui/column-node.d.ts +3 -0
- package/dist/ui/command.d.ts +25 -0
- package/dist/ui/comment-node-static.d.ts +3 -0
- package/dist/ui/comment-node.d.ts +3 -0
- package/dist/ui/comment-toolbar-button.d.ts +1 -0
- package/dist/ui/comment.d.ts +45 -0
- package/dist/ui/cursor-overlay.d.ts +4 -0
- package/dist/ui/date-node-static.d.ts +2 -0
- package/dist/ui/date-node.d.ts +2 -0
- package/dist/ui/dialog.d.ts +90 -0
- package/dist/ui/dropdown-menu.d.ts +35 -0
- package/dist/ui/editor-inspector-panel.d.ts +6 -0
- package/dist/ui/editor-static.d.ts +8 -0
- package/dist/ui/editor.d.ts +15 -0
- package/dist/ui/emoji-node.d.ts +3 -0
- package/dist/ui/emoji-toolbar-button.d.ts +16 -0
- package/dist/ui/equation-node-static.d.ts +4 -0
- package/dist/ui/equation-node.d.ts +5 -0
- package/dist/ui/equation-toolbar-button.d.ts +2 -0
- package/dist/ui/floating-discussion.d.ts +8 -0
- package/dist/ui/floating-toolbar-buttons.d.ts +1 -0
- package/dist/ui/floating-toolbar.d.ts +6 -0
- package/dist/ui/font-color-toolbar-button.d.ts +15 -0
- package/dist/ui/frame-node-static.d.ts +3 -0
- package/dist/ui/frame-node.d.ts +3 -0
- package/dist/ui/frame-settings.d.ts +19 -0
- package/dist/ui/ghost-text.d.ts +1 -0
- package/dist/ui/heading-node-static.d.ts +10 -0
- package/dist/ui/heading-node.d.ts +14 -0
- package/dist/ui/highlight-node-static.d.ts +2 -0
- package/dist/ui/highlight-node.d.ts +2 -0
- package/dist/ui/hover-card.d.ts +6 -0
- package/dist/ui/hr-node-static.d.ts +2 -0
- package/dist/ui/hr-node.d.ts +2 -0
- package/dist/ui/icon-node-static.d.ts +3 -0
- package/dist/ui/icon-node.d.ts +3 -0
- package/dist/ui/icon-picker.d.ts +16 -0
- package/dist/ui/icon-settings.d.ts +17 -0
- package/dist/ui/inline-combobox.d.ts +38 -0
- package/dist/ui/input.d.ts +7 -0
- package/dist/ui/kbd-node-static.d.ts +2 -0
- package/dist/ui/kbd-node.d.ts +2 -0
- package/dist/ui/label.d.ts +8 -0
- package/dist/ui/link-node-static.d.ts +11 -0
- package/dist/ui/link-node.d.ts +11 -0
- package/dist/ui/link-reference.d.ts +39 -0
- package/dist/ui/link-reference.js +84 -0
- package/dist/ui/link-search-panel.d.ts +5 -0
- package/dist/ui/link-toolbar-button.d.ts +3 -0
- package/dist/ui/link-toolbar-edit-command.d.ts +7 -0
- package/dist/ui/link-toolbar-shared.d.ts +18 -0
- package/dist/ui/link-toolbar.d.ts +1 -0
- package/dist/ui/mark-toolbar-button.d.ts +6 -0
- package/dist/ui/media-align-button.d.ts +5 -0
- package/dist/ui/media-audio-node-static.d.ts +3 -0
- package/dist/ui/media-audio-node.d.ts +2 -0
- package/dist/ui/media-card.d.ts +11 -0
- package/dist/ui/media-embed-node-static.d.ts +6 -0
- package/dist/ui/media-embed-node.d.ts +2 -0
- package/dist/ui/media-file-display.d.ts +11 -0
- package/dist/ui/media-file-mode-dropdown.d.ts +10 -0
- package/dist/ui/media-file-node-static.d.ts +3 -0
- package/dist/ui/media-file-node.d.ts +2 -0
- package/dist/ui/media-hint-icon-picker.d.ts +5 -0
- package/dist/ui/media-hint-settings.d.ts +2 -0
- package/dist/ui/media-image-lightbox.d.ts +17 -0
- package/dist/ui/media-image-node-static.d.ts +6 -0
- package/dist/ui/media-image-node.d.ts +7 -0
- package/dist/ui/media-placeholder-node.d.ts +3 -0
- package/dist/ui/media-preview-dialog.d.ts +12 -0
- package/dist/ui/media-toolbar.d.ts +3 -0
- package/dist/ui/media-upload-toast.d.ts +1 -0
- package/dist/ui/media-video-node-static.d.ts +6 -0
- package/dist/ui/media-video-node.d.ts +2 -0
- package/dist/ui/member-profile-card.d.ts +17 -0
- package/dist/ui/mention-document-element.d.ts +5 -0
- package/dist/ui/mention-document-hover-card.d.ts +17 -0
- package/dist/ui/mention-document-link.d.ts +13 -0
- package/dist/ui/mention-element.d.ts +5 -0
- package/dist/ui/mention-input-element.d.ts +2 -0
- package/dist/ui/mention-node-static.d.ts +7 -0
- package/dist/ui/mention-page-combobox-group.d.ts +8 -0
- package/dist/ui/mention-people-combobox-group.d.ts +8 -0
- package/dist/ui/menu.d.ts +103 -0
- package/dist/ui/mermaid-node-static.d.ts +4 -0
- package/dist/ui/mermaid-node.d.ts +3 -0
- package/dist/ui/more-toolbar-button.d.ts +3 -0
- package/dist/ui/paragraph-node-static.d.ts +2 -0
- package/dist/ui/paragraph-node.d.ts +2 -0
- package/dist/ui/popover.d.ts +11 -0
- package/dist/ui/progress.d.ts +3 -0
- package/dist/ui/resize-handle.d.ts +15 -0
- package/dist/ui/select.d.ts +13 -0
- package/dist/ui/separator.d.ts +8 -0
- package/dist/ui/slash-node.d.ts +20 -0
- package/dist/ui/smart-link-clipboard.d.ts +1 -0
- package/dist/ui/smart-link-copy-button.d.ts +6 -0
- package/dist/ui/smart-link-mode-dropdown.d.ts +9 -0
- package/dist/ui/smart-link-toolbar.d.ts +17 -0
- package/dist/ui/smart-link-view.d.ts +23 -0
- package/dist/ui/smart-link.d.ts +43 -0
- package/dist/ui/spinner.d.ts +7 -0
- package/dist/ui/step-node-static.d.ts +3 -0
- package/dist/ui/step-node.d.ts +3 -0
- package/dist/ui/step-settings.d.ts +19 -0
- package/dist/ui/steps-node-static.d.ts +10 -0
- package/dist/ui/steps-node.d.ts +10 -0
- package/dist/ui/suggestion-node-static.d.ts +3 -0
- package/dist/ui/suggestion-node.d.ts +6 -0
- package/dist/ui/suggestion-toolbar-button.d.ts +1 -0
- package/dist/ui/switch.d.ts +4 -0
- package/dist/ui/tabbed-code-block-actions.d.ts +24 -0
- package/dist/ui/tabbed-code-block-header.d.ts +23 -0
- package/dist/ui/tabbed-code-block-language-selector.d.ts +7 -0
- package/dist/ui/tabbed-code-block-languages.d.ts +6 -0
- package/dist/ui/tabbed-code-block-node-static.d.ts +4 -0
- package/dist/ui/tabbed-code-block-node.d.ts +4 -0
- package/dist/ui/tabbed-code-block-settings.d.ts +18 -0
- package/dist/ui/tabbed-code-block-sync.d.ts +10 -0
- package/dist/ui/tabbed-code-block-tab-dropdown.d.ts +10 -0
- package/dist/ui/tabbed-code-block-tab-strip.d.ts +27 -0
- package/dist/ui/tabbed-code-block-tab-trigger.d.ts +14 -0
- package/dist/ui/tabbed-code-block-utils.d.ts +9 -0
- package/dist/ui/table-icons.d.ts +7 -0
- package/dist/ui/table-node-static.d.ts +9 -0
- package/dist/ui/table-node.d.ts +9 -0
- package/dist/ui/tabs-node-static.d.ts +4 -0
- package/dist/ui/tabs-node.d.ts +3 -0
- package/dist/ui/tabs.d.ts +10 -0
- package/dist/ui/textarea.d.ts +10 -0
- package/dist/ui/tile-node-static.d.ts +3 -0
- package/dist/ui/tile-node.d.ts +3 -0
- package/dist/ui/tile-settings.d.ts +18 -0
- package/dist/ui/tiles-node-static.d.ts +3 -0
- package/dist/ui/tiles-node.d.ts +3 -0
- package/dist/ui/toc-node-static.d.ts +2 -0
- package/dist/ui/toc-node.d.ts +2 -0
- package/dist/ui/toc-sidebar.d.ts +6 -0
- package/dist/ui/toc-state-sync.d.ts +5 -0
- package/dist/ui/toggle-node-static.d.ts +3 -0
- package/dist/ui/toggle-node-views.d.ts +35 -0
- package/dist/ui/toggle-node.d.ts +3 -0
- package/dist/ui/toggle-settings.d.ts +23 -0
- package/dist/ui/toggle.d.ts +8 -0
- package/dist/ui/toolbar.d.ts +37 -0
- package/dist/ui/tooltip-node-static.d.ts +3 -0
- package/dist/ui/tooltip-node.d.ts +3 -0
- package/dist/ui/tooltip-preview-content.d.ts +6 -0
- package/dist/ui/tooltip-settings.d.ts +21 -0
- package/dist/ui/tooltip-toolbar-button.d.ts +3 -0
- package/dist/ui/tooltip.d.ts +19 -0
- package/dist/ui/tree-context-value.d.ts +22 -0
- package/dist/ui/tree-context.d.ts +32 -0
- package/dist/ui/tree-file-node-static.d.ts +8 -0
- package/dist/ui/tree-file-node.d.ts +11 -0
- package/dist/ui/tree-folder-node-static.d.ts +9 -0
- package/dist/ui/tree-folder-node.d.ts +12 -0
- package/dist/ui/tree-item-utils.d.ts +11 -0
- package/dist/ui/tree-items-list.d.ts +11 -0
- package/dist/ui/tree-node-events.d.ts +19 -0
- package/dist/ui/tree-node-state.d.ts +14 -0
- package/dist/ui/tree-node-static.d.ts +12 -0
- package/dist/ui/tree-node.d.ts +5 -0
- package/dist/ui/tree-root-actions.d.ts +11 -0
- package/dist/ui/tree-settings.d.ts +18 -0
- package/dist/ui/turn-into-toolbar-button.d.ts +129 -0
- package/dist/ui/update-display-tags.d.ts +5 -0
- package/dist/ui/update-node-static.d.ts +2 -0
- package/dist/ui/update-node.d.ts +3 -0
- package/dist/ui/update-rss-settings.d.ts +9 -0
- package/dist/ui/update-settings.d.ts +21 -0
- package/dist/ui/update-tags-settings.d.ts +8 -0
- package/dist/ui/updates-node-static.d.ts +2 -0
- package/dist/ui/updates-node.d.ts +2 -0
- package/dist/ui/use-member-profile.d.ts +22 -0
- package/dist/ui/use-placeholder-max-file-size.d.ts +3 -0
- package/dist/vendor/slate-yjs-core.d.ts +1 -0
- package/dist/vendor/slate-yjs-core.js +2 -0
- package/dist/vendor/y-protocols-awareness.d.ts +1 -0
- package/dist/vendor/y-protocols-awareness.js +2 -0
- package/dist/vendor/yjs.d.ts +1 -0
- package/dist/vendor/yjs.js +2 -0
- package/package.json +255 -4
|
@@ -0,0 +1,161 @@
|
|
|
1
|
+
import type { Value } from 'platejs';
|
|
2
|
+
import type { PlateEditor } from 'platejs/react';
|
|
3
|
+
import type { EditorAdapter, LinkMetadata, PagePreview } from '../context/editor-adapter';
|
|
4
|
+
import type { UploadedFile, UploadFunction } from '../hooks/use-upload-file';
|
|
5
|
+
export type { Value, PlateEditor };
|
|
6
|
+
export interface AIConfig {
|
|
7
|
+
enabled: boolean;
|
|
8
|
+
apiEndpoint?: string;
|
|
9
|
+
model?: string;
|
|
10
|
+
headers?: Record<string, string>;
|
|
11
|
+
systemPrompt?: string;
|
|
12
|
+
onError?: (error: Error) => void;
|
|
13
|
+
}
|
|
14
|
+
export interface UploadConfig {
|
|
15
|
+
uploadFn?: UploadFunction;
|
|
16
|
+
maxFileSize?: number;
|
|
17
|
+
acceptedFileTypes?: string[];
|
|
18
|
+
onUploadStart?: (file: File) => void;
|
|
19
|
+
onUploadComplete?: (file: UploadedFile) => void;
|
|
20
|
+
onUploadError?: (error: unknown) => void;
|
|
21
|
+
}
|
|
22
|
+
export declare const MarkShortcuts: readonly ["bold", "italic", "underline", "code", "strikethrough", "subscript", "superscript"];
|
|
23
|
+
export type MarkShortcut = (typeof MarkShortcuts)[number];
|
|
24
|
+
export interface EditorFeatures {
|
|
25
|
+
ai?: boolean;
|
|
26
|
+
copilot?: boolean;
|
|
27
|
+
comments?: boolean;
|
|
28
|
+
suggestions?: boolean;
|
|
29
|
+
toc?: boolean;
|
|
30
|
+
emoji?: boolean;
|
|
31
|
+
mentions?: boolean;
|
|
32
|
+
slashCommands?: boolean;
|
|
33
|
+
codeBlock?: boolean;
|
|
34
|
+
tabbedCodeBlock?: boolean;
|
|
35
|
+
callout?: boolean;
|
|
36
|
+
media?: boolean;
|
|
37
|
+
tables?: boolean;
|
|
38
|
+
toggles?: boolean;
|
|
39
|
+
tabs?: boolean;
|
|
40
|
+
accordionGroup?: boolean;
|
|
41
|
+
cards?: boolean;
|
|
42
|
+
steps?: boolean;
|
|
43
|
+
badge?: boolean;
|
|
44
|
+
frame?: boolean;
|
|
45
|
+
tiles?: boolean;
|
|
46
|
+
banner?: boolean;
|
|
47
|
+
icon?: boolean;
|
|
48
|
+
mermaid?: boolean;
|
|
49
|
+
tree?: boolean;
|
|
50
|
+
color?: boolean;
|
|
51
|
+
equations?: boolean;
|
|
52
|
+
dates?: boolean;
|
|
53
|
+
columns?: boolean;
|
|
54
|
+
links?: boolean;
|
|
55
|
+
/**
|
|
56
|
+
* Shows every link as an ordinary underlined text link on the text baseline, the way a published page shows it,
|
|
57
|
+
* in place of the smart link chip, URL, and card views. Leave it off to keep smart links.
|
|
58
|
+
*/
|
|
59
|
+
plainLinks?: boolean;
|
|
60
|
+
lists?: boolean;
|
|
61
|
+
/**
|
|
62
|
+
* Lets writers create to-do lists, the checklists with a checkbox on each item, next to bulleted and numbered
|
|
63
|
+
* lists. With `todoLists: false`, the slash menu, the turn-into menus, and the `[] ` shortcut offer no to-do list,
|
|
64
|
+
* and a to-do item that arrives through a paste or loaded HTML or markdown becomes a bulleted list item. It has no
|
|
65
|
+
* effect when `lists` is off.
|
|
66
|
+
*/
|
|
67
|
+
todoLists?: boolean;
|
|
68
|
+
textSubstitutions?: boolean;
|
|
69
|
+
markShortcuts?: readonly MarkShortcut[];
|
|
70
|
+
dnd?: boolean;
|
|
71
|
+
insertHandle?: boolean;
|
|
72
|
+
blockMenu?: boolean;
|
|
73
|
+
floatingToolbar?: boolean;
|
|
74
|
+
apiDocMode?: boolean;
|
|
75
|
+
tooltip?: boolean;
|
|
76
|
+
updates?: boolean;
|
|
77
|
+
}
|
|
78
|
+
export interface ToolbarItem {
|
|
79
|
+
type: string;
|
|
80
|
+
icon?: string;
|
|
81
|
+
label?: string;
|
|
82
|
+
}
|
|
83
|
+
export interface ToolbarConfig {
|
|
84
|
+
floating?: boolean;
|
|
85
|
+
items?: ToolbarItem[];
|
|
86
|
+
}
|
|
87
|
+
export interface MentionUser {
|
|
88
|
+
id: string;
|
|
89
|
+
name: string;
|
|
90
|
+
avatar?: string;
|
|
91
|
+
email?: string;
|
|
92
|
+
}
|
|
93
|
+
export interface MentionConfig {
|
|
94
|
+
users?: MentionUser[];
|
|
95
|
+
onSearch?: (query: string) => Promise<MentionUser[]>;
|
|
96
|
+
onSelect?: (user: MentionUser) => void;
|
|
97
|
+
}
|
|
98
|
+
export interface TocConfig {
|
|
99
|
+
topOffset?: number;
|
|
100
|
+
className?: string;
|
|
101
|
+
maxShowCount?: number;
|
|
102
|
+
}
|
|
103
|
+
export type EditorVariant = 'default' | 'demo' | 'fullWidth' | 'versionHistory' | 'comment' | 'select' | 'ai' | 'aiChat' | 'update' | 'viewer';
|
|
104
|
+
export declare const EditorThemes: readonly ["editor", "inherit"];
|
|
105
|
+
export type EditorTheme = (typeof EditorThemes)[number];
|
|
106
|
+
export interface WebEditorProps {
|
|
107
|
+
initialValue?: Value;
|
|
108
|
+
onChange?: (value: Value) => void;
|
|
109
|
+
onValueChange?: (value: Value, editor: PlateEditor) => void;
|
|
110
|
+
readOnly?: boolean;
|
|
111
|
+
adapter?: EditorAdapter;
|
|
112
|
+
/**
|
|
113
|
+
* Server-resolved external link card metadata keyed by url. Pre-populates the
|
|
114
|
+
* link resolver so the cards render in server HTML with no client fetch. Plain
|
|
115
|
+
* serializable data, passed straight from a server component.
|
|
116
|
+
*/
|
|
117
|
+
linkPreviewSeed?: LinkMetadata[];
|
|
118
|
+
/**
|
|
119
|
+
* Server-resolved internal page previews keyed by their reference. Seeded
|
|
120
|
+
* references render as real anchors in server HTML with no client fetch;
|
|
121
|
+
* references missing from the seed stay inert until live resolution (if the
|
|
122
|
+
* surface provides any) fills them in.
|
|
123
|
+
*/
|
|
124
|
+
pageReferenceSeed?: PagePreview[];
|
|
125
|
+
linkResolutionKey?: string;
|
|
126
|
+
ai?: AIConfig;
|
|
127
|
+
upload?: UploadConfig;
|
|
128
|
+
mentions?: MentionConfig;
|
|
129
|
+
features?: EditorFeatures;
|
|
130
|
+
toolbar?: ToolbarConfig;
|
|
131
|
+
toc?: TocConfig;
|
|
132
|
+
onFocus?: () => void;
|
|
133
|
+
onBlur?: () => void;
|
|
134
|
+
onEditorReady?: (editor: PlateEditor) => void;
|
|
135
|
+
className?: string;
|
|
136
|
+
containerClassName?: string;
|
|
137
|
+
editorClassName?: string;
|
|
138
|
+
placeholder?: string;
|
|
139
|
+
autoFocus?: boolean;
|
|
140
|
+
showToc?: boolean;
|
|
141
|
+
variant?: EditorVariant;
|
|
142
|
+
/**
|
|
143
|
+
* Chooses whose color tokens the editor and its menus use. 'editor', the default, applies the editor's own palette.
|
|
144
|
+
* 'inherit' applies the host page's shadcn tokens of the same names, such as --primary, --background, and their
|
|
145
|
+
* dark mode values, so the editor matches the app around it.
|
|
146
|
+
*/
|
|
147
|
+
theme?: EditorTheme;
|
|
148
|
+
}
|
|
149
|
+
export interface EditorConfig {
|
|
150
|
+
ai: AIConfig;
|
|
151
|
+
upload: UploadConfig;
|
|
152
|
+
mentions: MentionConfig;
|
|
153
|
+
features: EditorFeatures;
|
|
154
|
+
toolbar: ToolbarConfig;
|
|
155
|
+
readOnly: boolean;
|
|
156
|
+
}
|
|
157
|
+
export declare const DEFAULT_FEATURES: EditorFeatures;
|
|
158
|
+
export declare const DEFAULT_AI_CONFIG: AIConfig;
|
|
159
|
+
export declare const DEFAULT_UPLOAD_CONFIG: UploadConfig;
|
|
160
|
+
export declare const DEFAULT_MENTIONS_CONFIG: MentionConfig;
|
|
161
|
+
export declare const DEFAULT_TOOLBAR_CONFIG: ToolbarConfig;
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
// src/types/editor.ts
|
|
4
|
+
var MarkShortcuts = [
|
|
5
|
+
"bold",
|
|
6
|
+
"italic",
|
|
7
|
+
"underline",
|
|
8
|
+
"code",
|
|
9
|
+
"strikethrough",
|
|
10
|
+
"subscript",
|
|
11
|
+
"superscript"
|
|
12
|
+
];
|
|
13
|
+
var EditorThemes = ["editor", "inherit"];
|
|
14
|
+
var DEFAULT_FEATURES = {
|
|
15
|
+
ai: true,
|
|
16
|
+
copilot: true,
|
|
17
|
+
comments: true,
|
|
18
|
+
suggestions: true,
|
|
19
|
+
toc: true,
|
|
20
|
+
emoji: true,
|
|
21
|
+
mentions: true,
|
|
22
|
+
slashCommands: true,
|
|
23
|
+
codeBlock: true,
|
|
24
|
+
tabbedCodeBlock: true,
|
|
25
|
+
callout: true,
|
|
26
|
+
media: true,
|
|
27
|
+
tables: true,
|
|
28
|
+
toggles: true,
|
|
29
|
+
tabs: true,
|
|
30
|
+
accordionGroup: true,
|
|
31
|
+
cards: true,
|
|
32
|
+
steps: true,
|
|
33
|
+
badge: true,
|
|
34
|
+
frame: true,
|
|
35
|
+
tiles: true,
|
|
36
|
+
banner: true,
|
|
37
|
+
icon: true,
|
|
38
|
+
mermaid: true,
|
|
39
|
+
tree: true,
|
|
40
|
+
color: true,
|
|
41
|
+
equations: true,
|
|
42
|
+
dates: true,
|
|
43
|
+
columns: true,
|
|
44
|
+
links: true,
|
|
45
|
+
plainLinks: false,
|
|
46
|
+
lists: true,
|
|
47
|
+
todoLists: true,
|
|
48
|
+
textSubstitutions: true,
|
|
49
|
+
markShortcuts: MarkShortcuts,
|
|
50
|
+
dnd: true,
|
|
51
|
+
insertHandle: true,
|
|
52
|
+
blockMenu: true,
|
|
53
|
+
floatingToolbar: true,
|
|
54
|
+
apiDocMode: false,
|
|
55
|
+
tooltip: true,
|
|
56
|
+
updates: true
|
|
57
|
+
};
|
|
58
|
+
var DEFAULT_AI_CONFIG = {
|
|
59
|
+
enabled: false,
|
|
60
|
+
apiEndpoint: "/api/ai/command"
|
|
61
|
+
};
|
|
62
|
+
var DEFAULT_UPLOAD_CONFIG = {};
|
|
63
|
+
var DEFAULT_MENTIONS_CONFIG = {
|
|
64
|
+
users: []
|
|
65
|
+
};
|
|
66
|
+
var DEFAULT_TOOLBAR_CONFIG = {
|
|
67
|
+
floating: true
|
|
68
|
+
};
|
|
69
|
+
export {
|
|
70
|
+
DEFAULT_AI_CONFIG,
|
|
71
|
+
DEFAULT_FEATURES,
|
|
72
|
+
DEFAULT_MENTIONS_CONFIG,
|
|
73
|
+
DEFAULT_TOOLBAR_CONFIG,
|
|
74
|
+
DEFAULT_UPLOAD_CONFIG,
|
|
75
|
+
EditorThemes,
|
|
76
|
+
MarkShortcuts
|
|
77
|
+
};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { type SlateElementProps } from 'platejs/static';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
import type { TAccordionGroupElement } from '../components/editor/plugins/accordion-types';
|
|
4
|
+
interface AccordionGroupContextValue {
|
|
5
|
+
allowMultiple: boolean;
|
|
6
|
+
openIds: Set<string>;
|
|
7
|
+
toggleItem: (id: string) => void;
|
|
8
|
+
}
|
|
9
|
+
export declare const useAccordionGroupStatic: () => AccordionGroupContextValue | null;
|
|
10
|
+
export declare function AccordionGroupElementStatic(props: SlateElementProps<TAccordionGroupElement>): React.JSX.Element;
|
|
11
|
+
export {};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { type PlateElementProps } from 'platejs/react';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
interface AccordionGroupContextValue {
|
|
4
|
+
allowMultiple: boolean;
|
|
5
|
+
openIds: Set<string>;
|
|
6
|
+
toggleItem: (id: string) => void;
|
|
7
|
+
}
|
|
8
|
+
export declare const useAccordionGroup: () => AccordionGroupContextValue | null;
|
|
9
|
+
export declare function AccordionGroupElement(props: PlateElementProps): React.JSX.Element;
|
|
10
|
+
export {};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import * as AlertDialogPrimitive from '@radix-ui/react-alert-dialog';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
declare const AlertDialog: React.FC<AlertDialogPrimitive.AlertDialogProps>;
|
|
4
|
+
declare const AlertDialogTrigger: React.ForwardRefExoticComponent<AlertDialogPrimitive.AlertDialogTriggerProps & React.RefAttributes<HTMLButtonElement>>;
|
|
5
|
+
declare function AlertDialogPortal(props: React.ComponentProps<typeof AlertDialogPrimitive.Portal>): React.JSX.Element;
|
|
6
|
+
declare const AlertDialogOverlay: React.ForwardRefExoticComponent<Omit<AlertDialogPrimitive.AlertDialogOverlayProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
7
|
+
declare const AlertDialogContent: React.ForwardRefExoticComponent<Omit<AlertDialogPrimitive.AlertDialogContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
8
|
+
declare const AlertDialogHeader: {
|
|
9
|
+
({ className, ...props }: React.HTMLAttributes<HTMLDivElement>): React.JSX.Element;
|
|
10
|
+
displayName: string;
|
|
11
|
+
};
|
|
12
|
+
declare const AlertDialogFooter: {
|
|
13
|
+
({ className, ...props }: React.HTMLAttributes<HTMLDivElement>): React.JSX.Element;
|
|
14
|
+
displayName: string;
|
|
15
|
+
};
|
|
16
|
+
declare const AlertDialogTitle: React.ForwardRefExoticComponent<Omit<AlertDialogPrimitive.AlertDialogTitleProps & React.RefAttributes<HTMLHeadingElement>, "ref"> & React.RefAttributes<HTMLHeadingElement>>;
|
|
17
|
+
declare const AlertDialogDescription: React.ForwardRefExoticComponent<Omit<AlertDialogPrimitive.AlertDialogDescriptionProps & React.RefAttributes<HTMLParagraphElement>, "ref"> & React.RefAttributes<HTMLParagraphElement>>;
|
|
18
|
+
declare const AlertDialogAction: React.ForwardRefExoticComponent<Omit<AlertDialogPrimitive.AlertDialogActionProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
19
|
+
declare const AlertDialogCancel: React.ForwardRefExoticComponent<Omit<AlertDialogPrimitive.AlertDialogCancelProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
20
|
+
export { AlertDialog, AlertDialogPortal, AlertDialogOverlay, AlertDialogTrigger, AlertDialogContent, AlertDialogHeader, AlertDialogFooter, AlertDialogTitle, AlertDialogDescription, AlertDialogAction, AlertDialogCancel, };
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { type SlateElementProps } from 'platejs/static';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
import type { TExpandableElement } from '../../components/editor/plugins/api-doc/expandable-types';
|
|
4
|
+
export declare function ExpandableElementStatic(props: SlateElementProps<TExpandableElement>): React.JSX.Element;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import type { TExpandableElement } from '../../components/editor/plugins/api-doc/expandable-types';
|
|
3
|
+
interface ExpandableSettingsButtonProps {
|
|
4
|
+
onClick?: () => void;
|
|
5
|
+
}
|
|
6
|
+
export declare function ExpandableSettingsButton({ onClick }: ExpandableSettingsButtonProps): React.JSX.Element;
|
|
7
|
+
type ExpandableSettingsPanelProps = Omit<ExpandableSettingsFormProps, 'layout'>;
|
|
8
|
+
export declare function ExpandableSettingsPanel(props: ExpandableSettingsPanelProps): React.JSX.Element;
|
|
9
|
+
type ExpandableSettingsPopoverProps = Omit<ExpandableSettingsFormProps, 'layout' | 'onClose'>;
|
|
10
|
+
export declare function ExpandableSettingsPopover(props: ExpandableSettingsPopoverProps): React.JSX.Element;
|
|
11
|
+
interface ExpandableSettingsFormProps {
|
|
12
|
+
initialTitle: string;
|
|
13
|
+
updateElement: (updates: Partial<TExpandableElement>) => void;
|
|
14
|
+
layout?: 'panel' | 'popover';
|
|
15
|
+
onClose?: () => void;
|
|
16
|
+
}
|
|
17
|
+
export {};
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import { type SlateElementProps } from 'platejs/static';
|
|
2
|
+
import type { TResponseFieldItemElement } from '../../components/editor/plugins/api-doc/response-field-types';
|
|
3
|
+
export declare function ResponseFieldItemElementStatic(props: SlateElementProps<TResponseFieldItemElement>): import("react").JSX.Element;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { type SlateElementProps } from 'platejs/static';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
import type { TResponseFieldElement } from '../../components/editor/plugins/api-doc/response-field-types';
|
|
4
|
+
interface ResponseFieldContextValue {
|
|
5
|
+
element: TResponseFieldElement;
|
|
6
|
+
}
|
|
7
|
+
export declare const useResponseFieldContextStatic: () => ResponseFieldContextValue | null;
|
|
8
|
+
export declare function ResponseFieldElementStatic(props: SlateElementProps<TResponseFieldElement>): React.JSX.Element;
|
|
9
|
+
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { type PlateElementProps } from 'platejs/react';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
import type { TResponseFieldElement } from '../../components/editor/plugins/api-doc/response-field-types';
|
|
4
|
+
interface ResponseFieldContextValue {
|
|
5
|
+
element: TResponseFieldElement;
|
|
6
|
+
}
|
|
7
|
+
export declare const useResponseFieldContext: () => ResponseFieldContextValue | null;
|
|
8
|
+
export declare function ResponseFieldElement(props: PlateElementProps): React.JSX.Element;
|
|
9
|
+
export {};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { VariantProps } from 'class-variance-authority';
|
|
2
|
+
import { Avatar as AvatarPrimitive } from 'radix-ui';
|
|
3
|
+
import type * as React from 'react';
|
|
4
|
+
declare const avatarVariants: (props?: ({
|
|
5
|
+
size?: "default" | "lg" | "profile" | "settings" | "sm" | null | undefined;
|
|
6
|
+
variant?: "default" | null | undefined;
|
|
7
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
8
|
+
type AvatarProps = React.ComponentProps<typeof AvatarPrimitive.Root> & VariantProps<typeof avatarVariants>;
|
|
9
|
+
declare function Avatar({ className, size, variant, ...props }: AvatarProps): React.JSX.Element;
|
|
10
|
+
declare function AvatarImage({ className, onLoadingStatusChange, ...props }: React.ComponentProps<typeof AvatarPrimitive.Image> & Pick<AvatarPrimitive.AvatarImageProps, 'onLoadingStatusChange'>): React.JSX.Element;
|
|
11
|
+
declare const avatarFallbackVariants: (props?: ({
|
|
12
|
+
variant?: "default" | null | undefined;
|
|
13
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
14
|
+
type AvatarFallbackProps = React.ComponentProps<typeof AvatarPrimitive.Fallback> & VariantProps<typeof avatarFallbackVariants>;
|
|
15
|
+
declare function AvatarFallback({ className, variant, ...props }: AvatarFallbackProps): React.JSX.Element;
|
|
16
|
+
export { Avatar, AvatarFallback, AvatarImage };
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { type BadgeColor, type BadgeShape, type BadgeSize, type TBadgeElement } from '../components/editor/plugins/badge-types';
|
|
3
|
+
interface BadgeColorButtonProps {
|
|
4
|
+
color: BadgeColor;
|
|
5
|
+
selected: boolean;
|
|
6
|
+
setColor: React.Dispatch<React.SetStateAction<BadgeColor>>;
|
|
7
|
+
updateElement: (updates: Partial<TBadgeElement>) => void;
|
|
8
|
+
}
|
|
9
|
+
export declare function BadgeColorButton({ color, selected, setColor, updateElement }: BadgeColorButtonProps): React.JSX.Element;
|
|
10
|
+
interface BadgeSizeButtonProps {
|
|
11
|
+
size: BadgeSize;
|
|
12
|
+
selected: boolean;
|
|
13
|
+
setSize: React.Dispatch<React.SetStateAction<BadgeSize>>;
|
|
14
|
+
updateElement: (updates: Partial<TBadgeElement>) => void;
|
|
15
|
+
}
|
|
16
|
+
export declare function BadgeSizeButton({ size, selected, setSize, updateElement }: BadgeSizeButtonProps): React.JSX.Element;
|
|
17
|
+
interface BadgeShapeButtonProps {
|
|
18
|
+
shape: BadgeShape;
|
|
19
|
+
selected: boolean;
|
|
20
|
+
setShape: React.Dispatch<React.SetStateAction<BadgeShape>>;
|
|
21
|
+
updateElement: (updates: Partial<TBadgeElement>) => void;
|
|
22
|
+
}
|
|
23
|
+
export declare function BadgeShapeButton({ shape, selected, setShape, updateElement }: BadgeShapeButtonProps): React.JSX.Element;
|
|
24
|
+
export {};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import type { IconName } from 'lucide-react/dynamic';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
import { type BadgeColor, type BadgeShape, type BadgeSize, type TBadgeElement } from '../components/editor/plugins/badge-types';
|
|
4
|
+
type BadgeSettingsPanelProps = Omit<BadgeSettingsFormProps, 'layout'>;
|
|
5
|
+
export declare function BadgeSettingsPanel(props: BadgeSettingsPanelProps): React.JSX.Element;
|
|
6
|
+
type BadgeSettingsPopoverProps = Omit<BadgeSettingsFormProps, 'layout'> & {
|
|
7
|
+
children: React.ReactNode;
|
|
8
|
+
};
|
|
9
|
+
export declare function BadgeSettingsPopover({ children, ...props }: BadgeSettingsPopoverProps): React.JSX.Element;
|
|
10
|
+
interface BadgeSettingsFormProps {
|
|
11
|
+
initialColor: BadgeColor;
|
|
12
|
+
initialSize: BadgeSize;
|
|
13
|
+
initialShape: BadgeShape;
|
|
14
|
+
initialStroke: boolean;
|
|
15
|
+
initialIcon: IconName | undefined;
|
|
16
|
+
updateElement: (updates: Partial<TBadgeElement>) => void;
|
|
17
|
+
layout?: 'popover' | 'panel';
|
|
18
|
+
}
|
|
19
|
+
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { type VariantProps } from 'class-variance-authority';
|
|
2
|
+
import type * as React from 'react';
|
|
3
|
+
declare const badgeVariants: (props?: ({
|
|
4
|
+
variant?: "default" | "outline" | "destructive" | "secondary" | null | undefined;
|
|
5
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
6
|
+
export interface BadgeProps extends React.HTMLAttributes<HTMLSpanElement>, VariantProps<typeof badgeVariants> {
|
|
7
|
+
}
|
|
8
|
+
declare function Badge({ className, variant, ...props }: BadgeProps): React.JSX.Element;
|
|
9
|
+
export { Badge, badgeVariants };
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { type SlateElementProps } from 'platejs/static';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
import { type TBannerElement } from '../components/editor/plugins/banner-types';
|
|
4
|
+
export declare function BannerElementStatic(props: SlateElementProps<TBannerElement>): React.JSX.Element | null;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type * as React from 'react';
|
|
2
|
+
import { type ButtonProps } from './button';
|
|
3
|
+
export declare function BlockContextMenu({ children }: {
|
|
4
|
+
children: React.ReactNode;
|
|
5
|
+
}): string | number | bigint | boolean | Iterable<React.ReactNode> | Promise<string | number | bigint | boolean | React.ReactPortal | React.ReactElement<unknown, string | React.JSXElementConstructor<any>> | Iterable<React.ReactNode> | null | undefined> | React.JSX.Element | null | undefined;
|
|
6
|
+
export declare function BlockActionButton({ className, defaultStyles, ...props }: Partial<ButtonProps> & {
|
|
7
|
+
defaultStyles?: boolean;
|
|
8
|
+
}): React.JSX.Element;
|