{"version":3,"file":"Redirect_Migration.BWqITMcm.mjs","names":["React.useState","_jsxs","_jsx","__esmMin","init_ssg_sandbox_shims","_e","p","c","init_jsx_runtime","init_npm_react_18_3_1","window","addPropertyControls","init_framer_BWzg2IRg","ControlType","MigrationRedirectForm","baseUrl","emailParam","offerParam","offerFixed","placeholder","buttonLabel","email","setEmail","handleSubmit","e","input","url","init_Redirect_Migration"],"sources":["https:/framerusercontent.com/modules/criJ0NvB6TsGpmUg2cs4/TOHsVmjsiKQG3SWzmlOP/Redirect_Migration.js"],"sourcesContent":["import{jsx as _jsx,jsxs as _jsxs}from\"react/jsx-runtime\";import*as React from\"react\";import{addPropertyControls,ControlType}from\"framer\";/**\n * Form que captura apenas o e-mail e redireciona para:\n * https://redirect.logoseditora.com/migration/request?email=...&offer=...\n *\n * O valor de `offer` é FIXO e escolhido no painel do Framer\n * (Enum: \"anual\" ou \"trienal\"), não aparece para o usuário.\n */export default function MigrationRedirectForm({baseUrl=\"https://redirect.logoseditora.com/migration/request\",emailParam=\"email\",offerParam=\"offer\",offerFixed=\"anual\",placeholder=\"Seu e-mail\",buttonLabel=\"Continuar\"}){const[email,setEmail]=React.useState(\"\");function handleSubmit(e){e.preventDefault();const input=e.currentTarget.querySelector(\"input[type=email]\");if(input&&!input.checkValidity()){input.reportValidity();return;}// Monta a URL com e-mail + offer fixo\nconst url=new URL(baseUrl);url.searchParams.set(emailParam,email.trim());url.searchParams.set(offerParam,offerFixed)// usa o valor fixo escolhido no painel\n;window.location.href=url.toString();}const wrapperStyle={display:\"flex\",flexDirection:\"column\",gap:12,width:\"100%\",height:\"100%\",alignItems:\"center\",justifyContent:\"center\"};const inputStyle={width:\"100%\",maxWidth:300,padding:\"12px 14px\",borderRadius:10,border:\"1px solid rgba(0,0,0,0.15)\",outline:\"none\",fontSize:16};const buttonStyle={padding:\"12px 16px\",borderRadius:10,border:\"none\",fontSize:16,cursor:\"pointer\"};return /*#__PURE__*/_jsxs(\"form\",{onSubmit:handleSubmit,style:wrapperStyle,children:[/*#__PURE__*/_jsx(\"input\",{type:\"email\",required:true,autoComplete:\"email\",placeholder:placeholder,value:email,onChange:e=>setEmail(e.target.value),style:inputStyle}),/*#__PURE__*/_jsx(\"button\",{type:\"submit\",style:buttonStyle,children:buttonLabel})]});}// Propriedades configuráveis no painel do Framer\naddPropertyControls(MigrationRedirectForm,{baseUrl:{type:ControlType.String,title:\"Base URL\",defaultValue:\"https://redirect.logoseditora.com/migration/request\"},emailParam:{type:ControlType.String,title:\"Param email\",defaultValue:\"email\"},offerParam:{type:ControlType.String,title:\"Param offer\",defaultValue:\"offer\"},offerFixed:{type:ControlType.Enum,title:\"Offer (fixo)\",options:[\"anual\",\"trienal\"],optionTitles:[\"Anual\",\"Trienal\"],defaultValue:\"anual\"},placeholder:{type:ControlType.String,title:\"Placeholder\",defaultValue:\"Seu e-mail\"},buttonLabel:{type:ControlType.String,title:\"Bot\\xe3o\",defaultValue:\"Continuar\"}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"MigrationRedirectForm\",\"slots\":[],\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./Redirect_Migration.map"],"mappings":"A,+LAMG,SAAwBc,EAAsB,CAACC,UAAQ,sDAAsDC,aAAW,QAAQC,aAAW,QAAQC,aAAW,QAAQC,cAAY,aAAaC,cAAY,aAAa,CAAC,GAAK,CAACC,EAAMC,GAAUtB,EAAe,EAAE,EAAE,SAASuB,EAAaC,EAAE,CAACA,EAAE,eAAe,EAAE,IAAMC,EAAMD,EAAE,cAAc,cAAc,mBAAmB,EAAE,GAAGC,GAAO,CAACA,EAAM,cAAc,EAAE,CAACA,EAAM,eAAe,EAAE,MAAO,CAChb,IAAMC,EAAI,IAAI,IAAIX,CAAO,EAAEW,EAAI,aAAa,IAAIV,EAAWK,EAAM,KAAK,CAAC,EAAEK,EAAI,aAAa,IAAIT,EAAWC,CAA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