{"version":3,"file":"Examples.B20pbOY8.mjs","names":["useRef"],"sources":["https:/framerusercontent.com/modules/28rXvpPsrum7FH6cMELS/1jCAazZw1EGHjrG5Nu5D/Utils.js","https:/framer.com/m/framer/utils.js@^0.9.0","https:/framerusercontent.com/modules/iSgOkWxxMOxcyAM45Y3V/6ZsmgCnVMoOGxvjOrt2M/Examples.js"],"sourcesContent":["export const centerContent = {\n    display: \"flex\",\n    justifyContent: \"center\",\n    alignItems: \"center\"\n};\nexport const autoSizingText = {\n    width: \"max-content\",\n    wordBreak: \"break-word\",\n    overflowWrap: \"break-word\",\n    overflow: \"hidden\",\n    whiteSpace: \"pre-wrap\",\n    flexShrink: 0\n};\nexport const defaultContainerStyles = {\n    ...centerContent,\n    overflow: \"hidden\"\n};\nexport const containerStyles = defaultContainerStyles;\nexport const randomColor = ()=>\"#\" + Math.floor(Math.random() * 16777215).toString(16)\n;\n\nexport const __FramerMetadata__ = {\"exports\":{\"centerContent\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"containerStyles\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"autoSizingText\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"defaultContainerStyles\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"randomColor\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}}}}\n//# sourceMappingURL=./Utils.map","/*\n * Utils (framer/utils@0.9.0)\n *\n * Learn More: https://www.framer.com/asset-urls\n */\n\nexport * from \"https://framerusercontent.com/modules/28rXvpPsrum7FH6cMELS/1jCAazZw1EGHjrG5Nu5D/Utils.js\"\n","import{jsx as _jsx}from\"react/jsx-runtime\";import{forwardRef,useEffect,useRef}from\"react\";import{createStore}from\"https://framer.com/m/framer/store.js@^1.0.0\";import{randomColor}from\"https://framer.com/m/framer/utils.js@^0.9.0\";// Learn more: https://www.framer.com/developers/overrides/\nconst useStore=createStore({background:\"#0099FF\"});export function withRotate(Component){return /*#__PURE__*/forwardRef((props,ref)=>{return /*#__PURE__*/_jsx(Component,{ref:ref,...props,animate:{rotate:90},transition:{duration:2}});});}export function withHover(Component){return /*#__PURE__*/forwardRef((props,ref)=>{return /*#__PURE__*/_jsx(Component,{ref:ref,...props,whileHover:{scale:1.05}});});}export function withRandomColor(Component){return /*#__PURE__*/forwardRef((props,ref)=>{const[store,setStore]=useStore();return /*#__PURE__*/_jsx(Component,{ref:ref,...props,animate:{background:store.background},onClick:()=>{setStore({background:randomColor()});}});});}// Back button override\nexport function withBackButton(Component){return /*#__PURE__*/forwardRef((props,ref)=>{return /*#__PURE__*/_jsx(Component,{ref:ref,...props,onClick:()=>{const current=window.location.href;window.history.back();window.setTimeout(()=>{// If nothing changed, there was no previous page -> go home.\nif(window.location.href===current){window.location.href=\"/\";}},200);}});});}// Dynamic project count + empty-state.\n// Keeps the \"(N)\" heading equal to the number of work cards on the page (each card\n// is an <a> with an <img>); shows a \"No projects yet\" note when a category is empty.\n// Self-healing via interval + MutationObserver; zero is only trusted after it stays\n// zero for ~2s so it never flashes during load.\nexport function withDynamicCount(Component){return /*#__PURE__*/forwardRef((props,ref)=>{const localRef=useRef(null);useEffect(()=>{const el=localRef.current;if(!el)return;let zeroTicks=0;const RX=/\\(\\s*\\d+\\s*\\)/;function setCount(count){const walker=document.createTreeWalker(el,NodeFilter.SHOW_TEXT);let node;while(node=walker.nextNode()){const v=node.nodeValue||\"\";if(RX.test(v)){const next=v.replace(RX,\"(\"+count+\")\");if(node.nodeValue!==next)node.nodeValue=next;return;}}}function emptyNote(show){const host=el.parentElement||el;let note=host.querySelector(\"[data-empty-note]\");if(show){if(!note){note=document.createElement(\"div\");note.setAttribute(\"data-empty-note\",\"1\");note.textContent=\"No projects in this category yet.\";note.style.cssText=\"opacity:0.55;margin-top:24px;\";host.appendChild(note);}note.style.display=\"\";}else if(note){note.style.display=\"none\";}}function apply(){const scope=document.querySelector(\"main\")||document.body;const count=Array.from(scope.querySelectorAll(\"a\")).filter(a=>a.querySelector(\"img\")).length;setCount(count);emptyNote(false);}apply();requestAnimationFrame(apply);setTimeout(apply,50);setTimeout(apply,300);setTimeout(apply,1200);window.addEventListener(\"load\",apply);const interval=setInterval(apply,700);const scope=document.body;const observer=new MutationObserver(apply);if(scope)observer.observe(scope,{childList:true,subtree:true});return()=>{clearInterval(interval);observer.disconnect();};},[]);return /*#__PURE__*/_jsx(Component,{...props,ref:node=>{localRef.current=node;if(typeof ref===\"function\")ref(node);else if(ref)ref.current=node;}});});}\nexport const __FramerMetadata__ = {\"exports\":{\"withRotate\":{\"type\":\"reactHoc\",\"name\":\"withRotate\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"withRandomColor\":{\"type\":\"reactHoc\",\"name\":\"withRandomColor\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"withDynamicCount\":{\"type\":\"reactHoc\",\"name\":\"withDynamicCount\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"withBackButton\":{\"type\":\"reactHoc\",\"name\":\"withBackButton\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"withHover\":{\"type\":\"reactHoc\",\"name\":\"withHover\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./Examples.map"],"mappings":"kNAAa,EAAgB,CACzB,QAAS,OACT,eAAgB,SAChB,WAAY,QAChB,EAWI,CADA,GAAG,CACO,sBEPd,SAAgB,EAAiB,EAAU,CAAC,OAAoB,GAAY,EAAM,IAAM,CAAC,IAAM,EAASA,EAAO,IAAI,EAAszC,OAApzC,MAAc,CAAC,IAAM,EAAG,EAAS,QAAQ,GAAG,CAAC,EAAG,OAAuB,IAAM,EAAG,gBAAgB,SAAS,EAAS,EAAM,CAAC,IAAM,EAAO,SAAS,iBAAiB,EAAG,WAAW,SAAS,EAAM,EAAK,KAAM,EAAK,EAAO,SAAS,GAAE,CAAC,IAAM,EAAE,EAAK,WAAW,GAAG,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