@ukpc-lib/react 0.5.7 → 0.5.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/index.cjs +1 -1
- package/dist/components/index.js +2 -2
- package/dist/{index.module-deeaebfb.cjs → index.module-552a8ab7.cjs} +1 -1
- package/dist/{index.module-f34dfa18.js → index.module-7c688197.js} +2 -2
- package/dist/share/index.cjs +1 -1
- package/dist/share/index.js +1 -1
- package/package.json +1 -1
- package/web-components-bundle/favorite-menu/index.js +1 -1
- package/web-components-bundle/global-menu/index.js +1 -1
- package/web-components-bundle/global-topbar/index.js +1 -1
- package/web-components-bundle/has-permission/index.js +1 -1
- package/web-components-bundle/{index-0d90cafb.js → index-65501d23.js} +9396 -9399
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
var m9=require("./index.css");const st=require("react/jsx-runtime"),Q=require("react"),DI=require("axios"),PI=require("moment"),_c=require("@mui/material"),Sd=require("react-query");require("@r2wc/react-to-web-component");const x1=require("react-router-dom"),S1=require("react-dom");function _I(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}function RI(e,t){for(var n=0;n<t.length;n++){const r=t[n];if(typeof r!="string"&&!Array.isArray(r)){for(const i in r)if(i!=="default"&&!(i in e)){const o=Object.getOwnPropertyDescriptor(r,i);o&&Object.defineProperty(e,i,o.get?o:{enumerable:!0,get:()=>r[i]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}const Sn=_I(Q),II=`.modal-overlay{z-index:1300;position:fixed;top:0;right:0;bottom:0;left:0;background:hsla(0,0%,0%,.254);--tw-backdrop-blur: blur(4px);justify-content:center;align-items:center;-webkit-backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia)}.modal-title{font-size:1.25rem;line-height:1.75rem;color:#e01b00;font-weight:500}.modal-footer{display:flex;justify-content:space-between;width:80%}.modal-container{background:#ffffff;-webkit-backdrop-filter:blur(4.5px);backdrop-filter:blur(4.5px);display:flex;padding:32px 24px 40px;flex-direction:column;align-items:center;gap:24px;align-self:stretch;width:500px;height:204px;position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);border-radius:.5rem}.modal-button{border-radius:3px;border:1px solid #ddd;background:#ddd;padding:8px 32px;font-size:14px;transition:background-color .25s cubic-bezier(.4,0,.2,1) 0ms,box-shadow .25s cubic-bezier(.4,0,.2,1) 0ms,border-color .25s cubic-bezier(.4,0,.2,1) 0ms,color .25s cubic-bezier(.4,0,.2,1) 0ms}.cancel-btn:hover{background:#C5C5C5}.confirm-btn{background:#e01b00!important}.confirm-btn:hover{background:#BE1700!important}.text-white{color:#fff}.text-sm{font-size:.875rem;line-height:1.25rem}
|
|
2
2
|
`;function T1({isOpen:e,onClose:t,onConfirm:n}){if(!e)return null;function r(i){var o;((o=i.target)==null?void 0:o.id)==="modal-wrapper"&&t()}return st.jsxs(st.Fragment,{children:[st.jsx("style",{type:"text/css",children:II}),st.jsx("div",{onClick:r,className:"modal-overlay",id:"modal-wrapper",children:st.jsxs("div",{className:"modal-container",children:[st.jsx("h3",{className:"modal-title",children:"Log out"}),st.jsx("p",{className:"text-sm",children:"Are you sure want to log out?"}),st.jsxs("div",{className:"modal-footer",children:[st.jsx("button",{className:"modal-button cancel-btn",onClick:t,children:"Cancel"}),st.jsx("button",{onClick:n,className:"text-white confirm-btn modal-button",children:"Confirm"})]})]})})]})}const so={primary100:"#F0F6E1",primary200:"#E5F5ED",primary300:"#93D500",primary400:"#009D4F",primary500:"#2E7D32",secondary:"#CC0066",secondaryDark:"#AE1857",textPrimary:"#292929",white:"#FFFFFF",grey100:"#FAFAFA",grey200:"#EEEEEE",grey300:"#DDDDDD",grey400:"#C5C5C5",grey500:"#BFBFBF",grey600:"#85858A",success:"#009D4F",successLight:"#E5F5ED",warning:"#FFB600",warningLight:"#FFF8E5",danger:"#E01B00",dangerLight:"#FCE8E5",dangerDark:"#BE1700",linkPrimary:"#007BFF",linkLight:"#007BFF10",headerBgColor:"#292929",headerTextColor:"#FFF",buttonText:"#292929",buttonHover:"#2E7D32"};function Jo(e){"@babel/helpers - typeof";return Jo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Jo(e)}function ta(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function AI(e,t){if(Jo(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(Jo(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function C1(e){var t=AI(e,"string");return Jo(t)=="symbol"?t:String(t)}function Kb(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,C1(r.key),r)}}function na(e,t,n){return t&&Kb(e.prototype,t),n&&Kb(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function Ou(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Xh(e,t){return Xh=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},Xh(e,t)}function kp(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Xh(e,t)}function Bd(e,t){if(t&&(Jo(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Ou(e)}function Bs(e){return Bs=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Bs(e)}function $s(e,t,n){return t=C1(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function E1(e){if(Array.isArray(e))return e}function MI(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Zb(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function k1(e,t){if(e){if(typeof e=="string")return Zb(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Zb(e,t)}}function O1(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
3
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function LI(e){return E1(e)||MI(e)||k1(e)||O1()}function Jb(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Qb(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Jb(Object(n),!0).forEach(function(r){$s(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Jb(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}var NI={type:"logger",log:function(t){this.output("log",t)},warn:function(t){this.output("warn",t)},error:function(t){this.output("error",t)},output:function(t,n){console&&console[t]&&console[t].apply(console,n)}},FI=function(){function e(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};ta(this,e),this.init(t,n)}return na(e,[{key:"init",value:function(n){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.prefix=r.prefix||"i18next:",this.logger=n||NI,this.options=r,this.debug=r.debug}},{key:"setDebug",value:function(n){this.debug=n}},{key:"log",value:function(){for(var n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];return this.forward(r,"log","",!0)}},{key:"warn",value:function(){for(var n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];return this.forward(r,"warn","",!0)}},{key:"error",value:function(){for(var n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];return this.forward(r,"error","")}},{key:"deprecate",value:function(){for(var n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];return this.forward(r,"warn","WARNING DEPRECATED: ",!0)}},{key:"forward",value:function(n,r,i,o){return o&&!this.debug?null:(typeof n[0]=="string"&&(n[0]="".concat(i).concat(this.prefix," ").concat(n[0])),this.logger[r](n))}},{key:"create",value:function(n){return new e(this.logger,Qb(Qb({},{prefix:"".concat(this.prefix,":").concat(n,":")}),this.options))}},{key:"clone",value:function(n){return n=n||this.options,n.prefix=n.prefix||this.prefix,new e(this.logger,n)}}]),e}(),Ms=new FI,Ol=function(){function e(){ta(this,e),this.observers={}}return na(e,[{key:"on",value:function(n,r){var i=this;return n.split(" ").forEach(function(o){i.observers[o]=i.observers[o]||[],i.observers[o].push(r)}),this}},{key:"off",value:function(n,r){if(this.observers[n]){if(!r){delete this.observers[n];return}this.observers[n]=this.observers[n].filter(function(i){return i!==r})}}},{key:"emit",value:function(n){for(var r=arguments.length,i=new Array(r>1?r-1:0),o=1;o<r;o++)i[o-1]=arguments[o];if(this.observers[n]){var s=[].concat(this.observers[n]);s.forEach(function(c){c.apply(void 0,i)})}if(this.observers["*"]){var l=[].concat(this.observers["*"]);l.forEach(function(c){c.apply(c,[n].concat(i))})}}}]),e}();function Kf(){var e,t,n=new Promise(function(r,i){e=r,t=i});return n.resolve=e,n.reject=t,n}function e0(e){return e==null?"":""+e}function jI(e,t,n){e.forEach(function(r){t[r]&&(n[r]=t[r])})}function Um(e,t,n){function r(l){return l&&l.indexOf("###")>-1?l.replace(/###/g,"."):l}function i(){return!e||typeof e=="string"}for(var o=typeof t!="string"?[].concat(t):t.split(".");o.length>1;){if(i())return{};var s=r(o.shift());!e[s]&&n&&(e[s]=new n),Object.prototype.hasOwnProperty.call(e,s)?e=e[s]:e={}}return i()?{}:{obj:e,k:r(o.shift())}}function t0(e,t,n){var r=Um(e,t,Object),i=r.obj,o=r.k;i[o]=n}function BI(e,t,n,r){var i=Um(e,t,Object),o=i.obj,s=i.k;o[s]=o[s]||[],r&&(o[s]=o[s].concat(n)),r||o[s].push(n)}function Kh(e,t){var n=Um(e,t),r=n.obj,i=n.k;if(r)return r[i]}function $I(e,t,n){var r=Kh(e,n);return r!==void 0?r:Kh(t,n)}function D1(e,t,n){for(var r in t)r!=="__proto__"&&r!=="constructor"&&(r in e?typeof e[r]=="string"||e[r]instanceof String||typeof t[r]=="string"||t[r]instanceof String?n&&(e[r]=t[r]):D1(e[r],t[r],n):e[r]=t[r]);return e}function df(e){return e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&")}var VI={"&":"&","<":"<",">":">",'"':""","'":"'","/":"/"};function HI(e){return typeof e=="string"?e.replace(/[&<>"'\/]/g,function(t){return VI[t]}):e}var Op=typeof window<"u"&&window.navigator&&typeof window.navigator.userAgentData>"u"&&window.navigator.userAgent&&window.navigator.userAgent.indexOf("MSIE")>-1,UI=[" ",",","?","!",";"];function WI(e,t,n){t=t||"",n=n||"";var r=UI.filter(function(l){return t.indexOf(l)<0&&n.indexOf(l)<0});if(r.length===0)return!0;var i=new RegExp("(".concat(r.map(function(l){return l==="?"?"\\?":l}).join("|"),")")),o=!i.test(e);if(!o){var s=e.indexOf(n);s>0&&!i.test(e.substring(0,s))&&(o=!0)}return o}function Zh(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:".";if(e){if(e[t])return e[t];for(var r=t.split(n),i=e,o=0;o<r.length;++o){if(!i||typeof i[r[o]]=="string"&&o+1<r.length)return;if(i[r[o]]===void 0){for(var s=2,l=r.slice(o,o+s).join(n),c=i[l];c===void 0&&r.length>o+s;)s++,l=r.slice(o,o+s).join(n),c=i[l];if(c===void 0)return;if(c===null)return null;if(t.endsWith(l)){if(typeof c=="string")return c;if(l&&typeof c[l]=="string")return c[l]}var d=r.slice(o+s).join(n);return d?Zh(c,d,n):void 0}i=i[r[o]]}return i}}function n0(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function uh(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?n0(Object(n),!0).forEach(function(r){$s(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):n0(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function zI(e){var t=YI();return function(){var r=Bs(e),i;if(t){var o=Bs(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return Bd(this,i)}}function YI(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}var GI=function(e){kp(n,e);var t=zI(n);function n(r){var i,o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{ns:["translation"],defaultNS:"translation"};return ta(this,n),i=t.call(this),Op&&Ol.call(Ou(i)),i.data=r||{},i.options=o,i.options.keySeparator===void 0&&(i.options.keySeparator="."),i.options.ignoreJSONStructure===void 0&&(i.options.ignoreJSONStructure=!0),i}return na(n,[{key:"addNamespaces",value:function(i){this.options.ns.indexOf(i)<0&&this.options.ns.push(i)}},{key:"removeNamespaces",value:function(i){var o=this.options.ns.indexOf(i);o>-1&&this.options.ns.splice(o,1)}},{key:"getResource",value:function(i,o,s){var l=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},c=l.keySeparator!==void 0?l.keySeparator:this.options.keySeparator,d=l.ignoreJSONStructure!==void 0?l.ignoreJSONStructure:this.options.ignoreJSONStructure,v=[i,o];s&&typeof s!="string"&&(v=v.concat(s)),s&&typeof s=="string"&&(v=v.concat(c?s.split(c):s)),i.indexOf(".")>-1&&(v=i.split("."));var p=Kh(this.data,v);return p||!d||typeof s!="string"?p:Zh(this.data&&this.data[i]&&this.data[i][o],s,c)}},{key:"addResource",value:function(i,o,s,l){var c=arguments.length>4&&arguments[4]!==void 0?arguments[4]:{silent:!1},d=c.keySeparator!==void 0?c.keySeparator:this.options.keySeparator,v=[i,o];s&&(v=v.concat(d?s.split(d):s)),i.indexOf(".")>-1&&(v=i.split("."),l=o,o=v[1]),this.addNamespaces(o),t0(this.data,v,l),c.silent||this.emit("added",i,o,s,l)}},{key:"addResources",value:function(i,o,s){var l=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{silent:!1};for(var c in s)(typeof s[c]=="string"||Object.prototype.toString.apply(s[c])==="[object Array]")&&this.addResource(i,o,c,s[c],{silent:!0});l.silent||this.emit("added",i,o,s)}},{key:"addResourceBundle",value:function(i,o,s,l,c){var d=arguments.length>5&&arguments[5]!==void 0?arguments[5]:{silent:!1},v=[i,o];i.indexOf(".")>-1&&(v=i.split("."),l=s,s=o,o=v[1]),this.addNamespaces(o);var p=Kh(this.data,v)||{};l?D1(p,s,c):p=uh(uh({},p),s),t0(this.data,v,p),d.silent||this.emit("added",i,o,s)}},{key:"removeResourceBundle",value:function(i,o){this.hasResourceBundle(i,o)&&delete this.data[i][o],this.removeNamespaces(o),this.emit("removed",i,o)}},{key:"hasResourceBundle",value:function(i,o){return this.getResource(i,o)!==void 0}},{key:"getResourceBundle",value:function(i,o){return o||(o=this.options.defaultNS),this.options.compatibilityAPI==="v1"?uh(uh({},{}),this.getResource(i,o)):this.getResource(i,o)}},{key:"getDataByLanguage",value:function(i){return this.data[i]}},{key:"hasLanguageSomeTranslations",value:function(i){var o=this.getDataByLanguage(i),s=o&&Object.keys(o)||[];return!!s.find(function(l){return o[l]&&Object.keys(o[l]).length>0})}},{key:"toJSON",value:function(){return this.data}}]),n}(Ol),P1={processors:{},addPostProcessor:function(t){this.processors[t.name]=t},handle:function(t,n,r,i,o){var s=this;return t.forEach(function(l){s.processors[l]&&(n=s.processors[l].process(n,r,i,o))}),n}};function r0(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Ai(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?r0(Object(n),!0).forEach(function(r){$s(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):r0(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function qI(e){var t=XI();return function(){var r=Bs(e),i;if(t){var o=Bs(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return Bd(this,i)}}function XI(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}var i0={},o0=function(e){kp(n,e);var t=qI(n);function n(r){var i,o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return ta(this,n),i=t.call(this),Op&&Ol.call(Ou(i)),jI(["resourceStore","languageUtils","pluralResolver","interpolator","backendConnector","i18nFormat","utils"],r,Ou(i)),i.options=o,i.options.keySeparator===void 0&&(i.options.keySeparator="."),i.logger=Ms.create("translator"),i}return na(n,[{key:"changeLanguage",value:function(i){i&&(this.language=i)}},{key:"exists",value:function(i){var o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{interpolation:{}};if(i==null)return!1;var s=this.resolve(i,o);return s&&s.res!==void 0}},{key:"extractFromKey",value:function(i,o){var s=o.nsSeparator!==void 0?o.nsSeparator:this.options.nsSeparator;s===void 0&&(s=":");var l=o.keySeparator!==void 0?o.keySeparator:this.options.keySeparator,c=o.ns||this.options.defaultNS||[],d=s&&i.indexOf(s)>-1,v=!this.options.userDefinedKeySeparator&&!o.keySeparator&&!this.options.userDefinedNsSeparator&&!o.nsSeparator&&!WI(i,s,l);if(d&&!v){var p=i.match(this.interpolator.nestingRegexp);if(p&&p.length>0)return{key:i,namespaces:c};var S=i.split(s);(s!==l||s===l&&this.options.ns.indexOf(S[0])>-1)&&(c=S.shift()),i=S.join(l)}return typeof c=="string"&&(c=[c]),{key:i,namespaces:c}}},{key:"translate",value:function(i,o,s){var l=this;if(Jo(o)!=="object"&&this.options.overloadTranslationOptionHandler&&(o=this.options.overloadTranslationOptionHandler(arguments)),Jo(o)==="object"&&(o=Ai({},o)),o||(o={}),i==null)return"";Array.isArray(i)||(i=[String(i)]);var c=o.returnDetails!==void 0?o.returnDetails:this.options.returnDetails,d=o.keySeparator!==void 0?o.keySeparator:this.options.keySeparator,v=this.extractFromKey(i[i.length-1],o),p=v.key,S=v.namespaces,T=S[S.length-1],_=o.lng||this.language,R=o.appendNamespaceToCIMode||this.options.appendNamespaceToCIMode;if(_&&_.toLowerCase()==="cimode"){if(R){var L=o.nsSeparator||this.options.nsSeparator;return c?{res:"".concat(T).concat(L).concat(p),usedKey:p,exactUsedKey:p,usedLng:_,usedNS:T}:"".concat(T).concat(L).concat(p)}return c?{res:p,usedKey:p,exactUsedKey:p,usedLng:_,usedNS:T}:p}var I=this.resolve(i,o),U=I&&I.res,z=I&&I.usedKey||p,re=I&&I.exactUsedKey||p,Z=Object.prototype.toString.apply(U),he=["[object Number]","[object Function]","[object RegExp]"],x=o.joinArrays!==void 0?o.joinArrays:this.options.joinArrays,ce=!this.i18nFormat||this.i18nFormat.handleAsObject,ae=typeof U!="string"&&typeof U!="boolean"&&typeof U!="number";if(ce&&U&&ae&&he.indexOf(Z)<0&&!(typeof x=="string"&&Z==="[object Array]")){if(!o.returnObjects&&!this.options.returnObjects){this.options.returnedObjectHandler||this.logger.warn("accessing an object - but returnObjects options is not enabled!");var je=this.options.returnedObjectHandler?this.options.returnedObjectHandler(z,U,Ai(Ai({},o),{},{ns:S})):"key '".concat(p," (").concat(this.language,")' returned an object instead of string.");return c?(I.res=je,I):je}if(d){var qe=Z==="[object Array]",We=qe?[]:{},rt=qe?re:z;for(var nt in U)if(Object.prototype.hasOwnProperty.call(U,nt)){var ye="".concat(rt).concat(d).concat(nt);We[nt]=this.translate(ye,Ai(Ai({},o),{joinArrays:!1,ns:S})),We[nt]===ye&&(We[nt]=U[nt])}U=We}}else if(ce&&typeof x=="string"&&Z==="[object Array]")U=U.join(x),U&&(U=this.extendTranslation(U,i,o,s));else{var De=!1,He=!1,Je=o.count!==void 0&&typeof o.count!="string",at=n.hasDefaultValue(o),Oe=Je?this.pluralResolver.getSuffix(_,o.count,o):"",xe=o["defaultValue".concat(Oe)]||o.defaultValue;!this.isValidLookup(U)&&at&&(De=!0,U=xe),this.isValidLookup(U)||(He=!0,U=p);var Ue=o.missingKeyNoValueFallbackToKey||this.options.missingKeyNoValueFallbackToKey,Ve=Ue&&He?void 0:U,Re=at&&xe!==U&&this.options.updateMissing;if(He||De||Re){if(this.logger.log(Re?"updateKey":"missingKey",_,T,p,Re?xe:U),d){var Me=this.resolve(p,Ai(Ai({},o),{},{keySeparator:!1}));Me&&Me.res&&this.logger.warn("Seems the loaded translations were in flat JSON format instead of nested. Either set keySeparator: false on init or make sure your translations are published in nested format.")}var Xe=[],lt=this.languageUtils.getFallbackCodes(this.options.fallbackLng,o.lng||this.language);if(this.options.saveMissingTo==="fallback"&<&<[0])for(var mt=0;mt<lt.length;mt++)Xe.push(lt[mt]);else this.options.saveMissingTo==="all"?Xe=this.languageUtils.toResolveHierarchy(o.lng||this.language):Xe.push(o.lng||this.language);var wt=function(Et,it,$t){var Ht=at&&$t!==U?$t:Ve;l.options.missingKeyHandler?l.options.missingKeyHandler(Et,T,it,Ht,Re,o):l.backendConnector&&l.backendConnector.saveMissing&&l.backendConnector.saveMissing(Et,T,it,Ht,Re,o),l.emit("missingKey",Et,T,it,U)};this.options.saveMissing&&(this.options.saveMissingPlurals&&Je?Xe.forEach(function(vt){l.pluralResolver.getSuffixes(vt,o).forEach(function(Et){wt([vt],p+Et,o["defaultValue".concat(Et)]||xe)})}):wt(Xe,p,xe))}U=this.extendTranslation(U,i,o,I,s),He&&U===p&&this.options.appendNamespaceToMissingKey&&(U="".concat(T,":").concat(p)),(He||De)&&this.options.parseMissingKeyHandler&&(this.options.compatibilityAPI!=="v1"?U=this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey?"".concat(T,":").concat(p):p,De?U:void 0):U=this.options.parseMissingKeyHandler(U))}return c?(I.res=U,I):U}},{key:"extendTranslation",value:function(i,o,s,l,c){var d=this;if(this.i18nFormat&&this.i18nFormat.parse)i=this.i18nFormat.parse(i,Ai(Ai({},this.options.interpolation.defaultVariables),s),l.usedLng,l.usedNS,l.usedKey,{resolved:l});else if(!s.skipInterpolation){s.interpolation&&this.interpolator.init(Ai(Ai({},s),{interpolation:Ai(Ai({},this.options.interpolation),s.interpolation)}));var v=typeof i=="string"&&(s&&s.interpolation&&s.interpolation.skipOnVariables!==void 0?s.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables),p;if(v){var S=i.match(this.interpolator.nestingRegexp);p=S&&S.length}var T=s.replace&&typeof s.replace!="string"?s.replace:s;if(this.options.interpolation.defaultVariables&&(T=Ai(Ai({},this.options.interpolation.defaultVariables),T)),i=this.interpolator.interpolate(i,T,s.lng||this.language,s),v){var _=i.match(this.interpolator.nestingRegexp),R=_&&_.length;p<R&&(s.nest=!1)}!s.lng&&this.options.compatibilityAPI!=="v1"&&l&&l.res&&(s.lng=l.usedLng),s.nest!==!1&&(i=this.interpolator.nest(i,function(){for(var U=arguments.length,z=new Array(U),re=0;re<U;re++)z[re]=arguments[re];return c&&c[0]===z[0]&&!s.context?(d.logger.warn("It seems you are nesting recursively key: ".concat(z[0]," in key: ").concat(o[0])),null):d.translate.apply(d,z.concat([o]))},s)),s.interpolation&&this.interpolator.reset()}var L=s.postProcess||this.options.postProcess,I=typeof L=="string"?[L]:L;return i!=null&&I&&I.length&&s.applyPostProcessor!==!1&&(i=P1.handle(I,i,o,this.options&&this.options.postProcessPassResolved?Ai({i18nResolved:l},s):s,this)),i}},{key:"resolve",value:function(i){var o=this,s=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},l,c,d,v,p;return typeof i=="string"&&(i=[i]),i.forEach(function(S){if(!o.isValidLookup(l)){var T=o.extractFromKey(S,s),_=T.key;c=_;var R=T.namespaces;o.options.fallbackNS&&(R=R.concat(o.options.fallbackNS));var L=s.count!==void 0&&typeof s.count!="string",I=L&&!s.ordinal&&s.count===0&&o.pluralResolver.shouldUseIntlApi(),U=s.context!==void 0&&(typeof s.context=="string"||typeof s.context=="number")&&s.context!=="",z=s.lngs?s.lngs:o.languageUtils.toResolveHierarchy(s.lng||o.language,s.fallbackLng);R.forEach(function(re){o.isValidLookup(l)||(p=re,!i0["".concat(z[0],"-").concat(re)]&&o.utils&&o.utils.hasLoadedNamespace&&!o.utils.hasLoadedNamespace(p)&&(i0["".concat(z[0],"-").concat(re)]=!0,o.logger.warn('key "'.concat(c,'" for languages "').concat(z.join(", "),`" won't get resolved as namespace "`).concat(p,'" 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!!!")),z.forEach(function(Z){if(!o.isValidLookup(l)){v=Z;var he=[_];if(o.i18nFormat&&o.i18nFormat.addLookupKeys)o.i18nFormat.addLookupKeys(he,_,Z,re,s);else{var x;L&&(x=o.pluralResolver.getSuffix(Z,s.count,s));var ce="".concat(o.options.pluralSeparator,"zero");if(L&&(he.push(_+x),I&&he.push(_+ce)),U){var ae="".concat(_).concat(o.options.contextSeparator).concat(s.context);he.push(ae),L&&(he.push(ae+x),I&&he.push(ae+ce))}}for(var je;je=he.pop();)o.isValidLookup(l)||(d=je,l=o.getResource(Z,re,je,s))}}))})}}),{res:l,usedKey:c,exactUsedKey:d,usedLng:v,usedNS:p}}},{key:"isValidLookup",value:function(i){return i!==void 0&&!(!this.options.returnNull&&i===null)&&!(!this.options.returnEmptyString&&i==="")}},{key:"getResource",value:function(i,o,s){var l=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};return this.i18nFormat&&this.i18nFormat.getResource?this.i18nFormat.getResource(i,o,s,l):this.resourceStore.getResource(i,o,s,l)}}],[{key:"hasDefaultValue",value:function(i){var o="defaultValue";for(var s in i)if(Object.prototype.hasOwnProperty.call(i,s)&&o===s.substring(0,o.length)&&i[s]!==void 0)return!0;return!1}}]),n}(Ol);function Rg(e){return e.charAt(0).toUpperCase()+e.slice(1)}var a0=function(){function e(t){ta(this,e),this.options=t,this.supportedLngs=this.options.supportedLngs||!1,this.logger=Ms.create("languageUtils")}return na(e,[{key:"getScriptPartFromCode",value:function(n){if(!n||n.indexOf("-")<0)return null;var r=n.split("-");return r.length===2||(r.pop(),r[r.length-1].toLowerCase()==="x")?null:this.formatLanguageCode(r.join("-"))}},{key:"getLanguagePartFromCode",value:function(n){if(!n||n.indexOf("-")<0)return n;var r=n.split("-");return this.formatLanguageCode(r[0])}},{key:"formatLanguageCode",value:function(n){if(typeof n=="string"&&n.indexOf("-")>-1){var r=["hans","hant","latn","cyrl","cans","mong","arab"],i=n.split("-");return this.options.lowerCaseLng?i=i.map(function(o){return o.toLowerCase()}):i.length===2?(i[0]=i[0].toLowerCase(),i[1]=i[1].toUpperCase(),r.indexOf(i[1].toLowerCase())>-1&&(i[1]=Rg(i[1].toLowerCase()))):i.length===3&&(i[0]=i[0].toLowerCase(),i[1].length===2&&(i[1]=i[1].toUpperCase()),i[0]!=="sgn"&&i[2].length===2&&(i[2]=i[2].toUpperCase()),r.indexOf(i[1].toLowerCase())>-1&&(i[1]=Rg(i[1].toLowerCase())),r.indexOf(i[2].toLowerCase())>-1&&(i[2]=Rg(i[2].toLowerCase()))),i.join("-")}return this.options.cleanCode||this.options.lowerCaseLng?n.toLowerCase():n}},{key:"isSupportedCode",value:function(n){return(this.options.load==="languageOnly"||this.options.nonExplicitSupportedLngs)&&(n=this.getLanguagePartFromCode(n)),!this.supportedLngs||!this.supportedLngs.length||this.supportedLngs.indexOf(n)>-1}},{key:"getBestMatchFromCodes",value:function(n){var r=this;if(!n)return null;var i;return n.forEach(function(o){if(!i){var s=r.formatLanguageCode(o);(!r.options.supportedLngs||r.isSupportedCode(s))&&(i=s)}}),!i&&this.options.supportedLngs&&n.forEach(function(o){if(!i){var s=r.getLanguagePartFromCode(o);if(r.isSupportedCode(s))return i=s;i=r.options.supportedLngs.find(function(l){if(l===s)return l;if(!(l.indexOf("-")<0&&s.indexOf("-")<0)&&l.indexOf(s)===0)return l})}}),i||(i=this.getFallbackCodes(this.options.fallbackLng)[0]),i}},{key:"getFallbackCodes",value:function(n,r){if(!n)return[];if(typeof n=="function"&&(n=n(r)),typeof n=="string"&&(n=[n]),Object.prototype.toString.apply(n)==="[object Array]")return n;if(!r)return n.default||[];var i=n[r];return i||(i=n[this.getScriptPartFromCode(r)]),i||(i=n[this.formatLanguageCode(r)]),i||(i=n[this.getLanguagePartFromCode(r)]),i||(i=n.default),i||[]}},{key:"toResolveHierarchy",value:function(n,r){var i=this,o=this.getFallbackCodes(r||this.options.fallbackLng||[],n),s=[],l=function(d){d&&(i.isSupportedCode(d)?s.push(d):i.logger.warn("rejecting language code not found in supportedLngs: ".concat(d)))};return typeof n=="string"&&n.indexOf("-")>-1?(this.options.load!=="languageOnly"&&l(this.formatLanguageCode(n)),this.options.load!=="languageOnly"&&this.options.load!=="currentOnly"&&l(this.getScriptPartFromCode(n)),this.options.load!=="currentOnly"&&l(this.getLanguagePartFromCode(n))):typeof n=="string"&&l(this.formatLanguageCode(n)),o.forEach(function(c){s.indexOf(c)<0&&l(i.formatLanguageCode(c))}),s}}]),e}(),KI=[{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}],ZI={1:function(t){return+(t>1)},2:function(t){return+(t!=1)},3:function(t){return 0},4:function(t){return t%10==1&&t%100!=11?0:t%10>=2&&t%10<=4&&(t%100<10||t%100>=20)?1:2},5:function(t){return t==0?0:t==1?1:t==2?2:t%100>=3&&t%100<=10?3:t%100>=11?4:5},6:function(t){return t==1?0:t>=2&&t<=4?1:2},7:function(t){return t==1?0:t%10>=2&&t%10<=4&&(t%100<10||t%100>=20)?1:2},8:function(t){return t==1?0:t==2?1:t!=8&&t!=11?2:3},9:function(t){return+(t>=2)},10:function(t){return t==1?0:t==2?1:t<7?2:t<11?3:4},11:function(t){return t==1||t==11?0:t==2||t==12?1:t>2&&t<20?2:3},12:function(t){return+(t%10!=1||t%100==11)},13:function(t){return+(t!==0)},14:function(t){return t==1?0:t==2?1:t==3?2:3},15:function(t){return t%10==1&&t%100!=11?0:t%10>=2&&(t%100<10||t%100>=20)?1:2},16:function(t){return t%10==1&&t%100!=11?0:t!==0?1:2},17:function(t){return t==1||t%10==1&&t%100!=11?0:1},18:function(t){return t==0?0:t==1?1:2},19:function(t){return t==1?0:t==0||t%100>1&&t%100<11?1:t%100>10&&t%100<20?2:3},20:function(t){return t==1?0:t==0||t%100>0&&t%100<20?1:2},21:function(t){return t%100==1?1:t%100==2?2:t%100==3||t%100==4?3:0},22:function(t){return t==1?0:t==2?1:(t<0||t>10)&&t%10==0?2:3}},JI=["v1","v2","v3"],s0={zero:0,one:1,two:2,few:3,many:4,other:5};function QI(){var e={};return KI.forEach(function(t){t.lngs.forEach(function(n){e[n]={numbers:t.nr,plurals:ZI[t.fc]}})}),e}var eA=function(){function e(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};ta(this,e),this.languageUtils=t,this.options=n,this.logger=Ms.create("pluralResolver"),(!this.options.compatibilityJSON||this.options.compatibilityJSON==="v4")&&(typeof Intl>"u"||!Intl.PluralRules)&&(this.options.compatibilityJSON="v3",this.logger.error("Your environment seems not to be Intl API compatible, use an Intl.PluralRules polyfill. Will fallback to the compatibilityJSON v3 format handling.")),this.rules=QI()}return na(e,[{key:"addRule",value:function(n,r){this.rules[n]=r}},{key:"getRule",value:function(n){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(this.shouldUseIntlApi())try{return new Intl.PluralRules(n,{type:r.ordinal?"ordinal":"cardinal"})}catch{return}return this.rules[n]||this.rules[this.languageUtils.getLanguagePartFromCode(n)]}},{key:"needsPlural",value:function(n){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=this.getRule(n,r);return this.shouldUseIntlApi()?i&&i.resolvedOptions().pluralCategories.length>1:i&&i.numbers.length>1}},{key:"getPluralFormsOfKey",value:function(n,r){var i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return this.getSuffixes(n,i).map(function(o){return"".concat(r).concat(o)})}},{key:"getSuffixes",value:function(n){var r=this,i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},o=this.getRule(n,i);return o?this.shouldUseIntlApi()?o.resolvedOptions().pluralCategories.sort(function(s,l){return s0[s]-s0[l]}).map(function(s){return"".concat(r.options.prepend).concat(s)}):o.numbers.map(function(s){return r.getSuffix(n,s,i)}):[]}},{key:"getSuffix",value:function(n,r){var i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},o=this.getRule(n,i);return o?this.shouldUseIntlApi()?"".concat(this.options.prepend).concat(o.select(r)):this.getSuffixRetroCompatible(o,r):(this.logger.warn("no plural rule found for: ".concat(n)),"")}},{key:"getSuffixRetroCompatible",value:function(n,r){var i=this,o=n.noAbs?n.plurals(r):n.plurals(Math.abs(r)),s=n.numbers[o];this.options.simplifyPluralSuffix&&n.numbers.length===2&&n.numbers[0]===1&&(s===2?s="plural":s===1&&(s=""));var l=function(){return i.options.prepend&&s.toString()?i.options.prepend+s.toString():s.toString()};return this.options.compatibilityJSON==="v1"?s===1?"":typeof s=="number"?"_plural_".concat(s.toString()):l():this.options.compatibilityJSON==="v2"||this.options.simplifyPluralSuffix&&n.numbers.length===2&&n.numbers[0]===1?l():this.options.prepend&&o.toString()?this.options.prepend+o.toString():o.toString()}},{key:"shouldUseIntlApi",value:function(){return!JI.includes(this.options.compatibilityJSON)}}]),e}();function u0(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function es(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?u0(Object(n),!0).forEach(function(r){$s(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):u0(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function l0(e,t,n){var r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:".",i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!0,o=$I(e,t,n);return!o&&i&&typeof n=="string"&&(o=Zh(e,n,r),o===void 0&&(o=Zh(t,n,r))),o}var tA=function(){function e(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};ta(this,e),this.logger=Ms.create("interpolator"),this.options=t,this.format=t.interpolation&&t.interpolation.format||function(n){return n},this.init(t)}return na(e,[{key:"init",value:function(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};n.interpolation||(n.interpolation={escapeValue:!0});var r=n.interpolation;this.escape=r.escape!==void 0?r.escape:HI,this.escapeValue=r.escapeValue!==void 0?r.escapeValue:!0,this.useRawValueToEscape=r.useRawValueToEscape!==void 0?r.useRawValueToEscape:!1,this.prefix=r.prefix?df(r.prefix):r.prefixEscaped||"{{",this.suffix=r.suffix?df(r.suffix):r.suffixEscaped||"}}",this.formatSeparator=r.formatSeparator?r.formatSeparator:r.formatSeparator||",",this.unescapePrefix=r.unescapeSuffix?"":r.unescapePrefix||"-",this.unescapeSuffix=this.unescapePrefix?"":r.unescapeSuffix||"",this.nestingPrefix=r.nestingPrefix?df(r.nestingPrefix):r.nestingPrefixEscaped||df("$t("),this.nestingSuffix=r.nestingSuffix?df(r.nestingSuffix):r.nestingSuffixEscaped||df(")"),this.nestingOptionsSeparator=r.nestingOptionsSeparator?r.nestingOptionsSeparator:r.nestingOptionsSeparator||",",this.maxReplaces=r.maxReplaces?r.maxReplaces:1e3,this.alwaysFormat=r.alwaysFormat!==void 0?r.alwaysFormat:!1,this.resetRegExp()}},{key:"reset",value:function(){this.options&&this.init(this.options)}},{key:"resetRegExp",value:function(){var n="".concat(this.prefix,"(.+?)").concat(this.suffix);this.regexp=new RegExp(n,"g");var r="".concat(this.prefix).concat(this.unescapePrefix,"(.+?)").concat(this.unescapeSuffix).concat(this.suffix);this.regexpUnescape=new RegExp(r,"g");var i="".concat(this.nestingPrefix,"(.+?)").concat(this.nestingSuffix);this.nestingRegexp=new RegExp(i,"g")}},{key:"interpolate",value:function(n,r,i,o){var s=this,l,c,d,v=this.options&&this.options.interpolation&&this.options.interpolation.defaultVariables||{};function p(L){return L.replace(/\$/g,"$$$$")}var S=function(I){if(I.indexOf(s.formatSeparator)<0){var U=l0(r,v,I,s.options.keySeparator,s.options.ignoreJSONStructure);return s.alwaysFormat?s.format(U,void 0,i,es(es(es({},o),r),{},{interpolationkey:I})):U}var z=I.split(s.formatSeparator),re=z.shift().trim(),Z=z.join(s.formatSeparator).trim();return s.format(l0(r,v,re,s.options.keySeparator,s.options.ignoreJSONStructure),Z,i,es(es(es({},o),r),{},{interpolationkey:re}))};this.resetRegExp();var T=o&&o.missingInterpolationHandler||this.options.missingInterpolationHandler,_=o&&o.interpolation&&o.interpolation.skipOnVariables!==void 0?o.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables,R=[{regex:this.regexpUnescape,safeValue:function(I){return p(I)}},{regex:this.regexp,safeValue:function(I){return s.escapeValue?p(s.escape(I)):p(I)}}];return R.forEach(function(L){for(d=0;l=L.regex.exec(n);){var I=l[1].trim();if(c=S(I),c===void 0)if(typeof T=="function"){var U=T(n,l,o);c=typeof U=="string"?U:""}else if(o&&Object.prototype.hasOwnProperty.call(o,I))c="";else if(_){c=l[0];continue}else s.logger.warn("missed to pass in variable ".concat(I," for interpolating ").concat(n)),c="";else typeof c!="string"&&!s.useRawValueToEscape&&(c=e0(c));var z=L.safeValue(c);if(n=n.replace(l[0],z),_?(L.regex.lastIndex+=c.length,L.regex.lastIndex-=l[0].length):L.regex.lastIndex=0,d++,d>=s.maxReplaces)break}}),n}},{key:"nest",value:function(n,r){var i=this,o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},s,l,c;function d(T,_){var R=this.nestingOptionsSeparator;if(T.indexOf(R)<0)return T;var L=T.split(new RegExp("".concat(R,"[ ]*{"))),I="{".concat(L[1]);T=L[0],I=this.interpolate(I,c);var U=I.match(/'/g),z=I.match(/"/g);(U&&U.length%2===0&&!z||z.length%2!==0)&&(I=I.replace(/'/g,'"'));try{c=JSON.parse(I),_&&(c=es(es({},_),c))}catch(re){return this.logger.warn("failed parsing options string in nesting for key ".concat(T),re),"".concat(T).concat(R).concat(I)}return delete c.defaultValue,T}for(;s=this.nestingRegexp.exec(n);){var v=[];c=es({},o),c=c.replace&&typeof c.replace!="string"?c.replace:c,c.applyPostProcessor=!1,delete c.defaultValue;var p=!1;if(s[0].indexOf(this.formatSeparator)!==-1&&!/{.*}/.test(s[1])){var S=s[1].split(this.formatSeparator).map(function(T){return T.trim()});s[1]=S.shift(),v=S,p=!0}if(l=r(d.call(this,s[1].trim(),c),c),l&&s[0]===n&&typeof l!="string")return l;typeof l!="string"&&(l=e0(l)),l||(this.logger.warn("missed to resolve ".concat(s[1]," for nesting ").concat(n)),l=""),p&&(l=v.reduce(function(T,_){return i.format(T,_,o.lng,es(es({},o),{},{interpolationkey:s[1].trim()}))},l.trim())),n=n.replace(s[0],l),this.regexp.lastIndex=0}return n}}]),e}();function c0(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Su(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?c0(Object(n),!0).forEach(function(r){$s(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):c0(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function nA(e){var t=e.toLowerCase().trim(),n={};if(e.indexOf("(")>-1){var r=e.split("(");t=r[0].toLowerCase().trim();var i=r[1].substring(0,r[1].length-1);if(t==="currency"&&i.indexOf(":")<0)n.currency||(n.currency=i.trim());else if(t==="relativetime"&&i.indexOf(":")<0)n.range||(n.range=i.trim());else{var o=i.split(";");o.forEach(function(s){if(s){var l=s.split(":"),c=LI(l),d=c[0],v=c.slice(1),p=v.join(":").trim().replace(/^'+|'+$/g,"");n[d.trim()]||(n[d.trim()]=p),p==="false"&&(n[d.trim()]=!1),p==="true"&&(n[d.trim()]=!0),isNaN(p)||(n[d.trim()]=parseInt(p,10))}})}}return{formatName:t,formatOptions:n}}function hf(e){var t={};return function(r,i,o){var s=i+JSON.stringify(o),l=t[s];return l||(l=e(i,o),t[s]=l),l(r)}}var rA=function(){function e(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};ta(this,e),this.logger=Ms.create("formatter"),this.options=t,this.formats={number:hf(function(n,r){var i=new Intl.NumberFormat(n,Su({},r));return function(o){return i.format(o)}}),currency:hf(function(n,r){var i=new Intl.NumberFormat(n,Su(Su({},r),{},{style:"currency"}));return function(o){return i.format(o)}}),datetime:hf(function(n,r){var i=new Intl.DateTimeFormat(n,Su({},r));return function(o){return i.format(o)}}),relativetime:hf(function(n,r){var i=new Intl.RelativeTimeFormat(n,Su({},r));return function(o){return i.format(o,r.range||"day")}}),list:hf(function(n,r){var i=new Intl.ListFormat(n,Su({},r));return function(o){return i.format(o)}})},this.init(t)}return na(e,[{key:"init",value:function(n){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{interpolation:{}},i=r.interpolation;this.formatSeparator=i.formatSeparator?i.formatSeparator:i.formatSeparator||","}},{key:"add",value:function(n,r){this.formats[n.toLowerCase().trim()]=r}},{key:"addCached",value:function(n,r){this.formats[n.toLowerCase().trim()]=hf(r)}},{key:"format",value:function(n,r,i){var o=this,s=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},l=r.split(this.formatSeparator),c=l.reduce(function(d,v){var p=nA(v),S=p.formatName,T=p.formatOptions;if(o.formats[S]){var _=d;try{var R=s&&s.formatParams&&s.formatParams[s.interpolationkey]||{},L=R.locale||R.lng||s.locale||s.lng||i;_=o.formats[S](d,L,Su(Su(Su({},T),s),R))}catch(I){o.logger.warn(I)}return _}else o.logger.warn("there was no format function for ".concat(S));return d},n);return c}}]),e}();function f0(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function d0(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?f0(Object(n),!0).forEach(function(r){$s(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):f0(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function iA(e){var t=oA();return function(){var r=Bs(e),i;if(t){var o=Bs(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return Bd(this,i)}}function oA(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function aA(e,t){e.pending[t]!==void 0&&(delete e.pending[t],e.pendingCount--)}var sA=function(e){kp(n,e);var t=iA(n);function n(r,i,o){var s,l=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};return ta(this,n),s=t.call(this),Op&&Ol.call(Ou(s)),s.backend=r,s.store=i,s.services=o,s.languageUtils=o.languageUtils,s.options=l,s.logger=Ms.create("backendConnector"),s.waitingReads=[],s.maxParallelReads=l.maxParallelReads||10,s.readingCalls=0,s.maxRetries=l.maxRetries>=0?l.maxRetries:5,s.retryTimeout=l.retryTimeout>=1?l.retryTimeout:350,s.state={},s.queue=[],s.backend&&s.backend.init&&s.backend.init(o,l.backend,l),s}return na(n,[{key:"queueLoad",value:function(i,o,s,l){var c=this,d={},v={},p={},S={};return i.forEach(function(T){var _=!0;o.forEach(function(R){var L="".concat(T,"|").concat(R);!s.reload&&c.store.hasResourceBundle(T,R)?c.state[L]=2:c.state[L]<0||(c.state[L]===1?v[L]===void 0&&(v[L]=!0):(c.state[L]=1,_=!1,v[L]===void 0&&(v[L]=!0),d[L]===void 0&&(d[L]=!0),S[R]===void 0&&(S[R]=!0)))}),_||(p[T]=!0)}),(Object.keys(d).length||Object.keys(v).length)&&this.queue.push({pending:v,pendingCount:Object.keys(v).length,loaded:{},errors:[],callback:l}),{toLoad:Object.keys(d),pending:Object.keys(v),toLoadLanguages:Object.keys(p),toLoadNamespaces:Object.keys(S)}}},{key:"loaded",value:function(i,o,s){var l=i.split("|"),c=l[0],d=l[1];o&&this.emit("failedLoading",c,d,o),s&&this.store.addResourceBundle(c,d,s),this.state[i]=o?-1:2;var v={};this.queue.forEach(function(p){BI(p.loaded,[c],d),aA(p,i),o&&p.errors.push(o),p.pendingCount===0&&!p.done&&(Object.keys(p.loaded).forEach(function(S){v[S]||(v[S]={});var T=p.loaded[S];T.length&&T.forEach(function(_){v[S][_]===void 0&&(v[S][_]=!0)})}),p.done=!0,p.errors.length?p.callback(p.errors):p.callback())}),this.emit("loaded",v),this.queue=this.queue.filter(function(p){return!p.done})}},{key:"read",value:function(i,o,s){var l=this,c=arguments.length>3&&arguments[3]!==void 0?arguments[3]:0,d=arguments.length>4&&arguments[4]!==void 0?arguments[4]:this.retryTimeout,v=arguments.length>5?arguments[5]:void 0;if(!i.length)return v(null,{});if(this.readingCalls>=this.maxParallelReads){this.waitingReads.push({lng:i,ns:o,fcName:s,tried:c,wait:d,callback:v});return}this.readingCalls++;var p=function(R,L){if(l.readingCalls--,l.waitingReads.length>0){var I=l.waitingReads.shift();l.read(I.lng,I.ns,I.fcName,I.tried,I.wait,I.callback)}if(R&&L&&c<l.maxRetries){setTimeout(function(){l.read.call(l,i,o,s,c+1,d*2,v)},d);return}v(R,L)},S=this.backend[s].bind(this.backend);if(S.length===2){try{var T=S(i,o);T&&typeof T.then=="function"?T.then(function(_){return p(null,_)}).catch(p):p(null,T)}catch(_){p(_)}return}return S(i,o,p)}},{key:"prepareLoading",value:function(i,o){var s=this,l=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},c=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."),c&&c();typeof i=="string"&&(i=this.languageUtils.toResolveHierarchy(i)),typeof o=="string"&&(o=[o]);var d=this.queueLoad(i,o,l,c);if(!d.toLoad.length)return d.pending.length||c(),null;d.toLoad.forEach(function(v){s.loadOne(v)})}},{key:"load",value:function(i,o,s){this.prepareLoading(i,o,{},s)}},{key:"reload",value:function(i,o,s){this.prepareLoading(i,o,{reload:!0},s)}},{key:"loadOne",value:function(i){var o=this,s=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",l=i.split("|"),c=l[0],d=l[1];this.read(c,d,"read",void 0,void 0,function(v,p){v&&o.logger.warn("".concat(s,"loading namespace ").concat(d," for language ").concat(c," failed"),v),!v&&p&&o.logger.log("".concat(s,"loaded namespace ").concat(d," for language ").concat(c),p),o.loaded(i,v,p)})}},{key:"saveMissing",value:function(i,o,s,l,c){var d=arguments.length>5&&arguments[5]!==void 0?arguments[5]:{},v=arguments.length>6&&arguments[6]!==void 0?arguments[6]:function(){};if(this.services.utils&&this.services.utils.hasLoadedNamespace&&!this.services.utils.hasLoadedNamespace(o)){this.logger.warn('did not save key "'.concat(s,'" as the namespace "').concat(o,'" 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(!(s==null||s==="")){if(this.backend&&this.backend.create){var p=d0(d0({},d),{},{isUpdate:c}),S=this.backend.create.bind(this.backend);if(S.length<6)try{var T;S.length===5?T=S(i,o,s,l,p):T=S(i,o,s,l),T&&typeof T.then=="function"?T.then(function(_){return v(null,_)}).catch(v):v(null,T)}catch(_){v(_)}else S(i,o,s,l,v,p)}!i||!i[0]||this.store.addResource(i[0],o,s,l)}}}]),n}(Ol);function h0(){return{debug:!1,initImmediate:!0,ns:["translation"],defaultNS:["translation"],fallbackLng:["dev"],fallbackNS:!1,supportedLngs:!1,nonExplicitSupportedLngs:!1,load:"all",preload:!1,simplifyPluralSuffix:!0,keySeparator:".",nsSeparator:":",pluralSeparator:"_",contextSeparator:"_",partialBundledLanguages:!1,saveMissing:!1,updateMissing:!1,saveMissingTo:"fallback",saveMissingPlurals:!0,missingKeyHandler:!1,missingInterpolationHandler:!1,postProcess:!1,postProcessPassResolved:!1,returnNull:!0,returnEmptyString:!0,returnObjects:!1,joinArrays:!1,returnedObjectHandler:!1,parseMissingKeyHandler:!1,appendNamespaceToMissingKey:!1,appendNamespaceToCIMode:!1,overloadTranslationOptionHandler:function(t){var n={};if(Jo(t[1])==="object"&&(n=t[1]),typeof t[1]=="string"&&(n.defaultValue=t[1]),typeof t[2]=="string"&&(n.tDescription=t[2]),Jo(t[2])==="object"||Jo(t[3])==="object"){var r=t[3]||t[2];Object.keys(r).forEach(function(i){n[i]=r[i]})}return n},interpolation:{escapeValue:!0,format:function(t,n,r,i){return t},prefix:"{{",suffix:"}}",formatSeparator:",",unescapePrefix:"-",nestingPrefix:"$t(",nestingSuffix:")",nestingOptionsSeparator:",",maxReplaces:1e3,skipOnVariables:!0}}}function p0(e){return typeof e.ns=="string"&&(e.ns=[e.ns]),typeof e.fallbackLng=="string"&&(e.fallbackLng=[e.fallbackLng]),typeof e.fallbackNS=="string"&&(e.fallbackNS=[e.fallbackNS]),e.supportedLngs&&e.supportedLngs.indexOf("cimode")<0&&(e.supportedLngs=e.supportedLngs.concat(["cimode"])),e}function g0(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Ps(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?g0(Object(n),!0).forEach(function(r){$s(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):g0(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function uA(e){var t=lA();return function(){var r=Bs(e),i;if(t){var o=Bs(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return Bd(this,i)}}function lA(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function lh(){}function cA(e){var t=Object.getOwnPropertyNames(Object.getPrototypeOf(e));t.forEach(function(n){typeof e[n]=="function"&&(e[n]=e[n].bind(e))})}var Jh=function(e){kp(n,e);var t=uA(n);function n(){var r,i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},o=arguments.length>1?arguments[1]:void 0;if(ta(this,n),r=t.call(this),Op&&Ol.call(Ou(r)),r.options=p0(i),r.services={},r.logger=Ms,r.modules={external:[]},cA(Ou(r)),o&&!r.isInitialized&&!i.isClone){if(!r.options.initImmediate)return r.init(i,o),Bd(r,Ou(r));setTimeout(function(){r.init(i,o)},0)}return r}return na(n,[{key:"init",value:function(){var i=this,o=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},s=arguments.length>1?arguments[1]:void 0;typeof o=="function"&&(s=o,o={}),!o.defaultNS&&o.defaultNS!==!1&&o.ns&&(typeof o.ns=="string"?o.defaultNS=o.ns:o.ns.indexOf("translation")<0&&(o.defaultNS=o.ns[0]));var l=h0();this.options=Ps(Ps(Ps({},l),this.options),p0(o)),this.options.compatibilityAPI!=="v1"&&(this.options.interpolation=Ps(Ps({},l.interpolation),this.options.interpolation)),o.keySeparator!==void 0&&(this.options.userDefinedKeySeparator=o.keySeparator),o.nsSeparator!==void 0&&(this.options.userDefinedNsSeparator=o.nsSeparator);function c(I){return I?typeof I=="function"?new I:I:null}if(!this.options.isClone){this.modules.logger?Ms.init(c(this.modules.logger),this.options):Ms.init(null,this.options);var d;this.modules.formatter?d=this.modules.formatter:typeof Intl<"u"&&(d=rA);var v=new a0(this.options);this.store=new GI(this.options.resources,this.options);var p=this.services;p.logger=Ms,p.resourceStore=this.store,p.languageUtils=v,p.pluralResolver=new eA(v,{prepend:this.options.pluralSeparator,compatibilityJSON:this.options.compatibilityJSON,simplifyPluralSuffix:this.options.simplifyPluralSuffix}),d&&(!this.options.interpolation.format||this.options.interpolation.format===l.interpolation.format)&&(p.formatter=c(d),p.formatter.init(p,this.options),this.options.interpolation.format=p.formatter.format.bind(p.formatter)),p.interpolator=new tA(this.options),p.utils={hasLoadedNamespace:this.hasLoadedNamespace.bind(this)},p.backendConnector=new sA(c(this.modules.backend),p.resourceStore,p,this.options),p.backendConnector.on("*",function(I){for(var U=arguments.length,z=new Array(U>1?U-1:0),re=1;re<U;re++)z[re-1]=arguments[re];i.emit.apply(i,[I].concat(z))}),this.modules.languageDetector&&(p.languageDetector=c(this.modules.languageDetector),p.languageDetector.init&&p.languageDetector.init(p,this.options.detection,this.options)),this.modules.i18nFormat&&(p.i18nFormat=c(this.modules.i18nFormat),p.i18nFormat.init&&p.i18nFormat.init(this)),this.translator=new o0(this.services,this.options),this.translator.on("*",function(I){for(var U=arguments.length,z=new Array(U>1?U-1:0),re=1;re<U;re++)z[re-1]=arguments[re];i.emit.apply(i,[I].concat(z))}),this.modules.external.forEach(function(I){I.init&&I.init(i)})}if(this.format=this.options.interpolation.format,s||(s=lh),this.options.fallbackLng&&!this.services.languageDetector&&!this.options.lng){var S=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);S.length>0&&S[0]!=="dev"&&(this.options.lng=S[0])}!this.services.languageDetector&&!this.options.lng&&this.logger.warn("init: no languageDetector is used and no lng is defined");var T=["getResource","hasResourceBundle","getResourceBundle","getDataByLanguage"];T.forEach(function(I){i[I]=function(){var U;return(U=i.store)[I].apply(U,arguments)}});var _=["addResource","addResources","addResourceBundle","removeResourceBundle"];_.forEach(function(I){i[I]=function(){var U;return(U=i.store)[I].apply(U,arguments),i}});var R=Kf(),L=function(){var U=function(re,Z){i.isInitialized&&!i.initializedStoreOnce&&i.logger.warn("init: i18next is already initialized. You should call init just once!"),i.isInitialized=!0,i.options.isClone||i.logger.log("initialized",i.options),i.emit("initialized",i.options),R.resolve(Z),s(re,Z)};if(i.languages&&i.options.compatibilityAPI!=="v1"&&!i.isInitialized)return U(null,i.t.bind(i));i.changeLanguage(i.options.lng,U)};return this.options.resources||!this.options.initImmediate?L():setTimeout(L,0),R}},{key:"loadResources",value:function(i){var o=this,s=arguments.length>1&&arguments[1]!==void 0?arguments[1]:lh,l=s,c=typeof i=="string"?i:this.language;if(typeof i=="function"&&(l=i),!this.options.resources||this.options.partialBundledLanguages){if(c&&c.toLowerCase()==="cimode")return l();var d=[],v=function(T){if(T){var _=o.services.languageUtils.toResolveHierarchy(T);_.forEach(function(R){d.indexOf(R)<0&&d.push(R)})}};if(c)v(c);else{var p=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);p.forEach(function(S){return v(S)})}this.options.preload&&this.options.preload.forEach(function(S){return v(S)}),this.services.backendConnector.load(d,this.options.ns,function(S){!S&&!o.resolvedLanguage&&o.language&&o.setResolvedLanguage(o.language),l(S)})}else l(null)}},{key:"reloadResources",value:function(i,o,s){var l=Kf();return i||(i=this.languages),o||(o=this.options.ns),s||(s=lh),this.services.backendConnector.reload(i,o,function(c){l.resolve(),s(c)}),l}},{key:"use",value:function(i){if(!i)throw new Error("You are passing an undefined module! Please check the object you are passing to i18next.use()");if(!i.type)throw new Error("You are passing a wrong module! Please check the object you are passing to i18next.use()");return i.type==="backend"&&(this.modules.backend=i),(i.type==="logger"||i.log&&i.warn&&i.error)&&(this.modules.logger=i),i.type==="languageDetector"&&(this.modules.languageDetector=i),i.type==="i18nFormat"&&(this.modules.i18nFormat=i),i.type==="postProcessor"&&P1.addPostProcessor(i),i.type==="formatter"&&(this.modules.formatter=i),i.type==="3rdParty"&&this.modules.external.push(i),this}},{key:"setResolvedLanguage",value:function(i){if(!(!i||!this.languages)&&!(["cimode","dev"].indexOf(i)>-1))for(var o=0;o<this.languages.length;o++){var s=this.languages[o];if(!(["cimode","dev"].indexOf(s)>-1)&&this.store.hasLanguageSomeTranslations(s)){this.resolvedLanguage=s;break}}}},{key:"changeLanguage",value:function(i,o){var s=this;this.isLanguageChangingTo=i;var l=Kf();this.emit("languageChanging",i);var c=function(S){s.language=S,s.languages=s.services.languageUtils.toResolveHierarchy(S),s.resolvedLanguage=void 0,s.setResolvedLanguage(S)},d=function(S,T){T?(c(T),s.translator.changeLanguage(T),s.isLanguageChangingTo=void 0,s.emit("languageChanged",T),s.logger.log("languageChanged",T)):s.isLanguageChangingTo=void 0,l.resolve(function(){return s.t.apply(s,arguments)}),o&&o(S,function(){return s.t.apply(s,arguments)})},v=function(S){!i&&!S&&s.services.languageDetector&&(S=[]);var T=typeof S=="string"?S:s.services.languageUtils.getBestMatchFromCodes(S);T&&(s.language||c(T),s.translator.language||s.translator.changeLanguage(T),s.services.languageDetector&&s.services.languageDetector.cacheUserLanguage&&s.services.languageDetector.cacheUserLanguage(T)),s.loadResources(T,function(_){d(_,T)})};return!i&&this.services.languageDetector&&!this.services.languageDetector.async?v(this.services.languageDetector.detect()):!i&&this.services.languageDetector&&this.services.languageDetector.async?this.services.languageDetector.detect.length===0?this.services.languageDetector.detect().then(v):this.services.languageDetector.detect(v):v(i),l}},{key:"getFixedT",value:function(i,o,s){var l=this,c=function d(v,p){var S;if(Jo(p)!=="object"){for(var T=arguments.length,_=new Array(T>2?T-2:0),R=2;R<T;R++)_[R-2]=arguments[R];S=l.options.overloadTranslationOptionHandler([v,p].concat(_))}else S=Ps({},p);S.lng=S.lng||d.lng,S.lngs=S.lngs||d.lngs,S.ns=S.ns||d.ns,S.keyPrefix=S.keyPrefix||s||d.keyPrefix;var L=l.options.keySeparator||".",I;return S.keyPrefix&&Array.isArray(v)?I=v.map(function(U){return"".concat(S.keyPrefix).concat(L).concat(U)}):I=S.keyPrefix?"".concat(S.keyPrefix).concat(L).concat(v):v,l.t(I,S)};return typeof i=="string"?c.lng=i:c.lngs=i,c.ns=o,c.keyPrefix=s,c}},{key:"t",value:function(){var i;return this.translator&&(i=this.translator).translate.apply(i,arguments)}},{key:"exists",value:function(){var i;return this.translator&&(i=this.translator).exists.apply(i,arguments)}},{key:"setDefaultNamespace",value:function(i){this.options.defaultNS=i}},{key:"hasLoadedNamespace",value:function(i){var o=this,s=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(!this.isInitialized)return this.logger.warn("hasLoadedNamespace: i18next was not initialized",this.languages),!1;if(!this.languages||!this.languages.length)return this.logger.warn("hasLoadedNamespace: i18n.languages were undefined or empty",this.languages),!1;var l=s.lng||this.resolvedLanguage||this.languages[0],c=this.options?this.options.fallbackLng:!1,d=this.languages[this.languages.length-1];if(l.toLowerCase()==="cimode")return!0;var v=function(T,_){var R=o.services.backendConnector.state["".concat(T,"|").concat(_)];return R===-1||R===2};if(s.precheck){var p=s.precheck(this,v);if(p!==void 0)return p}return!!(this.hasResourceBundle(l,i)||!this.services.backendConnector.backend||this.options.resources&&!this.options.partialBundledLanguages||v(l,i)&&(!c||v(d,i)))}},{key:"loadNamespaces",value:function(i,o){var s=this,l=Kf();return this.options.ns?(typeof i=="string"&&(i=[i]),i.forEach(function(c){s.options.ns.indexOf(c)<0&&s.options.ns.push(c)}),this.loadResources(function(c){l.resolve(),o&&o(c)}),l):(o&&o(),Promise.resolve())}},{key:"loadLanguages",value:function(i,o){var s=Kf();typeof i=="string"&&(i=[i]);var l=this.options.preload||[],c=i.filter(function(d){return l.indexOf(d)<0});return c.length?(this.options.preload=l.concat(c),this.loadResources(function(d){s.resolve(),o&&o(d)}),s):(o&&o(),Promise.resolve())}},{key:"dir",value:function(i){if(i||(i=this.resolvedLanguage||(this.languages&&this.languages.length>0?this.languages[0]:this.language)),!i)return"rtl";var o=["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"],s=this.services&&this.services.languageUtils||new a0(h0());return o.indexOf(s.getLanguagePartFromCode(i))>-1||i.toLowerCase().indexOf("-arab")>1?"rtl":"ltr"}},{key:"cloneInstance",value:function(){var i=this,o=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},s=arguments.length>1&&arguments[1]!==void 0?arguments[1]:lh,l=Ps(Ps(Ps({},this.options),o),{isClone:!0}),c=new n(l);(o.debug!==void 0||o.prefix!==void 0)&&(c.logger=c.logger.clone(o));var d=["store","services","language"];return d.forEach(function(v){c[v]=i[v]}),c.services=Ps({},this.services),c.services.utils={hasLoadedNamespace:c.hasLoadedNamespace.bind(c)},c.translator=new o0(c.services,c.options),c.translator.on("*",function(v){for(var p=arguments.length,S=new Array(p>1?p-1:0),T=1;T<p;T++)S[T-1]=arguments[T];c.emit.apply(c,[v].concat(S))}),c.init(l,s),c.translator.options=c.options,c.translator.backendConnector.services.utils={hasLoadedNamespace:c.hasLoadedNamespace.bind(c)},c}},{key:"toJSON",value:function(){return{options:this.options,store:this.store,language:this.language,languages:this.languages,resolvedLanguage:this.resolvedLanguage}}}]),n}(Ol);$s(Jh,"createInstance",function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;return new Jh(e,t)});var li=Jh.createInstance();li.createInstance=Jh.createInstance;li.createInstance;li.dir;li.init;li.loadResources;li.reloadResources;li.use;li.changeLanguage;li.getFixedT;var _1=li.t;li.exists;li.setDefaultNamespace;li.hasLoadedNamespace;li.loadNamespaces;li.loadLanguages;const R1={TOKEN_MALFORMED:"token_malformed",TOKEN_EXPIRED:"token_expired"},I1=e=>{window.location.href=`${e}/authentication/login?callbackUrl=${window.location.href}`},A1=e=>{window.location.href=`${e}/authentication/logout?callbackUrl=${window.location.href}`},Ls=DI.create({withCredentials:!0});let Ig=!1,Nv=[];const v0=e=>{Nv.forEach(t=>{e?t.reject(e):t.resolve()}),Nv=[]};function M1(e,t){var o,s,l,c,d,v,p;const n=e.config,r=(s=(o=e.response)==null?void 0:o.data)==null?void 0:s.errorMessage,i=r===R1.TOKEN_EXPIRED;return((l=e.response)==null?void 0:l.status)===401&&i&&!n._retry?Ig?new Promise((S,T)=>{Nv.push({resolve:S,reject:T})}).then(()=>Ls(n)).catch(S=>Promise.reject(S)):(n._retry=!0,Ig=!0,Ls.post("/authentication/api/v1/auth/refresh-token",void 0,{baseURL:window.env.AUTHEN_DOMAIN}).then(()=>(v0(null),Ls(n))).catch(S=>(v0(S),Promise.reject(S))).finally(()=>{Ig=!1})):((c=e.response)==null?void 0:c.status)===401&&!i?I1(window.env.AUTHEN_DOMAIN):(((d=e.response)==null?void 0:d.status)===403?(v=t==null?void 0:t.handle403)==null||v.call(t,e):(!(t!=null&&t.disabledPushNotify)&&Rp(_1(`${r||"Something went wrong!"}`)),(p=t==null?void 0:t.handleOtherError)==null||p.call(t,e)),r&&e.response&&e.response.data&&(e.response.data.message=r),Promise.reject(e))}const fA=Ls.interceptors.response.use(e=>e,async e=>M1(e)),L1=Q.createContext({}),dA=({children:e})=>{const[t,n]=Q.useState(!0),[r,i]=Q.useState({all:{rows:[],total:0},unread:{rows:[],total:0}}),o=()=>{n(!t)},s=()=>{n(!0)};return st.jsx(L1.Provider,{value:{isOpen:t,toggleOpen:o,setShowModalFalse:s,notidata:r,setNotiData:i},children:e})};var N1={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},m0=Q.createContext&&Q.createContext(N1),hA=["attr","size","title"];function pA(e,t){if(e==null)return{};var n=gA(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function gA(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o<r.length;o++)i=r[o],!(t.indexOf(i)>=0)&&(n[i]=e[i]);return n}function Qh(){return Qh=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Qh.apply(this,arguments)}function y0(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function ep(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?y0(Object(n),!0).forEach(function(r){vA(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):y0(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function vA(e,t,n){return t=mA(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function mA(e){var t=yA(e,"string");return typeof t=="symbol"?t:String(t)}function yA(e,t){if(typeof e!="object"||e===null)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function F1(e){return e&&e.map((t,n)=>Q.createElement(t.tag,ep({key:n},t.attr),F1(t.child)))}function Dp(e){return t=>Q.createElement(bA,Qh({attr:ep({},e.attr)},t),F1(e.child))}function bA(e){var t=n=>{var{attr:r,size:i,title:o}=e,s=pA(e,hA),l=i||n.size||"1em",c;return n.className&&(c=n.className),e.className&&(c=(c?c+" ":"")+e.className),Q.createElement("svg",Qh({stroke:"currentColor",fill:"currentColor",strokeWidth:"0"},n.attr,r,s,{className:c,style:ep(ep({color:e.color||n.color},n.style),e.style),height:l,width:l,xmlns:"http://www.w3.org/2000/svg"}),o&&Q.createElement("title",null,o),e.children)};return m0!==void 0?Q.createElement(m0.Consumer,null,n=>t(n)):t(N1)}function wA(e){return Dp({tag:"svg",attr:{viewBox:"0 0 1024 1024"},child:[{tag:"path",attr:{d:"M689 165.1L308.2 493.5c-10.9 9.4-10.9 27.5 0 37L689 858.9c14.2 12.2 35 1.2 35-18.5V183.6c0-19.7-20.8-30.7-35-18.5z"},child:[]}]})(e)}function xA(e){return Dp({tag:"svg",attr:{viewBox:"0 0 1024 1024"},child:[{tag:"path",attr:{d:"M715.8 493.5L335 165.1c-14.2-12.2-35-1.2-35 18.5v656.8c0 19.7 20.8 30.7 35 18.5l380.8-328.4c10.9-9.4 10.9-27.6 0-37z"},child:[]}]})(e)}const j1=e=>{const t={...e.colors};return _c.createTheme({palette:{primary:{main:t.primary300,contrastText:t.textPrimary},secondary:{main:t.secondary,contrastText:t.textPrimary},warning:{main:t.warning,contrastText:t.textPrimary},error:{main:t.danger,contrastText:t.textPrimary}},typography:{fontFamily:"TT Firs Neue Trl",button:{textTransform:"none",fontSize:"0.875rem",fontWeight:400,boxShadow:"none"},body1:{fontSize:"0.875rem",fontWeight:400},body2:{fontSize:"0.75rem"},h6:{fontSize:"0.875rem",fontWeight:500},h5:{fontSize:"1rem",fontWeight:500},h4:{fontSize:"1.25rem",fontWeight:500},h3:{fontSize:"1.5rem",fontWeight:500},h2:{fontSize:"2rem",fontWeight:500},h1:{fontSize:"2.5rem",fontWeight:500},subtitle1:{fontSize:"0.75rem"},subtitle2:{fontSize:"0.625rem"}},components:{MuiIconButton:{styleOverrides:{root:{},sizeSmall:{}}},MuiButton:{styleOverrides:{root:{boxShadow:"none !important",padding:"8px 32px",borderWidth:1,borderRadius:3,fontWeight:400}},variants:[{props:{variant:"primary"},style:{backgroundColor:t.primary300,color:t.buttonText,"&:hover":{backgroundColor:t.buttonHover||t.primary300},"&.Mui-disabled":{backgroundColor:t.grey200}}},{props:{variant:"contained",color:"error"},style:{color:t.white}},{props:{variant:"confirm"},style:{backgroundColor:t.danger,color:t.white,"&:hover":{backgroundColor:t.dangerDark},"&.Mui-disabled":{backgroundColor:t.grey200}}},{props:{variant:"cancel"},style:{backgroundColor:t.grey300,color:t.textPrimary,"&:hover":{backgroundColor:t.grey400}}},{props:{variant:"outlinedPrimary"},style:{color:t.primary500,border:"1px solid",borderColor:t.primary500,"&:hover":{backgroundColor:"inherit"}}},{props:{variant:"outLinedDanger"},style:{color:t.danger,border:"1px solid",borderColor:t.danger,"&:hover":{backgroundColor:"inherit"}}},{props:{size:"small"},style:{fontSize:"12px",lineHeight:"normal",borderRadius:"3px",padding:"4px 16px"}}]},MuiAppBar:{styleOverrides:{root:{backgroundColor:t.appBarBgColor,color:t.appBarColor}}},MuiSelect:{defaultProps:{MenuProps:{PaperProps:{sx:{boxShadow:"none",border:1,borderStyle:"solid",borderColor:t.grey300,mt:"5px"}},MenuListProps:{sx:{padding:"5px","& .MuiMenuItem-root":{fontWeight:400,minHeight:0,borderRadius:"5px","&:hover":{backgroundColor:t.grey100},"&.Mui-selected":{backgroundColor:t.primary200}}}}}},styleOverrides:{select:{padding:"9.94px 5px 9.94px 15px"}}},MuiMenuItem:{styleOverrides:{root:{"&.Mui-selected":{backgroundColor:t.primary200,"&:hover":{backgroundColor:t.primary200}}}}},MuiPaginationItem:{defaultProps:{components:{previous:wA,next:xA}},styleOverrides:{root:{"& svg":{width:"10px"},border:"none",fontSize:"14px",lineHeight:"1.5rem",borderRadius:"7px","&.Mui-selected":{backgroundColor:`${t.primary300}1a !important`},"&.MuiPaginationItem-previousNext":{backgroundColor:t.grey200}}}},MuiChip:{styleOverrides:{root:{borderRadius:"5px",fontSize:"10px",lineHeight:"12px",fontWeight:400,"& .MuiChip-label":{lineHeight:"normal"}},avatar:{width:"10px"},colorSuccess:{color:t.success,backgroundColor:t.successLight},colorWarning:{color:t.warning,backgroundColor:t.warningLight},colorError:{color:t.danger,backgroundColor:t.dangerLight},colorSecondary:{color:t.linkPrimary,backgroundColor:t.linkLight}}},MuiTab:{styleOverrides:{root:{flexDirection:"row",alignContent:"center",gap:"8px",textTransform:"capitalize",fontSize:"14px",borderRadius:0,marginRight:0,height:"48px",minWidth:"100px",padding:"12px 16px",fontWeight:"500","& svg":{mb:"0 !important"},minHeight:"auto","& .chart-icon":{fill:t.grey600},"& .detail-icon":{stroke:t.grey600},color:t.grey400,"&.Mui-selected":{color:t.primary400}}}},MuiTabs:{styleOverrides:{indicator:{backgroundColor:t.primary400}}},MuiDrawer:{defaultProps:{},styleOverrides:{root:{"&.MuiDrawer-paper":{overflowY:"unset"},"& .MuiDrawer-paper":{zIndex:9},"&.MuiPaper-root":{border:"none",background:t.grey100,pt:12,zIndex:9}}}},MuiTextField:{defaultProps:{InputProps:{sx:{"& .Mui-disabled":{background:t.grey200}}},InputLabelProps:{shrink:!0}},styleOverrides:{root:{backgroundColor:t.white,"& .MuiOutlinedInput-input":{padding:"0px 16px 0px 12px",fontWeight:400,height:40,fontSize:"14px",border:1,borderRadius:4,"&::placeholder":{color:t.grey600}},"& .MuiFormLabel-asterisk":{color:t.danger}}}},MuiFormGroup:{styleOverrides:{root:{}}},MuiFormHelperText:{defaultProps:{sx:{fontSize:12}},styleOverrides:{}},MuiAutocomplete:{defaultProps:{sx:{"& .MuiPaper-root":{padding:"5px"}}},styleOverrides:{root:{"& .MuiSvgIcon-root":{width:"20px",height:"20px"},"& .MuiAutocomplete-tag":{margin:0},"& .MuiButtonBase-root":{marginRight:"2px !important",height:"max-content",padding:"2px"},"& .MuiOutlinedInput-root":{padding:"7.45px 55px 7.45px 10px !important"},"& svg":{},"& #checkboxes-tags-demo":{padding:"6px 4px"},"& .MuiAutocomplete-endAdornment":{top:"calc(50% - 12px)"}}}},MuiTableHead:{styleOverrides:{root:{"& th":{fontSize:"14px",padding:"8px 16px"}}}},MuiTableBody:{styleOverrides:{root:{"& th,td":{fontSize:"14px",padding:"8px 16px",height:"45px"},"& .MuiTableCell-root":{borderBottom:`1px solid ${t.grey300}`}}}},MuiRadio:{defaultProps:{sx:{"&.MuiButtonBase-root":{padding:"5px"}}},styleOverrides:{root:{"& .MuiSvgIcon-root":{fontSize:16},color:t.grey600,"&.Mui-checked":{color:t.success},"&.Mui-disabled":{color:t.grey600}}}},MuiTooltip:{defaultProps:{placement:"top"},styleOverrides:{tooltip:{fontSize:"10px",backgroundColor:t.grey600,color:t.white,"& .MuiTooltip-arrow":{color:t.grey600}}}}}})};function SA(e,t){const n={...e};return t==null||t.forEach(r=>{r.children&&r.children.forEach(i=>{n[i.key]=i.color.trim()})}),n}function TA(e){var s,l;const{data:t,isFetching:n}=Sd.useQuery(["customTheme"],()=>e!=null&&e.url?fetch(e.url).then(c=>c.json()):void 0,{enabled:!!(e!=null&&e.url)&&(e==null?void 0:e.enabled),refetchOnWindowFocus:!1,cacheTime:0}),r=SA(so,(s=t==null?void 0:t.theme)==null?void 0:s.keyColor);console.log("🚀 ~ useThemeContext ~ isFetching:",n);const i=j1({colors:r}),o=(l=t==null?void 0:t.theme)==null?void 0:l.image;return{colors:r,theme:i,logo:o,isFetching:n}}const B1=Q.createContext({}),CA=()=>Q.useContext(B1),EA=e=>{var o;const{children:t,brandTheme:n}=e,r=TA(n),i=((o=e.customTheme)==null?void 0:o.call(e,r.colors))||r.theme;return st.jsx(B1.Provider,{value:r,children:st.jsx(_c.ThemeProvider,{theme:i,children:t})})},kA=`*,:before,:after{box-sizing:border-box;border-width:0;border-style:solid;border-color:#e5e7eb}html,:host{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-tap-highlight-color:transparent}body{margin:0;line-height:inherit}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}button,input,optgroup,select,textarea{font-family:inherit;font-feature-settings:inherit;font-variation-settings:inherit;font-size:100%;font-weight:inherit;line-height:inherit;color:inherit;margin:0;padding:0}button,select{text-transform:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dl,dd,h1,h2,h3,h4,h5,h6,hr,figure,p,pre{margin:0}fieldset{margin:0;padding:0}legend{padding:0}ol,ul,menu{list-style:none;margin:0;padding:0}dialog{padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{opacity:1;color:#9ca3af}input::placeholder,textarea::placeholder{opacity:1;color:#9ca3af}button,[role=button]{cursor:pointer}:disabled{cursor:default}img,svg,video,canvas,audio,iframe,embed,object{display:block;vertical-align:middle}img,video{max-width:100%;height:auto}[hidden]{display:none}
|
|
3
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function LI(e){return E1(e)||MI(e)||k1(e)||O1()}function Jb(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Qb(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Jb(Object(n),!0).forEach(function(r){$s(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Jb(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}var NI={type:"logger",log:function(t){this.output("log",t)},warn:function(t){this.output("warn",t)},error:function(t){this.output("error",t)},output:function(t,n){console&&console[t]&&console[t].apply(console,n)}},FI=function(){function e(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};ta(this,e),this.init(t,n)}return na(e,[{key:"init",value:function(n){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.prefix=r.prefix||"i18next:",this.logger=n||NI,this.options=r,this.debug=r.debug}},{key:"setDebug",value:function(n){this.debug=n}},{key:"log",value:function(){for(var n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];return this.forward(r,"log","",!0)}},{key:"warn",value:function(){for(var n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];return this.forward(r,"warn","",!0)}},{key:"error",value:function(){for(var n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];return this.forward(r,"error","")}},{key:"deprecate",value:function(){for(var n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];return this.forward(r,"warn","WARNING DEPRECATED: ",!0)}},{key:"forward",value:function(n,r,i,o){return o&&!this.debug?null:(typeof n[0]=="string"&&(n[0]="".concat(i).concat(this.prefix," ").concat(n[0])),this.logger[r](n))}},{key:"create",value:function(n){return new e(this.logger,Qb(Qb({},{prefix:"".concat(this.prefix,":").concat(n,":")}),this.options))}},{key:"clone",value:function(n){return n=n||this.options,n.prefix=n.prefix||this.prefix,new e(this.logger,n)}}]),e}(),Ms=new FI,Ol=function(){function e(){ta(this,e),this.observers={}}return na(e,[{key:"on",value:function(n,r){var i=this;return n.split(" ").forEach(function(o){i.observers[o]=i.observers[o]||[],i.observers[o].push(r)}),this}},{key:"off",value:function(n,r){if(this.observers[n]){if(!r){delete this.observers[n];return}this.observers[n]=this.observers[n].filter(function(i){return i!==r})}}},{key:"emit",value:function(n){for(var r=arguments.length,i=new Array(r>1?r-1:0),o=1;o<r;o++)i[o-1]=arguments[o];if(this.observers[n]){var s=[].concat(this.observers[n]);s.forEach(function(c){c.apply(void 0,i)})}if(this.observers["*"]){var l=[].concat(this.observers["*"]);l.forEach(function(c){c.apply(c,[n].concat(i))})}}}]),e}();function Kf(){var e,t,n=new Promise(function(r,i){e=r,t=i});return n.resolve=e,n.reject=t,n}function e0(e){return e==null?"":""+e}function jI(e,t,n){e.forEach(function(r){t[r]&&(n[r]=t[r])})}function Um(e,t,n){function r(l){return l&&l.indexOf("###")>-1?l.replace(/###/g,"."):l}function i(){return!e||typeof e=="string"}for(var o=typeof t!="string"?[].concat(t):t.split(".");o.length>1;){if(i())return{};var s=r(o.shift());!e[s]&&n&&(e[s]=new n),Object.prototype.hasOwnProperty.call(e,s)?e=e[s]:e={}}return i()?{}:{obj:e,k:r(o.shift())}}function t0(e,t,n){var r=Um(e,t,Object),i=r.obj,o=r.k;i[o]=n}function BI(e,t,n,r){var i=Um(e,t,Object),o=i.obj,s=i.k;o[s]=o[s]||[],r&&(o[s]=o[s].concat(n)),r||o[s].push(n)}function Kh(e,t){var n=Um(e,t),r=n.obj,i=n.k;if(r)return r[i]}function $I(e,t,n){var r=Kh(e,n);return r!==void 0?r:Kh(t,n)}function D1(e,t,n){for(var r in t)r!=="__proto__"&&r!=="constructor"&&(r in e?typeof e[r]=="string"||e[r]instanceof String||typeof t[r]=="string"||t[r]instanceof String?n&&(e[r]=t[r]):D1(e[r],t[r],n):e[r]=t[r]);return e}function df(e){return e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&")}var VI={"&":"&","<":"<",">":">",'"':""","'":"'","/":"/"};function HI(e){return typeof e=="string"?e.replace(/[&<>"'\/]/g,function(t){return VI[t]}):e}var Op=typeof window<"u"&&window.navigator&&typeof window.navigator.userAgentData>"u"&&window.navigator.userAgent&&window.navigator.userAgent.indexOf("MSIE")>-1,UI=[" ",",","?","!",";"];function WI(e,t,n){t=t||"",n=n||"";var r=UI.filter(function(l){return t.indexOf(l)<0&&n.indexOf(l)<0});if(r.length===0)return!0;var i=new RegExp("(".concat(r.map(function(l){return l==="?"?"\\?":l}).join("|"),")")),o=!i.test(e);if(!o){var s=e.indexOf(n);s>0&&!i.test(e.substring(0,s))&&(o=!0)}return o}function Zh(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:".";if(e){if(e[t])return e[t];for(var r=t.split(n),i=e,o=0;o<r.length;++o){if(!i||typeof i[r[o]]=="string"&&o+1<r.length)return;if(i[r[o]]===void 0){for(var s=2,l=r.slice(o,o+s).join(n),c=i[l];c===void 0&&r.length>o+s;)s++,l=r.slice(o,o+s).join(n),c=i[l];if(c===void 0)return;if(c===null)return null;if(t.endsWith(l)){if(typeof c=="string")return c;if(l&&typeof c[l]=="string")return c[l]}var d=r.slice(o+s).join(n);return d?Zh(c,d,n):void 0}i=i[r[o]]}return i}}function n0(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function uh(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?n0(Object(n),!0).forEach(function(r){$s(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):n0(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function zI(e){var t=YI();return function(){var r=Bs(e),i;if(t){var o=Bs(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return Bd(this,i)}}function YI(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}var GI=function(e){kp(n,e);var t=zI(n);function n(r){var i,o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{ns:["translation"],defaultNS:"translation"};return ta(this,n),i=t.call(this),Op&&Ol.call(Ou(i)),i.data=r||{},i.options=o,i.options.keySeparator===void 0&&(i.options.keySeparator="."),i.options.ignoreJSONStructure===void 0&&(i.options.ignoreJSONStructure=!0),i}return na(n,[{key:"addNamespaces",value:function(i){this.options.ns.indexOf(i)<0&&this.options.ns.push(i)}},{key:"removeNamespaces",value:function(i){var o=this.options.ns.indexOf(i);o>-1&&this.options.ns.splice(o,1)}},{key:"getResource",value:function(i,o,s){var l=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},c=l.keySeparator!==void 0?l.keySeparator:this.options.keySeparator,d=l.ignoreJSONStructure!==void 0?l.ignoreJSONStructure:this.options.ignoreJSONStructure,v=[i,o];s&&typeof s!="string"&&(v=v.concat(s)),s&&typeof s=="string"&&(v=v.concat(c?s.split(c):s)),i.indexOf(".")>-1&&(v=i.split("."));var p=Kh(this.data,v);return p||!d||typeof s!="string"?p:Zh(this.data&&this.data[i]&&this.data[i][o],s,c)}},{key:"addResource",value:function(i,o,s,l){var c=arguments.length>4&&arguments[4]!==void 0?arguments[4]:{silent:!1},d=c.keySeparator!==void 0?c.keySeparator:this.options.keySeparator,v=[i,o];s&&(v=v.concat(d?s.split(d):s)),i.indexOf(".")>-1&&(v=i.split("."),l=o,o=v[1]),this.addNamespaces(o),t0(this.data,v,l),c.silent||this.emit("added",i,o,s,l)}},{key:"addResources",value:function(i,o,s){var l=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{silent:!1};for(var c in s)(typeof s[c]=="string"||Object.prototype.toString.apply(s[c])==="[object Array]")&&this.addResource(i,o,c,s[c],{silent:!0});l.silent||this.emit("added",i,o,s)}},{key:"addResourceBundle",value:function(i,o,s,l,c){var d=arguments.length>5&&arguments[5]!==void 0?arguments[5]:{silent:!1},v=[i,o];i.indexOf(".")>-1&&(v=i.split("."),l=s,s=o,o=v[1]),this.addNamespaces(o);var p=Kh(this.data,v)||{};l?D1(p,s,c):p=uh(uh({},p),s),t0(this.data,v,p),d.silent||this.emit("added",i,o,s)}},{key:"removeResourceBundle",value:function(i,o){this.hasResourceBundle(i,o)&&delete this.data[i][o],this.removeNamespaces(o),this.emit("removed",i,o)}},{key:"hasResourceBundle",value:function(i,o){return this.getResource(i,o)!==void 0}},{key:"getResourceBundle",value:function(i,o){return o||(o=this.options.defaultNS),this.options.compatibilityAPI==="v1"?uh(uh({},{}),this.getResource(i,o)):this.getResource(i,o)}},{key:"getDataByLanguage",value:function(i){return this.data[i]}},{key:"hasLanguageSomeTranslations",value:function(i){var o=this.getDataByLanguage(i),s=o&&Object.keys(o)||[];return!!s.find(function(l){return o[l]&&Object.keys(o[l]).length>0})}},{key:"toJSON",value:function(){return this.data}}]),n}(Ol),P1={processors:{},addPostProcessor:function(t){this.processors[t.name]=t},handle:function(t,n,r,i,o){var s=this;return t.forEach(function(l){s.processors[l]&&(n=s.processors[l].process(n,r,i,o))}),n}};function r0(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Ai(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?r0(Object(n),!0).forEach(function(r){$s(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):r0(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function qI(e){var t=XI();return function(){var r=Bs(e),i;if(t){var o=Bs(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return Bd(this,i)}}function XI(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}var i0={},o0=function(e){kp(n,e);var t=qI(n);function n(r){var i,o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return ta(this,n),i=t.call(this),Op&&Ol.call(Ou(i)),jI(["resourceStore","languageUtils","pluralResolver","interpolator","backendConnector","i18nFormat","utils"],r,Ou(i)),i.options=o,i.options.keySeparator===void 0&&(i.options.keySeparator="."),i.logger=Ms.create("translator"),i}return na(n,[{key:"changeLanguage",value:function(i){i&&(this.language=i)}},{key:"exists",value:function(i){var o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{interpolation:{}};if(i==null)return!1;var s=this.resolve(i,o);return s&&s.res!==void 0}},{key:"extractFromKey",value:function(i,o){var s=o.nsSeparator!==void 0?o.nsSeparator:this.options.nsSeparator;s===void 0&&(s=":");var l=o.keySeparator!==void 0?o.keySeparator:this.options.keySeparator,c=o.ns||this.options.defaultNS||[],d=s&&i.indexOf(s)>-1,v=!this.options.userDefinedKeySeparator&&!o.keySeparator&&!this.options.userDefinedNsSeparator&&!o.nsSeparator&&!WI(i,s,l);if(d&&!v){var p=i.match(this.interpolator.nestingRegexp);if(p&&p.length>0)return{key:i,namespaces:c};var S=i.split(s);(s!==l||s===l&&this.options.ns.indexOf(S[0])>-1)&&(c=S.shift()),i=S.join(l)}return typeof c=="string"&&(c=[c]),{key:i,namespaces:c}}},{key:"translate",value:function(i,o,s){var l=this;if(Jo(o)!=="object"&&this.options.overloadTranslationOptionHandler&&(o=this.options.overloadTranslationOptionHandler(arguments)),Jo(o)==="object"&&(o=Ai({},o)),o||(o={}),i==null)return"";Array.isArray(i)||(i=[String(i)]);var c=o.returnDetails!==void 0?o.returnDetails:this.options.returnDetails,d=o.keySeparator!==void 0?o.keySeparator:this.options.keySeparator,v=this.extractFromKey(i[i.length-1],o),p=v.key,S=v.namespaces,T=S[S.length-1],_=o.lng||this.language,R=o.appendNamespaceToCIMode||this.options.appendNamespaceToCIMode;if(_&&_.toLowerCase()==="cimode"){if(R){var L=o.nsSeparator||this.options.nsSeparator;return c?{res:"".concat(T).concat(L).concat(p),usedKey:p,exactUsedKey:p,usedLng:_,usedNS:T}:"".concat(T).concat(L).concat(p)}return c?{res:p,usedKey:p,exactUsedKey:p,usedLng:_,usedNS:T}:p}var I=this.resolve(i,o),U=I&&I.res,z=I&&I.usedKey||p,re=I&&I.exactUsedKey||p,Z=Object.prototype.toString.apply(U),he=["[object Number]","[object Function]","[object RegExp]"],x=o.joinArrays!==void 0?o.joinArrays:this.options.joinArrays,ce=!this.i18nFormat||this.i18nFormat.handleAsObject,ae=typeof U!="string"&&typeof U!="boolean"&&typeof U!="number";if(ce&&U&&ae&&he.indexOf(Z)<0&&!(typeof x=="string"&&Z==="[object Array]")){if(!o.returnObjects&&!this.options.returnObjects){this.options.returnedObjectHandler||this.logger.warn("accessing an object - but returnObjects options is not enabled!");var je=this.options.returnedObjectHandler?this.options.returnedObjectHandler(z,U,Ai(Ai({},o),{},{ns:S})):"key '".concat(p," (").concat(this.language,")' returned an object instead of string.");return c?(I.res=je,I):je}if(d){var qe=Z==="[object Array]",We=qe?[]:{},rt=qe?re:z;for(var nt in U)if(Object.prototype.hasOwnProperty.call(U,nt)){var ye="".concat(rt).concat(d).concat(nt);We[nt]=this.translate(ye,Ai(Ai({},o),{joinArrays:!1,ns:S})),We[nt]===ye&&(We[nt]=U[nt])}U=We}}else if(ce&&typeof x=="string"&&Z==="[object Array]")U=U.join(x),U&&(U=this.extendTranslation(U,i,o,s));else{var De=!1,He=!1,Je=o.count!==void 0&&typeof o.count!="string",at=n.hasDefaultValue(o),Oe=Je?this.pluralResolver.getSuffix(_,o.count,o):"",xe=o["defaultValue".concat(Oe)]||o.defaultValue;!this.isValidLookup(U)&&at&&(De=!0,U=xe),this.isValidLookup(U)||(He=!0,U=p);var Ue=o.missingKeyNoValueFallbackToKey||this.options.missingKeyNoValueFallbackToKey,Ve=Ue&&He?void 0:U,Re=at&&xe!==U&&this.options.updateMissing;if(He||De||Re){if(this.logger.log(Re?"updateKey":"missingKey",_,T,p,Re?xe:U),d){var Me=this.resolve(p,Ai(Ai({},o),{},{keySeparator:!1}));Me&&Me.res&&this.logger.warn("Seems the loaded translations were in flat JSON format instead of nested. Either set keySeparator: false on init or make sure your translations are published in nested format.")}var Xe=[],lt=this.languageUtils.getFallbackCodes(this.options.fallbackLng,o.lng||this.language);if(this.options.saveMissingTo==="fallback"&<&<[0])for(var mt=0;mt<lt.length;mt++)Xe.push(lt[mt]);else this.options.saveMissingTo==="all"?Xe=this.languageUtils.toResolveHierarchy(o.lng||this.language):Xe.push(o.lng||this.language);var wt=function(Et,it,$t){var Ht=at&&$t!==U?$t:Ve;l.options.missingKeyHandler?l.options.missingKeyHandler(Et,T,it,Ht,Re,o):l.backendConnector&&l.backendConnector.saveMissing&&l.backendConnector.saveMissing(Et,T,it,Ht,Re,o),l.emit("missingKey",Et,T,it,U)};this.options.saveMissing&&(this.options.saveMissingPlurals&&Je?Xe.forEach(function(vt){l.pluralResolver.getSuffixes(vt,o).forEach(function(Et){wt([vt],p+Et,o["defaultValue".concat(Et)]||xe)})}):wt(Xe,p,xe))}U=this.extendTranslation(U,i,o,I,s),He&&U===p&&this.options.appendNamespaceToMissingKey&&(U="".concat(T,":").concat(p)),(He||De)&&this.options.parseMissingKeyHandler&&(this.options.compatibilityAPI!=="v1"?U=this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey?"".concat(T,":").concat(p):p,De?U:void 0):U=this.options.parseMissingKeyHandler(U))}return c?(I.res=U,I):U}},{key:"extendTranslation",value:function(i,o,s,l,c){var d=this;if(this.i18nFormat&&this.i18nFormat.parse)i=this.i18nFormat.parse(i,Ai(Ai({},this.options.interpolation.defaultVariables),s),l.usedLng,l.usedNS,l.usedKey,{resolved:l});else if(!s.skipInterpolation){s.interpolation&&this.interpolator.init(Ai(Ai({},s),{interpolation:Ai(Ai({},this.options.interpolation),s.interpolation)}));var v=typeof i=="string"&&(s&&s.interpolation&&s.interpolation.skipOnVariables!==void 0?s.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables),p;if(v){var S=i.match(this.interpolator.nestingRegexp);p=S&&S.length}var T=s.replace&&typeof s.replace!="string"?s.replace:s;if(this.options.interpolation.defaultVariables&&(T=Ai(Ai({},this.options.interpolation.defaultVariables),T)),i=this.interpolator.interpolate(i,T,s.lng||this.language,s),v){var _=i.match(this.interpolator.nestingRegexp),R=_&&_.length;p<R&&(s.nest=!1)}!s.lng&&this.options.compatibilityAPI!=="v1"&&l&&l.res&&(s.lng=l.usedLng),s.nest!==!1&&(i=this.interpolator.nest(i,function(){for(var U=arguments.length,z=new Array(U),re=0;re<U;re++)z[re]=arguments[re];return c&&c[0]===z[0]&&!s.context?(d.logger.warn("It seems you are nesting recursively key: ".concat(z[0]," in key: ").concat(o[0])),null):d.translate.apply(d,z.concat([o]))},s)),s.interpolation&&this.interpolator.reset()}var L=s.postProcess||this.options.postProcess,I=typeof L=="string"?[L]:L;return i!=null&&I&&I.length&&s.applyPostProcessor!==!1&&(i=P1.handle(I,i,o,this.options&&this.options.postProcessPassResolved?Ai({i18nResolved:l},s):s,this)),i}},{key:"resolve",value:function(i){var o=this,s=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},l,c,d,v,p;return typeof i=="string"&&(i=[i]),i.forEach(function(S){if(!o.isValidLookup(l)){var T=o.extractFromKey(S,s),_=T.key;c=_;var R=T.namespaces;o.options.fallbackNS&&(R=R.concat(o.options.fallbackNS));var L=s.count!==void 0&&typeof s.count!="string",I=L&&!s.ordinal&&s.count===0&&o.pluralResolver.shouldUseIntlApi(),U=s.context!==void 0&&(typeof s.context=="string"||typeof s.context=="number")&&s.context!=="",z=s.lngs?s.lngs:o.languageUtils.toResolveHierarchy(s.lng||o.language,s.fallbackLng);R.forEach(function(re){o.isValidLookup(l)||(p=re,!i0["".concat(z[0],"-").concat(re)]&&o.utils&&o.utils.hasLoadedNamespace&&!o.utils.hasLoadedNamespace(p)&&(i0["".concat(z[0],"-").concat(re)]=!0,o.logger.warn('key "'.concat(c,'" for languages "').concat(z.join(", "),`" won't get resolved as namespace "`).concat(p,'" 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!!!")),z.forEach(function(Z){if(!o.isValidLookup(l)){v=Z;var he=[_];if(o.i18nFormat&&o.i18nFormat.addLookupKeys)o.i18nFormat.addLookupKeys(he,_,Z,re,s);else{var x;L&&(x=o.pluralResolver.getSuffix(Z,s.count,s));var ce="".concat(o.options.pluralSeparator,"zero");if(L&&(he.push(_+x),I&&he.push(_+ce)),U){var ae="".concat(_).concat(o.options.contextSeparator).concat(s.context);he.push(ae),L&&(he.push(ae+x),I&&he.push(ae+ce))}}for(var je;je=he.pop();)o.isValidLookup(l)||(d=je,l=o.getResource(Z,re,je,s))}}))})}}),{res:l,usedKey:c,exactUsedKey:d,usedLng:v,usedNS:p}}},{key:"isValidLookup",value:function(i){return i!==void 0&&!(!this.options.returnNull&&i===null)&&!(!this.options.returnEmptyString&&i==="")}},{key:"getResource",value:function(i,o,s){var l=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};return this.i18nFormat&&this.i18nFormat.getResource?this.i18nFormat.getResource(i,o,s,l):this.resourceStore.getResource(i,o,s,l)}}],[{key:"hasDefaultValue",value:function(i){var o="defaultValue";for(var s in i)if(Object.prototype.hasOwnProperty.call(i,s)&&o===s.substring(0,o.length)&&i[s]!==void 0)return!0;return!1}}]),n}(Ol);function Rg(e){return e.charAt(0).toUpperCase()+e.slice(1)}var a0=function(){function e(t){ta(this,e),this.options=t,this.supportedLngs=this.options.supportedLngs||!1,this.logger=Ms.create("languageUtils")}return na(e,[{key:"getScriptPartFromCode",value:function(n){if(!n||n.indexOf("-")<0)return null;var r=n.split("-");return r.length===2||(r.pop(),r[r.length-1].toLowerCase()==="x")?null:this.formatLanguageCode(r.join("-"))}},{key:"getLanguagePartFromCode",value:function(n){if(!n||n.indexOf("-")<0)return n;var r=n.split("-");return this.formatLanguageCode(r[0])}},{key:"formatLanguageCode",value:function(n){if(typeof n=="string"&&n.indexOf("-")>-1){var r=["hans","hant","latn","cyrl","cans","mong","arab"],i=n.split("-");return this.options.lowerCaseLng?i=i.map(function(o){return o.toLowerCase()}):i.length===2?(i[0]=i[0].toLowerCase(),i[1]=i[1].toUpperCase(),r.indexOf(i[1].toLowerCase())>-1&&(i[1]=Rg(i[1].toLowerCase()))):i.length===3&&(i[0]=i[0].toLowerCase(),i[1].length===2&&(i[1]=i[1].toUpperCase()),i[0]!=="sgn"&&i[2].length===2&&(i[2]=i[2].toUpperCase()),r.indexOf(i[1].toLowerCase())>-1&&(i[1]=Rg(i[1].toLowerCase())),r.indexOf(i[2].toLowerCase())>-1&&(i[2]=Rg(i[2].toLowerCase()))),i.join("-")}return this.options.cleanCode||this.options.lowerCaseLng?n.toLowerCase():n}},{key:"isSupportedCode",value:function(n){return(this.options.load==="languageOnly"||this.options.nonExplicitSupportedLngs)&&(n=this.getLanguagePartFromCode(n)),!this.supportedLngs||!this.supportedLngs.length||this.supportedLngs.indexOf(n)>-1}},{key:"getBestMatchFromCodes",value:function(n){var r=this;if(!n)return null;var i;return n.forEach(function(o){if(!i){var s=r.formatLanguageCode(o);(!r.options.supportedLngs||r.isSupportedCode(s))&&(i=s)}}),!i&&this.options.supportedLngs&&n.forEach(function(o){if(!i){var s=r.getLanguagePartFromCode(o);if(r.isSupportedCode(s))return i=s;i=r.options.supportedLngs.find(function(l){if(l===s)return l;if(!(l.indexOf("-")<0&&s.indexOf("-")<0)&&l.indexOf(s)===0)return l})}}),i||(i=this.getFallbackCodes(this.options.fallbackLng)[0]),i}},{key:"getFallbackCodes",value:function(n,r){if(!n)return[];if(typeof n=="function"&&(n=n(r)),typeof n=="string"&&(n=[n]),Object.prototype.toString.apply(n)==="[object Array]")return n;if(!r)return n.default||[];var i=n[r];return i||(i=n[this.getScriptPartFromCode(r)]),i||(i=n[this.formatLanguageCode(r)]),i||(i=n[this.getLanguagePartFromCode(r)]),i||(i=n.default),i||[]}},{key:"toResolveHierarchy",value:function(n,r){var i=this,o=this.getFallbackCodes(r||this.options.fallbackLng||[],n),s=[],l=function(d){d&&(i.isSupportedCode(d)?s.push(d):i.logger.warn("rejecting language code not found in supportedLngs: ".concat(d)))};return typeof n=="string"&&n.indexOf("-")>-1?(this.options.load!=="languageOnly"&&l(this.formatLanguageCode(n)),this.options.load!=="languageOnly"&&this.options.load!=="currentOnly"&&l(this.getScriptPartFromCode(n)),this.options.load!=="currentOnly"&&l(this.getLanguagePartFromCode(n))):typeof n=="string"&&l(this.formatLanguageCode(n)),o.forEach(function(c){s.indexOf(c)<0&&l(i.formatLanguageCode(c))}),s}}]),e}(),KI=[{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}],ZI={1:function(t){return+(t>1)},2:function(t){return+(t!=1)},3:function(t){return 0},4:function(t){return t%10==1&&t%100!=11?0:t%10>=2&&t%10<=4&&(t%100<10||t%100>=20)?1:2},5:function(t){return t==0?0:t==1?1:t==2?2:t%100>=3&&t%100<=10?3:t%100>=11?4:5},6:function(t){return t==1?0:t>=2&&t<=4?1:2},7:function(t){return t==1?0:t%10>=2&&t%10<=4&&(t%100<10||t%100>=20)?1:2},8:function(t){return t==1?0:t==2?1:t!=8&&t!=11?2:3},9:function(t){return+(t>=2)},10:function(t){return t==1?0:t==2?1:t<7?2:t<11?3:4},11:function(t){return t==1||t==11?0:t==2||t==12?1:t>2&&t<20?2:3},12:function(t){return+(t%10!=1||t%100==11)},13:function(t){return+(t!==0)},14:function(t){return t==1?0:t==2?1:t==3?2:3},15:function(t){return t%10==1&&t%100!=11?0:t%10>=2&&(t%100<10||t%100>=20)?1:2},16:function(t){return t%10==1&&t%100!=11?0:t!==0?1:2},17:function(t){return t==1||t%10==1&&t%100!=11?0:1},18:function(t){return t==0?0:t==1?1:2},19:function(t){return t==1?0:t==0||t%100>1&&t%100<11?1:t%100>10&&t%100<20?2:3},20:function(t){return t==1?0:t==0||t%100>0&&t%100<20?1:2},21:function(t){return t%100==1?1:t%100==2?2:t%100==3||t%100==4?3:0},22:function(t){return t==1?0:t==2?1:(t<0||t>10)&&t%10==0?2:3}},JI=["v1","v2","v3"],s0={zero:0,one:1,two:2,few:3,many:4,other:5};function QI(){var e={};return KI.forEach(function(t){t.lngs.forEach(function(n){e[n]={numbers:t.nr,plurals:ZI[t.fc]}})}),e}var eA=function(){function e(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};ta(this,e),this.languageUtils=t,this.options=n,this.logger=Ms.create("pluralResolver"),(!this.options.compatibilityJSON||this.options.compatibilityJSON==="v4")&&(typeof Intl>"u"||!Intl.PluralRules)&&(this.options.compatibilityJSON="v3",this.logger.error("Your environment seems not to be Intl API compatible, use an Intl.PluralRules polyfill. Will fallback to the compatibilityJSON v3 format handling.")),this.rules=QI()}return na(e,[{key:"addRule",value:function(n,r){this.rules[n]=r}},{key:"getRule",value:function(n){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(this.shouldUseIntlApi())try{return new Intl.PluralRules(n,{type:r.ordinal?"ordinal":"cardinal"})}catch{return}return this.rules[n]||this.rules[this.languageUtils.getLanguagePartFromCode(n)]}},{key:"needsPlural",value:function(n){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=this.getRule(n,r);return this.shouldUseIntlApi()?i&&i.resolvedOptions().pluralCategories.length>1:i&&i.numbers.length>1}},{key:"getPluralFormsOfKey",value:function(n,r){var i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return this.getSuffixes(n,i).map(function(o){return"".concat(r).concat(o)})}},{key:"getSuffixes",value:function(n){var r=this,i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},o=this.getRule(n,i);return o?this.shouldUseIntlApi()?o.resolvedOptions().pluralCategories.sort(function(s,l){return s0[s]-s0[l]}).map(function(s){return"".concat(r.options.prepend).concat(s)}):o.numbers.map(function(s){return r.getSuffix(n,s,i)}):[]}},{key:"getSuffix",value:function(n,r){var i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},o=this.getRule(n,i);return o?this.shouldUseIntlApi()?"".concat(this.options.prepend).concat(o.select(r)):this.getSuffixRetroCompatible(o,r):(this.logger.warn("no plural rule found for: ".concat(n)),"")}},{key:"getSuffixRetroCompatible",value:function(n,r){var i=this,o=n.noAbs?n.plurals(r):n.plurals(Math.abs(r)),s=n.numbers[o];this.options.simplifyPluralSuffix&&n.numbers.length===2&&n.numbers[0]===1&&(s===2?s="plural":s===1&&(s=""));var l=function(){return i.options.prepend&&s.toString()?i.options.prepend+s.toString():s.toString()};return this.options.compatibilityJSON==="v1"?s===1?"":typeof s=="number"?"_plural_".concat(s.toString()):l():this.options.compatibilityJSON==="v2"||this.options.simplifyPluralSuffix&&n.numbers.length===2&&n.numbers[0]===1?l():this.options.prepend&&o.toString()?this.options.prepend+o.toString():o.toString()}},{key:"shouldUseIntlApi",value:function(){return!JI.includes(this.options.compatibilityJSON)}}]),e}();function u0(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function es(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?u0(Object(n),!0).forEach(function(r){$s(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):u0(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function l0(e,t,n){var r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:".",i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!0,o=$I(e,t,n);return!o&&i&&typeof n=="string"&&(o=Zh(e,n,r),o===void 0&&(o=Zh(t,n,r))),o}var tA=function(){function e(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};ta(this,e),this.logger=Ms.create("interpolator"),this.options=t,this.format=t.interpolation&&t.interpolation.format||function(n){return n},this.init(t)}return na(e,[{key:"init",value:function(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};n.interpolation||(n.interpolation={escapeValue:!0});var r=n.interpolation;this.escape=r.escape!==void 0?r.escape:HI,this.escapeValue=r.escapeValue!==void 0?r.escapeValue:!0,this.useRawValueToEscape=r.useRawValueToEscape!==void 0?r.useRawValueToEscape:!1,this.prefix=r.prefix?df(r.prefix):r.prefixEscaped||"{{",this.suffix=r.suffix?df(r.suffix):r.suffixEscaped||"}}",this.formatSeparator=r.formatSeparator?r.formatSeparator:r.formatSeparator||",",this.unescapePrefix=r.unescapeSuffix?"":r.unescapePrefix||"-",this.unescapeSuffix=this.unescapePrefix?"":r.unescapeSuffix||"",this.nestingPrefix=r.nestingPrefix?df(r.nestingPrefix):r.nestingPrefixEscaped||df("$t("),this.nestingSuffix=r.nestingSuffix?df(r.nestingSuffix):r.nestingSuffixEscaped||df(")"),this.nestingOptionsSeparator=r.nestingOptionsSeparator?r.nestingOptionsSeparator:r.nestingOptionsSeparator||",",this.maxReplaces=r.maxReplaces?r.maxReplaces:1e3,this.alwaysFormat=r.alwaysFormat!==void 0?r.alwaysFormat:!1,this.resetRegExp()}},{key:"reset",value:function(){this.options&&this.init(this.options)}},{key:"resetRegExp",value:function(){var n="".concat(this.prefix,"(.+?)").concat(this.suffix);this.regexp=new RegExp(n,"g");var r="".concat(this.prefix).concat(this.unescapePrefix,"(.+?)").concat(this.unescapeSuffix).concat(this.suffix);this.regexpUnescape=new RegExp(r,"g");var i="".concat(this.nestingPrefix,"(.+?)").concat(this.nestingSuffix);this.nestingRegexp=new RegExp(i,"g")}},{key:"interpolate",value:function(n,r,i,o){var s=this,l,c,d,v=this.options&&this.options.interpolation&&this.options.interpolation.defaultVariables||{};function p(L){return L.replace(/\$/g,"$$$$")}var S=function(I){if(I.indexOf(s.formatSeparator)<0){var U=l0(r,v,I,s.options.keySeparator,s.options.ignoreJSONStructure);return s.alwaysFormat?s.format(U,void 0,i,es(es(es({},o),r),{},{interpolationkey:I})):U}var z=I.split(s.formatSeparator),re=z.shift().trim(),Z=z.join(s.formatSeparator).trim();return s.format(l0(r,v,re,s.options.keySeparator,s.options.ignoreJSONStructure),Z,i,es(es(es({},o),r),{},{interpolationkey:re}))};this.resetRegExp();var T=o&&o.missingInterpolationHandler||this.options.missingInterpolationHandler,_=o&&o.interpolation&&o.interpolation.skipOnVariables!==void 0?o.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables,R=[{regex:this.regexpUnescape,safeValue:function(I){return p(I)}},{regex:this.regexp,safeValue:function(I){return s.escapeValue?p(s.escape(I)):p(I)}}];return R.forEach(function(L){for(d=0;l=L.regex.exec(n);){var I=l[1].trim();if(c=S(I),c===void 0)if(typeof T=="function"){var U=T(n,l,o);c=typeof U=="string"?U:""}else if(o&&Object.prototype.hasOwnProperty.call(o,I))c="";else if(_){c=l[0];continue}else s.logger.warn("missed to pass in variable ".concat(I," for interpolating ").concat(n)),c="";else typeof c!="string"&&!s.useRawValueToEscape&&(c=e0(c));var z=L.safeValue(c);if(n=n.replace(l[0],z),_?(L.regex.lastIndex+=c.length,L.regex.lastIndex-=l[0].length):L.regex.lastIndex=0,d++,d>=s.maxReplaces)break}}),n}},{key:"nest",value:function(n,r){var i=this,o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},s,l,c;function d(T,_){var R=this.nestingOptionsSeparator;if(T.indexOf(R)<0)return T;var L=T.split(new RegExp("".concat(R,"[ ]*{"))),I="{".concat(L[1]);T=L[0],I=this.interpolate(I,c);var U=I.match(/'/g),z=I.match(/"/g);(U&&U.length%2===0&&!z||z.length%2!==0)&&(I=I.replace(/'/g,'"'));try{c=JSON.parse(I),_&&(c=es(es({},_),c))}catch(re){return this.logger.warn("failed parsing options string in nesting for key ".concat(T),re),"".concat(T).concat(R).concat(I)}return delete c.defaultValue,T}for(;s=this.nestingRegexp.exec(n);){var v=[];c=es({},o),c=c.replace&&typeof c.replace!="string"?c.replace:c,c.applyPostProcessor=!1,delete c.defaultValue;var p=!1;if(s[0].indexOf(this.formatSeparator)!==-1&&!/{.*}/.test(s[1])){var S=s[1].split(this.formatSeparator).map(function(T){return T.trim()});s[1]=S.shift(),v=S,p=!0}if(l=r(d.call(this,s[1].trim(),c),c),l&&s[0]===n&&typeof l!="string")return l;typeof l!="string"&&(l=e0(l)),l||(this.logger.warn("missed to resolve ".concat(s[1]," for nesting ").concat(n)),l=""),p&&(l=v.reduce(function(T,_){return i.format(T,_,o.lng,es(es({},o),{},{interpolationkey:s[1].trim()}))},l.trim())),n=n.replace(s[0],l),this.regexp.lastIndex=0}return n}}]),e}();function c0(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Su(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?c0(Object(n),!0).forEach(function(r){$s(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):c0(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function nA(e){var t=e.toLowerCase().trim(),n={};if(e.indexOf("(")>-1){var r=e.split("(");t=r[0].toLowerCase().trim();var i=r[1].substring(0,r[1].length-1);if(t==="currency"&&i.indexOf(":")<0)n.currency||(n.currency=i.trim());else if(t==="relativetime"&&i.indexOf(":")<0)n.range||(n.range=i.trim());else{var o=i.split(";");o.forEach(function(s){if(s){var l=s.split(":"),c=LI(l),d=c[0],v=c.slice(1),p=v.join(":").trim().replace(/^'+|'+$/g,"");n[d.trim()]||(n[d.trim()]=p),p==="false"&&(n[d.trim()]=!1),p==="true"&&(n[d.trim()]=!0),isNaN(p)||(n[d.trim()]=parseInt(p,10))}})}}return{formatName:t,formatOptions:n}}function hf(e){var t={};return function(r,i,o){var s=i+JSON.stringify(o),l=t[s];return l||(l=e(i,o),t[s]=l),l(r)}}var rA=function(){function e(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};ta(this,e),this.logger=Ms.create("formatter"),this.options=t,this.formats={number:hf(function(n,r){var i=new Intl.NumberFormat(n,Su({},r));return function(o){return i.format(o)}}),currency:hf(function(n,r){var i=new Intl.NumberFormat(n,Su(Su({},r),{},{style:"currency"}));return function(o){return i.format(o)}}),datetime:hf(function(n,r){var i=new Intl.DateTimeFormat(n,Su({},r));return function(o){return i.format(o)}}),relativetime:hf(function(n,r){var i=new Intl.RelativeTimeFormat(n,Su({},r));return function(o){return i.format(o,r.range||"day")}}),list:hf(function(n,r){var i=new Intl.ListFormat(n,Su({},r));return function(o){return i.format(o)}})},this.init(t)}return na(e,[{key:"init",value:function(n){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{interpolation:{}},i=r.interpolation;this.formatSeparator=i.formatSeparator?i.formatSeparator:i.formatSeparator||","}},{key:"add",value:function(n,r){this.formats[n.toLowerCase().trim()]=r}},{key:"addCached",value:function(n,r){this.formats[n.toLowerCase().trim()]=hf(r)}},{key:"format",value:function(n,r,i){var o=this,s=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},l=r.split(this.formatSeparator),c=l.reduce(function(d,v){var p=nA(v),S=p.formatName,T=p.formatOptions;if(o.formats[S]){var _=d;try{var R=s&&s.formatParams&&s.formatParams[s.interpolationkey]||{},L=R.locale||R.lng||s.locale||s.lng||i;_=o.formats[S](d,L,Su(Su(Su({},T),s),R))}catch(I){o.logger.warn(I)}return _}else o.logger.warn("there was no format function for ".concat(S));return d},n);return c}}]),e}();function f0(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function d0(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?f0(Object(n),!0).forEach(function(r){$s(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):f0(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function iA(e){var t=oA();return function(){var r=Bs(e),i;if(t){var o=Bs(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return Bd(this,i)}}function oA(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function aA(e,t){e.pending[t]!==void 0&&(delete e.pending[t],e.pendingCount--)}var sA=function(e){kp(n,e);var t=iA(n);function n(r,i,o){var s,l=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};return ta(this,n),s=t.call(this),Op&&Ol.call(Ou(s)),s.backend=r,s.store=i,s.services=o,s.languageUtils=o.languageUtils,s.options=l,s.logger=Ms.create("backendConnector"),s.waitingReads=[],s.maxParallelReads=l.maxParallelReads||10,s.readingCalls=0,s.maxRetries=l.maxRetries>=0?l.maxRetries:5,s.retryTimeout=l.retryTimeout>=1?l.retryTimeout:350,s.state={},s.queue=[],s.backend&&s.backend.init&&s.backend.init(o,l.backend,l),s}return na(n,[{key:"queueLoad",value:function(i,o,s,l){var c=this,d={},v={},p={},S={};return i.forEach(function(T){var _=!0;o.forEach(function(R){var L="".concat(T,"|").concat(R);!s.reload&&c.store.hasResourceBundle(T,R)?c.state[L]=2:c.state[L]<0||(c.state[L]===1?v[L]===void 0&&(v[L]=!0):(c.state[L]=1,_=!1,v[L]===void 0&&(v[L]=!0),d[L]===void 0&&(d[L]=!0),S[R]===void 0&&(S[R]=!0)))}),_||(p[T]=!0)}),(Object.keys(d).length||Object.keys(v).length)&&this.queue.push({pending:v,pendingCount:Object.keys(v).length,loaded:{},errors:[],callback:l}),{toLoad:Object.keys(d),pending:Object.keys(v),toLoadLanguages:Object.keys(p),toLoadNamespaces:Object.keys(S)}}},{key:"loaded",value:function(i,o,s){var l=i.split("|"),c=l[0],d=l[1];o&&this.emit("failedLoading",c,d,o),s&&this.store.addResourceBundle(c,d,s),this.state[i]=o?-1:2;var v={};this.queue.forEach(function(p){BI(p.loaded,[c],d),aA(p,i),o&&p.errors.push(o),p.pendingCount===0&&!p.done&&(Object.keys(p.loaded).forEach(function(S){v[S]||(v[S]={});var T=p.loaded[S];T.length&&T.forEach(function(_){v[S][_]===void 0&&(v[S][_]=!0)})}),p.done=!0,p.errors.length?p.callback(p.errors):p.callback())}),this.emit("loaded",v),this.queue=this.queue.filter(function(p){return!p.done})}},{key:"read",value:function(i,o,s){var l=this,c=arguments.length>3&&arguments[3]!==void 0?arguments[3]:0,d=arguments.length>4&&arguments[4]!==void 0?arguments[4]:this.retryTimeout,v=arguments.length>5?arguments[5]:void 0;if(!i.length)return v(null,{});if(this.readingCalls>=this.maxParallelReads){this.waitingReads.push({lng:i,ns:o,fcName:s,tried:c,wait:d,callback:v});return}this.readingCalls++;var p=function(R,L){if(l.readingCalls--,l.waitingReads.length>0){var I=l.waitingReads.shift();l.read(I.lng,I.ns,I.fcName,I.tried,I.wait,I.callback)}if(R&&L&&c<l.maxRetries){setTimeout(function(){l.read.call(l,i,o,s,c+1,d*2,v)},d);return}v(R,L)},S=this.backend[s].bind(this.backend);if(S.length===2){try{var T=S(i,o);T&&typeof T.then=="function"?T.then(function(_){return p(null,_)}).catch(p):p(null,T)}catch(_){p(_)}return}return S(i,o,p)}},{key:"prepareLoading",value:function(i,o){var s=this,l=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},c=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."),c&&c();typeof i=="string"&&(i=this.languageUtils.toResolveHierarchy(i)),typeof o=="string"&&(o=[o]);var d=this.queueLoad(i,o,l,c);if(!d.toLoad.length)return d.pending.length||c(),null;d.toLoad.forEach(function(v){s.loadOne(v)})}},{key:"load",value:function(i,o,s){this.prepareLoading(i,o,{},s)}},{key:"reload",value:function(i,o,s){this.prepareLoading(i,o,{reload:!0},s)}},{key:"loadOne",value:function(i){var o=this,s=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",l=i.split("|"),c=l[0],d=l[1];this.read(c,d,"read",void 0,void 0,function(v,p){v&&o.logger.warn("".concat(s,"loading namespace ").concat(d," for language ").concat(c," failed"),v),!v&&p&&o.logger.log("".concat(s,"loaded namespace ").concat(d," for language ").concat(c),p),o.loaded(i,v,p)})}},{key:"saveMissing",value:function(i,o,s,l,c){var d=arguments.length>5&&arguments[5]!==void 0?arguments[5]:{},v=arguments.length>6&&arguments[6]!==void 0?arguments[6]:function(){};if(this.services.utils&&this.services.utils.hasLoadedNamespace&&!this.services.utils.hasLoadedNamespace(o)){this.logger.warn('did not save key "'.concat(s,'" as the namespace "').concat(o,'" 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(!(s==null||s==="")){if(this.backend&&this.backend.create){var p=d0(d0({},d),{},{isUpdate:c}),S=this.backend.create.bind(this.backend);if(S.length<6)try{var T;S.length===5?T=S(i,o,s,l,p):T=S(i,o,s,l),T&&typeof T.then=="function"?T.then(function(_){return v(null,_)}).catch(v):v(null,T)}catch(_){v(_)}else S(i,o,s,l,v,p)}!i||!i[0]||this.store.addResource(i[0],o,s,l)}}}]),n}(Ol);function h0(){return{debug:!1,initImmediate:!0,ns:["translation"],defaultNS:["translation"],fallbackLng:["dev"],fallbackNS:!1,supportedLngs:!1,nonExplicitSupportedLngs:!1,load:"all",preload:!1,simplifyPluralSuffix:!0,keySeparator:".",nsSeparator:":",pluralSeparator:"_",contextSeparator:"_",partialBundledLanguages:!1,saveMissing:!1,updateMissing:!1,saveMissingTo:"fallback",saveMissingPlurals:!0,missingKeyHandler:!1,missingInterpolationHandler:!1,postProcess:!1,postProcessPassResolved:!1,returnNull:!0,returnEmptyString:!0,returnObjects:!1,joinArrays:!1,returnedObjectHandler:!1,parseMissingKeyHandler:!1,appendNamespaceToMissingKey:!1,appendNamespaceToCIMode:!1,overloadTranslationOptionHandler:function(t){var n={};if(Jo(t[1])==="object"&&(n=t[1]),typeof t[1]=="string"&&(n.defaultValue=t[1]),typeof t[2]=="string"&&(n.tDescription=t[2]),Jo(t[2])==="object"||Jo(t[3])==="object"){var r=t[3]||t[2];Object.keys(r).forEach(function(i){n[i]=r[i]})}return n},interpolation:{escapeValue:!0,format:function(t,n,r,i){return t},prefix:"{{",suffix:"}}",formatSeparator:",",unescapePrefix:"-",nestingPrefix:"$t(",nestingSuffix:")",nestingOptionsSeparator:",",maxReplaces:1e3,skipOnVariables:!0}}}function p0(e){return typeof e.ns=="string"&&(e.ns=[e.ns]),typeof e.fallbackLng=="string"&&(e.fallbackLng=[e.fallbackLng]),typeof e.fallbackNS=="string"&&(e.fallbackNS=[e.fallbackNS]),e.supportedLngs&&e.supportedLngs.indexOf("cimode")<0&&(e.supportedLngs=e.supportedLngs.concat(["cimode"])),e}function g0(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Ps(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?g0(Object(n),!0).forEach(function(r){$s(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):g0(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function uA(e){var t=lA();return function(){var r=Bs(e),i;if(t){var o=Bs(this).constructor;i=Reflect.construct(r,arguments,o)}else i=r.apply(this,arguments);return Bd(this,i)}}function lA(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function lh(){}function cA(e){var t=Object.getOwnPropertyNames(Object.getPrototypeOf(e));t.forEach(function(n){typeof e[n]=="function"&&(e[n]=e[n].bind(e))})}var Jh=function(e){kp(n,e);var t=uA(n);function n(){var r,i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},o=arguments.length>1?arguments[1]:void 0;if(ta(this,n),r=t.call(this),Op&&Ol.call(Ou(r)),r.options=p0(i),r.services={},r.logger=Ms,r.modules={external:[]},cA(Ou(r)),o&&!r.isInitialized&&!i.isClone){if(!r.options.initImmediate)return r.init(i,o),Bd(r,Ou(r));setTimeout(function(){r.init(i,o)},0)}return r}return na(n,[{key:"init",value:function(){var i=this,o=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},s=arguments.length>1?arguments[1]:void 0;typeof o=="function"&&(s=o,o={}),!o.defaultNS&&o.defaultNS!==!1&&o.ns&&(typeof o.ns=="string"?o.defaultNS=o.ns:o.ns.indexOf("translation")<0&&(o.defaultNS=o.ns[0]));var l=h0();this.options=Ps(Ps(Ps({},l),this.options),p0(o)),this.options.compatibilityAPI!=="v1"&&(this.options.interpolation=Ps(Ps({},l.interpolation),this.options.interpolation)),o.keySeparator!==void 0&&(this.options.userDefinedKeySeparator=o.keySeparator),o.nsSeparator!==void 0&&(this.options.userDefinedNsSeparator=o.nsSeparator);function c(I){return I?typeof I=="function"?new I:I:null}if(!this.options.isClone){this.modules.logger?Ms.init(c(this.modules.logger),this.options):Ms.init(null,this.options);var d;this.modules.formatter?d=this.modules.formatter:typeof Intl<"u"&&(d=rA);var v=new a0(this.options);this.store=new GI(this.options.resources,this.options);var p=this.services;p.logger=Ms,p.resourceStore=this.store,p.languageUtils=v,p.pluralResolver=new eA(v,{prepend:this.options.pluralSeparator,compatibilityJSON:this.options.compatibilityJSON,simplifyPluralSuffix:this.options.simplifyPluralSuffix}),d&&(!this.options.interpolation.format||this.options.interpolation.format===l.interpolation.format)&&(p.formatter=c(d),p.formatter.init(p,this.options),this.options.interpolation.format=p.formatter.format.bind(p.formatter)),p.interpolator=new tA(this.options),p.utils={hasLoadedNamespace:this.hasLoadedNamespace.bind(this)},p.backendConnector=new sA(c(this.modules.backend),p.resourceStore,p,this.options),p.backendConnector.on("*",function(I){for(var U=arguments.length,z=new Array(U>1?U-1:0),re=1;re<U;re++)z[re-1]=arguments[re];i.emit.apply(i,[I].concat(z))}),this.modules.languageDetector&&(p.languageDetector=c(this.modules.languageDetector),p.languageDetector.init&&p.languageDetector.init(p,this.options.detection,this.options)),this.modules.i18nFormat&&(p.i18nFormat=c(this.modules.i18nFormat),p.i18nFormat.init&&p.i18nFormat.init(this)),this.translator=new o0(this.services,this.options),this.translator.on("*",function(I){for(var U=arguments.length,z=new Array(U>1?U-1:0),re=1;re<U;re++)z[re-1]=arguments[re];i.emit.apply(i,[I].concat(z))}),this.modules.external.forEach(function(I){I.init&&I.init(i)})}if(this.format=this.options.interpolation.format,s||(s=lh),this.options.fallbackLng&&!this.services.languageDetector&&!this.options.lng){var S=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);S.length>0&&S[0]!=="dev"&&(this.options.lng=S[0])}!this.services.languageDetector&&!this.options.lng&&this.logger.warn("init: no languageDetector is used and no lng is defined");var T=["getResource","hasResourceBundle","getResourceBundle","getDataByLanguage"];T.forEach(function(I){i[I]=function(){var U;return(U=i.store)[I].apply(U,arguments)}});var _=["addResource","addResources","addResourceBundle","removeResourceBundle"];_.forEach(function(I){i[I]=function(){var U;return(U=i.store)[I].apply(U,arguments),i}});var R=Kf(),L=function(){var U=function(re,Z){i.isInitialized&&!i.initializedStoreOnce&&i.logger.warn("init: i18next is already initialized. You should call init just once!"),i.isInitialized=!0,i.options.isClone||i.logger.log("initialized",i.options),i.emit("initialized",i.options),R.resolve(Z),s(re,Z)};if(i.languages&&i.options.compatibilityAPI!=="v1"&&!i.isInitialized)return U(null,i.t.bind(i));i.changeLanguage(i.options.lng,U)};return this.options.resources||!this.options.initImmediate?L():setTimeout(L,0),R}},{key:"loadResources",value:function(i){var o=this,s=arguments.length>1&&arguments[1]!==void 0?arguments[1]:lh,l=s,c=typeof i=="string"?i:this.language;if(typeof i=="function"&&(l=i),!this.options.resources||this.options.partialBundledLanguages){if(c&&c.toLowerCase()==="cimode")return l();var d=[],v=function(T){if(T){var _=o.services.languageUtils.toResolveHierarchy(T);_.forEach(function(R){d.indexOf(R)<0&&d.push(R)})}};if(c)v(c);else{var p=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);p.forEach(function(S){return v(S)})}this.options.preload&&this.options.preload.forEach(function(S){return v(S)}),this.services.backendConnector.load(d,this.options.ns,function(S){!S&&!o.resolvedLanguage&&o.language&&o.setResolvedLanguage(o.language),l(S)})}else l(null)}},{key:"reloadResources",value:function(i,o,s){var l=Kf();return i||(i=this.languages),o||(o=this.options.ns),s||(s=lh),this.services.backendConnector.reload(i,o,function(c){l.resolve(),s(c)}),l}},{key:"use",value:function(i){if(!i)throw new Error("You are passing an undefined module! Please check the object you are passing to i18next.use()");if(!i.type)throw new Error("You are passing a wrong module! Please check the object you are passing to i18next.use()");return i.type==="backend"&&(this.modules.backend=i),(i.type==="logger"||i.log&&i.warn&&i.error)&&(this.modules.logger=i),i.type==="languageDetector"&&(this.modules.languageDetector=i),i.type==="i18nFormat"&&(this.modules.i18nFormat=i),i.type==="postProcessor"&&P1.addPostProcessor(i),i.type==="formatter"&&(this.modules.formatter=i),i.type==="3rdParty"&&this.modules.external.push(i),this}},{key:"setResolvedLanguage",value:function(i){if(!(!i||!this.languages)&&!(["cimode","dev"].indexOf(i)>-1))for(var o=0;o<this.languages.length;o++){var s=this.languages[o];if(!(["cimode","dev"].indexOf(s)>-1)&&this.store.hasLanguageSomeTranslations(s)){this.resolvedLanguage=s;break}}}},{key:"changeLanguage",value:function(i,o){var s=this;this.isLanguageChangingTo=i;var l=Kf();this.emit("languageChanging",i);var c=function(S){s.language=S,s.languages=s.services.languageUtils.toResolveHierarchy(S),s.resolvedLanguage=void 0,s.setResolvedLanguage(S)},d=function(S,T){T?(c(T),s.translator.changeLanguage(T),s.isLanguageChangingTo=void 0,s.emit("languageChanged",T),s.logger.log("languageChanged",T)):s.isLanguageChangingTo=void 0,l.resolve(function(){return s.t.apply(s,arguments)}),o&&o(S,function(){return s.t.apply(s,arguments)})},v=function(S){!i&&!S&&s.services.languageDetector&&(S=[]);var T=typeof S=="string"?S:s.services.languageUtils.getBestMatchFromCodes(S);T&&(s.language||c(T),s.translator.language||s.translator.changeLanguage(T),s.services.languageDetector&&s.services.languageDetector.cacheUserLanguage&&s.services.languageDetector.cacheUserLanguage(T)),s.loadResources(T,function(_){d(_,T)})};return!i&&this.services.languageDetector&&!this.services.languageDetector.async?v(this.services.languageDetector.detect()):!i&&this.services.languageDetector&&this.services.languageDetector.async?this.services.languageDetector.detect.length===0?this.services.languageDetector.detect().then(v):this.services.languageDetector.detect(v):v(i),l}},{key:"getFixedT",value:function(i,o,s){var l=this,c=function d(v,p){var S;if(Jo(p)!=="object"){for(var T=arguments.length,_=new Array(T>2?T-2:0),R=2;R<T;R++)_[R-2]=arguments[R];S=l.options.overloadTranslationOptionHandler([v,p].concat(_))}else S=Ps({},p);S.lng=S.lng||d.lng,S.lngs=S.lngs||d.lngs,S.ns=S.ns||d.ns,S.keyPrefix=S.keyPrefix||s||d.keyPrefix;var L=l.options.keySeparator||".",I;return S.keyPrefix&&Array.isArray(v)?I=v.map(function(U){return"".concat(S.keyPrefix).concat(L).concat(U)}):I=S.keyPrefix?"".concat(S.keyPrefix).concat(L).concat(v):v,l.t(I,S)};return typeof i=="string"?c.lng=i:c.lngs=i,c.ns=o,c.keyPrefix=s,c}},{key:"t",value:function(){var i;return this.translator&&(i=this.translator).translate.apply(i,arguments)}},{key:"exists",value:function(){var i;return this.translator&&(i=this.translator).exists.apply(i,arguments)}},{key:"setDefaultNamespace",value:function(i){this.options.defaultNS=i}},{key:"hasLoadedNamespace",value:function(i){var o=this,s=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(!this.isInitialized)return this.logger.warn("hasLoadedNamespace: i18next was not initialized",this.languages),!1;if(!this.languages||!this.languages.length)return this.logger.warn("hasLoadedNamespace: i18n.languages were undefined or empty",this.languages),!1;var l=s.lng||this.resolvedLanguage||this.languages[0],c=this.options?this.options.fallbackLng:!1,d=this.languages[this.languages.length-1];if(l.toLowerCase()==="cimode")return!0;var v=function(T,_){var R=o.services.backendConnector.state["".concat(T,"|").concat(_)];return R===-1||R===2};if(s.precheck){var p=s.precheck(this,v);if(p!==void 0)return p}return!!(this.hasResourceBundle(l,i)||!this.services.backendConnector.backend||this.options.resources&&!this.options.partialBundledLanguages||v(l,i)&&(!c||v(d,i)))}},{key:"loadNamespaces",value:function(i,o){var s=this,l=Kf();return this.options.ns?(typeof i=="string"&&(i=[i]),i.forEach(function(c){s.options.ns.indexOf(c)<0&&s.options.ns.push(c)}),this.loadResources(function(c){l.resolve(),o&&o(c)}),l):(o&&o(),Promise.resolve())}},{key:"loadLanguages",value:function(i,o){var s=Kf();typeof i=="string"&&(i=[i]);var l=this.options.preload||[],c=i.filter(function(d){return l.indexOf(d)<0});return c.length?(this.options.preload=l.concat(c),this.loadResources(function(d){s.resolve(),o&&o(d)}),s):(o&&o(),Promise.resolve())}},{key:"dir",value:function(i){if(i||(i=this.resolvedLanguage||(this.languages&&this.languages.length>0?this.languages[0]:this.language)),!i)return"rtl";var o=["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"],s=this.services&&this.services.languageUtils||new a0(h0());return o.indexOf(s.getLanguagePartFromCode(i))>-1||i.toLowerCase().indexOf("-arab")>1?"rtl":"ltr"}},{key:"cloneInstance",value:function(){var i=this,o=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},s=arguments.length>1&&arguments[1]!==void 0?arguments[1]:lh,l=Ps(Ps(Ps({},this.options),o),{isClone:!0}),c=new n(l);(o.debug!==void 0||o.prefix!==void 0)&&(c.logger=c.logger.clone(o));var d=["store","services","language"];return d.forEach(function(v){c[v]=i[v]}),c.services=Ps({},this.services),c.services.utils={hasLoadedNamespace:c.hasLoadedNamespace.bind(c)},c.translator=new o0(c.services,c.options),c.translator.on("*",function(v){for(var p=arguments.length,S=new Array(p>1?p-1:0),T=1;T<p;T++)S[T-1]=arguments[T];c.emit.apply(c,[v].concat(S))}),c.init(l,s),c.translator.options=c.options,c.translator.backendConnector.services.utils={hasLoadedNamespace:c.hasLoadedNamespace.bind(c)},c}},{key:"toJSON",value:function(){return{options:this.options,store:this.store,language:this.language,languages:this.languages,resolvedLanguage:this.resolvedLanguage}}}]),n}(Ol);$s(Jh,"createInstance",function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;return new Jh(e,t)});var li=Jh.createInstance();li.createInstance=Jh.createInstance;li.createInstance;li.dir;li.init;li.loadResources;li.reloadResources;li.use;li.changeLanguage;li.getFixedT;var _1=li.t;li.exists;li.setDefaultNamespace;li.hasLoadedNamespace;li.loadNamespaces;li.loadLanguages;const R1={TOKEN_MALFORMED:"token_malformed",TOKEN_EXPIRED:"token_expired"},I1=e=>{window.location.href=`${e}/authentication/login?callbackUrl=${window.location.href}`},A1=e=>{window.location.href=`${e}/authentication/logout?callbackUrl=${window.location.href}`},Ls=DI.create({withCredentials:!0});let Ig=!1,Nv=[];const v0=e=>{Nv.forEach(t=>{e?t.reject(e):t.resolve()}),Nv=[]};function M1(e,t){var o,s,l,c,d,v,p;const n=e.config,r=(s=(o=e.response)==null?void 0:o.data)==null?void 0:s.errorMessage,i=r===R1.TOKEN_EXPIRED;return((l=e.response)==null?void 0:l.status)===401&&i&&!n._retry?Ig?new Promise((S,T)=>{Nv.push({resolve:S,reject:T})}).then(()=>Ls(n)).catch(S=>Promise.reject(S)):(n._retry=!0,Ig=!0,Ls.post("/authentication/api/v1/auth/refresh-token",void 0,{baseURL:window.env.AUTHEN_DOMAIN}).then(()=>(v0(null),Ls(n))).catch(S=>(v0(S),Promise.reject(S))).finally(()=>{Ig=!1})):((c=e.response)==null?void 0:c.status)===401&&!i?I1(window.env.AUTHEN_DOMAIN):(((d=e.response)==null?void 0:d.status)===403?(v=t==null?void 0:t.handle403)==null||v.call(t,e):(!(t!=null&&t.disabledPushNotify)&&Rp(_1(`${r||"Something went wrong!"}`)),(p=t==null?void 0:t.handleOtherError)==null||p.call(t,e)),r&&e.response&&e.response.data&&(e.response.data.message=r),Promise.reject(e))}const fA=Ls.interceptors.response.use(e=>e,async e=>M1(e)),L1=Q.createContext({}),dA=({children:e})=>{const[t,n]=Q.useState(!0),[r,i]=Q.useState({all:{rows:[],total:0},unread:{rows:[],total:0}}),o=()=>{n(!t)},s=()=>{n(!0)};return st.jsx(L1.Provider,{value:{isOpen:t,toggleOpen:o,setShowModalFalse:s,notidata:r,setNotiData:i},children:e})};var N1={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},m0=Q.createContext&&Q.createContext(N1),hA=["attr","size","title"];function pA(e,t){if(e==null)return{};var n=gA(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function gA(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o<r.length;o++)i=r[o],!(t.indexOf(i)>=0)&&(n[i]=e[i]);return n}function Qh(){return Qh=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Qh.apply(this,arguments)}function y0(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function ep(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?y0(Object(n),!0).forEach(function(r){vA(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):y0(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function vA(e,t,n){return t=mA(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function mA(e){var t=yA(e,"string");return typeof t=="symbol"?t:String(t)}function yA(e,t){if(typeof e!="object"||e===null)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function F1(e){return e&&e.map((t,n)=>Q.createElement(t.tag,ep({key:n},t.attr),F1(t.child)))}function Dp(e){return t=>Q.createElement(bA,Qh({attr:ep({},e.attr)},t),F1(e.child))}function bA(e){var t=n=>{var{attr:r,size:i,title:o}=e,s=pA(e,hA),l=i||n.size||"1em",c;return n.className&&(c=n.className),e.className&&(c=(c?c+" ":"")+e.className),Q.createElement("svg",Qh({stroke:"currentColor",fill:"currentColor",strokeWidth:"0"},n.attr,r,s,{className:c,style:ep(ep({color:e.color||n.color},n.style),e.style),height:l,width:l,xmlns:"http://www.w3.org/2000/svg"}),o&&Q.createElement("title",null,o),e.children)};return m0!==void 0?Q.createElement(m0.Consumer,null,n=>t(n)):t(N1)}function wA(e){return Dp({tag:"svg",attr:{viewBox:"0 0 1024 1024"},child:[{tag:"path",attr:{d:"M689 165.1L308.2 493.5c-10.9 9.4-10.9 27.5 0 37L689 858.9c14.2 12.2 35 1.2 35-18.5V183.6c0-19.7-20.8-30.7-35-18.5z"},child:[]}]})(e)}function xA(e){return Dp({tag:"svg",attr:{viewBox:"0 0 1024 1024"},child:[{tag:"path",attr:{d:"M715.8 493.5L335 165.1c-14.2-12.2-35-1.2-35 18.5v656.8c0 19.7 20.8 30.7 35 18.5l380.8-328.4c10.9-9.4 10.9-27.6 0-37z"},child:[]}]})(e)}const j1=e=>{const t={...e.colors};return _c.createTheme({palette:{primary:{main:t.primary300,contrastText:t.textPrimary},secondary:{main:t.secondary,contrastText:t.textPrimary},warning:{main:t.warning,contrastText:t.textPrimary},error:{main:t.danger,contrastText:t.textPrimary}},typography:{fontFamily:"TT Firs Neue Trl",button:{textTransform:"none",fontSize:"0.875rem",fontWeight:400,boxShadow:"none"},body1:{fontSize:"0.875rem",fontWeight:400},body2:{fontSize:"0.75rem"},h6:{fontSize:"0.875rem",fontWeight:500},h5:{fontSize:"1rem",fontWeight:500},h4:{fontSize:"1.25rem",fontWeight:500},h3:{fontSize:"1.5rem",fontWeight:500},h2:{fontSize:"2rem",fontWeight:500},h1:{fontSize:"2.5rem",fontWeight:500},subtitle1:{fontSize:"0.75rem"},subtitle2:{fontSize:"0.625rem"}},components:{MuiIconButton:{styleOverrides:{root:{},sizeSmall:{}}},MuiButton:{styleOverrides:{root:{boxShadow:"none !important",padding:"8px 32px",borderWidth:1,borderRadius:3,fontWeight:400}},variants:[{props:{variant:"primary"},style:{backgroundColor:t.primary300,color:t.buttonText,"&:hover":{backgroundColor:t.buttonHover||t.primary300},"&.Mui-disabled":{backgroundColor:t.grey200}}},{props:{variant:"contained",color:"error"},style:{color:t.white}},{props:{variant:"confirm"},style:{backgroundColor:t.danger,color:t.white,"&:hover":{backgroundColor:t.dangerDark},"&.Mui-disabled":{backgroundColor:t.grey200}}},{props:{variant:"cancel"},style:{backgroundColor:t.grey300,color:t.textPrimary,"&:hover":{backgroundColor:t.grey400}}},{props:{variant:"outlinedPrimary"},style:{color:t.primary500,border:"1px solid",borderColor:t.primary500,"&:hover":{backgroundColor:"inherit"}}},{props:{variant:"outLinedDanger"},style:{color:t.danger,border:"1px solid",borderColor:t.danger,"&:hover":{backgroundColor:"inherit"}}},{props:{size:"small"},style:{fontSize:"12px",lineHeight:"normal",borderRadius:"3px",padding:"4px 16px"}}]},MuiAppBar:{styleOverrides:{root:{backgroundColor:t.appBarBgColor,color:t.appBarColor}}},MuiSelect:{defaultProps:{MenuProps:{PaperProps:{sx:{boxShadow:"none",border:1,borderStyle:"solid",borderColor:t.grey300,mt:"5px"}},MenuListProps:{sx:{padding:"5px","& .MuiMenuItem-root":{fontWeight:400,minHeight:0,borderRadius:"5px","&:hover":{backgroundColor:t.grey100},"&.Mui-selected":{backgroundColor:t.primary200}}}}}},styleOverrides:{select:{padding:"9.94px 5px 9.94px 15px"}}},MuiMenuItem:{styleOverrides:{root:{"&.Mui-selected":{backgroundColor:`${t.primary200} !important`,"&:hover":{backgroundColor:`${t.primary200} !important`}}}}},MuiPaginationItem:{defaultProps:{components:{previous:wA,next:xA}},styleOverrides:{root:{"& svg":{width:"10px"},border:"none",fontSize:"14px",lineHeight:"1.5rem",borderRadius:"7px","&.Mui-selected":{backgroundColor:`${t.primary300}1a !important`},"&.MuiPaginationItem-previousNext":{backgroundColor:t.grey200}}}},MuiChip:{styleOverrides:{root:{borderRadius:"5px",fontSize:"10px",lineHeight:"12px",fontWeight:400,"& .MuiChip-label":{lineHeight:"normal"}},avatar:{width:"10px"},colorSuccess:{color:t.success,backgroundColor:t.successLight},colorWarning:{color:t.warning,backgroundColor:t.warningLight},colorError:{color:t.danger,backgroundColor:t.dangerLight},colorSecondary:{color:t.linkPrimary,backgroundColor:t.linkLight}}},MuiTab:{styleOverrides:{root:{flexDirection:"row",alignContent:"center",gap:"8px",textTransform:"capitalize",fontSize:"14px",borderRadius:0,marginRight:0,height:"48px",minWidth:"100px",padding:"12px 16px",fontWeight:"500","& svg":{mb:"0 !important"},minHeight:"auto","& .chart-icon":{fill:t.grey600},"& .detail-icon":{stroke:t.grey600},color:t.grey400,"&.Mui-selected":{color:t.primary400}}}},MuiTabs:{styleOverrides:{indicator:{backgroundColor:t.primary400}}},MuiDrawer:{defaultProps:{},styleOverrides:{root:{"&.MuiDrawer-paper":{overflowY:"unset"},"& .MuiDrawer-paper":{zIndex:9},"&.MuiPaper-root":{border:"none",background:t.grey100,pt:12,zIndex:9}}}},MuiTextField:{defaultProps:{InputProps:{sx:{"& .Mui-disabled":{background:t.grey200}}},InputLabelProps:{shrink:!0}},styleOverrides:{root:{backgroundColor:t.white,"& .MuiOutlinedInput-input":{padding:"0px 16px 0px 12px",fontWeight:400,height:40,fontSize:"14px",border:1,borderRadius:4,"&::placeholder":{color:t.grey600}},"& .MuiFormLabel-asterisk":{color:t.danger}}}},MuiFormGroup:{styleOverrides:{root:{}}},MuiFormHelperText:{defaultProps:{sx:{fontSize:12}},styleOverrides:{}},MuiAutocomplete:{defaultProps:{sx:{"& .MuiPaper-root":{padding:"5px"}}},styleOverrides:{root:{"& .MuiSvgIcon-root":{width:"20px",height:"20px"},"& .MuiAutocomplete-tag":{margin:0},"& .MuiButtonBase-root":{marginRight:"2px !important",height:"max-content",padding:"2px"},"& .MuiOutlinedInput-root":{padding:"7.45px 55px 7.45px 10px !important"},"& svg":{},"& #checkboxes-tags-demo":{padding:"6px 4px"},"& .MuiAutocomplete-endAdornment":{top:"calc(50% - 12px)"}}}},MuiTableHead:{styleOverrides:{root:{"& th":{fontSize:"14px",padding:"8px 16px"}}}},MuiTableBody:{styleOverrides:{root:{"& th,td":{fontSize:"14px",padding:"8px 16px",height:"45px"},"& .MuiTableCell-root":{borderBottom:`1px solid ${t.grey300}`}}}},MuiRadio:{defaultProps:{sx:{"&.MuiButtonBase-root":{padding:"5px"}}},styleOverrides:{root:{"& .MuiSvgIcon-root":{fontSize:16},color:t.grey600,"&.Mui-checked":{color:t.success},"&.Mui-disabled":{color:t.grey600}}}},MuiTooltip:{defaultProps:{placement:"top"},styleOverrides:{tooltip:{fontSize:"10px",backgroundColor:t.grey600,color:t.white,"& .MuiTooltip-arrow":{color:t.grey600}}}}}})};function SA(e,t){const n={...e};return t==null||t.forEach(r=>{r.children&&r.children.forEach(i=>{n[i.key]=i.color.trim()})}),n}function TA(e){var s,l;const{data:t,isFetching:n}=Sd.useQuery(["customTheme"],()=>e!=null&&e.url?fetch(e.url).then(c=>c.json()):void 0,{enabled:!!(e!=null&&e.url)&&(e==null?void 0:e.enabled),refetchOnWindowFocus:!1,cacheTime:0}),r=SA(so,(s=t==null?void 0:t.theme)==null?void 0:s.keyColor);console.log("🚀 ~ useThemeContext ~ isFetching:",n);const i=j1({colors:r}),o=(l=t==null?void 0:t.theme)==null?void 0:l.image;return{colors:r,theme:i,logo:o,isFetching:n}}const B1=Q.createContext({}),CA=()=>Q.useContext(B1),EA=e=>{var o;const{children:t,brandTheme:n}=e,r=TA(n),i=((o=e.customTheme)==null?void 0:o.call(e,r.colors))||r.theme;return st.jsx(B1.Provider,{value:r,children:st.jsx(_c.ThemeProvider,{theme:i,children:t})})},kA=`*,:before,:after{box-sizing:border-box;border-width:0;border-style:solid;border-color:#e5e7eb}html,:host{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-tap-highlight-color:transparent}body{margin:0;line-height:inherit}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}button,input,optgroup,select,textarea{font-family:inherit;font-feature-settings:inherit;font-variation-settings:inherit;font-size:100%;font-weight:inherit;line-height:inherit;color:inherit;margin:0;padding:0}button,select{text-transform:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dl,dd,h1,h2,h3,h4,h5,h6,hr,figure,p,pre{margin:0}fieldset{margin:0;padding:0}legend{padding:0}ol,ul,menu{list-style:none;margin:0;padding:0}dialog{padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{opacity:1;color:#9ca3af}input::placeholder,textarea::placeholder{opacity:1;color:#9ca3af}button,[role=button]{cursor:pointer}:disabled{cursor:default}img,svg,video,canvas,audio,iframe,embed,object{display:block;vertical-align:middle}img,video{max-width:100%;height:auto}[hidden]{display:none}
|
|
4
4
|
`;function $1({children:e,styles:t=[],...n}){return st.jsxs("div",{...n,children:[[kA,...t].map((r,i)=>st.jsx("style",{type:"text/css",children:r},i)),e]})}var V1=[],OA=V1.forEach,DA=V1.slice;function PA(e){return OA.call(DA.call(arguments,1),function(t){if(t)for(var n in t)e[n]===void 0&&(e[n]=t[n])}),e}var b0=/^[\u0009\u0020-\u007e\u0080-\u00ff]+$/,_A=function(t,n,r){var i=r||{};i.path=i.path||"/";var o=encodeURIComponent(n),s="".concat(t,"=").concat(o);if(i.maxAge>0){var l=i.maxAge-0;if(Number.isNaN(l))throw new Error("maxAge should be a Number");s+="; Max-Age=".concat(Math.floor(l))}if(i.domain){if(!b0.test(i.domain))throw new TypeError("option domain is invalid");s+="; Domain=".concat(i.domain)}if(i.path){if(!b0.test(i.path))throw new TypeError("option path is invalid");s+="; Path=".concat(i.path)}if(i.expires){if(typeof i.expires.toUTCString!="function")throw new TypeError("option expires is invalid");s+="; Expires=".concat(i.expires.toUTCString())}if(i.httpOnly&&(s+="; HttpOnly"),i.secure&&(s+="; Secure"),i.sameSite){var c=typeof i.sameSite=="string"?i.sameSite.toLowerCase():i.sameSite;switch(c){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},w0={create:function(t,n,r,i){var o=arguments.length>4&&arguments[4]!==void 0?arguments[4]:{path:"/",sameSite:"strict"};r&&(o.expires=new Date,o.expires.setTime(o.expires.getTime()+r*60*1e3)),i&&(o.domain=i),document.cookie=_A(t,encodeURIComponent(n),o)},read:function(t){for(var n="".concat(t,"="),r=document.cookie.split(";"),i=0;i<r.length;i++){for(var o=r[i];o.charAt(0)===" ";)o=o.substring(1,o.length);if(o.indexOf(n)===0)return o.substring(n.length,o.length)}return null},remove:function(t){this.create(t,"",-1)}},RA={name:"cookie",lookup:function(t){var n;if(t.lookupCookie&&typeof document<"u"){var r=w0.read(t.lookupCookie);r&&(n=r)}return n},cacheUserLanguage:function(t,n){n.lookupCookie&&typeof document<"u"&&w0.create(n.lookupCookie,t,n.cookieMinutes,n.cookieDomain,n.cookieOptions)}},IA={name:"querystring",lookup:function(t){var n;if(typeof window<"u"){var r=window.location.search;!window.location.search&&window.location.hash&&window.location.hash.indexOf("?")>-1&&(r=window.location.hash.substring(window.location.hash.indexOf("?")));for(var i=r.substring(1),o=i.split("&"),s=0;s<o.length;s++){var l=o[s].indexOf("=");if(l>0){var c=o[s].substring(0,l);c===t.lookupQuerystring&&(n=o[s].substring(l+1))}}}return n}},Zf=null,x0=function(){if(Zf!==null)return Zf;try{Zf=window!=="undefined"&&window.localStorage!==null;var t="i18next.translate.boo";window.localStorage.setItem(t,"foo"),window.localStorage.removeItem(t)}catch{Zf=!1}return Zf},AA={name:"localStorage",lookup:function(t){var n;if(t.lookupLocalStorage&&x0()){var r=window.localStorage.getItem(t.lookupLocalStorage);r&&(n=r)}return n},cacheUserLanguage:function(t,n){n.lookupLocalStorage&&x0()&&window.localStorage.setItem(n.lookupLocalStorage,t)}},Jf=null,S0=function(){if(Jf!==null)return Jf;try{Jf=window!=="undefined"&&window.sessionStorage!==null;var t="i18next.translate.boo";window.sessionStorage.setItem(t,"foo"),window.sessionStorage.removeItem(t)}catch{Jf=!1}return Jf},MA={name:"sessionStorage",lookup:function(t){var n;if(t.lookupSessionStorage&&S0()){var r=window.sessionStorage.getItem(t.lookupSessionStorage);r&&(n=r)}return n},cacheUserLanguage:function(t,n){n.lookupSessionStorage&&S0()&&window.sessionStorage.setItem(n.lookupSessionStorage,t)}},LA={name:"navigator",lookup:function(t){var n=[];if(typeof navigator<"u"){if(navigator.languages)for(var r=0;r<navigator.languages.length;r++)n.push(navigator.languages[r]);navigator.userLanguage&&n.push(navigator.userLanguage),navigator.language&&n.push(navigator.language)}return n.length>0?n:void 0}},NA={name:"htmlTag",lookup:function(t){var n,r=t.htmlTag||(typeof document<"u"?document.documentElement:null);return r&&typeof r.getAttribute=="function"&&(n=r.getAttribute("lang")),n}},FA={name:"path",lookup:function(t){var n;if(typeof window<"u"){var r=window.location.pathname.match(/\/([a-zA-Z-]*)/g);if(r instanceof Array)if(typeof t.lookupFromPathIndex=="number"){if(typeof r[t.lookupFromPathIndex]!="string")return;n=r[t.lookupFromPathIndex].replace("/","")}else n=r[0].replace("/","")}return n}},jA={name:"subdomain",lookup:function(t){var n=typeof t.lookupFromSubdomainIndex=="number"?t.lookupFromSubdomainIndex+1:1,r=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(r)return r[n]}};function BA(){return{order:["querystring","cookie","localStorage","sessionStorage","navigator","htmlTag"],lookupQuerystring:"lng",lookupCookie:"i18next",lookupLocalStorage:"i18nextLng",lookupSessionStorage:"i18nextLng",caches:["localStorage"],excludeCacheFor:["cimode"],convertDetectedLanguage:function(t){return t}}}var H1=function(){function e(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};ta(this,e),this.type="languageDetector",this.detectors={},this.init(t,n)}return na(e,[{key:"init",value:function(n){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};this.services=n||{languageUtils:{}},this.options=PA(r,this.options||{},BA()),typeof this.options.convertDetectedLanguage=="string"&&this.options.convertDetectedLanguage.indexOf("15897")>-1&&(this.options.convertDetectedLanguage=function(o){return o.replace("-","_")}),this.options.lookupFromUrlIndex&&(this.options.lookupFromPathIndex=this.options.lookupFromUrlIndex),this.i18nOptions=i,this.addDetector(RA),this.addDetector(IA),this.addDetector(AA),this.addDetector(MA),this.addDetector(LA),this.addDetector(NA),this.addDetector(FA),this.addDetector(jA)}},{key:"addDetector",value:function(n){this.detectors[n.name]=n}},{key:"detect",value:function(n){var r=this;n||(n=this.options.order);var i=[];return n.forEach(function(o){if(r.detectors[o]){var s=r.detectors[o].lookup(r.options);s&&typeof s=="string"&&(s=[s]),s&&(i=i.concat(s))}}),i=i.map(function(o){return r.options.convertDetectedLanguage(o)}),this.services.languageUtils.getBestMatchFromCodes?i:i.length>0?i[0]:null}},{key:"cacheUserLanguage",value:function(n,r){var i=this;r||(r=this.options.caches),r&&(this.options.excludeCacheFor&&this.options.excludeCacheFor.indexOf(n)>-1||r.forEach(function(o){i.detectors[o]&&i.detectors[o].cacheUserLanguage(n,i.options)}))}}]),e}();H1.type="languageDetector";function Wm(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,o;for(o=0;o<r.length;o++)i=r[o],!(t.indexOf(i)>=0)&&(n[i]=e[i]);return n}const $A=Object.freeze(Object.defineProperty({__proto__:null,default:Wm},Symbol.toStringTag,{value:"Module"}));var Ko=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Bc(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function VA(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var i=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,i.get?i:{enumerable:!0,get:function(){return e[r]}})}),n}function HA(){if(console&&console.warn){for(var e,t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];typeof n[0]=="string"&&(n[0]="react-i18next:: ".concat(n[0])),(e=console).warn.apply(e,n)}}var T0={};function Fv(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];typeof t[0]=="string"&&T0[t[0]]||(typeof t[0]=="string"&&(T0[t[0]]=new Date),HA.apply(void 0,t))}var U1=function(t,n){return function(){if(t.isInitialized)n();else{var r=function i(){setTimeout(function(){t.off("initialized",i)},0),n()};t.on("initialized",r)}}};function C0(e,t,n){e.loadNamespaces(t,U1(e,n))}function E0(e,t,n,r){typeof n=="string"&&(n=[n]),n.forEach(function(i){e.options.ns.indexOf(i)<0&&e.options.ns.push(i)}),e.loadLanguages(t,U1(e,r))}function UA(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},r=t.languages[0],i=t.options?t.options.fallbackLng:!1,o=t.languages[t.languages.length-1];if(r.toLowerCase()==="cimode")return!0;var s=function(c,d){var v=t.services.backendConnector.state["".concat(c,"|").concat(d)];return v===-1||v===2};return n.bindI18n&&n.bindI18n.indexOf("languageChanging")>-1&&t.services.backendConnector.backend&&t.isLanguageChangingTo&&!s(t.isLanguageChangingTo,e)?!1:!!(t.hasResourceBundle(r,e)||!t.services.backendConnector.backend||t.options.resources&&!t.options.partialBundledLanguages||s(r,e)&&(!i||s(o,e)))}function WA(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};if(!t.languages||!t.languages.length)return Fv("i18n.languages were undefined or empty",t.languages),!0;var r=t.options.ignoreJSONStructure!==void 0;return r?t.hasLoadedNamespace(e,{lng:n.lng,precheck:function(o,s){if(n.bindI18n&&n.bindI18n.indexOf("languageChanging")>-1&&o.services.backendConnector.backend&&o.isLanguageChangingTo&&!s(o.isLanguageChangingTo,e))return!1}}):UA(e,t,n)}var zA=/&(?:amp|#38|lt|#60|gt|#62|apos|#39|quot|#34|nbsp|#160|copy|#169|reg|#174|hellip|#8230|#x2F|#47);/g,YA={"&":"&","&":"&","<":"<","<":"<",">":">",">":">","'":"'","'":"'",""":'"',""":'"'," ":" "," ":" ","©":"©","©":"©","®":"®","®":"®","…":"…","…":"…","/":"/","/":"/"},GA=function(t){return YA[t]},qA=function(t){return t.replace(zA,GA)};function k0(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function O0(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?k0(Object(n),!0).forEach(function(r){$s(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):k0(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}var jv={bindI18n:"languageChanged",bindI18nStore:"",transEmptyNodeValue:"",transSupportBasicHtmlNodes:!0,transWrapTextNodes:"",transKeepBasicHtmlNodesFor:["br","strong","i","p"],useSuspense:!0,unescape:qA};function XA(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};jv=O0(O0({},jv),e)}function KA(){return jv}var W1;function ZA(e){W1=e}function JA(){return W1}var QA={type:"3rdParty",init:function(t){XA(t.options.react),ZA(t)}},z1=Q.createContext(),eM=function(){function e(){ta(this,e),this.usedNamespaces={}}return na(e,[{key:"addUsedNamespaces",value:function(n){var r=this;n.forEach(function(i){r.usedNamespaces[i]||(r.usedNamespaces[i]=!0)})}},{key:"getUsedNamespaces",value:function(){return Object.keys(this.usedNamespaces)}}]),e}();function tM(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var r,i,o,s,l=[],c=!0,d=!1;try{if(o=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=o.call(n)).done)&&(l.push(r.value),l.length!==t);c=!0);}catch(v){d=!0,i=v}finally{try{if(!c&&n.return!=null&&(s=n.return(),Object(s)!==s))return}finally{if(d)throw i}}return l}}function nM(e,t){return E1(e)||tM(e,t)||k1(e,t)||O1()}function D0(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Ag(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?D0(Object(n),!0).forEach(function(r){$s(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):D0(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}var rM=function(t,n){var r=Q.useRef();return Q.useEffect(function(){r.current=n?r.current:t},[t,n]),r.current};function Y1(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=t.i18n,r=Q.useContext(z1)||{},i=r.i18n,o=r.defaultNS,s=n||i||JA();if(s&&!s.reportNamespaces&&(s.reportNamespaces=new eM),!s){Fv("You will need to pass in an i18next instance by using initReactI18next");var l=function(ae,je){return typeof je=="string"?je:je&&Jo(je)==="object"&&typeof je.defaultValue=="string"?je.defaultValue:Array.isArray(ae)?ae[ae.length-1]:ae},c=[l,{},!1];return c.t=l,c.i18n={},c.ready=!1,c}s.options.react&&s.options.react.wait!==void 0&&Fv("It seems you are still using the old wait option, you may migrate to the new useSuspense behaviour.");var d=Ag(Ag(Ag({},KA()),s.options.react),t),v=d.useSuspense,p=d.keyPrefix,S=e||o||s.options&&s.options.defaultNS;S=typeof S=="string"?[S]:S||["translation"],s.reportNamespaces.addUsedNamespaces&&s.reportNamespaces.addUsedNamespaces(S);var T=(s.isInitialized||s.initializedStoreOnce)&&S.every(function(ce){return WA(ce,s,d)});function _(){return s.getFixedT(t.lng||null,d.nsMode==="fallback"?S:S[0],p)}var R=Q.useState(_),L=nM(R,2),I=L[0],U=L[1],z=S.join();t.lng&&(z="".concat(t.lng).concat(z));var re=rM(z),Z=Q.useRef(!0);Q.useEffect(function(){var ce=d.bindI18n,ae=d.bindI18nStore;Z.current=!0,!T&&!v&&(t.lng?E0(s,t.lng,S,function(){Z.current&&U(_)}):C0(s,S,function(){Z.current&&U(_)})),T&&re&&re!==z&&Z.current&&U(_);function je(){Z.current&&U(_)}return ce&&s&&s.on(ce,je),ae&&s&&s.store.on(ae,je),function(){Z.current=!1,ce&&s&&ce.split(" ").forEach(function(qe){return s.off(qe,je)}),ae&&s&&ae.split(" ").forEach(function(qe){return s.store.off(qe,je)})}},[s,z]);var he=Q.useRef(!0);Q.useEffect(function(){Z.current&&!he.current&&U(_),he.current=!1},[s,p]);var x=[I,s,T];if(x.t=I,x.i18n=s,x.ready=T,T||!T&&!v)return x;throw new Promise(function(ce){t.lng?E0(s,t.lng,S,function(){return ce()}):C0(s,S,function(){return ce()})})}function iM(e){var t=e.i18n,n=e.defaultNS,r=e.children,i=Q.useMemo(function(){return{i18n:t,defaultNS:n}},[t,n]);return Q.createElement(z1.Provider,{value:i},r)}var G1=[],oM=G1.forEach,aM=G1.slice;function sM(e){return oM.call(aM.call(arguments,1),function(t){if(t)for(var n in t)e[n]===void 0&&(e[n]=t[n])}),e}function uM(e){return e?typeof e=="function"?new e:e:null}function lM(){return{handleEmptyResourcesAsFailed:!0,cacheHitMode:"none"}}function P0(e,t,n,r){var i=e.read.bind(e);if(i.length===2){try{var o=i(t,n);o&&typeof o.then=="function"?o.then(function(s){return r(null,s)}).catch(r):r(null,o)}catch(s){r(s)}return}i(t,n,r)}var q1=function(){function e(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};ta(this,e),this.backends=[],this.type="backend",this.allOptions=r,this.init(t,n)}return na(e,[{key:"init",value:function(n){var r=this,i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};this.services=n,this.options=sM(i,this.options||{},lM()),this.allOptions=o,this.options.backends&&this.options.backends.forEach(function(s,l){r.backends[l]=r.backends[l]||uM(s),r.backends[l].init(n,r.options.backendOptions&&r.options.backendOptions[l]||{},o)}),this.services&&this.options.reloadInterval&&setInterval(function(){return r.reload()},this.options.reloadInterval)}},{key:"read",value:function(n,r,i){var o=this,s=this.backends.length,l=function d(v){if(v>=s)return i(new Error("non of the backend loaded data",!0));var p=v===s-1,S=o.options.handleEmptyResourcesAsFailed&&!p?0:-1,T=o.backends[v];T.read?P0(T,n,r,function(_,R,L){if(!_&&R&&Object.keys(R).length>S){if(i(null,R,v),c(v-1,R),T.save&&o.options.cacheHitMode&&["refresh","refreshAndUpdateStore"].indexOf(o.options.cacheHitMode)>-1){if(L&&o.options.refreshExpirationTime&&L+o.options.refreshExpirationTime>Date.now())return;var I=o.backends[v+1];I&&I.read&&P0(I,n,r,function(U,z){U||z&&(Object.keys(z).length<=S||(c(v,z),o.options.cacheHitMode==="refreshAndUpdateStore"&&o.services&&o.services.resourceStore&&o.services.resourceStore.addResourceBundle(n,r,z)))})}}else d(v+1)}):d(v+1)},c=function d(v,p){if(!(v<0)){var S=o.backends[v];S.save&&S.save(n,r,p),d(v-1,p)}};l(0)}},{key:"create",value:function(n,r,i,o){var s=arguments.length>4&&arguments[4]!==void 0?arguments[4]:function(){},l=arguments.length>5&&arguments[5]!==void 0?arguments[5]:{};this.backends.forEach(function(c){if(c.create){var d=c.create.bind(c);if(d.length<6){try{var v;d.length===5?v=d(n,r,i,o,l):v=d(n,r,i,o),v&&typeof v.then=="function"?v.then(function(p){return s(null,p)}).catch(s):s(null,v)}catch(p){s(p)}return}d(n,r,i,o,s,l)}})}},{key:"reload",value:function(){var n=this,r=this.services,i=r.backendConnector,o=r.languageUtils,s=r.logger,l=i.language;if(!(l&&l.toLowerCase()==="cimode")){var c=[],d=function(p){var S=o.toResolveHierarchy(p);S.forEach(function(T){c.indexOf(T)<0&&c.push(T)})};d(l),this.allOptions.preload&&this.allOptions.preload.forEach(function(v){return d(v)}),c.forEach(function(v){n.allOptions.ns.forEach(function(p){i.read(v,p,"read",null,null,function(S,T){S&&s.warn("loading namespace ".concat(p," for language ").concat(v," failed"),S),!S&&T&&s.log("loaded namespace ".concat(p," for language ").concat(v),T),i.loaded("".concat(v,"|").concat(p),S,T)})})})}}}]),e}();q1.type="backend";function Bv(e){"@babel/helpers - typeof";return Bv=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Bv(e)}function X1(){return typeof XMLHttpRequest=="function"||(typeof XMLHttpRequest>"u"?"undefined":Bv(XMLHttpRequest))==="object"}function cM(e){return!!e&&typeof e.then=="function"}function fM(e){return cM(e)?e:Promise.resolve(e)}function dM(e){throw new Error('Could not dynamically require "'+e+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var $v={exports:{}},ch={exports:{}},_0;function hM(){return _0||(_0=1,function(e,t){var n=typeof globalThis<"u"&&globalThis||typeof self<"u"&&self||typeof Ko<"u"&&Ko,r=function(){function o(){this.fetch=!1,this.DOMException=n.DOMException}return o.prototype=n,new o}();(function(o){(function(s){var l=typeof o<"u"&&o||typeof self<"u"&&self||typeof l<"u"&&l,c={searchParams:"URLSearchParams"in l,iterable:"Symbol"in l&&"iterator"in Symbol,blob:"FileReader"in l&&"Blob"in l&&function(){try{return new Blob,!0}catch{return!1}}(),formData:"FormData"in l,arrayBuffer:"ArrayBuffer"in l};function d(ye){return ye&&DataView.prototype.isPrototypeOf(ye)}if(c.arrayBuffer)var v=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],p=ArrayBuffer.isView||function(ye){return ye&&v.indexOf(Object.prototype.toString.call(ye))>-1};function S(ye){if(typeof ye!="string"&&(ye=String(ye)),/[^a-z0-9\-#$%&'*+.^_`|~!]/i.test(ye)||ye==="")throw new TypeError('Invalid character in header field name: "'+ye+'"');return ye.toLowerCase()}function T(ye){return typeof ye!="string"&&(ye=String(ye)),ye}function _(ye){var De={next:function(){var He=ye.shift();return{done:He===void 0,value:He}}};return c.iterable&&(De[Symbol.iterator]=function(){return De}),De}function R(ye){this.map={},ye instanceof R?ye.forEach(function(De,He){this.append(He,De)},this):Array.isArray(ye)?ye.forEach(function(De){this.append(De[0],De[1])},this):ye&&Object.getOwnPropertyNames(ye).forEach(function(De){this.append(De,ye[De])},this)}R.prototype.append=function(ye,De){ye=S(ye),De=T(De);var He=this.map[ye];this.map[ye]=He?He+", "+De:De},R.prototype.delete=function(ye){delete this.map[S(ye)]},R.prototype.get=function(ye){return ye=S(ye),this.has(ye)?this.map[ye]:null},R.prototype.has=function(ye){return this.map.hasOwnProperty(S(ye))},R.prototype.set=function(ye,De){this.map[S(ye)]=T(De)},R.prototype.forEach=function(ye,De){for(var He in this.map)this.map.hasOwnProperty(He)&&ye.call(De,this.map[He],He,this)},R.prototype.keys=function(){var ye=[];return this.forEach(function(De,He){ye.push(He)}),_(ye)},R.prototype.values=function(){var ye=[];return this.forEach(function(De){ye.push(De)}),_(ye)},R.prototype.entries=function(){var ye=[];return this.forEach(function(De,He){ye.push([He,De])}),_(ye)},c.iterable&&(R.prototype[Symbol.iterator]=R.prototype.entries);function L(ye){if(ye.bodyUsed)return Promise.reject(new TypeError("Already read"));ye.bodyUsed=!0}function I(ye){return new Promise(function(De,He){ye.onload=function(){De(ye.result)},ye.onerror=function(){He(ye.error)}})}function U(ye){var De=new FileReader,He=I(De);return De.readAsArrayBuffer(ye),He}function z(ye){var De=new FileReader,He=I(De);return De.readAsText(ye),He}function re(ye){for(var De=new Uint8Array(ye),He=new Array(De.length),Je=0;Je<De.length;Je++)He[Je]=String.fromCharCode(De[Je]);return He.join("")}function Z(ye){if(ye.slice)return ye.slice(0);var De=new Uint8Array(ye.byteLength);return De.set(new Uint8Array(ye)),De.buffer}function he(){return this.bodyUsed=!1,this._initBody=function(ye){this.bodyUsed=this.bodyUsed,this._bodyInit=ye,ye?typeof ye=="string"?this._bodyText=ye:c.blob&&Blob.prototype.isPrototypeOf(ye)?this._bodyBlob=ye:c.formData&&FormData.prototype.isPrototypeOf(ye)?this._bodyFormData=ye:c.searchParams&&URLSearchParams.prototype.isPrototypeOf(ye)?this._bodyText=ye.toString():c.arrayBuffer&&c.blob&&d(ye)?(this._bodyArrayBuffer=Z(ye.buffer),this._bodyInit=new Blob([this._bodyArrayBuffer])):c.arrayBuffer&&(ArrayBuffer.prototype.isPrototypeOf(ye)||p(ye))?this._bodyArrayBuffer=Z(ye):this._bodyText=ye=Object.prototype.toString.call(ye):this._bodyText="",this.headers.get("content-type")||(typeof ye=="string"?this.headers.set("content-type","text/plain;charset=UTF-8"):this._bodyBlob&&this._bodyBlob.type?this.headers.set("content-type",this._bodyBlob.type):c.searchParams&&URLSearchParams.prototype.isPrototypeOf(ye)&&this.headers.set("content-type","application/x-www-form-urlencoded;charset=UTF-8"))},c.blob&&(this.blob=function(){var ye=L(this);if(ye)return ye;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 ye=L(this);return ye||(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(U)}),this.text=function(){var ye=L(this);if(ye)return ye;if(this._bodyBlob)return z(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(re(this._bodyArrayBuffer));if(this._bodyFormData)throw new Error("could not read FormData body as text");return Promise.resolve(this._bodyText)},c.formData&&(this.formData=function(){return this.text().then(je)}),this.json=function(){return this.text().then(JSON.parse)},this}var x=["DELETE","GET","HEAD","OPTIONS","POST","PUT"];function ce(ye){var De=ye.toUpperCase();return x.indexOf(De)>-1?De:ye}function ae(ye,De){if(!(this instanceof ae))throw new TypeError('Please use the "new" operator, this DOM object constructor cannot be called as a function.');De=De||{};var He=De.body;if(ye instanceof ae){if(ye.bodyUsed)throw new TypeError("Already read");this.url=ye.url,this.credentials=ye.credentials,De.headers||(this.headers=new R(ye.headers)),this.method=ye.method,this.mode=ye.mode,this.signal=ye.signal,!He&&ye._bodyInit!=null&&(He=ye._bodyInit,ye.bodyUsed=!0)}else this.url=String(ye);if(this.credentials=De.credentials||this.credentials||"same-origin",(De.headers||!this.headers)&&(this.headers=new R(De.headers)),this.method=ce(De.method||this.method||"GET"),this.mode=De.mode||this.mode||null,this.signal=De.signal||this.signal,this.referrer=null,(this.method==="GET"||this.method==="HEAD")&&He)throw new TypeError("Body not allowed for GET or HEAD requests");if(this._initBody(He),(this.method==="GET"||this.method==="HEAD")&&(De.cache==="no-store"||De.cache==="no-cache")){var Je=/([?&])_=[^&]*/;if(Je.test(this.url))this.url=this.url.replace(Je,"$1_="+new Date().getTime());else{var at=/\?/;this.url+=(at.test(this.url)?"&":"?")+"_="+new Date().getTime()}}}ae.prototype.clone=function(){return new ae(this,{body:this._bodyInit})};function je(ye){var De=new FormData;return ye.trim().split("&").forEach(function(He){if(He){var Je=He.split("="),at=Je.shift().replace(/\+/g," "),Oe=Je.join("=").replace(/\+/g," ");De.append(decodeURIComponent(at),decodeURIComponent(Oe))}}),De}function qe(ye){var De=new R,He=ye.replace(/\r?\n[\t ]+/g," ");return He.split("\r").map(function(Je){return Je.indexOf(`
|
|
5
5
|
`)===0?Je.substr(1,Je.length):Je}).forEach(function(Je){var at=Je.split(":"),Oe=at.shift().trim();if(Oe){var xe=at.join(":").trim();De.append(Oe,xe)}}),De}he.call(ae.prototype);function We(ye,De){if(!(this instanceof We))throw new TypeError('Please use the "new" operator, this DOM object constructor cannot be called as a function.');De||(De={}),this.type="default",this.status=De.status===void 0?200:De.status,this.ok=this.status>=200&&this.status<300,this.statusText=De.statusText===void 0?"":""+De.statusText,this.headers=new R(De.headers),this.url=De.url||"",this._initBody(ye)}he.call(We.prototype),We.prototype.clone=function(){return new We(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new R(this.headers),url:this.url})},We.error=function(){var ye=new We(null,{status:0,statusText:""});return ye.type="error",ye};var rt=[301,302,303,307,308];We.redirect=function(ye,De){if(rt.indexOf(De)===-1)throw new RangeError("Invalid status code");return new We(null,{status:De,headers:{location:ye}})},s.DOMException=l.DOMException;try{new s.DOMException}catch{s.DOMException=function(De,He){this.message=De,this.name=He;var Je=Error(De);this.stack=Je.stack},s.DOMException.prototype=Object.create(Error.prototype),s.DOMException.prototype.constructor=s.DOMException}function nt(ye,De){return new Promise(function(He,Je){var at=new ae(ye,De);if(at.signal&&at.signal.aborted)return Je(new s.DOMException("Aborted","AbortError"));var Oe=new XMLHttpRequest;function xe(){Oe.abort()}Oe.onload=function(){var Ve={status:Oe.status,statusText:Oe.statusText,headers:qe(Oe.getAllResponseHeaders()||"")};Ve.url="responseURL"in Oe?Oe.responseURL:Ve.headers.get("X-Request-URL");var Re="response"in Oe?Oe.response:Oe.responseText;setTimeout(function(){He(new We(Re,Ve))},0)},Oe.onerror=function(){setTimeout(function(){Je(new TypeError("Network request failed"))},0)},Oe.ontimeout=function(){setTimeout(function(){Je(new TypeError("Network request failed"))},0)},Oe.onabort=function(){setTimeout(function(){Je(new s.DOMException("Aborted","AbortError"))},0)};function Ue(Ve){try{return Ve===""&&l.location.href?l.location.href:Ve}catch{return Ve}}Oe.open(at.method,Ue(at.url),!0),at.credentials==="include"?Oe.withCredentials=!0:at.credentials==="omit"&&(Oe.withCredentials=!1),"responseType"in Oe&&(c.blob?Oe.responseType="blob":c.arrayBuffer&&at.headers.get("Content-Type")&&at.headers.get("Content-Type").indexOf("application/octet-stream")!==-1&&(Oe.responseType="arraybuffer")),De&&typeof De.headers=="object"&&!(De.headers instanceof R)?Object.getOwnPropertyNames(De.headers).forEach(function(Ve){Oe.setRequestHeader(Ve,T(De.headers[Ve]))}):at.headers.forEach(function(Ve,Re){Oe.setRequestHeader(Re,Ve)}),at.signal&&(at.signal.addEventListener("abort",xe),Oe.onreadystatechange=function(){Oe.readyState===4&&at.signal.removeEventListener("abort",xe)}),Oe.send(typeof at._bodyInit>"u"?null:at._bodyInit)})}return nt.polyfill=!0,l.fetch||(l.fetch=nt,l.Headers=R,l.Request=ae,l.Response=We),s.Headers=R,s.Request=ae,s.Response=We,s.fetch=nt,s})({})})(r),r.fetch.ponyfill=!0,delete r.fetch.polyfill;var i=n.fetch?n:r;t=i.fetch,t.default=i.fetch,t.fetch=i.fetch,t.Headers=i.Headers,t.Request=i.Request,t.Response=i.Response,e.exports=t}(ch,ch.exports)),ch.exports}(function(e,t){var n;if(typeof fetch=="function"&&(typeof Ko<"u"&&Ko.fetch?n=Ko.fetch:typeof window<"u"&&window.fetch?n=window.fetch:n=fetch),typeof dM<"u"&&(typeof window>"u"||typeof window.document>"u")){var r=n||hM();r.default&&(r=r.default),t.default=r,e.exports=t.default}})($v,$v.exports);var K1=$v.exports;const Z1=Bc(K1),R0=RI({__proto__:null,default:Z1},[K1]);function I0(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function A0(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?I0(Object(n),!0).forEach(function(r){pM(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):I0(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function pM(e,t,n){return t=gM(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function gM(e){var t=vM(e,"string");return Rc(t)=="symbol"?t:String(t)}function vM(e,t){if(Rc(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(Rc(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Rc(e){"@babel/helpers - typeof";return Rc=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Rc(e)}var Du;typeof fetch=="function"&&(typeof global<"u"&&global.fetch?Du=global.fetch:typeof window<"u"&&window.fetch?Du=window.fetch:Du=fetch);var Td;X1()&&(typeof global<"u"&&global.XMLHttpRequest?Td=global.XMLHttpRequest:typeof window<"u"&&window.XMLHttpRequest&&(Td=window.XMLHttpRequest));var tp;typeof ActiveXObject=="function"&&(typeof global<"u"&&global.ActiveXObject?tp=global.ActiveXObject:typeof window<"u"&&window.ActiveXObject&&(tp=window.ActiveXObject));!Du&&R0&&!Td&&!tp&&(Du=Z1||R0);typeof Du!="function"&&(Du=void 0);var Vv=function(t,n){if(n&&Rc(n)==="object"){var r="";for(var i in n)r+="&"+encodeURIComponent(i)+"="+encodeURIComponent(n[i]);if(!r)return t;t=t+(t.indexOf("?")!==-1?"&":"?")+r.slice(1)}return t},M0=function(t,n,r,i){var o=function(c){if(!c.ok)return r(c.statusText||"Error",{status:c.status});c.text().then(function(d){r(null,{status:c.status,data:d})}).catch(r)};if(i){var s=i(t,n);if(s instanceof Promise){s.then(o).catch(r);return}}typeof fetch=="function"?fetch(t,n).then(o).catch(r):Du(t,n).then(o).catch(r)},L0=!1,mM=function(t,n,r,i){t.queryStringParams&&(n=Vv(n,t.queryStringParams));var o=A0({},typeof t.customHeaders=="function"?t.customHeaders():t.customHeaders);typeof window>"u"&&typeof global<"u"&&typeof global.process<"u"&&global.process.versions&&global.process.versions.node&&(o["User-Agent"]="i18next-http-backend (node/".concat(global.process.version,"; ").concat(global.process.platform," ").concat(global.process.arch,")")),r&&(o["Content-Type"]="application/json");var s=typeof t.requestOptions=="function"?t.requestOptions(r):t.requestOptions,l=A0({method:r?"POST":"GET",body:r?t.stringify(r):void 0,headers:o},L0?{}:s),c=typeof t.alternateFetch=="function"&&t.alternateFetch.length>=1?t.alternateFetch:void 0;try{M0(n,l,i,c)}catch(d){if(!s||Object.keys(s).length===0||!d.message||d.message.indexOf("not implemented")<0)return i(d);try{Object.keys(s).forEach(function(v){delete l[v]}),M0(n,l,i,c),L0=!0}catch(v){i(v)}}},yM=function(t,n,r,i){r&&Rc(r)==="object"&&(r=Vv("",r).slice(1)),t.queryStringParams&&(n=Vv(n,t.queryStringParams));try{var o;Td?o=new Td:o=new tp("MSXML2.XMLHTTP.3.0"),o.open(r?"POST":"GET",n,1),t.crossDomain||o.setRequestHeader("X-Requested-With","XMLHttpRequest"),o.withCredentials=!!t.withCredentials,r&&o.setRequestHeader("Content-Type","application/x-www-form-urlencoded"),o.overrideMimeType&&o.overrideMimeType("application/json");var s=t.customHeaders;if(s=typeof s=="function"?s():s,s)for(var l in s)o.setRequestHeader(l,s[l]);o.onreadystatechange=function(){o.readyState>3&&i(o.status>=400?o.statusText:null,{status:o.status,data:o.responseText})},o.send(r)}catch(c){console&&console.log(c)}},bM=function(t,n,r,i){if(typeof r=="function"&&(i=r,r=void 0),i=i||function(){},Du&&n.indexOf("file:")!==0)return mM(t,n,r,i);if(X1()||typeof ActiveXObject=="function")return yM(t,n,r,i);i(new Error("No fetch and no xhr implementation found!"))};function Cd(e){"@babel/helpers - typeof";return Cd=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Cd(e)}function N0(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Mg(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?N0(Object(n),!0).forEach(function(r){J1(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):N0(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function wM(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function F0(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,Q1(r.key),r)}}function xM(e,t,n){return t&&F0(e.prototype,t),n&&F0(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function J1(e,t,n){return t=Q1(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Q1(e){var t=SM(e,"string");return Cd(t)=="symbol"?t:String(t)}function SM(e,t){if(Cd(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(Cd(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var TM=function(){return{loadPath:"/locales/{{lng}}/{{ns}}.json",addPath:"/locales/add/{{lng}}/{{ns}}",parse:function(n){return JSON.parse(n)},stringify:JSON.stringify,parsePayload:function(n,r,i){return J1({},r,i||"")},parseLoadPayload:function(n,r){},request:bM,reloadInterval:typeof window<"u"?!1:60*60*1e3,customHeaders:{},queryStringParams:{},crossDomain:!1,withCredentials:!1,overrideMimeType:!1,requestOptions:{mode:"cors",credentials:"same-origin",cache:"default"}}},eT=function(){function e(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};wM(this,e),this.services=t,this.options=n,this.allOptions=r,this.type="backend",this.init(t,n,r)}return xM(e,[{key:"init",value:function(n){var r=this,i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};this.services=n,this.options=Mg(Mg(Mg({},TM()),this.options||{}),i),this.allOptions=o,this.services&&this.options.reloadInterval&&setInterval(function(){return r.reload()},this.options.reloadInterval)}},{key:"readMulti",value:function(n,r,i){this._readAny(n,n,r,r,i)}},{key:"read",value:function(n,r,i){this._readAny([n],n,[r],r,i)}},{key:"_readAny",value:function(n,r,i,o,s){var l=this,c=this.options.loadPath;typeof this.options.loadPath=="function"&&(c=this.options.loadPath(n,i)),c=fM(c),c.then(function(d){if(!d)return s(null,{});var v=l.services.interpolator.interpolate(d,{lng:n.join("+"),ns:i.join("+")});l.loadUrl(v,s,r,o)})}},{key:"loadUrl",value:function(n,r,i,o){var s=this,l=typeof i=="string"?[i]:i,c=typeof o=="string"?[o]:o,d=this.options.parseLoadPayload(l,c);this.options.request(this.options,n,d,function(v,p){if(p&&(p.status>=500&&p.status<600||!p.status))return r("failed loading "+n+"; status code: "+p.status,!0);if(p&&p.status>=400&&p.status<500)return r("failed loading "+n+"; status code: "+p.status,!1);if(!p&&v&&v.message&&v.message.indexOf("Failed to fetch")>-1)return r("failed loading "+n+": "+v.message,!0);if(v)return r(v,!1);var S,T;try{typeof p.data=="string"?S=s.options.parse(p.data,i,o):S=p.data}catch{T="failed parsing "+n+" to json"}if(T)return r(T,!1);r(null,S)})}},{key:"create",value:function(n,r,i,o,s){var l=this;if(this.options.addPath){typeof n=="string"&&(n=[n]);var c=this.options.parsePayload(r,i,o),d=0,v=[],p=[];n.forEach(function(S){var T=l.options.addPath;typeof l.options.addPath=="function"&&(T=l.options.addPath(S,r));var _=l.services.interpolator.interpolate(T,{lng:S,ns:r});l.options.request(l.options,_,c,function(R,L){d+=1,v.push(R),p.push(L),d===n.length&&typeof s=="function"&&s(v,p)})})}}},{key:"reload",value:function(){var n=this,r=this.services,i=r.backendConnector,o=r.languageUtils,s=r.logger,l=i.language;if(!(l&&l.toLowerCase()==="cimode")){var c=[],d=function(p){var S=o.toResolveHierarchy(p);S.forEach(function(T){c.indexOf(T)<0&&c.push(T)})};d(l),this.allOptions.preload&&this.allOptions.preload.forEach(function(v){return d(v)}),c.forEach(function(v){n.allOptions.ns.forEach(function(p){i.read(v,p,"read",null,null,function(S,T){S&&s.warn("loading namespace ".concat(p," for language ").concat(v," failed"),S),!S&&T&&s.log("loaded namespace ".concat(p," for language ").concat(v),T),i.loaded("".concat(v,"|").concat(p),S,T)})})})}}}]),e}();eT.type="backend";var zm=(e=>(e.en="en",e.de="de",e))(zm||{});const CM={en:"English",de:"German"};li.use(q1).use(QA).use(H1).init({initImmediate:!0,ns:["translation"],fallbackLng:Object.keys(CM),fallbackNS:"translation",partialBundledLanguages:!0,resources:{},interpolation:{escapeValue:!1},backend:{backends:[eT],backendOptions:[{loadPath:"https://ukpcsaprod.blob.core.windows.net/lib/translations/{{lng}}/{{ns}}.json",crossDomain:!0,cacheHitMode:"refresh"}]}});const EM=e=>{const t=Sd.useQueryClient(),n=Q.useMemo(()=>e.axiosInstance||Ls,[e.axiosInstance]);window.env||(window.env={}),window.env.AUTHEN_DOMAIN=new URL(e.baseUrl).origin;const r=Sd.useQuery({queryKey:["user"],refetchOnWindowFocus:!1,retry:!1,queryFn:()=>n.get(e.baseUrl+"/user-management/api/v1/users/my-account").then(i=>i.data)});return Q.useEffect(()=>{window.onpageshow=function(i){i.persisted&&t.invalidateQueries(["user"])}},[t]),r},kM=e=>{const t=Sd.useQueryClient(),n=Q.useMemo(()=>e.axiosInstance||Ls,[e.axiosInstance]);window.env||(window.env={}),window.env.AUTHEN_DOMAIN=new URL(e.baseUrl).origin;const r=Sd.useQuery({queryKey:["user-permissions"],refetchOnWindowFocus:!1,retry:!1,queryFn:()=>n.get(e.baseUrl+"/user-management/api/v1/users/my-account/permissions").then(i=>i.data)});return Q.useEffect(()=>{window.onpageshow=function(i){i.persisted&&t.invalidateQueries(["user-permissions"])}},[t]),r},j0=window.location.href,Ym=Q.createContext({}),OM=e=>{const{children:t,baseUrl:n,axiosInstance:r}=e,i=new URL(n).origin,o=EM({axiosInstance:r,baseUrl:n}),s=kM({axiosInstance:r,baseUrl:n});function l(){const v=document.cookie.split(";");for(let p=0;p<v.length;p++){const S=v[p],T=S.indexOf("="),_=T>-1?S.substr(0,T):S;document.cookie=_+"=;expires=Thu, 01 Jan 1970 00:00:00 GMT"}}function c(){window.location.href=`${i}/authentication/login?callbackUrl=${j0}`}function d(){l(),window.location.href=`${i}/authentication/logout?callbackUrl=${j0}`}return st.jsx(Ym.Provider,{value:{user:o==null?void 0:o.data,login:c,logout:d,isFetching:o.isFetching,permissions:s==null?void 0:s.data},children:t})},DM=()=>Q.useContext(Ym);function PM(e,t,n){return n.some(r=>{const i=e[r];return String(i).toLowerCase().includes(t.toLowerCase())})}function _M(){const[e,t]=Q.useState();return Q.useEffect(()=>{const n=localStorage.getItem("language");t(n||zm.en)},[]),{language:e,setLanguage:t}}const tT=Q.createContext({}),RM=()=>Q.useContext(tT),IM=li,AM=_1,MM=()=>Y1(),LM=({children:e})=>{const t=_M();return st.jsx(tT.Provider,{value:t,children:st.jsx(iM,{i18n:li,children:e})})};var NM=typeof global=="object"&&global&&global.Object===Object&&global;const FM=NM;var jM=typeof self=="object"&&self&&self.Object===Object&&self,BM=FM||jM||Function("return this")();const nT=BM;var $M=nT.Symbol;const np=$M;var rT=Object.prototype,VM=rT.hasOwnProperty,HM=rT.toString,Qf=np?np.toStringTag:void 0;function UM(e){var t=VM.call(e,Qf),n=e[Qf];try{e[Qf]=void 0;var r=!0}catch{}var i=HM.call(e);return r&&(t?e[Qf]=n:delete e[Qf]),i}var WM=Object.prototype,zM=WM.toString;function YM(e){return zM.call(e)}var GM="[object Null]",qM="[object Undefined]",B0=np?np.toStringTag:void 0;function XM(e){return e==null?e===void 0?qM:GM:B0&&B0 in Object(e)?UM(e):YM(e)}function KM(e){return e!=null&&typeof e=="object"}var ZM="[object Symbol]";function JM(e){return typeof e=="symbol"||KM(e)&&XM(e)==ZM}var QM=/\s/;function eL(e){for(var t=e.length;t--&&QM.test(e.charAt(t)););return t}var tL=/^\s+/;function nL(e){return e&&e.slice(0,eL(e)+1).replace(tL,"")}function rp(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var $0=0/0,rL=/^[-+]0x[0-9a-f]+$/i,iL=/^0b[01]+$/i,oL=/^0o[0-7]+$/i,aL=parseInt;function V0(e){if(typeof e=="number")return e;if(JM(e))return $0;if(rp(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=rp(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=nL(e);var n=iL.test(e);return n||oL.test(e)?aL(e.slice(2),n?2:8):rL.test(e)?$0:+e}var sL=function(){return nT.Date.now()};const Lg=sL;var uL="Expected a function",lL=Math.max,cL=Math.min;function Bh(e,t,n){var r,i,o,s,l,c,d=0,v=!1,p=!1,S=!0;if(typeof e!="function")throw new TypeError(uL);t=V0(t)||0,rp(n)&&(v=!!n.leading,p="maxWait"in n,o=p?lL(V0(n.maxWait)||0,t):o,S="trailing"in n?!!n.trailing:S);function T(he){var x=r,ce=i;return r=i=void 0,d=he,s=e.apply(ce,x),s}function _(he){return d=he,l=setTimeout(I,t),v?T(he):s}function R(he){var x=he-c,ce=he-d,ae=t-x;return p?cL(ae,o-ce):ae}function L(he){var x=he-c,ce=he-d;return c===void 0||x>=t||x<0||p&&ce>=o}function I(){var he=Lg();if(L(he))return U(he);l=setTimeout(I,R(he))}function U(he){return l=void 0,S&&r?T(he):(r=i=void 0,s)}function z(){l!==void 0&&clearTimeout(l),d=0,r=c=i=l=void 0}function re(){return l===void 0?s:U(Lg())}function Z(){var he=Lg(),x=L(he);if(r=arguments,i=this,c=he,x){if(l===void 0)return _(c);if(p)return clearTimeout(l),l=setTimeout(I,t),T(c)}return l===void 0&&(l=setTimeout(I,t)),s}return Z.cancel=z,Z.flush=re,Z}var fL="Expected a function";function dL(e,t,n){var r=!0,i=!0;if(typeof e!="function")throw new TypeError(fL);return rp(n)&&(r="leading"in n?!!n.leading:r,i="trailing"in n?!!n.trailing:i),Bh(e,t,{leading:r,maxWait:t,trailing:i})}var hL=!!(typeof window<"u"&&window.document&&window.document.createElement),pL=hL;const iT=Bc(pL);var wf=function(){return wf=Object.assign||function(t){for(var n,r=1,i=arguments.length;r<i;r++){n=arguments[r];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(t[o]=n[o])}return t},wf.apply(this,arguments)},yf=null,H0=null;iT&&window.addEventListener("resize",function(){H0!==window.devicePixelRatio&&(H0=window.devicePixelRatio,yf=null)});function U0(){if(yf===null){if(typeof document>"u")return yf=0,yf;var e=document.body,t=document.createElement("div");t.classList.add("simplebar-hide-scrollbar"),e.appendChild(t);var n=t.getBoundingClientRect().right;e.removeChild(t),yf=n}return yf}function oT(e){return!e||!e.ownerDocument||!e.ownerDocument.defaultView?window:e.ownerDocument.defaultView}function aT(e){return!e||!e.ownerDocument?document:e.ownerDocument}var sT=function(e){var t={},n=Array.prototype.reduce.call(e,function(r,i){var o=i.name.match(/data-simplebar-(.+)/);if(o){var s=o[1].replace(/\W+(.)/g,function(l,c){return c.toUpperCase()});switch(i.value){case"true":r[s]=!0;break;case"false":r[s]=!1;break;case void 0:r[s]=!0;break;default:r[s]=i.value}}return r},t);return n};function uT(e,t){var n;e&&(n=e.classList).add.apply(n,t.split(" "))}function lT(e,t){e&&t.split(" ").forEach(function(n){e.classList.remove(n)})}function cT(e){return".".concat(e.split(" ").join("."))}var gL=Object.freeze({__proto__:null,getElementWindow:oT,getElementDocument:aT,getOptions:sT,addClasses:uT,removeClasses:lT,classNamesToQuery:cT}),cl=oT,Ng=aT,vL=sT,fl=uT,dl=lT,Oo=cT,fh=function(){function e(t,n){n===void 0&&(n={});var r=this;if(this.removePreventClickId=null,this.minScrollbarWidth=20,this.stopScrollDelay=175,this.isScrolling=!1,this.isMouseEntering=!1,this.scrollXTicking=!1,this.scrollYTicking=!1,this.wrapperEl=null,this.contentWrapperEl=null,this.contentEl=null,this.offsetEl=null,this.maskEl=null,this.placeholderEl=null,this.heightAutoObserverWrapperEl=null,this.heightAutoObserverEl=null,this.rtlHelpers=null,this.scrollbarWidth=0,this.resizeObserver=null,this.mutationObserver=null,this.elStyles=null,this.isRtl=null,this.mouseX=0,this.mouseY=0,this.onMouseMove=function(){},this.onWindowResize=function(){},this.onStopScrolling=function(){},this.onMouseEntered=function(){},this.onScroll=function(){var i=cl(r.el);r.scrollXTicking||(i.requestAnimationFrame(r.scrollX),r.scrollXTicking=!0),r.scrollYTicking||(i.requestAnimationFrame(r.scrollY),r.scrollYTicking=!0),r.isScrolling||(r.isScrolling=!0,fl(r.el,r.classNames.scrolling)),r.showScrollbar("x"),r.showScrollbar("y"),r.onStopScrolling()},this.scrollX=function(){r.axis.x.isOverflowing&&r.positionScrollbar("x"),r.scrollXTicking=!1},this.scrollY=function(){r.axis.y.isOverflowing&&r.positionScrollbar("y"),r.scrollYTicking=!1},this._onStopScrolling=function(){dl(r.el,r.classNames.scrolling),r.options.autoHide&&(r.hideScrollbar("x"),r.hideScrollbar("y")),r.isScrolling=!1},this.onMouseEnter=function(){r.isMouseEntering||(fl(r.el,r.classNames.mouseEntered),r.showScrollbar("x"),r.showScrollbar("y"),r.isMouseEntering=!0),r.onMouseEntered()},this._onMouseEntered=function(){dl(r.el,r.classNames.mouseEntered),r.options.autoHide&&(r.hideScrollbar("x"),r.hideScrollbar("y")),r.isMouseEntering=!1},this._onMouseMove=function(i){r.mouseX=i.clientX,r.mouseY=i.clientY,(r.axis.x.isOverflowing||r.axis.x.forceVisible)&&r.onMouseMoveForAxis("x"),(r.axis.y.isOverflowing||r.axis.y.forceVisible)&&r.onMouseMoveForAxis("y")},this.onMouseLeave=function(){r.onMouseMove.cancel(),(r.axis.x.isOverflowing||r.axis.x.forceVisible)&&r.onMouseLeaveForAxis("x"),(r.axis.y.isOverflowing||r.axis.y.forceVisible)&&r.onMouseLeaveForAxis("y"),r.mouseX=-1,r.mouseY=-1},this._onWindowResize=function(){r.scrollbarWidth=r.getScrollbarWidth(),r.hideNativeScrollbar()},this.onPointerEvent=function(i){if(!(!r.axis.x.track.el||!r.axis.y.track.el||!r.axis.x.scrollbar.el||!r.axis.y.scrollbar.el)){var o,s;r.axis.x.track.rect=r.axis.x.track.el.getBoundingClientRect(),r.axis.y.track.rect=r.axis.y.track.el.getBoundingClientRect(),(r.axis.x.isOverflowing||r.axis.x.forceVisible)&&(o=r.isWithinBounds(r.axis.x.track.rect)),(r.axis.y.isOverflowing||r.axis.y.forceVisible)&&(s=r.isWithinBounds(r.axis.y.track.rect)),(o||s)&&(i.stopPropagation(),i.type==="pointerdown"&&i.pointerType!=="touch"&&(o&&(r.axis.x.scrollbar.rect=r.axis.x.scrollbar.el.getBoundingClientRect(),r.isWithinBounds(r.axis.x.scrollbar.rect)?r.onDragStart(i,"x"):r.onTrackClick(i,"x")),s&&(r.axis.y.scrollbar.rect=r.axis.y.scrollbar.el.getBoundingClientRect(),r.isWithinBounds(r.axis.y.scrollbar.rect)?r.onDragStart(i,"y"):r.onTrackClick(i,"y"))))}},this.drag=function(i){var o,s,l,c,d,v,p,S,T,_,R;if(!(!r.draggedAxis||!r.contentWrapperEl)){var L,I=r.axis[r.draggedAxis].track,U=(s=(o=I.rect)===null||o===void 0?void 0:o[r.axis[r.draggedAxis].sizeAttr])!==null&&s!==void 0?s:0,z=r.axis[r.draggedAxis].scrollbar,re=(c=(l=r.contentWrapperEl)===null||l===void 0?void 0:l[r.axis[r.draggedAxis].scrollSizeAttr])!==null&&c!==void 0?c:0,Z=parseInt((v=(d=r.elStyles)===null||d===void 0?void 0:d[r.axis[r.draggedAxis].sizeAttr])!==null&&v!==void 0?v:"0px",10);i.preventDefault(),i.stopPropagation(),r.draggedAxis==="y"?L=i.pageY:L=i.pageX;var he=L-((S=(p=I.rect)===null||p===void 0?void 0:p[r.axis[r.draggedAxis].offsetAttr])!==null&&S!==void 0?S:0)-r.axis[r.draggedAxis].dragOffset;he=r.draggedAxis==="x"&&r.isRtl?((_=(T=I.rect)===null||T===void 0?void 0:T[r.axis[r.draggedAxis].sizeAttr])!==null&&_!==void 0?_:0)-z.size-he:he;var x=he/(U-z.size),ce=x*(re-Z);r.draggedAxis==="x"&&r.isRtl&&(ce=!((R=e.getRtlHelpers())===null||R===void 0)&&R.isScrollingToNegative?-ce:ce),r.contentWrapperEl[r.axis[r.draggedAxis].scrollOffsetAttr]=ce}},this.onEndDrag=function(i){var o=Ng(r.el),s=cl(r.el);i.preventDefault(),i.stopPropagation(),dl(r.el,r.classNames.dragging),o.removeEventListener("mousemove",r.drag,!0),o.removeEventListener("mouseup",r.onEndDrag,!0),r.removePreventClickId=s.setTimeout(function(){o.removeEventListener("click",r.preventClick,!0),o.removeEventListener("dblclick",r.preventClick,!0),r.removePreventClickId=null})},this.preventClick=function(i){i.preventDefault(),i.stopPropagation()},this.el=t,this.options=wf(wf({},e.defaultOptions),n),this.classNames=wf(wf({},e.defaultOptions.classNames),n.classNames),this.axis={x:{scrollOffsetAttr:"scrollLeft",sizeAttr:"width",scrollSizeAttr:"scrollWidth",offsetSizeAttr:"offsetWidth",offsetAttr:"left",overflowAttr:"overflowX",dragOffset:0,isOverflowing:!0,forceVisible:!1,track:{size:null,el:null,rect:null,isVisible:!1},scrollbar:{size:null,el:null,rect:null,isVisible:!1}},y:{scrollOffsetAttr:"scrollTop",sizeAttr:"height",scrollSizeAttr:"scrollHeight",offsetSizeAttr:"offsetHeight",offsetAttr:"top",overflowAttr:"overflowY",dragOffset:0,isOverflowing:!0,forceVisible:!1,track:{size:null,el:null,rect:null,isVisible:!1},scrollbar:{size:null,el:null,rect:null,isVisible:!1}}},typeof this.el!="object"||!this.el.nodeName)throw new Error("Argument passed to SimpleBar must be an HTML element instead of ".concat(this.el));this.onMouseMove=dL(this._onMouseMove,64),this.onWindowResize=Bh(this._onWindowResize,64,{leading:!0}),this.onStopScrolling=Bh(this._onStopScrolling,this.stopScrollDelay),this.onMouseEntered=Bh(this._onMouseEntered,this.stopScrollDelay),this.init()}return e.getRtlHelpers=function(){if(e.rtlHelpers)return e.rtlHelpers;var t=document.createElement("div");t.innerHTML='<div class="simplebar-dummy-scrollbar-size"><div></div></div>';var n=t.firstElementChild,r=n==null?void 0:n.firstElementChild;if(!r)return null;document.body.appendChild(n),n.scrollLeft=0;var i=e.getOffset(n),o=e.getOffset(r);n.scrollLeft=-999;var s=e.getOffset(r);return document.body.removeChild(n),e.rtlHelpers={isScrollOriginAtZero:i.left!==o.left,isScrollingToNegative:o.left!==s.left},e.rtlHelpers},e.prototype.getScrollbarWidth=function(){try{return this.contentWrapperEl&&getComputedStyle(this.contentWrapperEl,"::-webkit-scrollbar").display==="none"||"scrollbarWidth"in document.documentElement.style||"-ms-overflow-style"in document.documentElement.style?0:U0()}catch{return U0()}},e.getOffset=function(t){var n=t.getBoundingClientRect(),r=Ng(t),i=cl(t);return{top:n.top+(i.pageYOffset||r.documentElement.scrollTop),left:n.left+(i.pageXOffset||r.documentElement.scrollLeft)}},e.prototype.init=function(){iT&&(this.initDOM(),this.rtlHelpers=e.getRtlHelpers(),this.scrollbarWidth=this.getScrollbarWidth(),this.recalculate(),this.initListeners())},e.prototype.initDOM=function(){var t,n;this.wrapperEl=this.el.querySelector(Oo(this.classNames.wrapper)),this.contentWrapperEl=this.options.scrollableNode||this.el.querySelector(Oo(this.classNames.contentWrapper)),this.contentEl=this.options.contentNode||this.el.querySelector(Oo(this.classNames.contentEl)),this.offsetEl=this.el.querySelector(Oo(this.classNames.offset)),this.maskEl=this.el.querySelector(Oo(this.classNames.mask)),this.placeholderEl=this.findChild(this.wrapperEl,Oo(this.classNames.placeholder)),this.heightAutoObserverWrapperEl=this.el.querySelector(Oo(this.classNames.heightAutoObserverWrapperEl)),this.heightAutoObserverEl=this.el.querySelector(Oo(this.classNames.heightAutoObserverEl)),this.axis.x.track.el=this.findChild(this.el,"".concat(Oo(this.classNames.track)).concat(Oo(this.classNames.horizontal))),this.axis.y.track.el=this.findChild(this.el,"".concat(Oo(this.classNames.track)).concat(Oo(this.classNames.vertical))),this.axis.x.scrollbar.el=((t=this.axis.x.track.el)===null||t===void 0?void 0:t.querySelector(Oo(this.classNames.scrollbar)))||null,this.axis.y.scrollbar.el=((n=this.axis.y.track.el)===null||n===void 0?void 0:n.querySelector(Oo(this.classNames.scrollbar)))||null,this.options.autoHide||(fl(this.axis.x.scrollbar.el,this.classNames.visible),fl(this.axis.y.scrollbar.el,this.classNames.visible))},e.prototype.initListeners=function(){var t=this,n,r=cl(this.el);if(this.el.addEventListener("mouseenter",this.onMouseEnter),this.el.addEventListener("pointerdown",this.onPointerEvent,!0),this.el.addEventListener("mousemove",this.onMouseMove),this.el.addEventListener("mouseleave",this.onMouseLeave),(n=this.contentWrapperEl)===null||n===void 0||n.addEventListener("scroll",this.onScroll),r.addEventListener("resize",this.onWindowResize),!!this.contentEl){if(window.ResizeObserver){var i=!1,o=r.ResizeObserver||ResizeObserver;this.resizeObserver=new o(function(){i&&r.requestAnimationFrame(function(){t.recalculate()})}),this.resizeObserver.observe(this.el),this.resizeObserver.observe(this.contentEl),r.requestAnimationFrame(function(){i=!0})}this.mutationObserver=new r.MutationObserver(function(){r.requestAnimationFrame(function(){t.recalculate()})}),this.mutationObserver.observe(this.contentEl,{childList:!0,subtree:!0,characterData:!0})}},e.prototype.recalculate=function(){if(!(!this.heightAutoObserverEl||!this.contentEl||!this.contentWrapperEl||!this.wrapperEl||!this.placeholderEl)){var t=cl(this.el);this.elStyles=t.getComputedStyle(this.el),this.isRtl=this.elStyles.direction==="rtl";var n=this.contentEl.offsetWidth,r=this.heightAutoObserverEl.offsetHeight<=1,i=this.heightAutoObserverEl.offsetWidth<=1||n>0,o=this.contentWrapperEl.offsetWidth,s=this.elStyles.overflowX,l=this.elStyles.overflowY;this.contentEl.style.padding="".concat(this.elStyles.paddingTop," ").concat(this.elStyles.paddingRight," ").concat(this.elStyles.paddingBottom," ").concat(this.elStyles.paddingLeft),this.wrapperEl.style.margin="-".concat(this.elStyles.paddingTop," -").concat(this.elStyles.paddingRight," -").concat(this.elStyles.paddingBottom," -").concat(this.elStyles.paddingLeft);var c=this.contentEl.scrollHeight,d=this.contentEl.scrollWidth;this.contentWrapperEl.style.height=r?"auto":"100%",this.placeholderEl.style.width=i?"".concat(n||d,"px"):"auto",this.placeholderEl.style.height="".concat(c,"px");var v=this.contentWrapperEl.offsetHeight;this.axis.x.isOverflowing=n!==0&&d>n,this.axis.y.isOverflowing=c>v,this.axis.x.isOverflowing=s==="hidden"?!1:this.axis.x.isOverflowing,this.axis.y.isOverflowing=l==="hidden"?!1:this.axis.y.isOverflowing,this.axis.x.forceVisible=this.options.forceVisible==="x"||this.options.forceVisible===!0,this.axis.y.forceVisible=this.options.forceVisible==="y"||this.options.forceVisible===!0,this.hideNativeScrollbar();var p=this.axis.x.isOverflowing?this.scrollbarWidth:0,S=this.axis.y.isOverflowing?this.scrollbarWidth:0;this.axis.x.isOverflowing=this.axis.x.isOverflowing&&d>o-S,this.axis.y.isOverflowing=this.axis.y.isOverflowing&&c>v-p,this.axis.x.scrollbar.size=this.getScrollbarSize("x"),this.axis.y.scrollbar.size=this.getScrollbarSize("y"),this.axis.x.scrollbar.el&&(this.axis.x.scrollbar.el.style.width="".concat(this.axis.x.scrollbar.size,"px")),this.axis.y.scrollbar.el&&(this.axis.y.scrollbar.el.style.height="".concat(this.axis.y.scrollbar.size,"px")),this.positionScrollbar("x"),this.positionScrollbar("y"),this.toggleTrackVisibility("x"),this.toggleTrackVisibility("y")}},e.prototype.getScrollbarSize=function(t){var n,r;if(t===void 0&&(t="y"),!this.axis[t].isOverflowing||!this.contentEl)return 0;var i=this.contentEl[this.axis[t].scrollSizeAttr],o=(r=(n=this.axis[t].track.el)===null||n===void 0?void 0:n[this.axis[t].offsetSizeAttr])!==null&&r!==void 0?r:0,s=o/i,l;return l=Math.max(~~(s*o),this.options.scrollbarMinSize),this.options.scrollbarMaxSize&&(l=Math.min(l,this.options.scrollbarMaxSize)),l},e.prototype.positionScrollbar=function(t){var n,r,i;t===void 0&&(t="y");var o=this.axis[t].scrollbar;if(!(!this.axis[t].isOverflowing||!this.contentWrapperEl||!o.el||!this.elStyles)){var s=this.contentWrapperEl[this.axis[t].scrollSizeAttr],l=((n=this.axis[t].track.el)===null||n===void 0?void 0:n[this.axis[t].offsetSizeAttr])||0,c=parseInt(this.elStyles[this.axis[t].sizeAttr],10),d=this.contentWrapperEl[this.axis[t].scrollOffsetAttr];d=t==="x"&&this.isRtl&&(!((r=e.getRtlHelpers())===null||r===void 0)&&r.isScrollOriginAtZero)?-d:d,t==="x"&&this.isRtl&&(d=!((i=e.getRtlHelpers())===null||i===void 0)&&i.isScrollingToNegative?d:-d);var v=d/(s-c),p=~~((l-o.size)*v);p=t==="x"&&this.isRtl?-p+(l-o.size):p,o.el.style.transform=t==="x"?"translate3d(".concat(p,"px, 0, 0)"):"translate3d(0, ".concat(p,"px, 0)")}},e.prototype.toggleTrackVisibility=function(t){t===void 0&&(t="y");var n=this.axis[t].track.el,r=this.axis[t].scrollbar.el;!n||!r||!this.contentWrapperEl||(this.axis[t].isOverflowing||this.axis[t].forceVisible?(n.style.visibility="visible",this.contentWrapperEl.style[this.axis[t].overflowAttr]="scroll",this.el.classList.add("".concat(this.classNames.scrollable,"-").concat(t))):(n.style.visibility="hidden",this.contentWrapperEl.style[this.axis[t].overflowAttr]="hidden",this.el.classList.remove("".concat(this.classNames.scrollable,"-").concat(t))),this.axis[t].isOverflowing?r.style.display="block":r.style.display="none")},e.prototype.showScrollbar=function(t){t===void 0&&(t="y"),this.axis[t].isOverflowing&&!this.axis[t].scrollbar.isVisible&&(fl(this.axis[t].scrollbar.el,this.classNames.visible),this.axis[t].scrollbar.isVisible=!0)},e.prototype.hideScrollbar=function(t){t===void 0&&(t="y"),this.axis[t].isOverflowing&&this.axis[t].scrollbar.isVisible&&(dl(this.axis[t].scrollbar.el,this.classNames.visible),this.axis[t].scrollbar.isVisible=!1)},e.prototype.hideNativeScrollbar=function(){this.offsetEl&&(this.offsetEl.style[this.isRtl?"left":"right"]=this.axis.y.isOverflowing||this.axis.y.forceVisible?"-".concat(this.scrollbarWidth,"px"):"0px",this.offsetEl.style.bottom=this.axis.x.isOverflowing||this.axis.x.forceVisible?"-".concat(this.scrollbarWidth,"px"):"0px")},e.prototype.onMouseMoveForAxis=function(t){t===void 0&&(t="y");var n=this.axis[t];!n.track.el||!n.scrollbar.el||(n.track.rect=n.track.el.getBoundingClientRect(),n.scrollbar.rect=n.scrollbar.el.getBoundingClientRect(),this.isWithinBounds(n.track.rect)?(this.showScrollbar(t),fl(n.track.el,this.classNames.hover),this.isWithinBounds(n.scrollbar.rect)?fl(n.scrollbar.el,this.classNames.hover):dl(n.scrollbar.el,this.classNames.hover)):(dl(n.track.el,this.classNames.hover),this.options.autoHide&&this.hideScrollbar(t)))},e.prototype.onMouseLeaveForAxis=function(t){t===void 0&&(t="y"),dl(this.axis[t].track.el,this.classNames.hover),dl(this.axis[t].scrollbar.el,this.classNames.hover),this.options.autoHide&&this.hideScrollbar(t)},e.prototype.onDragStart=function(t,n){var r;n===void 0&&(n="y");var i=Ng(this.el),o=cl(this.el),s=this.axis[n].scrollbar,l=n==="y"?t.pageY:t.pageX;this.axis[n].dragOffset=l-(((r=s.rect)===null||r===void 0?void 0:r[this.axis[n].offsetAttr])||0),this.draggedAxis=n,fl(this.el,this.classNames.dragging),i.addEventListener("mousemove",this.drag,!0),i.addEventListener("mouseup",this.onEndDrag,!0),this.removePreventClickId===null?(i.addEventListener("click",this.preventClick,!0),i.addEventListener("dblclick",this.preventClick,!0)):(o.clearTimeout(this.removePreventClickId),this.removePreventClickId=null)},e.prototype.onTrackClick=function(t,n){var r=this,i,o,s,l;n===void 0&&(n="y");var c=this.axis[n];if(!(!this.options.clickOnTrack||!c.scrollbar.el||!this.contentWrapperEl)){t.preventDefault();var d=cl(this.el);this.axis[n].scrollbar.rect=c.scrollbar.el.getBoundingClientRect();var v=this.axis[n].scrollbar,p=(o=(i=v.rect)===null||i===void 0?void 0:i[this.axis[n].offsetAttr])!==null&&o!==void 0?o:0,S=parseInt((l=(s=this.elStyles)===null||s===void 0?void 0:s[this.axis[n].sizeAttr])!==null&&l!==void 0?l:"0px",10),T=this.contentWrapperEl[this.axis[n].scrollOffsetAttr],_=n==="y"?this.mouseY-p:this.mouseX-p,R=_<0?-1:1,L=R===-1?T-S:T+S,I=40,U=function(){r.contentWrapperEl&&(R===-1?T>L&&(T-=I,r.contentWrapperEl[r.axis[n].scrollOffsetAttr]=T,d.requestAnimationFrame(U)):T<L&&(T+=I,r.contentWrapperEl[r.axis[n].scrollOffsetAttr]=T,d.requestAnimationFrame(U)))};U()}},e.prototype.getContentElement=function(){return this.contentEl},e.prototype.getScrollElement=function(){return this.contentWrapperEl},e.prototype.removeListeners=function(){var t=cl(this.el);this.el.removeEventListener("mouseenter",this.onMouseEnter),this.el.removeEventListener("pointerdown",this.onPointerEvent,!0),this.el.removeEventListener("mousemove",this.onMouseMove),this.el.removeEventListener("mouseleave",this.onMouseLeave),this.contentWrapperEl&&this.contentWrapperEl.removeEventListener("scroll",this.onScroll),t.removeEventListener("resize",this.onWindowResize),this.mutationObserver&&this.mutationObserver.disconnect(),this.resizeObserver&&this.resizeObserver.disconnect(),this.onMouseMove.cancel(),this.onWindowResize.cancel(),this.onStopScrolling.cancel(),this.onMouseEntered.cancel()},e.prototype.unMount=function(){this.removeListeners()},e.prototype.isWithinBounds=function(t){return this.mouseX>=t.left&&this.mouseX<=t.left+t.width&&this.mouseY>=t.top&&this.mouseY<=t.top+t.height},e.prototype.findChild=function(t,n){var r=t.matches||t.webkitMatchesSelector||t.mozMatchesSelector||t.msMatchesSelector;return Array.prototype.filter.call(t.children,function(i){return r.call(i,n)})[0]},e.rtlHelpers=null,e.defaultOptions={forceVisible:!1,clickOnTrack:!0,scrollbarMinSize:25,scrollbarMaxSize:0,ariaLabel:"scrollable content",classNames:{contentEl:"simplebar-content",contentWrapper:"simplebar-content-wrapper",offset:"simplebar-offset",mask:"simplebar-mask",wrapper:"simplebar-wrapper",placeholder:"simplebar-placeholder",scrollbar:"simplebar-scrollbar",track:"simplebar-track",heightAutoObserverWrapperEl:"simplebar-height-auto-observer-wrapper",heightAutoObserverEl:"simplebar-height-auto-observer",visible:"simplebar-visible",horizontal:"simplebar-horizontal",vertical:"simplebar-vertical",hover:"simplebar-hover",dragging:"simplebar-dragging",scrolling:"simplebar-scrolling",scrollable:"simplebar-scrollable",mouseEntered:"simplebar-mouse-entered"},scrollableNode:null,contentNode:null,autoHide:!0},e.getOptions=vL,e.helpers=gL,e}(),Xo=function(){return Xo=Object.assign||function(t){for(var n,r=1,i=arguments.length;r<i;r++){n=arguments[r];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(t[o]=n[o])}return t},Xo.apply(this,arguments)};function mL(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n}var fT=Sn.forwardRef(function(e,t){var n=e.children,r=e.scrollableNodeProps,i=r===void 0?{}:r,o=mL(e,["children","scrollableNodeProps"]),s=Sn.useRef(),l=Sn.useRef(),c=Sn.useRef(),d={},v={};Object.keys(o).forEach(function(T){Object.prototype.hasOwnProperty.call(fh.defaultOptions,T)?d[T]=o[T]:v[T]=o[T]});var p=Xo(Xo({},fh.defaultOptions.classNames),d.classNames),S=Xo(Xo({},i),{className:"".concat(p.contentWrapper).concat(i.className?" ".concat(i.className):""),tabIndex:0,role:"region","aria-label":d.ariaLabel||fh.defaultOptions.ariaLabel});return Sn.useEffect(function(){var T;return l.current=S.ref?S.ref.current:l.current,s.current&&(T=new fh(s.current,Xo(Xo(Xo({},d),l.current&&{scrollableNode:l.current}),c.current&&{contentNode:c.current})),typeof t=="function"?t(T):t&&(t.current=T)),function(){T==null||T.unMount(),T=null,typeof t=="function"&&t(null)}},[]),Sn.createElement("div",Xo({"data-simplebar":"init",ref:s},v),Sn.createElement("div",{className:p.wrapper},Sn.createElement("div",{className:p.heightAutoObserverWrapperEl},Sn.createElement("div",{className:p.heightAutoObserverEl})),Sn.createElement("div",{className:p.mask},Sn.createElement("div",{className:p.offset},typeof n=="function"?n({scrollableNodeRef:l,scrollableNodeProps:Xo(Xo({},S),{ref:l}),contentNodeRef:c,contentNodeProps:{className:p.contentEl,ref:c}}):Sn.createElement("div",Xo({},S),Sn.createElement("div",{className:p.contentEl},n)))),Sn.createElement("div",{className:p.placeholder})),Sn.createElement("div",{className:"".concat(p.track," simplebar-horizontal")},Sn.createElement("div",{className:p.scrollbar})),Sn.createElement("div",{className:"".concat(p.track," simplebar-vertical")},Sn.createElement("div",{className:p.scrollbar})))});fT.displayName="SimpleBar";const dT=`[data-simplebar]{position:relative;flex-direction:column;flex-wrap:wrap;justify-content:flex-start;align-content:flex-start;align-items:flex-start}.simplebar-wrapper{overflow:hidden;width:inherit;height:inherit;max-width:inherit;max-height:inherit}.simplebar-mask{direction:inherit;position:absolute;overflow:hidden;padding:0;margin:0;left:0;top:0;bottom:0;right:0;width:auto!important;height:auto!important;z-index:0}.simplebar-offset{direction:inherit!important;box-sizing:inherit!important;resize:none!important;position:absolute;top:0;left:0;bottom:0;right:0;padding:0;margin:0;-webkit-overflow-scrolling:touch}.simplebar-content-wrapper{direction:inherit;box-sizing:border-box!important;position:relative;display:block;height:100%;width:auto;max-width:100%;max-height:100%;overflow:auto;scrollbar-width:none;-ms-overflow-style:none}.simplebar-content-wrapper::-webkit-scrollbar,.simplebar-hide-scrollbar::-webkit-scrollbar{display:none;width:0;height:0}.simplebar-content:after,.simplebar-content:before{content:" ";display:table}.simplebar-placeholder{max-height:100%;max-width:100%;width:100%;pointer-events:none}.simplebar-height-auto-observer-wrapper{box-sizing:inherit!important;height:100%;width:100%;max-width:1px;position:relative;float:left;max-height:1px;overflow:hidden;z-index:-1;padding:0;margin:0;pointer-events:none;flex-grow:inherit;flex-shrink:0;flex-basis:0}.simplebar-height-auto-observer{box-sizing:inherit;display:block;opacity:0;position:absolute;top:0;left:0;height:1000%;width:1000%;min-height:1px;min-width:1px;overflow:hidden;pointer-events:none;z-index:-1}.simplebar-track{z-index:1;position:absolute;right:0;bottom:0;pointer-events:none;overflow:hidden}[data-simplebar].simplebar-dragging,[data-simplebar].simplebar-dragging .simplebar-content{pointer-events:none;-webkit-touch-callout:none;-webkit-user-select:none;-moz-user-select:none;user-select:none}[data-simplebar].simplebar-dragging .simplebar-track{pointer-events:all}.simplebar-scrollbar{position:absolute;left:0;right:0;min-height:10px}.simplebar-scrollbar:before{position:absolute;content:"";background:#000;border-radius:7px;left:2px;right:2px;opacity:0;transition:opacity .2s .5s linear}.simplebar-scrollbar.simplebar-visible:before{opacity:.5;transition-delay:0s;transition-duration:0s}.simplebar-track.simplebar-vertical{top:0;width:11px}.simplebar-scrollbar:before{top:2px;bottom:2px;left:2px;right:2px}.simplebar-track.simplebar-horizontal{left:0;height:11px}.simplebar-track.simplebar-horizontal .simplebar-scrollbar{right:auto;left:0;top:0;bottom:0;min-height:0;min-width:10px;width:auto}[data-simplebar-direction=rtl] .simplebar-track.simplebar-vertical{right:auto;left:0}.simplebar-dummy-scrollbar-size{direction:rtl;position:fixed;opacity:0;visibility:hidden;height:500px;width:500px;overflow-y:hidden;overflow-x:scroll;-ms-overflow-style:scrollbar!important}.simplebar-dummy-scrollbar-size>div{width:200%;height:200%;margin:10px 0}.simplebar-hide-scrollbar{position:fixed;left:0;visibility:hidden;overflow-y:scroll;scrollbar-width:none;-ms-overflow-style:none}
|
|
6
6
|
`;function hT(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var i=e.length;for(t=0;t<i;t++)e[t]&&(n=hT(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function Eu(){for(var e,t,n=0,r="",i=arguments.length;n<i;n++)(e=arguments[n])&&(t=hT(e))&&(r&&(r+=" "),r+=t);return r}const Ed=e=>typeof e=="number"&&!isNaN(e),Oc=e=>typeof e=="string",Zo=e=>typeof e=="function",$h=e=>Oc(e)||Zo(e)?e:null,Hv=e=>Q.isValidElement(e)||Oc(e)||Zo(e)||Ed(e);function yL(e,t,n){n===void 0&&(n=300);const{scrollHeight:r,style:i}=e;requestAnimationFrame(()=>{i.minHeight="initial",i.height=r+"px",i.transition=`all ${n}ms`,requestAnimationFrame(()=>{i.height="0",i.padding="0",i.margin="0",setTimeout(t,n)})})}function Pp(e){let{enter:t,exit:n,appendPosition:r=!1,collapse:i=!0,collapseDuration:o=300}=e;return function(s){let{children:l,position:c,preventExitTransition:d,done:v,nodeRef:p,isIn:S,playToast:T}=s;const _=r?`${t}--${c}`:t,R=r?`${n}--${c}`:n,L=Q.useRef(0);return Q.useLayoutEffect(()=>{const I=p.current,U=_.split(" "),z=re=>{re.target===p.current&&(T(),I.removeEventListener("animationend",z),I.removeEventListener("animationcancel",z),L.current===0&&re.type!=="animationcancel"&&I.classList.remove(...U))};I.classList.add(...U),I.addEventListener("animationend",z),I.addEventListener("animationcancel",z)},[]),Q.useEffect(()=>{const I=p.current,U=()=>{I.removeEventListener("animationend",U),i?yL(I,v,o):v()};S||(d?U():(L.current=1,I.className+=` ${R}`,I.addEventListener("animationend",U)))},[S]),Q.createElement(Q.Fragment,null,l)}}function W0(e,t){return e!=null?{content:e.content,containerId:e.props.containerId,id:e.props.toastId,theme:e.props.theme,type:e.props.type,data:e.props.data||{},isLoading:e.props.isLoading,icon:e.props.icon,status:t}:{}}const ao=new Map;let kd=[];const Uv=new Set,bL=e=>Uv.forEach(t=>t(e)),pT=()=>ao.size>0;function gT(e,t){var n;if(t)return!((n=ao.get(t))==null||!n.isToastActive(e));let r=!1;return ao.forEach(i=>{i.isToastActive(e)&&(r=!0)}),r}function vT(e,t){Hv(e)&&(pT()||kd.push({content:e,options:t}),ao.forEach(n=>{n.buildToast(e,t)}))}function z0(e,t){ao.forEach(n=>{t!=null&&t!=null&&t.containerId?(t==null?void 0:t.containerId)===n.id&&n.toggle(e,t==null?void 0:t.id):n.toggle(e,t==null?void 0:t.id)})}function wL(e){const{subscribe:t,getSnapshot:n,setProps:r}=Q.useRef(function(o){const s=o.containerId||1;return{subscribe(l){const c=function(v,p,S){let T=1,_=0,R=[],L=[],I=[],U=p;const z=new Map,re=new Set,Z=()=>{I=Array.from(z.values()),re.forEach(ce=>ce())},he=ce=>{L=ce==null?[]:L.filter(ae=>ae!==ce),Z()},x=ce=>{const{toastId:ae,onOpen:je,updateId:qe,children:We}=ce.props,rt=qe==null;ce.staleId&&z.delete(ce.staleId),z.set(ae,ce),L=[...L,ce.props.toastId].filter(nt=>nt!==ce.staleId),Z(),S(W0(ce,rt?"added":"updated")),rt&&Zo(je)&&je(Q.isValidElement(We)&&We.props)};return{id:v,props:U,observe:ce=>(re.add(ce),()=>re.delete(ce)),toggle:(ce,ae)=>{z.forEach(je=>{ae!=null&&ae!==je.props.toastId||Zo(je.toggle)&&je.toggle(ce)})},removeToast:he,toasts:z,clearQueue:()=>{_-=R.length,R=[]},buildToast:(ce,ae)=>{if((Ue=>{let{containerId:Ve,toastId:Re,updateId:Me}=Ue;const Xe=Ve?Ve!==v:v!==1,lt=z.has(Re)&&Me==null;return Xe||lt})(ae))return;const{toastId:je,updateId:qe,data:We,staleId:rt,delay:nt}=ae,ye=()=>{he(je)},De=qe==null;De&&_++;const He={...U,style:U.toastStyle,key:T++,...Object.fromEntries(Object.entries(ae).filter(Ue=>{let[Ve,Re]=Ue;return Re!=null})),toastId:je,updateId:qe,data:We,closeToast:ye,isIn:!1,className:$h(ae.className||U.toastClassName),bodyClassName:$h(ae.bodyClassName||U.bodyClassName),progressClassName:$h(ae.progressClassName||U.progressClassName),autoClose:!ae.isLoading&&(Je=ae.autoClose,at=U.autoClose,Je===!1||Ed(Je)&&Je>0?Je:at),deleteToast(){const Ue=z.get(je),{onClose:Ve,children:Re}=Ue.props;Zo(Ve)&&Ve(Q.isValidElement(Re)&&Re.props),S(W0(Ue,"removed")),z.delete(je),_--,_<0&&(_=0),R.length>0?x(R.shift()):Z()}};var Je,at;He.closeButton=U.closeButton,ae.closeButton===!1||Hv(ae.closeButton)?He.closeButton=ae.closeButton:ae.closeButton===!0&&(He.closeButton=!Hv(U.closeButton)||U.closeButton);let Oe=ce;Q.isValidElement(ce)&&!Oc(ce.type)?Oe=Q.cloneElement(ce,{closeToast:ye,toastProps:He,data:We}):Zo(ce)&&(Oe=ce({closeToast:ye,toastProps:He,data:We}));const xe={content:Oe,props:He,staleId:rt};U.limit&&U.limit>0&&_>U.limit&&De?R.push(xe):Ed(nt)?setTimeout(()=>{x(xe)},nt):x(xe)},setProps(ce){U=ce},setToggle:(ce,ae)=>{z.get(ce).toggle=ae},isToastActive:ce=>L.some(ae=>ae===ce),getSnapshot:()=>U.newestOnTop?I.reverse():I}}(s,o,bL);ao.set(s,c);const d=c.observe(l);return kd.forEach(v=>vT(v.content,v.options)),kd=[],()=>{d(),ao.delete(s)}},setProps(l){var c;(c=ao.get(s))==null||c.setProps(l)},getSnapshot(){var l;return(l=ao.get(s))==null?void 0:l.getSnapshot()}}}(e)).current;r(e);const i=Q.useSyncExternalStore(t,n,n);return{getToastToRender:function(o){if(!i)return[];const s=new Map;return i.forEach(l=>{const{position:c}=l.props;s.has(c)||s.set(c,[]),s.get(c).push(l)}),Array.from(s,l=>o(l[0],l[1]))},isToastActive:gT,count:i==null?void 0:i.length}}function xL(e){const[t,n]=Q.useState(!1),[r,i]=Q.useState(!1),o=Q.useRef(null),s=Q.useRef({start:0,delta:0,removalDistance:0,canCloseOnClick:!0,canDrag:!1,didMove:!1}).current,{autoClose:l,pauseOnHover:c,closeToast:d,onClick:v,closeOnClick:p}=e;var S,T;function _(){n(!0)}function R(){n(!1)}function L(z){const re=o.current;s.canDrag&&re&&(s.didMove=!0,t&&R(),s.delta=e.draggableDirection==="x"?z.clientX-s.start:z.clientY-s.start,s.start!==z.clientX&&(s.canCloseOnClick=!1),re.style.transform=`translate3d(${e.draggableDirection==="x"?`${s.delta}px, var(--y)`:`0, calc(${s.delta}px + var(--y))`},0)`,re.style.opacity=""+(1-Math.abs(s.delta/s.removalDistance)))}function I(){document.removeEventListener("pointermove",L),document.removeEventListener("pointerup",I);const z=o.current;if(s.canDrag&&s.didMove&&z){if(s.canDrag=!1,Math.abs(s.delta)>s.removalDistance)return i(!0),e.closeToast(),void e.collapseAll();z.style.transition="transform 0.2s, opacity 0.2s",z.style.removeProperty("transform"),z.style.removeProperty("opacity")}}(T=ao.get((S={id:e.toastId,containerId:e.containerId,fn:n}).containerId||1))==null||T.setToggle(S.id,S.fn),Q.useEffect(()=>{if(e.pauseOnFocusLoss)return document.hasFocus()||R(),window.addEventListener("focus",_),window.addEventListener("blur",R),()=>{window.removeEventListener("focus",_),window.removeEventListener("blur",R)}},[e.pauseOnFocusLoss]);const U={onPointerDown:function(z){if(e.draggable===!0||e.draggable===z.pointerType){s.didMove=!1,document.addEventListener("pointermove",L),document.addEventListener("pointerup",I);const re=o.current;s.canCloseOnClick=!0,s.canDrag=!0,re.style.transition="none",e.draggableDirection==="x"?(s.start=z.clientX,s.removalDistance=re.offsetWidth*(e.draggablePercent/100)):(s.start=z.clientY,s.removalDistance=re.offsetHeight*(e.draggablePercent===80?1.5*e.draggablePercent:e.draggablePercent)/100)}},onPointerUp:function(z){const{top:re,bottom:Z,left:he,right:x}=o.current.getBoundingClientRect();z.nativeEvent.type!=="touchend"&&e.pauseOnHover&&z.clientX>=he&&z.clientX<=x&&z.clientY>=re&&z.clientY<=Z?R():_()}};return l&&c&&(U.onMouseEnter=R,e.stacked||(U.onMouseLeave=_)),p&&(U.onClick=z=>{v&&v(z),s.canCloseOnClick&&d()}),{playToast:_,pauseToast:R,isRunning:t,preventExitTransition:r,toastRef:o,eventHandlers:U}}function SL(e){let{delay:t,isRunning:n,closeToast:r,type:i="default",hide:o,className:s,style:l,controlledProgress:c,progress:d,rtl:v,isIn:p,theme:S}=e;const T=o||c&&d===0,_={...l,animationDuration:`${t}ms`,animationPlayState:n?"running":"paused"};c&&(_.transform=`scaleX(${d})`);const R=Eu("Toastify__progress-bar",c?"Toastify__progress-bar--controlled":"Toastify__progress-bar--animated",`Toastify__progress-bar-theme--${S}`,`Toastify__progress-bar--${i}`,{"Toastify__progress-bar--rtl":v}),L=Zo(s)?s({rtl:v,type:i,defaultClassName:R}):Eu(R,s),I={[c&&d>=1?"onTransitionEnd":"onAnimationEnd"]:c&&d<1?null:()=>{p&&r()}};return Q.createElement("div",{className:"Toastify__progress-bar--wrp","data-hidden":T},Q.createElement("div",{className:`Toastify__progress-bar--bg Toastify__progress-bar-theme--${S} Toastify__progress-bar--${i}`}),Q.createElement("div",{role:"progressbar","aria-hidden":T?"true":"false","aria-label":"notification timer",className:L,style:_,...I}))}let TL=1;const mT=()=>""+TL++;function CL(e){return e&&(Oc(e.toastId)||Ed(e.toastId))?e.toastId:mT()}function sd(e,t){return vT(e,t),t.toastId}function ip(e,t){return{...t,type:t&&t.type||e,toastId:CL(t)}}function dh(e){return(t,n)=>sd(t,ip(e,n))}function En(e,t){return sd(e,ip("default",t))}En.loading=(e,t)=>sd(e,ip("default",{isLoading:!0,autoClose:!1,closeOnClick:!1,closeButton:!1,draggable:!1,...t})),En.promise=function(e,t,n){let r,{pending:i,error:o,success:s}=t;i&&(r=Oc(i)?En.loading(i,n):En.loading(i.render,{...n,...i}));const l={isLoading:null,autoClose:null,closeOnClick:null,closeButton:null,draggable:null},c=(v,p,S)=>{if(p==null)return void En.dismiss(r);const T={type:v,...l,...n,data:S},_=Oc(p)?{render:p}:p;return r?En.update(r,{...T,..._}):En(_.render,{...T,..._}),S},d=Zo(e)?e():e;return d.then(v=>c("success",s,v)).catch(v=>c("error",o,v)),d},En.success=dh("success"),En.info=dh("info"),En.error=dh("error"),En.warning=dh("warning"),En.warn=En.warning,En.dark=(e,t)=>sd(e,ip("default",{theme:"dark",...t})),En.dismiss=function(e){(function(t){var n;if(pT()){if(t==null||Oc(n=t)||Ed(n))ao.forEach(i=>{i.removeToast(t)});else if(t&&("containerId"in t||"id"in t)){var r;(r=ao.get(t.containerId))!=null&&r.removeToast(t.id)||ao.forEach(i=>{i.removeToast(t.id)})}}else kd=kd.filter(i=>t!=null&&i.options.toastId!==t)})(e)},En.clearWaitingQueue=function(e){e===void 0&&(e={}),ao.forEach(t=>{!t.props.limit||e.containerId&&t.id!==e.containerId||t.clearQueue()})},En.isActive=gT,En.update=function(e,t){t===void 0&&(t={});const n=((r,i)=>{var o;let{containerId:s}=i;return(o=ao.get(s||1))==null?void 0:o.toasts.get(r)})(e,t);if(n){const{props:r,content:i}=n,o={delay:100,...r,...t,toastId:t.toastId||e,updateId:mT()};o.toastId!==e&&(o.staleId=e);const s=o.render||i;delete o.render,sd(s,o)}},En.done=e=>{En.update(e,{progress:1})},En.onChange=function(e){return Uv.add(e),()=>{Uv.delete(e)}},En.play=e=>z0(!0,e),En.pause=e=>z0(!1,e);const EL=typeof window<"u"?Q.useLayoutEffect:Q.useEffect,hh=e=>{let{theme:t,type:n,isLoading:r,...i}=e;return Q.createElement("svg",{viewBox:"0 0 24 24",width:"100%",height:"100%",fill:t==="colored"?"currentColor":`var(--toastify-icon-color-${n})`,...i})},Fg={info:function(e){return Q.createElement(hh,{...e},Q.createElement("path",{d:"M12 0a12 12 0 1012 12A12.013 12.013 0 0012 0zm.25 5a1.5 1.5 0 11-1.5 1.5 1.5 1.5 0 011.5-1.5zm2.25 13.5h-4a1 1 0 010-2h.75a.25.25 0 00.25-.25v-4.5a.25.25 0 00-.25-.25h-.75a1 1 0 010-2h1a2 2 0 012 2v4.75a.25.25 0 00.25.25h.75a1 1 0 110 2z"}))},warning:function(e){return Q.createElement(hh,{...e},Q.createElement("path",{d:"M23.32 17.191L15.438 2.184C14.728.833 13.416 0 11.996 0c-1.42 0-2.733.833-3.443 2.184L.533 17.448a4.744 4.744 0 000 4.368C1.243 23.167 2.555 24 3.975 24h16.05C22.22 24 24 22.044 24 19.632c0-.904-.251-1.746-.68-2.44zm-9.622 1.46c0 1.033-.724 1.823-1.698 1.823s-1.698-.79-1.698-1.822v-.043c0-1.028.724-1.822 1.698-1.822s1.698.79 1.698 1.822v.043zm.039-12.285l-.84 8.06c-.057.581-.408.943-.897.943-.49 0-.84-.367-.896-.942l-.84-8.065c-.057-.624.25-1.095.779-1.095h1.91c.528.005.84.476.784 1.1z"}))},success:function(e){return Q.createElement(hh,{...e},Q.createElement("path",{d:"M12 0a12 12 0 1012 12A12.014 12.014 0 0012 0zm6.927 8.2l-6.845 9.289a1.011 1.011 0 01-1.43.188l-4.888-3.908a1 1 0 111.25-1.562l4.076 3.261 6.227-8.451a1 1 0 111.61 1.183z"}))},error:function(e){return Q.createElement(hh,{...e},Q.createElement("path",{d:"M11.983 0a12.206 12.206 0 00-8.51 3.653A11.8 11.8 0 000 12.207 11.779 11.779 0 0011.8 24h.214A12.111 12.111 0 0024 11.791 11.766 11.766 0 0011.983 0zM10.5 16.542a1.476 1.476 0 011.449-1.53h.027a1.527 1.527 0 011.523 1.47 1.475 1.475 0 01-1.449 1.53h-.027a1.529 1.529 0 01-1.523-1.47zM11 12.5v-6a1 1 0 012 0v6a1 1 0 11-2 0z"}))},spinner:function(){return Q.createElement("div",{className:"Toastify__spinner"})}},kL=e=>{const{isRunning:t,preventExitTransition:n,toastRef:r,eventHandlers:i,playToast:o}=xL(e),{closeButton:s,children:l,autoClose:c,onClick:d,type:v,hideProgressBar:p,closeToast:S,transition:T,position:_,className:R,style:L,bodyClassName:I,bodyStyle:U,progressClassName:z,progressStyle:re,updateId:Z,role:he,progress:x,rtl:ce,toastId:ae,deleteToast:je,isIn:qe,isLoading:We,closeOnClick:rt,theme:nt}=e,ye=Eu("Toastify__toast",`Toastify__toast-theme--${nt}`,`Toastify__toast--${v}`,{"Toastify__toast--rtl":ce},{"Toastify__toast--close-on-click":rt}),De=Zo(R)?R({rtl:ce,position:_,type:v,defaultClassName:ye}):Eu(ye,R),He=function(xe){let{theme:Ue,type:Ve,isLoading:Re,icon:Me}=xe,Xe=null;const lt={theme:Ue,type:Ve};return Me===!1||(Zo(Me)?Xe=Me({...lt,isLoading:Re}):Q.isValidElement(Me)?Xe=Q.cloneElement(Me,lt):Re?Xe=Fg.spinner():(mt=>mt in Fg)(Ve)&&(Xe=Fg[Ve](lt))),Xe}(e),Je=!!x||!c,at={closeToast:S,type:v,theme:nt};let Oe=null;return s===!1||(Oe=Zo(s)?s(at):Q.isValidElement(s)?Q.cloneElement(s,at):function(xe){let{closeToast:Ue,theme:Ve,ariaLabel:Re="close"}=xe;return Q.createElement("button",{className:`Toastify__close-button Toastify__close-button--${Ve}`,type:"button",onClick:Me=>{Me.stopPropagation(),Ue(Me)},"aria-label":Re},Q.createElement("svg",{"aria-hidden":"true",viewBox:"0 0 14 16"},Q.createElement("path",{fillRule:"evenodd",d:"M7.71 8.23l3.75 3.75-1.48 1.48-3.75-3.75-3.75 3.75L1 11.98l3.75-3.75L1 4.48 2.48 3l3.75 3.75L9.98 3l1.48 1.48-3.75 3.75z"})))}(at)),Q.createElement(T,{isIn:qe,done:je,position:_,preventExitTransition:n,nodeRef:r,playToast:o},Q.createElement("div",{id:ae,onClick:d,"data-in":qe,className:De,...i,style:L,ref:r},Q.createElement("div",{...qe&&{role:he},className:Zo(I)?I({type:v}):Eu("Toastify__toast-body",I),style:U},He!=null&&Q.createElement("div",{className:Eu("Toastify__toast-icon",{"Toastify--animate-icon Toastify__zoom-enter":!We})},He),Q.createElement("div",null,l)),Oe,Q.createElement(SL,{...Z&&!Je?{key:`pb-${Z}`}:{},rtl:ce,theme:nt,delay:c,isRunning:t,isIn:qe,closeToast:S,hide:p,type:v,style:re,className:z,controlledProgress:Je,progress:x||0})))},_p=function(e,t){return t===void 0&&(t=!1),{enter:`Toastify--animate Toastify__${e}-enter`,exit:`Toastify--animate Toastify__${e}-exit`,appendPosition:t}},OL=Pp(_p("bounce",!0));Pp(_p("slide",!0));Pp(_p("zoom"));Pp(_p("flip"));const DL={position:"top-right",transition:OL,autoClose:5e3,closeButton:!0,pauseOnHover:!0,pauseOnFocusLoss:!0,draggable:"touch",draggablePercent:80,draggableDirection:"x",role:"alert",theme:"light"};function PL(e){let t={...DL,...e};const n=e.stacked,[r,i]=Q.useState(!0),o=Q.useRef(null),{getToastToRender:s,isToastActive:l,count:c}=wL(t),{className:d,style:v,rtl:p,containerId:S}=t;function T(R){const L=Eu("Toastify__toast-container",`Toastify__toast-container--${R}`,{"Toastify__toast-container--rtl":p});return Zo(d)?d({position:R,rtl:p,defaultClassName:L}):Eu(L,$h(d))}function _(){n&&(i(!0),En.play())}return EL(()=>{if(n){var R;const L=o.current.querySelectorAll('[data-in="true"]'),I=12,U=(R=t.position)==null?void 0:R.includes("top");let z=0,re=0;Array.from(L).reverse().forEach((Z,he)=>{const x=Z;x.classList.add("Toastify__toast--stacked"),he>0&&(x.dataset.collapsed=`${r}`),x.dataset.pos||(x.dataset.pos=U?"top":"bot");const ce=z*(r?.2:1)+(r?0:I*he);x.style.setProperty("--y",`${U?ce:-1*ce}px`),x.style.setProperty("--g",`${I}`),x.style.setProperty("--s",""+(1-(r?re:0))),z+=x.offsetHeight,re+=.025})}},[r,c,n]),Q.createElement("div",{ref:o,className:"Toastify",id:S,onMouseEnter:()=>{n&&(i(!1),En.pause())},onMouseLeave:_},s((R,L)=>{const I=L.length?{...v}:{...v,pointerEvents:"none"};return Q.createElement("div",{className:T(R),style:I,key:`container-${R}`},L.map(U=>{let{content:z,props:re}=U;return Q.createElement(kL,{...re,stacked:n,collapseAll:_,isIn:l(re.toastId,re.containerId),style:re.style,key:`toast-${re.key}`},z)}))}))}function _L(){return st.jsxs("svg",{width:"22",height:"22",viewBox:"0 0 22 22",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[st.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M11 1C16.5222 1 21 5.47676 21 11C21 16.5222 16.5222 21 11 21C5.47676 21 1 16.5222 1 11C1 5.47676 5.47676 1 11 1Z",stroke:"#E01B00",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"}),st.jsx("path",{d:"M10.9942 6.89636V11.6737",stroke:"#E01B00",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"}),st.jsx("path",{d:"M10.9941 15.1038H11.0049",stroke:"#E01B00",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"})]})}function RL(){return st.jsxs("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[st.jsx("rect",{width:"24",height:"24",rx:"12",fill:"#009D4F"}),st.jsx("path",{d:"M7.25244 12L10.4174 15.165L16.7474 8.83496",stroke:"white",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"})]})}function IL(){return st.jsxs("svg",{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[st.jsx("path",{d:"M12 7.73684V13.4211M12 21C7.69215 21 5.53823 21 4.29308 20.0953C3.20701 19.3063 2.50676 18.0934 2.36643 16.7583C2.20555 15.2276 3.28252 13.3623 5.43644 9.63158C7.59036 5.90088 8.66732 4.03553 10.0734 3.40952C11.2998 2.86349 12.7002 2.86349 13.9266 3.40952C15.3327 4.03553 16.4096 5.90088 18.5636 9.63158C20.7175 13.3623 21.7944 15.2276 21.6336 16.7583C21.4932 18.0934 20.793 19.3063 19.7069 20.0953C18.4618 21 16.3078 21 12 21Z",stroke:"#FFB600","stroke-width":"1.5","stroke-linecap":"round"}),st.jsx("path",{d:"M12.9473 16.263C12.9473 16.7863 12.5232 17.2104 12 17.2104C11.4768 17.2104 11.0526 16.7863 11.0526 16.263C11.0526 15.7398 11.4768 15.3157 12 15.3157C12.5232 15.3157 12.9473 15.7398 12.9473 16.263Z",fill:"#FFB600"})]})}const Gm={paddingLeft:"16px",borderLeft:"2px solid",boxShadow:"none",fontFamily:"inherit"},AL=({closeToast:e})=>st.jsx("i",{className:"material-icons",onClick:e,style:{cursor:"pointer"},children:st.jsx("svg",{width:"24",height:"25",viewBox:"0 0 24 25",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:st.jsx("path",{d:"M7.05086 6.13616C6.66033 5.74563 6.02717 5.74563 5.63664 6.13616C5.24612 6.52668 5.24612 7.15984 5.63664 7.55037L10.5864 12.5001L5.63664 17.4499C5.24612 17.8404 5.24612 18.4736 5.63664 18.8641C6.02717 19.2546 6.66033 19.2546 7.05086 18.8641L12.0006 13.9143L16.9504 18.8641C17.3409 19.2546 17.974 19.2546 18.3646 18.8641C18.7551 18.4736 18.7551 17.8404 18.3646 17.4499L13.4148 12.5001L18.3646 7.55037C18.7551 7.15984 18.7551 6.52668 18.3646 6.13616C17.974 5.74563 17.3409 5.74563 16.9504 6.13616L12.0006 11.0859L7.05086 6.13616Z",fill:"#85858A"})})}),yT=e=>{En.success(e,{icon:st.jsx(RL,{}),bodyStyle:{},position:"bottom-right",style:{...Gm,background:so.successLight,borderColor:so.success,color:so.success}})},Rp=e=>{En.error(e,{icon:st.jsx(_L,{}),position:"bottom-right",style:{...Gm,background:so.dangerLight,borderColor:so.danger,color:so.danger}})},ML=e=>{En.error(e,{icon:st.jsx(IL,{}),position:"bottom-right",style:{...Gm,background:so.warningLight,borderColor:so.warning,color:so.warning}})},LL=e=>{En(e,{closeButton:AL,toastId:"notify",position:"top-right",hideProgressBar:!0,containerId:"toastifyNotification",style:{width:"610px",minHeight:"72px",padding:"12px 24px 12px 0",color:so.textPrimary}})},bT=Q.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"}),Ip=Q.createContext({}),qm=Q.createContext(null),Ap=typeof document<"u",NL=Ap?Q.useLayoutEffect:Q.useEffect,wT=Q.createContext({strict:!1}),Xm=e=>e.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase(),FL="framerAppearId",xT="data-"+Xm(FL);function jL(e,t,n,r){const{visualElement:i}=Q.useContext(Ip),o=Q.useContext(wT),s=Q.useContext(qm),l=Q.useContext(bT).reducedMotion,c=Q.useRef();r=r||o.renderer,!c.current&&r&&(c.current=r(e,{visualState:t,parent:i,props:n,presenceContext:s,blockInitialAnimation:s?s.initial===!1:!1,reducedMotionConfig:l}));const d=c.current;Q.useInsertionEffect(()=>{d&&d.update(n,s)});const v=Q.useRef(!!(n[xT]&&!window.HandoffComplete));return NL(()=>{d&&(d.render(),v.current&&d.animationState&&d.animationState.animateChanges())}),Q.useEffect(()=>{d&&(d.updateFeatures(),!v.current&&d.animationState&&d.animationState.animateChanges(),v.current&&(v.current=!1,window.HandoffComplete=!0))}),d}function xf(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function BL(e,t,n){return Q.useCallback(r=>{r&&e.mount&&e.mount(r),t&&(r?t.mount(r):t.unmount()),n&&(typeof n=="function"?n(r):xf(n)&&(n.current=r))},[t])}function Od(e){return typeof e=="string"||Array.isArray(e)}function Mp(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}const Km=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],Zm=["initial",...Km];function Lp(e){return Mp(e.animate)||Zm.some(t=>Od(e[t]))}function ST(e){return!!(Lp(e)||e.variants)}function $L(e,t){if(Lp(e)){const{initial:n,animate:r}=e;return{initial:n===!1||Od(n)?n:void 0,animate:Od(r)?r:void 0}}return e.inherit!==!1?t:{}}function VL(e){const{initial:t,animate:n}=$L(e,Q.useContext(Ip));return Q.useMemo(()=>({initial:t,animate:n}),[Y0(t),Y0(n)])}function Y0(e){return Array.isArray(e)?e.join(" "):e}const G0={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]},Dd={};for(const e in G0)Dd[e]={isEnabled:t=>G0[e].some(n=>!!t[n])};function HL(e){for(const t in e)Dd[t]={...Dd[t],...e[t]}}const TT=Q.createContext({}),CT=Q.createContext({}),UL=Symbol.for("motionComponentSymbol");function WL({preloadedFeatures:e,createVisualElement:t,useRender:n,useVisualState:r,Component:i}){e&&HL(e);function o(l,c){let d;const v={...Q.useContext(bT),...l,layoutId:zL(l)},{isStatic:p}=v,S=VL(l),T=r(l,p);if(!p&&Ap){S.visualElement=jL(i,T,v,t);const _=Q.useContext(CT),R=Q.useContext(wT).strict;S.visualElement&&(d=S.visualElement.loadFeatures(v,R,e,_))}return Sn.createElement(Ip.Provider,{value:S},d&&S.visualElement?Sn.createElement(d,{visualElement:S.visualElement,...v}):null,n(i,l,BL(T,S.visualElement,c),T,p,S.visualElement))}const s=Q.forwardRef(o);return s[UL]=i,s}function zL({layoutId:e}){const t=Q.useContext(TT).id;return t&&e!==void 0?t+"-"+e:e}function YL(e){function t(r,i={}){return WL(e(r,i))}if(typeof Proxy>"u")return t;const n=new Map;return new Proxy(t,{get:(r,i)=>(n.has(i)||n.set(i,t(i)),n.get(i))})}const GL=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function Jm(e){return typeof e!="string"||e.includes("-")?!1:!!(GL.indexOf(e)>-1||/[A-Z]/.test(e))}const op={};function qL(e){Object.assign(op,e)}const $d=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],$c=new Set($d);function ET(e,{layout:t,layoutId:n}){return $c.has(e)||e.startsWith("origin")||(t||n!==void 0)&&(!!op[e]||e==="opacity")}const Do=e=>!!(e&&e.getVelocity),XL={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},KL=$d.length;function ZL(e,{enableHardwareAcceleration:t=!0,allowTransformNone:n=!0},r,i){let o="";for(let s=0;s<KL;s++){const l=$d[s];if(e[l]!==void 0){const c=XL[l]||l;o+=`${c}(${e[l]}) `}}return t&&!e.z&&(o+="translateZ(0)"),o=o.trim(),i?o=i(e,r?"":o):n&&r&&(o="none"),o}const kT=e=>t=>typeof t=="string"&&t.startsWith(e),OT=kT("--"),Wv=kT("var(--"),JL=/var\s*\(\s*--[\w-]+(\s*,\s*(?:(?:[^)(]|\((?:[^)(]+|\([^)(]*\))*\))*)+)?\s*\)/g,QL=(e,t)=>t&&typeof e=="number"?t.transform(e):e,Dl=(e,t,n)=>Math.min(Math.max(n,e),t),Vc={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},ud={...Vc,transform:e=>Dl(0,1,e)},ph={...Vc,default:1},ld=e=>Math.round(e*1e5)/1e5,Np=/(-)?([\d]*\.?[\d])+/g,DT=/(#[0-9a-f]{3,8}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2}(-?[\d\.]+%?)\s*[\,\/]?\s*[\d\.]*%?\))/gi,e2=/^(#[0-9a-f]{3,8}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2}(-?[\d\.]+%?)\s*[\,\/]?\s*[\d\.]*%?\))$/i;function Vd(e){return typeof e=="string"}const Hd=e=>({test:t=>Vd(t)&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),pl=Hd("deg"),Ns=Hd("%"),jt=Hd("px"),t2=Hd("vh"),n2=Hd("vw"),q0={...Ns,parse:e=>Ns.parse(e)/100,transform:e=>Ns.transform(e*100)},X0={...Vc,transform:Math.round},PT={borderWidth:jt,borderTopWidth:jt,borderRightWidth:jt,borderBottomWidth:jt,borderLeftWidth:jt,borderRadius:jt,radius:jt,borderTopLeftRadius:jt,borderTopRightRadius:jt,borderBottomRightRadius:jt,borderBottomLeftRadius:jt,width:jt,maxWidth:jt,height:jt,maxHeight:jt,size:jt,top:jt,right:jt,bottom:jt,left:jt,padding:jt,paddingTop:jt,paddingRight:jt,paddingBottom:jt,paddingLeft:jt,margin:jt,marginTop:jt,marginRight:jt,marginBottom:jt,marginLeft:jt,rotate:pl,rotateX:pl,rotateY:pl,rotateZ:pl,scale:ph,scaleX:ph,scaleY:ph,scaleZ:ph,skew:pl,skewX:pl,skewY:pl,distance:jt,translateX:jt,translateY:jt,translateZ:jt,x:jt,y:jt,z:jt,perspective:jt,transformPerspective:jt,opacity:ud,originX:q0,originY:q0,originZ:jt,zIndex:X0,fillOpacity:ud,strokeOpacity:ud,numOctaves:X0};function Qm(e,t,n,r){const{style:i,vars:o,transform:s,transformOrigin:l}=e;let c=!1,d=!1,v=!0;for(const p in t){const S=t[p];if(OT(p)){o[p]=S;continue}const T=PT[p],_=QL(S,T);if($c.has(p)){if(c=!0,s[p]=_,!v)continue;S!==(T.default||0)&&(v=!1)}else p.startsWith("origin")?(d=!0,l[p]=_):i[p]=_}if(t.transform||(c||r?i.transform=ZL(e.transform,n,v,r):i.transform&&(i.transform="none")),d){const{originX:p="50%",originY:S="50%",originZ:T=0}=l;i.transformOrigin=`${p} ${S} ${T}`}}const ey=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function _T(e,t,n){for(const r in t)!Do(t[r])&&!ET(r,n)&&(e[r]=t[r])}function r2({transformTemplate:e},t,n){return Q.useMemo(()=>{const r=ey();return Qm(r,t,{enableHardwareAcceleration:!n},e),Object.assign({},r.vars,r.style)},[t])}function i2(e,t,n){const r=e.style||{},i={};return _T(i,r,e),Object.assign(i,r2(e,t,n)),e.transformValues?e.transformValues(i):i}function o2(e,t,n){const r={},i=i2(e,t,n);return e.drag&&e.dragListener!==!1&&(r.draggable=!1,i.userSelect=i.WebkitUserSelect=i.WebkitTouchCallout="none",i.touchAction=e.drag===!0?"none":`pan-${e.drag==="x"?"y":"x"}`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(r.tabIndex=0),r.style=i,r}const a2=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","transformValues","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function ap(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||a2.has(e)}let RT=e=>!ap(e);function s2(e){e&&(RT=t=>t.startsWith("on")?!ap(t):e(t))}try{s2(require("@emotion/is-prop-valid").default)}catch{}function u2(e,t,n){const r={};for(const i in e)i==="values"&&typeof e.values=="object"||(RT(i)||n===!0&&ap(i)||!t&&!ap(i)||e.draggable&&i.startsWith("onDrag"))&&(r[i]=e[i]);return r}function K0(e,t,n){return typeof e=="string"?e:jt.transform(t+n*e)}function l2(e,t,n){const r=K0(t,e.x,e.width),i=K0(n,e.y,e.height);return`${r} ${i}`}const c2={offset:"stroke-dashoffset",array:"stroke-dasharray"},f2={offset:"strokeDashoffset",array:"strokeDasharray"};function d2(e,t,n=1,r=0,i=!0){e.pathLength=1;const o=i?c2:f2;e[o.offset]=jt.transform(-r);const s=jt.transform(t),l=jt.transform(n);e[o.array]=`${s} ${l}`}function ty(e,{attrX:t,attrY:n,attrScale:r,originX:i,originY:o,pathLength:s,pathSpacing:l=1,pathOffset:c=0,...d},v,p,S){if(Qm(e,d,v,S),p){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};const{attrs:T,style:_,dimensions:R}=e;T.transform&&(R&&(_.transform=T.transform),delete T.transform),R&&(i!==void 0||o!==void 0||_.transform)&&(_.transformOrigin=l2(R,i!==void 0?i:.5,o!==void 0?o:.5)),t!==void 0&&(T.x=t),n!==void 0&&(T.y=n),r!==void 0&&(T.scale=r),s!==void 0&&d2(T,s,l,c,!1)}const IT=()=>({...ey(),attrs:{}}),ny=e=>typeof e=="string"&&e.toLowerCase()==="svg";function h2(e,t,n,r){const i=Q.useMemo(()=>{const o=IT();return ty(o,t,{enableHardwareAcceleration:!1},ny(r),e.transformTemplate),{...o.attrs,style:{...o.style}}},[t]);if(e.style){const o={};_T(o,e.style,e),i.style={...o,...i.style}}return i}function p2(e=!1){return(n,r,i,{latestValues:o},s)=>{const c=(Jm(n)?h2:o2)(r,o,s,n),v={...u2(r,typeof n=="string",e),...c,ref:i},{children:p}=r,S=Q.useMemo(()=>Do(p)?p.get():p,[p]);return Q.createElement(n,{...v,children:S})}}function AT(e,{style:t,vars:n},r,i){Object.assign(e.style,t,i&&i.getProjectionStyles(r));for(const o in n)e.style.setProperty(o,n[o])}const MT=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]);function LT(e,t,n,r){AT(e,t,void 0,r);for(const i in t.attrs)e.setAttribute(MT.has(i)?i:Xm(i),t.attrs[i])}function ry(e,t){const{style:n}=e,r={};for(const i in n)(Do(n[i])||t.style&&Do(t.style[i])||ET(i,e))&&(r[i]=n[i]);return r}function NT(e,t){const n=ry(e,t);for(const r in e)if(Do(e[r])||Do(t[r])){const i=$d.indexOf(r)!==-1?"attr"+r.charAt(0).toUpperCase()+r.substring(1):r;n[i]=e[r]}return n}function iy(e,t,n,r={},i={}){return typeof t=="function"&&(t=t(n!==void 0?n:e.custom,r,i)),typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"&&(t=t(n!==void 0?n:e.custom,r,i)),t}function g2(e){const t=Q.useRef(null);return t.current===null&&(t.current=e()),t.current}const sp=e=>Array.isArray(e),v2=e=>!!(e&&typeof e=="object"&&e.mix&&e.toValue),m2=e=>sp(e)?e[e.length-1]||0:e;function Vh(e){const t=Do(e)?e.get():e;return v2(t)?t.toValue():t}function y2({scrapeMotionValuesFromProps:e,createRenderState:t,onMount:n},r,i,o){const s={latestValues:b2(r,i,o,e),renderState:t()};return n&&(s.mount=l=>n(r,l,s)),s}const FT=e=>(t,n)=>{const r=Q.useContext(Ip),i=Q.useContext(qm),o=()=>y2(e,t,r,i);return n?o():g2(o)};function b2(e,t,n,r){const i={},o=r(e,{});for(const S in o)i[S]=Vh(o[S]);let{initial:s,animate:l}=e;const c=Lp(e),d=ST(e);t&&d&&!c&&e.inherit!==!1&&(s===void 0&&(s=t.initial),l===void 0&&(l=t.animate));let v=n?n.initial===!1:!1;v=v||s===!1;const p=v?l:s;return p&&typeof p!="boolean"&&!Mp(p)&&(Array.isArray(p)?p:[p]).forEach(T=>{const _=iy(e,T);if(!_)return;const{transitionEnd:R,transition:L,...I}=_;for(const U in I){let z=I[U];if(Array.isArray(z)){const re=v?z.length-1:0;z=z[re]}z!==null&&(i[U]=z)}for(const U in R)i[U]=R[U]}),i}const lr=e=>e;class Z0{constructor(){this.order=[],this.scheduled=new Set}add(t){if(!this.scheduled.has(t))return this.scheduled.add(t),this.order.push(t),!0}remove(t){const n=this.order.indexOf(t);n!==-1&&(this.order.splice(n,1),this.scheduled.delete(t))}clear(){this.order.length=0,this.scheduled.clear()}}function w2(e){let t=new Z0,n=new Z0,r=0,i=!1,o=!1;const s=new WeakSet,l={schedule:(c,d=!1,v=!1)=>{const p=v&&i,S=p?t:n;return d&&s.add(c),S.add(c)&&p&&i&&(r=t.order.length),c},cancel:c=>{n.remove(c),s.delete(c)},process:c=>{if(i){o=!0;return}if(i=!0,[t,n]=[n,t],n.clear(),r=t.order.length,r)for(let d=0;d<r;d++){const v=t.order[d];v(c),s.has(v)&&(l.schedule(v),e())}i=!1,o&&(o=!1,l.process(c))}};return l}const gh=["prepare","read","update","preRender","render","postRender"],x2=40;function S2(e,t){let n=!1,r=!0;const i={delta:0,timestamp:0,isProcessing:!1},o=gh.reduce((p,S)=>(p[S]=w2(()=>n=!0),p),{}),s=p=>o[p].process(i),l=()=>{const p=performance.now();n=!1,i.delta=r?1e3/60:Math.max(Math.min(p-i.timestamp,x2),1),i.timestamp=p,i.isProcessing=!0,gh.forEach(s),i.isProcessing=!1,n&&t&&(r=!1,e(l))},c=()=>{n=!0,r=!0,i.isProcessing||e(l)};return{schedule:gh.reduce((p,S)=>{const T=o[S];return p[S]=(_,R=!1,L=!1)=>(n||c(),T.schedule(_,R,L)),p},{}),cancel:p=>gh.forEach(S=>o[S].cancel(p)),state:i,steps:o}}const{schedule:Hn,cancel:Iu,state:Li,steps:jg}=S2(typeof requestAnimationFrame<"u"?requestAnimationFrame:lr,!0),T2={useVisualState:FT({scrapeMotionValuesFromProps:NT,createRenderState:IT,onMount:(e,t,{renderState:n,latestValues:r})=>{Hn.read(()=>{try{n.dimensions=typeof t.getBBox=="function"?t.getBBox():t.getBoundingClientRect()}catch{n.dimensions={x:0,y:0,width:0,height:0}}}),Hn.render(()=>{ty(n,r,{enableHardwareAcceleration:!1},ny(t.tagName),e.transformTemplate),LT(t,n)})}})},C2={useVisualState:FT({scrapeMotionValuesFromProps:ry,createRenderState:ey})};function E2(e,{forwardMotionProps:t=!1},n,r){return{...Jm(e)?T2:C2,preloadedFeatures:n,useRender:p2(t),createVisualElement:r,Component:e}}function ku(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n)}const jT=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1;function Fp(e,t="page"){return{point:{x:e[t+"X"],y:e[t+"Y"]}}}const k2=e=>t=>jT(t)&&e(t,Fp(t));function Pu(e,t,n,r){return ku(e,t,k2(n),r)}const O2=(e,t)=>n=>t(e(n)),Sl=(...e)=>e.reduce(O2);function BT(e){let t=null;return()=>{const n=()=>{t=null};return t===null?(t=e,n):!1}}const J0=BT("dragHorizontal"),Q0=BT("dragVertical");function $T(e){let t=!1;if(e==="y")t=Q0();else if(e==="x")t=J0();else{const n=J0(),r=Q0();n&&r?t=()=>{n(),r()}:(n&&n(),r&&r())}return t}function VT(){const e=$T(!0);return e?(e(),!1):!0}class Il{constructor(t){this.isMounted=!1,this.node=t}update(){}}function ew(e,t){const n="pointer"+(t?"enter":"leave"),r="onHover"+(t?"Start":"End"),i=(o,s)=>{if(o.pointerType==="touch"||VT())return;const l=e.getProps();e.animationState&&l.whileHover&&e.animationState.setActive("whileHover",t),l[r]&&Hn.update(()=>l[r](o,s))};return Pu(e.current,n,i,{passive:!e.getProps()[r]})}class D2 extends Il{mount(){this.unmount=Sl(ew(this.node,!0),ew(this.node,!1))}unmount(){}}class P2 extends Il{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch{t=!0}!t||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=Sl(ku(this.node.current,"focus",()=>this.onFocus()),ku(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}const HT=(e,t)=>t?e===t?!0:HT(e,t.parentElement):!1;function Bg(e,t){if(!t)return;const n=new PointerEvent("pointer"+e);t(n,Fp(n))}class _2 extends Il{constructor(){super(...arguments),this.removeStartListeners=lr,this.removeEndListeners=lr,this.removeAccessibleListeners=lr,this.startPointerPress=(t,n)=>{if(this.isPressing)return;this.removeEndListeners();const r=this.node.getProps(),o=Pu(window,"pointerup",(l,c)=>{if(!this.checkPressEnd())return;const{onTap:d,onTapCancel:v,globalTapTarget:p}=this.node.getProps();Hn.update(()=>{!p&&!HT(this.node.current,l.target)?v&&v(l,c):d&&d(l,c)})},{passive:!(r.onTap||r.onPointerUp)}),s=Pu(window,"pointercancel",(l,c)=>this.cancelPress(l,c),{passive:!(r.onTapCancel||r.onPointerCancel)});this.removeEndListeners=Sl(o,s),this.startPress(t,n)},this.startAccessiblePress=()=>{const t=o=>{if(o.key!=="Enter"||this.isPressing)return;const s=l=>{l.key!=="Enter"||!this.checkPressEnd()||Bg("up",(c,d)=>{const{onTap:v}=this.node.getProps();v&&Hn.update(()=>v(c,d))})};this.removeEndListeners(),this.removeEndListeners=ku(this.node.current,"keyup",s),Bg("down",(l,c)=>{this.startPress(l,c)})},n=ku(this.node.current,"keydown",t),r=()=>{this.isPressing&&Bg("cancel",(o,s)=>this.cancelPress(o,s))},i=ku(this.node.current,"blur",r);this.removeAccessibleListeners=Sl(n,i)}}startPress(t,n){this.isPressing=!0;const{onTapStart:r,whileTap:i}=this.node.getProps();i&&this.node.animationState&&this.node.animationState.setActive("whileTap",!0),r&&Hn.update(()=>r(t,n))}checkPressEnd(){return this.removeEndListeners(),this.isPressing=!1,this.node.getProps().whileTap&&this.node.animationState&&this.node.animationState.setActive("whileTap",!1),!VT()}cancelPress(t,n){if(!this.checkPressEnd())return;const{onTapCancel:r}=this.node.getProps();r&&Hn.update(()=>r(t,n))}mount(){const t=this.node.getProps(),n=Pu(t.globalTapTarget?window:this.node.current,"pointerdown",this.startPointerPress,{passive:!(t.onTapStart||t.onPointerStart)}),r=ku(this.node.current,"focus",this.startAccessiblePress);this.removeStartListeners=Sl(n,r)}unmount(){this.removeStartListeners(),this.removeEndListeners(),this.removeAccessibleListeners()}}const zv=new WeakMap,$g=new WeakMap,R2=e=>{const t=zv.get(e.target);t&&t(e)},I2=e=>{e.forEach(R2)};function A2({root:e,...t}){const n=e||document;$g.has(n)||$g.set(n,{});const r=$g.get(n),i=JSON.stringify(t);return r[i]||(r[i]=new IntersectionObserver(I2,{root:e,...t})),r[i]}function M2(e,t,n){const r=A2(t);return zv.set(e,n),r.observe(e),()=>{zv.delete(e),r.unobserve(e)}}const L2={some:0,all:1};class N2 extends Il{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:t={}}=this.node.getProps(),{root:n,margin:r,amount:i="some",once:o}=t,s={root:n?n.current:void 0,rootMargin:r,threshold:typeof i=="number"?i:L2[i]},l=c=>{const{isIntersecting:d}=c;if(this.isInView===d||(this.isInView=d,o&&!d&&this.hasEnteredView))return;d&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",d);const{onViewportEnter:v,onViewportLeave:p}=this.node.getProps(),S=d?v:p;S&&S(c)};return M2(this.node.current,s,l)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:t,prevProps:n}=this.node;["amount","margin","root"].some(F2(t,n))&&this.startObserver()}unmount(){}}function F2({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}const j2={inView:{Feature:N2},tap:{Feature:_2},focus:{Feature:P2},hover:{Feature:D2}};function UT(e,t){if(!Array.isArray(t))return!1;const n=t.length;if(n!==e.length)return!1;for(let r=0;r<n;r++)if(t[r]!==e[r])return!1;return!0}function B2(e){const t={};return e.values.forEach((n,r)=>t[r]=n.get()),t}function $2(e){const t={};return e.values.forEach((n,r)=>t[r]=n.getVelocity()),t}function jp(e,t,n){const r=e.getProps();return iy(r,t,n!==void 0?n:r.custom,B2(e),$2(e))}let Ud=lr,is=lr;process.env.NODE_ENV!=="production"&&(Ud=(e,t)=>{!e&&typeof console<"u"&&console.warn(t)},is=(e,t)=>{if(!e)throw new Error(t)});const Tl=e=>e*1e3,_u=e=>e/1e3,V2={current:!1},WT=e=>Array.isArray(e)&&typeof e[0]=="number";function zT(e){return!!(!e||typeof e=="string"&&YT[e]||WT(e)||Array.isArray(e)&&e.every(zT))}const ad=([e,t,n,r])=>`cubic-bezier(${e}, ${t}, ${n}, ${r})`,YT={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:ad([0,.65,.55,1]),circOut:ad([.55,0,1,.45]),backIn:ad([.31,.01,.66,-.59]),backOut:ad([.33,1.53,.69,.99])};function GT(e){if(e)return WT(e)?ad(e):Array.isArray(e)?e.map(GT):YT[e]}function H2(e,t,n,{delay:r=0,duration:i,repeat:o=0,repeatType:s="loop",ease:l,times:c}={}){const d={[t]:n};c&&(d.offset=c);const v=GT(l);return Array.isArray(v)&&(d.easing=v),e.animate(d,{delay:r,duration:i,easing:Array.isArray(v)?"linear":v,fill:"both",iterations:o+1,direction:s==="reverse"?"alternate":"normal"})}function U2(e,{repeat:t,repeatType:n="loop"}){const r=t&&n!=="loop"&&t%2===1?0:e.length-1;return e[r]}const qT=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e,W2=1e-7,z2=12;function Y2(e,t,n,r,i){let o,s,l=0;do s=t+(n-t)/2,o=qT(s,r,i)-e,o>0?n=s:t=s;while(Math.abs(o)>W2&&++l<z2);return s}function Wd(e,t,n,r){if(e===t&&n===r)return lr;const i=o=>Y2(o,0,1,e,n);return o=>o===0||o===1?o:qT(i(o),t,r)}const G2=Wd(.42,0,1,1),q2=Wd(0,0,.58,1),XT=Wd(.42,0,.58,1),X2=e=>Array.isArray(e)&&typeof e[0]!="number",KT=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,ZT=e=>t=>1-e(1-t),oy=e=>1-Math.sin(Math.acos(e)),JT=ZT(oy),K2=KT(oy),QT=Wd(.33,1.53,.69,.99),ay=ZT(QT),Z2=KT(ay),J2=e=>(e*=2)<1?.5*ay(e):.5*(2-Math.pow(2,-10*(e-1))),tw={linear:lr,easeIn:G2,easeInOut:XT,easeOut:q2,circIn:oy,circInOut:K2,circOut:JT,backIn:ay,backInOut:Z2,backOut:QT,anticipate:J2},nw=e=>{if(Array.isArray(e)){is(e.length===4,"Cubic bezier arrays must contain four numerical values.");const[t,n,r,i]=e;return Wd(t,n,r,i)}else if(typeof e=="string")return is(tw[e]!==void 0,`Invalid easing type '${e}'`),tw[e];return e},sy=(e,t)=>n=>!!(Vd(n)&&e2.test(n)&&n.startsWith(e)||t&&Object.prototype.hasOwnProperty.call(n,t)),eC=(e,t,n)=>r=>{if(!Vd(r))return r;const[i,o,s,l]=r.match(Np);return{[e]:parseFloat(i),[t]:parseFloat(o),[n]:parseFloat(s),alpha:l!==void 0?parseFloat(l):1}},Q2=e=>Dl(0,255,e),Vg={...Vc,transform:e=>Math.round(Q2(e))},Cc={test:sy("rgb","red"),parse:eC("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:r=1})=>"rgba("+Vg.transform(e)+", "+Vg.transform(t)+", "+Vg.transform(n)+", "+ld(ud.transform(r))+")"};function eN(e){let t="",n="",r="",i="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),r=e.substring(5,7),i=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),r=e.substring(3,4),i=e.substring(4,5),t+=t,n+=n,r+=r,i+=i),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:i?parseInt(i,16)/255:1}}const Yv={test:sy("#"),parse:eN,transform:Cc.transform},Sf={test:sy("hsl","hue"),parse:eC("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>"hsla("+Math.round(e)+", "+Ns.transform(ld(t))+", "+Ns.transform(ld(n))+", "+ld(ud.transform(r))+")"},ro={test:e=>Cc.test(e)||Yv.test(e)||Sf.test(e),parse:e=>Cc.test(e)?Cc.parse(e):Sf.test(e)?Sf.parse(e):Yv.parse(e),transform:e=>Vd(e)?e:e.hasOwnProperty("red")?Cc.transform(e):Sf.transform(e)},nr=(e,t,n)=>-n*e+n*t+e;function Hg(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function tN({hue:e,saturation:t,lightness:n,alpha:r}){e/=360,t/=100,n/=100;let i=0,o=0,s=0;if(!t)i=o=s=n;else{const l=n<.5?n*(1+t):n+t-n*t,c=2*n-l;i=Hg(c,l,e+1/3),o=Hg(c,l,e),s=Hg(c,l,e-1/3)}return{red:Math.round(i*255),green:Math.round(o*255),blue:Math.round(s*255),alpha:r}}const Ug=(e,t,n)=>{const r=e*e;return Math.sqrt(Math.max(0,n*(t*t-r)+r))},nN=[Yv,Cc,Sf],rN=e=>nN.find(t=>t.test(e));function rw(e){const t=rN(e);is(!!t,`'${e}' is not an animatable color. Use the equivalent color code instead.`);let n=t.parse(e);return t===Sf&&(n=tN(n)),n}const tC=(e,t)=>{const n=rw(e),r=rw(t),i={...n};return o=>(i.red=Ug(n.red,r.red,o),i.green=Ug(n.green,r.green,o),i.blue=Ug(n.blue,r.blue,o),i.alpha=nr(n.alpha,r.alpha,o),Cc.transform(i))};function iN(e){var t,n;return isNaN(e)&&Vd(e)&&(((t=e.match(Np))===null||t===void 0?void 0:t.length)||0)+(((n=e.match(DT))===null||n===void 0?void 0:n.length)||0)>0}const nC={regex:JL,countKey:"Vars",token:"${v}",parse:lr},rC={regex:DT,countKey:"Colors",token:"${c}",parse:ro.parse},iC={regex:Np,countKey:"Numbers",token:"${n}",parse:Vc.parse};function Wg(e,{regex:t,countKey:n,token:r,parse:i}){const o=e.tokenised.match(t);o&&(e["num"+n]=o.length,e.tokenised=e.tokenised.replace(t,r),e.values.push(...o.map(i)))}function up(e){const t=e.toString(),n={value:t,tokenised:t,values:[],numVars:0,numColors:0,numNumbers:0};return n.value.includes("var(--")&&Wg(n,nC),Wg(n,rC),Wg(n,iC),n}function oC(e){return up(e).values}function aC(e){const{values:t,numColors:n,numVars:r,tokenised:i}=up(e),o=t.length;return s=>{let l=i;for(let c=0;c<o;c++)c<r?l=l.replace(nC.token,s[c]):c<r+n?l=l.replace(rC.token,ro.transform(s[c])):l=l.replace(iC.token,ld(s[c]));return l}}const oN=e=>typeof e=="number"?0:e;function aN(e){const t=oC(e);return aC(e)(t.map(oN))}const Pl={test:iN,parse:oC,createTransformer:aC,getAnimatableNone:aN},sC=(e,t)=>n=>`${n>0?t:e}`;function uC(e,t){return typeof e=="number"?n=>nr(e,t,n):ro.test(e)?tC(e,t):e.startsWith("var(")?sC(e,t):cC(e,t)}const lC=(e,t)=>{const n=[...e],r=n.length,i=e.map((o,s)=>uC(o,t[s]));return o=>{for(let s=0;s<r;s++)n[s]=i[s](o);return n}},sN=(e,t)=>{const n={...e,...t},r={};for(const i in n)e[i]!==void 0&&t[i]!==void 0&&(r[i]=uC(e[i],t[i]));return i=>{for(const o in r)n[o]=r[o](i);return n}},cC=(e,t)=>{const n=Pl.createTransformer(t),r=up(e),i=up(t);return r.numVars===i.numVars&&r.numColors===i.numColors&&r.numNumbers>=i.numNumbers?Sl(lC(r.values,i.values),n):(Ud(!0,`Complex values '${e}' and '${t}' too different to mix. Ensure all colors are of the same type, and that each contains the same quantity of number and color values. Falling back to instant transition.`),sC(e,t))},Pd=(e,t,n)=>{const r=t-e;return r===0?1:(n-e)/r},iw=(e,t)=>n=>nr(e,t,n);function uN(e){return typeof e=="number"?iw:typeof e=="string"?ro.test(e)?tC:cC:Array.isArray(e)?lC:typeof e=="object"?sN:iw}function lN(e,t,n){const r=[],i=n||uN(e[0]),o=e.length-1;for(let s=0;s<o;s++){let l=i(e[s],e[s+1]);if(t){const c=Array.isArray(t)?t[s]||lr:t;l=Sl(c,l)}r.push(l)}return r}function fC(e,t,{clamp:n=!0,ease:r,mixer:i}={}){const o=e.length;if(is(o===t.length,"Both input and output ranges must be the same length"),o===1)return()=>t[0];e[0]>e[o-1]&&(e=[...e].reverse(),t=[...t].reverse());const s=lN(t,r,i),l=s.length,c=d=>{let v=0;if(l>1)for(;v<e.length-2&&!(d<e[v+1]);v++);const p=Pd(e[v],e[v+1],d);return s[v](p)};return n?d=>c(Dl(e[0],e[o-1],d)):c}function cN(e,t){const n=e[e.length-1];for(let r=1;r<=t;r++){const i=Pd(0,t,r);e.push(nr(n,1,i))}}function fN(e){const t=[0];return cN(t,e.length-1),t}function dN(e,t){return e.map(n=>n*t)}function hN(e,t){return e.map(()=>t||XT).splice(0,e.length-1)}function lp({duration:e=300,keyframes:t,times:n,ease:r="easeInOut"}){const i=X2(r)?r.map(nw):nw(r),o={done:!1,value:t[0]},s=dN(n&&n.length===t.length?n:fN(t),e),l=fC(s,t,{ease:Array.isArray(i)?i:hN(t,i)});return{calculatedDuration:e,next:c=>(o.value=l(c),o.done=c>=e,o)}}function dC(e,t){return t?e*(1e3/t):0}const pN=5;function hC(e,t,n){const r=Math.max(t-pN,0);return dC(n-e(r),t-r)}const zg=.001,gN=.01,ow=10,vN=.05,mN=1;function yN({duration:e=800,bounce:t=.25,velocity:n=0,mass:r=1}){let i,o;Ud(e<=Tl(ow),"Spring duration must be 10 seconds or less");let s=1-t;s=Dl(vN,mN,s),e=Dl(gN,ow,_u(e)),s<1?(i=d=>{const v=d*s,p=v*e,S=v-n,T=Gv(d,s),_=Math.exp(-p);return zg-S/T*_},o=d=>{const p=d*s*e,S=p*n+n,T=Math.pow(s,2)*Math.pow(d,2)*e,_=Math.exp(-p),R=Gv(Math.pow(d,2),s);return(-i(d)+zg>0?-1:1)*((S-T)*_)/R}):(i=d=>{const v=Math.exp(-d*e),p=(d-n)*e+1;return-zg+v*p},o=d=>{const v=Math.exp(-d*e),p=(n-d)*(e*e);return v*p});const l=5/e,c=wN(i,o,l);if(e=Tl(e),isNaN(c))return{stiffness:100,damping:10,duration:e};{const d=Math.pow(c,2)*r;return{stiffness:d,damping:s*2*Math.sqrt(r*d),duration:e}}}const bN=12;function wN(e,t,n){let r=n;for(let i=1;i<bN;i++)r=r-e(r)/t(r);return r}function Gv(e,t){return e*Math.sqrt(1-t*t)}const xN=["duration","bounce"],SN=["stiffness","damping","mass"];function aw(e,t){return t.some(n=>e[n]!==void 0)}function TN(e){let t={velocity:0,stiffness:100,damping:10,mass:1,isResolvedFromDuration:!1,...e};if(!aw(e,SN)&&aw(e,xN)){const n=yN(e);t={...t,...n,mass:1},t.isResolvedFromDuration=!0}return t}function pC({keyframes:e,restDelta:t,restSpeed:n,...r}){const i=e[0],o=e[e.length-1],s={done:!1,value:i},{stiffness:l,damping:c,mass:d,duration:v,velocity:p,isResolvedFromDuration:S}=TN({...r,velocity:-_u(r.velocity||0)}),T=p||0,_=c/(2*Math.sqrt(l*d)),R=o-i,L=_u(Math.sqrt(l/d)),I=Math.abs(R)<5;n||(n=I?.01:2),t||(t=I?.005:.5);let U;if(_<1){const z=Gv(L,_);U=re=>{const Z=Math.exp(-_*L*re);return o-Z*((T+_*L*R)/z*Math.sin(z*re)+R*Math.cos(z*re))}}else if(_===1)U=z=>o-Math.exp(-L*z)*(R+(T+L*R)*z);else{const z=L*Math.sqrt(_*_-1);U=re=>{const Z=Math.exp(-_*L*re),he=Math.min(z*re,300);return o-Z*((T+_*L*R)*Math.sinh(he)+z*R*Math.cosh(he))/z}}return{calculatedDuration:S&&v||null,next:z=>{const re=U(z);if(S)s.done=z>=v;else{let Z=T;z!==0&&(_<1?Z=hC(U,z,re):Z=0);const he=Math.abs(Z)<=n,x=Math.abs(o-re)<=t;s.done=he&&x}return s.value=s.done?o:re,s}}}function sw({keyframes:e,velocity:t=0,power:n=.8,timeConstant:r=325,bounceDamping:i=10,bounceStiffness:o=500,modifyTarget:s,min:l,max:c,restDelta:d=.5,restSpeed:v}){const p=e[0],S={done:!1,value:p},T=ce=>l!==void 0&&ce<l||c!==void 0&&ce>c,_=ce=>l===void 0?c:c===void 0||Math.abs(l-ce)<Math.abs(c-ce)?l:c;let R=n*t;const L=p+R,I=s===void 0?L:s(L);I!==L&&(R=I-p);const U=ce=>-R*Math.exp(-ce/r),z=ce=>I+U(ce),re=ce=>{const ae=U(ce),je=z(ce);S.done=Math.abs(ae)<=d,S.value=S.done?I:je};let Z,he;const x=ce=>{T(S.value)&&(Z=ce,he=pC({keyframes:[S.value,_(S.value)],velocity:hC(z,ce,S.value),damping:i,stiffness:o,restDelta:d,restSpeed:v}))};return x(0),{calculatedDuration:null,next:ce=>{let ae=!1;return!he&&Z===void 0&&(ae=!0,re(ce),x(ce)),Z!==void 0&&ce>Z?he.next(ce-Z):(!ae&&re(ce),S)}}}const CN=e=>{const t=({timestamp:n})=>e(n);return{start:()=>Hn.update(t,!0),stop:()=>Iu(t),now:()=>Li.isProcessing?Li.timestamp:performance.now()}},uw=2e4;function lw(e){let t=0;const n=50;let r=e.next(t);for(;!r.done&&t<uw;)t+=n,r=e.next(t);return t>=uw?1/0:t}const EN={decay:sw,inertia:sw,tween:lp,keyframes:lp,spring:pC};function cp({autoplay:e=!0,delay:t=0,driver:n=CN,keyframes:r,type:i="keyframes",repeat:o=0,repeatDelay:s=0,repeatType:l="loop",onPlay:c,onStop:d,onComplete:v,onUpdate:p,...S}){let T=1,_=!1,R,L;const I=()=>{L=new Promise(xe=>{R=xe})};I();let U;const z=EN[i]||lp;let re;z!==lp&&typeof r[0]!="number"&&(process.env.NODE_ENV!=="production"&&is(r.length===2,`Only two keyframes currently supported with spring and inertia animations. Trying to animate ${r}`),re=fC([0,100],r,{clamp:!1}),r=[0,100]);const Z=z({...S,keyframes:r});let he;l==="mirror"&&(he=z({...S,keyframes:[...r].reverse(),velocity:-(S.velocity||0)}));let x="idle",ce=null,ae=null,je=null;Z.calculatedDuration===null&&o&&(Z.calculatedDuration=lw(Z));const{calculatedDuration:qe}=Z;let We=1/0,rt=1/0;qe!==null&&(We=qe+s,rt=We*(o+1)-s);let nt=0;const ye=xe=>{if(ae===null)return;T>0&&(ae=Math.min(ae,xe)),T<0&&(ae=Math.min(xe-rt/T,ae)),ce!==null?nt=ce:nt=Math.round(xe-ae)*T;const Ue=nt-t*(T>=0?1:-1),Ve=T>=0?Ue<0:Ue>rt;nt=Math.max(Ue,0),x==="finished"&&ce===null&&(nt=rt);let Re=nt,Me=Z;if(o){const wt=Math.min(nt,rt)/We;let vt=Math.floor(wt),Et=wt%1;!Et&&wt>=1&&(Et=1),Et===1&&vt--,vt=Math.min(vt,o+1),!!(vt%2)&&(l==="reverse"?(Et=1-Et,s&&(Et-=s/We)):l==="mirror"&&(Me=he)),Re=Dl(0,1,Et)*We}const Xe=Ve?{done:!1,value:r[0]}:Me.next(Re);re&&(Xe.value=re(Xe.value));let{done:lt}=Xe;!Ve&&qe!==null&&(lt=T>=0?nt>=rt:nt<=0);const mt=ce===null&&(x==="finished"||x==="running"&<);return p&&p(Xe.value),mt&&Je(),Xe},De=()=>{U&&U.stop(),U=void 0},He=()=>{x="idle",De(),R(),I(),ae=je=null},Je=()=>{x="finished",v&&v(),De(),R()},at=()=>{if(_)return;U||(U=n(ye));const xe=U.now();c&&c(),ce!==null?ae=xe-ce:(!ae||x==="finished")&&(ae=xe),x==="finished"&&I(),je=ae,ce=null,x="running",U.start()};e&&at();const Oe={then(xe,Ue){return L.then(xe,Ue)},get time(){return _u(nt)},set time(xe){xe=Tl(xe),nt=xe,ce!==null||!U||T===0?ce=xe:ae=U.now()-xe/T},get duration(){const xe=Z.calculatedDuration===null?lw(Z):Z.calculatedDuration;return _u(xe)},get speed(){return T},set speed(xe){xe===T||!U||(T=xe,Oe.time=_u(nt))},get state(){return x},play:at,pause:()=>{x="paused",ce=nt},stop:()=>{_=!0,x!=="idle"&&(x="idle",d&&d(),He())},cancel:()=>{je!==null&&ye(je),He()},complete:()=>{x="finished"},sample:xe=>(ae=0,ye(xe))};return Oe}function kN(e){let t;return()=>(t===void 0&&(t=e()),t)}const ON=kN(()=>Object.hasOwnProperty.call(Element.prototype,"animate")),DN=new Set(["opacity","clipPath","filter","transform","backgroundColor"]),vh=10,PN=2e4,_N=(e,t)=>t.type==="spring"||e==="backgroundColor"||!zT(t.ease);function RN(e,t,{onUpdate:n,onComplete:r,...i}){if(!(ON()&&DN.has(t)&&!i.repeatDelay&&i.repeatType!=="mirror"&&i.damping!==0&&i.type!=="inertia"))return!1;let s=!1,l,c,d=!1;const v=()=>{c=new Promise(z=>{l=z})};v();let{keyframes:p,duration:S=300,ease:T,times:_}=i;if(_N(t,i)){const z=cp({...i,repeat:0,delay:0});let re={done:!1,value:p[0]};const Z=[];let he=0;for(;!re.done&&he<PN;)re=z.sample(he),Z.push(re.value),he+=vh;_=void 0,p=Z,S=he-vh,T="linear"}const R=H2(e.owner.current,t,p,{...i,duration:S,ease:T,times:_}),L=()=>{d=!1,R.cancel()},I=()=>{d=!0,Hn.update(L),l(),v()};return R.onfinish=()=>{d||(e.set(U2(p,i)),r&&r(),I())},{then(z,re){return c.then(z,re)},attachTimeline(z){return R.timeline=z,R.onfinish=null,lr},get time(){return _u(R.currentTime||0)},set time(z){R.currentTime=Tl(z)},get speed(){return R.playbackRate},set speed(z){R.playbackRate=z},get duration(){return _u(S)},play:()=>{s||(R.play(),Iu(L))},pause:()=>R.pause(),stop:()=>{if(s=!0,R.playState==="idle")return;const{currentTime:z}=R;if(z){const re=cp({...i,autoplay:!1});e.setWithVelocity(re.sample(z-vh).value,re.sample(z).value,vh)}I()},complete:()=>{d||R.finish()},cancel:I}}function IN({keyframes:e,delay:t,onUpdate:n,onComplete:r}){const i=()=>(n&&n(e[e.length-1]),r&&r(),{time:0,speed:1,duration:0,play:lr,pause:lr,stop:lr,then:o=>(o(),Promise.resolve()),cancel:lr,complete:lr});return t?cp({keyframes:[0,1],duration:0,delay:t,onComplete:i}):i()}const AN={type:"spring",stiffness:500,damping:25,restSpeed:10},MN=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),LN={type:"keyframes",duration:.8},NN={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},FN=(e,{keyframes:t})=>t.length>2?LN:$c.has(e)?e.startsWith("scale")?MN(t[1]):AN:NN,qv=(e,t)=>e==="zIndex"?!1:!!(typeof t=="number"||Array.isArray(t)||typeof t=="string"&&(Pl.test(t)||t==="0")&&!t.startsWith("url(")),jN=new Set(["brightness","contrast","saturate","opacity"]);function BN(e){const[t,n]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;const[r]=n.match(Np)||[];if(!r)return e;const i=n.replace(r,"");let o=jN.has(t)?1:0;return r!==n&&(o*=100),t+"("+o+i+")"}const $N=/([a-z-]*)\(.*?\)/g,Xv={...Pl,getAnimatableNone:e=>{const t=e.match($N);return t?t.map(BN).join(" "):e}},VN={...PT,color:ro,backgroundColor:ro,outlineColor:ro,fill:ro,stroke:ro,borderColor:ro,borderTopColor:ro,borderRightColor:ro,borderBottomColor:ro,borderLeftColor:ro,filter:Xv,WebkitFilter:Xv},uy=e=>VN[e];function gC(e,t){let n=uy(e);return n!==Xv&&(n=Pl),n.getAnimatableNone?n.getAnimatableNone(t):void 0}const vC=e=>/^0[^.\s]+$/.test(e);function HN(e){if(typeof e=="number")return e===0;if(e!==null)return e==="none"||e==="0"||vC(e)}function UN(e,t,n,r){const i=qv(t,n);let o;Array.isArray(n)?o=[...n]:o=[null,n];const s=r.from!==void 0?r.from:e.get();let l;const c=[];for(let d=0;d<o.length;d++)o[d]===null&&(o[d]=d===0?s:o[d-1]),HN(o[d])&&c.push(d),typeof o[d]=="string"&&o[d]!=="none"&&o[d]!=="0"&&(l=o[d]);if(i&&c.length&&l)for(let d=0;d<c.length;d++){const v=c[d];o[v]=gC(t,l)}return o}function WN({when:e,delay:t,delayChildren:n,staggerChildren:r,staggerDirection:i,repeat:o,repeatType:s,repeatDelay:l,from:c,elapsed:d,...v}){return!!Object.keys(v).length}function ly(e,t){return e[t]||e.default||e}const zN={skipAnimations:!1},cy=(e,t,n,r={})=>i=>{const o=ly(r,e)||{},s=o.delay||r.delay||0;let{elapsed:l=0}=r;l=l-Tl(s);const c=UN(t,e,n,o),d=c[0],v=c[c.length-1],p=qv(e,d),S=qv(e,v);Ud(p===S,`You are trying to animate ${e} from "${d}" to "${v}". ${d} is not an animatable value - to enable this animation set ${d} to a value animatable to ${v} via the \`style\` property.`);let T={keyframes:c,velocity:t.getVelocity(),ease:"easeOut",...o,delay:-l,onUpdate:_=>{t.set(_),o.onUpdate&&o.onUpdate(_)},onComplete:()=>{i(),o.onComplete&&o.onComplete()}};if(WN(o)||(T={...T,...FN(e,T)}),T.duration&&(T.duration=Tl(T.duration)),T.repeatDelay&&(T.repeatDelay=Tl(T.repeatDelay)),!p||!S||V2.current||o.type===!1||zN.skipAnimations)return IN(T);if(!r.isHandoff&&t.owner&&t.owner.current instanceof HTMLElement&&!t.owner.getProps().onUpdate){const _=RN(t,e,T);if(_)return _}return cp(T)};function fp(e){return!!(Do(e)&&e.add)}const mC=e=>/^\-?\d*\.?\d+$/.test(e);function fy(e,t){e.indexOf(t)===-1&&e.push(t)}function dy(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}let hy=class{constructor(){this.subscriptions=[]}add(t){return fy(this.subscriptions,t),()=>dy(this.subscriptions,t)}notify(t,n,r){const i=this.subscriptions.length;if(i)if(i===1)this.subscriptions[0](t,n,r);else for(let o=0;o<i;o++){const s=this.subscriptions[o];s&&s(t,n,r)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}};const cw=new Set;function py(e,t,n){e||cw.has(t)||(console.warn(t),n&&console.warn(n),cw.add(t))}const YN=e=>!isNaN(parseFloat(e));let GN=class{constructor(t,n={}){this.version="10.18.0",this.timeDelta=0,this.lastUpdated=0,this.canTrackVelocity=!1,this.events={},this.updateAndNotify=(r,i=!0)=>{this.prev=this.current,this.current=r;const{delta:o,timestamp:s}=Li;this.lastUpdated!==s&&(this.timeDelta=o,this.lastUpdated=s,Hn.postRender(this.scheduleVelocityCheck)),this.prev!==this.current&&this.events.change&&this.events.change.notify(this.current),this.events.velocityChange&&this.events.velocityChange.notify(this.getVelocity()),i&&this.events.renderRequest&&this.events.renderRequest.notify(this.current)},this.scheduleVelocityCheck=()=>Hn.postRender(this.velocityCheck),this.velocityCheck=({timestamp:r})=>{r!==this.lastUpdated&&(this.prev=this.current,this.events.velocityChange&&this.events.velocityChange.notify(this.getVelocity()))},this.hasAnimated=!1,this.prev=this.current=t,this.canTrackVelocity=YN(this.current),this.owner=n.owner}onChange(t){return process.env.NODE_ENV!=="production"&&py(!1,'value.onChange(callback) is deprecated. Switch to value.on("change", callback).'),this.on("change",t)}on(t,n){this.events[t]||(this.events[t]=new hy);const r=this.events[t].add(n);return t==="change"?()=>{r(),Hn.read(()=>{this.events.change.getSize()||this.stop()})}:r}clearListeners(){for(const t in this.events)this.events[t].clear()}attach(t,n){this.passiveEffect=t,this.stopPassiveEffect=n}set(t,n=!0){!n||!this.passiveEffect?this.updateAndNotify(t,n):this.passiveEffect(t,this.updateAndNotify)}setWithVelocity(t,n,r){this.set(n),this.prev=t,this.timeDelta=r}jump(t){this.updateAndNotify(t),this.prev=t,this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}get(){return this.current}getPrevious(){return this.prev}getVelocity(){return this.canTrackVelocity?dC(parseFloat(this.current)-parseFloat(this.prev),this.timeDelta):0}start(t){return this.stop(),new Promise(n=>{this.hasAnimated=!0,this.animation=t(n),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}};function Rf(e,t){return new GN(e,t)}const yC=e=>t=>t.test(e),qN={test:e=>e==="auto",parse:e=>e},bC=[Vc,jt,Ns,pl,n2,t2,qN],ed=e=>bC.find(yC(e)),XN=[...bC,ro,Pl],KN=e=>XN.find(yC(e));function ZN(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,Rf(n))}function JN(e,t){const n=jp(e,t);let{transitionEnd:r={},transition:i={},...o}=n?e.makeTargetAnimatable(n,!1):{};o={...o,...r};for(const s in o){const l=m2(o[s]);ZN(e,s,l)}}function QN(e,t,n){var r,i;const o=Object.keys(t).filter(l=>!e.hasValue(l)),s=o.length;if(s)for(let l=0;l<s;l++){const c=o[l],d=t[c];let v=null;Array.isArray(d)&&(v=d[0]),v===null&&(v=(i=(r=n[c])!==null&&r!==void 0?r:e.readValue(c))!==null&&i!==void 0?i:t[c]),v!=null&&(typeof v=="string"&&(mC(v)||vC(v))?v=parseFloat(v):!KN(v)&&Pl.test(d)&&(v=gC(c,d)),e.addValue(c,Rf(v,{owner:e})),n[c]===void 0&&(n[c]=v),v!==null&&e.setBaseTarget(c,v))}}function eF(e,t){return t?(t[e]||t.default||t).from:void 0}function tF(e,t,n){const r={};for(const i in e){const o=eF(i,t);if(o!==void 0)r[i]=o;else{const s=n.getValue(i);s&&(r[i]=s.get())}}return r}function nF({protectedKeys:e,needsAnimating:t},n){const r=e.hasOwnProperty(n)&&t[n]!==!0;return t[n]=!1,r}function rF(e,t){const n=e.get();if(Array.isArray(t)){for(let r=0;r<t.length;r++)if(t[r]!==n)return!0}else return n!==t}function wC(e,t,{delay:n=0,transitionOverride:r,type:i}={}){let{transition:o=e.getDefaultTransition(),transitionEnd:s,...l}=e.makeTargetAnimatable(t);const c=e.getValue("willChange");r&&(o=r);const d=[],v=i&&e.animationState&&e.animationState.getState()[i];for(const p in l){const S=e.getValue(p),T=l[p];if(!S||T===void 0||v&&nF(v,p))continue;const _={delay:n,elapsed:0,...ly(o||{},p)};if(window.HandoffAppearAnimations){const I=e.getProps()[xT];if(I){const U=window.HandoffAppearAnimations(I,p,S,Hn);U!==null&&(_.elapsed=U,_.isHandoff=!0)}}let R=!_.isHandoff&&!rF(S,T);if(_.type==="spring"&&(S.getVelocity()||_.velocity)&&(R=!1),S.animation&&(R=!1),R)continue;S.start(cy(p,S,T,e.shouldReduceMotion&&$c.has(p)?{type:!1}:_));const L=S.animation;fp(c)&&(c.add(p),L.then(()=>c.remove(p))),d.push(L)}return s&&Promise.all(d).then(()=>{s&&JN(e,s)}),d}function Kv(e,t,n={}){const r=jp(e,t,n.custom);let{transition:i=e.getDefaultTransition()||{}}=r||{};n.transitionOverride&&(i=n.transitionOverride);const o=r?()=>Promise.all(wC(e,r,n)):()=>Promise.resolve(),s=e.variantChildren&&e.variantChildren.size?(c=0)=>{const{delayChildren:d=0,staggerChildren:v,staggerDirection:p}=i;return iF(e,t,d+c,v,p,n)}:()=>Promise.resolve(),{when:l}=i;if(l){const[c,d]=l==="beforeChildren"?[o,s]:[s,o];return c().then(()=>d())}else return Promise.all([o(),s(n.delay)])}function iF(e,t,n=0,r=0,i=1,o){const s=[],l=(e.variantChildren.size-1)*r,c=i===1?(d=0)=>d*r:(d=0)=>l-d*r;return Array.from(e.variantChildren).sort(oF).forEach((d,v)=>{d.notify("AnimationStart",t),s.push(Kv(d,t,{...o,delay:n+c(v)}).then(()=>d.notify("AnimationComplete",t)))}),Promise.all(s)}function oF(e,t){return e.sortNodePosition(t)}function aF(e,t,n={}){e.notify("AnimationStart",t);let r;if(Array.isArray(t)){const i=t.map(o=>Kv(e,o,n));r=Promise.all(i)}else if(typeof t=="string")r=Kv(e,t,n);else{const i=typeof t=="function"?jp(e,t,n.custom):t;r=Promise.all(wC(e,i,n))}return r.then(()=>e.notify("AnimationComplete",t))}const sF=[...Km].reverse(),uF=Km.length;function lF(e){return t=>Promise.all(t.map(({animation:n,options:r})=>aF(e,n,r)))}function cF(e){let t=lF(e);const n=dF();let r=!0;const i=(c,d)=>{const v=jp(e,d);if(v){const{transition:p,transitionEnd:S,...T}=v;c={...c,...T,...S}}return c};function o(c){t=c(e)}function s(c,d){const v=e.getProps(),p=e.getVariantContext(!0)||{},S=[],T=new Set;let _={},R=1/0;for(let I=0;I<uF;I++){const U=sF[I],z=n[U],re=v[U]!==void 0?v[U]:p[U],Z=Od(re),he=U===d?z.isActive:null;he===!1&&(R=I);let x=re===p[U]&&re!==v[U]&&Z;if(x&&r&&e.manuallyAnimateOnMount&&(x=!1),z.protectedKeys={..._},!z.isActive&&he===null||!re&&!z.prevProp||Mp(re)||typeof re=="boolean")continue;let ae=fF(z.prevProp,re)||U===d&&z.isActive&&!x&&Z||I>R&&Z,je=!1;const qe=Array.isArray(re)?re:[re];let We=qe.reduce(i,{});he===!1&&(We={});const{prevResolvedValues:rt={}}=z,nt={...rt,...We},ye=De=>{ae=!0,T.has(De)&&(je=!0,T.delete(De)),z.needsAnimating[De]=!0};for(const De in nt){const He=We[De],Je=rt[De];if(_.hasOwnProperty(De))continue;let at=!1;sp(He)&&sp(Je)?at=!UT(He,Je):at=He!==Je,at?He!==void 0?ye(De):T.add(De):He!==void 0&&T.has(De)?ye(De):z.protectedKeys[De]=!0}z.prevProp=re,z.prevResolvedValues=We,z.isActive&&(_={..._,...We}),r&&e.blockInitialAnimation&&(ae=!1),ae&&(!x||je)&&S.push(...qe.map(De=>({animation:De,options:{type:U,...c}})))}if(T.size){const I={};T.forEach(U=>{const z=e.getBaseTarget(U);z!==void 0&&(I[U]=z)}),S.push({animation:I})}let L=!!S.length;return r&&(v.initial===!1||v.initial===v.animate)&&!e.manuallyAnimateOnMount&&(L=!1),r=!1,L?t(S):Promise.resolve()}function l(c,d,v){var p;if(n[c].isActive===d)return Promise.resolve();(p=e.variantChildren)===null||p===void 0||p.forEach(T=>{var _;return(_=T.animationState)===null||_===void 0?void 0:_.setActive(c,d)}),n[c].isActive=d;const S=s(v,c);for(const T in n)n[T].protectedKeys={};return S}return{animateChanges:s,setActive:l,setAnimateFunction:o,getState:()=>n}}function fF(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!UT(t,e):!1}function gc(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function dF(){return{animate:gc(!0),whileInView:gc(),whileHover:gc(),whileTap:gc(),whileDrag:gc(),whileFocus:gc(),exit:gc()}}class hF extends Il{constructor(t){super(t),t.animationState||(t.animationState=cF(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();this.unmount(),Mp(t)&&(this.unmount=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:t}=this.node.getProps(),{animate:n}=this.node.prevProps||{};t!==n&&this.updateAnimationControlsSubscription()}unmount(){}}let pF=0;class gF extends Il{constructor(){super(...arguments),this.id=pF++}update(){if(!this.node.presenceContext)return;const{isPresent:t,onExitComplete:n,custom:r}=this.node.presenceContext,{isPresent:i}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===i)return;const o=this.node.animationState.setActive("exit",!t,{custom:r??this.node.getProps().custom});n&&!t&&o.then(()=>n(this.id))}mount(){const{register:t}=this.node.presenceContext||{};t&&(this.unmount=t(this.id))}unmount(){}}const vF={animation:{Feature:hF},exit:{Feature:gF}},fw=(e,t)=>Math.abs(e-t);function mF(e,t){const n=fw(e.x,t.x),r=fw(e.y,t.y);return Math.sqrt(n**2+r**2)}let xC=class{constructor(t,n,{transformPagePoint:r,contextWindow:i,dragSnapToOrigin:o=!1}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const p=Gg(this.lastMoveEventInfo,this.history),S=this.startEvent!==null,T=mF(p.offset,{x:0,y:0})>=3;if(!S&&!T)return;const{point:_}=p,{timestamp:R}=Li;this.history.push({..._,timestamp:R});const{onStart:L,onMove:I}=this.handlers;S||(L&&L(this.lastMoveEvent,p),this.startEvent=this.lastMoveEvent),I&&I(this.lastMoveEvent,p)},this.handlePointerMove=(p,S)=>{this.lastMoveEvent=p,this.lastMoveEventInfo=Yg(S,this.transformPagePoint),Hn.update(this.updatePoint,!0)},this.handlePointerUp=(p,S)=>{this.end();const{onEnd:T,onSessionEnd:_,resumeAnimation:R}=this.handlers;if(this.dragSnapToOrigin&&R&&R(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const L=Gg(p.type==="pointercancel"?this.lastMoveEventInfo:Yg(S,this.transformPagePoint),this.history);this.startEvent&&T&&T(p,L),_&&_(p,L)},!jT(t))return;this.dragSnapToOrigin=o,this.handlers=n,this.transformPagePoint=r,this.contextWindow=i||window;const s=Fp(t),l=Yg(s,this.transformPagePoint),{point:c}=l,{timestamp:d}=Li;this.history=[{...c,timestamp:d}];const{onSessionStart:v}=n;v&&v(t,Gg(l,this.history)),this.removeListeners=Sl(Pu(this.contextWindow,"pointermove",this.handlePointerMove),Pu(this.contextWindow,"pointerup",this.handlePointerUp),Pu(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),Iu(this.updatePoint)}};function Yg(e,t){return t?{point:t(e.point)}:e}function dw(e,t){return{x:e.x-t.x,y:e.y-t.y}}function Gg({point:e},t){return{point:e,delta:dw(e,SC(t)),offset:dw(e,yF(t)),velocity:bF(t,.1)}}function yF(e){return e[0]}function SC(e){return e[e.length-1]}function bF(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null;const i=SC(e);for(;n>=0&&(r=e[n],!(i.timestamp-r.timestamp>Tl(t)));)n--;if(!r)return{x:0,y:0};const o=_u(i.timestamp-r.timestamp);if(o===0)return{x:0,y:0};const s={x:(i.x-r.x)/o,y:(i.y-r.y)/o};return s.x===1/0&&(s.x=0),s.y===1/0&&(s.y=0),s}function ea(e){return e.max-e.min}function Zv(e,t=0,n=.01){return Math.abs(e-t)<=n}function hw(e,t,n,r=.5){e.origin=r,e.originPoint=nr(t.min,t.max,e.origin),e.scale=ea(n)/ea(t),(Zv(e.scale,1,1e-4)||isNaN(e.scale))&&(e.scale=1),e.translate=nr(n.min,n.max,e.origin)-e.originPoint,(Zv(e.translate)||isNaN(e.translate))&&(e.translate=0)}function cd(e,t,n,r){hw(e.x,t.x,n.x,r?r.originX:void 0),hw(e.y,t.y,n.y,r?r.originY:void 0)}function pw(e,t,n){e.min=n.min+t.min,e.max=e.min+ea(t)}function wF(e,t,n){pw(e.x,t.x,n.x),pw(e.y,t.y,n.y)}function gw(e,t,n){e.min=t.min-n.min,e.max=e.min+ea(t)}function fd(e,t,n){gw(e.x,t.x,n.x),gw(e.y,t.y,n.y)}function xF(e,{min:t,max:n},r){return t!==void 0&&e<t?e=r?nr(t,e,r.min):Math.max(e,t):n!==void 0&&e>n&&(e=r?nr(n,e,r.max):Math.min(e,n)),e}function vw(e,t,n){return{min:t!==void 0?e.min+t:void 0,max:n!==void 0?e.max+n-(e.max-e.min):void 0}}function SF(e,{top:t,left:n,bottom:r,right:i}){return{x:vw(e.x,n,i),y:vw(e.y,t,r)}}function mw(e,t){let n=t.min-e.min,r=t.max-e.max;return t.max-t.min<e.max-e.min&&([n,r]=[r,n]),{min:n,max:r}}function TF(e,t){return{x:mw(e.x,t.x),y:mw(e.y,t.y)}}function CF(e,t){let n=.5;const r=ea(e),i=ea(t);return i>r?n=Pd(t.min,t.max-r,e.min):r>i&&(n=Pd(e.min,e.max-i,t.min)),Dl(0,1,n)}function EF(e,t){const n={};return t.min!==void 0&&(n.min=t.min-e.min),t.max!==void 0&&(n.max=t.max-e.min),n}const Jv=.35;function kF(e=Jv){return e===!1?e=0:e===!0&&(e=Jv),{x:yw(e,"left","right"),y:yw(e,"top","bottom")}}function yw(e,t,n){return{min:bw(e,t),max:bw(e,n)}}function bw(e,t){return typeof e=="number"?e:e[t]||0}const ww=()=>({translate:0,scale:1,origin:0,originPoint:0}),Tf=()=>({x:ww(),y:ww()}),xw=()=>({min:0,max:0}),Dr=()=>({x:xw(),y:xw()});function Ea(e){return[e("x"),e("y")]}function TC({top:e,left:t,right:n,bottom:r}){return{x:{min:t,max:n},y:{min:e,max:r}}}function OF({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function DF(e,t){if(!t)return e;const n=t({x:e.left,y:e.top}),r=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:r.y,right:r.x}}function qg(e){return e===void 0||e===1}function Qv({scale:e,scaleX:t,scaleY:n}){return!qg(e)||!qg(t)||!qg(n)}function xc(e){return Qv(e)||CC(e)||e.z||e.rotate||e.rotateX||e.rotateY}function CC(e){return Sw(e.x)||Sw(e.y)}function Sw(e){return e&&e!=="0%"}function dp(e,t,n){const r=e-n,i=t*r;return n+i}function Tw(e,t,n,r,i){return i!==void 0&&(e=dp(e,i,r)),dp(e,n,r)+t}function em(e,t=0,n=1,r,i){e.min=Tw(e.min,t,n,r,i),e.max=Tw(e.max,t,n,r,i)}function EC(e,{x:t,y:n}){em(e.x,t.translate,t.scale,t.originPoint),em(e.y,n.translate,n.scale,n.originPoint)}function PF(e,t,n,r=!1){const i=n.length;if(!i)return;t.x=t.y=1;let o,s;for(let l=0;l<i;l++){o=n[l],s=o.projectionDelta;const c=o.instance;c&&c.style&&c.style.display==="contents"||(r&&o.options.layoutScroll&&o.scroll&&o!==o.root&&Cf(e,{x:-o.scroll.offset.x,y:-o.scroll.offset.y}),s&&(t.x*=s.x.scale,t.y*=s.y.scale,EC(e,s)),r&&xc(o.latestValues)&&Cf(e,o.latestValues))}t.x=Cw(t.x),t.y=Cw(t.y)}function Cw(e){return Number.isInteger(e)||e>1.0000000000001||e<.999999999999?e:1}function ml(e,t){e.min=e.min+t,e.max=e.max+t}function Ew(e,t,[n,r,i]){const o=t[i]!==void 0?t[i]:.5,s=nr(e.min,e.max,o);em(e,t[n],t[r],s,t.scale)}const _F=["x","scaleX","originX"],RF=["y","scaleY","originY"];function Cf(e,t){Ew(e.x,t,_F),Ew(e.y,t,RF)}function kC(e,t){return TC(DF(e.getBoundingClientRect(),t))}function IF(e,t,n){const r=kC(e,n),{scroll:i}=t;return i&&(ml(r.x,i.offset.x),ml(r.y,i.offset.y)),r}const OC=({current:e})=>e?e.ownerDocument.defaultView:null,AF=new WeakMap;let MF=class{constructor(t){this.openGlobalLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=Dr(),this.visualElement=t}start(t,{snapToCursor:n=!1}={}){const{presenceContext:r}=this.visualElement;if(r&&r.isPresent===!1)return;const i=v=>{const{dragSnapToOrigin:p}=this.getProps();p?this.pauseAnimation():this.stopAnimation(),n&&this.snapToCursor(Fp(v,"page").point)},o=(v,p)=>{const{drag:S,dragPropagation:T,onDragStart:_}=this.getProps();if(S&&!T&&(this.openGlobalLock&&this.openGlobalLock(),this.openGlobalLock=$T(S),!this.openGlobalLock))return;this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),Ea(L=>{let I=this.getAxisMotionValue(L).get()||0;if(Ns.test(I)){const{projection:U}=this.visualElement;if(U&&U.layout){const z=U.layout.layoutBox[L];z&&(I=ea(z)*(parseFloat(I)/100))}}this.originPoint[L]=I}),_&&Hn.update(()=>_(v,p),!1,!0);const{animationState:R}=this.visualElement;R&&R.setActive("whileDrag",!0)},s=(v,p)=>{const{dragPropagation:S,dragDirectionLock:T,onDirectionLock:_,onDrag:R}=this.getProps();if(!S&&!this.openGlobalLock)return;const{offset:L}=p;if(T&&this.currentDirection===null){this.currentDirection=LF(L),this.currentDirection!==null&&_&&_(this.currentDirection);return}this.updateAxis("x",p.point,L),this.updateAxis("y",p.point,L),this.visualElement.render(),R&&R(v,p)},l=(v,p)=>this.stop(v,p),c=()=>Ea(v=>{var p;return this.getAnimationState(v)==="paused"&&((p=this.getAxisMotionValue(v).animation)===null||p===void 0?void 0:p.play())}),{dragSnapToOrigin:d}=this.getProps();this.panSession=new xC(t,{onSessionStart:i,onStart:o,onMove:s,onSessionEnd:l,resumeAnimation:c},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:d,contextWindow:OC(this.visualElement)})}stop(t,n){const r=this.isDragging;if(this.cancel(),!r)return;const{velocity:i}=n;this.startAnimation(i);const{onDragEnd:o}=this.getProps();o&&Hn.update(()=>o(t,n))}cancel(){this.isDragging=!1;const{projection:t,animationState:n}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;const{dragPropagation:r}=this.getProps();!r&&this.openGlobalLock&&(this.openGlobalLock(),this.openGlobalLock=null),n&&n.setActive("whileDrag",!1)}updateAxis(t,n,r){const{drag:i}=this.getProps();if(!r||!mh(t,i,this.currentDirection))return;const o=this.getAxisMotionValue(t);let s=this.originPoint[t]+r[t];this.constraints&&this.constraints[t]&&(s=xF(s,this.constraints[t],this.elastic[t])),o.set(s)}resolveConstraints(){var t;const{dragConstraints:n,dragElastic:r}=this.getProps(),i=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):(t=this.visualElement.projection)===null||t===void 0?void 0:t.layout,o=this.constraints;n&&xf(n)?this.constraints||(this.constraints=this.resolveRefConstraints()):n&&i?this.constraints=SF(i.layoutBox,n):this.constraints=!1,this.elastic=kF(r),o!==this.constraints&&i&&this.constraints&&!this.hasMutatedConstraints&&Ea(s=>{this.getAxisMotionValue(s)&&(this.constraints[s]=EF(i.layoutBox[s],this.constraints[s]))})}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:n}=this.getProps();if(!t||!xf(t))return!1;const r=t.current;is(r!==null,"If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop.");const{projection:i}=this.visualElement;if(!i||!i.layout)return!1;const o=IF(r,i.root,this.visualElement.getTransformPagePoint());let s=TF(i.layout.layoutBox,o);if(n){const l=n(OF(s));this.hasMutatedConstraints=!!l,l&&(s=TC(l))}return s}startAnimation(t){const{drag:n,dragMomentum:r,dragElastic:i,dragTransition:o,dragSnapToOrigin:s,onDragTransitionEnd:l}=this.getProps(),c=this.constraints||{},d=Ea(v=>{if(!mh(v,n,this.currentDirection))return;let p=c&&c[v]||{};s&&(p={min:0,max:0});const S=i?200:1e6,T=i?40:1e7,_={type:"inertia",velocity:r?t[v]:0,bounceStiffness:S,bounceDamping:T,timeConstant:750,restDelta:1,restSpeed:10,...o,...p};return this.startAxisValueAnimation(v,_)});return Promise.all(d).then(l)}startAxisValueAnimation(t,n){const r=this.getAxisMotionValue(t);return r.start(cy(t,r,0,n))}stopAnimation(){Ea(t=>this.getAxisMotionValue(t).stop())}pauseAnimation(){Ea(t=>{var n;return(n=this.getAxisMotionValue(t).animation)===null||n===void 0?void 0:n.pause()})}getAnimationState(t){var n;return(n=this.getAxisMotionValue(t).animation)===null||n===void 0?void 0:n.state}getAxisMotionValue(t){const n="_drag"+t.toUpperCase(),r=this.visualElement.getProps(),i=r[n];return i||this.visualElement.getValue(t,(r.initial?r.initial[t]:void 0)||0)}snapToCursor(t){Ea(n=>{const{drag:r}=this.getProps();if(!mh(n,r,this.currentDirection))return;const{projection:i}=this.visualElement,o=this.getAxisMotionValue(n);if(i&&i.layout){const{min:s,max:l}=i.layout.layoutBox[n];o.set(t[n]-nr(s,l,.5))}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:n}=this.getProps(),{projection:r}=this.visualElement;if(!xf(n)||!r||!this.constraints)return;this.stopAnimation();const i={x:0,y:0};Ea(s=>{const l=this.getAxisMotionValue(s);if(l){const c=l.get();i[s]=CF({min:c,max:c},this.constraints[s])}});const{transformTemplate:o}=this.visualElement.getProps();this.visualElement.current.style.transform=o?o({},""):"none",r.root&&r.root.updateScroll(),r.updateLayout(),this.resolveConstraints(),Ea(s=>{if(!mh(s,t,null))return;const l=this.getAxisMotionValue(s),{min:c,max:d}=this.constraints[s];l.set(nr(c,d,i[s]))})}addListeners(){if(!this.visualElement.current)return;AF.set(this.visualElement,this);const t=this.visualElement.current,n=Pu(t,"pointerdown",c=>{const{drag:d,dragListener:v=!0}=this.getProps();d&&v&&this.start(c)}),r=()=>{const{dragConstraints:c}=this.getProps();xf(c)&&(this.constraints=this.resolveRefConstraints())},{projection:i}=this.visualElement,o=i.addEventListener("measure",r);i&&!i.layout&&(i.root&&i.root.updateScroll(),i.updateLayout()),r();const s=ku(window,"resize",()=>this.scalePositionWithinConstraints()),l=i.addEventListener("didUpdate",({delta:c,hasLayoutChanged:d})=>{this.isDragging&&d&&(Ea(v=>{const p=this.getAxisMotionValue(v);p&&(this.originPoint[v]+=c[v].translate,p.set(p.get()+c[v].translate))}),this.visualElement.render())});return()=>{s(),n(),o(),l&&l()}}getProps(){const t=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:r=!1,dragPropagation:i=!1,dragConstraints:o=!1,dragElastic:s=Jv,dragMomentum:l=!0}=t;return{...t,drag:n,dragDirectionLock:r,dragPropagation:i,dragConstraints:o,dragElastic:s,dragMomentum:l}}};function mh(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function LF(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}class NF extends Il{constructor(t){super(t),this.removeGroupControls=lr,this.removeListeners=lr,this.controls=new MF(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||lr}unmount(){this.removeGroupControls(),this.removeListeners()}}const kw=e=>(t,n)=>{e&&Hn.update(()=>e(t,n))};class FF extends Il{constructor(){super(...arguments),this.removePointerDownListener=lr}onPointerDown(t){this.session=new xC(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:OC(this.node)})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:n,onPan:r,onPanEnd:i}=this.node.getProps();return{onSessionStart:kw(t),onStart:kw(n),onMove:r,onEnd:(o,s)=>{delete this.session,i&&Hn.update(()=>i(o,s))}}}mount(){this.removePointerDownListener=Pu(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}function jF(){const e=Q.useContext(qm);if(e===null)return[!0,null];const{isPresent:t,onExitComplete:n,register:r}=e,i=Q.useId();return Q.useEffect(()=>r(i),[]),!t&&n?[!1,()=>n&&n(i)]:[!0]}const Hh={hasAnimatedSinceResize:!0,hasEverUpdated:!1};function Ow(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const td={correct:(e,t)=>{if(!t.target)return e;if(typeof e=="string")if(jt.test(e))e=parseFloat(e);else return e;const n=Ow(e,t.target.x),r=Ow(e,t.target.y);return`${n}% ${r}%`}},BF={correct:(e,{treeScale:t,projectionDelta:n})=>{const r=e,i=Pl.parse(e);if(i.length>5)return r;const o=Pl.createTransformer(e),s=typeof i[0]!="number"?1:0,l=n.x.scale*t.x,c=n.y.scale*t.y;i[0+s]/=l,i[1+s]/=c;const d=nr(l,c,.5);return typeof i[2+s]=="number"&&(i[2+s]/=d),typeof i[3+s]=="number"&&(i[3+s]/=d),o(i)}};let $F=class extends Q.Component{componentDidMount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r,layoutId:i}=this.props,{projection:o}=t;qL(VF),o&&(n.group&&n.group.add(o),r&&r.register&&i&&r.register(o),o.root.didUpdate(),o.addEventListener("animationComplete",()=>{this.safeToRemove()}),o.setOptions({...o.options,onExitComplete:()=>this.safeToRemove()})),Hh.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:n,visualElement:r,drag:i,isPresent:o}=this.props,s=r.projection;return s&&(s.isPresent=o,i||t.layoutDependency!==n||n===void 0?s.willUpdate():this.safeToRemove(),t.isPresent!==o&&(o?s.promote():s.relegate()||Hn.postRender(()=>{const l=s.getStack();(!l||!l.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{projection:t}=this.props.visualElement;t&&(t.root.didUpdate(),queueMicrotask(()=>{!t.currentAnimation&&t.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r}=this.props,{projection:i}=t;i&&(i.scheduleCheckAfterUnmount(),n&&n.group&&n.group.remove(i),r&&r.deregister&&r.deregister(i))}safeToRemove(){const{safeToRemove:t}=this.props;t&&t()}render(){return null}};function DC(e){const[t,n]=jF(),r=Q.useContext(TT);return Q.createElement($F,{...e,layoutGroup:r,switchLayoutGroup:Q.useContext(CT),isPresent:t,safeToRemove:n})}const VF={borderRadius:{...td,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:td,borderTopRightRadius:td,borderBottomLeftRadius:td,borderBottomRightRadius:td,boxShadow:BF},PC=["TopLeft","TopRight","BottomLeft","BottomRight"],HF=PC.length,Dw=e=>typeof e=="string"?parseFloat(e):e,Pw=e=>typeof e=="number"||jt.test(e);function UF(e,t,n,r,i,o){i?(e.opacity=nr(0,n.opacity!==void 0?n.opacity:1,WF(r)),e.opacityExit=nr(t.opacity!==void 0?t.opacity:1,0,zF(r))):o&&(e.opacity=nr(t.opacity!==void 0?t.opacity:1,n.opacity!==void 0?n.opacity:1,r));for(let s=0;s<HF;s++){const l=`border${PC[s]}Radius`;let c=_w(t,l),d=_w(n,l);if(c===void 0&&d===void 0)continue;c||(c=0),d||(d=0),c===0||d===0||Pw(c)===Pw(d)?(e[l]=Math.max(nr(Dw(c),Dw(d),r),0),(Ns.test(d)||Ns.test(c))&&(e[l]+="%")):e[l]=d}(t.rotate||n.rotate)&&(e.rotate=nr(t.rotate||0,n.rotate||0,r))}function _w(e,t){return e[t]!==void 0?e[t]:e.borderRadius}const WF=_C(0,.5,JT),zF=_C(.5,.95,lr);function _C(e,t,n){return r=>r<e?0:r>t?1:n(Pd(e,t,r))}function Rw(e,t){e.min=t.min,e.max=t.max}function xa(e,t){Rw(e.x,t.x),Rw(e.y,t.y)}function Iw(e,t,n,r,i){return e-=t,e=dp(e,1/n,r),i!==void 0&&(e=dp(e,1/i,r)),e}function YF(e,t=0,n=1,r=.5,i,o=e,s=e){if(Ns.test(t)&&(t=parseFloat(t),t=nr(s.min,s.max,t/100)-s.min),typeof t!="number")return;let l=nr(o.min,o.max,r);e===o&&(l-=t),e.min=Iw(e.min,t,n,l,i),e.max=Iw(e.max,t,n,l,i)}function Aw(e,t,[n,r,i],o,s){YF(e,t[n],t[r],t[i],t.scale,o,s)}const GF=["x","scaleX","originX"],qF=["y","scaleY","originY"];function Mw(e,t,n,r){Aw(e.x,t,GF,n?n.x:void 0,r?r.x:void 0),Aw(e.y,t,qF,n?n.y:void 0,r?r.y:void 0)}function Lw(e){return e.translate===0&&e.scale===1}function RC(e){return Lw(e.x)&&Lw(e.y)}function XF(e,t){return e.x.min===t.x.min&&e.x.max===t.x.max&&e.y.min===t.y.min&&e.y.max===t.y.max}function IC(e,t){return Math.round(e.x.min)===Math.round(t.x.min)&&Math.round(e.x.max)===Math.round(t.x.max)&&Math.round(e.y.min)===Math.round(t.y.min)&&Math.round(e.y.max)===Math.round(t.y.max)}function Nw(e){return ea(e.x)/ea(e.y)}let KF=class{constructor(){this.members=[]}add(t){fy(this.members,t),t.scheduleRender()}remove(t){if(dy(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){const n=this.members[this.members.length-1];n&&this.promote(n)}}relegate(t){const n=this.members.findIndex(i=>t===i);if(n===0)return!1;let r;for(let i=n;i>=0;i--){const o=this.members[i];if(o.isPresent!==!1){r=o;break}}return r?(this.promote(r),!0):!1}promote(t,n){const r=this.lead;if(t!==r&&(this.prevLead=r,this.lead=t,t.show(),r)){r.instance&&r.scheduleRender(),t.scheduleRender(),t.resumeFrom=r,n&&(t.resumeFrom.preserveOpacity=!0),r.snapshot&&(t.snapshot=r.snapshot,t.snapshot.latestValues=r.animationValues||r.latestValues),t.root&&t.root.isUpdating&&(t.isLayoutDirty=!0);const{crossfade:i}=t.options;i===!1&&r.hide()}}exitAnimationComplete(){this.members.forEach(t=>{const{options:n,resumingFrom:r}=t;n.onExitComplete&&n.onExitComplete(),r&&r.options.onExitComplete&&r.options.onExitComplete()})}scheduleRender(){this.members.forEach(t=>{t.instance&&t.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}};function Fw(e,t,n){let r="";const i=e.x.translate/t.x,o=e.y.translate/t.y;if((i||o)&&(r=`translate3d(${i}px, ${o}px, 0) `),(t.x!==1||t.y!==1)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),n){const{rotate:c,rotateX:d,rotateY:v}=n;c&&(r+=`rotate(${c}deg) `),d&&(r+=`rotateX(${d}deg) `),v&&(r+=`rotateY(${v}deg) `)}const s=e.x.scale*t.x,l=e.y.scale*t.y;return(s!==1||l!==1)&&(r+=`scale(${s}, ${l})`),r||"none"}const ZF=(e,t)=>e.depth-t.depth;let JF=class{constructor(){this.children=[],this.isDirty=!1}add(t){fy(this.children,t),this.isDirty=!0}remove(t){dy(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(ZF),this.isDirty=!1,this.children.forEach(t)}};function QF(e,t){const n=performance.now(),r=({timestamp:i})=>{const o=i-n;o>=t&&(Iu(r),e(o-t))};return Hn.read(r,!0),()=>Iu(r)}function ej(e){window.MotionDebug&&window.MotionDebug.record(e)}function tj(e){return e instanceof SVGElement&&e.tagName!=="svg"}function nj(e,t,n){const r=Do(e)?e:Rf(e);return r.start(cy("",r,t,n)),r.animation}const jw=["","X","Y","Z"],rj={visibility:"hidden"},Bw=1e3;let ij=0;const Sc={type:"projectionFrame",totalNodes:0,resolvedTargetDeltas:0,recalculatedProjection:0};function AC({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:i}){return class{constructor(s={},l=t==null?void 0:t()){this.id=ij++,this.animationId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.updateScheduled=!1,this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,Sc.totalNodes=Sc.resolvedTargetDeltas=Sc.recalculatedProjection=0,this.nodes.forEach(sj),this.nodes.forEach(dj),this.nodes.forEach(hj),this.nodes.forEach(uj),ej(Sc)},this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=s,this.root=l?l.root||l:this,this.path=l?[...l.path,l]:[],this.parent=l,this.depth=l?l.depth+1:0;for(let c=0;c<this.path.length;c++)this.path[c].shouldResetTransform=!0;this.root===this&&(this.nodes=new JF)}addEventListener(s,l){return this.eventHandlers.has(s)||this.eventHandlers.set(s,new hy),this.eventHandlers.get(s).add(l)}notifyListeners(s,...l){const c=this.eventHandlers.get(s);c&&c.notify(...l)}hasListeners(s){return this.eventHandlers.has(s)}mount(s,l=this.root.hasTreeAnimated){if(this.instance)return;this.isSVG=tj(s),this.instance=s;const{layoutId:c,layout:d,visualElement:v}=this.options;if(v&&!v.current&&v.mount(s),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),l&&(d||c)&&(this.isLayoutDirty=!0),e){let p;const S=()=>this.root.updateBlockedByResize=!1;e(s,()=>{this.root.updateBlockedByResize=!0,p&&p(),p=QF(S,250),Hh.hasAnimatedSinceResize&&(Hh.hasAnimatedSinceResize=!1,this.nodes.forEach(Vw))})}c&&this.root.registerSharedNode(c,this),this.options.animate!==!1&&v&&(c||d)&&this.addEventListener("didUpdate",({delta:p,hasLayoutChanged:S,hasRelativeTargetChanged:T,layout:_})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const R=this.options.transition||v.getDefaultTransition()||yj,{onLayoutAnimationStart:L,onLayoutAnimationComplete:I}=v.getProps(),U=!this.targetLayout||!IC(this.targetLayout,_)||T,z=!S&&T;if(this.options.layoutRoot||this.resumeFrom&&this.resumeFrom.instance||z||S&&(U||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0),this.setAnimationOrigin(p,z);const re={...ly(R,"layout"),onPlay:L,onComplete:I};(v.shouldReduceMotion||this.options.layoutRoot)&&(re.delay=0,re.type=!1),this.startAnimation(re)}else S||Vw(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=_})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const s=this.getStack();s&&s.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,Iu(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(pj),this.animationId++)}getTransformTemplate(){const{visualElement:s}=this.options;return s&&s.getProps().transformTemplate}willUpdate(s=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let v=0;v<this.path.length;v++){const p=this.path[v];p.shouldResetTransform=!0,p.updateScroll("snapshot"),p.options.layoutRoot&&p.willUpdate(!1)}const{layoutId:l,layout:c}=this.options;if(l===void 0&&!c)return;const d=this.getTransformTemplate();this.prevTransformTemplateValue=d?d(this.latestValues,""):void 0,this.updateSnapshot(),s&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){this.unblockUpdate(),this.clearAllSnapshots(),this.nodes.forEach($w);return}this.isUpdating||this.nodes.forEach(cj),this.isUpdating=!1,this.nodes.forEach(fj),this.nodes.forEach(oj),this.nodes.forEach(aj),this.clearAllSnapshots();const l=performance.now();Li.delta=Dl(0,1e3/60,l-Li.timestamp),Li.timestamp=l,Li.isProcessing=!0,jg.update.process(Li),jg.preRender.process(Li),jg.render.process(Li),Li.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,queueMicrotask(()=>this.update()))}clearAllSnapshots(){this.nodes.forEach(lj),this.sharedNodes.forEach(gj)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,Hn.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){Hn.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure())}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let c=0;c<this.path.length;c++)this.path[c].updateScroll();const s=this.layout;this.layout=this.measure(!1),this.layoutCorrected=Dr(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);const{visualElement:l}=this.options;l&&l.notify("LayoutMeasure",this.layout.layoutBox,s?s.layoutBox:void 0)}updateScroll(s="measure"){let l=!!(this.options.layoutScroll&&this.instance);this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===s&&(l=!1),l&&(this.scroll={animationId:this.root.animationId,phase:s,isRoot:r(this.instance),offset:n(this.instance)})}resetTransform(){if(!i)return;const s=this.isLayoutDirty||this.shouldResetTransform,l=this.projectionDelta&&!RC(this.projectionDelta),c=this.getTransformTemplate(),d=c?c(this.latestValues,""):void 0,v=d!==this.prevTransformTemplateValue;s&&(l||xc(this.latestValues)||v)&&(i(this.instance,d),this.shouldResetTransform=!1,this.scheduleRender())}measure(s=!0){const l=this.measurePageBox();let c=this.removeElementScroll(l);return s&&(c=this.removeTransform(c)),bj(c),{animationId:this.root.animationId,measuredBox:l,layoutBox:c,latestValues:{},source:this.id}}measurePageBox(){const{visualElement:s}=this.options;if(!s)return Dr();const l=s.measureViewportBox(),{scroll:c}=this.root;return c&&(ml(l.x,c.offset.x),ml(l.y,c.offset.y)),l}removeElementScroll(s){const l=Dr();xa(l,s);for(let c=0;c<this.path.length;c++){const d=this.path[c],{scroll:v,options:p}=d;if(d!==this.root&&v&&p.layoutScroll){if(v.isRoot){xa(l,s);const{scroll:S}=this.root;S&&(ml(l.x,-S.offset.x),ml(l.y,-S.offset.y))}ml(l.x,v.offset.x),ml(l.y,v.offset.y)}}return l}applyTransform(s,l=!1){const c=Dr();xa(c,s);for(let d=0;d<this.path.length;d++){const v=this.path[d];!l&&v.options.layoutScroll&&v.scroll&&v!==v.root&&Cf(c,{x:-v.scroll.offset.x,y:-v.scroll.offset.y}),xc(v.latestValues)&&Cf(c,v.latestValues)}return xc(this.latestValues)&&Cf(c,this.latestValues),c}removeTransform(s){const l=Dr();xa(l,s);for(let c=0;c<this.path.length;c++){const d=this.path[c];if(!d.instance||!xc(d.latestValues))continue;Qv(d.latestValues)&&d.updateSnapshot();const v=Dr(),p=d.measurePageBox();xa(v,p),Mw(l,d.latestValues,d.snapshot?d.snapshot.layoutBox:void 0,v)}return xc(this.latestValues)&&Mw(l,this.latestValues),l}setTargetDelta(s){this.targetDelta=s,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(s){this.options={...this.options,...s,crossfade:s.crossfade!==void 0?s.crossfade:!0}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==Li.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(s=!1){var l;const c=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=c.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=c.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=c.isSharedProjectionDirty);const d=!!this.resumingFrom||this!==c;if(!(s||d&&this.isSharedProjectionDirty||this.isProjectionDirty||!((l=this.parent)===null||l===void 0)&&l.isProjectionDirty||this.attemptToResolveRelativeTarget))return;const{layout:p,layoutId:S}=this.options;if(!(!this.layout||!(p||S))){if(this.resolvedRelativeTargetAt=Li.timestamp,!this.targetDelta&&!this.relativeTarget){const T=this.getClosestProjectingParent();T&&T.layout&&this.animationProgress!==1?(this.relativeParent=T,this.forceRelativeParentToResolveTarget(),this.relativeTarget=Dr(),this.relativeTargetOrigin=Dr(),fd(this.relativeTargetOrigin,this.layout.layoutBox,T.layout.layoutBox),xa(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}if(!(!this.relativeTarget&&!this.targetDelta)){if(this.target||(this.target=Dr(),this.targetWithTransforms=Dr()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),wF(this.target,this.relativeTarget,this.relativeParent.target)):this.targetDelta?(this.resumingFrom?this.target=this.applyTransform(this.layout.layoutBox):xa(this.target,this.layout.layoutBox),EC(this.target,this.targetDelta)):xa(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget){this.attemptToResolveRelativeTarget=!1;const T=this.getClosestProjectingParent();T&&!!T.resumingFrom==!!this.resumingFrom&&!T.options.layoutScroll&&T.target&&this.animationProgress!==1?(this.relativeParent=T,this.forceRelativeParentToResolveTarget(),this.relativeTarget=Dr(),this.relativeTargetOrigin=Dr(),fd(this.relativeTargetOrigin,this.target,T.target),xa(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}Sc.resolvedTargetDeltas++}}}getClosestProjectingParent(){if(!(!this.parent||Qv(this.parent.latestValues)||CC(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}calcProjection(){var s;const l=this.getLead(),c=!!this.resumingFrom||this!==l;let d=!0;if((this.isProjectionDirty||!((s=this.parent)===null||s===void 0)&&s.isProjectionDirty)&&(d=!1),c&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(d=!1),this.resolvedRelativeTargetAt===Li.timestamp&&(d=!1),d)return;const{layout:v,layoutId:p}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(v||p))return;xa(this.layoutCorrected,this.layout.layoutBox);const S=this.treeScale.x,T=this.treeScale.y;PF(this.layoutCorrected,this.treeScale,this.path,c),l.layout&&!l.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(l.target=l.layout.layoutBox);const{target:_}=l;if(!_){this.projectionTransform&&(this.projectionDelta=Tf(),this.projectionTransform="none",this.scheduleRender());return}this.projectionDelta||(this.projectionDelta=Tf(),this.projectionDeltaWithTransform=Tf());const R=this.projectionTransform;cd(this.projectionDelta,this.layoutCorrected,_,this.latestValues),this.projectionTransform=Fw(this.projectionDelta,this.treeScale),(this.projectionTransform!==R||this.treeScale.x!==S||this.treeScale.y!==T)&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",_)),Sc.recalculatedProjection++}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(s=!0){if(this.options.scheduleRender&&this.options.scheduleRender(),s){const l=this.getStack();l&&l.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}setAnimationOrigin(s,l=!1){const c=this.snapshot,d=c?c.latestValues:{},v={...this.latestValues},p=Tf();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!l;const S=Dr(),T=c?c.source:void 0,_=this.layout?this.layout.source:void 0,R=T!==_,L=this.getStack(),I=!L||L.members.length<=1,U=!!(R&&!I&&this.options.crossfade===!0&&!this.path.some(mj));this.animationProgress=0;let z;this.mixTargetDelta=re=>{const Z=re/1e3;Hw(p.x,s.x,Z),Hw(p.y,s.y,Z),this.setTargetDelta(p),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(fd(S,this.layout.layoutBox,this.relativeParent.layout.layoutBox),vj(this.relativeTarget,this.relativeTargetOrigin,S,Z),z&&XF(this.relativeTarget,z)&&(this.isProjectionDirty=!1),z||(z=Dr()),xa(z,this.relativeTarget)),R&&(this.animationValues=v,UF(v,d,this.latestValues,Z,U,I)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=Z},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(s){this.notifyListeners("animationStart"),this.currentAnimation&&this.currentAnimation.stop(),this.resumingFrom&&this.resumingFrom.currentAnimation&&this.resumingFrom.currentAnimation.stop(),this.pendingAnimation&&(Iu(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=Hn.update(()=>{Hh.hasAnimatedSinceResize=!0,this.currentAnimation=nj(0,Bw,{...s,onUpdate:l=>{this.mixTargetDelta(l),s.onUpdate&&s.onUpdate(l)},onComplete:()=>{s.onComplete&&s.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const s=this.getStack();s&&s.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(Bw),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const s=this.getLead();let{targetWithTransforms:l,target:c,layout:d,latestValues:v}=s;if(!(!l||!c||!d)){if(this!==s&&this.layout&&d&&MC(this.options.animationType,this.layout.layoutBox,d.layoutBox)){c=this.target||Dr();const p=ea(this.layout.layoutBox.x);c.x.min=s.target.x.min,c.x.max=c.x.min+p;const S=ea(this.layout.layoutBox.y);c.y.min=s.target.y.min,c.y.max=c.y.min+S}xa(l,c),Cf(l,v),cd(this.projectionDeltaWithTransform,this.layoutCorrected,l,v)}}registerSharedNode(s,l){this.sharedNodes.has(s)||this.sharedNodes.set(s,new KF),this.sharedNodes.get(s).add(l);const d=l.options.initialPromotionConfig;l.promote({transition:d?d.transition:void 0,preserveFollowOpacity:d&&d.shouldPreserveFollowOpacity?d.shouldPreserveFollowOpacity(l):void 0})}isLead(){const s=this.getStack();return s?s.lead===this:!0}getLead(){var s;const{layoutId:l}=this.options;return l?((s=this.getStack())===null||s===void 0?void 0:s.lead)||this:this}getPrevLead(){var s;const{layoutId:l}=this.options;return l?(s=this.getStack())===null||s===void 0?void 0:s.prevLead:void 0}getStack(){const{layoutId:s}=this.options;if(s)return this.root.sharedNodes.get(s)}promote({needsReset:s,transition:l,preserveFollowOpacity:c}={}){const d=this.getStack();d&&d.promote(this,c),s&&(this.projectionDelta=void 0,this.needsReset=!0),l&&this.setOptions({transition:l})}relegate(){const s=this.getStack();return s?s.relegate(this):!1}resetRotation(){const{visualElement:s}=this.options;if(!s)return;let l=!1;const{latestValues:c}=s;if((c.rotate||c.rotateX||c.rotateY||c.rotateZ)&&(l=!0),!l)return;const d={};for(let v=0;v<jw.length;v++){const p="rotate"+jw[v];c[p]&&(d[p]=c[p],s.setStaticValue(p,0))}s.render();for(const v in d)s.setStaticValue(v,d[v]);s.scheduleRender()}getProjectionStyles(s){var l,c;if(!this.instance||this.isSVG)return;if(!this.isVisible)return rj;const d={visibility:""},v=this.getTransformTemplate();if(this.needsReset)return this.needsReset=!1,d.opacity="",d.pointerEvents=Vh(s==null?void 0:s.pointerEvents)||"",d.transform=v?v(this.latestValues,""):"none",d;const p=this.getLead();if(!this.projectionDelta||!this.layout||!p.target){const R={};return this.options.layoutId&&(R.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,R.pointerEvents=Vh(s==null?void 0:s.pointerEvents)||""),this.hasProjected&&!xc(this.latestValues)&&(R.transform=v?v({},""):"none",this.hasProjected=!1),R}const S=p.animationValues||p.latestValues;this.applyTransformsToTarget(),d.transform=Fw(this.projectionDeltaWithTransform,this.treeScale,S),v&&(d.transform=v(S,d.transform));const{x:T,y:_}=this.projectionDelta;d.transformOrigin=`${T.origin*100}% ${_.origin*100}% 0`,p.animationValues?d.opacity=p===this?(c=(l=S.opacity)!==null&&l!==void 0?l:this.latestValues.opacity)!==null&&c!==void 0?c:1:this.preserveOpacity?this.latestValues.opacity:S.opacityExit:d.opacity=p===this?S.opacity!==void 0?S.opacity:"":S.opacityExit!==void 0?S.opacityExit:0;for(const R in op){if(S[R]===void 0)continue;const{correct:L,applyTo:I}=op[R],U=d.transform==="none"?S[R]:L(S[R],p);if(I){const z=I.length;for(let re=0;re<z;re++)d[I[re]]=U}else d[R]=U}return this.options.layoutId&&(d.pointerEvents=p===this?Vh(s==null?void 0:s.pointerEvents)||"":"none"),d}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(s=>{var l;return(l=s.currentAnimation)===null||l===void 0?void 0:l.stop()}),this.root.nodes.forEach($w),this.root.sharedNodes.clear()}}}function oj(e){e.updateLayout()}function aj(e){var t;const n=((t=e.resumeFrom)===null||t===void 0?void 0:t.snapshot)||e.snapshot;if(e.isLead()&&e.layout&&n&&e.hasListeners("didUpdate")){const{layoutBox:r,measuredBox:i}=e.layout,{animationType:o}=e.options,s=n.source!==e.layout.source;o==="size"?Ea(p=>{const S=s?n.measuredBox[p]:n.layoutBox[p],T=ea(S);S.min=r[p].min,S.max=S.min+T}):MC(o,n.layoutBox,r)&&Ea(p=>{const S=s?n.measuredBox[p]:n.layoutBox[p],T=ea(r[p]);S.max=S.min+T,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[p].max=e.relativeTarget[p].min+T)});const l=Tf();cd(l,r,n.layoutBox);const c=Tf();s?cd(c,e.applyTransform(i,!0),n.measuredBox):cd(c,r,n.layoutBox);const d=!RC(l);let v=!1;if(!e.resumeFrom){const p=e.getClosestProjectingParent();if(p&&!p.resumeFrom){const{snapshot:S,layout:T}=p;if(S&&T){const _=Dr();fd(_,n.layoutBox,S.layoutBox);const R=Dr();fd(R,r,T.layoutBox),IC(_,R)||(v=!0),p.options.layoutRoot&&(e.relativeTarget=R,e.relativeTargetOrigin=_,e.relativeParent=p)}}}e.notifyListeners("didUpdate",{layout:r,snapshot:n,delta:c,layoutDelta:l,hasLayoutChanged:d,hasRelativeTargetChanged:v})}else if(e.isLead()){const{onExitComplete:r}=e.options;r&&r()}e.options.transition=void 0}function sj(e){Sc.totalNodes++,e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function uj(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function lj(e){e.clearSnapshot()}function $w(e){e.clearMeasurements()}function cj(e){e.isLayoutDirty=!1}function fj(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function Vw(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function dj(e){e.resolveTargetDelta()}function hj(e){e.calcProjection()}function pj(e){e.resetRotation()}function gj(e){e.removeLeadSnapshot()}function Hw(e,t,n){e.translate=nr(t.translate,0,n),e.scale=nr(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function Uw(e,t,n,r){e.min=nr(t.min,n.min,r),e.max=nr(t.max,n.max,r)}function vj(e,t,n,r){Uw(e.x,t.x,n.x,r),Uw(e.y,t.y,n.y,r)}function mj(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}const yj={duration:.45,ease:[.4,0,.1,1]},Ww=e=>typeof navigator<"u"&&navigator.userAgent.toLowerCase().includes(e),zw=Ww("applewebkit/")&&!Ww("chrome/")?Math.round:lr;function Yw(e){e.min=zw(e.min),e.max=zw(e.max)}function bj(e){Yw(e.x),Yw(e.y)}function MC(e,t,n){return e==="position"||e==="preserve-aspect"&&!Zv(Nw(t),Nw(n),.2)}const wj=AC({attachResizeListener:(e,t)=>ku(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),Xg={current:void 0},LC=AC({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!Xg.current){const e=new wj({});e.mount(window),e.setOptions({layoutScroll:!0}),Xg.current=e}return Xg.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"}),xj={pan:{Feature:FF},drag:{Feature:NF,ProjectionNode:LC,MeasureLayout:DC}},Sj=/var\((--[a-zA-Z0-9-_]+),? ?([a-zA-Z0-9 ()%#.,-]+)?\)/;function Tj(e){const t=Sj.exec(e);if(!t)return[,];const[,n,r]=t;return[n,r]}const Cj=4;function tm(e,t,n=1){is(n<=Cj,`Max CSS variable fallback depth detected in property "${e}". This may indicate a circular fallback dependency.`);const[r,i]=Tj(e);if(!r)return;const o=window.getComputedStyle(t).getPropertyValue(r);if(o){const s=o.trim();return mC(s)?parseFloat(s):s}else return Wv(i)?tm(i,t,n+1):i}function Ej(e,{...t},n){const r=e.current;if(!(r instanceof Element))return{target:t,transitionEnd:n};n&&(n={...n}),e.values.forEach(i=>{const o=i.get();if(!Wv(o))return;const s=tm(o,r);s&&i.set(s)});for(const i in t){const o=t[i];if(!Wv(o))continue;const s=tm(o,r);s&&(t[i]=s,n||(n={}),n[i]===void 0&&(n[i]=o))}return{target:t,transitionEnd:n}}const kj=new Set(["width","height","top","left","right","bottom","x","y","translateX","translateY"]),NC=e=>kj.has(e),Oj=e=>Object.keys(e).some(NC),yh=e=>e===Vc||e===jt,Gw=(e,t)=>parseFloat(e.split(", ")[t]),qw=(e,t)=>(n,{transform:r})=>{if(r==="none"||!r)return 0;const i=r.match(/^matrix3d\((.+)\)$/);if(i)return Gw(i[1],t);{const o=r.match(/^matrix\((.+)\)$/);return o?Gw(o[1],e):0}},Dj=new Set(["x","y","z"]),Pj=$d.filter(e=>!Dj.has(e));function _j(e){const t=[];return Pj.forEach(n=>{const r=e.getValue(n);r!==void 0&&(t.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))}),t.length&&e.render(),t}const If={width:({x:e},{paddingLeft:t="0",paddingRight:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),height:({y:e},{paddingTop:t="0",paddingBottom:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:qw(4,13),y:qw(5,14)};If.translateX=If.x;If.translateY=If.y;const Rj=(e,t,n)=>{const r=t.measureViewportBox(),i=t.current,o=getComputedStyle(i),{display:s}=o,l={};s==="none"&&t.setStaticValue("display",e.display||"block"),n.forEach(d=>{l[d]=If[d](r,o)}),t.render();const c=t.measureViewportBox();return n.forEach(d=>{const v=t.getValue(d);v&&v.jump(l[d]),e[d]=If[d](c,o)}),e},Ij=(e,t,n={},r={})=>{t={...t},r={...r};const i=Object.keys(t).filter(NC);let o=[],s=!1;const l=[];if(i.forEach(c=>{const d=e.getValue(c);if(!e.hasValue(c))return;let v=n[c],p=ed(v);const S=t[c];let T;if(sp(S)){const _=S.length,R=S[0]===null?1:0;v=S[R],p=ed(v);for(let L=R;L<_&&S[L]!==null;L++)T?is(ed(S[L])===T,"All keyframes must be of the same type"):(T=ed(S[L]),is(T===p||yh(p)&&yh(T),"Keyframes must be of the same dimension as the current value"))}else T=ed(S);if(p!==T)if(yh(p)&&yh(T)){const _=d.get();typeof _=="string"&&d.set(parseFloat(_)),typeof S=="string"?t[c]=parseFloat(S):Array.isArray(S)&&T===jt&&(t[c]=S.map(parseFloat))}else p!=null&&p.transform&&(T!=null&&T.transform)&&(v===0||S===0)?v===0?d.set(T.transform(v)):t[c]=p.transform(S):(s||(o=_j(e),s=!0),l.push(c),r[c]=r[c]!==void 0?r[c]:t[c],d.jump(S))}),l.length){const c=l.indexOf("height")>=0?window.pageYOffset:null,d=Rj(t,e,l);return o.length&&o.forEach(([v,p])=>{e.getValue(v).set(p)}),e.render(),Ap&&c!==null&&window.scrollTo({top:c}),{target:d,transitionEnd:r}}else return{target:t,transitionEnd:r}};function Aj(e,t,n,r){return Oj(t)?Ij(e,t,n,r):{target:t,transitionEnd:r}}const Mj=(e,t,n,r)=>{const i=Ej(e,t,r);return t=i.target,r=i.transitionEnd,Aj(e,t,n,r)},nm={current:null},FC={current:!1};function Lj(){if(FC.current=!0,!!Ap)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>nm.current=e.matches;e.addListener(t),t()}else nm.current=!1}function Nj(e,t,n){const{willChange:r}=t;for(const i in t){const o=t[i],s=n[i];if(Do(o))e.addValue(i,o),fp(r)&&r.add(i),process.env.NODE_ENV==="development"&&py(o.version==="10.18.0",`Attempting to mix Framer Motion versions ${o.version} with 10.18.0 may not work as expected.`);else if(Do(s))e.addValue(i,Rf(o,{owner:e})),fp(r)&&r.remove(i);else if(s!==o)if(e.hasValue(i)){const l=e.getValue(i);!l.hasAnimated&&l.set(o)}else{const l=e.getStaticValue(i);e.addValue(i,Rf(l!==void 0?l:o,{owner:e}))}}for(const i in n)t[i]===void 0&&e.removeValue(i);return t}const Xw=new WeakMap,jC=Object.keys(Dd),Fj=jC.length,Kw=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"],jj=Zm.length;class Bj{constructor({parent:t,props:n,presenceContext:r,reducedMotionConfig:i,visualState:o},s={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.scheduleRender=()=>Hn.render(this.render,!1,!0);const{latestValues:l,renderState:c}=o;this.latestValues=l,this.baseTarget={...l},this.initialValues=n.initial?{...l}:{},this.renderState=c,this.parent=t,this.props=n,this.presenceContext=r,this.depth=t?t.depth+1:0,this.reducedMotionConfig=i,this.options=s,this.isControllingVariants=Lp(n),this.isVariantNode=ST(n),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);const{willChange:d,...v}=this.scrapeMotionValuesFromProps(n,{});for(const p in v){const S=v[p];l[p]!==void 0&&Do(S)&&(S.set(l[p],!1),fp(d)&&d.add(p))}}scrapeMotionValuesFromProps(t,n){return{}}mount(t){this.current=t,Xw.set(t,this),this.projection&&!this.projection.instance&&this.projection.mount(t),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((n,r)=>this.bindToMotionValue(r,n)),FC.current||Lj(),this.shouldReduceMotion=this.reducedMotionConfig==="never"?!1:this.reducedMotionConfig==="always"?!0:nm.current,process.env.NODE_ENV!=="production"&&py(this.shouldReduceMotion!==!0,"You have Reduced Motion enabled on your device. Animations may not appear as expected."),this.parent&&this.parent.children.add(this),this.update(this.props,this.presenceContext)}unmount(){Xw.delete(this.current),this.projection&&this.projection.unmount(),Iu(this.notifyUpdate),Iu(this.render),this.valueSubscriptions.forEach(t=>t()),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent&&this.parent.children.delete(this);for(const t in this.events)this.events[t].clear();for(const t in this.features)this.features[t].unmount();this.current=null}bindToMotionValue(t,n){const r=$c.has(t),i=n.on("change",s=>{this.latestValues[t]=s,this.props.onUpdate&&Hn.update(this.notifyUpdate,!1,!0),r&&this.projection&&(this.projection.isTransformDirty=!0)}),o=n.on("renderRequest",this.scheduleRender);this.valueSubscriptions.set(t,()=>{i(),o()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}loadFeatures({children:t,...n},r,i,o){let s,l;if(process.env.NODE_ENV!=="production"&&i&&r){const c="You have rendered a `motion` component within a `LazyMotion` component. This will break tree shaking. Import and render a `m` component instead.";n.ignoreStrict?Ud(!1,c):is(!1,c)}for(let c=0;c<Fj;c++){const d=jC[c],{isEnabled:v,Feature:p,ProjectionNode:S,MeasureLayout:T}=Dd[d];S&&(s=S),v(n)&&(!this.features[d]&&p&&(this.features[d]=new p(this)),T&&(l=T))}if((this.type==="html"||this.type==="svg")&&!this.projection&&s){this.projection=new s(this.latestValues,this.parent&&this.parent.projection);const{layoutId:c,layout:d,drag:v,dragConstraints:p,layoutScroll:S,layoutRoot:T}=n;this.projection.setOptions({layoutId:c,layout:d,alwaysMeasureLayout:!!v||p&&xf(p),visualElement:this,scheduleRender:()=>this.scheduleRender(),animationType:typeof d=="string"?d:"both",initialPromotionConfig:o,layoutScroll:S,layoutRoot:T})}return l}updateFeatures(){for(const t in this.features){const n=this.features[t];n.isMounted?n.update():(n.mount(),n.isMounted=!0)}}triggerBuild(){this.build(this.renderState,this.latestValues,this.options,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):Dr()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,n){this.latestValues[t]=n}makeTargetAnimatable(t,n=!0){return this.makeTargetAnimatableFromInstance(t,this.props,n)}update(t,n){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=n;for(let r=0;r<Kw.length;r++){const i=Kw[r];this.propEventSubscriptions[i]&&(this.propEventSubscriptions[i](),delete this.propEventSubscriptions[i]);const o=t["on"+i];o&&(this.propEventSubscriptions[i]=this.on(i,o))}this.prevMotionValues=Nj(this,this.scrapeMotionValuesFromProps(t,this.prevProps),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(t){return this.props.variants?this.props.variants[t]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}getVariantContext(t=!1){if(t)return this.parent?this.parent.getVariantContext():void 0;if(!this.isControllingVariants){const r=this.parent?this.parent.getVariantContext()||{}:{};return this.props.initial!==void 0&&(r.initial=this.props.initial),r}const n={};for(let r=0;r<jj;r++){const i=Zm[r],o=this.props[i];(Od(o)||o===!1)&&(n[i]=o)}return n}addVariantChild(t){const n=this.getClosestVariantNode();if(n)return n.variantChildren&&n.variantChildren.add(t),()=>n.variantChildren.delete(t)}addValue(t,n){n!==this.values.get(t)&&(this.removeValue(t),this.bindToMotionValue(t,n)),this.values.set(t,n),this.latestValues[t]=n.get()}removeValue(t){this.values.delete(t);const n=this.valueSubscriptions.get(t);n&&(n(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,n){if(this.props.values&&this.props.values[t])return this.props.values[t];let r=this.values.get(t);return r===void 0&&n!==void 0&&(r=Rf(n,{owner:this}),this.addValue(t,r)),r}readValue(t){var n;return this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:(n=this.getBaseTargetFromProps(this.props,t))!==null&&n!==void 0?n:this.readValueFromInstance(this.current,t,this.options)}setBaseTarget(t,n){this.baseTarget[t]=n}getBaseTarget(t){var n;const{initial:r}=this.props,i=typeof r=="string"||typeof r=="object"?(n=iy(this.props,r))===null||n===void 0?void 0:n[t]:void 0;if(r&&i!==void 0)return i;const o=this.getBaseTargetFromProps(this.props,t);return o!==void 0&&!Do(o)?o:this.initialValues[t]!==void 0&&i===void 0?void 0:this.baseTarget[t]}on(t,n){return this.events[t]||(this.events[t]=new hy),this.events[t].add(n)}notify(t,...n){this.events[t]&&this.events[t].notify(...n)}}class BC extends Bj{sortInstanceNodePosition(t,n){return t.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(t,n){return t.style?t.style[n]:void 0}removeValueFromRenderState(t,{vars:n,style:r}){delete n[t],delete r[t]}makeTargetAnimatableFromInstance({transition:t,transitionEnd:n,...r},{transformValues:i},o){let s=tF(r,t||{},this);if(i&&(n&&(n=i(n)),r&&(r=i(r)),s&&(s=i(s))),o){QN(this,r,s);const l=Mj(this,r,s,n);n=l.transitionEnd,r=l.target}return{transition:t,transitionEnd:n,...r}}}function $j(e){return window.getComputedStyle(e)}class Vj extends BC{constructor(){super(...arguments),this.type="html"}readValueFromInstance(t,n){if($c.has(n)){const r=uy(n);return r&&r.default||0}else{const r=$j(t),i=(OT(n)?r.getPropertyValue(n):r[n])||0;return typeof i=="string"?i.trim():i}}measureInstanceViewportBox(t,{transformPagePoint:n}){return kC(t,n)}build(t,n,r,i){Qm(t,n,r,i.transformTemplate)}scrapeMotionValuesFromProps(t,n){return ry(t,n)}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;Do(t)&&(this.childSubscription=t.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}renderInstance(t,n,r,i){AT(t,n,r,i)}}class Hj extends BC{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1}getBaseTargetFromProps(t,n){return t[n]}readValueFromInstance(t,n){if($c.has(n)){const r=uy(n);return r&&r.default||0}return n=MT.has(n)?n:Xm(n),t.getAttribute(n)}measureInstanceViewportBox(){return Dr()}scrapeMotionValuesFromProps(t,n){return NT(t,n)}build(t,n,r,i){ty(t,n,r,this.isSVGTag,i.transformTemplate)}renderInstance(t,n,r,i){LT(t,n,r,i)}mount(t){this.isSVGTag=ny(t.tagName),super.mount(t)}}const Uj=(e,t)=>Jm(e)?new Hj(t,{enableHardwareAcceleration:!1}):new Vj(t,{enableHardwareAcceleration:!0}),Wj={layout:{ProjectionNode:LC,MeasureLayout:DC}},zj={...vF,...j2,...xj,...Wj},$C=YL((e,t)=>E2(e,t,zj,Uj));function Af(){return Af=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Af.apply(this,arguments)}const Yj=Object.freeze(Object.defineProperty({__proto__:null,default:Af},Symbol.toStringTag,{value:"Module"}));function VC(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,Xh(e,t)}var rm=function(e,t){return rm=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,r){n.__proto__=r}||function(n,r){for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(n[i]=r[i])},rm(e,t)};function HC(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");rm(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}var ot=function(){return ot=Object.assign||function(t){for(var n,r=1,i=arguments.length;r<i;r++){n=arguments[r];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(t[o]=n[o])}return t},ot.apply(this,arguments)};function _a(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n}function Gr(e,t){var n=typeof Symbol=="function"&&e[Symbol.iterator];if(!n)return e;var r=n.call(e),i,o=[],s;try{for(;(t===void 0||t-- >0)&&!(i=r.next()).done;)o.push(i.value)}catch(l){s={error:l}}finally{try{i&&!i.done&&(n=r.return)&&n.call(r)}finally{if(s)throw s.error}}return o}function Qo(e,t,n){if(n||arguments.length===2)for(var r=0,i=t.length,o;r<i;r++)(o||!(r in t))&&(o||(o=Array.prototype.slice.call(t,0,r)),o[r]=t[r]);return e.concat(o||Array.prototype.slice.call(t))}/*!
|