{"version":3,"file":"SupaOverrides.e0rAuLPX.mjs","names":[],"sources":["https:/framerusercontent.com/modules/aok6yV7vDE3ydeDk6yqI/AWaPNChsRDVKtu8Gahj7/SupaOverrides.js"],"sourcesContent":["// supagateway-runtime v1 — installed by the SupaGateway plugin. Updates overwrite this file.\n//\n// Thin code overrides to gate EXISTING Framer layers by session/membership without\n// restructuring the page. Apply them from the layer's Code Overrides panel. They render\n// nothing until the session resolves, so gated layers never flash — but remember that\n// anything designed statically in Framer still exists in the published HTML source.\n// Truly sensitive data belongs behind runtime fetches (SupaMemberGate content), not\n// behind visibility toggles.\nimport{jsx as _jsx}from\"react/jsx-runtime\";import{hasMemberRouteAccess,isGatePaused,useSupaGateway}from\"https://framerusercontent.com/modules/sjCPM8O6ejTW2FtotAQM/MHQoGbwL5iKA68BeKog3/SupaGateway.js\";import{RenderTarget}from\"framer\";function gateBy(Component,isVisible){return function GatedLayer(props){const gateway=useSupaGateway();if(RenderTarget.current()===RenderTarget.canvas)return /*#__PURE__*/_jsx(Component,{...props});// Paused from the plugin while designing. Only ever true on a Framer or local host.\nif(isGatePaused())return /*#__PURE__*/_jsx(Component,{...props});if(gateway.phase===\"loading\")return null;if(!isVisible(gateway.phase,gateway.memberStatus))return null;return /*#__PURE__*/_jsx(Component,{...props});};}/** Layer is visible for active members, or for any session on a configured CMS/session route. */export function withMemberOnly(Component){return gateBy(Component,(phase,memberStatus)=>hasMemberRouteAccess(phase,memberStatus));}/** Layer is visible for any signed-in user, regardless of membership status. */export function withSessionOnly(Component){return gateBy(Component,phase=>phase===\"authenticated\");}/** Layer is visible only for signed-out visitors (login buttons, public CTAs). */export function withAnonymousOnly(Component){return gateBy(Component,phase=>phase===\"anonymous\");}\nexport const __FramerMetadata__ = {\"exports\":{\"withMemberOnly\":{\"type\":\"reactHoc\",\"name\":\"withMemberOnly\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"withSessionOnly\":{\"type\":\"reactHoc\",\"name\":\"withSessionOnly\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"withAnonymousOnly\":{\"type\":\"reactHoc\",\"name\":\"withAnonymousOnly\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./SupaOverrides.map"],"mappings":"yNAQyO,SAAS,EAAO,EAAU,EAAU,CAAC,OAAO,SAAoB,EAAM,CAAC,IAAM,EAAQ,EAAe,EACrK,OAD0K,EAAa,QAAQ,IAAI,EAAa,QACrX,EAAa,EAAsB,EAAK,EAAU,CAAC,GAAG,CAAK,CAAC,EAAK,EAAQ,QAAQ,WAAyB,CAAC,EAAU,EAAQ,MAAM,EAAQ,YAAY,EAAS,KAAyB,EAAK,EAAU,CAAC,GAAG,CAAK,CAAC,CAAE,CAAE,CAAkG,SAAgB,EAAe,EAAU,CAAC,OAAO,EAAO,GAAW,EAAM,IAAe,EAAqB,EAAM,CAAY,CAAC,CAAE,iBADnZ,IAA6J,IAAiC"}