@portabletext/editor 2.21.2 → 3.0.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 (79) hide show
  1. package/lib/_chunks-dts/index.d.ts +50 -210
  2. package/lib/_chunks-es/selector.is-at-the-start-of-block.js +103 -20
  3. package/lib/_chunks-es/selector.is-at-the-start-of-block.js.map +1 -1
  4. package/lib/_chunks-es/{util.get-text-block-text.js → util.slice-blocks.js} +29 -5
  5. package/lib/_chunks-es/util.slice-blocks.js.map +1 -0
  6. package/lib/_chunks-es/util.slice-text-block.js +13 -2
  7. package/lib/_chunks-es/util.slice-text-block.js.map +1 -1
  8. package/lib/behaviors/index.d.ts +1 -1
  9. package/lib/index.d.ts +2 -2
  10. package/lib/index.js +323 -320
  11. package/lib/index.js.map +1 -1
  12. package/lib/plugins/index.d.ts +2 -133
  13. package/lib/plugins/index.js +2 -796
  14. package/lib/plugins/index.js.map +1 -1
  15. package/lib/selectors/index.d.ts +2 -24
  16. package/lib/selectors/index.js +28 -130
  17. package/lib/selectors/index.js.map +1 -1
  18. package/lib/utils/index.d.ts +3 -3
  19. package/lib/utils/index.js +97 -9
  20. package/lib/utils/index.js.map +1 -1
  21. package/package.json +7 -9
  22. package/src/behaviors/behavior.perform-event.ts +7 -7
  23. package/src/editor/PortableTextEditor.tsx +0 -19
  24. package/src/editor/create-editor.ts +0 -3
  25. package/src/editor/editor-machine.ts +0 -10
  26. package/src/editor/event-to-change.tsx +5 -1
  27. package/src/editor/plugins/create-with-event-listeners.ts +0 -4
  28. package/src/editor/plugins/createWithObjectKeys.ts +2 -1
  29. package/src/editor/plugins/createWithPatches.ts +3 -3
  30. package/src/editor/plugins/createWithPlaceholderBlock.ts +2 -1
  31. package/src/editor/plugins/createWithPortableTextMarkModel.ts +2 -1
  32. package/src/editor/plugins/with-plugins.ts +10 -14
  33. package/src/editor/relay-machine.ts +0 -4
  34. package/src/editor/sync-machine.ts +2 -2
  35. package/src/editor.ts +0 -4
  36. package/src/history/behavior.operation.history.redo.ts +67 -0
  37. package/src/history/behavior.operation.history.undo.ts +71 -0
  38. package/src/history/event.history.undo.test.tsx +672 -0
  39. package/src/history/history.preserving-keys.test.tsx +112 -0
  40. package/src/history/remote-patches.ts +20 -0
  41. package/src/history/slate-plugin.history.ts +146 -0
  42. package/src/history/slate-plugin.redoing.ts +21 -0
  43. package/src/history/slate-plugin.undoing.ts +21 -0
  44. package/src/history/slate-plugin.without-history.ts +23 -0
  45. package/src/history/transform-operation.ts +245 -0
  46. package/src/history/undo-redo-collaboration.test.tsx +541 -0
  47. package/src/history/undo-redo.feature +125 -0
  48. package/src/history/undo-redo.test.tsx +195 -0
  49. package/src/history/undo-step.ts +148 -0
  50. package/src/index.ts +0 -1
  51. package/src/internal-utils/applyPatch.ts +46 -1
  52. package/src/operations/behavior.operations.ts +2 -4
  53. package/src/plugins/index.ts +0 -3
  54. package/src/selectors/index.ts +0 -3
  55. package/src/test/vitest/step-definitions.tsx +88 -8
  56. package/src/test/vitest/test-editor.tsx +1 -1
  57. package/lib/_chunks-es/selector.get-selection-text.js +0 -92
  58. package/lib/_chunks-es/selector.get-selection-text.js.map +0 -1
  59. package/lib/_chunks-es/selector.get-text-before.js +0 -36
  60. package/lib/_chunks-es/selector.get-text-before.js.map +0 -1
  61. package/lib/_chunks-es/util.get-text-block-text.js.map +0 -1
  62. package/lib/_chunks-es/util.is-empty-text-block.js +0 -40
  63. package/lib/_chunks-es/util.is-empty-text-block.js.map +0 -1
  64. package/lib/_chunks-es/util.merge-text-blocks.js +0 -101
  65. package/lib/_chunks-es/util.merge-text-blocks.js.map +0 -1
  66. package/src/editor/plugins/createWithMaxBlocks.ts +0 -53
  67. package/src/editor/plugins/createWithUndoRedo.ts +0 -628
  68. package/src/editor/with-undo-step.ts +0 -37
  69. package/src/editor/withUndoRedo.ts +0 -34
  70. package/src/editor-event-listener.tsx +0 -28
  71. package/src/plugins/plugin.decorator-shortcut.ts +0 -238
  72. package/src/plugins/plugin.markdown.test.tsx +0 -42
  73. package/src/plugins/plugin.markdown.tsx +0 -131
  74. package/src/plugins/plugin.one-line.tsx +0 -123
  75. package/src/selectors/selector.get-list-state.test.ts +0 -189
  76. package/src/selectors/selector.get-list-state.ts +0 -96
  77. package/src/selectors/selector.get-selected-slice.ts +0 -13
  78. package/src/selectors/selector.get-trimmed-selection.test.ts +0 -657
  79. package/src/selectors/selector.get-trimmed-selection.ts +0 -189
@@ -1,9 +1,9 @@
1
- import * as _sanity_types5 from "@sanity/types";
1
+ import * as _sanity_types4 from "@sanity/types";
2
2
  import { ArrayDefinition, ArraySchemaType, BlockDecoratorDefinition, BlockListDefinition, BlockStyleDefinition, ObjectSchemaType, Path, PortableTextBlock, PortableTextBlock as PortableTextBlock$1, PortableTextChild, PortableTextChild as PortableTextChild$1, PortableTextListBlock, PortableTextObject, PortableTextObject as PortableTextObject$2, PortableTextSpan, PortableTextSpan as PortableTextSpan$2, PortableTextTextBlock, PortableTextTextBlock as PortableTextTextBlock$2, TypedObject } from "@sanity/types";
3
3
  import { BaseRange, Descendant, Operation } from "slate";
4
- import * as xstate229 from "xstate";
4
+ import * as xstate228 from "xstate";
5
5
  import { ActorRef, ActorRefFrom, EventObject, Snapshot } from "xstate";
6
- import * as react20 from "react";
6
+ import * as react18 from "react";
7
7
  import React$1, { BaseSyntheticEvent, ClipboardEvent, Component, FocusEvent, JSX, KeyboardEvent as KeyboardEvent$1, MutableRefObject, PropsWithChildren, ReactElement, RefObject, TextareaHTMLAttributes } from "react";
8
8
  import { Patch, Patch as Patch$1 } from "@portabletext/patches";
9
9
  import * as _portabletext_schema5 from "@portabletext/schema";
