@portabletext/editor 1.39.0 → 1.40.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (109) hide show
  1. package/lib/_chunks-cjs/behavior.core.cjs +16 -5
  2. package/lib/_chunks-cjs/behavior.core.cjs.map +1 -1
  3. package/lib/_chunks-cjs/editor-provider.cjs +158 -153
  4. package/lib/_chunks-cjs/editor-provider.cjs.map +1 -1
  5. package/lib/_chunks-cjs/selector.get-text-before.cjs +0 -1
  6. package/lib/_chunks-cjs/selector.get-text-before.cjs.map +1 -1
  7. package/lib/_chunks-cjs/selector.is-at-the-start-of-block.cjs +0 -3
  8. package/lib/_chunks-cjs/selector.is-at-the-start-of-block.cjs.map +1 -1
  9. package/lib/_chunks-cjs/selector.is-overlapping-selection.cjs +0 -4
  10. package/lib/_chunks-cjs/selector.is-overlapping-selection.cjs.map +1 -1
  11. package/lib/_chunks-cjs/{parse-blocks.cjs → util.selection-point-to-block-offset.cjs} +74 -4
  12. package/lib/_chunks-cjs/util.selection-point-to-block-offset.cjs.map +1 -0
  13. package/lib/_chunks-cjs/util.slice-blocks.cjs +2 -2
  14. package/lib/_chunks-cjs/util.slice-blocks.cjs.map +1 -1
  15. package/lib/_chunks-cjs/util.split-text-block.cjs +68 -0
  16. package/lib/_chunks-cjs/util.split-text-block.cjs.map +1 -0
  17. package/lib/_chunks-es/behavior.core.js +17 -6
  18. package/lib/_chunks-es/behavior.core.js.map +1 -1
  19. package/lib/_chunks-es/editor-provider.js +155 -150
  20. package/lib/_chunks-es/editor-provider.js.map +1 -1
  21. package/lib/_chunks-es/selector.get-text-before.js +1 -2
  22. package/lib/_chunks-es/selector.get-text-before.js.map +1 -1
  23. package/lib/_chunks-es/selector.is-at-the-start-of-block.js +1 -4
  24. package/lib/_chunks-es/selector.is-at-the-start-of-block.js.map +1 -1
  25. package/lib/_chunks-es/selector.is-overlapping-selection.js +1 -5
  26. package/lib/_chunks-es/selector.is-overlapping-selection.js.map +1 -1
  27. package/lib/_chunks-es/{parse-blocks.js → util.selection-point-to-block-offset.js} +76 -5
  28. package/lib/_chunks-es/util.selection-point-to-block-offset.js.map +1 -0
  29. package/lib/_chunks-es/util.slice-blocks.js +2 -2
  30. package/lib/_chunks-es/util.slice-blocks.js.map +1 -1
  31. package/lib/_chunks-es/util.split-text-block.js +70 -0
  32. package/lib/_chunks-es/util.split-text-block.js.map +1 -0
  33. package/lib/behaviors/index.d.cts +1516 -911
  34. package/lib/behaviors/index.d.ts +1516 -911
  35. package/lib/index.cjs +197 -200
  36. package/lib/index.cjs.map +1 -1
  37. package/lib/index.d.cts +1247 -717
  38. package/lib/index.d.ts +1247 -717
  39. package/lib/index.js +204 -207
  40. package/lib/index.js.map +1 -1
  41. package/lib/plugins/index.cjs +11 -12
  42. package/lib/plugins/index.cjs.map +1 -1
  43. package/lib/plugins/index.d.cts +1238 -721
  44. package/lib/plugins/index.d.ts +1238 -721
  45. package/lib/plugins/index.js +3 -4
  46. package/lib/plugins/index.js.map +1 -1
  47. package/lib/selectors/index.d.cts +1237 -710
  48. package/lib/selectors/index.d.ts +1237 -710
  49. package/lib/utils/index.cjs +15 -87
  50. package/lib/utils/index.cjs.map +1 -1
  51. package/lib/utils/index.d.cts +1290 -713
  52. package/lib/utils/index.d.ts +1290 -713
  53. package/lib/utils/index.js +13 -86
  54. package/lib/utils/index.js.map +1 -1
  55. package/package.json +10 -10
  56. package/src/behavior-actions/behavior.action.decorator.add.ts +13 -2
  57. package/src/behaviors/behavior.core.block-objects.ts +32 -2
  58. package/src/behaviors/behavior.default.ts +59 -16
  59. package/src/behaviors/behavior.types.ts +67 -30
  60. package/src/editor/Editable.tsx +122 -68
  61. package/src/editor/PortableTextEditor.tsx +8 -8
  62. package/src/editor/__tests__/self-solving.test.tsx +1 -1
  63. package/src/editor/components/Element.tsx +1 -3
  64. package/src/editor/create-editor.ts +13 -5
  65. package/src/editor/editor-machine.ts +13 -3
  66. package/src/editor/editor-provider.tsx +11 -7
  67. package/src/editor/editor-selector.ts +4 -3
  68. package/src/editor/editor-snapshot.ts +2 -2
  69. package/src/editor/plugins/create-with-event-listeners.ts +18 -3
  70. package/src/editor/plugins/createWithPortableTextMarkModel.ts +1 -2
  71. package/src/internal-utils/block-keys.ts +9 -0
  72. package/src/internal-utils/collapse-selection.ts +36 -0
  73. package/src/internal-utils/compound-client-rect.ts +28 -0
  74. package/src/internal-utils/drag-selection.test.ts +507 -0
  75. package/src/internal-utils/drag-selection.ts +66 -0
  76. package/src/internal-utils/editor-selection.test.ts +40 -0
  77. package/src/internal-utils/editor-selection.ts +60 -0
  78. package/src/internal-utils/event-position.ts +55 -80
  79. package/src/internal-utils/inline-object-selection.ts +115 -0
  80. package/src/internal-utils/selection-block-keys.ts +20 -0
  81. package/src/internal-utils/selection-elements.ts +61 -0
  82. package/src/internal-utils/selection-focus-text.ts +38 -0
  83. package/src/internal-utils/selection-text.test.ts +23 -0
  84. package/src/internal-utils/selection-text.ts +90 -0
  85. package/src/internal-utils/split-string.ts +12 -0
  86. package/src/internal-utils/string-overlap.test.ts +14 -0
  87. package/src/internal-utils/string-overlap.ts +28 -0
  88. package/src/internal-utils/string-utils.ts +7 -0
  89. package/src/internal-utils/terse-pt.test.ts +60 -0
  90. package/src/internal-utils/terse-pt.ts +36 -0
  91. package/src/internal-utils/text-block-key.test.ts +30 -0
  92. package/src/internal-utils/text-block-key.ts +30 -0
  93. package/src/internal-utils/text-marks.test.ts +33 -0
  94. package/src/internal-utils/text-marks.ts +26 -0
  95. package/src/internal-utils/text-selection.test.ts +175 -0
  96. package/src/internal-utils/text-selection.ts +122 -0
  97. package/src/internal-utils/value-annotations.ts +31 -0
  98. package/src/internal-utils/values.ts +16 -5
  99. package/src/utils/index.ts +5 -0
  100. package/src/utils/util.block-offset-to-block-selection-point.ts +28 -0
  101. package/src/utils/util.block-offset-to-selection-point.ts +33 -0
  102. package/src/utils/util.block-offsets-to-selection.ts +3 -3
  103. package/src/utils/util.is-equal-selections.ts +20 -0
  104. package/src/utils/util.is-selection-collapsed.ts +15 -0
  105. package/src/utils/util.reverse-selection.ts +9 -5
  106. package/src/utils/util.selection-point-to-block-offset.ts +31 -0
  107. package/lib/_chunks-cjs/parse-blocks.cjs.map +0 -1
  108. package/lib/_chunks-es/parse-blocks.js.map +0 -1
  109. package/src/editor/components/use-draggable.ts +0 -123
@@ -52,7 +52,10 @@ import {
52
52
  BlockOffset as BlockOffset_2,
53
53
  PortableTextMemberSchemaTypes as PortableTextMemberSchemaTypes_2,
54
54
  } from '..'
55
- import {InsertPlacement as InsertPlacement_2} from '../behaviors/behavior.types'
55
+ import {
56
+ InputBehaviorEvent as InputBehaviorEvent_2,
57
+ InsertPlacement as InsertPlacement_2,
58
+ } from '../behaviors/behavior.types'
56
59
  import {MIMEType as MIMEType_2} from '../internal-utils/mime-type'
57
60
  import {PickFromUnion as PickFromUnion_2} from '../type-utils'
58
61
 
@@ -68,11 +71,13 @@ declare type Behavior<
68
71
  ? ClipboardBehaviorEvent
69
72
  : TBehaviorEventType extends 'drag.*'
70
73
  ? DragBehaviorEvent
