reactjs-tiptap-editor 0.2.6 → 0.2.7
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-Duvymqks.cjs +138 -0
- package/lib/RichTextEditor-GO6yxkq9.js +6972 -0
- package/lib/extension-bundle.cjs +1 -1
- package/lib/extension-bundle.d.cts +78 -78
- package/lib/extension-bundle.d.ts +78 -78
- package/lib/extension-bundle.js +2 -2
- package/lib/index.cjs +1 -1
- package/lib/index.d.cts +78 -78
- package/lib/index.d.ts +78 -78
- package/lib/index.js +1 -1
- package/lib/locale-bundle.d.cts +78 -78
- package/lib/locale-bundle.d.ts +78 -78
- package/lib/style.css +1 -1
- package/package.json +1 -1
- package/lib/RichTextEditor-B0-C2gAI.cjs +0 -138
- package/lib/RichTextEditor-DJXV8lHe.js +0 -6100
package/lib/index.d.cts
CHANGED
|
@@ -251,19 +251,15 @@ declare module '@tiptap/core' {
|
|
|
251
251
|
|
|
252
252
|
declare module '@tiptap/core' {
|
|
253
253
|
interface Commands<ReturnType> {
|
|
254
|
-
|
|
255
|
-
/**
|
|
256
|
-
* Add an image
|
|
257
|
-
*/
|
|
258
|
-
setImageInline: (options: Partial<SetImageAttrsOptions>) => ReturnType;
|
|
254
|
+
indent: {
|
|
259
255
|
/**
|
|
260
|
-
*
|
|
256
|
+
* Set the indent attribute
|
|
261
257
|
*/
|
|
262
|
-
|
|
258
|
+
indent: () => ReturnType;
|
|
263
259
|
/**
|
|
264
|
-
* Set
|
|
260
|
+
* Set the outdent attribute
|
|
265
261
|
*/
|
|
266
|
-
|
|
262
|
+
outdent: () => ReturnType;
|
|
267
263
|
};
|
|
268
264
|
}
|
|
269
265
|
}
|
|
@@ -281,24 +277,13 @@ declare module '@tiptap/core' {
|
|
|
281
277
|
|
|
282
278
|
declare module '@tiptap/core' {
|
|
283
279
|
interface Commands<ReturnType> {
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
*/
|
|
292
|
-
outdent: () => ReturnType;
|
|
293
|
-
};
|
|
294
|
-
}
|
|
295
|
-
}
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
declare module '@tiptap/core' {
|
|
299
|
-
interface Commands<ReturnType> {
|
|
300
|
-
katex: {
|
|
301
|
-
setKatex: (arg?: IKatexAttrs) => ReturnType;
|
|
280
|
+
columns: {
|
|
281
|
+
insertColumns: (attrs?: {
|
|
282
|
+
cols: number;
|
|
283
|
+
}) => ReturnType;
|
|
284
|
+
addColBefore: () => ReturnType;
|
|
285
|
+
addColAfter: () => ReturnType;
|
|
286
|
+
deleteCol: () => ReturnType;
|
|
302
287
|
};
|
|
303
288
|
}
|
|
304
289
|
}
|
|
@@ -306,10 +291,13 @@ declare module '@tiptap/core' {
|
|
|
306
291
|
|
|
307
292
|
declare module '@tiptap/core' {
|
|
308
293
|
interface Commands<ReturnType> {
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
294
|
+
iframe: {
|
|
295
|
+
/**
|
|
296
|
+
* Add an iframe
|
|
297
|
+
*/
|
|
298
|
+
setIframe: (options: {
|
|
299
|
+
src: string;
|
|
300
|
+
service: string;
|
|
313
301
|
}) => ReturnType;
|
|
314
302
|
};
|
|
315
303
|
}
|
|
@@ -333,8 +321,9 @@ declare module '@tiptap/core' {
|
|
|
333
321
|
|
|
334
322
|
declare module '@tiptap/core' {
|
|
335
323
|
interface Commands<ReturnType> {
|
|
336
|
-
|
|
337
|
-
|
|
324
|
+
tableCellBackground: {
|
|
325
|
+
setTableCellBackground: (color: string) => ReturnType;
|
|
326
|
+
unsetTableCellBackground: () => ReturnType;
|
|
338
327
|
};
|
|
339
328
|
}
|
|
340
329
|
}
|
|
@@ -342,14 +331,31 @@ declare module '@tiptap/core' {
|
|
|
342
331
|
|
|
343
332
|
declare module '@tiptap/core' {
|
|
344
333
|
interface Commands<ReturnType> {
|
|
345
|
-
|
|
334
|
+
emoji: {
|
|
335
|
+
setEmoji: (emoji: {
|
|
336
|
+
name: string;
|
|
337
|
+
emoji: string;
|
|
338
|
+
}) => ReturnType;
|
|
339
|
+
};
|
|
340
|
+
}
|
|
341
|
+
}
|
|
342
|
+
|
|
343
|
+
|
|
344
|
+
declare module '@tiptap/core' {
|
|
345
|
+
interface Commands<ReturnType> {
|
|
346
|
+
imageUpload: {
|
|
346
347
|
/**
|
|
347
|
-
* Add an
|
|
348
|
+
* Add an image
|
|
348
349
|
*/
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
350
|
+
setImageInline: (options: Partial<SetImageAttrsOptions>) => ReturnType;
|
|
351
|
+
/**
|
|
352
|
+
* Update an image
|
|
353
|
+
*/
|
|
354
|
+
updateImage: (options: Partial<SetImageAttrsOptions>) => ReturnType;
|
|
355
|
+
/**
|
|
356
|
+
* Set image alignment
|
|
357
|
+
*/
|
|
358
|
+
setAlignImage: (align: 'left' | 'center' | 'right') => ReturnType;
|
|
353
359
|
};
|
|
354
360
|
}
|
|
355
361
|
}
|
|
@@ -357,9 +363,8 @@ declare module '@tiptap/core' {
|
|
|
357
363
|
|
|
358
364
|
declare module '@tiptap/core' {
|
|
359
365
|
interface Commands<ReturnType> {
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
unsetTableCellBackground: () => ReturnType;
|
|
366
|
+
painter: {
|
|
367
|
+
setPainter: (marks: Mark[]) => ReturnType;
|
|
363
368
|
};
|
|
364
369
|
}
|
|
365
370
|
}
|
|
@@ -367,13 +372,8 @@ declare module '@tiptap/core' {
|
|
|
367
372
|
|
|
368
373
|
declare module '@tiptap/core' {
|
|
369
374
|
interface Commands<ReturnType> {
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
cols: number;
|
|
373
|
-
}) => ReturnType;
|
|
374
|
-
addColBefore: () => ReturnType;
|
|
375
|
-
addColAfter: () => ReturnType;
|
|
376
|
-
deleteCol: () => ReturnType;
|
|
375
|
+
katex: {
|
|
376
|
+
setKatex: (arg?: IKatexAttrs) => ReturnType;
|
|
377
377
|
};
|
|
378
378
|
}
|
|
379
379
|
}
|
|
@@ -409,9 +409,19 @@ declare module '@tiptap/core' {
|
|
|
409
409
|
|
|
410
410
|
declare module '@tiptap/core' {
|
|
411
411
|
interface Commands<ReturnType> {
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
412
|
+
imageGifUpload: {
|
|
413
|
+
/**
|
|
414
|
+
* Add an image gif
|
|
415
|
+
*/
|
|
416
|
+
setImageGif: (options: Partial<SetImageAttrsOptions>) => ReturnType;
|
|
417
|
+
/**
|
|
418
|
+
* Update an image gif
|
|
419
|
+
*/
|
|
420
|
+
updateImageGif: (options: Partial<SetImageAttrsOptions>) => ReturnType;
|
|
421
|
+
/**
|
|
422
|
+
* Set image alignment
|
|
423
|
+
*/
|
|
424
|
+
setAlignImageGif: (align: 'left' | 'center' | 'right') => ReturnType;
|
|
415
425
|
};
|
|
416
426
|
}
|
|
417
427
|
}
|
|
@@ -419,14 +429,9 @@ declare module '@tiptap/core' {
|
|
|
419
429
|
|
|
420
430
|
declare module '@tiptap/core' {
|
|
421
431
|
interface Commands<ReturnType> {
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
* @param options The tweet attributes
|
|
426
|
-
* @example editor.commands.setTweet({ src: 'https://x.com/seanpk/status/1800145949580517852' })
|
|
427
|
-
*/
|
|
428
|
-
setTweet: (options: SetTweetOptions) => ReturnType;
|
|
429
|
-
updateTweet: (options: SetTweetOptions) => ReturnType;
|
|
432
|
+
mermaid: {
|
|
433
|
+
setMermaid: (options: any, replace?: any) => ReturnType;
|
|
434
|
+
setAlignImageMermaid: (align: 'left' | 'center' | 'right') => ReturnType;
|
|
430
435
|
};
|
|
431
436
|
}
|
|
432
437
|
}
|
|
@@ -434,9 +439,8 @@ declare module '@tiptap/core' {
|
|
|
434
439
|
|
|
435
440
|
declare module '@tiptap/core' {
|
|
436
441
|
interface Commands<ReturnType> {
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
setAlignImageDrawer: (align: 'left' | 'center' | 'right') => ReturnType;
|
|
442
|
+
attachment: {
|
|
443
|
+
setAttachment: (attrs?: unknown) => ReturnType;
|
|
440
444
|
};
|
|
441
445
|
}
|
|
442
446
|
}
|
|
@@ -444,8 +448,14 @@ declare module '@tiptap/core' {
|
|
|
444
448
|
|
|
445
449
|
declare module '@tiptap/core' {
|
|
446
450
|
interface Commands<ReturnType> {
|
|
447
|
-
|
|
448
|
-
|
|
451
|
+
twitter: {
|
|
452
|
+
/**
|
|
453
|
+
* Insert a tweet
|
|
454
|
+
* @param options The tweet attributes
|
|
455
|
+
* @example editor.commands.setTweet({ src: 'https://x.com/seanpk/status/1800145949580517852' })
|
|
456
|
+
*/
|
|
457
|
+
setTweet: (options: SetTweetOptions) => ReturnType;
|
|
458
|
+
updateTweet: (options: SetTweetOptions) => ReturnType;
|
|
449
459
|
};
|
|
450
460
|
}
|
|
451
461
|
}
|
|
@@ -453,19 +463,9 @@ declare module '@tiptap/core' {
|
|
|
453
463
|
|
|
454
464
|
declare module '@tiptap/core' {
|
|
455
465
|
interface Commands<ReturnType> {
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
*/
|
|
460
|
-
setImageGif: (options: Partial<SetImageAttrsOptions>) => ReturnType;
|
|
461
|
-
/**
|
|
462
|
-
* Update an image gif
|
|
463
|
-
*/
|
|
464
|
-
updateImageGif: (options: Partial<SetImageAttrsOptions>) => ReturnType;
|
|
465
|
-
/**
|
|
466
|
-
* Set image alignment
|
|
467
|
-
*/
|
|
468
|
-
setAlignImageGif: (align: 'left' | 'center' | 'right') => ReturnType;
|
|
466
|
+
drawer: {
|
|
467
|
+
setDrawer: (options: any, replace?: any) => ReturnType;
|
|
468
|
+
setAlignImageDrawer: (align: 'left' | 'center' | 'right') => ReturnType;
|
|
469
469
|
};
|
|
470
470
|
}
|
|
471
471
|
}
|
package/lib/index.d.ts
CHANGED
|
@@ -251,19 +251,15 @@ declare module '@tiptap/core' {
|
|
|
251
251
|
|
|
252
252
|
declare module '@tiptap/core' {
|
|
253
253
|
interface Commands<ReturnType> {
|
|
254
|
-
|
|
255
|
-
/**
|
|
256
|
-
* Add an image
|
|
257
|
-
*/
|
|
258
|
-
setImageInline: (options: Partial<SetImageAttrsOptions>) => ReturnType;
|
|
254
|
+
indent: {
|
|
259
255
|
/**
|
|
260
|
-
*
|
|
256
|
+
* Set the indent attribute
|
|
261
257
|
*/
|
|
262
|
-
|
|
258
|
+
indent: () => ReturnType;
|
|
263
259
|
/**
|
|
264
|
-
* Set
|
|
260
|
+
* Set the outdent attribute
|
|
265
261
|
*/
|
|
266
|
-
|
|
262
|
+
outdent: () => ReturnType;
|
|
267
263
|
};
|
|
268
264
|
}
|
|
269
265
|
}
|
|
@@ -281,24 +277,13 @@ declare module '@tiptap/core' {
|
|
|
281
277
|
|
|
282
278
|
declare module '@tiptap/core' {
|
|
283
279
|
interface Commands<ReturnType> {
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
*/
|
|
292
|
-
outdent: () => ReturnType;
|
|
293
|
-
};
|
|
294
|
-
}
|
|
295
|
-
}
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
declare module '@tiptap/core' {
|
|
299
|
-
interface Commands<ReturnType> {
|
|
300
|
-
katex: {
|
|
301
|
-
setKatex: (arg?: IKatexAttrs) => ReturnType;
|
|
280
|
+
columns: {
|
|
281
|
+
insertColumns: (attrs?: {
|
|
282
|
+
cols: number;
|
|
283
|
+
}) => ReturnType;
|
|
284
|
+
addColBefore: () => ReturnType;
|
|
285
|
+
addColAfter: () => ReturnType;
|
|
286
|
+
deleteCol: () => ReturnType;
|
|
302
287
|
};
|
|
303
288
|
}
|
|
304
289
|
}
|
|
@@ -306,10 +291,13 @@ declare module '@tiptap/core' {
|
|
|
306
291
|
|
|
307
292
|
declare module '@tiptap/core' {
|
|
308
293
|
interface Commands<ReturnType> {
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
294
|
+
iframe: {
|
|
295
|
+
/**
|
|
296
|
+
* Add an iframe
|
|
297
|
+
*/
|
|
298
|
+
setIframe: (options: {
|
|
299
|
+
src: string;
|
|
300
|
+
service: string;
|
|
313
301
|
}) => ReturnType;
|
|
314
302
|
};
|
|
315
303
|
}
|
|
@@ -333,8 +321,9 @@ declare module '@tiptap/core' {
|
|
|
333
321
|
|
|
334
322
|
declare module '@tiptap/core' {
|
|
335
323
|
interface Commands<ReturnType> {
|
|
336
|
-
|
|
337
|
-
|
|
324
|
+
tableCellBackground: {
|
|
325
|
+
setTableCellBackground: (color: string) => ReturnType;
|
|
326
|
+
unsetTableCellBackground: () => ReturnType;
|
|
338
327
|
};
|
|
339
328
|
}
|
|
340
329
|
}
|
|
@@ -342,14 +331,31 @@ declare module '@tiptap/core' {
|
|
|
342
331
|
|
|
343
332
|
declare module '@tiptap/core' {
|
|
344
333
|
interface Commands<ReturnType> {
|
|
345
|
-
|
|
334
|
+
emoji: {
|
|
335
|
+
setEmoji: (emoji: {
|
|
336
|
+
name: string;
|
|
337
|
+
emoji: string;
|
|
338
|
+
}) => ReturnType;
|
|
339
|
+
};
|
|
340
|
+
}
|
|
341
|
+
}
|
|
342
|
+
|
|
343
|
+
|
|
344
|
+
declare module '@tiptap/core' {
|
|
345
|
+
interface Commands<ReturnType> {
|
|
346
|
+
imageUpload: {
|
|
346
347
|
/**
|
|
347
|
-
* Add an
|
|
348
|
+
* Add an image
|
|
348
349
|
*/
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
350
|
+
setImageInline: (options: Partial<SetImageAttrsOptions>) => ReturnType;
|
|
351
|
+
/**
|
|
352
|
+
* Update an image
|
|
353
|
+
*/
|
|
354
|
+
updateImage: (options: Partial<SetImageAttrsOptions>) => ReturnType;
|
|
355
|
+
/**
|
|
356
|
+
* Set image alignment
|
|
357
|
+
*/
|
|
358
|
+
setAlignImage: (align: 'left' | 'center' | 'right') => ReturnType;
|
|
353
359
|
};
|
|
354
360
|
}
|
|
355
361
|
}
|
|
@@ -357,9 +363,8 @@ declare module '@tiptap/core' {
|
|
|
357
363
|
|
|
358
364
|
declare module '@tiptap/core' {
|
|
359
365
|
interface Commands<ReturnType> {
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
unsetTableCellBackground: () => ReturnType;
|
|
366
|
+
painter: {
|
|
367
|
+
setPainter: (marks: Mark[]) => ReturnType;
|
|
363
368
|
};
|
|
364
369
|
}
|
|
365
370
|
}
|
|
@@ -367,13 +372,8 @@ declare module '@tiptap/core' {
|
|
|
367
372
|
|
|
368
373
|
declare module '@tiptap/core' {
|
|
369
374
|
interface Commands<ReturnType> {
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
cols: number;
|
|
373
|
-
}) => ReturnType;
|
|
374
|
-
addColBefore: () => ReturnType;
|
|
375
|
-
addColAfter: () => ReturnType;
|
|
376
|
-
deleteCol: () => ReturnType;
|
|
375
|
+
katex: {
|
|
376
|
+
setKatex: (arg?: IKatexAttrs) => ReturnType;
|
|
377
377
|
};
|
|
378
378
|
}
|
|
379
379
|
}
|
|
@@ -409,9 +409,19 @@ declare module '@tiptap/core' {
|
|
|
409
409
|
|
|
410
410
|
declare module '@tiptap/core' {
|
|
411
411
|
interface Commands<ReturnType> {
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
412
|
+
imageGifUpload: {
|
|
413
|
+
/**
|
|
414
|
+
* Add an image gif
|
|
415
|
+
*/
|
|
416
|
+
setImageGif: (options: Partial<SetImageAttrsOptions>) => ReturnType;
|
|
417
|
+
/**
|
|
418
|
+
* Update an image gif
|
|
419
|
+
*/
|
|
420
|
+
updateImageGif: (options: Partial<SetImageAttrsOptions>) => ReturnType;
|
|
421
|
+
/**
|
|
422
|
+
* Set image alignment
|
|
423
|
+
*/
|
|
424
|
+
setAlignImageGif: (align: 'left' | 'center' | 'right') => ReturnType;
|
|
415
425
|
};
|
|
416
426
|
}
|
|
417
427
|
}
|
|
@@ -419,14 +429,9 @@ declare module '@tiptap/core' {
|
|
|
419
429
|
|
|
420
430
|
declare module '@tiptap/core' {
|
|
421
431
|
interface Commands<ReturnType> {
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
* @param options The tweet attributes
|
|
426
|
-
* @example editor.commands.setTweet({ src: 'https://x.com/seanpk/status/1800145949580517852' })
|
|
427
|
-
*/
|
|
428
|
-
setTweet: (options: SetTweetOptions) => ReturnType;
|
|
429
|
-
updateTweet: (options: SetTweetOptions) => ReturnType;
|
|
432
|
+
mermaid: {
|
|
433
|
+
setMermaid: (options: any, replace?: any) => ReturnType;
|
|
434
|
+
setAlignImageMermaid: (align: 'left' | 'center' | 'right') => ReturnType;
|
|
430
435
|
};
|
|
431
436
|
}
|
|
432
437
|
}
|
|
@@ -434,9 +439,8 @@ declare module '@tiptap/core' {
|
|
|
434
439
|
|
|
435
440
|
declare module '@tiptap/core' {
|
|
436
441
|
interface Commands<ReturnType> {
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
setAlignImageDrawer: (align: 'left' | 'center' | 'right') => ReturnType;
|
|
442
|
+
attachment: {
|
|
443
|
+
setAttachment: (attrs?: unknown) => ReturnType;
|
|
440
444
|
};
|
|
441
445
|
}
|
|
442
446
|
}
|
|
@@ -444,8 +448,14 @@ declare module '@tiptap/core' {
|
|
|
444
448
|
|
|
445
449
|
declare module '@tiptap/core' {
|
|
446
450
|
interface Commands<ReturnType> {
|
|
447
|
-
|
|
448
|
-
|
|
451
|
+
twitter: {
|
|
452
|
+
/**
|
|
453
|
+
* Insert a tweet
|
|
454
|
+
* @param options The tweet attributes
|
|
455
|
+
* @example editor.commands.setTweet({ src: 'https://x.com/seanpk/status/1800145949580517852' })
|
|
456
|
+
*/
|
|
457
|
+
setTweet: (options: SetTweetOptions) => ReturnType;
|
|
458
|
+
updateTweet: (options: SetTweetOptions) => ReturnType;
|
|
449
459
|
};
|
|
450
460
|
}
|
|
451
461
|
}
|
|
@@ -453,19 +463,9 @@ declare module '@tiptap/core' {
|
|
|
453
463
|
|
|
454
464
|
declare module '@tiptap/core' {
|
|
455
465
|
interface Commands<ReturnType> {
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
*/
|
|
460
|
-
setImageGif: (options: Partial<SetImageAttrsOptions>) => ReturnType;
|
|
461
|
-
/**
|
|
462
|
-
* Update an image gif
|
|
463
|
-
*/
|
|
464
|
-
updateImageGif: (options: Partial<SetImageAttrsOptions>) => ReturnType;
|
|
465
|
-
/**
|
|
466
|
-
* Set image alignment
|
|
467
|
-
*/
|
|
468
|
-
setAlignImageGif: (align: 'left' | 'center' | 'right') => ReturnType;
|
|
466
|
+
drawer: {
|
|
467
|
+
setDrawer: (options: any, replace?: any) => ReturnType;
|
|
468
|
+
setAlignImageDrawer: (align: 'left' | 'center' | 'right') => ReturnType;
|
|
469
469
|
};
|
|
470
470
|
}
|
|
471
471
|
}
|
package/lib/index.js
CHANGED