{"version":3,"file":"FaqSchema.CP2o7tNJ.mjs","names":["__esmMin","init_jsx_runtime","c","addPropertyControls","init_framer_BEr93sCn","ControlType","clean","value","FaqSchema","items","parsed","props","entries","item","json","init_FaqSchema"],"sources":["https:/framerusercontent.com/modules/bVFy5ySTclCvOpyrAbgs/25QxtzHgHUEGE6ooE4Cm/FaqSchema.js"],"sourcesContent":["import{jsx as _jsx}from\"react/jsx-runtime\";import{addPropertyControls,ControlType}from\"framer\";function clean(value){return(value||\"\").replace(/\\s+/g,\" \").trim();}/**\n * FAQ-Schema fuer Seiten mit festem Text (JSON-LD)\n *\n * Eingabe: JSON mit Fragen (q) und Antworten (a), zum Beispiel\n * {\"faq\":[{\"q\":\"Frage?\",\"a\":\"Antwort.\"}]}\n * Die Fragen und Antworten muessen exakt mit dem sichtbaren Text der Seite\n * uebereinstimmen. Aendert sich eine FAQ auf der Seite, muss diese Liste\n * angepasst werden. Das Skript wird serverseitig im HTML ausgegeben.\n * Rendert selbst nichts Sichtbares.\n *\n * @framerIntrinsicWidth 1\n * @framerIntrinsicHeight 1\n *\n * @framerSupportedLayoutWidth fixed\n * @framerSupportedLayoutHeight fixed\n */export default function FaqSchema(props){let items=[];try{const parsed=JSON.parse(props.data||\"[]\");if(Array.isArray(parsed))items=parsed;else if(parsed&&Array.isArray(parsed.faq))items=parsed.faq;}catch(error){items=[];}const entries=items.filter(function(item){return item&&clean(item.q)&&clean(item.a);}).map(function(item){return{\"@type\":\"Question\",name:clean(item.q),acceptedAnswer:{\"@type\":\"Answer\",text:clean(item.a)}};});let json=\"\";if(entries.length>0){json=JSON.stringify({\"@context\":\"https://schema.org\",\"@type\":\"FAQPage\",mainEntity:entries});json=json.split(\"<\").join(\"\\\\u003c\");json=json.split(String.fromCharCode(8232)).join(\"\\\\u2028\");json=json.split(String.fromCharCode(8233)).join(\"\\\\u2029\");}return /*#__PURE__*/_jsx(\"div\",{style:{width:1,height:1,position:\"relative\",overflow:\"hidden\"},children:json?/*#__PURE__*/_jsx(\"script\",{type:\"application/ld+json\",dangerouslySetInnerHTML:{__html:json}}):null});}addPropertyControls(FaqSchema,{data:{type:ControlType.String,title:\"Fragen (JSON)\",defaultValue:\"[]\",displayTextArea:true}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"FaqSchema\",\"slots\":[],\"annotations\":{\"framerSupportedLayoutHeight\":\"fixed\",\"framerIntrinsicHeight\":\"1\",\"framerIntrinsicWidth\":\"1\",\"framerContractVersion\":\"1\",\"framerSupportedLayoutWidth\":\"fixed\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./FaqSchema.map"],"mappings":"A,4JAA+F,SAASM,EAAM,EAAM,CAAC,OAAOC,GAAO,GAAA,CAAI,QAAQ,OAAO,GAAG,CAAC,CAAC,KAAK,CAAE,CAe/J,SAAwBC,EAAU,EAAM,CAAC,IAAIC,EAAM,CAAC,EAAE,GAAG,CAAC,IAAMC,EAAO,KAAK,MAAMC,EAAM,MAAM,IAAI,EAAK,MAAM,QAAQD,CAAM,EAAE,EAAMA,EAAeA,GAAQ,MAAM,QAAQA,EAAO,GAAG,IAAE,EAAMA,EAAO,IAAI,MAAa,CAAC,EAAM,CAAC,CAAE,CAAC,IAAME,EAAQH,EAAM,OAAO,SAAS,EAAK,CAAC,OAAOI,GAAMP,EAAMO,EAAK,CAAC,GAAGP,EAAMO,EAAK,CAAC,CAAE,CAAC,CAAC,CAAC,IAAI,SAAS,EAAK,CAAC,MAAM,CAAC,QAAQ,WAAW,KAAKP,EAAMO,EAAK,CAAC,EAAE,eAAe,CAAC,QAAQ,SAAS,KAAKP,EAAMO,EAAK,CAAC,CAAC,CAAC,CAAE,CAAC,EAAMC,EAAK,GAAgR,OAA1QF,EAAQ,OAAO,IAAG,EAAK,KAAK,UAAU,CAAC,WAAW,qBAAqB,QAAQ,UAAU,WAAWA,CAAO,CAAC,EAAE,EAAKE,EAAK,MAAM,GAAG,CAAC,CAAC,KAA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