import { jsx as o } from "react/jsx-runtime";
import { createContext as d, useContext as n, useMemo as m } from "react";
import { PlateWrapper as c } from "../components/EditorPositioningWrapper/PlateWrapper.es.js";
import { useEditorResize as f } from "../hooks/useEditorResize.es.js";
const r = d({
  editorWidth: 0,
  editorRef: null
}), l = () => n(r), C = ({ children: i }) => {
  const { editorRef: e, editorWidth: t } = f(), s = m(() => ({ editorWidth: t, editorRef: e }), [t, e]);
  return /* @__PURE__ */ o(r.Provider, { value: s, children: /* @__PURE__ */ o(c, { ref: e, children: i }) });
};
export {
  C as EditorResizeContextProvider,
  l as useEditorResizeContext
};
//# sourceMappingURL=EditorResizeContext.es.js.map
