@react-email/editor 0.0.0-experimental.4 → 0.0.0-experimental.40
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/core/index.cjs +9 -0
- package/dist/core/index.d.cts +2 -0
- package/dist/core/index.d.mts +3 -0
- package/dist/core/index.mjs +4 -0
- package/dist/create-paste-handler-B8BtjBk3.d.cts +14 -0
- package/dist/create-paste-handler-B8BtjBk3.d.cts.map +1 -0
- package/dist/create-paste-handler-CGR738bC.d.mts +14 -0
- package/dist/create-paste-handler-CGR738bC.d.mts.map +1 -0
- package/dist/event-bus-CHEzOS_O.mjs +329 -0
- package/dist/event-bus-CHEzOS_O.mjs.map +1 -0
- package/dist/event-bus-fb8U7hrl.cjs +450 -0
- package/dist/extension-DyY8_bh4.mjs +1110 -0
- package/dist/extension-DyY8_bh4.mjs.map +1 -0
- package/dist/extension-w5VaUeSw.cjs +1235 -0
- package/dist/extensions/index.cjs +51 -0
- package/dist/extensions/index.d.cts +399 -0
- package/dist/extensions/index.d.cts.map +1 -0
- package/dist/extensions/index.d.mts +400 -0
- package/dist/extensions/index.d.mts.map +1 -0
- package/dist/extensions/index.mjs +5 -0
- package/dist/extensions-BvfmaKCn.mjs +2088 -0
- package/dist/extensions-BvfmaKCn.mjs.map +1 -0
- package/dist/extensions-CkjPj2JO.cjs +2369 -0
- package/dist/global-content-D_WYaFgX.mjs +78 -0
- package/dist/global-content-D_WYaFgX.mjs.map +1 -0
- package/dist/global-content-bJgotqmA.cjs +89 -0
- package/dist/index-C4KcMQ0R.d.cts +161 -0
- package/dist/index-C4KcMQ0R.d.cts.map +1 -0
- package/dist/index-CxX7W63O.d.mts +161 -0
- package/dist/index-CxX7W63O.d.mts.map +1 -0
- package/dist/index.cjs +74 -0
- package/dist/index.css +832 -0
- package/dist/index.css.map +1 -0
- package/dist/index.d.cts +33 -0
- package/dist/index.d.cts.map +1 -0
- package/dist/index.d.mts +31 -277
- package/dist/index.d.mts.map +1 -1
- package/dist/index.mjs +64 -1377
- package/dist/index.mjs.map +1 -1
- package/dist/plugins/index.cjs +23 -0
- package/dist/plugins/index.d.cts +191 -0
- package/dist/plugins/index.d.cts.map +1 -0
- package/dist/plugins/index.d.mts +191 -0
- package/dist/plugins/index.d.mts.map +1 -0
- package/dist/plugins/index.mjs +3 -0
- package/dist/root-CkYaJZpj.mjs +2316 -0
- package/dist/root-CkYaJZpj.mjs.map +1 -0
- package/dist/root-Gu08xybW.cjs +2832 -0
- package/dist/set-text-alignment-Cv72txmv.cjs +24 -0
- package/dist/set-text-alignment-OA8IMWmO.mjs +19 -0
- package/dist/set-text-alignment-OA8IMWmO.mjs.map +1 -0
- package/dist/styles-C-cCyJCn.cjs +211 -0
- package/dist/styles-_TMw3YxC.mjs +194 -0
- package/dist/styles-_TMw3YxC.mjs.map +1 -0
- package/dist/ui/bubble-menu/bubble-menu.css +285 -0
- package/dist/ui/index.cjs +147 -0
- package/dist/ui/index.d.cts +939 -0
- package/dist/ui/index.d.cts.map +1 -0
- package/dist/ui/index.d.mts +939 -0
- package/dist/ui/index.d.mts.map +1 -0
- package/dist/ui/index.mjs +60 -0
- package/dist/ui/index.mjs.map +1 -0
- package/dist/ui/slash-command/slash-command.css +44 -0
- package/dist/ui/themes/default.css +830 -0
- package/dist/utils/index.cjs +3 -0
- package/dist/utils/index.d.cts +7 -0
- package/dist/utils/index.d.cts.map +1 -0
- package/dist/utils/index.d.mts +7 -0
- package/dist/utils/index.d.mts.map +1 -0
- package/dist/utils/index.mjs +3 -0
- package/package.json +109 -21
- package/dist/index.d.ts +0 -279
- package/dist/index.d.ts.map +0 -1
- package/dist/index.js +0 -1436
|
@@ -0,0 +1,939 @@
|
|
|
1
|
+
import { Editor, Range } from "@tiptap/core";
|
|
2
|
+
import { EditorView } from "@tiptap/pm/view";
|
|
3
|
+
import * as React from "react";
|
|
4
|
+
import { ReactNode } from "react";
|
|
5
|
+
import * as react_jsx_runtime39 from "react/jsx-runtime";
|
|
6
|
+
import { EditorState, PluginKey } from "@tiptap/pm/state";
|
|
7
|
+
|
|
8
|
+
//#region src/ui/bubble-menu/create-mark-bubble-item.d.ts
|
|
9
|
+
interface PreWiredItemProps {
|
|
10
|
+
className?: string;
|
|
11
|
+
/** Override the default icon */
|
|
12
|
+
children?: React.ReactNode;
|
|
13
|
+
}
|
|
14
|
+
//#endregion
|
|
15
|
+
//#region src/ui/bubble-menu/align-center.d.ts
|
|
16
|
+
declare function BubbleMenuAlignCenter({
|
|
17
|
+
className,
|
|
18
|
+
children
|
|
19
|
+
}: PreWiredItemProps): react_jsx_runtime39.JSX.Element;
|
|
20
|
+
//#endregion
|
|
21
|
+
//#region src/ui/bubble-menu/align-left.d.ts
|
|
22
|
+
declare function BubbleMenuAlignLeft({
|
|
23
|
+
className,
|
|
24
|
+
children
|
|
25
|
+
}: PreWiredItemProps): react_jsx_runtime39.JSX.Element;
|
|
26
|
+
//#endregion
|
|
27
|
+
//#region src/ui/bubble-menu/align-right.d.ts
|
|
28
|
+
declare function BubbleMenuAlignRight({
|
|
29
|
+
className,
|
|
30
|
+
children
|
|
31
|
+
}: PreWiredItemProps): react_jsx_runtime39.JSX.Element;
|
|
32
|
+
//#endregion
|
|
33
|
+
//#region src/ui/bubble-menu/button-default.d.ts
|
|
34
|
+
interface BubbleMenuButtonDefaultProps extends Omit<React.ComponentPropsWithoutRef<'div'>, 'children'> {
|
|
35
|
+
placement?: 'top' | 'bottom';
|
|
36
|
+
offset?: number;
|
|
37
|
+
onHide?: () => void;
|
|
38
|
+
validateUrl?: (value: string) => string | null;
|
|
39
|
+
onLinkApply?: (href: string) => void;
|
|
40
|
+
onLinkRemove?: () => void;
|
|
41
|
+
}
|
|
42
|
+
declare function BubbleMenuButtonDefault({
|
|
43
|
+
placement,
|
|
44
|
+
offset,
|
|
45
|
+
onHide,
|
|
46
|
+
className,
|
|
47
|
+
validateUrl,
|
|
48
|
+
onLinkApply,
|
|
49
|
+
onLinkRemove,
|
|
50
|
+
...rest
|
|
51
|
+
}: BubbleMenuButtonDefaultProps): react_jsx_runtime39.JSX.Element;
|
|
52
|
+
//#endregion
|
|
53
|
+
//#region src/ui/bubble-menu/button-edit-link.d.ts
|
|
54
|
+
interface BubbleMenuButtonEditLinkProps extends Omit<React.ComponentProps<'button'>, 'type'> {}
|
|
55
|
+
declare function BubbleMenuButtonEditLink({
|
|
56
|
+
className,
|
|
57
|
+
children,
|
|
58
|
+
onClick,
|
|
59
|
+
onMouseDown,
|
|
60
|
+
...rest
|
|
61
|
+
}: BubbleMenuButtonEditLinkProps): react_jsx_runtime39.JSX.Element;
|
|
62
|
+
//#endregion
|
|
63
|
+
//#region src/ui/bubble-menu/button-form.d.ts
|
|
64
|
+
interface BubbleMenuButtonFormProps {
|
|
65
|
+
className?: string;
|
|
66
|
+
validateUrl?: (value: string) => string | null;
|
|
67
|
+
onLinkApply?: (href: string) => void;
|
|
68
|
+
onLinkRemove?: () => void;
|
|
69
|
+
}
|
|
70
|
+
declare function BubbleMenuButtonForm({
|
|
71
|
+
className,
|
|
72
|
+
validateUrl,
|
|
73
|
+
onLinkApply,
|
|
74
|
+
onLinkRemove
|
|
75
|
+
}: BubbleMenuButtonFormProps): react_jsx_runtime39.JSX.Element | null;
|
|
76
|
+
//#endregion
|
|
77
|
+
//#region src/ui/bubble-menu/button-toolbar.d.ts
|
|
78
|
+
interface BubbleMenuButtonToolbarProps extends React.ComponentProps<'div'> {}
|
|
79
|
+
declare function BubbleMenuButtonToolbar({
|
|
80
|
+
children,
|
|
81
|
+
...rest
|
|
82
|
+
}: BubbleMenuButtonToolbarProps): react_jsx_runtime39.JSX.Element | null;
|
|
83
|
+
//#endregion
|
|
84
|
+
//#region src/ui/bubble-menu/button-unlink.d.ts
|
|
85
|
+
interface BubbleMenuButtonUnlinkProps extends Omit<React.ComponentProps<'button'>, 'type'> {
|
|
86
|
+
onLinkRemove?: () => void;
|
|
87
|
+
}
|
|
88
|
+
declare function BubbleMenuButtonUnlink({
|
|
89
|
+
className,
|
|
90
|
+
children,
|
|
91
|
+
onClick,
|
|
92
|
+
onMouseDown,
|
|
93
|
+
onLinkRemove,
|
|
94
|
+
...rest
|
|
95
|
+
}: BubbleMenuButtonUnlinkProps): react_jsx_runtime39.JSX.Element;
|
|
96
|
+
//#endregion
|
|
97
|
+
//#region src/ui/bubble-menu/default.d.ts
|
|
98
|
+
type ExcludableItem$2 = 'bold' | 'italic' | 'underline' | 'strike' | 'code' | 'uppercase' | 'align-left' | 'align-center' | 'align-right' | 'node-selector' | 'link-selector';
|
|
99
|
+
interface BubbleMenuDefaultProps extends Omit<React.ComponentPropsWithoutRef<'div'>, 'children'> {
|
|
100
|
+
excludeItems?: ExcludableItem$2[];
|
|
101
|
+
hideWhenActiveNodes?: string[];
|
|
102
|
+
hideWhenActiveMarks?: string[];
|
|
103
|
+
placement?: 'top' | 'bottom';
|
|
104
|
+
offset?: number;
|
|
105
|
+
onHide?: () => void;
|
|
106
|
+
}
|
|
107
|
+
declare function BubbleMenuDefault({
|
|
108
|
+
excludeItems,
|
|
109
|
+
hideWhenActiveNodes,
|
|
110
|
+
hideWhenActiveMarks,
|
|
111
|
+
placement,
|
|
112
|
+
offset,
|
|
113
|
+
onHide,
|
|
114
|
+
className,
|
|
115
|
+
...rest
|
|
116
|
+
}: BubbleMenuDefaultProps): react_jsx_runtime39.JSX.Element;
|
|
117
|
+
//#endregion
|
|
118
|
+
//#region src/ui/bubble-menu/group.d.ts
|
|
119
|
+
interface BubbleMenuItemGroupProps {
|
|
120
|
+
className?: string;
|
|
121
|
+
children: React.ReactNode;
|
|
122
|
+
}
|
|
123
|
+
declare function BubbleMenuItemGroup({
|
|
124
|
+
className,
|
|
125
|
+
children
|
|
126
|
+
}: BubbleMenuItemGroupProps): react_jsx_runtime39.JSX.Element;
|
|
127
|
+
//#endregion
|
|
128
|
+
//#region src/ui/bubble-menu/image-default.d.ts
|
|
129
|
+
type ExcludableItem$1 = 'edit-link';
|
|
130
|
+
interface BubbleMenuImageDefaultProps extends Omit<React.ComponentPropsWithoutRef<'div'>, 'children'> {
|
|
131
|
+
excludeItems?: ExcludableItem$1[];
|
|
132
|
+
placement?: 'top' | 'bottom';
|
|
133
|
+
offset?: number;
|
|
134
|
+
onHide?: () => void;
|
|
135
|
+
}
|
|
136
|
+
declare function BubbleMenuImageDefault({
|
|
137
|
+
excludeItems,
|
|
138
|
+
placement,
|
|
139
|
+
offset,
|
|
140
|
+
onHide,
|
|
141
|
+
className,
|
|
142
|
+
...rest
|
|
143
|
+
}: BubbleMenuImageDefaultProps): react_jsx_runtime39.JSX.Element;
|
|
144
|
+
//#endregion
|
|
145
|
+
//#region src/ui/bubble-menu/image-edit-link.d.ts
|
|
146
|
+
interface BubbleMenuImageEditLinkProps extends Omit<React.ComponentProps<'button'>, 'type'> {}
|
|
147
|
+
declare function BubbleMenuImageEditLink({
|
|
148
|
+
className,
|
|
149
|
+
children,
|
|
150
|
+
onClick,
|
|
151
|
+
onMouseDown,
|
|
152
|
+
...rest
|
|
153
|
+
}: BubbleMenuImageEditLinkProps): react_jsx_runtime39.JSX.Element;
|
|
154
|
+
//#endregion
|
|
155
|
+
//#region src/ui/bubble-menu/image-toolbar.d.ts
|
|
156
|
+
interface BubbleMenuImageToolbarProps extends React.ComponentProps<'div'> {}
|
|
157
|
+
declare function BubbleMenuImageToolbar({
|
|
158
|
+
children,
|
|
159
|
+
...rest
|
|
160
|
+
}: BubbleMenuImageToolbarProps): react_jsx_runtime39.JSX.Element | null;
|
|
161
|
+
//#endregion
|
|
162
|
+
//#region src/ui/bubble-menu/item.d.ts
|
|
163
|
+
interface BubbleMenuItemProps extends React.ComponentProps<'button'> {
|
|
164
|
+
/** Used for aria-label and data-item attribute */
|
|
165
|
+
name: string;
|
|
166
|
+
/** Whether this item is currently active */
|
|
167
|
+
isActive: boolean;
|
|
168
|
+
/** Called when clicked */
|
|
169
|
+
onCommand: () => void;
|
|
170
|
+
}
|
|
171
|
+
declare function BubbleMenuItem({
|
|
172
|
+
name,
|
|
173
|
+
isActive,
|
|
174
|
+
onCommand,
|
|
175
|
+
className,
|
|
176
|
+
children,
|
|
177
|
+
...rest
|
|
178
|
+
}: BubbleMenuItemProps): react_jsx_runtime39.JSX.Element;
|
|
179
|
+
//#endregion
|
|
180
|
+
//#region src/ui/bubble-menu/link-default.d.ts
|
|
181
|
+
type ExcludableItem = 'edit-link' | 'open-link' | 'unlink';
|
|
182
|
+
interface BubbleMenuLinkDefaultProps extends Omit<React.ComponentPropsWithoutRef<'div'>, 'children'> {
|
|
183
|
+
excludeItems?: ExcludableItem[];
|
|
184
|
+
placement?: 'top' | 'bottom';
|
|
185
|
+
offset?: number;
|
|
186
|
+
onHide?: () => void;
|
|
187
|
+
validateUrl?: (value: string) => string | null;
|
|
188
|
+
onLinkApply?: (href: string) => void;
|
|
189
|
+
onLinkRemove?: () => void;
|
|
190
|
+
}
|
|
191
|
+
declare function BubbleMenuLinkDefault({
|
|
192
|
+
excludeItems,
|
|
193
|
+
placement,
|
|
194
|
+
offset,
|
|
195
|
+
onHide,
|
|
196
|
+
className,
|
|
197
|
+
validateUrl,
|
|
198
|
+
onLinkApply,
|
|
199
|
+
onLinkRemove,
|
|
200
|
+
...rest
|
|
201
|
+
}: BubbleMenuLinkDefaultProps): react_jsx_runtime39.JSX.Element;
|
|
202
|
+
//#endregion
|
|
203
|
+
//#region src/ui/bubble-menu/link-edit-link.d.ts
|
|
204
|
+
interface BubbleMenuLinkEditLinkProps extends Omit<React.ComponentProps<'button'>, 'type'> {}
|
|
205
|
+
declare function BubbleMenuLinkEditLink({
|
|
206
|
+
className,
|
|
207
|
+
children,
|
|
208
|
+
onClick,
|
|
209
|
+
onMouseDown,
|
|
210
|
+
...rest
|
|
211
|
+
}: BubbleMenuLinkEditLinkProps): react_jsx_runtime39.JSX.Element;
|
|
212
|
+
//#endregion
|
|
213
|
+
//#region src/ui/bubble-menu/link-form.d.ts
|
|
214
|
+
interface BubbleMenuLinkFormProps {
|
|
215
|
+
className?: string;
|
|
216
|
+
validateUrl?: (value: string) => string | null;
|
|
217
|
+
onLinkApply?: (href: string) => void;
|
|
218
|
+
onLinkRemove?: () => void;
|
|
219
|
+
children?: React.ReactNode;
|
|
220
|
+
}
|
|
221
|
+
declare function BubbleMenuLinkForm({
|
|
222
|
+
className,
|
|
223
|
+
validateUrl,
|
|
224
|
+
onLinkApply,
|
|
225
|
+
onLinkRemove,
|
|
226
|
+
children
|
|
227
|
+
}: BubbleMenuLinkFormProps): react_jsx_runtime39.JSX.Element | null;
|
|
228
|
+
//#endregion
|
|
229
|
+
//#region src/ui/bubble-menu/link-open-link.d.ts
|
|
230
|
+
interface BubbleMenuLinkOpenLinkProps extends Omit<React.ComponentProps<'a'>, 'href' | 'target' | 'rel'> {}
|
|
231
|
+
declare function BubbleMenuLinkOpenLink({
|
|
232
|
+
className,
|
|
233
|
+
children,
|
|
234
|
+
...rest
|
|
235
|
+
}: BubbleMenuLinkOpenLinkProps): react_jsx_runtime39.JSX.Element;
|
|
236
|
+
//#endregion
|
|
237
|
+
//#region src/ui/bubble-menu/link-selector.d.ts
|
|
238
|
+
interface BubbleMenuLinkSelectorProps {
|
|
239
|
+
className?: string;
|
|
240
|
+
/** Whether to show the link icon toggle button (default: true) */
|
|
241
|
+
showToggle?: boolean;
|
|
242
|
+
/** Custom URL validator. Return the valid URL string or null. */
|
|
243
|
+
validateUrl?: (value: string) => string | null;
|
|
244
|
+
/** Called after link is applied */
|
|
245
|
+
onLinkApply?: (href: string) => void;
|
|
246
|
+
/** Called after link is removed */
|
|
247
|
+
onLinkRemove?: () => void;
|
|
248
|
+
/** Plugin slot: extra actions rendered inside the link input form */
|
|
249
|
+
children?: React.ReactNode;
|
|
250
|
+
/** Controlled open state */
|
|
251
|
+
open?: boolean;
|
|
252
|
+
/** Called when open state changes */
|
|
253
|
+
onOpenChange?: (open: boolean) => void;
|
|
254
|
+
}
|
|
255
|
+
declare function BubbleMenuLinkSelector({
|
|
256
|
+
className,
|
|
257
|
+
showToggle,
|
|
258
|
+
validateUrl,
|
|
259
|
+
onLinkApply,
|
|
260
|
+
onLinkRemove,
|
|
261
|
+
children,
|
|
262
|
+
open: controlledOpen,
|
|
263
|
+
onOpenChange
|
|
264
|
+
}: BubbleMenuLinkSelectorProps): react_jsx_runtime39.JSX.Element | null;
|
|
265
|
+
//#endregion
|
|
266
|
+
//#region src/ui/bubble-menu/link-toolbar.d.ts
|
|
267
|
+
interface BubbleMenuLinkToolbarProps extends React.ComponentProps<'div'> {}
|
|
268
|
+
declare function BubbleMenuLinkToolbar({
|
|
269
|
+
children,
|
|
270
|
+
...rest
|
|
271
|
+
}: BubbleMenuLinkToolbarProps): react_jsx_runtime39.JSX.Element | null;
|
|
272
|
+
//#endregion
|
|
273
|
+
//#region src/ui/bubble-menu/link-unlink.d.ts
|
|
274
|
+
interface BubbleMenuLinkUnlinkProps extends Omit<React.ComponentProps<'button'>, 'type'> {}
|
|
275
|
+
declare function BubbleMenuLinkUnlink({
|
|
276
|
+
className,
|
|
277
|
+
children,
|
|
278
|
+
onClick,
|
|
279
|
+
onMouseDown,
|
|
280
|
+
...rest
|
|
281
|
+
}: BubbleMenuLinkUnlinkProps): react_jsx_runtime39.JSX.Element;
|
|
282
|
+
//#endregion
|
|
283
|
+
//#region src/ui/bubble-menu/node-selector.d.ts
|
|
284
|
+
type NodeType = 'Text' | 'Title' | 'Subtitle' | 'Heading' | 'Bullet List' | 'Numbered List' | 'Quote' | 'Code';
|
|
285
|
+
interface NodeSelectorItem {
|
|
286
|
+
name: NodeType;
|
|
287
|
+
icon: React.ComponentType<React.SVGAttributes<SVGSVGElement>>;
|
|
288
|
+
command: () => void;
|
|
289
|
+
isActive: boolean;
|
|
290
|
+
}
|
|
291
|
+
interface NodeSelectorRootProps {
|
|
292
|
+
/** Block types to exclude */
|
|
293
|
+
omit?: string[];
|
|
294
|
+
/** Controlled open state */
|
|
295
|
+
open?: boolean;
|
|
296
|
+
/** Called when open state changes */
|
|
297
|
+
onOpenChange?: (open: boolean) => void;
|
|
298
|
+
className?: string;
|
|
299
|
+
children: React.ReactNode;
|
|
300
|
+
}
|
|
301
|
+
declare function NodeSelectorRoot({
|
|
302
|
+
omit,
|
|
303
|
+
open: controlledOpen,
|
|
304
|
+
onOpenChange,
|
|
305
|
+
className,
|
|
306
|
+
children
|
|
307
|
+
}: NodeSelectorRootProps): react_jsx_runtime39.JSX.Element | null;
|
|
308
|
+
interface NodeSelectorTriggerProps {
|
|
309
|
+
className?: string;
|
|
310
|
+
children?: React.ReactNode;
|
|
311
|
+
}
|
|
312
|
+
declare function NodeSelectorTrigger({
|
|
313
|
+
className,
|
|
314
|
+
children
|
|
315
|
+
}: NodeSelectorTriggerProps): react_jsx_runtime39.JSX.Element;
|
|
316
|
+
interface NodeSelectorContentProps {
|
|
317
|
+
className?: string;
|
|
318
|
+
/** Popover alignment (default: "start") */
|
|
319
|
+
align?: 'start' | 'center' | 'end';
|
|
320
|
+
/** Render-prop for full control over item rendering.
|
|
321
|
+
* Receives the filtered items and a `close` function to dismiss the popover. */
|
|
322
|
+
children?: (items: NodeSelectorItem[], close: () => void) => React.ReactNode;
|
|
323
|
+
}
|
|
324
|
+
declare function NodeSelectorContent({
|
|
325
|
+
className,
|
|
326
|
+
align,
|
|
327
|
+
children
|
|
328
|
+
}: NodeSelectorContentProps): react_jsx_runtime39.JSX.Element;
|
|
329
|
+
interface BubbleMenuNodeSelectorProps {
|
|
330
|
+
/** Block types to exclude */
|
|
331
|
+
omit?: string[];
|
|
332
|
+
className?: string;
|
|
333
|
+
/** Override the trigger content (default: active item name + chevron icon) */
|
|
334
|
+
triggerContent?: React.ReactNode;
|
|
335
|
+
/** Controlled open state */
|
|
336
|
+
open?: boolean;
|
|
337
|
+
/** Called when open state changes */
|
|
338
|
+
onOpenChange?: (open: boolean) => void;
|
|
339
|
+
}
|
|
340
|
+
declare function BubbleMenuNodeSelector({
|
|
341
|
+
omit,
|
|
342
|
+
className,
|
|
343
|
+
triggerContent,
|
|
344
|
+
open,
|
|
345
|
+
onOpenChange
|
|
346
|
+
}: BubbleMenuNodeSelectorProps): react_jsx_runtime39.JSX.Element;
|
|
347
|
+
//#endregion
|
|
348
|
+
//#region src/ui/bubble-menu/triggers.d.ts
|
|
349
|
+
interface ShouldShowParams {
|
|
350
|
+
editor: Editor;
|
|
351
|
+
view: EditorView;
|
|
352
|
+
state: EditorState;
|
|
353
|
+
from: number;
|
|
354
|
+
to: number;
|
|
355
|
+
}
|
|
356
|
+
type ShouldShowFn = (params: ShouldShowParams) => boolean;
|
|
357
|
+
declare const bubbleMenuTriggers: {
|
|
358
|
+
textSelection(hideWhenActiveNodes?: string[], hideWhenActiveMarks?: string[]): ShouldShowFn;
|
|
359
|
+
node(name: string): ShouldShowFn;
|
|
360
|
+
nodeWithoutSelection(name: string): ShouldShowFn;
|
|
361
|
+
};
|
|
362
|
+
//#endregion
|
|
363
|
+
//#region src/ui/bubble-menu/root.d.ts
|
|
364
|
+
interface BubbleMenuRootProps extends Omit<React.ComponentPropsWithoutRef<'div'>, 'children'> {
|
|
365
|
+
shouldShow?: ShouldShowFn;
|
|
366
|
+
pluginKey?: PluginKey;
|
|
367
|
+
hideWhenActiveNodes?: string[];
|
|
368
|
+
hideWhenActiveMarks?: string[];
|
|
369
|
+
placement?: 'top' | 'bottom';
|
|
370
|
+
offset?: number;
|
|
371
|
+
onHide?: () => void;
|
|
372
|
+
children: React.ReactNode;
|
|
373
|
+
}
|
|
374
|
+
declare function BubbleMenuRoot({
|
|
375
|
+
shouldShow,
|
|
376
|
+
pluginKey,
|
|
377
|
+
hideWhenActiveNodes,
|
|
378
|
+
hideWhenActiveMarks,
|
|
379
|
+
placement,
|
|
380
|
+
offset,
|
|
381
|
+
onHide,
|
|
382
|
+
className,
|
|
383
|
+
children,
|
|
384
|
+
...rest
|
|
385
|
+
}: BubbleMenuRootProps): react_jsx_runtime39.JSX.Element | null;
|
|
386
|
+
//#endregion
|
|
387
|
+
//#region src/ui/bubble-menu/separator.d.ts
|
|
388
|
+
interface BubbleMenuSeparatorProps {
|
|
389
|
+
className?: string;
|
|
390
|
+
}
|
|
391
|
+
declare function BubbleMenuSeparator({
|
|
392
|
+
className
|
|
393
|
+
}: BubbleMenuSeparatorProps): react_jsx_runtime39.JSX.Element;
|
|
394
|
+
//#endregion
|
|
395
|
+
//#region src/ui/bubble-menu/bold.d.ts
|
|
396
|
+
declare const BubbleMenuBold: {
|
|
397
|
+
({
|
|
398
|
+
className,
|
|
399
|
+
children
|
|
400
|
+
}: PreWiredItemProps): react_jsx_runtime39.JSX.Element;
|
|
401
|
+
displayName: string;
|
|
402
|
+
};
|
|
403
|
+
//#endregion
|
|
404
|
+
//#region src/ui/bubble-menu/code.d.ts
|
|
405
|
+
declare const BubbleMenuCode: {
|
|
406
|
+
({
|
|
407
|
+
className,
|
|
408
|
+
children
|
|
409
|
+
}: PreWiredItemProps): react_jsx_runtime39.JSX.Element;
|
|
410
|
+
displayName: string;
|
|
411
|
+
};
|
|
412
|
+
//#endregion
|
|
413
|
+
//#region src/ui/bubble-menu/context.d.ts
|
|
414
|
+
interface BubbleMenuContextValue {
|
|
415
|
+
editor: Editor;
|
|
416
|
+
isEditing: boolean;
|
|
417
|
+
setIsEditing: (value: boolean) => void;
|
|
418
|
+
}
|
|
419
|
+
declare function useBubbleMenuContext(): BubbleMenuContextValue;
|
|
420
|
+
//#endregion
|
|
421
|
+
//#region src/ui/bubble-menu/italic.d.ts
|
|
422
|
+
declare const BubbleMenuItalic: {
|
|
423
|
+
({
|
|
424
|
+
className,
|
|
425
|
+
children
|
|
426
|
+
}: PreWiredItemProps): react_jsx_runtime39.JSX.Element;
|
|
427
|
+
displayName: string;
|
|
428
|
+
};
|
|
429
|
+
//#endregion
|
|
430
|
+
//#region src/ui/bubble-menu/strike.d.ts
|
|
431
|
+
declare const BubbleMenuStrike: {
|
|
432
|
+
({
|
|
433
|
+
className,
|
|
434
|
+
children
|
|
435
|
+
}: PreWiredItemProps): react_jsx_runtime39.JSX.Element;
|
|
436
|
+
displayName: string;
|
|
437
|
+
};
|
|
438
|
+
//#endregion
|
|
439
|
+
//#region src/ui/bubble-menu/underline.d.ts
|
|
440
|
+
declare const BubbleMenuUnderline: {
|
|
441
|
+
({
|
|
442
|
+
className,
|
|
443
|
+
children
|
|
444
|
+
}: PreWiredItemProps): react_jsx_runtime39.JSX.Element;
|
|
445
|
+
displayName: string;
|
|
446
|
+
};
|
|
447
|
+
//#endregion
|
|
448
|
+
//#region src/ui/bubble-menu/uppercase.d.ts
|
|
449
|
+
declare const BubbleMenuUppercase: {
|
|
450
|
+
({
|
|
451
|
+
className,
|
|
452
|
+
children
|
|
453
|
+
}: PreWiredItemProps): react_jsx_runtime39.JSX.Element;
|
|
454
|
+
displayName: string;
|
|
455
|
+
};
|
|
456
|
+
//#endregion
|
|
457
|
+
//#region src/ui/bubble-menu/index.d.ts
|
|
458
|
+
declare const BubbleMenu: {
|
|
459
|
+
readonly Root: typeof BubbleMenuRoot;
|
|
460
|
+
readonly ItemGroup: typeof BubbleMenuItemGroup;
|
|
461
|
+
readonly Separator: typeof BubbleMenuSeparator;
|
|
462
|
+
readonly Item: typeof BubbleMenuItem;
|
|
463
|
+
readonly Bold: {
|
|
464
|
+
({
|
|
465
|
+
className,
|
|
466
|
+
children
|
|
467
|
+
}: PreWiredItemProps): react_jsx_runtime39.JSX.Element;
|
|
468
|
+
displayName: string;
|
|
469
|
+
};
|
|
470
|
+
readonly Italic: {
|
|
471
|
+
({
|
|
472
|
+
className,
|
|
473
|
+
children
|
|
474
|
+
}: PreWiredItemProps): react_jsx_runtime39.JSX.Element;
|
|
475
|
+
displayName: string;
|
|
476
|
+
};
|
|
477
|
+
readonly Underline: {
|
|
478
|
+
({
|
|
479
|
+
className,
|
|
480
|
+
children
|
|
481
|
+
}: PreWiredItemProps): react_jsx_runtime39.JSX.Element;
|
|
482
|
+
displayName: string;
|
|
483
|
+
};
|
|
484
|
+
readonly Strike: {
|
|
485
|
+
({
|
|
486
|
+
className,
|
|
487
|
+
children
|
|
488
|
+
}: PreWiredItemProps): react_jsx_runtime39.JSX.Element;
|
|
489
|
+
displayName: string;
|
|
490
|
+
};
|
|
491
|
+
readonly Code: {
|
|
492
|
+
({
|
|
493
|
+
className,
|
|
494
|
+
children
|
|
495
|
+
}: PreWiredItemProps): react_jsx_runtime39.JSX.Element;
|
|
496
|
+
displayName: string;
|
|
497
|
+
};
|
|
498
|
+
readonly Uppercase: {
|
|
499
|
+
({
|
|
500
|
+
className,
|
|
501
|
+
children
|
|
502
|
+
}: PreWiredItemProps): react_jsx_runtime39.JSX.Element;
|
|
503
|
+
displayName: string;
|
|
504
|
+
};
|
|
505
|
+
readonly AlignLeft: typeof BubbleMenuAlignLeft;
|
|
506
|
+
readonly AlignCenter: typeof BubbleMenuAlignCenter;
|
|
507
|
+
readonly AlignRight: typeof BubbleMenuAlignRight;
|
|
508
|
+
readonly NodeSelector: typeof BubbleMenuNodeSelector & {
|
|
509
|
+
Root: typeof NodeSelectorRoot;
|
|
510
|
+
Trigger: typeof NodeSelectorTrigger;
|
|
511
|
+
Content: typeof NodeSelectorContent;
|
|
512
|
+
};
|
|
513
|
+
readonly LinkSelector: typeof BubbleMenuLinkSelector;
|
|
514
|
+
readonly Default: typeof BubbleMenuDefault;
|
|
515
|
+
readonly ButtonToolbar: typeof BubbleMenuButtonToolbar;
|
|
516
|
+
readonly ButtonEditLink: typeof BubbleMenuButtonEditLink;
|
|
517
|
+
readonly ButtonUnlink: typeof BubbleMenuButtonUnlink;
|
|
518
|
+
readonly ButtonForm: typeof BubbleMenuButtonForm;
|
|
519
|
+
readonly ButtonDefault: typeof BubbleMenuButtonDefault;
|
|
520
|
+
readonly LinkToolbar: typeof BubbleMenuLinkToolbar;
|
|
521
|
+
readonly LinkEditLink: typeof BubbleMenuLinkEditLink;
|
|
522
|
+
readonly LinkUnlink: typeof BubbleMenuLinkUnlink;
|
|
523
|
+
readonly LinkOpenLink: typeof BubbleMenuLinkOpenLink;
|
|
524
|
+
readonly LinkForm: typeof BubbleMenuLinkForm;
|
|
525
|
+
readonly LinkDefault: typeof BubbleMenuLinkDefault;
|
|
526
|
+
readonly ImageToolbar: typeof BubbleMenuImageToolbar;
|
|
527
|
+
readonly ImageEditLink: typeof BubbleMenuImageEditLink;
|
|
528
|
+
readonly ImageDefault: typeof BubbleMenuImageDefault;
|
|
529
|
+
};
|
|
530
|
+
//#endregion
|
|
531
|
+
//#region src/ui/icons/align-center.d.ts
|
|
532
|
+
interface IconProps$28 extends React.SVGAttributes<SVGSVGElement> {
|
|
533
|
+
size?: number | string;
|
|
534
|
+
}
|
|
535
|
+
declare function AlignCenterIcon({
|
|
536
|
+
size,
|
|
537
|
+
width,
|
|
538
|
+
height,
|
|
539
|
+
...props
|
|
540
|
+
}: IconProps$28): react_jsx_runtime39.JSX.Element;
|
|
541
|
+
//#endregion
|
|
542
|
+
//#region src/ui/icons/align-left.d.ts
|
|
543
|
+
interface IconProps$27 extends React.SVGAttributes<SVGSVGElement> {
|
|
544
|
+
size?: number | string;
|
|
545
|
+
}
|
|
546
|
+
declare function AlignLeftIcon({
|
|
547
|
+
size,
|
|
548
|
+
width,
|
|
549
|
+
height,
|
|
550
|
+
...props
|
|
551
|
+
}: IconProps$27): react_jsx_runtime39.JSX.Element;
|
|
552
|
+
//#endregion
|
|
553
|
+
//#region src/ui/icons/align-right.d.ts
|
|
554
|
+
interface IconProps$26 extends React.SVGAttributes<SVGSVGElement> {
|
|
555
|
+
size?: number | string;
|
|
556
|
+
}
|
|
557
|
+
declare function AlignRightIcon({
|
|
558
|
+
size,
|
|
559
|
+
width,
|
|
560
|
+
height,
|
|
561
|
+
...props
|
|
562
|
+
}: IconProps$26): react_jsx_runtime39.JSX.Element;
|
|
563
|
+
//#endregion
|
|
564
|
+
//#region src/ui/icons/bold.d.ts
|
|
565
|
+
interface IconProps$25 extends React.SVGAttributes<SVGSVGElement> {
|
|
566
|
+
size?: number | string;
|
|
567
|
+
}
|
|
568
|
+
declare function BoldIcon({
|
|
569
|
+
size,
|
|
570
|
+
width,
|
|
571
|
+
height,
|
|
572
|
+
...props
|
|
573
|
+
}: IconProps$25): react_jsx_runtime39.JSX.Element;
|
|
574
|
+
//#endregion
|
|
575
|
+
//#region src/ui/icons/case-upper.d.ts
|
|
576
|
+
interface IconProps$24 extends React.SVGAttributes<SVGSVGElement> {
|
|
577
|
+
size?: number | string;
|
|
578
|
+
}
|
|
579
|
+
declare function CaseUpperIcon({
|
|
580
|
+
size,
|
|
581
|
+
width,
|
|
582
|
+
height,
|
|
583
|
+
...props
|
|
584
|
+
}: IconProps$24): react_jsx_runtime39.JSX.Element;
|
|
585
|
+
//#endregion
|
|
586
|
+
//#region src/ui/icons/check.d.ts
|
|
587
|
+
interface IconProps$23 extends React.SVGAttributes<SVGSVGElement> {
|
|
588
|
+
size?: number | string;
|
|
589
|
+
}
|
|
590
|
+
declare function Check({
|
|
591
|
+
size,
|
|
592
|
+
width,
|
|
593
|
+
height,
|
|
594
|
+
...props
|
|
595
|
+
}: IconProps$23): react_jsx_runtime39.JSX.Element;
|
|
596
|
+
//#endregion
|
|
597
|
+
//#region src/ui/icons/chevron-down.d.ts
|
|
598
|
+
interface IconProps$22 extends React.SVGAttributes<SVGSVGElement> {
|
|
599
|
+
size?: number | string;
|
|
600
|
+
}
|
|
601
|
+
declare function ChevronDown({
|
|
602
|
+
size,
|
|
603
|
+
width,
|
|
604
|
+
height,
|
|
605
|
+
...props
|
|
606
|
+
}: IconProps$22): react_jsx_runtime39.JSX.Element;
|
|
607
|
+
//#endregion
|
|
608
|
+
//#region src/ui/icons/code.d.ts
|
|
609
|
+
interface IconProps$21 extends React.SVGAttributes<SVGSVGElement> {
|
|
610
|
+
size?: number | string;
|
|
611
|
+
}
|
|
612
|
+
declare function CodeIcon({
|
|
613
|
+
size,
|
|
614
|
+
width,
|
|
615
|
+
height,
|
|
616
|
+
...props
|
|
617
|
+
}: IconProps$21): react_jsx_runtime39.JSX.Element;
|
|
618
|
+
declare const Code: typeof CodeIcon;
|
|
619
|
+
//#endregion
|
|
620
|
+
//#region src/ui/icons/columns-2.d.ts
|
|
621
|
+
interface IconProps$20 extends React.SVGAttributes<SVGSVGElement> {
|
|
622
|
+
size?: number | string;
|
|
623
|
+
}
|
|
624
|
+
declare function Columns2({
|
|
625
|
+
size,
|
|
626
|
+
width,
|
|
627
|
+
height,
|
|
628
|
+
...props
|
|
629
|
+
}: IconProps$20): react_jsx_runtime39.JSX.Element;
|
|
630
|
+
//#endregion
|
|
631
|
+
//#region src/ui/icons/columns-3.d.ts
|
|
632
|
+
interface IconProps$19 extends React.SVGAttributes<SVGSVGElement> {
|
|
633
|
+
size?: number | string;
|
|
634
|
+
}
|
|
635
|
+
declare function Columns3({
|
|
636
|
+
size,
|
|
637
|
+
width,
|
|
638
|
+
height,
|
|
639
|
+
...props
|
|
640
|
+
}: IconProps$19): react_jsx_runtime39.JSX.Element;
|
|
641
|
+
//#endregion
|
|
642
|
+
//#region src/ui/icons/columns-4.d.ts
|
|
643
|
+
interface IconProps$18 extends React.SVGAttributes<SVGSVGElement> {
|
|
644
|
+
size?: number | string;
|
|
645
|
+
}
|
|
646
|
+
declare function Columns4({
|
|
647
|
+
size,
|
|
648
|
+
width,
|
|
649
|
+
height,
|
|
650
|
+
...props
|
|
651
|
+
}: IconProps$18): react_jsx_runtime39.JSX.Element;
|
|
652
|
+
//#endregion
|
|
653
|
+
//#region src/ui/icons/external-link.d.ts
|
|
654
|
+
interface IconProps$17 extends React.SVGAttributes<SVGSVGElement> {
|
|
655
|
+
size?: number | string;
|
|
656
|
+
}
|
|
657
|
+
declare function ExternalLinkIcon({
|
|
658
|
+
size,
|
|
659
|
+
width,
|
|
660
|
+
height,
|
|
661
|
+
...props
|
|
662
|
+
}: IconProps$17): react_jsx_runtime39.JSX.Element;
|
|
663
|
+
//#endregion
|
|
664
|
+
//#region src/ui/icons/heading-1.d.ts
|
|
665
|
+
interface IconProps$16 extends React.SVGAttributes<SVGSVGElement> {
|
|
666
|
+
size?: number | string;
|
|
667
|
+
}
|
|
668
|
+
declare function Heading1({
|
|
669
|
+
size,
|
|
670
|
+
width,
|
|
671
|
+
height,
|
|
672
|
+
...props
|
|
673
|
+
}: IconProps$16): react_jsx_runtime39.JSX.Element;
|
|
674
|
+
//#endregion
|
|
675
|
+
//#region src/ui/icons/heading-2.d.ts
|
|
676
|
+
interface IconProps$15 extends React.SVGAttributes<SVGSVGElement> {
|
|
677
|
+
size?: number | string;
|
|
678
|
+
}
|
|
679
|
+
declare function Heading2({
|
|
680
|
+
size,
|
|
681
|
+
width,
|
|
682
|
+
height,
|
|
683
|
+
...props
|
|
684
|
+
}: IconProps$15): react_jsx_runtime39.JSX.Element;
|
|
685
|
+
//#endregion
|
|
686
|
+
//#region src/ui/icons/heading-3.d.ts
|
|
687
|
+
interface IconProps$14 extends React.SVGAttributes<SVGSVGElement> {
|
|
688
|
+
size?: number | string;
|
|
689
|
+
}
|
|
690
|
+
declare function Heading3({
|
|
691
|
+
size,
|
|
692
|
+
width,
|
|
693
|
+
height,
|
|
694
|
+
...props
|
|
695
|
+
}: IconProps$14): react_jsx_runtime39.JSX.Element;
|
|
696
|
+
//#endregion
|
|
697
|
+
//#region src/ui/icons/italic.d.ts
|
|
698
|
+
interface IconProps$13 extends React.SVGAttributes<SVGSVGElement> {
|
|
699
|
+
size?: number | string;
|
|
700
|
+
}
|
|
701
|
+
declare function ItalicIcon({
|
|
702
|
+
size,
|
|
703
|
+
width,
|
|
704
|
+
height,
|
|
705
|
+
...props
|
|
706
|
+
}: IconProps$13): react_jsx_runtime39.JSX.Element;
|
|
707
|
+
//#endregion
|
|
708
|
+
//#region src/ui/icons/link.d.ts
|
|
709
|
+
interface IconProps$12 extends React.SVGAttributes<SVGSVGElement> {
|
|
710
|
+
size?: number | string;
|
|
711
|
+
}
|
|
712
|
+
declare function LinkIcon({
|
|
713
|
+
size,
|
|
714
|
+
width,
|
|
715
|
+
height,
|
|
716
|
+
...props
|
|
717
|
+
}: IconProps$12): react_jsx_runtime39.JSX.Element;
|
|
718
|
+
//#endregion
|
|
719
|
+
//#region src/ui/icons/list.d.ts
|
|
720
|
+
interface IconProps$11 extends React.SVGAttributes<SVGSVGElement> {
|
|
721
|
+
size?: number | string;
|
|
722
|
+
}
|
|
723
|
+
declare function List({
|
|
724
|
+
size,
|
|
725
|
+
width,
|
|
726
|
+
height,
|
|
727
|
+
...props
|
|
728
|
+
}: IconProps$11): react_jsx_runtime39.JSX.Element;
|
|
729
|
+
//#endregion
|
|
730
|
+
//#region src/ui/icons/list-ordered.d.ts
|
|
731
|
+
interface IconProps$10 extends React.SVGAttributes<SVGSVGElement> {
|
|
732
|
+
size?: number | string;
|
|
733
|
+
}
|
|
734
|
+
declare function ListOrdered({
|
|
735
|
+
size,
|
|
736
|
+
width,
|
|
737
|
+
height,
|
|
738
|
+
...props
|
|
739
|
+
}: IconProps$10): react_jsx_runtime39.JSX.Element;
|
|
740
|
+
//#endregion
|
|
741
|
+
//#region src/ui/icons/mouse-pointer.d.ts
|
|
742
|
+
interface IconProps$9 extends React.SVGAttributes<SVGSVGElement> {
|
|
743
|
+
size?: number | string;
|
|
744
|
+
}
|
|
745
|
+
declare function MousePointer({
|
|
746
|
+
size,
|
|
747
|
+
width,
|
|
748
|
+
height,
|
|
749
|
+
...props
|
|
750
|
+
}: IconProps$9): react_jsx_runtime39.JSX.Element;
|
|
751
|
+
//#endregion
|
|
752
|
+
//#region src/ui/icons/pencil.d.ts
|
|
753
|
+
interface IconProps$8 extends React.SVGAttributes<SVGSVGElement> {
|
|
754
|
+
size?: number | string;
|
|
755
|
+
}
|
|
756
|
+
declare function PencilIcon({
|
|
757
|
+
size,
|
|
758
|
+
width,
|
|
759
|
+
height,
|
|
760
|
+
...props
|
|
761
|
+
}: IconProps$8): react_jsx_runtime39.JSX.Element;
|
|
762
|
+
//#endregion
|
|
763
|
+
//#region src/ui/icons/rows-2.d.ts
|
|
764
|
+
interface IconProps$7 extends React.SVGAttributes<SVGSVGElement> {
|
|
765
|
+
size?: number | string;
|
|
766
|
+
}
|
|
767
|
+
declare function Rows2({
|
|
768
|
+
size,
|
|
769
|
+
width,
|
|
770
|
+
height,
|
|
771
|
+
...props
|
|
772
|
+
}: IconProps$7): react_jsx_runtime39.JSX.Element;
|
|
773
|
+
//#endregion
|
|
774
|
+
//#region src/ui/icons/split-square-vertical.d.ts
|
|
775
|
+
interface IconProps$6 extends React.SVGAttributes<SVGSVGElement> {
|
|
776
|
+
size?: number | string;
|
|
777
|
+
}
|
|
778
|
+
declare function SplitSquareVertical({
|
|
779
|
+
size,
|
|
780
|
+
width,
|
|
781
|
+
height,
|
|
782
|
+
...props
|
|
783
|
+
}: IconProps$6): react_jsx_runtime39.JSX.Element;
|
|
784
|
+
//#endregion
|
|
785
|
+
//#region src/ui/icons/square-code.d.ts
|
|
786
|
+
interface IconProps$5 extends React.SVGAttributes<SVGSVGElement> {
|
|
787
|
+
size?: number | string;
|
|
788
|
+
}
|
|
789
|
+
declare function SquareCode({
|
|
790
|
+
size,
|
|
791
|
+
width,
|
|
792
|
+
height,
|
|
793
|
+
...props
|
|
794
|
+
}: IconProps$5): react_jsx_runtime39.JSX.Element;
|
|
795
|
+
//#endregion
|
|
796
|
+
//#region src/ui/icons/strikethrough.d.ts
|
|
797
|
+
interface IconProps$4 extends React.SVGAttributes<SVGSVGElement> {
|
|
798
|
+
size?: number | string;
|
|
799
|
+
}
|
|
800
|
+
declare function StrikethroughIcon({
|
|
801
|
+
size,
|
|
802
|
+
width,
|
|
803
|
+
height,
|
|
804
|
+
...props
|
|
805
|
+
}: IconProps$4): react_jsx_runtime39.JSX.Element;
|
|
806
|
+
//#endregion
|
|
807
|
+
//#region src/ui/icons/text.d.ts
|
|
808
|
+
interface IconProps$3 extends React.SVGAttributes<SVGSVGElement> {
|
|
809
|
+
size?: number | string;
|
|
810
|
+
}
|
|
811
|
+
declare function TextIcon({
|
|
812
|
+
size,
|
|
813
|
+
width,
|
|
814
|
+
height,
|
|
815
|
+
...props
|
|
816
|
+
}: IconProps$3): react_jsx_runtime39.JSX.Element;
|
|
817
|
+
declare const Text: typeof TextIcon;
|
|
818
|
+
//#endregion
|
|
819
|
+
//#region src/ui/icons/text-quote.d.ts
|
|
820
|
+
interface IconProps$2 extends React.SVGAttributes<SVGSVGElement> {
|
|
821
|
+
size?: number | string;
|
|
822
|
+
}
|
|
823
|
+
declare function TextQuote({
|
|
824
|
+
size,
|
|
825
|
+
width,
|
|
826
|
+
height,
|
|
827
|
+
...props
|
|
828
|
+
}: IconProps$2): react_jsx_runtime39.JSX.Element;
|
|
829
|
+
//#endregion
|
|
830
|
+
//#region src/ui/icons/underline.d.ts
|
|
831
|
+
interface IconProps$1 extends React.SVGAttributes<SVGSVGElement> {
|
|
832
|
+
size?: number | string;
|
|
833
|
+
}
|
|
834
|
+
declare function UnderlineIcon({
|
|
835
|
+
size,
|
|
836
|
+
width,
|
|
837
|
+
height,
|
|
838
|
+
...props
|
|
839
|
+
}: IconProps$1): react_jsx_runtime39.JSX.Element;
|
|
840
|
+
//#endregion
|
|
841
|
+
//#region src/ui/icons/unlink.d.ts
|
|
842
|
+
interface IconProps extends React.SVGAttributes<SVGSVGElement> {
|
|
843
|
+
size?: number | string;
|
|
844
|
+
}
|
|
845
|
+
declare function UnlinkIcon({
|
|
846
|
+
size,
|
|
847
|
+
width,
|
|
848
|
+
height,
|
|
849
|
+
...props
|
|
850
|
+
}: IconProps): react_jsx_runtime39.JSX.Element;
|
|
851
|
+
//#endregion
|
|
852
|
+
//#region src/ui/slash-command/types.d.ts
|
|
853
|
+
type SlashCommandCategory = string;
|
|
854
|
+
interface SearchableItem {
|
|
855
|
+
title: string;
|
|
856
|
+
description: string;
|
|
857
|
+
searchTerms?: string[];
|
|
858
|
+
}
|
|
859
|
+
interface SlashCommandItem extends SearchableItem {
|
|
860
|
+
icon: ReactNode;
|
|
861
|
+
category: SlashCommandCategory;
|
|
862
|
+
command: (props: SlashCommandProps) => void;
|
|
863
|
+
}
|
|
864
|
+
interface SlashCommandProps {
|
|
865
|
+
editor: Editor;
|
|
866
|
+
range: Range;
|
|
867
|
+
}
|
|
868
|
+
interface SlashCommandRenderProps {
|
|
869
|
+
items: SlashCommandItem[];
|
|
870
|
+
query: string;
|
|
871
|
+
selectedIndex: number;
|
|
872
|
+
onSelect: (index: number) => void;
|
|
873
|
+
}
|
|
874
|
+
interface SlashCommandRootProps {
|
|
875
|
+
items?: SlashCommandItem[];
|
|
876
|
+
filterItems?: (items: SlashCommandItem[], query: string, editor: Editor) => SlashCommandItem[];
|
|
877
|
+
char?: string;
|
|
878
|
+
allow?: (props: {
|
|
879
|
+
editor: Editor;
|
|
880
|
+
}) => boolean;
|
|
881
|
+
children?: (props: SlashCommandRenderProps) => ReactNode;
|
|
882
|
+
}
|
|
883
|
+
interface CommandListProps {
|
|
884
|
+
items: SlashCommandItem[];
|
|
885
|
+
query: string;
|
|
886
|
+
selectedIndex: number;
|
|
887
|
+
onSelect: (index: number) => void;
|
|
888
|
+
}
|
|
889
|
+
//#endregion
|
|
890
|
+
//#region src/ui/slash-command/command-list.d.ts
|
|
891
|
+
declare function CommandList({
|
|
892
|
+
items,
|
|
893
|
+
query,
|
|
894
|
+
selectedIndex,
|
|
895
|
+
onSelect
|
|
896
|
+
}: CommandListProps): react_jsx_runtime39.JSX.Element;
|
|
897
|
+
//#endregion
|
|
898
|
+
//#region src/ui/slash-command/root.d.ts
|
|
899
|
+
declare function SlashCommandRoot({
|
|
900
|
+
items: itemsProp,
|
|
901
|
+
filterItems: filterItemsProp,
|
|
902
|
+
char,
|
|
903
|
+
allow: allowProp,
|
|
904
|
+
children
|
|
905
|
+
}: SlashCommandRootProps): React.ReactPortal | null;
|
|
906
|
+
//#endregion
|
|
907
|
+
//#region src/ui/slash-command/commands.d.ts
|
|
908
|
+
declare const TEXT: SlashCommandItem;
|
|
909
|
+
declare const H1: SlashCommandItem;
|
|
910
|
+
declare const H2: SlashCommandItem;
|
|
911
|
+
declare const H3: SlashCommandItem;
|
|
912
|
+
declare const BULLET_LIST: SlashCommandItem;
|
|
913
|
+
declare const NUMBERED_LIST: SlashCommandItem;
|
|
914
|
+
declare const QUOTE: SlashCommandItem;
|
|
915
|
+
declare const CODE: SlashCommandItem;
|
|
916
|
+
declare const BUTTON: SlashCommandItem;
|
|
917
|
+
declare const DIVIDER: SlashCommandItem;
|
|
918
|
+
declare const SECTION: SlashCommandItem;
|
|
919
|
+
declare const TWO_COLUMNS: SlashCommandItem;
|
|
920
|
+
declare const THREE_COLUMNS: SlashCommandItem;
|
|
921
|
+
declare const FOUR_COLUMNS: SlashCommandItem;
|
|
922
|
+
declare const defaultSlashCommands: SlashCommandItem[];
|
|
923
|
+
//#endregion
|
|
924
|
+
//#region src/ui/slash-command/search.d.ts
|
|
925
|
+
declare function scoreItem(item: SearchableItem, query: string): number;
|
|
926
|
+
declare function filterAndRankItems<T extends SearchableItem>(items: T[], query: string): T[];
|
|
927
|
+
//#endregion
|
|
928
|
+
//#region src/ui/slash-command/utils.d.ts
|
|
929
|
+
declare function isInsideNode(editor: Editor, type: string): boolean;
|
|
930
|
+
declare function isAtMaxColumnsDepth(editor: Editor): boolean;
|
|
931
|
+
//#endregion
|
|
932
|
+
//#region src/ui/slash-command/index.d.ts
|
|
933
|
+
declare const SlashCommand: {
|
|
934
|
+
readonly Root: typeof SlashCommandRoot;
|
|
935
|
+
readonly CommandList: typeof CommandList;
|
|
936
|
+
};
|
|
937
|
+
//#endregion
|
|
938
|
+
export { AlignCenterIcon, AlignLeftIcon, AlignRightIcon, BULLET_LIST, BUTTON, BoldIcon, BubbleMenu, BubbleMenuAlignCenter, BubbleMenuAlignLeft, BubbleMenuAlignRight, BubbleMenuBold, BubbleMenuButtonDefault, type BubbleMenuButtonDefaultProps, BubbleMenuButtonEditLink, type BubbleMenuButtonEditLinkProps, BubbleMenuButtonForm, type BubbleMenuButtonFormProps, BubbleMenuButtonToolbar, type BubbleMenuButtonToolbarProps, BubbleMenuButtonUnlink, type BubbleMenuButtonUnlinkProps, BubbleMenuCode, type BubbleMenuContextValue, BubbleMenuDefault, type BubbleMenuDefaultProps, BubbleMenuImageDefault, type BubbleMenuImageDefaultProps, BubbleMenuImageEditLink, type BubbleMenuImageEditLinkProps, BubbleMenuImageToolbar, type BubbleMenuImageToolbarProps, BubbleMenuItalic, BubbleMenuItem, BubbleMenuItemGroup, type BubbleMenuItemGroupProps, type BubbleMenuItemProps, BubbleMenuLinkDefault, type BubbleMenuLinkDefaultProps, BubbleMenuLinkEditLink, type BubbleMenuLinkEditLinkProps, BubbleMenuLinkForm, type BubbleMenuLinkFormProps, BubbleMenuLinkOpenLink, type BubbleMenuLinkOpenLinkProps, BubbleMenuLinkSelector, type BubbleMenuLinkSelectorProps, BubbleMenuLinkToolbar, type BubbleMenuLinkToolbarProps, BubbleMenuLinkUnlink, type BubbleMenuLinkUnlinkProps, BubbleMenuNodeSelector, type BubbleMenuNodeSelectorProps, BubbleMenuRoot, type BubbleMenuRootProps, BubbleMenuSeparator, type BubbleMenuSeparatorProps, BubbleMenuStrike, BubbleMenuUnderline, BubbleMenuUppercase, CODE, CaseUpperIcon, Check, ChevronDown, Code, CodeIcon, Columns2, Columns3, Columns4, CommandList, type CommandListProps, DIVIDER, ExternalLinkIcon, FOUR_COLUMNS, H1, H2, H3, Heading1, Heading2, Heading3, ItalicIcon, LinkIcon, List, ListOrdered, MousePointer, NUMBERED_LIST, NodeSelectorContent, type NodeSelectorContentProps, type NodeSelectorItem, NodeSelectorRoot, type NodeSelectorRootProps, NodeSelectorTrigger, type NodeSelectorTriggerProps, type NodeType, PencilIcon, type PreWiredItemProps, QUOTE, Rows2, SECTION, type SearchableItem, type ShouldShowFn, type ShouldShowParams, SlashCommand, type SlashCommandItem, type SlashCommandProps, type SlashCommandRenderProps, type SlashCommandRootProps, SplitSquareVertical, SquareCode, StrikethroughIcon, TEXT, THREE_COLUMNS, TWO_COLUMNS, Text, TextIcon, TextQuote, UnderlineIcon, UnlinkIcon, bubbleMenuTriggers, defaultSlashCommands, filterAndRankItems, isAtMaxColumnsDepth, isInsideNode, scoreItem, useBubbleMenuContext };
|
|
939
|
+
//# sourceMappingURL=index.d.cts.map
|