1import{a as v,b as ce}from"./chunk-4DQV44FG.js";import{ja as oe}from"./chunk-FLKPQEL7.js";import{h as ae,k as le}from"./chunk-C6V3REVE.js";import{d as se}from"./chunk-OX365WAG.js";import"./chunk-5I6HKKJD.js";import"./chunk-4D6CHN26.js";import"./chunk-LPGHQ4JX.js";import"./chunk-L2LVDH4H.js";import"./chunk-7SY5SJP4.js";import{Z as te}from"./chunk-YNKQPWSP.js";import{z as ne}from"./chunk-4EY2W66C.js";import{d as ie}from"./chunk-ZR73OBID.js";import{c as re}from"./chunk-I6MU6NBI.js";import"./chunk-PSSDY2AS.js";import"./chunk-EDUWHTNJ.js";import"./chunk-6R4CBI6E.js";import"./chunk-ZEH2WMTB.js";import{wa as ee}from"./chunk-3H2GI3MM.js";import{$c as h,Ba as F,Cc as H,Dd as u,Ea as I,Ed as J,Ha as V,Jb as j,Ka as z,Kc as P,Kd as K,Mc as l,Qa as U,Uc as Q,Vc as X,Yc as Y,bd as g,ic as $,jc as T,jd as q,lc as y,ld as W,mb as B,na as m,oc as S,pc as M,qb as c,qc as E,rc as s,sc as a,sd as _,tc as f,td as k,ud as Z,va as p,wa as d,wb as G,xa as x,ya as w}from"./chunk-N4XFLIUN.js";import"./chunk-DIH54OSL.js";var _e=n=>({count:n}),ve=(n,r)=>r.id,be=(n,r)=>r==null?null:r.id;function Ce(n,r){if(n&1&&f(0,"figure",18),n&2){let e=r.$implicit;E("data",e)}}function xe(n,r){if(n&1&&S(0,Ce,1,1,"figure",18,be),n&2){let e=l().$implicit;M(e.image)}}function we(n,r){if(n&1&&(s(0,"div",16)(1,"div",17),T(2,xe,2,0),a()()),n&2){let e=r.$implicit,t=l(2);Y("is-portrait",t.isPortrait(e)),c(2),y(e.image.length?2:-1)}}function Te(n,r){if(n&1){let e=H();s(0,"a",1),P("click",function(i){p(e);let o=l();return d(o.onLinkClick(i))})("pointerdown",function(i){p(e);let o=l();return d(o.onPointerDown(i))})("pointermove",function(i){p(e);let o=l();return d(o.onPointerMove(i))}),s(1,"span",2),h(2),_(3,"transloco"),a(),s(4,"div",3)(5,"div",4),x(),s(6,"svg",5),f(7,"path",6),a()(),w(),s(8,"div",7),x(),s(9,"svg",5),f(10,"path",8),a()(),w(),s(11,"div",9)(12,"div",10),P("emblaChange",function(){p(e);let i=l();return d(i.syncEmblaState())}),s(13,"div",11),S(14,we,3,3,"div",12,ve),a()()(),s(16,"div",13)(17,"p",14),h(18),_(19,"transloco"),a()(),s(20,"div",15)(21,"p",14),h(22),_(23,"transloco"),a()()()()}if(n&2){let e=l();$("href",e.overviewUrl(),B),c(2),g(" ",k(3,7,"collectionTeaser.viewAll")," "),c(10),E("options",e.emblaOptions)("plugins",e.emblaPlugins)("subscribeToEvents",e.subscribeToEvents),c(2),M(e.items()),c(4),g(" ",k(19,9,"collectionTeaser.title")," "),c(4),g(" ",Z(23,11,"collectionTeaser.artworks",W(14,_e,e.items().length))," ")}}var ye=5e3,me=5,Se=.52,pe=(n,r,e)=>Math.min(Math.max(n,r),e),Ge=(()=>{class n{#s;#a;#l;#c;#m;#p;isPortrait(e){let t=e.image?.[0],i=t?.width??0,o=t?.height??0;return i>0&&o>0&&o>i}syncEmblaState(){let e=this.emblaApi();e&&this.selectedIndex.set(e.selectedSnap())}#i;#n;#o;#t;onPointerDown(e){this.#n=e.clientX,this.#o=e.clientY,this.#t=!1}onPointerMove(e){if(e.buttons===0&&e.pointerType==="mouse")return;let t=Math.abs(e.clientX-this.#n),i=Math.abs(e.clientY-this.#o);(t>me||i>me)&&(this.#t=!0)}onLinkClick(e){if(e.preventDefault(),this.#t){this.#t=!1;return}let t=this.overviewUrl();t&&this.#c.navigate([t],{fragment:"gst-content",scroll:"after-transition"})}#e;constructor(){this.#s=m(oe),this.#a=ae(le.state()),this.#l=m(F),this.#c=m(te),this.#m=m(U),this.#p=m(I),this.site=u(()=>this.#a()?.data.site),this.resource=ie({params:()=>({site:this.site()}),stream:({params:e})=>this.#s.fetch({variables:{site:e.site}})}),this.items=u(()=>this.resource.value()?.data?.collectionsEntries??[]),this.overviewUrl=u(()=>this.resource.value()?.data?.collectionsOverview?.relativeUrl??null),this.emblaRef=K(v),this.emblaApi=u(()=>this.emblaRef()?.emblaApiSignal()??null),this.emblaOptions={loop:!0,align:"center",containScroll:!1,dragFree:!1,skipSnaps:!0},this.emblaPlugins=[ce()],this.subscribeToEvents=["select","reinit"],this.selectedIndex=J(()=>this.emblaApi()?.selectedSnap()??0),this.#i=V(0),this.#n=0,this.#o=0,this.#t=!1,this.#e=null,z(e=>{let t=this.emblaApi();t&&this.#p.runOutsideAngular(()=>{this.#d(t),this.#r(t);let i=()=>this.#r(t),o=()=>{this.#d(t),this.#r(t)};t.on("scroll",i),t.on("reinit",o),t.on("slideschanged",o),e(()=>{t.off("scroll",i),t.off("reinit",o),t.off("slideschanged",o)})})}),G(()=>{let e=new IntersectionObserver(t=>{for(let i of t)i.isIntersecting?this.#f():this.#u()},{threshold:.25}
1);e.observe(this.#m.nativeElement),this.#l.onDestroy(()=>{e.disconnect(),this.#u()})})}#d(e){this.#i.set(Se*e.snapList().length)}#r(e){let t=e.internalEngine(),i=e.scrollProgress(),o=t.scrollSnapList.slidesBySnap,de=e.slideNodes(),ue=this.#i();e.snapList().forEach((b,fe)=>{let C=b-i;o[fe].forEach(D=>{t.options.loop&&t.slideLooper.loopPoints.forEach(N=>{let O=N.target();if(D===N.index&&O!==0){let L=Math.sign(O);L===-1&&(C=b-(1+i)),L===1&&(C=b+(1-i))}});let A=C*ue,he=pe(1-Math.abs(A)*.15,.8,1),ge=pe(A,-1,1),R=de[D];R.style.setProperty("--scale-factor",`${he}`),R.style.setProperty("--rotate-factor",`${ge}`)})})}#f(){this.#e===null&&(this.#e=setInterval(()=>{this.emblaRef()?.goToNext()},ye))}#u(){this.#e!==null&&(clearInterval(this.#e),this.#e=null)}static{this.\u0275fac=function(t){return new(t||n)}}static{this.\u0275cmp=j({type:n,selectors:[["ukr-collection-teaser"]],viewQuery:function(t,i){t&1&&Q(i.emblaRef,v,5),t&2&&X()},hostAttrs:[1,"block"],features:[q([re()])],decls:1,vars:1,consts:[[1,"group/teaser","drag-none","relative","block","w-full","bg-white","focus-visible:outline-0"],[1,"group/teaser","drag-none","relative","block","w-full","bg-white","focus-visible:outline-0",3,"click","pointerdown","pointermove"],[1,"sr-only"],[1,"aspect-824/555","relative","isolate","w-full","select-none"],[1,"text-green","pointer-events-none","absolute","inset-x-0","top-0","z-10","h-[28%]","overflow-hidden"],["width","2","height","1","viewBox","0 0 2 1","preserveAspectRatio","none","aria-hidden","true",1,"absolute","inset-0","h-full","w-full","text-current"],["vector-effect","non-scaling-stroke","fill","currentColor","d","M 0 0.001 l 1 1 l 1 -0.999 z M 0 -1 l 1 1 l 1 -1 z",1,"ease-smooth","origin-center","translate-y-0","transition","duration-300","group-focus-within/teaser:translate-y-full","group-hover/teaser:translate-y-full","motion-reduce:duration-0"],[1,"text-green","pointer-events-none","absolute","inset-x-0","bottom-0","z-10","h-[28%]","overflow-hidden"],["vector-effect","non-scaling-stroke","fill","currentColor","d","M0 1l1-1 1 1z M0 2l1-1 1 1",1,"ease-smooth","origin-center","translate-y-0","transition","duration-300","group-focus-within/teaser:-translate-y-full","group-hover/teaser:-translate-y-full","motion-reduce:duration-0"],[1,"absolute","-inset-x-5","top-1/2","z-0","max-h-full","-translate-y-1/2","overflow-clip"],["emblaCarousel","",1,"embla","cursor-grab","active:cursor-grabbing",3,"emblaChange","options","plugins","subscribeToEvents"],[1,"embla__container","flex","touch-pan-y","items-center"],[1,"embla__slide","flex","shrink-0","items-center","justify-center","px-3","lg:px-5",3,"is-portrait"],[1,"pointer-events-none","absolute","inset-x-0","top-[14%]","z-20","flex","-translate-y-1/2","justify-center"],[1,"font-sans","text-[clamp(2.5rem,7vw,4.5rem)]","uppercase","leading-[0.8]","text-black"],[1,"pointer-events-none","absolute","inset-x-0","bottom-[14%]","z-20","flex","translate-y-1/2","justify-center"],[1,"embla__slide","flex","shrink-0","items-center","justify-center","px-3","lg:px-5"],[1,"embla__slide__inner","block","w-full"],["app-image","","imageClass","w-full h-auto max-h-full object-contain","sizes","(min-width: 1024px) 33vw, 66vw",1,"w-full",3,"data"]],template:function(t,i){t&1&&T(0,Te,24,16,"a",0),t&2&&y(i.items().length&&i.overviewUrl()?0:-1)},dependencies:[ee,se,v,ne],styles:[`.embla[_ngcontent-%COMP%]{overflow:visible}.embla__container[_ngcontent-%COMP%]{align-items:center}.embla__slide[_ngcontent-%COMP%]{flex:0 0 60%;min-width:0;--rotate-amount: 8deg}.embla__slide.is-portrait[_ngcontent-%COMP%]{flex:0 0 36%}.embla__slide__inner[_ngcontent-%COMP%]{transform-origin:center center;will-change:transform;transform:scale(var(--scale-factor, 1)) rotate(calc(var(--rotate-factor, 0) * var(--rotate-amount)))}@media(prefers-reduced-motion:reduce){.embla__slide__inner[_ngcontent-%COMP%]{transform:none!important}} 2 3`],changeDetection:0})}}return n})();export{Ge as CollectionTeaserComponent}; 4//# sourceMappingURL=chunk-ORUVDLJX.js.map
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.