reactjs-tiptap-editor 0.2.9 → 0.2.11
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/{RichTextEditor-DwHrESsL.js → RichTextEditor-CIenLXbH.js} +2033 -1839
- package/lib/{RichTextEditor-BbpdLvup.cjs → RichTextEditor-DJJ5SBya.cjs} +4 -4
- package/lib/extension-bundle.cjs +3 -3
- package/lib/extension-bundle.d.cts +53 -52
- package/lib/extension-bundle.d.ts +53 -52
- package/lib/extension-bundle.js +501 -494
- package/lib/index.cjs +1 -1
- package/lib/index.d.cts +52 -52
- package/lib/index.d.ts +52 -52
- package/lib/index.js +1 -1
- package/lib/locale-bundle.d.cts +52 -52
- package/lib/locale-bundle.d.ts +52 -52
- package/package.json +2 -2
|
@@ -358,6 +358,7 @@ declare interface IImageOptions extends GeneralOptions<IImageOptions> {
|
|
|
358
358
|
maxSize?: number;
|
|
359
359
|
/** The source URL of the image */
|
|
360
360
|
resourceImage: 'upload' | 'link' | 'both';
|
|
361
|
+
defaultInline?: boolean;
|
|
361
362
|
}
|
|
362
363
|
|
|
363
364
|
declare interface IKatexOptions {
|
|
@@ -699,15 +700,9 @@ declare module '@tiptap/core' {
|
|
|
699
700
|
|
|
700
701
|
declare module '@tiptap/core' {
|
|
701
702
|
interface Commands<ReturnType> {
|
|
702
|
-
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
*/
|
|
706
|
-
indent: () => ReturnType;
|
|
707
|
-
/**
|
|
708
|
-
* Set the outdent attribute
|
|
709
|
-
*/
|
|
710
|
-
outdent: () => ReturnType;
|
|
703
|
+
tableCellBackground: {
|
|
704
|
+
setTableCellBackground: (color: string) => ReturnType;
|
|
705
|
+
unsetTableCellBackground: () => ReturnType;
|
|
711
706
|
};
|
|
712
707
|
}
|
|
713
708
|
}
|
|
@@ -715,9 +710,8 @@ declare module '@tiptap/core' {
|
|
|
715
710
|
|
|
716
711
|
declare module '@tiptap/core' {
|
|
717
712
|
interface Commands<ReturnType> {
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
unsetLineHeight: () => ReturnType;
|
|
713
|
+
painter: {
|
|
714
|
+
setPainter: (marks: Mark[]) => ReturnType;
|
|
721
715
|
};
|
|
722
716
|
}
|
|
723
717
|
}
|
|
@@ -725,9 +719,13 @@ declare module '@tiptap/core' {
|
|
|
725
719
|
|
|
726
720
|
declare module '@tiptap/core' {
|
|
727
721
|
interface Commands<ReturnType> {
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
722
|
+
columns: {
|
|
723
|
+
insertColumns: (attrs?: {
|
|
724
|
+
cols: number;
|
|
725
|
+
}) => ReturnType;
|
|
726
|
+
addColBefore: () => ReturnType;
|
|
727
|
+
addColAfter: () => ReturnType;
|
|
728
|
+
deleteCol: () => ReturnType;
|
|
731
729
|
};
|
|
732
730
|
}
|
|
733
731
|
}
|
|
@@ -735,19 +733,15 @@ declare module '@tiptap/core' {
|
|
|
735
733
|
|
|
736
734
|
declare module '@tiptap/core' {
|
|
737
735
|
interface Commands<ReturnType> {
|
|
738
|
-
|
|
739
|
-
/**
|
|
740
|
-
* Add an image
|
|
741
|
-
*/
|
|
742
|
-
setImageInline: (options: Partial<SetImageAttrsOptions>) => ReturnType;
|
|
736
|
+
indent: {
|
|
743
737
|
/**
|
|
744
|
-
*
|
|
738
|
+
* Set the indent attribute
|
|
745
739
|
*/
|
|
746
|
-
|
|
740
|
+
indent: () => ReturnType;
|
|
747
741
|
/**
|
|
748
|
-
* Set
|
|
742
|
+
* Set the outdent attribute
|
|
749
743
|
*/
|
|
750
|
-
|
|
744
|
+
outdent: () => ReturnType;
|
|
751
745
|
};
|
|
752
746
|
}
|
|
753
747
|
}
|
|
@@ -755,8 +749,21 @@ declare module '@tiptap/core' {
|
|
|
755
749
|
|
|
756
750
|
declare module '@tiptap/core' {
|
|
757
751
|
interface Commands<ReturnType> {
|
|
758
|
-
|
|
759
|
-
|
|
752
|
+
lineHeight: {
|
|
753
|
+
setLineHeight: (lineHeight: string) => ReturnType;
|
|
754
|
+
unsetLineHeight: () => ReturnType;
|
|
755
|
+
};
|
|
756
|
+
}
|
|
757
|
+
}
|
|
758
|
+
|
|
759
|
+
|
|
760
|
+
declare module '@tiptap/core' {
|
|
761
|
+
interface Commands<ReturnType> {
|
|
762
|
+
emoji: {
|
|
763
|
+
setEmoji: (emoji: {
|
|
764
|
+
name: string;
|
|
765
|
+
emoji: string;
|
|
766
|
+
}) => ReturnType;
|
|
760
767
|
};
|
|
761
768
|
}
|
|
762
769
|
}
|
|
@@ -779,8 +786,19 @@ declare module '@tiptap/core' {
|
|
|
779
786
|
|
|
780
787
|
declare module '@tiptap/core' {
|
|
781
788
|
interface Commands<ReturnType> {
|
|
782
|
-
|
|
783
|
-
|
|
789
|
+
imageUpload: {
|
|
790
|
+
/**
|
|
791
|
+
* Add an image
|
|
792
|
+
*/
|
|
793
|
+
setImageInline: (options: Partial<SetImageAttrsOptions>) => ReturnType;
|
|
794
|
+
/**
|
|
795
|
+
* Update an image
|
|
796
|
+
*/
|
|
797
|
+
updateImage: (options: Partial<SetImageAttrsOptions>) => ReturnType;
|
|
798
|
+
/**
|
|
799
|
+
* Set image alignment
|
|
800
|
+
*/
|
|
801
|
+
setAlignImage: (align: 'left' | 'center' | 'right') => ReturnType;
|
|
784
802
|
};
|
|
785
803
|
}
|
|
786
804
|
}
|
|
@@ -803,25 +821,8 @@ declare module '@tiptap/core' {
|
|
|
803
821
|
|
|
804
822
|
declare module '@tiptap/core' {
|
|
805
823
|
interface Commands<ReturnType> {
|
|
806
|
-
|
|
807
|
-
|
|
808
|
-
cols: number;
|
|
809
|
-
}) => ReturnType;
|
|
810
|
-
addColBefore: () => ReturnType;
|
|
811
|
-
addColAfter: () => ReturnType;
|
|
812
|
-
deleteCol: () => ReturnType;
|
|
813
|
-
};
|
|
814
|
-
}
|
|
815
|
-
}
|
|
816
|
-
|
|
817
|
-
|
|
818
|
-
declare module '@tiptap/core' {
|
|
819
|
-
interface Commands<ReturnType> {
|
|
820
|
-
emoji: {
|
|
821
|
-
setEmoji: (emoji: {
|
|
822
|
-
name: string;
|
|
823
|
-
emoji: string;
|
|
824
|
-
}) => ReturnType;
|
|
824
|
+
katex: {
|
|
825
|
+
setKatex: (arg?: IKatexAttrs) => ReturnType;
|
|
825
826
|
};
|
|
826
827
|
}
|
|
827
828
|
}
|
|
@@ -857,9 +858,8 @@ declare module '@tiptap/core' {
|
|
|
857
858
|
|
|
858
859
|
declare module '@tiptap/core' {
|
|
859
860
|
interface Commands<ReturnType> {
|
|
860
|
-
|
|
861
|
-
|
|
862
|
-
setAlignImageMermaid: (align: 'left' | 'center' | 'right') => ReturnType;
|
|
861
|
+
attachment: {
|
|
862
|
+
setAttachment: (attrs?: unknown) => ReturnType;
|
|
863
863
|
};
|
|
864
864
|
}
|
|
865
865
|
}
|
|
@@ -912,8 +912,9 @@ declare module '@tiptap/core' {
|
|
|
912
912
|
|
|
913
913
|
declare module '@tiptap/core' {
|
|
914
914
|
interface Commands<ReturnType> {
|
|
915
|
-
|
|
916
|
-
|
|
915
|
+
mermaid: {
|
|
916
|
+
setMermaid: (options: any, replace?: any) => ReturnType;
|
|
917
|
+
setAlignImageMermaid: (align: 'left' | 'center' | 'right') => ReturnType;
|
|
917
918
|
};
|
|
918
919
|
}
|
|
919
920
|
}
|
|
@@ -358,6 +358,7 @@ declare interface IImageOptions extends GeneralOptions<IImageOptions> {
|
|
|
358
358
|
maxSize?: number;
|
|
359
359
|
/** The source URL of the image */
|
|
360
360
|
resourceImage: 'upload' | 'link' | 'both';
|
|
361
|
+
defaultInline?: boolean;
|
|
361
362
|
}
|
|
362
363
|
|
|
363
364
|
declare interface IKatexOptions {
|
|
@@ -699,15 +700,9 @@ declare module '@tiptap/core' {
|
|
|
699
700
|
|
|
700
701
|
declare module '@tiptap/core' {
|
|
701
702
|
interface Commands<ReturnType> {
|
|
702
|
-
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
*/
|
|
706
|
-
indent: () => ReturnType;
|
|
707
|
-
/**
|
|
708
|
-
* Set the outdent attribute
|
|
709
|
-
*/
|
|
710
|
-
outdent: () => ReturnType;
|
|
703
|
+
tableCellBackground: {
|
|
704
|
+
setTableCellBackground: (color: string) => ReturnType;
|
|
705
|
+
unsetTableCellBackground: () => ReturnType;
|
|
711
706
|
};
|
|
712
707
|
}
|
|
713
708
|
}
|
|
@@ -715,9 +710,8 @@ declare module '@tiptap/core' {
|
|
|
715
710
|
|
|
716
711
|
declare module '@tiptap/core' {
|
|
717
712
|
interface Commands<ReturnType> {
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
unsetLineHeight: () => ReturnType;
|
|
713
|
+
painter: {
|
|
714
|
+
setPainter: (marks: Mark[]) => ReturnType;
|
|
721
715
|
};
|
|
722
716
|
}
|
|
723
717
|
}
|
|
@@ -725,9 +719,13 @@ declare module '@tiptap/core' {
|
|
|
725
719
|
|
|
726
720
|
declare module '@tiptap/core' {
|
|
727
721
|
interface Commands<ReturnType> {
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
722
|
+
columns: {
|
|
723
|
+
insertColumns: (attrs?: {
|
|
724
|
+
cols: number;
|
|
725
|
+
}) => ReturnType;
|
|
726
|
+
addColBefore: () => ReturnType;
|
|
727
|
+
addColAfter: () => ReturnType;
|
|
728
|
+
deleteCol: () => ReturnType;
|
|
731
729
|
};
|
|
732
730
|
}
|
|
733
731
|
}
|
|
@@ -735,19 +733,15 @@ declare module '@tiptap/core' {
|
|
|
735
733
|
|
|
736
734
|
declare module '@tiptap/core' {
|
|
737
735
|
interface Commands<ReturnType> {
|
|
738
|
-
|
|
739
|
-
/**
|
|
740
|
-
* Add an image
|
|
741
|
-
*/
|
|
742
|
-
setImageInline: (options: Partial<SetImageAttrsOptions>) => ReturnType;
|
|
736
|
+
indent: {
|
|
743
737
|
/**
|
|
744
|
-
*
|
|
738
|
+
* Set the indent attribute
|
|
745
739
|
*/
|
|
746
|
-
|
|
740
|
+
indent: () => ReturnType;
|
|
747
741
|
/**
|
|
748
|
-
* Set
|
|
742
|
+
* Set the outdent attribute
|
|
749
743
|
*/
|
|
750
|
-
|
|
744
|
+
outdent: () => ReturnType;
|
|
751
745
|
};
|
|
752
746
|
}
|
|
753
747
|
}
|
|
@@ -755,8 +749,21 @@ declare module '@tiptap/core' {
|
|
|
755
749
|
|
|
756
750
|
declare module '@tiptap/core' {
|
|
757
751
|
interface Commands<ReturnType> {
|
|
758
|
-
|
|
759
|
-
|
|
752
|
+
lineHeight: {
|
|
753
|
+
setLineHeight: (lineHeight: string) => ReturnType;
|
|
754
|
+
unsetLineHeight: () => ReturnType;
|
|
755
|
+
};
|
|
756
|
+
}
|
|
757
|
+
}
|
|
758
|
+
|
|
759
|
+
|
|
760
|
+
declare module '@tiptap/core' {
|
|
761
|
+
interface Commands<ReturnType> {
|
|
762
|
+
emoji: {
|
|
763
|
+
setEmoji: (emoji: {
|
|
764
|
+
name: string;
|
|
765
|
+
emoji: string;
|
|
766
|
+
}) => ReturnType;
|
|
760
767
|
};
|
|
761
768
|
}
|
|
762
769
|
}
|
|
@@ -779,8 +786,19 @@ declare module '@tiptap/core' {
|
|
|
779
786
|
|
|
780
787
|
declare module '@tiptap/core' {
|
|
781
788
|
interface Commands<ReturnType> {
|
|
782
|
-
|
|
783
|
-
|
|
789
|
+
imageUpload: {
|
|
790
|
+
/**
|
|
791
|
+
* Add an image
|
|
792
|
+
*/
|
|
793
|
+
setImageInline: (options: Partial<SetImageAttrsOptions>) => ReturnType;
|
|
794
|
+
/**
|
|
795
|
+
* Update an image
|
|
796
|
+
*/
|
|
797
|
+
updateImage: (options: Partial<SetImageAttrsOptions>) => ReturnType;
|
|
798
|
+
/**
|
|
799
|
+
* Set image alignment
|
|
800
|
+
*/
|
|
801
|
+
setAlignImage: (align: 'left' | 'center' | 'right') => ReturnType;
|
|
784
802
|
};
|
|
785
803
|
}
|
|
786
804
|
}
|
|
@@ -803,25 +821,8 @@ declare module '@tiptap/core' {
|
|
|
803
821
|
|
|
804
822
|
declare module '@tiptap/core' {
|
|
805
823
|
interface Commands<ReturnType> {
|
|
806
|
-
|
|
807
|
-
|
|
808
|
-
cols: number;
|
|
809
|
-
}) => ReturnType;
|
|
810
|
-
addColBefore: () => ReturnType;
|
|
811
|
-
addColAfter: () => ReturnType;
|
|
812
|
-
deleteCol: () => ReturnType;
|
|
813
|
-
};
|
|
814
|
-
}
|
|
815
|
-
}
|
|
816
|
-
|
|
817
|
-
|
|
818
|
-
declare module '@tiptap/core' {
|
|
819
|
-
interface Commands<ReturnType> {
|
|
820
|
-
emoji: {
|
|
821
|
-
setEmoji: (emoji: {
|
|
822
|
-
name: string;
|
|
823
|
-
emoji: string;
|
|
824
|
-
}) => ReturnType;
|
|
824
|
+
katex: {
|
|
825
|
+
setKatex: (arg?: IKatexAttrs) => ReturnType;
|
|
825
826
|
};
|
|
826
827
|
}
|
|
827
828
|
}
|
|
@@ -857,9 +858,8 @@ declare module '@tiptap/core' {
|
|
|
857
858
|
|
|
858
859
|
declare module '@tiptap/core' {
|
|
859
860
|
interface Commands<ReturnType> {
|
|
860
|
-
|
|
861
|
-
|
|
862
|
-
setAlignImageMermaid: (align: 'left' | 'center' | 'right') => ReturnType;
|
|
861
|
+
attachment: {
|
|
862
|
+
setAttachment: (attrs?: unknown) => ReturnType;
|
|
863
863
|
};
|
|
864
864
|
}
|
|
865
865
|
}
|
|
@@ -912,8 +912,9 @@ declare module '@tiptap/core' {
|
|
|
912
912
|
|
|
913
913
|
declare module '@tiptap/core' {
|
|
914
914
|
interface Commands<ReturnType> {
|
|
915
|
-
|
|
916
|
-
|
|
915
|
+
mermaid: {
|
|
916
|
+
setMermaid: (options: any, replace?: any) => ReturnType;
|
|
917
|
+
setAlignImageMermaid: (align: 'left' | 'center' | 'right') => ReturnType;
|
|
917
918
|
};
|
|
918
919
|
}
|
|
919
920
|
}
|