@portabletext/editor 2.13.0 → 2.13.2

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.
@@ -3,12 +3,12 @@ import * as _sanity_types5 from "@sanity/types";
3
3
  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";
4
4
  import * as _portabletext_schema5 from "@portabletext/schema";
5
5
  import { AnnotationDefinition, AnnotationSchemaType, BaseDefinition, BlockObjectDefinition, BlockObjectSchemaType, DecoratorDefinition, DecoratorSchemaType, FieldDefinition, InlineObjectDefinition, InlineObjectSchemaType, ListDefinition, ListSchemaType, PortableTextObject as PortableTextObject$1, PortableTextSpan as PortableTextSpan$1, PortableTextTextBlock as PortableTextTextBlock$1, Schema, SchemaDefinition, SchemaDefinition as SchemaDefinition$1, StyleDefinition, StyleSchemaType, defineSchema } from "@portabletext/schema";
6
- import * as xstate241 from "xstate";
6
+ import * as xstate227 from "xstate";
7
7
  import { ActorRef, ActorRefFrom, EventObject, Snapshot } from "xstate";
8
8
  import { BaseRange, Descendant, Operation } from "slate";
9
- import * as react20 from "react";
9
+ import * as react22 from "react";
10
10
  import React$1, { BaseSyntheticEvent, ClipboardEvent, Component, FocusEvent, JSX, KeyboardEvent as KeyboardEvent$1, MutableRefObject, PropsWithChildren, ReactElement, RefObject, TextareaHTMLAttributes } from "react";
11
- import * as xstate_guards14 from "xstate/guards";
11
+ import * as xstate_guards12 from "xstate/guards";
12
12
  import { Observable, Subject } from "rxjs";
13
13
  import { DOMNode } from "slate-dom";
14
14
  import { ReactEditor } from "slate-react";
@@ -198,7 +198,7 @@ declare class PortableTextEditor extends Component<PortableTextEditorProps<Inter
198
198
  componentDidUpdate(prevProps: PortableTextEditorProps): void;
199
199
  componentWillUnmount(): void;
200
200
  setEditable: (editable: EditableAPI) => void;
201
- render(): react20.JSX.Element;
201
+ render(): react22.JSX.Element;
202
202
  /**
203
203
  * @deprecated
204
204
  * Use built-in selectors or write your own: https://www.portabletext.org/reference/selectors/
@@ -593,7 +593,7 @@ type PortableTextEditableProps = Omit<TextareaHTMLAttributes<HTMLDivElement>, 'o
593
593
  * ```
594
594
  * @group Components
595
595
  */
596
- declare const PortableTextEditable: react20.ForwardRefExoticComponent<Omit<PortableTextEditableProps, "ref"> & react20.RefAttributes<Omit<HTMLDivElement, "as" | "onPaste" | "onBeforeInput">>>;
596
+ declare const PortableTextEditable: react22.ForwardRefExoticComponent<Omit<PortableTextEditableProps, "ref"> & react22.RefAttributes<Omit<HTMLDivElement, "as" | "onPaste" | "onBeforeInput">>>;
597
597
  type DecoratedRange = BaseRange & {
598
598
  rangeDecoration: RangeDecoration;
599
599
  };
@@ -1168,7 +1168,7 @@ type EditorActor = ActorRefFrom<typeof editorMachine>;
1168
1168
  /**
1169
1169
  * @internal
1170
1170
  */
