reactjs-tiptap-editor-pro 0.2.41 → 0.2.43
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/lib/extension-bundle.cjs +16 -16
- package/lib/extension-bundle.d.cts +71 -71
- package/lib/extension-bundle.d.ts +71 -71
- package/lib/extension-bundle.js +517 -531
- package/lib/index.cjs +3 -3
- package/lib/index.d.cts +72 -71
- package/lib/index.d.ts +72 -71
- package/lib/index.js +236 -249
- package/lib/locale-bundle.d.cts +71 -71
- package/lib/locale-bundle.d.ts +71 -71
- package/package.json +1 -1
package/lib/index.d.cts
CHANGED
|
@@ -62,6 +62,7 @@ declare interface BubbleMenuProps {
|
|
|
62
62
|
* @default false
|
|
63
63
|
*/
|
|
64
64
|
hidden?: boolean;
|
|
65
|
+
onCopy?: (nodeJson: any) => any;
|
|
65
66
|
};
|
|
66
67
|
linkConfig?: {
|
|
67
68
|
/**
|
|
@@ -308,39 +309,9 @@ declare module '@tiptap/core' {
|
|
|
308
309
|
|
|
309
310
|
declare module '@tiptap/core' {
|
|
310
311
|
interface Commands<ReturnType> {
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
*/
|
|
315
|
-
indent: () => ReturnType;
|
|
316
|
-
/**
|
|
317
|
-
* Set the outdent attribute
|
|
318
|
-
*/
|
|
319
|
-
outdent: () => ReturnType;
|
|
320
|
-
};
|
|
321
|
-
}
|
|
322
|
-
}
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
declare module '@tiptap/core' {
|
|
326
|
-
interface Commands<ReturnType> {
|
|
327
|
-
iframe: {
|
|
328
|
-
/**
|
|
329
|
-
* Add an iframe
|
|
330
|
-
*/
|
|
331
|
-
setIframe: (options: {
|
|
332
|
-
src: string;
|
|
333
|
-
service: string;
|
|
334
|
-
}) => ReturnType;
|
|
335
|
-
};
|
|
336
|
-
}
|
|
337
|
-
}
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
declare module '@tiptap/core' {
|
|
341
|
-
interface Commands<ReturnType> {
|
|
342
|
-
painter: {
|
|
343
|
-
setPainter: (marks: Mark[]) => ReturnType;
|
|
312
|
+
lineHeight: {
|
|
313
|
+
setLineHeight: (lineHeight: string) => ReturnType;
|
|
314
|
+
unsetLineHeight: () => ReturnType;
|
|
344
315
|
};
|
|
345
316
|
}
|
|
346
317
|
}
|
|
@@ -368,9 +339,9 @@ declare module '@tiptap/core' {
|
|
|
368
339
|
|
|
369
340
|
declare module '@tiptap/core' {
|
|
370
341
|
interface Commands<ReturnType> {
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
342
|
+
tableCellBackground: {
|
|
343
|
+
setTableCellBackground: (color: string) => ReturnType;
|
|
344
|
+
unsetTableCellBackground: () => ReturnType;
|
|
374
345
|
};
|
|
375
346
|
}
|
|
376
347
|
}
|
|
@@ -390,13 +361,8 @@ declare module '@tiptap/core' {
|
|
|
390
361
|
|
|
391
362
|
declare module '@tiptap/core' {
|
|
392
363
|
interface Commands<ReturnType> {
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
cols: number;
|
|
396
|
-
}) => ReturnType;
|
|
397
|
-
addColBefore: () => ReturnType;
|
|
398
|
-
addColAfter: () => ReturnType;
|
|
399
|
-
deleteCol: () => ReturnType;
|
|
364
|
+
katex: {
|
|
365
|
+
setKatex: (arg?: IKatexAttrs) => ReturnType;
|
|
400
366
|
};
|
|
401
367
|
}
|
|
402
368
|
}
|
|
@@ -404,9 +370,13 @@ declare module '@tiptap/core' {
|
|
|
404
370
|
|
|
405
371
|
declare module '@tiptap/core' {
|
|
406
372
|
interface Commands<ReturnType> {
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
373
|
+
columns: {
|
|
374
|
+
insertColumns: (attrs?: {
|
|
375
|
+
cols: number;
|
|
376
|
+
}) => ReturnType;
|
|
377
|
+
addColBefore: () => ReturnType;
|
|
378
|
+
addColAfter: () => ReturnType;
|
|
379
|
+
deleteCol: () => ReturnType;
|
|
410
380
|
};
|
|
411
381
|
}
|
|
412
382
|
}
|
|
@@ -429,8 +399,15 @@ declare module '@tiptap/core' {
|
|
|
429
399
|
|
|
430
400
|
declare module '@tiptap/core' {
|
|
431
401
|
interface Commands<ReturnType> {
|
|
432
|
-
|
|
433
|
-
|
|
402
|
+
indent: {
|
|
403
|
+
/**
|
|
404
|
+
* Set the indent attribute
|
|
405
|
+
*/
|
|
406
|
+
indent: () => ReturnType;
|
|
407
|
+
/**
|
|
408
|
+
* Set the outdent attribute
|
|
409
|
+
*/
|
|
410
|
+
outdent: () => ReturnType;
|
|
434
411
|
};
|
|
435
412
|
}
|
|
436
413
|
}
|
|
@@ -438,8 +415,8 @@ declare module '@tiptap/core' {
|
|
|
438
415
|
|
|
439
416
|
declare module '@tiptap/core' {
|
|
440
417
|
interface Commands<ReturnType> {
|
|
441
|
-
|
|
442
|
-
|
|
418
|
+
painter: {
|
|
419
|
+
setPainter: (marks: Mark[]) => ReturnType;
|
|
443
420
|
};
|
|
444
421
|
}
|
|
445
422
|
}
|
|
@@ -447,9 +424,14 @@ declare module '@tiptap/core' {
|
|
|
447
424
|
|
|
448
425
|
declare module '@tiptap/core' {
|
|
449
426
|
interface Commands<ReturnType> {
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
427
|
+
iframe: {
|
|
428
|
+
/**
|
|
429
|
+
* Add an iframe
|
|
430
|
+
*/
|
|
431
|
+
setIframe: (options: {
|
|
432
|
+
src: string;
|
|
433
|
+
service: string;
|
|
434
|
+
}) => ReturnType;
|
|
453
435
|
};
|
|
454
436
|
}
|
|
455
437
|
}
|
|
@@ -457,8 +439,29 @@ declare module '@tiptap/core' {
|
|
|
457
439
|
|
|
458
440
|
declare module '@tiptap/core' {
|
|
459
441
|
interface Commands<ReturnType> {
|
|
460
|
-
|
|
461
|
-
|
|
442
|
+
drawer: {
|
|
443
|
+
setDrawer: (options: any, replace?: any) => ReturnType;
|
|
444
|
+
setAlignImageDrawer: (align: 'left' | 'center' | 'right') => ReturnType;
|
|
445
|
+
};
|
|
446
|
+
}
|
|
447
|
+
}
|
|
448
|
+
|
|
449
|
+
|
|
450
|
+
declare module '@tiptap/core' {
|
|
451
|
+
interface Commands<ReturnType> {
|
|
452
|
+
imageGifUpload: {
|
|
453
|
+
/**
|
|
454
|
+
* Add an image gif
|
|
455
|
+
*/
|
|
456
|
+
setImageGif: (options: Partial<SetImageAttrsOptions>) => ReturnType;
|
|
457
|
+
/**
|
|
458
|
+
* Update an image gif
|
|
459
|
+
*/
|
|
460
|
+
updateImageGif: (options: Partial<SetImageAttrsOptions>) => ReturnType;
|
|
461
|
+
/**
|
|
462
|
+
* Set image alignment
|
|
463
|
+
*/
|
|
464
|
+
setAlignImageGif: (align: 'left' | 'center' | 'right') => ReturnType;
|
|
462
465
|
};
|
|
463
466
|
}
|
|
464
467
|
}
|
|
@@ -481,19 +484,8 @@ declare module '@tiptap/core' {
|
|
|
481
484
|
|
|
482
485
|
declare module '@tiptap/core' {
|
|
483
486
|
interface Commands<ReturnType> {
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
* Add an image gif
|
|
487
|
-
*/
|
|
488
|
-
setImageGif: (options: Partial<SetImageAttrsOptions>) => ReturnType;
|
|
489
|
-
/**
|
|
490
|
-
* Update an image gif
|
|
491
|
-
*/
|
|
492
|
-
updateImageGif: (options: Partial<SetImageAttrsOptions>) => ReturnType;
|
|
493
|
-
/**
|
|
494
|
-
* Set image alignment
|
|
495
|
-
*/
|
|
496
|
-
setAlignImageGif: (align: 'left' | 'center' | 'right') => ReturnType;
|
|
487
|
+
exportWord: {
|
|
488
|
+
exportToWord: () => ReturnType;
|
|
497
489
|
};
|
|
498
490
|
}
|
|
499
491
|
}
|
|
@@ -501,9 +493,18 @@ declare module '@tiptap/core' {
|
|
|
501
493
|
|
|
502
494
|
declare module '@tiptap/core' {
|
|
503
495
|
interface Commands<ReturnType> {
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
496
|
+
attachment: {
|
|
497
|
+
setAttachment: (attrs?: unknown) => ReturnType;
|
|
498
|
+
};
|
|
499
|
+
}
|
|
500
|
+
}
|
|
501
|
+
|
|
502
|
+
|
|
503
|
+
declare module '@tiptap/core' {
|
|
504
|
+
interface Commands<ReturnType> {
|
|
505
|
+
tableOfContents: {
|
|
506
|
+
setTableOfContents: () => ReturnType;
|
|
507
|
+
removeTableOfContents: () => ReturnType;
|
|
507
508
|
};
|
|
508
509
|
}
|
|
509
510
|
}
|
package/lib/index.d.ts
CHANGED
|
@@ -62,6 +62,7 @@ declare interface BubbleMenuProps {
|
|
|
62
62
|
* @default false
|
|
63
63
|
*/
|
|
64
64
|
hidden?: boolean;
|
|
65
|
+
onCopy?: (nodeJson: any) => any;
|
|
65
66
|
};
|
|
66
67
|
linkConfig?: {
|
|
67
68
|
/**
|
|
@@ -308,39 +309,9 @@ declare module '@tiptap/core' {
|
|
|
308
309
|
|
|
309
310
|
declare module '@tiptap/core' {
|
|
310
311
|
interface Commands<ReturnType> {
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
*/
|
|
315
|
-
indent: () => ReturnType;
|
|
316
|
-
/**
|
|
317
|
-
* Set the outdent attribute
|
|
318
|
-
*/
|
|
319
|
-
outdent: () => ReturnType;
|
|
320
|
-
};
|
|
321
|
-
}
|
|
322
|
-
}
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
declare module '@tiptap/core' {
|
|
326
|
-
interface Commands<ReturnType> {
|
|
327
|
-
iframe: {
|
|
328
|
-
/**
|
|
329
|
-
* Add an iframe
|
|
330
|
-
*/
|
|
331
|
-
setIframe: (options: {
|
|
332
|
-
src: string;
|
|
333
|
-
service: string;
|
|
334
|
-
}) => ReturnType;
|
|
335
|
-
};
|
|
336
|
-
}
|
|
337
|
-
}
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
declare module '@tiptap/core' {
|
|
341
|
-
interface Commands<ReturnType> {
|
|
342
|
-
painter: {
|
|
343
|
-
setPainter: (marks: Mark[]) => ReturnType;
|
|
312
|
+
lineHeight: {
|
|
313
|
+
setLineHeight: (lineHeight: string) => ReturnType;
|
|
314
|
+
unsetLineHeight: () => ReturnType;
|
|
344
315
|
};
|
|
345
316
|
}
|
|
346
317
|
}
|
|
@@ -368,9 +339,9 @@ declare module '@tiptap/core' {
|
|
|
368
339
|
|
|
369
340
|
declare module '@tiptap/core' {
|
|
370
341
|
interface Commands<ReturnType> {
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
342
|
+
tableCellBackground: {
|
|
343
|
+
setTableCellBackground: (color: string) => ReturnType;
|
|
344
|
+
unsetTableCellBackground: () => ReturnType;
|
|
374
345
|
};
|
|
375
346
|
}
|
|
376
347
|
}
|
|
@@ -390,13 +361,8 @@ declare module '@tiptap/core' {
|
|
|
390
361
|
|
|
391
362
|
declare module '@tiptap/core' {
|
|
392
363
|
interface Commands<ReturnType> {
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
cols: number;
|
|
396
|
-
}) => ReturnType;
|
|
397
|
-
addColBefore: () => ReturnType;
|
|
398
|
-
addColAfter: () => ReturnType;
|
|
399
|
-
deleteCol: () => ReturnType;
|
|
364
|
+
katex: {
|
|
365
|
+
setKatex: (arg?: IKatexAttrs) => ReturnType;
|
|
400
366
|
};
|
|
401
367
|
}
|
|
402
368
|
}
|
|
@@ -404,9 +370,13 @@ declare module '@tiptap/core' {
|
|
|
404
370
|
|
|
405
371
|
declare module '@tiptap/core' {
|
|
406
372
|
interface Commands<ReturnType> {
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
373
|
+
columns: {
|
|
374
|
+
insertColumns: (attrs?: {
|
|
375
|
+
cols: number;
|
|
376
|
+
}) => ReturnType;
|
|
377
|
+
addColBefore: () => ReturnType;
|
|
378
|
+
addColAfter: () => ReturnType;
|
|
379
|
+
deleteCol: () => ReturnType;
|
|
410
380
|
};
|
|
411
381
|
}
|
|
412
382
|
}
|
|
@@ -429,8 +399,15 @@ declare module '@tiptap/core' {
|
|
|
429
399
|
|
|
430
400
|
declare module '@tiptap/core' {
|
|
431
401
|
interface Commands<ReturnType> {
|
|
432
|
-
|
|
433
|
-
|
|
402
|
+
indent: {
|
|
403
|
+
/**
|
|
404
|
+
* Set the indent attribute
|
|
405
|
+
*/
|
|
406
|
+
indent: () => ReturnType;
|
|
407
|
+
/**
|
|
408
|
+
* Set the outdent attribute
|
|
409
|
+
*/
|
|
410
|
+
outdent: () => ReturnType;
|
|
434
411
|
};
|
|
435
412
|
}
|
|
436
413
|
}
|
|
@@ -438,8 +415,8 @@ declare module '@tiptap/core' {
|
|
|
438
415
|
|
|
439
416
|
declare module '@tiptap/core' {
|
|
440
417
|
interface Commands<ReturnType> {
|
|
441
|
-
|
|
442
|
-
|
|
418
|
+
painter: {
|
|
419
|
+
setPainter: (marks: Mark[]) => ReturnType;
|
|
443
420
|
};
|
|
444
421
|
}
|
|
445
422
|
}
|
|
@@ -447,9 +424,14 @@ declare module '@tiptap/core' {
|
|
|
447
424
|
|
|
448
425
|
declare module '@tiptap/core' {
|
|
449
426
|
interface Commands<ReturnType> {
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
427
|
+
iframe: {
|
|
428
|
+
/**
|
|
429
|
+
* Add an iframe
|
|
430
|
+
*/
|
|
431
|
+
setIframe: (options: {
|
|
432
|
+
src: string;
|
|
433
|
+
service: string;
|
|
434
|
+
}) => ReturnType;
|
|
453
435
|
};
|
|
454
436
|
}
|
|
455
437
|
}
|
|
@@ -457,8 +439,29 @@ declare module '@tiptap/core' {
|
|
|
457
439
|
|
|
458
440
|
declare module '@tiptap/core' {
|
|
459
441
|
interface Commands<ReturnType> {
|
|
460
|
-
|
|
461
|
-
|
|
442
|
+
drawer: {
|
|
443
|
+
setDrawer: (options: any, replace?: any) => ReturnType;
|
|
444
|
+
setAlignImageDrawer: (align: 'left' | 'center' | 'right') => ReturnType;
|
|
445
|
+
};
|
|
446
|
+
}
|
|
447
|
+
}
|
|
448
|
+
|
|
449
|
+
|
|
450
|
+
declare module '@tiptap/core' {
|
|
451
|
+
interface Commands<ReturnType> {
|
|
452
|
+
imageGifUpload: {
|
|
453
|
+
/**
|
|
454
|
+
* Add an image gif
|
|
455
|
+
*/
|
|
456
|
+
setImageGif: (options: Partial<SetImageAttrsOptions>) => ReturnType;
|
|
457
|
+
/**
|
|
458
|
+
* Update an image gif
|
|
459
|
+
*/
|
|
460
|
+
updateImageGif: (options: Partial<SetImageAttrsOptions>) => ReturnType;
|
|
461
|
+
/**
|
|
462
|
+
* Set image alignment
|
|
463
|
+
*/
|
|
464
|
+
setAlignImageGif: (align: 'left' | 'center' | 'right') => ReturnType;
|
|
462
465
|
};
|
|
463
466
|
}
|
|
464
467
|
}
|
|
@@ -481,19 +484,8 @@ declare module '@tiptap/core' {
|
|
|
481
484
|
|
|
482
485
|
declare module '@tiptap/core' {
|
|
483
486
|
interface Commands<ReturnType> {
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
* Add an image gif
|
|
487
|
-
*/
|
|
488
|
-
setImageGif: (options: Partial<SetImageAttrsOptions>) => ReturnType;
|
|
489
|
-
/**
|
|
490
|
-
* Update an image gif
|
|
491
|
-
*/
|
|
492
|
-
updateImageGif: (options: Partial<SetImageAttrsOptions>) => ReturnType;
|
|
493
|
-
/**
|
|
494
|
-
* Set image alignment
|
|
495
|
-
*/
|
|
496
|
-
setAlignImageGif: (align: 'left' | 'center' | 'right') => ReturnType;
|
|
487
|
+
exportWord: {
|
|
488
|
+
exportToWord: () => ReturnType;
|
|
497
489
|
};
|
|
498
490
|
}
|
|
499
491
|
}
|
|
@@ -501,9 +493,18 @@ declare module '@tiptap/core' {
|
|
|
501
493
|
|
|
502
494
|
declare module '@tiptap/core' {
|
|
503
495
|
interface Commands<ReturnType> {
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
496
|
+
attachment: {
|
|
497
|
+
setAttachment: (attrs?: unknown) => ReturnType;
|
|
498
|
+
};
|
|
499
|
+
}
|
|
500
|
+
}
|
|
501
|
+
|
|
502
|
+
|
|
503
|
+
declare module '@tiptap/core' {
|
|
504
|
+
interface Commands<ReturnType> {
|
|
505
|
+
tableOfContents: {
|
|
506
|
+
setTableOfContents: () => ReturnType;
|
|
507
|
+
removeTableOfContents: () => ReturnType;
|
|
507
508
|
};
|
|
508
509
|
}
|
|
509
510
|
}
|