@blocknote/core 0.13.0 → 0.13.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +6 -2
- package/dist/blocknote.js +5724 -2803
- package/dist/blocknote.js.map +1 -1
- package/dist/blocknote.umd.cjs +7 -7
- package/dist/blocknote.umd.cjs.map +1 -1
- package/dist/style.css +1 -1
- package/dist/webpack-stats.json +1 -1
- package/package.json +2 -2
- package/src/api/exporters/html/__snapshots__/file/basic/external.html +1 -0
- package/src/api/exporters/html/__snapshots__/file/basic/internal.html +1 -0
- package/src/api/exporters/html/__snapshots__/file/button/external.html +1 -0
- package/src/api/exporters/html/__snapshots__/file/button/internal.html +1 -0
- package/src/api/exporters/html/__snapshots__/file/nested/external.html +1 -0
- package/src/api/exporters/html/__snapshots__/file/nested/internal.html +1 -0
- package/src/api/exporters/html/__snapshots__/file/noCaption/external.html +1 -0
- package/src/api/exporters/html/__snapshots__/file/noCaption/internal.html +1 -0
- package/src/api/exporters/html/__snapshots__/file/noName/external.html +1 -0
- package/src/api/exporters/html/__snapshots__/file/noName/internal.html +1 -0
- package/src/api/exporters/html/__snapshots__/image/basic/external.html +1 -1
- package/src/api/exporters/html/__snapshots__/image/basic/internal.html +1 -1
- package/src/api/exporters/html/__snapshots__/image/button/external.html +1 -1
- package/src/api/exporters/html/__snapshots__/image/button/internal.html +1 -1
- package/src/api/exporters/html/__snapshots__/image/nested/external.html +1 -1
- package/src/api/exporters/html/__snapshots__/image/nested/internal.html +1 -1
- package/src/api/exporters/html/__snapshots__/image/noCaption/external.html +1 -0
- package/src/api/exporters/html/__snapshots__/image/noCaption/internal.html +1 -0
- package/src/api/exporters/html/__snapshots__/image/noName/external.html +1 -0
- package/src/api/exporters/html/__snapshots__/image/noName/internal.html +1 -0
- package/src/api/exporters/html/__snapshots__/image/noPreview/external.html +1 -0
- package/src/api/exporters/html/__snapshots__/image/noPreview/internal.html +1 -0
- package/src/api/exporters/html/__snapshots__/simpleFile/basic/external.html +1 -0
- package/src/api/exporters/html/__snapshots__/simpleFile/basic/internal.html +1 -0
- package/src/api/exporters/html/__snapshots__/simpleFile/button/external.html +1 -0
- package/src/api/exporters/html/__snapshots__/simpleFile/button/internal.html +1 -0
- package/src/api/exporters/html/__snapshots__/simpleFile/nested/external.html +1 -0
- package/src/api/exporters/html/__snapshots__/simpleFile/nested/internal.html +1 -0
- package/src/api/exporters/html/__snapshots__/simpleImage/basic/external.html +1 -1
- package/src/api/exporters/html/__snapshots__/simpleImage/basic/internal.html +1 -1
- package/src/api/exporters/html/__snapshots__/simpleImage/button/external.html +1 -1
- package/src/api/exporters/html/__snapshots__/simpleImage/button/internal.html +1 -1
- package/src/api/exporters/html/__snapshots__/simpleImage/nested/external.html +1 -1
- package/src/api/exporters/html/__snapshots__/simpleImage/nested/internal.html +1 -1
- package/src/api/exporters/html/__snapshots__/simpleImage/noCaption/external.html +1 -0
- package/src/api/exporters/html/__snapshots__/simpleImage/noCaption/internal.html +1 -0
- package/src/api/exporters/html/__snapshots__/simpleImage/noName/external.html +1 -0
- package/src/api/exporters/html/__snapshots__/simpleImage/noName/internal.html +1 -0
- package/src/api/exporters/html/__snapshots__/simpleImage/noPreview/external.html +1 -0
- package/src/api/exporters/html/__snapshots__/simpleImage/noPreview/internal.html +1 -0
- package/src/api/exporters/markdown/__snapshots__/file/basic/markdown.md +3 -0
- package/src/api/exporters/markdown/__snapshots__/file/button/markdown.md +1 -0
- package/src/api/exporters/markdown/__snapshots__/file/nested/markdown.md +7 -0
- package/src/api/exporters/markdown/__snapshots__/file/noCaption/markdown.md +1 -0
- package/src/api/exporters/markdown/__snapshots__/file/noName/markdown.md +3 -0
- package/src/api/exporters/markdown/__snapshots__/image/basic/markdown.md +1 -1
- package/src/api/exporters/markdown/__snapshots__/image/button/markdown.md +1 -1
- package/src/api/exporters/markdown/__snapshots__/image/nested/markdown.md +2 -2
- package/src/api/exporters/markdown/__snapshots__/image/noCaption/markdown.md +1 -0
- package/src/api/exporters/markdown/__snapshots__/image/noName/markdown.md +3 -0
- package/src/api/exporters/markdown/__snapshots__/image/noPreview/markdown.md +3 -0
- package/src/api/exporters/markdown/__snapshots__/simpleFile/basic/markdown.md +3 -0
- package/src/api/exporters/markdown/__snapshots__/simpleFile/button/markdown.md +1 -0
- package/src/api/exporters/markdown/__snapshots__/simpleFile/nested/markdown.md +7 -0
- package/src/api/exporters/markdown/__snapshots__/simpleImage/basic/markdown.md +3 -1
- package/src/api/exporters/markdown/__snapshots__/simpleImage/button/markdown.md +1 -0
- package/src/api/exporters/markdown/__snapshots__/simpleImage/nested/markdown.md +6 -2
- package/src/api/exporters/markdown/__snapshots__/simpleImage/noCaption/markdown.md +1 -0
- package/src/api/exporters/markdown/__snapshots__/simpleImage/noName/markdown.md +3 -0
- package/src/api/exporters/markdown/__snapshots__/simpleImage/noPreview/markdown.md +3 -0
- package/src/api/nodeConversions/__snapshots__/nodeConversions.test.ts.snap +212 -4
- package/src/api/parsers/html/__snapshots__/paste/parse-basic-block-types.json +3 -1
- package/src/api/parsers/html/__snapshots__/paste/parse-fake-image-caption.json +3 -1
- package/src/api/testUtil/cases/customBlocks.ts +79 -33
- package/src/api/testUtil/cases/customInlineContent.ts +1 -1
- package/src/api/testUtil/cases/customStyles.ts +1 -1
- package/src/api/testUtil/cases/defaultSchema.ts +114 -4
- package/src/blocks/AudioBlockContent/AudioBlockContent.ts +162 -0
- package/src/blocks/AudioBlockContent/audioBlockHelpers.ts +5 -0
- package/src/blocks/FileBlockContent/FileBlockContent.ts +121 -0
- package/src/blocks/FileBlockContent/fileBlockHelpers.ts +377 -0
- package/src/blocks/ImageBlockContent/ImageBlockContent.ts +135 -356
- package/src/blocks/ImageBlockContent/imageBlockHelpers.ts +6 -0
- package/src/blocks/VideoBlockContent/VideoBlockContent.ts +182 -0
- package/src/blocks/VideoBlockContent/videoBlockHelpers.ts +6 -0
- package/src/blocks/defaultBlockTypeGuards.ts +53 -1
- package/src/blocks/defaultBlocks.ts +8 -2
- package/src/editor/Block.css +67 -27
- package/src/editor/BlockNoteEditor.ts +14 -10
- package/src/editor/BlockNoteExtensions.ts +1 -1
- package/src/editor/BlockNoteSchema.ts +12 -3
- package/src/extensions/{ImagePanel/ImageToolbarPlugin.ts → FilePanel/FilePanelPlugin.ts} +22 -25
- package/src/extensions/FormattingToolbar/FormattingToolbarPlugin.ts +14 -2
- package/src/extensions/NonEditableBlocks/NonEditableBlockPlugin.ts +43 -12
- package/src/extensions/SuggestionMenu/getDefaultSlashMenuItems.ts +59 -2
- package/src/i18n/locales/en.ts +102 -11
- package/src/i18n/locales/fr.ts +289 -0
- package/src/i18n/locales/index.ts +8 -0
- package/src/i18n/locales/is.ts +288 -0
- package/src/i18n/locales/ja.ts +300 -0
- package/src/i18n/locales/ko.ts +292 -0
- package/src/i18n/locales/nl.ts +101 -8
- package/src/i18n/locales/pl.ts +280 -0
- package/src/i18n/locales/pt.ts +281 -0
- package/src/i18n/locales/vi.ts +281 -0
- package/src/i18n/locales/zh.ts +312 -0
- package/src/index.ts +9 -2
- package/src/pm-nodes/BlockContainer.ts +5 -3
- package/src/schema/blocks/createSpec.ts +1 -0
- package/src/schema/blocks/internal.ts +10 -0
- package/src/schema/blocks/types.ts +41 -5
- package/src/util/string.ts +12 -0
- package/types/src/api/testUtil/cases/customBlocks.d.ts +228 -42
- package/types/src/api/testUtil/cases/customInlineContent.d.ts +178 -4
- package/types/src/api/testUtil/cases/customStyles.d.ts +178 -4
- package/types/src/blocks/AudioBlockContent/AudioBlockContent.d.ts +104 -0
- package/types/src/blocks/AudioBlockContent/audioBlockHelpers.d.ts +3 -0
- package/types/src/blocks/FileBlockContent/FileBlockContent.d.ts +96 -0
- package/types/src/blocks/FileBlockContent/fileBlockHelpers.d.ts +30 -0
- package/types/src/blocks/ImageBlockContent/ImageBlockContent.d.ts +53 -14
- package/types/src/blocks/ImageBlockContent/imageBlockHelpers.d.ts +4 -0
- package/types/src/blocks/VideoBlockContent/VideoBlockContent.d.ts +132 -0
- package/types/src/blocks/VideoBlockContent/videoBlockHelpers.d.ts +4 -0
- package/types/src/blocks/defaultBlockTypeGuards.d.ts +6 -1
- package/types/src/blocks/defaultBlocks.d.ts +356 -8
- package/types/src/editor/BlockNoteEditor.d.ts +5 -5
- package/types/src/extensions/{ImagePanel/ImageToolbarPlugin.d.ts → FilePanel/FilePanelPlugin.d.ts} +9 -12
- package/types/src/i18n/locales/en.d.ts +49 -7
- package/types/src/i18n/locales/fr.d.ts +2 -0
- package/types/src/i18n/locales/index.d.ts +8 -0
- package/types/src/i18n/locales/is.d.ts +2 -0
- package/types/src/i18n/locales/ja.d.ts +2 -0
- package/types/src/i18n/locales/ko.d.ts +2 -0
- package/types/src/i18n/locales/pl.d.ts +2 -0
- package/types/src/i18n/locales/pt.d.ts +2 -0
- package/types/src/i18n/locales/vi.d.ts +2 -0
- package/types/src/i18n/locales/zh.d.ts +2 -0
- package/types/src/index.d.ts +8 -2
- package/types/src/schema/blocks/internal.d.ts +1 -1
- package/types/src/schema/blocks/types.d.ts +26 -1
- package/types/src/util/string.d.ts +1 -0
- /package/src/blocks/{ImageBlockContent → FileBlockContent}/uploadToTmpFilesDotOrg_DEV_ONLY.ts +0 -0
- /package/types/src/blocks/{ImageBlockContent → FileBlockContent}/uploadToTmpFilesDotOrg_DEV_ONLY.d.ts +0 -0
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { EditorTestCases } from "../index";
|
|
2
2
|
import { DefaultInlineContentSchema, DefaultStyleSchema } from "../../../blocks/defaultBlocks";
|
|
3
3
|
import { BlockNoteSchema } from "../../../editor/BlockNoteSchema";
|
|
4
|
-
declare const schema: BlockNoteSchema<import("
|
|
4
|
+
declare const schema: BlockNoteSchema<import("../../../schema").BlockSchemaFromSpecs<{
|
|
5
5
|
simpleImage: {
|
|
6
6
|
config: {
|
|
7
|
-
type:
|
|
7
|
+
type: string;
|
|
8
8
|
propSchema: {
|
|
9
9
|
textAlignment: {
|
|
10
10
|
default: "left";
|
|
@@ -13,20 +13,26 @@ declare const schema: BlockNoteSchema<import("../../..").BlockSchemaFromSpecs<{
|
|
|
13
13
|
backgroundColor: {
|
|
14
14
|
default: "default";
|
|
15
15
|
};
|
|
16
|
+
name: {
|
|
17
|
+
default: "";
|
|
18
|
+
};
|
|
16
19
|
url: {
|
|
17
20
|
default: "";
|
|
18
21
|
};
|
|
19
22
|
caption: {
|
|
20
23
|
default: "";
|
|
21
24
|
};
|
|
22
|
-
|
|
23
|
-
default:
|
|
25
|
+
showPreview: {
|
|
26
|
+
default: true;
|
|
27
|
+
};
|
|
28
|
+
previewWidth: {
|
|
29
|
+
default: number;
|
|
24
30
|
};
|
|
25
31
|
};
|
|
26
32
|
content: "none";
|
|
27
33
|
};
|
|
28
|
-
implementation: import("
|
|
29
|
-
type:
|
|
34
|
+
implementation: import("../../../schema").TiptapBlockImplementation<{
|
|
35
|
+
type: string;
|
|
30
36
|
propSchema: {
|
|
31
37
|
textAlignment: {
|
|
32
38
|
default: "left";
|
|
@@ -35,22 +41,28 @@ declare const schema: BlockNoteSchema<import("../../..").BlockSchemaFromSpecs<{
|
|
|
35
41
|
backgroundColor: {
|
|
36
42
|
default: "default";
|
|
37
43
|
};
|
|
44
|
+
name: {
|
|
45
|
+
default: "";
|
|
46
|
+
};
|
|
38
47
|
url: {
|
|
39
48
|
default: "";
|
|
40
49
|
};
|
|
41
50
|
caption: {
|
|
42
51
|
default: "";
|
|
43
52
|
};
|
|
44
|
-
|
|
45
|
-
default:
|
|
53
|
+
showPreview: {
|
|
54
|
+
default: true;
|
|
55
|
+
};
|
|
56
|
+
previewWidth: {
|
|
57
|
+
default: number;
|
|
46
58
|
};
|
|
47
59
|
};
|
|
48
60
|
content: "none";
|
|
49
|
-
}, any, import("
|
|
61
|
+
}, any, import("../../../schema").InlineContentSchema, import("../../../schema").StyleSchema>;
|
|
50
62
|
};
|
|
51
63
|
customParagraph: {
|
|
52
64
|
config: {
|
|
53
|
-
type:
|
|
65
|
+
type: string;
|
|
54
66
|
propSchema: {
|
|
55
67
|
backgroundColor: {
|
|
56
68
|
default: "default";
|
|
@@ -65,8 +77,8 @@ declare const schema: BlockNoteSchema<import("../../..").BlockSchemaFromSpecs<{
|
|
|
65
77
|
};
|
|
66
78
|
content: "inline";
|
|
67
79
|
};
|
|
68
|
-
implementation: import("
|
|
69
|
-
type:
|
|
80
|
+
implementation: import("../../../schema").TiptapBlockImplementation<{
|
|
81
|
+
type: string;
|
|
70
82
|
propSchema: {
|
|
71
83
|
backgroundColor: {
|
|
72
84
|
default: "default";
|
|
@@ -80,11 +92,11 @@ declare const schema: BlockNoteSchema<import("../../..").BlockSchemaFromSpecs<{
|
|
|
80
92
|
};
|
|
81
93
|
};
|
|
82
94
|
content: "inline";
|
|
83
|
-
}, any, import("
|
|
95
|
+
}, any, import("../../../schema").InlineContentSchema, import("../../../schema").StyleSchema>;
|
|
84
96
|
};
|
|
85
97
|
simpleCustomParagraph: {
|
|
86
98
|
config: {
|
|
87
|
-
type:
|
|
99
|
+
type: string;
|
|
88
100
|
propSchema: {
|
|
89
101
|
backgroundColor: {
|
|
90
102
|
default: "default";
|
|
@@ -99,8 +111,8 @@ declare const schema: BlockNoteSchema<import("../../..").BlockSchemaFromSpecs<{
|
|
|
99
111
|
};
|
|
100
112
|
content: "inline";
|
|
101
113
|
};
|
|
102
|
-
implementation: import("
|
|
103
|
-
type:
|
|
114
|
+
implementation: import("../../../schema").TiptapBlockImplementation<{
|
|
115
|
+
type: string;
|
|
104
116
|
propSchema: {
|
|
105
117
|
backgroundColor: {
|
|
106
118
|
default: "default";
|
|
@@ -114,7 +126,7 @@ declare const schema: BlockNoteSchema<import("../../..").BlockSchemaFromSpecs<{
|
|
|
114
126
|
};
|
|
115
127
|
};
|
|
116
128
|
content: "inline";
|
|
117
|
-
}, any, import("
|
|
129
|
+
}, any, import("../../../schema").InlineContentSchema, import("../../../schema").StyleSchema>;
|
|
118
130
|
};
|
|
119
131
|
paragraph: {
|
|
120
132
|
config: {
|
|
@@ -133,7 +145,7 @@ declare const schema: BlockNoteSchema<import("../../..").BlockSchemaFromSpecs<{
|
|
|
133
145
|
};
|
|
134
146
|
};
|
|
135
147
|
};
|
|
136
|
-
implementation: import("
|
|
148
|
+
implementation: import("../../../schema").TiptapBlockImplementation<{
|
|
137
149
|
type: "paragraph";
|
|
138
150
|
content: "inline";
|
|
139
151
|
propSchema: {
|
|
@@ -148,7 +160,7 @@ declare const schema: BlockNoteSchema<import("../../..").BlockSchemaFromSpecs<{
|
|
|
148
160
|
values: readonly ["left", "center", "right", "justify"];
|
|
149
161
|
};
|
|
150
162
|
};
|
|
151
|
-
}, any, import("
|
|
163
|
+
}, any, import("../../../schema").InlineContentSchema, import("../../../schema").StyleSchema>;
|
|
152
164
|
};
|
|
153
165
|
heading: {
|
|
154
166
|
config: {
|
|
@@ -171,7 +183,7 @@ declare const schema: BlockNoteSchema<import("../../..").BlockSchemaFromSpecs<{
|
|
|
171
183
|
};
|
|
172
184
|
};
|
|
173
185
|
};
|
|
174
|
-
implementation: import("
|
|
186
|
+
implementation: import("../../../schema").TiptapBlockImplementation<{
|
|
175
187
|
type: "heading";
|
|
176
188
|
content: "inline";
|
|
177
189
|
propSchema: {
|
|
@@ -190,7 +202,7 @@ declare const schema: BlockNoteSchema<import("../../..").BlockSchemaFromSpecs<{
|
|
|
190
202
|
values: readonly ["left", "center", "right", "justify"];
|
|
191
203
|
};
|
|
192
204
|
};
|
|
193
|
-
}, any, import("
|
|
205
|
+
}, any, import("../../../schema").InlineContentSchema, import("../../../schema").StyleSchema>;
|
|
194
206
|
};
|
|
195
207
|
bulletListItem: {
|
|
196
208
|
config: {
|
|
@@ -209,7 +221,7 @@ declare const schema: BlockNoteSchema<import("../../..").BlockSchemaFromSpecs<{
|
|
|
209
221
|
};
|
|
210
222
|
};
|
|
211
223
|
};
|
|
212
|
-
implementation: import("
|
|
224
|
+
implementation: import("../../../schema").TiptapBlockImplementation<{
|
|
213
225
|
type: "bulletListItem";
|
|
214
226
|
content: "inline";
|
|
215
227
|
propSchema: {
|
|
@@ -224,7 +236,7 @@ declare const schema: BlockNoteSchema<import("../../..").BlockSchemaFromSpecs<{
|
|
|
224
236
|
values: readonly ["left", "center", "right", "justify"];
|
|
225
237
|
};
|
|
226
238
|
};
|
|
227
|
-
}, any, import("
|
|
239
|
+
}, any, import("../../../schema").InlineContentSchema, import("../../../schema").StyleSchema>;
|
|
228
240
|
};
|
|
229
241
|
numberedListItem: {
|
|
230
242
|
config: {
|
|
@@ -243,7 +255,7 @@ declare const schema: BlockNoteSchema<import("../../..").BlockSchemaFromSpecs<{
|
|
|
243
255
|
};
|
|
244
256
|
};
|
|
245
257
|
};
|
|
246
|
-
implementation: import("
|
|
258
|
+
implementation: import("../../../schema").TiptapBlockImplementation<{
|
|
247
259
|
type: "numberedListItem";
|
|
248
260
|
content: "inline";
|
|
249
261
|
propSchema: {
|
|
@@ -258,7 +270,49 @@ declare const schema: BlockNoteSchema<import("../../..").BlockSchemaFromSpecs<{
|
|
|
258
270
|
values: readonly ["left", "center", "right", "justify"];
|
|
259
271
|
};
|
|
260
272
|
};
|
|
261
|
-
}, any, import("
|
|
273
|
+
}, any, import("../../../schema").InlineContentSchema, import("../../../schema").StyleSchema>;
|
|
274
|
+
};
|
|
275
|
+
file: {
|
|
276
|
+
config: {
|
|
277
|
+
type: "file";
|
|
278
|
+
propSchema: {
|
|
279
|
+
backgroundColor: {
|
|
280
|
+
default: "default";
|
|
281
|
+
};
|
|
282
|
+
name: {
|
|
283
|
+
default: "";
|
|
284
|
+
};
|
|
285
|
+
url: {
|
|
286
|
+
default: "";
|
|
287
|
+
};
|
|
288
|
+
caption: {
|
|
289
|
+
default: "";
|
|
290
|
+
};
|
|
291
|
+
};
|
|
292
|
+
content: "none";
|
|
293
|
+
isFileBlock: true;
|
|
294
|
+
isFileBlockPlaceholder: (block: any) => boolean;
|
|
295
|
+
};
|
|
296
|
+
implementation: import("../../../schema").TiptapBlockImplementation<{
|
|
297
|
+
type: "file";
|
|
298
|
+
propSchema: {
|
|
299
|
+
backgroundColor: {
|
|
300
|
+
default: "default";
|
|
301
|
+
};
|
|
302
|
+
name: {
|
|
303
|
+
default: "";
|
|
304
|
+
};
|
|
305
|
+
url: {
|
|
306
|
+
default: "";
|
|
307
|
+
};
|
|
308
|
+
caption: {
|
|
309
|
+
default: "";
|
|
310
|
+
};
|
|
311
|
+
};
|
|
312
|
+
content: "none";
|
|
313
|
+
isFileBlock: true;
|
|
314
|
+
isFileBlockPlaceholder: (block: any) => boolean;
|
|
315
|
+
}, any, import("../../../schema").InlineContentSchema, import("../../../schema").StyleSchema>;
|
|
262
316
|
};
|
|
263
317
|
image: {
|
|
264
318
|
config: {
|
|
@@ -271,19 +325,28 @@ declare const schema: BlockNoteSchema<import("../../..").BlockSchemaFromSpecs<{
|
|
|
271
325
|
backgroundColor: {
|
|
272
326
|
default: "default";
|
|
273
327
|
};
|
|
328
|
+
name: {
|
|
329
|
+
default: "";
|
|
330
|
+
};
|
|
274
331
|
url: {
|
|
275
332
|
default: "";
|
|
276
333
|
};
|
|
277
334
|
caption: {
|
|
278
335
|
default: "";
|
|
279
336
|
};
|
|
280
|
-
|
|
281
|
-
default:
|
|
337
|
+
showPreview: {
|
|
338
|
+
default: true;
|
|
339
|
+
};
|
|
340
|
+
previewWidth: {
|
|
341
|
+
default: number;
|
|
282
342
|
};
|
|
283
343
|
};
|
|
284
344
|
content: "none";
|
|
345
|
+
isFileBlock: true;
|
|
346
|
+
isFileBlockPlaceholder: (block: any) => boolean;
|
|
347
|
+
fileBlockAcceptMimeTypes: string[];
|
|
285
348
|
};
|
|
286
|
-
implementation: import("
|
|
349
|
+
implementation: import("../../../schema").TiptapBlockImplementation<{
|
|
287
350
|
type: "image";
|
|
288
351
|
propSchema: {
|
|
289
352
|
textAlignment: {
|
|
@@ -293,18 +356,141 @@ declare const schema: BlockNoteSchema<import("../../..").BlockSchemaFromSpecs<{
|
|
|
293
356
|
backgroundColor: {
|
|
294
357
|
default: "default";
|
|
295
358
|
};
|
|
359
|
+
name: {
|
|
360
|
+
default: "";
|
|
361
|
+
};
|
|
362
|
+
url: {
|
|
363
|
+
default: "";
|
|
364
|
+
};
|
|
365
|
+
caption: {
|
|
366
|
+
default: "";
|
|
367
|
+
};
|
|
368
|
+
showPreview: {
|
|
369
|
+
default: true;
|
|
370
|
+
};
|
|
371
|
+
previewWidth: {
|
|
372
|
+
default: number;
|
|
373
|
+
};
|
|
374
|
+
};
|
|
375
|
+
content: "none";
|
|
376
|
+
isFileBlock: true;
|
|
377
|
+
isFileBlockPlaceholder: (block: any) => boolean;
|
|
378
|
+
fileBlockAcceptMimeTypes: string[];
|
|
379
|
+
}, any, import("../../../schema").InlineContentSchema, import("../../../schema").StyleSchema>;
|
|
380
|
+
};
|
|
381
|
+
video: {
|
|
382
|
+
config: {
|
|
383
|
+
type: "video";
|
|
384
|
+
propSchema: {
|
|
385
|
+
textAlignment: {
|
|
386
|
+
default: "left";
|
|
387
|
+
values: readonly ["left", "center", "right", "justify"];
|
|
388
|
+
};
|
|
389
|
+
backgroundColor: {
|
|
390
|
+
default: "default";
|
|
391
|
+
};
|
|
392
|
+
name: {
|
|
393
|
+
default: "";
|
|
394
|
+
};
|
|
395
|
+
url: {
|
|
396
|
+
default: "";
|
|
397
|
+
};
|
|
398
|
+
caption: {
|
|
399
|
+
default: "";
|
|
400
|
+
};
|
|
401
|
+
showPreview: {
|
|
402
|
+
default: true;
|
|
403
|
+
};
|
|
404
|
+
previewWidth: {
|
|
405
|
+
default: number;
|
|
406
|
+
};
|
|
407
|
+
};
|
|
408
|
+
content: "none";
|
|
409
|
+
isFileBlock: true;
|
|
410
|
+
isFileBlockPlaceholder: (block: any) => boolean;
|
|
411
|
+
fileBlockAcceptMimeTypes: string[];
|
|
412
|
+
};
|
|
413
|
+
implementation: import("../../../schema").TiptapBlockImplementation<{
|
|
414
|
+
type: "video";
|
|
415
|
+
propSchema: {
|
|
416
|
+
textAlignment: {
|
|
417
|
+
default: "left";
|
|
418
|
+
values: readonly ["left", "center", "right", "justify"];
|
|
419
|
+
};
|
|
420
|
+
backgroundColor: {
|
|
421
|
+
default: "default";
|
|
422
|
+
};
|
|
423
|
+
name: {
|
|
424
|
+
default: "";
|
|
425
|
+
};
|
|
426
|
+
url: {
|
|
427
|
+
default: "";
|
|
428
|
+
};
|
|
429
|
+
caption: {
|
|
430
|
+
default: "";
|
|
431
|
+
};
|
|
432
|
+
showPreview: {
|
|
433
|
+
default: true;
|
|
434
|
+
};
|
|
435
|
+
previewWidth: {
|
|
436
|
+
default: number;
|
|
437
|
+
};
|
|
438
|
+
};
|
|
439
|
+
content: "none";
|
|
440
|
+
isFileBlock: true;
|
|
441
|
+
isFileBlockPlaceholder: (block: any) => boolean;
|
|
442
|
+
fileBlockAcceptMimeTypes: string[];
|
|
443
|
+
}, any, import("../../../schema").InlineContentSchema, import("../../../schema").StyleSchema>;
|
|
444
|
+
};
|
|
445
|
+
audio: {
|
|
446
|
+
config: {
|
|
447
|
+
type: "audio";
|
|
448
|
+
propSchema: {
|
|
449
|
+
backgroundColor: {
|
|
450
|
+
default: "default";
|
|
451
|
+
};
|
|
452
|
+
name: {
|
|
453
|
+
default: "";
|
|
454
|
+
};
|
|
455
|
+
url: {
|
|
456
|
+
default: "";
|
|
457
|
+
};
|
|
458
|
+
caption: {
|
|
459
|
+
default: "";
|
|
460
|
+
};
|
|
461
|
+
showPreview: {
|
|
462
|
+
default: true;
|
|
463
|
+
};
|
|
464
|
+
};
|
|
465
|
+
content: "none";
|
|
466
|
+
isFileBlock: true;
|
|
467
|
+
isFileBlockPlaceholder: (block: any) => boolean;
|
|
468
|
+
fileBlockAcceptMimeTypes: string[];
|
|
469
|
+
};
|
|
470
|
+
implementation: import("../../../schema").TiptapBlockImplementation<{
|
|
471
|
+
type: "audio";
|
|
472
|
+
propSchema: {
|
|
473
|
+
backgroundColor: {
|
|
474
|
+
default: "default";
|
|
475
|
+
};
|
|
476
|
+
name: {
|
|
477
|
+
default: "";
|
|
478
|
+
};
|
|
296
479
|
url: {
|
|
297
480
|
default: "";
|
|
298
481
|
};
|
|
299
482
|
caption: {
|
|
300
483
|
default: "";
|
|
301
484
|
};
|
|
302
|
-
|
|
303
|
-
default:
|
|
485
|
+
showPreview: {
|
|
486
|
+
default: true;
|
|
304
487
|
};
|
|
305
488
|
};
|
|
306
489
|
content: "none";
|
|
307
|
-
|
|
490
|
+
isFileBlock: true;
|
|
491
|
+
isFileBlockPlaceholder: (block: any) => boolean;
|
|
492
|
+
fileBlockAcceptMimeTypes: string[];
|
|
493
|
+
}, any, import("../../../schema").InlineContentSchema, import("../../../schema").StyleSchema>;
|
|
308
494
|
};
|
|
309
495
|
table: {
|
|
310
496
|
config: {
|
|
@@ -323,7 +509,7 @@ declare const schema: BlockNoteSchema<import("../../..").BlockSchemaFromSpecs<{
|
|
|
323
509
|
};
|
|
324
510
|
};
|
|
325
511
|
};
|
|
326
|
-
implementation: import("
|
|
512
|
+
implementation: import("../../../schema").TiptapBlockImplementation<{
|
|
327
513
|
type: "table";
|
|
328
514
|
content: "table";
|
|
329
515
|
propSchema: {
|
|
@@ -338,9 +524,9 @@ declare const schema: BlockNoteSchema<import("../../..").BlockSchemaFromSpecs<{
|
|
|
338
524
|
values: readonly ["left", "center", "right", "justify"];
|
|
339
525
|
};
|
|
340
526
|
};
|
|
341
|
-
}, any, import("
|
|
527
|
+
}, any, import("../../../schema").InlineContentSchema, import("../../../schema").StyleSchema>;
|
|
342
528
|
};
|
|
343
|
-
}>, import("
|
|
529
|
+
}>, import("../../../schema").InlineContentSchemaFromSpecs<{
|
|
344
530
|
text: {
|
|
345
531
|
config: "text";
|
|
346
532
|
implementation: any;
|
|
@@ -349,55 +535,55 @@ declare const schema: BlockNoteSchema<import("../../..").BlockSchemaFromSpecs<{
|
|
|
349
535
|
config: "link";
|
|
350
536
|
implementation: any;
|
|
351
537
|
};
|
|
352
|
-
}>, import("
|
|
538
|
+
}>, import("../../../schema").StyleSchemaFromSpecs<{
|
|
353
539
|
bold: {
|
|
354
540
|
config: {
|
|
355
541
|
type: string;
|
|
356
542
|
propSchema: "boolean";
|
|
357
543
|
};
|
|
358
|
-
implementation: import("
|
|
544
|
+
implementation: import("../../../schema").StyleImplementation;
|
|
359
545
|
};
|
|
360
546
|
italic: {
|
|
361
547
|
config: {
|
|
362
548
|
type: string;
|
|
363
549
|
propSchema: "boolean";
|
|
364
550
|
};
|
|
365
|
-
implementation: import("
|
|
551
|
+
implementation: import("../../../schema").StyleImplementation;
|
|
366
552
|
};
|
|
367
553
|
underline: {
|
|
368
554
|
config: {
|
|
369
555
|
type: string;
|
|
370
556
|
propSchema: "boolean";
|
|
371
557
|
};
|
|
372
|
-
implementation: import("
|
|
558
|
+
implementation: import("../../../schema").StyleImplementation;
|
|
373
559
|
};
|
|
374
560
|
strike: {
|
|
375
561
|
config: {
|
|
376
562
|
type: string;
|
|
377
563
|
propSchema: "boolean";
|
|
378
564
|
};
|
|
379
|
-
implementation: import("
|
|
565
|
+
implementation: import("../../../schema").StyleImplementation;
|
|
380
566
|
};
|
|
381
567
|
code: {
|
|
382
568
|
config: {
|
|
383
569
|
type: string;
|
|
384
570
|
propSchema: "boolean";
|
|
385
571
|
};
|
|
386
|
-
implementation: import("
|
|
572
|
+
implementation: import("../../../schema").StyleImplementation;
|
|
387
573
|
};
|
|
388
574
|
textColor: {
|
|
389
575
|
config: {
|
|
390
576
|
type: string;
|
|
391
577
|
propSchema: "string";
|
|
392
578
|
};
|
|
393
|
-
implementation: import("
|
|
579
|
+
implementation: import("../../../schema").StyleImplementation;
|
|
394
580
|
};
|
|
395
581
|
backgroundColor: {
|
|
396
582
|
config: {
|
|
397
583
|
type: string;
|
|
398
584
|
propSchema: "string";
|
|
399
585
|
};
|
|
400
|
-
implementation: import("
|
|
586
|
+
implementation: import("../../../schema").StyleImplementation;
|
|
401
587
|
};
|
|
402
588
|
}>>;
|
|
403
589
|
export declare const customBlocksTestCases: EditorTestCases<typeof schema.blockSchema, DefaultInlineContentSchema, DefaultStyleSchema>;
|