@blocknote/xl-docx-exporter 0.19.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (90) hide show
  1. package/LICENSE +661 -0
  2. package/dist/Inter_18pt-Regular-byxnNS-8.js +5 -0
  3. package/dist/Inter_18pt-Regular-byxnNS-8.js.map +1 -0
  4. package/dist/blocknote-xl-docx-exporter.js +381 -0
  5. package/dist/blocknote-xl-docx-exporter.js.map +1 -0
  6. package/dist/blocknote-xl-docx-exporter.umd.cjs +991 -0
  7. package/dist/blocknote-xl-docx-exporter.umd.cjs.map +1 -0
  8. package/dist/styles-CcdeAskf.js +994 -0
  9. package/dist/styles-CcdeAskf.js.map +1 -0
  10. package/dist/webpack-stats.json +1 -0
  11. package/package.json +80 -0
  12. package/src/docx/__snapshots__/basic/document.xml +685 -0
  13. package/src/docx/__snapshots__/basic/styles.xml +960 -0
  14. package/src/docx/__snapshots__/withCustomOptions/core.xml +14 -0
  15. package/src/docx/__snapshots__/withCustomOptions/document.xml.rels +17 -0
  16. package/src/docx/__snapshots__/withCustomOptions/footer1.xml +8 -0
  17. package/src/docx/__snapshots__/withCustomOptions/header1.xml +8 -0
  18. package/src/docx/defaultSchema/blocks.ts +222 -0
  19. package/src/docx/defaultSchema/index.ts +9 -0
  20. package/src/docx/defaultSchema/inlinecontent.ts +29 -0
  21. package/src/docx/defaultSchema/styles.ts +73 -0
  22. package/src/docx/docxExporter.test.ts +118 -0
  23. package/src/docx/docxExporter.ts +269 -0
  24. package/src/docx/imageUtil.ts +21 -0
  25. package/src/docx/index.ts +2 -0
  26. package/src/docx/template/[Content_Types].xml +22 -0
  27. package/src/docx/template/_rels/.rels +2 -0
  28. package/src/docx/template/docProps/app.xml +35 -0
  29. package/src/docx/template/docProps/core.xml +16 -0
  30. package/src/docx/template/template blocknote.docx +0 -0
  31. package/src/docx/template/word/_rels/document.xml.rels +24 -0
  32. package/src/docx/template/word/document.xml +325 -0
  33. package/src/docx/template/word/fontTable.xml +2 -0
  34. package/src/docx/template/word/media/image1.jpeg +0 -0
  35. package/src/docx/template/word/settings.xml +71 -0
  36. package/src/docx/template/word/styles.xml +990 -0
  37. package/src/docx/template/word/theme/theme1.xml +2 -0
  38. package/src/docx/template/word/webSettings.xml +2 -0
  39. package/src/docx/util/Table.tsx +43 -0
  40. package/src/index.ts +1 -0
  41. package/src/vite-env.d.ts +11 -0
  42. package/types/src/Exporter.d.ts +26 -0
  43. package/types/src/context/BlockNoteContext.d.ts +59 -0
  44. package/types/src/context/BlockNoteContext.test.d.ts +1 -0
  45. package/types/src/context/ServerBlockNoteEditor.d.ts +137 -0
  46. package/types/src/context/ServerBlockNoteEditor.test.d.ts +1 -0
  47. package/types/src/context/react/ReactServer.test.d.ts +2 -0
  48. package/types/src/docx/blocks.d.ts +433 -0
  49. package/types/src/docx/defaultSchema/blocks.d.ts +3 -0
  50. package/types/src/docx/defaultSchema/index.d.ts +559 -0
  51. package/types/src/docx/defaultSchema/inlinecontent.d.ts +3 -0
  52. package/types/src/docx/defaultSchema/styles.d.ts +3 -0
  53. package/types/src/docx/docxExporter.d.ts +53 -0
  54. package/types/src/docx/docxExporter.test.d.ts +1 -0
  55. package/types/src/docx/imageUtil.d.ts +4 -0
  56. package/types/src/docx/index.d.ts +2 -0
  57. package/types/src/docx/inlinecontent.d.ts +12 -0
  58. package/types/src/docx/styles.d.ts +55 -0
  59. package/types/src/docx/util/Table.d.ts +3 -0
  60. package/types/src/docxExporter.d.ts +255 -0
  61. package/types/src/docxExporter.test.d.ts +1 -0
  62. package/types/src/index.d.ts +1 -0
  63. package/types/src/mapping.d.ts +29 -0
  64. package/types/src/pdf/blocks.d.ts +434 -0
  65. package/types/src/pdf/defaultSchema/blocks.d.ts +5 -0
  66. package/types/src/pdf/defaultSchema/index.d.ts +510 -0
  67. package/types/src/pdf/defaultSchema/inlinecontent.d.ts +5 -0
  68. package/types/src/pdf/defaultSchema/styles.d.ts +4 -0
  69. package/types/src/pdf/index.d.ts +2 -0
  70. package/types/src/pdf/inlinecontent.d.ts +13 -0
  71. package/types/src/pdf/pdfExporter.d.ts +35 -0
  72. package/types/src/pdf/pdfExporter.test.d.ts +1 -0
  73. package/types/src/pdf/styles.d.ts +55 -0
  74. package/types/src/pdf/types.d.ts +2 -0
  75. package/types/src/pdf/util/listItem.d.ts +9 -0
  76. package/types/src/pdf/util/loadFontDataUrl.d.ts +3 -0
  77. package/types/src/pdf/util/table/Table.d.ts +6 -0
  78. package/types/src/pdfExporter.d.ts +256 -0
  79. package/types/src/pdfExporter.test.d.ts +1 -0
  80. package/types/src/react-email/defaultSchema/blocks.d.ts +5 -0
  81. package/types/src/react-email/defaultSchema/index.d.ts +560 -0
  82. package/types/src/react-email/defaultSchema/inlinecontent.d.ts +5 -0
  83. package/types/src/react-email/defaultSchema/styles.d.ts +4 -0
  84. package/types/src/react-email/reactEmailExporter.d.ts +13 -0
  85. package/types/src/react-email/reactEmailExporter.test.d.ts +8 -0
  86. package/types/src/testDocument.d.ts +505 -0
  87. package/types/src/transformer.d.ts +20 -0
  88. package/types/src/util/fileUtil.d.ts +22 -0
  89. package/types/src/util/imageUtil.d.ts +4 -0
  90. package/types/src/yjs/index.d.ts +2 -0
