PageSourceSearch

https://4308.tech/_astro/Nav.astro_astro_type_script_index_0_lang.DgAMJ6s_.js

js 4308.tech collected 2026-09-24 11:03:35 UTC 4,175 bytes, 1 lines download raw bytes

1import{g as i}from"./index.CzGW6FVa.js";import{S as P}from"./ScrollTrigger.DNECHiyU.js";i.registerPlugin(P);const w=document.querySelector("[data-nav]"),W=document.querySelector("[data-nav-home]"),B=document.querySelector("[data-nav-middle]"),l=document.querySelector("[data-nav-toggle]"),s=document.querySelector("[data-overlay]"),b=document.querySelectorAll("[data-overlay-text]"),$=window.matchMedia("(prefers-reduced-motion: reduce)").matches,f=document.querySelector("[data-hero]"),R=document.querySelector(".hero__cta-wrap"),g=e=>Math.min(1,Math.max(0,e)),S=(e,o,r)=>e+(o-e)*r;let d=!1,c=!1;function H(){if(!s||c)return;if(c=!0,s.hidden=!1,w?.setAttribute("data-open",""),l?.setAttribute("aria-expanded","true"),l?.setAttribute("aria-label","Close menu"),document.body.style.overflow="hidden",$){i.set(s,{clipPath:"inset(0 0 0% 0)"}),i.set(b,{yPercent:0}),c=!1,d=!0;return}i.set(b,{yPercent:110}),i.timeline({onComplete:()=>{c=!1}}).to(s,{clipPath:"inset(0 0 0% 0)",duration:.7,ease:"expo.inOut"}).to(b,{yPercent:0,duration:.9,ease:"expo.out",stagger:.07},"-=0.35"),d=!0}function M(){if(!s||c)return;c=!0,w?.removeAttribute("data-open"),l?.setAttribute("aria-expanded","false"),l?.setAttribute("aria-label","Open menu"),document.body.style.overflow="";const e=()=>{s.hidden=!0,i.set(b,{yPercent:0}),c=!1,d=!1};if($){i.set(s,{clipPath:"inset(0 0 100% 0)"}),e();return}i.to(s,{clipPath:"inset(0 0 100% 0)",duration:.6,ease:"expo.inOut",onComplete:e})}l?.addEventListener("click",()=>d?M():H());s?.querySelectorAll("a").forEach(e=>e.addEventListener("click",()=>{d&&M()}));document.addEventListener("keydown",e=>{e.key==="Escape"&&d&&M()});const X=!!(w&&f&&R&&B&&W&&l&&!$);if(X)Y();else{const e=()=>f?f.offsetHeight*.5:0,o=()=>w?.classList.toggle("is-visible",window.scrollY>=e()||d);let r=!1;window.addEventListener("scroll",()=>{r||(r=!0,requestAnimationFrame(()=>{o(),r=!1}))},{passive:!0}),window.addEventListener("resize",o,{passive:!0}),o()}function Y(){const e=R,o=w,r=B,E=W,q=l,p=e.querySelector(".hero__cta"),v=e.querySelector(".hero__cta-label"),L=e.querySelector(".hero__cta-arrow");o.classList.add("morph");const j=e.parentElement,_=e.getBoundingClientRect(),u=document.createElement("div");u.style.width=`${_.width}px`,u.style.height=`${_.height}px`,u.style.marginTop=getComputedStyle(e).marginTop,u.setAttribute("aria-hidden","true"),j.insertBefore(u,e),document.body.appendChild(e),Object.assign(e.style,{position:"fixed",margin:"0",zIndex:"90",left:"0px",top:"0px"}),p.style.width="100%",p.style.height="100%",p.style.overflow="hidden",p.style.whiteSpace="nowrap",v&&(v.style.minWidth="0");const h=document.createElement("img");h.src="/figma/icon-send.svg",h.alt="",h.setAttribute("aria-hidden","true"),Object.assign(h.style,{position:"absolute",left:"50%",top:"50%",width:"30px",height:"30px",transform:"translate(-50%, -50%)",opacity:"0",pointerEvents:"none",filter:"brightness(0) invert(1)"}),p.appendChild(h),[E,q].forEach(t=>{t.style.transition="none"}),r.style.opacity="0",r.style.pointerEvents="none";let y={cx:0,cy:0,w:0,h:0},m={cx:0,cy:0,w:68,h:68},A=76;function C(){const t=u.getBoundingClientRect(),x=Math.min(336,window.innerWidth*.8);y={cx:window.innerWidth/2,cy:t.top+window.scrollY+t.height/2,w:x,h:70};const n=r.getBoundingClientRect();m={cx:n.left+n.width/2,cy:n.top+n.height/2,w:n.width,h:n.height},A=n.width+8}function O(t){t=g(t);const x=S(y.w,m.w,t),n=S(y.h,m.h,t),z=S(y.cx,m.cx,t),T=S(y.cy,m.cy,t);Object.assign(e.style,{width:`${x}px`,height:`${n}px`,left:`${z-x/2}px`,top:`${T-n/2}px`}),e.style.setProperty("--glow",String((1-t)*.7)),v&&(v.style.opacity=String(g(1-t*2.2))),L&&(L.style.opacity=String(g(1-t*2.2))),h.style.opacity=String(g((t-.5)*2.2));const a=g((t-.55)/.45);o.style.opacity=String(a),o.style.pointerEvents=a>.9?"auto":"none";const k=.4+.6*a;E.style.transform=`translateX(${(1-a)*A}px) scale(${k})`,q.style.transform=`translateX(${-(1-a)*A}px) scale(${k})`,E.style.opacity=String(a),q.style.opacity=String(a)}P.create({trigger:f,start:"top top",end:()=>"+="+Math.max(1,f.offsetHeight*.6),scrub:!0,onRefresh:C,onUpdate:t=>O(t.progress)}),C(),O(0),window.addEventListener("resize",()=>{C(),P.refresh()},{passive:!0})}

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.