{"version":3,"file":"PrintSearchData.Cse7DepF.mjs","names":["__esmMin","init_ssg_sandbox_shims","c","init_jsx_runtime","init_npm_react_18_3_1","ce","window","addPropertyControls","init_framer_Bf4_tcb2","ControlType","PrintSearchData","props","recordKey","record","publish","focus","manualLastPieces","detailUrl","sold","reserved","verified","total","year","title","code","place","collection","collectionName","image","keywords","init_PrintSearchData"],"sources":["https:/framerusercontent.com/modules/GgIyArr9O9xPWodyC5kL/uW4WWJ1Wu0OH3S0VtxY7/PrintSearchData.js"],"sourcesContent":["import{jsx as _jsx}from\"react/jsx-runtime\";import*as React from\"react\";import{addPropertyControls,ControlType}from\"framer\";export function usePrintCatalog(){const[data,setData]=React.useState([]);React.useEffect(()=>{const records=new Map;const receive=event=>{const detail=event.detail;if(!detail?.record?.recordKey)return;if(detail.remove)records.delete(detail.record.recordKey);else records.set(detail.record.recordKey,detail.record);setData(Array.from(records.values()));};window.addEventListener(\"jr-print-record\",receive);window.dispatchEvent(new Event(\"jr-print-request\"));return()=>window.removeEventListener(\"jr-print-record\",receive);},[]);return data;}/** @framerSupportedLayoutWidth any\n * @framerSupportedLayoutHeight any */export default function PrintSearchData(props){const{focus,manualLastPieces,detailUrl,sold,reserved,verified,total,year,recordKey,title,code,place,collection,collectionName,image,keywords}=props;React.useEffect(()=>{if(!recordKey)return;const record={focus,manualLastPieces,detailUrl,sold,reserved,verified,total,year,recordKey,title,code,place,collection,collectionName,image,keywords};const publish=()=>window.dispatchEvent(new CustomEvent(\"jr-print-record\",{detail:{record}}));window.addEventListener(\"jr-print-request\",publish);publish();return()=>{window.removeEventListener(\"jr-print-request\",publish);window.dispatchEvent(new CustomEvent(\"jr-print-record\",{detail:{record,remove:true}}));};},[focus,manualLastPieces,detailUrl,sold,reserved,verified,total,year,recordKey,title,code,place,collection,collectionName,image,keywords]);return /*#__PURE__*/_jsx(\"span\",{\"aria-hidden\":\"true\",style:{...props.style,display:\"block\",width:1,height:1,overflow:\"hidden\"}});}addPropertyControls(PrintSearchData,{focus:{type:ControlType.String,title:\"Hero focus\",defaultValue:\"center top\"},manualLastPieces:{type:ControlType.Boolean,title:\"Last pieces override\",defaultValue:false},detailUrl:{type:ControlType.Link,title:\"Print detail\"},sold:{type:ControlType.Number,title:\"Sold\"},reserved:{type:ControlType.Number,title:\"Reserved\"},verified:{type:ControlType.Boolean,title:\"Stock checked\",defaultValue:false},total:{type:ControlType.Number,title:\"Edition total\",defaultValue:15},year:{type:ControlType.String,title:\"Year\"},recordKey:{type:ControlType.String,title:\"Record key\"},title:{type:ControlType.String,title:\"Title\"},code:{type:ControlType.String,title:\"Code\"},place:{type:ControlType.String,title:\"Place\"},collectionName:{type:ControlType.String,title:\"Collection name\"},collection:{type:ControlType.Link,title:\"Collection\"},image:{type:ControlType.ResponsiveImage,title:\"Image\"},keywords:{type:ControlType.String,title:\"Keywords\"}});\nexport const __FramerMetadata__ = {\"exports\":{\"usePrintCatalog\":{\"type\":\"function\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"default\":{\"type\":\"reactComponent\",\"name\":\"PrintSearchData\",\"slots\":[],\"annotations\":{\"framerContractVersion\":\"1\",\"framerSupportedLayoutWidth\":\"any\",\"framerSupportedLayoutHeight\":\"\"}},\"PrintRecord\":{\"type\":\"tsType\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./PrintSearchData.map"],"mappings":"A,wLACsC,SAAwBU,EAAgB,EAAM,CAAC,GAAK,CAAC,QAAM,mBAAiB,YAAU,OAAK,WAAS,WAAS,QAAM,OAAK,YAAU,QAAM,OAAK,QAAM,aAAW,iBAAe,QAAM,YAAUC,EAAwoB,OAAloBN,MAAoB,CAAC,GAAG,CAACO,EAAU,OAAO,IAAMC,EAAO,CAAC,QAAM,mBAAiB,YAAU,OAAK,WAAS,WAAS,QAAM,OAAK,YAAU,QAAM,OAAK,QAAM,aAAW,iBAAe,QAAM,UAAQ,EAAQC,MAAYR,EAAO,cAAc,I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