PageSourceSearch

https://twelveearths.com/assets/entries/pages_index.7068b840.js

js twelveearths.com collected 2026-10-06 16:18:39 UTC 4,675 bytes, 1 lines download raw bytes

1import{R as x,h as E,r as k,W as j,X as h,j as t,c as I,q as g,Q as M,i as A}from"../chunks/chunk-7c95c149.js";import{a as b}from"../chunks/chunk-4c6ef037.js";import"../chunks/chunk-56865e9e.js";const R=r=>{const e=x.useRef(),n=x.useRef(),c=E(r);x.useEffect(()=>{const i=l=>{if(n.current!==void 0){const f=l-n.current;c.current(f)}n.current=l,e.current=requestAnimationFrame(i)};return e.current=requestAnimationFrame(i),()=>{e.current&&cancelAnimationFrame(e.current)}},[])};function w(r,e){const n=(e-r+180)%360-180;return n<-180?n+360:n}function v(r,e,n,c){const i=(c-90)*Math.PI/180;return[r+n*Math.cos(i),e+n*Math.sin(i)]}function $(r,e,n,c,i){const l=v(r,e,n,i),f=v(r,e,n,c),m=i-c<=180?"0":"1";return["M",l[0],l[1],"A",n,n,0,m,0,f[0],f[1],"L",r,e,"Z"].join(" ")}function P(r,e){return(r%e+e)%e}function y(r,e){return Math.atan2(Math.sin(r*(Math.PI/180))+Math.sin(e*(Math.PI/180)),Math.cos(r*(Math.PI/180))+Math.cos(e*(Math.PI/180)))*(180/Math.PI)}function z(r,e){const n=r.length,c=P(e-1,n),i=P(e+1,n),l=y(r[e],r[c]),f=y(r[e],r[i]);return[l,f]}const p=[-38,-12,12,52,72,88,116,132,168,192,236,276];function F({className:r,style:e}){k.useRef(null);const[n,c]=k.useState(!1),{ringScale:i,siteOffset:l}=j({ringScale:n?1:.8,siteOffset:n?-40:0,config:h.stiff}),[{altitude:f,azimuth:m},d]=j(()=>({altitude:90,azimuth:90,config:h.molasses}),[]);return k.useEffect(()=>{n&&d.start((s,o)=>{const a=o.springs.altitude.goal,u=o.springs.azimuth.goal;return{altitude:a+w(a,90),azimuth:u+w(u,90),config:h.stiff}})},[n]),R(s=>{s>1e3||n||d.start((o,a)=>({altitude:a.springs.altitude.goal+s*Math.random()/32,azimuth:a.springs.azimuth.goal+s*Math.random()/32,config:h.molasses}))}),b(({delta:[s,o]})=>{n||d.start((a,u)=>({altitude:u.springs.altitude.goal+360*o/window.innerHeight,azimuth:u.springs.azimuth.goal+360*s/window.innerWidth,config:h.molasses}))},{mouseOnly:!1,target:typeof window<"u"?window:void 0}),t.jsxs("svg",{className:I("w-48 h-48 icon stroke-current",r),role:"img",viewBox:"0 0 100 100",xmlns:"http://www.w3.org/2000/svg",fill:"none",children:[t.jsxs("defs",{children:[t.jsxs("mask",{id:"mask-back",children:[t.jsx(g.g,{style:{transform:i.to(s=>`scale(${s},${s})`)},"transform-origin":"50 50",children:t.jsx(g.g,{style:{transform:M([f,m],(s,o)=>{const a=90+s+"deg",u=Math.cos(o*(Math.PI/180))*Math.sign(Math.sin(o*(Math.PI/180)));return`rotate(${a}) scale(${u},1)`})},"transform-origin":"50 50",children:t.jsx("path",{d:"M 50 3.6 A 1 1 0 0 1 50 96.4",stroke:"white",vectorEffect:"non-scaling-stroke",strokeWidth:"2"})})}),t.jsx("circle",{cx:"50",cy:"50",r:"33.2",fill:"black",vectorEffect:"non-scaling-stroke",strokeWidth:"2"})]}),t.jsxs("mask",{id:"mask",children:[p.map((s,o)=>t.jsx(g.g,{style:{transform:l.to(a=>`rotate(${s}deg) translate(0,${a+"px"})`)},"transform-origin":"50 50",children:t.jsxs("g",{children:[t.jsx("circle",{cx:"50",cy:"50",r:"3.97",stroke:"white",fill:"black",vectorEffect:"non-scaling-stroke",strokeWidth:"2"}),o===3||o===10?t.jsx("circle",{cx:"50",cy:"50",r:"1",fill:"white",stroke:"none"}):null]})},o)),t.jsx("circle",{cx:"50",cy:"50",r:"33.2",fill:"black",vectorEffect:"non-scaling-stroke",strokeWidth:"2"})]}),t.jsxs("mask",{id:"mask-top",children:[t.jsx("circle",{cx:"50",cy:"50",r:"33.2",stroke:"white",fill:"black",vectorEffect:"non-scaling-stroke",strokeWidth:"2"}),t.jsx(g.g,{style:{transform:i.to(s=>`scale(${s},${s})`)},"transform-origin":"50 50",children:t.jsx(g.g,{id:"logo-ring-top",style:{transform:M([f,m],(s,o)=>{const a=90+s+"deg",u=Math.cos(o*(Math.PI/180))*Math.sign(Math.sin(o*(Math.PI/180)));return`rotate(${a}) scale(${u},1)`})},"transform-origin":"50 50",children:t.jsx("path",{d:"M 50 96.4 A 1 1 0 0 1 50 3.6",stroke:"white",vectorEffect:"non-scaling-stroke",strokeWidth:"2"})})})]})]}),t.jsx("rect",{mask:"url(#mask-back)",x:"0",y:"0",width:"100",height:"100",fill:"currentColor"}),t.jsx("g",{onPointerEnter:()=>c(!0),onPointerLeave:()=>c(!1),onPointerCancel:()=>c(!1),children:p.map((s,o)=>{const a=z(p,o);return t.jsx("path",{mask:"url(#mask)",fill:"currentColor",stroke:"none",d:$(50,50,50,a[0],a[1])},o)})}),t.jsx("rect",{mask:"url(#mask-top)",x:"0",y:"0",width:"100",height:"100",fill:"currentColor",pointerEvents:"none"})]})}function _(){return t.jsx(t.Fragment,{children:t.jsx("div",{className:"fixed inset-0 flex justify-center items-center touch-pinch-zoom",children:t.jsx(F,{})})})}const C=Object.freeze(Object.defineProperty({__proto__:null,default:_},Symbol.toStringTag,{value:"Module"})),q=[{configName:"onRenderClient",importPath:"/renderer/+onRenderClient.tsx",isValueFile:!0,exportValues:A},{configName:"Page",importPath:"/pages/index/+Page.tsx",isValueFile:!0,exportValues:C}];export{q as default};

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.