{"version":3,"file":"FaqSeoGenerator.0O2aCQKG.mjs","names":["React.useState"],"sources":["https:/framerusercontent.com/modules/jHv38M5pp1fECaBrFZVa/2gPqzDcwasMEx61BOb0c/FaqSeoGenerator.js"],"sourcesContent":["import{jsx as _jsx,jsxs as _jsxs}from\"react/jsx-runtime\";import*as React from\"react\";import{addPropertyControls,ControlType}from\"framer\";export default function FaqSchema(props){const{showVisual,preTitle,preTitleSize,preTitleColor,preTitleAlign,title,titleSize,titleColor,titleAlign,question1,answer1,question2,answer2,question3,answer3,question4,answer4,question5,answer5,question6,answer6,question7,answer7,question8,answer8,question9,answer9,question10,answer10}=props;if(!question1?.trim()||!answer1?.trim()){return null;}const faqData=[{q:question1,a:answer1},{q:question2,a:answer2},{q:question3,a:answer3},{q:question4,a:answer4},{q:question5,a:answer5},{q:question6,a:answer6},{q:question7,a:answer7},{q:question8,a:answer8},{q:question9,a:answer9},{q:question10,a:answer10}].filter(({q,a})=>q&&a&&q.trim()!==\"\"&&a.trim()!==\"\");const faqs=faqData.map(({q,a})=>({\"@type\":\"Question\",name:q.trim(),acceptedAnswer:{\"@type\":\"Answer\",text:a.trim()}}));const jsonLd={\"@context\":\"https://schema.org\",\"@type\":\"FAQPage\",mainEntity:faqs};React.useEffect(()=>{const pageSlug=window.location.pathname.split(\"/\").filter(Boolean).join(\"-\")||\"home\";const scriptId=`faq-schema-${pageSlug}`;const existingScript=document.getElementById(scriptId);if(existingScript)existingScript.remove();if(faqs.length>0){const script=document.createElement(\"script\");script.type=\"application/ld+json\";script.id=scriptId;script.textContent=JSON.stringify(jsonLd,null,2);document.head.appendChild(script);}},[faqs.length,jsonLd]);if(!showVisual&&faqs.length>0)return /*#__PURE__*/_jsxs(\"span\",{\"data-faq-schema\":\"true\",children:[\"FAQ Schema (\",faqs.length,\")\"]});const[openIndexes,setOpenIndexes]=React.useState([]);let titleAlignment=titleAlign?\"center\":\"left\";let preTitleAlignment=preTitleAlign?\"center\":\"left\";const leftFaqs=faqData.filter((_,i)=>i%2===0);const rightFaqs=faqData.filter((_,i)=>i%2===1);const renderItem=({q,a},index)=>/*#__PURE__*/_jsxs(\"div\",{className:\"faq-item\",children:[/*#__PURE__*/_jsxs(\"button\",{className:\"faq-question\",onClick:()=>setOpenIndexes(prev=>prev.includes(index)?prev.filter(i=>i!==index):[...prev,index]),children:[/*#__PURE__*/_jsx(\"span\",{children:q}),/*#__PURE__*/_jsx(\"span\",{className:\"chevron\",style:{transform:openIndexes.includes(index)?\"rotate(180deg)\":\"rotate(0deg)\"},children:/*#__PURE__*/_jsx(\"svg\",{xmlns:\"http://www.w3.org/2000/svg\",width:\"24\",height:\"24\",viewBox:\"0 0 24 24\",fill:\"none\",stroke:\"currentColor\",strokeWidth:\"2\",strokeLinecap:\"round\",strokeLinejoin:\"round\",children:/*#__PURE__*/_jsx(\"polyline\",{points:\"6 9 12 15 18 9\"})})})]}),openIndexes.includes(index)&&/*#__PURE__*/_jsx(\"div\",{className:\"faq-answer\",children:a})]},index);return /*#__PURE__*/_jsxs(\"div\",{className:\"faq-wrapper\",children:[preTitle&&/*#__PURE__*/_jsx(\"div\",{className:\"faq-pretitle-wrapper\",children:/*#__PURE__*/_jsx(\"p\",{className:\"faq-pretitle\",style:{color:preTitleColor,fontSize:preTitleSize,textAlign:preTitleAlignment},children:preTitle})}),/*#__PURE__*/_jsx(\"h2\",{className:\"faq-title\",style:{color:titleColor,fontSize:titleSize,textAlign:titleAlignment},children:title}),/*#__PURE__*/_jsxs(\"div\",{className:\"faq-items-columns\",children:[/*#__PURE__*/_jsx(\"div\",{className:\"faq-column\",children:leftFaqs.map((q,i)=>renderItem(q,i*2))}),/*#__PURE__*/_jsx(\"div\",{className:\"faq-column\",children:rightFaqs.map((q,i)=>renderItem(q,i*2+1))})]}),/*#__PURE__*/_jsx(\"style\",{children:`\n                .faq-wrapper {\n                    max-width: 100%;\n                    margin: auto;\n                    padding: 40px 20px;\n                    text-align: left;\n                }\n                .faq-pretitle {\n                    color: #666;\n                }\n                .faq-pretitle-wrapper {\n                    position: relative;\n                    width: fit-content;\n                    padding: 7px 20px;\n                    margin: auto;\n                    background-color: rgb(246, 238, 228);\n                    border-radius: 33px;\n                    margin-bottom: 26px;\n                }\n                .faq-title {\n                    margin-bottom: 32px;\n                    font-family: \"Martina Plantijn Regular\", sans-serif;\n                    font-weight: 400;\n                    font-size: 40px;\n                    line-height: 1.3em;\n                }\n                .faq-items-columns {\n                    display: flex;\n                    gap: 16px;\n                }\n                .faq-column {\n                    flex: 1;\n                    display: flex;\n                    flex-direction: column;\n                    gap: 16px;\n                }\n                @media (max-width: 580px) {\n                    .faq-items-columns {\n                        flex-direction: column;\n                    }\n                }\n                .faq-item {\n                    text-align: left;\n                }\n                .faq-wrapper .faq-question {\n                    width: 100%;\n                    display: flex;\n                    justify-content: space-between;\n                    align-items: flex-start;\n                    font-weight: 400;\n                    padding: 16px;\n                    background: none;\n                    border: none;\n                    cursor: pointer;\n                    border-radius: 8px;\n                    font-size: 18px;\n                    line-height: 28px;\n                    color: rgb(133, 133, 133);\n                }\n                .faq-wrapper .faq-question span {\n                    text-align: left;\n                }\n                .faq-wrapper .faq-question span svg {\n                    width: 100%;\n                    height: 100%;\n                }\n                .faq-answer {\n                    font-size: 16px;\n                    line-height: 26px;\n                    padding: 16px;\n                    color: #666666;\n                }\n                .chevron {\n                    display: inline-block;\n                    transition: transform 0.3s ease;\n                    width: 20px;\n                    min-width: 20px;\n                    max-width: 20px;\n                    margin-left: 5px;\n                }\n            `})]});}addPropertyControls(FaqSchema,{showVisual:{type:ControlType.Boolean,title:\"Afficher la FAQ\",defaultValue:true},preTitle:{type:ControlType.String,title:\"Pre-title\",defaultValue:\"Need to know\"},title:{type:ControlType.String,title:\"Title\",defaultValue:\"Frequently Asked Questions\"},titleAlign:{type:ControlType.Boolean,title:\"Center\",defaultValue:true},preTitleColor:{type:ControlType.Color,title:\"Pre-title Color\",defaultValue:\"#666\"},preTitleSize:{type:ControlType.Number,title:\"Pre-title Font Size\",defaultValue:16},preTitleAlign:{type:ControlType.Boolean,title:\"Center\",defaultValue:true},titleColor:{type:ControlType.Color,title:\"Title Color\",defaultValue:\"#000\"},titleSize:{type:ControlType.Number,title:\"Title Font Size\",defaultValue:40},question1:{type:ControlType.String,title:\"Question 1\"},answer1:{type:ControlType.String,title:\"Answer 1\"},question2:{type:ControlType.String,title:\"Question 2\"},answer2:{type:ControlType.String,title:\"Answer 2\"},question3:{type:ControlType.String,title:\"Question 3\"},answer3:{type:ControlType.String,title:\"Answer 3\"},question4:{type:ControlType.String,title:\"Question 4\"},answer4:{type:ControlType.String,title:\"Answer 4\"},question5:{type:ControlType.String,title:\"Question 5\"},answer5:{type:ControlType.String,title:\"Answer 5\"},question6:{type:ControlType.String,title:\"Question 6\"},answer6:{type:ControlType.String,title:\"Answer 6\"},question7:{type:ControlType.String,title:\"Question 7\"},answer7:{type:ControlType.String,title:\"Answer 7\"},question8:{type:ControlType.String,title:\"Question 8\"},answer8:{type:ControlType.String,title:\"Answer 8\"},question9:{type:ControlType.String,title:\"Question 9\"},answer9:{type:ControlType.String,title:\"Answer 9\"},question10:{type:ControlType.String,title:\"Question 10\"},answer10:{type:ControlType.String,title:\"Answer 10\"}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"FaqSchema\",\"slots\":[],\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./FaqSeoGenerator.map"],"mappings":"sMAAyI,SAAwB,EAAU,EAAM,CAAC,GAAK,CAAC,aAAW,WAAS,eAAa,gBAAc,gBAAc,QAAM,YAAU,aAAW,aAAW,YAAU,UAAQ,YAAU,UAAQ,YAAU,UAAQ,YAAU,UAAQ,YAAU,UAAQ,YAAU,UAAQ,YAAU,UAAQ,YAAU,UAAQ,YAAU,UAAQ,aAAW,YAAU,EAAM,GAAG,CAAC,GAAW,KAAK,GAAG,CAAC,GAAS,KAAK,EAAG,OAAO,KA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