@lofcz/platejs-core 53.1.6 → 53.1.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,46 +1,47 @@
1
- import { Ai as AnySlatePlugin, Ct as NodeComponents, Et as PluginConfig, F as RenderLeafProps, I as RenderElementFn, J as BaseEditor, Kr as NavigationFeedbackActiveTarget, L as RenderElementProps, M as RenderTextFn, N as RenderTextProps, Ot as WithAnyKey, P as RenderLeafFn, Pi as ExtendEditor$1, Q as SlateEditor, R as RenderChunkFn, St as NodeComponent, Tt as ParserOptions, U as BaseWithSlateOptions, Y as InferPlugins, Ya as createStaticEditor, _a as InputRulesConfig, _t as InferOptions, at as BasePluginContext, bt as MatchRules, ct as BaseTransformOptions, ea as SlatePlugin, ei as AutoScrollOperationsMap, et as AnyPluginConfig, fi as InsertExitBreakOptions, gt as InferKey, hr as CorePluginTransforms, ht as InferApi, ii as WithAutoScrollOptions, it as BasePlugin, j as EditableProps, ja as ResolvedInputRulesMeta, ko as HandlerReturnType, kt as WithRequiredKey, mi as InitOptions, mr as CorePluginApi, mt as GetInjectNodePropsReturnType, na as SlatePluginContext, ni as DomConfig, nt as BaseHtmlDeserializer, pr as CorePlugin, pt as GetInjectNodePropsOptions, qr as NavigationFeedbackConfig, ri as ScrollMode, rt as BaseInjectProps, st as BaseSerializer, ta as SlatePluginConfig, tt as BaseDeserializer, ui as LiftBlockOptions, va as InputRulesDefinition, vt as InferSelectors, yo as PlateStaticProps, yt as InferTransforms, z as RenderChunkProps } from "../index-BooMghRU";
2
- import * as _platejs_slate15 from "@platejs/slate";
1
+ import { Ct as NodeComponents, Et as PluginConfig, F as RenderLeafProps, Fi as ExtendEditor$1, I as RenderElementFn, J as BaseEditor, Jr as NavigationFeedbackConfig, L as RenderElementProps, M as RenderTextFn, N as RenderTextProps, Na as ResolvedInputRulesMeta, Ot as WithAnyKey, P as RenderLeafFn, Q as SlateEditor, R as RenderChunkFn, St as NodeComponent, Tt as ParserOptions, U as BaseWithSlateOptions, Y as InferPlugins, Za as createStaticEditor, _t as InferOptions, at as BasePluginContext, ba as InputRulesDefinition, bt as MatchRules, ci as InitOptions, ct as BaseTransformOptions, di as AutoScrollOperationsMap, et as AnyPluginConfig, gt as InferKey, hi as WithAutoScrollOptions, hr as CorePluginTransforms, ht as InferApi, ii as LiftBlockOptions, it as BasePlugin, j as EditableProps, ji as AnySlatePlugin, jo as HandlerReturnType, kt as WithRequiredKey, mi as ScrollMode, mr as CorePluginApi, mt as GetInjectNodePropsReturnType, na as SlatePluginConfig, nt as BaseHtmlDeserializer, oi as InsertExitBreakOptions, pi as DomConfig, pr as CorePlugin, pt as GetInjectNodePropsOptions, qr as NavigationFeedbackActiveTarget, ra as SlatePluginContext, rt as BaseInjectProps, st as BaseSerializer, ta as SlatePlugin, tt as BaseDeserializer, vt as InferSelectors, xo as PlateStaticProps, ya as InputRulesConfig, yt as InferTransforms, z as RenderChunkProps } from "../index-BDSzA1zP";
2
+ import * as _platejs_slate4 from "@platejs/slate";
3
3
  import { DecoratedRange, Descendant, DescendantIn, Editor, EditorApi, EditorTransforms, ElementEntry, NodeEntry, NodeOperation, Operation, Path, TElement, TNode, TRange, TSelection, TText, TextOperation, Value, ValueOf } from "@platejs/slate";
4
4
  import { AnyObject, Deep2Partial, Modify, Nullable, UnionToIntersection, UnknownObject } from "@udecode/utils";
5
5
  import { DefaultPlaceholder, Editable, RenderPlaceholderProps, Slate, useComposing, useFocused, useReadOnly, useSelected, useSlateStatic, withReact } from "slate-react";
6
- import React$1, { HTMLAttributes } from "react";
6
+ import React$1, { DependencyList, HTMLAttributes } from "react";
7
7
  import { HotkeysEvent, HotkeysOptions, Keys } from "@udecode/react-hotkeys";
8
- import * as jotai_x0 from "jotai-x";
9
- import { JotaiStore, createAtomStore, useStoreAtomState, useStoreAtomValue, useStoreSetAtom } from "jotai-x";
10
8
  import * as jotai10 from "jotai";
11
9
  import { Atom, atom } from "jotai";
10
+ import * as jotai_x2 from "jotai-x";
11
+ import { JotaiStore, createAtomStore, useStoreAtomState, useStoreAtomValue, useStoreSetAtom } from "jotai-x";
12
12
  import * as zustand_x0 from "zustand-x";
13
13
  import { TCreatedStoreType, TEqualityChecker, createZustandStore, useStoreSelect, useStoreState, useStoreValue, useTracked, useTrackedStore } from "zustand-x";
14
+ import { createStore } from "jotai/vanilla";
14
15
 
15
16
  //#region src/react/plugins/SlateReactExtensionPlugin.d.ts
16
17
  declare const SlateReactExtensionPlugin: PlatePlugin<PluginConfig<"slateExtension", {
17
18
  onNodeChange: (options: {
18
19
  editor: SlateEditor;
19
- node: _platejs_slate15.Descendant;
20
- operation: _platejs_slate15.NodeOperation;
21
- prevNode: _platejs_slate15.Descendant;
20
+ node: _platejs_slate4.Descendant;
21
+ operation: _platejs_slate4.NodeOperation;
22
+ prevNode: _platejs_slate4.Descendant;
22
23
  }) => void;
23
24
  onTextChange: (options: {
24
25
  editor: SlateEditor;
25
- node: _platejs_slate15.Descendant;
26
- operation: _platejs_slate15.TextOperation;
26
+ node: _platejs_slate4.Descendant;
27
+ operation: _platejs_slate4.TextOperation;
27
28
  prevText: string;
28
29
  text: string;
29
30
  }) => void;
30
31
  }, {
31
32
  redecorate: (() => void) & (() => void);
32
33
  }, {
33
- reset: (options: _platejs_slate15.ResetOptions | undefined) => void;
34
+ reset: (options: _platejs_slate4.ResetOptions | undefined) => void;
34
35
  init: ((args_0: InitOptions) => void) & ((args_0: InitOptions) => void);
35
36
  insertExitBreak: ((args_0?: InsertExitBreakOptions | undefined) => true | undefined) & ((args_0?: InsertExitBreakOptions | undefined) => true | undefined);
36
37
  liftBlock: ((args_0?: LiftBlockOptions | undefined) => true | undefined) & ((args_0?: LiftBlockOptions | undefined) => true | undefined);
37
38
  resetBlock: ((args_0?: {
38
- at?: _platejs_slate15.Path;
39
+ at?: _platejs_slate4.Path;
39
40
  } | undefined) => true | undefined) & ((args_0?: {
40
- at?: _platejs_slate15.Path;
41
+ at?: _platejs_slate4.Path;
41
42
  } | undefined) => true | undefined);
42
- setValue: ((value?: string | _platejs_slate15.Value | undefined) => void) & ((value?: string | _platejs_slate15.Value | undefined) => void);
43
- apply: <N$1 extends _platejs_slate15.TElement | _platejs_slate15.TText>(operation: _platejs_slate15.Operation<N$1>) => void;
43
+ setValue: ((value?: string | _platejs_slate4.Value | undefined) => void) & ((value?: string | _platejs_slate4.Value | undefined) => void);
44
+ apply: <N$1 extends _platejs_slate4.TElement | _platejs_slate4.TText>(operation: _platejs_slate4.Operation<N$1>) => void;
44
45
  }, {}>>;
45
46
  //#endregion
46
47
  //#region src/react/plugins/event-editor/EventEditorPlugin.d.ts
