{"version":3,"file":"dp3WklXpq.CJM0H55X.mjs","names":[],"sources":["https:/framerusercontent.com/modules/y8ko3Kyby8Do4Pal5PCE/ZR1OwnD0AmrVIafee76s/TemplateID.js","https:/framerusercontent.com/modules/GnhyrMxAz1OI4tB8QuOY/2DYW6IZQTrnkI3eK5EPl/dp3WklXpq.js"],"sourcesContent":["import{jsx as _jsx}from\"react/jsx-runtime\";import{useEffect,useRef}from\"react\";// Localstorage key\nconst WEBSITE_CONTEXT_KEY=\"websiteContext\";export const withSaveIdToLocalstorage=Component=>{return props=>{// Create a ref to get the rendered element\nconst ref=useRef(null);useEffect(()=>{var _ref_current;// Ensure we're in a browser environment\nif(typeof window===\"undefined\")return;// Get the text content (ID) from the rendered element\nconst id=(_ref_current=ref.current)===null||_ref_current===void 0?void 0:_ref_current.textContent;// Get existing data from localStorage\nconst existingData=localStorage.getItem(WEBSITE_CONTEXT_KEY);let websiteContext={};if(existingData){try{websiteContext=JSON.parse(existingData);}catch(error){console.error(\"Error parsing localStorage data:\",error);}}// Initialize the lastVisitedUseCaseTemplates array if it doesn't exist\nif(!websiteContext.lastVisitedUseCaseTemplates){websiteContext.lastVisitedUseCaseTemplates=[];}// Add the ID & page url to the lastVisitedUseCaseTemplates array if it's not already\nif(id&&!websiteContext.lastVisitedUseCaseTemplates.includes(id)){websiteContext.lastVisitedUseCaseTemplates=[...websiteContext.lastVisitedUseCaseTemplates||[],id];}// Update the pageUrl every time the component is rendered\ntry{websiteContext.pageUrl=new URL(window.location.href).pathname;}catch(error){console.error(\"Error updating pageUrl\",error);}// Save to localStorage\nlocalStorage.setItem(WEBSITE_CONTEXT_KEY,JSON.stringify(websiteContext));},[]);// Return the component with its original props\nreturn /*#__PURE__*/_jsx(Component,{...props,ref:ref});};};\nexport const __FramerMetadata__ = {\"exports\":{\"withSaveIdToLocalstorage\":{\"type\":\"reactHoc\",\"name\":\"withSaveIdToLocalstorage\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./TemplateID.map","// Generated by Framer (9f2fb1c)\nimport{fontStore}from\"framer\";fontStore.loadFonts([]);export const fonts=[{explicitInter:true,fonts:[]}];export const css=[\".framer-biavE .framer-styles-preset-11k8n1k:not(.rich-text-wrapper), .framer-biavE .framer-styles-preset-11k8n1k.rich-text-wrapper a { --framer-link-current-text-decoration: underline; --framer-link-hover-text-decoration: none; --framer-link-text-color: var(--token-b661b310-e5d7-4530-b157-7f2879548198, #1c1c1e); --framer-link-text-decoration: none; }\"];export const className=\"framer-biavE\";\nexport const __FramerMetadata__ = {\"exports\":{\"css\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"fonts\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"className\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}"],"mappings":"2PACwD,AAWlB,IAZtC,GAA2C,IAAoC,CACzE,EAAoB,iBAA8B,EAAyB,GAAmB,GAAO,CAC3G,IAAM,EAAI,EAAO,KAAK,CAQtB,MARuB,GAAU,IAAI,CAAC,IAAI,EAC1C,GAAU,WAAqB,OAE8B,IADvD,GAAI,EAAa,EAAI,UAA2D,YAChF,EAAa,aAAa,QAAQ,EAAoB,CAAK,EAAe,CAAE,EAAC,GAAG,EAAc,GAAG,CAAC,EAAe,KAAK,MAAM,EAAa,AAAE,OAAM,EAAM,CAAC,QAAQ,MAAM,mCAAmC,EAAM,AAAE,CAEvN,AADgD,EAAe,8BAA4B,CAAE,EAC1F,IAAK,EAAe,4BAA4B,SAAS,EAAG,GAAE,EAAe,4BAA4B,CAAC,GAAG,EAAe,6BAA6B,CAAE,EAAC,CAAG,GAClK,GAAG,CAAC,EAAe,QAAQ,IAAI,IAAI,EAAO,SAAS,MAAM,QAAU,OAAM,EAAM,CAAC,QAAQ,MAAM,yBAAyB,EAAM,AAAE,CAC/H,aAAa,QAAQ,EAAoB,KAAK,UAAU,EAAe,CAAC,AAAE,EAAC,CAAE,EAAC,CAC1D,EAAK,EAAU,CAAC,GAAG,EAAU,KAAI,EAAC,AAAE,mBCTob,AAA5e,GAA8B,GAAU,UAAU,CAAE,EAAC,CAAc,EAAM,CAAC,CAAC,eAAc,EAAK,MAAM,CAAE,CAAE,CAAA,EAAc,EAAI,CAAC,kWAAmW,EAAc,EAAU"}