reactjs-tiptap-editor 0.2.25 → 0.2.26
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-C_dIT2FZ.js → RichTextEditor-DH6J2is9.js} +3 -3
- package/lib/extension-bundle.d.cts +28 -28
- package/lib/extension-bundle.d.ts +28 -28
- package/lib/extension-bundle.js +5 -5
- package/lib/{index-BlV5SJJW.js → index-CO-iymkb.js} +1 -1
- package/lib/index.d.cts +28 -28
- package/lib/index.d.ts +28 -28
- package/lib/index.js +2 -2
- package/lib/locale-bundle.d.cts +28 -28
- package/lib/locale-bundle.d.ts +28 -28
- package/lib/locale-bundle.js +1 -1
- package/lib/{tiptap-CXio79KB.js → tiptap-DOP8lVCQ.js} +1 -1
- package/lib/{vendor-VlEklMUJ.js → vendor-BbgkyoD-.js} +45 -72
- package/package.json +2 -2
|
@@ -4,10 +4,10 @@ var Xt = (t, e, r) => mi(t, typeof e != "symbol" ? e + "" : e, r);
|
|
|
4
4
|
import { jsxs as g, jsx as i, Fragment as V } from "react/jsx-runtime";
|
|
5
5
|
import * as W from "react";
|
|
6
6
|
import Ht, { createContext as xi, useContext as fi, useSyncExternalStore as gi, useRef as J, useCallback as H, useState as S, useEffect as B, useMemo as U, Fragment as Pe, memo as pi, forwardRef as wi, useId as vi, useImperativeHandle as bi, useLayoutEffect as yi } from "react";
|
|
7
|
-
import { Q as re, b as yt, m as st, V as Ci, N as gt, W as de, R as pt, X as Re, Y as ie, Z as Ti, B as tt, _ as Ni, $ as ki, a0 as Si } from "./tiptap-
|
|
8
|
-
import { u as q, I as xt, n as ft, o as he, V as Ce, p as Mi, C as Ai, h as Z, B as Li, q as ne, E as Ii } from "./index-
|
|
7
|
+
import { Q as re, b as yt, m as st, V as Ci, N as gt, W as de, R as pt, X as Re, Y as ie, Z as Ti, B as tt, _ as Ni, $ as ki, a0 as Si } from "./tiptap-DOP8lVCQ.js";
|
|
8
|
+
import { u as q, I as xt, n as ft, o as he, V as Ce, p as Mi, C as Ai, h as Z, B as Li, q as ne, E as Ii } from "./index-CO-iymkb.js";
|
|
9
9
|
import * as br from "@radix-ui/react-separator";
|
|
10
|
-
import { ax as Ei, at as oe, ak as zi, ay as ue, au as Oe, T as Wt, N as Pi, A as Ri, az as ae, aA as ht, aB as yr, b as He, P as De, a0 as Oi, $ as Hi, av as Cr, aC as Di, aD as me, aE as _i, H as Ft, aF as Bi, aG as $i, S as Vi, aH as Wi, aI as Fi } from "./vendor-
|
|
10
|
+
import { ax as Ei, at as oe, ak as zi, ay as ue, au as Oe, T as Wt, N as Pi, A as Ri, az as ae, aA as ht, aB as yr, b as He, P as De, a0 as Oi, $ as Hi, av as Cr, aC as Di, aD as me, aE as _i, H as Ft, aF as Bi, aG as $i, S as Vi, aH as Wi, aI as Fi } from "./vendor-BbgkyoD-.js";
|
|
11
11
|
import * as et from "@radix-ui/react-toast";
|
|
12
12
|
import { ChevronRight as Ui, Check as Tr, Circle as Gi, X as Nr, WrapText as qi, PencilRuler as ji, FlipHorizontal as Xi, FlipVertical as Yi, CropIcon as Ki, ChevronUp as Zi, Paperclip as Ji, Eye as Qi, Settings as tn, ZoomOut as en, ZoomIn as rn, BookMarked as nn, Sigma as on, SmilePlusIcon as an, Replace as Ze, SmilePlus as cn, Frame as sn, Columns2 as Je, PanelRight as ln, PanelLeft as dn, Clipboard as hn, Copy as un, GripVertical as mn, Plus as kr, Columns4 as xn, Columns3 as fn, Heading6 as gn, Heading5 as pn, Heading4 as wn, Heading3 as vn, Heading2 as bn, Heading1 as yn, ChevronsUpDown as Cn, Trash as Tn, Trash2 as Sr, TableCellsSplit as Nn, TableCellsMerge as kn, BetweenVerticalEnd as Sn, BetweenVerticalStart as Mn, BetweenHorizonalStart as An, BetweenHorizonalEnd as Ln, Unlink as In, Pencil as Mr, Sparkles as En, Table as zn, Minimize as Pn, Maximize as Rn, Video as On, ImageUp as Hn, Link as Dn, ListTodo as _n, ListOrdered as Bn, List as $n, IndentDecrease as Vn, IndentIncrease as Wn, Type as Fn, CodeXml as Un, Code as Gn, Superscript as qn, Subscript as jn, ChevronDown as Xn, Undo2 as Yn, Redo2 as Kn, PaintRoller as Zn, Eraser as Jn, Minus as Qn, Strikethrough as to, Quote as eo, Underline as ro, Italic as io, LoaderCircle as no, Bold as oo, HelpCircle as Ar } from "lucide-react";
|
|
13
13
|
import * as Ut from "@radix-ui/react-tooltip";
|
|
@@ -775,16 +775,6 @@ declare module '@tiptap/core' {
|
|
|
775
775
|
}
|
|
776
776
|
|
|
777
777
|
|
|
778
|
-
declare module '@tiptap/core' {
|
|
779
|
-
interface Commands<ReturnType> {
|
|
780
|
-
tableCellBackground: {
|
|
781
|
-
setTableCellBackground: (color: string) => ReturnType;
|
|
782
|
-
unsetTableCellBackground: () => ReturnType;
|
|
783
|
-
};
|
|
784
|
-
}
|
|
785
|
-
}
|
|
786
|
-
|
|
787
|
-
|
|
788
778
|
declare module '@tiptap/core' {
|
|
789
779
|
interface Commands<ReturnType> {
|
|
790
780
|
painter: {
|
|
@@ -823,6 +813,16 @@ declare module '@tiptap/core' {
|
|
|
823
813
|
}
|
|
824
814
|
|
|
825
815
|
|
|
816
|
+
declare module '@tiptap/core' {
|
|
817
|
+
interface Commands<ReturnType> {
|
|
818
|
+
tableCellBackground: {
|
|
819
|
+
setTableCellBackground: (color: string) => ReturnType;
|
|
820
|
+
unsetTableCellBackground: () => ReturnType;
|
|
821
|
+
};
|
|
822
|
+
}
|
|
823
|
+
}
|
|
824
|
+
|
|
825
|
+
|
|
826
826
|
declare module '@tiptap/core' {
|
|
827
827
|
interface Commands<ReturnType> {
|
|
828
828
|
search: {
|
|
@@ -838,6 +838,15 @@ declare module '@tiptap/core' {
|
|
|
838
838
|
}
|
|
839
839
|
|
|
840
840
|
|
|
841
|
+
declare module '@tiptap/core' {
|
|
842
|
+
interface Commands<ReturnType> {
|
|
843
|
+
katex: {
|
|
844
|
+
setKatex: (arg?: IKatexAttrs) => ReturnType;
|
|
845
|
+
};
|
|
846
|
+
}
|
|
847
|
+
}
|
|
848
|
+
|
|
849
|
+
|
|
841
850
|
declare module '@tiptap/core' {
|
|
842
851
|
interface Commands<ReturnType> {
|
|
843
852
|
emoji: {
|
|
@@ -852,8 +861,8 @@ declare module '@tiptap/core' {
|
|
|
852
861
|
|
|
853
862
|
declare module '@tiptap/core' {
|
|
854
863
|
interface Commands<ReturnType> {
|
|
855
|
-
|
|
856
|
-
|
|
864
|
+
exportWord: {
|
|
865
|
+
exportToWord: () => ReturnType;
|
|
857
866
|
};
|
|
858
867
|
}
|
|
859
868
|
}
|
|
@@ -861,9 +870,8 @@ declare module '@tiptap/core' {
|
|
|
861
870
|
|
|
862
871
|
declare module '@tiptap/core' {
|
|
863
872
|
interface Commands<ReturnType> {
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
removeTableOfContents: () => ReturnType;
|
|
873
|
+
excalidraw: {
|
|
874
|
+
setExcalidraw: (attrs?: IExcalidrawAttrs) => ReturnType;
|
|
867
875
|
};
|
|
868
876
|
}
|
|
869
877
|
}
|
|
@@ -871,8 +879,9 @@ declare module '@tiptap/core' {
|
|
|
871
879
|
|
|
872
880
|
declare module '@tiptap/core' {
|
|
873
881
|
interface Commands<ReturnType> {
|
|
874
|
-
|
|
875
|
-
|
|
882
|
+
tableOfContents: {
|
|
883
|
+
setTableOfContents: () => ReturnType;
|
|
884
|
+
removeTableOfContents: () => ReturnType;
|
|
876
885
|
};
|
|
877
886
|
}
|
|
878
887
|
}
|
|
@@ -880,8 +889,8 @@ declare module '@tiptap/core' {
|
|
|
880
889
|
|
|
881
890
|
declare module '@tiptap/core' {
|
|
882
891
|
interface Commands<ReturnType> {
|
|
883
|
-
|
|
884
|
-
|
|
892
|
+
attachment: {
|
|
893
|
+
setAttachment: (attrs?: unknown) => ReturnType;
|
|
885
894
|
};
|
|
886
895
|
}
|
|
887
896
|
}
|
|
@@ -907,15 +916,6 @@ declare module '@tiptap/core' {
|
|
|
907
916
|
}
|
|
908
917
|
|
|
909
918
|
|
|
910
|
-
declare module '@tiptap/core' {
|
|
911
|
-
interface Commands<ReturnType> {
|
|
912
|
-
attachment: {
|
|
913
|
-
setAttachment: (attrs?: unknown) => ReturnType;
|
|
914
|
-
};
|
|
915
|
-
}
|
|
916
|
-
}
|
|
917
|
-
|
|
918
|
-
|
|
919
919
|
declare module '@tiptap/core' {
|
|
920
920
|
interface Commands<ReturnType> {
|
|
921
921
|
mermaid: {
|
|
@@ -775,16 +775,6 @@ declare module '@tiptap/core' {
|
|
|
775
775
|
}
|
|
776
776
|
|
|
777
777
|
|
|
778
|
-
declare module '@tiptap/core' {
|
|
779
|
-
interface Commands<ReturnType> {
|
|
780
|
-
tableCellBackground: {
|
|
781
|
-
setTableCellBackground: (color: string) => ReturnType;
|
|
782
|
-
unsetTableCellBackground: () => ReturnType;
|
|
783
|
-
};
|
|
784
|
-
}
|
|
785
|
-
}
|
|
786
|
-
|
|
787
|
-
|
|
788
778
|
declare module '@tiptap/core' {
|
|
789
779
|
interface Commands<ReturnType> {
|
|
790
780
|
painter: {
|
|
@@ -823,6 +813,16 @@ declare module '@tiptap/core' {
|
|
|
823
813
|
}
|
|
824
814
|
|
|
825
815
|
|
|
816
|
+
declare module '@tiptap/core' {
|
|
817
|
+
interface Commands<ReturnType> {
|
|
818
|
+
tableCellBackground: {
|
|
819
|
+
setTableCellBackground: (color: string) => ReturnType;
|
|
820
|
+
unsetTableCellBackground: () => ReturnType;
|
|
821
|
+
};
|
|
822
|
+
}
|
|
823
|
+
}
|
|
824
|
+
|
|
825
|
+
|
|
826
826
|
declare module '@tiptap/core' {
|
|
827
827
|
interface Commands<ReturnType> {
|
|
828
828
|
search: {
|
|
@@ -838,6 +838,15 @@ declare module '@tiptap/core' {
|
|
|
838
838
|
}
|
|
839
839
|
|
|
840
840
|
|
|
841
|
+
declare module '@tiptap/core' {
|
|
842
|
+
interface Commands<ReturnType> {
|
|
843
|
+
katex: {
|
|
844
|
+
setKatex: (arg?: IKatexAttrs) => ReturnType;
|
|
845
|
+
};
|
|
846
|
+
}
|
|
847
|
+
}
|
|
848
|
+
|
|
849
|
+
|
|
841
850
|
declare module '@tiptap/core' {
|
|
842
851
|
interface Commands<ReturnType> {
|
|
843
852
|
emoji: {
|
|
@@ -852,8 +861,8 @@ declare module '@tiptap/core' {
|
|
|
852
861
|
|
|
853
862
|
declare module '@tiptap/core' {
|
|
854
863
|
interface Commands<ReturnType> {
|
|
855
|
-
|
|
856
|
-
|
|
864
|
+
exportWord: {
|
|
865
|
+
exportToWord: () => ReturnType;
|
|
857
866
|
};
|
|
858
867
|
}
|
|
859
868
|
}
|
|
@@ -861,9 +870,8 @@ declare module '@tiptap/core' {
|
|
|
861
870
|
|
|
862
871
|
declare module '@tiptap/core' {
|
|
863
872
|
interface Commands<ReturnType> {
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
removeTableOfContents: () => ReturnType;
|
|
873
|
+
excalidraw: {
|
|
874
|
+
setExcalidraw: (attrs?: IExcalidrawAttrs) => ReturnType;
|
|
867
875
|
};
|
|
868
876
|
}
|
|
869
877
|
}
|
|
@@ -871,8 +879,9 @@ declare module '@tiptap/core' {
|
|
|
871
879
|
|
|
872
880
|
declare module '@tiptap/core' {
|
|
873
881
|
interface Commands<ReturnType> {
|
|
874
|
-
|
|
875
|
-
|
|
882
|
+
tableOfContents: {
|
|
883
|
+
setTableOfContents: () => ReturnType;
|
|
884
|
+
removeTableOfContents: () => ReturnType;
|
|
876
885
|
};
|
|
877
886
|
}
|
|
878
887
|
}
|
|
@@ -880,8 +889,8 @@ declare module '@tiptap/core' {
|
|
|
880
889
|
|
|
881
890
|
declare module '@tiptap/core' {
|
|
882
891
|
interface Commands<ReturnType> {
|
|
883
|
-
|
|
884
|
-
|
|
892
|
+
attachment: {
|
|
893
|
+
setAttachment: (attrs?: unknown) => ReturnType;
|
|
885
894
|
};
|
|
886
895
|
}
|
|
887
896
|
}
|
|
@@ -907,15 +916,6 @@ declare module '@tiptap/core' {
|
|
|
907
916
|
}
|
|
908
917
|
|
|
909
918
|
|
|
910
|
-
declare module '@tiptap/core' {
|
|
911
|
-
interface Commands<ReturnType> {
|
|
912
|
-
attachment: {
|
|
913
|
-
setAttachment: (attrs?: unknown) => ReturnType;
|
|
914
|
-
};
|
|
915
|
-
}
|
|
916
|
-
}
|
|
917
|
-
|
|
918
|
-
|
|
919
919
|
declare module '@tiptap/core' {
|
|
920
920
|
interface Commands<ReturnType> {
|
|
921
921
|
mermaid: {
|
package/lib/extension-bundle.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { a as ft, I as _t, U as gt, S as bt, C as xt, N as ae, b as oe, t as qe, R as Le, m as re, F as wt, H as pt, T as yt, E as C, c as vt, d as kt, e as Ct, O as Nt, f as At, g as Tt, h as St, L as Lt, i as Et, j as Ht, k as zt, D as Mt, P as Rt, l as It, n as Pt, G as jt, o as Bt, p as Ot, q as Dt, r as $t, s as Ft, u as qt, v as nt, w as it, x as at, y as Ee, z as Ut, A as Kt, J as Vt, K as Wt, M as Gt } from "./tiptap-
|
|
2
|
-
import { u as I, D as Zt, f as Jt, g as Ue, h as N, i as ot, j as Yt, T as le, k as de, m as ue } from "./index-
|
|
3
|
-
import { i as He, T as xe, a as we, B as K, b as pe, g as ze, A as x, c as E, u as Me, j as Qt, k as A, l as Z, m as J, n as Y, o as Q, p as rt, q as Ne, r as Xt, s as Re, P as X, t as ee, v as te, w as Ie, x as en, H as tn, L as nn, C as an, M as on, y as rn, z as Ke, F as he, G as U, J as j, I as sn, N as cn, V as ln, O as Ve, Q as ve, S as We, U as dn, W as un, X as hn, Y as P, Z as mn, _ as fn, $ as _n, a0 as gn, a1 as bn, a2 as st } from "./RichTextEditor-
|
|
4
|
-
import { D as Lo, E as Eo, d as Ho, e as zo, K as Mo, f as Ro, h as Io } from "./RichTextEditor-
|
|
5
|
-
import { al as xn, am as wn, an as pn, ao as yn, ap as vn, aq as kn, ar as Cn, as as Nn, at as R, au as An, P as se, T as ct, b as ne, $ as ge, a0 as be, A as Tn, a4 as Sn, av as Ln, aw as En } from "./vendor-
|
|
1
|
+
import { a as ft, I as _t, U as gt, S as bt, C as xt, N as ae, b as oe, t as qe, R as Le, m as re, F as wt, H as pt, T as yt, E as C, c as vt, d as kt, e as Ct, O as Nt, f as At, g as Tt, h as St, L as Lt, i as Et, j as Ht, k as zt, D as Mt, P as Rt, l as It, n as Pt, G as jt, o as Bt, p as Ot, q as Dt, r as $t, s as Ft, u as qt, v as nt, w as it, x as at, y as Ee, z as Ut, A as Kt, J as Vt, K as Wt, M as Gt } from "./tiptap-DOP8lVCQ.js";
|
|
2
|
+
import { u as I, D as Zt, f as Jt, g as Ue, h as N, i as ot, j as Yt, T as le, k as de, m as ue } from "./index-CO-iymkb.js";
|
|
3
|
+
import { i as He, T as xe, a as we, B as K, b as pe, g as ze, A as x, c as E, u as Me, j as Qt, k as A, l as Z, m as J, n as Y, o as Q, p as rt, q as Ne, r as Xt, s as Re, P as X, t as ee, v as te, w as Ie, x as en, H as tn, L as nn, C as an, M as on, y as rn, z as Ke, F as he, G as U, J as j, I as sn, N as cn, V as ln, O as Ve, Q as ve, S as We, U as dn, W as un, X as hn, Y as P, Z as mn, _ as fn, $ as _n, a0 as gn, a1 as bn, a2 as st } from "./RichTextEditor-DH6J2is9.js";
|
|
4
|
+
import { D as Lo, E as Eo, d as Ho, e as zo, K as Mo, f as Ro, h as Io } from "./RichTextEditor-DH6J2is9.js";
|
|
5
|
+
import { al as xn, am as wn, an as pn, ao as yn, ap as vn, aq as kn, ar as Cn, as as Nn, at as R, au as An, P as se, T as ct, b as ne, $ as ge, a0 as be, A as Tn, a4 as Sn, av as Ln, aw as En } from "./vendor-BbgkyoD-.js";
|
|
6
6
|
import Pe from "tippy.js";
|
|
7
7
|
import { Packer as Hn, WidthType as zn } from "docx";
|
|
8
8
|
import { DocxSerializer as Mn, defaultNodes as F, defaultMarks as Rn } from "prosemirror-docx";
|
|
@@ -2,7 +2,7 @@ var p = Object.defineProperty;
|
|
|
2
2
|
var s = (e, t, o) => t in e ? p(e, t, { enumerable: !0, configurable: !0, writable: !0, value: o }) : e[t] = o;
|
|
3
3
|
var a = (e, t, o) => s(e, typeof t != "symbol" ? t + "" : t, o);
|
|
4
4
|
import { useMemo as m, useEffect as g } from "react";
|
|
5
|
-
import { aj as u, ak as c } from "./vendor-
|
|
5
|
+
import { aj as u, ak as c } from "./vendor-BbgkyoD-.js";
|
|
6
6
|
const h = "en", b = 200, E = b - 80, L = 20, S = 1e5, w = 16, B = 10, R = 10, I = 2, W = [
|
|
7
7
|
"#000000",
|
|
8
8
|
"#262626",
|
package/lib/index.d.cts
CHANGED
|
@@ -344,16 +344,6 @@ declare module '@tiptap/core' {
|
|
|
344
344
|
}
|
|
345
345
|
|
|
346
346
|
|
|
347
|
-
declare module '@tiptap/core' {
|
|
348
|
-
interface Commands<ReturnType> {
|
|
349
|
-
tableCellBackground: {
|
|
350
|
-
setTableCellBackground: (color: string) => ReturnType;
|
|
351
|
-
unsetTableCellBackground: () => ReturnType;
|
|
352
|
-
};
|
|
353
|
-
}
|
|
354
|
-
}
|
|
355
|
-
|
|
356
|
-
|
|
357
347
|
declare module '@tiptap/core' {
|
|
358
348
|
interface Commands<ReturnType> {
|
|
359
349
|
painter: {
|
|
@@ -392,6 +382,16 @@ declare module '@tiptap/core' {
|
|
|
392
382
|
}
|
|
393
383
|
|
|
394
384
|
|
|
385
|
+
declare module '@tiptap/core' {
|
|
386
|
+
interface Commands<ReturnType> {
|
|
387
|
+
tableCellBackground: {
|
|
388
|
+
setTableCellBackground: (color: string) => ReturnType;
|
|
389
|
+
unsetTableCellBackground: () => ReturnType;
|
|
390
|
+
};
|
|
391
|
+
}
|
|
392
|
+
}
|
|
393
|
+
|
|
394
|
+
|
|
395
395
|
declare module '@tiptap/core' {
|
|
396
396
|
interface Commands<ReturnType> {
|
|
397
397
|
search: {
|
|
@@ -407,6 +407,15 @@ declare module '@tiptap/core' {
|
|
|
407
407
|
}
|
|
408
408
|
|
|
409
409
|
|
|
410
|
+
declare module '@tiptap/core' {
|
|
411
|
+
interface Commands<ReturnType> {
|
|
412
|
+
katex: {
|
|
413
|
+
setKatex: (arg?: IKatexAttrs) => ReturnType;
|
|
414
|
+
};
|
|
415
|
+
}
|
|
416
|
+
}
|
|
417
|
+
|
|
418
|
+
|
|
410
419
|
declare module '@tiptap/core' {
|
|
411
420
|
interface Commands<ReturnType> {
|
|
412
421
|
emoji: {
|
|
@@ -421,8 +430,8 @@ declare module '@tiptap/core' {
|
|
|
421
430
|
|
|
422
431
|
declare module '@tiptap/core' {
|
|
423
432
|
interface Commands<ReturnType> {
|
|
424
|
-
|
|
425
|
-
|
|
433
|
+
exportWord: {
|
|
434
|
+
exportToWord: () => ReturnType;
|
|
426
435
|
};
|
|
427
436
|
}
|
|
428
437
|
}
|
|
@@ -430,9 +439,8 @@ declare module '@tiptap/core' {
|
|
|
430
439
|
|
|
431
440
|
declare module '@tiptap/core' {
|
|
432
441
|
interface Commands<ReturnType> {
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
removeTableOfContents: () => ReturnType;
|
|
442
|
+
excalidraw: {
|
|
443
|
+
setExcalidraw: (attrs?: IExcalidrawAttrs) => ReturnType;
|
|
436
444
|
};
|
|
437
445
|
}
|
|
438
446
|
}
|
|
@@ -440,8 +448,9 @@ declare module '@tiptap/core' {
|
|
|
440
448
|
|
|
441
449
|
declare module '@tiptap/core' {
|
|
442
450
|
interface Commands<ReturnType> {
|
|
443
|
-
|
|
444
|
-
|
|
451
|
+
tableOfContents: {
|
|
452
|
+
setTableOfContents: () => ReturnType;
|
|
453
|
+
removeTableOfContents: () => ReturnType;
|
|
445
454
|
};
|
|
446
455
|
}
|
|
447
456
|
}
|
|
@@ -449,8 +458,8 @@ declare module '@tiptap/core' {
|
|
|
449
458
|
|
|
450
459
|
declare module '@tiptap/core' {
|
|
451
460
|
interface Commands<ReturnType> {
|
|
452
|
-
|
|
453
|
-
|
|
461
|
+
attachment: {
|
|
462
|
+
setAttachment: (attrs?: unknown) => ReturnType;
|
|
454
463
|
};
|
|
455
464
|
}
|
|
456
465
|
}
|
|
@@ -476,15 +485,6 @@ declare module '@tiptap/core' {
|
|
|
476
485
|
}
|
|
477
486
|
|
|
478
487
|
|
|
479
|
-
declare module '@tiptap/core' {
|
|
480
|
-
interface Commands<ReturnType> {
|
|
481
|
-
attachment: {
|
|
482
|
-
setAttachment: (attrs?: unknown) => ReturnType;
|
|
483
|
-
};
|
|
484
|
-
}
|
|
485
|
-
}
|
|
486
|
-
|
|
487
|
-
|
|
488
488
|
declare module '@tiptap/core' {
|
|
489
489
|
interface Commands<ReturnType> {
|
|
490
490
|
mermaid: {
|
package/lib/index.d.ts
CHANGED
|
@@ -344,16 +344,6 @@ declare module '@tiptap/core' {
|
|
|
344
344
|
}
|
|
345
345
|
|
|
346
346
|
|
|
347
|
-
declare module '@tiptap/core' {
|
|
348
|
-
interface Commands<ReturnType> {
|
|
349
|
-
tableCellBackground: {
|
|
350
|
-
setTableCellBackground: (color: string) => ReturnType;
|
|
351
|
-
unsetTableCellBackground: () => ReturnType;
|
|
352
|
-
};
|
|
353
|
-
}
|
|
354
|
-
}
|
|
355
|
-
|
|
356
|
-
|
|
357
347
|
declare module '@tiptap/core' {
|
|
358
348
|
interface Commands<ReturnType> {
|
|
359
349
|
painter: {
|
|
@@ -392,6 +382,16 @@ declare module '@tiptap/core' {
|
|
|
392
382
|
}
|
|
393
383
|
|
|
394
384
|
|
|
385
|
+
declare module '@tiptap/core' {
|
|
386
|
+
interface Commands<ReturnType> {
|
|
387
|
+
tableCellBackground: {
|
|
388
|
+
setTableCellBackground: (color: string) => ReturnType;
|
|
389
|
+
unsetTableCellBackground: () => ReturnType;
|
|
390
|
+
};
|
|
391
|
+
}
|
|
392
|
+
}
|
|
393
|
+
|
|
394
|
+
|
|
395
395
|
declare module '@tiptap/core' {
|
|
396
396
|
interface Commands<ReturnType> {
|
|
397
397
|
search: {
|
|
@@ -407,6 +407,15 @@ declare module '@tiptap/core' {
|
|
|
407
407
|
}
|
|
408
408
|
|
|
409
409
|
|
|
410
|
+
declare module '@tiptap/core' {
|
|
411
|
+
interface Commands<ReturnType> {
|
|
412
|
+
katex: {
|
|
413
|
+
setKatex: (arg?: IKatexAttrs) => ReturnType;
|
|
414
|
+
};
|
|
415
|
+
}
|
|
416
|
+
}
|
|
417
|
+
|
|
418
|
+
|
|
410
419
|
declare module '@tiptap/core' {
|
|
411
420
|
interface Commands<ReturnType> {
|
|
412
421
|
emoji: {
|
|
@@ -421,8 +430,8 @@ declare module '@tiptap/core' {
|
|
|
421
430
|
|
|
422
431
|
declare module '@tiptap/core' {
|
|
423
432
|
interface Commands<ReturnType> {
|
|
424
|
-
|
|
425
|
-
|
|
433
|
+
exportWord: {
|
|
434
|
+
exportToWord: () => ReturnType;
|
|
426
435
|
};
|
|
427
436
|
}
|
|
428
437
|
}
|
|
@@ -430,9 +439,8 @@ declare module '@tiptap/core' {
|
|
|
430
439
|
|
|
431
440
|
declare module '@tiptap/core' {
|
|
432
441
|
interface Commands<ReturnType> {
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
removeTableOfContents: () => ReturnType;
|
|
442
|
+
excalidraw: {
|
|
443
|
+
setExcalidraw: (attrs?: IExcalidrawAttrs) => ReturnType;
|
|
436
444
|
};
|
|
437
445
|
}
|
|
438
446
|
}
|
|
@@ -440,8 +448,9 @@ declare module '@tiptap/core' {
|
|
|
440
448
|
|
|
441
449
|
declare module '@tiptap/core' {
|
|
442
450
|
interface Commands<ReturnType> {
|
|
443
|
-
|
|
444
|
-
|
|
451
|
+
tableOfContents: {
|
|
452
|
+
setTableOfContents: () => ReturnType;
|
|
453
|
+
removeTableOfContents: () => ReturnType;
|
|
445
454
|
};
|
|
446
455
|
}
|
|
447
456
|
}
|
|
@@ -449,8 +458,8 @@ declare module '@tiptap/core' {
|
|
|
449
458
|
|
|
450
459
|
declare module '@tiptap/core' {
|
|
451
460
|
interface Commands<ReturnType> {
|
|
452
|
-
|
|
453
|
-
|
|
461
|
+
attachment: {
|
|
462
|
+
setAttachment: (attrs?: unknown) => ReturnType;
|
|
454
463
|
};
|
|
455
464
|
}
|
|
456
465
|
}
|
|
@@ -476,15 +485,6 @@ declare module '@tiptap/core' {
|
|
|
476
485
|
}
|
|
477
486
|
|
|
478
487
|
|
|
479
|
-
declare module '@tiptap/core' {
|
|
480
|
-
interface Commands<ReturnType> {
|
|
481
|
-
attachment: {
|
|
482
|
-
setAttachment: (attrs?: unknown) => ReturnType;
|
|
483
|
-
};
|
|
484
|
-
}
|
|
485
|
-
}
|
|
486
|
-
|
|
487
|
-
|
|
488
488
|
declare module '@tiptap/core' {
|
|
489
489
|
interface Commands<ReturnType> {
|
|
490
490
|
mermaid: {
|
package/lib/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { useRef as d, useState as o, useEffect as f } from "react";
|
|
2
|
-
import { R as m } from "./RichTextEditor-
|
|
3
|
-
import { B as x } from "./tiptap-
|
|
2
|
+
import { R as m } from "./RichTextEditor-DH6J2is9.js";
|
|
3
|
+
import { B as x } from "./tiptap-DOP8lVCQ.js";
|
|
4
4
|
function c() {
|
|
5
5
|
var t;
|
|
6
6
|
const e = d({ editor: null }), [u, s] = o(!1), [i, n] = o(null);
|
package/lib/locale-bundle.d.cts
CHANGED
|
@@ -973,16 +973,6 @@ declare module '@tiptap/core' {
|
|
|
973
973
|
}
|
|
974
974
|
|
|
975
975
|
|
|
976
|
-
declare module '@tiptap/core' {
|
|
977
|
-
interface Commands<ReturnType> {
|
|
978
|
-
tableCellBackground: {
|
|
979
|
-
setTableCellBackground: (color: string) => ReturnType;
|
|
980
|
-
unsetTableCellBackground: () => ReturnType;
|
|
981
|
-
};
|
|
982
|
-
}
|
|
983
|
-
}
|
|
984
|
-
|
|
985
|
-
|
|
986
976
|
declare module '@tiptap/core' {
|
|
987
977
|
interface Commands<ReturnType> {
|
|
988
978
|
painter: {
|
|
@@ -1021,6 +1011,16 @@ declare module '@tiptap/core' {
|
|
|
1021
1011
|
}
|
|
1022
1012
|
|
|
1023
1013
|
|
|
1014
|
+
declare module '@tiptap/core' {
|
|
1015
|
+
interface Commands<ReturnType> {
|
|
1016
|
+
tableCellBackground: {
|
|
1017
|
+
setTableCellBackground: (color: string) => ReturnType;
|
|
1018
|
+
unsetTableCellBackground: () => ReturnType;
|
|
1019
|
+
};
|
|
1020
|
+
}
|
|
1021
|
+
}
|
|
1022
|
+
|
|
1023
|
+
|
|
1024
1024
|
declare module '@tiptap/core' {
|
|
1025
1025
|
interface Commands<ReturnType> {
|
|
1026
1026
|
search: {
|
|
@@ -1036,6 +1036,15 @@ declare module '@tiptap/core' {
|
|
|
1036
1036
|
}
|
|
1037
1037
|
|
|
1038
1038
|
|
|
1039
|
+
declare module '@tiptap/core' {
|
|
1040
|
+
interface Commands<ReturnType> {
|
|
1041
|
+
katex: {
|
|
1042
|
+
setKatex: (arg?: IKatexAttrs) => ReturnType;
|
|
1043
|
+
};
|
|
1044
|
+
}
|
|
1045
|
+
}
|
|
1046
|
+
|
|
1047
|
+
|
|
1039
1048
|
declare module '@tiptap/core' {
|
|
1040
1049
|
interface Commands<ReturnType> {
|
|
1041
1050
|
emoji: {
|
|
@@ -1050,8 +1059,8 @@ declare module '@tiptap/core' {
|
|
|
1050
1059
|
|
|
1051
1060
|
declare module '@tiptap/core' {
|
|
1052
1061
|
interface Commands<ReturnType> {
|
|
1053
|
-
|
|
1054
|
-
|
|
1062
|
+
exportWord: {
|
|
1063
|
+
exportToWord: () => ReturnType;
|
|
1055
1064
|
};
|
|
1056
1065
|
}
|
|
1057
1066
|
}
|
|
@@ -1059,9 +1068,8 @@ declare module '@tiptap/core' {
|
|
|
1059
1068
|
|
|
1060
1069
|
declare module '@tiptap/core' {
|
|
1061
1070
|
interface Commands<ReturnType> {
|
|
1062
|
-
|
|
1063
|
-
|
|
1064
|
-
removeTableOfContents: () => ReturnType;
|
|
1071
|
+
excalidraw: {
|
|
1072
|
+
setExcalidraw: (attrs?: IExcalidrawAttrs) => ReturnType;
|
|
1065
1073
|
};
|
|
1066
1074
|
}
|
|
1067
1075
|
}
|
|
@@ -1069,8 +1077,9 @@ declare module '@tiptap/core' {
|
|
|
1069
1077
|
|
|
1070
1078
|
declare module '@tiptap/core' {
|
|
1071
1079
|
interface Commands<ReturnType> {
|
|
1072
|
-
|
|
1073
|
-
|
|
1080
|
+
tableOfContents: {
|
|
1081
|
+
setTableOfContents: () => ReturnType;
|
|
1082
|
+
removeTableOfContents: () => ReturnType;
|
|
1074
1083
|
};
|
|
1075
1084
|
}
|
|
1076
1085
|
}
|
|
@@ -1078,8 +1087,8 @@ declare module '@tiptap/core' {
|
|
|
1078
1087
|
|
|
1079
1088
|
declare module '@tiptap/core' {
|
|
1080
1089
|
interface Commands<ReturnType> {
|
|
1081
|
-
|
|
1082
|
-
|
|
1090
|
+
attachment: {
|
|
1091
|
+
setAttachment: (attrs?: unknown) => ReturnType;
|
|
1083
1092
|
};
|
|
1084
1093
|
}
|
|
1085
1094
|
}
|
|
@@ -1105,15 +1114,6 @@ declare module '@tiptap/core' {
|
|
|
1105
1114
|
}
|
|
1106
1115
|
|
|
1107
1116
|
|
|
1108
|
-
declare module '@tiptap/core' {
|
|
1109
|
-
interface Commands<ReturnType> {
|
|
1110
|
-
attachment: {
|
|
1111
|
-
setAttachment: (attrs?: unknown) => ReturnType;
|
|
1112
|
-
};
|
|
1113
|
-
}
|
|
1114
|
-
}
|
|
1115
|
-
|
|
1116
|
-
|
|
1117
1117
|
declare module '@tiptap/core' {
|
|
1118
1118
|
interface Commands<ReturnType> {
|
|
1119
1119
|
mermaid: {
|
package/lib/locale-bundle.d.ts
CHANGED
|
@@ -973,16 +973,6 @@ declare module '@tiptap/core' {
|
|
|
973
973
|
}
|
|
974
974
|
|
|
975
975
|
|
|
976
|
-
declare module '@tiptap/core' {
|
|
977
|
-
interface Commands<ReturnType> {
|
|
978
|
-
tableCellBackground: {
|
|
979
|
-
setTableCellBackground: (color: string) => ReturnType;
|
|
980
|
-
unsetTableCellBackground: () => ReturnType;
|
|
981
|
-
};
|
|
982
|
-
}
|
|
983
|
-
}
|
|
984
|
-
|
|
985
|
-
|
|
986
976
|
declare module '@tiptap/core' {
|
|
987
977
|
interface Commands<ReturnType> {
|
|
988
978
|
painter: {
|
|
@@ -1021,6 +1011,16 @@ declare module '@tiptap/core' {
|
|
|
1021
1011
|
}
|
|
1022
1012
|
|
|
1023
1013
|
|
|
1014
|
+
declare module '@tiptap/core' {
|
|
1015
|
+
interface Commands<ReturnType> {
|
|
1016
|
+
tableCellBackground: {
|
|
1017
|
+
setTableCellBackground: (color: string) => ReturnType;
|
|
1018
|
+
unsetTableCellBackground: () => ReturnType;
|
|
1019
|
+
};
|
|
1020
|
+
}
|
|
1021
|
+
}
|
|
1022
|
+
|
|
1023
|
+
|
|
1024
1024
|
declare module '@tiptap/core' {
|
|
1025
1025
|
interface Commands<ReturnType> {
|
|
1026
1026
|
search: {
|
|
@@ -1036,6 +1036,15 @@ declare module '@tiptap/core' {
|
|
|
1036
1036
|
}
|
|
1037
1037
|
|
|
1038
1038
|
|
|
1039
|
+
declare module '@tiptap/core' {
|
|
1040
|
+
interface Commands<ReturnType> {
|
|
1041
|
+
katex: {
|
|
1042
|
+
setKatex: (arg?: IKatexAttrs) => ReturnType;
|
|
1043
|
+
};
|
|
1044
|
+
}
|
|
1045
|
+
}
|
|
1046
|
+
|
|
1047
|
+
|
|
1039
1048
|
declare module '@tiptap/core' {
|
|
1040
1049
|
interface Commands<ReturnType> {
|
|
1041
1050
|
emoji: {
|
|
@@ -1050,8 +1059,8 @@ declare module '@tiptap/core' {
|
|
|
1050
1059
|
|
|
1051
1060
|
declare module '@tiptap/core' {
|
|
1052
1061
|
interface Commands<ReturnType> {
|
|
1053
|
-
|
|
1054
|
-
|
|
1062
|
+
exportWord: {
|
|
1063
|
+
exportToWord: () => ReturnType;
|
|
1055
1064
|
};
|
|
1056
1065
|
}
|
|
1057
1066
|
}
|
|
@@ -1059,9 +1068,8 @@ declare module '@tiptap/core' {
|
|
|
1059
1068
|
|
|
1060
1069
|
declare module '@tiptap/core' {
|
|
1061
1070
|
interface Commands<ReturnType> {
|
|
1062
|
-
|
|
1063
|
-
|
|
1064
|
-
removeTableOfContents: () => ReturnType;
|
|
1071
|
+
excalidraw: {
|
|
1072
|
+
setExcalidraw: (attrs?: IExcalidrawAttrs) => ReturnType;
|
|
1065
1073
|
};
|
|
1066
1074
|
}
|
|
1067
1075
|
}
|
|
@@ -1069,8 +1077,9 @@ declare module '@tiptap/core' {
|
|
|
1069
1077
|
|
|
1070
1078
|
declare module '@tiptap/core' {
|
|
1071
1079
|
interface Commands<ReturnType> {
|
|
1072
|
-
|
|
1073
|
-
|
|
1080
|
+
tableOfContents: {
|
|
1081
|
+
setTableOfContents: () => ReturnType;
|
|
1082
|
+
removeTableOfContents: () => ReturnType;
|
|
1074
1083
|
};
|
|
1075
1084
|
}
|
|
1076
1085
|
}
|
|
@@ -1078,8 +1087,8 @@ declare module '@tiptap/core' {
|
|
|
1078
1087
|
|
|
1079
1088
|
declare module '@tiptap/core' {
|
|
1080
1089
|
interface Commands<ReturnType> {
|
|
1081
|
-
|
|
1082
|
-
|
|
1090
|
+
attachment: {
|
|
1091
|
+
setAttachment: (attrs?: unknown) => ReturnType;
|
|
1083
1092
|
};
|
|
1084
1093
|
}
|
|
1085
1094
|
}
|
|
@@ -1105,15 +1114,6 @@ declare module '@tiptap/core' {
|
|
|
1105
1114
|
}
|
|
1106
1115
|
|
|
1107
1116
|
|
|
1108
|
-
declare module '@tiptap/core' {
|
|
1109
|
-
interface Commands<ReturnType> {
|
|
1110
|
-
attachment: {
|
|
1111
|
-
setAttachment: (attrs?: unknown) => ReturnType;
|
|
1112
|
-
};
|
|
1113
|
-
}
|
|
1114
|
-
}
|
|
1115
|
-
|
|
1116
|
-
|
|
1117
1117
|
declare module '@tiptap/core' {
|
|
1118
1118
|
interface Commands<ReturnType> {
|
|
1119
1119
|
mermaid: {
|
package/lib/locale-bundle.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import Je from "tippy.js";
|
|
2
|
-
import { E as Ye, a as Xe, P as H, b as I, S as Z, k as Qe, T as D, D as Ze, c as we, F as V, N as tn, d as xt, w as en, e as nn, f as rn, g as dt, h as tt, s as sn, i as Zt, j as on, l as an, m as ln, n as cn, o as dn, A as un, p as pn, q as hn, r as fn, t as mn, u as gn, v as yn, x as vn, y as Ee, z as bn, B as Mn, C as Sn, G as kn, H as wn, I as En, J as Tn, K as Ft, R as Cn, L as xn, M as An, O as On, Q as te, U as Ln, V as Te, W as _n, X as Pn, Y as Rn, Z as Hn, _ as $n, $ as pt, a0 as zt, a1 as In, a2 as Dn, a3 as Nn, a4 as Ce, a5 as Bn, a6 as ee, a7 as jn, a8 as ne, a9 as re, aa as Fn, ab as se, ac as zn, ad as Vn, ae as Wn, af as Kn, ag as Un, ah as qn, ai as Gn } from "./vendor-
|
|
2
|
+
import { E as Ye, a as Xe, P as H, b as I, S as Z, k as Qe, T as D, D as Ze, c as we, F as V, N as tn, d as xt, w as en, e as nn, f as rn, g as dt, h as tt, s as sn, i as Zt, j as on, l as an, m as ln, n as cn, o as dn, A as un, p as pn, q as hn, r as fn, t as mn, u as gn, v as yn, x as vn, y as Ee, z as bn, B as Mn, C as Sn, G as kn, H as wn, I as En, J as Tn, K as Ft, R as Cn, L as xn, M as An, O as On, Q as te, U as Ln, V as Te, W as _n, X as Pn, Y as Rn, Z as Hn, _ as $n, $ as pt, a0 as zt, a1 as In, a2 as Dn, a3 as Nn, a4 as Ce, a5 as Bn, a6 as ee, a7 as jn, a8 as ne, a9 as re, aa as Fn, ab as se, ac as zn, ad as Vn, ae as Wn, af as Kn, ag as Un, ah as qn, ai as Gn } from "./vendor-BbgkyoD-.js";
|
|
3
3
|
import L, { useRef as Jn, useState as Vt, useDebugValue as xe, useEffect as Wt, forwardRef as Yn, useLayoutEffect as Xn, useContext as Ae, createContext as Oe } from "react";
|
|
4
4
|
import Qn, { flushSync as Zn } from "react-dom";
|
|
5
5
|
function gt(e) {
|
|
@@ -12683,12 +12683,10 @@ var Ca = {}, hn = Symbol(), Qr = Symbol(), tg = (t) => typeof t == "string" ? Te
|
|
|
12683
12683
|
}, ng = (t, e) => (e[Qr] || Qc)(t, e), Qc = (t, e) => {
|
|
12684
12684
|
for (var n = [t], r, i = [], o = 0; r = tg(e[hn]); )
|
|
12685
12685
|
delete e[hn], Object.assign(e, r);
|
|
12686
|
-
for (C_(t, e, n, 0); i[o++] = n[0], n = n[1]; )
|
|
12687
|
-
;
|
|
12686
|
+
for (C_(t, e, n, 0); i[o++] = n[0], n = n[1]; ) ;
|
|
12688
12687
|
return i;
|
|
12689
12688
|
}, r1 = "</span>", Ua = "", fo = "", S_ = (t) => {
|
|
12690
|
-
for (var e = "", n = t.length, r = 0; r < n; )
|
|
12691
|
-
e += A_(t[r++]);
|
|
12689
|
+
for (var e = "", n = t.length, r = 0; r < n; ) e += A_(t[r++]);
|
|
12692
12690
|
return e;
|
|
12693
12691
|
}, A_ = (t) => {
|
|
12694
12692
|
if (t instanceof Ri) {
|
|
@@ -12702,34 +12700,30 @@ var Ca = {}, hn = Symbol(), Qr = Symbol(), tg = (t) => typeof t == "string" ? Te
|
|
|
12702
12700
|
` + Ua) : t);
|
|
12703
12701
|
}, C_ = (t, e, n, r, i) => {
|
|
12704
12702
|
for (var o in e)
|
|
12705
|
-
if (e[o])
|
|
12706
|
-
|
|
12707
|
-
|
|
12708
|
-
|
|
12709
|
-
|
|
12710
|
-
|
|
12711
|
-
if (
|
|
12712
|
-
if (
|
|
12713
|
-
|
|
12714
|
-
|
|
12715
|
-
|
|
12716
|
-
|
|
12717
|
-
|
|
12718
|
-
|
|
12719
|
-
|
|
12720
|
-
for (var S = g, s = p; (s += S[0].length) < _; S = S[1], b++)
|
|
12721
|
-
;
|
|
12722
|
-
y = t.slice(p, s), v.index -= p;
|
|
12723
|
-
}
|
|
12724
|
-
}
|
|
12725
|
-
if (v && v[0]) {
|
|
12726
|
-
for (var C = v.index, A = v[0], O = y.slice(C + A.length), P = p + y.length, E = new Ri(o, d ? ng(A, d) : A, A, m), k = g, x = 0, z; k = k[1], x++ < b; )
|
|
12727
|
-
;
|
|
12728
|
-
O && (!k || k[0] instanceof Ri ? k = [O, k] : k[0] = O + k[0]), p += C, g[0] = C ? y.slice(0, C) : E, C ? g = g[1] = [E, k] : g[1] = k, b && (C_(t, e, g, p, z = [o, a, P]), P = z[2]), i && P > i[2] && (i[2] = P);
|
|
12703
|
+
if (e[o]) for (var a = 0, s = e[o], c = Array.isArray(s) ? s : [s]; a < c.length; ++a) {
|
|
12704
|
+
if (i && i[0] == o && i[1] == a)
|
|
12705
|
+
return;
|
|
12706
|
+
for (var l = c[a], u = l.pattern || l, d = tg(l.inside), f = l.lookbehind, h = l.greedy && u.global, m = l.alias, g = n, p = r; g && (!i || p < i[2]); p += g[0].length, g = g[1]) {
|
|
12707
|
+
var y = g[0], b = 0, v, D;
|
|
12708
|
+
if (!(y instanceof Ri)) {
|
|
12709
|
+
if (u.lastIndex = h ? p : 0, v = u.exec(h ? t : y), v && f && v[1] && (D = v[1].length, v.index += D, v[0] = v[0].slice(D)), h) {
|
|
12710
|
+
if (!v)
|
|
12711
|
+
break;
|
|
12712
|
+
if (v[0]) {
|
|
12713
|
+
for (var C = v.index, _ = C + v[0].length, T; C >= p + (T = g[0].length); g = g[1], p += T) ;
|
|
12714
|
+
if (g[0] instanceof Ri)
|
|
12715
|
+
continue;
|
|
12716
|
+
for (var S = g, s = p; (s += S[0].length) < _; S = S[1], b++) ;
|
|
12717
|
+
y = t.slice(p, s), v.index -= p;
|
|
12729
12718
|
}
|
|
12730
12719
|
}
|
|
12720
|
+
if (v && v[0]) {
|
|
12721
|
+
for (var C = v.index, A = v[0], O = y.slice(C + A.length), P = p + y.length, E = new Ri(o, d ? ng(A, d) : A, A, m), k = g, x = 0, z; k = k[1], x++ < b; ) ;
|
|
12722
|
+
O && (!k || k[0] instanceof Ri ? k = [O, k] : k[0] = O + k[0]), p += C, g[0] = C ? y.slice(0, C) : E, C ? g = g[1] = [E, k] : g[1] = k, b && (C_(t, e, g, p, z = [o, a, P]), P = z[2]), i && P > i[2] && (i[2] = P);
|
|
12723
|
+
}
|
|
12731
12724
|
}
|
|
12732
12725
|
}
|
|
12726
|
+
}
|
|
12733
12727
|
};
|
|
12734
12728
|
function Ri(t, e, n, r) {
|
|
12735
12729
|
this.type = t, this.content = e, this.alias = r, this.length = n.length;
|
|
@@ -12999,8 +12993,7 @@ i1[hn] = Te.css = {
|
|
|
12999
12993
|
punctuation: /[(){},:;]/
|
|
13000
12994
|
};
|
|
13001
12995
|
var fs = (t, e) => {
|
|
13002
|
-
if (e.has(t))
|
|
13003
|
-
return e.get(t);
|
|
12996
|
+
if (e.has(t)) return e.get(t);
|
|
13004
12997
|
var n = t, r = rO.call(t).slice(8, -1);
|
|
13005
12998
|
if (r == "Object") {
|
|
13006
12999
|
e.set(t, n = {});
|
|
@@ -14983,8 +14976,7 @@ Te.graphql = {
|
|
|
14983
14976
|
if (!a(["definition-mutation", "punctuation"]) && r[o + 1].content == "(") {
|
|
14984
14977
|
o += 2;
|
|
14985
14978
|
var u = s("(", ")");
|
|
14986
|
-
if (!u)
|
|
14987
|
-
continue;
|
|
14979
|
+
if (!u) continue;
|
|
14988
14980
|
for (; o < u; o++) {
|
|
14989
14981
|
var d = r[o];
|
|
14990
14982
|
d.type == "variable" && (d.alias = "variable-input", l.push(d.content));
|
|
@@ -14993,11 +14985,10 @@ Te.graphql = {
|
|
|
14993
14985
|
}
|
|
14994
14986
|
if (!a(["punctuation", "property-query"]) && r[o].content == "{" && (r[++o].alias = "property-mutation", l[0])) {
|
|
14995
14987
|
var f = s("{", "}");
|
|
14996
|
-
if (f)
|
|
14997
|
-
|
|
14998
|
-
|
|
14999
|
-
|
|
15000
|
-
}
|
|
14988
|
+
if (f) for (var h = o; h < f; h++) {
|
|
14989
|
+
var m = r[h];
|
|
14990
|
+
m.type == "variable" && l.indexOf(m.content) >= 0 && (m.alias = "variable-input");
|
|
14991
|
+
}
|
|
15001
14992
|
}
|
|
15002
14993
|
}
|
|
15003
14994
|
}
|
|
@@ -15328,29 +15319,22 @@ const tM = (t, e, ...n) => {
|
|
|
15328
15319
|
var G;
|
|
15329
15320
|
let r, i, o = [], a, s = "", c, l = !1, u = !1, d = !0, f = [], h, m = 0;
|
|
15330
15321
|
const g = wO(), p = g.firstChild, y = p.children, b = y[0], v = b.firstChild, D = { language: "text", value: s }, _ = new Set(n), T = {}, S = (B) => {
|
|
15331
|
-
if (Object.assign(D, B), s = B.value ?? s, r = D.language, !Te[r])
|
|
15332
|
-
throw Error(`Language '${r}' has no grammar.`);
|
|
15322
|
+
if (Object.assign(D, B), s = B.value ?? s, r = D.language, !Te[r]) throw Error(`Language '${r}' has no grammar.`);
|
|
15333
15323
|
h = !!D.readOnly, g.style.tabSize = D.tabSize || 2, v.inputMode = h ? "none" : "", v.setAttribute("aria-readonly", h), O(), A(), (i != (i = Te[r]) || s != v.value) && (x(), v.value = s, v.selectionEnd = 0, C());
|
|
15334
15324
|
}, C = () => {
|
|
15335
15325
|
f = ng(s = v.value, i), z("tokenize", f, r, s);
|
|
15336
15326
|
let B = S_(f).split(`
|
|
15337
15327
|
`), V = 0, L = m, I = m = B.length;
|
|
15338
|
-
for (; B[V] == o[V] && V < I; )
|
|
15339
|
-
|
|
15340
|
-
|
|
15341
|
-
;
|
|
15342
|
-
if (V == I && V == L)
|
|
15343
|
-
y[V + 1].innerHTML = B[V] + `
|
|
15328
|
+
for (; B[V] == o[V] && V < I; ) ++V;
|
|
15329
|
+
for (; I && B[--I] == o[--L]; ) ;
|
|
15330
|
+
if (V == I && V == L) y[V + 1].innerHTML = B[V] + `
|
|
15344
15331
|
`;
|
|
15345
15332
|
else {
|
|
15346
15333
|
let ne = L < V ? L : V - 1, H = ne, Z = "";
|
|
15347
|
-
for (; H < I; )
|
|
15348
|
-
Z += `<div class=pce-line aria-hidden=true>${B[++H]}
|
|
15334
|
+
for (; H < I; ) Z += `<div class=pce-line aria-hidden=true>${B[++H]}
|
|
15349
15335
|
</div>`;
|
|
15350
|
-
for (H = I < V ? I : V - 1; H < L; H++)
|
|
15351
|
-
|
|
15352
|
-
for (Z && y[ne + 1].insertAdjacentHTML("afterend", Z), H = ne + 1; H < m; )
|
|
15353
|
-
y[++H].setAttribute("data-line", H);
|
|
15336
|
+
for (H = I < V ? I : V - 1; H < L; H++) y[V + 1].remove();
|
|
15337
|
+
for (Z && y[ne + 1].insertAdjacentHTML("afterend", Z), H = ne + 1; H < m; ) y[++H].setAttribute("data-line", H);
|
|
15354
15338
|
g.style.setProperty(
|
|
15355
15339
|
"--number-width",
|
|
15356
15340
|
Math.ceil(Math.log10(m + 1)) + ".001ch"
|
|
@@ -15454,8 +15438,7 @@ const tM = (t, e, ...n) => {
|
|
|
15454
15438
|
}, Et = (t, e, n, r) => t.textarea.addEventListener(e, n, r), _O = (t) => typeof t == "string" ? document.querySelector(t) : t, Z_ = navigator.userAgent, sc = /Mac|iPhone|iPod|iPad/i.test(navigator.platform), cc = /Chrome\//.test(Z_), ms = !cc && /AppleWebKit\//.test(Z_), J_ = (t, e = 0, n = 1 / 0) => {
|
|
15455
15439
|
let r = 1;
|
|
15456
15440
|
for (; (e = t.indexOf(`
|
|
15457
|
-
`, e) + 1) && e <= n; r++)
|
|
15458
|
-
;
|
|
15441
|
+
`, e) + 1) && e <= n; r++) ;
|
|
15459
15442
|
return r;
|
|
15460
15443
|
}, lu = {}, wO = /* @__PURE__ */ nl(
|
|
15461
15444
|
"<div><div class=pce-wrapper><div class=pce-overlays><textarea spellcheck=false autocapitalize=off autocomplete=off>"
|
|
@@ -15483,8 +15466,7 @@ const po = (t) => t.replace(/[$+?|.^*()[\]{}\\]/g, "\\$&"), np = (t, e) => t.sli
|
|
|
15483
15466
|
for (; -l <= r && (c = s.previousNode()); )
|
|
15484
15467
|
if (!c.lastChild && (l -= c.length || 0, l <= n)) {
|
|
15485
15468
|
for (; c != a; c = c.parentNode)
|
|
15486
|
-
if ((u = c.matches) != null && u.call(c, e))
|
|
15487
|
-
return c;
|
|
15469
|
+
if ((u = c.matches) != null && u.call(c, e)) return c;
|
|
15488
15470
|
}
|
|
15489
15471
|
}, uu = (t, e) => {
|
|
15490
15472
|
var n;
|
|
@@ -15492,8 +15474,7 @@ const po = (t) => t.replace(/[$+?|.^*()[\]{}\\]/g, "\\$&"), np = (t, e) => t.sli
|
|
|
15492
15474
|
/language-(\S*)/
|
|
15493
15475
|
)[1]) || t.options.language;
|
|
15494
15476
|
}, Rt = (t, e, n, r, i, o) => {
|
|
15495
|
-
if (t.options.readOnly)
|
|
15496
|
-
return;
|
|
15477
|
+
if (t.options.readOnly) return;
|
|
15497
15478
|
Ii = t.getSelection(), r ?? (r = n);
|
|
15498
15479
|
let a = t.textarea, s = t.value, c = cc && !s[r ?? Ii[1]] && /\n$/.test(e) && /^$|\n$/.test(s), l;
|
|
15499
15480
|
t.focused || a.focus(), n != null && a.setSelectionRange(n, r), i != null && (l = TO(t, "update", () => {
|
|
@@ -15550,8 +15531,7 @@ const O1 = navigator.clipboard, Gr = sc ? 4 : 2, AO = (t) => rp = t, Lr = (t) =>
|
|
|
15550
15531
|
const b = (D = (v = lu[uu(n)]) == null ? void 0 : v.autoCloseTags) == null ? void 0 : D.call(v, p, y, n);
|
|
15551
15532
|
b && (Rt(n, ">" + b, null, null, p[0] + 1), wt(g));
|
|
15552
15533
|
}, o.Tab = (g, [p, y], b) => {
|
|
15553
|
-
if (rp || r.readOnly || Fo(g) & 6)
|
|
15554
|
-
return;
|
|
15534
|
+
if (rp || r.readOnly || Fo(g) & 6) return;
|
|
15555
15535
|
const [v, D] = l(r), _ = g.shiftKey, [T, S, C] = nr(b, p, y);
|
|
15556
15536
|
return p < y || _ ? m(_, T, S, C, p, y, v, D) : Rt(n, v.repeat(D - (p - S) % D)), u();
|
|
15557
15537
|
}, o.Enter = (g, p, y) => {
|
|
@@ -15720,8 +15700,7 @@ const O1 = navigator.clipboard, Gr = sc ? 4 : 2, AO = (t) => rp = t, Lr = (t) =>
|
|
|
15720
15700
|
n[O + D] = p;
|
|
15721
15701
|
y = a[p] = m[p];
|
|
15722
15702
|
}
|
|
15723
|
-
for (let p = e; p > g; )
|
|
15724
|
-
o[--p].remove();
|
|
15703
|
+
for (let p = e; p > g; ) o[--p].remove();
|
|
15725
15704
|
s.append(...o.slice(e, e = g));
|
|
15726
15705
|
}, u = () => {
|
|
15727
15706
|
const h = n[i.activeLineNumber - 1] ?? -1;
|
|
@@ -15743,14 +15722,12 @@ const O1 = navigator.clipboard, Gr = sc ? 4 : 2, AO = (t) => rp = t, Lr = (t) =>
|
|
|
15743
15722
|
];
|
|
15744
15723
|
b = -1, y = T;
|
|
15745
15724
|
}
|
|
15746
|
-
if (_)
|
|
15747
|
-
break;
|
|
15725
|
+
if (_) break;
|
|
15748
15726
|
}
|
|
15749
15727
|
return c.length = m, p;
|
|
15750
15728
|
}, f = (h) => {
|
|
15751
15729
|
let m = h.search(/\S/), g = 0;
|
|
15752
|
-
if (m < 0)
|
|
15753
|
-
return m;
|
|
15730
|
+
if (m < 0) return m;
|
|
15754
15731
|
for (let p = 0; p < m; )
|
|
15755
15732
|
g += h[p++] == " " ? t - g % t : 1;
|
|
15756
15733
|
return Math.ceil(g / t);
|
|
@@ -15772,8 +15749,7 @@ const O1 = navigator.clipboard, Gr = sc ? 4 : 2, AO = (t) => rp = t, Lr = (t) =>
|
|
|
15772
15749
|
o = [f, h].map(
|
|
15773
15750
|
(m) => uc(t, ".punctuation", 0, -1, m[1])
|
|
15774
15751
|
), o[0] != o[1] && f[1] + f[3].length == h[1] && (o[0].textContent += o[1].textContent, o[1].textContent = "", o[1] = o[0]), c(!0);
|
|
15775
|
-
} else
|
|
15776
|
-
o = [];
|
|
15752
|
+
} else o = [];
|
|
15777
15753
|
i = d;
|
|
15778
15754
|
}
|
|
15779
15755
|
}, s = (l) => {
|
|
@@ -15807,8 +15783,7 @@ const O1 = navigator.clipboard, Gr = sc ? 4 : 2, AO = (t) => rp = t, Lr = (t) =>
|
|
|
15807
15783
|
else if ((h.alias || h.type) == "punctuation") {
|
|
15808
15784
|
let y = R1(p, e, g - 1), b = y || R1(p, n, g - 1);
|
|
15809
15785
|
if (b) {
|
|
15810
|
-
if (s[r] = [h, f, 0, p, !!y, f + g], y)
|
|
15811
|
-
o[i++] = [r, y];
|
|
15786
|
+
if (s[r] = [h, f, 0, p, !!y, f + g], y) o[i++] = [r, y];
|
|
15812
15787
|
else
|
|
15813
15788
|
for (let v = i; v; ) {
|
|
15814
15789
|
let [D, _] = o[--v];
|
|
@@ -15862,9 +15837,7 @@ const O1 = navigator.clipboard, Gr = sc ? 4 : 2, AO = (t) => rp = t, Lr = (t) =>
|
|
|
15862
15837
|
pairs: e
|
|
15863
15838
|
};
|
|
15864
15839
|
}, IO = (t, e) => {
|
|
15865
|
-
for (let n = 0, r = e.length; n < r; n++)
|
|
15866
|
-
if (e[n][1] <= t && e[n][2] >= t)
|
|
15867
|
-
return n;
|
|
15840
|
+
for (let n = 0, r = e.length; n < r; n++) if (e[n][1] <= t && e[n][2] >= t) return n;
|
|
15868
15841
|
}, cM = () => (t) => {
|
|
15869
15842
|
var e;
|
|
15870
15843
|
let n, r;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "reactjs-tiptap-editor",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.2.
|
|
4
|
+
"version": "0.2.26",
|
|
5
5
|
"packageManager": "pnpm@8.15.9",
|
|
6
6
|
"description": "A modern WYSIWYG rich text editor based on tiptap and shadcn ui for React",
|
|
7
7
|
"license": "MIT",
|
|
@@ -181,7 +181,7 @@
|
|
|
181
181
|
"lodash-es": "^4.17.21",
|
|
182
182
|
"lucide-react": "^0.427.0",
|
|
183
183
|
"mermaid": "^11.6.0",
|
|
184
|
-
"prism-code-editor": "^
|
|
184
|
+
"prism-code-editor-lightweight": "^0.0.2",
|
|
185
185
|
"prosemirror-docx": "^0.2.1",
|
|
186
186
|
"re-resizable": "^6.11.2",
|
|
187
187
|
"react-colorful": "^5.6.1",
|