{"version":3,"file":"Ultimo_step.B7Vsc2VB.mjs","names":[],"sources":["https:/framerusercontent.com/modules/a1ivwdZ8DQcBfFrjA03k/jhJxwsS5uViThc0wUdV0/Ultimo_step.js"],"sourcesContent":["\"use client\";import{jsx as _jsx,jsxs as _jsxs}from\"react/jsx-runtime\";import{addPropertyControls,ControlType}from\"framer\";import{useState,useEffect}from\"react\";export default function StepViewerFinal(props){const{title=\"Finalize seu agendamento\",subtitle=\"Complete o pagamento para garantir sua avalia\\xe7\\xe3o\",extraText=\"Ap\\xf3s o pagamento, voc\\xea receber\\xe1 um e-mail de confirma\\xe7\\xe3o com os detalhes do seu agendamento.\",showCheckIcon=false,showBadge=true,currentStep=4,totalSteps=4,showDetails=true,data=\"15/06/2023\",periodo=\"Das 9h \\xe0s 13h\",endereco=\"Rua das Flores, 123\"}=props;const[isMobile,setIsMobile]=useState(false);const[dadosAgendamento,setDadosAgendamento]=useState({data,periodo,endereco});useEffect(()=>{// Capturar parâmetros da URL que vêm da página anterior\nconst urlParams=new URLSearchParams(window.location.search);// Atualizar os dados com base nos parâmetros da URL\nif(urlParams.get(\"data\")||urlParams.get(\"periodo\")||urlParams.get(\"endereco\")){const dadosUrl={data:urlParams.get(\"data\")||urlParams.get(\"date\")||data,periodo:urlParams.get(\"periodo\")||urlParams.get(\"period\")||periodo,endereco:urlParams.get(\"endereco\")||urlParams.get(\"address\")||endereco};// Formatar a data se vier no formato YYYY-MM-DD\nif(dadosUrl.data&&dadosUrl.data.includes(\"-\")){const[year,month,day]=dadosUrl.data.split(\"-\");dadosUrl.data=`${day}/${month}/${year}`;}// Formatar o período se vier codificado\nif(dadosUrl.periodo===\"manha\"){dadosUrl.periodo=\"Das 9h \\xe0s 13h\";}else if(dadosUrl.periodo===\"tarde\"){dadosUrl.periodo=\"Das 13h \\xe0s 17h\";}// Construir endereço completo se vier separado\nconst cep=urlParams.get(\"cep\");const enderecoBase=urlParams.get(\"endereco\");const numero=urlParams.get(\"numero\");const complemento=urlParams.get(\"complemento\");if(enderecoBase&&numero){let enderecoCompleto=`${enderecoBase}, ${numero}`;if(complemento){enderecoCompleto+=`, ${complemento}`;}if(cep){enderecoCompleto+=` - CEP: ${cep}`;}dadosUrl.endereco=enderecoCompleto;}// Atualizar o estado local com os dados da URL\nsetDadosAgendamento(dadosUrl);}},[]);useEffect(()=>{const checkMobile=()=>{setIsMobile(window.innerWidth<=768);};checkMobile();window.addEventListener(\"resize\",checkMobile);return()=>window.removeEventListener(\"resize\",checkMobile);},[]);const CircularProgress=()=>{const percentage=currentStep/totalSteps*100;const radius=isMobile?25:35;const circumference=2*Math.PI*radius;const strokeDasharray=circumference;const strokeDashoffset=circumference-percentage/100*circumference;const size=isMobile?60:80;return /*#__PURE__*/_jsxs(\"div\",{style:{position:\"relative\",width:`${size}px`,height:`${size}px`},children:[/*#__PURE__*/_jsxs(\"svg\",{width:size,height:size,style:{transform:\"rotate(-90deg)\"},children:[/*#__PURE__*/_jsx(\"circle\",{cx:size/2,cy:size/2,r:radius,stroke:\"#e5e7eb\",strokeWidth:isMobile?4:6,fill:\"transparent\"}),/*#__PURE__*/_jsx(\"circle\",{cx:size/2,cy:size/2,r:radius,stroke:\"#22c55e\",strokeWidth:isMobile?4:6,fill:\"transparent\",strokeDasharray:strokeDasharray,strokeDashoffset:strokeDashoffset,strokeLinecap:\"round\",style:{transition:\"stroke-dashoffset 0.8s cubic-bezier(0.4, 0, 0.2, 1)\",filter:\"drop-shadow(0 0 8px rgba(34, 197, 94, 0.3))\"}})]}),/*#__PURE__*/_jsx(\"div\",{style:{position:\"absolute\",top:\"50%\",left:\"50%\",transform:\"translate(-50%, -50%)\",fontSize:isMobile?\"12px\":\"16px\",fontWeight:\"700\",color:\"#374151\",whiteSpace:\"nowrap\",textAlign:\"center\"},children:showCheckIcon?/*#__PURE__*/_jsx(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",width:isMobile?\"24\":\"32\",height:isMobile?\"24\":\"32\",viewBox:\"0 0 24 24\",fill:\"none\",stroke:\"#22c55e\",strokeWidth:\"3\",strokeLinecap:\"round\",strokeLinejoin:\"round\",children:/*#__PURE__*/_jsx(\"polyline\",{points:\"20 6 9 17 4 12\"})}):`${currentStep} de ${totalSteps}`})]});};const detailItemStyle={display:\"flex\",justifyContent:\"space-between\",alignItems:\"flex-start\",padding:isMobile?\"10px 0\":\"12px 0\",borderBottom:\"1px solid #eee\",fontSize:isMobile?\"14px\":\"16px\",backgroundColor:\"transparent\",minHeight:isMobile?\"44px\":\"auto\"};const detailsContainerStyle={backgroundColor:\"transparent\",borderRadius:isMobile?\"8px\":\"12px\",padding:isMobile?\"12px\":\"16px\",marginBottom:\"0\",border:\"1px solid #eee\",margin:\"0\"};const successBadgeStyle={display:\"inline-flex\",alignItems:\"center\",gap:\"6px\",backgroundColor:\"#dcfce7\",color:\"#166534\",padding:\"4px 12px\",borderRadius:\"20px\",fontSize:isMobile?\"12px\":\"14px\",fontWeight:\"500\",marginBottom:isMobile?\"12px\":\"16px\"};return /*#__PURE__*/_jsxs(\"div\",{style:{fontFamily:\"Inter, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif\",backgroundColor:\"transparent\",padding:isMobile?\"0 8px\":\"0\",margin:\"0\",width:\"100%\",height:\"fit-content\",display:\"flex\",flexDirection:\"column\"},children:[/*#__PURE__*/_jsxs(\"div\",{style:{marginBottom:isMobile?\"10px\":\"15px\",textAlign:\"center\"},children:[showCheckIcon&&showBadge&&/*#__PURE__*/_jsxs(\"div\",{style:successBadgeStyle,children:[/*#__PURE__*/_jsx(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",width:\"16\",height:\"16\",viewBox:\"0 0 24 24\",fill:\"none\",stroke:\"currentColor\",strokeWidth:\"2\",strokeLinecap:\"round\",strokeLinejoin:\"round\",children:/*#__PURE__*/_jsx(\"polyline\",{points:\"20 6 9 17 4 12\"})}),\"Pagamento Aprovado\"]}),/*#__PURE__*/_jsxs(\"div\",{style:{display:\"flex\",alignItems:\"center\",justifyContent:\"center\",marginBottom:isMobile?\"8px\":\"10px\",gap:isMobile?\"8px\":\"10px\",flexDirection:isMobile?\"column\":\"row\"},children:[/*#__PURE__*/_jsx(CircularProgress,{}),/*#__PURE__*/_jsx(\"div\",{style:{textAlign:isMobile?\"center\":\"left\",flex:1,maxWidth:isMobile?\"100%\":\"400px\"},children:/*#__PURE__*/_jsx(\"h2\",{style:{color:\"#22c55e\",fontSize:isMobile?\"18px\":\"22px\",fontWeight:\"700\",margin:\"0\",lineHeight:\"1.3\"},children:title})})]}),/*#__PURE__*/_jsx(\"p\",{style:{color:\"#6b7280\",fontSize:isMobile?\"13px\":\"15px\",lineHeight:\"1.5\",margin:\"0 0 16px 0\",maxWidth:isMobile?\"100%\":\"500px\",marginLeft:\"auto\",marginRight:\"auto\"},children:subtitle}),extraText&&/*#__PURE__*/_jsx(\"p\",{style:{color:\"#374151\",fontSize:isMobile?\"12px\":\"14px\",lineHeight:\"1.5\",margin:\"0 0 20px 0\",maxWidth:isMobile?\"100%\":\"600px\",marginLeft:\"auto\",marginRight:\"auto\",fontWeight:\"500\"},children:extraText})]}),showCheckIcon&&showDetails&&/*#__PURE__*/_jsxs(\"div\",{style:detailsContainerStyle,children:[/*#__PURE__*/_jsx(\"h3\",{style:{fontSize:isMobile?\"16px\":\"18px\",fontWeight:\"600\",margin:`0 0 ${isMobile?\"8px\":\"12px\"} 0`,color:\"#374151\"},children:\"Detalhes do Agendamento\"}),/*#__PURE__*/_jsxs(\"div\",{style:detailItemStyle,children:[/*#__PURE__*/_jsx(\"span\",{style:{fontWeight:\"500\"},children:\"Data da Avalia\\xe7\\xe3o\"}),/*#__PURE__*/_jsx(\"span\",{style:{color:\"#6b7280\",fontSize:isMobile?\"12px\":\"14px\"},children:dadosAgendamento.data})]}),/*#__PURE__*/_jsxs(\"div\",{style:detailItemStyle,children:[/*#__PURE__*/_jsx(\"span\",{style:{fontWeight:\"500\"},children:\"Hor\\xe1rio\"}),/*#__PURE__*/_jsx(\"span\",{style:{color:\"#6b7280\",fontSize:isMobile?\"12px\":\"14px\"},children:dadosAgendamento.periodo})]})]})]});}// Controles de propriedade para o Framer\naddPropertyControls(StepViewerFinal,{title:{type:ControlType.String,title:\"T\\xedtulo\",defaultValue:\"Agendamento confirmado com sucesso!\"},subtitle:{type:ControlType.String,title:\"Subt\\xedtulo\",defaultValue:\"Seu pagamento foi processado e sua avalia\\xe7\\xe3o est\\xe1 agendada\"},extraText:{type:ControlType.String,title:\"Texto Adicional\",defaultValue:\"Voc\\xea receber\\xe1 um e-mail de confirma\\xe7\\xe3o em breve com todos os detalhes. Nosso avaliador entrar\\xe1 em contato 1 dia antes da visita.\"},showCheckIcon:{type:ControlType.Boolean,title:\"Mostrar \\xcdcone de Check\",defaultValue:true},showBadge:{type:ControlType.Boolean,title:\"Mostrar Badge 'Pagamento Aprovado'\",defaultValue:true,hidden:props=>!props.showCheckIcon},showDetails:{type:ControlType.Boolean,title:\"Mostrar Detalhes\",defaultValue:true,hidden:props=>!props.showCheckIcon},data:{type:ControlType.String,title:\"Data\",defaultValue:\"15/06/2023\",hidden:props=>!props.showDetails||!props.showCheckIcon},periodo:{type:ControlType.String,title:\"Per\\xedodo\",defaultValue:\"Das 9h \\xe0s 13h\",hidden:props=>!props.showDetails||!props.showCheckIcon},endereco:{type:ControlType.String,title:\"Endere\\xe7o\",defaultValue:\"Rua das Flores, 123\",hidden:props=>!props.showDetails||!props.showCheckIcon},currentStep:{type:ControlType.Number,title:\"Etapa Atual\",defaultValue:4,min:1,max:10,step:1},totalSteps:{type:ControlType.Number,title:\"Total de Etapas\",defaultValue:4,min:1,max:10,step:1}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"StepViewerFinal\",\"slots\":[],\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./Ultimo_step.map"],"mappings":"yTAAgK,SAAwB,EAAgB,EAAM,CAAC,GAA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