@portabletext/editor 1.12.2 → 1.13.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.
- package/lib/index.d.mts +234 -14
- package/lib/index.d.ts +234 -14
- package/lib/index.esm.js +361 -81
- package/lib/index.esm.js.map +1 -1
- package/lib/index.js +364 -83
- package/lib/index.js.map +1 -1
- package/lib/index.mjs +361 -81
- package/lib/index.mjs.map +1 -1
- package/package.json +10 -7
- package/src/editor/Editable.tsx +60 -5
- package/src/editor/behavior/behavior.action.insert-break.ts +21 -24
- package/src/editor/behavior/behavior.actions.ts +125 -3
- package/src/editor/behavior/behavior.code-editor.ts +86 -0
- package/src/editor/behavior/behavior.core.block-objects.ts +34 -1
- package/src/editor/behavior/behavior.core.ts +2 -0
- package/src/editor/behavior/behavior.links.ts +2 -2
- package/src/editor/behavior/behavior.markdown.ts +1 -1
- package/src/editor/behavior/behavior.types.ts +37 -2
- package/src/editor/behavior/behavior.utils.ts +2 -2
- package/src/editor/editor-machine.ts +5 -2
- package/src/editor/plugins/createWithHotKeys.ts +2 -49
- package/src/index.ts +4 -0
- package/src/utils/is-hotkey.test.ts +112 -0
- package/src/utils/is-hotkey.ts +209 -0
package/lib/index.d.mts
CHANGED
|
@@ -149,6 +149,11 @@ export declare type BehaviorActionIntend =
|
|
|
149
149
|
children?: PortableTextTextBlock['children']
|
|
150
150
|
}
|
|
151
151
|
}
|
|
152
|
+
| {
|
|
153
|
+
type: 'move block'
|
|
154
|
+
blockPath: [KeyedSegment]
|
|
155
|
+
to: [KeyedSegment]
|
|
156
|
+
}
|
|
152
157
|
| {
|
|
153
158
|
type: 'set block'
|
|
154
159
|
paths: Array<[KeyedSegment]>
|
|
@@ -178,6 +183,12 @@ export declare type BehaviorActionIntend =
|
|
|
178
183
|
type: 'select'
|
|
179
184
|
selection: EditorSelection
|
|
180
185
|
}
|
|
186
|
+
| {
|
|
187
|
+
type: 'select previous block'
|
|
188
|
+
}
|
|
189
|
+
| {
|
|
190
|
+
type: 'select next block'
|
|
191
|
+
}
|
|
181
192
|
| {
|
|
182
193
|
type: 'reselect'
|
|
183
194
|
}
|
|
@@ -197,7 +208,13 @@ export declare type BehaviorActionIntendSet<
|
|
|
197
208
|
event: PickFromUnion<BehaviorEvent, 'type', TBehaviorEventType>
|
|
198
209
|
},
|
|
199
210
|
guardResponse: TGuardResponse,
|
|
200
|
-
) => Array<
|
|
211
|
+
) => Array<
|
|
212
|
+
OmitFromUnion<
|
|
213
|
+
BehaviorActionIntend,
|
|
214
|
+
'type',
|
|
215
|
+
'copy' | 'key.down' | 'key.up' | 'paste'
|
|
216
|
+
>
|
|
217
|
+
>
|
|
201
218
|
|
|
202
219
|
/**
|
|
203
220
|
* @alpha
|
|
@@ -236,6 +253,10 @@ export declare type BehaviorEvent =
|
|
|
236
253
|
}
|
|
237
254
|
}
|
|
238
255
|
}
|
|
256
|
+
| {
|
|
257
|
+
type: 'copy'
|
|
258
|
+
data: DataTransfer
|
|
259
|
+
}
|
|
239
260
|
| {
|
|
240
261
|
type: 'decorator.add'
|
|
241
262
|
decorator: string
|
|
@@ -272,7 +293,21 @@ export declare type BehaviorEvent =
|
|
|
272
293
|
}
|
|
273
294
|
| {
|
|
274
295
|
type: 'paste'
|
|
275
|
-
|
|
296
|
+
data: DataTransfer
|
|
297
|
+
}
|
|
298
|
+
| {
|
|
299
|
+
type: 'key.down'
|
|
300
|
+
keyboardEvent: Pick<
|
|
301
|
+
KeyboardEvent,
|
|
302
|
+
'key' | 'code' | 'altKey' | 'ctrlKey' | 'metaKey' | 'shiftKey'
|
|
303
|
+
>
|
|
304
|
+
}
|
|
305
|
+
| {
|
|
306
|
+
type: 'key.up'
|
|
307
|
+
keyboardEvent: Pick<
|
|
308
|
+
KeyboardEvent,
|
|
309
|
+
'key' | 'code' | 'altKey' | 'ctrlKey' | 'metaKey' | 'shiftKey'
|
|
310
|
+
>
|
|
276
311
|
}
|
|
277
312
|
|
|
278
313
|
/**
|
|
@@ -387,6 +422,14 @@ export declare type BlurChange = {
|
|
|
387
422
|
event: FocusEvent_2<HTMLDivElement, Element>
|
|
388
423
|
}
|
|
389
424
|
|
|
425
|
+
/**
|
|
426
|
+
* @alpha
|
|
427
|
+
*/
|
|
428
|
+
export declare type CodeEditorBehaviorsConfig = {
|
|
429
|
+
moveBlockUpShortcut: string
|
|
430
|
+
moveBlockDownShortcut: string
|
|
431
|
+
}
|
|
432
|
+
|
|
390
433
|
/**
|
|
391
434
|
* The editor was either connected or disconnected to the network
|
|
392
435
|
* To show out of sync warnings etc when in collaborative mode.
|
|
@@ -405,6 +448,7 @@ export declare const coreBehavior: {
|
|
|
405
448
|
| 'annotation.add'
|
|
406
449
|
| 'annotation.remove'
|
|
407
450
|
| 'annotation.toggle'
|
|
451
|
+
| 'copy'
|
|
408
452
|
| 'decorator.add'
|
|
409
453
|
| 'decorator.remove'
|
|
410
454
|
| 'decorator.toggle'
|
|
@@ -413,7 +457,9 @@ export declare const coreBehavior: {
|
|
|
413
457
|
| 'insert soft break'
|
|
414
458
|
| 'insert break'
|
|
415
459
|
| 'insert text'
|
|
416
|
-
| 'paste'
|
|
460
|
+
| 'paste'
|
|
461
|
+
| 'key.down'
|
|
462
|
+
| 'key.up',
|
|
417
463
|
true
|
|
418
464
|
>
|
|
419
465
|
decorators: {
|
|
@@ -422,6 +468,7 @@ export declare const coreBehavior: {
|
|
|
422
468
|
| 'annotation.add'
|
|
423
469
|
| 'annotation.remove'
|
|
424
470
|
| 'annotation.toggle'
|
|
471
|
+
| 'copy'
|
|
425
472
|
| 'decorator.add'
|
|
426
473
|
| 'decorator.remove'
|
|
427
474
|
| 'decorator.toggle'
|
|
@@ -430,7 +477,9 @@ export declare const coreBehavior: {
|
|
|
430
477
|
| 'insert soft break'
|
|
431
478
|
| 'insert break'
|
|
432
479
|
| 'insert text'
|
|
433
|
-
| 'paste'
|
|
480
|
+
| 'paste'
|
|
481
|
+
| 'key.down'
|
|
482
|
+
| 'key.up',
|
|
434
483
|
true
|
|
435
484
|
>
|
|
436
485
|
decoratorRemove: Behavior<
|
|
@@ -438,6 +487,7 @@ export declare const coreBehavior: {
|
|
|
438
487
|
| 'annotation.add'
|
|
439
488
|
| 'annotation.remove'
|
|
440
489
|
| 'annotation.toggle'
|
|
490
|
+
| 'copy'
|
|
441
491
|
| 'decorator.add'
|
|
442
492
|
| 'decorator.remove'
|
|
443
493
|
| 'decorator.toggle'
|
|
@@ -446,7 +496,9 @@ export declare const coreBehavior: {
|
|
|
446
496
|
| 'insert soft break'
|
|
447
497
|
| 'insert break'
|
|
448
498
|
| 'insert text'
|
|
449
|
-
| 'paste'
|
|
499
|
+
| 'paste'
|
|
500
|
+
| 'key.down'
|
|
501
|
+
| 'key.up',
|
|
450
502
|
true
|
|
451
503
|
>
|
|
452
504
|
decoratorToggle: Behavior<
|
|
@@ -454,6 +506,7 @@ export declare const coreBehavior: {
|
|
|
454
506
|
| 'annotation.add'
|
|
455
507
|
| 'annotation.remove'
|
|
456
508
|
| 'annotation.toggle'
|
|
509
|
+
| 'copy'
|
|
457
510
|
| 'decorator.add'
|
|
458
511
|
| 'decorator.remove'
|
|
459
512
|
| 'decorator.toggle'
|
|
@@ -462,16 +515,57 @@ export declare const coreBehavior: {
|
|
|
462
515
|
| 'insert soft break'
|
|
463
516
|
| 'insert break'
|
|
464
517
|
| 'insert text'
|
|
465
|
-
| 'paste'
|
|
518
|
+
| 'paste'
|
|
519
|
+
| 'key.down'
|
|
520
|
+
| 'key.up',
|
|
466
521
|
true
|
|
467
522
|
>
|
|
468
523
|
}
|
|
469
524
|
blockObjects: {
|
|
525
|
+
arrowDownOnLonelyBlockObject: Behavior<
|
|
526
|
+
| 'focus'
|
|
527
|
+
| 'annotation.add'
|
|
528
|
+
| 'annotation.remove'
|
|
529
|
+
| 'annotation.toggle'
|
|
530
|
+
| 'copy'
|
|
531
|
+
| 'decorator.add'
|
|
532
|
+
| 'decorator.remove'
|
|
533
|
+
| 'decorator.toggle'
|
|
534
|
+
| 'delete backward'
|
|
535
|
+
| 'delete forward'
|
|
536
|
+
| 'insert soft break'
|
|
537
|
+
| 'insert break'
|
|
538
|
+
| 'insert text'
|
|
539
|
+
| 'paste'
|
|
540
|
+
| 'key.down'
|
|
541
|
+
| 'key.up',
|
|
542
|
+
true
|
|
543
|
+
>
|
|
544
|
+
arrowUpOnLonelyBlockObject: Behavior<
|
|
545
|
+
| 'focus'
|
|
546
|
+
| 'annotation.add'
|
|
547
|
+
| 'annotation.remove'
|
|
548
|
+
| 'annotation.toggle'
|
|
549
|
+
| 'copy'
|
|
550
|
+
| 'decorator.add'
|
|
551
|
+
| 'decorator.remove'
|
|
552
|
+
| 'decorator.toggle'
|
|
553
|
+
| 'delete backward'
|
|
554
|
+
| 'delete forward'
|
|
555
|
+
| 'insert soft break'
|
|
556
|
+
| 'insert break'
|
|
557
|
+
| 'insert text'
|
|
558
|
+
| 'paste'
|
|
559
|
+
| 'key.down'
|
|
560
|
+
| 'key.up',
|
|
561
|
+
true
|
|
562
|
+
>
|
|
470
563
|
breakingBlockObject: Behavior<
|
|
471
564
|
| 'focus'
|
|
472
565
|
| 'annotation.add'
|
|
473
566
|
| 'annotation.remove'
|
|
474
567
|
| 'annotation.toggle'
|
|
568
|
+
| 'copy'
|
|
475
569
|
| 'decorator.add'
|
|
476
570
|
| 'decorator.remove'
|
|
477
571
|
| 'decorator.toggle'
|
|
@@ -480,7 +574,9 @@ export declare const coreBehavior: {
|
|
|
480
574
|
| 'insert soft break'
|
|
481
575
|
| 'insert break'
|
|
482
576
|
| 'insert text'
|
|
483
|
-
| 'paste'
|
|
577
|
+
| 'paste'
|
|
578
|
+
| 'key.down'
|
|
579
|
+
| 'key.up',
|
|
484
580
|
true
|
|
485
581
|
>
|
|
486
582
|
deletingEmptyTextBlockAfterBlockObject: Behavior<
|
|
@@ -488,6 +584,7 @@ export declare const coreBehavior: {
|
|
|
488
584
|
| 'annotation.add'
|
|
489
585
|
| 'annotation.remove'
|
|
490
586
|
| 'annotation.toggle'
|
|
587
|
+
| 'copy'
|
|
491
588
|
| 'decorator.add'
|
|
492
589
|
| 'decorator.remove'
|
|
493
590
|
| 'decorator.toggle'
|
|
@@ -496,7 +593,9 @@ export declare const coreBehavior: {
|
|
|
496
593
|
| 'insert soft break'
|
|
497
594
|
| 'insert break'
|
|
498
595
|
| 'insert text'
|
|
499
|
-
| 'paste'
|
|
596
|
+
| 'paste'
|
|
597
|
+
| 'key.down'
|
|
598
|
+
| 'key.up',
|
|
500
599
|
true
|
|
501
600
|
>
|
|
502
601
|
deletingEmptyTextBlockBeforeBlockObject: Behavior<
|
|
@@ -504,6 +603,7 @@ export declare const coreBehavior: {
|
|
|
504
603
|
| 'annotation.add'
|
|
505
604
|
| 'annotation.remove'
|
|
506
605
|
| 'annotation.toggle'
|
|
606
|
+
| 'copy'
|
|
507
607
|
| 'decorator.add'
|
|
508
608
|
| 'decorator.remove'
|
|
509
609
|
| 'decorator.toggle'
|
|
@@ -512,7 +612,9 @@ export declare const coreBehavior: {
|
|
|
512
612
|
| 'insert soft break'
|
|
513
613
|
| 'insert break'
|
|
514
614
|
| 'insert text'
|
|
515
|
-
| 'paste'
|
|
615
|
+
| 'paste'
|
|
616
|
+
| 'key.down'
|
|
617
|
+
| 'key.up',
|
|
516
618
|
true
|
|
517
619
|
>
|
|
518
620
|
}
|
|
@@ -522,6 +624,7 @@ export declare const coreBehavior: {
|
|
|
522
624
|
| 'annotation.add'
|
|
523
625
|
| 'annotation.remove'
|
|
524
626
|
| 'annotation.toggle'
|
|
627
|
+
| 'copy'
|
|
525
628
|
| 'decorator.add'
|
|
526
629
|
| 'decorator.remove'
|
|
527
630
|
| 'decorator.toggle'
|
|
@@ -530,7 +633,9 @@ export declare const coreBehavior: {
|
|
|
530
633
|
| 'insert soft break'
|
|
531
634
|
| 'insert break'
|
|
532
635
|
| 'insert text'
|
|
533
|
-
| 'paste'
|
|
636
|
+
| 'paste'
|
|
637
|
+
| 'key.down'
|
|
638
|
+
| 'key.up',
|
|
534
639
|
true
|
|
535
640
|
>
|
|
536
641
|
unindentListOnBackspace: Behavior<
|
|
@@ -538,6 +643,7 @@ export declare const coreBehavior: {
|
|
|
538
643
|
| 'annotation.add'
|
|
539
644
|
| 'annotation.remove'
|
|
540
645
|
| 'annotation.toggle'
|
|
646
|
+
| 'copy'
|
|
541
647
|
| 'decorator.add'
|
|
542
648
|
| 'decorator.remove'
|
|
543
649
|
| 'decorator.toggle'
|
|
@@ -546,7 +652,9 @@ export declare const coreBehavior: {
|
|
|
546
652
|
| 'insert soft break'
|
|
547
653
|
| 'insert break'
|
|
548
654
|
| 'insert text'
|
|
549
|
-
| 'paste'
|
|
655
|
+
| 'paste'
|
|
656
|
+
| 'key.down'
|
|
657
|
+
| 'key.up',
|
|
550
658
|
true
|
|
551
659
|
>
|
|
552
660
|
}
|
|
@@ -560,6 +668,32 @@ export declare const coreBehaviors: Behavior<
|
|
|
560
668
|
| 'annotation.add'
|
|
561
669
|
| 'annotation.remove'
|
|
562
670
|
| 'annotation.toggle'
|
|
671
|
+
| 'copy'
|
|
672
|
+
| 'decorator.add'
|
|
673
|
+
| 'decorator.remove'
|
|
674
|
+
| 'decorator.toggle'
|
|
675
|
+
| 'delete backward'
|
|
676
|
+
| 'delete forward'
|
|
677
|
+
| 'insert soft break'
|
|
678
|
+
| 'insert break'
|
|
679
|
+
| 'insert text'
|
|
680
|
+
| 'paste'
|
|
681
|
+
| 'key.down'
|
|
682
|
+
| 'key.up',
|
|
683
|
+
true
|
|
684
|
+
>[]
|
|
685
|
+
|
|
686
|
+
/**
|
|
687
|
+
* @alpha
|
|
688
|
+
*/
|
|
689
|
+
export declare function createCodeEditorBehaviors(
|
|
690
|
+
config: CodeEditorBehaviorsConfig,
|
|
691
|
+
): Behavior<
|
|
692
|
+
| 'focus'
|
|
693
|
+
| 'annotation.add'
|
|
694
|
+
| 'annotation.remove'
|
|
695
|
+
| 'annotation.toggle'
|
|
696
|
+
| 'copy'
|
|
563
697
|
| 'decorator.add'
|
|
564
698
|
| 'decorator.remove'
|
|
565
699
|
| 'decorator.toggle'
|
|
@@ -568,7 +702,9 @@ export declare const coreBehaviors: Behavior<
|
|
|
568
702
|
| 'insert soft break'
|
|
569
703
|
| 'insert break'
|
|
570
704
|
| 'insert text'
|
|
571
|
-
| 'paste'
|
|
705
|
+
| 'paste'
|
|
706
|
+
| 'key.down'
|
|
707
|
+
| 'key.up',
|
|
572
708
|
true
|
|
573
709
|
>[]
|
|
574
710
|
|
|
@@ -582,6 +718,7 @@ export declare function createLinkBehaviors(
|
|
|
582
718
|
| 'annotation.add'
|
|
583
719
|
| 'annotation.remove'
|
|
584
720
|
| 'annotation.toggle'
|
|
721
|
+
| 'copy'
|
|
585
722
|
| 'decorator.add'
|
|
586
723
|
| 'decorator.remove'
|
|
587
724
|
| 'decorator.toggle'
|
|
@@ -590,7 +727,9 @@ export declare function createLinkBehaviors(
|
|
|
590
727
|
| 'insert soft break'
|
|
591
728
|
| 'insert break'
|
|
592
729
|
| 'insert text'
|
|
593
|
-
| 'paste'
|
|
730
|
+
| 'paste'
|
|
731
|
+
| 'key.down'
|
|
732
|
+
| 'key.up',
|
|
594
733
|
true
|
|
595
734
|
>[]
|
|
596
735
|
|
|
@@ -604,6 +743,7 @@ export declare function createMarkdownBehaviors(
|
|
|
604
743
|
| 'annotation.add'
|
|
605
744
|
| 'annotation.remove'
|
|
606
745
|
| 'annotation.toggle'
|
|
746
|
+
| 'copy'
|
|
607
747
|
| 'decorator.add'
|
|
608
748
|
| 'decorator.remove'
|
|
609
749
|
| 'decorator.toggle'
|
|
@@ -612,7 +752,9 @@ export declare function createMarkdownBehaviors(
|
|
|
612
752
|
| 'insert soft break'
|
|
613
753
|
| 'insert break'
|
|
614
754
|
| 'insert text'
|
|
615
|
-
| 'paste'
|
|
755
|
+
| 'paste'
|
|
756
|
+
| 'key.down'
|
|
757
|
+
| 'key.up',
|
|
616
758
|
true
|
|
617
759
|
>[]
|
|
618
760
|
|
|
@@ -875,6 +1017,9 @@ export declare const editorMachine: StateMachine<
|
|
|
875
1017
|
type: 'behavior event'
|
|
876
1018
|
behaviorEvent: BehaviorEvent
|
|
877
1019
|
editor: PortableTextSlateEditor
|
|
1020
|
+
nativeEvent?: {
|
|
1021
|
+
preventDefault: () => void
|
|
1022
|
+
}
|
|
878
1023
|
}
|
|
879
1024
|
| {
|
|
880
1025
|
type: 'behavior action intends'
|
|
@@ -1148,6 +1293,9 @@ export declare const editorMachine: StateMachine<
|
|
|
1148
1293
|
type: 'behavior event'
|
|
1149
1294
|
behaviorEvent: BehaviorEvent
|
|
1150
1295
|
editor: PortableTextSlateEditor
|
|
1296
|
+
nativeEvent?: {
|
|
1297
|
+
preventDefault: () => void
|
|
1298
|
+
}
|
|
1151
1299
|
}
|
|
1152
1300
|
| {
|
|
1153
1301
|
type: 'behavior action intends'
|
|
@@ -1260,6 +1408,9 @@ export declare const editorMachine: StateMachine<
|
|
|
1260
1408
|
type: 'behavior event'
|
|
1261
1409
|
behaviorEvent: BehaviorEvent
|
|
1262
1410
|
editor: PortableTextSlateEditor
|
|
1411
|
+
nativeEvent?: {
|
|
1412
|
+
preventDefault: () => void
|
|
1413
|
+
}
|
|
1263
1414
|
}
|
|
1264
1415
|
| {
|
|
1265
1416
|
type: 'behavior action intends'
|
|
@@ -1397,6 +1548,9 @@ export declare const editorMachine: StateMachine<
|
|
|
1397
1548
|
type: 'behavior event'
|
|
1398
1549
|
behaviorEvent: BehaviorEvent
|
|
1399
1550
|
editor: PortableTextSlateEditor
|
|
1551
|
+
nativeEvent?: {
|
|
1552
|
+
preventDefault: () => void
|
|
1553
|
+
}
|
|
1400
1554
|
}
|
|
1401
1555
|
| {
|
|
1402
1556
|
type: 'behavior action intends'
|
|
@@ -1622,6 +1776,9 @@ export declare const editorMachine: StateMachine<
|
|
|
1622
1776
|
type: 'behavior event'
|
|
1623
1777
|
behaviorEvent: BehaviorEvent
|
|
1624
1778
|
editor: PortableTextSlateEditor
|
|
1779
|
+
nativeEvent?: {
|
|
1780
|
+
preventDefault: () => void
|
|
1781
|
+
}
|
|
1625
1782
|
}
|
|
1626
1783
|
| {
|
|
1627
1784
|
type: 'behavior action intends'
|
|
@@ -1847,6 +2004,9 @@ export declare const editorMachine: StateMachine<
|
|
|
1847
2004
|
type: 'behavior event'
|
|
1848
2005
|
behaviorEvent: BehaviorEvent
|
|
1849
2006
|
editor: PortableTextSlateEditor
|
|
2007
|
+
nativeEvent?: {
|
|
2008
|
+
preventDefault: () => void
|
|
2009
|
+
}
|
|
1850
2010
|
}
|
|
1851
2011
|
| {
|
|
1852
2012
|
type: 'behavior action intends'
|
|
@@ -2069,6 +2229,9 @@ export declare const editorMachine: StateMachine<
|
|
|
2069
2229
|
type: 'behavior event'
|
|
2070
2230
|
behaviorEvent: BehaviorEvent
|
|
2071
2231
|
editor: PortableTextSlateEditor
|
|
2232
|
+
nativeEvent?: {
|
|
2233
|
+
preventDefault: () => void
|
|
2234
|
+
}
|
|
2072
2235
|
}
|
|
2073
2236
|
| {
|
|
2074
2237
|
type: 'behavior action intends'
|
|
@@ -2285,6 +2448,9 @@ export declare const editorMachine: StateMachine<
|
|
|
2285
2448
|
type: 'behavior event'
|
|
2286
2449
|
behaviorEvent: BehaviorEvent
|
|
2287
2450
|
editor: PortableTextSlateEditor
|
|
2451
|
+
nativeEvent?: {
|
|
2452
|
+
preventDefault: () => void
|
|
2453
|
+
}
|
|
2288
2454
|
}
|
|
2289
2455
|
| {
|
|
2290
2456
|
type: 'behavior action intends'
|
|
@@ -2486,6 +2652,9 @@ export declare const editorMachine: StateMachine<
|
|
|
2486
2652
|
type: 'behavior event'
|
|
2487
2653
|
behaviorEvent: BehaviorEvent
|
|
2488
2654
|
editor: PortableTextSlateEditor
|
|
2655
|
+
nativeEvent?: {
|
|
2656
|
+
preventDefault: () => void
|
|
2657
|
+
}
|
|
2489
2658
|
}
|
|
2490
2659
|
| {
|
|
2491
2660
|
type: 'behavior action intends'
|
|
@@ -2687,6 +2856,9 @@ export declare const editorMachine: StateMachine<
|
|
|
2687
2856
|
type: 'behavior event'
|
|
2688
2857
|
behaviorEvent: BehaviorEvent
|
|
2689
2858
|
editor: PortableTextSlateEditor
|
|
2859
|
+
nativeEvent?: {
|
|
2860
|
+
preventDefault: () => void
|
|
2861
|
+
}
|
|
2690
2862
|
}
|
|
2691
2863
|
| {
|
|
2692
2864
|
type: 'behavior action intends'
|
|
@@ -2889,6 +3061,9 @@ export declare const editorMachine: StateMachine<
|
|
|
2889
3061
|
type: 'behavior event'
|
|
2890
3062
|
behaviorEvent: BehaviorEvent
|
|
2891
3063
|
editor: PortableTextSlateEditor
|
|
3064
|
+
nativeEvent?: {
|
|
3065
|
+
preventDefault: () => void
|
|
3066
|
+
}
|
|
2892
3067
|
}
|
|
2893
3068
|
| {
|
|
2894
3069
|
type: 'behavior action intends'
|
|
@@ -3092,6 +3267,9 @@ export declare const editorMachine: StateMachine<
|
|
|
3092
3267
|
type: 'behavior event'
|
|
3093
3268
|
behaviorEvent: BehaviorEvent
|
|
3094
3269
|
editor: PortableTextSlateEditor
|
|
3270
|
+
nativeEvent?: {
|
|
3271
|
+
preventDefault: () => void
|
|
3272
|
+
}
|
|
3095
3273
|
}
|
|
3096
3274
|
| {
|
|
3097
3275
|
type: 'behavior action intends'
|
|
@@ -3293,6 +3471,9 @@ export declare const editorMachine: StateMachine<
|
|
|
3293
3471
|
type: 'behavior event'
|
|
3294
3472
|
behaviorEvent: BehaviorEvent
|
|
3295
3473
|
editor: PortableTextSlateEditor
|
|
3474
|
+
nativeEvent?: {
|
|
3475
|
+
preventDefault: () => void
|
|
3476
|
+
}
|
|
3296
3477
|
}
|
|
3297
3478
|
| {
|
|
3298
3479
|
type: 'behavior action intends'
|
|
@@ -3494,6 +3675,9 @@ export declare const editorMachine: StateMachine<
|
|
|
3494
3675
|
type: 'behavior event'
|
|
3495
3676
|
behaviorEvent: BehaviorEvent
|
|
3496
3677
|
editor: PortableTextSlateEditor
|
|
3678
|
+
nativeEvent?: {
|
|
3679
|
+
preventDefault: () => void
|
|
3680
|
+
}
|
|
3497
3681
|
}
|
|
3498
3682
|
| {
|
|
3499
3683
|
type: 'behavior action intends'
|
|
@@ -3695,6 +3879,9 @@ export declare const editorMachine: StateMachine<
|
|
|
3695
3879
|
type: 'behavior event'
|
|
3696
3880
|
behaviorEvent: BehaviorEvent
|
|
3697
3881
|
editor: PortableTextSlateEditor
|
|
3882
|
+
nativeEvent?: {
|
|
3883
|
+
preventDefault: () => void
|
|
3884
|
+
}
|
|
3698
3885
|
}
|
|
3699
3886
|
| {
|
|
3700
3887
|
type: 'behavior action intends'
|
|
@@ -3895,6 +4082,9 @@ export declare const editorMachine: StateMachine<
|
|
|
3895
4082
|
type: 'behavior event'
|
|
3896
4083
|
behaviorEvent: BehaviorEvent
|
|
3897
4084
|
editor: PortableTextSlateEditor
|
|
4085
|
+
nativeEvent?: {
|
|
4086
|
+
preventDefault: () => void
|
|
4087
|
+
}
|
|
3898
4088
|
}
|
|
3899
4089
|
| {
|
|
3900
4090
|
type: 'behavior action intends'
|
|
@@ -4093,6 +4283,9 @@ export declare const editorMachine: StateMachine<
|
|
|
4093
4283
|
type: 'behavior event'
|
|
4094
4284
|
behaviorEvent: BehaviorEvent
|
|
4095
4285
|
editor: PortableTextSlateEditor
|
|
4286
|
+
nativeEvent?: {
|
|
4287
|
+
preventDefault: () => void
|
|
4288
|
+
}
|
|
4096
4289
|
}
|
|
4097
4290
|
| {
|
|
4098
4291
|
type: 'behavior action intends'
|
|
@@ -4293,6 +4486,9 @@ export declare const editorMachine: StateMachine<
|
|
|
4293
4486
|
type: 'behavior event'
|
|
4294
4487
|
behaviorEvent: BehaviorEvent
|
|
4295
4488
|
editor: PortableTextSlateEditor
|
|
4489
|
+
nativeEvent?: {
|
|
4490
|
+
preventDefault: () => void
|
|
4491
|
+
}
|
|
4296
4492
|
}
|
|
4297
4493
|
| {
|
|
4298
4494
|
type: 'behavior action intends'
|
|
@@ -4500,6 +4696,9 @@ export declare const editorMachine: StateMachine<
|
|
|
4500
4696
|
type: 'behavior event'
|
|
4501
4697
|
behaviorEvent: BehaviorEvent
|
|
4502
4698
|
editor: PortableTextSlateEditor
|
|
4699
|
+
nativeEvent?: {
|
|
4700
|
+
preventDefault: () => void
|
|
4701
|
+
}
|
|
4503
4702
|
}
|
|
4504
4703
|
| {
|
|
4505
4704
|
type: 'behavior action intends'
|
|
@@ -4628,6 +4827,9 @@ export declare const editorMachine: StateMachine<
|
|
|
4628
4827
|
type: 'behavior event'
|
|
4629
4828
|
behaviorEvent: BehaviorEvent
|
|
4630
4829
|
editor: PortableTextSlateEditor
|
|
4830
|
+
nativeEvent?: {
|
|
4831
|
+
preventDefault: () => void
|
|
4832
|
+
}
|
|
4631
4833
|
}
|
|
4632
4834
|
| {
|
|
4633
4835
|
type: 'behavior action intends'
|
|
@@ -4753,6 +4955,9 @@ export declare const editorMachine: StateMachine<
|
|
|
4753
4955
|
type: 'behavior event'
|
|
4754
4956
|
behaviorEvent: BehaviorEvent
|
|
4755
4957
|
editor: PortableTextSlateEditor
|
|
4958
|
+
nativeEvent?: {
|
|
4959
|
+
preventDefault: () => void
|
|
4960
|
+
}
|
|
4756
4961
|
}
|
|
4757
4962
|
| {
|
|
4758
4963
|
type: 'behavior action intends'
|
|
@@ -4955,6 +5160,9 @@ export declare const editorMachine: StateMachine<
|
|
|
4955
5160
|
type: 'behavior event'
|
|
4956
5161
|
behaviorEvent: BehaviorEvent
|
|
4957
5162
|
editor: PortableTextSlateEditor
|
|
5163
|
+
nativeEvent?: {
|
|
5164
|
+
preventDefault: () => void
|
|
5165
|
+
}
|
|
4958
5166
|
}
|
|
4959
5167
|
| {
|
|
4960
5168
|
type: 'behavior action intends'
|
|
@@ -5047,6 +5255,9 @@ export declare const editorMachine: StateMachine<
|
|
|
5047
5255
|
type: 'behavior event'
|
|
5048
5256
|
behaviorEvent: BehaviorEvent
|
|
5049
5257
|
editor: PortableTextSlateEditor
|
|
5258
|
+
nativeEvent?: {
|
|
5259
|
+
preventDefault: () => void
|
|
5260
|
+
}
|
|
5050
5261
|
}
|
|
5051
5262
|
>) => boolean
|
|
5052
5263
|
}
|
|
@@ -5109,6 +5320,9 @@ export declare const editorMachine: StateMachine<
|
|
|
5109
5320
|
type: 'behavior event'
|
|
5110
5321
|
behaviorEvent: BehaviorEvent
|
|
5111
5322
|
editor: PortableTextSlateEditor
|
|
5323
|
+
nativeEvent?: {
|
|
5324
|
+
preventDefault: () => void
|
|
5325
|
+
}
|
|
5112
5326
|
}
|
|
5113
5327
|
| {
|
|
5114
5328
|
type: 'behavior action intends'
|
|
@@ -5230,6 +5444,9 @@ export declare const editorMachine: StateMachine<
|
|
|
5230
5444
|
type: 'behavior event'
|
|
5231
5445
|
behaviorEvent: BehaviorEvent
|
|
5232
5446
|
editor: PortableTextSlateEditor
|
|
5447
|
+
nativeEvent?: {
|
|
5448
|
+
preventDefault: () => void
|
|
5449
|
+
}
|
|
5233
5450
|
}
|
|
5234
5451
|
| {
|
|
5235
5452
|
type: 'behavior action intends'
|
|
@@ -5610,6 +5827,9 @@ export declare type InternalEditorEvent =
|
|
|
5610
5827
|
type: 'behavior event'
|
|
5611
5828
|
behaviorEvent: BehaviorEvent
|
|
5612
5829
|
editor: PortableTextSlateEditor
|
|
5830
|
+
nativeEvent?: {
|
|
5831
|
+
preventDefault: () => void
|
|
5832
|
+
}
|
|
5613
5833
|
}
|
|
5614
5834
|
| {
|
|
5615
5835
|
type: 'behavior action intends'
|