@oyat/editor 1.6.4 → 1.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +53 -36
- package/dist/components/editor/editor-base-kit.d.ts +283 -1
- package/dist/components/editor/editor-base-kit.d.ts.map +1 -1
- package/dist/components/editor/editor-kit.d.ts +592 -1
- package/dist/components/editor/editor-kit.d.ts.map +1 -1
- package/dist/components/editor/plate-editor.d.ts +4 -1
- package/dist/components/editor/plate-editor.d.ts.map +1 -1
- package/dist/components/editor/plugins/media-base-kit.d.ts +2 -2
- package/dist/components/editor/plugins/media-base-kit.d.ts.map +1 -1
- package/dist/components/editor/plugins/media-kit.d.ts +2 -2
- package/dist/components/editor/plugins/media-kit.d.ts.map +1 -1
- package/dist/components/ui/callout-node-static.d.ts +4 -0
- package/dist/components/ui/callout-node-static.d.ts.map +1 -1
- package/dist/components/ui/caption.d.ts +11 -0
- package/dist/components/ui/caption.d.ts.map +1 -0
- package/dist/components/ui/code-block-node-static.d.ts +7 -0
- package/dist/components/ui/code-block-node-static.d.ts.map +1 -1
- package/dist/components/ui/column-node-static.d.ts +8 -0
- package/dist/components/ui/column-node-static.d.ts.map +1 -1
- package/dist/components/ui/editor.d.ts +1 -1
- package/dist/components/ui/equation-node-static.d.ts +10 -0
- package/dist/components/ui/equation-node-static.d.ts.map +1 -1
- package/dist/components/ui/fixed-toolbar-buttons.d.ts.map +1 -1
- package/dist/components/ui/floating-toolbar-buttons.d.ts.map +1 -1
- package/dist/components/ui/font-color-toolbar-button.d.ts +23 -0
- package/dist/components/ui/font-color-toolbar-button.d.ts.map +1 -0
- package/dist/components/ui/insert-image-url-toolbar-button.d.ts +2 -0
- package/dist/components/ui/insert-image-url-toolbar-button.d.ts.map +1 -0
- package/dist/components/ui/insert-toolbar-button.d.ts.map +1 -1
- package/dist/components/ui/media-picker-toolbar-trigger.d.ts +2 -0
- package/dist/components/ui/media-picker-toolbar-trigger.d.ts.map +1 -0
- package/dist/components/ui/more-toolbar-button.d.ts.map +1 -1
- package/dist/components/ui/toc-node-static.d.ts +5 -0
- package/dist/components/ui/toc-node-static.d.ts.map +1 -1
- package/dist/components/ui/turn-into-toolbar-button.d.ts.map +1 -1
- package/dist/contexts/media-picker-context.d.ts +14 -0
- package/dist/contexts/media-picker-context.d.ts.map +1 -0
- package/dist/contexts/media-picker-provider.d.ts +8 -0
- package/dist/contexts/media-picker-provider.d.ts.map +1 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +840 -841
- package/dist/index.js.map +1 -1
- package/package.json +37 -50
- package/dist/components/editor/plate-types.d.ts +0 -85
- package/dist/components/editor/plate-types.d.ts.map +0 -1
- package/dist/components/editor/plugins/basic-nodes-kit.d.ts +0 -24
- package/dist/components/editor/plugins/basic-nodes-kit.d.ts.map +0 -1
- package/dist/components/editor/plugins/emoji-kit.d.ts +0 -6
- package/dist/components/editor/plugins/emoji-kit.d.ts.map +0 -1
- package/dist/components/editor/settings-dialog.d.ts +0 -8
- package/dist/components/editor/settings-dialog.d.ts.map +0 -1
- package/dist/components/editor/use-chat.d.ts +0 -64
- package/dist/components/editor/use-chat.d.ts.map +0 -1
- package/dist/components/ui/ai-chat-editor.d.ts +0 -5
- package/dist/components/ui/ai-chat-editor.d.ts.map +0 -1
- package/dist/components/ui/ai-menu.d.ts +0 -8
- package/dist/components/ui/ai-menu.d.ts.map +0 -1
- package/dist/components/ui/ai-node.d.ts +0 -4
- package/dist/components/ui/ai-node.d.ts.map +0 -1
- package/dist/components/ui/ai-toolbar-button.d.ts +0 -4
- package/dist/components/ui/ai-toolbar-button.d.ts.map +0 -1
- package/dist/components/ui/comment-toolbar-button.d.ts +0 -2
- package/dist/components/ui/comment-toolbar-button.d.ts.map +0 -1
- package/dist/components/ui/editor-static.d.ts +0 -9
- package/dist/components/ui/editor-static.d.ts.map +0 -1
- package/dist/components/ui/emoji-node.d.ts +0 -3
- package/dist/components/ui/emoji-node.d.ts.map +0 -1
- package/dist/components/ui/equation-toolbar-button.d.ts +0 -4
- package/dist/components/ui/equation-toolbar-button.d.ts.map +0 -1
- package/dist/components/ui/export-toolbar-button.d.ts +0 -3
- package/dist/components/ui/export-toolbar-button.d.ts.map +0 -1
- package/dist/components/ui/font-size-toolbar-button.d.ts +0 -2
- package/dist/components/ui/font-size-toolbar-button.d.ts.map +0 -1
- package/dist/components/ui/ghost-text.d.ts +0 -2
- package/dist/components/ui/ghost-text.d.ts.map +0 -1
- package/dist/components/ui/import-toolbar-button.d.ts +0 -3
- package/dist/components/ui/import-toolbar-button.d.ts.map +0 -1
- package/dist/components/ui/line-height-toolbar-button.d.ts +0 -3
- package/dist/components/ui/line-height-toolbar-button.d.ts.map +0 -1
- package/dist/components/ui/media-embed-node.d.ts +0 -5
- package/dist/components/ui/media-embed-node.d.ts.map +0 -1
- package/dist/components/ui/media-video-node-static.d.ts +0 -4
- package/dist/components/ui/media-video-node-static.d.ts.map +0 -1
- package/dist/components/ui/media-video-node.d.ts +0 -5
- package/dist/components/ui/media-video-node.d.ts.map +0 -1
- package/dist/components/ui/mode-toolbar-button.d.ts +0 -3
- package/dist/components/ui/mode-toolbar-button.d.ts.map +0 -1
- package/dist/components/ui/suggestion-toolbar-button.d.ts +0 -2
- package/dist/components/ui/suggestion-toolbar-button.d.ts.map +0 -1
- package/dist/components/ui/toggle-toolbar-button.d.ts +0 -4
- package/dist/components/ui/toggle-toolbar-button.d.ts.map +0 -1
|
@@ -1,6 +1,597 @@
|
|
|
1
1
|
import { Value } from 'platejs';
|
|
2
2
|
import { TPlateEditor } from 'platejs/react';
|
|
3
|
-
export declare const EditorKit:
|
|
3
|
+
export declare const EditorKit: (import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"textAlign", {}, {}, Record<"textAlign", {
|
|
4
|
+
setNodes: (value: import('@platejs/basic-styles').Alignment, setNodesOptions?: import('platejs').SetNodesOptions | undefined) => void;
|
|
5
|
+
}>, {}>> | import('platejs').SlatePlugin<import('@platejs/autoformat').AutoformatConfig> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"p", {}, {}, {}, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<any, {}, {}, Record<any, {
|
|
6
|
+
toggle: () => void;
|
|
7
|
+
}>, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"blockquote", {}, {}, Record<"blockquote", {
|
|
8
|
+
toggle: () => void;
|
|
9
|
+
}>, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"hr", {}, {}, {}, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"bold", {}, {}, Record<"bold", {
|
|
10
|
+
toggle: () => void;
|
|
11
|
+
}>, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"italic", {}, {}, Record<"italic", {
|
|
12
|
+
toggle: () => void;
|
|
13
|
+
}>, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"underline", {}, {}, Record<"underline", {
|
|
14
|
+
toggle: () => void;
|
|
15
|
+
}>, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"code", {}, {}, Record<"code", {
|
|
16
|
+
toggle: () => void;
|
|
17
|
+
}>, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"strikethrough", {}, {}, Record<"strikethrough", {
|
|
18
|
+
toggle: () => void;
|
|
19
|
+
}>, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"subscript", {}, {}, Record<"subscript", {
|
|
20
|
+
toggle: () => void;
|
|
21
|
+
}>, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"superscript", {}, {}, Record<"superscript", {
|
|
22
|
+
toggle: () => void;
|
|
23
|
+
}>, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"highlight", {}, {}, Record<"highlight", {
|
|
24
|
+
toggle: () => void;
|
|
25
|
+
}>, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"kbd", {}, {}, Record<"kbd", {
|
|
26
|
+
toggle: () => void;
|
|
27
|
+
}>, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"blockMenu", {
|
|
28
|
+
openId: ((string & {}) | "context") | null;
|
|
29
|
+
position: {
|
|
30
|
+
x: number;
|
|
31
|
+
y: number;
|
|
32
|
+
};
|
|
33
|
+
}, {
|
|
34
|
+
blockMenu: {
|
|
35
|
+
hide: () => void;
|
|
36
|
+
show: (id: (string & {}) | "context", position?: {
|
|
37
|
+
x: number;
|
|
38
|
+
y: number;
|
|
39
|
+
}) => void;
|
|
40
|
+
showContextMenu: (blockId: string, position: {
|
|
41
|
+
x: number;
|
|
42
|
+
y: number;
|
|
43
|
+
}) => void;
|
|
44
|
+
};
|
|
45
|
+
} & Record<"blockMenu", Partial<{
|
|
46
|
+
hide: () => void;
|
|
47
|
+
show: (id: (string & {}) | "context", position?: {
|
|
48
|
+
x: number;
|
|
49
|
+
y: number;
|
|
50
|
+
}) => void;
|
|
51
|
+
showContextMenu: (blockId: string, position: {
|
|
52
|
+
x: number;
|
|
53
|
+
y: number;
|
|
54
|
+
}) => void;
|
|
55
|
+
}>>, {}, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"blockSelection", {
|
|
56
|
+
anchorId?: string | null;
|
|
57
|
+
areaOptions?: {
|
|
58
|
+
document?: Document;
|
|
59
|
+
} & {
|
|
60
|
+
container?: (string | HTMLElement | (string | HTMLElement)[]) | undefined;
|
|
61
|
+
behaviour?: {
|
|
62
|
+
intersect?: ("center" | "cover" | "touch") | undefined;
|
|
63
|
+
overlap?: ("drop" | "invert" | "keep") | undefined;
|
|
64
|
+
scrolling?: {
|
|
65
|
+
manualSpeed?: number | undefined;
|
|
66
|
+
speedDivider?: number | undefined;
|
|
67
|
+
startScrollMargins?: {
|
|
68
|
+
x?: number | undefined;
|
|
69
|
+
y?: number | undefined;
|
|
70
|
+
} | undefined;
|
|
71
|
+
} | undefined;
|
|
72
|
+
startThreshold?: number | {
|
|
73
|
+
x?: number | undefined;
|
|
74
|
+
y?: number | undefined;
|
|
75
|
+
} | undefined;
|
|
76
|
+
triggers?: ((0 | 1 | 2 | 3 | 4) | {
|
|
77
|
+
button: 0 | 1 | 2 | 3 | 4;
|
|
78
|
+
modifiers: ("shift" | "alt" | "ctrl")[];
|
|
79
|
+
})[] | undefined;
|
|
80
|
+
} | undefined;
|
|
81
|
+
boundaries?: (string | HTMLElement | (string | HTMLElement)[]) | undefined;
|
|
82
|
+
features?: {
|
|
83
|
+
range?: boolean | undefined;
|
|
84
|
+
singleTap?: {
|
|
85
|
+
allow?: boolean | undefined;
|
|
86
|
+
intersect?: ("touch" | "native") | undefined;
|
|
87
|
+
} | undefined;
|
|
88
|
+
touch?: boolean | undefined;
|
|
89
|
+
} | undefined;
|
|
90
|
+
selectables?: (string | string[]) | undefined;
|
|
91
|
+
selectionAreaClass?: string | undefined;
|
|
92
|
+
startAreas?: (string | HTMLElement | (string | HTMLElement)[]) | undefined;
|
|
93
|
+
};
|
|
94
|
+
editorPaddingRight?: import('react').CSSProperties["width"];
|
|
95
|
+
enableContextMenu?: boolean;
|
|
96
|
+
disableSelectAll?: boolean;
|
|
97
|
+
isSelecting?: boolean;
|
|
98
|
+
isSelectionAreaVisible?: boolean;
|
|
99
|
+
rightSelectionAreaClassName?: string;
|
|
100
|
+
selectedIds?: Set<string>;
|
|
101
|
+
shadowInputRef?: React.RefObject<HTMLInputElement | null>;
|
|
102
|
+
isSelectable?: (element: import('platejs').TElement, path: import('platejs').Path) => boolean;
|
|
103
|
+
onKeyDownSelecting?: (editor: import('platejs').SlateEditor, e: KeyboardEvent) => void;
|
|
104
|
+
}, {
|
|
105
|
+
blockSelection: {
|
|
106
|
+
addOnContextMenu: import('platejs').OmitFirst<(editor: import('platejs/react').PlateEditor, { disabledWhenFocused, element, event }: {
|
|
107
|
+
element: import('platejs').TElement;
|
|
108
|
+
event: React.MouseEvent<HTMLDivElement, MouseEvent>;
|
|
109
|
+
disabledWhenFocused?: boolean;
|
|
110
|
+
}) => void>;
|
|
111
|
+
setSelectedIds: import('platejs').OmitFirst<(editor: import('platejs').SlateEditor, { added, ids, removed }: Partial<{
|
|
112
|
+
added: Element[];
|
|
113
|
+
removed: Element[];
|
|
114
|
+
}> & {
|
|
115
|
+
ids?: string[];
|
|
116
|
+
}) => void>;
|
|
117
|
+
add: (id: string[] | string) => void;
|
|
118
|
+
addSelectedRow: (id: string, options?: {
|
|
119
|
+
clear?: boolean;
|
|
120
|
+
delay?: number;
|
|
121
|
+
}) => void;
|
|
122
|
+
clear: () => void;
|
|
123
|
+
delete: (id: string[] | string) => void;
|
|
124
|
+
deselect: () => void;
|
|
125
|
+
first: () => import('platejs').NodeEntry<import('platejs').TIdElement> | null;
|
|
126
|
+
focus: () => void;
|
|
127
|
+
getNodes: (options?: {
|
|
128
|
+
collapseTableRows?: boolean;
|
|
129
|
+
selectionFallback?: boolean;
|
|
130
|
+
sort?: boolean;
|
|
131
|
+
}) => import('platejs').NodeEntry<import('platejs').TIdElement>[];
|
|
132
|
+
has: (id: string[] | string) => boolean;
|
|
133
|
+
isSelectable: (element: import('platejs').TElement, path: import('platejs').Path) => boolean;
|
|
134
|
+
moveSelection: (direction: "down" | "up") => void;
|
|
135
|
+
resetSelectedIds: () => void;
|
|
136
|
+
selectAll: () => void;
|
|
137
|
+
set: (id: string[] | string) => void;
|
|
138
|
+
shiftSelection: (direction: "down" | "up") => void;
|
|
139
|
+
unselect: () => void;
|
|
140
|
+
};
|
|
141
|
+
} & Record<"blockSelection", Partial<{
|
|
142
|
+
addOnContextMenu: import('platejs').OmitFirst<(editor: import('platejs/react').PlateEditor, { disabledWhenFocused, element, event }: {
|
|
143
|
+
element: import('platejs').TElement;
|
|
144
|
+
event: React.MouseEvent<HTMLDivElement, MouseEvent>;
|
|
145
|
+
disabledWhenFocused?: boolean;
|
|
146
|
+
}) => void>;
|
|
147
|
+
setSelectedIds: import('platejs').OmitFirst<(editor: import('platejs').SlateEditor, { added, ids, removed }: Partial<{
|
|
148
|
+
added: Element[];
|
|
149
|
+
removed: Element[];
|
|
150
|
+
}> & {
|
|
151
|
+
ids?: string[];
|
|
152
|
+
}) => void>;
|
|
153
|
+
add: (id: string[] | string) => void;
|
|
154
|
+
addSelectedRow: (id: string, options?: {
|
|
155
|
+
clear?: boolean;
|
|
156
|
+
delay?: number;
|
|
157
|
+
}) => void;
|
|
158
|
+
clear: () => void;
|
|
159
|
+
delete: (id: string[] | string) => void;
|
|
160
|
+
deselect: () => void;
|
|
161
|
+
first: () => import('platejs').NodeEntry<import('platejs').TIdElement> | null;
|
|
162
|
+
focus: () => void;
|
|
163
|
+
getNodes: (options?: {
|
|
164
|
+
collapseTableRows?: boolean;
|
|
165
|
+
selectionFallback?: boolean;
|
|
166
|
+
sort?: boolean;
|
|
167
|
+
}) => import('platejs').NodeEntry<import('platejs').TIdElement>[];
|
|
168
|
+
has: (id: string[] | string) => boolean;
|
|
169
|
+
isSelectable: (element: import('platejs').TElement, path: import('platejs').Path) => boolean;
|
|
170
|
+
moveSelection: (direction: "down" | "up") => void;
|
|
171
|
+
resetSelectedIds: () => void;
|
|
172
|
+
selectAll: () => void;
|
|
173
|
+
set: (id: string[] | string) => void;
|
|
174
|
+
shiftSelection: (direction: "down" | "up") => void;
|
|
175
|
+
unselect: () => void;
|
|
176
|
+
}>>, Record<"blockSelection", {
|
|
177
|
+
duplicate: () => void;
|
|
178
|
+
insertBlocksAndSelect: (nodes: import('platejs').TElement[], args_1: {
|
|
179
|
+
at: import('platejs').Path;
|
|
180
|
+
insertedCallback?: () => void;
|
|
181
|
+
}) => void;
|
|
182
|
+
removeNodes: () => void;
|
|
183
|
+
select: () => void;
|
|
184
|
+
selectBlocks: (at: import('platejs').Path | import('platejs').TNode) => void;
|
|
185
|
+
setIndent: (indent: number, options?: import('platejs').SetNodesOptions | undefined) => void;
|
|
186
|
+
setNodes: (props: Partial<Omit<import('platejs').TElement, "children">>, options?: import('platejs').SetNodesOptions | undefined) => void;
|
|
187
|
+
setTexts: (props: Partial<Omit<import('platejs').TText, "text">>, options?: Omit<import('platejs').SetNodesOptions, "at"> | undefined) => void;
|
|
188
|
+
}>, {
|
|
189
|
+
isSelected?: (id?: string) => boolean;
|
|
190
|
+
isSelectingSome?: () => boolean;
|
|
191
|
+
}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"dnd", {
|
|
192
|
+
_isOver?: boolean;
|
|
193
|
+
draggingId?: string[] | string | null;
|
|
194
|
+
dropTarget?: {
|
|
195
|
+
id: string | null;
|
|
196
|
+
line: import('@platejs/dnd').DropLineDirection;
|
|
197
|
+
};
|
|
198
|
+
enableScroller?: boolean;
|
|
199
|
+
isDragging?: boolean;
|
|
200
|
+
multiplePreviewRef?: React.RefObject<HTMLDivElement | null> | null;
|
|
201
|
+
scrollerProps?: Partial<import('@platejs/dnd').ScrollerProps>;
|
|
202
|
+
onDropFiles?: (props: {
|
|
203
|
+
id: string;
|
|
204
|
+
dragItem: import('@platejs/dnd').FileDragItemNode;
|
|
205
|
+
editor: import('platejs/react').PlateEditor;
|
|
206
|
+
monitor: import('react-dnd').DropTargetMonitor<import('@platejs/dnd').DragItemNode, unknown>;
|
|
207
|
+
nodeRef: any;
|
|
208
|
+
target?: import('platejs').Path;
|
|
209
|
+
}) => void;
|
|
210
|
+
}, {}, {}, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"blockPlaceholder", {
|
|
211
|
+
_target: {
|
|
212
|
+
node: import('platejs').TElement;
|
|
213
|
+
placeholder: string;
|
|
214
|
+
} | null;
|
|
215
|
+
placeholders: Record<string, string>;
|
|
216
|
+
query: (context: import('platejs/react').PlatePluginContext<import('platejs/react').BlockPlaceholderConfig> & {
|
|
217
|
+
node: import('platejs').TElement;
|
|
218
|
+
path: import('platejs').Path;
|
|
219
|
+
}) => boolean;
|
|
220
|
+
className?: string;
|
|
221
|
+
}, {}, {}, {
|
|
222
|
+
placeholder: (node: import('platejs').TElement) => string | undefined;
|
|
223
|
+
}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"callout", {}, {}, {
|
|
224
|
+
insert: {
|
|
225
|
+
callout: (args_0?: ({
|
|
226
|
+
batchDirty?: boolean;
|
|
227
|
+
hanging?: boolean;
|
|
228
|
+
nextBlock?: boolean;
|
|
229
|
+
removeEmpty?: import('platejs').QueryNodeOptions | boolean;
|
|
230
|
+
select?: boolean;
|
|
231
|
+
} & {
|
|
232
|
+
id?: boolean | string;
|
|
233
|
+
block?: boolean;
|
|
234
|
+
empty?: boolean;
|
|
235
|
+
match?: import('platejs').Predicate<import('platejs').NodeIn<Value>> | undefined;
|
|
236
|
+
text?: boolean;
|
|
237
|
+
} & import('platejs').QueryAt & import('platejs').QueryMode & import('platejs').QueryVoids & {
|
|
238
|
+
icon?: string;
|
|
239
|
+
variant?: (string & {}) | import('platejs').TCalloutElement["variant"];
|
|
240
|
+
}) | undefined) => void;
|
|
241
|
+
};
|
|
242
|
+
}, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"code_block", {
|
|
243
|
+
defaultLanguage?: string | null;
|
|
244
|
+
lowlight?: ReturnType<typeof import('lowlight').createLowlight> | null;
|
|
245
|
+
}, {}, Record<"code_block", {
|
|
246
|
+
toggle: () => void;
|
|
247
|
+
}>, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<any, {}, {}, {}, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"code_syntax", {}, {}, {}, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"column_group", {}, {}, {}, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"column", {}, {}, {}, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"comment", {
|
|
248
|
+
activeId: string | null;
|
|
249
|
+
commentingBlock: import('platejs').Path | null;
|
|
250
|
+
hoverId: string | null;
|
|
251
|
+
uniquePathMap: Map<string, import('platejs').Path>;
|
|
252
|
+
}, {
|
|
253
|
+
comment: {
|
|
254
|
+
has: (options: {
|
|
255
|
+
id: string;
|
|
256
|
+
}) => boolean;
|
|
257
|
+
node: (options?: import('platejs').EditorNodesOptions & {
|
|
258
|
+
id?: string;
|
|
259
|
+
isDraft?: boolean;
|
|
260
|
+
}) => import('platejs').NodeEntry<import('platejs').TCommentText> | undefined;
|
|
261
|
+
nodeId: (leaf: import('platejs').TCommentText) => string | undefined;
|
|
262
|
+
nodes: (options?: import('platejs').EditorNodesOptions & {
|
|
263
|
+
id?: string;
|
|
264
|
+
isDraft?: boolean;
|
|
265
|
+
transient?: boolean;
|
|
266
|
+
}) => import('platejs').NodeEntry<import('platejs').TCommentText>[];
|
|
267
|
+
};
|
|
268
|
+
}, {
|
|
269
|
+
comment: {
|
|
270
|
+
removeMark: () => void;
|
|
271
|
+
setDraft: (options?: import('platejs').SetNodesOptions) => void;
|
|
272
|
+
unsetMark: (options: {
|
|
273
|
+
id?: string;
|
|
274
|
+
transient?: boolean;
|
|
275
|
+
}) => void;
|
|
276
|
+
};
|
|
277
|
+
} & Record<"comment", {
|
|
278
|
+
setDraft: () => void;
|
|
279
|
+
}>, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"cursorOverlay", {
|
|
280
|
+
cursors: Record<string, import('@platejs/selection/react').CursorState<import('@platejs/selection/react').CursorData>>;
|
|
281
|
+
}, {
|
|
282
|
+
cursorOverlay: {
|
|
283
|
+
addCursor: (id: string, cursor: Omit<import('@platejs/selection/react').CursorState<import('@platejs/selection/react').CursorData>, "id">) => void;
|
|
284
|
+
removeCursor: (id: (string & {}) | "drag" | "selection") => void;
|
|
285
|
+
};
|
|
286
|
+
} & Record<"cursorOverlay", {
|
|
287
|
+
addCursor: (id: string, cursor: Omit<import('@platejs/selection/react').CursorState<import('@platejs/selection/react').CursorData>, "id">) => void;
|
|
288
|
+
removeCursor: (id: (string & {}) | "drag" | "selection") => void;
|
|
289
|
+
}>, {}, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"date", {}, {}, {
|
|
290
|
+
insert: {
|
|
291
|
+
date: (args_0?: ({
|
|
292
|
+
date?: string;
|
|
293
|
+
} & {
|
|
294
|
+
batchDirty?: boolean;
|
|
295
|
+
hanging?: boolean;
|
|
296
|
+
nextBlock?: boolean;
|
|
297
|
+
removeEmpty?: import('platejs').QueryNodeOptions | boolean;
|
|
298
|
+
select?: boolean;
|
|
299
|
+
} & {
|
|
300
|
+
id?: boolean | string;
|
|
301
|
+
block?: boolean;
|
|
302
|
+
empty?: boolean;
|
|
303
|
+
match?: import('platejs').Predicate<import('platejs').NodeIn<Value>> | undefined;
|
|
304
|
+
text?: boolean;
|
|
305
|
+
} & import('platejs').QueryAt & import('platejs').QueryMode & import('platejs').QueryVoids) | undefined) => void;
|
|
306
|
+
};
|
|
307
|
+
}, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"placeholder", import('@platejs/media').MediaPlaceholderOptions & {
|
|
308
|
+
disableEmptyPlaceholder: boolean;
|
|
309
|
+
disableFileDrop: boolean;
|
|
310
|
+
uploadConfig: import('@platejs/media/react').UploadConfig;
|
|
311
|
+
uploadingFiles: Record<string, File>;
|
|
312
|
+
error?: import('@platejs/media/react').UploadError | null;
|
|
313
|
+
maxFileCount?: number;
|
|
314
|
+
multiple?: boolean;
|
|
315
|
+
}, {
|
|
316
|
+
placeholder: import('@platejs/media/react').PlaceholderApi;
|
|
317
|
+
} & Record<"placeholder", {
|
|
318
|
+
addUploadingFile: (id: string, file: File) => void;
|
|
319
|
+
getUploadingFile: (id: string) => File;
|
|
320
|
+
removeUploadingFile: (id: string) => void;
|
|
321
|
+
}>, {
|
|
322
|
+
insert: {
|
|
323
|
+
media: (files: FileList, options?: (Omit<import('platejs').InsertNodesOptions, "at"> & {
|
|
324
|
+
at?: import('platejs').Path;
|
|
325
|
+
}) | undefined) => any;
|
|
326
|
+
};
|
|
327
|
+
}, {}>> | import('platejs').SlatePlugin<import('platejs').PluginConfig<"docx", {}, {}, {}, {}>> | import('platejs').SlatePlugin<import('platejs').PluginConfig<"juice", {}, {}, {}, {}>> | import('platejs').SlatePlugin<import('platejs').PluginConfig<"exitBreak", {}, {}, Record<"exitBreak", {
|
|
328
|
+
insert: (options: Omit<import('platejs').InsertExitBreakOptions, "reverse">) => true | undefined;
|
|
329
|
+
insertBefore: (options: Omit<import('platejs').InsertExitBreakOptions, "reverse">) => true | undefined;
|
|
330
|
+
}>, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"table", {
|
|
331
|
+
_cellIndices: Record<string, {
|
|
332
|
+
col: number;
|
|
333
|
+
row: number;
|
|
334
|
+
}>;
|
|
335
|
+
selectedCells: import('platejs').TElement[] | null;
|
|
336
|
+
selectedTables: import('platejs').TElement[] | null;
|
|
337
|
+
disableExpandOnInsert?: boolean;
|
|
338
|
+
disableMarginLeft?: boolean;
|
|
339
|
+
disableMerge?: boolean;
|
|
340
|
+
enableUnsetSingleColSize?: boolean;
|
|
341
|
+
initialTableWidth?: number;
|
|
342
|
+
minColumnWidth?: number;
|
|
343
|
+
}, {
|
|
344
|
+
create: {
|
|
345
|
+
table: import('platejs').OmitFirst<(editor: import('platejs').SlateEditor, { colCount, header, rowCount, ...cellOptions }?: import('@platejs/table').GetEmptyTableNodeOptions) => import('platejs').TTableElement>;
|
|
346
|
+
tableCell: import('platejs').OmitFirst<(editor: import('platejs').SlateEditor, { children, header, row }?: import('@platejs/table').CreateCellOptions) => {
|
|
347
|
+
children: import('platejs').Descendant[];
|
|
348
|
+
type: string;
|
|
349
|
+
}>;
|
|
350
|
+
tableRow: import('platejs').OmitFirst<(editor: import('platejs').SlateEditor, { colCount, ...cellOptions }?: import('@platejs/table').GetEmptyRowNodeOptions) => {
|
|
351
|
+
children: {
|
|
352
|
+
children: import('platejs').Descendant[];
|
|
353
|
+
type: string;
|
|
354
|
+
}[];
|
|
355
|
+
type: string;
|
|
356
|
+
}>;
|
|
357
|
+
};
|
|
358
|
+
table: {
|
|
359
|
+
getCellBorders: import('platejs').OmitFirst<(editor: import('platejs').SlateEditor, { cellIndices, defaultBorder, element }: {
|
|
360
|
+
element: import('platejs').TTableCellElement;
|
|
361
|
+
cellIndices?: import('@platejs/table').CellIndices;
|
|
362
|
+
defaultBorder?: import('platejs').TTableCellBorder;
|
|
363
|
+
}) => import('@platejs/table').BorderStylesDefault>;
|
|
364
|
+
getCellSize: import('platejs').OmitFirst<(editor: import('platejs').SlateEditor, { cellIndices, colSizes, element, rowSize }: {
|
|
365
|
+
element: import('platejs').TTableCellElement;
|
|
366
|
+
cellIndices?: import('@platejs/table').CellIndices;
|
|
367
|
+
colSizes?: number[];
|
|
368
|
+
rowSize?: number;
|
|
369
|
+
}) => {
|
|
370
|
+
minHeight: number | undefined;
|
|
371
|
+
width: number;
|
|
372
|
+
}>;
|
|
373
|
+
getColSpan: (cellElem: import('platejs').TTableCellElement) => number;
|
|
374
|
+
getRowSpan: (cellElem: import('platejs').TTableCellElement) => number;
|
|
375
|
+
getCellChildren: (cell: import('platejs').TTableCellElement) => import('platejs').Descendant[];
|
|
376
|
+
};
|
|
377
|
+
} & {
|
|
378
|
+
create: {
|
|
379
|
+
table: import('platejs').OmitFirst<(editor: import('platejs').SlateEditor, { colCount, header, rowCount, ...cellOptions }?: import('@platejs/table').GetEmptyTableNodeOptions) => import('platejs').TTableElement>;
|
|
380
|
+
tableCell: import('platejs').OmitFirst<(editor: import('platejs').SlateEditor, { children, header, row }?: import('@platejs/table').CreateCellOptions) => {
|
|
381
|
+
children: import('platejs').Descendant[];
|
|
382
|
+
type: string;
|
|
383
|
+
}>;
|
|
384
|
+
tableRow: import('platejs').OmitFirst<(editor: import('platejs').SlateEditor, { colCount, ...cellOptions }?: import('@platejs/table').GetEmptyRowNodeOptions) => {
|
|
385
|
+
children: {
|
|
386
|
+
children: import('platejs').Descendant[];
|
|
387
|
+
type: string;
|
|
388
|
+
}[];
|
|
389
|
+
type: string;
|
|
390
|
+
}>;
|
|
391
|
+
};
|
|
392
|
+
table: {
|
|
393
|
+
getCellBorders: import('platejs').OmitFirst<(editor: import('platejs').SlateEditor, { cellIndices, defaultBorder, element }: {
|
|
394
|
+
element: import('platejs').TTableCellElement;
|
|
395
|
+
cellIndices?: import('@platejs/table').CellIndices;
|
|
396
|
+
defaultBorder?: import('platejs').TTableCellBorder;
|
|
397
|
+
}) => import('@platejs/table').BorderStylesDefault>;
|
|
398
|
+
getCellSize: import('platejs').OmitFirst<(editor: import('platejs').SlateEditor, { cellIndices, colSizes, element, rowSize }: {
|
|
399
|
+
element: import('platejs').TTableCellElement;
|
|
400
|
+
cellIndices?: import('@platejs/table').CellIndices;
|
|
401
|
+
colSizes?: number[];
|
|
402
|
+
rowSize?: number;
|
|
403
|
+
}) => {
|
|
404
|
+
minHeight: number | undefined;
|
|
405
|
+
width: number;
|
|
406
|
+
}>;
|
|
407
|
+
getColSpan: (cellElem: import('platejs').TTableCellElement) => number;
|
|
408
|
+
getRowSpan: (cellElem: import('platejs').TTableCellElement) => number;
|
|
409
|
+
getCellChildren: (cell: import('platejs').TTableCellElement) => import('platejs').Descendant[];
|
|
410
|
+
};
|
|
411
|
+
}, {
|
|
412
|
+
insert: {
|
|
413
|
+
table: import('platejs').OmitFirst<(editor: import('platejs').SlateEditor, { colCount, header, rowCount }?: import('@platejs/table').GetEmptyTableNodeOptions, { select: shouldSelect, ...options }?: import('platejs').InsertNodesOptions) => void>;
|
|
414
|
+
tableColumn: import('platejs').OmitFirst<(editor: import('platejs').SlateEditor, options?: {
|
|
415
|
+
at?: import('platejs').Path;
|
|
416
|
+
before?: boolean;
|
|
417
|
+
fromCell?: import('platejs').Path;
|
|
418
|
+
header?: boolean;
|
|
419
|
+
select?: boolean;
|
|
420
|
+
}) => void>;
|
|
421
|
+
tableRow: import('platejs').OmitFirst<(editor: import('platejs').SlateEditor, options?: {
|
|
422
|
+
at?: import('platejs').Path;
|
|
423
|
+
before?: boolean;
|
|
424
|
+
fromRow?: import('platejs').Path;
|
|
425
|
+
header?: boolean;
|
|
426
|
+
select?: boolean;
|
|
427
|
+
}) => void>;
|
|
428
|
+
};
|
|
429
|
+
remove: {
|
|
430
|
+
table: import('platejs').OmitFirst<(editor: import('platejs').SlateEditor) => void>;
|
|
431
|
+
tableColumn: import('platejs').OmitFirst<(editor: import('platejs').SlateEditor) => void>;
|
|
432
|
+
tableRow: import('platejs').OmitFirst<(editor: import('platejs').SlateEditor) => void>;
|
|
433
|
+
};
|
|
434
|
+
table: {
|
|
435
|
+
merge: import('platejs').OmitFirst<(editor: import('platejs').SlateEditor) => void>;
|
|
436
|
+
split: import('platejs').OmitFirst<(editor: import('platejs').SlateEditor) => void>;
|
|
437
|
+
};
|
|
438
|
+
} & {
|
|
439
|
+
insert: {
|
|
440
|
+
table: import('platejs').OmitFirst<(editor: import('platejs').SlateEditor, { colCount, header, rowCount }?: import('@platejs/table').GetEmptyTableNodeOptions, { select: shouldSelect, ...options }?: import('platejs').InsertNodesOptions) => void>;
|
|
441
|
+
tableColumn: import('platejs').OmitFirst<(editor: import('platejs').SlateEditor, options?: {
|
|
442
|
+
at?: import('platejs').Path;
|
|
443
|
+
before?: boolean;
|
|
444
|
+
fromCell?: import('platejs').Path;
|
|
445
|
+
header?: boolean;
|
|
446
|
+
select?: boolean;
|
|
447
|
+
}) => void>;
|
|
448
|
+
tableRow: import('platejs').OmitFirst<(editor: import('platejs').SlateEditor, options?: {
|
|
449
|
+
at?: import('platejs').Path;
|
|
450
|
+
before?: boolean;
|
|
451
|
+
fromRow?: import('platejs').Path;
|
|
452
|
+
header?: boolean;
|
|
453
|
+
select?: boolean;
|
|
454
|
+
}) => void>;
|
|
455
|
+
};
|
|
456
|
+
remove: {
|
|
457
|
+
table: import('platejs').OmitFirst<(editor: import('platejs').SlateEditor) => void>;
|
|
458
|
+
tableColumn: import('platejs').OmitFirst<(editor: import('platejs').SlateEditor) => void>;
|
|
459
|
+
tableRow: import('platejs').OmitFirst<(editor: import('platejs').SlateEditor) => void>;
|
|
460
|
+
};
|
|
461
|
+
table: {
|
|
462
|
+
merge: import('platejs').OmitFirst<(editor: import('platejs').SlateEditor) => void>;
|
|
463
|
+
split: import('platejs').OmitFirst<(editor: import('platejs').SlateEditor) => void>;
|
|
464
|
+
};
|
|
465
|
+
}, {
|
|
466
|
+
cellIndices?: (id: string) => import('@platejs/table').CellIndices;
|
|
467
|
+
}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"fixed-toolbar", {}, {}, {}, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"floating-toolbar", {}, {}, {}, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"color", {}, {}, Record<"color", {
|
|
468
|
+
addMark: (value: string) => void;
|
|
469
|
+
}>, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"backgroundColor", {}, {}, Record<"backgroundColor", {
|
|
470
|
+
addMark: (value: string) => void;
|
|
471
|
+
}>, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"fontSize", {}, {}, Record<"fontSize", {
|
|
472
|
+
addMark: (value: string) => void;
|
|
473
|
+
}>, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"fontFamily", {}, {}, Record<"fontFamily", {
|
|
474
|
+
addMark: (value: string) => void;
|
|
475
|
+
}>, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"lineHeight", {}, {}, Record<"lineHeight", {
|
|
476
|
+
setNodes: (value: number, setNodesOptions?: import('platejs').SetNodesOptions | undefined) => void;
|
|
477
|
+
}>, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"a", {
|
|
478
|
+
allowedSchemes?: string[];
|
|
479
|
+
dangerouslySkipSanitization?: boolean;
|
|
480
|
+
defaultLinkAttributes?: React.AnchorHTMLAttributes<HTMLAnchorElement>;
|
|
481
|
+
forceSubmit?: boolean;
|
|
482
|
+
keepSelectedTextOnPaste?: boolean;
|
|
483
|
+
rangeBeforeOptions?: import('platejs').EditorBeforeOptions;
|
|
484
|
+
triggerFloatingLinkHotkeys?: string[] | string;
|
|
485
|
+
getLinkUrl?: (prevUrl: string | null) => Promise<string | null>;
|
|
486
|
+
getUrlHref?: (url: string) => string | undefined;
|
|
487
|
+
isUrl?: (text: string) => boolean;
|
|
488
|
+
transformInput?: (url: string) => string | undefined;
|
|
489
|
+
} & {
|
|
490
|
+
isEditing: boolean;
|
|
491
|
+
mode: import('@platejs/link/react').FloatingLinkMode;
|
|
492
|
+
mouseDown: boolean;
|
|
493
|
+
newTab: boolean;
|
|
494
|
+
openEditorId: string | null;
|
|
495
|
+
text: string;
|
|
496
|
+
updated: boolean;
|
|
497
|
+
url: string;
|
|
498
|
+
triggerFloatingLinkHotkeys?: string;
|
|
499
|
+
}, {
|
|
500
|
+
floatingLink: {
|
|
501
|
+
hide: () => void;
|
|
502
|
+
reset: () => void;
|
|
503
|
+
show: (mode: import('@platejs/link/react').FloatingLinkMode, editorId: string) => void;
|
|
504
|
+
};
|
|
505
|
+
link: {
|
|
506
|
+
getAttributes: import('platejs').OmitFirst<(editor: import('platejs').SlateEditor, link: import('platejs').TLinkElement) => Pick<import('react').AnchorHTMLAttributes<HTMLAnchorElement>, "href" | "target"> & import('platejs').UnknownObject>;
|
|
507
|
+
};
|
|
508
|
+
}, {}, {
|
|
509
|
+
isOpen?: (editorId: string) => boolean;
|
|
510
|
+
}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"indent", {
|
|
511
|
+
indentMax?: number;
|
|
512
|
+
offset?: number;
|
|
513
|
+
unit?: string;
|
|
514
|
+
}, {}, {}, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"list", {
|
|
515
|
+
getSiblingListOptions?: import('@platejs/list').GetSiblingListOptions<import('platejs').TElement>;
|
|
516
|
+
getListStyleType?: (element: HTMLElement) => import('@platejs/list').ListStyleType;
|
|
517
|
+
}, {}, {}, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"inline_equation", {}, {}, {
|
|
518
|
+
insert: {
|
|
519
|
+
inlineEquation: (texExpression?: string | undefined, options?: import('platejs').InsertNodesOptions | undefined) => void;
|
|
520
|
+
};
|
|
521
|
+
}, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"equation", {}, {}, {
|
|
522
|
+
insert: {
|
|
523
|
+
equation: (options?: import('platejs').InsertNodesOptions | undefined) => void;
|
|
524
|
+
};
|
|
525
|
+
}, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"img", {
|
|
526
|
+
disableEmbedInsert?: boolean;
|
|
527
|
+
disableUploadInsert?: boolean;
|
|
528
|
+
uploadImage?: (dataUrl: ArrayBuffer | string) => ArrayBuffer | Promise<ArrayBuffer | string> | string;
|
|
529
|
+
} & import('@platejs/media').MediaPluginOptions, {}, {
|
|
530
|
+
insert: {
|
|
531
|
+
imageFromFiles: (files: FileList, options?: import('platejs').InsertNodesOptions | undefined) => void;
|
|
532
|
+
};
|
|
533
|
+
}, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"audio", {}, {}, {}, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"file", {}, {}, {}, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"caption", {
|
|
534
|
+
focusEndPath: import('platejs').Path | null;
|
|
535
|
+
focusStartPath: import('platejs').Path | null;
|
|
536
|
+
query: {
|
|
537
|
+
allow: string[];
|
|
538
|
+
};
|
|
539
|
+
visibleId: string | null;
|
|
540
|
+
}, {}, {}, {
|
|
541
|
+
isVisible?: (elementId: string) => boolean;
|
|
542
|
+
}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"mention", {
|
|
543
|
+
insertSpaceAfterMention?: boolean;
|
|
544
|
+
} & import('@platejs/combobox').TriggerComboboxPluginOptions, {}, {
|
|
545
|
+
insert: {
|
|
546
|
+
mention: (options: {
|
|
547
|
+
search: string;
|
|
548
|
+
value: any;
|
|
549
|
+
key?: any;
|
|
550
|
+
}) => void;
|
|
551
|
+
};
|
|
552
|
+
}, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"mention_input", {}, {}, {}, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"slash_command", import('@platejs/combobox').TriggerComboboxPluginOptions, {}, {}, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"slash_input", {}, {}, {}, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"suggestion", {
|
|
553
|
+
currentUserId: string | null;
|
|
554
|
+
isSuggesting: boolean;
|
|
555
|
+
} & {
|
|
556
|
+
activeId: string | null;
|
|
557
|
+
hoverId: string | null;
|
|
558
|
+
uniquePathMap: Map<string, import('platejs').Path>;
|
|
559
|
+
}, {
|
|
560
|
+
suggestion: {
|
|
561
|
+
dataList: (node: import('platejs').TSuggestionText) => import('platejs').TInlineSuggestionData[];
|
|
562
|
+
isBlockSuggestion: (node: import('platejs').TNode) => node is import('platejs').TSuggestionElement;
|
|
563
|
+
node: (options?: import('platejs').EditorNodesOptions & {
|
|
564
|
+
id?: string;
|
|
565
|
+
isText?: boolean;
|
|
566
|
+
}) => import('platejs').NodeEntry<import('platejs').TSuggestionElement | import('platejs').TSuggestionText> | undefined;
|
|
567
|
+
nodeId: (node: import('platejs').TElement | import('platejs').TSuggestionText) => string | undefined;
|
|
568
|
+
nodes: (options?: import('platejs').EditorNodesOptions & {
|
|
569
|
+
transient?: boolean;
|
|
570
|
+
}) => import('platejs').NodeEntry<import('platejs').TElement | import('platejs').TSuggestionText>[];
|
|
571
|
+
suggestionData: (node: import('platejs').TElement | import('platejs').TSuggestionText) => import('platejs').TInlineSuggestionData | import('platejs').TSuggestionElement["suggestion"] | undefined;
|
|
572
|
+
withoutSuggestions: (fn: () => void) => void;
|
|
573
|
+
};
|
|
574
|
+
}, {}, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"tr", {}, {}, {}, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"td", {}, {}, {}, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"th", {}, {}, {}, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"toc", {
|
|
575
|
+
isScroll: boolean;
|
|
576
|
+
topOffset: number;
|
|
577
|
+
queryHeading?: (editor: import('platejs').SlateEditor) => import('@platejs/toc').Heading[];
|
|
578
|
+
}, {}, {}, {}>> | import('platejs/react').PlatePlugin<import('platejs').PluginConfig<"toggle", {
|
|
579
|
+
openIds?: Set<string>;
|
|
580
|
+
} & {
|
|
581
|
+
toggleIndex?: ReturnType<(elements: Value) => Map<string, string[]>>;
|
|
582
|
+
}, {
|
|
583
|
+
toggle: {
|
|
584
|
+
toggleIds: (ids: string[], force?: boolean | null) => void;
|
|
585
|
+
};
|
|
586
|
+
}, {}, {
|
|
587
|
+
isOpen?: (toggleId: string) => boolean;
|
|
588
|
+
someClosed?: (toggleIds: string[]) => boolean;
|
|
589
|
+
}>> | import('platejs').SlatePlugin<import('platejs').PluginConfig<"trailingBlock", {
|
|
590
|
+
type: string;
|
|
591
|
+
} & {
|
|
592
|
+
level?: number;
|
|
593
|
+
type?: string;
|
|
594
|
+
} & import('platejs').QueryNodeOptions, {}, {}, {}>>)[];
|
|
4
595
|
export type MyEditor = TPlateEditor<Value, (typeof EditorKit)[number]>;
|
|
5
596
|
export declare const useEditor: () => MyEditor | null;
|
|
6
597
|
//# sourceMappingURL=editor-kit.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"editor-kit.d.ts","sourceRoot":"","sources":["../../../src/components/editor/editor-kit.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,KAAK,EAAuB,MAAM,SAAS,CAAC;AAC1D,OAAO,EAAE,KAAK,YAAY,EAAgB,MAAM,eAAe,CAAC;
|
|
1
|
+
{"version":3,"file":"editor-kit.d.ts","sourceRoot":"","sources":["../../../src/components/editor/editor-kit.tsx"],"names":[],"mappings":"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"}
|
|
@@ -1,8 +1,11 @@
|
|
|
1
|
+
import { MediaPickerRenderProp } from '../../contexts/media-picker-provider';
|
|
1
2
|
import { Value } from 'platejs';
|
|
2
3
|
export interface PlateEditorProps {
|
|
3
4
|
initialValue?: Value | string;
|
|
4
5
|
onChange?: (value: Value) => void;
|
|
5
6
|
mode?: 'draft' | 'full';
|
|
7
|
+
/** Host-supplied media picker for image insertion. Receives { open, onSelect } and returns a ReactNode (e.g. trigger button). */
|
|
8
|
+
mediaPicker?: MediaPickerRenderProp;
|
|
6
9
|
}
|
|
7
|
-
export declare function PlateEditor({ initialValue, onChange, mode, }: PlateEditorProps): import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
export declare function PlateEditor({ initialValue, onChange, mode, mediaPicker, }: PlateEditorProps): import("react/jsx-runtime").JSX.Element;
|
|
8
11
|
//# sourceMappingURL=plate-editor.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"plate-editor.d.ts","sourceRoot":"","sources":["../../../src/components/editor/plate-editor.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"plate-editor.d.ts","sourceRoot":"","sources":["../../../src/components/editor/plate-editor.tsx"],"names":[],"mappings":"AASA,OAAO,EAEL,KAAK,qBAAqB,EAC3B,MAAM,kCAAkC,CAAC;AAI1C,OAAO,EAAE,KAAK,KAAK,EAAE,MAAM,SAAS,CAAC;AAGrC,MAAM,WAAW,gBAAgB;IAC/B,YAAY,CAAC,EAAE,KAAK,GAAG,MAAM,CAAC;IAC9B,QAAQ,CAAC,EAAE,CAAC,KAAK,EAAE,KAAK,KAAK,IAAI,CAAC;IAClC,IAAI,CAAC,EAAE,OAAO,GAAG,MAAM,CAAC;IACxB,iIAAiI;IACjI,WAAW,CAAC,EAAE,qBAAqB,CAAC;CACrC;AAiED,wBAAgB,WAAW,CAAC,EAC1B,YAAY,EACZ,QAAQ,EACR,IAAc,EACd,WAAW,GACZ,EAAE,gBAAgB,2CAuBlB"}
|
|
@@ -6,7 +6,7 @@ export declare const BaseMediaKit: (import('platejs').SlatePlugin<import('platej
|
|
|
6
6
|
insert: {
|
|
7
7
|
imageFromFiles: (files: FileList, options?: import('platejs').InsertNodesOptions | undefined) => void;
|
|
8
8
|
};
|
|
9
|
-
}, {}>> | import('platejs').SlatePlugin<import('platejs').PluginConfig<"
|
|
9
|
+
}, {}>> | import('platejs').SlatePlugin<import('platejs').PluginConfig<"audio", {}, {}, {}, {}>> | import('platejs').SlatePlugin<import('platejs').PluginConfig<"file", {}, {}, {}, {}>> | import('platejs').SlatePlugin<import('platejs').PluginConfig<"caption", {
|
|
10
10
|
focusEndPath: import('platejs').Path | null;
|
|
11
11
|
focusStartPath: import('platejs').Path | null;
|
|
12
12
|
query: {
|
|
@@ -15,7 +15,7 @@ export declare const BaseMediaKit: (import('platejs').SlatePlugin<import('platej
|
|
|
15
15
|
visibleId: string | null;
|
|
16
16
|
}, {}, {}, {
|
|
17
17
|
isVisible?: (elementId: string) => boolean;
|
|
18
|
-
}>> | import('platejs').SlatePlugin<import('
|
|
18
|
+
}>> | import('platejs').SlatePlugin<import('platejs').PluginConfig<"placeholder", import('@platejs/media').MediaPlaceholderOptions, {}, {
|
|
19
19
|
insert: {
|
|
20
20
|
audioPlaceholder: (options?: import('platejs').InsertNodesOptions | undefined) => void;
|
|
21
21
|
filePlaceholder: (options?: import('platejs').InsertNodesOptions | undefined) => void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"media-base-kit.d.ts","sourceRoot":"","sources":["../../../../src/components/editor/plugins/media-base-kit.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"media-base-kit.d.ts","sourceRoot":"","sources":["../../../../src/components/editor/plugins/media-base-kit.tsx"],"names":[],"mappings":"AAaA,eAAO,MAAM,YAAY;;;;;;iDAaw4D,CAAC;;;;;;;;;;;;;kCAAk1E,CAAC;iCAAiF,CAAC;kCAAkF,CAAC;kCAAkF,CAAC;;UAD5+I,CAAC"}
|