@everymatrix/player-challenges 0.1.18 → 0.1.19

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.
Files changed (93) hide show
  1. package/components/{ArrowLeftIcon-f3IOpYNO.cjs → ArrowLeftIcon-BEURnjpJ.cjs} +1 -1
  2. package/components/{ArrowLeftIcon-DorWQbN-.js → ArrowLeftIcon-DN6e9luu.js} +1 -1
  3. package/components/Badge-BEjEww7C.cjs +9 -0
  4. package/components/Badge-DSBvI-B9.js +138 -0
  5. package/components/{Button-CUICdAqJ.cjs → Button-Bvh3WQSZ.cjs} +2 -2
  6. package/components/{Button-DgtpbC5z.js → Button-ewgCN0Ji.js} +17 -17
  7. package/components/ChallengeBanner-E82laAQ0.js +103 -0
  8. package/components/ChallengeBanner-WwVvI1Uu.cjs +30 -0
  9. package/components/{ChallengeBreadcrumbs-DHNKXK43.js → ChallengeBreadcrumbs-BtOwj4Jl.js} +7 -7
  10. package/components/ChallengeBreadcrumbs-SeC9192i.cjs +1 -0
  11. package/components/{ChallengeCard-SkQ_xfqo.js → ChallengeCard-BZ8CZvgE.js} +5 -5
  12. package/components/{ChallengeCard-BuDYjnna.cjs → ChallengeCard-Zj92mrKO.cjs} +1 -1
  13. package/components/{ChallengeClaimCode-zgBFr-2W.cjs → ChallengeClaimCode-BXn91GDr.cjs} +1 -1
  14. package/components/{ChallengeClaimCode-DiJqww5t.js → ChallengeClaimCode-CeM2Z6p6.js} +2 -2
  15. package/components/{ChallengeDetails-DMdkjCMC.js → ChallengeDetails-B5AHPIQM.js} +2 -2
  16. package/components/{ChallengeDetails-D1h6ITwb.cjs → ChallengeDetails-BVoZJVVL.cjs} +1 -1
  17. package/components/ChallengeDetailsSkeleton-CdG_rSGQ.js +138 -0
  18. package/components/ChallengeDetailsSkeleton-u24ioQh6.cjs +20 -0
  19. package/components/{ChallengeEvents-D5kenBIc.cjs → ChallengeEvents-7BMohfz-.cjs} +1 -1
  20. package/components/{ChallengeEvents-B6l3iUIf.js → ChallengeEvents-DkdwGm5z.js} +16 -16
  21. package/components/ChallengeGames-BvHQAgRm.js +135 -0
  22. package/components/ChallengeGames-hnPYCbOH.cjs +14 -0
  23. package/components/{ChallengeHistory-8LPDK1aA.js → ChallengeHistory-C0lhKrpA.js} +4 -4
  24. package/components/{ChallengeHistory-CHK2Q13H.cjs → ChallengeHistory-DoXcpVtR.cjs} +1 -1
  25. package/components/ChallengeLevels-BpGMpkdK.cjs +8 -0
  26. package/components/ChallengeLevels-CmLntQ0a.js +314 -0
  27. package/components/ChallengeList-DWrRtGZ6.cjs +47 -0
  28. package/components/{ChallengeList-D6_LjVsa.js → ChallengeList-Dztxku3t.js} +616 -560
  29. package/components/{ChallengeProgress-BFAihSd8.js → ChallengeProgress-BPSQNZFN.js} +9 -9
  30. package/components/{ChallengeProgress-F4DvqxcC.cjs → ChallengeProgress-vtUcMyKL.cjs} +1 -1
  31. package/components/{ChallengeProgressItem-BHk-1FKU.js → ChallengeProgressItem-3A5VPooB.js} +239 -223
  32. package/components/ChallengeProgressItem-bSzmG8l2.cjs +69 -0
  33. package/components/ChallengeRules-VFOXD1ge.cjs +1 -0
  34. package/components/ChallengeRules-YzymE0DQ.js +161 -0
  35. package/components/ChallengeSummary-D6OJ_aBt.cjs +1 -0
  36. package/components/{ChallengeSummary-sGIfhmFq.js → ChallengeSummary-rhsO5YE0.js} +79 -87
  37. package/components/ChallengeTabContent-2kOyabcA.js +779 -0
  38. package/components/ChallengeTabContent-BmBcztk_.cjs +16 -0
  39. package/components/{ChallengeTabPanel-CdcGT_LI.js → ChallengeTabPanel-CqwPtmvo.js} +47 -44
  40. package/components/ChallengeTabPanel-D_brgA-W.cjs +1 -0
  41. package/components/ChallengeTabs-Bkx7hDSs.cjs +14 -0
  42. package/components/ChallengeTabs-DrR1HXiu.js +8749 -0
  43. package/components/{CheckIcon-BqS1Tdfu.cjs → CheckIcon-DeZrzQxv.cjs} +1 -1
  44. package/components/{CheckIcon-B82NDFTL.js → CheckIcon-DlNpzYWO.js} +1 -1
  45. package/components/{ChevronIcon-C0yjiiug.js → ChevronIcon-BLforcQh.js} +1 -1
  46. package/components/{ChevronIcon-zvGKIAT7.cjs → ChevronIcon-Bx8g9KW1.cjs} +1 -1
  47. package/components/ChipIcon-BIaydmmL.js +26 -0
  48. package/components/ChipIcon-kKYQ4DVa.cjs +1 -0
  49. package/components/ChipShineIcon-BhJxc-7o.cjs +1 -0
  50. package/components/ChipShineIcon-x_PFBpiC.js +28 -0
  51. package/components/{ExistIcon-DifozqZH.cjs → ExistIcon--rtolulO.cjs} +1 -1
  52. package/components/{ExistIcon-Y3lLvkAJ.js → ExistIcon-eNMDxHqT.js} +1 -1
  53. package/components/{GiftIcon-CY_-XK0b.js → GiftIcon-B0dDFiN1.js} +14 -14
  54. package/components/{GiftIcon-Bd4y8-Fm.cjs → GiftIcon-BEczx5al.cjs} +1 -1
  55. package/components/{LinkIcon-CLHvOQ2s.js → LinkIcon-B1a0ukPT.js} +1 -1
  56. package/components/{LinkIcon-Bttg6ZAz.cjs → LinkIcon-D8SAcoU1.cjs} +1 -1
  57. package/components/{LockIcon-gAFRYl52.js → LockIcon-B96T_uuy.js} +1 -1
  58. package/components/{LockIcon-BgDxb03o.cjs → LockIcon-C0YL_dFy.cjs} +1 -1
  59. package/components/Pagination-BACM981T.js +113 -0
  60. package/components/Pagination-Xk727E7v.cjs +4 -0
  61. package/components/PlayerChallenges-T3zWVcYA.cjs +1 -0
  62. package/components/{PlayerChallenges-CaUu7idr.js → PlayerChallenges-r9ozrIGW.js} +147 -127
  63. package/components/{StarIcon-CbfuCfUA.js → StarIcon-BcWj-wRN.js} +1 -1
  64. package/components/{StarIcon-DE0r6703.cjs → StarIcon-D891Qux1.cjs} +1 -1
  65. package/components/{TargetIcon-BVhRYDcS.js → TargetIcon-Bv2zPej6.js} +14 -14
  66. package/components/{TargetIcon-DDclkkVP.cjs → TargetIcon-CCXuJUbZ.cjs} +1 -1
  67. package/esnext/player-challenges.cjs +1 -1
  68. package/esnext/player-challenges.js +2 -2
  69. package/package.json +1 -1
  70. package/components/Badge-BDyFx08l.cjs +0 -7
  71. package/components/Badge-t5ERZxvC.js +0 -130
  72. package/components/ChallengeBanner-DSarDh3k.js +0 -59
  73. package/components/ChallengeBanner-uzrRUAwa.cjs +0 -4
  74. package/components/ChallengeBreadcrumbs-DwyCD4n7.cjs +0 -1
  75. package/components/ChallengeGames-CZu1MzPA.cjs +0 -11
  76. package/components/ChallengeGames-CjLLzYVy.js +0 -134
  77. package/components/ChallengeLevels-CCZGLr9f.cjs +0 -8
  78. package/components/ChallengeLevels-s9abBMuq.js +0 -292
  79. package/components/ChallengeList-CK16hckg.cjs +0 -20
  80. package/components/ChallengeProgressItem-DrMZEU3z.cjs +0 -68
  81. package/components/ChallengeRules-CIINsSVb.js +0 -173
  82. package/components/ChallengeRules-D5vuaTVl.cjs +0 -1
  83. package/components/ChallengeSummary-BhoNxD8d.cjs +0 -1
  84. package/components/ChallengeTabContent-CYsszYCj.js +0 -795
  85. package/components/ChallengeTabContent-CftvI5C6.cjs +0 -12
  86. package/components/ChallengeTabPanel-ChsZw13b.cjs +0 -1
  87. package/components/ChallengeTabSkeleton-CDYom40f.cjs +0 -15
  88. package/components/ChallengeTabSkeleton-CuRzH3G_.js +0 -92
  89. package/components/ChallengeTabs-Dcgam5G5.cjs +0 -14
  90. package/components/ChallengeTabs-TgwP2u9F.js +0 -8618
  91. package/components/Pagination-4P-rWszf.cjs +0 -12
  92. package/components/Pagination-CbvI_9SC.js +0 -123
  93. package/components/PlayerChallenges-CtnY-k5K.cjs +0 -1
