@portabletext/editor 1.49.9 → 1.49.11
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 +160 -2885
- package/lib/behaviors/index.d.ts +160 -2885
- package/lib/index.cjs +356 -311
- package/lib/index.cjs.map +1 -1
- package/lib/index.d.cts +170 -2874
- package/lib/index.d.ts +170 -2874
- package/lib/index.js +359 -314
- package/lib/index.js.map +1 -1
- package/lib/plugins/index.cjs.map +1 -1
- package/lib/plugins/index.d.cts +162 -2879
- package/lib/plugins/index.d.ts +162 -2879
- package/lib/plugins/index.js.map +1 -1
- package/lib/selectors/index.d.cts +160 -2885
- package/lib/selectors/index.d.ts +160 -2885
- package/lib/utils/index.d.cts +160 -2885
- package/lib/utils/index.d.ts +160 -2885
- package/package.json +7 -7
- package/src/editor/Editable.tsx +14 -12
- package/src/editor/PortableTextEditor.tsx +21 -26
- package/src/editor/__tests__/self-solving.test.tsx +9 -9
- package/src/editor/create-editor.ts +91 -53
- package/src/editor/create-slate-editor.tsx +3 -0
- package/src/editor/editor-machine.ts +15 -127
- package/src/editor/editor-provider.tsx +20 -15
- package/src/editor/mutation-machine.ts +125 -7
- package/src/editor/plugins/createWithPatches.ts +5 -2
- package/src/editor/plugins/createWithPortableTextSelections.ts +4 -2
- package/src/editor/plugins/with-plugins.ts +8 -3
- package/src/editor/relay-actor-context.ts +4 -0
- package/src/editor/relay-machine.ts +89 -0
- package/src/editor/route-events-to-changes.tsx +4 -10
- package/src/editor/sync-machine.ts +2 -2
- package/src/editor-event-listener.tsx +1 -1
- package/src/editor.ts +2 -4
- package/src/index.ts +3 -6
- package/src/internal-utils/__tests__/operationToPatches.test.ts +3 -1
- package/src/internal-utils/__tests__/patchToOperations.test.ts +2 -0
- package/src/internal-utils/applyPatch.ts +6 -2
- package/src/plugins/plugin.event-listener.tsx +1 -1
- package/src/types/editor.ts +12 -4
package/lib/index.d.cts
CHANGED
|
@@ -21,7 +21,6 @@ import {
|
|
|
21
21
|
import type {
|
|
22
22
|
BaseSyntheticEvent,
|
|
23
23
|
ClipboardEvent as ClipboardEvent_2,
|
|
24
|
-
FocusEvent as FocusEvent_2,
|
|
25
24
|
KeyboardEvent as KeyboardEvent_2,
|
|
26
25
|
default as React_2,
|
|
27
26
|
ReactElement,
|
|
@@ -29,6 +28,7 @@ import type {
|
|
|
29
28
|
} from 'react'
|
|
30
29
|
import {
|
|
31
30
|
Component,
|
|
31
|
+
FocusEvent as FocusEvent_2,
|
|
32
32
|
ForwardRefExoticComponent,
|
|
33
33
|
JSX,
|
|
34
34
|
MutableRefObject,
|
|
@@ -63,7 +63,10 @@ import {
|
|
|
63
63
|
} from 'xstate'
|
|
64
64
|
import type {EventObject, Snapshot} from 'xstate'
|
|
65
65
|
import {GuardArgs} from 'xstate/guards'
|
|
66
|
-
import {
|
|
66
|
+
import {
|
|
67
|
+
Editor as Editor_2,
|
|
68
|
+
InvalidValueResolution as InvalidValueResolution_2,
|
|
69
|
+
} from '..'
|
|
67
70
|
|
|
68
71
|
declare type AbstractBehaviorEvent =
|
|
69
72
|
| {
|
|
@@ -480,7 +483,9 @@ declare type ClipboardBehaviorEvent =
|
|
|
480
483
|
/**
|
|
481
484
|
* The editor was either connected or disconnected to the network
|
|
482
485
|
* To show out of sync warnings etc when in collaborative mode.
|
|
483
|
-
* @beta
|
|
486
|
+
* @beta
|
|
487
|
+
* @deprecated The change is no longer emitted
|
|
488
|
+
* */
|
|
484
489
|
export declare type ConnectionChange = {
|
|
485
490
|
type: 'connection'
|
|
486
491
|
value: 'online' | 'offline'
|
|
@@ -818,12 +823,6 @@ export declare type EditorEmittedEvent =
|
|
|
818
823
|
| {
|
|
819
824
|
type: 'editable'
|
|
820
825
|
}
|
|
821
|
-
| {
|
|
822
|
-
type: 'error'
|
|
823
|
-
name: string
|
|
824
|
-
description: string
|
|
825
|
-
data: unknown
|
|
826
|
-
}
|
|
827
826
|
| {
|
|
828
827
|
type: 'focused'
|
|
829
828
|
event: FocusEvent_2<HTMLDivElement, Element>
|
|
@@ -906,14 +905,6 @@ declare const editorMachine: StateMachine<
|
|
|
906
905
|
type: 'update readOnly'
|
|
907
906
|
readOnly: boolean
|
|
908
907
|
}
|
|
909
|
-
| {
|
|
910
|
-
type: 'update schema'
|
|
911
|
-
schema: EditorSchema
|
|
912
|
-
}
|
|
913
|
-
| {
|
|
914
|
-
type: 'update key generator'
|
|
915
|
-
keyGenerator: () => string
|
|
916
|
-
}
|
|
917
908
|
| {
|
|
918
909
|
type: 'update maxBlocks'
|
|
919
910
|
maxBlocks: number | undefined
|
|
@@ -937,6 +928,10 @@ declare const editorMachine: StateMachine<
|
|
|
937
928
|
| {
|
|
938
929
|
type: 'normalizing'
|
|
939
930
|
}
|
|
931
|
+
| {
|
|
932
|
+
type: 'update selection'
|
|
933
|
+
selection: EditorSelection
|
|
934
|
+
}
|
|
940
935
|
| {
|
|
941
936
|
type: 'done normalizing'
|
|
942
937
|
}
|
|
@@ -954,62 +949,6 @@ declare const editorMachine: StateMachine<
|
|
|
954
949
|
preventDefault: () => void
|
|
955
950
|
}
|
|
956
951
|
}
|
|
957
|
-
| {
|
|
958
|
-
type: 'notify.patch'
|
|
959
|
-
patch: Patch
|
|
960
|
-
}
|
|
961
|
-
| {
|
|
962
|
-
type: 'notify.mutation'
|
|
963
|
-
patches: Array<Patch>
|
|
964
|
-
snapshot: Array<PortableTextBlock> | undefined
|
|
965
|
-
value: Array<PortableTextBlock> | undefined
|
|
966
|
-
}
|
|
967
|
-
| {
|
|
968
|
-
type: 'notify.blurred'
|
|
969
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
970
|
-
}
|
|
971
|
-
| {
|
|
972
|
-
type: 'notify.done loading'
|
|
973
|
-
}
|
|
974
|
-
| {
|
|
975
|
-
type: 'notify.editable'
|
|
976
|
-
}
|
|
977
|
-
| {
|
|
978
|
-
type: 'notify.error'
|
|
979
|
-
name: string
|
|
980
|
-
description: string
|
|
981
|
-
data: unknown
|
|
982
|
-
}
|
|
983
|
-
| {
|
|
984
|
-
type: 'notify.focused'
|
|
985
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
986
|
-
}
|
|
987
|
-
| {
|
|
988
|
-
type: 'notify.invalid value'
|
|
989
|
-
resolution: InvalidValueResolution | null
|
|
990
|
-
value: Array<PortableTextBlock> | undefined
|
|
991
|
-
}
|
|
992
|
-
| {
|
|
993
|
-
type: 'notify.loading'
|
|
994
|
-
}
|
|
995
|
-
| {
|
|
996
|
-
type: 'notify.read only'
|
|
997
|
-
}
|
|
998
|
-
| {
|
|
999
|
-
type: 'notify.ready'
|
|
1000
|
-
}
|
|
1001
|
-
| {
|
|
1002
|
-
type: 'notify.selection'
|
|
1003
|
-
selection: EditorSelection
|
|
1004
|
-
}
|
|
1005
|
-
| {
|
|
1006
|
-
type: 'notify.value changed'
|
|
1007
|
-
value: Array<PortableTextBlock> | undefined
|
|
1008
|
-
}
|
|
1009
|
-
| {
|
|
1010
|
-
type: 'notify.unset'
|
|
1011
|
-
previousValue: Array<PortableTextBlock>
|
|
1012
|
-
}
|
|
1013
952
|
| {
|
|
1014
953
|
type: 'dragstart'
|
|
1015
954
|
origin: Pick<EventPosition, 'selection'>
|
|
@@ -1032,10 +971,6 @@ declare const editorMachine: StateMachine<
|
|
|
1032
971
|
type: 'remove behavior from context'
|
|
1033
972
|
params: NonReducibleUnknown
|
|
1034
973
|
}
|
|
1035
|
-
'assign schema': {
|
|
1036
|
-
type: 'assign schema'
|
|
1037
|
-
params: NonReducibleUnknown
|
|
1038
|
-
}
|
|
1039
974
|
'emit patch event': {
|
|
1040
975
|
type: 'emit patch event'
|
|
1041
976
|
params: NonReducibleUnknown
|
|
@@ -1135,7 +1070,6 @@ declare const editorMachine: StateMachine<
|
|
|
1135
1070
|
initialValue?: Array<PortableTextBlock>
|
|
1136
1071
|
},
|
|
1137
1072
|
NonReducibleUnknown,
|
|
1138
|
-
| PatchEvent
|
|
1139
1073
|
| InternalPatchEvent
|
|
1140
1074
|
| MutationEvent
|
|
1141
1075
|
| PatchesEvent
|
|
@@ -1149,19 +1083,13 @@ declare const editorMachine: StateMachine<
|
|
|
1149
1083
|
| {
|
|
1150
1084
|
type: 'editable'
|
|
1151
1085
|
}
|
|
1152
|
-
| {
|
|
1153
|
-
type: 'error'
|
|
1154
|
-
name: string
|
|
1155
|
-
description: string
|
|
1156
|
-
data: unknown
|
|
1157
|
-
}
|
|
1158
1086
|
| {
|
|
1159
1087
|
type: 'focused'
|
|
1160
1088
|
event: FocusEvent_2<HTMLDivElement, Element>
|
|
1161
1089
|
}
|
|
1162
1090
|
| {
|
|
1163
1091
|
type: 'invalid value'
|
|
1164
|
-
resolution:
|
|
1092
|
+
resolution: InvalidValueResolution_2 | null
|
|
1165
1093
|
value: Array<PortableTextBlock> | undefined
|
|
1166
1094
|
}
|
|
1167
1095
|
| {
|
|
@@ -1180,8 +1108,7 @@ declare const editorMachine: StateMachine<
|
|
|
1180
1108
|
| {
|
|
1181
1109
|
type: 'value changed'
|
|
1182
1110
|
value: Array<PortableTextBlock> | undefined
|
|
1183
|
-
}
|
|
1184
|
-
| UnsetEvent,
|
|
1111
|
+
},
|
|
1185
1112
|
MetaObject,
|
|
1186
1113
|
{
|
|
1187
1114
|
readonly id: 'editor'
|
|
@@ -1246,14 +1173,6 @@ declare const editorMachine: StateMachine<
|
|
|
1246
1173
|
type: 'update readOnly'
|
|
1247
1174
|
readOnly: boolean
|
|
1248
1175
|
}
|
|
1249
|
-
| {
|
|
1250
|
-
type: 'update schema'
|
|
1251
|
-
schema: EditorSchema
|
|
1252
|
-
}
|
|
1253
|
-
| {
|
|
1254
|
-
type: 'update key generator'
|
|
1255
|
-
keyGenerator: () => string
|
|
1256
|
-
}
|
|
1257
1176
|
| {
|
|
1258
1177
|
type: 'update maxBlocks'
|
|
1259
1178
|
maxBlocks: number | undefined
|
|
@@ -1277,6 +1196,10 @@ declare const editorMachine: StateMachine<
|
|
|
1277
1196
|
| {
|
|
1278
1197
|
type: 'normalizing'
|
|
1279
1198
|
}
|
|
1199
|
+
| {
|
|
1200
|
+
type: 'update selection'
|
|
1201
|
+
selection: EditorSelection
|
|
1202
|
+
}
|
|
1280
1203
|
| {
|
|
1281
1204
|
type: 'done normalizing'
|
|
1282
1205
|
}
|
|
@@ -1294,62 +1217,6 @@ declare const editorMachine: StateMachine<
|
|
|
1294
1217
|
preventDefault: () => void
|
|
1295
1218
|
}
|
|
1296
1219
|
}
|
|
1297
|
-
| {
|
|
1298
|
-
type: 'notify.patch'
|
|
1299
|
-
patch: Patch
|
|
1300
|
-
}
|
|
1301
|
-
| {
|
|
1302
|
-
type: 'notify.mutation'
|
|
1303
|
-
patches: Array<Patch>
|
|
1304
|
-
snapshot: Array<PortableTextBlock> | undefined
|
|
1305
|
-
value: Array<PortableTextBlock> | undefined
|
|
1306
|
-
}
|
|
1307
|
-
| {
|
|
1308
|
-
type: 'notify.blurred'
|
|
1309
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
1310
|
-
}
|
|
1311
|
-
| {
|
|
1312
|
-
type: 'notify.done loading'
|
|
1313
|
-
}
|
|
1314
|
-
| {
|
|
1315
|
-
type: 'notify.editable'
|
|
1316
|
-
}
|
|
1317
|
-
| {
|
|
1318
|
-
type: 'notify.error'
|
|
1319
|
-
name: string
|
|
1320
|
-
description: string
|
|
1321
|
-
data: unknown
|
|
1322
|
-
}
|
|
1323
|
-
| {
|
|
1324
|
-
type: 'notify.focused'
|
|
1325
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
1326
|
-
}
|
|
1327
|
-
| {
|
|
1328
|
-
type: 'notify.invalid value'
|
|
1329
|
-
resolution: InvalidValueResolution | null
|
|
1330
|
-
value: Array<PortableTextBlock> | undefined
|
|
1331
|
-
}
|
|
1332
|
-
| {
|
|
1333
|
-
type: 'notify.loading'
|
|
1334
|
-
}
|
|
1335
|
-
| {
|
|
1336
|
-
type: 'notify.read only'
|
|
1337
|
-
}
|
|
1338
|
-
| {
|
|
1339
|
-
type: 'notify.ready'
|
|
1340
|
-
}
|
|
1341
|
-
| {
|
|
1342
|
-
type: 'notify.selection'
|
|
1343
|
-
selection: EditorSelection
|
|
1344
|
-
}
|
|
1345
|
-
| {
|
|
1346
|
-
type: 'notify.value changed'
|
|
1347
|
-
value: Array<PortableTextBlock> | undefined
|
|
1348
|
-
}
|
|
1349
|
-
| {
|
|
1350
|
-
type: 'notify.unset'
|
|
1351
|
-
previousValue: Array<PortableTextBlock>
|
|
1352
|
-
}
|
|
1353
1220
|
| {
|
|
1354
1221
|
type: 'dragstart'
|
|
1355
1222
|
origin: Pick<EventPosition, 'selection'>
|
|
@@ -1375,14 +1242,6 @@ declare const editorMachine: StateMachine<
|
|
|
1375
1242
|
type: 'update readOnly'
|
|
1376
1243
|
readOnly: boolean
|
|
1377
1244
|
}
|
|
1378
|
-
| {
|
|
1379
|
-
type: 'update schema'
|
|
1380
|
-
schema: EditorSchema
|
|
1381
|
-
}
|
|
1382
|
-
| {
|
|
1383
|
-
type: 'update key generator'
|
|
1384
|
-
keyGenerator: () => string
|
|
1385
|
-
}
|
|
1386
1245
|
| {
|
|
1387
1246
|
type: 'update maxBlocks'
|
|
1388
1247
|
maxBlocks: number | undefined
|
|
@@ -1406,6 +1265,10 @@ declare const editorMachine: StateMachine<
|
|
|
1406
1265
|
| {
|
|
1407
1266
|
type: 'normalizing'
|
|
1408
1267
|
}
|
|
1268
|
+
| {
|
|
1269
|
+
type: 'update selection'
|
|
1270
|
+
selection: EditorSelection
|
|
1271
|
+
}
|
|
1409
1272
|
| {
|
|
1410
1273
|
type: 'done normalizing'
|
|
1411
1274
|
}
|
|
@@ -1423,62 +1286,6 @@ declare const editorMachine: StateMachine<
|
|
|
1423
1286
|
preventDefault: () => void
|
|
1424
1287
|
}
|
|
1425
1288
|
}
|
|
1426
|
-
| {
|
|
1427
|
-
type: 'notify.patch'
|
|
1428
|
-
patch: Patch
|
|
1429
|
-
}
|
|
1430
|
-
| {
|
|
1431
|
-
type: 'notify.mutation'
|
|
1432
|
-
patches: Array<Patch>
|
|
1433
|
-
snapshot: Array<PortableTextBlock> | undefined
|
|
1434
|
-
value: Array<PortableTextBlock> | undefined
|
|
1435
|
-
}
|
|
1436
|
-
| {
|
|
1437
|
-
type: 'notify.blurred'
|
|
1438
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
1439
|
-
}
|
|
1440
|
-
| {
|
|
1441
|
-
type: 'notify.done loading'
|
|
1442
|
-
}
|
|
1443
|
-
| {
|
|
1444
|
-
type: 'notify.editable'
|
|
1445
|
-
}
|
|
1446
|
-
| {
|
|
1447
|
-
type: 'notify.error'
|
|
1448
|
-
name: string
|
|
1449
|
-
description: string
|
|
1450
|
-
data: unknown
|
|
1451
|
-
}
|
|
1452
|
-
| {
|
|
1453
|
-
type: 'notify.focused'
|
|
1454
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
1455
|
-
}
|
|
1456
|
-
| {
|
|
1457
|
-
type: 'notify.invalid value'
|
|
1458
|
-
resolution: InvalidValueResolution | null
|
|
1459
|
-
value: Array<PortableTextBlock> | undefined
|
|
1460
|
-
}
|
|
1461
|
-
| {
|
|
1462
|
-
type: 'notify.loading'
|
|
1463
|
-
}
|
|
1464
|
-
| {
|
|
1465
|
-
type: 'notify.read only'
|
|
1466
|
-
}
|
|
1467
|
-
| {
|
|
1468
|
-
type: 'notify.ready'
|
|
1469
|
-
}
|
|
1470
|
-
| {
|
|
1471
|
-
type: 'notify.selection'
|
|
1472
|
-
selection: EditorSelection
|
|
1473
|
-
}
|
|
1474
|
-
| {
|
|
1475
|
-
type: 'notify.value changed'
|
|
1476
|
-
value: Array<PortableTextBlock> | undefined
|
|
1477
|
-
}
|
|
1478
|
-
| {
|
|
1479
|
-
type: 'notify.unset'
|
|
1480
|
-
previousValue: Array<PortableTextBlock>
|
|
1481
|
-
}
|
|
1482
1289
|
| {
|
|
1483
1290
|
type: 'dragstart'
|
|
1484
1291
|
origin: Pick<EventPosition, 'selection'>
|
|
@@ -1506,7 +1313,13 @@ declare const editorMachine: StateMachine<
|
|
|
1506
1313
|
initialValue: PortableTextBlock[] | undefined
|
|
1507
1314
|
}
|
|
1508
1315
|
readonly on: {
|
|
1509
|
-
readonly '
|
|
1316
|
+
readonly 'add behavior': {
|
|
1317
|
+
readonly actions: 'add behavior to context'
|
|
1318
|
+
}
|
|
1319
|
+
readonly 'remove behavior': {
|
|
1320
|
+
readonly actions: 'remove behavior from context'
|
|
1321
|
+
}
|
|
1322
|
+
readonly 'update maxBlocks': {
|
|
1510
1323
|
readonly actions: ActionFunction<
|
|
1511
1324
|
{
|
|
1512
1325
|
behaviors: Set<BehaviorConfig>
|
|
@@ -1527,8 +1340,8 @@ declare const editorMachine: StateMachine<
|
|
|
1527
1340
|
slateEditor?: PortableTextSlateEditor
|
|
1528
1341
|
},
|
|
1529
1342
|
{
|
|
1530
|
-
type: '
|
|
1531
|
-
|
|
1343
|
+
type: 'update maxBlocks'
|
|
1344
|
+
maxBlocks: number | undefined
|
|
1532
1345
|
},
|
|
1533
1346
|
| InternalPatchEvent
|
|
1534
1347
|
| MutationEvent
|
|
@@ -1537,14 +1350,6 @@ declare const editorMachine: StateMachine<
|
|
|
1537
1350
|
type: 'update readOnly'
|
|
1538
1351
|
readOnly: boolean
|
|
1539
1352
|
}
|
|
1540
|
-
| {
|
|
1541
|
-
type: 'update schema'
|
|
1542
|
-
schema: EditorSchema
|
|
1543
|
-
}
|
|
1544
|
-
| {
|
|
1545
|
-
type: 'update key generator'
|
|
1546
|
-
keyGenerator: () => string
|
|
1547
|
-
}
|
|
1548
1353
|
| {
|
|
1549
1354
|
type: 'update maxBlocks'
|
|
1550
1355
|
maxBlocks: number | undefined
|
|
@@ -1568,6 +1373,10 @@ declare const editorMachine: StateMachine<
|
|
|
1568
1373
|
| {
|
|
1569
1374
|
type: 'normalizing'
|
|
1570
1375
|
}
|
|
1376
|
+
| {
|
|
1377
|
+
type: 'update selection'
|
|
1378
|
+
selection: EditorSelection
|
|
1379
|
+
}
|
|
1571
1380
|
| {
|
|
1572
1381
|
type: 'done normalizing'
|
|
1573
1382
|
}
|
|
@@ -1585,62 +1394,6 @@ declare const editorMachine: StateMachine<
|
|
|
1585
1394
|
preventDefault: () => void
|
|
1586
1395
|
}
|
|
1587
1396
|
}
|
|
1588
|
-
| {
|
|
1589
|
-
type: 'notify.patch'
|
|
1590
|
-
patch: Patch
|
|
1591
|
-
}
|
|
1592
|
-
| {
|
|
1593
|
-
type: 'notify.mutation'
|
|
1594
|
-
patches: Array<Patch>
|
|
1595
|
-
snapshot: Array<PortableTextBlock> | undefined
|
|
1596
|
-
value: Array<PortableTextBlock> | undefined
|
|
1597
|
-
}
|
|
1598
|
-
| {
|
|
1599
|
-
type: 'notify.blurred'
|
|
1600
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
1601
|
-
}
|
|
1602
|
-
| {
|
|
1603
|
-
type: 'notify.done loading'
|
|
1604
|
-
}
|
|
1605
|
-
| {
|
|
1606
|
-
type: 'notify.editable'
|
|
1607
|
-
}
|
|
1608
|
-
| {
|
|
1609
|
-
type: 'notify.error'
|
|
1610
|
-
name: string
|
|
1611
|
-
description: string
|
|
1612
|
-
data: unknown
|
|
1613
|
-
}
|
|
1614
|
-
| {
|
|
1615
|
-
type: 'notify.focused'
|
|
1616
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
1617
|
-
}
|
|
1618
|
-
| {
|
|
1619
|
-
type: 'notify.invalid value'
|
|
1620
|
-
resolution: InvalidValueResolution | null
|
|
1621
|
-
value: Array<PortableTextBlock> | undefined
|
|
1622
|
-
}
|
|
1623
|
-
| {
|
|
1624
|
-
type: 'notify.loading'
|
|
1625
|
-
}
|
|
1626
|
-
| {
|
|
1627
|
-
type: 'notify.read only'
|
|
1628
|
-
}
|
|
1629
|
-
| {
|
|
1630
|
-
type: 'notify.ready'
|
|
1631
|
-
}
|
|
1632
|
-
| {
|
|
1633
|
-
type: 'notify.selection'
|
|
1634
|
-
selection: EditorSelection
|
|
1635
|
-
}
|
|
1636
|
-
| {
|
|
1637
|
-
type: 'notify.value changed'
|
|
1638
|
-
value: Array<PortableTextBlock> | undefined
|
|
1639
|
-
}
|
|
1640
|
-
| {
|
|
1641
|
-
type: 'notify.unset'
|
|
1642
|
-
previousValue: Array<PortableTextBlock>
|
|
1643
|
-
}
|
|
1644
1397
|
| {
|
|
1645
1398
|
type: 'dragstart'
|
|
1646
1399
|
origin: Pick<EventPosition, 'selection'>
|
|
@@ -1657,2126 +1410,104 @@ declare const editorMachine: StateMachine<
|
|
|
1657
1410
|
never,
|
|
1658
1411
|
never,
|
|
1659
1412
|
never,
|
|
1660
|
-
|
|
1661
|
-
| InternalPatchEvent
|
|
1662
|
-
| MutationEvent
|
|
1663
|
-
| PatchesEvent
|
|
1664
|
-
| {
|
|
1665
|
-
type: 'blurred'
|
|
1666
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
1667
|
-
}
|
|
1668
|
-
| {
|
|
1669
|
-
type: 'done loading'
|
|
1670
|
-
}
|
|
1671
|
-
| {
|
|
1672
|
-
type: 'editable'
|
|
1673
|
-
}
|
|
1674
|
-
| {
|
|
1675
|
-
type: 'error'
|
|
1676
|
-
name: string
|
|
1677
|
-
description: string
|
|
1678
|
-
data: unknown
|
|
1679
|
-
}
|
|
1680
|
-
| {
|
|
1681
|
-
type: 'focused'
|
|
1682
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
1683
|
-
}
|
|
1684
|
-
| {
|
|
1685
|
-
type: 'invalid value'
|
|
1686
|
-
resolution: InvalidValueResolution | null
|
|
1687
|
-
value: Array<PortableTextBlock> | undefined
|
|
1688
|
-
}
|
|
1689
|
-
| {
|
|
1690
|
-
type: 'loading'
|
|
1691
|
-
}
|
|
1692
|
-
| {
|
|
1693
|
-
type: 'read only'
|
|
1694
|
-
}
|
|
1695
|
-
| {
|
|
1696
|
-
type: 'ready'
|
|
1697
|
-
}
|
|
1698
|
-
| {
|
|
1699
|
-
type: 'selection'
|
|
1700
|
-
selection: EditorSelection
|
|
1701
|
-
}
|
|
1702
|
-
| {
|
|
1703
|
-
type: 'value changed'
|
|
1704
|
-
value: Array<PortableTextBlock> | undefined
|
|
1705
|
-
}
|
|
1706
|
-
| UnsetEvent
|
|
1413
|
+
never
|
|
1707
1414
|
>
|
|
1708
1415
|
}
|
|
1709
|
-
readonly '
|
|
1710
|
-
readonly actions:
|
|
1711
|
-
|
|
1712
|
-
|
|
1713
|
-
|
|
1714
|
-
|
|
1715
|
-
|
|
1716
|
-
pendingEvents: Array<InternalPatchEvent | MutationEvent>
|
|
1717
|
-
pendingIncomingPatchesEvents: Array<PatchesEvent>
|
|
1718
|
-
schema: EditorSchema
|
|
1719
|
-
initialReadOnly: boolean
|
|
1720
|
-
maxBlocks: number | undefined
|
|
1721
|
-
selection: EditorSelection
|
|
1722
|
-
initialValue: Array<PortableTextBlock> | undefined
|
|
1723
|
-
internalDrag?: {
|
|
1724
|
-
ghost?: HTMLElement
|
|
1725
|
-
origin: Pick<EventPosition, 'selection'>
|
|
1726
|
-
}
|
|
1727
|
-
slateEditor?: PortableTextSlateEditor
|
|
1728
|
-
},
|
|
1729
|
-
{
|
|
1730
|
-
type: 'notify.done loading'
|
|
1731
|
-
},
|
|
1732
|
-
| InternalPatchEvent
|
|
1733
|
-
| MutationEvent
|
|
1734
|
-
| PatchesEvent
|
|
1735
|
-
| {
|
|
1736
|
-
type: 'update readOnly'
|
|
1737
|
-
readOnly: boolean
|
|
1738
|
-
}
|
|
1739
|
-
| {
|
|
1740
|
-
type: 'update schema'
|
|
1741
|
-
schema: EditorSchema
|
|
1742
|
-
}
|
|
1743
|
-
| {
|
|
1744
|
-
type: 'update key generator'
|
|
1416
|
+
readonly 'update selection': {
|
|
1417
|
+
readonly actions: readonly [
|
|
1418
|
+
ActionFunction<
|
|
1419
|
+
{
|
|
1420
|
+
behaviors: Set<BehaviorConfig>
|
|
1421
|
+
converters: Set<Converter>
|
|
1422
|
+
getLegacySchema: () => PortableTextMemberSchemaTypes
|
|
1745
1423
|
keyGenerator: () => string
|
|
1746
|
-
|
|
1747
|
-
|
|
1748
|
-
type: 'update maxBlocks'
|
|
1749
|
-
maxBlocks: number | undefined
|
|
1750
|
-
}
|
|
1751
|
-
| {
|
|
1752
|
-
type: 'add behavior'
|
|
1753
|
-
behaviorConfig: BehaviorConfig
|
|
1754
|
-
}
|
|
1755
|
-
| {
|
|
1756
|
-
type: 'remove behavior'
|
|
1757
|
-
behaviorConfig: BehaviorConfig
|
|
1758
|
-
}
|
|
1759
|
-
| {
|
|
1760
|
-
type: 'blur'
|
|
1761
|
-
editor: PortableTextSlateEditor
|
|
1762
|
-
}
|
|
1763
|
-
| {
|
|
1764
|
-
type: 'focus'
|
|
1765
|
-
editor: PortableTextSlateEditor
|
|
1766
|
-
}
|
|
1767
|
-
| {
|
|
1768
|
-
type: 'normalizing'
|
|
1769
|
-
}
|
|
1770
|
-
| {
|
|
1771
|
-
type: 'done normalizing'
|
|
1772
|
-
}
|
|
1773
|
-
| {
|
|
1774
|
-
type: 'done syncing value'
|
|
1775
|
-
}
|
|
1776
|
-
| {
|
|
1777
|
-
type: 'syncing value'
|
|
1778
|
-
}
|
|
1779
|
-
| {
|
|
1780
|
-
type: 'behavior event'
|
|
1781
|
-
behaviorEvent: BehaviorEvent
|
|
1782
|
-
editor: PortableTextSlateEditor
|
|
1783
|
-
nativeEvent?: {
|
|
1784
|
-
preventDefault: () => void
|
|
1785
|
-
}
|
|
1786
|
-
}
|
|
1787
|
-
| {
|
|
1788
|
-
type: 'notify.patch'
|
|
1789
|
-
patch: Patch
|
|
1790
|
-
}
|
|
1791
|
-
| {
|
|
1792
|
-
type: 'notify.mutation'
|
|
1793
|
-
patches: Array<Patch>
|
|
1794
|
-
snapshot: Array<PortableTextBlock> | undefined
|
|
1795
|
-
value: Array<PortableTextBlock> | undefined
|
|
1796
|
-
}
|
|
1797
|
-
| {
|
|
1798
|
-
type: 'notify.blurred'
|
|
1799
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
1800
|
-
}
|
|
1801
|
-
| {
|
|
1802
|
-
type: 'notify.done loading'
|
|
1803
|
-
}
|
|
1804
|
-
| {
|
|
1805
|
-
type: 'notify.editable'
|
|
1806
|
-
}
|
|
1807
|
-
| {
|
|
1808
|
-
type: 'notify.error'
|
|
1809
|
-
name: string
|
|
1810
|
-
description: string
|
|
1811
|
-
data: unknown
|
|
1812
|
-
}
|
|
1813
|
-
| {
|
|
1814
|
-
type: 'notify.focused'
|
|
1815
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
1816
|
-
}
|
|
1817
|
-
| {
|
|
1818
|
-
type: 'notify.invalid value'
|
|
1819
|
-
resolution: InvalidValueResolution | null
|
|
1820
|
-
value: Array<PortableTextBlock> | undefined
|
|
1821
|
-
}
|
|
1822
|
-
| {
|
|
1823
|
-
type: 'notify.loading'
|
|
1824
|
-
}
|
|
1825
|
-
| {
|
|
1826
|
-
type: 'notify.read only'
|
|
1827
|
-
}
|
|
1828
|
-
| {
|
|
1829
|
-
type: 'notify.ready'
|
|
1830
|
-
}
|
|
1831
|
-
| {
|
|
1832
|
-
type: 'notify.selection'
|
|
1833
|
-
selection: EditorSelection
|
|
1834
|
-
}
|
|
1835
|
-
| {
|
|
1836
|
-
type: 'notify.value changed'
|
|
1837
|
-
value: Array<PortableTextBlock> | undefined
|
|
1838
|
-
}
|
|
1839
|
-
| {
|
|
1840
|
-
type: 'notify.unset'
|
|
1841
|
-
previousValue: Array<PortableTextBlock>
|
|
1842
|
-
}
|
|
1843
|
-
| {
|
|
1844
|
-
type: 'dragstart'
|
|
1845
|
-
origin: Pick<EventPosition, 'selection'>
|
|
1846
|
-
ghost?: HTMLElement
|
|
1847
|
-
}
|
|
1848
|
-
| {
|
|
1849
|
-
type: 'dragend'
|
|
1850
|
-
}
|
|
1851
|
-
| {
|
|
1852
|
-
type: 'drop'
|
|
1853
|
-
},
|
|
1854
|
-
undefined,
|
|
1855
|
-
never,
|
|
1856
|
-
never,
|
|
1857
|
-
never,
|
|
1858
|
-
never,
|
|
1859
|
-
| PatchEvent
|
|
1860
|
-
| InternalPatchEvent
|
|
1861
|
-
| MutationEvent
|
|
1862
|
-
| PatchesEvent
|
|
1863
|
-
| {
|
|
1864
|
-
type: 'blurred'
|
|
1865
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
1866
|
-
}
|
|
1867
|
-
| {
|
|
1868
|
-
type: 'done loading'
|
|
1869
|
-
}
|
|
1870
|
-
| {
|
|
1871
|
-
type: 'editable'
|
|
1872
|
-
}
|
|
1873
|
-
| {
|
|
1874
|
-
type: 'error'
|
|
1875
|
-
name: string
|
|
1876
|
-
description: string
|
|
1877
|
-
data: unknown
|
|
1878
|
-
}
|
|
1879
|
-
| {
|
|
1880
|
-
type: 'focused'
|
|
1881
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
1882
|
-
}
|
|
1883
|
-
| {
|
|
1884
|
-
type: 'invalid value'
|
|
1885
|
-
resolution: InvalidValueResolution | null
|
|
1886
|
-
value: Array<PortableTextBlock> | undefined
|
|
1887
|
-
}
|
|
1888
|
-
| {
|
|
1889
|
-
type: 'loading'
|
|
1890
|
-
}
|
|
1891
|
-
| {
|
|
1892
|
-
type: 'read only'
|
|
1893
|
-
}
|
|
1894
|
-
| {
|
|
1895
|
-
type: 'ready'
|
|
1896
|
-
}
|
|
1897
|
-
| {
|
|
1898
|
-
type: 'selection'
|
|
1899
|
-
selection: EditorSelection
|
|
1900
|
-
}
|
|
1901
|
-
| {
|
|
1902
|
-
type: 'value changed'
|
|
1903
|
-
value: Array<PortableTextBlock> | undefined
|
|
1904
|
-
}
|
|
1905
|
-
| UnsetEvent
|
|
1906
|
-
>
|
|
1907
|
-
}
|
|
1908
|
-
readonly 'notify.error': {
|
|
1909
|
-
readonly actions: ActionFunction<
|
|
1910
|
-
{
|
|
1911
|
-
behaviors: Set<BehaviorConfig>
|
|
1912
|
-
converters: Set<Converter>
|
|
1913
|
-
getLegacySchema: () => PortableTextMemberSchemaTypes
|
|
1914
|
-
keyGenerator: () => string
|
|
1915
|
-
pendingEvents: Array<InternalPatchEvent | MutationEvent>
|
|
1916
|
-
pendingIncomingPatchesEvents: Array<PatchesEvent>
|
|
1917
|
-
schema: EditorSchema
|
|
1918
|
-
initialReadOnly: boolean
|
|
1919
|
-
maxBlocks: number | undefined
|
|
1920
|
-
selection: EditorSelection
|
|
1921
|
-
initialValue: Array<PortableTextBlock> | undefined
|
|
1922
|
-
internalDrag?: {
|
|
1923
|
-
ghost?: HTMLElement
|
|
1924
|
-
origin: Pick<EventPosition, 'selection'>
|
|
1925
|
-
}
|
|
1926
|
-
slateEditor?: PortableTextSlateEditor
|
|
1927
|
-
},
|
|
1928
|
-
{
|
|
1929
|
-
type: 'notify.error'
|
|
1930
|
-
name: string
|
|
1931
|
-
description: string
|
|
1932
|
-
data: unknown
|
|
1933
|
-
},
|
|
1934
|
-
| InternalPatchEvent
|
|
1935
|
-
| MutationEvent
|
|
1936
|
-
| PatchesEvent
|
|
1937
|
-
| {
|
|
1938
|
-
type: 'update readOnly'
|
|
1939
|
-
readOnly: boolean
|
|
1940
|
-
}
|
|
1941
|
-
| {
|
|
1942
|
-
type: 'update schema'
|
|
1943
|
-
schema: EditorSchema
|
|
1944
|
-
}
|
|
1945
|
-
| {
|
|
1946
|
-
type: 'update key generator'
|
|
1947
|
-
keyGenerator: () => string
|
|
1948
|
-
}
|
|
1949
|
-
| {
|
|
1950
|
-
type: 'update maxBlocks'
|
|
1951
|
-
maxBlocks: number | undefined
|
|
1952
|
-
}
|
|
1953
|
-
| {
|
|
1954
|
-
type: 'add behavior'
|
|
1955
|
-
behaviorConfig: BehaviorConfig
|
|
1956
|
-
}
|
|
1957
|
-
| {
|
|
1958
|
-
type: 'remove behavior'
|
|
1959
|
-
behaviorConfig: BehaviorConfig
|
|
1960
|
-
}
|
|
1961
|
-
| {
|
|
1962
|
-
type: 'blur'
|
|
1963
|
-
editor: PortableTextSlateEditor
|
|
1964
|
-
}
|
|
1965
|
-
| {
|
|
1966
|
-
type: 'focus'
|
|
1967
|
-
editor: PortableTextSlateEditor
|
|
1968
|
-
}
|
|
1969
|
-
| {
|
|
1970
|
-
type: 'normalizing'
|
|
1971
|
-
}
|
|
1972
|
-
| {
|
|
1973
|
-
type: 'done normalizing'
|
|
1974
|
-
}
|
|
1975
|
-
| {
|
|
1976
|
-
type: 'done syncing value'
|
|
1977
|
-
}
|
|
1978
|
-
| {
|
|
1979
|
-
type: 'syncing value'
|
|
1980
|
-
}
|
|
1981
|
-
| {
|
|
1982
|
-
type: 'behavior event'
|
|
1983
|
-
behaviorEvent: BehaviorEvent
|
|
1984
|
-
editor: PortableTextSlateEditor
|
|
1985
|
-
nativeEvent?: {
|
|
1986
|
-
preventDefault: () => void
|
|
1987
|
-
}
|
|
1988
|
-
}
|
|
1989
|
-
| {
|
|
1990
|
-
type: 'notify.patch'
|
|
1991
|
-
patch: Patch
|
|
1992
|
-
}
|
|
1993
|
-
| {
|
|
1994
|
-
type: 'notify.mutation'
|
|
1995
|
-
patches: Array<Patch>
|
|
1996
|
-
snapshot: Array<PortableTextBlock> | undefined
|
|
1997
|
-
value: Array<PortableTextBlock> | undefined
|
|
1998
|
-
}
|
|
1999
|
-
| {
|
|
2000
|
-
type: 'notify.blurred'
|
|
2001
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
2002
|
-
}
|
|
2003
|
-
| {
|
|
2004
|
-
type: 'notify.done loading'
|
|
2005
|
-
}
|
|
2006
|
-
| {
|
|
2007
|
-
type: 'notify.editable'
|
|
2008
|
-
}
|
|
2009
|
-
| {
|
|
2010
|
-
type: 'notify.error'
|
|
2011
|
-
name: string
|
|
2012
|
-
description: string
|
|
2013
|
-
data: unknown
|
|
2014
|
-
}
|
|
2015
|
-
| {
|
|
2016
|
-
type: 'notify.focused'
|
|
2017
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
2018
|
-
}
|
|
2019
|
-
| {
|
|
2020
|
-
type: 'notify.invalid value'
|
|
2021
|
-
resolution: InvalidValueResolution | null
|
|
2022
|
-
value: Array<PortableTextBlock> | undefined
|
|
2023
|
-
}
|
|
2024
|
-
| {
|
|
2025
|
-
type: 'notify.loading'
|
|
2026
|
-
}
|
|
2027
|
-
| {
|
|
2028
|
-
type: 'notify.read only'
|
|
2029
|
-
}
|
|
2030
|
-
| {
|
|
2031
|
-
type: 'notify.ready'
|
|
2032
|
-
}
|
|
2033
|
-
| {
|
|
2034
|
-
type: 'notify.selection'
|
|
2035
|
-
selection: EditorSelection
|
|
2036
|
-
}
|
|
2037
|
-
| {
|
|
2038
|
-
type: 'notify.value changed'
|
|
2039
|
-
value: Array<PortableTextBlock> | undefined
|
|
2040
|
-
}
|
|
2041
|
-
| {
|
|
2042
|
-
type: 'notify.unset'
|
|
2043
|
-
previousValue: Array<PortableTextBlock>
|
|
2044
|
-
}
|
|
2045
|
-
| {
|
|
2046
|
-
type: 'dragstart'
|
|
2047
|
-
origin: Pick<EventPosition, 'selection'>
|
|
2048
|
-
ghost?: HTMLElement
|
|
2049
|
-
}
|
|
2050
|
-
| {
|
|
2051
|
-
type: 'dragend'
|
|
2052
|
-
}
|
|
2053
|
-
| {
|
|
2054
|
-
type: 'drop'
|
|
2055
|
-
},
|
|
2056
|
-
undefined,
|
|
2057
|
-
never,
|
|
2058
|
-
never,
|
|
2059
|
-
never,
|
|
2060
|
-
never,
|
|
2061
|
-
| PatchEvent
|
|
2062
|
-
| InternalPatchEvent
|
|
2063
|
-
| MutationEvent
|
|
2064
|
-
| PatchesEvent
|
|
2065
|
-
| {
|
|
2066
|
-
type: 'blurred'
|
|
2067
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
2068
|
-
}
|
|
2069
|
-
| {
|
|
2070
|
-
type: 'done loading'
|
|
2071
|
-
}
|
|
2072
|
-
| {
|
|
2073
|
-
type: 'editable'
|
|
2074
|
-
}
|
|
2075
|
-
| {
|
|
2076
|
-
type: 'error'
|
|
2077
|
-
name: string
|
|
2078
|
-
description: string
|
|
2079
|
-
data: unknown
|
|
2080
|
-
}
|
|
2081
|
-
| {
|
|
2082
|
-
type: 'focused'
|
|
2083
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
2084
|
-
}
|
|
2085
|
-
| {
|
|
2086
|
-
type: 'invalid value'
|
|
2087
|
-
resolution: InvalidValueResolution | null
|
|
2088
|
-
value: Array<PortableTextBlock> | undefined
|
|
2089
|
-
}
|
|
2090
|
-
| {
|
|
2091
|
-
type: 'loading'
|
|
2092
|
-
}
|
|
2093
|
-
| {
|
|
2094
|
-
type: 'read only'
|
|
2095
|
-
}
|
|
2096
|
-
| {
|
|
2097
|
-
type: 'ready'
|
|
2098
|
-
}
|
|
2099
|
-
| {
|
|
2100
|
-
type: 'selection'
|
|
2101
|
-
selection: EditorSelection
|
|
2102
|
-
}
|
|
2103
|
-
| {
|
|
2104
|
-
type: 'value changed'
|
|
2105
|
-
value: Array<PortableTextBlock> | undefined
|
|
2106
|
-
}
|
|
2107
|
-
| UnsetEvent
|
|
2108
|
-
>
|
|
2109
|
-
}
|
|
2110
|
-
readonly 'notify.invalid value': {
|
|
2111
|
-
readonly actions: ActionFunction<
|
|
2112
|
-
{
|
|
2113
|
-
behaviors: Set<BehaviorConfig>
|
|
2114
|
-
converters: Set<Converter>
|
|
2115
|
-
getLegacySchema: () => PortableTextMemberSchemaTypes
|
|
2116
|
-
keyGenerator: () => string
|
|
2117
|
-
pendingEvents: Array<InternalPatchEvent | MutationEvent>
|
|
2118
|
-
pendingIncomingPatchesEvents: Array<PatchesEvent>
|
|
2119
|
-
schema: EditorSchema
|
|
2120
|
-
initialReadOnly: boolean
|
|
2121
|
-
maxBlocks: number | undefined
|
|
2122
|
-
selection: EditorSelection
|
|
2123
|
-
initialValue: Array<PortableTextBlock> | undefined
|
|
2124
|
-
internalDrag?: {
|
|
2125
|
-
ghost?: HTMLElement
|
|
2126
|
-
origin: Pick<EventPosition, 'selection'>
|
|
2127
|
-
}
|
|
2128
|
-
slateEditor?: PortableTextSlateEditor
|
|
2129
|
-
},
|
|
2130
|
-
{
|
|
2131
|
-
type: 'notify.invalid value'
|
|
2132
|
-
resolution: InvalidValueResolution | null
|
|
2133
|
-
value: Array<PortableTextBlock> | undefined
|
|
2134
|
-
},
|
|
2135
|
-
| InternalPatchEvent
|
|
2136
|
-
| MutationEvent
|
|
2137
|
-
| PatchesEvent
|
|
2138
|
-
| {
|
|
2139
|
-
type: 'update readOnly'
|
|
2140
|
-
readOnly: boolean
|
|
2141
|
-
}
|
|
2142
|
-
| {
|
|
2143
|
-
type: 'update schema'
|
|
2144
|
-
schema: EditorSchema
|
|
2145
|
-
}
|
|
2146
|
-
| {
|
|
2147
|
-
type: 'update key generator'
|
|
2148
|
-
keyGenerator: () => string
|
|
2149
|
-
}
|
|
2150
|
-
| {
|
|
2151
|
-
type: 'update maxBlocks'
|
|
2152
|
-
maxBlocks: number | undefined
|
|
2153
|
-
}
|
|
2154
|
-
| {
|
|
2155
|
-
type: 'add behavior'
|
|
2156
|
-
behaviorConfig: BehaviorConfig
|
|
2157
|
-
}
|
|
2158
|
-
| {
|
|
2159
|
-
type: 'remove behavior'
|
|
2160
|
-
behaviorConfig: BehaviorConfig
|
|
2161
|
-
}
|
|
2162
|
-
| {
|
|
2163
|
-
type: 'blur'
|
|
2164
|
-
editor: PortableTextSlateEditor
|
|
2165
|
-
}
|
|
2166
|
-
| {
|
|
2167
|
-
type: 'focus'
|
|
2168
|
-
editor: PortableTextSlateEditor
|
|
2169
|
-
}
|
|
2170
|
-
| {
|
|
2171
|
-
type: 'normalizing'
|
|
2172
|
-
}
|
|
2173
|
-
| {
|
|
2174
|
-
type: 'done normalizing'
|
|
2175
|
-
}
|
|
2176
|
-
| {
|
|
2177
|
-
type: 'done syncing value'
|
|
2178
|
-
}
|
|
2179
|
-
| {
|
|
2180
|
-
type: 'syncing value'
|
|
2181
|
-
}
|
|
2182
|
-
| {
|
|
2183
|
-
type: 'behavior event'
|
|
2184
|
-
behaviorEvent: BehaviorEvent
|
|
2185
|
-
editor: PortableTextSlateEditor
|
|
2186
|
-
nativeEvent?: {
|
|
2187
|
-
preventDefault: () => void
|
|
2188
|
-
}
|
|
2189
|
-
}
|
|
2190
|
-
| {
|
|
2191
|
-
type: 'notify.patch'
|
|
2192
|
-
patch: Patch
|
|
2193
|
-
}
|
|
2194
|
-
| {
|
|
2195
|
-
type: 'notify.mutation'
|
|
2196
|
-
patches: Array<Patch>
|
|
2197
|
-
snapshot: Array<PortableTextBlock> | undefined
|
|
2198
|
-
value: Array<PortableTextBlock> | undefined
|
|
2199
|
-
}
|
|
2200
|
-
| {
|
|
2201
|
-
type: 'notify.blurred'
|
|
2202
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
2203
|
-
}
|
|
2204
|
-
| {
|
|
2205
|
-
type: 'notify.done loading'
|
|
2206
|
-
}
|
|
2207
|
-
| {
|
|
2208
|
-
type: 'notify.editable'
|
|
2209
|
-
}
|
|
2210
|
-
| {
|
|
2211
|
-
type: 'notify.error'
|
|
2212
|
-
name: string
|
|
2213
|
-
description: string
|
|
2214
|
-
data: unknown
|
|
2215
|
-
}
|
|
2216
|
-
| {
|
|
2217
|
-
type: 'notify.focused'
|
|
2218
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
2219
|
-
}
|
|
2220
|
-
| {
|
|
2221
|
-
type: 'notify.invalid value'
|
|
2222
|
-
resolution: InvalidValueResolution | null
|
|
2223
|
-
value: Array<PortableTextBlock> | undefined
|
|
2224
|
-
}
|
|
2225
|
-
| {
|
|
2226
|
-
type: 'notify.loading'
|
|
2227
|
-
}
|
|
2228
|
-
| {
|
|
2229
|
-
type: 'notify.read only'
|
|
2230
|
-
}
|
|
2231
|
-
| {
|
|
2232
|
-
type: 'notify.ready'
|
|
2233
|
-
}
|
|
2234
|
-
| {
|
|
2235
|
-
type: 'notify.selection'
|
|
2236
|
-
selection: EditorSelection
|
|
2237
|
-
}
|
|
2238
|
-
| {
|
|
2239
|
-
type: 'notify.value changed'
|
|
2240
|
-
value: Array<PortableTextBlock> | undefined
|
|
2241
|
-
}
|
|
2242
|
-
| {
|
|
2243
|
-
type: 'notify.unset'
|
|
2244
|
-
previousValue: Array<PortableTextBlock>
|
|
2245
|
-
}
|
|
2246
|
-
| {
|
|
2247
|
-
type: 'dragstart'
|
|
2248
|
-
origin: Pick<EventPosition, 'selection'>
|
|
2249
|
-
ghost?: HTMLElement
|
|
2250
|
-
}
|
|
2251
|
-
| {
|
|
2252
|
-
type: 'dragend'
|
|
2253
|
-
}
|
|
2254
|
-
| {
|
|
2255
|
-
type: 'drop'
|
|
2256
|
-
},
|
|
2257
|
-
undefined,
|
|
2258
|
-
never,
|
|
2259
|
-
never,
|
|
2260
|
-
never,
|
|
2261
|
-
never,
|
|
2262
|
-
| PatchEvent
|
|
2263
|
-
| InternalPatchEvent
|
|
2264
|
-
| MutationEvent
|
|
2265
|
-
| PatchesEvent
|
|
2266
|
-
| {
|
|
2267
|
-
type: 'blurred'
|
|
2268
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
2269
|
-
}
|
|
2270
|
-
| {
|
|
2271
|
-
type: 'done loading'
|
|
2272
|
-
}
|
|
2273
|
-
| {
|
|
2274
|
-
type: 'editable'
|
|
2275
|
-
}
|
|
2276
|
-
| {
|
|
2277
|
-
type: 'error'
|
|
2278
|
-
name: string
|
|
2279
|
-
description: string
|
|
2280
|
-
data: unknown
|
|
2281
|
-
}
|
|
2282
|
-
| {
|
|
2283
|
-
type: 'focused'
|
|
2284
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
2285
|
-
}
|
|
2286
|
-
| {
|
|
2287
|
-
type: 'invalid value'
|
|
2288
|
-
resolution: InvalidValueResolution | null
|
|
2289
|
-
value: Array<PortableTextBlock> | undefined
|
|
2290
|
-
}
|
|
2291
|
-
| {
|
|
2292
|
-
type: 'loading'
|
|
2293
|
-
}
|
|
2294
|
-
| {
|
|
2295
|
-
type: 'read only'
|
|
2296
|
-
}
|
|
2297
|
-
| {
|
|
2298
|
-
type: 'ready'
|
|
2299
|
-
}
|
|
2300
|
-
| {
|
|
2301
|
-
type: 'selection'
|
|
2302
|
-
selection: EditorSelection
|
|
2303
|
-
}
|
|
2304
|
-
| {
|
|
2305
|
-
type: 'value changed'
|
|
2306
|
-
value: Array<PortableTextBlock> | undefined
|
|
2307
|
-
}
|
|
2308
|
-
| UnsetEvent
|
|
2309
|
-
>
|
|
2310
|
-
}
|
|
2311
|
-
readonly 'notify.focused': {
|
|
2312
|
-
readonly actions: ActionFunction<
|
|
2313
|
-
{
|
|
2314
|
-
behaviors: Set<BehaviorConfig>
|
|
2315
|
-
converters: Set<Converter>
|
|
2316
|
-
getLegacySchema: () => PortableTextMemberSchemaTypes
|
|
2317
|
-
keyGenerator: () => string
|
|
2318
|
-
pendingEvents: Array<InternalPatchEvent | MutationEvent>
|
|
2319
|
-
pendingIncomingPatchesEvents: Array<PatchesEvent>
|
|
2320
|
-
schema: EditorSchema
|
|
2321
|
-
initialReadOnly: boolean
|
|
2322
|
-
maxBlocks: number | undefined
|
|
2323
|
-
selection: EditorSelection
|
|
2324
|
-
initialValue: Array<PortableTextBlock> | undefined
|
|
2325
|
-
internalDrag?: {
|
|
2326
|
-
ghost?: HTMLElement
|
|
2327
|
-
origin: Pick<EventPosition, 'selection'>
|
|
2328
|
-
}
|
|
2329
|
-
slateEditor?: PortableTextSlateEditor
|
|
2330
|
-
},
|
|
2331
|
-
{
|
|
2332
|
-
type: 'notify.focused'
|
|
2333
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
2334
|
-
},
|
|
2335
|
-
| InternalPatchEvent
|
|
2336
|
-
| MutationEvent
|
|
2337
|
-
| PatchesEvent
|
|
2338
|
-
| {
|
|
2339
|
-
type: 'update readOnly'
|
|
2340
|
-
readOnly: boolean
|
|
2341
|
-
}
|
|
2342
|
-
| {
|
|
2343
|
-
type: 'update schema'
|
|
2344
|
-
schema: EditorSchema
|
|
2345
|
-
}
|
|
2346
|
-
| {
|
|
2347
|
-
type: 'update key generator'
|
|
2348
|
-
keyGenerator: () => string
|
|
2349
|
-
}
|
|
2350
|
-
| {
|
|
2351
|
-
type: 'update maxBlocks'
|
|
2352
|
-
maxBlocks: number | undefined
|
|
2353
|
-
}
|
|
2354
|
-
| {
|
|
2355
|
-
type: 'add behavior'
|
|
2356
|
-
behaviorConfig: BehaviorConfig
|
|
2357
|
-
}
|
|
2358
|
-
| {
|
|
2359
|
-
type: 'remove behavior'
|
|
2360
|
-
behaviorConfig: BehaviorConfig
|
|
2361
|
-
}
|
|
2362
|
-
| {
|
|
2363
|
-
type: 'blur'
|
|
2364
|
-
editor: PortableTextSlateEditor
|
|
2365
|
-
}
|
|
2366
|
-
| {
|
|
2367
|
-
type: 'focus'
|
|
2368
|
-
editor: PortableTextSlateEditor
|
|
2369
|
-
}
|
|
2370
|
-
| {
|
|
2371
|
-
type: 'normalizing'
|
|
2372
|
-
}
|
|
2373
|
-
| {
|
|
2374
|
-
type: 'done normalizing'
|
|
2375
|
-
}
|
|
2376
|
-
| {
|
|
2377
|
-
type: 'done syncing value'
|
|
2378
|
-
}
|
|
2379
|
-
| {
|
|
2380
|
-
type: 'syncing value'
|
|
2381
|
-
}
|
|
2382
|
-
| {
|
|
2383
|
-
type: 'behavior event'
|
|
2384
|
-
behaviorEvent: BehaviorEvent
|
|
2385
|
-
editor: PortableTextSlateEditor
|
|
2386
|
-
nativeEvent?: {
|
|
2387
|
-
preventDefault: () => void
|
|
2388
|
-
}
|
|
2389
|
-
}
|
|
2390
|
-
| {
|
|
2391
|
-
type: 'notify.patch'
|
|
2392
|
-
patch: Patch
|
|
2393
|
-
}
|
|
2394
|
-
| {
|
|
2395
|
-
type: 'notify.mutation'
|
|
2396
|
-
patches: Array<Patch>
|
|
2397
|
-
snapshot: Array<PortableTextBlock> | undefined
|
|
2398
|
-
value: Array<PortableTextBlock> | undefined
|
|
2399
|
-
}
|
|
2400
|
-
| {
|
|
2401
|
-
type: 'notify.blurred'
|
|
2402
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
2403
|
-
}
|
|
2404
|
-
| {
|
|
2405
|
-
type: 'notify.done loading'
|
|
2406
|
-
}
|
|
2407
|
-
| {
|
|
2408
|
-
type: 'notify.editable'
|
|
2409
|
-
}
|
|
2410
|
-
| {
|
|
2411
|
-
type: 'notify.error'
|
|
2412
|
-
name: string
|
|
2413
|
-
description: string
|
|
2414
|
-
data: unknown
|
|
2415
|
-
}
|
|
2416
|
-
| {
|
|
2417
|
-
type: 'notify.focused'
|
|
2418
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
2419
|
-
}
|
|
2420
|
-
| {
|
|
2421
|
-
type: 'notify.invalid value'
|
|
2422
|
-
resolution: InvalidValueResolution | null
|
|
2423
|
-
value: Array<PortableTextBlock> | undefined
|
|
2424
|
-
}
|
|
2425
|
-
| {
|
|
2426
|
-
type: 'notify.loading'
|
|
2427
|
-
}
|
|
2428
|
-
| {
|
|
2429
|
-
type: 'notify.read only'
|
|
2430
|
-
}
|
|
2431
|
-
| {
|
|
2432
|
-
type: 'notify.ready'
|
|
2433
|
-
}
|
|
2434
|
-
| {
|
|
2435
|
-
type: 'notify.selection'
|
|
2436
|
-
selection: EditorSelection
|
|
2437
|
-
}
|
|
2438
|
-
| {
|
|
2439
|
-
type: 'notify.value changed'
|
|
2440
|
-
value: Array<PortableTextBlock> | undefined
|
|
2441
|
-
}
|
|
2442
|
-
| {
|
|
2443
|
-
type: 'notify.unset'
|
|
2444
|
-
previousValue: Array<PortableTextBlock>
|
|
2445
|
-
}
|
|
2446
|
-
| {
|
|
2447
|
-
type: 'dragstart'
|
|
2448
|
-
origin: Pick<EventPosition, 'selection'>
|
|
2449
|
-
ghost?: HTMLElement
|
|
2450
|
-
}
|
|
2451
|
-
| {
|
|
2452
|
-
type: 'dragend'
|
|
2453
|
-
}
|
|
2454
|
-
| {
|
|
2455
|
-
type: 'drop'
|
|
2456
|
-
},
|
|
2457
|
-
undefined,
|
|
2458
|
-
never,
|
|
2459
|
-
never,
|
|
2460
|
-
never,
|
|
2461
|
-
never,
|
|
2462
|
-
| PatchEvent
|
|
2463
|
-
| InternalPatchEvent
|
|
2464
|
-
| MutationEvent
|
|
2465
|
-
| PatchesEvent
|
|
2466
|
-
| {
|
|
2467
|
-
type: 'blurred'
|
|
2468
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
2469
|
-
}
|
|
2470
|
-
| {
|
|
2471
|
-
type: 'done loading'
|
|
2472
|
-
}
|
|
2473
|
-
| {
|
|
2474
|
-
type: 'editable'
|
|
2475
|
-
}
|
|
2476
|
-
| {
|
|
2477
|
-
type: 'error'
|
|
2478
|
-
name: string
|
|
2479
|
-
description: string
|
|
2480
|
-
data: unknown
|
|
2481
|
-
}
|
|
2482
|
-
| {
|
|
2483
|
-
type: 'focused'
|
|
2484
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
2485
|
-
}
|
|
2486
|
-
| {
|
|
2487
|
-
type: 'invalid value'
|
|
2488
|
-
resolution: InvalidValueResolution | null
|
|
2489
|
-
value: Array<PortableTextBlock> | undefined
|
|
2490
|
-
}
|
|
2491
|
-
| {
|
|
2492
|
-
type: 'loading'
|
|
2493
|
-
}
|
|
2494
|
-
| {
|
|
2495
|
-
type: 'read only'
|
|
2496
|
-
}
|
|
2497
|
-
| {
|
|
2498
|
-
type: 'ready'
|
|
2499
|
-
}
|
|
2500
|
-
| {
|
|
2501
|
-
type: 'selection'
|
|
2502
|
-
selection: EditorSelection
|
|
2503
|
-
}
|
|
2504
|
-
| {
|
|
2505
|
-
type: 'value changed'
|
|
2506
|
-
value: Array<PortableTextBlock> | undefined
|
|
2507
|
-
}
|
|
2508
|
-
| UnsetEvent
|
|
2509
|
-
>
|
|
2510
|
-
}
|
|
2511
|
-
readonly 'notify.selection': {
|
|
2512
|
-
readonly actions: readonly [
|
|
2513
|
-
ActionFunction<
|
|
2514
|
-
{
|
|
2515
|
-
behaviors: Set<BehaviorConfig>
|
|
2516
|
-
converters: Set<Converter>
|
|
2517
|
-
getLegacySchema: () => PortableTextMemberSchemaTypes
|
|
2518
|
-
keyGenerator: () => string
|
|
2519
|
-
pendingEvents: Array<InternalPatchEvent | MutationEvent>
|
|
2520
|
-
pendingIncomingPatchesEvents: Array<PatchesEvent>
|
|
2521
|
-
schema: EditorSchema
|
|
2522
|
-
initialReadOnly: boolean
|
|
2523
|
-
maxBlocks: number | undefined
|
|
2524
|
-
selection: EditorSelection
|
|
2525
|
-
initialValue: Array<PortableTextBlock> | undefined
|
|
2526
|
-
internalDrag?: {
|
|
2527
|
-
ghost?: HTMLElement
|
|
2528
|
-
origin: Pick<EventPosition, 'selection'>
|
|
2529
|
-
}
|
|
2530
|
-
slateEditor?: PortableTextSlateEditor
|
|
2531
|
-
},
|
|
2532
|
-
{
|
|
2533
|
-
type: 'notify.selection'
|
|
2534
|
-
selection: EditorSelection
|
|
2535
|
-
},
|
|
2536
|
-
| InternalPatchEvent
|
|
2537
|
-
| MutationEvent
|
|
2538
|
-
| PatchesEvent
|
|
2539
|
-
| {
|
|
2540
|
-
type: 'update readOnly'
|
|
2541
|
-
readOnly: boolean
|
|
2542
|
-
}
|
|
2543
|
-
| {
|
|
2544
|
-
type: 'update schema'
|
|
2545
|
-
schema: EditorSchema
|
|
2546
|
-
}
|
|
2547
|
-
| {
|
|
2548
|
-
type: 'update key generator'
|
|
2549
|
-
keyGenerator: () => string
|
|
2550
|
-
}
|
|
2551
|
-
| {
|
|
2552
|
-
type: 'update maxBlocks'
|
|
2553
|
-
maxBlocks: number | undefined
|
|
2554
|
-
}
|
|
2555
|
-
| {
|
|
2556
|
-
type: 'add behavior'
|
|
2557
|
-
behaviorConfig: BehaviorConfig
|
|
2558
|
-
}
|
|
2559
|
-
| {
|
|
2560
|
-
type: 'remove behavior'
|
|
2561
|
-
behaviorConfig: BehaviorConfig
|
|
2562
|
-
}
|
|
2563
|
-
| {
|
|
2564
|
-
type: 'blur'
|
|
2565
|
-
editor: PortableTextSlateEditor
|
|
2566
|
-
}
|
|
2567
|
-
| {
|
|
2568
|
-
type: 'focus'
|
|
2569
|
-
editor: PortableTextSlateEditor
|
|
2570
|
-
}
|
|
2571
|
-
| {
|
|
2572
|
-
type: 'normalizing'
|
|
2573
|
-
}
|
|
2574
|
-
| {
|
|
2575
|
-
type: 'done normalizing'
|
|
2576
|
-
}
|
|
2577
|
-
| {
|
|
2578
|
-
type: 'done syncing value'
|
|
2579
|
-
}
|
|
2580
|
-
| {
|
|
2581
|
-
type: 'syncing value'
|
|
2582
|
-
}
|
|
2583
|
-
| {
|
|
2584
|
-
type: 'behavior event'
|
|
2585
|
-
behaviorEvent: BehaviorEvent
|
|
2586
|
-
editor: PortableTextSlateEditor
|
|
2587
|
-
nativeEvent?: {
|
|
2588
|
-
preventDefault: () => void
|
|
2589
|
-
}
|
|
2590
|
-
}
|
|
2591
|
-
| {
|
|
2592
|
-
type: 'notify.patch'
|
|
2593
|
-
patch: Patch
|
|
2594
|
-
}
|
|
2595
|
-
| {
|
|
2596
|
-
type: 'notify.mutation'
|
|
2597
|
-
patches: Array<Patch>
|
|
2598
|
-
snapshot: Array<PortableTextBlock> | undefined
|
|
2599
|
-
value: Array<PortableTextBlock> | undefined
|
|
2600
|
-
}
|
|
2601
|
-
| {
|
|
2602
|
-
type: 'notify.blurred'
|
|
2603
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
2604
|
-
}
|
|
2605
|
-
| {
|
|
2606
|
-
type: 'notify.done loading'
|
|
2607
|
-
}
|
|
2608
|
-
| {
|
|
2609
|
-
type: 'notify.editable'
|
|
2610
|
-
}
|
|
2611
|
-
| {
|
|
2612
|
-
type: 'notify.error'
|
|
2613
|
-
name: string
|
|
2614
|
-
description: string
|
|
2615
|
-
data: unknown
|
|
2616
|
-
}
|
|
2617
|
-
| {
|
|
2618
|
-
type: 'notify.focused'
|
|
2619
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
2620
|
-
}
|
|
2621
|
-
| {
|
|
2622
|
-
type: 'notify.invalid value'
|
|
2623
|
-
resolution: InvalidValueResolution | null
|
|
2624
|
-
value: Array<PortableTextBlock> | undefined
|
|
2625
|
-
}
|
|
2626
|
-
| {
|
|
2627
|
-
type: 'notify.loading'
|
|
2628
|
-
}
|
|
2629
|
-
| {
|
|
2630
|
-
type: 'notify.read only'
|
|
2631
|
-
}
|
|
2632
|
-
| {
|
|
2633
|
-
type: 'notify.ready'
|
|
2634
|
-
}
|
|
2635
|
-
| {
|
|
2636
|
-
type: 'notify.selection'
|
|
2637
|
-
selection: EditorSelection
|
|
2638
|
-
}
|
|
2639
|
-
| {
|
|
2640
|
-
type: 'notify.value changed'
|
|
2641
|
-
value: Array<PortableTextBlock> | undefined
|
|
2642
|
-
}
|
|
2643
|
-
| {
|
|
2644
|
-
type: 'notify.unset'
|
|
2645
|
-
previousValue: Array<PortableTextBlock>
|
|
2646
|
-
}
|
|
2647
|
-
| {
|
|
2648
|
-
type: 'dragstart'
|
|
2649
|
-
origin: Pick<EventPosition, 'selection'>
|
|
2650
|
-
ghost?: HTMLElement
|
|
2651
|
-
}
|
|
2652
|
-
| {
|
|
2653
|
-
type: 'dragend'
|
|
2654
|
-
}
|
|
2655
|
-
| {
|
|
2656
|
-
type: 'drop'
|
|
2657
|
-
},
|
|
2658
|
-
undefined,
|
|
2659
|
-
never,
|
|
2660
|
-
never,
|
|
2661
|
-
never,
|
|
2662
|
-
never,
|
|
2663
|
-
never
|
|
2664
|
-
>,
|
|
2665
|
-
ActionFunction<
|
|
2666
|
-
{
|
|
2667
|
-
behaviors: Set<BehaviorConfig>
|
|
2668
|
-
converters: Set<Converter>
|
|
2669
|
-
getLegacySchema: () => PortableTextMemberSchemaTypes
|
|
2670
|
-
keyGenerator: () => string
|
|
2671
|
-
pendingEvents: Array<InternalPatchEvent | MutationEvent>
|
|
2672
|
-
pendingIncomingPatchesEvents: Array<PatchesEvent>
|
|
2673
|
-
schema: EditorSchema
|
|
2674
|
-
initialReadOnly: boolean
|
|
2675
|
-
maxBlocks: number | undefined
|
|
2676
|
-
selection: EditorSelection
|
|
2677
|
-
initialValue: Array<PortableTextBlock> | undefined
|
|
2678
|
-
internalDrag?: {
|
|
2679
|
-
ghost?: HTMLElement
|
|
2680
|
-
origin: Pick<EventPosition, 'selection'>
|
|
2681
|
-
}
|
|
2682
|
-
slateEditor?: PortableTextSlateEditor
|
|
2683
|
-
},
|
|
2684
|
-
{
|
|
2685
|
-
type: 'notify.selection'
|
|
2686
|
-
selection: EditorSelection
|
|
2687
|
-
},
|
|
2688
|
-
| InternalPatchEvent
|
|
2689
|
-
| MutationEvent
|
|
2690
|
-
| PatchesEvent
|
|
2691
|
-
| {
|
|
2692
|
-
type: 'update readOnly'
|
|
2693
|
-
readOnly: boolean
|
|
2694
|
-
}
|
|
2695
|
-
| {
|
|
2696
|
-
type: 'update schema'
|
|
2697
|
-
schema: EditorSchema
|
|
2698
|
-
}
|
|
2699
|
-
| {
|
|
2700
|
-
type: 'update key generator'
|
|
2701
|
-
keyGenerator: () => string
|
|
2702
|
-
}
|
|
2703
|
-
| {
|
|
2704
|
-
type: 'update maxBlocks'
|
|
2705
|
-
maxBlocks: number | undefined
|
|
2706
|
-
}
|
|
2707
|
-
| {
|
|
2708
|
-
type: 'add behavior'
|
|
2709
|
-
behaviorConfig: BehaviorConfig
|
|
2710
|
-
}
|
|
2711
|
-
| {
|
|
2712
|
-
type: 'remove behavior'
|
|
2713
|
-
behaviorConfig: BehaviorConfig
|
|
2714
|
-
}
|
|
2715
|
-
| {
|
|
2716
|
-
type: 'blur'
|
|
2717
|
-
editor: PortableTextSlateEditor
|
|
2718
|
-
}
|
|
2719
|
-
| {
|
|
2720
|
-
type: 'focus'
|
|
2721
|
-
editor: PortableTextSlateEditor
|
|
2722
|
-
}
|
|
2723
|
-
| {
|
|
2724
|
-
type: 'normalizing'
|
|
2725
|
-
}
|
|
2726
|
-
| {
|
|
2727
|
-
type: 'done normalizing'
|
|
2728
|
-
}
|
|
2729
|
-
| {
|
|
2730
|
-
type: 'done syncing value'
|
|
2731
|
-
}
|
|
2732
|
-
| {
|
|
2733
|
-
type: 'syncing value'
|
|
2734
|
-
}
|
|
2735
|
-
| {
|
|
2736
|
-
type: 'behavior event'
|
|
2737
|
-
behaviorEvent: BehaviorEvent
|
|
2738
|
-
editor: PortableTextSlateEditor
|
|
2739
|
-
nativeEvent?: {
|
|
2740
|
-
preventDefault: () => void
|
|
2741
|
-
}
|
|
2742
|
-
}
|
|
2743
|
-
| {
|
|
2744
|
-
type: 'notify.patch'
|
|
2745
|
-
patch: Patch
|
|
2746
|
-
}
|
|
2747
|
-
| {
|
|
2748
|
-
type: 'notify.mutation'
|
|
2749
|
-
patches: Array<Patch>
|
|
2750
|
-
snapshot: Array<PortableTextBlock> | undefined
|
|
2751
|
-
value: Array<PortableTextBlock> | undefined
|
|
2752
|
-
}
|
|
2753
|
-
| {
|
|
2754
|
-
type: 'notify.blurred'
|
|
2755
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
2756
|
-
}
|
|
2757
|
-
| {
|
|
2758
|
-
type: 'notify.done loading'
|
|
2759
|
-
}
|
|
2760
|
-
| {
|
|
2761
|
-
type: 'notify.editable'
|
|
2762
|
-
}
|
|
2763
|
-
| {
|
|
2764
|
-
type: 'notify.error'
|
|
2765
|
-
name: string
|
|
2766
|
-
description: string
|
|
2767
|
-
data: unknown
|
|
2768
|
-
}
|
|
2769
|
-
| {
|
|
2770
|
-
type: 'notify.focused'
|
|
2771
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
2772
|
-
}
|
|
2773
|
-
| {
|
|
2774
|
-
type: 'notify.invalid value'
|
|
2775
|
-
resolution: InvalidValueResolution | null
|
|
2776
|
-
value: Array<PortableTextBlock> | undefined
|
|
2777
|
-
}
|
|
2778
|
-
| {
|
|
2779
|
-
type: 'notify.loading'
|
|
2780
|
-
}
|
|
2781
|
-
| {
|
|
2782
|
-
type: 'notify.read only'
|
|
2783
|
-
}
|
|
2784
|
-
| {
|
|
2785
|
-
type: 'notify.ready'
|
|
2786
|
-
}
|
|
2787
|
-
| {
|
|
2788
|
-
type: 'notify.selection'
|
|
2789
|
-
selection: EditorSelection
|
|
2790
|
-
}
|
|
2791
|
-
| {
|
|
2792
|
-
type: 'notify.value changed'
|
|
2793
|
-
value: Array<PortableTextBlock> | undefined
|
|
2794
|
-
}
|
|
2795
|
-
| {
|
|
2796
|
-
type: 'notify.unset'
|
|
2797
|
-
previousValue: Array<PortableTextBlock>
|
|
2798
|
-
}
|
|
2799
|
-
| {
|
|
2800
|
-
type: 'dragstart'
|
|
2801
|
-
origin: Pick<EventPosition, 'selection'>
|
|
2802
|
-
ghost?: HTMLElement
|
|
2803
|
-
}
|
|
2804
|
-
| {
|
|
2805
|
-
type: 'dragend'
|
|
2806
|
-
}
|
|
2807
|
-
| {
|
|
2808
|
-
type: 'drop'
|
|
2809
|
-
},
|
|
2810
|
-
undefined,
|
|
2811
|
-
never,
|
|
2812
|
-
never,
|
|
2813
|
-
never,
|
|
2814
|
-
never,
|
|
2815
|
-
| PatchEvent
|
|
2816
|
-
| InternalPatchEvent
|
|
2817
|
-
| MutationEvent
|
|
2818
|
-
| PatchesEvent
|
|
2819
|
-
| {
|
|
2820
|
-
type: 'blurred'
|
|
2821
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
2822
|
-
}
|
|
2823
|
-
| {
|
|
2824
|
-
type: 'done loading'
|
|
2825
|
-
}
|
|
2826
|
-
| {
|
|
2827
|
-
type: 'editable'
|
|
2828
|
-
}
|
|
2829
|
-
| {
|
|
2830
|
-
type: 'error'
|
|
2831
|
-
name: string
|
|
2832
|
-
description: string
|
|
2833
|
-
data: unknown
|
|
2834
|
-
}
|
|
2835
|
-
| {
|
|
2836
|
-
type: 'focused'
|
|
2837
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
2838
|
-
}
|
|
2839
|
-
| {
|
|
2840
|
-
type: 'invalid value'
|
|
2841
|
-
resolution: InvalidValueResolution | null
|
|
2842
|
-
value: Array<PortableTextBlock> | undefined
|
|
2843
|
-
}
|
|
2844
|
-
| {
|
|
2845
|
-
type: 'loading'
|
|
2846
|
-
}
|
|
2847
|
-
| {
|
|
2848
|
-
type: 'read only'
|
|
2849
|
-
}
|
|
2850
|
-
| {
|
|
2851
|
-
type: 'ready'
|
|
2852
|
-
}
|
|
2853
|
-
| {
|
|
2854
|
-
type: 'selection'
|
|
2855
|
-
selection: EditorSelection
|
|
2856
|
-
}
|
|
2857
|
-
| {
|
|
2858
|
-
type: 'value changed'
|
|
2859
|
-
value: Array<PortableTextBlock> | undefined
|
|
2860
|
-
}
|
|
2861
|
-
| UnsetEvent
|
|
2862
|
-
>,
|
|
2863
|
-
]
|
|
2864
|
-
}
|
|
2865
|
-
readonly 'notify.unset': {
|
|
2866
|
-
readonly actions: ActionFunction<
|
|
2867
|
-
{
|
|
2868
|
-
behaviors: Set<BehaviorConfig>
|
|
2869
|
-
converters: Set<Converter>
|
|
2870
|
-
getLegacySchema: () => PortableTextMemberSchemaTypes
|
|
2871
|
-
keyGenerator: () => string
|
|
2872
|
-
pendingEvents: Array<InternalPatchEvent | MutationEvent>
|
|
2873
|
-
pendingIncomingPatchesEvents: Array<PatchesEvent>
|
|
2874
|
-
schema: EditorSchema
|
|
2875
|
-
initialReadOnly: boolean
|
|
2876
|
-
maxBlocks: number | undefined
|
|
2877
|
-
selection: EditorSelection
|
|
2878
|
-
initialValue: Array<PortableTextBlock> | undefined
|
|
2879
|
-
internalDrag?: {
|
|
2880
|
-
ghost?: HTMLElement
|
|
2881
|
-
origin: Pick<EventPosition, 'selection'>
|
|
2882
|
-
}
|
|
2883
|
-
slateEditor?: PortableTextSlateEditor
|
|
2884
|
-
},
|
|
2885
|
-
{
|
|
2886
|
-
type: 'notify.unset'
|
|
2887
|
-
previousValue: Array<PortableTextBlock>
|
|
2888
|
-
},
|
|
2889
|
-
| InternalPatchEvent
|
|
2890
|
-
| MutationEvent
|
|
2891
|
-
| PatchesEvent
|
|
2892
|
-
| {
|
|
2893
|
-
type: 'update readOnly'
|
|
2894
|
-
readOnly: boolean
|
|
2895
|
-
}
|
|
2896
|
-
| {
|
|
2897
|
-
type: 'update schema'
|
|
2898
|
-
schema: EditorSchema
|
|
2899
|
-
}
|
|
2900
|
-
| {
|
|
2901
|
-
type: 'update key generator'
|
|
2902
|
-
keyGenerator: () => string
|
|
2903
|
-
}
|
|
2904
|
-
| {
|
|
2905
|
-
type: 'update maxBlocks'
|
|
2906
|
-
maxBlocks: number | undefined
|
|
2907
|
-
}
|
|
2908
|
-
| {
|
|
2909
|
-
type: 'add behavior'
|
|
2910
|
-
behaviorConfig: BehaviorConfig
|
|
2911
|
-
}
|
|
2912
|
-
| {
|
|
2913
|
-
type: 'remove behavior'
|
|
2914
|
-
behaviorConfig: BehaviorConfig
|
|
2915
|
-
}
|
|
2916
|
-
| {
|
|
2917
|
-
type: 'blur'
|
|
2918
|
-
editor: PortableTextSlateEditor
|
|
2919
|
-
}
|
|
2920
|
-
| {
|
|
2921
|
-
type: 'focus'
|
|
2922
|
-
editor: PortableTextSlateEditor
|
|
2923
|
-
}
|
|
2924
|
-
| {
|
|
2925
|
-
type: 'normalizing'
|
|
2926
|
-
}
|
|
2927
|
-
| {
|
|
2928
|
-
type: 'done normalizing'
|
|
2929
|
-
}
|
|
2930
|
-
| {
|
|
2931
|
-
type: 'done syncing value'
|
|
2932
|
-
}
|
|
2933
|
-
| {
|
|
2934
|
-
type: 'syncing value'
|
|
2935
|
-
}
|
|
2936
|
-
| {
|
|
2937
|
-
type: 'behavior event'
|
|
2938
|
-
behaviorEvent: BehaviorEvent
|
|
2939
|
-
editor: PortableTextSlateEditor
|
|
2940
|
-
nativeEvent?: {
|
|
2941
|
-
preventDefault: () => void
|
|
2942
|
-
}
|
|
2943
|
-
}
|
|
2944
|
-
| {
|
|
2945
|
-
type: 'notify.patch'
|
|
2946
|
-
patch: Patch
|
|
2947
|
-
}
|
|
2948
|
-
| {
|
|
2949
|
-
type: 'notify.mutation'
|
|
2950
|
-
patches: Array<Patch>
|
|
2951
|
-
snapshot: Array<PortableTextBlock> | undefined
|
|
2952
|
-
value: Array<PortableTextBlock> | undefined
|
|
2953
|
-
}
|
|
2954
|
-
| {
|
|
2955
|
-
type: 'notify.blurred'
|
|
2956
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
2957
|
-
}
|
|
2958
|
-
| {
|
|
2959
|
-
type: 'notify.done loading'
|
|
2960
|
-
}
|
|
2961
|
-
| {
|
|
2962
|
-
type: 'notify.editable'
|
|
2963
|
-
}
|
|
2964
|
-
| {
|
|
2965
|
-
type: 'notify.error'
|
|
2966
|
-
name: string
|
|
2967
|
-
description: string
|
|
2968
|
-
data: unknown
|
|
2969
|
-
}
|
|
2970
|
-
| {
|
|
2971
|
-
type: 'notify.focused'
|
|
2972
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
2973
|
-
}
|
|
2974
|
-
| {
|
|
2975
|
-
type: 'notify.invalid value'
|
|
2976
|
-
resolution: InvalidValueResolution | null
|
|
2977
|
-
value: Array<PortableTextBlock> | undefined
|
|
2978
|
-
}
|
|
2979
|
-
| {
|
|
2980
|
-
type: 'notify.loading'
|
|
2981
|
-
}
|
|
2982
|
-
| {
|
|
2983
|
-
type: 'notify.read only'
|
|
2984
|
-
}
|
|
2985
|
-
| {
|
|
2986
|
-
type: 'notify.ready'
|
|
2987
|
-
}
|
|
2988
|
-
| {
|
|
2989
|
-
type: 'notify.selection'
|
|
2990
|
-
selection: EditorSelection
|
|
2991
|
-
}
|
|
2992
|
-
| {
|
|
2993
|
-
type: 'notify.value changed'
|
|
2994
|
-
value: Array<PortableTextBlock> | undefined
|
|
2995
|
-
}
|
|
2996
|
-
| {
|
|
2997
|
-
type: 'notify.unset'
|
|
2998
|
-
previousValue: Array<PortableTextBlock>
|
|
2999
|
-
}
|
|
3000
|
-
| {
|
|
3001
|
-
type: 'dragstart'
|
|
3002
|
-
origin: Pick<EventPosition, 'selection'>
|
|
3003
|
-
ghost?: HTMLElement
|
|
3004
|
-
}
|
|
3005
|
-
| {
|
|
3006
|
-
type: 'dragend'
|
|
3007
|
-
}
|
|
3008
|
-
| {
|
|
3009
|
-
type: 'drop'
|
|
3010
|
-
},
|
|
3011
|
-
undefined,
|
|
3012
|
-
never,
|
|
3013
|
-
never,
|
|
3014
|
-
never,
|
|
3015
|
-
never,
|
|
3016
|
-
| PatchEvent
|
|
3017
|
-
| InternalPatchEvent
|
|
3018
|
-
| MutationEvent
|
|
3019
|
-
| PatchesEvent
|
|
3020
|
-
| {
|
|
3021
|
-
type: 'blurred'
|
|
3022
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
3023
|
-
}
|
|
3024
|
-
| {
|
|
3025
|
-
type: 'done loading'
|
|
3026
|
-
}
|
|
3027
|
-
| {
|
|
3028
|
-
type: 'editable'
|
|
3029
|
-
}
|
|
3030
|
-
| {
|
|
3031
|
-
type: 'error'
|
|
3032
|
-
name: string
|
|
3033
|
-
description: string
|
|
3034
|
-
data: unknown
|
|
3035
|
-
}
|
|
3036
|
-
| {
|
|
3037
|
-
type: 'focused'
|
|
3038
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
3039
|
-
}
|
|
3040
|
-
| {
|
|
3041
|
-
type: 'invalid value'
|
|
3042
|
-
resolution: InvalidValueResolution | null
|
|
3043
|
-
value: Array<PortableTextBlock> | undefined
|
|
3044
|
-
}
|
|
3045
|
-
| {
|
|
3046
|
-
type: 'loading'
|
|
3047
|
-
}
|
|
3048
|
-
| {
|
|
3049
|
-
type: 'read only'
|
|
3050
|
-
}
|
|
3051
|
-
| {
|
|
3052
|
-
type: 'ready'
|
|
3053
|
-
}
|
|
3054
|
-
| {
|
|
3055
|
-
type: 'selection'
|
|
3056
|
-
selection: EditorSelection
|
|
3057
|
-
}
|
|
3058
|
-
| {
|
|
3059
|
-
type: 'value changed'
|
|
3060
|
-
value: Array<PortableTextBlock> | undefined
|
|
3061
|
-
}
|
|
3062
|
-
| UnsetEvent
|
|
3063
|
-
>
|
|
3064
|
-
}
|
|
3065
|
-
readonly 'notify.loading': {
|
|
3066
|
-
readonly actions: ActionFunction<
|
|
3067
|
-
{
|
|
3068
|
-
behaviors: Set<BehaviorConfig>
|
|
3069
|
-
converters: Set<Converter>
|
|
3070
|
-
getLegacySchema: () => PortableTextMemberSchemaTypes
|
|
3071
|
-
keyGenerator: () => string
|
|
3072
|
-
pendingEvents: Array<InternalPatchEvent | MutationEvent>
|
|
3073
|
-
pendingIncomingPatchesEvents: Array<PatchesEvent>
|
|
3074
|
-
schema: EditorSchema
|
|
3075
|
-
initialReadOnly: boolean
|
|
3076
|
-
maxBlocks: number | undefined
|
|
3077
|
-
selection: EditorSelection
|
|
3078
|
-
initialValue: Array<PortableTextBlock> | undefined
|
|
3079
|
-
internalDrag?: {
|
|
3080
|
-
ghost?: HTMLElement
|
|
3081
|
-
origin: Pick<EventPosition, 'selection'>
|
|
3082
|
-
}
|
|
3083
|
-
slateEditor?: PortableTextSlateEditor
|
|
3084
|
-
},
|
|
3085
|
-
{
|
|
3086
|
-
type: 'notify.loading'
|
|
3087
|
-
},
|
|
3088
|
-
| InternalPatchEvent
|
|
3089
|
-
| MutationEvent
|
|
3090
|
-
| PatchesEvent
|
|
3091
|
-
| {
|
|
3092
|
-
type: 'update readOnly'
|
|
3093
|
-
readOnly: boolean
|
|
3094
|
-
}
|
|
3095
|
-
| {
|
|
3096
|
-
type: 'update schema'
|
|
3097
|
-
schema: EditorSchema
|
|
3098
|
-
}
|
|
3099
|
-
| {
|
|
3100
|
-
type: 'update key generator'
|
|
3101
|
-
keyGenerator: () => string
|
|
3102
|
-
}
|
|
3103
|
-
| {
|
|
3104
|
-
type: 'update maxBlocks'
|
|
3105
|
-
maxBlocks: number | undefined
|
|
3106
|
-
}
|
|
3107
|
-
| {
|
|
3108
|
-
type: 'add behavior'
|
|
3109
|
-
behaviorConfig: BehaviorConfig
|
|
3110
|
-
}
|
|
3111
|
-
| {
|
|
3112
|
-
type: 'remove behavior'
|
|
3113
|
-
behaviorConfig: BehaviorConfig
|
|
3114
|
-
}
|
|
3115
|
-
| {
|
|
3116
|
-
type: 'blur'
|
|
3117
|
-
editor: PortableTextSlateEditor
|
|
3118
|
-
}
|
|
3119
|
-
| {
|
|
3120
|
-
type: 'focus'
|
|
3121
|
-
editor: PortableTextSlateEditor
|
|
3122
|
-
}
|
|
3123
|
-
| {
|
|
3124
|
-
type: 'normalizing'
|
|
3125
|
-
}
|
|
3126
|
-
| {
|
|
3127
|
-
type: 'done normalizing'
|
|
3128
|
-
}
|
|
3129
|
-
| {
|
|
3130
|
-
type: 'done syncing value'
|
|
3131
|
-
}
|
|
3132
|
-
| {
|
|
3133
|
-
type: 'syncing value'
|
|
3134
|
-
}
|
|
3135
|
-
| {
|
|
3136
|
-
type: 'behavior event'
|
|
3137
|
-
behaviorEvent: BehaviorEvent
|
|
3138
|
-
editor: PortableTextSlateEditor
|
|
3139
|
-
nativeEvent?: {
|
|
3140
|
-
preventDefault: () => void
|
|
3141
|
-
}
|
|
3142
|
-
}
|
|
3143
|
-
| {
|
|
3144
|
-
type: 'notify.patch'
|
|
3145
|
-
patch: Patch
|
|
3146
|
-
}
|
|
3147
|
-
| {
|
|
3148
|
-
type: 'notify.mutation'
|
|
3149
|
-
patches: Array<Patch>
|
|
3150
|
-
snapshot: Array<PortableTextBlock> | undefined
|
|
3151
|
-
value: Array<PortableTextBlock> | undefined
|
|
3152
|
-
}
|
|
3153
|
-
| {
|
|
3154
|
-
type: 'notify.blurred'
|
|
3155
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
3156
|
-
}
|
|
3157
|
-
| {
|
|
3158
|
-
type: 'notify.done loading'
|
|
3159
|
-
}
|
|
3160
|
-
| {
|
|
3161
|
-
type: 'notify.editable'
|
|
3162
|
-
}
|
|
3163
|
-
| {
|
|
3164
|
-
type: 'notify.error'
|
|
3165
|
-
name: string
|
|
3166
|
-
description: string
|
|
3167
|
-
data: unknown
|
|
3168
|
-
}
|
|
3169
|
-
| {
|
|
3170
|
-
type: 'notify.focused'
|
|
3171
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
3172
|
-
}
|
|
3173
|
-
| {
|
|
3174
|
-
type: 'notify.invalid value'
|
|
3175
|
-
resolution: InvalidValueResolution | null
|
|
3176
|
-
value: Array<PortableTextBlock> | undefined
|
|
3177
|
-
}
|
|
3178
|
-
| {
|
|
3179
|
-
type: 'notify.loading'
|
|
3180
|
-
}
|
|
3181
|
-
| {
|
|
3182
|
-
type: 'notify.read only'
|
|
3183
|
-
}
|
|
3184
|
-
| {
|
|
3185
|
-
type: 'notify.ready'
|
|
3186
|
-
}
|
|
3187
|
-
| {
|
|
3188
|
-
type: 'notify.selection'
|
|
3189
|
-
selection: EditorSelection
|
|
3190
|
-
}
|
|
3191
|
-
| {
|
|
3192
|
-
type: 'notify.value changed'
|
|
3193
|
-
value: Array<PortableTextBlock> | undefined
|
|
3194
|
-
}
|
|
3195
|
-
| {
|
|
3196
|
-
type: 'notify.unset'
|
|
3197
|
-
previousValue: Array<PortableTextBlock>
|
|
3198
|
-
}
|
|
3199
|
-
| {
|
|
3200
|
-
type: 'dragstart'
|
|
3201
|
-
origin: Pick<EventPosition, 'selection'>
|
|
3202
|
-
ghost?: HTMLElement
|
|
3203
|
-
}
|
|
3204
|
-
| {
|
|
3205
|
-
type: 'dragend'
|
|
3206
|
-
}
|
|
3207
|
-
| {
|
|
3208
|
-
type: 'drop'
|
|
3209
|
-
},
|
|
3210
|
-
undefined,
|
|
3211
|
-
never,
|
|
3212
|
-
never,
|
|
3213
|
-
never,
|
|
3214
|
-
never,
|
|
3215
|
-
| PatchEvent
|
|
3216
|
-
| InternalPatchEvent
|
|
3217
|
-
| MutationEvent
|
|
3218
|
-
| PatchesEvent
|
|
3219
|
-
| {
|
|
3220
|
-
type: 'blurred'
|
|
3221
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
3222
|
-
}
|
|
3223
|
-
| {
|
|
3224
|
-
type: 'done loading'
|
|
3225
|
-
}
|
|
3226
|
-
| {
|
|
3227
|
-
type: 'editable'
|
|
3228
|
-
}
|
|
3229
|
-
| {
|
|
3230
|
-
type: 'error'
|
|
3231
|
-
name: string
|
|
3232
|
-
description: string
|
|
3233
|
-
data: unknown
|
|
3234
|
-
}
|
|
3235
|
-
| {
|
|
3236
|
-
type: 'focused'
|
|
3237
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
3238
|
-
}
|
|
3239
|
-
| {
|
|
3240
|
-
type: 'invalid value'
|
|
3241
|
-
resolution: InvalidValueResolution | null
|
|
3242
|
-
value: Array<PortableTextBlock> | undefined
|
|
3243
|
-
}
|
|
3244
|
-
| {
|
|
3245
|
-
type: 'loading'
|
|
3246
|
-
}
|
|
3247
|
-
| {
|
|
3248
|
-
type: 'read only'
|
|
3249
|
-
}
|
|
3250
|
-
| {
|
|
3251
|
-
type: 'ready'
|
|
3252
|
-
}
|
|
3253
|
-
| {
|
|
3254
|
-
type: 'selection'
|
|
3255
|
-
selection: EditorSelection
|
|
3256
|
-
}
|
|
3257
|
-
| {
|
|
3258
|
-
type: 'value changed'
|
|
3259
|
-
value: Array<PortableTextBlock> | undefined
|
|
3260
|
-
}
|
|
3261
|
-
| UnsetEvent
|
|
3262
|
-
>
|
|
3263
|
-
}
|
|
3264
|
-
readonly 'notify.value changed': {
|
|
3265
|
-
readonly actions: ActionFunction<
|
|
3266
|
-
{
|
|
3267
|
-
behaviors: Set<BehaviorConfig>
|
|
3268
|
-
converters: Set<Converter>
|
|
3269
|
-
getLegacySchema: () => PortableTextMemberSchemaTypes
|
|
3270
|
-
keyGenerator: () => string
|
|
3271
|
-
pendingEvents: Array<InternalPatchEvent | MutationEvent>
|
|
3272
|
-
pendingIncomingPatchesEvents: Array<PatchesEvent>
|
|
3273
|
-
schema: EditorSchema
|
|
3274
|
-
initialReadOnly: boolean
|
|
3275
|
-
maxBlocks: number | undefined
|
|
3276
|
-
selection: EditorSelection
|
|
3277
|
-
initialValue: Array<PortableTextBlock> | undefined
|
|
3278
|
-
internalDrag?: {
|
|
3279
|
-
ghost?: HTMLElement
|
|
3280
|
-
origin: Pick<EventPosition, 'selection'>
|
|
3281
|
-
}
|
|
3282
|
-
slateEditor?: PortableTextSlateEditor
|
|
3283
|
-
},
|
|
3284
|
-
{
|
|
3285
|
-
type: 'notify.value changed'
|
|
3286
|
-
value: Array<PortableTextBlock> | undefined
|
|
3287
|
-
},
|
|
3288
|
-
| InternalPatchEvent
|
|
3289
|
-
| MutationEvent
|
|
3290
|
-
| PatchesEvent
|
|
3291
|
-
| {
|
|
3292
|
-
type: 'update readOnly'
|
|
3293
|
-
readOnly: boolean
|
|
3294
|
-
}
|
|
3295
|
-
| {
|
|
3296
|
-
type: 'update schema'
|
|
3297
|
-
schema: EditorSchema
|
|
3298
|
-
}
|
|
3299
|
-
| {
|
|
3300
|
-
type: 'update key generator'
|
|
3301
|
-
keyGenerator: () => string
|
|
3302
|
-
}
|
|
3303
|
-
| {
|
|
3304
|
-
type: 'update maxBlocks'
|
|
3305
|
-
maxBlocks: number | undefined
|
|
3306
|
-
}
|
|
3307
|
-
| {
|
|
3308
|
-
type: 'add behavior'
|
|
3309
|
-
behaviorConfig: BehaviorConfig
|
|
3310
|
-
}
|
|
3311
|
-
| {
|
|
3312
|
-
type: 'remove behavior'
|
|
3313
|
-
behaviorConfig: BehaviorConfig
|
|
3314
|
-
}
|
|
3315
|
-
| {
|
|
3316
|
-
type: 'blur'
|
|
3317
|
-
editor: PortableTextSlateEditor
|
|
3318
|
-
}
|
|
3319
|
-
| {
|
|
3320
|
-
type: 'focus'
|
|
3321
|
-
editor: PortableTextSlateEditor
|
|
3322
|
-
}
|
|
3323
|
-
| {
|
|
3324
|
-
type: 'normalizing'
|
|
3325
|
-
}
|
|
3326
|
-
| {
|
|
3327
|
-
type: 'done normalizing'
|
|
3328
|
-
}
|
|
3329
|
-
| {
|
|
3330
|
-
type: 'done syncing value'
|
|
3331
|
-
}
|
|
3332
|
-
| {
|
|
3333
|
-
type: 'syncing value'
|
|
3334
|
-
}
|
|
3335
|
-
| {
|
|
3336
|
-
type: 'behavior event'
|
|
3337
|
-
behaviorEvent: BehaviorEvent
|
|
3338
|
-
editor: PortableTextSlateEditor
|
|
3339
|
-
nativeEvent?: {
|
|
3340
|
-
preventDefault: () => void
|
|
3341
|
-
}
|
|
3342
|
-
}
|
|
3343
|
-
| {
|
|
3344
|
-
type: 'notify.patch'
|
|
3345
|
-
patch: Patch
|
|
3346
|
-
}
|
|
3347
|
-
| {
|
|
3348
|
-
type: 'notify.mutation'
|
|
3349
|
-
patches: Array<Patch>
|
|
3350
|
-
snapshot: Array<PortableTextBlock> | undefined
|
|
3351
|
-
value: Array<PortableTextBlock> | undefined
|
|
3352
|
-
}
|
|
3353
|
-
| {
|
|
3354
|
-
type: 'notify.blurred'
|
|
3355
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
3356
|
-
}
|
|
3357
|
-
| {
|
|
3358
|
-
type: 'notify.done loading'
|
|
3359
|
-
}
|
|
3360
|
-
| {
|
|
3361
|
-
type: 'notify.editable'
|
|
3362
|
-
}
|
|
3363
|
-
| {
|
|
3364
|
-
type: 'notify.error'
|
|
3365
|
-
name: string
|
|
3366
|
-
description: string
|
|
3367
|
-
data: unknown
|
|
3368
|
-
}
|
|
3369
|
-
| {
|
|
3370
|
-
type: 'notify.focused'
|
|
3371
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
3372
|
-
}
|
|
3373
|
-
| {
|
|
3374
|
-
type: 'notify.invalid value'
|
|
3375
|
-
resolution: InvalidValueResolution | null
|
|
3376
|
-
value: Array<PortableTextBlock> | undefined
|
|
3377
|
-
}
|
|
3378
|
-
| {
|
|
3379
|
-
type: 'notify.loading'
|
|
3380
|
-
}
|
|
3381
|
-
| {
|
|
3382
|
-
type: 'notify.read only'
|
|
3383
|
-
}
|
|
3384
|
-
| {
|
|
3385
|
-
type: 'notify.ready'
|
|
3386
|
-
}
|
|
3387
|
-
| {
|
|
3388
|
-
type: 'notify.selection'
|
|
3389
|
-
selection: EditorSelection
|
|
3390
|
-
}
|
|
3391
|
-
| {
|
|
3392
|
-
type: 'notify.value changed'
|
|
3393
|
-
value: Array<PortableTextBlock> | undefined
|
|
3394
|
-
}
|
|
3395
|
-
| {
|
|
3396
|
-
type: 'notify.unset'
|
|
3397
|
-
previousValue: Array<PortableTextBlock>
|
|
3398
|
-
}
|
|
3399
|
-
| {
|
|
3400
|
-
type: 'dragstart'
|
|
3401
|
-
origin: Pick<EventPosition, 'selection'>
|
|
3402
|
-
ghost?: HTMLElement
|
|
3403
|
-
}
|
|
3404
|
-
| {
|
|
3405
|
-
type: 'dragend'
|
|
3406
|
-
}
|
|
3407
|
-
| {
|
|
3408
|
-
type: 'drop'
|
|
3409
|
-
},
|
|
3410
|
-
undefined,
|
|
3411
|
-
never,
|
|
3412
|
-
never,
|
|
3413
|
-
never,
|
|
3414
|
-
never,
|
|
3415
|
-
| PatchEvent
|
|
3416
|
-
| InternalPatchEvent
|
|
3417
|
-
| MutationEvent
|
|
3418
|
-
| PatchesEvent
|
|
3419
|
-
| {
|
|
3420
|
-
type: 'blurred'
|
|
3421
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
3422
|
-
}
|
|
3423
|
-
| {
|
|
3424
|
-
type: 'done loading'
|
|
3425
|
-
}
|
|
3426
|
-
| {
|
|
3427
|
-
type: 'editable'
|
|
3428
|
-
}
|
|
3429
|
-
| {
|
|
3430
|
-
type: 'error'
|
|
3431
|
-
name: string
|
|
3432
|
-
description: string
|
|
3433
|
-
data: unknown
|
|
3434
|
-
}
|
|
3435
|
-
| {
|
|
3436
|
-
type: 'focused'
|
|
3437
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
3438
|
-
}
|
|
3439
|
-
| {
|
|
3440
|
-
type: 'invalid value'
|
|
3441
|
-
resolution: InvalidValueResolution | null
|
|
3442
|
-
value: Array<PortableTextBlock> | undefined
|
|
3443
|
-
}
|
|
3444
|
-
| {
|
|
3445
|
-
type: 'loading'
|
|
3446
|
-
}
|
|
3447
|
-
| {
|
|
3448
|
-
type: 'read only'
|
|
3449
|
-
}
|
|
3450
|
-
| {
|
|
3451
|
-
type: 'ready'
|
|
3452
|
-
}
|
|
3453
|
-
| {
|
|
3454
|
-
type: 'selection'
|
|
3455
|
-
selection: EditorSelection
|
|
3456
|
-
}
|
|
3457
|
-
| {
|
|
3458
|
-
type: 'value changed'
|
|
3459
|
-
value: Array<PortableTextBlock> | undefined
|
|
3460
|
-
}
|
|
3461
|
-
| UnsetEvent
|
|
3462
|
-
>
|
|
3463
|
-
}
|
|
3464
|
-
readonly 'add behavior': {
|
|
3465
|
-
readonly actions: 'add behavior to context'
|
|
3466
|
-
}
|
|
3467
|
-
readonly 'remove behavior': {
|
|
3468
|
-
readonly actions: 'remove behavior from context'
|
|
3469
|
-
}
|
|
3470
|
-
readonly 'update key generator': {
|
|
3471
|
-
readonly actions: ActionFunction<
|
|
3472
|
-
{
|
|
3473
|
-
behaviors: Set<BehaviorConfig>
|
|
3474
|
-
converters: Set<Converter>
|
|
3475
|
-
getLegacySchema: () => PortableTextMemberSchemaTypes
|
|
3476
|
-
keyGenerator: () => string
|
|
3477
|
-
pendingEvents: Array<InternalPatchEvent | MutationEvent>
|
|
3478
|
-
pendingIncomingPatchesEvents: Array<PatchesEvent>
|
|
3479
|
-
schema: EditorSchema
|
|
3480
|
-
initialReadOnly: boolean
|
|
3481
|
-
maxBlocks: number | undefined
|
|
3482
|
-
selection: EditorSelection
|
|
3483
|
-
initialValue: Array<PortableTextBlock> | undefined
|
|
3484
|
-
internalDrag?: {
|
|
3485
|
-
ghost?: HTMLElement
|
|
3486
|
-
origin: Pick<EventPosition, 'selection'>
|
|
3487
|
-
}
|
|
3488
|
-
slateEditor?: PortableTextSlateEditor
|
|
3489
|
-
},
|
|
3490
|
-
{
|
|
3491
|
-
type: 'update key generator'
|
|
3492
|
-
keyGenerator: () => string
|
|
3493
|
-
},
|
|
3494
|
-
| InternalPatchEvent
|
|
3495
|
-
| MutationEvent
|
|
3496
|
-
| PatchesEvent
|
|
3497
|
-
| {
|
|
3498
|
-
type: 'update readOnly'
|
|
3499
|
-
readOnly: boolean
|
|
3500
|
-
}
|
|
3501
|
-
| {
|
|
3502
|
-
type: 'update schema'
|
|
3503
|
-
schema: EditorSchema
|
|
3504
|
-
}
|
|
3505
|
-
| {
|
|
3506
|
-
type: 'update key generator'
|
|
3507
|
-
keyGenerator: () => string
|
|
3508
|
-
}
|
|
3509
|
-
| {
|
|
3510
|
-
type: 'update maxBlocks'
|
|
3511
|
-
maxBlocks: number | undefined
|
|
3512
|
-
}
|
|
3513
|
-
| {
|
|
3514
|
-
type: 'add behavior'
|
|
3515
|
-
behaviorConfig: BehaviorConfig
|
|
3516
|
-
}
|
|
3517
|
-
| {
|
|
3518
|
-
type: 'remove behavior'
|
|
3519
|
-
behaviorConfig: BehaviorConfig
|
|
3520
|
-
}
|
|
3521
|
-
| {
|
|
3522
|
-
type: 'blur'
|
|
3523
|
-
editor: PortableTextSlateEditor
|
|
3524
|
-
}
|
|
3525
|
-
| {
|
|
3526
|
-
type: 'focus'
|
|
3527
|
-
editor: PortableTextSlateEditor
|
|
3528
|
-
}
|
|
3529
|
-
| {
|
|
3530
|
-
type: 'normalizing'
|
|
3531
|
-
}
|
|
3532
|
-
| {
|
|
3533
|
-
type: 'done normalizing'
|
|
3534
|
-
}
|
|
3535
|
-
| {
|
|
3536
|
-
type: 'done syncing value'
|
|
3537
|
-
}
|
|
3538
|
-
| {
|
|
3539
|
-
type: 'syncing value'
|
|
3540
|
-
}
|
|
3541
|
-
| {
|
|
3542
|
-
type: 'behavior event'
|
|
3543
|
-
behaviorEvent: BehaviorEvent
|
|
3544
|
-
editor: PortableTextSlateEditor
|
|
3545
|
-
nativeEvent?: {
|
|
3546
|
-
preventDefault: () => void
|
|
3547
|
-
}
|
|
3548
|
-
}
|
|
3549
|
-
| {
|
|
3550
|
-
type: 'notify.patch'
|
|
3551
|
-
patch: Patch
|
|
3552
|
-
}
|
|
3553
|
-
| {
|
|
3554
|
-
type: 'notify.mutation'
|
|
3555
|
-
patches: Array<Patch>
|
|
3556
|
-
snapshot: Array<PortableTextBlock> | undefined
|
|
3557
|
-
value: Array<PortableTextBlock> | undefined
|
|
3558
|
-
}
|
|
3559
|
-
| {
|
|
3560
|
-
type: 'notify.blurred'
|
|
3561
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
3562
|
-
}
|
|
3563
|
-
| {
|
|
3564
|
-
type: 'notify.done loading'
|
|
3565
|
-
}
|
|
3566
|
-
| {
|
|
3567
|
-
type: 'notify.editable'
|
|
3568
|
-
}
|
|
3569
|
-
| {
|
|
3570
|
-
type: 'notify.error'
|
|
3571
|
-
name: string
|
|
3572
|
-
description: string
|
|
3573
|
-
data: unknown
|
|
3574
|
-
}
|
|
3575
|
-
| {
|
|
3576
|
-
type: 'notify.focused'
|
|
3577
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
3578
|
-
}
|
|
3579
|
-
| {
|
|
3580
|
-
type: 'notify.invalid value'
|
|
3581
|
-
resolution: InvalidValueResolution | null
|
|
3582
|
-
value: Array<PortableTextBlock> | undefined
|
|
3583
|
-
}
|
|
3584
|
-
| {
|
|
3585
|
-
type: 'notify.loading'
|
|
3586
|
-
}
|
|
3587
|
-
| {
|
|
3588
|
-
type: 'notify.read only'
|
|
3589
|
-
}
|
|
3590
|
-
| {
|
|
3591
|
-
type: 'notify.ready'
|
|
3592
|
-
}
|
|
3593
|
-
| {
|
|
3594
|
-
type: 'notify.selection'
|
|
3595
|
-
selection: EditorSelection
|
|
3596
|
-
}
|
|
3597
|
-
| {
|
|
3598
|
-
type: 'notify.value changed'
|
|
3599
|
-
value: Array<PortableTextBlock> | undefined
|
|
3600
|
-
}
|
|
3601
|
-
| {
|
|
3602
|
-
type: 'notify.unset'
|
|
3603
|
-
previousValue: Array<PortableTextBlock>
|
|
3604
|
-
}
|
|
3605
|
-
| {
|
|
3606
|
-
type: 'dragstart'
|
|
3607
|
-
origin: Pick<EventPosition, 'selection'>
|
|
3608
|
-
ghost?: HTMLElement
|
|
3609
|
-
}
|
|
3610
|
-
| {
|
|
3611
|
-
type: 'dragend'
|
|
3612
|
-
}
|
|
3613
|
-
| {
|
|
3614
|
-
type: 'drop'
|
|
3615
|
-
},
|
|
3616
|
-
undefined,
|
|
3617
|
-
never,
|
|
3618
|
-
never,
|
|
3619
|
-
never,
|
|
3620
|
-
never,
|
|
3621
|
-
never
|
|
3622
|
-
>
|
|
3623
|
-
}
|
|
3624
|
-
readonly 'update schema': {
|
|
3625
|
-
readonly actions: 'assign schema'
|
|
3626
|
-
}
|
|
3627
|
-
readonly 'update maxBlocks': {
|
|
3628
|
-
readonly actions: ActionFunction<
|
|
3629
|
-
{
|
|
3630
|
-
behaviors: Set<BehaviorConfig>
|
|
3631
|
-
converters: Set<Converter>
|
|
3632
|
-
getLegacySchema: () => PortableTextMemberSchemaTypes
|
|
3633
|
-
keyGenerator: () => string
|
|
3634
|
-
pendingEvents: Array<InternalPatchEvent | MutationEvent>
|
|
3635
|
-
pendingIncomingPatchesEvents: Array<PatchesEvent>
|
|
3636
|
-
schema: EditorSchema
|
|
3637
|
-
initialReadOnly: boolean
|
|
3638
|
-
maxBlocks: number | undefined
|
|
3639
|
-
selection: EditorSelection
|
|
3640
|
-
initialValue: Array<PortableTextBlock> | undefined
|
|
3641
|
-
internalDrag?: {
|
|
3642
|
-
ghost?: HTMLElement
|
|
3643
|
-
origin: Pick<EventPosition, 'selection'>
|
|
3644
|
-
}
|
|
3645
|
-
slateEditor?: PortableTextSlateEditor
|
|
3646
|
-
},
|
|
3647
|
-
{
|
|
3648
|
-
type: 'update maxBlocks'
|
|
3649
|
-
maxBlocks: number | undefined
|
|
3650
|
-
},
|
|
3651
|
-
| InternalPatchEvent
|
|
3652
|
-
| MutationEvent
|
|
3653
|
-
| PatchesEvent
|
|
3654
|
-
| {
|
|
3655
|
-
type: 'update readOnly'
|
|
3656
|
-
readOnly: boolean
|
|
3657
|
-
}
|
|
3658
|
-
| {
|
|
3659
|
-
type: 'update schema'
|
|
1424
|
+
pendingEvents: Array<InternalPatchEvent | MutationEvent>
|
|
1425
|
+
pendingIncomingPatchesEvents: Array<PatchesEvent>
|
|
3660
1426
|
schema: EditorSchema
|
|
3661
|
-
|
|
3662
|
-
| {
|
|
3663
|
-
type: 'update key generator'
|
|
3664
|
-
keyGenerator: () => string
|
|
3665
|
-
}
|
|
3666
|
-
| {
|
|
3667
|
-
type: 'update maxBlocks'
|
|
1427
|
+
initialReadOnly: boolean
|
|
3668
1428
|
maxBlocks: number | undefined
|
|
3669
|
-
|
|
3670
|
-
|
|
3671
|
-
|
|
3672
|
-
|
|
3673
|
-
|
|
3674
|
-
| {
|
|
3675
|
-
type: 'remove behavior'
|
|
3676
|
-
behaviorConfig: BehaviorConfig
|
|
3677
|
-
}
|
|
3678
|
-
| {
|
|
3679
|
-
type: 'blur'
|
|
3680
|
-
editor: PortableTextSlateEditor
|
|
3681
|
-
}
|
|
3682
|
-
| {
|
|
3683
|
-
type: 'focus'
|
|
3684
|
-
editor: PortableTextSlateEditor
|
|
3685
|
-
}
|
|
3686
|
-
| {
|
|
3687
|
-
type: 'normalizing'
|
|
3688
|
-
}
|
|
3689
|
-
| {
|
|
3690
|
-
type: 'done normalizing'
|
|
3691
|
-
}
|
|
3692
|
-
| {
|
|
3693
|
-
type: 'done syncing value'
|
|
3694
|
-
}
|
|
3695
|
-
| {
|
|
3696
|
-
type: 'syncing value'
|
|
3697
|
-
}
|
|
3698
|
-
| {
|
|
3699
|
-
type: 'behavior event'
|
|
3700
|
-
behaviorEvent: BehaviorEvent
|
|
3701
|
-
editor: PortableTextSlateEditor
|
|
3702
|
-
nativeEvent?: {
|
|
3703
|
-
preventDefault: () => void
|
|
1429
|
+
selection: EditorSelection
|
|
1430
|
+
initialValue: Array<PortableTextBlock> | undefined
|
|
1431
|
+
internalDrag?: {
|
|
1432
|
+
ghost?: HTMLElement
|
|
1433
|
+
origin: Pick<EventPosition, 'selection'>
|
|
3704
1434
|
}
|
|
3705
|
-
|
|
3706
|
-
|
|
3707
|
-
|
|
3708
|
-
|
|
3709
|
-
}
|
|
3710
|
-
| {
|
|
3711
|
-
type: 'notify.mutation'
|
|
3712
|
-
patches: Array<Patch>
|
|
3713
|
-
snapshot: Array<PortableTextBlock> | undefined
|
|
3714
|
-
value: Array<PortableTextBlock> | undefined
|
|
3715
|
-
}
|
|
3716
|
-
| {
|
|
3717
|
-
type: 'notify.blurred'
|
|
3718
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
3719
|
-
}
|
|
3720
|
-
| {
|
|
3721
|
-
type: 'notify.done loading'
|
|
3722
|
-
}
|
|
3723
|
-
| {
|
|
3724
|
-
type: 'notify.editable'
|
|
3725
|
-
}
|
|
3726
|
-
| {
|
|
3727
|
-
type: 'notify.error'
|
|
3728
|
-
name: string
|
|
3729
|
-
description: string
|
|
3730
|
-
data: unknown
|
|
3731
|
-
}
|
|
3732
|
-
| {
|
|
3733
|
-
type: 'notify.focused'
|
|
3734
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
3735
|
-
}
|
|
3736
|
-
| {
|
|
3737
|
-
type: 'notify.invalid value'
|
|
3738
|
-
resolution: InvalidValueResolution | null
|
|
3739
|
-
value: Array<PortableTextBlock> | undefined
|
|
3740
|
-
}
|
|
3741
|
-
| {
|
|
3742
|
-
type: 'notify.loading'
|
|
3743
|
-
}
|
|
3744
|
-
| {
|
|
3745
|
-
type: 'notify.read only'
|
|
3746
|
-
}
|
|
3747
|
-
| {
|
|
3748
|
-
type: 'notify.ready'
|
|
3749
|
-
}
|
|
3750
|
-
| {
|
|
3751
|
-
type: 'notify.selection'
|
|
1435
|
+
slateEditor?: PortableTextSlateEditor
|
|
1436
|
+
},
|
|
1437
|
+
{
|
|
1438
|
+
type: 'update selection'
|
|
3752
1439
|
selection: EditorSelection
|
|
3753
|
-
}
|
|
3754
|
-
| {
|
|
3755
|
-
type: 'notify.value changed'
|
|
3756
|
-
value: Array<PortableTextBlock> | undefined
|
|
3757
|
-
}
|
|
3758
|
-
| {
|
|
3759
|
-
type: 'notify.unset'
|
|
3760
|
-
previousValue: Array<PortableTextBlock>
|
|
3761
|
-
}
|
|
3762
|
-
| {
|
|
3763
|
-
type: 'dragstart'
|
|
3764
|
-
origin: Pick<EventPosition, 'selection'>
|
|
3765
|
-
ghost?: HTMLElement
|
|
3766
|
-
}
|
|
3767
|
-
| {
|
|
3768
|
-
type: 'dragend'
|
|
3769
|
-
}
|
|
3770
|
-
| {
|
|
3771
|
-
type: 'drop'
|
|
3772
1440
|
},
|
|
3773
|
-
|
|
3774
|
-
|
|
3775
|
-
|
|
3776
|
-
|
|
3777
|
-
|
|
3778
|
-
|
|
3779
|
-
|
|
1441
|
+
| InternalPatchEvent
|
|
1442
|
+
| MutationEvent
|
|
1443
|
+
| PatchesEvent
|
|
1444
|
+
| {
|
|
1445
|
+
type: 'update readOnly'
|
|
1446
|
+
readOnly: boolean
|
|
1447
|
+
}
|
|
1448
|
+
| {
|
|
1449
|
+
type: 'update maxBlocks'
|
|
1450
|
+
maxBlocks: number | undefined
|
|
1451
|
+
}
|
|
1452
|
+
| {
|
|
1453
|
+
type: 'add behavior'
|
|
1454
|
+
behaviorConfig: BehaviorConfig
|
|
1455
|
+
}
|
|
1456
|
+
| {
|
|
1457
|
+
type: 'remove behavior'
|
|
1458
|
+
behaviorConfig: BehaviorConfig
|
|
1459
|
+
}
|
|
1460
|
+
| {
|
|
1461
|
+
type: 'blur'
|
|
1462
|
+
editor: PortableTextSlateEditor
|
|
1463
|
+
}
|
|
1464
|
+
| {
|
|
1465
|
+
type: 'focus'
|
|
1466
|
+
editor: PortableTextSlateEditor
|
|
1467
|
+
}
|
|
1468
|
+
| {
|
|
1469
|
+
type: 'normalizing'
|
|
1470
|
+
}
|
|
1471
|
+
| {
|
|
1472
|
+
type: 'update selection'
|
|
1473
|
+
selection: EditorSelection
|
|
1474
|
+
}
|
|
1475
|
+
| {
|
|
1476
|
+
type: 'done normalizing'
|
|
1477
|
+
}
|
|
1478
|
+
| {
|
|
1479
|
+
type: 'done syncing value'
|
|
1480
|
+
}
|
|
1481
|
+
| {
|
|
1482
|
+
type: 'syncing value'
|
|
1483
|
+
}
|
|
1484
|
+
| {
|
|
1485
|
+
type: 'behavior event'
|
|
1486
|
+
behaviorEvent: BehaviorEvent
|
|
1487
|
+
editor: PortableTextSlateEditor
|
|
1488
|
+
nativeEvent?: {
|
|
1489
|
+
preventDefault: () => void
|
|
1490
|
+
}
|
|
1491
|
+
}
|
|
1492
|
+
| {
|
|
1493
|
+
type: 'dragstart'
|
|
1494
|
+
origin: Pick<EventPosition, 'selection'>
|
|
1495
|
+
ghost?: HTMLElement
|
|
1496
|
+
}
|
|
1497
|
+
| {
|
|
1498
|
+
type: 'dragend'
|
|
1499
|
+
}
|
|
1500
|
+
| {
|
|
1501
|
+
type: 'drop'
|
|
1502
|
+
},
|
|
1503
|
+
undefined,
|
|
1504
|
+
never,
|
|
1505
|
+
never,
|
|
1506
|
+
never,
|
|
1507
|
+
never,
|
|
1508
|
+
never
|
|
1509
|
+
>,
|
|
1510
|
+
]
|
|
3780
1511
|
}
|
|
3781
1512
|
}
|
|
3782
1513
|
readonly type: 'parallel'
|
|
@@ -3972,14 +1703,6 @@ declare const editorMachine: StateMachine<
|
|
|
3972
1703
|
type: 'update readOnly'
|
|
3973
1704
|
readOnly: boolean
|
|
3974
1705
|
}
|
|
3975
|
-
| {
|
|
3976
|
-
type: 'update schema'
|
|
3977
|
-
schema: EditorSchema
|
|
3978
|
-
}
|
|
3979
|
-
| {
|
|
3980
|
-
type: 'update key generator'
|
|
3981
|
-
keyGenerator: () => string
|
|
3982
|
-
}
|
|
3983
1706
|
| {
|
|
3984
1707
|
type: 'update maxBlocks'
|
|
3985
1708
|
maxBlocks: number | undefined
|
|
@@ -4004,77 +1727,25 @@ declare const editorMachine: StateMachine<
|
|
|
4004
1727
|
type: 'normalizing'
|
|
4005
1728
|
}
|
|
4006
1729
|
| {
|
|
4007
|
-
type: '
|
|
4008
|
-
|
|
4009
|
-
| {
|
|
4010
|
-
type: 'done syncing value'
|
|
4011
|
-
}
|
|
4012
|
-
| {
|
|
4013
|
-
type: 'syncing value'
|
|
4014
|
-
}
|
|
4015
|
-
| {
|
|
4016
|
-
type: 'behavior event'
|
|
4017
|
-
behaviorEvent: BehaviorEvent
|
|
4018
|
-
editor: PortableTextSlateEditor
|
|
4019
|
-
nativeEvent?: {
|
|
4020
|
-
preventDefault: () => void
|
|
4021
|
-
}
|
|
4022
|
-
}
|
|
4023
|
-
| {
|
|
4024
|
-
type: 'notify.patch'
|
|
4025
|
-
patch: Patch
|
|
4026
|
-
}
|
|
4027
|
-
| {
|
|
4028
|
-
type: 'notify.mutation'
|
|
4029
|
-
patches: Array<Patch>
|
|
4030
|
-
snapshot: Array<PortableTextBlock> | undefined
|
|
4031
|
-
value: Array<PortableTextBlock> | undefined
|
|
4032
|
-
}
|
|
4033
|
-
| {
|
|
4034
|
-
type: 'notify.blurred'
|
|
4035
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
4036
|
-
}
|
|
4037
|
-
| {
|
|
4038
|
-
type: 'notify.done loading'
|
|
4039
|
-
}
|
|
4040
|
-
| {
|
|
4041
|
-
type: 'notify.editable'
|
|
4042
|
-
}
|
|
4043
|
-
| {
|
|
4044
|
-
type: 'notify.error'
|
|
4045
|
-
name: string
|
|
4046
|
-
description: string
|
|
4047
|
-
data: unknown
|
|
4048
|
-
}
|
|
4049
|
-
| {
|
|
4050
|
-
type: 'notify.focused'
|
|
4051
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
4052
|
-
}
|
|
4053
|
-
| {
|
|
4054
|
-
type: 'notify.invalid value'
|
|
4055
|
-
resolution: InvalidValueResolution | null
|
|
4056
|
-
value: Array<PortableTextBlock> | undefined
|
|
4057
|
-
}
|
|
4058
|
-
| {
|
|
4059
|
-
type: 'notify.loading'
|
|
4060
|
-
}
|
|
4061
|
-
| {
|
|
4062
|
-
type: 'notify.read only'
|
|
1730
|
+
type: 'update selection'
|
|
1731
|
+
selection: EditorSelection
|
|
4063
1732
|
}
|
|
4064
1733
|
| {
|
|
4065
|
-
type: '
|
|
1734
|
+
type: 'done normalizing'
|
|
4066
1735
|
}
|
|
4067
1736
|
| {
|
|
4068
|
-
type: '
|
|
4069
|
-
selection: EditorSelection
|
|
1737
|
+
type: 'done syncing value'
|
|
4070
1738
|
}
|
|
4071
1739
|
| {
|
|
4072
|
-
type: '
|
|
4073
|
-
value: Array<PortableTextBlock> | undefined
|
|
1740
|
+
type: 'syncing value'
|
|
4074
1741
|
}
|
|
4075
1742
|
| {
|
|
4076
|
-
type: '
|
|
4077
|
-
|
|
1743
|
+
type: 'behavior event'
|
|
1744
|
+
behaviorEvent: BehaviorEvent
|
|
1745
|
+
editor: PortableTextSlateEditor
|
|
1746
|
+
nativeEvent?: {
|
|
1747
|
+
preventDefault: () => void
|
|
1748
|
+
}
|
|
4078
1749
|
}
|
|
4079
1750
|
| {
|
|
4080
1751
|
type: 'dragstart'
|
|
@@ -4138,14 +1809,6 @@ declare const editorMachine: StateMachine<
|
|
|
4138
1809
|
type: 'update readOnly'
|
|
4139
1810
|
readOnly: boolean
|
|
4140
1811
|
}
|
|
4141
|
-
| {
|
|
4142
|
-
type: 'update schema'
|
|
4143
|
-
schema: EditorSchema
|
|
4144
|
-
}
|
|
4145
|
-
| {
|
|
4146
|
-
type: 'update key generator'
|
|
4147
|
-
keyGenerator: () => string
|
|
4148
|
-
}
|
|
4149
1812
|
| {
|
|
4150
1813
|
type: 'update maxBlocks'
|
|
4151
1814
|
maxBlocks: number | undefined
|
|
@@ -4169,6 +1832,10 @@ declare const editorMachine: StateMachine<
|
|
|
4169
1832
|
| {
|
|
4170
1833
|
type: 'normalizing'
|
|
4171
1834
|
}
|
|
1835
|
+
| {
|
|
1836
|
+
type: 'update selection'
|
|
1837
|
+
selection: EditorSelection
|
|
1838
|
+
}
|
|
4172
1839
|
| {
|
|
4173
1840
|
type: 'done normalizing'
|
|
4174
1841
|
}
|
|
@@ -4186,62 +1853,6 @@ declare const editorMachine: StateMachine<
|
|
|
4186
1853
|
preventDefault: () => void
|
|
4187
1854
|
}
|
|
4188
1855
|
}
|
|
4189
|
-
| {
|
|
4190
|
-
type: 'notify.patch'
|
|
4191
|
-
patch: Patch
|
|
4192
|
-
}
|
|
4193
|
-
| {
|
|
4194
|
-
type: 'notify.mutation'
|
|
4195
|
-
patches: Array<Patch>
|
|
4196
|
-
snapshot: Array<PortableTextBlock> | undefined
|
|
4197
|
-
value: Array<PortableTextBlock> | undefined
|
|
4198
|
-
}
|
|
4199
|
-
| {
|
|
4200
|
-
type: 'notify.blurred'
|
|
4201
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
4202
|
-
}
|
|
4203
|
-
| {
|
|
4204
|
-
type: 'notify.done loading'
|
|
4205
|
-
}
|
|
4206
|
-
| {
|
|
4207
|
-
type: 'notify.editable'
|
|
4208
|
-
}
|
|
4209
|
-
| {
|
|
4210
|
-
type: 'notify.error'
|
|
4211
|
-
name: string
|
|
4212
|
-
description: string
|
|
4213
|
-
data: unknown
|
|
4214
|
-
}
|
|
4215
|
-
| {
|
|
4216
|
-
type: 'notify.focused'
|
|
4217
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
4218
|
-
}
|
|
4219
|
-
| {
|
|
4220
|
-
type: 'notify.invalid value'
|
|
4221
|
-
resolution: InvalidValueResolution | null
|
|
4222
|
-
value: Array<PortableTextBlock> | undefined
|
|
4223
|
-
}
|
|
4224
|
-
| {
|
|
4225
|
-
type: 'notify.loading'
|
|
4226
|
-
}
|
|
4227
|
-
| {
|
|
4228
|
-
type: 'notify.read only'
|
|
4229
|
-
}
|
|
4230
|
-
| {
|
|
4231
|
-
type: 'notify.ready'
|
|
4232
|
-
}
|
|
4233
|
-
| {
|
|
4234
|
-
type: 'notify.selection'
|
|
4235
|
-
selection: EditorSelection
|
|
4236
|
-
}
|
|
4237
|
-
| {
|
|
4238
|
-
type: 'notify.value changed'
|
|
4239
|
-
value: Array<PortableTextBlock> | undefined
|
|
4240
|
-
}
|
|
4241
|
-
| {
|
|
4242
|
-
type: 'notify.unset'
|
|
4243
|
-
previousValue: Array<PortableTextBlock>
|
|
4244
|
-
}
|
|
4245
1856
|
| {
|
|
4246
1857
|
type: 'dragstart'
|
|
4247
1858
|
origin: Pick<EventPosition, 'selection'>
|
|
@@ -4325,14 +1936,6 @@ declare const editorMachine: StateMachine<
|
|
|
4325
1936
|
type: 'update readOnly'
|
|
4326
1937
|
readOnly: boolean
|
|
4327
1938
|
}
|
|
4328
|
-
| {
|
|
4329
|
-
type: 'update schema'
|
|
4330
|
-
schema: EditorSchema
|
|
4331
|
-
}
|
|
4332
|
-
| {
|
|
4333
|
-
type: 'update key generator'
|
|
4334
|
-
keyGenerator: () => string
|
|
4335
|
-
}
|
|
4336
1939
|
| {
|
|
4337
1940
|
type: 'update maxBlocks'
|
|
4338
1941
|
maxBlocks: number | undefined
|
|
@@ -4356,6 +1959,10 @@ declare const editorMachine: StateMachine<
|
|
|
4356
1959
|
| {
|
|
4357
1960
|
type: 'normalizing'
|
|
4358
1961
|
}
|
|
1962
|
+
| {
|
|
1963
|
+
type: 'update selection'
|
|
1964
|
+
selection: EditorSelection
|
|
1965
|
+
}
|
|
4359
1966
|
| {
|
|
4360
1967
|
type: 'done normalizing'
|
|
4361
1968
|
}
|
|
@@ -4373,62 +1980,6 @@ declare const editorMachine: StateMachine<
|
|
|
4373
1980
|
preventDefault: () => void
|
|
4374
1981
|
}
|
|
4375
1982
|
}
|
|
4376
|
-
| {
|
|
4377
|
-
type: 'notify.patch'
|
|
4378
|
-
patch: Patch
|
|
4379
|
-
}
|
|
4380
|
-
| {
|
|
4381
|
-
type: 'notify.mutation'
|
|
4382
|
-
patches: Array<Patch>
|
|
4383
|
-
snapshot: Array<PortableTextBlock> | undefined
|
|
4384
|
-
value: Array<PortableTextBlock> | undefined
|
|
4385
|
-
}
|
|
4386
|
-
| {
|
|
4387
|
-
type: 'notify.blurred'
|
|
4388
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
4389
|
-
}
|
|
4390
|
-
| {
|
|
4391
|
-
type: 'notify.done loading'
|
|
4392
|
-
}
|
|
4393
|
-
| {
|
|
4394
|
-
type: 'notify.editable'
|
|
4395
|
-
}
|
|
4396
|
-
| {
|
|
4397
|
-
type: 'notify.error'
|
|
4398
|
-
name: string
|
|
4399
|
-
description: string
|
|
4400
|
-
data: unknown
|
|
4401
|
-
}
|
|
4402
|
-
| {
|
|
4403
|
-
type: 'notify.focused'
|
|
4404
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
4405
|
-
}
|
|
4406
|
-
| {
|
|
4407
|
-
type: 'notify.invalid value'
|
|
4408
|
-
resolution: InvalidValueResolution | null
|
|
4409
|
-
value: Array<PortableTextBlock> | undefined
|
|
4410
|
-
}
|
|
4411
|
-
| {
|
|
4412
|
-
type: 'notify.loading'
|
|
4413
|
-
}
|
|
4414
|
-
| {
|
|
4415
|
-
type: 'notify.read only'
|
|
4416
|
-
}
|
|
4417
|
-
| {
|
|
4418
|
-
type: 'notify.ready'
|
|
4419
|
-
}
|
|
4420
|
-
| {
|
|
4421
|
-
type: 'notify.selection'
|
|
4422
|
-
selection: EditorSelection
|
|
4423
|
-
}
|
|
4424
|
-
| {
|
|
4425
|
-
type: 'notify.value changed'
|
|
4426
|
-
value: Array<PortableTextBlock> | undefined
|
|
4427
|
-
}
|
|
4428
|
-
| {
|
|
4429
|
-
type: 'notify.unset'
|
|
4430
|
-
previousValue: Array<PortableTextBlock>
|
|
4431
|
-
}
|
|
4432
1983
|
| {
|
|
4433
1984
|
type: 'dragstart'
|
|
4434
1985
|
origin: Pick<EventPosition, 'selection'>
|
|
@@ -4447,14 +1998,6 @@ declare const editorMachine: StateMachine<
|
|
|
4447
1998
|
type: 'update readOnly'
|
|
4448
1999
|
readOnly: boolean
|
|
4449
2000
|
}
|
|
4450
|
-
| {
|
|
4451
|
-
type: 'update schema'
|
|
4452
|
-
schema: EditorSchema
|
|
4453
|
-
}
|
|
4454
|
-
| {
|
|
4455
|
-
type: 'update key generator'
|
|
4456
|
-
keyGenerator: () => string
|
|
4457
|
-
}
|
|
4458
2001
|
| {
|
|
4459
2002
|
type: 'update maxBlocks'
|
|
4460
2003
|
maxBlocks: number | undefined
|
|
@@ -4478,6 +2021,10 @@ declare const editorMachine: StateMachine<
|
|
|
4478
2021
|
| {
|
|
4479
2022
|
type: 'normalizing'
|
|
4480
2023
|
}
|
|
2024
|
+
| {
|
|
2025
|
+
type: 'update selection'
|
|
2026
|
+
selection: EditorSelection
|
|
2027
|
+
}
|
|
4481
2028
|
| {
|
|
4482
2029
|
type: 'done normalizing'
|
|
4483
2030
|
}
|
|
@@ -4495,62 +2042,6 @@ declare const editorMachine: StateMachine<
|
|
|
4495
2042
|
preventDefault: () => void
|
|
4496
2043
|
}
|
|
4497
2044
|
}
|
|
4498
|
-
| {
|
|
4499
|
-
type: 'notify.patch'
|
|
4500
|
-
patch: Patch
|
|
4501
|
-
}
|
|
4502
|
-
| {
|
|
4503
|
-
type: 'notify.mutation'
|
|
4504
|
-
patches: Array<Patch>
|
|
4505
|
-
snapshot: Array<PortableTextBlock> | undefined
|
|
4506
|
-
value: Array<PortableTextBlock> | undefined
|
|
4507
|
-
}
|
|
4508
|
-
| {
|
|
4509
|
-
type: 'notify.blurred'
|
|
4510
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
4511
|
-
}
|
|
4512
|
-
| {
|
|
4513
|
-
type: 'notify.done loading'
|
|
4514
|
-
}
|
|
4515
|
-
| {
|
|
4516
|
-
type: 'notify.editable'
|
|
4517
|
-
}
|
|
4518
|
-
| {
|
|
4519
|
-
type: 'notify.error'
|
|
4520
|
-
name: string
|
|
4521
|
-
description: string
|
|
4522
|
-
data: unknown
|
|
4523
|
-
}
|
|
4524
|
-
| {
|
|
4525
|
-
type: 'notify.focused'
|
|
4526
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
4527
|
-
}
|
|
4528
|
-
| {
|
|
4529
|
-
type: 'notify.invalid value'
|
|
4530
|
-
resolution: InvalidValueResolution | null
|
|
4531
|
-
value: Array<PortableTextBlock> | undefined
|
|
4532
|
-
}
|
|
4533
|
-
| {
|
|
4534
|
-
type: 'notify.loading'
|
|
4535
|
-
}
|
|
4536
|
-
| {
|
|
4537
|
-
type: 'notify.read only'
|
|
4538
|
-
}
|
|
4539
|
-
| {
|
|
4540
|
-
type: 'notify.ready'
|
|
4541
|
-
}
|
|
4542
|
-
| {
|
|
4543
|
-
type: 'notify.selection'
|
|
4544
|
-
selection: EditorSelection
|
|
4545
|
-
}
|
|
4546
|
-
| {
|
|
4547
|
-
type: 'notify.value changed'
|
|
4548
|
-
value: Array<PortableTextBlock> | undefined
|
|
4549
|
-
}
|
|
4550
|
-
| {
|
|
4551
|
-
type: 'notify.unset'
|
|
4552
|
-
previousValue: Array<PortableTextBlock>
|
|
4553
|
-
}
|
|
4554
2045
|
| {
|
|
4555
2046
|
type: 'dragstart'
|
|
4556
2047
|
origin: Pick<EventPosition, 'selection'>
|
|
@@ -4589,14 +2080,6 @@ declare const editorMachine: StateMachine<
|
|
|
4589
2080
|
type: 'update readOnly'
|
|
4590
2081
|
readOnly: boolean
|
|
4591
2082
|
}
|
|
4592
|
-
| {
|
|
4593
|
-
type: 'update schema'
|
|
4594
|
-
schema: EditorSchema
|
|
4595
|
-
}
|
|
4596
|
-
| {
|
|
4597
|
-
type: 'update key generator'
|
|
4598
|
-
keyGenerator: () => string
|
|
4599
|
-
}
|
|
4600
2083
|
| {
|
|
4601
2084
|
type: 'update maxBlocks'
|
|
4602
2085
|
maxBlocks: number | undefined
|
|
@@ -4620,6 +2103,10 @@ declare const editorMachine: StateMachine<
|
|
|
4620
2103
|
| {
|
|
4621
2104
|
type: 'normalizing'
|
|
4622
2105
|
}
|
|
2106
|
+
| {
|
|
2107
|
+
type: 'update selection'
|
|
2108
|
+
selection: EditorSelection
|
|
2109
|
+
}
|
|
4623
2110
|
| {
|
|
4624
2111
|
type: 'done normalizing'
|
|
4625
2112
|
}
|
|
@@ -4637,62 +2124,6 @@ declare const editorMachine: StateMachine<
|
|
|
4637
2124
|
preventDefault: () => void
|
|
4638
2125
|
}
|
|
4639
2126
|
}
|
|
4640
|
-
| {
|
|
4641
|
-
type: 'notify.patch'
|
|
4642
|
-
patch: Patch
|
|
4643
|
-
}
|
|
4644
|
-
| {
|
|
4645
|
-
type: 'notify.mutation'
|
|
4646
|
-
patches: Array<Patch>
|
|
4647
|
-
snapshot: Array<PortableTextBlock> | undefined
|
|
4648
|
-
value: Array<PortableTextBlock> | undefined
|
|
4649
|
-
}
|
|
4650
|
-
| {
|
|
4651
|
-
type: 'notify.blurred'
|
|
4652
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
4653
|
-
}
|
|
4654
|
-
| {
|
|
4655
|
-
type: 'notify.done loading'
|
|
4656
|
-
}
|
|
4657
|
-
| {
|
|
4658
|
-
type: 'notify.editable'
|
|
4659
|
-
}
|
|
4660
|
-
| {
|
|
4661
|
-
type: 'notify.error'
|
|
4662
|
-
name: string
|
|
4663
|
-
description: string
|
|
4664
|
-
data: unknown
|
|
4665
|
-
}
|
|
4666
|
-
| {
|
|
4667
|
-
type: 'notify.focused'
|
|
4668
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
4669
|
-
}
|
|
4670
|
-
| {
|
|
4671
|
-
type: 'notify.invalid value'
|
|
4672
|
-
resolution: InvalidValueResolution | null
|
|
4673
|
-
value: Array<PortableTextBlock> | undefined
|
|
4674
|
-
}
|
|
4675
|
-
| {
|
|
4676
|
-
type: 'notify.loading'
|
|
4677
|
-
}
|
|
4678
|
-
| {
|
|
4679
|
-
type: 'notify.read only'
|
|
4680
|
-
}
|
|
4681
|
-
| {
|
|
4682
|
-
type: 'notify.ready'
|
|
4683
|
-
}
|
|
4684
|
-
| {
|
|
4685
|
-
type: 'notify.selection'
|
|
4686
|
-
selection: EditorSelection
|
|
4687
|
-
}
|
|
4688
|
-
| {
|
|
4689
|
-
type: 'notify.value changed'
|
|
4690
|
-
value: Array<PortableTextBlock> | undefined
|
|
4691
|
-
}
|
|
4692
|
-
| {
|
|
4693
|
-
type: 'notify.unset'
|
|
4694
|
-
previousValue: Array<PortableTextBlock>
|
|
4695
|
-
}
|
|
4696
2127
|
| {
|
|
4697
2128
|
type: 'dragstart'
|
|
4698
2129
|
origin: Pick<EventPosition, 'selection'>
|
|
@@ -4711,14 +2142,6 @@ declare const editorMachine: StateMachine<
|
|
|
4711
2142
|
type: 'update readOnly'
|
|
4712
2143
|
readOnly: boolean
|
|
4713
2144
|
}
|
|
4714
|
-
| {
|
|
4715
|
-
type: 'update schema'
|
|
4716
|
-
schema: EditorSchema
|
|
4717
|
-
}
|
|
4718
|
-
| {
|
|
4719
|
-
type: 'update key generator'
|
|
4720
|
-
keyGenerator: () => string
|
|
4721
|
-
}
|
|
4722
2145
|
| {
|
|
4723
2146
|
type: 'update maxBlocks'
|
|
4724
2147
|
maxBlocks: number | undefined
|
|
@@ -4742,6 +2165,10 @@ declare const editorMachine: StateMachine<
|
|
|
4742
2165
|
| {
|
|
4743
2166
|
type: 'normalizing'
|
|
4744
2167
|
}
|
|
2168
|
+
| {
|
|
2169
|
+
type: 'update selection'
|
|
2170
|
+
selection: EditorSelection
|
|
2171
|
+
}
|
|
4745
2172
|
| {
|
|
4746
2173
|
type: 'done normalizing'
|
|
4747
2174
|
}
|
|
@@ -4759,62 +2186,6 @@ declare const editorMachine: StateMachine<
|
|
|
4759
2186
|
preventDefault: () => void
|
|
4760
2187
|
}
|
|
4761
2188
|
}
|
|
4762
|
-
| {
|
|
4763
|
-
type: 'notify.patch'
|
|
4764
|
-
patch: Patch
|
|
4765
|
-
}
|
|
4766
|
-
| {
|
|
4767
|
-
type: 'notify.mutation'
|
|
4768
|
-
patches: Array<Patch>
|
|
4769
|
-
snapshot: Array<PortableTextBlock> | undefined
|
|
4770
|
-
value: Array<PortableTextBlock> | undefined
|
|
4771
|
-
}
|
|
4772
|
-
| {
|
|
4773
|
-
type: 'notify.blurred'
|
|
4774
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
4775
|
-
}
|
|
4776
|
-
| {
|
|
4777
|
-
type: 'notify.done loading'
|
|
4778
|
-
}
|
|
4779
|
-
| {
|
|
4780
|
-
type: 'notify.editable'
|
|
4781
|
-
}
|
|
4782
|
-
| {
|
|
4783
|
-
type: 'notify.error'
|
|
4784
|
-
name: string
|
|
4785
|
-
description: string
|
|
4786
|
-
data: unknown
|
|
4787
|
-
}
|
|
4788
|
-
| {
|
|
4789
|
-
type: 'notify.focused'
|
|
4790
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
4791
|
-
}
|
|
4792
|
-
| {
|
|
4793
|
-
type: 'notify.invalid value'
|
|
4794
|
-
resolution: InvalidValueResolution | null
|
|
4795
|
-
value: Array<PortableTextBlock> | undefined
|
|
4796
|
-
}
|
|
4797
|
-
| {
|
|
4798
|
-
type: 'notify.loading'
|
|
4799
|
-
}
|
|
4800
|
-
| {
|
|
4801
|
-
type: 'notify.read only'
|
|
4802
|
-
}
|
|
4803
|
-
| {
|
|
4804
|
-
type: 'notify.ready'
|
|
4805
|
-
}
|
|
4806
|
-
| {
|
|
4807
|
-
type: 'notify.selection'
|
|
4808
|
-
selection: EditorSelection
|
|
4809
|
-
}
|
|
4810
|
-
| {
|
|
4811
|
-
type: 'notify.value changed'
|
|
4812
|
-
value: Array<PortableTextBlock> | undefined
|
|
4813
|
-
}
|
|
4814
|
-
| {
|
|
4815
|
-
type: 'notify.unset'
|
|
4816
|
-
previousValue: Array<PortableTextBlock>
|
|
4817
|
-
}
|
|
4818
2189
|
| {
|
|
4819
2190
|
type: 'dragstart'
|
|
4820
2191
|
origin: Pick<EventPosition, 'selection'>
|
|
@@ -4915,14 +2286,6 @@ declare const editorMachine: StateMachine<
|
|
|
4915
2286
|
type: 'update readOnly'
|
|
4916
2287
|
readOnly: boolean
|
|
4917
2288
|
}
|
|
4918
|
-
| {
|
|
4919
|
-
type: 'update schema'
|
|
4920
|
-
schema: EditorSchema
|
|
4921
|
-
}
|
|
4922
|
-
| {
|
|
4923
|
-
type: 'update key generator'
|
|
4924
|
-
keyGenerator: () => string
|
|
4925
|
-
}
|
|
4926
2289
|
| {
|
|
4927
2290
|
type: 'update maxBlocks'
|
|
4928
2291
|
maxBlocks: number | undefined
|
|
@@ -4946,6 +2309,10 @@ declare const editorMachine: StateMachine<
|
|
|
4946
2309
|
| {
|
|
4947
2310
|
type: 'normalizing'
|
|
4948
2311
|
}
|
|
2312
|
+
| {
|
|
2313
|
+
type: 'update selection'
|
|
2314
|
+
selection: EditorSelection
|
|
2315
|
+
}
|
|
4949
2316
|
| {
|
|
4950
2317
|
type: 'done normalizing'
|
|
4951
2318
|
}
|
|
@@ -4963,62 +2330,6 @@ declare const editorMachine: StateMachine<
|
|
|
4963
2330
|
preventDefault: () => void
|
|
4964
2331
|
}
|
|
4965
2332
|
}
|
|
4966
|
-
| {
|
|
4967
|
-
type: 'notify.patch'
|
|
4968
|
-
patch: Patch
|
|
4969
|
-
}
|
|
4970
|
-
| {
|
|
4971
|
-
type: 'notify.mutation'
|
|
4972
|
-
patches: Array<Patch>
|
|
4973
|
-
snapshot: Array<PortableTextBlock> | undefined
|
|
4974
|
-
value: Array<PortableTextBlock> | undefined
|
|
4975
|
-
}
|
|
4976
|
-
| {
|
|
4977
|
-
type: 'notify.blurred'
|
|
4978
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
4979
|
-
}
|
|
4980
|
-
| {
|
|
4981
|
-
type: 'notify.done loading'
|
|
4982
|
-
}
|
|
4983
|
-
| {
|
|
4984
|
-
type: 'notify.editable'
|
|
4985
|
-
}
|
|
4986
|
-
| {
|
|
4987
|
-
type: 'notify.error'
|
|
4988
|
-
name: string
|
|
4989
|
-
description: string
|
|
4990
|
-
data: unknown
|
|
4991
|
-
}
|
|
4992
|
-
| {
|
|
4993
|
-
type: 'notify.focused'
|
|
4994
|
-
event: FocusEvent_2<HTMLDivElement, Element>
|
|
4995
|
-
}
|
|
4996
|
-
| {
|
|
4997
|
-
type: 'notify.invalid value'
|
|
4998
|
-
resolution: InvalidValueResolution | null
|
|
4999
|
-
value: Array<PortableTextBlock> | undefined
|
|
5000
|
-
}
|
|
5001
|
-
| {
|
|
5002
|
-
type: 'notify.loading'
|
|
5003
|
-
}
|
|
5004
|
-
| {
|
|
5005
|
-
type: 'notify.read only'
|
|
5006
|
-
}
|
|
5007
|
-
| {
|
|
5008
|
-
type: 'notify.ready'
|
|
5009
|
-
}
|
|
5010
|
-
| {
|
|
5011
|
-
type: 'notify.selection'
|
|
5012
|
-
selection: EditorSelection
|
|
5013
|
-
}
|
|
5014
|
-
| {
|
|
5015
|
-
type: 'notify.value changed'
|
|
5016
|
-
value: Array<PortableTextBlock> | undefined
|
|
5017
|
-
}
|
|
5018
|
-
| {
|
|
5019
|
-
type: 'notify.unset'
|
|
5020
|
-
previousValue: Array<PortableTextBlock>
|
|
5021
|
-
}
|
|
5022
2333
|
| {
|
|
5023
2334
|
type: 'dragstart'
|
|
5024
2335
|
origin: Pick<EventPosition, 'selection'>
|
|
@@ -5035,7 +2346,6 @@ declare const editorMachine: StateMachine<
|
|
|
5035
2346
|
never,
|
|
5036
2347
|
never,
|
|
5037
2348
|
never,
|
|
5038
|
-
| PatchEvent
|
|
5039
2349
|
| InternalPatchEvent
|
|
5040
2350
|
| MutationEvent
|
|
5041
2351
|
| PatchesEvent
|
|
@@ -5049,19 +2359,13 @@ declare const editorMachine: StateMachine<
|
|
|
5049
2359
|
| {
|
|
5050
2360
|
type: 'editable'
|
|
5051
2361
|
}
|
|
5052
|
-
| {
|
|
5053
|
-
type: 'error'
|
|
5054
|
-
name: string
|
|
5055
|
-
description: string
|
|
5056
|
-
data: unknown
|
|
5057
|
-
}
|
|
5058
2362
|
| {
|
|
5059
2363
|
type: 'focused'
|
|
5060
2364
|
event: FocusEvent_2<HTMLDivElement, Element>
|
|
5061
2365
|
}
|
|
5062
2366
|
| {
|
|
5063
2367
|
type: 'invalid value'
|
|
5064
|
-
resolution:
|
|
2368
|
+
resolution: InvalidValueResolution_2 | null
|
|
5065
2369
|
value: Array<PortableTextBlock> | undefined
|
|
5066
2370
|
}
|
|
5067
2371
|
| {
|
|
@@ -5081,7 +2385,6 @@ declare const editorMachine: StateMachine<
|
|
|
5081
2385
|
type: 'value changed'
|
|
5082
2386
|
value: Array<PortableTextBlock> | undefined
|
|
5083
2387
|
}
|
|
5084
|
-
| UnsetEvent
|
|
5085
2388
|
>,
|
|
5086
2389
|
]
|
|
5087
2390
|
}
|
|
@@ -5317,7 +2620,9 @@ export declare type EditorSnapshot = {
|
|
|
5317
2620
|
|
|
5318
2621
|
/**
|
|
5319
2622
|
* The editor produced an error
|
|
5320
|
-
* @beta
|
|
2623
|
+
* @beta
|
|
2624
|
+
* @deprecated The change is no longer emitted
|
|
2625
|
+
* */
|
|
5321
2626
|
export declare type ErrorChange = {
|
|
5322
2627
|
type: 'error'
|
|
5323
2628
|
name: string
|
|
@@ -5373,14 +2678,6 @@ declare type ExternalEditorEvent =
|
|
|
5373
2678
|
type: 'update readOnly'
|
|
5374
2679
|
readOnly: boolean
|
|
5375
2680
|
}
|
|
5376
|
-
| {
|
|
5377
|
-
type: 'update schema'
|
|
5378
|
-
schema: EditorSchema
|
|
5379
|
-
}
|
|
5380
|
-
| {
|
|
5381
|
-
type: 'update key generator'
|
|
5382
|
-
keyGenerator: () => string
|
|
5383
|
-
}
|
|
5384
2681
|
| {
|
|
5385
2682
|
type: 'update maxBlocks'
|
|
5386
2683
|
maxBlocks: number | undefined
|
|
@@ -6347,7 +3644,9 @@ export declare type ReadyChange = {
|
|
|
6347
3644
|
|
|
6348
3645
|
/**
|
|
6349
3646
|
* The editor performed redo history step
|
|
6350
|
-
* @beta
|
|
3647
|
+
* @beta
|
|
3648
|
+
* @deprecated The change is no longer emitted
|
|
3649
|
+
* */
|
|
6351
3650
|
export declare type RedoChange = {
|
|
6352
3651
|
type: 'redo'
|
|
6353
3652
|
patches: Patch[]
|
|
@@ -6627,7 +3926,9 @@ declare type TextBlockWithOptionalKey = Omit<PortableTextTextBlock, '_key'> & {
|
|
|
6627
3926
|
|
|
6628
3927
|
/**
|
|
6629
3928
|
* The editor performed a undo history step
|
|
6630
|
-
* @beta
|
|
3929
|
+
* @beta
|
|
3930
|
+
* @deprecated The change is no longer emitted
|
|
3931
|
+
* */
|
|
6631
3932
|
export declare type UndoChange = {
|
|
6632
3933
|
type: 'undo'
|
|
6633
3934
|
patches: Patch[]
|
|
@@ -6640,11 +3941,6 @@ export declare type UnsetChange = {
|
|
|
6640
3941
|
previousValue: PortableTextBlock[]
|
|
6641
3942
|
}
|
|
6642
3943
|
|
|
6643
|
-
declare type UnsetEvent = {
|
|
6644
|
-
type: 'unset'
|
|
6645
|
-
previousValue: Array<PortableTextBlock>
|
|
6646
|
-
}
|
|
6647
|
-
|
|
6648
3944
|
/**
|
|
6649
3945
|
* @public
|
|
6650
3946
|
* Get the current editor context from the `EditorProvider`.
|