{"version":3,"file":"WithGrid.br5XEBe0.mjs","names":["useState","debounce"],"sources":["https:/framerusercontent.com/modules/VqIcVfFXD6Y7W22wZ3J0/WDibLN04AkZLhQd1fUJZ/WithGrid.js"],"sourcesContent":["import{jsx as _jsx}from\"react/jsx-runtime\";import{useEffect,useState}from\"react\";import debounce from\"lodash/debounce\";export function withGridLine(Component){return props=>{return /*#__PURE__*/_jsx(Component,{...props,style:{...props.style,transformOrigin:\"top left\"},animate:{scaleX:[0,1]},transition:{duration:2,ease:[.075,.82,.165,1]}});};}export function withGridWidth(Component){return props=>{const DEFAULT_WIDTH=25;const[width,setWidth]=useState(DEFAULT_WIDTH);useEffect(()=>{const style=document.createElement(\"style\");style.textContent=`\n                .grid-align:nth-child(2n) {\n                    justify-content: end;\n                }\n\n                .grid-align:nth-child(3n) {\n                    justify-content: center;\n                }\n            `;document.head.appendChild(style);return()=>{document.head.removeChild(style);};},[]);useEffect(()=>{const onResize=()=>{if(window.matchMedia(\"(max-width: 609px)\").matches){setWidth(100);}else if(window.matchMedia(\"(max-width: 1100px)\").matches){setWidth(50);}else{setWidth(DEFAULT_WIDTH);}};const debouncedResize=debounce(onResize,200);window.addEventListener(\"resize\",debouncedResize);onResize();return()=>{window.removeEventListener(\"resize\",debouncedResize);};},[]);return /*#__PURE__*/_jsx(Component,{...props,className:`${props.className} grid-align`,style:{...props.style,width:`${width}vw`}});};}export function withGridWidthImage(Component){return props=>{return /*#__PURE__*/_jsx(Component,{...props,style:{...props.style,width:\"75vw\",minWidth:0}});};}\nexport const __FramerMetadata__ = {\"exports\":{\"withGridLine\":{\"type\":\"reactHoc\",\"name\":\"withGridLine\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"withGridWidth\":{\"type\":\"reactHoc\",\"name\":\"withGridWidth\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"withGridWidthImage\":{\"type\":\"reactHoc\",\"name\":\"withGridWidthImage\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./WithGrid.map"],"mappings":"0LAAuH,SAAgB,EAAa,EAAU,CAAC,MAAO,IAA4B,EAAK,EAAU,CAAC,GAAG,EAAM,MAAM,CAAC,GAAG,EAAM,MAAM,gBAAgB,UAAU,EAAE,QAAQ,CAAC,OAAO,CAAC,EAAE,CAAC,CAAC,EAAE,WAAW,CAAC,SAAS,EAAE,KAAK,CAAC,KAAK,IAAI,KAAK,CAAC,CAAC,CAAC,CAAC,CAAI,CAAC,SAAgB,EAAc,EAAU,CAAC,MAAO,IAAO,CAAC,GAA4B,CAAC,EAAM,GAAUA,EAAS,EAAa,EAQgB,OARd,MAAc,CAAC,IAAM,EAAM,SAAS,cAAc,OAAO,EAQ/d,MARie,GAAM,YAAY;;;;;;;;cAQphB,SAAS,KAAK,YAAY,CAAK,MAAY,CAAC,SAAS,KAAK,YAAY,CAAK,CAAE,CAAE,EAAE,CAAC,CAAC,EAAE,MAAc,CAAC,IAAM,MAAa,CAAI,EAAO,WAAW,oBAAoB,CAAC,CAAC,QAAS,EAAS,GAAG,EAAW,EAAO,WAAW,qBAAqB,CAAC,CAAC,QAAS,EAAS,EAAE,EAAQ,EAAS,EAAa,CAAG,EAAQ,EAAgBC,EAAS,EAAS,GAAG,EAA+D,OAA7D,EAAO,iBAAiB,SAAS,CAAe,EAAE,EAAS,MAAY,CAAC,EAAO,oBAAoB,SAAS,CAAe,CAAE,CAAE,EAAE,CAAC,CAAC,EAAsB,EAAK,EAAU,CAAC,GAAG,EAAM,UAAU,GAAG,EAAM,UAAU,aAAa,MAAM,CAAC,GAAG,EAAM,MAAM,MAAM,GAAG,EAAM,GAAG,CAAC,CAAC,CAAE,CAAE,qBAR9jB,IAAsC,IAAsC"}