71
- : TBehaviorEventType extends 'keyboard.*'
72
- ? KeyboardBehaviorEvent
73
- : TBehaviorEventType extends 'mouse.*'
74
- ? MouseBehaviorEvent
75
- : PickFromUnion<BehaviorEvent, 'type', TBehaviorEventType>,
74
+ : TBehaviorEventType extends 'input.*'
75
+ ? InputBehaviorEvent
76
+ : TBehaviorEventType extends 'keyboard.*'
77
+ ? KeyboardBehaviorEvent
78
+ : TBehaviorEventType extends 'mouse.*'
79
+ ? MouseBehaviorEvent
80
+ : PickFromUnion<BehaviorEvent, 'type', TBehaviorEventType>,
76
81
  > = {
77
82
  /**
78
83
  * The internal editor event that triggers this behavior.
@@ -140,6 +145,9 @@ declare type BehaviorEvent =
140
145
  | {
141
146
  type: 'drag.*'
142
147
  }
148
+ | {
149
+ type: 'input.*'
150
+ }
143
151
  | {
144
152
  type: 'keyboard.*'
145
153
  }
@@ -174,21 +182,21 @@ declare type ClipboardBehaviorEvent =
174
182
  originEvent: {
175
183
  dataTransfer: DataTransfer
176
184
  }
177
- position: EventPosition
185
+ position: Pick<EventPosition, 'selection'>
178
186
  }
179
187
  | {
180
188
  type: 'clipboard.cut'
181
189
  originEvent: {
182
190
  dataTransfer: DataTransfer
183
191
  }
184
- position: EventPosition
192
+ position: Pick<EventPosition, 'selection'>
185
193
  }
186
194
  | {
187
195
  type: 'clipboard.paste'
188
196
  originEvent: {
189
197
  dataTransfer: DataTransfer
190
198
  }
191
- position: EventPosition
199
+ position: Pick<EventPosition, 'selection'>
192
200
  }
193
201
 
194
202
  declare type Converter<TMIMEType extends MIMEType = MIMEType> = {
@@ -243,11 +251,13 @@ declare type CustomBehaviorEvent<
243
251
  declare type DataBehaviorEvent =
244
252
  | {
245
253
  type: 'deserialize'
246
- originEvent: PickFromUnion<
247
- NativeBehaviorEvent,
248
- 'type',
249
- 'drag.drop' | 'clipboard.paste'
250
- >
254
+ originEvent:
255
+ | PickFromUnion<
256
+ NativeBehaviorEvent,
257
+ 'type',
258
+ 'drag.drop' | 'clipboard.paste'
259
+ >
260
+ | InputBehaviorEvent
251
261
  }
252
262
  | {
253
263
  type: 'serialize'
@@ -276,7 +286,7 @@ declare type DragBehaviorEvent =
276
286
  originEvent: {
277
287
  dataTransfer: DataTransfer
278
288
  }
279
- position: EventPosition
289
+ position: Pick<EventPosition, 'selection'>
280
290
  }
281
291
  | {
282
292
  type: 'drag.drag'
@@ -441,7 +451,7 @@ declare const editorMachine: StateMachine<
441
451
  value: Array<PortableTextBlock> | undefined
442
452
  internalDrag?: {
443
453
  ghost?: HTMLElement
444
- origin: EventPosition
454
+ origin: Pick<EventPosition, 'selection'>
445
455
  }
446
456
  },
447
457
  | {
@@ -502,6 +512,10 @@ declare const editorMachine: StateMachine<
502
512
  | {
503
513
  type: 'decorator.toggle'
504
514
  decorator: string
515
+ offsets?: {
516
+ anchor: BlockOffset_2
517
+ focus: BlockOffset_2
518
+ }
505
519
  }
506
520
  | {
507
521
  type: 'delete'
@@ -646,22 +660,26 @@ declare const editorMachine: StateMachine<
646
660
  mimeType: `${string}/${string}`
647
661
  reason: string
648
662
  } & {
649
- originEvent: PickFromUnion_2<
650
- NativeBehaviorEvent,
651
- 'type',
652
- 'drag.drop' | 'clipboard.paste'
653
- >
663
+ originEvent:
664
+ | PickFromUnion_2<
665
+ NativeBehaviorEvent,
666
+ 'type',
667
+ 'drag.drop' | 'clipboard.paste'
668
+ >
669
+ | InputBehaviorEvent_2
654
670
  })
655
671
  | ({
656
672
  type: 'deserialization.success'
657
673
  data: Array<PortableTextBlock>
658
674
  mimeType: `${string}/${string}`
659
675
  } & {
660
- originEvent: PickFromUnion_2<
661
- NativeBehaviorEvent,
662
- 'type',
663
- 'drag.drop' | 'clipboard.paste'
664
- >
676
+ originEvent:
677
+ | PickFromUnion_2<
678
+ NativeBehaviorEvent,
679
+ 'type',
680
+ 'drag.drop' | 'clipboard.paste'
681
+ >
682
+ | InputBehaviorEvent_2
665
683
  })
666
684
  | {
667
685
  type: 'serialization.success'
@@ -806,7 +824,7 @@ declare const editorMachine: StateMachine<
806
824
  }
807
825
  | {
808
826
  type: 'dragstart'
809
- origin: EventPosition
827
+ origin: Pick<EventPosition, 'selection'>
810
828
  ghost?: HTMLElement
811
829
  }
812
830
  | {
@@ -876,7 +894,7 @@ declare const editorMachine: StateMachine<
876
894
  {
877
895
  'edit mode':
878
896
  | {
879
- editable: 'idle' | 'dragging internally'
897
+ editable: 'dragging internally' | 'idle'
880
898
  }
881
899
  | {
882
900
  'read only': 'read only' | 'determine initial edit mode'
@@ -885,7 +903,7 @@ declare const editorMachine: StateMachine<
885
903
  | 'setting up'
886
904
  | 'dirty'
887
905
  | {
888
- pristine: 'idle' | 'normalizing'
906
+ pristine: 'normalizing' | 'idle'
889
907
  }
890
908
  },
891
909
  'dragging internally',
@@ -957,6 +975,10 @@ declare const editorMachine: StateMachine<
957
975
  | {
958
976
  type: 'decorator.toggle'
959
977
  decorator: string
978
+ offsets?: {
979
+ anchor: BlockOffset_2
980
+ focus: BlockOffset_2
981
+ }
960
982
  }
961
983
  | {
962
984
  type: 'delete'
@@ -1101,22 +1123,26 @@ declare const editorMachine: StateMachine<
1101
1123
  mimeType: `${string}/${string}`
1102
1124
  reason: string
1103
1125
  } & {
1104
- originEvent: PickFromUnion_2<
1105
- NativeBehaviorEvent,
1106
- 'type',
1107
- 'drag.drop' | 'clipboard.paste'
1108
- >
1126
+ originEvent:
1127
+ | PickFromUnion_2<
1128
+ NativeBehaviorEvent,
1129
+ 'type',
1130
+ 'drag.drop' | 'clipboard.paste'
1131
+ >
1132
+ | InputBehaviorEvent_2
1109
1133
  })
1110
1134
  | ({
1111
1135
  type: 'deserialization.success'
1112
1136
  data: Array<PortableTextBlock>
1113
1137
  mimeType: `${string}/${string}`
1114
1138
  } & {
1115
- originEvent: PickFromUnion_2<
1116
- NativeBehaviorEvent,
1117
- 'type',
1118
- 'drag.drop' | 'clipboard.paste'
1119
- >
1139
+ originEvent:
1140
+ | PickFromUnion_2<
1141
+ NativeBehaviorEvent,
1142
+ 'type',
1143
+ 'drag.drop' | 'clipboard.paste'
1144
+ >
1145
+ | InputBehaviorEvent_2
1120
1146
  })
1121
1147
  | {
1122
1148
  type: 'serialization.success'
@@ -1240,7 +1266,7 @@ declare const editorMachine: StateMachine<
1240
1266
  value: Array<PortableTextBlock> | undefined
1241
1267
  internalDrag?: {
1242
1268
  ghost?: HTMLElement
1243
- origin: EventPosition
1269
+ origin: Pick<EventPosition, 'selection'>
1244
1270
  }
1245
1271
  },
1246
1272
  | {
@@ -1301,6 +1327,10 @@ declare const editorMachine: StateMachine<
1301
1327
  | {
1302
1328
  type: 'decorator.toggle'
1303
1329
  decorator: string
1330
+ offsets?: {
1331
+ anchor: BlockOffset_2
1332
+ focus: BlockOffset_2
1333
+ }
1304
1334
  }
1305
1335
  | {
1306
1336
  type: 'delete'
@@ -1445,22 +1475,26 @@ declare const editorMachine: StateMachine<
1445
1475
  mimeType: `${string}/${string}`
1446
1476
  reason: string
1447
1477
  } & {
1448
- originEvent: PickFromUnion_2<
1449
- NativeBehaviorEvent,
1450
- 'type',
1451
- 'drag.drop' | 'clipboard.paste'
1452
- >
1478
+ originEvent:
1479
+ | PickFromUnion_2<
1480
+ NativeBehaviorEvent,
1481
+ 'type',
1482
+ 'drag.drop' | 'clipboard.paste'
1483
+ >
1484
+ | InputBehaviorEvent_2
1453
1485
  })
1454
1486
  | ({
1455
1487
  type: 'deserialization.success'
1456
1488
  data: Array<PortableTextBlock>
1457
1489
  mimeType: `${string}/${string}`
1458
1490
  } & {
1459
- originEvent: PickFromUnion_2<
1460
- NativeBehaviorEvent,
1461
- 'type',
1462
- 'drag.drop' | 'clipboard.paste'
1463
- >
1491
+ originEvent:
1492
+ | PickFromUnion_2<
1493
+ NativeBehaviorEvent,
1494
+ 'type',
1495
+ 'drag.drop' | 'clipboard.paste'
1496
+ >
1497
+ | InputBehaviorEvent_2
1464
1498
  })
1465
1499
  | {
1466
1500
  type: 'serialization.success'
@@ -1605,7 +1639,7 @@ declare const editorMachine: StateMachine<
1605
1639
  }
1606
1640
  | {
1607
1641
  type: 'dragstart'
1608
- origin: EventPosition
1642
+ origin: Pick<EventPosition, 'selection'>
1609
1643
  ghost?: HTMLElement
1610
1644
  }
1611
1645
  | {
@@ -1679,6 +1713,10 @@ declare const editorMachine: StateMachine<
1679
1713
  | {
1680
1714
  type: 'decorator.toggle'
1681
1715
  decorator: string
1716
+ offsets?: {
1717
+ anchor: BlockOffset_2
1718
+ focus: BlockOffset_2
1719
+ }
1682
1720
  }
1683
1721
  | {
1684
1722
  type: 'delete'
@@ -1823,22 +1861,26 @@ declare const editorMachine: StateMachine<
1823
1861
  mimeType: `${string}/${string}`
1824
1862
  reason: string
1825
1863
  } & {
1826
- originEvent: PickFromUnion_2<
1827
- NativeBehaviorEvent,
1828
- 'type',
1829
- 'drag.drop' | 'clipboard.paste'
1830
- >
1864
+ originEvent:
1865
+ | PickFromUnion_2<
1866
+ NativeBehaviorEvent,
1867
+ 'type',
1868
+ 'drag.drop' | 'clipboard.paste'
1869
+ >
1870
+ | InputBehaviorEvent_2
1831
1871
  })
1832
1872
  | ({
1833
1873
  type: 'deserialization.success'
1834
1874
  data: Array<PortableTextBlock>
1835
1875
  mimeType: `${string}/${string}`
1836
1876
  } & {
1837
- originEvent: PickFromUnion_2<
1838
- NativeBehaviorEvent,
1839
- 'type',
1840
- 'drag.drop' | 'clipboard.paste'
1841
- >
1877
+ originEvent:
1878
+ | PickFromUnion_2<
1879
+ NativeBehaviorEvent,
1880
+ 'type',
1881
+ 'drag.drop' | 'clipboard.paste'
1882
+ >
1883
+ | InputBehaviorEvent_2
1842
1884
  })
1843
1885
  | {
1844
1886
  type: 'serialization.success'
@@ -1983,7 +2025,7 @@ declare const editorMachine: StateMachine<
1983
2025
  }
1984
2026
  | {
1985
2027
  type: 'dragstart'
1986
- origin: EventPosition
2028
+ origin: Pick<EventPosition, 'selection'>
1987
2029
  ghost?: HTMLElement
1988
2030
  }
1989
2031
  | {
@@ -2020,7 +2062,7 @@ declare const editorMachine: StateMachine<
2020
2062
  value: Array<PortableTextBlock> | undefined
2021
2063
  internalDrag?: {
2022
2064
  ghost?: HTMLElement
2023
- origin: EventPosition
2065
+ origin: Pick<EventPosition, 'selection'>
2024
2066
  }
2025
2067
  },
2026
2068
  {
@@ -2085,6 +2127,10 @@ declare const editorMachine: StateMachine<
2085
2127
  | {
2086
2128
  type: 'decorator.toggle'
2087
2129
  decorator: string
2130
+ offsets?: {
2131
+ anchor: BlockOffset_2
2132
+ focus: BlockOffset_2
2133
+ }
2088
2134
  }
2089
2135
  | {
2090
2136
  type: 'delete'
@@ -2229,22 +2275,26 @@ declare const editorMachine: StateMachine<
2229
2275
  mimeType: `${string}/${string}`
2230
2276
  reason: string
2231
2277
  } & {
2232
- originEvent: PickFromUnion_2<
2233
- NativeBehaviorEvent,
2234
- 'type',
2235
- 'drag.drop' | 'clipboard.paste'
2236
- >
2278
+ originEvent:
2279
+ | PickFromUnion_2<
2280
+ NativeBehaviorEvent,
2281
+ 'type',
2282
+ 'drag.drop' | 'clipboard.paste'
2283
+ >
2284
+ | InputBehaviorEvent_2
2237
2285
  })
2238
2286
  | ({
2239
2287
  type: 'deserialization.success'
2240
2288
  data: Array<PortableTextBlock>
2241
2289
  mimeType: `${string}/${string}`
2242
2290
  } & {
2243
- originEvent: PickFromUnion_2<
2244
- NativeBehaviorEvent,
2245
- 'type',
2246
- 'drag.drop' | 'clipboard.paste'
2247
- >
2291
+ originEvent:
2292
+ | PickFromUnion_2<
2293
+ NativeBehaviorEvent,
2294
+ 'type',
2295
+ 'drag.drop' | 'clipboard.paste'
2296
+ >
2297
+ | InputBehaviorEvent_2
2248
2298
  })
2249
2299
  | {
2250
2300
  type: 'serialization.success'
@@ -2389,7 +2439,7 @@ declare const editorMachine: StateMachine<
2389
2439
  }
2390
2440
  | {
2391
2441
  type: 'dragstart'
2392
- origin: EventPosition
2442
+ origin: Pick<EventPosition, 'selection'>
2393
2443
  ghost?: HTMLElement
2394
2444
  }
2395
2445
  | {
@@ -2461,6 +2511,10 @@ declare const editorMachine: StateMachine<
2461
2511
  | {
2462
2512
  type: 'decorator.toggle'
2463
2513
  decorator: string
2514
+ offsets?: {
2515
+ anchor: BlockOffset_2
2516
+ focus: BlockOffset_2
2517
+ }
2464
2518
  }
2465
2519
  | {
2466
2520
  type: 'delete'
@@ -2605,22 +2659,26 @@ declare const editorMachine: StateMachine<
2605
2659
  mimeType: `${string}/${string}`
2606
2660
  reason: string
2607
2661
  } & {
2608
- originEvent: PickFromUnion_2<
2609
- NativeBehaviorEvent,
2610
- 'type',
2611
- 'drag.drop' | 'clipboard.paste'
2612
- >
2662
+ originEvent:
2663
+ | PickFromUnion_2<
2664
+ NativeBehaviorEvent,
2665
+ 'type',
2666
+ 'drag.drop' | 'clipboard.paste'
2667
+ >
2668
+ | InputBehaviorEvent_2
2613
2669
  })
2614
2670
  | ({
2615
2671
  type: 'deserialization.success'
2616
2672
  data: Array<PortableTextBlock>
2617
2673
  mimeType: `${string}/${string}`
2618
2674
  } & {
2619
- originEvent: PickFromUnion_2<
2620
- NativeBehaviorEvent,
2621
- 'type',
2622
- 'drag.drop' | 'clipboard.paste'
2623
- >
2675
+ originEvent:
2676
+ | PickFromUnion_2<
2677
+ NativeBehaviorEvent,
2678
+ 'type',
2679
+ 'drag.drop' | 'clipboard.paste'
2680
+ >
2681
+ | InputBehaviorEvent_2
2624
2682
  })
2625
2683
  | {
2626
2684
  type: 'serialization.success'
@@ -2709,7 +2767,7 @@ declare const editorMachine: StateMachine<
2709
2767
  value: Array<PortableTextBlock> | undefined
2710
2768
  internalDrag?: {
2711
2769
  ghost?: HTMLElement
2712
- origin: EventPosition
2770
+ origin: Pick<EventPosition, 'selection'>
2713
2771
  }
2714
2772
  },
2715
2773
  {
@@ -2773,6 +2831,10 @@ declare const editorMachine: StateMachine<
2773
2831
  | {
2774
2832
  type: 'decorator.toggle'
2775
2833
  decorator: string
2834
+ offsets?: {
2835
+ anchor: BlockOffset_2
2836
+ focus: BlockOffset_2
2837
+ }
2776
2838
  }
2777
2839
  | {
2778
2840
  type: 'delete'
@@ -2917,22 +2979,26 @@ declare const editorMachine: StateMachine<
2917
2979
  mimeType: `${string}/${string}`
2918
2980
  reason: string
2919
2981
  } & {
2920
- originEvent: PickFromUnion_2<
2921
- NativeBehaviorEvent,
2922
- 'type',
2923
- 'drag.drop' | 'clipboard.paste'
2924
- >
2982
+ originEvent:
2983
+ | PickFromUnion_2<
2984
+ NativeBehaviorEvent,
2985
+ 'type',
2986
+ 'drag.drop' | 'clipboard.paste'
2987
+ >
2988
+ | InputBehaviorEvent_2
2925
2989
  })
2926
2990
  | ({
2927
2991
  type: 'deserialization.success'
2928
2992
  data: Array<PortableTextBlock>
2929
2993
  mimeType: `${string}/${string}`
2930
2994
  } & {
2931
- originEvent: PickFromUnion_2<
2932
- NativeBehaviorEvent,
2933
- 'type',
2934
- 'drag.drop' | 'clipboard.paste'
2935
- >
2995
+ originEvent:
2996
+ | PickFromUnion_2<
2997
+ NativeBehaviorEvent,
2998
+ 'type',
2999
+ 'drag.drop' | 'clipboard.paste'
3000
+ >
3001
+ | InputBehaviorEvent_2
2936
3002
  })
2937
3003
  | {
2938
3004
  type: 'serialization.success'
@@ -3077,7 +3143,7 @@ declare const editorMachine: StateMachine<
3077
3143
  }
3078
3144
  | {
3079
3145
  type: 'dragstart'
3080
- origin: EventPosition
3146
+ origin: Pick<EventPosition, 'selection'>
3081
3147
  ghost?: HTMLElement
3082
3148
  }
3083
3149
  | {
@@ -3149,6 +3215,10 @@ declare const editorMachine: StateMachine<
3149
3215
  | {
3150
3216
  type: 'decorator.toggle'
3151
3217
  decorator: string
3218
+ offsets?: {
3219
+ anchor: BlockOffset_2
3220
+ focus: BlockOffset_2
3221
+ }
3152
3222
  }
3153
3223
  | {
3154
3224
  type: 'delete'
@@ -3293,22 +3363,26 @@ declare const editorMachine: StateMachine<
3293
3363
  mimeType: `${string}/${string}`
3294
3364
  reason: string
3295
3365
  } & {
3296
- originEvent: PickFromUnion_2<
3297
- NativeBehaviorEvent,
3298
- 'type',
3299
- 'drag.drop' | 'clipboard.paste'
3300
- >
3366
+ originEvent:
3367
+ | PickFromUnion_2<
3368
+ NativeBehaviorEvent,
3369
+ 'type',
3370
+ 'drag.drop' | 'clipboard.paste'
3371
+ >
3372
+ | InputBehaviorEvent_2
3301
3373
  })
3302
3374
  | ({
3303
3375
  type: 'deserialization.success'
3304
3376
  data: Array<PortableTextBlock>
3305
3377
  mimeType: `${string}/${string}`
3306
3378
  } & {
3307
- originEvent: PickFromUnion_2<
3308
- NativeBehaviorEvent,
3309
- 'type',
3310
- 'drag.drop' | 'clipboard.paste'
3311
- >
3379
+ originEvent:
3380
+ | PickFromUnion_2<
3381
+ NativeBehaviorEvent,
3382
+ 'type',
3383
+ 'drag.drop' | 'clipboard.paste'
3384
+ >
3385
+ | InputBehaviorEvent_2
3312
3386
  })
3313
3387
  | {
3314
3388
  type: 'serialization.success'
@@ -3397,7 +3471,7 @@ declare const editorMachine: StateMachine<
3397
3471
  value: Array<PortableTextBlock> | undefined
3398
3472
  internalDrag?: {
3399
3473
  ghost?: HTMLElement
3400
- origin: EventPosition
3474
+ origin: Pick<EventPosition, 'selection'>
3401
3475
  }
3402
3476
  },
3403
3477
  {
@@ -3464,6 +3538,10 @@ declare const editorMachine: StateMachine<
3464
3538
  | {
3465
3539
  type: 'decorator.toggle'
3466
3540
  decorator: string
3541
+ offsets?: {
3542
+ anchor: BlockOffset_2
3543
+ focus: BlockOffset_2
3544
+ }
3467
3545
  }
3468
3546
  | {
3469
3547
  type: 'delete'
@@ -3608,22 +3686,26 @@ declare const editorMachine: StateMachine<
3608
3686
  mimeType: `${string}/${string}`
3609
3687
  reason: string
3610
3688
  } & {
3611
- originEvent: PickFromUnion_2<
3612
- NativeBehaviorEvent,
3613
- 'type',
3614
- 'drag.drop' | 'clipboard.paste'
3615
- >
3689
+ originEvent:
3690
+ | PickFromUnion_2<
3691
+ NativeBehaviorEvent,
3692
+ 'type',
3693
+ 'drag.drop' | 'clipboard.paste'
3694
+ >
3695
+ | InputBehaviorEvent_2
3616
3696
  })
3617
3697
  | ({
3618
3698
  type: 'deserialization.success'
3619
3699
  data: Array<PortableTextBlock>
3620
3700
  mimeType: `${string}/${string}`
3621
3701
  } & {
3622
- originEvent: PickFromUnion_2<
3623
- NativeBehaviorEvent,
3624
- 'type',
3625
- 'drag.drop' | 'clipboard.paste'
3626
- >
3702
+ originEvent:
3703
+ | PickFromUnion_2<
3704
+ NativeBehaviorEvent,
3705
+ 'type',
3706
+ 'drag.drop' | 'clipboard.paste'
3707
+ >
3708
+ | InputBehaviorEvent_2
3627
3709
  })
3628
3710
  | {
3629
3711
  type: 'serialization.success'
@@ -3768,7 +3850,7 @@ declare const editorMachine: StateMachine<
3768
3850
  }
3769
3851
  | {
3770
3852
  type: 'dragstart'
3771
- origin: EventPosition
3853
+ origin: Pick<EventPosition, 'selection'>
3772
3854
  ghost?: HTMLElement
3773
3855
  }
3774
3856
  | {
@@ -3840,6 +3922,10 @@ declare const editorMachine: StateMachine<
3840
3922
  | {
3841
3923
  type: 'decorator.toggle'
3842
3924
  decorator: string
3925
+ offsets?: {
3926
+ anchor: BlockOffset_2
3927
+ focus: BlockOffset_2
3928
+ }
3843
3929
  }
3844
3930
  | {
3845
3931
  type: 'delete'
@@ -3984,22 +4070,26 @@ declare const editorMachine: StateMachine<
3984
4070
  mimeType: `${string}/${string}`
3985
4071
  reason: string
3986
4072
  } & {
3987
- originEvent: PickFromUnion_2<
3988
- NativeBehaviorEvent,
3989
- 'type',
3990
- 'drag.drop' | 'clipboard.paste'
3991
- >
4073
+ originEvent:
4074
+ | PickFromUnion_2<
4075
+ NativeBehaviorEvent,
4076
+ 'type',
4077
+ 'drag.drop' | 'clipboard.paste'
4078
+ >
4079
+ | InputBehaviorEvent_2
3992
4080
  })
3993
4081
  | ({
3994
4082
  type: 'deserialization.success'
3995
4083
  data: Array<PortableTextBlock>
3996
4084
  mimeType: `${string}/${string}`
3997
4085
  } & {
3998
- originEvent: PickFromUnion_2<
3999
- NativeBehaviorEvent,
4000
- 'type',
4001
- 'drag.drop' | 'clipboard.paste'
4002
- >
4086
+ originEvent:
4087
+ | PickFromUnion_2<
4088
+ NativeBehaviorEvent,
4089
+ 'type',
4090
+ 'drag.drop' | 'clipboard.paste'
4091
+ >
4092
+ | InputBehaviorEvent_2
4003
4093
  })
4004
4094
  | {
4005
4095
  type: 'serialization.success'
@@ -4088,7 +4178,7 @@ declare const editorMachine: StateMachine<
4088
4178
  value: Array<PortableTextBlock> | undefined
4089
4179
  internalDrag?: {
4090
4180
  ghost?: HTMLElement
4091
- origin: EventPosition
4181
+ origin: Pick<EventPosition, 'selection'>
4092
4182
  }
4093
4183
  },
4094
4184
  {
@@ -4154,6 +4244,10 @@ declare const editorMachine: StateMachine<
4154
4244
  | {
4155
4245
  type: 'decorator.toggle'
4156
4246
  decorator: string
4247
+ offsets?: {
4248
+ anchor: BlockOffset_2
4249
+ focus: BlockOffset_2
4250
+ }
4157
4251
  }
4158
4252
  | {
4159
4253
  type: 'delete'
@@ -4298,22 +4392,26 @@ declare const editorMachine: StateMachine<
4298
4392
  mimeType: `${string}/${string}`
4299
4393
  reason: string
4300
4394
  } & {
4301
- originEvent: PickFromUnion_2<
4302
- NativeBehaviorEvent,
4303
- 'type',
4304
- 'drag.drop' | 'clipboard.paste'
4305
- >
4395
+ originEvent:
4396
+ | PickFromUnion_2<
4397
+ NativeBehaviorEvent,
4398
+ 'type',
4399
+ 'drag.drop' | 'clipboard.paste'
4400
+ >
4401
+ | InputBehaviorEvent_2
4306
4402
  })
4307
4403
  | ({
4308
4404
  type: 'deserialization.success'
4309
4405
  data: Array<PortableTextBlock>
4310
4406
  mimeType: `${string}/${string}`
4311
4407
  } & {
4312
- originEvent: PickFromUnion_2<
4313
- NativeBehaviorEvent,
4314
- 'type',
4315
- 'drag.drop' | 'clipboard.paste'
4316
- >
4408
+ originEvent:
4409
+ | PickFromUnion_2<
4410
+ NativeBehaviorEvent,
4411
+ 'type',
4412
+ 'drag.drop' | 'clipboard.paste'
4413
+ >
4414
+ | InputBehaviorEvent_2
4317
4415
  })
4318
4416
  | {
4319
4417
  type: 'serialization.success'
@@ -4458,7 +4556,7 @@ declare const editorMachine: StateMachine<
4458
4556
  }
4459
4557
  | {
4460
4558
  type: 'dragstart'
4461
- origin: EventPosition
4559
+ origin: Pick<EventPosition, 'selection'>
4462
4560
  ghost?: HTMLElement
4463
4561
  }
4464
4562
  | {
@@ -4530,6 +4628,10 @@ declare const editorMachine: StateMachine<
4530
4628
  | {
4531
4629
  type: 'decorator.toggle'
4532
4630
  decorator: string
4631
+ offsets?: {
4632
+ anchor: BlockOffset_2
4633
+ focus: BlockOffset_2
4634
+ }
4533
4635
  }
4534
4636
  | {
4535
4637
  type: 'delete'
@@ -4674,22 +4776,26 @@ declare const editorMachine: StateMachine<
4674
4776
  mimeType: `${string}/${string}`
4675
4777
  reason: string
4676
4778
  } & {
4677
- originEvent: PickFromUnion_2<
4678
- NativeBehaviorEvent,
4679
- 'type',
4680
- 'drag.drop' | 'clipboard.paste'
4681
- >
4779
+ originEvent:
4780
+ | PickFromUnion_2<
4781
+ NativeBehaviorEvent,
4782
+ 'type',
4783
+ 'drag.drop' | 'clipboard.paste'
4784
+ >
4785
+ | InputBehaviorEvent_2
4682
4786
  })
4683
4787
  | ({
4684
4788
  type: 'deserialization.success'
4685
4789
  data: Array<PortableTextBlock>
4686
4790
  mimeType: `${string}/${string}`
4687
4791
  } & {
4688
- originEvent: PickFromUnion_2<
4689
- NativeBehaviorEvent,
4690
- 'type',
4691
- 'drag.drop' | 'clipboard.paste'
4692
- >
4792
+ originEvent:
4793
+ | PickFromUnion_2<
4794
+ NativeBehaviorEvent,
4795
+ 'type',
4796
+ 'drag.drop' | 'clipboard.paste'
4797
+ >
4798
+ | InputBehaviorEvent_2
4693
4799
  })
4694
4800
  | {
4695
4801
  type: 'serialization.success'
@@ -4778,7 +4884,7 @@ declare const editorMachine: StateMachine<
4778
4884
  value: Array<PortableTextBlock> | undefined
4779
4885
  internalDrag?: {
4780
4886
  ghost?: HTMLElement
4781
- origin: EventPosition
4887
+ origin: Pick<EventPosition, 'selection'>
4782
4888
  }
4783
4889
  },
4784
4890
  {
@@ -4843,6 +4949,10 @@ declare const editorMachine: StateMachine<
4843
4949
  | {
4844
4950
  type: 'decorator.toggle'
4845
4951
  decorator: string
4952
+ offsets?: {
4953
+ anchor: BlockOffset_2
4954
+ focus: BlockOffset_2
4955
+ }
4846
4956
  }
4847
4957
  | {
4848
4958
  type: 'delete'
@@ -4987,22 +5097,26 @@ declare const editorMachine: StateMachine<
4987
5097
  mimeType: `${string}/${string}`
4988
5098
  reason: string
4989
5099
  } & {
4990
- originEvent: PickFromUnion_2<
4991
- NativeBehaviorEvent,
4992
- 'type',
4993
- 'drag.drop' | 'clipboard.paste'
4994
- >
5100
+ originEvent:
5101
+ | PickFromUnion_2<
5102
+ NativeBehaviorEvent,
5103
+ 'type',
5104
+ 'drag.drop' | 'clipboard.paste'
5105
+ >
5106
+ | InputBehaviorEvent_2
4995
5107
  })
4996
5108
  | ({
4997
5109
  type: 'deserialization.success'
4998
5110
  data: Array<PortableTextBlock>
4999
5111
  mimeType: `${string}/${string}`
5000
5112
  } & {
5001
- originEvent: PickFromUnion_2<
5002
- NativeBehaviorEvent,
5003
- 'type',
5004
- 'drag.drop' | 'clipboard.paste'
5005
- >
5113
+ originEvent:
5114
+ | PickFromUnion_2<
5115
+ NativeBehaviorEvent,
5116
+ 'type',
5117
+ 'drag.drop' | 'clipboard.paste'
5118
+ >
5119
+ | InputBehaviorEvent_2
5006
5120
  })
5007
5121
  | {
5008
5122
  type: 'serialization.success'
@@ -5147,7 +5261,7 @@ declare const editorMachine: StateMachine<
5147
5261
  }
5148
5262
  | {
5149
5263
  type: 'dragstart'
5150
- origin: EventPosition
5264
+ origin: Pick<EventPosition, 'selection'>
5151
5265
  ghost?: HTMLElement
5152
5266
  }
5153
5267
  | {
@@ -5219,6 +5333,10 @@ declare const editorMachine: StateMachine<
5219
5333
  | {
5220
5334
  type: 'decorator.toggle'
5221
5335
  decorator: string
5336
+ offsets?: {
5337
+ anchor: BlockOffset_2
5338
+ focus: BlockOffset_2
5339
+ }
5222
5340
  }
5223
5341
  | {
5224
5342
  type: 'delete'
@@ -5363,22 +5481,26 @@ declare const editorMachine: StateMachine<
5363
5481
  mimeType: `${string}/${string}`
5364
5482
  reason: string
5365
5483
  } & {
5366
- originEvent: PickFromUnion_2<
5367
- NativeBehaviorEvent,
5368
- 'type',
5369
- 'drag.drop' | 'clipboard.paste'
5370
- >
5484
+ originEvent:
5485
+ | PickFromUnion_2<
5486
+ NativeBehaviorEvent,
5487
+ 'type',
5488
+ 'drag.drop' | 'clipboard.paste'
5489
+ >
5490
+ | InputBehaviorEvent_2
5371
5491
  })
5372
5492
  | ({
5373
5493
  type: 'deserialization.success'
5374
5494
  data: Array<PortableTextBlock>
5375
5495
  mimeType: `${string}/${string}`
5376
5496
  } & {
5377
- originEvent: PickFromUnion_2<
5378
- NativeBehaviorEvent,
5379
- 'type',
5380
- 'drag.drop' | 'clipboard.paste'
5381
- >
5497
+ originEvent:
5498
+ | PickFromUnion_2<
5499
+ NativeBehaviorEvent,
5500
+ 'type',
5501
+ 'drag.drop' | 'clipboard.paste'
5502
+ >
5503
+ | InputBehaviorEvent_2
5382
5504
  })
5383
5505
  | {
5384
5506
  type: 'serialization.success'
@@ -5468,7 +5590,7 @@ declare const editorMachine: StateMachine<
5468
5590
  value: Array<PortableTextBlock> | undefined
5469
5591
  internalDrag?: {
5470
5592
  ghost?: HTMLElement
5471
- origin: EventPosition
5593
+ origin: Pick<EventPosition, 'selection'>
5472
5594
  }
5473
5595
  },
5474
5596
  {
@@ -5533,6 +5655,10 @@ declare const editorMachine: StateMachine<
5533
5655
  | {
5534
5656
  type: 'decorator.toggle'
5535
5657
  decorator: string
5658
+ offsets?: {
5659
+ anchor: BlockOffset_2
5660
+ focus: BlockOffset_2
5661
+ }
5536
5662
  }
5537
5663
  | {
5538
5664
  type: 'delete'
@@ -5677,22 +5803,26 @@ declare const editorMachine: StateMachine<
5677
5803
  mimeType: `${string}/${string}`
5678
5804
  reason: string
5679
5805
  } & {
5680
- originEvent: PickFromUnion_2<
5681
- NativeBehaviorEvent,
5682
- 'type',
5683
- 'drag.drop' | 'clipboard.paste'
5684
- >
5806
+ originEvent:
5807
+ | PickFromUnion_2<
5808
+ NativeBehaviorEvent,
5809
+ 'type',
5810
+ 'drag.drop' | 'clipboard.paste'
5811
+ >
5812
+ | InputBehaviorEvent_2
5685
5813
  })
5686
5814
  | ({
5687
5815
  type: 'deserialization.success'
5688
5816
  data: Array<PortableTextBlock>
5689
5817
  mimeType: `${string}/${string}`
5690
5818
  } & {
5691
- originEvent: PickFromUnion_2<
5692
- NativeBehaviorEvent,
5693
- 'type',
5694
- 'drag.drop' | 'clipboard.paste'
5695
- >
5819
+ originEvent:
5820
+ | PickFromUnion_2<
5821
+ NativeBehaviorEvent,
5822
+ 'type',
5823
+ 'drag.drop' | 'clipboard.paste'
5824
+ >
5825
+ | InputBehaviorEvent_2
5696
5826
  })
5697
5827
  | {
5698
5828
  type: 'serialization.success'
@@ -5837,7 +5967,7 @@ declare const editorMachine: StateMachine<
5837
5967
  }
5838
5968
  | {
5839
5969
  type: 'dragstart'
5840
- origin: EventPosition
5970
+ origin: Pick<EventPosition, 'selection'>
5841
5971
  ghost?: HTMLElement
5842
5972
  }
5843
5973
  | {
@@ -5866,7 +5996,7 @@ declare const editorMachine: StateMachine<
5866
5996
  value: Array<PortableTextBlock> | undefined
5867
5997
  internalDrag?: {
5868
5998
  ghost?: HTMLElement
5869
- origin: EventPosition
5999
+ origin: Pick<EventPosition, 'selection'>
5870
6000
  }
5871
6001
  },
5872
6002
  {
@@ -5931,6 +6061,10 @@ declare const editorMachine: StateMachine<
5931
6061
  | {
5932
6062
  type: 'decorator.toggle'
5933
6063
  decorator: string
6064
+ offsets?: {
6065
+ anchor: BlockOffset_2
6066
+ focus: BlockOffset_2
6067
+ }
5934
6068
  }
5935
6069
  | {
5936
6070
  type: 'delete'
@@ -6075,22 +6209,26 @@ declare const editorMachine: StateMachine<
6075
6209
  mimeType: `${string}/${string}`
6076
6210
  reason: string
6077
6211
  } & {
6078
- originEvent: PickFromUnion_2<
6079
- NativeBehaviorEvent,
6080
- 'type',
6081
- 'drag.drop' | 'clipboard.paste'
6082
- >
6212
+ originEvent:
6213
+ | PickFromUnion_2<
6214
+ NativeBehaviorEvent,
6215
+ 'type',
6216
+ 'drag.drop' | 'clipboard.paste'
6217
+ >
6218
+ | InputBehaviorEvent_2
6083
6219
  })
6084
6220
  | ({
6085
6221
  type: 'deserialization.success'
6086
6222
  data: Array<PortableTextBlock>
6087
6223
  mimeType: `${string}/${string}`
6088
6224
  } & {
6089
- originEvent: PickFromUnion_2<
6090
- NativeBehaviorEvent,
6091
- 'type',
6092
- 'drag.drop' | 'clipboard.paste'
6093
- >
6225
+ originEvent:
6226
+ | PickFromUnion_2<
6227
+ NativeBehaviorEvent,
6228
+ 'type',
6229
+ 'drag.drop' | 'clipboard.paste'
6230
+ >
6231
+ | InputBehaviorEvent_2
6094
6232
  })
6095
6233
  | {
6096
6234
  type: 'serialization.success'
@@ -6235,7 +6373,7 @@ declare const editorMachine: StateMachine<
6235
6373
  }
6236
6374
  | {
6237
6375
  type: 'dragstart'
6238
- origin: EventPosition
6376
+ origin: Pick<EventPosition, 'selection'>
6239
6377
  ghost?: HTMLElement
6240
6378
  }
6241
6379
  | {
@@ -6307,6 +6445,10 @@ declare const editorMachine: StateMachine<
6307
6445
  | {
6308
6446
  type: 'decorator.toggle'
6309
6447
  decorator: string
6448
+ offsets?: {
6449
+ anchor: BlockOffset_2
6450
+ focus: BlockOffset_2
6451
+ }
6310
6452
  }
6311
6453
  | {
6312
6454
  type: 'delete'
@@ -6451,22 +6593,26 @@ declare const editorMachine: StateMachine<
6451
6593
  mimeType: `${string}/${string}`
6452
6594
  reason: string
6453
6595
  } & {
6454
- originEvent: PickFromUnion_2<
6455
- NativeBehaviorEvent,
6456
- 'type',
6457
- 'drag.drop' | 'clipboard.paste'
6458
- >
6596
+ originEvent:
6597
+ | PickFromUnion_2<
6598
+ NativeBehaviorEvent,
6599
+ 'type',
6600
+ 'drag.drop' | 'clipboard.paste'
6601
+ >
6602
+ | InputBehaviorEvent_2
6459
6603
  })
6460
6604
  | ({
6461
6605
  type: 'deserialization.success'
6462
6606
  data: Array<PortableTextBlock>
6463
6607
  mimeType: `${string}/${string}`
6464
6608
  } & {
6465
- originEvent: PickFromUnion_2<
6466
- NativeBehaviorEvent,
6467
- 'type',
6468
- 'drag.drop' | 'clipboard.paste'
6469
- >
6609
+ originEvent:
6610
+ | PickFromUnion_2<
6611
+ NativeBehaviorEvent,
6612
+ 'type',
6613
+ 'drag.drop' | 'clipboard.paste'
6614
+ >
6615
+ | InputBehaviorEvent_2
6470
6616
  })
6471
6617
  | {
6472
6618
  type: 'serialization.success'
@@ -6556,7 +6702,7 @@ declare const editorMachine: StateMachine<
6556
6702
  value: Array<PortableTextBlock> | undefined
6557
6703
  internalDrag?: {
6558
6704
  ghost?: HTMLElement
6559
- origin: EventPosition
6705
+ origin: Pick<EventPosition, 'selection'>
6560
6706
  }
6561
6707
  },
6562
6708
  {
@@ -6621,6 +6767,10 @@ declare const editorMachine: StateMachine<
6621
6767
  | {
6622
6768
  type: 'decorator.toggle'
6623
6769
  decorator: string
6770
+ offsets?: {
6771
+ anchor: BlockOffset_2
6772
+ focus: BlockOffset_2
6773
+ }
6624
6774
  }
6625
6775
  | {
6626
6776
  type: 'delete'
@@ -6765,22 +6915,26 @@ declare const editorMachine: StateMachine<
6765
6915
  mimeType: `${string}/${string}`
6766
6916
  reason: string
6767
6917
  } & {
6768
- originEvent: PickFromUnion_2<
6769
- NativeBehaviorEvent,
6770
- 'type',
6771
- 'drag.drop' | 'clipboard.paste'
6772
- >
6918
+ originEvent:
6919
+ | PickFromUnion_2<
6920
+ NativeBehaviorEvent,
6921
+ 'type',
6922
+ 'drag.drop' | 'clipboard.paste'
6923
+ >
6924
+ | InputBehaviorEvent_2
6773
6925
  })
6774
6926
  | ({
6775
6927
  type: 'deserialization.success'
6776
6928
  data: Array<PortableTextBlock>
6777
6929
  mimeType: `${string}/${string}`
6778
6930
  } & {
6779
- originEvent: PickFromUnion_2<
6780
- NativeBehaviorEvent,
6781
- 'type',
6782
- 'drag.drop' | 'clipboard.paste'
6783
- >
6931
+ originEvent:
6932
+ | PickFromUnion_2<
6933
+ NativeBehaviorEvent,
6934
+ 'type',
6935
+ 'drag.drop' | 'clipboard.paste'
6936
+ >
6937
+ | InputBehaviorEvent_2
6784
6938
  })
6785
6939
  | {
6786
6940
  type: 'serialization.success'
@@ -6925,7 +7079,7 @@ declare const editorMachine: StateMachine<
6925
7079
  }
6926
7080
  | {
6927
7081
  type: 'dragstart'
6928
- origin: EventPosition
7082
+ origin: Pick<EventPosition, 'selection'>
6929
7083
  ghost?: HTMLElement
6930
7084
  }
6931
7085
  | {
@@ -6997,6 +7151,10 @@ declare const editorMachine: StateMachine<
6997
7151
  | {
6998
7152
  type: 'decorator.toggle'
6999
7153
  decorator: string
7154
+ offsets?: {
7155
+ anchor: BlockOffset_2
7156
+ focus: BlockOffset_2
7157
+ }
7000
7158
  }
7001
7159
  | {
7002
7160
  type: 'delete'
@@ -7141,22 +7299,26 @@ declare const editorMachine: StateMachine<
7141
7299
  mimeType: `${string}/${string}`
7142
7300
  reason: string
7143
7301
  } & {
7144
- originEvent: PickFromUnion_2<
7145
- NativeBehaviorEvent,
7146
- 'type',
7147
- 'drag.drop' | 'clipboard.paste'
7148
- >
7302
+ originEvent:
7303
+ | PickFromUnion_2<
7304
+ NativeBehaviorEvent,
7305
+ 'type',
7306
+ 'drag.drop' | 'clipboard.paste'
7307
+ >
7308
+ | InputBehaviorEvent_2
7149
7309
  })
7150
7310
  | ({
7151
7311
  type: 'deserialization.success'
7152
7312
  data: Array<PortableTextBlock>
7153
7313
  mimeType: `${string}/${string}`
7154
7314
  } & {
7155
- originEvent: PickFromUnion_2<
7156
- NativeBehaviorEvent,
7157
- 'type',
7158
- 'drag.drop' | 'clipboard.paste'
7159
- >
7315
+ originEvent:
7316
+ | PickFromUnion_2<
7317
+ NativeBehaviorEvent,
7318
+ 'type',
7319
+ 'drag.drop' | 'clipboard.paste'
7320
+ >
7321
+ | InputBehaviorEvent_2
7160
7322
  })
7161
7323
  | {
7162
7324
  type: 'serialization.success'
@@ -7245,7 +7407,7 @@ declare const editorMachine: StateMachine<
7245
7407
  value: Array<PortableTextBlock> | undefined
7246
7408
  internalDrag?: {
7247
7409
  ghost?: HTMLElement
7248
- origin: EventPosition
7410
+ origin: Pick<EventPosition, 'selection'>
7249
7411
  }
7250
7412
  },
7251
7413
  {
@@ -7309,6 +7471,10 @@ declare const editorMachine: StateMachine<
7309
7471
  | {
7310
7472
  type: 'decorator.toggle'
7311
7473
  decorator: string
7474
+ offsets?: {
7475
+ anchor: BlockOffset_2
7476
+ focus: BlockOffset_2
7477
+ }
7312
7478
  }
7313
7479
  | {
7314
7480
  type: 'delete'
@@ -7453,22 +7619,26 @@ declare const editorMachine: StateMachine<
7453
7619
  mimeType: `${string}/${string}`
7454
7620
  reason: string
7455
7621
  } & {
7456
- originEvent: PickFromUnion_2<
7457
- NativeBehaviorEvent,
7458
- 'type',
7459
- 'drag.drop' | 'clipboard.paste'
7460
- >
7622
+ originEvent:
7623
+ | PickFromUnion_2<
7624
+ NativeBehaviorEvent,
7625
+ 'type',
7626
+ 'drag.drop' | 'clipboard.paste'
7627
+ >
7628
+ | InputBehaviorEvent_2
7461
7629
  })
7462
7630
  | ({
7463
7631
  type: 'deserialization.success'
7464
7632
  data: Array<PortableTextBlock>
7465
7633
  mimeType: `${string}/${string}`
7466
7634
  } & {
7467
- originEvent: PickFromUnion_2<
7468
- NativeBehaviorEvent,
7469
- 'type',
7470
- 'drag.drop' | 'clipboard.paste'
7471
- >
7635
+ originEvent:
7636
+ | PickFromUnion_2<
7637
+ NativeBehaviorEvent,
7638
+ 'type',
7639
+ 'drag.drop' | 'clipboard.paste'
7640
+ >
7641
+ | InputBehaviorEvent_2
7472
7642
  })
7473
7643
  | {
7474
7644
  type: 'serialization.success'
@@ -7613,7 +7783,7 @@ declare const editorMachine: StateMachine<
7613
7783
  }
7614
7784
  | {
7615
7785
  type: 'dragstart'
7616
- origin: EventPosition
7786
+ origin: Pick<EventPosition, 'selection'>
7617
7787
  ghost?: HTMLElement
7618
7788
  }
7619
7789
  | {
@@ -7685,6 +7855,10 @@ declare const editorMachine: StateMachine<
7685
7855
  | {
7686
7856
  type: 'decorator.toggle'
7687
7857
  decorator: string
7858
+ offsets?: {
7859
+ anchor: BlockOffset_2
7860
+ focus: BlockOffset_2
7861
+ }
7688
7862
  }
7689
7863
  | {
7690
7864
  type: 'delete'
@@ -7829,22 +8003,26 @@ declare const editorMachine: StateMachine<
7829
8003
  mimeType: `${string}/${string}`
7830
8004
  reason: string
7831
8005
  } & {
7832
- originEvent: PickFromUnion_2<
7833
- NativeBehaviorEvent,
7834
- 'type',
7835
- 'drag.drop' | 'clipboard.paste'
7836
- >
8006
+ originEvent:
8007
+ | PickFromUnion_2<
8008
+ NativeBehaviorEvent,
8009
+ 'type',
8010
+ 'drag.drop' | 'clipboard.paste'
8011
+ >
8012
+ | InputBehaviorEvent_2
7837
8013
  })
7838
8014
  | ({
7839
8015
  type: 'deserialization.success'
7840
8016
  data: Array<PortableTextBlock>
7841
8017
  mimeType: `${string}/${string}`
7842
8018
  } & {
7843
- originEvent: PickFromUnion_2<
7844
- NativeBehaviorEvent,
7845
- 'type',
7846
- 'drag.drop' | 'clipboard.paste'
7847
- >
8019
+ originEvent:
8020
+ | PickFromUnion_2<
8021
+ NativeBehaviorEvent,
8022
+ 'type',
8023
+ 'drag.drop' | 'clipboard.paste'
8024
+ >
8025
+ | InputBehaviorEvent_2
7848
8026
  })
7849
8027
  | {
7850
8028
  type: 'serialization.success'
@@ -7933,7 +8111,7 @@ declare const editorMachine: StateMachine<
7933
8111
  value: Array<PortableTextBlock> | undefined
7934
8112
  internalDrag?: {
7935
8113
  ghost?: HTMLElement
7936
- origin: EventPosition
8114
+ origin: Pick<EventPosition, 'selection'>
7937
8115
  }
7938
8116
  },
7939
8117
  {
@@ -7998,6 +8176,10 @@ declare const editorMachine: StateMachine<
7998
8176
  | {
7999
8177
  type: 'decorator.toggle'
8000
8178
  decorator: string
8179
+ offsets?: {
8180
+ anchor: BlockOffset_2
8181
+ focus: BlockOffset_2
8182
+ }
8001
8183
  }
8002
8184
  | {
8003
8185
  type: 'delete'
@@ -8142,22 +8324,26 @@ declare const editorMachine: StateMachine<
8142
8324
  mimeType: `${string}/${string}`
8143
8325
  reason: string
8144
8326
  } & {
8145
- originEvent: PickFromUnion_2<
8146
- NativeBehaviorEvent,
8147
- 'type',
8148
- 'drag.drop' | 'clipboard.paste'
8149
- >
8327
+ originEvent:
8328
+ | PickFromUnion_2<
8329
+ NativeBehaviorEvent,
8330
+ 'type',
8331
+ 'drag.drop' | 'clipboard.paste'
8332
+ >
8333
+ | InputBehaviorEvent_2
8150
8334
  })
8151
8335
  | ({
8152
8336
  type: 'deserialization.success'
8153
8337
  data: Array<PortableTextBlock>
8154
8338
  mimeType: `${string}/${string}`
8155
8339
  } & {
8156
- originEvent: PickFromUnion_2<
8157
- NativeBehaviorEvent,
8158
- 'type',
8159
- 'drag.drop' | 'clipboard.paste'
8160
- >
8340
+ originEvent:
8341
+ | PickFromUnion_2<
8342
+ NativeBehaviorEvent,
8343
+ 'type',
8344
+ 'drag.drop' | 'clipboard.paste'
8345
+ >
8346
+ | InputBehaviorEvent_2
8161
8347
  })
8162
8348
  | {
8163
8349
  type: 'serialization.success'
@@ -8302,7 +8488,7 @@ declare const editorMachine: StateMachine<
8302
8488
  }
8303
8489
  | {
8304
8490
  type: 'dragstart'
8305
- origin: EventPosition
8491
+ origin: Pick<EventPosition, 'selection'>
8306
8492
  ghost?: HTMLElement
8307
8493
  }
8308
8494
  | {
@@ -8374,6 +8560,10 @@ declare const editorMachine: StateMachine<
8374
8560
  | {
8375
8561
  type: 'decorator.toggle'
8376
8562
  decorator: string
8563
+ offsets?: {
8564
+ anchor: BlockOffset_2
8565
+ focus: BlockOffset_2
8566
+ }
8377
8567
  }
8378
8568
  | {
8379
8569
  type: 'delete'
@@ -8518,22 +8708,26 @@ declare const editorMachine: StateMachine<
8518
8708
  mimeType: `${string}/${string}`
8519
8709
  reason: string
8520
8710
  } & {
8521
- originEvent: PickFromUnion_2<
8522
- NativeBehaviorEvent,
8523
- 'type',
8524
- 'drag.drop' | 'clipboard.paste'
8525
- >
8711
+ originEvent:
8712
+ | PickFromUnion_2<
8713
+ NativeBehaviorEvent,
8714
+ 'type',
8715
+ 'drag.drop' | 'clipboard.paste'
8716
+ >
8717
+ | InputBehaviorEvent_2
8526
8718
  })
8527
8719
  | ({
8528
8720
  type: 'deserialization.success'
8529
8721
  data: Array<PortableTextBlock>
8530
8722
  mimeType: `${string}/${string}`
8531
8723
  } & {
8532
- originEvent: PickFromUnion_2<
8533
- NativeBehaviorEvent,
8534
- 'type',
8535
- 'drag.drop' | 'clipboard.paste'
8536
- >
8724
+ originEvent:
8725
+ | PickFromUnion_2<
8726
+ NativeBehaviorEvent,
8727
+ 'type',
8728
+ 'drag.drop' | 'clipboard.paste'
8729
+ >
8730
+ | InputBehaviorEvent_2
8537
8731
  })
8538
8732
  | {
8539
8733
  type: 'serialization.success'
@@ -8628,7 +8822,7 @@ declare const editorMachine: StateMachine<
8628
8822
  value: Array<PortableTextBlock> | undefined
8629
8823
  internalDrag?: {
8630
8824
  ghost?: HTMLElement
8631
- origin: EventPosition
8825
+ origin: Pick<EventPosition, 'selection'>
8632
8826
  }
8633
8827
  },
8634
8828
  PatchesEvent,
@@ -8690,6 +8884,10 @@ declare const editorMachine: StateMachine<
8690
8884
  | {
8691
8885
  type: 'decorator.toggle'
8692
8886
  decorator: string
8887
+ offsets?: {
8888
+ anchor: BlockOffset_2
8889
+ focus: BlockOffset_2
8890
+ }
8693
8891
  }
8694
8892
  | {
8695
8893
  type: 'delete'
@@ -8834,22 +9032,26 @@ declare const editorMachine: StateMachine<
8834
9032
  mimeType: `${string}/${string}`
8835
9033
  reason: string
8836
9034
  } & {
8837
- originEvent: PickFromUnion_2<
8838
- NativeBehaviorEvent,
8839
- 'type',
8840
- 'drag.drop' | 'clipboard.paste'
8841
- >
9035
+ originEvent:
9036
+ | PickFromUnion_2<
9037
+ NativeBehaviorEvent,
9038
+ 'type',
9039
+ 'drag.drop' | 'clipboard.paste'
9040
+ >
9041
+ | InputBehaviorEvent_2
8842
9042
  })
8843
9043
  | ({
8844
9044
  type: 'deserialization.success'
8845
9045
  data: Array<PortableTextBlock>
8846
9046
  mimeType: `${string}/${string}`
8847
9047
  } & {
8848
- originEvent: PickFromUnion_2<
8849
- NativeBehaviorEvent,
8850
- 'type',
8851
- 'drag.drop' | 'clipboard.paste'
8852
- >
9048
+ originEvent:
9049
+ | PickFromUnion_2<
9050
+ NativeBehaviorEvent,
9051
+ 'type',
9052
+ 'drag.drop' | 'clipboard.paste'
9053
+ >
9054
+ | InputBehaviorEvent_2
8853
9055
  })
8854
9056
  | {
8855
9057
  type: 'serialization.success'
@@ -8994,7 +9196,7 @@ declare const editorMachine: StateMachine<
8994
9196
  }
8995
9197
  | {
8996
9198
  type: 'dragstart'
8997
- origin: EventPosition
9199
+ origin: Pick<EventPosition, 'selection'>
8998
9200
  ghost?: HTMLElement
8999
9201
  }
9000
9202
  | {
@@ -9066,6 +9268,10 @@ declare const editorMachine: StateMachine<
9066
9268
  | {
9067
9269
  type: 'decorator.toggle'
9068
9270
  decorator: string
9271
+ offsets?: {
9272
+ anchor: BlockOffset_2
9273
+ focus: BlockOffset_2
9274
+ }
9069
9275
  }
9070
9276
  | {
9071
9277
  type: 'delete'
@@ -9210,22 +9416,26 @@ declare const editorMachine: StateMachine<
9210
9416
  mimeType: `${string}/${string}`
9211
9417
  reason: string
9212
9418
  } & {
9213
- originEvent: PickFromUnion_2<
9214
- NativeBehaviorEvent,
9215
- 'type',
9216
- 'drag.drop' | 'clipboard.paste'
9217
- >
9419
+ originEvent:
9420
+ | PickFromUnion_2<
9421
+ NativeBehaviorEvent,
9422
+ 'type',
9423
+ 'drag.drop' | 'clipboard.paste'
9424
+ >
9425
+ | InputBehaviorEvent_2
9218
9426
  })
9219
9427
  | ({
9220
9428
  type: 'deserialization.success'
9221
9429
  data: Array<PortableTextBlock>
9222
9430
  mimeType: `${string}/${string}`
9223
9431
  } & {
9224
- originEvent: PickFromUnion_2<
9225
- NativeBehaviorEvent,
9226
- 'type',
9227
- 'drag.drop' | 'clipboard.paste'
9228
- >
9432
+ originEvent:
9433
+ | PickFromUnion_2<
9434
+ NativeBehaviorEvent,
9435
+ 'type',
9436
+ 'drag.drop' | 'clipboard.paste'
9437
+ >
9438
+ | InputBehaviorEvent_2
9229
9439
  })
9230
9440
  | {
9231
9441
  type: 'serialization.success'
@@ -9317,7 +9527,7 @@ declare const editorMachine: StateMachine<
9317
9527
  value: Array<PortableTextBlock> | undefined
9318
9528
  internalDrag?: {
9319
9529
  ghost?: HTMLElement
9320
- origin: EventPosition
9530
+ origin: Pick<EventPosition, 'selection'>
9321
9531
  }
9322
9532
  },
9323
9533
  {
@@ -9382,6 +9592,10 @@ declare const editorMachine: StateMachine<
9382
9592
  | {
9383
9593
  type: 'decorator.toggle'
9384
9594
  decorator: string
9595
+ offsets?: {
9596
+ anchor: BlockOffset_2
9597
+ focus: BlockOffset_2
9598
+ }
9385
9599
  }
9386
9600
  | {
9387
9601
  type: 'delete'
@@ -9526,22 +9740,26 @@ declare const editorMachine: StateMachine<
9526
9740
  mimeType: `${string}/${string}`
9527
9741
  reason: string
9528
9742
  } & {
9529
- originEvent: PickFromUnion_2<
9530
- NativeBehaviorEvent,
9531
- 'type',
9532
- 'drag.drop' | 'clipboard.paste'
9533
- >
9743
+ originEvent:
9744
+ | PickFromUnion_2<
9745
+ NativeBehaviorEvent,
9746
+ 'type',
9747
+ 'drag.drop' | 'clipboard.paste'
9748
+ >
9749
+ | InputBehaviorEvent_2
9534
9750
  })
9535
9751
  | ({
9536
9752
  type: 'deserialization.success'
9537
9753
  data: Array<PortableTextBlock>
9538
9754
  mimeType: `${string}/${string}`
9539
9755
  } & {
9540
- originEvent: PickFromUnion_2<
9541
- NativeBehaviorEvent,
9542
- 'type',
9543
- 'drag.drop' | 'clipboard.paste'
9544
- >
9756
+ originEvent:
9757
+ | PickFromUnion_2<
9758
+ NativeBehaviorEvent,
9759
+ 'type',
9760
+ 'drag.drop' | 'clipboard.paste'
9761
+ >
9762
+ | InputBehaviorEvent_2
9545
9763
  })
9546
9764
  | {
9547
9765
  type: 'serialization.success'
@@ -9686,7 +9904,7 @@ declare const editorMachine: StateMachine<
9686
9904
  }
9687
9905
  | {
9688
9906
  type: 'dragstart'
9689
- origin: EventPosition
9907
+ origin: Pick<EventPosition, 'selection'>
9690
9908
  ghost?: HTMLElement
9691
9909
  }
9692
9910
  | {
@@ -9720,7 +9938,7 @@ declare const editorMachine: StateMachine<
9720
9938
  value: Array<PortableTextBlock> | undefined
9721
9939
  internalDrag?: {
9722
9940
  ghost?: HTMLElement
9723
- origin: EventPosition
9941
+ origin: Pick<EventPosition, 'selection'>
9724
9942
  }
9725
9943
  },
9726
9944
  {
@@ -9785,6 +10003,10 @@ declare const editorMachine: StateMachine<
9785
10003
  | {
9786
10004
  type: 'decorator.toggle'
9787
10005
  decorator: string
10006
+ offsets?: {
10007
+ anchor: BlockOffset_2
10008
+ focus: BlockOffset_2
10009
+ }
9788
10010
  }
9789
10011
  | {
9790
10012
  type: 'delete'
@@ -9929,22 +10151,26 @@ declare const editorMachine: StateMachine<
9929
10151
  mimeType: `${string}/${string}`
9930
10152
  reason: string
9931
10153
  } & {
9932
- originEvent: PickFromUnion_2<
9933
- NativeBehaviorEvent,
9934
- 'type',
9935
- 'drag.drop' | 'clipboard.paste'
9936
- >
10154
+ originEvent:
10155
+ | PickFromUnion_2<
10156
+ NativeBehaviorEvent,
10157
+ 'type',
10158
+ 'drag.drop' | 'clipboard.paste'
10159
+ >
10160
+ | InputBehaviorEvent_2
9937
10161
  })
9938
10162
  | ({
9939
10163
  type: 'deserialization.success'
9940
10164
  data: Array<PortableTextBlock>
9941
10165
  mimeType: `${string}/${string}`
9942
10166
  } & {
9943
- originEvent: PickFromUnion_2<
9944
- NativeBehaviorEvent,
9945
- 'type',
9946
- 'drag.drop' | 'clipboard.paste'
9947
- >
10167
+ originEvent:
10168
+ | PickFromUnion_2<
10169
+ NativeBehaviorEvent,
10170
+ 'type',
10171
+ 'drag.drop' | 'clipboard.paste'
10172
+ >
10173
+ | InputBehaviorEvent_2
9948
10174
  })
9949
10175
  | {
9950
10176
  type: 'serialization.success'
@@ -10089,7 +10315,7 @@ declare const editorMachine: StateMachine<
10089
10315
  }
10090
10316
  | {
10091
10317
  type: 'dragstart'
10092
- origin: EventPosition
10318
+ origin: Pick<EventPosition, 'selection'>
10093
10319
  ghost?: HTMLElement
10094
10320
  }
10095
10321
  | {
@@ -10120,7 +10346,7 @@ declare const editorMachine: StateMachine<
10120
10346
  value: Array<PortableTextBlock> | undefined
10121
10347
  internalDrag?: {
10122
10348
  ghost?: HTMLElement
10123
- origin: EventPosition
10349
+ origin: Pick<EventPosition, 'selection'>
10124
10350
  }
10125
10351
  },
10126
10352
  {
@@ -10185,6 +10411,10 @@ declare const editorMachine: StateMachine<
10185
10411
  | {
10186
10412
  type: 'decorator.toggle'
10187
10413
  decorator: string
10414
+ offsets?: {
10415
+ anchor: BlockOffset_2
10416
+ focus: BlockOffset_2
10417
+ }
10188
10418
  }
10189
10419
  | {
10190
10420
  type: 'delete'
@@ -10329,22 +10559,26 @@ declare const editorMachine: StateMachine<
10329
10559
  mimeType: `${string}/${string}`
10330
10560
  reason: string
10331
10561
  } & {
10332
- originEvent: PickFromUnion_2<
10333
- NativeBehaviorEvent,
10334
- 'type',
10335
- 'drag.drop' | 'clipboard.paste'
10336
- >
10562
+ originEvent:
10563
+ | PickFromUnion_2<
10564
+ NativeBehaviorEvent,
10565
+ 'type',
10566
+ 'drag.drop' | 'clipboard.paste'
10567
+ >
10568
+ | InputBehaviorEvent_2
10337
10569
  })
10338
10570
  | ({
10339
10571
  type: 'deserialization.success'
10340
10572
  data: Array<PortableTextBlock>
10341
10573
  mimeType: `${string}/${string}`
10342
10574
  } & {
10343
- originEvent: PickFromUnion_2<
10344
- NativeBehaviorEvent,
10345
- 'type',
10346
- 'drag.drop' | 'clipboard.paste'
10347
- >
10575
+ originEvent:
10576
+ | PickFromUnion_2<
10577
+ NativeBehaviorEvent,
10578
+ 'type',
10579
+ 'drag.drop' | 'clipboard.paste'
10580
+ >
10581
+ | InputBehaviorEvent_2
10348
10582
  })
10349
10583
  | {
10350
10584
  type: 'serialization.success'
@@ -10489,7 +10723,7 @@ declare const editorMachine: StateMachine<
10489
10723
  }
10490
10724
  | {
10491
10725
  type: 'dragstart'
10492
- origin: EventPosition
10726
+ origin: Pick<EventPosition, 'selection'>
10493
10727
  ghost?: HTMLElement
10494
10728
  }
10495
10729
  | {
@@ -10532,7 +10766,7 @@ declare const editorMachine: StateMachine<
10532
10766
  value: Array<PortableTextBlock> | undefined
10533
10767
  internalDrag?: {
10534
10768
  ghost?: HTMLElement
10535
- origin: EventPosition
10769
+ origin: Pick<EventPosition, 'selection'>
10536
10770
  }
10537
10771
  },
10538
10772
  {
@@ -10573,7 +10807,7 @@ declare const editorMachine: StateMachine<
10573
10807
  value: Array<PortableTextBlock> | undefined
10574
10808
  internalDrag?: {
10575
10809
  ghost?: HTMLElement
10576
- origin: EventPosition
10810
+ origin: Pick<EventPosition, 'selection'>
10577
10811
  }
10578
10812
  },
10579
10813
  {
@@ -10605,7 +10839,7 @@ declare const editorMachine: StateMachine<
10605
10839
  value: Array<PortableTextBlock> | undefined
10606
10840
  internalDrag?: {
10607
10841
  ghost?: HTMLElement
10608
- origin: EventPosition
10842
+ origin: Pick<EventPosition, 'selection'>
10609
10843
  }
10610
10844
  },
10611
10845
  {
@@ -10638,7 +10872,7 @@ declare const editorMachine: StateMachine<
10638
10872
  value: Array<PortableTextBlock> | undefined
10639
10873
  internalDrag?: {
10640
10874
  ghost?: HTMLElement
10641
- origin: EventPosition
10875
+ origin: Pick<EventPosition, 'selection'>
10642
10876
  }
10643
10877
  },
10644
10878
  {
@@ -10669,7 +10903,7 @@ declare const editorMachine: StateMachine<
10669
10903
  value: Array<PortableTextBlock> | undefined
10670
10904
  internalDrag?: {
10671
10905
  ghost?: HTMLElement
10672
- origin: EventPosition
10906
+ origin: Pick<EventPosition, 'selection'>
10673
10907
  }
10674
10908
  },
10675
10909
  | {
@@ -10754,6 +10988,10 @@ declare const editorMachine: StateMachine<
10754
10988
  | {
10755
10989
  type: 'decorator.toggle'
10756
10990
  decorator: string
10991
+ offsets?: {
10992
+ anchor: BlockOffset_2
10993
+ focus: BlockOffset_2
10994
+ }
10757
10995
  }
10758
10996
  | {
10759
10997
  type: 'delete'
@@ -10898,22 +11136,26 @@ declare const editorMachine: StateMachine<
10898
11136
  mimeType: `${string}/${string}`
10899
11137
  reason: string
10900
11138
  } & {
10901
- originEvent: PickFromUnion_2<
10902
- NativeBehaviorEvent,
10903
- 'type',
10904
- 'drag.drop' | 'clipboard.paste'
10905
- >
11139
+ originEvent:
11140
+ | PickFromUnion_2<
11141
+ NativeBehaviorEvent,
11142
+ 'type',
11143
+ 'drag.drop' | 'clipboard.paste'
11144
+ >
11145
+ | InputBehaviorEvent_2
10906
11146
  })
10907
11147
  | ({
10908
11148
  type: 'deserialization.success'
10909
11149
  data: Array<PortableTextBlock>
10910
11150
  mimeType: `${string}/${string}`
10911
11151
  } & {
10912
- originEvent: PickFromUnion_2<
10913
- NativeBehaviorEvent,
10914
- 'type',
10915
- 'drag.drop' | 'clipboard.paste'
10916
- >
11152
+ originEvent:
11153
+ | PickFromUnion_2<
11154
+ NativeBehaviorEvent,
11155
+ 'type',
11156
+ 'drag.drop' | 'clipboard.paste'
11157
+ >
11158
+ | InputBehaviorEvent_2
10917
11159
  })
10918
11160
  | {
10919
11161
  type: 'serialization.success'
@@ -11058,7 +11300,7 @@ declare const editorMachine: StateMachine<
11058
11300
  }
11059
11301
  | {
11060
11302
  type: 'dragstart'
11061
- origin: EventPosition
11303
+ origin: Pick<EventPosition, 'selection'>
11062
11304
  ghost?: HTMLElement
11063
11305
  }
11064
11306
  | {
@@ -11130,6 +11372,10 @@ declare const editorMachine: StateMachine<
11130
11372
  | {
11131
11373
  type: 'decorator.toggle'
11132
11374
  decorator: string
11375
+ offsets?: {
11376
+ anchor: BlockOffset_2
11377
+ focus: BlockOffset_2
11378
+ }
11133
11379
  }
11134
11380
  | {
11135
11381
  type: 'delete'
@@ -11274,22 +11520,26 @@ declare const editorMachine: StateMachine<
11274
11520
  mimeType: `${string}/${string}`
11275
11521
  reason: string
11276
11522
  } & {
11277
- originEvent: PickFromUnion_2<
11278
- NativeBehaviorEvent,
11279
- 'type',
11280
- 'drag.drop' | 'clipboard.paste'
11281
- >
11523
+ originEvent:
11524
+ | PickFromUnion_2<
11525
+ NativeBehaviorEvent,
11526
+ 'type',
11527
+ 'drag.drop' | 'clipboard.paste'
11528
+ >
11529
+ | InputBehaviorEvent_2
11282
11530
  })
11283
11531
  | ({
11284
11532
  type: 'deserialization.success'
11285
11533
  data: Array<PortableTextBlock>
11286
11534
  mimeType: `${string}/${string}`
11287
11535
  } & {
11288
- originEvent: PickFromUnion_2<
11289
- NativeBehaviorEvent,
11290
- 'type',
11291
- 'drag.drop' | 'clipboard.paste'
11292
- >
11536
+ originEvent:
11537
+ | PickFromUnion_2<
11538
+ NativeBehaviorEvent,
11539
+ 'type',
11540
+ 'drag.drop' | 'clipboard.paste'
11541
+ >
11542
+ | InputBehaviorEvent_2
11293
11543
  })
11294
11544
  | {
11295
11545
  type: 'serialization.success'
@@ -11378,7 +11628,7 @@ declare const editorMachine: StateMachine<
11378
11628
  value: Array<PortableTextBlock> | undefined
11379
11629
  internalDrag?: {
11380
11630
  ghost?: HTMLElement
11381
- origin: EventPosition
11631
+ origin: Pick<EventPosition, 'selection'>
11382
11632
  }
11383
11633
  },
11384
11634
  | {
@@ -11449,6 +11699,10 @@ declare const editorMachine: StateMachine<
11449
11699
  | {
11450
11700
  type: 'decorator.toggle'
11451
11701
  decorator: string
11702
+ offsets?: {
11703
+ anchor: BlockOffset_2
11704
+ focus: BlockOffset_2
11705
+ }
11452
11706
  }
11453
11707
  | {
11454
11708
  type: 'delete'
@@ -11593,22 +11847,26 @@ declare const editorMachine: StateMachine<
11593
11847
  mimeType: `${string}/${string}`
11594
11848
  reason: string
11595
11849
  } & {
11596
- originEvent: PickFromUnion_2<
11597
- NativeBehaviorEvent,
11598
- 'type',
11599
- 'drag.drop' | 'clipboard.paste'
11600
- >
11850
+ originEvent:
11851
+ | PickFromUnion_2<
11852
+ NativeBehaviorEvent,
11853
+ 'type',
11854
+ 'drag.drop' | 'clipboard.paste'
11855
+ >
11856
+ | InputBehaviorEvent_2
11601
11857
  })
11602
11858
  | ({
11603
11859
  type: 'deserialization.success'
11604
11860
  data: Array<PortableTextBlock>
11605
11861
  mimeType: `${string}/${string}`
11606
11862
  } & {
11607
- originEvent: PickFromUnion_2<
11608
- NativeBehaviorEvent,
11609
- 'type',
11610
- 'drag.drop' | 'clipboard.paste'
11611
- >
11863
+ originEvent:
11864
+ | PickFromUnion_2<
11865
+ NativeBehaviorEvent,
11866
+ 'type',
11867
+ 'drag.drop' | 'clipboard.paste'
11868
+ >
11869
+ | InputBehaviorEvent_2
11612
11870
  })
11613
11871
  | {
11614
11872
  type: 'serialization.success'
@@ -11753,7 +12011,7 @@ declare const editorMachine: StateMachine<
11753
12011
  }
11754
12012
  | {
11755
12013
  type: 'dragstart'
11756
- origin: EventPosition
12014
+ origin: Pick<EventPosition, 'selection'>
11757
12015
  ghost?: HTMLElement
11758
12016
  }
11759
12017
  | {
@@ -11825,6 +12083,10 @@ declare const editorMachine: StateMachine<
11825
12083
  | {
11826
12084
  type: 'decorator.toggle'
11827
12085
  decorator: string
12086
+ offsets?: {
12087
+ anchor: BlockOffset_2
12088
+ focus: BlockOffset_2
12089
+ }
11828
12090
  }
11829
12091
  | {
11830
12092
  type: 'delete'
@@ -11969,22 +12231,26 @@ declare const editorMachine: StateMachine<
11969
12231
  mimeType: `${string}/${string}`
11970
12232
  reason: string
11971
12233
  } & {
11972
- originEvent: PickFromUnion_2<
11973
- NativeBehaviorEvent,
11974
- 'type',
11975
- 'drag.drop' | 'clipboard.paste'
11976
- >
12234
+ originEvent:
12235
+ | PickFromUnion_2<
12236
+ NativeBehaviorEvent,
12237
+ 'type',
12238
+ 'drag.drop' | 'clipboard.paste'
12239
+ >
12240
+ | InputBehaviorEvent_2
11977
12241
  })
11978
12242
  | ({
11979
12243
  type: 'deserialization.success'
11980
12244
  data: Array<PortableTextBlock>
11981
12245
  mimeType: `${string}/${string}`
11982
12246
  } & {
11983
- originEvent: PickFromUnion_2<
11984
- NativeBehaviorEvent,
11985
- 'type',
11986
- 'drag.drop' | 'clipboard.paste'
11987
- >
12247
+ originEvent:
12248
+ | PickFromUnion_2<
12249
+ NativeBehaviorEvent,
12250
+ 'type',
12251
+ 'drag.drop' | 'clipboard.paste'
12252
+ >
12253
+ | InputBehaviorEvent_2
11988
12254
  })
11989
12255
  | {
11990
12256
  type: 'serialization.success'
@@ -12073,7 +12339,7 @@ declare const editorMachine: StateMachine<
12073
12339
  value: Array<PortableTextBlock> | undefined
12074
12340
  internalDrag?: {
12075
12341
  ghost?: HTMLElement
12076
- origin: EventPosition
12342
+ origin: Pick<EventPosition, 'selection'>
12077
12343
  }
12078
12344
  },
12079
12345
  {
@@ -12137,6 +12403,10 @@ declare const editorMachine: StateMachine<
12137
12403
  | {
12138
12404
  type: 'decorator.toggle'
12139
12405
  decorator: string
12406
+ offsets?: {
12407
+ anchor: BlockOffset_2
12408
+ focus: BlockOffset_2
12409
+ }
12140
12410
  }
12141
12411
  | {
12142
12412
  type: 'delete'
@@ -12281,22 +12551,26 @@ declare const editorMachine: StateMachine<
12281
12551
  mimeType: `${string}/${string}`
12282
12552
  reason: string
12283
12553
  } & {
12284
- originEvent: PickFromUnion_2<
12285
- NativeBehaviorEvent,
12286
- 'type',
12287
- 'drag.drop' | 'clipboard.paste'
12288
- >
12554
+ originEvent:
12555
+ | PickFromUnion_2<
12556
+ NativeBehaviorEvent,
12557
+ 'type',
12558
+ 'drag.drop' | 'clipboard.paste'
12559
+ >
12560
+ | InputBehaviorEvent_2
12289
12561
  })
12290
12562
  | ({
12291
12563
  type: 'deserialization.success'
12292
12564
  data: Array<PortableTextBlock>
12293
12565
  mimeType: `${string}/${string}`
12294
12566
  } & {
12295
- originEvent: PickFromUnion_2<
12296
- NativeBehaviorEvent,
12297
- 'type',
12298
- 'drag.drop' | 'clipboard.paste'
12299
- >
12567
+ originEvent:
12568
+ | PickFromUnion_2<
12569
+ NativeBehaviorEvent,
12570
+ 'type',
12571
+ 'drag.drop' | 'clipboard.paste'
12572
+ >
12573
+ | InputBehaviorEvent_2
12300
12574
  })
12301
12575
  | {
12302
12576
  type: 'serialization.success'
@@ -12441,7 +12715,7 @@ declare const editorMachine: StateMachine<
12441
12715
  }
12442
12716
  | {
12443
12717
  type: 'dragstart'
12444
- origin: EventPosition
12718
+ origin: Pick<EventPosition, 'selection'>
12445
12719
  ghost?: HTMLElement
12446
12720
  }
12447
12721
  | {
@@ -12513,6 +12787,10 @@ declare const editorMachine: StateMachine<
12513
12787
  | {
12514
12788
  type: 'decorator.toggle'
12515
12789
  decorator: string
12790
+ offsets?: {
12791
+ anchor: BlockOffset_2
12792
+ focus: BlockOffset_2
12793
+ }
12516
12794
  }
12517
12795
  | {
12518
12796
  type: 'delete'
@@ -12657,22 +12935,26 @@ declare const editorMachine: StateMachine<
12657
12935
  mimeType: `${string}/${string}`
12658
12936
  reason: string
12659
12937
  } & {
12660
- originEvent: PickFromUnion_2<
12661
- NativeBehaviorEvent,
12662
- 'type',
12663
- 'drag.drop' | 'clipboard.paste'
12664
- >
12938
+ originEvent:
12939
+ | PickFromUnion_2<
12940
+ NativeBehaviorEvent,
12941
+ 'type',
12942
+ 'drag.drop' | 'clipboard.paste'
12943
+ >
12944
+ | InputBehaviorEvent_2
12665
12945
  })
12666
12946
  | ({
12667
12947
  type: 'deserialization.success'
12668
12948
  data: Array<PortableTextBlock>
12669
12949
  mimeType: `${string}/${string}`
12670
12950
  } & {
12671
- originEvent: PickFromUnion_2<
12672
- NativeBehaviorEvent,
12673
- 'type',
12674
- 'drag.drop' | 'clipboard.paste'
12675
- >
12951
+ originEvent:
12952
+ | PickFromUnion_2<
12953
+ NativeBehaviorEvent,
12954
+ 'type',
12955
+ 'drag.drop' | 'clipboard.paste'
12956
+ >
12957
+ | InputBehaviorEvent_2
12676
12958
  })
12677
12959
  | {
12678
12960
  type: 'serialization.success'
@@ -12761,7 +13043,7 @@ declare const editorMachine: StateMachine<
12761
13043
  value: Array<PortableTextBlock> | undefined
12762
13044
  internalDrag?: {
12763
13045
  ghost?: HTMLElement
12764
- origin: EventPosition
13046
+ origin: Pick<EventPosition, 'selection'>
12765
13047
  }
12766
13048
  },
12767
13049
  {
@@ -12825,6 +13107,10 @@ declare const editorMachine: StateMachine<
12825
13107
  | {
12826
13108
  type: 'decorator.toggle'
12827
13109
  decorator: string
13110
+ offsets?: {
13111
+ anchor: BlockOffset_2
13112
+ focus: BlockOffset_2
13113
+ }
12828
13114
  }
12829
13115
  | {
12830
13116
  type: 'delete'
@@ -12969,22 +13255,26 @@ declare const editorMachine: StateMachine<
12969
13255
  mimeType: `${string}/${string}`
12970
13256
  reason: string
12971
13257
  } & {
12972
- originEvent: PickFromUnion_2<
12973
- NativeBehaviorEvent,
12974
- 'type',
12975
- 'drag.drop' | 'clipboard.paste'
12976
- >
13258
+ originEvent:
13259
+ | PickFromUnion_2<
13260
+ NativeBehaviorEvent,
13261
+ 'type',
13262
+ 'drag.drop' | 'clipboard.paste'
13263
+ >
13264
+ | InputBehaviorEvent_2
12977
13265
  })
12978
13266
  | ({
12979
13267
  type: 'deserialization.success'
12980
13268
  data: Array<PortableTextBlock>
12981
13269
  mimeType: `${string}/${string}`
12982
13270
  } & {
12983
- originEvent: PickFromUnion_2<
12984
- NativeBehaviorEvent,
12985
- 'type',
12986
- 'drag.drop' | 'clipboard.paste'
12987
- >
13271
+ originEvent:
13272
+ | PickFromUnion_2<
13273
+ NativeBehaviorEvent,
13274
+ 'type',
13275
+ 'drag.drop' | 'clipboard.paste'
13276
+ >
13277
+ | InputBehaviorEvent_2
12988
13278
  })
12989
13279
  | {
12990
13280
  type: 'serialization.success'
@@ -13129,7 +13419,7 @@ declare const editorMachine: StateMachine<
13129
13419
  }
13130
13420
  | {
13131
13421
  type: 'dragstart'
13132
- origin: EventPosition
13422
+ origin: Pick<EventPosition, 'selection'>
13133
13423
  ghost?: HTMLElement
13134
13424
  }
13135
13425
  | {
@@ -13201,6 +13491,10 @@ declare const editorMachine: StateMachine<
13201
13491
  | {
13202
13492
  type: 'decorator.toggle'
13203
13493
  decorator: string
13494
+ offsets?: {
13495
+ anchor: BlockOffset_2
13496
+ focus: BlockOffset_2
13497
+ }
13204
13498
  }
13205
13499
  | {
13206
13500
  type: 'delete'
@@ -13345,22 +13639,26 @@ declare const editorMachine: StateMachine<
13345
13639
  mimeType: `${string}/${string}`
13346
13640
  reason: string
13347
13641
  } & {
13348
- originEvent: PickFromUnion_2<
13349
- NativeBehaviorEvent,
13350
- 'type',
13351
- 'drag.drop' | 'clipboard.paste'
13352
- >
13642
+ originEvent:
13643
+ | PickFromUnion_2<
13644
+ NativeBehaviorEvent,
13645
+ 'type',
13646
+ 'drag.drop' | 'clipboard.paste'
13647
+ >
13648
+ | InputBehaviorEvent_2
13353
13649
  })
13354
13650
  | ({
13355
13651
  type: 'deserialization.success'
13356
13652
  data: Array<PortableTextBlock>
13357
13653
  mimeType: `${string}/${string}`
13358
13654
  } & {
13359
- originEvent: PickFromUnion_2<
13360
- NativeBehaviorEvent,
13361
- 'type',
13362
- 'drag.drop' | 'clipboard.paste'
13363
- >
13655
+ originEvent:
13656
+ | PickFromUnion_2<
13657
+ NativeBehaviorEvent,
13658
+ 'type',
13659
+ 'drag.drop' | 'clipboard.paste'
13660
+ >
13661
+ | InputBehaviorEvent_2
13364
13662
  })
13365
13663
  | {
13366
13664
  type: 'serialization.success'
@@ -13449,7 +13747,7 @@ declare const editorMachine: StateMachine<
13449
13747
  value: Array<PortableTextBlock> | undefined
13450
13748
  internalDrag?: {
13451
13749
  ghost?: HTMLElement
13452
- origin: EventPosition
13750
+ origin: Pick<EventPosition, 'selection'>
13453
13751
  }
13454
13752
  },
13455
13753
  | {
@@ -13467,6 +13765,10 @@ declare const editorMachine: StateMachine<
13467
13765
  | {
13468
13766
  type: 'decorator.toggle'
13469
13767
  decorator: string
13768
+ offsets?: {
13769
+ anchor: BlockOffset_2
13770
+ focus: BlockOffset_2
13771
+ }
13470
13772
  },
13471
13773
  | {
13472
13774
  type: 'annotation.add'
@@ -13526,6 +13828,10 @@ declare const editorMachine: StateMachine<
13526
13828
  | {
13527
13829
  type: 'decorator.toggle'
13528
13830
  decorator: string
13831
+ offsets?: {
13832
+ anchor: BlockOffset_2
13833
+ focus: BlockOffset_2
13834
+ }
13529
13835
  }
13530
13836
  | {
13531
13837
  type: 'delete'
@@ -13670,22 +13976,26 @@ declare const editorMachine: StateMachine<
13670
13976
  mimeType: `${string}/${string}`
13671
13977
  reason: string
13672
13978
  } & {
13673
- originEvent: PickFromUnion_2<
13674
- NativeBehaviorEvent,
13675
- 'type',
13676
- 'drag.drop' | 'clipboard.paste'
13677
- >
13979
+ originEvent:
13980
+ | PickFromUnion_2<
13981
+ NativeBehaviorEvent,
13982
+ 'type',
13983
+ 'drag.drop' | 'clipboard.paste'
13984
+ >
13985
+ | InputBehaviorEvent_2
13678
13986
  })
13679
13987
  | ({
13680
13988
  type: 'deserialization.success'
13681
13989
  data: Array<PortableTextBlock>
13682
13990
  mimeType: `${string}/${string}`
13683
13991
  } & {
13684
- originEvent: PickFromUnion_2<
13685
- NativeBehaviorEvent,
13686
- 'type',
13687
- 'drag.drop' | 'clipboard.paste'
13688
- >
13992
+ originEvent:
13993
+ | PickFromUnion_2<
13994
+ NativeBehaviorEvent,
13995
+ 'type',
13996
+ 'drag.drop' | 'clipboard.paste'
13997
+ >
13998
+ | InputBehaviorEvent_2
13689
13999
  })
13690
14000
  | {
13691
14001
  type: 'serialization.success'
@@ -13830,7 +14140,7 @@ declare const editorMachine: StateMachine<
13830
14140
  }
13831
14141
  | {
13832
14142
  type: 'dragstart'
13833
- origin: EventPosition
14143
+ origin: Pick<EventPosition, 'selection'>
13834
14144
  ghost?: HTMLElement
13835
14145
  }
13836
14146
  | {
@@ -13902,6 +14212,10 @@ declare const editorMachine: StateMachine<
13902
14212
  | {
13903
14213
  type: 'decorator.toggle'
13904
14214
  decorator: string
14215
+ offsets?: {
14216
+ anchor: BlockOffset_2
14217
+ focus: BlockOffset_2
14218
+ }
13905
14219
  }
13906
14220
  | {
13907
14221
  type: 'delete'
@@ -14046,22 +14360,26 @@ declare const editorMachine: StateMachine<
14046
14360
  mimeType: `${string}/${string}`
14047
14361
  reason: string
14048
14362
  } & {
14049
- originEvent: PickFromUnion_2<
14050
- NativeBehaviorEvent,
14051
- 'type',
14052
- 'drag.drop' | 'clipboard.paste'
14053
- >
14363
+ originEvent:
14364
+ | PickFromUnion_2<
14365
+ NativeBehaviorEvent,
14366
+ 'type',
14367
+ 'drag.drop' | 'clipboard.paste'
14368
+ >
14369
+ | InputBehaviorEvent_2
14054
14370
  })
14055
14371
  | ({
14056
14372
  type: 'deserialization.success'
14057
14373
  data: Array<PortableTextBlock>
14058
14374
  mimeType: `${string}/${string}`
14059
14375
  } & {
14060
- originEvent: PickFromUnion_2<
14061
- NativeBehaviorEvent,
14062
- 'type',
14063
- 'drag.drop' | 'clipboard.paste'
14064
- >
14376
+ originEvent:
14377
+ | PickFromUnion_2<
14378
+ NativeBehaviorEvent,
14379
+ 'type',
14380
+ 'drag.drop' | 'clipboard.paste'
14381
+ >
14382
+ | InputBehaviorEvent_2
14065
14383
  })
14066
14384
  | {
14067
14385
  type: 'serialization.success'
@@ -14150,7 +14468,7 @@ declare const editorMachine: StateMachine<
14150
14468
  value: Array<PortableTextBlock> | undefined
14151
14469
  internalDrag?: {
14152
14470
  ghost?: HTMLElement
14153
- origin: EventPosition
14471
+ origin: Pick<EventPosition, 'selection'>
14154
14472
  }
14155
14473
  },
14156
14474
  | {
@@ -14228,8 +14546,12 @@ declare const editorMachine: StateMachine<
14228
14546
  | {
14229
14547
  type: 'decorator.toggle'
14230
14548
  decorator: string
14231
- }
14232
- | {
14549
+ offsets?: {
14550
+ anchor: BlockOffset_2
14551
+ focus: BlockOffset_2
14552
+ }
14553
+ }
14554
+ | {
14233
14555
  type: 'delete'
14234
14556
  selection: NonNullable<EditorSelection>
14235
14557
  }
@@ -14372,22 +14694,26 @@ declare const editorMachine: StateMachine<
14372
14694
  mimeType: `${string}/${string}`
14373
14695
  reason: string
14374
14696
  } & {
14375
- originEvent: PickFromUnion_2<
14376
- NativeBehaviorEvent,
14377
- 'type',
14378
- 'drag.drop' | 'clipboard.paste'
14379
- >
14697
+ originEvent:
14698
+ | PickFromUnion_2<
14699
+ NativeBehaviorEvent,
14700
+ 'type',
14701
+ 'drag.drop' | 'clipboard.paste'
14702
+ >
14703
+ | InputBehaviorEvent_2
14380
14704
  })
14381
14705
  | ({
14382
14706
  type: 'deserialization.success'
14383
14707
  data: Array<PortableTextBlock>
14384
14708
  mimeType: `${string}/${string}`
14385
14709
  } & {
14386
- originEvent: PickFromUnion_2<
14387
- NativeBehaviorEvent,
14388
- 'type',
14389
- 'drag.drop' | 'clipboard.paste'
14390
- >
14710
+ originEvent:
14711
+ | PickFromUnion_2<
14712
+ NativeBehaviorEvent,
14713
+ 'type',
14714
+ 'drag.drop' | 'clipboard.paste'
14715
+ >
14716
+ | InputBehaviorEvent_2
14391
14717
  })
14392
14718
  | {
14393
14719
  type: 'serialization.success'
@@ -14532,7 +14858,7 @@ declare const editorMachine: StateMachine<
14532
14858
  }
14533
14859
  | {
14534
14860
  type: 'dragstart'
14535
- origin: EventPosition
14861
+ origin: Pick<EventPosition, 'selection'>
14536
14862
  ghost?: HTMLElement
14537
14863
  }
14538
14864
  | {
@@ -14604,6 +14930,10 @@ declare const editorMachine: StateMachine<
14604
14930
  | {
14605
14931
  type: 'decorator.toggle'
14606
14932
  decorator: string
14933
+ offsets?: {
14934
+ anchor: BlockOffset_2
14935
+ focus: BlockOffset_2
14936
+ }
14607
14937
  }
14608
14938
  | {
14609
14939
  type: 'delete'
@@ -14748,22 +15078,26 @@ declare const editorMachine: StateMachine<
14748
15078
  mimeType: `${string}/${string}`
14749
15079
  reason: string
14750
15080
  } & {
14751
- originEvent: PickFromUnion_2<
14752
- NativeBehaviorEvent,
14753
- 'type',
14754
- 'drag.drop' | 'clipboard.paste'
14755
- >
15081
+ originEvent:
15082
+ | PickFromUnion_2<
15083
+ NativeBehaviorEvent,
15084
+ 'type',
15085
+ 'drag.drop' | 'clipboard.paste'
15086
+ >
15087
+ | InputBehaviorEvent_2
14756
15088
  })
14757
15089
  | ({
14758
15090
  type: 'deserialization.success'
14759
15091
  data: Array<PortableTextBlock>
14760
15092
  mimeType: `${string}/${string}`
14761
15093
  } & {
14762
- originEvent: PickFromUnion_2<
14763
- NativeBehaviorEvent,
14764
- 'type',
14765
- 'drag.drop' | 'clipboard.paste'
14766
- >
15094
+ originEvent:
15095
+ | PickFromUnion_2<
15096
+ NativeBehaviorEvent,
15097
+ 'type',
15098
+ 'drag.drop' | 'clipboard.paste'
15099
+ >
15100
+ | InputBehaviorEvent_2
14767
15101
  })
14768
15102
  | {
14769
15103
  type: 'serialization.success'
@@ -14852,7 +15186,7 @@ declare const editorMachine: StateMachine<
14852
15186
  value: Array<PortableTextBlock> | undefined
14853
15187
  internalDrag?: {
14854
15188
  ghost?: HTMLElement
14855
- origin: EventPosition
15189
+ origin: Pick<EventPosition, 'selection'>
14856
15190
  }
14857
15191
  },
14858
15192
  {
@@ -14916,6 +15250,10 @@ declare const editorMachine: StateMachine<
14916
15250
  | {
14917
15251
  type: 'decorator.toggle'
14918
15252
  decorator: string
15253
+ offsets?: {
15254
+ anchor: BlockOffset_2
15255
+ focus: BlockOffset_2
15256
+ }
14919
15257
  }
14920
15258
  | {
14921
15259
  type: 'delete'
@@ -15060,22 +15398,26 @@ declare const editorMachine: StateMachine<
15060
15398
  mimeType: `${string}/${string}`
15061
15399
  reason: string
15062
15400
  } & {
15063
- originEvent: PickFromUnion_2<
15064
- NativeBehaviorEvent,
15065
- 'type',
15066
- 'drag.drop' | 'clipboard.paste'
15067
- >
15401
+ originEvent:
15402
+ | PickFromUnion_2<
15403
+ NativeBehaviorEvent,
15404
+ 'type',
15405
+ 'drag.drop' | 'clipboard.paste'
15406
+ >
15407
+ | InputBehaviorEvent_2
15068
15408
  })
15069
15409
  | ({
15070
15410
  type: 'deserialization.success'
15071
15411
  data: Array<PortableTextBlock>
15072
15412
  mimeType: `${string}/${string}`
15073
15413
  } & {
15074
- originEvent: PickFromUnion_2<
15075
- NativeBehaviorEvent,
15076
- 'type',
15077
- 'drag.drop' | 'clipboard.paste'
15078
- >
15414
+ originEvent:
15415
+ | PickFromUnion_2<
15416
+ NativeBehaviorEvent,
15417
+ 'type',
15418
+ 'drag.drop' | 'clipboard.paste'
15419
+ >
15420
+ | InputBehaviorEvent_2
15079
15421
  })
15080
15422
  | {
15081
15423
  type: 'serialization.success'
@@ -15220,7 +15562,7 @@ declare const editorMachine: StateMachine<
15220
15562
  }
15221
15563
  | {
15222
15564
  type: 'dragstart'
15223
- origin: EventPosition
15565
+ origin: Pick<EventPosition, 'selection'>
15224
15566
  ghost?: HTMLElement
15225
15567
  }
15226
15568
  | {
@@ -15292,6 +15634,10 @@ declare const editorMachine: StateMachine<
15292
15634
  | {
15293
15635
  type: 'decorator.toggle'
15294
15636
  decorator: string
15637
+ offsets?: {
15638
+ anchor: BlockOffset_2
15639
+ focus: BlockOffset_2
15640
+ }
15295
15641
  }
15296
15642
  | {
15297
15643
  type: 'delete'
@@ -15436,22 +15782,26 @@ declare const editorMachine: StateMachine<
15436
15782
  mimeType: `${string}/${string}`
15437
15783
  reason: string
15438
15784
  } & {
15439
- originEvent: PickFromUnion_2<
15440
- NativeBehaviorEvent,
15441
- 'type',
15442
- 'drag.drop' | 'clipboard.paste'
15443
- >
15785
+ originEvent:
15786
+ | PickFromUnion_2<
15787
+ NativeBehaviorEvent,
15788
+ 'type',
15789
+ 'drag.drop' | 'clipboard.paste'
15790
+ >
15791
+ | InputBehaviorEvent_2
15444
15792
  })
15445
15793
  | ({
15446
15794
  type: 'deserialization.success'
15447
15795
  data: Array<PortableTextBlock>
15448
15796
  mimeType: `${string}/${string}`
15449
15797
  } & {
15450
- originEvent: PickFromUnion_2<
15451
- NativeBehaviorEvent,
15452
- 'type',
15453
- 'drag.drop' | 'clipboard.paste'
15454
- >
15798
+ originEvent:
15799
+ | PickFromUnion_2<
15800
+ NativeBehaviorEvent,
15801
+ 'type',
15802
+ 'drag.drop' | 'clipboard.paste'
15803
+ >
15804
+ | InputBehaviorEvent_2
15455
15805
  })
15456
15806
  | {
15457
15807
  type: 'serialization.success'
@@ -15540,7 +15890,7 @@ declare const editorMachine: StateMachine<
15540
15890
  value: Array<PortableTextBlock> | undefined
15541
15891
  internalDrag?: {
15542
15892
  ghost?: HTMLElement
15543
- origin: EventPosition
15893
+ origin: Pick<EventPosition, 'selection'>
15544
15894
  }
15545
15895
  },
15546
15896
  | {
@@ -15607,6 +15957,10 @@ declare const editorMachine: StateMachine<
15607
15957
  | {
15608
15958
  type: 'decorator.toggle'
15609
15959
  decorator: string
15960
+ offsets?: {
15961
+ anchor: BlockOffset_2
15962
+ focus: BlockOffset_2
15963
+ }
15610
15964
  }
15611
15965
  | {
15612
15966
  type: 'delete'
@@ -15751,22 +16105,26 @@ declare const editorMachine: StateMachine<
15751
16105
  mimeType: `${string}/${string}`
15752
16106
  reason: string
15753
16107
  } & {
15754
- originEvent: PickFromUnion_2<
15755
- NativeBehaviorEvent,
15756
- 'type',
15757
- 'drag.drop' | 'clipboard.paste'
15758
- >
16108
+ originEvent:
16109
+ | PickFromUnion_2<
16110
+ NativeBehaviorEvent,
16111
+ 'type',
16112
+ 'drag.drop' | 'clipboard.paste'
16113
+ >
16114
+ | InputBehaviorEvent_2
15759
16115
  })
15760
16116
  | ({
15761
16117
  type: 'deserialization.success'
15762
16118
  data: Array<PortableTextBlock>
15763
16119
  mimeType: `${string}/${string}`
15764
16120
  } & {
15765
- originEvent: PickFromUnion_2<
15766
- NativeBehaviorEvent,
15767
- 'type',
15768
- 'drag.drop' | 'clipboard.paste'
15769
- >
16121
+ originEvent:
16122
+ | PickFromUnion_2<
16123
+ NativeBehaviorEvent,
16124
+ 'type',
16125
+ 'drag.drop' | 'clipboard.paste'
16126
+ >
16127
+ | InputBehaviorEvent_2
15770
16128
  })
15771
16129
  | {
15772
16130
  type: 'serialization.success'
@@ -15911,7 +16269,7 @@ declare const editorMachine: StateMachine<
15911
16269
  }
15912
16270
  | {
15913
16271
  type: 'dragstart'
15914
- origin: EventPosition
16272
+ origin: Pick<EventPosition, 'selection'>
15915
16273
  ghost?: HTMLElement
15916
16274
  }
15917
16275
  | {
@@ -15983,6 +16341,10 @@ declare const editorMachine: StateMachine<
15983
16341
  | {
15984
16342
  type: 'decorator.toggle'
15985
16343
  decorator: string
16344
+ offsets?: {
16345
+ anchor: BlockOffset_2
16346
+ focus: BlockOffset_2
16347
+ }
15986
16348
  }
15987
16349
  | {
15988
16350
  type: 'delete'
@@ -16127,22 +16489,26 @@ declare const editorMachine: StateMachine<
16127
16489
  mimeType: `${string}/${string}`
16128
16490
  reason: string
16129
16491
  } & {
16130
- originEvent: PickFromUnion_2<
16131
- NativeBehaviorEvent,
16132
- 'type',
16133
- 'drag.drop' | 'clipboard.paste'
16134
- >
16492
+ originEvent:
16493
+ | PickFromUnion_2<
16494
+ NativeBehaviorEvent,
16495
+ 'type',
16496
+ 'drag.drop' | 'clipboard.paste'
16497
+ >
16498
+ | InputBehaviorEvent_2
16135
16499
  })
16136
16500
  | ({
16137
16501
  type: 'deserialization.success'
16138
16502
  data: Array<PortableTextBlock>
16139
16503
  mimeType: `${string}/${string}`
16140
16504
  } & {
16141
- originEvent: PickFromUnion_2<
16142
- NativeBehaviorEvent,
16143
- 'type',
16144
- 'drag.drop' | 'clipboard.paste'
16145
- >
16505
+ originEvent:
16506
+ | PickFromUnion_2<
16507
+ NativeBehaviorEvent,
16508
+ 'type',
16509
+ 'drag.drop' | 'clipboard.paste'
16510
+ >
16511
+ | InputBehaviorEvent_2
16146
16512
  })
16147
16513
  | {
16148
16514
  type: 'serialization.success'
@@ -16231,7 +16597,7 @@ declare const editorMachine: StateMachine<
16231
16597
  value: Array<PortableTextBlock> | undefined
16232
16598
  internalDrag?: {
16233
16599
  ghost?: HTMLElement
16234
- origin: EventPosition
16600
+ origin: Pick<EventPosition, 'selection'>
16235
16601
  }
16236
16602
  },
16237
16603
  | {
@@ -16351,6 +16717,10 @@ declare const editorMachine: StateMachine<
16351
16717
  | {
16352
16718
  type: 'decorator.toggle'
16353
16719
  decorator: string
16720
+ offsets?: {
16721
+ anchor: BlockOffset_2
16722
+ focus: BlockOffset_2
16723
+ }
16354
16724
  }
16355
16725
  | {
16356
16726
  type: 'delete'
@@ -16495,22 +16865,26 @@ declare const editorMachine: StateMachine<
16495
16865
  mimeType: `${string}/${string}`
16496
16866
  reason: string
16497
16867
  } & {
16498
- originEvent: PickFromUnion_2<
16499
- NativeBehaviorEvent,
16500
- 'type',
16501
- 'drag.drop' | 'clipboard.paste'
16502
- >
16868
+ originEvent:
16869
+ | PickFromUnion_2<
16870
+ NativeBehaviorEvent,
16871
+ 'type',
16872
+ 'drag.drop' | 'clipboard.paste'
16873
+ >
16874
+ | InputBehaviorEvent_2
16503
16875
  })
16504
16876
  | ({
16505
16877
  type: 'deserialization.success'
16506
16878
  data: Array<PortableTextBlock>
16507
16879
  mimeType: `${string}/${string}`
16508
16880
  } & {
16509
- originEvent: PickFromUnion_2<
16510
- NativeBehaviorEvent,
16511
- 'type',
16512
- 'drag.drop' | 'clipboard.paste'
16513
- >
16881
+ originEvent:
16882
+ | PickFromUnion_2<
16883
+ NativeBehaviorEvent,
16884
+ 'type',
16885
+ 'drag.drop' | 'clipboard.paste'
16886
+ >
16887
+ | InputBehaviorEvent_2
16514
16888
  })
16515
16889
  | {
16516
16890
  type: 'serialization.success'
@@ -16655,7 +17029,7 @@ declare const editorMachine: StateMachine<
16655
17029
  }
16656
17030
  | {
16657
17031
  type: 'dragstart'
16658
- origin: EventPosition
17032
+ origin: Pick<EventPosition, 'selection'>
16659
17033
  ghost?: HTMLElement
16660
17034
  }
16661
17035
  | {
@@ -16727,6 +17101,10 @@ declare const editorMachine: StateMachine<
16727
17101
  | {
16728
17102
  type: 'decorator.toggle'
16729
17103
  decorator: string
17104
+ offsets?: {
17105
+ anchor: BlockOffset_2
17106
+ focus: BlockOffset_2
17107
+ }
16730
17108
  }
16731
17109
  | {
16732
17110
  type: 'delete'
@@ -16871,22 +17249,26 @@ declare const editorMachine: StateMachine<
16871
17249
  mimeType: `${string}/${string}`
16872
17250
  reason: string
16873
17251
  } & {
16874
- originEvent: PickFromUnion_2<
16875
- NativeBehaviorEvent,
16876
- 'type',
16877
- 'drag.drop' | 'clipboard.paste'
16878
- >
17252
+ originEvent:
17253
+ | PickFromUnion_2<
17254
+ NativeBehaviorEvent,
17255
+ 'type',
17256
+ 'drag.drop' | 'clipboard.paste'
17257
+ >
17258
+ | InputBehaviorEvent_2
16879
17259
  })
16880
17260
  | ({
16881
17261
  type: 'deserialization.success'
16882
17262
  data: Array<PortableTextBlock>
16883
17263
  mimeType: `${string}/${string}`
16884
17264
  } & {
16885
- originEvent: PickFromUnion_2<
16886
- NativeBehaviorEvent,
16887
- 'type',
16888
- 'drag.drop' | 'clipboard.paste'
16889
- >
17265
+ originEvent:
17266
+ | PickFromUnion_2<
17267
+ NativeBehaviorEvent,
17268
+ 'type',
17269
+ 'drag.drop' | 'clipboard.paste'
17270
+ >
17271
+ | InputBehaviorEvent_2
16890
17272
  })
16891
17273
  | {
16892
17274
  type: 'serialization.success'
@@ -16975,7 +17357,7 @@ declare const editorMachine: StateMachine<
16975
17357
  value: Array<PortableTextBlock> | undefined
16976
17358
  internalDrag?: {
16977
17359
  ghost?: HTMLElement
16978
- origin: EventPosition
17360
+ origin: Pick<EventPosition, 'selection'>
16979
17361
  }
16980
17362
  },
16981
17363
  | {
@@ -17048,6 +17430,10 @@ declare const editorMachine: StateMachine<
17048
17430
  | {
17049
17431
  type: 'decorator.toggle'
17050
17432
  decorator: string
17433
+ offsets?: {
17434
+ anchor: BlockOffset_2
17435
+ focus: BlockOffset_2
17436
+ }
17051
17437
  }
17052
17438
  | {
17053
17439
  type: 'delete'
@@ -17192,22 +17578,26 @@ declare const editorMachine: StateMachine<
17192
17578
  mimeType: `${string}/${string}`
17193
17579
  reason: string
17194
17580
  } & {
17195
- originEvent: PickFromUnion_2<
17196
- NativeBehaviorEvent,
17197
- 'type',
17198
- 'drag.drop' | 'clipboard.paste'
17199
- >
17581
+ originEvent:
17582
+ | PickFromUnion_2<
17583
+ NativeBehaviorEvent,
17584
+ 'type',
17585
+ 'drag.drop' | 'clipboard.paste'
17586
+ >
17587
+ | InputBehaviorEvent_2
17200
17588
  })
17201
17589
  | ({
17202
17590
  type: 'deserialization.success'
17203
17591
  data: Array<PortableTextBlock>
17204
17592
  mimeType: `${string}/${string}`
17205
17593
  } & {
17206
- originEvent: PickFromUnion_2<
17207
- NativeBehaviorEvent,
17208
- 'type',
17209
- 'drag.drop' | 'clipboard.paste'
17210
- >
17594
+ originEvent:
17595
+ | PickFromUnion_2<
17596
+ NativeBehaviorEvent,
17597
+ 'type',
17598
+ 'drag.drop' | 'clipboard.paste'
17599
+ >
17600
+ | InputBehaviorEvent_2
17211
17601
  })
17212
17602
  | {
17213
17603
  type: 'serialization.success'
@@ -17352,7 +17742,7 @@ declare const editorMachine: StateMachine<
17352
17742
  }
17353
17743
  | {
17354
17744
  type: 'dragstart'
17355
- origin: EventPosition
17745
+ origin: Pick<EventPosition, 'selection'>
17356
17746
  ghost?: HTMLElement
17357
17747
  }
17358
17748
  | {
@@ -17424,6 +17814,10 @@ declare const editorMachine: StateMachine<
17424
17814
  | {
17425
17815
  type: 'decorator.toggle'
17426
17816
  decorator: string
17817
+ offsets?: {
17818
+ anchor: BlockOffset_2
17819
+ focus: BlockOffset_2
17820
+ }
17427
17821
  }
17428
17822
  | {
17429
17823
  type: 'delete'
@@ -17568,22 +17962,26 @@ declare const editorMachine: StateMachine<
17568
17962
  mimeType: `${string}/${string}`
17569
17963
  reason: string
17570
17964
  } & {
17571
- originEvent: PickFromUnion_2<
17572
- NativeBehaviorEvent,
17573
- 'type',
17574
- 'drag.drop' | 'clipboard.paste'
17575
- >
17965
+ originEvent:
17966
+ | PickFromUnion_2<
17967
+ NativeBehaviorEvent,
17968
+ 'type',
17969
+ 'drag.drop' | 'clipboard.paste'
17970
+ >
17971
+ | InputBehaviorEvent_2
17576
17972
  })
17577
17973
  | ({
17578
17974
  type: 'deserialization.success'
17579
17975
  data: Array<PortableTextBlock>
17580
17976
  mimeType: `${string}/${string}`
17581
17977
  } & {
17582
- originEvent: PickFromUnion_2<
17583
- NativeBehaviorEvent,
17584
- 'type',
17585
- 'drag.drop' | 'clipboard.paste'
17586
- >
17978
+ originEvent:
17979
+ | PickFromUnion_2<
17980
+ NativeBehaviorEvent,
17981
+ 'type',
17982
+ 'drag.drop' | 'clipboard.paste'
17983
+ >
17984
+ | InputBehaviorEvent_2
17587
17985
  })
17588
17986
  | {
17589
17987
  type: 'serialization.success'
@@ -17672,7 +18070,7 @@ declare const editorMachine: StateMachine<
17672
18070
  value: Array<PortableTextBlock> | undefined
17673
18071
  internalDrag?: {
17674
18072
  ghost?: HTMLElement
17675
- origin: EventPosition
18073
+ origin: Pick<EventPosition, 'selection'>
17676
18074
  }
17677
18075
  },
17678
18076
  | {
@@ -17746,6 +18144,10 @@ declare const editorMachine: StateMachine<
17746
18144
  | {
17747
18145
  type: 'decorator.toggle'
17748
18146
  decorator: string
18147
+ offsets?: {
18148
+ anchor: BlockOffset_2
18149
+ focus: BlockOffset_2
18150
+ }
17749
18151
  }
17750
18152
  | {
17751
18153
  type: 'delete'
@@ -17890,22 +18292,26 @@ declare const editorMachine: StateMachine<
17890
18292
  mimeType: `${string}/${string}`
17891
18293
  reason: string
17892
18294
  } & {
17893
- originEvent: PickFromUnion_2<
17894
- NativeBehaviorEvent,
17895
- 'type',
17896
- 'drag.drop' | 'clipboard.paste'
17897
- >
18295
+ originEvent:
18296
+ | PickFromUnion_2<
18297
+ NativeBehaviorEvent,
18298
+ 'type',
18299
+ 'drag.drop' | 'clipboard.paste'
18300
+ >
18301
+ | InputBehaviorEvent_2
17898
18302
  })
17899
18303
  | ({
17900
18304
  type: 'deserialization.success'
17901
18305
  data: Array<PortableTextBlock>
17902
18306
  mimeType: `${string}/${string}`
17903
18307
  } & {
17904
- originEvent: PickFromUnion_2<
17905
- NativeBehaviorEvent,
17906
- 'type',
17907
- 'drag.drop' | 'clipboard.paste'
17908
- >
18308
+ originEvent:
18309
+ | PickFromUnion_2<
18310
+ NativeBehaviorEvent,
18311
+ 'type',
18312
+ 'drag.drop' | 'clipboard.paste'
18313
+ >
18314
+ | InputBehaviorEvent_2
17909
18315
  })
17910
18316
  | {
17911
18317
  type: 'serialization.success'
@@ -18050,7 +18456,7 @@ declare const editorMachine: StateMachine<
18050
18456
  }
18051
18457
  | {
18052
18458
  type: 'dragstart'
18053
- origin: EventPosition
18459
+ origin: Pick<EventPosition, 'selection'>
18054
18460
  ghost?: HTMLElement
18055
18461
  }
18056
18462
  | {
@@ -18122,6 +18528,10 @@ declare const editorMachine: StateMachine<
18122
18528
  | {
18123
18529
  type: 'decorator.toggle'
18124
18530
  decorator: string
18531
+ offsets?: {
18532
+ anchor: BlockOffset_2
18533
+ focus: BlockOffset_2
18534
+ }
18125
18535
  }
18126
18536
  | {
18127
18537
  type: 'delete'
@@ -18266,22 +18676,26 @@ declare const editorMachine: StateMachine<
18266
18676
  mimeType: `${string}/${string}`
18267
18677
  reason: string
18268
18678
  } & {
18269
- originEvent: PickFromUnion_2<
18270
- NativeBehaviorEvent,
18271
- 'type',
18272
- 'drag.drop' | 'clipboard.paste'
18273
- >
18679
+ originEvent:
18680
+ | PickFromUnion_2<
18681
+ NativeBehaviorEvent,
18682
+ 'type',
18683
+ 'drag.drop' | 'clipboard.paste'
18684
+ >
18685
+ | InputBehaviorEvent_2
18274
18686
  })
18275
18687
  | ({
18276
18688
  type: 'deserialization.success'
18277
18689
  data: Array<PortableTextBlock>
18278
18690
  mimeType: `${string}/${string}`
18279
18691
  } & {
18280
- originEvent: PickFromUnion_2<
18281
- NativeBehaviorEvent,
18282
- 'type',
18283
- 'drag.drop' | 'clipboard.paste'
18284
- >
18692
+ originEvent:
18693
+ | PickFromUnion_2<
18694
+ NativeBehaviorEvent,
18695
+ 'type',
18696
+ 'drag.drop' | 'clipboard.paste'
18697
+ >
18698
+ | InputBehaviorEvent_2
18285
18699
  })
18286
18700
  | {
18287
18701
  type: 'serialization.success'
@@ -18370,7 +18784,7 @@ declare const editorMachine: StateMachine<
18370
18784
  value: Array<PortableTextBlock> | undefined
18371
18785
  internalDrag?: {
18372
18786
  ghost?: HTMLElement
18373
- origin: EventPosition
18787
+ origin: Pick<EventPosition, 'selection'>
18374
18788
  }
18375
18789
  },
18376
18790
  {
@@ -18435,6 +18849,10 @@ declare const editorMachine: StateMachine<
18435
18849
  | {
18436
18850
  type: 'decorator.toggle'
18437
18851
  decorator: string
18852
+ offsets?: {
18853
+ anchor: BlockOffset_2
18854
+ focus: BlockOffset_2
18855
+ }
18438
18856
  }
18439
18857
  | {
18440
18858
  type: 'delete'
@@ -18579,22 +18997,26 @@ declare const editorMachine: StateMachine<
18579
18997
  mimeType: `${string}/${string}`
18580
18998
  reason: string
18581
18999
  } & {
18582
- originEvent: PickFromUnion_2<
18583
- NativeBehaviorEvent,
18584
- 'type',
18585
- 'drag.drop' | 'clipboard.paste'
18586
- >
19000
+ originEvent:
19001
+ | PickFromUnion_2<
19002
+ NativeBehaviorEvent,
19003
+ 'type',
19004
+ 'drag.drop' | 'clipboard.paste'
19005
+ >
19006
+ | InputBehaviorEvent_2
18587
19007
  })
18588
19008
  | ({
18589
19009
  type: 'deserialization.success'
18590
19010
  data: Array<PortableTextBlock>
18591
19011
  mimeType: `${string}/${string}`
18592
19012
  } & {
18593
- originEvent: PickFromUnion_2<
18594
- NativeBehaviorEvent,
18595
- 'type',
18596
- 'drag.drop' | 'clipboard.paste'
18597
- >
19013
+ originEvent:
19014
+ | PickFromUnion_2<
19015
+ NativeBehaviorEvent,
19016
+ 'type',
19017
+ 'drag.drop' | 'clipboard.paste'
19018
+ >
19019
+ | InputBehaviorEvent_2
18598
19020
  })
18599
19021
  | {
18600
19022
  type: 'serialization.success'
@@ -18739,7 +19161,7 @@ declare const editorMachine: StateMachine<
18739
19161
  }
18740
19162
  | {
18741
19163
  type: 'dragstart'
18742
- origin: EventPosition
19164
+ origin: Pick<EventPosition, 'selection'>
18743
19165
  ghost?: HTMLElement
18744
19166
  }
18745
19167
  | {
@@ -18811,6 +19233,10 @@ declare const editorMachine: StateMachine<
18811
19233
  | {
18812
19234
  type: 'decorator.toggle'
18813
19235
  decorator: string
19236
+ offsets?: {
19237
+ anchor: BlockOffset_2
19238
+ focus: BlockOffset_2
19239
+ }
18814
19240
  }
18815
19241
  | {
18816
19242
  type: 'delete'
@@ -18955,22 +19381,26 @@ declare const editorMachine: StateMachine<
18955
19381
  mimeType: `${string}/${string}`
18956
19382
  reason: string
18957
19383
  } & {
18958
- originEvent: PickFromUnion_2<
18959
- NativeBehaviorEvent,
18960
- 'type',
18961
- 'drag.drop' | 'clipboard.paste'
18962
- >
19384
+ originEvent:
19385
+ | PickFromUnion_2<
19386
+ NativeBehaviorEvent,
19387
+ 'type',
19388
+ 'drag.drop' | 'clipboard.paste'
19389
+ >
19390
+ | InputBehaviorEvent_2
18963
19391
  })
18964
19392
  | ({
18965
19393
  type: 'deserialization.success'
18966
19394
  data: Array<PortableTextBlock>
18967
19395
  mimeType: `${string}/${string}`
18968
19396
  } & {
18969
- originEvent: PickFromUnion_2<
18970
- NativeBehaviorEvent,
18971
- 'type',
18972
- 'drag.drop' | 'clipboard.paste'
18973
- >
19397
+ originEvent:
19398
+ | PickFromUnion_2<
19399
+ NativeBehaviorEvent,
19400
+ 'type',
19401
+ 'drag.drop' | 'clipboard.paste'
19402
+ >
19403
+ | InputBehaviorEvent_2
18974
19404
  })
18975
19405
  | {
18976
19406
  type: 'serialization.success'
@@ -19059,7 +19489,7 @@ declare const editorMachine: StateMachine<
19059
19489
  value: Array<PortableTextBlock> | undefined
19060
19490
  internalDrag?: {
19061
19491
  ghost?: HTMLElement
19062
- origin: EventPosition
19492
+ origin: Pick<EventPosition, 'selection'>
19063
19493
  }
19064
19494
  },
19065
19495
  | {
@@ -19128,6 +19558,10 @@ declare const editorMachine: StateMachine<
19128
19558
  | {
19129
19559
  type: 'decorator.toggle'
19130
19560
  decorator: string
19561
+ offsets?: {
19562
+ anchor: BlockOffset_2
19563
+ focus: BlockOffset_2
19564
+ }
19131
19565
  }
19132
19566
  | {
19133
19567
  type: 'delete'
@@ -19272,22 +19706,26 @@ declare const editorMachine: StateMachine<
19272
19706
  mimeType: `${string}/${string}`
19273
19707
  reason: string
19274
19708
  } & {
19275
- originEvent: PickFromUnion_2<
19276
- NativeBehaviorEvent,
19277
- 'type',
19278
- 'drag.drop' | 'clipboard.paste'
19279
- >
19709
+ originEvent:
19710
+ | PickFromUnion_2<
19711
+ NativeBehaviorEvent,
19712
+ 'type',
19713
+ 'drag.drop' | 'clipboard.paste'
19714
+ >
19715
+ | InputBehaviorEvent_2
19280
19716
  })
19281
19717
  | ({
19282
19718
  type: 'deserialization.success'
19283
19719
  data: Array<PortableTextBlock>
19284
19720
  mimeType: `${string}/${string}`
19285
19721
  } & {
19286
- originEvent: PickFromUnion_2<
19287
- NativeBehaviorEvent,
19288
- 'type',
19289
- 'drag.drop' | 'clipboard.paste'
19290
- >
19722
+ originEvent:
19723
+ | PickFromUnion_2<
19724
+ NativeBehaviorEvent,
19725
+ 'type',
19726
+ 'drag.drop' | 'clipboard.paste'
19727
+ >
19728
+ | InputBehaviorEvent_2
19291
19729
  })
19292
19730
  | {
19293
19731
  type: 'serialization.success'
@@ -19432,7 +19870,7 @@ declare const editorMachine: StateMachine<
19432
19870
  }
19433
19871
  | {
19434
19872
  type: 'dragstart'
19435
- origin: EventPosition
19873
+ origin: Pick<EventPosition, 'selection'>
19436
19874
  ghost?: HTMLElement
19437
19875
  }
19438
19876
  | {
@@ -19504,6 +19942,10 @@ declare const editorMachine: StateMachine<
19504
19942
  | {
19505
19943
  type: 'decorator.toggle'
19506
19944
  decorator: string
19945
+ offsets?: {
19946
+ anchor: BlockOffset_2
19947
+ focus: BlockOffset_2
19948
+ }
19507
19949
  }
19508
19950
  | {
19509
19951
  type: 'delete'
@@ -19648,22 +20090,26 @@ declare const editorMachine: StateMachine<
19648
20090
  mimeType: `${string}/${string}`
19649
20091
  reason: string
19650
20092
  } & {
19651
- originEvent: PickFromUnion_2<
19652
- NativeBehaviorEvent,
19653
- 'type',
19654
- 'drag.drop' | 'clipboard.paste'
19655
- >
20093
+ originEvent:
20094
+ | PickFromUnion_2<
20095
+ NativeBehaviorEvent,
20096
+ 'type',
20097
+ 'drag.drop' | 'clipboard.paste'
20098
+ >
20099
+ | InputBehaviorEvent_2
19656
20100
  })
19657
20101
  | ({
19658
20102
  type: 'deserialization.success'
19659
20103
  data: Array<PortableTextBlock>
19660
20104
  mimeType: `${string}/${string}`
19661
20105
  } & {
19662
- originEvent: PickFromUnion_2<
19663
- NativeBehaviorEvent,
19664
- 'type',
19665
- 'drag.drop' | 'clipboard.paste'
19666
- >
20106
+ originEvent:
20107
+ | PickFromUnion_2<
20108
+ NativeBehaviorEvent,
20109
+ 'type',
20110
+ 'drag.drop' | 'clipboard.paste'
20111
+ >
20112
+ | InputBehaviorEvent_2
19667
20113
  })
19668
20114
  | {
19669
20115
  type: 'serialization.success'
@@ -19752,7 +20198,7 @@ declare const editorMachine: StateMachine<
19752
20198
  value: Array<PortableTextBlock> | undefined
19753
20199
  internalDrag?: {
19754
20200
  ghost?: HTMLElement
19755
- origin: EventPosition
20201
+ origin: Pick<EventPosition, 'selection'>
19756
20202
  }
19757
20203
  },
19758
20204
  | {
@@ -19825,6 +20271,10 @@ declare const editorMachine: StateMachine<
19825
20271
  | {
19826
20272
  type: 'decorator.toggle'
19827
20273
  decorator: string
20274
+ offsets?: {
20275
+ anchor: BlockOffset_2
20276
+ focus: BlockOffset_2
20277
+ }
19828
20278
  }
19829
20279
  | {
19830
20280
  type: 'delete'
@@ -19969,22 +20419,26 @@ declare const editorMachine: StateMachine<
19969
20419
  mimeType: `${string}/${string}`
19970
20420
  reason: string
19971
20421
  } & {
19972
- originEvent: PickFromUnion_2<
19973
- NativeBehaviorEvent,
19974
- 'type',
19975
- 'drag.drop' | 'clipboard.paste'
19976
- >
20422
+ originEvent:
20423
+ | PickFromUnion_2<
20424
+ NativeBehaviorEvent,
20425
+ 'type',
20426
+ 'drag.drop' | 'clipboard.paste'
20427
+ >
20428
+ | InputBehaviorEvent_2
19977
20429
  })
19978
20430
  | ({
19979
20431
  type: 'deserialization.success'
19980
20432
  data: Array<PortableTextBlock>
19981
20433
  mimeType: `${string}/${string}`
19982
20434
  } & {
19983
- originEvent: PickFromUnion_2<
19984
- NativeBehaviorEvent,
19985
- 'type',
19986
- 'drag.drop' | 'clipboard.paste'
19987
- >
20435
+ originEvent:
20436
+ | PickFromUnion_2<
20437
+ NativeBehaviorEvent,
20438
+ 'type',
20439
+ 'drag.drop' | 'clipboard.paste'
20440
+ >
20441
+ | InputBehaviorEvent_2
19988
20442
  })
19989
20443
  | {
19990
20444
  type: 'serialization.success'
@@ -20129,7 +20583,7 @@ declare const editorMachine: StateMachine<
20129
20583
  }
20130
20584
  | {
20131
20585
  type: 'dragstart'
20132
- origin: EventPosition
20586
+ origin: Pick<EventPosition, 'selection'>
20133
20587
  ghost?: HTMLElement
20134
20588
  }
20135
20589
  | {
@@ -20201,6 +20655,10 @@ declare const editorMachine: StateMachine<
20201
20655
  | {
20202
20656
  type: 'decorator.toggle'
20203
20657
  decorator: string
20658
+ offsets?: {
20659
+ anchor: BlockOffset_2
20660
+ focus: BlockOffset_2
20661
+ }
20204
20662
  }
20205
20663
  | {
20206
20664
  type: 'delete'
@@ -20345,22 +20803,26 @@ declare const editorMachine: StateMachine<
20345
20803
  mimeType: `${string}/${string}`
20346
20804
  reason: string
20347
20805
  } & {
20348
- originEvent: PickFromUnion_2<
20349
- NativeBehaviorEvent,
20350
- 'type',
20351
- 'drag.drop' | 'clipboard.paste'
20352
- >
20806
+ originEvent:
20807
+ | PickFromUnion_2<
20808
+ NativeBehaviorEvent,
20809
+ 'type',
20810
+ 'drag.drop' | 'clipboard.paste'
20811
+ >
20812
+ | InputBehaviorEvent_2
20353
20813
  })
20354
20814
  | ({
20355
20815
  type: 'deserialization.success'
20356
20816
  data: Array<PortableTextBlock>
20357
20817
  mimeType: `${string}/${string}`
20358
20818
  } & {
20359
- originEvent: PickFromUnion_2<
20360
- NativeBehaviorEvent,
20361
- 'type',
20362
- 'drag.drop' | 'clipboard.paste'
20363
- >
20819
+ originEvent:
20820
+ | PickFromUnion_2<
20821
+ NativeBehaviorEvent,
20822
+ 'type',
20823
+ 'drag.drop' | 'clipboard.paste'
20824
+ >
20825
+ | InputBehaviorEvent_2
20364
20826
  })
20365
20827
  | {
20366
20828
  type: 'serialization.success'
@@ -20470,12 +20932,12 @@ declare const editorMachine: StateMachine<
20470
20932
  value: Array<PortableTextBlock> | undefined
20471
20933
  internalDrag?: {
20472
20934
  ghost?: HTMLElement
20473
- origin: EventPosition
20935
+ origin: Pick<EventPosition, 'selection'>
20474
20936
  }
20475
20937
  },
20476
20938
  {
20477
20939
  type: 'dragstart'
20478
- origin: EventPosition
20940
+ origin: Pick<EventPosition, 'selection'>
20479
20941
  ghost?: HTMLElement
20480
20942
  },
20481
20943
  | {
@@ -20536,6 +20998,10 @@ declare const editorMachine: StateMachine<
20536
20998
  | {
20537
20999
  type: 'decorator.toggle'
20538
21000
  decorator: string
21001
+ offsets?: {
21002
+ anchor: BlockOffset_2
21003
+ focus: BlockOffset_2
21004
+ }
20539
21005
  }
20540
21006
  | {
20541
21007
  type: 'delete'
@@ -20680,22 +21146,26 @@ declare const editorMachine: StateMachine<
20680
21146
  mimeType: `${string}/${string}`
20681
21147
  reason: string
20682
21148
  } & {
20683
- originEvent: PickFromUnion_2<
20684
- NativeBehaviorEvent,
20685
- 'type',
20686
- 'drag.drop' | 'clipboard.paste'
20687
- >
21149
+ originEvent:
21150
+ | PickFromUnion_2<
21151
+ NativeBehaviorEvent,
21152
+ 'type',
21153
+ 'drag.drop' | 'clipboard.paste'
21154
+ >
21155
+ | InputBehaviorEvent_2
20688
21156
  })
20689
21157
  | ({
20690
21158
  type: 'deserialization.success'
20691
21159
  data: Array<PortableTextBlock>
20692
21160
  mimeType: `${string}/${string}`
20693
21161
  } & {
20694
- originEvent: PickFromUnion_2<
20695
- NativeBehaviorEvent,
20696
- 'type',
20697
- 'drag.drop' | 'clipboard.paste'
20698
- >
21162
+ originEvent:
21163
+ | PickFromUnion_2<
21164
+ NativeBehaviorEvent,
21165
+ 'type',
21166
+ 'drag.drop' | 'clipboard.paste'
21167
+ >
21168
+ | InputBehaviorEvent_2
20699
21169
  })
20700
21170
  | {
20701
21171
  type: 'serialization.success'
@@ -20844,7 +21314,7 @@ declare const editorMachine: StateMachine<
20844
21314
  }
20845
21315
  | {
20846
21316
  type: 'dragstart'
20847
- origin: EventPosition
21317
+ origin: Pick<EventPosition, 'selection'>
20848
21318
  ghost?: HTMLElement
20849
21319
  }
20850
21320
  | {
@@ -20882,7 +21352,7 @@ declare const editorMachine: StateMachine<
20882
21352
  value: Array<PortableTextBlock> | undefined
20883
21353
  internalDrag?: {
20884
21354
  ghost?: HTMLElement
20885
- origin: EventPosition
21355
+ origin: Pick<EventPosition, 'selection'>
20886
21356
  }
20887
21357
  },
20888
21358
  | {
@@ -20943,6 +21413,10 @@ declare const editorMachine: StateMachine<
20943
21413
  | {
20944
21414
  type: 'decorator.toggle'
20945
21415
  decorator: string
21416
+ offsets?: {
21417
+ anchor: BlockOffset_2
21418
+ focus: BlockOffset_2
21419
+ }
20946
21420
  }
20947
21421
  | {
20948
21422
  type: 'delete'
@@ -21087,22 +21561,26 @@ declare const editorMachine: StateMachine<
21087
21561
  mimeType: `${string}/${string}`
21088
21562
  reason: string
21089
21563
  } & {
21090
- originEvent: PickFromUnion_2<
21091
- NativeBehaviorEvent,
21092
- 'type',
21093
- 'drag.drop' | 'clipboard.paste'
21094
- >
21564
+ originEvent:
21565
+ | PickFromUnion_2<
21566
+ NativeBehaviorEvent,
21567
+ 'type',
21568
+ 'drag.drop' | 'clipboard.paste'
21569
+ >
21570
+ | InputBehaviorEvent_2
21095
21571
  })
21096
21572
  | ({
21097
21573
  type: 'deserialization.success'
21098
21574
  data: Array<PortableTextBlock>
21099
21575
  mimeType: `${string}/${string}`
21100
21576
  } & {
21101
- originEvent: PickFromUnion_2<
21102
- NativeBehaviorEvent,
21103
- 'type',
21104
- 'drag.drop' | 'clipboard.paste'
21105
- >
21577
+ originEvent:
21578
+ | PickFromUnion_2<
21579
+ NativeBehaviorEvent,
21580
+ 'type',
21581
+ 'drag.drop' | 'clipboard.paste'
21582
+ >
21583
+ | InputBehaviorEvent_2
21106
21584
  })
21107
21585
  | {
21108
21586
  type: 'serialization.success'
@@ -21247,7 +21725,7 @@ declare const editorMachine: StateMachine<
21247
21725
  }
21248
21726
  | {
21249
21727
  type: 'dragstart'
21250
- origin: EventPosition
21728
+ origin: Pick<EventPosition, 'selection'>
21251
21729
  ghost?: HTMLElement
21252
21730
  }
21253
21731
  | {
@@ -21314,6 +21792,10 @@ declare const editorMachine: StateMachine<
21314
21792
  | {
21315
21793
  type: 'decorator.toggle'
21316
21794
  decorator: string
21795
+ offsets?: {
21796
+ anchor: BlockOffset_2
21797
+ focus: BlockOffset_2
21798
+ }
21317
21799
  }
21318
21800
  | {
21319
21801
  type: 'delete'
@@ -21458,22 +21940,26 @@ declare const editorMachine: StateMachine<
21458
21940
  mimeType: `${string}/${string}`
21459
21941
  reason: string
21460
21942
  } & {
21461
- originEvent: PickFromUnion_2<
21462
- NativeBehaviorEvent,
21463
- 'type',
21464
- 'drag.drop' | 'clipboard.paste'
21465
- >
21943
+ originEvent:
21944
+ | PickFromUnion_2<
21945
+ NativeBehaviorEvent,
21946
+ 'type',
21947
+ 'drag.drop' | 'clipboard.paste'
21948
+ >
21949
+ | InputBehaviorEvent_2
21466
21950
  })
21467
21951
  | ({
21468
21952
  type: 'deserialization.success'
21469
21953
  data: Array<PortableTextBlock>
21470
21954
  mimeType: `${string}/${string}`
21471
21955
  } & {
21472
- originEvent: PickFromUnion_2<
21473
- NativeBehaviorEvent,
21474
- 'type',
21475
- 'drag.drop' | 'clipboard.paste'
21476
- >
21956
+ originEvent:
21957
+ | PickFromUnion_2<
21958
+ NativeBehaviorEvent,
21959
+ 'type',
21960
+ 'drag.drop' | 'clipboard.paste'
21961
+ >
21962
+ | InputBehaviorEvent_2
21477
21963
  })
21478
21964
  | {
21479
21965
  type: 'serialization.success'
@@ -21618,7 +22104,7 @@ declare const editorMachine: StateMachine<
21618
22104
  }
21619
22105
  | {
21620
22106
  type: 'dragstart'
21621
- origin: EventPosition
22107
+ origin: Pick<EventPosition, 'selection'>
21622
22108
  ghost?: HTMLElement
21623
22109
  }
21624
22110
  | {
@@ -21641,7 +22127,7 @@ declare const editorMachine: StateMachine<
21641
22127
  value: Array<PortableTextBlock> | undefined
21642
22128
  internalDrag?: {
21643
22129
  ghost?: HTMLElement
21644
- origin: EventPosition
22130
+ origin: Pick<EventPosition, 'selection'>
21645
22131
  }
21646
22132
  },
21647
22133
  | {
@@ -21702,6 +22188,10 @@ declare const editorMachine: StateMachine<
21702
22188
  | {
21703
22189
  type: 'decorator.toggle'
21704
22190
  decorator: string
22191
+ offsets?: {
22192
+ anchor: BlockOffset_2
22193
+ focus: BlockOffset_2
22194
+ }
21705
22195
  }
21706
22196
  | {
21707
22197
  type: 'delete'
@@ -21846,22 +22336,26 @@ declare const editorMachine: StateMachine<
21846
22336
  mimeType: `${string}/${string}`
21847
22337
  reason: string
21848
22338
  } & {
21849
- originEvent: PickFromUnion_2<
21850
- NativeBehaviorEvent,
21851
- 'type',
21852
- 'drag.drop' | 'clipboard.paste'
21853
- >
22339
+ originEvent:
22340
+ | PickFromUnion_2<
22341
+ NativeBehaviorEvent,
22342
+ 'type',
22343
+ 'drag.drop' | 'clipboard.paste'
22344
+ >
22345
+ | InputBehaviorEvent_2
21854
22346
  })
21855
22347
  | ({
21856
22348
  type: 'deserialization.success'
21857
22349
  data: Array<PortableTextBlock>
21858
22350
  mimeType: `${string}/${string}`
21859
22351
  } & {
21860
- originEvent: PickFromUnion_2<
21861
- NativeBehaviorEvent,
21862
- 'type',
21863
- 'drag.drop' | 'clipboard.paste'
21864
- >
22352
+ originEvent:
22353
+ | PickFromUnion_2<
22354
+ NativeBehaviorEvent,
22355
+ 'type',
22356
+ 'drag.drop' | 'clipboard.paste'
22357
+ >
22358
+ | InputBehaviorEvent_2
21865
22359
  })
21866
22360
  | {
21867
22361
  type: 'serialization.success'
@@ -22006,7 +22500,7 @@ declare const editorMachine: StateMachine<
22006
22500
  }
22007
22501
  | {
22008
22502
  type: 'dragstart'
22009
- origin: EventPosition
22503
+ origin: Pick<EventPosition, 'selection'>
22010
22504
  ghost?: HTMLElement
22011
22505
  }
22012
22506
  | {
@@ -22073,6 +22567,10 @@ declare const editorMachine: StateMachine<
22073
22567
  | {
22074
22568
  type: 'decorator.toggle'
22075
22569
  decorator: string
22570
+ offsets?: {
22571
+ anchor: BlockOffset_2
22572
+ focus: BlockOffset_2
22573
+ }
22076
22574
  }
22077
22575
  | {
22078
22576
  type: 'delete'
@@ -22217,22 +22715,26 @@ declare const editorMachine: StateMachine<
22217
22715
  mimeType: `${string}/${string}`
22218
22716
  reason: string
22219
22717
  } & {
22220
- originEvent: PickFromUnion_2<
22221
- NativeBehaviorEvent,
22222
- 'type',
22223
- 'drag.drop' | 'clipboard.paste'
22224
- >
22718
+ originEvent:
22719
+ | PickFromUnion_2<
22720
+ NativeBehaviorEvent,
22721
+ 'type',
22722
+ 'drag.drop' | 'clipboard.paste'
22723
+ >
22724
+ | InputBehaviorEvent_2
22225
22725
  })
22226
22726
  | ({
22227
22727
  type: 'deserialization.success'
22228
22728
  data: Array<PortableTextBlock>
22229
22729
  mimeType: `${string}/${string}`
22230
22730
  } & {
22231
- originEvent: PickFromUnion_2<
22232
- NativeBehaviorEvent,
22233
- 'type',
22234
- 'drag.drop' | 'clipboard.paste'
22235
- >
22731
+ originEvent:
22732
+ | PickFromUnion_2<
22733
+ NativeBehaviorEvent,
22734
+ 'type',
22735
+ 'drag.drop' | 'clipboard.paste'
22736
+ >
22737
+ | InputBehaviorEvent_2
22236
22738
  })
22237
22739
  | {
22238
22740
  type: 'serialization.success'
@@ -22377,7 +22879,7 @@ declare const editorMachine: StateMachine<
22377
22879
  }
22378
22880
  | {
22379
22881
  type: 'dragstart'
22380
- origin: EventPosition
22882
+ origin: Pick<EventPosition, 'selection'>
22381
22883
  ghost?: HTMLElement
22382
22884
  }
22383
22885
  | {
@@ -22514,7 +23016,7 @@ declare type EditorSnapshot = {
22514
23016
  hasTag: HasTag
22515
23017
  internalDrag:
22516
23018
  | {
22517
- origin: EventPosition
23019
+ origin: Pick<EventPosition, 'selection'>
22518
23020
  }
22519
23021
  | undefined
22520
23022
  }
@@ -22854,6 +23356,24 @@ declare type HistoryItem = {
22854
23356
  timestamp: Date
22855
23357
  }
22856
23358
 
23359
+ /**
23360
+ * Used to represent native InputEvents that hold a DataTransfer object.
23361
+ *
23362
+ * These can either be one of:
23363
+ *
23364
+ * - insertFromPaste
23365
+ * - insertFromPasteAsQuotation
23366
+ * - insertFromDrop
23367
+ * - insertReplacementText
23368
+ * - insertFromYank
23369
+ */
23370
+ declare type InputBehaviorEvent = {
23371
+ type: 'input.*'
23372
+ originEvent: {
23373
+ dataTransfer: DataTransfer
23374
+ }
23375
+ }
23376
+
22857
23377
  declare type InsertPlacement = 'auto' | 'after' | 'before'
22858
23378
 
22859
23379
  declare type InternalPatchEvent = NamespaceEvent<PatchEvent, 'internal'> & {
@@ -23016,9 +23536,10 @@ declare type NamespaceEvent<
23016
23536
  */
23017
23537
  declare type NativeBehaviorEvent =
23018
23538
  | ClipboardBehaviorEvent
23539
+ | DragBehaviorEvent
23540
+ | InputBehaviorEvent
23019
23541
  | KeyboardBehaviorEvent
23020
23542
  | MouseBehaviorEvent
23021
- | DragBehaviorEvent
23022
23543
 
23023
23544
  /**
23024
23545
  * @public
@@ -23165,6 +23686,10 @@ declare type SyntheticBehaviorEvent =
23165
23686
  | {
23166
23687
  type: 'decorator.toggle'
23167
23688
  decorator: string
23689
+ offsets?: {
23690
+ anchor: BlockOffset
23691
+ focus: BlockOffset
23692
+ }
23168
23693
  }
23169
23694
  | {
23170
23695
  type: 'delete'
@@ -23309,11 +23834,13 @@ declare type SyntheticBehaviorEvent =
23309
23834
  'type',
23310
23835
  'deserialization.failure' | 'deserialization.success'
23311
23836
  > & {
23312
- originEvent: PickFromUnion<
23313
- NativeBehaviorEvent,
23314
- 'type',
23315
- 'drag.drop' | 'clipboard.paste'
23316
- >
23837
+ originEvent:
23838
+ | PickFromUnion<
23839
+ NativeBehaviorEvent,
23840
+ 'type',
23841
+ 'drag.drop' | 'clipboard.paste'
23842
+ >
23843
+ | InputBehaviorEvent
23317
23844
  })
23318
23845
  | {
23319
23846
  type: 'serialization.success'