@payfit/unity-components
Version:
26 lines (25 loc) • 633 B
JavaScript
import { createContext as e, useContext as t } from "react";
import { jsx as n } from "react/jsx-runtime";
//#region src/components/breadcrumbs/Breadcrumbs.context.tsx
var r = e({
wrap: "wrap",
isMobile: !1,
isStaticApi: !1
});
function i({ children: e, wrap: t, isMobile: i, isStaticApi: a }) {
return /* @__PURE__ */ n(r.Provider, {
value: {
wrap: t,
isMobile: i,
isStaticApi: a
},
children: e
});
}
function a() {
let e = t(r);
if (!e) throw Error("useBreadcrumbsContext must be used within an BreadcrumbsProvider");
return e;
}
//#endregion
export { i as BreadcrumbsProvider, a as useBreadcrumbsContext };