{"version":3,"file":"License_cache.C8xUEQCU.mjs","names":[],"sources":["https:/framerusercontent.com/modules/TxqscBcbPXl18geyBROf/S7yZKjtqtHfQ0qiR18ts/Shared_loading_skeleton_props.js","https:/framerusercontent.com/modules/U32JRYBcPmO9IzIRP4Rj/GrFKLNDUaXKzMFWb6e2Q/License_cache.js"],"sourcesContent":["import{ControlType}from\"framer\";import{SHARED_COLORS}from\"https://framerusercontent.com/modules/Nrs4jz2AAEOfEZRQEQij/7Ao2SBt1Ssf683HHXgzl/Shared_styles.js\";export const LoadingSkeletonPropertyControls={loaderStyle:{type:ControlType.Object,title:\"🎨 Loader Style\",buttonTitle:\"Show, Size, Color\",controls:{showLoader:{type:ControlType.Boolean,title:\"Visible\",defaultValue:true},backgroundColor:{type:ControlType.Color,title:\"Background\",defaultValue:SHARED_COLORS.backgroundMuted,hidden:props=>!props.showLoader},width:{type:ControlType.Number,title:\"Width\",defaultValue:16,min:1,step:1,unit:\"px\",hidden:props=>!props.showLoader},height:{type:ControlType.Number,title:\"Height\",defaultValue:16,min:1,step:1,unit:\"px\",hidden:props=>!props.showLoader},previewLoader:{type:ControlType.Boolean,title:\"Preview\",defaultValue:false,hidden:props=>!props.showLoader,description:\"Preview the loader on the Framer canvas.\"}},description:\"Pulsing-frame animation displayed while the component loads data from Shopify, usually for a split second on first page load.\"}};\nexport const __FramerMetadata__ = {\"exports\":{\"LoadingSkeletonPropertyControls\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"LoadingSkeletonProps\":{\"type\":\"tsType\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./Shared_loading_skeleton_props.map","function _define_property(obj,key,value){if(key in obj){Object.defineProperty(obj,key,{value:value,enumerable:true,configurable:true,writable:true});}else{obj[key]=value;}return obj;}class LicenseCache{// Get cached license data\nget(){// First check in-memory cache (fastest)\nif(this.memoryCache&&this.memoryCacheTime&&Date.now()-this.memoryCacheTime<this.cacheDuration){return this.memoryCache;}// Then check localStorage (cross-tab persistence)\ntry{const stored=localStorage.getItem(this.cacheKey);if(stored){const parsed=JSON.parse(stored);if(parsed.data&&parsed.timestamp&&Date.now()-parsed.timestamp<this.cacheDuration){// Update memory cache\nthis.memoryCache=parsed.data;this.memoryCacheTime=parsed.timestamp;return parsed.data;}}}catch(error){console.warn(\"Error reading license cache from localStorage:\",error);}return null;}// Set license data in cache\nset(data){const cacheData={data:data,timestamp:Date.now()};// Update memory cache\nthis.memoryCache=data;this.memoryCacheTime=cacheData.timestamp;// Update localStorage\ntry{localStorage.setItem(this.cacheKey,JSON.stringify(cacheData));}catch(error){console.warn(\"Error saving license cache to localStorage:\",error);}}// Clear cache\nclear(){this.memoryCache=null;this.memoryCacheTime=null;try{localStorage.removeItem(this.cacheKey);}catch(error){console.warn(\"Error clearing license cache from localStorage:\",error);}}// Check if cache is valid\nisValid(){const cached=this.get();return cached!==null;}constructor(cacheDuration=6e4){_define_property(this,\"cacheDuration\",void 0);_define_property(this,\"cacheKey\",void 0);_define_property(this,\"memoryCache\",void 0);_define_property(this,\"memoryCacheTime\",void 0);// 1 minute default\nthis.cacheDuration=cacheDuration;this.cacheKey=\"frameship-license-cache\";this.memoryCache=null;this.memoryCacheTime=null;}}// Export singleton instance\nexport const licenseCache=new LicenseCache(6e4);\nexport const __FramerMetadata__ = {\"exports\":{\"licenseCache\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"LicenseCacheData\":{\"type\":\"tsType\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./License_cache.map"],"mappings":"0LAAgC,IAA4H,CAAa,EAAgC,CAAC,YAAY,CAAC,KAAK,EAAY,OAAO,MAAM,kBAAkB,YAAY,oBAAoB,SAAS,CAAC,WAAW,CAAC,KAAK,EAAY,QAAQ,MAAM,UAAU,aAAa,GAAK,CAAC,gBAAgB,CAAC,KAA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