@@ -1,14 +0,0 @@
1
- typeof globalThis.HTMLElement>"u"&&(globalThis.HTMLElement=class{},globalThis.customElements={define(){},get(){},whenDefined(){}});const Ao="5";typeof window<"u"&&((window.__svelte??={}).v??=new Set).add(Ao);const Io=1,Po=2,Ps=4,Oo=8,$o=16,No=1,Mo=4,Ho=8,Do=16,Bo=1,Ro=2,Os="[",pi="[!",ts="[?",vi="]",tn={},ge=Symbol("uninitialized"),Lo="http://www.w3.org/1999/xhtml",$s=!1;var Ns=Array.isArray,Fo=Array.prototype.indexOf,er=Array.prototype.includes,vr=Array.from,tr=Object.keys,On=Object.defineProperty,Lt=Object.getOwnPropertyDescriptor,ko=Object.getOwnPropertyDescriptors,Go=Object.prototype,Uo=Array.prototype,Ms=Object.getPrototypeOf,ns=Object.isExtensible;const yt=()=>{};function Hs(e){for(var t=0;t<e.length;t++)e[t]()}function Ds(){var e,t,n=new Promise((r,i)=>{e=r,t=i});return{promise:n,resolve:e,reject:t}}const ye=2,nn=4,Bn=8,Bs=1<<24,qe=16,Ve=32,ut=64,Ur=128,je=512,me=1024,pe=2048,Qe=4096,Pe=8192,Ge=16384,zt=32768,jr=1<<25,rn=65536,nr=1<<17,jo=1<<18,Yt=1<<19,Rs=1<<20,rt=1<<25,jt=65536,rr=1<<21,en=1<<22,Pt=1<<23,An=Symbol("$state"),Ls=Symbol("legacy props"),Vo=Symbol(""),Fs=Symbol("attributes"),Vr=Symbol("class"),zr=Symbol("style"),Yr=Symbol("text"),ks=Symbol("form reset"),Rn=new class extends Error{name="StaleReactionError";message="The reaction that called `getAbortSignal()` was re-run or destroyed"},Gs=!!globalThis.document?.contentType&&globalThis.document.contentType.includes("xml"),gr=3,Ln=8;function Us(e){throw new Error("https://svelte.dev/e/lifecycle_outside_component")}function zo(){throw new Error("https://svelte.dev/e/async_derived_orphan")}function Yo(e,t,n){throw new Error("https://svelte.dev/e/each_key_duplicate")}function Xo(e){throw new Error("https://svelte.dev/e/effect_in_teardown")}function Wo(){throw new Error("https://svelte.dev/e/effect_in_unowned_derived")}function qo(e){throw new Error("https://svelte.dev/e/effect_orphan")}function Zo(){throw new Error("https://svelte.dev/e/effect_update_depth_exceeded")}function Jo(){throw new Error("https://svelte.dev/e/hydration_failed")}function Qo(e){throw new Error("https://svelte.dev/e/props_invalid_value")}function Ko(){throw new Error("https://svelte.dev/e/state_descriptors_fixed")}function eu(){throw new Error("https://svelte.dev/e/state_prototype_fixed")}function tu(){throw new Error("https://svelte.dev/e/state_unsafe_mutation")}function nu(){throw new Error("https://svelte.dev/e/svelte_boundary_reset_onerror")}function ru(){console.warn("https://svelte.dev/e/derived_inert")}function mr(e){console.warn("https://svelte.dev/e/hydration_mismatch")}function iu(){console.warn("https://svelte.dev/e/svelte_boundary_reset_noop")}let K=!1;function _t(e){K=e}let ee;function He(e){if(e===null)throw mr(),tn;return ee=e}function _r(){return He(ft(ee))}function $n(e){if(K){if(ft(ee)!==null)throw mr(),tn;ee=e}}function js(e=1){if(K){for(var t=e,n=ee;t--;)n=ft(n);ee=n}}function ir(e=!0){for(var t=0,n=ee;;){if(n.nodeType===Ln){var r=n.data;if(r===vi){if(t===0)return n;t-=1}else(r===Os||r===pi||r[0]==="["&&!isNaN(Number(r.slice(1))))&&(t+=1)}var i=ft(n);e&&n.remove(),n=i}}function Vs(e){if(!e||e.nodeType!==Ln)throw mr(),tn;return e.data}function zs(e){return e===this.v}function Ys(e,t){return e!=e?t==t:e!==t||e!==null&&typeof e=="object"||typeof e=="function"}function Xs(e){return!Ys(e,this.v)}let su=!1,xe=null;function sn(e){xe=e}function br(e,t=!1,n){xe={p:xe,i:!1,c:null,e:null,s:e,x:null,r:z,l:null}}function yr(e){var t=xe,n=t.e;if(n!==null){t.e=null;for(var r of n)va(r)}return e!==void 0&&(t.x=e),t.i=!0,xe=t.p,e??{}}function Ws(){return!0}let Bt=[];function qs(){var e=Bt;Bt=[],Hs(e)}function it(e){if(Bt.length===0&&!In){var t=Bt;queueMicrotask(()=>{t===Bt&&qs()})}Bt.push(e)}function au(){for(;Bt.length>0;)qs()}function Zs(e){var t=z;if(t===null)return Z.f|=Pt,e;if(!(t.f&zt)&&!(t.f&nn))throw e;Ct(e,t)}function Ct(e,t){if(!(t!==null&&t.f&Ge)){for(;t!==null;){if(t.f&Ur){if(!(t.f&zt))throw e;try{t.b.error(e);return}catch(n){e=n}}t=t.parent}throw e}}const ou=-7169;function fe(e,t){e.f=e.f&ou|t}function gi(e){e.f&je||e.deps===null?fe(e,me):fe(e,Qe)}function Js(e){if(e!==null)for(const t of e)!(t.f&ye)||!(t.f&jt)||(t.f^=jt,Js(t.deps))}function Qs(e,t,n){e.f&pe?t.add(e):e.f&Qe&&n.add(e),Js(e.deps),fe(e,me)}function mi(e,t,n){if(e==null)return t(void 0),n&&n(void 0),yt;const r=Nt(()=>e.subscribe(t,n));return r.unsubscribe?()=>r.unsubscribe():r}const Jt=[];function uu(e,t){return{subscribe:Er(e,t).subscribe}}function Er(e,t=yt){let n=null;const r=new Set;function i(o){if(Ys(e,o)&&(e=o,n)){const u=!Jt.length;for(const l of r)l[1](),Jt.push(l,e);if(u){for(let l=0;l<Jt.length;l+=2)Jt[l][0](Jt[l+1]);Jt.length=0}}}function s(o){i(o(e))}function a(o,u=yt){const l=[o,u];return r.add(l),r.size===1&&(n=t(i,s)||yt),o(e),()=>{r.delete(l),r.size===0&&n&&(n(),n=null)}}return{set:i,update:s,subscribe:a}}function pn(e,t,n){const r=!Array.isArray(e),i=r?[e]:e;if(!i.every(Boolean))throw new Error("derived() expects stores as input, got a falsy value");const s=t.length<2;return uu(n,(a,o)=>{let u=!1;const l=[];let f=0,c=yt;const h=()=>{if(f)return;c();const p=t(r?l[0]:l,a,o);s?a(p):c=typeof p=="function"?p:yt},d=i.map((p,y)=>mi(p,_=>{l[y]=_,f&=~(1<<y),u&&h()},()=>{f|=1<<y}));return u=!0,h(),function(){Hs(d),c(),u=!1}})}function lu(e){let t;return mi(e,n=>t=n)(),t}let Vn=!1,Xr=Symbol("unmounted");function _i(e,t,n){const r=n[t]??={store:null,source:xi(void 0),unsubscribe:yt};if(r.store!==e&&!(Xr in n))if(r.unsubscribe(),r.store=e??null,e==null)r.source.v=void 0,r.unsubscribe=yt;else{var i=!0;r.unsubscribe=mi(e,s=>{i?r.source.v=s:ie(r.source,s)}),i=!1}return e&&Xr in n?lu(e):$(r.source)}function bi(){const e={};function t(){Ii(()=>{for(var n in e)e[n].unsubscribe();On(e,Xr,{enumerable:!1,value:!0})})}return[e,t]}function fu(e){var t=Vn;try{return Vn=!1,[e(),Vn]}finally{Vn=t}}let rs=!1;function cu(){rs||(rs=!0,document.addEventListener("reset",e=>{Promise.resolve().then(()=>{if(!e.defaultPrevented)for(const t of e.target.elements)t[ks]?.()})},{capture:!0}))}function Fn(e){var t=Z,n=z;ze(null),lt(null);try{return e()}finally{ze(t),lt(n)}}function hu(e){let t=0,n=Vt(0),r;return()=>{Ai()&&($(n),Oi(()=>(t===0&&(r=Nt(()=>e(()=>Pn(n)))),t+=1,()=>{it(()=>{t-=1,t===0&&(r?.(),r=void 0,Pn(n))})})))}}var du=rn|Yt;function pu(e,t,n,r){new vu(e,t,n,r)}class vu{parent;is_pending=!1;transform_error;#e;#t=K?ee:null;#n;#a;#i;#o=null;#r=null;#u=null;#s=null;#v=0;#l=0;#f=!1;#h=new Set;#g=new Set;#c=null;#_=hu(()=>(this.#c=Vt(this.#v),()=>{this.#c=null}));constructor(t,n,r,i){this.#e=t,this.#n=n,this.#a=s=>{var a=z;a.b=this,a.f|=Ur,r(s)},this.parent=z.b,this.transform_error=i??this.parent?.transform_error??(s=>s),this.#i=Ni(()=>{if(K){const s=this.#t;_r();const a=s.data===pi;if(s.data.startsWith(ts)){const u=JSON.parse(s.data.slice(ts.length));this.#b(u)}else a?this.#w():this.#m()}else this.#d()},du),K&&(this.#e=ee)}#m(){try{this.#o=We(()=>this.#a(this.#e))}catch(t){this.error(t)}}#b(t){const n=this.#n.failed,{reset:r,invoke_onerror:i}=this.#y(t);it(i),n&&(this.#u=We(()=>{n(this.#e,()=>t,()=>r)}))}#y(t){var n=!1,r=!1;const i=()=>{if(n){iu();return}n=!0,r&&nu(),this.#u!==null&&Ft(this.#u,()=>{this.#u=null}),this.#p(()=>{this.#d()})};return{reset:i,invoke_onerror:()=>{try{r=!0,this.#n.onerror?.(t,i),r=!1}catch(a){Ct(a,this.#i&&this.#i.parent)}}}}#w(){const t=this.#n.pending;t&&(this.is_pending=!0,this.#r=We(()=>t(this.#e)),it(()=>{var n=this.#s=document.createDocumentFragment(),r=Ke();n.append(r),this.#o=this.#p(()=>We(()=>this.#a(r))),this.#l===0&&(this.#e.before(n),this.#s=null,Ft(this.#r,()=>{this.#r=null}),this.#E(te))}))}#d(){try{if(this.is_pending=this.has_pending_snippet(),this.#l=0,this.#v=0,this.#o=We(()=>{this.#a(this.#e)}),this.#l>0){var t=this.#s=document.createDocumentFragment();Hi(this.#o,t);const n=this.#n.pending;this.#r=We(()=>n(this.#e))}else this.#E(te)}catch(n){this.error(n)}}#E(t){this.is_pending=!1,t.transfer_effects(this.#h,this.#g)}defer_effect(t){Qs(t,this.#h,this.#g)}is_rendered(){return!this.is_pending&&(!this.parent||this.parent.is_rendered())}has_pending_snippet(){return!!this.#n.pending}#p(t){var n=z,r=Z,i=xe;lt(this.#i),ze(this.#i),sn(this.#i.ctx);try{return Et.ensure(),t()}catch(s){return Zs(s),null}finally{lt(n),ze(r),sn(i)}}#x(t,n){if(!this.has_pending_snippet()){this.parent&&this.parent.#x(t,n);return}this.#l+=t,this.#l===0&&(this.#E(n),this.#r&&Ft(this.#r,()=>{this.#r=null}),this.#s&&(this.#e.before(this.#s),this.#s=null))}update_pending_count(t,n){this.#x(t,n),this.#v+=t,!(!this.#c||this.#f)&&(this.#f=!0,it(()=>{this.#f=!1,this.#c&&on(this.#c,this.#v)}))}get_effect_pending(){return this.#_(),$(this.#c)}error(t){if(!this.#n.onerror&&!this.#n.failed)throw t;te?.is_fork?(this.#o&&te.skip_effect(this.#o),this.#r&&te.skip_effect(this.#r),this.#u&&te.skip_effect(this.#u),te.oncommit(()=>{this.#S(t)})):this.#S(t)}#S(t){this.#o&&(Oe(this.#o),this.#o=null),this.#r&&(Oe(this.#r),this.#r=null),this.#u&&(Oe(this.#u),this.#u=null),K&&(He(this.#t),js(),He(ir()));let n=this.#n.failed;const r=i=>{const{reset:s,invoke_onerror:a}=this.#y(i);a(),n&&(this.#u=this.#p(()=>{try{return We(()=>{var o=z;o.b=this,o.f|=Ur,n(this.#e,()=>i,()=>s)})}catch(o){return Ct(o,this.#i.parent),null}}))};it(()=>{var i;try{i=this.transform_error(t)}catch(s){Ct(s,this.#i&&this.#i.parent);return}i!==null&&typeof i=="object"&&typeof i.then=="function"?i.then(r,s=>Ct(s,this.#i&&this.#i.parent)):r(i)})}}function gu(e,t,n,r){const i=Nn;var s=e.filter(d=>!d.settled),a=t.map(i);if(n.length===0&&s.length===0){r(a);return}var o=z,u=mu(),l=s.length===1?s[0].promise:s.length>1?Promise.all(s.map(d=>d.promise)):null;function f(d){if(!(o.f&Ge)){u();try{r([...a,...d])}catch(p){Ct(p,o)}sr()}}var c=Ks();if(n.length===0){l.then(()=>f([])).finally(c);return}function h(){Promise.all(n.map(d=>_u(d))).then(f).catch(d=>Ct(d,o)).finally(c)}l?l.then(()=>{u(),h(),sr()}):h()}function mu(){var e=z,t=Z,n=xe,r=te;return function(s=!0){lt(e),ze(t),sn(n),s&&!(e.f&Ge)&&(r?.activate(),r?.apply())}}function sr(e=!0){lt(null),ze(null),sn(null),e&&te?.deactivate()}function Ks(){var e=z,t=e.b,n=te,r=!!t?.is_rendered();return t?.update_pending_count(1,n),n.increment(r,e),()=>{t?.update_pending_count(-1,n),n.decrement(r,e)}}function Nn(e){var t=ye|pe;return z!==null&&(z.f|=Yt),{ctx:xe,deps:null,effects:null,equals:zs,f:t,fn:e,reactions:null,rv:0,v:ge,wv:0,parent:z,ac:null}}const wn=Symbol("obsolete");function _u(e,t,n){let r=z;r===null&&zo();var i=void 0,s=Vt(ge),a=!Z,o=new Set;return Pu(()=>{var u=z,l=Ds();i=l.promise;try{Promise.resolve(e()).then(l.resolve,d=>{d!==Rn&&l.reject(d)}).finally(sr)}catch(d){l.reject(d),sr()}var f=te;if(a){if(u.f&zt)var c=Ks();if(r.b?.is_rendered())f.async_deriveds.get(u)?.reject(wn);else for(const d of o.values())d.reject(wn);o.add(l),f.async_deriveds.set(u,l)}const h=(d,p=void 0)=>{c?.(),o.delete(l),p!==wn&&(f.activate(),p?(s.f|=Pt,on(s,p)):(s.f&Pt&&(s.f^=Pt),on(s,d)),f.deactivate())};l.promise.then(h,d=>h(null,d||"unknown"))}),Ii(()=>{for(const u of o)u.reject(wn)}),new Promise(u=>{function l(f){function c(){f===i?u(s):l(i)}f.then(c,c)}l(i)})}function an(e){const t=Nn(e);return ya(t),t}function ea(e){const t=Nn(e);return t.equals=Xs,t}function bu(e){var t=e.effects;if(t!==null){e.effects=null;for(var n=0;n<t.length;n+=1)Oe(t[n])}}function yi(e){var t,n=z,r=e.parent;if(!xt&&r!==null&&e.v!==ge&&r.f&(Ge|Pe))return ru(),e.v;lt(r);try{e.f&=~jt,bu(e),t=Sa(e)}finally{lt(n)}return t}function ta(e){var t=yi(e);if(!e.equals(t)&&(e.wv=wa(),(!te?.is_fork||e.deps===null)&&(te!==null?(te.capture(e,t,!0),Wr?.capture(e,t,!0)):e.v=t,e.deps===null))){fe(e,me);return}xt||(Ze!==null?(Ai()||te?.is_fork)&&Ze.set(e,t):gi(e))}function yu(e){if(e.effects!==null)for(const t of e.effects)(t.teardown||t.ac)&&(t.teardown?.(),t.ac!==null&&Fn(()=>{t.ac.abort(Rn),t.ac=null}),t.fn!==null&&(t.teardown=yt),Mn(t,0),Mi(t))}function na(e){if(e.effects!==null)for(const t of e.effects)t.teardown&&t.fn!==null&&un(t)}let Pr=null,Qt=null,te=null,Wr=null,Ze=null,qr=null,In=!1,Or=!1,Kt=null,Wn=null;var is=0;let Eu=1;class Et{id=Eu++;#e=!1;linked=!0;#t=null;#n=null;async_deriveds=new Map;current=new Map;previous=new Map;#a=new Set;#i=new Set;#o=0;#r=new Map;#u=null;#s=[];#v=[];#l=new Set;#f=new Set;#h=new Map;#g=new Set;is_fork=!1;#c=!1;constructor(){Qt===null?Pr=Qt=this:(Qt.#n=this,this.#t=Qt),Qt=this}#_(){if(this.is_fork)return!0;for(const r of this.#r.keys()){for(var t=r,n=!1;t.parent!==null;){if(this.#h.has(t)){n=!0;break}t=t.parent}if(!n)return!0}return!1}skip_effect(t){this.#h.has(t)||this.#h.set(t,{d:[],m:[]}),this.#g.delete(t)}unskip_effect(t,n=r=>this.schedule(r)){var r=this.#h.get(t);if(r){this.#h.delete(t);for(var i of r.d)fe(i,pe),n(i);for(i of r.m)fe(i,Qe),n(i)}this.#g.add(t)}#m(){this.#e=!0,is++>1e3&&(this.#p(),wu());for(const u of this.#l)this.#f.delete(u),fe(u,pe),this.schedule(u);for(const u of this.#f)fe(u,Qe),this.schedule(u);const t=this.#s;this.#s=[],this.apply();var n=Kt=[],r=[],i=Wn=[];for(const u of t)try{this.#b(u,n,r)}catch(l){throw sa(u),this.#_()||this.discard(),l}if(te=null,i.length>0){var s=Et.ensure();for(const u of i)s.schedule(u)}if(Kt=null,Wn=null,this.#_()){this.#d(r),this.#d(n);for(const[u,l]of this.#h)ia(u,l);i.length>0&&te.#m();return}const a=this.#y();if(a){this.#d(r),this.#d(n),a.#w(this);return}this.#l.clear(),this.#f.clear();for(const u of this.#a)u(this);this.#a.clear(),Wr=this,ss(r),ss(n),Wr=null,this.#u?.resolve();var o=te;if(this.#o===0&&(this.#s.length===0||o!==null)&&this.#p(),this.#s.length>0)if(o!==null){const u=o;u.#s.push(...this.#s.filter(l=>!u.#s.includes(l)))}else o=this;o!==null&&(st.clear(),o.#m())}#b(t,n,r){t.f^=me;for(var i=t.first;i!==null;){var s=i.f,a=(s&(Ve|ut))!==0,o=a&&(s&me)!==0,u=o||(s&Pe)!==0||this.#h.has(i);if(!u&&i.fn!==null){a?i.f^=me:s&nn?n.push(i):kn(i)&&(s&qe&&this.#f.add(i),un(i));var l=i.first;if(l!==null){i=l;continue}}for(;i!==null;){var f=i.next;if(f!==null){i=f;break}i=i.parent}}}#y(){for(var t=this.#t;t!==null;){if(!t.is_fork){for(const[n,[,r]]of this.current)if(t.current.has(n)&&!r)return t}t=t.#t}return null}#w(t){for(const[r,i]of t.current)!this.previous.has(r)&&t.previous.has(r)&&this.previous.set(r,t.previous.get(r)),this.current.set(r,i);for(const[r,i]of t.async_deriveds){const s=this.async_deriveds.get(r);s&&i.promise.then(s.resolve).catch(s.reject)}t.async_deriveds.clear(),this.transfer_effects(t.#l,t.#f);const n=r=>{var i=r.reactions;if(i!==null&&!(r.f&ye&&!(r.f&(pe|Qe))))for(const o of i){var s=o.f;if(s&ye)n(o);else{var a=o;s&(en|qe)&&!this.async_deriveds.has(a)&&(this.#f.delete(a),fe(a,pe),this.schedule(a))}}};for(const r of this.current.keys())n(r);this.oncommit(()=>t.discard()),t.#p(),te=this,this.#m()}#d(t){for(var n=0;n<t.length;n+=1)Qs(t[n],this.#l,this.#f)}capture(t,n,r=!1){t.v!==ge&&!this.previous.has(t)&&this.previous.set(t,t.v),t.f&Pt||(this.current.set(t,[n,r]),Ze?.set(t,n)),this.is_fork||(t.v=n)}activate(){te=this}deactivate(){te=null,Ze=null}flush(){try{Or=!0,te=this,this.#m()}finally{is=0,qr=null,Kt=null,Wn=null,Or=!1,te=null,Ze=null,st.clear()}}discard(){for(const t of this.#i)t(this);this.#i.clear();for(const t of this.async_deriveds.values())t.reject(wn);this.#p(),this.#u?.resolve()}register_created_effect(t){this.#v.push(t)}#E(){for(let c=Pr;c!==null;c=c.#n){var t=c.id<this.id,n=[];for(const[h,[d,p]]of this.current){if(c.current.has(h)){var r=c.current.get(h)[0];if(t&&d!==r)c.current.set(h,[d,p]);else continue}n.push(h)}if(t)for(const[h,d]of this.async_deriveds){const p=c.async_deriveds.get(h);p&&d.promise.then(p.resolve).catch(p.reject)}var i=[...c.current.keys()].filter(h=>!c.current.get(h)[1]);if(!(!c.#e||i.length===0)){var s=i.filter(h=>!this.current.has(h));if(s.length===0)t&&c.discard();else if(n.length>0){if(t)for(const h of this.#g)c.unskip_effect(h,d=>{d.f&(qe|en)?c.schedule(d):c.#d([d])});c.activate();var a=new Set,o=new Map;for(var u of n)ra(u,s,a,o);o=new Map;var l=[...c.current].filter(([h,d])=>{const p=this.current.get(h);return p?p[0]!==d[0]||p[1]!==d[1]:!0}).map(([h])=>h);if(l.length>0)for(const h of this.#v)!(h.f&(Ge|Pe|nr))&&Ei(h,l,o)&&(h.f&(en|qe)?(fe(h,pe),c.schedule(h)):c.#l.add(h));if(c.#s.length>0&&!c.#c){c.apply();for(var f of c.#s)c.#b(f,[],[]);c.#s=[]}c.deactivate()}}}}increment(t,n){if(this.#o+=1,t){let r=this.#r.get(n)??0;this.#r.set(n,r+1)}}decrement(t,n){if(this.#o-=1,t){let r=this.#r.get(n)??0;r===1?this.#r.delete(n):this.#r.set(n,r-1)}this.#c||(this.#c=!0,it(()=>{this.#c=!1,this.linked&&this.flush()}))}transfer_effects(t,n){for(const r of t)this.#l.add(r);for(const r of n)this.#f.add(r);t.clear(),n.clear()}oncommit(t){this.#a.add(t)}ondiscard(t){this.#i.add(t)}settled(){return(this.#u??=Ds()).promise}static ensure(){if(te===null){const t=te=new Et;!Or&&!In&&it(()=>{t.#e||t.flush()})}return te}apply(){{Ze=null;return}}schedule(t){if(qr=t,t.b?.is_pending&&t.f&(nn|Bn|Bs)&&!(t.f&zt)){t.b.defer_effect(t);return}for(var n=t;n.parent!==null;){n=n.parent;var r=n.f;if(Kt!==null&&n===z&&(Z===null||!(Z.f&ye)))return;if(r&(ut|Ve)){if(!(r&me))return;n.f^=me}}this.#s.push(n)}#p(){if(this.linked){var t=this.#t,n=this.#n;t===null?Pr=n:t.#n=n,n===null?Qt=t:n.#t=t,this.linked=!1}}}function bt(e){var t=In;In=!0;try{for(var n;;){if(au(),te===null)return n;te.flush()}}finally{In=t}}function wu(){try{Zo()}catch(e){Ct(e,qr)}}let mt=null;function ss(e){var t=e.length;if(t!==0){for(var n=0;n<t;){var r=e[n++];if(!(r.f&(Ge|Pe))&&kn(r)&&(mt=new Set,un(r),r.deps===null&&r.first===null&&r.nodes===null&&r.teardown===null&&r.ac===null&&ma(r),mt?.size>0)){st.clear();for(const i of mt){if(i.f&(Ge|Pe))continue;const s=[i];let a=i.parent;for(;a!==null;)mt.has(a)&&(mt.delete(a),s.push(a)),a=a.parent;for(let o=s.length-1;o>=0;o--){const u=s[o];u.f&(Ge|Pe)||un(u)}}mt.clear()}}mt=null}}function ra(e,t,n,r){if(!n.has(e)&&(n.add(e),e.reactions!==null))for(const i of e.reactions){const s=i.f;s&ye?ra(i,t,n,r):s&(en|qe)&&!(s&pe)&&Ei(i,t,r)&&(fe(i,pe),wi(i))}}function Ei(e,t,n){const r=n.get(e);if(r!==void 0)return r;if(e.deps!==null)for(const i of e.deps){if(er.call(t,i))return!0;if(i.f&ye&&Ei(i,t,n))return n.set(i,!0),!0}return n.set(e,!1),!1}function wi(e){te.schedule(e)}function ia(e,t){if(!(e.f&Ve&&e.f&me)){e.f&pe?t.d.push(e):e.f&Qe&&t.m.push(e),fe(e,me);for(var n=e.first;n!==null;)ia(n,t),n=n.next}}function sa(e){fe(e,me);for(var t=e.first;t!==null;)sa(t),t=t.next}let ar=new Set;const st=new Map;let aa=!1;function Vt(e,t){var n={f:0,v:e,reactions:null,equals:zs,rv:0,wv:0};return n}function Ie(e,t){const n=Vt(e);return ya(n),n}function xi(e,t=!1,n=!0){const r=Vt(e);return t||(r.equals=Xs),r}function ie(e,t,n=!1){Z!==null&&(!Je||Z.f&nr)&&Ws()&&Z.f&(ye|qe|en|nr)&&(at===null||!at.has(e))&&tu();let r=n?ke(t):t;return on(e,r,Wn)}function on(e,t,n=null){if(!e.equals(t)){xt?st.set(e,t):st.has(e)||st.set(e,e.v);var r=Et.ensure();if(r.capture(e,t),e.f&ye){const i=e;e.f&pe&&yi(i),Ze===null&&gi(i)}e.wv=wa(),oa(e,pe,n),z!==null&&z.f&me&&!(z.f&(Ve|ut))&&(Ue===null?Nu([e]):Ue.push(e)),!r.is_fork&&ar.size>0&&!aa&&xu()}return t}function xu(){aa=!1;for(const e of ar){e.f&me&&fe(e,Qe);let t;try{t=kn(e)}catch{t=!0}t&&un(e)}ar.clear()}function Pn(e){ie(e,e.v+1)}function oa(e,t,n){var r=e.reactions;if(r!==null)for(var i=r.length,s=0;s<i;s++){var a=r[s],o=a.f,u=(o&pe)===0;if(u&&fe(a,t),o&nr)ar.add(a);else if(o&ye){var l=a;Ze?.delete(l),o&jt||(o&je&&(z===null||!(z.f&rr))&&(a.f|=jt),oa(l,Qe,n))}else if(u){var f=a;o&qe&&mt!==null&&mt.add(f),n!==null?n.push(f):wi(f)}}}function ke(e){if(typeof e!="object"||e===null||An in e)return e;const t=Ms(e);if(t!==Go&&t!==Uo)return e;var n=new Map,r=Ns(e),i=Ie(0),s=kt,a=o=>{if(kt===s)return o();var u=Z,l=kt;ze(null),us(s);var f=o();return ze(u),us(l),f};return r&&n.set("length",Ie(e.length)),new Proxy(e,{defineProperty(o,u,l){(!("value"in l)||l.configurable===!1||l.enumerable===!1||l.writable===!1)&&Ko();var f=n.get(u);return f===void 0?a(()=>{var c=Ie(l.value);return n.set(u,c),c}):ie(f,l.value,!0),!0},deleteProperty(o,u){var l=n.get(u);if(l===void 0){if(u in o){const f=a(()=>Ie(ge));n.set(u,f),Pn(i)}}else ie(l,ge),Pn(i);return!0},get(o,u,l){if(u===An)return e;var f=n.get(u),c=u in o;if(f===void 0&&(!c||Lt(o,u)?.writable)&&(f=a(()=>{var d=ke(c?o[u]:ge),p=Ie(d);return p}),n.set(u,f)),f!==void 0){var h=$(f);return h===ge?void 0:h}return Reflect.get(o,u,l)},getOwnPropertyDescriptor(o,u){var l=Reflect.getOwnPropertyDescriptor(o,u);if(l&&"value"in l){var f=n.get(u);f&&(l.value=$(f))}else if(l===void 0){var c=n.get(u),h=c?.v;if(c!==void 0&&h!==ge)return{enumerable:!0,configurable:!0,value:h,writable:!0}}return l},has(o,u){if(u===An)return!0;var l=n.get(u),f=l!==void 0&&l.v!==ge||Reflect.has(o,u);if(l!==void 0||z!==null&&(!f||Lt(o,u)?.writable)){l===void 0&&(l=a(()=>{var h=f?ke(o[u]):ge,d=Ie(h);return d}),n.set(u,l));var c=$(l);if(c===ge)return!1}return f},set(o,u,l,f){var c=n.get(u),h=u in o;if(r&&u==="length")for(var d=l;d<c.v;d+=1){var p=n.get(d+"");p!==void 0?ie(p,ge):d in o&&(p=a(()=>Ie(ge)),n.set(d+"",p))}if(c===void 0)(!h||Lt(o,u)?.writable)&&(c=a(()=>Ie(void 0)),ie(c,ke(l)),n.set(u,c));else{h=c.v!==ge;var y=a(()=>ke(l));ie(c,y)}var _=Reflect.getOwnPropertyDescriptor(o,u);if(_?.set&&_.set.call(f,l),!h){if(r&&typeof u=="string"){var P=n.get("length"),L=Number(u);Number.isInteger(L)&&L>=P.v&&ie(P,L+1)}Pn(i)}return!0},ownKeys(o){$(i);var u=Reflect.ownKeys(o).filter(c=>{var h=n.get(c);return h===void 0||h.v!==ge});for(var[l,f]of n)f.v!==ge&&!(l in o)&&u.push(l);return u},setPrototypeOf(){eu()}})}var as,ua,la,fa;function Zr(){if(as===void 0){as=window,ua=/Firefox/.test(navigator.userAgent);var e=Element.prototype,t=Node.prototype,n=Text.prototype;la=Lt(t,"firstChild").get,fa=Lt(t,"nextSibling").get,ns(e)&&(e[Vr]=void 0,e[Fs]=null,e[zr]=void 0,e.__e=void 0),ns(n)&&(n[Yr]=void 0)}}function Ke(e=""){return document.createTextNode(e)}function wt(e){return la.call(e)}function ft(e){return fa.call(e)}function Si(e,t){if(!K)return wt(e);var n=wt(ee);if(n===null)n=ee.appendChild(Ke());else if(t&&n.nodeType!==gr){var r=Ke();return n?.before(r),He(r),r}return t&&Ci(n),He(n),n}function Su(e,t=!1){if(!K){var n=wt(e);return n instanceof Comment&&n.data===""?ft(n):n}if(t){if(ee?.nodeType!==gr){var r=Ke();return ee?.before(r),He(r),r}Ci(ee)}return ee}function ca(e,t=1,n=!1){let r=K?ee:e;for(var i;t--;)i=r,r=ft(r);if(!K)return r;if(n){if(r?.nodeType!==gr){var s=Ke();return r===null?i?.after(s):r.before(s),He(s),s}Ci(r)}return He(r),r}function ha(e){e.textContent=""}function Ti(e,t,n){return document.createElement(e)}function Ci(e){if(e.nodeValue.length<65536)return;let t=e.nextSibling;for(;t!==null&&t.nodeType===gr;)t.remove(),e.nodeValue+=t.nodeValue,t=e.nextSibling}function da(e){z===null&&(Z===null&&qo(),Wo()),xt&&Xo()}function Tu(e,t){var n=t.last;n===null?t.last=t.first=e:(n.next=e,e.prev=n,t.last=e)}function et(e,t){var n=z;n!==null&&n.f&Pe&&(e|=Pe);var r={ctx:xe,deps:null,nodes:null,f:e|pe|je,first:null,fn:t,last:null,next:null,parent:n,b:n&&n.b,prev:null,teardown:null,wv:0,ac:null};te?.register_created_effect(r);var i=r;if(e&nn)Kt!==null?Kt.push(r):Et.ensure().schedule(r);else if(t!==null){try{un(r)}catch(a){throw Oe(r),a}i.deps===null&&i.teardown===null&&i.nodes===null&&i.first===i.last&&!(i.f&Yt)&&(i=i.first,e&qe&&e&rn&&i!==null&&(i.f|=rn))}if(i!==null&&(i.parent=n,n!==null&&Tu(i,n),Z!==null&&Z.f&ye&&!(e&ut))){var s=Z;(s.effects??=[]).push(i)}return r}function Ai(){return Z!==null&&!Je}function Ii(e){const t=et(Bn,null);return fe(t,me),t.teardown=e,t}function pa(e){da();var t=z.f,n=!Z&&(t&Ve)!==0&&xe!==null&&!xe.i;if(n){var r=xe;(r.e??=[]).push(e)}else return va(e)}function va(e){return et(nn|Rs,e)}function Cu(e){return da(),et(Bn|Rs,e)}function Au(e){Et.ensure();const t=et(ut|Yt,e);return()=>{Oe(t)}}function Iu(e){Et.ensure();const t=et(ut|Yt,e);return(n={})=>new Promise(r=>{n.outro?Ft(t,()=>{Oe(t),r(void 0)}):(Oe(t),r(void 0))})}function Pi(e){return et(nn,e)}function Pu(e){return et(en|Yt,e)}function Oi(e,t=0){return et(Bn|t,e)}function $i(e,t=[],n=[],r=[]){gu(r,t,n,i=>{et(Bn,()=>{e(...i.map($))})})}function Ni(e,t=0){var n=et(qe|t,e);return n}function We(e){return et(Ve|Yt,e)}function ga(e){var t=e.teardown;if(t!==null){const n=xt,r=Z;os(!0),ze(null);try{t.call(null)}finally{os(n),ze(r)}}}function Mi(e,t=!1){var n=e.first;for(e.first=e.last=null;n!==null;){const i=n.ac;i!==null&&Fn(()=>{i.abort(Rn)});var r=n.next;n.f&ut?n.parent=null:Oe(n,t),n=r}}function Ou(e){for(var t=e.first;t!==null;){var n=t.next;t.f&Ve||Oe(t),t=n}}function Oe(e,t=!0){var n=!1;(t||e.f&jo)&&e.nodes!==null&&e.nodes.end!==null&&($u(e.nodes.start,e.nodes.end),n=!0),e.f|=jr,Mi(e,t&&!n),Mn(e,0);var r=e.nodes&&e.nodes.t;if(r!==null)for(const s of r)s.stop();ga(e),e.f^=jr,e.f|=Ge;var i=e.parent;i!==null&&i.first!==null&&ma(e),e.next=e.prev=e.teardown=e.ctx=e.deps=e.fn=e.nodes=e.ac=e.b=null}function $u(e,t){for(;e!==null;){var n=e===t?null:ft(e);e.remove(),e=n}}function ma(e){var t=e.parent,n=e.prev,r=e.next;n!==null&&(n.next=r),r!==null&&(r.prev=n),t!==null&&(t.first===e&&(t.first=r),t.last===e&&(t.last=n))}function Ft(e,t,n=!0){var r=[];_a(e,r,!0);var i=()=>{n&&Oe(e),t&&t()},s=r.length;if(s>0){var a=()=>--s||i();for(var o of r)o.out(a)}else i()}function _a(e,t,n){if(!(e.f&Pe)){e.f^=Pe;var r=e.nodes&&e.nodes.t;if(r!==null)for(const o of r)(o.is_global||n)&&t.push(o);for(var i=e.first;i!==null;){var s=i.next;if(!(i.f&ut)){var a=(i.f&rn)!==0||(i.f&Ve)!==0&&(e.f&qe)!==0;_a(i,t,a?n:!1)}i=s}}}function or(e){ba(e,!0)}function ba(e,t){if(e.f&Pe){e.f^=Pe,e.f&me||(fe(e,pe),Et.ensure().schedule(e));for(var n=e.first;n!==null;){var r=n.next,i=(n.f&rn)!==0||(n.f&Ve)!==0;ba(n,i?t:!1),n=r}var s=e.nodes&&e.nodes.t;if(s!==null)for(const a of s)(a.is_global||t)&&a.in()}}function Hi(e,t){if(e.nodes)for(var n=e.nodes.start,r=e.nodes.end;n!==null;){var i=n===r?null:ft(n);t.append(n),n=i}}let qn=!1,xt=!1;function os(e){xt=e}let Z=null,Je=!1;function ze(e){Z=e}let z=null;function lt(e){z=e}let at=null;function ya(e){Z!==null&&(at??=new Set).add(e)}let Ne=null,Fe=0,Ue=null;function Nu(e){Ue=e}let Ea=1,Rt=0,kt=Rt;function us(e){kt=e}function wa(){return++Ea}function kn(e){var t=e.f;if(t&pe)return!0;if(t&ye&&(e.f&=~jt),t&Qe){for(var n=e.deps,r=n.length,i=0;i<r;i++){var s=n[i];if(kn(s)&&ta(s),s.wv>e.wv)return!0}t&je&&Ze===null&&fe(e,me)}return!1}function xa(e,t,n=!0){var r=e.reactions;if(r!==null&&!(at!==null&&at.has(e)))for(var i=0;i<r.length;i++){var s=r[i];s.f&ye?xa(s,t,!1):t===s&&(n?fe(s,pe):s.f&me&&fe(s,Qe),wi(s))}}function Sa(e){var t=Ne,n=Fe,r=Ue,i=Z,s=at,a=xe,o=Je,u=kt,l=e.f;Ne=null,Fe=0,Ue=null,Z=l&(Ve|ut)?null:e,at=null,sn(e.ctx),Je=!1,kt=++Rt,e.ac!==null&&(Fn(()=>{e.ac.abort(Rn)}),e.ac=null);try{e.f|=rr;var f=e.fn,c=f();e.f|=zt;var h=e.deps,d=te?.is_fork;if(Ne!==null){var p;if(d||Mn(e,Fe),h!==null&&Fe>0)for(h.length=Fe+Ne.length,p=0;p<Ne.length;p++)h[Fe+p]=Ne[p];else e.deps=h=Ne;if(Ai()&&e.f&je)for(p=Fe;p<h.length;p++)(h[p].reactions??=[]).push(e)}else!d&&h!==null&&Fe<h.length&&(Mn(e,Fe),h.length=Fe);if(Ws()&&Ue!==null&&!Je&&h!==null&&!(e.f&(ye|Qe|pe)))for(p=0;p<Ue.length;p++)xa(Ue[p],e);if(i!==null&&i!==e){if(Rt++,i.deps!==null)for(let y=0;y<n;y+=1)i.deps[y].rv=Rt;if(t!==null)for(const y of t)y.rv=Rt;Ue!==null&&(r===null?r=Ue:r.push(...Ue))}return e.f&Pt&&(e.f^=Pt),c}catch(y){return Zs(y)}finally{e.f^=rr,Ne=t,Fe=n,Ue=r,Z=i,at=s,sn(a),Je=o,kt=u}}function Mu(e,t){let n=t.reactions;if(n!==null){var r=Fo.call(n,e);if(r!==-1){var i=n.length-1;i===0?n=t.reactions=null:(n[r]=n[i],n.pop())}}if(n===null&&t.f&ye&&(Ne===null||!er.call(Ne,t))){var s=t;s.f&je&&(s.f^=je,s.f&=~jt),s.v!==ge&&gi(s),s.ac!==null&&Fn(()=>{s.ac.abort(Rn),s.ac=null,fe(s,pe)}),yu(s),Mn(s,0)}}function Mn(e,t){var n=e.deps;if(n!==null)for(var r=t;r<n.length;r++)Mu(e,n[r])}function un(e){var t=e.f;if(!(t&Ge)){fe(e,me);var n=z,r=qn;z=e,qn=(t&(Ve|ut))===0;try{t&(qe|Bs)?Ou(e):Mi(e),ga(e);var i=Sa(e);e.teardown=typeof i=="function"?i:null,e.wv=Ea;var s;$s&&su&&e.f&pe&&e.deps}finally{qn=r,z=n}}}function $(e){var t=e.f,n=(t&ye)!==0;if(Z!==null&&!Je){var r=z!==null&&(z.f&Ge)!==0;if(!r&&(at===null||!at.has(e))){var i=Z.deps;if(Z.f&rr)e.rv<Rt&&(e.rv=Rt,Ne===null&&i!==null&&i[Fe]===e?Fe++:Ne===null?Ne=[e]:Ne.push(e));else{Z.deps??=[],er.call(Z.deps,e)||Z.deps.push(e);var s=e.reactions;s===null?e.reactions=[Z]:er.call(s,Z)||s.push(Z)}}}if(xt&&st.has(e))return st.get(e);if(n){var a=e;if(xt){var o=a.v;return(!(a.f&me)&&a.reactions!==null||Ca(a))&&(o=yi(a)),st.set(a,o),o}var u=(a.f&je)===0&&!Je&&Z!==null&&(qn||(Z.f&je)!==0),l=(a.f&zt)===0;kn(a)&&(u&&(a.f|=je),ta(a)),u&&!l&&(na(a),Ta(a))}if(Ze?.has(e))return Ze.get(e);if(e.f&Pt)throw e.v;return e.v}function Ta(e){if(e.f|=je,e.deps!==null)for(const t of e.deps)(t.reactions??=[]).push(e),t.f&ye&&!(t.f&je)&&(na(t),Ta(t))}function Ca(e){if(e.v===ge)return!0;if(e.deps===null)return!1;for(const t of e.deps)if(st.has(t)||t.f&ye&&Ca(t))return!0;return!1}function Nt(e){var t=Je;try{return Je=!0,e()}finally{Je=t}}const xn=Symbol("events"),Aa=new Set,Jr=new Set;function Hu(e){if(!K)return;e.removeAttribute("onload"),e.removeAttribute("onerror");const t=e.__e;t!==void 0&&(e.__e=void 0,queueMicrotask(()=>{e.isConnected&&e.dispatchEvent(t)}))}function Du(e,t,n,r={}){function i(s){if(r.capture||Qr.call(t,s),!s.cancelBubble)return Fn(()=>n?.call(this,s))}return e.startsWith("pointer")||e.startsWith("touch")||e==="wheel"?it(()=>{t.addEventListener(e,i,r)}):t.addEventListener(e,i,r),i}function Bu(e,t,n,r,i){var s={capture:r,passive:i},a=Du(e,t,n,s);(t===document.body||t===window||t===document||t instanceof HTMLMediaElement)&&Ii(()=>{t.removeEventListener(e,a,s)})}function Di(e,t,n){(t[xn]??={})[e]=n}function Bi(e){for(var t=0;t<e.length;t++)Aa.add(e[t]);for(var n of Jr)n(e)}let $r=null,Nr=!1;function Qr(e){var t=this,n=t.ownerDocument,r=e.type,i=e.composedPath?.()||[],s=i[0]||e.target;$r=e,Nr||(Nr=!0,setTimeout(()=>{Nr=!1,$r=null}));var a=0,o=$r===e&&e[xn];if(o){var u=i.indexOf(o);if(u!==-1&&(t===document||t===window)){e[xn]=t;return}var l=i.indexOf(t);if(l===-1)return;u<=l&&(a=u)}if(s=i[a]||e.target,s!==t){On(e,"currentTarget",{configurable:!0,get(){return s||n}});var f=Z,c=z;ze(null),lt(null);try{for(var h,d=[];s!==null&&s!==t;){try{var p=s[xn]?.[r];p!=null&&(!s.disabled||e.target===s)&&p.call(s,e)}catch(y){h?d.push(y):h=y}if(e.cancelBubble)break;a++,s=a<i.length?i[a]:null}if(h){for(let y of d)queueMicrotask(()=>{throw y});throw h}}finally{e[xn]=t,delete e.currentTarget,ze(f),lt(c)}}}const Ru=globalThis?.window?.trustedTypes&&globalThis.window.trustedTypes.createPolicy("svelte-trusted-html",{createHTML:e=>e});function Lu(e){return Ru?.createHTML(e)??e}function Ia(e){var t=Ti("template");return t.innerHTML=Lu(e.replaceAll("<!>","<!---->")),t.content}function Ot(e,t){var n=z;n.nodes===null&&(n.nodes={start:e,end:t,a:null,t:null})}function vn(e,t){var n=(t&Bo)!==0,r=(t&Ro)!==0,i,s=!e.startsWith("<!>");return()=>{if(K)return Ot(ee,null),ee;i===void 0&&(i=Ia(s?e:"<!>"+e),n||(i=wt(i)));var a=r||ua?document.importNode(i,!0):i.cloneNode(!0);if(n){var o=wt(a),u=a.lastChild;Ot(o,u)}else Ot(a,a);return a}}function Fu(e,t,n="svg"){var r=!e.startsWith("<!>"),i=`<${n}>${r?e:"<!>"+e}</${n}>`,s;return()=>{if(K)return Ot(ee,null),ee;if(!s){var a=Ia(i),o=wt(a);s=wt(o)}var u=s.cloneNode(!0);return Ot(u,u),u}}function ku(e,t){return Fu(e,t,"svg")}function Gu(){if(K)return Ot(ee,null),ee;var e=document.createDocumentFragment(),t=document.createComment(""),n=Ke();return e.append(t,n),Ot(t,n),e}function Gt(e,t){if(K){var n=z;(!(n.f&zt)||n.nodes.end===null)&&(n.nodes.end=ee),_r();return}e!==null&&e.before(t)}const Uu=["touchstart","touchmove"];function ju(e){return Uu.includes(e)}function Ri(e,t){var n=t==null?"":typeof t=="object"?`${t}`:t;n!==(e[Yr]??=e.nodeValue)&&(e[Yr]=n,e.nodeValue=`${n}`)}function Pa(e,t){return Oa(e,t)}function Vu(e,t){Zr(),t.intro=t.intro??!1;const n=t.target,r=K,i=ee;try{for(var s=wt(n);s&&(s.nodeType!==Ln||s.data!==Os);)s=ft(s);if(!s)throw tn;_t(!0),He(s);const a=Oa(e,{...t,anchor:s});return _t(!1),a}catch(a){if(a instanceof Error&&a.message.split(`
2
- `).some(o=>o.startsWith("https://svelte.dev/e/")))throw a;return a!==tn&&console.warn("Failed to hydrate: ",a),t.recover===!1&&Jo(),Zr(),ha(n),_t(!1),Pa(e,t)}finally{_t(r),He(i)}}const zn=new Map;function Oa(e,{target:t,anchor:n,props:r={},events:i,context:s,intro:a=!0,transformError:o}){Zr();var u=void 0,l=Iu(()=>{var f=n??t.appendChild(Ke());pu(f,{pending:()=>{}},d=>{br({});var p=xe;if(s&&(p.c=s),i&&(r.$$events=i),K&&Ot(d,null),u=e(d,r)||{},K&&(z.nodes.end=ee,ee===null||ee.nodeType!==Ln||ee.data!==vi))throw mr(),tn;yr()},o);var c=new Set,h=d=>{for(var p=0;p<d.length;p++){var y=d[p];if(!c.has(y)){c.add(y);var _=ju(y);for(const M of[t,document]){var P=zn.get(M);P===void 0&&(P=new Map,zn.set(M,P));var L=P.get(y);L===void 0?(M.addEventListener(y,Qr,{passive:_}),P.set(y,1)):P.set(y,L+1)}}}};return h(vr(Aa)),Jr.add(h),()=>{for(var d of c)for(const _ of[t,document]){var p=zn.get(_),y=p.get(d);--y==0?(_.removeEventListener(d,Qr),p.delete(d),p.size===0&&zn.delete(_)):p.set(d,y)}Jr.delete(h),f!==n&&f.parentNode?.removeChild(f)}});return Kr.set(u,l),u}let Kr=new WeakMap;function zu(e,t){const n=Kr.get(e);return n?(Kr.delete(e),n(t)):Promise.resolve()}class Yu{anchor;#e=new Map;#t=new Map;#n=new Map;#a=new Set;#i=!0;constructor(t,n=!0){this.anchor=t,this.#i=n}#o=t=>{if(this.#e.has(t)){var n=this.#e.get(t),r=this.#t.get(n);if(r)or(r),this.#a.delete(n);else{var i=this.#n.get(n);i&&(or(i.effect),this.#t.set(n,i.effect),this.#n.delete(n),i.fragment.lastChild.remove(),this.anchor.before(i.fragment),r=i.effect)}for(const[s,a]of this.#e){if(this.#e.delete(s),s===t)break;const o=this.#n.get(a);o&&(Oe(o.effect),this.#n.delete(a))}for(const[s,a]of this.#t){if(s===n||this.#a.has(s))continue;const o=()=>{if(Array.from(this.#e.values()).includes(s)){var l=document.createDocumentFragment();Hi(a,l),l.append(Ke()),this.#n.set(s,{effect:a,fragment:l})}else Oe(a);this.#a.delete(s),this.#t.delete(s)};this.#i||!r?(this.#a.add(s),Ft(a,o,!1)):o()}}};#r=t=>{this.#e.delete(t);const n=Array.from(this.#e.values());for(const[r,i]of this.#n)n.includes(r)||(Oe(i.effect),this.#n.delete(r))};ensure(t,n){var r=te;n&&!this.#t.has(t)&&!this.#n.has(t)&&this.#t.set(t,We(()=>n(this.anchor))),this.#e.set(r,t),K&&(this.anchor=ee),this.#o(r)}}function Xu(e){xe===null&&Us(),pa(()=>{const t=Nt(e);if(typeof t=="function")return t})}function Wu(e){xe===null&&Us(),Xu(()=>()=>Nt(e))}function $a(e,t,n=!1){var r;K&&(r=ee,_r());var i=new Yu(e),s=n?rn:0;function a(o,u){if(K){var l=Vs(r);if(o!==parseInt(l.substring(1))){var f=ir();He(f),i.anchor=f,_t(!1),i.ensure(o,u),_t(!0);return}}i.ensure(o,u)}Ni(()=>{var o=!1;t((u,l=0)=>{o=!0,a(l,u)}),o||a(-1,null)},s)}function Na(e,t){return t}function qu(e,t,n){for(var r=[],i=t.length,s,a=t.length,o=0;o<i;o++){let c=t[o];Ft(c,()=>{if(s){if(s.pending.delete(c),s.done.add(c),s.pending.size===0){var h=e.outrogroups;ei(e,vr(s.done)),h.delete(s),h.size===0&&(e.outrogroups=null)}}else a-=1},!1)}if(a===0){var u=r.length===0&&n!==null&&e.pending.size===0;if(u){var l=n,f=l.parentNode;ha(f),f.append(l),e.items.clear()}ei(e,t,!u)}else s={pending:new Set(t),done:new Set},(e.outrogroups??=new Set).add(s)}function ei(e,t,n=!0){var r;if(e.pending.size>0){r=new Set;for(const a of e.pending.values())for(const o of a)r.add(e.items.get(o).e)}for(var i=0;i<t.length;i++){var s=t[i];if(r?.has(s)){s.f|=rt;const a=document.createDocumentFragment();Hi(s,a)}else Oe(t[i],n)}}var ls;function Li(e,t,n,r,i,s=null){var a=e,o=new Map,u=(t&Ps)!==0;if(u){var l=e;a=K?He(wt(l)):l.appendChild(Ke())}K&&_r();var f=null,c=ea(()=>{var L=n();return Ns(L)?L:L==null?[]:vr(L)}),h,d=new Map,p=!0;function y(L){P.effect.f&Ge||(P.pending.delete(L),P.fallback=f,Zu(P,h,a,t,r),f!==null&&(h.length===0?f.f&rt?(f.f^=rt,Sn(f,null,a)):or(f):Ft(f,()=>{f=null})))}var _=Ni(()=>{h=$(c);var L=h.length;let M=!1;if(K){var R=Vs(a)===pi;R!==(L===0)&&(a=ir(),He(a),_t(!1),M=!0)}for(var Y=new Set,N=te,C=0;C<L;C+=1){K&&ee.nodeType===Ln&&ee.data===vi&&(a=ee,M=!0,_t(!1));var S=h[C],j=r(S,C),g=p?null:o.get(j);g?(g.v&&on(g.v,S),g.i&&on(g.i,C)):(g=Ju(o,p?a:ls??=Ke(),S,j,C,i,t,n),p||(g.e.f|=rt),o.set(j,g)),Y.add(j)}L===0&&s&&!f&&(p?f=We(()=>s(a)):(f=We(()=>s(ls??=Ke())),f.f|=rt)),L>Y.size&&Yo(),K&&L>0&&He(ir()),p||(d.set(N,Y),y(N)),M&&_t(!0),$(c)}),P={effect:_,items:o,pending:d,outrogroups:null,fallback:f};p=!1,K&&(a=ee)}function yn(e){for(;e!==null&&!(e.f&Ve);)e=e.next;return e}function Zu(e,t,n,r,i){var s=(r&Oo)!==0,a=t.length,o=e.items,u=yn(e.effect.first),l,f=null,c,h=[],d=[],p,y,_,P;if(s)for(P=0;P<a;P+=1)p=t[P],y=i(p,P),_=o.get(y).e,_.f&rt||(_.nodes?.a?.measure(),(c??=new Set).add(_));for(P=0;P<a;P+=1){if(p=t[P],y=i(p,P),_=o.get(y).e,e.outrogroups!==null)for(const g of e.outrogroups)g.pending.delete(_),g.done.delete(_);if(_.f&Pe&&(or(_),s&&(_.nodes?.a?.unfix(),(c??=new Set).delete(_))),_.f&rt)if(_.f^=rt,_===u)Sn(_,null,n);else{var L=f?f.next:u;_===e.effect.last&&(e.effect.last=_.prev),_.prev&&(_.prev.next=_.next),_.next&&(_.next.prev=_.prev),Tt(e,f,_),Tt(e,_,L),Sn(_,L,n),f=_,h=[],d=[],u=yn(f.next);continue}if(_!==u){if(l!==void 0&&l.has(_)){if(h.length<d.length){var M=d[0],R;f=M.prev;var Y=h[0],N=h[h.length-1];for(R=0;R<h.length;R+=1)Sn(h[R],M,n);for(R=0;R<d.length;R+=1)l.delete(d[R]);Tt(e,Y.prev,N.next),Tt(e,f,Y),Tt(e,N,M),u=M,f=N,P-=1,h=[],d=[]}else l.delete(_),Sn(_,u,n),Tt(e,_.prev,_.next),Tt(e,_,f===null?e.effect.first:f.next),Tt(e,f,_),f=_;continue}for(h=[],d=[];u!==null&&u!==_;)(l??=new Set).add(u),d.push(u),u=yn(u.next);if(u===null)continue}_.f&rt||h.push(_),f=_,u=yn(_.next)}if(e.outrogroups!==null){for(const g of e.outrogroups)g.pending.size===0&&(ei(e,vr(g.done)),e.outrogroups?.delete(g));e.outrogroups.size===0&&(e.outrogroups=null)}if(u!==null||l!==void 0){var C=[];if(l!==void 0)for(_ of l)_.f&Pe||C.push(_);for(;u!==null;)!(u.f&Pe)&&u!==e.fallback&&C.push(u),u=yn(u.next);var S=C.length;if(S>0){var j=r&Ps&&a===0?n:null;if(s){for(P=0;P<S;P+=1)C[P].nodes?.a?.measure();for(P=0;P<S;P+=1)C[P].nodes?.a?.fix()}qu(e,C,j)}}s&&it(()=>{if(c!==void 0)for(_ of c)_.nodes?.a?.apply()})}function Ju(e,t,n,r,i,s,a,o){var u=a&Io?a&$o?Vt(n):xi(n,!1,!1):null,l=a&Po?Vt(i):null;return{v:u,i:l,e:We(()=>(s(t,u??n,l??i,o),()=>{e.delete(r)}))}}function Sn(e,t,n){if(e.nodes)for(var r=e.nodes.start,i=e.nodes.end,s=t&&!(t.f&rt)?t.nodes.start:n;r!==null;){var a=ft(r);if(s.before(r),r===i)return;r=a}}function Tt(e,t,n){t===null?e.effect.first=n:t.next=n,n===null?e.effect.last=t:n.prev=t}function Fi(e,t){Pi(()=>{e=z?.parent?.nodes?.start??e;var n=e.getRootNode(),r=n.host?n:n.head??n.ownerDocument.head;if(!r.querySelector("#"+t.hash)){const i=Ti("style");i.id=t.hash,i.textContent=t.code,r.appendChild(i)}})}function Ma(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var i=e.length;for(t=0;t<i;t++)e[t]&&(n=Ma(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function Qu(){for(var e,t,n=0,r="",i=arguments.length;n<i;n++)(e=arguments[n])&&(t=Ma(e))&&(r&&(r+=" "),r+=t);return r}function Ku(e){return typeof e=="object"?Qu(e):e??""}const fs=[...`
3
- \r\f \v\uFEFF`];function el(e,t,n){var r=e==null?"":""+e;if(t&&(r=r?r+" "+t:t),n){for(var i of Object.keys(n))if(n[i])r=r?r+" "+i:i;else if(r.length)for(var s=i.length,a=0;(a=r.indexOf(i,a))>=0;){var o=a+s;(a===0||fs.includes(r[a-1]))&&(o===r.length||fs.includes(r[o]))?r=(a===0?"":r.substring(0,a))+r.substring(o+1):a=o}}return r===""?null:r}function tl(e,t){return e==null?null:String(e)}function ki(e,t,n,r,i,s){var a=e[Vr];if(K||a!==n||a===void 0){var o=el(n,r,s);(!K||o!==e.getAttribute("class"))&&(o==null?e.removeAttribute("class"):e.className=o),e[Vr]=n}else if(s&&i!==s)for(var u in s){var l=!!s[u];(i==null||l!==!!i[u])&&e.classList.toggle(u,l)}return s}function nl(e,t,n,r){var i=e[zr];if(K||i!==t){var s=tl(t);(!K||s!==e.getAttribute("style"))&&(s==null?e.removeAttribute("style"):e.style.cssText=s),e[zr]=t}return r}const rl=Symbol("is custom element"),il=Symbol("is html"),sl=Gs?"link":"LINK",al=Gs?"progress":"PROGRESS";function ol(e){if(K){var t=!1,n=()=>{if(!t){if(t=!0,e.hasAttribute("value")){var r=e.value;ur(e,"value",null),e.value=r}if(e.hasAttribute("checked")){var i=e.checked;ur(e,"checked",null),e.checked=i}}};e[ks]=n,it(n),cu()}}function ul(e,t){var n=Ha(e);n.value===(n.value=t??void 0)||e.value===t&&(t!==0||e.nodeName!==al)||(e.value=t??"")}function ur(e,t,n,r){var i=Ha(e);K&&(i[t]=e.getAttribute(t),t==="src"||t==="srcset"||t==="href"&&e.nodeName===sl)||i[t]!==(i[t]=n)&&(t==="loading"&&(e[Vo]=n),n==null?e.removeAttribute(t):typeof n!="string"&&ll(e).includes(t)?e[t]=n:e.setAttribute(t,n))}function Ha(e){return e[Fs]??={[rl]:e.nodeName.includes("-"),[il]:e.namespaceURI===Lo}}var cs=new Map;function ll(e){var t=e.getAttribute("is")||e.nodeName,n=cs.get(t);if(n)return n;cs.set(t,n=[]);for(var r,i=e,s=Element.prototype;s!==i;){r=ko(i);for(var a in r)r[a].set&&a!=="innerHTML"&&a!=="textContent"&&a!=="innerText"&&n.push(a);i=Ms(i)}return n}class Gi{#e=new WeakMap;#t;#n;static entries=new WeakMap;constructor(t){this.#n=t}observe(t,n){var r=this.#e.get(t)||new Set;return r.add(n),this.#e.set(t,r),this.#a().observe(t,this.#n),()=>{var i=this.#e.get(t);i.delete(n),i.size===0&&(this.#e.delete(t),this.#t.unobserve(t))}}#a(){return this.#t??(this.#t=new ResizeObserver(t=>{for(var n of t){Gi.entries.set(n.target,n);for(var r of this.#e.get(n.target)||[])r(n)}}))}}var fl=new Gi({box:"border-box"});function cl(e,t,n){var r=fl.observe(e,()=>n(e[t]));Pi(()=>(Nt(()=>n(e[t])),r))}function Mr(e,t){return e===t||e?.[An]===t}function hl(e={},t,n,r){var i=xe.r,s=z;return Pi(()=>{var a,o;return Oi(()=>{a=o,o=r?.()||[],Nt(()=>{Mr(n(...o),e)||(t(e,...o),a&&Mr(n(...a),e)&&t(null,...a))})}),()=>{let u=s;for(;u!==i&&u.parent!==null&&u.parent.f&jr;)u=u.parent;const l=()=>{o&&Mr(n(...o),e)&&t(null,...o)},f=u.teardown;u.teardown=()=>{l(),f?.()}}}),e}function At(e,t,n,r){var i=!0,s=(n&Ho)!==0,a=(n&Do)!==0,o=r,u=!0,l=void 0,f=()=>a&&i?(l??=Nn(r),$(l)):(u&&(u=!1,o=a?Nt(r):r),o);let c;if(s){var h=An in e||Ls in e;c=Lt(e,t)?.set??(h&&t in e?R=>e[t]=R:void 0)}var d,p=!1;s?[d,p]=fu(()=>e[t]):d=e[t],d===void 0&&r!==void 0&&(d=f(),c&&(Qo(),c(d)));var y;if(y=()=>{var R=e[t];return R===void 0?f():(u=!0,R)},!(n&Mo))return y;if(c){var _=e.$$legacy;return function(R,Y){return arguments.length>0?((!Y||_||p)&&c(Y?y():R),R):y()}}var P=!1,L=(n&No?Nn:ea)(()=>(P=!1,y()));s&&$(L);var M=z;return function(R,Y){if(arguments.length>0){const N=Y?$(L):s?ke(R):R;return ie(L,N),P=!0,o!==void 0&&(o=N),R}return xt&&P||M.f&Ge?L.v:$(L)}}function dl(e){return new pl(e)}class pl{#e;#t;constructor(t){var n=new Map,r=(s,a)=>{var o=xi(a,!1,!1);return n.set(s,o),o};const i=new Proxy({...t.props||{},$$events:{}},{get(s,a){return $(n.get(a)??r(a,Reflect.get(s,a)))},has(s,a){return a===Ls?!0:($(n.get(a)??r(a,Reflect.get(s,a))),Reflect.has(s,a))},set(s,a,o){return ie(n.get(a)??r(a,o),o),Reflect.set(s,a,o)}});this.#t=(t.hydrate?Vu:Pa)(t.component,{target:t.target,anchor:t.anchor,props:i,context:t.context,intro:t.intro??!1,recover:t.recover,transformError:t.transformError}),(!t?.props?.$$host||t.sync===!1)&&bt(),this.#e=i.$$events;for(const s of Object.keys(this.#t))s==="$set"||s==="$destroy"||s==="$on"||On(this,s,{get(){return this.#t[s]},set(a){this.#t[s]=a},enumerable:!0});this.#t.$set=s=>{Object.assign(i,s)},this.#t.$destroy=()=>{zu(this.#t)}}$set(t){this.#t.$set(t)}$on(t,n){this.#e[t]=this.#e[t]||[];const r=(...i)=>n.call(this,...i);return this.#e[t].push(r),()=>{this.#e[t]=this.#e[t].filter(i=>i!==r)}}$destroy(){this.#t.$destroy()}}let Da;typeof HTMLElement=="function"&&(Da=class extends HTMLElement{$$ctor;$$s;$$c;$$cn=!1;$$d={};$$r=!1;$$p_d={};$$l={};$$l_u=new Map;$$me;$$shadowRoot=null;constructor(e,t,n){super(),this.$$ctor=e,this.$$s=t,n&&(this.$$shadowRoot=this.attachShadow(n))}addEventListener(e,t,n){if(this.$$l[e]=this.$$l[e]||[],this.$$l[e].push(t),this.$$c){const r=this.$$c.$on(e,t);this.$$l_u.set(t,r)}super.addEventListener(e,t,n)}removeEventListener(e,t,n){if(super.removeEventListener(e,t,n),this.$$c){const r=this.$$l_u.get(t);r&&(r(),this.$$l_u.delete(t))}}async connectedCallback(){if(this.$$cn=!0,!this.$$c){let t=function(i){return s=>{const a=Ti("slot");i!=="default"&&(a.name=i),Gt(s,a)}};var e=t;if(await Promise.resolve(),!this.$$cn||this.$$c)return;const n={},r=vl(this);for(const i of this.$$s)i in r&&(i==="default"&&!this.$$d.children?(this.$$d.children=t(i),n.default=!0):n[i]=t(i));for(const i of this.attributes){const s=this.$$g_p(i.name);s in this.$$d||(this.$$d[s]=Zn(s,i.value,this.$$p_d,"toProp"))}for(const i in this.$$p_d)!(i in this.$$d)&&this[i]!==void 0&&(this.$$d[i]=this[i],delete this[i]);this.$$c=dl({component:this.$$ctor,target:this.$$shadowRoot||this,props:{...this.$$d,$$slots:n,$$host:this}}),this.$$me=Au(()=>{Oi(()=>{this.$$r=!0;for(const i of tr(this.$$c)){if(!this.$$p_d[i]?.reflect)continue;this.$$d[i]=this.$$c[i];const s=Zn(i,this.$$d[i],this.$$p_d,"toAttribute");s==null?this.removeAttribute(this.$$p_d[i].attribute||i):this.setAttribute(this.$$p_d[i].attribute||i,s)}this.$$r=!1})});for(const i in this.$$l)for(const s of this.$$l[i]){const a=this.$$c.$on(i,s);this.$$l_u.set(s,a)}this.$$l={}}}attributeChangedCallback(e,t,n){this.$$r||(e=this.$$g_p(e),this.$$d[e]=Zn(e,n,this.$$p_d,"toProp"),this.$$c?.$set({[e]:this.$$d[e]}))}disconnectedCallback(){this.$$cn=!1,Promise.resolve().then(()=>{!this.$$cn&&this.$$c&&(this.$$c.$destroy(),this.$$me(),this.$$c=void 0)})}$$g_p(e){return tr(this.$$p_d).find(t=>this.$$p_d[t].attribute===e||!this.$$p_d[t].attribute&&t.toLowerCase()===e)||e}});function Zn(e,t,n,r){const i=n[e]?.type;if(t=i==="Boolean"&&typeof t!="boolean"?t!=null:t,!r||!n[e])return t;if(r==="toAttribute")switch(i){case"Object":case"Array":return t==null?null:JSON.stringify(t);case"Boolean":return t?"":null;case"Number":return t??null;default:return t}else switch(i){case"Object":case"Array":return t&&JSON.parse(t);case"Boolean":return t;case"Number":return t!=null?+t:t;default:return t}}function vl(e){const t={};return e.childNodes.forEach(n=>{t[n.slot||"default"]=!0}),t}function Ui(e,t,n,r,i,s){let a=class extends Da{constructor(){super(e,n,i),this.$$p_d=t}static get observedAttributes(){return tr(t).map(o=>(t[o].attribute||o).toLowerCase())}};return tr(t).forEach(o=>{On(a.prototype,o,{get(){return this.$$c&&o in this.$$c?this.$$c[o]:this.$$d[o]},set(u){u=Zn(o,u,t),this.$$d[o]=u;var l=this.$$c;if(l){var f=Lt(l,o)?.get;f?l[o]=u:l.$set({[o]:u})}}})}),r.forEach(o=>{On(a.prototype,o,{get(){return this.$$c?.[o]}})}),e.element=a,a}const De=(e,t)=>{window.postMessage({...t,type:`Challenges:${e}`},window.location.href)},gl=e=>{De("TabClicked",{tabName:e})},ml=(e,t,n)=>{De("OptInClicked",{id:e,name:t,status:n})},_l=(e,t,n)=>{De("OptOutClicked",{id:e,name:t,status:n})},bl=(e,t,n)=>{De("ViewDetailClicked",{id:e,name:t,status:n})},yl=(e,t,n,r)=>{De("DetailTabClicked",{id:e,name:t,status:n,tabName:r})},El=(e,t)=>{De("DetailPageOpen",{isOpen:e,challengeId:t})},wl=(e,t,n)=>{De("PauseClicked",{id:e,name:t,status:n})},xl=(e,t,n)=>{De("ResumeClicked",{id:e,name:t,status:n})},ti=e=>{De("ActionSuccess",{action:e})},ni=(e,t,n)=>{De("ActionFail",{action:e,errorMessage:t,errorCode:n})},Sl=(e,t,n,r)=>{De("GameLaunch",{gameId:e.CasinoGameId,ClientCompatibility:e.ClientCompatibility,GameId:e.GameId,GameName:e.GameName,GameLaunchUrl:e.GameLaunchUrl,RestrictedCountries:e.RestrictedCountries,Vendor:e.Vendor,challengeId:t,challengeName:n,challengeStatus:r})},Tl=(e,t,n)=>{De("GoToDeposit",{id:e,name:t,status:n})},Ba=()=>{De("LoginClicked")},Cl=e=>{De("PromoClicked",{promoType:e})},Al="Challenges:OptoutConfirmed";var Tn=(e=>(e[e.Accumulative=0]="Accumulative",e[e.SingleBet=1]="SingleBet",e[e.MultipleOneBetSize=2]="MultipleOneBetSize",e[e.BetMultiplier=3]="BetMultiplier",e))(Tn||{}),Cn=(e=>(e[e.Single=0]="Single",e[e.Daily=1]="Daily",e[e.Weekly=2]="Weekly",e[e.Monthly=3]="Monthly",e))(Cn||{}),lr=(e=>(e[e.Draft=0]="Draft",e[e.Enabled=1]="Enabled",e[e.Paused=2]="Paused",e[e.Closed=3]="Closed",e[e.Deleted=4]="Deleted",e))(lr||{}),V=(e=>(e[e.Started=0]="Started",e[e.InProgress=1]="InProgress",e[e.PendingLevelReward=2]="PendingLevelReward",e[e.Completed=3]="Completed",e[e.Expired=4]="Expired",e[e.Forfeited=5]="Forfeited",e[e.Awaiting=6]="Awaiting",e[e.Paused=7]="Paused",e))(V||{}),Ra=(e=>(e[e.Completed=0]="Completed",e[e.Expired=1]="Expired",e[e.Forfeited=2]="Forfeited",e))(Ra||{}),ot=(e=>(e[e.Closed=0]="Closed",e[e.InProgress=1]="InProgress",e[e.Fillup=2]="Fillup",e[e.Completed=3]="Completed",e))(ot||{}),Jn=(e=>(e[e.RealCash=0]="RealCash",e[e.BonusMoney=1]="BonusMoney",e[e.Mixed=2]="Mixed",e))(Jn||{}),wr=(e=>(e[e.GameLaunch=0]="GameLaunch",e[e.Reward=1]="Reward",e[e.Manual=2]="Manual",e[e.Claim=3]="Claim",e[e.Event=4]="Event",e[e.Deposit=5]="Deposit",e[e.ClaimByButton=6]="ClaimByButton",e))(wr||{}),fr=(e=>(e[e.Casino=0]="Casino",e[e.Any=1]="Any",e[e.Sportsbook=2]="Sportsbook",e))(fr||{}),Dt=(e=>(e.OptIn="optIn",e.OptOut="optOut",e.Pause="pause",e.Resume="resume",e.Claim="claim",e))(Dt||{});const ln=0,Gn=20,Il=10,Pl=e=>e?Il:Gn,Ol=7;class La extends Error{constructor(t,n){super(n??"Challenge API Error"),this.errorCode=t,this.name="ChallengeApiError"}}const $l=(e,t)=>new URL(`${e}/challenge/${t}`),tt=async(e,t,n,r=i=>i?.ErrorMessage??null)=>{const s=await(await fetch($l(e,t).href,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(n)})).json();if(!s?.Success)throw new La(s?.ErrorCode??null,r(s));return s},ji=({domainId:e,locale:t="en",pageNumber:n=ln,pageSize:r=Gn,sessionId:i,isFutureAvailable:s=!1})=>({DomainId:String(e),PlayerLanguage:t,PageNumber:n,PageSize:r,...i&&{PlayerSession:i,IsFutureAvailable:s}}),Fa=({domainId:e,locale:t="en",pageNumber:n=ln,pageSize:r=Gn,challengeId:i,sessionId:s})=>({DomainId:String(e),PlayerLanguage:t,PageNumber:n,PageSize:r,ChallengeId:i,...s&&{PlayerSession:s}}),Hr=e=>tt(e.endpoint,"GetChallengesInfo",ji(e)),Nl=async({challengeId:e,...t})=>{const n={...Fa({...t,challengeId:e})};return(await tt(t.endpoint,"GetChallengesInfo",n)).Data?.[0]},Ml=e=>tt(e.endpoint,"DisplayableWidgetChallenges",ji({...e,isFutureAvailable:e.isFutureAvailable??!0})),Hl=async({challengeId:e,...t})=>{const n={...Fa({...t,challengeId:e})};return(await tt(t.endpoint,"DisplayableWidgetChallenges",n)).Data?.[0]},ka=({userId:e,...t})=>{const n={...ji(t),...e&&{UserId:String(e)}};return tt(t.endpoint,"PlayerHistory",n)},Dl=({domainId:e,code:t,sessionId:n,endpoint:r})=>{const i={DomainId:String(e),ActivationCode:t,PlayerSession:n};return tt(r,"GrantChallengeByCode",i)},Bl=async({challengeId:e,sessionId:t,endpoint:n})=>{const r={ChallengeId:e,...t&&{PlayerSession:t}};return(await tt(n,"GetChallengeGames",r)).ChallengeGames},Rl=({endpoint:e,domainId:t,sessionId:n,userId:r,progressTo:i,isPause:s=!1})=>{const a={DomainId:String(t),...n&&{PlayerSession:n},...r&&{InternalUserId:String(r)},...s?{ProgressToDeactivate:i}:{ProgressToActivate:i}};return tt(e,"ChangeProgressStatus",a)},Ll=({endpoint:e,domainId:t,challengeProgressId:n})=>{const r={DomainId:String(t),ChallengeProgressId:n};return tt(e,"ChangeProgressIsNewStatus",r)},Fl=({endpoint:e,domainId:t,sessionId:n,userId:r,challengeId:i})=>{const s={DomainId:String(t),...n&&{PlayerSession:n},ChallengeId:i,OperatorUserId:String(r)};return tt(e,"ChallengeForfeit",s,a=>a?.Message??a?.ErrorMessage??null)},kl=({endpoint:e,domainId:t,sessionId:n,challengeId:r})=>{const i={DomainId:String(t),...n&&{PlayerSession:n},ChallengeId:r};return tt(e,"ChallengePlayerClaimByButtonGrant",i)};var Vi=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function zi(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var ri={exports:{}};/** @license
4
- * eventsource.js
5
- * Available under MIT License (MIT)
6
- * https://github.com/Yaffle/EventSource/
7
- */(function(e,t){(function(n){var r=n.setTimeout,i=n.clearTimeout,s=n.XMLHttpRequest,a=n.XDomainRequest,o=n.ActiveXObject,u=n.EventSource,l=n.document,f=n.Promise,c=n.fetch,h=n.Response,d=n.TextDecoder,p=n.TextEncoder,y=n.AbortController;if(typeof window<"u"&&typeof l<"u"&&!("readyState"in l)&&l.body==null&&(l.readyState="loading",window.addEventListener("load",function(v){l.readyState="complete"},!1)),s==null&&o!=null&&(s=function(){return new o("Microsoft.XMLHTTP")}),Object.create==null&&(Object.create=function(v){function A(){}return A.prototype=v,new A}),Date.now||(Date.now=function(){return new Date().getTime()}),y==null){var _=c;c=function(v,A){var O=A.signal;return _(v,{headers:A.headers,credentials:A.credentials,cache:A.cache}).then(function(T){var G=T.body.getReader();return O._reader=G,O._aborted&&O._reader.cancel(),{status:T.status,statusText:T.statusText,headers:T.headers,body:{getReader:function(){return G}}}})},y=function(){this.signal={_reader:null,_aborted:!1},this.abort=function(){this.signal._reader!=null&&this.signal._reader.cancel(),this.signal._aborted=!0}}}function P(){this.bitsNeeded=0,this.codePoint=0}P.prototype.decode=function(v){function A(ne,re,U){if(U===1)return ne>=128>>re&&ne<<re<=2047;if(U===2)return ne>=2048>>re&&ne<<re<=55295||ne>=57344>>re&&ne<<re<=65535;if(U===3)return ne>=65536>>re&&ne<<re<=1114111;throw new Error}function O(ne,re){if(ne===6*1)return re>>6>15?3:re>31?2:1;if(ne===6*2)return re>15?3:2;if(ne===6*3)return 3;throw new Error}for(var T=65533,G="",B=this.bitsNeeded,X=this.codePoint,oe=0;oe<v.length;oe+=1){var J=v[oe];B!==0&&(J<128||J>191||!A(X<<6|J&63,B-6,O(B,X)))&&(B=0,X=T,G+=String.fromCharCode(X)),B===0?(J>=0&&J<=127?(B=0,X=J):J>=192&&J<=223?(B=6*1,X=J&31):J>=224&&J<=239?(B=6*2,X=J&15):J>=240&&J<=247?(B=6*3,X=J&7):(B=0,X=T),B!==0&&!A(X,B,O(B,X))&&(B=0,X=T)):(B-=6,X=X<<6|J&63),B===0&&(X<=65535?G+=String.fromCharCode(X):(G+=String.fromCharCode(55296+(X-65535-1>>10)),G+=String.fromCharCode(56320+(X-65535-1&1023))))}return this.bitsNeeded=B,this.codePoint=X,G};var L=function(){try{return new d().decode(new p().encode("test"),{stream:!0})==="test"}catch(v){console.debug("TextDecoder does not support streaming option. Using polyfill instead: "+v)}return!1};(d==null||p==null||!L())&&(d=P);var M=function(){};function R(v){this.withCredentials=!1,this.readyState=0,this.status=0,this.statusText="",this.responseText="",this.onprogress=M,this.onload=M,this.onerror=M,this.onreadystatechange=M,this._contentType="",this._xhr=v,this._sendTimeout=0,this._abort=M}R.prototype.open=function(v,A){this._abort(!0);var O=this,T=this._xhr,G=1,B=0;this._abort=function(U){O._sendTimeout!==0&&(i(O._sendTimeout),O._sendTimeout=0),(G===1||G===2||G===3)&&(G=4,T.onload=M,T.onerror=M,T.onabort=M,T.onprogress=M,T.onreadystatechange=M,T.abort(),B!==0&&(i(B),B=0),U||(O.readyState=4,O.onabort(null),O.onreadystatechange())),G=0};var X=function(){if(G===1){var U=0,ue="",dt=void 0;if("contentType"in T)U=200,ue="OK",dt=T.contentType;else try{U=T.status,ue=T.statusText,dt=T.getResponseHeader("Content-Type")}catch{U=0,ue="",dt=void 0}U!==0&&(G=2,O.readyState=2,O.status=U,O.statusText=ue,O._contentType=dt,O.onreadystatechange())}},oe=function(){if(X(),G===2||G===3){G=3;var U="";try{U=T.responseText}catch{}O.readyState=3,O.responseText=U,O.onprogress()}},J=function(U,ue){if((ue==null||ue.preventDefault==null)&&(ue={preventDefault:M}),oe(),G===1||G===2||G===3){if(G=4,B!==0&&(i(B),B=0),O.readyState=4,U==="load")O.onload(ue);else if(U==="error")O.onerror(ue);else if(U==="abort")O.onabort(ue);else throw new TypeError;O.onreadystatechange()}},ne=function(U){T!=null&&(T.readyState===4?(!("onload"in T)||!("onerror"in T)||!("onabort"in T))&&J(T.responseText===""?"error":"load",U):T.readyState===3?"onprogress"in T||oe():T.readyState===2&&X())},re=function(){B=r(function(){re()},500),T.readyState===3&&oe()};"onload"in T&&(T.onload=function(U){J("load",U)}),"onerror"in T&&(T.onerror=function(U){J("error",U)}),"onabort"in T&&(T.onabort=function(U){J("abort",U)}),"onprogress"in T&&(T.onprogress=oe),"onreadystatechange"in T&&(T.onreadystatechange=function(U){ne(U)}),("contentType"in T||!("ontimeout"in s.prototype))&&(A+=(A.indexOf("?")===-1?"?":"&")+"padding=true"),T.open(v,A,!0),"readyState"in T&&(B=r(function(){re()},0))},R.prototype.abort=function(){this._abort(!1)},R.prototype.getResponseHeader=function(v){return this._contentType},R.prototype.setRequestHeader=function(v,A){var O=this._xhr;"setRequestHeader"in O&&O.setRequestHeader(v,A)},R.prototype.getAllResponseHeaders=function(){return this._xhr.getAllResponseHeaders!=null&&this._xhr.getAllResponseHeaders()||""},R.prototype.send=function(){if((!("ontimeout"in s.prototype)||!("sendAsBinary"in s.prototype)&&!("mozAnon"in s.prototype))&&l!=null&&l.readyState!=null&&l.readyState!=="complete"){var v=this;v._sendTimeout=r(function(){v._sendTimeout=0,v.send()},4);return}var A=this._xhr;"withCredentials"in A&&(A.withCredentials=this.withCredentials);try{A.send(void 0)}catch(O){throw O}};function Y(v){return v.replace(/[A-Z]/g,function(A){return String.fromCharCode(A.charCodeAt(0)+32)})}function N(v){for(var A=Object.create(null),O=v.split(`\r
8
- `),T=0;T<O.length;T+=1){var G=O[T],B=G.split(": "),X=B.shift(),oe=B.join(": ");A[Y(X)]=oe}this._map=A}N.prototype.get=function(v){return this._map[Y(v)]},s!=null&&s.HEADERS_RECEIVED==null&&(s.HEADERS_RECEIVED=2);function C(){}C.prototype.open=function(v,A,O,T,G,B,X){v.open("GET",G);var oe=0;v.onprogress=function(){var ne=v.responseText,re=ne.slice(oe);oe+=re.length,O(re)},v.onerror=function(ne){ne.preventDefault(),T(new Error("NetworkError"))},v.onload=function(){T(null)},v.onabort=function(){T(null)},v.onreadystatechange=function(){if(v.readyState===s.HEADERS_RECEIVED){var ne=v.status,re=v.statusText,U=v.getResponseHeader("Content-Type"),ue=v.getAllResponseHeaders();A(ne,re,U,new N(ue))}},v.withCredentials=B;for(var J in X)Object.prototype.hasOwnProperty.call(X,J)&&v.setRequestHeader(J,X[J]);return v.send(),v};function S(v){this._headers=v}S.prototype.get=function(v){return this._headers.get(v)};function j(){}j.prototype.open=function(v,A,O,T,G,B,X){var oe=null,J=new y,ne=J.signal,re=new d;return c(G,{headers:X,credentials:B?"include":"same-origin",signal:ne,cache:"no-store"}).then(function(U){return oe=U.body.getReader(),A(U.status,U.statusText,U.headers.get("Content-Type"),new S(U.headers)),new f(function(ue,dt){var _n=function(){oe.read().then(function(Be){if(Be.done)ue(void 0);else{var Se=re.decode(Be.value,{stream:!0});O(Se),_n()}}).catch(function(Be){dt(Be)})};_n()})}).catch(function(U){if(U.name!=="AbortError")return U}).then(function(U){T(U)}),{abort:function(){oe?.cancel(),J.abort()}}};function g(){this._listeners=Object.create(null)}function E(v){r(function(){throw v},0)}g.prototype.dispatchEvent=function(v){v.target=this;var A=this._listeners[v.type];if(A!=null)for(var O=A.length,T=0;T<O;T+=1){var G=A[T];try{typeof G.handleEvent=="function"?G.handleEvent(v):G.call(this,v)}catch(B){E(B)}}},g.prototype.addEventListener=function(v,A){v=String(v);var O=this._listeners,T=O[v];T==null&&(T=[],O[v]=T);for(var G=!1,B=0;B<T.length;B+=1)T[B]===A&&(G=!0);G||T.push(A)},g.prototype.removeEventListener=function(v,A){v=String(v);var O=this._listeners,T=O[v];if(T!=null){for(var G=[],B=0;B<T.length;B+=1)T[B]!==A&&G.push(T[B]);G.length===0?delete O[v]:O[v]=G}};function D(v){this.type=v,this.target=void 0}function F(v,A){D.call(this,v),this.data=A.data,this.lastEventId=A.lastEventId}F.prototype=Object.create(D.prototype);function w(v,A){D.call(this,v),this.status=A.status,this.statusText=A.statusText,this.headers=A.headers}w.prototype=Object.create(D.prototype);function m(v,A){D.call(this,v),this.error=A.error}m.prototype=Object.create(D.prototype);var b=-1,I=0,x=1,H=2,k=-1,W=0,se=1,ce=2,_e=3,$e=/^text\/event\-stream(;.*)?$/i,St=1e3,ct=18e6,ht=function(v,A){var O=v==null?A:parseInt(v,10);return O!==O&&(O=A),Ye(O)},Ye=function(v){return Math.min(Math.max(v,St),ct)},he=function(v,A,O){try{typeof A=="function"&&A.call(v,O)}catch(T){E(T)}};function de(v,A){g.call(this),A=A||{},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,So(this,v,A)}function Mt(){return s!=null&&"withCredentials"in s.prototype||a==null?new s:new a}var Wt=c!=null&&h!=null&&"body"in h.prototype;function So(v,A,O){A=String(A);var T=!!O.withCredentials,G=O.lastEventIdQueryParameterName||"lastEventId",B=Ye(1e3),X=ht(O.heartbeatTimeout,45e3),oe="",J=B,ne=!1,re=0,U=O.headers||{},ue=O.Transport,dt=Wt&&ue==null?void 0:new R(ue!=null?new ue:Mt()),_n=ue!=null&&typeof ue!="string"?new ue:dt==null?new j:new C,Be=void 0,Se=0,Xe=b,qt="",Un="",pt="",jn="",Te=W,Ar=0,Ht=0,To=function(be,ve,Re,Le){if(Xe===I)if(be===200&&Re!=null&&$e.test(Re)){Xe=x,ne=Date.now(),J=B,v.readyState=x;var Ce=new w("open",{status:be,statusText:ve,headers:Le});v.dispatchEvent(Ce),he(v,v.onopen,Ce)}else{var Ee="";be!==200?(ve&&(ve=ve.replace(/\s+/g," ")),Ee="EventSource's response has a status "+be+" "+ve+" that is not 200. Aborting the connection."):Ee="EventSource's response has a Content-Type specifying an unsupported type: "+(Re==null?"-":Re.replace(/\s+/g," "))+". Aborting the connection.",Ir();var Ce=new w("error",{status:be,statusText:ve,headers:Le});v.dispatchEvent(Ce),he(v,v.onerror,Ce),console.error(Ee)}},Co=function(be){if(Xe===x){for(var ve=-1,Re=0;Re<be.length;Re+=1){var Le=be.charCodeAt(Re);(Le===10||Le===13)&&(ve=Re)}var Ce=(ve!==-1?jn:"")+be.slice(0,ve+1);jn=(ve===-1?jn:"")+be.slice(ve+1),be!==""&&(ne=Date.now(),re+=be.length);for(var Ee=0;Ee<Ce.length;Ee+=1){var Le=Ce.charCodeAt(Ee);if(Te===k&&Le===10)Te=W;else if(Te===k&&(Te=W),Le===13||Le===10){if(Te!==W){Te===se&&(Ht=Ee+1);var vt=Ce.slice(Ar,Ht-1),gt=Ce.slice(Ht+(Ht<Ee&&Ce.charCodeAt(Ht)===32?1:0),Ee);vt==="data"?(qt+=`
9
- `,qt+=gt):vt==="id"?Un=gt:vt==="event"?pt=gt:vt==="retry"?(B=ht(gt,B),J=B):vt==="heartbeatTimeout"&&(X=ht(gt,X),Se!==0&&(i(Se),Se=r(function(){bn()},X)))}if(Te===W){if(qt!==""){oe=Un,pt===""&&(pt="message");var Zt=new F(pt,{data:qt.slice(1),lastEventId:Un});if(v.dispatchEvent(Zt),pt==="open"?he(v,v.onopen,Zt):pt==="message"?he(v,v.onmessage,Zt):pt==="error"&&he(v,v.onerror,Zt),Xe===H)return}qt="",pt=""}Te=Le===13?k:W}else Te===W&&(Ar=Ee,Te=se),Te===se?Le===58&&(Ht=Ee+1,Te=ce):Te===ce&&(Te=_e)}}},es=function(be){if(Xe===x||Xe===I){Xe=b,Se!==0&&(i(Se),Se=0),Se=r(function(){bn()},J),J=Ye(Math.min(B*16,J*2)),v.readyState=I;var ve=new m("error",{error:be});v.dispatchEvent(ve),he(v,v.onerror,ve),be!=null&&console.error(be)}},Ir=function(){Xe=H,Be!=null&&(Be.abort(),Be=void 0),Se!==0&&(i(Se),Se=0),v.readyState=H},bn=function(){if(Se=0,Xe!==b){if(!ne&&Be!=null)es(new Error("No activity within "+X+" milliseconds. "+(Xe===I?"No response received.":re+" chars received.")+" Reconnecting.")),Be!=null&&(Be.abort(),Be=void 0);else{var be=Math.max((ne||Date.now())+X-Date.now(),1);ne=!1,Se=r(function(){bn()},be)}return}ne=!1,re=0,Se=r(function(){bn()},X),Xe=I,qt="",pt="",Un=oe,jn="",Ar=0,Ht=0,Te=W;var ve=A;if(A.slice(0,5)!=="data:"&&A.slice(0,5)!=="blob:"&&oe!==""){var Re=A.indexOf("?");ve=Re===-1?A:A.slice(0,Re+1)+A.slice(Re+1).replace(/(?:^|&)([^=&]*)(?:=[^&]*)?/g,function(gt,Zt){return Zt===G?"":gt}),ve+=(A.indexOf("?")===-1?"?":"&")+G+"="+encodeURIComponent(oe)}var Le=v.withCredentials,Ce={};Ce.Accept="text/event-stream";var Ee=v.headers;if(Ee!=null)for(var vt in Ee)Object.prototype.hasOwnProperty.call(Ee,vt)&&(Ce[vt]=Ee[vt]);try{Be=_n.open(dt,To,Co,es,ve,Le,Ce)}catch(gt){throw Ir(),gt}};v.url=A,v.readyState=I,v.withCredentials=T,v.headers=U,v._close=Ir,bn()}de.prototype=Object.create(g.prototype),de.prototype.CONNECTING=I,de.prototype.OPEN=x,de.prototype.CLOSED=H,de.prototype.close=function(){this._close()},de.CONNECTING=I,de.OPEN=x,de.CLOSED=H,de.prototype.withCredentials=void 0;var Ki=u;s!=null&&(u==null||!("withCredentials"in u.prototype))&&(Ki=de),function(v){{var A=v(t);A!==void 0&&(e.exports=A)}}(function(v){v.EventSourcePolyfill=de,v.NativeEventSource=u,v.EventSource=Ki})})(typeof globalThis>"u"?typeof window<"u"?window:typeof self<"u"?self:Vi:globalThis)})(ri,ri.exports);var hs=ri.exports;const ds=(e,t)=>{try{return JSON.parse(e?.data)}catch(n){console.error(`Exception when parsing challenges ${t} live update`,n);return}},Gl=e=>{const{endpoint:t,userId:n,sessionId:r,onNewProgress:i,onSessionExpired:s,onChallengeEnabledChange:a,onProgressForfeited:o}=e;let u,l;const f=()=>{u?.close(),l?.close(),u=void 0,l=void 0};return typeof EventSource>"u"||!t?{close:f}:(n&&r&&(u=new hs.EventSourcePolyfill(`${t}/v2/player/${n}/information/updates`,{headers:{"X-SessionId":r}}),u.addEventListener("message",c=>{const h=ds(c,"player");if(!h)return;if(h.type==="SESSION_EXPIRATION"){f(),s?.();return}const d=h.body;if(d?.messageType==="newProgressNotification"){const p=d.challengeProgress;p&&String(p.InternalUserId)===String(n)&&i?.(p)}})),l=new hs.EventSourcePolyfill(`${t}/v1/encoder/challenges/*/update`),l.addEventListener("message",c=>{const d=ds(c,"status")?.data;if(d)switch(d.messageType){case"disabledChallengeNotification":a?.(String(d.challengeId),!1);break;case"enabledChallengeNotification":a?.(String(d.challengeId),!0);break;case"forfeitedChallengeProgressNotification":o?.(String(d.challengeProgressId));break}}),{close:f})},Ul=(e,t=!1)=>{if(typeof e=="boolean")return e;if(e==null)return t;if(typeof e=="number")return e!==0;const n=String(e).trim().toLowerCase();return n===""?!0:n!=="false"&&n!=="0"},jl=(e,t)=>{if(e==null||e==="")return t;const n=Number(e);return Number.isFinite(n)?n:t};var Ga={exports:{}};(function(e,t){(function(n,r){e.exports=r()})(Vi,function(){var n=1e3,r=6e4,i=36e5,s="millisecond",a="second",o="minute",u="hour",l="day",f="week",c="month",h="quarter",d="year",p="date",y="Invalid Date",_=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,P=/\[([^\]]+)]|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,L={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(w){var m=["th","st","nd","rd"],b=w%100;return"["+w+(m[(b-20)%10]||m[b]||m[0])+"]"}},M=function(w,m,b){var I=String(w);return!I||I.length>=m?w:""+Array(m+1-I.length).join(b)+w},R={s:M,z:function(w){var m=-w.utcOffset(),b=Math.abs(m),I=Math.floor(b/60),x=b%60;return(m<=0?"+":"-")+M(I,2,"0")+":"+M(x,2,"0")},m:function w(m,b){if(m.date()<b.date())return-w(b,m);var I=12*(b.year()-m.year())+(b.month()-m.month()),x=m.clone().add(I,c),H=b-x<0,k=m.clone().add(I+(H?-1:1),c);return+(-(I+(b-x)/(H?x-k:k-x))||0)},a:function(w){return w<0?Math.ceil(w)||0:Math.floor(w)},p:function(w){return{M:c,y:d,w:f,d:l,D:p,h:u,m:o,s:a,ms:s,Q:h}[w]||String(w||"").toLowerCase().replace(/s$/,"")},u:function(w){return w===void 0}},Y="en",N={};N[Y]=L;var C="$isDayjsObject",S=function(w){return w instanceof D||!(!w||!w[C])},j=function w(m,b,I){var x;if(!m)return Y;if(typeof m=="string"){var H=m.toLowerCase();N[H]&&(x=H),b&&(N[H]=b,x=H);var k=m.split("-");if(!x&&k.length>1)return w(k[0])}else{var W=m.name;N[W]=m,x=W}return!I&&x&&(Y=x),x||!I&&Y},g=function(w,m){if(S(w))return w.clone();var b=typeof m=="object"?m:{};return b.date=w,b.args=arguments,new D(b)},E=R;E.l=j,E.i=S,E.w=function(w,m){return g(w,{locale:m.$L,utc:m.$u,x:m.$x,$offset:m.$offset})};var D=function(){function w(b){this.$L=j(b.locale,null,!0),this.parse(b),this.$x=this.$x||b.x||{},this[C]=!0}var m=w.prototype;return m.parse=function(b){this.$d=function(I){var x=I.date,H=I.utc;if(x===null)return new Date(NaN);if(E.u(x))return new Date;if(x instanceof Date)return new Date(x);if(typeof x=="string"&&!/Z$/i.test(x)){var k=x.match(_);if(k){var W=k[2]-1||0,se=(k[7]||"0").substring(0,3);return H?new Date(Date.UTC(k[1],W,k[3]||1,k[4]||0,k[5]||0,k[6]||0,se)):new Date(k[1],W,k[3]||1,k[4]||0,k[5]||0,k[6]||0,se)}}return new Date(x)}(b),this.init()},m.init=function(){var b=this.$d;this.$y=b.getFullYear(),this.$M=b.getMonth(),this.$D=b.getDate(),this.$W=b.getDay(),this.$H=b.getHours(),this.$m=b.getMinutes(),this.$s=b.getSeconds(),this.$ms=b.getMilliseconds()},m.$utils=function(){return E},m.isValid=function(){return this.$d.toString()!==y},m.isSame=function(b,I){var x=g(b);return this.startOf(I)<=x&&x<=this.endOf(I)},m.isAfter=function(b,I){return g(b)<this.startOf(I)},m.isBefore=function(b,I){return this.endOf(I)<g(b)},m.$g=function(b,I,x){return E.u(b)?this[I]:this.set(x,b)},m.unix=function(){return Math.floor(this.valueOf()/1e3)},m.valueOf=function(){return this.$d.getTime()},m.startOf=function(b,I){var x=this,H=!!E.u(I)||I,k=E.p(b),W=function(Ye,he){var de=E.w(x.$u?Date.UTC(x.$y,he,Ye):new Date(x.$y,he,Ye),x);return H?de:de.endOf(l)},se=function(Ye,he){return E.w(x.toDate()[Ye].apply(x.toDate("s"),(H?[0,0,0,0]:[23,59,59,999]).slice(he)),x)},ce=this.$W,_e=this.$M,$e=this.$D,St="set"+(this.$u?"UTC":"");switch(k){case d:return H?W(1,0):W(31,11);case c:return H?W(1,_e):W(0,_e+1);case f:var ct=this.$locale().weekStart||0,ht=(ce<ct?ce+7:ce)-ct;return W(H?$e-ht:$e+(6-ht),_e);case l:case p:return se(St+"Hours",0);case u:return se(St+"Minutes",1);case o:return se(St+"Seconds",2);case a:return se(St+"Milliseconds",3);default:return this.clone()}},m.endOf=function(b){return this.startOf(b,!1)},m.$set=function(b,I){var x,H=E.p(b),k="set"+(this.$u?"UTC":""),W=(x={},x[l]=k+"Date",x[p]=k+"Date",x[c]=k+"Month",x[d]=k+"FullYear",x[u]=k+"Hours",x[o]=k+"Minutes",x[a]=k+"Seconds",x[s]=k+"Milliseconds",x)[H],se=H===l?this.$D+(I-this.$W):I;if(H===c||H===d){var ce=this.clone().set(p,1);ce.$d[W](se),ce.init(),this.$d=ce.set(p,Math.min(this.$D,ce.daysInMonth())).$d}else W&&this.$d[W](se);return this.init(),this},m.set=function(b,I){return this.clone().$set(b,I)},m.get=function(b){return this[E.p(b)]()},m.add=function(b,I){var x,H=this;b=Number(b);var k=E.p(I),W=function(_e){var $e=g(H);return E.w($e.date($e.date()+Math.round(_e*b)),H)};if(k===c)return this.set(c,this.$M+b);if(k===d)return this.set(d,this.$y+b);if(k===l)return W(1);if(k===f)return W(7);var se=(x={},x[o]=r,x[u]=i,x[a]=n,x)[k]||1,ce=this.$d.getTime()+b*se;return E.w(ce,this)},m.subtract=function(b,I){return this.add(-1*b,I)},m.format=function(b){var I=this,x=this.$locale();if(!this.isValid())return x.invalidDate||y;var H=b||"YYYY-MM-DDTHH:mm:ssZ",k=E.z(this),W=this.$H,se=this.$m,ce=this.$M,_e=x.weekdays,$e=x.months,St=x.meridiem,ct=function(he,de,Mt,Wt){return he&&(he[de]||he(I,H))||Mt[de].slice(0,Wt)},ht=function(he){return E.s(W%12||12,he,"0")},Ye=St||function(he,de,Mt){var Wt=he<12?"AM":"PM";return Mt?Wt.toLowerCase():Wt};return H.replace(P,function(he,de){return de||function(Mt){switch(Mt){case"YY":return String(I.$y).slice(-2);case"YYYY":return E.s(I.$y,4,"0");case"M":return ce+1;case"MM":return E.s(ce+1,2,"0");case"MMM":return ct(x.monthsShort,ce,$e,3);case"MMMM":return ct($e,ce);case"D":return I.$D;case"DD":return E.s(I.$D,2,"0");case"d":return String(I.$W);case"dd":return ct(x.weekdaysMin,I.$W,_e,2);case"ddd":return ct(x.weekdaysShort,I.$W,_e,3);case"dddd":return _e[I.$W];case"H":return String(W);case"HH":return E.s(W,2,"0");case"h":return ht(1);case"hh":return ht(2);case"a":return Ye(W,se,!0);case"A":return Ye(W,se,!1);case"m":return String(se);case"mm":return E.s(se,2,"0");case"s":return String(I.$s);case"ss":return E.s(I.$s,2,"0");case"SSS":return E.s(I.$ms,3,"0");case"Z":return k}return null}(he)||k.replace(":","")})},m.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},m.diff=function(b,I,x){var H,k=this,W=E.p(I),se=g(b),ce=(se.utcOffset()-this.utcOffset())*r,_e=this-se,$e=function(){return E.m(k,se)};switch(W){case d:H=$e()/12;break;case c:H=$e();break;case h:H=$e()/3;break;case f:H=(_e-ce)/6048e5;break;case l:H=(_e-ce)/864e5;break;case u:H=_e/i;break;case o:H=_e/r;break;case a:H=_e/n;break;default:H=_e}return x?H:E.a(H)},m.daysInMonth=function(){return this.endOf(c).$D},m.$locale=function(){return N[this.$L]},m.locale=function(b,I){if(!b)return this.$L;var x=this.clone(),H=j(b,I,!0);return H&&(x.$L=H),x},m.clone=function(){return E.w(this.$d,this)},m.toDate=function(){return new Date(this.valueOf())},m.toJSON=function(){return this.isValid()?this.toISOString():null},m.toISOString=function(){return this.$d.toISOString()},m.toString=function(){return this.$d.toUTCString()},w}(),F=D.prototype;return g.prototype=F,[["$ms",s],["$s",a],["$m",o],["$H",u],["$W",l],["$M",c],["$y",d],["$D",p]].forEach(function(w){F[w[1]]=function(m){return this.$g(m,w[0],w[1])}}),g.extend=function(w,m){return w.$i||(w(m,D,g),w.$i=!0),g},g.locale=j,g.isDayjs=S,g.unix=function(w){return g(1e3*w)},g.en=N[Y],g.Ls=N,g.p={},g})})(Ga);var Vl=Ga.exports;const Ut=zi(Vl);var Ua={exports:{}};(function(e,t){(function(n,r){e.exports=r()})(Vi,function(){var n,r,i=1e3,s=6e4,a=36e5,o=864e5,u=31536e6,l=2628e6,f=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/,c=/\[([^\]]+)]|YYYY|YY|Y|M{1,2}|D{1,2}|H{1,2}|m{1,2}|s{1,2}|SSS/g,h={years:u,months:l,days:o,hours:a,minutes:s,seconds:i,milliseconds:1,weeks:6048e5},d=function(N){return N instanceof R},p=function(N,C,S){return new R(N,S,C.$l)},y=function(N){return r.p(N)+"s"},_=function(N){return N<0},P=function(N){return _(N)?Math.ceil(N):Math.floor(N)},L=function(N){return Math.abs(N)},M=function(N,C){return N?_(N)?{negative:!0,format:""+L(N)+C}:{negative:!1,format:""+N+C}:{negative:!1,format:""}},R=function(){function N(S,j,g){var E=this;if(this.$d={},this.$l=g,S===void 0&&(this.$ms=0,this.parseFromMilliseconds()),j)return p(S*h[y(j)],this);if(typeof S=="number")return this.$ms=S,this.parseFromMilliseconds(),this;if(typeof S=="object")return Object.keys(S).forEach(function(w){E.$d[y(w)]=S[w]}),this.calMilliseconds(),this;if(typeof S=="string"){var D=S.match(f);if(D){var F=D.slice(2).map(function(w){return w!=null?Number(w):0});return this.$d.years=F[0],this.$d.months=F[1],this.$d.weeks=F[2],this.$d.days=F[3],this.$d.hours=F[4],this.$d.minutes=F[5],this.$d.seconds=F[6],this.calMilliseconds(),this}}return this}var C=N.prototype;return C.calMilliseconds=function(){var S=this;this.$ms=Object.keys(this.$d).reduce(function(j,g){return j+(S.$d[g]||0)*h[g]},0)},C.parseFromMilliseconds=function(){var S=this.$ms;this.$d.years=P(S/u),S%=u,this.$d.months=P(S/l),S%=l,this.$d.days=P(S/o),S%=o,this.$d.hours=P(S/a),S%=a,this.$d.minutes=P(S/s),S%=s,this.$d.seconds=P(S/i),S%=i,this.$d.milliseconds=S},C.toISOString=function(){var S=M(this.$d.years,"Y"),j=M(this.$d.months,"M"),g=+this.$d.days||0;this.$d.weeks&&(g+=7*this.$d.weeks);var E=M(g,"D"),D=M(this.$d.hours,"H"),F=M(this.$d.minutes,"M"),w=this.$d.seconds||0;this.$d.milliseconds&&(w+=this.$d.milliseconds/1e3,w=Math.round(1e3*w)/1e3);var m=M(w,"S"),b=S.negative||j.negative||E.negative||D.negative||F.negative||m.negative,I=D.format||F.format||m.format?"T":"",x=(b?"-":"")+"P"+S.format+j.format+E.format+I+D.format+F.format+m.format;return x==="P"||x==="-P"?"P0D":x},C.toJSON=function(){return this.toISOString()},C.format=function(S){var j=S||"YYYY-MM-DDTHH:mm:ss",g={Y:this.$d.years,YY:r.s(this.$d.years,2,"0"),YYYY:r.s(this.$d.years,4,"0"),M:this.$d.months,MM:r.s(this.$d.months,2,"0"),D:this.$d.days,DD:r.s(this.$d.days,2,"0"),H:this.$d.hours,HH:r.s(this.$d.hours,2,"0"),m:this.$d.minutes,mm:r.s(this.$d.minutes,2,"0"),s:this.$d.seconds,ss:r.s(this.$d.seconds,2,"0"),SSS:r.s(this.$d.milliseconds,3,"0")};return j.replace(c,function(E,D){return D||String(g[E])})},C.as=function(S){return this.$ms/h[y(S)]},C.get=function(S){var j=this.$ms,g=y(S);return g==="milliseconds"?j%=1e3:j=g==="weeks"?P(j/h[g]):this.$d[g],j||0},C.add=function(S,j,g){var E;return E=j?S*h[y(j)]:d(S)?S.$ms:p(S,this).$ms,p(this.$ms+E*(g?-1:1),this)},C.subtract=function(S,j){return this.add(S,j,!0)},C.locale=function(S){var j=this.clone();return j.$l=S,j},C.clone=function(){return p(this.$ms,this)},C.humanize=function(S){return n().add(this.$ms,"ms").locale(this.$l).fromNow(!S)},C.valueOf=function(){return this.asMilliseconds()},C.milliseconds=function(){return this.get("milliseconds")},C.asMilliseconds=function(){return this.as("milliseconds")},C.seconds=function(){return this.get("seconds")},C.asSeconds=function(){return this.as("seconds")},C.minutes=function(){return this.get("minutes")},C.asMinutes=function(){return this.as("minutes")},C.hours=function(){return this.get("hours")},C.asHours=function(){return this.as("hours")},C.days=function(){return this.get("days")},C.asDays=function(){return this.as("days")},C.weeks=function(){return this.get("weeks")},C.asWeeks=function(){return this.as("weeks")},C.months=function(){return this.get("months")},C.asMonths=function(){return this.as("months")},C.years=function(){return this.get("years")},C.asYears=function(){return this.as("years")},N}(),Y=function(N,C,S){return N.add(C.years()*S,"y").add(C.months()*S,"M").add(C.days()*S,"d").add(C.hours()*S,"h").add(C.minutes()*S,"m").add(C.seconds()*S,"s").add(C.milliseconds()*S,"ms")};return function(N,C,S){n=S,r=S().$utils(),S.duration=function(E,D){var F=S.locale();return p(E,{$l:F},D)},S.isDuration=d;var j=C.prototype.add,g=C.prototype.subtract;C.prototype.add=function(E,D){return d(E)?Y(this,E,1):j.bind(this)(E,D)},C.prototype.subtract=function(E,D){return d(E)?Y(this,E,-1):g.bind(this)(E,D)}}})})(Ua);var zl=Ua.exports;const Yl=zi(zl);Ut.extend(Yl);const Xl=e=>e.toString().padStart(2,"0"),ps=(e,t=Ut().valueOf())=>{const n=Ut(e).valueOf()-t;if(n<=0)return null;const r=Ut.duration(n);return[Math.floor(r.asDays()),r.hours(),r.minutes(),r.seconds()].map(Xl).join(" : ")},ja=(e,t="DD/MM/YYYY")=>Ut(e).format(t),Wl=(e,t,n=Ut().valueOf())=>{if(!t)return null;switch(e){case V.Expired:case V.Forfeited:case V.Completed:return{date:ja(t)};case V.Started:return{label:"startsIn",countdownTime:ps(t,n)};default:return{label:"endsIn",countdownTime:ps(t,n)}}},ql=e=>{switch(e){case V.Started:case V.Awaiting:return"scheduled";case V.InProgress:case V.PendingLevelReward:return"ongoing";case V.Paused:return"paused";case V.Completed:return"completed";case V.Expired:return"expired";case V.Forfeited:return"rejected";default:return e}},Zl=(e,t=!1)=>{const n=ql(e);return t&&n==="scheduled"?"new":n},Va=-1,za=(e,t=[])=>e.Status===V.Started&&(e.LevelProgresses?.[0]?.ProgressPercentage??0)>0||t.includes(e.ChallengeId),vs=(e,t=[])=>e.ChallengeStatus===lr.Paused||t.includes(e.ChallengeId),Jl=(e,t=[])=>{if(e.Status===V.Completed)return 100;if(!(za(e,t)||e.Status===V.PendingLevelReward||e.Status===V.InProgress))return Va;const r=e.LevelProgresses??[],i=r.find(a=>a.ProgressStatus===ot.InProgress);return i?i.ProgressPercentage:r.filter(a=>a.ProgressStatus===ot.Fillup||a.ProgressStatus===ot.Completed).at(-1)?.ProgressPercentage??0},Ya=e=>V[e.Status]??"",Yi=(e,t)=>!!e.Triggers?.includes(t),Xi=e=>Yi(e,wr.Deposit),Xa=e=>!Xi(e)&&Yi(e,wr.ClaimByButton),Ql=e=>!Xi(e)&&!Xa(e)&&Yi(e,wr.GameLaunch),Dr={kind:"viewDetails",labelKey:"viewDetails",variant:"secondary"},Kl={kind:"login",labelKey:"login",variant:"primary"},ef=(e,t={})=>{const{isPromo:n=!1,isPaused:r=!1,isAuthorized:i=!1}=t;if(!i)return Kl;if(r||za(e,[])||e.Status===V.Expired)return Dr;if(n)return Xi(e)?{kind:"deposit",labelKey:"deposit",variant:"primary"}:Xa(e)?{kind:"claim",labelKey:"claim",variant:"primary"}:Ql(e)?{kind:"launchGame",labelKey:"launchGame",variant:"primary"}:Dr;switch(e.Status){case V.Started:return{kind:"optIn",labelKey:"optIn",variant:"primary"};case V.Paused:return{kind:"resume",labelKey:"resume",variant:"accent"};case V.InProgress:case V.PendingLevelReward:return{kind:"pause",labelKey:"pause",variant:"secondary"};default:return Dr}};var tf=function(t){return nf(t)&&!rf(t)};function nf(e){return!!e&&typeof e=="object"}function rf(e){var t=Object.prototype.toString.call(e);return t==="[object RegExp]"||t==="[object Date]"||of(e)}var sf=typeof Symbol=="function"&&Symbol.for,af=sf?Symbol.for("react.element"):60103;function of(e){return e.$$typeof===af}function uf(e){return Array.isArray(e)?[]:{}}function Hn(e,t){return t.clone!==!1&&t.isMergeableObject(e)?fn(uf(e),e,t):e}function lf(e,t,n){return e.concat(t).map(function(r){return Hn(r,n)})}function ff(e,t){if(!t.customMerge)return fn;var n=t.customMerge(e);return typeof n=="function"?n:fn}function cf(e){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(e).filter(function(t){return Object.propertyIsEnumerable.call(e,t)}):[]}function gs(e){return Object.keys(e).concat(cf(e))}function Wa(e,t){try{return t in e}catch{return!1}}function hf(e,t){return Wa(e,t)&&!(Object.hasOwnProperty.call(e,t)&&Object.propertyIsEnumerable.call(e,t))}function df(e,t,n){var r={};return n.isMergeableObject(e)&&gs(e).forEach(function(i){r[i]=Hn(e[i],n)}),gs(t).forEach(function(i){hf(e,i)||(Wa(e,i)&&n.isMergeableObject(t[i])?r[i]=ff(i,n)(e[i],t[i],n):r[i]=Hn(t[i],n))}),r}function fn(e,t,n){n=n||{},n.arrayMerge=n.arrayMerge||lf,n.isMergeableObject=n.isMergeableObject||tf,n.cloneUnlessOtherwiseSpecified=Hn;var r=Array.isArray(t),i=Array.isArray(e),s=r===i;return s?r?n.arrayMerge(e,t,n):df(e,t,n):Hn(t,n)}fn.all=function(t,n){if(!Array.isArray(t))throw new Error("first argument should be an array");return t.reduce(function(r,i){return fn(r,i,n)},{})};var pf=fn,vf=pf;const gf=zi(vf);var ii=function(e,t){return ii=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,r){n.__proto__=r}||function(n,r){for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(n[i]=r[i])},ii(e,t)};function xr(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");ii(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}var nt=function(){return nt=Object.assign||function(t){for(var n,r=1,i=arguments.length;r<i;r++){n=arguments[r];for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(t[s]=n[s])}return t},nt.apply(this,arguments)};function mf(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n}function Br(e,t,n){if(n||arguments.length===2)for(var r=0,i=t.length,s;r<i;r++)(s||!(r in t))&&(s||(s=Array.prototype.slice.call(t,0,r)),s[r]=t[r]);return e.concat(s||Array.prototype.slice.call(t))}function Rr(e,t){var n=t&&t.cache?t.cache:Sf,r=t&&t.serializer?t.serializer:wf,i=t&&t.strategy?t.strategy:yf;return i(e,{cache:n,serializer:r})}function _f(e){return e==null||typeof e=="number"||typeof e=="boolean"}function bf(e,t,n,r){var i=_f(r)?r:n(r),s=t.get(i);return typeof s>"u"&&(s=e.call(this,r),t.set(i,s)),s}function qa(e,t,n){var r=Array.prototype.slice.call(arguments,3),i=n(r),s=t.get(i);return typeof s>"u"&&(s=e.apply(this,r),t.set(i,s)),s}function Za(e,t,n,r,i){return n.bind(t,e,r,i)}function yf(e,t){var n=e.length===1?bf:qa;return Za(e,this,n,t.cache.create(),t.serializer)}function Ef(e,t){return Za(e,this,qa,t.cache.create(),t.serializer)}var wf=function(){return JSON.stringify(arguments)},xf=function(){function e(){this.cache=Object.create(null)}return e.prototype.get=function(t){return this.cache[t]},e.prototype.set=function(t,n){this.cache[t]=n},e}(),Sf={create:function(){return new xf}},Lr={variadic:Ef},cr=function(){return cr=Object.assign||function(t){for(var n,r=1,i=arguments.length;r<i;r++){n=arguments[r];for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(t[s]=n[s])}return t},cr.apply(this,arguments)};var q;(function(e){e[e.EXPECT_ARGUMENT_CLOSING_BRACE=1]="EXPECT_ARGUMENT_CLOSING_BRACE",e[e.EMPTY_ARGUMENT=2]="EMPTY_ARGUMENT",e[e.MALFORMED_ARGUMENT=3]="MALFORMED_ARGUMENT",e[e.EXPECT_ARGUMENT_TYPE=4]="EXPECT_ARGUMENT_TYPE",e[e.INVALID_ARGUMENT_TYPE=5]="INVALID_ARGUMENT_TYPE",e[e.EXPECT_ARGUMENT_STYLE=6]="EXPECT_ARGUMENT_STYLE",e[e.INVALID_NUMBER_SKELETON=7]="INVALID_NUMBER_SKELETON",e[e.INVALID_DATE_TIME_SKELETON=8]="INVALID_DATE_TIME_SKELETON",e[e.EXPECT_NUMBER_SKELETON=9]="EXPECT_NUMBER_SKELETON",e[e.EXPECT_DATE_TIME_SKELETON=10]="EXPECT_DATE_TIME_SKELETON",e[e.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE=11]="UNCLOSED_QUOTE_IN_ARGUMENT_STYLE",e[e.EXPECT_SELECT_ARGUMENT_OPTIONS=12]="EXPECT_SELECT_ARGUMENT_OPTIONS",e[e.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE=13]="EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE",e[e.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE=14]="INVALID_PLURAL_ARGUMENT_OFFSET_VALUE",e[e.EXPECT_SELECT_ARGUMENT_SELECTOR=15]="EXPECT_SELECT_ARGUMENT_SELECTOR",e[e.EXPECT_PLURAL_ARGUMENT_SELECTOR=16]="EXPECT_PLURAL_ARGUMENT_SELECTOR",e[e.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT=17]="EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT",e[e.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT=18]="EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT",e[e.INVALID_PLURAL_ARGUMENT_SELECTOR=19]="INVALID_PLURAL_ARGUMENT_SELECTOR",e[e.DUPLICATE_PLURAL_ARGUMENT_SELECTOR=20]="DUPLICATE_PLURAL_ARGUMENT_SELECTOR",e[e.DUPLICATE_SELECT_ARGUMENT_SELECTOR=21]="DUPLICATE_SELECT_ARGUMENT_SELECTOR",e[e.MISSING_OTHER_CLAUSE=22]="MISSING_OTHER_CLAUSE",e[e.INVALID_TAG=23]="INVALID_TAG",e[e.INVALID_TAG_NAME=25]="INVALID_TAG_NAME",e[e.UNMATCHED_CLOSING_TAG=26]="UNMATCHED_CLOSING_TAG",e[e.UNCLOSED_TAG=27]="UNCLOSED_TAG"})(q||(q={}));var ae;(function(e){e[e.literal=0]="literal",e[e.argument=1]="argument",e[e.number=2]="number",e[e.date=3]="date",e[e.time=4]="time",e[e.select=5]="select",e[e.plural=6]="plural",e[e.pound=7]="pound",e[e.tag=8]="tag"})(ae||(ae={}));var cn;(function(e){e[e.number=0]="number",e[e.dateTime=1]="dateTime"})(cn||(cn={}));function ms(e){return e.type===ae.literal}function Tf(e){return e.type===ae.argument}function Ja(e){return e.type===ae.number}function Qa(e){return e.type===ae.date}function Ka(e){return e.type===ae.time}function eo(e){return e.type===ae.select}function to(e){return e.type===ae.plural}function Cf(e){return e.type===ae.pound}function no(e){return e.type===ae.tag}function ro(e){return!!(e&&typeof e=="object"&&e.type===cn.number)}function si(e){return!!(e&&typeof e=="object"&&e.type===cn.dateTime)}var io=/[ \xA0\u1680\u2000-\u200A\u202F\u205F\u3000]/,Af=/(?:[Eec]{1,6}|G{1,5}|[Qq]{1,5}|(?:[yYur]+|U{1,5})|[ML]{1,5}|d{1,2}|D{1,3}|F{1}|[abB]{1,5}|[hkHK]{1,2}|w{1,2}|W{1}|m{1,2}|s{1,2}|[zZOvVxX]{1,4})(?=([^']*'[^']*')*[^']*$)/g;function If(e){var t={};return e.replace(Af,function(n){var r=n.length;switch(n[0]){case"G":t.era=r===4?"long":r===5?"narrow":"short";break;case"y":t.year=r===2?"2-digit":"numeric";break;case"Y":case"u":case"U":case"r":throw new RangeError("`Y/u/U/r` (year) patterns are not supported, use `y` instead");case"q":case"Q":throw new RangeError("`q/Q` (quarter) patterns are not supported");case"M":case"L":t.month=["numeric","2-digit","short","long","narrow"][r-1];break;case"w":case"W":throw new RangeError("`w/W` (week) patterns are not supported");case"d":t.day=["numeric","2-digit"][r-1];break;case"D":case"F":case"g":throw new RangeError("`D/F/g` (day) patterns are not supported, use `d` instead");case"E":t.weekday=r===4?"long":r===5?"narrow":"short";break;case"e":if(r<4)throw new RangeError("`e..eee` (weekday) patterns are not supported");t.weekday=["short","long","narrow","short"][r-4];break;case"c":if(r<4)throw new RangeError("`c..ccc` (weekday) patterns are not supported");t.weekday=["short","long","narrow","short"][r-4];break;case"a":t.hour12=!0;break;case"b":case"B":throw new RangeError("`b/B` (period) patterns are not supported, use `a` instead");case"h":t.hourCycle="h12",t.hour=["numeric","2-digit"][r-1];break;case"H":t.hourCycle="h23",t.hour=["numeric","2-digit"][r-1];break;case"K":t.hourCycle="h11",t.hour=["numeric","2-digit"][r-1];break;case"k":t.hourCycle="h24",t.hour=["numeric","2-digit"][r-1];break;case"j":case"J":case"C":throw new RangeError("`j/J/C` (hour) patterns are not supported, use `h/H/K/k` instead");case"m":t.minute=["numeric","2-digit"][r-1];break;case"s":t.second=["numeric","2-digit"][r-1];break;case"S":case"A":throw new RangeError("`S/A` (second) patterns are not supported, use `s` instead");case"z":t.timeZoneName=r<4?"short":"long";break;case"Z":case"O":case"v":case"V":case"X":case"x":throw new RangeError("`Z/O/v/V/X/x` (timeZone) patterns are not supported, use `z` instead")}return""}),t}var le=function(){return le=Object.assign||function(t){for(var n,r=1,i=arguments.length;r<i;r++){n=arguments[r];for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(t[s]=n[s])}return t},le.apply(this,arguments)};var Pf=/[\t-\r \x85\u200E\u200F\u2028\u2029]/i;function Of(e){if(e.length===0)throw new Error("Number skeleton cannot be empty");for(var t=e.split(Pf).filter(function(h){return h.length>0}),n=[],r=0,i=t;r<i.length;r++){var s=i[r],a=s.split("/");if(a.length===0)throw new Error("Invalid number skeleton");for(var o=a[0],u=a.slice(1),l=0,f=u;l<f.length;l++){var c=f[l];if(c.length===0)throw new Error("Invalid number skeleton")}n.push({stem:o,options:u})}return n}function $f(e){return e.replace(/^(.*?)-/,"")}var _s=/^\.(?:(0+)(\*)?|(#+)|(0+)(#+))$/g,so=/^(@+)?(\+|#+)?[rs]?$/g,Nf=/(\*)(0+)|(#+)(0+)|(0+)/g,ao=/^(0+)$/;function bs(e){var t={};return e[e.length-1]==="r"?t.roundingPriority="morePrecision":e[e.length-1]==="s"&&(t.roundingPriority="lessPrecision"),e.replace(so,function(n,r,i){return typeof i!="string"?(t.minimumSignificantDigits=r.length,t.maximumSignificantDigits=r.length):i==="+"?t.minimumSignificantDigits=r.length:r[0]==="#"?t.maximumSignificantDigits=r.length:(t.minimumSignificantDigits=r.length,t.maximumSignificantDigits=r.length+(typeof i=="string"?i.length:0)),""}),t}function oo(e){switch(e){case"sign-auto":return{signDisplay:"auto"};case"sign-accounting":case"()":return{currencySign:"accounting"};case"sign-always":case"+!":return{signDisplay:"always"};case"sign-accounting-always":case"()!":return{signDisplay:"always",currencySign:"accounting"};case"sign-except-zero":case"+?":return{signDisplay:"exceptZero"};case"sign-accounting-except-zero":case"()?":return{signDisplay:"exceptZero",currencySign:"accounting"};case"sign-never":case"+_":return{signDisplay:"never"}}}function Mf(e){var t;if(e[0]==="E"&&e[1]==="E"?(t={notation:"engineering"},e=e.slice(2)):e[0]==="E"&&(t={notation:"scientific"},e=e.slice(1)),t){var n=e.slice(0,2);if(n==="+!"?(t.signDisplay="always",e=e.slice(2)):n==="+?"&&(t.signDisplay="exceptZero",e=e.slice(2)),!ao.test(e))throw new Error("Malformed concise eng/scientific notation");t.minimumIntegerDigits=e.length}return t}function ys(e){var t={},n=oo(e);return n||t}function Hf(e){for(var t={},n=0,r=e;n<r.length;n++){var i=r[n];switch(i.stem){case"percent":case"%":t.style="percent";continue;case"%x100":t.style="percent",t.scale=100;continue;case"currency":t.style="currency",t.currency=i.options[0];continue;case"group-off":case",_":t.useGrouping=!1;continue;case"precision-integer":case".":t.maximumFractionDigits=0;continue;case"measure-unit":case"unit":t.style="unit",t.unit=$f(i.options[0]);continue;case"compact-short":case"K":t.notation="compact",t.compactDisplay="short";continue;case"compact-long":case"KK":t.notation="compact",t.compactDisplay="long";continue;case"scientific":t=le(le(le({},t),{notation:"scientific"}),i.options.reduce(function(u,l){return le(le({},u),ys(l))},{}));continue;case"engineering":t=le(le(le({},t),{notation:"engineering"}),i.options.reduce(function(u,l){return le(le({},u),ys(l))},{}));continue;case"notation-simple":t.notation="standard";continue;case"unit-width-narrow":t.currencyDisplay="narrowSymbol",t.unitDisplay="narrow";continue;case"unit-width-short":t.currencyDisplay="code",t.unitDisplay="short";continue;case"unit-width-full-name":t.currencyDisplay="name",t.unitDisplay="long";continue;case"unit-width-iso-code":t.currencyDisplay="symbol";continue;case"scale":t.scale=parseFloat(i.options[0]);continue;case"rounding-mode-floor":t.roundingMode="floor";continue;case"rounding-mode-ceiling":t.roundingMode="ceil";continue;case"rounding-mode-down":t.roundingMode="trunc";continue;case"rounding-mode-up":t.roundingMode="expand";continue;case"rounding-mode-half-even":t.roundingMode="halfEven";continue;case"rounding-mode-half-down":t.roundingMode="halfTrunc";continue;case"rounding-mode-half-up":t.roundingMode="halfExpand";continue;case"integer-width":if(i.options.length>1)throw new RangeError("integer-width stems only accept a single optional option");i.options[0].replace(Nf,function(u,l,f,c,h,d){if(l)t.minimumIntegerDigits=f.length;else{if(c&&h)throw new Error("We currently do not support maximum integer digits");if(d)throw new Error("We currently do not support exact integer digits")}return""});continue}if(ao.test(i.stem)){t.minimumIntegerDigits=i.stem.length;continue}if(_s.test(i.stem)){if(i.options.length>1)throw new RangeError("Fraction-precision stems only accept a single optional option");i.stem.replace(_s,function(u,l,f,c,h,d){return f==="*"?t.minimumFractionDigits=l.length:c&&c[0]==="#"?t.maximumFractionDigits=c.length:h&&d?(t.minimumFractionDigits=h.length,t.maximumFractionDigits=h.length+d.length):(t.minimumFractionDigits=l.length,t.maximumFractionDigits=l.length),""});var s=i.options[0];s==="w"?t=le(le({},t),{trailingZeroDisplay:"stripIfInteger"}):s&&(t=le(le({},t),bs(s)));continue}if(so.test(i.stem)){t=le(le({},t),bs(i.stem));continue}var a=oo(i.stem);a&&(t=le(le({},t),a));var o=Mf(i.stem);o&&(t=le(le({},t),o))}return t}var Yn={"001":["H","h"],419:["h","H","hB","hb"],AC:["H","h","hb","hB"],AD:["H","hB"],AE:["h","hB","hb","H"],AF:["H","hb","hB","h"],AG:["h","hb","H","hB"],AI:["H","h","hb","hB"],AL:["h","H","hB"],AM:["H","hB"],AO:["H","hB"],AR:["h","H","hB","hb"],AS:["h","H"],AT:["H","hB"],AU:["h","hb","H","hB"],AW:["H","hB"],AX:["H"],AZ:["H","hB","h"],BA:["H","hB","h"],BB:["h","hb","H","hB"],BD:["h","hB","H"],BE:["H","hB"],BF:["H","hB"],BG:["H","hB","h"],BH:["h","hB","hb","H"],BI:["H","h"],BJ:["H","hB"],BL:["H","hB"],BM:["h","hb","H","hB"],BN:["hb","hB","h","H"],BO:["h","H","hB","hb"],BQ:["H"],BR:["H","hB"],BS:["h","hb","H","hB"],BT:["h","H"],BW:["H","h","hb","hB"],BY:["H","h"],BZ:["H","h","hb","hB"],CA:["h","hb","H","hB"],CC:["H","h","hb","hB"],CD:["hB","H"],CF:["H","h","hB"],CG:["H","hB"],CH:["H","hB","h"],CI:["H","hB"],CK:["H","h","hb","hB"],CL:["h","H","hB","hb"],CM:["H","h","hB"],CN:["H","hB","hb","h"],CO:["h","H","hB","hb"],CP:["H"],CR:["h","H","hB","hb"],CU:["h","H","hB","hb"],CV:["H","hB"],CW:["H","hB"],CX:["H","h","hb","hB"],CY:["h","H","hb","hB"],CZ:["H"],DE:["H","hB"],DG:["H","h","hb","hB"],DJ:["h","H"],DK:["H"],DM:["h","hb","H","hB"],DO:["h","H","hB","hb"],DZ:["h","hB","hb","H"],EA:["H","h","hB","hb"],EC:["h","H","hB","hb"],EE:["H","hB"],EG:["h","hB","hb","H"],EH:["h","hB","hb","H"],ER:["h","H"],ES:["H","hB","h","hb"],ET:["hB","hb","h","H"],FI:["H"],FJ:["h","hb","H","hB"],FK:["H","h","hb","hB"],FM:["h","hb","H","hB"],FO:["H","h"],FR:["H","hB"],GA:["H","hB"],GB:["H","h","hb","hB"],GD:["h","hb","H","hB"],GE:["H","hB","h"],GF:["H","hB"],GG:["H","h","hb","hB"],GH:["h","H"],GI:["H","h","hb","hB"],GL:["H","h"],GM:["h","hb","H","hB"],GN:["H","hB"],GP:["H","hB"],GQ:["H","hB","h","hb"],GR:["h","H","hb","hB"],GT:["h","H","hB","hb"],GU:["h","hb","H","hB"],GW:["H","hB"],GY:["h","hb","H","hB"],HK:["h","hB","hb","H"],HN:["h","H","hB","hb"],HR:["H","hB"],HU:["H","h"],IC:["H","h","hB","hb"],ID:["H"],IE:["H","h","hb","hB"],IL:["H","hB"],IM:["H","h","hb","hB"],IN:["h","H"],IO:["H","h","hb","hB"],IQ:["h","hB","hb","H"],IR:["hB","H"],IS:["H"],IT:["H","hB"],JE:["H","h","hb","hB"],JM:["h","hb","H","hB"],JO:["h","hB","hb","H"],JP:["H","K","h"],KE:["hB","hb","H","h"],KG:["H","h","hB","hb"],KH:["hB","h","H","hb"],KI:["h","hb","H","hB"],KM:["H","h","hB","hb"],KN:["h","hb","H","hB"],KP:["h","H","hB","hb"],KR:["h","H","hB","hb"],KW:["h","hB","hb","H"],KY:["h","hb","H","hB"],KZ:["H","hB"],LA:["H","hb","hB","h"],LB:["h","hB","hb","H"],LC:["h","hb","H","hB"],LI:["H","hB","h"],LK:["H","h","hB","hb"],LR:["h","hb","H","hB"],LS:["h","H"],LT:["H","h","hb","hB"],LU:["H","h","hB"],LV:["H","hB","hb","h"],LY:["h","hB","hb","H"],MA:["H","h","hB","hb"],MC:["H","hB"],MD:["H","hB"],ME:["H","hB","h"],MF:["H","hB"],MG:["H","h"],MH:["h","hb","H","hB"],MK:["H","h","hb","hB"],ML:["H"],MM:["hB","hb","H","h"],MN:["H","h","hb","hB"],MO:["h","hB","hb","H"],MP:["h","hb","H","hB"],MQ:["H","hB"],MR:["h","hB","hb","H"],MS:["H","h","hb","hB"],MT:["H","h"],MU:["H","h"],MV:["H","h"],MW:["h","hb","H","hB"],MX:["h","H","hB","hb"],MY:["hb","hB","h","H"],MZ:["H","hB"],NA:["h","H","hB","hb"],NC:["H","hB"],NE:["H"],NF:["H","h","hb","hB"],NG:["H","h","hb","hB"],NI:["h","H","hB","hb"],NL:["H","hB"],NO:["H","h"],NP:["H","h","hB"],NR:["H","h","hb","hB"],NU:["H","h","hb","hB"],NZ:["h","hb","H","hB"],OM:["h","hB","hb","H"],PA:["h","H","hB","hb"],PE:["h","H","hB","hb"],PF:["H","h","hB"],PG:["h","H"],PH:["h","hB","hb","H"],PK:["h","hB","H"],PL:["H","h"],PM:["H","hB"],PN:["H","h","hb","hB"],PR:["h","H","hB","hb"],PS:["h","hB","hb","H"],PT:["H","hB"],PW:["h","H"],PY:["h","H","hB","hb"],QA:["h","hB","hb","H"],RE:["H","hB"],RO:["H","hB"],RS:["H","hB","h"],RU:["H"],RW:["H","h"],SA:["h","hB","hb","H"],SB:["h","hb","H","hB"],SC:["H","h","hB"],SD:["h","hB","hb","H"],SE:["H"],SG:["h","hb","H","hB"],SH:["H","h","hb","hB"],SI:["H","hB"],SJ:["H"],SK:["H"],SL:["h","hb","H","hB"],SM:["H","h","hB"],SN:["H","h","hB"],SO:["h","H"],SR:["H","hB"],SS:["h","hb","H","hB"],ST:["H","hB"],SV:["h","H","hB","hb"],SX:["H","h","hb","hB"],SY:["h","hB","hb","H"],SZ:["h","hb","H","hB"],TA:["H","h","hb","hB"],TC:["h","hb","H","hB"],TD:["h","H","hB"],TF:["H","h","hB"],TG:["H","hB"],TH:["H","h"],TJ:["H","h"],TL:["H","hB","hb","h"],TM:["H","h"],TN:["h","hB","hb","H"],TO:["h","H"],TR:["H","hB"],TT:["h","hb","H","hB"],TW:["hB","hb","h","H"],TZ:["hB","hb","H","h"],UA:["H","hB","h"],UG:["hB","hb","H","h"],UM:["h","hb","H","hB"],US:["h","hb","H","hB"],UY:["h","H","hB","hb"],UZ:["H","hB","h"],VA:["H","h","hB"],VC:["h","hb","H","hB"],VE:["h","H","hB","hb"],VG:["h","hb","H","hB"],VI:["h","hb","H","hB"],VN:["H","h"],VU:["h","H"],WF:["H","hB"],WS:["h","H"],XK:["H","hB","h"],YE:["h","hB","hb","H"],YT:["H","hB"],ZA:["H","h","hb","hB"],ZM:["h","hb","H","hB"],ZW:["H","h"],"af-ZA":["H","h","hB","hb"],"ar-001":["h","hB","hb","H"],"ca-ES":["H","h","hB"],"en-001":["h","hb","H","hB"],"en-HK":["h","hb","H","hB"],"en-IL":["H","h","hb","hB"],"en-MY":["h","hb","H","hB"],"es-BR":["H","h","hB","hb"],"es-ES":["H","h","hB","hb"],"es-GQ":["H","h","hB","hb"],"fr-CA":["H","h","hB"],"gl-ES":["H","h","hB"],"gu-IN":["hB","hb","h","H"],"hi-IN":["hB","h","H"],"it-CH":["H","h","hB"],"it-IT":["H","h","hB"],"kn-IN":["hB","h","H"],"ml-IN":["hB","h","H"],"mr-IN":["hB","hb","h","H"],"pa-IN":["hB","hb","h","H"],"ta-IN":["hB","h","hb","H"],"te-IN":["hB","h","H"],"zu-ZA":["H","hB","hb","h"]};function Df(e,t){for(var n="",r=0;r<e.length;r++){var i=e.charAt(r);if(i==="j"){for(var s=0;r+1<e.length&&e.charAt(r+1)===i;)s++,r++;var a=1+(s&1),o=s<2?1:3+(s>>1),u="a",l=Bf(t);for((l=="H"||l=="k")&&(o=0);o-- >0;)n+=u;for(;a-- >0;)n=l+n}else i==="J"?n+="H":n+=i}return n}function Bf(e){var t=e.hourCycle;if(t===void 0&&e.hourCycles&&e.hourCycles.length&&(t=e.hourCycles[0]),t)switch(t){case"h24":return"k";case"h23":return"H";case"h12":return"h";case"h11":return"K";default:throw new Error("Invalid hourCycle")}var n=e.language,r;n!=="root"&&(r=e.maximize().region);var i=Yn[r||""]||Yn[n||""]||Yn["".concat(n,"-001")]||Yn["001"];return i[0]}var Fr,Rf=new RegExp("^".concat(io.source,"*")),Lf=new RegExp("".concat(io.source,"*$"));function Q(e,t){return{start:e,end:t}}var Ff=!!String.prototype.startsWith&&"_a".startsWith("a",1),kf=!!String.fromCodePoint,Gf=!!Object.fromEntries,Uf=!!String.prototype.codePointAt,jf=!!String.prototype.trimStart,Vf=!!String.prototype.trimEnd,zf=!!Number.isSafeInteger,Yf=zf?Number.isSafeInteger:function(e){return typeof e=="number"&&isFinite(e)&&Math.floor(e)===e&&Math.abs(e)<=9007199254740991},ai=!0;try{var Xf=lo("([^\\p{White_Space}\\p{Pattern_Syntax}]*)","yu");ai=((Fr=Xf.exec("a"))===null||Fr===void 0?void 0:Fr[0])==="a"}catch{ai=!1}var Es=Ff?function(t,n,r){return t.startsWith(n,r)}:function(t,n,r){return t.slice(r,r+n.length)===n},oi=kf?String.fromCodePoint:function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];for(var r="",i=t.length,s=0,a;i>s;){if(a=t[s++],a>1114111)throw RangeError(a+" is not a valid code point");r+=a<65536?String.fromCharCode(a):String.fromCharCode(((a-=65536)>>10)+55296,a%1024+56320)}return r},ws=Gf?Object.fromEntries:function(t){for(var n={},r=0,i=t;r<i.length;r++){var s=i[r],a=s[0],o=s[1];n[a]=o}return n},uo=Uf?function(t,n){return t.codePointAt(n)}:function(t,n){var r=t.length;if(!(n<0||n>=r)){var i=t.charCodeAt(n),s;return i<55296||i>56319||n+1===r||(s=t.charCodeAt(n+1))<56320||s>57343?i:(i-55296<<10)+(s-56320)+65536}},Wf=jf?function(t){return t.trimStart()}:function(t){return t.replace(Rf,"")},qf=Vf?function(t){return t.trimEnd()}:function(t){return t.replace(Lf,"")};function lo(e,t){return new RegExp(e,t)}var ui;if(ai){var xs=lo("([^\\p{White_Space}\\p{Pattern_Syntax}]*)","yu");ui=function(t,n){var r;xs.lastIndex=n;var i=xs.exec(t);return(r=i[1])!==null&&r!==void 0?r:""}}else ui=function(t,n){for(var r=[];;){var i=uo(t,n);if(i===void 0||fo(i)||Kf(i))break;r.push(i),n+=i>=65536?2:1}return oi.apply(void 0,r)};var Zf=function(){function e(t,n){n===void 0&&(n={}),this.message=t,this.position={offset:0,line:1,column:1},this.ignoreTag=!!n.ignoreTag,this.locale=n.locale,this.requiresOtherClause=!!n.requiresOtherClause,this.shouldParseSkeletons=!!n.shouldParseSkeletons}return e.prototype.parse=function(){if(this.offset()!==0)throw Error("parser can only be used once");return this.parseMessage(0,"",!1)},e.prototype.parseMessage=function(t,n,r){for(var i=[];!this.isEOF();){var s=this.char();if(s===123){var a=this.parseArgument(t,r);if(a.err)return a;i.push(a.val)}else{if(s===125&&t>0)break;if(s===35&&(n==="plural"||n==="selectordinal")){var o=this.clonePosition();this.bump(),i.push({type:ae.pound,location:Q(o,this.clonePosition())})}else if(s===60&&!this.ignoreTag&&this.peek()===47){if(r)break;return this.error(q.UNMATCHED_CLOSING_TAG,Q(this.clonePosition(),this.clonePosition()))}else if(s===60&&!this.ignoreTag&&li(this.peek()||0)){var a=this.parseTag(t,n);if(a.err)return a;i.push(a.val)}else{var a=this.parseLiteral(t,n);if(a.err)return a;i.push(a.val)}}}return{val:i,err:null}},e.prototype.parseTag=function(t,n){var r=this.clonePosition();this.bump();var i=this.parseTagName();if(this.bumpSpace(),this.bumpIf("/>"))return{val:{type:ae.literal,value:"<".concat(i,"/>"),location:Q(r,this.clonePosition())},err:null};if(this.bumpIf(">")){var s=this.parseMessage(t+1,n,!0);if(s.err)return s;var a=s.val,o=this.clonePosition();if(this.bumpIf("</")){if(this.isEOF()||!li(this.char()))return this.error(q.INVALID_TAG,Q(o,this.clonePosition()));var u=this.clonePosition(),l=this.parseTagName();return i!==l?this.error(q.UNMATCHED_CLOSING_TAG,Q(u,this.clonePosition())):(this.bumpSpace(),this.bumpIf(">")?{val:{type:ae.tag,value:i,children:a,location:Q(r,this.clonePosition())},err:null}:this.error(q.INVALID_TAG,Q(o,this.clonePosition())))}else return this.error(q.UNCLOSED_TAG,Q(r,this.clonePosition()))}else return this.error(q.INVALID_TAG,Q(r,this.clonePosition()))},e.prototype.parseTagName=function(){var t=this.offset();for(this.bump();!this.isEOF()&&Qf(this.char());)this.bump();return this.message.slice(t,this.offset())},e.prototype.parseLiteral=function(t,n){for(var r=this.clonePosition(),i="";;){var s=this.tryParseQuote(n);if(s){i+=s;continue}var a=this.tryParseUnquoted(t,n);if(a){i+=a;continue}var o=this.tryParseLeftAngleBracket();if(o){i+=o;continue}break}var u=Q(r,this.clonePosition());return{val:{type:ae.literal,value:i,location:u},err:null}},e.prototype.tryParseLeftAngleBracket=function(){return!this.isEOF()&&this.char()===60&&(this.ignoreTag||!Jf(this.peek()||0))?(this.bump(),"<"):null},e.prototype.tryParseQuote=function(t){if(this.isEOF()||this.char()!==39)return null;switch(this.peek()){case 39:return this.bump(),this.bump(),"'";case 123:case 60:case 62:case 125:break;case 35:if(t==="plural"||t==="selectordinal")break;return null;default:return null}this.bump();var n=[this.char()];for(this.bump();!this.isEOF();){var r=this.char();if(r===39)if(this.peek()===39)n.push(39),this.bump();else{this.bump();break}else n.push(r);this.bump()}return oi.apply(void 0,n)},e.prototype.tryParseUnquoted=function(t,n){if(this.isEOF())return null;var r=this.char();return r===60||r===123||r===35&&(n==="plural"||n==="selectordinal")||r===125&&t>0?null:(this.bump(),oi(r))},e.prototype.parseArgument=function(t,n){var r=this.clonePosition();if(this.bump(),this.bumpSpace(),this.isEOF())return this.error(q.EXPECT_ARGUMENT_CLOSING_BRACE,Q(r,this.clonePosition()));if(this.char()===125)return this.bump(),this.error(q.EMPTY_ARGUMENT,Q(r,this.clonePosition()));var i=this.parseIdentifierIfPossible().value;if(!i)return this.error(q.MALFORMED_ARGUMENT,Q(r,this.clonePosition()));if(this.bumpSpace(),this.isEOF())return this.error(q.EXPECT_ARGUMENT_CLOSING_BRACE,Q(r,this.clonePosition()));switch(this.char()){case 125:return this.bump(),{val:{type:ae.argument,value:i,location:Q(r,this.clonePosition())},err:null};case 44:return this.bump(),this.bumpSpace(),this.isEOF()?this.error(q.EXPECT_ARGUMENT_CLOSING_BRACE,Q(r,this.clonePosition())):this.parseArgumentOptions(t,n,i,r);default:return this.error(q.MALFORMED_ARGUMENT,Q(r,this.clonePosition()))}},e.prototype.parseIdentifierIfPossible=function(){var t=this.clonePosition(),n=this.offset(),r=ui(this.message,n),i=n+r.length;this.bumpTo(i);var s=this.clonePosition(),a=Q(t,s);return{value:r,location:a}},e.prototype.parseArgumentOptions=function(t,n,r,i){var s,a=this.clonePosition(),o=this.parseIdentifierIfPossible().value,u=this.clonePosition();switch(o){case"":return this.error(q.EXPECT_ARGUMENT_TYPE,Q(a,u));case"number":case"date":case"time":{this.bumpSpace();var l=null;if(this.bumpIf(",")){this.bumpSpace();var f=this.clonePosition(),c=this.parseSimpleArgStyleIfPossible();if(c.err)return c;var h=qf(c.val);if(h.length===0)return this.error(q.EXPECT_ARGUMENT_STYLE,Q(this.clonePosition(),this.clonePosition()));var d=Q(f,this.clonePosition());l={style:h,styleLocation:d}}var p=this.tryParseArgumentClose(i);if(p.err)return p;var y=Q(i,this.clonePosition());if(l&&Es(l?.style,"::",0)){var _=Wf(l.style.slice(2));if(o==="number"){var c=this.parseNumberSkeletonFromString(_,l.styleLocation);return c.err?c:{val:{type:ae.number,value:r,location:y,style:c.val},err:null}}else{if(_.length===0)return this.error(q.EXPECT_DATE_TIME_SKELETON,y);var P=_;this.locale&&(P=Df(_,this.locale));var h={type:cn.dateTime,pattern:P,location:l.styleLocation,parsedOptions:this.shouldParseSkeletons?If(P):{}},L=o==="date"?ae.date:ae.time;return{val:{type:L,value:r,location:y,style:h},err:null}}}return{val:{type:o==="number"?ae.number:o==="date"?ae.date:ae.time,value:r,location:y,style:(s=l?.style)!==null&&s!==void 0?s:null},err:null}}case"plural":case"selectordinal":case"select":{var M=this.clonePosition();if(this.bumpSpace(),!this.bumpIf(","))return this.error(q.EXPECT_SELECT_ARGUMENT_OPTIONS,Q(M,cr({},M)));this.bumpSpace();var R=this.parseIdentifierIfPossible(),Y=0;if(o!=="select"&&R.value==="offset"){if(!this.bumpIf(":"))return this.error(q.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE,Q(this.clonePosition(),this.clonePosition()));this.bumpSpace();var c=this.tryParseDecimalInteger(q.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE,q.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE);if(c.err)return c;this.bumpSpace(),R=this.parseIdentifierIfPossible(),Y=c.val}var N=this.tryParsePluralOrSelectOptions(t,o,n,R);if(N.err)return N;var p=this.tryParseArgumentClose(i);if(p.err)return p;var C=Q(i,this.clonePosition());return o==="select"?{val:{type:ae.select,value:r,options:ws(N.val),location:C},err:null}:{val:{type:ae.plural,value:r,options:ws(N.val),offset:Y,pluralType:o==="plural"?"cardinal":"ordinal",location:C},err:null}}default:return this.error(q.INVALID_ARGUMENT_TYPE,Q(a,u))}},e.prototype.tryParseArgumentClose=function(t){return this.isEOF()||this.char()!==125?this.error(q.EXPECT_ARGUMENT_CLOSING_BRACE,Q(t,this.clonePosition())):(this.bump(),{val:!0,err:null})},e.prototype.parseSimpleArgStyleIfPossible=function(){for(var t=0,n=this.clonePosition();!this.isEOF();){var r=this.char();switch(r){case 39:{this.bump();var i=this.clonePosition();if(!this.bumpUntil("'"))return this.error(q.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE,Q(i,this.clonePosition()));this.bump();break}case 123:{t+=1,this.bump();break}case 125:{if(t>0)t-=1;else return{val:this.message.slice(n.offset,this.offset()),err:null};break}default:this.bump();break}}return{val:this.message.slice(n.offset,this.offset()),err:null}},e.prototype.parseNumberSkeletonFromString=function(t,n){var r=[];try{r=Of(t)}catch{return this.error(q.INVALID_NUMBER_SKELETON,n)}return{val:{type:cn.number,tokens:r,location:n,parsedOptions:this.shouldParseSkeletons?Hf(r):{}},err:null}},e.prototype.tryParsePluralOrSelectOptions=function(t,n,r,i){for(var s,a=!1,o=[],u=new Set,l=i.value,f=i.location;;){if(l.length===0){var c=this.clonePosition();if(n!=="select"&&this.bumpIf("=")){var h=this.tryParseDecimalInteger(q.EXPECT_PLURAL_ARGUMENT_SELECTOR,q.INVALID_PLURAL_ARGUMENT_SELECTOR);if(h.err)return h;f=Q(c,this.clonePosition()),l=this.message.slice(c.offset,this.offset())}else break}if(u.has(l))return this.error(n==="select"?q.DUPLICATE_SELECT_ARGUMENT_SELECTOR:q.DUPLICATE_PLURAL_ARGUMENT_SELECTOR,f);l==="other"&&(a=!0),this.bumpSpace();var d=this.clonePosition();if(!this.bumpIf("{"))return this.error(n==="select"?q.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT:q.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT,Q(this.clonePosition(),this.clonePosition()));var p=this.parseMessage(t+1,n,r);if(p.err)return p;var y=this.tryParseArgumentClose(d);if(y.err)return y;o.push([l,{value:p.val,location:Q(d,this.clonePosition())}]),u.add(l),this.bumpSpace(),s=this.parseIdentifierIfPossible(),l=s.value,f=s.location}return o.length===0?this.error(n==="select"?q.EXPECT_SELECT_ARGUMENT_SELECTOR:q.EXPECT_PLURAL_ARGUMENT_SELECTOR,Q(this.clonePosition(),this.clonePosition())):this.requiresOtherClause&&!a?this.error(q.MISSING_OTHER_CLAUSE,Q(this.clonePosition(),this.clonePosition())):{val:o,err:null}},e.prototype.tryParseDecimalInteger=function(t,n){var r=1,i=this.clonePosition();this.bumpIf("+")||this.bumpIf("-")&&(r=-1);for(var s=!1,a=0;!this.isEOF();){var o=this.char();if(o>=48&&o<=57)s=!0,a=a*10+(o-48),this.bump();else break}var u=Q(i,this.clonePosition());return s?(a*=r,Yf(a)?{val:a,err:null}:this.error(n,u)):this.error(t,u)},e.prototype.offset=function(){return this.position.offset},e.prototype.isEOF=function(){return this.offset()===this.message.length},e.prototype.clonePosition=function(){return{offset:this.position.offset,line:this.position.line,column:this.position.column}},e.prototype.char=function(){var t=this.position.offset;if(t>=this.message.length)throw Error("out of bound");var n=uo(this.message,t);if(n===void 0)throw Error("Offset ".concat(t," is at invalid UTF-16 code unit boundary"));return n},e.prototype.error=function(t,n){return{val:null,err:{kind:t,message:this.message,location:n}}},e.prototype.bump=function(){if(!this.isEOF()){var t=this.char();t===10?(this.position.line+=1,this.position.column=1,this.position.offset+=1):(this.position.column+=1,this.position.offset+=t<65536?1:2)}},e.prototype.bumpIf=function(t){if(Es(this.message,t,this.offset())){for(var n=0;n<t.length;n++)this.bump();return!0}return!1},e.prototype.bumpUntil=function(t){var n=this.offset(),r=this.message.indexOf(t,n);return r>=0?(this.bumpTo(r),!0):(this.bumpTo(this.message.length),!1)},e.prototype.bumpTo=function(t){if(this.offset()>t)throw Error("targetOffset ".concat(t," must be greater than or equal to the current offset ").concat(this.offset()));for(t=Math.min(t,this.message.length);;){var n=this.offset();if(n===t)break;if(n>t)throw Error("targetOffset ".concat(t," is at invalid UTF-16 code unit boundary"));if(this.bump(),this.isEOF())break}},e.prototype.bumpSpace=function(){for(;!this.isEOF()&&fo(this.char());)this.bump()},e.prototype.peek=function(){if(this.isEOF())return null;var t=this.char(),n=this.offset(),r=this.message.charCodeAt(n+(t>=65536?2:1));return r??null},e}();function li(e){return e>=97&&e<=122||e>=65&&e<=90}function Jf(e){return li(e)||e===47}function Qf(e){return e===45||e===46||e>=48&&e<=57||e===95||e>=97&&e<=122||e>=65&&e<=90||e==183||e>=192&&e<=214||e>=216&&e<=246||e>=248&&e<=893||e>=895&&e<=8191||e>=8204&&e<=8205||e>=8255&&e<=8256||e>=8304&&e<=8591||e>=11264&&e<=12271||e>=12289&&e<=55295||e>=63744&&e<=64975||e>=65008&&e<=65533||e>=65536&&e<=983039}function fo(e){return e>=9&&e<=13||e===32||e===133||e>=8206&&e<=8207||e===8232||e===8233}function Kf(e){return e>=33&&e<=35||e===36||e>=37&&e<=39||e===40||e===41||e===42||e===43||e===44||e===45||e>=46&&e<=47||e>=58&&e<=59||e>=60&&e<=62||e>=63&&e<=64||e===91||e===92||e===93||e===94||e===96||e===123||e===124||e===125||e===126||e===161||e>=162&&e<=165||e===166||e===167||e===169||e===171||e===172||e===174||e===176||e===177||e===182||e===187||e===191||e===215||e===247||e>=8208&&e<=8213||e>=8214&&e<=8215||e===8216||e===8217||e===8218||e>=8219&&e<=8220||e===8221||e===8222||e===8223||e>=8224&&e<=8231||e>=8240&&e<=8248||e===8249||e===8250||e>=8251&&e<=8254||e>=8257&&e<=8259||e===8260||e===8261||e===8262||e>=8263&&e<=8273||e===8274||e===8275||e>=8277&&e<=8286||e>=8592&&e<=8596||e>=8597&&e<=8601||e>=8602&&e<=8603||e>=8604&&e<=8607||e===8608||e>=8609&&e<=8610||e===8611||e>=8612&&e<=8613||e===8614||e>=8615&&e<=8621||e===8622||e>=8623&&e<=8653||e>=8654&&e<=8655||e>=8656&&e<=8657||e===8658||e===8659||e===8660||e>=8661&&e<=8691||e>=8692&&e<=8959||e>=8960&&e<=8967||e===8968||e===8969||e===8970||e===8971||e>=8972&&e<=8991||e>=8992&&e<=8993||e>=8994&&e<=9e3||e===9001||e===9002||e>=9003&&e<=9083||e===9084||e>=9085&&e<=9114||e>=9115&&e<=9139||e>=9140&&e<=9179||e>=9180&&e<=9185||e>=9186&&e<=9254||e>=9255&&e<=9279||e>=9280&&e<=9290||e>=9291&&e<=9311||e>=9472&&e<=9654||e===9655||e>=9656&&e<=9664||e===9665||e>=9666&&e<=9719||e>=9720&&e<=9727||e>=9728&&e<=9838||e===9839||e>=9840&&e<=10087||e===10088||e===10089||e===10090||e===10091||e===10092||e===10093||e===10094||e===10095||e===10096||e===10097||e===10098||e===10099||e===10100||e===10101||e>=10132&&e<=10175||e>=10176&&e<=10180||e===10181||e===10182||e>=10183&&e<=10213||e===10214||e===10215||e===10216||e===10217||e===10218||e===10219||e===10220||e===10221||e===10222||e===10223||e>=10224&&e<=10239||e>=10240&&e<=10495||e>=10496&&e<=10626||e===10627||e===10628||e===10629||e===10630||e===10631||e===10632||e===10633||e===10634||e===10635||e===10636||e===10637||e===10638||e===10639||e===10640||e===10641||e===10642||e===10643||e===10644||e===10645||e===10646||e===10647||e===10648||e>=10649&&e<=10711||e===10712||e===10713||e===10714||e===10715||e>=10716&&e<=10747||e===10748||e===10749||e>=10750&&e<=11007||e>=11008&&e<=11055||e>=11056&&e<=11076||e>=11077&&e<=11078||e>=11079&&e<=11084||e>=11085&&e<=11123||e>=11124&&e<=11125||e>=11126&&e<=11157||e===11158||e>=11159&&e<=11263||e>=11776&&e<=11777||e===11778||e===11779||e===11780||e===11781||e>=11782&&e<=11784||e===11785||e===11786||e===11787||e===11788||e===11789||e>=11790&&e<=11798||e===11799||e>=11800&&e<=11801||e===11802||e===11803||e===11804||e===11805||e>=11806&&e<=11807||e===11808||e===11809||e===11810||e===11811||e===11812||e===11813||e===11814||e===11815||e===11816||e===11817||e>=11818&&e<=11822||e===11823||e>=11824&&e<=11833||e>=11834&&e<=11835||e>=11836&&e<=11839||e===11840||e===11841||e===11842||e>=11843&&e<=11855||e>=11856&&e<=11857||e===11858||e>=11859&&e<=11903||e>=12289&&e<=12291||e===12296||e===12297||e===12298||e===12299||e===12300||e===12301||e===12302||e===12303||e===12304||e===12305||e>=12306&&e<=12307||e===12308||e===12309||e===12310||e===12311||e===12312||e===12313||e===12314||e===12315||e===12316||e===12317||e>=12318&&e<=12319||e===12320||e===12336||e===64830||e===64831||e>=65093&&e<=65094}function fi(e){e.forEach(function(t){if(delete t.location,eo(t)||to(t))for(var n in t.options)delete t.options[n].location,fi(t.options[n].value);else Ja(t)&&ro(t.style)||(Qa(t)||Ka(t))&&si(t.style)?delete t.style.location:no(t)&&fi(t.children)})}function ec(e,t){t===void 0&&(t={}),t=cr({shouldParseSkeletons:!0,requiresOtherClause:!0},t);var n=new Zf(e,t).parse();if(n.err){var r=SyntaxError(q[n.err.kind]);throw r.location=n.err.location,r.originalMessage=n.err.message,r}return t?.captureLocation||fi(n.val),n.val}var hn;(function(e){e.MISSING_VALUE="MISSING_VALUE",e.INVALID_VALUE="INVALID_VALUE",e.MISSING_INTL_API="MISSING_INTL_API"})(hn||(hn={}));var Sr=function(e){xr(t,e);function t(n,r,i){var s=e.call(this,n)||this;return s.code=r,s.originalMessage=i,s}return t.prototype.toString=function(){return"[formatjs Error: ".concat(this.code,"] ").concat(this.message)},t}(Error),Ss=function(e){xr(t,e);function t(n,r,i,s){return e.call(this,'Invalid values for "'.concat(n,'": "').concat(r,'". Options are "').concat(Object.keys(i).join('", "'),'"'),hn.INVALID_VALUE,s)||this}return t}(Sr),tc=function(e){xr(t,e);function t(n,r,i){return e.call(this,'Value for "'.concat(n,'" must be of type ').concat(r),hn.INVALID_VALUE,i)||this}return t}(Sr),nc=function(e){xr(t,e);function t(n,r){return e.call(this,'The intl string context variable "'.concat(n,'" was not provided to the string "').concat(r,'"'),hn.MISSING_VALUE,r)||this}return t}(Sr),Ae;(function(e){e[e.literal=0]="literal",e[e.object=1]="object"})(Ae||(Ae={}));function rc(e){return e.length<2?e:e.reduce(function(t,n){var r=t[t.length-1];return!r||r.type!==Ae.literal||n.type!==Ae.literal?t.push(n):r.value+=n.value,t},[])}function ic(e){return typeof e=="function"}function Qn(e,t,n,r,i,s,a){if(e.length===1&&ms(e[0]))return[{type:Ae.literal,value:e[0].value}];for(var o=[],u=0,l=e;u<l.length;u++){var f=l[u];if(ms(f)){o.push({type:Ae.literal,value:f.value});continue}if(Cf(f)){typeof s=="number"&&o.push({type:Ae.literal,value:n.getNumberFormat(t).format(s)});continue}var c=f.value;if(!(i&&c in i))throw new nc(c,a);var h=i[c];if(Tf(f)){(!h||typeof h=="string"||typeof h=="number")&&(h=typeof h=="string"||typeof h=="number"?String(h):""),o.push({type:typeof h=="string"?Ae.literal:Ae.object,value:h});continue}if(Qa(f)){var d=typeof f.style=="string"?r.date[f.style]:si(f.style)?f.style.parsedOptions:void 0;o.push({type:Ae.literal,value:n.getDateTimeFormat(t,d).format(h)});continue}if(Ka(f)){var d=typeof f.style=="string"?r.time[f.style]:si(f.style)?f.style.parsedOptions:r.time.medium;o.push({type:Ae.literal,value:n.getDateTimeFormat(t,d).format(h)});continue}if(Ja(f)){var d=typeof f.style=="string"?r.number[f.style]:ro(f.style)?f.style.parsedOptions:void 0;d&&d.scale&&(h=h*(d.scale||1)),o.push({type:Ae.literal,value:n.getNumberFormat(t,d).format(h)});continue}if(no(f)){var p=f.children,y=f.value,_=i[y];if(!ic(_))throw new tc(y,"function",a);var P=Qn(p,t,n,r,i,s),L=_(P.map(function(Y){return Y.value}));Array.isArray(L)||(L=[L]),o.push.apply(o,L.map(function(Y){return{type:typeof Y=="string"?Ae.literal:Ae.object,value:Y}}))}if(eo(f)){var M=f.options[h]||f.options.other;if(!M)throw new Ss(f.value,h,Object.keys(f.options),a);o.push.apply(o,Qn(M.value,t,n,r,i));continue}if(to(f)){var M=f.options["=".concat(h)];if(!M){if(!Intl.PluralRules)throw new Sr(`Intl.PluralRules is not available in this environment.
10
- Try polyfilling it using "@formatjs/intl-pluralrules"
11
- `,hn.MISSING_INTL_API,a);var R=n.getPluralRules(t,{type:f.pluralType}).select(h-(f.offset||0));M=f.options[R]||f.options.other}if(!M)throw new Ss(f.value,h,Object.keys(f.options),a);o.push.apply(o,Qn(M.value,t,n,r,i,h-(f.offset||0)));continue}}return rc(o)}function sc(e,t){return t?nt(nt(nt({},e||{}),t||{}),Object.keys(e).reduce(function(n,r){return n[r]=nt(nt({},e[r]),t[r]||{}),n},{})):e}function ac(e,t){return t?Object.keys(e).reduce(function(n,r){return n[r]=sc(e[r],t[r]),n},nt({},e)):e}function kr(e){return{create:function(){return{get:function(t){return e[t]},set:function(t,n){e[t]=n}}}}}function oc(e){return e===void 0&&(e={number:{},dateTime:{},pluralRules:{}}),{getNumberFormat:Rr(function(){for(var t,n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];return new((t=Intl.NumberFormat).bind.apply(t,Br([void 0],n,!1)))},{cache:kr(e.number),strategy:Lr.variadic}),getDateTimeFormat:Rr(function(){for(var t,n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];return new((t=Intl.DateTimeFormat).bind.apply(t,Br([void 0],n,!1)))},{cache:kr(e.dateTime),strategy:Lr.variadic}),getPluralRules:Rr(function(){for(var t,n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];return new((t=Intl.PluralRules).bind.apply(t,Br([void 0],n,!1)))},{cache:kr(e.pluralRules),strategy:Lr.variadic})}}var uc=function(){function e(t,n,r,i){n===void 0&&(n=e.defaultLocale);var s=this;if(this.formatterCache={number:{},dateTime:{},pluralRules:{}},this.format=function(u){var l=s.formatToParts(u);if(l.length===1)return l[0].value;var f=l.reduce(function(c,h){return!c.length||h.type!==Ae.literal||typeof c[c.length-1]!="string"?c.push(h.value):c[c.length-1]+=h.value,c},[]);return f.length<=1?f[0]||"":f},this.formatToParts=function(u){return Qn(s.ast,s.locales,s.formatters,s.formats,u,void 0,s.message)},this.resolvedOptions=function(){var u;return{locale:((u=s.resolvedLocale)===null||u===void 0?void 0:u.toString())||Intl.NumberFormat.supportedLocalesOf(s.locales)[0]}},this.getAst=function(){return s.ast},this.locales=n,this.resolvedLocale=e.resolveLocale(n),typeof t=="string"){if(this.message=t,!e.__parse)throw new TypeError("IntlMessageFormat.__parse must be set to process `message` of type `string`");var a=i||{};a.formatters;var o=mf(a,["formatters"]);this.ast=e.__parse(t,nt(nt({},o),{locale:this.resolvedLocale}))}else this.ast=t;if(!Array.isArray(this.ast))throw new TypeError("A message must be provided as a String or AST.");this.formats=ac(e.formats,r),this.formatters=i&&i.formatters||oc(this.formatterCache)}return Object.defineProperty(e,"defaultLocale",{get:function(){return e.memoizedDefaultLocale||(e.memoizedDefaultLocale=new Intl.NumberFormat().resolvedOptions().locale),e.memoizedDefaultLocale},enumerable:!1,configurable:!0}),e.memoizedDefaultLocale=null,e.resolveLocale=function(t){if(!(typeof Intl.Locale>"u")){var n=Intl.NumberFormat.supportedLocalesOf(t);return n.length>0?new Intl.Locale(n[0]):new Intl.Locale(typeof t=="string"?t:t[0])}},e.__parse=ec,e.formats={number:{integer:{maximumFractionDigits:0},currency:{style:"currency"},percent:{style:"percent"}},date:{short:{month:"numeric",day:"numeric",year:"2-digit"},medium:{month:"short",day:"numeric",year:"numeric"},long:{month:"long",day:"numeric",year:"numeric"},full:{weekday:"long",month:"long",day:"numeric",year:"numeric"}},time:{short:{hour:"numeric",minute:"numeric"},medium:{hour:"numeric",minute:"numeric",second:"numeric"},long:{hour:"numeric",minute:"numeric",second:"numeric",timeZoneName:"short"},full:{hour:"numeric",minute:"numeric",second:"numeric",timeZoneName:"short"}}},e}();function lc(e,t){if(t==null)return;if(t in e)return e[t];const n=t.split(".");let r=e;for(let i=0;i<n.length;i++)if(typeof r=="object"){if(i>0){const s=n.slice(i,n.length).join(".");if(s in r){r=r[s];break}}r=r[n[i]]}else r=void 0;return r}const It={},fc=(e,t,n)=>n&&(t in It||(It[t]={}),e in It[t]||(It[t][e]=n),n),co=(e,t)=>{if(t==null)return;if(t in It&&e in It[t])return It[t][e];const n=Tr(t);for(let r=0;r<n.length;r++){const i=n[r],s=hc(i,e);if(s)return fc(e,t,s)}};let Wi;const gn=Er({});function cc(e){return Wi[e]||null}function ho(e){return e in Wi}function hc(e,t){if(!ho(e))return null;const n=cc(e);return lc(n,t)}function dc(e){if(e==null)return;const t=Tr(e);for(let n=0;n<t.length;n++){const r=t[n];if(ho(r))return r}}function po(e,...t){delete It[e],gn.update(n=>(n[e]=gf.all([n[e]||{},...t]),n))}pn([gn],([e])=>Object.keys(e));gn.subscribe(e=>Wi=e);const Kn={};function pc(e,t){Kn[e].delete(t),Kn[e].size===0&&delete Kn[e]}function vo(e){return Kn[e]}function vc(e){return Tr(e).map(t=>{const n=vo(t);return[t,n?[...n]:[]]}).filter(([,t])=>t.length>0)}function ci(e){return e==null?!1:Tr(e).some(t=>{var n;return(n=vo(t))==null?void 0:n.size})}function gc(e,t){return Promise.all(t.map(r=>(pc(e,r),r().then(i=>i.default||i)))).then(r=>po(e,...r))}const En={};function go(e){if(!ci(e))return e in En?En[e]:Promise.resolve();const t=vc(e);return En[e]=Promise.all(t.map(([n,r])=>gc(n,r))).then(()=>{if(ci(e))return go(e);delete En[e]}),En[e]}const mc={number:{scientific:{notation:"scientific"},engineering:{notation:"engineering"},compactLong:{notation:"compact",compactDisplay:"long"},compactShort:{notation:"compact",compactDisplay:"short"}},date:{short:{month:"numeric",day:"numeric",year:"2-digit"},medium:{month:"short",day:"numeric",year:"numeric"},long:{month:"long",day:"numeric",year:"numeric"},full:{weekday:"long",month:"long",day:"numeric",year:"numeric"}},time:{short:{hour:"numeric",minute:"numeric"},medium:{hour:"numeric",minute:"numeric",second:"numeric"},long:{hour:"numeric",minute:"numeric",second:"numeric",timeZoneName:"short"},full:{hour:"numeric",minute:"numeric",second:"numeric",timeZoneName:"short"}}},_c={fallbackLocale:null,loadingDelay:200,formats:mc,warnOnMissingMessages:!0,handleMissingMessage:void 0,ignoreTag:!0},bc=_c;function dn(){return bc}const Gr=Er(!1);var yc=Object.defineProperty,Ec=Object.defineProperties,wc=Object.getOwnPropertyDescriptors,Ts=Object.getOwnPropertySymbols,xc=Object.prototype.hasOwnProperty,Sc=Object.prototype.propertyIsEnumerable,Cs=(e,t,n)=>t in e?yc(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Tc=(e,t)=>{for(var n in t||(t={}))xc.call(t,n)&&Cs(e,n,t[n]);if(Ts)for(var n of Ts(t))Sc.call(t,n)&&Cs(e,n,t[n]);return e},Cc=(e,t)=>Ec(e,wc(t));let hi;const hr=Er(null);function As(e){return e.split("-").map((t,n,r)=>r.slice(0,n+1).join("-")).reverse()}function Tr(e,t=dn().fallbackLocale){const n=As(e);return t?[...new Set([...n,...As(t)])]:n}function Xt(){return hi??void 0}hr.subscribe(e=>{hi=e??void 0,typeof window<"u"&&e!=null&&document.documentElement.setAttribute("lang",e)});const Ac=e=>{if(e&&dc(e)&&ci(e)){const{loadingDelay:t}=dn();let n;return typeof window<"u"&&Xt()!=null&&t?n=window.setTimeout(()=>Gr.set(!0),t):Gr.set(!0),go(e).then(()=>{hr.set(e)}).finally(()=>{clearTimeout(n),Gr.set(!1)})}return hr.set(e)},$t=Cc(Tc({},hr),{set:Ac}),Cr=e=>{const t=Object.create(null);return r=>{const i=JSON.stringify(r);return i in t?t[i]:t[i]=e(r)}};var Ic=Object.defineProperty,dr=Object.getOwnPropertySymbols,mo=Object.prototype.hasOwnProperty,_o=Object.prototype.propertyIsEnumerable,Is=(e,t,n)=>t in e?Ic(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,qi=(e,t)=>{for(var n in t||(t={}))mo.call(t,n)&&Is(e,n,t[n]);if(dr)for(var n of dr(t))_o.call(t,n)&&Is(e,n,t[n]);return e},mn=(e,t)=>{var n={};for(var r in e)mo.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&dr)for(var r of dr(e))t.indexOf(r)<0&&_o.call(e,r)&&(n[r]=e[r]);return n};const Dn=(e,t)=>{const{formats:n}=dn();if(e in n&&t in n[e])return n[e][t];throw new Error(`[svelte-i18n] Unknown "${t}" ${e} format.`)},Pc=Cr(e=>{var t=e,{locale:n,format:r}=t,i=mn(t,["locale","format"]);if(n==null)throw new Error('[svelte-i18n] A "locale" must be set to format numbers');return r&&(i=Dn("number",r)),new Intl.NumberFormat(n,i)}),Oc=Cr(e=>{var t=e,{locale:n,format:r}=t,i=mn(t,["locale","format"]);if(n==null)throw new Error('[svelte-i18n] A "locale" must be set to format dates');return r?i=Dn("date",r):Object.keys(i).length===0&&(i=Dn("date","short")),new Intl.DateTimeFormat(n,i)}),$c=Cr(e=>{var t=e,{locale:n,format:r}=t,i=mn(t,["locale","format"]);if(n==null)throw new Error('[svelte-i18n] A "locale" must be set to format time values');return r?i=Dn("time",r):Object.keys(i).length===0&&(i=Dn("time","short")),new Intl.DateTimeFormat(n,i)}),Nc=(e={})=>{var t=e,{locale:n=Xt()}=t,r=mn(t,["locale"]);return Pc(qi({locale:n},r))},Mc=(e={})=>{var t=e,{locale:n=Xt()}=t,r=mn(t,["locale"]);return Oc(qi({locale:n},r))},Hc=(e={})=>{var t=e,{locale:n=Xt()}=t,r=mn(t,["locale"]);return $c(qi({locale:n},r))},Dc=Cr((e,t=Xt())=>new uc(e,t,dn().formats,{ignoreTag:dn().ignoreTag})),Bc=(e,t={})=>{var n,r,i,s;let a=t;typeof e=="object"&&(a=e,e=a.id);const{values:o,locale:u=Xt(),default:l}=a;if(u==null)throw new Error("[svelte-i18n] Cannot format a message without first setting the initial locale.");let f=co(e,u);if(!f)f=(s=(i=(r=(n=dn()).handleMissingMessage)==null?void 0:r.call(n,{locale:u,id:e,defaultValue:l}))!=null?i:l)!=null?s:e;else if(typeof f!="string")return console.warn(`[svelte-i18n] Message with id "${e}" must be of type "string", found: "${typeof f}". Gettin its value through the "$format" method is deprecated; use the "json" method instead.`),f;if(!o)return f;let c=f;try{c=Dc(f,u).format(o)}catch(h){h instanceof Error&&console.warn(`[svelte-i18n] Message "${e}" has syntax error:`,h.message)}return c},Rc=(e,t)=>Hc(t).format(e),Lc=(e,t)=>Mc(t).format(e),Fc=(e,t)=>Nc(t).format(e),kc=(e,t=Xt())=>co(e,t),Zi=pn([$t,gn],()=>Bc);pn([$t],()=>Rc);pn([$t],()=>Lc);pn([$t],()=>Fc);pn([$t,gn],()=>kc);const Gc={en:{new:"New",scheduled:"Scheduled",onGoing:"Ongoing",paused:"Paused",completed:"Completed",expired:"Expired",rejected:"Rejected",failed:"Failed",forfeited:"Forfeited",endsIn:"Ends in",startsIn:"Starts in",promo:"Promo",active:"Active",claim:"Claim",pending:"Pending",finished:"Finished",optIn:"Opt In",login:"Login",resume:"Resume",pause:"Pause",levels:"Levels",level:"Level",events:"Events",rules:"Rules",games:"Games",status:"Status",time:"Time",viewDetails:"View Details",details:"Details",get:"Get",Condition:"Condition",termsAndConditions:"Terms & Conditions",allChallenges:"All Challenges",all:"All",placeBetsOf:"Place bets of",place:"Place",bet:"bet",bets:"bets",betTime:"time",betTimes:"times",minBet:"min bet",winStakeRatio:"Win/stake ratio"},tr:{new:"Yeni",scheduled:"Planlandı",onGoing:"Devam Ediyor",paused:"Duraklatıldı",completed:"Tamamlandı",expired:"Süresi Doldu",rejected:"Reddedildi",failed:"Başarısız",forfeited:"Vazgeçildi",endsIn:"Bitiş",startsIn:"Başlangıç",promo:"Promosyon",active:"Aktif",claim:"Al",pending:"Beklemede",finished:"Bitti",optIn:"Katıl",login:"Giriş Yap",resume:"Devam Et",pause:"Duraklat",levels:"Seviyeler",level:"Seviye",events:"Etkinlikler",rules:"Kurallar",games:"Oyunlar",viewDetails:"Detayları Gör",details:"Detayları",get:"Al",Condition:"Koşul",termsAndConditions:"Şartlar ve Koşullar",allChallenges:"Tüm Meydan Okumalar",all:"Tümü"},da:{new:"Ny",scheduled:"Planlagt",onGoing:"I gang",paused:"Sat på pause",completed:"Gennemført",expired:"Udløbet",rejected:"Afvist",failed:"Mislykket",forfeited:"Opgivet",endsIn:"Slutter om",startsIn:"Starter om",promo:"Promo",active:"Aktiv",claim:"Hent",pending:"Afventer",finished:"Færdig",optIn:"Tilmeld",login:"Log ind",resume:"Fortsæt",pause:"Pause",levels:"Niveauer",level:"Niveau",events:"Begivenheder",rules:"Regler",games:"Spil",viewDetails:"Se detaljer",details:"Detaljer",get:"Få",Condition:"Betingelse",termsAndConditions:"Vilkår og betingelser",allChallenges:"Alle udfordringer",all:"Alle"},de:{new:"Neu",scheduled:"Geplant",onGoing:"Läuft",paused:"Pausiert",completed:"Abgeschlossen",expired:"Abgelaufen",rejected:"Abgelehnt",failed:"Fehlgeschlagen",forfeited:"Aufgegeben",endsIn:"Endet in",startsIn:"Startet in",promo:"Promo",active:"Aktiv",claim:"Abholen",pending:"Ausstehend",finished:"Beendet",optIn:"Teilnehmen",login:"Anmelden",resume:"Fortsetzen",pause:"Pausieren",levels:"Stufen",level:"Stufe",events:"Events",rules:"Regeln",games:"Spiele",viewDetails:"Details anzeigen",details:"Details",get:"Erhalten",Condition:"Bedingung",termsAndConditions:"Allgemeine Geschäftsbedingungen",allChallenges:"Alle Challenges",all:"Alle"},nl:{new:"Nieuw",scheduled:"Gepland",onGoing:"Bezig",paused:"Gepauzeerd",completed:"Voltooid",expired:"Verlopen",rejected:"Afgewezen",failed:"Mislukt",forfeited:"Opgegeven",endsIn:"Eindigt over",startsIn:"Begint over",promo:"Promo",active:"Actief",claim:"Ophalen",pending:"In afwachting",finished:"Voltooid",optIn:"Deelnemen",login:"Inloggen",resume:"Hervatten",pause:"Pauzeren",levels:"Niveaus",level:"Niveau",events:"Evenementen",rules:"Regels",games:"Spellen",viewDetails:"Details bekijken",details:"Details",get:"Ontvang",Condition:"Voorwaarde",termsAndConditions:"Algemene voorwaarden",allChallenges:"Alle Challenges",all:"Alle"},fr:{new:"Nouveau",scheduled:"Planifié",onGoing:"En cours",paused:"En pause",completed:"Terminé",expired:"Expiré",rejected:"Rejeté",failed:"Échoué",forfeited:"Abandonné",endsIn:"Se termine dans",startsIn:"Commence dans",promo:"Promo",active:"Actif",claim:"Réclamer",pending:"En attente",finished:"Terminé",optIn:"Participer",login:"Connexion",resume:"Reprendre",pause:"Pause",levels:"Niveaux",level:"Niveau",events:"Événements",rules:"Règles",games:"Jeux",viewDetails:"Voir les détails",details:"Détails",get:"Obtenir",Condition:"Condition",termsAndConditions:"Conditions générales",allChallenges:"Tous les challenges",all:"Tous"},hu:{new:"Új",scheduled:"Ütemezett",onGoing:"Folyamatban",paused:"Szüneteltetve",completed:"Befejezve",expired:"Lejárt",rejected:"Elutasítva",failed:"Sikertelen",forfeited:"Feladva",endsIn:"Vége:",startsIn:"Kezdés:",promo:"Promóció",active:"Aktív",claim:"Átvétel",pending:"Függőben",finished:"Befejezve",optIn:"Csatlakozás",login:"Bejelentkezés",resume:"Folytatás",pause:"Szünet",levels:"Szintek",level:"Szint",events:"Események",rules:"Szabályok",games:"Játékok",viewDetails:"Részletek megtekintése",details:"Részletek",get:"Megszerez",Condition:"Feltétel",termsAndConditions:"Felhasználási feltételek",allChallenges:"Összes kihívás",all:"Összes"}},Uc=({withLocale:e,translations:t})=>{$t.subscribe(n=>{n==null&&(gn.set(t),$t.set(e))})},jc=(e,t)=>{po(e,t)},Vc=e=>{$t.set(e)},di=e=>{Object.entries(e).forEach(([t,n])=>{jc(t,n)})},zc=(e,...t)=>{Uc({withLocale:e,translations:{}}),di(Gc),t.forEach(di)},Yc=(e,t)=>{const n=new URL(e,window.location.href);fetch(n.href).then(r=>r.json()).then(r=>di(r)).catch(r=>{console.log(`${t} translation url err:`,r)})},Xc=[V.Started,V.InProgress,V.PendingLevelReward,V.Completed],pr=e=>Xc.includes(e),Wc=[V.InProgress,V.PendingLevelReward,V.Paused,V.Completed,V.Expired,V.Forfeited],bo=e=>Wc.includes(e),yo=e=>bo(e.Status),Ji=e=>e.ProgressStatus===ot.Completed,qc=(e,t)=>Ji(e)?!1:e.ProgressStatus===ot.InProgress&&pr(t),Zc=(e,t)=>bo(t)?Ji(e)&&pr(t)?"completed":qc(e,t)?"current":e.ProgressStatus===ot.InProgress&&!pr(t)?"locked-in-progress":"locked":"locked",Jc=e=>e?e.CustomRewardMessage?e.CustomRewardMessage:(e.Rewards??[]).map(t=>t?.RewardDescription).filter(t=>!!t).join(" + "):"",Qc=(e,t,n)=>{if(!e)return"";const r=s=>`${t}${s}`,i=s=>s?`, ${n("minBet")} ${r(s)}`:"";switch(e.LevelTargetType){case Tn.Accumulative:return`${n("placeBetsOf")} ${r(e.DisplayCurrencyTargetTurnover)}${i(e.BetRange?.MinBet)}`;case Tn.SingleBet:return`${n("place")} ${r(e.DisplayCurrencyTargetTurnover)} ${n("bet")}`;case Tn.MultipleOneBetSize:return`${n("place")} ${e.TargetBetCount} ${n("bets")}${i(e.DisplayCurrencyTargetTurnover)}`;case Tn.BetMultiplier:{const s=`${e.TargetBetCount} ${n(e.TargetBetCount===1?"betTime":"betTimes")}`;return`${n("winStakeRatio")} x${e.Multiplier} ${s}${i(e.BetRange?.MinBet)}`}default:return""}},Kc=e=>e.ProgressStatus===ot.Fillup||e.ProgressStatus===ot.Completed,Eo=e=>{if(!e.length)return 0;const t=e.findIndex(n=>n.ProgressStatus===ot.InProgress);return t>=0?t+1:Math.min(e.filter(Kc).length+1,e.length)},eh=e=>{const t=e.LevelProgresses??[];if(t.length)return yo(e)?t[Eo(t)-1]:t[0]},th=e=>e!=="history",Xn=()=>({loading:!1,error:void 0,pageNumber:ln,hasMore:!1,totalCount:0}),nh=e=>{let t=Ie(ke([])),n=Ie(ke([])),r=Ie(ke([])),i=Ie(ke([])),s=Ie(ke([]));const a=an(()=>$(r).filter(g=>vs(g,$(s)))),o=an(()=>$(n).filter(g=>!vs(g,$(s)))),u=ke({promo:Xn(),active:Xn(),pending:Xn(),history:Xn()}),l=g=>u[g];let f;const c=g=>{switch(g){case"promo":return $(t);case"pending":return $(r);default:return $(n)}},h=(g,E)=>{ie(g==="promo"?t:g==="pending"?r:n,E,!0)},d=g=>{ie(t,g($(t)),!0),ie(n,g($(n)),!0),ie(r,g($(r)),!0)},p=(g,E)=>{d(D=>D.map(F=>F.Id===g?{...F,...E}:F))},y=(g,E)=>{d(D=>D.map(F=>F.ChallengeId===g?{...F,...E}:F))},_=g=>{if(g)return[...$(n),...$(r),...$(t)].find(E=>E.ChallengeId===g)},P=g=>{d(E=>E.filter(D=>D.Id!==g))},L=async(g,E,D)=>{const{endpoint:F,domainId:w,userSession:m,userId:b,locale:I,pageSize:x=Gn}=e();if(!F)throw new Error("challenges: endpoint is missing. Please provide a valid endpoint URL.");const H={endpoint:F,domainId:w,sessionId:m,locale:I,pageNumber:D,pageSize:x};if(E)return Hr({endpoint:F,domainId:w,locale:I,pageNumber:D,pageSize:x});switch(g){case"promo":return Ml(H);case"pending":return Hr({...H,isFutureAvailable:!0});case"history":return ka({...H,userId:b??"",isFutureAvailable:!0});default:return Hr({...H,isFutureAvailable:!1})}},M=(g,E,D)=>{const F=u[g];if(F.pageNumber=E.PageNumber??ln,!th(g)){const b=E.Data??[];ie(i,D?[...$(i),...b]:b,!0),F.totalCount=E.TotalItem??$(i).length,F.hasMore=$(i).length<F.totalCount;return}const w=E.Data??[],m=D?[...c(g),...w]:w;h(g,m),F.totalCount=E.TotalCount??m.length,F.hasMore=m.length<F.totalCount},R=async(g,E,{append:D=!1,page:F}={})=>{const w=u[g];w.loading=!0,w.error=void 0;try{const m=F??(D?w.pageNumber+1:ln),b=await L(g,E,m);M(g,b,D)}catch(m){w.error=m,e().onError?.(m)}finally{w.loading=!1}},Y=(g,E)=>{const D=u[g];return D.hasMore&&!D.loading?R(g,E,{append:!0}):Promise.resolve()},N=(g,E,D)=>u[g].loading?Promise.resolve():R(g,E,{page:D}),C=(g,E)=>{const D=$(s).includes(g);E&&!D?ie(s,[...$(s),g],!0):!E&&D&&ie(s,$(s).filter(F=>F!==g),!0)},S=()=>{const{endpoint:g,userId:E,userSession:D,liveUpdates:F=!0}=e();!F||f||(f=Gl({endpoint:g,userId:E,sessionId:D,onNewProgress:w=>{w.Status===V.Started?ie(n,[w,...$(n)],!0):w.Status===V.Awaiting&&ie(r,[w,...$(r)],!0)},onSessionExpired:()=>j(),onChallengeEnabledChange:(w,m)=>{C(w,!m),y(w,{ChallengeStatus:m?lr.Enabled:lr.Paused})},onProgressForfeited:w=>{p(w,{Status:V.Forfeited})}}))},j=()=>{f?.close(),f=void 0};return{get promoChallenges(){return $(t)},get activeChallenges(){return $(n)},get runningChallenges(){return $(o)},get pausedChallenges(){return $(a)},get pendingChallenges(){return $(r)},get playerHistory(){return $(i)},get pausedChallengeIds(){return $(s)},getState:l,getList:c,findChallenge:_,load:R,loadMore:Y,loadPage:N,setPaused:C,patchProgress:p,patchChallenge:y,removeProgress:P,connect:S,disconnect:j}},rh=e=>{let t=Ie(!1);const n=async(s,a,o)=>{const{endpoint:u,domainId:l,userSession:f,userId:c,onStatusChange:h}=e();ie(t,!0);try{await Rl({endpoint:u,domainId:l,sessionId:f,userId:c??"",progressTo:s.Id,isPause:a}),h?.(s.Id,a?V.Paused:V.InProgress),ti(o)}catch(d){ni(o,d instanceof Error?d.message:String(d))}finally{ie(t,!1)}},r=async s=>{const{endpoint:a,domainId:o,userSession:u,onClaimed:l}=e();ie(t,!0);try{await kl({endpoint:a,domainId:o,sessionId:u,challengeId:s.Id}),l?.(s.ChallengeId),ti(Dt.Claim)}catch(f){ni(Dt.Claim,f instanceof Error?f.message:String(f))}finally{ie(t,!1)}};return{get loading(){return $(t)},run:(s,a)=>{const o=a.ChallengeId,u=a.ChallengePresentation?.PresentationName??"",l=Ya(a);switch(s){case"login":Ba();break;case"deposit":Tl(o,u,l);break;case"claim":r(a);break;case"optIn":ml(o,u,l),n(a,!1,Dt.OptIn);break;case"resume":xl(o,u,l),n(a,!1,Dt.Resume);break;case"pause":wl(o,u,l),n(a,!0,Dt.Pause);break}}}},we={Promo:0,Active:1,Pending:2,Finished:3,Code:4},ih=e=>{const t=Number(e);return Object.values(we).includes(t)?t:void 0},sh={[we.Promo]:"promo",[we.Active]:"active",[we.Pending]:"pending",[we.Finished]:"finished",[we.Code]:"claim"},ah={[we.Promo]:"promo",[we.Active]:"active",[we.Pending]:"pending",[we.Finished]:"history",[we.Code]:void 0};var oh=vn('<span class="player-challenges__tab-dot svelte-1jf237k" aria-hidden="true"></span>'),uh=vn('<button type="button" role="tab"> <!></button>'),lh=vn('<div class="player-challenges__tabs svelte-1jf237k" role="tablist"></div>');const fh={hash:"svelte-1jf237k",code:`.player-challenges__tabs.svelte-1jf237k {box-sizing:border-box;display:flex;flex-direction:row;justify-content:space-between;align-items:center;padding:6px 8px;gap:4px;background:var(--bg-overlay-neutral-level-2, rgba(251, 251, 251, 0.1));border:1px solid var(--border-subtle, rgba(251, 251, 251, 0.05));border-radius:100px;width:fit-content;max-width:100%;overflow-x:auto;scrollbar-width:none;-ms-overflow-style:none;&::-webkit-scrollbar {display:none;}}.player-challenges__tab.svelte-1jf237k {box-sizing:border-box;display:inline-flex;align-items:center;gap:4px;padding:6px 47px;border:0;border-radius:36px;background:transparent;color:var(--text-subtle, rgba(223, 227, 232, 1));font-size:10px;font-weight:500;white-space:nowrap;cursor:pointer;line-height:145%;appearance:none;-webkit-appearance:none;-webkit-tap-highlight-color:transparent;&:focus-visible {outline:none;}&.active {background:var(--tabs-bg-selected, rgba(251, 251, 251, 0.2));color:var(--text-default, rgba(223, 227, 232, 1));}&:hover:not(.active) {background:var(--bg-tabs-hover, rgba(251, 251, 251, 0.1));}}.player-challenges__tab-dot.svelte-1jf237k {width:6px;height:6px;border-radius:50%;flex-shrink:0;background:var(--semantic-success-400, rgba(45, 223, 0, 1));}
12
-
13
- @media (max-width: 767px) {.player-challenges__tabs.svelte-1jf237k {width:100%;justify-content:flex-start;gap:2px;padding:6px 8px;}.player-challenges__tab.svelte-1jf237k {flex:1 0 auto;justify-content:center;padding:6px 12px;}
14
- }`};function wo(e,t){br(t,!0),Fi(e,fh);const n=()=>_i(Zi,"$_",r),[r,i]=bi(),s=At(t,"activeTab",7),a=At(t,"onTabChange",7),o=At(t,"notifyTabs",23,()=>[]),u=At(t,"showTabDot",7,!1),l=an(()=>[{id:we.Promo,label:n()("promo")},{id:we.Active,label:n()("active")},{id:we.Code,label:n()("claim")},{id:we.Pending,label:n()("pending")},{id:we.Finished,label:n()("finished")}]);var f={get activeTab(){return s()},set activeTab(d){s(d),bt()},get onTabChange(){return a()},set onTabChange(d){a(d),bt()},get notifyTabs(){return o()},set notifyTabs(d=[]){o(d),bt()},get showTabDot(){return u()},set showTabDot(d=!1){u(d),bt()}},c=lh();Li(c,21,()=>$(l),d=>d.id,(d,p)=>{var y=uh();let _;var P=Si(y),L=ca(P);{var M=Y=>{var N=oh();Gt(Y,N)},R=an(()=>u()&&o().includes($(p).id));$a(L,Y=>{$(R)&&Y(M)})}$n(y),$i(()=>{_=ki(y,1,"player-challenges__tab svelte-1jf237k",null,_,{active:s()===$(p).id}),ur(y,"aria-selected",s()===$(p).id),Ri(P,`${$(p).label??""} `)}),Di("click",y,()=>a()?.($(p).id)),Gt(d,y)}),$n(c),Gt(e,c);var h=yr(f);return i(),h}Bi(["click"]);Ui(wo,{activeTab:{},onTabChange:{},notifyTabs:{},showTabDot:{}},[],[],{mode:"open"});const Me={Levels:"levels",Games:"games",Events:"events",Rules:"rules"},ch=e=>{const t=String(e??"").toLowerCase();return Object.values(Me).includes(t)?t:void 0},Qi=e=>{switch(e){case fr.Casino:return[Me.Levels,Me.Games,Me.Rules];case fr.Sportsbook:return[Me.Levels,Me.Events,Me.Rules];default:return[]}},hh=e=>Qi(e).find(t=>t===Me.Games||t===Me.Events),dh=e=>[e.Discipline?.Name,e.Location?.Name,e.Template?.Name,e.Tournament?.Name,e.Event?.Name].filter(Boolean).join(", "),ph=e=>[...e??[]].sort((t,n)=>t.OrderNumber-n.OrderNumber),vh=e=>{switch(e){case Jn.RealCash:return"contributionTypeRealMoney";case Jn.BonusMoney:return"contributionTypeBonusMoney";case Jn.Mixed:return"contributionTypeMixed";default:return}},gh=e=>e?"contributeToOne":"contributeToAll",mh=e=>{switch(e){case Cn.Single:return"recurrenceSingle";case Cn.Daily:return"recurrenceDaily";case Cn.Weekly:return"recurrenceWeekly";case Cn.Monthly:return"recurrenceMonthly";default:return}};var _h=vn('<button type="button"> </button>'),bh=vn('<div class="challenge-details__tabs svelte-lloeg4"></div>');const yh={hash:"svelte-lloeg4",code:".challenge-details__tabs.svelte-lloeg4 {border:none;border-bottom:1px solid var(--border-default, rgba(251, 251, 251, 0.15));display:flex;flex-direction:row;justify-content:center;align-items:center;background-color:transparent;}.challenge-details__tab.svelte-lloeg4 {border:none;padding:12px 10px;gap:10px;height:36px;position:relative;flex:none;order:1;flex-grow:1;color:var(--text-super-subtle, rgba(251, 251, 251, 0.5));font-size:12px;font-weight:700;background-color:transparent;text-transform:uppercase;&.active {color:var(--text-brand, rgba(255, 204, 0, 1));&::after {content:'';position:absolute;left:0;right:0;bottom:-3px;height:2px;background:var(--pagination-bg-selected, rgba(255, 204, 0, 1));}}}"};function xo(e,t){br(t,!0),Fi(e,yh);const n=()=>_i(Zi,"$_",r),[r,i]=bi(),s=At(t,"challengeItem",7),a=At(t,"activeTab",15),o=At(t,"onTabChange",7),u={[Me.Levels]:"levels",[Me.Games]:"games",[Me.Events]:"events",[Me.Rules]:"rules"},l=an(()=>Qi(s().ContributedFrom).map(d=>({id:d,label:n()(u[d])})));var f={get challengeItem(){return s()},set challengeItem(d){s(d),bt()},get activeTab(){return a()},set activeTab(d){a(d),bt()},get onTabChange(){return o()},set onTabChange(d){o(d),bt()}},c=bh();Li(c,21,()=>$(l),Na,(d,p)=>{var y=_h();let _;var P=Si(y,!0);$n(y),$i(()=>{_=ki(y,1,"challenge-details__tab svelte-lloeg4",null,_,{active:a()===$(p).id}),Ri(P,$(p).label)}),Di("click",y,()=>o()?.($(p).id)),Gt(d,y)}),$n(c),Gt(e,c);var h=yr(f);return i(),h}Bi(["click"]);Ui(xo,{challengeItem:{},activeTab:{},onTabChange:{}},[],[],{mode:"open"});exports.$format=Zi;exports.CHALLENGES_TAB_LIST_KIND=ah;exports.CHALLENGES_TAB_NAMES=sh;exports.ChallengeAction=Dt;exports.ChallengeApiError=La;exports.ChallengeDetailsTab=Me;exports.ChallengeHistoryLevelStatus=Ra;exports.ChallengeProgressStatus=V;exports.ChallengeTabs=xo;exports.ChallengeTabs$1=wo;exports.ChallengesTab=we;exports.ContributedFrom=fr;exports.NO_PROGRESS=Va;exports.OPT_OUT_CONFIRMED_MESSAGE=Al;exports.PAGE_NUMBER_DEFAULT=ln;exports.PAGE_SIZE_DEFAULT=Gn;exports.PAGINATION_VISIBLE_PAGE=Ol;exports.append=Gt;exports.append_styles=Fi;exports.bind_element_size=cl;exports.bind_this=hl;exports.child=Si;exports.clsx=Ku;exports.comment=Gu;exports.createChallengeActions=rh;exports.createChallengesData=nh;exports.create_custom_element=Ui;exports.dayjs=Ut;exports.delegate=Bi;exports.delegated=Di;exports.each=Li;exports.event=Bu;exports.first_child=Su;exports.flushSync=bt;exports.formatDisplayDate=ja;exports.from_html=vn;exports.from_svg=ku;exports.get=$;exports.getAvailableTabs=Qi;exports.getBadgeContent=Wl;exports.getChallengeAction=ef;exports.getChallengeById=Nl;exports.getChallengeGames=Bl;exports.getChallengeHistory=ka;exports.getChallengeProgress=Jl;exports.getChallengeStatusName=Ya;exports.getContributeToKey=gh;exports.getContributionTypeKey=vh;exports.getCurrentLevelNumber=Eo;exports.getDisplayLevel=eh;exports.getEventRuleName=dh;exports.getGamesTab=hh;exports.getLevelCondition=Qc;exports.getLevelDisplayStatus=Zc;exports.getLevelRewardText=Jc;exports.getPageSize=Pl;exports.getPromoChallengeById=Hl;exports.getRecurrenceKey=mh;exports.grantChallengeByCode=Dl;exports.if_block=$a;exports.index=Na;exports.initI18n=zc;exports.isChallengeActive=pr;exports.isLevelCompleted=Ji;exports.isOptedIn=yo;exports.loadTranslationUrl=Yc;exports.mapChallengeStatus=Zl;exports.next=js;exports.onDestroy=Wu;exports.optOutChallenge=Fl;exports.pop=yr;exports.prop=At;exports.proxy=ke;exports.push=br;exports.remove_input_defaults=ol;exports.replay_events=Hu;exports.reset=$n;exports.sendChallengeActionFail=ni;exports.sendChallengeActionSuccess=ti;exports.sendChallengeDetailPageOpen=El;exports.sendChallengeDetailTabClicked=yl;exports.sendChallengeLoginClicked=Ba;exports.sendChallengeTabClicked=gl;exports.sendChallengeViewDetailClicked=bl;exports.sendGameClicked=Sl;exports.sendOptOutClicked=_l;exports.sendPromoChallengeClicked=Cl;exports.set=ie;exports.setLocale=Vc;exports.set_attribute=ur;exports.set_class=ki;exports.set_style=nl;exports.set_text=Ri;exports.set_value=ul;exports.setup_stores=bi;exports.sibling=ca;exports.sortEventRules=ph;exports.state=Ie;exports.store_get=_i;exports.template_effect=$i;exports.toBoolean=Ul;exports.toChallengeDetailsTab=ch;exports.toChallengesTab=ih;exports.toNumber=jl;exports.untrack=Nt;exports.updateChallengeIsNewStatus=Ll;exports.user_derived=an;exports.user_effect=pa;exports.user_pre_effect=Cu;