PageSourceSearch

https://wewere.online/assets/eventUtils-BzBD_l0W.js

js wewere.online collected 2026-10-08 09:22:24 UTC 3,993 bytes, 1 lines download raw bytes

1const I=["rgb(0, 120, 191)","rgb(255, 102, 94)","rgb(0, 169, 92)","rgb(255, 123, 75)","rgb(146, 55, 141)","rgb(255, 232, 0)","rgb(255, 72, 176)","rgb(0, 131, 138)"],R={HOUR_HUE_RANGE:5,HOUR_SAT_MIN:-5,HOUR_SAT_MAX:5,DAY_LIGHT_MIN:-7,DAY_LIGHT_MAX:15};function T(t){const n=t.match(/^hsl\(\s*(\d+)\s*,\s*(\d+)%?\s*,\s*(\d+)%?\s*\)$/);if(n)return{h:parseInt(n[1]),s:parseInt(n[2]),l:parseInt(n[3])};let e,s,a;const i=t.match(/^rgba?\(\s*([\d.]+)\s*,\s*([\d.]+)\s*,\s*([\d.]+)/);if(i)e=parseFloat(i[1])/255,s=parseFloat(i[2])/255,a=parseFloat(i[3])/255;else{let o=t.replace("#","");if(o.length===3&&(o=o[0]+o[0]+o[1]+o[1]+o[2]+o[2]),o.length!==6)return null;e=parseInt(o.slice(0,2),16)/255,s=parseInt(o.slice(2,4),16)/255,a=parseInt(o.slice(4,6),16)/255}const c=Math.max(e,s,a),r=Math.min(e,s,a),u=(c+r)/2;let h=0,f=0;if(c!==r){const o=c-r;f=u>.5?o/(2-c-r):o/(c+r),c===e?h=((s-a)/o+(s<a?6:0))/6:c===s?h=((a-e)/o+2)/6:h=((e-s)/o+4)/6}return{h:Math.round(h*360),s:Math.round(f*100),l:Math.round(u*100)}}function S(t,n,e){const s=T(t);if(!s)return t;const a=new Date(n);let i,c;if(e)try{const l=new Intl.DateTimeFormat("en-US",{timeZone:e,hour:"numeric",minute:"numeric",hour12:!1}).formatToParts(a);i=parseInt(l.find(m=>m.type==="hour")?.value??"0"),c=parseInt(l.find(m=>m.type==="minute")?.value??"0")}catch{i=a.getUTCHours(),c=a.getUTCMinutes()}else i=a.getUTCHours(),c=a.getUTCMinutes();const r=R,u=c/60,h=Math.sin(u*Math.PI*2)*(r.HOUR_HUE_RANGE/2),f=r.HOUR_SAT_MIN+(r.HOUR_SAT_MAX-r.HOUR_SAT_MIN)*(.5+.5*Math.cos(u*Math.PI*2)),o=(i+c/60)/24,M=r.DAY_LIGHT_MIN+(r.DAY_LIGHT_MAX-r.DAY_LIGHT_MIN)*(.5+.5*Math.cos((o-.5)*Math.PI*2)),d=((s.h+h)%360+360)%360,O=Math.max(0,Math.min(100,s.s+f)),A=Math.max(0,Math.min(100,s.l+M));return`hsl(${Math.round(d)}, ${Math.round(O)}%, ${Math.round(A)}%)`}const g=1.8,L=1.2,_=[[98,115,78],[100,108,82],[132,118,92],[108,102,82],[115,112,92],[140,95,72],[145,115,75],[128,98,82],[95,98,115],[92,88,108],[88,95,105]];function p([t,n,e],s){const a=i=>Math.round(Math.min(255,Math.max(0,i*s)));return`rgb(${a(t)}, ${a(n)}, ${a(e)})`}const N=_.map(t=>p(t,g)),w=_.map(t=>p(t,L));function E(t){let n=0;for(let e=0;e<t.length;e++){const s=t.charCodeAt(e);n=(n<<5)-n+s,n=n&n}return Math.abs(n)}function C(t){const n=E(t);return I[n%I.length]}function $(t,n=t.ts){const e=t.meta.cursor_color;return e?S(e,n,t.meta.tz):C(t.meta.pid)}function H(t){if(!t)return"";try{return new URL(t.startsWith("http")?t:`https://${t}`).hostname.replace("www.","")}catch{return""}}function D(t){if(!t)return"";try{return new URL(t.startsWith("http")?t:`https://${t}`).pathname||"/"}catch{return""}}function U(t,n){if(!n)return!0;const e=D(t);if(!e)return!1;const s=n.startsWith("/")?n:`/${n}`;return e.startsWith(s)}function G(t,n){if(!n||n.length===0)return!0;const e=H(t||"");for(const s of n)if(!(s.domain&&e!==s.domain)&&U(t,s.path))return!0;return!1}function P(t){const n=(t??"").trim();if(!n)return{domain:"",path:""};if(/^https?:\/\//i.test(n))try{const r=new URL(n),u=r.hostname.replace(/^www\./,""),h=r.pathname&&r.pathname!=="/"?r.pathname:"";return{domain:u,path:h}}catch{}const e=n.replace(/[?#].*$/,""),s=e.indexOf("/"),a=s===-1?e:e.slice(0,s),i=s===-1?"":e.slice(s);return a.includes(".")?{domain:a.replace(/^www\./,""),path:i}:e?{domain:"",path:e.startsWith("/")?e:`/${e}`}:{domain:"",path:""}}function x(t){if(!t.domain&&!t.path)return"";if(!t.domain)return t.path.startsWith("/")?t.path:`/${t.path}`;if(!t.path)return t.domain;const n=t.path.startsWith("/")?t.path:`/${t.path}`;return`${t.domain}${n}`}const b=2*6e4;function W(t,n=b,e=Date.now()){const s=e-n,a=new Set,i=new Set,c=new Set;for(const r of t){if(!r.meta?.pid||Math.min(r.ts,e)<s)continue;a.add(r.meta.pid);const u=r.meta.tz;if(u){i.add(u);const h=u.split("/")[0];h&&h!=="Etc"&&h!=="UTC"&&h!=="GMT"&&c.add(h)}}return{people:a.size,timezones:i.size,continents:c.size}}const F=3e5,z=9e5,y=.1,Y=3e4;export{Y as M,I as R,z as S,F as T,G as a,T as b,y as c,N as d,H as e,x as f,$ as g,w as h,C as i,P as p,W as s};

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.