@react-email/editor 0.0.0-experimental.17 → 0.0.0-experimental.18
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/index.cjs +3 -0
- package/dist/index.d.cts +322 -299
- package/dist/index.d.cts.map +1 -1
- package/dist/index.d.mts +319 -296
- package/dist/index.d.mts.map +1 -1
- package/dist/index.mjs +10 -10
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -1,24 +1,24 @@
|
|
|
1
|
-
import * as
|
|
2
|
-
import { Content, Editor,
|
|
3
|
-
import { CodeBlockOptions } from "@tiptap/extension-code-block";
|
|
4
|
-
import * as _tiptap_extension_code0 from "@tiptap/extension-code";
|
|
5
|
-
import * as _tiptap_extension_paragraph0 from "@tiptap/extension-paragraph";
|
|
6
|
-
import * as _tiptap_extension_bullet_list0 from "@tiptap/extension-bullet-list";
|
|
7
|
-
import * as _tiptap_extension_ordered_list0 from "@tiptap/extension-ordered-list";
|
|
8
|
-
import * as _tiptap_extension_blockquote0 from "@tiptap/extension-blockquote";
|
|
9
|
-
import * as _tiptap_extension_list_item0 from "@tiptap/extension-list-item";
|
|
10
|
-
import * as _tiptap_extension_hard_break0 from "@tiptap/extension-hard-break";
|
|
11
|
-
import * as _tiptap_extension_italic0 from "@tiptap/extension-italic";
|
|
12
|
-
import * as _tiptap_extensions1 from "@tiptap/extensions";
|
|
13
|
-
import * as _tiptap_extension_strike0 from "@tiptap/extension-strike";
|
|
14
|
-
import * as _tiptap_extension_heading0 from "@tiptap/extension-heading";
|
|
15
|
-
import * as _tiptap_extension_horizontal_rule0 from "@tiptap/extension-horizontal-rule";
|
|
16
|
-
import * as _tiptap_extension_link0 from "@tiptap/extension-link";
|
|
17
|
-
import { StarterKitOptions as StarterKitOptions$1 } from "@tiptap/starter-kit";
|
|
18
|
-
import { Node as Node$1 } from "@tiptap/pm/model";
|
|
1
|
+
import * as _tiptap_core0 from "@tiptap/core";
|
|
2
|
+
import { Content, Editor, Extension, Extensions, JSONContent, Mark, MarkConfig, MarkType, Node, NodeConfig as NodeConfig$1, NodeType as NodeType$1, ParentConfig, Range } from "@tiptap/core";
|
|
19
3
|
import { UseEditorOptions } from "@tiptap/react";
|
|
4
|
+
import { Node as Node$1 } from "@tiptap/pm/model";
|
|
20
5
|
import { EditorView } from "@tiptap/pm/view";
|
|
21
|
-
import
|
|
6
|
+
import { BlockquoteOptions } from "@tiptap/extension-blockquote";
|
|
7
|
+
import { BulletListOptions } from "@tiptap/extension-bullet-list";
|
|
8
|
+
import { CodeOptions } from "@tiptap/extension-code";
|
|
9
|
+
import { HardBreakOptions } from "@tiptap/extension-hard-break";
|
|
10
|
+
import { ItalicOptions } from "@tiptap/extension-italic";
|
|
11
|
+
import { ListItemOptions } from "@tiptap/extension-list-item";
|
|
12
|
+
import { OrderedListOptions } from "@tiptap/extension-ordered-list";
|
|
13
|
+
import { ParagraphOptions } from "@tiptap/extension-paragraph";
|
|
14
|
+
import { StrikeOptions } from "@tiptap/extension-strike";
|
|
15
|
+
import { StarterKitOptions as StarterKitOptions$1 } from "@tiptap/starter-kit";
|
|
16
|
+
import { CodeBlockOptions } from "@tiptap/extension-code-block";
|
|
17
|
+
import { HorizontalRuleOptions } from "@tiptap/extension-horizontal-rule";
|
|
18
|
+
import { HeadingOptions as HeadingOptions$1 } from "@tiptap/extension-heading";
|
|
19
|
+
import { LinkOptions as LinkOptions$1 } from "@tiptap/extension-link";
|
|
20
|
+
import { PlaceholderOptions as PlaceholderOptions$1 } from "@tiptap/extension-placeholder";
|
|
21
|
+
import * as react_jsx_runtime8 from "react/jsx-runtime";
|
|
22
22
|
import * as React$1 from "react";
|
|
23
23
|
import { ComponentType, ReactNode, Ref } from "react";
|
|
24
24
|
|
|
@@ -73,21 +73,28 @@ type RendererComponent = (props: {
|
|
|
73
73
|
style: React.CSSProperties;
|
|
74
74
|
children?: React.ReactNode;
|
|
75
75
|
}) => React.ReactNode;
|
|
76
|
-
interface EmailNodeConfig<Options
|
|
76
|
+
interface EmailNodeConfig<Options, Storage> extends NodeConfig$1<Options, Storage> {
|
|
77
77
|
renderToReactEmail: RendererComponent;
|
|
78
78
|
}
|
|
79
|
-
type ConfigParameter$1<Options
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
79
|
+
type ConfigParameter$1<Options, Storage> = Partial<Omit<EmailNodeConfig<Options, Storage>, 'renderToReactEmail'>> & Pick<EmailNodeConfig<Options, Storage>, 'renderToReactEmail'> & ThisType<{
|
|
80
|
+
name: string;
|
|
81
|
+
options: Options;
|
|
82
|
+
storage: Storage;
|
|
83
|
+
editor: Editor;
|
|
84
|
+
type: NodeType$1;
|
|
85
|
+
parent: (...args: any[]) => any;
|
|
86
|
+
}>;
|
|
87
|
+
declare class EmailNode<Options = Record<string, never>, Storage = Record<string, never>> extends Node<Options, Storage> {
|
|
88
|
+
config: EmailNodeConfig<Options, Storage>;
|
|
89
|
+
constructor(config: ConfigParameter$1<Options, Storage>);
|
|
83
90
|
/**
|
|
84
91
|
* Create a new Node instance
|
|
85
92
|
* @param config - Node configuration object or a function that returns a configuration object
|
|
86
93
|
*/
|
|
87
94
|
static create<O = Record<string, never>, S = Record<string, never>>(config: ConfigParameter$1<O, S> | (() => ConfigParameter$1<O, S>)): EmailNode<O, S>;
|
|
88
95
|
static from<O, S>(node: Node<O, S>, renderToReactEmail: RendererComponent): EmailNode<O, S>;
|
|
89
|
-
configure(options?: Partial<Options
|
|
90
|
-
extend<ExtendedOptions = Options
|
|
96
|
+
configure(options?: Partial<Options>): EmailNode<Options, Storage>;
|
|
97
|
+
extend<ExtendedOptions = Options, ExtendedStorage = Storage, ExtendedConfig extends NodeConfig$1<ExtendedOptions, ExtendedStorage> = EmailNodeConfig<ExtendedOptions, ExtendedStorage>>(extendedConfig?: (() => Partial<ExtendedConfig>) | (Partial<ExtendedConfig> & ThisType<{
|
|
91
98
|
name: string;
|
|
92
99
|
options: ExtendedOptions;
|
|
93
100
|
storage: ExtendedStorage;
|
|
@@ -96,12 +103,65 @@ declare class EmailNode<Options$1 = Record<string, never>, Storage = Record<stri
|
|
|
96
103
|
}>)): EmailNode<ExtendedOptions, ExtendedStorage>;
|
|
97
104
|
}
|
|
98
105
|
//#endregion
|
|
99
|
-
//#region src/
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
106
|
+
//#region src/core/create-paste-handler.d.ts
|
|
107
|
+
type PasteHandler = (payload: string | File, view: EditorView) => boolean;
|
|
108
|
+
type UploadImageHandler = (file: File, view: EditorView, pos: number, preserveAttributes?: {
|
|
109
|
+
width?: string;
|
|
110
|
+
height?: string;
|
|
111
|
+
alignment?: string;
|
|
112
|
+
href?: string;
|
|
113
|
+
}) => void | Promise<void>;
|
|
114
|
+
//#endregion
|
|
115
|
+
//#region src/core/use-editor.d.ts
|
|
116
|
+
declare function useEditor({
|
|
117
|
+
content,
|
|
118
|
+
extensions,
|
|
119
|
+
onUpdate,
|
|
120
|
+
onPaste,
|
|
121
|
+
onUploadImage,
|
|
122
|
+
onReady,
|
|
123
|
+
editable,
|
|
124
|
+
...rest
|
|
125
|
+
}: {
|
|
126
|
+
content: Content;
|
|
127
|
+
extensions?: Extensions;
|
|
128
|
+
onUpdate?: (editor: Editor, transaction: {
|
|
129
|
+
getMeta: (key: string) => unknown;
|
|
130
|
+
}) => void;
|
|
131
|
+
onPaste?: PasteHandler;
|
|
132
|
+
onUploadImage?: UploadImageHandler;
|
|
133
|
+
onReady?: (editor: Editor | null) => void;
|
|
134
|
+
editable?: boolean;
|
|
135
|
+
} & UseEditorOptions): {
|
|
136
|
+
editor: Editor;
|
|
137
|
+
isEditorEmpty: boolean;
|
|
138
|
+
extensions: Extensions;
|
|
139
|
+
contentError: Error | null;
|
|
140
|
+
isCollaborative: boolean;
|
|
141
|
+
};
|
|
142
|
+
//#endregion
|
|
143
|
+
//#region src/extensions/alignment-attribute.d.ts
|
|
144
|
+
interface AlignmentOptions {
|
|
145
|
+
types: string[];
|
|
146
|
+
alignments: string[];
|
|
103
147
|
}
|
|
104
|
-
declare
|
|
148
|
+
declare module '@tiptap/core' {
|
|
149
|
+
interface Commands<ReturnType> {
|
|
150
|
+
alignment: {
|
|
151
|
+
/**
|
|
152
|
+
* Set the text align attribute
|
|
153
|
+
*/
|
|
154
|
+
setAlignment: (alignment: string) => ReturnType;
|
|
155
|
+
};
|
|
156
|
+
}
|
|
157
|
+
}
|
|
158
|
+
declare const AlignmentAttribute: Extension<AlignmentOptions, any>;
|
|
159
|
+
//#endregion
|
|
160
|
+
//#region src/extensions/body.d.ts
|
|
161
|
+
interface BodyOptions {
|
|
162
|
+
HTMLAttributes: Record<string, unknown>;
|
|
163
|
+
}
|
|
164
|
+
declare const Body: EmailNode<BodyOptions, Record<string, never>>;
|
|
105
165
|
//#endregion
|
|
106
166
|
//#region src/core/serializer/email-mark.d.ts
|
|
107
167
|
type SerializedMark = NonNullable<JSONContent['marks']>[number];
|
|
@@ -111,21 +171,28 @@ type RendererComponent$1 = (props: {
|
|
|
111
171
|
style: React.CSSProperties;
|
|
112
172
|
children?: React.ReactNode;
|
|
113
173
|
}) => React.ReactNode;
|
|
114
|
-
interface EmailMarkConfig<Options
|
|
174
|
+
interface EmailMarkConfig<Options, Storage> extends MarkConfig<Options, Storage> {
|
|
115
175
|
renderToReactEmail: RendererComponent$1;
|
|
116
176
|
}
|
|
117
|
-
type ConfigParameter<Options
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
177
|
+
type ConfigParameter<Options, Storage> = Partial<Omit<EmailMarkConfig<Options, Storage>, 'renderToReactEmail'>> & Pick<EmailMarkConfig<Options, Storage>, 'renderToReactEmail'> & ThisType<{
|
|
178
|
+
name: string;
|
|
179
|
+
options: Options;
|
|
180
|
+
storage: Storage;
|
|
181
|
+
editor: Editor;
|
|
182
|
+
type: MarkType;
|
|
183
|
+
parent: (...args: any[]) => any;
|
|
184
|
+
}>;
|
|
185
|
+
declare class EmailMark<Options = Record<string, never>, Storage = Record<string, never>> extends Mark<Options, Storage> {
|
|
186
|
+
config: EmailMarkConfig<Options, Storage>;
|
|
187
|
+
constructor(config: ConfigParameter<Options, Storage>);
|
|
121
188
|
/**
|
|
122
189
|
* Create a new Mark instance
|
|
123
190
|
* @param config - Mark configuration object or a function that returns a configuration object
|
|
124
191
|
*/
|
|
125
192
|
static create<O = Record<string, never>, S = Record<string, never>>(config: ConfigParameter<O, S> | (() => ConfigParameter<O, S>)): EmailMark<O, S>;
|
|
126
193
|
static from<O, S>(mark: Mark<O, S>, renderToReactEmail: RendererComponent$1): EmailMark<O, S>;
|
|
127
|
-
configure(options?: Partial<Options
|
|
128
|
-
extend<ExtendedOptions = Options
|
|
194
|
+
configure(options?: Partial<Options>): EmailMark<Options, Storage>;
|
|
195
|
+
extend<ExtendedOptions = Options, ExtendedStorage = Storage, ExtendedConfig extends MarkConfig<ExtendedOptions, ExtendedStorage> = EmailMarkConfig<ExtendedOptions, ExtendedStorage>>(extendedConfig?: (() => Partial<ExtendedConfig>) | (Partial<ExtendedConfig> & ThisType<{
|
|
129
196
|
name: string;
|
|
130
197
|
options: ExtendedOptions;
|
|
131
198
|
storage: ExtendedStorage;
|
|
@@ -134,12 +201,6 @@ declare class EmailMark<Options$1 = Record<string, never>, Storage = Record<stri
|
|
|
134
201
|
}>)): EmailMark<ExtendedOptions, ExtendedStorage>;
|
|
135
202
|
}
|
|
136
203
|
//#endregion
|
|
137
|
-
//#region src/extensions/preview-text.d.ts
|
|
138
|
-
interface PreviewTextOptions {
|
|
139
|
-
HTMLAttributes: Record<string, unknown>;
|
|
140
|
-
}
|
|
141
|
-
declare const PreviewText: Node<PreviewTextOptions, any>;
|
|
142
|
-
//#endregion
|
|
143
204
|
//#region src/extensions/bold.d.ts
|
|
144
205
|
interface BoldOptions {
|
|
145
206
|
/**
|
|
@@ -173,89 +234,48 @@ declare module '@tiptap/core' {
|
|
|
173
234
|
*/
|
|
174
235
|
declare const Bold: EmailMark<BoldOptions, Record<string, never>>;
|
|
175
236
|
//#endregion
|
|
176
|
-
//#region src/extensions/
|
|
177
|
-
interface
|
|
178
|
-
/**
|
|
179
|
-
* HTML attributes to add to the sup element.
|
|
180
|
-
* @default {}
|
|
181
|
-
* @example { class: 'foo' }
|
|
182
|
-
*/
|
|
237
|
+
//#region src/extensions/button.d.ts
|
|
238
|
+
interface EditorButtonOptions {
|
|
183
239
|
HTMLAttributes: Record<string, unknown>;
|
|
240
|
+
[key: string]: unknown;
|
|
184
241
|
}
|
|
185
242
|
declare module '@tiptap/core' {
|
|
186
243
|
interface Commands<ReturnType> {
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
*/
|
|
191
|
-
setSup: () => ReturnType;
|
|
192
|
-
/**
|
|
193
|
-
* Toggle a superscript mark
|
|
194
|
-
*/
|
|
195
|
-
toggleSup: () => ReturnType;
|
|
196
|
-
/**
|
|
197
|
-
* Unset a superscript mark
|
|
198
|
-
*/
|
|
199
|
-
unsetSup: () => ReturnType;
|
|
244
|
+
button: {
|
|
245
|
+
setButton: () => ReturnType;
|
|
246
|
+
updateButton: (attributes: Record<string, unknown>) => ReturnType;
|
|
200
247
|
};
|
|
201
248
|
}
|
|
202
249
|
}
|
|
203
|
-
|
|
204
|
-
* This extension allows you to mark text as superscript.
|
|
205
|
-
* @see https://tiptap.dev/api/marks/superscript
|
|
206
|
-
*/
|
|
207
|
-
declare const Sup: EmailMark<SupOptions, Record<string, never>>;
|
|
250
|
+
declare const Button: EmailNode<EditorButtonOptions, Record<string, never>>;
|
|
208
251
|
//#endregion
|
|
209
|
-
//#region src/extensions/
|
|
210
|
-
interface
|
|
211
|
-
|
|
252
|
+
//#region src/extensions/class-attribute.d.ts
|
|
253
|
+
interface ClassAttributeOptions {
|
|
254
|
+
types: string[];
|
|
255
|
+
class: string[];
|
|
212
256
|
}
|
|
213
257
|
declare module '@tiptap/core' {
|
|
214
258
|
interface Commands<ReturnType> {
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
259
|
+
class: {
|
|
260
|
+
/**
|
|
261
|
+
* Set the class attribute
|
|
262
|
+
*/
|
|
263
|
+
setClass: (classList: string) => ReturnType;
|
|
264
|
+
/**
|
|
265
|
+
* Unset the class attribute
|
|
266
|
+
*/
|
|
267
|
+
unsetClass: () => ReturnType;
|
|
219
268
|
};
|
|
220
269
|
}
|
|
221
270
|
}
|
|
222
|
-
declare const
|
|
223
|
-
//#endregion
|
|
224
|
-
//#region src/extensions/table.d.ts
|
|
225
|
-
declare module '@tiptap/core' {
|
|
226
|
-
interface NodeConfig<Options$1, Storage> {
|
|
227
|
-
/**
|
|
228
|
-
* A string or function to determine the role of the table.
|
|
229
|
-
* @default 'table'
|
|
230
|
-
* @example () => 'table'
|
|
231
|
-
*/
|
|
232
|
-
tableRole?: string | ((this: {
|
|
233
|
-
name: string;
|
|
234
|
-
options: Options$1;
|
|
235
|
-
storage: Storage;
|
|
236
|
-
parent: ParentConfig<NodeConfig<Options$1>>['tableRole'];
|
|
237
|
-
}) => string);
|
|
238
|
-
}
|
|
239
|
-
}
|
|
240
|
-
interface TableOptions {
|
|
241
|
-
HTMLAttributes: Record<string, unknown>;
|
|
242
|
-
}
|
|
243
|
-
declare const Table: EmailNode<TableOptions, Record<string, never>>;
|
|
244
|
-
interface TableRowOptions extends Record<string, unknown> {
|
|
245
|
-
HTMLAttributes?: Record<string, unknown>;
|
|
246
|
-
}
|
|
247
|
-
declare const TableRow: EmailNode<TableRowOptions, Record<string, never>>;
|
|
248
|
-
interface TableCellOptions extends Record<string, unknown> {
|
|
249
|
-
HTMLAttributes?: Record<string, unknown>;
|
|
250
|
-
}
|
|
251
|
-
declare const TableCell: EmailNode<TableCellOptions, Record<string, never>>;
|
|
252
|
-
declare const TableHeader: Node<any, any>;
|
|
271
|
+
declare const ClassAttribute: Extension<ClassAttributeOptions, any>;
|
|
253
272
|
//#endregion
|
|
254
|
-
//#region src/extensions/
|
|
255
|
-
interface
|
|
256
|
-
|
|
273
|
+
//#region src/extensions/code-block.d.ts
|
|
274
|
+
interface CodeBlockPrismOptions extends CodeBlockOptions {
|
|
275
|
+
defaultLanguage: string;
|
|
276
|
+
defaultTheme: string;
|
|
257
277
|
}
|
|
258
|
-
declare const
|
|
278
|
+
declare const CodeBlockPrism: EmailNode<CodeBlockPrismOptions, any>;
|
|
259
279
|
//#endregion
|
|
260
280
|
//#region src/extensions/div.d.ts
|
|
261
281
|
interface DivOptions {
|
|
@@ -263,34 +283,9 @@ interface DivOptions {
|
|
|
263
283
|
}
|
|
264
284
|
declare const Div: EmailNode<DivOptions, Record<string, never>>;
|
|
265
285
|
//#endregion
|
|
266
|
-
//#region src/extensions/
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
[key: string]: unknown;
|
|
270
|
-
}
|
|
271
|
-
declare module '@tiptap/core' {
|
|
272
|
-
interface Commands<ReturnType> {
|
|
273
|
-
button: {
|
|
274
|
-
setButton: () => ReturnType;
|
|
275
|
-
updateButton: (attributes: Record<string, unknown>) => ReturnType;
|
|
276
|
-
};
|
|
277
|
-
}
|
|
278
|
-
}
|
|
279
|
-
declare const Button: EmailNode<EditorButtonOptions, Record<string, never>>;
|
|
280
|
-
//#endregion
|
|
281
|
-
//#region src/extensions/section.d.ts
|
|
282
|
-
interface SectionOptions {
|
|
283
|
-
HTMLAttributes: Record<string, unknown>;
|
|
284
|
-
[key: string]: unknown;
|
|
285
|
-
}
|
|
286
|
-
declare module '@tiptap/core' {
|
|
287
|
-
interface Commands<ReturnType> {
|
|
288
|
-
section: {
|
|
289
|
-
insertSection: () => ReturnType;
|
|
290
|
-
};
|
|
291
|
-
}
|
|
292
|
-
}
|
|
293
|
-
declare const Section: EmailNode<SectionOptions, Record<string, never>>;
|
|
286
|
+
//#region src/extensions/divider.d.ts
|
|
287
|
+
type DividerOptions = HorizontalRuleOptions;
|
|
288
|
+
declare const Divider: EmailNode<HorizontalRuleOptions, any>;
|
|
294
289
|
//#endregion
|
|
295
290
|
//#region src/extensions/global-content.d.ts
|
|
296
291
|
interface GlobalContentOptions {
|
|
@@ -308,22 +303,49 @@ declare module '@tiptap/core' {
|
|
|
308
303
|
declare function getGlobalContent(key: string, editor: Editor): unknown | null;
|
|
309
304
|
declare const GlobalContent: Node<GlobalContentOptions, any>;
|
|
310
305
|
//#endregion
|
|
311
|
-
//#region src/extensions/
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
306
|
+
//#region src/extensions/heading.d.ts
|
|
307
|
+
type HeadingOptions = HeadingOptions$1;
|
|
308
|
+
declare const Heading: EmailNode<HeadingOptions$1, any>;
|
|
309
|
+
//#endregion
|
|
310
|
+
//#region src/extensions/link.d.ts
|
|
311
|
+
type LinkOptions = LinkOptions$1;
|
|
312
|
+
declare const Link: EmailMark<LinkOptions$1, any>;
|
|
313
|
+
//#endregion
|
|
314
|
+
//#region src/extensions/max-nesting.d.ts
|
|
315
|
+
interface MaxNestingOptions {
|
|
316
|
+
maxDepth: number;
|
|
317
|
+
nodeTypes?: string[];
|
|
318
|
+
}
|
|
319
|
+
declare const MaxNesting: Extension<MaxNestingOptions, any>;
|
|
320
|
+
//#endregion
|
|
321
|
+
//#region src/extensions/placeholder.d.ts
|
|
322
|
+
interface PlaceholderOptions {
|
|
323
|
+
placeholder?: string | ((props: {
|
|
324
|
+
node: Node$1;
|
|
325
|
+
}) => string);
|
|
326
|
+
includeChildren?: boolean;
|
|
327
|
+
}
|
|
328
|
+
declare const Placeholder: Extension<PlaceholderOptions$1, any>;
|
|
329
|
+
//#endregion
|
|
330
|
+
//#region src/extensions/preview-text.d.ts
|
|
331
|
+
interface PreviewTextOptions {
|
|
332
|
+
HTMLAttributes: Record<string, unknown>;
|
|
333
|
+
}
|
|
334
|
+
declare const PreviewText: Node<PreviewTextOptions, any>;
|
|
335
|
+
//#endregion
|
|
336
|
+
//#region src/extensions/section.d.ts
|
|
337
|
+
interface SectionOptions {
|
|
338
|
+
HTMLAttributes: Record<string, unknown>;
|
|
339
|
+
[key: string]: unknown;
|
|
315
340
|
}
|
|
316
341
|
declare module '@tiptap/core' {
|
|
317
342
|
interface Commands<ReturnType> {
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
* Set the text align attribute
|
|
321
|
-
*/
|
|
322
|
-
setAlignment: (alignment: string) => ReturnType;
|
|
343
|
+
section: {
|
|
344
|
+
insertSection: () => ReturnType;
|
|
323
345
|
};
|
|
324
346
|
}
|
|
325
347
|
}
|
|
326
|
-
declare const
|
|
348
|
+
declare const Section: EmailNode<SectionOptions, Record<string, never>>;
|
|
327
349
|
//#endregion
|
|
328
350
|
//#region src/extensions/style-attribute.d.ts
|
|
329
351
|
interface StyleAttributeOptions {
|
|
@@ -346,42 +368,92 @@ declare module '@tiptap/core' {
|
|
|
346
368
|
}
|
|
347
369
|
declare const StyleAttribute: Extension<StyleAttributeOptions, any>;
|
|
348
370
|
//#endregion
|
|
349
|
-
//#region src/extensions/
|
|
350
|
-
interface
|
|
351
|
-
|
|
352
|
-
|
|
371
|
+
//#region src/extensions/sup.d.ts
|
|
372
|
+
interface SupOptions {
|
|
373
|
+
/**
|
|
374
|
+
* HTML attributes to add to the sup element.
|
|
375
|
+
* @default {}
|
|
376
|
+
* @example { class: 'foo' }
|
|
377
|
+
*/
|
|
378
|
+
HTMLAttributes: Record<string, unknown>;
|
|
353
379
|
}
|
|
354
380
|
declare module '@tiptap/core' {
|
|
355
381
|
interface Commands<ReturnType> {
|
|
356
|
-
|
|
382
|
+
sup: {
|
|
357
383
|
/**
|
|
358
|
-
* Set
|
|
384
|
+
* Set a superscript mark
|
|
359
385
|
*/
|
|
360
|
-
|
|
386
|
+
setSup: () => ReturnType;
|
|
361
387
|
/**
|
|
362
|
-
*
|
|
388
|
+
* Toggle a superscript mark
|
|
363
389
|
*/
|
|
364
|
-
|
|
390
|
+
toggleSup: () => ReturnType;
|
|
391
|
+
/**
|
|
392
|
+
* Unset a superscript mark
|
|
393
|
+
*/
|
|
394
|
+
unsetSup: () => ReturnType;
|
|
365
395
|
};
|
|
366
396
|
}
|
|
367
397
|
}
|
|
368
|
-
|
|
398
|
+
/**
|
|
399
|
+
* This extension allows you to mark text as superscript.
|
|
400
|
+
* @see https://tiptap.dev/api/marks/superscript
|
|
401
|
+
*/
|
|
402
|
+
declare const Sup: EmailMark<SupOptions, Record<string, never>>;
|
|
369
403
|
//#endregion
|
|
370
|
-
//#region src/extensions/
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
404
|
+
//#region src/extensions/table.d.ts
|
|
405
|
+
declare module '@tiptap/core' {
|
|
406
|
+
interface NodeConfig<Options, Storage> {
|
|
407
|
+
/**
|
|
408
|
+
* A string or function to determine the role of the table.
|
|
409
|
+
* @default 'table'
|
|
410
|
+
* @example () => 'table'
|
|
411
|
+
*/
|
|
412
|
+
tableRole?: string | ((this: {
|
|
413
|
+
name: string;
|
|
414
|
+
options: Options;
|
|
415
|
+
storage: Storage;
|
|
416
|
+
parent: ParentConfig<NodeConfig<Options>>['tableRole'];
|
|
417
|
+
}) => string);
|
|
418
|
+
}
|
|
374
419
|
}
|
|
375
|
-
|
|
420
|
+
interface TableOptions {
|
|
421
|
+
HTMLAttributes: Record<string, unknown>;
|
|
422
|
+
}
|
|
423
|
+
declare const Table: EmailNode<TableOptions, Record<string, never>>;
|
|
424
|
+
interface TableRowOptions extends Record<string, unknown> {
|
|
425
|
+
HTMLAttributes?: Record<string, unknown>;
|
|
426
|
+
}
|
|
427
|
+
declare const TableRow: EmailNode<TableRowOptions, Record<string, never>>;
|
|
428
|
+
interface TableCellOptions extends Record<string, unknown> {
|
|
429
|
+
HTMLAttributes?: Record<string, unknown>;
|
|
430
|
+
}
|
|
431
|
+
declare const TableCell: EmailNode<TableCellOptions, Record<string, never>>;
|
|
432
|
+
declare const TableHeader: Node<any, any>;
|
|
433
|
+
//#endregion
|
|
434
|
+
//#region src/extensions/uppercase.d.ts
|
|
435
|
+
interface UppercaseOptions {
|
|
436
|
+
HTMLAttributes: Record<string, unknown>;
|
|
437
|
+
}
|
|
438
|
+
declare module '@tiptap/core' {
|
|
439
|
+
interface Commands<ReturnType> {
|
|
440
|
+
uppercase: {
|
|
441
|
+
setUppercase: () => ReturnType;
|
|
442
|
+
toggleUppercase: () => ReturnType;
|
|
443
|
+
unsetUppercase: () => ReturnType;
|
|
444
|
+
};
|
|
445
|
+
}
|
|
446
|
+
}
|
|
447
|
+
declare const Uppercase: EmailMark<UppercaseOptions, Record<string, never>>;
|
|
376
448
|
//#endregion
|
|
377
449
|
//#region src/extensions/blockquote.d.ts
|
|
378
|
-
declare const Blockquote: EmailNode<
|
|
450
|
+
declare const Blockquote: EmailNode<BlockquoteOptions, any>;
|
|
379
451
|
//#endregion
|
|
380
452
|
//#region src/extensions/bullet-list.d.ts
|
|
381
|
-
declare const BulletList: EmailNode<
|
|
453
|
+
declare const BulletList: EmailNode<BulletListOptions, any>;
|
|
382
454
|
//#endregion
|
|
383
455
|
//#region src/extensions/code.d.ts
|
|
384
|
-
declare const Code: EmailMark<
|
|
456
|
+
declare const Code: EmailMark<CodeOptions, any>;
|
|
385
457
|
//#endregion
|
|
386
458
|
//#region src/extensions/columns.d.ts
|
|
387
459
|
declare module '@tiptap/core' {
|
|
@@ -400,28 +472,19 @@ declare const FourColumns: EmailNode<Record<string, never>, Record<string, never
|
|
|
400
472
|
declare const ColumnsColumn: EmailNode<Record<string, never>, Record<string, never>>;
|
|
401
473
|
//#endregion
|
|
402
474
|
//#region src/extensions/hard-break.d.ts
|
|
403
|
-
declare const HardBreak: EmailNode<
|
|
475
|
+
declare const HardBreak: EmailNode<HardBreakOptions, any>;
|
|
404
476
|
//#endregion
|
|
405
477
|
//#region src/extensions/italic.d.ts
|
|
406
|
-
declare const Italic: EmailMark<
|
|
478
|
+
declare const Italic: EmailMark<ItalicOptions, any>;
|
|
407
479
|
//#endregion
|
|
408
480
|
//#region src/extensions/list-item.d.ts
|
|
409
|
-
declare const ListItem: EmailNode<
|
|
481
|
+
declare const ListItem: EmailNode<ListItemOptions, any>;
|
|
410
482
|
//#endregion
|
|
411
483
|
//#region src/extensions/ordered-list.d.ts
|
|
412
|
-
declare const OrderedList: EmailNode<
|
|
484
|
+
declare const OrderedList: EmailNode<OrderedListOptions, any>;
|
|
413
485
|
//#endregion
|
|
414
486
|
//#region src/extensions/paragraph.d.ts
|
|
415
|
-
declare const Paragraph: EmailNode<
|
|
416
|
-
//#endregion
|
|
417
|
-
//#region src/extensions/placeholder.d.ts
|
|
418
|
-
interface PlaceholderOptions {
|
|
419
|
-
placeholder?: string | ((props: {
|
|
420
|
-
node: Node$1;
|
|
421
|
-
}) => string);
|
|
422
|
-
includeChildren?: boolean;
|
|
423
|
-
}
|
|
424
|
-
declare const Placeholder: _tiptap_core6.Extension<_tiptap_extensions1.PlaceholderOptions, any>;
|
|
487
|
+
declare const Paragraph: EmailNode<ParagraphOptions, any>;
|
|
425
488
|
//#endregion
|
|
426
489
|
//#region src/extensions/preserved-style.d.ts
|
|
427
490
|
declare const PreservedStyle: EmailMark<Record<string, never>, Record<string, never>>;
|
|
@@ -433,86 +496,46 @@ declare const PreservedStyle: EmailMark<Record<string, never>, Record<string, ne
|
|
|
433
496
|
declare function processStylesForUnlink(styleString: string | null | undefined): string | null;
|
|
434
497
|
//#endregion
|
|
435
498
|
//#region src/extensions/strike.d.ts
|
|
436
|
-
declare const Strike: EmailMark<
|
|
499
|
+
declare const Strike: EmailMark<StrikeOptions, any>;
|
|
437
500
|
//#endregion
|
|
438
501
|
//#region src/extensions/index.d.ts
|
|
439
|
-
type
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
MaxNesting: Extension<MaxNestingOptions, any>;
|
|
473
|
-
};
|
|
474
|
-
type StarterKitOptions = { [Key in keyof StarterKitExtensionMap]: StarterKitExtensionMap[Key] extends Extendable<infer Options> ? Partial<Options> | false : never } & {
|
|
502
|
+
type StarterKitOptions = {
|
|
503
|
+
CodeBlockPrism: Partial<CodeBlockPrismOptions> | false;
|
|
504
|
+
Code: Partial<CodeOptions> | false;
|
|
505
|
+
Paragraph: Partial<ParagraphOptions> | false;
|
|
506
|
+
BulletList: Partial<BulletListOptions> | false;
|
|
507
|
+
OrderedList: Partial<OrderedListOptions> | false;
|
|
508
|
+
Blockquote: Partial<BlockquoteOptions> | false;
|
|
509
|
+
ListItem: Partial<ListItemOptions> | false;
|
|
510
|
+
HardBreak: Partial<HardBreakOptions> | false;
|
|
511
|
+
Italic: Partial<ItalicOptions> | false;
|
|
512
|
+
Placeholder: Partial<PlaceholderOptions> | false;
|
|
513
|
+
PreviewText: Partial<PreviewTextOptions> | false;
|
|
514
|
+
Bold: Partial<BoldOptions> | false;
|
|
515
|
+
Strike: Partial<StrikeOptions> | false;
|
|
516
|
+
Heading: Partial<HeadingOptions> | false;
|
|
517
|
+
Divider: Partial<DividerOptions> | false;
|
|
518
|
+
Link: Partial<LinkOptions> | false;
|
|
519
|
+
Sup: Partial<SupOptions> | false;
|
|
520
|
+
Uppercase: Partial<UppercaseOptions> | false;
|
|
521
|
+
PreservedStyle: Partial<Record<string, never>> | false;
|
|
522
|
+
Table: Partial<TableOptions> | false;
|
|
523
|
+
TableRow: Partial<TableRowOptions> | false;
|
|
524
|
+
TableCell: Partial<TableCellOptions> | false;
|
|
525
|
+
TableHeader: Partial<Record<string, any>> | false;
|
|
526
|
+
Body: Partial<BodyOptions> | false;
|
|
527
|
+
Div: Partial<DivOptions> | false;
|
|
528
|
+
Button: Partial<EditorButtonOptions> | false;
|
|
529
|
+
Section: Partial<SectionOptions> | false;
|
|
530
|
+
GlobalContent: Partial<GlobalContentOptions> | false;
|
|
531
|
+
AlignmentAttribute: Partial<AlignmentOptions> | false;
|
|
532
|
+
StyleAttribute: Partial<StyleAttributeOptions> | false;
|
|
533
|
+
ClassAttribute: Partial<ClassAttributeOptions> | false;
|
|
534
|
+
MaxNesting: Partial<MaxNestingOptions> | false;
|
|
475
535
|
TiptapStarterKit: Partial<StarterKitOptions$1> | false;
|
|
476
536
|
};
|
|
477
537
|
declare const StarterKit: Extension<StarterKitOptions, any>;
|
|
478
538
|
//#endregion
|
|
479
|
-
//#region src/core/create-paste-handler.d.ts
|
|
480
|
-
type PasteHandler = (payload: string | File, view: EditorView) => boolean;
|
|
481
|
-
type UploadImageHandler = (file: File, view: EditorView, pos: number, preserveAttributes?: {
|
|
482
|
-
width?: string;
|
|
483
|
-
height?: string;
|
|
484
|
-
alignment?: string;
|
|
485
|
-
href?: string;
|
|
486
|
-
}) => void | Promise<void>;
|
|
487
|
-
//#endregion
|
|
488
|
-
//#region src/core/use-editor.d.ts
|
|
489
|
-
declare function useEditor({
|
|
490
|
-
content,
|
|
491
|
-
extensions,
|
|
492
|
-
onUpdate,
|
|
493
|
-
onPaste,
|
|
494
|
-
onUploadImage,
|
|
495
|
-
onReady,
|
|
496
|
-
editable,
|
|
497
|
-
...rest
|
|
498
|
-
}: {
|
|
499
|
-
content: Content;
|
|
500
|
-
extensions?: Extensions;
|
|
501
|
-
onUpdate?: (editor: Editor, transaction: {
|
|
502
|
-
getMeta: (key: string) => unknown;
|
|
503
|
-
}) => void;
|
|
504
|
-
onPaste?: PasteHandler;
|
|
505
|
-
onUploadImage?: UploadImageHandler;
|
|
506
|
-
onReady?: (editor: Editor | null) => void;
|
|
507
|
-
editable?: boolean;
|
|
508
|
-
} & UseEditorOptions): {
|
|
509
|
-
editor: Editor;
|
|
510
|
-
isEditorEmpty: boolean;
|
|
511
|
-
extensions: (_tiptap_core6.AnyExtension | _tiptap_core6.Extension<StarterKitOptions, any> | _tiptap_core6.Extension<_tiptap_extensions1.UndoRedoOptions, any>)[];
|
|
512
|
-
contentError: Error | null;
|
|
513
|
-
isCollaborative: boolean;
|
|
514
|
-
};
|
|
515
|
-
//#endregion
|
|
516
539
|
//#region src/ui/bubble-menu/create-mark-bubble-item.d.ts
|
|
517
540
|
interface PreWiredItemProps {
|
|
518
541
|
className?: string;
|
|
@@ -524,19 +547,19 @@ interface PreWiredItemProps {
|
|
|
524
547
|
declare function BubbleMenuAlignCenter({
|
|
525
548
|
className,
|
|
526
549
|
children
|
|
527
|
-
}: PreWiredItemProps):
|
|
550
|
+
}: PreWiredItemProps): react_jsx_runtime8.JSX.Element;
|
|
528
551
|
//#endregion
|
|
529
552
|
//#region src/ui/bubble-menu/align-left.d.ts
|
|
530
553
|
declare function BubbleMenuAlignLeft({
|
|
531
554
|
className,
|
|
532
555
|
children
|
|
533
|
-
}: PreWiredItemProps):
|
|
556
|
+
}: PreWiredItemProps): react_jsx_runtime8.JSX.Element;
|
|
534
557
|
//#endregion
|
|
535
558
|
//#region src/ui/bubble-menu/align-right.d.ts
|
|
536
559
|
declare function BubbleMenuAlignRight({
|
|
537
560
|
className,
|
|
538
561
|
children
|
|
539
|
-
}: PreWiredItemProps):
|
|
562
|
+
}: PreWiredItemProps): react_jsx_runtime8.JSX.Element;
|
|
540
563
|
//#endregion
|
|
541
564
|
//#region src/ui/bubble-menu/default.d.ts
|
|
542
565
|
type ExcludableItem$3 = 'bold' | 'italic' | 'underline' | 'strike' | 'code' | 'uppercase' | 'align-left' | 'align-center' | 'align-right' | 'node-selector' | 'link-selector';
|
|
@@ -561,7 +584,7 @@ declare function BubbleMenuDefault({
|
|
|
561
584
|
offset,
|
|
562
585
|
onHide,
|
|
563
586
|
className
|
|
564
|
-
}: BubbleMenuDefaultProps):
|
|
587
|
+
}: BubbleMenuDefaultProps): react_jsx_runtime8.JSX.Element;
|
|
565
588
|
//#endregion
|
|
566
589
|
//#region src/ui/bubble-menu/group.d.ts
|
|
567
590
|
interface BubbleMenuItemGroupProps {
|
|
@@ -571,7 +594,7 @@ interface BubbleMenuItemGroupProps {
|
|
|
571
594
|
declare function BubbleMenuItemGroup({
|
|
572
595
|
className,
|
|
573
596
|
children
|
|
574
|
-
}: BubbleMenuItemGroupProps):
|
|
597
|
+
}: BubbleMenuItemGroupProps): react_jsx_runtime8.JSX.Element;
|
|
575
598
|
//#endregion
|
|
576
599
|
//#region src/ui/bubble-menu/item.d.ts
|
|
577
600
|
interface BubbleMenuItemProps extends React$1.ComponentProps<'button'> {
|
|
@@ -589,7 +612,7 @@ declare function BubbleMenuItem({
|
|
|
589
612
|
className,
|
|
590
613
|
children,
|
|
591
614
|
...rest
|
|
592
|
-
}: BubbleMenuItemProps):
|
|
615
|
+
}: BubbleMenuItemProps): react_jsx_runtime8.JSX.Element;
|
|
593
616
|
//#endregion
|
|
594
617
|
//#region src/ui/bubble-menu/link-selector.d.ts
|
|
595
618
|
interface BubbleMenuLinkSelectorProps {
|
|
@@ -618,7 +641,7 @@ declare function BubbleMenuLinkSelector({
|
|
|
618
641
|
children,
|
|
619
642
|
open: controlledOpen,
|
|
620
643
|
onOpenChange
|
|
621
|
-
}: BubbleMenuLinkSelectorProps):
|
|
644
|
+
}: BubbleMenuLinkSelectorProps): react_jsx_runtime8.JSX.Element | null;
|
|
622
645
|
//#endregion
|
|
623
646
|
//#region src/ui/bubble-menu/node-selector.d.ts
|
|
624
647
|
type NodeType = 'Text' | 'Title' | 'Subtitle' | 'Heading' | 'Bullet List' | 'Numbered List' | 'Quote' | 'Code';
|
|
@@ -644,7 +667,7 @@ declare function NodeSelectorRoot({
|
|
|
644
667
|
onOpenChange,
|
|
645
668
|
className,
|
|
646
669
|
children
|
|
647
|
-
}: NodeSelectorRootProps):
|
|
670
|
+
}: NodeSelectorRootProps): react_jsx_runtime8.JSX.Element | null;
|
|
648
671
|
interface NodeSelectorTriggerProps {
|
|
649
672
|
className?: string;
|
|
650
673
|
children?: React$1.ReactNode;
|
|
@@ -652,7 +675,7 @@ interface NodeSelectorTriggerProps {
|
|
|
652
675
|
declare function NodeSelectorTrigger({
|
|
653
676
|
className,
|
|
654
677
|
children
|
|
655
|
-
}: NodeSelectorTriggerProps):
|
|
678
|
+
}: NodeSelectorTriggerProps): react_jsx_runtime8.JSX.Element;
|
|
656
679
|
interface NodeSelectorContentProps {
|
|
657
680
|
className?: string;
|
|
658
681
|
/** Popover alignment (default: "start") */
|
|
@@ -665,7 +688,7 @@ declare function NodeSelectorContent({
|
|
|
665
688
|
className,
|
|
666
689
|
align,
|
|
667
690
|
children
|
|
668
|
-
}: NodeSelectorContentProps):
|
|
691
|
+
}: NodeSelectorContentProps): react_jsx_runtime8.JSX.Element;
|
|
669
692
|
interface BubbleMenuNodeSelectorProps {
|
|
670
693
|
/** Block types to exclude */
|
|
671
694
|
omit?: string[];
|
|
@@ -683,7 +706,7 @@ declare function BubbleMenuNodeSelector({
|
|
|
683
706
|
triggerContent,
|
|
684
707
|
open,
|
|
685
708
|
onOpenChange
|
|
686
|
-
}: BubbleMenuNodeSelectorProps):
|
|
709
|
+
}: BubbleMenuNodeSelectorProps): react_jsx_runtime8.JSX.Element;
|
|
687
710
|
//#endregion
|
|
688
711
|
//#region src/ui/bubble-menu/root.d.ts
|
|
689
712
|
interface BubbleMenuRootProps {
|
|
@@ -706,7 +729,7 @@ declare function BubbleMenuRoot({
|
|
|
706
729
|
onHide,
|
|
707
730
|
className,
|
|
708
731
|
children
|
|
709
|
-
}: BubbleMenuRootProps):
|
|
732
|
+
}: BubbleMenuRootProps): react_jsx_runtime8.JSX.Element | null;
|
|
710
733
|
//#endregion
|
|
711
734
|
//#region src/ui/bubble-menu/separator.d.ts
|
|
712
735
|
interface BubbleMenuSeparatorProps {
|
|
@@ -714,14 +737,14 @@ interface BubbleMenuSeparatorProps {
|
|
|
714
737
|
}
|
|
715
738
|
declare function BubbleMenuSeparator({
|
|
716
739
|
className
|
|
717
|
-
}: BubbleMenuSeparatorProps):
|
|
740
|
+
}: BubbleMenuSeparatorProps): react_jsx_runtime8.JSX.Element;
|
|
718
741
|
//#endregion
|
|
719
742
|
//#region src/ui/bubble-menu/bold.d.ts
|
|
720
743
|
declare const BubbleMenuBold: {
|
|
721
744
|
({
|
|
722
745
|
className,
|
|
723
746
|
children
|
|
724
|
-
}: PreWiredItemProps):
|
|
747
|
+
}: PreWiredItemProps): react_jsx_runtime8.JSX.Element;
|
|
725
748
|
displayName: string;
|
|
726
749
|
};
|
|
727
750
|
//#endregion
|
|
@@ -730,7 +753,7 @@ declare const BubbleMenuCode: {
|
|
|
730
753
|
({
|
|
731
754
|
className,
|
|
732
755
|
children
|
|
733
|
-
}: PreWiredItemProps):
|
|
756
|
+
}: PreWiredItemProps): react_jsx_runtime8.JSX.Element;
|
|
734
757
|
displayName: string;
|
|
735
758
|
};
|
|
736
759
|
//#endregion
|
|
@@ -739,7 +762,7 @@ declare const BubbleMenuItalic: {
|
|
|
739
762
|
({
|
|
740
763
|
className,
|
|
741
764
|
children
|
|
742
|
-
}: PreWiredItemProps):
|
|
765
|
+
}: PreWiredItemProps): react_jsx_runtime8.JSX.Element;
|
|
743
766
|
displayName: string;
|
|
744
767
|
};
|
|
745
768
|
//#endregion
|
|
@@ -748,7 +771,7 @@ declare const BubbleMenuStrike: {
|
|
|
748
771
|
({
|
|
749
772
|
className,
|
|
750
773
|
children
|
|
751
|
-
}: PreWiredItemProps):
|
|
774
|
+
}: PreWiredItemProps): react_jsx_runtime8.JSX.Element;
|
|
752
775
|
displayName: string;
|
|
753
776
|
};
|
|
754
777
|
//#endregion
|
|
@@ -757,7 +780,7 @@ declare const BubbleMenuUnderline: {
|
|
|
757
780
|
({
|
|
758
781
|
className,
|
|
759
782
|
children
|
|
760
|
-
}: PreWiredItemProps):
|
|
783
|
+
}: PreWiredItemProps): react_jsx_runtime8.JSX.Element;
|
|
761
784
|
displayName: string;
|
|
762
785
|
};
|
|
763
786
|
//#endregion
|
|
@@ -766,7 +789,7 @@ declare const BubbleMenuUppercase: {
|
|
|
766
789
|
({
|
|
767
790
|
className,
|
|
768
791
|
children
|
|
769
|
-
}: PreWiredItemProps):
|
|
792
|
+
}: PreWiredItemProps): react_jsx_runtime8.JSX.Element;
|
|
770
793
|
displayName: string;
|
|
771
794
|
};
|
|
772
795
|
//#endregion
|
|
@@ -780,42 +803,42 @@ declare const BubbleMenu: {
|
|
|
780
803
|
({
|
|
781
804
|
className,
|
|
782
805
|
children
|
|
783
|
-
}: PreWiredItemProps):
|
|
806
|
+
}: PreWiredItemProps): react_jsx_runtime8.JSX.Element;
|
|
784
807
|
displayName: string;
|
|
785
808
|
};
|
|
786
809
|
readonly Italic: {
|
|
787
810
|
({
|
|
788
811
|
className,
|
|
789
812
|
children
|
|
790
|
-
}: PreWiredItemProps):
|
|
813
|
+
}: PreWiredItemProps): react_jsx_runtime8.JSX.Element;
|
|
791
814
|
displayName: string;
|
|
792
815
|
};
|
|
793
816
|
readonly Underline: {
|
|
794
817
|
({
|
|
795
818
|
className,
|
|
796
819
|
children
|
|
797
|
-
}: PreWiredItemProps):
|
|
820
|
+
}: PreWiredItemProps): react_jsx_runtime8.JSX.Element;
|
|
798
821
|
displayName: string;
|
|
799
822
|
};
|
|
800
823
|
readonly Strike: {
|
|
801
824
|
({
|
|
802
825
|
className,
|
|
803
826
|
children
|
|
804
|
-
}: PreWiredItemProps):
|
|
827
|
+
}: PreWiredItemProps): react_jsx_runtime8.JSX.Element;
|
|
805
828
|
displayName: string;
|
|
806
829
|
};
|
|
807
830
|
readonly Code: {
|
|
808
831
|
({
|
|
809
832
|
className,
|
|
810
833
|
children
|
|
811
|
-
}: PreWiredItemProps):
|
|
834
|
+
}: PreWiredItemProps): react_jsx_runtime8.JSX.Element;
|
|
812
835
|
displayName: string;
|
|
813
836
|
};
|
|
814
837
|
readonly Uppercase: {
|
|
815
838
|
({
|
|
816
839
|
className,
|
|
817
840
|
children
|
|
818
|
-
}: PreWiredItemProps):
|
|
841
|
+
}: PreWiredItemProps): react_jsx_runtime8.JSX.Element;
|
|
819
842
|
displayName: string;
|
|
820
843
|
};
|
|
821
844
|
readonly AlignLeft: typeof BubbleMenuAlignLeft;
|
|
@@ -845,7 +868,7 @@ declare function ButtonBubbleMenuDefault({
|
|
|
845
868
|
offset,
|
|
846
869
|
onHide,
|
|
847
870
|
className
|
|
848
|
-
}: ButtonBubbleMenuDefaultProps):
|
|
871
|
+
}: ButtonBubbleMenuDefaultProps): react_jsx_runtime8.JSX.Element;
|
|
849
872
|
//#endregion
|
|
850
873
|
//#region src/ui/button-bubble-menu/edit-link.d.ts
|
|
851
874
|
interface ButtonBubbleMenuEditLinkProps extends Omit<React$1.ComponentProps<'button'>, 'type'> {}
|
|
@@ -855,7 +878,7 @@ declare function ButtonBubbleMenuEditLink({
|
|
|
855
878
|
onClick,
|
|
856
879
|
onMouseDown,
|
|
857
880
|
...rest
|
|
858
|
-
}: ButtonBubbleMenuEditLinkProps):
|
|
881
|
+
}: ButtonBubbleMenuEditLinkProps): react_jsx_runtime8.JSX.Element;
|
|
859
882
|
//#endregion
|
|
860
883
|
//#region src/ui/button-bubble-menu/root.d.ts
|
|
861
884
|
interface ButtonBubbleMenuRootProps {
|
|
@@ -875,14 +898,14 @@ declare function ButtonBubbleMenuRoot({
|
|
|
875
898
|
offset,
|
|
876
899
|
className,
|
|
877
900
|
children
|
|
878
|
-
}: ButtonBubbleMenuRootProps):
|
|
901
|
+
}: ButtonBubbleMenuRootProps): react_jsx_runtime8.JSX.Element | null;
|
|
879
902
|
//#endregion
|
|
880
903
|
//#region src/ui/button-bubble-menu/toolbar.d.ts
|
|
881
904
|
interface ButtonBubbleMenuToolbarProps extends React$1.ComponentProps<'div'> {}
|
|
882
905
|
declare function ButtonBubbleMenuToolbar({
|
|
883
906
|
children,
|
|
884
907
|
...rest
|
|
885
|
-
}: ButtonBubbleMenuToolbarProps):
|
|
908
|
+
}: ButtonBubbleMenuToolbarProps): react_jsx_runtime8.JSX.Element | null;
|
|
886
909
|
//#endregion
|
|
887
910
|
//#region src/ui/button-bubble-menu/context.d.ts
|
|
888
911
|
interface ButtonBubbleMenuContextValue {
|
|
@@ -915,7 +938,7 @@ declare function ImageBubbleMenuDefault({
|
|
|
915
938
|
offset,
|
|
916
939
|
onHide,
|
|
917
940
|
className
|
|
918
|
-
}: ImageBubbleMenuDefaultProps):
|
|
941
|
+
}: ImageBubbleMenuDefaultProps): react_jsx_runtime8.JSX.Element;
|
|
919
942
|
//#endregion
|
|
920
943
|
//#region src/ui/image-bubble-menu/edit-link.d.ts
|
|
921
944
|
interface ImageBubbleMenuEditLinkProps extends Omit<React$1.ComponentProps<'button'>, 'type'> {}
|
|
@@ -925,7 +948,7 @@ declare function ImageBubbleMenuEditLink({
|
|
|
925
948
|
onClick,
|
|
926
949
|
onMouseDown,
|
|
927
950
|
...rest
|
|
928
|
-
}: ImageBubbleMenuEditLinkProps):
|
|
951
|
+
}: ImageBubbleMenuEditLinkProps): react_jsx_runtime8.JSX.Element;
|
|
929
952
|
//#endregion
|
|
930
953
|
//#region src/ui/image-bubble-menu/root.d.ts
|
|
931
954
|
interface ImageBubbleMenuRootProps {
|
|
@@ -945,14 +968,14 @@ declare function ImageBubbleMenuRoot({
|
|
|
945
968
|
offset,
|
|
946
969
|
className,
|
|
947
970
|
children
|
|
948
|
-
}: ImageBubbleMenuRootProps):
|
|
971
|
+
}: ImageBubbleMenuRootProps): react_jsx_runtime8.JSX.Element | null;
|
|
949
972
|
//#endregion
|
|
950
973
|
//#region src/ui/image-bubble-menu/toolbar.d.ts
|
|
951
974
|
interface ImageBubbleMenuToolbarProps extends React$1.ComponentProps<'div'> {}
|
|
952
975
|
declare function ImageBubbleMenuToolbar({
|
|
953
976
|
children,
|
|
954
977
|
...rest
|
|
955
|
-
}: ImageBubbleMenuToolbarProps):
|
|
978
|
+
}: ImageBubbleMenuToolbarProps): react_jsx_runtime8.JSX.Element | null;
|
|
956
979
|
//#endregion
|
|
957
980
|
//#region src/ui/image-bubble-menu/context.d.ts
|
|
958
981
|
interface ImageBubbleMenuContextValue {
|
|
@@ -991,7 +1014,7 @@ declare function LinkBubbleMenuDefault({
|
|
|
991
1014
|
validateUrl,
|
|
992
1015
|
onLinkApply,
|
|
993
1016
|
onLinkRemove
|
|
994
|
-
}: LinkBubbleMenuDefaultProps):
|
|
1017
|
+
}: LinkBubbleMenuDefaultProps): react_jsx_runtime8.JSX.Element;
|
|
995
1018
|
//#endregion
|
|
996
1019
|
//#region src/ui/link-bubble-menu/edit-link.d.ts
|
|
997
1020
|
interface LinkBubbleMenuEditLinkProps extends Omit<React$1.ComponentProps<'button'>, 'type'> {}
|
|
@@ -1001,7 +1024,7 @@ declare function LinkBubbleMenuEditLink({
|
|
|
1001
1024
|
onClick,
|
|
1002
1025
|
onMouseDown,
|
|
1003
1026
|
...rest
|
|
1004
|
-
}: LinkBubbleMenuEditLinkProps):
|
|
1027
|
+
}: LinkBubbleMenuEditLinkProps): react_jsx_runtime8.JSX.Element;
|
|
1005
1028
|
//#endregion
|
|
1006
1029
|
//#region src/ui/link-bubble-menu/form.d.ts
|
|
1007
1030
|
interface LinkBubbleMenuFormProps {
|
|
@@ -1021,7 +1044,7 @@ declare function LinkBubbleMenuForm({
|
|
|
1021
1044
|
onLinkApply,
|
|
1022
1045
|
onLinkRemove,
|
|
1023
1046
|
children
|
|
1024
|
-
}: LinkBubbleMenuFormProps):
|
|
1047
|
+
}: LinkBubbleMenuFormProps): react_jsx_runtime8.JSX.Element | null;
|
|
1025
1048
|
//#endregion
|
|
1026
1049
|
//#region src/ui/link-bubble-menu/open-link.d.ts
|
|
1027
1050
|
interface LinkBubbleMenuOpenLinkProps extends Omit<React$1.ComponentProps<'a'>, 'href' | 'target' | 'rel'> {}
|
|
@@ -1029,7 +1052,7 @@ declare function LinkBubbleMenuOpenLink({
|
|
|
1029
1052
|
className,
|
|
1030
1053
|
children,
|
|
1031
1054
|
...rest
|
|
1032
|
-
}: LinkBubbleMenuOpenLinkProps):
|
|
1055
|
+
}: LinkBubbleMenuOpenLinkProps): react_jsx_runtime8.JSX.Element;
|
|
1033
1056
|
//#endregion
|
|
1034
1057
|
//#region src/ui/link-bubble-menu/root.d.ts
|
|
1035
1058
|
interface LinkBubbleMenuRootProps {
|
|
@@ -1049,14 +1072,14 @@ declare function LinkBubbleMenuRoot({
|
|
|
1049
1072
|
offset,
|
|
1050
1073
|
className,
|
|
1051
1074
|
children
|
|
1052
|
-
}: LinkBubbleMenuRootProps):
|
|
1075
|
+
}: LinkBubbleMenuRootProps): react_jsx_runtime8.JSX.Element | null;
|
|
1053
1076
|
//#endregion
|
|
1054
1077
|
//#region src/ui/link-bubble-menu/toolbar.d.ts
|
|
1055
1078
|
interface LinkBubbleMenuToolbarProps extends React$1.ComponentProps<'div'> {}
|
|
1056
1079
|
declare function LinkBubbleMenuToolbar({
|
|
1057
1080
|
children,
|
|
1058
1081
|
...rest
|
|
1059
|
-
}: LinkBubbleMenuToolbarProps):
|
|
1082
|
+
}: LinkBubbleMenuToolbarProps): react_jsx_runtime8.JSX.Element | null;
|
|
1060
1083
|
//#endregion
|
|
1061
1084
|
//#region src/ui/link-bubble-menu/unlink.d.ts
|
|
1062
1085
|
interface LinkBubbleMenuUnlinkProps extends Omit<React$1.ComponentProps<'button'>, 'type'> {}
|
|
@@ -1066,7 +1089,7 @@ declare function LinkBubbleMenuUnlink({
|
|
|
1066
1089
|
onClick,
|
|
1067
1090
|
onMouseDown,
|
|
1068
1091
|
...rest
|
|
1069
|
-
}: LinkBubbleMenuUnlinkProps):
|
|
1092
|
+
}: LinkBubbleMenuUnlinkProps): react_jsx_runtime8.JSX.Element;
|
|
1070
1093
|
//#endregion
|
|
1071
1094
|
//#region src/ui/link-bubble-menu/context.d.ts
|
|
1072
1095
|
interface LinkBubbleMenuContextValue {
|
|
@@ -1125,7 +1148,7 @@ declare function CommandList({
|
|
|
1125
1148
|
command,
|
|
1126
1149
|
query,
|
|
1127
1150
|
ref
|
|
1128
|
-
}: CommandListProps):
|
|
1151
|
+
}: CommandListProps): react_jsx_runtime8.JSX.Element;
|
|
1129
1152
|
//#endregion
|
|
1130
1153
|
//#region src/ui/slash-command/commands.d.ts
|
|
1131
1154
|
declare const TEXT: SlashCommandItem;
|
|
@@ -1149,7 +1172,7 @@ declare function createSlashCommand(options?: {
|
|
|
1149
1172
|
items?: SlashCommandItem[];
|
|
1150
1173
|
filterItems?: (items: SlashCommandItem[], query: string, editor: Editor) => SlashCommandItem[];
|
|
1151
1174
|
component?: CommandListComponent;
|
|
1152
|
-
}):
|
|
1175
|
+
}): _tiptap_core0.Extension<any, any>;
|
|
1153
1176
|
//#endregion
|
|
1154
1177
|
//#region src/ui/slash-command/search.d.ts
|
|
1155
1178
|
declare function scoreItem(item: SearchableItem, query: string): number;
|
|
@@ -1160,10 +1183,10 @@ declare function isInsideNode(editor: Editor, type: string): boolean;
|
|
|
1160
1183
|
declare function isAtMaxColumnsDepth(editor: Editor): boolean;
|
|
1161
1184
|
//#endregion
|
|
1162
1185
|
//#region src/ui/slash-command/index.d.ts
|
|
1163
|
-
declare const SlashCommand:
|
|
1186
|
+
declare const SlashCommand: _tiptap_core0.Extension<any, any>;
|
|
1164
1187
|
//#endregion
|
|
1165
1188
|
//#region src/utils/set-text-alignment.d.ts
|
|
1166
1189
|
declare function setTextAlignment(editor: Editor, alignment: string): void;
|
|
1167
1190
|
//#endregion
|
|
1168
|
-
export { AlignmentAttribute, AlignmentOptions, BULLET_LIST, BUTTON, Blockquote, Body, BodyOptions, Bold, BoldOptions, BubbleMenu, BubbleMenuAlignCenter, BubbleMenuAlignLeft, BubbleMenuAlignRight, BubbleMenuBold, BubbleMenuCode, BubbleMenuDefault, type BubbleMenuDefaultProps, BubbleMenuItalic, BubbleMenuItem, BubbleMenuItemGroup, type BubbleMenuItemGroupProps, type BubbleMenuItemProps, BubbleMenuLinkSelector, type BubbleMenuLinkSelectorProps, BubbleMenuNodeSelector, type BubbleMenuNodeSelectorProps, BubbleMenuRoot, type BubbleMenuRootProps, BubbleMenuSeparator, type BubbleMenuSeparatorProps, BubbleMenuStrike, BubbleMenuUnderline, BubbleMenuUppercase, BulletList, Button, ButtonBubbleMenu, ButtonBubbleMenuDefault, type ButtonBubbleMenuDefaultProps, ButtonBubbleMenuEditLink, type ButtonBubbleMenuEditLinkProps, ButtonBubbleMenuRoot, type ButtonBubbleMenuRootProps, ButtonBubbleMenuToolbar, type ButtonBubbleMenuToolbarProps, CODE, COLUMN_PARENT_TYPES, ClassAttribute, ClassAttributeOptions, Code, CodeBlockPrism, CodeBlockPrismOptions, ColumnsColumn, CommandList, type CommandListComponent, type CommandListProps, type CommandListRef, DIVIDER, Div, DivOptions, EditorButtonOptions, EditorEventHandler, EditorEventMap, EditorEventName, EditorEventSubscription, EmailNode, EmailNodeConfig, FOUR_COLUMNS, FourColumns, GlobalContent, GlobalContentOptions, H1, H2, H3, HardBreak, ImageBubbleMenu, ImageBubbleMenuDefault, type ImageBubbleMenuDefaultProps, ImageBubbleMenuEditLink, type ImageBubbleMenuEditLinkProps, ImageBubbleMenuRoot, type ImageBubbleMenuRootProps, ImageBubbleMenuToolbar, type ImageBubbleMenuToolbarProps, Italic, LinkBubbleMenu, LinkBubbleMenuDefault, type LinkBubbleMenuDefaultProps, LinkBubbleMenuEditLink, type LinkBubbleMenuEditLinkProps, LinkBubbleMenuForm, type LinkBubbleMenuFormProps, LinkBubbleMenuOpenLink, type LinkBubbleMenuOpenLinkProps, LinkBubbleMenuRoot, type LinkBubbleMenuRootProps, LinkBubbleMenuToolbar, type LinkBubbleMenuToolbarProps, LinkBubbleMenuUnlink, type LinkBubbleMenuUnlinkProps, ListItem, MAX_COLUMNS_DEPTH, MaxNesting, MaxNestingOptions, NUMBERED_LIST, NodeSelectorContent, type NodeSelectorContentProps, type NodeSelectorItem, NodeSelectorRoot, type NodeSelectorRootProps, NodeSelectorTrigger, type NodeSelectorTriggerProps, type NodeType, OrderedList, Paragraph, Placeholder, PlaceholderOptions, type PreWiredItemProps, PreservedStyle, PreviewText, PreviewTextOptions, QUOTE, RendererComponent, SECTION, type SearchableItem, Section, SectionOptions, SlashCommand, type SlashCommandItem, type SlashCommandProps, StarterKit, StarterKitOptions, Strike, StyleAttribute, StyleAttributeOptions, Sup, SupOptions, TEXT, THREE_COLUMNS, TWO_COLUMNS, Table, TableCell, TableCellOptions, TableHeader, TableOptions, TableRow, TableRowOptions, ThreeColumns, TwoColumns, Uppercase, UppercaseOptions, composeReactEmail, createSlashCommand, defaultSlashCommands, editorEventBus, filterAndRankItems, getColumnsDepth, getGlobalContent, isAtMaxColumnsDepth, isInsideNode, processStylesForUnlink, scoreItem, setTextAlignment, useButtonBubbleMenuContext, useEditor, useImageBubbleMenuContext, useLinkBubbleMenuContext };
|
|
1191
|
+
export { AlignmentAttribute, AlignmentOptions, BULLET_LIST, BUTTON, Blockquote, Body, BodyOptions, Bold, BoldOptions, BubbleMenu, BubbleMenuAlignCenter, BubbleMenuAlignLeft, BubbleMenuAlignRight, BubbleMenuBold, BubbleMenuCode, BubbleMenuDefault, type BubbleMenuDefaultProps, BubbleMenuItalic, BubbleMenuItem, BubbleMenuItemGroup, type BubbleMenuItemGroupProps, type BubbleMenuItemProps, BubbleMenuLinkSelector, type BubbleMenuLinkSelectorProps, BubbleMenuNodeSelector, type BubbleMenuNodeSelectorProps, BubbleMenuRoot, type BubbleMenuRootProps, BubbleMenuSeparator, type BubbleMenuSeparatorProps, BubbleMenuStrike, BubbleMenuUnderline, BubbleMenuUppercase, BulletList, Button, ButtonBubbleMenu, ButtonBubbleMenuDefault, type ButtonBubbleMenuDefaultProps, ButtonBubbleMenuEditLink, type ButtonBubbleMenuEditLinkProps, ButtonBubbleMenuRoot, type ButtonBubbleMenuRootProps, ButtonBubbleMenuToolbar, type ButtonBubbleMenuToolbarProps, CODE, COLUMN_PARENT_TYPES, ClassAttribute, ClassAttributeOptions, Code, CodeBlockPrism, CodeBlockPrismOptions, ColumnsColumn, CommandList, type CommandListComponent, type CommandListProps, type CommandListRef, DIVIDER, Div, DivOptions, Divider, DividerOptions, EditorButtonOptions, EditorEventHandler, EditorEventMap, EditorEventName, EditorEventSubscription, EmailNode, EmailNodeConfig, FOUR_COLUMNS, FourColumns, GlobalContent, GlobalContentOptions, H1, H2, H3, HardBreak, Heading, HeadingOptions, ImageBubbleMenu, ImageBubbleMenuDefault, type ImageBubbleMenuDefaultProps, ImageBubbleMenuEditLink, type ImageBubbleMenuEditLinkProps, ImageBubbleMenuRoot, type ImageBubbleMenuRootProps, ImageBubbleMenuToolbar, type ImageBubbleMenuToolbarProps, Italic, Link, LinkBubbleMenu, LinkBubbleMenuDefault, type LinkBubbleMenuDefaultProps, LinkBubbleMenuEditLink, type LinkBubbleMenuEditLinkProps, LinkBubbleMenuForm, type LinkBubbleMenuFormProps, LinkBubbleMenuOpenLink, type LinkBubbleMenuOpenLinkProps, LinkBubbleMenuRoot, type LinkBubbleMenuRootProps, LinkBubbleMenuToolbar, type LinkBubbleMenuToolbarProps, LinkBubbleMenuUnlink, type LinkBubbleMenuUnlinkProps, LinkOptions, ListItem, MAX_COLUMNS_DEPTH, MaxNesting, MaxNestingOptions, NUMBERED_LIST, NodeSelectorContent, type NodeSelectorContentProps, type NodeSelectorItem, NodeSelectorRoot, type NodeSelectorRootProps, NodeSelectorTrigger, type NodeSelectorTriggerProps, type NodeType, OrderedList, Paragraph, Placeholder, PlaceholderOptions, type PreWiredItemProps, PreservedStyle, PreviewText, PreviewTextOptions, QUOTE, RendererComponent, SECTION, type SearchableItem, Section, SectionOptions, SlashCommand, type SlashCommandItem, type SlashCommandProps, StarterKit, StarterKitOptions, Strike, StyleAttribute, StyleAttributeOptions, Sup, SupOptions, TEXT, THREE_COLUMNS, TWO_COLUMNS, Table, TableCell, TableCellOptions, TableHeader, TableOptions, TableRow, TableRowOptions, ThreeColumns, TwoColumns, Uppercase, UppercaseOptions, composeReactEmail, createSlashCommand, defaultSlashCommands, editorEventBus, filterAndRankItems, getColumnsDepth, getGlobalContent, isAtMaxColumnsDepth, isInsideNode, processStylesForUnlink, scoreItem, setTextAlignment, useButtonBubbleMenuContext, useEditor, useImageBubbleMenuContext, useLinkBubbleMenuContext };
|
|
1169
1192
|
//# sourceMappingURL=index.d.cts.map
|