iBet uBet web content aggregator. Adding the entire web to your favor.
iBet uBet web content aggregator. Adding the entire web to your favor.



Link to original content: http://www.statista.com/accounts/build/entry.client-HHFRWWJ3.js
import{a as De,c as $e}from"/accounts/build/_shared/chunk-7N3GWXXL.js";import{a as Lt,b as Pt,q as Ie,s as Fe}from"/accounts/build/_shared/chunk-2OSNKVOL.js";import{a as je,c as ye,d as Q}from"/accounts/build/_shared/chunk-GOPQ4PBN.js";var nt=ye((F,tt)=>{var ue=typeof globalThis<"u"&&globalThis||typeof self<"u"&&self||typeof globalThis<"u"&&globalThis,fe=function(){function i(){this.fetch=!1,this.DOMException=ue.DOMException}return i.prototype=ue,new i}();(function(i){var e=function(t){var n=typeof i<"u"&&i||typeof self<"u"&&self||typeof n<"u"&&n,r={searchParams:"URLSearchParams"in n,iterable:"Symbol"in n&&"iterator"in Symbol,blob:"FileReader"in n&&"Blob"in n&&function(){try{return new Blob,!0}catch{return!1}}(),formData:"FormData"in n,arrayBuffer:"ArrayBuffer"in n};function s(u){return u&&DataView.prototype.isPrototypeOf(u)}if(r.arrayBuffer)var o=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],a=ArrayBuffer.isView||function(u){return u&&o.indexOf(Object.prototype.toString.call(u))>-1};function l(u){if(typeof u!="string"&&(u=String(u)),/[^a-z0-9\-#$%&'*+.^_`|~!]/i.test(u)||u==="")throw new TypeError('Invalid character in header field name: "'+u+'"');return u.toLowerCase()}function c(u){return typeof u!="string"&&(u=String(u)),u}function d(u){var p={next:function(){var y=u.shift();return{done:y===void 0,value:y}}};return r.iterable&&(p[Symbol.iterator]=function(){return p}),p}function h(u){this.map={},u instanceof h?u.forEach(function(p,y){this.append(y,p)},this):Array.isArray(u)?u.forEach(function(p){this.append(p[0],p[1])},this):u&&Object.getOwnPropertyNames(u).forEach(function(p){this.append(p,u[p])},this)}h.prototype.append=function(u,p){u=l(u),p=c(p);var y=this.map[u];this.map[u]=y?y+", "+p:p},h.prototype.delete=function(u){delete this.map[l(u)]},h.prototype.get=function(u){return u=l(u),this.has(u)?this.map[u]:null},h.prototype.has=function(u){return this.map.hasOwnProperty(l(u))},h.prototype.set=function(u,p){this.map[l(u)]=c(p)},h.prototype.forEach=function(u,p){for(var y in this.map)this.map.hasOwnProperty(y)&&u.call(p,this.map[y],y,this)},h.prototype.keys=function(){var u=[];return this.forEach(function(p,y){u.push(y)}),d(u)},h.prototype.values=function(){var u=[];return this.forEach(function(p){u.push(p)}),d(u)},h.prototype.entries=function(){var u=[];return this.forEach(function(p,y){u.push([y,p])}),d(u)},r.iterable&&(h.prototype[Symbol.iterator]=h.prototype.entries);function f(u){if(u.bodyUsed)return Promise.reject(new TypeError("Already read"));u.bodyUsed=!0}function g(u){return new Promise(function(p,y){u.onload=function(){p(u.result)},u.onerror=function(){y(u.error)}})}function b(u){var p=new FileReader,y=g(p);return p.readAsArrayBuffer(u),y}function S(u){var p=new FileReader,y=g(p);return p.readAsText(u),y}function w(u){for(var p=new Uint8Array(u),y=new Array(p.length),x=0;x-1?p:u}function P(u,p){if(!(this instanceof P))throw new TypeError('Please use the "new" operator, this DOM object constructor cannot be called as a function.');p=p||{};var y=p.body;if(u instanceof P){if(u.bodyUsed)throw new TypeError("Already read");this.url=u.url,this.credentials=u.credentials,p.headers||(this.headers=new h(u.headers)),this.method=u.method,this.mode=u.mode,this.signal=u.signal,!y&&u._bodyInit!=null&&(y=u._bodyInit,u.bodyUsed=!0)}else this.url=String(u);if(this.credentials=p.credentials||this.credentials||"same-origin",(p.headers||!this.headers)&&(this.headers=new h(p.headers)),this.method=L(p.method||this.method||"GET"),this.mode=p.mode||this.mode||null,this.signal=p.signal||this.signal,this.referrer=null,(this.method==="GET"||this.method==="HEAD")&&y)throw new TypeError("Body not allowed for GET or HEAD requests");if(this._initBody(y),(this.method==="GET"||this.method==="HEAD")&&(p.cache==="no-store"||p.cache==="no-cache")){var x=/([?&])_=[^&]*/;if(x.test(this.url))this.url=this.url.replace(x,"$1_="+new Date().getTime());else{var O=/\?/;this.url+=(O.test(this.url)?"&":"?")+"_="+new Date().getTime()}}}P.prototype.clone=function(){return new P(this,{body:this._bodyInit})};function j(u){var p=new FormData;return u.trim().split("&").forEach(function(y){if(y){var x=y.split("="),O=x.shift().replace(/\+/g," "),v=x.join("=").replace(/\+/g," ");p.append(decodeURIComponent(O),decodeURIComponent(v))}}),p}function k(u){var p=new h,y=u.replace(/\r?\n[\t ]+/g," ");return y.split("\r").map(function(x){return x.indexOf(` `)===0?x.substr(1,x.length):x}).forEach(function(x){var O=x.split(":"),v=O.shift().trim();if(v){var M=O.join(":").trim();p.append(v,M)}}),p}C.call(P.prototype);function A(u,p){if(!(this instanceof A))throw new TypeError('Please use the "new" operator, this DOM object constructor cannot be called as a function.');p||(p={}),this.type="default",this.status=p.status===void 0?200:p.status,this.ok=this.status>=200&&this.status<300,this.statusText=p.statusText===void 0?"":""+p.statusText,this.headers=new h(p.headers),this.url=p.url||"",this._initBody(u)}C.call(A.prototype),A.prototype.clone=function(){return new A(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new h(this.headers),url:this.url})},A.error=function(){var u=new A(null,{status:0,statusText:""});return u.type="error",u};var me=[301,302,303,307,308];A.redirect=function(u,p){if(me.indexOf(p)===-1)throw new RangeError("Invalid status code");return new A(null,{status:p,headers:{location:u}})},t.DOMException=n.DOMException;try{new t.DOMException}catch{t.DOMException=function(p,y){this.message=p,this.name=y;var x=Error(p);this.stack=x.stack},t.DOMException.prototype=Object.create(Error.prototype),t.DOMException.prototype.constructor=t.DOMException}function V(u,p){return new Promise(function(y,x){var O=new P(u,p);if(O.signal&&O.signal.aborted)return x(new t.DOMException("Aborted","AbortError"));var v=new XMLHttpRequest;function M(){v.abort()}v.onload=function(){var R={status:v.status,statusText:v.statusText,headers:k(v.getAllResponseHeaders()||"")};R.url="responseURL"in v?v.responseURL:R.headers.get("X-Request-URL");var D="response"in v?v.response:v.responseText;setTimeout(function(){y(new A(D,R))},0)},v.onerror=function(){setTimeout(function(){x(new TypeError("Network request failed"))},0)},v.ontimeout=function(){setTimeout(function(){x(new TypeError("Network request failed"))},0)},v.onabort=function(){setTimeout(function(){x(new t.DOMException("Aborted","AbortError"))},0)};function T(R){try{return R===""&&n.location.href?n.location.href:R}catch{return R}}v.open(O.method,T(O.url),!0),O.credentials==="include"?v.withCredentials=!0:O.credentials==="omit"&&(v.withCredentials=!1),"responseType"in v&&(r.blob?v.responseType="blob":r.arrayBuffer&&O.headers.get("Content-Type")&&O.headers.get("Content-Type").indexOf("application/octet-stream")!==-1&&(v.responseType="arraybuffer")),p&&typeof p.headers=="object"&&!(p.headers instanceof h)?Object.getOwnPropertyNames(p.headers).forEach(function(R){v.setRequestHeader(R,c(p.headers[R]))}):O.headers.forEach(function(R,D){v.setRequestHeader(D,R)}),O.signal&&(O.signal.addEventListener("abort",M),v.onreadystatechange=function(){v.readyState===4&&O.signal.removeEventListener("abort",M)}),v.send(typeof O._bodyInit>"u"?null:O._bodyInit)})}return V.polyfill=!0,n.fetch||(n.fetch=V,n.Headers=h,n.Request=P,n.Response=A),t.Headers=h,t.Request=P,t.Response=A,t.fetch=V,t}({})})(fe);fe.fetch.ponyfill=!0;delete fe.fetch.polyfill;var X=ue.fetch?ue:fe;F=X.fetch;F.default=X.fetch;F.fetch=X.fetch;F.Headers=X.Headers;F.Request=X.Request;F.Response=X.Response;tt.exports=F});var rt=ye((Ee,it)=>{var ce;typeof fetch=="function"&&(typeof globalThis<"u"&&globalThis.fetch?ce=globalThis.fetch:typeof window<"u"&&window.fetch?ce=window.fetch:ce=fetch);typeof je<"u"&&typeof window>"u"&&(ne=ce||nt(),ne.default&&(ne=ne.default),Ee.default=ne,it.exports=Ee.default);var ne});var vt=ye(Ae=>{"use strict";var bt=Pt();Ae.createRoot=bt.createRoot,Ae.hydrateRoot=bt.hydrateRoot;var Jn});var m=i=>typeof i=="string",G=()=>{let i,e,t=new Promise((n,r)=>{i=n,e=r});return t.resolve=i,t.reject=e,t},Ue=i=>i==null?"":""+i,Rt=(i,e,t)=>{i.forEach(n=>{e[n]&&(t[n]=e[n])})},Ct=/###/g,Me=i=>i&&i.indexOf("###")>-1?i.replace(Ct,"."):i,Be=i=>!i||m(i),Y=(i,e,t)=>{let n=m(e)?e.split("."):e,r=0;for(;r{let{obj:n,k:r}=Y(i,e,Object);if(n!==void 0||e.length===1){n[r]=t;return}let s=e[e.length-1],o=e.slice(0,e.length-1),a=Y(i,o,Object);for(;a.obj===void 0&&o.length;)s=`${o[o.length-1]}.${s}`,o=o.slice(0,o.length-1),a=Y(i,o,Object),a&&a.obj&&typeof a.obj[`${a.k}.${s}`]<"u"&&(a.obj=void 0);a.obj[`${a.k}.${s}`]=t},Et=(i,e,t,n)=>{let{obj:r,k:s}=Y(i,e,Object);r[s]=r[s]||[],r[s].push(t)},se=(i,e)=>{let{obj:t,k:n}=Y(i,e);if(t)return t[n]},kt=(i,e,t)=>{let n=se(i,t);return n!==void 0?n:se(e,t)},Je=(i,e,t)=>{for(let n in e)n!=="__proto__"&&n!=="constructor"&&(n in i?m(i[n])||i[n]instanceof String||m(e[n])||e[n]instanceof String?t&&(i[n]=e[n]):Je(i[n],e[n],t):i[n]=e[n]);return i},_=i=>i.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&"),Nt={"&":"&","<":"<",">":">",'"':""","'":"'","/":"/"},At=i=>m(i)?i.replace(/[&<>"'\/]/g,e=>Nt[e]):i,we=class{constructor(e){this.capacity=e,this.regExpMap=new Map,this.regExpQueue=[]}getRegExp(e){let t=this.regExpMap.get(e);if(t!==void 0)return t;let n=new RegExp(e);return this.regExpQueue.length===this.capacity&&this.regExpMap.delete(this.regExpQueue.shift()),this.regExpMap.set(e,n),this.regExpQueue.push(e),n}},Tt=[" ",",","?","!",";"],jt=new we(20),Dt=(i,e,t)=>{e=e||"",t=t||"";let n=Tt.filter(o=>e.indexOf(o)<0&&t.indexOf(o)<0);if(n.length===0)return!0;let r=jt.getRegExp(`(${n.map(o=>o==="?"?"\\?":o).join("|")})`),s=!r.test(i);if(!s){let o=i.indexOf(t);o>0&&!r.test(i.substring(0,o))&&(s=!0)}return s},xe=function(i,e){let t=arguments.length>2&&arguments[2]!==void 0?arguments[2]:".";if(!i)return;if(i[e])return i[e];let n=e.split(t),r=i;for(let s=0;s-1&&li&&i.replace("_","-"),$t={type:"logger",log(i){this.output("log",i)},warn(i){this.output("warn",i)},error(i){this.output("error",i)},output(i,e){console&&console[i]&&console[i].apply(console,e)}},K=class{constructor(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.init(e,t)}init(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.prefix=t.prefix||"i18next:",this.logger=e||$t,this.options=t,this.debug=t.debug}log(){for(var e=arguments.length,t=new Array(e),n=0;n{this.observers[n]||(this.observers[n]=new Map);let r=this.observers[n].get(t)||0;this.observers[n].set(t,r+1)}),this}off(e,t){if(this.observers[e]){if(!t){delete this.observers[e];return}this.observers[e].delete(t)}}emit(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r{let[a,l]=o;for(let c=0;c{let[a,l]=o;for(let c=0;c1&&arguments[1]!==void 0?arguments[1]:{ns:["translation"],defaultNS:"translation"};super(),this.data=e||{},this.options=t,this.options.keySeparator===void 0&&(this.options.keySeparator="."),this.options.ignoreJSONStructure===void 0&&(this.options.ignoreJSONStructure=!0)}addNamespaces(e){this.options.ns.indexOf(e)<0&&this.options.ns.push(e)}removeNamespaces(e){let t=this.options.ns.indexOf(e);t>-1&&this.options.ns.splice(t,1)}getResource(e,t,n){let r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},s=r.keySeparator!==void 0?r.keySeparator:this.options.keySeparator,o=r.ignoreJSONStructure!==void 0?r.ignoreJSONStructure:this.options.ignoreJSONStructure,a;e.indexOf(".")>-1?a=e.split("."):(a=[e,t],n&&(Array.isArray(n)?a.push(...n):m(n)&&s?a.push(...n.split(s)):a.push(n)));let l=se(this.data,a);return!l&&!t&&!n&&e.indexOf(".")>-1&&(e=a[0],t=a[1],n=a.slice(2).join(".")),l||!o||!m(n)?l:xe(this.data&&this.data[e]&&this.data[e][t],n,s)}addResource(e,t,n,r){let s=arguments.length>4&&arguments[4]!==void 0?arguments[4]:{silent:!1},o=s.keySeparator!==void 0?s.keySeparator:this.options.keySeparator,a=[e,t];n&&(a=a.concat(o?n.split(o):n)),e.indexOf(".")>-1&&(a=e.split("."),r=t,t=a[1]),this.addNamespaces(t),He(this.data,a,r),s.silent||this.emit("added",e,t,n,r)}addResources(e,t,n){let r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{silent:!1};for(let s in n)(m(n[s])||Array.isArray(n[s]))&&this.addResource(e,t,s,n[s],{silent:!0});r.silent||this.emit("added",e,t,n)}addResourceBundle(e,t,n,r,s){let o=arguments.length>5&&arguments[5]!==void 0?arguments[5]:{silent:!1,skipCopy:!1},a=[e,t];e.indexOf(".")>-1&&(a=e.split("."),r=n,n=t,t=a[1]),this.addNamespaces(t);let l=se(this.data,a)||{};o.skipCopy||(n=JSON.parse(JSON.stringify(n))),r?Je(l,n,s):l={...l,...n},He(this.data,a,l),o.silent||this.emit("added",e,t,n)}removeResourceBundle(e,t){this.hasResourceBundle(e,t)&&delete this.data[e][t],this.removeNamespaces(t),this.emit("removed",e,t)}hasResourceBundle(e,t){return this.getResource(e,t)!==void 0}getResourceBundle(e,t){return t||(t=this.options.defaultNS),this.options.compatibilityAPI==="v1"?{...this.getResource(e,t)}:this.getResource(e,t)}getDataByLanguage(e){return this.data[e]}hasLanguageSomeTranslations(e){let t=this.getDataByLanguage(e);return!!(t&&Object.keys(t)||[]).find(r=>t[r]&&Object.keys(t[r]).length>0)}toJSON(){return this.data}},Xe={processors:{},addPostProcessor(i){this.processors[i.name]=i},handle(i,e,t,n,r){return i.forEach(s=>{this.processors[s]&&(e=this.processors[s].process(e,t,n,r))}),e}},Ve={},J=class extends z{constructor(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};super(),Rt(["resourceStore","languageUtils","pluralResolver","interpolator","backendConnector","i18nFormat","utils"],e,this),this.options=t,this.options.keySeparator===void 0&&(this.options.keySeparator="."),this.logger=$.create("translator")}changeLanguage(e){e&&(this.language=e)}exists(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{interpolation:{}};if(e==null)return!1;let n=this.resolve(e,t);return n&&n.res!==void 0}extractFromKey(e,t){let n=t.nsSeparator!==void 0?t.nsSeparator:this.options.nsSeparator;n===void 0&&(n=":");let r=t.keySeparator!==void 0?t.keySeparator:this.options.keySeparator,s=t.ns||this.options.defaultNS||[],o=n&&e.indexOf(n)>-1,a=!this.options.userDefinedKeySeparator&&!t.keySeparator&&!this.options.userDefinedNsSeparator&&!t.nsSeparator&&!Dt(e,n,r);if(o&&!a){let l=e.match(this.interpolator.nestingRegexp);if(l&&l.length>0)return{key:e,namespaces:s};let c=e.split(n);(n!==r||n===r&&this.options.ns.indexOf(c[0])>-1)&&(s=c.shift()),e=c.join(r)}return m(s)&&(s=[s]),{key:e,namespaces:s}}translate(e,t,n){if(typeof t!="object"&&this.options.overloadTranslationOptionHandler&&(t=this.options.overloadTranslationOptionHandler(arguments)),typeof t=="object"&&(t={...t}),t||(t={}),e==null)return"";Array.isArray(e)||(e=[String(e)]);let r=t.returnDetails!==void 0?t.returnDetails:this.options.returnDetails,s=t.keySeparator!==void 0?t.keySeparator:this.options.keySeparator,{key:o,namespaces:a}=this.extractFromKey(e[e.length-1],t),l=a[a.length-1],c=t.lng||this.language,d=t.appendNamespaceToCIMode||this.options.appendNamespaceToCIMode;if(c&&c.toLowerCase()==="cimode"){if(d){let L=t.nsSeparator||this.options.nsSeparator;return r?{res:`${l}${L}${o}`,usedKey:o,exactUsedKey:o,usedLng:c,usedNS:l,usedParams:this.getUsedParamsDetails(t)}:`${l}${L}${o}`}return r?{res:o,usedKey:o,exactUsedKey:o,usedLng:c,usedNS:l,usedParams:this.getUsedParamsDetails(t)}:o}let h=this.resolve(e,t),f=h&&h.res,g=h&&h.usedKey||o,b=h&&h.exactUsedKey||o,S=Object.prototype.toString.apply(f),w=["[object Number]","[object Function]","[object RegExp]"],N=t.joinArrays!==void 0?t.joinArrays:this.options.joinArrays,C=!this.i18nFormat||this.i18nFormat.handleAsObject,U=!m(f)&&typeof f!="boolean"&&typeof f!="number";if(C&&f&&U&&w.indexOf(S)<0&&!(m(N)&&Array.isArray(f))){if(!t.returnObjects&&!this.options.returnObjects){this.options.returnedObjectHandler||this.logger.warn("accessing an object - but returnObjects options is not enabled!");let L=this.options.returnedObjectHandler?this.options.returnedObjectHandler(g,f,{...t,ns:a}):`key '${o} (${this.language})' returned an object instead of string.`;return r?(h.res=L,h.usedParams=this.getUsedParamsDetails(t),h):L}if(s){let L=Array.isArray(f),P=L?[]:{},j=L?b:g;for(let k in f)if(Object.prototype.hasOwnProperty.call(f,k)){let A=`${j}${s}${k}`;P[k]=this.translate(A,{...t,joinArrays:!1,ns:a}),P[k]===A&&(P[k]=f[k])}f=P}}else if(C&&m(N)&&Array.isArray(f))f=f.join(N),f&&(f=this.extendTranslation(f,e,t,n));else{let L=!1,P=!1,j=t.count!==void 0&&!m(t.count),k=J.hasDefaultValue(t),A=j?this.pluralResolver.getSuffix(c,t.count,t):"",me=t.ordinal&&j?this.pluralResolver.getSuffix(c,t.count,{ordinal:!1}):"",V=j&&!t.ordinal&&t.count===0&&this.pluralResolver.shouldUseIntlApi(),u=V&&t[`defaultValue${this.options.pluralSeparator}zero`]||t[`defaultValue${A}`]||t[`defaultValue${me}`]||t.defaultValue;!this.isValidLookup(f)&&k&&(L=!0,f=u),this.isValidLookup(f)||(P=!0,f=o);let y=(t.missingKeyNoValueFallbackToKey||this.options.missingKeyNoValueFallbackToKey)&&P?void 0:f,x=k&&u!==f&&this.options.updateMissing;if(P||L||x){if(this.logger.log(x?"updateKey":"missingKey",c,l,o,x?u:f),s){let T=this.resolve(o,{...t,keySeparator:!1});T&&T.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.")}let O=[],v=this.languageUtils.getFallbackCodes(this.options.fallbackLng,t.lng||this.language);if(this.options.saveMissingTo==="fallback"&&v&&v[0])for(let T=0;T{let Te=k&&D!==f?D:y;this.options.missingKeyHandler?this.options.missingKeyHandler(T,l,R,Te,x,t):this.backendConnector&&this.backendConnector.saveMissing&&this.backendConnector.saveMissing(T,l,R,Te,x,t),this.emit("missingKey",T,l,R,f)};this.options.saveMissing&&(this.options.saveMissingPlurals&&j?O.forEach(T=>{let R=this.pluralResolver.getSuffixes(T,t);V&&t[`defaultValue${this.options.pluralSeparator}zero`]&&R.indexOf(`${this.options.pluralSeparator}zero`)<0&&R.push(`${this.options.pluralSeparator}zero`),R.forEach(D=>{M([T],o+D,t[`defaultValue${D}`]||u)})}):M(O,o,u))}f=this.extendTranslation(f,e,t,h,n),P&&f===o&&this.options.appendNamespaceToMissingKey&&(f=`${l}:${o}`),(P||L)&&this.options.parseMissingKeyHandler&&(this.options.compatibilityAPI!=="v1"?f=this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey?`${l}:${o}`:o,L?f:void 0):f=this.options.parseMissingKeyHandler(f))}return r?(h.res=f,h.usedParams=this.getUsedParamsDetails(t),h):f}extendTranslation(e,t,n,r,s){var o=this;if(this.i18nFormat&&this.i18nFormat.parse)e=this.i18nFormat.parse(e,{...this.options.interpolation.defaultVariables,...n},n.lng||this.language||r.usedLng,r.usedNS,r.usedKey,{resolved:r});else if(!n.skipInterpolation){n.interpolation&&this.interpolator.init({...n,interpolation:{...this.options.interpolation,...n.interpolation}});let c=m(e)&&(n&&n.interpolation&&n.interpolation.skipOnVariables!==void 0?n.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables),d;if(c){let f=e.match(this.interpolator.nestingRegexp);d=f&&f.length}let h=n.replace&&!m(n.replace)?n.replace:n;if(this.options.interpolation.defaultVariables&&(h={...this.options.interpolation.defaultVariables,...h}),e=this.interpolator.interpolate(e,h,n.lng||this.language||r.usedLng,n),c){let f=e.match(this.interpolator.nestingRegexp),g=f&&f.length;d1&&arguments[1]!==void 0?arguments[1]:{},n,r,s,o,a;return m(e)&&(e=[e]),e.forEach(l=>{if(this.isValidLookup(n))return;let c=this.extractFromKey(l,t),d=c.key;r=d;let h=c.namespaces;this.options.fallbackNS&&(h=h.concat(this.options.fallbackNS));let f=t.count!==void 0&&!m(t.count),g=f&&!t.ordinal&&t.count===0&&this.pluralResolver.shouldUseIntlApi(),b=t.context!==void 0&&(m(t.context)||typeof t.context=="number")&&t.context!=="",S=t.lngs?t.lngs:this.languageUtils.toResolveHierarchy(t.lng||this.language,t.fallbackLng);h.forEach(w=>{this.isValidLookup(n)||(a=w,!Ve[`${S[0]}-${w}`]&&this.utils&&this.utils.hasLoadedNamespace&&!this.utils.hasLoadedNamespace(a)&&(Ve[`${S[0]}-${w}`]=!0,this.logger.warn(`key "${r}" for languages "${S.join(", ")}" won't get resolved as namespace "${a}" 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!!!")),S.forEach(N=>{if(this.isValidLookup(n))return;o=N;let C=[d];if(this.i18nFormat&&this.i18nFormat.addLookupKeys)this.i18nFormat.addLookupKeys(C,d,N,w,t);else{let L;f&&(L=this.pluralResolver.getSuffix(N,t.count,t));let P=`${this.options.pluralSeparator}zero`,j=`${this.options.pluralSeparator}ordinal${this.options.pluralSeparator}`;if(f&&(C.push(d+L),t.ordinal&&L.indexOf(j)===0&&C.push(d+L.replace(j,this.options.pluralSeparator)),g&&C.push(d+P)),b){let k=`${d}${this.options.contextSeparator}${t.context}`;C.push(k),f&&(C.push(k+L),t.ordinal&&L.indexOf(j)===0&&C.push(k+L.replace(j,this.options.pluralSeparator)),g&&C.push(k+P))}}let U;for(;U=C.pop();)this.isValidLookup(n)||(s=U,n=this.getResource(N,w,U,t))}))})}),{res:n,usedKey:r,exactUsedKey:s,usedLng:o,usedNS:a}}isValidLookup(e){return e!==void 0&&!(!this.options.returnNull&&e===null)&&!(!this.options.returnEmptyString&&e==="")}getResource(e,t,n){let r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};return this.i18nFormat&&this.i18nFormat.getResource?this.i18nFormat.getResource(e,t,n,r):this.resourceStore.getResource(e,t,n,r)}getUsedParamsDetails(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=["defaultValue","ordinal","context","replace","lng","lngs","fallbackLng","ns","keySeparator","nsSeparator","returnObjects","returnDetails","joinArrays","postProcess","interpolation"],n=e.replace&&!m(e.replace),r=n?e.replace:e;if(n&&typeof e.count<"u"&&(r.count=e.count),this.options.interpolation.defaultVariables&&(r={...this.options.interpolation.defaultVariables,...r}),!n){r={...r};for(let s of t)delete r[s]}return r}static hasDefaultValue(e){let t="defaultValue";for(let n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&t===n.substring(0,t.length)&&e[n]!==void 0)return!0;return!1}},be=i=>i.charAt(0).toUpperCase()+i.slice(1),le=class{constructor(e){this.options=e,this.supportedLngs=this.options.supportedLngs||!1,this.logger=$.create("languageUtils")}getScriptPartFromCode(e){if(e=oe(e),!e||e.indexOf("-")<0)return null;let t=e.split("-");return t.length===2||(t.pop(),t[t.length-1].toLowerCase()==="x")?null:this.formatLanguageCode(t.join("-"))}getLanguagePartFromCode(e){if(e=oe(e),!e||e.indexOf("-")<0)return e;let t=e.split("-");return this.formatLanguageCode(t[0])}formatLanguageCode(e){if(m(e)&&e.indexOf("-")>-1){if(typeof Intl<"u"&&typeof Intl.getCanonicalLocales<"u")try{let r=Intl.getCanonicalLocales(e)[0];if(r&&this.options.lowerCaseLng&&(r=r.toLowerCase()),r)return r}catch{}let t=["hans","hant","latn","cyrl","cans","mong","arab"],n=e.split("-");return this.options.lowerCaseLng?n=n.map(r=>r.toLowerCase()):n.length===2?(n[0]=n[0].toLowerCase(),n[1]=n[1].toUpperCase(),t.indexOf(n[1].toLowerCase())>-1&&(n[1]=be(n[1].toLowerCase()))):n.length===3&&(n[0]=n[0].toLowerCase(),n[1].length===2&&(n[1]=n[1].toUpperCase()),n[0]!=="sgn"&&n[2].length===2&&(n[2]=n[2].toUpperCase()),t.indexOf(n[1].toLowerCase())>-1&&(n[1]=be(n[1].toLowerCase())),t.indexOf(n[2].toLowerCase())>-1&&(n[2]=be(n[2].toLowerCase()))),n.join("-")}return this.options.cleanCode||this.options.lowerCaseLng?e.toLowerCase():e}isSupportedCode(e){return(this.options.load==="languageOnly"||this.options.nonExplicitSupportedLngs)&&(e=this.getLanguagePartFromCode(e)),!this.supportedLngs||!this.supportedLngs.length||this.supportedLngs.indexOf(e)>-1}getBestMatchFromCodes(e){if(!e)return null;let t;return e.forEach(n=>{if(t)return;let r=this.formatLanguageCode(n);(!this.options.supportedLngs||this.isSupportedCode(r))&&(t=r)}),!t&&this.options.supportedLngs&&e.forEach(n=>{if(t)return;let r=this.getLanguagePartFromCode(n);if(this.isSupportedCode(r))return t=r;t=this.options.supportedLngs.find(s=>{if(s===r)return s;if(!(s.indexOf("-")<0&&r.indexOf("-")<0)&&(s.indexOf("-")>0&&r.indexOf("-")<0&&s.substring(0,s.indexOf("-"))===r||s.indexOf(r)===0&&r.length>1))return s})}),t||(t=this.getFallbackCodes(this.options.fallbackLng)[0]),t}getFallbackCodes(e,t){if(!e)return[];if(typeof e=="function"&&(e=e(t)),m(e)&&(e=[e]),Array.isArray(e))return e;if(!t)return e.default||[];let n=e[t];return n||(n=e[this.getScriptPartFromCode(t)]),n||(n=e[this.formatLanguageCode(t)]),n||(n=e[this.getLanguagePartFromCode(t)]),n||(n=e.default),n||[]}toResolveHierarchy(e,t){let n=this.getFallbackCodes(t||this.options.fallbackLng||[],e),r=[],s=o=>{o&&(this.isSupportedCode(o)?r.push(o):this.logger.warn(`rejecting language code not found in supportedLngs: ${o}`))};return m(e)&&(e.indexOf("-")>-1||e.indexOf("_")>-1)?(this.options.load!=="languageOnly"&&s(this.formatLanguageCode(e)),this.options.load!=="languageOnly"&&this.options.load!=="currentOnly"&&s(this.getScriptPartFromCode(e)),this.options.load!=="currentOnly"&&s(this.getLanguagePartFromCode(e))):m(e)&&s(this.formatLanguageCode(e)),n.forEach(o=>{r.indexOf(o)<0&&s(this.formatLanguageCode(o))}),r}},It=[{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}],Ft={1:i=>Number(i>1),2:i=>Number(i!=1),3:i=>0,4:i=>Number(i%10==1&&i%100!=11?0:i%10>=2&&i%10<=4&&(i%100<10||i%100>=20)?1:2),5:i=>Number(i==0?0:i==1?1:i==2?2:i%100>=3&&i%100<=10?3:i%100>=11?4:5),6:i=>Number(i==1?0:i>=2&&i<=4?1:2),7:i=>Number(i==1?0:i%10>=2&&i%10<=4&&(i%100<10||i%100>=20)?1:2),8:i=>Number(i==1?0:i==2?1:i!=8&&i!=11?2:3),9:i=>Number(i>=2),10:i=>Number(i==1?0:i==2?1:i<7?2:i<11?3:4),11:i=>Number(i==1||i==11?0:i==2||i==12?1:i>2&&i<20?2:3),12:i=>Number(i%10!=1||i%100==11),13:i=>Number(i!==0),14:i=>Number(i==1?0:i==2?1:i==3?2:3),15:i=>Number(i%10==1&&i%100!=11?0:i%10>=2&&(i%100<10||i%100>=20)?1:2),16:i=>Number(i%10==1&&i%100!=11?0:i!==0?1:2),17:i=>Number(i==1||i%10==1&&i%100!=11?0:1),18:i=>Number(i==0?0:i==1?1:2),19:i=>Number(i==1?0:i==0||i%100>1&&i%100<11?1:i%100>10&&i%100<20?2:3),20:i=>Number(i==1?0:i==0||i%100>0&&i%100<20?1:2),21:i=>Number(i%100==1?1:i%100==2?2:i%100==3||i%100==4?3:0),22:i=>Number(i==1?0:i==2?1:(i<0||i>10)&&i%10==0?2:3)},Ut=["v1","v2","v3"],Mt=["v4"],_e={zero:0,one:1,two:2,few:3,many:4,other:5},Bt=()=>{let i={};return It.forEach(e=>{e.lngs.forEach(t=>{i[t]={numbers:e.nr,plurals:Ft[e.fc]}})}),i},Se=class{constructor(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.languageUtils=e,this.options=t,this.logger=$.create("pluralResolver"),(!this.options.compatibilityJSON||Mt.includes(this.options.compatibilityJSON))&&(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=Bt(),this.pluralRulesCache={}}addRule(e,t){this.rules[e]=t}clearCache(){this.pluralRulesCache={}}getRule(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(this.shouldUseIntlApi())try{let n=oe(e==="dev"?"en":e),r=t.ordinal?"ordinal":"cardinal",s=JSON.stringify({cleanedCode:n,type:r});if(s in this.pluralRulesCache)return this.pluralRulesCache[s];let o=new Intl.PluralRules(n,{type:r});return this.pluralRulesCache[s]=o,o}catch{return}return this.rules[e]||this.rules[this.languageUtils.getLanguagePartFromCode(e)]}needsPlural(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=this.getRule(e,t);return this.shouldUseIntlApi()?n&&n.resolvedOptions().pluralCategories.length>1:n&&n.numbers.length>1}getPluralFormsOfKey(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return this.getSuffixes(e,n).map(r=>`${t}${r}`)}getSuffixes(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=this.getRule(e,t);return n?this.shouldUseIntlApi()?n.resolvedOptions().pluralCategories.sort((r,s)=>_e[r]-_e[s]).map(r=>`${this.options.prepend}${t.ordinal?`ordinal${this.options.prepend}`:""}${r}`):n.numbers.map(r=>this.getSuffix(e,r,t)):[]}getSuffix(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},r=this.getRule(e,n);return r?this.shouldUseIntlApi()?`${this.options.prepend}${n.ordinal?`ordinal${this.options.prepend}`:""}${r.select(t)}`:this.getSuffixRetroCompatible(r,t):(this.logger.warn(`no plural rule found for: ${e}`),"")}getSuffixRetroCompatible(e,t){let n=e.noAbs?e.plurals(t):e.plurals(Math.abs(t)),r=e.numbers[n];this.options.simplifyPluralSuffix&&e.numbers.length===2&&e.numbers[0]===1&&(r===2?r="plural":r===1&&(r=""));let s=()=>this.options.prepend&&r.toString()?this.options.prepend+r.toString():r.toString();return this.options.compatibilityJSON==="v1"?r===1?"":typeof r=="number"?`_plural_${r.toString()}`:s():this.options.compatibilityJSON==="v2"||this.options.simplifyPluralSuffix&&e.numbers.length===2&&e.numbers[0]===1?s():this.options.prepend&&n.toString()?this.options.prepend+n.toString():n.toString()}shouldUseIntlApi(){return!Ut.includes(this.options.compatibilityJSON)}},qe=function(i,e,t){let n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:".",r=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!0,s=kt(i,e,t);return!s&&r&&m(t)&&(s=xe(i,t,n),s===void 0&&(s=xe(e,t,n))),s},ve=i=>i.replace(/\$/g,"$$$$"),Oe=class{constructor(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};this.logger=$.create("interpolator"),this.options=e,this.format=e.interpolation&&e.interpolation.format||(t=>t),this.init(e)}init(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};e.interpolation||(e.interpolation={escapeValue:!0});let{escape:t,escapeValue:n,useRawValueToEscape:r,prefix:s,prefixEscaped:o,suffix:a,suffixEscaped:l,formatSeparator:c,unescapeSuffix:d,unescapePrefix:h,nestingPrefix:f,nestingPrefixEscaped:g,nestingSuffix:b,nestingSuffixEscaped:S,nestingOptionsSeparator:w,maxReplaces:N,alwaysFormat:C}=e.interpolation;this.escape=t!==void 0?t:At,this.escapeValue=n!==void 0?n:!0,this.useRawValueToEscape=r!==void 0?r:!1,this.prefix=s?_(s):o||"{{",this.suffix=a?_(a):l||"}}",this.formatSeparator=c||",",this.unescapePrefix=d?"":h||"-",this.unescapeSuffix=this.unescapePrefix?"":d||"",this.nestingPrefix=f?_(f):g||_("$t("),this.nestingSuffix=b?_(b):S||_(")"),this.nestingOptionsSeparator=w||",",this.maxReplaces=N||1e3,this.alwaysFormat=C!==void 0?C:!1,this.resetRegExp()}reset(){this.options&&this.init(this.options)}resetRegExp(){let e=(t,n)=>t&&t.source===n?(t.lastIndex=0,t):new RegExp(n,"g");this.regexp=e(this.regexp,`${this.prefix}(.+?)${this.suffix}`),this.regexpUnescape=e(this.regexpUnescape,`${this.prefix}${this.unescapePrefix}(.+?)${this.unescapeSuffix}${this.suffix}`),this.nestingRegexp=e(this.nestingRegexp,`${this.nestingPrefix}(.+?)${this.nestingSuffix}`)}interpolate(e,t,n,r){let s,o,a,l=this.options&&this.options.interpolation&&this.options.interpolation.defaultVariables||{},c=g=>{if(g.indexOf(this.formatSeparator)<0){let N=qe(t,l,g,this.options.keySeparator,this.options.ignoreJSONStructure);return this.alwaysFormat?this.format(N,void 0,n,{...r,...t,interpolationkey:g}):N}let b=g.split(this.formatSeparator),S=b.shift().trim(),w=b.join(this.formatSeparator).trim();return this.format(qe(t,l,S,this.options.keySeparator,this.options.ignoreJSONStructure),w,n,{...r,...t,interpolationkey:S})};this.resetRegExp();let d=r&&r.missingInterpolationHandler||this.options.missingInterpolationHandler,h=r&&r.interpolation&&r.interpolation.skipOnVariables!==void 0?r.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables;return[{regex:this.regexpUnescape,safeValue:g=>ve(g)},{regex:this.regexp,safeValue:g=>this.escapeValue?ve(this.escape(g)):ve(g)}].forEach(g=>{for(a=0;s=g.regex.exec(e);){let b=s[1].trim();if(o=c(b),o===void 0)if(typeof d=="function"){let w=d(e,s,r);o=m(w)?w:""}else if(r&&Object.prototype.hasOwnProperty.call(r,b))o="";else if(h){o=s[0];continue}else this.logger.warn(`missed to pass in variable ${b} for interpolating ${e}`),o="";else!m(o)&&!this.useRawValueToEscape&&(o=Ue(o));let S=g.safeValue(o);if(e=e.replace(s[0],S),h?(g.regex.lastIndex+=o.length,g.regex.lastIndex-=s[0].length):g.regex.lastIndex=0,a++,a>=this.maxReplaces)break}}),e}nest(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},r,s,o,a=(l,c)=>{let d=this.nestingOptionsSeparator;if(l.indexOf(d)<0)return l;let h=l.split(new RegExp(`${d}[ ]*{`)),f=`{${h[1]}`;l=h[0],f=this.interpolate(f,o);let g=f.match(/'/g),b=f.match(/"/g);(g&&g.length%2===0&&!b||b.length%2!==0)&&(f=f.replace(/'/g,'"'));try{o=JSON.parse(f),c&&(o={...c,...o})}catch(S){return this.logger.warn(`failed parsing options string in nesting for key ${l}`,S),`${l}${d}${f}`}return o.defaultValue&&o.defaultValue.indexOf(this.prefix)>-1&&delete o.defaultValue,l};for(;r=this.nestingRegexp.exec(e);){let l=[];o={...n},o=o.replace&&!m(o.replace)?o.replace:o,o.applyPostProcessor=!1,delete o.defaultValue;let c=!1;if(r[0].indexOf(this.formatSeparator)!==-1&&!/{.*}/.test(r[1])){let d=r[1].split(this.formatSeparator).map(h=>h.trim());r[1]=d.shift(),l=d,c=!0}if(s=t(a.call(this,r[1].trim(),o),o),s&&r[0]===e&&!m(s))return s;m(s)||(s=Ue(s)),s||(this.logger.warn(`missed to resolve ${r[1]} for nesting ${e}`),s=""),c&&(s=l.reduce((d,h)=>this.format(d,h,n.lng,{...n,interpolationkey:r[1].trim()}),s.trim())),e=e.replace(r[0],s),this.regexp.lastIndex=0}return e}},Ht=i=>{let e=i.toLowerCase().trim(),t={};if(i.indexOf("(")>-1){let n=i.split("(");e=n[0].toLowerCase().trim();let r=n[1].substring(0,n[1].length-1);e==="currency"&&r.indexOf(":")<0?t.currency||(t.currency=r.trim()):e==="relativetime"&&r.indexOf(":")<0?t.range||(t.range=r.trim()):r.split(";").forEach(o=>{if(o){let[a,...l]=o.split(":"),c=l.join(":").trim().replace(/^'+|'+$/g,""),d=a.trim();t[d]||(t[d]=c),c==="false"&&(t[d]=!1),c==="true"&&(t[d]=!0),isNaN(c)||(t[d]=parseInt(c,10))}})}return{formatName:e,formatOptions:t}},q=i=>{let e={};return(t,n,r)=>{let s=r;r&&r.interpolationkey&&r.formatParams&&r.formatParams[r.interpolationkey]&&r[r.interpolationkey]&&(s={...s,[r.interpolationkey]:void 0});let o=n+JSON.stringify(s),a=e[o];return a||(a=i(oe(n),r),e[o]=a),a(t)}},Le=class{constructor(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};this.logger=$.create("formatter"),this.options=e,this.formats={number:q((t,n)=>{let r=new Intl.NumberFormat(t,{...n});return s=>r.format(s)}),currency:q((t,n)=>{let r=new Intl.NumberFormat(t,{...n,style:"currency"});return s=>r.format(s)}),datetime:q((t,n)=>{let r=new Intl.DateTimeFormat(t,{...n});return s=>r.format(s)}),relativetime:q((t,n)=>{let r=new Intl.RelativeTimeFormat(t,{...n});return s=>r.format(s,n.range||"day")}),list:q((t,n)=>{let r=new Intl.ListFormat(t,{...n});return s=>r.format(s)})},this.init(e)}init(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{interpolation:{}};this.formatSeparator=t.interpolation.formatSeparator||","}add(e,t){this.formats[e.toLowerCase().trim()]=t}addCached(e,t){this.formats[e.toLowerCase().trim()]=q(t)}format(e,t,n){let r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},s=t.split(this.formatSeparator);if(s.length>1&&s[0].indexOf("(")>1&&s[0].indexOf(")")<0&&s.find(a=>a.indexOf(")")>-1)){let a=s.findIndex(l=>l.indexOf(")")>-1);s[0]=[s[0],...s.splice(1,a)].join(this.formatSeparator)}return s.reduce((a,l)=>{let{formatName:c,formatOptions:d}=Ht(l);if(this.formats[c]){let h=a;try{let f=r&&r.formatParams&&r.formatParams[r.interpolationkey]||{},g=f.locale||f.lng||r.locale||r.lng||n;h=this.formats[c](a,g,{...d,...r,...f})}catch(f){this.logger.warn(f)}return h}else this.logger.warn(`there was no format function for ${c}`);return a},e)}},Vt=(i,e)=>{i.pending[e]!==void 0&&(delete i.pending[e],i.pendingCount--)},Pe=class extends z{constructor(e,t,n){let r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};super(),this.backend=e,this.store=t,this.services=n,this.languageUtils=n.languageUtils,this.options=r,this.logger=$.create("backendConnector"),this.waitingReads=[],this.maxParallelReads=r.maxParallelReads||10,this.readingCalls=0,this.maxRetries=r.maxRetries>=0?r.maxRetries:5,this.retryTimeout=r.retryTimeout>=1?r.retryTimeout:350,this.state={},this.queue=[],this.backend&&this.backend.init&&this.backend.init(n,r.backend,r)}queueLoad(e,t,n,r){let s={},o={},a={},l={};return e.forEach(c=>{let d=!0;t.forEach(h=>{let f=`${c}|${h}`;!n.reload&&this.store.hasResourceBundle(c,h)?this.state[f]=2:this.state[f]<0||(this.state[f]===1?o[f]===void 0&&(o[f]=!0):(this.state[f]=1,d=!1,o[f]===void 0&&(o[f]=!0),s[f]===void 0&&(s[f]=!0),l[h]===void 0&&(l[h]=!0)))}),d||(a[c]=!0)}),(Object.keys(s).length||Object.keys(o).length)&&this.queue.push({pending:o,pendingCount:Object.keys(o).length,loaded:{},errors:[],callback:r}),{toLoad:Object.keys(s),pending:Object.keys(o),toLoadLanguages:Object.keys(a),toLoadNamespaces:Object.keys(l)}}loaded(e,t,n){let r=e.split("|"),s=r[0],o=r[1];t&&this.emit("failedLoading",s,o,t),!t&&n&&this.store.addResourceBundle(s,o,n,void 0,void 0,{skipCopy:!0}),this.state[e]=t?-1:2,t&&n&&(this.state[e]=0);let a={};this.queue.forEach(l=>{Et(l.loaded,[s],o),Vt(l,e),t&&l.errors.push(t),l.pendingCount===0&&!l.done&&(Object.keys(l.loaded).forEach(c=>{a[c]||(a[c]={});let d=l.loaded[c];d.length&&d.forEach(h=>{a[c][h]===void 0&&(a[c][h]=!0)})}),l.done=!0,l.errors.length?l.callback(l.errors):l.callback())}),this.emit("loaded",a),this.queue=this.queue.filter(l=>!l.done)}read(e,t,n){let r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:0,s=arguments.length>4&&arguments[4]!==void 0?arguments[4]:this.retryTimeout,o=arguments.length>5?arguments[5]:void 0;if(!e.length)return o(null,{});if(this.readingCalls>=this.maxParallelReads){this.waitingReads.push({lng:e,ns:t,fcName:n,tried:r,wait:s,callback:o});return}this.readingCalls++;let a=(c,d)=>{if(this.readingCalls--,this.waitingReads.length>0){let h=this.waitingReads.shift();this.read(h.lng,h.ns,h.fcName,h.tried,h.wait,h.callback)}if(c&&d&&r{this.read.call(this,e,t,n,r+1,s*2,o)},s);return}o(c,d)},l=this.backend[n].bind(this.backend);if(l.length===2){try{let c=l(e,t);c&&typeof c.then=="function"?c.then(d=>a(null,d)).catch(a):a(null,c)}catch(c){a(c)}return}return l(e,t,a)}prepareLoading(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},r=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."),r&&r();m(e)&&(e=this.languageUtils.toResolveHierarchy(e)),m(t)&&(t=[t]);let s=this.queueLoad(e,t,n,r);if(!s.toLoad.length)return s.pending.length||r(),null;s.toLoad.forEach(o=>{this.loadOne(o)})}load(e,t,n){this.prepareLoading(e,t,{},n)}reload(e,t,n){this.prepareLoading(e,t,{reload:!0},n)}loadOne(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",n=e.split("|"),r=n[0],s=n[1];this.read(r,s,"read",void 0,void 0,(o,a)=>{o&&this.logger.warn(`${t}loading namespace ${s} for language ${r} failed`,o),!o&&a&&this.logger.log(`${t}loaded namespace ${s} for language ${r}`,a),this.loaded(e,o,a)})}saveMissing(e,t,n,r,s){let o=arguments.length>5&&arguments[5]!==void 0?arguments[5]:{},a=arguments.length>6&&arguments[6]!==void 0?arguments[6]:()=>{};if(this.services.utils&&this.services.utils.hasLoadedNamespace&&!this.services.utils.hasLoadedNamespace(t)){this.logger.warn(`did not save key "${n}" as the namespace "${t}" 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(!(n==null||n==="")){if(this.backend&&this.backend.create){let l={...o,isUpdate:s},c=this.backend.create.bind(this.backend);if(c.length<6)try{let d;c.length===5?d=c(e,t,n,r,l):d=c(e,t,n,r),d&&typeof d.then=="function"?d.then(h=>a(null,h)).catch(a):a(null,d)}catch(d){a(d)}else c(e,t,n,r,a,l)}!e||!e[0]||this.store.addResource(e[0],t,n,r)}}},Ke=()=>({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:!1,returnEmptyString:!0,returnObjects:!1,joinArrays:!1,returnedObjectHandler:!1,parseMissingKeyHandler:!1,appendNamespaceToMissingKey:!1,appendNamespaceToCIMode:!1,overloadTranslationOptionHandler:i=>{let e={};if(typeof i[1]=="object"&&(e=i[1]),m(i[1])&&(e.defaultValue=i[1]),m(i[2])&&(e.tDescription=i[2]),typeof i[2]=="object"||typeof i[3]=="object"){let t=i[3]||i[2];Object.keys(t).forEach(n=>{e[n]=t[n]})}return e},interpolation:{escapeValue:!0,format:i=>i,prefix:"{{",suffix:"}}",formatSeparator:",",unescapePrefix:"-",nestingPrefix:"$t(",nestingSuffix:")",nestingOptionsSeparator:",",maxReplaces:1e3,skipOnVariables:!0}}),ze=i=>(m(i.ns)&&(i.ns=[i.ns]),m(i.fallbackLng)&&(i.fallbackLng=[i.fallbackLng]),m(i.fallbackNS)&&(i.fallbackNS=[i.fallbackNS]),i.supportedLngs&&i.supportedLngs.indexOf("cimode")<0&&(i.supportedLngs=i.supportedLngs.concat(["cimode"])),i),re=()=>{},_t=i=>{Object.getOwnPropertyNames(Object.getPrototypeOf(i)).forEach(t=>{typeof i[t]=="function"&&(i[t]=i[t].bind(i))})},B=class extends z{constructor(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;if(super(),this.options=ze(e),this.services={},this.logger=$,this.modules={external:[]},_t(this),t&&!this.isInitialized&&!e.isClone){if(!this.options.initImmediate)return this.init(e,t),this;setTimeout(()=>{this.init(e,t)},0)}}init(){var e=this;let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=arguments.length>1?arguments[1]:void 0;this.isInitializing=!0,typeof t=="function"&&(n=t,t={}),!t.defaultNS&&t.defaultNS!==!1&&t.ns&&(m(t.ns)?t.defaultNS=t.ns:t.ns.indexOf("translation")<0&&(t.defaultNS=t.ns[0]));let r=Ke();this.options={...r,...this.options,...ze(t)},this.options.compatibilityAPI!=="v1"&&(this.options.interpolation={...r.interpolation,...this.options.interpolation}),t.keySeparator!==void 0&&(this.options.userDefinedKeySeparator=t.keySeparator),t.nsSeparator!==void 0&&(this.options.userDefinedNsSeparator=t.nsSeparator);let s=d=>d?typeof d=="function"?new d:d:null;if(!this.options.isClone){this.modules.logger?$.init(s(this.modules.logger),this.options):$.init(null,this.options);let d;this.modules.formatter?d=this.modules.formatter:typeof Intl<"u"&&(d=Le);let h=new le(this.options);this.store=new ae(this.options.resources,this.options);let f=this.services;f.logger=$,f.resourceStore=this.store,f.languageUtils=h,f.pluralResolver=new Se(h,{prepend:this.options.pluralSeparator,compatibilityJSON:this.options.compatibilityJSON,simplifyPluralSuffix:this.options.simplifyPluralSuffix}),d&&(!this.options.interpolation.format||this.options.interpolation.format===r.interpolation.format)&&(f.formatter=s(d),f.formatter.init(f,this.options),this.options.interpolation.format=f.formatter.format.bind(f.formatter)),f.interpolator=new Oe(this.options),f.utils={hasLoadedNamespace:this.hasLoadedNamespace.bind(this)},f.backendConnector=new Pe(s(this.modules.backend),f.resourceStore,f,this.options),f.backendConnector.on("*",function(g){for(var b=arguments.length,S=new Array(b>1?b-1:0),w=1;w1?b-1:0),w=1;w{g.init&&g.init(this)})}if(this.format=this.options.interpolation.format,n||(n=re),this.options.fallbackLng&&!this.services.languageDetector&&!this.options.lng){let 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"),["getResource","hasResourceBundle","getResourceBundle","getDataByLanguage"].forEach(d=>{this[d]=function(){return e.store[d](...arguments)}}),["addResource","addResources","addResourceBundle","removeResourceBundle"].forEach(d=>{this[d]=function(){return e.store[d](...arguments),e}});let l=G(),c=()=>{let d=(h,f)=>{this.isInitializing=!1,this.isInitialized&&!this.initializedStoreOnce&&this.logger.warn("init: i18next is already initialized. You should call init just once!"),this.isInitialized=!0,this.options.isClone||this.logger.log("initialized",this.options),this.emit("initialized",this.options),l.resolve(f),n(h,f)};if(this.languages&&this.options.compatibilityAPI!=="v1"&&!this.isInitialized)return d(null,this.t.bind(this));this.changeLanguage(this.options.lng,d)};return this.options.resources||!this.options.initImmediate?c():setTimeout(c,0),l}loadResources(e){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:re,r=m(e)?e:this.language;if(typeof e=="function"&&(n=e),!this.options.resources||this.options.partialBundledLanguages){if(r&&r.toLowerCase()==="cimode"&&(!this.options.preload||this.options.preload.length===0))return n();let s=[],o=a=>{if(!a||a==="cimode")return;this.services.languageUtils.toResolveHierarchy(a).forEach(c=>{c!=="cimode"&&s.indexOf(c)<0&&s.push(c)})};r?o(r):this.services.languageUtils.getFallbackCodes(this.options.fallbackLng).forEach(l=>o(l)),this.options.preload&&this.options.preload.forEach(a=>o(a)),this.services.backendConnector.load(s,this.options.ns,a=>{!a&&!this.resolvedLanguage&&this.language&&this.setResolvedLanguage(this.language),n(a)})}else n(null)}reloadResources(e,t,n){let r=G();return typeof e=="function"&&(n=e,e=void 0),typeof t=="function"&&(n=t,t=void 0),e||(e=this.languages),t||(t=this.options.ns),n||(n=re),this.services.backendConnector.reload(e,t,s=>{r.resolve(),n(s)}),r}use(e){if(!e)throw new Error("You are passing an undefined module! Please check the object you are passing to i18next.use()");if(!e.type)throw new Error("You are passing a wrong module! Please check the object you are passing to i18next.use()");return e.type==="backend"&&(this.modules.backend=e),(e.type==="logger"||e.log&&e.warn&&e.error)&&(this.modules.logger=e),e.type==="languageDetector"&&(this.modules.languageDetector=e),e.type==="i18nFormat"&&(this.modules.i18nFormat=e),e.type==="postProcessor"&&Xe.addPostProcessor(e),e.type==="formatter"&&(this.modules.formatter=e),e.type==="3rdParty"&&this.modules.external.push(e),this}setResolvedLanguage(e){if(!(!e||!this.languages)&&!(["cimode","dev"].indexOf(e)>-1))for(let t=0;t-1)&&this.store.hasLanguageSomeTranslations(n)){this.resolvedLanguage=n;break}}}changeLanguage(e,t){var n=this;this.isLanguageChangingTo=e;let r=G();this.emit("languageChanging",e);let s=l=>{this.language=l,this.languages=this.services.languageUtils.toResolveHierarchy(l),this.resolvedLanguage=void 0,this.setResolvedLanguage(l)},o=(l,c)=>{c?(s(c),this.translator.changeLanguage(c),this.isLanguageChangingTo=void 0,this.emit("languageChanged",c),this.logger.log("languageChanged",c)):this.isLanguageChangingTo=void 0,r.resolve(function(){return n.t(...arguments)}),t&&t(l,function(){return n.t(...arguments)})},a=l=>{!e&&!l&&this.services.languageDetector&&(l=[]);let c=m(l)?l:this.services.languageUtils.getBestMatchFromCodes(l);c&&(this.language||s(c),this.translator.language||this.translator.changeLanguage(c),this.services.languageDetector&&this.services.languageDetector.cacheUserLanguage&&this.services.languageDetector.cacheUserLanguage(c)),this.loadResources(c,d=>{o(d,c)})};return!e&&this.services.languageDetector&&!this.services.languageDetector.async?a(this.services.languageDetector.detect()):!e&&this.services.languageDetector&&this.services.languageDetector.async?this.services.languageDetector.detect.length===0?this.services.languageDetector.detect().then(a):this.services.languageDetector.detect(a):a(e),r}getFixedT(e,t,n){var r=this;let s=function(o,a){let l;if(typeof a!="object"){for(var c=arguments.length,d=new Array(c>2?c-2:0),h=2;h`${l.keyPrefix}${f}${b}`):g=l.keyPrefix?`${l.keyPrefix}${f}${o}`:o,r.t(g,l)};return m(e)?s.lng=e:s.lngs=e,s.ns=t,s.keyPrefix=n,s}t(){return this.translator&&this.translator.translate(...arguments)}exists(){return this.translator&&this.translator.exists(...arguments)}setDefaultNamespace(e){this.options.defaultNS=e}hasLoadedNamespace(e){let t=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;let n=t.lng||this.resolvedLanguage||this.languages[0],r=this.options?this.options.fallbackLng:!1,s=this.languages[this.languages.length-1];if(n.toLowerCase()==="cimode")return!0;let o=(a,l)=>{let c=this.services.backendConnector.state[`${a}|${l}`];return c===-1||c===0||c===2};if(t.precheck){let a=t.precheck(this,o);if(a!==void 0)return a}return!!(this.hasResourceBundle(n,e)||!this.services.backendConnector.backend||this.options.resources&&!this.options.partialBundledLanguages||o(n,e)&&(!r||o(s,e)))}loadNamespaces(e,t){let n=G();return this.options.ns?(m(e)&&(e=[e]),e.forEach(r=>{this.options.ns.indexOf(r)<0&&this.options.ns.push(r)}),this.loadResources(r=>{n.resolve(),t&&t(r)}),n):(t&&t(),Promise.resolve())}loadLanguages(e,t){let n=G();m(e)&&(e=[e]);let r=this.options.preload||[],s=e.filter(o=>r.indexOf(o)<0&&this.services.languageUtils.isSupportedCode(o));return s.length?(this.options.preload=r.concat(s),this.loadResources(o=>{n.resolve(),t&&t(o)}),n):(t&&t(),Promise.resolve())}dir(e){if(e||(e=this.resolvedLanguage||(this.languages&&this.languages.length>0?this.languages[0]:this.language)),!e)return"rtl";let t=["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"],n=this.services&&this.services.languageUtils||new le(Ke());return t.indexOf(n.getLanguagePartFromCode(e))>-1||e.toLowerCase().indexOf("-arab")>1?"rtl":"ltr"}static createInstance(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;return new B(e,t)}cloneInstance(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:re,n=e.forkResourceStore;n&&delete e.forkResourceStore;let r={...this.options,...e,isClone:!0},s=new B(r);return(e.debug!==void 0||e.prefix!==void 0)&&(s.logger=s.logger.clone(e)),["store","services","language"].forEach(a=>{s[a]=this[a]}),s.services={...this.services},s.services.utils={hasLoadedNamespace:s.hasLoadedNamespace.bind(s)},n&&(s.store=new ae(this.store.data,r),s.services.resourceStore=s.store),s.translator=new J(s.services,r),s.translator.on("*",function(a){for(var l=arguments.length,c=new Array(l>1?l-1:0),d=1;d{if(e)for(let t in e)i[t]===void 0&&(i[t]=e[t])}),i}var We=/^[\u0009\u0020-\u007e\u0080-\u00ff]+$/,Jt=(i,e,t)=>{let n=t||{};n.path=n.path||"/";let r=encodeURIComponent(e),s=`${i}=${r}`;if(n.maxAge>0){let o=n.maxAge-0;if(Number.isNaN(o))throw new Error("maxAge should be a Number");s+=`; Max-Age=${Math.floor(o)}`}if(n.domain){if(!We.test(n.domain))throw new TypeError("option domain is invalid");s+=`; Domain=${n.domain}`}if(n.path){if(!We.test(n.path))throw new TypeError("option path is invalid");s+=`; Path=${n.path}`}if(n.expires){if(typeof n.expires.toUTCString!="function")throw new TypeError("option expires is invalid");s+=`; Expires=${n.expires.toUTCString()}`}if(n.httpOnly&&(s+="; HttpOnly"),n.secure&&(s+="; Secure"),n.sameSite)switch(typeof n.sameSite=="string"?n.sameSite.toLowerCase():n.sameSite){case!0:s+="; SameSite=Strict";break;case"lax":s+="; SameSite=Lax";break;case"strict":s+="; SameSite=Strict";break;case"none":s+="; SameSite=None";break;default:throw new TypeError("option sameSite is invalid")}return s},Qe={create(i,e,t,n){let r=arguments.length>4&&arguments[4]!==void 0?arguments[4]:{path:"/",sameSite:"strict"};t&&(r.expires=new Date,r.expires.setTime(r.expires.getTime()+t*60*1e3)),n&&(r.domain=n),document.cookie=Jt(i,encodeURIComponent(e),r)},read(i){let e=`${i}=`,t=document.cookie.split(";");for(let n=0;n-1&&(n=window.location.hash.substring(window.location.hash.indexOf("?")));let s=n.substring(1).split("&");for(let o=0;o0&&s[o].substring(0,a)===e&&(t=s[o].substring(a+1))}}return t}},Z=null,Ge=()=>{if(Z!==null)return Z;try{Z=window!=="undefined"&&window.localStorage!==null;let i="i18next.translate.boo";window.localStorage.setItem(i,"foo"),window.localStorage.removeItem(i)}catch{Z=!1}return Z},Qt={name:"localStorage",lookup(i){let{lookupLocalStorage:e}=i;if(e&&Ge())return window.localStorage.getItem(e)||void 0},cacheUserLanguage(i,e){let{lookupLocalStorage:t}=e;t&&Ge()&&window.localStorage.setItem(t,i)}},ee=null,Ye=()=>{if(ee!==null)return ee;try{ee=window!=="undefined"&&window.sessionStorage!==null;let i="i18next.translate.boo";window.sessionStorage.setItem(i,"foo"),window.sessionStorage.removeItem(i)}catch{ee=!1}return ee},Gt={name:"sessionStorage",lookup(i){let{lookupSessionStorage:e}=i;if(e&&Ye())return window.sessionStorage.getItem(e)||void 0},cacheUserLanguage(i,e){let{lookupSessionStorage:t}=e;t&&Ye()&&window.sessionStorage.setItem(t,i)}},Yt={name:"navigator",lookup(i){let e=[];if(typeof navigator<"u"){let{languages:t,userLanguage:n,language:r}=navigator;if(t)for(let s=0;s0?e:void 0}},Zt={name:"htmlTag",lookup(i){let{htmlTag:e}=i,t,n=e||(typeof document<"u"?document.documentElement:null);return n&&typeof n.getAttribute=="function"&&(t=n.getAttribute("lang")),t}},en={name:"path",lookup(i){let{lookupFromPathIndex:e}=i;if(typeof window>"u")return;let t=window.location.pathname.match(/\/([a-zA-Z-]*)/g);return Array.isArray(t)?t[typeof e=="number"?e:0]?.replace("/",""):void 0}},tn={name:"subdomain",lookup(i){let{lookupFromSubdomainIndex:e}=i,t=typeof e=="number"?e+1:1,n=typeof window<"u"&&window.location?.hostname?.match(/^(\w{2,5})\.(([a-z0-9-]{1,63}\.[a-z]{2,6})|localhost)/i);if(n)return n[t]}};function nn(){return{order:["querystring","cookie","localStorage","sessionStorage","navigator","htmlTag"],lookupQuerystring:"lng",lookupCookie:"i18next",lookupLocalStorage:"i18nextLng",lookupSessionStorage:"i18nextLng",caches:["localStorage"],excludeCacheFor:["cimode"],convertDetectedLanguage:i=>i}}var te=class{constructor(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.type="languageDetector",this.detectors={},this.init(e,t)}init(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};this.services=e||{languageUtils:{}},this.options=zt(t,this.options||{},nn()),typeof this.options.convertDetectedLanguage=="string"&&this.options.convertDetectedLanguage.indexOf("15897")>-1&&(this.options.convertDetectedLanguage=r=>r.replace("-","_")),this.options.lookupFromUrlIndex&&(this.options.lookupFromPathIndex=this.options.lookupFromUrlIndex),this.i18nOptions=n,this.addDetector(Xt),this.addDetector(Wt),this.addDetector(Qt),this.addDetector(Gt),this.addDetector(Yt),this.addDetector(Zt),this.addDetector(en),this.addDetector(tn)}addDetector(e){return this.detectors[e.name]=e,this}detect(e){e||(e=this.options.order);let t=[];return e.forEach(n=>{if(this.detectors[n]){let r=this.detectors[n].lookup(this.options);r&&typeof r=="string"&&(r=[r]),r&&(t=t.concat(r))}}),t=t.map(n=>this.options.convertDetectedLanguage(n)),this.services.languageUtils.getBestMatchFromCodes?t:t.length>0?t[0]:null}cacheUserLanguage(e,t){t||(t=this.options.caches),t&&(this.options.excludeCacheFor&&this.options.excludeCacheFor.indexOf(e)>-1||t.forEach(n=>{this.detectors[n]&&this.detectors[n].cacheUserLanguage(e,this.options)}))}};te.type="languageDetector";function Re(i){return Re=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Re(i)}var Ze=[],An=Ze.forEach,Tn=Ze.slice;function Ce(){return typeof XMLHttpRequest=="function"||(typeof XMLHttpRequest>"u"?"undefined":Re(XMLHttpRequest))==="object"}function rn(i){return!!i&&typeof i.then=="function"}function et(i){return rn(i)?i:Promise.resolve(i)}var de=Q(rt(),1);function st(i,e){var t=Object.keys(i);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(i);e&&(n=n.filter(function(r){return Object.getOwnPropertyDescriptor(i,r).enumerable})),t.push.apply(t,n)}return t}function ot(i){for(var e=1;e"u"&&typeof globalThis<"u"&&typeof globalThis.process<"u"&&globalThis.process.versions&&globalThis.process.versions.node&&(s["User-Agent"]="i18next-http-backend (node/".concat(globalThis.process.version,"; ").concat(globalThis.process.platform," ").concat(globalThis.process.arch,")")),n&&(s["Content-Type"]="application/json");var o=typeof e.requestOptions=="function"?e.requestOptions(n):e.requestOptions,a=ot({method:n?"POST":"GET",body:n?e.stringify(n):void 0,headers:s},lt?{}:o),l=typeof e.alternateFetch=="function"&&e.alternateFetch.length>=1?e.alternateFetch:void 0;try{at(t,a,r,l)}catch(c){if(!o||Object.keys(o).length===0||!c.message||c.message.indexOf("not implemented")<0)return r(c);try{Object.keys(o).forEach(function(d){delete a[d]}),at(t,a,r,l),lt=!0}catch(d){r(d)}}},un=function(e,t,n,r){n&&H(n)==="object"&&(n=ke("",n).slice(1)),e.queryStringParams&&(t=ke(t,e.queryStringParams));try{var s;ie?s=new ie:s=new he("MSXML2.XMLHTTP.3.0"),s.open(n?"POST":"GET",t,1),e.crossDomain||s.setRequestHeader("X-Requested-With","XMLHttpRequest"),s.withCredentials=!!e.withCredentials,n&&s.setRequestHeader("Content-Type","application/x-www-form-urlencoded"),s.overrideMimeType&&s.overrideMimeType("application/json");var o=e.customHeaders;if(o=typeof o=="function"?o():o,o)for(var a in o)s.setRequestHeader(a,o[a]);s.onreadystatechange=function(){s.readyState>3&&r(s.status>=400?s.statusText:null,{status:s.status,data:s.responseText})},s.send(n)}catch(l){console&&console.log(l)}},fn=function(e,t,n,r){if(typeof n=="function"&&(r=n,n=void 0),r=r||function(){},I&&t.indexOf("file:")!==0)return ln(e,t,n,r);if(Ce()||typeof ActiveXObject=="function")return un(e,t,n,r);r(new Error("No fetch and no xhr implementation found!"))},ut=fn;function W(i){return W=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},W(i)}function ft(i,e){var t=Object.keys(i);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(i);e&&(n=n.filter(function(r){return Object.getOwnPropertyDescriptor(i,r).enumerable})),t.push.apply(t,n)}return t}function Ne(i){for(var e=1;e1&&arguments[1]!==void 0?arguments[1]:{},n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};cn(this,i),this.services=e,this.options=t,this.allOptions=n,this.type="backend",this.init(e,t,n)}return dn(i,[{key:"init",value:function(t){var n=this,r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},s=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};if(this.services=t,this.options=Ne(Ne(Ne({},pn()),this.options||{}),r),this.allOptions=s,this.services&&this.options.reloadInterval){var o=setInterval(function(){return n.reload()},this.options.reloadInterval);W(o)==="object"&&typeof o.unref=="function"&&o.unref()}}},{key:"readMulti",value:function(t,n,r){this._readAny(t,t,n,n,r)}},{key:"read",value:function(t,n,r){this._readAny([t],t,[n],n,r)}},{key:"_readAny",value:function(t,n,r,s,o){var a=this,l=this.options.loadPath;typeof this.options.loadPath=="function"&&(l=this.options.loadPath(t,r)),l=et(l),l.then(function(c){if(!c)return o(null,{});var d=a.services.interpolator.interpolate(c,{lng:t.join("+"),ns:r.join("+")});a.loadUrl(d,o,n,s)})}},{key:"loadUrl",value:function(t,n,r,s){var o=this,a=typeof r=="string"?[r]:r,l=typeof s=="string"?[s]:s,c=this.options.parseLoadPayload(a,l);this.options.request(this.options,t,c,function(d,h){if(h&&(h.status>=500&&h.status<600||!h.status))return n("failed loading "+t+"; status code: "+h.status,!0);if(h&&h.status>=400&&h.status<500)return n("failed loading "+t+"; status code: "+h.status,!1);if(!h&&d&&d.message){var f=d.message.toLowerCase(),g=["failed","fetch","network","load"].find(function(w){return f.indexOf(w)>-1});if(g)return n("failed loading "+t+": "+d.message,!0)}if(d)return n(d,!1);var b,S;try{typeof h.data=="string"?b=o.options.parse(h.data,r,s):b=h.data}catch{S="failed parsing "+t+" to json"}if(S)return n(S,!1);n(null,b)})}},{key:"create",value:function(t,n,r,s,o){var a=this;if(this.options.addPath){typeof t=="string"&&(t=[t]);var l=this.options.parsePayload(n,r,s),c=0,d=[],h=[];t.forEach(function(f){var g=a.options.addPath;typeof a.options.addPath=="function"&&(g=a.options.addPath(f,n));var b=a.services.interpolator.interpolate(g,{lng:f,ns:n});a.options.request(a.options,b,l,function(S,w){c+=1,d.push(S),h.push(w),c===t.length&&typeof o=="function"&&o(d,h)})})}}},{key:"reload",value:function(){var t=this,n=this.services,r=n.backendConnector,s=n.languageUtils,o=n.logger,a=r.language;if(!(a&&a.toLowerCase()==="cimode")){var l=[],c=function(h){var f=s.toResolveHierarchy(h);f.forEach(function(g){l.indexOf(g)<0&&l.push(g)})};c(a),this.allOptions.preload&&this.allOptions.preload.forEach(function(d){return c(d)}),l.forEach(function(d){t.allOptions.ns.forEach(function(h){r.read(d,h,"read",null,null,function(f,g){f&&o.warn("loading namespace ".concat(h," for language ").concat(d," failed"),f),!f&&g&&o.log("loaded namespace ".concat(h," for language ").concat(d),g),r.loaded("".concat(d,"|").concat(h),f,g)})})})}}}])}();pt.type="backend";var gt=pt;function mt(){return[...Object.values(window.__remixRouteModules).flatMap(e=>typeof e?.handle!="object"?[]:e.handle?"i18n"in e.handle?typeof e.handle.i18n=="string"?[e.handle.i18n]:Array.isArray(e.handle.i18n)&&e.handle.i18n.every(t=>typeof t=="string")?e.handle.i18n:[]:[]:[])]}async function yt({basePath:i,config:e,hash:t}){return await E.use(De).use(te).use(gt).init({...e,ns:mt(),backend:{loadPath:`${i}/locales/${t}/{{lng}}/{{ns}}.json`},detection:{order:["htmlTag"],caches:[]}}),E}var ge=Q(Lt(),1),Ot=Q(vt(),1);var wt={supportedLngs:["de","en","es","fr"],fallbackLng:"en",defaultNS:"common",react:{useSuspense:!1}},xt="92156e5";var pe=Q(Fe(),1);async function St(){let i=await yt({basePath:document.querySelector("html")?.dataset.basePath??"/",config:wt,hash:xt});(0,ge.startTransition)(()=>{(0,Ot.hydrateRoot)(document,(0,pe.jsx)($e,{i18n:i,children:(0,pe.jsx)(ge.StrictMode,{children:(0,pe.jsx)(Ie,{})})}))})}globalThis.requestIdleCallback?globalThis.requestIdleCallback(St):globalThis.setTimeout(St,1);