@portabletext/editor 1.49.7 → 1.49.8
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/behaviors/index.d.cts +24 -272
- package/lib/behaviors/index.d.ts +24 -272
- package/lib/index.cjs +3049 -3097
- package/lib/index.cjs.map +1 -1
- package/lib/index.d.cts +31 -277
- package/lib/index.d.ts +31 -277
- package/lib/index.js +3127 -3175
- package/lib/index.js.map +1 -1
- package/lib/plugins/index.d.cts +31 -277
- package/lib/plugins/index.d.ts +31 -277
- package/lib/selectors/index.d.cts +24 -272
- package/lib/selectors/index.d.ts +24 -272
- package/lib/utils/index.d.cts +24 -272
- package/lib/utils/index.d.ts +24 -272
- package/package.json +1 -1
- package/src/editor/PortableTextEditor.tsx +12 -101
- package/src/editor/create-editor.ts +132 -2
- package/src/editor/editor-machine.ts +2 -9
- package/src/editor/editor-provider.tsx +1 -6
- package/src/editor/route-events-to-changes.tsx +81 -0
- package/src/editor/sync-machine.ts +31 -0
- package/src/editor.ts +7 -1
- package/src/internal-utils/text-selection.ts +3 -1
- package/src/editor/__tests__/pteWarningsSelfSolving.test.tsx +0 -364
- package/src/editor/components/Synchronizer.tsx +0 -134
|
@@ -620,7 +620,7 @@ declare const editorMachine: StateMachine<
|
|
|
620
620
|
initialReadOnly: boolean
|
|
621
621
|
maxBlocks: number | undefined
|
|
622
622
|
selection: EditorSelection
|
|
623
|
-
|
|
623
|
+
initialValue: Array<PortableTextBlock> | undefined
|
|
624
624
|
internalDrag?: {
|
|
625
625
|
ghost?: HTMLElement
|
|
626
626
|
origin: Pick<EventPosition, 'selection'>
|
|
@@ -642,10 +642,6 @@ declare const editorMachine: StateMachine<
|
|
|
642
642
|
type: 'update key generator'
|
|
643
643
|
keyGenerator: () => string
|
|
644
644
|
}
|
|
645
|
-
| {
|
|
646
|
-
type: 'update value'
|
|
647
|
-
value: Array<PortableTextBlock> | undefined
|
|
648
|
-
}
|
|
649
645
|
| {
|
|
650
646
|
type: 'update maxBlocks'
|
|
651
647
|
maxBlocks: number | undefined
|
|
@@ -964,7 +960,7 @@ declare const editorMachine: StateMachine<
|
|
|
964
960
|
initialReadOnly: boolean
|
|
965
961
|
maxBlocks: number | undefined
|
|
966
962
|
selection: EditorSelection
|
|
967
|
-
|
|
963
|
+
initialValue: Array<PortableTextBlock> | undefined
|
|
968
964
|
internalDrag?: {
|
|
969
965
|
ghost?: HTMLElement
|
|
970
966
|
origin: Pick<EventPosition, 'selection'>
|
|
@@ -986,10 +982,6 @@ declare const editorMachine: StateMachine<
|
|
|
986
982
|
type: 'update key generator'
|
|
987
983
|
keyGenerator: () => string
|
|
988
984
|
}
|
|
989
|
-
| {
|
|
990
|
-
type: 'update value'
|
|
991
|
-
value: Array<PortableTextBlock> | undefined
|
|
992
|
-
}
|
|
993
985
|
| {
|
|
994
986
|
type: 'update maxBlocks'
|
|
995
987
|
maxBlocks: number | undefined
|
|
@@ -1119,10 +1111,6 @@ declare const editorMachine: StateMachine<
|
|
|
1119
1111
|
type: 'update key generator'
|
|
1120
1112
|
keyGenerator: () => string
|
|
1121
1113
|
}
|
|
1122
|
-
| {
|
|
1123
|
-
type: 'update value'
|
|
1124
|
-
value: Array<PortableTextBlock> | undefined
|
|
1125
|
-
}
|
|
1126
1114
|
| {
|
|
1127
1115
|
type: 'update maxBlocks'
|
|
1128
1116
|
maxBlocks: number | undefined
|
|
@@ -1243,7 +1231,7 @@ declare const editorMachine: StateMachine<
|
|
|
1243
1231
|
selection: null
|
|
1244
1232
|
initialReadOnly: boolean
|
|
1245
1233
|
maxBlocks: number | undefined
|
|
1246
|
-
|
|
1234
|
+
initialValue: PortableTextBlock[] | undefined
|
|
1247
1235
|
}
|
|
1248
1236
|
readonly on: {
|
|
1249
1237
|
readonly 'notify.blurred': {
|
|
@@ -1259,7 +1247,7 @@ declare const editorMachine: StateMachine<
|
|
|
1259
1247
|
initialReadOnly: boolean
|
|
1260
1248
|
maxBlocks: number | undefined
|
|
1261
1249
|
selection: EditorSelection
|
|
1262
|
-
|
|
1250
|
+
initialValue: Array<PortableTextBlock> | undefined
|
|
1263
1251
|
internalDrag?: {
|
|
1264
1252
|
ghost?: HTMLElement
|
|
1265
1253
|
origin: Pick<EventPosition, 'selection'>
|
|
@@ -1285,10 +1273,6 @@ declare const editorMachine: StateMachine<
|
|
|
1285
1273
|
type: 'update key generator'
|
|
1286
1274
|
keyGenerator: () => string
|
|
1287
1275
|
}
|
|
1288
|
-
| {
|
|
1289
|
-
type: 'update value'
|
|
1290
|
-
value: Array<PortableTextBlock> | undefined
|
|
1291
|
-
}
|
|
1292
1276
|
| {
|
|
1293
1277
|
type: 'update maxBlocks'
|
|
1294
1278
|
maxBlocks: number | undefined
|
|
@@ -1463,7 +1447,7 @@ declare const editorMachine: StateMachine<
|
|
|
1463
1447
|
initialReadOnly: boolean
|
|
1464
1448
|
maxBlocks: number | undefined
|
|
1465
1449
|
selection: EditorSelection
|
|
1466
|
-
|
|
1450
|
+
initialValue: Array<PortableTextBlock> | undefined
|
|
1467
1451
|
internalDrag?: {
|
|
1468
1452
|
ghost?: HTMLElement
|
|
1469
1453
|
origin: Pick<EventPosition, 'selection'>
|
|
@@ -1488,10 +1472,6 @@ declare const editorMachine: StateMachine<
|
|
|
1488
1472
|
type: 'update key generator'
|
|
1489
1473
|
keyGenerator: () => string
|
|
1490
1474
|
}
|
|
1491
|
-
| {
|
|
1492
|
-
type: 'update value'
|
|
1493
|
-
value: Array<PortableTextBlock> | undefined
|
|
1494
|
-
}
|
|
1495
1475
|
| {
|
|
1496
1476
|
type: 'update maxBlocks'
|
|
1497
1477
|
maxBlocks: number | undefined
|
|
@@ -1666,7 +1646,7 @@ declare const editorMachine: StateMachine<
|
|
|
1666
1646
|
initialReadOnly: boolean
|
|
1667
1647
|
maxBlocks: number | undefined
|
|
1668
1648
|
selection: EditorSelection
|
|
1669
|
-
|
|
1649
|
+
initialValue: Array<PortableTextBlock> | undefined
|
|
1670
1650
|
internalDrag?: {
|
|
1671
1651
|
ghost?: HTMLElement
|
|
1672
1652
|
origin: Pick<EventPosition, 'selection'>
|
|
@@ -1694,10 +1674,6 @@ declare const editorMachine: StateMachine<
|
|
|
1694
1674
|
type: 'update key generator'
|
|
1695
1675
|
keyGenerator: () => string
|
|
1696
1676
|
}
|
|
1697
|
-
| {
|
|
1698
|
-
type: 'update value'
|
|
1699
|
-
value: Array<PortableTextBlock> | undefined
|
|
1700
|
-
}
|
|
1701
1677
|
| {
|
|
1702
1678
|
type: 'update maxBlocks'
|
|
1703
1679
|
maxBlocks: number | undefined
|
|
@@ -1872,7 +1848,7 @@ declare const editorMachine: StateMachine<
|
|
|
1872
1848
|
initialReadOnly: boolean
|
|
1873
1849
|
maxBlocks: number | undefined
|
|
1874
1850
|
selection: EditorSelection
|
|
1875
|
-
|
|
1851
|
+
initialValue: Array<PortableTextBlock> | undefined
|
|
1876
1852
|
internalDrag?: {
|
|
1877
1853
|
ghost?: HTMLElement
|
|
1878
1854
|
origin: Pick<EventPosition, 'selection'>
|
|
@@ -1899,10 +1875,6 @@ declare const editorMachine: StateMachine<
|
|
|
1899
1875
|
type: 'update key generator'
|
|
1900
1876
|
keyGenerator: () => string
|
|
1901
1877
|
}
|
|
1902
|
-
| {
|
|
1903
|
-
type: 'update value'
|
|
1904
|
-
value: Array<PortableTextBlock> | undefined
|
|
1905
|
-
}
|
|
1906
1878
|
| {
|
|
1907
1879
|
type: 'update maxBlocks'
|
|
1908
1880
|
maxBlocks: number | undefined
|
|
@@ -2077,7 +2049,7 @@ declare const editorMachine: StateMachine<
|
|
|
2077
2049
|
initialReadOnly: boolean
|
|
2078
2050
|
maxBlocks: number | undefined
|
|
2079
2051
|
selection: EditorSelection
|
|
2080
|
-
|
|
2052
|
+
initialValue: Array<PortableTextBlock> | undefined
|
|
2081
2053
|
internalDrag?: {
|
|
2082
2054
|
ghost?: HTMLElement
|
|
2083
2055
|
origin: Pick<EventPosition, 'selection'>
|
|
@@ -2103,10 +2075,6 @@ declare const editorMachine: StateMachine<
|
|
|
2103
2075
|
type: 'update key generator'
|
|
2104
2076
|
keyGenerator: () => string
|
|
2105
2077
|
}
|
|
2106
|
-
| {
|
|
2107
|
-
type: 'update value'
|
|
2108
|
-
value: Array<PortableTextBlock> | undefined
|
|
2109
|
-
}
|
|
2110
2078
|
| {
|
|
2111
2079
|
type: 'update maxBlocks'
|
|
2112
2080
|
maxBlocks: number | undefined
|
|
@@ -2282,7 +2250,7 @@ declare const editorMachine: StateMachine<
|
|
|
2282
2250
|
initialReadOnly: boolean
|
|
2283
2251
|
maxBlocks: number | undefined
|
|
2284
2252
|
selection: EditorSelection
|
|
2285
|
-
|
|
2253
|
+
initialValue: Array<PortableTextBlock> | undefined
|
|
2286
2254
|
internalDrag?: {
|
|
2287
2255
|
ghost?: HTMLElement
|
|
2288
2256
|
origin: Pick<EventPosition, 'selection'>
|
|
@@ -2308,10 +2276,6 @@ declare const editorMachine: StateMachine<
|
|
|
2308
2276
|
type: 'update key generator'
|
|
2309
2277
|
keyGenerator: () => string
|
|
2310
2278
|
}
|
|
2311
|
-
| {
|
|
2312
|
-
type: 'update value'
|
|
2313
|
-
value: Array<PortableTextBlock> | undefined
|
|
2314
|
-
}
|
|
2315
2279
|
| {
|
|
2316
2280
|
type: 'update maxBlocks'
|
|
2317
2281
|
maxBlocks: number | undefined
|
|
@@ -2438,7 +2402,7 @@ declare const editorMachine: StateMachine<
|
|
|
2438
2402
|
initialReadOnly: boolean
|
|
2439
2403
|
maxBlocks: number | undefined
|
|
2440
2404
|
selection: EditorSelection
|
|
2441
|
-
|
|
2405
|
+
initialValue: Array<PortableTextBlock> | undefined
|
|
2442
2406
|
internalDrag?: {
|
|
2443
2407
|
ghost?: HTMLElement
|
|
2444
2408
|
origin: Pick<EventPosition, 'selection'>
|
|
@@ -2464,10 +2428,6 @@ declare const editorMachine: StateMachine<
|
|
|
2464
2428
|
type: 'update key generator'
|
|
2465
2429
|
keyGenerator: () => string
|
|
2466
2430
|
}
|
|
2467
|
-
| {
|
|
2468
|
-
type: 'update value'
|
|
2469
|
-
value: Array<PortableTextBlock> | undefined
|
|
2470
|
-
}
|
|
2471
2431
|
| {
|
|
2472
2432
|
type: 'update maxBlocks'
|
|
2473
2433
|
maxBlocks: number | undefined
|
|
@@ -2643,7 +2603,7 @@ declare const editorMachine: StateMachine<
|
|
|
2643
2603
|
initialReadOnly: boolean
|
|
2644
2604
|
maxBlocks: number | undefined
|
|
2645
2605
|
selection: EditorSelection
|
|
2646
|
-
|
|
2606
|
+
initialValue: Array<PortableTextBlock> | undefined
|
|
2647
2607
|
internalDrag?: {
|
|
2648
2608
|
ghost?: HTMLElement
|
|
2649
2609
|
origin: Pick<EventPosition, 'selection'>
|
|
@@ -2669,10 +2629,6 @@ declare const editorMachine: StateMachine<
|
|
|
2669
2629
|
type: 'update key generator'
|
|
2670
2630
|
keyGenerator: () => string
|
|
2671
2631
|
}
|
|
2672
|
-
| {
|
|
2673
|
-
type: 'update value'
|
|
2674
|
-
value: Array<PortableTextBlock> | undefined
|
|
2675
|
-
}
|
|
2676
2632
|
| {
|
|
2677
2633
|
type: 'update maxBlocks'
|
|
2678
2634
|
maxBlocks: number | undefined
|
|
@@ -2847,7 +2803,7 @@ declare const editorMachine: StateMachine<
|
|
|
2847
2803
|
initialReadOnly: boolean
|
|
2848
2804
|
maxBlocks: number | undefined
|
|
2849
2805
|
selection: EditorSelection
|
|
2850
|
-
|
|
2806
|
+
initialValue: Array<PortableTextBlock> | undefined
|
|
2851
2807
|
internalDrag?: {
|
|
2852
2808
|
ghost?: HTMLElement
|
|
2853
2809
|
origin: Pick<EventPosition, 'selection'>
|
|
@@ -2872,10 +2828,6 @@ declare const editorMachine: StateMachine<
|
|
|
2872
2828
|
type: 'update key generator'
|
|
2873
2829
|
keyGenerator: () => string
|
|
2874
2830
|
}
|
|
2875
|
-
| {
|
|
2876
|
-
type: 'update value'
|
|
2877
|
-
value: Array<PortableTextBlock> | undefined
|
|
2878
|
-
}
|
|
2879
2831
|
| {
|
|
2880
2832
|
type: 'update maxBlocks'
|
|
2881
2833
|
maxBlocks: number | undefined
|
|
@@ -3050,7 +3002,7 @@ declare const editorMachine: StateMachine<
|
|
|
3050
3002
|
initialReadOnly: boolean
|
|
3051
3003
|
maxBlocks: number | undefined
|
|
3052
3004
|
selection: EditorSelection
|
|
3053
|
-
|
|
3005
|
+
initialValue: Array<PortableTextBlock> | undefined
|
|
3054
3006
|
internalDrag?: {
|
|
3055
3007
|
ghost?: HTMLElement
|
|
3056
3008
|
origin: Pick<EventPosition, 'selection'>
|
|
@@ -3076,10 +3028,6 @@ declare const editorMachine: StateMachine<
|
|
|
3076
3028
|
type: 'update key generator'
|
|
3077
3029
|
keyGenerator: () => string
|
|
3078
3030
|
}
|
|
3079
|
-
| {
|
|
3080
|
-
type: 'update value'
|
|
3081
|
-
value: Array<PortableTextBlock> | undefined
|
|
3082
|
-
}
|
|
3083
3031
|
| {
|
|
3084
3032
|
type: 'update maxBlocks'
|
|
3085
3033
|
maxBlocks: number | undefined
|
|
@@ -3260,7 +3208,7 @@ declare const editorMachine: StateMachine<
|
|
|
3260
3208
|
initialReadOnly: boolean
|
|
3261
3209
|
maxBlocks: number | undefined
|
|
3262
3210
|
selection: EditorSelection
|
|
3263
|
-
|
|
3211
|
+
initialValue: Array<PortableTextBlock> | undefined
|
|
3264
3212
|
internalDrag?: {
|
|
3265
3213
|
ghost?: HTMLElement
|
|
3266
3214
|
origin: Pick<EventPosition, 'selection'>
|
|
@@ -3286,10 +3234,6 @@ declare const editorMachine: StateMachine<
|
|
|
3286
3234
|
type: 'update key generator'
|
|
3287
3235
|
keyGenerator: () => string
|
|
3288
3236
|
}
|
|
3289
|
-
| {
|
|
3290
|
-
type: 'update value'
|
|
3291
|
-
value: Array<PortableTextBlock> | undefined
|
|
3292
|
-
}
|
|
3293
3237
|
| {
|
|
3294
3238
|
type: 'update maxBlocks'
|
|
3295
3239
|
maxBlocks: number | undefined
|
|
@@ -3408,164 +3352,6 @@ declare const editorMachine: StateMachine<
|
|
|
3408
3352
|
readonly 'update schema': {
|
|
3409
3353
|
readonly actions: 'assign schema'
|
|
3410
3354
|
}
|
|
3411
|
-
readonly 'update value': {
|
|
3412
|
-
readonly actions: ActionFunction<
|
|
3413
|
-
{
|
|
3414
|
-
behaviors: Set<BehaviorConfig>
|
|
3415
|
-
converters: Set<Converter>
|
|
3416
|
-
getLegacySchema: () => PortableTextMemberSchemaTypes
|
|
3417
|
-
keyGenerator: () => string
|
|
3418
|
-
pendingEvents: Array<InternalPatchEvent | MutationEvent>
|
|
3419
|
-
pendingIncomingPatchesEvents: Array<PatchesEvent>
|
|
3420
|
-
schema: EditorSchema
|
|
3421
|
-
initialReadOnly: boolean
|
|
3422
|
-
maxBlocks: number | undefined
|
|
3423
|
-
selection: EditorSelection
|
|
3424
|
-
incomingValue: Array<PortableTextBlock> | undefined
|
|
3425
|
-
internalDrag?: {
|
|
3426
|
-
ghost?: HTMLElement
|
|
3427
|
-
origin: Pick<EventPosition, 'selection'>
|
|
3428
|
-
}
|
|
3429
|
-
slateEditor?: PortableTextSlateEditor
|
|
3430
|
-
},
|
|
3431
|
-
{
|
|
3432
|
-
type: 'update value'
|
|
3433
|
-
value: Array<PortableTextBlock> | undefined
|
|
3434
|
-
},
|
|
3435
|
-
| InternalPatchEvent
|
|
3436
|
-
| MutationEvent
|
|
3437
|
-
| PatchesEvent
|
|
3438
|
-
| {
|
|
3439
|
-
type: 'update readOnly'
|
|
3440
|
-
readOnly: boolean
|
|
3441
|
-
}
|
|
3442
|
-
| {
|
|
3443
|
-
type: 'update schema'
|
|
3444
|
-
schema: EditorSchema
|
|
3445
|
-
}
|
|
3446
|
-
| {
|
|
3447
|
-
type: 'update key generator'
|
|
3448
|
-
keyGenerator: () => string
|
|
3449
|
-
}
|
|
3450
|
-
| {
|
|
3451
|
-
type: 'update value'
|
|
3452
|
-
value: Array<PortableTextBlock> | undefined
|
|
3453
|
-
}
|
|
3454
|
-
| {
|
|
3455
|
-
type: 'update maxBlocks'
|
|
3456
|
-
maxBlocks: number | undefined
|
|
3457
|
-
}
|
|
3458
|
-
| {
|
|
3459
|
-
type: 'add behavior'
|
|
3460
|
-
behaviorConfig: BehaviorConfig
|
|
3461
|
-
}
|
|
3462
|
-
| {
|
|
3463
|
-
type: 'remove behavior'
|
|
3464
|
-
behaviorConfig: BehaviorConfig
|
|
3465
|
-
}
|
|
3466
|
-
| {
|
|
3467
|
-
type: 'blur'
|
|
3468
|
-
editor: PortableTextSlateEditor
|
|
3469
|
-
}
|
|
3470
|
-
| {
|
|
3471
|
-
type: 'focus'
|
|
3472
|
-
editor: PortableTextSlateEditor
|
|
3473
|
-
}
|
|
3474
|
-
| {
|
|
3475
|
-
type: 'normalizing'
|
|
3476
|
-
}
|
|
3477
|
-
| {
|
|
3478
|
-
type: 'done normalizing'
|
|
3479
|
-
}
|
|
3480
|
-
| {
|
|
3481
|
-
type: 'done syncing value'
|
|
3482
|
-
}
|
|
3483
|
-
| {
|
|
3484
|
-
type: 'syncing value'
|
|
3485
|
-
}
|
|
3486
|
-
| {
|
|
3487
|
-
type: 'behavior event'
|
|
3488
|
-
behaviorEvent: BehaviorEvent
|
|
3489
|
-
editor: PortableTextSlateEditor
|
|
3490
|
-
nativeEvent?: {
|
|
3491
|
-
preventDefault: () => void
|
|
3492
|
-
}
|
|
3493
|
-
}
|
|
3494
|
-
| {
|
|
3495
|
-
type: 'notify.patch'
|
|
3496
|
-
patch: Patch
|
|
3497
|
-
}
|
|
3498
|
-
| {
|
|
3499
|
-
type: 'notify.mutation'
|
|
3500
|
-
patches: Array<Patch>
|
|
3501
|
-
snapshot: Array<PortableTextBlock> | undefined
|
|
3502
|
-
value: Array<PortableTextBlock> | undefined
|
|
3503
|
-
}
|
|
3504
|
-
| {
|
|
3505
|
-
type: 'notify.blurred'
|
|
3506
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
3507
|
-
}
|
|
3508
|
-
| {
|
|
3509
|
-
type: 'notify.done loading'
|
|
3510
|
-
}
|
|
3511
|
-
| {
|
|
3512
|
-
type: 'notify.editable'
|
|
3513
|
-
}
|
|
3514
|
-
| {
|
|
3515
|
-
type: 'notify.error'
|
|
3516
|
-
name: string
|
|
3517
|
-
description: string
|
|
3518
|
-
data: unknown
|
|
3519
|
-
}
|
|
3520
|
-
| {
|
|
3521
|
-
type: 'notify.focused'
|
|
3522
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
3523
|
-
}
|
|
3524
|
-
| {
|
|
3525
|
-
type: 'notify.invalid value'
|
|
3526
|
-
resolution: InvalidValueResolution | null
|
|
3527
|
-
value: Array<PortableTextBlock> | undefined
|
|
3528
|
-
}
|
|
3529
|
-
| {
|
|
3530
|
-
type: 'notify.loading'
|
|
3531
|
-
}
|
|
3532
|
-
| {
|
|
3533
|
-
type: 'notify.read only'
|
|
3534
|
-
}
|
|
3535
|
-
| {
|
|
3536
|
-
type: 'notify.ready'
|
|
3537
|
-
}
|
|
3538
|
-
| {
|
|
3539
|
-
type: 'notify.selection'
|
|
3540
|
-
selection: EditorSelection
|
|
3541
|
-
}
|
|
3542
|
-
| {
|
|
3543
|
-
type: 'notify.value changed'
|
|
3544
|
-
value: Array<PortableTextBlock> | undefined
|
|
3545
|
-
}
|
|
3546
|
-
| {
|
|
3547
|
-
type: 'notify.unset'
|
|
3548
|
-
previousValue: Array<PortableTextBlock>
|
|
3549
|
-
}
|
|
3550
|
-
| {
|
|
3551
|
-
type: 'dragstart'
|
|
3552
|
-
origin: Pick<EventPosition, 'selection'>
|
|
3553
|
-
ghost?: HTMLElement
|
|
3554
|
-
}
|
|
3555
|
-
| {
|
|
3556
|
-
type: 'dragend'
|
|
3557
|
-
}
|
|
3558
|
-
| {
|
|
3559
|
-
type: 'drop'
|
|
3560
|
-
},
|
|
3561
|
-
undefined,
|
|
3562
|
-
never,
|
|
3563
|
-
never,
|
|
3564
|
-
never,
|
|
3565
|
-
never,
|
|
3566
|
-
never
|
|
3567
|
-
>
|
|
3568
|
-
}
|
|
3569
3355
|
readonly 'update maxBlocks': {
|
|
3570
3356
|
readonly actions: ActionFunction<
|
|
3571
3357
|
{
|
|
@@ -3579,7 +3365,7 @@ declare const editorMachine: StateMachine<
|
|
|
3579
3365
|
initialReadOnly: boolean
|
|
3580
3366
|
maxBlocks: number | undefined
|
|
3581
3367
|
selection: EditorSelection
|
|
3582
|
-
|
|
3368
|
+
initialValue: Array<PortableTextBlock> | undefined
|
|
3583
3369
|
internalDrag?: {
|
|
3584
3370
|
ghost?: HTMLElement
|
|
3585
3371
|
origin: Pick<EventPosition, 'selection'>
|
|
@@ -3605,10 +3391,6 @@ declare const editorMachine: StateMachine<
|
|
|
3605
3391
|
type: 'update key generator'
|
|
3606
3392
|
keyGenerator: () => string
|
|
3607
3393
|
}
|
|
3608
|
-
| {
|
|
3609
|
-
type: 'update value'
|
|
3610
|
-
value: Array<PortableTextBlock> | undefined
|
|
3611
|
-
}
|
|
3612
3394
|
| {
|
|
3613
3395
|
type: 'update maxBlocks'
|
|
3614
3396
|
maxBlocks: number | undefined
|
|
@@ -3749,7 +3531,7 @@ declare const editorMachine: StateMachine<
|
|
|
3749
3531
|
initialReadOnly: boolean
|
|
3750
3532
|
maxBlocks: number | undefined
|
|
3751
3533
|
selection: EditorSelection
|
|
3752
|
-
|
|
3534
|
+
initialValue: Array<PortableTextBlock> | undefined
|
|
3753
3535
|
internalDrag?: {
|
|
3754
3536
|
ghost?: HTMLElement
|
|
3755
3537
|
origin: Pick<EventPosition, 'selection'>
|
|
@@ -3791,7 +3573,7 @@ declare const editorMachine: StateMachine<
|
|
|
3791
3573
|
initialReadOnly: boolean
|
|
3792
3574
|
maxBlocks: number | undefined
|
|
3793
3575
|
selection: EditorSelection
|
|
3794
|
-
|
|
3576
|
+
initialValue: Array<PortableTextBlock> | undefined
|
|
3795
3577
|
internalDrag?: {
|
|
3796
3578
|
ghost?: HTMLElement
|
|
3797
3579
|
origin: Pick<EventPosition, 'selection'>
|
|
@@ -3828,7 +3610,7 @@ declare const editorMachine: StateMachine<
|
|
|
3828
3610
|
initialReadOnly: boolean
|
|
3829
3611
|
maxBlocks: number | undefined
|
|
3830
3612
|
selection: EditorSelection
|
|
3831
|
-
|
|
3613
|
+
initialValue: Array<PortableTextBlock> | undefined
|
|
3832
3614
|
internalDrag?: {
|
|
3833
3615
|
ghost?: HTMLElement
|
|
3834
3616
|
origin: Pick<EventPosition, 'selection'>
|
|
@@ -3864,7 +3646,7 @@ declare const editorMachine: StateMachine<
|
|
|
3864
3646
|
initialReadOnly: boolean
|
|
3865
3647
|
maxBlocks: number | undefined
|
|
3866
3648
|
selection: EditorSelection
|
|
3867
|
-
|
|
3649
|
+
initialValue: Array<PortableTextBlock> | undefined
|
|
3868
3650
|
internalDrag?: {
|
|
3869
3651
|
ghost?: HTMLElement
|
|
3870
3652
|
origin: Pick<EventPosition, 'selection'>
|
|
@@ -3900,7 +3682,7 @@ declare const editorMachine: StateMachine<
|
|
|
3900
3682
|
initialReadOnly: boolean
|
|
3901
3683
|
maxBlocks: number | undefined
|
|
3902
3684
|
selection: EditorSelection
|
|
3903
|
-
|
|
3685
|
+
initialValue: Array<PortableTextBlock> | undefined
|
|
3904
3686
|
internalDrag?: {
|
|
3905
3687
|
ghost?: HTMLElement
|
|
3906
3688
|
origin: Pick<EventPosition, 'selection'>
|
|
@@ -3926,10 +3708,6 @@ declare const editorMachine: StateMachine<
|
|
|
3926
3708
|
type: 'update key generator'
|
|
3927
3709
|
keyGenerator: () => string
|
|
3928
3710
|
}
|
|
3929
|
-
| {
|
|
3930
|
-
type: 'update value'
|
|
3931
|
-
value: Array<PortableTextBlock> | undefined
|
|
3932
|
-
}
|
|
3933
3711
|
| {
|
|
3934
3712
|
type: 'update maxBlocks'
|
|
3935
3713
|
maxBlocks: number | undefined
|
|
@@ -4069,7 +3847,7 @@ declare const editorMachine: StateMachine<
|
|
|
4069
3847
|
initialReadOnly: boolean
|
|
4070
3848
|
maxBlocks: number | undefined
|
|
4071
3849
|
selection: EditorSelection
|
|
4072
|
-
|
|
3850
|
+
initialValue: Array<PortableTextBlock> | undefined
|
|
4073
3851
|
internalDrag?: {
|
|
4074
3852
|
ghost?: HTMLElement
|
|
4075
3853
|
origin: Pick<EventPosition, 'selection'>
|
|
@@ -4096,10 +3874,6 @@ declare const editorMachine: StateMachine<
|
|
|
4096
3874
|
type: 'update key generator'
|
|
4097
3875
|
keyGenerator: () => string
|
|
4098
3876
|
}
|
|
4099
|
-
| {
|
|
4100
|
-
type: 'update value'
|
|
4101
|
-
value: Array<PortableTextBlock> | undefined
|
|
4102
|
-
}
|
|
4103
3877
|
| {
|
|
4104
3878
|
type: 'update maxBlocks'
|
|
4105
3879
|
maxBlocks: number | undefined
|
|
@@ -4265,7 +4039,7 @@ declare const editorMachine: StateMachine<
|
|
|
4265
4039
|
initialReadOnly: boolean
|
|
4266
4040
|
maxBlocks: number | undefined
|
|
4267
4041
|
selection: EditorSelection
|
|
4268
|
-
|
|
4042
|
+
initialValue: Array<PortableTextBlock> | undefined
|
|
4269
4043
|
internalDrag?: {
|
|
4270
4044
|
ghost?: HTMLElement
|
|
4271
4045
|
origin: Pick<EventPosition, 'selection'>
|
|
@@ -4287,10 +4061,6 @@ declare const editorMachine: StateMachine<
|
|
|
4287
4061
|
type: 'update key generator'
|
|
4288
4062
|
keyGenerator: () => string
|
|
4289
4063
|
}
|
|
4290
|
-
| {
|
|
4291
|
-
type: 'update value'
|
|
4292
|
-
value: Array<PortableTextBlock> | undefined
|
|
4293
|
-
}
|
|
4294
4064
|
| {
|
|
4295
4065
|
type: 'update maxBlocks'
|
|
4296
4066
|
maxBlocks: number | undefined
|
|
@@ -4413,10 +4183,6 @@ declare const editorMachine: StateMachine<
|
|
|
4413
4183
|
type: 'update key generator'
|
|
4414
4184
|
keyGenerator: () => string
|
|
4415
4185
|
}
|
|
4416
|
-
| {
|
|
4417
|
-
type: 'update value'
|
|
4418
|
-
value: Array<PortableTextBlock> | undefined
|
|
4419
|
-
}
|
|
4420
4186
|
| {
|
|
4421
4187
|
type: 'update maxBlocks'
|
|
4422
4188
|
maxBlocks: number | undefined
|
|
@@ -4537,7 +4303,7 @@ declare const editorMachine: StateMachine<
|
|
|
4537
4303
|
initialReadOnly: boolean
|
|
4538
4304
|
maxBlocks: number | undefined
|
|
4539
4305
|
selection: EditorSelection
|
|
4540
|
-
|
|
4306
|
+
initialValue: Array<PortableTextBlock> | undefined
|
|
4541
4307
|
internalDrag?: {
|
|
4542
4308
|
ghost?: HTMLElement
|
|
4543
4309
|
origin: Pick<EventPosition, 'selection'>
|
|
@@ -4559,10 +4325,6 @@ declare const editorMachine: StateMachine<
|
|
|
4559
4325
|
type: 'update key generator'
|
|
4560
4326
|
keyGenerator: () => string
|
|
4561
4327
|
}
|
|
4562
|
-
| {
|
|
4563
|
-
type: 'update value'
|
|
4564
|
-
value: Array<PortableTextBlock> | undefined
|
|
4565
|
-
}
|
|
4566
4328
|
| {
|
|
4567
4329
|
type: 'update maxBlocks'
|
|
4568
4330
|
maxBlocks: number | undefined
|
|
@@ -4685,10 +4447,6 @@ declare const editorMachine: StateMachine<
|
|
|
4685
4447
|
type: 'update key generator'
|
|
4686
4448
|
keyGenerator: () => string
|
|
4687
4449
|
}
|
|
4688
|
-
| {
|
|
4689
|
-
type: 'update value'
|
|
4690
|
-
value: Array<PortableTextBlock> | undefined
|
|
4691
|
-
}
|
|
4692
4450
|
| {
|
|
4693
4451
|
type: 'update maxBlocks'
|
|
4694
4452
|
maxBlocks: number | undefined
|
|
@@ -4870,9 +4628,7 @@ declare const editorMachine: StateMachine<
|
|
|
4870
4628
|
initialReadOnly: boolean
|
|
4871
4629
|
maxBlocks: number | undefined
|
|
4872
4630
|
selection: EditorSelection
|
|
4873
|
-
|
|
4874
|
-
| Array<PortableTextBlock>
|
|
4875
|
-
| undefined
|
|
4631
|
+
initialValue: Array<PortableTextBlock> | undefined
|
|
4876
4632
|
internalDrag?: {
|
|
4877
4633
|
ghost?: HTMLElement
|
|
4878
4634
|
origin: Pick<EventPosition, 'selection'>
|
|
@@ -4895,10 +4651,6 @@ declare const editorMachine: StateMachine<
|
|
|
4895
4651
|
type: 'update key generator'
|
|
4896
4652
|
keyGenerator: () => string
|
|
4897
4653
|
}
|
|
4898
|
-
| {
|
|
4899
|
-
type: 'update value'
|
|
4900
|
-
value: Array<PortableTextBlock> | undefined
|
|
4901
|
-
}
|
|
4902
4654
|
| {
|
|
4903
4655
|
type: 'update maxBlocks'
|
|
4904
4656
|
maxBlocks: number | undefined
|