import formatErrorMessage from "../../../../utils/esm/formatErrorMessage.js";
import * as React from "react";
const MenuGroupContext = /* @__PURE__ */ React.createContext(void 0);
if (process.env.NODE_ENV !== "production") MenuGroupContext.displayName = "MenuGroupContext";
function useMenuGroupRootContext() {
  const context = React.useContext(MenuGroupContext);
  if (context === void 0) {
    throw new Error(process.env.NODE_ENV !== "production" ? "Base UI: MenuGroupRootContext is missing. Menu group parts must be used within <Menu.Group>." : formatErrorMessage(31));
  }
  return context;
}
export {
  MenuGroupContext,
  useMenuGroupRootContext
};
//# sourceMappingURL=MenuGroupContext.js.map
