reactjs-tiptap-editor 0.2.29 → 0.3.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 (255) hide show
  1. package/lib/ActionMenuButton-Bycn676n.js +33 -0
  2. package/lib/ActionMenuButton-CpFNwSUZ.cjs +1 -0
  3. package/lib/Attachment.cjs +19 -0
  4. package/lib/Attachment.d.cts +344 -0
  5. package/lib/Attachment.d.ts +344 -0
  6. package/lib/Attachment.js +259 -0
  7. package/lib/Blockquote.cjs +1 -0
  8. package/lib/Blockquote.d.cts +343 -0
  9. package/lib/Blockquote.d.ts +343 -0
  10. package/lib/Blockquote.js +65 -0
  11. package/lib/Bold.cjs +1 -0
  12. package/lib/Bold.d.cts +343 -0
  13. package/lib/Bold.d.ts +343 -0
  14. package/lib/Bold.js +90 -0
  15. package/lib/BulletList.cjs +1 -0
  16. package/lib/BulletList.d.cts +343 -0
  17. package/lib/BulletList.d.ts +343 -0
  18. package/lib/BulletList.js +72 -0
  19. package/lib/Clear.cjs +1 -0
  20. package/lib/Clear.d.cts +342 -0
  21. package/lib/Clear.d.ts +342 -0
  22. package/lib/Clear.js +23 -0
  23. package/lib/Code.cjs +1 -0
  24. package/lib/Code.d.cts +343 -0
  25. package/lib/Code.d.ts +343 -0
  26. package/lib/Code.js +70 -0
  27. package/lib/CodeBlock.cjs +39 -0
  28. package/lib/CodeBlock.d.cts +352 -0
  29. package/lib/CodeBlock.d.ts +352 -0
  30. package/lib/CodeBlock.js +3639 -0
  31. package/lib/Color.cjs +1 -0
  32. package/lib/Color.d.cts +350 -0
  33. package/lib/Color.d.ts +350 -0
  34. package/lib/Color.js +141 -0
  35. package/lib/Document.cjs +1 -0
  36. package/lib/Document.d.cts +272 -0
  37. package/lib/Document.d.ts +272 -0
  38. package/lib/Document.js +13 -0
  39. package/lib/Drawer-BZadE1gM.js +1367 -0
  40. package/lib/Drawer-rwnFvgZR.cjs +1 -0
  41. package/lib/Drawer.cjs +1 -0
  42. package/lib/Drawer.d.cts +344 -0
  43. package/lib/Drawer.d.ts +344 -0
  44. package/lib/Drawer.js +7 -0
  45. package/lib/Emoji.cjs +1 -0
  46. package/lib/Emoji.d.cts +277 -0
  47. package/lib/Emoji.d.ts +277 -0
  48. package/lib/Emoji.js +2168 -0
  49. package/lib/Excalidraw-B2414Smc.js +651 -0
  50. package/lib/Excalidraw-D21vMFe0.cjs +1 -0
  51. package/lib/Excalidraw.cjs +1 -0
  52. package/lib/Excalidraw.d.cts +278 -0
  53. package/lib/Excalidraw.d.ts +278 -0
  54. package/lib/Excalidraw.js +6 -0
  55. package/lib/ExportPdf.cjs +15 -0
  56. package/lib/ExportPdf.d.cts +270 -0
  57. package/lib/ExportPdf.d.ts +270 -0
  58. package/lib/ExportPdf.js +67 -0
  59. package/lib/ExportWord.cjs +1 -0
  60. package/lib/ExportWord.d.cts +341 -0
  61. package/lib/ExportWord.d.ts +341 -0
  62. package/lib/ExportWord.js +72 -0
  63. package/lib/FontFamily.cjs +1 -0
  64. package/lib/FontFamily.d.cts +354 -0
  65. package/lib/FontFamily.d.ts +354 -0
  66. package/lib/FontFamily.js +136 -0
  67. package/lib/FontSize.cjs +1 -0
  68. package/lib/FontSize.d.cts +359 -0
  69. package/lib/FontSize.d.ts +359 -0
  70. package/lib/FontSize.js +110 -0
  71. package/lib/FormatPainter.cjs +1 -0
  72. package/lib/FormatPainter.d.cts +353 -0
  73. package/lib/FormatPainter.d.ts +353 -0
  74. package/lib/FormatPainter.js +74 -0
  75. package/lib/Heading.cjs +1 -0
  76. package/lib/Heading.d.cts +343 -0
  77. package/lib/Heading.d.ts +343 -0
  78. package/lib/Heading.js +147 -0
  79. package/lib/Highlight.cjs +1 -0
  80. package/lib/Highlight.d.cts +344 -0
  81. package/lib/Highlight.d.ts +344 -0
  82. package/lib/Highlight.js +85 -0
  83. package/lib/History.cjs +1 -0
  84. package/lib/History.d.cts +343 -0
  85. package/lib/History.d.ts +343 -0
  86. package/lib/History.js +431 -0
  87. package/lib/HorizontalRule.cjs +1 -0
  88. package/lib/HorizontalRule.d.cts +343 -0
  89. package/lib/HorizontalRule.d.ts +343 -0
  90. package/lib/HorizontalRule.js +87 -0
  91. package/lib/Iframe.cjs +1 -0
  92. package/lib/Iframe.d.cts +277 -0
  93. package/lib/Iframe.d.ts +277 -0
  94. package/lib/Iframe.js +6 -0
  95. package/lib/Image.cjs +1 -0
  96. package/lib/Image.d.cts +370 -0
  97. package/lib/Image.d.ts +370 -0
  98. package/lib/Image.js +7 -0
  99. package/lib/ImageGif.cjs +1 -0
  100. package/lib/ImageGif.d.cts +292 -0
  101. package/lib/ImageGif.d.ts +292 -0
  102. package/lib/ImageGif.js +7 -0
  103. package/lib/ImportWord.cjs +231 -0
  104. package/lib/ImportWord.d.cts +353 -0
  105. package/lib/ImportWord.d.ts +353 -0
  106. package/lib/ImportWord.js +16620 -0
  107. package/lib/Indent.cjs +1 -0
  108. package/lib/Indent.d.cts +344 -0
  109. package/lib/Indent.d.ts +344 -0
  110. package/lib/Indent.js +78 -0
  111. package/lib/Italic.cjs +1 -0
  112. package/lib/Italic.d.cts +343 -0
  113. package/lib/Italic.d.ts +343 -0
  114. package/lib/Italic.js +91 -0
  115. package/lib/Katex.cjs +1 -0
  116. package/lib/Katex.d.cts +279 -0
  117. package/lib/Katex.d.ts +279 -0
  118. package/lib/Katex.js +197 -0
  119. package/lib/LineHeight.cjs +1 -0
  120. package/lib/LineHeight.d.cts +347 -0
  121. package/lib/LineHeight.d.ts +347 -0
  122. package/lib/LineHeight.js +137 -0
  123. package/lib/Link.cjs +5 -0
  124. package/lib/Link.d.cts +343 -0
  125. package/lib/Link.d.ts +343 -0
  126. package/lib/Link.js +1048 -0
  127. package/lib/ListItem.cjs +1 -0
  128. package/lib/ListItem.d.cts +269 -0
  129. package/lib/ListItem.d.ts +269 -0
  130. package/lib/ListItem.js +33 -0
  131. package/lib/Mention.cjs +1 -0
  132. package/lib/Mention.d.cts +272 -0
  133. package/lib/Mention.d.ts +272 -0
  134. package/lib/Mention.js +233 -0
  135. package/lib/Mermaid.cjs +2 -0
  136. package/lib/Mermaid.d.cts +344 -0
  137. package/lib/Mermaid.d.ts +344 -0
  138. package/lib/Mermaid.js +390 -0
  139. package/lib/MoreMark.cjs +1 -0
  140. package/lib/MoreMark.d.cts +355 -0
  141. package/lib/MoreMark.d.ts +355 -0
  142. package/lib/MoreMark.js +95 -0
  143. package/lib/MultiColumn.cjs +1 -0
  144. package/lib/MultiColumn.d.cts +277 -0
  145. package/lib/MultiColumn.d.ts +277 -0
  146. package/lib/MultiColumn.js +8 -0
  147. package/lib/OrderedList.cjs +1 -0
  148. package/lib/OrderedList.d.cts +343 -0
  149. package/lib/OrderedList.d.ts +343 -0
  150. package/lib/OrderedList.js +90 -0
  151. package/lib/RichTextEditor-Cy9XKEI5.js +11178 -0
  152. package/lib/RichTextEditor-DkpDEr5U.cjs +137 -0
  153. package/lib/SearchAndReplace.cjs +1 -0
  154. package/lib/SearchAndReplace.d.cts +358 -0
  155. package/lib/SearchAndReplace.d.ts +358 -0
  156. package/lib/SearchAndReplace.js +339 -0
  157. package/lib/Selection.cjs +1 -0
  158. package/lib/Selection.d.cts +272 -0
  159. package/lib/Selection.d.ts +272 -0
  160. package/lib/Selection.js +25 -0
  161. package/lib/SlashCommand.cjs +1 -0
  162. package/lib/SlashCommand.d.cts +299 -0
  163. package/lib/SlashCommand.d.ts +299 -0
  164. package/lib/SlashCommand.js +369 -0
  165. package/lib/Strike.cjs +1 -0
  166. package/lib/Strike.d.cts +343 -0
  167. package/lib/Strike.d.ts +343 -0
  168. package/lib/Strike.js +80 -0
  169. package/lib/SubAndSuperScript.cjs +1 -0
  170. package/lib/SubAndSuperScript.d.cts +358 -0
  171. package/lib/SubAndSuperScript.d.ts +358 -0
  172. package/lib/SubAndSuperScript.js +41 -0
  173. package/lib/Table.cjs +1 -0
  174. package/lib/Table.d.cts +366 -0
  175. package/lib/Table.d.ts +366 -0
  176. package/lib/Table.js +2165 -0
  177. package/lib/TableOfContent.cjs +1 -0
  178. package/lib/TableOfContent.d.cts +274 -0
  179. package/lib/TableOfContent.d.ts +274 -0
  180. package/lib/TableOfContent.js +184 -0
  181. package/lib/TaskList.cjs +1 -0
  182. package/lib/TaskList.d.cts +349 -0
  183. package/lib/TaskList.d.ts +349 -0
  184. package/lib/TaskList.js +175 -0
  185. package/lib/TextAlign.cjs +1 -0
  186. package/lib/TextAlign.d.cts +353 -0
  187. package/lib/TextAlign.d.ts +353 -0
  188. package/lib/TextAlign.js +165 -0
  189. package/lib/TextBubble.cjs +1 -0
  190. package/lib/TextBubble.d.cts +343 -0
  191. package/lib/TextBubble.d.ts +343 -0
  192. package/lib/TextBubble.js +131 -0
  193. package/lib/TextDirection.cjs +1 -0
  194. package/lib/TextDirection.d.cts +270 -0
  195. package/lib/TextDirection.d.ts +270 -0
  196. package/lib/TextDirection.js +142 -0
  197. package/lib/TextUnderline.cjs +1 -0
  198. package/lib/TextUnderline.d.cts +343 -0
  199. package/lib/TextUnderline.d.ts +343 -0
  200. package/lib/TextUnderline.js +61 -0
  201. package/lib/TrailingNode.cjs +1 -0
  202. package/lib/TrailingNode.d.cts +280 -0
  203. package/lib/TrailingNode.d.ts +280 -0
  204. package/lib/TrailingNode.js +41 -0
  205. package/lib/Twitter-B_tSItrW.js +1743 -0
  206. package/lib/Twitter-CfDC4bFV.cjs +17 -0
  207. package/lib/Twitter.cjs +1 -0
  208. package/lib/Twitter.d.cts +295 -0
  209. package/lib/Twitter.d.ts +295 -0
  210. package/lib/Twitter.js +6 -0
  211. package/lib/Video.cjs +1 -0
  212. package/lib/Video.d.cts +371 -0
  213. package/lib/Video.d.ts +371 -0
  214. package/lib/Video.js +6 -0
  215. package/lib/bubble-extra.cjs +2 -0
  216. package/lib/bubble-extra.d.cts +294 -0
  217. package/lib/bubble-extra.d.ts +294 -0
  218. package/lib/bubble-extra.js +623 -0
  219. package/lib/dom-dataset-CAXnsjYE.cjs +33 -0
  220. package/lib/dom-dataset-CJ7GyQ2E.js +999 -0
  221. package/lib/index-COecBbaE.cjs +89 -0
  222. package/lib/index-ClFtfQ0J.cjs +1 -0
  223. package/lib/index-CvYIX2-x.js +129 -0
  224. package/lib/index-CySbCeQd.cjs +1 -0
  225. package/lib/{index-CO-iymkb.js → index-D9llIWB5.js} +442 -101
  226. package/lib/index-DXBa3JBo.js +46 -0
  227. package/lib/index-DjP7Onch.cjs +1 -0
  228. package/lib/index-Drmyqk9P.js +12322 -0
  229. package/lib/index-DuhDIOel.js +76 -0
  230. package/lib/index-LbrE7K9i.cjs +1 -0
  231. package/lib/index.cjs +2 -1
  232. package/lib/index.d.cts +290 -108
  233. package/lib/index.d.ts +290 -108
  234. package/lib/index.js +587 -13
  235. package/lib/locale-bundle.cjs +1 -1
  236. package/lib/locale-bundle.d.cts +108 -108
  237. package/lib/locale-bundle.d.ts +108 -108
  238. package/lib/locale-bundle.js +1 -1
  239. package/lib/shortId-Bfj8TyNr.cjs +2 -0
  240. package/lib/shortId-WJVkrvml.js +30 -0
  241. package/lib/style.css +1 -1
  242. package/lib/textarea-B45fP3gP.cjs +1 -0
  243. package/lib/textarea-DXTdXr2y.js +20 -0
  244. package/package.json +678 -15
  245. package/lib/RichTextEditor-Ce2IeNE6.js +0 -8265
  246. package/lib/RichTextEditor-hDDApaDD.cjs +0 -136
  247. package/lib/extension-bundle.cjs +0 -33
  248. package/lib/extension-bundle.d.cts +0 -951
  249. package/lib/extension-bundle.d.ts +0 -951
  250. package/lib/extension-bundle.js +0 -5982
  251. package/lib/index-CJ6Hb9MN.cjs +0 -1
  252. package/lib/tiptap-DOP8lVCQ.js +0 -5950
  253. package/lib/tiptap-Dq62HiQ9.cjs +0 -113
  254. package/lib/vendor-BbgkyoD-.js +0 -40297
  255. package/lib/vendor-DdwtMmSr.cjs +0 -302
