@everymatrix/tournaments-banner 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/StatusBadge-C6v95b03.cjs +8 -0
- package/components/StatusBadge-CBE0IpOM.cjs +8 -0
- package/components/StatusBadge-DLrMedBp.js +6756 -0
- package/components/StatusBadge-vLV0XrQ8.js +6838 -0
- package/components/TournamentImage-BEMMcCkt.cjs +5 -0
- package/components/TournamentImage-BamdCHr_.js +177 -0
- package/components/TournamentImage-CokDB684.cjs +5 -0
- package/components/TournamentImage-jDlLsHTp.js +180 -0
- package/components/TournamentsBanner-CgubmW_K.js +1785 -0
- package/components/TournamentsBanner-Ck6aUxuv.cjs +36 -0
- package/components/TournamentsBanner-DipIdf7b.js +1817 -0
- package/components/TournamentsBanner-fdqVau44.cjs +36 -0
- package/components/translations-BWrwvIbl.js +40 -0
- package/components/translations-Bu383Jwx.cjs +1 -0
- package/components/translations-Bvm5gqMb.js +40 -0
- package/components/translations-Dw7XuwXd.cjs +1 -0
- package/es2015/tournaments-banner.cjs +1 -0
- package/es2015/tournaments-banner.js +28 -0
- package/esnext/tournaments-banner.cjs +1 -0
- package/esnext/tournaments-banner.js +28 -0
- package/package.json +27 -0
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
var _t=Object.defineProperty,wt=Object.defineProperties;var St=Object.getOwnPropertyDescriptors;var Qe=Object.getOwnPropertySymbols;var Tt=Object.prototype.hasOwnProperty,Et=Object.prototype.propertyIsEnumerable;var Je=(n,t,e)=>t in n?_t(n,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):n[t]=e,Ke=(n,t)=>{for(var e in t||(t={}))Tt.call(t,e)&&Je(n,e,t[e]);if(Qe)for(var e of Qe(t))Et.call(t,e)&&Je(n,e,t[e]);return n},et=(n,t)=>wt(n,St(t));var ke=(n,t,e)=>new Promise((o,s)=>{var a=g=>{try{_(e.next(g))}catch(L){s(L)}},h=g=>{try{_(e.throw(g))}catch(L){s(L)}},_=g=>g.done?o(g.value):Promise.resolve(g.value).then(a,h);_((e=e.apply(n,t)).next())});typeof globalThis.HTMLElement=="undefined"&&(globalThis.HTMLElement=class{},globalThis.customElements={define(){},get(){},whenDefined(){}});const r=require("./StatusBadge-C6v95b03.cjs"),xt=require("./TournamentImage-BEMMcCkt.cjs"),Dt=(n,t)=>{window.postMessage(et(Ke({},t),{type:n}),window.location.href)},Mt=(n,t)=>{Dt(`Tournaments:${n}`,t)},Ot=(n,t)=>{Mt("viewTournamentDetails",{tournamentId:n.id,tournamentName:n.nameOrTitle})},At=n=>{const t=new Headers;return n&&t.append("X-SessionId",n),t},Ct=n=>ke(exports,null,function*(){var s,a,h;const t=new URL(`${n.endpoint}/v1/tournaments`);t.searchParams.append("language",n.language),t.searchParams.append("sortField",(s=n.sortField)!=null?s:"StartTime"),t.searchParams.append("sortOrder",(a=n.sortOrder)!=null?a:"desc"),t.searchParams.append("platform",n.platform);const o=yield(yield fetch(t,{method:"GET",headers:At(n.session)})).json();return(h=o==null?void 0:o.items)!=null?h:[]}),Lt=n=>ke(exports,null,function*(){const t=yield Ct(n),e=new Date;return t.filter(o=>new Date(o.exhibitionEndTime)>e)});var tt={exports:{}};/** @license
|
|
2
|
+
* eventsource.js
|
|
3
|
+
* Available under MIT License (MIT)
|
|
4
|
+
* https://github.com/Yaffle/EventSource/
|
|
5
|
+
*/(function(n,t){(function(e){var o=e.setTimeout,s=e.clearTimeout,a=e.XMLHttpRequest,h=e.XDomainRequest,_=e.ActiveXObject,g=e.EventSource,L=e.document,$=e.Promise,j=e.fetch,Z=e.Response,U=e.TextDecoder,P=e.TextEncoder,X=e.AbortController;if(typeof window!="undefined"&&typeof L!="undefined"&&!("readyState"in L)&&L.body==null&&(L.readyState="loading",window.addEventListener("load",function(i){L.readyState="complete"},!1)),a==null&&_!=null&&(a=function(){return new _("Microsoft.XMLHTTP")}),Object.create==null&&(Object.create=function(i){function u(){}return u.prototype=i,new u}),Date.now||(Date.now=function(){return new Date().getTime()}),X==null){var E=j;j=function(i,u){var v=u.signal;return E(i,{headers:u.headers,credentials:u.credentials,cache:u.cache}).then(function(f){var x=f.body.getReader();return v._reader=x,v._aborted&&v._reader.cancel(),{status:f.status,statusText:f.statusText,headers:f.headers,body:{getReader:function(){return x}}}})},X=function(){this.signal={_reader:null,_aborted:!1},this.abort=function(){this.signal._reader!=null&&this.signal._reader.cancel(),this.signal._aborted=!0}}}function O(){this.bitsNeeded=0,this.codePoint=0}O.prototype.decode=function(i){function u(k,V,M){if(M===1)return k>=128>>V&&k<<V<=2047;if(M===2)return k>=2048>>V&&k<<V<=55295||k>=57344>>V&&k<<V<=65535;if(M===3)return k>=65536>>V&&k<<V<=1114111;throw new Error}function v(k,V){if(k===6*1)return V>>6>15?3:V>31?2:1;if(k===6*2)return V>15?3:2;if(k===6*3)return 3;throw new Error}for(var f=65533,x="",T=this.bitsNeeded,I=this.codePoint,J=0;J<i.length;J+=1){var R=i[J];T!==0&&(R<128||R>191||!u(I<<6|R&63,T-6,v(T,I)))&&(T=0,I=f,x+=String.fromCharCode(I)),T===0?(R>=0&&R<=127?(T=0,I=R):R>=192&&R<=223?(T=6*1,I=R&31):R>=224&&R<=239?(T=6*2,I=R&15):R>=240&&R<=247?(T=6*3,I=R&7):(T=0,I=f),T!==0&&!u(I,T,v(T,I))&&(T=0,I=f)):(T-=6,I=I<<6|R&63),T===0&&(I<=65535?x+=String.fromCharCode(I):(x+=String.fromCharCode(55296+(I-65535-1>>10)),x+=String.fromCharCode(56320+(I-65535-1&1023))))}return this.bitsNeeded=T,this.codePoint=I,x};var H=function(){try{return new U().decode(new P().encode("test"),{stream:!0})==="test"}catch(i){console.debug("TextDecoder does not support streaming option. Using polyfill instead: "+i)}return!1};(U==null||P==null||!H())&&(U=O);var D=function(){};function z(i){this.withCredentials=!1,this.readyState=0,this.status=0,this.statusText="",this.responseText="",this.onprogress=D,this.onload=D,this.onerror=D,this.onreadystatechange=D,this._contentType="",this._xhr=i,this._sendTimeout=0,this._abort=D}z.prototype.open=function(i,u){this._abort(!0);var v=this,f=this._xhr,x=1,T=0;this._abort=function(M){v._sendTimeout!==0&&(s(v._sendTimeout),v._sendTimeout=0),(x===1||x===2||x===3)&&(x=4,f.onload=D,f.onerror=D,f.onabort=D,f.onprogress=D,f.onreadystatechange=D,f.abort(),T!==0&&(s(T),T=0),M||(v.readyState=4,v.onabort(null),v.onreadystatechange())),x=0};var I=function(){if(x===1){var M=0,K="",Se=void 0;if("contentType"in f)M=200,K="OK",Se=f.contentType;else try{M=f.status,K=f.statusText,Se=f.getResponseHeader("Content-Type")}catch(Ce){M=0,K="",Se=void 0}M!==0&&(x=2,v.readyState=2,v.status=M,v.statusText=K,v._contentType=Se,v.onreadystatechange())}},J=function(){if(I(),x===2||x===3){x=3;var M="";try{M=f.responseText}catch(K){}v.readyState=3,v.responseText=M,v.onprogress()}},R=function(M,K){if((K==null||K.preventDefault==null)&&(K={preventDefault:D}),J(),x===1||x===2||x===3){if(x=4,T!==0&&(s(T),T=0),v.readyState=4,M==="load")v.onload(K);else if(M==="error")v.onerror(K);else if(M==="abort")v.onabort(K);else throw new TypeError;v.onreadystatechange()}},k=function(M){f!=null&&(f.readyState===4?(!("onload"in f)||!("onerror"in f)||!("onabort"in f))&&R(f.responseText===""?"error":"load",M):f.readyState===3?"onprogress"in f||J():f.readyState===2&&I())},V=function(){T=o(function(){V()},500),f.readyState===3&&J()};"onload"in f&&(f.onload=function(M){R("load",M)}),"onerror"in f&&(f.onerror=function(M){R("error",M)}),"onabort"in f&&(f.onabort=function(M){R("abort",M)}),"onprogress"in f&&(f.onprogress=J),"onreadystatechange"in f&&(f.onreadystatechange=function(M){k(M)}),("contentType"in f||!("ontimeout"in a.prototype))&&(u+=(u.indexOf("?")===-1?"?":"&")+"padding=true"),f.open(i,u,!0),"readyState"in f&&(T=o(function(){V()},0))},z.prototype.abort=function(){this._abort(!1)},z.prototype.getResponseHeader=function(i){return this._contentType},z.prototype.setRequestHeader=function(i,u){var v=this._xhr;"setRequestHeader"in v&&v.setRequestHeader(i,u)},z.prototype.getAllResponseHeaders=function(){return this._xhr.getAllResponseHeaders!=null&&this._xhr.getAllResponseHeaders()||""},z.prototype.send=function(){if((!("ontimeout"in a.prototype)||!("sendAsBinary"in a.prototype)&&!("mozAnon"in a.prototype))&&L!=null&&L.readyState!=null&&L.readyState!=="complete"){var i=this;i._sendTimeout=o(function(){i._sendTimeout=0,i.send()},4);return}var u=this._xhr;"withCredentials"in u&&(u.withCredentials=this.withCredentials);try{u.send(void 0)}catch(v){throw v}};function ee(i){return i.replace(/[A-Z]/g,function(u){return String.fromCharCode(u.charCodeAt(0)+32)})}function ne(i){for(var u=Object.create(null),v=i.split(`\r
|
|
6
|
+
`),f=0;f<v.length;f+=1){var x=v[f],T=x.split(": "),I=T.shift(),J=T.join(": ");u[ee(I)]=J}this._map=u}ne.prototype.get=function(i){return this._map[ee(i)]},a!=null&&a.HEADERS_RECEIVED==null&&(a.HEADERS_RECEIVED=2);function ue(){}ue.prototype.open=function(i,u,v,f,x,T,I){i.open("GET",x);var J=0;i.onprogress=function(){var k=i.responseText,V=k.slice(J);J+=V.length,v(V)},i.onerror=function(k){k.preventDefault(),f(new Error("NetworkError"))},i.onload=function(){f(null)},i.onabort=function(){f(null)},i.onreadystatechange=function(){if(i.readyState===a.HEADERS_RECEIVED){var k=i.status,V=i.statusText,M=i.getResponseHeader("Content-Type"),K=i.getAllResponseHeaders();u(k,V,M,new ne(K))}},i.withCredentials=T;for(var R in I)Object.prototype.hasOwnProperty.call(I,R)&&i.setRequestHeader(R,I[R]);return i.send(),i};function ie(i){this._headers=i}ie.prototype.get=function(i){return this._headers.get(i)};function oe(){}oe.prototype.open=function(i,u,v,f,x,T,I){var J=null,R=new X,k=R.signal,V=new U;return j(x,{headers:I,credentials:T?"include":"same-origin",signal:k,cache:"no-store"}).then(function(M){return J=M.body.getReader(),u(M.status,M.statusText,M.headers.get("Content-Type"),new ie(M.headers)),new $(function(K,Se){var Ce=function(){J.read().then(function(ge){if(ge.done)K(void 0);else{var he=V.decode(ge.value,{stream:!0});v(he),Ce()}}).catch(function(ge){Se(ge)})};Ce()})}).catch(function(M){if(M.name!=="AbortError")return M}).then(function(M){f(M)}),{abort:function(){J!=null&&J.cancel(),R.abort()}}};function F(){this._listeners=Object.create(null)}function A(i){o(function(){throw i},0)}F.prototype.dispatchEvent=function(i){i.target=this;var u=this._listeners[i.type];if(u!=null)for(var v=u.length,f=0;f<v;f+=1){var x=u[f];try{typeof x.handleEvent=="function"?x.handleEvent(i):x.call(this,i)}catch(T){A(T)}}},F.prototype.addEventListener=function(i,u){i=String(i);var v=this._listeners,f=v[i];f==null&&(f=[],v[i]=f);for(var x=!1,T=0;T<f.length;T+=1)f[T]===u&&(x=!0);x||f.push(u)},F.prototype.removeEventListener=function(i,u){i=String(i);var v=this._listeners,f=v[i];if(f!=null){for(var x=[],T=0;T<f.length;T+=1)f[T]!==u&&x.push(f[T]);x.length===0?delete v[i]:v[i]=x}};function q(i){this.type=i,this.target=void 0}function ae(i,u){q.call(this,i),this.data=u.data,this.lastEventId=u.lastEventId}ae.prototype=Object.create(q.prototype);function y(i,u){q.call(this,i),this.status=u.status,this.statusText=u.statusText,this.headers=u.headers}y.prototype=Object.create(q.prototype);function d(i,u){q.call(this,i),this.error=u.error}d.prototype=Object.create(q.prototype);var c=-1,p=0,l=1,b=2,w=-1,S=0,Y=1,W=2,te=3,ce=/^text\/event\-stream(;.*)?$/i,ye=1e3,m=18e6,C=function(i,u){var v=i==null?u:parseInt(i,10);return v!==v&&(v=u),N(v)},N=function(i){return Math.min(Math.max(i,ye),m)},B=function(i,u,v){try{typeof u=="function"&&u.call(i,v)}catch(f){A(f)}};function G(i,u){F.call(this),u=u||{},this.onopen=void 0,this.onmessage=void 0,this.onerror=void 0,this.url=void 0,this.readyState=void 0,this.withCredentials=void 0,this.headers=void 0,this._close=void 0,me(this,i,u)}function re(){return a!=null&&"withCredentials"in a.prototype||h==null?new a:new h}var Q=j!=null&&Z!=null&&"body"in Z.prototype;function me(i,u,v){u=String(u);var f=!!v.withCredentials,x=v.lastEventIdQueryParameterName||"lastEventId",T=N(1e3),I=C(v.heartbeatTimeout,45e3),J="",R=T,k=!1,V=0,M=v.headers||{},K=v.Transport,Se=Q&&K==null?void 0:new z(K!=null?new K:re()),Ce=K!=null&&typeof K!="string"?new K:Se==null?new oe:new ue,ge=void 0,he=0,we=c,Oe="",Pe="",Te="",Ie="",pe=S,He=0,Me=0,gt=function(le,se,be,_e){if(we===p)if(le===200&&be!=null&&ce.test(be)){we=l,k=Date.now(),R=T,i.readyState=l;var ve=new y("open",{status:le,statusText:se,headers:_e});i.dispatchEvent(ve),B(i,i.onopen,ve)}else{var fe="";le!==200?(se&&(se=se.replace(/\s+/g," ")),fe="EventSource's response has a status "+le+" "+se+" that is not 200. Aborting the connection."):fe="EventSource's response has a Content-Type specifying an unsupported type: "+(be==null?"-":be.replace(/\s+/g," "))+". Aborting the connection.",Ne();var ve=new y("error",{status:le,statusText:se,headers:_e});i.dispatchEvent(ve),B(i,i.onerror,ve),console.error(fe)}},bt=function(le){if(we===l){for(var se=-1,be=0;be<le.length;be+=1){var _e=le.charCodeAt(be);(_e===10||_e===13)&&(se=be)}var ve=(se!==-1?Ie:"")+le.slice(0,se+1);Ie=(se===-1?Ie:"")+le.slice(se+1),le!==""&&(k=Date.now(),V+=le.length);for(var fe=0;fe<ve.length;fe+=1){var _e=ve.charCodeAt(fe);if(pe===w&&_e===10)pe=S;else if(pe===w&&(pe=S),_e===13||_e===10){if(pe!==S){pe===Y&&(Me=fe+1);var Ee=ve.slice(He,Me-1),xe=ve.slice(Me+(Me<fe&&ve.charCodeAt(Me)===32?1:0),fe);Ee==="data"?(Oe+=`
|
|
7
|
+
`,Oe+=xe):Ee==="id"?Pe=xe:Ee==="event"?Te=xe:Ee==="retry"?(T=C(xe,T),R=T):Ee==="heartbeatTimeout"&&(I=C(xe,I),he!==0&&(s(he),he=o(function(){Le()},I)))}if(pe===S){if(Oe!==""){J=Pe,Te===""&&(Te="message");var Ae=new ae(Te,{data:Oe.slice(1),lastEventId:Pe});if(i.dispatchEvent(Ae),Te==="open"?B(i,i.onopen,Ae):Te==="message"?B(i,i.onmessage,Ae):Te==="error"&&B(i,i.onerror,Ae),we===b)return}Oe="",Te=""}pe=_e===13?w:S}else pe===S&&(He=fe,pe=Y),pe===Y?_e===58&&(Me=fe+1,pe=W):pe===W&&(pe=te)}}},Ze=function(le){if(we===l||we===p){we=c,he!==0&&(s(he),he=0),he=o(function(){Le()},R),R=N(Math.min(T*16,R*2)),i.readyState=p;var se=new d("error",{error:le});i.dispatchEvent(se),B(i,i.onerror,se),le!=null&&console.error(le)}},Ne=function(){we=b,ge!=null&&(ge.abort(),ge=void 0),he!==0&&(s(he),he=0),i.readyState=b},Le=function(){if(he=0,we!==c){if(!k&&ge!=null)Ze(new Error("No activity within "+I+" milliseconds. "+(we===p?"No response received.":V+" chars received.")+" Reconnecting.")),ge!=null&&(ge.abort(),ge=void 0);else{var le=Math.max((k||Date.now())+I-Date.now(),1);k=!1,he=o(function(){Le()},le)}return}k=!1,V=0,he=o(function(){Le()},I),we=p,Oe="",Te="",Pe=J,Ie="",He=0,Me=0,pe=S;var se=u;if(u.slice(0,5)!=="data:"&&u.slice(0,5)!=="blob:"&&J!==""){var be=u.indexOf("?");se=be===-1?u:u.slice(0,be+1)+u.slice(be+1).replace(/(?:^|&)([^=&]*)(?:=[^&]*)?/g,function(xe,Ae){return Ae===x?"":xe}),se+=(u.indexOf("?")===-1?"?":"&")+x+"="+encodeURIComponent(J)}var _e=i.withCredentials,ve={};ve.Accept="text/event-stream";var fe=i.headers;if(fe!=null)for(var Ee in fe)Object.prototype.hasOwnProperty.call(fe,Ee)&&(ve[Ee]=fe[Ee]);try{ge=Ce.open(Se,gt,bt,Ze,se,_e,ve)}catch(xe){throw Ne(),xe}};i.url=u,i.readyState=p,i.withCredentials=f,i.headers=M,i._close=Ne,Le()}G.prototype=Object.create(F.prototype),G.prototype.CONNECTING=p,G.prototype.OPEN=l,G.prototype.CLOSED=b,G.prototype.close=function(){this._close()},G.CONNECTING=p,G.OPEN=l,G.CLOSED=b,G.prototype.withCredentials=void 0;var de=g;a!=null&&(g==null||!("withCredentials"in g.prototype))&&(de=G),function(i){{var u=i(t);u!==void 0&&(n.exports=u)}}(function(i){i.EventSourcePolyfill=G,i.NativeEventSource=g,i.EventSource=de})})(typeof globalThis=="undefined"?typeof window!="undefined"?window:typeof self!="undefined"?self:r.commonjsGlobal:globalThis)})(tt,tt.exports);var ct={exports:{}};(function(n,t){(function(e,o){n.exports=o()})(r.commonjsGlobal,function(){var e=1e3,o=6e4,s=36e5,a="millisecond",h="second",_="minute",g="hour",L="day",$="week",j="month",Z="quarter",U="year",P="date",X="Invalid Date",E=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,O=/\[([^\]]+)]|YYYY|YY|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,H={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(y){var d=["th","st","nd","rd"],c=y%100;return"["+y+(d[(c-20)%10]||d[c]||d[0])+"]"}},D=function(y,d,c){var p=String(y);return!p||p.length>=d?y:""+Array(d+1-p.length).join(c)+y},z={s:D,z:function(y){var d=-y.utcOffset(),c=Math.abs(d),p=Math.floor(c/60),l=c%60;return(d<=0?"+":"-")+D(p,2,"0")+":"+D(l,2,"0")},m:function y(d,c){if(d.date()<c.date())return-y(c,d);var p=12*(c.year()-d.year())+(c.month()-d.month()),l=d.clone().add(p,j),b=c-l<0,w=d.clone().add(p+(b?-1:1),j);return+(-(p+(c-l)/(b?l-w:w-l))||0)},a:function(y){return y<0?Math.ceil(y)||0:Math.floor(y)},p:function(y){return{M:j,y:U,w:$,d:L,D:P,h:g,m:_,s:h,ms:a,Q:Z}[y]||String(y||"").toLowerCase().replace(/s$/,"")},u:function(y){return y===void 0}},ee="en",ne={};ne[ee]=H;var ue="$isDayjsObject",ie=function(y){return y instanceof q||!(!y||!y[ue])},oe=function y(d,c,p){var l;if(!d)return ee;if(typeof d=="string"){var b=d.toLowerCase();ne[b]&&(l=b),c&&(ne[b]=c,l=b);var w=d.split("-");if(!l&&w.length>1)return y(w[0])}else{var S=d.name;ne[S]=d,l=S}return!p&&l&&(ee=l),l||!p&&ee},F=function(y,d){if(ie(y))return y.clone();var c=typeof d=="object"?d:{};return c.date=y,c.args=arguments,new q(c)},A=z;A.l=oe,A.i=ie,A.w=function(y,d){return F(y,{locale:d.$L,utc:d.$u,x:d.$x,$offset:d.$offset})};var q=function(){function y(c){this.$L=oe(c.locale,null,!0),this.parse(c),this.$x=this.$x||c.x||{},this[ue]=!0}var d=y.prototype;return d.parse=function(c){this.$d=function(p){var l=p.date,b=p.utc;if(l===null)return new Date(NaN);if(A.u(l))return new Date;if(l instanceof Date)return new Date(l);if(typeof l=="string"&&!/Z$/i.test(l)){var w=l.match(E);if(w){var S=w[2]-1||0,Y=(w[7]||"0").substring(0,3);return b?new Date(Date.UTC(w[1],S,w[3]||1,w[4]||0,w[5]||0,w[6]||0,Y)):new Date(w[1],S,w[3]||1,w[4]||0,w[5]||0,w[6]||0,Y)}}return new Date(l)}(c),this.init()},d.init=function(){var c=this.$d;this.$y=c.getFullYear(),this.$M=c.getMonth(),this.$D=c.getDate(),this.$W=c.getDay(),this.$H=c.getHours(),this.$m=c.getMinutes(),this.$s=c.getSeconds(),this.$ms=c.getMilliseconds()},d.$utils=function(){return A},d.isValid=function(){return this.$d.toString()!==X},d.isSame=function(c,p){var l=F(c);return this.startOf(p)<=l&&l<=this.endOf(p)},d.isAfter=function(c,p){return F(c)<this.startOf(p)},d.isBefore=function(c,p){return this.endOf(p)<F(c)},d.$g=function(c,p,l){return A.u(c)?this[p]:this.set(l,c)},d.unix=function(){return Math.floor(this.valueOf()/1e3)},d.valueOf=function(){return this.$d.getTime()},d.startOf=function(c,p){var l=this,b=!!A.u(p)||p,w=A.p(c),S=function(N,B){var G=A.w(l.$u?Date.UTC(l.$y,B,N):new Date(l.$y,B,N),l);return b?G:G.endOf(L)},Y=function(N,B){return A.w(l.toDate()[N].apply(l.toDate("s"),(b?[0,0,0,0]:[23,59,59,999]).slice(B)),l)},W=this.$W,te=this.$M,ce=this.$D,ye="set"+(this.$u?"UTC":"");switch(w){case U:return b?S(1,0):S(31,11);case j:return b?S(1,te):S(0,te+1);case $:var m=this.$locale().weekStart||0,C=(W<m?W+7:W)-m;return S(b?ce-C:ce+(6-C),te);case L:case P:return Y(ye+"Hours",0);case g:return Y(ye+"Minutes",1);case _:return Y(ye+"Seconds",2);case h:return Y(ye+"Milliseconds",3);default:return this.clone()}},d.endOf=function(c){return this.startOf(c,!1)},d.$set=function(c,p){var l,b=A.p(c),w="set"+(this.$u?"UTC":""),S=(l={},l[L]=w+"Date",l[P]=w+"Date",l[j]=w+"Month",l[U]=w+"FullYear",l[g]=w+"Hours",l[_]=w+"Minutes",l[h]=w+"Seconds",l[a]=w+"Milliseconds",l)[b],Y=b===L?this.$D+(p-this.$W):p;if(b===j||b===U){var W=this.clone().set(P,1);W.$d[S](Y),W.init(),this.$d=W.set(P,Math.min(this.$D,W.daysInMonth())).$d}else S&&this.$d[S](Y);return this.init(),this},d.set=function(c,p){return this.clone().$set(c,p)},d.get=function(c){return this[A.p(c)]()},d.add=function(c,p){var l,b=this;c=Number(c);var w=A.p(p),S=function(te){var ce=F(b);return A.w(ce.date(ce.date()+Math.round(te*c)),b)};if(w===j)return this.set(j,this.$M+c);if(w===U)return this.set(U,this.$y+c);if(w===L)return S(1);if(w===$)return S(7);var Y=(l={},l[_]=o,l[g]=s,l[h]=e,l)[w]||1,W=this.$d.getTime()+c*Y;return A.w(W,this)},d.subtract=function(c,p){return this.add(-1*c,p)},d.format=function(c){var p=this,l=this.$locale();if(!this.isValid())return l.invalidDate||X;var b=c||"YYYY-MM-DDTHH:mm:ssZ",w=A.z(this),S=this.$H,Y=this.$m,W=this.$M,te=l.weekdays,ce=l.months,ye=l.meridiem,m=function(B,G,re,Q){return B&&(B[G]||B(p,b))||re[G].slice(0,Q)},C=function(B){return A.s(S%12||12,B,"0")},N=ye||function(B,G,re){var Q=B<12?"AM":"PM";return re?Q.toLowerCase():Q};return b.replace(O,function(B,G){return G||function(re){switch(re){case"YY":return String(p.$y).slice(-2);case"YYYY":return A.s(p.$y,4,"0");case"M":return W+1;case"MM":return A.s(W+1,2,"0");case"MMM":return m(l.monthsShort,W,ce,3);case"MMMM":return m(ce,W);case"D":return p.$D;case"DD":return A.s(p.$D,2,"0");case"d":return String(p.$W);case"dd":return m(l.weekdaysMin,p.$W,te,2);case"ddd":return m(l.weekdaysShort,p.$W,te,3);case"dddd":return te[p.$W];case"H":return String(S);case"HH":return A.s(S,2,"0");case"h":return C(1);case"hh":return C(2);case"a":return N(S,Y,!0);case"A":return N(S,Y,!1);case"m":return String(Y);case"mm":return A.s(Y,2,"0");case"s":return String(p.$s);case"ss":return A.s(p.$s,2,"0");case"SSS":return A.s(p.$ms,3,"0");case"Z":return w}return null}(B)||w.replace(":","")})},d.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},d.diff=function(c,p,l){var b,w=this,S=A.p(p),Y=F(c),W=(Y.utcOffset()-this.utcOffset())*o,te=this-Y,ce=function(){return A.m(w,Y)};switch(S){case U:b=ce()/12;break;case j:b=ce();break;case Z:b=ce()/3;break;case $:b=(te-W)/6048e5;break;case L:b=(te-W)/864e5;break;case g:b=te/s;break;case _:b=te/o;break;case h:b=te/e;break;default:b=te}return l?b:A.a(b)},d.daysInMonth=function(){return this.endOf(j).$D},d.$locale=function(){return ne[this.$L]},d.locale=function(c,p){if(!c)return this.$L;var l=this.clone(),b=oe(c,p,!0);return b&&(l.$L=b),l},d.clone=function(){return A.w(this.$d,this)},d.toDate=function(){return new Date(this.valueOf())},d.toJSON=function(){return this.isValid()?this.toISOString():null},d.toISOString=function(){return this.$d.toISOString()},d.toString=function(){return this.$d.toUTCString()},y}(),ae=q.prototype;return F.prototype=ae,[["$ms",a],["$s",h],["$m",_],["$H",g],["$W",L],["$M",j],["$y",U],["$D",P]].forEach(function(y){ae[y[1]]=function(d){return this.$g(d,y[0],y[1])}}),F.extend=function(y,d){return y.$i||(y(d,q,F),y.$i=!0),F},F.locale=oe,F.isDayjs=ie,F.unix=function(y){return F(1e3*y)},F.en=ne[ee],F.Ls=ne,F.p={},F})})(ct);var $t=ct.exports;const Pt=r.getDefaultExportFromCjs($t);var lt={exports:{}};(function(n,t){(function(e,o){n.exports=o()})(r.commonjsGlobal,function(){var e={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},o=/(\[[^[]*\])|([-_:/.,()\s]+)|(A|a|Q|YYYY|YY?|ww?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g,s=/\d/,a=/\d\d/,h=/\d\d?/,_=/\d*[^-_:/,()\s\d]+/,g={},L=function(E){return(E=+E)+(E>68?1900:2e3)},$=function(E){return function(O){this[E]=+O}},j=[/[+-]\d\d:?(\d\d)?|Z/,function(E){(this.zone||(this.zone={})).offset=function(O){if(!O||O==="Z")return 0;var H=O.match(/([+-]|\d\d)/g),D=60*H[1]+(+H[2]||0);return D===0?0:H[0]==="+"?-D:D}(E)}],Z=function(E){var O=g[E];return O&&(O.indexOf?O:O.s.concat(O.f))},U=function(E,O){var H,D=g.meridiem;if(D){for(var z=1;z<=24;z+=1)if(E.indexOf(D(z,0,O))>-1){H=z>12;break}}else H=E===(O?"pm":"PM");return H},P={A:[_,function(E){this.afternoon=U(E,!1)}],a:[_,function(E){this.afternoon=U(E,!0)}],Q:[s,function(E){this.month=3*(E-1)+1}],S:[s,function(E){this.milliseconds=100*+E}],SS:[a,function(E){this.milliseconds=10*+E}],SSS:[/\d{3}/,function(E){this.milliseconds=+E}],s:[h,$("seconds")],ss:[h,$("seconds")],m:[h,$("minutes")],mm:[h,$("minutes")],H:[h,$("hours")],h:[h,$("hours")],HH:[h,$("hours")],hh:[h,$("hours")],D:[h,$("day")],DD:[a,$("day")],Do:[_,function(E){var O=g.ordinal,H=E.match(/\d+/);if(this.day=H[0],O)for(var D=1;D<=31;D+=1)O(D).replace(/\[|\]/g,"")===E&&(this.day=D)}],w:[h,$("week")],ww:[a,$("week")],M:[h,$("month")],MM:[a,$("month")],MMM:[_,function(E){var O=Z("months"),H=(Z("monthsShort")||O.map(function(D){return D.slice(0,3)})).indexOf(E)+1;if(H<1)throw new Error;this.month=H%12||H}],MMMM:[_,function(E){var O=Z("months").indexOf(E)+1;if(O<1)throw new Error;this.month=O%12||O}],Y:[/[+-]?\d+/,$("year")],YY:[a,function(E){this.year=L(E)}],YYYY:[/\d{4}/,$("year")],Z:j,ZZ:j};function X(E){var O,H;O=E,H=g&&g.formats;for(var D=(E=O.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,function(F,A,q){var ae=q&&q.toUpperCase();return A||H[q]||e[q]||H[ae].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(y,d,c){return d||c.slice(1)})})).match(o),z=D.length,ee=0;ee<z;ee+=1){var ne=D[ee],ue=P[ne],ie=ue&&ue[0],oe=ue&&ue[1];D[ee]=oe?{regex:ie,parser:oe}:ne.replace(/^\[|\]$/g,"")}return function(F){for(var A={},q=0,ae=0;q<z;q+=1){var y=D[q];if(typeof y=="string")ae+=y.length;else{var d=y.regex,c=y.parser,p=F.slice(ae),l=d.exec(p)[0];c.call(A,l),F=F.replace(l,"")}}return function(b){var w=b.afternoon;if(w!==void 0){var S=b.hours;w?S<12&&(b.hours+=12):S===12&&(b.hours=0),delete b.afternoon}}(A),A}}return function(E,O,H){H.p.customParseFormat=!0,E&&E.parseTwoDigitYear&&(L=E.parseTwoDigitYear);var D=O.prototype,z=D.parse;D.parse=function(ee){var ne=ee.date,ue=ee.utc,ie=ee.args;this.$u=ue;var oe=ie[1];if(typeof oe=="string"){var F=ie[2]===!0,A=ie[3]===!0,q=F||A,ae=ie[2];A&&(ae=ie[2]),g=this.$locale(),!F&&ae&&(g=H.Ls[ae]),this.$d=function(p,l,b,w){try{if(["x","X"].indexOf(l)>-1)return new Date((l==="X"?1e3:1)*p);var S=X(l)(p),Y=S.year,W=S.month,te=S.day,ce=S.hours,ye=S.minutes,m=S.seconds,C=S.milliseconds,N=S.zone,B=S.week,G=new Date,re=te||(Y||W?1:G.getDate()),Q=Y||G.getFullYear(),me=0;Y&&!W||(me=W>0?W-1:G.getMonth());var de,i=ce||0,u=ye||0,v=m||0,f=C||0;return N?new Date(Date.UTC(Q,me,re,i,u,v,f+60*N.offset*1e3)):b?new Date(Date.UTC(Q,me,re,i,u,v,f)):(de=new Date(Q,me,re,i,u,v,f),B&&(de=w(de).week(B).toDate()),de)}catch(x){return new Date("")}}(ne,oe,ue,H),this.init(),ae&&ae!==!0&&(this.$L=this.locale(ae).$L),q&&ne!=this.format(oe)&&(this.$d=new Date("")),g={}}else if(oe instanceof Array)for(var y=oe.length,d=1;d<=y;d+=1){ie[1]=oe[d-1];var c=H.apply(this,ie);if(c.isValid()){this.$d=c.$d,this.$L=c.$L,this.init();break}d===y&&(this.$d=new Date(""))}else z.call(this,ee)}}})})(lt);var It=lt.exports;const Ft=r.getDefaultExportFromCjs(It);Pt.extend(Ft);const Rt=()=>typeof window=="undefined",Fe=(n,t=!1)=>{if(typeof n=="boolean")return n;if(n==null)return t;if(typeof n=="number")return n!==0;const e=String(n).trim().toLowerCase();return e===""?!0:e!=="false"&&e!=="0"},Yt={en:{bannerSlideLabel:"Tournament {index} of {total}",bannerGoToSlide:"Go to tournament {index}"},tr:{bannerSlideLabel:"Turnuva {index} / {total}",bannerGoToSlide:"{index}. turnuvaya git"},da:{bannerSlideLabel:"Turnering {index} af {total}",bannerGoToSlide:"Gå til turnering {index}"}},jt=5e3,Ht=1e3,Nt=!0,kt=!0,Ut=!0,zt=!0;/*! *****************************************************************************
|
|
8
|
+
Copyright (c) Microsoft Corporation.
|
|
9
|
+
|
|
10
|
+
Permission to use, copy, modify, and/or distribute this software for any
|
|
11
|
+
purpose with or without fee is hereby granted.
|
|
12
|
+
|
|
13
|
+
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|
14
|
+
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
|
15
|
+
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|
16
|
+
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
17
|
+
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
18
|
+
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
19
|
+
PERFORMANCE OF THIS SOFTWARE.
|
|
20
|
+
***************************************************************************** */var ze=function(n,t){return ze=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,o){e.__proto__=o}||function(e,o){for(var s in o)Object.prototype.hasOwnProperty.call(o,s)&&(e[s]=o[s])},ze(n,t)};function $e(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");ze(n,t);function e(){this.constructor=n}n.prototype=t===null?Object.create(t):(e.prototype=t.prototype,new e)}function We(n){var t=typeof Symbol=="function"&&Symbol.iterator,e=t&&n[t],o=0;if(e)return e.call(n);if(n&&typeof n.length=="number")return{next:function(){return n&&o>=n.length&&(n=void 0),{value:n&&n[o++],done:!n}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function Be(n,t){var e=typeof Symbol=="function"&&n[Symbol.iterator];if(!e)return n;var o=e.call(n),s,a=[],h;try{for(;(t===void 0||t-- >0)&&!(s=o.next()).done;)a.push(s.value)}catch(_){h={error:_}}finally{try{s&&!s.done&&(e=o.return)&&e.call(o)}finally{if(h)throw h.error}}return a}function Ge(n,t,e){if(arguments.length===2)for(var o=0,s=t.length,a;o<s;o++)(a||!(o in t))&&(a||(a=Array.prototype.slice.call(t,0,o)),a[o]=t[o]);return n.concat(a||t)}function De(n){return typeof n=="function"}function ft(n){var t=function(o){Error.call(o),o.stack=new Error().stack},e=n(t);return e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e}var Ue=ft(function(n){return function(e){n(this),this.message=e?e.length+` errors occurred during unsubscription:
|
|
21
|
+
`+e.map(function(o,s){return s+1+") "+o.toString()}).join(`
|
|
22
|
+
`):"",this.name="UnsubscriptionError",this.errors=e}});function Ve(n,t){if(n){var e=n.indexOf(t);0<=e&&n.splice(e,1)}}var je=function(){function n(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}return n.prototype.unsubscribe=function(){var t,e,o,s,a;if(!this.closed){this.closed=!0;var h=this._parentage;if(h)if(this._parentage=null,Array.isArray(h))try{for(var _=We(h),g=_.next();!g.done;g=_.next()){var L=g.value;L.remove(this)}}catch(X){t={error:X}}finally{try{g&&!g.done&&(e=_.return)&&e.call(_)}finally{if(t)throw t.error}}else h.remove(this);var $=this.initialTeardown;if(De($))try{$()}catch(X){a=X instanceof Ue?X.errors:[X]}var j=this._finalizers;if(j){this._finalizers=null;try{for(var Z=We(j),U=Z.next();!U.done;U=Z.next()){var P=U.value;try{rt(P)}catch(X){a=a!=null?a:[],X instanceof Ue?a=Ge(Ge([],Be(a)),Be(X.errors)):a.push(X)}}}catch(X){o={error:X}}finally{try{U&&!U.done&&(s=Z.return)&&s.call(Z)}finally{if(o)throw o.error}}}if(a)throw new Ue(a)}},n.prototype.add=function(t){var e;if(t&&t!==this)if(this.closed)rt(t);else{if(t instanceof n){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=(e=this._finalizers)!==null&&e!==void 0?e:[]).push(t)}},n.prototype._hasParent=function(t){var e=this._parentage;return e===t||Array.isArray(e)&&e.includes(t)},n.prototype._addParent=function(t){var e=this._parentage;this._parentage=Array.isArray(e)?(e.push(t),e):e?[e,t]:t},n.prototype._removeParent=function(t){var e=this._parentage;e===t?this._parentage=null:Array.isArray(e)&&Ve(e,t)},n.prototype.remove=function(t){var e=this._finalizers;e&&Ve(e,t),t instanceof n&&t._removeParent(this)},n.EMPTY=function(){var t=new n;return t.closed=!0,t}(),n}(),dt=je.EMPTY;function ht(n){return n instanceof je||n&&"closed"in n&&De(n.remove)&&De(n.add)&&De(n.unsubscribe)}function rt(n){De(n)?n():n.unsubscribe()}var Wt={Promise:void 0},Bt={setTimeout:function(n,t){for(var e=[],o=2;o<arguments.length;o++)e[o-2]=arguments[o];return setTimeout.apply(void 0,Ge([n,t],Be(e)))},clearTimeout:function(n){return clearTimeout(n)},delegate:void 0};function Gt(n){Bt.setTimeout(function(){throw n})}function nt(){}function Ye(n){n()}var pt=function(n){$e(t,n);function t(e){var o=n.call(this)||this;return o.isStopped=!1,e?(o.destination=e,ht(e)&&e.add(o)):o.destination=qt,o}return t.create=function(e,o,s){return new Xe(e,o,s)},t.prototype.next=function(e){this.isStopped||this._next(e)},t.prototype.error=function(e){this.isStopped||(this.isStopped=!0,this._error(e))},t.prototype.complete=function(){this.isStopped||(this.isStopped=!0,this._complete())},t.prototype.unsubscribe=function(){this.closed||(this.isStopped=!0,n.prototype.unsubscribe.call(this),this.destination=null)},t.prototype._next=function(e){this.destination.next(e)},t.prototype._error=function(e){try{this.destination.error(e)}finally{this.unsubscribe()}},t.prototype._complete=function(){try{this.destination.complete()}finally{this.unsubscribe()}},t}(je),Vt=function(){function n(t){this.partialObserver=t}return n.prototype.next=function(t){var e=this.partialObserver;if(e.next)try{e.next(t)}catch(o){Re(o)}},n.prototype.error=function(t){var e=this.partialObserver;if(e.error)try{e.error(t)}catch(o){Re(o)}else Re(t)},n.prototype.complete=function(){var t=this.partialObserver;if(t.complete)try{t.complete()}catch(e){Re(e)}},n}(),Xe=function(n){$e(t,n);function t(e,o,s){var a=n.call(this)||this,h;return De(e)||!e?h={next:e!=null?e:void 0,error:o!=null?o:void 0,complete:s!=null?s:void 0}:h=e,a.destination=new Vt(h),a}return t}(pt);function Re(n){Gt(n)}function Xt(n){throw n}var qt={closed:!0,next:nt,error:Xt,complete:nt},Zt=function(){return typeof Symbol=="function"&&Symbol.observable||"@@observable"}();function Qt(n){return n}function Jt(n){return n.length===0?Qt:n.length===1?n[0]:function(e){return n.reduce(function(o,s){return s(o)},e)}}var ot=function(){function n(t){t&&(this._subscribe=t)}return n.prototype.lift=function(t){var e=new n;return e.source=this,e.operator=t,e},n.prototype.subscribe=function(t,e,o){var s=this,a=er(t)?t:new Xe(t,e,o);return Ye(function(){var h=s,_=h.operator,g=h.source;a.add(_?_.call(a,g):g?s._subscribe(a):s._trySubscribe(a))}),a},n.prototype._trySubscribe=function(t){try{return this._subscribe(t)}catch(e){t.error(e)}},n.prototype.forEach=function(t,e){var o=this;return e=it(e),new e(function(s,a){var h=new Xe({next:function(_){try{t(_)}catch(g){a(g),h.unsubscribe()}},error:a,complete:s});o.subscribe(h)})},n.prototype._subscribe=function(t){var e;return(e=this.source)===null||e===void 0?void 0:e.subscribe(t)},n.prototype[Zt]=function(){return this},n.prototype.pipe=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return Jt(t)(this)},n.prototype.toPromise=function(t){var e=this;return t=it(t),new t(function(o,s){var a;e.subscribe(function(h){return a=h},function(h){return s(h)},function(){return o(a)})})},n.create=function(t){return new n(t)},n}();function it(n){var t;return(t=n!=null?n:Wt.Promise)!==null&&t!==void 0?t:Promise}function Kt(n){return n&&De(n.next)&&De(n.error)&&De(n.complete)}function er(n){return n&&n instanceof pt||Kt(n)&&ht(n)}var tr=ft(function(n){return function(){n(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"}}),vt=function(n){$e(t,n);function t(){var e=n.call(this)||this;return e.closed=!1,e.currentObservers=null,e.observers=[],e.isStopped=!1,e.hasError=!1,e.thrownError=null,e}return t.prototype.lift=function(e){var o=new at(this,this);return o.operator=e,o},t.prototype._throwIfClosed=function(){if(this.closed)throw new tr},t.prototype.next=function(e){var o=this;Ye(function(){var s,a;if(o._throwIfClosed(),!o.isStopped){o.currentObservers||(o.currentObservers=Array.from(o.observers));try{for(var h=We(o.currentObservers),_=h.next();!_.done;_=h.next()){var g=_.value;g.next(e)}}catch(L){s={error:L}}finally{try{_&&!_.done&&(a=h.return)&&a.call(h)}finally{if(s)throw s.error}}}})},t.prototype.error=function(e){var o=this;Ye(function(){if(o._throwIfClosed(),!o.isStopped){o.hasError=o.isStopped=!0,o.thrownError=e;for(var s=o.observers;s.length;)s.shift().error(e)}})},t.prototype.complete=function(){var e=this;Ye(function(){if(e._throwIfClosed(),!e.isStopped){e.isStopped=!0;for(var o=e.observers;o.length;)o.shift().complete()}})},t.prototype.unsubscribe=function(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null},Object.defineProperty(t.prototype,"observed",{get:function(){var e;return((e=this.observers)===null||e===void 0?void 0:e.length)>0},enumerable:!1,configurable:!0}),t.prototype._trySubscribe=function(e){return this._throwIfClosed(),n.prototype._trySubscribe.call(this,e)},t.prototype._subscribe=function(e){return this._throwIfClosed(),this._checkFinalizedStatuses(e),this._innerSubscribe(e)},t.prototype._innerSubscribe=function(e){var o=this,s=this,a=s.hasError,h=s.isStopped,_=s.observers;return a||h?dt:(this.currentObservers=null,_.push(e),new je(function(){o.currentObservers=null,Ve(_,e)}))},t.prototype._checkFinalizedStatuses=function(e){var o=this,s=o.hasError,a=o.thrownError,h=o.isStopped;s?e.error(a):h&&e.complete()},t.prototype.asObservable=function(){var e=new ot;return e.source=this,e},t.create=function(e,o){return new at(e,o)},t}(ot),at=function(n){$e(t,n);function t(e,o){var s=n.call(this)||this;return s.destination=e,s.source=o,s}return t.prototype.next=function(e){var o,s;(s=(o=this.destination)===null||o===void 0?void 0:o.next)===null||s===void 0||s.call(o,e)},t.prototype.error=function(e){var o,s;(s=(o=this.destination)===null||o===void 0?void 0:o.error)===null||s===void 0||s.call(o,e)},t.prototype.complete=function(){var e,o;(o=(e=this.destination)===null||e===void 0?void 0:e.complete)===null||o===void 0||o.call(e)},t.prototype._subscribe=function(e){var o,s;return(s=(o=this.source)===null||o===void 0?void 0:o.subscribe(e))!==null&&s!==void 0?s:dt},t}(vt),yt={now:function(){return(yt.delegate||Date).now()},delegate:void 0},rr=function(n){$e(t,n);function t(e,o,s){e===void 0&&(e=1/0),o===void 0&&(o=1/0),s===void 0&&(s=yt);var a=n.call(this)||this;return a._bufferSize=e,a._windowTime=o,a._timestampProvider=s,a._buffer=[],a._infiniteTimeWindow=!0,a._infiniteTimeWindow=o===1/0,a._bufferSize=Math.max(1,e),a._windowTime=Math.max(1,o),a}return t.prototype.next=function(e){var o=this,s=o.isStopped,a=o._buffer,h=o._infiniteTimeWindow,_=o._timestampProvider,g=o._windowTime;s||(a.push(e),!h&&a.push(_.now()+g)),this._trimBuffer(),n.prototype.next.call(this,e)},t.prototype._subscribe=function(e){this._throwIfClosed(),this._trimBuffer();for(var o=this._innerSubscribe(e),s=this,a=s._infiniteTimeWindow,h=s._buffer,_=h.slice(),g=0;g<_.length&&!e.closed;g+=a?1:2)e.next(_[g]);return this._checkFinalizedStatuses(e),o},t.prototype._trimBuffer=function(){var e=this,o=e._bufferSize,s=e._timestampProvider,a=e._buffer,h=e._infiniteTimeWindow,_=(h?1:2)*o;if(o<1/0&&_<a.length&&a.splice(0,a.length-_),!h){for(var g=s.now(),L=0,$=1;$<a.length&&a[$]<=g;$+=2)L=$;L&&a.splice(0,L+1)}},t}(vt);const st=[],ut={},nr=(n,t=0)=>{if(st.indexOf(n)==-1){const e=new rr(t);ut[n]=e,st.push(n)}return ut[n]};typeof window!="undefined"&&(window.emWidgets={topic:nr});const or=n=>n.toLowerCase().match(/android/i)?"Android":n.toLowerCase().match(/iphone/i)?"iPhone":n.toLowerCase().match(/ipad|ipod/i)?"iPad":"PC";String(Number.MAX_SAFE_INTEGER).length;var ir=r.from_html('<div class="tournaments-banner svelte-h8hbcz"><div class="tournaments-banner__skeleton svelte-h8hbcz" aria-busy="true"></div></div>'),ar=r.from_html('<a class="tournaments-banner__slide svelte-h8hbcz"><!></a>'),sr=r.from_html('<button type="button"></button>'),ur=r.from_html('<div class="tournaments-banner__dots svelte-h8hbcz"></div>'),cr=r.from_html('<div class="tournaments-banner svelte-h8hbcz" role="region" aria-roledescription="carousel"><div class="tournaments-banner__track svelte-h8hbcz"></div> <!></div>');const lr={hash:"svelte-h8hbcz",code:`.tournaments-banner.svelte-h8hbcz {display:flex;flex-direction:column;gap:8px;.tournaments-banner__track:where(.svelte-h8hbcz) {display:flex;overflow-x:auto;scroll-snap-type:x mandatory;scroll-behavior:smooth;overscroll-behavior-x:contain;scrollbar-width:none;-ms-overflow-style:none;&::-webkit-scrollbar {display:none;}}.tournaments-banner__slide:where(.svelte-h8hbcz) {display:block;flex:0 0 100%;color:inherit;text-decoration:none;min-width:0;scroll-snap-align:start;scroll-snap-stop:always;cursor:pointer;&:focus-visible {outline:2px solid var(--border-alert, rgba(255, 204, 0, 1));outline-offset:-2px;border-radius:13px;}}.tournaments-banner__skeleton:where(.svelte-h8hbcz) {height:308px;border-radius:13px;background:var(--bg-overlay-neutral-level-1, rgba(251, 251, 251, 0.05));
|
|
23
|
+
animation: svelte-h8hbcz-tournaments-banner-pulse 1.5s ease-in-out infinite;}.tournaments-banner__dots:where(.svelte-h8hbcz) {display:flex;justify-content:center;gap:8px;}.tournaments-banner__dot:where(.svelte-h8hbcz) {width:8px;height:8px;padding:0;border:0;border-radius:50%;background:var(--text-subtle, rgba(223, 227, 232, 1));opacity:0.8;cursor:pointer;&.active {background:var(--text-brand, rgba(255, 204, 0, 1));opacity:1;}&:focus-visible {outline:2px solid var(--border-alert, rgba(255, 204, 0, 1));outline-offset:2px;}}}
|
|
24
|
+
|
|
25
|
+
@keyframes svelte-h8hbcz-tournaments-banner-pulse {
|
|
26
|
+
50% {
|
|
27
|
+
opacity: 0.4;
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
@media (max-width: 767px) {.tournaments-banner.svelte-h8hbcz .tournaments-banner__skeleton:where(.svelte-h8hbcz) {height:160px;}
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
@media (prefers-reduced-motion: reduce) {.tournaments-banner.svelte-h8hbcz .tournaments-banner__track:where(.svelte-h8hbcz) {scroll-behavior:auto;}.tournaments-banner.svelte-h8hbcz .tournaments-banner__skeleton:where(.svelte-h8hbcz) {
|
|
35
|
+
animation: none;}
|
|
36
|
+
}`};function qe(n,t){var ye;r.push(t,!0),r.append_styles(n,lr);const e=()=>r.store_get(r.$format,"$_",o),[o,s]=r.setup_stores(),a=r.prop(t,"endpoint"),h=r.prop(t,"language",7,"en"),_=r.prop(t,"session"),g=r.prop(t,"platformProp",7,null),L=r.prop(t,"translationurl"),$=r.prop(t,"navigationhref",7,""),j=r.prop(t,"enableautoplay",7,void 0),Z=r.prop(t,"autoplayinterval",7,void 0),U=r.prop(t,"pauseoninteraction",7,void 0),P=r.prop(t,"loop",7,void 0),X=r.prop(t,"showdots",7,void 0);r.setupI18n({withLocale:"en",translations:{}}),r.registerTranslations(Yt),r.setLocale(h()),r.user_pre_effect(()=>{L()&&r.loadTranslations(L())}),r.user_effect(()=>{r.setLocale(h())});const E=Rt()?(ye=g())!=null?ye:"dk":or(window.navigator.userAgent);let O=r.state(r.proxy([])),H=r.state(!0),D=r.state(0),z=r.state(null),ee=r.state(!1),ne=r.state(!1),ue=r.state(!1),ie=r.state(!1),oe=r.state(!1);const F=r.user_derived(()=>Fe(j(),Nt)),A=r.user_derived(()=>Fe(U(),kt)),q=r.user_derived(()=>Fe(P(),Ut)),ae=r.user_derived(()=>Fe(X(),zt)),y=r.user_derived(()=>Number(Z())>0?Math.max(Number(Z()),Ht):jt),d=m=>`${$().replace(/\/$/,"")}/${m.id}`;r.user_effect(()=>{const m={endpoint:a(),language:h(),session:_(),platform:E};if(!m.endpoint)return;let C=!1;return r.set(H,!0),Lt(m).then(N=>{C||(r.set(O,N,!0),r.set(D,0))}).catch(N=>{console.log(N),C||r.set(O,[],!0)}).finally(()=>{C||r.set(H,!1)}),()=>{C=!0}}),r.user_effect(()=>{const m=window.matchMedia("(prefers-reduced-motion: reduce)"),C=()=>{r.set(oe,m.matches,!0)},N=()=>{r.set(ie,document.visibilityState==="hidden")};return C(),N(),m.addEventListener("change",C),document.addEventListener("visibilitychange",N),()=>{m.removeEventListener("change",C),document.removeEventListener("visibilitychange",N)}}),r.user_effect(()=>{const m=r.get(D),C=r.get(O).length,N=r.get(A)&&(r.get(ee)||r.get(ne)||r.get(ue)),B=m>=C-1;if(!r.get(F)||C<2||N||r.get(ie)||r.get(oe)||B&&!r.get(q))return;const G=setTimeout(()=>p((m+1)%C),r.get(y));return()=>clearTimeout(G)});const c=()=>{!r.get(z)||!r.get(z).clientWidth||r.set(D,Math.round(r.get(z).scrollLeft/r.get(z).clientWidth),!0)},p=m=>{var C;(C=r.get(z))==null||C.scrollTo({left:m*r.get(z).clientWidth,behavior:"smooth"})},l=m=>{r.set(ne,m.target.matches(":focus-visible"),!0)},b=(m,C)=>{$()||(m.preventDefault(),Ot(C))};var w={get endpoint(){return a()},set endpoint(m){a(m),r.flushSync()},get language(){return h()},set language(m="en"){h(m),r.flushSync()},get session(){return _()},set session(m){_(m),r.flushSync()},get platformProp(){return g()},set platformProp(m=null){g(m),r.flushSync()},get translationurl(){return L()},set translationurl(m){L(m),r.flushSync()},get navigationhref(){return $()},set navigationhref(m=""){$(m),r.flushSync()},get enableautoplay(){return j()},set enableautoplay(m=void 0){j(m),r.flushSync()},get autoplayinterval(){return Z()},set autoplayinterval(m=void 0){Z(m),r.flushSync()},get pauseoninteraction(){return U()},set pauseoninteraction(m=void 0){U(m),r.flushSync()},get loop(){return P()},set loop(m=void 0){P(m),r.flushSync()},get showdots(){return X()},set showdots(m=void 0){X(m),r.flushSync()}},S=r.comment(),Y=r.first_child(S);{var W=m=>{var C=ir();r.append(m,C)},te=m=>{var C=cr(),N=r.child(C);r.each(N,23,()=>r.get(O),re=>re.id,(re,Q,me)=>{var de=ar(),i=r.child(de);{let u=r.user_derived(()=>r.get(me)===0);xt.TournamentImage(i,{variant:"banner",get priority(){return r.get(u)},get src(){return r.get(Q).thumbnail},get alt(){return r.get(Q).nameOrTitle},get state(){return r.get(Q).state},get startTime(){return r.get(Q).startTime},get endTime(){return r.get(Q).endTime},get language(){return h()}})}r.reset(de),r.template_effect((u,v)=>{r.set_attribute(de,"href",u),r.set_attribute(de,"aria-label",v)},[()=>$()?d(r.get(Q)):"#",()=>`${r.get(Q).nameOrTitle} – ${e()("bannerSlideLabel",{values:{index:r.get(me)+1,total:r.get(O).length}})}`]),r.delegated("click",de,u=>b(u,r.get(Q))),r.append(re,de)}),r.reset(N),r.bind_this(N,re=>r.set(z,re),()=>r.get(z));var B=r.sibling(N,2);{var G=re=>{var Q=ur();r.each(Q,23,()=>r.get(O),me=>me.id,(me,de,i)=>{var u=sr();let v;r.template_effect(f=>{v=r.set_class(u,1,"tournaments-banner__dot svelte-h8hbcz",null,v,{active:r.get(i)===r.get(D)}),r.set_attribute(u,"aria-label",f),r.set_attribute(u,"aria-current",r.get(i)===r.get(D)?"true":void 0)},[()=>e()("bannerGoToSlide",{values:{index:r.get(i)+1}})]),r.delegated("click",u,()=>p(r.get(i))),r.append(me,u)}),r.reset(Q),r.append(re,Q)};r.if_block(B,re=>{r.get(ae)&&r.get(O).length>1&&re(G)})}r.reset(C),r.event("mouseenter",C,()=>r.set(ee,!0)),r.event("mouseleave",C,()=>r.set(ee,!1)),r.delegated("focusin",C,l),r.delegated("focusout",C,()=>r.set(ne,!1)),r.delegated("touchstart",C,()=>r.set(ue,!0)),r.delegated("touchend",C,()=>r.set(ue,!1)),r.event("touchcancel",C,()=>r.set(ue,!1)),r.event("scroll",N,c),r.append(m,C)};r.if_block(Y,m=>{r.get(H)?m(W):r.get(O).length&&m(te,1)})}r.append(n,S);var ce=r.pop(w);return s(),ce}r.delegate(["focusin","focusout","touchstart","touchend","click"]);r.create_custom_element(qe,{endpoint:{},language:{},session:{},platformProp:{},translationurl:{},navigationhref:{},enableautoplay:{},autoplayinterval:{},pauseoninteraction:{},loop:{},showdots:{}},[],[],{mode:"open"});function mt(n,t){r.push(t,!0);let e=r.prop(t,"endpoint"),o=r.prop(t,"language",7,"en"),s=r.prop(t,"session"),a=r.prop(t,"platformProp",7,null),h=r.prop(t,"translationurl"),_=r.prop(t,"navigationhref"),g=r.prop(t,"enableautoplay"),L=r.prop(t,"autoplayinterval"),$=r.prop(t,"pauseoninteraction"),j=r.prop(t,"loop"),Z=r.prop(t,"showdots");var U={get endpoint(){return e()},set endpoint(P){e(P),r.flushSync()},get language(){return o()},set language(P="en"){o(P),r.flushSync()},get session(){return s()},set session(P){s(P),r.flushSync()},get platformProp(){return a()},set platformProp(P=null){a(P),r.flushSync()},get translationurl(){return h()},set translationurl(P){h(P),r.flushSync()},get navigationhref(){return _()},set navigationhref(P){_(P),r.flushSync()},get enableautoplay(){return g()},set enableautoplay(P){g(P),r.flushSync()},get autoplayinterval(){return L()},set autoplayinterval(P){L(P),r.flushSync()},get pauseoninteraction(){return $()},set pauseoninteraction(P){$(P),r.flushSync()},get loop(){return j()},set loop(P){j(P),r.flushSync()},get showdots(){return Z()},set showdots(P){Z(P),r.flushSync()}};return qe(n,{get endpoint(){return e()},get language(){return o()},get session(){return s()},get platformProp(){return a()},get translationurl(){return h()},get navigationhref(){return _()},get enableautoplay(){return g()},get autoplayinterval(){return L()},get pauseoninteraction(){return $()},get loop(){return j()},get showdots(){return Z()}}),r.pop(U)}customElements.define("tournaments-banner",r.create_custom_element(mt,{endpoint:{},language:{},session:{},platformProp:{},translationurl:{},navigationhref:{},enableautoplay:{},autoplayinterval:{},pauseoninteraction:{},loop:{},showdots:{}},[],[]));const fr=Object.freeze(Object.defineProperty({__proto__:null,default:mt},Symbol.toStringTag,{value:"Module"}));exports.TournamentsBanner=qe;exports.TournamentsBanner_ce=fr;
|