reactjs-tiptap-editor 0.3.28 → 0.3.30
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/{ActionMenuButton-D0hFczCn.js → ActionMenuButton-B6fitGKu.js} +1 -1
- package/lib/{ActionMenuButton-C20molC9.cjs → ActionMenuButton-wiDnIxE2.cjs} +1 -1
- package/lib/Attachment.cjs +1 -1
- package/lib/Attachment.d.cts +41 -41
- package/lib/Attachment.d.ts +41 -41
- package/lib/Attachment.js +1 -1
- package/lib/Blockquote.cjs +1 -1
- package/lib/Blockquote.d.cts +41 -41
- package/lib/Blockquote.d.ts +41 -41
- package/lib/Blockquote.js +1 -1
- package/lib/Bold.cjs +1 -1
- package/lib/Bold.d.cts +41 -41
- package/lib/Bold.d.ts +41 -41
- package/lib/Bold.js +1 -1
- package/lib/BulletList.cjs +1 -1
- package/lib/BulletList.d.cts +41 -41
- package/lib/BulletList.d.ts +41 -41
- package/lib/BulletList.js +1 -1
- package/lib/Clear.cjs +1 -1
- package/lib/Clear.d.cts +41 -41
- package/lib/Clear.d.ts +41 -41
- package/lib/Clear.js +1 -1
- package/lib/Code.cjs +1 -1
- package/lib/Code.d.cts +41 -41
- package/lib/Code.d.ts +41 -41
- package/lib/Code.js +1 -1
- package/lib/CodeBlock.cjs +1 -1
- package/lib/CodeBlock.d.cts +41 -41
- package/lib/CodeBlock.d.ts +41 -41
- package/lib/CodeBlock.js +1 -1
- package/lib/CodeView.cjs +1 -1
- package/lib/CodeView.d.cts +41 -41
- package/lib/CodeView.d.ts +41 -41
- package/lib/CodeView.js +1 -1
- package/lib/Color.cjs +1 -1
- package/lib/Color.d.cts +41 -41
- package/lib/Color.d.ts +41 -41
- package/lib/Color.js +1 -1
- package/lib/Document.d.cts +41 -41
- package/lib/Document.d.ts +41 -41
- package/lib/{Drawer-B96jQIQU.js → Drawer-BKTU9CpU.js} +1 -1
- package/lib/{Drawer-0kBt3GVL.cjs → Drawer-CmoEF-Zg.cjs} +1 -1
- package/lib/Drawer.cjs +1 -1
- package/lib/Drawer.d.cts +41 -41
- package/lib/Drawer.d.ts +41 -41
- package/lib/Drawer.js +2 -2
- package/lib/Emoji.cjs +1 -1
- package/lib/Emoji.d.cts +41 -41
- package/lib/Emoji.d.ts +41 -41
- package/lib/Emoji.js +1 -1
- package/lib/{Excalidraw-z3VZyGJ4.js → Excalidraw-CM74U5tG.js} +1 -1
- package/lib/{Excalidraw-HK9kjpX5.cjs → Excalidraw-DAPP9qgY.cjs} +1 -1
- package/lib/Excalidraw.cjs +1 -1
- package/lib/Excalidraw.d.cts +41 -41
- package/lib/Excalidraw.d.ts +41 -41
- package/lib/Excalidraw.js +1 -1
- package/lib/ExportPdf.cjs +1 -1
- package/lib/ExportPdf.d.cts +41 -41
- package/lib/ExportPdf.d.ts +41 -41
- package/lib/ExportPdf.js +1 -1
- package/lib/ExportWord.cjs +1 -1
- package/lib/ExportWord.d.cts +41 -41
- package/lib/ExportWord.d.ts +41 -41
- package/lib/ExportWord.js +1 -1
- package/lib/FontFamily.cjs +1 -1
- package/lib/FontFamily.d.cts +41 -41
- package/lib/FontFamily.d.ts +41 -41
- package/lib/FontFamily.js +2 -2
- package/lib/FontSize.cjs +1 -1
- package/lib/FontSize.d.cts +41 -41
- package/lib/FontSize.d.ts +41 -41
- package/lib/FontSize.js +2 -2
- package/lib/FormatPainter.cjs +1 -1
- package/lib/FormatPainter.d.cts +41 -41
- package/lib/FormatPainter.d.ts +41 -41
- package/lib/FormatPainter.js +1 -1
- package/lib/Heading.cjs +1 -1
- package/lib/Heading.d.cts +41 -41
- package/lib/Heading.d.ts +41 -41
- package/lib/Heading.js +2 -2
- package/lib/Highlight.cjs +1 -1
- package/lib/Highlight.d.cts +41 -41
- package/lib/Highlight.d.ts +41 -41
- package/lib/Highlight.js +1 -1
- package/lib/History.cjs +1 -1
- package/lib/History.d.cts +41 -41
- package/lib/History.d.ts +41 -41
- package/lib/History.js +1 -1
- package/lib/HorizontalRule.cjs +1 -1
- package/lib/HorizontalRule.d.cts +41 -41
- package/lib/HorizontalRule.d.ts +41 -41
- package/lib/HorizontalRule.js +1 -1
- package/lib/Iframe.cjs +1 -1
- package/lib/Iframe.d.cts +41 -41
- package/lib/Iframe.d.ts +41 -41
- package/lib/Iframe.js +1 -1
- package/lib/Image.cjs +1 -1
- package/lib/Image.d.cts +41 -41
- package/lib/Image.d.ts +41 -41
- package/lib/Image.js +1 -1
- package/lib/ImageGif.cjs +1 -1
- package/lib/ImageGif.d.cts +44 -43
- package/lib/ImageGif.d.ts +44 -43
- package/lib/ImageGif.js +1 -1
- package/lib/ImportWord.cjs +1 -1
- package/lib/ImportWord.d.cts +41 -41
- package/lib/ImportWord.d.ts +41 -41
- package/lib/ImportWord.js +1 -1
- package/lib/Indent.cjs +1 -1
- package/lib/Indent.d.cts +41 -41
- package/lib/Indent.d.ts +41 -41
- package/lib/Indent.js +1 -1
- package/lib/Italic.cjs +1 -1
- package/lib/Italic.d.cts +41 -41
- package/lib/Italic.d.ts +41 -41
- package/lib/Italic.js +1 -1
- package/lib/Katex.cjs +1 -1
- package/lib/Katex.d.cts +41 -41
- package/lib/Katex.d.ts +41 -41
- package/lib/Katex.js +2 -2
- package/lib/LineHeight.cjs +1 -1
- package/lib/LineHeight.d.cts +41 -41
- package/lib/LineHeight.d.ts +41 -41
- package/lib/LineHeight.js +1 -1
- package/lib/Link.cjs +1 -1
- package/lib/Link.d.cts +41 -41
- package/lib/Link.d.ts +41 -41
- package/lib/Link.js +1 -1
- package/lib/ListItem.d.cts +41 -41
- package/lib/ListItem.d.ts +41 -41
- package/lib/Mention.d.cts +41 -41
- package/lib/Mention.d.ts +41 -41
- package/lib/Mermaid.cjs +1 -1
- package/lib/Mermaid.d.cts +41 -41
- package/lib/Mermaid.d.ts +41 -41
- package/lib/Mermaid.js +2 -2
- package/lib/MoreMark.cjs +1 -1
- package/lib/MoreMark.d.cts +41 -41
- package/lib/MoreMark.d.ts +41 -41
- package/lib/MoreMark.js +1 -1
- package/lib/MultiColumn.cjs +1 -1
- package/lib/MultiColumn.d.cts +41 -41
- package/lib/MultiColumn.d.ts +41 -41
- package/lib/MultiColumn.js +1 -1
- package/lib/OrderedList.cjs +1 -1
- package/lib/OrderedList.d.cts +41 -41
- package/lib/OrderedList.d.ts +41 -41
- package/lib/OrderedList.js +1 -1
- package/lib/{RichTextEditor-CnWZ69eX.js → RichTextEditor-BQN2eLD_.js} +997 -943
- package/lib/{RichTextEditor-BKywwUM4.cjs → RichTextEditor-C8Sm1E6J.cjs} +5 -5
- package/lib/SearchAndReplace.cjs +1 -1
- package/lib/SearchAndReplace.d.cts +41 -41
- package/lib/SearchAndReplace.d.ts +41 -41
- package/lib/SearchAndReplace.js +1 -1
- package/lib/Selection.d.cts +41 -41
- package/lib/Selection.d.ts +41 -41
- package/lib/SlashCommand.cjs +1 -1
- package/lib/SlashCommand.d.cts +41 -41
- package/lib/SlashCommand.d.ts +41 -41
- package/lib/SlashCommand.js +1 -1
- package/lib/Strike.cjs +1 -1
- package/lib/Strike.d.cts +41 -41
- package/lib/Strike.d.ts +41 -41
- package/lib/Strike.js +1 -1
- package/lib/SubAndSuperScript.cjs +1 -1
- package/lib/SubAndSuperScript.d.cts +41 -41
- package/lib/SubAndSuperScript.d.ts +41 -41
- package/lib/SubAndSuperScript.js +1 -1
- package/lib/Table.cjs +1 -1
- package/lib/Table.d.cts +41 -41
- package/lib/Table.d.ts +41 -41
- package/lib/Table.js +1 -1
- package/lib/TableOfContent.cjs +1 -1
- package/lib/TableOfContent.d.cts +41 -41
- package/lib/TableOfContent.d.ts +41 -41
- package/lib/TableOfContent.js +1 -1
- package/lib/TaskList.cjs +1 -1
- package/lib/TaskList.d.cts +41 -41
- package/lib/TaskList.d.ts +41 -41
- package/lib/TaskList.js +1 -1
- package/lib/TextAlign.cjs +1 -1
- package/lib/TextAlign.d.cts +41 -41
- package/lib/TextAlign.d.ts +41 -41
- package/lib/TextAlign.js +1 -1
- package/lib/TextBubble.cjs +1 -1
- package/lib/TextBubble.d.cts +41 -41
- package/lib/TextBubble.d.ts +41 -41
- package/lib/TextBubble.js +1 -1
- package/lib/TextDirection.cjs +1 -1
- package/lib/TextDirection.d.cts +41 -41
- package/lib/TextDirection.d.ts +41 -41
- package/lib/TextDirection.js +1 -1
- package/lib/TextUnderline.cjs +1 -1
- package/lib/TextUnderline.d.cts +41 -41
- package/lib/TextUnderline.d.ts +41 -41
- package/lib/TextUnderline.js +1 -1
- package/lib/TrailingNode.d.cts +41 -41
- package/lib/TrailingNode.d.ts +41 -41
- package/lib/{Twitter-Dj49i3B9.cjs → Twitter-CL2pu4QM.cjs} +1 -1
- package/lib/{Twitter-CCf1aM0f.js → Twitter-Dg6WWauX.js} +1 -1
- package/lib/Twitter.cjs +1 -1
- package/lib/Twitter.d.cts +41 -41
- package/lib/Twitter.d.ts +41 -41
- package/lib/Twitter.js +1 -1
- package/lib/Video.cjs +1 -1
- package/lib/Video.d.cts +41 -41
- package/lib/Video.d.ts +41 -41
- package/lib/Video.js +1 -1
- package/lib/bubble-extra.cjs +1 -1
- package/lib/bubble-extra.d.cts +41 -41
- package/lib/bubble-extra.d.ts +41 -41
- package/lib/bubble-extra.js +5 -5
- package/lib/index.cjs +1 -1
- package/lib/index.d.cts +41 -41
- package/lib/index.d.ts +41 -41
- package/lib/index.js +2 -2
- package/lib/locale-bundle.d.cts +41 -41
- package/lib/locale-bundle.d.ts +41 -41
- package/lib/style.css +1 -1
- package/lib/{textarea-nr3UZ7Wg.js → textarea-BglwYF6b.js} +1 -1
- package/lib/{textarea-DhlS0JCr.cjs → textarea-D5WVZMgt.cjs} +1 -1
- package/package.json +1 -1
package/lib/CodeBlock.d.cts
CHANGED
|
@@ -131,8 +131,11 @@ declare module '@tiptap/core' {
|
|
|
131
131
|
|
|
132
132
|
declare module '@tiptap/core' {
|
|
133
133
|
interface Commands<ReturnType> {
|
|
134
|
-
|
|
135
|
-
|
|
134
|
+
emoji: {
|
|
135
|
+
setEmoji: (emoji: {
|
|
136
|
+
name: string;
|
|
137
|
+
emoji: string;
|
|
138
|
+
}) => ReturnType;
|
|
136
139
|
};
|
|
137
140
|
}
|
|
138
141
|
}
|
|
@@ -140,11 +143,8 @@ declare module '@tiptap/core' {
|
|
|
140
143
|
|
|
141
144
|
declare module '@tiptap/core' {
|
|
142
145
|
interface Commands<ReturnType> {
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
name: string;
|
|
146
|
-
emoji: string;
|
|
147
|
-
}) => ReturnType;
|
|
146
|
+
excalidraw: {
|
|
147
|
+
setExcalidraw: (attrs?: IExcalidrawAttrs) => ReturnType;
|
|
148
148
|
};
|
|
149
149
|
}
|
|
150
150
|
}
|
|
@@ -195,21 +195,6 @@ declare module '@tiptap/core' {
|
|
|
195
195
|
}
|
|
196
196
|
|
|
197
197
|
|
|
198
|
-
declare module '@tiptap/core' {
|
|
199
|
-
interface Commands<ReturnType> {
|
|
200
|
-
iframe: {
|
|
201
|
-
/**
|
|
202
|
-
* Add an iframe
|
|
203
|
-
*/
|
|
204
|
-
setIframe: (options: {
|
|
205
|
-
src: string;
|
|
206
|
-
service: string;
|
|
207
|
-
}) => ReturnType;
|
|
208
|
-
};
|
|
209
|
-
}
|
|
210
|
-
}
|
|
211
|
-
|
|
212
|
-
|
|
213
198
|
declare module '@tiptap/core' {
|
|
214
199
|
interface Commands<ReturnType> {
|
|
215
200
|
imageUpload: {
|
|
@@ -230,6 +215,21 @@ declare module '@tiptap/core' {
|
|
|
230
215
|
}
|
|
231
216
|
|
|
232
217
|
|
|
218
|
+
declare module '@tiptap/core' {
|
|
219
|
+
interface Commands<ReturnType> {
|
|
220
|
+
iframe: {
|
|
221
|
+
/**
|
|
222
|
+
* Add an iframe
|
|
223
|
+
*/
|
|
224
|
+
setIframe: (options: {
|
|
225
|
+
src: string;
|
|
226
|
+
service: string;
|
|
227
|
+
}) => ReturnType;
|
|
228
|
+
};
|
|
229
|
+
}
|
|
230
|
+
}
|
|
231
|
+
|
|
232
|
+
|
|
233
233
|
declare module '@tiptap/core' {
|
|
234
234
|
interface Commands<ReturnType> {
|
|
235
235
|
imageGifUpload: {
|
|
@@ -268,9 +268,8 @@ declare module '@tiptap/core' {
|
|
|
268
268
|
|
|
269
269
|
declare module '@tiptap/core' {
|
|
270
270
|
interface Commands<ReturnType> {
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
unsetLineHeight: () => ReturnType;
|
|
271
|
+
katex: {
|
|
272
|
+
setKatex: (arg?: IKatexAttrs) => ReturnType;
|
|
274
273
|
};
|
|
275
274
|
}
|
|
276
275
|
}
|
|
@@ -278,8 +277,9 @@ declare module '@tiptap/core' {
|
|
|
278
277
|
|
|
279
278
|
declare module '@tiptap/core' {
|
|
280
279
|
interface Commands<ReturnType> {
|
|
281
|
-
|
|
282
|
-
|
|
280
|
+
lineHeight: {
|
|
281
|
+
setLineHeight: (lineHeight: string) => ReturnType;
|
|
282
|
+
unsetLineHeight: () => ReturnType;
|
|
283
283
|
};
|
|
284
284
|
}
|
|
285
285
|
}
|
|
@@ -295,6 +295,20 @@ declare module '@tiptap/core' {
|
|
|
295
295
|
}
|
|
296
296
|
|
|
297
297
|
|
|
298
|
+
declare module '@tiptap/core' {
|
|
299
|
+
interface Commands<ReturnType> {
|
|
300
|
+
columns: {
|
|
301
|
+
insertColumns: (attrs?: {
|
|
302
|
+
cols: number;
|
|
303
|
+
}) => ReturnType;
|
|
304
|
+
addColBefore: () => ReturnType;
|
|
305
|
+
addColAfter: () => ReturnType;
|
|
306
|
+
deleteCol: () => ReturnType;
|
|
307
|
+
};
|
|
308
|
+
}
|
|
309
|
+
}
|
|
310
|
+
|
|
311
|
+
|
|
298
312
|
declare module '@tiptap/core' {
|
|
299
313
|
interface Commands<ReturnType> {
|
|
300
314
|
search: {
|
|
@@ -310,20 +324,6 @@ declare module '@tiptap/core' {
|
|
|
310
324
|
}
|
|
311
325
|
|
|
312
326
|
|
|
313
|
-
declare module '@tiptap/core' {
|
|
314
|
-
interface Commands<ReturnType> {
|
|
315
|
-
columns: {
|
|
316
|
-
insertColumns: (attrs?: {
|
|
317
|
-
cols: number;
|
|
318
|
-
}) => ReturnType;
|
|
319
|
-
addColBefore: () => ReturnType;
|
|
320
|
-
addColAfter: () => ReturnType;
|
|
321
|
-
deleteCol: () => ReturnType;
|
|
322
|
-
};
|
|
323
|
-
}
|
|
324
|
-
}
|
|
325
|
-
|
|
326
|
-
|
|
327
327
|
declare module '@tiptap/core' {
|
|
328
328
|
interface Commands<ReturnType> {
|
|
329
329
|
tableOfContents: {
|
package/lib/CodeBlock.d.ts
CHANGED
|
@@ -131,8 +131,11 @@ declare module '@tiptap/core' {
|
|
|
131
131
|
|
|
132
132
|
declare module '@tiptap/core' {
|
|
133
133
|
interface Commands<ReturnType> {
|
|
134
|
-
|
|
135
|
-
|
|
134
|
+
emoji: {
|
|
135
|
+
setEmoji: (emoji: {
|
|
136
|
+
name: string;
|
|
137
|
+
emoji: string;
|
|
138
|
+
}) => ReturnType;
|
|
136
139
|
};
|
|
137
140
|
}
|
|
138
141
|
}
|
|
@@ -140,11 +143,8 @@ declare module '@tiptap/core' {
|
|
|
140
143
|
|
|
141
144
|
declare module '@tiptap/core' {
|
|
142
145
|
interface Commands<ReturnType> {
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
name: string;
|
|
146
|
-
emoji: string;
|
|
147
|
-
}) => ReturnType;
|
|
146
|
+
excalidraw: {
|
|
147
|
+
setExcalidraw: (attrs?: IExcalidrawAttrs) => ReturnType;
|
|
148
148
|
};
|
|
149
149
|
}
|
|
150
150
|
}
|
|
@@ -195,21 +195,6 @@ declare module '@tiptap/core' {
|
|
|
195
195
|
}
|
|
196
196
|
|
|
197
197
|
|
|
198
|
-
declare module '@tiptap/core' {
|
|
199
|
-
interface Commands<ReturnType> {
|
|
200
|
-
iframe: {
|
|
201
|
-
/**
|
|
202
|
-
* Add an iframe
|
|
203
|
-
*/
|
|
204
|
-
setIframe: (options: {
|
|
205
|
-
src: string;
|
|
206
|
-
service: string;
|
|
207
|
-
}) => ReturnType;
|
|
208
|
-
};
|
|
209
|
-
}
|
|
210
|
-
}
|
|
211
|
-
|
|
212
|
-
|
|
213
198
|
declare module '@tiptap/core' {
|
|
214
199
|
interface Commands<ReturnType> {
|
|
215
200
|
imageUpload: {
|
|
@@ -230,6 +215,21 @@ declare module '@tiptap/core' {
|
|
|
230
215
|
}
|
|
231
216
|
|
|
232
217
|
|
|
218
|
+
declare module '@tiptap/core' {
|
|
219
|
+
interface Commands<ReturnType> {
|
|
220
|
+
iframe: {
|
|
221
|
+
/**
|
|
222
|
+
* Add an iframe
|
|
223
|
+
*/
|
|
224
|
+
setIframe: (options: {
|
|
225
|
+
src: string;
|
|
226
|
+
service: string;
|
|
227
|
+
}) => ReturnType;
|
|
228
|
+
};
|
|
229
|
+
}
|
|
230
|
+
}
|
|
231
|
+
|
|
232
|
+
|
|
233
233
|
declare module '@tiptap/core' {
|
|
234
234
|
interface Commands<ReturnType> {
|
|
235
235
|
imageGifUpload: {
|
|
@@ -268,9 +268,8 @@ declare module '@tiptap/core' {
|
|
|
268
268
|
|
|
269
269
|
declare module '@tiptap/core' {
|
|
270
270
|
interface Commands<ReturnType> {
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
unsetLineHeight: () => ReturnType;
|
|
271
|
+
katex: {
|
|
272
|
+
setKatex: (arg?: IKatexAttrs) => ReturnType;
|
|
274
273
|
};
|
|
275
274
|
}
|
|
276
275
|
}
|
|
@@ -278,8 +277,9 @@ declare module '@tiptap/core' {
|
|
|
278
277
|
|
|
279
278
|
declare module '@tiptap/core' {
|
|
280
279
|
interface Commands<ReturnType> {
|
|
281
|
-
|
|
282
|
-
|
|
280
|
+
lineHeight: {
|
|
281
|
+
setLineHeight: (lineHeight: string) => ReturnType;
|
|
282
|
+
unsetLineHeight: () => ReturnType;
|
|
283
283
|
};
|
|
284
284
|
}
|
|
285
285
|
}
|
|
@@ -295,6 +295,20 @@ declare module '@tiptap/core' {
|
|
|
295
295
|
}
|
|
296
296
|
|
|
297
297
|
|
|
298
|
+
declare module '@tiptap/core' {
|
|
299
|
+
interface Commands<ReturnType> {
|
|
300
|
+
columns: {
|
|
301
|
+
insertColumns: (attrs?: {
|
|
302
|
+
cols: number;
|
|
303
|
+
}) => ReturnType;
|
|
304
|
+
addColBefore: () => ReturnType;
|
|
305
|
+
addColAfter: () => ReturnType;
|
|
306
|
+
deleteCol: () => ReturnType;
|
|
307
|
+
};
|
|
308
|
+
}
|
|
309
|
+
}
|
|
310
|
+
|
|
311
|
+
|
|
298
312
|
declare module '@tiptap/core' {
|
|
299
313
|
interface Commands<ReturnType> {
|
|
300
314
|
search: {
|
|
@@ -310,20 +324,6 @@ declare module '@tiptap/core' {
|
|
|
310
324
|
}
|
|
311
325
|
|
|
312
326
|
|
|
313
|
-
declare module '@tiptap/core' {
|
|
314
|
-
interface Commands<ReturnType> {
|
|
315
|
-
columns: {
|
|
316
|
-
insertColumns: (attrs?: {
|
|
317
|
-
cols: number;
|
|
318
|
-
}) => ReturnType;
|
|
319
|
-
addColBefore: () => ReturnType;
|
|
320
|
-
addColAfter: () => ReturnType;
|
|
321
|
-
deleteCol: () => ReturnType;
|
|
322
|
-
};
|
|
323
|
-
}
|
|
324
|
-
}
|
|
325
|
-
|
|
326
|
-
|
|
327
327
|
declare module '@tiptap/core' {
|
|
328
328
|
interface Commands<ReturnType> {
|
|
329
329
|
tableOfContents: {
|
package/lib/CodeBlock.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { N as sa, t as Gt, m as oa } from "./index-DI9T3iLd.js";
|
|
2
2
|
import { N as la, c as Le, R as ca } from "./dom-dataset-Di3tIRrR.js";
|
|
3
3
|
import { jsxs as _e, jsx as k } from "react/jsx-runtime";
|
|
4
|
-
import { d as ne, A as da, Z as ua, a3 as pa, k as xe } from "./RichTextEditor-
|
|
4
|
+
import { d as ne, A as da, Z as ua, a3 as pa, k as xe } from "./RichTextEditor-BQN2eLD_.js";
|
|
5
5
|
import * as ue from "react";
|
|
6
6
|
import { useRef as zt, useCallback as it, useEffect as Ht } from "react";
|
|
7
7
|
import * as F from "@radix-ui/react-select";
|
package/lib/CodeView.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("./index-ByRfqzMr.cjs"),c=require("./RichTextEditor-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("./index-ByRfqzMr.cjs"),c=require("./RichTextEditor-C8Sm1E6J.cjs"),s=i.Extension.create({name:"codeView",addOptions(){var e;return{...(e=this.parent)==null?void 0:e.call(this),button({editor:t,t:o}){return{component:c.ActionButton,componentProps:{action:()=>{t.commands.toggleCodeView()},isActive:()=>t.storage.codeView.isActive||!1,disabled:!1,icon:"CodeView",tooltip:o("editor.codeView.tooltip")||"View HTML Code",customClass:"tiptap-code-view-button"}}}}},addStorage(){return{isActive:!1,originalContent:""}},addCommands(){return{toggleCodeView:()=>({editor:e})=>{const t=e.storage.codeView.isActive;if(t)e.commands.setContent(e.getText());else{const o=e.getHTML();e.storage.codeView.originalContent=o;const n=o.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'");e.commands.setContent(`<div class="tiptap-code-view-wrapper">${n}</div>`)}return e.storage.codeView.isActive=!t,!0}}}});exports.CodeView=s;
|
package/lib/CodeView.d.cts
CHANGED
|
@@ -121,8 +121,11 @@ declare module '@tiptap/core' {
|
|
|
121
121
|
|
|
122
122
|
declare module '@tiptap/core' {
|
|
123
123
|
interface Commands<ReturnType> {
|
|
124
|
-
|
|
125
|
-
|
|
124
|
+
emoji: {
|
|
125
|
+
setEmoji: (emoji: {
|
|
126
|
+
name: string;
|
|
127
|
+
emoji: string;
|
|
128
|
+
}) => ReturnType;
|
|
126
129
|
};
|
|
127
130
|
}
|
|
128
131
|
}
|
|
@@ -130,11 +133,8 @@ declare module '@tiptap/core' {
|
|
|
130
133
|
|
|
131
134
|
declare module '@tiptap/core' {
|
|
132
135
|
interface Commands<ReturnType> {
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
name: string;
|
|
136
|
-
emoji: string;
|
|
137
|
-
}) => ReturnType;
|
|
136
|
+
excalidraw: {
|
|
137
|
+
setExcalidraw: (attrs?: IExcalidrawAttrs) => ReturnType;
|
|
138
138
|
};
|
|
139
139
|
}
|
|
140
140
|
}
|
|
@@ -185,21 +185,6 @@ declare module '@tiptap/core' {
|
|
|
185
185
|
}
|
|
186
186
|
|
|
187
187
|
|
|
188
|
-
declare module '@tiptap/core' {
|
|
189
|
-
interface Commands<ReturnType> {
|
|
190
|
-
iframe: {
|
|
191
|
-
/**
|
|
192
|
-
* Add an iframe
|
|
193
|
-
*/
|
|
194
|
-
setIframe: (options: {
|
|
195
|
-
src: string;
|
|
196
|
-
service: string;
|
|
197
|
-
}) => ReturnType;
|
|
198
|
-
};
|
|
199
|
-
}
|
|
200
|
-
}
|
|
201
|
-
|
|
202
|
-
|
|
203
188
|
declare module '@tiptap/core' {
|
|
204
189
|
interface Commands<ReturnType> {
|
|
205
190
|
imageUpload: {
|
|
@@ -220,6 +205,21 @@ declare module '@tiptap/core' {
|
|
|
220
205
|
}
|
|
221
206
|
|
|
222
207
|
|
|
208
|
+
declare module '@tiptap/core' {
|
|
209
|
+
interface Commands<ReturnType> {
|
|
210
|
+
iframe: {
|
|
211
|
+
/**
|
|
212
|
+
* Add an iframe
|
|
213
|
+
*/
|
|
214
|
+
setIframe: (options: {
|
|
215
|
+
src: string;
|
|
216
|
+
service: string;
|
|
217
|
+
}) => ReturnType;
|
|
218
|
+
};
|
|
219
|
+
}
|
|
220
|
+
}
|
|
221
|
+
|
|
222
|
+
|
|
223
223
|
declare module '@tiptap/core' {
|
|
224
224
|
interface Commands<ReturnType> {
|
|
225
225
|
imageGifUpload: {
|
|
@@ -258,9 +258,8 @@ declare module '@tiptap/core' {
|
|
|
258
258
|
|
|
259
259
|
declare module '@tiptap/core' {
|
|
260
260
|
interface Commands<ReturnType> {
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
unsetLineHeight: () => ReturnType;
|
|
261
|
+
katex: {
|
|
262
|
+
setKatex: (arg?: IKatexAttrs) => ReturnType;
|
|
264
263
|
};
|
|
265
264
|
}
|
|
266
265
|
}
|
|
@@ -268,8 +267,9 @@ declare module '@tiptap/core' {
|
|
|
268
267
|
|
|
269
268
|
declare module '@tiptap/core' {
|
|
270
269
|
interface Commands<ReturnType> {
|
|
271
|
-
|
|
272
|
-
|
|
270
|
+
lineHeight: {
|
|
271
|
+
setLineHeight: (lineHeight: string) => ReturnType;
|
|
272
|
+
unsetLineHeight: () => ReturnType;
|
|
273
273
|
};
|
|
274
274
|
}
|
|
275
275
|
}
|
|
@@ -285,6 +285,20 @@ declare module '@tiptap/core' {
|
|
|
285
285
|
}
|
|
286
286
|
|
|
287
287
|
|
|
288
|
+
declare module '@tiptap/core' {
|
|
289
|
+
interface Commands<ReturnType> {
|
|
290
|
+
columns: {
|
|
291
|
+
insertColumns: (attrs?: {
|
|
292
|
+
cols: number;
|
|
293
|
+
}) => ReturnType;
|
|
294
|
+
addColBefore: () => ReturnType;
|
|
295
|
+
addColAfter: () => ReturnType;
|
|
296
|
+
deleteCol: () => ReturnType;
|
|
297
|
+
};
|
|
298
|
+
}
|
|
299
|
+
}
|
|
300
|
+
|
|
301
|
+
|
|
288
302
|
declare module '@tiptap/core' {
|
|
289
303
|
interface Commands<ReturnType> {
|
|
290
304
|
search: {
|
|
@@ -300,20 +314,6 @@ declare module '@tiptap/core' {
|
|
|
300
314
|
}
|
|
301
315
|
|
|
302
316
|
|
|
303
|
-
declare module '@tiptap/core' {
|
|
304
|
-
interface Commands<ReturnType> {
|
|
305
|
-
columns: {
|
|
306
|
-
insertColumns: (attrs?: {
|
|
307
|
-
cols: number;
|
|
308
|
-
}) => ReturnType;
|
|
309
|
-
addColBefore: () => ReturnType;
|
|
310
|
-
addColAfter: () => ReturnType;
|
|
311
|
-
deleteCol: () => ReturnType;
|
|
312
|
-
};
|
|
313
|
-
}
|
|
314
|
-
}
|
|
315
|
-
|
|
316
|
-
|
|
317
317
|
declare module '@tiptap/core' {
|
|
318
318
|
interface Commands<ReturnType> {
|
|
319
319
|
tableOfContents: {
|
package/lib/CodeView.d.ts
CHANGED
|
@@ -121,8 +121,11 @@ declare module '@tiptap/core' {
|
|
|
121
121
|
|
|
122
122
|
declare module '@tiptap/core' {
|
|
123
123
|
interface Commands<ReturnType> {
|
|
124
|
-
|
|
125
|
-
|
|
124
|
+
emoji: {
|
|
125
|
+
setEmoji: (emoji: {
|
|
126
|
+
name: string;
|
|
127
|
+
emoji: string;
|
|
128
|
+
}) => ReturnType;
|
|
126
129
|
};
|
|
127
130
|
}
|
|
128
131
|
}
|
|
@@ -130,11 +133,8 @@ declare module '@tiptap/core' {
|
|
|
130
133
|
|
|
131
134
|
declare module '@tiptap/core' {
|
|
132
135
|
interface Commands<ReturnType> {
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
name: string;
|
|
136
|
-
emoji: string;
|
|
137
|
-
}) => ReturnType;
|
|
136
|
+
excalidraw: {
|
|
137
|
+
setExcalidraw: (attrs?: IExcalidrawAttrs) => ReturnType;
|
|
138
138
|
};
|
|
139
139
|
}
|
|
140
140
|
}
|
|
@@ -185,21 +185,6 @@ declare module '@tiptap/core' {
|
|
|
185
185
|
}
|
|
186
186
|
|
|
187
187
|
|
|
188
|
-
declare module '@tiptap/core' {
|
|
189
|
-
interface Commands<ReturnType> {
|
|
190
|
-
iframe: {
|
|
191
|
-
/**
|
|
192
|
-
* Add an iframe
|
|
193
|
-
*/
|
|
194
|
-
setIframe: (options: {
|
|
195
|
-
src: string;
|
|
196
|
-
service: string;
|
|
197
|
-
}) => ReturnType;
|
|
198
|
-
};
|
|
199
|
-
}
|
|
200
|
-
}
|
|
201
|
-
|
|
202
|
-
|
|
203
188
|
declare module '@tiptap/core' {
|
|
204
189
|
interface Commands<ReturnType> {
|
|
205
190
|
imageUpload: {
|
|
@@ -220,6 +205,21 @@ declare module '@tiptap/core' {
|
|
|
220
205
|
}
|
|
221
206
|
|
|
222
207
|
|
|
208
|
+
declare module '@tiptap/core' {
|
|
209
|
+
interface Commands<ReturnType> {
|
|
210
|
+
iframe: {
|
|
211
|
+
/**
|
|
212
|
+
* Add an iframe
|
|
213
|
+
*/
|
|
214
|
+
setIframe: (options: {
|
|
215
|
+
src: string;
|
|
216
|
+
service: string;
|
|
217
|
+
}) => ReturnType;
|
|
218
|
+
};
|
|
219
|
+
}
|
|
220
|
+
}
|
|
221
|
+
|
|
222
|
+
|
|
223
223
|
declare module '@tiptap/core' {
|
|
224
224
|
interface Commands<ReturnType> {
|
|
225
225
|
imageGifUpload: {
|
|
@@ -258,9 +258,8 @@ declare module '@tiptap/core' {
|
|
|
258
258
|
|
|
259
259
|
declare module '@tiptap/core' {
|
|
260
260
|
interface Commands<ReturnType> {
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
unsetLineHeight: () => ReturnType;
|
|
261
|
+
katex: {
|
|
262
|
+
setKatex: (arg?: IKatexAttrs) => ReturnType;
|
|
264
263
|
};
|
|
265
264
|
}
|
|
266
265
|
}
|
|
@@ -268,8 +267,9 @@ declare module '@tiptap/core' {
|
|
|
268
267
|
|
|
269
268
|
declare module '@tiptap/core' {
|
|
270
269
|
interface Commands<ReturnType> {
|
|
271
|
-
|
|
272
|
-
|
|
270
|
+
lineHeight: {
|
|
271
|
+
setLineHeight: (lineHeight: string) => ReturnType;
|
|
272
|
+
unsetLineHeight: () => ReturnType;
|
|
273
273
|
};
|
|
274
274
|
}
|
|
275
275
|
}
|
|
@@ -285,6 +285,20 @@ declare module '@tiptap/core' {
|
|
|
285
285
|
}
|
|
286
286
|
|
|
287
287
|
|
|
288
|
+
declare module '@tiptap/core' {
|
|
289
|
+
interface Commands<ReturnType> {
|
|
290
|
+
columns: {
|
|
291
|
+
insertColumns: (attrs?: {
|
|
292
|
+
cols: number;
|
|
293
|
+
}) => ReturnType;
|
|
294
|
+
addColBefore: () => ReturnType;
|
|
295
|
+
addColAfter: () => ReturnType;
|
|
296
|
+
deleteCol: () => ReturnType;
|
|
297
|
+
};
|
|
298
|
+
}
|
|
299
|
+
}
|
|
300
|
+
|
|
301
|
+
|
|
288
302
|
declare module '@tiptap/core' {
|
|
289
303
|
interface Commands<ReturnType> {
|
|
290
304
|
search: {
|
|
@@ -300,20 +314,6 @@ declare module '@tiptap/core' {
|
|
|
300
314
|
}
|
|
301
315
|
|
|
302
316
|
|
|
303
|
-
declare module '@tiptap/core' {
|
|
304
|
-
interface Commands<ReturnType> {
|
|
305
|
-
columns: {
|
|
306
|
-
insertColumns: (attrs?: {
|
|
307
|
-
cols: number;
|
|
308
|
-
}) => ReturnType;
|
|
309
|
-
addColBefore: () => ReturnType;
|
|
310
|
-
addColAfter: () => ReturnType;
|
|
311
|
-
deleteCol: () => ReturnType;
|
|
312
|
-
};
|
|
313
|
-
}
|
|
314
|
-
}
|
|
315
|
-
|
|
316
|
-
|
|
317
317
|
declare module '@tiptap/core' {
|
|
318
318
|
interface Commands<ReturnType> {
|
|
319
319
|
tableOfContents: {
|
package/lib/CodeView.js
CHANGED
package/lib/Color.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require("./index-DclQSrIx.cjs");const u=require("./index-ByRfqzMr.cjs"),l=require("react/jsx-runtime"),d=require("react"),i=require("./RichTextEditor-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require("./index-DclQSrIx.cjs");const u=require("./index-ByRfqzMr.cjs"),l=require("react/jsx-runtime"),d=require("react"),i=require("./RichTextEditor-C8Sm1E6J.cjs"),x=u.Extension.create({name:"color",addOptions(){return{types:["textStyle"]}},addGlobalAttributes(){return[{types:this.options.types,attributes:{color:{default:null,parseHTML:e=>{var t;return(t=e.style.color)===null||t===void 0?void 0:t.replace(/['"]+/g,"")},renderHTML:e=>e.color?{style:`color: ${e.color}`}:{}}}}]},addCommands(){return{setColor:e=>({chain:t})=>t().setMark("textStyle",{color:e}).run(),unsetColor:()=>({chain:e})=>e().setMark("textStyle",{color:null}).removeEmptyTextStyle().run()}}});function C({fill:e}){return l.jsx("svg",{width:"18px",height:"18px",viewBox:"0 0 240 240",version:"1.1",xmlns:"http://www.w3.org/2000/svg",children:l.jsx("g",{stroke:"none",strokeWidth:1,fill:"none",fillRule:"evenodd",children:l.jsx("g",{transform:"translate(0.000000, 0.500000)",children:l.jsxs("g",{transform:"translate(39.000000, 17.353553)",children:[l.jsx("path",{d:"M11,201.146447 L167,201.146447 C173.075132,201.146447 178,206.071314 178,212.146447 C178,218.221579 173.075132,223.146447 167,223.146447 L11,223.146447 C4.92486775,223.146447 7.43989126e-16,218.221579 0,212.146447 C-7.43989126e-16,206.071314 4.92486775,201.146447 11,201.146447 Z",id:"矩形",fill:e||"#DF2A3F",fillRule:"evenodd"}),l.jsx("path",{d:"M72.3425855,16.8295583 C75.799482,7.50883712 86.1577877,2.75526801 95.4785089,6.21216449 C100.284516,7.99463061 104.096358,11.7387855 105.968745,16.4968188 L106.112518,16.8745422 L159.385152,161.694068 C161.291848,166.877345 158.635655,172.624903 153.452378,174.531599 C148.358469,176.405421 142.719567,173.872338 140.716873,168.864661 L140.614848,168.598825 L89.211,28.86 L37.3759214,168.623816 C35.4885354,173.712715 29.8981043,176.351047 24.7909589,174.617647 L24.5226307,174.522368 C19.4337312,172.634982 16.7953993,167.044551 18.5287999,161.937406 L18.6240786,161.669077 L72.3425855,16.8295583 Z",id:"路径-21",fill:"currentColor",fillRule:"nonzero"}),l.jsx("path",{d:"M121,103.146447 C126.522847,103.146447 131,107.623599 131,113.146447 C131,118.575687 126.673329,122.994378 121.279905,123.142605 L121,123.146447 L55,123.146447 C49.4771525,123.146447 45,118.669294 45,113.146447 C45,107.717207 49.3266708,103.298515 54.7200952,103.150288 L55,103.146447 L121,103.146447 Z",id:"路径-22",fill:"currentColor",fillRule:"nonzero"})]})})})})}function h(e){const[t,c]=d.useState(void 0);function r(o){var a;(a=e.action)==null||a.call(e,o)}function n(){var o;(o=e.action)==null||o.call(e,t)}const s=d.useCallback(i.debounce(o=>{c(o)},350),[]);return l.jsxs("div",{className:"richtext-flex richtext-items-center richtext-h-[32px]",children:[l.jsx(i.ActionButton,{tooltip:e==null?void 0:e.tooltip,disabled:e==null?void 0:e.disabled,action:n,children:l.jsx("span",{className:"richtext-flex richtext-items-center richtext-justify-center richtext-text-sm",children:l.jsx(C,{fill:t||e.initialDisplayedColor})})}),l.jsx(i.ColorPicker,{selectedColor:t,setSelectedColor:s,onChange:r,disabled:e==null?void 0:e.disabled,colors:e==null?void 0:e.colors,defaultColor:e==null?void 0:e.defaultColor,children:l.jsx(i.Button,{variant:"ghost",size:"icon",className:"r!ichtext-h-[32px] !richtext-w-3",disabled:e==null?void 0:e.disabled,children:l.jsx(i.IconComponent,{className:"!richtext-w-3 !richtext-h-3 richtext-text-zinc-500",name:"MenuDown"})})})]})}const f=x.extend({addOptions(){var e;return{...(e=this.parent)==null?void 0:e.call(this),button({editor:t,t:c,extension:r}){return{component:h,componentProps:{colors:r.options.colors,defaultColor:r.options.defaultColor,action:n=>{n===void 0&&t.chain().focus().unsetColor().run(),typeof n=="string"&&t.chain().focus().setColor(n).run()},isActive:()=>{const{color:n}=t.getAttributes("textStyle");return n&&t.isActive({color:n})||!1},editor:t,disabled:!1,tooltip:c("editor.color.tooltip")}}}}}});exports.Color=f;
|