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/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
- indent: {
312
- /**
313
- * Set the indent attribute
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
- lineHeight: {
372
- setLineHeight: (lineHeight: string) => ReturnType;
373
- unsetLineHeight: () => ReturnType;
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
- columns: {
394
- insertColumns: (attrs?: {
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
- tableCellBackground: {
408
- setTableCellBackground: (color: string) => ReturnType;
409
- unsetTableCellBackground: () => ReturnType;
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
- katex: {
433
- setKatex: (arg?: IKatexAttrs) => ReturnType;
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
- exportWord: {
442
- exportToWord: () => ReturnType;
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
- tableOfContents: {
451
- setTableOfContents: () => ReturnType;
452
- removeTableOfContents: () => ReturnType;
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
- attachment: {
461
- setAttachment: (attrs?: unknown) => ReturnType;
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
- imageGifUpload: {
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
- drawer: {
505
- setDrawer: (options: any, replace?: any) => ReturnType;
506
- setAlignImageDrawer: (align: 'left' | 'center' | 'right') => ReturnType;
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
- indent: {
312
- /**
313
- * Set the indent attribute
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
- lineHeight: {
372
- setLineHeight: (lineHeight: string) => ReturnType;
373
- unsetLineHeight: () => ReturnType;
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
- columns: {
394
- insertColumns: (attrs?: {
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
- tableCellBackground: {
408
- setTableCellBackground: (color: string) => ReturnType;
409
- unsetTableCellBackground: () => ReturnType;
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
- katex: {
433
- setKatex: (arg?: IKatexAttrs) => ReturnType;
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
- exportWord: {
442
- exportToWord: () => ReturnType;
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
- tableOfContents: {
451
- setTableOfContents: () => ReturnType;
452
- removeTableOfContents: () => ReturnType;
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
- attachment: {
461
- setAttachment: (attrs?: unknown) => ReturnType;
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
- imageGifUpload: {
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
- drawer: {
505
- setDrawer: (options: any, replace?: any) => ReturnType;
506
- setAlignImageDrawer: (align: 'left' | 'center' | 'right') => ReturnType;
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
  }