{
  "version": 3,
  "sources": ["ssg:https://framerusercontent.com/modules/oaAH7umUjUOTeKmykfom/QUgwaKJzm3ppWZi5RkAd/Stores.js", "ssg:https://framerusercontent.com/modules/uaC9hWf3ec7HqMv3sXMc/CvMGzbirJDY4adFEJwd3/Hooks.js", "ssg:https://framerusercontent.com/modules/NktNXvnf4m4T7jKQcOHx/tE0GTXnTLinhu2bnx5vZ/Utilities.js", "ssg:https://framerusercontent.com/modules/6302MhFgrbrAhL3E23ix/7qAc3bZadzRIf9GvYmDW/UncodeSearch.js"],
  "sourcesContent": ["import{createStore}from\"https://framer.com/m/framer/store.js@^1.0.0\";export const useCollectionStore=createStore({})/**\n * {\n *   [collectionName]:{\n *      fieldsByID:{},\n *      fieldsByName:{},\n *      orderBy:[],\n *      cmsItems:[],\n *      realTimeSearch:{fields:[], text}\n *   }\n * }\n */;\nexport const __FramerMetadata__ = {\"exports\":{\"useCollectionStore\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./Stores.map", "// @ts-ignore\nimport{useQueryData,useIsOnFramerCanvas}from\"framer\";import{useState,useEffect,useRef,useMemo}from\"react\";import{getProps,constructFramerCMSQueryWhere}from\"https://framerusercontent.com/modules/NktNXvnf4m4T7jKQcOHx/tE0GTXnTLinhu2bnx5vZ/Utilities.js\";import{useCollectionStore}from\"https://framerusercontent.com/modules/oaAH7umUjUOTeKmykfom/QUgwaKJzm3ppWZi5RkAd/Stores.js\";/**\n * Hook to debounce a value.\n * @param {number} delay - The delay in milliseconds before showing the alert. Default is 2000.\n * @param {any} value - The value that will return after the timeout delay.\n * @returns {any} - Returns the value.\n */export const useDebouncer=({delay,value})=>{const[debouncedValue,setDebouncedValue]=useState(value);useEffect(()=>{const ID=setTimeout(()=>{setDebouncedValue(value);},delay);return()=>clearTimeout(ID);},[value]);return debouncedValue;};/**\n * Hook to manage error alerts.\n * @param {number} alertDelay - The delay in milliseconds before showing the alert. Default is 2000.\n * @returns {object} - Returns an object containing functions to manage error messages and the alert.\n */export const useErrorAlert=({alertDelay=2e3})=>{const isOnFramerCanvas=useIsOnFramerCanvas();const[hasError,setHasError]=useState(false);const[errors,setErrors]=useState([]);const timeoutIdRef=useRef(null);const addErrorMessage=text=>{if(isOnFramerCanvas)return;setErrors(prev=>[...prev,text]);setHasError(true);};const clearErrors=()=>{setErrors([]);setHasError(false);};const showErrorAlert=()=>{const id=setTimeout(()=>{alert(`\nError!\n\n${errors.join(\"\\n\")}`);},alertDelay);timeoutIdRef.current=id;};const cancelShowErrorAlert=()=>clearInterval(timeoutIdRef.current);useEffect(()=>{if(hasError)showErrorAlert();return()=>{cancelShowErrorAlert();};},[hasError,errors.length]);return{addErrorMessage,hasError};};export const useCollectionFieldSorting=({collectionName})=>{const[store,setStore]=useCollectionStore();const collection=store[collectionName];const collectionIsInitialized=!!collection;const setDirection=ascending=>{if(!collectionIsInitialized)return;setStore(prev=>({...prev,[collectionName]:{...prev[collectionName],renderKey:Math.floor(Math.random()*1e5),orderBy:[{direction:ascending?\"asc\":\"desc\",name:\"index\",type:\"Identifier\"}]}}));};return{setDirection};};export const useCollectionList=({collectionList})=>{const[collectionStore,setCollectionStore]=useCollectionStore();const[isSyncing,setIsSyncing]=useState(true);const[key,setKey]=useState(0);const isOnFramerCanvas=useIsOnFramerCanvas();const collectionName=useMemo(()=>{return isOnFramerCanvas?null:getProps({object:collectionList,target:{name:\"displayName\",type:\"string\"}});},[!!collectionList,isOnFramerCanvas]);const collection=collectionStore[collectionName];const collectionIsInitialized=!!collection;const query=useMemo(()=>{// return an empty object if on canvas view, collection is not initiated, or collecintList is not linked\nif(isOnFramerCanvas||!collectionList||!collectionIsInitialized)return{};const q=getProps({object:collectionList,target:{name:\"query\",type:\"object\"}})||null;// if a collectionList is linked, but no query is found, then it's not a colletionList\nif(!q)return null;const type=\"Identifier\";const select=[];Object.keys(collection.fieldsByID).forEach(name=>{select.push({name,type});});select.push({type,name:\"id\"});q.select=select;return q;},[!!collectionList,collectionIsInitialized,isOnFramerCanvas,collection===null||collection===void 0?void 0:collection.renderKey]);// upon any changes to the collection, the query must be updated to get the CMS items\nconst cmsItems=useMemo(()=>{if(isOnFramerCanvas||!collectionIsInitialized||!query||Object.keys(query).length<1)return[];// CMS Beta update 09/11/24\n// Collection referencing. Collection alias property is being included in 'where' tree\nconst collectionAlias=getProps({object:query,target:{name:\"alias\",type:\"string\"}});const where=constructFramerCMSQueryWhere({collectionAlias,realTimeSearch:collection.realTimeSearch,cmsFields:collection.fieldsByName});// // checks if the construct has any nodes\nconst hasNodes=Object.keys(where).length>0;// // if there's any active filters, apply them to the collection list, otherwise delete 'where'\nif(!hasNodes){delete query.where;}else{query.where=where;}// // if there's a sorting order, apply it to the collection list, otherwise delete 'orderBy'\nif(collection.orderBy.length===0){delete query.orderBy;}else if(collection.orderBy.length>0){query.orderBy=collection.orderBy;}return Object.values(useQueryData(query));},[isOnFramerCanvas,collectionIsInitialized,collection===null||collection===void 0?void 0:collection.renderKey]);//  store the cmsItems to store, and sync local state key when collection.renderKey has been changed\nuseEffect(()=>{if(collectionIsInitialized&&!isOnFramerCanvas){setIsSyncing(false);setKey(collection.renderKey);setCollectionStore(prev=>({...prev,[collectionName]:{...prev[collectionName],cmsItems}}));}},[collectionIsInitialized,isOnFramerCanvas,collection===null||collection===void 0?void 0:collection.renderKey]);// sync the collectionList with the collection in the store\nuseEffect(()=>{if(!isOnFramerCanvas&&collectionIsInitialized){setCollectionStore(prev=>({...prev,[collectionName]:{...prev[collectionName],renderKey:Math.floor(Math.random()*1e5)}}));}},[collectionList,isOnFramerCanvas,collectionIsInitialized]);// initialize collection in collectionStore\nuseEffect(()=>{if(!isOnFramerCanvas&&!collectionIsInitialized&&query){const fieldsByID=getProps({object:collectionList,target:{name:\"propertyControls\",type:\"object\"}})||{};const fieldsByName={};// populate the controls object with the control's cms field name (title) as property names\nfor(const[controlID,field]of Object.entries(fieldsByID)){// @ts-ignore\nconst{title,...otherProps}=field;fieldsByName[title]={...otherProps,id:controlID,activeFilters:[]};}setCollectionStore(prev=>({...prev,[collectionName]:{...prev[collectionName],fieldsByID,fieldsByName,orderBy:[],realTimeSearch:{fields:[],text:\"\"},cmsItems}}));}},[collectionIsInitialized,isOnFramerCanvas,!!query]);return{key,invalidCollectionList:!isOnFramerCanvas&&!!collectionList&&!query,isInitialized:!isSyncing&&collectionIsInitialized,noResults:cmsItems.length<1};};\nexport const __FramerMetadata__ = {\"exports\":{\"useDebouncer\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"useCollectionList\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"useErrorAlert\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"useCollectionFieldSorting\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./Hooks.map", "// returns boolean if a string is in ISO 8601 format\nexport function isISO8601(str){const isoDateRegex=/^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(\\.\\d+)?(Z|([+-]\\d{2}:\\d{2}))?$/;return isoDateRegex.test(str);}/**\n * Accepts a text, checks to see if it's in ISO 8601 format, if yes, resets the time and returns ISO 8601 string, otherwise return empty string.\n * @param {string} text - Date as a string in ISO 8601 format.\n * @returns {string} - Returns the same string value with the time cleared or an empty string.\n */export function resetTimeOfISODateString(text){return isISO8601(text)?`${text.substring(0,10)}T00:00:00.000Z`:\"\";}// used to find a matching active filter on CMS Fields, depending on the filter condition both value and condition have to match or only the condition\nexport function findActiveFilter({currentFilter,target}){const{condition,value}=currentFilter;const valuesMatch=value===target.value;const conditionsMatch=condition===target.condition;// value does not matter if we're checking if it's set or not\nif(condition===\"isSet\"||condition===\"notSet\")return conditionsMatch;return valuesMatch&&conditionsMatch;}export function getProps({object,target,returnParent=false}){if(!object||!target.name||!target.type)return undefined;const propMatch=object[target.name];const typeMatch=target.type.toLowerCase()===\"array\"?Array.isArray(propMatch):typeof propMatch===target.type.toLowerCase();if(propMatch&&typeMatch){// return the target or the target's parent (which will contain the target)\nreturn returnParent?object:propMatch;}for(let nestedProp in object){const value=object[nestedProp];// don't go down another level if the value is not of type object/array\nif(typeof value!==\"object\")continue;const result=getProps({returnParent,target,object:value});if(result!==undefined)return result;}}function createBinaryNode({left,right,operator}){return{left,right,operator,type:\"BinaryOperation\"};}function createCaseNode({controlId,optionIds}){const createCondition=optionId=>{return{then:{type:\"LiteralValue\",value:true},type:\"Condition\",when:{type:\"LiteralValue\",value:optionId}};};return{type:\"Case\",conditions:optionIds.map(createCondition),else:{type:\"LiteralValue\",value:false},value:{name:controlId,type:\"Identifier\"}};}function createDateNode({controlId,operator,value}){const dateType={dataType:\"DATE\",type:\"TypeCast\"};const left={...dateType,value:{name:controlId,type:\"Identifier\"}};const right={...dateType,value:{type:\"LiteralValue\",value}};return createBinaryNode({left,right,operator});}function createFunctionCallNode({binaryNode,functionName}){return{functionName,arguments:[binaryNode.left,binaryNode.right],type:\"FunctionCall\"};}function createUnaryOperationNode({value}){return{operator:\"not\",type:\"UnaryOperation\",value};}// returns the tree structure used by Framer to apply filters to collection list\nfunction createFramerFilterTree({nodes=[],operator=\"and\"}){let tree={};nodes.forEach((node,index)=>{if(index===0){tree=node;}else{tree={operator,left:tree,right:node,type:\"BinaryOperation\"};}});return tree;}// sorting the CMS only works with one sort preference at a time and only without any filters or the fiters that are currently applied.\n// this function is to always include the selected sorting CMS field a 'dummy' filter as a placeholder, it filters the CMS field if the value is set or not, escentially always including without affecting the true active filters.\nfunction sortingPlaceholderNode(sort){const controlIdentifier={name:sort.name,type:\"Identifier\"};const left=createBinaryNode({operator:\"!=\",left:controlIdentifier,right:{value:null,type:\"LiteralValue\"}});const right=createBinaryNode({operator:\"!=\",left:controlIdentifier,right:{value:\"\",type:\"LiteralValue\"}});const isSetNode=createBinaryNode({left,right,operator:\"and\"});const isNotSetNode=createUnaryOperationNode({value:isSetNode});return createFramerFilterTree({nodes:[isSetNode,isNotSetNode],operator:\"or\"});}/**\n * in collectionList.props.children.props.query.where || collectionList.props.children.props.children.props.query.where\n * this function builds the 'where' tree object which acts as the filter conditions for the collection list\n *\n * loops through each field, for each active filter in the field build a sub-tree with operator \"or\"\n * multiple selections from the same field (category) will results in \"or\" filters\n *\n * at the end, loop through all sub-trees and build the main tree with operator \"and\"\n * selections from different fields (categories) compound filters using the \"and\" operator\n *\n * @param {object} cmsFields - An object made up of the CMS fields by name which contains an array of active filters per field.\n * @param {object} realTimeSearch - An object contianing an array of CMS fields and a text value.\n * @returns {object} - Returns an object structured the way Framer stores its filter data for the CMS.\n */export function constructFramerCMSQueryWhere({cmsFields,collectionAlias,realTimeSearch}){// for every CMS field with active filters, a sub tree is created, at the end, after looping through all the fields and checking active filters, each sub tree will be combined into the main Framer filter tree\nconst subTrees=[];// if there is a search text, loop through the selected CMS fields and apply if the type is supported\nif(realTimeSearch.text){const nodes=[];// remove any duplicates\nconst realTimeSearchFields=Array.from(new Set(realTimeSearch.fields));realTimeSearchFields.forEach(fieldName=>{const control=cmsFields[fieldName]||{};const{type}=control;const controlIdentifier={collection:collectionAlias,name:control.id,type:\"Identifier\"};if(type===\"string\"){nodes.push(createFunctionCallNode({binaryNode:createBinaryNode({left:controlIdentifier,right:{value:realTimeSearch.text,type:\"LiteralValue\"},operator:\"==\"}),functionName:\"CONTAINS\"}));}});subTrees.push(createFramerFilterTree({nodes,operator:\"or\"}));}// Loop over each CMS field, extract the selected values to filter\nfor(const[fieldName,properties]of Object.entries(cmsFields)){const cmsField=cmsFields[fieldName];const{activeFilters,filteredValues,id,options,optionTitles,type}=cmsField;// early return if CMS field does not have any active filters\nif(activeFilters.length<=0)continue;const cmsField_isEnum=type===\"enum\";const cmsField_isString=type===\"string\";const cmsField_isNumber=type===\"number\";const cmsField_isBoolean=type===\"boolean\";const cmsField_isImage=type===\"responsiveimage\";const cmsField_isDate=type===\"date\";const cmsField_isLink=type===\"link\";const cmsField_isFormattedText=type===\"richtext\";const cmsField_isColor=type===\"color\";const cmsField_isFile=type===\"file\";const controlIdentifier={collection:collectionAlias,name:id,type:\"Identifier\"};/**\n         * CMS field is date when set to Date\n         */if(cmsField_isDate){const nodes=[];activeFilters.forEach(activeFilter=>{const{condition,value}=activeFilter;// for ranges add a node where minValue is less than or equal, & maxValue is greater than or equal\nif(condition===\"IS_BETWEEN_DATES\"){// inclusive : [], exclusive: ()\nconst minCondition=value.charAt(0)===\"[\"?\">=\":\">\";const maxCondition=value.charAt(value.length-1)===\"]\"?\"<=\":\"<\";const range=value.substring(1,value.length-1).split(\",\");const minValue=range[0];const maxValue=range[1];// the results will be greater than or equal to this start\nconst left=createBinaryNode({left:controlIdentifier,right:{value:minValue,type:\"LiteralValue\"},operator:minCondition});// the results will be less than or equal to this end\nconst right=createBinaryNode({left:controlIdentifier,right:{value:maxValue,type:\"LiteralValue\"},operator:maxCondition});nodes.push(createBinaryNode({left,right,operator:\"and\"}));// early return for date ranges and continue to the next active filter\nreturn;}// handles single dates\nnodes.push(createBinaryNode({left:controlIdentifier,right:{value,type:\"LiteralValue\"},operator:condition}));});subTrees.push(createFramerFilterTree({nodes,operator:\"or\"}));}/**\n         * CMS field is file when set to File\n         *\n         * Every CMS field that is an File, will only have one filter that is checking if the file is set or not\n         */if(cmsField_isFile){const logicalNotOperator=activeFilters[0].condition.charAt(0)===\"!\";const left=createBinaryNode({operator:\"!=\",left:controlIdentifier,right:{value:null,type:\"LiteralValue\"}});const right=createBinaryNode({operator:\"!=\",left:controlIdentifier,right:{value:\"\",type:\"LiteralValue\"}});const node=createBinaryNode({left,right,operator:\"and\"});subTrees.push(logicalNotOperator?createUnaryOperationNode({value:node}):node);}/**\n         * CMS field is responsiveImage when set to Image\n         *\n         * Every CMS field that is an Image, will only have one filter that is checking if the image is set or not\n         */if(cmsField_isImage){const logicalNotOperator=activeFilters[0].condition.charAt(0)===\"!\";const left=createBinaryNode({operator:\"!=\",left:controlIdentifier,right:{value:null,type:\"LiteralValue\"}});const right=createBinaryNode({operator:\"!=\",left:controlIdentifier,right:{value:\"\",type:\"LiteralValue\"}});const node=createBinaryNode({left,right,operator:\"and\"});subTrees.push(logicalNotOperator?createUnaryOperationNode({value:node}):node);}/**\n         * CMS field is richtext when set to Formatted Text\n         *\n         * Every CMS field that is a Formatted Text, will only have one filter that is checking if the formatted text is set or not\n         */if(cmsField_isFormattedText){// const logicalNotOperator =\n//     activeFilters[0].condition.charAt(0) === \"!\"\n// const left = createBinaryNode({\n//     operator: \"!=\",\n//     left: controlIdentifier,\n//     right: { value: null, type: \"LiteralValue\" },\n// })\n// const right = createBinaryNode({\n//     operator: \"!=\",\n//     left: controlIdentifier,\n//     right: { value: \"\", type: \"LiteralValue\" },\n// })\n// const node = createBinaryNode({ left, right, operator: \"and\" })\n// subTrees.push(\n//     logicalNotOperator\n//         ? createUnaryOperationNode({ value: node })\n//         : node\n// )\nconst nodes=[];activeFilters.forEach(activeFilter=>{const{condition,value}=activeFilter;let node;let logicalNotOperator=false;if(condition.includes(\"IS_SET\")){logicalNotOperator=condition.charAt(0)===\"!\";const left=createBinaryNode({operator:\"!=\",left:controlIdentifier,right:{value:null,type:\"LiteralValue\"}});const right=createBinaryNode({operator:\"!=\",left:controlIdentifier,right:{value:\"\",type:\"LiteralValue\"}});node=createBinaryNode({left,right,operator:\"and\"});}else if(condition.includes(\"STARTS_WITH\")||condition.includes(\"ENDS_WITH\")||condition.includes(\"CONTAINS\")){logicalNotOperator=condition.charAt(0)===\"!\";const functionName=logicalNotOperator?condition.substring(1):condition;node=createFunctionCallNode({binaryNode:createBinaryNode({left:controlIdentifier,right:{value,type:\"LiteralValue\"},operator:\"==\"}),functionName});}else{// handles: Equals \"==\" & Doesn't Equal \"!=\"\nnode=createBinaryNode({left:controlIdentifier,right:{value,type:\"LiteralValue\"},operator:condition});}// handles: !IS_SET, !STARTS_WITH, !ENDS_WITH, & !CONTAINS\nif(logicalNotOperator)node=createUnaryOperationNode({value:node});nodes.push(node);});subTrees.push(createFramerFilterTree({nodes,operator:\"or\"}));}/**\n         * CMS field is link when set to Link\n         *\n         * Every CMS field that is a Link, will only have one filter that is checking if the image is set or not\n         */if(cmsField_isLink){const logicalNotOperator=activeFilters[0].condition.charAt(0)===\"!\";const left=createBinaryNode({operator:\"!=\",left:controlIdentifier,right:{value:null,type:\"LiteralValue\"}});const right=createBinaryNode({operator:\"!=\",left:controlIdentifier,right:{value:\"\",type:\"LiteralValue\"}});const node=createBinaryNode({left,right,operator:\"and\"});subTrees.push(logicalNotOperator?createUnaryOperationNode({value:node}):node);}/**\n         * CMS field is boolean when set to Toggle\n         *\n         * Any CMS fields that are a Toggle will ever only have one filter with a value of either true or false.\n         */if(cmsField_isBoolean){subTrees.push(activeFilters[0].value?controlIdentifier:createUnaryOperationNode({value:controlIdentifier}));}/**\n         * CMS field is enum when set to Option\n         */if(cmsField_isEnum){// cross reference the filter values to their corresponding Framer control IDs\nconst activeFilterOptionIds=activeFilters.map(activeFilter=>{const index=optionTitles.indexOf(activeFilter.value);return options[index];});// only one node is every pushed for this type of CMS field filter. the type of node is what changes. a single filter for this field uses a binary node, more than one uses a case node\nsubTrees.push(activeFilters.length===1?createBinaryNode({left:controlIdentifier,right:{value:activeFilterOptionIds[0],type:\"LiteralValue\"},operator:activeFilters[0].condition}):createCaseNode({controlId:id,optionIds:activeFilterOptionIds}));}/**\n         * CMS field is color when set to Color\n         */// if (cmsField_isColor) {\n//     const nodes = []\n//     activeFilters.forEach((activeFilter) => {\n//         const { condition, value } = activeFilter\n//         nodes.push(\n//             createBinaryNode({\n//                 left: controlIdentifier,\n//                 right: { value, type: \"LiteralValue\" },\n//                 operator: condition,\n//             })\n//         )\n//     })\n//     subTrees.push(createFramerFilterTree({ nodes, operator: \"or\" }))\n// }\n/**\n         * CMS field is string when set to Plain Text\n         */if(cmsField_isString){const nodes=[];activeFilters.forEach(activeFilter=>{const{condition,value}=activeFilter;let node;let logicalNotOperator=false;if(condition.includes(\"IS_SET\")){logicalNotOperator=condition.charAt(0)===\"!\";const left=createBinaryNode({operator:\"!=\",left:controlIdentifier,right:{value:null,type:\"LiteralValue\"}});const right=createBinaryNode({operator:\"!=\",left:controlIdentifier,right:{value:\"\",type:\"LiteralValue\"}});node=createBinaryNode({left,right,operator:\"and\"});}else if(condition.includes(\"STARTS_WITH\")||condition.includes(\"ENDS_WITH\")||condition.includes(\"CONTAINS\")){logicalNotOperator=condition.charAt(0)===\"!\";const functionName=logicalNotOperator?condition.substring(1):condition;node=createFunctionCallNode({binaryNode:createBinaryNode({left:controlIdentifier,right:{value,type:\"LiteralValue\"},operator:\"==\"}),functionName});}else{// handles: Equals \"==\" & Doesn't Equal \"!=\"\nnode=createBinaryNode({left:controlIdentifier,right:{value,type:\"LiteralValue\"},operator:condition});}// handles: !IS_SET, !STARTS_WITH, !ENDS_WITH, & !CONTAINS\nif(logicalNotOperator)node=createUnaryOperationNode({value:node});nodes.push(node);});subTrees.push(createFramerFilterTree({nodes,operator:\"or\"}));}/**\n         * CMS filed is number when set to Number\n         */if(cmsField_isNumber){const nodes=[];activeFilters.forEach(activeFilter=>{const{condition,value}=activeFilter;// for ranges add a node where minValue is less than or equal, & maxValue is greater than or equal\nif(condition===\"IS_BETWEEN_NUMBERS\"){// inclusive : [], exclusive: ()\nconst minCondition=value.charAt(0)===\"[\"?\">=\":\">\";const maxCondition=value.charAt(value.length-1)===\"]\"?\"<=\":\"<\";const range=value.substring(1,value.length-1).split(\",\");const minValue=Number(range[0]);const maxValue=Number(range[1]);// the results will be greater than or equal to this start\nconst left=createBinaryNode({left:controlIdentifier,right:{value:minValue,type:\"LiteralValue\"},operator:minCondition});// the results will be less than or equal to this end\nconst right=createBinaryNode({left:controlIdentifier,right:{value:maxValue,type:\"LiteralValue\"},operator:maxCondition});nodes.push(createBinaryNode({left,right,operator:\"and\"}));// return early for ranges and continue to the next active filter\nreturn;}// handles single values\nnodes.push(createBinaryNode({left:controlIdentifier,right:{value,type:\"LiteralValue\"},operator:condition}));});subTrees.push(createFramerFilterTree({nodes,operator:\"or\"}));}}return createFramerFilterTree({nodes:subTrees,operator:\"and\"});}\nexport const __FramerMetadata__ = {\"exports\":{\"getProps\":{\"type\":\"function\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"findActiveFilter\":{\"type\":\"function\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"resetTimeOfISODateString\":{\"type\":\"function\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"isISO8601\":{\"type\":\"function\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"constructFramerCMSQueryWhere\":{\"type\":\"function\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./Utilities.map", "import{jsx as _jsx}from\"react/jsx-runtime\";import{useEffect,useState}from\"react\";import{addPropertyControls,ControlType}from\"framer\";import{useCollectionStore}from\"https://framerusercontent.com/modules/oaAH7umUjUOTeKmykfom/QUgwaKJzm3ppWZi5RkAd/Stores.js\";import{useDebouncer}from\"https://framerusercontent.com/modules/uaC9hWf3ec7HqMv3sXMc/CvMGzbirJDY4adFEJwd3/Hooks.js\";/**\n * @framerSupportedLayoutWidth any\n * @framerSupportedLayoutHeight any\n * @framerDisableUnlink\n */export default function UncodeSearch(props){const{collectionName,cmsFieldNames,debounceDelay,preserveFilter,redirectUrl,clearUrl,inputName,width,height}=props;const componentName=\"UncodeSearch\";if(!collectionName){console.error(\"O 'collectionName' n\\xe3o foi fornecido ao UncodeSearch.\");return /*#__PURE__*/_jsx(\"div\",{style:{color:\"red\",width:width,height:height},children:\"Error! UncodeSearch requires the 'Collection Name'.\"});}const[store,setStore]=useCollectionStore();const collection=store[collectionName];const collectionIsInitialized=!!collection;if(!collectionIsInitialized){console.warn(`A cole\\xe7\\xe3o '${collectionName}' n\\xe3o foi encontrada no store. Verifique se o nome est\\xe1 correto e se o store est\\xe1 inicializado.`);}// Fun\u00E7\u00E3o para extrair o par\u00E2metro 'search' da URL\nconst getSearchParam=()=>{if(typeof window!==\"undefined\"){const params=new URLSearchParams(window.location.search);return params.get(\"search\")||\"\";}return\"\";};// Estado para armazenar o valor do input externo\nconst[userInput,setUserInput]=useState(()=>{const querySearch=getSearchParam();if(querySearch){return querySearch;}else if(collectionIsInitialized){return collection.realTimeSearch.text||\"\";}return\"\";});const debouncedInput=useDebouncer({delay:debounceDelay,value:userInput});// Efeito para monitorar o input externo\nuseEffect(()=>{const inputSelector=`input[name=\"${inputName}\"]`;const inputElement=document.querySelector(inputSelector);if(!inputElement){console.warn(`Input com o name '${inputName}' n\\xe3o foi encontrado.`);return;}const handleInputChange=e=>{setUserInput(e.target.value);};const handleInputKeyPress=e=>{if(e.key===\"Enter\"){e.preventDefault();performRedirect();}};// Configura os event listeners\ninputElement.addEventListener(\"input\",handleInputChange);inputElement.addEventListener(\"keypress\",handleInputKeyPress);// Define o valor inicial do input externo\ninputElement.value=userInput;// Cleanup\nreturn()=>{inputElement.removeEventListener(\"input\",handleInputChange);inputElement.removeEventListener(\"keypress\",handleInputKeyPress);};},[inputName,userInput]);// Fun\u00E7\u00E3o para realizar o redirecionamento\nconst performRedirect=()=>{if(redirectUrl){const baseUrl=typeof redirectUrl===\"string\"?redirectUrl:redirectUrl.href;try{const url=new URL(baseUrl,window.location.origin);url.searchParams.set(\"search\",userInput);window.location.href=url.toString();}catch(error){console.error(\"Erro ao construir a URL de redirecionamento:\",error);}}else{console.warn(\"A prop 'redirectUrl' n\\xe3o foi fornecida.\");}};// Fun\u00E7\u00E3o para limpar a pesquisa\nconst clearSearch=()=>{setUserInput(\"\");if(collectionIsInitialized){setStore(prev=>({...prev,[collectionName]:{...prev[collectionName],realTimeSearch:{...prev[collectionName].realTimeSearch,text:\"\"}}}));}if(clearUrl){const baseUrl=typeof clearUrl===\"string\"?clearUrl:clearUrl.href;try{const url=new URL(baseUrl,window.location.origin);url.searchParams.delete(\"search\");window.location.href=url.toString();}catch(error){console.error(\"Erro ao construir a URL ap\\xf3s limpeza:\",error);}}else{const url=new URL(window.location.href);url.searchParams.delete(\"search\");window.history.replaceState({},\"\",url.toString());}};// Efeito para lidar com o bot\u00E3o de pesquisa\nuseEffect(()=>{const searchButton=document.querySelector('button[name=\"uncodesearchbutton\"][data-framer-name=\"uncodesearchbutton\"]');if(searchButton){const handleClick=e=>{e.preventDefault();performRedirect();};searchButton.addEventListener(\"click\",handleClick);// Cleanup\nreturn()=>{searchButton.removeEventListener(\"click\",handleClick);};}else{console.warn('Bot\\xe3o de pesquisa com name e data-framer-name \"uncodesearchbutton\" n\\xe3o foi encontrado.');}},[redirectUrl,userInput]);// Efeito para lidar com o bot\u00E3o de limpar\nuseEffect(()=>{const clearButton=document.querySelector('button[name=\"uncodexsearch\"][data-framer-name=\"uncodexsearch\"]');if(clearButton){const handleClick=e=>{e.preventDefault();clearSearch();};clearButton.addEventListener(\"click\",handleClick);// Cleanup\nreturn()=>{clearButton.removeEventListener(\"click\",handleClick);};}else{console.warn('Bot\\xe3o de limpar com name e data-framer-name \"uncodexsearch\" n\\xe3o foi encontrado.');}},[clearUrl]);// Atualiza o store com o input debounced\nuseEffect(()=>{if(collectionIsInitialized&&debouncedInput!==collection.realTimeSearch.text){setStore(prev=>({...prev,[collectionName]:{...prev[collectionName],renderKey:Math.floor(Math.random()*1e5),realTimeSearch:{fields:cmsFieldNames,text:debouncedInput}}}));}},[collectionIsInitialized,debouncedInput]);// Fun\u00E7\u00E3o de limpeza para resetar quando o usu\u00E1rio n\u00E3o est\u00E1 preservando o filtro de busca\nuseEffect(()=>{return()=>{if(collectionIsInitialized&&!preserveFilter){setStore(prev=>({...prev,[collectionName]:{...prev[collectionName],realTimeSearch:{...prev[collectionName].realTimeSearch,text:\"\"}}}));}};},[collectionIsInitialized,preserveFilter]);// Retorna um div transparente de 1x1 pixels\nreturn /*#__PURE__*/_jsx(\"div\",{style:{width:1,height:1,opacity:0}});}UncodeSearch.displayName=\"UncodeSearch\";UncodeSearch.defaultProps={width:1,height:1};addPropertyControls(UncodeSearch,{collectionName:{type:ControlType.String,title:\"Collection Name\",defaultValue:\"Componentes\",description:\"Deve corresponder exatamente ao nome da cole\\xe7\\xe3o.\"},cmsFieldNames:{type:ControlType.Array,control:{type:ControlType.String},title:\"Fields\",description:\"Os nomes devem corresponder exatamente aos definidos no CMS. Apenas campos de texto plano e slug.\"},debounceDelay:{type:ControlType.Number,title:\"Debounce Delay\",defaultValue:300,description:\"Tempo de atraso para debouncing em milissegundos.\"},preserveFilter:{type:ControlType.Boolean,title:\"Preserve\",defaultValue:true,hidden:()=>true,description:\"Mant\\xe9m a busca ativa ao navegar entre p\\xe1ginas; caso contr\\xe1rio, o texto da busca e o filtro s\\xe3o limpos.\"},redirectUrl:{type:ControlType.Link,title:\"Redirect URL\",description:\"URL para redirecionar com a query string de pesquisa.\",defaultValue:\"https://uncode.club\"},clearUrl:{type:ControlType.Link,title:\"Clear URL\",description:\"URL para redirecionar ap\\xf3s limpar a pesquisa.\",defaultValue:\"\"},inputName:{type:ControlType.String,title:\"Input Name\",description:\"Valor do atributo 'name' do input de pesquisa externo.\",defaultValue:\"search\"},codeBy:{type:ControlType.String,title:\"Author\",description:\"Code by UncodeStack e @omatusaelhorch.\",defaultValue:\"Autor: UncodeStack e @omatusaelhorch\"}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"UncodeSearch\",\"slots\":[],\"annotations\":{\"framerContractVersion\":\"1\",\"framerSupportedLayoutHeight\":\"any\",\"framerDisableUnlink\":\"\",\"framerSupportedLayoutWidth\":\"any\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./UncodeSearch.map"],
  "mappings": "mOAAAA,IAA4E,IAAMC,EAAmBC,EAAY,CAAC,CAAC,ECAnHC,ICAAC,IAMO,SAASC,GAAiB,CAAC,cAAAC,EAAc,OAAAC,CAAM,EAAE,CAAC,GAAK,CAAC,UAAAC,EAAU,MAA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g_sandbox_shims", "useCollectionStore", "createStore", "init_ssg_sandbox_shims", "init_ssg_sandbox_shims", "findActiveFilter", "currentFilter", "target", "condition", "value", "valuesMatch", "conditionsMatch", "getProps", "object", "returnParent", "propMatch", "typeMatch", "nestedProp", "result", "createBinaryNode", "left", "right", "operator", "createCaseNode", "controlId", "optionIds", "createCondition", "optionId", "createFunctionCallNode", "binaryNode", "functionName", "createUnaryOperationNode", "value", "createFramerFilterTree", "nodes", "operator", "tree", "node", "index", "constructFramerCMSQueryWhere", "cmsFields", "collectionAlias", "realTimeSearch", "subTrees", "nodes", "fieldName", "control", "type", "controlIdentifier", "createFunctionCallNode", "createBinaryNode", "createFramerFilterTree", "properties", "cmsField", "activeFilters", "filteredValues", "id", "options", "optionTitles", "cmsField_isEnum", "cmsField_isString", "cmsField_isNumber", "cmsField_isBoolean", "cmsField_isImage", "cmsField_isDate", "cmsField_isLink", "cmsField_isFormattedText", "cmsField_isColor", "cmsField_isFile", "activeFilter", "condition", "value", "minCondition", "maxCondition", "range", "minValue", "maxValue", "left", "right", "logicalNotOperator", "node", "createUnaryOperationNode", "functionName", "activeFilterOptionIds", "index", "createCaseNode", "useDebouncer", "delay", "value", "debouncedValue", "setDebouncedValue", "ye", "ue", "ID", "useErrorAlert", "alertDelay", "isOnFramerCanvas", "useIsOnFramerCanvas", "hasError", "setHasError", "errors", "setErrors", "timeoutIdRef", "pe", "addErrorMessage", "text", "prev", "clearErrors", "showErrorAlert", "id", "cancelShowErrorAlert", "useCollectionList", "collectionList", "collectionStore", "setCollectionStore", "useCollectionStore", "isSyncing", "setIsSyncing", "ye", "key", "setKey", "isOnFramerCanvas", "useIsOnFramerCanvas", "collectionName", "se", "getProps", "collection", "collectionIsInitialized", "query", "q", "type", "select", "name", "cmsItems", "collectionAlias", "where", "constructFramerCMSQueryWhere", "useQueryData", "ue", "prev", "fieldsByID", "fieldsByName", "controlID", "field", "title", "otherProps", "init_ssg_sandbox_shims", "UncodeSearch", "props", "collectionName", "cmsFieldNames", "debounceDelay", "preserveFilter", "redirectUrl", "clearUrl", "inputName", "width", "height", "componentName", "p", "store", "setStore", "useCollectionStore", "collection", "collectionIsInitialized", "getSearchParam", "userInput", "setUserInput", "ye", "querySearch", "debouncedInput", "useDebouncer", "ue", "inputSelector", "inputElement", "handleInputChange", "e", "handleInputKeyPress", "performRedirect", "baseUrl", "url", "error", "clearSearch", "prev", "searchButton", "handleClick", "clearButton", "addPropertyControls", "ControlType"]
}