1171
- declare const editorMachine: xstate241.StateMachine<{
1171
+ declare const editorMachine: xstate227.StateMachine<{
1172
1172
  behaviors: Set<BehaviorConfig>;
1173
1173
  behaviorsSorted: boolean;
1174
1174
  converters: Set<Converter>;
@@ -1186,7 +1186,7 @@ declare const editorMachine: xstate241.StateMachine<{
1186
1186
  };
1187
1187
  dragGhost?: HTMLElement;
1188
1188
  slateEditor?: PortableTextSlateEditor;
1189
- }, MutationEvent | InternalPatchEvent | PatchesEvent | {
1189
+ }, InternalPatchEvent | MutationEvent | PatchesEvent | {
1190
1190
  type: "update readOnly";
1191
1191
  readOnly: boolean;
1192
1192
  } | {
@@ -1233,58 +1233,58 @@ declare const editorMachine: xstate241.StateMachine<{
1233
1233
  type: "dragend";
1234
1234
  } | {
1235
1235
  type: "drop";
1236
- }, {}, never, xstate241.Values<{
1236
+ }, {}, never, xstate227.Values<{
1237
1237
  "add behavior to context": {
1238
1238
  type: "add behavior to context";
1239
- params: xstate241.NonReducibleUnknown;
1239
+ params: xstate227.NonReducibleUnknown;
1240
1240
  };
1241
1241
  "remove behavior from context": {
1242
1242
  type: "remove behavior from context";
1243
- params: xstate241.NonReducibleUnknown;
1243
+ params: xstate227.NonReducibleUnknown;
1244
1244
  };
1245
1245
  "emit patch event": {
1246
1246
  type: "emit patch event";
1247
- params: xstate241.NonReducibleUnknown;
1247
+ params: xstate227.NonReducibleUnknown;
1248
1248
  };
1249
1249
  "emit mutation event": {
1250
1250
  type: "emit mutation event";
1251
- params: xstate241.NonReducibleUnknown;
1251
+ params: xstate227.NonReducibleUnknown;
1252
1252
  };
1253
1253
  "emit read only": {
1254
1254
  type: "emit read only";
1255
- params: xstate241.NonReducibleUnknown;
1255
+ params: xstate227.NonReducibleUnknown;
1256
1256
  };
1257
1257
  "emit editable": {
1258
1258
  type: "emit editable";
1259
- params: xstate241.NonReducibleUnknown;
1259
+ params: xstate227.NonReducibleUnknown;
1260
1260
  };
1261
1261
  "defer event": {
1262
1262
  type: "defer event";
1263
- params: xstate241.NonReducibleUnknown;
1263
+ params: xstate227.NonReducibleUnknown;
1264
1264
  };
1265
1265
  "emit pending events": {
1266
1266
  type: "emit pending events";
1267
- params: xstate241.NonReducibleUnknown;
1267
+ params: xstate227.NonReducibleUnknown;
1268
1268
  };
1269
1269
  "emit ready": {
1270
1270
  type: "emit ready";
1271
- params: xstate241.NonReducibleUnknown;
1271
+ params: xstate227.NonReducibleUnknown;
1272
1272
  };
1273
1273
  "clear pending events": {
1274
1274
  type: "clear pending events";
1275
- params: xstate241.NonReducibleUnknown;
1275
+ params: xstate227.NonReducibleUnknown;
1276
1276
  };
1277
1277
  "defer incoming patches": {
1278
1278
  type: "defer incoming patches";
1279
- params: xstate241.NonReducibleUnknown;
1279
+ params: xstate227.NonReducibleUnknown;
1280
1280
  };
1281
1281
  "emit pending incoming patches": {
1282
1282
  type: "emit pending incoming patches";
1283
- params: xstate241.NonReducibleUnknown;
1283
+ params: xstate227.NonReducibleUnknown;
1284
1284
  };
1285
1285
  "clear pending incoming patches": {
1286
1286
  type: "clear pending incoming patches";
1287
- params: xstate241.NonReducibleUnknown;
1287
+ params: xstate227.NonReducibleUnknown;
1288
1288
  };
1289
1289
  "handle blur": {
1290
1290
  type: "handle blur";
@@ -1300,7 +1300,7 @@ declare const editorMachine: xstate241.StateMachine<{
1300
1300
  };
1301
1301
  "sort behaviors": {
1302
1302
  type: "sort behaviors";
1303
- params: xstate241.NonReducibleUnknown;
1303
+ params: xstate227.NonReducibleUnknown;
1304
1304
  };
1305
1305
  }>, {
1306
1306
  type: "slate is busy";
@@ -1329,9 +1329,9 @@ declare const editorMachine: xstate241.StateMachine<{
1329
1329
  readOnly?: boolean;
1330
1330
  schema: EditorSchema;
1331
1331
  initialValue?: Array<PortableTextBlock>;
1332
- }, xstate241.NonReducibleUnknown, {
1332
+ }, xstate227.NonReducibleUnknown, InternalPatchEvent | MutationEvent | PatchesEvent | {
1333
1333
  type: "blurred";
1334
- event: react20.FocusEvent<HTMLDivElement, Element>;
1334
+ event: react22.FocusEvent<HTMLDivElement, Element>;
1335
1335
  } | {
1336
1336
  type: "done loading";
1337
1337
  } | {
@@ -1343,14 +1343,14 @@ declare const editorMachine: xstate241.StateMachine<{
1343
1343
  data: unknown;
1344
1344
  } | {
1345
1345
  type: "focused";
1346
- event: react20.FocusEvent<HTMLDivElement, Element>;
1346
+ event: react22.FocusEvent<HTMLDivElement, Element>;
1347
1347
  } | {
1348
1348
  type: "invalid value";
1349
1349
  resolution: InvalidValueResolution | null;
1350
1350
  value: Array<PortableTextBlock> | undefined;
1351
1351
  } | {
1352
1352
  type: "loading";
1353
- } | MutationEvent | {
1353
+ } | {
1354
1354
  type: "read only";
1355
1355
  } | {
1356
1356
  type: "ready";
@@ -1360,19 +1360,19 @@ declare const editorMachine: xstate241.StateMachine<{
1360
1360
  } | {
1361
1361
  type: "value changed";
1362
1362
  value: Array<PortableTextBlock> | undefined;
1363
- } | InternalPatchEvent | PatchesEvent, xstate241.MetaObject, {
1363
+ }, xstate227.MetaObject, {
1364
1364
  readonly id: "editor";
1365
1365
  readonly context: ({
1366
1366
  input
1367
1367
  }: {
1368
1368
  spawn: {
1369
- <TSrc extends never>(logic: TSrc, ...[options]: never): xstate241.ActorRefFromLogic<never>;
1370
- <TLogic extends xstate241.AnyActorLogic>(src: TLogic, ...[options]: xstate241.ConditionalRequired<[options?: ({
1369
+ <TSrc extends never>(logic: TSrc, ...[options]: never): xstate227.ActorRefFromLogic<never>;
1370
+ <TLogic extends xstate227.AnyActorLogic>(src: TLogic, ...[options]: xstate227.ConditionalRequired<[options?: ({
1371
1371
  id?: never;
1372
1372
  systemId?: string;
1373
- input?: xstate241.InputFrom<TLogic> | undefined;
1373
+ input?: xstate227.InputFrom<TLogic> | undefined;
1374
1374
  syncSnapshot?: boolean;
1375
- } & { [K in xstate241.RequiredLogicInput<TLogic>]: unknown }) | undefined], xstate241.IsNotNever<xstate241.RequiredLogicInput<TLogic>>>): xstate241.ActorRefFromLogic<TLogic>;
1375
+ } & { [K in xstate227.RequiredLogicInput<TLogic>]: unknown }) | undefined], xstate227.IsNotNever<xstate227.RequiredLogicInput<TLogic>>>): xstate227.ActorRefFromLogic<TLogic>;
1376
1376
  };
1377
1377
  input: {
1378
1378
  converters?: Array<Converter>;
@@ -1383,7 +1383,7 @@ declare const editorMachine: xstate241.StateMachine<{
1383
1383
  schema: EditorSchema;
1384
1384
  initialValue?: Array<PortableTextBlock>;
1385
1385
  };
1386
- self: xstate241.ActorRef<xstate241.MachineSnapshot<{
1386
+ self: xstate227.ActorRef<xstate227.MachineSnapshot<{
1387
1387
  behaviors: Set<BehaviorConfig>;
1388
1388
  behaviorsSorted: boolean;
1389
1389
  converters: Set<Converter>;
@@ -1401,7 +1401,7 @@ declare const editorMachine: xstate241.StateMachine<{
1401
1401
  };
1402
1402
  dragGhost?: HTMLElement;
1403
1403
  slateEditor?: PortableTextSlateEditor;
1404
- }, MutationEvent | InternalPatchEvent | PatchesEvent | {
1404
+ }, InternalPatchEvent | MutationEvent | PatchesEvent | {
1405
1405
  type: "update readOnly";
1406
1406
  readOnly: boolean;
1407
1407
  } | {
@@ -1448,7 +1448,7 @@ declare const editorMachine: xstate241.StateMachine<{
1448
1448
  type: "dragend";
1449
1449
  } | {
1450
1450
  type: "drop";
1451
- }, Record<string, xstate241.AnyActorRef | undefined>, xstate241.StateValue, string, unknown, any, any>, MutationEvent | InternalPatchEvent | PatchesEvent | {
1451
+ }, Record<string, xstate227.AnyActorRef | undefined>, xstate227.StateValue, string, unknown, any, any>, InternalPatchEvent | MutationEvent | PatchesEvent | {
1452
1452
  type: "update readOnly";
1453
1453
  readOnly: boolean;
1454
1454
  } | {
@@ -1495,10 +1495,10 @@ declare const editorMachine: xstate241.StateMachine<{
1495
1495
  type: "dragend";
1496
1496
  } | {
1497
1497
  type: "drop";
1498
- }, xstate241.AnyEventObject>;
1498
+ }, xstate227.AnyEventObject>;
1499
1499
  }) => {
1500
1500
  behaviors: Set<{
1501
- 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.*" | "style.*" | "delete.*" | "select.*" | "deserialize.*" | "serialize.*" | "annotation.*" | "block.*" | "child.*" | "decorator.*" | "insert.*" | "move.*" | "deserialization.*" | "list item.*" | "serialization.*" | "clipboard.*" | "drag.*" | "keyboard.*" | "mouse.*", true, {
1501
+ 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, {
1502
1502
  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">;
1503
1503
  annotation: {
1504
1504
  name: string;
@@ -1797,7 +1797,7 @@ declare const editorMachine: xstate241.StateMachine<{
1797
1797
  readonly actions: "remove behavior from context";
1798
1798
  };
1799
1799
  readonly 'update maxBlocks': {
1800
- readonly actions: xstate241.ActionFunction<{
1800
+ readonly actions: xstate227.ActionFunction<{
1801
1801
  behaviors: Set<BehaviorConfig>;
1802
1802
  behaviorsSorted: boolean;
1803
1803
  converters: Set<Converter>;
@@ -1818,7 +1818,7 @@ declare const editorMachine: xstate241.StateMachine<{
1818
1818
  }, {
1819
1819
  type: "update maxBlocks";
1820
1820
  maxBlocks: number | undefined;
1821
- }, MutationEvent | InternalPatchEvent | PatchesEvent | {
1821
+ }, InternalPatchEvent | MutationEvent | PatchesEvent | {
1822
1822
  type: "update readOnly";
1823
1823
  readOnly: boolean;
1824
1824
  } | {
@@ -1868,7 +1868,7 @@ declare const editorMachine: xstate241.StateMachine<{
1868
1868
  }, undefined, never, never, never, never, never>;
1869
1869
  };
1870
1870
  readonly 'update selection': {
1871
- readonly actions: readonly [xstate241.ActionFunction<{
1871
+ readonly actions: readonly [xstate227.ActionFunction<{
1872
1872
  behaviors: Set<BehaviorConfig>;
1873
1873
  behaviorsSorted: boolean;
1874
1874
  converters: Set<Converter>;
@@ -1889,7 +1889,7 @@ declare const editorMachine: xstate241.StateMachine<{
1889
1889
  }, {
1890
1890
  type: "update selection";
1891
1891
  selection: EditorSelection;
1892
- }, MutationEvent | InternalPatchEvent | PatchesEvent | {
1892
+ }, InternalPatchEvent | MutationEvent | PatchesEvent | {
1893
1893
  type: "update readOnly";
1894
1894
  readOnly: boolean;
1895
1895
  } | {
@@ -1936,7 +1936,7 @@ declare const editorMachine: xstate241.StateMachine<{
1936
1936
  type: "dragend";
1937
1937
  } | {
1938
1938
  type: "drop";
1939
- }, undefined, never, never, never, never, never>, xstate241.ActionFunction<{
1939
+ }, undefined, never, never, never, never, never>, xstate227.ActionFunction<{
1940
1940
  behaviors: Set<BehaviorConfig>;
1941
1941
  behaviorsSorted: boolean;
1942
1942
  converters: Set<Converter>;
@@ -1957,7 +1957,7 @@ declare const editorMachine: xstate241.StateMachine<{
1957
1957
  }, {
1958
1958
  type: "update selection";
1959
1959
  selection: EditorSelection;
1960
- }, MutationEvent | InternalPatchEvent | PatchesEvent | {
1960
+ }, InternalPatchEvent | MutationEvent | PatchesEvent | {
1961
1961
  type: "update readOnly";
1962
1962
  readOnly: boolean;
1963
1963
  } | {
@@ -2004,9 +2004,9 @@ declare const editorMachine: xstate241.StateMachine<{
2004
2004
  type: "dragend";
2005
2005
  } | {
2006
2006
  type: "drop";
2007
- }, undefined, never, never, never, never, {
2007
+ }, undefined, never, never, never, never, InternalPatchEvent | MutationEvent | PatchesEvent | {
2008
2008
  type: "blurred";
2009
- event: react20.FocusEvent<HTMLDivElement, Element>;
2009
+ event: react22.FocusEvent<HTMLDivElement, Element>;
2010
2010
  } | {
2011
2011
  type: "done loading";
2012
2012
  } | {
@@ -2018,14 +2018,14 @@ declare const editorMachine: xstate241.StateMachine<{
2018
2018
  data: unknown;
2019
2019
  } | {
2020
2020
  type: "focused";
2021
- event: react20.FocusEvent<HTMLDivElement, Element>;
2021
+ event: react22.FocusEvent<HTMLDivElement, Element>;
2022
2022
  } | {
2023
2023
  type: "invalid value";
2024
2024
  resolution: InvalidValueResolution | null;
2025
2025
  value: Array<PortableTextBlock> | undefined;
2026
2026
  } | {
2027
2027
  type: "loading";
2028
- } | MutationEvent | {
2028
+ } | {
2029
2029
  type: "read only";
2030
2030
  } | {
2031
2031
  type: "ready";
@@ -2035,10 +2035,10 @@ declare const editorMachine: xstate241.StateMachine<{
2035
2035
  } | {
2036
2036
  type: "value changed";
2037
2037
  value: Array<PortableTextBlock> | undefined;
2038
- } | InternalPatchEvent | PatchesEvent>];
2038
+ }>];
2039
2039
  };
2040
2040
  readonly 'set drag ghost': {
2041
- readonly actions: xstate241.ActionFunction<{
2041
+ readonly actions: xstate227.ActionFunction<{
2042
2042
  behaviors: Set<BehaviorConfig>;
2043
2043
  behaviorsSorted: boolean;
2044
2044
  converters: Set<Converter>;
@@ -2059,7 +2059,7 @@ declare const editorMachine: xstate241.StateMachine<{
2059
2059
  }, {
2060
2060
  type: "set drag ghost";
2061
2061
  ghost: HTMLElement;
2062
- }, MutationEvent | InternalPatchEvent | PatchesEvent | {
2062
+ }, InternalPatchEvent | MutationEvent | PatchesEvent | {
2063
2063
  type: "update readOnly";
2064
2064
  readOnly: boolean;
2065
2065
  } | {
@@ -2121,7 +2121,7 @@ declare const editorMachine: xstate241.StateMachine<{
2121
2121
  readonly actions: readonly ["sort behaviors", "handle behavior event"];
2122
2122
  readonly guard: ({
2123
2123
  event
2124
- }: xstate_guards14.GuardArgs<{
2124
+ }: xstate_guards12.GuardArgs<{
2125
2125
  behaviors: Set<BehaviorConfig>;
2126
2126
  behaviorsSorted: boolean;
2127
2127
  converters: Set<Converter>;
@@ -2158,7 +2158,7 @@ declare const editorMachine: xstate241.StateMachine<{
2158
2158
  readonly target: "#editor.edit mode.read only.read only";
2159
2159
  readonly guard: ({
2160
2160
  context
2161
- }: xstate_guards14.GuardArgs<{
2161
+ }: xstate_guards12.GuardArgs<{
2162
2162
  behaviors: Set<BehaviorConfig>;
2163
2163
  behaviorsSorted: boolean;
2164
2164
  converters: Set<Converter>;
@@ -2191,7 +2191,7 @@ declare const editorMachine: xstate241.StateMachine<{
2191
2191
  readonly 'update readOnly': {
2192
2192
  readonly guard: ({
2193
2193
  event
2194
- }: xstate_guards14.GuardArgs<{
2194
+ }: xstate_guards12.GuardArgs<{
2195
2195
  behaviors: Set<BehaviorConfig>;
2196
2196
  behaviorsSorted: boolean;
2197
2197
  converters: Set<Converter>;
@@ -2225,7 +2225,7 @@ declare const editorMachine: xstate241.StateMachine<{
2225
2225
  readonly 'update readOnly': {
2226
2226
  readonly guard: ({
2227
2227
  event
2228
- }: xstate_guards14.GuardArgs<{
2228
+ }: xstate_guards12.GuardArgs<{
2229
2229
  behaviors: Set<BehaviorConfig>;
2230
2230
  behaviorsSorted: boolean;
2231
2231
  converters: Set<Converter>;
@@ -2258,7 +2258,7 @@ declare const editorMachine: xstate241.StateMachine<{
2258
2258
  };
2259
2259
  readonly focus: {
2260
2260
  readonly target: ".focusing";
2261
- readonly actions: readonly [xstate241.ActionFunction<{
2261
+ readonly actions: readonly [xstate227.ActionFunction<{
2262
2262
  behaviors: Set<BehaviorConfig>;
2263
2263
  behaviorsSorted: boolean;
2264
2264
  converters: Set<Converter>;
@@ -2279,7 +2279,7 @@ declare const editorMachine: xstate241.StateMachine<{
2279
2279
  }, {
2280
2280
  type: "focus";
2281
2281
  editor: PortableTextSlateEditor;
2282
- }, MutationEvent | InternalPatchEvent | PatchesEvent | {
2282
+ }, InternalPatchEvent | MutationEvent | PatchesEvent | {
2283
2283
  type: "update readOnly";
2284
2284
  readOnly: boolean;
2285
2285
  } | {
@@ -2336,7 +2336,7 @@ declare const editorMachine: xstate241.StateMachine<{
2336
2336
  readonly exit: readonly [() => void];
2337
2337
  readonly on: {
2338
2338
  readonly dragstart: {
2339
- readonly actions: readonly [xstate241.ActionFunction<{
2339
+ readonly actions: readonly [xstate227.ActionFunction<{
2340
2340
  behaviors: Set<BehaviorConfig>;
2341
2341
  behaviorsSorted: boolean;
2342
2342
  converters: Set<Converter>;
@@ -2358,7 +2358,7 @@ declare const editorMachine: xstate241.StateMachine<{
2358
2358
  type: "dragstart";
2359
2359
  ghost?: HTMLElement;
2360
2360
  origin: Pick<EventPosition, "selection">;
2361
- }, MutationEvent | InternalPatchEvent | PatchesEvent | {
2361
+ }, InternalPatchEvent | MutationEvent | PatchesEvent | {
2362
2362
  type: "update readOnly";
2363
2363
  readOnly: boolean;
2364
2364
  } | {
@@ -2439,7 +2439,7 @@ declare const editorMachine: xstate241.StateMachine<{
2439
2439
  readonly entry: readonly [() => void];
2440
2440
  readonly exit: readonly [() => void, ({
2441
2441
  context
2442
- }: xstate241.ActionArgs<{
2442
+ }: xstate227.ActionArgs<{
2443
2443
  behaviors: Set<BehaviorConfig>;
2444
2444
  behaviorsSorted: boolean;
2445
2445
  converters: Set<Converter>;
@@ -2457,7 +2457,7 @@ declare const editorMachine: xstate241.StateMachine<{
2457
2457
  };
2458
2458
  dragGhost?: HTMLElement;
2459
2459
  slateEditor?: PortableTextSlateEditor;
2460
- }, MutationEvent | InternalPatchEvent | PatchesEvent | {
2460
+ }, InternalPatchEvent | MutationEvent | PatchesEvent | {
2461
2461
  type: "update readOnly";
2462
2462
  readOnly: boolean;
2463
2463
  } | {
@@ -2504,7 +2504,7 @@ declare const editorMachine: xstate241.StateMachine<{
2504
2504
  type: "dragend";
2505
2505
  } | {
2506
2506
  type: "drop";
2507
- }, MutationEvent | InternalPatchEvent | PatchesEvent | {
2507
+ }, InternalPatchEvent | MutationEvent | PatchesEvent | {
2508
2508
  type: "update readOnly";
2509
2509
  readOnly: boolean;
2510
2510
  } | {
@@ -2551,7 +2551,7 @@ declare const editorMachine: xstate241.StateMachine<{
2551
2551
  type: "dragend";
2552
2552
  } | {
2553
2553
  type: "drop";
2554
- }>) => void, xstate241.ActionFunction<{
2554
+ }>) => void, xstate227.ActionFunction<{
2555
2555
  behaviors: Set<BehaviorConfig>;
2556
2556
  behaviorsSorted: boolean;
2557
2557
  converters: Set<Converter>;
@@ -2569,7 +2569,7 @@ declare const editorMachine: xstate241.StateMachine<{
2569
2569
  };
2570
2570
  dragGhost?: HTMLElement;
2571
2571
  slateEditor?: PortableTextSlateEditor;
2572
- }, MutationEvent | InternalPatchEvent | PatchesEvent | {
2572
+ }, InternalPatchEvent | MutationEvent | PatchesEvent | {
2573
2573
  type: "update readOnly";
2574
2574
  readOnly: boolean;
2575
2575
  } | {
@@ -2616,7 +2616,7 @@ declare const editorMachine: xstate241.StateMachine<{
2616
2616
  type: "dragend";
2617
2617
  } | {
2618
2618
  type: "drop";
2619
- }, MutationEvent | InternalPatchEvent | PatchesEvent | {
2619
+ }, InternalPatchEvent | MutationEvent | PatchesEvent | {
2620
2620
  type: "update readOnly";
2621
2621
  readOnly: boolean;
2622
2622
  } | {
@@ -2663,7 +2663,7 @@ declare const editorMachine: xstate241.StateMachine<{
2663
2663
  type: "dragend";
2664
2664
  } | {
2665
2665
  type: "drop";
2666
- }, undefined, never, never, never, never, never>, xstate241.ActionFunction<{
2666
+ }, undefined, never, never, never, never, never>, xstate227.ActionFunction<{
2667
2667
  behaviors: Set<BehaviorConfig>;
2668
2668
  behaviorsSorted: boolean;
2669
2669
  converters: Set<Converter>;
@@ -2681,7 +2681,7 @@ declare const editorMachine: xstate241.StateMachine<{
2681
2681
  };
2682
2682
  dragGhost?: HTMLElement;
2683
2683
  slateEditor?: PortableTextSlateEditor;
2684
- }, MutationEvent | InternalPatchEvent | PatchesEvent | {
2684
+ }, InternalPatchEvent | MutationEvent | PatchesEvent | {
2685
2685
  type: "update readOnly";
2686
2686
  readOnly: boolean;
2687
2687
  } | {
@@ -2728,7 +2728,7 @@ declare const editorMachine: xstate241.StateMachine<{
2728
2728
  type: "dragend";
2729
2729
  } | {
2730
2730
  type: "drop";
2731
- }, MutationEvent | InternalPatchEvent | PatchesEvent | {
2731
+ }, InternalPatchEvent | MutationEvent | PatchesEvent | {
2732
2732
  type: "update readOnly";
2733
2733
  readOnly: boolean;
2734
2734
  } | {
@@ -2822,7 +2822,7 @@ declare const editorMachine: xstate241.StateMachine<{
2822
2822
  readonly exit: readonly [() => void];
2823
2823
  readonly on: {
2824
2824
  readonly patches: {
2825
- readonly actions: readonly [xstate241.ActionFunction<{
2825
+ readonly actions: readonly [xstate227.ActionFunction<{
2826
2826
  behaviors: Set<BehaviorConfig>;
2827
2827
  behaviorsSorted: boolean;
2828
2828
  converters: Set<Converter>;
@@ -2840,7 +2840,7 @@ declare const editorMachine: xstate241.StateMachine<{
2840
2840
  };
2841
2841
  dragGhost?: HTMLElement;
2842
2842
  slateEditor?: PortableTextSlateEditor;
2843
- }, PatchesEvent, MutationEvent | InternalPatchEvent | PatchesEvent | {
2843
+ }, PatchesEvent, InternalPatchEvent | MutationEvent | PatchesEvent | {
2844
2844
  type: "update readOnly";
2845
2845
  readOnly: boolean;
2846
2846
  } | {
@@ -2887,9 +2887,9 @@ declare const editorMachine: xstate241.StateMachine<{
2887
2887
  type: "dragend";
2888
2888
  } | {
2889
2889
  type: "drop";
2890
- }, undefined, never, never, never, never, {
2890
+ }, undefined, never, never, never, never, InternalPatchEvent | MutationEvent | PatchesEvent | {
2891
2891
  type: "blurred";
2892
- event: react20.FocusEvent<HTMLDivElement, Element>;
2892
+ event: react22.FocusEvent<HTMLDivElement, Element>;
2893
2893
  } | {
2894
2894
  type: "done loading";
2895
2895
  } | {
@@ -2901,14 +2901,14 @@ declare const editorMachine: xstate241.StateMachine<{
2901
2901
  data: unknown;
2902
2902
  } | {
2903
2903
  type: "focused";
2904
- event: react20.FocusEvent<HTMLDivElement, Element>;
2904
+ event: react22.FocusEvent<HTMLDivElement, Element>;
2905
2905
  } | {
2906
2906
  type: "invalid value";
2907
2907
  resolution: InvalidValueResolution | null;
2908
2908
  value: Array<PortableTextBlock> | undefined;
2909
2909
  } | {
2910
2910
  type: "loading";
2911
- } | MutationEvent | {
2911
+ } | {
2912
2912
  type: "read only";
2913
2913
  } | {
2914
2914
  type: "ready";
@@ -2918,7 +2918,7 @@ declare const editorMachine: xstate241.StateMachine<{
2918
2918
  } | {
2919
2919
  type: "value changed";
2920
2920
  value: Array<PortableTextBlock> | undefined;
2921
- } | InternalPatchEvent | PatchesEvent>];
2921
+ }>];
2922
2922
  };
2923
2923
  readonly 'syncing value': {
2924
2924
  readonly target: "syncing value";
@@ -1498,7 +1498,7 @@ declare const editorMachine: xstate227.StateMachine<{
1498
1498
  }, xstate227.AnyEventObject>;
1499
1499
  }) => {
1500
1500
  behaviors: Set<{
1501
- 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, {
1501
+ 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, {
1502
1502
  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">;
1503
1503
  annotation: {
1504
1504
  name: string;