{"version":3,"file":"DynamicIframe.DcssAczE.mjs","names":[],"sources":["https:/framerusercontent.com/modules/k2H6ehFe75M07dSRPZGm/BD3Vkg6DiwYdQyoopDTN/DynamicIframe.js"],"sourcesContent":["// Welcome to Code in Framer\n// Get Started: https://www.framer.com/developers/\nimport{jsx as _jsx}from\"react/jsx-runtime\";import*as React from\"react\";/**\n * These annotations control how your component sizes\n * Learn more: https://www.framer.com/developers/#code-components-auto-sizing\n *\n * @framerSupportedLayoutWidth any-prefer-fixed\n * @framerSupportedLayoutHeight any-prefer-fixed\n */export default function DynamicIframe(props){// This is a React component containing an Example component\n// - Replace <Example /> with your own code\n// - Find inspiration: https://www.framer.com/developers/\nReact.useEffect(()=>{const currentURL=window.location.href;const encodedURL=encodeURIComponent(currentURL);const jsonParams=`%7B%22ds135.Website_URL%22%3A%22${encodedURL}%22%7D`;const reportURL=`https://lookerstudio.google.com/embed/reporting/e24c1205-92d9-4c85-b74c-be96e063230e/page/qGooD?params=${jsonParams}`;const iframe=document.getElementById(\"dynamic-iframe\");if(iframe){iframe.src=reportURL;}// Dynamic resizing based on content\nwindow.addEventListener(\"message\",event=>{if(event.origin===\"https://lookerstudio.google.com\"&&event.data.height){iframe.style.height=`${event.data.height}px`;}});},[]);return /*#__PURE__*/_jsx(\"iframe\",{id:\"dynamic-iframe\",width:\"100%\",height:\"100%\",frameBorder:\"0\",scrolling:\"no\",style:{border:0,overflow:\"hidden\",width:\"100%\",height:\"100%\"},allowFullScreen:true,sandbox:\"allow-storage-access-by-user-activation allow-scripts allow-same-origin allow-popups allow-popups-to-escape-sandbox\"});}// Styles are written in object syntax\n// Learn more: https://reactjs.org/docs/dom-elements.html#style\n/*\nconst containerStyle: CSSProperties = {\n    width: \"100%\",\n    height: \"100vh\", // Ensure full height of the viewport\n    display: \"flex\",\n    justifyContent: \"center\",\n    alignItems: \"center\",\n    position: \"relative\", // Correct type for 'position'\n    overflow: \"auto\", // Allow scrolling at the container level\n}\n */\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"DynamicIframe\",\"slots\":[],\"annotations\":{\"framerContractVersion\":\"1\",\"framerSupportedLayoutWidth\":\"any-prefer-fixed\",\"framerSupportedLayoutHeight\":\"any-prefer-fixed\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./DynamicIframe.map"],"mappings":"mMAQG,SAAwB,EAAc,EAAM,CAI0H,MADzK,GAAgB,IAAI,CAAC,IAAM,EAAW,EAAO,SAAS,KAAW,EAAW,mBAAmB,EAAW,CAAO,GAAY,kCAAkC,EAAW,QAAc,GAAW,yGAAyG,IAAmB,EAAO,SAAS,eAAe,iBAAiB,CAC/W,AADmX,IAAQ,EAAO,IAAI,GACtY,EAAO,iBAAiB,UAAU,GAAO,CAAC,AAAG,EAAM,SAAS,mCAAmC,EAAM,KAAK,SAAQ,EAAO,MAAM,UAAU,EAAM,KAAK,OAAO,IAAM,EAAC,AAAE,EAAC,CAAE,EAAC,CAAqB,EAAK,SAAS,CAAC,GAAG,iBAAiB,MAAM,OAAO,OAAO,OAAO,YAAY,IAAI,UAAU,KAAK,MAAM,CAAC,OAAO,EAAE,SAAS,SAAS,MAAM,OAAO,OAAO,MAAO,EAAC,iBAAgB,EAAK,QAAQ,qHAAsH,EAAC,AAAE,kBAV9e,GAA2C,IAA4B"}