@ukpc-lib/react 0.2.30 → 0.2.33

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (30) hide show
  1. package/dist/@types/resources.d.ts +457 -0
  2. package/dist/components/index.cjs +30 -30
  3. package/dist/components/index.js +2785 -2912
  4. package/dist/index.module-1f083a17.cjs +1088 -0
  5. package/dist/index.module-68397449.js +26213 -0
  6. package/dist/main.d.ts +0 -1
  7. package/dist/share/TranslationProvider/index.d.ts +4 -5
  8. package/dist/share/index.cjs +1 -1
  9. package/dist/share/index.js +20 -17
  10. package/package.json +3 -3
  11. package/web-components-bundle/access-denied/index.cjs +1 -1
  12. package/web-components-bundle/access-denied/index.js +2 -2
  13. package/web-components-bundle/global-menu/index.cjs +1 -1
  14. package/web-components-bundle/global-menu/index.js +2 -2
  15. package/web-components-bundle/global-topbar/index.cjs +1 -1
  16. package/web-components-bundle/global-topbar/index.js +4 -4
  17. package/web-components-bundle/has-permission/index.cjs +1 -1
  18. package/web-components-bundle/has-permission/index.js +4 -4
  19. package/web-components-bundle/index-090b40a1.cjs +3 -0
  20. package/web-components-bundle/{index-aa69d7f8.js → index-8f3da76f.js} +718 -723
  21. package/web-components-bundle/{index-1db32fa4.cjs → index-94f3fa31.cjs} +80 -80
  22. package/web-components-bundle/{index-e20e66c0.js → index-9b037068.js} +931 -936
  23. package/web-components-bundle/index-9d0c4c92.js +3506 -0
  24. package/web-components-bundle/{index-d3cefb44.cjs → index-c699dba7.cjs} +20 -20
  25. package/web-components-bundle/{react-to-web-component-cf652ce8.js → react-to-web-component-24d28041.js} +652 -645
  26. package/web-components-bundle/{react-to-web-component-fde3f1ba.cjs → react-to-web-component-5d347552.cjs} +9 -9
  27. package/dist/index.module-10fe74a9.js +0 -25593
  28. package/dist/index.module-5858fff5.cjs +0 -1087
  29. package/web-components-bundle/index-433c2a88.cjs +0 -2
  30. package/web-components-bundle/index-f9eb06fc.js +0 -3000
