{"version":3,"file":"LineDraw.MQqPj2Cs.mjs","names":["useRef","__esmMin","init_ssg_sandbox_shims","window","de","c","J","init_jsx_runtime","init_npm_react_18_3_1","ce","RenderTarget","init_framer_Bf4_tcb2","ensureCss","s","CSS","withLineDraw","ref","setRef","el","forwarded","border","thin","attr","vertical","io","entries","ROOT_MARGIN","Component","props","DURATION","EASE","init_LineDraw"],"sources":["https:/framerusercontent.com/modules/KwefRtqwajKq4IhkGVW2/zdZcryO6UzALyQTtk0UX/LineDraw.js"],"sourcesContent":["import{jsx as _jsx}from\"react/jsx-runtime\";import{forwardRef,useEffect,useRef}from\"react\";import{RenderTarget}from\"framer\";/**\n * withLineDraw (BECK, alle Trennlinien)\n *\n * Die Linie zeichnet sich einmal von links nach rechts ein, sobald ihr Container\n * im Viewport ist. Kein Replay.\n * - Rahmen mit Border (Framer zeichnet sie als ::after, data-border=\"true\"):\n *   nur die Border wird per clip-path aufgedeckt, der Inhalt bleibt unberührt.\n * - Dünne Rahmen ohne Border (1-px-Linien mit Füllung): der Rahmen selbst.\n * Ohne Border und nicht dünn: nichts tun (Inhalt wird nie beschnitten).\n * Hochkant-Linien (höher als breit) zeichnen von oben nach unten.\n */const DURATION=1.4// s\n;const EASE=\"cubic-bezier(0.25, 1, 0.5, 1)\";const ROOT_MARGIN=\"0px 0px -8% 0px\";const CSS=`\n[data-bld]::after{clip-path:inset(0 100% 0 0);transition:clip-path ${DURATION}s ${EASE}}\n[data-bld=\"1\"]::after{clip-path:inset(0 0 0 0)}\n[data-bld-self]{clip-path:inset(0 100% 0 0);transition:clip-path ${DURATION}s ${EASE}}\n[data-bld-self=\"v\"]{clip-path:inset(0 0 100% 0)}\n[data-bld-self=\"1\"]{clip-path:inset(0 0 0 0)}\n`;function ensureCss(){if(document.getElementById(\"bld-css\"))return;const s=document.createElement(\"style\");s.id=\"bld-css\";s.textContent=CSS;document.head.appendChild(s);}export function withLineDraw(Component){return /*#__PURE__*/forwardRef((props,forwarded)=>{const ref=useRef(null);const setRef=el=>{ref.current=el;if(typeof forwarded===\"function\")forwarded(el);else if(forwarded)forwarded.current=el;};useEffect(()=>{const el=ref.current;if(!el||RenderTarget.current()===RenderTarget.canvas)return;if(window.matchMedia(\"(prefers-reduced-motion: reduce)\").matches||typeof IntersectionObserver===\"undefined\")return;ensureCss();const border=el.getAttribute(\"data-border\")===\"true\";const thin=Math.min(el.offsetWidth,el.offsetHeight)<=3;if(!border&&!thin)return;// kein Linien-Element (z. B. Border nur auf anderem Breakpoint)\nconst attr=border?\"data-bld\":\"data-bld-self\";const vertical=!border&&el.offsetHeight>el.offsetWidth;el.setAttribute(attr,vertical?\"v\":\"0\");const io=new IntersectionObserver(entries=>{if(!entries.some(e=>e.isIntersecting))return;io.disconnect();requestAnimationFrame(()=>el.setAttribute(attr,\"1\"));},{rootMargin:ROOT_MARGIN,threshold:0});io.observe(el);return()=>io.disconnect();},[]);return /*#__PURE__*/_jsx(Component,{...props,ref:setRef});});}\nexport const __FramerMetadata__ = {\"exports\":{\"withLineDraw\":{\"type\":\"reactHoc\",\"name\":\"withLineDraw\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./LineDraw.map"],"mappings":"A,gMAiBE,SAASY,GAAW,CAAC,GAAG,SAAS,eAAe,SAAS,EAAE,OAAO,IAAMC,EAAE,SAAS,cAAc,OAAO,EAAE,EAAE,GAAG,UAAU,EAAE,YAAYC,EAAI,SAAS,KAAK,YAAYD,CAAC,CAAE,CAAC,SAAgBE,EAAa,EAAU,CAAC,MAAoB,iBAAY,EAAM,IAAY,CAAC,IAAMC,EAAIhB,EAAO,IAAI,EAAQiB,EAAO,GAAI,CAAC,EAAI,QAAQC,EAAM,OAAOC,GAAY,WAAWA,EAAUD,CAAE,EAAUC,IAAU,EAAU,QAAQD,EAAG,EACpB,OADsBT,MAAc,CAAC,IAAMS,EAAGF,EAAI,QAAoE,GAAzD,CAACE,GAAIR,EAAa,QAAQ,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