@nextblock-cms/editor 0.2.15 → 0.2.16
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/index.css +1 -0
- package/{index.cjs → index.js} +110 -110
- package/index.mjs +23 -17
- package/package.json +4 -81
- package/index.d.ts +0 -29
- package/lib/NotionEditor.d.ts +0 -16
- package/lib/components/DragHandle.d.ts +0 -15
- package/lib/components/HtmlContent.d.ts +0 -7
- package/lib/components/menus/BubbleMenu.d.ts +0 -7
- package/lib/components/menus/EnhancedFloatingMenu.d.ts +0 -8
- package/lib/components/menus/FloatingMenu.d.ts +0 -7
- package/lib/components/menus/ImageToolbar.d.ts +0 -7
- package/lib/components/menus/SlashCommandList.d.ts +0 -13
- package/lib/components/menus/TableToolbar.d.ts +0 -7
- package/lib/components/menus/Toolbar.d.ts +0 -7
- package/lib/components/mobile/MobileToolbar.d.ts +0 -8
- package/lib/components/test/FeatureValidationTest.d.ts +0 -3
- package/lib/components/test/NotionEditorEnhancedTest.d.ts +0 -11
- package/lib/components/test/UndoRedoTest.d.ts +0 -15
- package/lib/components/ui/AdvancedColorMenu.d.ts +0 -9
- package/lib/components/ui/AdvancedFontSizeMenu.d.ts +0 -7
- package/lib/components/ui/Toolbar.d.ts +0 -7
- package/lib/components/ui/UndoRedoButtons.d.ts +0 -10
- package/lib/components/widgets/AlertWidgetComponent.d.ts +0 -3
- package/lib/components/widgets/CtaWidgetComponent.d.ts +0 -3
- package/lib/editor.d.ts +0 -19
- package/lib/extensions/AdvancedPlaceholder.d.ts +0 -3
- package/lib/extensions/AlertWidget.d.ts +0 -18
- package/lib/extensions/CtaWidgetNode.d.ts +0 -16
- package/lib/extensions/DivNode.d.ts +0 -2
- package/lib/extensions/DraggableNodes.d.ts +0 -11
- package/lib/extensions/EnhancedFocus.d.ts +0 -10
- package/lib/extensions/FontSizeMark.d.ts +0 -13
- package/lib/extensions/ImageExtended.d.ts +0 -2
- package/lib/extensions/KeyboardShortcuts.d.ts +0 -7
- package/lib/extensions/PreserveAllAttributesExtension.d.ts +0 -2
- package/lib/extensions/ResizableImageView.d.ts +0 -2
- package/lib/extensions/ScriptTagNode.d.ts +0 -2
- package/lib/extensions/StyleTagNode.d.ts +0 -2
- package/lib/extensions/TrailingNode.d.ts +0 -9
- package/lib/extensions/components/AlertWidgetComponent.d.ts +0 -3
- package/lib/extensions/components/CtaWidgetComponent.d.ts +0 -3
- package/lib/extensions/slash-command.d.ts +0 -17
- package/lib/hooks/useEditorHistory.d.ts +0 -30
- package/lib/kit.d.ts +0 -2
- package/lib/utils/formatHTML.d.ts +0 -2
- package/lib/utils/mediaPicker.d.ts +0 -11
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
import { Editor } from '@tiptap/core';
|
|
2
|
-
export interface EditorHistoryState {
|
|
3
|
-
canUndo: boolean;
|
|
4
|
-
canRedo: boolean;
|
|
5
|
-
historyDepth: number;
|
|
6
|
-
isHistoryEmpty: boolean;
|
|
7
|
-
}
|
|
8
|
-
export interface EditorHistoryActions {
|
|
9
|
-
undo: () => boolean;
|
|
10
|
-
redo: () => boolean;
|
|
11
|
-
clearHistory: () => void;
|
|
12
|
-
getHistoryState: () => EditorHistoryState;
|
|
13
|
-
}
|
|
14
|
-
/**
|
|
15
|
-
* Custom hook for managing Tiptap editor history state and actions
|
|
16
|
-
* Provides real-time updates of undo/redo availability and history management
|
|
17
|
-
*/
|
|
18
|
-
export declare const useEditorHistory: (editor: Editor | null) => EditorHistoryState & EditorHistoryActions;
|
|
19
|
-
/**
|
|
20
|
-
* Utility function to check if undo/redo actions are available
|
|
21
|
-
*/
|
|
22
|
-
export declare const canExecuteHistoryAction: (editor: Editor | null, action: "undo" | "redo") => boolean;
|
|
23
|
-
/**
|
|
24
|
-
* Utility function to execute history actions safely
|
|
25
|
-
*/
|
|
26
|
-
export declare const executeHistoryAction: (editor: Editor | null, action: "undo" | "redo") => boolean;
|
|
27
|
-
/**
|
|
28
|
-
* Get keyboard shortcut text based on platform
|
|
29
|
-
*/
|
|
30
|
-
export declare const getHistoryShortcut: (action: "undo" | "redo") => string;
|
package/lib/kit.d.ts
DELETED
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { Editor } from '@tiptap/core';
|
|
2
|
-
export type PickedImage = {
|
|
3
|
-
src: string;
|
|
4
|
-
alt?: string;
|
|
5
|
-
width?: number | null;
|
|
6
|
-
height?: number | null;
|
|
7
|
-
blurDataURL?: string | null;
|
|
8
|
-
};
|
|
9
|
-
export type OpenImagePicker = () => Promise<PickedImage | null>;
|
|
10
|
-
export declare function setOpenImagePicker(editor: Editor, open?: OpenImagePicker): void;
|
|
11
|
-
export declare function getOpenImagePicker(editor: Editor): OpenImagePicker | undefined;
|