@@ -0,0 +1,95 @@
1
+ import { E as h } from "./index-Drmyqk9P.js";
2
+ import { S as d, a as m } from "./index-DuhDIOel.js";
3
+ import { jsxs as u, jsx as c } from "react/jsx-runtime";
4
+ import { useMemo as f } from "react";
5
+ import { D as x, e as b, A as g, M, f as S, h as k, k as A, g as w } from "./RichTextEditor-Cy9XKEI5.js";
6
+ function y(t) {
7
+ var s;
8
+ const i = f(() => {
9
+ var o;
10
+ const e = (o = t == null ? void 0 : t.items) == null ? void 0 : o.find((a) => a.isActive());
11
+ return e && !e.default ? {
12
+ ...e,
13
+ icon: e != null && e.icon ? e == null ? void 0 : e.icon : t == null ? void 0 : t.icon
14
+ } : {
15
+ title: t.tooltip,
16
+ icon: t.icon,
17
+ isActive: () => !1
18
+ };
19
+ }, [t]);
20
+ return /* @__PURE__ */ u(x, { children: [
21
+ /* @__PURE__ */ c(
22
+ b,
23
+ {
24
+ asChild: !0,
25
+ disabled: t == null ? void 0 : t.disabled,
26
+ children: /* @__PURE__ */ c(
27
+ g,
28
+ {
29
+ customClass: "!richtext-w-12 richtext-h-12",
30
+ disabled: t == null ? void 0 : t.disabled,
31
+ icon: t == null ? void 0 : t.icon,
32
+ tooltip: t == null ? void 0 : t.tooltip,
33
+ children: /* @__PURE__ */ c(M, { className: "richtext-size-3 richtext-text-gray-500" })
34
+ }
35
+ )
36
+ }
37
+ ),
38
+ /* @__PURE__ */ c(S, { className: "w-full", children: (s = t == null ? void 0 : t.items) == null ? void 0 : s.map((e, n) => /* @__PURE__ */ u(
39
+ k,
40
+ {
41
+ checked: i.title === e.title,
42
+ className: "richtext-flex richtext-items-center richtext-gap-3",
43
+ onClick: e.action,
44
+ children: [
45
+ /* @__PURE__ */ c(A, { name: e == null ? void 0 : e.icon }),
46
+ /* @__PURE__ */ c("span", { className: "richtext-ml-1", children: e.title }),
47
+ !!(e != null && e.shortcutKeys) && /* @__PURE__ */ c("span", { className: "richtext-ml-auto richtext-text-xs richtext-tracking-widest richtext-opacity-60", children: w(e.shortcutKeys) })
48
+ ]
49
+ },
50
+ `more-mark-${n}`
51
+ )) })
52
+ ] });
53
+ }
54
+ const B = /* @__PURE__ */ h.create({
55
+ name: "moreMark",
56
+ addOptions() {
57
+ var t;
58
+ return {
59
+ ...(t = this.parent) == null ? void 0 : t.call(this),
60
+ button({ editor: i, extension: s, t: e }) {
61
+ const n = s.options.subscript, o = s.options.superscript, a = {
62
+ action: () => i.commands.toggleSubscript(),
63
+ isActive: () => i.isActive("subscript") || !1,
64
+ disabled: !i.can().toggleSubscript(),
65
+ icon: "Subscript",
66
+ title: e("editor.subscript.tooltip"),
67
+ shortcutKeys: ["mod", "."]
68
+ }, l = {
69
+ action: () => i.commands.toggleSuperscript(),
70
+ isActive: () => i.isActive("superscript") || !1,
71
+ disabled: !i.can().toggleSuperscript(),
72
+ icon: "Superscript",
73
+ title: e("editor.superscript.tooltip"),
74
+ shortcutKeys: ["mod", ","]
75
+ }, r = [];
76
+ return n !== !1 && r.push(a), o !== !1 && r.push(l), {
77
+ component: y,
78
+ componentProps: {
79
+ icon: "Type",
80
+ tooltip: e("editor.moremark"),
81
+ disabled: !i.isEditable,
82
+ items: r
83
+ }
84
+ };
85
+ }
86
+ };
87
+ },
88
+ addExtensions() {
89
+ const t = [];
90
+ return this.options.subscript !== !1 && t.push(d.configure(this.options.subscript)), this.options.superscript !== !1 && t.push(m.configure(this.options.superscript)), t;
91
+ }
92
+ });
93
+ export {
94
+ B as MoreMark
95
+ };
@@ -0,0 +1 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require("./index-COecBbaE.cjs");const o=require("./RichTextEditor-DkpDEr5U.cjs");exports.Column=o.Column;exports.ColumnActionButton=o.ColumnActionButton;exports.EXTENSION_PRIORITY_HIGHEST=o.EXTENSION_PRIORITY_HIGHEST;exports.MultiColumn=o.MultiColumn;
@@ -0,0 +1,277 @@
1
+ import { Extension } from '@tiptap/core';
2
+ import { Node as Node_2 } from '@tiptap/core';
3
+
4
+ export declare const Column: Node_2<any, any>;
5
+
6
+ export declare const ColumnActionButton: Extension<any, any>;
7
+
8
+ export declare const EXTENSION_PRIORITY_HIGHEST = 200;
9
+
10
+ export declare const MultiColumn: Node_2<any, any>;
11
+
12
+ export { }
13
+
14
+
15
+ declare module '@tiptap/core' {
16
+ interface Commands<ReturnType> {
17
+ attachment: {
18
+ setAttachment: (attrs?: unknown) => ReturnType;
19
+ };
20
+ }
21
+ }
22
+
23
+
24
+ declare module '@tiptap/core' {
25
+ interface Commands<ReturnType> {
26
+ setCodeBlock: {
27
+ setCodeBlock: (options?: any) => ReturnType;
28
+ };
29
+ }
30
+ }
31
+
32
+
33
+ declare module '@tiptap/core' {
34
+ interface Commands<ReturnType> {
35
+ excalidraw: {
36
+ setExcalidraw: (attrs?: IExcalidrawAttrs) => ReturnType;
37
+ };
38
+ }
39
+ }
40
+
41
+
42
+ declare module '@tiptap/core' {
43
+ interface Commands<ReturnType> {
44
+ emoji: {
45
+ setEmoji: (emoji: {
46
+ name: string;
47
+ emoji: string;
48
+ }) => ReturnType;
49
+ };
50
+ }
51
+ }
52
+
53
+
54
+ declare module '@tiptap/core' {
55
+ interface Commands<ReturnType> {
56
+ drawer: {
57
+ setDrawer: (options: any, replace?: any) => ReturnType;
58
+ setAlignImageDrawer: (align: 'left' | 'center' | 'right') => ReturnType;
59
+ };
60
+ }
61
+ }
62
+
63
+
64
+ declare module '@tiptap/core' {
65
+ interface Commands<ReturnType> {
66
+ exportWord: {
67
+ exportToWord: () => ReturnType;
68
+ };
69
+ }
70
+ }
71
+
72
+
73
+ declare module '@tiptap/core' {
74
+ interface Commands<ReturnType> {
75
+ fontSize: {
76
+ /**
77
+ * Set the text font size. ex: "12px", "2em", or "small". Must be a valid
78
+ * CSS font-size
79
+ * (https://developer.mozilla.org/en-US/docs/Web/CSS/font-size).
80
+ */
81
+ setFontSize: (fontSize: string) => ReturnType;
82
+ /**
83
+ * Unset the font size
84
+ */
85
+ unsetFontSize: () => ReturnType;
86
+ };
87
+ }
88
+ }
89
+
90
+
91
+ declare module '@tiptap/core' {
92
+ interface Commands<ReturnType> {
93
+ painter: {
94
+ setPainter: (marks: Mark[]) => ReturnType;
95
+ };
96
+ }
97
+ }
98
+
99
+
100
+ declare module '@tiptap/core' {
101
+ interface Commands<ReturnType> {
102
+ iframe: {
103
+ /**
104
+ * Add an iframe
105
+ */
106
+ setIframe: (options: {
107
+ src: string;
108
+ service: string;
109
+ }) => ReturnType;
110
+ };
111
+ }
112
+ }
113
+
114
+
115
+ declare module '@tiptap/core' {
116
+ interface Commands<ReturnType> {
117
+ imageUpload: {
118
+ /**
119
+ * Add an image
120
+ */
121
+ setImageInline: (options: Partial<SetImageAttrsOptions>) => ReturnType;
122
+ /**
123
+ * Update an image
124
+ */
125
+ updateImage: (options: Partial<SetImageAttrsOptions>) => ReturnType;
126
+ /**
127
+ * Set image alignment
128
+ */
129
+ setAlignImage: (align: 'left' | 'center' | 'right') => ReturnType;
130
+ };
131
+ }
132
+ }
133
+
134
+
135
+ declare module '@tiptap/core' {
136
+ interface Commands<ReturnType> {
137
+ imageGifUpload: {
138
+ /**
139
+ * Add an image gif
140
+ */
141
+ setImageGif: (options: Partial<SetImageAttrsOptions>) => ReturnType;
142
+ /**
143
+ * Update an image gif
144
+ */
145
+ updateImageGif: (options: Partial<SetImageAttrsOptions>) => ReturnType;
146
+ /**
147
+ * Set image alignment
148
+ */
149
+ setAlignImageGif: (align: 'left' | 'center' | 'right') => ReturnType;
150
+ };
151
+ }
152
+ }
153
+
154
+
155
+ declare module '@tiptap/core' {
156
+ interface Commands<ReturnType> {
157
+ indent: {
158
+ /**
159
+ * Set the indent attribute
160
+ */
161
+ indent: () => ReturnType;
162
+ /**
163
+ * Set the outdent attribute
164
+ */
165
+ outdent: () => ReturnType;
166
+ };
167
+ }
168
+ }
169
+
170
+
171
+ declare module '@tiptap/core' {
172
+ interface Commands<ReturnType> {
173
+ katex: {
174
+ setKatex: (arg?: IKatexAttrs) => ReturnType;
175
+ };
176
+ }
177
+ }
178
+
179
+
180
+ declare module '@tiptap/core' {
181
+ interface Commands<ReturnType> {
182
+ lineHeight: {
183
+ setLineHeight: (lineHeight: string) => ReturnType;
184
+ unsetLineHeight: () => ReturnType;
185
+ };
186
+ }
187
+ }
188
+
189
+
190
+ declare module '@tiptap/core' {
191
+ interface Commands<ReturnType> {
192
+ mermaid: {
193
+ setMermaid: (options: any, replace?: any) => ReturnType;
194
+ setAlignImageMermaid: (align: 'left' | 'center' | 'right') => ReturnType;
195
+ };
196
+ }
197
+ }
198
+
199
+
200
+ declare module '@tiptap/core' {
201
+ interface Commands<ReturnType> {
202
+ columns: {
203
+ insertColumns: (attrs?: {
204
+ cols: number;
205
+ }) => ReturnType;
206
+ addColBefore: () => ReturnType;
207
+ addColAfter: () => ReturnType;
208
+ deleteCol: () => ReturnType;
209
+ };
210
+ }
211
+ }
212
+
213
+
214
+ declare module '@tiptap/core' {
215
+ interface Commands<ReturnType> {
216
+ search: {
217
+ setSearchTerm: (searchTerm: string) => ReturnType;
218
+ setReplaceTerm: (replaceTerm: string) => ReturnType;
219
+ replace: () => ReturnType;
220
+ replaceAll: () => ReturnType;
221
+ goToPrevSearchResult: () => void;
222
+ goToNextSearchResult: () => void;
223
+ setCaseSensitive: (caseSensitive: boolean) => ReturnType;
224
+ };
225
+ }
226
+ }
227
+
228
+
229
+ declare module '@tiptap/core' {
230
+ interface Commands<ReturnType> {
231
+ tableOfContents: {
232
+ setTableOfContents: () => ReturnType;
233
+ removeTableOfContents: () => ReturnType;
234
+ };
235
+ }
236
+ }
237
+
238
+
239
+ declare module '@tiptap/core' {
240
+ interface Commands<ReturnType> {
241
+ twitter: {
242
+ /**
243
+ * Insert a tweet
244
+ * @param options The tweet attributes
245
+ * @example editor.commands.setTweet({ src: 'https://x.com/seanpk/status/1800145949580517852' })
246
+ */
247
+ setTweet: (options: SetTweetOptions) => ReturnType;
248
+ updateTweet: (options: SetTweetOptions) => ReturnType;
249
+ };
250
+ }
251
+ }
252
+
253
+
254
+ declare module '@tiptap/core' {
255
+ interface Commands<ReturnType> {
256
+ video: {
257
+ /**
258
+ * Add an video
259
+ */
260
+ setVideo: (options: Partial<SetVideoOptions>) => ReturnType;
261
+ /**
262
+ * Update an video
263
+ */
264
+ updateVideo: (options: Partial<SetVideoOptions>) => ReturnType;
265
+ };
266
+ }
267
+ }
268
+
269
+
270
+ declare module '@tiptap/core' {
271
+ interface Commands<ReturnType> {
272
+ tableCellBackground: {
273
+ setTableCellBackground: (color: string) => ReturnType;
274
+ unsetTableCellBackground: () => ReturnType;
275
+ };
276
+ }
277
+ }
@@ -0,0 +1,277 @@
1
+ import { Extension } from '@tiptap/core';
2
+ import { Node as Node_2 } from '@tiptap/core';
3
+
4
+ export declare const Column: Node_2<any, any>;
5
+
6
+ export declare const ColumnActionButton: Extension<any, any>;
7
+
8
+ export declare const EXTENSION_PRIORITY_HIGHEST = 200;
9
+
10
+ export declare const MultiColumn: Node_2<any, any>;
11
+
12
+ export { }
13
+
14
+
15
+ declare module '@tiptap/core' {
16
+ interface Commands<ReturnType> {
17
+ attachment: {
18
+ setAttachment: (attrs?: unknown) => ReturnType;
19
+ };
20
+ }
21
+ }
22
+
23
+
24
+ declare module '@tiptap/core' {
25
+ interface Commands<ReturnType> {
26
+ setCodeBlock: {
27
+ setCodeBlock: (options?: any) => ReturnType;
28
+ };
29
+ }
30
+ }
31
+
32
+
33
+ declare module '@tiptap/core' {
34
+ interface Commands<ReturnType> {
35
+ excalidraw: {
36
+ setExcalidraw: (attrs?: IExcalidrawAttrs) => ReturnType;
37
+ };
38
+ }
39
+ }
40
+
41
+
42
+ declare module '@tiptap/core' {
43
+ interface Commands<ReturnType> {
44
+ emoji: {
45
+ setEmoji: (emoji: {
46
+ name: string;
47
+ emoji: string;
48
+ }) => ReturnType;
49
+ };
50
+ }
51
+ }
52
+
53
+
54
+ declare module '@tiptap/core' {
55
+ interface Commands<ReturnType> {
56
+ drawer: {
57
+ setDrawer: (options: any, replace?: any) => ReturnType;
58
+ setAlignImageDrawer: (align: 'left' | 'center' | 'right') => ReturnType;
59
+ };
60
+ }
61
+ }
62
+
63
+
64
+ declare module '@tiptap/core' {
65
+ interface Commands<ReturnType> {
66
+ exportWord: {
67
+ exportToWord: () => ReturnType;
68
+ };
69
+ }
70
+ }
71
+
72
+
73
+ declare module '@tiptap/core' {
74
+ interface Commands<ReturnType> {
75
+ fontSize: {
76
+ /**
77
+ * Set the text font size. ex: "12px", "2em", or "small". Must be a valid
78
+ * CSS font-size
79
+ * (https://developer.mozilla.org/en-US/docs/Web/CSS/font-size).
80
+ */
81
+ setFontSize: (fontSize: string) => ReturnType;
82
+ /**
83
+ * Unset the font size
84
+ */
85
+ unsetFontSize: () => ReturnType;
86
+ };
87
+ }
88
+ }
89
+
90
+
91
+ declare module '@tiptap/core' {
92
+ interface Commands<ReturnType> {
93
+ painter: {
94
+ setPainter: (marks: Mark[]) => ReturnType;
95
+ };
96
+ }
97
+ }
98
+
99
+
100
+ declare module '@tiptap/core' {
101
+ interface Commands<ReturnType> {
102
+ iframe: {
103
+ /**
104
+ * Add an iframe
105
+ */
106
+ setIframe: (options: {
107
+ src: string;
108
+ service: string;
109
+ }) => ReturnType;
110
+ };
111
+ }
112
+ }
113
+
114
+
115
+ declare module '@tiptap/core' {
116
+ interface Commands<ReturnType> {
117
+ imageUpload: {
118
+ /**
119
+ * Add an image
120
+ */
121
+ setImageInline: (options: Partial<SetImageAttrsOptions>) => ReturnType;
122
+ /**
123
+ * Update an image
124
+ */
125
+ updateImage: (options: Partial<SetImageAttrsOptions>) => ReturnType;
126
+ /**
127
+ * Set image alignment
128
+ */
129
+ setAlignImage: (align: 'left' | 'center' | 'right') => ReturnType;
130
+ };
131
+ }
132
+ }
133
+
134
+
135
+ declare module '@tiptap/core' {
136
+ interface Commands<ReturnType> {
137
+ imageGifUpload: {
138
+ /**
139
+ * Add an image gif
140
+ */
141
+ setImageGif: (options: Partial<SetImageAttrsOptions>) => ReturnType;
142
+ /**
143
+ * Update an image gif
144
+ */
145
+ updateImageGif: (options: Partial<SetImageAttrsOptions>) => ReturnType;
146
+ /**
147
+ * Set image alignment
148
+ */
149
+ setAlignImageGif: (align: 'left' | 'center' | 'right') => ReturnType;
150
+ };
151
+ }
152
+ }
153
+
154
+
155
+ declare module '@tiptap/core' {
156
+ interface Commands<ReturnType> {
157
+ indent: {
158
+ /**
159
+ * Set the indent attribute
160
+ */
161
+ indent: () => ReturnType;
162
+ /**
163
+ * Set the outdent attribute
164
+ */
165
+ outdent: () => ReturnType;
166
+ };
167
+ }
168
+ }
169
+
170
+
171
+ declare module '@tiptap/core' {
172
+ interface Commands<ReturnType> {
173
+ katex: {
174
+ setKatex: (arg?: IKatexAttrs) => ReturnType;
175
+ };
176
+ }
177
+ }
178
+
179
+
180
+ declare module '@tiptap/core' {
181
+ interface Commands<ReturnType> {
182
+ lineHeight: {
183
+ setLineHeight: (lineHeight: string) => ReturnType;
184
+ unsetLineHeight: () => ReturnType;
185
+ };
186
+ }
187
+ }
188
+
189
+
190
+ declare module '@tiptap/core' {
191
+ interface Commands<ReturnType> {
192
+ mermaid: {
193
+ setMermaid: (options: any, replace?: any) => ReturnType;
194
+ setAlignImageMermaid: (align: 'left' | 'center' | 'right') => ReturnType;
195
+ };
196
+ }
197
+ }
198
+
199
+
200
+ declare module '@tiptap/core' {
201
+ interface Commands<ReturnType> {
202
+ columns: {
203
+ insertColumns: (attrs?: {
204
+ cols: number;
205
+ }) => ReturnType;
206
+ addColBefore: () => ReturnType;
207
+ addColAfter: () => ReturnType;
208
+ deleteCol: () => ReturnType;
209
+ };
210
+ }
211
+ }
212
+
213
+
214
+ declare module '@tiptap/core' {
215
+ interface Commands<ReturnType> {
216
+ search: {
217
+ setSearchTerm: (searchTerm: string) => ReturnType;
218
+ setReplaceTerm: (replaceTerm: string) => ReturnType;
219
+ replace: () => ReturnType;
220
+ replaceAll: () => ReturnType;
221
+ goToPrevSearchResult: () => void;
222
+ goToNextSearchResult: () => void;
223
+ setCaseSensitive: (caseSensitive: boolean) => ReturnType;
224
+ };
225
+ }
226
+ }
227
+
228
+
229
+ declare module '@tiptap/core' {
230
+ interface Commands<ReturnType> {
231
+ tableOfContents: {
232
+ setTableOfContents: () => ReturnType;
233
+ removeTableOfContents: () => ReturnType;
234
+ };
235
+ }
236
+ }
237
+
238
+
239
+ declare module '@tiptap/core' {
240
+ interface Commands<ReturnType> {
241
+ twitter: {
242
+ /**
243
+ * Insert a tweet
244
+ * @param options The tweet attributes
245
+ * @example editor.commands.setTweet({ src: 'https://x.com/seanpk/status/1800145949580517852' })
246
+ */
247
+ setTweet: (options: SetTweetOptions) => ReturnType;
248
+ updateTweet: (options: SetTweetOptions) => ReturnType;
249
+ };
250
+ }
251
+ }
252
+
253
+
254
+ declare module '@tiptap/core' {
255
+ interface Commands<ReturnType> {
256
+ video: {
257
+ /**
258
+ * Add an video
259
+ */
260
+ setVideo: (options: Partial<SetVideoOptions>) => ReturnType;
261
+ /**
262
+ * Update an video
263
+ */
264
+ updateVideo: (options: Partial<SetVideoOptions>) => ReturnType;
265
+ };
266
+ }
267
+ }
268
+
269
+
270
+ declare module '@tiptap/core' {
271
+ interface Commands<ReturnType> {
272
+ tableCellBackground: {
273
+ setTableCellBackground: (color: string) => ReturnType;
274
+ unsetTableCellBackground: () => ReturnType;
275
+ };
276
+ }
277
+ }
@@ -0,0 +1,8 @@
1
+ import "./index-Drmyqk9P.js";
2
+ import { a8 as m, ah as n, ag as u, a9 as l } from "./RichTextEditor-Cy9XKEI5.js";
3
+ export {
4
+ m as Column,
5
+ n as ColumnActionButton,
6
+ u as EXTENSION_PRIORITY_HIGHEST,
7
+ l as MultiColumn
8
+ };
@@ -0,0 +1 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("./index-COecBbaE.cjs"),n=require("./RichTextEditor-DkpDEr5U.cjs"),a="listItem",i="textStyle",o=/^(\d+)\.\s$/,d=r.Node.create({name:"orderedList",addOptions(){return{itemTypeName:"listItem",HTMLAttributes:{},keepMarks:!1,keepAttributes:!1}},group:"block list",content(){return`${this.options.itemTypeName}+`},addAttributes(){return{start:{default:1,parseHTML:t=>t.hasAttribute("start")?parseInt(t.getAttribute("start")||"",10):1},type:{default:null,parseHTML:t=>t.getAttribute("type")}}},parseHTML(){return[{tag:"ol"}]},renderHTML({HTMLAttributes:t}){const{start:e,...s}=t;return e===1?["ol",r.mergeAttributes(this.options.HTMLAttributes,s),0]:["ol",r.mergeAttributes(this.options.HTMLAttributes,t),0]},addCommands(){return{toggleOrderedList:()=>({commands:t,chain:e})=>this.options.keepAttributes?e().toggleList(this.name,this.options.itemTypeName,this.options.keepMarks).updateAttributes(a,this.editor.getAttributes(i)).run():t.toggleList(this.name,this.options.itemTypeName,this.options.keepMarks)}},addKeyboardShortcuts(){return{"Mod-Shift-7":()=>this.editor.commands.toggleOrderedList()}},addInputRules(){let t=r.wrappingInputRule({find:o,type:this.type,getAttributes:e=>({start:+e[1]}),joinPredicate:(e,s)=>s.childCount+s.attrs.start===+e[1]});return(this.options.keepMarks||this.options.keepAttributes)&&(t=r.wrappingInputRule({find:o,type:this.type,keepMarks:this.options.keepMarks,keepAttributes:this.options.keepAttributes,getAttributes:e=>({start:+e[1],...this.editor.getAttributes(i)}),joinPredicate:(e,s)=>s.childCount+s.attrs.start===+e[1],editor:this.editor})),[t]}}),u=d.extend({addOptions(){var t;return{...(t=this.parent)==null?void 0:t.call(this),button:({editor:e,t:s})=>({component:n.ActionButton,componentProps:{action:()=>e.commands.toggleOrderedList(),isActive:()=>e.isActive("orderedList")||!1,disabled:!1,icon:"ListOrdered",shortcutKeys:["mod","shift","7"],tooltip:s("editor.orderedlist.tooltip")}})}}});exports.OrderedList=u;