@@ -1,2 +0,0 @@
1
- "use strict";const v=require("./react-to-web-component-fde3f1ba.cjs");function ct(r,e){for(var t=0;t<e.length;t++){const n=e[t];if(typeof n!="string"&&!Array.isArray(n)){for(const i in n)if(i!=="default"&&!(i in r)){const s=Object.getOwnPropertyDescriptor(n,i);s&&Object.defineProperty(r,i,s.get?s:{enumerable:!0,get:()=>n[i]})}}}return Object.freeze(Object.defineProperty(r,Symbol.toStringTag,{value:"Module"}))}function X(r){"@babel/helpers - typeof";return X=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},X(r)}function dt(r,e){if(X(r)!="object"||!r)return r;var t=r[Symbol.toPrimitive];if(t!==void 0){var n=t.call(r,e||"default");if(X(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(r)}function ht(r){var e=dt(r,"string");return X(e)=="symbol"?e:String(e)}function pt(){if(console&&console.warn){for(var r=arguments.length,e=new Array(r),t=0;t<r;t++)e[t]=arguments[t];typeof e[0]=="string"&&(e[0]=`react-i18next:: ${e[0]}`),console.warn(...e)}}const be={};function de(){for(var r=arguments.length,e=new Array(r),t=0;t<r;t++)e[t]=arguments[t];typeof e[0]=="string"&&be[e[0]]||(typeof e[0]=="string"&&(be[e[0]]=new Date),pt(...e))}const Ve=(r,e)=>()=>{if(r.isInitialized)e();else{const t=()=>{setTimeout(()=>{r.off("initialized",t)},0),e()};r.on("initialized",t)}};function ve(r,e,t){r.loadNamespaces(e,Ve(r,t))}function xe(r,e,t,n){typeof t=="string"&&(t=[t]),t.forEach(i=>{r.options.ns.indexOf(i)<0&&r.options.ns.push(i)}),r.loadLanguages(e,Ve(r,n))}function gt(r,e){let t=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};const n=e.languages[0],i=e.options?e.options.fallbackLng:!1,s=e.languages[e.languages.length-1];if(n.toLowerCase()==="cimode")return!0;const o=(a,u)=>{const l=e.services.backendConnector.state[`${a}|${u}`];return l===-1||l===2};return t.bindI18n&&t.bindI18n.indexOf("languageChanging")>-1&&e.services.backendConnector.backend&&e.isLanguageChangingTo&&!o(e.isLanguageChangingTo,r)?!1:!!(e.hasResourceBundle(n,r)||!e.services.backendConnector.backend||e.options.resources&&!e.options.partialBundledLanguages||o(n,r)&&(!i||o(s,r)))}function mt(r,e){let t=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return!e.languages||!e.languages.length?(de("i18n.languages were undefined or empty",e.languages),!0):e.options.ignoreJSONStructure!==void 0?e.hasLoadedNamespace(r,{lng:t.lng,precheck:(i,s)=>{if(t.bindI18n&&t.bindI18n.indexOf("languageChanging")>-1&&i.services.backendConnector.backend&&i.isLanguageChangingTo&&!s(i.isLanguageChangingTo,r))return!1}}):gt(r,e,t)}const yt=/&(?:amp|#38|lt|#60|gt|#62|apos|#39|quot|#34|nbsp|#160|copy|#169|reg|#174|hellip|#8230|#x2F|#47);/g,bt={"&amp;":"&","&#38;":"&","&lt;":"<","&#60;":"<","&gt;":">","&#62;":">","&apos;":"'","&#39;":"'","&quot;":'"',"&#34;":'"',"&nbsp;":" ","&#160;":" ","&copy;":"©","&#169;":"©","&reg;":"®","&#174;":"®","&hellip;":"…","&#8230;":"…","&#x2F;":"/","&#47;":"/"},vt=r=>bt[r],xt=r=>r.replace(yt,vt);let he={bindI18n:"languageChanged",bindI18nStore:"",transEmptyNodeValue:"",transSupportBasicHtmlNodes:!0,transWrapTextNodes:"",transKeepBasicHtmlNodesFor:["br","strong","i","p"],useSuspense:!0,unescape:xt};function wt(){let r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};he={...he,...r}}function St(){return he}let Ke;function Ot(r){Ke=r}function Pt(){return Ke}const Lt={type:"3rdParty",init(r){wt(r.options.react),Ot(r)}},ze=v.reactExports.createContext();class Et{constructor(){this.usedNamespaces={}}addUsedNamespaces(e){e.forEach(t=>{this.usedNamespaces[t]||(this.usedNamespaces[t]=!0)})}getUsedNamespaces(){return Object.keys(this.usedNamespaces)}}const Rt=(r,e)=>{const t=v.reactExports.useRef();return v.reactExports.useEffect(()=>{t.current=e?t.current:r},[r,e]),t.current};function Je(r,e,t,n){return r.getFixedT(e,t,n)}function jt(r,e,t,n){return v.reactExports.useCallback(Je(r,e,t,n),[r,e,t,n])}function kt(r){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};const{i18n:t}=e,{i18n:n,defaultNS:i}=v.reactExports.useContext(ze)||{},s=t||n||Pt();if(s&&!s.reportNamespaces&&(s.reportNamespaces=new Et),!s){de("You will need to pass in an i18next instance by using initReactI18next");const S=(j,L)=>typeof L=="string"?L:L&&typeof L=="object"&&typeof L.defaultValue=="string"?L.defaultValue:Array.isArray(j)?j[j.length-1]:j,R=[S,{},!1];return R.t=S,R.i18n={},R.ready=!1,R}s.options.react&&s.options.react.wait!==void 0&&de("It seems you are still using the old wait option, you may migrate to the new useSuspense behaviour.");const o={...St(),...s.options.react,...e},{useSuspense:a,keyPrefix:u}=o;let l=r||i||s.options&&s.options.defaultNS;l=typeof l=="string"?[l]:l||["translation"],s.reportNamespaces.addUsedNamespaces&&s.reportNamespaces.addUsedNamespaces(l);const f=(s.isInitialized||s.initializedStoreOnce)&&l.every(S=>mt(S,s,o)),h=jt(s,e.lng||null,o.nsMode==="fallback"?l:l[0],u),c=()=>h,g=()=>Je(s,e.lng||null,o.nsMode==="fallback"?l:l[0],u),[y,m]=v.reactExports.useState(c);let w=l.join();e.lng&&(w=`${e.lng}${w}`);const k=Rt(w),E=v.reactExports.useRef(!0);v.reactExports.useEffect(()=>{const{bindI18n:S,bindI18nStore:R}=o;E.current=!0,!f&&!a&&(e.lng?xe(s,e.lng,l,()=>{E.current&&m(g)}):ve(s,l,()=>{E.current&&m(g)})),f&&k&&k!==w&&E.current&&m(g);function j(){E.current&&m(g)}return S&&s&&s.on(S,j),R&&s&&s.store.on(R,j),()=>{E.current=!1,S&&s&&S.split(" ").forEach(L=>s.off(L,j)),R&&s&&R.split(" ").forEach(L=>s.store.off(L,j))}},[s,w]),v.reactExports.useEffect(()=>{E.current&&f&&m(c)},[s,u,f]);const N=[y,s,f];if(N.t=y,N.i18n=s,N.ready=f,f||!f&&!a)return N;throw new Promise(S=>{e.lng?xe(s,e.lng,l,()=>S()):ve(s,l,()=>S())})}function Ct(r){let{i18n:e,defaultNS:t,children:n}=r;const i=v.reactExports.useMemo(()=>({i18n:e,defaultNS:t}),[e,t]);return v.reactExports.createElement(ze.Provider,{value:i},n)}const Nt={type:"logger",log(r){this.output("log",r)},warn(r){this.output("warn",r)},error(r){this.output("error",r)},output(r,e){console&&console[r]&&console[r].apply(console,e)}};class re{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||Nt,this.options=t,this.debug=t.debug}log(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.forward(t,"log","",!0)}warn(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.forward(t,"warn","",!0)}error(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.forward(t,"error","")}deprecate(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.forward(t,"warn","WARNING DEPRECATED: ",!0)}forward(e,t,n,i){return i&&!this.debug?null:(typeof e[0]=="string"&&(e[0]=`${n}${this.prefix} ${e[0]}`),this.logger[t](e))}create(e){return new re(this.logger,{prefix:`${this.prefix}:${e}:`,...this.options})}clone(e){return e=e||this.options,e.prefix=e.prefix||this.prefix,new re(this.logger,e)}}var I=new re;class ue{constructor(){this.observers={}}on(e,t){return e.split(" ").forEach(n=>{this.observers[n]||(this.observers[n]=new Map);const i=this.observers[n].get(t)||0;this.observers[n].set(t,i+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),i=1;i<t;i++)n[i-1]=arguments[i];this.observers[e]&&Array.from(this.observers[e].entries()).forEach(o=>{let[a,u]=o;for(let l=0;l<u;l++)a(...n)}),this.observers["*"]&&Array.from(this.observers["*"].entries()).forEach(o=>{let[a,u]=o;for(let l=0;l<u;l++)a.apply(a,[e,...n])})}}function V(){let r,e;const t=new Promise((n,i)=>{r=n,e=i});return t.resolve=r,t.reject=e,t}function we(r){return r==null?"":""+r}function Tt(r,e,t){r.forEach(n=>{e[n]&&(t[n]=e[n])})}const At=/###/g;function J(r,e,t){function n(a){return a&&a.indexOf("###")>-1?a.replace(At,"."):a}function i(){return!r||typeof r=="string"}const s=typeof e!="string"?e:e.split(".");let o=0;for(;o<s.length-1;){if(i())return{};const a=n(s[o]);!r[a]&&t&&(r[a]=new t),Object.prototype.hasOwnProperty.call(r,a)?r=r[a]:r={},++o}return i()?{}:{obj:r,k:n(s[o])}}function Se(r,e,t){const{obj:n,k:i}=J(r,e,Object);if(n!==void 0||e.length===1){n[i]=t;return}let s=e[e.length-1],o=e.slice(0,e.length-1),a=J(r,o,Object);for(;a.obj===void 0&&o.length;)s=`${o[o.length-1]}.${s}`,o=o.slice(0,o.length-1),a=J(r,o,Object),a&&a.obj&&typeof a.obj[`${a.k}.${s}`]<"u"&&(a.obj=void 0);a.obj[`${a.k}.${s}`]=t}function $t(r,e,t,n){const{obj:i,k:s}=J(r,e,Object);i[s]=i[s]||[],n&&(i[s]=i[s].concat(t)),n||i[s].push(t)}function ie(r,e){const{obj:t,k:n}=J(r,e);if(t)return t[n]}function It(r,e,t){const n=ie(r,t);return n!==void 0?n:ie(e,t)}function Xe(r,e,t){for(const n in e)n!=="__proto__"&&n!=="constructor"&&(n in r?typeof r[n]=="string"||r[n]instanceof String||typeof e[n]=="string"||e[n]instanceof String?t&&(r[n]=e[n]):Xe(r[n],e[n],t):r[n]=e[n]);return r}function H(r){return r.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&")}var Dt={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;","/":"&#x2F;"};function Ft(r){return typeof r=="string"?r.replace(/[&<>"'\/]/g,e=>Dt[e]):r}class Ut{constructor(e){this.capacity=e,this.regExpMap=new Map,this.regExpQueue=[]}getRegExp(e){const t=this.regExpMap.get(e);if(t!==void 0)return t;const 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}}const _t=[" ",",","?","!",";"],Bt=new Ut(20);function Mt(r,e,t){e=e||"",t=t||"";const n=_t.filter(o=>e.indexOf(o)<0&&t.indexOf(o)<0);if(n.length===0)return!0;const i=Bt.getRegExp(`(${n.map(o=>o==="?"?"\\?":o).join("|")})`);let s=!i.test(r);if(!s){const o=r.indexOf(t);o>0&&!i.test(r.substring(0,o))&&(s=!0)}return s}function pe(r,e){let t=arguments.length>2&&arguments[2]!==void 0?arguments[2]:".";if(!r)return;if(r[e])return r[e];const n=e.split(t);let i=r;for(let s=0;s<n.length;){if(!i||typeof i!="object")return;let o,a="";for(let u=s;u<n.length;++u)if(u!==s&&(a+=t),a+=n[u],o=i[a],o!==void 0){if(["string","number","boolean"].indexOf(typeof o)>-1&&u<n.length-1)continue;s+=u-s+1;break}i=o}return i}function se(r){return r&&r.indexOf("_")>0?r.replace("_","-"):r}class Oe extends ue{constructor(e){let t=arguments.length>1&&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){const t=this.options.ns.indexOf(e);t>-1&&this.options.ns.splice(t,1)}getResource(e,t,n){let i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};const s=i.keySeparator!==void 0?i.keySeparator:this.options.keySeparator,o=i.ignoreJSONStructure!==void 0?i.ignoreJSONStructure:this.options.ignoreJSONStructure;let a;e.indexOf(".")>-1?a=e.split("."):(a=[e,t],n&&(Array.isArray(n)?a.push(...n):typeof n=="string"&&s?a.push(...n.split(s)):a.push(n)));const u=ie(this.data,a);return!u&&!t&&!n&&e.indexOf(".")>-1&&(e=a[0],t=a[1],n=a.slice(2).join(".")),u||!o||typeof n!="string"?u:pe(this.data&&this.data[e]&&this.data[e][t],n,s)}addResource(e,t,n,i){let s=arguments.length>4&&arguments[4]!==void 0?arguments[4]:{silent:!1};const o=s.keySeparator!==void 0?s.keySeparator:this.options.keySeparator;let a=[e,t];n&&(a=a.concat(o?n.split(o):n)),e.indexOf(".")>-1&&(a=e.split("."),i=t,t=a[1]),this.addNamespaces(t),Se(this.data,a,i),s.silent||this.emit("added",e,t,n,i)}addResources(e,t,n){let i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{silent:!1};for(const s in n)(typeof n[s]=="string"||Object.prototype.toString.apply(n[s])==="[object Array]")&&this.addResource(e,t,s,n[s],{silent:!0});i.silent||this.emit("added",e,t,n)}addResourceBundle(e,t,n,i,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("."),i=n,n=t,t=a[1]),this.addNamespaces(t);let u=ie(this.data,a)||{};o.skipCopy||(n=JSON.parse(JSON.stringify(n))),i?Xe(u,n,s):u={...u,...n},Se(this.data,a,u),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){const t=this.getDataByLanguage(e);return!!(t&&Object.keys(t)||[]).find(i=>t[i]&&Object.keys(t[i]).length>0)}toJSON(){return this.data}}var Ge={processors:{},addPostProcessor(r){this.processors[r.name]=r},handle(r,e,t,n,i){return r.forEach(s=>{this.processors[s]&&(e=this.processors[s].process(e,t,n,i))}),e}};const Pe={};class oe extends ue{constructor(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};super(),Tt(["resourceStore","languageUtils","pluralResolver","interpolator","backendConnector","i18nFormat","utils"],e,this),this.options=t,this.options.keySeparator===void 0&&(this.options.keySeparator="."),this.logger=I.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;const 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=":");const i=t.keySeparator!==void 0?t.keySeparator:this.options.keySeparator;let s=t.ns||this.options.defaultNS||[];const o=n&&e.indexOf(n)>-1,a=!this.options.userDefinedKeySeparator&&!t.keySeparator&&!this.options.userDefinedNsSeparator&&!t.nsSeparator&&!Mt(e,n,i);if(o&&!a){const u=e.match(this.interpolator.nestingRegexp);if(u&&u.length>0)return{key:e,namespaces:s};const l=e.split(n);(n!==i||n===i&&this.options.ns.indexOf(l[0])>-1)&&(s=l.shift()),e=l.join(i)}return typeof s=="string"&&(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)]);const i=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),u=a[a.length-1],l=t.lng||this.language,f=t.appendNamespaceToCIMode||this.options.appendNamespaceToCIMode;if(l&&l.toLowerCase()==="cimode"){if(f){const S=t.nsSeparator||this.options.nsSeparator;return i?{res:`${u}${S}${o}`,usedKey:o,exactUsedKey:o,usedLng:l,usedNS:u,usedParams:this.getUsedParamsDetails(t)}:`${u}${S}${o}`}return i?{res:o,usedKey:o,exactUsedKey:o,usedLng:l,usedNS:u,usedParams:this.getUsedParamsDetails(t)}:o}const h=this.resolve(e,t);let c=h&&h.res;const g=h&&h.usedKey||o,y=h&&h.exactUsedKey||o,m=Object.prototype.toString.apply(c),w=["[object Number]","[object Function]","[object RegExp]"],k=t.joinArrays!==void 0?t.joinArrays:this.options.joinArrays,E=!this.i18nFormat||this.i18nFormat.handleAsObject;if(E&&c&&(typeof c!="string"&&typeof c!="boolean"&&typeof c!="number")&&w.indexOf(m)<0&&!(typeof k=="string"&&m==="[object Array]")){if(!t.returnObjects&&!this.options.returnObjects){this.options.returnedObjectHandler||this.logger.warn("accessing an object - but returnObjects options is not enabled!");const S=this.options.returnedObjectHandler?this.options.returnedObjectHandler(g,c,{...t,ns:a}):`key '${o} (${this.language})' returned an object instead of string.`;return i?(h.res=S,h.usedParams=this.getUsedParamsDetails(t),h):S}if(s){const S=m==="[object Array]",R=S?[]:{},j=S?y:g;for(const L in c)if(Object.prototype.hasOwnProperty.call(c,L)){const M=`${j}${s}${L}`;R[L]=this.translate(M,{...t,joinArrays:!1,ns:a}),R[L]===M&&(R[L]=c[L])}c=R}}else if(E&&typeof k=="string"&&m==="[object Array]")c=c.join(k),c&&(c=this.extendTranslation(c,e,t,n));else{let S=!1,R=!1;const j=t.count!==void 0&&typeof t.count!="string",L=oe.hasDefaultValue(t),M=j?this.pluralResolver.getSuffix(l,t.count,t):"",$=t.ordinal&&j?this.pluralResolver.getSuffix(l,t.count,{ordinal:!1}):"",Y=j&&!t.ordinal&&t.count===0&&this.pluralResolver.shouldUseIntlApi(),U=Y&&t[`defaultValue${this.options.pluralSeparator}zero`]||t[`defaultValue${M}`]||t[`defaultValue${$}`]||t.defaultValue;!this.isValidLookup(c)&&L&&(S=!0,c=U),this.isValidLookup(c)||(R=!0,c=o);const le=(t.missingKeyNoValueFallbackToKey||this.options.missingKeyNoValueFallbackToKey)&&R?void 0:c,D=L&&U!==c&&this.options.updateMissing;if(R||S||D){if(this.logger.log(D?"updateKey":"missingKey",l,u,o,D?U:c),s){const x=this.resolve(o,{...t,keySeparator:!1});x&&x.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 d=[];const p=this.languageUtils.getFallbackCodes(this.options.fallbackLng,t.lng||this.language);if(this.options.saveMissingTo==="fallback"&&p&&p[0])for(let x=0;x<p.length;x++)d.push(p[x]);else this.options.saveMissingTo==="all"?d=this.languageUtils.toResolveHierarchy(t.lng||this.language):d.push(t.lng||this.language);const b=(x,P,O)=>{const _=L&&O!==c?O:le;this.options.missingKeyHandler?this.options.missingKeyHandler(x,u,P,_,D,t):this.backendConnector&&this.backendConnector.saveMissing&&this.backendConnector.saveMissing(x,u,P,_,D,t),this.emit("missingKey",x,u,P,c)};this.options.saveMissing&&(this.options.saveMissingPlurals&&j?d.forEach(x=>{const P=this.pluralResolver.getSuffixes(x,t);Y&&t[`defaultValue${this.options.pluralSeparator}zero`]&&P.indexOf(`${this.options.pluralSeparator}zero`)<0&&P.push(`${this.options.pluralSeparator}zero`),P.forEach(O=>{b([x],o+O,t[`defaultValue${O}`]||U)})}):b(d,o,U))}c=this.extendTranslation(c,e,t,h,n),R&&c===o&&this.options.appendNamespaceToMissingKey&&(c=`${u}:${o}`),(R||S)&&this.options.parseMissingKeyHandler&&(this.options.compatibilityAPI!=="v1"?c=this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey?`${u}:${o}`:o,S?c:void 0):c=this.options.parseMissingKeyHandler(c))}return i?(h.res=c,h.usedParams=this.getUsedParamsDetails(t),h):c}extendTranslation(e,t,n,i,s){var o=this;if(this.i18nFormat&&this.i18nFormat.parse)e=this.i18nFormat.parse(e,{...this.options.interpolation.defaultVariables,...n},n.lng||this.language||i.usedLng,i.usedNS,i.usedKey,{resolved:i});else if(!n.skipInterpolation){n.interpolation&&this.interpolator.init({...n,interpolation:{...this.options.interpolation,...n.interpolation}});const l=typeof e=="string"&&(n&&n.interpolation&&n.interpolation.skipOnVariables!==void 0?n.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables);let f;if(l){const c=e.match(this.interpolator.nestingRegexp);f=c&&c.length}let h=n.replace&&typeof n.replace!="string"?n.replace:n;if(this.options.interpolation.defaultVariables&&(h={...this.options.interpolation.defaultVariables,...h}),e=this.interpolator.interpolate(e,h,n.lng||this.language,n),l){const c=e.match(this.interpolator.nestingRegexp),g=c&&c.length;f<g&&(n.nest=!1)}!n.lng&&this.options.compatibilityAPI!=="v1"&&i&&i.res&&(n.lng=i.usedLng),n.nest!==!1&&(e=this.interpolator.nest(e,function(){for(var c=arguments.length,g=new Array(c),y=0;y<c;y++)g[y]=arguments[y];return s&&s[0]===g[0]&&!n.context?(o.logger.warn(`It seems you are nesting recursively key: ${g[0]} in key: ${t[0]}`),null):o.translate(...g,t)},n)),n.interpolation&&this.interpolator.reset()}const a=n.postProcess||this.options.postProcess,u=typeof a=="string"?[a]:a;return e!=null&&u&&u.length&&n.applyPostProcessor!==!1&&(e=Ge.handle(u,e,t,this.options&&this.options.postProcessPassResolved?{i18nResolved:{...i,usedParams:this.getUsedParamsDetails(n)},...n}:n,this)),e}resolve(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n,i,s,o,a;return typeof e=="string"&&(e=[e]),e.forEach(u=>{if(this.isValidLookup(n))return;const l=this.extractFromKey(u,t),f=l.key;i=f;let h=l.namespaces;this.options.fallbackNS&&(h=h.concat(this.options.fallbackNS));const c=t.count!==void 0&&typeof t.count!="string",g=c&&!t.ordinal&&t.count===0&&this.pluralResolver.shouldUseIntlApi(),y=t.context!==void 0&&(typeof t.context=="string"||typeof t.context=="number")&&t.context!=="",m=t.lngs?t.lngs:this.languageUtils.toResolveHierarchy(t.lng||this.language,t.fallbackLng);h.forEach(w=>{this.isValidLookup(n)||(a=w,!Pe[`${m[0]}-${w}`]&&this.utils&&this.utils.hasLoadedNamespace&&!this.utils.hasLoadedNamespace(a)&&(Pe[`${m[0]}-${w}`]=!0,this.logger.warn(`key "${i}" for languages "${m.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!!!")),m.forEach(k=>{if(this.isValidLookup(n))return;o=k;const E=[f];if(this.i18nFormat&&this.i18nFormat.addLookupKeys)this.i18nFormat.addLookupKeys(E,f,k,w,t);else{let S;c&&(S=this.pluralResolver.getSuffix(k,t.count,t));const R=`${this.options.pluralSeparator}zero`,j=`${this.options.pluralSeparator}ordinal${this.options.pluralSeparator}`;if(c&&(E.push(f+S),t.ordinal&&S.indexOf(j)===0&&E.push(f+S.replace(j,this.options.pluralSeparator)),g&&E.push(f+R)),y){const L=`${f}${this.options.contextSeparator}${t.context}`;E.push(L),c&&(E.push(L+S),t.ordinal&&S.indexOf(j)===0&&E.push(L+S.replace(j,this.options.pluralSeparator)),g&&E.push(L+R))}}let N;for(;N=E.pop();)this.isValidLookup(n)||(s=N,n=this.getResource(k,w,N,t))}))})}),{res:n,usedKey:i,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 i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};return this.i18nFormat&&this.i18nFormat.getResource?this.i18nFormat.getResource(e,t,n,i):this.resourceStore.getResource(e,t,n,i)}getUsedParamsDetails(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};const t=["defaultValue","ordinal","context","replace","lng","lngs","fallbackLng","ns","keySeparator","nsSeparator","returnObjects","returnDetails","joinArrays","postProcess","interpolation"],n=e.replace&&typeof e.replace!="string";let i=n?e.replace:e;if(n&&typeof e.count<"u"&&(i.count=e.count),this.options.interpolation.defaultVariables&&(i={...this.options.interpolation.defaultVariables,...i}),!n){i={...i};for(const s of t)delete i[s]}return i}static hasDefaultValue(e){const t="defaultValue";for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&t===n.substring(0,t.length)&&e[n]!==void 0)return!0;return!1}}function fe(r){return r.charAt(0).toUpperCase()+r.slice(1)}class Le{constructor(e){this.options=e,this.supportedLngs=this.options.supportedLngs||!1,this.logger=I.create("languageUtils")}getScriptPartFromCode(e){if(e=se(e),!e||e.indexOf("-")<0)return null;const t=e.split("-");return t.length===2||(t.pop(),t[t.length-1].toLowerCase()==="x")?null:this.formatLanguageCode(t.join("-"))}getLanguagePartFromCode(e){if(e=se(e),!e||e.indexOf("-")<0)return e;const t=e.split("-");return this.formatLanguageCode(t[0])}formatLanguageCode(e){if(typeof e=="string"&&e.indexOf("-")>-1){const t=["hans","hant","latn","cyrl","cans","mong","arab"];let n=e.split("-");return this.options.lowerCaseLng?n=n.map(i=>i.toLowerCase()):n.length===2?(n[0]=n[0].toLowerCase(),n[1]=n[1].toUpperCase(),t.indexOf(n[1].toLowerCase())>-1&&(n[1]=fe(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]=fe(n[1].toLowerCase())),t.indexOf(n[2].toLowerCase())>-1&&(n[2]=fe(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;const i=this.formatLanguageCode(n);(!this.options.supportedLngs||this.isSupportedCode(i))&&(t=i)}),!t&&this.options.supportedLngs&&e.forEach(n=>{if(t)return;const i=this.getLanguagePartFromCode(n);if(this.isSupportedCode(i))return t=i;t=this.options.supportedLngs.find(s=>{if(s===i)return s;if(!(s.indexOf("-")<0&&i.indexOf("-")<0)&&(s.indexOf("-")>0&&i.indexOf("-")<0&&s.substring(0,s.indexOf("-"))===i||s.indexOf(i)===0&&i.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)),typeof e=="string"&&(e=[e]),Object.prototype.toString.apply(e)==="[object Array]")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){const n=this.getFallbackCodes(t||this.options.fallbackLng||[],e),i=[],s=o=>{o&&(this.isSupportedCode(o)?i.push(o):this.logger.warn(`rejecting language code not found in supportedLngs: ${o}`))};return typeof e=="string"&&(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))):typeof e=="string"&&s(this.formatLanguageCode(e)),n.forEach(o=>{i.indexOf(o)<0&&s(this.formatLanguageCode(o))}),i}}let Ht=[{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}],qt={1:function(r){return+(r>1)},2:function(r){return+(r!=1)},3:function(r){return 0},4:function(r){return r%10==1&&r%100!=11?0:r%10>=2&&r%10<=4&&(r%100<10||r%100>=20)?1:2},5:function(r){return r==0?0:r==1?1:r==2?2:r%100>=3&&r%100<=10?3:r%100>=11?4:5},6:function(r){return r==1?0:r>=2&&r<=4?1:2},7:function(r){return r==1?0:r%10>=2&&r%10<=4&&(r%100<10||r%100>=20)?1:2},8:function(r){return r==1?0:r==2?1:r!=8&&r!=11?2:3},9:function(r){return+(r>=2)},10:function(r){return r==1?0:r==2?1:r<7?2:r<11?3:4},11:function(r){return r==1||r==11?0:r==2||r==12?1:r>2&&r<20?2:3},12:function(r){return+(r%10!=1||r%100==11)},13:function(r){return+(r!==0)},14:function(r){return r==1?0:r==2?1:r==3?2:3},15:function(r){return r%10==1&&r%100!=11?0:r%10>=2&&(r%100<10||r%100>=20)?1:2},16:function(r){return r%10==1&&r%100!=11?0:r!==0?1:2},17:function(r){return r==1||r%10==1&&r%100!=11?0:1},18:function(r){return r==0?0:r==1?1:2},19:function(r){return r==1?0:r==0||r%100>1&&r%100<11?1:r%100>10&&r%100<20?2:3},20:function(r){return r==1?0:r==0||r%100>0&&r%100<20?1:2},21:function(r){return r%100==1?1:r%100==2?2:r%100==3||r%100==4?3:0},22:function(r){return r==1?0:r==2?1:(r<0||r>10)&&r%10==0?2:3}};const Vt=["v1","v2","v3"],Kt=["v4"],Ee={zero:0,one:1,two:2,few:3,many:4,other:5};function zt(){const r={};return Ht.forEach(e=>{e.lngs.forEach(t=>{r[t]={numbers:e.nr,plurals:qt[e.fc]}})}),r}class Jt{constructor(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.languageUtils=e,this.options=t,this.logger=I.create("pluralResolver"),(!this.options.compatibilityJSON||Kt.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=zt()}addRule(e,t){this.rules[e]=t}getRule(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(this.shouldUseIntlApi())try{return new Intl.PluralRules(se(e==="dev"?"en":e),{type:t.ordinal?"ordinal":"cardinal"})}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]:{};const 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(i=>`${t}${i}`)}getSuffixes(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};const n=this.getRule(e,t);return n?this.shouldUseIntlApi()?n.resolvedOptions().pluralCategories.sort((i,s)=>Ee[i]-Ee[s]).map(i=>`${this.options.prepend}${t.ordinal?`ordinal${this.options.prepend}`:""}${i}`):n.numbers.map(i=>this.getSuffix(e,i,t)):[]}getSuffix(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};const i=this.getRule(e,n);return i?this.shouldUseIntlApi()?`${this.options.prepend}${n.ordinal?`ordinal${this.options.prepend}`:""}${i.select(t)}`:this.getSuffixRetroCompatible(i,t):(this.logger.warn(`no plural rule found for: ${e}`),"")}getSuffixRetroCompatible(e,t){const n=e.noAbs?e.plurals(t):e.plurals(Math.abs(t));let i=e.numbers[n];this.options.simplifyPluralSuffix&&e.numbers.length===2&&e.numbers[0]===1&&(i===2?i="plural":i===1&&(i=""));const s=()=>this.options.prepend&&i.toString()?this.options.prepend+i.toString():i.toString();return this.options.compatibilityJSON==="v1"?i===1?"":typeof i=="number"?`_plural_${i.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!Vt.includes(this.options.compatibilityJSON)}}function Re(r,e,t){let n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:".",i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!0,s=It(r,e,t);return!s&&i&&typeof t=="string"&&(s=pe(r,t,n),s===void 0&&(s=pe(e,t,n))),s}class Xt{constructor(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};this.logger=I.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});const t=e.interpolation;this.escape=t.escape!==void 0?t.escape:Ft,this.escapeValue=t.escapeValue!==void 0?t.escapeValue:!0,this.useRawValueToEscape=t.useRawValueToEscape!==void 0?t.useRawValueToEscape:!1,this.prefix=t.prefix?H(t.prefix):t.prefixEscaped||"{{",this.suffix=t.suffix?H(t.suffix):t.suffixEscaped||"}}",this.formatSeparator=t.formatSeparator?t.formatSeparator:t.formatSeparator||",",this.unescapePrefix=t.unescapeSuffix?"":t.unescapePrefix||"-",this.unescapeSuffix=this.unescapePrefix?"":t.unescapeSuffix||"",this.nestingPrefix=t.nestingPrefix?H(t.nestingPrefix):t.nestingPrefixEscaped||H("$t("),this.nestingSuffix=t.nestingSuffix?H(t.nestingSuffix):t.nestingSuffixEscaped||H(")"),this.nestingOptionsSeparator=t.nestingOptionsSeparator?t.nestingOptionsSeparator:t.nestingOptionsSeparator||",",this.maxReplaces=t.maxReplaces?t.maxReplaces:1e3,this.alwaysFormat=t.alwaysFormat!==void 0?t.alwaysFormat:!1,this.resetRegExp()}reset(){this.options&&this.init(this.options)}resetRegExp(){const 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,i){let s,o,a;const u=this.options&&this.options.interpolation&&this.options.interpolation.defaultVariables||{};function l(y){return y.replace(/\$/g,"$$$$")}const f=y=>{if(y.indexOf(this.formatSeparator)<0){const E=Re(t,u,y,this.options.keySeparator,this.options.ignoreJSONStructure);return this.alwaysFormat?this.format(E,void 0,n,{...i,...t,interpolationkey:y}):E}const m=y.split(this.formatSeparator),w=m.shift().trim(),k=m.join(this.formatSeparator).trim();return this.format(Re(t,u,w,this.options.keySeparator,this.options.ignoreJSONStructure),k,n,{...i,...t,interpolationkey:w})};this.resetRegExp();const h=i&&i.missingInterpolationHandler||this.options.missingInterpolationHandler,c=i&&i.interpolation&&i.interpolation.skipOnVariables!==void 0?i.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables;return[{regex:this.regexpUnescape,safeValue:y=>l(y)},{regex:this.regexp,safeValue:y=>this.escapeValue?l(this.escape(y)):l(y)}].forEach(y=>{for(a=0;s=y.regex.exec(e);){const m=s[1].trim();if(o=f(m),o===void 0)if(typeof h=="function"){const k=h(e,s,i);o=typeof k=="string"?k:""}else if(i&&Object.prototype.hasOwnProperty.call(i,m))o="";else if(c){o=s[0];continue}else this.logger.warn(`missed to pass in variable ${m} for interpolating ${e}`),o="";else typeof o!="string"&&!this.useRawValueToEscape&&(o=we(o));const w=y.safeValue(o);if(e=e.replace(s[0],w),c?(y.regex.lastIndex+=o.length,y.regex.lastIndex-=s[0].length):y.regex.lastIndex=0,a++,a>=this.maxReplaces)break}}),e}nest(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},i,s,o;function a(u,l){const f=this.nestingOptionsSeparator;if(u.indexOf(f)<0)return u;const h=u.split(new RegExp(`${f}[ ]*{`));let c=`{${h[1]}`;u=h[0],c=this.interpolate(c,o);const g=c.match(/'/g),y=c.match(/"/g);(g&&g.length%2===0&&!y||y.length%2!==0)&&(c=c.replace(/'/g,'"'));try{o=JSON.parse(c),l&&(o={...l,...o})}catch(m){return this.logger.warn(`failed parsing options string in nesting for key ${u}`,m),`${u}${f}${c}`}return delete o.defaultValue,u}for(;i=this.nestingRegexp.exec(e);){let u=[];o={...n},o=o.replace&&typeof o.replace!="string"?o.replace:o,o.applyPostProcessor=!1,delete o.defaultValue;let l=!1;if(i[0].indexOf(this.formatSeparator)!==-1&&!/{.*}/.test(i[1])){const f=i[1].split(this.formatSeparator).map(h=>h.trim());i[1]=f.shift(),u=f,l=!0}if(s=t(a.call(this,i[1].trim(),o),o),s&&i[0]===e&&typeof s!="string")return s;typeof s!="string"&&(s=we(s)),s||(this.logger.warn(`missed to resolve ${i[1]} for nesting ${e}`),s=""),l&&(s=u.reduce((f,h)=>this.format(f,h,n.lng,{...n,interpolationkey:i[1].trim()}),s.trim())),e=e.replace(i[0],s),this.regexp.lastIndex=0}return e}}function Gt(r){let e=r.toLowerCase().trim();const t={};if(r.indexOf("(")>-1){const n=r.split("(");e=n[0].toLowerCase().trim();const i=n[1].substring(0,n[1].length-1);e==="currency"&&i.indexOf(":")<0?t.currency||(t.currency=i.trim()):e==="relativetime"&&i.indexOf(":")<0?t.range||(t.range=i.trim()):i.split(";").forEach(o=>{if(!o)return;const[a,...u]=o.split(":"),l=u.join(":").trim().replace(/^'+|'+$/g,"");t[a.trim()]||(t[a.trim()]=l),l==="false"&&(t[a.trim()]=!1),l==="true"&&(t[a.trim()]=!0),isNaN(l)||(t[a.trim()]=parseInt(l,10))})}return{formatName:e,formatOptions:t}}function q(r){const e={};return function(n,i,s){const o=i+JSON.stringify(s);let a=e[o];return a||(a=r(se(i),s),e[o]=a),a(n)}}class Wt{constructor(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};this.logger=I.create("formatter"),this.options=e,this.formats={number:q((t,n)=>{const i=new Intl.NumberFormat(t,{...n});return s=>i.format(s)}),currency:q((t,n)=>{const i=new Intl.NumberFormat(t,{...n,style:"currency"});return s=>i.format(s)}),datetime:q((t,n)=>{const i=new Intl.DateTimeFormat(t,{...n});return s=>i.format(s)}),relativetime:q((t,n)=>{const i=new Intl.RelativeTimeFormat(t,{...n});return s=>i.format(s,n.range||"day")}),list:q((t,n)=>{const i=new Intl.ListFormat(t,{...n});return s=>i.format(s)})},this.init(e)}init(e){const n=(arguments.length>1&&arguments[1]!==void 0?arguments[1]:{interpolation:{}}).interpolation;this.formatSeparator=n.formatSeparator?n.formatSeparator:n.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 i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};return t.split(this.formatSeparator).reduce((a,u)=>{const{formatName:l,formatOptions:f}=Gt(u);if(this.formats[l]){let h=a;try{const c=i&&i.formatParams&&i.formatParams[i.interpolationkey]||{},g=c.locale||c.lng||i.locale||i.lng||n;h=this.formats[l](a,g,{...f,...i,...c})}catch(c){this.logger.warn(c)}return h}else this.logger.warn(`there was no format function for ${l}`);return a},e)}}function Qt(r,e){r.pending[e]!==void 0&&(delete r.pending[e],r.pendingCount--)}class Yt extends ue{constructor(e,t,n){let i=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=i,this.logger=I.create("backendConnector"),this.waitingReads=[],this.maxParallelReads=i.maxParallelReads||10,this.readingCalls=0,this.maxRetries=i.maxRetries>=0?i.maxRetries:5,this.retryTimeout=i.retryTimeout>=1?i.retryTimeout:350,this.state={},this.queue=[],this.backend&&this.backend.init&&this.backend.init(n,i.backend,i)}queueLoad(e,t,n,i){const s={},o={},a={},u={};return e.forEach(l=>{let f=!0;t.forEach(h=>{const c=`${l}|${h}`;!n.reload&&this.store.hasResourceBundle(l,h)?this.state[c]=2:this.state[c]<0||(this.state[c]===1?o[c]===void 0&&(o[c]=!0):(this.state[c]=1,f=!1,o[c]===void 0&&(o[c]=!0),s[c]===void 0&&(s[c]=!0),u[h]===void 0&&(u[h]=!0)))}),f||(a[l]=!0)}),(Object.keys(s).length||Object.keys(o).length)&&this.queue.push({pending:o,pendingCount:Object.keys(o).length,loaded:{},errors:[],callback:i}),{toLoad:Object.keys(s),pending:Object.keys(o),toLoadLanguages:Object.keys(a),toLoadNamespaces:Object.keys(u)}}loaded(e,t,n){const i=e.split("|"),s=i[0],o=i[1];t&&this.emit("failedLoading",s,o,t),n&&this.store.addResourceBundle(s,o,n,void 0,void 0,{skipCopy:!0}),this.state[e]=t?-1:2;const a={};this.queue.forEach(u=>{$t(u.loaded,[s],o),Qt(u,e),t&&u.errors.push(t),u.pendingCount===0&&!u.done&&(Object.keys(u.loaded).forEach(l=>{a[l]||(a[l]={});const f=u.loaded[l];f.length&&f.forEach(h=>{a[l][h]===void 0&&(a[l][h]=!0)})}),u.done=!0,u.errors.length?u.callback(u.errors):u.callback())}),this.emit("loaded",a),this.queue=this.queue.filter(u=>!u.done)}read(e,t,n){let i=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:i,wait:s,callback:o});return}this.readingCalls++;const a=(l,f)=>{if(this.readingCalls--,this.waitingReads.length>0){const h=this.waitingReads.shift();this.read(h.lng,h.ns,h.fcName,h.tried,h.wait,h.callback)}if(l&&f&&i<this.maxRetries){setTimeout(()=>{this.read.call(this,e,t,n,i+1,s*2,o)},s);return}o(l,f)},u=this.backend[n].bind(this.backend);if(u.length===2){try{const l=u(e,t);l&&typeof l.then=="function"?l.then(f=>a(null,f)).catch(a):a(null,l)}catch(l){a(l)}return}return u(e,t,a)}prepareLoading(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},i=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."),i&&i();typeof e=="string"&&(e=this.languageUtils.toResolveHierarchy(e)),typeof t=="string"&&(t=[t]);const s=this.queueLoad(e,t,n,i);if(!s.toLoad.length)return s.pending.length||i(),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]:"";const n=e.split("|"),i=n[0],s=n[1];this.read(i,s,"read",void 0,void 0,(o,a)=>{o&&this.logger.warn(`${t}loading namespace ${s} for language ${i} failed`,o),!o&&a&&this.logger.log(`${t}loaded namespace ${s} for language ${i}`,a),this.loaded(e,o,a)})}saveMissing(e,t,n,i,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){const u={...o,isUpdate:s},l=this.backend.create.bind(this.backend);if(l.length<6)try{let f;l.length===5?f=l(e,t,n,i,u):f=l(e,t,n,i),f&&typeof f.then=="function"?f.then(h=>a(null,h)).catch(a):a(null,f)}catch(f){a(f)}else l(e,t,n,i,a,u)}!e||!e[0]||this.store.addResource(e[0],t,n,i)}}}function je(){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:!1,returnEmptyString:!0,returnObjects:!1,joinArrays:!1,returnedObjectHandler:!1,parseMissingKeyHandler:!1,appendNamespaceToMissingKey:!1,appendNamespaceToCIMode:!1,overloadTranslationOptionHandler:function(e){let t={};if(typeof e[1]=="object"&&(t=e[1]),typeof e[1]=="string"&&(t.defaultValue=e[1]),typeof e[2]=="string"&&(t.tDescription=e[2]),typeof e[2]=="object"||typeof e[3]=="object"){const n=e[3]||e[2];Object.keys(n).forEach(i=>{t[i]=n[i]})}return t},interpolation:{escapeValue:!0,format:r=>r,prefix:"{{",suffix:"}}",formatSeparator:",",unescapePrefix:"-",nestingPrefix:"$t(",nestingSuffix:")",nestingOptionsSeparator:",",maxReplaces:1e3,skipOnVariables:!0}}}function ke(r){return typeof r.ns=="string"&&(r.ns=[r.ns]),typeof r.fallbackLng=="string"&&(r.fallbackLng=[r.fallbackLng]),typeof r.fallbackNS=="string"&&(r.fallbackNS=[r.fallbackNS]),r.supportedLngs&&r.supportedLngs.indexOf("cimode")<0&&(r.supportedLngs=r.supportedLngs.concat(["cimode"])),r}function ee(){}function Zt(r){Object.getOwnPropertyNames(Object.getPrototypeOf(r)).forEach(t=>{typeof r[t]=="function"&&(r[t]=r[t].bind(r))})}class G extends ue{constructor(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;if(super(),this.options=ke(e),this.services={},this.logger=I,this.modules={external:[]},Zt(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&&(typeof t.ns=="string"?t.defaultNS=t.ns:t.ns.indexOf("translation")<0&&(t.defaultNS=t.ns[0]));const i=je();this.options={...i,...this.options,...ke(t)},this.options.compatibilityAPI!=="v1"&&(this.options.interpolation={...i.interpolation,...this.options.interpolation}),t.keySeparator!==void 0&&(this.options.userDefinedKeySeparator=t.keySeparator),t.nsSeparator!==void 0&&(this.options.userDefinedNsSeparator=t.nsSeparator);function s(f){return f?typeof f=="function"?new f:f:null}if(!this.options.isClone){this.modules.logger?I.init(s(this.modules.logger),this.options):I.init(null,this.options);let f;this.modules.formatter?f=this.modules.formatter:typeof Intl<"u"&&(f=Wt);const h=new Le(this.options);this.store=new Oe(this.options.resources,this.options);const c=this.services;c.logger=I,c.resourceStore=this.store,c.languageUtils=h,c.pluralResolver=new Jt(h,{prepend:this.options.pluralSeparator,compatibilityJSON:this.options.compatibilityJSON,simplifyPluralSuffix:this.options.simplifyPluralSuffix}),f&&(!this.options.interpolation.format||this.options.interpolation.format===i.interpolation.format)&&(c.formatter=s(f),c.formatter.init(c,this.options),this.options.interpolation.format=c.formatter.format.bind(c.formatter)),c.interpolator=new Xt(this.options),c.utils={hasLoadedNamespace:this.hasLoadedNamespace.bind(this)},c.backendConnector=new Yt(s(this.modules.backend),c.resourceStore,c,this.options),c.backendConnector.on("*",function(g){for(var y=arguments.length,m=new Array(y>1?y-1:0),w=1;w<y;w++)m[w-1]=arguments[w];e.emit(g,...m)}),this.modules.languageDetector&&(c.languageDetector=s(this.modules.languageDetector),c.languageDetector.init&&c.languageDetector.init(c,this.options.detection,this.options)),this.modules.i18nFormat&&(c.i18nFormat=s(this.modules.i18nFormat),c.i18nFormat.init&&c.i18nFormat.init(this)),this.translator=new oe(this.services,this.options),this.translator.on("*",function(g){for(var y=arguments.length,m=new Array(y>1?y-1:0),w=1;w<y;w++)m[w-1]=arguments[w];e.emit(g,...m)}),this.modules.external.forEach(g=>{g.init&&g.init(this)})}if(this.format=this.options.interpolation.format,n||(n=ee),this.options.fallbackLng&&!this.services.languageDetector&&!this.options.lng){const f=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);f.length>0&&f[0]!=="dev"&&(this.options.lng=f[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(f=>{this[f]=function(){return e.store[f](...arguments)}}),["addResource","addResources","addResourceBundle","removeResourceBundle"].forEach(f=>{this[f]=function(){return e.store[f](...arguments),e}});const u=V(),l=()=>{const f=(h,c)=>{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),u.resolve(c),n(h,c)};if(this.languages&&this.options.compatibilityAPI!=="v1"&&!this.isInitialized)return f(null,this.t.bind(this));this.changeLanguage(this.options.lng,f)};return this.options.resources||!this.options.initImmediate?l():setTimeout(l,0),u}loadResources(e){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:ee;const i=typeof e=="string"?e:this.language;if(typeof e=="function"&&(n=e),!this.options.resources||this.options.partialBundledLanguages){if(i&&i.toLowerCase()==="cimode"&&(!this.options.preload||this.options.preload.length===0))return n();const s=[],o=a=>{if(!a||a==="cimode")return;this.services.languageUtils.toResolveHierarchy(a).forEach(l=>{l!=="cimode"&&s.indexOf(l)<0&&s.push(l)})};i?o(i):this.services.languageUtils.getFallbackCodes(this.options.fallbackLng).forEach(u=>o(u)),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){const i=V();return e||(e=this.languages),t||(t=this.options.ns),n||(n=ee),this.services.backendConnector.reload(e,t,s=>{i.resolve(),n(s)}),i}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"&&Ge.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<this.languages.length;t++){const n=this.languages[t];if(!(["cimode","dev"].indexOf(n)>-1)&&this.store.hasLanguageSomeTranslations(n)){this.resolvedLanguage=n;break}}}changeLanguage(e,t){var n=this;this.isLanguageChangingTo=e;const i=V();this.emit("languageChanging",e);const s=u=>{this.language=u,this.languages=this.services.languageUtils.toResolveHierarchy(u),this.resolvedLanguage=void 0,this.setResolvedLanguage(u)},o=(u,l)=>{l?(s(l),this.translator.changeLanguage(l),this.isLanguageChangingTo=void 0,this.emit("languageChanged",l),this.logger.log("languageChanged",l)):this.isLanguageChangingTo=void 0,i.resolve(function(){return n.t(...arguments)}),t&&t(u,function(){return n.t(...arguments)})},a=u=>{!e&&!u&&this.services.languageDetector&&(u=[]);const l=typeof u=="string"?u:this.services.languageUtils.getBestMatchFromCodes(u);l&&(this.language||s(l),this.translator.language||this.translator.changeLanguage(l),this.services.languageDetector&&this.services.languageDetector.cacheUserLanguage&&this.services.languageDetector.cacheUserLanguage(l)),this.loadResources(l,f=>{o(f,l)})};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),i}getFixedT(e,t,n){var i=this;const s=function(o,a){let u;if(typeof a!="object"){for(var l=arguments.length,f=new Array(l>2?l-2:0),h=2;h<l;h++)f[h-2]=arguments[h];u=i.options.overloadTranslationOptionHandler([o,a].concat(f))}else u={...a};u.lng=u.lng||s.lng,u.lngs=u.lngs||s.lngs,u.ns=u.ns||s.ns,u.keyPrefix=u.keyPrefix||n||s.keyPrefix;const c=i.options.keySeparator||".";let g;return u.keyPrefix&&Array.isArray(o)?g=o.map(y=>`${u.keyPrefix}${c}${y}`):g=u.keyPrefix?`${u.keyPrefix}${c}${o}`:o,i.t(g,u)};return typeof e=="string"?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;const n=t.lng||this.resolvedLanguage||this.languages[0],i=this.options?this.options.fallbackLng:!1,s=this.languages[this.languages.length-1];if(n.toLowerCase()==="cimode")return!0;const o=(a,u)=>{const l=this.services.backendConnector.state[`${a}|${u}`];return l===-1||l===2};if(t.precheck){const 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)&&(!i||o(s,e)))}loadNamespaces(e,t){const n=V();return this.options.ns?(typeof e=="string"&&(e=[e]),e.forEach(i=>{this.options.ns.indexOf(i)<0&&this.options.ns.push(i)}),this.loadResources(i=>{n.resolve(),t&&t(i)}),n):(t&&t(),Promise.resolve())}loadLanguages(e,t){const n=V();typeof e=="string"&&(e=[e]);const i=this.options.preload||[],s=e.filter(o=>i.indexOf(o)<0);return s.length?(this.options.preload=i.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";const 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(je());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 G(e,t)}cloneInstance(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:ee;const n=e.forkResourceStore;n&&delete e.forkResourceStore;const i={...this.options,...e,isClone:!0},s=new G(i);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 Oe(this.store.data,i),s.services.resourceStore=s.store),s.translator=new oe(s.services,i),s.translator.on("*",function(a){for(var u=arguments.length,l=new Array(u>1?u-1:0),f=1;f<u;f++)l[f-1]=arguments[f];s.emit(a,...l)}),s.init(i,t),s.translator.options=i,s.translator.backendConnector.services.utils={hasLoadedNamespace:s.hasLoadedNamespace.bind(s)},s}toJSON(){return{options:this.options,store:this.store,language:this.language,languages:this.languages,resolvedLanguage:this.resolvedLanguage}}}const C=G.createInstance();C.createInstance=G.createInstance;C.createInstance;C.dir;C.init;C.loadResources;C.reloadResources;C.use;C.changeLanguage;C.getFixedT;C.t;C.exists;C.setDefaultNamespace;C.hasLoadedNamespace;C.loadNamespaces;C.loadLanguages;function We(r,e){if(!(r instanceof e))throw new TypeError("Cannot call a class as a function")}function Ce(r,e){for(var t=0;t<e.length;t++){var n=e[t];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(r,ht(n.key),n)}}function Qe(r,e,t){return e&&Ce(r.prototype,e),t&&Ce(r,t),Object.defineProperty(r,"prototype",{writable:!1}),r}var Ye=[],en=Ye.forEach,tn=Ye.slice;function nn(r){return en.call(tn.call(arguments,1),function(e){if(e)for(var t in e)r[t]===void 0&&(r[t]=e[t])}),r}var Ne=/^[\u0009\u0020-\u007e\u0080-\u00ff]+$/,rn=function(e,t,n){var i=n||{};i.path=i.path||"/";var s=encodeURIComponent(t),o="".concat(e,"=").concat(s);if(i.maxAge>0){var a=i.maxAge-0;if(Number.isNaN(a))throw new Error("maxAge should be a Number");o+="; Max-Age=".concat(Math.floor(a))}if(i.domain){if(!Ne.test(i.domain))throw new TypeError("option domain is invalid");o+="; Domain=".concat(i.domain)}if(i.path){if(!Ne.test(i.path))throw new TypeError("option path is invalid");o+="; Path=".concat(i.path)}if(i.expires){if(typeof i.expires.toUTCString!="function")throw new TypeError("option expires is invalid");o+="; Expires=".concat(i.expires.toUTCString())}if(i.httpOnly&&(o+="; HttpOnly"),i.secure&&(o+="; Secure"),i.sameSite){var u=typeof i.sameSite=="string"?i.sameSite.toLowerCase():i.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},Te={create:function(e,t,n,i){var s=arguments.length>4&&arguments[4]!==void 0?arguments[4]:{path:"/",sameSite:"strict"};n&&(s.expires=new Date,s.expires.setTime(s.expires.getTime()+n*60*1e3)),i&&(s.domain=i),document.cookie=rn(e,encodeURIComponent(t),s)},read:function(e){for(var t="".concat(e,"="),n=document.cookie.split(";"),i=0;i<n.length;i++){for(var s=n[i];s.charAt(0)===" ";)s=s.substring(1,s.length);if(s.indexOf(t)===0)return s.substring(t.length,s.length)}return null},remove:function(e){this.create(e,"",-1)}},sn={name:"cookie",lookup:function(e){var t;if(e.lookupCookie&&typeof document<"u"){var n=Te.read(e.lookupCookie);n&&(t=n)}return t},cacheUserLanguage:function(e,t){t.lookupCookie&&typeof document<"u"&&Te.create(t.lookupCookie,e,t.cookieMinutes,t.cookieDomain,t.cookieOptions)}},on={name:"querystring",lookup:function(e){var t;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 i=n.substring(1),s=i.split("&"),o=0;o<s.length;o++){var a=s[o].indexOf("=");if(a>0){var u=s[o].substring(0,a);u===e.lookupQuerystring&&(t=s[o].substring(a+1))}}}return t}},K=null,Ae=function(){if(K!==null)return K;try{K=window!=="undefined"&&window.localStorage!==null;var e="i18next.translate.boo";window.localStorage.setItem(e,"foo"),window.localStorage.removeItem(e)}catch{K=!1}return K},an={name:"localStorage",lookup:function(e){var t;if(e.lookupLocalStorage&&Ae()){var n=window.localStorage.getItem(e.lookupLocalStorage);n&&(t=n)}return t},cacheUserLanguage:function(e,t){t.lookupLocalStorage&&Ae()&&window.localStorage.setItem(t.lookupLocalStorage,e)}},z=null,$e=function(){if(z!==null)return z;try{z=window!=="undefined"&&window.sessionStorage!==null;var e="i18next.translate.boo";window.sessionStorage.setItem(e,"foo"),window.sessionStorage.removeItem(e)}catch{z=!1}return z},un={name:"sessionStorage",lookup:function(e){var t;if(e.lookupSessionStorage&&$e()){var n=window.sessionStorage.getItem(e.lookupSessionStorage);n&&(t=n)}return t},cacheUserLanguage:function(e,t){t.lookupSessionStorage&&$e()&&window.sessionStorage.setItem(t.lookupSessionStorage,e)}},ln={name:"navigator",lookup:function(e){var t=[];if(typeof navigator<"u"){if(navigator.languages)for(var n=0;n<navigator.languages.length;n++)t.push(navigator.languages[n]);navigator.userLanguage&&t.push(navigator.userLanguage),navigator.language&&t.push(navigator.language)}return t.length>0?t:void 0}},fn={name:"htmlTag",lookup:function(e){var t,n=e.htmlTag||(typeof document<"u"?document.documentElement:null);return n&&typeof n.getAttribute=="function"&&(t=n.getAttribute("lang")),t}},cn={name:"path",lookup:function(e){var t;if(typeof window<"u"){var n=window.location.pathname.match(/\/([a-zA-Z-]*)/g);if(n instanceof Array)if(typeof e.lookupFromPathIndex=="number"){if(typeof n[e.lookupFromPathIndex]!="string")return;t=n[e.lookupFromPathIndex].replace("/","")}else t=n[0].replace("/","")}return t}},dn={name:"subdomain",lookup:function(e){var t=typeof e.lookupFromSubdomainIndex=="number"?e.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[t]}};function hn(){return{order:["querystring","cookie","localStorage","sessionStorage","navigator","htmlTag"],lookupQuerystring:"lng",lookupCookie:"i18next",lookupLocalStorage:"i18nextLng",lookupSessionStorage:"i18nextLng",caches:["localStorage"],excludeCacheFor:["cimode"],convertDetectedLanguage:function(e){return e}}}var Ze=function(){function r(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};We(this,r),this.type="languageDetector",this.detectors={},this.init(e,t)}return Qe(r,[{key:"init",value:function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};this.services=t||{languageUtils:{}},this.options=nn(n,this.options||{},hn()),typeof this.options.convertDetectedLanguage=="string"&&this.options.convertDetectedLanguage.indexOf("15897")>-1&&(this.options.convertDetectedLanguage=function(s){return s.replace("-","_")}),this.options.lookupFromUrlIndex&&(this.options.lookupFromPathIndex=this.options.lookupFromUrlIndex),this.i18nOptions=i,this.addDetector(sn),this.addDetector(on),this.addDetector(an),this.addDetector(un),this.addDetector(ln),this.addDetector(fn),this.addDetector(cn),this.addDetector(dn)}},{key:"addDetector",value:function(t){this.detectors[t.name]=t}},{key:"detect",value:function(t){var n=this;t||(t=this.options.order);var i=[];return t.forEach(function(s){if(n.detectors[s]){var o=n.detectors[s].lookup(n.options);o&&typeof o=="string"&&(o=[o]),o&&(i=i.concat(o))}}),i=i.map(function(s){return n.options.convertDetectedLanguage(s)}),this.services.languageUtils.getBestMatchFromCodes?i:i.length>0?i[0]:null}},{key:"cacheUserLanguage",value:function(t,n){var i=this;n||(n=this.options.caches),n&&(this.options.excludeCacheFor&&this.options.excludeCacheFor.indexOf(t)>-1||n.forEach(function(s){i.detectors[s]&&i.detectors[s].cacheUserLanguage(t,i.options)}))}}]),r}();Ze.type="languageDetector";var et=[],pn=et.forEach,gn=et.slice;function mn(r){return pn.call(gn.call(arguments,1),function(e){if(e)for(var t in e)r[t]===void 0&&(r[t]=e[t])}),r}function yn(r){return r?typeof r=="function"?new r:r:null}function bn(){return{handleEmptyResourcesAsFailed:!0,cacheHitMode:"none"}}function Ie(r,e,t,n){var i=r.read.bind(r);if(i.length===2){try{var s=i(e,t);s&&typeof s.then=="function"?s.then(function(o){return n(null,o)}).catch(n):n(null,s)}catch(o){n(o)}return}i(e,t,n)}var tt=function(){function r(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};We(this,r),this.backends=[],this.type="backend",this.allOptions=n,this.init(e,t)}return Qe(r,[{key:"init",value:function(t){var n=this,i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},s=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};this.services=t,this.options=mn(i,this.options||{},bn()),this.allOptions=s,this.options.backends&&this.options.backends.forEach(function(o,a){n.backends[a]=n.backends[a]||yn(o),n.backends[a].init(t,n.options.backendOptions&&n.options.backendOptions[a]||{},s)}),this.services&&this.options.reloadInterval&&setInterval(function(){return n.reload()},this.options.reloadInterval)}},{key:"read",value:function(t,n,i){var s=this,o=this.backends.length,a=function l(f){if(f>=o)return i(new Error("non of the backend loaded data",!0));var h=f===o-1,c=s.options.handleEmptyResourcesAsFailed&&!h?0:-1,g=s.backends[f];g.read?Ie(g,t,n,function(y,m,w){if(!y&&m&&Object.keys(m).length>c){if(i(null,m,f),u(f-1,m),g.save&&s.options.cacheHitMode&&["refresh","refreshAndUpdateStore"].indexOf(s.options.cacheHitMode)>-1){if(w&&s.options.refreshExpirationTime&&w+s.options.refreshExpirationTime>Date.now())return;var k=s.backends[f+1];k&&k.read&&Ie(k,t,n,function(E,N){E||N&&(Object.keys(N).length<=c||(u(f,N),s.options.cacheHitMode==="refreshAndUpdateStore"&&s.services&&s.services.resourceStore&&s.services.resourceStore.addResourceBundle(t,n,N)))})}}else l(f+1)}):l(f+1)},u=function l(f,h){if(!(f<0)){var c=s.backends[f];c.save&&c.save(t,n,h),l(f-1,h)}};a(0)}},{key:"create",value:function(t,n,i,s){var o=arguments.length>4&&arguments[4]!==void 0?arguments[4]:function(){},a=arguments.length>5&&arguments[5]!==void 0?arguments[5]:{};this.backends.forEach(function(u){if(u.create){var l=u.create.bind(u);if(l.length<6){try{var f;l.length===5?f=l(t,n,i,s,a):f=l(t,n,i,s),f&&typeof f.then=="function"?f.then(function(h){return o(null,h)}).catch(o):o(null,f)}catch(h){o(h)}return}l(t,n,i,s,o,a)}})}},{key:"reload",value:function(){var t=this,n=this.services,i=n.backendConnector,s=n.languageUtils,o=n.logger,a=i.language;if(!(a&&a.toLowerCase()==="cimode")){var u=[],l=function(h){var c=s.toResolveHierarchy(h);c.forEach(function(g){u.indexOf(g)<0&&u.push(g)})};l(a),this.allOptions.preload&&this.allOptions.preload.forEach(function(f){return l(f)}),u.forEach(function(f){t.allOptions.ns.forEach(function(h){i.read(f,h,"read",null,null,function(c,g){c&&o.warn("loading namespace ".concat(h," for language ").concat(f," failed"),c),!c&&g&&o.log("loaded namespace ".concat(h," for language ").concat(f),g),i.loaded("".concat(f,"|").concat(h),c,g)})})})}}}]),r}();tt.type="backend";function ge(r){"@babel/helpers - typeof";return ge=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},ge(r)}function nt(){return typeof XMLHttpRequest=="function"||(typeof XMLHttpRequest>"u"?"undefined":ge(XMLHttpRequest))==="object"}function vn(r){return!!r&&typeof r.then=="function"}function xn(r){return vn(r)?r:Promise.resolve(r)}function wn(r){throw new Error('Could not dynamically require "'+r+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var me={exports:{}},te={exports:{}},De;function Sn(){return De||(De=1,function(r,e){var t=typeof globalThis<"u"&&globalThis||typeof self<"u"&&self||typeof v.commonjsGlobal<"u"&&v.commonjsGlobal,n=function(){function s(){this.fetch=!1,this.DOMException=t.DOMException}return s.prototype=t,new s}();(function(s){(function(o){var a=typeof s<"u"&&s||typeof self<"u"&&self||typeof a<"u"&&a,u={searchParams:"URLSearchParams"in a,iterable:"Symbol"in a&&"iterator"in Symbol,blob:"FileReader"in a&&"Blob"in a&&function(){try{return new Blob,!0}catch{return!1}}(),formData:"FormData"in a,arrayBuffer:"ArrayBuffer"in a};function l(d){return d&&DataView.prototype.isPrototypeOf(d)}if(u.arrayBuffer)var f=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],h=ArrayBuffer.isView||function(d){return d&&f.indexOf(Object.prototype.toString.call(d))>-1};function c(d){if(typeof d!="string"&&(d=String(d)),/[^a-z0-9\-#$%&'*+.^_`|~!]/i.test(d)||d==="")throw new TypeError('Invalid character in header field name: "'+d+'"');return d.toLowerCase()}function g(d){return typeof d!="string"&&(d=String(d)),d}function y(d){var p={next:function(){var b=d.shift();return{done:b===void 0,value:b}}};return u.iterable&&(p[Symbol.iterator]=function(){return p}),p}function m(d){this.map={},d instanceof m?d.forEach(function(p,b){this.append(b,p)},this):Array.isArray(d)?d.forEach(function(p){this.append(p[0],p[1])},this):d&&Object.getOwnPropertyNames(d).forEach(function(p){this.append(p,d[p])},this)}m.prototype.append=function(d,p){d=c(d),p=g(p);var b=this.map[d];this.map[d]=b?b+", "+p:p},m.prototype.delete=function(d){delete this.map[c(d)]},m.prototype.get=function(d){return d=c(d),this.has(d)?this.map[d]:null},m.prototype.has=function(d){return this.map.hasOwnProperty(c(d))},m.prototype.set=function(d,p){this.map[c(d)]=g(p)},m.prototype.forEach=function(d,p){for(var b in this.map)this.map.hasOwnProperty(b)&&d.call(p,this.map[b],b,this)},m.prototype.keys=function(){var d=[];return this.forEach(function(p,b){d.push(b)}),y(d)},m.prototype.values=function(){var d=[];return this.forEach(function(p){d.push(p)}),y(d)},m.prototype.entries=function(){var d=[];return this.forEach(function(p,b){d.push([b,p])}),y(d)},u.iterable&&(m.prototype[Symbol.iterator]=m.prototype.entries);function w(d){if(d.bodyUsed)return Promise.reject(new TypeError("Already read"));d.bodyUsed=!0}function k(d){return new Promise(function(p,b){d.onload=function(){p(d.result)},d.onerror=function(){b(d.error)}})}function E(d){var p=new FileReader,b=k(p);return p.readAsArrayBuffer(d),b}function N(d){var p=new FileReader,b=k(p);return p.readAsText(d),b}function S(d){for(var p=new Uint8Array(d),b=new Array(p.length),x=0;x<p.length;x++)b[x]=String.fromCharCode(p[x]);return b.join("")}function R(d){if(d.slice)return d.slice(0);var p=new Uint8Array(d.byteLength);return p.set(new Uint8Array(d)),p.buffer}function j(){return this.bodyUsed=!1,this._initBody=function(d){this.bodyUsed=this.bodyUsed,this._bodyInit=d,d?typeof d=="string"?this._bodyText=d:u.blob&&Blob.prototype.isPrototypeOf(d)?this._bodyBlob=d:u.formData&&FormData.prototype.isPrototypeOf(d)?this._bodyFormData=d:u.searchParams&&URLSearchParams.prototype.isPrototypeOf(d)?this._bodyText=d.toString():u.arrayBuffer&&u.blob&&l(d)?(this._bodyArrayBuffer=R(d.buffer),this._bodyInit=new Blob([this._bodyArrayBuffer])):u.arrayBuffer&&(ArrayBuffer.prototype.isPrototypeOf(d)||h(d))?this._bodyArrayBuffer=R(d):this._bodyText=d=Object.prototype.toString.call(d):this._bodyText="",this.headers.get("content-type")||(typeof d=="string"?this.headers.set("content-type","text/plain;charset=UTF-8"):this._bodyBlob&&this._bodyBlob.type?this.headers.set("content-type",this._bodyBlob.type):u.searchParams&&URLSearchParams.prototype.isPrototypeOf(d)&&this.headers.set("content-type","application/x-www-form-urlencoded;charset=UTF-8"))},u.blob&&(this.blob=function(){var d=w(this);if(d)return d;if(this._bodyBlob)return Promise.resolve(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(new Blob([this._bodyArrayBuffer]));if(this._bodyFormData)throw new Error("could not read FormData body as blob");return Promise.resolve(new Blob([this._bodyText]))},this.arrayBuffer=function(){if(this._bodyArrayBuffer){var d=w(this);return d||(ArrayBuffer.isView(this._bodyArrayBuffer)?Promise.resolve(this._bodyArrayBuffer.buffer.slice(this._bodyArrayBuffer.byteOffset,this._bodyArrayBuffer.byteOffset+this._bodyArrayBuffer.byteLength)):Promise.resolve(this._bodyArrayBuffer))}else return this.blob().then(E)}),this.text=function(){var d=w(this);if(d)return d;if(this._bodyBlob)return N(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(S(this._bodyArrayBuffer));if(this._bodyFormData)throw new Error("could not read FormData body as text");return Promise.resolve(this._bodyText)},u.formData&&(this.formData=function(){return this.text().then(Y)}),this.json=function(){return this.text().then(JSON.parse)},this}var L=["DELETE","GET","HEAD","OPTIONS","POST","PUT"];function M(d){var p=d.toUpperCase();return L.indexOf(p)>-1?p:d}function $(d,p){if(!(this instanceof $))throw new TypeError('Please use the "new" operator, this DOM object constructor cannot be called as a function.');p=p||{};var b=p.body;if(d instanceof $){if(d.bodyUsed)throw new TypeError("Already read");this.url=d.url,this.credentials=d.credentials,p.headers||(this.headers=new m(d.headers)),this.method=d.method,this.mode=d.mode,this.signal=d.signal,!b&&d._bodyInit!=null&&(b=d._bodyInit,d.bodyUsed=!0)}else this.url=String(d);if(this.credentials=p.credentials||this.credentials||"same-origin",(p.headers||!this.headers)&&(this.headers=new m(p.headers)),this.method=M(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")&&b)throw new TypeError("Body not allowed for GET or HEAD requests");if(this._initBody(b),(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 P=/\?/;this.url+=(P.test(this.url)?"&":"?")+"_="+new Date().getTime()}}}$.prototype.clone=function(){return new $(this,{body:this._bodyInit})};function Y(d){var p=new FormData;return d.trim().split("&").forEach(function(b){if(b){var x=b.split("="),P=x.shift().replace(/\+/g," "),O=x.join("=").replace(/\+/g," ");p.append(decodeURIComponent(P),decodeURIComponent(O))}}),p}function U(d){var p=new m,b=d.replace(/\r?\n[\t ]+/g," ");return b.split("\r").map(function(x){return x.indexOf(`
2
- `)===0?x.substr(1,x.length):x}).forEach(function(x){var P=x.split(":"),O=P.shift().trim();if(O){var _=P.join(":").trim();p.append(O,_)}}),p}j.call($.prototype);function T(d,p){if(!(this instanceof T))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 m(p.headers),this.url=p.url||"",this._initBody(d)}j.call(T.prototype),T.prototype.clone=function(){return new T(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new m(this.headers),url:this.url})},T.error=function(){var d=new T(null,{status:0,statusText:""});return d.type="error",d};var le=[301,302,303,307,308];T.redirect=function(d,p){if(le.indexOf(p)===-1)throw new RangeError("Invalid status code");return new T(null,{status:p,headers:{location:d}})},o.DOMException=a.DOMException;try{new o.DOMException}catch{o.DOMException=function(p,b){this.message=p,this.name=b;var x=Error(p);this.stack=x.stack},o.DOMException.prototype=Object.create(Error.prototype),o.DOMException.prototype.constructor=o.DOMException}function D(d,p){return new Promise(function(b,x){var P=new $(d,p);if(P.signal&&P.signal.aborted)return x(new o.DOMException("Aborted","AbortError"));var O=new XMLHttpRequest;function _(){O.abort()}O.onload=function(){var A={status:O.status,statusText:O.statusText,headers:U(O.getAllResponseHeaders()||"")};A.url="responseURL"in O?O.responseURL:A.headers.get("X-Request-URL");var Z="response"in O?O.response:O.responseText;setTimeout(function(){b(new T(Z,A))},0)},O.onerror=function(){setTimeout(function(){x(new TypeError("Network request failed"))},0)},O.ontimeout=function(){setTimeout(function(){x(new TypeError("Network request failed"))},0)},O.onabort=function(){setTimeout(function(){x(new o.DOMException("Aborted","AbortError"))},0)};function ft(A){try{return A===""&&a.location.href?a.location.href:A}catch{return A}}O.open(P.method,ft(P.url),!0),P.credentials==="include"?O.withCredentials=!0:P.credentials==="omit"&&(O.withCredentials=!1),"responseType"in O&&(u.blob?O.responseType="blob":u.arrayBuffer&&P.headers.get("Content-Type")&&P.headers.get("Content-Type").indexOf("application/octet-stream")!==-1&&(O.responseType="arraybuffer")),p&&typeof p.headers=="object"&&!(p.headers instanceof m)?Object.getOwnPropertyNames(p.headers).forEach(function(A){O.setRequestHeader(A,g(p.headers[A]))}):P.headers.forEach(function(A,Z){O.setRequestHeader(Z,A)}),P.signal&&(P.signal.addEventListener("abort",_),O.onreadystatechange=function(){O.readyState===4&&P.signal.removeEventListener("abort",_)}),O.send(typeof P._bodyInit>"u"?null:P._bodyInit)})}return D.polyfill=!0,a.fetch||(a.fetch=D,a.Headers=m,a.Request=$,a.Response=T),o.Headers=m,o.Request=$,o.Response=T,o.fetch=D,o})({})})(n),n.fetch.ponyfill=!0,delete n.fetch.polyfill;var i=t.fetch?t:n;e=i.fetch,e.default=i.fetch,e.fetch=i.fetch,e.Headers=i.Headers,e.Request=i.Request,e.Response=i.Response,r.exports=e}(te,te.exports)),te.exports}(function(r,e){var t;if(typeof fetch=="function"&&(typeof v.commonjsGlobal<"u"&&v.commonjsGlobal.fetch?t=v.commonjsGlobal.fetch:typeof window<"u"&&window.fetch?t=window.fetch:t=fetch),typeof wn<"u"&&(typeof window>"u"||typeof window.document>"u")){var n=t||Sn();n.default&&(n=n.default),e.default=n,r.exports=e.default}})(me,me.exports);var rt=me.exports;const it=v.getDefaultExportFromCjs(rt),Fe=ct({__proto__:null,default:it},[rt]);function Ue(r,e){var t=Object.keys(r);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(r);e&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(r,i).enumerable})),t.push.apply(t,n)}return t}function _e(r){for(var e=1;e<arguments.length;e++){var t=arguments[e]!=null?arguments[e]:{};e%2?Ue(Object(t),!0).forEach(function(n){On(r,n,t[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(t)):Ue(Object(t)).forEach(function(n){Object.defineProperty(r,n,Object.getOwnPropertyDescriptor(t,n))})}return r}function On(r,e,t){return e=Pn(e),e in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}function Pn(r){var e=Ln(r,"string");return B(e)=="symbol"?e:String(e)}function Ln(r,e){if(B(r)!="object"||!r)return r;var t=r[Symbol.toPrimitive];if(t!==void 0){var n=t.call(r,e||"default");if(B(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(r)}function B(r){"@babel/helpers - typeof";return B=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},B(r)}var F;typeof fetch=="function"&&(typeof global<"u"&&global.fetch?F=global.fetch:typeof window<"u"&&window.fetch?F=window.fetch:F=fetch);var W;nt()&&(typeof global<"u"&&global.XMLHttpRequest?W=global.XMLHttpRequest:typeof window<"u"&&window.XMLHttpRequest&&(W=window.XMLHttpRequest));var ae;typeof ActiveXObject=="function"&&(typeof global<"u"&&global.ActiveXObject?ae=global.ActiveXObject:typeof window<"u"&&window.ActiveXObject&&(ae=window.ActiveXObject));!F&&Fe&&!W&&!ae&&(F=it||Fe);typeof F!="function"&&(F=void 0);var ye=function(e,t){if(t&&B(t)==="object"){var n="";for(var i in t)n+="&"+encodeURIComponent(i)+"="+encodeURIComponent(t[i]);if(!n)return e;e=e+(e.indexOf("?")!==-1?"&":"?")+n.slice(1)}return e},Be=function(e,t,n,i){var s=function(u){if(!u.ok)return n(u.statusText||"Error",{status:u.status});u.text().then(function(l){n(null,{status:u.status,data:l})}).catch(n)};if(i){var o=i(e,t);if(o instanceof Promise){o.then(s).catch(n);return}}typeof fetch=="function"?fetch(e,t).then(s).catch(n):F(e,t).then(s).catch(n)},Me=!1,En=function(e,t,n,i){e.queryStringParams&&(t=ye(t,e.queryStringParams));var s=_e({},typeof e.customHeaders=="function"?e.customHeaders():e.customHeaders);typeof window>"u"&&typeof global<"u"&&typeof global.process<"u"&&global.process.versions&&global.process.versions.node&&(s["User-Agent"]="i18next-http-backend (node/".concat(global.process.version,"; ").concat(global.process.platform," ").concat(global.process.arch,")")),n&&(s["Content-Type"]="application/json");var o=typeof e.requestOptions=="function"?e.requestOptions(n):e.requestOptions,a=_e({method:n?"POST":"GET",body:n?e.stringify(n):void 0,headers:s},Me?{}:o),u=typeof e.alternateFetch=="function"&&e.alternateFetch.length>=1?e.alternateFetch:void 0;try{Be(t,a,i,u)}catch(l){if(!o||Object.keys(o).length===0||!l.message||l.message.indexOf("not implemented")<0)return i(l);try{Object.keys(o).forEach(function(f){delete a[f]}),Be(t,a,i,u),Me=!0}catch(f){i(f)}}},Rn=function(e,t,n,i){n&&B(n)==="object"&&(n=ye("",n).slice(1)),e.queryStringParams&&(t=ye(t,e.queryStringParams));try{var s;W?s=new W:s=new ae("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&&i(s.status>=400?s.statusText:null,{status:s.status,data:s.responseText})},s.send(n)}catch(u){console&&console.log(u)}},jn=function(e,t,n,i){if(typeof n=="function"&&(i=n,n=void 0),i=i||function(){},F&&t.indexOf("file:")!==0)return En(e,t,n,i);if(nt()||typeof ActiveXObject=="function")return Rn(e,t,n,i);i(new Error("No fetch and no xhr implementation found!"))};function Q(r){"@babel/helpers - typeof";return Q=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},Q(r)}function He(r,e){var t=Object.keys(r);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(r);e&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(r,i).enumerable})),t.push.apply(t,n)}return t}function ce(r){for(var e=1;e<arguments.length;e++){var t=arguments[e]!=null?arguments[e]:{};e%2?He(Object(t),!0).forEach(function(n){st(r,n,t[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(t)):He(Object(t)).forEach(function(n){Object.defineProperty(r,n,Object.getOwnPropertyDescriptor(t,n))})}return r}function kn(r,e){if(!(r instanceof e))throw new TypeError("Cannot call a class as a function")}function qe(r,e){for(var t=0;t<e.length;t++){var n=e[t];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(r,ot(n.key),n)}}function Cn(r,e,t){return e&&qe(r.prototype,e),t&&qe(r,t),Object.defineProperty(r,"prototype",{writable:!1}),r}function st(r,e,t){return e=ot(e),e in r?Object.defineProperty(r,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):r[e]=t,r}function ot(r){var e=Nn(r,"string");return Q(e)=="symbol"?e:String(e)}function Nn(r,e){if(Q(r)!="object"||!r)return r;var t=r[Symbol.toPrimitive];if(t!==void 0){var n=t.call(r,e||"default");if(Q(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(r)}var Tn=function(){return{loadPath:"/locales/{{lng}}/{{ns}}.json",addPath:"/locales/add/{{lng}}/{{ns}}",parse:function(t){return JSON.parse(t)},stringify:JSON.stringify,parsePayload:function(t,n,i){return st({},n,i||"")},parseLoadPayload:function(t,n){},request:jn,reloadInterval:typeof window<"u"?!1:60*60*1e3,customHeaders:{},queryStringParams:{},crossDomain:!1,withCredentials:!1,overrideMimeType:!1,requestOptions:{mode:"cors",credentials:"same-origin",cache:"default"}}},at=function(){function r(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};kn(this,r),this.services=e,this.options=t,this.allOptions=n,this.type="backend",this.init(e,t,n)}return Cn(r,[{key:"init",value:function(t){var n=this,i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},s=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};this.services=t,this.options=ce(ce(ce({},Tn()),this.options||{}),i),this.allOptions=s,this.services&&this.options.reloadInterval&&setInterval(function(){return n.reload()},this.options.reloadInterval)}},{key:"readMulti",value:function(t,n,i){this._readAny(t,t,n,n,i)}},{key:"read",value:function(t,n,i){this._readAny([t],t,[n],n,i)}},{key:"_readAny",value:function(t,n,i,s,o){var a=this,u=this.options.loadPath;typeof this.options.loadPath=="function"&&(u=this.options.loadPath(t,i)),u=xn(u),u.then(function(l){if(!l)return o(null,{});var f=a.services.interpolator.interpolate(l,{lng:t.join("+"),ns:i.join("+")});a.loadUrl(f,o,n,s)})}},{key:"loadUrl",value:function(t,n,i,s){var o=this,a=typeof i=="string"?[i]:i,u=typeof s=="string"?[s]:s,l=this.options.parseLoadPayload(a,u);this.options.request(this.options,t,l,function(f,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&&f&&f.message&&f.message.indexOf("Failed to fetch")>-1)return n("failed loading "+t+": "+f.message,!0);if(f)return n(f,!1);var c,g;try{typeof h.data=="string"?c=o.options.parse(h.data,i,s):c=h.data}catch{g="failed parsing "+t+" to json"}if(g)return n(g,!1);n(null,c)})}},{key:"create",value:function(t,n,i,s,o){var a=this;if(this.options.addPath){typeof t=="string"&&(t=[t]);var u=this.options.parsePayload(n,i,s),l=0,f=[],h=[];t.forEach(function(c){var g=a.options.addPath;typeof a.options.addPath=="function"&&(g=a.options.addPath(c,n));var y=a.services.interpolator.interpolate(g,{lng:c,ns:n});a.options.request(a.options,y,u,function(m,w){l+=1,f.push(m),h.push(w),l===t.length&&typeof o=="function"&&o(f,h)})})}}},{key:"reload",value:function(){var t=this,n=this.services,i=n.backendConnector,s=n.languageUtils,o=n.logger,a=i.language;if(!(a&&a.toLowerCase()==="cimode")){var u=[],l=function(h){var c=s.toResolveHierarchy(h);c.forEach(function(g){u.indexOf(g)<0&&u.push(g)})};l(a),this.allOptions.preload&&this.allOptions.preload.forEach(function(f){return l(f)}),u.forEach(function(f){t.allOptions.ns.forEach(function(h){i.read(f,h,"read",null,null,function(c,g){c&&o.warn("loading namespace ".concat(h," for language ").concat(f," failed"),c),!c&&g&&o.log("loaded namespace ".concat(h," for language ").concat(f),g),i.loaded("".concat(f,"|").concat(h),c,g)})})})}}}]),r}();at.type="backend";var ut=(r=>(r.en="en",r.de="de",r))(ut||{});C.use(tt).use(Lt).use(Ze).init({initImmediate:!0,fallbackLng:"en",backend:{backends:[at],backendOptions:[{loadPath:"https://ukpcsaprod.blob.core.windows.net/lib/translations/{{lng}}/{{ns}}.json",crossDomain:!0}]}});const ne={"page-container":"_page-container_6iqty_1","page-main-content":"_page-main-content_6iqty_8","page-title":"_page-title_6iqty_19","text-base":"_text-base_6iqty_25","mt-4":"_mt-4_6iqty_32"},lt=()=>{const{t:r}=kt();return v.jsxRuntimeExports.jsx("div",{className:"unauth__container "+ne["page-container"],children:v.jsxRuntimeExports.jsxs("div",{className:"unauth__main-content "+ne["page-main-content"],children:[v.jsxRuntimeExports.jsx(An,{}),v.jsxRuntimeExports.jsxs("div",{className:"unauth__main-text flex flex-col gap-[8px] items-center justify-center text-center",children:[v.jsxRuntimeExports.jsx("h2",{className:"unauth__main-text__title "+ne["page-title"],children:r("components.unauthorizedPage.title")}),v.jsxRuntimeExports.jsxs("p",{className:"unauth__main-text__desc "+ne["text-base"],children:[r("components.unauthorizedPage.description1")," ",v.jsxRuntimeExports.jsx("br",{})," ",r("components.unauthorizedPage.description2")]})]})]})})},An=()=>v.jsxRuntimeExports.jsxs("svg",{width:"61",height:"60",viewBox:"0 0 61 60",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[v.jsxRuntimeExports.jsxs("g",{filter:"url(#filter0_d_10800_50471)",children:[v.jsxRuntimeExports.jsx("rect",{x:"2.5",y:"1",width:"56",height:"56",rx:"28",fill:"white"}),v.jsxRuntimeExports.jsx("path",{d:"M24.6667 27.833V23.1663C24.6667 21.6192 25.2812 20.1355 26.3752 19.0416C27.4692 17.9476 28.9529 17.333 30.5 17.333C32.0471 17.333 33.5308 17.9476 34.6248 19.0416C35.7188 20.1355 36.3333 21.6192 36.3333 23.1663V27.833M22.3333 27.833H38.6667C39.9553 27.833 41 28.8777 41 30.1663V38.333C41 39.6217 39.9553 40.6663 38.6667 40.6663H22.3333C21.0447 40.6663 20 39.6217 20 38.333V30.1663C20 28.8777 21.0447 27.833 22.3333 27.833Z",stroke:"#292929","stroke-width":"2.33333","stroke-linecap":"round","stroke-linejoin":"round"})]}),v.jsxRuntimeExports.jsx("defs",{children:v.jsxRuntimeExports.jsxs("filter",{id:"filter0_d_10800_50471",x:"0.5",y:"0",width:"60",height:"60",filterUnits:"userSpaceOnUse","color-interpolation-filters":"sRGB",children:[v.jsxRuntimeExports.jsx("feFlood",{"flood-opacity":"0",result:"BackgroundImageFix"}),v.jsxRuntimeExports.jsx("feColorMatrix",{in:"SourceAlpha",type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),v.jsxRuntimeExports.jsx("feOffset",{dy:"1"}),v.jsxRuntimeExports.jsx("feGaussianBlur",{stdDeviation:"1"}),v.jsxRuntimeExports.jsx("feColorMatrix",{type:"matrix",values:"0 0 0 0 0.0627451 0 0 0 0 0.0941176 0 0 0 0 0.156863 0 0 0 0.05 0"}),v.jsxRuntimeExports.jsx("feBlend",{mode:"normal",in2:"BackgroundImageFix",result:"effect1_dropShadow_10800_50471"}),v.jsxRuntimeExports.jsx("feBlend",{mode:"normal",in:"SourceGraphic",in2:"effect1_dropShadow_10800_50471",result:"shape"})]})})]});function $n(){return v.jsxRuntimeExports.jsx(Ct,{i18n:C,children:v.jsxRuntimeExports.jsx(lt,{})})}{const r=v.s($n);customElements.define("access-denied",r)}exports.Language=ut;exports.UnauthorizedPage=lt;exports.instance=C;