import { jsx as e } from "@emotion/react/jsx-runtime";
import { FlagsProvider as m, ModuleDictionaryProvider as g, ModuleSkeletonProvider as v, ModulePrivilegesProvider as p } from "@m4l/core";
import { useLocales as P } from "@m4l/graphics";
import { ModalProvider as i } from "../../contexts/ModalContext/index.js";
function L(l) {
  const {
    children: r,
    isAuth: o = !0,
    moduleId: d,
    moduleNameField: n,
    skeletonFlags: t,
    privileges: c,
    componentsDictionary: a,
    moduleDictionaryLoaded: s
  } = l, u = P().currentLocale?.localeString;
  return /* @__PURE__ */ e(m, { children: /* @__PURE__ */ e(
    g,
    {
      isAuth: o,
      moduleId: d,
      moduleNameField: n,
      componentsDictionary: a,
      currentLang: u,
      moduleDictionaryLoaded: s,
      children: /* @__PURE__ */ e(v, { flags: t, children: o ? /* @__PURE__ */ e(p, { queryPrivileges: c, children: /* @__PURE__ */ e(i, { children: r }) }) : /* @__PURE__ */ e(i, { children: r }) })
    }
  ) });
}
export {
  L as BaseModule
};
