{"version":3,"file":"StructuredData.BCTVwyGA.mjs","names":[],"sources":["https:/framerusercontent.com/modules/7kUWnApbxhKGWl2egdDY/8rHYi0IlqKWKOLi1eFsH/StructuredData.js"],"sourcesContent":["import{jsx as _jsx,jsxs as _jsxs}from\"react/jsx-runtime\";import{addPropertyControls,ControlType,RenderTarget}from\"framer\";/**\n * StructuredData\n *\n * Renders a JSON-LD <script> tag into the page so search and AI engines can\n * read structured data. Two modes:\n *  - \"article\": builds schema.org/Article from the controls (bind them to the\n *    Blog CMS fields on the /blog/:Blog template).\n *  - \"raw\": renders the JSON pasted into the `json` control as-is (used for the\n *    FAQPage on /about).\n *\n * On the Framer canvas it shows a small label instead of the invisible script.\n *\n * @framerSupportedLayoutWidth auto\n * @framerSupportedLayoutHeight auto\n */const SITE=\"https://theagi.company\";const ORG={\"@type\":\"Organization\",\"@id\":SITE+\"/#organization\",name:\"AGI, Inc.\",url:SITE,logo:{\"@type\":\"ImageObject\",url:\"https://framerusercontent.com/images/tY2sVpmcD7yDCvuFdWz3qjV4.png\"}};function isoDate(value){if(!value)return undefined;const d=new Date(value);if(isNaN(d.getTime()))return undefined;return d.toISOString().slice(0,10);}export default function StructuredData(props){const{mode,headline,slug,date,authorName,image,json}=props;let data=null;if(mode===\"article\"){if(headline){const url=SITE+\"/blog/\"+(slug||\"\");const published=isoDate(date);data={\"@context\":\"https://schema.org\",\"@type\":\"Article\",headline,url,mainEntityOfPage:{\"@type\":\"WebPage\",\"@id\":url},author:{\"@type\":authorName&&!/team/i.test(authorName)?\"Person\":\"Organization\",name:authorName||\"AGI, Inc.\"},publisher:ORG};if(image)data.image=[image];if(published){data.datePublished=published;data.dateModified=published;}}}else if(json){try{data=JSON.parse(json);}catch{data=null;}}if(RenderTarget.current()===RenderTarget.canvas){return /*#__PURE__*/_jsxs(\"div\",{style:{font:\"11px/1.4 Inter, sans-serif\",color:\"#6b6b6b\",padding:\"2px 6px\",border:\"1px dashed #bab7b5\",borderRadius:4,whiteSpace:\"nowrap\"},children:[\"JSON-LD: \",mode,data?\"\":\" (empty)\"]});}if(!data)return null;return /*#__PURE__*/_jsx(\"script\",{type:\"application/ld+json\",dangerouslySetInnerHTML:{__html:JSON.stringify(data)}});}StructuredData.defaultProps={mode:\"article\"};addPropertyControls(StructuredData,{mode:{type:ControlType.Enum,title:\"Mode\",options:[\"article\",\"raw\"],optionTitles:[\"Article (CMS)\",\"Raw JSON\"],defaultValue:\"article\"},headline:{type:ControlType.String,title:\"Headline\",hidden:p=>p.mode!==\"article\"},slug:{type:ControlType.String,title:\"Slug\",hidden:p=>p.mode!==\"article\"},date:{type:ControlType.Date,title:\"Date\",hidden:p=>p.mode!==\"article\"},authorName:{type:ControlType.String,title:\"Author\",hidden:p=>p.mode!==\"article\"},image:{type:ControlType.Image,title:\"Image\",hidden:p=>p.mode!==\"article\"},json:{type:ControlType.String,title:\"JSON\",displayTextArea:true,hidden:p=>p.mode!==\"raw\"}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"StructuredData\",\"slots\":[],\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./StructuredData.map"],"mappings":"0KAcqO,SAAS,EAAQ,EAAM,CAAC,GAAG,CAAC,EAAM,OAAiB,IAAM,EAAE,IAAI,KAAK,CAAK,EAAK,UAAM,EAAE,QAAQ,CAAC,EAAmB,OAAO,EAAE,YAAY,CAAC,CAAC,MAAM,EAAE,EAAE,CAAE,CAAC,SAAwB,EAAe,EAAM,CAAC,GAAK,CAAC,OAAK,WAAS,OAAK,OAAK,aAAW,QAAM,QAAM,EAAU,EAAK,KAAK,GAAG,IAAO,cAAc,EAAS,CAAC,IAAM,EAAI,gCAAe,GAAM,IAAU,EAAU,EAAQ,CAAI,EAAE,EAAK,CAAC,WAAW,qBAAqB,QAAQ,UAAU,WAAS,MAAI,iBAAiB,CAAC,QAAQ,UAAU,MAAM,CAAG,EAAE,OAA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