import { WixDesignSystemProvider } from "@wix/design-system";
import React, { useContext } from "react";
const UiComponentsContext = React.createContext(null);
const UiComponentsPopoverAppendToContext = React.createContext(
  void 0
);
const UiComponentsPopoverAppendToProvider = ({ appendTo, children }) => {
  return /* @__PURE__ */ React.createElement(UiComponentsPopoverAppendToContext.Provider, { value: appendTo }, children);
};
const UiComponentsProvider = ({
  children,
  containerEl
}) => {
  return /* @__PURE__ */ React.createElement(WixDesignSystemProvider, { features: { newColorsBranding: true } }, /* @__PURE__ */ React.createElement(UiComponentsContext.Provider, { value: containerEl }, children));
};
const usePanelContainerElement = () => useContext(UiComponentsContext);
const usePopoverAppendToElement = () => useContext(UiComponentsPopoverAppendToContext) ?? usePanelContainerElement();
export {
  UiComponentsContext,
  UiComponentsPopoverAppendToContext,
  UiComponentsPopoverAppendToProvider,
  UiComponentsProvider,
  usePanelContainerElement,
  usePopoverAppendToElement
};
//# sourceMappingURL=ui-components-provider.js.map
