@shipengine/alchemy 0.3.7 → 0.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/alchemy.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  export declare const alchemy: {
2
- createElement: <P extends object, T extends import("./components").TranslationResources<import("./components").TranslationNamespaces>>(Component: import("./components").ElementComponent<P>, fallback: import("./components").ElementFallbackComponent, defaultResources: T) => ({ resources, ...props }: P & {
2
+ createElement: <P extends object, T extends import("./components").TranslationResources<import("./components").TranslationNamespaces>>(Component: import("./components").ElementComponent<P>, fallback: import("./components").ElementFallbackComponent, options?: import("./create-element").CreateElementOptions<T> | undefined) => ({ resources, ...props }: P & {
3
3
  resources?: T | undefined;
4
4
  }) => import("@emotion/react/jsx-runtime").JSX.Element;
5
5
  };
@@ -1,3 +1,4 @@
1
+ import { SerializedStyles } from "@emotion/react";
1
2
  import { WithConditionalCSSProp } from "@emotion/react/types/jsx-namespace";
2
3
  import { TranslationResources } from "./hooks";
3
4
  export type ElementComponentProps = object & WithConditionalCSSProp<object>;
@@ -8,7 +9,8 @@ export type ElementFallbackComponentProps = {
8
9
  export type ElementFallbackComponent = React.ComponentType<ElementFallbackComponentProps>;
9
10
  export interface ElementProps {
10
11
  children: React.ReactElement<ElementComponentProps>;
12
+ css?: SerializedStyles;
11
13
  fallback: ElementFallbackComponent;
12
14
  resources?: TranslationResources;
13
15
  }
14
- export declare const Element: ({ children, fallback: FallbackComponent, resources }: ElementProps) => import("@emotion/react/types/jsx-namespace").EmotionJSX.Element;
16
+ export declare const Element: ({ children, css, fallback: FallbackComponent, resources, }: ElementProps) => import("@emotion/react/types/jsx-namespace").EmotionJSX.Element;
@@ -1,4 +1,9 @@
1
+ import { CSSProperties } from "@emotion/serialize";
1
2
  import { ElementComponent, ElementFallbackComponent, TranslationResources } from "./components";
2
- export declare const createElement: <P extends object, T extends TranslationResources<import("./components").TranslationNamespaces>>(Component: ElementComponent<P>, fallback: ElementFallbackComponent, defaultResources: T) => ({ resources, ...props }: P & {
3
+ export interface CreateElementOptions<T extends TranslationResources> {
4
+ css?: CSSProperties;
5
+ resources?: T;
6
+ }
7
+ export declare const createElement: <P extends object, T extends TranslationResources<import("./components").TranslationNamespaces>>(Component: ElementComponent<P>, fallback: ElementFallbackComponent, options?: CreateElementOptions<T> | undefined) => ({ resources, ...props }: P & {
3
8
  resources?: T | undefined;
4
9
  }) => import("@emotion/react/types/jsx-namespace").EmotionJSX.Element;
package/index.js CHANGED
@@ -27,4 +27,4 @@ You should wrap it with \`css\` like this:
27
27
  /* [wrapped with `+t+`] */
28
28
  `)}var Wv=Bv;function jv(e){return function(){return e}}var Nv=jv,Gv=lt,Xv=function(){try{var e=Gv(Object,"defineProperty");return e({},"",{}),e}catch{}}(),pl=Xv,Hv=Nv,bo=pl,Mv=Lr,zv=bo?function(e,t){return bo(e,"toString",{configurable:!0,enumerable:!1,value:Hv(t),writable:!0})}:Mv,Uv=zv,Vv=Uv,Zv=fl,qv=Zv(Vv),ai=qv;function Yv(e,t){for(var r=-1,n=e==null?0:e.length;++r<n&&t(e[r],r,e)!==!1;);return e}var ii=Yv;function Jv(e,t,r,n){for(var a=e.length,i=r+(n?1:-1);n?i--:++i<a;)if(t(e[i],i,e))return i;return-1}var Kv=Jv;function Qv(e){return e!==e}var eC=Qv;function tC(e,t,r){for(var n=r-1,a=e.length;++n<a;)if(e[n]===t)return n;return-1}var rC=tC,nC=Kv,aC=eC,iC=rC;function oC(e,t,r){return t===t?iC(e,t,r):nC(e,aC,r)}var sC=oC,uC=sC;function cC(e,t){var r=e==null?0:e.length;return!!r&&uC(e,t,0)>-1}var lC=cC,fC=ii,gC=lC,pC=1,dC=2,hC=8,yC=16,vC=32,CC=64,AC=128,bC=256,mC=512,IC=[["ary",AC],["bind",pC],["bindKey",dC],["curry",hC],["curryRight",yC],["flip",mC],["partial",vC],["partialRight",CC],["rearg",bC]];function SC(e,t){return fC(IC,function(r){var n="_."+r[0];t&r[1]&&!gC(e,n)&&e.push(n)}),e.sort()}var _C=SC,xC=Dv,OC=Wv,wC=ai,RC=_C;function LC(e,t,r){var n=t+"";return wC(e,OC(n,RC(xC(n),r)))}var dl=LC,TC=_v,EC=gl,$C=dl,PC=1,FC=2,DC=4,kC=8,mo=32,Io=64;function BC(e,t,r,n,a,i,o,s,u,f){var g=t&kC,c=g?o:void 0,d=g?void 0:o,h=g?i:void 0,v=g?void 0:i;t|=g?mo:Io,t&=~(g?Io:mo),t&DC||(t&=~(PC|FC));var m=[e,t,a,h,c,v,d,s,u,f],b=r.apply(void 0,m);return TC(e)&&EC(b,m),b.placeholder=n,$C(b,e,t)}var hl=BC;function WC(e){var t=e;return t.placeholder}var yl=WC,jC=9007199254740991,NC=/^(?:0|[1-9]\d*)$/;function GC(e,t){var r=typeof e;return t=t??jC,!!t&&(r=="number"||r!="symbol"&&NC.test(e))&&e>-1&&e%1==0&&e<t}var Pr=GC,XC=jt,HC=Pr,MC=Math.min;function zC(e,t){for(var r=e.length,n=MC(t.length,r),a=XC(e);n--;){var i=t[n];e[n]=HC(i,r)?a[i]:void 0}return e}var UC=zC,So="__lodash_placeholder__";function VC(e,t){for(var r=-1,n=e.length,a=0,i=[];++r<n;){var o=e[r];(o===t||o===So)&&(e[r]=So,i[a++]=r)}return i}var oi=VC,ZC=sl,qC=ul,YC=Ny,_o=$r,JC=hl,KC=yl,QC=UC,eA=oi,tA=ge,rA=1,nA=2,aA=8,iA=16,oA=128,sA=512;function vl(e,t,r,n,a,i,o,s,u,f){var g=t&oA,c=t&rA,d=t&nA,h=t&(aA|iA),v=t&sA,m=d?void 0:_o(e);function b(){for(var y=arguments.length,A=Array(y),x=y;x--;)A[x]=arguments[x];if(h)var I=KC(b),S=YC(A,I);if(n&&(A=ZC(A,n,a,h)),i&&(A=qC(A,i,o,h)),y-=S,h&&y<f){var D=eA(A,I);return JC(e,t,vl,b.placeholder,r,A,D,s,u,f-y)}var $=c?r:this,N=d?$[e]:e;return y=A.length,s?A=QC(A,s):v&&y>1&&A.reverse(),g&&u<y&&(A.length=u),this&&this!==tA&&this instanceof b&&(N=m||_o(N)),N.apply($,A)}return b}var Cl=vl,uA=ti,cA=$r,lA=Cl,fA=hl,gA=yl,pA=oi,dA=ge;function hA(e,t,r){var n=cA(e);function a(){for(var i=arguments.length,o=Array(i),s=i,u=gA(a);s--;)o[s]=arguments[s];var f=i<3&&o[0]!==u&&o[i-1]!==u?[]:pA(o,u);if(i-=f.length,i<r)return fA(e,t,lA,a.placeholder,void 0,o,f,void 0,void 0,r-i);var g=this&&this!==dA&&this instanceof a?n:e;return uA(g,this,o)}return a}var yA=hA,vA=ti,CA=$r,AA=ge,bA=1;function mA(e,t,r,n){var a=t&bA,i=CA(e);function o(){for(var s=-1,u=arguments.length,f=-1,g=n.length,c=Array(g+u),d=this&&this!==AA&&this instanceof o?i:e;++f<g;)c[f]=n[f];for(;u--;)c[f++]=arguments[++s];return vA(d,a?r:this,c)}return o}var IA=mA,SA=sl,_A=ul,xo=oi,Oo="__lodash_placeholder__",fn=1,xA=2,OA=4,wo=8,Lt=128,Ro=256,wA=Math.min;function RA(e,t){var r=e[1],n=t[1],a=r|n,i=a<(fn|xA|Lt),o=n==Lt&&r==wo||n==Lt&&r==Ro&&e[7].length<=t[8]||n==(Lt|Ro)&&t[7].length<=t[8]&&r==wo;if(!(i||o))return e;n&fn&&(e[2]=t[2],a|=r&fn?0:OA);var s=t[3];if(s){var u=e[3];e[3]=u?SA(u,s,t[4]):s,e[4]=u?xo(e[3],Oo):t[4]}return s=t[5],s&&(u=e[5],e[5]=u?_A(u,s,t[6]):s,e[6]=u?xo(e[5],Oo):t[6]),s=t[7],s&&(e[7]=s),n&Lt&&(e[8]=e[8]==null?t[8]:wA(e[8],t[8])),e[9]==null&&(e[9]=t[9]),e[0]=t[0],e[1]=a,e}var LA=RA,TA=/\s/;function EA(e){for(var t=e.length;t--&&TA.test(e.charAt(t)););return t}var $A=EA,PA=$A,FA=/^\s+/;function DA(e){return e&&e.slice(0,PA(e)+1).replace(FA,"")}var kA=DA,BA=ct,WA=Se,jA="[object Symbol]";function NA(e){return typeof e=="symbol"||WA(e)&&BA(e)==jA}var Nt=NA,GA=kA,Lo=Te,XA=Nt,To=0/0,HA=/^[-+]0x[0-9a-f]+$/i,MA=/^0b[01]+$/i,zA=/^0o[0-7]+$/i,UA=parseInt;function VA(e){if(typeof e=="number")return e;if(XA(e))return To;if(Lo(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=Lo(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=GA(e);var r=MA.test(e);return r||zA.test(e)?UA(e.slice(2),r?2:8):HA.test(e)?To:+e}var ZA=VA,qA=ZA,Eo=1/0,YA=17976931348623157e292;function JA(e){if(!e)return e===0?e:0;if(e=qA(e),e===Eo||e===-Eo){var t=e<0?-1:1;return t*YA}return e===e?e:0}var KA=JA,QA=KA;function eb(e){var t=QA(e),r=t%1;return t===t?r?t-r:t:0}var Al=eb,tb=ol,rb=Py,nb=yA,ab=Cl,ib=IA,ob=cl,sb=LA,ub=gl,cb=dl,$o=Al,lb="Expected a function",Po=1,fb=2,gn=8,pn=16,dn=32,Fo=64,Do=Math.max;function gb(e,t,r,n,a,i,o,s){var u=t&fb;if(!u&&typeof e!="function")throw new TypeError(lb);var f=n?n.length:0;if(f||(t&=~(dn|Fo),n=a=void 0),o=o===void 0?o:Do($o(o),0),s=s===void 0?s:$o(s),f-=a?a.length:0,t&Fo){var g=n,c=a;n=a=void 0}var d=u?void 0:ob(e),h=[e,t,r,n,a,g,c,i,o,s];if(d&&sb(h,d),e=h[0],t=h[1],r=h[2],n=h[3],a=h[4],s=h[9]=h[9]===void 0?u?0:e.length:Do(h[9]-f,0),!s&&t&(gn|pn)&&(t&=~(gn|pn)),!t||t==Po)var v=rb(e,t,r);else t==gn||t==pn?v=nb(e,t,s):(t==dn||t==(Po|dn))&&!a.length?v=ib(e,t,r,n):v=ab.apply(void 0,h);var m=d?tb:ub;return cb(m(v,h),e,t)}var si=gb,pb=si,db=128;function hb(e,t,r){return t=r?void 0:t,t=e&&t==null?e.length:t,pb(e,db,void 0,void 0,void 0,void 0,t)}var yb=hb,ko=pl;function vb(e,t,r){t=="__proto__"&&ko?ko(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}var ui=vb,hn,Bo;function Gt(){if(Bo)return hn;Bo=1;function e(t,r){return t===r||t!==t&&r!==r}return hn=e,hn}var Cb=ui,Ab=Gt(),bb=Object.prototype,mb=bb.hasOwnProperty;function Ib(e,t,r){var n=e[t];(!(mb.call(e,t)&&Ab(n,r))||r===void 0&&!(t in e))&&Cb(e,t,r)}var bl=Ib,Sb=bl,_b=ui;function xb(e,t,r,n){var a=!r;r||(r={});for(var i=-1,o=t.length;++i<o;){var s=t[i],u=n?n(r[s],e[s],s,r,e):void 0;u===void 0&&(u=e[s]),a?_b(r,s,u):Sb(r,s,u)}return r}var Xt=xb;function Ob(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}var wb=Ob,yn,Wo;function Rb(){if(Wo)return yn;Wo=1;var e=ct,t=Se,r="[object Arguments]";function n(a){return t(a)&&e(a)==r}return yn=n,yn}var vn,jo;function Fr(){if(jo)return vn;jo=1;var e=Rb(),t=Se,r=Object.prototype,n=r.hasOwnProperty,a=r.propertyIsEnumerable,i=e(function(){return arguments}())?e:function(o){return t(o)&&n.call(o,"callee")&&!a.call(o,"callee")};return vn=i,vn}var ut={},Lb={get exports(){return ut},set exports(e){ut=e}};function Tb(){return!1}var Eb=Tb;(function(e,t){var r=ge,n=Eb,a=t&&!t.nodeType&&t,i=a&&!0&&e&&!e.nodeType&&e,o=i&&i.exports===a,s=o?r.Buffer:void 0,u=s?s.isBuffer:void 0,f=u||n;e.exports=f})(Lb,ut);var $b=9007199254740991;function Pb(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=$b}var ci=Pb,Cn,No;function Fb(){if(No)return Cn;No=1;var e=ct,t=ci,r=Se,n="[object Arguments]",a="[object Array]",i="[object Boolean]",o="[object Date]",s="[object Error]",u="[object Function]",f="[object Map]",g="[object Number]",c="[object Object]",d="[object RegExp]",h="[object Set]",v="[object String]",m="[object WeakMap]",b="[object ArrayBuffer]",y="[object DataView]",A="[object Float32Array]",x="[object Float64Array]",I="[object Int8Array]",S="[object Int16Array]",D="[object Int32Array]",$="[object Uint8Array]",N="[object Uint8ClampedArray]",ne="[object Uint16Array]",W="[object Uint32Array]",F={};F[A]=F[x]=F[I]=F[S]=F[D]=F[$]=F[N]=F[ne]=F[W]=!0,F[n]=F[a]=F[b]=F[i]=F[y]=F[o]=F[s]=F[u]=F[f]=F[g]=F[c]=F[d]=F[h]=F[v]=F[m]=!1;function q(oe){return r(oe)&&t(oe.length)&&!!F[e(oe)]}return Cn=q,Cn}function Db(e){return function(t){return e(t)}}var li=Db,mt={},kb={get exports(){return mt},set exports(e){mt=e}};(function(e,t){var r=tl,n=t&&!t.nodeType&&t,a=n&&!0&&e&&!e.nodeType&&e,i=a&&a.exports===n,o=i&&r.process,s=function(){try{var u=a&&a.require&&a.require("util").types;return u||o&&o.binding&&o.binding("util")}catch{}}();e.exports=s})(kb,mt);var An,Go;function fi(){if(Go)return An;Go=1;var e=Fb(),t=li,r=mt,n=r&&r.isTypedArray,a=n?t(n):e;return An=a,An}var Bb=wb,Wb=Fr(),jb=pe,Nb=ut,Gb=Pr,Xb=fi(),Hb=Object.prototype,Mb=Hb.hasOwnProperty;function zb(e,t){var r=jb(e),n=!r&&Wb(e),a=!r&&!n&&Nb(e),i=!r&&!n&&!a&&Xb(e),o=r||n||a||i,s=o?Bb(e.length,String):[],u=s.length;for(var f in e)(t||Mb.call(e,f))&&!(o&&(f=="length"||a&&(f=="offset"||f=="parent")||i&&(f=="buffer"||f=="byteLength"||f=="byteOffset")||Gb(f,u)))&&s.push(f);return s}var ml=zb,Ub=Object.prototype;function Vb(e){var t=e&&e.constructor,r=typeof t=="function"&&t.prototype||Ub;return e===r}var gi=Vb;function Zb(e,t){return function(r){return e(t(r))}}var Il=Zb,qb=Il,Yb=qb(Object.keys,Object),Jb=Yb,Kb=gi,Qb=Jb,em=Object.prototype,tm=em.hasOwnProperty;function rm(e){if(!Kb(e))return Qb(e);var t=[];for(var r in Object(e))tm.call(e,r)&&r!="constructor"&&t.push(r);return t}var Sl=rm,nm=Tr,am=ci;function im(e){return e!=null&&am(e.length)&&!nm(e)}var Dr=im,om=ml,sm=Sl,um=Dr;function cm(e){return um(e)?om(e):sm(e)}var kr=cm,lm=Xt,fm=kr;function gm(e,t){return e&&lm(t,fm(t),e)}var _l=gm,bn,Xo;function pm(){if(Xo)return bn;Xo=1;function e(){this.__data__=[],this.size=0}return bn=e,bn}var mn,Ho;function Br(){if(Ho)return mn;Ho=1;var e=Gt();function t(r,n){for(var a=r.length;a--;)if(e(r[a][0],n))return a;return-1}return mn=t,mn}var In,Mo;function dm(){if(Mo)return In;Mo=1;var e=Br(),t=Array.prototype,r=t.splice;function n(a){var i=this.__data__,o=e(i,a);if(o<0)return!1;var s=i.length-1;return o==s?i.pop():r.call(i,o,1),--this.size,!0}return In=n,In}var Sn,zo;function hm(){if(zo)return Sn;zo=1;var e=Br();function t(r){var n=this.__data__,a=e(n,r);return a<0?void 0:n[a][1]}return Sn=t,Sn}var _n,Uo;function ym(){if(Uo)return _n;Uo=1;var e=Br();function t(r){return e(this.__data__,r)>-1}return _n=t,_n}var xn,Vo;function vm(){if(Vo)return xn;Vo=1;var e=Br();function t(r,n){var a=this.__data__,i=e(a,r);return i<0?(++this.size,a.push([r,n])):a[i][1]=n,this}return xn=t,xn}var On,Zo;function Wr(){if(Zo)return On;Zo=1;var e=pm(),t=dm(),r=hm(),n=ym(),a=vm();function i(o){var s=-1,u=o==null?0:o.length;for(this.clear();++s<u;){var f=o[s];this.set(f[0],f[1])}}return i.prototype.clear=e,i.prototype.delete=t,i.prototype.get=r,i.prototype.has=n,i.prototype.set=a,On=i,On}var wn,qo;function Cm(){if(qo)return wn;qo=1;var e=Wr();function t(){this.__data__=new e,this.size=0}return wn=t,wn}var Rn,Yo;function Am(){if(Yo)return Rn;Yo=1;function e(t){var r=this.__data__,n=r.delete(t);return this.size=r.size,n}return Rn=e,Rn}var Ln,Jo;function bm(){if(Jo)return Ln;Jo=1;function e(t){return this.__data__.get(t)}return Ln=e,Ln}var Tn,Ko;function mm(){if(Ko)return Tn;Ko=1;function e(t){return this.__data__.has(t)}return Tn=e,Tn}var Im=lt,Sm=ge,_m=Im(Sm,"Map"),pi=_m,En,Qo;function jr(){if(Qo)return En;Qo=1;var e=lt,t=e(Object,"create");return En=t,En}var $n,es;function xm(){if(es)return $n;es=1;var e=jr();function t(){this.__data__=e?e(null):{},this.size=0}return $n=t,$n}var Pn,ts;function Om(){if(ts)return Pn;ts=1;function e(t){var r=this.has(t)&&delete this.__data__[t];return this.size-=r?1:0,r}return Pn=e,Pn}var Fn,rs;function wm(){if(rs)return Fn;rs=1;var e=jr(),t="__lodash_hash_undefined__",r=Object.prototype,n=r.hasOwnProperty;function a(i){var o=this.__data__;if(e){var s=o[i];return s===t?void 0:s}return n.call(o,i)?o[i]:void 0}return Fn=a,Fn}var Dn,ns;function Rm(){if(ns)return Dn;ns=1;var e=jr(),t=Object.prototype,r=t.hasOwnProperty;function n(a){var i=this.__data__;return e?i[a]!==void 0:r.call(i,a)}return Dn=n,Dn}var kn,as;function Lm(){if(as)return kn;as=1;var e=jr(),t="__lodash_hash_undefined__";function r(n,a){var i=this.__data__;return this.size+=this.has(n)?0:1,i[n]=e&&a===void 0?t:a,this}return kn=r,kn}var Bn,is;function Tm(){if(is)return Bn;is=1;var e=xm(),t=Om(),r=wm(),n=Rm(),a=Lm();function i(o){var s=-1,u=o==null?0:o.length;for(this.clear();++s<u;){var f=o[s];this.set(f[0],f[1])}}return i.prototype.clear=e,i.prototype.delete=t,i.prototype.get=r,i.prototype.has=n,i.prototype.set=a,Bn=i,Bn}var Wn,os;function Em(){if(os)return Wn;os=1;var e=Tm(),t=Wr(),r=pi;function n(){this.size=0,this.__data__={hash:new e,map:new(r||t),string:new e}}return Wn=n,Wn}var jn,ss;function $m(){if(ss)return jn;ss=1;function e(t){var r=typeof t;return r=="string"||r=="number"||r=="symbol"||r=="boolean"?t!=="__proto__":t===null}return jn=e,jn}var Nn,us;function Nr(){if(us)return Nn;us=1;var e=$m();function t(r,n){var a=r.__data__;return e(n)?a[typeof n=="string"?"string":"hash"]:a.map}return Nn=t,Nn}var Gn,cs;function Pm(){if(cs)return Gn;cs=1;var e=Nr();function t(r){var n=e(this,r).delete(r);return this.size-=n?1:0,n}return Gn=t,Gn}var Xn,ls;function Fm(){if(ls)return Xn;ls=1;var e=Nr();function t(r){return e(this,r).get(r)}return Xn=t,Xn}var Hn,fs;function Dm(){if(fs)return Hn;fs=1;var e=Nr();function t(r){return e(this,r).has(r)}return Hn=t,Hn}var Mn,gs;function km(){if(gs)return Mn;gs=1;var e=Nr();function t(r,n){var a=e(this,r),i=a.size;return a.set(r,n),this.size+=a.size==i?0:1,this}return Mn=t,Mn}var zn,ps;function di(){if(ps)return zn;ps=1;var e=Em(),t=Pm(),r=Fm(),n=Dm(),a=km();function i(o){var s=-1,u=o==null?0:o.length;for(this.clear();++s<u;){var f=o[s];this.set(f[0],f[1])}}return i.prototype.clear=e,i.prototype.delete=t,i.prototype.get=r,i.prototype.has=n,i.prototype.set=a,zn=i,zn}var Un,ds;function Bm(){if(ds)return Un;ds=1;var e=Wr(),t=pi,r=di(),n=200;function a(i,o){var s=this.__data__;if(s instanceof e){var u=s.__data__;if(!t||u.length<n-1)return u.push([i,o]),this.size=++s.size,this;s=this.__data__=new r(u)}return s.set(i,o),this.size=s.size,this}return Un=a,Un}var Vn,hs;function Gr(){if(hs)return Vn;hs=1;var e=Wr(),t=Cm(),r=Am(),n=bm(),a=mm(),i=Bm();function o(s){var u=this.__data__=new e(s);this.size=u.size}return o.prototype.clear=t,o.prototype.delete=r,o.prototype.get=n,o.prototype.has=a,o.prototype.set=i,Vn=o,Vn}var Zn,ys;function Wm(){if(ys)return Zn;ys=1;function e(t){var r=[];if(t!=null)for(var n in Object(t))r.push(n);return r}return Zn=e,Zn}var qn,vs;function jm(){if(vs)return qn;vs=1;var e=Te,t=gi,r=Wm(),n=Object.prototype,a=n.hasOwnProperty;function i(o){if(!e(o))return r(o);var s=t(o),u=[];for(var f in o)f=="constructor"&&(s||!a.call(o,f))||u.push(f);return u}return qn=i,qn}var Yn,Cs;function Ht(){if(Cs)return Yn;Cs=1;var e=ml,t=jm(),r=Dr;function n(a){return r(a)?e(a,!0):t(a)}return Yn=n,Yn}var Nm=Xt,Gm=Ht();function Xm(e,t){return e&&Nm(t,Gm(t),e)}var Hm=Xm,Bt={},Mm={get exports(){return Bt},set exports(e){Bt=e}};(function(e,t){var r=ge,n=t&&!t.nodeType&&t,a=n&&!0&&e&&!e.nodeType&&e,i=a&&a.exports===n,o=i?r.Buffer:void 0,s=o?o.allocUnsafe:void 0;function u(f,g){if(g)return f.slice();var c=f.length,d=s?s(c):new f.constructor(c);return f.copy(d),d}e.exports=u})(Mm,Bt);function zm(e,t){for(var r=-1,n=e==null?0:e.length,a=0,i=[];++r<n;){var o=e[r];t(o,r,e)&&(i[a++]=o)}return i}var Um=zm;function Vm(){return[]}var xl=Vm,Zm=Um,qm=xl,Ym=Object.prototype,Jm=Ym.propertyIsEnumerable,As=Object.getOwnPropertySymbols,Km=As?function(e){return e==null?[]:(e=Object(e),Zm(As(e),function(t){return Jm.call(e,t)}))}:qm,hi=Km,Qm=Xt,eI=hi;function tI(e,t){return Qm(e,eI(e),t)}var rI=tI;function nI(e,t){for(var r=-1,n=t.length,a=e.length;++r<n;)e[a+r]=t[r];return e}var yi=nI,aI=Il,iI=aI(Object.getPrototypeOf,Object),vi=iI,oI=yi,sI=vi,uI=hi,cI=xl,lI=Object.getOwnPropertySymbols,fI=lI?function(e){for(var t=[];e;)oI(t,uI(e)),e=sI(e);return t}:cI,Ol=fI,gI=Xt,pI=Ol;function dI(e,t){return gI(e,pI(e),t)}var hI=dI,yI=yi,vI=pe;function CI(e,t,r){var n=t(e);return vI(e)?n:yI(n,r(e))}var wl=CI,AI=wl,bI=hi,mI=kr;function II(e){return AI(e,mI,bI)}var Rl=II,SI=wl,_I=Ol,xI=Ht();function OI(e){return SI(e,xI,_I)}var wI=OI,RI=lt,LI=ge,TI=RI(LI,"DataView"),EI=TI,$I=lt,PI=ge,FI=$I(PI,"Promise"),DI=FI,kI=lt,BI=ge,WI=kI(BI,"Set"),jI=WI,ka=EI,Ba=pi,Wa=DI,ja=jI,Na=al,Ll=ct,_t=nl,bs="[object Map]",NI="[object Object]",ms="[object Promise]",Is="[object Set]",Ss="[object WeakMap]",_s="[object DataView]",GI=_t(ka),XI=_t(Ba),HI=_t(Wa),MI=_t(ja),zI=_t(Na),ot=Ll;(ka&&ot(new ka(new ArrayBuffer(1)))!=_s||Ba&&ot(new Ba)!=bs||Wa&&ot(Wa.resolve())!=ms||ja&&ot(new ja)!=Is||Na&&ot(new Na)!=Ss)&&(ot=function(e){var t=Ll(e),r=t==NI?e.constructor:void 0,n=r?_t(r):"";if(n)switch(n){case GI:return _s;case XI:return bs;case HI:return ms;case MI:return Is;case zI:return Ss}return t});var Mt=ot,UI=Object.prototype,VI=UI.hasOwnProperty;function ZI(e){var t=e.length,r=new e.constructor(t);return t&&typeof e[0]=="string"&&VI.call(e,"index")&&(r.index=e.index,r.input=e.input),r}var qI=ZI,YI=ge,JI=YI.Uint8Array,Tl=JI,xs=Tl;function KI(e){var t=new e.constructor(e.byteLength);return new xs(t).set(new xs(e)),t}var Ci=KI,QI=Ci;function e1(e,t){var r=t?QI(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.byteLength)}var t1=e1,r1=/\w*$/;function n1(e){var t=new e.constructor(e.source,r1.exec(e));return t.lastIndex=e.lastIndex,t}var a1=n1,Os=St,ws=Os?Os.prototype:void 0,Rs=ws?ws.valueOf:void 0;function i1(e){return Rs?Object(Rs.call(e)):{}}var o1=i1,Jn,Ls;function El(){if(Ls)return Jn;Ls=1;var e=Ci;function t(r,n){var a=n?e(r.buffer):r.buffer;return new r.constructor(a,r.byteOffset,r.length)}return Jn=t,Jn}var s1=Ci,u1=t1,c1=a1,l1=o1,f1=El(),g1="[object Boolean]",p1="[object Date]",d1="[object Map]",h1="[object Number]",y1="[object RegExp]",v1="[object Set]",C1="[object String]",A1="[object Symbol]",b1="[object ArrayBuffer]",m1="[object DataView]",I1="[object Float32Array]",S1="[object Float64Array]",_1="[object Int8Array]",x1="[object Int16Array]",O1="[object Int32Array]",w1="[object Uint8Array]",R1="[object Uint8ClampedArray]",L1="[object Uint16Array]",T1="[object Uint32Array]";function E1(e,t,r){var n=e.constructor;switch(t){case b1:return s1(e);case g1:case p1:return new n(+e);case m1:return u1(e,r);case I1:case S1:case _1:case x1:case O1:case w1:case R1:case L1:case T1:return f1(e,r);case d1:return new n;case h1:case C1:return new n(e);case y1:return c1(e);case v1:return new n;case A1:return l1(e)}}var $1=E1,P1=Er,F1=vi,D1=gi;function k1(e){return typeof e.constructor=="function"&&!D1(e)?P1(F1(e)):{}}var $l=k1,B1=Mt,W1=Se,j1="[object Map]";function N1(e){return W1(e)&&B1(e)==j1}var G1=N1,X1=G1,H1=li,Ts=mt,Es=Ts&&Ts.isMap,M1=Es?H1(Es):X1,z1=M1,U1=Mt,V1=Se,Z1="[object Set]";function q1(e){return V1(e)&&U1(e)==Z1}var Y1=q1,J1=Y1,K1=li,$s=mt,Ps=$s&&$s.isSet,Q1=Ps?K1(Ps):J1,e0=Q1,t0=Gr(),r0=ii,n0=bl,a0=_l,i0=Hm,o0=Bt,s0=jt,u0=rI,c0=hI,l0=Rl,f0=wI,g0=Mt,p0=qI,d0=$1,h0=$l,y0=pe,v0=ut,C0=z1,A0=Te,b0=e0,m0=kr,I0=Ht(),S0=1,_0=2,x0=4,Pl="[object Arguments]",O0="[object Array]",w0="[object Boolean]",R0="[object Date]",L0="[object Error]",Fl="[object Function]",T0="[object GeneratorFunction]",E0="[object Map]",$0="[object Number]",Dl="[object Object]",P0="[object RegExp]",F0="[object Set]",D0="[object String]",k0="[object Symbol]",B0="[object WeakMap]",W0="[object ArrayBuffer]",j0="[object DataView]",N0="[object Float32Array]",G0="[object Float64Array]",X0="[object Int8Array]",H0="[object Int16Array]",M0="[object Int32Array]",z0="[object Uint8Array]",U0="[object Uint8ClampedArray]",V0="[object Uint16Array]",Z0="[object Uint32Array]",U={};U[Pl]=U[O0]=U[W0]=U[j0]=U[w0]=U[R0]=U[N0]=U[G0]=U[X0]=U[H0]=U[M0]=U[E0]=U[$0]=U[Dl]=U[P0]=U[F0]=U[D0]=U[k0]=U[z0]=U[U0]=U[V0]=U[Z0]=!0;U[L0]=U[Fl]=U[B0]=!1;function cr(e,t,r,n,a,i){var o,s=t&S0,u=t&_0,f=t&x0;if(r&&(o=a?r(e,n,a,i):r(e)),o!==void 0)return o;if(!A0(e))return e;var g=y0(e);if(g){if(o=p0(e),!s)return s0(e,o)}else{var c=g0(e),d=c==Fl||c==T0;if(v0(e))return o0(e,s);if(c==Dl||c==Pl||d&&!a){if(o=u||d?{}:h0(e),!s)return u?c0(e,i0(o,e)):u0(e,a0(o,e))}else{if(!U[c])return a?e:{};o=d0(e,c,s)}}i||(i=new t0);var h=i.get(e);if(h)return h;i.set(e,o),b0(e)?e.forEach(function(b){o.add(cr(b,t,r,b,e,i))}):C0(e)&&e.forEach(function(b,y){o.set(y,cr(b,t,r,y,e,i))});var v=f?u?f0:l0:u?I0:m0,m=g?void 0:v(e);return r0(m||e,function(b,y){m&&(y=b,b=e[y]),n0(o,y,cr(b,t,r,y,e,i))}),o}var kl=cr,q0=kl,Y0=4;function J0(e){return q0(e,Y0)}var K0=J0,Q0=si,eS=8;function Ai(e,t,r){t=r?void 0:t;var n=Q0(e,eS,void 0,void 0,void 0,void 0,void 0,t);return n.placeholder=Ai.placeholder,n}Ai.placeholder={};var tS=Ai,rS=ct,nS=vi,aS=Se,iS="[object Object]",oS=Function.prototype,sS=Object.prototype,Bl=oS.toString,uS=sS.hasOwnProperty,cS=Bl.call(Object);function lS(e){if(!aS(e)||rS(e)!=iS)return!1;var t=nS(e);if(t===null)return!0;var r=uS.call(t,"constructor")&&t.constructor;return typeof r=="function"&&r instanceof r&&Bl.call(r)==cS}var Wl=lS,fS=ct,gS=Se,pS=Wl,dS="[object DOMException]",hS="[object Error]";function yS(e){if(!gS(e))return!1;var t=fS(e);return t==hS||t==dS||typeof e.message=="string"&&typeof e.name=="string"&&!pS(e)}var vS=yS,CS=Mt,AS=Se,bS="[object WeakMap]";function mS(e){return AS(e)&&CS(e)==bS}var IS=mS,SS="__lodash_hash_undefined__";function _S(e){return this.__data__.set(e,SS),this}var xS=_S;function OS(e){return this.__data__.has(e)}var wS=OS,RS=di(),LS=xS,TS=wS;function vr(e){var t=-1,r=e==null?0:e.length;for(this.__data__=new RS;++t<r;)this.add(e[t])}vr.prototype.add=vr.prototype.push=LS;vr.prototype.has=TS;var ES=vr;function $S(e,t){for(var r=-1,n=e==null?0:e.length;++r<n;)if(t(e[r],r,e))return!0;return!1}var PS=$S;function FS(e,t){return e.has(t)}var DS=FS,kS=ES,BS=PS,WS=DS,jS=1,NS=2;function GS(e,t,r,n,a,i){var o=r&jS,s=e.length,u=t.length;if(s!=u&&!(o&&u>s))return!1;var f=i.get(e),g=i.get(t);if(f&&g)return f==t&&g==e;var c=-1,d=!0,h=r&NS?new kS:void 0;for(i.set(e,t),i.set(t,e);++c<s;){var v=e[c],m=t[c];if(n)var b=o?n(m,v,c,t,e,i):n(v,m,c,e,t,i);if(b!==void 0){if(b)continue;d=!1;break}if(h){if(!BS(t,function(y,A){if(!WS(h,A)&&(v===y||a(v,y,r,n,i)))return h.push(A)})){d=!1;break}}else if(!(v===m||a(v,m,r,n,i))){d=!1;break}}return i.delete(e),i.delete(t),d}var jl=GS;function XS(e){var t=-1,r=Array(e.size);return e.forEach(function(n,a){r[++t]=[a,n]}),r}var HS=XS;function MS(e){var t=-1,r=Array(e.size);return e.forEach(function(n){r[++t]=n}),r}var zS=MS,Fs=St,Ds=Tl,US=Gt(),VS=jl,ZS=HS,qS=zS,YS=1,JS=2,KS="[object Boolean]",QS="[object Date]",e_="[object Error]",t_="[object Map]",r_="[object Number]",n_="[object RegExp]",a_="[object Set]",i_="[object String]",o_="[object Symbol]",s_="[object ArrayBuffer]",u_="[object DataView]",ks=Fs?Fs.prototype:void 0,Kn=ks?ks.valueOf:void 0;function c_(e,t,r,n,a,i,o){switch(r){case u_:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case s_:return!(e.byteLength!=t.byteLength||!i(new Ds(e),new Ds(t)));case KS:case QS:case r_:return US(+e,+t);case e_:return e.name==t.name&&e.message==t.message;case n_:case i_:return e==t+"";case t_:var s=ZS;case a_:var u=n&YS;if(s||(s=qS),e.size!=t.size&&!u)return!1;var f=o.get(e);if(f)return f==t;n|=JS,o.set(e,t);var g=VS(s(e),s(t),n,a,i,o);return o.delete(e),g;case o_:if(Kn)return Kn.call(e)==Kn.call(t)}return!1}var l_=c_,Bs=Rl,f_=1,g_=Object.prototype,p_=g_.hasOwnProperty;function d_(e,t,r,n,a,i){var o=r&f_,s=Bs(e),u=s.length,f=Bs(t),g=f.length;if(u!=g&&!o)return!1;for(var c=u;c--;){var d=s[c];if(!(o?d in t:p_.call(t,d)))return!1}var h=i.get(e),v=i.get(t);if(h&&v)return h==t&&v==e;var m=!0;i.set(e,t),i.set(t,e);for(var b=o;++c<u;){d=s[c];var y=e[d],A=t[d];if(n)var x=o?n(A,y,d,t,e,i):n(y,A,d,e,t,i);if(!(x===void 0?y===A||a(y,A,r,n,i):x)){m=!1;break}b||(b=d=="constructor")}if(m&&!b){var I=e.constructor,S=t.constructor;I!=S&&"constructor"in e&&"constructor"in t&&!(typeof I=="function"&&I instanceof I&&typeof S=="function"&&S instanceof S)&&(m=!1)}return i.delete(e),i.delete(t),m}var h_=d_,Qn=Gr(),y_=jl,v_=l_,C_=h_,Ws=Mt,js=pe,Ns=ut,A_=fi(),b_=1,Gs="[object Arguments]",Xs="[object Array]",nr="[object Object]",m_=Object.prototype,Hs=m_.hasOwnProperty;function I_(e,t,r,n,a,i){var o=js(e),s=js(t),u=o?Xs:Ws(e),f=s?Xs:Ws(t);u=u==Gs?nr:u,f=f==Gs?nr:f;var g=u==nr,c=f==nr,d=u==f;if(d&&Ns(e)){if(!Ns(t))return!1;o=!0,g=!1}if(d&&!g)return i||(i=new Qn),o||A_(e)?y_(e,t,r,n,a,i):v_(e,t,u,r,n,a,i);if(!(r&b_)){var h=g&&Hs.call(e,"__wrapped__"),v=c&&Hs.call(t,"__wrapped__");if(h||v){var m=h?e.value():e,b=v?t.value():t;return i||(i=new Qn),a(m,b,r,n,i)}}return d?(i||(i=new Qn),C_(e,t,r,n,a,i)):!1}var S_=I_,__=S_,Ms=Se;function Nl(e,t,r,n,a){return e===t?!0:e==null||t==null||!Ms(e)&&!Ms(t)?e!==e&&t!==t:__(e,t,r,n,Nl,a)}var Gl=Nl,x_=Gr(),O_=Gl,w_=1,R_=2;function L_(e,t,r,n){var a=r.length,i=a,o=!n;if(e==null)return!i;for(e=Object(e);a--;){var s=r[a];if(o&&s[2]?s[1]!==e[s[0]]:!(s[0]in e))return!1}for(;++a<i;){s=r[a];var u=s[0],f=e[u],g=s[1];if(o&&s[2]){if(f===void 0&&!(u in e))return!1}else{var c=new x_;if(n)var d=n(f,g,u,e,t,c);if(!(d===void 0?O_(g,f,w_|R_,n,c):d))return!1}}return!0}var T_=L_,E_=Te;function $_(e){return e===e&&!E_(e)}var Xl=$_,P_=Xl,F_=kr;function D_(e){for(var t=F_(e),r=t.length;r--;){var n=t[r],a=e[n];t[r]=[n,a,P_(a)]}return t}var k_=D_;function B_(e,t){return function(r){return r==null?!1:r[e]===t&&(t!==void 0||e in Object(r))}}var Hl=B_,W_=T_,j_=k_,N_=Hl;function G_(e){var t=j_(e);return t.length==1&&t[0][2]?N_(t[0][0],t[0][1]):function(r){return r===e||W_(r,e,t)}}var X_=G_,H_=pe,M_=Nt,z_=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,U_=/^\w*$/;function V_(e,t){if(H_(e))return!1;var r=typeof e;return r=="number"||r=="symbol"||r=="boolean"||e==null||M_(e)?!0:U_.test(e)||!z_.test(e)||t!=null&&e in Object(t)}var bi=V_,Ml=di(),Z_="Expected a function";function mi(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(Z_);var r=function(){var n=arguments,a=t?t.apply(this,n):n[0],i=r.cache;if(i.has(a))return i.get(a);var o=e.apply(this,n);return r.cache=i.set(a,o)||i,o};return r.cache=new(mi.Cache||Ml),r}mi.Cache=Ml;var q_=mi,Y_=q_,J_=500;function K_(e){var t=Y_(e,function(n){return r.size===J_&&r.clear(),n}),r=t.cache;return t}var Q_=K_,ex=Q_,tx=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,rx=/\\(\\)?/g,nx=ex(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace(tx,function(r,n,a,i){t.push(a?i.replace(rx,"$1"):n||r)}),t}),zl=nx;function ax(e,t){for(var r=-1,n=e==null?0:e.length,a=Array(n);++r<n;)a[r]=t(e[r],r,e);return a}var Ul=ax,zs=St,ix=Ul,ox=pe,sx=Nt,ux=1/0,Us=zs?zs.prototype:void 0,Vs=Us?Us.toString:void 0;function Vl(e){if(typeof e=="string")return e;if(ox(e))return ix(e,Vl)+"";if(sx(e))return Vs?Vs.call(e):"";var t=e+"";return t=="0"&&1/e==-ux?"-0":t}var cx=Vl,lx=cx;function fx(e){return e==null?"":lx(e)}var Zl=fx,gx=pe,px=bi,dx=zl,hx=Zl;function yx(e,t){return gx(e)?e:px(e,t)?[e]:dx(hx(e))}var ql=yx,vx=Nt,Cx=1/0;function Ax(e){if(typeof e=="string"||vx(e))return e;var t=e+"";return t=="0"&&1/e==-Cx?"-0":t}var zt=Ax,bx=ql,mx=zt;function Ix(e,t){t=bx(t,e);for(var r=0,n=t.length;e!=null&&r<n;)e=e[mx(t[r++])];return r&&r==n?e:void 0}var Yl=Ix,Sx=Yl;function _x(e,t,r){var n=e==null?void 0:Sx(e,t);return n===void 0?r:n}var xx=_x;function Ox(e,t){return e!=null&&t in Object(e)}var wx=Ox,Rx=ql,Lx=Fr(),Tx=pe,Ex=Pr,$x=ci,Px=zt;function Fx(e,t,r){t=Rx(t,e);for(var n=-1,a=t.length,i=!1;++n<a;){var o=Px(t[n]);if(!(i=e!=null&&r(e,o)))break;e=e[o]}return i||++n!=a?i:(a=e==null?0:e.length,!!a&&$x(a)&&Ex(o,a)&&(Tx(e)||Lx(e)))}var Dx=Fx,kx=wx,Bx=Dx;function Wx(e,t){return e!=null&&Bx(e,t,kx)}var jx=Wx,Nx=Gl,Gx=xx,Xx=jx,Hx=bi,Mx=Xl,zx=Hl,Ux=zt,Vx=1,Zx=2;function qx(e,t){return Hx(e)&&Mx(t)?zx(Ux(e),t):function(r){var n=Gx(r,e);return n===void 0&&n===t?Xx(r,e):Nx(t,n,Vx|Zx)}}var Yx=qx;function Jx(e){return function(t){return t?.[e]}}var Kx=Jx,Qx=Yl;function eO(e){return function(t){return Qx(t,e)}}var tO=eO,rO=Kx,nO=tO,aO=bi,iO=zt;function oO(e){return aO(e)?rO(iO(e)):nO(e)}var sO=oO,uO=X_,cO=Yx,lO=Lr,fO=pe,gO=sO;function pO(e){return typeof e=="function"?e:e==null?lO:typeof e=="object"?fO(e)?cO(e[0],e[1]):uO(e):gO(e)}var dO=pO,hO=kl,yO=dO,vO=1;function CO(e){return yO(typeof e=="function"?e:hO(e,vO))}var AO=CO,Zs=St,bO=Fr(),mO=pe,qs=Zs?Zs.isConcatSpreadable:void 0;function IO(e){return mO(e)||bO(e)||!!(qs&&e&&e[qs])}var SO=IO,_O=yi,xO=SO;function Jl(e,t,r,n,a){var i=-1,o=e.length;for(r||(r=xO),a||(a=[]);++i<o;){var s=e[i];t>0&&r(s)?t>1?Jl(s,t-1,r,n,a):_O(a,s):n||(a[a.length]=s)}return a}var OO=Jl,wO=OO;function RO(e){var t=e==null?0:e.length;return t?wO(e,1):[]}var LO=RO,TO=ti,Ys=Math.max;function EO(e,t,r){return t=Ys(t===void 0?e.length-1:t,0),function(){for(var n=arguments,a=-1,i=Ys(n.length-t,0),o=Array(i);++a<i;)o[a]=n[t+a];a=-1;for(var s=Array(t+1);++a<t;)s[a]=n[a];return s[t]=r(o),TO(e,this,s)}}var Kl=EO,$O=LO,PO=Kl,FO=ai;function DO(e){return FO(PO(e,void 0,$O),e+"")}var kO=DO,BO=si,WO=kO,jO=256,NO=WO(function(e,t){return BO(e,jO,void 0,void 0,void 0,t)}),GO=NO,XO=Ul,HO=jt,MO=pe,zO=Nt,UO=zl,VO=zt,ZO=Zl;function qO(e){return MO(e)?XO(e,VO):zO(e)?[e]:HO(UO(ZO(e)))}var YO=qO,JO={ary:yb,assign:_l,clone:K0,curry:tS,forEach:ii,isArray:pe,isError:vS,isFunction:Tr,isWeakMap:IS,iteratee:AO,keys:Sl,rearg:GO,toInteger:Al,toPath:YO},KO=vh,QO=JO;function ew(e,t,r){return KO(QO,e,t,r)}var tw=ew,ea,Js;function Ql(){if(Js)return ea;Js=1;var e=ui,t=Gt();function r(n,a,i){(i!==void 0&&!t(n[a],i)||i===void 0&&!(a in n))&&e(n,a,i)}return ea=r,ea}var ta,Ks;function rw(){if(Ks)return ta;Ks=1;function e(t){return function(r,n,a){for(var i=-1,o=Object(r),s=a(r),u=s.length;u--;){var f=s[t?u:++i];if(n(o[f],f,o)===!1)break}return r}}return ta=e,ta}var ra,Qs;function nw(){if(Qs)return ra;Qs=1;var e=rw(),t=e();return ra=t,ra}var na,eu;function aw(){if(eu)return na;eu=1;var e=Dr,t=Se;function r(n){return t(n)&&e(n)}return na=r,na}var aa,tu;function ef(){if(tu)return aa;tu=1;function e(t,r){if(!(r==="constructor"&&typeof t[r]=="function")&&r!="__proto__")return t[r]}return aa=e,aa}var ia,ru;function iw(){if(ru)return ia;ru=1;var e=Xt,t=Ht();function r(n){return e(n,t(n))}return ia=r,ia}var oa,nu;function ow(){if(nu)return oa;nu=1;var e=Ql(),t=Bt,r=El(),n=jt,a=$l,i=Fr(),o=pe,s=aw(),u=ut,f=Tr,g=Te,c=Wl,d=fi(),h=ef(),v=iw();function m(b,y,A,x,I,S,D){var $=h(b,A),N=h(y,A),ne=D.get(N);if(ne){e(b,A,ne);return}var W=S?S($,N,A+"",b,y,D):void 0,F=W===void 0;if(F){var q=o(N),oe=!q&&u(N),ee=!q&&!oe&&d(N);W=N,q||oe||ee?o($)?W=$:s($)?W=n($):oe?(F=!1,W=t(N,!0)):ee?(F=!1,W=r(N,!0)):W=[]:c(N)||i(N)?(W=$,i($)?W=v($):(!g($)||f($))&&(W=a(N))):F=!1}F&&(D.set(N,W),I(W,N,x,S,D),D.delete(N)),e(b,A,W)}return oa=m,oa}var sa,au;function sw(){if(au)return sa;au=1;var e=Gr(),t=Ql(),r=nw(),n=ow(),a=Te,i=Ht(),o=ef();function s(u,f,g,c,d){u!==f&&r(f,function(h,v){if(d||(d=new e),a(h))n(u,f,v,g,s,c,d);else{var m=c?c(o(u,v),h,v+"",u,f,d):void 0;m===void 0&&(m=h),t(u,v,m)}},i)}return sa=s,sa}var ua,iu;function uw(){if(iu)return ua;iu=1;var e=Lr,t=Kl,r=ai;function n(a,i){return r(t(a,i,e),a+"")}return ua=n,ua}var ca,ou;function cw(){if(ou)return ca;ou=1;var e=Gt(),t=Dr,r=Pr,n=Te;function a(i,o,s){if(!n(s))return!1;var u=typeof o;return(u=="number"?t(s)&&r(o,s.length):u=="string"&&o in s)?e(s[o],i):!1}return ca=a,ca}var la,su;function lw(){if(su)return la;su=1;var e=uw(),t=cw();function r(n){return e(function(a,i){var o=-1,s=i.length,u=s>1?i[s-1]:void 0,f=s>2?i[2]:void 0;for(u=n.length>3&&typeof u=="function"?(s--,u):void 0,f&&t(i[0],i[1],f)&&(u=s<3?void 0:u,s=1),a=Object(a);++o<s;){var g=i[o];g&&n(a,g,o,u)}return a})}return la=r,la}var fa,uu;function fw(){if(uu)return fa;uu=1;var e=sw(),t=lw(),r=t(function(n,a,i){e(n,a,i)});return fa=r,fa}var gw=tw,tf=gw("merge",fw());tf.placeholder=el();var Ke=tf;const Ie={palette:{primary:{ultraLight:"#EDEDED",light:"#D6D6D6",main:"#7A7A7A",dark:"#626262"},secondary:{ultraLight:"#F4F4F4",light:"#787878",main:"#616161",dark:"#303030"},error:{main:"#a72514",light:"#fee5e4"},success:{main:"#286327",light:"#dcfddb"},alert:{main:"#725200",light:"#ffe7ca"},info:{main:"#195f7f",light:"#dbedfd"},gray:{main:"#706f6f",light:"#d3d3d3",ultraLight:"#f4f4f4",megaLight:"#fafafa",dark:"#373737"},black:"#000",white:"#fff",dataVisualization:{highContrast:{blueDark:"#002039",coral:"#F95D6A",purpleDark:"#665191",orange:"#FFA600",purple:"#A05195",orangeDark:"#FF7C43",blue:"#3970C1",cyan:"#45CEE0",pink:"#D12771",green:"#B3D849"},lowContrast:{blueDark:"#5283AB",coral:"#FCA6AD",purpleDark:"#B1A2D0",orange:"#FDDFA5",purple:"#D4BBFF",orangeDark:"#FCC2A9",blue:"#96B3DE",cyan:"#BAE6FF",pink:"#E995BA",green:"#DEF895"}}},spacingBase:8,borderRadius:{XS:"2px",S:"4px",M:"8px",L:"16px",XL:"32px"},breakPoints:{mobileLarge:480,tablet:768,tabletLarge:960,desktop:1280},typography:{fontWeight:{light:200,normal:400,semibold:600,bold:700},fontSize:{XXS:"10px",XS:"12px",S:"14px",M:"16px",L:"18px",XL:"20px",XXL:"24px",XXXL:"32px",XXXXL:"48px"},lineHeight:{S:"20px",M:"24px",L:"28px",XL:"32px",XXL:"48px",XXXL:"72px"},letterSpacing:{S:0,M:1,L:3,XL:5,XXL:8,XXXL:12}},card:{borderRadius:{mobile:"4px",tablet:"8px",desktop:"8px"}},elevations:{flat1:{boxShadow:"0 2px 2px rgba(0, 0, 0, 0.1)",zIndex:1},flat2:{boxShadow:"0 2px 2px rgba(0, 0, 0, 0.1)",zIndex:1e3},above:{boxShadow:"0 0 12px rgba(0, 0, 0, 0.1)",zIndex:1e3},sticky:{boxShadow:"none",zIndex:1001},raised:{boxShadow:"0 8px 8px rgba(0, 0, 0, 0.1)",zIndex:1002},raisedInverted1:{boxShadow:"0 -8px 8px rgba(0, 0, 0, 0.1)",zIndex:1002},raisedInverted2:{boxShadow:"0 -8px 8px rgba(0, 0, 0, 0.1)",zIndex:1003},popout1:{boxShadow:"0 4px 16px rgba(0, 0, 0, 0.1)",zIndex:1004},popout2:{boxShadow:"0 4px 16px rgba(0, 0, 0, 0.1)",zIndex:1005},overlay1:{boxShadow:"0 0 24px rgba(0, 0, 0, 0.1)",zIndex:1006},backdrop:{boxShadow:"none",zIndex:1007},overlay2:{boxShadow:"0 0 24px rgba(0, 0, 0, 0.1)",zIndex:1008}},grid:{mobile:{columns:4,horizontalSpace:16,verticalSpace:16,gutter:16},mobileLarge:{columns:4,horizontalSpace:16,verticalSpace:16,gutter:16},tablet:{columns:12,horizontalSpace:16,verticalSpace:24,gutter:24},tabletLarge:{columns:12,horizontalSpace:16,verticalSpace:24,gutter:24},desktop:{columns:12,horizontalSpace:16,verticalSpace:24,gutter:24},desktopLarge:{columns:12,horizontalSpace:16,verticalSpace:24,gutter:24}},defaultFontFamily:"Arial",fontFaces:[],iconSize:{small:"16px",medium:"20px",regular:"24px",large:"32px"}};class pw{constructor(){var t=this;let{borderRadius:r={},breakPoints:n={},iconSize:a={},palette:i={},spacingBase:o,typography:s={},card:u={},elevations:f={},grid:g={},fontFaces:c,defaultFontFamily:d,components:h={}}=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};te(this,"removePx",v=>parseInt(v.substring(0,v.indexOf("px")))),te(this,"mediaQuery",v=>`@media (min-width: ${this.breakPoints[v]}px)`),te(this,"getComponent",v=>this.components[v]||{}),te(this,"getComponentOverride",v=>this.components[v]||{}),te(this,"spacing",function(){let v=arguments.length>0&&arguments[0]!==void 0?arguments[0]:1;return t.spacingBase*v}),te(this,"getElevation",v=>({boxShadow:this.elevations[v].boxShadow,zIndex:this.elevations[v].zIndex})),te(this,"getCardStyle",()=>({backgroundColor:this.palette.white,borderRadius:this.card.borderRadius.mobile,[this.mediaQuery("tablet")]:{borderRadius:this.card.borderRadius.tablet},[this.mediaQuery("desktop")]:{borderRadius:this.card.borderRadius.desktop}})),te(this,"toRem",function(v){let m=arguments.length>1&&arguments[1]!==void 0?arguments[1]:t.typography.fontSize.M;return`${t.removePx(v)/t.removePx(m)}rem`}),te(this,"toEm",v=>`${v/100}em`),te(this,"toPercentage",v=>`${v*100}%`),te(this,"toRGBA",(v,m)=>{let b=v.replace("#","");b.length===3&&(b=b[0]+b[0]+b[1]+b[1]+b[2]+b[2]);const y=parseInt(b.substring(0,2),16),A=parseInt(b.substring(2,4),16),x=parseInt(b.substring(4,6),16);return`rgba(${y}, ${A}, ${x}, ${m})`}),te(this,"getLineHeight",(v,m)=>this.removePx(m)/this.removePx(v)),this.borderRadius=Ke(Ie.borderRadius,r),this.breakPoints=Ke(Ie.breakPoints,n),this.iconSize=Ke(Ie.iconSize,a),this.palette=Ke(Ie.palette,i),this.spacingBase=o||Ie.spacingBase,this.typography=Ke(Ie.typography,s),this.card=Ke(Ie.card,u),this.elevations=Ke(Ie.elevations,f),this.grid=Ke(Ie.grid,g),this.fontFaces=c||Ie.fontFaces,this.defaultFontFamily=d||Ie.defaultFontFamily,this.components=h}}let Ga;(function(e){e.ADD_FILLED="ADD_FILLED",e.ADD="ADD",e.AGENT="AGENT",e.ALERT="ALERT",e.ANALYTICS="ANALYTICS",e.CONVERSATION="CONVERSATION",e.ARROW_BOTTOM="ARROW_BOTTOM",e.ARROW_LEFT="ARROW_LEFT",e.ARROW_RIGHT="ARROW_RIGHT",e.ARROW_TOP="ARROW_TOP",e.ATTACH="ATTACH",e.AUTOMATION="AUTOMATION",e.BELL="BELL",e.BOAT="BOAT",e.BUCKET="BUCKET",e.BUFFER="BUFFER",e.CALENDAR="CALENDAR",e.CANCEL_FILLED="CANCEL_FILLED",e.CANCEL="CANCEL",e.CAR="CAR",e.CARDBOARD_BOX_CHECK="CARDBOARD_BOX_CHECK",e.CARDBOARD_BOX_SHIELD="CARDBOARD_BOX_SHIELD",e.CARDBOARD_BOX="CARDBOARD_BOX",e.CARET_BOTTOM="CARET_BOTTOM",e.CARET_TOP="CARET_TOP",e.CARGO="CARGO",e.CART="CART",e.CASH_DISABLED="CASH_DISABLED",e.CASH="CASH",e.CHART_UPWARDS="CHART_UPWARDS",e.CHECK_FILLED="CHECK_FILLED",e.CHECK_MARK="CHECK_MARK",e.CHECK="CHECK",e.CHEVRON_BOTTOM="CHEVRON_BOTTOM",e.CHEVRON_LEFT="CHEVRON_LEFT",e.CHEVRON_RIGHT="CHEVRON_RIGHT",e.CHEVRON_TOP="CHEVRON_TOP",e.CIRCLE="CIRCLE",e.CIRCULAR_ARROW="CIRCULAR_ARROW",e.CLOCK="CLOCK",e.CLOSE="CLOSE",e.COINS="COINS",e.CONTRACT="CONTRACT",e.COPY="COPY",e.CREDIT_CARD="CREDIT_CARD",e.DASH="DASH",e.DESKTOP="DESKTOP",e.DOOR_DELIVERY="DOOR_DELIVERY",e.DOTS="DOTS",e.DOWNLOAD="DOWNLOAD",e.DUPLICATE="DUPLICATE",e.ECOMMERCE="ECOMMERCE",e.EDIT="EDIT",e.EYE_DISABLED="EYE_DISABLED",e.EYE="EYE",e.FAST_DELIVERY="FAST_DELIVERY",e.FILE_LIST="FILE_LIST",e.FILE_PDF="FILE_PDF",e.FILE="FILE",e.FILTER="FILTER",e.FORKLIFT="FORKLIFT",e.FOUR="FOUR",e.FRAGILE="FRAGILE",e.GIFT="GIFT",e.GROUP="GROUP",e.HAND_BOX="HAND_BOX",e.HARD_BOX="HARD_BOX",e.HELP="HELP",e.HOURGLASS="HOURGLASS",e.HOUSE="HOUSE",e.IMPORT="IMPORT",e.INBOX="INBOX",e.INFO_FILLED="INFO_FILLED",e.INFO="INFO",e.KEY="KEY",e.LABEL="LABEL",e.LIST="LIST",e.LOGOUT_BOLD="LOGOUT_BOLD",e.LOGOUT="LOGOUT",e.MAIL="MAIL",e.MAP="MAP",e.MARGIN_PROFILE="MARGIN_PROFILE",e.MARKER_FILLED="MARKER_FILLED",e.MARKER="MARKER",e.MENU="MENU",e.MOBILE="MOBILE",e.MONEY="MONEY",e.ONE="ONE",e.OPEN_BOX="OPEN_BOX",e.PADLOCK_OPEN="PADLOCK_OPEN",e.PADLOCK="PADLOCK",e.PAGINATION_LEFT="PAGINATION_LEFT",e.PAGINATION_RIGHT="PAGINATION_RIGHT",e.PALLET="PALLET",e.PANTONE="PANTONE",e.PERCENTAGE="PERCENTAGE",e.PLANE="PLANE",e.PLUG="PLUG",e.PLUS="PLUS",e.PRINTER_DISABLED="PRINTER_DISABLED",e.PRINTER="PRINTER",e.REMOVE_FILLED="REMOVE_FILLED",e.REMOVE="REMOVE",e.ROCKET="ROCKET",e.SAVINGS="SAVINGS",e.SCAN_BARCODE="SCAN_BARCODE",e.SEARCH="SEARCH",e.SETTINGS="SETTINGS",e.SHIELD_DISABLED="SHIELD_DISABLED",e.SHIELD="SHIELD",e.SINGLE_COLLECTION="SINGLE_COLLECTION",e.SORT_ALPHA_ASC="SORT_ALPHA_ASC",e.SORT_ALPHA_DESC="SORT_ALPHA_DESC",e.SORT="SORT",e.SPEED_TRUCK="SPEED_TRUCK",e.SPINNER="SPINNER",e.STORE="STORE",e.SUBSCRIPTION="SUBSCRIPTION",e.TABLET="TABLET",e.THREE="THREE",e.TIMER="TIMER",e.TRACKING="TRACKING",e.TRAIN="TRAIN",e.TRASH="TRASH",e.TROLLEY="TROLLEY",e.TRUCK="TRUCK",e.TWO="TWO",e.USER_FILLED="USER_FILLED",e.USER="USER",e.VAN="VAN",e.WAREHOUSE="WAREHOUSE",e.WEIGHT="WEIGHT",e.WORLD_SHIPPING="WORLD_SHIPPING",e.WORLD="WORLD"})(Ga||(Ga={}));const dw=Object.freeze(Object.defineProperty({__proto__:null,get IconNames(){return Ga},Theme:pw,fallbackTheme:Ie},Symbol.toStringTag,{value:"Module"})),rf=xp(dw);var Ii={},hw=kt;const yw=(e,t,r)=>({Chip:Ue(e,t.Chip,r?.Chip),Link:Ue(e,t.Link,r?.Link),Button:Ue(e,t.Button,r?.Button),Dialog:Ue(e,t.Dialog,r?.Dialog),Typography:Ue(e,t.Typography,r?.Typography),Checkbox:Ue(e,t.Checkbox,r?.Checkbox),Field:Ue(e,t.Field,r?.Field),FieldContainer:Ue(e,t.FieldContainer,r?.FieldContainer)});function Ue(e,t,r){const n=t(e),a=r?.(e);return hw({},n,a)}Ii.createThemeComponents=yw;Ii.createThemedComponent=Ue;var vw=kt,Cw=Le,nf=rf,Aw=Ii,bw=ei;const mw=(e,t)=>Array.isArray(t)?t:void 0;function af(e){const{components:t,...r}=bw.fallback,{components:n,...a}=e,i=vw({},r,a,mw),o=new nf.Theme(i);return o.components=Aw.createThemeComponents(o,t,n),o}function Iw(e){const t=Cw[e];return af(t)}function Sw(e){return new nf.Theme(e)}Rr.buildTheme=af;Rr.createTheme=Iw;Rr.deserialize=Sw;var of={};(function(e){e.BrandName=void 0,function(t){t.DPD="dpd",t.EBAY="ebay",t.EBAY_IT="ebay_it",t.PACKLINK_CONS="packlink_cons",t.PAYPAL="paypal",t.PACKLINK_PRO="packlink_pro",t.PAYPAL_SHIPCENTER="paypal_shipcenter",t.BIGCOMMERCE="bigcommerce",t.SHIPENGINE_DASHBOARD="shipengine_dashboard",t.FALLBACK="fallback"}(e.BrandName||(e.BrandName={}))})(of);(function(e){var t=Rr,r=of,n=rf;e.buildTheme=t.buildTheme,e.createTheme=t.createTheme,e.deserialize=t.deserialize,Object.defineProperty(e,"BrandName",{enumerable:!0,get:function(){return r.BrandName}}),Object.defineProperty(e,"BorderRadiusVariables",{enumerable:!0,get:function(){return n.BorderRadiusVariables}}),Object.defineProperty(e,"BreakpointsVariables",{enumerable:!0,get:function(){return n.BreakpointsVariables}}),Object.defineProperty(e,"CardVariables",{enumerable:!0,get:function(){return n.CardVariables}}),Object.defineProperty(e,"ComponentsVariables",{enumerable:!0,get:function(){return n.ComponentsVariables}}),Object.defineProperty(e,"CustomThemeData",{enumerable:!0,get:function(){return n.CustomThemeData}}),Object.defineProperty(e,"ElevationBase",{enumerable:!0,get:function(){return n.ElevationBase}}),Object.defineProperty(e,"ElevationsVariables",{enumerable:!0,get:function(){return n.ElevationsVariables}}),Object.defineProperty(e,"FontFacesVariables",{enumerable:!0,get:function(){return n.FontFacesVariables}}),Object.defineProperty(e,"FontSizeVariables",{enumerable:!0,get:function(){return n.FontSizeVariables}}),Object.defineProperty(e,"FontWeightVariables",{enumerable:!0,get:function(){return n.FontWeightVariables}}),Object.defineProperty(e,"GridBase",{enumerable:!0,get:function(){return n.GridBase}}),Object.defineProperty(e,"GridVariables",{enumerable:!0,get:function(){return n.GridVariables}}),Object.defineProperty(e,"IconNames",{enumerable:!0,get:function(){return n.IconNames}}),Object.defineProperty(e,"IconsVariables",{enumerable:!0,get:function(){return n.IconsVariables}}),Object.defineProperty(e,"LetterSpacingVariables",{enumerable:!0,get:function(){return n.LetterSpacingVariables}}),Object.defineProperty(e,"LineHeightVariables",{enumerable:!0,get:function(){return n.LineHeightVariables}}),Object.defineProperty(e,"PaletteVariables",{enumerable:!0,get:function(){return n.PaletteVariables}}),Object.defineProperty(e,"Theme",{enumerable:!0,get:function(){return n.Theme}}),Object.defineProperty(e,"ThemeCardBorderRadius",{enumerable:!0,get:function(){return n.ThemeCardBorderRadius}}),Object.defineProperty(e,"ThemeData",{enumerable:!0,get:function(){return n.ThemeData}}),Object.defineProperty(e,"ThemePaletteColorBase",{enumerable:!0,get:function(){return n.ThemePaletteColorBase}}),Object.defineProperty(e,"ThemePaletteColorExpanded",{enumerable:!0,get:function(){return n.ThemePaletteColorExpanded}}),Object.defineProperty(e,"ThemePaletteColorGray",{enumerable:!0,get:function(){return n.ThemePaletteColorGray}}),Object.defineProperty(e,"ThemePaletteColorStandard",{enumerable:!0,get:function(){return n.ThemePaletteColorStandard}}),Object.defineProperty(e,"ThemePaletteDataVisualization",{enumerable:!0,get:function(){return n.ThemePaletteDataVisualization}}),Object.defineProperty(e,"ThemePaletteDataVisualizationColors",{enumerable:!0,get:function(){return n.ThemePaletteDataVisualizationColors}}),Object.defineProperty(e,"TypographyVariables",{enumerable:!0,get:function(){return n.TypographyVariables}})})(wr);function sf(){let e={};return{get:a=>e[a],set:(a,i)=>{e[a]=i},reset:()=>{e={}}}}const _w=Q.createContext({resolveIcon:()=>Promise.resolve(""),iconCache:sf()}),xw=e=>{let{children:t,resolveIcon:r,iconCache:n=sf()}=e;return Q.useEffect(()=>{n.reset()},[n,r]),ve(_w.Provider,{value:{resolveIcon:r,iconCache:n},children:t})},Ow=e=>t=>{const r=e?`.${e}`:"html";return Pt.css({[r]:{boxSizing:"border-box",color:t.palette.gray.dark,fontWeight:t.typography.fontWeight.normal,fontSize:t.typography.fontSize.M,lineHeight:1.15,WebkitTextSizeAdjust:"100%",...r==="html"&&{body:{margin:0}},main:{display:"block"},"*, *::before, *::after":{boxSizing:"inherit"},"h1, h2, h3, h4, h5, h6":{marginTop:0,marginBottom:t.spacing(3)},"abbr[title]":{borderBottom:"none",textDecoration:"underline dotted"},"b, strong":{fontWeight:"bolder"},code:{fontFamily:"monospace, monospace",fontSize:"1em"},"ul, ol":{margin:0,padding:0},"button, input, optgroup, select, textarea":{fontFamily:"inherit",fontSize:"100%",lineHeight:"1.15",margin:0},"button, input":{overflow:"visible"},"button, select":{textTransform:"none"},'button, [type="button"], [type="reset"], [type="submit"]':{WebkitAppearance:"button"},'button::-moz-focus-inner,[type="button"]::-moz-focus-inner, [type="reset"]::-moz-focus-inner, [type="submit"]::-moz-focus-inner':{borderStyle:"none",padding:0},'button:-moz-focusring, [type="button"]:-moz-focusring, [type="reset"]:-moz-focusring, [type="submit"]:-moz-focusring':{outline:"1px dotted ButtonText"},button:{border:0},"input[type=number]":{MozAppearance:"textfield"},"input[type=number]::-webkit-inner-spin-button, input[type=number]::-webkit-outer-spin-button":{margin:0,WebkitAppearance:"none"},"input[type=search]::-webkit-search-decoration, input[type=search]::-webkit-search-cancel-button, input[type=search]::-webkit-search-results-button, input[type=search]::-webkit-search-results-decoration":{display:"none"},'input[type="time"]::-webkit-calendar-picker-indicator':{display:"none"},textarea:{resize:"vertical"},small:{fontSize:"80%"},fieldset:{padding:`${t.spacing(.7)}px ${t.spacing(1.5)}px ${t.spacing(1.25)}px`},legend:{boxSizing:"border-box",color:"inherit",display:"table",maxWidth:"100%",padding:0,whiteSpace:"normal"},'[type="number"]::-webkit-inner-spin-button, [type="number"]::-webkit-outer-spin-button':{height:"auto"},'[type="search"]':{WebkitAppearance:"textfield",outlineOffset:"-2px"},'[type="search"]::-webkit-search-decoration':{WebkitAppearance:"none"},"::-webkit-file-upload-button":{WebkitAppearance:"button",font:"inherit"},details:{display:"block"},template:{display:"none"},"[hidden]":{display:"none"}}},process.env.NODE_ENV==="production"?"":";label:getEmotionResetStyles;",process.env.NODE_ENV==="production"?"":"/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIkVtb3Rpb25SZXNldFN0eWxlcy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFTZSIsImZpbGUiOiJFbW90aW9uUmVzZXRTdHlsZXMudHMiLCJzb3VyY2VzQ29udGVudCI6WyJpbXBvcnQgeyBjc3MsIFNlcmlhbGl6ZWRTdHlsZXMgfSBmcm9tICdAZW1vdGlvbi9yZWFjdCc7XG5cbmltcG9ydCB7IFRoZW1lIH0gZnJvbSAnQHBhY2tsaW5rL2dpZ2VyLXRoZW1lJztcblxuZXhwb3J0IGNvbnN0IGdldEVtb3Rpb25SZXNldFN0eWxlcyA9XG4gICAgKGNsYXNzTmFtZT86IHN0cmluZykgPT5cbiAgICAodGhlbWU6IFRoZW1lKTogU2VyaWFsaXplZFN0eWxlcyA9PiB7XG4gICAgICAgIGNvbnN0IHBhcmVudFNlbGVjdG9yID0gY2xhc3NOYW1lID8gYC4ke2NsYXNzTmFtZX1gIDogJ2h0bWwnO1xuXG4gICAgICAgIHJldHVybiBjc3Moe1xuICAgICAgICAgICAgW3BhcmVudFNlbGVjdG9yXToge1xuICAgICAgICAgICAgICAgIGJveFNpemluZzogJ2JvcmRlci1ib3gnLFxuICAgICAgICAgICAgICAgIGNvbG9yOiB0aGVtZS5wYWxldHRlLmdyYXkuZGFyayxcbiAgICAgICAgICAgICAgICBmb250V2VpZ2h0OiB0aGVtZS50eXBvZ3JhcGh5LmZvbnRXZWlnaHQubm9ybWFsLFxuICAgICAgICAgICAgICAgIGZvbnRTaXplOiB0aGVtZS50eXBvZ3JhcGh5LmZvbnRTaXplLk0sXG5cbiAgICAgICAgICAgICAgICAvKipcbiAgICAgICAgICAgICAgICAgKiAxLiBDb3JyZWN0IHRoZSBsaW5lIGhlaWdodCBpbiBhbGwgYnJvd3NlcnMuXG4gICAgICAgICAgICAgICAgICogMi4gUHJldmVudCBhZGp1c3RtZW50cyBvZiBmb250IHNpemUgYWZ0ZXIgb3JpZW50YXRpb24gY2hhbmdlcyBpbiBpT1MuXG4gICAgICAgICAgICAgICAgICovXG4gICAgICAgICAgICAgICAgbGluZUhlaWdodDogMS4xNSxcbiAgICAgICAgICAgICAgICBXZWJraXRUZXh0U2l6ZUFkanVzdDogJzEwMCUnLFxuXG4gICAgICAgICAgICAgICAgLyoqXG4gICAgICAgICAgICAgICAgICogUmVtb3ZlIHRoZSBtYXJnaW4gaW4gYWxsIGJyb3dzZXJzLlxuICAgICAgICAgICAgICAgICAqL1xuICAgICAgICAgICAgICAgIC4uLihwYXJlbnRTZWxlY3RvciA9PT0gJ2h0bWwnICYmIHtcbiAgICAgICAgICAgICAgICAgICAgYm9keToge1xuICAgICAgICAgICAgICAgICAgICAgICAgbWFyZ2luOiAwLFxuICAgICAgICAgICAgICAgICAgICB9LFxuICAgICAgICAgICAgICAgIH0pLFxuXG4gICAgICAgICAgICAgICAgLyoqXG4gICAgICAgICAgICAgICAgICogUmVuZGVyIHRoZSBgbWFpbmAgZWxlbWVudCBjb25zaXN0ZW50bHkgaW4gSUUuXG4gICAgICAgICAgICAgICAgICovXG4gICAgICAgICAgICAgICAgbWFpbjoge1xuICAgICAgICAgICAgICAgICAgICBkaXNwbGF5OiAnYmxvY2snLFxuICAgICAgICAgICAgICAgIH0sXG5cbiAgICAgICAgICAgICAgICAnKiwgKjo6YmVmb3JlLCAqOjphZnRlcic6IHtcbiAgICAgICAgICAgICAgICAgICAgYm94U2l6aW5nOiAnaW5oZXJpdCcsXG4gICAgICAgICAgICAgICAgfSxcblxuICAgICAgICAgICAgICAgICdoMSwgaDIsIGgzLCBoNCwgaDUsIGg2Jzoge1xuICAgICAgICAgICAgICAgICAgICBtYXJnaW5Ub3A6IDAsXG4gICAgICAgICAgICAgICAgICAgIG1hcmdpbkJvdHRvbTogdGhlbWUuc3BhY2luZygzKSxcbiAgICAgICAgICAgICAgICB9LFxuXG4gICAgICAgICAgICAgICAgLyoqXG4gICAgICAgICAgICAgICAgICogMS4gUmVtb3ZlIHRoZSBib3R0b20gYm9yZGVyIGluIENocm9tZSA1Ny1cbiAgICAgICAgICAgICAgICAgKiAyLiBBZGQgdGhlIGNvcnJlY3QgdGV4dCBkZWNvcmF0aW9uIGluIENocm9tZSwgRWRnZSwgSUUsIE9wZXJhLCBhbmQgU2FmYXJpLlxuICAgICAgICAgICAgICAgICAqL1xuICAgICAgICAgICAgICAgICdhYmJyW3RpdGxlXSc6IHtcbiAgICAgICAgICAgICAgICAgICAgYm9yZGVyQm90dG9tOiAnbm9uZScsXG4gICAgICAgICAgICAgICAgICAgIHRleHREZWNvcmF0aW9uOiAndW5kZXJsaW5lIGRvdHRlZCcsXG4gICAgICAgICAgICAgICAgfSxcblxuICAgICAgICAgICAgICAgIC8qKlxuICAgICAgICAgICAgICAgICAqIEFkZCB0aGUgY29ycmVjdCBmb250IHdlaWdodCBpbiBDaHJvbWUsIEVkZ2UsIGFuZCBTYWZhcmkuXG4gICAgICAgICAgICAgICAgICovXG5cbiAgICAgICAgICAgICAgICAnYiwgc3Ryb25nJzoge1xuICAgICAgICAgICAgICAgICAgICBmb250V2VpZ2h0OiAnYm9sZGVyJyxcbiAgICAgICAgICAgICAgICB9LFxuXG4gICAgICAgICAgICAgICAgY29kZToge1xuICAgICAgICAgICAgICAgICAgICBmb250RmFtaWx5OiAnbW9ub3NwYWNlLCBtb25vc3BhY2UnLFxuICAgICAgICAgICAgICAgICAgICBmb250U2l6ZTogJzFlbScsXG4gICAgICAgICAgICAgICAgfSxcblxuICAgICAgICAgICAgICAgICd1bCwgb2wnOiB7XG4gICAgICAgICAgICAgICAgICAgIG1hcmdpbjogMCxcbiAgICAgICAgICAgICAgICAgICAgcGFkZGluZzogMCxcbiAgICAgICAgICAgICAgICB9LFxuXG4gICAgICAgICAgICAgICAgLyoqXG4gICAgICAgICAgICAgICAgICogMS4gQ2hhbmdlIHRoZSBmb250IHN0eWxlcyBpbiBhbGwgYnJvd3NlcnMuXG4gICAgICAgICAgICAgICAgICogMi4gUmVtb3ZlIHRoZSBtYXJnaW4gaW4gRmlyZWZveCBhbmQgU2FmYXJpLlxuICAgICAgICAgICAgICAgICAqL1xuICAgICAgICAgICAgICAgICdidXR0b24sIGlucHV0LCBvcHRncm91cCwgc2VsZWN0LCB0ZXh0YXJlYSc6IHtcbiAgICAgICAgICAgICAgICAgICAgZm9udEZhbWlseTogJ2luaGVyaXQnLFxuICAgICAgICAgICAgICAgICAgICBmb250U2l6ZTogJzEwMCUnLFxuICAgICAgICAgICAgICAgICAgICBsaW5lSGVpZ2h0OiAnMS4xNScsXG4gICAgICAgICAgICAgICAgICAgIG1hcmdpbjogMCxcbiAgICAgICAgICAgICAgICB9LFxuXG4gICAgICAgICAgICAgICAgLyoqXG4gICAgICAgICAgICAgICAgICogU2hvdyB0aGUgb3ZlcmZsb3cgaW4gSUUuXG4gICAgICAgICAgICAgICAgICogMS4gU2hvdyB0aGUgb3ZlcmZsb3cgaW4gRWRnZS5cbiAgICAgICAgICAgICAgICAgKi9cbiAgICAgICAgICAgICAgICAnYnV0dG9uLCBpbnB1dCc6IHtcbiAgICAgICAgICAgICAgICAgICAgb3ZlcmZsb3c6ICd2aXNpYmxlJyxcbiAgICAgICAgICAgICAgICB9LFxuXG4gICAgICAgICAgICAgICAgLyoqXG4gICAgICAgICAgICAgICAgICogUmVtb3ZlIHRoZSBpbmhlcml0YW5jZSBvZiB0ZXh0IHRyYW5zZm9ybSBpbiBFZGdlLCBGaXJlZm94LCBhbmQgSUUuXG4gICAgICAgICAgICAgICAgICogMS4gUmVtb3ZlIHRoZSBpbmhlcml0YW5jZSBvZiB0ZXh0IHRyYW5zZm9ybSBpbiBGaXJlZm94LlxuICAgICAgICAgICAgICAgICAqL1xuICAgICAgICAgICAgICAgICdidXR0b24sIHNlbGVjdCc6IHtcbiAgICAgICAgICAgICAgICAgICAgdGV4dFRyYW5zZm9ybTogJ25vbmUnLFxuICAgICAgICAgICAgICAgIH0sXG5cbiAgICAgICAgICAgICAgICAnYnV0dG9uLCBbdHlwZT1cImJ1dHRvblwiXSwgW3R5cGU9XCJyZXNldFwiXSwgW3R5cGU9XCJzdWJtaXRcIl0nOiB7XG4gICAgICAgICAgICAgICAgICAgIFdlYmtpdEFwcGVhcmFuY2U6ICdidXR0b24nLFxuICAgICAgICAgICAgICAgIH0sXG5cbiAgICAgICAgICAgICAgICAvKipcbiAgICAgICAgICAgICAgICAgKiBSZW1vdmUgdGhlIGlubmVyIGJvcmRlciBhbmQgcGFkZGluZyBpbiBGaXJlZm94LlxuICAgICAgICAgICAgICAgICAqL1xuICAgICAgICAgICAgICAgICdidXR0b246Oi1tb3otZm9jdXMtaW5uZXIsW3R5cGU9XCJidXR0b25cIl06Oi1tb3otZm9jdXMtaW5uZXIsIFt0eXBlPVwicmVzZXRcIl06Oi1tb3otZm9jdXMtaW5uZXIsIFt0eXBlPVwic3VibWl0XCJdOjotbW96LWZvY3VzLWlubmVyJzpcbiAgICAgICAgICAgICAgICAgICAge1xuICAgICAgICAgICAgICAgICAgICAgICAgYm9yZGVyU3R5bGU6ICdub25lJyxcbiAgICAgICAgICAgICAgICAgICAgICAgIHBhZGRpbmc6IDAsXG4gICAgICAgICAgICAgICAgICAgIH0sXG5cbiAgICAgICAgICAgICAgICAvKipcbiAgICAgICAgICAgICAgICAgKiBSZXN0b3JlIHRoZSBmb2N1cyBzdHlsZXMgdW5zZXQgYnkgdGhlIHByZXZpb3VzIHJ1bGUuXG4gICAgICAgICAgICAgICAgICovXG4gICAgICAgICAgICAgICAgJ2J1dHRvbjotbW96LWZvY3VzcmluZywgW3R5cGU9XCJidXR0b25cIl06LW1vei1mb2N1c3JpbmcsIFt0eXBlPVwicmVzZXRcIl06LW1vei1mb2N1c3JpbmcsIFt0eXBlPVwic3VibWl0XCJdOi1tb3otZm9jdXNyaW5nJzpcbiAgICAgICAgICAgICAgICAgICAge1xuICAgICAgICAgICAgICAgICAgICAgICAgb3V0bGluZTogJzFweCBkb3R0ZWQgQnV0dG9uVGV4dCcsXG4gICAgICAgICAgICAgICAgICAgIH0sXG5cbiAgICAgICAgICAgICAgICBidXR0b246IHtcbiAgICAgICAgICAgICAgICAgICAgYm9yZGVyOiAwLFxuICAgICAgICAgICAgICAgIH0sXG5cbiAgICAgICAgICAgICAgICAnaW5wdXRbdHlwZT1udW1iZXJdJzoge1xuICAgICAgICAgICAgICAgICAgICBNb3pBcHBlYXJhbmNlOiAndGV4dGZpZWxkJyxcbiAgICAgICAgICAgICAgICB9LFxuXG4gICAgICAgICAgICAgICAgJ2lucHV0W3R5cGU9bnVtYmVyXTo6LXdlYmtpdC1pbm5lci1zcGluLWJ1dHRvbiwgaW5wdXRbdHlwZT1udW1iZXJdOjotd2Via2l0LW91dGVyLXNwaW4tYnV0dG9uJzoge1xuICAgICAgICAgICAgICAgICAgICBtYXJnaW46IDAsXG4gICAgICAgICAgICAgICAgICAgIFdlYmtpdEFwcGVhcmFuY2U6ICdub25lJyxcbiAgICAgICAgICAgICAgICB9LFxuXG4gICAgICAgICAgICAgICAgJ2lucHV0W3R5cGU9c2VhcmNoXTo6LXdlYmtpdC1zZWFyY2gtZGVjb3JhdGlvbiwgaW5wdXRbdHlwZT1zZWFyY2hdOjotd2Via2l0LXNlYXJjaC1jYW5jZWwtYnV0dG9uLCBpbnB1dFt0eXBlPXNlYXJjaF06Oi13ZWJraXQtc2VhcmNoLXJlc3VsdHMtYnV0dG9uLCBpbnB1dFt0eXBlPXNlYXJjaF06Oi13ZWJraXQtc2VhcmNoLXJlc3VsdHMtZGVjb3JhdGlvbic6XG4gICAgICAgICAgICAgICAgICAgIHtcbiAgICAgICAgICAgICAgICAgICAgICAgIGRpc3BsYXk6ICdub25lJyxcbiAgICAgICAgICAgICAgICAgICAgfSxcblxuICAgICAgICAgICAgICAgICdpbnB1dFt0eXBlPVwidGltZVwiXTo6LXdlYmtpdC1jYWxlbmRhci1waWNrZXItaW5kaWNhdG9yJzoge1xuICAgICAgICAgICAgICAgICAgICBkaXNwbGF5OiAnbm9uZScsXG4gICAgICAgICAgICAgICAgfSxcblxuICAgICAgICAgICAgICAgIC8qKlxuICAgICAgICAgICAgICAgICAqIFJlbW92ZSB0aGUgZGVmYXVsdCB2ZXJ0aWNhbCBzY3JvbGxiYXIgaW4gSUUgMTArLlxuICAgICAgICAgICAgICAgICAqL1xuICAgICAgICAgICAgICAgIHRleHRhcmVhOiB7XG4gICAgICAgICAgICAgICAgICAgIHJlc2l6ZTogJ3ZlcnRpY2FsJyxcbiAgICAgICAgICAgICAgICB9LFxuXG4gICAgICAgICAgICAgICAgLyoqXG4gICAgICAgICAgICAgICAgICogQWRkIHRoZSBjb3JyZWN0IGZvbnQgc2l6ZSBpbiBhbGwgYnJvd3NlcnMuXG4gICAgICAgICAgICAgICAgICovXG4gICAgICAgICAgICAgICAgc21hbGw6IHtcbiAgICAgICAgICAgICAgICAgICAgZm9udFNpemU6ICc4MCUnLFxuICAgICAgICAgICAgICAgIH0sXG5cbiAgICAgICAgICAgICAgICAvKipcbiAgICAgICAgICAgICAgICAgKiBDb3JyZWN0IHRoZSBwYWRkaW5nIGluIEZpcmVmb3guXG4gICAgICAgICAgICAgICAgICovXG4gICAgICAgICAgICAgICAgZmllbGRzZXQ6IHtcbiAgICAgICAgICAgICAgICAgICAgcGFkZGluZzogYCR7dGhlbWUuc3BhY2luZygwLjcpfXB4ICR7dGhlbWUuc3BhY2luZygxLjUpfXB4ICR7dGhlbWUuc3BhY2luZygxLjI1KX1weGAsXG4gICAgICAgICAgICAgICAgfSxcblxuICAgICAgICAgICAgICAgIC8qKlxuICAgICAgICAgICAgICAgICAqIDEuIENvcnJlY3QgdGhlIHRleHQgd3JhcHBpbmcgaW4gRWRnZSBhbmQgSUUuXG4gICAgICAgICAgICAgICAgICogMi4gQ29ycmVjdCB0aGUgY29sb3IgaW5oZXJpdGFuY2UgZnJvbSBgZmllbGRzZXRgIGVsZW1lbnRzIGluIElFLlxuICAgICAgICAgICAgICAgICAqIDMuIFJlbW92ZSB0aGUgcGFkZGluZyBzbyBkZXZlbG9wZXJzIGFyZSBub3QgY2F1Z2h0IG91dCB3aGVuIHRoZXkgemVybyBvdXRcbiAgICAgICAgICAgICAgICAgKiAgICBgZmllbGRzZXRgIGVsZW1lbnRzIGluIGFsbCBicm93c2Vycy5cbiAgICAgICAgICAgICAgICAgKi9cbiAgICAgICAgICAgICAgICBsZWdlbmQ6IHtcbiAgICAgICAgICAgICAgICAgICAgYm94U2l6aW5nOiAnYm9yZGVyLWJveCcsXG4gICAgICAgICAgICAgICAgICAgIGNvbG9yOiAnaW5oZXJpdCcsXG4gICAgICAgICAgICAgICAgICAgIGRpc3BsYXk6ICd0YWJsZScsXG4gICAgICAgICAgICAgICAgICAgIG1heFdpZHRoOiAnMTAwJScsXG4gICAgICAgICAgICAgICAgICAgIHBhZGRpbmc6IDAsXG4gICAgICAgICAgICAgICAgICAgIHdoaXRlU3BhY2U6ICdub3JtYWwnLFxuICAgICAgICAgICAgICAgIH0sXG5cbiAgICAgICAgICAgICAgICAvKipcbiAgICAgICAgICAgICAgICAgKiBDb3JyZWN0IHRoZSBjdXJzb3Igc3R5bGUgb2YgaW5jcmVtZW50IGFuZCBkZWNyZW1lbnQgYnV0dG9ucyBpbiBDaHJvbWUuXG4gICAgICAgICAgICAgICAgICovXG4gICAgICAgICAgICAgICAgJ1t0eXBlPVwibnVtYmVyXCJdOjotd2Via2l0LWlubmVyLXNwaW4tYnV0dG9uLCBbdHlwZT1cIm51bWJlclwiXTo6LXdlYmtpdC1vdXRlci1zcGluLWJ1dHRvbic6IHtcbiAgICAgICAgICAgICAgICAgICAgaGVpZ2h0OiAnYXV0bycsXG4gICAgICAgICAgICAgICAgfSxcblxuICAgICAgICAgICAgICAgIC8qKlxuICAgICAgICAgICAgICAgICAqIDEuIENvcnJlY3QgdGhlIG9kZCBhcHBlYXJhbmNlIGluIENocm9tZSBhbmQgU2FmYXJpLlxuICAgICAgICAgICAgICAgICAqIDIuIENvcnJlY3QgdGhlIG91dGxpbmUgc3R5bGUgaW4gU2FmYXJpLlxuICAgICAgICAgICAgICAgICAqL1xuICAgICAgICAgICAgICAgICdbdHlwZT1cInNlYXJjaFwiXSc6IHtcbiAgICAgICAgICAgICAgICAgICAgV2Via2l0QXBwZWFyYW5jZTogJ3RleHRmaWVsZCcsXG4gICAgICAgICAgICAgICAgICAgIG91dGxpbmVPZmZzZXQ6ICctMnB4JyxcbiAgICAgICAgICAgICAgICB9LFxuXG4gICAgICAgICAgICAgICAgLyoqXG4gICAgICAgICAgICAgICAgICogUmVtb3ZlIHRoZSBpbm5lciBwYWRkaW5nIGluIENocm9tZSBhbmQgU2FmYXJpIG9uIG1hY09TLlxuICAgICAgICAgICAgICAgICAqL1xuICAgICAgICAgICAgICAgICdbdHlwZT1cInNlYXJjaFwiXTo6LXdlYmtpdC1zZWFyY2gtZGVjb3JhdGlvbic6IHtcbiAgICAgICAgICAgICAgICAgICAgV2Via2l0QXBwZWFyYW5jZTogJ25vbmUnLFxuICAgICAgICAgICAgICAgIH0sXG5cbiAgICAgICAgICAgICAgICAvKipcbiAgICAgICAgICAgICAgICAgKiAxLiBDb3JyZWN0IHRoZSBpbmFiaWxpdHkgdG8gc3R5bGUgY2xpY2thYmxlIHR5cGVzIGluIGlPUyBhbmQgU2FmYXJpLlxuICAgICAgICAgICAgICAgICAqIDIuIENoYW5nZSBmb250IHByb3BlcnRpZXMgdG8gYGluaGVyaXRgIGluIFNhZmFyaS5cbiAgICAgICAgICAgICAgICAgKi9cbiAgICAgICAgICAgICAgICAnOjotd2Via2l0LWZpbGUtdXBsb2FkLWJ1dHRvbic6IHtcbiAgICAgICAgICAgICAgICAgICAgV2Via2l0QXBwZWFyYW5jZTogJ2J1dHRvbicsXG4gICAgICAgICAgICAgICAgICAgIGZvbnQ6ICdpbmhlcml0JyxcbiAgICAgICAgICAgICAgICB9LFxuXG4gICAgICAgICAgICAgICAgLypcbiAgICAgICAgICAgICAgICAgKiBBZGQgdGhlIGNvcnJlY3QgZGlzcGxheSBpbiBFZGdlLCBJRSAxMCssIGFuZCBGaXJlZm94LlxuICAgICAgICAgICAgICAgICAqL1xuICAgICAgICAgICAgICAgIGRldGFpbHM6IHtcbiAgICAgICAgICAgICAgICAgICAgZGlzcGxheTogJ2Jsb2NrJyxcbiAgICAgICAgICAgICAgICB9LFxuXG4gICAgICAgICAgICAgICAgLyoqXG4gICAgICAgICAgICAgICAgICogQWRkIHRoZSBjb3JyZWN0IGRpc3BsYXkgaW4gSUUgMTArLlxuICAgICAgICAgICAgICAgICAqL1xuICAgICAgICAgICAgICAgIHRlbXBsYXRlOiB7XG4gICAgICAgICAgICAgICAgICAgIGRpc3BsYXk6ICdub25lJyxcbiAgICAgICAgICAgICAgICB9LFxuXG4gICAgICAgICAgICAgICAgLyoqXG4gICAgICAgICAgICAgICAgICogQWRkIHRoZSBjb3JyZWN0IGRpc3BsYXkgaW4gSUUgMTArLlxuICAgICAgICAgICAgICAgICAqL1xuICAgICAgICAgICAgICAgICdbaGlkZGVuXSc6IHtcbiAgICAgICAgICAgICAgICAgICAgZGlzcGxheTogJ25vbmUnLFxuICAgICAgICAgICAgICAgIH0sXG4gICAgICAgICAgICB9LFxuICAgICAgICB9KTtcbiAgICB9O1xuIl19 */")};var uf={};Object.defineProperty(uf,"__esModule",{value:!0});var ww=uf.default=function(){};const cf=({cdnURL:e,scope:t,theme:r})=>{const[n,a]=Q.useState();return Q.useEffect(()=>{(async()=>{try{const i=r?.fontFaces??[];await Promise.all(i.map(async({family:o,source:s,descriptors:u})=>{const f=s.map(g=>`url(${g.replace("$cdnUrl",e)})`).join(", ");try{const c=await new FontFace(o,f,u).load();document.fonts.add(c)}catch(g){console.error(g)}})),a(r?.defaultFontFamily)}catch(i){st.logger.error({error:i},"Error loading fonts")}})()},[e,r]),Pt.css({[`.${t}`]:{fontFamily:n}})};var Xa={},Rw={get exports(){return Xa},set exports(e){Xa=e}},Cr={},Lw={get exports(){return Cr},set exports(e){Cr=e}},lf=function(t,r){return function(){for(var a=new Array(arguments.length),i=0;i<a.length;i++)a[i]=arguments[i];return t.apply(r,a)}},Tw=lf,rt=Object.prototype.toString;function Si(e){return Array.isArray(e)}function Ha(e){return typeof e>"u"}function Ew(e){return e!==null&&!Ha(e)&&e.constructor!==null&&!Ha(e.constructor)&&typeof e.constructor.isBuffer=="function"&&e.constructor.isBuffer(e)}function ff(e){return rt.call(e)==="[object ArrayBuffer]"}function $w(e){return rt.call(e)==="[object FormData]"}function Pw(e){var t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&ff(e.buffer),t}function Fw(e){return typeof e=="string"}function Dw(e){return typeof e=="number"}function gf(e){return e!==null&&typeof e=="object"}function lr(e){if(rt.call(e)!=="[object Object]")return!1;var t=Object.getPrototypeOf(e);return t===null||t===Object.prototype}function kw(e){return rt.call(e)==="[object Date]"}function Bw(e){return rt.call(e)==="[object File]"}function Ww(e){return rt.call(e)==="[object Blob]"}function pf(e){return rt.call(e)==="[object Function]"}function jw(e){return gf(e)&&pf(e.pipe)}function Nw(e){return rt.call(e)==="[object URLSearchParams]"}function Gw(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}function Xw(){return typeof navigator<"u"&&(navigator.product==="ReactNative"||navigator.product==="NativeScript"||navigator.product==="NS")?!1:typeof window<"u"&&typeof document<"u"}function _i(e,t){if(!(e===null||typeof e>"u"))if(typeof e!="object"&&(e=[e]),Si(e))for(var r=0,n=e.length;r<n;r++)t.call(null,e[r],r,e);else for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&t.call(null,e[a],a,e)}function Ma(){var e={};function t(a,i){lr(e[i])&&lr(a)?e[i]=Ma(e[i],a):lr(a)?e[i]=Ma({},a):Si(a)?e[i]=a.slice():e[i]=a}for(var r=0,n=arguments.length;r<n;r++)_i(arguments[r],t);return e}function Hw(e,t,r){return _i(t,function(a,i){r&&typeof a=="function"?e[i]=Tw(a,r):e[i]=a}),e}function Mw(e){return e.charCodeAt(0)===65279&&(e=e.slice(1)),e}var de={isArray:Si,isArrayBuffer:ff,isBuffer:Ew,isFormData:$w,isArrayBufferView:Pw,isString:Fw,isNumber:Dw,isObject:gf,isPlainObject:lr,isUndefined:Ha,isDate:kw,isFile:Bw,isBlob:Ww,isFunction:pf,isStream:jw,isURLSearchParams:Nw,isStandardBrowserEnv:Xw,forEach:_i,merge:Ma,extend:Hw,trim:Gw,stripBOM:Mw},dt=de;function cu(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}var df=function(t,r,n){if(!r)return t;var a;if(n)a=n(r);else if(dt.isURLSearchParams(r))a=r.toString();else{var i=[];dt.forEach(r,function(u,f){u===null||typeof u>"u"||(dt.isArray(u)?f=f+"[]":u=[u],dt.forEach(u,function(c){dt.isDate(c)?c=c.toISOString():dt.isObject(c)&&(c=JSON.stringify(c)),i.push(cu(f)+"="+cu(c))}))}),a=i.join("&")}if(a){var o=t.indexOf("#");o!==-1&&(t=t.slice(0,o)),t+=(t.indexOf("?")===-1?"?":"&")+a}return t},zw=de;function Xr(){this.handlers=[]}Xr.prototype.use=function(t,r,n){return this.handlers.push({fulfilled:t,rejected:r,synchronous:n?n.synchronous:!1,runWhen:n?n.runWhen:null}),this.handlers.length-1};Xr.prototype.eject=function(t){this.handlers[t]&&(this.handlers[t]=null)};Xr.prototype.forEach=function(t){zw.forEach(this.handlers,function(n){n!==null&&t(n)})};var Uw=Xr,Vw=de,Zw=function(t,r){Vw.forEach(t,function(a,i){i!==r&&i.toUpperCase()===r.toUpperCase()&&(t[r]=a,delete t[i])})},hf=function(t,r,n,a,i){return t.config=r,n&&(t.code=n),t.request=a,t.response=i,t.isAxiosError=!0,t.toJSON=function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:this.config,code:this.code,status:this.response&&this.response.status?this.response.status:null}},t},yf={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},ga,lu;function vf(){if(lu)return ga;lu=1;var e=hf;return ga=function(r,n,a,i,o){var s=new Error(r);return e(s,n,a,i,o)},ga}var pa,fu;function qw(){if(fu)return pa;fu=1;var e=vf();return pa=function(r,n,a){var i=a.config.validateStatus;!a.status||!i||i(a.status)?r(a):n(e("Request failed with status code "+a.status,a.config,null,a.request,a))},pa}var da,gu;function Yw(){if(gu)return da;gu=1;var e=de;return da=e.isStandardBrowserEnv()?function(){return{write:function(n,a,i,o,s,u){var f=[];f.push(n+"="+encodeURIComponent(a)),e.isNumber(i)&&f.push("expires="+new Date(i).toGMTString()),e.isString(o)&&f.push("path="+o),e.isString(s)&&f.push("domain="+s),u===!0&&f.push("secure"),document.cookie=f.join("; ")},read:function(n){var a=document.cookie.match(new RegExp("(^|;\\s*)("+n+")=([^;]*)"));return a?decodeURIComponent(a[3]):null},remove:function(n){this.write(n,"",Date.now()-864e5)}}}():function(){return{write:function(){},read:function(){return null},remove:function(){}}}(),da}var ha,pu;function Jw(){return pu||(pu=1,ha=function(t){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(t)}),ha}var ya,du;function Kw(){return du||(du=1,ya=function(t,r){return r?t.replace(/\/+$/,"")+"/"+r.replace(/^\/+/,""):t}),ya}var va,hu;function Qw(){if(hu)return va;hu=1;var e=Jw(),t=Kw();return va=function(n,a){return n&&!e(a)?t(n,a):a},va}var Ca,yu;function eR(){if(yu)return Ca;yu=1;var e=de,t=["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"];return Ca=function(n){var a={},i,o,s;return n&&e.forEach(n.split(`
29
29
  `),function(f){if(s=f.indexOf(":"),i=e.trim(f.substr(0,s)).toLowerCase(),o=e.trim(f.substr(s+1)),i){if(a[i]&&t.indexOf(i)>=0)return;i==="set-cookie"?a[i]=(a[i]?a[i]:[]).concat([o]):a[i]=a[i]?a[i]+", "+o:o}}),a},Ca}var Aa,vu;function tR(){if(vu)return Aa;vu=1;var e=de;return Aa=e.isStandardBrowserEnv()?function(){var r=/(msie|trident)/i.test(navigator.userAgent),n=document.createElement("a"),a;function i(o){var s=o;return r&&(n.setAttribute("href",s),s=n.href),n.setAttribute("href",s),{href:n.href,protocol:n.protocol?n.protocol.replace(/:$/,""):"",host:n.host,search:n.search?n.search.replace(/^\?/,""):"",hash:n.hash?n.hash.replace(/^#/,""):"",hostname:n.hostname,port:n.port,pathname:n.pathname.charAt(0)==="/"?n.pathname:"/"+n.pathname}}return a=i(window.location.href),function(s){var u=e.isString(s)?i(s):s;return u.protocol===a.protocol&&u.host===a.host}}():function(){return function(){return!0}}(),Aa}var ba,Cu;function Hr(){if(Cu)return ba;Cu=1;function e(t){this.message=t}return e.prototype.toString=function(){return"Cancel"+(this.message?": "+this.message:"")},e.prototype.__CANCEL__=!0,ba=e,ba}var ma,Au;function bu(){if(Au)return ma;Au=1;var e=de,t=qw(),r=Yw(),n=df,a=Qw(),i=eR(),o=tR(),s=vf(),u=yf,f=Hr();return ma=function(c){return new Promise(function(h,v){var m=c.data,b=c.headers,y=c.responseType,A;function x(){c.cancelToken&&c.cancelToken.unsubscribe(A),c.signal&&c.signal.removeEventListener("abort",A)}e.isFormData(m)&&delete b["Content-Type"];var I=new XMLHttpRequest;if(c.auth){var S=c.auth.username||"",D=c.auth.password?unescape(encodeURIComponent(c.auth.password)):"";b.Authorization="Basic "+btoa(S+":"+D)}var $=a(c.baseURL,c.url);I.open(c.method.toUpperCase(),n($,c.params,c.paramsSerializer),!0),I.timeout=c.timeout;function N(){if(I){var W="getAllResponseHeaders"in I?i(I.getAllResponseHeaders()):null,F=!y||y==="text"||y==="json"?I.responseText:I.response,q={data:F,status:I.status,statusText:I.statusText,headers:W,config:c,request:I};t(function(ee){h(ee),x()},function(ee){v(ee),x()},q),I=null}}if("onloadend"in I?I.onloadend=N:I.onreadystatechange=function(){!I||I.readyState!==4||I.status===0&&!(I.responseURL&&I.responseURL.indexOf("file:")===0)||setTimeout(N)},I.onabort=function(){I&&(v(s("Request aborted",c,"ECONNABORTED",I)),I=null)},I.onerror=function(){v(s("Network Error",c,null,I)),I=null},I.ontimeout=function(){var F=c.timeout?"timeout of "+c.timeout+"ms exceeded":"timeout exceeded",q=c.transitional||u;c.timeoutErrorMessage&&(F=c.timeoutErrorMessage),v(s(F,c,q.clarifyTimeoutError?"ETIMEDOUT":"ECONNABORTED",I)),I=null},e.isStandardBrowserEnv()){var ne=(c.withCredentials||o($))&&c.xsrfCookieName?r.read(c.xsrfCookieName):void 0;ne&&(b[c.xsrfHeaderName]=ne)}"setRequestHeader"in I&&e.forEach(b,function(F,q){typeof m>"u"&&q.toLowerCase()==="content-type"?delete b[q]:I.setRequestHeader(q,F)}),e.isUndefined(c.withCredentials)||(I.withCredentials=!!c.withCredentials),y&&y!=="json"&&(I.responseType=c.responseType),typeof c.onDownloadProgress=="function"&&I.addEventListener("progress",c.onDownloadProgress),typeof c.onUploadProgress=="function"&&I.upload&&I.upload.addEventListener("progress",c.onUploadProgress),(c.cancelToken||c.signal)&&(A=function(W){I&&(v(!W||W&&W.type?new f("canceled"):W),I.abort(),I=null)},c.cancelToken&&c.cancelToken.subscribe(A),c.signal&&(c.signal.aborted?A():c.signal.addEventListener("abort",A))),m||(m=null),I.send(m)})},ma}var se=de,mu=Zw,rR=hf,nR=yf,aR={"Content-Type":"application/x-www-form-urlencoded"};function Iu(e,t){!se.isUndefined(e)&&se.isUndefined(e["Content-Type"])&&(e["Content-Type"]=t)}function iR(){var e;return(typeof XMLHttpRequest<"u"||typeof process<"u"&&Object.prototype.toString.call(process)==="[object process]")&&(e=bu()),e}function oR(e,t,r){if(se.isString(e))try{return(t||JSON.parse)(e),se.trim(e)}catch(n){if(n.name!=="SyntaxError")throw n}return(r||JSON.stringify)(e)}var Mr={transitional:nR,adapter:iR(),transformRequest:[function(t,r){return mu(r,"Accept"),mu(r,"Content-Type"),se.isFormData(t)||se.isArrayBuffer(t)||se.isBuffer(t)||se.isStream(t)||se.isFile(t)||se.isBlob(t)?t:se.isArrayBufferView(t)?t.buffer:se.isURLSearchParams(t)?(Iu(r,"application/x-www-form-urlencoded;charset=utf-8"),t.toString()):se.isObject(t)||r&&r["Content-Type"]==="application/json"?(Iu(r,"application/json"),oR(t)):t}],transformResponse:[function(t){var r=this.transitional||Mr.transitional,n=r&&r.silentJSONParsing,a=r&&r.forcedJSONParsing,i=!n&&this.responseType==="json";if(i||a&&se.isString(t)&&t.length)try{return JSON.parse(t)}catch(o){if(i)throw o.name==="SyntaxError"?rR(o,this,"E_JSON_PARSE"):o}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};se.forEach(["delete","get","head"],function(t){Mr.headers[t]={}});se.forEach(["post","put","patch"],function(t){Mr.headers[t]=se.merge(aR)});var xi=Mr,sR=de,uR=xi,cR=function(t,r,n){var a=this||uR;return sR.forEach(n,function(o){t=o.call(a,t,r)}),t},Ia,Su;function Cf(){return Su||(Su=1,Ia=function(t){return!!(t&&t.__CANCEL__)}),Ia}var _u=de,Sa=cR,lR=Cf(),fR=xi,gR=Hr();function _a(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new gR("canceled")}var pR=function(t){_a(t),t.headers=t.headers||{},t.data=Sa.call(t,t.data,t.headers,t.transformRequest),t.headers=_u.merge(t.headers.common||{},t.headers[t.method]||{},t.headers),_u.forEach(["delete","get","head","post","put","patch","common"],function(a){delete t.headers[a]});var r=t.adapter||fR.adapter;return r(t).then(function(a){return _a(t),a.data=Sa.call(t,a.data,a.headers,t.transformResponse),a},function(a){return lR(a)||(_a(t),a&&a.response&&(a.response.data=Sa.call(t,a.response.data,a.response.headers,t.transformResponse))),Promise.reject(a)})},ye=de,Af=function(t,r){r=r||{};var n={};function a(g,c){return ye.isPlainObject(g)&&ye.isPlainObject(c)?ye.merge(g,c):ye.isPlainObject(c)?ye.merge({},c):ye.isArray(c)?c.slice():c}function i(g){if(ye.isUndefined(r[g])){if(!ye.isUndefined(t[g]))return a(void 0,t[g])}else return a(t[g],r[g])}function o(g){if(!ye.isUndefined(r[g]))return a(void 0,r[g])}function s(g){if(ye.isUndefined(r[g])){if(!ye.isUndefined(t[g]))return a(void 0,t[g])}else return a(void 0,r[g])}function u(g){if(g in r)return a(t[g],r[g]);if(g in t)return a(void 0,t[g])}var f={url:o,method:o,data:o,baseURL:s,transformRequest:s,transformResponse:s,paramsSerializer:s,timeout:s,timeoutMessage:s,withCredentials:s,adapter:s,responseType:s,xsrfCookieName:s,xsrfHeaderName:s,onUploadProgress:s,onDownloadProgress:s,decompress:s,maxContentLength:s,maxBodyLength:s,transport:s,httpAgent:s,httpsAgent:s,cancelToken:s,socketPath:s,responseEncoding:s,validateStatus:u};return ye.forEach(Object.keys(t).concat(Object.keys(r)),function(c){var d=f[c]||i,h=d(c);ye.isUndefined(h)&&d!==u||(n[c]=h)}),n},xa,xu;function bf(){return xu||(xu=1,xa={version:"0.26.1"}),xa}var dR=bf().version,Oi={};["object","boolean","number","function","string","symbol"].forEach(function(e,t){Oi[e]=function(n){return typeof n===e||"a"+(t<1?"n ":" ")+e}});var Ou={};Oi.transitional=function(t,r,n){function a(i,o){return"[Axios v"+dR+"] Transitional option '"+i+"'"+o+(n?". "+n:"")}return function(i,o,s){if(t===!1)throw new Error(a(o," has been removed"+(r?" in "+r:"")));return r&&!Ou[o]&&(Ou[o]=!0,console.warn(a(o," has been deprecated since v"+r+" and will be removed in the near future"))),t?t(i,o,s):!0}};function hR(e,t,r){if(typeof e!="object")throw new TypeError("options must be an object");for(var n=Object.keys(e),a=n.length;a-- >0;){var i=n[a],o=t[i];if(o){var s=e[i],u=s===void 0||o(s,i,e);if(u!==!0)throw new TypeError("option "+i+" must be "+u);continue}if(r!==!0)throw Error("Unknown option "+i)}}var yR={assertOptions:hR,validators:Oi},mf=de,vR=df,wu=Uw,Ru=pR,zr=Af,If=yR,ht=If.validators;function Ut(e){this.defaults=e,this.interceptors={request:new wu,response:new wu}}Ut.prototype.request=function(t,r){typeof t=="string"?(r=r||{},r.url=t):r=t||{},r=zr(this.defaults,r),r.method?r.method=r.method.toLowerCase():this.defaults.method?r.method=this.defaults.method.toLowerCase():r.method="get";var n=r.transitional;n!==void 0&&If.assertOptions(n,{silentJSONParsing:ht.transitional(ht.boolean),forcedJSONParsing:ht.transitional(ht.boolean),clarifyTimeoutError:ht.transitional(ht.boolean)},!1);var a=[],i=!0;this.interceptors.request.forEach(function(h){typeof h.runWhen=="function"&&h.runWhen(r)===!1||(i=i&&h.synchronous,a.unshift(h.fulfilled,h.rejected))});var o=[];this.interceptors.response.forEach(function(h){o.push(h.fulfilled,h.rejected)});var s;if(!i){var u=[Ru,void 0];for(Array.prototype.unshift.apply(u,a),u=u.concat(o),s=Promise.resolve(r);u.length;)s=s.then(u.shift(),u.shift());return s}for(var f=r;a.length;){var g=a.shift(),c=a.shift();try{f=g(f)}catch(d){c(d);break}}try{s=Ru(f)}catch(d){return Promise.reject(d)}for(;o.length;)s=s.then(o.shift(),o.shift());return s};Ut.prototype.getUri=function(t){return t=zr(this.defaults,t),vR(t.url,t.params,t.paramsSerializer).replace(/^\?/,"")};mf.forEach(["delete","get","head","options"],function(t){Ut.prototype[t]=function(r,n){return this.request(zr(n||{},{method:t,url:r,data:(n||{}).data}))}});mf.forEach(["post","put","patch"],function(t){Ut.prototype[t]=function(r,n,a){return this.request(zr(a||{},{method:t,url:r,data:n}))}});var CR=Ut,Oa,Lu;function AR(){if(Lu)return Oa;Lu=1;var e=Hr();function t(r){if(typeof r!="function")throw new TypeError("executor must be a function.");var n;this.promise=new Promise(function(o){n=o});var a=this;this.promise.then(function(i){if(a._listeners){var o,s=a._listeners.length;for(o=0;o<s;o++)a._listeners[o](i);a._listeners=null}}),this.promise.then=function(i){var o,s=new Promise(function(u){a.subscribe(u),o=u}).then(i);return s.cancel=function(){a.unsubscribe(o)},s},r(function(o){a.reason||(a.reason=new e(o),n(a.reason))})}return t.prototype.throwIfRequested=function(){if(this.reason)throw this.reason},t.prototype.subscribe=function(n){if(this.reason){n(this.reason);return}this._listeners?this._listeners.push(n):this._listeners=[n]},t.prototype.unsubscribe=function(n){if(this._listeners){var a=this._listeners.indexOf(n);a!==-1&&this._listeners.splice(a,1)}},t.source=function(){var n,a=new t(function(o){n=o});return{token:a,cancel:n}},Oa=t,Oa}var wa,Tu;function bR(){return Tu||(Tu=1,wa=function(t){return function(n){return t.apply(null,n)}}),wa}var Ra,Eu;function mR(){if(Eu)return Ra;Eu=1;var e=de;return Ra=function(r){return e.isObject(r)&&r.isAxiosError===!0},Ra}var $u=de,IR=lf,fr=CR,SR=Af,_R=xi;function Sf(e){var t=new fr(e),r=IR(fr.prototype.request,t);return $u.extend(r,fr.prototype,t),$u.extend(r,t),r.create=function(a){return Sf(SR(e,a))},r}var Ne=Sf(_R);Ne.Axios=fr;Ne.Cancel=Hr();Ne.CancelToken=AR();Ne.isCancel=Cf();Ne.VERSION=bf().version;Ne.all=function(t){return Promise.all(t)};Ne.spread=bR();Ne.isAxiosError=mR();Lw.exports=Ne;Cr.default=Ne;(function(e){e.exports=Cr})(Rw);const za=_p(Xa),_f=({brandName:e,cdnURL:t})=>{const[r,n]=Q.useState();return Q.useEffect(()=>{(async()=>{try{const a=await za.get("/brand/iconIndex.json",{baseURL:t});n(a.data)}catch(a){st.logger.error({error:a},`Error loading icon index for brand ${e}`)}})()},[e,t]),async a=>{if(r){const i=(r[a.toLowerCase()]||[]).includes(e)?e:wr.BrandName.FALLBACK;return(await za.get(`/brand/${i}/icons/${a.toLowerCase()}.svg`,{baseURL:t,responseType:"text"})).data}}},xf=({cdnURL:e,brandName:t})=>{const[r,n]=Q.useState();return Q.useEffect(()=>{(async()=>{try{const a=await za.get(`/brand/${t}/theme.json`,{baseURL:e}),i=new wr.Theme(a.data);n(i)}catch(a){st.logger.error({error:a},`Error loading theme for brand ${t}`)}})()},[t,e]),r},wi=Q.createContext(void 0),xR=({baseURL:e="https://api.shipengine.com",brandName:t=wr.BrandName.FALLBACK,cdnURL:r="https://cdn.packlink.com",children:n,getToken:a,onError:i,scope:o="lmnt"})=>{const s=xf({brandName:t,cdnURL:r}),u=cf({cdnURL:r,scope:o,theme:s}),f=_f({brandName:t,cdnURL:r});return s?(i=i??ww,ve(wi.Provider,{value:{baseURL:e,brandName:t,cdnURL:r,getToken:a,onError:i,scope:o,theme:s},children:Qp(Pt.ThemeProvider,{theme:s,children:[ve(Pt.Global,{styles:[Ow(o),u]}),ve(xw,{resolveIcon:f,children:ve(st.ShipEngine,{baseURL:e,getToken:a,children:n})})]})})):null},Of=()=>{const e=Q.useContext(wi);if(!e)throw new Error("useAlchemy must be called from within the scope of <Alchemy />");return e};class wf extends Ta.Component{constructor(t){super(t),this.state={error:void 0}}componentDidCatch(t,r){t.stack=r.componentStack,this.props.onError(t),st.logger.error({error:t},t.message),this.setState({error:t})}render(){const{fallback:t,children:r}=this.props,{error:n}=this.state;return n?ve("div",{role:"alert",children:ve(t,{error:n})}):r}}function Ee(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Pu(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,Kc(n.key),n)}}function $e(e,t,r){return t&&Pu(e.prototype,t),r&&Pu(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function et(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Ua(e,t){return Ua=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,a){return n.__proto__=a,n},Ua(e,t)}function Ur(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Ua(e,t)}function Vt(e,t){if(t&&(Re(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return et(e)}function je(e){return je=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},je(e)}function OR(e){if(Array.isArray(e))return e}function wR(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Fu(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function RR(e,t){if(e){if(typeof e=="string")return Fu(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Fu(e,t)}}function LR(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
30
- In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function TR(e){return OR(e)||wR(e)||RR(e)||LR()}function Du(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function ku(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Du(Object(r),!0).forEach(function(n){te(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Du(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var ER={type:"logger",log:function(t){this.output("log",t)},warn:function(t){this.output("warn",t)},error:function(t){this.output("error",t)},output:function(t,r){console&&console[t]&&console[t].apply(console,r)}},$R=function(){function e(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};Ee(this,e),this.init(t,r)}return $e(e,[{key:"init",value:function(r){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.prefix=n.prefix||"i18next:",this.logger=r||ER,this.options=n,this.debug=n.debug}},{key:"setDebug",value:function(r){this.debug=r}},{key:"log",value:function(){for(var r=arguments.length,n=new Array(r),a=0;a<r;a++)n[a]=arguments[a];return this.forward(n,"log","",!0)}},{key:"warn",value:function(){for(var r=arguments.length,n=new Array(r),a=0;a<r;a++)n[a]=arguments[a];return this.forward(n,"warn","",!0)}},{key:"error",value:function(){for(var r=arguments.length,n=new Array(r),a=0;a<r;a++)n[a]=arguments[a];return this.forward(n,"error","")}},{key:"deprecate",value:function(){for(var r=arguments.length,n=new Array(r),a=0;a<r;a++)n[a]=arguments[a];return this.forward(n,"warn","WARNING DEPRECATED: ",!0)}},{key:"forward",value:function(r,n,a,i){return i&&!this.debug?null:(typeof r[0]=="string"&&(r[0]="".concat(a).concat(this.prefix," ").concat(r[0])),this.logger[n](r))}},{key:"create",value:function(r){return new e(this.logger,ku(ku({},{prefix:"".concat(this.prefix,":").concat(r,":")}),this.options))}},{key:"clone",value:function(r){return r=r||this.options,r.prefix=r.prefix||this.prefix,new e(this.logger,r)}}]),e}(),Be=new $R,tt=function(){function e(){Ee(this,e),this.observers={}}return $e(e,[{key:"on",value:function(r,n){var a=this;return r.split(" ").forEach(function(i){a.observers[i]=a.observers[i]||[],a.observers[i].push(n)}),this}},{key:"off",value:function(r,n){if(this.observers[r]){if(!n){delete this.observers[r];return}this.observers[r]=this.observers[r].filter(function(a){return a!==n})}}},{key:"emit",value:function(r){for(var n=arguments.length,a=new Array(n>1?n-1:0),i=1;i<n;i++)a[i-1]=arguments[i];if(this.observers[r]){var o=[].concat(this.observers[r]);o.forEach(function(u){u.apply(void 0,a)})}if(this.observers["*"]){var s=[].concat(this.observers["*"]);s.forEach(function(u){u.apply(u,[r].concat(a))})}}}]),e}();function Tt(){var e,t,r=new Promise(function(n,a){e=n,t=a});return r.resolve=e,r.reject=t,r}function Bu(e){return e==null?"":""+e}function PR(e,t,r){e.forEach(function(n){t[n]&&(r[n]=t[n])})}function Ri(e,t,r){function n(s){return s&&s.indexOf("###")>-1?s.replace(/###/g,"."):s}function a(){return!e||typeof e=="string"}for(var i=typeof t!="string"?[].concat(t):t.split(".");i.length>1;){if(a())return{};var o=n(i.shift());!e[o]&&r&&(e[o]=new r),Object.prototype.hasOwnProperty.call(e,o)?e=e[o]:e={}}return a()?{}:{obj:e,k:n(i.shift())}}function Wu(e,t,r){var n=Ri(e,t,Object),a=n.obj,i=n.k;a[i]=r}function FR(e,t,r,n){var a=Ri(e,t,Object),i=a.obj,o=a.k;i[o]=i[o]||[],n&&(i[o]=i[o].concat(r)),n||i[o].push(r)}function Ar(e,t){var r=Ri(e,t),n=r.obj,a=r.k;if(n)return n[a]}function ju(e,t,r){var n=Ar(e,r);return n!==void 0?n:Ar(t,r)}function Rf(e,t,r){for(var n in t)n!=="__proto__"&&n!=="constructor"&&(n in e?typeof e[n]=="string"||e[n]instanceof String||typeof t[n]=="string"||t[n]instanceof String?r&&(e[n]=t[n]):Rf(e[n],t[n],r):e[n]=t[n]);return e}function yt(e){return e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&")}var DR={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;","/":"&#x2F;"};function kR(e){return typeof e=="string"?e.replace(/[&<>"'\/]/g,function(t){return DR[t]}):e}var Vr=typeof window<"u"&&window.navigator&&typeof window.navigator.userAgentData>"u"&&window.navigator.userAgent&&window.navigator.userAgent.indexOf("MSIE")>-1,BR=[" ",",","?","!",";"];function WR(e,t,r){t=t||"",r=r||"";var n=BR.filter(function(s){return t.indexOf(s)<0&&r.indexOf(s)<0});if(n.length===0)return!0;var a=new RegExp("(".concat(n.map(function(s){return s==="?"?"\\?":s}).join("|"),")")),i=!a.test(e);if(!i){var o=e.indexOf(r);o>0&&!a.test(e.substring(0,o))&&(i=!0)}return i}function Nu(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function ar(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Nu(Object(r),!0).forEach(function(n){te(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Nu(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function jR(e){var t=NR();return function(){var n=je(e),a;if(t){var i=je(this).constructor;a=Reflect.construct(n,arguments,i)}else a=n.apply(this,arguments);return Vt(this,a)}}function NR(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Lf(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:".";if(e){if(e[t])return e[t];for(var n=t.split(r),a=e,i=0;i<n.length;++i){if(!a||typeof a[n[i]]=="string"&&i+1<n.length)return;if(a[n[i]]===void 0){for(var o=2,s=n.slice(i,i+o).join(r),u=a[s];u===void 0&&n.length>i+o;)o++,s=n.slice(i,i+o).join(r),u=a[s];if(u===void 0)return;if(u===null)return null;if(t.endsWith(s)){if(typeof u=="string")return u;if(s&&typeof u[s]=="string")return u[s]}var f=n.slice(i+o).join(r);return f?Lf(u,f,r):void 0}a=a[n[i]]}return a}}var GR=function(e){Ur(r,e);var t=jR(r);function r(n){var a,i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{ns:["translation"],defaultNS:"translation"};return Ee(this,r),a=t.call(this),Vr&&tt.call(et(a)),a.data=n||{},a.options=i,a.options.keySeparator===void 0&&(a.options.keySeparator="."),a.options.ignoreJSONStructure===void 0&&(a.options.ignoreJSONStructure=!0),a}return $e(r,[{key:"addNamespaces",value:function(a){this.options.ns.indexOf(a)<0&&this.options.ns.push(a)}},{key:"removeNamespaces",value:function(a){var i=this.options.ns.indexOf(a);i>-1&&this.options.ns.splice(i,1)}},{key:"getResource",value:function(a,i,o){var s=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},u=s.keySeparator!==void 0?s.keySeparator:this.options.keySeparator,f=s.ignoreJSONStructure!==void 0?s.ignoreJSONStructure:this.options.ignoreJSONStructure,g=[a,i];o&&typeof o!="string"&&(g=g.concat(o)),o&&typeof o=="string"&&(g=g.concat(u?o.split(u):o)),a.indexOf(".")>-1&&(g=a.split("."));var c=Ar(this.data,g);return c||!f||typeof o!="string"?c:Lf(this.data&&this.data[a]&&this.data[a][i],o,u)}},{key:"addResource",value:function(a,i,o,s){var u=arguments.length>4&&arguments[4]!==void 0?arguments[4]:{silent:!1},f=this.options.keySeparator;f===void 0&&(f=".");var g=[a,i];o&&(g=g.concat(f?o.split(f):o)),a.indexOf(".")>-1&&(g=a.split("."),s=i,i=g[1]),this.addNamespaces(i),Wu(this.data,g,s),u.silent||this.emit("added",a,i,o,s)}},{key:"addResources",value:function(a,i,o){var s=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{silent:!1};for(var u in o)(typeof o[u]=="string"||Object.prototype.toString.apply(o[u])==="[object Array]")&&this.addResource(a,i,u,o[u],{silent:!0});s.silent||this.emit("added",a,i,o)}},{key:"addResourceBundle",value:function(a,i,o,s,u){var f=arguments.length>5&&arguments[5]!==void 0?arguments[5]:{silent:!1},g=[a,i];a.indexOf(".")>-1&&(g=a.split("."),s=o,o=i,i=g[1]),this.addNamespaces(i);var c=Ar(this.data,g)||{};s?Rf(c,o,u):c=ar(ar({},c),o),Wu(this.data,g,c),f.silent||this.emit("added",a,i,o)}},{key:"removeResourceBundle",value:function(a,i){this.hasResourceBundle(a,i)&&delete this.data[a][i],this.removeNamespaces(i),this.emit("removed",a,i)}},{key:"hasResourceBundle",value:function(a,i){return this.getResource(a,i)!==void 0}},{key:"getResourceBundle",value:function(a,i){return i||(i=this.options.defaultNS),this.options.compatibilityAPI==="v1"?ar(ar({},{}),this.getResource(a,i)):this.getResource(a,i)}},{key:"getDataByLanguage",value:function(a){return this.data[a]}},{key:"hasLanguageSomeTranslations",value:function(a){var i=this.getDataByLanguage(a),o=i&&Object.keys(i)||[];return!!o.find(function(s){return i[s]&&Object.keys(i[s]).length>0})}},{key:"toJSON",value:function(){return this.data}}]),r}(tt),Tf={processors:{},addPostProcessor:function(t){this.processors[t.name]=t},handle:function(t,r,n,a,i){var o=this;return t.forEach(function(s){o.processors[s]&&(r=o.processors[s].process(r,n,a,i))}),r}};function Gu(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function le(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Gu(Object(r),!0).forEach(function(n){te(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Gu(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function XR(e){var t=HR();return function(){var n=je(e),a;if(t){var i=je(this).constructor;a=Reflect.construct(n,arguments,i)}else a=n.apply(this,arguments);return Vt(this,a)}}function HR(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}var Xu={},Hu=function(e){Ur(r,e);var t=XR(r);function r(n){var a,i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return Ee(this,r),a=t.call(this),Vr&&tt.call(et(a)),PR(["resourceStore","languageUtils","pluralResolver","interpolator","backendConnector","i18nFormat","utils"],n,et(a)),a.options=i,a.options.keySeparator===void 0&&(a.options.keySeparator="."),a.logger=Be.create("translator"),a}return $e(r,[{key:"changeLanguage",value:function(a){a&&(this.language=a)}},{key:"exists",value:function(a){var i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{interpolation:{}};if(a==null)return!1;var o=this.resolve(a,i);return o&&o.res!==void 0}},{key:"extractFromKey",value:function(a,i){var o=i.nsSeparator!==void 0?i.nsSeparator:this.options.nsSeparator;o===void 0&&(o=":");var s=i.keySeparator!==void 0?i.keySeparator:this.options.keySeparator,u=i.ns||this.options.defaultNS||[],f=o&&a.indexOf(o)>-1,g=!this.options.userDefinedKeySeparator&&!i.keySeparator&&!this.options.userDefinedNsSeparator&&!i.nsSeparator&&!WR(a,o,s);if(f&&!g){var c=a.match(this.interpolator.nestingRegexp);if(c&&c.length>0)return{key:a,namespaces:u};var d=a.split(o);(o!==s||o===s&&this.options.ns.indexOf(d[0])>-1)&&(u=d.shift()),a=d.join(s)}return typeof u=="string"&&(u=[u]),{key:a,namespaces:u}}},{key:"translate",value:function(a,i,o){var s=this;if(Re(i)!=="object"&&this.options.overloadTranslationOptionHandler&&(i=this.options.overloadTranslationOptionHandler(arguments)),i||(i={}),a==null)return"";Array.isArray(a)||(a=[String(a)]);var u=i.returnDetails!==void 0?i.returnDetails:this.options.returnDetails,f=i.keySeparator!==void 0?i.keySeparator:this.options.keySeparator,g=this.extractFromKey(a[a.length-1],i),c=g.key,d=g.namespaces,h=d[d.length-1],v=i.lng||this.language,m=i.appendNamespaceToCIMode||this.options.appendNamespaceToCIMode;if(v&&v.toLowerCase()==="cimode"){if(m){var b=i.nsSeparator||this.options.nsSeparator;return u?{res:"".concat(h).concat(b).concat(c),usedKey:c,exactUsedKey:c,usedLng:v,usedNS:h}:"".concat(h).concat(b).concat(c)}return u?{res:c,usedKey:c,exactUsedKey:c,usedLng:v,usedNS:h}:c}var y=this.resolve(a,i),A=y&&y.res,x=y&&y.usedKey||c,I=y&&y.exactUsedKey||c,S=Object.prototype.toString.apply(A),D=["[object Number]","[object Function]","[object RegExp]"],$=i.joinArrays!==void 0?i.joinArrays:this.options.joinArrays,N=!this.i18nFormat||this.i18nFormat.handleAsObject,ne=typeof A!="string"&&typeof A!="boolean"&&typeof A!="number";if(N&&A&&ne&&D.indexOf(S)<0&&!(typeof $=="string"&&S==="[object Array]")){if(!i.returnObjects&&!this.options.returnObjects){this.options.returnedObjectHandler||this.logger.warn("accessing an object - but returnObjects options is not enabled!");var W=this.options.returnedObjectHandler?this.options.returnedObjectHandler(x,A,le(le({},i),{},{ns:d})):"key '".concat(c," (").concat(this.language,")' returned an object instead of string.");return u?(y.res=W,y):W}if(f){var F=S==="[object Array]",q=F?[]:{},oe=F?I:x;for(var ee in A)if(Object.prototype.hasOwnProperty.call(A,ee)){var Ge="".concat(oe).concat(f).concat(ee);q[ee]=this.translate(Ge,le(le({},i),{joinArrays:!1,ns:d})),q[ee]===Ge&&(q[ee]=A[ee])}A=q}}else if(N&&typeof $=="string"&&S==="[object Array]")A=A.join($),A&&(A=this.extendTranslation(A,a,i,o));else{var Pe=!1,_e=!1,Fe=i.count!==void 0&&typeof i.count!="string",Xe=r.hasDefaultValue(i),Ye=Fe?this.pluralResolver.getSuffix(v,i.count,i):"",Ae=i["defaultValue".concat(Ye)]||i.defaultValue;!this.isValidLookup(A)&&Xe&&(Pe=!0,A=Ae),this.isValidLookup(A)||(_e=!0,A=c);var Je=i.missingKeyNoValueFallbackToKey||this.options.missingKeyNoValueFallbackToKey,k=Je&&_e?void 0:A,ue=Xe&&Ae!==A&&this.options.updateMissing;if(_e||Pe||ue){if(this.logger.log(ue?"updateKey":"missingKey",v,h,c,ue?Ae:A),f){var E=this.resolve(c,le(le({},i),{},{keySeparator:!1}));E&&E.res&&this.logger.warn("Seems the loaded translations were in flat JSON format instead of nested. Either set keySeparator: false on init or make sure your translations are published in nested format.")}var _=[],w=this.languageUtils.getFallbackCodes(this.options.fallbackLng,i.lng||this.language);if(this.options.saveMissingTo==="fallback"&&w&&w[0])for(var P=0;P<w.length;P++)_.push(w[P]);else this.options.saveMissingTo==="all"?_=this.languageUtils.toResolveHierarchy(i.lng||this.language):_.push(i.lng||this.language);var B=function(K,O,ae){var be=Xe&&ae!==A?ae:k;s.options.missingKeyHandler?s.options.missingKeyHandler(K,h,O,be,ue,i):s.backendConnector&&s.backendConnector.saveMissing&&s.backendConnector.saveMissing(K,h,O,be,ue,i),s.emit("missingKey",K,h,O,A)};this.options.saveMissing&&(this.options.saveMissingPlurals&&Fe?_.forEach(function(V){s.pluralResolver.getSuffixes(V,i).forEach(function(K){B([V],c+K,i["defaultValue".concat(K)]||Ae)})}):B(_,c,Ae))}A=this.extendTranslation(A,a,i,y,o),_e&&A===c&&this.options.appendNamespaceToMissingKey&&(A="".concat(h,":").concat(c)),(_e||Pe)&&this.options.parseMissingKeyHandler&&(this.options.compatibilityAPI!=="v1"?A=this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey?"".concat(h,":").concat(c):c,Pe?A:void 0):A=this.options.parseMissingKeyHandler(A))}return u?(y.res=A,y):A}},{key:"extendTranslation",value:function(a,i,o,s,u){var f=this;if(this.i18nFormat&&this.i18nFormat.parse)a=this.i18nFormat.parse(a,le(le({},this.options.interpolation.defaultVariables),o),s.usedLng,s.usedNS,s.usedKey,{resolved:s});else if(!o.skipInterpolation){o.interpolation&&this.interpolator.init(le(le({},o),{interpolation:le(le({},this.options.interpolation),o.interpolation)}));var g=typeof a=="string"&&(o&&o.interpolation&&o.interpolation.skipOnVariables!==void 0?o.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables),c;if(g){var d=a.match(this.interpolator.nestingRegexp);c=d&&d.length}var h=o.replace&&typeof o.replace!="string"?o.replace:o;if(this.options.interpolation.defaultVariables&&(h=le(le({},this.options.interpolation.defaultVariables),h)),a=this.interpolator.interpolate(a,h,o.lng||this.language,o),g){var v=a.match(this.interpolator.nestingRegexp),m=v&&v.length;c<m&&(o.nest=!1)}o.nest!==!1&&(a=this.interpolator.nest(a,function(){for(var A=arguments.length,x=new Array(A),I=0;I<A;I++)x[I]=arguments[I];return u&&u[0]===x[0]&&!o.context?(f.logger.warn("It seems you are nesting recursively key: ".concat(x[0]," in key: ").concat(i[0])),null):f.translate.apply(f,x.concat([i]))},o)),o.interpolation&&this.interpolator.reset()}var b=o.postProcess||this.options.postProcess,y=typeof b=="string"?[b]:b;return a!=null&&y&&y.length&&o.applyPostProcessor!==!1&&(a=Tf.handle(y,a,i,this.options&&this.options.postProcessPassResolved?le({i18nResolved:s},o):o,this)),a}},{key:"resolve",value:function(a){var i=this,o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},s,u,f,g,c;return typeof a=="string"&&(a=[a]),a.forEach(function(d){if(!i.isValidLookup(s)){var h=i.extractFromKey(d,o),v=h.key;u=v;var m=h.namespaces;i.options.fallbackNS&&(m=m.concat(i.options.fallbackNS));var b=o.count!==void 0&&typeof o.count!="string",y=b&&!o.ordinal&&o.count===0&&i.pluralResolver.shouldUseIntlApi(),A=o.context!==void 0&&(typeof o.context=="string"||typeof o.context=="number")&&o.context!=="",x=o.lngs?o.lngs:i.languageUtils.toResolveHierarchy(o.lng||i.language,o.fallbackLng);m.forEach(function(I){i.isValidLookup(s)||(c=I,!Xu["".concat(x[0],"-").concat(I)]&&i.utils&&i.utils.hasLoadedNamespace&&!i.utils.hasLoadedNamespace(c)&&(Xu["".concat(x[0],"-").concat(I)]=!0,i.logger.warn('key "'.concat(u,'" for languages "').concat(x.join(", "),`" won't get resolved as namespace "`).concat(c,'" was not yet loaded'),"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")),x.forEach(function(S){if(!i.isValidLookup(s)){g=S;var D=[v];if(i.i18nFormat&&i.i18nFormat.addLookupKeys)i.i18nFormat.addLookupKeys(D,v,S,I,o);else{var $;b&&($=i.pluralResolver.getSuffix(S,o.count,o));var N="".concat(i.options.pluralSeparator,"zero");if(b&&(D.push(v+$),y&&D.push(v+N)),A){var ne="".concat(v).concat(i.options.contextSeparator).concat(o.context);D.push(ne),b&&(D.push(ne+$),y&&D.push(ne+N))}}for(var W;W=D.pop();)i.isValidLookup(s)||(f=W,s=i.getResource(S,I,W,o))}}))})}}),{res:s,usedKey:u,exactUsedKey:f,usedLng:g,usedNS:c}}},{key:"isValidLookup",value:function(a){return a!==void 0&&!(!this.options.returnNull&&a===null)&&!(!this.options.returnEmptyString&&a==="")}},{key:"getResource",value:function(a,i,o){var s=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};return this.i18nFormat&&this.i18nFormat.getResource?this.i18nFormat.getResource(a,i,o,s):this.resourceStore.getResource(a,i,o,s)}}],[{key:"hasDefaultValue",value:function(a){var i="defaultValue";for(var o in a)if(Object.prototype.hasOwnProperty.call(a,o)&&i===o.substring(0,i.length)&&a[o]!==void 0)return!0;return!1}}]),r}(tt);function La(e){return e.charAt(0).toUpperCase()+e.slice(1)}var Mu=function(){function e(t){Ee(this,e),this.options=t,this.supportedLngs=this.options.supportedLngs||!1,this.logger=Be.create("languageUtils")}return $e(e,[{key:"getScriptPartFromCode",value:function(r){if(!r||r.indexOf("-")<0)return null;var n=r.split("-");return n.length===2||(n.pop(),n[n.length-1].toLowerCase()==="x")?null:this.formatLanguageCode(n.join("-"))}},{key:"getLanguagePartFromCode",value:function(r){if(!r||r.indexOf("-")<0)return r;var n=r.split("-");return this.formatLanguageCode(n[0])}},{key:"formatLanguageCode",value:function(r){if(typeof r=="string"&&r.indexOf("-")>-1){var n=["hans","hant","latn","cyrl","cans","mong","arab"],a=r.split("-");return this.options.lowerCaseLng?a=a.map(function(i){return i.toLowerCase()}):a.length===2?(a[0]=a[0].toLowerCase(),a[1]=a[1].toUpperCase(),n.indexOf(a[1].toLowerCase())>-1&&(a[1]=La(a[1].toLowerCase()))):a.length===3&&(a[0]=a[0].toLowerCase(),a[1].length===2&&(a[1]=a[1].toUpperCase()),a[0]!=="sgn"&&a[2].length===2&&(a[2]=a[2].toUpperCase()),n.indexOf(a[1].toLowerCase())>-1&&(a[1]=La(a[1].toLowerCase())),n.indexOf(a[2].toLowerCase())>-1&&(a[2]=La(a[2].toLowerCase()))),a.join("-")}return this.options.cleanCode||this.options.lowerCaseLng?r.toLowerCase():r}},{key:"isSupportedCode",value:function(r){return(this.options.load==="languageOnly"||this.options.nonExplicitSupportedLngs)&&(r=this.getLanguagePartFromCode(r)),!this.supportedLngs||!this.supportedLngs.length||this.supportedLngs.indexOf(r)>-1}},{key:"getBestMatchFromCodes",value:function(r){var n=this;if(!r)return null;var a;return r.forEach(function(i){if(!a){var o=n.formatLanguageCode(i);(!n.options.supportedLngs||n.isSupportedCode(o))&&(a=o)}}),!a&&this.options.supportedLngs&&r.forEach(function(i){if(!a){var o=n.getLanguagePartFromCode(i);if(n.isSupportedCode(o))return a=o;a=n.options.supportedLngs.find(function(s){if(s.indexOf(o)===0)return s})}}),a||(a=this.getFallbackCodes(this.options.fallbackLng)[0]),a}},{key:"getFallbackCodes",value:function(r,n){if(!r)return[];if(typeof r=="function"&&(r=r(n)),typeof r=="string"&&(r=[r]),Object.prototype.toString.apply(r)==="[object Array]")return r;if(!n)return r.default||[];var a=r[n];return a||(a=r[this.getScriptPartFromCode(n)]),a||(a=r[this.formatLanguageCode(n)]),a||(a=r[this.getLanguagePartFromCode(n)]),a||(a=r.default),a||[]}},{key:"toResolveHierarchy",value:function(r,n){var a=this,i=this.getFallbackCodes(n||this.options.fallbackLng||[],r),o=[],s=function(f){f&&(a.isSupportedCode(f)?o.push(f):a.logger.warn("rejecting language code not found in supportedLngs: ".concat(f)))};return typeof r=="string"&&r.indexOf("-")>-1?(this.options.load!=="languageOnly"&&s(this.formatLanguageCode(r)),this.options.load!=="languageOnly"&&this.options.load!=="currentOnly"&&s(this.getScriptPartFromCode(r)),this.options.load!=="currentOnly"&&s(this.getLanguagePartFromCode(r))):typeof r=="string"&&s(this.formatLanguageCode(r)),i.forEach(function(u){o.indexOf(u)<0&&s(a.formatLanguageCode(u))}),o}}]),e}(),MR=[{lngs:["ach","ak","am","arn","br","fil","gun","ln","mfe","mg","mi","oc","pt","pt-BR","tg","tl","ti","tr","uz","wa"],nr:[1,2],fc:1},{lngs:["af","an","ast","az","bg","bn","ca","da","de","dev","el","en","eo","es","et","eu","fi","fo","fur","fy","gl","gu","ha","hi","hu","hy","ia","it","kk","kn","ku","lb","mai","ml","mn","mr","nah","nap","nb","ne","nl","nn","no","nso","pa","pap","pms","ps","pt-PT","rm","sco","se","si","so","son","sq","sv","sw","ta","te","tk","ur","yo"],nr:[1,2],fc:2},{lngs:["ay","bo","cgg","fa","ht","id","ja","jbo","ka","km","ko","ky","lo","ms","sah","su","th","tt","ug","vi","wo","zh"],nr:[1],fc:3},{lngs:["be","bs","cnr","dz","hr","ru","sr","uk"],nr:[1,2,5],fc:4},{lngs:["ar"],nr:[0,1,2,3,11,100],fc:5},{lngs:["cs","sk"],nr:[1,2,5],fc:6},{lngs:["csb","pl"],nr:[1,2,5],fc:7},{lngs:["cy"],nr:[1,2,3,8],fc:8},{lngs:["fr"],nr:[1,2],fc:9},{lngs:["ga"],nr:[1,2,3,7,11],fc:10},{lngs:["gd"],nr:[1,2,3,20],fc:11},{lngs:["is"],nr:[1,2],fc:12},{lngs:["jv"],nr:[0,1],fc:13},{lngs:["kw"],nr:[1,2,3,4],fc:14},{lngs:["lt"],nr:[1,2,10],fc:15},{lngs:["lv"],nr:[1,2,0],fc:16},{lngs:["mk"],nr:[1,2],fc:17},{lngs:["mnk"],nr:[0,1,2],fc:18},{lngs:["mt"],nr:[1,2,11,20],fc:19},{lngs:["or"],nr:[2,1],fc:2},{lngs:["ro"],nr:[1,2,20],fc:20},{lngs:["sl"],nr:[5,1,2,3],fc:21},{lngs:["he","iw"],nr:[1,2,20,21],fc:22}],zR={1:function(t){return Number(t>1)},2:function(t){return Number(t!=1)},3:function(t){return 0},4:function(t){return Number(t%10==1&&t%100!=11?0:t%10>=2&&t%10<=4&&(t%100<10||t%100>=20)?1:2)},5:function(t){return Number(t==0?0:t==1?1:t==2?2:t%100>=3&&t%100<=10?3:t%100>=11?4:5)},6:function(t){return Number(t==1?0:t>=2&&t<=4?1:2)},7:function(t){return Number(t==1?0:t%10>=2&&t%10<=4&&(t%100<10||t%100>=20)?1:2)},8:function(t){return Number(t==1?0:t==2?1:t!=8&&t!=11?2:3)},9:function(t){return Number(t>=2)},10:function(t){return Number(t==1?0:t==2?1:t<7?2:t<11?3:4)},11:function(t){return Number(t==1||t==11?0:t==2||t==12?1:t>2&&t<20?2:3)},12:function(t){return Number(t%10!=1||t%100==11)},13:function(t){return Number(t!==0)},14:function(t){return Number(t==1?0:t==2?1:t==3?2:3)},15:function(t){return Number(t%10==1&&t%100!=11?0:t%10>=2&&(t%100<10||t%100>=20)?1:2)},16:function(t){return Number(t%10==1&&t%100!=11?0:t!==0?1:2)},17:function(t){return Number(t==1||t%10==1&&t%100!=11?0:1)},18:function(t){return Number(t==0?0:t==1?1:2)},19:function(t){return Number(t==1?0:t==0||t%100>1&&t%100<11?1:t%100>10&&t%100<20?2:3)},20:function(t){return Number(t==1?0:t==0||t%100>0&&t%100<20?1:2)},21:function(t){return Number(t%100==1?1:t%100==2?2:t%100==3||t%100==4?3:0)},22:function(t){return Number(t==1?0:t==2?1:(t<0||t>10)&&t%10==0?2:3)}},UR=["v1","v2","v3"],zu={zero:0,one:1,two:2,few:3,many:4,other:5};function VR(){var e={};return MR.forEach(function(t){t.lngs.forEach(function(r){e[r]={numbers:t.nr,plurals:zR[t.fc]}})}),e}var ZR=function(){function e(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};Ee(this,e),this.languageUtils=t,this.options=r,this.logger=Be.create("pluralResolver"),(!this.options.compatibilityJSON||this.options.compatibilityJSON==="v4")&&(typeof Intl>"u"||!Intl.PluralRules)&&(this.options.compatibilityJSON="v3",this.logger.error("Your environment seems not to be Intl API compatible, use an Intl.PluralRules polyfill. Will fallback to the compatibilityJSON v3 format handling.")),this.rules=VR()}return $e(e,[{key:"addRule",value:function(r,n){this.rules[r]=n}},{key:"getRule",value:function(r){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(this.shouldUseIntlApi())try{return new Intl.PluralRules(r,{type:n.ordinal?"ordinal":"cardinal"})}catch{return}return this.rules[r]||this.rules[this.languageUtils.getLanguagePartFromCode(r)]}},{key:"needsPlural",value:function(r){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},a=this.getRule(r,n);return this.shouldUseIntlApi()?a&&a.resolvedOptions().pluralCategories.length>1:a&&a.numbers.length>1}},{key:"getPluralFormsOfKey",value:function(r,n){var a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return this.getSuffixes(r,a).map(function(i){return"".concat(n).concat(i)})}},{key:"getSuffixes",value:function(r){var n=this,a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=this.getRule(r,a);return i?this.shouldUseIntlApi()?i.resolvedOptions().pluralCategories.sort(function(o,s){return zu[o]-zu[s]}).map(function(o){return"".concat(n.options.prepend).concat(o)}):i.numbers.map(function(o){return n.getSuffix(r,o,a)}):[]}},{key:"getSuffix",value:function(r,n){var a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},i=this.getRule(r,a);return i?this.shouldUseIntlApi()?"".concat(this.options.prepend).concat(i.select(n)):this.getSuffixRetroCompatible(i,n):(this.logger.warn("no plural rule found for: ".concat(r)),"")}},{key:"getSuffixRetroCompatible",value:function(r,n){var a=this,i=r.noAbs?r.plurals(n):r.plurals(Math.abs(n)),o=r.numbers[i];this.options.simplifyPluralSuffix&&r.numbers.length===2&&r.numbers[0]===1&&(o===2?o="plural":o===1&&(o=""));var s=function(){return a.options.prepend&&o.toString()?a.options.prepend+o.toString():o.toString()};return this.options.compatibilityJSON==="v1"?o===1?"":typeof o=="number"?"_plural_".concat(o.toString()):s():this.options.compatibilityJSON==="v2"||this.options.simplifyPluralSuffix&&r.numbers.length===2&&r.numbers[0]===1?s():this.options.prepend&&i.toString()?this.options.prepend+i.toString():i.toString()}},{key:"shouldUseIntlApi",value:function(){return!UR.includes(this.options.compatibilityJSON)}}]),e}();function Uu(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function xe(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Uu(Object(r),!0).forEach(function(n){te(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Uu(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var qR=function(){function e(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};Ee(this,e),this.logger=Be.create("interpolator"),this.options=t,this.format=t.interpolation&&t.interpolation.format||function(r){return r},this.init(t)}return $e(e,[{key:"init",value:function(){var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};r.interpolation||(r.interpolation={escapeValue:!0});var n=r.interpolation;this.escape=n.escape!==void 0?n.escape:kR,this.escapeValue=n.escapeValue!==void 0?n.escapeValue:!0,this.useRawValueToEscape=n.useRawValueToEscape!==void 0?n.useRawValueToEscape:!1,this.prefix=n.prefix?yt(n.prefix):n.prefixEscaped||"{{",this.suffix=n.suffix?yt(n.suffix):n.suffixEscaped||"}}",this.formatSeparator=n.formatSeparator?n.formatSeparator:n.formatSeparator||",",this.unescapePrefix=n.unescapeSuffix?"":n.unescapePrefix||"-",this.unescapeSuffix=this.unescapePrefix?"":n.unescapeSuffix||"",this.nestingPrefix=n.nestingPrefix?yt(n.nestingPrefix):n.nestingPrefixEscaped||yt("$t("),this.nestingSuffix=n.nestingSuffix?yt(n.nestingSuffix):n.nestingSuffixEscaped||yt(")"),this.nestingOptionsSeparator=n.nestingOptionsSeparator?n.nestingOptionsSeparator:n.nestingOptionsSeparator||",",this.maxReplaces=n.maxReplaces?n.maxReplaces:1e3,this.alwaysFormat=n.alwaysFormat!==void 0?n.alwaysFormat:!1,this.resetRegExp()}},{key:"reset",value:function(){this.options&&this.init(this.options)}},{key:"resetRegExp",value:function(){var r="".concat(this.prefix,"(.+?)").concat(this.suffix);this.regexp=new RegExp(r,"g");var n="".concat(this.prefix).concat(this.unescapePrefix,"(.+?)").concat(this.unescapeSuffix).concat(this.suffix);this.regexpUnescape=new RegExp(n,"g");var a="".concat(this.nestingPrefix,"(.+?)").concat(this.nestingSuffix);this.nestingRegexp=new RegExp(a,"g")}},{key:"interpolate",value:function(r,n,a,i){var o=this,s,u,f,g=this.options&&this.options.interpolation&&this.options.interpolation.defaultVariables||{};function c(b){return b.replace(/\$/g,"$$$$")}var d=function(y){if(y.indexOf(o.formatSeparator)<0){var A=ju(n,g,y);return o.alwaysFormat?o.format(A,void 0,a,xe(xe(xe({},i),n),{},{interpolationkey:y})):A}var x=y.split(o.formatSeparator),I=x.shift().trim(),S=x.join(o.formatSeparator).trim();return o.format(ju(n,g,I),S,a,xe(xe(xe({},i),n),{},{interpolationkey:I}))};this.resetRegExp();var h=i&&i.missingInterpolationHandler||this.options.missingInterpolationHandler,v=i&&i.interpolation&&i.interpolation.skipOnVariables!==void 0?i.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables,m=[{regex:this.regexpUnescape,safeValue:function(y){return c(y)}},{regex:this.regexp,safeValue:function(y){return o.escapeValue?c(o.escape(y)):c(y)}}];return m.forEach(function(b){for(f=0;s=b.regex.exec(r);){var y=s[1].trim();if(u=d(y),u===void 0)if(typeof h=="function"){var A=h(r,s,i);u=typeof A=="string"?A:""}else if(i&&Object.prototype.hasOwnProperty.call(i,y))u="";else if(v){u=s[0];continue}else o.logger.warn("missed to pass in variable ".concat(y," for interpolating ").concat(r)),u="";else typeof u!="string"&&!o.useRawValueToEscape&&(u=Bu(u));var x=b.safeValue(u);if(r=r.replace(s[0],x),v?(b.regex.lastIndex+=u.length,b.regex.lastIndex-=s[0].length):b.regex.lastIndex=0,f++,f>=o.maxReplaces)break}}),r}},{key:"nest",value:function(r,n){var a=this,i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},o,s,u;function f(h,v){var m=this.nestingOptionsSeparator;if(h.indexOf(m)<0)return h;var b=h.split(new RegExp("".concat(m,"[ ]*{"))),y="{".concat(b[1]);h=b[0],y=this.interpolate(y,u);var A=y.match(/'/g),x=y.match(/"/g);(A&&A.length%2===0&&!x||x.length%2!==0)&&(y=y.replace(/'/g,'"'));try{u=JSON.parse(y),v&&(u=xe(xe({},v),u))}catch(I){return this.logger.warn("failed parsing options string in nesting for key ".concat(h),I),"".concat(h).concat(m).concat(y)}return delete u.defaultValue,h}for(;o=this.nestingRegexp.exec(r);){var g=[];u=xe({},i),u=u.replace&&typeof u.replace!="string"?u.replace:u,u.applyPostProcessor=!1,delete u.defaultValue;var c=!1;if(o[0].indexOf(this.formatSeparator)!==-1&&!/{.*}/.test(o[1])){var d=o[1].split(this.formatSeparator).map(function(h){return h.trim()});o[1]=d.shift(),g=d,c=!0}if(s=n(f.call(this,o[1].trim(),u),u),s&&o[0]===r&&typeof s!="string")return s;typeof s!="string"&&(s=Bu(s)),s||(this.logger.warn("missed to resolve ".concat(o[1]," for nesting ").concat(r)),s=""),c&&(s=g.reduce(function(h,v){return a.format(h,v,i.lng,xe(xe({},i),{},{interpolationkey:o[1].trim()}))},s.trim())),r=r.replace(o[0],s),this.regexp.lastIndex=0}return r}}]),e}();function Vu(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function ze(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Vu(Object(r),!0).forEach(function(n){te(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Vu(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function YR(e){var t=e.toLowerCase().trim(),r={};if(e.indexOf("(")>-1){var n=e.split("(");t=n[0].toLowerCase().trim();var a=n[1].substring(0,n[1].length-1);if(t==="currency"&&a.indexOf(":")<0)r.currency||(r.currency=a.trim());else if(t==="relativetime"&&a.indexOf(":")<0)r.range||(r.range=a.trim());else{var i=a.split(";");i.forEach(function(o){if(o){var s=o.split(":"),u=TR(s),f=u[0],g=u.slice(1),c=g.join(":").trim().replace(/^'+|'+$/g,"");r[f.trim()]||(r[f.trim()]=c),c==="false"&&(r[f.trim()]=!1),c==="true"&&(r[f.trim()]=!0),isNaN(c)||(r[f.trim()]=parseInt(c,10))}})}}return{formatName:t,formatOptions:r}}function vt(e){var t={};return function(n,a,i){var o=a+JSON.stringify(i),s=t[o];return s||(s=e(a,i),t[o]=s),s(n)}}var JR=function(){function e(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};Ee(this,e),this.logger=Be.create("formatter"),this.options=t,this.formats={number:vt(function(r,n){var a=new Intl.NumberFormat(r,ze({},n));return function(i){return a.format(i)}}),currency:vt(function(r,n){var a=new Intl.NumberFormat(r,ze(ze({},n),{},{style:"currency"}));return function(i){return a.format(i)}}),datetime:vt(function(r,n){var a=new Intl.DateTimeFormat(r,ze({},n));return function(i){return a.format(i)}}),relativetime:vt(function(r,n){var a=new Intl.RelativeTimeFormat(r,ze({},n));return function(i){return a.format(i,n.range||"day")}}),list:vt(function(r,n){var a=new Intl.ListFormat(r,ze({},n));return function(i){return a.format(i)}})},this.init(t)}return $e(e,[{key:"init",value:function(r){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{interpolation:{}},a=n.interpolation;this.formatSeparator=a.formatSeparator?a.formatSeparator:a.formatSeparator||","}},{key:"add",value:function(r,n){this.formats[r.toLowerCase().trim()]=n}},{key:"addCached",value:function(r,n){this.formats[r.toLowerCase().trim()]=vt(n)}},{key:"format",value:function(r,n,a){var i=this,o=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},s=n.split(this.formatSeparator),u=s.reduce(function(f,g){var c=YR(g),d=c.formatName,h=c.formatOptions;if(i.formats[d]){var v=f;try{var m=o&&o.formatParams&&o.formatParams[o.interpolationkey]||{},b=m.locale||m.lng||o.locale||o.lng||a;v=i.formats[d](f,b,ze(ze(ze({},h),o),m))}catch(y){i.logger.warn(y)}return v}else i.logger.warn("there was no format function for ".concat(d));return f},r);return u}}]),e}();function Zu(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function qu(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Zu(Object(r),!0).forEach(function(n){te(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Zu(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function KR(e){var t=QR();return function(){var n=je(e),a;if(t){var i=je(this).constructor;a=Reflect.construct(n,arguments,i)}else a=n.apply(this,arguments);return Vt(this,a)}}function QR(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function eL(e,t){e.pending[t]!==void 0&&(delete e.pending[t],e.pendingCount--)}var tL=function(e){Ur(r,e);var t=KR(r);function r(n,a,i){var o,s=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};return Ee(this,r),o=t.call(this),Vr&&tt.call(et(o)),o.backend=n,o.store=a,o.services=i,o.languageUtils=i.languageUtils,o.options=s,o.logger=Be.create("backendConnector"),o.waitingReads=[],o.maxParallelReads=s.maxParallelReads||10,o.readingCalls=0,o.maxRetries=s.maxRetries>=0?s.maxRetries:5,o.retryTimeout=s.retryTimeout>=1?s.retryTimeout:350,o.state={},o.queue=[],o.backend&&o.backend.init&&o.backend.init(i,s.backend,s),o}return $e(r,[{key:"queueLoad",value:function(a,i,o,s){var u=this,f={},g={},c={},d={};return a.forEach(function(h){var v=!0;i.forEach(function(m){var b="".concat(h,"|").concat(m);!o.reload&&u.store.hasResourceBundle(h,m)?u.state[b]=2:u.state[b]<0||(u.state[b]===1?g[b]===void 0&&(g[b]=!0):(u.state[b]=1,v=!1,g[b]===void 0&&(g[b]=!0),f[b]===void 0&&(f[b]=!0),d[m]===void 0&&(d[m]=!0)))}),v||(c[h]=!0)}),(Object.keys(f).length||Object.keys(g).length)&&this.queue.push({pending:g,pendingCount:Object.keys(g).length,loaded:{},errors:[],callback:s}),{toLoad:Object.keys(f),pending:Object.keys(g),toLoadLanguages:Object.keys(c),toLoadNamespaces:Object.keys(d)}}},{key:"loaded",value:function(a,i,o){var s=a.split("|"),u=s[0],f=s[1];i&&this.emit("failedLoading",u,f,i),o&&this.store.addResourceBundle(u,f,o),this.state[a]=i?-1:2;var g={};this.queue.forEach(function(c){FR(c.loaded,[u],f),eL(c,a),i&&c.errors.push(i),c.pendingCount===0&&!c.done&&(Object.keys(c.loaded).forEach(function(d){g[d]||(g[d]={});var h=c.loaded[d];h.length&&h.forEach(function(v){g[d][v]===void 0&&(g[d][v]=!0)})}),c.done=!0,c.errors.length?c.callback(c.errors):c.callback())}),this.emit("loaded",g),this.queue=this.queue.filter(function(c){return!c.done})}},{key:"read",value:function(a,i,o){var s=this,u=arguments.length>3&&arguments[3]!==void 0?arguments[3]:0,f=arguments.length>4&&arguments[4]!==void 0?arguments[4]:this.retryTimeout,g=arguments.length>5?arguments[5]:void 0;if(!a.length)return g(null,{});if(this.readingCalls>=this.maxParallelReads){this.waitingReads.push({lng:a,ns:i,fcName:o,tried:u,wait:f,callback:g});return}this.readingCalls++;var c=function(m,b){if(s.readingCalls--,s.waitingReads.length>0){var y=s.waitingReads.shift();s.read(y.lng,y.ns,y.fcName,y.tried,y.wait,y.callback)}if(m&&b&&u<s.maxRetries){setTimeout(function(){s.read.call(s,a,i,o,u+1,f*2,g)},f);return}g(m,b)},d=this.backend[o].bind(this.backend);if(d.length===2){try{var h=d(a,i);h&&typeof h.then=="function"?h.then(function(v){return c(null,v)}).catch(c):c(null,h)}catch(v){c(v)}return}return d(a,i,c)}},{key:"prepareLoading",value:function(a,i){var o=this,s=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},u=arguments.length>3?arguments[3]:void 0;if(!this.backend)return this.logger.warn("No backend was added via i18next.use. Will not load resources."),u&&u();typeof a=="string"&&(a=this.languageUtils.toResolveHierarchy(a)),typeof i=="string"&&(i=[i]);var f=this.queueLoad(a,i,s,u);if(!f.toLoad.length)return f.pending.length||u(),null;f.toLoad.forEach(function(g){o.loadOne(g)})}},{key:"load",value:function(a,i,o){this.prepareLoading(a,i,{},o)}},{key:"reload",value:function(a,i,o){this.prepareLoading(a,i,{reload:!0},o)}},{key:"loadOne",value:function(a){var i=this,o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",s=a.split("|"),u=s[0],f=s[1];this.read(u,f,"read",void 0,void 0,function(g,c){g&&i.logger.warn("".concat(o,"loading namespace ").concat(f," for language ").concat(u," failed"),g),!g&&c&&i.logger.log("".concat(o,"loaded namespace ").concat(f," for language ").concat(u),c),i.loaded(a,g,c)})}},{key:"saveMissing",value:function(a,i,o,s,u){var f=arguments.length>5&&arguments[5]!==void 0?arguments[5]:{},g=arguments.length>6&&arguments[6]!==void 0?arguments[6]:function(){};if(this.services.utils&&this.services.utils.hasLoadedNamespace&&!this.services.utils.hasLoadedNamespace(i)){this.logger.warn('did not save key "'.concat(o,'" as the namespace "').concat(i,'" was not yet loaded'),"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!");return}if(!(o==null||o==="")){if(this.backend&&this.backend.create){var c=qu(qu({},f),{},{isUpdate:u}),d=this.backend.create.bind(this.backend);if(d.length<6)try{var h;d.length===5?h=d(a,i,o,s,c):h=d(a,i,o,s),h&&typeof h.then=="function"?h.then(function(v){return g(null,v)}).catch(g):g(null,h)}catch(v){g(v)}else d(a,i,o,s,g,c)}!a||!a[0]||this.store.addResource(a[0],i,o,s)}}}]),r}(tt);function Yu(){return{debug:!1,initImmediate:!0,ns:["translation"],defaultNS:["translation"],fallbackLng:["dev"],fallbackNS:!1,supportedLngs:!1,nonExplicitSupportedLngs:!1,load:"all",preload:!1,simplifyPluralSuffix:!0,keySeparator:".",nsSeparator:":",pluralSeparator:"_",contextSeparator:"_",partialBundledLanguages:!1,saveMissing:!1,updateMissing:!1,saveMissingTo:"fallback",saveMissingPlurals:!0,missingKeyHandler:!1,missingInterpolationHandler:!1,postProcess:!1,postProcessPassResolved:!1,returnNull:!0,returnEmptyString:!0,returnObjects:!1,joinArrays:!1,returnedObjectHandler:!1,parseMissingKeyHandler:!1,appendNamespaceToMissingKey:!1,appendNamespaceToCIMode:!1,overloadTranslationOptionHandler:function(t){var r={};if(Re(t[1])==="object"&&(r=t[1]),typeof t[1]=="string"&&(r.defaultValue=t[1]),typeof t[2]=="string"&&(r.tDescription=t[2]),Re(t[2])==="object"||Re(t[3])==="object"){var n=t[3]||t[2];Object.keys(n).forEach(function(a){r[a]=n[a]})}return r},interpolation:{escapeValue:!0,format:function(t,r,n,a){return t},prefix:"{{",suffix:"}}",formatSeparator:",",unescapePrefix:"-",nestingPrefix:"$t(",nestingSuffix:")",nestingOptionsSeparator:",",maxReplaces:1e3,skipOnVariables:!0}}}function Ju(e){return typeof e.ns=="string"&&(e.ns=[e.ns]),typeof e.fallbackLng=="string"&&(e.fallbackLng=[e.fallbackLng]),typeof e.fallbackNS=="string"&&(e.fallbackNS=[e.fallbackNS]),e.supportedLngs&&e.supportedLngs.indexOf("cimode")<0&&(e.supportedLngs=e.supportedLngs.concat(["cimode"])),e}function Ku(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function De(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Ku(Object(r),!0).forEach(function(n){te(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Ku(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function rL(e){var t=nL();return function(){var n=je(e),a;if(t){var i=je(this).constructor;a=Reflect.construct(n,arguments,i)}else a=n.apply(this,arguments);return Vt(this,a)}}function nL(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function ir(){}function aL(e){var t=Object.getOwnPropertyNames(Object.getPrototypeOf(e));t.forEach(function(r){typeof e[r]=="function"&&(e[r]=e[r].bind(e))})}var br=function(e){Ur(r,e);var t=rL(r);function r(){var n,a=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},i=arguments.length>1?arguments[1]:void 0;if(Ee(this,r),n=t.call(this),Vr&&tt.call(et(n)),n.options=Ju(a),n.services={},n.logger=Be,n.modules={external:[]},aL(et(n)),i&&!n.isInitialized&&!a.isClone){if(!n.options.initImmediate)return n.init(a,i),Vt(n,et(n));setTimeout(function(){n.init(a,i)},0)}return n}return $e(r,[{key:"init",value:function(){var a=this,i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},o=arguments.length>1?arguments[1]:void 0;typeof i=="function"&&(o=i,i={}),!i.defaultNS&&i.defaultNS!==!1&&i.ns&&(typeof i.ns=="string"?i.defaultNS=i.ns:i.ns.indexOf("translation")<0&&(i.defaultNS=i.ns[0]));var s=Yu();this.options=De(De(De({},s),this.options),Ju(i)),this.options.compatibilityAPI!=="v1"&&(this.options.interpolation=De(De({},s.interpolation),this.options.interpolation)),i.keySeparator!==void 0&&(this.options.userDefinedKeySeparator=i.keySeparator),i.nsSeparator!==void 0&&(this.options.userDefinedNsSeparator=i.nsSeparator);function u(y){return y?typeof y=="function"?new y:y:null}if(!this.options.isClone){this.modules.logger?Be.init(u(this.modules.logger),this.options):Be.init(null,this.options);var f;this.modules.formatter?f=this.modules.formatter:typeof Intl<"u"&&(f=JR);var g=new Mu(this.options);this.store=new GR(this.options.resources,this.options);var c=this.services;c.logger=Be,c.resourceStore=this.store,c.languageUtils=g,c.pluralResolver=new ZR(g,{prepend:this.options.pluralSeparator,compatibilityJSON:this.options.compatibilityJSON,simplifyPluralSuffix:this.options.simplifyPluralSuffix}),f&&(!this.options.interpolation.format||this.options.interpolation.format===s.interpolation.format)&&(c.formatter=u(f),c.formatter.init(c,this.options),this.options.interpolation.format=c.formatter.format.bind(c.formatter)),c.interpolator=new qR(this.options),c.utils={hasLoadedNamespace:this.hasLoadedNamespace.bind(this)},c.backendConnector=new tL(u(this.modules.backend),c.resourceStore,c,this.options),c.backendConnector.on("*",function(y){for(var A=arguments.length,x=new Array(A>1?A-1:0),I=1;I<A;I++)x[I-1]=arguments[I];a.emit.apply(a,[y].concat(x))}),this.modules.languageDetector&&(c.languageDetector=u(this.modules.languageDetector),c.languageDetector.init&&c.languageDetector.init(c,this.options.detection,this.options)),this.modules.i18nFormat&&(c.i18nFormat=u(this.modules.i18nFormat),c.i18nFormat.init&&c.i18nFormat.init(this)),this.translator=new Hu(this.services,this.options),this.translator.on("*",function(y){for(var A=arguments.length,x=new Array(A>1?A-1:0),I=1;I<A;I++)x[I-1]=arguments[I];a.emit.apply(a,[y].concat(x))}),this.modules.external.forEach(function(y){y.init&&y.init(a)})}if(this.format=this.options.interpolation.format,o||(o=ir),this.options.fallbackLng&&!this.services.languageDetector&&!this.options.lng){var d=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);d.length>0&&d[0]!=="dev"&&(this.options.lng=d[0])}!this.services.languageDetector&&!this.options.lng&&this.logger.warn("init: no languageDetector is used and no lng is defined");var h=["getResource","hasResourceBundle","getResourceBundle","getDataByLanguage"];h.forEach(function(y){a[y]=function(){var A;return(A=a.store)[y].apply(A,arguments)}});var v=["addResource","addResources","addResourceBundle","removeResourceBundle"];v.forEach(function(y){a[y]=function(){var A;return(A=a.store)[y].apply(A,arguments),a}});var m=Tt(),b=function(){var A=function(I,S){a.isInitialized&&!a.initializedStoreOnce&&a.logger.warn("init: i18next is already initialized. You should call init just once!"),a.isInitialized=!0,a.options.isClone||a.logger.log("initialized",a.options),a.emit("initialized",a.options),m.resolve(S),o(I,S)};if(a.languages&&a.options.compatibilityAPI!=="v1"&&!a.isInitialized)return A(null,a.t.bind(a));a.changeLanguage(a.options.lng,A)};return this.options.resources||!this.options.initImmediate?b():setTimeout(b,0),m}},{key:"loadResources",value:function(a){var i=this,o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:ir,s=o,u=typeof a=="string"?a:this.language;if(typeof a=="function"&&(s=a),!this.options.resources||this.options.partialBundledLanguages){if(u&&u.toLowerCase()==="cimode")return s();var f=[],g=function(h){if(h){var v=i.services.languageUtils.toResolveHierarchy(h);v.forEach(function(m){f.indexOf(m)<0&&f.push(m)})}};if(u)g(u);else{var c=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);c.forEach(function(d){return g(d)})}this.options.preload&&this.options.preload.forEach(function(d){return g(d)}),this.services.backendConnector.load(f,this.options.ns,function(d){!d&&!i.resolvedLanguage&&i.language&&i.setResolvedLanguage(i.language),s(d)})}else s(null)}},{key:"reloadResources",value:function(a,i,o){var s=Tt();return a||(a=this.languages),i||(i=this.options.ns),o||(o=ir),this.services.backendConnector.reload(a,i,function(u){s.resolve(),o(u)}),s}},{key:"use",value:function(a){if(!a)throw new Error("You are passing an undefined module! Please check the object you are passing to i18next.use()");if(!a.type)throw new Error("You are passing a wrong module! Please check the object you are passing to i18next.use()");return a.type==="backend"&&(this.modules.backend=a),(a.type==="logger"||a.log&&a.warn&&a.error)&&(this.modules.logger=a),a.type==="languageDetector"&&(this.modules.languageDetector=a),a.type==="i18nFormat"&&(this.modules.i18nFormat=a),a.type==="postProcessor"&&Tf.addPostProcessor(a),a.type==="formatter"&&(this.modules.formatter=a),a.type==="3rdParty"&&this.modules.external.push(a),this}},{key:"setResolvedLanguage",value:function(a){if(!(!a||!this.languages)&&!(["cimode","dev"].indexOf(a)>-1))for(var i=0;i<this.languages.length;i++){var o=this.languages[i];if(!(["cimode","dev"].indexOf(o)>-1)&&this.store.hasLanguageSomeTranslations(o)){this.resolvedLanguage=o;break}}}},{key:"changeLanguage",value:function(a,i){var o=this;this.isLanguageChangingTo=a;var s=Tt();this.emit("languageChanging",a);var u=function(d){o.language=d,o.languages=o.services.languageUtils.toResolveHierarchy(d),o.resolvedLanguage=void 0,o.setResolvedLanguage(d)},f=function(d,h){h?(u(h),o.translator.changeLanguage(h),o.isLanguageChangingTo=void 0,o.emit("languageChanged",h),o.logger.log("languageChanged",h)):o.isLanguageChangingTo=void 0,s.resolve(function(){return o.t.apply(o,arguments)}),i&&i(d,function(){return o.t.apply(o,arguments)})},g=function(d){!a&&!d&&o.services.languageDetector&&(d=[]);var h=typeof d=="string"?d:o.services.languageUtils.getBestMatchFromCodes(d);h&&(o.language||u(h),o.translator.language||o.translator.changeLanguage(h),o.services.languageDetector&&o.services.languageDetector.cacheUserLanguage&&o.services.languageDetector.cacheUserLanguage(h)),o.loadResources(h,function(v){f(v,h)})};return!a&&this.services.languageDetector&&!this.services.languageDetector.async?g(this.services.languageDetector.detect()):!a&&this.services.languageDetector&&this.services.languageDetector.async?this.services.languageDetector.detect.length===0?this.services.languageDetector.detect().then(g):this.services.languageDetector.detect(g):g(a),s}},{key:"getFixedT",value:function(a,i,o){var s=this,u=function f(g,c){var d;if(Re(c)!=="object"){for(var h=arguments.length,v=new Array(h>2?h-2:0),m=2;m<h;m++)v[m-2]=arguments[m];d=s.options.overloadTranslationOptionHandler([g,c].concat(v))}else d=De({},c);d.lng=d.lng||f.lng,d.lngs=d.lngs||f.lngs,d.ns=d.ns||f.ns,d.keyPrefix=d.keyPrefix||o||f.keyPrefix;var b=s.options.keySeparator||".",y;return d.keyPrefix&&Array.isArray(g)?y=g.map(function(A){return"".concat(d.keyPrefix).concat(b).concat(A)}):y=d.keyPrefix?"".concat(d.keyPrefix).concat(b).concat(g):g,s.t(y,d)};return typeof a=="string"?u.lng=a:u.lngs=a,u.ns=i,u.keyPrefix=o,u}},{key:"t",value:function(){var a;return this.translator&&(a=this.translator).translate.apply(a,arguments)}},{key:"exists",value:function(){var a;return this.translator&&(a=this.translator).exists.apply(a,arguments)}},{key:"setDefaultNamespace",value:function(a){this.options.defaultNS=a}},{key:"hasLoadedNamespace",value:function(a){var i=this,o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(!this.isInitialized)return this.logger.warn("hasLoadedNamespace: i18next was not initialized",this.languages),!1;if(!this.languages||!this.languages.length)return this.logger.warn("hasLoadedNamespace: i18n.languages were undefined or empty",this.languages),!1;var s=this.resolvedLanguage||this.languages[0],u=this.options?this.options.fallbackLng:!1,f=this.languages[this.languages.length-1];if(s.toLowerCase()==="cimode")return!0;var g=function(h,v){var m=i.services.backendConnector.state["".concat(h,"|").concat(v)];return m===-1||m===2};if(o.precheck){var c=o.precheck(this,g);if(c!==void 0)return c}return!!(this.hasResourceBundle(s,a)||!this.services.backendConnector.backend||this.options.resources&&!this.options.partialBundledLanguages||g(s,a)&&(!u||g(f,a)))}},{key:"loadNamespaces",value:function(a,i){var o=this,s=Tt();return this.options.ns?(typeof a=="string"&&(a=[a]),a.forEach(function(u){o.options.ns.indexOf(u)<0&&o.options.ns.push(u)}),this.loadResources(function(u){s.resolve(),i&&i(u)}),s):(i&&i(),Promise.resolve())}},{key:"loadLanguages",value:function(a,i){var o=Tt();typeof a=="string"&&(a=[a]);var s=this.options.preload||[],u=a.filter(function(f){return s.indexOf(f)<0});return u.length?(this.options.preload=s.concat(u),this.loadResources(function(f){o.resolve(),i&&i(f)}),o):(i&&i(),Promise.resolve())}},{key:"dir",value:function(a){if(a||(a=this.resolvedLanguage||(this.languages&&this.languages.length>0?this.languages[0]:this.language)),!a)return"rtl";var i=["ar","shu","sqr","ssh","xaa","yhd","yud","aao","abh","abv","acm","acq","acw","acx","acy","adf","ads","aeb","aec","afb","ajp","apc","apd","arb","arq","ars","ary","arz","auz","avl","ayh","ayl","ayn","ayp","bbz","pga","he","iw","ps","pbt","pbu","pst","prp","prd","ug","ur","ydd","yds","yih","ji","yi","hbo","men","xmn","fa","jpr","peo","pes","prs","dv","sam","ckb"],o=this.services&&this.services.languageUtils||new Mu(Yu());return i.indexOf(o.getLanguagePartFromCode(a))>-1||a.toLowerCase().indexOf("-arab")>1?"rtl":"ltr"}},{key:"cloneInstance",value:function(){var a=this,i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:ir,s=De(De(De({},this.options),i),{isClone:!0}),u=new r(s);(i.debug!==void 0||i.prefix!==void 0)&&(u.logger=u.logger.clone(i));var f=["store","services","language"];return f.forEach(function(g){u[g]=a[g]}),u.services=De({},this.services),u.services.utils={hasLoadedNamespace:u.hasLoadedNamespace.bind(u)},u.translator=new Hu(u.services,u.options),u.translator.on("*",function(g){for(var c=arguments.length,d=new Array(c>1?c-1:0),h=1;h<c;h++)d[h-1]=arguments[h];u.emit.apply(u,[g].concat(d))}),u.init(s,o),u.translator.options=u.options,u.translator.backendConnector.services.utils={hasLoadedNamespace:u.hasLoadedNamespace.bind(u)},u}},{key:"toJSON",value:function(){return{options:this.options,store:this.store,language:this.language,languages:this.languages,resolvedLanguage:this.resolvedLanguage}}}]),r}(tt);te(br,"createInstance",function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;return new br(e,t)});var ce=br.createInstance();ce.createInstance=br.createInstance;ce.createInstance;ce.dir;ce.init;ce.loadResources;ce.reloadResources;ce.use;ce.changeLanguage;ce.getFixedT;ce.t;ce.exists;ce.setDefaultNamespace;ce.hasLoadedNamespace;ce.loadNamespaces;ce.loadLanguages;var Ef=[],iL=Ef.forEach,oL=Ef.slice;function sL(e){return iL.call(oL.call(arguments,1),function(t){if(t)for(var r in t)e[r]===void 0&&(e[r]=t[r])}),e}var Qu=/^[\u0009\u0020-\u007e\u0080-\u00ff]+$/,uL=function(t,r,n){var a=n||{};a.path=a.path||"/";var i=encodeURIComponent(r),o="".concat(t,"=").concat(i);if(a.maxAge>0){var s=a.maxAge-0;if(Number.isNaN(s))throw new Error("maxAge should be a Number");o+="; Max-Age=".concat(Math.floor(s))}if(a.domain){if(!Qu.test(a.domain))throw new TypeError("option domain is invalid");o+="; Domain=".concat(a.domain)}if(a.path){if(!Qu.test(a.path))throw new TypeError("option path is invalid");o+="; Path=".concat(a.path)}if(a.expires){if(typeof a.expires.toUTCString!="function")throw new TypeError("option expires is invalid");o+="; Expires=".concat(a.expires.toUTCString())}if(a.httpOnly&&(o+="; HttpOnly"),a.secure&&(o+="; Secure"),a.sameSite){var u=typeof a.sameSite=="string"?a.sameSite.toLowerCase():a.sameSite;switch(u){case!0:o+="; SameSite=Strict";break;case"lax":o+="; SameSite=Lax";break;case"strict":o+="; SameSite=Strict";break;case"none":o+="; SameSite=None";break;default:throw new TypeError("option sameSite is invalid")}}return o},ec={create:function(t,r,n,a){var i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:{path:"/",sameSite:"strict"};n&&(i.expires=new Date,i.expires.setTime(i.expires.getTime()+n*60*1e3)),a&&(i.domain=a),document.cookie=uL(t,encodeURIComponent(r),i)},read:function(t){for(var r="".concat(t,"="),n=document.cookie.split(";"),a=0;a<n.length;a++){for(var i=n[a];i.charAt(0)===" ";)i=i.substring(1,i.length);if(i.indexOf(r)===0)return i.substring(r.length,i.length)}return null},remove:function(t){this.create(t,"",-1)}},cL={name:"cookie",lookup:function(t){var r;if(t.lookupCookie&&typeof document<"u"){var n=ec.read(t.lookupCookie);n&&(r=n)}return r},cacheUserLanguage:function(t,r){r.lookupCookie&&typeof document<"u"&&ec.create(r.lookupCookie,t,r.cookieMinutes,r.cookieDomain,r.cookieOptions)}},lL={name:"querystring",lookup:function(t){var r;if(typeof window<"u"){var n=window.location.search;!window.location.search&&window.location.hash&&window.location.hash.indexOf("?")>-1&&(n=window.location.hash.substring(window.location.hash.indexOf("?")));for(var a=n.substring(1),i=a.split("&"),o=0;o<i.length;o++){var s=i[o].indexOf("=");if(s>0){var u=i[o].substring(0,s);u===t.lookupQuerystring&&(r=i[o].substring(s+1))}}}return r}},Et=null,tc=function(){if(Et!==null)return Et;try{Et=window!=="undefined"&&window.localStorage!==null;var t="i18next.translate.boo";window.localStorage.setItem(t,"foo"),window.localStorage.removeItem(t)}catch{Et=!1}return Et},fL={name:"localStorage",lookup:function(t){var r;if(t.lookupLocalStorage&&tc()){var n=window.localStorage.getItem(t.lookupLocalStorage);n&&(r=n)}return r},cacheUserLanguage:function(t,r){r.lookupLocalStorage&&tc()&&window.localStorage.setItem(r.lookupLocalStorage,t)}},$t=null,rc=function(){if($t!==null)return $t;try{$t=window!=="undefined"&&window.sessionStorage!==null;var t="i18next.translate.boo";window.sessionStorage.setItem(t,"foo"),window.sessionStorage.removeItem(t)}catch{$t=!1}return $t},gL={name:"sessionStorage",lookup:function(t){var r;if(t.lookupSessionStorage&&rc()){var n=window.sessionStorage.getItem(t.lookupSessionStorage);n&&(r=n)}return r},cacheUserLanguage:function(t,r){r.lookupSessionStorage&&rc()&&window.sessionStorage.setItem(r.lookupSessionStorage,t)}},pL={name:"navigator",lookup:function(t){var r=[];if(typeof navigator<"u"){if(navigator.languages)for(var n=0;n<navigator.languages.length;n++)r.push(navigator.languages[n]);navigator.userLanguage&&r.push(navigator.userLanguage),navigator.language&&r.push(navigator.language)}return r.length>0?r:void 0}},dL={name:"htmlTag",lookup:function(t){var r,n=t.htmlTag||(typeof document<"u"?document.documentElement:null);return n&&typeof n.getAttribute=="function"&&(r=n.getAttribute("lang")),r}},hL={name:"path",lookup:function(t){var r;if(typeof window<"u"){var n=window.location.pathname.match(/\/([a-zA-Z-]*)/g);if(n instanceof Array)if(typeof t.lookupFromPathIndex=="number"){if(typeof n[t.lookupFromPathIndex]!="string")return;r=n[t.lookupFromPathIndex].replace("/","")}else r=n[0].replace("/","")}return r}},yL={name:"subdomain",lookup:function(t){var r=typeof t.lookupFromSubdomainIndex=="number"?t.lookupFromSubdomainIndex+1:1,n=typeof window<"u"&&window.location&&window.location.hostname&&window.location.hostname.match(/^(\w{2,5})\.(([a-z0-9-]{1,63}\.[a-z]{2,6})|localhost)/i);if(n)return n[r]}};function vL(){return{order:["querystring","cookie","localStorage","sessionStorage","navigator","htmlTag"],lookupQuerystring:"lng",lookupCookie:"i18next",lookupLocalStorage:"i18nextLng",lookupSessionStorage:"i18nextLng",caches:["localStorage"],excludeCacheFor:["cimode"]}}var $f=function(){function e(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};Ee(this,e),this.type="languageDetector",this.detectors={},this.init(t,r)}return $e(e,[{key:"init",value:function(r){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};this.services=r,this.options=sL(n,this.options||{},vL()),this.options.lookupFromUrlIndex&&(this.options.lookupFromPathIndex=this.options.lookupFromUrlIndex),this.i18nOptions=a,this.addDetector(cL),this.addDetector(lL),this.addDetector(fL),this.addDetector(gL),this.addDetector(pL),this.addDetector(dL),this.addDetector(hL),this.addDetector(yL)}},{key:"addDetector",value:function(r){this.detectors[r.name]=r}},{key:"detect",value:function(r){var n=this;r||(r=this.options.order);var a=[];return r.forEach(function(i){if(n.detectors[i]){var o=n.detectors[i].lookup(n.options);o&&typeof o=="string"&&(o=[o]),o&&(a=a.concat(o))}}),this.services.languageUtils.getBestMatchFromCodes?a:a.length>0?a[0]:null}},{key:"cacheUserLanguage",value:function(r,n){var a=this;n||(n=this.options.caches),n&&(this.options.excludeCacheFor&&this.options.excludeCacheFor.indexOf(r)>-1||n.forEach(function(i){a.detectors[i]&&a.detectors[i].cacheUserLanguage(r,a.options)}))}}]),e}();$f.type="languageDetector";const Pf=({resources:e})=>Q.useMemo(()=>ce.createInstance({defaultNS:"common",fallbackLng:"en",fallbackNS:"common",load:"languageOnly",ns:["common"],overloadTranslationOptionHandler:t=>({defaultValue:t[1]}),react:{useSuspense:!1},resources:e,supportedLngs:e?Object.keys(e):[]},t=>{if(t)return console.error(t)}).use($f),[e]),Ff=lc(e=>{const t=`.${e}`;return pc({key:"css",stylisPlugins:[n=>{n?.type==="rule"&&n?.value.startsWith(".css")&&(n.props=[n.props].flat().map(a=>a.includes(t)?a:`${t} ${a}`))},fp]})}),Df=({children:e,fallback:t,resources:r})=>{const{scope:n,onError:a}=Of(),i=Pf({resources:r});return ve("div",{className:n,children:ve(Pt.CacheProvider,{value:Ff(n),children:ve(Ug.I18nextProvider,{i18n:i,children:ve(wf,{fallback:t,onError:a,children:e})})})})},CL=(e,t,r)=>({resources:n,...a})=>{const i=r;return n&&Object.keys(r).forEach(o=>{Object.keys(r[o]).forEach(s=>{i[o][s]={...i[o][s],...n[o]?.[s]}})}),ve(Df,{resources:i,fallback:t,children:ve(e,{...a})})},AL={createElement:CL};exports.Alchemy=xR;exports.AlchemyContext=wi;exports.Element=Df;exports.ErrorBoundary=wf;exports.default=AL;exports.memoizedCreateCache=Ff;exports.useAlchemy=Of;exports.useI18n=Pf;exports.useLoadFonts=cf;exports.useLoadIcons=_f;exports.useLoadTheme=xf;Object.keys(st).forEach(e=>{e!=="default"&&!exports.hasOwnProperty(e)&&Object.defineProperty(exports,e,{enumerable:!0,get:()=>st[e]})});
30
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function TR(e){return OR(e)||wR(e)||RR(e)||LR()}function Du(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function ku(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Du(Object(r),!0).forEach(function(n){te(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Du(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var ER={type:"logger",log:function(t){this.output("log",t)},warn:function(t){this.output("warn",t)},error:function(t){this.output("error",t)},output:function(t,r){console&&console[t]&&console[t].apply(console,r)}},$R=function(){function e(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};Ee(this,e),this.init(t,r)}return $e(e,[{key:"init",value:function(r){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.prefix=n.prefix||"i18next:",this.logger=r||ER,this.options=n,this.debug=n.debug}},{key:"setDebug",value:function(r){this.debug=r}},{key:"log",value:function(){for(var r=arguments.length,n=new Array(r),a=0;a<r;a++)n[a]=arguments[a];return this.forward(n,"log","",!0)}},{key:"warn",value:function(){for(var r=arguments.length,n=new Array(r),a=0;a<r;a++)n[a]=arguments[a];return this.forward(n,"warn","",!0)}},{key:"error",value:function(){for(var r=arguments.length,n=new Array(r),a=0;a<r;a++)n[a]=arguments[a];return this.forward(n,"error","")}},{key:"deprecate",value:function(){for(var r=arguments.length,n=new Array(r),a=0;a<r;a++)n[a]=arguments[a];return this.forward(n,"warn","WARNING DEPRECATED: ",!0)}},{key:"forward",value:function(r,n,a,i){return i&&!this.debug?null:(typeof r[0]=="string"&&(r[0]="".concat(a).concat(this.prefix," ").concat(r[0])),this.logger[n](r))}},{key:"create",value:function(r){return new e(this.logger,ku(ku({},{prefix:"".concat(this.prefix,":").concat(r,":")}),this.options))}},{key:"clone",value:function(r){return r=r||this.options,r.prefix=r.prefix||this.prefix,new e(this.logger,r)}}]),e}(),Be=new $R,tt=function(){function e(){Ee(this,e),this.observers={}}return $e(e,[{key:"on",value:function(r,n){var a=this;return r.split(" ").forEach(function(i){a.observers[i]=a.observers[i]||[],a.observers[i].push(n)}),this}},{key:"off",value:function(r,n){if(this.observers[r]){if(!n){delete this.observers[r];return}this.observers[r]=this.observers[r].filter(function(a){return a!==n})}}},{key:"emit",value:function(r){for(var n=arguments.length,a=new Array(n>1?n-1:0),i=1;i<n;i++)a[i-1]=arguments[i];if(this.observers[r]){var o=[].concat(this.observers[r]);o.forEach(function(u){u.apply(void 0,a)})}if(this.observers["*"]){var s=[].concat(this.observers["*"]);s.forEach(function(u){u.apply(u,[r].concat(a))})}}}]),e}();function Tt(){var e,t,r=new Promise(function(n,a){e=n,t=a});return r.resolve=e,r.reject=t,r}function Bu(e){return e==null?"":""+e}function PR(e,t,r){e.forEach(function(n){t[n]&&(r[n]=t[n])})}function Ri(e,t,r){function n(s){return s&&s.indexOf("###")>-1?s.replace(/###/g,"."):s}function a(){return!e||typeof e=="string"}for(var i=typeof t!="string"?[].concat(t):t.split(".");i.length>1;){if(a())return{};var o=n(i.shift());!e[o]&&r&&(e[o]=new r),Object.prototype.hasOwnProperty.call(e,o)?e=e[o]:e={}}return a()?{}:{obj:e,k:n(i.shift())}}function Wu(e,t,r){var n=Ri(e,t,Object),a=n.obj,i=n.k;a[i]=r}function FR(e,t,r,n){var a=Ri(e,t,Object),i=a.obj,o=a.k;i[o]=i[o]||[],n&&(i[o]=i[o].concat(r)),n||i[o].push(r)}function Ar(e,t){var r=Ri(e,t),n=r.obj,a=r.k;if(n)return n[a]}function ju(e,t,r){var n=Ar(e,r);return n!==void 0?n:Ar(t,r)}function Rf(e,t,r){for(var n in t)n!=="__proto__"&&n!=="constructor"&&(n in e?typeof e[n]=="string"||e[n]instanceof String||typeof t[n]=="string"||t[n]instanceof String?r&&(e[n]=t[n]):Rf(e[n],t[n],r):e[n]=t[n]);return e}function yt(e){return e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&")}var DR={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;","/":"&#x2F;"};function kR(e){return typeof e=="string"?e.replace(/[&<>"'\/]/g,function(t){return DR[t]}):e}var Vr=typeof window<"u"&&window.navigator&&typeof window.navigator.userAgentData>"u"&&window.navigator.userAgent&&window.navigator.userAgent.indexOf("MSIE")>-1,BR=[" ",",","?","!",";"];function WR(e,t,r){t=t||"",r=r||"";var n=BR.filter(function(s){return t.indexOf(s)<0&&r.indexOf(s)<0});if(n.length===0)return!0;var a=new RegExp("(".concat(n.map(function(s){return s==="?"?"\\?":s}).join("|"),")")),i=!a.test(e);if(!i){var o=e.indexOf(r);o>0&&!a.test(e.substring(0,o))&&(i=!0)}return i}function Nu(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function ar(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Nu(Object(r),!0).forEach(function(n){te(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Nu(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function jR(e){var t=NR();return function(){var n=je(e),a;if(t){var i=je(this).constructor;a=Reflect.construct(n,arguments,i)}else a=n.apply(this,arguments);return Vt(this,a)}}function NR(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Lf(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:".";if(e){if(e[t])return e[t];for(var n=t.split(r),a=e,i=0;i<n.length;++i){if(!a||typeof a[n[i]]=="string"&&i+1<n.length)return;if(a[n[i]]===void 0){for(var o=2,s=n.slice(i,i+o).join(r),u=a[s];u===void 0&&n.length>i+o;)o++,s=n.slice(i,i+o).join(r),u=a[s];if(u===void 0)return;if(u===null)return null;if(t.endsWith(s)){if(typeof u=="string")return u;if(s&&typeof u[s]=="string")return u[s]}var f=n.slice(i+o).join(r);return f?Lf(u,f,r):void 0}a=a[n[i]]}return a}}var GR=function(e){Ur(r,e);var t=jR(r);function r(n){var a,i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{ns:["translation"],defaultNS:"translation"};return Ee(this,r),a=t.call(this),Vr&&tt.call(et(a)),a.data=n||{},a.options=i,a.options.keySeparator===void 0&&(a.options.keySeparator="."),a.options.ignoreJSONStructure===void 0&&(a.options.ignoreJSONStructure=!0),a}return $e(r,[{key:"addNamespaces",value:function(a){this.options.ns.indexOf(a)<0&&this.options.ns.push(a)}},{key:"removeNamespaces",value:function(a){var i=this.options.ns.indexOf(a);i>-1&&this.options.ns.splice(i,1)}},{key:"getResource",value:function(a,i,o){var s=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},u=s.keySeparator!==void 0?s.keySeparator:this.options.keySeparator,f=s.ignoreJSONStructure!==void 0?s.ignoreJSONStructure:this.options.ignoreJSONStructure,g=[a,i];o&&typeof o!="string"&&(g=g.concat(o)),o&&typeof o=="string"&&(g=g.concat(u?o.split(u):o)),a.indexOf(".")>-1&&(g=a.split("."));var c=Ar(this.data,g);return c||!f||typeof o!="string"?c:Lf(this.data&&this.data[a]&&this.data[a][i],o,u)}},{key:"addResource",value:function(a,i,o,s){var u=arguments.length>4&&arguments[4]!==void 0?arguments[4]:{silent:!1},f=this.options.keySeparator;f===void 0&&(f=".");var g=[a,i];o&&(g=g.concat(f?o.split(f):o)),a.indexOf(".")>-1&&(g=a.split("."),s=i,i=g[1]),this.addNamespaces(i),Wu(this.data,g,s),u.silent||this.emit("added",a,i,o,s)}},{key:"addResources",value:function(a,i,o){var s=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{silent:!1};for(var u in o)(typeof o[u]=="string"||Object.prototype.toString.apply(o[u])==="[object Array]")&&this.addResource(a,i,u,o[u],{silent:!0});s.silent||this.emit("added",a,i,o)}},{key:"addResourceBundle",value:function(a,i,o,s,u){var f=arguments.length>5&&arguments[5]!==void 0?arguments[5]:{silent:!1},g=[a,i];a.indexOf(".")>-1&&(g=a.split("."),s=o,o=i,i=g[1]),this.addNamespaces(i);var c=Ar(this.data,g)||{};s?Rf(c,o,u):c=ar(ar({},c),o),Wu(this.data,g,c),f.silent||this.emit("added",a,i,o)}},{key:"removeResourceBundle",value:function(a,i){this.hasResourceBundle(a,i)&&delete this.data[a][i],this.removeNamespaces(i),this.emit("removed",a,i)}},{key:"hasResourceBundle",value:function(a,i){return this.getResource(a,i)!==void 0}},{key:"getResourceBundle",value:function(a,i){return i||(i=this.options.defaultNS),this.options.compatibilityAPI==="v1"?ar(ar({},{}),this.getResource(a,i)):this.getResource(a,i)}},{key:"getDataByLanguage",value:function(a){return this.data[a]}},{key:"hasLanguageSomeTranslations",value:function(a){var i=this.getDataByLanguage(a),o=i&&Object.keys(i)||[];return!!o.find(function(s){return i[s]&&Object.keys(i[s]).length>0})}},{key:"toJSON",value:function(){return this.data}}]),r}(tt),Tf={processors:{},addPostProcessor:function(t){this.processors[t.name]=t},handle:function(t,r,n,a,i){var o=this;return t.forEach(function(s){o.processors[s]&&(r=o.processors[s].process(r,n,a,i))}),r}};function Gu(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function le(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Gu(Object(r),!0).forEach(function(n){te(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Gu(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function XR(e){var t=HR();return function(){var n=je(e),a;if(t){var i=je(this).constructor;a=Reflect.construct(n,arguments,i)}else a=n.apply(this,arguments);return Vt(this,a)}}function HR(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}var Xu={},Hu=function(e){Ur(r,e);var t=XR(r);function r(n){var a,i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return Ee(this,r),a=t.call(this),Vr&&tt.call(et(a)),PR(["resourceStore","languageUtils","pluralResolver","interpolator","backendConnector","i18nFormat","utils"],n,et(a)),a.options=i,a.options.keySeparator===void 0&&(a.options.keySeparator="."),a.logger=Be.create("translator"),a}return $e(r,[{key:"changeLanguage",value:function(a){a&&(this.language=a)}},{key:"exists",value:function(a){var i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{interpolation:{}};if(a==null)return!1;var o=this.resolve(a,i);return o&&o.res!==void 0}},{key:"extractFromKey",value:function(a,i){var o=i.nsSeparator!==void 0?i.nsSeparator:this.options.nsSeparator;o===void 0&&(o=":");var s=i.keySeparator!==void 0?i.keySeparator:this.options.keySeparator,u=i.ns||this.options.defaultNS||[],f=o&&a.indexOf(o)>-1,g=!this.options.userDefinedKeySeparator&&!i.keySeparator&&!this.options.userDefinedNsSeparator&&!i.nsSeparator&&!WR(a,o,s);if(f&&!g){var c=a.match(this.interpolator.nestingRegexp);if(c&&c.length>0)return{key:a,namespaces:u};var d=a.split(o);(o!==s||o===s&&this.options.ns.indexOf(d[0])>-1)&&(u=d.shift()),a=d.join(s)}return typeof u=="string"&&(u=[u]),{key:a,namespaces:u}}},{key:"translate",value:function(a,i,o){var s=this;if(Re(i)!=="object"&&this.options.overloadTranslationOptionHandler&&(i=this.options.overloadTranslationOptionHandler(arguments)),i||(i={}),a==null)return"";Array.isArray(a)||(a=[String(a)]);var u=i.returnDetails!==void 0?i.returnDetails:this.options.returnDetails,f=i.keySeparator!==void 0?i.keySeparator:this.options.keySeparator,g=this.extractFromKey(a[a.length-1],i),c=g.key,d=g.namespaces,h=d[d.length-1],v=i.lng||this.language,m=i.appendNamespaceToCIMode||this.options.appendNamespaceToCIMode;if(v&&v.toLowerCase()==="cimode"){if(m){var b=i.nsSeparator||this.options.nsSeparator;return u?{res:"".concat(h).concat(b).concat(c),usedKey:c,exactUsedKey:c,usedLng:v,usedNS:h}:"".concat(h).concat(b).concat(c)}return u?{res:c,usedKey:c,exactUsedKey:c,usedLng:v,usedNS:h}:c}var y=this.resolve(a,i),A=y&&y.res,x=y&&y.usedKey||c,I=y&&y.exactUsedKey||c,S=Object.prototype.toString.apply(A),D=["[object Number]","[object Function]","[object RegExp]"],$=i.joinArrays!==void 0?i.joinArrays:this.options.joinArrays,N=!this.i18nFormat||this.i18nFormat.handleAsObject,ne=typeof A!="string"&&typeof A!="boolean"&&typeof A!="number";if(N&&A&&ne&&D.indexOf(S)<0&&!(typeof $=="string"&&S==="[object Array]")){if(!i.returnObjects&&!this.options.returnObjects){this.options.returnedObjectHandler||this.logger.warn("accessing an object - but returnObjects options is not enabled!");var W=this.options.returnedObjectHandler?this.options.returnedObjectHandler(x,A,le(le({},i),{},{ns:d})):"key '".concat(c," (").concat(this.language,")' returned an object instead of string.");return u?(y.res=W,y):W}if(f){var F=S==="[object Array]",q=F?[]:{},oe=F?I:x;for(var ee in A)if(Object.prototype.hasOwnProperty.call(A,ee)){var Ge="".concat(oe).concat(f).concat(ee);q[ee]=this.translate(Ge,le(le({},i),{joinArrays:!1,ns:d})),q[ee]===Ge&&(q[ee]=A[ee])}A=q}}else if(N&&typeof $=="string"&&S==="[object Array]")A=A.join($),A&&(A=this.extendTranslation(A,a,i,o));else{var Pe=!1,_e=!1,Fe=i.count!==void 0&&typeof i.count!="string",Xe=r.hasDefaultValue(i),Ye=Fe?this.pluralResolver.getSuffix(v,i.count,i):"",Ae=i["defaultValue".concat(Ye)]||i.defaultValue;!this.isValidLookup(A)&&Xe&&(Pe=!0,A=Ae),this.isValidLookup(A)||(_e=!0,A=c);var Je=i.missingKeyNoValueFallbackToKey||this.options.missingKeyNoValueFallbackToKey,k=Je&&_e?void 0:A,ue=Xe&&Ae!==A&&this.options.updateMissing;if(_e||Pe||ue){if(this.logger.log(ue?"updateKey":"missingKey",v,h,c,ue?Ae:A),f){var E=this.resolve(c,le(le({},i),{},{keySeparator:!1}));E&&E.res&&this.logger.warn("Seems the loaded translations were in flat JSON format instead of nested. Either set keySeparator: false on init or make sure your translations are published in nested format.")}var _=[],w=this.languageUtils.getFallbackCodes(this.options.fallbackLng,i.lng||this.language);if(this.options.saveMissingTo==="fallback"&&w&&w[0])for(var P=0;P<w.length;P++)_.push(w[P]);else this.options.saveMissingTo==="all"?_=this.languageUtils.toResolveHierarchy(i.lng||this.language):_.push(i.lng||this.language);var B=function(K,O,ae){var be=Xe&&ae!==A?ae:k;s.options.missingKeyHandler?s.options.missingKeyHandler(K,h,O,be,ue,i):s.backendConnector&&s.backendConnector.saveMissing&&s.backendConnector.saveMissing(K,h,O,be,ue,i),s.emit("missingKey",K,h,O,A)};this.options.saveMissing&&(this.options.saveMissingPlurals&&Fe?_.forEach(function(V){s.pluralResolver.getSuffixes(V,i).forEach(function(K){B([V],c+K,i["defaultValue".concat(K)]||Ae)})}):B(_,c,Ae))}A=this.extendTranslation(A,a,i,y,o),_e&&A===c&&this.options.appendNamespaceToMissingKey&&(A="".concat(h,":").concat(c)),(_e||Pe)&&this.options.parseMissingKeyHandler&&(this.options.compatibilityAPI!=="v1"?A=this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey?"".concat(h,":").concat(c):c,Pe?A:void 0):A=this.options.parseMissingKeyHandler(A))}return u?(y.res=A,y):A}},{key:"extendTranslation",value:function(a,i,o,s,u){var f=this;if(this.i18nFormat&&this.i18nFormat.parse)a=this.i18nFormat.parse(a,le(le({},this.options.interpolation.defaultVariables),o),s.usedLng,s.usedNS,s.usedKey,{resolved:s});else if(!o.skipInterpolation){o.interpolation&&this.interpolator.init(le(le({},o),{interpolation:le(le({},this.options.interpolation),o.interpolation)}));var g=typeof a=="string"&&(o&&o.interpolation&&o.interpolation.skipOnVariables!==void 0?o.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables),c;if(g){var d=a.match(this.interpolator.nestingRegexp);c=d&&d.length}var h=o.replace&&typeof o.replace!="string"?o.replace:o;if(this.options.interpolation.defaultVariables&&(h=le(le({},this.options.interpolation.defaultVariables),h)),a=this.interpolator.interpolate(a,h,o.lng||this.language,o),g){var v=a.match(this.interpolator.nestingRegexp),m=v&&v.length;c<m&&(o.nest=!1)}o.nest!==!1&&(a=this.interpolator.nest(a,function(){for(var A=arguments.length,x=new Array(A),I=0;I<A;I++)x[I]=arguments[I];return u&&u[0]===x[0]&&!o.context?(f.logger.warn("It seems you are nesting recursively key: ".concat(x[0]," in key: ").concat(i[0])),null):f.translate.apply(f,x.concat([i]))},o)),o.interpolation&&this.interpolator.reset()}var b=o.postProcess||this.options.postProcess,y=typeof b=="string"?[b]:b;return a!=null&&y&&y.length&&o.applyPostProcessor!==!1&&(a=Tf.handle(y,a,i,this.options&&this.options.postProcessPassResolved?le({i18nResolved:s},o):o,this)),a}},{key:"resolve",value:function(a){var i=this,o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},s,u,f,g,c;return typeof a=="string"&&(a=[a]),a.forEach(function(d){if(!i.isValidLookup(s)){var h=i.extractFromKey(d,o),v=h.key;u=v;var m=h.namespaces;i.options.fallbackNS&&(m=m.concat(i.options.fallbackNS));var b=o.count!==void 0&&typeof o.count!="string",y=b&&!o.ordinal&&o.count===0&&i.pluralResolver.shouldUseIntlApi(),A=o.context!==void 0&&(typeof o.context=="string"||typeof o.context=="number")&&o.context!=="",x=o.lngs?o.lngs:i.languageUtils.toResolveHierarchy(o.lng||i.language,o.fallbackLng);m.forEach(function(I){i.isValidLookup(s)||(c=I,!Xu["".concat(x[0],"-").concat(I)]&&i.utils&&i.utils.hasLoadedNamespace&&!i.utils.hasLoadedNamespace(c)&&(Xu["".concat(x[0],"-").concat(I)]=!0,i.logger.warn('key "'.concat(u,'" for languages "').concat(x.join(", "),`" won't get resolved as namespace "`).concat(c,'" was not yet loaded'),"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")),x.forEach(function(S){if(!i.isValidLookup(s)){g=S;var D=[v];if(i.i18nFormat&&i.i18nFormat.addLookupKeys)i.i18nFormat.addLookupKeys(D,v,S,I,o);else{var $;b&&($=i.pluralResolver.getSuffix(S,o.count,o));var N="".concat(i.options.pluralSeparator,"zero");if(b&&(D.push(v+$),y&&D.push(v+N)),A){var ne="".concat(v).concat(i.options.contextSeparator).concat(o.context);D.push(ne),b&&(D.push(ne+$),y&&D.push(ne+N))}}for(var W;W=D.pop();)i.isValidLookup(s)||(f=W,s=i.getResource(S,I,W,o))}}))})}}),{res:s,usedKey:u,exactUsedKey:f,usedLng:g,usedNS:c}}},{key:"isValidLookup",value:function(a){return a!==void 0&&!(!this.options.returnNull&&a===null)&&!(!this.options.returnEmptyString&&a==="")}},{key:"getResource",value:function(a,i,o){var s=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};return this.i18nFormat&&this.i18nFormat.getResource?this.i18nFormat.getResource(a,i,o,s):this.resourceStore.getResource(a,i,o,s)}}],[{key:"hasDefaultValue",value:function(a){var i="defaultValue";for(var o in a)if(Object.prototype.hasOwnProperty.call(a,o)&&i===o.substring(0,i.length)&&a[o]!==void 0)return!0;return!1}}]),r}(tt);function La(e){return e.charAt(0).toUpperCase()+e.slice(1)}var Mu=function(){function e(t){Ee(this,e),this.options=t,this.supportedLngs=this.options.supportedLngs||!1,this.logger=Be.create("languageUtils")}return $e(e,[{key:"getScriptPartFromCode",value:function(r){if(!r||r.indexOf("-")<0)return null;var n=r.split("-");return n.length===2||(n.pop(),n[n.length-1].toLowerCase()==="x")?null:this.formatLanguageCode(n.join("-"))}},{key:"getLanguagePartFromCode",value:function(r){if(!r||r.indexOf("-")<0)return r;var n=r.split("-");return this.formatLanguageCode(n[0])}},{key:"formatLanguageCode",value:function(r){if(typeof r=="string"&&r.indexOf("-")>-1){var n=["hans","hant","latn","cyrl","cans","mong","arab"],a=r.split("-");return this.options.lowerCaseLng?a=a.map(function(i){return i.toLowerCase()}):a.length===2?(a[0]=a[0].toLowerCase(),a[1]=a[1].toUpperCase(),n.indexOf(a[1].toLowerCase())>-1&&(a[1]=La(a[1].toLowerCase()))):a.length===3&&(a[0]=a[0].toLowerCase(),a[1].length===2&&(a[1]=a[1].toUpperCase()),a[0]!=="sgn"&&a[2].length===2&&(a[2]=a[2].toUpperCase()),n.indexOf(a[1].toLowerCase())>-1&&(a[1]=La(a[1].toLowerCase())),n.indexOf(a[2].toLowerCase())>-1&&(a[2]=La(a[2].toLowerCase()))),a.join("-")}return this.options.cleanCode||this.options.lowerCaseLng?r.toLowerCase():r}},{key:"isSupportedCode",value:function(r){return(this.options.load==="languageOnly"||this.options.nonExplicitSupportedLngs)&&(r=this.getLanguagePartFromCode(r)),!this.supportedLngs||!this.supportedLngs.length||this.supportedLngs.indexOf(r)>-1}},{key:"getBestMatchFromCodes",value:function(r){var n=this;if(!r)return null;var a;return r.forEach(function(i){if(!a){var o=n.formatLanguageCode(i);(!n.options.supportedLngs||n.isSupportedCode(o))&&(a=o)}}),!a&&this.options.supportedLngs&&r.forEach(function(i){if(!a){var o=n.getLanguagePartFromCode(i);if(n.isSupportedCode(o))return a=o;a=n.options.supportedLngs.find(function(s){if(s.indexOf(o)===0)return s})}}),a||(a=this.getFallbackCodes(this.options.fallbackLng)[0]),a}},{key:"getFallbackCodes",value:function(r,n){if(!r)return[];if(typeof r=="function"&&(r=r(n)),typeof r=="string"&&(r=[r]),Object.prototype.toString.apply(r)==="[object Array]")return r;if(!n)return r.default||[];var a=r[n];return a||(a=r[this.getScriptPartFromCode(n)]),a||(a=r[this.formatLanguageCode(n)]),a||(a=r[this.getLanguagePartFromCode(n)]),a||(a=r.default),a||[]}},{key:"toResolveHierarchy",value:function(r,n){var a=this,i=this.getFallbackCodes(n||this.options.fallbackLng||[],r),o=[],s=function(f){f&&(a.isSupportedCode(f)?o.push(f):a.logger.warn("rejecting language code not found in supportedLngs: ".concat(f)))};return typeof r=="string"&&r.indexOf("-")>-1?(this.options.load!=="languageOnly"&&s(this.formatLanguageCode(r)),this.options.load!=="languageOnly"&&this.options.load!=="currentOnly"&&s(this.getScriptPartFromCode(r)),this.options.load!=="currentOnly"&&s(this.getLanguagePartFromCode(r))):typeof r=="string"&&s(this.formatLanguageCode(r)),i.forEach(function(u){o.indexOf(u)<0&&s(a.formatLanguageCode(u))}),o}}]),e}(),MR=[{lngs:["ach","ak","am","arn","br","fil","gun","ln","mfe","mg","mi","oc","pt","pt-BR","tg","tl","ti","tr","uz","wa"],nr:[1,2],fc:1},{lngs:["af","an","ast","az","bg","bn","ca","da","de","dev","el","en","eo","es","et","eu","fi","fo","fur","fy","gl","gu","ha","hi","hu","hy","ia","it","kk","kn","ku","lb","mai","ml","mn","mr","nah","nap","nb","ne","nl","nn","no","nso","pa","pap","pms","ps","pt-PT","rm","sco","se","si","so","son","sq","sv","sw","ta","te","tk","ur","yo"],nr:[1,2],fc:2},{lngs:["ay","bo","cgg","fa","ht","id","ja","jbo","ka","km","ko","ky","lo","ms","sah","su","th","tt","ug","vi","wo","zh"],nr:[1],fc:3},{lngs:["be","bs","cnr","dz","hr","ru","sr","uk"],nr:[1,2,5],fc:4},{lngs:["ar"],nr:[0,1,2,3,11,100],fc:5},{lngs:["cs","sk"],nr:[1,2,5],fc:6},{lngs:["csb","pl"],nr:[1,2,5],fc:7},{lngs:["cy"],nr:[1,2,3,8],fc:8},{lngs:["fr"],nr:[1,2],fc:9},{lngs:["ga"],nr:[1,2,3,7,11],fc:10},{lngs:["gd"],nr:[1,2,3,20],fc:11},{lngs:["is"],nr:[1,2],fc:12},{lngs:["jv"],nr:[0,1],fc:13},{lngs:["kw"],nr:[1,2,3,4],fc:14},{lngs:["lt"],nr:[1,2,10],fc:15},{lngs:["lv"],nr:[1,2,0],fc:16},{lngs:["mk"],nr:[1,2],fc:17},{lngs:["mnk"],nr:[0,1,2],fc:18},{lngs:["mt"],nr:[1,2,11,20],fc:19},{lngs:["or"],nr:[2,1],fc:2},{lngs:["ro"],nr:[1,2,20],fc:20},{lngs:["sl"],nr:[5,1,2,3],fc:21},{lngs:["he","iw"],nr:[1,2,20,21],fc:22}],zR={1:function(t){return Number(t>1)},2:function(t){return Number(t!=1)},3:function(t){return 0},4:function(t){return Number(t%10==1&&t%100!=11?0:t%10>=2&&t%10<=4&&(t%100<10||t%100>=20)?1:2)},5:function(t){return Number(t==0?0:t==1?1:t==2?2:t%100>=3&&t%100<=10?3:t%100>=11?4:5)},6:function(t){return Number(t==1?0:t>=2&&t<=4?1:2)},7:function(t){return Number(t==1?0:t%10>=2&&t%10<=4&&(t%100<10||t%100>=20)?1:2)},8:function(t){return Number(t==1?0:t==2?1:t!=8&&t!=11?2:3)},9:function(t){return Number(t>=2)},10:function(t){return Number(t==1?0:t==2?1:t<7?2:t<11?3:4)},11:function(t){return Number(t==1||t==11?0:t==2||t==12?1:t>2&&t<20?2:3)},12:function(t){return Number(t%10!=1||t%100==11)},13:function(t){return Number(t!==0)},14:function(t){return Number(t==1?0:t==2?1:t==3?2:3)},15:function(t){return Number(t%10==1&&t%100!=11?0:t%10>=2&&(t%100<10||t%100>=20)?1:2)},16:function(t){return Number(t%10==1&&t%100!=11?0:t!==0?1:2)},17:function(t){return Number(t==1||t%10==1&&t%100!=11?0:1)},18:function(t){return Number(t==0?0:t==1?1:2)},19:function(t){return Number(t==1?0:t==0||t%100>1&&t%100<11?1:t%100>10&&t%100<20?2:3)},20:function(t){return Number(t==1?0:t==0||t%100>0&&t%100<20?1:2)},21:function(t){return Number(t%100==1?1:t%100==2?2:t%100==3||t%100==4?3:0)},22:function(t){return Number(t==1?0:t==2?1:(t<0||t>10)&&t%10==0?2:3)}},UR=["v1","v2","v3"],zu={zero:0,one:1,two:2,few:3,many:4,other:5};function VR(){var e={};return MR.forEach(function(t){t.lngs.forEach(function(r){e[r]={numbers:t.nr,plurals:zR[t.fc]}})}),e}var ZR=function(){function e(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};Ee(this,e),this.languageUtils=t,this.options=r,this.logger=Be.create("pluralResolver"),(!this.options.compatibilityJSON||this.options.compatibilityJSON==="v4")&&(typeof Intl>"u"||!Intl.PluralRules)&&(this.options.compatibilityJSON="v3",this.logger.error("Your environment seems not to be Intl API compatible, use an Intl.PluralRules polyfill. Will fallback to the compatibilityJSON v3 format handling.")),this.rules=VR()}return $e(e,[{key:"addRule",value:function(r,n){this.rules[r]=n}},{key:"getRule",value:function(r){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(this.shouldUseIntlApi())try{return new Intl.PluralRules(r,{type:n.ordinal?"ordinal":"cardinal"})}catch{return}return this.rules[r]||this.rules[this.languageUtils.getLanguagePartFromCode(r)]}},{key:"needsPlural",value:function(r){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},a=this.getRule(r,n);return this.shouldUseIntlApi()?a&&a.resolvedOptions().pluralCategories.length>1:a&&a.numbers.length>1}},{key:"getPluralFormsOfKey",value:function(r,n){var a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return this.getSuffixes(r,a).map(function(i){return"".concat(n).concat(i)})}},{key:"getSuffixes",value:function(r){var n=this,a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=this.getRule(r,a);return i?this.shouldUseIntlApi()?i.resolvedOptions().pluralCategories.sort(function(o,s){return zu[o]-zu[s]}).map(function(o){return"".concat(n.options.prepend).concat(o)}):i.numbers.map(function(o){return n.getSuffix(r,o,a)}):[]}},{key:"getSuffix",value:function(r,n){var a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},i=this.getRule(r,a);return i?this.shouldUseIntlApi()?"".concat(this.options.prepend).concat(i.select(n)):this.getSuffixRetroCompatible(i,n):(this.logger.warn("no plural rule found for: ".concat(r)),"")}},{key:"getSuffixRetroCompatible",value:function(r,n){var a=this,i=r.noAbs?r.plurals(n):r.plurals(Math.abs(n)),o=r.numbers[i];this.options.simplifyPluralSuffix&&r.numbers.length===2&&r.numbers[0]===1&&(o===2?o="plural":o===1&&(o=""));var s=function(){return a.options.prepend&&o.toString()?a.options.prepend+o.toString():o.toString()};return this.options.compatibilityJSON==="v1"?o===1?"":typeof o=="number"?"_plural_".concat(o.toString()):s():this.options.compatibilityJSON==="v2"||this.options.simplifyPluralSuffix&&r.numbers.length===2&&r.numbers[0]===1?s():this.options.prepend&&i.toString()?this.options.prepend+i.toString():i.toString()}},{key:"shouldUseIntlApi",value:function(){return!UR.includes(this.options.compatibilityJSON)}}]),e}();function Uu(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function xe(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Uu(Object(r),!0).forEach(function(n){te(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Uu(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var qR=function(){function e(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};Ee(this,e),this.logger=Be.create("interpolator"),this.options=t,this.format=t.interpolation&&t.interpolation.format||function(r){return r},this.init(t)}return $e(e,[{key:"init",value:function(){var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};r.interpolation||(r.interpolation={escapeValue:!0});var n=r.interpolation;this.escape=n.escape!==void 0?n.escape:kR,this.escapeValue=n.escapeValue!==void 0?n.escapeValue:!0,this.useRawValueToEscape=n.useRawValueToEscape!==void 0?n.useRawValueToEscape:!1,this.prefix=n.prefix?yt(n.prefix):n.prefixEscaped||"{{",this.suffix=n.suffix?yt(n.suffix):n.suffixEscaped||"}}",this.formatSeparator=n.formatSeparator?n.formatSeparator:n.formatSeparator||",",this.unescapePrefix=n.unescapeSuffix?"":n.unescapePrefix||"-",this.unescapeSuffix=this.unescapePrefix?"":n.unescapeSuffix||"",this.nestingPrefix=n.nestingPrefix?yt(n.nestingPrefix):n.nestingPrefixEscaped||yt("$t("),this.nestingSuffix=n.nestingSuffix?yt(n.nestingSuffix):n.nestingSuffixEscaped||yt(")"),this.nestingOptionsSeparator=n.nestingOptionsSeparator?n.nestingOptionsSeparator:n.nestingOptionsSeparator||",",this.maxReplaces=n.maxReplaces?n.maxReplaces:1e3,this.alwaysFormat=n.alwaysFormat!==void 0?n.alwaysFormat:!1,this.resetRegExp()}},{key:"reset",value:function(){this.options&&this.init(this.options)}},{key:"resetRegExp",value:function(){var r="".concat(this.prefix,"(.+?)").concat(this.suffix);this.regexp=new RegExp(r,"g");var n="".concat(this.prefix).concat(this.unescapePrefix,"(.+?)").concat(this.unescapeSuffix).concat(this.suffix);this.regexpUnescape=new RegExp(n,"g");var a="".concat(this.nestingPrefix,"(.+?)").concat(this.nestingSuffix);this.nestingRegexp=new RegExp(a,"g")}},{key:"interpolate",value:function(r,n,a,i){var o=this,s,u,f,g=this.options&&this.options.interpolation&&this.options.interpolation.defaultVariables||{};function c(b){return b.replace(/\$/g,"$$$$")}var d=function(y){if(y.indexOf(o.formatSeparator)<0){var A=ju(n,g,y);return o.alwaysFormat?o.format(A,void 0,a,xe(xe(xe({},i),n),{},{interpolationkey:y})):A}var x=y.split(o.formatSeparator),I=x.shift().trim(),S=x.join(o.formatSeparator).trim();return o.format(ju(n,g,I),S,a,xe(xe(xe({},i),n),{},{interpolationkey:I}))};this.resetRegExp();var h=i&&i.missingInterpolationHandler||this.options.missingInterpolationHandler,v=i&&i.interpolation&&i.interpolation.skipOnVariables!==void 0?i.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables,m=[{regex:this.regexpUnescape,safeValue:function(y){return c(y)}},{regex:this.regexp,safeValue:function(y){return o.escapeValue?c(o.escape(y)):c(y)}}];return m.forEach(function(b){for(f=0;s=b.regex.exec(r);){var y=s[1].trim();if(u=d(y),u===void 0)if(typeof h=="function"){var A=h(r,s,i);u=typeof A=="string"?A:""}else if(i&&Object.prototype.hasOwnProperty.call(i,y))u="";else if(v){u=s[0];continue}else o.logger.warn("missed to pass in variable ".concat(y," for interpolating ").concat(r)),u="";else typeof u!="string"&&!o.useRawValueToEscape&&(u=Bu(u));var x=b.safeValue(u);if(r=r.replace(s[0],x),v?(b.regex.lastIndex+=u.length,b.regex.lastIndex-=s[0].length):b.regex.lastIndex=0,f++,f>=o.maxReplaces)break}}),r}},{key:"nest",value:function(r,n){var a=this,i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},o,s,u;function f(h,v){var m=this.nestingOptionsSeparator;if(h.indexOf(m)<0)return h;var b=h.split(new RegExp("".concat(m,"[ ]*{"))),y="{".concat(b[1]);h=b[0],y=this.interpolate(y,u);var A=y.match(/'/g),x=y.match(/"/g);(A&&A.length%2===0&&!x||x.length%2!==0)&&(y=y.replace(/'/g,'"'));try{u=JSON.parse(y),v&&(u=xe(xe({},v),u))}catch(I){return this.logger.warn("failed parsing options string in nesting for key ".concat(h),I),"".concat(h).concat(m).concat(y)}return delete u.defaultValue,h}for(;o=this.nestingRegexp.exec(r);){var g=[];u=xe({},i),u=u.replace&&typeof u.replace!="string"?u.replace:u,u.applyPostProcessor=!1,delete u.defaultValue;var c=!1;if(o[0].indexOf(this.formatSeparator)!==-1&&!/{.*}/.test(o[1])){var d=o[1].split(this.formatSeparator).map(function(h){return h.trim()});o[1]=d.shift(),g=d,c=!0}if(s=n(f.call(this,o[1].trim(),u),u),s&&o[0]===r&&typeof s!="string")return s;typeof s!="string"&&(s=Bu(s)),s||(this.logger.warn("missed to resolve ".concat(o[1]," for nesting ").concat(r)),s=""),c&&(s=g.reduce(function(h,v){return a.format(h,v,i.lng,xe(xe({},i),{},{interpolationkey:o[1].trim()}))},s.trim())),r=r.replace(o[0],s),this.regexp.lastIndex=0}return r}}]),e}();function Vu(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function ze(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Vu(Object(r),!0).forEach(function(n){te(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Vu(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function YR(e){var t=e.toLowerCase().trim(),r={};if(e.indexOf("(")>-1){var n=e.split("(");t=n[0].toLowerCase().trim();var a=n[1].substring(0,n[1].length-1);if(t==="currency"&&a.indexOf(":")<0)r.currency||(r.currency=a.trim());else if(t==="relativetime"&&a.indexOf(":")<0)r.range||(r.range=a.trim());else{var i=a.split(";");i.forEach(function(o){if(o){var s=o.split(":"),u=TR(s),f=u[0],g=u.slice(1),c=g.join(":").trim().replace(/^'+|'+$/g,"");r[f.trim()]||(r[f.trim()]=c),c==="false"&&(r[f.trim()]=!1),c==="true"&&(r[f.trim()]=!0),isNaN(c)||(r[f.trim()]=parseInt(c,10))}})}}return{formatName:t,formatOptions:r}}function vt(e){var t={};return function(n,a,i){var o=a+JSON.stringify(i),s=t[o];return s||(s=e(a,i),t[o]=s),s(n)}}var JR=function(){function e(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};Ee(this,e),this.logger=Be.create("formatter"),this.options=t,this.formats={number:vt(function(r,n){var a=new Intl.NumberFormat(r,ze({},n));return function(i){return a.format(i)}}),currency:vt(function(r,n){var a=new Intl.NumberFormat(r,ze(ze({},n),{},{style:"currency"}));return function(i){return a.format(i)}}),datetime:vt(function(r,n){var a=new Intl.DateTimeFormat(r,ze({},n));return function(i){return a.format(i)}}),relativetime:vt(function(r,n){var a=new Intl.RelativeTimeFormat(r,ze({},n));return function(i){return a.format(i,n.range||"day")}}),list:vt(function(r,n){var a=new Intl.ListFormat(r,ze({},n));return function(i){return a.format(i)}})},this.init(t)}return $e(e,[{key:"init",value:function(r){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{interpolation:{}},a=n.interpolation;this.formatSeparator=a.formatSeparator?a.formatSeparator:a.formatSeparator||","}},{key:"add",value:function(r,n){this.formats[r.toLowerCase().trim()]=n}},{key:"addCached",value:function(r,n){this.formats[r.toLowerCase().trim()]=vt(n)}},{key:"format",value:function(r,n,a){var i=this,o=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},s=n.split(this.formatSeparator),u=s.reduce(function(f,g){var c=YR(g),d=c.formatName,h=c.formatOptions;if(i.formats[d]){var v=f;try{var m=o&&o.formatParams&&o.formatParams[o.interpolationkey]||{},b=m.locale||m.lng||o.locale||o.lng||a;v=i.formats[d](f,b,ze(ze(ze({},h),o),m))}catch(y){i.logger.warn(y)}return v}else i.logger.warn("there was no format function for ".concat(d));return f},r);return u}}]),e}();function Zu(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function qu(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Zu(Object(r),!0).forEach(function(n){te(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Zu(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function KR(e){var t=QR();return function(){var n=je(e),a;if(t){var i=je(this).constructor;a=Reflect.construct(n,arguments,i)}else a=n.apply(this,arguments);return Vt(this,a)}}function QR(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function eL(e,t){e.pending[t]!==void 0&&(delete e.pending[t],e.pendingCount--)}var tL=function(e){Ur(r,e);var t=KR(r);function r(n,a,i){var o,s=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};return Ee(this,r),o=t.call(this),Vr&&tt.call(et(o)),o.backend=n,o.store=a,o.services=i,o.languageUtils=i.languageUtils,o.options=s,o.logger=Be.create("backendConnector"),o.waitingReads=[],o.maxParallelReads=s.maxParallelReads||10,o.readingCalls=0,o.maxRetries=s.maxRetries>=0?s.maxRetries:5,o.retryTimeout=s.retryTimeout>=1?s.retryTimeout:350,o.state={},o.queue=[],o.backend&&o.backend.init&&o.backend.init(i,s.backend,s),o}return $e(r,[{key:"queueLoad",value:function(a,i,o,s){var u=this,f={},g={},c={},d={};return a.forEach(function(h){var v=!0;i.forEach(function(m){var b="".concat(h,"|").concat(m);!o.reload&&u.store.hasResourceBundle(h,m)?u.state[b]=2:u.state[b]<0||(u.state[b]===1?g[b]===void 0&&(g[b]=!0):(u.state[b]=1,v=!1,g[b]===void 0&&(g[b]=!0),f[b]===void 0&&(f[b]=!0),d[m]===void 0&&(d[m]=!0)))}),v||(c[h]=!0)}),(Object.keys(f).length||Object.keys(g).length)&&this.queue.push({pending:g,pendingCount:Object.keys(g).length,loaded:{},errors:[],callback:s}),{toLoad:Object.keys(f),pending:Object.keys(g),toLoadLanguages:Object.keys(c),toLoadNamespaces:Object.keys(d)}}},{key:"loaded",value:function(a,i,o){var s=a.split("|"),u=s[0],f=s[1];i&&this.emit("failedLoading",u,f,i),o&&this.store.addResourceBundle(u,f,o),this.state[a]=i?-1:2;var g={};this.queue.forEach(function(c){FR(c.loaded,[u],f),eL(c,a),i&&c.errors.push(i),c.pendingCount===0&&!c.done&&(Object.keys(c.loaded).forEach(function(d){g[d]||(g[d]={});var h=c.loaded[d];h.length&&h.forEach(function(v){g[d][v]===void 0&&(g[d][v]=!0)})}),c.done=!0,c.errors.length?c.callback(c.errors):c.callback())}),this.emit("loaded",g),this.queue=this.queue.filter(function(c){return!c.done})}},{key:"read",value:function(a,i,o){var s=this,u=arguments.length>3&&arguments[3]!==void 0?arguments[3]:0,f=arguments.length>4&&arguments[4]!==void 0?arguments[4]:this.retryTimeout,g=arguments.length>5?arguments[5]:void 0;if(!a.length)return g(null,{});if(this.readingCalls>=this.maxParallelReads){this.waitingReads.push({lng:a,ns:i,fcName:o,tried:u,wait:f,callback:g});return}this.readingCalls++;var c=function(m,b){if(s.readingCalls--,s.waitingReads.length>0){var y=s.waitingReads.shift();s.read(y.lng,y.ns,y.fcName,y.tried,y.wait,y.callback)}if(m&&b&&u<s.maxRetries){setTimeout(function(){s.read.call(s,a,i,o,u+1,f*2,g)},f);return}g(m,b)},d=this.backend[o].bind(this.backend);if(d.length===2){try{var h=d(a,i);h&&typeof h.then=="function"?h.then(function(v){return c(null,v)}).catch(c):c(null,h)}catch(v){c(v)}return}return d(a,i,c)}},{key:"prepareLoading",value:function(a,i){var o=this,s=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},u=arguments.length>3?arguments[3]:void 0;if(!this.backend)return this.logger.warn("No backend was added via i18next.use. Will not load resources."),u&&u();typeof a=="string"&&(a=this.languageUtils.toResolveHierarchy(a)),typeof i=="string"&&(i=[i]);var f=this.queueLoad(a,i,s,u);if(!f.toLoad.length)return f.pending.length||u(),null;f.toLoad.forEach(function(g){o.loadOne(g)})}},{key:"load",value:function(a,i,o){this.prepareLoading(a,i,{},o)}},{key:"reload",value:function(a,i,o){this.prepareLoading(a,i,{reload:!0},o)}},{key:"loadOne",value:function(a){var i=this,o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",s=a.split("|"),u=s[0],f=s[1];this.read(u,f,"read",void 0,void 0,function(g,c){g&&i.logger.warn("".concat(o,"loading namespace ").concat(f," for language ").concat(u," failed"),g),!g&&c&&i.logger.log("".concat(o,"loaded namespace ").concat(f," for language ").concat(u),c),i.loaded(a,g,c)})}},{key:"saveMissing",value:function(a,i,o,s,u){var f=arguments.length>5&&arguments[5]!==void 0?arguments[5]:{},g=arguments.length>6&&arguments[6]!==void 0?arguments[6]:function(){};if(this.services.utils&&this.services.utils.hasLoadedNamespace&&!this.services.utils.hasLoadedNamespace(i)){this.logger.warn('did not save key "'.concat(o,'" as the namespace "').concat(i,'" was not yet loaded'),"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!");return}if(!(o==null||o==="")){if(this.backend&&this.backend.create){var c=qu(qu({},f),{},{isUpdate:u}),d=this.backend.create.bind(this.backend);if(d.length<6)try{var h;d.length===5?h=d(a,i,o,s,c):h=d(a,i,o,s),h&&typeof h.then=="function"?h.then(function(v){return g(null,v)}).catch(g):g(null,h)}catch(v){g(v)}else d(a,i,o,s,g,c)}!a||!a[0]||this.store.addResource(a[0],i,o,s)}}}]),r}(tt);function Yu(){return{debug:!1,initImmediate:!0,ns:["translation"],defaultNS:["translation"],fallbackLng:["dev"],fallbackNS:!1,supportedLngs:!1,nonExplicitSupportedLngs:!1,load:"all",preload:!1,simplifyPluralSuffix:!0,keySeparator:".",nsSeparator:":",pluralSeparator:"_",contextSeparator:"_",partialBundledLanguages:!1,saveMissing:!1,updateMissing:!1,saveMissingTo:"fallback",saveMissingPlurals:!0,missingKeyHandler:!1,missingInterpolationHandler:!1,postProcess:!1,postProcessPassResolved:!1,returnNull:!0,returnEmptyString:!0,returnObjects:!1,joinArrays:!1,returnedObjectHandler:!1,parseMissingKeyHandler:!1,appendNamespaceToMissingKey:!1,appendNamespaceToCIMode:!1,overloadTranslationOptionHandler:function(t){var r={};if(Re(t[1])==="object"&&(r=t[1]),typeof t[1]=="string"&&(r.defaultValue=t[1]),typeof t[2]=="string"&&(r.tDescription=t[2]),Re(t[2])==="object"||Re(t[3])==="object"){var n=t[3]||t[2];Object.keys(n).forEach(function(a){r[a]=n[a]})}return r},interpolation:{escapeValue:!0,format:function(t,r,n,a){return t},prefix:"{{",suffix:"}}",formatSeparator:",",unescapePrefix:"-",nestingPrefix:"$t(",nestingSuffix:")",nestingOptionsSeparator:",",maxReplaces:1e3,skipOnVariables:!0}}}function Ju(e){return typeof e.ns=="string"&&(e.ns=[e.ns]),typeof e.fallbackLng=="string"&&(e.fallbackLng=[e.fallbackLng]),typeof e.fallbackNS=="string"&&(e.fallbackNS=[e.fallbackNS]),e.supportedLngs&&e.supportedLngs.indexOf("cimode")<0&&(e.supportedLngs=e.supportedLngs.concat(["cimode"])),e}function Ku(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(a){return Object.getOwnPropertyDescriptor(e,a).enumerable})),r.push.apply(r,n)}return r}function De(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Ku(Object(r),!0).forEach(function(n){te(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Ku(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function rL(e){var t=nL();return function(){var n=je(e),a;if(t){var i=je(this).constructor;a=Reflect.construct(n,arguments,i)}else a=n.apply(this,arguments);return Vt(this,a)}}function nL(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function ir(){}function aL(e){var t=Object.getOwnPropertyNames(Object.getPrototypeOf(e));t.forEach(function(r){typeof e[r]=="function"&&(e[r]=e[r].bind(e))})}var br=function(e){Ur(r,e);var t=rL(r);function r(){var n,a=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},i=arguments.length>1?arguments[1]:void 0;if(Ee(this,r),n=t.call(this),Vr&&tt.call(et(n)),n.options=Ju(a),n.services={},n.logger=Be,n.modules={external:[]},aL(et(n)),i&&!n.isInitialized&&!a.isClone){if(!n.options.initImmediate)return n.init(a,i),Vt(n,et(n));setTimeout(function(){n.init(a,i)},0)}return n}return $e(r,[{key:"init",value:function(){var a=this,i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},o=arguments.length>1?arguments[1]:void 0;typeof i=="function"&&(o=i,i={}),!i.defaultNS&&i.defaultNS!==!1&&i.ns&&(typeof i.ns=="string"?i.defaultNS=i.ns:i.ns.indexOf("translation")<0&&(i.defaultNS=i.ns[0]));var s=Yu();this.options=De(De(De({},s),this.options),Ju(i)),this.options.compatibilityAPI!=="v1"&&(this.options.interpolation=De(De({},s.interpolation),this.options.interpolation)),i.keySeparator!==void 0&&(this.options.userDefinedKeySeparator=i.keySeparator),i.nsSeparator!==void 0&&(this.options.userDefinedNsSeparator=i.nsSeparator);function u(y){return y?typeof y=="function"?new y:y:null}if(!this.options.isClone){this.modules.logger?Be.init(u(this.modules.logger),this.options):Be.init(null,this.options);var f;this.modules.formatter?f=this.modules.formatter:typeof Intl<"u"&&(f=JR);var g=new Mu(this.options);this.store=new GR(this.options.resources,this.options);var c=this.services;c.logger=Be,c.resourceStore=this.store,c.languageUtils=g,c.pluralResolver=new ZR(g,{prepend:this.options.pluralSeparator,compatibilityJSON:this.options.compatibilityJSON,simplifyPluralSuffix:this.options.simplifyPluralSuffix}),f&&(!this.options.interpolation.format||this.options.interpolation.format===s.interpolation.format)&&(c.formatter=u(f),c.formatter.init(c,this.options),this.options.interpolation.format=c.formatter.format.bind(c.formatter)),c.interpolator=new qR(this.options),c.utils={hasLoadedNamespace:this.hasLoadedNamespace.bind(this)},c.backendConnector=new tL(u(this.modules.backend),c.resourceStore,c,this.options),c.backendConnector.on("*",function(y){for(var A=arguments.length,x=new Array(A>1?A-1:0),I=1;I<A;I++)x[I-1]=arguments[I];a.emit.apply(a,[y].concat(x))}),this.modules.languageDetector&&(c.languageDetector=u(this.modules.languageDetector),c.languageDetector.init&&c.languageDetector.init(c,this.options.detection,this.options)),this.modules.i18nFormat&&(c.i18nFormat=u(this.modules.i18nFormat),c.i18nFormat.init&&c.i18nFormat.init(this)),this.translator=new Hu(this.services,this.options),this.translator.on("*",function(y){for(var A=arguments.length,x=new Array(A>1?A-1:0),I=1;I<A;I++)x[I-1]=arguments[I];a.emit.apply(a,[y].concat(x))}),this.modules.external.forEach(function(y){y.init&&y.init(a)})}if(this.format=this.options.interpolation.format,o||(o=ir),this.options.fallbackLng&&!this.services.languageDetector&&!this.options.lng){var d=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);d.length>0&&d[0]!=="dev"&&(this.options.lng=d[0])}!this.services.languageDetector&&!this.options.lng&&this.logger.warn("init: no languageDetector is used and no lng is defined");var h=["getResource","hasResourceBundle","getResourceBundle","getDataByLanguage"];h.forEach(function(y){a[y]=function(){var A;return(A=a.store)[y].apply(A,arguments)}});var v=["addResource","addResources","addResourceBundle","removeResourceBundle"];v.forEach(function(y){a[y]=function(){var A;return(A=a.store)[y].apply(A,arguments),a}});var m=Tt(),b=function(){var A=function(I,S){a.isInitialized&&!a.initializedStoreOnce&&a.logger.warn("init: i18next is already initialized. You should call init just once!"),a.isInitialized=!0,a.options.isClone||a.logger.log("initialized",a.options),a.emit("initialized",a.options),m.resolve(S),o(I,S)};if(a.languages&&a.options.compatibilityAPI!=="v1"&&!a.isInitialized)return A(null,a.t.bind(a));a.changeLanguage(a.options.lng,A)};return this.options.resources||!this.options.initImmediate?b():setTimeout(b,0),m}},{key:"loadResources",value:function(a){var i=this,o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:ir,s=o,u=typeof a=="string"?a:this.language;if(typeof a=="function"&&(s=a),!this.options.resources||this.options.partialBundledLanguages){if(u&&u.toLowerCase()==="cimode")return s();var f=[],g=function(h){if(h){var v=i.services.languageUtils.toResolveHierarchy(h);v.forEach(function(m){f.indexOf(m)<0&&f.push(m)})}};if(u)g(u);else{var c=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);c.forEach(function(d){return g(d)})}this.options.preload&&this.options.preload.forEach(function(d){return g(d)}),this.services.backendConnector.load(f,this.options.ns,function(d){!d&&!i.resolvedLanguage&&i.language&&i.setResolvedLanguage(i.language),s(d)})}else s(null)}},{key:"reloadResources",value:function(a,i,o){var s=Tt();return a||(a=this.languages),i||(i=this.options.ns),o||(o=ir),this.services.backendConnector.reload(a,i,function(u){s.resolve(),o(u)}),s}},{key:"use",value:function(a){if(!a)throw new Error("You are passing an undefined module! Please check the object you are passing to i18next.use()");if(!a.type)throw new Error("You are passing a wrong module! Please check the object you are passing to i18next.use()");return a.type==="backend"&&(this.modules.backend=a),(a.type==="logger"||a.log&&a.warn&&a.error)&&(this.modules.logger=a),a.type==="languageDetector"&&(this.modules.languageDetector=a),a.type==="i18nFormat"&&(this.modules.i18nFormat=a),a.type==="postProcessor"&&Tf.addPostProcessor(a),a.type==="formatter"&&(this.modules.formatter=a),a.type==="3rdParty"&&this.modules.external.push(a),this}},{key:"setResolvedLanguage",value:function(a){if(!(!a||!this.languages)&&!(["cimode","dev"].indexOf(a)>-1))for(var i=0;i<this.languages.length;i++){var o=this.languages[i];if(!(["cimode","dev"].indexOf(o)>-1)&&this.store.hasLanguageSomeTranslations(o)){this.resolvedLanguage=o;break}}}},{key:"changeLanguage",value:function(a,i){var o=this;this.isLanguageChangingTo=a;var s=Tt();this.emit("languageChanging",a);var u=function(d){o.language=d,o.languages=o.services.languageUtils.toResolveHierarchy(d),o.resolvedLanguage=void 0,o.setResolvedLanguage(d)},f=function(d,h){h?(u(h),o.translator.changeLanguage(h),o.isLanguageChangingTo=void 0,o.emit("languageChanged",h),o.logger.log("languageChanged",h)):o.isLanguageChangingTo=void 0,s.resolve(function(){return o.t.apply(o,arguments)}),i&&i(d,function(){return o.t.apply(o,arguments)})},g=function(d){!a&&!d&&o.services.languageDetector&&(d=[]);var h=typeof d=="string"?d:o.services.languageUtils.getBestMatchFromCodes(d);h&&(o.language||u(h),o.translator.language||o.translator.changeLanguage(h),o.services.languageDetector&&o.services.languageDetector.cacheUserLanguage&&o.services.languageDetector.cacheUserLanguage(h)),o.loadResources(h,function(v){f(v,h)})};return!a&&this.services.languageDetector&&!this.services.languageDetector.async?g(this.services.languageDetector.detect()):!a&&this.services.languageDetector&&this.services.languageDetector.async?this.services.languageDetector.detect.length===0?this.services.languageDetector.detect().then(g):this.services.languageDetector.detect(g):g(a),s}},{key:"getFixedT",value:function(a,i,o){var s=this,u=function f(g,c){var d;if(Re(c)!=="object"){for(var h=arguments.length,v=new Array(h>2?h-2:0),m=2;m<h;m++)v[m-2]=arguments[m];d=s.options.overloadTranslationOptionHandler([g,c].concat(v))}else d=De({},c);d.lng=d.lng||f.lng,d.lngs=d.lngs||f.lngs,d.ns=d.ns||f.ns,d.keyPrefix=d.keyPrefix||o||f.keyPrefix;var b=s.options.keySeparator||".",y;return d.keyPrefix&&Array.isArray(g)?y=g.map(function(A){return"".concat(d.keyPrefix).concat(b).concat(A)}):y=d.keyPrefix?"".concat(d.keyPrefix).concat(b).concat(g):g,s.t(y,d)};return typeof a=="string"?u.lng=a:u.lngs=a,u.ns=i,u.keyPrefix=o,u}},{key:"t",value:function(){var a;return this.translator&&(a=this.translator).translate.apply(a,arguments)}},{key:"exists",value:function(){var a;return this.translator&&(a=this.translator).exists.apply(a,arguments)}},{key:"setDefaultNamespace",value:function(a){this.options.defaultNS=a}},{key:"hasLoadedNamespace",value:function(a){var i=this,o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(!this.isInitialized)return this.logger.warn("hasLoadedNamespace: i18next was not initialized",this.languages),!1;if(!this.languages||!this.languages.length)return this.logger.warn("hasLoadedNamespace: i18n.languages were undefined or empty",this.languages),!1;var s=this.resolvedLanguage||this.languages[0],u=this.options?this.options.fallbackLng:!1,f=this.languages[this.languages.length-1];if(s.toLowerCase()==="cimode")return!0;var g=function(h,v){var m=i.services.backendConnector.state["".concat(h,"|").concat(v)];return m===-1||m===2};if(o.precheck){var c=o.precheck(this,g);if(c!==void 0)return c}return!!(this.hasResourceBundle(s,a)||!this.services.backendConnector.backend||this.options.resources&&!this.options.partialBundledLanguages||g(s,a)&&(!u||g(f,a)))}},{key:"loadNamespaces",value:function(a,i){var o=this,s=Tt();return this.options.ns?(typeof a=="string"&&(a=[a]),a.forEach(function(u){o.options.ns.indexOf(u)<0&&o.options.ns.push(u)}),this.loadResources(function(u){s.resolve(),i&&i(u)}),s):(i&&i(),Promise.resolve())}},{key:"loadLanguages",value:function(a,i){var o=Tt();typeof a=="string"&&(a=[a]);var s=this.options.preload||[],u=a.filter(function(f){return s.indexOf(f)<0});return u.length?(this.options.preload=s.concat(u),this.loadResources(function(f){o.resolve(),i&&i(f)}),o):(i&&i(),Promise.resolve())}},{key:"dir",value:function(a){if(a||(a=this.resolvedLanguage||(this.languages&&this.languages.length>0?this.languages[0]:this.language)),!a)return"rtl";var i=["ar","shu","sqr","ssh","xaa","yhd","yud","aao","abh","abv","acm","acq","acw","acx","acy","adf","ads","aeb","aec","afb","ajp","apc","apd","arb","arq","ars","ary","arz","auz","avl","ayh","ayl","ayn","ayp","bbz","pga","he","iw","ps","pbt","pbu","pst","prp","prd","ug","ur","ydd","yds","yih","ji","yi","hbo","men","xmn","fa","jpr","peo","pes","prs","dv","sam","ckb"],o=this.services&&this.services.languageUtils||new Mu(Yu());return i.indexOf(o.getLanguagePartFromCode(a))>-1||a.toLowerCase().indexOf("-arab")>1?"rtl":"ltr"}},{key:"cloneInstance",value:function(){var a=this,i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:ir,s=De(De(De({},this.options),i),{isClone:!0}),u=new r(s);(i.debug!==void 0||i.prefix!==void 0)&&(u.logger=u.logger.clone(i));var f=["store","services","language"];return f.forEach(function(g){u[g]=a[g]}),u.services=De({},this.services),u.services.utils={hasLoadedNamespace:u.hasLoadedNamespace.bind(u)},u.translator=new Hu(u.services,u.options),u.translator.on("*",function(g){for(var c=arguments.length,d=new Array(c>1?c-1:0),h=1;h<c;h++)d[h-1]=arguments[h];u.emit.apply(u,[g].concat(d))}),u.init(s,o),u.translator.options=u.options,u.translator.backendConnector.services.utils={hasLoadedNamespace:u.hasLoadedNamespace.bind(u)},u}},{key:"toJSON",value:function(){return{options:this.options,store:this.store,language:this.language,languages:this.languages,resolvedLanguage:this.resolvedLanguage}}}]),r}(tt);te(br,"createInstance",function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;return new br(e,t)});var ce=br.createInstance();ce.createInstance=br.createInstance;ce.createInstance;ce.dir;ce.init;ce.loadResources;ce.reloadResources;ce.use;ce.changeLanguage;ce.getFixedT;ce.t;ce.exists;ce.setDefaultNamespace;ce.hasLoadedNamespace;ce.loadNamespaces;ce.loadLanguages;var Ef=[],iL=Ef.forEach,oL=Ef.slice;function sL(e){return iL.call(oL.call(arguments,1),function(t){if(t)for(var r in t)e[r]===void 0&&(e[r]=t[r])}),e}var Qu=/^[\u0009\u0020-\u007e\u0080-\u00ff]+$/,uL=function(t,r,n){var a=n||{};a.path=a.path||"/";var i=encodeURIComponent(r),o="".concat(t,"=").concat(i);if(a.maxAge>0){var s=a.maxAge-0;if(Number.isNaN(s))throw new Error("maxAge should be a Number");o+="; Max-Age=".concat(Math.floor(s))}if(a.domain){if(!Qu.test(a.domain))throw new TypeError("option domain is invalid");o+="; Domain=".concat(a.domain)}if(a.path){if(!Qu.test(a.path))throw new TypeError("option path is invalid");o+="; Path=".concat(a.path)}if(a.expires){if(typeof a.expires.toUTCString!="function")throw new TypeError("option expires is invalid");o+="; Expires=".concat(a.expires.toUTCString())}if(a.httpOnly&&(o+="; HttpOnly"),a.secure&&(o+="; Secure"),a.sameSite){var u=typeof a.sameSite=="string"?a.sameSite.toLowerCase():a.sameSite;switch(u){case!0:o+="; SameSite=Strict";break;case"lax":o+="; SameSite=Lax";break;case"strict":o+="; SameSite=Strict";break;case"none":o+="; SameSite=None";break;default:throw new TypeError("option sameSite is invalid")}}return o},ec={create:function(t,r,n,a){var i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:{path:"/",sameSite:"strict"};n&&(i.expires=new Date,i.expires.setTime(i.expires.getTime()+n*60*1e3)),a&&(i.domain=a),document.cookie=uL(t,encodeURIComponent(r),i)},read:function(t){for(var r="".concat(t,"="),n=document.cookie.split(";"),a=0;a<n.length;a++){for(var i=n[a];i.charAt(0)===" ";)i=i.substring(1,i.length);if(i.indexOf(r)===0)return i.substring(r.length,i.length)}return null},remove:function(t){this.create(t,"",-1)}},cL={name:"cookie",lookup:function(t){var r;if(t.lookupCookie&&typeof document<"u"){var n=ec.read(t.lookupCookie);n&&(r=n)}return r},cacheUserLanguage:function(t,r){r.lookupCookie&&typeof document<"u"&&ec.create(r.lookupCookie,t,r.cookieMinutes,r.cookieDomain,r.cookieOptions)}},lL={name:"querystring",lookup:function(t){var r;if(typeof window<"u"){var n=window.location.search;!window.location.search&&window.location.hash&&window.location.hash.indexOf("?")>-1&&(n=window.location.hash.substring(window.location.hash.indexOf("?")));for(var a=n.substring(1),i=a.split("&"),o=0;o<i.length;o++){var s=i[o].indexOf("=");if(s>0){var u=i[o].substring(0,s);u===t.lookupQuerystring&&(r=i[o].substring(s+1))}}}return r}},Et=null,tc=function(){if(Et!==null)return Et;try{Et=window!=="undefined"&&window.localStorage!==null;var t="i18next.translate.boo";window.localStorage.setItem(t,"foo"),window.localStorage.removeItem(t)}catch{Et=!1}return Et},fL={name:"localStorage",lookup:function(t){var r;if(t.lookupLocalStorage&&tc()){var n=window.localStorage.getItem(t.lookupLocalStorage);n&&(r=n)}return r},cacheUserLanguage:function(t,r){r.lookupLocalStorage&&tc()&&window.localStorage.setItem(r.lookupLocalStorage,t)}},$t=null,rc=function(){if($t!==null)return $t;try{$t=window!=="undefined"&&window.sessionStorage!==null;var t="i18next.translate.boo";window.sessionStorage.setItem(t,"foo"),window.sessionStorage.removeItem(t)}catch{$t=!1}return $t},gL={name:"sessionStorage",lookup:function(t){var r;if(t.lookupSessionStorage&&rc()){var n=window.sessionStorage.getItem(t.lookupSessionStorage);n&&(r=n)}return r},cacheUserLanguage:function(t,r){r.lookupSessionStorage&&rc()&&window.sessionStorage.setItem(r.lookupSessionStorage,t)}},pL={name:"navigator",lookup:function(t){var r=[];if(typeof navigator<"u"){if(navigator.languages)for(var n=0;n<navigator.languages.length;n++)r.push(navigator.languages[n]);navigator.userLanguage&&r.push(navigator.userLanguage),navigator.language&&r.push(navigator.language)}return r.length>0?r:void 0}},dL={name:"htmlTag",lookup:function(t){var r,n=t.htmlTag||(typeof document<"u"?document.documentElement:null);return n&&typeof n.getAttribute=="function"&&(r=n.getAttribute("lang")),r}},hL={name:"path",lookup:function(t){var r;if(typeof window<"u"){var n=window.location.pathname.match(/\/([a-zA-Z-]*)/g);if(n instanceof Array)if(typeof t.lookupFromPathIndex=="number"){if(typeof n[t.lookupFromPathIndex]!="string")return;r=n[t.lookupFromPathIndex].replace("/","")}else r=n[0].replace("/","")}return r}},yL={name:"subdomain",lookup:function(t){var r=typeof t.lookupFromSubdomainIndex=="number"?t.lookupFromSubdomainIndex+1:1,n=typeof window<"u"&&window.location&&window.location.hostname&&window.location.hostname.match(/^(\w{2,5})\.(([a-z0-9-]{1,63}\.[a-z]{2,6})|localhost)/i);if(n)return n[r]}};function vL(){return{order:["querystring","cookie","localStorage","sessionStorage","navigator","htmlTag"],lookupQuerystring:"lng",lookupCookie:"i18next",lookupLocalStorage:"i18nextLng",lookupSessionStorage:"i18nextLng",caches:["localStorage"],excludeCacheFor:["cimode"]}}var $f=function(){function e(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};Ee(this,e),this.type="languageDetector",this.detectors={},this.init(t,r)}return $e(e,[{key:"init",value:function(r){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};this.services=r,this.options=sL(n,this.options||{},vL()),this.options.lookupFromUrlIndex&&(this.options.lookupFromPathIndex=this.options.lookupFromUrlIndex),this.i18nOptions=a,this.addDetector(cL),this.addDetector(lL),this.addDetector(fL),this.addDetector(gL),this.addDetector(pL),this.addDetector(dL),this.addDetector(hL),this.addDetector(yL)}},{key:"addDetector",value:function(r){this.detectors[r.name]=r}},{key:"detect",value:function(r){var n=this;r||(r=this.options.order);var a=[];return r.forEach(function(i){if(n.detectors[i]){var o=n.detectors[i].lookup(n.options);o&&typeof o=="string"&&(o=[o]),o&&(a=a.concat(o))}}),this.services.languageUtils.getBestMatchFromCodes?a:a.length>0?a[0]:null}},{key:"cacheUserLanguage",value:function(r,n){var a=this;n||(n=this.options.caches),n&&(this.options.excludeCacheFor&&this.options.excludeCacheFor.indexOf(r)>-1||n.forEach(function(i){a.detectors[i]&&a.detectors[i].cacheUserLanguage(r,a.options)}))}}]),e}();$f.type="languageDetector";const Pf=({resources:e})=>Q.useMemo(()=>ce.createInstance({defaultNS:"common",fallbackLng:"en",fallbackNS:"common",load:"languageOnly",ns:["common"],overloadTranslationOptionHandler:t=>({defaultValue:t[1]}),react:{useSuspense:!1},resources:e,supportedLngs:e?Object.keys(e):[]},t=>{if(t)return console.error(t)}).use($f),[e]),Ff=lc(e=>{const t=`.${e}`;return pc({key:"css",stylisPlugins:[n=>{n?.type==="rule"&&n?.value.startsWith(".css")&&(n.props=[n.props].flat().map(a=>a.includes(t)?a:`${t} ${a}`))},fp]})}),Df=({children:e,css:t,fallback:r,resources:n})=>{const{scope:a,onError:i}=Of(),o=Pf({resources:n});return ve("div",{className:a,css:t,children:ve(Pt.CacheProvider,{value:Ff(a),children:ve(Ug.I18nextProvider,{i18n:o,children:ve(wf,{fallback:r,onError:i,children:e})})})})},CL=(e,t)=>{const r=e??{};return t&&Object.entries(r).forEach(([n,a])=>{Object.entries(a).forEach(([i,o])=>{r[n][i]={...r[n]?.[i],...o}})}),r},AL=(e,t,r)=>({resources:n,...a})=>ve(Df,{resources:CL(r?.resources,n),fallback:t,children:ve(e,{...a})}),bL={createElement:AL};exports.Alchemy=xR;exports.AlchemyContext=wi;exports.Element=Df;exports.ErrorBoundary=wf;exports.default=bL;exports.memoizedCreateCache=Ff;exports.useAlchemy=Of;exports.useI18n=Pf;exports.useLoadFonts=cf;exports.useLoadIcons=_f;exports.useLoadTheme=xf;Object.keys(st).forEach(e=>{e!=="default"&&!exports.hasOwnProperty(e)&&Object.defineProperty(exports,e,{enumerable:!0,get:()=>st[e]})});
package/index.mjs CHANGED
@@ -7394,7 +7394,7 @@ const Ua = /* @__PURE__ */ wp(Xa), LR = ({ brandName: e, cdnURL: t }) => {
7394
7394
  }
7395
7395
  })();
7396
7396
  }, [t, e]), r;
7397
- }, wf = vr(void 0), FL = ({
7397
+ }, wf = vr(void 0), DL = ({
7398
7398
  baseURL: e = "https://api.shipengine.com",
7399
7399
  brandName: t = Or.BrandName.FALLBACK,
7400
7400
  cdnURL: r = "https://cdn.packlink.com",
@@ -9707,28 +9707,33 @@ const xL = ({ resources: e }) => Ug(() => ue.createInstance(
9707
9707
  n?.type === "rule" && n?.value.startsWith(".css") && (n.props = [n.props].flat().map((a) => a.includes(t) ? a : `${t} ${a}`));
9708
9708
  }, dp]
9709
9709
  });
9710
- }), wL = ({ children: e, fallback: t, resources: r }) => {
9711
- const { scope: n, onError: a } = ER(), i = xL({ resources: r });
9712
- return /* @__PURE__ */ ye("div", { className: n, children: /* @__PURE__ */ ye(Zg, { value: OL(n), children: /* @__PURE__ */ ye(Yg, { i18n: i, children: /* @__PURE__ */ ye($R, { fallback: t, onError: a, children: e }) }) }) });
9713
- }, RL = (e, t, r) => ({ resources: n, ...a }) => {
9714
- const i = r;
9715
- return n && Object.keys(r).forEach((o) => {
9716
- Object.keys(r[o]).forEach((s) => {
9717
- i[o][s] = {
9718
- ...i[o][s],
9719
- ...n[o]?.[s]
9710
+ }), wL = ({
9711
+ children: e,
9712
+ css: t,
9713
+ fallback: r,
9714
+ resources: n
9715
+ }) => {
9716
+ const { scope: a, onError: i } = ER(), o = xL({ resources: n });
9717
+ return /* @__PURE__ */ ye("div", { className: a, css: t, children: /* @__PURE__ */ ye(Zg, { value: OL(a), children: /* @__PURE__ */ ye(Yg, { i18n: o, children: /* @__PURE__ */ ye($R, { fallback: r, onError: i, children: e }) }) }) });
9718
+ }, RL = (e, t) => {
9719
+ const r = e ?? {};
9720
+ return t && Object.entries(r).forEach(([n, a]) => {
9721
+ Object.entries(a).forEach(([i, o]) => {
9722
+ r[n][i] = {
9723
+ ...r[n]?.[i],
9724
+ ...o
9720
9725
  };
9721
9726
  });
9722
- }), /* @__PURE__ */ ye(wL, { resources: i, fallback: t, children: /* @__PURE__ */ ye(e, { ...a }) });
9723
- }, DL = {
9724
- createElement: RL
9727
+ }), r;
9728
+ }, LL = (e, t, r) => ({ resources: n, ...a }) => /* @__PURE__ */ ye(wL, { resources: RL(r?.resources, n), fallback: t, children: /* @__PURE__ */ ye(e, { ...a }) }), kL = {
9729
+ createElement: LL
9725
9730
  };
9726
9731
  export {
9727
- FL as Alchemy,
9732
+ DL as Alchemy,
9728
9733
  wf as AlchemyContext,
9729
9734
  wL as Element,
9730
9735
  $R as ErrorBoundary,
9731
- DL as default,
9736
+ kL as default,
9732
9737
  OL as memoizedCreateCache,
9733
9738
  ER as useAlchemy,
9734
9739
  xL as useI18n,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@shipengine/alchemy",
3
- "version": "0.3.7",
3
+ "version": "0.4.0",
4
4
  "main": "./index.js",
5
5
  "types": "./index.d.ts",
6
6
  "exports": {