@@ -116,10 +116,6 @@ type ErrorEvent = {
116
116
  type MutationEvent = {
117
117
  type: 'mutation';
118
118
  patches: Array<Patch>;
119
- /**
120
- * @deprecated Use `value` instead
121
- */
122
- snapshot: Array<PortableTextBlock> | undefined;
123
119
  value: Array<PortableTextBlock> | undefined;
124
120
  };
125
121
  type PatchEvent = {
@@ -162,10 +158,6 @@ type PortableTextEditorProps<TEditor extends InternalEditor | undefined = undefi
162
158
  * Schema type for the portable text field
163
159
  */
164
160
  schemaType: ArraySchemaType<PortableTextBlock> | ArrayDefinition;
165
- /**
166
- * Maximum number of blocks to allow within the editor
167
- */
168
- maxBlocks?: number | string;
169
161
  /**
170
162
  * Function used to generate keys for array items (`_key`)
171
163
  */
@@ -219,7 +211,7 @@ declare class PortableTextEditor extends Component<PortableTextEditorProps<Inter
219
211
  componentDidUpdate(prevProps: PortableTextEditorProps): void;
220
212
  componentWillUnmount(): void;
221
213
  setEditable: (editable: EditableAPI) => void;
222
- render(): react20.JSX.Element;
214
+ render(): react18.JSX.Element;
223
215
  /**
224
216
  * @deprecated
225
217
  * Use built-in selectors or write your own: https://www.portabletext.org/reference/selectors/
@@ -276,7 +268,7 @@ declare class PortableTextEditor extends Component<PortableTextEditorProps<Inter
276
268
  static blur: (editor: PortableTextEditor) => void;
277
269
  static delete: (editor: PortableTextEditor, selection: EditorSelection, options?: EditableAPIDeleteOptions) => void;
278
270
  static findDOMNode: (editor: PortableTextEditor, element: PortableTextBlock | PortableTextChild) => Node | undefined;
279
- static findByPath: (editor: PortableTextEditor, path: Path) => [_sanity_types5.PortableTextTextBlock<PortableTextObject | _sanity_types5.PortableTextSpan> | PortableTextObject | _sanity_types5.PortableTextSpan | undefined, Path | undefined];
271
+ static findByPath: (editor: PortableTextEditor, path: Path) => [_sanity_types4.PortableTextTextBlock<PortableTextObject | _sanity_types4.PortableTextSpan> | PortableTextObject | _sanity_types4.PortableTextSpan | undefined, Path | undefined];
280
272
  /**
281
273
  * @deprecated
282
274
  * Use `editor.send(...)` instead
@@ -614,7 +606,7 @@ type PortableTextEditableProps = Omit<TextareaHTMLAttributes<HTMLDivElement>, 'o
614
606
  * ```
615
607
  * @group Components
616
608
  */
617
- declare const PortableTextEditable: react20.ForwardRefExoticComponent<Omit<PortableTextEditableProps, "ref"> & react20.RefAttributes<Omit<HTMLDivElement, "as" | "onPaste" | "onBeforeInput">>>;
609
+ declare const PortableTextEditable: react18.ForwardRefExoticComponent<Omit<PortableTextEditableProps, "ref"> & react18.RefAttributes<Omit<HTMLDivElement, "as" | "onPaste" | "onBeforeInput">>>;
618
610
  type DecoratedRange = BaseRange & {
619
611
  rangeDecoration: RangeDecoration;
620
612
  };
@@ -1167,10 +1159,6 @@ type EditorConfig = {
1167
1159
  * @beta
1168
1160
  */
1169
1161
  keyGenerator?: () => string;
1170
- /**
1171
- * @deprecated Will be removed in the next major version
1172
- */
1173
- maxBlocks?: number;
1174
1162
  readOnly?: boolean;
1175
1163
  initialValue?: Array<PortableTextBlock>;
1176
1164
  } & ({
@@ -1202,18 +1190,6 @@ type Editor = {
1202
1190
  send: (event: EditorEvent) => void;
1203
1191
  on: ActorRef<Snapshot<unknown>, EventObject, EditorEmittedEvent>['on'];
1204
1192
  };
1205
- /**
1206
- * @public
1207
- * @deprecated
1208
- * This component has been renamed. Use `EventListenerPlugin` instead.
1209
- *
1210
- * ```
1211
- * import {EventListenerPlugin} from '@portabletext/editor/plugins'
1212
- * ```
1213
- */
1214
- declare function EditorEventListener(props: {
1215
- on: (event: EditorEmittedEvent) => void;
1216
- }): null;
1217
1193
  /**
1218
1194
  * @public
1219
1195
  */
@@ -1345,9 +1321,6 @@ type PatchesEvent = {
1345
1321
  type ExternalEditorEvent = {
1346
1322
  type: 'update readOnly';
1347
1323
  readOnly: boolean;
1348
- } | {
1349
- type: 'update maxBlocks';
1350
- maxBlocks: number | undefined;
1351
1324
  } | PatchesEvent;
1352
1325
  type InternalPatchEvent = NamespaceEvent<PatchEvent, 'internal'> & {
1353
1326
  operationId?: string;
@@ -1360,7 +1333,7 @@ type EditorActor = ActorRefFrom<typeof editorMachine>;
1360
1333
  /**
1361
1334
  * @internal
1362
1335
  */
1363
- declare const editorMachine: xstate229.StateMachine<{
1336
+ declare const editorMachine: xstate228.StateMachine<{
1364
1337
  behaviors: Set<BehaviorConfig>;
1365
1338
  behaviorsSorted: boolean;
1366
1339
  converters: Set<Converter>;
@@ -1370,7 +1343,6 @@ declare const editorMachine: xstate229.StateMachine<{
1370
1343
  pendingIncomingPatchesEvents: Array<PatchesEvent>;
1371
1344
  schema: EditorSchema;
1372
1345
  initialReadOnly: boolean;
1373
- maxBlocks: number | undefined;
1374
1346
  selection: EditorSelection;
1375
1347
  initialValue: Array<PortableTextBlock> | undefined;
1376
1348
  internalDrag?: {
@@ -1381,9 +1353,6 @@ declare const editorMachine: xstate229.StateMachine<{
1381
1353
  }, InternalPatchEvent | MutationEvent | PatchesEvent | {
1382
1354
  type: "update readOnly";
1383
1355
  readOnly: boolean;
1384
- } | {
1385
- type: "update maxBlocks";
1386
- maxBlocks: number | undefined;
1387
1356
  } | {
1388
1357
  type: "add behavior";
1389
1358
  behaviorConfig: BehaviorConfig;
@@ -1424,62 +1393,62 @@ declare const editorMachine: xstate229.StateMachine<{
1424
1393
  } | {
1425
1394
  type: "add slate editor";
1426
1395
  editor: PortableTextSlateEditor;
1427
- }, {}, never, xstate229.Values<{
1396
+ }, {}, never, xstate228.Values<{
1428
1397
  "add behavior to context": {
1429
1398
  type: "add behavior to context";
1430
- params: xstate229.NonReducibleUnknown;
1399
+ params: xstate228.NonReducibleUnknown;
1431
1400
  };
1432
1401
  "remove behavior from context": {
1433
1402
  type: "remove behavior from context";
1434
- params: xstate229.NonReducibleUnknown;
1403
+ params: xstate228.NonReducibleUnknown;
1435
1404
  };
1436
1405
  "add slate editor to context": {
1437
1406
  type: "add slate editor to context";
1438
- params: xstate229.NonReducibleUnknown;
1407
+ params: xstate228.NonReducibleUnknown;
1439
1408
  };
1440
1409
  "emit patch event": {
1441
1410
  type: "emit patch event";
1442
- params: xstate229.NonReducibleUnknown;
1411
+ params: xstate228.NonReducibleUnknown;
1443
1412
  };
1444
1413
  "emit mutation event": {
1445
1414
  type: "emit mutation event";
1446
- params: xstate229.NonReducibleUnknown;
1415
+ params: xstate228.NonReducibleUnknown;
1447
1416
  };
1448
1417
  "emit read only": {
1449
1418
  type: "emit read only";
1450
- params: xstate229.NonReducibleUnknown;
1419
+ params: xstate228.NonReducibleUnknown;
1451
1420
  };
1452
1421
  "emit editable": {
1453
1422
  type: "emit editable";
1454
- params: xstate229.NonReducibleUnknown;
1423
+ params: xstate228.NonReducibleUnknown;
1455
1424
  };
1456
1425
  "defer event": {
1457
1426
  type: "defer event";
1458
- params: xstate229.NonReducibleUnknown;
1427
+ params: xstate228.NonReducibleUnknown;
1459
1428
  };
1460
1429
  "emit pending events": {
1461
1430
  type: "emit pending events";
1462
- params: xstate229.NonReducibleUnknown;
1431
+ params: xstate228.NonReducibleUnknown;
1463
1432
  };
1464
1433
  "emit ready": {
1465
1434
  type: "emit ready";
1466
- params: xstate229.NonReducibleUnknown;
1435
+ params: xstate228.NonReducibleUnknown;
1467
1436
  };
1468
1437
  "clear pending events": {
1469
1438
  type: "clear pending events";
1470
- params: xstate229.NonReducibleUnknown;
1439
+ params: xstate228.NonReducibleUnknown;
1471
1440
  };
1472
1441
  "defer incoming patches": {
1473
1442
  type: "defer incoming patches";
1474
- params: xstate229.NonReducibleUnknown;
1443
+ params: xstate228.NonReducibleUnknown;
1475
1444
  };
1476
1445
  "emit pending incoming patches": {
1477
1446
  type: "emit pending incoming patches";
1478
- params: xstate229.NonReducibleUnknown;
1447
+ params: xstate228.NonReducibleUnknown;
1479
1448
  };
1480
1449
  "clear pending incoming patches": {
1481
1450
  type: "clear pending incoming patches";
1482
- params: xstate229.NonReducibleUnknown;
1451
+ params: xstate228.NonReducibleUnknown;
1483
1452
  };
1484
1453
  "handle blur": {
1485
1454
  type: "handle blur";
@@ -1495,9 +1464,9 @@ declare const editorMachine: xstate229.StateMachine<{
1495
1464
  };
1496
1465
  "sort behaviors": {
1497
1466
  type: "sort behaviors";
1498
- params: xstate229.NonReducibleUnknown;
1467
+ params: xstate228.NonReducibleUnknown;
1499
1468
  };
1500
- }>, xstate229.Values<{
1469
+ }>, xstate228.Values<{
1501
1470
  "slate is busy": {
1502
1471
  type: "slate is busy";
1503
1472
  params: unknown;
@@ -1526,13 +1495,12 @@ declare const editorMachine: xstate229.StateMachine<{
1526
1495
  converters?: Array<Converter>;
1527
1496
  getLegacySchema: () => PortableTextMemberSchemaTypes;
1528
1497
  keyGenerator: () => string;
1529
- maxBlocks?: number;
1530
1498
  readOnly?: boolean;
1531
1499
  schema: EditorSchema;
1532
1500
  initialValue?: Array<PortableTextBlock>;
1533
- }, xstate229.NonReducibleUnknown, InternalPatchEvent | MutationEvent | PatchesEvent | {
1501
+ }, xstate228.NonReducibleUnknown, InternalPatchEvent | MutationEvent | PatchesEvent | {
1534
1502
  type: "blurred";
1535
- event: react20.FocusEvent<HTMLDivElement, Element>;
1503
+ event: react18.FocusEvent<HTMLDivElement, Element>;
1536
1504
  } | {
1537
1505
  type: "done loading";
1538
1506
  } | {
@@ -1544,7 +1512,7 @@ declare const editorMachine: xstate229.StateMachine<{
1544
1512
  data: unknown;
1545
1513
  } | {
1546
1514
  type: "focused";
1547
- event: react20.FocusEvent<HTMLDivElement, Element>;
1515
+ event: react18.FocusEvent<HTMLDivElement, Element>;
1548
1516
  } | {
1549
1517
  type: "invalid value";
1550
1518
  resolution: InvalidValueResolution | null;
@@ -1561,30 +1529,29 @@ declare const editorMachine: xstate229.StateMachine<{
1561
1529
  } | {
1562
1530
  type: "value changed";
1563
1531
  value: Array<PortableTextBlock> | undefined;
1564
- }, xstate229.MetaObject, {
1532
+ }, xstate228.MetaObject, {
1565
1533
  readonly id: "editor";
1566
1534
  readonly context: ({
1567
1535
  input
1568
1536
  }: {
1569
1537
  spawn: {
1570
- <TSrc extends never>(logic: TSrc, ...[options]: never): xstate229.ActorRefFromLogic<never>;
1571
- <TLogic extends xstate229.AnyActorLogic>(src: TLogic, ...[options]: xstate229.ConditionalRequired<[options?: ({
1538
+ <TSrc extends never>(logic: TSrc, ...[options]: never): xstate228.ActorRefFromLogic<never>;
1539
+ <TLogic extends xstate228.AnyActorLogic>(src: TLogic, ...[options]: xstate228.ConditionalRequired<[options?: ({
1572
1540
  id?: never;
1573
1541
  systemId?: string;
1574
- input?: xstate229.InputFrom<TLogic> | undefined;
1542
+ input?: xstate228.InputFrom<TLogic> | undefined;
1575
1543
  syncSnapshot?: boolean;
1576
- } & { [K in xstate229.RequiredLogicInput<TLogic>]: unknown }) | undefined], xstate229.IsNotNever<xstate229.RequiredLogicInput<TLogic>>>): xstate229.ActorRefFromLogic<TLogic>;
1544
+ } & { [K in xstate228.RequiredLogicInput<TLogic>]: unknown }) | undefined], xstate228.IsNotNever<xstate228.RequiredLogicInput<TLogic>>>): xstate228.ActorRefFromLogic<TLogic>;
1577
1545
  };
1578
1546
  input: {
1579
1547
  converters?: Array<Converter>;
1580
1548
  getLegacySchema: () => PortableTextMemberSchemaTypes;
1581
1549
  keyGenerator: () => string;
1582
- maxBlocks?: number;
1583
1550
  readOnly?: boolean;
1584
1551
  schema: EditorSchema;
1585
1552
  initialValue?: Array<PortableTextBlock>;
1586
1553
  };
1587
- self: xstate229.ActorRef<xstate229.MachineSnapshot<{
1554
+ self: xstate228.ActorRef<xstate228.MachineSnapshot<{
1588
1555
  behaviors: Set<BehaviorConfig>;
1589
1556
  behaviorsSorted: boolean;
1590
1557
  converters: Set<Converter>;
@@ -1594,7 +1561,6 @@ declare const editorMachine: xstate229.StateMachine<{
1594
1561
  pendingIncomingPatchesEvents: Array<PatchesEvent>;
1595
1562
  schema: EditorSchema;
1596
1563
  initialReadOnly: boolean;
1597
- maxBlocks: number | undefined;
1598
1564
  selection: EditorSelection;
1599
1565
  initialValue: Array<PortableTextBlock> | undefined;
1600
1566
  internalDrag?: {
@@ -1605,9 +1571,6 @@ declare const editorMachine: xstate229.StateMachine<{
1605
1571
  }, InternalPatchEvent | MutationEvent | PatchesEvent | {
1606
1572
  type: "update readOnly";
1607
1573
  readOnly: boolean;
1608
- } | {
1609
- type: "update maxBlocks";
1610
- maxBlocks: number | undefined;
1611
1574
  } | {
1612
1575
  type: "add behavior";
1613
1576
  behaviorConfig: BehaviorConfig;
@@ -1648,12 +1611,9 @@ declare const editorMachine: xstate229.StateMachine<{
1648
1611
  } | {
1649
1612
  type: "add slate editor";
1650
1613
  editor: PortableTextSlateEditor;
1651
- }, Record<string, xstate229.AnyActorRef | undefined>, xstate229.StateValue, string, unknown, any, any>, InternalPatchEvent | MutationEvent | PatchesEvent | {
1614
+ }, Record<string, xstate228.AnyActorRef | undefined>, xstate228.StateValue, string, unknown, any, any>, InternalPatchEvent | MutationEvent | PatchesEvent | {
1652
1615
  type: "update readOnly";
1653
1616
  readOnly: boolean;
1654
- } | {
1655
- type: "update maxBlocks";
1656
- maxBlocks: number | undefined;
1657
1617
  } | {
1658
1618
  type: "add behavior";
1659
1619
  behaviorConfig: BehaviorConfig;
@@ -1694,10 +1654,10 @@ declare const editorMachine: xstate229.StateMachine<{
1694
1654
  } | {
1695
1655
  type: "add slate editor";
1696
1656
  editor: PortableTextSlateEditor;
1697
- }, xstate229.AnyEventObject>;
1657
+ }, xstate228.AnyEventObject>;
1698
1658
  }) => {
1699
1659
  behaviors: Set<{
1700
- behavior: Behavior<"*" | "split" | `custom.${string}` | "annotation.add" | "annotation.remove" | "block.set" | "block.unset" | "child.set" | "child.unset" | "decorator.add" | "decorator.remove" | "delete" | "history.redo" | "history.undo" | "insert.block" | "insert.child" | "insert.text" | "move.backward" | "move.block" | "move.forward" | "select" | "annotation.set" | "annotation.toggle" | "decorator.toggle" | "delete.backward" | "delete.block" | "delete.child" | "delete.forward" | "delete.text" | "deserialize" | "deserialize.data" | "deserialization.success" | "deserialization.failure" | "insert.blocks" | "insert.break" | "insert.inline object" | "insert.soft break" | "insert.span" | "list item.add" | "list item.remove" | "list item.toggle" | "move.block down" | "move.block up" | "select.block" | "select.previous block" | "select.next block" | "serialize" | "serialize.data" | "serialization.success" | "serialization.failure" | "style.add" | "style.remove" | "style.toggle" | "clipboard.copy" | "clipboard.cut" | "clipboard.paste" | "drag.dragstart" | "drag.drag" | "drag.dragend" | "drag.dragenter" | "drag.dragover" | "drag.dragleave" | "drag.drop" | "input.*" | "keyboard.keydown" | "keyboard.keyup" | "mouse.click" | "history.*" | "split.*" | "delete.*" | "select.*" | "deserialize.*" | "serialize.*" | "annotation.*" | "block.*" | "child.*" | "decorator.*" | "insert.*" | "move.*" | "deserialization.*" | "list item.*" | "serialization.*" | "style.*" | "clipboard.*" | "drag.*" | "keyboard.*" | "mouse.*", true, {
1660
+ behavior: Behavior<"*" | "split" | `custom.${string}` | "annotation.add" | "annotation.remove" | "block.set" | "block.unset" | "child.set" | "child.unset" | "decorator.add" | "decorator.remove" | "delete" | "history.redo" | "history.undo" | "insert.block" | "insert.child" | "insert.text" | "move.backward" | "move.block" | "move.forward" | "select" | "annotation.set" | "annotation.toggle" | "decorator.toggle" | "delete.backward" | "delete.block" | "delete.child" | "delete.forward" | "delete.text" | "deserialize" | "deserialize.data" | "deserialization.success" | "deserialization.failure" | "insert.blocks" | "insert.break" | "insert.inline object" | "insert.soft break" | "insert.span" | "list item.add" | "list item.remove" | "list item.toggle" | "move.block down" | "move.block up" | "select.block" | "select.previous block" | "select.next block" | "serialize" | "serialize.data" | "serialization.success" | "serialization.failure" | "style.add" | "style.remove" | "style.toggle" | "clipboard.copy" | "clipboard.cut" | "clipboard.paste" | "drag.dragstart" | "drag.drag" | "drag.dragend" | "drag.dragenter" | "drag.dragover" | "drag.dragleave" | "drag.drop" | "input.*" | "keyboard.keydown" | "keyboard.keyup" | "mouse.click" | "style.*" | "history.*" | "split.*" | "delete.*" | "select.*" | "deserialize.*" | "serialize.*" | "annotation.*" | "block.*" | "child.*" | "decorator.*" | "insert.*" | "move.*" | "deserialization.*" | "list item.*" | "serialization.*" | "clipboard.*" | "drag.*" | "keyboard.*" | "mouse.*", true, {
1701
1661
  type: StrictExtract<"split" | "annotation.add" | "annotation.remove" | "block.set" | "block.unset" | "child.set" | "child.unset" | "decorator.add" | "decorator.remove" | "delete" | "history.redo" | "history.undo" | "insert.block" | "insert.child" | "insert.text" | "move.backward" | "move.block" | "move.forward" | "select" | "annotation.set" | "annotation.toggle" | "decorator.toggle" | "delete.backward" | "delete.block" | "delete.child" | "delete.forward" | "delete.text" | "deserialize" | "deserialize.data" | "deserialization.success" | "deserialization.failure" | "insert.blocks" | "insert.break" | "insert.inline object" | "insert.soft break" | "insert.span" | "list item.add" | "list item.remove" | "list item.toggle" | "move.block down" | "move.block up" | "select.block" | "select.previous block" | "select.next block" | "serialize" | "serialize.data" | "serialization.success" | "serialization.failure" | "style.add" | "style.remove" | "style.toggle", "annotation.add">;
1702
1662
  annotation: {
1703
1663
  name: string;
@@ -1978,7 +1938,6 @@ declare const editorMachine: xstate229.StateMachine<{
1978
1938
  schema: _portabletext_schema5.Schema;
1979
1939
  selection: null;
1980
1940
  initialReadOnly: boolean;
1981
- maxBlocks: number | undefined;
1982
1941
  initialValue: PortableTextBlock[] | undefined;
1983
1942
  };
1984
1943
  readonly on: {
@@ -1988,81 +1947,11 @@ declare const editorMachine: xstate229.StateMachine<{
1988
1947
  readonly 'remove behavior': {
1989
1948
  readonly actions: "remove behavior from context";
1990
1949
  };
1991
- readonly 'update maxBlocks': {
1992
- readonly actions: xstate229.ActionFunction<{
1993
- behaviors: Set<BehaviorConfig>;
1994
- behaviorsSorted: boolean;
1995
- converters: Set<Converter>;
1996
- getLegacySchema: () => PortableTextMemberSchemaTypes;
1997
- keyGenerator: () => string;
1998
- pendingEvents: Array<InternalPatchEvent | MutationEvent>;
1999
- pendingIncomingPatchesEvents: Array<PatchesEvent>;
2000
- schema: EditorSchema;
2001
- initialReadOnly: boolean;
2002
- maxBlocks: number | undefined;
2003
- selection: EditorSelection;
2004
- initialValue: Array<PortableTextBlock> | undefined;
2005
- internalDrag?: {
2006
- origin: Pick<EventPosition, "selection">;
2007
- };
2008
- dragGhost?: HTMLElement;
2009
- slateEditor?: PortableTextSlateEditor;
2010
- }, {
2011
- type: "update maxBlocks";
2012
- maxBlocks: number | undefined;
2013
- }, InternalPatchEvent | MutationEvent | PatchesEvent | {
2014
- type: "update readOnly";
2015
- readOnly: boolean;
2016
- } | {
2017
- type: "update maxBlocks";
2018
- maxBlocks: number | undefined;
2019
- } | {
2020
- type: "add behavior";
2021
- behaviorConfig: BehaviorConfig;
2022
- } | {
2023
- type: "remove behavior";
2024
- behaviorConfig: BehaviorConfig;
2025
- } | {
2026
- type: "blur";
2027
- editor: PortableTextSlateEditor;
2028
- } | {
2029
- type: "focus";
2030
- editor: PortableTextSlateEditor;
2031
- } | {
2032
- type: "update selection";
2033
- selection: EditorSelection;
2034
- } | {
2035
- type: "done syncing value";
2036
- } | {
2037
- type: "syncing value";
2038
- } | {
2039
- type: "behavior event";
2040
- behaviorEvent: BehaviorEvent;
2041
- editor: PortableTextSlateEditor;
2042
- nativeEvent?: {
2043
- preventDefault: () => void;
2044
- };
2045
- } | {
2046
- type: "set drag ghost";
2047
- ghost: HTMLElement;
2048
- } | {
2049
- type: "dragstart";
2050
- ghost?: HTMLElement;
2051
- origin: Pick<EventPosition, "selection">;
2052
- } | {
2053
- type: "dragend";
2054
- } | {
2055
- type: "drop";
2056
- } | {
2057
- type: "add slate editor";
2058
- editor: PortableTextSlateEditor;
2059
- }, undefined, never, never, never, never, never>;
2060
- };
2061
1950
  readonly 'add slate editor': {
2062
1951
  readonly actions: "add slate editor to context";
2063
1952
  };
2064
1953
  readonly 'update selection': {
2065
- readonly actions: readonly [xstate229.ActionFunction<{
1954
+ readonly actions: readonly [xstate228.ActionFunction<{
2066
1955
  behaviors: Set<BehaviorConfig>;
2067
1956
  behaviorsSorted: boolean;
2068
1957
  converters: Set<Converter>;
@@ -2072,7 +1961,6 @@ declare const editorMachine: xstate229.StateMachine<{
2072
1961
  pendingIncomingPatchesEvents: Array<PatchesEvent>;
2073
1962
  schema: EditorSchema;
2074
1963
  initialReadOnly: boolean;
2075
- maxBlocks: number | undefined;
2076
1964
  selection: EditorSelection;
2077
1965
  initialValue: Array<PortableTextBlock> | undefined;
2078
1966
  internalDrag?: {
@@ -2086,9 +1974,6 @@ declare const editorMachine: xstate229.StateMachine<{
2086
1974
  }, InternalPatchEvent | MutationEvent | PatchesEvent | {
2087
1975
  type: "update readOnly";
2088
1976
  readOnly: boolean;
2089
- } | {
2090
- type: "update maxBlocks";
2091
- maxBlocks: number | undefined;
2092
1977
  } | {
2093
1978
  type: "add behavior";
2094
1979
  behaviorConfig: BehaviorConfig;
@@ -2129,7 +2014,7 @@ declare const editorMachine: xstate229.StateMachine<{
2129
2014
  } | {
2130
2015
  type: "add slate editor";
2131
2016
  editor: PortableTextSlateEditor;
2132
- }, undefined, never, never, never, never, never>, xstate229.ActionFunction<{
2017
+ }, undefined, never, never, never, never, never>, xstate228.ActionFunction<{
2133
2018
  behaviors: Set<BehaviorConfig>;
2134
2019
  behaviorsSorted: boolean;
2135
2020
  converters: Set<Converter>;
@@ -2139,7 +2024,6 @@ declare const editorMachine: xstate229.StateMachine<{
2139
2024
  pendingIncomingPatchesEvents: Array<PatchesEvent>;
2140
2025
  schema: EditorSchema;
2141
2026
  initialReadOnly: boolean;
2142
- maxBlocks: number | undefined;
2143
2027
  selection: EditorSelection;
2144
2028
  initialValue: Array<PortableTextBlock> | undefined;
2145
2029
  internalDrag?: {
@@ -2153,9 +2037,6 @@ declare const editorMachine: xstate229.StateMachine<{
2153
2037
  }, InternalPatchEvent | MutationEvent | PatchesEvent | {
2154
2038
  type: "update readOnly";
2155
2039
  readOnly: boolean;
2156
- } | {
2157
- type: "update maxBlocks";
2158
- maxBlocks: number | undefined;
2159
2040
  } | {
2160
2041
  type: "add behavior";
2161
2042
  behaviorConfig: BehaviorConfig;
@@ -2198,7 +2079,7 @@ declare const editorMachine: xstate229.StateMachine<{
2198
2079
  editor: PortableTextSlateEditor;
2199
2080
  }, undefined, never, never, never, never, InternalPatchEvent | MutationEvent | PatchesEvent | {
2200
2081
  type: "blurred";
2201
- event: react20.FocusEvent<HTMLDivElement, Element>;
2082
+ event: react18.FocusEvent<HTMLDivElement, Element>;
2202
2083
  } | {
2203
2084
  type: "done loading";
2204
2085
  } | {
@@ -2210,7 +2091,7 @@ declare const editorMachine: xstate229.StateMachine<{
2210
2091
  data: unknown;
2211
2092
  } | {
2212
2093
  type: "focused";
2213
- event: react20.FocusEvent<HTMLDivElement, Element>;
2094
+ event: react18.FocusEvent<HTMLDivElement, Element>;
2214
2095
  } | {
2215
2096
  type: "invalid value";
2216
2097
  resolution: InvalidValueResolution | null;
@@ -2230,7 +2111,7 @@ declare const editorMachine: xstate229.StateMachine<{
2230
2111
  }>];
2231
2112
  };
2232
2113
  readonly 'set drag ghost': {
2233
- readonly actions: xstate229.ActionFunction<{
2114
+ readonly actions: xstate228.ActionFunction<{
2234
2115
  behaviors: Set<BehaviorConfig>;
2235
2116
  behaviorsSorted: boolean;
2236
2117
  converters: Set<Converter>;
@@ -2240,7 +2121,6 @@ declare const editorMachine: xstate229.StateMachine<{
2240
2121
  pendingIncomingPatchesEvents: Array<PatchesEvent>;
2241
2122
  schema: EditorSchema;
2242
2123
  initialReadOnly: boolean;
2243
- maxBlocks: number | undefined;
2244
2124
  selection: EditorSelection;
2245
2125
  initialValue: Array<PortableTextBlock> | undefined;
2246
2126
  internalDrag?: {
@@ -2254,9 +2134,6 @@ declare const editorMachine: xstate229.StateMachine<{
2254
2134
  }, InternalPatchEvent | MutationEvent | PatchesEvent | {
2255
2135
  type: "update readOnly";
2256
2136
  readOnly: boolean;
2257
- } | {
2258
- type: "update maxBlocks";
2259
- maxBlocks: number | undefined;
2260
2137
  } | {
2261
2138
  type: "add behavior";
2262
2139
  behaviorConfig: BehaviorConfig;
@@ -2322,7 +2199,6 @@ declare const editorMachine: xstate229.StateMachine<{
2322
2199
  pendingIncomingPatchesEvents: Array<PatchesEvent>;
2323
2200
  schema: EditorSchema;
2324
2201
  initialReadOnly: boolean;
2325
- maxBlocks: number | undefined;
2326
2202
  selection: EditorSelection;
2327
2203
  initialValue: Array<PortableTextBlock> | undefined;
2328
2204
  internalDrag?: {
@@ -2359,7 +2235,6 @@ declare const editorMachine: xstate229.StateMachine<{
2359
2235
  pendingIncomingPatchesEvents: Array<PatchesEvent>;
2360
2236
  schema: EditorSchema;
2361
2237
  initialReadOnly: boolean;
2362
- maxBlocks: number | undefined;
2363
2238
  selection: EditorSelection;
2364
2239
  initialValue: Array<PortableTextBlock> | undefined;
2365
2240
  internalDrag?: {
@@ -2392,7 +2267,6 @@ declare const editorMachine: xstate229.StateMachine<{
2392
2267
  pendingIncomingPatchesEvents: Array<PatchesEvent>;
2393
2268
  schema: EditorSchema;
2394
2269
  initialReadOnly: boolean;
2395
- maxBlocks: number | undefined;
2396
2270
  selection: EditorSelection;
2397
2271
  initialValue: Array<PortableTextBlock> | undefined;
2398
2272
  internalDrag?: {
@@ -2426,7 +2300,6 @@ declare const editorMachine: xstate229.StateMachine<{
2426
2300
  pendingIncomingPatchesEvents: Array<PatchesEvent>;
2427
2301
  schema: EditorSchema;
2428
2302
  initialReadOnly: boolean;
2429
- maxBlocks: number | undefined;
2430
2303
  selection: EditorSelection;
2431
2304
  initialValue: Array<PortableTextBlock> | undefined;
2432
2305
  internalDrag?: {
@@ -2449,7 +2322,7 @@ declare const editorMachine: xstate229.StateMachine<{
2449
2322
  };
2450
2323
  readonly focus: {
2451
2324
  readonly target: ".focusing";
2452
- readonly actions: readonly [xstate229.ActionFunction<{
2325
+ readonly actions: readonly [xstate228.ActionFunction<{
2453
2326
  behaviors: Set<BehaviorConfig>;
2454
2327
  behaviorsSorted: boolean;
2455
2328
  converters: Set<Converter>;
@@ -2459,7 +2332,6 @@ declare const editorMachine: xstate229.StateMachine<{
2459
2332
  pendingIncomingPatchesEvents: Array<PatchesEvent>;
2460
2333
  schema: EditorSchema;
2461
2334
  initialReadOnly: boolean;
2462
- maxBlocks: number | undefined;
2463
2335
  selection: EditorSelection;
2464
2336
  initialValue: Array<PortableTextBlock> | undefined;
2465
2337
  internalDrag?: {
@@ -2473,9 +2345,6 @@ declare const editorMachine: xstate229.StateMachine<{
2473
2345
  }, InternalPatchEvent | MutationEvent | PatchesEvent | {
2474
2346
  type: "update readOnly";
2475
2347
  readOnly: boolean;
2476
- } | {
2477
- type: "update maxBlocks";
2478
- maxBlocks: number | undefined;
2479
2348
  } | {
2480
2349
  type: "add behavior";
2481
2350
  behaviorConfig: BehaviorConfig;
@@ -2526,7 +2395,7 @@ declare const editorMachine: xstate229.StateMachine<{
2526
2395
  readonly exit: readonly [() => void];
2527
2396
  readonly on: {
2528
2397
  readonly dragstart: {
2529
- readonly actions: readonly [xstate229.ActionFunction<{
2398
+ readonly actions: readonly [xstate228.ActionFunction<{
2530
2399
  behaviors: Set<BehaviorConfig>;
2531
2400
  behaviorsSorted: boolean;
2532
2401
  converters: Set<Converter>;
@@ -2536,7 +2405,6 @@ declare const editorMachine: xstate229.StateMachine<{
2536
2405
  pendingIncomingPatchesEvents: Array<PatchesEvent>;
2537
2406
  schema: EditorSchema;
2538
2407
  initialReadOnly: boolean;
2539
- maxBlocks: number | undefined;
2540
2408
  selection: EditorSelection;
2541
2409
  initialValue: Array<PortableTextBlock> | undefined;
2542
2410
  internalDrag?: {
@@ -2551,9 +2419,6 @@ declare const editorMachine: xstate229.StateMachine<{
2551
2419
  }, InternalPatchEvent | MutationEvent | PatchesEvent | {
2552
2420
  type: "update readOnly";
2553
2421
  readOnly: boolean;
2554
- } | {
2555
- type: "update maxBlocks";
2556
- maxBlocks: number | undefined;
2557
2422
  } | {
2558
2423
  type: "add behavior";
2559
2424
  behaviorConfig: BehaviorConfig;
@@ -2628,7 +2493,7 @@ declare const editorMachine: xstate229.StateMachine<{
2628
2493
  readonly entry: readonly [() => void];
2629
2494
  readonly exit: readonly [() => void, ({
2630
2495
  context
2631
- }: xstate229.ActionArgs<{
2496
+ }: xstate228.ActionArgs<{
2632
2497
  behaviors: Set<BehaviorConfig>;
2633
2498
  behaviorsSorted: boolean;
2634
2499
  converters: Set<Converter>;
@@ -2638,7 +2503,6 @@ declare const editorMachine: xstate229.StateMachine<{
2638
2503
  pendingIncomingPatchesEvents: Array<PatchesEvent>;
2639
2504
  schema: EditorSchema;
2640
2505
  initialReadOnly: boolean;
2641
- maxBlocks: number | undefined;
2642
2506
  selection: EditorSelection;
2643
2507
  initialValue: Array<PortableTextBlock> | undefined;
2644
2508
  internalDrag?: {
@@ -2649,9 +2513,6 @@ declare const editorMachine: xstate229.StateMachine<{
2649
2513
  }, InternalPatchEvent | MutationEvent | PatchesEvent | {
2650
2514
  type: "update readOnly";
2651
2515
  readOnly: boolean;
2652
- } | {
2653
- type: "update maxBlocks";
2654
- maxBlocks: number | undefined;
2655
2516
  } | {
2656
2517
  type: "add behavior";
2657
2518
  behaviorConfig: BehaviorConfig;
@@ -2695,9 +2556,6 @@ declare const editorMachine: xstate229.StateMachine<{
2695
2556
  }, InternalPatchEvent | MutationEvent | PatchesEvent | {
2696
2557
  type: "update readOnly";
2697
2558
  readOnly: boolean;
2698
- } | {
2699
- type: "update maxBlocks";
2700
- maxBlocks: number | undefined;
2701
2559
  } | {
2702
2560
  type: "add behavior";
2703
2561
  behaviorConfig: BehaviorConfig;
@@ -2738,7 +2596,7 @@ declare const editorMachine: xstate229.StateMachine<{
2738
2596
  } | {
2739
2597
  type: "add slate editor";
2740
2598
  editor: PortableTextSlateEditor;
2741
- }>) => void, xstate229.ActionFunction<{
2599
+ }>) => void, xstate228.ActionFunction<{
2742
2600
  behaviors: Set<BehaviorConfig>;
2743
2601
  behaviorsSorted: boolean;
2744
2602
  converters: Set<Converter>;
@@ -2748,7 +2606,6 @@ declare const editorMachine: xstate229.StateMachine<{
2748
2606
  pendingIncomingPatchesEvents: Array<PatchesEvent>;
2749
2607
  schema: EditorSchema;
2750
2608
  initialReadOnly: boolean;
2751
- maxBlocks: number | undefined;
2752
2609
  selection: EditorSelection;
2753
2610
  initialValue: Array<PortableTextBlock> | undefined;
2754
2611
  internalDrag?: {
@@ -2759,9 +2616,6 @@ declare const editorMachine: xstate229.StateMachine<{
2759
2616
  }, InternalPatchEvent | MutationEvent | PatchesEvent | {
2760
2617
  type: "update readOnly";
2761
2618
  readOnly: boolean;
2762
- } | {
2763
- type: "update maxBlocks";
2764
- maxBlocks: number | undefined;
2765
2619
  } | {
2766
2620
  type: "add behavior";
2767
2621
  behaviorConfig: BehaviorConfig;
@@ -2805,9 +2659,6 @@ declare const editorMachine: xstate229.StateMachine<{
2805
2659
  }, InternalPatchEvent | MutationEvent | PatchesEvent | {
2806
2660
  type: "update readOnly";
2807
2661
  readOnly: boolean;
2808
- } | {
2809
- type: "update maxBlocks";
2810
- maxBlocks: number | undefined;
2811
2662
  } | {
2812
2663
  type: "add behavior";
2813
2664
  behaviorConfig: BehaviorConfig;
@@ -2848,7 +2699,7 @@ declare const editorMachine: xstate229.StateMachine<{
2848
2699
  } | {
2849
2700
  type: "add slate editor";
2850
2701
  editor: PortableTextSlateEditor;
2851
- }, undefined, never, never, never, never, never>, xstate229.ActionFunction<{
2702
+ }, undefined, never, never, never, never, never>, xstate228.ActionFunction<{
2852
2703
  behaviors: Set<BehaviorConfig>;
2853
2704
  behaviorsSorted: boolean;
2854
2705
  converters: Set<Converter>;
@@ -2858,7 +2709,6 @@ declare const editorMachine: xstate229.StateMachine<{
2858
2709
  pendingIncomingPatchesEvents: Array<PatchesEvent>;
2859
2710
  schema: EditorSchema;
2860
2711
  initialReadOnly: boolean;
2861
- maxBlocks: number | undefined;
2862
2712
  selection: EditorSelection;
2863
2713
  initialValue: Array<PortableTextBlock> | undefined;
2864
2714
  internalDrag?: {
@@ -2869,9 +2719,6 @@ declare const editorMachine: xstate229.StateMachine<{
2869
2719
  }, InternalPatchEvent | MutationEvent | PatchesEvent | {
2870
2720
  type: "update readOnly";
2871
2721
  readOnly: boolean;
2872
- } | {
2873
- type: "update maxBlocks";
2874
- maxBlocks: number | undefined;
2875
2722
  } | {
2876
2723
  type: "add behavior";
2877
2724
  behaviorConfig: BehaviorConfig;
@@ -2915,9 +2762,6 @@ declare const editorMachine: xstate229.StateMachine<{
2915
2762
  }, InternalPatchEvent | MutationEvent | PatchesEvent | {
2916
2763
  type: "update readOnly";
2917
2764
  readOnly: boolean;
2918
- } | {
2919
- type: "update maxBlocks";
2920
- maxBlocks: number | undefined;
2921
2765
  } | {
2922
2766
  type: "add behavior";
2923
2767
  behaviorConfig: BehaviorConfig;
@@ -3005,7 +2849,7 @@ declare const editorMachine: xstate229.StateMachine<{
3005
2849
  readonly exit: readonly [() => void];
3006
2850
  readonly on: {
3007
2851
  readonly patches: {
3008
- readonly actions: readonly [xstate229.ActionFunction<{
2852
+ readonly actions: readonly [xstate228.ActionFunction<{
3009
2853
  behaviors: Set<BehaviorConfig>;
3010
2854
  behaviorsSorted: boolean;
3011
2855
  converters: Set<Converter>;
@@ -3015,7 +2859,6 @@ declare const editorMachine: xstate229.StateMachine<{
3015
2859
  pendingIncomingPatchesEvents: Array<PatchesEvent>;
3016
2860
  schema: EditorSchema;
3017
2861
  initialReadOnly: boolean;
3018
- maxBlocks: number | undefined;
3019
2862
  selection: EditorSelection;
3020
2863
  initialValue: Array<PortableTextBlock> | undefined;
3021
2864
  internalDrag?: {
@@ -3026,9 +2869,6 @@ declare const editorMachine: xstate229.StateMachine<{
3026
2869
  }, PatchesEvent, InternalPatchEvent | MutationEvent | PatchesEvent | {
3027
2870
  type: "update readOnly";
3028
2871
  readOnly: boolean;
3029
- } | {
3030
- type: "update maxBlocks";
3031
- maxBlocks: number | undefined;
3032
2872
  } | {
3033
2873
  type: "add behavior";
3034
2874
  behaviorConfig: BehaviorConfig;
@@ -3071,7 +2911,7 @@ declare const editorMachine: xstate229.StateMachine<{
3071
2911
  editor: PortableTextSlateEditor;
3072
2912
  }, undefined, never, never, never, never, InternalPatchEvent | MutationEvent | PatchesEvent | {
3073
2913
  type: "blurred";
3074
- event: react20.FocusEvent<HTMLDivElement, Element>;
2914
+ event: react18.FocusEvent<HTMLDivElement, Element>;
3075
2915
  } | {
3076
2916
  type: "done loading";
3077
2917
  } | {
@@ -3083,7 +2923,7 @@ declare const editorMachine: xstate229.StateMachine<{
3083
2923
  data: unknown;
3084
2924
  } | {
3085
2925
  type: "focused";
3086
- event: react20.FocusEvent<HTMLDivElement, Element>;
2926
+ event: react18.FocusEvent<HTMLDivElement, Element>;
3087
2927
  } | {
3088
2928
  type: "invalid value";
3089
2929
  resolution: InvalidValueResolution | null;
@@ -3633,4 +3473,4 @@ type BehaviorActionSet<TBehaviorEvent, TGuardResponse> = (payload: {
3633
3473
  event: TBehaviorEvent;
3634
3474
  dom: EditorDom;
3635
3475
  }, guardResponse: TGuardResponse) => Array<BehaviorAction>;
3636
- export { AddedAnnotationPaths as $, PortableTextEditorProps as $t, PortableTextTextBlock$2 as A, RangeDecorationOnMovedDetails as At, EditorSelector as B, RenderStyleFunction as Bt, ListDefinition as C, OnPasteResult as Ct, PortableTextChild$1 as D, PatchObservable as Dt, PortableTextBlock$1 as E, PatchChange as Et, BlockOffset as F, RenderChildFunction as Ft, Editor as G, ValueChange as Gt, EditorProvider as H, SelectionChange as Ht, useEditor as I, RenderDecoratorFunction as It, Behavior as J, ChildPath as Jt, EditorConfig as K, AnnotationPath as Kt, defaultKeyGenerator as L, RenderEditableFunction as Lt, StyleDefinition as M, RedoChange as Mt, StyleSchemaType as N, RenderAnnotationFunction as Nt, PortableTextObject$2 as O, PortableTextMemberSchemaTypes as Ot, defineSchema as P, RenderBlockFunction as Pt, EditorSnapshot as Q, PortableTextEditor as Qt, usePortableTextEditorSelection as R, RenderListItemFunction as Rt, InlineObjectSchemaType as S, OnPasteFn as St, Patch$1 as T, PasteData as Tt, EditorProviderProps as U, UndoChange as Ut, useEditorSelector as V, ScrollSelectionIntoViewFunction as Vt, EditorEventListener as W, UnsetChange as Wt, BehaviorGuard as X, PortableTextEditableProps as Xt, defineBehavior as Y, PortableTextEditable as Yt, EditorContext as Z, HotkeyOptions as Zt, BlockObjectSchemaType as _, InvalidValueResolution as _t, forward as a, BlockStyleRenderProps as at, FieldDefinition as b, OnBeforeInputFn as bt, CustomBehaviorEvent as c, EditableAPI as ct, SyntheticBehaviorEvent as d, EditorChanges as dt, EditorSchema as en, BlockAnnotationRenderProps as et, PatchesEvent as f, EditorSelection as ft, BlockObjectDefinition as g, InvalidValue as gt, BaseDefinition as h, FocusChange as ht, execute as i, BlockRenderProps as it, SchemaDefinition$1 as j, ReadyChange as jt, PortableTextSpan$2 as k, RangeDecoration as kt, InsertPlacement as l, EditableAPIDeleteOptions as lt, AnnotationSchemaType as m, ErrorChange as mt, BehaviorActionSet as n, MutationEvent as nn, BlockDecoratorRenderProps as nt, raise as o, BlurChange as ot, AnnotationDefinition as p, EditorSelectionPoint as pt, EditorEvent as q, BlockPath as qt, effect as r, BlockListItemRenderProps as rt, BehaviorEvent as s, ConnectionChange as st, BehaviorAction as t, EditorEmittedEvent as tn, BlockChildRenderProps as tt, NativeBehaviorEvent as u, EditorChange as ut, DecoratorDefinition as v, LoadingChange as vt, ListSchemaType as w, OnPasteResultOrPromise as wt, InlineObjectDefinition as x, OnCopyFn as xt, DecoratorSchemaType as y, MutationChange as yt, usePortableTextEditor as z, RenderPlaceholderFunction as zt };
3476
+ export { BlockAnnotationRenderProps as $, EditorSchema as $t, PortableTextTextBlock$2 as A, ReadyChange as At, EditorSelector as B, ScrollSelectionIntoViewFunction as Bt, ListDefinition as C, OnPasteResultOrPromise as Ct, PortableTextChild$1 as D, PortableTextMemberSchemaTypes as Dt, PortableTextBlock$1 as E, PatchObservable as Et, BlockOffset as F, RenderDecoratorFunction as Ft, EditorConfig as G, AnnotationPath as Gt, EditorProvider as H, UndoChange as Ht, useEditor as I, RenderEditableFunction as It, defineBehavior as J, PortableTextEditable as Jt, EditorEvent as K, BlockPath as Kt, defaultKeyGenerator as L, RenderListItemFunction as Lt, StyleDefinition as M, RenderAnnotationFunction as Mt, StyleSchemaType as N, RenderBlockFunction as Nt, PortableTextObject$2 as O, RangeDecoration as Ot, defineSchema as P, RenderChildFunction as Pt, AddedAnnotationPaths as Q, PortableTextEditorProps as Qt, usePortableTextEditorSelection as R, RenderPlaceholderFunction as Rt, InlineObjectSchemaType as S, OnPasteResult as St, Patch$1 as T, PatchChange as Tt, EditorProviderProps as U, UnsetChange as Ut, useEditorSelector as V, SelectionChange as Vt, Editor as W, ValueChange as Wt, EditorContext as X, HotkeyOptions as Xt, BehaviorGuard as Y, PortableTextEditableProps as Yt, EditorSnapshot as Z, PortableTextEditor as Zt, BlockObjectSchemaType as _, LoadingChange as _t, forward as a, BlurChange as at, FieldDefinition as b, OnCopyFn as bt, CustomBehaviorEvent as c, EditableAPIDeleteOptions as ct, SyntheticBehaviorEvent as d, EditorSelection as dt, EditorEmittedEvent as en, BlockChildRenderProps as et, PatchesEvent as f, EditorSelectionPoint as ft, BlockObjectDefinition as g, InvalidValueResolution as gt, BaseDefinition as h, InvalidValue as ht, execute as i, BlockStyleRenderProps as it, SchemaDefinition$1 as j, RedoChange as jt, PortableTextSpan$2 as k, RangeDecorationOnMovedDetails as kt, InsertPlacement as l, EditorChange as lt, AnnotationSchemaType as m, FocusChange as mt, BehaviorActionSet as n, BlockListItemRenderProps as nt, raise as o, ConnectionChange as ot, AnnotationDefinition as p, ErrorChange as pt, Behavior as q, ChildPath as qt, effect as r, BlockRenderProps as rt, BehaviorEvent as s, EditableAPI as st, BehaviorAction as t, MutationEvent as tn, BlockDecoratorRenderProps as tt, NativeBehaviorEvent as u, EditorChanges as ut, DecoratorDefinition as v, MutationChange as vt, ListSchemaType as w, PasteData as wt, InlineObjectDefinition as x, OnPasteFn as xt, DecoratorSchemaType as y, OnBeforeInputFn as yt, usePortableTextEditor as z, RenderStyleFunction as zt };