{
  "version": 3,
  "sources": ["ssg:https://framerusercontent.com/modules/yEKCyTOLQl2FKjnbfLin/nIXoYcj2TFFzAhNNn37T/Suscription_Form.js"],
  "sourcesContent": ["import{jsx as _jsx,jsxs as _jsxs}from\"react/jsx-runtime\";import{addPropertyControls,ControlType}from\"framer\";import{useState,useEffect}from\"react\";import{motion}from\"framer-motion\";const portalId=\"22632737\";const formGuid=\"d2ca8f56-a5a4-414c-8131-9d48ef92d3fc\";const hubspotUrl=`https://api.hsforms.com/submissions/v3/integration/submit/${portalId}/${formGuid}`;/**\n * These annotations control how your component sizes\n * Learn more: https://www.framer.com/developers/#code-components-auto-sizing\n *\n * @framerSupportedLayoutWidth fixed\n * @framerSupportedLayoutHeight auto\n */export default function SubscriptionForm(props){const[success,setSuccess]=useState(false);const[isLoading,setIsLoading]=useState(false);const[email,setEmail]=useState(\"\");const{color,color_2}=props;useStyles(`\n        [data-scope=\"subscription\"] input:focus,\n        [data-scope=\"subscription\"] button:focus { \n            outline: none;\n        }\n\n        [data-scope=\"subscription\"] input:-webkit-autofill,\n        [data-scope=\"subscription\"] input:-webkit-autofill:hover,\n        [data-scope=\"subscription\"] input:-webkit-autofill:focus,\n        [data-scope=\"subscription\"] input:-webkit-autofill:active {\n        background-color: transparent !important;\n        color: #fafafa !important;\n        -webkit-text-fill-color: #fafafa !important; /* Ensures text color */\n        box-shadow: 0 0 0px 1000px #141414 inset !important;\n        -webkit-box-shadow: 0 0 0px 1000px #141414 inset !important;\n        }\n\n\n        @media (max-width: 1000px) {\n            [data-scope=\"subscription\"] {\n                font-size: 16px !important;\n            }\n            [data-scope=\"subscription\"] form {\n                width: 100% !important;\n                height: 42px !important;\n            }\n            [data-scope=\"subscription\"] input {\n                width: 100% !important;\n            }\n            [data-scope=\"subscription\"] .inner {\n                padding: 12px 16px !important;\n            }\n        }\n\n        @media (min-width: 2560px) {\n            [data-scope=\"subscription\"] {\n                font-size: 32px !important;\n            }\n            [data-scope=\"subscription\"] form {\n                width: 100% !important;\n                height: 72px !important;\n            }\n            [data-scope=\"subscription\"] input {\n                width: 100% !important;\n            }\n            [data-scope=\"subscription\"] .inner {\n                padding: 17px 24px !important;\n            }\n        }\n    `);const handleSubmit=e=>{e.preventDefault();setIsLoading(true);fetch(hubspotUrl,{method:\"POST\",headers:{\"Content-Type\":\"application/json\"},body:JSON.stringify({fields:[{name:\"email\",value:email}]})}).then(response=>{if(response.ok){setSuccess(true);setEmail(\"\");}else{setSuccess(false);}}).catch(error=>{setSuccess(false);}).finally(()=>{setIsLoading(false);});};const handleChange=e=>setEmail(e.target.value);return /*#__PURE__*/_jsxs(\"div\",{style:styles.wrapper,\"data-scope\":\"subscription\",children:[/*#__PURE__*/_jsxs(\"form\",{style:styles.form,onSubmit:handleSubmit,children:[/*#__PURE__*/_jsx(\"input\",{required:true,type:\"email\",name:\"email\",className:\"input\",placeholder:\"Your email\",style:{...styles.input,color:color,border:`1px solid ${color}`},value:email,onChange:handleChange}),/*#__PURE__*/_jsx(\"button\",{style:{...styles.button,...isLoading?styles.disabled:{}},disabled:isLoading,children:/*#__PURE__*/_jsx(\"span\",{children:/*#__PURE__*/_jsx(motion.span,{className:\"inner\",style:{...styles.inner,backgroundColor:color,color:color_2},whileHover:{backgroundColor:\"#4A397C\",color:\"#fafafa\"},transition:{duration:0},children:isLoading?\"...\":\"Sign up!\"})})})]}),success&&/*#__PURE__*/_jsxs(\"div\",{style:styles.success,children:[\"Thank you for subscribing!\",/*#__PURE__*/_jsx(\"button\",{onClick:()=>setSuccess(false),style:{background:\"transparent\",border:\"none\",padding:0,margin:0,position:\"absolute\",height:\"auto\",right:\"1em\",cursor:\"pointer\"},children:/*#__PURE__*/_jsx(XIcon,{})})]})]});}const styles={wrapper:{fontSize:16,position:\"relative\"},form:{display:\"flex\",flexDirection:\"row\",alignItems:\"center\",width:\"100%\",height:56,gap:\"1em\"},input:{flex:1,margin:0,font:\"inherit\",/*         border: \"1px solid #fafafa\", */backgroundColor:\"transparent\",/*         color: \"#fafafa\", */padding:\"\",height:\"100%\",borderRadius:999,textAlign:\"center\",minWidth:0},button:{margin:0,padding:0,font:\"inherit\",background:\"transparent\",border:\"none\",cursor:\"pointer\",display:\"flex\",flexDirection:\"row\",alignItems:\"center\"},disabled:{opacity:.75,cursor:\"wait\"},inner:{verticalAlign:\"middle\",/*        backgroundColor: \"#fafafa\", *//*         color: \"#141414\", */borderRadius:999,padding:\"1.2em 2.5em\"},success:{textAlign:\"center\",marginTop:\"0.75rem\",fontSize:\"0.875em\",position:\"absolute\",bottom:\"-4em\",left:0,right:0,backgroundColor:\"#15B097\",borderRadius:999,padding:\"0.8em\"}};function XIcon(){return /*#__PURE__*/_jsxs(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",width:\"1.5em\",height:\"1.5em\",viewBox:\"0 0 24 24\",fill:\"none\",stroke:\"currentColor\",strokeWidth:\"1.5\",strokeLinecap:\"round\",strokeLinejoin:\"round\",children:[/*#__PURE__*/_jsx(\"path\",{d:\"M18 6 6 18\"}),/*#__PURE__*/_jsx(\"path\",{d:\"m6 6 12 12\"})]});}const useStyles=css=>{const STYLE_ID=\"isma\";useEffect(()=>{let styleTag=document.getElementById(STYLE_ID);if(!styleTag){styleTag=document.createElement(\"style\");styleTag.id=STYLE_ID;document.head.appendChild(styleTag);}if(!styleTag.innerHTML.includes(css)){styleTag.innerHTML+=css;}return()=>{styleTag.innerHTML=styleTag.innerHTML.replace(css,\"\");if(styleTag.innerHTML.trim()===\"\"){document.head.removeChild(styleTag);}};},[css]);};addPropertyControls(SubscriptionForm,{color:{title:\"color\",type:ControlType.Color,defaultValue:\"#fafafa\"},color_2:{title:\"color_2\",type:ControlType.Color,defaultValue:\"#141414\"}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"SubscriptionForm\",\"slots\":[],\"annotations\":{\"framerContractVersion\":\"1\",\"framerSupportedLayoutWidth\":\"fixed\",\"framerSupportedLayoutHeight\":\"auto\"}},\"__FramerMetad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AAE,QAAQ,CAAC,MAAM,UAAU,KAAKA,EAAY,MAAM,aAAa,SAAS,CAAC,CAAC",
  "names": ["init_ssg_sandbox_shims", "portalId", "formGuid", "hubspotUrl", "SubscriptionForm", "props", "success", "setSuccess", "ye", "isLoading", "setIsLoading", "email", "setEmail", "color", "color_2", "useStyles", "handleSubmit", "e", "response", "error", "handleChange", "u", "styles", "p", "motion", "XIcon", "css", "STYLE_ID", "ue", "styleTag", "addPropertyControls", "ControlType"]
}
