mirror of
https://github.com/Sped0n/bridget.git
synced 2026-04-14 10:09:31 -07:00
build: update bundled artifacts
This commit is contained in:
File diff suppressed because one or more lines are too long
@@ -1 +0,0 @@
|
||||
import{g as t,P as e}from"./cVJHck.js";import{W as n,c as a,s,i,a as o,d as g}from"./main.js";let r=[],c={x:0,y:0};const d=new n([]),l=new n(!1),h=new n(!1),m=new n(!1);function u(){return d.get().map((t=>r[t.i]))}function f(){const t=u().slice(-s.get().trailLength);return t.slice(0,t.length-1)}function y(){const t=u();return t[t.length-1]}function I(){const t=s.get(),e=[];for(let n=0;n<5;n++)e.push(r[i(t.index+n,t.length)]);return e}function p(){const t=s.get();return r[i(t.index,t.length)]}function w(){const t=s.get();return r[g(t.index,t.length)]}function x(t){if(l.get()||h.get())return;const e={x:t.clientX,y:t.clientY};if(Math.hypot(e.x-c.x,e.y-c.y)>s.get().threshold){c=e,o();const t={i:s.get().index,...e};d.set([...d.get(),t].slice(-s.get().length))}}function W(){if(h.get())return;l.set(!0),h.set(!0),v([y(),p(),w()]);const n=t.timeline();n.to(f(),{y:"+=20",ease:e.easeIn,stagger:.075,duration:.3,delay:.1,opacity:0}),n.to(y(),{x:0,y:0,ease:e.easeInOut,duration:.7,delay:.3}),n.to(y(),{delay:.1,scale:1,ease:e.easeInOut}),n.then((()=>{h.set(!1)}))}function E(){if(h.get())return;l.set(!1),h.set(!0),U([y()]),U(f());const n=t.timeline();n.to(y(),{scale:.6,duration:.6,ease:e.easeInOut}),n.to(y(),{delay:.3,duration:.7,ease:e.easeInOut,x:d.get()[d.get().length-1].x-window.innerWidth/2,y:d.get()[d.get().length-1].y-window.innerHeight/2}),n.to(f(),{y:"-=20",ease:e.easeOut,stagger:-.1,duration:.3,opacity:1}),n.then((()=>{h.set(!1)}))}function H(e){!function(t){const e=document.createElement("div");e.className="stage";for(const n of t){const t=document.createElement("img");t.height=n.loImgH,t.width=n.loImgW,t.dataset.hiUrl=n.hiUrl,t.dataset.hiImgH=n.hiImgH.toString(),t.dataset.hiImgW=n.hiImgW.toString(),t.dataset.loUrl=n.loUrl,t.dataset.loImgH=n.loImgH.toString(),t.dataset.loImgW=n.loImgW.toString(),t.alt="image",e.append(t)}a.append(e)}(e);const n=document.getElementsByClassName("stage").item(0);r=Array.from(n.getElementsByTagName("img")),n.addEventListener("click",(()=>{W()})),n.addEventListener("keydown",(()=>{W()})),window.addEventListener("mousemove",x,{passive:!0}),l.addWatcher((()=>{m.set(l.get()&&!h.get())})),h.addWatcher((()=>{m.set(l.get()&&!h.get())})),d.addWatcher((()=>{!function(){const e=u();0!==e.length&&(U(I()),t.set(e,{x:t=>d.get()[t].x-window.innerWidth/2,y:t=>d.get()[t].y-window.innerHeight/2,opacity:t=>t+1+s.get().trailLength<=d.get().length?0:1,zIndex:t=>t,scale:.6}),l.get()&&(U(u()),v([y()]),t.set(r,{opacity:0}),t.set(y(),{opacity:1,x:0,y:0,scale:1})))}()})),U(I())}function v(t){t.forEach((t=>{t.src=t.dataset.hiUrl,t.height=parseInt(t.dataset.hiImgH),t.width=parseInt(t.dataset.hiImgW)}))}function U(t){t.forEach((t=>{t.src=t.dataset.loUrl,t.height=parseInt(t.dataset.loImgH),t.width=parseInt(t.dataset.loImgW)}))}export{m as active,d as cordHist,H as initStage,h as isAnimating,l as isOpen,E as minimizeImage};
|
||||
File diff suppressed because one or more lines are too long
1
static/bundled/js/ep7_9p.js
Normal file
1
static/bundled/js/ep7_9p.js
Normal file
File diff suppressed because one or more lines are too long
1
static/bundled/js/fRwBqI.js
Normal file
1
static/bundled/js/fRwBqI.js
Normal file
@@ -0,0 +1 @@
|
||||
import{W as e,s as t,e as n,l as a,f as s,g as c,h as o,j as l,c as m,o as i,k as d}from"./main.js";const r=new e(!1);let p,u,g,h;const E=new e(!1);let y,v,f,N=-1,w=[],x=[],I=[],B=!1;function T(){n.set(!0),I[t.get().index].scrollIntoView({block:"center",behavior:"auto"}),v.to(u,{y:"100%",ease:f.easeInOut,duration:1}),v.to(g,{opacity:0,duration:1.2,delay:.4})}function C(){const e=[];e.push(x[h.activeIndex]),e.push(x[Math.min(h.activeIndex+1,h.slides.length)]),e.push(x[Math.max(h.activeIndex-1,0)]);for(const t of e)t.src=t.dataset.src}let L=[];function k(e){c(e),!E.get()&&B&&(E.set(!0),C(),v.to(g,{opacity:1,duration:1}),v.to(u,{y:0,ease:f.easeInOut,duration:1,delay:.4}),setTimeout((()=>{n.set(!1),E.set(!1)}),1200))}function A(e){(function(e){!function(e){const t=document.createElement("div");t.className="collection";for(const[n,a]of e.entries()){const e=0!==n?d(-25,25):0,s=0!==n?d(-30,30):0,c=document.createElement("img");c.dataset.src=a.loUrl,c.height=a.loImgH,c.width=a.loImgW,c.alt=a.alt,c.style.transform=`translate3d(${e}%, ${s-50}%, 0)`,t.append(c)}m.append(t)}(e);const t=document.getElementsByClassName("collection").item(0);r.addWatcher((e=>{e?t.classList.remove("hidden"):t.classList.add("hidden")})),L=Array.from(t.getElementsByTagName("img")),L.forEach(((e,t)=>{e.addEventListener("click",(()=>{k(t)}),{passive:!0}),e.addEventListener("keydown",(()=>{k(t)}),{passive:!0}),i(e,(()=>{for(let e=0;e<5;e++){const n=t+e;n<0||n>L.length-1||(L[n].src=L[n].dataset.src)}}))}))})(e),function(e){!function(e){const t=document.createElement("div");t.className="swiper-wrapper";for(const n of e){const e=document.createElement("div");e.className="swiper-slide";const a=document.createElement("img");a.dataset.src=n.hiUrl,a.height=n.hiImgH,a.width=n.hiImgW,a.alt=n.alt,e.append(a),t.append(e)}const n=document.createElement("div");n.className="galleryInner",n.append(t);const a=document.createElement("div");a.insertAdjacentHTML("afterbegin",'<span class="num"></span><span class="num"></span><span class="num"></span><span class="num"></span>\n <span>/</span>\n <span class="num"></span><span class="num"></span><span class="num"></span><span class="num"></span>');const s=document.createElement("div"),c=document.getElementById("main")?.getAttribute("closeText");s.innerText=l(c),s.addEventListener("click",(()=>{T()}),{passive:!0}),s.addEventListener("keydown",(()=>{T()}),{passive:!0});const o=document.createElement("div");o.className="nav",o.append(a,s);const i=document.createElement("div");i.className="gallery",i.append(n),i.append(o);const d=document.createElement("div");d.className="curtain",m.append(i,d)}(e),w=Array.from(document.getElementsByClassName("nav").item(0)?.getElementsByClassName("num")??[]),p=document.getElementsByClassName("galleryInner").item(0),u=document.getElementsByClassName("gallery").item(0),g=document.getElementsByClassName("curtain").item(0),x=Array.from(u.getElementsByTagName("img")),I=Array.from(document.getElementsByClassName("collection").item(0)?.getElementsByTagName("img")??[]),t.addWatcher((()=>{const e=t.get();var n;e.index!==N&&(n=e.index,C(),h.slideTo(n,0),function(){const e=o(t.get().index+1),n=o(t.get().length);w.forEach(((t,a)=>{t.innerText=a<4?e[a]:n[a-4]}))}(),N=e.index)})),r.addWatcher((e=>{e&&n.set(!0)})),window.addEventListener("touchstart",(()=>{a().then((e=>{v=e[0],f=e[1]})).catch((e=>{console.log(e)})),s().then((e=>{y=e,h=new y(p,{spaceBetween:20}),h.on("slideChange",(({realIndex:e})=>{c(e)}))})).catch((e=>{console.log(e)})),B=!0}),{once:!0,passive:!0}),r.set(!0)}(e)}export{A as initMobile};
|
||||
@@ -1 +1 @@
|
||||
function t(t,e){return(t+1)%e}function e(t,e){return(t+e-1)%e}function n(t){return("0000"+t.toString()).slice(-4)}function s(t,e){return Math.floor(Math.random()*(e-t+1))+t}function r(t,e){new IntersectionObserver(((n,s)=>{n.forEach((n=>{n.intersectionRatio>0&&(e(t),s.disconnect())}))})).observe(t)}class i{constructor(t){this.obj=t,this.watchers=[]}get(){return this.obj}set(t){this.obj=t,this.watchers.forEach((t=>{t()}))}addWatcher(t){this.watchers.push(t)}}const o=new i(!0);let a;const c=[{threshold:20,trailLength:20},{threshold:40,trailLength:10},{threshold:80,trailLength:5},{threshold:140,trailLength:5},{threshold:200,trailLength:5}],l=new i({index:-1,length:0,threshold:c[2].threshold,trailLength:c[2].trailLength});function h(t){const e=l.get();e.index=t,l.set(e)}function d(){const e=l.get();e.index=t(e.index,e.length),l.set(e)}function m(t,e){const n=c.findIndex((e=>t.threshold===e.threshold))+e;if(n<0||n>=c.length)return t;const s=c[n];return{...t,...s}}const g=document.getElementsByClassName("threshold").item(0),u=Array.from(g.getElementsByClassName("num")),f=g.getElementsByClassName("dec").item(0),E=g.getElementsByClassName("inc").item(0),x=document.getElementsByClassName("index").item(0),y=Array.from(x.getElementsByClassName("num")),L=document.getElementsByClassName("links").item(0),B=Array.from(L.getElementsByClassName("link")),b=document.getElementById("main")?.getAttribute("currentMenuItemIndex");for(const[t,e]of B.entries())t===parseInt(b)&&(e.classList.add("current"),0!==t&&(document.title=e.innerText+" | "+document.title));function w(){const t=n(l.get().threshold);u.forEach(((e,n)=>{e.innerText=t[n]}))}function C(){const t=n(l.get().index+1),e=n(l.get().length);y.forEach(((n,s)=>{n.innerText=s<4?t[s]:e[s-4]}))}a=document.getElementsByClassName("container").item(0),o.addWatcher((()=>{o.get()?a.classList.remove("disableScroll"):a.classList.add("disableScroll")}));const N=function(){const t=document.getElementById("imagesSource");return null===t?[]:JSON.parse(t.textContent).sort(((t,e)=>t.index<e.index?-1:1))}();(function(t){const e=l.get();e.length=t,l.set(e),l.addWatcher((()=>{C(),w()}))})(N.length),w(),C(),f.addEventListener("click",(()=>{!function(){let t=l.get();t=m(t,-1),l.set(t)}()}),{passive:!0}),E.addEventListener("click",(()=>{!function(){let t=l.get();t=m(t,1),l.set(t)}()}),{passive:!0}),N.length>0&&(window.matchMedia("(hover: none)").matches?(await import("./AKxhiG.js")).initMobile(N):(await import("./4ZVXLc.js")).initStage(N));export{i as W,d as a,o as b,a as c,e as d,h as e,n as f,s as g,t as i,r as o,l as s};
|
||||
function t(t,e){return(t+1)%e}function e(t,e){return(t+e-1)%e}function n(t){return("0000"+t.toString()).slice(-4)}function s(t,e){return Math.floor(Math.random()*(e-t+1))+t}function o(t,e){new IntersectionObserver(((n,s)=>{n.forEach((n=>{n.intersectionRatio>0&&(e(t),s.disconnect())}))})).observe(t)}function r(t){return t.charAt(0).toUpperCase()+t.slice(1)}async function i(){const t=await import("./-BhIIs.js");return[t.gsap,t.Power3]}async function a(){return(await import("./ep7_9p.js")).Swiper}class c{constructor(t){this.obj=t,this.watchers=[]}get(){return this.obj}set(t){this.obj=t,this.watchers.forEach((t=>{t(this.obj)}))}addWatcher(t){this.watchers.push(t)}}const l=new c(!0);let h;const d=[{threshold:20,trailLength:20},{threshold:40,trailLength:10},{threshold:80,trailLength:5},{threshold:140,trailLength:5},{threshold:200,trailLength:5}],m=new c({index:-1,length:0,threshold:d[parseInt(sessionStorage.getItem("thresholdsIndex")||"2")].threshold,trailLength:d[parseInt(sessionStorage.getItem("thresholdsIndex")||"2")].trailLength});function g(t){const e=m.get();e.index=t,m.set(e)}function u(){const e=m.get();e.index=t(e.index,e.length),m.set(e)}function f(){const t=m.get();t.index=e(t.index,t.length),m.set(t)}function x(t,e){let n=d.findIndex((e=>t.threshold===e.threshold))+e;if(n<0||n>=d.length)return t;sessionStorage.setItem("thresholdsIndex",n.toString());const s=d[n];return{...t,...s}}const p=document.getElementsByClassName("threshold").item(0),E=Array.from(p.getElementsByClassName("num")),y=p.getElementsByClassName("dec").item(0),I=p.getElementsByClassName("inc").item(0),w=document.getElementsByClassName("index").item(0),L=Array.from(w.getElementsByClassName("num")),b=document.getElementsByClassName("links").item(0),B=Array.from(b.getElementsByClassName("link")),C=document.getElementById("main")?.getAttribute("currentMenuItemIndex");for(const[t,e]of B.entries())t===parseInt(C)&&(e.classList.add("current"),0!==t&&(document.title=e.innerText+" | "+document.title));function N(t){E.forEach(((e,n)=>{e.innerText=t[n]}))}function S(t,e){L.forEach(((n,s)=>{n.innerText=s<4?t[s]:e[s-4]}))}h=document.getElementsByClassName("container").item(0),l.addWatcher((t=>{t?h.classList.remove("disableScroll"):h.classList.add("disableScroll")}));const j=function(){const t=document.getElementById("imagesSource");return null===t?[]:JSON.parse(t.textContent).sort(((t,e)=>t.index<e.index?-1:1))}();!function(t){const e=m.get();e.length=t,x(e,0),m.set(e)}(j.length),function(){const t=m.get();N(n(t.threshold)),S(n(t.index+1),n(t.length)),m.addWatcher((t=>{S(n(t.index+1),n(t.length)),N(n(t.threshold))})),y.addEventListener("click",(()=>{!function(){let t=m.get();t=x(t,-1),m.set(t)}()}),{passive:!0}),I.addEventListener("click",(()=>{!function(){let t=m.get();t=x(t,1),m.set(t)}()}),{passive:!0})}(),j.length>0&&(window.matchMedia("(hover: none)").matches?import("./fRwBqI.js").then((t=>t.initMobile(j))).catch((t=>console.log(t))):import("./wWaJYt.js").then((t=>t.initDesktop(j))).catch((t=>console.log(t))));export{c as W,u as a,f as b,h as c,e as d,l as e,a as f,g,n as h,t as i,r as j,s as k,i as l,o,m as s};
|
||||
1
static/bundled/js/wWaJYt.js
Normal file
1
static/bundled/js/wWaJYt.js
Normal file
@@ -0,0 +1 @@
|
||||
import{l as e,c as t,W as n,s as a,i as s,a as i,d as o,b as c}from"./main.js";let r=[],d={x:0,y:0};const g=new n([]),l=new n(!1),m=new n(!1),u=new n(!1);let h,p,f=!1;function v(){return g.get().map((e=>r[e.i]))}function y(){const e=v().slice(-a.get().trailLength);return e.slice(0,e.length-1)}function w(){const e=v();return e[e.length-1]}function I(){const e=a.get(),t=[];for(let n=0;n<5;n++)t.push(r[s(e.index+n,e.length)]);return t}function x(){const e=a.get();return r[s(e.index,e.length)]}function E(){const e=a.get();return r[o(e.index,e.length)]}function L(e){if(l.get()||m.get()||!f)return;const t={x:e.clientX,y:e.clientY};if(Math.hypot(t.x-d.x,t.y-d.y)>a.get().threshold){d=t,i();const e={i:a.get().index,...t};g.set([...g.get(),e].slice(-a.get().length))}}function W(){if(m.get()||!f)return;l.set(!0),m.set(!0),k([w(),x(),E()]);const e=h.timeline();e.to(y(),{y:"+=20",ease:p.easeIn,stagger:.075,duration:.3,delay:.1,opacity:0}),e.to(w(),{x:0,y:0,ease:p.easeInOut,duration:.7,delay:.3}),e.to(w(),{delay:.1,scale:1,ease:p.easeInOut}),e.then((()=>{m.set(!1)})).catch((e=>{console.log(e)}))}function H(){if(m.get()||!f)return;l.set(!1),m.set(!0),N([w()]),N(y());const e=h.timeline();e.to(w(),{scale:.6,duration:.6,ease:p.easeInOut}),e.to(w(),{delay:.3,duration:.7,ease:p.easeInOut,x:g.get()[g.get().length-1].x-window.innerWidth/2,y:g.get()[g.get().length-1].y-window.innerHeight/2}),e.to(y(),{y:"-=20",ease:p.easeOut,stagger:-.1,duration:.3,opacity:1}),e.then((()=>{m.set(!1)})).catch((e=>{console.log(e)}))}function k(e){e.forEach((e=>{e.src=e.dataset.hiUrl,e.height=parseInt(e.dataset.hiImgH),e.width=parseInt(e.dataset.hiImgW)}))}function N(e){e.forEach((e=>{e.src=e.dataset.loUrl,e.height=parseInt(e.dataset.loImgH),e.width=parseInt(e.dataset.loImgW)}))}const b=document.createElement("div"),A=document.createElement("div");function O(e){const t=e.clientX,n=e.clientY;b.style.transform=`translate3d(${t}px, ${n}px, 0)`}function U(e){A.innerText=e}const T=document.getElementById("main"),S=[T.getAttribute("prevText"),T.getAttribute("closeText"),T.getAttribute("nextText")];function B(e){e===S[0]?$():e===S[1]?H():Y()}function X(e){if(!l.get()&&!m.get())switch(e.key){case"ArrowLeft":$();break;case"Escape":H();break;case"ArrowRight":Y()}}function Y(){m.get()||(g.set(g.get().map((e=>({...e,i:s(e.i,a.get().length)})))),i())}function $(){m.get()||(g.set(g.get().map((e=>({...e,i:o(e.i,a.get().length)})))),c())}function j(n){b.className="cursor",A.className="cursorInner",b.append(A),t.append(b),window.addEventListener("mousemove",O,{passive:!0}),u.addWatcher((e=>{e?b.classList.add("active"):b.classList.remove("active")})),function(n){!function(e){const n=document.createElement("div");n.className="stage";for(const t of e){const e=document.createElement("img");e.height=t.loImgH,e.width=t.loImgW,e.dataset.hiUrl=t.hiUrl,e.dataset.hiImgH=t.hiImgH.toString(),e.dataset.hiImgW=t.hiImgW.toString(),e.dataset.loUrl=t.loUrl,e.dataset.loImgH=t.loImgH.toString(),e.dataset.loImgW=t.loImgW.toString(),e.alt=t.alt,n.append(e)}t.append(n)}(n);const s=document.getElementsByClassName("stage").item(0);r=Array.from(s.getElementsByTagName("img")),s.addEventListener("click",(()=>{W()})),s.addEventListener("keydown",(()=>{W()})),window.addEventListener("mousemove",L,{passive:!0}),l.addWatcher((e=>{u.set(e&&!m.get())})),m.addWatcher((e=>{u.set(l.get()&&!e)})),g.addWatcher((e=>{!function(){const e=v();0!==e.length&&f&&(N(I()),h.set(e,{x:e=>g.get()[e].x-window.innerWidth/2,y:e=>g.get()[e].y-window.innerHeight/2,opacity:e=>e+1+a.get().trailLength<=g.get().length?0:1,zIndex:e=>e,scale:.6}),l.get()&&(N(v()),k([w()]),h.set(r,{opacity:0}),h.set(w(),{opacity:1,x:0,y:0,scale:1})))}()})),N(I()),window.addEventListener("mousemove",(()=>{e().then((e=>{h=e[0],p=e[1],f=!0})).catch((e=>{console.log(e)}))}),{once:!0,passive:!0})}(n),function(){const e=document.createElement("div");e.className="navOverlay";for(const t of S){const n=document.createElement("div");n.className="overlay",n.addEventListener("click",(()=>{B(t)}),{passive:!0}),n.addEventListener("keydown",(()=>{B(t)}),{passive:!0}),n.addEventListener("mouseover",(()=>{U(t)}),{passive:!0}),n.addEventListener("focus",(()=>{U(t)}),{passive:!0}),e.append(n)}u.addWatcher((()=>{u.get()?e.classList.add("active"):e.classList.remove("active")})),t.append(e),window.addEventListener("keydown",X,{passive:!0})}()}export{j as initDesktop};
|
||||
Reference in New Issue
Block a user