@baasix/lexical 0.0.2 → 0.0.3

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/dist/index.js CHANGED
@@ -796,6 +796,7 @@ function ActionsPlugin({
796
796
  // node
797
797
  shouldPreserveNewLinesInMarkdown
798
798
  );
799
+ root.selectEnd();
799
800
  } else {
800
801
  const markdown = $convertToMarkdownString2(
801
802
  PLAYGROUND_TRANSFORMERS,
@@ -806,9 +807,7 @@ function ActionsPlugin({
806
807
  const codeNode = $createCodeNode("markdown");
807
808
  codeNode.append($createTextNode2(markdown));
808
809
  root.clear().append(codeNode);
809
- if (markdown.length === 0) {
810
- codeNode.select();
811
- }
810
+ codeNode.select();
812
811
  }
813
812
  });
814
813
  }, [editor, shouldPreserveNewLinesInMarkdown]);