"use strict";

Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.focusEditor = void 0;
var _slate = require("slate");
var _slateReact = require("slate-react");
const focusEditor = (editor, target) => {
  if (target) {
    _slate.Editor.withoutNormalizing(editor, () => {
      _slate.Transforms.deselect(editor);
      _slate.Transforms.select(editor, target);
    });
  }
  _slateReact.ReactEditor.focus(editor);
};
exports.focusEditor = focusEditor;