@everymatrix/player-account-vault 0.19.7 → 0.19.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/PlayerAccountVault-D2U-yg2W.cjs +3 -0
- package/components/{PlayerAccountVault-CCs1I5Og.js → PlayerAccountVault-DlvJ0h2m.js} +1785 -1470
- package/components/{PlayerAccountVault-CXjFpsjH.js → PlayerAccountVault-DqqlFpzx.js} +1717 -1405
- package/es2015/player-account-vault.cjs +1 -1
- package/es2015/player-account-vault.js +7 -7
- package/package.json +1 -1
- package/components/PlayerAccountVault-FAeoGOqS.cjs +0 -3
- package/components/balance-error-CE_1OErX.js +0 -30
- package/components/balance-error-QmmPv69I.cjs +0 -1
- package/components/balance-error-Vm_CNjW8.js +0 -30
- package/components/custom-select-BNvUE8tq.js +0 -319
- package/components/custom-select-BQujSd9v.js +0 -326
- package/components/custom-select-BTnYkMCn.cjs +0 -1
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
"use strict";var Pr=Object.defineProperty,Ir=Object.defineProperties;var Lr=Object.getOwnPropertyDescriptors;var En=Object.getOwnPropertySymbols;var Nr=Object.prototype.hasOwnProperty,Or=Object.prototype.propertyIsEnumerable;var Vt=(e,t,n)=>t in e?Pr(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Ue=(e,t)=>{for(var n in t||(t={}))Nr.call(t,n)&&Vt(e,n,t[n]);if(En)for(var n of En(t))Or.call(t,n)&&Vt(e,n,t[n]);return e},Ft=(e,t)=>Ir(e,Lr(t));var ae=(e,t,n)=>(Vt(e,typeof t!="symbol"?t+"":t,n),n);var Gt=(e,t,n)=>new Promise((r,i)=>{var o=s=>{try{l(n.next(s))}catch(u){i(u)}},a=s=>{try{l(n.throw(s))}catch(u){i(u)}},l=s=>s.done?r(s.value):Promise.resolve(s.value).then(o,a);l((n=n.apply(e,t)).next())});Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});function I(){}function er(e){return e()}function xn(){return Object.create(null)}function Ee(e){e.forEach(er)}function ct(e){return typeof e=="function"}function Pt(e,t){return e!=e?t==t:e!==t||e&&typeof e=="object"||typeof e=="function"}function Rr(e){return Object.keys(e).length===0}function tr(e,...t){if(e==null){for(const r of t)r(void 0);return I}const n=e.subscribe(...t);return n.unsubscribe?()=>n.unsubscribe():n}function kr(e){let t;return tr(e,n=>t=n)(),t}function Dr(e){return e&&ct(e.destroy)?e.destroy:I}function v(e,t){e.appendChild(t)}function hn(e,t,n){const r=Mr(e);if(!r.getElementById(t)){const i=T("style");i.id=t,i.textContent=n,Ur(r,i)}}function Mr(e){if(!e)return document;const t=e.getRootNode?e.getRootNode():e.ownerDocument;return t&&t.host?t:e.ownerDocument}function Ur(e,t){return v(e.head||e,t),t.sheet}function H(e,t,n){e.insertBefore(t,n||null)}function B(e){e.parentNode&&e.parentNode.removeChild(e)}function nr(e,t){for(let n=0;n<e.length;n+=1)e[n]&&e[n].d(t)}function T(e){return document.createElement(e)}function wn(e){return document.createElementNS("http://www.w3.org/2000/svg",e)}function W(e){return document.createTextNode(e)}function R(){return W(" ")}function rr(){return W("")}function ie(e,t,n,r){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n,r)}function Vr(e){return function(t){return t.stopPropagation(),e.call(this,t)}}function b(e,t,n){n==null?e.removeAttribute(t):e.getAttribute(t)!==n&&e.setAttribute(t,n)}function Tt(e){return e===""?null:+e}function Fr(e){return Array.from(e.childNodes)}function te(e,t){t=""+t,e.data!==t&&(e.data=t)}function yt(e,t){e.value=t==null?"":t}function se(e,t,n){e.classList.toggle(t,!!n)}function Gr(e){const t={};return e.childNodes.forEach(n=>{t[n.slot||"default"]=!0}),t}let at;function ot(e){at=e}function $r(){if(!at)throw new Error("Function called outside component initialization");return at}function jr(e){$r().$$.on_mount.push(e)}const Ge=[],je=[];let $e=[];const Yt=[],Xr=Promise.resolve();let Jt=!1;function Wr(){Jt||(Jt=!0,Xr.then(j))}function qt(e){$e.push(e)}function An(e){Yt.push(e)}const $t=new Set;let Ve=0;function j(){if(Ve!==0)return;const e=at;do{try{for(;Ve<Ge.length;){const t=Ge[Ve];Ve++,ot(t),zr(t.$$)}}catch(t){throw Ge.length=0,Ve=0,t}for(ot(null),Ge.length=0,Ve=0;je.length;)je.pop()();for(let t=0;t<$e.length;t+=1){const n=$e[t];$t.has(n)||($t.add(n),n())}$e.length=0}while(Ge.length);for(;Yt.length;)Yt.pop()();Jt=!1,$t.clear(),ot(e)}function zr(e){if(e.fragment!==null){e.update(),Ee(e.before_update);const t=e.dirty;e.dirty=[-1],e.fragment&&e.fragment.p(e.ctx,t),e.after_update.forEach(qt)}}function Zr(e){const t=[],n=[];$e.forEach(r=>e.indexOf(r)===-1?t.push(r):n.push(r)),n.forEach(r=>r()),$e=t}const Et=new Set;let Ne;function Se(){Ne={r:0,c:[],p:Ne}}function He(){Ne.r||Ee(Ne.c),Ne=Ne.p}function V(e,t){e&&e.i&&(Et.delete(e),e.i(t))}function $(e,t,n,r){if(e&&e.o){if(Et.has(e))return;Et.add(e),Ne.c.push(()=>{Et.delete(e),r&&(n&&e.d(1),r())}),e.o(t)}else r&&r()}function Ct(e){return(e==null?void 0:e.length)!==void 0?e:Array.from(e)}function Tn(e,t,n){const r=e.$$.props[t];r!==void 0&&(e.$$.bound[r]=n,n(e.$$.ctx[r]))}function st(e){e&&e.c()}function Xe(e,t,n){const{fragment:r,after_update:i}=e.$$;r&&r.m(t,n),qt(()=>{const o=e.$$.on_mount.map(er).filter(ct);e.$$.on_destroy?e.$$.on_destroy.push(...o):Ee(o),e.$$.on_mount=[]}),i.forEach(qt)}function We(e,t){const n=e.$$;n.fragment!==null&&(Zr(n.after_update),Ee(n.on_destroy),n.fragment&&n.fragment.d(t),n.on_destroy=n.fragment=null,n.ctx=[])}function Qr(e,t){e.$$.dirty[0]===-1&&(Ge.push(e),Wr(),e.$$.dirty.fill(0)),e.$$.dirty[t/31|0]|=1<<t%31}function fn(e,t,n,r,i,o,a=null,l=[-1]){const s=at;ot(e);const u=e.$$={fragment:null,ctx:[],props:o,update:I,not_equal:i,bound:xn(),on_mount:[],on_destroy:[],on_disconnect:[],before_update:[],after_update:[],context:new Map(t.context||(s?s.$$.context:[])),callbacks:xn(),dirty:l,skip_bound:!1,root:t.target||s.$$.root};a&&a(u.root);let c=!1;if(u.ctx=n?n(e,t.props||{},(f,h,...d)=>{const E=d.length?d[0]:h;return u.ctx&&i(u.ctx[f],u.ctx[f]=E)&&(!u.skip_bound&&u.bound[f]&&u.bound[f](E),c&&Qr(e,f)),h}):[],u.update(),c=!0,Ee(u.before_update),u.fragment=r?r(u.ctx):!1,t.target){if(t.hydrate){const f=Fr(t.target);u.fragment&&u.fragment.l(f),f.forEach(B)}else u.fragment&&u.fragment.c();t.intro&&V(e.$$.fragment),Xe(e,t.target,t.anchor),j()}ot(s)}let ir;typeof HTMLElement=="function"&&(ir=class extends HTMLElement{constructor(t,n,r){super();ae(this,"$$ctor");ae(this,"$$s");ae(this,"$$c");ae(this,"$$cn",!1);ae(this,"$$d",{});ae(this,"$$r",!1);ae(this,"$$p_d",{});ae(this,"$$l",{});ae(this,"$$l_u",new Map);this.$$ctor=t,this.$$s=n,r&&this.attachShadow({mode:"open"})}addEventListener(t,n,r){if(this.$$l[t]=this.$$l[t]||[],this.$$l[t].push(n),this.$$c){const i=this.$$c.$on(t,n);this.$$l_u.set(n,i)}super.addEventListener(t,n,r)}removeEventListener(t,n,r){if(super.removeEventListener(t,n,r),this.$$c){const i=this.$$l_u.get(n);i&&(i(),this.$$l_u.delete(n))}}connectedCallback(){return Gt(this,null,function*(){if(this.$$cn=!0,!this.$$c){let t=function(o){return()=>{let a;return{c:function(){a=T("slot"),o!=="default"&&b(a,"name",o)},m:function(u,c){H(u,a,c)},d:function(u){u&&B(a)}}}};if(yield Promise.resolve(),!this.$$cn||this.$$c)return;const n={},r=Gr(this);for(const o of this.$$s)o in r&&(n[o]=[t(o)]);for(const o of this.attributes){const a=this.$$g_p(o.name);a in this.$$d||(this.$$d[a]=xt(a,o.value,this.$$p_d,"toProp"))}for(const o in this.$$p_d)!(o in this.$$d)&&this[o]!==void 0&&(this.$$d[o]=this[o],delete this[o]);this.$$c=new this.$$ctor({target:this.shadowRoot||this,props:Ft(Ue({},this.$$d),{$$slots:n,$$scope:{ctx:[]}})});const i=()=>{this.$$r=!0;for(const o in this.$$p_d)if(this.$$d[o]=this.$$c.$$.ctx[this.$$c.$$.props[o]],this.$$p_d[o].reflect){const a=xt(o,this.$$d[o],this.$$p_d,"toAttribute");a==null?this.removeAttribute(this.$$p_d[o].attribute||o):this.setAttribute(this.$$p_d[o].attribute||o,a)}this.$$r=!1};this.$$c.$$.after_update.push(i),i();for(const o in this.$$l)for(const a of this.$$l[o]){const l=this.$$c.$on(o,a);this.$$l_u.set(a,l)}this.$$l={}}})}attributeChangedCallback(t,n,r){var i;this.$$r||(t=this.$$g_p(t),this.$$d[t]=xt(t,r,this.$$p_d,"toProp"),(i=this.$$c)==null||i.$set({[t]:this.$$d[t]}))}disconnectedCallback(){this.$$cn=!1,Promise.resolve().then(()=>{!this.$$cn&&this.$$c&&(this.$$c.$destroy(),this.$$c=void 0)})}$$g_p(t){return Object.keys(this.$$p_d).find(n=>this.$$p_d[n].attribute===t||!this.$$p_d[n].attribute&&n.toLowerCase()===t)||t}});function xt(e,t,n,r){var o;const i=(o=n[e])==null?void 0:o.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?null:t;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 pn(e,t,n,r,i,o){let a=class extends ir{constructor(){super(e,n,i),this.$$p_d=t}static get observedAttributes(){return Object.keys(t).map(l=>(t[l].attribute||l).toLowerCase())}};return Object.keys(t).forEach(l=>{Object.defineProperty(a.prototype,l,{get(){return this.$$c&&l in this.$$c?this.$$c[l]:this.$$d[l]},set(s){var u;s=xt(l,s,t),this.$$d[l]=s,(u=this.$$c)==null||u.$set({[l]:s})}})}),r.forEach(l=>{Object.defineProperty(a.prototype,l,{get(){var s;return(s=this.$$c)==null?void 0:s[l]}})}),e.element=a,a}class dn{constructor(){ae(this,"$$");ae(this,"$$set")}$destroy(){We(this,1),this.$destroy=I}$on(t,n){if(!ct(n))return I;const r=this.$$.callbacks[t]||(this.$$.callbacks[t]=[]);return r.push(n),()=>{const i=r.indexOf(n);i!==-1&&r.splice(i,1)}}$set(t){this.$$set&&!Rr(t)&&(this.$$.skip_bound=!0,this.$$set(t),this.$$.skip_bound=!1)}}const Kr="4";typeof window!="undefined"&&(window.__svelte||(window.__svelte={v:new Set})).v.add(Kr);const Fe=[];function Yr(e,t){return{subscribe:It(e,t).subscribe}}function It(e,t=I){let n;const r=new Set;function i(l){if(Pt(e,l)&&(e=l,n)){const s=!Fe.length;for(const u of r)u[1](),Fe.push(u,e);if(s){for(let u=0;u<Fe.length;u+=2)Fe[u][0](Fe[u+1]);Fe.length=0}}}function o(l){i(l(e))}function a(l,s=I){const u=[l,s];return r.add(u),r.size===1&&(n=t(i,o)||I),l(e),()=>{r.delete(u),r.size===0&&n&&(n(),n=null)}}return{set:i,update:o,subscribe:a}}function Ye(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 o=t.length<2;return Yr(n,(a,l)=>{let s=!1;const u=[];let c=0,f=I;const h=()=>{if(c)return;f();const E=t(r?u[0]:u,a,l);o?a(E):f=ct(E)?E:I},d=i.map((E,p)=>tr(E,_=>{u[p]=_,c&=~(1<<p),s&&h()},()=>{c|=1<<p}));return s=!0,h(),function(){Ee(d),f(),s=!1}})}function Jr(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var qr=function(t){return ei(t)&&!ti(t)};function ei(e){return!!e&&typeof e=="object"}function ti(e){var t=Object.prototype.toString.call(e);return t==="[object RegExp]"||t==="[object Date]"||ii(e)}var ni=typeof Symbol=="function"&&Symbol.for,ri=ni?Symbol.for("react.element"):60103;function ii(e){return e.$$typeof===ri}function oi(e){return Array.isArray(e)?[]:{}}function lt(e,t){return t.clone!==!1&&t.isMergeableObject(e)?ze(oi(e),e,t):e}function ai(e,t,n){return e.concat(t).map(function(r){return lt(r,n)})}function si(e,t){if(!t.customMerge)return ze;var n=t.customMerge(e);return typeof n=="function"?n:ze}function li(e){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(e).filter(function(t){return Object.propertyIsEnumerable.call(e,t)}):[]}function Cn(e){return Object.keys(e).concat(li(e))}function or(e,t){try{return t in e}catch(n){return!1}}function ui(e,t){return or(e,t)&&!(Object.hasOwnProperty.call(e,t)&&Object.propertyIsEnumerable.call(e,t))}function ci(e,t,n){var r={};return n.isMergeableObject(e)&&Cn(e).forEach(function(i){r[i]=lt(e[i],n)}),Cn(t).forEach(function(i){ui(e,i)||(or(e,i)&&n.isMergeableObject(t[i])?r[i]=si(i,n)(e[i],t[i],n):r[i]=lt(t[i],n))}),r}function ze(e,t,n){n=n||{},n.arrayMerge=n.arrayMerge||ai,n.isMergeableObject=n.isMergeableObject||qr,n.cloneUnlessOtherwiseSpecified=lt;var r=Array.isArray(t),i=Array.isArray(e),o=r===i;return o?r?n.arrayMerge(e,t,n):ci(e,t,n):lt(t,n)}ze.all=function(t,n){if(!Array.isArray(t))throw new Error("first argument should be an array");return t.reduce(function(r,i){return ze(r,i,n)},{})};var hi=ze,fi=hi;const pi=Jr(fi);var en=function(e,t){return en=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])},en(e,t)};function Lt(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");en(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}var ge=function(){return ge=Object.assign||function(t){for(var n,r=1,i=arguments.length;r<i;r++){n=arguments[r];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(t[o]=n[o])}return t},ge.apply(this,arguments)};function di(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 jt(e,t,n){if(n||arguments.length===2)for(var r=0,i=t.length,o;r<i;r++)(o||!(r in t))&&(o||(o=Array.prototype.slice.call(t,0,r)),o[r]=t[r]);return e.concat(o||Array.prototype.slice.call(t))}function Xt(e,t){var n=t&&t.cache?t.cache:Ei,r=t&&t.serializer?t.serializer:vi,i=t&&t.strategy?t.strategy:bi;return i(e,{cache:n,serializer:r})}function mi(e){return e==null||typeof e=="number"||typeof e=="boolean"}function gi(e,t,n,r){var i=mi(r)?r:n(r),o=t.get(i);return typeof o=="undefined"&&(o=e.call(this,r),t.set(i,o)),o}function ar(e,t,n){var r=Array.prototype.slice.call(arguments,3),i=n(r),o=t.get(i);return typeof o=="undefined"&&(o=e.apply(this,r),t.set(i,o)),o}function sr(e,t,n,r,i){return n.bind(t,e,r,i)}function bi(e,t){var n=e.length===1?gi:ar;return sr(e,this,n,t.cache.create(),t.serializer)}function yi(e,t){return sr(e,this,ar,t.cache.create(),t.serializer)}var vi=function(){return JSON.stringify(arguments)},_i=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}(),Ei={create:function(){return new _i}},Wt={variadic:yi},Bt=function(){return Bt=Object.assign||function(t){for(var n,r=1,i=arguments.length;r<i;r++){n=arguments[r];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(t[o]=n[o])}return t},Bt.apply(this,arguments)};var P;(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"})(P||(P={}));var U;(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"})(U||(U={}));var Ze;(function(e){e[e.number=0]="number",e[e.dateTime=1]="dateTime"})(Ze||(Ze={}));function Bn(e){return e.type===U.literal}function xi(e){return e.type===U.argument}function lr(e){return e.type===U.number}function ur(e){return e.type===U.date}function cr(e){return e.type===U.time}function hr(e){return e.type===U.select}function fr(e){return e.type===U.plural}function wi(e){return e.type===U.pound}function pr(e){return e.type===U.tag}function dr(e){return!!(e&&typeof e=="object"&&e.type===Ze.number)}function tn(e){return!!(e&&typeof e=="object"&&e.type===Ze.dateTime)}var mr=/[ \xA0\u1680\u2000-\u200A\u202F\u205F\u3000]/,Ai=/(?:[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 Ti(e){var t={};return e.replace(Ai,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 F=function(){return F=Object.assign||function(t){for(var n,r=1,i=arguments.length;r<i;r++){n=arguments[r];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(t[o]=n[o])}return t},F.apply(this,arguments)};var Ci=/[\t-\r \x85\u200E\u200F\u2028\u2029]/i;function Bi(e){if(e.length===0)throw new Error("Number skeleton cannot be empty");for(var t=e.split(Ci).filter(function(h){return h.length>0}),n=[],r=0,i=t;r<i.length;r++){var o=i[r],a=o.split("/");if(a.length===0)throw new Error("Invalid number skeleton");for(var l=a[0],s=a.slice(1),u=0,c=s;u<c.length;u++){var f=c[u];if(f.length===0)throw new Error("Invalid number skeleton")}n.push({stem:l,options:s})}return n}function Si(e){return e.replace(/^(.*?)-/,"")}var Sn=/^\.(?:(0+)(\*)?|(#+)|(0+)(#+))$/g,gr=/^(@+)?(\+|#+)?[rs]?$/g,Hi=/(\*)(0+)|(#+)(0+)|(0+)/g,br=/^(0+)$/;function Hn(e){var t={};return e[e.length-1]==="r"?t.roundingPriority="morePrecision":e[e.length-1]==="s"&&(t.roundingPriority="lessPrecision"),e.replace(gr,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 yr(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 Pi(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)),!br.test(e))throw new Error("Malformed concise eng/scientific notation");t.minimumIntegerDigits=e.length}return t}function Pn(e){var t={},n=yr(e);return n||t}function Ii(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=Si(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=F(F(F({},t),{notation:"scientific"}),i.options.reduce(function(s,u){return F(F({},s),Pn(u))},{}));continue;case"engineering":t=F(F(F({},t),{notation:"engineering"}),i.options.reduce(function(s,u){return F(F({},s),Pn(u))},{}));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(Hi,function(s,u,c,f,h,d){if(u)t.minimumIntegerDigits=c.length;else{if(f&&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(br.test(i.stem)){t.minimumIntegerDigits=i.stem.length;continue}if(Sn.test(i.stem)){if(i.options.length>1)throw new RangeError("Fraction-precision stems only accept a single optional option");i.stem.replace(Sn,function(s,u,c,f,h,d){return c==="*"?t.minimumFractionDigits=u.length:f&&f[0]==="#"?t.maximumFractionDigits=f.length:h&&d?(t.minimumFractionDigits=h.length,t.maximumFractionDigits=h.length+d.length):(t.minimumFractionDigits=u.length,t.maximumFractionDigits=u.length),""});var o=i.options[0];o==="w"?t=F(F({},t),{trailingZeroDisplay:"stripIfInteger"}):o&&(t=F(F({},t),Hn(o)));continue}if(gr.test(i.stem)){t=F(F({},t),Hn(i.stem));continue}var a=yr(i.stem);a&&(t=F(F({},t),a));var l=Pi(i.stem);l&&(t=F(F({},t),l))}return t}var vt={"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 Li(e,t){for(var n="",r=0;r<e.length;r++){var i=e.charAt(r);if(i==="j"){for(var o=0;r+1<e.length&&e.charAt(r+1)===i;)o++,r++;var a=1+(o&1),l=o<2?1:3+(o>>1),s="a",u=Ni(t);for((u=="H"||u=="k")&&(l=0);l-- >0;)n+=s;for(;a-- >0;)n=u+n}else i==="J"?n+="H":n+=i}return n}function Ni(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=vt[r||""]||vt[n||""]||vt["".concat(n,"-001")]||vt["001"];return i[0]}var zt,Oi=new RegExp("^".concat(mr.source,"*")),Ri=new RegExp("".concat(mr.source,"*$"));function N(e,t){return{start:e,end:t}}var ki=!!String.prototype.startsWith&&"_a".startsWith("a",1),Di=!!String.fromCodePoint,Mi=!!Object.fromEntries,Ui=!!String.prototype.codePointAt,Vi=!!String.prototype.trimStart,Fi=!!String.prototype.trimEnd,Gi=!!Number.isSafeInteger,$i=Gi?Number.isSafeInteger:function(e){return typeof e=="number"&&isFinite(e)&&Math.floor(e)===e&&Math.abs(e)<=9007199254740991},nn=!0;try{var ji=_r("([^\\p{White_Space}\\p{Pattern_Syntax}]*)","yu");nn=((zt=ji.exec("a"))===null||zt===void 0?void 0:zt[0])==="a"}catch(e){nn=!1}var In=ki?function(t,n,r){return t.startsWith(n,r)}:function(t,n,r){return t.slice(r,r+n.length)===n},rn=Di?String.fromCodePoint:function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];for(var r="",i=t.length,o=0,a;i>o;){if(a=t[o++],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},Ln=Mi?Object.fromEntries:function(t){for(var n={},r=0,i=t;r<i.length;r++){var o=i[r],a=o[0],l=o[1];n[a]=l}return n},vr=Ui?function(t,n){return t.codePointAt(n)}:function(t,n){var r=t.length;if(!(n<0||n>=r)){var i=t.charCodeAt(n),o;return i<55296||i>56319||n+1===r||(o=t.charCodeAt(n+1))<56320||o>57343?i:(i-55296<<10)+(o-56320)+65536}},Xi=Vi?function(t){return t.trimStart()}:function(t){return t.replace(Oi,"")},Wi=Fi?function(t){return t.trimEnd()}:function(t){return t.replace(Ri,"")};function _r(e,t){return new RegExp(e,t)}var on;if(nn){var Nn=_r("([^\\p{White_Space}\\p{Pattern_Syntax}]*)","yu");on=function(t,n){var r;Nn.lastIndex=n;var i=Nn.exec(t);return(r=i[1])!==null&&r!==void 0?r:""}}else on=function(t,n){for(var r=[];;){var i=vr(t,n);if(i===void 0||Er(i)||Ki(i))break;r.push(i),n+=i>=65536?2:1}return rn.apply(void 0,r)};var zi=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 o=this.char();if(o===123){var a=this.parseArgument(t,r);if(a.err)return a;i.push(a.val)}else{if(o===125&&t>0)break;if(o===35&&(n==="plural"||n==="selectordinal")){var l=this.clonePosition();this.bump(),i.push({type:U.pound,location:N(l,this.clonePosition())})}else if(o===60&&!this.ignoreTag&&this.peek()===47){if(r)break;return this.error(P.UNMATCHED_CLOSING_TAG,N(this.clonePosition(),this.clonePosition()))}else if(o===60&&!this.ignoreTag&&an(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:U.literal,value:"<".concat(i,"/>"),location:N(r,this.clonePosition())},err:null};if(this.bumpIf(">")){var o=this.parseMessage(t+1,n,!0);if(o.err)return o;var a=o.val,l=this.clonePosition();if(this.bumpIf("</")){if(this.isEOF()||!an(this.char()))return this.error(P.INVALID_TAG,N(l,this.clonePosition()));var s=this.clonePosition(),u=this.parseTagName();return i!==u?this.error(P.UNMATCHED_CLOSING_TAG,N(s,this.clonePosition())):(this.bumpSpace(),this.bumpIf(">")?{val:{type:U.tag,value:i,children:a,location:N(r,this.clonePosition())},err:null}:this.error(P.INVALID_TAG,N(l,this.clonePosition())))}else return this.error(P.UNCLOSED_TAG,N(r,this.clonePosition()))}else return this.error(P.INVALID_TAG,N(r,this.clonePosition()))},e.prototype.parseTagName=function(){var t=this.offset();for(this.bump();!this.isEOF()&&Qi(this.char());)this.bump();return this.message.slice(t,this.offset())},e.prototype.parseLiteral=function(t,n){for(var r=this.clonePosition(),i="";;){var o=this.tryParseQuote(n);if(o){i+=o;continue}var a=this.tryParseUnquoted(t,n);if(a){i+=a;continue}var l=this.tryParseLeftAngleBracket();if(l){i+=l;continue}break}var s=N(r,this.clonePosition());return{val:{type:U.literal,value:i,location:s},err:null}},e.prototype.tryParseLeftAngleBracket=function(){return!this.isEOF()&&this.char()===60&&(this.ignoreTag||!Zi(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 rn.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(),rn(r))},e.prototype.parseArgument=function(t,n){var r=this.clonePosition();if(this.bump(),this.bumpSpace(),this.isEOF())return this.error(P.EXPECT_ARGUMENT_CLOSING_BRACE,N(r,this.clonePosition()));if(this.char()===125)return this.bump(),this.error(P.EMPTY_ARGUMENT,N(r,this.clonePosition()));var i=this.parseIdentifierIfPossible().value;if(!i)return this.error(P.MALFORMED_ARGUMENT,N(r,this.clonePosition()));if(this.bumpSpace(),this.isEOF())return this.error(P.EXPECT_ARGUMENT_CLOSING_BRACE,N(r,this.clonePosition()));switch(this.char()){case 125:return this.bump(),{val:{type:U.argument,value:i,location:N(r,this.clonePosition())},err:null};case 44:return this.bump(),this.bumpSpace(),this.isEOF()?this.error(P.EXPECT_ARGUMENT_CLOSING_BRACE,N(r,this.clonePosition())):this.parseArgumentOptions(t,n,i,r);default:return this.error(P.MALFORMED_ARGUMENT,N(r,this.clonePosition()))}},e.prototype.parseIdentifierIfPossible=function(){var t=this.clonePosition(),n=this.offset(),r=on(this.message,n),i=n+r.length;this.bumpTo(i);var o=this.clonePosition(),a=N(t,o);return{value:r,location:a}},e.prototype.parseArgumentOptions=function(t,n,r,i){var o,a=this.clonePosition(),l=this.parseIdentifierIfPossible().value,s=this.clonePosition();switch(l){case"":return this.error(P.EXPECT_ARGUMENT_TYPE,N(a,s));case"number":case"date":case"time":{this.bumpSpace();var u=null;if(this.bumpIf(",")){this.bumpSpace();var c=this.clonePosition(),f=this.parseSimpleArgStyleIfPossible();if(f.err)return f;var h=Wi(f.val);if(h.length===0)return this.error(P.EXPECT_ARGUMENT_STYLE,N(this.clonePosition(),this.clonePosition()));var d=N(c,this.clonePosition());u={style:h,styleLocation:d}}var E=this.tryParseArgumentClose(i);if(E.err)return E;var p=N(i,this.clonePosition());if(u&&In(u==null?void 0:u.style,"::",0)){var _=Xi(u.style.slice(2));if(l==="number"){var f=this.parseNumberSkeletonFromString(_,u.styleLocation);return f.err?f:{val:{type:U.number,value:r,location:p,style:f.val},err:null}}else{if(_.length===0)return this.error(P.EXPECT_DATE_TIME_SKELETON,p);var y=_;this.locale&&(y=Li(_,this.locale));var h={type:Ze.dateTime,pattern:y,location:u.styleLocation,parsedOptions:this.shouldParseSkeletons?Ti(y):{}},L=l==="date"?U.date:U.time;return{val:{type:L,value:r,location:p,style:h},err:null}}}return{val:{type:l==="number"?U.number:l==="date"?U.date:U.time,value:r,location:p,style:(o=u==null?void 0:u.style)!==null&&o!==void 0?o:null},err:null}}case"plural":case"selectordinal":case"select":{var C=this.clonePosition();if(this.bumpSpace(),!this.bumpIf(","))return this.error(P.EXPECT_SELECT_ARGUMENT_OPTIONS,N(C,Bt({},C)));this.bumpSpace();var Z=this.parseIdentifierIfPossible(),k=0;if(l!=="select"&&Z.value==="offset"){if(!this.bumpIf(":"))return this.error(P.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE,N(this.clonePosition(),this.clonePosition()));this.bumpSpace();var f=this.tryParseDecimalInteger(P.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE,P.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE);if(f.err)return f;this.bumpSpace(),Z=this.parseIdentifierIfPossible(),k=f.val}var ne=this.tryParsePluralOrSelectOptions(t,l,n,Z);if(ne.err)return ne;var E=this.tryParseArgumentClose(i);if(E.err)return E;var oe=N(i,this.clonePosition());return l==="select"?{val:{type:U.select,value:r,options:Ln(ne.val),location:oe},err:null}:{val:{type:U.plural,value:r,options:Ln(ne.val),offset:k,pluralType:l==="plural"?"cardinal":"ordinal",location:oe},err:null}}default:return this.error(P.INVALID_ARGUMENT_TYPE,N(a,s))}},e.prototype.tryParseArgumentClose=function(t){return this.isEOF()||this.char()!==125?this.error(P.EXPECT_ARGUMENT_CLOSING_BRACE,N(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(P.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE,N(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=Bi(t)}catch(i){return this.error(P.INVALID_NUMBER_SKELETON,n)}return{val:{type:Ze.number,tokens:r,location:n,parsedOptions:this.shouldParseSkeletons?Ii(r):{}},err:null}},e.prototype.tryParsePluralOrSelectOptions=function(t,n,r,i){for(var o,a=!1,l=[],s=new Set,u=i.value,c=i.location;;){if(u.length===0){var f=this.clonePosition();if(n!=="select"&&this.bumpIf("=")){var h=this.tryParseDecimalInteger(P.EXPECT_PLURAL_ARGUMENT_SELECTOR,P.INVALID_PLURAL_ARGUMENT_SELECTOR);if(h.err)return h;c=N(f,this.clonePosition()),u=this.message.slice(f.offset,this.offset())}else break}if(s.has(u))return this.error(n==="select"?P.DUPLICATE_SELECT_ARGUMENT_SELECTOR:P.DUPLICATE_PLURAL_ARGUMENT_SELECTOR,c);u==="other"&&(a=!0),this.bumpSpace();var d=this.clonePosition();if(!this.bumpIf("{"))return this.error(n==="select"?P.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT:P.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT,N(this.clonePosition(),this.clonePosition()));var E=this.parseMessage(t+1,n,r);if(E.err)return E;var p=this.tryParseArgumentClose(d);if(p.err)return p;l.push([u,{value:E.val,location:N(d,this.clonePosition())}]),s.add(u),this.bumpSpace(),o=this.parseIdentifierIfPossible(),u=o.value,c=o.location}return l.length===0?this.error(n==="select"?P.EXPECT_SELECT_ARGUMENT_SELECTOR:P.EXPECT_PLURAL_ARGUMENT_SELECTOR,N(this.clonePosition(),this.clonePosition())):this.requiresOtherClause&&!a?this.error(P.MISSING_OTHER_CLAUSE,N(this.clonePosition(),this.clonePosition())):{val:l,err:null}},e.prototype.tryParseDecimalInteger=function(t,n){var r=1,i=this.clonePosition();this.bumpIf("+")||this.bumpIf("-")&&(r=-1);for(var o=!1,a=0;!this.isEOF();){var l=this.char();if(l>=48&&l<=57)o=!0,a=a*10+(l-48),this.bump();else break}var s=N(i,this.clonePosition());return o?(a*=r,$i(a)?{val:a,err:null}:this.error(n,s)):this.error(t,s)},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=vr(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(In(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()&&Er(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?r:null},e}();function an(e){return e>=97&&e<=122||e>=65&&e<=90}function Zi(e){return an(e)||e===47}function Qi(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 Er(e){return e>=9&&e<=13||e===32||e===133||e>=8206&&e<=8207||e===8232||e===8233}function Ki(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 sn(e){e.forEach(function(t){if(delete t.location,hr(t)||fr(t))for(var n in t.options)delete t.options[n].location,sn(t.options[n].value);else lr(t)&&dr(t.style)||(ur(t)||cr(t))&&tn(t.style)?delete t.style.location:pr(t)&&sn(t.children)})}function Yi(e,t){t===void 0&&(t={}),t=Bt({shouldParseSkeletons:!0,requiresOtherClause:!0},t);var n=new zi(e,t).parse();if(n.err){var r=SyntaxError(P[n.err.kind]);throw r.location=n.err.location,r.originalMessage=n.err.message,r}return t!=null&&t.captureLocation||sn(n.val),n.val}var Qe;(function(e){e.MISSING_VALUE="MISSING_VALUE",e.INVALID_VALUE="INVALID_VALUE",e.MISSING_INTL_API="MISSING_INTL_API"})(Qe||(Qe={}));var Nt=function(e){Lt(t,e);function t(n,r,i){var o=e.call(this,n)||this;return o.code=r,o.originalMessage=i,o}return t.prototype.toString=function(){return"[formatjs Error: ".concat(this.code,"] ").concat(this.message)},t}(Error),On=function(e){Lt(t,e);function t(n,r,i,o){return e.call(this,'Invalid values for "'.concat(n,'": "').concat(r,'". Options are "').concat(Object.keys(i).join('", "'),'"'),Qe.INVALID_VALUE,o)||this}return t}(Nt),Ji=function(e){Lt(t,e);function t(n,r,i){return e.call(this,'Value for "'.concat(n,'" must be of type ').concat(r),Qe.INVALID_VALUE,i)||this}return t}(Nt),qi=function(e){Lt(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,'"'),Qe.MISSING_VALUE,r)||this}return t}(Nt),Y;(function(e){e[e.literal=0]="literal",e[e.object=1]="object"})(Y||(Y={}));function eo(e){return e.length<2?e:e.reduce(function(t,n){var r=t[t.length-1];return!r||r.type!==Y.literal||n.type!==Y.literal?t.push(n):r.value+=n.value,t},[])}function to(e){return typeof e=="function"}function wt(e,t,n,r,i,o,a){if(e.length===1&&Bn(e[0]))return[{type:Y.literal,value:e[0].value}];for(var l=[],s=0,u=e;s<u.length;s++){var c=u[s];if(Bn(c)){l.push({type:Y.literal,value:c.value});continue}if(wi(c)){typeof o=="number"&&l.push({type:Y.literal,value:n.getNumberFormat(t).format(o)});continue}var f=c.value;if(!(i&&f in i))throw new qi(f,a);var h=i[f];if(xi(c)){(!h||typeof h=="string"||typeof h=="number")&&(h=typeof h=="string"||typeof h=="number"?String(h):""),l.push({type:typeof h=="string"?Y.literal:Y.object,value:h});continue}if(ur(c)){var d=typeof c.style=="string"?r.date[c.style]:tn(c.style)?c.style.parsedOptions:void 0;l.push({type:Y.literal,value:n.getDateTimeFormat(t,d).format(h)});continue}if(cr(c)){var d=typeof c.style=="string"?r.time[c.style]:tn(c.style)?c.style.parsedOptions:r.time.medium;l.push({type:Y.literal,value:n.getDateTimeFormat(t,d).format(h)});continue}if(lr(c)){var d=typeof c.style=="string"?r.number[c.style]:dr(c.style)?c.style.parsedOptions:void 0;d&&d.scale&&(h=h*(d.scale||1)),l.push({type:Y.literal,value:n.getNumberFormat(t,d).format(h)});continue}if(pr(c)){var E=c.children,p=c.value,_=i[p];if(!to(_))throw new Ji(p,"function",a);var y=wt(E,t,n,r,i,o),L=_(y.map(function(k){return k.value}));Array.isArray(L)||(L=[L]),l.push.apply(l,L.map(function(k){return{type:typeof k=="string"?Y.literal:Y.object,value:k}}))}if(hr(c)){var C=c.options[h]||c.options.other;if(!C)throw new On(c.value,h,Object.keys(c.options),a);l.push.apply(l,wt(C.value,t,n,r,i));continue}if(fr(c)){var C=c.options["=".concat(h)];if(!C){if(!Intl.PluralRules)throw new Nt(`Intl.PluralRules is not available in this environment.
|
|
2
|
+
Try polyfilling it using "@formatjs/intl-pluralrules"
|
|
3
|
+
`,Qe.MISSING_INTL_API,a);var Z=n.getPluralRules(t,{type:c.pluralType}).select(h-(c.offset||0));C=c.options[Z]||c.options.other}if(!C)throw new On(c.value,h,Object.keys(c.options),a);l.push.apply(l,wt(C.value,t,n,r,i,h-(c.offset||0)));continue}}return eo(l)}function no(e,t){return t?ge(ge(ge({},e||{}),t||{}),Object.keys(e).reduce(function(n,r){return n[r]=ge(ge({},e[r]),t[r]||{}),n},{})):e}function ro(e,t){return t?Object.keys(e).reduce(function(n,r){return n[r]=no(e[r],t[r]),n},ge({},e)):e}function Zt(e){return{create:function(){return{get:function(t){return e[t]},set:function(t,n){e[t]=n}}}}}function io(e){return e===void 0&&(e={number:{},dateTime:{},pluralRules:{}}),{getNumberFormat:Xt(function(){for(var t,n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];return new((t=Intl.NumberFormat).bind.apply(t,jt([void 0],n,!1)))},{cache:Zt(e.number),strategy:Wt.variadic}),getDateTimeFormat:Xt(function(){for(var t,n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];return new((t=Intl.DateTimeFormat).bind.apply(t,jt([void 0],n,!1)))},{cache:Zt(e.dateTime),strategy:Wt.variadic}),getPluralRules:Xt(function(){for(var t,n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];return new((t=Intl.PluralRules).bind.apply(t,jt([void 0],n,!1)))},{cache:Zt(e.pluralRules),strategy:Wt.variadic})}}var oo=function(){function e(t,n,r,i){n===void 0&&(n=e.defaultLocale);var o=this;if(this.formatterCache={number:{},dateTime:{},pluralRules:{}},this.format=function(s){var u=o.formatToParts(s);if(u.length===1)return u[0].value;var c=u.reduce(function(f,h){return!f.length||h.type!==Y.literal||typeof f[f.length-1]!="string"?f.push(h.value):f[f.length-1]+=h.value,f},[]);return c.length<=1?c[0]||"":c},this.formatToParts=function(s){return wt(o.ast,o.locales,o.formatters,o.formats,s,void 0,o.message)},this.resolvedOptions=function(){var s;return{locale:((s=o.resolvedLocale)===null||s===void 0?void 0:s.toString())||Intl.NumberFormat.supportedLocalesOf(o.locales)[0]}},this.getAst=function(){return o.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 l=di(a,["formatters"]);this.ast=e.__parse(t,ge(ge({},l),{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=ro(e.formats,r),this.formatters=i&&i.formatters||io(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!="undefined"){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=Yi,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 ao(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 o=n.slice(i,n.length).join(".");if(o in r){r=r[o];break}}r=r[n[i]]}else r=void 0;return r}const Be={},so=(e,t,n)=>n&&(t in Be||(Be[t]={}),e in Be[t]||(Be[t][e]=n),n),xr=(e,t)=>{if(t==null)return;if(t in Be&&e in Be[t])return Be[t][e];const n=Ot(t);for(let r=0;r<n.length;r++){const i=n[r],o=uo(i,e);if(o)return so(e,t,o)}};let mn;const Je=It({});function lo(e){return mn[e]||null}function wr(e){return e in mn}function uo(e,t){if(!wr(e))return null;const n=lo(e);return ao(n,t)}function co(e){if(e==null)return;const t=Ot(e);for(let n=0;n<t.length;n++){const r=t[n];if(wr(r))return r}}function Ar(e,...t){delete Be[e],Je.update(n=>(n[e]=pi.all([n[e]||{},...t]),n))}Ye([Je],([e])=>Object.keys(e));Je.subscribe(e=>mn=e);const At={};function ho(e,t){At[e].delete(t),At[e].size===0&&delete At[e]}function Tr(e){return At[e]}function fo(e){return Ot(e).map(t=>{const n=Tr(t);return[t,n?[...n]:[]]}).filter(([,t])=>t.length>0)}function ln(e){return e==null?!1:Ot(e).some(t=>{var n;return(n=Tr(t))==null?void 0:n.size})}function po(e,t){return Promise.all(t.map(r=>(ho(e,r),r().then(i=>i.default||i)))).then(r=>Ar(e,...r))}const it={};function Cr(e){if(!ln(e))return e in it?it[e]:Promise.resolve();const t=fo(e);return it[e]=Promise.all(t.map(([n,r])=>po(n,r))).then(()=>{if(ln(e))return Cr(e);delete it[e]}),it[e]}const mo={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"}}},go={fallbackLocale:null,loadingDelay:200,formats:mo,warnOnMissingMessages:!0,handleMissingMessage:void 0,ignoreTag:!0},bo=go;function Ke(){return bo}const Qt=It(!1);var yo=Object.defineProperty,vo=Object.defineProperties,_o=Object.getOwnPropertyDescriptors,Rn=Object.getOwnPropertySymbols,Eo=Object.prototype.hasOwnProperty,xo=Object.prototype.propertyIsEnumerable,kn=(e,t,n)=>t in e?yo(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,wo=(e,t)=>{for(var n in t||(t={}))Eo.call(t,n)&&kn(e,n,t[n]);if(Rn)for(var n of Rn(t))xo.call(t,n)&&kn(e,n,t[n]);return e},Ao=(e,t)=>vo(e,_o(t));let un;const St=It(null);function Dn(e){return e.split("-").map((t,n,r)=>r.slice(0,n+1).join("-")).reverse()}function Ot(e,t=Ke().fallbackLocale){const n=Dn(e);return t?[...new Set([...n,...Dn(t)])]:n}function Oe(){return un!=null?un:void 0}St.subscribe(e=>{un=e!=null?e:void 0,typeof window!="undefined"&&e!=null&&document.documentElement.setAttribute("lang",e)});const To=e=>{if(e&&co(e)&&ln(e)){const{loadingDelay:t}=Ke();let n;return typeof window!="undefined"&&Oe()!=null&&t?n=window.setTimeout(()=>Qt.set(!0),t):Qt.set(!0),Cr(e).then(()=>{St.set(e)}).finally(()=>{clearTimeout(n),Qt.set(!1)})}return St.set(e)},Pe=Ao(wo({},St),{set:To}),Rt=e=>{const t=Object.create(null);return r=>{const i=JSON.stringify(r);return i in t?t[i]:t[i]=e(r)}};var Co=Object.defineProperty,Ht=Object.getOwnPropertySymbols,Br=Object.prototype.hasOwnProperty,Sr=Object.prototype.propertyIsEnumerable,Mn=(e,t,n)=>t in e?Co(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,gn=(e,t)=>{for(var n in t||(t={}))Br.call(t,n)&&Mn(e,n,t[n]);if(Ht)for(var n of Ht(t))Sr.call(t,n)&&Mn(e,n,t[n]);return e},qe=(e,t)=>{var n={};for(var r in e)Br.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&Ht)for(var r of Ht(e))t.indexOf(r)<0&&Sr.call(e,r)&&(n[r]=e[r]);return n};const ut=(e,t)=>{const{formats:n}=Ke();if(e in n&&t in n[e])return n[e][t];throw new Error(`[svelte-i18n] Unknown "${t}" ${e} format.`)},Bo=Rt(e=>{var t=e,{locale:n,format:r}=t,i=qe(t,["locale","format"]);if(n==null)throw new Error('[svelte-i18n] A "locale" must be set to format numbers');return r&&(i=ut("number",r)),new Intl.NumberFormat(n,i)}),So=Rt(e=>{var t=e,{locale:n,format:r}=t,i=qe(t,["locale","format"]);if(n==null)throw new Error('[svelte-i18n] A "locale" must be set to format dates');return r?i=ut("date",r):Object.keys(i).length===0&&(i=ut("date","short")),new Intl.DateTimeFormat(n,i)}),Ho=Rt(e=>{var t=e,{locale:n,format:r}=t,i=qe(t,["locale","format"]);if(n==null)throw new Error('[svelte-i18n] A "locale" must be set to format time values');return r?i=ut("time",r):Object.keys(i).length===0&&(i=ut("time","short")),new Intl.DateTimeFormat(n,i)}),Po=(e={})=>{var t=e,{locale:n=Oe()}=t,r=qe(t,["locale"]);return Bo(gn({locale:n},r))},Io=(e={})=>{var t=e,{locale:n=Oe()}=t,r=qe(t,["locale"]);return So(gn({locale:n},r))},Lo=(e={})=>{var t=e,{locale:n=Oe()}=t,r=qe(t,["locale"]);return Ho(gn({locale:n},r))},No=Rt((e,t=Oe())=>new oo(e,t,Ke().formats,{ignoreTag:Ke().ignoreTag})),Oo=(e,t={})=>{var n,r,i,o;let a=t;typeof e=="object"&&(a=e,e=a.id);const{values:l,locale:s=Oe(),default:u}=a;if(s==null)throw new Error("[svelte-i18n] Cannot format a message without first setting the initial locale.");let c=xr(e,s);if(!c)c=(o=(i=(r=(n=Ke()).handleMissingMessage)==null?void 0:r.call(n,{locale:s,id:e,defaultValue:u}))!=null?i:u)!=null?o:e;else if(typeof c!="string")return console.warn(`[svelte-i18n] Message with id "${e}" must be of type "string", found: "${typeof c}". Gettin its value through the "$format" method is deprecated; use the "json" method instead.`),c;if(!l)return c;let f=c;try{f=No(c,s).format(l)}catch(h){h instanceof Error&&console.warn(`[svelte-i18n] Message "${e}" has syntax error:`,h.message)}return f},Ro=(e,t)=>Lo(t).format(e),ko=(e,t)=>Io(t).format(e),Do=(e,t)=>Po(t).format(e),Mo=(e,t=Oe())=>xr(e,t),Uo=Ye([Pe,Je],()=>Oo);Ye([Pe],()=>Ro);Ye([Pe],()=>ko);Ye([Pe],()=>Do);Ye([Pe,Je],()=>Mo);function Vo({withLocale:e,translations:t}){Pe.subscribe(n=>{n==null&&(Je.set(t),Pe.set(e))})}function Un(e,t){Ar(e,t)}function Fo(e){Pe.set(e)}const M=kr(Uo),Vn={en:{vaultExchange:"Vault Exchange",debitPlaceHolder:"Debit amount",creditPlaceHolder:"Credit amount",totalBalance:"Total balance",currentBalance:"Balance",balanceUnavailable:"Balance unavailable. Please try again.",exchangeFrom:"From",exchangeTo:"To",creditAmount:"Credit Amount",debitAmount:"Debit Amount",exchange:"Exchange",accept:"Accept",decline:"Decline",reset:"Reset",select:"Select",exchangeSuccess:"Exchange completed successfully!",feesIncluded:"Fees included",feesUnavailable:"Fees unavailable.",invalidValue:"Invalid value",exceededValue:"Amount exceeds balance",generalError:"An error occurred during the wallet exchange. Please try again.",InvalidSession:"Invalid session. Please try again.",1001:"A technical error occurred. Please try again later.",1002:"A database error occurred. Please try again later.",1003:"Invalid parameters provided. Please check your input.",1004:"No changes were detected.",1005:"The data was updated by someone else. Please try again.",1006:"An API error occurred. Please try again later.",1007:"The request timed out. Please try again later.",1008:"Failed to acquire necessary lock. Please try again.",1009:"This feature is currently not enabled.",1010:"Database connection timed out. Please try again later.",1011:"Database command timed out. Please try again later.",1012:"Database is not properly configured. Please contact support.",1013:"Failed to update internal state. Please try again.",1103:"A transaction error occurred. Please try again later.",1105:"Wallet not found.",1504:"You are not permitted to perform this action.",1506:"Fee has been invalidated. Please recalculate.",1507:"This fee addition type is not supported.",1508:"Insufficient funds to apply the fee.",10101:"An unknown technical error occurred.",10102:"User is blocked from performing this action.",10103:"User not found.",10104:"Insufficient funds to withdraw. Requested amount is greater than available balance.",10106:"The selected currency is not supported.",10107:"Transaction is currently being processed. Please wait.",10108:"Transaction not found.",10113:"User is self-excluded. Action cannot be performed.",10114:"User account is not active.",10115:"Transaction intent not found."},tr:{vaultExchange:"Kasa Değişimi",debitPlaceHolder:"Borç miktarı",creditPlaceHolder:"Alacak miktarı",totalBalance:"Toplam bakiye",currentBalance:"Bakiye",balanceUnavailable:"Bakiye kullanılamıyor. Lütfen tekrar deneyin.",exchangeFrom:"Şuradan Değiştir",exchangeTo:"Şuraya Değiştir",creditAmount:"Kredi Tutarı",debitAmount:"Borç Tutarı",exchange:"Değiştir",accept:"Kabul etmek",decline:"Reddetmek",reset:"Sıfırla",select:"Seç",feesIncluded:"Ücretler dahil",feesUnavailable:"Ücretler mevcut değil.",exchangeSuccess:"Değişim başarıyla tamamlandı!",invalidValue:"Geçersiz değer",exceededValue:"Tutar, bakiyeyi aşıyor",generalError:"Cüzdan değişimi sırasında bir hata oluştu. Lütfen tekrar deneyin.",InvalidSession:"Geçersiz oturum. Lütfen tekrar deneyin.",1001:"Bir teknik hata oluştu. Lütfen daha sonra tekrar deneyin.",1002:"Bir veritabanı hatası oluştu. Lütfen daha sonra tekrar deneyin.",1003:"Geçersiz parametreler sağlandı. Lütfen girdilerinizi kontrol edin.",1004:"Herhangi bir değişiklik tespit edilmedi.",1005:"Veri başka biri tarafından güncellendi. Lütfen tekrar deneyin.",1006:"Bir API hatası oluştu. Lütfen daha sonra tekrar deneyin.",1007:"İstek zaman aşımına uğradı. Lütfen daha sonra tekrar deneyin.",1008:"Gerekli kilit alınamadı. Lütfen tekrar deneyin.",1009:"Bu özellik şu anda etkin değil.",1010:"Veritabanı bağlantısı zaman aşımına uğradı. Lütfen daha sonra tekrar deneyin.",1011:"Veritabanı komutu zaman aşımına uğradı. Lütfen daha sonra tekrar deneyin.",1012:"Veritabanı düzgün yapılandırılmamış. Lütfen destek ile iletişime geçin.",1013:"İç durum güncellenemedi. Lütfen tekrar deneyin.",1103:"Bir işlem hatası oluştu. Lütfen daha sonra tekrar deneyin.",1105:"Cüzdan bulunamadı.",1504:"Bu işlemi gerçekleştirme izniniz yok.",1506:"Ücret geçersiz hale getirildi. Lütfen yeniden hesaplayın.",1507:"Bu ücret ekleme türü desteklenmiyor.",1508:"Ücreti uygulamak için yetersiz bakiye.",10101:"Bilinmeyen bir teknik hata oluştu.",10102:"Kullanıcı bu işlemi gerçekleştirmekten engellenmiştir.",10103:"Kullanıcı bulunamadı.",10104:"Yetersiz bakiye. Talep edilen tutar, mevcut bakiyeden fazladır.",10106:"Seçilen para birimi desteklenmiyor.",10107:"İşlem şu anda işleniyor. Lütfen bekleyin.",10108:"İşlem bulunamadı.",10113:"Kullanıcı kendini dışladı. İşlem gerçekleştirilemez.",10114:"Kullanıcı hesabı aktif değil.",10115:"İşlem niyeti bulunamadı."}},Go={"1INCH":"",AAVE:"",ADA:"₳",ADF:"",ADP:"",AED:"د.إ",AFN:"؋",ALGO:"Ⱥ",ALL:"L",AMD:"Դ",AMP:"",ANG:"ƒ",AOA:"Kz",AQAQAAUKXMYQOUSOUJHLTNBOI:"",AQAQAAUXKBXDCWFVEDYIDYHWD:"",AQAQADPGMAZQICGIVARVFRSQS:"",AQAQAFDJIKCUBVVVGVQNBWRDX:"",AQAQAFMRIPFFPCHYHKSGDDGOF:"",AQAQAFRMNSQNCLRLEJGEIDLDO:"",AQAQAJMRAJIZSQTNLYHHJNUIA:"",AQAQAOLFQBZJAPJMVXZDAXXKJ:"",AR:"",ARS:"$",ATOM:"",AUD:"$",AVAX:"",AWG:"ƒ",AXS:"",AZN:"₼",BAM:"KM",BAT:"",BBD:"$",BCH:"Ƀ",BDT:"৳",BGN:"лв",BHD:"ب.د",BIF:"",BMD:"$",BNB:"",BND:"$",BOB:"$b",BORA:"",BRL:"R$",BSD:"$",BSV:"Ɓ",BTC:"₿",BTCB:"",BTN:"Nu.",BTT:"",BUSD:"₮",BWP:"P",BYN:"Br",BYR:"",BZD:"BZ$",CAD:"$",CAKE:"",CDF:"",CEL:"",CELO:"",CHF:"CHF",CHZ:"",CLP:"$",CNY:"¥",COMP:"",COP:"$",CRC:"₡",CRO:"",CRV:"",CUC:"",CUP:"₱",CVE:"",CZK:"Kč",DAI:"◈",DASH:"Đ",DCR:"",DJF:"",DKK:"kr",DOGE:"Ð",DOP:"RD$",DOT:"●",DZD:"د.ج",EEK:"",EGLD:"",EGP:"£",ELON:"",ENJ:"",EOS:"ε",ETB:"",ETC:"ξ",ETH:"Ξ",EUR:"€",FIL:"⨎",FJD:"$",FKP:"£",FLOW:"",FTM:"",FTT:"",FUN:"",GALA:"",GBP:"£",GCC:"",GEL:"",GHS:"¢",GIP:"£",GMD:"",GNF:"",GRT:"",GTQ:"Q",GYD:"$",HBAR:"",HKD:"$",HNL:"L",HNT:"",HOT:"",HRK:"",HT:"",HTG:"",HUF:"Ft",ICP:"∞",ICX:"",IDR:"Rp",ILS:"₪",INR:"₹",IOTX:"",IQD:"د.ع",IRR:"﷼",ISK:"kr",JMD:"J$",JOD:"د.ا",JPY:"¥",KCS:"",KDA:"",KES:"KSh",KGS:"лв",KHR:"៛",KLAY:"",KPW:"₩",KRW:"₩",KSM:"",KWD:"د.ك",KYD:"$",KZT:"лв",LAK:"₭",LBP:"£",LEO:"",LINK:"",LKR:"₨",LPT:"",LRC:"",LRD:"$",LSL:"",LTC:"Ł",LTL:"",LUNA:"",LVL:"",LYD:"د.ل",MAD:"د.م",MANA:"",MATIC:"",MDL:"",MGA:"",MINA:"",MIOTA:"ɨ",MKD:"ден",MKR:"Μ",MMK:"",MNT:"₮",MOP:"",MRO:"",MUR:"₨",MVR:"",MWK:"",MXN:"$",MYR:"RM",MZN:"MT",NAD:"$",NEAR:"",NEO:"",NEXO:"",NGN:"₦",NIO:"C$",NOK:"kr",NPR:"₨",NZD:"$",OKB:"",OMG:"",OMR:"﷼",ONE:"",PAB:"B/.",PEN:"S/.",PGK:"",PHP:"₱",PKR:"₨",PLN:"zł",PYG:"₲",QAR:"﷼",QNT:"",QTUM:"",RON:"lei",ROSE:"",RSD:"Дин.",RUB:"₽",RUNE:"",RVN:"",RWF:"",SAND:"",SAR:"﷼",SBD:"$",SCC:"",SCR:"₨",SDG:"د.س",SEK:"kr",SGD:"$",SHIB:"",SHP:"£",SLL:"",SOL:"",SOS:"S",SRD:"$",STD:"",STX:"",SUSHI:"",SVC:"$",SYP:"£",SZL:"",TES:"",TFUEL:"",THB:"฿",THETA:"ϑ",TJS:"",TMT:"",TND:"د.ت",TOP:"",TRX:"",TRY:"₺",TTD:"TT$",TUSD:"",TWD:"NT$",TZS:"",UAH:"₴",UGX:"",UNI:"",USD:"$",USDC:"",USDT:"₮",UST:"",UYU:"$U",UZS:"лв",VEF:"",VES:"Bs",VET:"",VND:"₫",VUV:"",WAVES:"",WBTC:"₿",WST:"",XAF:"",XCD:"$",XDC:"",XEC:"",XEM:"",XFUN:"",XLM:"✕",XMR:"ɱ",XOF:"",XPF:"",XRP:"✕",XTZ:"ꜩ",YER:"﷼",YFI:"",ZAR:"R",ZEC:"ⓩ",ZMK:"",ZMW:"",ZWD:"Z$"},$o=6e3,jo={InvalidSession:"Invalid session"},z={BalanceError:"BalanceError",CheckWalletExchangeError:"CheckWalletExchangeError",WalletExchangeError:"WalletExchangeError",CurrenciesError:"CurrenciesError"},Fn={ResetVaultWidget:"ResetVaultWidget",CloseVaultWidget:"CloseVaultWidget"},Kt={VaultWidgetReset:"VaultWidgetReset",VaultWidgetClosed:"VaultWidgetClosed",VaultDropdownToggled:"VaultDropdownToggled"},Gn={Real:"Real",Vault:"Vault"},Ce={success:"success",error:"error"},Xo=String(Number.MAX_SAFE_INTEGER)+1,_t={ArrowDown:"ArrowDown",ArrowUp:"ArrowUp",Enter:"Enter",Escape:"Escape"};function Wo(e,t){let n;return function(...r){n&&clearTimeout(n),n=setTimeout(()=>{e.apply(r)},t)}}const $n=(e,t=null,n=2)=>{try{return JSON.stringify(e,t,n)}catch(r){return console.warn("Failed to stringify:",r),null}};function zo(e){const t=n=>{e.contains(n.target)||e.dispatchEvent(new CustomEvent("outclick"))};return document.addEventListener("click",t),{destroy(){document.removeEventListener("click",t)}}}function Zo(e){hn(e,"svelte-1fe9nk9",".selectWrapper.svelte-1fe9nk9.svelte-1fe9nk9{position:relative;min-width:96px;font-family:inherit;height:var(--emw--base-height, 36px);font-size:var(--emw--font-size-small, 12px);border-radius:var(--emw--border-radius-small, 8px)}.selectButton.svelte-1fe9nk9.svelte-1fe9nk9{width:100%;height:100%;cursor:pointer;text-align:left;border:unset;display:flex;align-items:center;justify-content:space-between;background-color:rgba(255, 255, 255, var(--emw--background-opacity, 0.9));-webkit-backdrop-filter:blur(var(--emw--filter-blur, 31.5px));backdrop-filter:blur(var(--emw--filter-blur, 31.5px));padding:0 var(--emw--spacing-small, 10px);font-size:var(--emw--font-size-small, 12px);border-radius:var(--emw--border-radius-small, 8px);font-family:inherit}.label.svelte-1fe9nk9.svelte-1fe9nk9{display:flex;align-items:center}.selectDropdown.svelte-1fe9nk9.svelte-1fe9nk9{position:absolute;top:calc(100% + 2px);left:0;right:0;display:flex;flex-direction:column;gap:4px;max-height:200px;overflow-y:auto;scrollbar-width:thin;z-index:100;background-color:rgba(255, 255, 255, var(--emw--background-opacity, 0.9));-webkit-backdrop-filter:blur(var(--emw--filter-blur, 31.5px));backdrop-filter:blur(var(--emw--filter-blur, 31.5px));border-radius:var(--emw--border-radius-small, 8px)}.selectDropdown.svelte-1fe9nk9 li.svelte-1fe9nk9{height:24px;flex:0 0 24px;display:flex;align-items:center;;;padding:0 var(--emw--spacing-small, 10px);cursor:pointer;transition:all 0.3s ease}.selectDropdown.svelte-1fe9nk9 li.svelte-1fe9nk9:hover,.selectDropdown.svelte-1fe9nk9 li.active.svelte-1fe9nk9{background:var(--emw--selected-option, var(--emw-w-color-gray-150, #f0f0f0))}.symbol.svelte-1fe9nk9.svelte-1fe9nk9{display:inline-flex;width:1rem;height:1rem;border-radius:50%;align-items:center;justify-content:center;line-height:0;margin-right:5px;overflow:hidden;background:var(--emw-typography, var(--emw-w-color-gray-450, #595959));font-size:var(--emw--font-size-small, 12px);color:var(--emw--button-typography, var(--emw--color-white, #fff))}")}function jn(e,t,n){const r=e.slice();return r[14]=t[n],r[16]=n,r}function Xn(e){var i;let t,n=(((i=e[0])==null?void 0:i.symbol)||"")+"",r;return{c(){t=T("span"),r=W(n),b(t,"class","symbol svelte-1fe9nk9")},m(o,a){H(o,t,a),v(t,r)},p(o,a){var l;a&1&&n!==(n=(((l=o[0])==null?void 0:l.symbol)||"")+"")&&te(r,n)},d(o){o&&B(t)}}}function Wn(e){let t,n=Ct(e[1]),r=[];for(let i=0;i<n.length;i+=1)r[i]=zn(jn(e,n,i));return{c(){t=T("ul");for(let i=0;i<r.length;i+=1)r[i].c();b(t,"class","selectDropdown svelte-1fe9nk9")},m(i,o){H(i,t,o);for(let a=0;a<r.length;a+=1)r[a]&&r[a].m(t,null);e[13](t)},p(i,o){if(o&547){n=Ct(i[1]);let a;for(a=0;a<n.length;a+=1){const l=jn(i,n,a);r[a]?r[a].p(l,o):(r[a]=zn(l),r[a].c(),r[a].m(t,null))}for(;a<r.length;a+=1)r[a].d(1);r.length=n.length}},d(i){i&&B(t),nr(r,i),e[13](null)}}}function zn(e){var h,d;let t,n,r=((h=e[14])==null?void 0:h.symbol)+"",i,o,a=((d=e[14])==null?void 0:d.currency)+"",l,s,u,c,f;return{c(){var E,p,_,y;t=T("li"),n=T("span"),i=W(r),o=R(),l=W(a),s=R(),b(n,"class","symbol svelte-1fe9nk9"),b(t,"role","option"),b(t,"aria-selected",u=((E=e[14])==null?void 0:E.currency)===((p=e[0])==null?void 0:p.currency)||e[16]===e[5]),b(t,"class","svelte-1fe9nk9"),se(t,"active",((_=e[14])==null?void 0:_.currency)===((y=e[0])==null?void 0:y.currency)||e[16]===e[5])},m(E,p){H(E,t,p),v(t,n),v(n,i),v(t,o),v(t,l),v(t,s),c||(f=[ie(t,"keydown",Ko),ie(t,"click",function(){ct(e[9](e[14],e[16]))&&e[9](e[14],e[16]).apply(this,arguments)})],c=!0)},p(E,p){var _,y,L,C,Z,k;e=E,p&2&&r!==(r=((_=e[14])==null?void 0:_.symbol)+"")&&te(i,r),p&2&&a!==(a=((y=e[14])==null?void 0:y.currency)+"")&&te(l,a),p&35&&u!==(u=((L=e[14])==null?void 0:L.currency)===((C=e[0])==null?void 0:C.currency)||e[16]===e[5])&&b(t,"aria-selected",u),p&35&&se(t,"active",((Z=e[14])==null?void 0:Z.currency)===((k=e[0])==null?void 0:k.currency)||e[16]===e[5])},d(E){E&&B(t),c=!1,Ee(f)}}}function Qo(e){var E,p;let t,n,r,i,o=(((E=e[0])==null?void 0:E.currency)||e[2])+"",a,l,s,u,c,f,h=((p=e[0])==null?void 0:p.symbol)&&e[4]&&Xn(e),d=e[7]&&Wn(e);return{c(){t=T("div"),n=T("button"),r=T("span"),h&&h.c(),i=R(),a=W(o),l=R(),s=T("span"),s.innerHTML='<svg width="12" height="7" viewBox="0 0 12 7" fill="currentColor" xmlns="http://www.w3.org/2000/svg"><path d="M0.984228 0.664666C0.928537 0.612038 0.863025 0.570896 0.791433 0.543587C0.719842 0.516278 0.643572 0.503337 0.566979 0.505504C0.490386 0.50767 0.41497 0.524902 0.345037 0.556215C0.275103 0.587527 0.212022 0.632308 0.159395 0.687999C0.106768 0.74369 0.0656252 0.809203 0.0383161 0.880794C0.0110071 0.952386 -0.00193361 1.02866 0.000233093 1.10525C0.0023998 1.18184 0.0196314 1.25726 0.050944 1.32719C0.0822566 1.39712 0.127037 1.46021 0.182728 1.51283L5.43273 6.47117C5.54104 6.57356 5.68443 6.63061 5.83348 6.63061C5.98253 6.63061 6.12592 6.57356 6.23423 6.47117L11.4848 1.51283C11.5417 1.46055 11.5877 1.39748 11.62 1.32729C11.6523 1.2571 11.6704 1.18119 11.6731 1.10396C11.6759 1.02673 11.6633 0.949723 11.636 0.877415C11.6087 0.805107 11.5674 0.738937 11.5143 0.68275C11.4612 0.626563 11.3976 0.581479 11.3269 0.550115C11.2563 0.518751 11.1801 0.501734 11.1029 0.500051C11.0256 0.498369 10.9488 0.512054 10.8769 0.540313C10.8049 0.568572 10.7393 0.610841 10.6839 0.664665L5.83348 5.245L0.984228 0.664666Z" fill="currentColor"></path></svg>',u=R(),d&&d.c(),b(r,"class","label svelte-1fe9nk9"),b(s,"class","arrow"),se(s,"open",e[7]),b(n,"class","selectButton svelte-1fe9nk9"),b(n,"aria-haspopup","listbox"),b(n,"aria-expanded",e[7]),b(n,"aria-controls","custom-select"),b(n,"tabindex","0"),n.disabled=e[3],b(t,"class","selectWrapper svelte-1fe9nk9")},m(_,y){H(_,t,y),v(t,n),v(n,r),h&&h.m(r,null),v(r,i),v(r,a),v(n,l),v(n,s),v(t,u),d&&d.m(t,null),c||(f=[ie(n,"keydown",e[11]),ie(n,"click",Vr(e[8])),Dr(zo.call(null,t)),ie(t,"outclick",e[10])],c=!0)},p(_,[y]){var L,C;(L=_[0])!=null&&L.symbol&&_[4]?h?h.p(_,y):(h=Xn(_),h.c(),h.m(r,i)):h&&(h.d(1),h=null),y&5&&o!==(o=(((C=_[0])==null?void 0:C.currency)||_[2])+"")&&te(a,o),y&128&&se(s,"open",_[7]),y&128&&b(n,"aria-expanded",_[7]),y&8&&(n.disabled=_[3]),_[7]?d?d.p(_,y):(d=Wn(_),d.c(),d.m(t,null)):d&&(d.d(1),d=null)},i:I,o:I,d(_){_&&B(t),h&&h.d(),d&&d.d(),c=!1,Ee(f)}}}const Ko=e=>e.preventDefault();function Yo(e,t,n){let{options:r=[]}=t,{selected:i=null}=t,{placeholder:o=M("select")}=t,{disabled:a=!1}=t,{withSymbol:l=!0}=t,{onChange:s=()=>{}}=t,u=-1,c,f=!1;const h=()=>{r.length!==0&&(n(7,f=!f),f&&(n(5,u=r.findIndex(y=>(y==null?void 0:y.currency)===(i==null?void 0:i.currency))),setTimeout(()=>c==null?void 0:c.focus(),0)))},d=(y,L)=>()=>{n(7,f=!1),n(0,i=y),s&&typeof s=="function"&&s(y,L)},E=()=>{n(7,f=!1)},p=y=>{f&&(y.key===_t.ArrowDown?(y.preventDefault(),n(5,u=(u+1)%r.length)):y.key===_t.ArrowUp?(y.preventDefault(),n(5,u=(u-1+r.length)%r.length)):y.key===_t.Enter?(y.preventDefault(),d(i,u)()):y.key===_t.Escape&&n(7,f=!1))};function _(y){je[y?"unshift":"push"](()=>{c=y,n(6,c)})}return e.$$set=y=>{"options"in y&&n(1,r=y.options),"selected"in y&&n(0,i=y.selected),"placeholder"in y&&n(2,o=y.placeholder),"disabled"in y&&n(3,a=y.disabled),"withSymbol"in y&&n(4,l=y.withSymbol),"onChange"in y&&n(12,s=y.onChange)},[i,r,o,a,l,u,c,f,h,d,E,p,s,_]}class cn extends dn{constructor(t){super(),fn(this,t,Yo,Qo,Pt,{options:1,selected:0,placeholder:2,disabled:3,withSymbol:4,onChange:12},Zo)}get options(){return this.$$.ctx[1]}set options(t){this.$$set({options:t}),j()}get selected(){return this.$$.ctx[0]}set selected(t){this.$$set({selected:t}),j()}get placeholder(){return this.$$.ctx[2]}set placeholder(t){this.$$set({placeholder:t}),j()}get disabled(){return this.$$.ctx[3]}set disabled(t){this.$$set({disabled:t}),j()}get withSymbol(){return this.$$.ctx[4]}set withSymbol(t){this.$$set({withSymbol:t}),j()}get onChange(){return this.$$.ctx[12]}set onChange(t){this.$$set({onChange:t}),j()}}pn(cn,{options:{},selected:{},placeholder:{},disabled:{type:"Boolean"},withSymbol:{type:"Boolean"},onChange:{}},[],[],!0);function Jo(e){hn(e,"svelte-2fhtvy",".warningIcon.svelte-2fhtvy{line-height:1;margin-right:0.4rem}")}function qo(e){let t,n,r=M("balanceUnavailable")+"",i;return{c(){t=T("span"),t.innerHTML='<svg fill="currentColor" width="20px" height="20px" viewBox="0 0 64 64" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xml:space="preserve"><g><path d="M32.427,7.987c2.183,0.124 4,1.165 5.096,3.281l17.936,36.208c1.739,3.66 -0.954,8.585 -5.373,8.656l-36.119,0c-4.022,-0.064 -7.322,-4.631 -5.352,-8.696l18.271,-36.207c0.342,-0.65 0.498,-0.838 0.793,-1.179c1.186,-1.375 2.483,-2.111 4.748,-2.063Zm-0.295,3.997c-0.687,0.034 -1.316,0.419 -1.659,1.017c-6.312,11.979 -12.397,24.081 -18.301,36.267c-0.546,1.225 0.391,2.797 1.762,2.863c12.06,0.195 24.125,0.195 36.185,0c1.325,-0.064 2.321,-1.584 1.769,-2.85c-5.793,-12.184 -11.765,-24.286 -17.966,-36.267c-0.366,-0.651 -0.903,-1.042 -1.79,-1.03Z" style="fill-rule:nonzero;"></path><path d="M33.631,40.581l-3.348,0l-0.368,-16.449l4.1,0l-0.384,16.449Zm-3.828,5.03c0,-0.609 0.197,-1.113 0.592,-1.514c0.396,-0.4 0.935,-0.601 1.618,-0.601c0.684,0 1.223,0.201 1.618,0.601c0.395,0.401 0.593,0.905 0.593,1.514c0,0.587 -0.193,1.078 -0.577,1.473c-0.385,0.395 -0.929,0.593 -1.634,0.593c-0.705,0 -1.249,-0.198 -1.634,-0.593c-0.384,-0.395 -0.576,-0.886 -0.576,-1.473Z" style="fill-rule:nonzero;"></path></g></svg>',n=R(),i=W(r),b(t,"class","warningIcon svelte-2fhtvy")},m(o,a){H(o,t,a),H(o,n,a),H(o,i,a)},p:I,i:I,o:I,d(o){o&&(B(t),B(n),B(i))}}}class kt extends dn{constructor(t){super(),fn(this,t,null,qo,Pt,{},Jo)}}pn(kt,{},[],[],!0);function ea(e){hn(e,"svelte-vp2pzr",'@charset "UTF-8";*{margin:0;padding:0}.playerAccountVault{max-width:400px;display:flex;flex-direction:column;justify-content:center;align-items:center;margin:auto;font-family:inherit;overflow:hidden;gap:var(--emw--spacing-small, 10px);font-size:var(--emw--font-size-small, 12px);background:var(--emw--widget-background, #F8F8F8);color:var(--emw--typography, var(--emw--color-gray-450, #595959));padding:var(--emw--spacing-medium, 16px);position:relative}.playerAccountVault .closeButton{position:absolute;background:none;border:none;top:var(--emw--spacing-medium, 16px);right:var(--emw--spacing-small, 10px);line-height:0;cursor:pointer}.playerAccountVault .closeButton svg{fill:var(--emw--color-faded, #A0A29F)}.playerAccountVault .playerVaultContainer{width:100%;display:flex;justify-content:space-between;align-items:center;gap:var(--emw--spacing-small, 10px);border-radius:var(--emw--border-radius-smaller, 5px);box-sizing:border-box}.playerAccountVault .amountContainer{display:flex;align-items:center}.playerAccountVault .headerContainer{display:flex;width:100%;gap:var(--emw--spacing-small, 10px);justify-content:space-between;flex-direction:column}.playerAccountVault .headerContainer .headerTitle{font-family:inherit;color:var(--emw--color-secondary, #24B04F);font-size:var(--emw--font-size-large, 16px);font-weight:var(--emw--font-weight-normal, 400)}.playerAccountVault .headerContainer .totalAmount{margin-right:4px;color:var(--emw--color-faded, #A0A29F)}.playerAccountVault .exchangesContainer{width:100%;height:100%;box-sizing:border-box;position:relative;display:flex;flex-direction:column;gap:var(--emw--spacing-small, 10px)}.playerAccountVault .exchangesContainer .containerExchangeFrom .exchangeHeader,.playerAccountVault .exchangesContainer .containerExchangeTo .exchangeHeader{font-size:inherit;font-family:inherit;font-family:inherit}.playerAccountVault .exchangesContainer .containerExchangeFrom .flexingContainerRow,.playerAccountVault .exchangesContainer .containerExchangeTo .flexingContainerRow{display:flex;align-items:center;gap:var(--emw--spacing-small, 10px)}.playerAccountVault .exchangesContainer .containerExchangeFrom .flexingContainerRow input[type=number]::-webkit-inner-spin-button,.playerAccountVault .exchangesContainer .containerExchangeFrom .flexingContainerRow input[type=number]::-webkit-outer-spin-button,.playerAccountVault .exchangesContainer .containerExchangeTo .flexingContainerRow input[type=number]::-webkit-inner-spin-button,.playerAccountVault .exchangesContainer .containerExchangeTo .flexingContainerRow input[type=number]::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}.playerAccountVault .exchangesContainer .containerExchangeFrom .flexingContainerRow input[type=number],.playerAccountVault .exchangesContainer .containerExchangeTo .flexingContainerRow input[type=number]{-moz-appearance:textfield}.playerAccountVault .exchangesContainer .containerExchangeFrom .flexingContainerRow .exchangeInput,.playerAccountVault .exchangesContainer .containerExchangeTo .flexingContainerRow .exchangeInput{flex:1;min-width:50px;border:unset;height:var(--emw--base-height, 36px);font-size:var(--emw--font-size-medium, 14px);padding:0 var(--emw--spacing-small, 10px);border-radius:var(--emw--border-radius-small, 8px);background-color:rgba(255, 255, 255, var(--emw--background-opacity, 0.9));-webkit-backdrop-filter:blur(var(--emw--filter-blur, 31.5px));backdrop-filter:blur(var(--emw--filter-blur, 31.5px));font-family:inherit}.playerAccountVault .exchangesContainer .containerExchangeFrom .flexingContainerRow .exchangeInput:focus,.playerAccountVault .exchangesContainer .containerExchangeTo .flexingContainerRow .exchangeInput:focus{outline:none}.playerAccountVault .exchangesContainer .containerExchangeFrom .flexingContainerRow .currenciesSelect,.playerAccountVault .exchangesContainer .containerExchangeTo .flexingContainerRow .currenciesSelect{min-width:96px;border:unset;white-space:nowrap;height:var(--emw--base-height, 36px);padding:0 var(--emw--spacing-small, 10px)}.playerAccountVault .exchangesContainer .containerExchangeFrom .flexingContainerRow .currenciesSelect:focus,.playerAccountVault .exchangesContainer .containerExchangeTo .flexingContainerRow .currenciesSelect:focus{outline:none}.playerAccountVault .exchangesContainer .containerExchangeFrom .balanceContainer,.playerAccountVault .exchangesContainer .containerExchangeTo .balanceContainer{display:flex;justify-content:space-between;gap:var(--emw--spacing-small, 10px)}.playerAccountVault .exchangesContainer .containerExchangeFrom .balanceContainer.hasError,.playerAccountVault .exchangesContainer .containerExchangeTo .balanceContainer.hasError{color:var(--emw--color-error, var(--emw--color-red, #ed0909))}.playerAccountVault .exchangesContainer .containerExchangeFrom .balanceContainer.hasError span,.playerAccountVault .exchangesContainer .containerExchangeTo .balanceContainer.hasError span{color:var(--emw--color-error, var(--emw--color-red, #ed0909))}.playerAccountVault .exchangesContainer .containerExchangeFrom .balanceContainer .validationError,.playerAccountVault .exchangesContainer .containerExchangeTo .balanceContainer .validationError{flex:1}.playerAccountVault .exchangesContainer .containerExchangeFrom .playerBalance,.playerAccountVault .exchangesContainer .containerExchangeTo .playerBalance{white-space:nowrap;justify-content:flex-end}.playerAccountVault .exchangesContainer .containerExchangeFrom .playerBalance .amount,.playerAccountVault .exchangesContainer .containerExchangeTo .playerBalance .amount{color:var(--emw--color-faded, #A0A29F);margin-right:4px}.playerAccountVault .vaultsContainer{display:flex;flex-direction:column;width:100%}.playerAccountVault .vaultsContainer .vaultToggleButton{display:flex;align-items:center;justify-content:center;width:35px;height:35px;cursor:pointer;border:unset;align-self:flex-end;padding:var(--emw--spacing-small, 10px);background:var(--emw--color-primary, #24B04F);border-radius:var(--emw--border-radius-small, 8px)}.playerAccountVault .vaultsContainer .vaultToggleButton .vaultToggleIcon{transform:rotateZ(0deg);transition:all 0.3s ease-in-out}.playerAccountVault .vaultsContainer .vaultToggleButton .vaultToggleIcon path{fill:var(--emw--color-white, #fff)}.playerAccountVault .vaultsContainer .vaultToggleButton.active .vaultToggleIcon{transform:rotateZ(180deg)}.playerAccountVault .vaultsContainer .vaultDropdown{width:80%;max-height:0;height:200px;margin:0 auto;display:flex;flex-direction:column;overflow:auto;opacity:0;scrollbar-width:thin;gap:var(--emw--spacing-small, 10px);font-size:var(--emw--font-size-medium, 14px);color:var(--emw--color-white, #fff);font-family:inherit;transition:max-height 0.4s ease-out, opacity 0.4s ease-out}.playerAccountVault .vaultsContainer .vaultDropdown .vaultItem{display:inherit;font-size:var(--emw--font-size-medium, 14px);justify-content:space-between;width:100%;margin:0 auto;box-sizing:border-box;height:var(--emw--base-height, 36px);padding:var(--emw--spacing-small, 10px);background:var(--emw--color-primary, #24B04F);border-radius:var(--emw--border-radius-small, 8px)}.playerAccountVault .vaultsContainer .vaultDropdown.expanded{transition:max-height 1s ease-in, opacity 0.4s ease-in;max-height:1000vh;opacity:1}.playerAccountVault .notificationsContainer{width:100%;min-height:var(--emw--base-height, 36px);padding:0px}.playerAccountVault .notificationsContainer.error{color:var(--emw--color-error, var(--emw--color-red, #FF2424))}.playerAccountVault .notificationsContainer.success{color:var(--emw--color-success, var(--emw--color-primary, #24B04F))}.playerAccountVault .feesContainer{width:100%;height:var(--emw--base-height, 36px);display:flex;align-items:center;justify-content:space-between;background-color:rgba(255, 255, 255, var(--emw--background-opacity, 0.9));-webkit-backdrop-filter:blur(var(--emw--filter-blur, 31.5px));backdrop-filter:blur(var(--emw--filter-blur, 31.5px));border-radius:var(--emw--border-radius-small, 8px);padding:0 var(--emw--spacing-small, 10px);box-sizing:border-box}.playerAccountVault .feesContainer .feesLabel{color:var(--emw--color-faded, #A0A29F)}.playerAccountVault .actionsContainer{width:100%;height:100%;display:flex;justify-content:space-between;align-items:center;box-sizing:border-box;gap:var(--emw--spacing-small, 10px)}.playerAccountVault .actionsContainer button{flex:1;height:var(--emw--base-height, 36px);border:none;cursor:pointer;font-family:inherit;font-size:var(--emw--font-size-small, 12px);border-radius:var(--emw--border-radius-small, 8px);font-weight:var(--emw--font-weight-bold, 500);transition:background 0.3s ease, color 0.3s ease, filter 0.3s ease}.playerAccountVault .actionsContainer .exchangeButton{background:var(--emw--color-primary, #24B04F);color:var(--emw--button-typography, var(--emw--color-white, #fff))}.playerAccountVault .actionsContainer .exchangeButton:hover{filter:brightness(110%)}.playerAccountVault .actionsContainer .resetButton{background:transparent;color:var(--emw--typography, var(--emw--color-gray-450, #595959));border:2px solid var(--emw--color-primary, #24B04F)}.playerAccountVault .actionsContainer .resetButton:hover{background:var(--emw--color-primary, #24B04F);color:var(--emw--button-typography, var(--emw--color-white, #fff))}.playerAccountVault .actionsContainer .exchangeButton.disabled{cursor:default;filter:none;background:var(--emw--button-disabled, var(--emw--color-gray-450, #595959))}.playerAccountVault .actionsContainer .exchangeButton.disabled:hover{background:var(--emw--button-disabled, var(--emw--color-gray-450, #595959))}.playerAccountVault .actionsContainer .exchangeButton.disabled.pending{background:var(--emw--color-primary, #24B04F);pointer-events:none;opacity:0.5}.playerAccountVault .skeleton{background-color:rgba(0, 0, 0, 0.11);height:auto;min-height:0.1rem;-webkit-animation:loading 1.5s ease-in-out 0.5s infinite;animation:loading 1.5s ease-in-out 0.5s infinite}.playerAccountVault .skeleton::before{content:" "}@keyframes loading{0%{opacity:1}50%{opacity:0.4}100%{opacity:1}}.playerAccountVault .exchangeContainer{display:flex;flex-direction:column;gap:4px}')}function Zn(e,t,n){const r=e.slice();return r[61]=t[n],r}function Qn(e){var Le;let t,n,r,i,o,a,l,s,u,c,f,h,d,E,p,_,y,L,C,Z,k,ne,oe,le,X,fe,Re,ue,pe,xe,Q,J,de,et,we,ke,ht,De,tt,re,Ae=M(((Le=e[12])==null?void 0:Le.message)||"")+"",Ie,be,ye,Me,q,Te=M("exchange")+"",ft,ve,ee,nt,rt,K=e[3]&&Kn(e),G=e[2]&&Yn(e);function Dt(g){e[39](g)}let pt={withSymbol:e[4],disabled:!e[16]||!e[17],options:e[21],onChange:e[26]};e[5]!==void 0&&(pt.selected=e[5]),p=new cn({props:pt}),je.push(()=>Tn(p,"selected",Dt));const dt=[aa,oa],ce=[];function mt(g,S){return!g[16]||!g[17]?0:1}L=mt(e),C=ce[L]=dt[L](e);function Mt(g){e[41](g)}let gt={withSymbol:e[4],disabled:!e[0]||!!e[13]||!e[16]||!e[17],options:e[22],onChange:e[26]};e[6]!==void 0&&(gt.selected=e[6]),ue=new cn({props:gt}),je.push(()=>Tn(ue,"selected",Mt));const bt=[ca,ua],me=[];function m(g,S){return!g[16]||!g[17]?0:1}Q=m(e),J=me[Q]=bt[Q](e);let x=e[1]&&Jn(e);function O(g,S){var A;return((A=g[12])==null?void 0:A.source)===z.CheckWalletExchangeError?da:pa}let w=O(e),D=w(e);return{c(){var g,S,A;t=T("div"),K&&K.c(),n=R(),r=T("div"),i=T("h1"),i.textContent=`${M("vaultExchange")}`,o=R(),G&&G.c(),a=R(),l=T("div"),s=T("div"),u=T("p"),u.textContent=`${M("exchangeFrom")}`,c=R(),f=T("div"),h=T("input"),E=R(),st(p.$$.fragment),y=R(),C.c(),Z=R(),k=T("div"),ne=T("p"),ne.textContent=`${M("exchangeTo")}`,oe=R(),le=T("div"),X=T("input"),Re=R(),st(ue.$$.fragment),xe=R(),J.c(),de=R(),x&&x.c(),et=R(),we=T("div"),ke=T("span"),ke.textContent=`${M("feesIncluded")}`,ht=R(),De=T("span"),D.c(),tt=R(),re=T("div"),Ie=R(),be=T("div"),ye=T("button"),ye.textContent=`${M("reset")}`,Me=R(),q=T("button"),ft=W(Te),b(i,"class","headerTitle"),b(r,"class","headerContainer"),b(u,"class","exchangeHeader"),b(h,"id","senderInput"),h.disabled=d=!e[0]||!e[16]||!e[17],b(h,"placeholder",M("debitPlaceHolder")),b(h,"class","exchangeInput"),b(h,"type","number"),b(h,"aria-label","Enter exchange amount"),b(h,"inputmode","decimal"),b(h,"step","0.000000000000000001"),b(h,"min","0"),b(f,"class","flexingContainerRow"),b(s,"class","containerExchangeFrom exchangeContainer"),b(ne,"class","exchangeHeader"),b(X,"id","destinationInput"),X.disabled=fe=!e[0]||!e[16]||!e[17],b(X,"placeholder",M("creditPlaceHolder")),b(X,"class","exchangeInput"),b(X,"type","number"),X.readOnly=!0,b(X,"min","0"),b(le,"class","flexingContainerRow"),b(k,"class","containerExchangeTo exchangeContainer"),b(l,"class","exchangesContainer"),b(ke,"class","feesLabel"),b(we,"class","feesContainer"),b(re,"class","notificationsContainer"),se(re,"error",((g=e[12])==null?void 0:g.type)==="error"),se(re,"success",((S=e[12])==null?void 0:S.type)==="success"),b(ye,"class","resetButton"),b(ye,"type","button"),b(q,"type","button"),b(q,"class","exchangeButton"),q.disabled=ve=e[14]||e[18]||e[8]===0&&!((A=e[5])!=null&&A.amount),se(q,"disabled",e[14]||e[18]),se(q,"pending",e[18]),b(be,"class","actionsContainer"),b(t,"class","playerAccountVault")},m(g,S){H(g,t,S),K&&K.m(t,null),v(t,n),v(t,r),v(r,i),v(r,o),G&&G.m(r,null),v(t,a),v(t,l),v(l,s),v(s,u),v(s,c),v(s,f),v(f,h),yt(h,e[8]),v(f,E),Xe(p,f,null),v(s,y),ce[L].m(s,null),v(l,Z),v(l,k),v(k,ne),v(k,oe),v(k,le),v(le,X),yt(X,e[9]),v(le,Re),Xe(ue,le,null),v(k,xe),me[Q].m(k,null),v(t,de),x&&x.m(t,null),v(t,et),v(t,we),v(we,ke),v(we,ht),v(we,De),D.m(De,null),v(t,tt),v(t,re),re.innerHTML=Ae,v(t,Ie),v(t,be),v(be,ye),v(be,Me),v(be,q),v(q,ft),e[42](t),ee=!0,nt||(rt=[ie(h,"input",e[38]),ie(h,"input",e[27]),ie(h,"beforeinput",e[28]),ie(X,"input",e[40]),ie(ye,"click",e[25]),ie(q,"click",e[29])],nt=!0)},p(g,S){var bn,yn,vn,_n;g[3]?K?K.p(g,S):(K=Kn(g),K.c(),K.m(t,n)):K&&(K.d(1),K=null),g[2]?G?(G.p(g,S),S[0]&4&&V(G,1)):(G=Yn(g),G.c(),V(G,1),G.m(r,null)):G&&(Se(),$(G,1,1,()=>{G=null}),He()),(!ee||S[0]&196609&&d!==(d=!g[0]||!g[16]||!g[17]))&&(h.disabled=d),S[0]&256&&Tt(h.value)!==g[8]&&yt(h,g[8]);const A={};S[0]&16&&(A.withSymbol=g[4]),S[0]&196608&&(A.disabled=!g[16]||!g[17]),S[0]&2097152&&(A.options=g[21]),!_&&S[0]&32&&(_=!0,A.selected=g[5],An(()=>_=!1)),p.$set(A);let _e=L;L=mt(g),L===_e?ce[L].p(g,S):(Se(),$(ce[_e],1,1,()=>{ce[_e]=null}),He(),C=ce[L],C?C.p(g,S):(C=ce[L]=dt[L](g),C.c()),V(C,1),C.m(s,null)),(!ee||S[0]&196609&&fe!==(fe=!g[0]||!g[16]||!g[17]))&&(X.disabled=fe),S[0]&512&&Tt(X.value)!==g[9]&&yt(X,g[9]);const he={};S[0]&16&&(he.withSymbol=g[4]),S[0]&204801&&(he.disabled=!g[0]||!!g[13]||!g[16]||!g[17]),S[0]&4194304&&(he.options=g[22]),!pe&&S[0]&64&&(pe=!0,he.selected=g[6],An(()=>pe=!1)),ue.$set(he);let Ut=Q;Q=m(g),Q===Ut?me[Q].p(g,S):(Se(),$(me[Ut],1,1,()=>{me[Ut]=null}),He(),J=me[Q],J?J.p(g,S):(J=me[Q]=bt[Q](g),J.c()),V(J,1),J.m(k,null)),g[1]?x?x.p(g,S):(x=Jn(g),x.c(),x.m(t,et)):x&&(x.d(1),x=null),w===(w=O(g))&&D?D.p(g,S):(D.d(1),D=w(g),D&&(D.c(),D.m(De,null))),(!ee||S[0]&4096)&&Ae!==(Ae=M(((bn=g[12])==null?void 0:bn.message)||"")+"")&&(re.innerHTML=Ae),(!ee||S[0]&4096)&&se(re,"error",((yn=g[12])==null?void 0:yn.type)==="error"),(!ee||S[0]&4096)&&se(re,"success",((vn=g[12])==null?void 0:vn.type)==="success"),(!ee||S[0]&278816&&ve!==(ve=g[14]||g[18]||g[8]===0&&!((_n=g[5])!=null&&_n.amount)))&&(q.disabled=ve),(!ee||S[0]&278528)&&se(q,"disabled",g[14]||g[18]),(!ee||S[0]&262144)&&se(q,"pending",g[18])},i(g){ee||(V(G),V(p.$$.fragment,g),V(C),V(ue.$$.fragment,g),V(J),ee=!0)},o(g){$(G),$(p.$$.fragment,g),$(C),$(ue.$$.fragment,g),$(J),ee=!1},d(g){g&&B(t),K&&K.d(),G&&G.d(),We(p),ce[L].d(),We(ue),me[Q].d(),x&&x.d(),D.d(),e[42](null),nt=!1,Ee(rt)}}}function Kn(e){let t,n,r;return{c(){t=T("button"),t.innerHTML='<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><path d="M13.414 12l4.95-4.95-1.414-1.414-4.95 4.95-4.95-4.95L5.636 7.05l4.95 4.95-4.95 4.95 1.414 1.414 4.95-4.95 4.95 4.95 1.414-1.414-4.95-4.95z"></path></svg>',b(t,"type","button"),b(t,"class","closeButton")},m(i,o){H(i,t,o),n||(r=ie(t,"click",e[24]),n=!0)},p:I,d(i){i&&B(t),n=!1,r()}}}function Yn(e){let t,n,r,i;const o=[na,ta],a=[];function l(s,u){return!s[16]||!s[17]?0:1}return t=l(e),n=a[t]=o[t](e),{c(){n.c(),r=rr()},m(s,u){a[t].m(s,u),H(s,r,u),i=!0},p(s,u){let c=t;t=l(s),t===c?a[t].p(s,u):(Se(),$(a[c],1,1,()=>{a[c]=null}),He(),n=a[t],n?n.p(s,u):(n=a[t]=o[t](s),n.c()),V(n,1),n.m(r.parentNode,r))},i(s){i||(V(n),i=!0)},o(s){$(n),i=!1},d(s){s&&B(r),a[t].d(s)}}}function ta(e){let t,n,r,i;const o=[ia,ra],a=[];function l(s,u){var c;return((c=s[12])==null?void 0:c.source)===z.BalanceError?0:1}return n=l(e),r=a[n]=o[n](e),{c(){t=T("div"),r.c(),b(t,"class","headerPlayerBalance amountContainer")},m(s,u){H(s,t,u),a[n].m(t,null),i=!0},p(s,u){let c=n;n=l(s),n===c?a[n].p(s,u):(Se(),$(a[c],1,1,()=>{a[c]=null}),He(),r=a[n],r?r.p(s,u):(r=a[n]=o[n](s),r.c()),V(r,1),r.m(t,null))},i(s){i||(V(r),i=!0)},o(s){$(r),i=!1},d(s){s&&B(t),a[n].d()}}}function na(e){let t;return{c(){t=T("div"),b(t,"class","skeleton")},m(n,r){H(n,t,r)},p:I,i:I,o:I,d(n){n&&B(t)}}}function ra(e){var s,u;let t,n,r=(((s=e[10])==null?void 0:s.amount)||0)+"",i,o,a=(((u=e[10])==null?void 0:u.currency)||"")+"",l;return{c(){t=T("span"),t.textContent=`${M("totalBalance")}`,n=R(),i=W(r),o=R(),l=W(a),b(t,"class","totalAmount")},m(c,f){H(c,t,f),H(c,n,f),H(c,i,f),H(c,o,f),H(c,l,f)},p(c,f){var h,d;f[0]&1024&&r!==(r=(((h=c[10])==null?void 0:h.amount)||0)+"")&&te(i,r),f[0]&1024&&a!==(a=(((d=c[10])==null?void 0:d.currency)||"")+"")&&te(l,a)},i:I,o:I,d(c){c&&(B(t),B(n),B(i),B(o),B(l))}}}function ia(e){let t,n;return t=new kt({}),{c(){st(t.$$.fragment)},m(r,i){Xe(t,r,i),n=!0},p:I,i(r){n||(V(t.$$.fragment,r),n=!0)},o(r){$(t.$$.fragment,r),n=!1},d(r){We(t,r)}}}function oa(e){let t,n,r,i,o,a,l,s,u;const c=[la,sa],f=[];function h(d,E){var p;return((p=d[12])==null?void 0:p.source)===z.BalanceError?0:1}return a=h(e),l=f[a]=c[a](e),{c(){t=T("div"),n=T("p"),r=W(e[13]),i=R(),o=T("div"),l.c(),b(n,"class","validationError"),b(o,"class","playerBalance amountContainer"),b(t,"class",s="balanceContainer "+(e[13]?"hasError":""))},m(d,E){H(d,t,E),v(t,n),v(n,r),v(t,i),v(t,o),f[a].m(o,null),u=!0},p(d,E){(!u||E[0]&8192)&&te(r,d[13]);let p=a;a=h(d),a===p?f[a].p(d,E):(Se(),$(f[p],1,1,()=>{f[p]=null}),He(),l=f[a],l?l.p(d,E):(l=f[a]=c[a](d),l.c()),V(l,1),l.m(o,null)),(!u||E[0]&8192&&s!==(s="balanceContainer "+(d[13]?"hasError":"")))&&b(t,"class",s)},i(d){u||(V(l),u=!0)},o(d){$(l),u=!1},d(d){d&&B(t),f[a].d()}}}function aa(e){let t;return{c(){t=T("div"),b(t,"class","skeleton")},m(n,r){H(n,t,r)},p:I,i:I,o:I,d(n){n&&B(t)}}}function sa(e){var s,u;let t,n,r=(((s=e[5])==null?void 0:s.amount)||0)+"",i,o,a=(((u=e[5])==null?void 0:u.currency)||"")+"",l;return{c(){t=T("span"),t.textContent=`${M("currentBalance")}`,n=R(),i=W(r),o=R(),l=W(a),b(t,"class","amount")},m(c,f){H(c,t,f),H(c,n,f),H(c,i,f),H(c,o,f),H(c,l,f)},p(c,f){var h,d;f[0]&32&&r!==(r=(((h=c[5])==null?void 0:h.amount)||0)+"")&&te(i,r),f[0]&32&&a!==(a=(((d=c[5])==null?void 0:d.currency)||"")+"")&&te(l,a)},i:I,o:I,d(c){c&&(B(t),B(n),B(i),B(o),B(l))}}}function la(e){let t,n;return t=new kt({}),{c(){st(t.$$.fragment)},m(r,i){Xe(t,r,i),n=!0},p:I,i(r){n||(V(t.$$.fragment,r),n=!0)},o(r){$(t.$$.fragment,r),n=!1},d(r){We(t,r)}}}function ua(e){let t,n,r,i;const o=[fa,ha],a=[];function l(s,u){var c;return((c=s[12])==null?void 0:c.source)===z.BalanceError?0:1}return n=l(e),r=a[n]=o[n](e),{c(){t=T("div"),r.c(),b(t,"class","playerBalance amountContainer")},m(s,u){H(s,t,u),a[n].m(t,null),i=!0},p(s,u){let c=n;n=l(s),n===c?a[n].p(s,u):(Se(),$(a[c],1,1,()=>{a[c]=null}),He(),r=a[n],r?r.p(s,u):(r=a[n]=o[n](s),r.c()),V(r,1),r.m(t,null))},i(s){i||(V(r),i=!0)},o(s){$(r),i=!1},d(s){s&&B(t),a[n].d()}}}function ca(e){let t;return{c(){t=T("div"),b(t,"class","skeleton")},m(n,r){H(n,t,r)},p:I,i:I,o:I,d(n){n&&B(t)}}}function ha(e){var s,u;let t,n,r=(((s=e[6])==null?void 0:s.amount)||0)+"",i,o,a=(((u=e[6])==null?void 0:u.currency)||"")+"",l;return{c(){t=T("span"),t.textContent=`${M("currentBalance")}`,n=R(),i=W(r),o=R(),l=W(a),b(t,"class","amount")},m(c,f){H(c,t,f),H(c,n,f),H(c,i,f),H(c,o,f),H(c,l,f)},p(c,f){var h,d;f[0]&64&&r!==(r=(((h=c[6])==null?void 0:h.amount)||0)+"")&&te(i,r),f[0]&64&&a!==(a=(((d=c[6])==null?void 0:d.currency)||"")+"")&&te(l,a)},i:I,o:I,d(c){c&&(B(t),B(n),B(i),B(o),B(l))}}}function fa(e){let t,n;return t=new kt({}),{c(){st(t.$$.fragment)},m(r,i){Xe(t,r,i),n=!0},p:I,i(r){n||(V(t.$$.fragment,r),n=!0)},o(r){$(t.$$.fragment,r),n=!1},d(r){We(t,r)}}}function Jn(e){let t,n,r,i,o,a,l,s,u,c,f=Ct(e[20]),h=[];for(let d=0;d<f.length;d+=1)h[d]=qn(Zn(e,f,d));return{c(){t=T("div"),n=T("button"),r=wn("svg"),i=wn("path"),a=R(),l=T("div");for(let d=0;d<h.length;d+=1)h[d].c();b(i,"d","M0.984228 0.664666C0.928537 0.612038 0.863025 0.570896 0.791433 0.543587C0.719842 0.516278 0.643572 0.503337 0.566979 0.505504C0.490386 0.50767 0.41497 0.524902 0.345037 0.556215C0.275103 0.587527 0.212022 0.632308 0.159395 0.687999C0.106768 0.74369 0.0656252 0.809203 0.0383161 0.880794C0.0110071 0.952386 -0.00193361 1.02866 0.000233093 1.10525C0.0023998 1.18184 0.0196314 1.25726 0.050944 1.32719C0.0822566 1.39712 0.127037 1.46021 0.182728 1.51283L5.43273 6.47117C5.54104 6.57356 5.68443 6.63061 5.83348 6.63061C5.98253 6.63061 6.12592 6.57356 6.23423 6.47117L11.4848 1.51283C11.5417 1.46055 11.5877 1.39748 11.62 1.32729C11.6523 1.2571 11.6704 1.18119 11.6731 1.10396C11.6759 1.02673 11.6633 0.949723 11.636 0.877415C11.6087 0.805107 11.5674 0.738937 11.5143 0.68275C11.4612 0.626563 11.3976 0.581479 11.3269 0.550115C11.2563 0.518751 11.1801 0.501734 11.1029 0.500051C11.0256 0.498369 10.9488 0.512054 10.8769 0.540313C10.8049 0.568572 10.7393 0.610841 10.6839 0.664665L5.83348 5.245L0.984228 0.664666Z"),b(i,"fill","currentColor"),b(r,"class","vaultToggleIcon"),b(r,"width","12"),b(r,"height","7"),b(r,"viewBox","0 0 12 7"),b(r,"fill","currentColor"),b(r,"xmlns","http://www.w3.org/2000/svg"),b(n,"type","button"),b(n,"class",o="vaultToggleButton "+(e[15]&&e[20].length>0?"active":"")),b(l,"class",s="vaultDropdown "+(e[15]&&e[20].length>0?"expanded":"")),b(t,"class","vaultsContainer")},m(d,E){H(d,t,E),v(t,n),v(n,r),v(r,i),v(t,a),v(t,l);for(let p=0;p<h.length;p+=1)h[p]&&h[p].m(l,null);u||(c=ie(n,"click",e[23]),u=!0)},p(d,E){if(E[0]&1081344&&o!==(o="vaultToggleButton "+(d[15]&&d[20].length>0?"active":""))&&b(n,"class",o),E[0]&1048576){f=Ct(d[20]);let p;for(p=0;p<f.length;p+=1){const _=Zn(d,f,p);h[p]?h[p].p(_,E):(h[p]=qn(_),h[p].c(),h[p].m(l,null))}for(;p<h.length;p+=1)h[p].d(1);h.length=f.length}E[0]&1081344&&s!==(s="vaultDropdown "+(d[15]&&d[20].length>0?"expanded":""))&&b(l,"class",s)},d(d){d&&B(t),nr(h,d),u=!1,c()}}}function qn(e){var c,f;let t,n,r=((c=e[61])==null?void 0:c.currency)+"",i,o,a,l=((f=e[61])==null?void 0:f.amount)+"",s,u;return{c(){t=T("div"),n=T("p"),i=W(r),o=R(),a=T("p"),s=W(l),u=R(),b(t,"class","vaultItem")},m(h,d){H(h,t,d),v(t,n),v(n,i),v(t,o),v(t,a),v(a,s),v(t,u)},p(h,d){var E,p;d[0]&1048576&&r!==(r=((E=h[61])==null?void 0:E.currency)+"")&&te(i,r),d[0]&1048576&&l!==(l=((p=h[61])==null?void 0:p.amount)+"")&&te(s,l)},d(h){h&&B(t)}}}function pa(e){var r,i;let t=`${((r=e[11])==null?void 0:r.amount)||0} ${((i=e[11])==null?void 0:i.currency)||""}`,n;return{c(){n=W(t)},m(o,a){H(o,n,a)},p(o,a){var l,s;a[0]&2048&&t!==(t=`${((l=o[11])==null?void 0:l.amount)||0} ${((s=o[11])==null?void 0:s.currency)||""}`)&&te(n,t)},d(o){o&&B(n)}}}function da(e){let t=M("feesUnavailable")+"",n;return{c(){n=W(t)},m(r,i){H(r,n,i)},p:I,d(r){r&&B(n)}}}function ma(e){let t,n,r=e[19]&&Qn(e);return{c(){r&&r.c(),t=rr()},m(i,o){r&&r.m(i,o),H(i,t,o),n=!0},p(i,o){i[19]?r?(r.p(i,o),o[0]&524288&&V(r,1)):(r=Qn(i),r.c(),V(r,1),r.m(t.parentNode,t)):r&&(Se(),$(r,1,1,()=>{r=null}),He())},i(i){n||(V(r),n=!0)},o(i){$(r),n=!1},d(i){i&&B(t),r&&r.d(i)}}}function ga(e,t,n){let{session:r=""}=t,{userid:i=""}=t,{endpoint:o=""}=t,{lang:a="en"}=t,{clientstyling:l=""}=t,{clientstylingurl:s=""}=t,{translationurl:u=""}=t,{playercurrency:c=""}=t,{showvaults:f=!0}=t,{showtotalbalance:h=!0}=t,{showclosebutton:d=!0}=t,{showcurrencysymbol:E=!0}=t,p=null,_=null,y=0,L=0,C=null,Z=null,k=null,ne="",oe=!0,le=!1,X=!1,fe=!1,Re=!1,ue=!0,pe=[],xe=[],Q=[],J=[],de;Vo({withLocale:"en",translations:{}}),Object.keys(Vn).forEach(m=>{Un(m,Vn[m])});const et=()=>{Fo(a)},we=()=>{fetch(u).then(m=>m.json()).then(m=>{Object.keys(m).forEach(x=>{Un(x,m[x])})}).catch(m=>{console.error("There was a problem with the translations request.",m)})},ke=()=>{let m=document.createElement("style");m.innerHTML=l,de.appendChild(m)},ht=()=>{let m,x=new URL(s),O=document.createElement("style");fetch(x.href).then(w=>w.text()).then(w=>{O.innerHTML=w,m&&clearTimeout(m),m=setTimeout(()=>{de.appendChild(O)},1)})},De=()=>{xe.length!==0&&(n(15,le=!le),window.postMessage({type:Kt.VaultDropdownToggled,state:le},window.location.href))},tt=()=>{n(19,ue=!1),window.postMessage({type:Kt.VaultWidgetClosed},window.location.href)},re=()=>{n(14,oe=!0),Ie(),be(),ye(),Me(),window.postMessage({type:Kt.VaultWidgetReset},window.location.href)},Ae=()=>{n(14,oe=!0),n(9,L=0)},Ie=()=>{n(11,Z=null)},be=()=>{n(8,y=0),n(9,L=0)},ye=()=>{n(13,ne="")},Me=()=>{n(12,k=null)},q=m=>{m&&n(13,ne=m)},Te=({type:m,message:x,source:O=""})=>{let w;switch(n(12,k={message:x,source:O,type:m}),m){case Ce.error:n(14,oe=!0),window.postMessage({type:O,data:{type:m,message:x}},window.location.href);break;case Ce.success:n(14,oe=!0),window.postMessage({type:O,data:{type:m,message:x}},window.location.href),w&&clearTimeout(w),w=setTimeout(()=>{Me()},$o);break}},ft=()=>new Promise((m,x)=>{const O=k==null?void 0:k.message.includes(jo.InvalidSession);O&&x(),(y<0||y===null||isNaN(Number(y)))&&(Ae(),Ie(),x(M("invalidValue"))),y>(p==null?void 0:p.amount)&&(Ae(),Ie(),x(M("exceededValue"))),y===0&&y===0&&!O&&(re(),x()),(!p||!_)&&!O&&x(),ye(),m()}),ve=(m,x)=>Gt(this,null,function*(){var w,D;const O=yield m.json();return(m==null?void 0:m.status)>=200&&(m==null?void 0:m.status)<400?O:(x===z.CheckWalletExchangeError&&Ae(),!X&&x===z.BalanceError&&(n(16,X=!0),n(17,fe=!0)),!fe&&x===z.CurrenciesError&&n(17,fe=!0),Te({type:Ce.error,message:M((w=O==null?void 0:O.thirdPartyResponse)==null?void 0:w.code)||M((D=O==null?void 0:O.thirdPartyResponse)==null?void 0:D.errorCode)||"generalError",source:x}))}),ee=()=>new Promise((m,x)=>{const O=new URL(`${o}/v1/player/${i}/wallet-exchange/currencies`);fetch(O,{method:"GET",headers:{"X-SessionId":r,"Content-Type":"application/json",Accept:"application/json"}}).then(D=>ve(D,z.CurrenciesError)).then(D=>{m(D==null?void 0:D.currencies)}).catch(D=>{Te({type:Ce.error,message:M("generalError"),source:z.CurrenciesError}),x(),console.error("There was an error on the allowed currencies request.",D)}).finally(()=>{n(17,fe=!0)})}),nt=({data:m,shouldUpdateSelectedCurrencies:x,allowed:O=[]})=>{const{items:w=[],totalAmount:D={},totalRealAmount:Le}=m||{};n(10,C=Object.entries(Le||D).map(([A="",_e=0])=>({currency:A,amount:_e}))[0]);let g=null;const S=new Map(O.map(A=>[A.code,A]));for(const A of w)if((A==null?void 0:A.type)===Gn.Real){const _e=S.get(A==null?void 0:A.currency);if(_e&&_e.code===(A==null?void 0:A.currency)){const he=Ft(Ue(Ue({},A),_e),{symbol:Go[A==null?void 0:A.currency]});n(37,pe=[...pe,he]),(A==null?void 0:A.currency)===(C==null?void 0:C.currency)&&n(10,C=Ue(Ue({},C),he)),(A==null?void 0:A.currency)!==(C==null?void 0:C.currency)&&(A==null?void 0:A.walletAccountType)===Gn.Vault&&n(20,xe=[...xe,he]),x&&(A==null?void 0:A.amount)>0&&n(5,p=C!=null&&C.currency?C:g),p&&(p==null?void 0:p.currency)===(A==null?void 0:A.currency)&&n(5,p=he),_&&(_==null?void 0:_.currency)===(A==null?void 0:A.currency)&&n(6,_=he)}}},rt=(m=!0)=>{const x=new URL(`${o}/v2/player/${i}/balance`);fetch(x,{method:"GET",headers:{"X-SessionId":r,"Content-Type":"application/json",Accept:"application/json"}}).then(w=>ve(w,z.BalanceError)).then(w=>{w&&ee().then(D=>{n(37,pe=[]),n(20,xe=[]),nt({data:w,shouldUpdateSelectedCurrencies:m,allowed:D})})}).catch(w=>{Te({type:Ce.error,message:M("generalError"),source:z.BalanceError}),console.error("There was an error with the player balance request.",w)}).finally(()=>{n(16,X=!0)})},G=Wo(()=>{ft().then(()=>{const m=new URL(`${o}/v2/player/${i}/check/wallet-exchange`),x={userId:i,amount:y,currency:p==null?void 0:p.currency,fromCurrency:p==null?void 0:p.currency,toCurrency:_==null?void 0:_.currency,payload:{PlayerCurrency:c}},O={method:"POST",headers:{"X-SessionId":r,"Content-Type":"application/json",Accept:"application/json"},body:$n(x)};fetch(m,O).then(w=>ve(w,z.CheckWalletExchangeError)).then(w=>{var D,Le;w&&((k==null?void 0:k.source)===z.CheckWalletExchangeError&&Me(),Array.isArray((D=w==null?void 0:w.fees)==null?void 0:D.fees)&&n(11,Z=w.fees.fees.find(g=>g.id)),Array.isArray(w==null?void 0:w.walletActions)&&n(9,L=((Le=w.walletActions.find(g=>(g==null?void 0:g.directionName)==="Credit"))==null?void 0:Le.amount)||0),y>0&&(p!=null&&p.currency)&&(_!=null&&_.currency)&&c&&n(14,oe=!1))}).catch(w=>{Te({type:Ce.error,message:M("generalError"),source:z.CheckWalletExchangeError}),console.error("There was a problem with the wallet exchange request.",w)})}).catch(m=>{q(m)})},500),Dt=m=>{const x=m.target.value;if(x.length<=Xo){const[O,w]=x.split(".");w&&w.length>=(p==null?void 0:p.precision)&&n(8,y=parseFloat(O+"."+w.slice(0,p==null?void 0:p.precision)))}G()},pt=m=>{const x=m.data;[">","<",","].includes(x)&&m.preventDefault(),x&&!x.match(/[\d.]/)&&m.preventDefault(),x==="."&&m.target.value.includes(".")&&m.preventDefault()},dt=()=>{const m=new URL(`${o}/v2/player/${i}/wallet-exchange`);n(18,Re=!0);const x={userId:i,amount:y,currency:p==null?void 0:p.currency,fromCurrency:p==null?void 0:p.currency,toCurrency:_==null?void 0:_.currency,payload:{PlayerCurrency:c}},O={method:"PUT",headers:{"X-SessionId":r,"Content-Type":"application/json",Accept:"application/json"},body:$n(x)};fetch(m,O).then(w=>ve(w,z.WalletExchangeError)).then(w=>{w&&(Te({type:Ce.success,message:M("exchangeSuccess"),source:"ExchangeSuccess"}),rt(!1))}).catch(w=>{Te({type:Ce.error,message:M("generalError"),source:z.WalletExchangeError}),console.error("There was an error with the wallet exchange request.",w)}).finally(()=>{n(18,Re=!1),be(),Ie()})},ce=m=>{const{data:{type:x}={}}=m||{};switch(x){case Fn.ResetVaultWidget:re();break;case Fn.CloseVaultWidget:tt();break}};jr(()=>(window.addEventListener("message",ce),()=>{window.removeEventListener("message",ce)}));function mt(){y=Tt(this.value),n(8,y)}function Mt(m){p=m,n(5,p)}function gt(){L=Tt(this.value),n(9,L)}function bt(m){_=m,n(6,_)}function me(m){je[m?"unshift":"push"](()=>{de=m,n(7,de)})}return e.$$set=m=>{"session"in m&&n(0,r=m.session),"userid"in m&&n(30,i=m.userid),"endpoint"in m&&n(31,o=m.endpoint),"lang"in m&&n(32,a=m.lang),"clientstyling"in m&&n(33,l=m.clientstyling),"clientstylingurl"in m&&n(34,s=m.clientstylingurl),"translationurl"in m&&n(35,u=m.translationurl),"playercurrency"in m&&n(36,c=m.playercurrency),"showvaults"in m&&n(1,f=m.showvaults),"showtotalbalance"in m&&n(2,h=m.showtotalbalance),"showclosebutton"in m&&n(3,d=m.showclosebutton),"showcurrencysymbol"in m&&n(4,E=m.showcurrencysymbol)},e.$$.update=()=>{e.$$.dirty[1]&2&&a&&et(),e.$$.dirty[0]&1073741825|e.$$.dirty[1]&33&&r&&i&&o&&c&&rt(),e.$$.dirty[0]&128|e.$$.dirty[1]&4&&l&&de&&ke(),e.$$.dirty[0]&128|e.$$.dirty[1]&8&&s&&de&&ht(),e.$$.dirty[1]&16&&u&&we(),e.$$.dirty[0]&64|e.$$.dirty[1]&64&&n(21,Q=pe.filter(m=>(m==null?void 0:m.amount)>0&&(m==null?void 0:m.currency)!==(_==null?void 0:_.currency))),e.$$.dirty[0]&32|e.$$.dirty[1]&64&&n(22,J=pe.filter(m=>(p==null?void 0:p.currency)!==(m==null?void 0:m.currency)))},[r,f,h,d,E,p,_,de,y,L,C,Z,k,ne,oe,le,X,fe,Re,ue,xe,Q,J,De,tt,re,G,Dt,pt,dt,i,o,a,l,s,u,c,pe,mt,Mt,gt,bt,me]}class Hr extends dn{constructor(t){super(),fn(this,t,ga,ma,Pt,{session:0,userid:30,endpoint:31,lang:32,clientstyling:33,clientstylingurl:34,translationurl:35,playercurrency:36,showvaults:1,showtotalbalance:2,showclosebutton:3,showcurrencysymbol:4},ea,[-1,-1,-1])}get session(){return this.$$.ctx[0]}set session(t){this.$$set({session:t}),j()}get userid(){return this.$$.ctx[30]}set userid(t){this.$$set({userid:t}),j()}get endpoint(){return this.$$.ctx[31]}set endpoint(t){this.$$set({endpoint:t}),j()}get lang(){return this.$$.ctx[32]}set lang(t){this.$$set({lang:t}),j()}get clientstyling(){return this.$$.ctx[33]}set clientstyling(t){this.$$set({clientstyling:t}),j()}get clientstylingurl(){return this.$$.ctx[34]}set clientstylingurl(t){this.$$set({clientstylingurl:t}),j()}get translationurl(){return this.$$.ctx[35]}set translationurl(t){this.$$set({translationurl:t}),j()}get playercurrency(){return this.$$.ctx[36]}set playercurrency(t){this.$$set({playercurrency:t}),j()}get showvaults(){return this.$$.ctx[1]}set showvaults(t){this.$$set({showvaults:t}),j()}get showtotalbalance(){return this.$$.ctx[2]}set showtotalbalance(t){this.$$set({showtotalbalance:t}),j()}get showclosebutton(){return this.$$.ctx[3]}set showclosebutton(t){this.$$set({showclosebutton:t}),j()}get showcurrencysymbol(){return this.$$.ctx[4]}set showcurrencysymbol(t){this.$$set({showcurrencysymbol:t}),j()}}pn(Hr,{session:{},userid:{},endpoint:{},lang:{},clientstyling:{},clientstylingurl:{},translationurl:{},playercurrency:{},showvaults:{type:"Boolean"},showtotalbalance:{type:"Boolean"},showclosebutton:{type:"Boolean"},showcurrencysymbol:{type:"Boolean"}},[],[],!0);exports.default=Hr;
|