/** @license MIT | @cube-dev/ui-kit v0.0.0-canary-f1f3d22 | Cube Dev Team */
import { createContext, useContext } from "react";
import { jsx } from "react/jsx-runtime";
import invariant from "tiny-invariant";

//#region src/components/overlays/NewNotifications/NotificationView/NotificationProvider.tsx
const NotificationContext = createContext(null);
/**
* @internal This component is unstable and must not be used outside of `NotificationView`.
*/
function NotificationProvider(props) {
	const { children, ...value } = props;
	return /* @__PURE__ */ jsx(NotificationContext.Provider, {
		value,
		children
	});
}
function useNotificationContext() {
	const context = useContext(NotificationContext);
	invariant(context, "This component cannot be used outside of <Notification />");
	return context;
}

//#endregion
export { NotificationProvider, useNotificationContext };
//# sourceMappingURL=NotificationProvider.js.map