lexical 0.36.2-nightly.20250930.0 → 0.36.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.
package/Lexical.dev.js CHANGED
@@ -2079,6 +2079,9 @@ let lastKeyDownTimeStamp = 0;
2079
2079
  let lastKeyCode = null;
2080
2080
  let lastBeforeInputInsertTextTimeStamp = 0;
2081
2081
  let unprocessedBeforeInputData = null;
2082
+ // Node can be moved between documents (for example using createPortal), so we
2083
+ // need to track the document each root element was originally registered on.
2084
+ const rootElementToDocument = new WeakMap();
2082
2085
  const rootElementsRegistered = new WeakMap();
2083
2086
  let isSelectionChangeFromDOMUpdate = false;
2084
2087
  let isSelectionChangeFromMouseDown = false;
@@ -2940,11 +2943,12 @@ function addRootElementEvents(rootElement, editor) {
2940
2943
  // We only want to have a single global selectionchange event handler, shared
2941
2944
  // between all editor instances.
2942
2945
  const doc = rootElement.ownerDocument;
2943
- const documentRootElementsCount = rootElementsRegistered.get(doc);
2944
- if (documentRootElementsCount === undefined || documentRootElementsCount < 1) {
2946
+ rootElementToDocument.set(rootElement, doc);
2947
+ const documentRootElementsCount = rootElementsRegistered.get(doc) ?? 0;
2948
+ if (documentRootElementsCount < 1) {
2945
2949
  doc.addEventListener('selectionchange', onDocumentSelectionChange);
2946
2950
  }
2947
- rootElementsRegistered.set(doc, (documentRootElementsCount || 0) + 1);
2951
+ rootElementsRegistered.set(doc, documentRootElementsCount + 1);
2948
2952
 
2949
2953
  // @ts-expect-error: internal field
2950
2954
  rootElement.__lexicalEditor = editor;
@@ -2996,7 +3000,11 @@ function addRootElementEvents(rootElement, editor) {
2996
3000
  }
2997
3001
  const rootElementNotRegisteredWarning = warnOnlyOnce('Root element not registered');
2998
3002
  function removeRootElementEvents(rootElement) {
2999
- const doc = rootElement.ownerDocument;
3003
+ const doc = rootElementToDocument.get(rootElement);
3004
+ if (doc === undefined) {
3005
+ rootElementNotRegisteredWarning();
3006
+ return;
3007
+ }
3000
3008
  const documentRootElementsCount = rootElementsRegistered.get(doc);
3001
3009
  if (documentRootElementsCount === undefined) {
3002
3010
  // This can happen if setRootElement() failed
@@ -3010,6 +3018,7 @@ function removeRootElementEvents(rootElement) {
3010
3018
  if (!(newCount >= 0)) {
3011
3019
  formatDevErrorMessage(`Root element count less than 0`);
3012
3020
  }
3021
+ rootElementToDocument.delete(rootElement);
3013
3022
  rootElementsRegistered.set(doc, newCount);
3014
3023
  if (newCount === 0) {
3015
3024
  doc.removeEventListener('selectionchange', onDocumentSelectionChange);
@@ -4213,6 +4222,75 @@ function insertRangeAfter(node, firstToInsert, lastToInsert) {
4213
4222
  }
4214
4223
  }
4215
4224
 
4225
+ /**
4226
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
4227
+ *
4228
+ * This source code is licensed under the MIT license found in the
4229
+ * LICENSE file in the root directory of this source tree.
4230
+ *
4231
+ */
4232
+
4233
+ /**
4234
+ * Common update tags used in Lexical. These tags can be used with editor.update() or $addUpdateTag()
4235
+ * to indicate the type/purpose of an update. Multiple tags can be used in a single update.
4236
+ */
4237
+
4238
+ /**
4239
+ * Indicates that the update is related to history operations (undo/redo)
4240
+ */
4241
+ const HISTORIC_TAG = 'historic';
4242
+
4243
+ /**
4244
+ * Indicates that a new history entry should be pushed to the history stack
4245
+ */
4246
+ const HISTORY_PUSH_TAG = 'history-push';
4247
+
4248
+ /**
4249
+ * Indicates that the current update should be merged with the previous history entry
4250
+ */
4251
+ const HISTORY_MERGE_TAG = 'history-merge';
4252
+
4253
+ /**
4254
+ * Indicates that the update is related to a paste operation
4255
+ */
4256
+ const PASTE_TAG = 'paste';
4257
+
4258
+ /**
4259
+ * Indicates that the update is related to collaborative editing
4260
+ */
4261
+ const COLLABORATION_TAG = 'collaboration';
4262
+
4263
+ /**
4264
+ * Indicates that the update should skip collaborative sync
4265
+ */
4266
+ const SKIP_COLLAB_TAG = 'skip-collab';
4267
+
4268
+ /**
4269
+ * Indicates that the update should skip scrolling the selection into view
4270
+ */
4271
+ const SKIP_SCROLL_INTO_VIEW_TAG = 'skip-scroll-into-view';
4272
+
4273
+ /**
4274
+ * Indicates that the update should skip updating the DOM selection
4275
+ * This is useful when you want to make updates without changing the selection or focus
4276
+ */
4277
+ const SKIP_DOM_SELECTION_TAG = 'skip-dom-selection';
4278
+
4279
+ /**
4280
+ * Indicates that after changing the selection, the editor should not focus itself
4281
+ * This tag is ignored if {@link SKIP_DOM_SELECTION_TAG} is used
4282
+ */
4283
+ const SKIP_SELECTION_FOCUS_TAG = 'skip-selection-focus';
4284
+
4285
+ /**
4286
+ * The update was triggered by editor.focus()
4287
+ */
4288
+ const FOCUS_TAG = 'focus';
4289
+
4290
+ /**
4291
+ * The set of known update tags to help with TypeScript suggestions.
4292
+ */
4293
+
4216
4294
  /**
4217
4295
  * Copyright (c) Meta Platforms, Inc. and affiliates.
4218
4296
  *
@@ -7683,9 +7761,11 @@ function updateDOMSelection(prevSelection, nextSelection, editor, domSelection,
7683
7761
  !(domSelection.type === 'Range' && isCollapsed)) {
7684
7762
  // If the root element does not have focus, ensure it has focus
7685
7763
  if (activeElement === null || !rootElement.contains(activeElement)) {
7686
- rootElement.focus({
7687
- preventScroll: true
7688
- });
7764
+ if (!tags.has(SKIP_SELECTION_FOCUS_TAG)) {
7765
+ rootElement.focus({
7766
+ preventScroll: true
7767
+ });
7768
+ }
7689
7769
  }
7690
7770
  if (anchor.type !== 'element') {
7691
7771
  return;
@@ -9704,69 +9784,6 @@ class EditorState {
9704
9784
  *
9705
9785
  */
9706
9786
 
9707
- /**
9708
- * Common update tags used in Lexical. These tags can be used with editor.update() or $addUpdateTag()
9709
- * to indicate the type/purpose of an update. Multiple tags can be used in a single update.
9710
- */
9711
-
9712
- /**
9713
- * Indicates that the update is related to history operations (undo/redo)
9714
- */
9715
- const HISTORIC_TAG = 'historic';
9716
-
9717
- /**
9718
- * Indicates that a new history entry should be pushed to the history stack
9719
- */
9720
- const HISTORY_PUSH_TAG = 'history-push';
9721
-
9722
- /**
9723
- * Indicates that the current update should be merged with the previous history entry
9724
- */
9725
- const HISTORY_MERGE_TAG = 'history-merge';
9726
-
9727
- /**
9728
- * Indicates that the update is related to a paste operation
9729
- */
9730
- const PASTE_TAG = 'paste';
9731
-
9732
- /**
9733
- * Indicates that the update is related to collaborative editing
9734
- */
9735
- const COLLABORATION_TAG = 'collaboration';
9736
-
9737
- /**
9738
- * Indicates that the update should skip collaborative sync
9739
- */
9740
- const SKIP_COLLAB_TAG = 'skip-collab';
9741
-
9742
- /**
9743
- * Indicates that the update should skip scrolling the selection into view
9744
- */
9745
- const SKIP_SCROLL_INTO_VIEW_TAG = 'skip-scroll-into-view';
9746
-
9747
- /**
9748
- * Indicates that the update should skip updating the DOM selection
9749
- * This is useful when you want to make updates without changing the selection or focus
9750
- */
9751
- const SKIP_DOM_SELECTION_TAG = 'skip-dom-selection';
9752
-
9753
- /**
9754
- * The update was triggered by editor.focus()
9755
- */
9756
- const FOCUS_TAG = 'focus';
9757
-
9758
- /**
9759
- * The set of known update tags to help with TypeScript suggestions.
9760
- */
9761
-
9762
- /**
9763
- * Copyright (c) Meta Platforms, Inc. and affiliates.
9764
- *
9765
- * This source code is licensed under the MIT license found in the
9766
- * LICENSE file in the root directory of this source tree.
9767
- *
9768
- */
9769
-
9770
9787
 
9771
9788
  // TODO: Cleanup ArtificialNode__DO_NOT_USE #5966
9772
9789
  /** @internal */
@@ -10786,7 +10803,7 @@ class LexicalEditor {
10786
10803
  };
10787
10804
  }
10788
10805
  }
10789
- LexicalEditor.version = "0.36.2-nightly.20250930.0+dev.cjs";
10806
+ LexicalEditor.version = "0.36.2+dev.cjs";
10790
10807
 
10791
10808
  let pendingNodeToClone = null;
10792
10809
  function setPendingNodeToClone(pendingNode) {
@@ -14043,6 +14060,7 @@ exports.SELECT_ALL_COMMAND = SELECT_ALL_COMMAND;
14043
14060
  exports.SKIP_COLLAB_TAG = SKIP_COLLAB_TAG;
14044
14061
  exports.SKIP_DOM_SELECTION_TAG = SKIP_DOM_SELECTION_TAG;
14045
14062
  exports.SKIP_SCROLL_INTO_VIEW_TAG = SKIP_SCROLL_INTO_VIEW_TAG;
14063
+ exports.SKIP_SELECTION_FOCUS_TAG = SKIP_SELECTION_FOCUS_TAG;
14046
14064
  exports.TEXT_TYPE_TO_FORMAT = TEXT_TYPE_TO_FORMAT;
14047
14065
  exports.TabNode = TabNode;
14048
14066
  exports.TextNode = TextNode;
package/Lexical.dev.mjs CHANGED
@@ -2077,6 +2077,9 @@ let lastKeyDownTimeStamp = 0;
2077
2077
  let lastKeyCode = null;
2078
2078
  let lastBeforeInputInsertTextTimeStamp = 0;
2079
2079
  let unprocessedBeforeInputData = null;
2080
+ // Node can be moved between documents (for example using createPortal), so we
2081
+ // need to track the document each root element was originally registered on.
2082
+ const rootElementToDocument = new WeakMap();
2080
2083
  const rootElementsRegistered = new WeakMap();
2081
2084
  let isSelectionChangeFromDOMUpdate = false;
2082
2085
  let isSelectionChangeFromMouseDown = false;
@@ -2938,11 +2941,12 @@ function addRootElementEvents(rootElement, editor) {
2938
2941
  // We only want to have a single global selectionchange event handler, shared
2939
2942
  // between all editor instances.
2940
2943
  const doc = rootElement.ownerDocument;
2941
- const documentRootElementsCount = rootElementsRegistered.get(doc);
2942
- if (documentRootElementsCount === undefined || documentRootElementsCount < 1) {
2944
+ rootElementToDocument.set(rootElement, doc);
2945
+ const documentRootElementsCount = rootElementsRegistered.get(doc) ?? 0;
2946
+ if (documentRootElementsCount < 1) {
2943
2947
  doc.addEventListener('selectionchange', onDocumentSelectionChange);
2944
2948
  }
2945
- rootElementsRegistered.set(doc, (documentRootElementsCount || 0) + 1);
2949
+ rootElementsRegistered.set(doc, documentRootElementsCount + 1);
2946
2950
 
2947
2951
  // @ts-expect-error: internal field
2948
2952
  rootElement.__lexicalEditor = editor;
@@ -2994,7 +2998,11 @@ function addRootElementEvents(rootElement, editor) {
2994
2998
  }
2995
2999
  const rootElementNotRegisteredWarning = warnOnlyOnce('Root element not registered');
2996
3000
  function removeRootElementEvents(rootElement) {
2997
- const doc = rootElement.ownerDocument;
3001
+ const doc = rootElementToDocument.get(rootElement);
3002
+ if (doc === undefined) {
3003
+ rootElementNotRegisteredWarning();
3004
+ return;
3005
+ }
2998
3006
  const documentRootElementsCount = rootElementsRegistered.get(doc);
2999
3007
  if (documentRootElementsCount === undefined) {
3000
3008
  // This can happen if setRootElement() failed
@@ -3008,6 +3016,7 @@ function removeRootElementEvents(rootElement) {
3008
3016
  if (!(newCount >= 0)) {
3009
3017
  formatDevErrorMessage(`Root element count less than 0`);
3010
3018
  }
3019
+ rootElementToDocument.delete(rootElement);
3011
3020
  rootElementsRegistered.set(doc, newCount);
3012
3021
  if (newCount === 0) {
3013
3022
  doc.removeEventListener('selectionchange', onDocumentSelectionChange);
@@ -4211,6 +4220,75 @@ function insertRangeAfter(node, firstToInsert, lastToInsert) {
4211
4220
  }
4212
4221
  }
4213
4222
 
4223
+ /**
4224
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
4225
+ *
4226
+ * This source code is licensed under the MIT license found in the
4227
+ * LICENSE file in the root directory of this source tree.
4228
+ *
4229
+ */
4230
+
4231
+ /**
4232
+ * Common update tags used in Lexical. These tags can be used with editor.update() or $addUpdateTag()
4233
+ * to indicate the type/purpose of an update. Multiple tags can be used in a single update.
4234
+ */
4235
+
4236
+ /**
4237
+ * Indicates that the update is related to history operations (undo/redo)
4238
+ */
4239
+ const HISTORIC_TAG = 'historic';
4240
+
4241
+ /**
4242
+ * Indicates that a new history entry should be pushed to the history stack
4243
+ */
4244
+ const HISTORY_PUSH_TAG = 'history-push';
4245
+
4246
+ /**
4247
+ * Indicates that the current update should be merged with the previous history entry
4248
+ */
4249
+ const HISTORY_MERGE_TAG = 'history-merge';
4250
+
4251
+ /**
4252
+ * Indicates that the update is related to a paste operation
4253
+ */
4254
+ const PASTE_TAG = 'paste';
4255
+
4256
+ /**
4257
+ * Indicates that the update is related to collaborative editing
4258
+ */
4259
+ const COLLABORATION_TAG = 'collaboration';
4260
+
4261
+ /**
4262
+ * Indicates that the update should skip collaborative sync
4263
+ */
4264
+ const SKIP_COLLAB_TAG = 'skip-collab';
4265
+
4266
+ /**
4267
+ * Indicates that the update should skip scrolling the selection into view
4268
+ */
4269
+ const SKIP_SCROLL_INTO_VIEW_TAG = 'skip-scroll-into-view';
4270
+
4271
+ /**
4272
+ * Indicates that the update should skip updating the DOM selection
4273
+ * This is useful when you want to make updates without changing the selection or focus
4274
+ */
4275
+ const SKIP_DOM_SELECTION_TAG = 'skip-dom-selection';
4276
+
4277
+ /**
4278
+ * Indicates that after changing the selection, the editor should not focus itself
4279
+ * This tag is ignored if {@link SKIP_DOM_SELECTION_TAG} is used
4280
+ */
4281
+ const SKIP_SELECTION_FOCUS_TAG = 'skip-selection-focus';
4282
+
4283
+ /**
4284
+ * The update was triggered by editor.focus()
4285
+ */
4286
+ const FOCUS_TAG = 'focus';
4287
+
4288
+ /**
4289
+ * The set of known update tags to help with TypeScript suggestions.
4290
+ */
4291
+
4214
4292
  /**
4215
4293
  * Copyright (c) Meta Platforms, Inc. and affiliates.
4216
4294
  *
@@ -7681,9 +7759,11 @@ function updateDOMSelection(prevSelection, nextSelection, editor, domSelection,
7681
7759
  !(domSelection.type === 'Range' && isCollapsed)) {
7682
7760
  // If the root element does not have focus, ensure it has focus
7683
7761
  if (activeElement === null || !rootElement.contains(activeElement)) {
7684
- rootElement.focus({
7685
- preventScroll: true
7686
- });
7762
+ if (!tags.has(SKIP_SELECTION_FOCUS_TAG)) {
7763
+ rootElement.focus({
7764
+ preventScroll: true
7765
+ });
7766
+ }
7687
7767
  }
7688
7768
  if (anchor.type !== 'element') {
7689
7769
  return;
@@ -9702,69 +9782,6 @@ class EditorState {
9702
9782
  *
9703
9783
  */
9704
9784
 
9705
- /**
9706
- * Common update tags used in Lexical. These tags can be used with editor.update() or $addUpdateTag()
9707
- * to indicate the type/purpose of an update. Multiple tags can be used in a single update.
9708
- */
9709
-
9710
- /**
9711
- * Indicates that the update is related to history operations (undo/redo)
9712
- */
9713
- const HISTORIC_TAG = 'historic';
9714
-
9715
- /**
9716
- * Indicates that a new history entry should be pushed to the history stack
9717
- */
9718
- const HISTORY_PUSH_TAG = 'history-push';
9719
-
9720
- /**
9721
- * Indicates that the current update should be merged with the previous history entry
9722
- */
9723
- const HISTORY_MERGE_TAG = 'history-merge';
9724
-
9725
- /**
9726
- * Indicates that the update is related to a paste operation
9727
- */
9728
- const PASTE_TAG = 'paste';
9729
-
9730
- /**
9731
- * Indicates that the update is related to collaborative editing
9732
- */
9733
- const COLLABORATION_TAG = 'collaboration';
9734
-
9735
- /**
9736
- * Indicates that the update should skip collaborative sync
9737
- */
9738
- const SKIP_COLLAB_TAG = 'skip-collab';
9739
-
9740
- /**
9741
- * Indicates that the update should skip scrolling the selection into view
9742
- */
9743
- const SKIP_SCROLL_INTO_VIEW_TAG = 'skip-scroll-into-view';
9744
-
9745
- /**
9746
- * Indicates that the update should skip updating the DOM selection
9747
- * This is useful when you want to make updates without changing the selection or focus
9748
- */
9749
- const SKIP_DOM_SELECTION_TAG = 'skip-dom-selection';
9750
-
9751
- /**
9752
- * The update was triggered by editor.focus()
9753
- */
9754
- const FOCUS_TAG = 'focus';
9755
-
9756
- /**
9757
- * The set of known update tags to help with TypeScript suggestions.
9758
- */
9759
-
9760
- /**
9761
- * Copyright (c) Meta Platforms, Inc. and affiliates.
9762
- *
9763
- * This source code is licensed under the MIT license found in the
9764
- * LICENSE file in the root directory of this source tree.
9765
- *
9766
- */
9767
-
9768
9785
 
9769
9786
  // TODO: Cleanup ArtificialNode__DO_NOT_USE #5966
9770
9787
  /** @internal */
@@ -10784,7 +10801,7 @@ class LexicalEditor {
10784
10801
  };
10785
10802
  }
10786
10803
  }
10787
- LexicalEditor.version = "0.36.2-nightly.20250930.0+dev.esm";
10804
+ LexicalEditor.version = "0.36.2+dev.esm";
10788
10805
 
10789
10806
  let pendingNodeToClone = null;
10790
10807
  function setPendingNodeToClone(pendingNode) {
@@ -13878,4 +13895,4 @@ function shallowMergeConfig(config, overrides) {
13878
13895
  return config;
13879
13896
  }
13880
13897
 
13881
- export { $addUpdateTag, $applyNodeReplacement, $caretFromPoint, $caretRangeFromSelection, $cloneWithProperties, $comparePointCaretNext, $copyNode, $create, $createLineBreakNode, $createNodeSelection, $createParagraphNode, $createPoint, $createRangeSelection, $createRangeSelectionFromDom, $createTabNode, $createTextNode, $extendCaretToRange, $findMatchingParent, $getAdjacentChildCaret, $getAdjacentNode, $getAdjacentSiblingOrParentSiblingCaret, $getCaretInDirection, $getCaretRange, $getCaretRangeInDirection, $getCharacterOffsets, $getChildCaret, $getChildCaretAtIndex, $getChildCaretOrSelf, $getCollapsedCaretRange, $getCommonAncestor, $getCommonAncestorResultBranchOrder, $getEditor, $getNearestNodeFromDOMNode, $getNearestRootOrShadowRoot, $getNodeByKey, $getNodeByKeyOrThrow, $getNodeFromDOMNode, $getPreviousSelection, $getRoot, $getSelection, $getSiblingCaret, $getState, $getStateChange, $getTextContent, $getTextNodeOffset, $getTextPointCaret, $getTextPointCaretSlice, $getWritableNodeState, $hasAncestor, $hasUpdateTag, $insertNodes, $isBlockElementNode, $isChildCaret, $isDecoratorNode, $isEditorState, $isElementNode, $isExtendableTextPointCaret, $isInlineElementOrDecoratorNode, $isLeafNode, $isLineBreakNode, $isNodeCaret, $isNodeSelection, $isParagraphNode, $isRangeSelection, $isRootNode, $isRootOrShadowRoot, $isSiblingCaret, $isTabNode, $isTextNode, $isTextPointCaret, $isTextPointCaretSlice, $isTokenOrSegmented, $isTokenOrTab, $nodesOfType, $normalizeCaret, $normalizeSelection as $normalizeSelection__EXPERIMENTAL, $onUpdate, $parseSerializedNode, $removeTextFromCaretRange, $rewindSiblingCaret, $selectAll, $setCompositionKey, $setPointFromCaret, $setSelection, $setSelectionFromCaretRange, $setState, $splitAtPointCaretNext, $splitNode, $updateRangeSelectionFromCaretRange, ArtificialNode__DO_NOT_USE, BLUR_COMMAND, CAN_REDO_COMMAND, CAN_UNDO_COMMAND, CLEAR_EDITOR_COMMAND, CLEAR_HISTORY_COMMAND, CLICK_COMMAND, COLLABORATION_TAG, COMMAND_PRIORITY_CRITICAL, COMMAND_PRIORITY_EDITOR, COMMAND_PRIORITY_HIGH, COMMAND_PRIORITY_LOW, COMMAND_PRIORITY_NORMAL, CONTROLLED_TEXT_INSERTION_COMMAND, COPY_COMMAND, CUT_COMMAND, DELETE_CHARACTER_COMMAND, DELETE_LINE_COMMAND, DELETE_WORD_COMMAND, DRAGEND_COMMAND, DRAGOVER_COMMAND, DRAGSTART_COMMAND, DROP_COMMAND, DecoratorNode, ElementNode, FOCUS_COMMAND, FORMAT_ELEMENT_COMMAND, FORMAT_TEXT_COMMAND, HISTORIC_TAG, HISTORY_MERGE_TAG, HISTORY_PUSH_TAG, INDENT_CONTENT_COMMAND, INSERT_LINE_BREAK_COMMAND, INSERT_PARAGRAPH_COMMAND, INSERT_TAB_COMMAND, INTERNAL_$isBlock, IS_ALL_FORMATTING, IS_BOLD, IS_CODE, IS_HIGHLIGHT, IS_ITALIC, IS_STRIKETHROUGH, IS_SUBSCRIPT, IS_SUPERSCRIPT, IS_UNDERLINE, KEY_ARROW_DOWN_COMMAND, KEY_ARROW_LEFT_COMMAND, KEY_ARROW_RIGHT_COMMAND, KEY_ARROW_UP_COMMAND, KEY_BACKSPACE_COMMAND, KEY_DELETE_COMMAND, KEY_DOWN_COMMAND, KEY_ENTER_COMMAND, KEY_ESCAPE_COMMAND, KEY_MODIFIER_COMMAND, KEY_SPACE_COMMAND, KEY_TAB_COMMAND, LineBreakNode, MOVE_TO_END, MOVE_TO_START, NODE_STATE_KEY, OUTDENT_CONTENT_COMMAND, PASTE_COMMAND, PASTE_TAG, ParagraphNode, REDO_COMMAND, REMOVE_TEXT_COMMAND, RootNode, SELECTION_CHANGE_COMMAND, SELECTION_INSERT_CLIPBOARD_NODES_COMMAND, SELECT_ALL_COMMAND, SKIP_COLLAB_TAG, SKIP_DOM_SELECTION_TAG, SKIP_SCROLL_INTO_VIEW_TAG, TEXT_TYPE_TO_FORMAT, TabNode, TextNode, UNDO_COMMAND, buildImportMap, configExtension, createCommand, createEditor, createSharedNodeState, createState, declarePeerDependency, defineExtension, flipDirection, getDOMOwnerDocument, getDOMSelection, getDOMSelectionFromTarget, getDOMTextNode, getEditorPropertyFromDOMNode, getNearestEditorFromDOMNode, getRegisteredNode, getRegisteredNodeOrThrow, getStaticNodeConfig, isBlockDomNode, isCurrentlyReadOnlyMode, isDOMDocumentNode, isDOMNode, isDOMTextNode, isDOMUnmanaged, isDocumentFragment, isExactShortcutMatch, isHTMLAnchorElement, isHTMLElement, isInlineDomNode, isLexicalEditor, isModifierMatch, isSelectionCapturedInDecoratorInput, isSelectionWithinEditor, makeStepwiseIterator, removeFromParent, resetRandomKey, safeCast, setDOMUnmanaged, setNodeIndentFromDOM, shallowMergeConfig };
13898
+ export { $addUpdateTag, $applyNodeReplacement, $caretFromPoint, $caretRangeFromSelection, $cloneWithProperties, $comparePointCaretNext, $copyNode, $create, $createLineBreakNode, $createNodeSelection, $createParagraphNode, $createPoint, $createRangeSelection, $createRangeSelectionFromDom, $createTabNode, $createTextNode, $extendCaretToRange, $findMatchingParent, $getAdjacentChildCaret, $getAdjacentNode, $getAdjacentSiblingOrParentSiblingCaret, $getCaretInDirection, $getCaretRange, $getCaretRangeInDirection, $getCharacterOffsets, $getChildCaret, $getChildCaretAtIndex, $getChildCaretOrSelf, $getCollapsedCaretRange, $getCommonAncestor, $getCommonAncestorResultBranchOrder, $getEditor, $getNearestNodeFromDOMNode, $getNearestRootOrShadowRoot, $getNodeByKey, $getNodeByKeyOrThrow, $getNodeFromDOMNode, $getPreviousSelection, $getRoot, $getSelection, $getSiblingCaret, $getState, $getStateChange, $getTextContent, $getTextNodeOffset, $getTextPointCaret, $getTextPointCaretSlice, $getWritableNodeState, $hasAncestor, $hasUpdateTag, $insertNodes, $isBlockElementNode, $isChildCaret, $isDecoratorNode, $isEditorState, $isElementNode, $isExtendableTextPointCaret, $isInlineElementOrDecoratorNode, $isLeafNode, $isLineBreakNode, $isNodeCaret, $isNodeSelection, $isParagraphNode, $isRangeSelection, $isRootNode, $isRootOrShadowRoot, $isSiblingCaret, $isTabNode, $isTextNode, $isTextPointCaret, $isTextPointCaretSlice, $isTokenOrSegmented, $isTokenOrTab, $nodesOfType, $normalizeCaret, $normalizeSelection as $normalizeSelection__EXPERIMENTAL, $onUpdate, $parseSerializedNode, $removeTextFromCaretRange, $rewindSiblingCaret, $selectAll, $setCompositionKey, $setPointFromCaret, $setSelection, $setSelectionFromCaretRange, $setState, $splitAtPointCaretNext, $splitNode, $updateRangeSelectionFromCaretRange, ArtificialNode__DO_NOT_USE, BLUR_COMMAND, CAN_REDO_COMMAND, CAN_UNDO_COMMAND, CLEAR_EDITOR_COMMAND, CLEAR_HISTORY_COMMAND, CLICK_COMMAND, COLLABORATION_TAG, COMMAND_PRIORITY_CRITICAL, COMMAND_PRIORITY_EDITOR, COMMAND_PRIORITY_HIGH, COMMAND_PRIORITY_LOW, COMMAND_PRIORITY_NORMAL, CONTROLLED_TEXT_INSERTION_COMMAND, COPY_COMMAND, CUT_COMMAND, DELETE_CHARACTER_COMMAND, DELETE_LINE_COMMAND, DELETE_WORD_COMMAND, DRAGEND_COMMAND, DRAGOVER_COMMAND, DRAGSTART_COMMAND, DROP_COMMAND, DecoratorNode, ElementNode, FOCUS_COMMAND, FORMAT_ELEMENT_COMMAND, FORMAT_TEXT_COMMAND, HISTORIC_TAG, HISTORY_MERGE_TAG, HISTORY_PUSH_TAG, INDENT_CONTENT_COMMAND, INSERT_LINE_BREAK_COMMAND, INSERT_PARAGRAPH_COMMAND, INSERT_TAB_COMMAND, INTERNAL_$isBlock, IS_ALL_FORMATTING, IS_BOLD, IS_CODE, IS_HIGHLIGHT, IS_ITALIC, IS_STRIKETHROUGH, IS_SUBSCRIPT, IS_SUPERSCRIPT, IS_UNDERLINE, KEY_ARROW_DOWN_COMMAND, KEY_ARROW_LEFT_COMMAND, KEY_ARROW_RIGHT_COMMAND, KEY_ARROW_UP_COMMAND, KEY_BACKSPACE_COMMAND, KEY_DELETE_COMMAND, KEY_DOWN_COMMAND, KEY_ENTER_COMMAND, KEY_ESCAPE_COMMAND, KEY_MODIFIER_COMMAND, KEY_SPACE_COMMAND, KEY_TAB_COMMAND, LineBreakNode, MOVE_TO_END, MOVE_TO_START, NODE_STATE_KEY, OUTDENT_CONTENT_COMMAND, PASTE_COMMAND, PASTE_TAG, ParagraphNode, REDO_COMMAND, REMOVE_TEXT_COMMAND, RootNode, SELECTION_CHANGE_COMMAND, SELECTION_INSERT_CLIPBOARD_NODES_COMMAND, SELECT_ALL_COMMAND, SKIP_COLLAB_TAG, SKIP_DOM_SELECTION_TAG, SKIP_SCROLL_INTO_VIEW_TAG, SKIP_SELECTION_FOCUS_TAG, TEXT_TYPE_TO_FORMAT, TabNode, TextNode, UNDO_COMMAND, buildImportMap, configExtension, createCommand, createEditor, createSharedNodeState, createState, declarePeerDependency, defineExtension, flipDirection, getDOMOwnerDocument, getDOMSelection, getDOMSelectionFromTarget, getDOMTextNode, getEditorPropertyFromDOMNode, getNearestEditorFromDOMNode, getRegisteredNode, getRegisteredNodeOrThrow, getStaticNodeConfig, isBlockDomNode, isCurrentlyReadOnlyMode, isDOMDocumentNode, isDOMNode, isDOMTextNode, isDOMUnmanaged, isDocumentFragment, isExactShortcutMatch, isHTMLAnchorElement, isHTMLElement, isInlineDomNode, isLexicalEditor, isModifierMatch, isSelectionCapturedInDecoratorInput, isSelectionWithinEditor, makeStepwiseIterator, removeFromParent, resetRandomKey, safeCast, setDOMUnmanaged, setNodeIndentFromDOM, shallowMergeConfig };
package/Lexical.mjs CHANGED
@@ -172,6 +172,7 @@ export const SELECT_ALL_COMMAND = mod.SELECT_ALL_COMMAND;
172
172
  export const SKIP_COLLAB_TAG = mod.SKIP_COLLAB_TAG;
173
173
  export const SKIP_DOM_SELECTION_TAG = mod.SKIP_DOM_SELECTION_TAG;
174
174
  export const SKIP_SCROLL_INTO_VIEW_TAG = mod.SKIP_SCROLL_INTO_VIEW_TAG;
175
+ export const SKIP_SELECTION_FOCUS_TAG = mod.SKIP_SELECTION_FOCUS_TAG;
175
176
  export const TEXT_TYPE_TO_FORMAT = mod.TEXT_TYPE_TO_FORMAT;
176
177
  export const TabNode = mod.TabNode;
177
178
  export const TextNode = mod.TextNode;
package/Lexical.node.mjs CHANGED
@@ -170,6 +170,7 @@ export const SELECT_ALL_COMMAND = mod.SELECT_ALL_COMMAND;
170
170
  export const SKIP_COLLAB_TAG = mod.SKIP_COLLAB_TAG;
171
171
  export const SKIP_DOM_SELECTION_TAG = mod.SKIP_DOM_SELECTION_TAG;
172
172
  export const SKIP_SCROLL_INTO_VIEW_TAG = mod.SKIP_SCROLL_INTO_VIEW_TAG;
173
+ export const SKIP_SELECTION_FOCUS_TAG = mod.SKIP_SELECTION_FOCUS_TAG;
173
174
  export const TEXT_TYPE_TO_FORMAT = mod.TEXT_TYPE_TO_FORMAT;
174
175
  export const TabNode = mod.TabNode;
175
176
  export const TextNode = mod.TextNode;