@@ -100,7 +101,7 @@ declare const ParagraphPlugin: PlatePlugin<PluginConfig<"p", {}, {}, {}, {}>>;
100
101
  declare const ReactPlugin: PlatePlugin<PluginConfig<"dom", {
101
102
  scrollMode?: ScrollMode;
102
103
  scrollOperations?: AutoScrollOperationsMap;
103
- scrollOptions?: _platejs_slate15.ScrollIntoViewOptions;
104
+ scrollOptions?: _platejs_slate4.ScrollIntoViewOptions;
104
105
  }, {
105
106
  isScrolling: () => boolean;
106
107
  }, {
@@ -112,7 +113,7 @@ declare const withPlateReact: ExtendEditor$1<DomConfig>;
112
113
  //#endregion
113
114
  //#region src/react/editor/withPlate.d.ts
114
115
  type PlateCorePlugin = CorePlugin | typeof EventEditorPlugin | typeof SlateReactExtensionPlugin;
115
- type WithPlateOptions<V$1 extends Value = Value, P$1 extends AnyPluginConfig = PlateCorePlugin> = BaseWithSlateOptions<P$1> & Pick<Partial<AnyPlatePlugin>, 'api' | 'decorate' | 'extendEditor' | 'handlers' | 'inject' | 'normalizeInitialValue' | 'options' | 'override' | 'priority' | 'render' | 'shortcuts' | 'transforms' | 'useHooks'> & {
116
+ type WithPlateOptions<V$1 extends Value = Value, P$1 extends AnyPluginConfig = PlateCorePlugin> = BaseWithSlateOptions<P$1> & Pick<Partial<AnyPlatePlugin>, 'api' | 'decorate' | 'extendEditor' | 'handlers' | 'inject' | 'transformInitialValue' | 'normalizeInitialValue' | 'options' | 'override' | 'priority' | 'render' | 'shortcuts' | 'transforms' | 'useHooks'> & {
116
117
  value?: ((editor: PlateEditor) => Promise<V$1> | V$1) | V$1 | string;
117
118
  rootPlugin?: (plugin: AnyPlatePlugin) => AnyPlatePlugin;
118
119
  onReady?: (ctx: {
@@ -307,9 +308,13 @@ interface NodeWrapperComponentProps<C extends AnyPluginConfig = PluginConfig> ex
307
308
  }
308
309
  /** @deprecated Use {@link RenderNodeWrapperFunction} instead. */
309
310
  type NodeWrapperComponentReturnType<C extends AnyPluginConfig = PluginConfig> = React$1.FC<PlateElementProps<TElement, C>> | undefined;
311
+ type TransformInitialValue<C extends AnyPluginConfig = PluginConfig> = (ctx: PlatePluginContext<C> & {
312
+ value: Value;
313
+ }) => Value;
314
+ /** @deprecated Use {@link TransformInitialValue} instead. */
310
315
  type NormalizeInitialValue<C extends AnyPluginConfig = PluginConfig> = (ctx: PlatePluginContext<C> & {
311
316
  value: Value;
312
- }) => void;
317
+ }) => Value | void;
313
318
  /**
314
319
  * Function called whenever a change occurs in the editor. Return `false` to
315
320
  * prevent calling the next plugin handler.
@@ -378,7 +383,10 @@ type PlatePlugin<C extends AnyPluginConfig = PluginConfig> = BasePlugin<C> & Nul
378
383
  decorate?: Decorate<WithAnyKey<C>>;
379
384
  /** @see {@link ExtendEditor} */
380
385
  extendEditor?: ExtendEditor<WithAnyKey<C>>;
386
+ /** Transform the initial value before the editor is ready. */
387
+ transformInitialValue?: TransformInitialValue<WithAnyKey<C>>;
381
388
  /** Normalize initial value before passing it into the editor. */
389
+ /** @deprecated Use `transformInitialValue` instead. */
382
390
  normalizeInitialValue?: NormalizeInitialValue<WithAnyKey<C>>;
383
391
  /** @see {@link UseHooks} */
384
392
  useHooks?: UseHooks<WithAnyKey<C>>;
@@ -810,35 +818,35 @@ declare const getPlateCorePlugins: ({
810
818
  }) => (PlatePlugin<PluginConfig<"eventEditor", {}, {}, {}, {}>> | PlatePlugin<PluginConfig<"slateExtension", {
811
819
  onNodeChange: (options: {
812
820
  editor: SlateEditor;
813
- node: _platejs_slate15.Descendant;
814
- operation: _platejs_slate15.NodeOperation;
815
- prevNode: _platejs_slate15.Descendant;
821
+ node: _platejs_slate4.Descendant;
822
+ operation: _platejs_slate4.NodeOperation;
823
+ prevNode: _platejs_slate4.Descendant;
816
824
  }) => void;
817
825
  onTextChange: (options: {
818
826
  editor: SlateEditor;
819
- node: _platejs_slate15.Descendant;
820
- operation: _platejs_slate15.TextOperation;
827
+ node: _platejs_slate4.Descendant;
828
+ operation: _platejs_slate4.TextOperation;
821
829
  prevText: string;
822
830
  text: string;
823
831
  }) => void;
824
832
  }, {
825
833
  redecorate: (() => void) & (() => void);
826
834
  }, {
827
- reset: (options: _platejs_slate15.ResetOptions | undefined) => void;
835
+ reset: (options: _platejs_slate4.ResetOptions | undefined) => void;
828
836
  init: ((args_0: InitOptions) => void) & ((args_0: InitOptions) => void);
829
837
  insertExitBreak: ((args_0?: InsertExitBreakOptions | undefined) => true | undefined) & ((args_0?: InsertExitBreakOptions | undefined) => true | undefined);
830
838
  liftBlock: ((args_0?: LiftBlockOptions | undefined) => true | undefined) & ((args_0?: LiftBlockOptions | undefined) => true | undefined);
831
839
  resetBlock: ((args_0?: {
832
- at?: _platejs_slate15.Path;
840
+ at?: _platejs_slate4.Path;
833
841
  } | undefined) => true | undefined) & ((args_0?: {
834
- at?: _platejs_slate15.Path;
842
+ at?: _platejs_slate4.Path;
835
843
  } | undefined) => true | undefined);
836
- setValue: ((value?: string | _platejs_slate15.Value | undefined) => void) & ((value?: string | _platejs_slate15.Value | undefined) => void);
837
- apply: <N$1 extends _platejs_slate15.TElement | _platejs_slate15.TText>(operation: _platejs_slate15.Operation<N$1>) => void;
844
+ setValue: ((value?: string | _platejs_slate4.Value | undefined) => void) & ((value?: string | _platejs_slate4.Value | undefined) => void);
845
+ apply: <N$1 extends _platejs_slate4.TElement | _platejs_slate4.TText>(operation: _platejs_slate4.Operation<N$1>) => void;
838
846
  }, {}>> | PlatePlugin<PluginConfig<"dom", {
839
847
  scrollMode?: ScrollMode;
840
848
  scrollOperations?: AutoScrollOperationsMap;
841
- scrollOptions?: _platejs_slate15.ScrollIntoViewOptions;
849
+ scrollOptions?: _platejs_slate4.ScrollIntoViewOptions;
842
850
  }, {
843
851
  isScrolling: () => boolean;
844
852
  }, {
@@ -908,7 +916,7 @@ declare function getPlugin<C extends AnyPluginConfig = PluginConfig>(editor: Pla
908
916
  } ? C : PlatePlugin<C>;
909
917
  //#endregion
910
918
  //#region src/react/plugin/omitPluginContext.d.ts
911
- declare const omitPluginContext: <T extends PlatePluginContext<AnyPlatePlugin>>(ctx: T) => Omit<T, "api" | "editor" | "getOptions" | "getOption" | "tf" | "type" | "setOptions" | "setOption" | "plugin">;
919
+ declare const omitPluginContext: <T extends PlatePluginContext<AnyPlatePlugin>>(ctx: T) => Omit<T, "api" | "editor" | "type" | "getOption" | "tf" | "setOptions" | "getOptions" | "setOption" | "plugin">;
912
920
  //#endregion
913
921
  //#region src/react/plugin/toPlatePlugin.d.ts
914
922
  type PlatePluginConfig$1<C extends AnyPluginConfig, EO = {}, EA = {}, ET = {}, ES = {}> = Omit<Partial<PlatePlugin<PluginConfig<C['key'], EO & InferOptions<C>, EA & InferApi<C>, ET & InferTransforms<C>, ES & InferSelectors<C>>>>, keyof PlatePluginMethods | 'api' | 'node' | 'options' | 'transforms'> & {
@@ -951,6 +959,8 @@ declare function toTPlatePlugin<C extends AnyPluginConfig = PluginConfig, TConte
951
959
  //#endregion
952
960
  //#region src/react/components/plate-nodes.d.ts
953
961
  declare const useNodeAttributes: (props: any, ref?: any) => any;
962
+ declare const isHtmlVoidElementTag: (tag: keyof HTMLElementTagNameMap) => boolean;
963
+ declare const useBlockIdAttributeRef: <T extends HTMLElement>(blockId: unknown, ref?: React$1.Ref<T>) => (node: T) => (() => void) | undefined;
954
964
  type PlateChunkProps = RenderChunkProps;
955
965
  type PlateElementProps<N$1 extends TElement = TElement, C extends AnyPluginConfig = PluginConfig> = PlateNodeProps<C> & RenderElementProps<N$1> & {
956
966
  attributes: UnknownObject;
@@ -1053,7 +1063,7 @@ type UseElementSelectorOptions<T> = {
1053
1063
  key?: string;
1054
1064
  equalityFn?: (a: T, b: T) => boolean;
1055
1065
  };
1056
- declare const useElementSelector: <T>(selector: <N$1 extends TElement>(state: NodeEntry<N$1>, prev?: T) => T, deps: React$1.DependencyList, {
1066
+ declare const useElementSelector: <T>(selector: <N$1 extends TElement>(state: NodeEntry<N$1>, prev?: T) => T, deps: DependencyList, {
1057
1067
  key,
1058
1068
  equalityFn
1059
1069
  }?: UseElementSelectorOptions<T>) => T;
@@ -1065,11 +1075,37 @@ type ElementStoreState = {
1065
1075
  entry: ElementEntry;
1066
1076
  path: Path;
1067
1077
  };
1068
- declare const ElementProvider: React$1.FC<jotai_x0.ProviderProps<{
1069
- element: TElement;
1070
- entry: ElementEntry;
1071
- path: Path;
1072
- }>>, elementStore: jotai_x0.StoreApi<ElementStoreState, object, "element">, useElementStore: jotai_x0.UseStoreApi<ElementStoreState, object>;
1078
+ type ElementContextValue = Nullable<ElementStoreState> & {
1079
+ parent: ElementContextValue | null;
1080
+ scope?: string;
1081
+ };
1082
+ type ElementStoreContextValue = {
1083
+ parent: ElementStoreContextValue | null;
1084
+ runtime: ElementRuntimeStore;
1085
+ scope?: string;
1086
+ store: ReturnType<typeof createStore>;
1087
+ };
1088
+ type ElementRuntimeState = Nullable<ElementStoreState>;
1089
+ type ElementRuntimeStore = {
1090
+ getJotaiStore: () => ReturnType<typeof createStore>;
1091
+ getState: () => ElementRuntimeState;
1092
+ setState: (nextState: ElementRuntimeState) => void;
1093
+ subscribe: (listener: () => void) => () => void;
1094
+ };
1095
+ declare const elementStore: jotai_x2.StoreApi<ElementStoreState, object, "element">;
1096
+ declare const withElementContext: <T>(context: Omit<ElementContextValue, "parent">, callback: () => T) => T;
1097
+ declare const useElementContext: (scope?: string) => ElementContextValue | null;
1098
+ declare const useElementStoreContext: (scope?: string) => ElementStoreContextValue | null;
1099
+ declare const useElementStore: (scope?: string) => jotai_x2.ReturnOfUseStoreApi<ElementStoreState, object>;
1100
+ declare function ElementProvider({
1101
+ children,
1102
+ path,
1103
+ scope,
1104
+ ...props
1105
+ }: React$1.PropsWithChildren<Partial<ElementStoreState> & {
1106
+ scope?: string;
1107
+ }>): React$1.JSX.Element;
1108
+ declare function FirstBlockEffect(): null;
1073
1109
  //#endregion
1074
1110
  //#region src/react/stores/element/usePath.d.ts
1075
1111
  /** Get the memoized path of the closest element. */
@@ -1194,7 +1230,7 @@ declare const createPlateStore: <E extends PlateEditor = PlateEditor>({
1194
1230
  onTextChange,
1195
1231
  onValueChange,
1196
1232
  ...state
1197
- }?: Partial<PlateStoreState<E>>) => jotai_x0.AtomStoreApi<PlateStoreState<E>, {
1233
+ }?: Partial<PlateStoreState<E>>) => jotai_x2.AtomStoreApi<PlateStoreState<E>, {
1198
1234
  trackedEditor: jotai10.Atom<{
1199
1235
  editor: any;
1200
1236
  version: number | null;
@@ -1208,12 +1244,12 @@ declare const createPlateStore: <E extends PlateEditor = PlateEditor>({
1208
1244
  version: number | null;
1209
1245
  }>;
1210
1246
  }, "plate">;
1211
- declare const PlateStoreProvider: React$1.FC<jotai_x0.ProviderProps<{
1247
+ declare const PlateStoreProvider: React$1.FC<jotai_x2.ProviderProps<{
1212
1248
  composing: boolean | null;
1213
1249
  decorate: ((options: {
1214
1250
  editor: PlateEditor;
1215
- entry: _platejs_slate15.NodeEntry;
1216
- }) => _platejs_slate15.TRange[]) | null;
1251
+ entry: _platejs_slate4.NodeEntry;
1252
+ }) => _platejs_slate4.TRange[]) | null;
1217
1253
  isMounted: boolean | null;
1218
1254
  primary: boolean | null;
1219
1255
  readOnly: boolean | null;
@@ -1227,34 +1263,34 @@ declare const PlateStoreProvider: React$1.FC<jotai_x0.ProviderProps<{
1227
1263
  versionValue: number | null;
1228
1264
  onChange: ((options: {
1229
1265
  editor: PlateEditor;
1230
- value: _platejs_slate15.Value;
1266
+ value: _platejs_slate4.Value;
1231
1267
  }) => void) | null;
1232
1268
  onNodeChange: ((options: {
1233
1269
  editor: PlateEditor;
1234
- node: _platejs_slate15.Descendant;
1235
- operation: _platejs_slate15.NodeOperation;
1236
- prevNode: _platejs_slate15.Descendant;
1270
+ node: _platejs_slate4.Descendant;
1271
+ operation: _platejs_slate4.NodeOperation;
1272
+ prevNode: _platejs_slate4.Descendant;
1237
1273
  }) => void) | null;
1238
1274
  onSelectionChange: ((options: {
1239
1275
  editor: PlateEditor;
1240
- selection: _platejs_slate15.TSelection;
1276
+ selection: _platejs_slate4.TSelection;
1241
1277
  }) => void) | null;
1242
1278
  onTextChange: ((options: {
1243
1279
  editor: PlateEditor;
1244
- node: _platejs_slate15.Descendant;
1245
- operation: _platejs_slate15.TextOperation;
1280
+ node: _platejs_slate4.Descendant;
1281
+ operation: _platejs_slate4.TextOperation;
1246
1282
  prevText: string;
1247
1283
  text: string;
1248
1284
  }) => void) | null;
1249
1285
  onValueChange: ((options: {
1250
1286
  editor: PlateEditor;
1251
- value: _platejs_slate15.Value;
1287
+ value: _platejs_slate4.Value;
1252
1288
  }) => void) | null;
1253
1289
  id: string;
1254
1290
  containerRef: React$1.RefObject<HTMLDivElement | null>;
1255
1291
  editor: PlateEditor;
1256
1292
  scrollRef: React$1.RefObject<HTMLDivElement | null>;
1257
- }>>, plateStore: jotai_x0.StoreApi<PlateStoreState<PlateEditor>, {
1293
+ }>>, plateStore: jotai_x2.StoreApi<PlateStoreState<PlateEditor>, {
1258
1294
  trackedEditor: jotai10.Atom<{
1259
1295
  editor: any;
1260
1296
  version: number | null;
@@ -1267,52 +1303,52 @@ declare const PlateStoreProvider: React$1.FC<jotai_x0.ProviderProps<{
1267
1303
  value: any;
1268
1304
  version: number | null;
1269
1305
  }>;
1270
- }, "plate">, usePlateLocalSet: <K$1 extends "decorate" | "renderLeaf" | "renderText" | "editor" | "id" | "onChange" | "renderElement" | "onNodeChange" | "onTextChange" | "readOnly" | "composing" | "isMounted" | "primary" | "renderChunk" | "versionDecorate" | "versionEditor" | "versionSelection" | "versionValue" | "onSelectionChange" | "onValueChange" | "containerRef" | "scrollRef" | "trackedEditor" | "trackedSelection" | "trackedValue">(key: K$1, options?: string | jotai_x0.UseAtomOptions) => ({
1271
- composing: jotai_x0.SimpleWritableAtom<boolean | null>;
1272
- decorate: jotai_x0.SimpleWritableAtom<((options: {
1306
+ }, "plate">, usePlateLocalSet: <K$1 extends "renderElement" | "decorate" | "renderLeaf" | "renderText" | "editor" | "id" | "onChange" | "onNodeChange" | "onTextChange" | "readOnly" | "composing" | "isMounted" | "primary" | "renderChunk" | "versionDecorate" | "versionEditor" | "versionSelection" | "versionValue" | "onSelectionChange" | "onValueChange" | "containerRef" | "scrollRef" | "trackedEditor" | "trackedSelection" | "trackedValue">(key: K$1, options?: string | jotai_x2.UseAtomOptions) => ({
1307
+ composing: jotai_x2.SimpleWritableAtom<boolean | null>;
1308
+ decorate: jotai_x2.SimpleWritableAtom<((options: {
1273
1309
  editor: PlateEditor;
1274
- entry: _platejs_slate15.NodeEntry;
1275
- }) => _platejs_slate15.TRange[]) | null>;
1276
- isMounted: jotai_x0.SimpleWritableAtom<boolean | null>;
1277
- primary: jotai_x0.SimpleWritableAtom<boolean | null>;
1278
- readOnly: jotai_x0.SimpleWritableAtom<boolean | null>;
1279
- renderChunk: jotai_x0.SimpleWritableAtom<RenderChunkFn | null>;
1280
- renderElement: jotai_x0.SimpleWritableAtom<RenderElementFn | null>;
1281
- renderLeaf: jotai_x0.SimpleWritableAtom<RenderLeafFn | null>;
1282
- renderText: jotai_x0.SimpleWritableAtom<RenderTextFn | null>;
1283
- versionDecorate: jotai_x0.SimpleWritableAtom<number | null>;
1284
- versionEditor: jotai_x0.SimpleWritableAtom<number | null>;
1285
- versionSelection: jotai_x0.SimpleWritableAtom<number | null>;
1286
- versionValue: jotai_x0.SimpleWritableAtom<number | null>;
1287
- onChange: jotai_x0.SimpleWritableAtom<((options: {
1310
+ entry: _platejs_slate4.NodeEntry;
1311
+ }) => _platejs_slate4.TRange[]) | null>;
1312
+ isMounted: jotai_x2.SimpleWritableAtom<boolean | null>;
1313
+ primary: jotai_x2.SimpleWritableAtom<boolean | null>;
1314
+ readOnly: jotai_x2.SimpleWritableAtom<boolean | null>;
1315
+ renderChunk: jotai_x2.SimpleWritableAtom<RenderChunkFn | null>;
1316
+ renderElement: jotai_x2.SimpleWritableAtom<RenderElementFn | null>;
1317
+ renderLeaf: jotai_x2.SimpleWritableAtom<RenderLeafFn | null>;
1318
+ renderText: jotai_x2.SimpleWritableAtom<RenderTextFn | null>;
1319
+ versionDecorate: jotai_x2.SimpleWritableAtom<number | null>;
1320
+ versionEditor: jotai_x2.SimpleWritableAtom<number | null>;
1321
+ versionSelection: jotai_x2.SimpleWritableAtom<number | null>;
1322
+ versionValue: jotai_x2.SimpleWritableAtom<number | null>;
1323
+ onChange: jotai_x2.SimpleWritableAtom<((options: {
1288
1324
  editor: PlateEditor;
1289
- value: _platejs_slate15.Value;
1325
+ value: _platejs_slate4.Value;
1290
1326
  }) => void) | null>;
1291
- onNodeChange: jotai_x0.SimpleWritableAtom<((options: {
1327
+ onNodeChange: jotai_x2.SimpleWritableAtom<((options: {
1292
1328
  editor: PlateEditor;
1293
- node: _platejs_slate15.Descendant;
1294
- operation: _platejs_slate15.NodeOperation;
1295
- prevNode: _platejs_slate15.Descendant;
1329
+ node: _platejs_slate4.Descendant;
1330
+ operation: _platejs_slate4.NodeOperation;
1331
+ prevNode: _platejs_slate4.Descendant;
1296
1332
  }) => void) | null>;
1297
- onSelectionChange: jotai_x0.SimpleWritableAtom<((options: {
1333
+ onSelectionChange: jotai_x2.SimpleWritableAtom<((options: {
1298
1334
  editor: PlateEditor;
1299
- selection: _platejs_slate15.TSelection;
1335
+ selection: _platejs_slate4.TSelection;
1300
1336
  }) => void) | null>;
1301
- onTextChange: jotai_x0.SimpleWritableAtom<((options: {
1337
+ onTextChange: jotai_x2.SimpleWritableAtom<((options: {
1302
1338
  editor: PlateEditor;
1303
- node: _platejs_slate15.Descendant;
1304
- operation: _platejs_slate15.TextOperation;
1339
+ node: _platejs_slate4.Descendant;
1340
+ operation: _platejs_slate4.TextOperation;
1305
1341
  prevText: string;
1306
1342
  text: string;
1307
1343
  }) => void) | null>;
1308
- onValueChange: jotai_x0.SimpleWritableAtom<((options: {
1344
+ onValueChange: jotai_x2.SimpleWritableAtom<((options: {
1309
1345
  editor: PlateEditor;
1310
- value: _platejs_slate15.Value;
1346
+ value: _platejs_slate4.Value;
1311
1347
  }) => void) | null>;
1312
- id: jotai_x0.SimpleWritableAtom<string>;
1313
- containerRef: jotai_x0.SimpleWritableAtom<React$1.RefObject<HTMLDivElement | null>>;
1314
- editor: jotai_x0.SimpleWritableAtom<PlateEditor>;
1315
- scrollRef: jotai_x0.SimpleWritableAtom<React$1.RefObject<HTMLDivElement | null>>;
1348
+ id: jotai_x2.SimpleWritableAtom<string>;
1349
+ containerRef: jotai_x2.SimpleWritableAtom<React$1.RefObject<HTMLDivElement | null>>;
1350
+ editor: jotai_x2.SimpleWritableAtom<PlateEditor>;
1351
+ scrollRef: jotai_x2.SimpleWritableAtom<React$1.RefObject<HTMLDivElement | null>>;
1316
1352
  } & {
1317
1353
  trackedEditor: jotai10.Atom<{
1318
1354
  editor: any;
@@ -1326,52 +1362,52 @@ declare const PlateStoreProvider: React$1.FC<jotai_x0.ProviderProps<{
1326
1362
  value: any;
1327
1363
  version: number | null;
1328
1364
  }>;
1329
- })[K$1] extends jotai10.WritableAtom<infer _V, infer A extends unknown[], infer R> ? (...args: A) => R : never, usePlateLocalState: <K$1 extends "decorate" | "renderLeaf" | "renderText" | "editor" | "id" | "onChange" | "renderElement" | "onNodeChange" | "onTextChange" | "readOnly" | "composing" | "isMounted" | "primary" | "renderChunk" | "versionDecorate" | "versionEditor" | "versionSelection" | "versionValue" | "onSelectionChange" | "onValueChange" | "containerRef" | "scrollRef" | "trackedEditor" | "trackedSelection" | "trackedValue">(key: K$1, options?: string | jotai_x0.UseAtomOptions) => ({
1330
- composing: jotai_x0.SimpleWritableAtom<boolean | null>;
1331
- decorate: jotai_x0.SimpleWritableAtom<((options: {
1365
+ })[K$1] extends jotai10.WritableAtom<infer _V, infer A extends unknown[], infer R> ? (...args: A) => R : never, usePlateLocalState: <K$1 extends "renderElement" | "decorate" | "renderLeaf" | "renderText" | "editor" | "id" | "onChange" | "onNodeChange" | "onTextChange" | "readOnly" | "composing" | "isMounted" | "primary" | "renderChunk" | "versionDecorate" | "versionEditor" | "versionSelection" | "versionValue" | "onSelectionChange" | "onValueChange" | "containerRef" | "scrollRef" | "trackedEditor" | "trackedSelection" | "trackedValue">(key: K$1, options?: string | jotai_x2.UseAtomOptions) => ({
1366
+ composing: jotai_x2.SimpleWritableAtom<boolean | null>;
1367
+ decorate: jotai_x2.SimpleWritableAtom<((options: {
1332
1368
  editor: PlateEditor;
1333
- entry: _platejs_slate15.NodeEntry;
1334
- }) => _platejs_slate15.TRange[]) | null>;
1335
- isMounted: jotai_x0.SimpleWritableAtom<boolean | null>;
1336
- primary: jotai_x0.SimpleWritableAtom<boolean | null>;
1337
- readOnly: jotai_x0.SimpleWritableAtom<boolean | null>;
1338
- renderChunk: jotai_x0.SimpleWritableAtom<RenderChunkFn | null>;
1339
- renderElement: jotai_x0.SimpleWritableAtom<RenderElementFn | null>;
1340
- renderLeaf: jotai_x0.SimpleWritableAtom<RenderLeafFn | null>;
1341
- renderText: jotai_x0.SimpleWritableAtom<RenderTextFn | null>;
1342
- versionDecorate: jotai_x0.SimpleWritableAtom<number | null>;
1343
- versionEditor: jotai_x0.SimpleWritableAtom<number | null>;
1344
- versionSelection: jotai_x0.SimpleWritableAtom<number | null>;
1345
- versionValue: jotai_x0.SimpleWritableAtom<number | null>;
1346
- onChange: jotai_x0.SimpleWritableAtom<((options: {
1369
+ entry: _platejs_slate4.NodeEntry;
1370
+ }) => _platejs_slate4.TRange[]) | null>;
1371
+ isMounted: jotai_x2.SimpleWritableAtom<boolean | null>;
1372
+ primary: jotai_x2.SimpleWritableAtom<boolean | null>;
1373
+ readOnly: jotai_x2.SimpleWritableAtom<boolean | null>;
1374
+ renderChunk: jotai_x2.SimpleWritableAtom<RenderChunkFn | null>;
1375
+ renderElement: jotai_x2.SimpleWritableAtom<RenderElementFn | null>;
1376
+ renderLeaf: jotai_x2.SimpleWritableAtom<RenderLeafFn | null>;
1377
+ renderText: jotai_x2.SimpleWritableAtom<RenderTextFn | null>;
1378
+ versionDecorate: jotai_x2.SimpleWritableAtom<number | null>;
1379
+ versionEditor: jotai_x2.SimpleWritableAtom<number | null>;
1380
+ versionSelection: jotai_x2.SimpleWritableAtom<number | null>;
1381
+ versionValue: jotai_x2.SimpleWritableAtom<number | null>;
1382
+ onChange: jotai_x2.SimpleWritableAtom<((options: {
1347
1383
  editor: PlateEditor;
1348
- value: _platejs_slate15.Value;
1384
+ value: _platejs_slate4.Value;
1349
1385
  }) => void) | null>;
1350
- onNodeChange: jotai_x0.SimpleWritableAtom<((options: {
1386
+ onNodeChange: jotai_x2.SimpleWritableAtom<((options: {
1351
1387
  editor: PlateEditor;
1352
- node: _platejs_slate15.Descendant;
1353
- operation: _platejs_slate15.NodeOperation;
1354
- prevNode: _platejs_slate15.Descendant;
1388
+ node: _platejs_slate4.Descendant;
1389
+ operation: _platejs_slate4.NodeOperation;
1390
+ prevNode: _platejs_slate4.Descendant;
1355
1391
  }) => void) | null>;
1356
- onSelectionChange: jotai_x0.SimpleWritableAtom<((options: {
1392
+ onSelectionChange: jotai_x2.SimpleWritableAtom<((options: {
1357
1393
  editor: PlateEditor;
1358
- selection: _platejs_slate15.TSelection;
1394
+ selection: _platejs_slate4.TSelection;
1359
1395
  }) => void) | null>;
1360
- onTextChange: jotai_x0.SimpleWritableAtom<((options: {
1396
+ onTextChange: jotai_x2.SimpleWritableAtom<((options: {
1361
1397
  editor: PlateEditor;
1362
- node: _platejs_slate15.Descendant;
1363
- operation: _platejs_slate15.TextOperation;
1398
+ node: _platejs_slate4.Descendant;
1399
+ operation: _platejs_slate4.TextOperation;
1364
1400
  prevText: string;
1365
1401
  text: string;
1366
1402
  }) => void) | null>;
1367
- onValueChange: jotai_x0.SimpleWritableAtom<((options: {
1403
+ onValueChange: jotai_x2.SimpleWritableAtom<((options: {
1368
1404
  editor: PlateEditor;
1369
- value: _platejs_slate15.Value;
1405
+ value: _platejs_slate4.Value;
1370
1406
  }) => void) | null>;
1371
- id: jotai_x0.SimpleWritableAtom<string>;
1372
- containerRef: jotai_x0.SimpleWritableAtom<React$1.RefObject<HTMLDivElement | null>>;
1373
- editor: jotai_x0.SimpleWritableAtom<PlateEditor>;
1374
- scrollRef: jotai_x0.SimpleWritableAtom<React$1.RefObject<HTMLDivElement | null>>;
1407
+ id: jotai_x2.SimpleWritableAtom<string>;
1408
+ containerRef: jotai_x2.SimpleWritableAtom<React$1.RefObject<HTMLDivElement | null>>;
1409
+ editor: jotai_x2.SimpleWritableAtom<PlateEditor>;
1410
+ scrollRef: jotai_x2.SimpleWritableAtom<React$1.RefObject<HTMLDivElement | null>>;
1375
1411
  } & {
1376
1412
  trackedEditor: jotai10.Atom<{
1377
1413
  editor: any;
@@ -1385,7 +1421,7 @@ declare const PlateStoreProvider: React$1.FC<jotai_x0.ProviderProps<{
1385
1421
  value: any;
1386
1422
  version: number | null;
1387
1423
  }>;
1388
- })[K$1] extends jotai10.WritableAtom<infer V, infer A extends unknown[], infer R> ? [V, (...args: A) => R] : never, usePlateLocalStore: jotai_x0.UseStoreApi<PlateStoreState<PlateEditor>, {
1424
+ })[K$1] extends jotai10.WritableAtom<infer V, infer A extends unknown[], infer R> ? [V, (...args: A) => R] : never, usePlateLocalStore: jotai_x2.UseStoreApi<PlateStoreState<PlateEditor>, {
1389
1425
  trackedEditor: jotai10.Atom<{
1390
1426
  editor: any;
1391
1427
  version: number | null;
@@ -1398,52 +1434,52 @@ declare const PlateStoreProvider: React$1.FC<jotai_x0.ProviderProps<{
1398
1434
  value: any;
1399
1435
  version: number | null;
1400
1436
  }>;
1401
- }>, usePlateLocalValue: <K$1 extends "decorate" | "renderLeaf" | "renderText" | "editor" | "id" | "onChange" | "renderElement" | "onNodeChange" | "onTextChange" | "readOnly" | "composing" | "isMounted" | "primary" | "renderChunk" | "versionDecorate" | "versionEditor" | "versionSelection" | "versionValue" | "onSelectionChange" | "onValueChange" | "containerRef" | "scrollRef" | "trackedEditor" | "trackedSelection" | "trackedValue", S = (({
1402
- composing: jotai_x0.SimpleWritableAtom<boolean | null>;
1403
- decorate: jotai_x0.SimpleWritableAtom<((options: {
1437
+ }>, usePlateLocalValue: <K$1 extends "renderElement" | "decorate" | "renderLeaf" | "renderText" | "editor" | "id" | "onChange" | "onNodeChange" | "onTextChange" | "readOnly" | "composing" | "isMounted" | "primary" | "renderChunk" | "versionDecorate" | "versionEditor" | "versionSelection" | "versionValue" | "onSelectionChange" | "onValueChange" | "containerRef" | "scrollRef" | "trackedEditor" | "trackedSelection" | "trackedValue", S = (({
1438
+ composing: jotai_x2.SimpleWritableAtom<boolean | null>;
1439
+ decorate: jotai_x2.SimpleWritableAtom<((options: {
1404
1440
  editor: PlateEditor;
1405
- entry: _platejs_slate15.NodeEntry;
1406
- }) => _platejs_slate15.TRange[]) | null>;
1407
- isMounted: jotai_x0.SimpleWritableAtom<boolean | null>;
1408
- primary: jotai_x0.SimpleWritableAtom<boolean | null>;
1409
- readOnly: jotai_x0.SimpleWritableAtom<boolean | null>;
1410
- renderChunk: jotai_x0.SimpleWritableAtom<RenderChunkFn | null>;
1411
- renderElement: jotai_x0.SimpleWritableAtom<RenderElementFn | null>;
1412
- renderLeaf: jotai_x0.SimpleWritableAtom<RenderLeafFn | null>;
1413
- renderText: jotai_x0.SimpleWritableAtom<RenderTextFn | null>;
1414
- versionDecorate: jotai_x0.SimpleWritableAtom<number | null>;
1415
- versionEditor: jotai_x0.SimpleWritableAtom<number | null>;
1416
- versionSelection: jotai_x0.SimpleWritableAtom<number | null>;
1417
- versionValue: jotai_x0.SimpleWritableAtom<number | null>;
1418
- onChange: jotai_x0.SimpleWritableAtom<((options: {
1441
+ entry: _platejs_slate4.NodeEntry;
1442
+ }) => _platejs_slate4.TRange[]) | null>;
1443
+ isMounted: jotai_x2.SimpleWritableAtom<boolean | null>;
1444
+ primary: jotai_x2.SimpleWritableAtom<boolean | null>;
1445
+ readOnly: jotai_x2.SimpleWritableAtom<boolean | null>;
1446
+ renderChunk: jotai_x2.SimpleWritableAtom<RenderChunkFn | null>;
1447
+ renderElement: jotai_x2.SimpleWritableAtom<RenderElementFn | null>;
1448
+ renderLeaf: jotai_x2.SimpleWritableAtom<RenderLeafFn | null>;
1449
+ renderText: jotai_x2.SimpleWritableAtom<RenderTextFn | null>;
1450
+ versionDecorate: jotai_x2.SimpleWritableAtom<number | null>;
1451
+ versionEditor: jotai_x2.SimpleWritableAtom<number | null>;
1452
+ versionSelection: jotai_x2.SimpleWritableAtom<number | null>;
1453
+ versionValue: jotai_x2.SimpleWritableAtom<number | null>;
1454
+ onChange: jotai_x2.SimpleWritableAtom<((options: {
1419
1455
  editor: PlateEditor;
1420
- value: _platejs_slate15.Value;
1456
+ value: _platejs_slate4.Value;
1421
1457
  }) => void) | null>;
1422
- onNodeChange: jotai_x0.SimpleWritableAtom<((options: {
1458
+ onNodeChange: jotai_x2.SimpleWritableAtom<((options: {
1423
1459
  editor: PlateEditor;
1424
- node: _platejs_slate15.Descendant;
1425
- operation: _platejs_slate15.NodeOperation;
1426
- prevNode: _platejs_slate15.Descendant;
1460
+ node: _platejs_slate4.Descendant;
1461
+ operation: _platejs_slate4.NodeOperation;
1462
+ prevNode: _platejs_slate4.Descendant;
1427
1463
  }) => void) | null>;
1428
- onSelectionChange: jotai_x0.SimpleWritableAtom<((options: {
1464
+ onSelectionChange: jotai_x2.SimpleWritableAtom<((options: {
1429
1465
  editor: PlateEditor;
1430
- selection: _platejs_slate15.TSelection;
1466
+ selection: _platejs_slate4.TSelection;
1431
1467
  }) => void) | null>;
1432
- onTextChange: jotai_x0.SimpleWritableAtom<((options: {
1468
+ onTextChange: jotai_x2.SimpleWritableAtom<((options: {
1433
1469
  editor: PlateEditor;
1434
- node: _platejs_slate15.Descendant;
1435
- operation: _platejs_slate15.TextOperation;
1470
+ node: _platejs_slate4.Descendant;
1471
+ operation: _platejs_slate4.TextOperation;
1436
1472
  prevText: string;
1437
1473
  text: string;
1438
1474
  }) => void) | null>;
1439
- onValueChange: jotai_x0.SimpleWritableAtom<((options: {
1475
+ onValueChange: jotai_x2.SimpleWritableAtom<((options: {
1440
1476
  editor: PlateEditor;
1441
- value: _platejs_slate15.Value;
1477
+ value: _platejs_slate4.Value;
1442
1478
  }) => void) | null>;
1443
- id: jotai_x0.SimpleWritableAtom<string>;
1444
- containerRef: jotai_x0.SimpleWritableAtom<React$1.RefObject<HTMLDivElement | null>>;
1445
- editor: jotai_x0.SimpleWritableAtom<PlateEditor>;
1446
- scrollRef: jotai_x0.SimpleWritableAtom<React$1.RefObject<HTMLDivElement | null>>;
1479
+ id: jotai_x2.SimpleWritableAtom<string>;
1480
+ containerRef: jotai_x2.SimpleWritableAtom<React$1.RefObject<HTMLDivElement | null>>;
1481
+ editor: jotai_x2.SimpleWritableAtom<PlateEditor>;
1482
+ scrollRef: jotai_x2.SimpleWritableAtom<React$1.RefObject<HTMLDivElement | null>>;
1447
1483
  } & {
1448
1484
  trackedEditor: jotai10.Atom<{
1449
1485
  editor: any;
@@ -1459,51 +1495,51 @@ declare const PlateStoreProvider: React$1.FC<jotai_x0.ProviderProps<{
1459
1495
  }>;
1460
1496
  })[K$1] extends jotai10.Atom<infer V> ? V : never)>(key: K$1, options?: ({
1461
1497
  selector?: ((v: ({
1462
- composing: jotai_x0.SimpleWritableAtom<boolean | null>;
1463
- decorate: jotai_x0.SimpleWritableAtom<((options: {
1498
+ composing: jotai_x2.SimpleWritableAtom<boolean | null>;
1499
+ decorate: jotai_x2.SimpleWritableAtom<((options: {
1464
1500
  editor: PlateEditor;
1465
- entry: _platejs_slate15.NodeEntry;
1466
- }) => _platejs_slate15.TRange[]) | null>;
1467
- isMounted: jotai_x0.SimpleWritableAtom<boolean | null>;
1468
- primary: jotai_x0.SimpleWritableAtom<boolean | null>;
1469
- readOnly: jotai_x0.SimpleWritableAtom<boolean | null>;
1470
- renderChunk: jotai_x0.SimpleWritableAtom<RenderChunkFn | null>;
1471
- renderElement: jotai_x0.SimpleWritableAtom<RenderElementFn | null>;
1472
- renderLeaf: jotai_x0.SimpleWritableAtom<RenderLeafFn | null>;
1473
- renderText: jotai_x0.SimpleWritableAtom<RenderTextFn | null>;
1474
- versionDecorate: jotai_x0.SimpleWritableAtom<number | null>;
1475
- versionEditor: jotai_x0.SimpleWritableAtom<number | null>;
1476
- versionSelection: jotai_x0.SimpleWritableAtom<number | null>;
1477
- versionValue: jotai_x0.SimpleWritableAtom<number | null>;
1478
- onChange: jotai_x0.SimpleWritableAtom<((options: {
1501
+ entry: _platejs_slate4.NodeEntry;
1502
+ }) => _platejs_slate4.TRange[]) | null>;
1503
+ isMounted: jotai_x2.SimpleWritableAtom<boolean | null>;
1504
+ primary: jotai_x2.SimpleWritableAtom<boolean | null>;
1505
+ readOnly: jotai_x2.SimpleWritableAtom<boolean | null>;
1506
+ renderChunk: jotai_x2.SimpleWritableAtom<RenderChunkFn | null>;
1507
+ renderElement: jotai_x2.SimpleWritableAtom<RenderElementFn | null>;
1508
+ renderLeaf: jotai_x2.SimpleWritableAtom<RenderLeafFn | null>;
1509
+ renderText: jotai_x2.SimpleWritableAtom<RenderTextFn | null>;
1510
+ versionDecorate: jotai_x2.SimpleWritableAtom<number | null>;
1511
+ versionEditor: jotai_x2.SimpleWritableAtom<number | null>;
1512
+ versionSelection: jotai_x2.SimpleWritableAtom<number | null>;
1513
+ versionValue: jotai_x2.SimpleWritableAtom<number | null>;
1514
+ onChange: jotai_x2.SimpleWritableAtom<((options: {
1479
1515
  editor: PlateEditor;
1480
- value: _platejs_slate15.Value;
1516
+ value: _platejs_slate4.Value;
1481
1517
  }) => void) | null>;
1482
- onNodeChange: jotai_x0.SimpleWritableAtom<((options: {
1518
+ onNodeChange: jotai_x2.SimpleWritableAtom<((options: {
1483
1519
  editor: PlateEditor;
1484
- node: _platejs_slate15.Descendant;
1485
- operation: _platejs_slate15.NodeOperation;
1486
- prevNode: _platejs_slate15.Descendant;
1520
+ node: _platejs_slate4.Descendant;
1521
+ operation: _platejs_slate4.NodeOperation;
1522
+ prevNode: _platejs_slate4.Descendant;
1487
1523
  }) => void) | null>;
1488
- onSelectionChange: jotai_x0.SimpleWritableAtom<((options: {
1524
+ onSelectionChange: jotai_x2.SimpleWritableAtom<((options: {
1489
1525
  editor: PlateEditor;
1490
- selection: _platejs_slate15.TSelection;
1526
+ selection: _platejs_slate4.TSelection;
1491
1527
  }) => void) | null>;
1492
- onTextChange: jotai_x0.SimpleWritableAtom<((options: {
1528
+ onTextChange: jotai_x2.SimpleWritableAtom<((options: {
1493
1529
  editor: PlateEditor;
1494
- node: _platejs_slate15.Descendant;
1495
- operation: _platejs_slate15.TextOperation;
1530
+ node: _platejs_slate4.Descendant;
1531
+ operation: _platejs_slate4.TextOperation;
1496
1532
  prevText: string;
1497
1533
  text: string;
1498
1534
  }) => void) | null>;
1499
- onValueChange: jotai_x0.SimpleWritableAtom<((options: {
1535
+ onValueChange: jotai_x2.SimpleWritableAtom<((options: {
1500
1536
  editor: PlateEditor;
1501
- value: _platejs_slate15.Value;
1537
+ value: _platejs_slate4.Value;
1502
1538
  }) => void) | null>;
1503
- id: jotai_x0.SimpleWritableAtom<string>;
1504
- containerRef: jotai_x0.SimpleWritableAtom<React$1.RefObject<HTMLDivElement | null>>;
1505
- editor: jotai_x0.SimpleWritableAtom<PlateEditor>;
1506
- scrollRef: jotai_x0.SimpleWritableAtom<React$1.RefObject<HTMLDivElement | null>>;
1539
+ id: jotai_x2.SimpleWritableAtom<string>;
1540
+ containerRef: jotai_x2.SimpleWritableAtom<React$1.RefObject<HTMLDivElement | null>>;
1541
+ editor: jotai_x2.SimpleWritableAtom<PlateEditor>;
1542
+ scrollRef: jotai_x2.SimpleWritableAtom<React$1.RefObject<HTMLDivElement | null>>;
1507
1543
  } & {
1508
1544
  trackedEditor: jotai10.Atom<{
1509
1545
  editor: any;
@@ -1519,8 +1555,8 @@ declare const PlateStoreProvider: React$1.FC<jotai_x0.ProviderProps<{
1519
1555
  }>;
1520
1556
  })[K$1] extends jotai10.Atom<infer V_1> ? V_1 : never, prevSelectorOutput?: S | undefined) => S) | undefined;
1521
1557
  equalityFn?: ((prev: S, next: S) => boolean) | undefined;
1522
- } & jotai_x0.UseAtomOptions) | undefined, deps?: unknown[]) => S;
1523
- declare const usePlateStore: (id?: string) => jotai_x0.ReturnOfUseStoreApi<PlateStoreState<PlateEditor>, {
1558
+ } & jotai_x2.UseAtomOptions) | undefined, deps?: unknown[]) => S;
1559
+ declare const usePlateStore: (id?: string) => jotai_x2.ReturnOfUseStoreApi<PlateStoreState<PlateEditor>, {
1524
1560
  trackedEditor: jotai10.Atom<{
1525
1561
  editor: any;
1526
1562
  version: number | null;
@@ -1626,7 +1662,7 @@ declare function useEditorPluginOptions<C extends AnyPluginConfig, U>(editor: Pl
1626
1662
  }): U;
1627
1663
  //#endregion
1628
1664
  //#region src/react/stores/plate-controller/plateControllerStore.d.ts
1629
- declare const PlateController: React$1.FC<jotai_x0.ProviderProps<{
1665
+ declare const PlateController: React$1.FC<jotai_x2.ProviderProps<{
1630
1666
  activeId: string | null;
1631
1667
  editorStores: Record<string, ({
1632
1668
  get: <Value$1>(atom: Atom<Value$1>) => Value$1;
@@ -1668,7 +1704,7 @@ declare const PlateController: React$1.FC<jotai_x0.ProviderProps<{
1668
1704
  dev_restore_atoms: (values: Iterable<readonly [Atom<unknown>, unknown]>) => void;
1669
1705
  }>) | null>;
1670
1706
  primaryEditorIds: string[];
1671
- }>>, plateControllerStore: jotai_x0.StoreApi<{
1707
+ }>>, plateControllerStore: jotai_x2.StoreApi<{
1672
1708
  activeId: jotai10.PrimitiveAtom<string | null> & {
1673
1709
  init: string | null;
1674
1710
  };
@@ -1754,7 +1790,7 @@ declare const PlateController: React$1.FC<jotai_x0.ProviderProps<{
1754
1790
  primaryEditorIds: jotai10.PrimitiveAtom<string[]> & {
1755
1791
  init: string[];
1756
1792
  };
1757
- }, object, "plateController">, _usePlateControllerStore: jotai_x0.UseStoreApi<{
1793
+ }, object, "plateController">, _usePlateControllerStore: jotai_x2.UseStoreApi<{
1758
1794
  activeId: jotai10.PrimitiveAtom<string | null> & {
1759
1795
  init: string | null;
1760
1796
  };
@@ -1956,7 +1992,7 @@ declare const useEditableProps: ({
1956
1992
  * if another node is updated in a way that affects this node's path, this hook
1957
1993
  * will not return the new path.
1958
1994
  */
1959
- declare const useNodePath: (node: TNode) => _platejs_slate15.Path | undefined;
1995
+ declare const useNodePath: (node: TNode) => _platejs_slate4.Path | undefined;
1960
1996
  //#endregion
1961
1997
  //#region src/react/hooks/useSlateProps.d.ts
1962
1998
  type SlateComponentProps = Omit<React$1.ComponentProps<typeof Slate>, 'children'>;
@@ -1971,7 +2007,7 @@ declare const useSlateProps: ({
1971
2007
  }) => PlateSlateProps;
1972
2008
  //#endregion
1973
2009
  //#region src/react/utils/createPlateFallbackEditor.d.ts
1974
- declare const createPlateFallbackEditor: (options?: CreatePlateEditorOptions) => TPlateEditor<_platejs_slate15.Value, PlateCorePlugin>;
2010
+ declare const createPlateFallbackEditor: (options?: CreatePlateEditorOptions) => TPlateEditor<_platejs_slate4.Value, PlateCorePlugin>;
1975
2011
  //#endregion
1976
2012
  //#region src/react/utils/dom-attributes.d.ts
1977
2013
  declare const DOM_HANDLERS: (keyof DOMHandlers)[];
@@ -1987,6 +2023,7 @@ declare const getRenderNodeProps: ({
1987
2023
  disableInjectNodeProps,
1988
2024
  editor,
1989
2025
  plugin,
2026
+ pluginContext,
1990
2027
  props,
1991
2028
  readOnly
1992
2029
  }: {
@@ -1995,6 +2032,7 @@ declare const getRenderNodeProps: ({
1995
2032
  attributes?: AnyObject;
1996
2033
  disableInjectNodeProps?: boolean;
1997
2034
  plugin?: AnyEditorPlatePlugin;
2035
+ pluginContext?: AnyObject;
1998
2036
  readOnly?: boolean;
1999
2037
  }) => PlateHTMLProps;
2000
2038
  //#endregion
@@ -2042,7 +2080,9 @@ declare const pipeRenderText: (editor: PlateEditor, renderTextProp?: EditablePro
2042
2080
  * element then that JSX element is rendered.
2043
2081
  */
2044
2082
  type RenderElement = (props: PlateElementProps) => React$1.ReactElement<any> | undefined;
2045
- declare function BelowRootNodes(props: any): React$1.JSX.Element;
2083
+ declare function BelowRootNodes({
2084
+ ...props
2085
+ }: any): React$1.JSX.Element;
2046
2086
  /**
2047
2087
  * Get a `Editable.renderElement` handler for `plugin.node.type`. If the type is
2048
2088
  * equals to the slate element type, render `plugin.render.node`. Else, return
@@ -2068,4 +2108,4 @@ type RenderText = (props: PlateTextProps) => React$1.ReactElement<any>;
2068
2108
  */
2069
2109
  declare const pluginRenderText: (editor: PlateEditor, plugin: AnyEditorPlatePlugin) => RenderText;
2070
2110
  //#endregion
2071
- export { AnyEditorPlatePlugin, AnyPlatePlugin, BLUR_EDITOR_EVENT, BelowRootNodes, ContentVisibilityChunk, CreatePlateEditorOptions, DOMHandler, DOMHandlers, DOM_HANDLERS, Decorate, DefaultPlaceholder, Deserializer, Editable, EditableSiblingComponent, EditorHotkeysEffect, EditorMethodsEffect, EditorPlatePlugin, EditorRefEffect, EditorRefPluginEffect, ElementProvider, ElementStoreState, EventEditorPlugin, EventEditorState, EventEditorStore, ExtendEditor, ExtendEditorApi, ExtendEditorTransforms, FOCUS_EDITOR_EVENT, GLOBAL_PLATE_SCOPE, HtmlDeserializer, HtmlReactSerializer, HtmlSerializer, InferConfig, InjectNodeProps, KeyboardHandler, KeyofPlugins, LeafNodeProps, NavigationFeedbackPlugin, NodeProps, NodeWrapperComponent, NodeWrapperComponentProps, NodeWrapperComponentReturnType, NormalizeInitialValue, OnChange, OnNodeChange, OnTextChange, OverrideEditor, PLATE_SCOPE, ParagraphPlugin, Parser, Plate, PlateChangeKey, PlateChunkProps, PlateContainer, PlateContent, PlateContentProps, PlateController, PlateControllerEffect, PlateControllerEffectProps, PlateCorePlugin, PlateEditor, PlateElement, PlateElementProps, PlateHTMLProps, PlateLeaf, PlateLeafProps, PlateNodeProps, PlatePlugin, PlatePluginConfig, PlatePluginContext, PlatePluginMethods, PlatePlugins, PlateProps, PlateSlate, PlateStore, PlateStoreProvider, PlateStoreState, PlateTest, PlateText, PlateTextProps, PlateView, PlateViewProps, ReactPlugin, RenderElement, RenderLeaf, RenderNodeWrapper, RenderNodeWrapperFunction, RenderNodeWrapperProps, type RenderPlaceholderProps, RenderText, SCOPE_ELEMENT, Serializer, Shortcut, Shortcuts, Slate, SlateReactExtensionPlugin, StyledPlateElementProps, StyledPlateLeafProps, StyledPlateTextProps, TPlateEditor, TextNodeProps, TransformOptions, UseEditorSelectorOptions, UseHooks, WithPlateOptions, atom, convertDomEventToSyntheticEvent, createAtomStore, createPlateEditor, createPlateFallbackEditor, createPlatePlugin, createPlateStore, createTPlatePlugin, createZustandStore, elementStore, getEditorPlugin, getEventPlateId, getPlateCorePlugins, getPlugin, getRenderNodeProps, isEventHandled, omitPluginContext, pipeHandler, pipeOnChange, pipeRenderElement, pipeRenderLeaf, pipeRenderText, plateControllerStore, plateStore, pluginRenderElement, pluginRenderLeaf, pluginRenderText, toPlatePlugin, toTPlatePlugin, useComposing, useEditableProps, useEditorComposing, useEditorContainerRef, useEditorId, useEditorMounted, useEditorPlugin, useEditorPluginOption, useEditorPluginOptions, useEditorReadOnly, useEditorRef, useEditorScrollRef, useEditorSelection, useEditorSelector, useEditorState, useEditorValue, useEditorVersion, useElement, useElementSelector, useElementStore, useEventEditorValue, useEventPlateId, useFocusEditorEvents, useFocused, useFocusedLast, useIncrementVersion, useNavigationHighlight, useNodeAttributes, useNodePath, usePath, usePlateControllerExists, usePlateControllerLocalStore, usePlateControllerStore, usePlateEditor, usePlateLocalStore, usePlateSet, usePlateState, usePlateStore, usePlateValue, usePlateViewEditor, usePluginOption, usePluginOptions, useReadOnly, useRedecorate, useScrollRef, useSelected, useSelectionVersion, useSlateProps, useSlateStatic, useStoreAtomState, useStoreAtomValue, useStoreSelect, useStoreSetAtom, useStoreState, useStoreValue, useTracked, useTrackedStore, useValueVersion, withHOC, withPlate, withPlateReact, withReact };
2111
+ export { AnyEditorPlatePlugin, AnyPlatePlugin, BLUR_EDITOR_EVENT, BelowRootNodes, ContentVisibilityChunk, CreatePlateEditorOptions, DOMHandler, DOMHandlers, DOM_HANDLERS, Decorate, DefaultPlaceholder, Deserializer, Editable, EditableSiblingComponent, EditorHotkeysEffect, EditorMethodsEffect, EditorPlatePlugin, EditorRefEffect, EditorRefPluginEffect, ElementProvider, ElementStoreState, EventEditorPlugin, EventEditorState, EventEditorStore, ExtendEditor, ExtendEditorApi, ExtendEditorTransforms, FOCUS_EDITOR_EVENT, FirstBlockEffect, GLOBAL_PLATE_SCOPE, HtmlDeserializer, HtmlReactSerializer, HtmlSerializer, InferConfig, InjectNodeProps, KeyboardHandler, KeyofPlugins, LeafNodeProps, NavigationFeedbackPlugin, NodeProps, NodeWrapperComponent, NodeWrapperComponentProps, NodeWrapperComponentReturnType, NormalizeInitialValue, OnChange, OnNodeChange, OnTextChange, OverrideEditor, PLATE_SCOPE, ParagraphPlugin, Parser, Plate, PlateChangeKey, PlateChunkProps, PlateContainer, PlateContent, PlateContentProps, PlateController, PlateControllerEffect, PlateControllerEffectProps, PlateCorePlugin, PlateEditor, PlateElement, PlateElementProps, PlateHTMLProps, PlateLeaf, PlateLeafProps, PlateNodeProps, PlatePlugin, PlatePluginConfig, PlatePluginContext, PlatePluginMethods, PlatePlugins, PlateProps, PlateSlate, PlateStore, PlateStoreProvider, PlateStoreState, PlateTest, PlateText, PlateTextProps, PlateView, PlateViewProps, ReactPlugin, RenderElement, RenderLeaf, RenderNodeWrapper, RenderNodeWrapperFunction, RenderNodeWrapperProps, type RenderPlaceholderProps, RenderText, SCOPE_ELEMENT, Serializer, Shortcut, Shortcuts, Slate, SlateReactExtensionPlugin, StyledPlateElementProps, StyledPlateLeafProps, StyledPlateTextProps, TPlateEditor, TextNodeProps, TransformInitialValue, TransformOptions, UseEditorSelectorOptions, UseHooks, WithPlateOptions, atom, convertDomEventToSyntheticEvent, createAtomStore, createPlateEditor, createPlateFallbackEditor, createPlatePlugin, createPlateStore, createTPlatePlugin, createZustandStore, elementStore, getEditorPlugin, getEventPlateId, getPlateCorePlugins, getPlugin, getRenderNodeProps, isEventHandled, isHtmlVoidElementTag, omitPluginContext, pipeHandler, pipeOnChange, pipeRenderElement, pipeRenderLeaf, pipeRenderText, plateControllerStore, plateStore, pluginRenderElement, pluginRenderLeaf, pluginRenderText, toPlatePlugin, toTPlatePlugin, useBlockIdAttributeRef, useComposing, useEditableProps, useEditorComposing, useEditorContainerRef, useEditorId, useEditorMounted, useEditorPlugin, useEditorPluginOption, useEditorPluginOptions, useEditorReadOnly, useEditorRef, useEditorScrollRef, useEditorSelection, useEditorSelector, useEditorState, useEditorValue, useEditorVersion, useElement, useElementContext, useElementSelector, useElementStore, useElementStoreContext, useEventEditorValue, useEventPlateId, useFocusEditorEvents, useFocused, useFocusedLast, useIncrementVersion, useNavigationHighlight, useNodeAttributes, useNodePath, usePath, usePlateControllerExists, usePlateControllerLocalStore, usePlateControllerStore, usePlateEditor, usePlateLocalStore, usePlateSet, usePlateState, usePlateStore, usePlateValue, usePlateViewEditor, usePluginOption, usePluginOptions, useReadOnly, useRedecorate, useScrollRef, useSelected, useSelectionVersion, useSlateProps, useSlateStatic, useStoreAtomState, useStoreAtomValue, useStoreSelect, useStoreSetAtom, useStoreState, useStoreValue, useTracked, useTrackedStore, useValueVersion, withElementContext, withHOC, withPlate, withPlateReact, withReact };