@@ -0,0 +1,510 @@
1
+ /// <reference types="react" />
2
+ export declare const pdfDefaultSchemaMappings: {
3
+ blockMapping: import("@blocknote/core").BlockMapping<import("@blocknote/core").BlockSchemaFromSpecs<{
4
+ paragraph: {
5
+ config: {
6
+ type: "paragraph";
7
+ content: "inline";
8
+ propSchema: {
9
+ backgroundColor: {
10
+ default: "default";
11
+ };
12
+ textColor: {
13
+ default: "default";
14
+ };
15
+ textAlignment: {
16
+ default: "left";
17
+ values: readonly ["left", "center", "right", "justify"];
18
+ };
19
+ };
20
+ };
21
+ implementation: import("@blocknote/core").TiptapBlockImplementation<{
22
+ type: "paragraph";
23
+ content: "inline";
24
+ propSchema: {
25
+ backgroundColor: {
26
+ default: "default";
27
+ };
28
+ textColor: {
29
+ default: "default";
30
+ };
31
+ textAlignment: {
32
+ default: "left";
33
+ values: readonly ["left", "center", "right", "justify"];
34
+ };
35
+ };
36
+ }, any, import("@blocknote/core").InlineContentSchema, import("@blocknote/core").StyleSchema>;
37
+ };
38
+ heading: {
39
+ config: {
40
+ type: "heading";
41
+ content: "inline";
42
+ propSchema: {
43
+ level: {
44
+ default: number;
45
+ values: readonly [1, 2, 3];
46
+ };
47
+ backgroundColor: {
48
+ default: "default";
49
+ };
50
+ textColor: {
51
+ default: "default";
52
+ };
53
+ textAlignment: {
54
+ default: "left";
55
+ values: readonly ["left", "center", "right", "justify"];
56
+ };
57
+ };
58
+ };
59
+ implementation: import("@blocknote/core").TiptapBlockImplementation<{
60
+ type: "heading";
61
+ content: "inline";
62
+ propSchema: {
63
+ level: {
64
+ default: number;
65
+ values: readonly [1, 2, 3];
66
+ };
67
+ backgroundColor: {
68
+ default: "default";
69
+ };
70
+ textColor: {
71
+ default: "default";
72
+ };
73
+ textAlignment: {
74
+ default: "left";
75
+ values: readonly ["left", "center", "right", "justify"];
76
+ };
77
+ };
78
+ }, any, import("@blocknote/core").InlineContentSchema, import("@blocknote/core").StyleSchema>;
79
+ };
80
+ codeBlock: {
81
+ config: {
82
+ type: "codeBlock";
83
+ content: "inline";
84
+ propSchema: {
85
+ language: {
86
+ default: string;
87
+ values: string[];
88
+ };
89
+ };
90
+ };
91
+ implementation: import("@blocknote/core").TiptapBlockImplementation<{
92
+ type: "codeBlock";
93
+ content: "inline";
94
+ propSchema: {
95
+ language: {
96
+ default: string;
97
+ values: string[];
98
+ };
99
+ };
100
+ }, any, import("@blocknote/core").InlineContentSchema, import("@blocknote/core").StyleSchema>;
101
+ };
102
+ bulletListItem: {
103
+ config: {
104
+ type: "bulletListItem";
105
+ content: "inline";
106
+ propSchema: {
107
+ backgroundColor: {
108
+ default: "default";
109
+ };
110
+ textColor: {
111
+ default: "default";
112
+ };
113
+ textAlignment: {
114
+ default: "left";
115
+ values: readonly ["left", "center", "right", "justify"];
116
+ };
117
+ };
118
+ };
119
+ implementation: import("@blocknote/core").TiptapBlockImplementation<{
120
+ type: "bulletListItem";
121
+ content: "inline";
122
+ propSchema: {
123
+ backgroundColor: {
124
+ default: "default";
125
+ };
126
+ textColor: {
127
+ default: "default";
128
+ };
129
+ textAlignment: {
130
+ default: "left";
131
+ values: readonly ["left", "center", "right", "justify"];
132
+ };
133
+ };
134
+ }, any, import("@blocknote/core").InlineContentSchema, import("@blocknote/core").StyleSchema>;
135
+ };
136
+ numberedListItem: {
137
+ config: {
138
+ type: "numberedListItem";
139
+ content: "inline";
140
+ propSchema: {
141
+ backgroundColor: {
142
+ default: "default";
143
+ };
144
+ textColor: {
145
+ default: "default";
146
+ };
147
+ textAlignment: {
148
+ default: "left";
149
+ values: readonly ["left", "center", "right", "justify"];
150
+ };
151
+ };
152
+ };
153
+ implementation: import("@blocknote/core").TiptapBlockImplementation<{
154
+ type: "numberedListItem";
155
+ content: "inline";
156
+ propSchema: {
157
+ backgroundColor: {
158
+ default: "default";
159
+ };
160
+ textColor: {
161
+ default: "default";
162
+ };
163
+ textAlignment: {
164
+ default: "left";
165
+ values: readonly ["left", "center", "right", "justify"];
166
+ };
167
+ };
168
+ }, any, import("@blocknote/core").InlineContentSchema, import("@blocknote/core").StyleSchema>;
169
+ };
170
+ checkListItem: {
171
+ config: {
172
+ type: "checkListItem";
173
+ content: "inline";
174
+ propSchema: {
175
+ checked: {
176
+ default: false;
177
+ };
178
+ backgroundColor: {
179
+ default: "default";
180
+ };
181
+ textColor: {
182
+ default: "default";
183
+ };
184
+ textAlignment: {
185
+ default: "left";
186
+ values: readonly ["left", "center", "right", "justify"];
187
+ };
188
+ };
189
+ };
190
+ implementation: import("@blocknote/core").TiptapBlockImplementation<{
191
+ type: "checkListItem";
192
+ content: "inline";
193
+ propSchema: {
194
+ checked: {
195
+ default: false;
196
+ };
197
+ backgroundColor: {
198
+ default: "default";
199
+ };
200
+ textColor: {
201
+ default: "default";
202
+ };
203
+ textAlignment: {
204
+ default: "left";
205
+ values: readonly ["left", "center", "right", "justify"];
206
+ };
207
+ };
208
+ }, any, import("@blocknote/core").InlineContentSchema, import("@blocknote/core").StyleSchema>;
209
+ };
210
+ table: {
211
+ config: {
212
+ type: "table";
213
+ content: "table";
214
+ propSchema: {
215
+ backgroundColor: {
216
+ default: "default";
217
+ };
218
+ textColor: {
219
+ default: "default";
220
+ };
221
+ };
222
+ };
223
+ implementation: import("@blocknote/core").TiptapBlockImplementation<{
224
+ type: "table";
225
+ content: "table";
226
+ propSchema: {
227
+ backgroundColor: {
228
+ default: "default";
229
+ };
230
+ textColor: {
231
+ default: "default";
232
+ };
233
+ };
234
+ }, any, import("@blocknote/core").InlineContentSchema, import("@blocknote/core").StyleSchema>;
235
+ };
236
+ file: {
237
+ config: {
238
+ type: "file";
239
+ propSchema: {
240
+ backgroundColor: {
241
+ default: "default";
242
+ };
243
+ name: {
244
+ default: "";
245
+ };
246
+ url: {
247
+ default: "";
248
+ };
249
+ caption: {
250
+ default: "";
251
+ };
252
+ };
253
+ content: "none";
254
+ isFileBlock: true;
255
+ };
256
+ implementation: import("@blocknote/core").TiptapBlockImplementation<{
257
+ type: "file";
258
+ propSchema: {
259
+ backgroundColor: {
260
+ default: "default";
261
+ };
262
+ name: {
263
+ default: "";
264
+ };
265
+ url: {
266
+ default: "";
267
+ };
268
+ caption: {
269
+ default: "";
270
+ };
271
+ };
272
+ content: "none";
273
+ isFileBlock: true;
274
+ }, any, import("@blocknote/core").InlineContentSchema, import("@blocknote/core").StyleSchema>;
275
+ };
276
+ image: {
277
+ config: {
278
+ type: "image";
279
+ propSchema: {
280
+ textAlignment: {
281
+ default: "left";
282
+ values: readonly ["left", "center", "right", "justify"];
283
+ };
284
+ backgroundColor: {
285
+ default: "default";
286
+ };
287
+ name: {
288
+ default: "";
289
+ };
290
+ url: {
291
+ default: "";
292
+ };
293
+ caption: {
294
+ default: "";
295
+ };
296
+ showPreview: {
297
+ default: true;
298
+ };
299
+ previewWidth: {
300
+ default: number;
301
+ };
302
+ };
303
+ content: "none";
304
+ isFileBlock: true;
305
+ fileBlockAccept: string[];
306
+ };
307
+ implementation: import("@blocknote/core").TiptapBlockImplementation<{
308
+ type: "image";
309
+ propSchema: {
310
+ textAlignment: {
311
+ default: "left";
312
+ values: readonly ["left", "center", "right", "justify"];
313
+ };
314
+ backgroundColor: {
315
+ default: "default";
316
+ };
317
+ name: {
318
+ default: "";
319
+ };
320
+ url: {
321
+ default: "";
322
+ };
323
+ caption: {
324
+ default: "";
325
+ };
326
+ showPreview: {
327
+ default: true;
328
+ };
329
+ previewWidth: {
330
+ default: number;
331
+ };
332
+ };
333
+ content: "none";
334
+ isFileBlock: true;
335
+ fileBlockAccept: string[];
336
+ }, any, import("@blocknote/core").InlineContentSchema, import("@blocknote/core").StyleSchema>;
337
+ };
338
+ video: {
339
+ config: {
340
+ type: "video";
341
+ propSchema: {
342
+ textAlignment: {
343
+ default: "left";
344
+ values: readonly ["left", "center", "right", "justify"];
345
+ };
346
+ backgroundColor: {
347
+ default: "default";
348
+ };
349
+ name: {
350
+ default: "";
351
+ };
352
+ url: {
353
+ default: "";
354
+ };
355
+ caption: {
356
+ default: "";
357
+ };
358
+ showPreview: {
359
+ default: true;
360
+ };
361
+ previewWidth: {
362
+ default: number;
363
+ };
364
+ };
365
+ content: "none";
366
+ isFileBlock: true;
367
+ fileBlockAccept: string[];
368
+ };
369
+ implementation: import("@blocknote/core").TiptapBlockImplementation<{
370
+ type: "video";
371
+ propSchema: {
372
+ textAlignment: {
373
+ default: "left";
374
+ values: readonly ["left", "center", "right", "justify"];
375
+ };
376
+ backgroundColor: {
377
+ default: "default";
378
+ };
379
+ name: {
380
+ default: "";
381
+ };
382
+ url: {
383
+ default: "";
384
+ };
385
+ caption: {
386
+ default: "";
387
+ };
388
+ showPreview: {
389
+ default: true;
390
+ };
391
+ previewWidth: {
392
+ default: number;
393
+ };
394
+ };
395
+ content: "none";
396
+ isFileBlock: true;
397
+ fileBlockAccept: string[];
398
+ }, any, import("@blocknote/core").InlineContentSchema, import("@blocknote/core").StyleSchema>;
399
+ };
400
+ audio: {
401
+ config: {
402
+ type: "audio";
403
+ propSchema: {
404
+ backgroundColor: {
405
+ default: "default";
406
+ };
407
+ name: {
408
+ default: "";
409
+ };
410
+ url: {
411
+ default: "";
412
+ };
413
+ caption: {
414
+ default: "";
415
+ };
416
+ showPreview: {
417
+ default: true;
418
+ };
419
+ };
420
+ content: "none";
421
+ isFileBlock: true;
422
+ fileBlockAccept: string[];
423
+ };
424
+ implementation: import("@blocknote/core").TiptapBlockImplementation<{
425
+ type: "audio";
426
+ propSchema: {
427
+ backgroundColor: {
428
+ default: "default";
429
+ };
430
+ name: {
431
+ default: "";
432
+ };
433
+ url: {
434
+ default: "";
435
+ };
436
+ caption: {
437
+ default: "";
438
+ };
439
+ showPreview: {
440
+ default: true;
441
+ };
442
+ };
443
+ content: "none";
444
+ isFileBlock: true;
445
+ fileBlockAccept: string[];
446
+ }, any, import("@blocknote/core").InlineContentSchema, import("@blocknote/core").StyleSchema>;
447
+ };
448
+ }>, any, any, import("react").ReactElement<import("@react-pdf/renderer").Text, string | import("react").JSXElementConstructor<any>>, import("react").ReactElement<import("@react-pdf/renderer").Text, string | import("react").JSXElementConstructor<any>> | import("react").ReactElement<import("@react-pdf/renderer").Link, string | import("react").JSXElementConstructor<any>>>;
449
+ inlineContentMapping: import("@blocknote/core").InlineContentMapping<import("@blocknote/core").InlineContentSchemaFromSpecs<{
450
+ text: {
451
+ config: "text";
452
+ implementation: any;
453
+ };
454
+ link: {
455
+ config: "link";
456
+ implementation: any;
457
+ };
458
+ }>, any, import("react").ReactElement<import("@react-pdf/renderer").Text, string | import("react").JSXElementConstructor<any>> | import("react").ReactElement<import("@react-pdf/renderer").Link, string | import("react").JSXElementConstructor<any>>, import("react").ReactElement<import("@react-pdf/renderer").Text, string | import("react").JSXElementConstructor<any>>>;
459
+ styleMapping: import("@blocknote/core").StyleMapping<import("@blocknote/core").StyleSchemaFromSpecs<{
460
+ bold: {
461
+ config: {
462
+ type: string;
463
+ propSchema: "boolean";
464
+ };
465
+ implementation: import("@blocknote/core").StyleImplementation;
466
+ };
467
+ italic: {
468
+ config: {
469
+ type: string;
470
+ propSchema: "boolean";
471
+ };
472
+ implementation: import("@blocknote/core").StyleImplementation;
473
+ };
474
+ underline: {
475
+ config: {
476
+ type: string;
477
+ propSchema: "boolean";
478
+ };
479
+ implementation: import("@blocknote/core").StyleImplementation;
480
+ };
481
+ strike: {
482
+ config: {
483
+ type: string;
484
+ propSchema: "boolean";
485
+ };
486
+ implementation: import("@blocknote/core").StyleImplementation;
487
+ };
488
+ code: {
489
+ config: {
490
+ type: string;
491
+ propSchema: "boolean";
492
+ };
493
+ implementation: import("@blocknote/core").StyleImplementation;
494
+ };
495
+ textColor: {
496
+ config: {
497
+ type: string;
498
+ propSchema: "string";
499
+ };
500
+ implementation: import("@blocknote/core").StyleImplementation;
501
+ };
502
+ backgroundColor: {
503
+ config: {
504
+ type: string;
505
+ propSchema: "string";
506
+ };
507
+ implementation: import("@blocknote/core").StyleImplementation;
508
+ };
509
+ }>, import("@react-pdf/types").Style | import("@react-pdf/types").Style[] | undefined>;
510
+ };
@@ -0,0 +1,5 @@
1
+ /// <reference types="react" />
2
+ import { DefaultInlineContentSchema } from "@blocknote/core";
3
+ import { InlineContentMapping } from "@blocknote/core/src/exporter/mapping.js";
4
+ import { Link, Text } from "@react-pdf/renderer";
5
+ export declare const pdfInlineContentMappingForDefaultSchema: InlineContentMapping<DefaultInlineContentSchema, any, React.ReactElement<Link> | React.ReactElement<Text>, React.ReactElement<Text>>;
@@ -0,0 +1,4 @@
1
+ import { DefaultStyleSchema } from "@blocknote/core";
2
+ import { StyleMapping } from "@blocknote/core/src/exporter/mapping.js";
3
+ import { TextProps } from "@react-pdf/renderer";
4
+ export declare const pdfStyleMappingForDefaultSchema: StyleMapping<DefaultStyleSchema, TextProps["style"]>;
@@ -0,0 +1,2 @@
1
+ export * from "./defaultSchema/index.js";
2
+ export * from "./pdfExporter.jsx";
@@ -0,0 +1,13 @@
1
+ /// <reference types="react" />
2
+ import { StyleSchema, StyledText } from "@blocknote/core";
3
+ import { Link, Text } from "@react-pdf/renderer";
4
+ export declare function docxInlineContentMappingForDefaultSchema(styledTextTransformer: (styledText: StyledText<StyleSchema>) => React.ReactElement<Text>): import("../mapping").InlineContentMapping<import("@blocknote/core").InlineContentSchemaFromSpecs<{
5
+ text: {
6
+ config: "text";
7
+ implementation: any;
8
+ };
9
+ link: {
10
+ config: "link";
11
+ implementation: any;
12
+ };
13
+ }>, StyleSchema, import("react").ReactElement<Text, string | import("react").JSXElementConstructor<any>> | import("react").ReactElement<Link, string | import("react").JSXElementConstructor<any>>>;
@@ -0,0 +1,35 @@
1
+ /// <reference types="react" />
2
+ import { Block, BlockNoteSchema, BlockSchema, DefaultProps, InlineContentSchema, StyleSchema, StyledText } from "@blocknote/core";
3
+ import { Exporter, ExporterOptions } from "@blocknote/core";
4
+ import { Font, Link, Text, TextProps } from "@react-pdf/renderer";
5
+ import { Style } from "./types.js";
6
+ type Options = ExporterOptions & {
7
+ emojiSource: false | ReturnType<typeof Font.getEmojiSource>;
8
+ };
9
+ export declare class PDFExporter<B extends BlockSchema, S extends StyleSchema, I extends InlineContentSchema> extends Exporter<B, I, S, React.ReactElement<Text>, React.ReactElement<Link> | React.ReactElement<Text>, TextProps["style"], React.ReactElement<Text>> {
10
+ readonly schema: BlockNoteSchema<B, I, S>;
11
+ readonly options: Options;
12
+ constructor(schema: BlockNoteSchema<B, I, S>, mappings: Exporter<NoInfer<B>, NoInfer<I>, NoInfer<S>, React.ReactElement<Text>, // RB
13
+ // RB
14
+ React.ReactElement<Link> | React.ReactElement<Text>, // RI
15
+ TextProps["style"], // RS
16
+ React.ReactElement<Text>>["mappings"], options?: Partial<Options>);
17
+ transformStyledText(styledText: StyledText<S>): import("react/jsx-runtime").JSX.Element;
18
+ transformBlocks(blocks: Block<B, I, S>[], // Or BlockFromConfig<B[keyof B], I, S>?
19
+ nestingLevel?: number): Promise<React.ReactElement<Text>[]>;
20
+ createStyles(): {
21
+ page: {
22
+ paddingTop: number;
23
+ paddingBottom: number;
24
+ paddingHorizontal: number;
25
+ fontFamily: string;
26
+ fontSize: number;
27
+ lineHeight: number;
28
+ };
29
+ section: {};
30
+ };
31
+ registerFonts(): Promise<void>;
32
+ toReactPDFDocument(blocks: Block<B, I, S>[]): Promise<import("react/jsx-runtime").JSX.Element>;
33
+ protected blocknoteDefaultPropsToReactPDFStyle(props: Partial<DefaultProps>): Style;
34
+ }
35
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,55 @@
1
+ import { StyleSchema, StyledText } from "@blocknote/core";
2
+ import { TextProps } from "@react-pdf/renderer";
3
+ import { StyleMapping } from "../mapping";
4
+ export declare const docxStyleMappingForDefaultSchema: StyleMapping<import("@blocknote/core").StyleSchemaFromSpecs<{
5
+ bold: {
6
+ config: {
7
+ type: string;
8
+ propSchema: "boolean";
9
+ };
10
+ implementation: import("@blocknote/core").StyleImplementation;
11
+ };
12
+ italic: {
13
+ config: {
14
+ type: string;
15
+ propSchema: "boolean";
16
+ };
17
+ implementation: import("@blocknote/core").StyleImplementation;
18
+ };
19
+ underline: {
20
+ config: {
21
+ type: string;
22
+ propSchema: "boolean";
23
+ };
24
+ implementation: import("@blocknote/core").StyleImplementation;
25
+ };
26
+ strike: {
27
+ config: {
28
+ type: string;
29
+ propSchema: "boolean";
30
+ };
31
+ implementation: import("@blocknote/core").StyleImplementation;
32
+ };
33
+ code: {
34
+ config: {
35
+ type: string;
36
+ propSchema: "boolean";
37
+ };
38
+ implementation: import("@blocknote/core").StyleImplementation;
39
+ };
40
+ textColor: {
41
+ config: {
42
+ type: string;
43
+ propSchema: "string";
44
+ };
45
+ implementation: import("@blocknote/core").StyleImplementation;
46
+ };
47
+ backgroundColor: {
48
+ config: {
49
+ type: string;
50
+ propSchema: "string";
51
+ };
52
+ implementation: import("@blocknote/core").StyleImplementation;
53
+ };
54
+ }>, Style>;
55
+ export declare function createDocxStyledTextTransformer<S extends StyleSchema>(mapping: StyleMapping<S, TextProps>): (styledText: StyledText<S>) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,2 @@
1
+ import { Styles } from "@react-pdf/renderer";
2
+ export type Style = Styles[keyof Styles];
@@ -0,0 +1,9 @@
1
+ import { Style } from "../types.js";
2
+ export declare const BULLET_MARKER = "\u2022";
3
+ export declare const CHECK_MARKER_UNCHECKED: import("react/jsx-runtime").JSX.Element;
4
+ export declare const CHECK_MARKER_CHECKED: import("react/jsx-runtime").JSX.Element;
5
+ export declare const ListItem: ({ listMarker, children, style, }: {
6
+ listMarker: string | React.ReactNode;
7
+ children: React.ReactNode;
8
+ style?: Style;
9
+ }) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,3 @@
1
+ export declare function loadFontDataUrl(requireUrl: {
2
+ default: string;
3
+ }): Promise<any>;
@@ -0,0 +1,6 @@
1
+ import { InlineContentSchema, StyleSchema, TableContent } from "@blocknote/core";
2
+ import { Exporter } from "@blocknote/core/src/exporter/Exporter.js";
3
+ export declare const Table: (props: {
4
+ data: TableContent<InlineContentSchema>;
5
+ transformer: Exporter<any, InlineContentSchema, StyleSchema, any, any, any, any>;
6
+ }) => import("react/jsx-runtime").JSX.Element;