@digital-realty/ui-mfe-dcim 16.0.0 → 17.0.0-GP-6771.563680
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/assets/app-Cy93P83f.js +124 -0
- package/dist/index.html +13 -1
- package/dist/locales/en/location.json +7 -2
- package/dist/ui-mfe-dcim.js +1 -1
- package/dist/ui-mfe-html-dcim.js +1 -1
- package/dist/ui-mfe-light-dcim.js +1 -1
- package/package.json +18 -12
- package/dist/assets/app-LS0Pbwzr.js +0 -1027
|
@@ -0,0 +1,124 @@
|
|
|
1
|
+
var CU=Object.defineProperty;var EU=(t,e,r)=>e in t?CU(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r;var qe=(t,e,r)=>EU(t,typeof e!="symbol"?e+"":e,r);import*as ie from"react";import He,{useSyncExternalStore as E0,useState as or,useRef as $t,useCallback as rt,useEffect as ut,useMemo as yr,forwardRef as Cn,useLayoutEffect as Bu,createContext as md,useContext as zu,Component as OU,Fragment as AU,createElement as to,cloneElement as IU,useId as RU}from"react";import*as DU from"react-dom";import MU from"react-dom";import{IxButtonStyled as PU}from"@digital-realty/ix-button/ix-button.js";import"@digital-realty/ix-checkbox/ix-checkbox.js";import"@digital-realty/ix-date-next/ix-date-next.js";import{IxDialogStyled as LU}from"@digital-realty/ix-dialog/ix-dialog.js";import"@digital-realty/ix-divider/ix-divider.js";import"@digital-realty/ix-drawer/ix-drawer.js";import{IxIconStyled as NU}from"@digital-realty/ix-icon/ix-icon.js";import{IxIconButtonStyled as FU}from"@digital-realty/ix-icon-button/ix-icon-button.js";import"@digital-realty/ix-grid/ix-grid.js";import"@digital-realty/ix-progress/ix-progress.js";import{IxSelectStyled as kU}from"@digital-realty/ix-select/ix-select.js";import{IxSelectOptionStyled as jU}from"@digital-realty/ix-select/ix-select-option.js";import"@digital-realty/ix-switch/ix-switch.js";import"@digital-realty/ix-textbox/ix-textbox.js";import{html as $U}from"lit";import{ifDefined as UU}from"lit/directives/if-defined.js";import"@digital-realty/ix-toast/ix-message-toast.js";var pi=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function vi(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function qU(t){if(Object.prototype.hasOwnProperty.call(t,"__esModule"))return t;var e=t.default;if(typeof e=="function"){var r=function n(){return this instanceof n?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};r.prototype=e.prototype}else r={};return Object.defineProperty(r,"__esModule",{value:!0}),Object.keys(t).forEach(function(n){var i=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(r,n,i.get?i:{enumerable:!0,get:function(){return t[n]}})}),r}var gp={exports:{}},Ko={};/**
|
|
2
|
+
* @license React
|
|
3
|
+
* react-jsx-runtime.production.min.js
|
|
4
|
+
*
|
|
5
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
6
|
+
*
|
|
7
|
+
* This source code is licensed under the MIT license found in the
|
|
8
|
+
* LICENSE file in the root directory of this source tree.
|
|
9
|
+
*/var Iw;function HU(){if(Iw)return Ko;Iw=1;var t=He,e=Symbol.for("react.element"),r=Symbol.for("react.fragment"),n=Object.prototype.hasOwnProperty,i=t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,a={key:!0,ref:!0,__self:!0,__source:!0};function s(o,l,c){var d,h={},g=null,m=null;c!==void 0&&(g=""+c),l.key!==void 0&&(g=""+l.key),l.ref!==void 0&&(m=l.ref);for(d in l)n.call(l,d)&&!a.hasOwnProperty(d)&&(h[d]=l[d]);if(o&&o.defaultProps)for(d in l=o.defaultProps,l)h[d]===void 0&&(h[d]=l[d]);return{$$typeof:e,type:o,key:g,ref:m,props:h,_owner:i.current}}return Ko.Fragment=r,Ko.jsx=s,Ko.jsxs=s,Ko}var Rw;function WU(){return Rw||(Rw=1,gp.exports=HU()),gp.exports}var A=WU();function Cf(t,e){return Cf=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,n){return r.__proto__=n,r},Cf(t,e)}function bo(t,e){t.prototype=Object.create(e.prototype),t.prototype.constructor=t,Cf(t,e)}var _o=(function(){function t(){this.listeners=[]}var e=t.prototype;return e.subscribe=function(n){var i=this,a=n||function(){};return this.listeners.push(a),this.onSubscribe(),function(){i.listeners=i.listeners.filter(function(s){return s!==a}),i.onUnsubscribe()}},e.hasListeners=function(){return this.listeners.length>0},e.onSubscribe=function(){},e.onUnsubscribe=function(){},t})();function ot(){return ot=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)({}).hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},ot.apply(null,arguments)}var Ef=typeof window>"u";function Pr(){}function BU(t,e){return typeof t=="function"?t(e):t}function Oy(t){return typeof t=="number"&&t>=0&&t!==1/0}function Of(t){return Array.isArray(t)?t:[t]}function JI(t,e){return Math.max(t+(e||0)-Date.now(),0)}function gf(t,e,r){return Vu(t)?typeof e=="function"?ot({},r,{queryKey:t,queryFn:e}):ot({},e,{queryKey:t}):t}function zU(t,e,r){return Vu(t)?typeof e=="function"?ot({},r,{mutationKey:t,mutationFn:e}):ot({},e,{mutationKey:t}):typeof t=="function"?ot({},e,{mutationFn:t}):ot({},t)}function da(t,e,r){return Vu(t)?[ot({},e,{queryKey:t}),r]:[t||{},e]}function VU(t,e){if(t===!0&&e===!0||t==null&&e==null)return"all";if(t===!1&&e===!1)return"none";var r=t??!e;return r?"active":"inactive"}function Dw(t,e){var r=t.active,n=t.exact,i=t.fetching,a=t.inactive,s=t.predicate,o=t.queryKey,l=t.stale;if(Vu(o)){if(n){if(e.queryHash!==O0(o,e.options))return!1}else if(!Af(e.queryKey,o))return!1}var c=VU(r,a);if(c==="none")return!1;if(c!=="all"){var d=e.isActive();if(c==="active"&&!d||c==="inactive"&&d)return!1}return!(typeof l=="boolean"&&e.isStale()!==l||typeof i=="boolean"&&e.isFetching()!==i||s&&!s(e))}function Mw(t,e){var r=t.exact,n=t.fetching,i=t.predicate,a=t.mutationKey;if(Vu(a)){if(!e.options.mutationKey)return!1;if(r){if(ts(e.options.mutationKey)!==ts(a))return!1}else if(!Af(e.options.mutationKey,a))return!1}return!(typeof n=="boolean"&&e.state.status==="loading"!==n||i&&!i(e))}function O0(t,e){var r=(e==null?void 0:e.queryKeyHashFn)||ts;return r(t)}function ts(t){var e=Of(t);return GU(e)}function GU(t){return JSON.stringify(t,function(e,r){return Ay(r)?Object.keys(r).sort().reduce(function(n,i){return n[i]=r[i],n},{}):r})}function Af(t,e){return QI(Of(t),Of(e))}function QI(t,e){return t===e?!0:typeof t!=typeof e?!1:t&&e&&typeof t=="object"&&typeof e=="object"?!Object.keys(e).some(function(r){return!QI(t[r],e[r])}):!1}function If(t,e){if(t===e)return t;var r=Array.isArray(t)&&Array.isArray(e);if(r||Ay(t)&&Ay(e)){for(var n=r?t.length:Object.keys(t).length,i=r?e:Object.keys(e),a=i.length,s=r?[]:{},o=0,l=0;l<a;l++){var c=r?l:i[l];s[c]=If(t[c],e[c]),s[c]===t[c]&&o++}return n===a&&o===n?t:s}return e}function KU(t,e){if(t&&!e||e&&!t)return!1;for(var r in t)if(t[r]!==e[r])return!1;return!0}function Ay(t){if(!Pw(t))return!1;var e=t.constructor;if(typeof e>"u")return!0;var r=e.prototype;return!(!Pw(r)||!r.hasOwnProperty("isPrototypeOf"))}function Pw(t){return Object.prototype.toString.call(t)==="[object Object]"}function Vu(t){return typeof t=="string"||Array.isArray(t)}function XU(t){return new Promise(function(e){setTimeout(e,t)})}function Lw(t){Promise.resolve().then(t).catch(function(e){return setTimeout(function(){throw e})})}function eR(){if(typeof AbortController=="function")return new AbortController}var YU=(function(t){bo(e,t);function e(){var n;return n=t.call(this)||this,n.setup=function(i){var a;if(!Ef&&((a=window)!=null&&a.addEventListener)){var s=function(){return i()};return window.addEventListener("visibilitychange",s,!1),window.addEventListener("focus",s,!1),function(){window.removeEventListener("visibilitychange",s),window.removeEventListener("focus",s)}}},n}var r=e.prototype;return r.onSubscribe=function(){this.cleanup||this.setEventListener(this.setup)},r.onUnsubscribe=function(){if(!this.hasListeners()){var i;(i=this.cleanup)==null||i.call(this),this.cleanup=void 0}},r.setEventListener=function(i){var a,s=this;this.setup=i,(a=this.cleanup)==null||a.call(this),this.cleanup=i(function(o){typeof o=="boolean"?s.setFocused(o):s.onFocus()})},r.setFocused=function(i){this.focused=i,i&&this.onFocus()},r.onFocus=function(){this.listeners.forEach(function(i){i()})},r.isFocused=function(){return typeof this.focused=="boolean"?this.focused:typeof document>"u"?!0:[void 0,"visible","prerender"].includes(document.visibilityState)},e})(_o),wu=new YU,ZU=(function(t){bo(e,t);function e(){var n;return n=t.call(this)||this,n.setup=function(i){var a;if(!Ef&&((a=window)!=null&&a.addEventListener)){var s=function(){return i()};return window.addEventListener("online",s,!1),window.addEventListener("offline",s,!1),function(){window.removeEventListener("online",s),window.removeEventListener("offline",s)}}},n}var r=e.prototype;return r.onSubscribe=function(){this.cleanup||this.setEventListener(this.setup)},r.onUnsubscribe=function(){if(!this.hasListeners()){var i;(i=this.cleanup)==null||i.call(this),this.cleanup=void 0}},r.setEventListener=function(i){var a,s=this;this.setup=i,(a=this.cleanup)==null||a.call(this),this.cleanup=i(function(o){typeof o=="boolean"?s.setOnline(o):s.onOnline()})},r.setOnline=function(i){this.online=i,i&&this.onOnline()},r.onOnline=function(){this.listeners.forEach(function(i){i()})},r.isOnline=function(){return typeof this.online=="boolean"?this.online:typeof navigator>"u"||typeof navigator.onLine>"u"?!0:navigator.onLine},e})(_o),mf=new ZU;function JU(t){return Math.min(1e3*Math.pow(2,t),3e4)}function Rf(t){return typeof(t==null?void 0:t.cancel)=="function"}var tR=function(e){this.revert=e==null?void 0:e.revert,this.silent=e==null?void 0:e.silent};function vf(t){return t instanceof tR}var rR=function(e){var r=this,n=!1,i,a,s,o;this.abort=e.abort,this.cancel=function(g){return i==null?void 0:i(g)},this.cancelRetry=function(){n=!0},this.continueRetry=function(){n=!1},this.continue=function(){return a==null?void 0:a()},this.failureCount=0,this.isPaused=!1,this.isResolved=!1,this.isTransportCancelable=!1,this.promise=new Promise(function(g,m){s=g,o=m});var l=function(m){r.isResolved||(r.isResolved=!0,e.onSuccess==null||e.onSuccess(m),a==null||a(),s(m))},c=function(m){r.isResolved||(r.isResolved=!0,e.onError==null||e.onError(m),a==null||a(),o(m))},d=function(){return new Promise(function(m){a=m,r.isPaused=!0,e.onPause==null||e.onPause()}).then(function(){a=void 0,r.isPaused=!1,e.onContinue==null||e.onContinue()})},h=function g(){if(!r.isResolved){var m;try{m=e.fn()}catch(v){m=Promise.reject(v)}i=function(b){if(!r.isResolved&&(c(new tR(b)),r.abort==null||r.abort(),Rf(m)))try{m.cancel()}catch{}},r.isTransportCancelable=Rf(m),Promise.resolve(m).then(l).catch(function(v){var b,y;if(!r.isResolved){var x=(b=e.retry)!=null?b:3,w=(y=e.retryDelay)!=null?y:JU,S=typeof w=="function"?w(r.failureCount,v):w,E=x===!0||typeof x=="number"&&r.failureCount<x||typeof x=="function"&&x(r.failureCount,v);if(n||!E){c(v);return}r.failureCount++,e.onFail==null||e.onFail(r.failureCount,v),XU(S).then(function(){if(!wu.isFocused()||!mf.isOnline())return d()}).then(function(){n?c(v):g()})}})}};h()},QU=(function(){function t(){this.queue=[],this.transactions=0,this.notifyFn=function(r){r()},this.batchNotifyFn=function(r){r()}}var e=t.prototype;return e.batch=function(n){var i;this.transactions++;try{i=n()}finally{this.transactions--,this.transactions||this.flush()}return i},e.schedule=function(n){var i=this;this.transactions?this.queue.push(n):Lw(function(){i.notifyFn(n)})},e.batchCalls=function(n){var i=this;return function(){for(var a=arguments.length,s=new Array(a),o=0;o<a;o++)s[o]=arguments[o];i.schedule(function(){n.apply(void 0,s)})}},e.flush=function(){var n=this,i=this.queue;this.queue=[],i.length&&Lw(function(){n.batchNotifyFn(function(){i.forEach(function(a){n.notifyFn(a)})})})},e.setNotifyFunction=function(n){this.notifyFn=n},e.setBatchNotifyFunction=function(n){this.batchNotifyFn=n},t})(),Jt=new QU,nR=console;function Df(){return nR}function eq(t){nR=t}var tq=(function(){function t(r){this.abortSignalConsumed=!1,this.hadObservers=!1,this.defaultOptions=r.defaultOptions,this.setOptions(r.options),this.observers=[],this.cache=r.cache,this.queryKey=r.queryKey,this.queryHash=r.queryHash,this.initialState=r.state||this.getDefaultState(this.options),this.state=this.initialState,this.meta=r.meta,this.scheduleGc()}var e=t.prototype;return e.setOptions=function(n){var i;this.options=ot({},this.defaultOptions,n),this.meta=n==null?void 0:n.meta,this.cacheTime=Math.max(this.cacheTime||0,(i=this.options.cacheTime)!=null?i:300*1e3)},e.setDefaultOptions=function(n){this.defaultOptions=n},e.scheduleGc=function(){var n=this;this.clearGcTimeout(),Oy(this.cacheTime)&&(this.gcTimeout=setTimeout(function(){n.optionalRemove()},this.cacheTime))},e.clearGcTimeout=function(){this.gcTimeout&&(clearTimeout(this.gcTimeout),this.gcTimeout=void 0)},e.optionalRemove=function(){this.observers.length||(this.state.isFetching?this.hadObservers&&this.scheduleGc():this.cache.remove(this))},e.setData=function(n,i){var a,s,o=this.state.data,l=BU(n,o);return(a=(s=this.options).isDataEqual)!=null&&a.call(s,o,l)?l=o:this.options.structuralSharing!==!1&&(l=If(o,l)),this.dispatch({data:l,type:"success",dataUpdatedAt:i==null?void 0:i.updatedAt}),l},e.setState=function(n,i){this.dispatch({type:"setState",state:n,setStateOptions:i})},e.cancel=function(n){var i,a=this.promise;return(i=this.retryer)==null||i.cancel(n),a?a.then(Pr).catch(Pr):Promise.resolve()},e.destroy=function(){this.clearGcTimeout(),this.cancel({silent:!0})},e.reset=function(){this.destroy(),this.setState(this.initialState)},e.isActive=function(){return this.observers.some(function(n){return n.options.enabled!==!1})},e.isFetching=function(){return this.state.isFetching},e.isStale=function(){return this.state.isInvalidated||!this.state.dataUpdatedAt||this.observers.some(function(n){return n.getCurrentResult().isStale})},e.isStaleByTime=function(n){return n===void 0&&(n=0),this.state.isInvalidated||!this.state.dataUpdatedAt||!JI(this.state.dataUpdatedAt,n)},e.onFocus=function(){var n,i=this.observers.find(function(a){return a.shouldFetchOnWindowFocus()});i&&i.refetch(),(n=this.retryer)==null||n.continue()},e.onOnline=function(){var n,i=this.observers.find(function(a){return a.shouldFetchOnReconnect()});i&&i.refetch(),(n=this.retryer)==null||n.continue()},e.addObserver=function(n){this.observers.indexOf(n)===-1&&(this.observers.push(n),this.hadObservers=!0,this.clearGcTimeout(),this.cache.notify({type:"observerAdded",query:this,observer:n}))},e.removeObserver=function(n){this.observers.indexOf(n)!==-1&&(this.observers=this.observers.filter(function(i){return i!==n}),this.observers.length||(this.retryer&&(this.retryer.isTransportCancelable||this.abortSignalConsumed?this.retryer.cancel({revert:!0}):this.retryer.cancelRetry()),this.cacheTime?this.scheduleGc():this.cache.remove(this)),this.cache.notify({type:"observerRemoved",query:this,observer:n}))},e.getObserversCount=function(){return this.observers.length},e.invalidate=function(){this.state.isInvalidated||this.dispatch({type:"invalidate"})},e.fetch=function(n,i){var a=this,s,o,l;if(this.state.isFetching){if(this.state.dataUpdatedAt&&(i!=null&&i.cancelRefetch))this.cancel({silent:!0});else if(this.promise){var c;return(c=this.retryer)==null||c.continueRetry(),this.promise}}if(n&&this.setOptions(n),!this.options.queryFn){var d=this.observers.find(function(w){return w.options.queryFn});d&&this.setOptions(d.options)}var h=Of(this.queryKey),g=eR(),m={queryKey:h,pageParam:void 0,meta:this.meta};Object.defineProperty(m,"signal",{enumerable:!0,get:function(){if(g)return a.abortSignalConsumed=!0,g.signal}});var v=function(){return a.options.queryFn?(a.abortSignalConsumed=!1,a.options.queryFn(m)):Promise.reject("Missing queryFn")},b={fetchOptions:i,options:this.options,queryKey:h,state:this.state,fetchFn:v,meta:this.meta};if((s=this.options.behavior)!=null&&s.onFetch){var y;(y=this.options.behavior)==null||y.onFetch(b)}if(this.revertState=this.state,!this.state.isFetching||this.state.fetchMeta!==((o=b.fetchOptions)==null?void 0:o.meta)){var x;this.dispatch({type:"fetch",meta:(x=b.fetchOptions)==null?void 0:x.meta})}return this.retryer=new rR({fn:b.fetchFn,abort:g==null||(l=g.abort)==null?void 0:l.bind(g),onSuccess:function(S){a.setData(S),a.cache.config.onSuccess==null||a.cache.config.onSuccess(S,a),a.cacheTime===0&&a.optionalRemove()},onError:function(S){vf(S)&&S.silent||a.dispatch({type:"error",error:S}),vf(S)||(a.cache.config.onError==null||a.cache.config.onError(S,a),Df().error(S)),a.cacheTime===0&&a.optionalRemove()},onFail:function(){a.dispatch({type:"failed"})},onPause:function(){a.dispatch({type:"pause"})},onContinue:function(){a.dispatch({type:"continue"})},retry:b.options.retry,retryDelay:b.options.retryDelay}),this.promise=this.retryer.promise,this.promise},e.dispatch=function(n){var i=this;this.state=this.reducer(this.state,n),Jt.batch(function(){i.observers.forEach(function(a){a.onQueryUpdate(n)}),i.cache.notify({query:i,type:"queryUpdated",action:n})})},e.getDefaultState=function(n){var i=typeof n.initialData=="function"?n.initialData():n.initialData,a=typeof n.initialData<"u",s=a?typeof n.initialDataUpdatedAt=="function"?n.initialDataUpdatedAt():n.initialDataUpdatedAt:0,o=typeof i<"u";return{data:i,dataUpdateCount:0,dataUpdatedAt:o?s??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchMeta:null,isFetching:!1,isInvalidated:!1,isPaused:!1,status:o?"success":"idle"}},e.reducer=function(n,i){var a,s;switch(i.type){case"failed":return ot({},n,{fetchFailureCount:n.fetchFailureCount+1});case"pause":return ot({},n,{isPaused:!0});case"continue":return ot({},n,{isPaused:!1});case"fetch":return ot({},n,{fetchFailureCount:0,fetchMeta:(a=i.meta)!=null?a:null,isFetching:!0,isPaused:!1},!n.dataUpdatedAt&&{error:null,status:"loading"});case"success":return ot({},n,{data:i.data,dataUpdateCount:n.dataUpdateCount+1,dataUpdatedAt:(s=i.dataUpdatedAt)!=null?s:Date.now(),error:null,fetchFailureCount:0,isFetching:!1,isInvalidated:!1,isPaused:!1,status:"success"});case"error":var o=i.error;return vf(o)&&o.revert&&this.revertState?ot({},this.revertState):ot({},n,{error:o,errorUpdateCount:n.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:n.fetchFailureCount+1,isFetching:!1,isPaused:!1,status:"error"});case"invalidate":return ot({},n,{isInvalidated:!0});case"setState":return ot({},n,i.state);default:return n}},t})(),rq=(function(t){bo(e,t);function e(n){var i;return i=t.call(this)||this,i.config=n||{},i.queries=[],i.queriesMap={},i}var r=e.prototype;return r.build=function(i,a,s){var o,l=a.queryKey,c=(o=a.queryHash)!=null?o:O0(l,a),d=this.get(c);return d||(d=new tq({cache:this,queryKey:l,queryHash:c,options:i.defaultQueryOptions(a),state:s,defaultOptions:i.getQueryDefaults(l),meta:a.meta}),this.add(d)),d},r.add=function(i){this.queriesMap[i.queryHash]||(this.queriesMap[i.queryHash]=i,this.queries.push(i),this.notify({type:"queryAdded",query:i}))},r.remove=function(i){var a=this.queriesMap[i.queryHash];a&&(i.destroy(),this.queries=this.queries.filter(function(s){return s!==i}),a===i&&delete this.queriesMap[i.queryHash],this.notify({type:"queryRemoved",query:i}))},r.clear=function(){var i=this;Jt.batch(function(){i.queries.forEach(function(a){i.remove(a)})})},r.get=function(i){return this.queriesMap[i]},r.getAll=function(){return this.queries},r.find=function(i,a){var s=da(i,a),o=s[0];return typeof o.exact>"u"&&(o.exact=!0),this.queries.find(function(l){return Dw(o,l)})},r.findAll=function(i,a){var s=da(i,a),o=s[0];return Object.keys(o).length>0?this.queries.filter(function(l){return Dw(o,l)}):this.queries},r.notify=function(i){var a=this;Jt.batch(function(){a.listeners.forEach(function(s){s(i)})})},r.onFocus=function(){var i=this;Jt.batch(function(){i.queries.forEach(function(a){a.onFocus()})})},r.onOnline=function(){var i=this;Jt.batch(function(){i.queries.forEach(function(a){a.onOnline()})})},e})(_o),nq=(function(){function t(r){this.options=ot({},r.defaultOptions,r.options),this.mutationId=r.mutationId,this.mutationCache=r.mutationCache,this.observers=[],this.state=r.state||iR(),this.meta=r.meta}var e=t.prototype;return e.setState=function(n){this.dispatch({type:"setState",state:n})},e.addObserver=function(n){this.observers.indexOf(n)===-1&&this.observers.push(n)},e.removeObserver=function(n){this.observers=this.observers.filter(function(i){return i!==n})},e.cancel=function(){return this.retryer?(this.retryer.cancel(),this.retryer.promise.then(Pr).catch(Pr)):Promise.resolve()},e.continue=function(){return this.retryer?(this.retryer.continue(),this.retryer.promise):this.execute()},e.execute=function(){var n=this,i,a=this.state.status==="loading",s=Promise.resolve();return a||(this.dispatch({type:"loading",variables:this.options.variables}),s=s.then(function(){n.mutationCache.config.onMutate==null||n.mutationCache.config.onMutate(n.state.variables,n)}).then(function(){return n.options.onMutate==null?void 0:n.options.onMutate(n.state.variables)}).then(function(o){o!==n.state.context&&n.dispatch({type:"loading",context:o,variables:n.state.variables})})),s.then(function(){return n.executeMutation()}).then(function(o){i=o,n.mutationCache.config.onSuccess==null||n.mutationCache.config.onSuccess(i,n.state.variables,n.state.context,n)}).then(function(){return n.options.onSuccess==null?void 0:n.options.onSuccess(i,n.state.variables,n.state.context)}).then(function(){return n.options.onSettled==null?void 0:n.options.onSettled(i,null,n.state.variables,n.state.context)}).then(function(){return n.dispatch({type:"success",data:i}),i}).catch(function(o){return n.mutationCache.config.onError==null||n.mutationCache.config.onError(o,n.state.variables,n.state.context,n),Df().error(o),Promise.resolve().then(function(){return n.options.onError==null?void 0:n.options.onError(o,n.state.variables,n.state.context)}).then(function(){return n.options.onSettled==null?void 0:n.options.onSettled(void 0,o,n.state.variables,n.state.context)}).then(function(){throw n.dispatch({type:"error",error:o}),o})})},e.executeMutation=function(){var n=this,i;return this.retryer=new rR({fn:function(){return n.options.mutationFn?n.options.mutationFn(n.state.variables):Promise.reject("No mutationFn found")},onFail:function(){n.dispatch({type:"failed"})},onPause:function(){n.dispatch({type:"pause"})},onContinue:function(){n.dispatch({type:"continue"})},retry:(i=this.options.retry)!=null?i:0,retryDelay:this.options.retryDelay}),this.retryer.promise},e.dispatch=function(n){var i=this;this.state=iq(this.state,n),Jt.batch(function(){i.observers.forEach(function(a){a.onMutationUpdate(n)}),i.mutationCache.notify(i)})},t})();function iR(){return{context:void 0,data:void 0,error:null,failureCount:0,isPaused:!1,status:"idle",variables:void 0}}function iq(t,e){switch(e.type){case"failed":return ot({},t,{failureCount:t.failureCount+1});case"pause":return ot({},t,{isPaused:!0});case"continue":return ot({},t,{isPaused:!1});case"loading":return ot({},t,{context:e.context,data:void 0,error:null,isPaused:!1,status:"loading",variables:e.variables});case"success":return ot({},t,{data:e.data,error:null,status:"success",isPaused:!1});case"error":return ot({},t,{data:void 0,error:e.error,failureCount:t.failureCount+1,isPaused:!1,status:"error"});case"setState":return ot({},t,e.state);default:return t}}var aq=(function(t){bo(e,t);function e(n){var i;return i=t.call(this)||this,i.config=n||{},i.mutations=[],i.mutationId=0,i}var r=e.prototype;return r.build=function(i,a,s){var o=new nq({mutationCache:this,mutationId:++this.mutationId,options:i.defaultMutationOptions(a),state:s,defaultOptions:a.mutationKey?i.getMutationDefaults(a.mutationKey):void 0,meta:a.meta});return this.add(o),o},r.add=function(i){this.mutations.push(i),this.notify(i)},r.remove=function(i){this.mutations=this.mutations.filter(function(a){return a!==i}),i.cancel(),this.notify(i)},r.clear=function(){var i=this;Jt.batch(function(){i.mutations.forEach(function(a){i.remove(a)})})},r.getAll=function(){return this.mutations},r.find=function(i){return typeof i.exact>"u"&&(i.exact=!0),this.mutations.find(function(a){return Mw(i,a)})},r.findAll=function(i){return this.mutations.filter(function(a){return Mw(i,a)})},r.notify=function(i){var a=this;Jt.batch(function(){a.listeners.forEach(function(s){s(i)})})},r.onFocus=function(){this.resumePausedMutations()},r.onOnline=function(){this.resumePausedMutations()},r.resumePausedMutations=function(){var i=this.mutations.filter(function(a){return a.state.isPaused});return Jt.batch(function(){return i.reduce(function(a,s){return a.then(function(){return s.continue().catch(Pr)})},Promise.resolve())})},e})(_o);function sq(){return{onFetch:function(e){e.fetchFn=function(){var r,n,i,a,s,o,l=(r=e.fetchOptions)==null||(n=r.meta)==null?void 0:n.refetchPage,c=(i=e.fetchOptions)==null||(a=i.meta)==null?void 0:a.fetchMore,d=c==null?void 0:c.pageParam,h=(c==null?void 0:c.direction)==="forward",g=(c==null?void 0:c.direction)==="backward",m=((s=e.state.data)==null?void 0:s.pages)||[],v=((o=e.state.data)==null?void 0:o.pageParams)||[],b=eR(),y=b==null?void 0:b.signal,x=v,w=!1,S=e.options.queryFn||function(){return Promise.reject("Missing queryFn")},E=function(ee,J,te,ce){return x=ce?[J].concat(x):[].concat(x,[J]),ce?[te].concat(ee):[].concat(ee,[te])},C=function(ee,J,te,ce){if(w)return Promise.reject("Cancelled");if(typeof te>"u"&&!J&&ee.length)return Promise.resolve(ee);var B={queryKey:e.queryKey,signal:y,pageParam:te,meta:e.meta},ae=S(B),Ce=Promise.resolve(ae).then(function(ve){return E(ee,te,ve,ce)});if(Rf(ae)){var Ae=Ce;Ae.cancel=ae.cancel}return Ce},I;if(!m.length)I=C([]);else if(h){var T=typeof d<"u",D=T?d:Nw(e.options,m);I=C(m,T,D)}else if(g){var P=typeof d<"u",L=P?d:oq(e.options,m);I=C(m,P,L,!0)}else(function(){x=[];var X=typeof e.options.getNextPageParam>"u",ee=l&&m[0]?l(m[0],0,m):!0;I=ee?C([],X,v[0]):Promise.resolve(E([],v[0],m[0]));for(var J=function(B){I=I.then(function(ae){var Ce=l&&m[B]?l(m[B],B,m):!0;if(Ce){var Ae=X?v[B]:Nw(e.options,ae);return C(ae,X,Ae)}return Promise.resolve(E(ae,v[B],m[B]))})},te=1;te<m.length;te++)J(te)})();var F=I.then(function(X){return{pages:X,pageParams:x}}),H=F;return H.cancel=function(){w=!0,b==null||b.abort(),Rf(I)&&I.cancel()},F}}}}function Nw(t,e){return t.getNextPageParam==null?void 0:t.getNextPageParam(e[e.length-1],e)}function oq(t,e){return t.getPreviousPageParam==null?void 0:t.getPreviousPageParam(e[0],e)}var uq=(function(){function t(r){r===void 0&&(r={}),this.queryCache=r.queryCache||new rq,this.mutationCache=r.mutationCache||new aq,this.defaultOptions=r.defaultOptions||{},this.queryDefaults=[],this.mutationDefaults=[]}var e=t.prototype;return e.mount=function(){var n=this;this.unsubscribeFocus=wu.subscribe(function(){wu.isFocused()&&mf.isOnline()&&(n.mutationCache.onFocus(),n.queryCache.onFocus())}),this.unsubscribeOnline=mf.subscribe(function(){wu.isFocused()&&mf.isOnline()&&(n.mutationCache.onOnline(),n.queryCache.onOnline())})},e.unmount=function(){var n,i;(n=this.unsubscribeFocus)==null||n.call(this),(i=this.unsubscribeOnline)==null||i.call(this)},e.isFetching=function(n,i){var a=da(n,i),s=a[0];return s.fetching=!0,this.queryCache.findAll(s).length},e.isMutating=function(n){return this.mutationCache.findAll(ot({},n,{fetching:!0})).length},e.getQueryData=function(n,i){var a;return(a=this.queryCache.find(n,i))==null?void 0:a.state.data},e.getQueriesData=function(n){return this.getQueryCache().findAll(n).map(function(i){var a=i.queryKey,s=i.state,o=s.data;return[a,o]})},e.setQueryData=function(n,i,a){var s=gf(n),o=this.defaultQueryOptions(s);return this.queryCache.build(this,o).setData(i,a)},e.setQueriesData=function(n,i,a){var s=this;return Jt.batch(function(){return s.getQueryCache().findAll(n).map(function(o){var l=o.queryKey;return[l,s.setQueryData(l,i,a)]})})},e.getQueryState=function(n,i){var a;return(a=this.queryCache.find(n,i))==null?void 0:a.state},e.removeQueries=function(n,i){var a=da(n,i),s=a[0],o=this.queryCache;Jt.batch(function(){o.findAll(s).forEach(function(l){o.remove(l)})})},e.resetQueries=function(n,i,a){var s=this,o=da(n,i,a),l=o[0],c=o[1],d=this.queryCache,h=ot({},l,{active:!0});return Jt.batch(function(){return d.findAll(l).forEach(function(g){g.reset()}),s.refetchQueries(h,c)})},e.cancelQueries=function(n,i,a){var s=this,o=da(n,i,a),l=o[0],c=o[1],d=c===void 0?{}:c;typeof d.revert>"u"&&(d.revert=!0);var h=Jt.batch(function(){return s.queryCache.findAll(l).map(function(g){return g.cancel(d)})});return Promise.all(h).then(Pr).catch(Pr)},e.invalidateQueries=function(n,i,a){var s,o,l,c=this,d=da(n,i,a),h=d[0],g=d[1],m=ot({},h,{active:(s=(o=h.refetchActive)!=null?o:h.active)!=null?s:!0,inactive:(l=h.refetchInactive)!=null?l:!1});return Jt.batch(function(){return c.queryCache.findAll(h).forEach(function(v){v.invalidate()}),c.refetchQueries(m,g)})},e.refetchQueries=function(n,i,a){var s=this,o=da(n,i,a),l=o[0],c=o[1],d=Jt.batch(function(){return s.queryCache.findAll(l).map(function(g){return g.fetch(void 0,ot({},c,{meta:{refetchPage:l==null?void 0:l.refetchPage}}))})}),h=Promise.all(d).then(Pr);return c!=null&&c.throwOnError||(h=h.catch(Pr)),h},e.fetchQuery=function(n,i,a){var s=gf(n,i,a),o=this.defaultQueryOptions(s);typeof o.retry>"u"&&(o.retry=!1);var l=this.queryCache.build(this,o);return l.isStaleByTime(o.staleTime)?l.fetch(o):Promise.resolve(l.state.data)},e.prefetchQuery=function(n,i,a){return this.fetchQuery(n,i,a).then(Pr).catch(Pr)},e.fetchInfiniteQuery=function(n,i,a){var s=gf(n,i,a);return s.behavior=sq(),this.fetchQuery(s)},e.prefetchInfiniteQuery=function(n,i,a){return this.fetchInfiniteQuery(n,i,a).then(Pr).catch(Pr)},e.cancelMutations=function(){var n=this,i=Jt.batch(function(){return n.mutationCache.getAll().map(function(a){return a.cancel()})});return Promise.all(i).then(Pr).catch(Pr)},e.resumePausedMutations=function(){return this.getMutationCache().resumePausedMutations()},e.executeMutation=function(n){return this.mutationCache.build(this,n).execute()},e.getQueryCache=function(){return this.queryCache},e.getMutationCache=function(){return this.mutationCache},e.getDefaultOptions=function(){return this.defaultOptions},e.setDefaultOptions=function(n){this.defaultOptions=n},e.setQueryDefaults=function(n,i){var a=this.queryDefaults.find(function(s){return ts(n)===ts(s.queryKey)});a?a.defaultOptions=i:this.queryDefaults.push({queryKey:n,defaultOptions:i})},e.getQueryDefaults=function(n){var i;return n?(i=this.queryDefaults.find(function(a){return Af(n,a.queryKey)}))==null?void 0:i.defaultOptions:void 0},e.setMutationDefaults=function(n,i){var a=this.mutationDefaults.find(function(s){return ts(n)===ts(s.mutationKey)});a?a.defaultOptions=i:this.mutationDefaults.push({mutationKey:n,defaultOptions:i})},e.getMutationDefaults=function(n){var i;return n?(i=this.mutationDefaults.find(function(a){return Af(n,a.mutationKey)}))==null?void 0:i.defaultOptions:void 0},e.defaultQueryOptions=function(n){if(n!=null&&n._defaulted)return n;var i=ot({},this.defaultOptions.queries,this.getQueryDefaults(n==null?void 0:n.queryKey),n,{_defaulted:!0});return!i.queryHash&&i.queryKey&&(i.queryHash=O0(i.queryKey,i)),i},e.defaultQueryObserverOptions=function(n){return this.defaultQueryOptions(n)},e.defaultMutationOptions=function(n){return n!=null&&n._defaulted?n:ot({},this.defaultOptions.mutations,this.getMutationDefaults(n==null?void 0:n.mutationKey),n,{_defaulted:!0})},e.clear=function(){this.queryCache.clear(),this.mutationCache.clear()},t})(),lq=(function(t){bo(e,t);function e(n,i){var a;return a=t.call(this)||this,a.client=n,a.options=i,a.trackedProps=[],a.selectError=null,a.bindMethods(),a.setOptions(i),a}var r=e.prototype;return r.bindMethods=function(){this.remove=this.remove.bind(this),this.refetch=this.refetch.bind(this)},r.onSubscribe=function(){this.listeners.length===1&&(this.currentQuery.addObserver(this),Fw(this.currentQuery,this.options)&&this.executeFetch(),this.updateTimers())},r.onUnsubscribe=function(){this.listeners.length||this.destroy()},r.shouldFetchOnReconnect=function(){return Iy(this.currentQuery,this.options,this.options.refetchOnReconnect)},r.shouldFetchOnWindowFocus=function(){return Iy(this.currentQuery,this.options,this.options.refetchOnWindowFocus)},r.destroy=function(){this.listeners=[],this.clearTimers(),this.currentQuery.removeObserver(this)},r.setOptions=function(i,a){var s=this.options,o=this.currentQuery;if(this.options=this.client.defaultQueryObserverOptions(i),typeof this.options.enabled<"u"&&typeof this.options.enabled!="boolean")throw new Error("Expected enabled to be a boolean");this.options.queryKey||(this.options.queryKey=s.queryKey),this.updateQuery();var l=this.hasListeners();l&&kw(this.currentQuery,o,this.options,s)&&this.executeFetch(),this.updateResult(a),l&&(this.currentQuery!==o||this.options.enabled!==s.enabled||this.options.staleTime!==s.staleTime)&&this.updateStaleTimeout();var c=this.computeRefetchInterval();l&&(this.currentQuery!==o||this.options.enabled!==s.enabled||c!==this.currentRefetchInterval)&&this.updateRefetchInterval(c)},r.getOptimisticResult=function(i){var a=this.client.defaultQueryObserverOptions(i),s=this.client.getQueryCache().build(this.client,a);return this.createResult(s,a)},r.getCurrentResult=function(){return this.currentResult},r.trackResult=function(i,a){var s=this,o={},l=function(d){s.trackedProps.includes(d)||s.trackedProps.push(d)};return Object.keys(i).forEach(function(c){Object.defineProperty(o,c,{configurable:!1,enumerable:!0,get:function(){return l(c),i[c]}})}),(a.useErrorBoundary||a.suspense)&&l("error"),o},r.getNextResult=function(i){var a=this;return new Promise(function(s,o){var l=a.subscribe(function(c){c.isFetching||(l(),c.isError&&(i!=null&&i.throwOnError)?o(c.error):s(c))})})},r.getCurrentQuery=function(){return this.currentQuery},r.remove=function(){this.client.getQueryCache().remove(this.currentQuery)},r.refetch=function(i){return this.fetch(ot({},i,{meta:{refetchPage:i==null?void 0:i.refetchPage}}))},r.fetchOptimistic=function(i){var a=this,s=this.client.defaultQueryObserverOptions(i),o=this.client.getQueryCache().build(this.client,s);return o.fetch().then(function(){return a.createResult(o,s)})},r.fetch=function(i){var a=this;return this.executeFetch(i).then(function(){return a.updateResult(),a.currentResult})},r.executeFetch=function(i){this.updateQuery();var a=this.currentQuery.fetch(this.options,i);return i!=null&&i.throwOnError||(a=a.catch(Pr)),a},r.updateStaleTimeout=function(){var i=this;if(this.clearStaleTimeout(),!(Ef||this.currentResult.isStale||!Oy(this.options.staleTime))){var a=JI(this.currentResult.dataUpdatedAt,this.options.staleTime),s=a+1;this.staleTimeoutId=setTimeout(function(){i.currentResult.isStale||i.updateResult()},s)}},r.computeRefetchInterval=function(){var i;return typeof this.options.refetchInterval=="function"?this.options.refetchInterval(this.currentResult.data,this.currentQuery):(i=this.options.refetchInterval)!=null?i:!1},r.updateRefetchInterval=function(i){var a=this;this.clearRefetchInterval(),this.currentRefetchInterval=i,!(Ef||this.options.enabled===!1||!Oy(this.currentRefetchInterval)||this.currentRefetchInterval===0)&&(this.refetchIntervalId=setInterval(function(){(a.options.refetchIntervalInBackground||wu.isFocused())&&a.executeFetch()},this.currentRefetchInterval))},r.updateTimers=function(){this.updateStaleTimeout(),this.updateRefetchInterval(this.computeRefetchInterval())},r.clearTimers=function(){this.clearStaleTimeout(),this.clearRefetchInterval()},r.clearStaleTimeout=function(){this.staleTimeoutId&&(clearTimeout(this.staleTimeoutId),this.staleTimeoutId=void 0)},r.clearRefetchInterval=function(){this.refetchIntervalId&&(clearInterval(this.refetchIntervalId),this.refetchIntervalId=void 0)},r.createResult=function(i,a){var s=this.currentQuery,o=this.options,l=this.currentResult,c=this.currentResultState,d=this.currentResultOptions,h=i!==s,g=h?i.state:this.currentQueryInitialState,m=h?this.currentResult:this.previousQueryResult,v=i.state,b=v.dataUpdatedAt,y=v.error,x=v.errorUpdatedAt,w=v.isFetching,S=v.status,E=!1,C=!1,I;if(a.optimisticResults){var T=this.hasListeners(),D=!T&&Fw(i,a),P=T&&kw(i,s,a,o);(D||P)&&(w=!0,b||(S="loading"))}if(a.keepPreviousData&&!v.dataUpdateCount&&(m!=null&&m.isSuccess)&&S!=="error")I=m.data,b=m.dataUpdatedAt,S=m.status,E=!0;else if(a.select&&typeof v.data<"u")if(l&&v.data===(c==null?void 0:c.data)&&a.select===this.selectFn)I=this.selectResult;else try{this.selectFn=a.select,I=a.select(v.data),a.structuralSharing!==!1&&(I=If(l==null?void 0:l.data,I)),this.selectResult=I,this.selectError=null}catch(H){Df().error(H),this.selectError=H}else I=v.data;if(typeof a.placeholderData<"u"&&typeof I>"u"&&(S==="loading"||S==="idle")){var L;if(l!=null&&l.isPlaceholderData&&a.placeholderData===(d==null?void 0:d.placeholderData))L=l.data;else if(L=typeof a.placeholderData=="function"?a.placeholderData():a.placeholderData,a.select&&typeof L<"u")try{L=a.select(L),a.structuralSharing!==!1&&(L=If(l==null?void 0:l.data,L)),this.selectError=null}catch(H){Df().error(H),this.selectError=H}typeof L<"u"&&(S="success",I=L,C=!0)}this.selectError&&(y=this.selectError,I=this.selectResult,x=Date.now(),S="error");var F={status:S,isLoading:S==="loading",isSuccess:S==="success",isError:S==="error",isIdle:S==="idle",data:I,dataUpdatedAt:b,error:y,errorUpdatedAt:x,failureCount:v.fetchFailureCount,errorUpdateCount:v.errorUpdateCount,isFetched:v.dataUpdateCount>0||v.errorUpdateCount>0,isFetchedAfterMount:v.dataUpdateCount>g.dataUpdateCount||v.errorUpdateCount>g.errorUpdateCount,isFetching:w,isRefetching:w&&S!=="loading",isLoadingError:S==="error"&&v.dataUpdatedAt===0,isPlaceholderData:C,isPreviousData:E,isRefetchError:S==="error"&&v.dataUpdatedAt!==0,isStale:A0(i,a),refetch:this.refetch,remove:this.remove};return F},r.shouldNotifyListeners=function(i,a){if(!a)return!0;var s=this.options,o=s.notifyOnChangeProps,l=s.notifyOnChangePropsExclusions;if(!o&&!l||o==="tracked"&&!this.trackedProps.length)return!0;var c=o==="tracked"?this.trackedProps:o;return Object.keys(i).some(function(d){var h=d,g=i[h]!==a[h],m=c==null?void 0:c.some(function(b){return b===d}),v=l==null?void 0:l.some(function(b){return b===d});return g&&!v&&(!c||m)})},r.updateResult=function(i){var a=this.currentResult;if(this.currentResult=this.createResult(this.currentQuery,this.options),this.currentResultState=this.currentQuery.state,this.currentResultOptions=this.options,!KU(this.currentResult,a)){var s={cache:!0};(i==null?void 0:i.listeners)!==!1&&this.shouldNotifyListeners(this.currentResult,a)&&(s.listeners=!0),this.notify(ot({},s,i))}},r.updateQuery=function(){var i=this.client.getQueryCache().build(this.client,this.options);if(i!==this.currentQuery){var a=this.currentQuery;this.currentQuery=i,this.currentQueryInitialState=i.state,this.previousQueryResult=this.currentResult,this.hasListeners()&&(a==null||a.removeObserver(this),i.addObserver(this))}},r.onQueryUpdate=function(i){var a={};i.type==="success"?a.onSuccess=!0:i.type==="error"&&!vf(i.error)&&(a.onError=!0),this.updateResult(a),this.hasListeners()&&this.updateTimers()},r.notify=function(i){var a=this;Jt.batch(function(){i.onSuccess?(a.options.onSuccess==null||a.options.onSuccess(a.currentResult.data),a.options.onSettled==null||a.options.onSettled(a.currentResult.data,null)):i.onError&&(a.options.onError==null||a.options.onError(a.currentResult.error),a.options.onSettled==null||a.options.onSettled(void 0,a.currentResult.error)),i.listeners&&a.listeners.forEach(function(s){s(a.currentResult)}),i.cache&&a.client.getQueryCache().notify({query:a.currentQuery,type:"observerResultsUpdated"})})},e})(_o);function cq(t,e){return e.enabled!==!1&&!t.state.dataUpdatedAt&&!(t.state.status==="error"&&e.retryOnMount===!1)}function Fw(t,e){return cq(t,e)||t.state.dataUpdatedAt>0&&Iy(t,e,e.refetchOnMount)}function Iy(t,e,r){if(e.enabled!==!1){var n=typeof r=="function"?r(t):r;return n==="always"||n!==!1&&A0(t,e)}return!1}function kw(t,e,r,n){return r.enabled!==!1&&(t!==e||n.enabled===!1)&&(!r.suspense||t.state.status!=="error")&&A0(t,r)}function A0(t,e){return t.isStaleByTime(e.staleTime)}var fq=(function(t){bo(e,t);function e(n,i){var a;return a=t.call(this)||this,a.client=n,a.setOptions(i),a.bindMethods(),a.updateResult(),a}var r=e.prototype;return r.bindMethods=function(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)},r.setOptions=function(i){this.options=this.client.defaultMutationOptions(i)},r.onUnsubscribe=function(){if(!this.listeners.length){var i;(i=this.currentMutation)==null||i.removeObserver(this)}},r.onMutationUpdate=function(i){this.updateResult();var a={listeners:!0};i.type==="success"?a.onSuccess=!0:i.type==="error"&&(a.onError=!0),this.notify(a)},r.getCurrentResult=function(){return this.currentResult},r.reset=function(){this.currentMutation=void 0,this.updateResult(),this.notify({listeners:!0})},r.mutate=function(i,a){return this.mutateOptions=a,this.currentMutation&&this.currentMutation.removeObserver(this),this.currentMutation=this.client.getMutationCache().build(this.client,ot({},this.options,{variables:typeof i<"u"?i:this.options.variables})),this.currentMutation.addObserver(this),this.currentMutation.execute()},r.updateResult=function(){var i=this.currentMutation?this.currentMutation.state:iR(),a=ot({},i,{isLoading:i.status==="loading",isSuccess:i.status==="success",isError:i.status==="error",isIdle:i.status==="idle",mutate:this.mutate,reset:this.reset});this.currentResult=a},r.notify=function(i){var a=this;Jt.batch(function(){a.mutateOptions&&(i.onSuccess?(a.mutateOptions.onSuccess==null||a.mutateOptions.onSuccess(a.currentResult.data,a.currentResult.variables,a.currentResult.context),a.mutateOptions.onSettled==null||a.mutateOptions.onSettled(a.currentResult.data,null,a.currentResult.variables,a.currentResult.context)):i.onError&&(a.mutateOptions.onError==null||a.mutateOptions.onError(a.currentResult.error,a.currentResult.variables,a.currentResult.context),a.mutateOptions.onSettled==null||a.mutateOptions.onSettled(void 0,a.currentResult.error,a.currentResult.variables,a.currentResult.context))),i.listeners&&a.listeners.forEach(function(s){s(a.currentResult)})})},e})(_o),dq=MU.unstable_batchedUpdates;Jt.setBatchNotifyFunction(dq);var hq=console;eq(hq);var jw=He.createContext(void 0),aR=He.createContext(!1);function sR(t){return t&&typeof window<"u"?(window.ReactQueryClientContext||(window.ReactQueryClientContext=jw),window.ReactQueryClientContext):jw}var oR=function(){var e=He.useContext(sR(He.useContext(aR)));if(!e)throw new Error("No QueryClient set, use QueryClientProvider to set one");return e},Nae=function(e){var r=e.client,n=e.contextSharing,i=n===void 0?!1:n,a=e.children;He.useEffect(function(){return r.mount(),function(){r.unmount()}},[r]);var s=sR(i);return He.createElement(aR.Provider,{value:i},He.createElement(s.Provider,{value:r},a))};function pq(){var t=!1;return{clearReset:function(){t=!1},reset:function(){t=!0},isReset:function(){return t}}}var gq=He.createContext(pq()),mq=function(){return He.useContext(gq)};function uR(t,e,r){return typeof e=="function"?e.apply(void 0,r):typeof e=="boolean"?e:!!t}function I0(t,e,r){var n=He.useRef(!1),i=He.useState(0),a=i[1],s=zU(t,e,r),o=oR(),l=He.useRef();l.current?l.current.setOptions(s):l.current=new fq(o,s);var c=l.current.getCurrentResult();He.useEffect(function(){n.current=!0;var h=l.current.subscribe(Jt.batchCalls(function(){n.current&&a(function(g){return g+1})}));return function(){n.current=!1,h()}},[]);var d=He.useCallback(function(h,g){l.current.mutate(h,g).catch(Pr)},[]);if(c.error&&uR(void 0,l.current.options.useErrorBoundary,[c.error]))throw c.error;return ot({},c,{mutate:d,mutateAsync:c.mutate})}function vq(t,e){var r=He.useRef(!1),n=He.useState(0),i=n[1],a=oR(),s=mq(),o=a.defaultQueryObserverOptions(t);o.optimisticResults=!0,o.onError&&(o.onError=Jt.batchCalls(o.onError)),o.onSuccess&&(o.onSuccess=Jt.batchCalls(o.onSuccess)),o.onSettled&&(o.onSettled=Jt.batchCalls(o.onSettled)),o.suspense&&(typeof o.staleTime!="number"&&(o.staleTime=1e3),o.cacheTime===0&&(o.cacheTime=1)),(o.suspense||o.useErrorBoundary)&&(s.isReset()||(o.retryOnMount=!1));var l=He.useState(function(){return new e(a,o)}),c=l[0],d=c.getOptimisticResult(o);if(He.useEffect(function(){r.current=!0,s.clearReset();var h=c.subscribe(Jt.batchCalls(function(){r.current&&i(function(g){return g+1})}));return c.updateResult(),function(){r.current=!1,h()}},[s,c]),He.useEffect(function(){c.setOptions(o,{listeners:!1})},[o,c]),o.suspense&&d.isLoading)throw c.fetchOptimistic(o).then(function(h){var g=h.data;o.onSuccess==null||o.onSuccess(g),o.onSettled==null||o.onSettled(g,null)}).catch(function(h){s.clearReset(),o.onError==null||o.onError(h),o.onSettled==null||o.onSettled(void 0,h)});if(d.isError&&!s.isReset()&&!d.isFetching&&uR(o.suspense,o.useErrorBoundary,[d.error,c.getCurrentQuery()]))throw d.error;return o.notifyOnChangeProps==="tracked"&&(d=c.trackResult(d,o)),d}function Ui(t,e,r){var n=gf(t,e,r);return vq(n,lq)}/**
|
|
10
|
+
* @remix-run/router v1.23.3
|
|
11
|
+
*
|
|
12
|
+
* Copyright (c) Remix Software Inc.
|
|
13
|
+
*
|
|
14
|
+
* This source code is licensed under the MIT license found in the
|
|
15
|
+
* LICENSE.md file in the root directory of this source tree.
|
|
16
|
+
*
|
|
17
|
+
* @license MIT
|
|
18
|
+
*/function Zt(){return Zt=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)({}).hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},Zt.apply(null,arguments)}var vr;(function(t){t.Pop="POP",t.Push="PUSH",t.Replace="REPLACE"})(vr||(vr={}));const $w="popstate";function yq(t){t===void 0&&(t={});function e(n,i){let{pathname:a,search:s,hash:o}=n.location;return Mu("",{pathname:a,search:s,hash:o},i.state&&i.state.usr||null,i.state&&i.state.key||"default")}function r(n,i){return typeof i=="string"?i:cs(i)}return _q(e,r,null,t)}function nt(t,e){if(t===!1||t===null||typeof t>"u")throw new Error(e)}function ls(t,e){if(!t){typeof console<"u"&&console.warn(e);try{throw new Error(e)}catch{}}}function bq(){return Math.random().toString(36).substr(2,8)}function Uw(t,e){return{usr:t.state,key:t.key,idx:e}}function Mu(t,e,r,n){return r===void 0&&(r=null),Zt({pathname:typeof t=="string"?t:t.pathname,search:"",hash:""},typeof e=="string"?Sa(e):e,{state:r,key:e&&e.key||n||bq()})}function cs(t){let{pathname:e="/",search:r="",hash:n=""}=t;return r&&r!=="?"&&(e+=r.charAt(0)==="?"?r:"?"+r),n&&n!=="#"&&(e+=n.charAt(0)==="#"?n:"#"+n),e}function Sa(t){let e={};if(t){let r=t.indexOf("#");r>=0&&(e.hash=t.substr(r),t=t.substr(0,r));let n=t.indexOf("?");n>=0&&(e.search=t.substr(n),t=t.substr(0,n)),t&&(e.pathname=t)}return e}function _q(t,e,r,n){n===void 0&&(n={});let{window:i=document.defaultView,v5Compat:a=!1}=n,s=i.history,o=vr.Pop,l=null,c=d();c==null&&(c=0,s.replaceState(Zt({},s.state,{idx:c}),""));function d(){return(s.state||{idx:null}).idx}function h(){o=vr.Pop;let y=d(),x=y==null?null:y-c;c=y,l&&l({action:o,location:b.location,delta:x})}function g(y,x){o=vr.Push;let w=Mu(b.location,y,x);c=d()+1;let S=Uw(w,c),E=b.createHref(w);try{s.pushState(S,"",E)}catch(C){if(C instanceof DOMException&&C.name==="DataCloneError")throw C;i.location.assign(E)}a&&l&&l({action:o,location:b.location,delta:1})}function m(y,x){o=vr.Replace;let w=Mu(b.location,y,x);c=d();let S=Uw(w,c),E=b.createHref(w);s.replaceState(S,"",E),a&&l&&l({action:o,location:b.location,delta:0})}function v(y){let x=i.location.origin!=="null"?i.location.origin:i.location.href,w=typeof y=="string"?y:cs(y);return w=w.replace(/ $/,"%20"),nt(x,"No window.location.(origin|href) available to create URL for href: "+w),new URL(w,x)}let b={get action(){return o},get location(){return t(i,s)},listen(y){if(l)throw new Error("A history only accepts one active listener");return i.addEventListener($w,h),l=y,()=>{i.removeEventListener($w,h),l=null}},createHref(y){return e(i,y)},createURL:v,encodeLocation(y){let x=v(y);return{pathname:x.pathname,search:x.search,hash:x.hash}},push:g,replace:m,go(y){return s.go(y)}};return b}var kt;(function(t){t.data="data",t.deferred="deferred",t.redirect="redirect",t.error="error"})(kt||(kt={}));const xq=new Set(["lazy","caseSensitive","path","id","index","children"]);function wq(t){return t.index===!0}function Mf(t,e,r,n){return r===void 0&&(r=[]),n===void 0&&(n={}),t.map((i,a)=>{let s=[...r,String(a)],o=typeof i.id=="string"?i.id:s.join("-");if(nt(i.index!==!0||!i.children,"Cannot specify children on an index route"),nt(!n[o],'Found a route id collision on id "'+o+`". Route id's must be globally unique within Data Router usages`),wq(i)){let l=Zt({},i,e(i),{id:o});return n[o]=l,l}else{let l=Zt({},i,e(i),{id:o,children:void 0});return n[o]=l,i.children&&(l.children=Mf(i.children,e,s,n)),l}})}function Ja(t,e,r){return r===void 0&&(r="/"),yf(t,e,r,!1)}function yf(t,e,r,n){let i=typeof e=="string"?Sa(e):e,a=$i(i.pathname||"/",r);if(a==null)return null;let s=lR(t);Sq(s);let o=null,l=Nq(a);for(let c=0;o==null&&c<s.length;++c)o=Pq(s[c],l,n);return o}function Tq(t,e){let{route:r,pathname:n,params:i}=t;return{id:r.id,pathname:n,params:i,data:e[r.id],handle:r.handle}}function lR(t,e,r,n){e===void 0&&(e=[]),r===void 0&&(r=[]),n===void 0&&(n="");let i=(a,s,o)=>{let l={relativePath:o===void 0?a.path||"":o,caseSensitive:a.caseSensitive===!0,childrenIndex:s,route:a};l.relativePath.startsWith("/")&&(nt(l.relativePath.startsWith(n),'Absolute route path "'+l.relativePath+'" nested under path '+('"'+n+'" is not valid. An absolute child route path ')+"must start with the combined path of all its parent routes."),l.relativePath=l.relativePath.slice(n.length));let c=ki([n,l.relativePath]),d=r.concat(l);a.children&&a.children.length>0&&(nt(a.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+c+'".')),lR(a.children,e,d,c)),!(a.path==null&&!a.index)&&e.push({path:c,score:Dq(c,a.index),routesMeta:d})};return t.forEach((a,s)=>{var o;if(a.path===""||!((o=a.path)!=null&&o.includes("?")))i(a,s);else for(let l of cR(a.path))i(a,s,l)}),e}function cR(t){let e=t.split("/");if(e.length===0)return[];let[r,...n]=e,i=r.endsWith("?"),a=r.replace(/\?$/,"");if(n.length===0)return i?[a,""]:[a];let s=cR(n.join("/")),o=[];return o.push(...s.map(l=>l===""?a:[a,l].join("/"))),i&&o.push(...s),o.map(l=>t.startsWith("/")&&l===""?"/":l)}function Sq(t){t.sort((e,r)=>e.score!==r.score?r.score-e.score:Mq(e.routesMeta.map(n=>n.childrenIndex),r.routesMeta.map(n=>n.childrenIndex)))}const Cq=/^:[\w-]+$/,Eq=3,Oq=2,Aq=1,Iq=10,Rq=-2,qw=t=>t==="*";function Dq(t,e){let r=t.split("/"),n=r.length;return r.some(qw)&&(n+=Rq),e&&(n+=Oq),r.filter(i=>!qw(i)).reduce((i,a)=>i+(Cq.test(a)?Eq:a===""?Aq:Iq),n)}function Mq(t,e){return t.length===e.length&&t.slice(0,-1).every((n,i)=>n===e[i])?t[t.length-1]-e[e.length-1]:0}function Pq(t,e,r){r===void 0&&(r=!1);let{routesMeta:n}=t,i={},a="/",s=[];for(let o=0;o<n.length;++o){let l=n[o],c=o===n.length-1,d=a==="/"?e:e.slice(a.length)||"/",h=Pf({path:l.relativePath,caseSensitive:l.caseSensitive,end:c},d),g=l.route;if(!h&&c&&r&&!n[n.length-1].route.index&&(h=Pf({path:l.relativePath,caseSensitive:l.caseSensitive,end:!1},d)),!h)return null;Object.assign(i,h.params),s.push({params:i,pathname:ki([a,h.pathname]),pathnameBase:$q(ki([a,h.pathnameBase])),route:g}),h.pathnameBase!=="/"&&(a=ki([a,h.pathnameBase]))}return s}function Pf(t,e){typeof t=="string"&&(t={path:t,caseSensitive:!1,end:!0});let[r,n]=Lq(t.path,t.caseSensitive,t.end),i=e.match(r);if(!i)return null;let a=i[0],s=a.replace(/(.)\/+$/,"$1"),o=i.slice(1);return{params:n.reduce((c,d,h)=>{let{paramName:g,isOptional:m}=d;if(g==="*"){let b=o[h]||"";s=a.slice(0,a.length-b.length).replace(/(.)\/+$/,"$1")}const v=o[h];return m&&!v?c[g]=void 0:c[g]=(v||"").replace(/%2F/g,"/"),c},{}),pathname:a,pathnameBase:s,pattern:t}}function Lq(t,e,r){e===void 0&&(e=!1),r===void 0&&(r=!0),ls(t==="*"||!t.endsWith("*")||t.endsWith("/*"),'Route path "'+t+'" will be treated as if it were '+('"'+t.replace(/\*$/,"/*")+'" because the `*` character must ')+"always follow a `/` in the pattern. To get rid of this warning, "+('please change the route path to "'+t.replace(/\*$/,"/*")+'".'));let n=[],i="^"+t.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(s,o,l)=>(n.push({paramName:o,isOptional:l!=null}),l?"/?([^\\/]+)?":"/([^\\/]+)"));return t.endsWith("*")?(n.push({paramName:"*"}),i+=t==="*"||t==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):r?i+="\\/*$":t!==""&&t!=="/"&&(i+="(?:(?=\\/|$))"),[new RegExp(i,e?void 0:"i"),n]}function Nq(t){try{return t.split("/").map(e=>decodeURIComponent(e).replace(/\//g,"%2F")).join("/")}catch(e){return ls(!1,'The URL path "'+t+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent '+("encoding ("+e+").")),t}}function $i(t,e){if(e==="/")return t;if(!t.toLowerCase().startsWith(e.toLowerCase()))return null;let r=e.endsWith("/")?e.length-1:e.length,n=t.charAt(r);return n&&n!=="/"?null:t.slice(r)||"/"}const Fq=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,kq=t=>Fq.test(t);function jq(t,e){e===void 0&&(e="/");let{pathname:r,search:n="",hash:i=""}=typeof t=="string"?Sa(t):t,a;if(r)if(kq(r))a=r;else{if(r.includes("//")){let s=r;r=R0(r),ls(!1,"Pathnames cannot have embedded double slashes - normalizing "+(s+" -> "+r))}r.startsWith("/")?a=Hw(r.substring(1),"/"):a=Hw(r,e)}else a=e;return{pathname:a,search:Uq(n),hash:qq(i)}}function Hw(t,e){let r=e.replace(/\/+$/,"").split("/");return t.split("/").forEach(i=>{i===".."?r.length>1&&r.pop():i!=="."&&r.push(i)}),r.length>1?r.join("/"):"/"}function mp(t,e,r,n){return"Cannot include a '"+t+"' character in a manually specified "+("`to."+e+"` field ["+JSON.stringify(n)+"]. Please separate it out to the ")+("`to."+r+"` field. Alternatively you may provide the full path as ")+'a string in <Link to="..."> and the router will parse it for you.'}function fR(t){return t.filter((e,r)=>r===0||e.route.path&&e.route.path.length>0)}function vd(t,e){let r=fR(t);return e?r.map((n,i)=>i===r.length-1?n.pathname:n.pathnameBase):r.map(n=>n.pathnameBase)}function yd(t,e,r,n){n===void 0&&(n=!1);let i;typeof t=="string"?i=Sa(t):(i=Zt({},t),nt(!i.pathname||!i.pathname.includes("?"),mp("?","pathname","search",i)),nt(!i.pathname||!i.pathname.includes("#"),mp("#","pathname","hash",i)),nt(!i.search||!i.search.includes("#"),mp("#","search","hash",i)));let a=t===""||i.pathname==="",s=a?"/":i.pathname,o;if(s==null)o=r;else{let h=e.length-1;if(!n&&s.startsWith("..")){let g=s.split("/");for(;g[0]==="..";)g.shift(),h-=1;i.pathname=g.join("/")}o=h>=0?e[h]:"/"}let l=jq(i,o),c=s&&s!=="/"&&s.endsWith("/"),d=(a||s===".")&&r.endsWith("/");return!l.pathname.endsWith("/")&&(c||d)&&(l.pathname+="/"),l}const R0=t=>t.replace(/\/\/+/g,"/"),ki=t=>R0(t.join("/")),$q=t=>t.replace(/\/+$/,"").replace(/^\/*/,"/"),Uq=t=>!t||t==="?"?"":t.startsWith("?")?t:"?"+t,qq=t=>!t||t==="#"?"":t.startsWith("#")?t:"#"+t;class Lf{constructor(e,r,n,i){i===void 0&&(i=!1),this.status=e,this.statusText=r||"",this.internal=i,n instanceof Error?(this.data=n.toString(),this.error=n):this.data=n}}function Pu(t){return t!=null&&typeof t.status=="number"&&typeof t.statusText=="string"&&typeof t.internal=="boolean"&&"data"in t}const dR=["post","put","patch","delete"],Hq=new Set(dR),Wq=["get",...dR],Bq=new Set(Wq),zq=new Set([301,302,303,307,308]),Vq=new Set([307,308]),vp={state:"idle",location:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},Gq={state:"idle",data:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},Xo={state:"unblocked",proceed:void 0,reset:void 0,location:void 0},D0=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,Kq=t=>({hasErrorBoundary:!!t.hasErrorBoundary}),hR="remix-router-transitions";function Xq(t){const e=t.window?t.window:typeof window<"u"?window:void 0,r=typeof e<"u"&&typeof e.document<"u"&&typeof e.document.createElement<"u",n=!r;nt(t.routes.length>0,"You must provide a non-empty routes array to createRouter");let i;if(t.mapRouteProperties)i=t.mapRouteProperties;else if(t.detectErrorBoundary){let k=t.detectErrorBoundary;i=U=>({hasErrorBoundary:k(U)})}else i=Kq;let a={},s=Mf(t.routes,i,void 0,a),o,l=t.basename||"/",c=t.dataStrategy||Qq,d=t.patchRoutesOnNavigation,h=Zt({v7_fetcherPersist:!1,v7_normalizeFormMethod:!1,v7_partialHydration:!1,v7_prependBasename:!1,v7_relativeSplatPath:!1,v7_skipActionErrorRevalidation:!1},t.future),g=null,m=new Set,v=null,b=null,y=null,x=t.hydrationData!=null,w=Ja(s,t.history.location,l),S=!1,E=null;if(w==null&&!d){let k=sn(404,{pathname:t.history.location.pathname}),{matches:U,route:G}=Qw(s);w=U,E={[G.id]:k}}w&&!t.hydrationData&&hn(w,s,t.history.location.pathname).active&&(w=null);let C;if(w)if(w.some(k=>k.route.lazy))C=!1;else if(!w.some(k=>k.route.loader))C=!0;else if(h.v7_partialHydration){let k=t.hydrationData?t.hydrationData.loaderData:null,U=t.hydrationData?t.hydrationData.errors:null;if(U){let G=w.findIndex(re=>U[re.route.id]!==void 0);C=w.slice(0,G+1).every(re=>!Dy(re.route,k,U))}else C=w.every(G=>!Dy(G.route,k,U))}else C=t.hydrationData!=null;else if(C=!1,w=[],h.v7_partialHydration){let k=hn(null,s,t.history.location.pathname);k.active&&k.matches&&(S=!0,w=k.matches)}let I,T={historyAction:t.history.action,location:t.history.location,matches:w,initialized:C,navigation:vp,restoreScrollPosition:t.hydrationData!=null?!1:null,preventScrollReset:!1,revalidation:"idle",loaderData:t.hydrationData&&t.hydrationData.loaderData||{},actionData:t.hydrationData&&t.hydrationData.actionData||null,errors:t.hydrationData&&t.hydrationData.errors||E,fetchers:new Map,blockers:new Map},D=vr.Pop,P=!1,L,F=!1,H=new Map,X=null,ee=!1,J=!1,te=[],ce=new Set,B=new Map,ae=0,Ce=-1,Ae=new Map,ve=new Set,ct=new Map,Ge=new Map,Le=new Set,Ue=new Map,ht=new Map,We;function Se(){if(g=t.history.listen(k=>{let{action:U,location:G,delta:re}=k;if(We){We(),We=void 0;return}ls(ht.size===0||re!=null,"You are trying to use a blocker on a POP navigation to a location that was not created by @remix-run/router. This will fail silently in production. This can happen if you are navigating outside the router via `window.history.pushState`/`window.location.hash` instead of using router navigation APIs. This can also happen if you are using createHashRouter and the user manually changes the URL.");let oe=Dt({currentLocation:T.location,nextLocation:G,historyAction:U});if(oe&&re!=null){let we=new Promise(De=>{We=De});t.history.go(re*-1),xt(oe,{state:"blocked",location:G,proceed(){xt(oe,{state:"proceeding",proceed:void 0,reset:void 0,location:G}),we.then(()=>t.history.go(re))},reset(){let De=new Map(T.blockers);De.set(oe,Xo),Oe({blockers:De})}});return}return Ne(U,G)}),r){hH(e,H);let k=()=>pH(e,H);e.addEventListener("pagehide",k),X=()=>e.removeEventListener("pagehide",k)}return T.initialized||Ne(vr.Pop,T.location,{initialHydration:!0}),I}function xe(){g&&g(),X&&X(),m.clear(),L&&L.abort(),T.fetchers.forEach((k,U)=>Ur(U)),T.blockers.forEach((k,U)=>at(U))}function Ze(k){return m.add(k),()=>m.delete(k)}function Oe(k,U){U===void 0&&(U={}),T=Zt({},T,k);let G=[],re=[];h.v7_fetcherPersist&&T.fetchers.forEach((oe,we)=>{oe.state==="idle"&&(Le.has(we)?re.push(we):G.push(we))}),Le.forEach(oe=>{!T.fetchers.has(oe)&&!B.has(oe)&&re.push(oe)}),[...m].forEach(oe=>oe(T,{deletedFetchers:re,viewTransitionOpts:U.viewTransitionOpts,flushSync:U.flushSync===!0})),h.v7_fetcherPersist?(G.forEach(oe=>T.fetchers.delete(oe)),re.forEach(oe=>Ur(oe))):re.forEach(oe=>Le.delete(oe))}function Je(k,U,G){var re,oe;let{flushSync:we}=G===void 0?{}:G,De=T.actionData!=null&&T.navigation.formMethod!=null&&Qn(T.navigation.formMethod)&&T.navigation.state==="loading"&&((re=k.state)==null?void 0:re._isRedirect)!==!0,he;U.actionData?Object.keys(U.actionData).length>0?he=U.actionData:he=null:De?he=T.actionData:he=null;let me=U.loaderData?Zw(T.loaderData,U.loaderData,U.matches||[],U.errors):T.loaderData,de=T.blockers;de.size>0&&(de=new Map(de),de.forEach((et,er)=>de.set(er,Xo)));let be=P===!0||T.navigation.formMethod!=null&&Qn(T.navigation.formMethod)&&((oe=k.state)==null?void 0:oe._isRedirect)!==!0;o&&(s=o,o=void 0),ee||D===vr.Pop||(D===vr.Push?t.history.push(k,k.state):D===vr.Replace&&t.history.replace(k,k.state));let Fe;if(D===vr.Pop){let et=H.get(T.location.pathname);et&&et.has(k.pathname)?Fe={currentLocation:T.location,nextLocation:k}:H.has(k.pathname)&&(Fe={currentLocation:k,nextLocation:T.location})}else if(F){let et=H.get(T.location.pathname);et?et.add(k.pathname):(et=new Set([k.pathname]),H.set(T.location.pathname,et)),Fe={currentLocation:T.location,nextLocation:k}}Oe(Zt({},U,{actionData:he,loaderData:me,historyAction:D,location:k,initialized:!0,navigation:vp,revalidation:"idle",restoreScrollPosition:Vi(k,U.matches||T.matches),preventScrollReset:be,blockers:de}),{viewTransitionOpts:Fe,flushSync:we===!0}),D=vr.Pop,P=!1,F=!1,ee=!1,J=!1,te=[]}async function Rt(k,U){if(typeof k=="number"){t.history.go(k);return}let G=Ry(T.location,T.matches,l,h.v7_prependBasename,k,h.v7_relativeSplatPath,U==null?void 0:U.fromRouteId,U==null?void 0:U.relative),{path:re,submission:oe,error:we}=Ww(h.v7_normalizeFormMethod,!1,G,U),De=T.location,he=Mu(T.location,re,U&&U.state);he=Zt({},he,t.history.encodeLocation(he));let me=U&&U.replace!=null?U.replace:void 0,de=vr.Push;me===!0?de=vr.Replace:me===!1||oe!=null&&Qn(oe.formMethod)&&oe.formAction===T.location.pathname+T.location.search&&(de=vr.Replace);let be=U&&"preventScrollReset"in U?U.preventScrollReset===!0:void 0,Fe=(U&&U.flushSync)===!0,et=Dt({currentLocation:De,nextLocation:he,historyAction:de});if(et){xt(et,{state:"blocked",location:he,proceed(){xt(et,{state:"proceeding",proceed:void 0,reset:void 0,location:he}),Rt(k,U)},reset(){let er=new Map(T.blockers);er.set(et,Xo),Oe({blockers:er})}});return}return await Ne(de,he,{submission:oe,pendingError:we,preventScrollReset:be,replace:U&&U.replace,enableViewTransition:U&&U.viewTransition,flushSync:Fe})}function ft(){if(Qe(),Oe({revalidation:"loading"}),T.navigation.state!=="submitting"){if(T.navigation.state==="idle"){Ne(T.historyAction,T.location,{startUninterruptedRevalidation:!0});return}Ne(D||T.historyAction,T.navigation.location,{overrideNavigation:T.navigation,enableViewTransition:F===!0})}}async function Ne(k,U,G){L&&L.abort(),L=null,D=k,ee=(G&&G.startUninterruptedRevalidation)===!0,An(T.location,T.matches),P=(G&&G.preventScrollReset)===!0,F=(G&&G.enableViewTransition)===!0;let re=o||s,oe=G&&G.overrideNavigation,we=G!=null&&G.initialHydration&&T.matches&&T.matches.length>0&&!S?T.matches:Ja(re,U,l),De=(G&&G.flushSync)===!0;if(we&&T.initialized&&!J&&aH(T.location,U)&&!(G&&G.submission&&Qn(G.submission.formMethod))){Je(U,{matches:we},{flushSync:De});return}let he=hn(we,re,U.pathname);if(he.active&&he.matches&&(we=he.matches),!we){let{error:gt,notFoundMatches:st,route:Wt}=ke(U.pathname);Je(U,{matches:st,loaderData:{},errors:{[Wt.id]:gt}},{flushSync:De});return}L=new AbortController;let me=Ws(t.history,U,L.signal,G&&G.submission),de;if(G&&G.pendingError)de=[Qa(we).route.id,{type:kt.error,error:G.pendingError}];else if(G&&G.submission&&Qn(G.submission.formMethod)){let gt=await Nt(me,U,G.submission,we,he.active,{replace:G.replace,flushSync:De});if(gt.shortCircuited)return;if(gt.pendingActionResult){let[st,Wt]=gt.pendingActionResult;if(wn(Wt)&&Pu(Wt.error)&&Wt.error.status===404){L=null,Je(U,{matches:gt.matches,loaderData:{},errors:{[st]:Wt.error}});return}}we=gt.matches||we,de=gt.pendingActionResult,oe=yp(U,G.submission),De=!1,he.active=!1,me=Ws(t.history,me.url,me.signal)}let{shortCircuited:be,matches:Fe,loaderData:et,errors:er}=await Ot(me,U,we,he.active,oe,G&&G.submission,G&&G.fetcherSubmission,G&&G.replace,G&&G.initialHydration===!0,De,de);be||(L=null,Je(U,Zt({matches:Fe||we},Jw(de),{loaderData:et,errors:er})))}async function Nt(k,U,G,re,oe,we){we===void 0&&(we={}),Qe();let De=fH(U,G);if(Oe({navigation:De},{flushSync:we.flushSync===!0}),oe){let de=await br(re,U.pathname,k.signal);if(de.type==="aborted")return{shortCircuited:!0};if(de.type==="error"){let be=Qa(de.partialMatches).route.id;return{matches:de.partialMatches,pendingActionResult:[be,{type:kt.error,error:de.error}]}}else if(de.matches)re=de.matches;else{let{notFoundMatches:be,error:Fe,route:et}=ke(U.pathname);return{matches:be,pendingActionResult:[et.id,{type:kt.error,error:Fe}]}}}let he,me=hu(re,U);if(!me.route.action&&!me.route.lazy)he={type:kt.error,error:sn(405,{method:k.method,pathname:U.pathname,routeId:me.route.id})};else if(he=(await _e("action",T,k,[me],re,null))[me.route.id],k.signal.aborted)return{shortCircuited:!0};if(rs(he)){let de;return we&&we.replace!=null?de=we.replace:de=Kw(he.response.headers.get("Location"),new URL(k.url),l,t.history)===T.location.pathname+T.location.search,await ue(k,he,!0,{submission:G,replace:de}),{shortCircuited:!0}}if(ha(he))throw sn(400,{type:"defer-action"});if(wn(he)){let de=Qa(re,me.route.id);return(we&&we.replace)!==!0&&(D=vr.Push),{matches:re,pendingActionResult:[de.route.id,he]}}return{matches:re,pendingActionResult:[me.route.id,he]}}async function Ot(k,U,G,re,oe,we,De,he,me,de,be){let Fe=oe||yp(U,we),et=we||De||t1(Fe),er=!ee&&(!h.v7_partialHydration||!me);if(re){if(er){let Vt=Lr(be);Oe(Zt({navigation:Fe},Vt!==void 0?{actionData:Vt}:{}),{flushSync:de})}let mt=await br(G,U.pathname,k.signal);if(mt.type==="aborted")return{shortCircuited:!0};if(mt.type==="error"){let Vt=Qa(mt.partialMatches).route.id;return{matches:mt.partialMatches,loaderData:{},errors:{[Vt]:mt.error}}}else if(mt.matches)G=mt.matches;else{let{error:Vt,notFoundMatches:Ki,route:Ma}=ke(U.pathname);return{matches:Ki,loaderData:{},errors:{[Ma.id]:Vt}}}}let gt=o||s,[st,Wt]=zw(t.history,T,G,et,U,h.v7_partialHydration&&me===!0,h.v7_skipActionErrorRevalidation,J,te,ce,Le,ct,ve,gt,l,be);if(qr(mt=>!(G&&G.some(Vt=>Vt.route.id===mt))||st&&st.some(Vt=>Vt.route.id===mt)),Ce=++ae,st.length===0&&Wt.length===0){let mt=zn();return Je(U,Zt({matches:G,loaderData:{},errors:be&&wn(be[1])?{[be[0]]:be[1].error}:null},Jw(be),mt?{fetchers:new Map(T.fetchers)}:{}),{flushSync:de}),{shortCircuited:!0}}if(er){let mt={};if(!re){mt.navigation=Fe;let Vt=Lr(be);Vt!==void 0&&(mt.actionData=Vt)}Wt.length>0&&(mt.fetchers=Yr(Wt)),Oe(mt,{flushSync:de})}Wt.forEach(mt=>{Rr(mt.key),mt.controller&&B.set(mt.key,mt.controller)});let Vn=()=>Wt.forEach(mt=>Rr(mt.key));L&&L.signal.addEventListener("abort",Vn);let{loaderResults:Ia,fetcherResults:Jr}=await Re(T,G,st,Wt,k);if(k.signal.aborted)return{shortCircuited:!0};L&&L.signal.removeEventListener("abort",Vn),Wt.forEach(mt=>B.delete(mt.key));let In=Xl(Ia);if(In)return await ue(k,In.result,!0,{replace:he}),{shortCircuited:!0};if(In=Xl(Jr),In)return ve.add(In.key),await ue(k,In.result,!0,{replace:he}),{shortCircuited:!0};let{loaderData:Gi,errors:Ra}=Yw(T,G,Ia,be,Wt,Jr,Ue);Ue.forEach((mt,Vt)=>{mt.subscribe(Ki=>{(Ki||mt.done)&&Ue.delete(Vt)})}),h.v7_partialHydration&&me&&T.errors&&(Ra=Zt({},T.errors,Ra));let xi=zn(),As=z(Ce),Da=xi||As||Wt.length>0;return Zt({matches:G,loaderData:Gi,errors:Ra},Da?{fetchers:new Map(T.fetchers)}:{})}function Lr(k){if(k&&!wn(k[1]))return{[k[0]]:k[1].data};if(T.actionData)return Object.keys(T.actionData).length===0?null:T.actionData}function Yr(k){return k.forEach(U=>{let G=T.fetchers.get(U.key),re=Yo(void 0,G?G.data:void 0);T.fetchers.set(U.key,re)}),new Map(T.fetchers)}function fr(k,U,G,re){if(n)throw new Error("router.fetch() was called during the server render, but it shouldn't be. You are likely calling a useFetcher() method in the body of your component. Try moving it to a useEffect or a callback.");Rr(k);let oe=(re&&re.flushSync)===!0,we=o||s,De=Ry(T.location,T.matches,l,h.v7_prependBasename,G,h.v7_relativeSplatPath,U,re==null?void 0:re.relative),he=Ja(we,De,l),me=hn(he,we,De);if(me.active&&me.matches&&(he=me.matches),!he){Ct(k,U,sn(404,{pathname:De}),{flushSync:oe});return}let{path:de,submission:be,error:Fe}=Ww(h.v7_normalizeFormMethod,!0,De,re);if(Fe){Ct(k,U,Fe,{flushSync:oe});return}let et=hu(he,de),er=(re&&re.preventScrollReset)===!0;if(be&&Qn(be.formMethod)){W(k,U,de,et,he,me.active,oe,er,be);return}ct.set(k,{routeId:U,path:de}),se(k,U,de,et,he,me.active,oe,er,be)}async function W(k,U,G,re,oe,we,De,he,me){Qe(),ct.delete(k);function de(ar){if(!ar.route.action&&!ar.route.lazy){let Xi=sn(405,{method:me.formMethod,pathname:G,routeId:U});return Ct(k,U,Xi,{flushSync:De}),!0}return!1}if(!we&&de(re))return;let be=T.fetchers.get(k);St(k,dH(me,be),{flushSync:De});let Fe=new AbortController,et=Ws(t.history,G,Fe.signal,me);if(we){let ar=await br(oe,new URL(et.url).pathname,et.signal,k);if(ar.type==="aborted")return;if(ar.type==="error"){Ct(k,U,ar.error,{flushSync:De});return}else if(ar.matches){if(oe=ar.matches,re=hu(oe,G),de(re))return}else{Ct(k,U,sn(404,{pathname:G}),{flushSync:De});return}}B.set(k,Fe);let er=ae,st=(await _e("action",T,et,[re],oe,k))[re.route.id];if(et.signal.aborted){B.get(k)===Fe&&B.delete(k);return}if(h.v7_fetcherPersist&&Le.has(k)){if(rs(st)||wn(st)){St(k,ua(void 0));return}}else{if(rs(st))if(B.delete(k),Ce>er){St(k,ua(void 0));return}else return ve.add(k),St(k,Yo(me)),ue(et,st,!1,{fetcherSubmission:me,preventScrollReset:he});if(wn(st)){Ct(k,U,st.error);return}}if(ha(st))throw sn(400,{type:"defer-action"});let Wt=T.navigation.location||T.location,Vn=Ws(t.history,Wt,Fe.signal),Ia=o||s,Jr=T.navigation.state!=="idle"?Ja(Ia,T.navigation.location,l):T.matches;nt(Jr,"Didn't find any matches after fetcher action");let In=++ae;Ae.set(k,In);let Gi=Yo(me,st.data);T.fetchers.set(k,Gi);let[Ra,xi]=zw(t.history,T,Jr,me,Wt,!1,h.v7_skipActionErrorRevalidation,J,te,ce,Le,ct,ve,Ia,l,[re.route.id,st]);xi.filter(ar=>ar.key!==k).forEach(ar=>{let Xi=ar.key,Mo=T.fetchers.get(Xi),ll=Yo(void 0,Mo?Mo.data:void 0);T.fetchers.set(Xi,ll),Rr(Xi),ar.controller&&B.set(Xi,ar.controller)}),Oe({fetchers:new Map(T.fetchers)});let As=()=>xi.forEach(ar=>Rr(ar.key));Fe.signal.addEventListener("abort",As);let{loaderResults:Da,fetcherResults:mt}=await Re(T,Jr,Ra,xi,Vn);if(Fe.signal.aborted)return;Fe.signal.removeEventListener("abort",As),Ae.delete(k),B.delete(k),xi.forEach(ar=>B.delete(ar.key));let Vt=Xl(Da);if(Vt)return ue(Vn,Vt.result,!1,{preventScrollReset:he});if(Vt=Xl(mt),Vt)return ve.add(Vt.key),ue(Vn,Vt.result,!1,{preventScrollReset:he});let{loaderData:Ki,errors:Ma}=Yw(T,Jr,Da,void 0,xi,mt,Ue);if(T.fetchers.has(k)){let ar=ua(st.data);T.fetchers.set(k,ar)}z(In),T.navigation.state==="loading"&&In>Ce?(nt(D,"Expected pending action"),L&&L.abort(),Je(T.navigation.location,{matches:Jr,loaderData:Ki,errors:Ma,fetchers:new Map(T.fetchers)})):(Oe({errors:Ma,loaderData:Zw(T.loaderData,Ki,Jr,Ma),fetchers:new Map(T.fetchers)}),J=!1)}async function se(k,U,G,re,oe,we,De,he,me){let de=T.fetchers.get(k);St(k,Yo(me,de?de.data:void 0),{flushSync:De});let be=new AbortController,Fe=Ws(t.history,G,be.signal);if(we){let st=await br(oe,new URL(Fe.url).pathname,Fe.signal,k);if(st.type==="aborted")return;if(st.type==="error"){Ct(k,U,st.error,{flushSync:De});return}else if(st.matches)oe=st.matches,re=hu(oe,G);else{Ct(k,U,sn(404,{pathname:G}),{flushSync:De});return}}B.set(k,be);let et=ae,gt=(await _e("loader",T,Fe,[re],oe,k))[re.route.id];if(ha(gt)&&(gt=await M0(gt,Fe.signal,!0)||gt),B.get(k)===be&&B.delete(k),!Fe.signal.aborted){if(Le.has(k)){St(k,ua(void 0));return}if(rs(gt))if(Ce>et){St(k,ua(void 0));return}else{ve.add(k),await ue(Fe,gt,!1,{preventScrollReset:he});return}if(wn(gt)){Ct(k,U,gt.error);return}nt(!ha(gt),"Unhandled fetcher deferred data"),St(k,ua(gt.data))}}async function ue(k,U,G,re){let{submission:oe,fetcherSubmission:we,preventScrollReset:De,replace:he}=re===void 0?{}:re;U.response.headers.has("X-Remix-Revalidate")&&(J=!0);let me=U.response.headers.get("Location");nt(me,"Expected a Location header on the redirect Response"),me=Kw(me,new URL(k.url),l,t.history);let de=Mu(T.location,me,{_isRedirect:!0});if(r){let st=!1;if(U.response.headers.has("X-Remix-Reload-Document"))st=!0;else if(D0.test(me)){const Wt=t.history.createURL(me);st=Wt.origin!==e.location.origin||$i(Wt.pathname,l)==null}if(st){he?e.location.replace(me):e.location.assign(me);return}}L=null;let be=he===!0||U.response.headers.has("X-Remix-Replace")?vr.Replace:vr.Push,{formMethod:Fe,formAction:et,formEncType:er}=T.navigation;!oe&&!we&&Fe&&et&&er&&(oe=t1(T.navigation));let gt=oe||we;if(Vq.has(U.response.status)&>&&Qn(gt.formMethod))await Ne(be,de,{submission:Zt({},gt,{formAction:me}),preventScrollReset:De||P,enableViewTransition:G?F:void 0});else{let st=yp(de,oe);await Ne(be,de,{overrideNavigation:st,fetcherSubmission:we,preventScrollReset:De||P,enableViewTransition:G?F:void 0})}}async function _e(k,U,G,re,oe,we){let De,he={};try{De=await eH(c,k,U,G,re,oe,we,a,i)}catch(me){return re.forEach(de=>{he[de.route.id]={type:kt.error,error:me}}),he}for(let[me,de]of Object.entries(De))if(sH(de)){let be=de.result;he[me]={type:kt.redirect,response:nH(be,G,me,oe,l,h.v7_relativeSplatPath)}}else he[me]=await rH(de);return he}async function Re(k,U,G,re,oe){let we=k.matches,De=_e("loader",k,oe,G,U,null),he=Promise.all(re.map(async be=>{if(be.matches&&be.match&&be.controller){let et=(await _e("loader",k,Ws(t.history,be.path,be.controller.signal),[be.match],be.matches,be.key))[be.match.route.id];return{[be.key]:et}}else return Promise.resolve({[be.key]:{type:kt.error,error:sn(404,{pathname:be.path})}})})),me=await De,de=(await he).reduce((be,Fe)=>Object.assign(be,Fe),{});return await Promise.all([lH(U,me,oe.signal,we,k.loaderData),cH(U,de,re)]),{loaderResults:me,fetcherResults:de}}function Qe(){J=!0,te.push(...qr()),ct.forEach((k,U)=>{B.has(U)&&ce.add(U),Rr(U)})}function St(k,U,G){G===void 0&&(G={}),T.fetchers.set(k,U),Oe({fetchers:new Map(T.fetchers)},{flushSync:(G&&G.flushSync)===!0})}function Ct(k,U,G,re){re===void 0&&(re={});let oe=Qa(T.matches,U);Ur(k),Oe({errors:{[oe.route.id]:G},fetchers:new Map(T.fetchers)},{flushSync:(re&&re.flushSync)===!0})}function Zr(k){return Ge.set(k,(Ge.get(k)||0)+1),Le.has(k)&&Le.delete(k),T.fetchers.get(k)||Gq}function Ur(k){let U=T.fetchers.get(k);B.has(k)&&!(U&&U.state==="loading"&&Ae.has(k))&&Rr(k),ct.delete(k),Ae.delete(k),ve.delete(k),h.v7_fetcherPersist&&Le.delete(k),ce.delete(k),T.fetchers.delete(k)}function _i(k){let U=(Ge.get(k)||0)-1;U<=0?(Ge.delete(k),Le.add(k),h.v7_fetcherPersist||Ur(k)):Ge.set(k,U),Oe({fetchers:new Map(T.fetchers)})}function Rr(k){let U=B.get(k);U&&(U.abort(),B.delete(k))}function En(k){for(let U of k){let G=Zr(U),re=ua(G.data);T.fetchers.set(U,re)}}function zn(){let k=[],U=!1;for(let G of ve){let re=T.fetchers.get(G);nt(re,"Expected fetcher: "+G),re.state==="loading"&&(ve.delete(G),k.push(G),U=!0)}return En(k),U}function z(k){let U=[];for(let[G,re]of Ae)if(re<k){let oe=T.fetchers.get(G);nt(oe,"Expected fetcher: "+G),oe.state==="loading"&&(Rr(G),Ae.delete(G),U.push(G))}return En(U),U.length>0}function V(k,U){let G=T.blockers.get(k)||Xo;return ht.get(k)!==U&&ht.set(k,U),G}function at(k){T.blockers.delete(k),ht.delete(k)}function xt(k,U){let G=T.blockers.get(k)||Xo;nt(G.state==="unblocked"&&U.state==="blocked"||G.state==="blocked"&&U.state==="blocked"||G.state==="blocked"&&U.state==="proceeding"||G.state==="blocked"&&U.state==="unblocked"||G.state==="proceeding"&&U.state==="unblocked","Invalid blocker state transition: "+G.state+" -> "+U.state);let re=new Map(T.blockers);re.set(k,U),Oe({blockers:re})}function Dt(k){let{currentLocation:U,nextLocation:G,historyAction:re}=k;if(ht.size===0)return;ht.size>1&&ls(!1,"A router only supports one blocker at a time");let oe=Array.from(ht.entries()),[we,De]=oe[oe.length-1],he=T.blockers.get(we);if(!(he&&he.state==="proceeding")&&De({currentLocation:U,nextLocation:G,historyAction:re}))return we}function ke(k){let U=sn(404,{pathname:k}),G=o||s,{matches:re,route:oe}=Qw(G);return qr(),{notFoundMatches:re,route:oe,error:U}}function qr(k){let U=[];return Ue.forEach((G,re)=>{(!k||k(re))&&(G.cancel(),U.push(re),Ue.delete(re))}),U}function On(k,U,G){if(v=k,y=U,b=G||null,!x&&T.navigation===vp){x=!0;let re=Vi(T.location,T.matches);re!=null&&Oe({restoreScrollPosition:re})}return()=>{v=null,y=null,b=null}}function Tr(k,U){return b&&b(k,U.map(re=>Tq(re,T.loaderData)))||k.key}function An(k,U){if(v&&y){let G=Tr(k,U);v[G]=y()}}function Vi(k,U){if(v){let G=Tr(k,U),re=v[G];if(typeof re=="number")return re}return null}function hn(k,U,G){if(d)if(k){if(Object.keys(k[0].params).length>0)return{active:!0,matches:yf(U,G,l,!0)}}else return{active:!0,matches:yf(U,G,l,!0)||[]};return{active:!1,matches:null}}async function br(k,U,G,re){if(!d)return{type:"success",matches:k};let oe=k;for(;;){let we=o==null,De=o||s,he=a;try{await d({signal:G,path:U,matches:oe,fetcherKey:re,patch:(be,Fe)=>{G.aborted||Gw(be,Fe,De,he,i)}})}catch(be){return{type:"error",error:be,partialMatches:oe}}finally{we&&!G.aborted&&(s=[...s])}if(G.aborted)return{type:"aborted"};let me=Ja(De,U,l);if(me)return{type:"success",matches:me};let de=yf(De,U,l,!0);if(!de||oe.length===de.length&&oe.every((be,Fe)=>be.route.id===de[Fe].route.id))return{type:"success",matches:null};oe=de}}function Es(k){a={},o=Mf(k,i,void 0,a)}function Os(k,U){let G=o==null;Gw(k,U,o||s,a,i),G&&(s=[...s],Oe({}))}return I={get basename(){return l},get future(){return h},get state(){return T},get routes(){return s},get window(){return e},initialize:Se,subscribe:Ze,enableScrollRestoration:On,navigate:Rt,fetch:fr,revalidate:ft,createHref:k=>t.history.createHref(k),encodeLocation:k=>t.history.encodeLocation(k),getFetcher:Zr,deleteFetcher:_i,dispose:xe,getBlocker:V,deleteBlocker:at,patchRoutes:Os,_internalFetchControllers:B,_internalActiveDeferreds:Ue,_internalSetRoutes:Es},I}function Yq(t){return t!=null&&("formData"in t&&t.formData!=null||"body"in t&&t.body!==void 0)}function Ry(t,e,r,n,i,a,s,o){let l,c;if(s){l=[];for(let h of e)if(l.push(h),h.route.id===s){c=h;break}}else l=e,c=e[e.length-1];let d=yd(i||".",vd(l,a),$i(t.pathname,r)||t.pathname,o==="path");if(i==null&&(d.search=t.search,d.hash=t.hash),(i==null||i===""||i===".")&&c){let h=P0(d.search);if(c.route.index&&!h)d.search=d.search?d.search.replace(/^\?/,"?index&"):"?index";else if(!c.route.index&&h){let g=new URLSearchParams(d.search),m=g.getAll("index");g.delete("index"),m.filter(b=>b).forEach(b=>g.append("index",b));let v=g.toString();d.search=v?"?"+v:""}}return n&&r!=="/"&&(d.pathname=d.pathname==="/"?r:ki([r,d.pathname])),cs(d)}function Ww(t,e,r,n){if(!n||!Yq(n))return{path:r};if(n.formMethod&&!uH(n.formMethod))return{path:r,error:sn(405,{method:n.formMethod})};let i=()=>({path:r,error:sn(400,{type:"invalid-body"})}),a=n.formMethod||"get",s=t?a.toUpperCase():a.toLowerCase(),o=mR(r);if(n.body!==void 0){if(n.formEncType==="text/plain"){if(!Qn(s))return i();let g=typeof n.body=="string"?n.body:n.body instanceof FormData||n.body instanceof URLSearchParams?Array.from(n.body.entries()).reduce((m,v)=>{let[b,y]=v;return""+m+b+"="+y+`
|
|
19
|
+
`},""):String(n.body);return{path:r,submission:{formMethod:s,formAction:o,formEncType:n.formEncType,formData:void 0,json:void 0,text:g}}}else if(n.formEncType==="application/json"){if(!Qn(s))return i();try{let g=typeof n.body=="string"?JSON.parse(n.body):n.body;return{path:r,submission:{formMethod:s,formAction:o,formEncType:n.formEncType,formData:void 0,json:g,text:void 0}}}catch{return i()}}}nt(typeof FormData=="function","FormData is not available in this environment");let l,c;if(n.formData)l=My(n.formData),c=n.formData;else if(n.body instanceof FormData)l=My(n.body),c=n.body;else if(n.body instanceof URLSearchParams)l=n.body,c=Xw(l);else if(n.body==null)l=new URLSearchParams,c=new FormData;else try{l=new URLSearchParams(n.body),c=Xw(l)}catch{return i()}let d={formMethod:s,formAction:o,formEncType:n&&n.formEncType||"application/x-www-form-urlencoded",formData:c,json:void 0,text:void 0};if(Qn(d.formMethod))return{path:r,submission:d};let h=Sa(r);return e&&h.search&&P0(h.search)&&l.append("index",""),h.search="?"+l,{path:cs(h),submission:d}}function Bw(t,e,r){r===void 0&&(r=!1);let n=t.findIndex(i=>i.route.id===e);return n>=0?t.slice(0,r?n+1:n):t}function zw(t,e,r,n,i,a,s,o,l,c,d,h,g,m,v,b){let y=b?wn(b[1])?b[1].error:b[1].data:void 0,x=t.createURL(e.location),w=t.createURL(i),S=r;a&&e.errors?S=Bw(r,Object.keys(e.errors)[0],!0):b&&wn(b[1])&&(S=Bw(r,b[0]));let E=b?b[1].statusCode:void 0,C=s&&E&&E>=400,I=S.filter((D,P)=>{let{route:L}=D;if(L.lazy)return!0;if(L.loader==null)return!1;if(a)return Dy(L,e.loaderData,e.errors);if(Zq(e.loaderData,e.matches[P],D)||l.some(X=>X===D.route.id))return!0;let F=e.matches[P],H=D;return Vw(D,Zt({currentUrl:x,currentParams:F.params,nextUrl:w,nextParams:H.params},n,{actionResult:y,actionStatus:E,defaultShouldRevalidate:C?!1:o||x.pathname+x.search===w.pathname+w.search||x.search!==w.search||pR(F,H)}))}),T=[];return h.forEach((D,P)=>{if(a||!r.some(ee=>ee.route.id===D.routeId)||d.has(P))return;let L=Ja(m,D.path,v);if(!L){T.push({key:P,routeId:D.routeId,path:D.path,matches:null,match:null,controller:null});return}let F=e.fetchers.get(P),H=hu(L,D.path),X=!1;g.has(P)?X=!1:c.has(P)?(c.delete(P),X=!0):F&&F.state!=="idle"&&F.data===void 0?X=o:X=Vw(H,Zt({currentUrl:x,currentParams:e.matches[e.matches.length-1].params,nextUrl:w,nextParams:r[r.length-1].params},n,{actionResult:y,actionStatus:E,defaultShouldRevalidate:C?!1:o})),X&&T.push({key:P,routeId:D.routeId,path:D.path,matches:L,match:H,controller:new AbortController})}),[I,T]}function Dy(t,e,r){if(t.lazy)return!0;if(!t.loader)return!1;let n=e!=null&&e[t.id]!==void 0,i=r!=null&&r[t.id]!==void 0;return!n&&i?!1:typeof t.loader=="function"&&t.loader.hydrate===!0?!0:!n&&!i}function Zq(t,e,r){let n=!e||r.route.id!==e.route.id,i=t[r.route.id]===void 0;return n||i}function pR(t,e){let r=t.route.path;return t.pathname!==e.pathname||r!=null&&r.endsWith("*")&&t.params["*"]!==e.params["*"]}function Vw(t,e){if(t.route.shouldRevalidate){let r=t.route.shouldRevalidate(e);if(typeof r=="boolean")return r}return e.defaultShouldRevalidate}function Gw(t,e,r,n,i){var a;let s;if(t){let c=n[t];nt(c,"No route found to patch children into: routeId = "+t),c.children||(c.children=[]),s=c.children}else s=r;let o=e.filter(c=>!s.some(d=>gR(c,d))),l=Mf(o,i,[t||"_","patch",String(((a=s)==null?void 0:a.length)||"0")],n);s.push(...l)}function gR(t,e){return"id"in t&&"id"in e&&t.id===e.id?!0:t.index===e.index&&t.path===e.path&&t.caseSensitive===e.caseSensitive?(!t.children||t.children.length===0)&&(!e.children||e.children.length===0)?!0:t.children.every((r,n)=>{var i;return(i=e.children)==null?void 0:i.some(a=>gR(r,a))}):!1}async function Jq(t,e,r){if(!t.lazy)return;let n=await t.lazy();if(!t.lazy)return;let i=r[t.id];nt(i,"No route found in manifest");let a={};for(let s in n){let l=i[s]!==void 0&&s!=="hasErrorBoundary";ls(!l,'Route "'+i.id+'" has a static property "'+s+'" defined but its lazy function is also returning a value for this property. '+('The lazy route property "'+s+'" will be ignored.')),!l&&!xq.has(s)&&(a[s]=n[s])}Object.assign(i,a),Object.assign(i,Zt({},e(i),{lazy:void 0}))}async function Qq(t){let{matches:e}=t,r=e.filter(i=>i.shouldLoad);return(await Promise.all(r.map(i=>i.resolve()))).reduce((i,a,s)=>Object.assign(i,{[r[s].route.id]:a}),{})}async function eH(t,e,r,n,i,a,s,o,l,c){let d=a.map(m=>m.route.lazy?Jq(m.route,l,o):void 0),h=a.map((m,v)=>{let b=d[v],y=i.some(w=>w.route.id===m.route.id);return Zt({},m,{shouldLoad:y,resolve:async w=>(w&&n.method==="GET"&&(m.route.lazy||m.route.loader)&&(y=!0),y?tH(e,n,m,b,w,c):Promise.resolve({type:kt.data,result:void 0}))})}),g=await t({matches:h,request:n,params:a[0].params,fetcherKey:s,context:c});try{await Promise.all(d)}catch{}return g}async function tH(t,e,r,n,i,a){let s,o,l=c=>{let d,h=new Promise((v,b)=>d=b);o=()=>d(),e.signal.addEventListener("abort",o);let g=v=>typeof c!="function"?Promise.reject(new Error("You cannot call the handler for a route which defines a boolean "+('"'+t+'" [routeId: '+r.route.id+"]"))):c({request:e,params:r.params,context:a},...v!==void 0?[v]:[]),m=(async()=>{try{return{type:"data",result:await(i?i(b=>g(b)):g())}}catch(v){return{type:"error",result:v}}})();return Promise.race([m,h])};try{let c=r.route[t];if(n)if(c){let d,[h]=await Promise.all([l(c).catch(g=>{d=g}),n]);if(d!==void 0)throw d;s=h}else if(await n,c=r.route[t],c)s=await l(c);else if(t==="action"){let d=new URL(e.url),h=d.pathname+d.search;throw sn(405,{method:e.method,pathname:h,routeId:r.route.id})}else return{type:kt.data,result:void 0};else if(c)s=await l(c);else{let d=new URL(e.url),h=d.pathname+d.search;throw sn(404,{pathname:h})}nt(s.result!==void 0,"You defined "+(t==="action"?"an action":"a loader")+" for route "+('"'+r.route.id+"\" but didn't return anything from your `"+t+"` ")+"function. Please return a value or `null`.")}catch(c){return{type:kt.error,result:c}}finally{o&&e.signal.removeEventListener("abort",o)}return s}async function rH(t){let{result:e,type:r}=t;if(vR(e)){let h;try{let g=e.headers.get("Content-Type");g&&/\bapplication\/json\b/.test(g)?e.body==null?h=null:h=await e.json():h=await e.text()}catch(g){return{type:kt.error,error:g}}return r===kt.error?{type:kt.error,error:new Lf(e.status,e.statusText,h),statusCode:e.status,headers:e.headers}:{type:kt.data,data:h,statusCode:e.status,headers:e.headers}}if(r===kt.error){if(e1(e)){var n,i;if(e.data instanceof Error){var a,s;return{type:kt.error,error:e.data,statusCode:(a=e.init)==null?void 0:a.status,headers:(s=e.init)!=null&&s.headers?new Headers(e.init.headers):void 0}}return{type:kt.error,error:new Lf(((n=e.init)==null?void 0:n.status)||500,void 0,e.data),statusCode:Pu(e)?e.status:void 0,headers:(i=e.init)!=null&&i.headers?new Headers(e.init.headers):void 0}}return{type:kt.error,error:e,statusCode:Pu(e)?e.status:void 0}}if(oH(e)){var o,l;return{type:kt.deferred,deferredData:e,statusCode:(o=e.init)==null?void 0:o.status,headers:((l=e.init)==null?void 0:l.headers)&&new Headers(e.init.headers)}}if(e1(e)){var c,d;return{type:kt.data,data:e.data,statusCode:(c=e.init)==null?void 0:c.status,headers:(d=e.init)!=null&&d.headers?new Headers(e.init.headers):void 0}}return{type:kt.data,data:e}}function nH(t,e,r,n,i,a){let s=t.headers.get("Location");if(nt(s,"Redirects returned/thrown from loaders/actions must have a Location header"),!D0.test(s)){let o=n.slice(0,n.findIndex(l=>l.route.id===r)+1);s=Ry(new URL(e.url),o,i,!0,s,a),t.headers.set("Location",s)}return t}function Kw(t,e,r,n){let i=["about:","blob:","chrome:","chrome-untrusted:","content:","data:","devtools:","file:","filesystem:","javascript:"];if(D0.test(t)){let a=t,s=a.startsWith("//")?new URL(e.protocol+a):new URL(a);if(i.includes(s.protocol))throw new Error("Invalid redirect location");let o=$i(s.pathname,r)!=null;if(s.origin===e.origin&&o)return R0(s.pathname)+s.search+s.hash}try{let a=n.createURL(t);if(i.includes(a.protocol))throw new Error("Invalid redirect location")}catch{}return t}function Ws(t,e,r,n){let i=t.createURL(mR(e)).toString(),a={signal:r};if(n&&Qn(n.formMethod)){let{formMethod:s,formEncType:o}=n;a.method=s.toUpperCase(),o==="application/json"?(a.headers=new Headers({"Content-Type":o}),a.body=JSON.stringify(n.json)):o==="text/plain"?a.body=n.text:o==="application/x-www-form-urlencoded"&&n.formData?a.body=My(n.formData):a.body=n.formData}return new Request(i,a)}function My(t){let e=new URLSearchParams;for(let[r,n]of t.entries())e.append(r,typeof n=="string"?n:n.name);return e}function Xw(t){let e=new FormData;for(let[r,n]of t.entries())e.append(r,n);return e}function iH(t,e,r,n,i){let a={},s=null,o,l=!1,c={},d=r&&wn(r[1])?r[1].error:void 0;return t.forEach(h=>{if(!(h.route.id in e))return;let g=h.route.id,m=e[g];if(nt(!rs(m),"Cannot handle redirect results in processLoaderData"),wn(m)){let v=m.error;d!==void 0&&(v=d,d=void 0),s=s||{};{let b=Qa(t,g);s[b.route.id]==null&&(s[b.route.id]=v)}a[g]=void 0,l||(l=!0,o=Pu(m.error)?m.error.status:500),m.headers&&(c[g]=m.headers)}else ha(m)?(n.set(g,m.deferredData),a[g]=m.deferredData.data,m.statusCode!=null&&m.statusCode!==200&&!l&&(o=m.statusCode),m.headers&&(c[g]=m.headers)):(a[g]=m.data,m.statusCode&&m.statusCode!==200&&!l&&(o=m.statusCode),m.headers&&(c[g]=m.headers))}),d!==void 0&&r&&(s={[r[0]]:d},a[r[0]]=void 0),{loaderData:a,errors:s,statusCode:o||200,loaderHeaders:c}}function Yw(t,e,r,n,i,a,s){let{loaderData:o,errors:l}=iH(e,r,n,s);return i.forEach(c=>{let{key:d,match:h,controller:g}=c,m=a[d];if(nt(m,"Did not find corresponding fetcher result"),!(g&&g.signal.aborted))if(wn(m)){let v=Qa(t.matches,h==null?void 0:h.route.id);l&&l[v.route.id]||(l=Zt({},l,{[v.route.id]:m.error})),t.fetchers.delete(d)}else if(rs(m))nt(!1,"Unhandled fetcher revalidation redirect");else if(ha(m))nt(!1,"Unhandled fetcher deferred data");else{let v=ua(m.data);t.fetchers.set(d,v)}}),{loaderData:o,errors:l}}function Zw(t,e,r,n){let i=Zt({},e);for(let a of r){let s=a.route.id;if(e.hasOwnProperty(s)?e[s]!==void 0&&(i[s]=e[s]):t[s]!==void 0&&a.route.loader&&(i[s]=t[s]),n&&n.hasOwnProperty(s))break}return i}function Jw(t){return t?wn(t[1])?{actionData:{}}:{actionData:{[t[0]]:t[1].data}}:{}}function Qa(t,e){return(e?t.slice(0,t.findIndex(n=>n.route.id===e)+1):[...t]).reverse().find(n=>n.route.hasErrorBoundary===!0)||t[0]}function Qw(t){let e=t.length===1?t[0]:t.find(r=>r.index||!r.path||r.path==="/")||{id:"__shim-error-route__"};return{matches:[{params:{},pathname:"",pathnameBase:"",route:e}],route:e}}function sn(t,e){let{pathname:r,routeId:n,method:i,type:a,message:s}=e===void 0?{}:e,o="Unknown Server Error",l="Unknown @remix-run/router error";return t===400?(o="Bad Request",i&&r&&n?l="You made a "+i+' request to "'+r+'" but '+('did not provide a `loader` for route "'+n+'", ')+"so there is no way to handle the request.":a==="defer-action"?l="defer() is not supported in actions":a==="invalid-body"&&(l="Unable to encode submission body")):t===403?(o="Forbidden",l='Route "'+n+'" does not match URL "'+r+'"'):t===404?(o="Not Found",l='No route matches URL "'+r+'"'):t===405&&(o="Method Not Allowed",i&&r&&n?l="You made a "+i.toUpperCase()+' request to "'+r+'" but '+('did not provide an `action` for route "'+n+'", ')+"so there is no way to handle the request.":i&&(l='Invalid request method "'+i.toUpperCase()+'"')),new Lf(t||500,o,new Error(l),!0)}function Xl(t){let e=Object.entries(t);for(let r=e.length-1;r>=0;r--){let[n,i]=e[r];if(rs(i))return{key:n,result:i}}}function mR(t){let e=typeof t=="string"?Sa(t):t;return cs(Zt({},e,{hash:""}))}function aH(t,e){return t.pathname!==e.pathname||t.search!==e.search?!1:t.hash===""?e.hash!=="":t.hash===e.hash?!0:e.hash!==""}function sH(t){return vR(t.result)&&zq.has(t.result.status)}function ha(t){return t.type===kt.deferred}function wn(t){return t.type===kt.error}function rs(t){return(t&&t.type)===kt.redirect}function e1(t){return typeof t=="object"&&t!=null&&"type"in t&&"data"in t&&"init"in t&&t.type==="DataWithResponseInit"}function oH(t){let e=t;return e&&typeof e=="object"&&typeof e.data=="object"&&typeof e.subscribe=="function"&&typeof e.cancel=="function"&&typeof e.resolveData=="function"}function vR(t){return t!=null&&typeof t.status=="number"&&typeof t.statusText=="string"&&typeof t.headers=="object"&&typeof t.body<"u"}function uH(t){return Bq.has(t.toLowerCase())}function Qn(t){return Hq.has(t.toLowerCase())}async function lH(t,e,r,n,i){let a=Object.entries(e);for(let s=0;s<a.length;s++){let[o,l]=a[s],c=t.find(g=>(g==null?void 0:g.route.id)===o);if(!c)continue;let d=n.find(g=>g.route.id===c.route.id),h=d!=null&&!pR(d,c)&&(i&&i[c.route.id])!==void 0;ha(l)&&h&&await M0(l,r,!1).then(g=>{g&&(e[o]=g)})}}async function cH(t,e,r){for(let n=0;n<r.length;n++){let{key:i,routeId:a,controller:s}=r[n],o=e[i];t.find(c=>(c==null?void 0:c.route.id)===a)&&ha(o)&&(nt(s,"Expected an AbortController for revalidating fetcher deferred result"),await M0(o,s.signal,!0).then(c=>{c&&(e[i]=c)}))}}async function M0(t,e,r){if(r===void 0&&(r=!1),!await t.deferredData.resolveData(e)){if(r)try{return{type:kt.data,data:t.deferredData.unwrappedData}}catch(i){return{type:kt.error,error:i}}return{type:kt.data,data:t.deferredData.data}}}function P0(t){return new URLSearchParams(t).getAll("index").some(e=>e==="")}function hu(t,e){let r=typeof e=="string"?Sa(e).search:e.search;if(t[t.length-1].route.index&&P0(r||""))return t[t.length-1];let n=fR(t);return n[n.length-1]}function t1(t){let{formMethod:e,formAction:r,formEncType:n,text:i,formData:a,json:s}=t;if(!(!e||!r||!n)){if(i!=null)return{formMethod:e,formAction:r,formEncType:n,formData:void 0,json:void 0,text:i};if(a!=null)return{formMethod:e,formAction:r,formEncType:n,formData:a,json:void 0,text:void 0};if(s!==void 0)return{formMethod:e,formAction:r,formEncType:n,formData:void 0,json:s,text:void 0}}}function yp(t,e){return e?{state:"loading",location:t,formMethod:e.formMethod,formAction:e.formAction,formEncType:e.formEncType,formData:e.formData,json:e.json,text:e.text}:{state:"loading",location:t,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0}}function fH(t,e){return{state:"submitting",location:t,formMethod:e.formMethod,formAction:e.formAction,formEncType:e.formEncType,formData:e.formData,json:e.json,text:e.text}}function Yo(t,e){return t?{state:"loading",formMethod:t.formMethod,formAction:t.formAction,formEncType:t.formEncType,formData:t.formData,json:t.json,text:t.text,data:e}:{state:"loading",formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:e}}function dH(t,e){return{state:"submitting",formMethod:t.formMethod,formAction:t.formAction,formEncType:t.formEncType,formData:t.formData,json:t.json,text:t.text,data:e?e.data:void 0}}function ua(t){return{state:"idle",formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:t}}function hH(t,e){try{let r=t.sessionStorage.getItem(hR);if(r){let n=JSON.parse(r);for(let[i,a]of Object.entries(n||{}))a&&Array.isArray(a)&&e.set(i,new Set(a||[]))}}catch{}}function pH(t,e){if(e.size>0){let r={};for(let[n,i]of e)r[n]=[...i];try{t.sessionStorage.setItem(hR,JSON.stringify(r))}catch(n){ls(!1,"Failed to save applied view transitions in sessionStorage ("+n+").")}}}/**
|
|
20
|
+
* React Router v6.30.4
|
|
21
|
+
*
|
|
22
|
+
* Copyright (c) Remix Software Inc.
|
|
23
|
+
*
|
|
24
|
+
* This source code is licensed under the MIT license found in the
|
|
25
|
+
* LICENSE.md file in the root directory of this source tree.
|
|
26
|
+
*
|
|
27
|
+
* @license MIT
|
|
28
|
+
*/function Nf(){return Nf=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)({}).hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},Nf.apply(null,arguments)}const Gu=ie.createContext(null),L0=ie.createContext(null),qi=ie.createContext(null),N0=ie.createContext(null),Ca=ie.createContext({outlet:null,matches:[],isDataRoute:!1}),yR=ie.createContext(null);function gH(t,e){let{relative:r}=e===void 0?{}:e;xo()||nt(!1);let{basename:n,navigator:i}=ie.useContext(qi),{hash:a,pathname:s,search:o}=_d(t,{relative:r}),l=s;return n!=="/"&&(l=s==="/"?n:ki([n,s])),i.createHref({pathname:l,search:o,hash:a})}function xo(){return ie.useContext(N0)!=null}function vs(){return xo()||nt(!1),ie.useContext(N0).location}function bR(t){ie.useContext(qi).static||ie.useLayoutEffect(t)}function bd(){let{isDataRoute:t}=ie.useContext(Ca);return t?OH():mH()}function mH(){xo()||nt(!1);let t=ie.useContext(Gu),{basename:e,future:r,navigator:n}=ie.useContext(qi),{matches:i}=ie.useContext(Ca),{pathname:a}=vs(),s=JSON.stringify(vd(i,r.v7_relativeSplatPath)),o=ie.useRef(!1);return bR(()=>{o.current=!0}),ie.useCallback(function(c,d){if(d===void 0&&(d={}),!o.current)return;if(typeof c=="number"){n.go(c);return}let h=yd(c,JSON.parse(s),a,d.relative==="path");t==null&&e!=="/"&&(h.pathname=h.pathname==="/"?e:ki([e,h.pathname])),(d.replace?n.replace:n.push)(h,d.state,d)},[e,n,s,a,t])}function _d(t,e){let{relative:r}=e===void 0?{}:e,{future:n}=ie.useContext(qi),{matches:i}=ie.useContext(Ca),{pathname:a}=vs(),s=JSON.stringify(vd(i,n.v7_relativeSplatPath));return ie.useMemo(()=>yd(t,JSON.parse(s),a,r==="path"),[t,s,a,r])}function vH(t,e,r,n){xo()||nt(!1);let{navigator:i}=ie.useContext(qi),{matches:a}=ie.useContext(Ca),s=a[a.length-1],o=s?s.params:{};s&&s.pathname;let l=s?s.pathnameBase:"/";s&&s.route;let c=vs(),d;d=c;let h=d.pathname||"/",g=h;if(l!=="/"){let b=l.replace(/^\//,"").split("/");g="/"+h.replace(/^\//,"").split("/").slice(b.length).join("/")}let m=Ja(t,{pathname:g});return wH(m&&m.map(b=>Object.assign({},b,{params:Object.assign({},o,b.params),pathname:ki([l,i.encodeLocation?i.encodeLocation(b.pathname).pathname:b.pathname]),pathnameBase:b.pathnameBase==="/"?l:ki([l,i.encodeLocation?i.encodeLocation(b.pathnameBase).pathname:b.pathnameBase])})),a,r,n)}function yH(){let t=EH(),e=Pu(t)?t.status+" "+t.statusText:t instanceof Error?t.message:JSON.stringify(t),r=t instanceof Error?t.stack:null,i={padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"};return ie.createElement(ie.Fragment,null,ie.createElement("h2",null,"Unexpected Application Error!"),ie.createElement("h3",{style:{fontStyle:"italic"}},e),r?ie.createElement("pre",{style:i},r):null,null)}const bH=ie.createElement(yH,null);class _H extends ie.Component{constructor(e){super(e),this.state={location:e.location,revalidation:e.revalidation,error:e.error}}static getDerivedStateFromError(e){return{error:e}}static getDerivedStateFromProps(e,r){return r.location!==e.location||r.revalidation!=="idle"&&e.revalidation==="idle"?{error:e.error,location:e.location,revalidation:e.revalidation}:{error:e.error!==void 0?e.error:r.error,location:r.location,revalidation:e.revalidation||r.revalidation}}componentDidCatch(e,r){console.error("React Router caught the following error during render",e,r)}render(){return this.state.error!==void 0?ie.createElement(Ca.Provider,{value:this.props.routeContext},ie.createElement(yR.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function xH(t){let{routeContext:e,match:r,children:n}=t,i=ie.useContext(Gu);return i&&i.static&&i.staticContext&&(r.route.errorElement||r.route.ErrorBoundary)&&(i.staticContext._deepestRenderedBoundaryId=r.route.id),ie.createElement(Ca.Provider,{value:e},n)}function wH(t,e,r,n){var i;if(e===void 0&&(e=[]),r===void 0&&(r=null),n===void 0&&(n=null),t==null){var a;if(!r)return null;if(r.errors)t=r.matches;else if((a=n)!=null&&a.v7_partialHydration&&e.length===0&&!r.initialized&&r.matches.length>0)t=r.matches;else return null}let s=t,o=(i=r)==null?void 0:i.errors;if(o!=null){let d=s.findIndex(h=>h.route.id&&(o==null?void 0:o[h.route.id])!==void 0);d>=0||nt(!1),s=s.slice(0,Math.min(s.length,d+1))}let l=!1,c=-1;if(r&&n&&n.v7_partialHydration)for(let d=0;d<s.length;d++){let h=s[d];if((h.route.HydrateFallback||h.route.hydrateFallbackElement)&&(c=d),h.route.id){let{loaderData:g,errors:m}=r,v=h.route.loader&&g[h.route.id]===void 0&&(!m||m[h.route.id]===void 0);if(h.route.lazy||v){l=!0,c>=0?s=s.slice(0,c+1):s=[s[0]];break}}}return s.reduceRight((d,h,g)=>{let m,v=!1,b=null,y=null;r&&(m=o&&h.route.id?o[h.route.id]:void 0,b=h.route.errorElement||bH,l&&(c<0&&g===0?(AH("route-fallback"),v=!0,y=null):c===g&&(v=!0,y=h.route.hydrateFallbackElement||null)));let x=e.concat(s.slice(0,g+1)),w=()=>{let S;return m?S=b:v?S=y:h.route.Component?S=ie.createElement(h.route.Component,null):h.route.element?S=h.route.element:S=d,ie.createElement(xH,{match:h,routeContext:{outlet:d,matches:x,isDataRoute:r!=null},children:S})};return r&&(h.route.ErrorBoundary||h.route.errorElement||g===0)?ie.createElement(_H,{location:r.location,revalidation:r.revalidation,component:b,error:m,children:w(),routeContext:{outlet:null,matches:x,isDataRoute:!0}}):w()},null)}var _R=(function(t){return t.UseBlocker="useBlocker",t.UseRevalidator="useRevalidator",t.UseNavigateStable="useNavigate",t})(_R||{}),xR=(function(t){return t.UseBlocker="useBlocker",t.UseLoaderData="useLoaderData",t.UseActionData="useActionData",t.UseRouteError="useRouteError",t.UseNavigation="useNavigation",t.UseRouteLoaderData="useRouteLoaderData",t.UseMatches="useMatches",t.UseRevalidator="useRevalidator",t.UseNavigateStable="useNavigate",t.UseRouteId="useRouteId",t})(xR||{});function TH(t){let e=ie.useContext(Gu);return e||nt(!1),e}function SH(t){let e=ie.useContext(L0);return e||nt(!1),e}function CH(t){let e=ie.useContext(Ca);return e||nt(!1),e}function wR(t){let e=CH(),r=e.matches[e.matches.length-1];return r.route.id||nt(!1),r.route.id}function EH(){var t;let e=ie.useContext(yR),r=SH(xR.UseRouteError),n=wR();return e!==void 0?e:(t=r.errors)==null?void 0:t[n]}function OH(){let{router:t}=TH(_R.UseNavigateStable),e=wR(),r=ie.useRef(!1);return bR(()=>{r.current=!0}),ie.useCallback(function(i,a){a===void 0&&(a={}),r.current&&(typeof i=="number"?t.navigate(i):t.navigate(i,Nf({fromRouteId:e},a)))},[t,e])}const r1={};function AH(t,e,r){r1[t]||(r1[t]=!0)}function IH(t,e){t==null||t.v7_startTransition,(t==null?void 0:t.v7_relativeSplatPath)===void 0&&(!e||e.v7_relativeSplatPath),e&&(e.v7_fetcherPersist,e.v7_normalizeFormMethod,e.v7_partialHydration,e.v7_skipActionErrorRevalidation)}function RH(t){let{to:e,replace:r,state:n,relative:i}=t;xo()||nt(!1);let{future:a,static:s}=ie.useContext(qi),{matches:o}=ie.useContext(Ca),{pathname:l}=vs(),c=bd(),d=yd(e,vd(o,a.v7_relativeSplatPath),l,i==="path"),h=JSON.stringify(d);return ie.useEffect(()=>c(JSON.parse(h),{replace:r,state:n,relative:i}),[c,h,i,r,n]),null}function DH(t){let{basename:e="/",children:r=null,location:n,navigationType:i=vr.Pop,navigator:a,static:s=!1,future:o}=t;xo()&&nt(!1);let l=e.replace(/^\/*/,"/"),c=ie.useMemo(()=>({basename:l,navigator:a,static:s,future:Nf({v7_relativeSplatPath:!1},o)}),[l,o,a,s]);typeof n=="string"&&(n=Sa(n));let{pathname:d="/",search:h="",hash:g="",state:m=null,key:v="default"}=n,b=ie.useMemo(()=>{let y=$i(d,l);return y==null?null:{location:{pathname:y,search:h,hash:g,state:m,key:v},navigationType:i}},[l,d,h,g,m,v,i]);return b==null?null:ie.createElement(qi.Provider,{value:c},ie.createElement(N0.Provider,{children:r,value:b}))}new Promise(()=>{});function MH(t){let e={hasErrorBoundary:t.ErrorBoundary!=null||t.errorElement!=null};return t.Component&&Object.assign(e,{element:ie.createElement(t.Component),Component:void 0}),t.HydrateFallback&&Object.assign(e,{hydrateFallbackElement:ie.createElement(t.HydrateFallback),HydrateFallback:void 0}),t.ErrorBoundary&&Object.assign(e,{errorElement:ie.createElement(t.ErrorBoundary),ErrorBoundary:void 0}),e}/**
|
|
29
|
+
* React Router DOM v6.30.4
|
|
30
|
+
*
|
|
31
|
+
* Copyright (c) Remix Software Inc.
|
|
32
|
+
*
|
|
33
|
+
* This source code is licensed under the MIT license found in the
|
|
34
|
+
* LICENSE.md file in the root directory of this source tree.
|
|
35
|
+
*
|
|
36
|
+
* @license MIT
|
|
37
|
+
*/function oo(){return oo=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)({}).hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},oo.apply(null,arguments)}function TR(t,e){if(t==null)return{};var r={};for(var n in t)if({}.hasOwnProperty.call(t,n)){if(e.indexOf(n)!==-1)continue;r[n]=t[n]}return r}function PH(t){return!!(t.metaKey||t.altKey||t.ctrlKey||t.shiftKey)}function LH(t,e){return t.button===0&&(!e||e==="_self")&&!PH(t)}const NH=["onClick","relative","reloadDocument","replace","state","target","to","preventScrollReset","viewTransition"],FH=["aria-current","caseSensitive","className","end","style","to","viewTransition","children"],kH="6";try{window.__reactRouterVersion=kH}catch{}function Fae(t,e){return Xq({basename:e==null?void 0:e.basename,future:oo({},e==null?void 0:e.future,{v7_prependBasename:!0}),history:yq({window:e==null?void 0:e.window}),hydrationData:(e==null?void 0:e.hydrationData)||jH(),routes:t,mapRouteProperties:MH,dataStrategy:e==null?void 0:e.dataStrategy,patchRoutesOnNavigation:e==null?void 0:e.patchRoutesOnNavigation,window:e==null?void 0:e.window}).initialize()}function jH(){var t;let e=(t=window)==null?void 0:t.__staticRouterHydrationData;return e&&e.errors&&(e=oo({},e,{errors:$H(e.errors)})),e}function $H(t){if(!t)return null;let e=Object.entries(t),r={};for(let[n,i]of e)if(i&&i.__type==="RouteErrorResponse")r[n]=new Lf(i.status,i.statusText,i.data,i.internal===!0);else if(i&&i.__type==="Error"){if(i.__subType){let a=window[i.__subType];if(typeof a=="function")try{let s=new a(i.message);s.stack="",r[n]=s}catch{}}if(r[n]==null){let a=new Error(i.message);a.stack="",r[n]=a}}else r[n]=i;return r}const SR=ie.createContext({isTransitioning:!1}),UH=ie.createContext(new Map),qH="startTransition",n1=ie[qH],HH="flushSync",i1=DU[HH];function WH(t){n1?n1(t):t()}function Zo(t){i1?i1(t):t()}class BH{constructor(){this.status="pending",this.promise=new Promise((e,r)=>{this.resolve=n=>{this.status==="pending"&&(this.status="resolved",e(n))},this.reject=n=>{this.status==="pending"&&(this.status="rejected",r(n))}})}}function kae(t){let{fallbackElement:e,router:r,future:n}=t,[i,a]=ie.useState(r.state),[s,o]=ie.useState(),[l,c]=ie.useState({isTransitioning:!1}),[d,h]=ie.useState(),[g,m]=ie.useState(),[v,b]=ie.useState(),y=ie.useRef(new Map),{v7_startTransition:x}=n||{},w=ie.useCallback(D=>{x?WH(D):D()},[x]),S=ie.useCallback((D,P)=>{let{deletedFetchers:L,flushSync:F,viewTransitionOpts:H}=P;D.fetchers.forEach((ee,J)=>{ee.data!==void 0&&y.current.set(J,ee.data)}),L.forEach(ee=>y.current.delete(ee));let X=r.window==null||r.window.document==null||typeof r.window.document.startViewTransition!="function";if(!H||X){F?Zo(()=>a(D)):w(()=>a(D));return}if(F){Zo(()=>{g&&(d&&d.resolve(),g.skipTransition()),c({isTransitioning:!0,flushSync:!0,currentLocation:H.currentLocation,nextLocation:H.nextLocation})});let ee=r.window.document.startViewTransition(()=>{Zo(()=>a(D))});ee.finished.finally(()=>{Zo(()=>{h(void 0),m(void 0),o(void 0),c({isTransitioning:!1})})}),Zo(()=>m(ee));return}g?(d&&d.resolve(),g.skipTransition(),b({state:D,currentLocation:H.currentLocation,nextLocation:H.nextLocation})):(o(D),c({isTransitioning:!0,flushSync:!1,currentLocation:H.currentLocation,nextLocation:H.nextLocation}))},[r.window,g,d,y,w]);ie.useLayoutEffect(()=>r.subscribe(S),[r,S]),ie.useEffect(()=>{l.isTransitioning&&!l.flushSync&&h(new BH)},[l]),ie.useEffect(()=>{if(d&&s&&r.window){let D=s,P=d.promise,L=r.window.document.startViewTransition(async()=>{w(()=>a(D)),await P});L.finished.finally(()=>{h(void 0),m(void 0),o(void 0),c({isTransitioning:!1})}),m(L)}},[w,s,d,r.window]),ie.useEffect(()=>{d&&s&&i.location.key===s.location.key&&d.resolve()},[d,g,i.location,s]),ie.useEffect(()=>{!l.isTransitioning&&v&&(o(v.state),c({isTransitioning:!0,flushSync:!1,currentLocation:v.currentLocation,nextLocation:v.nextLocation}),b(void 0))},[l.isTransitioning,v]),ie.useEffect(()=>{},[]);let E=ie.useMemo(()=>({createHref:r.createHref,encodeLocation:r.encodeLocation,go:D=>r.navigate(D),push:(D,P,L)=>r.navigate(D,{state:P,preventScrollReset:L==null?void 0:L.preventScrollReset}),replace:(D,P,L)=>r.navigate(D,{replace:!0,state:P,preventScrollReset:L==null?void 0:L.preventScrollReset})}),[r]),C=r.basename||"/",I=ie.useMemo(()=>({router:r,navigator:E,static:!1,basename:C}),[r,E,C]),T=ie.useMemo(()=>({v7_relativeSplatPath:r.future.v7_relativeSplatPath}),[r.future.v7_relativeSplatPath]);return ie.useEffect(()=>IH(n,r.future),[n,r.future]),ie.createElement(ie.Fragment,null,ie.createElement(Gu.Provider,{value:I},ie.createElement(L0.Provider,{value:i},ie.createElement(UH.Provider,{value:y.current},ie.createElement(SR.Provider,{value:l},ie.createElement(DH,{basename:C,location:i.location,navigationType:i.historyAction,navigator:E,future:T},i.initialized||r.future.v7_partialHydration?ie.createElement(zH,{routes:r.routes,future:r.future,state:i}):e))))),null)}const zH=ie.memo(VH);function VH(t){let{routes:e,future:r,state:n}=t;return vH(e,void 0,n,r)}const GH=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",KH=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,XH=ie.forwardRef(function(e,r){let{onClick:n,relative:i,reloadDocument:a,replace:s,state:o,target:l,to:c,preventScrollReset:d,viewTransition:h}=e,g=TR(e,NH),{basename:m}=ie.useContext(qi),v,b=!1;if(typeof c=="string"&&KH.test(c)&&(v=c,GH))try{let S=new URL(window.location.href),E=c.startsWith("//")?new URL(S.protocol+c):new URL(c),C=$i(E.pathname,m);E.origin===S.origin&&C!=null?c=C+E.search+E.hash:b=!0}catch{}let y=gH(c,{relative:i}),x=JH(c,{replace:s,state:o,target:l,preventScrollReset:d,relative:i,viewTransition:h});function w(S){n&&n(S),S.defaultPrevented||x(S)}return ie.createElement("a",oo({},g,{href:v||y,onClick:b||a?n:w,ref:r,target:l}))}),YH=ie.forwardRef(function(e,r){let{"aria-current":n="page",caseSensitive:i=!1,className:a="",end:s=!1,style:o,to:l,viewTransition:c,children:d}=e,h=TR(e,FH),g=_d(l,{relative:h.relative}),m=vs(),v=ie.useContext(L0),{navigator:b,basename:y}=ie.useContext(qi),x=v!=null&&QH(g)&&c===!0,w=b.encodeLocation?b.encodeLocation(g).pathname:g.pathname,S=m.pathname,E=v&&v.navigation&&v.navigation.location?v.navigation.location.pathname:null;i||(S=S.toLowerCase(),E=E?E.toLowerCase():null,w=w.toLowerCase()),E&&y&&(E=$i(E,y)||E);const C=w!=="/"&&w.endsWith("/")?w.length-1:w.length;let I=S===w||!s&&S.startsWith(w)&&S.charAt(C)==="/",T=E!=null&&(E===w||!s&&E.startsWith(w)&&E.charAt(w.length)==="/"),D={isActive:I,isPending:T,isTransitioning:x},P=I?n:void 0,L;typeof a=="function"?L=a(D):L=[a,I?"active":null,T?"pending":null,x?"transitioning":null].filter(Boolean).join(" ");let F=typeof o=="function"?o(D):o;return ie.createElement(XH,oo({},h,{"aria-current":P,className:L,ref:r,style:F,to:l,viewTransition:c}),typeof d=="function"?d(D):d)});var Py;(function(t){t.UseScrollRestoration="useScrollRestoration",t.UseSubmit="useSubmit",t.UseSubmitFetcher="useSubmitFetcher",t.UseFetcher="useFetcher",t.useViewTransitionState="useViewTransitionState"})(Py||(Py={}));var a1;(function(t){t.UseFetcher="useFetcher",t.UseFetchers="useFetchers",t.UseScrollRestoration="useScrollRestoration"})(a1||(a1={}));function ZH(t){let e=ie.useContext(Gu);return e||nt(!1),e}function JH(t,e){let{target:r,replace:n,state:i,preventScrollReset:a,relative:s,viewTransition:o}=e===void 0?{}:e,l=bd(),c=vs(),d=_d(t,{relative:s});return ie.useCallback(h=>{if(LH(h,r)){h.preventDefault();let g=n!==void 0?n:cs(c)===cs(d);l(t,{replace:g,state:i,preventScrollReset:a,relative:s,viewTransition:o})}},[c,l,d,n,i,r,t,a,s,o])}function QH(t,e){e===void 0&&(e={});let r=ie.useContext(SR);r==null&&nt(!1);let{basename:n}=ZH(Py.useViewTransitionState),i=_d(t,{relative:e.relative});if(!r.isTransitioning)return!1;let a=$i(r.currentLocation.pathname,n)||r.currentLocation.pathname,s=$i(r.nextLocation.pathname,n)||r.nextLocation.pathname;return Pf(i.pathname,s)!=null||Pf(i.pathname,a)!=null}const Ha=new Map;function jae(t,e){if(E0===void 0)throw new TypeError('You are using React 17 or below. Install with "npm install use-local-storage-state@17".');const[r]=or(e==null?void 0:e.defaultValue);if(typeof window>"u")return[r,()=>{},{isPersistent:!0,removeItem:()=>{}}];const n=e==null?void 0:e.serializer;return eW(t,r,e==null?void 0:e.storageSync,n==null?void 0:n.parse,n==null?void 0:n.stringify)}function eW(t,e,r=!0,n=tW,i=JSON.stringify){!Ha.has(t)&&e!==void 0&&Jo(()=>localStorage.getItem(t))===null&&Jo(()=>localStorage.setItem(t,i(e)));const a=$t({item:null,parsed:e}),s=E0(rt(l=>{const c=d=>{t===d&&l()};return Ly.add(c),()=>{Ly.delete(c)}},[t]),()=>{var l;const c=(l=Jo(()=>localStorage.getItem(t)))!==null&&l!==void 0?l:null;if(Ha.has(t))a.current={item:c,parsed:Ha.get(t)};else if(c!==a.current.item){let d;try{d=c===null?e:n(c)}catch{d=e}a.current={item:c,parsed:d}}return a.current.parsed},()=>e),o=rt(l=>{const c=l instanceof Function?l(a.current.parsed):l;try{localStorage.setItem(t,i(c)),Ha.delete(t)}catch{Ha.set(t,c)}bp(t)},[t,i]);return ut(()=>{if(!r)return;const l=c=>{c.storageArea===Jo(()=>localStorage)&&c.key===t&&bp(t)};return window.addEventListener("storage",l),()=>window.removeEventListener("storage",l)},[t,r]),yr(()=>[s,o,{isPersistent:s===e||!Ha.has(t),removeItem(){Jo(()=>localStorage.removeItem(t)),Ha.delete(t),bp(t)}}],[t,o,s,e])}const Ly=new Set;function bp(t){for(const e of[...Ly])e(t)}function tW(t){return t==="undefined"?void 0:JSON.parse(t)}function Jo(t){try{return t()}catch{return}}/**
|
|
38
|
+
* @license
|
|
39
|
+
* Copyright 2018 Google LLC
|
|
40
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
41
|
+
*/const rW=new Set(["children","localName","ref","style","className"]),s1=new WeakMap,o1=(t,e,r,n,i)=>{const a=i==null?void 0:i[e];a===void 0?(t[e]=r,r==null&&e in HTMLElement.prototype&&t.removeAttribute(e)):r!==n&&((s,o,l)=>{let c=s1.get(s);c===void 0&&s1.set(s,c=new Map);let d=c.get(o);l!==void 0?d===void 0?(c.set(o,d={handleEvent:l}),s.addEventListener(o,d)):d.handleEvent=l:d!==void 0&&(c.delete(o),s.removeEventListener(o,d))})(t,a,r)},dn=({react:t,tagName:e,elementClass:r,events:n,displayName:i})=>{const a=new Set(Object.keys(n??{})),s=t.forwardRef(((o,l)=>{const c=t.useRef(new Map),d=t.useRef(null),h={},g={};for(const[m,v]of Object.entries(o))rW.has(m)?h[m==="className"?"class":m]=v:a.has(m)||m in r.prototype?g[m]=v:h[m]=v;return t.useLayoutEffect((()=>{if(d.current===null)return;const m=new Map;for(const v in g)o1(d.current,v,o[v],c.current.get(v),n),c.current.delete(v),m.set(v,o[v]);for(const[v,b]of c.current)o1(d.current,v,void 0,b,n);c.current=m})),t.useLayoutEffect((()=>{var m;(m=d.current)==null||m.removeAttribute("defer-hydration")}),[]),h.suppressHydrationWarning=!0,t.createElement(e,{...h,ref:t.useCallback((m=>{d.current=m,typeof l=="function"?l(m):l!==null&&(l.current=m)}),[l])})}));return s.displayName=i??r.name,s},nW=dn({tagName:"ix-button",elementClass:PU,react:He}),xd=Cn((t,e)=>A.jsx(nW,{type:"button",...t,ref:e}));xd.displayName="IxButton";const iW=customElements.get("ix-checkbox"),aW=dn({tagName:"ix-checkbox",elementClass:iW,react:He,events:{onCheckboxChange:"change"}}),F0=Cn(({"aria-label":t,label:e,style:r,...n},i)=>{const a=$t(null),s=t||e,o=rt(l=>{a.current=l,typeof i=="function"?i(l):i&&(i.current=l)},[i]);return Bu(()=>{const l=a.current;l&&(l.ariaAttributes=s?{"aria-label":s}:{},l.requestUpdate())},[s]),A.jsx(aW,{label:e,style:{display:"inline-flex",...r},...n,ref:o})});F0.displayName="IxCheckbox";const sW=customElements.get("ix-date-next"),oW=dn({tagName:"ix-date-next",elementClass:sW,react:He}),_p=(t,e)=>{const r=t==null?void 0:t.datePicker;!t||!r||(e&&!r.invalid&&t.reportValidity(),t.errorText!==e&&(t.errorText=e),r.invalid=!!e)},Ny=Cn(({errorText:t="",format:e,onChanged:r,timezone:n,...i},a)=>{const s=$t(null),o=$t(t);o.current=t;const l=rt(d=>{s.current=d,typeof a=="function"?a(d):a&&(a.current=d)},[a]);Bu(()=>{const d=s.current;d&&e&&d.setAttribute("format",e),d&&n&&d.setAttribute("timezone",n)},[e,n]),ut(()=>{const d=s.current;_p(d,t),d==null||d.updateComplete.then(()=>_p(d,o.current))});const c=rt(d=>{r==null||r(d),_p(s.current,o.current)},[r]);return A.jsx(oW,{ref:l,...i,...e?{format:e}:null,...n?{timezone:n}:null,onChanged:c})});Ny.displayName="IxDate";const uW=dn({tagName:"ix-dialog",elementClass:LU,react:He}),lW=customElements.get("ix-divider"),cW=dn({tagName:"ix-divider",elementClass:lW,react:He}),fW=customElements.get("ix-drawer"),dW=dn({tagName:"ix-drawer",elementClass:fW,react:He}),Hi=dn({tagName:"ix-icon",elementClass:NU,react:He}),hW=dn({tagName:"ix-icon-button",elementClass:FU,react:He}),pW=customElements.get("ix-pagination"),gW=dn({tagName:"ix-pagination",elementClass:pW,react:He,events:{onUpdatePagination:"updatePagination"}}),mW=customElements.get("ix-progress"),Ff=dn({tagName:"ix-progress",elementClass:mW,react:He}),vW=dn({tagName:"ix-select",elementClass:kU,react:He,events:{onSelectInput:"input"}}),yW=dn({tagName:"ix-select-option",elementClass:jU,react:He}),bW=customElements.get("ix-switch"),_W=dn({tagName:"ix-switch",elementClass:bW,react:He,events:{onSwitchChange:"change"}}),k0=Cn(({"aria-label":t,style:e,...r},n)=>{const i=$t(null),a=rt(s=>{i.current=s,typeof n=="function"?n(s):n&&(n.current=s)},[n]);return Bu(()=>{const s=i.current;s==null||s.updateComplete.then(()=>{var o,l;t?(o=s.component)==null||o.setAttribute("aria-label",t):(l=s.component)==null||l.removeAttribute("aria-label")})},[t]),A.jsx(_W,{style:{display:"inline-flex",...e},...r,ref:a})});k0.displayName="IxSwitch";const xW=customElements.get("ix-textbox"),wW=t=>{const[e]=t.composedPath();return e instanceof HTMLInputElement||e instanceof HTMLTextAreaElement?e.value:""},TW=dn({tagName:"ix-textbox",elementClass:xW,react:He,events:{onTextInput:"input"}});var SW={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},CW=function(e,r,n){var i,a=SW[e];return typeof a=="string"?i=a:r===1?i=a.one:i=a.other.replace("{{count}}",r.toString()),n!=null&&n.addSuffix?n.comparison&&n.comparison>0?"in "+i:i+" ago":i};function xp(t){return function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},r=e.width?String(e.width):t.defaultWidth,n=t.formats[r]||t.formats[t.defaultWidth];return n}}var EW={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},OW={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},AW={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},IW={date:xp({formats:EW,defaultWidth:"full"}),time:xp({formats:OW,defaultWidth:"full"}),dateTime:xp({formats:AW,defaultWidth:"full"})},RW={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},DW=function(e,r,n,i){return RW[e]};function Qo(t){return function(e,r){var n=r!=null&&r.context?String(r.context):"standalone",i;if(n==="formatting"&&t.formattingValues){var a=t.defaultFormattingWidth||t.defaultWidth,s=r!=null&&r.width?String(r.width):a;i=t.formattingValues[s]||t.formattingValues[a]}else{var o=t.defaultWidth,l=r!=null&&r.width?String(r.width):t.defaultWidth;i=t.values[l]||t.values[o]}var c=t.argumentCallback?t.argumentCallback(e):e;return i[c]}}var MW={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},PW={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},LW={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},NW={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},FW={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},kW={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},jW=function(e,r){var n=Number(e),i=n%100;if(i>20||i<10)switch(i%10){case 1:return n+"st";case 2:return n+"nd";case 3:return n+"rd"}return n+"th"},$W={ordinalNumber:jW,era:Qo({values:MW,defaultWidth:"wide"}),quarter:Qo({values:PW,defaultWidth:"wide",argumentCallback:function(e){return e-1}}),month:Qo({values:LW,defaultWidth:"wide"}),day:Qo({values:NW,defaultWidth:"wide"}),dayPeriod:Qo({values:FW,defaultWidth:"wide",formattingValues:kW,defaultFormattingWidth:"wide"})};function eu(t){return function(e){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=r.width,i=n&&t.matchPatterns[n]||t.matchPatterns[t.defaultMatchWidth],a=e.match(i);if(!a)return null;var s=a[0],o=n&&t.parsePatterns[n]||t.parsePatterns[t.defaultParseWidth],l=Array.isArray(o)?qW(o,function(h){return h.test(s)}):UW(o,function(h){return h.test(s)}),c;c=t.valueCallback?t.valueCallback(l):l,c=r.valueCallback?r.valueCallback(c):c;var d=e.slice(s.length);return{value:c,rest:d}}}function UW(t,e){for(var r in t)if(t.hasOwnProperty(r)&&e(t[r]))return r}function qW(t,e){for(var r=0;r<t.length;r++)if(e(t[r]))return r}function HW(t){return function(e){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=e.match(t.matchPattern);if(!n)return null;var i=n[0],a=e.match(t.parsePattern);if(!a)return null;var s=t.valueCallback?t.valueCallback(a[0]):a[0];s=r.valueCallback?r.valueCallback(s):s;var o=e.slice(i.length);return{value:s,rest:o}}}var WW=/^(\d+)(th|st|nd|rd)?/i,BW=/\d+/i,zW={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},VW={any:[/^b/i,/^(a|c)/i]},GW={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},KW={any:[/1/i,/2/i,/3/i,/4/i]},XW={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},YW={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},ZW={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},JW={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},QW={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},eB={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},tB={ordinalNumber:HW({matchPattern:WW,parsePattern:BW,valueCallback:function(e){return parseInt(e,10)}}),era:eu({matchPatterns:zW,defaultMatchWidth:"wide",parsePatterns:VW,defaultParseWidth:"any"}),quarter:eu({matchPatterns:GW,defaultMatchWidth:"wide",parsePatterns:KW,defaultParseWidth:"any",valueCallback:function(e){return e+1}}),month:eu({matchPatterns:XW,defaultMatchWidth:"wide",parsePatterns:YW,defaultParseWidth:"any"}),day:eu({matchPatterns:ZW,defaultMatchWidth:"wide",parsePatterns:JW,defaultParseWidth:"any"}),dayPeriod:eu({matchPatterns:QW,defaultMatchWidth:"any",parsePatterns:eB,defaultParseWidth:"any"})},wd={code:"en-US",formatDistance:CW,formatLong:IW,formatRelative:DW,localize:$W,match:tB,options:{weekStartsOn:0,firstWeekContainsDate:1}};const CR=()=>({adapterLocale:wd}),rB=md({activeAccount:null,email:"",handleCloseWelcomeVideo:()=>{},internalDomains:[],isError:!1,ready:!1,setActiveAccount:()=>{},setShowReleaseDialog:()=>{},showReleaseDialog:!1,showWelcomeVideo:!1,superUser:!1,userInfo:{},userPreferences:null}),nB=()=>zu(rB),iB="17.0.0-GP-6771.563680",aB={version:iB},sB=()=>{var e;const t=(e=window.gpConfig)==null?void 0:e["ui-mfe-dcim"];if(!t)throw new Error("ui-mfe-dcim config not loaded. Ensure config.json is fetched before app bootstrap.");return t},oB=()=>{const{mfeChartsUi:t}=sB();return{appVersion:aB.version,globalApiUrl:t.globalApiUrl,i18nLoadPath:t.isDev?"/locales/{{lng}}/{{ns}}.json":"/src/lib/locales/{{lng}}/{{ns}}.json"}};class j0 extends Error{constructor(r,n,i,a){super(r);qe(this,"statusCode",0);qe(this,"description");qe(this,"details");this.statusCode=n,this.description=i||"",this.details=a||"",Object.setPrototypeOf(this,j0.prototype)}}const ER=t=>t==null,uB=async t=>{var e,r,n,i,a;if(!t.ok){const s=await t.json(),o=(r=(e=s==null?void 0:s.Errors)==null?void 0:e.Error)==null?void 0:r[0];throw new j0(((i=(n=s==null?void 0:s.Errors)==null?void 0:n.Error)==null?void 0:i[0].ReasonCode)||((a=s==null?void 0:s.error)==null?void 0:a.message),t.status,o==null?void 0:o.Description,o==null?void 0:o.Details)}};function mi(t){"@babel/helpers - typeof";return mi=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},mi(t)}function _t(t){if(t===null||t===!0||t===!1)return NaN;var e=Number(t);return isNaN(e)?e:e<0?Math.ceil(e):Math.floor(e)}function ye(t,e){if(e.length<t)throw new TypeError(t+" argument"+(t>1?"s":"")+" required, but only "+e.length+" present")}function Ee(t){ye(1,arguments);var e=Object.prototype.toString.call(t);return t instanceof Date||mi(t)==="object"&&e==="[object Date]"?new Date(t.getTime()):typeof t=="number"||e==="[object Number]"?new Date(t):((typeof t=="string"||e==="[object String]")&&typeof console<"u"&&(console.warn("Starting with v2.0.0-beta.1 date-fns doesn't accept strings as date arguments. Please use `parseISO` to parse strings. See: https://github.com/date-fns/date-fns/blob/master/docs/upgradeGuide.md#string-arguments"),console.warn(new Error().stack)),new Date(NaN))}function $0(t,e){ye(2,arguments);var r=Ee(t),n=_t(e);return isNaN(n)?new Date(NaN):(n&&r.setDate(r.getDate()+n),r)}function Td(t,e){ye(2,arguments);var r=Ee(t),n=_t(e);if(isNaN(n))return new Date(NaN);if(!n)return r;var i=r.getDate(),a=new Date(r.getTime());a.setMonth(r.getMonth()+n+1,0);var s=a.getDate();return i>=s?a:(r.setFullYear(a.getFullYear(),a.getMonth(),i),r)}function Ku(t,e){ye(2,arguments);var r=Ee(t).getTime(),n=_t(e);return new Date(r+n)}var lB=36e5;function cB(t,e){ye(2,arguments);var r=_t(e);return Ku(t,r*lB)}var fB={};function Wi(){return fB}function u1(t,e){var r,n,i,a,s,o,l,c;ye(1,arguments);var d=Wi(),h=_t((r=(n=(i=(a=e==null?void 0:e.weekStartsOn)!==null&&a!==void 0?a:e==null||(s=e.locale)===null||s===void 0||(o=s.options)===null||o===void 0?void 0:o.weekStartsOn)!==null&&i!==void 0?i:d.weekStartsOn)!==null&&n!==void 0?n:(l=d.locale)===null||l===void 0||(c=l.options)===null||c===void 0?void 0:c.weekStartsOn)!==null&&r!==void 0?r:0);if(!(h>=0&&h<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var g=Ee(t),m=g.getDay(),v=(m<h?7:0)+m-h;return g.setDate(g.getDate()-v),g.setHours(0,0,0,0),g}function uo(t){var e=new Date(Date.UTC(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()));return e.setUTCFullYear(t.getFullYear()),t.getTime()-e.getTime()}function fs(t){ye(1,arguments);var e=Ee(t);return e.setHours(0,0,0,0),e}var dB=864e5;function hB(t,e){ye(2,arguments);var r=fs(t),n=fs(e),i=r.getTime()-uo(r),a=n.getTime()-uo(n);return Math.round((i-a)/dB)}var pB=6e4;function gB(t,e){ye(2,arguments);var r=_t(e);return Ku(t,r*pB)}function mB(t,e){ye(2,arguments);var r=_t(e),n=r*3;return Td(t,n)}function vB(t,e){ye(2,arguments);var r=_t(e);return Ku(t,r*1e3)}function yB(t,e){ye(2,arguments);var r=_t(e),n=r*7;return $0(t,n)}function bB(t,e){ye(2,arguments);var r=_t(e);return Td(t,r*12)}function ro(t,e){ye(2,arguments);var r=Ee(t),n=Ee(e),i=r.getTime()-n.getTime();return i<0?-1:i>0?1:i}var Sd=6e4,Cd=36e5,_B=1e3;function xB(t,e){ye(2,arguments);var r=fs(t),n=fs(e);return r.getTime()===n.getTime()}function OR(t){return ye(1,arguments),t instanceof Date||mi(t)==="object"&&Object.prototype.toString.call(t)==="[object Date]"}function wo(t){if(ye(1,arguments),!OR(t)&&typeof t!="number")return!1;var e=Ee(t);return!isNaN(Number(e))}function wB(t,e){ye(2,arguments);var r=Ee(t),n=Ee(e),i=r.getFullYear()-n.getFullYear(),a=r.getMonth()-n.getMonth();return i*12+a}function TB(t,e){ye(2,arguments);var r=Ee(t),n=Ee(e);return r.getFullYear()-n.getFullYear()}function l1(t,e){var r=t.getFullYear()-e.getFullYear()||t.getMonth()-e.getMonth()||t.getDate()-e.getDate()||t.getHours()-e.getHours()||t.getMinutes()-e.getMinutes()||t.getSeconds()-e.getSeconds()||t.getMilliseconds()-e.getMilliseconds();return r<0?-1:r>0?1:r}function AR(t,e){ye(2,arguments);var r=Ee(t),n=Ee(e),i=l1(r,n),a=Math.abs(hB(r,n));r.setDate(r.getDate()-i*a);var s=+(l1(r,n)===-i),o=i*(a-s);return o===0?0:o}function Ed(t,e){return ye(2,arguments),Ee(t).getTime()-Ee(e).getTime()}var c1={ceil:Math.ceil,round:Math.round,floor:Math.floor,trunc:function(e){return e<0?Math.ceil(e):Math.floor(e)}},SB="trunc";function Xu(t){return t?c1[t]:c1[SB]}function CB(t,e,r){ye(2,arguments);var n=Ed(t,e)/Cd;return Xu(void 0)(n)}function EB(t,e,r){ye(2,arguments);var n=Ed(t,e)/Sd;return Xu(void 0)(n)}function Od(t){ye(1,arguments);var e=Ee(t);return e.setHours(23,59,59,999),e}function IR(t){ye(1,arguments);var e=Ee(t),r=e.getMonth();return e.setFullYear(e.getFullYear(),r+1,0),e.setHours(23,59,59,999),e}function OB(t){ye(1,arguments);var e=Ee(t);return Od(e).getTime()===IR(e).getTime()}function RR(t,e){ye(2,arguments);var r=Ee(t),n=Ee(e),i=ro(r,n),a=Math.abs(wB(r,n)),s;if(a<1)s=0;else{r.getMonth()===1&&r.getDate()>27&&r.setDate(30),r.setMonth(r.getMonth()-i*a);var o=ro(r,n)===-i;OB(Ee(t))&&a===1&&ro(t,n)===1&&(o=!1),s=i*(a-Number(o))}return s===0?0:s}function AB(t,e,r){ye(2,arguments);var n=RR(t,e)/3;return Xu(void 0)(n)}function IB(t,e,r){ye(2,arguments);var n=Ed(t,e)/1e3;return Xu(void 0)(n)}function RB(t,e,r){ye(2,arguments);var n=AR(t,e)/7;return Xu(void 0)(n)}function DB(t,e){ye(2,arguments);var r=Ee(t),n=Ee(e),i=ro(r,n),a=Math.abs(TB(r,n));r.setFullYear(1584),n.setFullYear(1584);var s=ro(r,n)===-i,o=i*(a-Number(s));return o===0?0:o}function MB(t){ye(1,arguments);var e=Ee(t);return e.setSeconds(0,0),e}function PB(t){ye(1,arguments);var e=Ee(t),r=e.getMonth(),n=r-r%3;return e.setMonth(n,1),e.setHours(0,0,0,0),e}function LB(t){ye(1,arguments);var e=Ee(t);return e.setDate(1),e.setHours(0,0,0,0),e}function NB(t){ye(1,arguments);var e=Ee(t),r=e.getFullYear();return e.setFullYear(r+1,0,0),e.setHours(23,59,59,999),e}function FB(t){ye(1,arguments);var e=Ee(t),r=new Date(0);return r.setFullYear(e.getFullYear(),0,1),r.setHours(0,0,0,0),r}function kB(t){ye(1,arguments);var e=Ee(t);return e.setMinutes(59,59,999),e}function jB(t,e){var r,n,i,a,s,o;ye(1,arguments);var l=Wi(),c=_t((r=(n=(i=(a=void 0)!==null&&a!==void 0?a:void 0)!==null&&i!==void 0?i:l.weekStartsOn)!==null&&n!==void 0?n:(s=l.locale)===null||s===void 0||(o=s.options)===null||o===void 0?void 0:o.weekStartsOn)!==null&&r!==void 0?r:0);if(!(c>=0&&c<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var d=Ee(t),h=d.getDay(),g=(h<c?-7:0)+6-(h-c);return d.setDate(d.getDate()+g),d.setHours(23,59,59,999),d}function $B(t){ye(1,arguments);var e=Ee(t);return e.setSeconds(59,999),e}function UB(t){ye(1,arguments);var e=Ee(t),r=e.getMonth(),n=r-r%3+3;return e.setMonth(n,0),e.setHours(23,59,59,999),e}function qB(t){ye(1,arguments);var e=Ee(t);return e.setMilliseconds(999),e}function DR(t,e){ye(2,arguments);var r=_t(e);return Ku(t,-r)}var HB=864e5;function WB(t){ye(1,arguments);var e=Ee(t),r=e.getTime();e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0);var n=e.getTime(),i=r-n;return Math.floor(i/HB)+1}function lo(t){ye(1,arguments);var e=1,r=Ee(t),n=r.getUTCDay(),i=(n<e?7:0)+n-e;return r.setUTCDate(r.getUTCDate()-i),r.setUTCHours(0,0,0,0),r}function MR(t){ye(1,arguments);var e=Ee(t),r=e.getUTCFullYear(),n=new Date(0);n.setUTCFullYear(r+1,0,4),n.setUTCHours(0,0,0,0);var i=lo(n),a=new Date(0);a.setUTCFullYear(r,0,4),a.setUTCHours(0,0,0,0);var s=lo(a);return e.getTime()>=i.getTime()?r+1:e.getTime()>=s.getTime()?r:r-1}function BB(t){ye(1,arguments);var e=MR(t),r=new Date(0);r.setUTCFullYear(e,0,4),r.setUTCHours(0,0,0,0);var n=lo(r);return n}var zB=6048e5;function PR(t){ye(1,arguments);var e=Ee(t),r=lo(e).getTime()-BB(e).getTime();return Math.round(r/zB)+1}function ds(t,e){var r,n,i,a,s,o,l,c;ye(1,arguments);var d=Wi(),h=_t((r=(n=(i=(a=e==null?void 0:e.weekStartsOn)!==null&&a!==void 0?a:e==null||(s=e.locale)===null||s===void 0||(o=s.options)===null||o===void 0?void 0:o.weekStartsOn)!==null&&i!==void 0?i:d.weekStartsOn)!==null&&n!==void 0?n:(l=d.locale)===null||l===void 0||(c=l.options)===null||c===void 0?void 0:c.weekStartsOn)!==null&&r!==void 0?r:0);if(!(h>=0&&h<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var g=Ee(t),m=g.getUTCDay(),v=(m<h?7:0)+m-h;return g.setUTCDate(g.getUTCDate()-v),g.setUTCHours(0,0,0,0),g}function U0(t,e){var r,n,i,a,s,o,l,c;ye(1,arguments);var d=Ee(t),h=d.getUTCFullYear(),g=Wi(),m=_t((r=(n=(i=(a=e==null?void 0:e.firstWeekContainsDate)!==null&&a!==void 0?a:e==null||(s=e.locale)===null||s===void 0||(o=s.options)===null||o===void 0?void 0:o.firstWeekContainsDate)!==null&&i!==void 0?i:g.firstWeekContainsDate)!==null&&n!==void 0?n:(l=g.locale)===null||l===void 0||(c=l.options)===null||c===void 0?void 0:c.firstWeekContainsDate)!==null&&r!==void 0?r:1);if(!(m>=1&&m<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var v=new Date(0);v.setUTCFullYear(h+1,0,m),v.setUTCHours(0,0,0,0);var b=ds(v,e),y=new Date(0);y.setUTCFullYear(h,0,m),y.setUTCHours(0,0,0,0);var x=ds(y,e);return d.getTime()>=b.getTime()?h+1:d.getTime()>=x.getTime()?h:h-1}function VB(t,e){var r,n,i,a,s,o,l,c;ye(1,arguments);var d=Wi(),h=_t((r=(n=(i=(a=e==null?void 0:e.firstWeekContainsDate)!==null&&a!==void 0?a:e==null||(s=e.locale)===null||s===void 0||(o=s.options)===null||o===void 0?void 0:o.firstWeekContainsDate)!==null&&i!==void 0?i:d.firstWeekContainsDate)!==null&&n!==void 0?n:(l=d.locale)===null||l===void 0||(c=l.options)===null||c===void 0?void 0:c.firstWeekContainsDate)!==null&&r!==void 0?r:1),g=U0(t,e),m=new Date(0);m.setUTCFullYear(g,0,h),m.setUTCHours(0,0,0,0);var v=ds(m,e);return v}var GB=6048e5;function LR(t,e){ye(1,arguments);var r=Ee(t),n=ds(r,e).getTime()-VB(r,e).getTime();return Math.round(n/GB)+1}function Ft(t,e){for(var r=t<0?"-":"",n=Math.abs(t).toString();n.length<e;)n="0"+n;return r+n}var aa={y:function(e,r){var n=e.getUTCFullYear(),i=n>0?n:1-n;return Ft(r==="yy"?i%100:i,r.length)},M:function(e,r){var n=e.getUTCMonth();return r==="M"?String(n+1):Ft(n+1,2)},d:function(e,r){return Ft(e.getUTCDate(),r.length)},a:function(e,r){var n=e.getUTCHours()/12>=1?"pm":"am";switch(r){case"a":case"aa":return n.toUpperCase();case"aaa":return n;case"aaaaa":return n[0];case"aaaa":default:return n==="am"?"a.m.":"p.m."}},h:function(e,r){return Ft(e.getUTCHours()%12||12,r.length)},H:function(e,r){return Ft(e.getUTCHours(),r.length)},m:function(e,r){return Ft(e.getUTCMinutes(),r.length)},s:function(e,r){return Ft(e.getUTCSeconds(),r.length)},S:function(e,r){var n=r.length,i=e.getUTCMilliseconds(),a=Math.floor(i*Math.pow(10,n-3));return Ft(a,r.length)}},Bs={midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},KB={G:function(e,r,n){var i=e.getUTCFullYear()>0?1:0;switch(r){case"G":case"GG":case"GGG":return n.era(i,{width:"abbreviated"});case"GGGGG":return n.era(i,{width:"narrow"});case"GGGG":default:return n.era(i,{width:"wide"})}},y:function(e,r,n){if(r==="yo"){var i=e.getUTCFullYear(),a=i>0?i:1-i;return n.ordinalNumber(a,{unit:"year"})}return aa.y(e,r)},Y:function(e,r,n,i){var a=U0(e,i),s=a>0?a:1-a;if(r==="YY"){var o=s%100;return Ft(o,2)}return r==="Yo"?n.ordinalNumber(s,{unit:"year"}):Ft(s,r.length)},R:function(e,r){var n=MR(e);return Ft(n,r.length)},u:function(e,r){var n=e.getUTCFullYear();return Ft(n,r.length)},Q:function(e,r,n){var i=Math.ceil((e.getUTCMonth()+1)/3);switch(r){case"Q":return String(i);case"QQ":return Ft(i,2);case"Qo":return n.ordinalNumber(i,{unit:"quarter"});case"QQQ":return n.quarter(i,{width:"abbreviated",context:"formatting"});case"QQQQQ":return n.quarter(i,{width:"narrow",context:"formatting"});case"QQQQ":default:return n.quarter(i,{width:"wide",context:"formatting"})}},q:function(e,r,n){var i=Math.ceil((e.getUTCMonth()+1)/3);switch(r){case"q":return String(i);case"qq":return Ft(i,2);case"qo":return n.ordinalNumber(i,{unit:"quarter"});case"qqq":return n.quarter(i,{width:"abbreviated",context:"standalone"});case"qqqqq":return n.quarter(i,{width:"narrow",context:"standalone"});case"qqqq":default:return n.quarter(i,{width:"wide",context:"standalone"})}},M:function(e,r,n){var i=e.getUTCMonth();switch(r){case"M":case"MM":return aa.M(e,r);case"Mo":return n.ordinalNumber(i+1,{unit:"month"});case"MMM":return n.month(i,{width:"abbreviated",context:"formatting"});case"MMMMM":return n.month(i,{width:"narrow",context:"formatting"});case"MMMM":default:return n.month(i,{width:"wide",context:"formatting"})}},L:function(e,r,n){var i=e.getUTCMonth();switch(r){case"L":return String(i+1);case"LL":return Ft(i+1,2);case"Lo":return n.ordinalNumber(i+1,{unit:"month"});case"LLL":return n.month(i,{width:"abbreviated",context:"standalone"});case"LLLLL":return n.month(i,{width:"narrow",context:"standalone"});case"LLLL":default:return n.month(i,{width:"wide",context:"standalone"})}},w:function(e,r,n,i){var a=LR(e,i);return r==="wo"?n.ordinalNumber(a,{unit:"week"}):Ft(a,r.length)},I:function(e,r,n){var i=PR(e);return r==="Io"?n.ordinalNumber(i,{unit:"week"}):Ft(i,r.length)},d:function(e,r,n){return r==="do"?n.ordinalNumber(e.getUTCDate(),{unit:"date"}):aa.d(e,r)},D:function(e,r,n){var i=WB(e);return r==="Do"?n.ordinalNumber(i,{unit:"dayOfYear"}):Ft(i,r.length)},E:function(e,r,n){var i=e.getUTCDay();switch(r){case"E":case"EE":case"EEE":return n.day(i,{width:"abbreviated",context:"formatting"});case"EEEEE":return n.day(i,{width:"narrow",context:"formatting"});case"EEEEEE":return n.day(i,{width:"short",context:"formatting"});case"EEEE":default:return n.day(i,{width:"wide",context:"formatting"})}},e:function(e,r,n,i){var a=e.getUTCDay(),s=(a-i.weekStartsOn+8)%7||7;switch(r){case"e":return String(s);case"ee":return Ft(s,2);case"eo":return n.ordinalNumber(s,{unit:"day"});case"eee":return n.day(a,{width:"abbreviated",context:"formatting"});case"eeeee":return n.day(a,{width:"narrow",context:"formatting"});case"eeeeee":return n.day(a,{width:"short",context:"formatting"});case"eeee":default:return n.day(a,{width:"wide",context:"formatting"})}},c:function(e,r,n,i){var a=e.getUTCDay(),s=(a-i.weekStartsOn+8)%7||7;switch(r){case"c":return String(s);case"cc":return Ft(s,r.length);case"co":return n.ordinalNumber(s,{unit:"day"});case"ccc":return n.day(a,{width:"abbreviated",context:"standalone"});case"ccccc":return n.day(a,{width:"narrow",context:"standalone"});case"cccccc":return n.day(a,{width:"short",context:"standalone"});case"cccc":default:return n.day(a,{width:"wide",context:"standalone"})}},i:function(e,r,n){var i=e.getUTCDay(),a=i===0?7:i;switch(r){case"i":return String(a);case"ii":return Ft(a,r.length);case"io":return n.ordinalNumber(a,{unit:"day"});case"iii":return n.day(i,{width:"abbreviated",context:"formatting"});case"iiiii":return n.day(i,{width:"narrow",context:"formatting"});case"iiiiii":return n.day(i,{width:"short",context:"formatting"});case"iiii":default:return n.day(i,{width:"wide",context:"formatting"})}},a:function(e,r,n){var i=e.getUTCHours(),a=i/12>=1?"pm":"am";switch(r){case"a":case"aa":return n.dayPeriod(a,{width:"abbreviated",context:"formatting"});case"aaa":return n.dayPeriod(a,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return n.dayPeriod(a,{width:"narrow",context:"formatting"});case"aaaa":default:return n.dayPeriod(a,{width:"wide",context:"formatting"})}},b:function(e,r,n){var i=e.getUTCHours(),a;switch(i===12?a=Bs.noon:i===0?a=Bs.midnight:a=i/12>=1?"pm":"am",r){case"b":case"bb":return n.dayPeriod(a,{width:"abbreviated",context:"formatting"});case"bbb":return n.dayPeriod(a,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return n.dayPeriod(a,{width:"narrow",context:"formatting"});case"bbbb":default:return n.dayPeriod(a,{width:"wide",context:"formatting"})}},B:function(e,r,n){var i=e.getUTCHours(),a;switch(i>=17?a=Bs.evening:i>=12?a=Bs.afternoon:i>=4?a=Bs.morning:a=Bs.night,r){case"B":case"BB":case"BBB":return n.dayPeriod(a,{width:"abbreviated",context:"formatting"});case"BBBBB":return n.dayPeriod(a,{width:"narrow",context:"formatting"});case"BBBB":default:return n.dayPeriod(a,{width:"wide",context:"formatting"})}},h:function(e,r,n){if(r==="ho"){var i=e.getUTCHours()%12;return i===0&&(i=12),n.ordinalNumber(i,{unit:"hour"})}return aa.h(e,r)},H:function(e,r,n){return r==="Ho"?n.ordinalNumber(e.getUTCHours(),{unit:"hour"}):aa.H(e,r)},K:function(e,r,n){var i=e.getUTCHours()%12;return r==="Ko"?n.ordinalNumber(i,{unit:"hour"}):Ft(i,r.length)},k:function(e,r,n){var i=e.getUTCHours();return i===0&&(i=24),r==="ko"?n.ordinalNumber(i,{unit:"hour"}):Ft(i,r.length)},m:function(e,r,n){return r==="mo"?n.ordinalNumber(e.getUTCMinutes(),{unit:"minute"}):aa.m(e,r)},s:function(e,r,n){return r==="so"?n.ordinalNumber(e.getUTCSeconds(),{unit:"second"}):aa.s(e,r)},S:function(e,r){return aa.S(e,r)},X:function(e,r,n,i){var a=i._originalDate||e,s=a.getTimezoneOffset();if(s===0)return"Z";switch(r){case"X":return d1(s);case"XXXX":case"XX":return Va(s);case"XXXXX":case"XXX":default:return Va(s,":")}},x:function(e,r,n,i){var a=i._originalDate||e,s=a.getTimezoneOffset();switch(r){case"x":return d1(s);case"xxxx":case"xx":return Va(s);case"xxxxx":case"xxx":default:return Va(s,":")}},O:function(e,r,n,i){var a=i._originalDate||e,s=a.getTimezoneOffset();switch(r){case"O":case"OO":case"OOO":return"GMT"+f1(s,":");case"OOOO":default:return"GMT"+Va(s,":")}},z:function(e,r,n,i){var a=i._originalDate||e,s=a.getTimezoneOffset();switch(r){case"z":case"zz":case"zzz":return"GMT"+f1(s,":");case"zzzz":default:return"GMT"+Va(s,":")}},t:function(e,r,n,i){var a=i._originalDate||e,s=Math.floor(a.getTime()/1e3);return Ft(s,r.length)},T:function(e,r,n,i){var a=i._originalDate||e,s=a.getTime();return Ft(s,r.length)}};function f1(t,e){var r=t>0?"-":"+",n=Math.abs(t),i=Math.floor(n/60),a=n%60;if(a===0)return r+String(i);var s=e;return r+String(i)+s+Ft(a,2)}function d1(t,e){if(t%60===0){var r=t>0?"-":"+";return r+Ft(Math.abs(t)/60,2)}return Va(t,e)}function Va(t,e){var r=e||"",n=t>0?"-":"+",i=Math.abs(t),a=Ft(Math.floor(i/60),2),s=Ft(i%60,2);return n+a+r+s}var h1=function(e,r){switch(e){case"P":return r.date({width:"short"});case"PP":return r.date({width:"medium"});case"PPP":return r.date({width:"long"});case"PPPP":default:return r.date({width:"full"})}},NR=function(e,r){switch(e){case"p":return r.time({width:"short"});case"pp":return r.time({width:"medium"});case"ppp":return r.time({width:"long"});case"pppp":default:return r.time({width:"full"})}},XB=function(e,r){var n=e.match(/(P+)(p+)?/)||[],i=n[1],a=n[2];if(!a)return h1(e,r);var s;switch(i){case"P":s=r.dateTime({width:"short"});break;case"PP":s=r.dateTime({width:"medium"});break;case"PPP":s=r.dateTime({width:"long"});break;case"PPPP":default:s=r.dateTime({width:"full"});break}return s.replace("{{date}}",h1(i,r)).replace("{{time}}",NR(a,r))},Fy={p:NR,P:XB},YB=["D","DD"],ZB=["YY","YYYY"];function FR(t){return YB.indexOf(t)!==-1}function kR(t){return ZB.indexOf(t)!==-1}function kf(t,e,r){if(t==="YYYY")throw new RangeError("Use `yyyy` instead of `YYYY` (in `".concat(e,"`) for formatting years to the input `").concat(r,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(t==="YY")throw new RangeError("Use `yy` instead of `YY` (in `".concat(e,"`) for formatting years to the input `").concat(r,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(t==="D")throw new RangeError("Use `d` instead of `D` (in `".concat(e,"`) for formatting days of the month to the input `").concat(r,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(t==="DD")throw new RangeError("Use `dd` instead of `DD` (in `".concat(e,"`) for formatting days of the month to the input `").concat(r,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"))}var JB=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,QB=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,e3=/^'([^]*?)'?$/,t3=/''/g,r3=/[a-zA-Z]/;function Yu(t,e,r){var n,i,a,s,o,l,c,d,h,g,m,v,b,y,x,w,S,E;ye(2,arguments);var C=String(e),I=Wi(),T=(n=(i=r==null?void 0:r.locale)!==null&&i!==void 0?i:I.locale)!==null&&n!==void 0?n:wd,D=_t((a=(s=(o=(l=r==null?void 0:r.firstWeekContainsDate)!==null&&l!==void 0?l:r==null||(c=r.locale)===null||c===void 0||(d=c.options)===null||d===void 0?void 0:d.firstWeekContainsDate)!==null&&o!==void 0?o:I.firstWeekContainsDate)!==null&&s!==void 0?s:(h=I.locale)===null||h===void 0||(g=h.options)===null||g===void 0?void 0:g.firstWeekContainsDate)!==null&&a!==void 0?a:1);if(!(D>=1&&D<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var P=_t((m=(v=(b=(y=r==null?void 0:r.weekStartsOn)!==null&&y!==void 0?y:r==null||(x=r.locale)===null||x===void 0||(w=x.options)===null||w===void 0?void 0:w.weekStartsOn)!==null&&b!==void 0?b:I.weekStartsOn)!==null&&v!==void 0?v:(S=I.locale)===null||S===void 0||(E=S.options)===null||E===void 0?void 0:E.weekStartsOn)!==null&&m!==void 0?m:0);if(!(P>=0&&P<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(!T.localize)throw new RangeError("locale must contain localize property");if(!T.formatLong)throw new RangeError("locale must contain formatLong property");var L=Ee(t);if(!wo(L))throw new RangeError("Invalid time value");var F=uo(L),H=DR(L,F),X={firstWeekContainsDate:D,weekStartsOn:P,locale:T,_originalDate:L},ee=C.match(QB).map(function(J){var te=J[0];if(te==="p"||te==="P"){var ce=Fy[te];return ce(J,T.formatLong)}return J}).join("").match(JB).map(function(J){if(J==="''")return"'";var te=J[0];if(te==="'")return n3(J);var ce=KB[te];if(ce)return!(r!=null&&r.useAdditionalWeekYearTokens)&&kR(J)&&kf(J,e,String(t)),!(r!=null&&r.useAdditionalDayOfYearTokens)&&FR(J)&&kf(J,e,String(t)),ce(H,J,T.localize,X);if(te.match(r3))throw new RangeError("Format string contains an unescaped latin alphabet character `"+te+"`");return J}).join("");return ee}function n3(t){var e=t.match(e3);return e?e[1].replace(t3,"'"):t}function q0(t,e){if(t==null)throw new TypeError("assign requires that input parameter not be null or undefined");for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}function i3(t){return q0({},t)}var p1=1e3*60,jf=1440,g1=jf*30,m1=jf*365;function a3(t,e,r){var n,i,a;ye(2,arguments);var s=Wi(),o=(n=(i=void 0)!==null&&i!==void 0?i:s.locale)!==null&&n!==void 0?n:wd;if(!o.formatDistance)throw new RangeError("locale must contain localize.formatDistance property");var l=ro(t,e);if(isNaN(l))throw new RangeError("Invalid time value");var c=q0(i3(r),{addSuffix:!1,comparison:l}),d,h;l>0?(d=Ee(e),h=Ee(t)):(d=Ee(t),h=Ee(e));var g=String((a=void 0)!==null&&a!==void 0?a:"round"),m;if(g==="floor")m=Math.floor;else if(g==="ceil")m=Math.ceil;else if(g==="round")m=Math.round;else throw new RangeError("roundingMethod must be 'floor', 'ceil' or 'round'");var v=h.getTime()-d.getTime(),b=v/p1,y=uo(h)-uo(d),x=(v-y)/p1,w=r==null?void 0:r.unit,S;if(w?S=String(w):b<1?S="second":b<60?S="minute":b<jf?S="hour":x<g1?S="day":x<m1?S="month":S="year",S==="second"){var E=m(v/1e3);return o.formatDistance("xSeconds",E,c)}else if(S==="minute"){var C=m(b);return o.formatDistance("xMinutes",C,c)}else if(S==="hour"){var I=m(b/60);return o.formatDistance("xHours",I,c)}else if(S==="day"){var T=m(x/jf);return o.formatDistance("xDays",T,c)}else if(S==="month"){var D=m(x/g1);return D===12&&w!=="month"?o.formatDistance("xYears",1,c):o.formatDistance("xMonths",D,c)}else if(S==="year"){var P=m(x/m1);return o.formatDistance("xYears",P,c)}throw new RangeError("unit must be 'second', 'minute', 'hour', 'day', 'month' or 'year'")}function v1(t,e){(e==null||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r<e;r++)n[r]=t[r];return n}function s3(t,e){if(t){if(typeof t=="string")return v1(t,e);var r={}.toString.call(t).slice(8,-1);return r==="Object"&&t.constructor&&(r=t.constructor.name),r==="Map"||r==="Set"?Array.from(t):r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?v1(t,e):void 0}}function y1(t,e){var r=typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(!r){if(Array.isArray(t)||(r=s3(t))||e){r&&(t=r);var n=0,i=function(){};return{s:i,n:function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(c){throw c},f:i}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
42
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a,s=!0,o=!1;return{s:function(){r=r.call(t)},n:function(){var c=r.next();return s=c.done,c},e:function(c){o=!0,a=c},f:function(){try{s||r.return==null||r.return()}finally{if(o)throw a}}}}function ge(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function wt(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Cf(t,e)}function $f(t){return $f=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},$f(t)}function jR(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(jR=function(){return!!t})()}function o3(t,e){if(e&&(mi(e)=="object"||typeof e=="function"))return e;if(e!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return ge(t)}function Tt(t){var e=jR();return function(){var r,n=$f(t);if(e){var i=$f(this).constructor;r=Reflect.construct(n,arguments,i)}else r=n.apply(this,arguments);return o3(this,r)}}function yt(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function u3(t,e){if(mi(t)!="object"||!t)return t;var r=t[Symbol.toPrimitive];if(r!==void 0){var n=r.call(t,e);if(mi(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function $R(t){var e=u3(t,"string");return mi(e)=="symbol"?e:e+""}function l3(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,$R(n.key),n)}}function bt(t,e,r){return e&&l3(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t}function fe(t,e,r){return(e=$R(e))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var c3=10,UR=(function(){function t(){yt(this,t),fe(this,"priority",void 0),fe(this,"subPriority",0)}return bt(t,[{key:"validate",value:function(r,n){return!0}}]),t})(),f3=(function(t){wt(r,t);var e=Tt(r);function r(n,i,a,s,o){var l;return yt(this,r),l=e.call(this),l.value=n,l.validateValue=i,l.setValue=a,l.priority=s,o&&(l.subPriority=o),l}return bt(r,[{key:"validate",value:function(i,a){return this.validateValue(i,this.value,a)}},{key:"set",value:function(i,a,s){return this.setValue(i,a,this.value,s)}}]),r})(UR),d3=(function(t){wt(r,t);var e=Tt(r);function r(){var n;yt(this,r);for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=e.call.apply(e,[this].concat(a)),fe(ge(n),"priority",c3),fe(ge(n),"subPriority",-1),n}return bt(r,[{key:"set",value:function(i,a){if(a.timestampIsSet)return i;var s=new Date(0);return s.setFullYear(i.getUTCFullYear(),i.getUTCMonth(),i.getUTCDate()),s.setHours(i.getUTCHours(),i.getUTCMinutes(),i.getUTCSeconds(),i.getUTCMilliseconds()),s}}]),r})(UR),It=(function(){function t(){yt(this,t),fe(this,"incompatibleTokens",void 0),fe(this,"priority",void 0),fe(this,"subPriority",void 0)}return bt(t,[{key:"run",value:function(r,n,i,a){var s=this.parse(r,n,i,a);return s?{setter:new f3(s.value,this.validate,this.set,this.priority,this.subPriority),rest:s.rest}:null}},{key:"validate",value:function(r,n,i){return!0}}]),t})(),h3=(function(t){wt(r,t);var e=Tt(r);function r(){var n;yt(this,r);for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=e.call.apply(e,[this].concat(a)),fe(ge(n),"priority",140),fe(ge(n),"incompatibleTokens",["R","u","t","T"]),n}return bt(r,[{key:"parse",value:function(i,a,s){switch(a){case"G":case"GG":case"GGG":return s.era(i,{width:"abbreviated"})||s.era(i,{width:"narrow"});case"GGGGG":return s.era(i,{width:"narrow"});case"GGGG":default:return s.era(i,{width:"wide"})||s.era(i,{width:"abbreviated"})||s.era(i,{width:"narrow"})}}},{key:"set",value:function(i,a,s){return a.era=s,i.setUTCFullYear(s,0,1),i.setUTCHours(0,0,0,0),i}}]),r})(It),pr={month:/^(1[0-2]|0?\d)/,date:/^(3[0-1]|[0-2]?\d)/,dayOfYear:/^(36[0-6]|3[0-5]\d|[0-2]?\d?\d)/,week:/^(5[0-3]|[0-4]?\d)/,hour23h:/^(2[0-3]|[0-1]?\d)/,hour24h:/^(2[0-4]|[0-1]?\d)/,hour11h:/^(1[0-1]|0?\d)/,hour12h:/^(1[0-2]|0?\d)/,minute:/^[0-5]?\d/,second:/^[0-5]?\d/,singleDigit:/^\d/,twoDigits:/^\d{1,2}/,threeDigits:/^\d{1,3}/,fourDigits:/^\d{1,4}/,anyDigitsSigned:/^-?\d+/,singleDigitSigned:/^-?\d/,twoDigitsSigned:/^-?\d{1,2}/,threeDigitsSigned:/^-?\d{1,3}/,fourDigitsSigned:/^-?\d{1,4}/},di={basicOptionalMinutes:/^([+-])(\d{2})(\d{2})?|Z/,basic:/^([+-])(\d{2})(\d{2})|Z/,basicOptionalSeconds:/^([+-])(\d{2})(\d{2})((\d{2}))?|Z/,extended:/^([+-])(\d{2}):(\d{2})|Z/,extendedOptionalSeconds:/^([+-])(\d{2}):(\d{2})(:(\d{2}))?|Z/};function gr(t,e){return t&&{value:e(t.value),rest:t.rest}}function nr(t,e){var r=e.match(t);return r?{value:parseInt(r[0],10),rest:e.slice(r[0].length)}:null}function hi(t,e){var r=e.match(t);if(!r)return null;if(r[0]==="Z")return{value:0,rest:e.slice(1)};var n=r[1]==="+"?1:-1,i=r[2]?parseInt(r[2],10):0,a=r[3]?parseInt(r[3],10):0,s=r[5]?parseInt(r[5],10):0;return{value:n*(i*Cd+a*Sd+s*_B),rest:e.slice(r[0].length)}}function qR(t){return nr(pr.anyDigitsSigned,t)}function cr(t,e){switch(t){case 1:return nr(pr.singleDigit,e);case 2:return nr(pr.twoDigits,e);case 3:return nr(pr.threeDigits,e);case 4:return nr(pr.fourDigits,e);default:return nr(new RegExp("^\\d{1,"+t+"}"),e)}}function Uf(t,e){switch(t){case 1:return nr(pr.singleDigitSigned,e);case 2:return nr(pr.twoDigitsSigned,e);case 3:return nr(pr.threeDigitsSigned,e);case 4:return nr(pr.fourDigitsSigned,e);default:return nr(new RegExp("^-?\\d{1,"+t+"}"),e)}}function H0(t){switch(t){case"morning":return 4;case"evening":return 17;case"pm":case"noon":case"afternoon":return 12;case"am":case"midnight":case"night":default:return 0}}function HR(t,e){var r=e>0,n=r?e:1-e,i;if(n<=50)i=t||100;else{var a=n+50,s=Math.floor(a/100)*100,o=t>=a%100;i=t+s-(o?100:0)}return r?i:1-i}function WR(t){return t%400===0||t%4===0&&t%100!==0}var p3=(function(t){wt(r,t);var e=Tt(r);function r(){var n;yt(this,r);for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=e.call.apply(e,[this].concat(a)),fe(ge(n),"priority",130),fe(ge(n),"incompatibleTokens",["Y","R","u","w","I","i","e","c","t","T"]),n}return bt(r,[{key:"parse",value:function(i,a,s){var o=function(c){return{year:c,isTwoDigitYear:a==="yy"}};switch(a){case"y":return gr(cr(4,i),o);case"yo":return gr(s.ordinalNumber(i,{unit:"year"}),o);default:return gr(cr(a.length,i),o)}}},{key:"validate",value:function(i,a){return a.isTwoDigitYear||a.year>0}},{key:"set",value:function(i,a,s){var o=i.getUTCFullYear();if(s.isTwoDigitYear){var l=HR(s.year,o);return i.setUTCFullYear(l,0,1),i.setUTCHours(0,0,0,0),i}var c=!("era"in a)||a.era===1?s.year:1-s.year;return i.setUTCFullYear(c,0,1),i.setUTCHours(0,0,0,0),i}}]),r})(It),g3=(function(t){wt(r,t);var e=Tt(r);function r(){var n;yt(this,r);for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=e.call.apply(e,[this].concat(a)),fe(ge(n),"priority",130),fe(ge(n),"incompatibleTokens",["y","R","u","Q","q","M","L","I","d","D","i","t","T"]),n}return bt(r,[{key:"parse",value:function(i,a,s){var o=function(c){return{year:c,isTwoDigitYear:a==="YY"}};switch(a){case"Y":return gr(cr(4,i),o);case"Yo":return gr(s.ordinalNumber(i,{unit:"year"}),o);default:return gr(cr(a.length,i),o)}}},{key:"validate",value:function(i,a){return a.isTwoDigitYear||a.year>0}},{key:"set",value:function(i,a,s,o){var l=U0(i,o);if(s.isTwoDigitYear){var c=HR(s.year,l);return i.setUTCFullYear(c,0,o.firstWeekContainsDate),i.setUTCHours(0,0,0,0),ds(i,o)}var d=!("era"in a)||a.era===1?s.year:1-s.year;return i.setUTCFullYear(d,0,o.firstWeekContainsDate),i.setUTCHours(0,0,0,0),ds(i,o)}}]),r})(It),m3=(function(t){wt(r,t);var e=Tt(r);function r(){var n;yt(this,r);for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=e.call.apply(e,[this].concat(a)),fe(ge(n),"priority",130),fe(ge(n),"incompatibleTokens",["G","y","Y","u","Q","q","M","L","w","d","D","e","c","t","T"]),n}return bt(r,[{key:"parse",value:function(i,a){return Uf(a==="R"?4:a.length,i)}},{key:"set",value:function(i,a,s){var o=new Date(0);return o.setUTCFullYear(s,0,4),o.setUTCHours(0,0,0,0),lo(o)}}]),r})(It),v3=(function(t){wt(r,t);var e=Tt(r);function r(){var n;yt(this,r);for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=e.call.apply(e,[this].concat(a)),fe(ge(n),"priority",130),fe(ge(n),"incompatibleTokens",["G","y","Y","R","w","I","i","e","c","t","T"]),n}return bt(r,[{key:"parse",value:function(i,a){return Uf(a==="u"?4:a.length,i)}},{key:"set",value:function(i,a,s){return i.setUTCFullYear(s,0,1),i.setUTCHours(0,0,0,0),i}}]),r})(It),y3=(function(t){wt(r,t);var e=Tt(r);function r(){var n;yt(this,r);for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=e.call.apply(e,[this].concat(a)),fe(ge(n),"priority",120),fe(ge(n),"incompatibleTokens",["Y","R","q","M","L","w","I","d","D","i","e","c","t","T"]),n}return bt(r,[{key:"parse",value:function(i,a,s){switch(a){case"Q":case"QQ":return cr(a.length,i);case"Qo":return s.ordinalNumber(i,{unit:"quarter"});case"QQQ":return s.quarter(i,{width:"abbreviated",context:"formatting"})||s.quarter(i,{width:"narrow",context:"formatting"});case"QQQQQ":return s.quarter(i,{width:"narrow",context:"formatting"});case"QQQQ":default:return s.quarter(i,{width:"wide",context:"formatting"})||s.quarter(i,{width:"abbreviated",context:"formatting"})||s.quarter(i,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(i,a){return a>=1&&a<=4}},{key:"set",value:function(i,a,s){return i.setUTCMonth((s-1)*3,1),i.setUTCHours(0,0,0,0),i}}]),r})(It),b3=(function(t){wt(r,t);var e=Tt(r);function r(){var n;yt(this,r);for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=e.call.apply(e,[this].concat(a)),fe(ge(n),"priority",120),fe(ge(n),"incompatibleTokens",["Y","R","Q","M","L","w","I","d","D","i","e","c","t","T"]),n}return bt(r,[{key:"parse",value:function(i,a,s){switch(a){case"q":case"qq":return cr(a.length,i);case"qo":return s.ordinalNumber(i,{unit:"quarter"});case"qqq":return s.quarter(i,{width:"abbreviated",context:"standalone"})||s.quarter(i,{width:"narrow",context:"standalone"});case"qqqqq":return s.quarter(i,{width:"narrow",context:"standalone"});case"qqqq":default:return s.quarter(i,{width:"wide",context:"standalone"})||s.quarter(i,{width:"abbreviated",context:"standalone"})||s.quarter(i,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(i,a){return a>=1&&a<=4}},{key:"set",value:function(i,a,s){return i.setUTCMonth((s-1)*3,1),i.setUTCHours(0,0,0,0),i}}]),r})(It),_3=(function(t){wt(r,t);var e=Tt(r);function r(){var n;yt(this,r);for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=e.call.apply(e,[this].concat(a)),fe(ge(n),"incompatibleTokens",["Y","R","q","Q","L","w","I","D","i","e","c","t","T"]),fe(ge(n),"priority",110),n}return bt(r,[{key:"parse",value:function(i,a,s){var o=function(c){return c-1};switch(a){case"M":return gr(nr(pr.month,i),o);case"MM":return gr(cr(2,i),o);case"Mo":return gr(s.ordinalNumber(i,{unit:"month"}),o);case"MMM":return s.month(i,{width:"abbreviated",context:"formatting"})||s.month(i,{width:"narrow",context:"formatting"});case"MMMMM":return s.month(i,{width:"narrow",context:"formatting"});case"MMMM":default:return s.month(i,{width:"wide",context:"formatting"})||s.month(i,{width:"abbreviated",context:"formatting"})||s.month(i,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(i,a){return a>=0&&a<=11}},{key:"set",value:function(i,a,s){return i.setUTCMonth(s,1),i.setUTCHours(0,0,0,0),i}}]),r})(It),x3=(function(t){wt(r,t);var e=Tt(r);function r(){var n;yt(this,r);for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=e.call.apply(e,[this].concat(a)),fe(ge(n),"priority",110),fe(ge(n),"incompatibleTokens",["Y","R","q","Q","M","w","I","D","i","e","c","t","T"]),n}return bt(r,[{key:"parse",value:function(i,a,s){var o=function(c){return c-1};switch(a){case"L":return gr(nr(pr.month,i),o);case"LL":return gr(cr(2,i),o);case"Lo":return gr(s.ordinalNumber(i,{unit:"month"}),o);case"LLL":return s.month(i,{width:"abbreviated",context:"standalone"})||s.month(i,{width:"narrow",context:"standalone"});case"LLLLL":return s.month(i,{width:"narrow",context:"standalone"});case"LLLL":default:return s.month(i,{width:"wide",context:"standalone"})||s.month(i,{width:"abbreviated",context:"standalone"})||s.month(i,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(i,a){return a>=0&&a<=11}},{key:"set",value:function(i,a,s){return i.setUTCMonth(s,1),i.setUTCHours(0,0,0,0),i}}]),r})(It);function w3(t,e,r){ye(2,arguments);var n=Ee(t),i=_t(e),a=LR(n,r)-i;return n.setUTCDate(n.getUTCDate()-a*7),n}var T3=(function(t){wt(r,t);var e=Tt(r);function r(){var n;yt(this,r);for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=e.call.apply(e,[this].concat(a)),fe(ge(n),"priority",100),fe(ge(n),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","i","t","T"]),n}return bt(r,[{key:"parse",value:function(i,a,s){switch(a){case"w":return nr(pr.week,i);case"wo":return s.ordinalNumber(i,{unit:"week"});default:return cr(a.length,i)}}},{key:"validate",value:function(i,a){return a>=1&&a<=53}},{key:"set",value:function(i,a,s,o){return ds(w3(i,s,o),o)}}]),r})(It);function S3(t,e){ye(2,arguments);var r=Ee(t),n=_t(e),i=PR(r)-n;return r.setUTCDate(r.getUTCDate()-i*7),r}var C3=(function(t){wt(r,t);var e=Tt(r);function r(){var n;yt(this,r);for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=e.call.apply(e,[this].concat(a)),fe(ge(n),"priority",100),fe(ge(n),"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","e","c","t","T"]),n}return bt(r,[{key:"parse",value:function(i,a,s){switch(a){case"I":return nr(pr.week,i);case"Io":return s.ordinalNumber(i,{unit:"week"});default:return cr(a.length,i)}}},{key:"validate",value:function(i,a){return a>=1&&a<=53}},{key:"set",value:function(i,a,s){return lo(S3(i,s))}}]),r})(It),E3=[31,28,31,30,31,30,31,31,30,31,30,31],O3=[31,29,31,30,31,30,31,31,30,31,30,31],A3=(function(t){wt(r,t);var e=Tt(r);function r(){var n;yt(this,r);for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=e.call.apply(e,[this].concat(a)),fe(ge(n),"priority",90),fe(ge(n),"subPriority",1),fe(ge(n),"incompatibleTokens",["Y","R","q","Q","w","I","D","i","e","c","t","T"]),n}return bt(r,[{key:"parse",value:function(i,a,s){switch(a){case"d":return nr(pr.date,i);case"do":return s.ordinalNumber(i,{unit:"date"});default:return cr(a.length,i)}}},{key:"validate",value:function(i,a){var s=i.getUTCFullYear(),o=WR(s),l=i.getUTCMonth();return o?a>=1&&a<=O3[l]:a>=1&&a<=E3[l]}},{key:"set",value:function(i,a,s){return i.setUTCDate(s),i.setUTCHours(0,0,0,0),i}}]),r})(It),I3=(function(t){wt(r,t);var e=Tt(r);function r(){var n;yt(this,r);for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=e.call.apply(e,[this].concat(a)),fe(ge(n),"priority",90),fe(ge(n),"subpriority",1),fe(ge(n),"incompatibleTokens",["Y","R","q","Q","M","L","w","I","d","E","i","e","c","t","T"]),n}return bt(r,[{key:"parse",value:function(i,a,s){switch(a){case"D":case"DD":return nr(pr.dayOfYear,i);case"Do":return s.ordinalNumber(i,{unit:"date"});default:return cr(a.length,i)}}},{key:"validate",value:function(i,a){var s=i.getUTCFullYear(),o=WR(s);return o?a>=1&&a<=366:a>=1&&a<=365}},{key:"set",value:function(i,a,s){return i.setUTCMonth(0,s),i.setUTCHours(0,0,0,0),i}}]),r})(It);function W0(t,e,r){var n,i,a,s,o,l,c,d;ye(2,arguments);var h=Wi(),g=_t((n=(i=(a=(s=r==null?void 0:r.weekStartsOn)!==null&&s!==void 0?s:r==null||(o=r.locale)===null||o===void 0||(l=o.options)===null||l===void 0?void 0:l.weekStartsOn)!==null&&a!==void 0?a:h.weekStartsOn)!==null&&i!==void 0?i:(c=h.locale)===null||c===void 0||(d=c.options)===null||d===void 0?void 0:d.weekStartsOn)!==null&&n!==void 0?n:0);if(!(g>=0&&g<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var m=Ee(t),v=_t(e),b=m.getUTCDay(),y=v%7,x=(y+7)%7,w=(x<g?7:0)+v-b;return m.setUTCDate(m.getUTCDate()+w),m}var R3=(function(t){wt(r,t);var e=Tt(r);function r(){var n;yt(this,r);for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=e.call.apply(e,[this].concat(a)),fe(ge(n),"priority",90),fe(ge(n),"incompatibleTokens",["D","i","e","c","t","T"]),n}return bt(r,[{key:"parse",value:function(i,a,s){switch(a){case"E":case"EE":case"EEE":return s.day(i,{width:"abbreviated",context:"formatting"})||s.day(i,{width:"short",context:"formatting"})||s.day(i,{width:"narrow",context:"formatting"});case"EEEEE":return s.day(i,{width:"narrow",context:"formatting"});case"EEEEEE":return s.day(i,{width:"short",context:"formatting"})||s.day(i,{width:"narrow",context:"formatting"});case"EEEE":default:return s.day(i,{width:"wide",context:"formatting"})||s.day(i,{width:"abbreviated",context:"formatting"})||s.day(i,{width:"short",context:"formatting"})||s.day(i,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(i,a){return a>=0&&a<=6}},{key:"set",value:function(i,a,s,o){return i=W0(i,s,o),i.setUTCHours(0,0,0,0),i}}]),r})(It),D3=(function(t){wt(r,t);var e=Tt(r);function r(){var n;yt(this,r);for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=e.call.apply(e,[this].concat(a)),fe(ge(n),"priority",90),fe(ge(n),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","c","t","T"]),n}return bt(r,[{key:"parse",value:function(i,a,s,o){var l=function(d){var h=Math.floor((d-1)/7)*7;return(d+o.weekStartsOn+6)%7+h};switch(a){case"e":case"ee":return gr(cr(a.length,i),l);case"eo":return gr(s.ordinalNumber(i,{unit:"day"}),l);case"eee":return s.day(i,{width:"abbreviated",context:"formatting"})||s.day(i,{width:"short",context:"formatting"})||s.day(i,{width:"narrow",context:"formatting"});case"eeeee":return s.day(i,{width:"narrow",context:"formatting"});case"eeeeee":return s.day(i,{width:"short",context:"formatting"})||s.day(i,{width:"narrow",context:"formatting"});case"eeee":default:return s.day(i,{width:"wide",context:"formatting"})||s.day(i,{width:"abbreviated",context:"formatting"})||s.day(i,{width:"short",context:"formatting"})||s.day(i,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(i,a){return a>=0&&a<=6}},{key:"set",value:function(i,a,s,o){return i=W0(i,s,o),i.setUTCHours(0,0,0,0),i}}]),r})(It),M3=(function(t){wt(r,t);var e=Tt(r);function r(){var n;yt(this,r);for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=e.call.apply(e,[this].concat(a)),fe(ge(n),"priority",90),fe(ge(n),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","e","t","T"]),n}return bt(r,[{key:"parse",value:function(i,a,s,o){var l=function(d){var h=Math.floor((d-1)/7)*7;return(d+o.weekStartsOn+6)%7+h};switch(a){case"c":case"cc":return gr(cr(a.length,i),l);case"co":return gr(s.ordinalNumber(i,{unit:"day"}),l);case"ccc":return s.day(i,{width:"abbreviated",context:"standalone"})||s.day(i,{width:"short",context:"standalone"})||s.day(i,{width:"narrow",context:"standalone"});case"ccccc":return s.day(i,{width:"narrow",context:"standalone"});case"cccccc":return s.day(i,{width:"short",context:"standalone"})||s.day(i,{width:"narrow",context:"standalone"});case"cccc":default:return s.day(i,{width:"wide",context:"standalone"})||s.day(i,{width:"abbreviated",context:"standalone"})||s.day(i,{width:"short",context:"standalone"})||s.day(i,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(i,a){return a>=0&&a<=6}},{key:"set",value:function(i,a,s,o){return i=W0(i,s,o),i.setUTCHours(0,0,0,0),i}}]),r})(It);function P3(t,e){ye(2,arguments);var r=_t(e);r%7===0&&(r=r-7);var n=1,i=Ee(t),a=i.getUTCDay(),s=r%7,o=(s+7)%7,l=(o<n?7:0)+r-a;return i.setUTCDate(i.getUTCDate()+l),i}var L3=(function(t){wt(r,t);var e=Tt(r);function r(){var n;yt(this,r);for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=e.call.apply(e,[this].concat(a)),fe(ge(n),"priority",90),fe(ge(n),"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","E","e","c","t","T"]),n}return bt(r,[{key:"parse",value:function(i,a,s){var o=function(c){return c===0?7:c};switch(a){case"i":case"ii":return cr(a.length,i);case"io":return s.ordinalNumber(i,{unit:"day"});case"iii":return gr(s.day(i,{width:"abbreviated",context:"formatting"})||s.day(i,{width:"short",context:"formatting"})||s.day(i,{width:"narrow",context:"formatting"}),o);case"iiiii":return gr(s.day(i,{width:"narrow",context:"formatting"}),o);case"iiiiii":return gr(s.day(i,{width:"short",context:"formatting"})||s.day(i,{width:"narrow",context:"formatting"}),o);case"iiii":default:return gr(s.day(i,{width:"wide",context:"formatting"})||s.day(i,{width:"abbreviated",context:"formatting"})||s.day(i,{width:"short",context:"formatting"})||s.day(i,{width:"narrow",context:"formatting"}),o)}}},{key:"validate",value:function(i,a){return a>=1&&a<=7}},{key:"set",value:function(i,a,s){return i=P3(i,s),i.setUTCHours(0,0,0,0),i}}]),r})(It),N3=(function(t){wt(r,t);var e=Tt(r);function r(){var n;yt(this,r);for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=e.call.apply(e,[this].concat(a)),fe(ge(n),"priority",80),fe(ge(n),"incompatibleTokens",["b","B","H","k","t","T"]),n}return bt(r,[{key:"parse",value:function(i,a,s){switch(a){case"a":case"aa":case"aaa":return s.dayPeriod(i,{width:"abbreviated",context:"formatting"})||s.dayPeriod(i,{width:"narrow",context:"formatting"});case"aaaaa":return s.dayPeriod(i,{width:"narrow",context:"formatting"});case"aaaa":default:return s.dayPeriod(i,{width:"wide",context:"formatting"})||s.dayPeriod(i,{width:"abbreviated",context:"formatting"})||s.dayPeriod(i,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(i,a,s){return i.setUTCHours(H0(s),0,0,0),i}}]),r})(It),F3=(function(t){wt(r,t);var e=Tt(r);function r(){var n;yt(this,r);for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=e.call.apply(e,[this].concat(a)),fe(ge(n),"priority",80),fe(ge(n),"incompatibleTokens",["a","B","H","k","t","T"]),n}return bt(r,[{key:"parse",value:function(i,a,s){switch(a){case"b":case"bb":case"bbb":return s.dayPeriod(i,{width:"abbreviated",context:"formatting"})||s.dayPeriod(i,{width:"narrow",context:"formatting"});case"bbbbb":return s.dayPeriod(i,{width:"narrow",context:"formatting"});case"bbbb":default:return s.dayPeriod(i,{width:"wide",context:"formatting"})||s.dayPeriod(i,{width:"abbreviated",context:"formatting"})||s.dayPeriod(i,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(i,a,s){return i.setUTCHours(H0(s),0,0,0),i}}]),r})(It),k3=(function(t){wt(r,t);var e=Tt(r);function r(){var n;yt(this,r);for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=e.call.apply(e,[this].concat(a)),fe(ge(n),"priority",80),fe(ge(n),"incompatibleTokens",["a","b","t","T"]),n}return bt(r,[{key:"parse",value:function(i,a,s){switch(a){case"B":case"BB":case"BBB":return s.dayPeriod(i,{width:"abbreviated",context:"formatting"})||s.dayPeriod(i,{width:"narrow",context:"formatting"});case"BBBBB":return s.dayPeriod(i,{width:"narrow",context:"formatting"});case"BBBB":default:return s.dayPeriod(i,{width:"wide",context:"formatting"})||s.dayPeriod(i,{width:"abbreviated",context:"formatting"})||s.dayPeriod(i,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(i,a,s){return i.setUTCHours(H0(s),0,0,0),i}}]),r})(It),j3=(function(t){wt(r,t);var e=Tt(r);function r(){var n;yt(this,r);for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=e.call.apply(e,[this].concat(a)),fe(ge(n),"priority",70),fe(ge(n),"incompatibleTokens",["H","K","k","t","T"]),n}return bt(r,[{key:"parse",value:function(i,a,s){switch(a){case"h":return nr(pr.hour12h,i);case"ho":return s.ordinalNumber(i,{unit:"hour"});default:return cr(a.length,i)}}},{key:"validate",value:function(i,a){return a>=1&&a<=12}},{key:"set",value:function(i,a,s){var o=i.getUTCHours()>=12;return o&&s<12?i.setUTCHours(s+12,0,0,0):!o&&s===12?i.setUTCHours(0,0,0,0):i.setUTCHours(s,0,0,0),i}}]),r})(It),$3=(function(t){wt(r,t);var e=Tt(r);function r(){var n;yt(this,r);for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=e.call.apply(e,[this].concat(a)),fe(ge(n),"priority",70),fe(ge(n),"incompatibleTokens",["a","b","h","K","k","t","T"]),n}return bt(r,[{key:"parse",value:function(i,a,s){switch(a){case"H":return nr(pr.hour23h,i);case"Ho":return s.ordinalNumber(i,{unit:"hour"});default:return cr(a.length,i)}}},{key:"validate",value:function(i,a){return a>=0&&a<=23}},{key:"set",value:function(i,a,s){return i.setUTCHours(s,0,0,0),i}}]),r})(It),U3=(function(t){wt(r,t);var e=Tt(r);function r(){var n;yt(this,r);for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=e.call.apply(e,[this].concat(a)),fe(ge(n),"priority",70),fe(ge(n),"incompatibleTokens",["h","H","k","t","T"]),n}return bt(r,[{key:"parse",value:function(i,a,s){switch(a){case"K":return nr(pr.hour11h,i);case"Ko":return s.ordinalNumber(i,{unit:"hour"});default:return cr(a.length,i)}}},{key:"validate",value:function(i,a){return a>=0&&a<=11}},{key:"set",value:function(i,a,s){var o=i.getUTCHours()>=12;return o&&s<12?i.setUTCHours(s+12,0,0,0):i.setUTCHours(s,0,0,0),i}}]),r})(It),q3=(function(t){wt(r,t);var e=Tt(r);function r(){var n;yt(this,r);for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=e.call.apply(e,[this].concat(a)),fe(ge(n),"priority",70),fe(ge(n),"incompatibleTokens",["a","b","h","H","K","t","T"]),n}return bt(r,[{key:"parse",value:function(i,a,s){switch(a){case"k":return nr(pr.hour24h,i);case"ko":return s.ordinalNumber(i,{unit:"hour"});default:return cr(a.length,i)}}},{key:"validate",value:function(i,a){return a>=1&&a<=24}},{key:"set",value:function(i,a,s){var o=s<=24?s%24:s;return i.setUTCHours(o,0,0,0),i}}]),r})(It),H3=(function(t){wt(r,t);var e=Tt(r);function r(){var n;yt(this,r);for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=e.call.apply(e,[this].concat(a)),fe(ge(n),"priority",60),fe(ge(n),"incompatibleTokens",["t","T"]),n}return bt(r,[{key:"parse",value:function(i,a,s){switch(a){case"m":return nr(pr.minute,i);case"mo":return s.ordinalNumber(i,{unit:"minute"});default:return cr(a.length,i)}}},{key:"validate",value:function(i,a){return a>=0&&a<=59}},{key:"set",value:function(i,a,s){return i.setUTCMinutes(s,0,0),i}}]),r})(It),W3=(function(t){wt(r,t);var e=Tt(r);function r(){var n;yt(this,r);for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=e.call.apply(e,[this].concat(a)),fe(ge(n),"priority",50),fe(ge(n),"incompatibleTokens",["t","T"]),n}return bt(r,[{key:"parse",value:function(i,a,s){switch(a){case"s":return nr(pr.second,i);case"so":return s.ordinalNumber(i,{unit:"second"});default:return cr(a.length,i)}}},{key:"validate",value:function(i,a){return a>=0&&a<=59}},{key:"set",value:function(i,a,s){return i.setUTCSeconds(s,0),i}}]),r})(It),B3=(function(t){wt(r,t);var e=Tt(r);function r(){var n;yt(this,r);for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=e.call.apply(e,[this].concat(a)),fe(ge(n),"priority",30),fe(ge(n),"incompatibleTokens",["t","T"]),n}return bt(r,[{key:"parse",value:function(i,a){var s=function(l){return Math.floor(l*Math.pow(10,-a.length+3))};return gr(cr(a.length,i),s)}},{key:"set",value:function(i,a,s){return i.setUTCMilliseconds(s),i}}]),r})(It),z3=(function(t){wt(r,t);var e=Tt(r);function r(){var n;yt(this,r);for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=e.call.apply(e,[this].concat(a)),fe(ge(n),"priority",10),fe(ge(n),"incompatibleTokens",["t","T","x"]),n}return bt(r,[{key:"parse",value:function(i,a){switch(a){case"X":return hi(di.basicOptionalMinutes,i);case"XX":return hi(di.basic,i);case"XXXX":return hi(di.basicOptionalSeconds,i);case"XXXXX":return hi(di.extendedOptionalSeconds,i);case"XXX":default:return hi(di.extended,i)}}},{key:"set",value:function(i,a,s){return a.timestampIsSet?i:new Date(i.getTime()-s)}}]),r})(It),V3=(function(t){wt(r,t);var e=Tt(r);function r(){var n;yt(this,r);for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=e.call.apply(e,[this].concat(a)),fe(ge(n),"priority",10),fe(ge(n),"incompatibleTokens",["t","T","X"]),n}return bt(r,[{key:"parse",value:function(i,a){switch(a){case"x":return hi(di.basicOptionalMinutes,i);case"xx":return hi(di.basic,i);case"xxxx":return hi(di.basicOptionalSeconds,i);case"xxxxx":return hi(di.extendedOptionalSeconds,i);case"xxx":default:return hi(di.extended,i)}}},{key:"set",value:function(i,a,s){return a.timestampIsSet?i:new Date(i.getTime()-s)}}]),r})(It),G3=(function(t){wt(r,t);var e=Tt(r);function r(){var n;yt(this,r);for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=e.call.apply(e,[this].concat(a)),fe(ge(n),"priority",40),fe(ge(n),"incompatibleTokens","*"),n}return bt(r,[{key:"parse",value:function(i){return qR(i)}},{key:"set",value:function(i,a,s){return[new Date(s*1e3),{timestampIsSet:!0}]}}]),r})(It),K3=(function(t){wt(r,t);var e=Tt(r);function r(){var n;yt(this,r);for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=e.call.apply(e,[this].concat(a)),fe(ge(n),"priority",20),fe(ge(n),"incompatibleTokens","*"),n}return bt(r,[{key:"parse",value:function(i){return qR(i)}},{key:"set",value:function(i,a,s){return[new Date(s),{timestampIsSet:!0}]}}]),r})(It),X3={G:new h3,y:new p3,Y:new g3,R:new m3,u:new v3,Q:new y3,q:new b3,M:new _3,L:new x3,w:new T3,I:new C3,d:new A3,D:new I3,E:new R3,e:new D3,c:new M3,i:new L3,a:new N3,b:new F3,B:new k3,h:new j3,H:new $3,K:new U3,k:new q3,m:new H3,s:new W3,S:new B3,X:new z3,x:new V3,t:new G3,T:new K3},Y3=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,Z3=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,J3=/^'([^]*?)'?$/,Q3=/''/g,ez=/\S/,tz=/[a-zA-Z]/;function BR(t,e,r,n){var i,a,s,o,l,c,d,h,g,m,v,b,y,x,w,S,E,C;ye(3,arguments);var I=String(t),T=String(e),D=Wi(),P=(i=(a=n==null?void 0:n.locale)!==null&&a!==void 0?a:D.locale)!==null&&i!==void 0?i:wd;if(!P.match)throw new RangeError("locale must contain match property");var L=_t((s=(o=(l=(c=n==null?void 0:n.firstWeekContainsDate)!==null&&c!==void 0?c:n==null||(d=n.locale)===null||d===void 0||(h=d.options)===null||h===void 0?void 0:h.firstWeekContainsDate)!==null&&l!==void 0?l:D.firstWeekContainsDate)!==null&&o!==void 0?o:(g=D.locale)===null||g===void 0||(m=g.options)===null||m===void 0?void 0:m.firstWeekContainsDate)!==null&&s!==void 0?s:1);if(!(L>=1&&L<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var F=_t((v=(b=(y=(x=n==null?void 0:n.weekStartsOn)!==null&&x!==void 0?x:n==null||(w=n.locale)===null||w===void 0||(S=w.options)===null||S===void 0?void 0:S.weekStartsOn)!==null&&y!==void 0?y:D.weekStartsOn)!==null&&b!==void 0?b:(E=D.locale)===null||E===void 0||(C=E.options)===null||C===void 0?void 0:C.weekStartsOn)!==null&&v!==void 0?v:0);if(!(F>=0&&F<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(T==="")return I===""?Ee(r):new Date(NaN);var H={firstWeekContainsDate:L,weekStartsOn:F,locale:P},X=[new d3],ee=T.match(Z3).map(function(We){var Se=We[0];if(Se in Fy){var xe=Fy[Se];return xe(We,P.formatLong)}return We}).join("").match(Y3),J=[],te=y1(ee),ce;try{var B=function(){var Se=ce.value;!(n!=null&&n.useAdditionalWeekYearTokens)&&kR(Se)&&kf(Se,T,t),!(n!=null&&n.useAdditionalDayOfYearTokens)&&FR(Se)&&kf(Se,T,t);var xe=Se[0],Ze=X3[xe];if(Ze){var Oe=Ze.incompatibleTokens;if(Array.isArray(Oe)){var Je=J.find(function(ft){return Oe.includes(ft.token)||ft.token===xe});if(Je)throw new RangeError("The format string mustn't contain `".concat(Je.fullToken,"` and `").concat(Se,"` at the same time"))}else if(Ze.incompatibleTokens==="*"&&J.length>0)throw new RangeError("The format string mustn't contain `".concat(Se,"` and any other token at the same time"));J.push({token:xe,fullToken:Se});var Rt=Ze.run(I,Se,P.match,H);if(!Rt)return{v:new Date(NaN)};X.push(Rt.setter),I=Rt.rest}else{if(xe.match(tz))throw new RangeError("Format string contains an unescaped latin alphabet character `"+xe+"`");if(Se==="''"?Se="'":xe==="'"&&(Se=rz(Se)),I.indexOf(Se)===0)I=I.slice(Se.length);else return{v:new Date(NaN)}}};for(te.s();!(ce=te.n()).done;){var ae=B();if(mi(ae)==="object")return ae.v}}catch(We){te.e(We)}finally{te.f()}if(I.length>0&&ez.test(I))return new Date(NaN);var Ce=X.map(function(We){return We.priority}).sort(function(We,Se){return Se-We}).filter(function(We,Se,xe){return xe.indexOf(We)===Se}).map(function(We){return X.filter(function(Se){return Se.priority===We}).sort(function(Se,xe){return xe.subPriority-Se.subPriority})}).map(function(We){return We[0]}),Ae=Ee(r);if(isNaN(Ae.getTime()))return new Date(NaN);var ve=DR(Ae,uo(Ae)),ct={},Ge=y1(Ce),Le;try{for(Ge.s();!(Le=Ge.n()).done;){var Ue=Le.value;if(!Ue.validate(ve,H))return new Date(NaN);var ht=Ue.set(ve,ct,H);Array.isArray(ht)?(ve=ht[0],q0(ct,ht[1])):ve=ht}}catch(We){Ge.e(We)}finally{Ge.f()}return ve}function rz(t){return t.match(J3)[1].replace(Q3,"'")}function nz(t){ye(1,arguments);var e=Ee(t);return e.setMinutes(0,0,0),e}function iz(t){ye(1,arguments);var e=Ee(t);return e.setMilliseconds(0),e}function az(t,e){ye(2,arguments);var r=_t(e);return $0(t,-r)}function cn(t,e){var r;ye(1,arguments);var n=_t((r=e==null?void 0:e.additionalDigits)!==null&&r!==void 0?r:2);if(n!==2&&n!==1&&n!==0)throw new RangeError("additionalDigits must be 0, 1 or 2");if(!(typeof t=="string"||Object.prototype.toString.call(t)==="[object String]"))return new Date(NaN);var i=lz(t),a;if(i.date){var s=cz(i.date,n);a=fz(s.restDateString,s.year)}if(!a||isNaN(a.getTime()))return new Date(NaN);var o=a.getTime(),l=0,c;if(i.time&&(l=dz(i.time),isNaN(l)))return new Date(NaN);if(i.timezone){if(c=hz(i.timezone),isNaN(c))return new Date(NaN)}else{var d=new Date(o+l),h=new Date(0);return h.setFullYear(d.getUTCFullYear(),d.getUTCMonth(),d.getUTCDate()),h.setHours(d.getUTCHours(),d.getUTCMinutes(),d.getUTCSeconds(),d.getUTCMilliseconds()),h}return new Date(o+l+c)}var Yl={dateTimeDelimiter:/[T ]/,timeZoneDelimiter:/[Z ]/i,timezone:/([Z+-].*)$/},sz=/^-?(?:(\d{3})|(\d{2})(?:-?(\d{2}))?|W(\d{2})(?:-?(\d{1}))?|)$/,oz=/^(\d{2}(?:[.,]\d*)?)(?::?(\d{2}(?:[.,]\d*)?))?(?::?(\d{2}(?:[.,]\d*)?))?$/,uz=/^([+-])(\d{2})(?::?(\d{2}))?$/;function lz(t){var e={},r=t.split(Yl.dateTimeDelimiter),n;if(r.length>2)return e;if(/:/.test(r[0])?n=r[0]:(e.date=r[0],n=r[1],Yl.timeZoneDelimiter.test(e.date)&&(e.date=t.split(Yl.timeZoneDelimiter)[0],n=t.substr(e.date.length,t.length))),n){var i=Yl.timezone.exec(n);i?(e.time=n.replace(i[1],""),e.timezone=i[1]):e.time=n}return e}function cz(t,e){var r=new RegExp("^(?:(\\d{4}|[+-]\\d{"+(4+e)+"})|(\\d{2}|[+-]\\d{"+(2+e)+"})$)"),n=t.match(r);if(!n)return{year:NaN,restDateString:""};var i=n[1]?parseInt(n[1]):null,a=n[2]?parseInt(n[2]):null;return{year:a===null?i:a*100,restDateString:t.slice((n[1]||n[2]).length)}}function fz(t,e){if(e===null)return new Date(NaN);var r=t.match(sz);if(!r)return new Date(NaN);var n=!!r[4],i=tu(r[1]),a=tu(r[2])-1,s=tu(r[3]),o=tu(r[4]),l=tu(r[5])-1;if(n)return yz(e,o,l)?pz(e,o,l):new Date(NaN);var c=new Date(0);return!mz(e,a,s)||!vz(e,i)?new Date(NaN):(c.setUTCFullYear(e,a,Math.max(i,s)),c)}function tu(t){return t?parseInt(t):1}function dz(t){var e=t.match(oz);if(!e)return NaN;var r=wp(e[1]),n=wp(e[2]),i=wp(e[3]);return bz(r,n,i)?r*Cd+n*Sd+i*1e3:NaN}function wp(t){return t&&parseFloat(t.replace(",","."))||0}function hz(t){if(t==="Z")return 0;var e=t.match(uz);if(!e)return 0;var r=e[1]==="+"?-1:1,n=parseInt(e[2]),i=e[3]&&parseInt(e[3])||0;return _z(n,i)?r*(n*Cd+i*Sd):NaN}function pz(t,e,r){var n=new Date(0);n.setUTCFullYear(t,0,4);var i=n.getUTCDay()||7,a=(e-1)*7+r+1-i;return n.setUTCDate(n.getUTCDate()+a),n}var gz=[31,null,31,30,31,30,31,31,30,31,30,31];function zR(t){return t%400===0||t%4===0&&t%100!==0}function mz(t,e,r){return e>=0&&e<=11&&r>=1&&r<=(gz[e]||(zR(t)?29:28))}function vz(t,e){return e>=1&&e<=(zR(t)?366:365)}function yz(t,e,r){return e>=1&&e<=53&&r>=0&&r<=6}function bz(t,e,r){return t===24?e===0&&r===0:r>=0&&r<60&&e>=0&&e<60&&t>=0&&t<25}function _z(t,e){return e>=0&&e<=59}function xz(t,e){ye(2,arguments);var r=_t(e);return Td(t,-r)}function wz(t,e){if(ye(2,arguments),!e||mi(e)!=="object")return new Date(NaN);var r=e.years?_t(e.years):0,n=e.months?_t(e.months):0,i=e.weeks?_t(e.weeks):0,a=e.days?_t(e.days):0,s=e.hours?_t(e.hours):0,o=e.minutes?_t(e.minutes):0,l=e.seconds?_t(e.seconds):0,c=xz(t,n+r*12),d=az(c,a+i*7),h=o+s*60,g=l+h*60,m=g*1e3,v=new Date(d.getTime()-m);return v}const Tz=t=>{if(t instanceof Date)return t;const e=t.replace(/-/g,"/").replace("T"," "),r=cn(t);return wo(r)?r:BR(e,"dd/MMM/yy HH:mm:ss",new Date)},Sz=(t,e)=>Yu(Tz(t),e),Cz=t=>new Date(t*1e3);var VR=(t=>(t.ACTIVE_ACCOUNT="activeAccount",t.X_AUTH="user-authentication",t))(VR||{});const b1="application/json",Tp={Accept:"Accept",Authorization:"Authorization",ContentType:"Content-Type"},Ez=t=>t.replace(/([^:]\/)\/+/g,"$1"),ri=({pathname:t,searchParams:e})=>{const{globalApiUrl:r}=oB(),n=new URL(r);return n.pathname+=t,n.href=Ez(n.href),e&&Object.entries(e).forEach(([i,a])=>{!ER(a)&&a!==""&&(Array.isArray(a)?a.forEach(s=>n.searchParams.append(i,String(s))):n.searchParams.append(i,String(a)))}),n},B0=()=>{const t=new Headers,e=Rz();return t.set(Tp.Authorization,`Bearer ${e}`),t.set(Tp.Accept,b1),t.set(Tp.ContentType,b1),t},GR=async(t,e)=>{const r=t.toString(),n=await fetch(r,{mode:"cors",...e});return await uB(n),n},Ad=async(t,e,r)=>{const n=await GR(t,e);if(r)return n;try{return await n.json()}catch{return n.ok||console.error("The response is not valid JSON"),""}},Oz=(t,e)=>{const r=B0();return Ad(t,{method:"GET",headers:r},e)},Az=(t,e,r)=>{const n=B0();return Ad(t,{method:"POST",headers:n,body:r?e:JSON.stringify(e)})},Iz=(t,e)=>{const r=B0();return Ad(t,{method:"PUT",headers:r,body:JSON.stringify(e)})};function Rz(){const t=JSON.parse(localStorage.getItem(VR.X_AUTH)||"{}");if(!t.access_token){const e="cannot read x-auth token from local storage";throw console.error(e),new Error(e)}return t.access_token}const ni={baseFetch:GR,get:Oz,handleFetch:Ad,post:Az,put:Iz};var fn=(t=>(t.ACCOUNT="ACCOUNT",t.ACCOUNT_CONTACTS="ACCOUNT_CONTACTS",t.ACCOUNT_ROLES="ACCOUNT_ROLES",t.ACCOUNT_USERS="ACCOUNT_USERS",t.ACCOUNTS="ACCOUNTS",t.ACTIVE_ACCOUNT="ACTIVE_ACCOUNT",t.ALERTS="alerts",t.ASSETS="ASSETS",t.ASSETS_TREE="ASSETS_TREE",t.ATTACHMENTS="ATTACHMENTS",t.ATTACHMENT_CONTENT="ATTACHMENT_CONTENT",t.CANCEL_CS_TICKET="CANCEL_CS_TICKET",t.CANCEL_FA_TICKET="CANCEL_FA_TICKET",t.CANCEL_RH_TICKET="CANCEL_RH_TICKET",t.CANCEL_SR_TICKET="CANCEL_SR_TICKET",t.CATEGORIES="CATEGORIES",t.COMPANIES="COMPANIES",t.CITIES="CITIES",t.CLIENT_SERVICES_TICKET="CLIENT_SERVICES_TICKET",t.CLIENT_SERVICES_TICKETS="CLIENT_SERVICES_TICKETS",t.COOKIES_PREFERENCE="COOKIES_PREFERENCE",t.COURIER_COMPANIES="COURIER_COMPANIES",t.CREATE_ACCOUNT_ROLE="create_account_role",t.CREATE_CUSTOMER_SUPPORT_TICKET="CREATE_CUSTOMER_SUPPORT_TICKET",t.CREATE_NOTIFICATION="CREATE_NOTIFICATION",t.CREATE_PERMISSION_GROUP="create_permission_group",t.CREATE_RELEASE="CREATE_RELEASE",t.CREATE_REMOTE_HANDS_TICKET="CREATE_REMOTE_HANDS_TICKET",t.CREATE_ROLE="CREATE_ROLE",t.CREATE_ROLE_ASSET_PERMISSION="CREATE_ROLE_ASSET_PERMISSION",t.CREATE_ROLE_PERMISSION="CREATE_ROLE_PERMISSION",t.CREATE_ROLE_PERMISSION_GROUP="CREATE_ROLE_PERMISSION_GROUP",t.CUSTOMER_SUPPORT_CONTACTS="CUSTOMER_SUPPORT_CONTACTS",t.CUSTOMER_SUPPORT_TICKETS="CUSTOMER_SUPPORT_TICKETS",t.DATE_FORMAT="DATE_FORMAT",t.DEFAULT_ACCOUNT="DEFAULT_ACCOUNT",t.DELETE_ROLE="DELETE_ROLE",t.DELETE_GROUP_PERMISSION="DELETE_GROUP_PERMISSION",t.DELETE_PERMISSION="DELETE_PERMISSION",t.DELETE_PERMISSION_GROUP="DELETE_PERMISSION_GROUP",t.DCIM_ALERTS="DCIM_ALERTS",t.DCIM_ALERT_INSTANCES="DCIM_ALERT_INSTANCES",t.DCIM_ALERT_INSTANCE_DETAILS="DCIM_ALERT_INSTANCE_DETAILS",t.DCIM_CHART_DATA="DCIM_CHART_DATA",t.DCIM_CHART_DATA_GROUP="DCIM_CHART_DATA_GROUP",t.DCIM_CHART_METADATA="DCIM_CHART_METADATA",t.DCIM_ENABLED_LOCATIONS="DCIM_ENABLED_LOCATIONS",t.DCIM_HISTORICAL_ALERTS="DCIM_HISTORICAL_ALERTS",t.DCIM_HISTORICAL_ALERT_INSTANCE_DETAILS="DCIM_HISTORICAL_ALERT_INSTANCE_DETAILS",t.DCIM_LOCATIONS="DCIM_LOCATIONS",t.DOWNLOAD_USERS="DOWNLOAD_USERS",t.EDIT_ACCOUNT="EDIT_ACCOUNT",t.EDIT_NOTIFICATION="EDIT_NOTIFICATION",t.EDIT_PERMISSION_GROUP="EDIT_PERMISSION_GROUP",t.EDIT_PRIVILEGE="EDIT_PRIVILEGE",t.EDIT_ROLE="EDIT_ROLE",t.EDIT_ROLE_PERMISSION="EDIT_ROLE_PERMISSION",t.EDIT_USER_PERMISSIONS="EDIT_USER_PERMISSIONS",t.EDIT_USER_PREFERENCES="EDIT_USER_PREFERENCES",t.EDIT_USER_PROFILE="EDIT_USER_PROFILE",t.ELEGIBLE_REPORTS="ELEGIBLE_REPORTS",t.FA_TICKET_APPROVE_OR_DENY="FA_TICKET_APPROVE_OR_DENY",t.FACILITY_ACCESS="FACILITY_ACCESS",t.FACILITY_ACCESS_CONTACT_ACCESS="FACILTY_ACCESS_CONTACT_ACCESS",t.FACILITY_ACCESS_CONTACTS="FACILTY_ACCESS_CONTACTS",t.FACILITY_ACCESS_TICKETS="FACILTY_ACCESS_TICKETS",t.LOCATIONS="LOCATIONS",t.LOCATIONS_PAGED="LOCATIONS_PAGED",t.POP_POES_LOCATIONS="POP_POES_LOCATIONS",t.METRICS_FIRST_TIME_LOGIN="METRICS_FIRST_TIME_LOGIN",t.METRICS_LOGIN="metrics_login",t.METRICS_LOGOUT="metrics_logout",t.METROS="metros",t.MODIFY_BADGE="MODIFY_BADGE",t.NOTIFICATION="NOTIFICATION",t.NOTIFICATIONS="NOTIFICATIONS",t.PERMISSION_GROUP_PERMISSIONS="PERMISSION_GROUP_PERMISSIONS",t.PERMISSION_GROUPS="PERMISSION_GROUPS",t.PERMISSIONS="PERMISSIONS",t.PERMISSIONS_PRIVILEGES="PERMISSIONS_PRIVILEGES",t.PERMISSIONS_AVAILABLE="PERMISSIONS_AVAILABLE",t.PLANNED_SITE_MAINTENANCE="PLANNED_SITE_MAINTENANCE",t.PORTAL_ROLES="PORTAL_ROLES",t.POSITIONS="POSITIONS",t.REGIONS="REGIONS",t.RELEASE="RELEASE",t.RELEASE_INFO="RELEASE_INFO",t.REMOVE_ACCOUNT="REMOVE_ACCOUNT",t.REMOVE_ACCOUNT_ROLE="REMOVE_ACCOUNT_ROLE",t.REMOTE_HANDS_TICKET="REMOTE_HANDS_TICKET",t.REMOTE_HANDS_CATEGORIES="REMOTE_HANDS_CATEGORIES",t.REPORT_FILE_DOWNLOAD="REPORT_FILE_DOWNLOAD",t.REPORTS="REPORTS",t.REQUEST_TYPES="REQUEST_TYPES",t.ROLE="ROLE",t.ROLE_ACCESS_PERMISSIONS="ROLE_ACCESS_PERMISSIONS",t.ROLE_ASSET_PERMISSIONS="ROLE_ASSET_PERMISSIONS",t.ROLE_NAMES="ROLE_NAMES",t.ROLE_PERMISSIONS="ROLE_PERMISSIONS",t.ROLE_PERMISSIONS_PRIVILEGES="ROLE_PERMISSIONS_PRIVILEGES",t.ROLE_PERMISSION_GROUP="ROLE_PERMISSION_GROUP",t.ROLES="ROLES",t.SERVICE_TICKETS="SERVICE_TICKETS",t.SERVICE_TICKETS_CANCELLATATION_REASONS="SERVICE_TICKETS_CANCELLATATION_REASONS",t.SET_ACTIVE_USER_ACCOUNT="SET_ACTIVE_USER_ACCOUNT",t.SHIPMENTS_TICKET="SHIPMENTS_TICKET",t.SHIPMENTS_TICKETS="SHIPMENTS_TICKETS",t.SITES="SITES",t.SITES_PAGED="SITES_PAGED",t.SITES_TREE="SITES_TREE",t.SUPPORT_DOWNLOAD="SUPPORT_DOWNLOAD",t.SUPPORT_TICKETS="SUPPORT_TICKETS",t.SUPPORT_TICKET="SUPPORT_TICKET",t.SUPPORT_TICKET_MESSAGES="SUPPORT_TICKET_MESSAGES",t.UNITS="UNITS",t.UNREAD_NOTIFICATIONS="UNREAD_NOTIFICATIONS",t.UPDATE_CUSTOMER_SUPPORT_TICKET="UPDATE_CUSTOMER_SUPPORT_TICKET",t.UPDATE_FA_TICKET="UPDATE_FA_TICKET",t.UPDATE_RELEASE="UPDATE_RELEASE",t.UPDATE_REMOTE_HANDS_TICKET="UPDATE_REMOTE_HANDS_TICKET",t.UPDATE_SHIPMENTS_TICKET="UPDATE_SHIPMENTS_TICKET",t.USER="USER",t.USER_ACCOUNT_CREATORS="USER_ACCOUNT_CREATORS",t.USER_ACCOUNTS="USER_ACCOUNTS",t.USER_ACCOUNT_APPROVALS="USER_ACCOUNT_APPROVALS",t.USER_ACCOUNT_STATUS="USER_ACCOUNT_STATUS",t.USER_ASSIGNMENTS="USER_ASSIGNMENTS",t.USER_BY_EMAIL="USER_BY_EMAIL",t.USER_CREATE="USER_CREATE",t.USER_DETAILS="USER_DETAILS",t.USER_EDIT="USER_EDIT",t.USER_ID="USER_ID",t.USER_INTERNAL_DOMAINS="USER_INTERNAL_DOMAINS",t.USER_IS_ON_BEHALF_OF="USER_IS_ON_BEHALF_OF",t.USER_LOGOUT="USER_LOGOUT",t.USER_ON_BEHALF_OF="USER_ON_BEHALF_OF",t.USER_PREFERENCES="USER_PREFERENCES",t.USER_PROFILE="USER_PROFILE",t.USER_RELEASE="USER_RELEASE",t.USER_UPDATE="USER_UPDATE",t.USERS_CONTACTS="USERS_CONTACTS",t.USERS_LOCATIONS="USERS_LOCATIONS",t.TECHNICAL_SUPPORT_CONTACTS="TECHNICAL_SUPPORT_CONTACTS",t.TIME_ZONE="TIME_ZONE",t.TIME_ZONE_WINDOWS_IANA="TIME_ZONE_WINDOWS_IANA",t.UPLOAD_ATTACHMENTS="UPLOAD_ATTACHMENTS",t.VALIDATE_ROLE="VALIDATE_ROLE",t.WORK_ORDER_DETAILS="WORK_ORDER_DETAILS",t.WORK_ORDERS="WORK_ORDERS",t.CONTACT_US="CONTACT_US",t))(fn||{});const KR={xs:0,sm:600,md:900,lg:1200,xl:1536},Et=t=>`(max-width:${KR[t]-.05}px)`,pa=t=>`(min-width:${KR[t]}px)`,Dz=(t,e)=>`${pa(t)} and ${Et(e)}`,Ve=t=>{const e=rt(n=>{const i=window.matchMedia(t);return i.addEventListener?(i.addEventListener("change",n),()=>i.removeEventListener("change",n)):(i.addListener(n),()=>i.removeListener(n))},[t]),r=rt(()=>window.matchMedia(t).matches,[t]);return E0(e,r,()=>!1)},To=()=>{const t=Ve(Et("md")),e=Ve(Dz("sm","lg"));return{isMobile:t,isTablet:e}};var bf=(t=>(t.Hour12="12-hour",t.Hour24="24-hour",t))(bf||{}),qf=(t=>(t.MMddyyyy="MM/dd/yyyy",t.ddMMyyyy="dd/MM/yyyy",t.yyyyMMdd="yyyy/MM/dd",t))(qf||{}),pu=(t=>(t.Hour12="h:mm a",t.Hour24="HH:mm",t))(pu||{});const Mz="MM/dd/yyyy",Hf=(t,e,r="-")=>!t||t===""||t==="-"?r:(typeof t=="number"&&(t=Cz(t)),Sz(t,e||Mz));function _1(t,e,r){return t.includes(r)?r:e}const z0=()=>{const{userPreferences:t}=nB(),e=qf.MMddyyyy,r=bf.Hour12,n=Intl.DateTimeFormat().resolvedOptions().timeZone,i=yr(()=>({dateFormat:_1(Object.values(qf),e,t==null?void 0:t.dateFormat),timeFormat:_1(Object.values(bf),r,t==null?void 0:t.timeFormat),timeZone:(t==null?void 0:t.timeZone)||n}),[e,r,n,t==null?void 0:t.dateFormat,t==null?void 0:t.timeFormat,t==null?void 0:t.timeZone]),a=yr(()=>i.timeFormat===bf.Hour12,[i.timeFormat]),s=rt(c=>{let d=a?"hh:mm aa":"HH:mm";return c&&(d=a?"hh:mm:ss aa":"HH:mm:ss"),d},[a]),o=rt((c,d,h,g)=>{let m=i.dateFormat;return d&&(m=`${m} ${s(h)}`),Hf(c,m,g)},[i.dateFormat,s]),l=rt((c,d,h)=>{const g=s(d);return Hf(c,g,h)},[s]);return{...i,defaultDateFormat:e,defaultTimeFormat:r,defaultTimeZone:n,isTime12Hour:a,formatDateTime:o,formatTime:l,getTimeFormatString:s}};var la=(t=>(t.DEVICE_NAME="deviceName",t.FUNCTION_VALUE="functionValue",t.THRESHOLD="threshold",t))(la||{}),XR=(t=>(t.ASC="asc",t.DESC="desc",t))(XR||{});const Id=()=>{const[t,e]=or({preferredDateFormat:qf.MMddyyyy,preferredTimeFormat:pu.Hour24}),r=()=>{const l=localStorage.getItem("date-format");if(l)try{const c=JSON.parse(l);c&&typeof c=="object"&&e(c)}catch(c){console.error("Error parsing date-format from local storage:",c)}};ut(()=>{r();const l=()=>{r()};return window.addEventListener("dateFormatChanged",l),()=>{window.removeEventListener("dateFormatChanged",l)}},[]);const n=yr(()=>t.preferredTimeFormat===pu.Hour12,[t.preferredTimeFormat]),i=rt(l=>{let c=n?pu.Hour12:pu.Hour24;return l&&(c=n?"hh:mm:ss a":"HH:mm:ss"),c},[n]),a=yr(()=>`${t.preferredDateFormat} ${t.preferredTimeFormat}`,[t]),s=rt((l,c,d,h)=>{let g=t.preferredDateFormat;return c&&(g=`${g} ${i(d)}`),Hf(l,g,h)},[t.preferredDateFormat,i]),o=rt((l,c,d)=>{const h=i(c);return Hf(l,h,d)},[i]);return{dateTimeFormatPreferences:t,dateTimeFormatUserPreferenceString:a,formatDateTime:s,formatTime:o,getTimeFormatString:i}};var gu={exports:{}};/**
|
|
43
|
+
* @license
|
|
44
|
+
* Lodash <https://lodash.com/>
|
|
45
|
+
* Copyright OpenJS Foundation and other contributors <https://openjsf.org/>
|
|
46
|
+
* Released under MIT license <https://lodash.com/license>
|
|
47
|
+
* Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE>
|
|
48
|
+
* Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
|
|
49
|
+
*/var Pz=gu.exports,x1;function Lz(){return x1||(x1=1,(function(t,e){(function(){var r,n="4.18.1",i=200,a="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",s="Expected a function",o="Invalid `variable` option passed into `_.template`",l="Invalid `imports` option passed into `_.template`",c="__lodash_hash_undefined__",d=500,h="__lodash_placeholder__",g=1,m=2,v=4,b=1,y=2,x=1,w=2,S=4,E=8,C=16,I=32,T=64,D=128,P=256,L=512,F=30,H="...",X=800,ee=16,J=1,te=2,ce=3,B=1/0,ae=9007199254740991,Ce=17976931348623157e292,Ae=NaN,ve=4294967295,ct=ve-1,Ge=ve>>>1,Le=[["ary",D],["bind",x],["bindKey",w],["curry",E],["curryRight",C],["flip",L],["partial",I],["partialRight",T],["rearg",P]],Ue="[object Arguments]",ht="[object Array]",We="[object AsyncFunction]",Se="[object Boolean]",xe="[object Date]",Ze="[object DOMException]",Oe="[object Error]",Je="[object Function]",Rt="[object GeneratorFunction]",ft="[object Map]",Ne="[object Number]",Nt="[object Null]",Ot="[object Object]",Lr="[object Promise]",Yr="[object Proxy]",fr="[object RegExp]",W="[object Set]",se="[object String]",ue="[object Symbol]",_e="[object Undefined]",Re="[object WeakMap]",Qe="[object WeakSet]",St="[object ArrayBuffer]",Ct="[object DataView]",Zr="[object Float32Array]",Ur="[object Float64Array]",_i="[object Int8Array]",Rr="[object Int16Array]",En="[object Int32Array]",zn="[object Uint8Array]",z="[object Uint8ClampedArray]",V="[object Uint16Array]",at="[object Uint32Array]",xt=/\b__p \+= '';/g,Dt=/\b(__p \+=) '' \+/g,ke=/(__e\(.*?\)|\b__t\)) \+\n'';/g,qr=/&(?:amp|lt|gt|quot|#39);/g,On=/[&<>"']/g,Tr=RegExp(qr.source),An=RegExp(On.source),Vi=/<%-([\s\S]+?)%>/g,hn=/<%([\s\S]+?)%>/g,br=/<%=([\s\S]+?)%>/g,Es=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Os=/^\w*$/,k=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,U=/[\\^$.*+?()[\]{}|]/g,G=RegExp(U.source),re=/^\s+/,oe=/\s/,we=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,De=/\{\n\/\* \[wrapped with (.+)\] \*/,he=/,? & /,me=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,de=/[()=,{}\[\]\/\s]/,be=/\\(\\)?/g,Fe=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,et=/\w*$/,er=/^[-+]0x[0-9a-f]+$/i,gt=/^0b[01]+$/i,st=/^\[object .+?Constructor\]$/,Wt=/^0o[0-7]+$/i,Vn=/^(?:0|[1-9]\d*)$/,Ia=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,Jr=/($^)/,In=/['\n\r\u2028\u2029\\]/g,Gi="\\ud800-\\udfff",Ra="\\u0300-\\u036f",xi="\\ufe20-\\ufe2f",As="\\u20d0-\\u20ff",Da=Ra+xi+As,mt="\\u2700-\\u27bf",Vt="a-z\\xdf-\\xf6\\xf8-\\xff",Ki="\\xac\\xb1\\xd7\\xf7",Ma="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",ar="\\u2000-\\u206f",Xi=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Mo="A-Z\\xc0-\\xd6\\xd8-\\xde",ll="\\ufe0e\\ufe0f",u_=Ki+Ma+ar+Xi,ih="['’]",EL="["+Gi+"]",l_="["+u_+"]",cl="["+Da+"]",c_="\\d+",OL="["+mt+"]",f_="["+Vt+"]",d_="[^"+Gi+u_+c_+mt+Vt+Mo+"]",ah="\\ud83c[\\udffb-\\udfff]",AL="(?:"+cl+"|"+ah+")",h_="[^"+Gi+"]",sh="(?:\\ud83c[\\udde6-\\uddff]){2}",oh="[\\ud800-\\udbff][\\udc00-\\udfff]",Is="["+Mo+"]",p_="\\u200d",g_="(?:"+f_+"|"+d_+")",IL="(?:"+Is+"|"+d_+")",m_="(?:"+ih+"(?:d|ll|m|re|s|t|ve))?",v_="(?:"+ih+"(?:D|LL|M|RE|S|T|VE))?",y_=AL+"?",b_="["+ll+"]?",RL="(?:"+p_+"(?:"+[h_,sh,oh].join("|")+")"+b_+y_+")*",DL="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",ML="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",__=b_+y_+RL,PL="(?:"+[OL,sh,oh].join("|")+")"+__,LL="(?:"+[h_+cl+"?",cl,sh,oh,EL].join("|")+")",NL=RegExp(ih,"g"),FL=RegExp(cl,"g"),uh=RegExp(ah+"(?="+ah+")|"+LL+__,"g"),kL=RegExp([Is+"?"+f_+"+"+m_+"(?="+[l_,Is,"$"].join("|")+")",IL+"+"+v_+"(?="+[l_,Is+g_,"$"].join("|")+")",Is+"?"+g_+"+"+m_,Is+"+"+v_,ML,DL,c_,PL].join("|"),"g"),jL=RegExp("["+p_+Gi+Da+ll+"]"),$L=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,UL=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],qL=-1,Gt={};Gt[Zr]=Gt[Ur]=Gt[_i]=Gt[Rr]=Gt[En]=Gt[zn]=Gt[z]=Gt[V]=Gt[at]=!0,Gt[Ue]=Gt[ht]=Gt[St]=Gt[Se]=Gt[Ct]=Gt[xe]=Gt[Oe]=Gt[Je]=Gt[ft]=Gt[Ne]=Gt[Ot]=Gt[fr]=Gt[W]=Gt[se]=Gt[Re]=!1;var Bt={};Bt[Ue]=Bt[ht]=Bt[St]=Bt[Ct]=Bt[Se]=Bt[xe]=Bt[Zr]=Bt[Ur]=Bt[_i]=Bt[Rr]=Bt[En]=Bt[ft]=Bt[Ne]=Bt[Ot]=Bt[fr]=Bt[W]=Bt[se]=Bt[ue]=Bt[zn]=Bt[z]=Bt[V]=Bt[at]=!0,Bt[Oe]=Bt[Je]=Bt[Re]=!1;var HL={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},WL={"&":"&","<":"<",">":">",'"':""","'":"'"},BL={"&":"&","<":"<",">":">",""":'"',"'":"'"},zL={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},VL=parseFloat,GL=parseInt,x_=typeof pi=="object"&&pi&&pi.Object===Object&&pi,KL=typeof self=="object"&&self&&self.Object===Object&&self,Dr=x_||KL||Function("return this")(),lh=e&&!e.nodeType&&e,Pa=lh&&!0&&t&&!t.nodeType&&t,w_=Pa&&Pa.exports===lh,ch=w_&&x_.process,Rn=(function(){try{var $=Pa&&Pa.require&&Pa.require("util").types;return $||ch&&ch.binding&&ch.binding("util")}catch{}})(),T_=Rn&&Rn.isArrayBuffer,S_=Rn&&Rn.isDate,C_=Rn&&Rn.isMap,E_=Rn&&Rn.isRegExp,O_=Rn&&Rn.isSet,A_=Rn&&Rn.isTypedArray;function pn($,Y,K){switch(K.length){case 0:return $.call(Y);case 1:return $.call(Y,K[0]);case 2:return $.call(Y,K[0],K[1]);case 3:return $.call(Y,K[0],K[1],K[2])}return $.apply(Y,K)}function XL($,Y,K,pe){for(var je=-1,At=$==null?0:$.length;++je<At;){var _r=$[je];Y(pe,_r,K(_r),$)}return pe}function gn($,Y){for(var K=-1,pe=$==null?0:$.length;++K<pe&&Y($[K],K,$)!==!1;);return $}function YL($,Y){for(var K=$==null?0:$.length;K--&&Y($[K],K,$)!==!1;);return $}function I_($,Y){for(var K=-1,pe=$==null?0:$.length;++K<pe;)if(!Y($[K],K,$))return!1;return!0}function Yi($,Y){for(var K=-1,pe=$==null?0:$.length,je=0,At=[];++K<pe;){var _r=$[K];Y(_r,K,$)&&(At[je++]=_r)}return At}function fl($,Y){var K=$==null?0:$.length;return!!K&&Rs($,Y,0)>-1}function fh($,Y,K){for(var pe=-1,je=$==null?0:$.length;++pe<je;)if(K(Y,$[pe]))return!0;return!1}function Yt($,Y){for(var K=-1,pe=$==null?0:$.length,je=Array(pe);++K<pe;)je[K]=Y($[K],K,$);return je}function Zi($,Y){for(var K=-1,pe=Y.length,je=$.length;++K<pe;)$[je+K]=Y[K];return $}function dh($,Y,K,pe){var je=-1,At=$==null?0:$.length;for(pe&&At&&(K=$[++je]);++je<At;)K=Y(K,$[je],je,$);return K}function ZL($,Y,K,pe){var je=$==null?0:$.length;for(pe&&je&&(K=$[--je]);je--;)K=Y(K,$[je],je,$);return K}function hh($,Y){for(var K=-1,pe=$==null?0:$.length;++K<pe;)if(Y($[K],K,$))return!0;return!1}var JL=ph("length");function QL($){return $.split("")}function eN($){return $.match(me)||[]}function R_($,Y,K){var pe;return K($,function(je,At,_r){if(Y(je,At,_r))return pe=At,!1}),pe}function dl($,Y,K,pe){for(var je=$.length,At=K+(pe?1:-1);pe?At--:++At<je;)if(Y($[At],At,$))return At;return-1}function Rs($,Y,K){return Y===Y?dN($,Y,K):dl($,D_,K)}function tN($,Y,K,pe){for(var je=K-1,At=$.length;++je<At;)if(pe($[je],Y))return je;return-1}function D_($){return $!==$}function M_($,Y){var K=$==null?0:$.length;return K?mh($,Y)/K:Ae}function ph($){return function(Y){return Y==null?r:Y[$]}}function gh($){return function(Y){return $==null?r:$[Y]}}function P_($,Y,K,pe,je){return je($,function(At,_r,qt){K=pe?(pe=!1,At):Y(K,At,_r,qt)}),K}function rN($,Y){var K=$.length;for($.sort(Y);K--;)$[K]=$[K].value;return $}function mh($,Y){for(var K,pe=-1,je=$.length;++pe<je;){var At=Y($[pe]);At!==r&&(K=K===r?At:K+At)}return K}function vh($,Y){for(var K=-1,pe=Array($);++K<$;)pe[K]=Y(K);return pe}function nN($,Y){return Yt(Y,function(K){return[K,$[K]]})}function L_($){return $&&$.slice(0,j_($)+1).replace(re,"")}function mn($){return function(Y){return $(Y)}}function yh($,Y){return Yt(Y,function(K){return $[K]})}function Po($,Y){return $.has(Y)}function N_($,Y){for(var K=-1,pe=$.length;++K<pe&&Rs(Y,$[K],0)>-1;);return K}function F_($,Y){for(var K=$.length;K--&&Rs(Y,$[K],0)>-1;);return K}function iN($,Y){for(var K=$.length,pe=0;K--;)$[K]===Y&&++pe;return pe}var aN=gh(HL),sN=gh(WL);function oN($){return"\\"+zL[$]}function uN($,Y){return $==null?r:$[Y]}function Ds($){return jL.test($)}function lN($){return $L.test($)}function cN($){for(var Y,K=[];!(Y=$.next()).done;)K.push(Y.value);return K}function bh($){var Y=-1,K=Array($.size);return $.forEach(function(pe,je){K[++Y]=[je,pe]}),K}function k_($,Y){return function(K){return $(Y(K))}}function Ji($,Y){for(var K=-1,pe=$.length,je=0,At=[];++K<pe;){var _r=$[K];(_r===Y||_r===h)&&($[K]=h,At[je++]=K)}return At}function hl($){var Y=-1,K=Array($.size);return $.forEach(function(pe){K[++Y]=pe}),K}function fN($){var Y=-1,K=Array($.size);return $.forEach(function(pe){K[++Y]=[pe,pe]}),K}function dN($,Y,K){for(var pe=K-1,je=$.length;++pe<je;)if($[pe]===Y)return pe;return-1}function hN($,Y,K){for(var pe=K+1;pe--;)if($[pe]===Y)return pe;return pe}function Ms($){return Ds($)?gN($):JL($)}function Gn($){return Ds($)?mN($):QL($)}function j_($){for(var Y=$.length;Y--&&oe.test($.charAt(Y)););return Y}var pN=gh(BL);function gN($){for(var Y=uh.lastIndex=0;uh.test($);)++Y;return Y}function mN($){return $.match(uh)||[]}function vN($){return $.match(kL)||[]}var yN=(function $(Y){Y=Y==null?Dr:Ps.defaults(Dr.Object(),Y,Ps.pick(Dr,UL));var K=Y.Array,pe=Y.Date,je=Y.Error,At=Y.Function,_r=Y.Math,qt=Y.Object,_h=Y.RegExp,bN=Y.String,Dn=Y.TypeError,pl=K.prototype,_N=At.prototype,Ls=qt.prototype,gl=Y["__core-js_shared__"],ml=_N.toString,Mt=Ls.hasOwnProperty,xN=0,$_=(function(){var u=/[^.]+$/.exec(gl&&gl.keys&&gl.keys.IE_PROTO||"");return u?"Symbol(src)_1."+u:""})(),vl=Ls.toString,wN=ml.call(qt),TN=Dr._,SN=_h("^"+ml.call(Mt).replace(U,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),yl=w_?Y.Buffer:r,Qi=Y.Symbol,bl=Y.Uint8Array,U_=yl?yl.allocUnsafe:r,_l=k_(qt.getPrototypeOf,qt),q_=qt.create,H_=Ls.propertyIsEnumerable,xl=pl.splice,W_=Qi?Qi.isConcatSpreadable:r,Lo=Qi?Qi.iterator:r,La=Qi?Qi.toStringTag:r,wl=(function(){try{var u=$a(qt,"defineProperty");return u({},"",{}),u}catch{}})(),CN=Y.clearTimeout!==Dr.clearTimeout&&Y.clearTimeout,EN=pe&&pe.now!==Dr.Date.now&&pe.now,ON=Y.setTimeout!==Dr.setTimeout&&Y.setTimeout,Tl=_r.ceil,Sl=_r.floor,xh=qt.getOwnPropertySymbols,AN=yl?yl.isBuffer:r,B_=Y.isFinite,IN=pl.join,RN=k_(qt.keys,qt),xr=_r.max,Nr=_r.min,DN=pe.now,MN=Y.parseInt,z_=_r.random,PN=pl.reverse,wh=$a(Y,"DataView"),No=$a(Y,"Map"),Th=$a(Y,"Promise"),Ns=$a(Y,"Set"),Fo=$a(Y,"WeakMap"),ko=$a(qt,"create"),Cl=Fo&&new Fo,Fs={},LN=Ua(wh),NN=Ua(No),FN=Ua(Th),kN=Ua(Ns),jN=Ua(Fo),El=Qi?Qi.prototype:r,jo=El?El.valueOf:r,V_=El?El.toString:r;function R(u){if(sr(u)&&!Be(u)&&!(u instanceof pt)){if(u instanceof Mn)return u;if(Mt.call(u,"__wrapped__"))return Gx(u)}return new Mn(u)}var ks=(function(){function u(){}return function(f){if(!tr(f))return{};if(q_)return q_(f);u.prototype=f;var p=new u;return u.prototype=r,p}})();function Ol(){}function Mn(u,f){this.__wrapped__=u,this.__actions__=[],this.__chain__=!!f,this.__index__=0,this.__values__=r}R.templateSettings={escape:Vi,evaluate:hn,interpolate:br,variable:"",imports:{_:R}},R.prototype=Ol.prototype,R.prototype.constructor=R,Mn.prototype=ks(Ol.prototype),Mn.prototype.constructor=Mn;function pt(u){this.__wrapped__=u,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=ve,this.__views__=[]}function $N(){var u=new pt(this.__wrapped__);return u.__actions__=Qr(this.__actions__),u.__dir__=this.__dir__,u.__filtered__=this.__filtered__,u.__iteratees__=Qr(this.__iteratees__),u.__takeCount__=this.__takeCount__,u.__views__=Qr(this.__views__),u}function UN(){if(this.__filtered__){var u=new pt(this);u.__dir__=-1,u.__filtered__=!0}else u=this.clone(),u.__dir__*=-1;return u}function qN(){var u=this.__wrapped__.value(),f=this.__dir__,p=Be(u),_=f<0,O=p?u.length:0,M=QF(0,O,this.__views__),N=M.start,j=M.end,q=j-N,Z=_?j:N-1,Q=this.__iteratees__,ne=Q.length,le=0,Te=Nr(q,this.__takeCount__);if(!p||!_&&O==q&&Te==q)return mx(u,this.__actions__);var Pe=[];e:for(;q--&&le<Te;){Z+=f;for(var Ke=-1,Ie=u[Z];++Ke<ne;){var dt=Q[Ke],vt=dt.iteratee,bn=dt.type,Br=vt(Ie);if(bn==te)Ie=Br;else if(!Br){if(bn==J)continue e;break e}}Pe[le++]=Ie}return Pe}pt.prototype=ks(Ol.prototype),pt.prototype.constructor=pt;function Na(u){var f=-1,p=u==null?0:u.length;for(this.clear();++f<p;){var _=u[f];this.set(_[0],_[1])}}function HN(){this.__data__=ko?ko(null):{},this.size=0}function WN(u){var f=this.has(u)&&delete this.__data__[u];return this.size-=f?1:0,f}function BN(u){var f=this.__data__;if(ko){var p=f[u];return p===c?r:p}return Mt.call(f,u)?f[u]:r}function zN(u){var f=this.__data__;return ko?f[u]!==r:Mt.call(f,u)}function VN(u,f){var p=this.__data__;return this.size+=this.has(u)?0:1,p[u]=ko&&f===r?c:f,this}Na.prototype.clear=HN,Na.prototype.delete=WN,Na.prototype.get=BN,Na.prototype.has=zN,Na.prototype.set=VN;function wi(u){var f=-1,p=u==null?0:u.length;for(this.clear();++f<p;){var _=u[f];this.set(_[0],_[1])}}function GN(){this.__data__=[],this.size=0}function KN(u){var f=this.__data__,p=Al(f,u);if(p<0)return!1;var _=f.length-1;return p==_?f.pop():xl.call(f,p,1),--this.size,!0}function XN(u){var f=this.__data__,p=Al(f,u);return p<0?r:f[p][1]}function YN(u){return Al(this.__data__,u)>-1}function ZN(u,f){var p=this.__data__,_=Al(p,u);return _<0?(++this.size,p.push([u,f])):p[_][1]=f,this}wi.prototype.clear=GN,wi.prototype.delete=KN,wi.prototype.get=XN,wi.prototype.has=YN,wi.prototype.set=ZN;function Ti(u){var f=-1,p=u==null?0:u.length;for(this.clear();++f<p;){var _=u[f];this.set(_[0],_[1])}}function JN(){this.size=0,this.__data__={hash:new Na,map:new(No||wi),string:new Na}}function QN(u){var f=Ul(this,u).delete(u);return this.size-=f?1:0,f}function eF(u){return Ul(this,u).get(u)}function tF(u){return Ul(this,u).has(u)}function rF(u,f){var p=Ul(this,u),_=p.size;return p.set(u,f),this.size+=p.size==_?0:1,this}Ti.prototype.clear=JN,Ti.prototype.delete=QN,Ti.prototype.get=eF,Ti.prototype.has=tF,Ti.prototype.set=rF;function Fa(u){var f=-1,p=u==null?0:u.length;for(this.__data__=new Ti;++f<p;)this.add(u[f])}function nF(u){return this.__data__.set(u,c),this}function iF(u){return this.__data__.has(u)}Fa.prototype.add=Fa.prototype.push=nF,Fa.prototype.has=iF;function Kn(u){var f=this.__data__=new wi(u);this.size=f.size}function aF(){this.__data__=new wi,this.size=0}function sF(u){var f=this.__data__,p=f.delete(u);return this.size=f.size,p}function oF(u){return this.__data__.get(u)}function uF(u){return this.__data__.has(u)}function lF(u,f){var p=this.__data__;if(p instanceof wi){var _=p.__data__;if(!No||_.length<i-1)return _.push([u,f]),this.size=++p.size,this;p=this.__data__=new Ti(_)}return p.set(u,f),this.size=p.size,this}Kn.prototype.clear=aF,Kn.prototype.delete=sF,Kn.prototype.get=oF,Kn.prototype.has=uF,Kn.prototype.set=lF;function G_(u,f){var p=Be(u),_=!p&&qa(u),O=!p&&!_&&ia(u),M=!p&&!_&&!O&&qs(u),N=p||_||O||M,j=N?vh(u.length,bN):[],q=j.length;for(var Z in u)(f||Mt.call(u,Z))&&!(N&&(Z=="length"||O&&(Z=="offset"||Z=="parent")||M&&(Z=="buffer"||Z=="byteLength"||Z=="byteOffset")||Ei(Z,q)))&&j.push(Z);return j}function K_(u){var f=u.length;return f?u[Lh(0,f-1)]:r}function cF(u,f){return ql(Qr(u),ka(f,0,u.length))}function fF(u){return ql(Qr(u))}function Sh(u,f,p){(p!==r&&!Yn(u[f],p)||p===r&&!(f in u))&&ii(u,f,p)}function $o(u,f,p){var _=u[f];(!(Mt.call(u,f)&&Yn(_,p))||p===r&&!(f in u))&&ii(u,f,p)}function Al(u,f){for(var p=u.length;p--;)if(Yn(u[p][0],f))return p;return-1}function dF(u,f,p,_){return ea(u,function(O,M,N){f(_,O,p(O),N)}),_}function X_(u,f){return u&&si(f,Sr(f),u)}function hF(u,f){return u&&si(f,tn(f),u)}function ii(u,f,p){f=="__proto__"&&wl?wl(u,f,{configurable:!0,enumerable:!0,value:p,writable:!0}):u[f]=p}function Ch(u,f){for(var p=-1,_=f.length,O=K(_),M=u==null;++p<_;)O[p]=M?r:sp(u,f[p]);return O}function ka(u,f,p){return u===u&&(p!==r&&(u=u<=p?u:p),f!==r&&(u=u>=f?u:f)),u}function Pn(u,f,p,_,O,M){var N,j=f&g,q=f&m,Z=f&v;if(p&&(N=O?p(u,_,O,M):p(u)),N!==r)return N;if(!tr(u))return u;var Q=Be(u);if(Q){if(N=t2(u),!j)return Qr(u,N)}else{var ne=Fr(u),le=ne==Je||ne==Rt;if(ia(u))return bx(u,j);if(ne==Ot||ne==Ue||le&&!O){if(N=q||le?{}:jx(u),!j)return q?BF(u,hF(N,u)):WF(u,X_(N,u))}else{if(!Bt[ne])return O?u:{};N=r2(u,ne,j)}}M||(M=new Kn);var Te=M.get(u);if(Te)return Te;M.set(u,N),hw(u)?u.forEach(function(Ie){N.add(Pn(Ie,f,p,Ie,u,M))}):fw(u)&&u.forEach(function(Ie,dt){N.set(dt,Pn(Ie,f,p,dt,u,M))});var Pe=Z?q?zh:Bh:q?tn:Sr,Ke=Q?r:Pe(u);return gn(Ke||u,function(Ie,dt){Ke&&(dt=Ie,Ie=u[dt]),$o(N,dt,Pn(Ie,f,p,dt,u,M))}),N}function pF(u){var f=Sr(u);return function(p){return Y_(p,u,f)}}function Y_(u,f,p){var _=p.length;if(u==null)return!_;for(u=qt(u);_--;){var O=p[_],M=f[O],N=u[O];if(N===r&&!(O in u)||!M(N))return!1}return!0}function Z_(u,f,p){if(typeof u!="function")throw new Dn(s);return Vo(function(){u.apply(r,p)},f)}function Uo(u,f,p,_){var O=-1,M=fl,N=!0,j=u.length,q=[],Z=f.length;if(!j)return q;p&&(f=Yt(f,mn(p))),_?(M=fh,N=!1):f.length>=i&&(M=Po,N=!1,f=new Fa(f));e:for(;++O<j;){var Q=u[O],ne=p==null?Q:p(Q);if(Q=_||Q!==0?Q:0,N&&ne===ne){for(var le=Z;le--;)if(f[le]===ne)continue e;q.push(Q)}else M(f,ne,_)||q.push(Q)}return q}var ea=Sx(ai),J_=Sx(Oh,!0);function gF(u,f){var p=!0;return ea(u,function(_,O,M){return p=!!f(_,O,M),p}),p}function Il(u,f,p){for(var _=-1,O=u.length;++_<O;){var M=u[_],N=f(M);if(N!=null&&(j===r?N===N&&!yn(N):p(N,j)))var j=N,q=M}return q}function mF(u,f,p,_){var O=u.length;for(p=ze(p),p<0&&(p=-p>O?0:O+p),_=_===r||_>O?O:ze(_),_<0&&(_+=O),_=p>_?0:gw(_);p<_;)u[p++]=f;return u}function Q_(u,f){var p=[];return ea(u,function(_,O,M){f(_,O,M)&&p.push(_)}),p}function Mr(u,f,p,_,O){var M=-1,N=u.length;for(p||(p=i2),O||(O=[]);++M<N;){var j=u[M];f>0&&p(j)?f>1?Mr(j,f-1,p,_,O):Zi(O,j):_||(O[O.length]=j)}return O}var Eh=Cx(),ex=Cx(!0);function ai(u,f){return u&&Eh(u,f,Sr)}function Oh(u,f){return u&&ex(u,f,Sr)}function Rl(u,f){return Yi(f,function(p){return Oi(u[p])})}function ja(u,f){f=ra(f,u);for(var p=0,_=f.length;u!=null&&p<_;)u=u[Xn(f[p++])];return p&&p==_?u:r}function tx(u,f,p){var _=f(u);return Be(u)?_:Zi(_,p(u))}function Hr(u){return u==null?u===r?_e:Nt:La&&La in qt(u)?JF(u):f2(u)}function Ah(u,f){return u>f}function vF(u,f){return u!=null&&Mt.call(u,f)}function yF(u,f){return u!=null&&f in qt(u)}function bF(u,f,p){return u>=Nr(f,p)&&u<xr(f,p)}function Ih(u,f,p){for(var _=p?fh:fl,O=u[0].length,M=u.length,N=M,j=K(M),q=1/0,Z=[];N--;){var Q=u[N];N&&f&&(Q=Yt(Q,mn(f))),q=Nr(Q.length,q),j[N]=!p&&(f||O>=120&&Q.length>=120)?new Fa(N&&Q):r}Q=u[0];var ne=-1,le=j[0];e:for(;++ne<O&&Z.length<q;){var Te=Q[ne],Pe=f?f(Te):Te;if(Te=p||Te!==0?Te:0,!(le?Po(le,Pe):_(Z,Pe,p))){for(N=M;--N;){var Ke=j[N];if(!(Ke?Po(Ke,Pe):_(u[N],Pe,p)))continue e}le&&le.push(Pe),Z.push(Te)}}return Z}function _F(u,f,p,_){return ai(u,function(O,M,N){f(_,p(O),M,N)}),_}function qo(u,f,p){f=ra(f,u),u=Hx(u,f);var _=u==null?u:u[Xn(Nn(f))];return _==null?r:pn(_,u,p)}function rx(u){return sr(u)&&Hr(u)==Ue}function xF(u){return sr(u)&&Hr(u)==St}function wF(u){return sr(u)&&Hr(u)==xe}function Ho(u,f,p,_,O){return u===f?!0:u==null||f==null||!sr(u)&&!sr(f)?u!==u&&f!==f:TF(u,f,p,_,Ho,O)}function TF(u,f,p,_,O,M){var N=Be(u),j=Be(f),q=N?ht:Fr(u),Z=j?ht:Fr(f);q=q==Ue?Ot:q,Z=Z==Ue?Ot:Z;var Q=q==Ot,ne=Z==Ot,le=q==Z;if(le&&ia(u)){if(!ia(f))return!1;N=!0,Q=!1}if(le&&!Q)return M||(M=new Kn),N||qs(u)?Nx(u,f,p,_,O,M):YF(u,f,q,p,_,O,M);if(!(p&b)){var Te=Q&&Mt.call(u,"__wrapped__"),Pe=ne&&Mt.call(f,"__wrapped__");if(Te||Pe){var Ke=Te?u.value():u,Ie=Pe?f.value():f;return M||(M=new Kn),O(Ke,Ie,p,_,M)}}return le?(M||(M=new Kn),ZF(u,f,p,_,O,M)):!1}function SF(u){return sr(u)&&Fr(u)==ft}function Rh(u,f,p,_){var O=p.length,M=O,N=!_;if(u==null)return!M;for(u=qt(u);O--;){var j=p[O];if(N&&j[2]?j[1]!==u[j[0]]:!(j[0]in u))return!1}for(;++O<M;){j=p[O];var q=j[0],Z=u[q],Q=j[1];if(N&&j[2]){if(Z===r&&!(q in u))return!1}else{var ne=new Kn;if(_)var le=_(Z,Q,q,u,f,ne);if(!(le===r?Ho(Q,Z,b|y,_,ne):le))return!1}}return!0}function nx(u){if(!tr(u)||s2(u))return!1;var f=Oi(u)?SN:st;return f.test(Ua(u))}function CF(u){return sr(u)&&Hr(u)==fr}function EF(u){return sr(u)&&Fr(u)==W}function OF(u){return sr(u)&&Gl(u.length)&&!!Gt[Hr(u)]}function ix(u){return typeof u=="function"?u:u==null?rn:typeof u=="object"?Be(u)?ox(u[0],u[1]):sx(u):Ow(u)}function Dh(u){if(!zo(u))return RN(u);var f=[];for(var p in qt(u))Mt.call(u,p)&&p!="constructor"&&f.push(p);return f}function AF(u){if(!tr(u))return c2(u);var f=zo(u),p=[];for(var _ in u)_=="constructor"&&(f||!Mt.call(u,_))||p.push(_);return p}function Mh(u,f){return u<f}function ax(u,f){var p=-1,_=en(u)?K(u.length):[];return ea(u,function(O,M,N){_[++p]=f(O,M,N)}),_}function sx(u){var f=Gh(u);return f.length==1&&f[0][2]?Ux(f[0][0],f[0][1]):function(p){return p===u||Rh(p,u,f)}}function ox(u,f){return Xh(u)&&$x(f)?Ux(Xn(u),f):function(p){var _=sp(p,u);return _===r&&_===f?op(p,u):Ho(f,_,b|y)}}function Dl(u,f,p,_,O){u!==f&&Eh(f,function(M,N){if(O||(O=new Kn),tr(M))IF(u,f,N,p,Dl,_,O);else{var j=_?_(Zh(u,N),M,N+"",u,f,O):r;j===r&&(j=M),Sh(u,N,j)}},tn)}function IF(u,f,p,_,O,M,N){var j=Zh(u,p),q=Zh(f,p),Z=N.get(q);if(Z){Sh(u,p,Z);return}var Q=M?M(j,q,p+"",u,f,N):r,ne=Q===r;if(ne){var le=Be(q),Te=!le&&ia(q),Pe=!le&&!Te&&qs(q);Q=q,le||Te||Pe?Be(j)?Q=j:dr(j)?Q=Qr(j):Te?(ne=!1,Q=bx(q,!0)):Pe?(ne=!1,Q=_x(q,!0)):Q=[]:Go(q)||qa(q)?(Q=j,qa(j)?Q=mw(j):(!tr(j)||Oi(j))&&(Q=jx(q))):ne=!1}ne&&(N.set(q,Q),O(Q,q,_,M,N),N.delete(q)),Sh(u,p,Q)}function ux(u,f){var p=u.length;if(p)return f+=f<0?p:0,Ei(f,p)?u[f]:r}function lx(u,f,p){f.length?f=Yt(f,function(M){return Be(M)?function(N){return ja(N,M.length===1?M[0]:M)}:M}):f=[rn];var _=-1;f=Yt(f,mn(Me()));var O=ax(u,function(M,N,j){var q=Yt(f,function(Z){return Z(M)});return{criteria:q,index:++_,value:M}});return rN(O,function(M,N){return HF(M,N,p)})}function RF(u,f){return cx(u,f,function(p,_){return op(u,_)})}function cx(u,f,p){for(var _=-1,O=f.length,M={};++_<O;){var N=f[_],j=ja(u,N);p(j,N)&&Wo(M,ra(N,u),j)}return M}function DF(u){return function(f){return ja(f,u)}}function Ph(u,f,p,_){var O=_?tN:Rs,M=-1,N=f.length,j=u;for(u===f&&(f=Qr(f)),p&&(j=Yt(u,mn(p)));++M<N;)for(var q=0,Z=f[M],Q=p?p(Z):Z;(q=O(j,Q,q,_))>-1;)j!==u&&xl.call(j,q,1),xl.call(u,q,1);return u}function fx(u,f){for(var p=u?f.length:0,_=p-1;p--;){var O=f[p];if(p==_||O!==M){var M=O;Ei(O)?xl.call(u,O,1):kh(u,O)}}return u}function Lh(u,f){return u+Sl(z_()*(f-u+1))}function MF(u,f,p,_){for(var O=-1,M=xr(Tl((f-u)/(p||1)),0),N=K(M);M--;)N[_?M:++O]=u,u+=p;return N}function Nh(u,f){var p="";if(!u||f<1||f>ae)return p;do f%2&&(p+=u),f=Sl(f/2),f&&(u+=u);while(f);return p}function tt(u,f){return Jh(qx(u,f,rn),u+"")}function PF(u){return K_(Hs(u))}function LF(u,f){var p=Hs(u);return ql(p,ka(f,0,p.length))}function Wo(u,f,p,_){if(!tr(u))return u;f=ra(f,u);for(var O=-1,M=f.length,N=M-1,j=u;j!=null&&++O<M;){var q=Xn(f[O]),Z=p;if(q==="__proto__"||q==="constructor"||q==="prototype")return u;if(O!=N){var Q=j[q];Z=_?_(Q,q,j):r,Z===r&&(Z=tr(Q)?Q:Ei(f[O+1])?[]:{})}$o(j,q,Z),j=j[q]}return u}var dx=Cl?function(u,f){return Cl.set(u,f),u}:rn,NF=wl?function(u,f){return wl(u,"toString",{configurable:!0,enumerable:!1,value:lp(f),writable:!0})}:rn;function FF(u){return ql(Hs(u))}function Ln(u,f,p){var _=-1,O=u.length;f<0&&(f=-f>O?0:O+f),p=p>O?O:p,p<0&&(p+=O),O=f>p?0:p-f>>>0,f>>>=0;for(var M=K(O);++_<O;)M[_]=u[_+f];return M}function kF(u,f){var p;return ea(u,function(_,O,M){return p=f(_,O,M),!p}),!!p}function Ml(u,f,p){var _=0,O=u==null?_:u.length;if(typeof f=="number"&&f===f&&O<=Ge){for(;_<O;){var M=_+O>>>1,N=u[M];N!==null&&!yn(N)&&(p?N<=f:N<f)?_=M+1:O=M}return O}return Fh(u,f,rn,p)}function Fh(u,f,p,_){var O=0,M=u==null?0:u.length;if(M===0)return 0;f=p(f);for(var N=f!==f,j=f===null,q=yn(f),Z=f===r;O<M;){var Q=Sl((O+M)/2),ne=p(u[Q]),le=ne!==r,Te=ne===null,Pe=ne===ne,Ke=yn(ne);if(N)var Ie=_||Pe;else Z?Ie=Pe&&(_||le):j?Ie=Pe&&le&&(_||!Te):q?Ie=Pe&&le&&!Te&&(_||!Ke):Te||Ke?Ie=!1:Ie=_?ne<=f:ne<f;Ie?O=Q+1:M=Q}return Nr(M,ct)}function hx(u,f){for(var p=-1,_=u.length,O=0,M=[];++p<_;){var N=u[p],j=f?f(N):N;if(!p||!Yn(j,q)){var q=j;M[O++]=N===0?0:N}}return M}function px(u){return typeof u=="number"?u:yn(u)?Ae:+u}function vn(u){if(typeof u=="string")return u;if(Be(u))return Yt(u,vn)+"";if(yn(u))return V_?V_.call(u):"";var f=u+"";return f=="0"&&1/u==-B?"-0":f}function ta(u,f,p){var _=-1,O=fl,M=u.length,N=!0,j=[],q=j;if(p)N=!1,O=fh;else if(M>=i){var Z=f?null:KF(u);if(Z)return hl(Z);N=!1,O=Po,q=new Fa}else q=f?[]:j;e:for(;++_<M;){var Q=u[_],ne=f?f(Q):Q;if(Q=p||Q!==0?Q:0,N&&ne===ne){for(var le=q.length;le--;)if(q[le]===ne)continue e;f&&q.push(ne),j.push(Q)}else O(q,ne,p)||(q!==j&&q.push(ne),j.push(Q))}return j}function kh(u,f){f=ra(f,u);var p=-1,_=f.length;if(!_)return!0;for(;++p<_;){var O=Xn(f[p]);if(O==="__proto__"&&!Mt.call(u,"__proto__")||(O==="constructor"||O==="prototype")&&p<_-1)return!1}var M=Hx(u,f);return M==null||delete M[Xn(Nn(f))]}function gx(u,f,p,_){return Wo(u,f,p(ja(u,f)),_)}function Pl(u,f,p,_){for(var O=u.length,M=_?O:-1;(_?M--:++M<O)&&f(u[M],M,u););return p?Ln(u,_?0:M,_?M+1:O):Ln(u,_?M+1:0,_?O:M)}function mx(u,f){var p=u;return p instanceof pt&&(p=p.value()),dh(f,function(_,O){return O.func.apply(O.thisArg,Zi([_],O.args))},p)}function jh(u,f,p){var _=u.length;if(_<2)return _?ta(u[0]):[];for(var O=-1,M=K(_);++O<_;)for(var N=u[O],j=-1;++j<_;)j!=O&&(M[O]=Uo(M[O]||N,u[j],f,p));return ta(Mr(M,1),f,p)}function vx(u,f,p){for(var _=-1,O=u.length,M=f.length,N={};++_<O;){var j=_<M?f[_]:r;p(N,u[_],j)}return N}function $h(u){return dr(u)?u:[]}function Uh(u){return typeof u=="function"?u:rn}function ra(u,f){return Be(u)?u:Xh(u,f)?[u]:Vx(Pt(u))}var jF=tt;function na(u,f,p){var _=u.length;return p=p===r?_:p,!f&&p>=_?u:Ln(u,f,p)}var yx=CN||function(u){return Dr.clearTimeout(u)};function bx(u,f){if(f)return u.slice();var p=u.length,_=U_?U_(p):new u.constructor(p);return u.copy(_),_}function qh(u){var f=new u.constructor(u.byteLength);return new bl(f).set(new bl(u)),f}function $F(u,f){var p=f?qh(u.buffer):u.buffer;return new u.constructor(p,u.byteOffset,u.byteLength)}function UF(u){var f=new u.constructor(u.source,et.exec(u));return f.lastIndex=u.lastIndex,f}function qF(u){return jo?qt(jo.call(u)):{}}function _x(u,f){var p=f?qh(u.buffer):u.buffer;return new u.constructor(p,u.byteOffset,u.length)}function xx(u,f){if(u!==f){var p=u!==r,_=u===null,O=u===u,M=yn(u),N=f!==r,j=f===null,q=f===f,Z=yn(f);if(!j&&!Z&&!M&&u>f||M&&N&&q&&!j&&!Z||_&&N&&q||!p&&q||!O)return 1;if(!_&&!M&&!Z&&u<f||Z&&p&&O&&!_&&!M||j&&p&&O||!N&&O||!q)return-1}return 0}function HF(u,f,p){for(var _=-1,O=u.criteria,M=f.criteria,N=O.length,j=p.length;++_<N;){var q=xx(O[_],M[_]);if(q){if(_>=j)return q;var Z=p[_];return q*(Z=="desc"?-1:1)}}return u.index-f.index}function wx(u,f,p,_){for(var O=-1,M=u.length,N=p.length,j=-1,q=f.length,Z=xr(M-N,0),Q=K(q+Z),ne=!_;++j<q;)Q[j]=f[j];for(;++O<N;)(ne||O<M)&&(Q[p[O]]=u[O]);for(;Z--;)Q[j++]=u[O++];return Q}function Tx(u,f,p,_){for(var O=-1,M=u.length,N=-1,j=p.length,q=-1,Z=f.length,Q=xr(M-j,0),ne=K(Q+Z),le=!_;++O<Q;)ne[O]=u[O];for(var Te=O;++q<Z;)ne[Te+q]=f[q];for(;++N<j;)(le||O<M)&&(ne[Te+p[N]]=u[O++]);return ne}function Qr(u,f){var p=-1,_=u.length;for(f||(f=K(_));++p<_;)f[p]=u[p];return f}function si(u,f,p,_){var O=!p;p||(p={});for(var M=-1,N=f.length;++M<N;){var j=f[M],q=_?_(p[j],u[j],j,p,u):r;q===r&&(q=u[j]),O?ii(p,j,q):$o(p,j,q)}return p}function WF(u,f){return si(u,Kh(u),f)}function BF(u,f){return si(u,Fx(u),f)}function Ll(u,f){return function(p,_){var O=Be(p)?XL:dF,M=f?f():{};return O(p,u,Me(_,2),M)}}function js(u){return tt(function(f,p){var _=-1,O=p.length,M=O>1?p[O-1]:r,N=O>2?p[2]:r;for(M=u.length>3&&typeof M=="function"?(O--,M):r,N&&Wr(p[0],p[1],N)&&(M=O<3?r:M,O=1),f=qt(f);++_<O;){var j=p[_];j&&u(f,j,_,M)}return f})}function Sx(u,f){return function(p,_){if(p==null)return p;if(!en(p))return u(p,_);for(var O=p.length,M=f?O:-1,N=qt(p);(f?M--:++M<O)&&_(N[M],M,N)!==!1;);return p}}function Cx(u){return function(f,p,_){for(var O=-1,M=qt(f),N=_(f),j=N.length;j--;){var q=N[u?j:++O];if(p(M[q],q,M)===!1)break}return f}}function zF(u,f,p){var _=f&x,O=Bo(u);function M(){var N=this&&this!==Dr&&this instanceof M?O:u;return N.apply(_?p:this,arguments)}return M}function Ex(u){return function(f){f=Pt(f);var p=Ds(f)?Gn(f):r,_=p?p[0]:f.charAt(0),O=p?na(p,1).join(""):f.slice(1);return _[u]()+O}}function $s(u){return function(f){return dh(Cw(Sw(f).replace(NL,"")),u,"")}}function Bo(u){return function(){var f=arguments;switch(f.length){case 0:return new u;case 1:return new u(f[0]);case 2:return new u(f[0],f[1]);case 3:return new u(f[0],f[1],f[2]);case 4:return new u(f[0],f[1],f[2],f[3]);case 5:return new u(f[0],f[1],f[2],f[3],f[4]);case 6:return new u(f[0],f[1],f[2],f[3],f[4],f[5]);case 7:return new u(f[0],f[1],f[2],f[3],f[4],f[5],f[6])}var p=ks(u.prototype),_=u.apply(p,f);return tr(_)?_:p}}function VF(u,f,p){var _=Bo(u);function O(){for(var M=arguments.length,N=K(M),j=M,q=Us(O);j--;)N[j]=arguments[j];var Z=M<3&&N[0]!==q&&N[M-1]!==q?[]:Ji(N,q);if(M-=Z.length,M<p)return Dx(u,f,Nl,O.placeholder,r,N,Z,r,r,p-M);var Q=this&&this!==Dr&&this instanceof O?_:u;return pn(Q,this,N)}return O}function Ox(u){return function(f,p,_){var O=qt(f);if(!en(f)){var M=Me(p,3);f=Sr(f),p=function(j){return M(O[j],j,O)}}var N=u(f,p,_);return N>-1?O[M?f[N]:N]:r}}function Ax(u){return Ci(function(f){var p=f.length,_=p,O=Mn.prototype.thru;for(u&&f.reverse();_--;){var M=f[_];if(typeof M!="function")throw new Dn(s);if(O&&!N&&$l(M)=="wrapper")var N=new Mn([],!0)}for(_=N?_:p;++_<p;){M=f[_];var j=$l(M),q=j=="wrapper"?Vh(M):r;q&&Yh(q[0])&&q[1]==(D|E|I|P)&&!q[4].length&&q[9]==1?N=N[$l(q[0])].apply(N,q[3]):N=M.length==1&&Yh(M)?N[j]():N.thru(M)}return function(){var Z=arguments,Q=Z[0];if(N&&Z.length==1&&Be(Q))return N.plant(Q).value();for(var ne=0,le=p?f[ne].apply(this,Z):Q;++ne<p;)le=f[ne].call(this,le);return le}})}function Nl(u,f,p,_,O,M,N,j,q,Z){var Q=f&D,ne=f&x,le=f&w,Te=f&(E|C),Pe=f&L,Ke=le?r:Bo(u);function Ie(){for(var dt=arguments.length,vt=K(dt),bn=dt;bn--;)vt[bn]=arguments[bn];if(Te)var Br=Us(Ie),_n=iN(vt,Br);if(_&&(vt=wx(vt,_,O,Te)),M&&(vt=Tx(vt,M,N,Te)),dt-=_n,Te&&dt<Z){var hr=Ji(vt,Br);return Dx(u,f,Nl,Ie.placeholder,p,vt,hr,j,q,Z-dt)}var Zn=ne?p:this,Ii=le?Zn[u]:u;return dt=vt.length,j?vt=d2(vt,j):Pe&&dt>1&&vt.reverse(),Q&&q<dt&&(vt.length=q),this&&this!==Dr&&this instanceof Ie&&(Ii=Ke||Bo(Ii)),Ii.apply(Zn,vt)}return Ie}function Ix(u,f){return function(p,_){return _F(p,u,f(_),{})}}function Fl(u,f){return function(p,_){var O;if(p===r&&_===r)return f;if(p!==r&&(O=p),_!==r){if(O===r)return _;typeof p=="string"||typeof _=="string"?(p=vn(p),_=vn(_)):(p=px(p),_=px(_)),O=u(p,_)}return O}}function Hh(u){return Ci(function(f){return f=Yt(f,mn(Me())),tt(function(p){var _=this;return u(f,function(O){return pn(O,_,p)})})})}function kl(u,f){f=f===r?" ":vn(f);var p=f.length;if(p<2)return p?Nh(f,u):f;var _=Nh(f,Tl(u/Ms(f)));return Ds(f)?na(Gn(_),0,u).join(""):_.slice(0,u)}function GF(u,f,p,_){var O=f&x,M=Bo(u);function N(){for(var j=-1,q=arguments.length,Z=-1,Q=_.length,ne=K(Q+q),le=this&&this!==Dr&&this instanceof N?M:u;++Z<Q;)ne[Z]=_[Z];for(;q--;)ne[Z++]=arguments[++j];return pn(le,O?p:this,ne)}return N}function Rx(u){return function(f,p,_){return _&&typeof _!="number"&&Wr(f,p,_)&&(p=_=r),f=Ai(f),p===r?(p=f,f=0):p=Ai(p),_=_===r?f<p?1:-1:Ai(_),MF(f,p,_,u)}}function jl(u){return function(f,p){return typeof f=="string"&&typeof p=="string"||(f=Fn(f),p=Fn(p)),u(f,p)}}function Dx(u,f,p,_,O,M,N,j,q,Z){var Q=f&E,ne=Q?N:r,le=Q?r:N,Te=Q?M:r,Pe=Q?r:M;f|=Q?I:T,f&=~(Q?T:I),f&S||(f&=-4);var Ke=[u,f,O,Te,ne,Pe,le,j,q,Z],Ie=p.apply(r,Ke);return Yh(u)&&Wx(Ie,Ke),Ie.placeholder=_,Bx(Ie,u,f)}function Wh(u){var f=_r[u];return function(p,_){if(p=Fn(p),_=_==null?0:Nr(ze(_),292),_&&B_(p)){var O=(Pt(p)+"e").split("e"),M=f(O[0]+"e"+(+O[1]+_));return O=(Pt(M)+"e").split("e"),+(O[0]+"e"+(+O[1]-_))}return f(p)}}var KF=Ns&&1/hl(new Ns([,-0]))[1]==B?function(u){return new Ns(u)}:dp;function Mx(u){return function(f){var p=Fr(f);return p==ft?bh(f):p==W?fN(f):nN(f,u(f))}}function Si(u,f,p,_,O,M,N,j){var q=f&w;if(!q&&typeof u!="function")throw new Dn(s);var Z=_?_.length:0;if(Z||(f&=-97,_=O=r),N=N===r?N:xr(ze(N),0),j=j===r?j:ze(j),Z-=O?O.length:0,f&T){var Q=_,ne=O;_=O=r}var le=q?r:Vh(u),Te=[u,f,p,_,O,Q,ne,M,N,j];if(le&&l2(Te,le),u=Te[0],f=Te[1],p=Te[2],_=Te[3],O=Te[4],j=Te[9]=Te[9]===r?q?0:u.length:xr(Te[9]-Z,0),!j&&f&(E|C)&&(f&=-25),!f||f==x)var Pe=zF(u,f,p);else f==E||f==C?Pe=VF(u,f,j):(f==I||f==(x|I))&&!O.length?Pe=GF(u,f,p,_):Pe=Nl.apply(r,Te);var Ke=le?dx:Wx;return Bx(Ke(Pe,Te),u,f)}function Px(u,f,p,_){return u===r||Yn(u,Ls[p])&&!Mt.call(_,p)?f:u}function Lx(u,f,p,_,O,M){return tr(u)&&tr(f)&&(M.set(f,u),Dl(u,f,r,Lx,M),M.delete(f)),u}function XF(u){return Go(u)?r:u}function Nx(u,f,p,_,O,M){var N=p&b,j=u.length,q=f.length;if(j!=q&&!(N&&q>j))return!1;var Z=M.get(u),Q=M.get(f);if(Z&&Q)return Z==f&&Q==u;var ne=-1,le=!0,Te=p&y?new Fa:r;for(M.set(u,f),M.set(f,u);++ne<j;){var Pe=u[ne],Ke=f[ne];if(_)var Ie=N?_(Ke,Pe,ne,f,u,M):_(Pe,Ke,ne,u,f,M);if(Ie!==r){if(Ie)continue;le=!1;break}if(Te){if(!hh(f,function(dt,vt){if(!Po(Te,vt)&&(Pe===dt||O(Pe,dt,p,_,M)))return Te.push(vt)})){le=!1;break}}else if(!(Pe===Ke||O(Pe,Ke,p,_,M))){le=!1;break}}return M.delete(u),M.delete(f),le}function YF(u,f,p,_,O,M,N){switch(p){case Ct:if(u.byteLength!=f.byteLength||u.byteOffset!=f.byteOffset)return!1;u=u.buffer,f=f.buffer;case St:return!(u.byteLength!=f.byteLength||!M(new bl(u),new bl(f)));case Se:case xe:case Ne:return Yn(+u,+f);case Oe:return u.name==f.name&&u.message==f.message;case fr:case se:return u==f+"";case ft:var j=bh;case W:var q=_&b;if(j||(j=hl),u.size!=f.size&&!q)return!1;var Z=N.get(u);if(Z)return Z==f;_|=y,N.set(u,f);var Q=Nx(j(u),j(f),_,O,M,N);return N.delete(u),Q;case ue:if(jo)return jo.call(u)==jo.call(f)}return!1}function ZF(u,f,p,_,O,M){var N=p&b,j=Bh(u),q=j.length,Z=Bh(f),Q=Z.length;if(q!=Q&&!N)return!1;for(var ne=q;ne--;){var le=j[ne];if(!(N?le in f:Mt.call(f,le)))return!1}var Te=M.get(u),Pe=M.get(f);if(Te&&Pe)return Te==f&&Pe==u;var Ke=!0;M.set(u,f),M.set(f,u);for(var Ie=N;++ne<q;){le=j[ne];var dt=u[le],vt=f[le];if(_)var bn=N?_(vt,dt,le,f,u,M):_(dt,vt,le,u,f,M);if(!(bn===r?dt===vt||O(dt,vt,p,_,M):bn)){Ke=!1;break}Ie||(Ie=le=="constructor")}if(Ke&&!Ie){var Br=u.constructor,_n=f.constructor;Br!=_n&&"constructor"in u&&"constructor"in f&&!(typeof Br=="function"&&Br instanceof Br&&typeof _n=="function"&&_n instanceof _n)&&(Ke=!1)}return M.delete(u),M.delete(f),Ke}function Ci(u){return Jh(qx(u,r,Yx),u+"")}function Bh(u){return tx(u,Sr,Kh)}function zh(u){return tx(u,tn,Fx)}var Vh=Cl?function(u){return Cl.get(u)}:dp;function $l(u){for(var f=u.name+"",p=Fs[f],_=Mt.call(Fs,f)?p.length:0;_--;){var O=p[_],M=O.func;if(M==null||M==u)return O.name}return f}function Us(u){var f=Mt.call(R,"placeholder")?R:u;return f.placeholder}function Me(){var u=R.iteratee||cp;return u=u===cp?ix:u,arguments.length?u(arguments[0],arguments[1]):u}function Ul(u,f){var p=u.__data__;return a2(f)?p[typeof f=="string"?"string":"hash"]:p.map}function Gh(u){for(var f=Sr(u),p=f.length;p--;){var _=f[p],O=u[_];f[p]=[_,O,$x(O)]}return f}function $a(u,f){var p=uN(u,f);return nx(p)?p:r}function JF(u){var f=Mt.call(u,La),p=u[La];try{u[La]=r;var _=!0}catch{}var O=vl.call(u);return _&&(f?u[La]=p:delete u[La]),O}var Kh=xh?function(u){return u==null?[]:(u=qt(u),Yi(xh(u),function(f){return H_.call(u,f)}))}:hp,Fx=xh?function(u){for(var f=[];u;)Zi(f,Kh(u)),u=_l(u);return f}:hp,Fr=Hr;(wh&&Fr(new wh(new ArrayBuffer(1)))!=Ct||No&&Fr(new No)!=ft||Th&&Fr(Th.resolve())!=Lr||Ns&&Fr(new Ns)!=W||Fo&&Fr(new Fo)!=Re)&&(Fr=function(u){var f=Hr(u),p=f==Ot?u.constructor:r,_=p?Ua(p):"";if(_)switch(_){case LN:return Ct;case NN:return ft;case FN:return Lr;case kN:return W;case jN:return Re}return f});function QF(u,f,p){for(var _=-1,O=p.length;++_<O;){var M=p[_],N=M.size;switch(M.type){case"drop":u+=N;break;case"dropRight":f-=N;break;case"take":f=Nr(f,u+N);break;case"takeRight":u=xr(u,f-N);break}}return{start:u,end:f}}function e2(u){var f=u.match(De);return f?f[1].split(he):[]}function kx(u,f,p){f=ra(f,u);for(var _=-1,O=f.length,M=!1;++_<O;){var N=Xn(f[_]);if(!(M=u!=null&&p(u,N)))break;u=u[N]}return M||++_!=O?M:(O=u==null?0:u.length,!!O&&Gl(O)&&Ei(N,O)&&(Be(u)||qa(u)))}function t2(u){var f=u.length,p=new u.constructor(f);return f&&typeof u[0]=="string"&&Mt.call(u,"index")&&(p.index=u.index,p.input=u.input),p}function jx(u){return typeof u.constructor=="function"&&!zo(u)?ks(_l(u)):{}}function r2(u,f,p){var _=u.constructor;switch(f){case St:return qh(u);case Se:case xe:return new _(+u);case Ct:return $F(u,p);case Zr:case Ur:case _i:case Rr:case En:case zn:case z:case V:case at:return _x(u,p);case ft:return new _;case Ne:case se:return new _(u);case fr:return UF(u);case W:return new _;case ue:return qF(u)}}function n2(u,f){var p=f.length;if(!p)return u;var _=p-1;return f[_]=(p>1?"& ":"")+f[_],f=f.join(p>2?", ":" "),u.replace(we,`{
|
|
50
|
+
/* [wrapped with `+f+`] */
|
|
51
|
+
`)}function i2(u){return Be(u)||qa(u)||!!(W_&&u&&u[W_])}function Ei(u,f){var p=typeof u;return f=f??ae,!!f&&(p=="number"||p!="symbol"&&Vn.test(u))&&u>-1&&u%1==0&&u<f}function Wr(u,f,p){if(!tr(p))return!1;var _=typeof f;return(_=="number"?en(p)&&Ei(f,p.length):_=="string"&&f in p)?Yn(p[f],u):!1}function Xh(u,f){if(Be(u))return!1;var p=typeof u;return p=="number"||p=="symbol"||p=="boolean"||u==null||yn(u)?!0:Os.test(u)||!Es.test(u)||f!=null&&u in qt(f)}function a2(u){var f=typeof u;return f=="string"||f=="number"||f=="symbol"||f=="boolean"?u!=="__proto__":u===null}function Yh(u){var f=$l(u),p=R[f];if(typeof p!="function"||!(f in pt.prototype))return!1;if(u===p)return!0;var _=Vh(p);return!!_&&u===_[0]}function s2(u){return!!$_&&$_ in u}var o2=gl?Oi:pp;function zo(u){var f=u&&u.constructor,p=typeof f=="function"&&f.prototype||Ls;return u===p}function $x(u){return u===u&&!tr(u)}function Ux(u,f){return function(p){return p==null?!1:p[u]===f&&(f!==r||u in qt(p))}}function u2(u){var f=zl(u,function(_){return p.size===d&&p.clear(),_}),p=f.cache;return f}function l2(u,f){var p=u[1],_=f[1],O=p|_,M=O<(x|w|D),N=_==D&&p==E||_==D&&p==P&&u[7].length<=f[8]||_==(D|P)&&f[7].length<=f[8]&&p==E;if(!(M||N))return u;_&x&&(u[2]=f[2],O|=p&x?0:S);var j=f[3];if(j){var q=u[3];u[3]=q?wx(q,j,f[4]):j,u[4]=q?Ji(u[3],h):f[4]}return j=f[5],j&&(q=u[5],u[5]=q?Tx(q,j,f[6]):j,u[6]=q?Ji(u[5],h):f[6]),j=f[7],j&&(u[7]=j),_&D&&(u[8]=u[8]==null?f[8]:Nr(u[8],f[8])),u[9]==null&&(u[9]=f[9]),u[0]=f[0],u[1]=O,u}function c2(u){var f=[];if(u!=null)for(var p in qt(u))f.push(p);return f}function f2(u){return vl.call(u)}function qx(u,f,p){return f=xr(f===r?u.length-1:f,0),function(){for(var _=arguments,O=-1,M=xr(_.length-f,0),N=K(M);++O<M;)N[O]=_[f+O];O=-1;for(var j=K(f+1);++O<f;)j[O]=_[O];return j[f]=p(N),pn(u,this,j)}}function Hx(u,f){return f.length<2?u:ja(u,Ln(f,0,-1))}function d2(u,f){for(var p=u.length,_=Nr(f.length,p),O=Qr(u);_--;){var M=f[_];u[_]=Ei(M,p)?O[M]:r}return u}function Zh(u,f){if(!(f==="constructor"&&typeof u[f]=="function")&&f!="__proto__")return u[f]}var Wx=zx(dx),Vo=ON||function(u,f){return Dr.setTimeout(u,f)},Jh=zx(NF);function Bx(u,f,p){var _=f+"";return Jh(u,n2(_,h2(e2(_),p)))}function zx(u){var f=0,p=0;return function(){var _=DN(),O=ee-(_-p);if(p=_,O>0){if(++f>=X)return arguments[0]}else f=0;return u.apply(r,arguments)}}function ql(u,f){var p=-1,_=u.length,O=_-1;for(f=f===r?_:f;++p<f;){var M=Lh(p,O),N=u[M];u[M]=u[p],u[p]=N}return u.length=f,u}var Vx=u2(function(u){var f=[];return u.charCodeAt(0)===46&&f.push(""),u.replace(k,function(p,_,O,M){f.push(O?M.replace(be,"$1"):_||p)}),f});function Xn(u){if(typeof u=="string"||yn(u))return u;var f=u+"";return f=="0"&&1/u==-B?"-0":f}function Ua(u){if(u!=null){try{return ml.call(u)}catch{}try{return u+""}catch{}}return""}function h2(u,f){return gn(Le,function(p){var _="_."+p[0];f&p[1]&&!fl(u,_)&&u.push(_)}),u.sort()}function Gx(u){if(u instanceof pt)return u.clone();var f=new Mn(u.__wrapped__,u.__chain__);return f.__actions__=Qr(u.__actions__),f.__index__=u.__index__,f.__values__=u.__values__,f}function p2(u,f,p){(p?Wr(u,f,p):f===r)?f=1:f=xr(ze(f),0);var _=u==null?0:u.length;if(!_||f<1)return[];for(var O=0,M=0,N=K(Tl(_/f));O<_;)N[M++]=Ln(u,O,O+=f);return N}function g2(u){for(var f=-1,p=u==null?0:u.length,_=0,O=[];++f<p;){var M=u[f];M&&(O[_++]=M)}return O}function m2(){var u=arguments.length;if(!u)return[];for(var f=K(u-1),p=arguments[0],_=u;_--;)f[_-1]=arguments[_];return Zi(Be(p)?Qr(p):[p],Mr(f,1))}var v2=tt(function(u,f){return dr(u)?Uo(u,Mr(f,1,dr,!0)):[]}),y2=tt(function(u,f){var p=Nn(f);return dr(p)&&(p=r),dr(u)?Uo(u,Mr(f,1,dr,!0),Me(p,2)):[]}),b2=tt(function(u,f){var p=Nn(f);return dr(p)&&(p=r),dr(u)?Uo(u,Mr(f,1,dr,!0),r,p):[]});function _2(u,f,p){var _=u==null?0:u.length;return _?(f=p||f===r?1:ze(f),Ln(u,f<0?0:f,_)):[]}function x2(u,f,p){var _=u==null?0:u.length;return _?(f=p||f===r?1:ze(f),f=_-f,Ln(u,0,f<0?0:f)):[]}function w2(u,f){return u&&u.length?Pl(u,Me(f,3),!0,!0):[]}function T2(u,f){return u&&u.length?Pl(u,Me(f,3),!0):[]}function S2(u,f,p,_){var O=u==null?0:u.length;return O?(p&&typeof p!="number"&&Wr(u,f,p)&&(p=0,_=O),mF(u,f,p,_)):[]}function Kx(u,f,p){var _=u==null?0:u.length;if(!_)return-1;var O=p==null?0:ze(p);return O<0&&(O=xr(_+O,0)),dl(u,Me(f,3),O)}function Xx(u,f,p){var _=u==null?0:u.length;if(!_)return-1;var O=_-1;return p!==r&&(O=ze(p),O=p<0?xr(_+O,0):Nr(O,_-1)),dl(u,Me(f,3),O,!0)}function Yx(u){var f=u==null?0:u.length;return f?Mr(u,1):[]}function C2(u){var f=u==null?0:u.length;return f?Mr(u,B):[]}function E2(u,f){var p=u==null?0:u.length;return p?(f=f===r?1:ze(f),Mr(u,f)):[]}function O2(u){for(var f=-1,p=u==null?0:u.length,_={};++f<p;){var O=u[f];ii(_,O[0],O[1])}return _}function Zx(u){return u&&u.length?u[0]:r}function A2(u,f,p){var _=u==null?0:u.length;if(!_)return-1;var O=p==null?0:ze(p);return O<0&&(O=xr(_+O,0)),Rs(u,f,O)}function I2(u){var f=u==null?0:u.length;return f?Ln(u,0,-1):[]}var R2=tt(function(u){var f=Yt(u,$h);return f.length&&f[0]===u[0]?Ih(f):[]}),D2=tt(function(u){var f=Nn(u),p=Yt(u,$h);return f===Nn(p)?f=r:p.pop(),p.length&&p[0]===u[0]?Ih(p,Me(f,2)):[]}),M2=tt(function(u){var f=Nn(u),p=Yt(u,$h);return f=typeof f=="function"?f:r,f&&p.pop(),p.length&&p[0]===u[0]?Ih(p,r,f):[]});function P2(u,f){return u==null?"":IN.call(u,f)}function Nn(u){var f=u==null?0:u.length;return f?u[f-1]:r}function L2(u,f,p){var _=u==null?0:u.length;if(!_)return-1;var O=_;return p!==r&&(O=ze(p),O=O<0?xr(_+O,0):Nr(O,_-1)),f===f?hN(u,f,O):dl(u,D_,O,!0)}function N2(u,f){return u&&u.length?ux(u,ze(f)):r}var F2=tt(Jx);function Jx(u,f){return u&&u.length&&f&&f.length?Ph(u,f):u}function k2(u,f,p){return u&&u.length&&f&&f.length?Ph(u,f,Me(p,2)):u}function j2(u,f,p){return u&&u.length&&f&&f.length?Ph(u,f,r,p):u}var $2=Ci(function(u,f){var p=u==null?0:u.length,_=Ch(u,f);return fx(u,Yt(f,function(O){return Ei(O,p)?+O:O}).sort(xx)),_});function U2(u,f){var p=[];if(!(u&&u.length))return p;var _=-1,O=[],M=u.length;for(f=Me(f,3);++_<M;){var N=u[_];f(N,_,u)&&(p.push(N),O.push(_))}return fx(u,O),p}function Qh(u){return u==null?u:PN.call(u)}function q2(u,f,p){var _=u==null?0:u.length;return _?(p&&typeof p!="number"&&Wr(u,f,p)?(f=0,p=_):(f=f==null?0:ze(f),p=p===r?_:ze(p)),Ln(u,f,p)):[]}function H2(u,f){return Ml(u,f)}function W2(u,f,p){return Fh(u,f,Me(p,2))}function B2(u,f){var p=u==null?0:u.length;if(p){var _=Ml(u,f);if(_<p&&Yn(u[_],f))return _}return-1}function z2(u,f){return Ml(u,f,!0)}function V2(u,f,p){return Fh(u,f,Me(p,2),!0)}function G2(u,f){var p=u==null?0:u.length;if(p){var _=Ml(u,f,!0)-1;if(Yn(u[_],f))return _}return-1}function K2(u){return u&&u.length?hx(u):[]}function X2(u,f){return u&&u.length?hx(u,Me(f,2)):[]}function Y2(u){var f=u==null?0:u.length;return f?Ln(u,1,f):[]}function Z2(u,f,p){return u&&u.length?(f=p||f===r?1:ze(f),Ln(u,0,f<0?0:f)):[]}function J2(u,f,p){var _=u==null?0:u.length;return _?(f=p||f===r?1:ze(f),f=_-f,Ln(u,f<0?0:f,_)):[]}function Q2(u,f){return u&&u.length?Pl(u,Me(f,3),!1,!0):[]}function ek(u,f){return u&&u.length?Pl(u,Me(f,3)):[]}var tk=tt(function(u){return ta(Mr(u,1,dr,!0))}),rk=tt(function(u){var f=Nn(u);return dr(f)&&(f=r),ta(Mr(u,1,dr,!0),Me(f,2))}),nk=tt(function(u){var f=Nn(u);return f=typeof f=="function"?f:r,ta(Mr(u,1,dr,!0),r,f)});function ik(u){return u&&u.length?ta(u):[]}function ak(u,f){return u&&u.length?ta(u,Me(f,2)):[]}function sk(u,f){return f=typeof f=="function"?f:r,u&&u.length?ta(u,r,f):[]}function ep(u){if(!(u&&u.length))return[];var f=0;return u=Yi(u,function(p){if(dr(p))return f=xr(p.length,f),!0}),vh(f,function(p){return Yt(u,ph(p))})}function Qx(u,f){if(!(u&&u.length))return[];var p=ep(u);return f==null?p:Yt(p,function(_){return pn(f,r,_)})}var ok=tt(function(u,f){return dr(u)?Uo(u,f):[]}),uk=tt(function(u){return jh(Yi(u,dr))}),lk=tt(function(u){var f=Nn(u);return dr(f)&&(f=r),jh(Yi(u,dr),Me(f,2))}),ck=tt(function(u){var f=Nn(u);return f=typeof f=="function"?f:r,jh(Yi(u,dr),r,f)}),fk=tt(ep);function dk(u,f){return vx(u||[],f||[],$o)}function hk(u,f){return vx(u||[],f||[],Wo)}var pk=tt(function(u){var f=u.length,p=f>1?u[f-1]:r;return p=typeof p=="function"?(u.pop(),p):r,Qx(u,p)});function ew(u){var f=R(u);return f.__chain__=!0,f}function gk(u,f){return f(u),u}function Hl(u,f){return f(u)}var mk=Ci(function(u){var f=u.length,p=f?u[0]:0,_=this.__wrapped__,O=function(M){return Ch(M,u)};return f>1||this.__actions__.length||!(_ instanceof pt)||!Ei(p)?this.thru(O):(_=_.slice(p,+p+(f?1:0)),_.__actions__.push({func:Hl,args:[O],thisArg:r}),new Mn(_,this.__chain__).thru(function(M){return f&&!M.length&&M.push(r),M}))});function vk(){return ew(this)}function yk(){return new Mn(this.value(),this.__chain__)}function bk(){this.__values__===r&&(this.__values__=pw(this.value()));var u=this.__index__>=this.__values__.length,f=u?r:this.__values__[this.__index__++];return{done:u,value:f}}function _k(){return this}function xk(u){for(var f,p=this;p instanceof Ol;){var _=Gx(p);_.__index__=0,_.__values__=r,f?O.__wrapped__=_:f=_;var O=_;p=p.__wrapped__}return O.__wrapped__=u,f}function wk(){var u=this.__wrapped__;if(u instanceof pt){var f=u;return this.__actions__.length&&(f=new pt(this)),f=f.reverse(),f.__actions__.push({func:Hl,args:[Qh],thisArg:r}),new Mn(f,this.__chain__)}return this.thru(Qh)}function Tk(){return mx(this.__wrapped__,this.__actions__)}var Sk=Ll(function(u,f,p){Mt.call(u,p)?++u[p]:ii(u,p,1)});function Ck(u,f,p){var _=Be(u)?I_:gF;return p&&Wr(u,f,p)&&(f=r),_(u,Me(f,3))}function Ek(u,f){var p=Be(u)?Yi:Q_;return p(u,Me(f,3))}var Ok=Ox(Kx),Ak=Ox(Xx);function Ik(u,f){return Mr(Wl(u,f),1)}function Rk(u,f){return Mr(Wl(u,f),B)}function Dk(u,f,p){return p=p===r?1:ze(p),Mr(Wl(u,f),p)}function tw(u,f){var p=Be(u)?gn:ea;return p(u,Me(f,3))}function rw(u,f){var p=Be(u)?YL:J_;return p(u,Me(f,3))}var Mk=Ll(function(u,f,p){Mt.call(u,p)?u[p].push(f):ii(u,p,[f])});function Pk(u,f,p,_){u=en(u)?u:Hs(u),p=p&&!_?ze(p):0;var O=u.length;return p<0&&(p=xr(O+p,0)),Kl(u)?p<=O&&u.indexOf(f,p)>-1:!!O&&Rs(u,f,p)>-1}var Lk=tt(function(u,f,p){var _=-1,O=typeof f=="function",M=en(u)?K(u.length):[];return ea(u,function(N){M[++_]=O?pn(f,N,p):qo(N,f,p)}),M}),Nk=Ll(function(u,f,p){ii(u,p,f)});function Wl(u,f){var p=Be(u)?Yt:ax;return p(u,Me(f,3))}function Fk(u,f,p,_){return u==null?[]:(Be(f)||(f=f==null?[]:[f]),p=_?r:p,Be(p)||(p=p==null?[]:[p]),lx(u,f,p))}var kk=Ll(function(u,f,p){u[p?0:1].push(f)},function(){return[[],[]]});function jk(u,f,p){var _=Be(u)?dh:P_,O=arguments.length<3;return _(u,Me(f,4),p,O,ea)}function $k(u,f,p){var _=Be(u)?ZL:P_,O=arguments.length<3;return _(u,Me(f,4),p,O,J_)}function Uk(u,f){var p=Be(u)?Yi:Q_;return p(u,Vl(Me(f,3)))}function qk(u){var f=Be(u)?K_:PF;return f(u)}function Hk(u,f,p){(p?Wr(u,f,p):f===r)?f=1:f=ze(f);var _=Be(u)?cF:LF;return _(u,f)}function Wk(u){var f=Be(u)?fF:FF;return f(u)}function Bk(u){if(u==null)return 0;if(en(u))return Kl(u)?Ms(u):u.length;var f=Fr(u);return f==ft||f==W?u.size:Dh(u).length}function zk(u,f,p){var _=Be(u)?hh:kF;return p&&Wr(u,f,p)&&(f=r),_(u,Me(f,3))}var Vk=tt(function(u,f){if(u==null)return[];var p=f.length;return p>1&&Wr(u,f[0],f[1])?f=[]:p>2&&Wr(f[0],f[1],f[2])&&(f=[f[0]]),lx(u,Mr(f,1),[])}),Bl=EN||function(){return Dr.Date.now()};function Gk(u,f){if(typeof f!="function")throw new Dn(s);return u=ze(u),function(){if(--u<1)return f.apply(this,arguments)}}function nw(u,f,p){return f=p?r:f,f=u&&f==null?u.length:f,Si(u,D,r,r,r,r,f)}function iw(u,f){var p;if(typeof f!="function")throw new Dn(s);return u=ze(u),function(){return--u>0&&(p=f.apply(this,arguments)),u<=1&&(f=r),p}}var tp=tt(function(u,f,p){var _=x;if(p.length){var O=Ji(p,Us(tp));_|=I}return Si(u,_,f,p,O)}),aw=tt(function(u,f,p){var _=x|w;if(p.length){var O=Ji(p,Us(aw));_|=I}return Si(f,_,u,p,O)});function sw(u,f,p){f=p?r:f;var _=Si(u,E,r,r,r,r,r,f);return _.placeholder=sw.placeholder,_}function ow(u,f,p){f=p?r:f;var _=Si(u,C,r,r,r,r,r,f);return _.placeholder=ow.placeholder,_}function uw(u,f,p){var _,O,M,N,j,q,Z=0,Q=!1,ne=!1,le=!0;if(typeof u!="function")throw new Dn(s);f=Fn(f)||0,tr(p)&&(Q=!!p.leading,ne="maxWait"in p,M=ne?xr(Fn(p.maxWait)||0,f):M,le="trailing"in p?!!p.trailing:le);function Te(hr){var Zn=_,Ii=O;return _=O=r,Z=hr,N=u.apply(Ii,Zn),N}function Pe(hr){return Z=hr,j=Vo(dt,f),Q?Te(hr):N}function Ke(hr){var Zn=hr-q,Ii=hr-Z,Aw=f-Zn;return ne?Nr(Aw,M-Ii):Aw}function Ie(hr){var Zn=hr-q,Ii=hr-Z;return q===r||Zn>=f||Zn<0||ne&&Ii>=M}function dt(){var hr=Bl();if(Ie(hr))return vt(hr);j=Vo(dt,Ke(hr))}function vt(hr){return j=r,le&&_?Te(hr):(_=O=r,N)}function bn(){j!==r&&yx(j),Z=0,_=q=O=j=r}function Br(){return j===r?N:vt(Bl())}function _n(){var hr=Bl(),Zn=Ie(hr);if(_=arguments,O=this,q=hr,Zn){if(j===r)return Pe(q);if(ne)return yx(j),j=Vo(dt,f),Te(q)}return j===r&&(j=Vo(dt,f)),N}return _n.cancel=bn,_n.flush=Br,_n}var Kk=tt(function(u,f){return Z_(u,1,f)}),Xk=tt(function(u,f,p){return Z_(u,Fn(f)||0,p)});function Yk(u){return Si(u,L)}function zl(u,f){if(typeof u!="function"||f!=null&&typeof f!="function")throw new Dn(s);var p=function(){var _=arguments,O=f?f.apply(this,_):_[0],M=p.cache;if(M.has(O))return M.get(O);var N=u.apply(this,_);return p.cache=M.set(O,N)||M,N};return p.cache=new(zl.Cache||Ti),p}zl.Cache=Ti;function Vl(u){if(typeof u!="function")throw new Dn(s);return function(){var f=arguments;switch(f.length){case 0:return!u.call(this);case 1:return!u.call(this,f[0]);case 2:return!u.call(this,f[0],f[1]);case 3:return!u.call(this,f[0],f[1],f[2])}return!u.apply(this,f)}}function Zk(u){return iw(2,u)}var Jk=jF(function(u,f){f=f.length==1&&Be(f[0])?Yt(f[0],mn(Me())):Yt(Mr(f,1),mn(Me()));var p=f.length;return tt(function(_){for(var O=-1,M=Nr(_.length,p);++O<M;)_[O]=f[O].call(this,_[O]);return pn(u,this,_)})}),rp=tt(function(u,f){var p=Ji(f,Us(rp));return Si(u,I,r,f,p)}),lw=tt(function(u,f){var p=Ji(f,Us(lw));return Si(u,T,r,f,p)}),Qk=Ci(function(u,f){return Si(u,P,r,r,r,f)});function ej(u,f){if(typeof u!="function")throw new Dn(s);return f=f===r?f:ze(f),tt(u,f)}function tj(u,f){if(typeof u!="function")throw new Dn(s);return f=f==null?0:xr(ze(f),0),tt(function(p){var _=p[f],O=na(p,0,f);return _&&Zi(O,_),pn(u,this,O)})}function rj(u,f,p){var _=!0,O=!0;if(typeof u!="function")throw new Dn(s);return tr(p)&&(_="leading"in p?!!p.leading:_,O="trailing"in p?!!p.trailing:O),uw(u,f,{leading:_,maxWait:f,trailing:O})}function nj(u){return nw(u,1)}function ij(u,f){return rp(Uh(f),u)}function aj(){if(!arguments.length)return[];var u=arguments[0];return Be(u)?u:[u]}function sj(u){return Pn(u,v)}function oj(u,f){return f=typeof f=="function"?f:r,Pn(u,v,f)}function uj(u){return Pn(u,g|v)}function lj(u,f){return f=typeof f=="function"?f:r,Pn(u,g|v,f)}function cj(u,f){return f==null||Y_(u,f,Sr(f))}function Yn(u,f){return u===f||u!==u&&f!==f}var fj=jl(Ah),dj=jl(function(u,f){return u>=f}),qa=rx((function(){return arguments})())?rx:function(u){return sr(u)&&Mt.call(u,"callee")&&!H_.call(u,"callee")},Be=K.isArray,hj=T_?mn(T_):xF;function en(u){return u!=null&&Gl(u.length)&&!Oi(u)}function dr(u){return sr(u)&&en(u)}function pj(u){return u===!0||u===!1||sr(u)&&Hr(u)==Se}var ia=AN||pp,gj=S_?mn(S_):wF;function mj(u){return sr(u)&&u.nodeType===1&&!Go(u)}function vj(u){if(u==null)return!0;if(en(u)&&(Be(u)||typeof u=="string"||typeof u.splice=="function"||ia(u)||qs(u)||qa(u)))return!u.length;var f=Fr(u);if(f==ft||f==W)return!u.size;if(zo(u))return!Dh(u).length;for(var p in u)if(Mt.call(u,p))return!1;return!0}function yj(u,f){return Ho(u,f)}function bj(u,f,p){p=typeof p=="function"?p:r;var _=p?p(u,f):r;return _===r?Ho(u,f,r,p):!!_}function np(u){if(!sr(u))return!1;var f=Hr(u);return f==Oe||f==Ze||typeof u.message=="string"&&typeof u.name=="string"&&!Go(u)}function _j(u){return typeof u=="number"&&B_(u)}function Oi(u){if(!tr(u))return!1;var f=Hr(u);return f==Je||f==Rt||f==We||f==Yr}function cw(u){return typeof u=="number"&&u==ze(u)}function Gl(u){return typeof u=="number"&&u>-1&&u%1==0&&u<=ae}function tr(u){var f=typeof u;return u!=null&&(f=="object"||f=="function")}function sr(u){return u!=null&&typeof u=="object"}var fw=C_?mn(C_):SF;function xj(u,f){return u===f||Rh(u,f,Gh(f))}function wj(u,f,p){return p=typeof p=="function"?p:r,Rh(u,f,Gh(f),p)}function Tj(u){return dw(u)&&u!=+u}function Sj(u){if(o2(u))throw new je(a);return nx(u)}function Cj(u){return u===null}function Ej(u){return u==null}function dw(u){return typeof u=="number"||sr(u)&&Hr(u)==Ne}function Go(u){if(!sr(u)||Hr(u)!=Ot)return!1;var f=_l(u);if(f===null)return!0;var p=Mt.call(f,"constructor")&&f.constructor;return typeof p=="function"&&p instanceof p&&ml.call(p)==wN}var ip=E_?mn(E_):CF;function Oj(u){return cw(u)&&u>=-ae&&u<=ae}var hw=O_?mn(O_):EF;function Kl(u){return typeof u=="string"||!Be(u)&&sr(u)&&Hr(u)==se}function yn(u){return typeof u=="symbol"||sr(u)&&Hr(u)==ue}var qs=A_?mn(A_):OF;function Aj(u){return u===r}function Ij(u){return sr(u)&&Fr(u)==Re}function Rj(u){return sr(u)&&Hr(u)==Qe}var Dj=jl(Mh),Mj=jl(function(u,f){return u<=f});function pw(u){if(!u)return[];if(en(u))return Kl(u)?Gn(u):Qr(u);if(Lo&&u[Lo])return cN(u[Lo]());var f=Fr(u),p=f==ft?bh:f==W?hl:Hs;return p(u)}function Ai(u){if(!u)return u===0?u:0;if(u=Fn(u),u===B||u===-B){var f=u<0?-1:1;return f*Ce}return u===u?u:0}function ze(u){var f=Ai(u),p=f%1;return f===f?p?f-p:f:0}function gw(u){return u?ka(ze(u),0,ve):0}function Fn(u){if(typeof u=="number")return u;if(yn(u))return Ae;if(tr(u)){var f=typeof u.valueOf=="function"?u.valueOf():u;u=tr(f)?f+"":f}if(typeof u!="string")return u===0?u:+u;u=L_(u);var p=gt.test(u);return p||Wt.test(u)?GL(u.slice(2),p?2:8):er.test(u)?Ae:+u}function mw(u){return si(u,tn(u))}function Pj(u){return u?ka(ze(u),-ae,ae):u===0?u:0}function Pt(u){return u==null?"":vn(u)}var Lj=js(function(u,f){if(zo(f)||en(f)){si(f,Sr(f),u);return}for(var p in f)Mt.call(f,p)&&$o(u,p,f[p])}),vw=js(function(u,f){si(f,tn(f),u)}),yw=js(function(u,f,p,_){si(f,tn(f),u,_)}),ap=js(function(u,f,p,_){si(f,Sr(f),u,_)}),Nj=Ci(Ch);function Fj(u,f){var p=ks(u);return f==null?p:X_(p,f)}var kj=tt(function(u,f){u=qt(u);var p=-1,_=f.length,O=_>2?f[2]:r;for(O&&Wr(f[0],f[1],O)&&(_=1);++p<_;)for(var M=f[p],N=tn(M),j=-1,q=N.length;++j<q;){var Z=N[j],Q=u[Z];(Q===r||Yn(Q,Ls[Z])&&!Mt.call(u,Z))&&(u[Z]=M[Z])}return u}),jj=tt(function(u){return u.push(r,Lx),pn(bw,r,u)});function $j(u,f){return R_(u,Me(f,3),ai)}function Uj(u,f){return R_(u,Me(f,3),Oh)}function qj(u,f){return u==null?u:Eh(u,Me(f,3),tn)}function Hj(u,f){return u==null?u:ex(u,Me(f,3),tn)}function Wj(u,f){return u&&ai(u,Me(f,3))}function Bj(u,f){return u&&Oh(u,Me(f,3))}function zj(u){return u==null?[]:Rl(u,Sr(u))}function Vj(u){return u==null?[]:Rl(u,tn(u))}function sp(u,f,p){var _=u==null?r:ja(u,f);return _===r?p:_}function Gj(u,f){return u!=null&&kx(u,f,vF)}function op(u,f){return u!=null&&kx(u,f,yF)}var Kj=Ix(function(u,f,p){f!=null&&typeof f.toString!="function"&&(f=vl.call(f)),u[f]=p},lp(rn)),Xj=Ix(function(u,f,p){f!=null&&typeof f.toString!="function"&&(f=vl.call(f)),Mt.call(u,f)?u[f].push(p):u[f]=[p]},Me),Yj=tt(qo);function Sr(u){return en(u)?G_(u):Dh(u)}function tn(u){return en(u)?G_(u,!0):AF(u)}function Zj(u,f){var p={};return f=Me(f,3),ai(u,function(_,O,M){ii(p,f(_,O,M),_)}),p}function Jj(u,f){var p={};return f=Me(f,3),ai(u,function(_,O,M){ii(p,O,f(_,O,M))}),p}var Qj=js(function(u,f,p){Dl(u,f,p)}),bw=js(function(u,f,p,_){Dl(u,f,p,_)}),e$=Ci(function(u,f){var p={};if(u==null)return p;var _=!1;f=Yt(f,function(M){return M=ra(M,u),_||(_=M.length>1),M}),si(u,zh(u),p),_&&(p=Pn(p,g|m|v,XF));for(var O=f.length;O--;)kh(p,f[O]);return p});function t$(u,f){return _w(u,Vl(Me(f)))}var r$=Ci(function(u,f){return u==null?{}:RF(u,f)});function _w(u,f){if(u==null)return{};var p=Yt(zh(u),function(_){return[_]});return f=Me(f),cx(u,p,function(_,O){return f(_,O[0])})}function n$(u,f,p){f=ra(f,u);var _=-1,O=f.length;for(O||(O=1,u=r);++_<O;){var M=u==null?r:u[Xn(f[_])];M===r&&(_=O,M=p),u=Oi(M)?M.call(u):M}return u}function i$(u,f,p){return u==null?u:Wo(u,f,p)}function a$(u,f,p,_){return _=typeof _=="function"?_:r,u==null?u:Wo(u,f,p,_)}var xw=Mx(Sr),ww=Mx(tn);function s$(u,f,p){var _=Be(u),O=_||ia(u)||qs(u);if(f=Me(f,4),p==null){var M=u&&u.constructor;O?p=_?new M:[]:tr(u)?p=Oi(M)?ks(_l(u)):{}:p={}}return(O?gn:ai)(u,function(N,j,q){return f(p,N,j,q)}),p}function o$(u,f){return u==null?!0:kh(u,f)}function u$(u,f,p){return u==null?u:gx(u,f,Uh(p))}function l$(u,f,p,_){return _=typeof _=="function"?_:r,u==null?u:gx(u,f,Uh(p),_)}function Hs(u){return u==null?[]:yh(u,Sr(u))}function c$(u){return u==null?[]:yh(u,tn(u))}function f$(u,f,p){return p===r&&(p=f,f=r),p!==r&&(p=Fn(p),p=p===p?p:0),f!==r&&(f=Fn(f),f=f===f?f:0),ka(Fn(u),f,p)}function d$(u,f,p){return f=Ai(f),p===r?(p=f,f=0):p=Ai(p),u=Fn(u),bF(u,f,p)}function h$(u,f,p){if(p&&typeof p!="boolean"&&Wr(u,f,p)&&(f=p=r),p===r&&(typeof f=="boolean"?(p=f,f=r):typeof u=="boolean"&&(p=u,u=r)),u===r&&f===r?(u=0,f=1):(u=Ai(u),f===r?(f=u,u=0):f=Ai(f)),u>f){var _=u;u=f,f=_}if(p||u%1||f%1){var O=z_();return Nr(u+O*(f-u+VL("1e-"+((O+"").length-1))),f)}return Lh(u,f)}var p$=$s(function(u,f,p){return f=f.toLowerCase(),u+(p?Tw(f):f)});function Tw(u){return up(Pt(u).toLowerCase())}function Sw(u){return u=Pt(u),u&&u.replace(Ia,aN).replace(FL,"")}function g$(u,f,p){u=Pt(u),f=vn(f);var _=u.length;p=p===r?_:ka(ze(p),0,_);var O=p;return p-=f.length,p>=0&&u.slice(p,O)==f}function m$(u){return u=Pt(u),u&&An.test(u)?u.replace(On,sN):u}function v$(u){return u=Pt(u),u&&G.test(u)?u.replace(U,"\\$&"):u}var y$=$s(function(u,f,p){return u+(p?"-":"")+f.toLowerCase()}),b$=$s(function(u,f,p){return u+(p?" ":"")+f.toLowerCase()}),_$=Ex("toLowerCase");function x$(u,f,p){u=Pt(u),f=ze(f);var _=f?Ms(u):0;if(!f||_>=f)return u;var O=(f-_)/2;return kl(Sl(O),p)+u+kl(Tl(O),p)}function w$(u,f,p){u=Pt(u),f=ze(f);var _=f?Ms(u):0;return f&&_<f?u+kl(f-_,p):u}function T$(u,f,p){u=Pt(u),f=ze(f);var _=f?Ms(u):0;return f&&_<f?kl(f-_,p)+u:u}function S$(u,f,p){return p||f==null?f=0:f&&(f=+f),MN(Pt(u).replace(re,""),f||0)}function C$(u,f,p){return(p?Wr(u,f,p):f===r)?f=1:f=ze(f),Nh(Pt(u),f)}function E$(){var u=arguments,f=Pt(u[0]);return u.length<3?f:f.replace(u[1],u[2])}var O$=$s(function(u,f,p){return u+(p?"_":"")+f.toLowerCase()});function A$(u,f,p){return p&&typeof p!="number"&&Wr(u,f,p)&&(f=p=r),p=p===r?ve:p>>>0,p?(u=Pt(u),u&&(typeof f=="string"||f!=null&&!ip(f))&&(f=vn(f),!f&&Ds(u))?na(Gn(u),0,p):u.split(f,p)):[]}var I$=$s(function(u,f,p){return u+(p?" ":"")+up(f)});function R$(u,f,p){return u=Pt(u),p=p==null?0:ka(ze(p),0,u.length),f=vn(f),u.slice(p,p+f.length)==f}function D$(u,f,p){var _=R.templateSettings;p&&Wr(u,f,p)&&(f=r),u=Pt(u),f=ap({},f,_,Px);var O=ap({},f.imports,_.imports,Px),M=Sr(O),N=yh(O,M);gn(M,function(Ie){if(de.test(Ie))throw new je(l)});var j,q,Z=0,Q=f.interpolate||Jr,ne="__p += '",le=_h((f.escape||Jr).source+"|"+Q.source+"|"+(Q===br?Fe:Jr).source+"|"+(f.evaluate||Jr).source+"|$","g"),Te="//# sourceURL="+(Mt.call(f,"sourceURL")?(f.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++qL+"]")+`
|
|
52
|
+
`;u.replace(le,function(Ie,dt,vt,bn,Br,_n){return vt||(vt=bn),ne+=u.slice(Z,_n).replace(In,oN),dt&&(j=!0,ne+=`' +
|
|
53
|
+
__e(`+dt+`) +
|
|
54
|
+
'`),Br&&(q=!0,ne+=`';
|
|
55
|
+
`+Br+`;
|
|
56
|
+
__p += '`),vt&&(ne+=`' +
|
|
57
|
+
((__t = (`+vt+`)) == null ? '' : __t) +
|
|
58
|
+
'`),Z=_n+Ie.length,Ie}),ne+=`';
|
|
59
|
+
`;var Pe=Mt.call(f,"variable")&&f.variable;if(!Pe)ne=`with (obj) {
|
|
60
|
+
`+ne+`
|
|
61
|
+
}
|
|
62
|
+
`;else if(de.test(Pe))throw new je(o);ne=(q?ne.replace(xt,""):ne).replace(Dt,"$1").replace(ke,"$1;"),ne="function("+(Pe||"obj")+`) {
|
|
63
|
+
`+(Pe?"":`obj || (obj = {});
|
|
64
|
+
`)+"var __t, __p = ''"+(j?", __e = _.escape":"")+(q?`, __j = Array.prototype.join;
|
|
65
|
+
function print() { __p += __j.call(arguments, '') }
|
|
66
|
+
`:`;
|
|
67
|
+
`)+ne+`return __p
|
|
68
|
+
}`;var Ke=Ew(function(){return At(M,Te+"return "+ne).apply(r,N)});if(Ke.source=ne,np(Ke))throw Ke;return Ke}function M$(u){return Pt(u).toLowerCase()}function P$(u){return Pt(u).toUpperCase()}function L$(u,f,p){if(u=Pt(u),u&&(p||f===r))return L_(u);if(!u||!(f=vn(f)))return u;var _=Gn(u),O=Gn(f),M=N_(_,O),N=F_(_,O)+1;return na(_,M,N).join("")}function N$(u,f,p){if(u=Pt(u),u&&(p||f===r))return u.slice(0,j_(u)+1);if(!u||!(f=vn(f)))return u;var _=Gn(u),O=F_(_,Gn(f))+1;return na(_,0,O).join("")}function F$(u,f,p){if(u=Pt(u),u&&(p||f===r))return u.replace(re,"");if(!u||!(f=vn(f)))return u;var _=Gn(u),O=N_(_,Gn(f));return na(_,O).join("")}function k$(u,f){var p=F,_=H;if(tr(f)){var O="separator"in f?f.separator:O;p="length"in f?ze(f.length):p,_="omission"in f?vn(f.omission):_}u=Pt(u);var M=u.length;if(Ds(u)){var N=Gn(u);M=N.length}if(p>=M)return u;var j=p-Ms(_);if(j<1)return _;var q=N?na(N,0,j).join(""):u.slice(0,j);if(O===r)return q+_;if(N&&(j+=q.length-j),ip(O)){if(u.slice(j).search(O)){var Z,Q=q;for(O.global||(O=_h(O.source,Pt(et.exec(O))+"g")),O.lastIndex=0;Z=O.exec(Q);)var ne=Z.index;q=q.slice(0,ne===r?j:ne)}}else if(u.indexOf(vn(O),j)!=j){var le=q.lastIndexOf(O);le>-1&&(q=q.slice(0,le))}return q+_}function j$(u){return u=Pt(u),u&&Tr.test(u)?u.replace(qr,pN):u}var $$=$s(function(u,f,p){return u+(p?" ":"")+f.toUpperCase()}),up=Ex("toUpperCase");function Cw(u,f,p){return u=Pt(u),f=p?r:f,f===r?lN(u)?vN(u):eN(u):u.match(f)||[]}var Ew=tt(function(u,f){try{return pn(u,r,f)}catch(p){return np(p)?p:new je(p)}}),U$=Ci(function(u,f){return gn(f,function(p){p=Xn(p),ii(u,p,tp(u[p],u))}),u});function q$(u){var f=u==null?0:u.length,p=Me();return u=f?Yt(u,function(_){if(typeof _[1]!="function")throw new Dn(s);return[p(_[0]),_[1]]}):[],tt(function(_){for(var O=-1;++O<f;){var M=u[O];if(pn(M[0],this,_))return pn(M[1],this,_)}})}function H$(u){return pF(Pn(u,g))}function lp(u){return function(){return u}}function W$(u,f){return u==null||u!==u?f:u}var B$=Ax(),z$=Ax(!0);function rn(u){return u}function cp(u){return ix(typeof u=="function"?u:Pn(u,g))}function V$(u){return sx(Pn(u,g))}function G$(u,f){return ox(u,Pn(f,g))}var K$=tt(function(u,f){return function(p){return qo(p,u,f)}}),X$=tt(function(u,f){return function(p){return qo(u,p,f)}});function fp(u,f,p){var _=Sr(f),O=Rl(f,_);p==null&&!(tr(f)&&(O.length||!_.length))&&(p=f,f=u,u=this,O=Rl(f,Sr(f)));var M=!(tr(p)&&"chain"in p)||!!p.chain,N=Oi(u);return gn(O,function(j){var q=f[j];u[j]=q,N&&(u.prototype[j]=function(){var Z=this.__chain__;if(M||Z){var Q=u(this.__wrapped__),ne=Q.__actions__=Qr(this.__actions__);return ne.push({func:q,args:arguments,thisArg:u}),Q.__chain__=Z,Q}return q.apply(u,Zi([this.value()],arguments))})}),u}function Y$(){return Dr._===this&&(Dr._=TN),this}function dp(){}function Z$(u){return u=ze(u),tt(function(f){return ux(f,u)})}var J$=Hh(Yt),Q$=Hh(I_),eU=Hh(hh);function Ow(u){return Xh(u)?ph(Xn(u)):DF(u)}function tU(u){return function(f){return u==null?r:ja(u,f)}}var rU=Rx(),nU=Rx(!0);function hp(){return[]}function pp(){return!1}function iU(){return{}}function aU(){return""}function sU(){return!0}function oU(u,f){if(u=ze(u),u<1||u>ae)return[];var p=ve,_=Nr(u,ve);f=Me(f),u-=ve;for(var O=vh(_,f);++p<u;)f(p);return O}function uU(u){return Be(u)?Yt(u,Xn):yn(u)?[u]:Qr(Vx(Pt(u)))}function lU(u){var f=++xN;return Pt(u)+f}var cU=Fl(function(u,f){return u+f},0),fU=Wh("ceil"),dU=Fl(function(u,f){return u/f},1),hU=Wh("floor");function pU(u){return u&&u.length?Il(u,rn,Ah):r}function gU(u,f){return u&&u.length?Il(u,Me(f,2),Ah):r}function mU(u){return M_(u,rn)}function vU(u,f){return M_(u,Me(f,2))}function yU(u){return u&&u.length?Il(u,rn,Mh):r}function bU(u,f){return u&&u.length?Il(u,Me(f,2),Mh):r}var _U=Fl(function(u,f){return u*f},1),xU=Wh("round"),wU=Fl(function(u,f){return u-f},0);function TU(u){return u&&u.length?mh(u,rn):0}function SU(u,f){return u&&u.length?mh(u,Me(f,2)):0}return R.after=Gk,R.ary=nw,R.assign=Lj,R.assignIn=vw,R.assignInWith=yw,R.assignWith=ap,R.at=Nj,R.before=iw,R.bind=tp,R.bindAll=U$,R.bindKey=aw,R.castArray=aj,R.chain=ew,R.chunk=p2,R.compact=g2,R.concat=m2,R.cond=q$,R.conforms=H$,R.constant=lp,R.countBy=Sk,R.create=Fj,R.curry=sw,R.curryRight=ow,R.debounce=uw,R.defaults=kj,R.defaultsDeep=jj,R.defer=Kk,R.delay=Xk,R.difference=v2,R.differenceBy=y2,R.differenceWith=b2,R.drop=_2,R.dropRight=x2,R.dropRightWhile=w2,R.dropWhile=T2,R.fill=S2,R.filter=Ek,R.flatMap=Ik,R.flatMapDeep=Rk,R.flatMapDepth=Dk,R.flatten=Yx,R.flattenDeep=C2,R.flattenDepth=E2,R.flip=Yk,R.flow=B$,R.flowRight=z$,R.fromPairs=O2,R.functions=zj,R.functionsIn=Vj,R.groupBy=Mk,R.initial=I2,R.intersection=R2,R.intersectionBy=D2,R.intersectionWith=M2,R.invert=Kj,R.invertBy=Xj,R.invokeMap=Lk,R.iteratee=cp,R.keyBy=Nk,R.keys=Sr,R.keysIn=tn,R.map=Wl,R.mapKeys=Zj,R.mapValues=Jj,R.matches=V$,R.matchesProperty=G$,R.memoize=zl,R.merge=Qj,R.mergeWith=bw,R.method=K$,R.methodOf=X$,R.mixin=fp,R.negate=Vl,R.nthArg=Z$,R.omit=e$,R.omitBy=t$,R.once=Zk,R.orderBy=Fk,R.over=J$,R.overArgs=Jk,R.overEvery=Q$,R.overSome=eU,R.partial=rp,R.partialRight=lw,R.partition=kk,R.pick=r$,R.pickBy=_w,R.property=Ow,R.propertyOf=tU,R.pull=F2,R.pullAll=Jx,R.pullAllBy=k2,R.pullAllWith=j2,R.pullAt=$2,R.range=rU,R.rangeRight=nU,R.rearg=Qk,R.reject=Uk,R.remove=U2,R.rest=ej,R.reverse=Qh,R.sampleSize=Hk,R.set=i$,R.setWith=a$,R.shuffle=Wk,R.slice=q2,R.sortBy=Vk,R.sortedUniq=K2,R.sortedUniqBy=X2,R.split=A$,R.spread=tj,R.tail=Y2,R.take=Z2,R.takeRight=J2,R.takeRightWhile=Q2,R.takeWhile=ek,R.tap=gk,R.throttle=rj,R.thru=Hl,R.toArray=pw,R.toPairs=xw,R.toPairsIn=ww,R.toPath=uU,R.toPlainObject=mw,R.transform=s$,R.unary=nj,R.union=tk,R.unionBy=rk,R.unionWith=nk,R.uniq=ik,R.uniqBy=ak,R.uniqWith=sk,R.unset=o$,R.unzip=ep,R.unzipWith=Qx,R.update=u$,R.updateWith=l$,R.values=Hs,R.valuesIn=c$,R.without=ok,R.words=Cw,R.wrap=ij,R.xor=uk,R.xorBy=lk,R.xorWith=ck,R.zip=fk,R.zipObject=dk,R.zipObjectDeep=hk,R.zipWith=pk,R.entries=xw,R.entriesIn=ww,R.extend=vw,R.extendWith=yw,fp(R,R),R.add=cU,R.attempt=Ew,R.camelCase=p$,R.capitalize=Tw,R.ceil=fU,R.clamp=f$,R.clone=sj,R.cloneDeep=uj,R.cloneDeepWith=lj,R.cloneWith=oj,R.conformsTo=cj,R.deburr=Sw,R.defaultTo=W$,R.divide=dU,R.endsWith=g$,R.eq=Yn,R.escape=m$,R.escapeRegExp=v$,R.every=Ck,R.find=Ok,R.findIndex=Kx,R.findKey=$j,R.findLast=Ak,R.findLastIndex=Xx,R.findLastKey=Uj,R.floor=hU,R.forEach=tw,R.forEachRight=rw,R.forIn=qj,R.forInRight=Hj,R.forOwn=Wj,R.forOwnRight=Bj,R.get=sp,R.gt=fj,R.gte=dj,R.has=Gj,R.hasIn=op,R.head=Zx,R.identity=rn,R.includes=Pk,R.indexOf=A2,R.inRange=d$,R.invoke=Yj,R.isArguments=qa,R.isArray=Be,R.isArrayBuffer=hj,R.isArrayLike=en,R.isArrayLikeObject=dr,R.isBoolean=pj,R.isBuffer=ia,R.isDate=gj,R.isElement=mj,R.isEmpty=vj,R.isEqual=yj,R.isEqualWith=bj,R.isError=np,R.isFinite=_j,R.isFunction=Oi,R.isInteger=cw,R.isLength=Gl,R.isMap=fw,R.isMatch=xj,R.isMatchWith=wj,R.isNaN=Tj,R.isNative=Sj,R.isNil=Ej,R.isNull=Cj,R.isNumber=dw,R.isObject=tr,R.isObjectLike=sr,R.isPlainObject=Go,R.isRegExp=ip,R.isSafeInteger=Oj,R.isSet=hw,R.isString=Kl,R.isSymbol=yn,R.isTypedArray=qs,R.isUndefined=Aj,R.isWeakMap=Ij,R.isWeakSet=Rj,R.join=P2,R.kebabCase=y$,R.last=Nn,R.lastIndexOf=L2,R.lowerCase=b$,R.lowerFirst=_$,R.lt=Dj,R.lte=Mj,R.max=pU,R.maxBy=gU,R.mean=mU,R.meanBy=vU,R.min=yU,R.minBy=bU,R.stubArray=hp,R.stubFalse=pp,R.stubObject=iU,R.stubString=aU,R.stubTrue=sU,R.multiply=_U,R.nth=N2,R.noConflict=Y$,R.noop=dp,R.now=Bl,R.pad=x$,R.padEnd=w$,R.padStart=T$,R.parseInt=S$,R.random=h$,R.reduce=jk,R.reduceRight=$k,R.repeat=C$,R.replace=E$,R.result=n$,R.round=xU,R.runInContext=$,R.sample=qk,R.size=Bk,R.snakeCase=O$,R.some=zk,R.sortedIndex=H2,R.sortedIndexBy=W2,R.sortedIndexOf=B2,R.sortedLastIndex=z2,R.sortedLastIndexBy=V2,R.sortedLastIndexOf=G2,R.startCase=I$,R.startsWith=R$,R.subtract=wU,R.sum=TU,R.sumBy=SU,R.template=D$,R.times=oU,R.toFinite=Ai,R.toInteger=ze,R.toLength=gw,R.toLower=M$,R.toNumber=Fn,R.toSafeInteger=Pj,R.toString=Pt,R.toUpper=P$,R.trim=L$,R.trimEnd=N$,R.trimStart=F$,R.truncate=k$,R.unescape=j$,R.uniqueId=lU,R.upperCase=$$,R.upperFirst=up,R.each=tw,R.eachRight=rw,R.first=Zx,fp(R,(function(){var u={};return ai(R,function(f,p){Mt.call(R.prototype,p)||(u[p]=f)}),u})(),{chain:!1}),R.VERSION=n,gn(["bind","bindKey","curry","curryRight","partial","partialRight"],function(u){R[u].placeholder=R}),gn(["drop","take"],function(u,f){pt.prototype[u]=function(p){p=p===r?1:xr(ze(p),0);var _=this.__filtered__&&!f?new pt(this):this.clone();return _.__filtered__?_.__takeCount__=Nr(p,_.__takeCount__):_.__views__.push({size:Nr(p,ve),type:u+(_.__dir__<0?"Right":"")}),_},pt.prototype[u+"Right"]=function(p){return this.reverse()[u](p).reverse()}}),gn(["filter","map","takeWhile"],function(u,f){var p=f+1,_=p==J||p==ce;pt.prototype[u]=function(O){var M=this.clone();return M.__iteratees__.push({iteratee:Me(O,3),type:p}),M.__filtered__=M.__filtered__||_,M}}),gn(["head","last"],function(u,f){var p="take"+(f?"Right":"");pt.prototype[u]=function(){return this[p](1).value()[0]}}),gn(["initial","tail"],function(u,f){var p="drop"+(f?"":"Right");pt.prototype[u]=function(){return this.__filtered__?new pt(this):this[p](1)}}),pt.prototype.compact=function(){return this.filter(rn)},pt.prototype.find=function(u){return this.filter(u).head()},pt.prototype.findLast=function(u){return this.reverse().find(u)},pt.prototype.invokeMap=tt(function(u,f){return typeof u=="function"?new pt(this):this.map(function(p){return qo(p,u,f)})}),pt.prototype.reject=function(u){return this.filter(Vl(Me(u)))},pt.prototype.slice=function(u,f){u=ze(u);var p=this;return p.__filtered__&&(u>0||f<0)?new pt(p):(u<0?p=p.takeRight(-u):u&&(p=p.drop(u)),f!==r&&(f=ze(f),p=f<0?p.dropRight(-f):p.take(f-u)),p)},pt.prototype.takeRightWhile=function(u){return this.reverse().takeWhile(u).reverse()},pt.prototype.toArray=function(){return this.take(ve)},ai(pt.prototype,function(u,f){var p=/^(?:filter|find|map|reject)|While$/.test(f),_=/^(?:head|last)$/.test(f),O=R[_?"take"+(f=="last"?"Right":""):f],M=_||/^find/.test(f);O&&(R.prototype[f]=function(){var N=this.__wrapped__,j=_?[1]:arguments,q=N instanceof pt,Z=j[0],Q=q||Be(N),ne=function(dt){var vt=O.apply(R,Zi([dt],j));return _&&le?vt[0]:vt};Q&&p&&typeof Z=="function"&&Z.length!=1&&(q=Q=!1);var le=this.__chain__,Te=!!this.__actions__.length,Pe=M&&!le,Ke=q&&!Te;if(!M&&Q){N=Ke?N:new pt(this);var Ie=u.apply(N,j);return Ie.__actions__.push({func:Hl,args:[ne],thisArg:r}),new Mn(Ie,le)}return Pe&&Ke?u.apply(this,j):(Ie=this.thru(ne),Pe?_?Ie.value()[0]:Ie.value():Ie)})}),gn(["pop","push","shift","sort","splice","unshift"],function(u){var f=pl[u],p=/^(?:push|sort|unshift)$/.test(u)?"tap":"thru",_=/^(?:pop|shift)$/.test(u);R.prototype[u]=function(){var O=arguments;if(_&&!this.__chain__){var M=this.value();return f.apply(Be(M)?M:[],O)}return this[p](function(N){return f.apply(Be(N)?N:[],O)})}}),ai(pt.prototype,function(u,f){var p=R[f];if(p){var _=p.name+"";Mt.call(Fs,_)||(Fs[_]=[]),Fs[_].push({name:f,func:p})}}),Fs[Nl(r,w).name]=[{name:"wrapper",func:r}],pt.prototype.clone=$N,pt.prototype.reverse=UN,pt.prototype.value=qN,R.prototype.at=mk,R.prototype.chain=vk,R.prototype.commit=yk,R.prototype.next=bk,R.prototype.plant=xk,R.prototype.reverse=wk,R.prototype.toJSON=R.prototype.valueOf=R.prototype.value=Tk,R.prototype.first=R.prototype.head,Lo&&(R.prototype[Lo]=_k),R}),Ps=yN();Pa?((Pa.exports=Ps)._=Ps,lh._=Ps):Dr._=Ps}).call(Pz)})(gu,gu.exports)),gu.exports}var mr=Lz();const Ea={appearance:"none",border:0,margin:0,padding:0,background:"none",color:"inherit",font:"inherit",textAlign:"inherit",cursor:"pointer"};Object.entries(Ea).map(([t,e])=>`${mr.kebabCase(t)}: ${e};`).join(`
|
|
69
|
+
`);const Nz={critical:["clr-critical","#db0028"],primary:["clr-primary","#1456e0"],warning:["clr-warning","#ff9800"],success:["clr-success","#4caf50"],info:["clr-info","#2196f3"],onSurface:["clr-on-surface","#092241"],onSurfaceVariant:["clr-on-surface-variant","#092241b3"],onPrimary:["clr-on-primary","#ffffff"],outline:["clr-outline","#0922411f"],outlineVariant:["clr-outline-variant","#09224114"]},Fz={surface:"#ffffff",pointBorder:"#5585ff"},V0=Object.entries(Nz),YR=Object.entries(Fz),Tn={...Object.fromEntries(V0.map(([t,[,e]])=>[t,e])),...Object.fromEntries(YR)};Object.fromEntries(V0.map(([t,[e]])=>[t,e]));const Ye={...Object.fromEntries(V0.map(([t,[e,r]])=>[t,`var(--${e}, ${r})`])),...Object.fromEntries(YR)},Tu="'Open Sans', sans-serif",Wf={family:Tu,size:12},Bf={caption:{fontFamily:Tu,fontSize:"12px",fontWeight:400,lineHeight:"16px"},small:{fontFamily:Tu,fontSize:"14px",fontWeight:400,lineHeight:"20px"},smallBold:{fontFamily:Tu,fontSize:"14px",fontWeight:700,lineHeight:"20px"}},ZR=72,w1={color:"initial",fontFamily:"var(--root-secondary-font, 'Red Hat Display', sans-serif)",fontSize:20,fontWeight:700,letterSpacing:"0.15px",lineHeight:"24px",margin:0,padding:24},kz={margin:0,whiteSpace:"nowrap"},jz={...Ea,alignItems:"center",borderRadius:100,boxSizing:"border-box",color:Ye.primary,display:"inline-flex",fontFamily:"var(--root-secondary-font, 'Red Hat Display', sans-serif)",fontSize:14,fontWeight:700,justifyContent:"center",minHeight:36,minWidth:64,padding:"8.5px 20px",textTransform:"uppercase",whiteSpace:"nowrap"},$z=({children:t,disabled:e,style:r,type:n="button",...i})=>A.jsx("button",{type:n,disabled:e,style:{...jz,...e?{color:"rgba(0, 0, 0, 0.26)",cursor:"default"}:null,...r},...i,children:t}),Uz=({children:t,style:e,...r})=>A.jsx("div",{role:"dialog","aria-modal":"true",style:{backgroundColor:Ye.surface,boxSizing:"border-box",color:Ye.onSurface,inset:0,overflowY:"auto",paddingTop:ZR,position:"fixed",zIndex:1300,...e},...r,children:t}),qz=({children:t,style:e,...r})=>A.jsx("div",{style:{alignItems:"center",backgroundColor:Ye.surface,boxSizing:"border-box",display:"flex",height:ZR,justifyContent:"space-between",left:0,paddingRight:16,position:"fixed",right:0,top:0,zIndex:1,...e},...r,children:t}),T1=({isFullScreen:t,children:e,style:r,...n})=>A.jsx("div",{style:{overflow:"hidden",padding:t?"8px 16px 16px":"8px 24px 20px",...r},...n,children:e}),Hz=({children:t,style:e,...r})=>A.jsx("div",{style:{alignItems:"center",display:"flex",flexWrap:"wrap",gap:0,justifyContent:"flex-end",padding:"8px 15px 8px 20px",...e},...r,children:t}),Wz=t=>{ut(()=>{if(!t)return;const e=document.body.style.overflow;return document.body.style.overflow="hidden",()=>{document.body.style.overflow=e}},[t])},G0=({title:t,actions:e,children:r,open:n,fullScreen:i,fullWidth:a})=>{const o=Ve(Et("sm"))&&!!(i||a);return Wz(n&&o),o?n?A.jsxs(Uz,{"data-testid":"fullscreen-dialog","aria-labelledby":"dialog-title",children:[A.jsx(qz,{"data-part":"top-bar",children:e==null?void 0:e.map(l=>A.jsx($z,{onClick:l.trigger,type:l.type,disabled:l.disabled,children:l.mobileLabel},`${l.label}-${l.type}`))}),A.jsx("h2",{id:"dialog-title","data-part":"title",style:w1,children:t}),!!r&&A.jsx(T1,{"data-part":"content",isFullScreen:!0,children:r})]}):null:A.jsxs(uW,{open:n,preventCancel:!0,preventCloseOnScrimClick:!0,"aria-labelledby":"dialog-title",style:{"--md-dialog-container-shape":"12px"},children:[A.jsx("h2",{slot:"headline",id:"dialog-title",style:w1,children:t}),!!r&&A.jsx(T1,{slot:"content",isFullScreen:!1,children:r}),A.jsx(Hz,{slot:"actions",children:e==null?void 0:e.map(l=>A.jsx(xd,{appearance:"text",onClick:l.trigger,type:l.type,disabled:l.disabled,submitting:l.loading,style:kz,children:l.label},`${l.label}-${l.type}`))})]})},Bz=t=>t.name,zz=t=>t.id,K0=({options:t=[],value:e,onChange:r,label:n,ariaLabel:i,name:a,trailingIcon:s,style:o,getOptionLabel:l=Bz,getOptionValue:c=zz,getOptionDisabled:d})=>{const h=String(e??"");return A.jsx(vW,{"aria-label":i,label:n,menuPositioning:"fixed",name:a,onSelectInput:g=>r(g.target.value),style:o,trailingIcon:s,children:t.map(g=>{const m=String(c(g));return A.jsx(yW,{disabled:d==null?void 0:d(g),selected:m===h,value:m,children:A.jsx("div",{slot:"headline",children:l(g)})},m)})})};function Vz(){if(console&&console.warn){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];as(e[0])&&(e[0]=`react-i18next:: ${e[0]}`),console.warn(...e)}}const S1={};function ky(){for(var t=arguments.length,e=new Array(t),r=0;r<t;r++)e[r]=arguments[r];as(e[0])&&S1[e[0]]||(as(e[0])&&(S1[e[0]]=new Date),Vz(...e))}const JR=(t,e)=>()=>{if(t.isInitialized)e();else{const r=()=>{setTimeout(()=>{t.off("initialized",r)},0),e()};t.on("initialized",r)}},C1=(t,e,r)=>{t.loadNamespaces(e,JR(t,r))},E1=(t,e,r,n)=>{as(r)&&(r=[r]),r.forEach(i=>{t.options.ns.indexOf(i)<0&&t.options.ns.push(i)}),t.loadLanguages(e,JR(t,n))},Gz=function(t,e){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};const n=e.languages[0],i=e.options?e.options.fallbackLng:!1,a=e.languages[e.languages.length-1];if(n.toLowerCase()==="cimode")return!0;const s=(o,l)=>{const c=e.services.backendConnector.state[`${o}|${l}`];return c===-1||c===2};return r.bindI18n&&r.bindI18n.indexOf("languageChanging")>-1&&e.services.backendConnector.backend&&e.isLanguageChangingTo&&!s(e.isLanguageChangingTo,t)?!1:!!(e.hasResourceBundle(n,t)||!e.services.backendConnector.backend||e.options.resources&&!e.options.partialBundledLanguages||s(n,t)&&(!i||s(a,t)))},Kz=function(t,e){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return!e.languages||!e.languages.length?(ky("i18n.languages were undefined or empty",e.languages),!0):e.options.ignoreJSONStructure!==void 0?e.hasLoadedNamespace(t,{lng:r.lng,precheck:(i,a)=>{if(r.bindI18n&&r.bindI18n.indexOf("languageChanging")>-1&&i.services.backendConnector.backend&&i.isLanguageChangingTo&&!a(i.isLanguageChangingTo,t))return!1}}):Gz(t,e,r)},as=t=>typeof t=="string",Xz=t=>typeof t=="object"&&t!==null,Yz=/&(?:amp|#38|lt|#60|gt|#62|apos|#39|quot|#34|nbsp|#160|copy|#169|reg|#174|hellip|#8230|#x2F|#47);/g,Zz={"&":"&","&":"&","<":"<","<":"<",">":">",">":">","'":"'","'":"'",""":'"',""":'"'," ":" "," ":" ","©":"©","©":"©","®":"®","®":"®","…":"…","…":"…","/":"/","/":"/"},Jz=t=>Zz[t],Qz=t=>t.replace(Yz,Jz);let jy={bindI18n:"languageChanged",bindI18nStore:"",transEmptyNodeValue:"",transSupportBasicHtmlNodes:!0,transWrapTextNodes:"",transKeepBasicHtmlNodesFor:["br","strong","i","p"],useSuspense:!0,unescape:Qz};const eV=function(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};jy={...jy,...t}},tV=()=>jy;let QR;const rV=t=>{QR=t},nV=()=>QR,iV={type:"3rdParty",init(t){eV(t.options.react),rV(t)}},aV=md();class sV{constructor(){qe(this,"getUsedNamespaces",()=>Object.keys(this.usedNamespaces));this.usedNamespaces={}}addUsedNamespaces(e){e.forEach(r=>{this.usedNamespaces[r]||(this.usedNamespaces[r]=!0)})}}const oV=(t,e)=>{const r=$t();return ut(()=>{r.current=t},[t,e]),r.current},eD=(t,e,r,n)=>t.getFixedT(e,r,n),uV=(t,e,r,n)=>rt(eD(t,e,r,n),[t,e,r,n]),Qt=function(t){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};const{i18n:r}=e,{i18n:n,defaultNS:i}=zu(aV)||{},a=r||n||nV();if(a&&!a.reportNamespaces&&(a.reportNamespaces=new sV),!a){ky("You will need to pass in an i18next instance by using initReactI18next");const E=(I,T)=>as(T)?T:Xz(T)&&as(T.defaultValue)?T.defaultValue:Array.isArray(I)?I[I.length-1]:I,C=[E,{},!1];return C.t=E,C.i18n={},C.ready=!1,C}a.options.react&&a.options.react.wait!==void 0&&ky("It seems you are still using the old wait option, you may migrate to the new useSuspense behaviour.");const s={...tV(),...a.options.react,...e},{useSuspense:o,keyPrefix:l}=s;let c=t||i||a.options&&a.options.defaultNS;c=as(c)?[c]:c||["translation"],a.reportNamespaces.addUsedNamespaces&&a.reportNamespaces.addUsedNamespaces(c);const d=(a.isInitialized||a.initializedStoreOnce)&&c.every(E=>Kz(E,a,s)),h=uV(a,e.lng||null,s.nsMode==="fallback"?c:c[0],l),g=()=>h,m=()=>eD(a,e.lng||null,s.nsMode==="fallback"?c:c[0],l),[v,b]=or(g);let y=c.join();e.lng&&(y=`${e.lng}${y}`);const x=oV(y),w=$t(!0);ut(()=>{const{bindI18n:E,bindI18nStore:C}=s;w.current=!0,!d&&!o&&(e.lng?E1(a,e.lng,c,()=>{w.current&&b(m)}):C1(a,c,()=>{w.current&&b(m)})),d&&x&&x!==y&&w.current&&b(m);const I=()=>{w.current&&b(m)};return E&&a&&a.on(E,I),C&&a&&a.store.on(C,I),()=>{w.current=!1,E&&a&&E.split(" ").forEach(T=>a.off(T,I)),C&&a&&C.split(" ").forEach(T=>a.store.off(T,I))}},[a,y]),ut(()=>{w.current&&d&&b(g)},[a,l,d]);const S=[v,a,d];if(S.t=v,S.i18n=a,S.ready=d,d||!d&&!o)return S;throw new Promise(E=>{e.lng?E1(a,e.lng,c,()=>E()):C1(a,c,()=>E())})},lV={h1:{token:"page-title",element:"h1"},h2:{token:"page-title",element:"h2"},h3:{token:"page-title",element:"h3"},h4:{token:"page-title",element:"h4"},h5:{token:"heading",element:"h5"},h6:{token:"heading",element:"h6"},subtitle1:{token:"default",element:"p"},subtitle2:{token:"small",element:"p",weight:"bold"},body1:{token:"default",element:"p"},body2:{token:"small",element:"p"},button:{token:"button",element:"span"},caption:{token:"caption",element:"span"},overline:{token:"caption",element:"span"}},cV=t=>({margin:0,fontFamily:`var(--text-${t}-font)`,fontSize:`var(--text-${t}-size)`,fontWeight:`var(--text-${t}-weight)`,lineHeight:`var(--text-${t}-line-height)`,letterSpacing:`var(--text-${t}-letter-spacing)`,textTransform:`var(--text-${t}-transform)`,textDecoration:`var(--text-${t}-decoration)`}),lt=({variant:t="body1",component:e,align:r,noWrap:n,gutterBottom:i,className:a,style:s,children:o,...l})=>{const{token:c,element:d,weight:h}=lV[t],g=e??d,m={...cV(c),...h?{fontWeight:h}:null,...r?{textAlign:r}:null,...n?{whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis"}:null,...i?{marginBottom:"0.35em"}:null,...s};return A.jsx(g,{className:a,style:m,...l,children:o})},X0=({children:t,style:e,...r})=>A.jsx("div",{style:{display:"flex",flexDirection:"column",alignItems:"center",gap:8,padding:24,...e},...r,children:t}),fV=({$direction:t,children:e,style:r,...n})=>A.jsx("div",{style:{display:"flex",alignItems:"center",gap:16,flexDirection:t==="vertical"?"column":"row",...t==="vertical"?{textAlign:"center"}:null,...r},...n,children:e}),dV=()=>A.jsx(Hi,{filled:!0,style:{"--ix-icon-font-size":"24px",color:"var(--clr-critical, #db0028)"},children:"error"}),hV=({$direction:t,children:e,style:r,...n})=>A.jsx("div",{style:{display:"flex",flexDirection:"column",gap:8,...t==="vertical"?{textAlign:"center"}:null,...r},...n,children:e}),pV=({error:t,title:e,message:r,direction:n="horizontal"})=>{const{t:i}=Qt("common");return A.jsxs(fV,{$direction:n,"data-testid":"common-error-msg",children:[A.jsx(dV,{}),A.jsxs(hV,{$direction:n,children:[A.jsx(lt,{variant:"subtitle1","data-testid":"common-error-msg-title",component:"p",children:e||i("error-title")}),A.jsx(lt,{variant:"body2","data-testid":"common-error-msg-description",children:(t==null?void 0:t.message)||r||i("error-message")})]})]})},gV=()=>A.jsx(X0,{children:A.jsx(pV,{direction:"vertical"})});class $ae extends OU{constructor(e){super(e),this.state={hasError:!1}}static getDerivedStateFromError(e){return{hasError:!0}}componentDidCatch(e){console.error("Client side error",{error:e})}render(){return this.state.hasError?A.jsx(gV,{}):this.props.children}}const mV={display:"flex",flexDirection:"column",height:"100%",justifyContent:"flex-start",overflowY:"auto",width:"100%"},vV=({children:t,style:e,...r})=>A.jsx("div",{style:{...mV,...e},...r,children:t}),Y0=({children:t,className:e})=>A.jsx(vV,{className:e,children:t}),yV=({children:t,onClose:e,open:r})=>{const n=Ve(Et("md")),i=$t(null);return ut(()=>{var a;(a=i.current)==null||a.toggleAttribute("isvisible",r)},[r]),ut(()=>{if(!r)return;const a=s=>{s.key==="Escape"&&e()};return document.addEventListener("keydown",a),()=>document.removeEventListener("keydown",a)},[r,e]),A.jsx(dW,{ref:i,isVisible:r,onClosed:e,compact:!0,hideClose:!0,style:{"--ix-drawer-padding":"0","--ix-drawer-width-md":n?"100vw":"816px","--ix-drawer-width-lg":"816px","--ix-drawer-border-radius":n?"0":"16px 0 0 16px"},children:A.jsx("div",{slot:"content",children:t})})},bV={display:"flex",alignItems:"center",justifyContent:"center"},_V=({linear:t})=>t?A.jsx(Ff,{indeterminate:!0,role:"progressbar","aria-label":"Loading...","aria-busy":"true","data-testid":"linear-progress"}):A.jsx("div",{style:bV,children:A.jsx(Ff,{linear:!1,indeterminate:!0,style:{"--md-circular-progress-size":"40px"},role:"progressbar","aria-label":"Loading...","aria-busy":"true","data-testid":"circular-progress"})}),xV=()=>{const[t,e]=or([]);return{closeDialog:()=>{e(i=>(i.pop(),[...i]))},createDialog:(i,a)=>{const s={...i,open:!0,key:mr.uniqueId("dialog_")};e(a?()=>[s]:o=>[...o,s])},dialogs:t}},tD=md([]);function Uae({children:t}){const{closeDialog:e,createDialog:r,dialogs:n}=xV(),i=$t([r,e]);return A.jsxs(tD.Provider,{value:i.current,children:[t,n.map(a=>A.jsx(AU,{children:a},a.key))]})}function rD(){const t=zu(tD);if(!t)throw new Error("Dialog context is only available inside its provider");return t}const $e=t=>typeof t=="string",ru=()=>{let t,e;const r=new Promise((n,i)=>{t=n,e=i});return r.resolve=t,r.reject=e,r},O1=t=>t==null?"":""+t,wV=(t,e,r)=>{t.forEach(n=>{e[n]&&(r[n]=e[n])})},TV=/###/g,A1=t=>t&&t.indexOf("###")>-1?t.replace(TV,"."):t,I1=t=>!t||$e(t),Su=(t,e,r)=>{const n=$e(e)?e.split("."):e;let i=0;for(;i<n.length-1;){if(I1(t))return{};const a=A1(n[i]);!t[a]&&r&&(t[a]=new r),Object.prototype.hasOwnProperty.call(t,a)?t=t[a]:t={},++i}return I1(t)?{}:{obj:t,k:A1(n[i])}},R1=(t,e,r)=>{const{obj:n,k:i}=Su(t,e,Object);if(n!==void 0||e.length===1){n[i]=r;return}let a=e[e.length-1],s=e.slice(0,e.length-1),o=Su(t,s,Object);for(;o.obj===void 0&&s.length;)a=`${s[s.length-1]}.${a}`,s=s.slice(0,s.length-1),o=Su(t,s,Object),o&&o.obj&&typeof o.obj[`${o.k}.${a}`]<"u"&&(o.obj=void 0);o.obj[`${o.k}.${a}`]=r},SV=(t,e,r,n)=>{const{obj:i,k:a}=Su(t,e,Object);i[a]=i[a]||[],i[a].push(r)},zf=(t,e)=>{const{obj:r,k:n}=Su(t,e);if(r)return r[n]},CV=(t,e,r)=>{const n=zf(t,r);return n!==void 0?n:zf(e,r)},nD=(t,e,r)=>{for(const n in e)n!=="__proto__"&&n!=="constructor"&&(n in t?$e(t[n])||t[n]instanceof String||$e(e[n])||e[n]instanceof String?r&&(t[n]=e[n]):nD(t[n],e[n],r):t[n]=e[n]);return t},zs=t=>t.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&");var EV={"&":"&","<":"<",">":">",'"':""","'":"'","/":"/"};const OV=t=>$e(t)?t.replace(/[&<>"'\/]/g,e=>EV[e]):t;class AV{constructor(e){this.capacity=e,this.regExpMap=new Map,this.regExpQueue=[]}getRegExp(e){const r=this.regExpMap.get(e);if(r!==void 0)return r;const n=new RegExp(e);return this.regExpQueue.length===this.capacity&&this.regExpMap.delete(this.regExpQueue.shift()),this.regExpMap.set(e,n),this.regExpQueue.push(e),n}}const IV=[" ",",","?","!",";"],RV=new AV(20),DV=(t,e,r)=>{e=e||"",r=r||"";const n=IV.filter(s=>e.indexOf(s)<0&&r.indexOf(s)<0);if(n.length===0)return!0;const i=RV.getRegExp(`(${n.map(s=>s==="?"?"\\?":s).join("|")})`);let a=!i.test(t);if(!a){const s=t.indexOf(r);s>0&&!i.test(t.substring(0,s))&&(a=!0)}return a},$y=function(t,e){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:".";if(!t)return;if(t[e])return t[e];const n=e.split(r);let i=t;for(let a=0;a<n.length;){if(!i||typeof i!="object")return;let s,o="";for(let l=a;l<n.length;++l)if(l!==a&&(o+=r),o+=n[l],s=i[o],s!==void 0){if(["string","number","boolean"].indexOf(typeof s)>-1&&l<n.length-1)continue;a+=l-a+1;break}i=s}return i},Vf=t=>t&&t.replace("_","-"),MV={type:"logger",log(t){this.output("log",t)},warn(t){this.output("warn",t)},error(t){this.output("error",t)},output(t,e){console&&console[t]&&console[t].apply(console,e)}};class Gf{constructor(e){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.init(e,r)}init(e){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.prefix=r.prefix||"i18next:",this.logger=e||MV,this.options=r,this.debug=r.debug}log(){for(var e=arguments.length,r=new Array(e),n=0;n<e;n++)r[n]=arguments[n];return this.forward(r,"log","",!0)}warn(){for(var e=arguments.length,r=new Array(e),n=0;n<e;n++)r[n]=arguments[n];return this.forward(r,"warn","",!0)}error(){for(var e=arguments.length,r=new Array(e),n=0;n<e;n++)r[n]=arguments[n];return this.forward(r,"error","")}deprecate(){for(var e=arguments.length,r=new Array(e),n=0;n<e;n++)r[n]=arguments[n];return this.forward(r,"warn","WARNING DEPRECATED: ",!0)}forward(e,r,n,i){return i&&!this.debug?null:($e(e[0])&&(e[0]=`${n}${this.prefix} ${e[0]}`),this.logger[r](e))}create(e){return new Gf(this.logger,{prefix:`${this.prefix}:${e}:`,...this.options})}clone(e){return e=e||this.options,e.prefix=e.prefix||this.prefix,new Gf(this.logger,e)}}var gi=new Gf;class Rd{constructor(){this.observers={}}on(e,r){return e.split(" ").forEach(n=>{this.observers[n]||(this.observers[n]=new Map);const i=this.observers[n].get(r)||0;this.observers[n].set(r,i+1)}),this}off(e,r){if(this.observers[e]){if(!r){delete this.observers[e];return}this.observers[e].delete(r)}}emit(e){for(var r=arguments.length,n=new Array(r>1?r-1:0),i=1;i<r;i++)n[i-1]=arguments[i];this.observers[e]&&Array.from(this.observers[e].entries()).forEach(s=>{let[o,l]=s;for(let c=0;c<l;c++)o(...n)}),this.observers["*"]&&Array.from(this.observers["*"].entries()).forEach(s=>{let[o,l]=s;for(let c=0;c<l;c++)o.apply(o,[e,...n])})}}class D1 extends Rd{constructor(e){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{ns:["translation"],defaultNS:"translation"};super(),this.data=e||{},this.options=r,this.options.keySeparator===void 0&&(this.options.keySeparator="."),this.options.ignoreJSONStructure===void 0&&(this.options.ignoreJSONStructure=!0)}addNamespaces(e){this.options.ns.indexOf(e)<0&&this.options.ns.push(e)}removeNamespaces(e){const r=this.options.ns.indexOf(e);r>-1&&this.options.ns.splice(r,1)}getResource(e,r,n){let i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};const a=i.keySeparator!==void 0?i.keySeparator:this.options.keySeparator,s=i.ignoreJSONStructure!==void 0?i.ignoreJSONStructure:this.options.ignoreJSONStructure;let o;e.indexOf(".")>-1?o=e.split("."):(o=[e,r],n&&(Array.isArray(n)?o.push(...n):$e(n)&&a?o.push(...n.split(a)):o.push(n)));const l=zf(this.data,o);return!l&&!r&&!n&&e.indexOf(".")>-1&&(e=o[0],r=o[1],n=o.slice(2).join(".")),l||!s||!$e(n)?l:$y(this.data&&this.data[e]&&this.data[e][r],n,a)}addResource(e,r,n,i){let a=arguments.length>4&&arguments[4]!==void 0?arguments[4]:{silent:!1};const s=a.keySeparator!==void 0?a.keySeparator:this.options.keySeparator;let o=[e,r];n&&(o=o.concat(s?n.split(s):n)),e.indexOf(".")>-1&&(o=e.split("."),i=r,r=o[1]),this.addNamespaces(r),R1(this.data,o,i),a.silent||this.emit("added",e,r,n,i)}addResources(e,r,n){let i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{silent:!1};for(const a in n)($e(n[a])||Array.isArray(n[a]))&&this.addResource(e,r,a,n[a],{silent:!0});i.silent||this.emit("added",e,r,n)}addResourceBundle(e,r,n,i,a){let s=arguments.length>5&&arguments[5]!==void 0?arguments[5]:{silent:!1,skipCopy:!1},o=[e,r];e.indexOf(".")>-1&&(o=e.split("."),i=n,n=r,r=o[1]),this.addNamespaces(r);let l=zf(this.data,o)||{};s.skipCopy||(n=JSON.parse(JSON.stringify(n))),i?nD(l,n,a):l={...l,...n},R1(this.data,o,l),s.silent||this.emit("added",e,r,n)}removeResourceBundle(e,r){this.hasResourceBundle(e,r)&&delete this.data[e][r],this.removeNamespaces(r),this.emit("removed",e,r)}hasResourceBundle(e,r){return this.getResource(e,r)!==void 0}getResourceBundle(e,r){return r||(r=this.options.defaultNS),this.options.compatibilityAPI==="v1"?{...this.getResource(e,r)}:this.getResource(e,r)}getDataByLanguage(e){return this.data[e]}hasLanguageSomeTranslations(e){const r=this.getDataByLanguage(e);return!!(r&&Object.keys(r)||[]).find(i=>r[i]&&Object.keys(r[i]).length>0)}toJSON(){return this.data}}var iD={processors:{},addPostProcessor(t){this.processors[t.name]=t},handle(t,e,r,n,i){return t.forEach(a=>{this.processors[a]&&(e=this.processors[a].process(e,r,n,i))}),e}};const M1={};class Kf extends Rd{constructor(e){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};super(),wV(["resourceStore","languageUtils","pluralResolver","interpolator","backendConnector","i18nFormat","utils"],e,this),this.options=r,this.options.keySeparator===void 0&&(this.options.keySeparator="."),this.logger=gi.create("translator")}changeLanguage(e){e&&(this.language=e)}exists(e){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{interpolation:{}};if(e==null)return!1;const n=this.resolve(e,r);return n&&n.res!==void 0}extractFromKey(e,r){let n=r.nsSeparator!==void 0?r.nsSeparator:this.options.nsSeparator;n===void 0&&(n=":");const i=r.keySeparator!==void 0?r.keySeparator:this.options.keySeparator;let a=r.ns||this.options.defaultNS||[];const s=n&&e.indexOf(n)>-1,o=!this.options.userDefinedKeySeparator&&!r.keySeparator&&!this.options.userDefinedNsSeparator&&!r.nsSeparator&&!DV(e,n,i);if(s&&!o){const l=e.match(this.interpolator.nestingRegexp);if(l&&l.length>0)return{key:e,namespaces:$e(a)?[a]:a};const c=e.split(n);(n!==i||n===i&&this.options.ns.indexOf(c[0])>-1)&&(a=c.shift()),e=c.join(i)}return{key:e,namespaces:$e(a)?[a]:a}}translate(e,r,n){if(typeof r!="object"&&this.options.overloadTranslationOptionHandler&&(r=this.options.overloadTranslationOptionHandler(arguments)),typeof r=="object"&&(r={...r}),r||(r={}),e==null)return"";Array.isArray(e)||(e=[String(e)]);const i=r.returnDetails!==void 0?r.returnDetails:this.options.returnDetails,a=r.keySeparator!==void 0?r.keySeparator:this.options.keySeparator,{key:s,namespaces:o}=this.extractFromKey(e[e.length-1],r),l=o[o.length-1],c=r.lng||this.language,d=r.appendNamespaceToCIMode||this.options.appendNamespaceToCIMode;if(c&&c.toLowerCase()==="cimode"){if(d){const E=r.nsSeparator||this.options.nsSeparator;return i?{res:`${l}${E}${s}`,usedKey:s,exactUsedKey:s,usedLng:c,usedNS:l,usedParams:this.getUsedParamsDetails(r)}:`${l}${E}${s}`}return i?{res:s,usedKey:s,exactUsedKey:s,usedLng:c,usedNS:l,usedParams:this.getUsedParamsDetails(r)}:s}const h=this.resolve(e,r);let g=h&&h.res;const m=h&&h.usedKey||s,v=h&&h.exactUsedKey||s,b=Object.prototype.toString.apply(g),y=["[object Number]","[object Function]","[object RegExp]"],x=r.joinArrays!==void 0?r.joinArrays:this.options.joinArrays,w=!this.i18nFormat||this.i18nFormat.handleAsObject,S=!$e(g)&&typeof g!="boolean"&&typeof g!="number";if(w&&g&&S&&y.indexOf(b)<0&&!($e(x)&&Array.isArray(g))){if(!r.returnObjects&&!this.options.returnObjects){this.options.returnedObjectHandler||this.logger.warn("accessing an object - but returnObjects options is not enabled!");const E=this.options.returnedObjectHandler?this.options.returnedObjectHandler(m,g,{...r,ns:o}):`key '${s} (${this.language})' returned an object instead of string.`;return i?(h.res=E,h.usedParams=this.getUsedParamsDetails(r),h):E}if(a){const E=Array.isArray(g),C=E?[]:{},I=E?v:m;for(const T in g)if(Object.prototype.hasOwnProperty.call(g,T)){const D=`${I}${a}${T}`;C[T]=this.translate(D,{...r,joinArrays:!1,ns:o}),C[T]===D&&(C[T]=g[T])}g=C}}else if(w&&$e(x)&&Array.isArray(g))g=g.join(x),g&&(g=this.extendTranslation(g,e,r,n));else{let E=!1,C=!1;const I=r.count!==void 0&&!$e(r.count),T=Kf.hasDefaultValue(r),D=I?this.pluralResolver.getSuffix(c,r.count,r):"",P=r.ordinal&&I?this.pluralResolver.getSuffix(c,r.count,{ordinal:!1}):"",L=I&&!r.ordinal&&r.count===0&&this.pluralResolver.shouldUseIntlApi(),F=L&&r[`defaultValue${this.options.pluralSeparator}zero`]||r[`defaultValue${D}`]||r[`defaultValue${P}`]||r.defaultValue;!this.isValidLookup(g)&&T&&(E=!0,g=F),this.isValidLookup(g)||(C=!0,g=s);const X=(r.missingKeyNoValueFallbackToKey||this.options.missingKeyNoValueFallbackToKey)&&C?void 0:g,ee=T&&F!==g&&this.options.updateMissing;if(C||E||ee){if(this.logger.log(ee?"updateKey":"missingKey",c,l,s,ee?F:g),a){const B=this.resolve(s,{...r,keySeparator:!1});B&&B.res&&this.logger.warn("Seems the loaded translations were in flat JSON format instead of nested. Either set keySeparator: false on init or make sure your translations are published in nested format.")}let J=[];const te=this.languageUtils.getFallbackCodes(this.options.fallbackLng,r.lng||this.language);if(this.options.saveMissingTo==="fallback"&&te&&te[0])for(let B=0;B<te.length;B++)J.push(te[B]);else this.options.saveMissingTo==="all"?J=this.languageUtils.toResolveHierarchy(r.lng||this.language):J.push(r.lng||this.language);const ce=(B,ae,Ce)=>{const Ae=T&&Ce!==g?Ce:X;this.options.missingKeyHandler?this.options.missingKeyHandler(B,l,ae,Ae,ee,r):this.backendConnector&&this.backendConnector.saveMissing&&this.backendConnector.saveMissing(B,l,ae,Ae,ee,r),this.emit("missingKey",B,l,ae,g)};this.options.saveMissing&&(this.options.saveMissingPlurals&&I?J.forEach(B=>{const ae=this.pluralResolver.getSuffixes(B,r);L&&r[`defaultValue${this.options.pluralSeparator}zero`]&&ae.indexOf(`${this.options.pluralSeparator}zero`)<0&&ae.push(`${this.options.pluralSeparator}zero`),ae.forEach(Ce=>{ce([B],s+Ce,r[`defaultValue${Ce}`]||F)})}):ce(J,s,F))}g=this.extendTranslation(g,e,r,h,n),C&&g===s&&this.options.appendNamespaceToMissingKey&&(g=`${l}:${s}`),(C||E)&&this.options.parseMissingKeyHandler&&(this.options.compatibilityAPI!=="v1"?g=this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey?`${l}:${s}`:s,E?g:void 0):g=this.options.parseMissingKeyHandler(g))}return i?(h.res=g,h.usedParams=this.getUsedParamsDetails(r),h):g}extendTranslation(e,r,n,i,a){var s=this;if(this.i18nFormat&&this.i18nFormat.parse)e=this.i18nFormat.parse(e,{...this.options.interpolation.defaultVariables,...n},n.lng||this.language||i.usedLng,i.usedNS,i.usedKey,{resolved:i});else if(!n.skipInterpolation){n.interpolation&&this.interpolator.init({...n,interpolation:{...this.options.interpolation,...n.interpolation}});const c=$e(e)&&(n&&n.interpolation&&n.interpolation.skipOnVariables!==void 0?n.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables);let d;if(c){const g=e.match(this.interpolator.nestingRegexp);d=g&&g.length}let h=n.replace&&!$e(n.replace)?n.replace:n;if(this.options.interpolation.defaultVariables&&(h={...this.options.interpolation.defaultVariables,...h}),e=this.interpolator.interpolate(e,h,n.lng||this.language||i.usedLng,n),c){const g=e.match(this.interpolator.nestingRegexp),m=g&&g.length;d<m&&(n.nest=!1)}!n.lng&&this.options.compatibilityAPI!=="v1"&&i&&i.res&&(n.lng=this.language||i.usedLng),n.nest!==!1&&(e=this.interpolator.nest(e,function(){for(var g=arguments.length,m=new Array(g),v=0;v<g;v++)m[v]=arguments[v];return a&&a[0]===m[0]&&!n.context?(s.logger.warn(`It seems you are nesting recursively key: ${m[0]} in key: ${r[0]}`),null):s.translate(...m,r)},n)),n.interpolation&&this.interpolator.reset()}const o=n.postProcess||this.options.postProcess,l=$e(o)?[o]:o;return e!=null&&l&&l.length&&n.applyPostProcessor!==!1&&(e=iD.handle(l,e,r,this.options&&this.options.postProcessPassResolved?{i18nResolved:{...i,usedParams:this.getUsedParamsDetails(n)},...n}:n,this)),e}resolve(e){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n,i,a,s,o;return $e(e)&&(e=[e]),e.forEach(l=>{if(this.isValidLookup(n))return;const c=this.extractFromKey(l,r),d=c.key;i=d;let h=c.namespaces;this.options.fallbackNS&&(h=h.concat(this.options.fallbackNS));const g=r.count!==void 0&&!$e(r.count),m=g&&!r.ordinal&&r.count===0&&this.pluralResolver.shouldUseIntlApi(),v=r.context!==void 0&&($e(r.context)||typeof r.context=="number")&&r.context!=="",b=r.lngs?r.lngs:this.languageUtils.toResolveHierarchy(r.lng||this.language,r.fallbackLng);h.forEach(y=>{this.isValidLookup(n)||(o=y,!M1[`${b[0]}-${y}`]&&this.utils&&this.utils.hasLoadedNamespace&&!this.utils.hasLoadedNamespace(o)&&(M1[`${b[0]}-${y}`]=!0,this.logger.warn(`key "${i}" for languages "${b.join(", ")}" won't get resolved as namespace "${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!!!")),b.forEach(x=>{if(this.isValidLookup(n))return;s=x;const w=[d];if(this.i18nFormat&&this.i18nFormat.addLookupKeys)this.i18nFormat.addLookupKeys(w,d,x,y,r);else{let E;g&&(E=this.pluralResolver.getSuffix(x,r.count,r));const C=`${this.options.pluralSeparator}zero`,I=`${this.options.pluralSeparator}ordinal${this.options.pluralSeparator}`;if(g&&(w.push(d+E),r.ordinal&&E.indexOf(I)===0&&w.push(d+E.replace(I,this.options.pluralSeparator)),m&&w.push(d+C)),v){const T=`${d}${this.options.contextSeparator}${r.context}`;w.push(T),g&&(w.push(T+E),r.ordinal&&E.indexOf(I)===0&&w.push(T+E.replace(I,this.options.pluralSeparator)),m&&w.push(T+C))}}let S;for(;S=w.pop();)this.isValidLookup(n)||(a=S,n=this.getResource(x,y,S,r))}))})}),{res:n,usedKey:i,exactUsedKey:a,usedLng:s,usedNS:o}}isValidLookup(e){return e!==void 0&&!(!this.options.returnNull&&e===null)&&!(!this.options.returnEmptyString&&e==="")}getResource(e,r,n){let i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};return this.i18nFormat&&this.i18nFormat.getResource?this.i18nFormat.getResource(e,r,n,i):this.resourceStore.getResource(e,r,n,i)}getUsedParamsDetails(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};const r=["defaultValue","ordinal","context","replace","lng","lngs","fallbackLng","ns","keySeparator","nsSeparator","returnObjects","returnDetails","joinArrays","postProcess","interpolation"],n=e.replace&&!$e(e.replace);let i=n?e.replace:e;if(n&&typeof e.count<"u"&&(i.count=e.count),this.options.interpolation.defaultVariables&&(i={...this.options.interpolation.defaultVariables,...i}),!n){i={...i};for(const a of r)delete i[a]}return i}static hasDefaultValue(e){const r="defaultValue";for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&r===n.substring(0,r.length)&&e[n]!==void 0)return!0;return!1}}const Sp=t=>t.charAt(0).toUpperCase()+t.slice(1);class P1{constructor(e){this.options=e,this.supportedLngs=this.options.supportedLngs||!1,this.logger=gi.create("languageUtils")}getScriptPartFromCode(e){if(e=Vf(e),!e||e.indexOf("-")<0)return null;const r=e.split("-");return r.length===2||(r.pop(),r[r.length-1].toLowerCase()==="x")?null:this.formatLanguageCode(r.join("-"))}getLanguagePartFromCode(e){if(e=Vf(e),!e||e.indexOf("-")<0)return e;const r=e.split("-");return this.formatLanguageCode(r[0])}formatLanguageCode(e){if($e(e)&&e.indexOf("-")>-1){if(typeof Intl<"u"&&typeof Intl.getCanonicalLocales<"u")try{let i=Intl.getCanonicalLocales(e)[0];if(i&&this.options.lowerCaseLng&&(i=i.toLowerCase()),i)return i}catch{}const r=["hans","hant","latn","cyrl","cans","mong","arab"];let n=e.split("-");return this.options.lowerCaseLng?n=n.map(i=>i.toLowerCase()):n.length===2?(n[0]=n[0].toLowerCase(),n[1]=n[1].toUpperCase(),r.indexOf(n[1].toLowerCase())>-1&&(n[1]=Sp(n[1].toLowerCase()))):n.length===3&&(n[0]=n[0].toLowerCase(),n[1].length===2&&(n[1]=n[1].toUpperCase()),n[0]!=="sgn"&&n[2].length===2&&(n[2]=n[2].toUpperCase()),r.indexOf(n[1].toLowerCase())>-1&&(n[1]=Sp(n[1].toLowerCase())),r.indexOf(n[2].toLowerCase())>-1&&(n[2]=Sp(n[2].toLowerCase()))),n.join("-")}return this.options.cleanCode||this.options.lowerCaseLng?e.toLowerCase():e}isSupportedCode(e){return(this.options.load==="languageOnly"||this.options.nonExplicitSupportedLngs)&&(e=this.getLanguagePartFromCode(e)),!this.supportedLngs||!this.supportedLngs.length||this.supportedLngs.indexOf(e)>-1}getBestMatchFromCodes(e){if(!e)return null;let r;return e.forEach(n=>{if(r)return;const i=this.formatLanguageCode(n);(!this.options.supportedLngs||this.isSupportedCode(i))&&(r=i)}),!r&&this.options.supportedLngs&&e.forEach(n=>{if(r)return;const i=this.getLanguagePartFromCode(n);if(this.isSupportedCode(i))return r=i;r=this.options.supportedLngs.find(a=>{if(a===i)return a;if(!(a.indexOf("-")<0&&i.indexOf("-")<0)&&(a.indexOf("-")>0&&i.indexOf("-")<0&&a.substring(0,a.indexOf("-"))===i||a.indexOf(i)===0&&i.length>1))return a})}),r||(r=this.getFallbackCodes(this.options.fallbackLng)[0]),r}getFallbackCodes(e,r){if(!e)return[];if(typeof e=="function"&&(e=e(r)),$e(e)&&(e=[e]),Array.isArray(e))return e;if(!r)return e.default||[];let n=e[r];return n||(n=e[this.getScriptPartFromCode(r)]),n||(n=e[this.formatLanguageCode(r)]),n||(n=e[this.getLanguagePartFromCode(r)]),n||(n=e.default),n||[]}toResolveHierarchy(e,r){const n=this.getFallbackCodes(r||this.options.fallbackLng||[],e),i=[],a=s=>{s&&(this.isSupportedCode(s)?i.push(s):this.logger.warn(`rejecting language code not found in supportedLngs: ${s}`))};return $e(e)&&(e.indexOf("-")>-1||e.indexOf("_")>-1)?(this.options.load!=="languageOnly"&&a(this.formatLanguageCode(e)),this.options.load!=="languageOnly"&&this.options.load!=="currentOnly"&&a(this.getScriptPartFromCode(e)),this.options.load!=="currentOnly"&&a(this.getLanguagePartFromCode(e))):$e(e)&&a(this.formatLanguageCode(e)),n.forEach(s=>{i.indexOf(s)<0&&a(this.formatLanguageCode(s))}),i}}let PV=[{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}],LV={1:t=>+(t>1),2:t=>+(t!=1),3:t=>0,4:t=>t%10==1&&t%100!=11?0:t%10>=2&&t%10<=4&&(t%100<10||t%100>=20)?1:2,5:t=>t==0?0:t==1?1:t==2?2:t%100>=3&&t%100<=10?3:t%100>=11?4:5,6:t=>t==1?0:t>=2&&t<=4?1:2,7:t=>t==1?0:t%10>=2&&t%10<=4&&(t%100<10||t%100>=20)?1:2,8:t=>t==1?0:t==2?1:t!=8&&t!=11?2:3,9:t=>+(t>=2),10:t=>t==1?0:t==2?1:t<7?2:t<11?3:4,11:t=>t==1||t==11?0:t==2||t==12?1:t>2&&t<20?2:3,12:t=>+(t%10!=1||t%100==11),13:t=>+(t!==0),14:t=>t==1?0:t==2?1:t==3?2:3,15:t=>t%10==1&&t%100!=11?0:t%10>=2&&(t%100<10||t%100>=20)?1:2,16:t=>t%10==1&&t%100!=11?0:t!==0?1:2,17:t=>t==1||t%10==1&&t%100!=11?0:1,18:t=>t==0?0:t==1?1:2,19:t=>t==1?0:t==0||t%100>1&&t%100<11?1:t%100>10&&t%100<20?2:3,20:t=>t==1?0:t==0||t%100>0&&t%100<20?1:2,21:t=>t%100==1?1:t%100==2?2:t%100==3||t%100==4?3:0,22:t=>t==1?0:t==2?1:(t<0||t>10)&&t%10==0?2:3};const NV=["v1","v2","v3"],FV=["v4"],L1={zero:0,one:1,two:2,few:3,many:4,other:5},kV=()=>{const t={};return PV.forEach(e=>{e.lngs.forEach(r=>{t[r]={numbers:e.nr,plurals:LV[e.fc]}})}),t};class jV{constructor(e){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.languageUtils=e,this.options=r,this.logger=gi.create("pluralResolver"),(!this.options.compatibilityJSON||FV.includes(this.options.compatibilityJSON))&&(typeof Intl>"u"||!Intl.PluralRules)&&(this.options.compatibilityJSON="v3",this.logger.error("Your environment seems not to be Intl API compatible, use an Intl.PluralRules polyfill. Will fallback to the compatibilityJSON v3 format handling.")),this.rules=kV(),this.pluralRulesCache={}}addRule(e,r){this.rules[e]=r}clearCache(){this.pluralRulesCache={}}getRule(e){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(this.shouldUseIntlApi()){const n=Vf(e==="dev"?"en":e),i=r.ordinal?"ordinal":"cardinal",a=JSON.stringify({cleanedCode:n,type:i});if(a in this.pluralRulesCache)return this.pluralRulesCache[a];let s;try{s=new Intl.PluralRules(n,{type:i})}catch{if(!e.match(/-|_/))return;const l=this.languageUtils.getLanguagePartFromCode(e);s=this.getRule(l,r)}return this.pluralRulesCache[a]=s,s}return this.rules[e]||this.rules[this.languageUtils.getLanguagePartFromCode(e)]}needsPlural(e){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};const n=this.getRule(e,r);return this.shouldUseIntlApi()?n&&n.resolvedOptions().pluralCategories.length>1:n&&n.numbers.length>1}getPluralFormsOfKey(e,r){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return this.getSuffixes(e,n).map(i=>`${r}${i}`)}getSuffixes(e){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};const n=this.getRule(e,r);return n?this.shouldUseIntlApi()?n.resolvedOptions().pluralCategories.sort((i,a)=>L1[i]-L1[a]).map(i=>`${this.options.prepend}${r.ordinal?`ordinal${this.options.prepend}`:""}${i}`):n.numbers.map(i=>this.getSuffix(e,i,r)):[]}getSuffix(e,r){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};const i=this.getRule(e,n);return i?this.shouldUseIntlApi()?`${this.options.prepend}${n.ordinal?`ordinal${this.options.prepend}`:""}${i.select(r)}`:this.getSuffixRetroCompatible(i,r):(this.logger.warn(`no plural rule found for: ${e}`),"")}getSuffixRetroCompatible(e,r){const n=e.noAbs?e.plurals(r):e.plurals(Math.abs(r));let i=e.numbers[n];this.options.simplifyPluralSuffix&&e.numbers.length===2&&e.numbers[0]===1&&(i===2?i="plural":i===1&&(i=""));const a=()=>this.options.prepend&&i.toString()?this.options.prepend+i.toString():i.toString();return this.options.compatibilityJSON==="v1"?i===1?"":typeof i=="number"?`_plural_${i.toString()}`:a():this.options.compatibilityJSON==="v2"||this.options.simplifyPluralSuffix&&e.numbers.length===2&&e.numbers[0]===1?a():this.options.prepend&&n.toString()?this.options.prepend+n.toString():n.toString()}shouldUseIntlApi(){return!NV.includes(this.options.compatibilityJSON)}}const N1=function(t,e,r){let n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:".",i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!0,a=CV(t,e,r);return!a&&i&&$e(r)&&(a=$y(t,r,n),a===void 0&&(a=$y(e,r,n))),a},Cp=t=>t.replace(/\$/g,"$$$$");class $V{constructor(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};this.logger=gi.create("interpolator"),this.options=e,this.format=e.interpolation&&e.interpolation.format||(r=>r),this.init(e)}init(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};e.interpolation||(e.interpolation={escapeValue:!0});const{escape:r,escapeValue:n,useRawValueToEscape:i,prefix:a,prefixEscaped:s,suffix:o,suffixEscaped:l,formatSeparator:c,unescapeSuffix:d,unescapePrefix:h,nestingPrefix:g,nestingPrefixEscaped:m,nestingSuffix:v,nestingSuffixEscaped:b,nestingOptionsSeparator:y,maxReplaces:x,alwaysFormat:w}=e.interpolation;this.escape=r!==void 0?r:OV,this.escapeValue=n!==void 0?n:!0,this.useRawValueToEscape=i!==void 0?i:!1,this.prefix=a?zs(a):s||"{{",this.suffix=o?zs(o):l||"}}",this.formatSeparator=c||",",this.unescapePrefix=d?"":h||"-",this.unescapeSuffix=this.unescapePrefix?"":d||"",this.nestingPrefix=g?zs(g):m||zs("$t("),this.nestingSuffix=v?zs(v):b||zs(")"),this.nestingOptionsSeparator=y||",",this.maxReplaces=x||1e3,this.alwaysFormat=w!==void 0?w:!1,this.resetRegExp()}reset(){this.options&&this.init(this.options)}resetRegExp(){const e=(r,n)=>r&&r.source===n?(r.lastIndex=0,r):new RegExp(n,"g");this.regexp=e(this.regexp,`${this.prefix}(.+?)${this.suffix}`),this.regexpUnescape=e(this.regexpUnescape,`${this.prefix}${this.unescapePrefix}(.+?)${this.unescapeSuffix}${this.suffix}`),this.nestingRegexp=e(this.nestingRegexp,`${this.nestingPrefix}(.+?)${this.nestingSuffix}`)}interpolate(e,r,n,i){let a,s,o;const l=this.options&&this.options.interpolation&&this.options.interpolation.defaultVariables||{},c=m=>{if(m.indexOf(this.formatSeparator)<0){const x=N1(r,l,m,this.options.keySeparator,this.options.ignoreJSONStructure);return this.alwaysFormat?this.format(x,void 0,n,{...i,...r,interpolationkey:m}):x}const v=m.split(this.formatSeparator),b=v.shift().trim(),y=v.join(this.formatSeparator).trim();return this.format(N1(r,l,b,this.options.keySeparator,this.options.ignoreJSONStructure),y,n,{...i,...r,interpolationkey:b})};this.resetRegExp();const d=i&&i.missingInterpolationHandler||this.options.missingInterpolationHandler,h=i&&i.interpolation&&i.interpolation.skipOnVariables!==void 0?i.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables;return[{regex:this.regexpUnescape,safeValue:m=>Cp(m)},{regex:this.regexp,safeValue:m=>this.escapeValue?Cp(this.escape(m)):Cp(m)}].forEach(m=>{for(o=0;a=m.regex.exec(e);){const v=a[1].trim();if(s=c(v),s===void 0)if(typeof d=="function"){const y=d(e,a,i);s=$e(y)?y:""}else if(i&&Object.prototype.hasOwnProperty.call(i,v))s="";else if(h){s=a[0];continue}else this.logger.warn(`missed to pass in variable ${v} for interpolating ${e}`),s="";else!$e(s)&&!this.useRawValueToEscape&&(s=O1(s));const b=m.safeValue(s);if(e=e.replace(a[0],b),h?(m.regex.lastIndex+=s.length,m.regex.lastIndex-=a[0].length):m.regex.lastIndex=0,o++,o>=this.maxReplaces)break}}),e}nest(e,r){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},i,a,s;const o=(l,c)=>{const d=this.nestingOptionsSeparator;if(l.indexOf(d)<0)return l;const h=l.split(new RegExp(`${d}[ ]*{`));let g=`{${h[1]}`;l=h[0],g=this.interpolate(g,s);const m=g.match(/'/g),v=g.match(/"/g);(m&&m.length%2===0&&!v||v.length%2!==0)&&(g=g.replace(/'/g,'"'));try{s=JSON.parse(g),c&&(s={...c,...s})}catch(b){return this.logger.warn(`failed parsing options string in nesting for key ${l}`,b),`${l}${d}${g}`}return s.defaultValue&&s.defaultValue.indexOf(this.prefix)>-1&&delete s.defaultValue,l};for(;i=this.nestingRegexp.exec(e);){let l=[];s={...n},s=s.replace&&!$e(s.replace)?s.replace:s,s.applyPostProcessor=!1,delete s.defaultValue;let c=!1;if(i[0].indexOf(this.formatSeparator)!==-1&&!/{.*}/.test(i[1])){const d=i[1].split(this.formatSeparator).map(h=>h.trim());i[1]=d.shift(),l=d,c=!0}if(a=r(o.call(this,i[1].trim(),s),s),a&&i[0]===e&&!$e(a))return a;$e(a)||(a=O1(a)),a||(this.logger.warn(`missed to resolve ${i[1]} for nesting ${e}`),a=""),c&&(a=l.reduce((d,h)=>this.format(d,h,n.lng,{...n,interpolationkey:i[1].trim()}),a.trim())),e=e.replace(i[0],a),this.regexp.lastIndex=0}return e}}const UV=t=>{let e=t.toLowerCase().trim();const r={};if(t.indexOf("(")>-1){const n=t.split("(");e=n[0].toLowerCase().trim();const i=n[1].substring(0,n[1].length-1);e==="currency"&&i.indexOf(":")<0?r.currency||(r.currency=i.trim()):e==="relativetime"&&i.indexOf(":")<0?r.range||(r.range=i.trim()):i.split(";").forEach(s=>{if(s){const[o,...l]=s.split(":"),c=l.join(":").trim().replace(/^'+|'+$/g,""),d=o.trim();r[d]||(r[d]=c),c==="false"&&(r[d]=!1),c==="true"&&(r[d]=!0),isNaN(c)||(r[d]=parseInt(c,10))}})}return{formatName:e,formatOptions:r}},Vs=t=>{const e={};return(r,n,i)=>{let a=i;i&&i.interpolationkey&&i.formatParams&&i.formatParams[i.interpolationkey]&&i[i.interpolationkey]&&(a={...a,[i.interpolationkey]:void 0});const s=n+JSON.stringify(a);let o=e[s];return o||(o=t(Vf(n),i),e[s]=o),o(r)}};class qV{constructor(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};this.logger=gi.create("formatter"),this.options=e,this.formats={number:Vs((r,n)=>{const i=new Intl.NumberFormat(r,{...n});return a=>i.format(a)}),currency:Vs((r,n)=>{const i=new Intl.NumberFormat(r,{...n,style:"currency"});return a=>i.format(a)}),datetime:Vs((r,n)=>{const i=new Intl.DateTimeFormat(r,{...n});return a=>i.format(a)}),relativetime:Vs((r,n)=>{const i=new Intl.RelativeTimeFormat(r,{...n});return a=>i.format(a,n.range||"day")}),list:Vs((r,n)=>{const i=new Intl.ListFormat(r,{...n});return a=>i.format(a)})},this.init(e)}init(e){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{interpolation:{}};this.formatSeparator=r.interpolation.formatSeparator||","}add(e,r){this.formats[e.toLowerCase().trim()]=r}addCached(e,r){this.formats[e.toLowerCase().trim()]=Vs(r)}format(e,r,n){let i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};const a=r.split(this.formatSeparator);if(a.length>1&&a[0].indexOf("(")>1&&a[0].indexOf(")")<0&&a.find(o=>o.indexOf(")")>-1)){const o=a.findIndex(l=>l.indexOf(")")>-1);a[0]=[a[0],...a.splice(1,o)].join(this.formatSeparator)}return a.reduce((o,l)=>{const{formatName:c,formatOptions:d}=UV(l);if(this.formats[c]){let h=o;try{const g=i&&i.formatParams&&i.formatParams[i.interpolationkey]||{},m=g.locale||g.lng||i.locale||i.lng||n;h=this.formats[c](o,m,{...d,...i,...g})}catch(g){this.logger.warn(g)}return h}else this.logger.warn(`there was no format function for ${c}`);return o},e)}}const HV=(t,e)=>{t.pending[e]!==void 0&&(delete t.pending[e],t.pendingCount--)};class WV extends Rd{constructor(e,r,n){let i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};super(),this.backend=e,this.store=r,this.services=n,this.languageUtils=n.languageUtils,this.options=i,this.logger=gi.create("backendConnector"),this.waitingReads=[],this.maxParallelReads=i.maxParallelReads||10,this.readingCalls=0,this.maxRetries=i.maxRetries>=0?i.maxRetries:5,this.retryTimeout=i.retryTimeout>=1?i.retryTimeout:350,this.state={},this.queue=[],this.backend&&this.backend.init&&this.backend.init(n,i.backend,i)}queueLoad(e,r,n,i){const a={},s={},o={},l={};return e.forEach(c=>{let d=!0;r.forEach(h=>{const g=`${c}|${h}`;!n.reload&&this.store.hasResourceBundle(c,h)?this.state[g]=2:this.state[g]<0||(this.state[g]===1?s[g]===void 0&&(s[g]=!0):(this.state[g]=1,d=!1,s[g]===void 0&&(s[g]=!0),a[g]===void 0&&(a[g]=!0),l[h]===void 0&&(l[h]=!0)))}),d||(o[c]=!0)}),(Object.keys(a).length||Object.keys(s).length)&&this.queue.push({pending:s,pendingCount:Object.keys(s).length,loaded:{},errors:[],callback:i}),{toLoad:Object.keys(a),pending:Object.keys(s),toLoadLanguages:Object.keys(o),toLoadNamespaces:Object.keys(l)}}loaded(e,r,n){const i=e.split("|"),a=i[0],s=i[1];r&&this.emit("failedLoading",a,s,r),!r&&n&&this.store.addResourceBundle(a,s,n,void 0,void 0,{skipCopy:!0}),this.state[e]=r?-1:2,r&&n&&(this.state[e]=0);const o={};this.queue.forEach(l=>{SV(l.loaded,[a],s),HV(l,e),r&&l.errors.push(r),l.pendingCount===0&&!l.done&&(Object.keys(l.loaded).forEach(c=>{o[c]||(o[c]={});const d=l.loaded[c];d.length&&d.forEach(h=>{o[c][h]===void 0&&(o[c][h]=!0)})}),l.done=!0,l.errors.length?l.callback(l.errors):l.callback())}),this.emit("loaded",o),this.queue=this.queue.filter(l=>!l.done)}read(e,r,n){let i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:0,a=arguments.length>4&&arguments[4]!==void 0?arguments[4]:this.retryTimeout,s=arguments.length>5?arguments[5]:void 0;if(!e.length)return s(null,{});if(this.readingCalls>=this.maxParallelReads){this.waitingReads.push({lng:e,ns:r,fcName:n,tried:i,wait:a,callback:s});return}this.readingCalls++;const o=(c,d)=>{if(this.readingCalls--,this.waitingReads.length>0){const h=this.waitingReads.shift();this.read(h.lng,h.ns,h.fcName,h.tried,h.wait,h.callback)}if(c&&d&&i<this.maxRetries){setTimeout(()=>{this.read.call(this,e,r,n,i+1,a*2,s)},a);return}s(c,d)},l=this.backend[n].bind(this.backend);if(l.length===2){try{const c=l(e,r);c&&typeof c.then=="function"?c.then(d=>o(null,d)).catch(o):o(null,c)}catch(c){o(c)}return}return l(e,r,o)}prepareLoading(e,r){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},i=arguments.length>3?arguments[3]:void 0;if(!this.backend)return this.logger.warn("No backend was added via i18next.use. Will not load resources."),i&&i();$e(e)&&(e=this.languageUtils.toResolveHierarchy(e)),$e(r)&&(r=[r]);const a=this.queueLoad(e,r,n,i);if(!a.toLoad.length)return a.pending.length||i(),null;a.toLoad.forEach(s=>{this.loadOne(s)})}load(e,r,n){this.prepareLoading(e,r,{},n)}reload(e,r,n){this.prepareLoading(e,r,{reload:!0},n)}loadOne(e){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"";const n=e.split("|"),i=n[0],a=n[1];this.read(i,a,"read",void 0,void 0,(s,o)=>{s&&this.logger.warn(`${r}loading namespace ${a} for language ${i} failed`,s),!s&&o&&this.logger.log(`${r}loaded namespace ${a} for language ${i}`,o),this.loaded(e,s,o)})}saveMissing(e,r,n,i,a){let s=arguments.length>5&&arguments[5]!==void 0?arguments[5]:{},o=arguments.length>6&&arguments[6]!==void 0?arguments[6]:()=>{};if(this.services.utils&&this.services.utils.hasLoadedNamespace&&!this.services.utils.hasLoadedNamespace(r)){this.logger.warn(`did not save key "${n}" as the namespace "${r}" was not yet loaded`,"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!");return}if(!(n==null||n==="")){if(this.backend&&this.backend.create){const l={...s,isUpdate:a},c=this.backend.create.bind(this.backend);if(c.length<6)try{let d;c.length===5?d=c(e,r,n,i,l):d=c(e,r,n,i),d&&typeof d.then=="function"?d.then(h=>o(null,h)).catch(o):o(null,d)}catch(d){o(d)}else c(e,r,n,i,o,l)}!e||!e[0]||this.store.addResource(e[0],r,n,i)}}}const F1=()=>({debug:!1,initImmediate:!0,ns:["translation"],defaultNS:["translation"],fallbackLng:["dev"],fallbackNS:!1,supportedLngs:!1,nonExplicitSupportedLngs:!1,load:"all",preload:!1,simplifyPluralSuffix:!0,keySeparator:".",nsSeparator:":",pluralSeparator:"_",contextSeparator:"_",partialBundledLanguages:!1,saveMissing:!1,updateMissing:!1,saveMissingTo:"fallback",saveMissingPlurals:!0,missingKeyHandler:!1,missingInterpolationHandler:!1,postProcess:!1,postProcessPassResolved:!1,returnNull:!1,returnEmptyString:!0,returnObjects:!1,joinArrays:!1,returnedObjectHandler:!1,parseMissingKeyHandler:!1,appendNamespaceToMissingKey:!1,appendNamespaceToCIMode:!1,overloadTranslationOptionHandler:t=>{let e={};if(typeof t[1]=="object"&&(e=t[1]),$e(t[1])&&(e.defaultValue=t[1]),$e(t[2])&&(e.tDescription=t[2]),typeof t[2]=="object"||typeof t[3]=="object"){const r=t[3]||t[2];Object.keys(r).forEach(n=>{e[n]=r[n]})}return e},interpolation:{escapeValue:!0,format:t=>t,prefix:"{{",suffix:"}}",formatSeparator:",",unescapePrefix:"-",nestingPrefix:"$t(",nestingSuffix:")",nestingOptionsSeparator:",",maxReplaces:1e3,skipOnVariables:!0}}),k1=t=>($e(t.ns)&&(t.ns=[t.ns]),$e(t.fallbackLng)&&(t.fallbackLng=[t.fallbackLng]),$e(t.fallbackNS)&&(t.fallbackNS=[t.fallbackNS]),t.supportedLngs&&t.supportedLngs.indexOf("cimode")<0&&(t.supportedLngs=t.supportedLngs.concat(["cimode"])),t),Zl=()=>{},BV=t=>{Object.getOwnPropertyNames(Object.getPrototypeOf(t)).forEach(r=>{typeof t[r]=="function"&&(t[r]=t[r].bind(t))})};class Lu extends Rd{constructor(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},r=arguments.length>1?arguments[1]:void 0;if(super(),this.options=k1(e),this.services={},this.logger=gi,this.modules={external:[]},BV(this),r&&!this.isInitialized&&!e.isClone){if(!this.options.initImmediate)return this.init(e,r),this;setTimeout(()=>{this.init(e,r)},0)}}init(){var e=this;let r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=arguments.length>1?arguments[1]:void 0;this.isInitializing=!0,typeof r=="function"&&(n=r,r={}),!r.defaultNS&&r.defaultNS!==!1&&r.ns&&($e(r.ns)?r.defaultNS=r.ns:r.ns.indexOf("translation")<0&&(r.defaultNS=r.ns[0]));const i=F1();this.options={...i,...this.options,...k1(r)},this.options.compatibilityAPI!=="v1"&&(this.options.interpolation={...i.interpolation,...this.options.interpolation}),r.keySeparator!==void 0&&(this.options.userDefinedKeySeparator=r.keySeparator),r.nsSeparator!==void 0&&(this.options.userDefinedNsSeparator=r.nsSeparator);const a=d=>d?typeof d=="function"?new d:d:null;if(!this.options.isClone){this.modules.logger?gi.init(a(this.modules.logger),this.options):gi.init(null,this.options);let d;this.modules.formatter?d=this.modules.formatter:typeof Intl<"u"&&(d=qV);const h=new P1(this.options);this.store=new D1(this.options.resources,this.options);const g=this.services;g.logger=gi,g.resourceStore=this.store,g.languageUtils=h,g.pluralResolver=new jV(h,{prepend:this.options.pluralSeparator,compatibilityJSON:this.options.compatibilityJSON,simplifyPluralSuffix:this.options.simplifyPluralSuffix}),d&&(!this.options.interpolation.format||this.options.interpolation.format===i.interpolation.format)&&(g.formatter=a(d),g.formatter.init(g,this.options),this.options.interpolation.format=g.formatter.format.bind(g.formatter)),g.interpolator=new $V(this.options),g.utils={hasLoadedNamespace:this.hasLoadedNamespace.bind(this)},g.backendConnector=new WV(a(this.modules.backend),g.resourceStore,g,this.options),g.backendConnector.on("*",function(m){for(var v=arguments.length,b=new Array(v>1?v-1:0),y=1;y<v;y++)b[y-1]=arguments[y];e.emit(m,...b)}),this.modules.languageDetector&&(g.languageDetector=a(this.modules.languageDetector),g.languageDetector.init&&g.languageDetector.init(g,this.options.detection,this.options)),this.modules.i18nFormat&&(g.i18nFormat=a(this.modules.i18nFormat),g.i18nFormat.init&&g.i18nFormat.init(this)),this.translator=new Kf(this.services,this.options),this.translator.on("*",function(m){for(var v=arguments.length,b=new Array(v>1?v-1:0),y=1;y<v;y++)b[y-1]=arguments[y];e.emit(m,...b)}),this.modules.external.forEach(m=>{m.init&&m.init(this)})}if(this.format=this.options.interpolation.format,n||(n=Zl),this.options.fallbackLng&&!this.services.languageDetector&&!this.options.lng){const d=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);d.length>0&&d[0]!=="dev"&&(this.options.lng=d[0])}!this.services.languageDetector&&!this.options.lng&&this.logger.warn("init: no languageDetector is used and no lng is defined"),["getResource","hasResourceBundle","getResourceBundle","getDataByLanguage"].forEach(d=>{this[d]=function(){return e.store[d](...arguments)}}),["addResource","addResources","addResourceBundle","removeResourceBundle"].forEach(d=>{this[d]=function(){return e.store[d](...arguments),e}});const l=ru(),c=()=>{const d=(h,g)=>{this.isInitializing=!1,this.isInitialized&&!this.initializedStoreOnce&&this.logger.warn("init: i18next is already initialized. You should call init just once!"),this.isInitialized=!0,this.options.isClone||this.logger.log("initialized",this.options),this.emit("initialized",this.options),l.resolve(g),n(h,g)};if(this.languages&&this.options.compatibilityAPI!=="v1"&&!this.isInitialized)return d(null,this.t.bind(this));this.changeLanguage(this.options.lng,d)};return this.options.resources||!this.options.initImmediate?c():setTimeout(c,0),l}loadResources(e){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Zl;const i=$e(e)?e:this.language;if(typeof e=="function"&&(n=e),!this.options.resources||this.options.partialBundledLanguages){if(i&&i.toLowerCase()==="cimode"&&(!this.options.preload||this.options.preload.length===0))return n();const a=[],s=o=>{if(!o||o==="cimode")return;this.services.languageUtils.toResolveHierarchy(o).forEach(c=>{c!=="cimode"&&a.indexOf(c)<0&&a.push(c)})};i?s(i):this.services.languageUtils.getFallbackCodes(this.options.fallbackLng).forEach(l=>s(l)),this.options.preload&&this.options.preload.forEach(o=>s(o)),this.services.backendConnector.load(a,this.options.ns,o=>{!o&&!this.resolvedLanguage&&this.language&&this.setResolvedLanguage(this.language),n(o)})}else n(null)}reloadResources(e,r,n){const i=ru();return typeof e=="function"&&(n=e,e=void 0),typeof r=="function"&&(n=r,r=void 0),e||(e=this.languages),r||(r=this.options.ns),n||(n=Zl),this.services.backendConnector.reload(e,r,a=>{i.resolve(),n(a)}),i}use(e){if(!e)throw new Error("You are passing an undefined module! Please check the object you are passing to i18next.use()");if(!e.type)throw new Error("You are passing a wrong module! Please check the object you are passing to i18next.use()");return e.type==="backend"&&(this.modules.backend=e),(e.type==="logger"||e.log&&e.warn&&e.error)&&(this.modules.logger=e),e.type==="languageDetector"&&(this.modules.languageDetector=e),e.type==="i18nFormat"&&(this.modules.i18nFormat=e),e.type==="postProcessor"&&iD.addPostProcessor(e),e.type==="formatter"&&(this.modules.formatter=e),e.type==="3rdParty"&&this.modules.external.push(e),this}setResolvedLanguage(e){if(!(!e||!this.languages)&&!(["cimode","dev"].indexOf(e)>-1))for(let r=0;r<this.languages.length;r++){const n=this.languages[r];if(!(["cimode","dev"].indexOf(n)>-1)&&this.store.hasLanguageSomeTranslations(n)){this.resolvedLanguage=n;break}}}changeLanguage(e,r){var n=this;this.isLanguageChangingTo=e;const i=ru();this.emit("languageChanging",e);const a=l=>{this.language=l,this.languages=this.services.languageUtils.toResolveHierarchy(l),this.resolvedLanguage=void 0,this.setResolvedLanguage(l)},s=(l,c)=>{c?(a(c),this.translator.changeLanguage(c),this.isLanguageChangingTo=void 0,this.emit("languageChanged",c),this.logger.log("languageChanged",c)):this.isLanguageChangingTo=void 0,i.resolve(function(){return n.t(...arguments)}),r&&r(l,function(){return n.t(...arguments)})},o=l=>{!e&&!l&&this.services.languageDetector&&(l=[]);const c=$e(l)?l:this.services.languageUtils.getBestMatchFromCodes(l);c&&(this.language||a(c),this.translator.language||this.translator.changeLanguage(c),this.services.languageDetector&&this.services.languageDetector.cacheUserLanguage&&this.services.languageDetector.cacheUserLanguage(c)),this.loadResources(c,d=>{s(d,c)})};return!e&&this.services.languageDetector&&!this.services.languageDetector.async?o(this.services.languageDetector.detect()):!e&&this.services.languageDetector&&this.services.languageDetector.async?this.services.languageDetector.detect.length===0?this.services.languageDetector.detect().then(o):this.services.languageDetector.detect(o):o(e),i}getFixedT(e,r,n){var i=this;const a=function(s,o){let l;if(typeof o!="object"){for(var c=arguments.length,d=new Array(c>2?c-2:0),h=2;h<c;h++)d[h-2]=arguments[h];l=i.options.overloadTranslationOptionHandler([s,o].concat(d))}else l={...o};l.lng=l.lng||a.lng,l.lngs=l.lngs||a.lngs,l.ns=l.ns||a.ns,l.keyPrefix!==""&&(l.keyPrefix=l.keyPrefix||n||a.keyPrefix);const g=i.options.keySeparator||".";let m;return l.keyPrefix&&Array.isArray(s)?m=s.map(v=>`${l.keyPrefix}${g}${v}`):m=l.keyPrefix?`${l.keyPrefix}${g}${s}`:s,i.t(m,l)};return $e(e)?a.lng=e:a.lngs=e,a.ns=r,a.keyPrefix=n,a}t(){return this.translator&&this.translator.translate(...arguments)}exists(){return this.translator&&this.translator.exists(...arguments)}setDefaultNamespace(e){this.options.defaultNS=e}hasLoadedNamespace(e){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(!this.isInitialized)return this.logger.warn("hasLoadedNamespace: i18next was not initialized",this.languages),!1;if(!this.languages||!this.languages.length)return this.logger.warn("hasLoadedNamespace: i18n.languages were undefined or empty",this.languages),!1;const n=r.lng||this.resolvedLanguage||this.languages[0],i=this.options?this.options.fallbackLng:!1,a=this.languages[this.languages.length-1];if(n.toLowerCase()==="cimode")return!0;const s=(o,l)=>{const c=this.services.backendConnector.state[`${o}|${l}`];return c===-1||c===0||c===2};if(r.precheck){const o=r.precheck(this,s);if(o!==void 0)return o}return!!(this.hasResourceBundle(n,e)||!this.services.backendConnector.backend||this.options.resources&&!this.options.partialBundledLanguages||s(n,e)&&(!i||s(a,e)))}loadNamespaces(e,r){const n=ru();return this.options.ns?($e(e)&&(e=[e]),e.forEach(i=>{this.options.ns.indexOf(i)<0&&this.options.ns.push(i)}),this.loadResources(i=>{n.resolve(),r&&r(i)}),n):(r&&r(),Promise.resolve())}loadLanguages(e,r){const n=ru();$e(e)&&(e=[e]);const i=this.options.preload||[],a=e.filter(s=>i.indexOf(s)<0&&this.services.languageUtils.isSupportedCode(s));return a.length?(this.options.preload=i.concat(a),this.loadResources(s=>{n.resolve(),r&&r(s)}),n):(r&&r(),Promise.resolve())}dir(e){if(e||(e=this.resolvedLanguage||(this.languages&&this.languages.length>0?this.languages[0]:this.language)),!e)return"rtl";const r=["ar","shu","sqr","ssh","xaa","yhd","yud","aao","abh","abv","acm","acq","acw","acx","acy","adf","ads","aeb","aec","afb","ajp","apc","apd","arb","arq","ars","ary","arz","auz","avl","ayh","ayl","ayn","ayp","bbz","pga","he","iw","ps","pbt","pbu","pst","prp","prd","ug","ur","ydd","yds","yih","ji","yi","hbo","men","xmn","fa","jpr","peo","pes","prs","dv","sam","ckb"],n=this.services&&this.services.languageUtils||new P1(F1());return r.indexOf(n.getLanguagePartFromCode(e))>-1||e.toLowerCase().indexOf("-arab")>1?"rtl":"ltr"}static createInstance(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},r=arguments.length>1?arguments[1]:void 0;return new Lu(e,r)}cloneInstance(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Zl;const n=e.forkResourceStore;n&&delete e.forkResourceStore;const i={...this.options,...e,isClone:!0},a=new Lu(i);return(e.debug!==void 0||e.prefix!==void 0)&&(a.logger=a.logger.clone(e)),["store","services","language"].forEach(o=>{a[o]=this[o]}),a.services={...this.services},a.services.utils={hasLoadedNamespace:a.hasLoadedNamespace.bind(a)},n&&(a.store=new D1(this.store.data,i),a.services.resourceStore=a.store),a.translator=new Kf(a.services,i),a.translator.on("*",function(o){for(var l=arguments.length,c=new Array(l>1?l-1:0),d=1;d<l;d++)c[d-1]=arguments[d];a.emit(o,...c)}),a.init(i,r),a.translator.options=i,a.translator.backendConnector.services.utils={hasLoadedNamespace:a.hasLoadedNamespace.bind(a)},a}toJSON(){return{options:this.options,store:this.store,language:this.language,languages:this.languages,resolvedLanguage:this.resolvedLanguage}}}const $r=Lu.createInstance();$r.createInstance=Lu.createInstance;$r.createInstance;$r.dir;$r.init;$r.loadResources;$r.reloadResources;$r.use;$r.changeLanguage;$r.getFixedT;$r.t;$r.exists;$r.setDefaultNamespace;$r.hasLoadedNamespace;$r.loadNamespaces;$r.loadLanguages;const zV="Approve",VV="Approved",GV="Copy",KV="Deny",XV="Denied",YV="Expand",ZV="Retry",JV="Start",QV="Yes",e6="No",t6="and",r6="Hide",n6="Back",i6="Forward",a6="Close",s6="Next",o6="Cancel",u6="Yes, Submit",l6="Dismiss",c6="Save",f6="Search",d6="Loading",h6={completed:"Authentication completed","signing-in":"Signing in...","signing-out":"Signing out...",unauthorized:"You're not authorized to access this page."},p6={attachments:"Attachments",label:"Click here to browse your PC or drop files to upload","created-by-on-time":"by {{createdBy}} on {{date}}","files-too-large":"The following files exceed the maximum size of {{maxSize}}: {{files}}","max-size-label":"Max file size is 10MB with accepted file formats of: JPG (JPEG), PNG, PDF, GIF, DOC/X, XLS/X, CSV"},g6={disclaimer:"Draft","create-user-title":"Add New User","create-ticket-title":"Support Ticket"},m6={"assets-counter":"{{assets}} locations","select-assets":"Select Locations","select-all":"Select All","assets-search-placeholder":"Search by Site or Asset Name...","no-assets-description":"This site contains no assets, click NEXT to continue.","asset-item":"Asset item","view-ticket":"View Ticket"},v6="Active",y6="Phone",b6="Email",_6="Account",x6="Accounts",w6="Role",T6="Roles",S6="Option",C6="Options",E6="From",O6="To",A6="More",I6="Logout",R6="Refresh",D6={404:{title:"This Page could not be found.",detail:"The page you are after doesn't exist, or no longer exists. Check out the homepage instead.",button:"go to homepage"},approve:zV,approved:VV,copy:GV,deny:KV,denied:XV,expand:YV,"approve-all":"Approve All","deny-all":"Deny All",retry:ZV,start:JV,yes:QV,no:e6,and:t6,"error-title":"Error:","error-message":"An error occurred, please try again.","enhanced-error-message":"We are unable to display the relevant ticket information. For further assistance, please share the below details with us via <1>GlobalPortal@digitalrealty.com</1>","error-api":"API is not responding",hide:r6,"edit-details":"Edit Details",back:n6,"go-back":"Go Back",forward:i6,close:a6,next:s6,cancel:o6,submit:u6,dismiss:l6,"sort-by":"Sort by",save:c6,"save-changes":"Save Changes","changes-saved":"Changes Saved","changes-not-saved":"Changes Can not Be Saved","try-again":"Try again","request-error-message":"We are unable to process your request. Please, try again or reach out to us for further assistance. We apologize for the inconvenience. Your Digital Realty Team",search:f6,"close-button":"Close Button","open-button":"Open Button",loading:d6,"app-loading":"Loading...","redirect-soon":"You will be redirected soon.",auth:h6,dropzone:p6,draft:g6,"cancel-dialog":{title:"Are you sure do you want to cancel?",text:"All the details provided will be lost.",dismiss:"Dismiss",cancel:{"add-user":"Cancel Adding User","create-ticket":"Request Cancellation"},"cancel-ticket-creation":{title:"Are you sure you want to proceed? All details provided will be lost.",yes:"Yes",no:"No"}},tickets:m6,"view-all":"View all","view-attachment-button":"view attachment button","download-attachment-button":"download attachment button","hide-button":"hide button","close-buton":"close buton","previous-button":"previous button","next-button":"next button",active:v6,"notifications-button":"Notifications Button","expand-navbar-button":"Expand Navbar Button","search-field":"Search Field","search-icon":"Search Icon","search-button":"Search Button",phone:y6,email:b6,"datagrid-no-rows":"No data to display","no-attachments":"No attachments",account_one:_6,account_other:x6,role_one:w6,role_other:T6,"last-update":"Last Update","no-comments":"No Comments",option_one:S6,option_other:C6,from:E6,to:O6,"email-helper-text":"Enter email addresses separated by a comma, semicolon or the Enter key.","master-account":"Master Account","master-account-label":"Open the Account Selector","unsaved-changes-title":"Attention","unsaved-changes-message":"There are unsaved changes on this page, save or discard them before leaving.",more:A6,"not-implemented":"Not Implemented",logout:I6,refresh:R6,"record-version":{"record-has-been-updated":"Record has been updated","refresh-page":"Refresh the page to see the latest record."},"view-list":"View List"},M6="Chart Overview",P6="DCIM data for the past 7 days shown below. Click a chart to view details and change the range.",L6={title:"Alerts","configure-alerts-button":"Configure Alerts",types:{title:"Alert Types",all:"All",critical:"Critical",custom:"Custom",history:"History"},categories:{title:"Alert Categories",all:"All",power:"Power",environmental:"Environmental",auxiliary:"Auxiliary"},details:{title:"Alert Instances","alert-number":"Alert Number",site:"Site",location:"Location","total-load":"Total Load","threshold-value":"Threshold Value","affected-ci":"Affected CI",description:"Description","alert-timeline-summary":"Alert Timeline Summary","alert-generated-on":"Alert Generated On",duration:"Duration",error:"Server error fetching alert data"},definitions:{title:"Alert Definitions","warning-message":"Ensure your mobile service provider does not block automated text messaging if you subscribe to that notification method."}},N6="Cancel",F6={"no-dcim-data-available":"No DCIM data available for this location","no-dcim-data-available-chart":"No DCIM data available for this chart",title:M6,subtitle:P6,"dcim-chart":{"load-fail":{title:"Charts could not be loaded.",message:"The charts for this location are currently not available. Check back later, or contact support."},"toggle-device":"Toggle {{id}}","y-axis-metric":"Y-Axis Metric",timezone:{utc:"Time shown in Coordinated Universal Time (UTC)"},"show-alert-data":"Show Alert Data","date-range":{from:"From",to:"to",errors:{"from-required":"Select a from date.","to-required":"Select a to date.",future:"Select a date no later than today.","to-before-from":"Select a to date on or after the from date."}},utc:"UTC",increments:{label:"Increments",day:"1 Day",hour:"60 Minutes","15-minute":"15 Minutes","5-minute":"5 Minutes",minute:"1 Minute"},view:{trend:"Trend",daily:"Daily"},"point-value":{current:"Value","daily-avg":"Daily Avg","daily-min":"Daily Min","daily-max":"Daily Max",alert:"[{{type}}] {{category}} alert"},"device-selector":{label:"Devices on Chart","deselect-all":"Deselect all","select-all":"Select all"},export:{"file-name":"{{view}} Data for {{location}} - {{site}}",header:{deviceDataId:"Device ID",deviceName:"Device Name",date:"Date",minValue:"Min",maxValue:"Max",pointValue:"Average"}}},alerts:L6,"customize-alert-dialog":{title:"Customize Alert",message:"You can choose to customize this alert. Digital Realty will not take actions on custom alerts.","it-load-level":"IT Load Level",threshold:"Threshold","total-ITkW":"TotalITkW >","email-alerts":"Email Alerts","sms-alerts":"SMS Alerts","bottom-message":"Ensure your mobile service provider does not block automated text messaging if you subscribe to that notification method.","cancel-button":"Cancel","save-button":"Save","success-updated":"Alert updated","success-custom-created":"Custom alert created","success-custom-updated":"Custom alert updated","success-critical-updated":"Critical alert updated","server-error":"Server Error","threshold-validation-error":"Threshold is outside the allowed range","critical-enrollment-operator-and-threshold-empty":"Cannot update Custom Alert threshold because Parent has empty comparison operator and threshold"},"alert-instance":{alertId:"Alert Id",site:"Site",location:"Location",alertName:"Alert Name",deviceName:"Device Name",functionValue:"{{device}} Current Value",alertTimeStamp:"Opened",alertType:"Alert Type",configurationItem:"Configuration Item"},"alert-definition":{deviceName:"Device Name",threshold:"Threshold",liveValue:"Live Value",timeStamp:"Time Stamp"},"alert-list":{"sort-by":"Sort By",deviceName:"Device Name",functionValue:"Device Function",threshold:"Threshold"},cancel:N6},k6="Notifications",j6={planned_site_maintenance:"Planned Site Maintenance",emergency_repair:"Emergency Repair",dcim_alert:"DCIM Alert",service_ticket_update:"Service Ticket Update"},$6="Today",U6="Earlier",q6={notifications:k6,type:j6,"type-group":{planned_site_maintenance:"$t(type.planned_site_maintenance)",emergency_repair:"$t(type.emergency_repair)s",dcim_alert:"$t(type.dcim_alert)s",service_ticket_update:"$t(type.service_ticket_update)s"},"none-yet":"No notifications yet.","group-by":{type:"Sort by type",date:"Sort by type"},today:$6,earlier:U6,"mark-all-read":"Mark All Read","mark-all-read-confirmation-message":"Are you sure you want to mark all notifications as read?","filter-by-type":"Filter by type","filter-by-date":"Filter by date","filter-list":"Filter List","clear-all":"Clear All",delete:"Are you sure you want to delete this notification?"};$r.use(iV).init({resources:{en:{common:D6,location:F6,notifications:q6}},interpolation:{escapeValue:!1},lng:"en"});const qae=async t=>{},H6={defaultOptions:{queries:{refetchOnWindowFocus:!1,retry:!1}}},Hae=new uq(H6);var Ep,j1;function So(){return j1||(j1=1,Ep=TypeError),Ep}const W6={},B6=Object.freeze(Object.defineProperty({__proto__:null,default:W6},Symbol.toStringTag,{value:"Module"})),z6=qU(B6);var Op,$1;function Dd(){if($1)return Op;$1=1;var t=typeof Map=="function"&&Map.prototype,e=Object.getOwnPropertyDescriptor&&t?Object.getOwnPropertyDescriptor(Map.prototype,"size"):null,r=t&&e&&typeof e.get=="function"?e.get:null,n=t&&Map.prototype.forEach,i=typeof Set=="function"&&Set.prototype,a=Object.getOwnPropertyDescriptor&&i?Object.getOwnPropertyDescriptor(Set.prototype,"size"):null,s=i&&a&&typeof a.get=="function"?a.get:null,o=i&&Set.prototype.forEach,l=typeof WeakMap=="function"&&WeakMap.prototype,c=l?WeakMap.prototype.has:null,d=typeof WeakSet=="function"&&WeakSet.prototype,h=d?WeakSet.prototype.has:null,g=typeof WeakRef=="function"&&WeakRef.prototype,m=g?WeakRef.prototype.deref:null,v=Boolean.prototype.valueOf,b=Object.prototype.toString,y=Function.prototype.toString,x=String.prototype.match,w=String.prototype.slice,S=String.prototype.replace,E=String.prototype.toUpperCase,C=String.prototype.toLowerCase,I=RegExp.prototype.test,T=Array.prototype.concat,D=Array.prototype.join,P=Array.prototype.slice,L=Math.floor,F=typeof BigInt=="function"?BigInt.prototype.valueOf:null,H=Object.getOwnPropertySymbols,X=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Symbol.prototype.toString:null,ee=typeof Symbol=="function"&&typeof Symbol.iterator=="object",J=typeof Symbol=="function"&&Symbol.toStringTag&&(typeof Symbol.toStringTag===ee||!0)?Symbol.toStringTag:null,te=Object.prototype.propertyIsEnumerable,ce=(typeof Reflect=="function"?Reflect.getPrototypeOf:Object.getPrototypeOf)||([].__proto__===Array.prototype?function(z){return z.__proto__}:null);function B(z,V){if(z===1/0||z===-1/0||z!==z||z&&z>-1e3&&z<1e3||I.call(/e/,V))return V;var at=/[0-9](?=(?:[0-9]{3})+(?![0-9]))/g;if(typeof z=="number"){var xt=z<0?-L(-z):L(z);if(xt!==z){var Dt=String(xt),ke=w.call(V,Dt.length+1);return S.call(Dt,at,"$&_")+"."+S.call(S.call(ke,/([0-9]{3})/g,"$&_"),/_$/,"")}}return S.call(V,at,"$&_")}var ae=z6,Ce=ae.custom,Ae=Rt(Ce)?Ce:null,ve={__proto__:null,double:'"',single:"'"},ct={__proto__:null,double:/(["\\])/g,single:/(['\\])/g};Op=function z(V,at,xt,Dt){var ke=at||{};if(Nt(ke,"quoteStyle")&&!Nt(ve,ke.quoteStyle))throw new TypeError('option "quoteStyle" must be "single" or "double"');if(Nt(ke,"maxStringLength")&&(typeof ke.maxStringLength=="number"?ke.maxStringLength<0&&ke.maxStringLength!==1/0:ke.maxStringLength!==null))throw new TypeError('option "maxStringLength", if provided, must be a positive integer, Infinity, or `null`');var qr=Nt(ke,"customInspect")?ke.customInspect:!0;if(typeof qr!="boolean"&&qr!=="symbol")throw new TypeError("option \"customInspect\", if provided, must be `true`, `false`, or `'symbol'`");if(Nt(ke,"indent")&&ke.indent!==null&&ke.indent!==" "&&!(parseInt(ke.indent,10)===ke.indent&&ke.indent>0))throw new TypeError('option "indent" must be "\\t", an integer > 0, or `null`');if(Nt(ke,"numericSeparator")&&typeof ke.numericSeparator!="boolean")throw new TypeError('option "numericSeparator", if provided, must be `true` or `false`');var On=ke.numericSeparator;if(typeof V>"u")return"undefined";if(V===null)return"null";if(typeof V=="boolean")return V?"true":"false";if(typeof V=="string")return Qe(V,ke);if(typeof V=="number"){if(V===0)return 1/0/V>0?"0":"-0";var Tr=String(V);return On?B(V,Tr):Tr}if(typeof V=="bigint"){var An=String(V)+"n";return On?B(V,An):An}var Vi=typeof ke.depth>"u"?5:ke.depth;if(typeof xt>"u"&&(xt=0),xt>=Vi&&Vi>0&&typeof V=="object")return ht(V)?"[Array]":"[Object]";var hn=Rr(ke,xt);if(typeof Dt>"u")Dt=[];else if(Yr(Dt,V)>=0)return"[Circular]";function br(gt,st,Wt){if(st&&(Dt=P.call(Dt),Dt.push(st)),Wt){var Vn={depth:ke.depth};return Nt(ke,"quoteStyle")&&(Vn.quoteStyle=ke.quoteStyle),z(gt,Vn,xt+1,Dt)}return z(gt,ke,xt+1,Dt)}if(typeof V=="function"&&!Se(V)){var Es=Lr(V),Os=zn(V,br);return"[Function"+(Es?": "+Es:" (anonymous)")+"]"+(Os.length>0?" { "+D.call(Os,", ")+" }":"")}if(Rt(V)){var k=ee?S.call(String(V),/^(Symbol\(.*\))_[^)]*$/,"$1"):X.call(V);return typeof V=="object"&&!ee?Ct(k):k}if(Re(V)){for(var U="<"+C.call(String(V.nodeName)),G=V.attributes||[],re=0;re<G.length;re++)U+=" "+G[re].name+"="+Ge(Le(G[re].value),"double",ke);return U+=">",V.childNodes&&V.childNodes.length&&(U+="..."),U+="</"+C.call(String(V.nodeName))+">",U}if(ht(V)){if(V.length===0)return"[]";var oe=zn(V,br);return hn&&!_i(oe)?"["+En(oe,hn)+"]":"[ "+D.call(oe,", ")+" ]"}if(xe(V)){var we=zn(V,br);return!("cause"in Error.prototype)&&"cause"in V&&!te.call(V,"cause")?"{ ["+String(V)+"] "+D.call(T.call("[cause]: "+br(V.cause),we),", ")+" }":we.length===0?"["+String(V)+"]":"{ ["+String(V)+"] "+D.call(we,", ")+" }"}if(typeof V=="object"&&qr){if(Ae&&typeof V[Ae]=="function"&&ae)return ae(V,{depth:Vi-xt});if(qr!=="symbol"&&typeof V.inspect=="function")return V.inspect()}if(fr(V)){var De=[];return n&&n.call(V,function(gt,st){De.push(br(st,V,!0)+" => "+br(gt,V))}),Ur("Map",r.call(V),De,hn)}if(ue(V)){var he=[];return o&&o.call(V,function(gt){he.push(br(gt,V))}),Ur("Set",s.call(V),he,hn)}if(W(V))return Zr("WeakMap");if(_e(V))return Zr("WeakSet");if(se(V))return Zr("WeakRef");if(Oe(V))return Ct(br(Number(V)));if(ft(V))return Ct(br(F.call(V)));if(Je(V))return Ct(v.call(V));if(Ze(V))return Ct(br(String(V)));if(typeof window<"u"&&V===window)return"{ [object Window] }";if(typeof globalThis<"u"&&V===globalThis||typeof pi<"u"&&V===pi)return"{ [object globalThis] }";if(!We(V)&&!Se(V)){var me=zn(V,br),de=ce?ce(V)===Object.prototype:V instanceof Object||V.constructor===Object,be=V instanceof Object?"":"null prototype",Fe=!de&&J&&Object(V)===V&&J in V?w.call(Ot(V),8,-1):be?"Object":"",et=de||typeof V.constructor!="function"?"":V.constructor.name?V.constructor.name+" ":"",er=et+(Fe||be?"["+D.call(T.call([],Fe||[],be||[]),": ")+"] ":"");return me.length===0?er+"{}":hn?er+"{"+En(me,hn)+"}":er+"{ "+D.call(me,", ")+" }"}return String(V)};function Ge(z,V,at){var xt=at.quoteStyle||V,Dt=ve[xt];return Dt+z+Dt}function Le(z){return S.call(String(z),/"/g,""")}function Ue(z){return!J||!(typeof z=="object"&&(J in z||typeof z[J]<"u"))}function ht(z){return Ot(z)==="[object Array]"&&Ue(z)}function We(z){return Ot(z)==="[object Date]"&&Ue(z)}function Se(z){return Ot(z)==="[object RegExp]"&&Ue(z)}function xe(z){return Ot(z)==="[object Error]"&&Ue(z)}function Ze(z){return Ot(z)==="[object String]"&&Ue(z)}function Oe(z){return Ot(z)==="[object Number]"&&Ue(z)}function Je(z){return Ot(z)==="[object Boolean]"&&Ue(z)}function Rt(z){if(ee)return z&&typeof z=="object"&&z instanceof Symbol;if(typeof z=="symbol")return!0;if(!z||typeof z!="object"||!X)return!1;try{return X.call(z),!0}catch{}return!1}function ft(z){if(!z||typeof z!="object"||!F)return!1;try{return F.call(z),!0}catch{}return!1}var Ne=Object.prototype.hasOwnProperty||function(z){return z in this};function Nt(z,V){return Ne.call(z,V)}function Ot(z){return b.call(z)}function Lr(z){if(z.name)return z.name;var V=x.call(y.call(z),/^function\s*([\w$]+)/);return V?V[1]:null}function Yr(z,V){if(z.indexOf)return z.indexOf(V);for(var at=0,xt=z.length;at<xt;at++)if(z[at]===V)return at;return-1}function fr(z){if(!r||!z||typeof z!="object")return!1;try{r.call(z);try{s.call(z)}catch{return!0}return z instanceof Map}catch{}return!1}function W(z){if(!c||!z||typeof z!="object")return!1;try{c.call(z,c);try{h.call(z,h)}catch{return!0}return z instanceof WeakMap}catch{}return!1}function se(z){if(!m||!z||typeof z!="object")return!1;try{return m.call(z),!0}catch{}return!1}function ue(z){if(!s||!z||typeof z!="object")return!1;try{s.call(z);try{r.call(z)}catch{return!0}return z instanceof Set}catch{}return!1}function _e(z){if(!h||!z||typeof z!="object")return!1;try{h.call(z,h);try{c.call(z,c)}catch{return!0}return z instanceof WeakSet}catch{}return!1}function Re(z){return!z||typeof z!="object"?!1:typeof HTMLElement<"u"&&z instanceof HTMLElement?!0:typeof z.nodeName=="string"&&typeof z.getAttribute=="function"}function Qe(z,V){if(z.length>V.maxStringLength){var at=z.length-V.maxStringLength,xt="... "+at+" more character"+(at>1?"s":"");return Qe(w.call(z,0,V.maxStringLength),V)+xt}var Dt=ct[V.quoteStyle||"single"];Dt.lastIndex=0;var ke=S.call(S.call(z,Dt,"\\$1"),/[\x00-\x1f]/g,St);return Ge(ke,"single",V)}function St(z){var V=z.charCodeAt(0),at={8:"b",9:"t",10:"n",12:"f",13:"r"}[V];return at?"\\"+at:"\\x"+(V<16?"0":"")+E.call(V.toString(16))}function Ct(z){return"Object("+z+")"}function Zr(z){return z+" { ? }"}function Ur(z,V,at,xt){var Dt=xt?En(at,xt):D.call(at,", ");return z+" ("+V+") {"+Dt+"}"}function _i(z){for(var V=0;V<z.length;V++)if(Yr(z[V],`
|
|
70
|
+
`)>=0)return!1;return!0}function Rr(z,V){var at;if(z.indent===" ")at=" ";else if(typeof z.indent=="number"&&z.indent>0)at=D.call(Array(z.indent+1)," ");else return null;return{base:at,prev:D.call(Array(V+1),at)}}function En(z,V){if(z.length===0)return"";var at=`
|
|
71
|
+
`+V.prev+V.base;return at+D.call(z,","+at)+`
|
|
72
|
+
`+V.prev}function zn(z,V){var at=ht(z),xt=[];if(at){xt.length=z.length;for(var Dt=0;Dt<z.length;Dt++)xt[Dt]=Nt(z,Dt)?V(z[Dt],z):""}var ke=typeof H=="function"?H(z):[],qr;if(ee){qr={};for(var On=0;On<ke.length;On++)qr["$"+ke[On]]=ke[On]}for(var Tr in z)Nt(z,Tr)&&(at&&String(Number(Tr))===Tr&&Tr<z.length||ee&&qr["$"+Tr]instanceof Symbol||(I.call(/[^\w$]/,Tr)?xt.push(V(Tr,z)+": "+V(z[Tr],z)):xt.push(Tr+": "+V(z[Tr],z))));if(typeof H=="function")for(var An=0;An<ke.length;An++)te.call(z,ke[An])&&xt.push("["+V(ke[An])+"]: "+V(z[ke[An]],z));return xt}return Op}var Ap,U1;function V6(){if(U1)return Ap;U1=1;var t=Dd(),e=So(),r=function(o,l,c){for(var d=o,h;(h=d.next)!=null;d=h)if(h.key===l)return d.next=h.next,c||(h.next=o.next,o.next=h),h},n=function(o,l){if(o){var c=r(o,l);return c&&c.value}},i=function(o,l,c){var d=r(o,l);d?d.value=c:o.next={key:l,next:o.next,value:c}},a=function(o,l){return o?!!r(o,l):!1},s=function(o,l){if(o)return r(o,l,!0)};return Ap=function(){var l,c={assert:function(d){if(!c.has(d))throw new e("Side channel does not contain "+t(d))},delete:function(d){var h=s(l,d);return h&&l&&!l.next&&(l=void 0),!!h},get:function(d){return n(l,d)},has:function(d){return a(l,d)},set:function(d,h){l||(l={next:void 0}),i(l,d,h)}};return c},Ap}var Ip,q1;function aD(){return q1||(q1=1,Ip=Object),Ip}var Rp,H1;function G6(){return H1||(H1=1,Rp=Error),Rp}var Dp,W1;function K6(){return W1||(W1=1,Dp=EvalError),Dp}var Mp,B1;function X6(){return B1||(B1=1,Mp=RangeError),Mp}var Pp,z1;function Y6(){return z1||(z1=1,Pp=ReferenceError),Pp}var Lp,V1;function Z6(){return V1||(V1=1,Lp=SyntaxError),Lp}var Np,G1;function J6(){return G1||(G1=1,Np=URIError),Np}var Fp,K1;function Q6(){return K1||(K1=1,Fp=Math.abs),Fp}var kp,X1;function e5(){return X1||(X1=1,kp=Math.floor),kp}var jp,Y1;function t5(){return Y1||(Y1=1,jp=Math.max),jp}var $p,Z1;function r5(){return Z1||(Z1=1,$p=Math.min),$p}var Up,J1;function n5(){return J1||(J1=1,Up=Math.pow),Up}var qp,Q1;function i5(){return Q1||(Q1=1,qp=Math.round),qp}var Hp,eT;function a5(){return eT||(eT=1,Hp=Number.isNaN||function(e){return e!==e}),Hp}var Wp,tT;function s5(){if(tT)return Wp;tT=1;var t=a5();return Wp=function(r){return t(r)||r===0?r:r<0?-1:1},Wp}var Bp,rT;function o5(){return rT||(rT=1,Bp=Object.getOwnPropertyDescriptor),Bp}var zp,nT;function sD(){if(nT)return zp;nT=1;var t=o5();if(t)try{t([],"length")}catch{t=null}return zp=t,zp}var Vp,iT;function u5(){if(iT)return Vp;iT=1;var t=Object.defineProperty||!1;if(t)try{t({},"a",{value:1})}catch{t=!1}return Vp=t,Vp}var Gp,aT;function l5(){return aT||(aT=1,Gp=function(){if(typeof Symbol!="function"||typeof Object.getOwnPropertySymbols!="function")return!1;if(typeof Symbol.iterator=="symbol")return!0;var e={},r=Symbol("test"),n=Object(r);if(typeof r=="string"||Object.prototype.toString.call(r)!=="[object Symbol]"||Object.prototype.toString.call(n)!=="[object Symbol]")return!1;var i=42;e[r]=i;for(var a in e)return!1;if(typeof Object.keys=="function"&&Object.keys(e).length!==0||typeof Object.getOwnPropertyNames=="function"&&Object.getOwnPropertyNames(e).length!==0)return!1;var s=Object.getOwnPropertySymbols(e);if(s.length!==1||s[0]!==r||!Object.prototype.propertyIsEnumerable.call(e,r))return!1;if(typeof Object.getOwnPropertyDescriptor=="function"){var o=Object.getOwnPropertyDescriptor(e,r);if(o.value!==i||o.enumerable!==!0)return!1}return!0}),Gp}var Kp,sT;function c5(){if(sT)return Kp;sT=1;var t=typeof Symbol<"u"&&Symbol,e=l5();return Kp=function(){return typeof t!="function"||typeof Symbol!="function"||typeof t("foo")!="symbol"||typeof Symbol("bar")!="symbol"?!1:e()},Kp}var Xp,oT;function oD(){return oT||(oT=1,Xp=typeof Reflect<"u"&&Reflect.getPrototypeOf||null),Xp}var Yp,uT;function uD(){if(uT)return Yp;uT=1;var t=aD();return Yp=t.getPrototypeOf||null,Yp}var Zp,lT;function f5(){if(lT)return Zp;lT=1;var t="Function.prototype.bind called on incompatible ",e=Object.prototype.toString,r=Math.max,n="[object Function]",i=function(l,c){for(var d=[],h=0;h<l.length;h+=1)d[h]=l[h];for(var g=0;g<c.length;g+=1)d[g+l.length]=c[g];return d},a=function(l,c){for(var d=[],h=c,g=0;h<l.length;h+=1,g+=1)d[g]=l[h];return d},s=function(o,l){for(var c="",d=0;d<o.length;d+=1)c+=o[d],d+1<o.length&&(c+=l);return c};return Zp=function(l){var c=this;if(typeof c!="function"||e.apply(c)!==n)throw new TypeError(t+c);for(var d=a(arguments,1),h,g=function(){if(this instanceof h){var x=c.apply(this,i(d,arguments));return Object(x)===x?x:this}return c.apply(l,i(d,arguments))},m=r(0,c.length-d.length),v=[],b=0;b<m;b++)v[b]="$"+b;if(h=Function("binder","return function ("+s(v,",")+"){ return binder.apply(this,arguments); }")(g),c.prototype){var y=function(){};y.prototype=c.prototype,h.prototype=new y,y.prototype=null}return h},Zp}var Jp,cT;function Md(){if(cT)return Jp;cT=1;var t=f5();return Jp=Function.prototype.bind||t,Jp}var Qp,fT;function Z0(){return fT||(fT=1,Qp=Function.prototype.call),Qp}var eg,dT;function lD(){return dT||(dT=1,eg=Function.prototype.apply),eg}var tg,hT;function d5(){return hT||(hT=1,tg=typeof Reflect<"u"&&Reflect&&Reflect.apply),tg}var rg,pT;function h5(){if(pT)return rg;pT=1;var t=Md(),e=lD(),r=Z0(),n=d5();return rg=n||t.call(r,e),rg}var ng,gT;function cD(){if(gT)return ng;gT=1;var t=Md(),e=So(),r=Z0(),n=h5();return ng=function(a){if(a.length<1||typeof a[0]!="function")throw new e("a function is required");return n(t,r,a)},ng}var ig,mT;function p5(){if(mT)return ig;mT=1;var t=cD(),e=sD(),r;try{r=[].__proto__===Array.prototype}catch(s){if(!s||typeof s!="object"||!("code"in s)||s.code!=="ERR_PROTO_ACCESS")throw s}var n=!!r&&e&&e(Object.prototype,"__proto__"),i=Object,a=i.getPrototypeOf;return ig=n&&typeof n.get=="function"?t([n.get]):typeof a=="function"?function(o){return a(o==null?o:i(o))}:!1,ig}var ag,vT;function g5(){if(vT)return ag;vT=1;var t=oD(),e=uD(),r=p5();return ag=t?function(i){return t(i)}:e?function(i){if(!i||typeof i!="object"&&typeof i!="function")throw new TypeError("getProto: not an object");return e(i)}:r?function(i){return r(i)}:null,ag}var sg,yT;function m5(){if(yT)return sg;yT=1;var t=Function.prototype.call,e=Object.prototype.hasOwnProperty,r=Md();return sg=r.call(t,e),sg}var og,bT;function J0(){if(bT)return og;bT=1;var t,e=aD(),r=G6(),n=K6(),i=X6(),a=Y6(),s=Z6(),o=So(),l=J6(),c=Q6(),d=e5(),h=t5(),g=r5(),m=n5(),v=i5(),b=s5(),y=Function,x=function(Se){try{return y('"use strict"; return ('+Se+").constructor;")()}catch{}},w=sD(),S=u5(),E=function(){throw new o},C=w?(function(){try{return arguments.callee,E}catch{try{return w(arguments,"callee").get}catch{return E}}})():E,I=c5()(),T=g5(),D=uD(),P=oD(),L=lD(),F=Z0(),H={},X=typeof Uint8Array>"u"||!T?t:T(Uint8Array),ee={__proto__:null,"%AggregateError%":typeof AggregateError>"u"?t:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?t:ArrayBuffer,"%ArrayIteratorPrototype%":I&&T?T([][Symbol.iterator]()):t,"%AsyncFromSyncIteratorPrototype%":t,"%AsyncFunction%":H,"%AsyncGenerator%":H,"%AsyncGeneratorFunction%":H,"%AsyncIteratorPrototype%":H,"%Atomics%":typeof Atomics>"u"?t:Atomics,"%BigInt%":typeof BigInt>"u"?t:BigInt,"%BigInt64Array%":typeof BigInt64Array>"u"?t:BigInt64Array,"%BigUint64Array%":typeof BigUint64Array>"u"?t:BigUint64Array,"%Boolean%":Boolean,"%DataView%":typeof DataView>"u"?t:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":r,"%eval%":eval,"%EvalError%":n,"%Float16Array%":typeof Float16Array>"u"?t:Float16Array,"%Float32Array%":typeof Float32Array>"u"?t:Float32Array,"%Float64Array%":typeof Float64Array>"u"?t:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry>"u"?t:FinalizationRegistry,"%Function%":y,"%GeneratorFunction%":H,"%Int8Array%":typeof Int8Array>"u"?t:Int8Array,"%Int16Array%":typeof Int16Array>"u"?t:Int16Array,"%Int32Array%":typeof Int32Array>"u"?t:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":I&&T?T(T([][Symbol.iterator]())):t,"%JSON%":typeof JSON=="object"?JSON:t,"%Map%":typeof Map>"u"?t:Map,"%MapIteratorPrototype%":typeof Map>"u"||!I||!T?t:T(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":e,"%Object.getOwnPropertyDescriptor%":w,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?t:Promise,"%Proxy%":typeof Proxy>"u"?t:Proxy,"%RangeError%":i,"%ReferenceError%":a,"%Reflect%":typeof Reflect>"u"?t:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set>"u"?t:Set,"%SetIteratorPrototype%":typeof Set>"u"||!I||!T?t:T(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?t:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":I&&T?T(""[Symbol.iterator]()):t,"%Symbol%":I?Symbol:t,"%SyntaxError%":s,"%ThrowTypeError%":C,"%TypedArray%":X,"%TypeError%":o,"%Uint8Array%":typeof Uint8Array>"u"?t:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?t:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array>"u"?t:Uint16Array,"%Uint32Array%":typeof Uint32Array>"u"?t:Uint32Array,"%URIError%":l,"%WeakMap%":typeof WeakMap>"u"?t:WeakMap,"%WeakRef%":typeof WeakRef>"u"?t:WeakRef,"%WeakSet%":typeof WeakSet>"u"?t:WeakSet,"%Function.prototype.call%":F,"%Function.prototype.apply%":L,"%Object.defineProperty%":S,"%Object.getPrototypeOf%":D,"%Math.abs%":c,"%Math.floor%":d,"%Math.max%":h,"%Math.min%":g,"%Math.pow%":m,"%Math.round%":v,"%Math.sign%":b,"%Reflect.getPrototypeOf%":P};if(T)try{null.error}catch(Se){var J=T(T(Se));ee["%Error.prototype%"]=J}var te=function Se(xe){var Ze;if(xe==="%AsyncFunction%")Ze=x("async function () {}");else if(xe==="%GeneratorFunction%")Ze=x("function* () {}");else if(xe==="%AsyncGeneratorFunction%")Ze=x("async function* () {}");else if(xe==="%AsyncGenerator%"){var Oe=Se("%AsyncGeneratorFunction%");Oe&&(Ze=Oe.prototype)}else if(xe==="%AsyncIteratorPrototype%"){var Je=Se("%AsyncGenerator%");Je&&T&&(Ze=T(Je.prototype))}return ee[xe]=Ze,Ze},ce={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},B=Md(),ae=m5(),Ce=B.call(F,Array.prototype.concat),Ae=B.call(L,Array.prototype.splice),ve=B.call(F,String.prototype.replace),ct=B.call(F,String.prototype.slice),Ge=B.call(F,RegExp.prototype.exec),Le=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,Ue=/\\(\\)?/g,ht=function(xe){var Ze=ct(xe,0,1),Oe=ct(xe,-1);if(Ze==="%"&&Oe!=="%")throw new s("invalid intrinsic syntax, expected closing `%`");if(Oe==="%"&&Ze!=="%")throw new s("invalid intrinsic syntax, expected opening `%`");var Je=[];return ve(xe,Le,function(Rt,ft,Ne,Nt){Je[Je.length]=Ne?ve(Nt,Ue,"$1"):ft||Rt}),Je},We=function(xe,Ze){var Oe=xe,Je;if(ae(ce,Oe)&&(Je=ce[Oe],Oe="%"+Je[0]+"%"),ae(ee,Oe)){var Rt=ee[Oe];if(Rt===H&&(Rt=te(Oe)),typeof Rt>"u"&&!Ze)throw new o("intrinsic "+xe+" exists, but is not available. Please file an issue!");return{alias:Je,name:Oe,value:Rt}}throw new s("intrinsic "+xe+" does not exist!")};return og=function(xe,Ze){if(typeof xe!="string"||xe.length===0)throw new o("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof Ze!="boolean")throw new o('"allowMissing" argument must be a boolean');if(Ge(/^%?[^%]*%?$/,xe)===null)throw new s("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var Oe=ht(xe),Je=Oe.length>0?Oe[0]:"",Rt=We("%"+Je+"%",Ze),ft=Rt.name,Ne=Rt.value,Nt=!1,Ot=Rt.alias;Ot&&(Je=Ot[0],Ae(Oe,Ce([0,1],Ot)));for(var Lr=1,Yr=!0;Lr<Oe.length;Lr+=1){var fr=Oe[Lr],W=ct(fr,0,1),se=ct(fr,-1);if((W==='"'||W==="'"||W==="`"||se==='"'||se==="'"||se==="`")&&W!==se)throw new s("property names with quotes must have matching quotes");if((fr==="constructor"||!Yr)&&(Nt=!0),Je+="."+fr,ft="%"+Je+"%",ae(ee,ft))Ne=ee[ft];else if(Ne!=null){if(!(fr in Ne)){if(!Ze)throw new o("base intrinsic for "+xe+" exists, but the property is not available.");return}if(w&&Lr+1>=Oe.length){var ue=w(Ne,fr);Yr=!!ue,Yr&&"get"in ue&&!("originalValue"in ue.get)?Ne=ue.get:Ne=Ne[fr]}else Yr=ae(Ne,fr),Ne=Ne[fr];Yr&&!Nt&&(ee[ft]=Ne)}}return Ne},og}var ug,_T;function fD(){if(_T)return ug;_T=1;var t=J0(),e=cD(),r=e([t("%String.prototype.indexOf%")]);return ug=function(i,a){var s=t(i,!!a);return typeof s=="function"&&r(i,".prototype.")>-1?e([s]):s},ug}var lg,xT;function dD(){if(xT)return lg;xT=1;var t=J0(),e=fD(),r=Dd(),n=So(),i=t("%Map%",!0),a=e("Map.prototype.get",!0),s=e("Map.prototype.set",!0),o=e("Map.prototype.has",!0),l=e("Map.prototype.delete",!0),c=e("Map.prototype.size",!0);return lg=!!i&&function(){var h,g={assert:function(m){if(!g.has(m))throw new n("Side channel does not contain "+r(m))},delete:function(m){if(h){var v=l(h,m);return c(h)===0&&(h=void 0),v}return!1},get:function(m){if(h)return a(h,m)},has:function(m){return h?o(h,m):!1},set:function(m,v){h||(h=new i),s(h,m,v)}};return g},lg}var cg,wT;function v5(){if(wT)return cg;wT=1;var t=J0(),e=fD(),r=Dd(),n=dD(),i=So(),a=t("%WeakMap%",!0),s=e("WeakMap.prototype.get",!0),o=e("WeakMap.prototype.set",!0),l=e("WeakMap.prototype.has",!0),c=e("WeakMap.prototype.delete",!0);return cg=a?function(){var h,g,m={assert:function(v){if(!m.has(v))throw new i("Side channel does not contain "+r(v))},delete:function(v){if(a&&v&&(typeof v=="object"||typeof v=="function")){if(h)return c(h,v)}else if(n&&g)return g.delete(v);return!1},get:function(v){return a&&v&&(typeof v=="object"||typeof v=="function")&&h?s(h,v):g&&g.get(v)},has:function(v){return a&&v&&(typeof v=="object"||typeof v=="function")&&h?l(h,v):!!g&&g.has(v)},set:function(v,b){a&&v&&(typeof v=="object"||typeof v=="function")?(h||(h=new a),o(h,v,b)):n&&(g||(g=n()),g.set(v,b))}};return m}:n,cg}var fg,TT;function hD(){if(TT)return fg;TT=1;var t=So(),e=Dd(),r=V6(),n=dD(),i=v5(),a=i||n||r;return fg=function(){var o,l={assert:function(c){if(!l.has(c)){var d=c&&Object(c)===c?"the given object key":e(c);throw new t("Side channel does not contain "+d)}},delete:function(c){return!!o&&o.delete(c)},get:function(c){return o&&o.get(c)},has:function(c){return!!o&&o.has(c)},set:function(c,d){o||(o=a()),o.set(c,d)}};return l},fg}var dg,ST;function Q0(){if(ST)return dg;ST=1;var t=String.prototype.replace,e=/%20/g,r={RFC1738:"RFC1738",RFC3986:"RFC3986"};return dg={default:r.RFC3986,formatters:{RFC1738:function(n){return t.call(n,e,"+")},RFC3986:function(n){return String(n)}},RFC1738:r.RFC1738,RFC3986:r.RFC3986},dg}var hg,CT;function pD(){if(CT)return hg;CT=1;var t=Q0(),e=hD(),r=Object.prototype.hasOwnProperty,n=Array.isArray,i=e(),a=function(T,D){return i.set(T,D),T},s=function(T){return i.has(T)},o=function(T){return i.get(T)},l=function(T,D){i.set(T,D)},c=(function(){for(var I=[],T=0;T<256;++T)I[I.length]="%"+((T<16?"0":"")+T.toString(16)).toUpperCase();return I})(),d=function(T){for(;T.length>1;){var D=T.pop(),P=D.obj[D.prop];if(n(P)){for(var L=[],F=0;F<P.length;++F)typeof P[F]<"u"&&(L[L.length]=P[F]);D.obj[D.prop]=L}}},h=function(T,D){for(var P=D&&D.plainObjects?{__proto__:null}:{},L=0;L<T.length;++L)typeof T[L]<"u"&&(P[L]=T[L]);return P},g=function I(T,D,P){if(!D)return T;if(typeof D!="object"&&typeof D!="function"){if(n(T)){var L=T.length;if(P&&typeof P.arrayLimit=="number"&&L>P.arrayLimit)return a(h(T.concat(D),P),L);T[L]=D}else if(T&&typeof T=="object")if(s(T)){var F=o(T)+1;T[F]=D,l(T,F)}else{if(P&&P.strictMerge)return[T,D];(P&&(P.plainObjects||P.allowPrototypes)||!r.call(Object.prototype,D))&&(T[D]=!0)}else return[T,D];return T}if(!T||typeof T!="object"){if(s(D)){for(var H=Object.keys(D),X=P&&P.plainObjects?{__proto__:null,0:T}:{0:T},ee=0;ee<H.length;ee++){var J=parseInt(H[ee],10);X[J+1]=D[H[ee]]}return a(X,o(D)+1)}var te=[T].concat(D);return P&&typeof P.arrayLimit=="number"&&te.length>P.arrayLimit?a(h(te,P),te.length-1):te}var ce=T;return n(T)&&!n(D)&&(ce=h(T,P)),n(T)&&n(D)?(D.forEach(function(B,ae){if(r.call(T,ae)){var Ce=T[ae];Ce&&typeof Ce=="object"&&B&&typeof B=="object"?T[ae]=I(Ce,B,P):T[T.length]=B}else T[ae]=B}),T):Object.keys(D).reduce(function(B,ae){var Ce=D[ae];if(r.call(B,ae)?B[ae]=I(B[ae],Ce,P):B[ae]=Ce,s(D)&&!s(B)&&a(B,o(D)),s(B)){var Ae=parseInt(ae,10);String(Ae)===ae&&Ae>=0&&Ae>o(B)&&l(B,Ae)}return B},ce)},m=function(T,D){return Object.keys(D).reduce(function(P,L){return P[L]=D[L],P},T)},v=function(I,T,D){var P=I.replace(/\+/g," ");if(D==="iso-8859-1")return P.replace(/%[0-9a-f]{2}/gi,unescape);try{return decodeURIComponent(P)}catch{return P}},b=1024,y=function(T,D,P,L,F){if(T.length===0)return T;var H=T;if(typeof T=="symbol"?H=Symbol.prototype.toString.call(T):typeof T!="string"&&(H=String(T)),P==="iso-8859-1")return escape(H).replace(/%u[0-9a-f]{4}/gi,function(ae){return"%26%23"+parseInt(ae.slice(2),16)+"%3B"});for(var X="",ee=0;ee<H.length;ee+=b){for(var J=H.length>=b?H.slice(ee,ee+b):H,te=[],ce=0;ce<J.length;++ce){var B=J.charCodeAt(ce);if(B===45||B===46||B===95||B===126||B>=48&&B<=57||B>=65&&B<=90||B>=97&&B<=122||F===t.RFC1738&&(B===40||B===41)){te[te.length]=J.charAt(ce);continue}if(B<128){te[te.length]=c[B];continue}if(B<2048){te[te.length]=c[192|B>>6]+c[128|B&63];continue}if(B<55296||B>=57344){te[te.length]=c[224|B>>12]+c[128|B>>6&63]+c[128|B&63];continue}ce+=1,B=65536+((B&1023)<<10|J.charCodeAt(ce)&1023),te[te.length]=c[240|B>>18]+c[128|B>>12&63]+c[128|B>>6&63]+c[128|B&63]}X+=te.join("")}return X},x=function(T){for(var D=[{obj:{o:T},prop:"o"}],P=[],L=0;L<D.length;++L)for(var F=D[L],H=F.obj[F.prop],X=Object.keys(H),ee=0;ee<X.length;++ee){var J=X[ee],te=H[J];typeof te=="object"&&te!==null&&P.indexOf(te)===-1&&(D[D.length]={obj:H,prop:J},P[P.length]=te)}return d(D),T},w=function(T){return Object.prototype.toString.call(T)==="[object RegExp]"},S=function(T){return!T||typeof T!="object"?!1:!!(T.constructor&&T.constructor.isBuffer&&T.constructor.isBuffer(T))},E=function(T,D,P,L){if(s(T)){var F=o(T)+1;return T[F]=D,l(T,F),T}var H=[].concat(T,D);return H.length>P?a(h(H,{plainObjects:L}),H.length-1):H},C=function(T,D){if(n(T)){for(var P=[],L=0;L<T.length;L+=1)P[P.length]=D(T[L]);return P}return D(T)};return hg={arrayToObject:h,assign:m,combine:E,compact:x,decode:v,encode:y,isBuffer:S,isOverflow:s,isRegExp:w,markOverflow:a,maybeMap:C,merge:g},hg}var pg,ET;function y5(){if(ET)return pg;ET=1;var t=hD(),e=pD(),r=Q0(),n=Object.prototype.hasOwnProperty,i={brackets:function(y){return y+"[]"},comma:"comma",indices:function(y,x){return y+"["+x+"]"},repeat:function(y){return y}},a=Array.isArray,s=Array.prototype.push,o=function(b,y){s.apply(b,a(y)?y:[y])},l=Date.prototype.toISOString,c=r.default,d={addQueryPrefix:!1,allowDots:!1,allowEmptyArrays:!1,arrayFormat:"indices",charset:"utf-8",charsetSentinel:!1,commaRoundTrip:!1,delimiter:"&",encode:!0,encodeDotInKeys:!1,encoder:e.encode,encodeValuesOnly:!1,filter:void 0,format:c,formatter:r.formatters[c],indices:!1,serializeDate:function(y){return l.call(y)},skipNulls:!1,strictNullHandling:!1},h=function(y){return typeof y=="string"||typeof y=="number"||typeof y=="boolean"||typeof y=="symbol"||typeof y=="bigint"},g={},m=function b(y,x,w,S,E,C,I,T,D,P,L,F,H,X,ee,J,te,ce){for(var B=y,ae=ce,Ce=0,Ae=!1;(ae=ae.get(g))!==void 0&&!Ae;){var ve=ae.get(y);if(Ce+=1,typeof ve<"u"){if(ve===Ce)throw new RangeError("Cyclic object value");Ae=!0}typeof ae.get(g)>"u"&&(Ce=0)}if(typeof P=="function"?B=P(x,B):B instanceof Date?B=H(B):w==="comma"&&a(B)&&(B=e.maybeMap(B,function(ft){return ft instanceof Date?H(ft):ft})),B===null){if(C)return ee(D&&!J?D(x,d.encoder,te,"key",X):x);B=""}if(h(B)||e.isBuffer(B)){if(D){var ct=J?x:D(x,d.encoder,te,"key",X);return[ee(ct)+"="+ee(D(B,d.encoder,te,"value",X))]}return[ee(x)+"="+ee(String(B))]}var Ge=[];if(typeof B>"u")return Ge;var Le;if(w==="comma"&&a(B))J&&D&&(B=e.maybeMap(B,function(ft){return ft==null?ft:D(ft)})),Le=[{value:B.length>0?B.join(",")||null:void 0}];else if(a(P))Le=P;else{var Ue=Object.keys(B);Le=L?Ue.sort(L):Ue}var ht=T?String(x).replace(/\./g,"%2E"):String(x),We=S&&a(B)&&B.length===1?ht+"[]":ht;if(E&&a(B)&&B.length===0)return We+"[]";for(var Se=0;Se<Le.length;++Se){var xe=Le[Se],Ze=typeof xe=="object"&&xe&&typeof xe.value<"u"?xe.value:B[xe];if(!(I&&Ze===null)){var Oe=F&&T?String(xe).replace(/\./g,"%2E"):String(xe),Je=a(B)?typeof w=="function"?w(We,Oe):We:We+(F?"."+Oe:"["+Oe+"]");ce.set(y,Ce);var Rt=t();Rt.set(g,ce),o(Ge,b(Ze,Je,w,S,E,C,I,T,w==="comma"&&J&&a(B)?null:D,P,L,F,H,X,ee,J,te,Rt))}}return Ge},v=function(y){if(!y)return d;if(typeof y.allowEmptyArrays<"u"&&typeof y.allowEmptyArrays!="boolean")throw new TypeError("`allowEmptyArrays` option can only be `true` or `false`, when provided");if(typeof y.encodeDotInKeys<"u"&&typeof y.encodeDotInKeys!="boolean")throw new TypeError("`encodeDotInKeys` option can only be `true` or `false`, when provided");if(y.encoder!==null&&typeof y.encoder<"u"&&typeof y.encoder!="function")throw new TypeError("Encoder has to be a function.");var x=y.charset||d.charset;if(typeof y.charset<"u"&&y.charset!=="utf-8"&&y.charset!=="iso-8859-1")throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var w=r.default;if(typeof y.format<"u"){if(!n.call(r.formatters,y.format))throw new TypeError("Unknown format option provided.");w=y.format}var S=r.formatters[w],E=d.filter;(typeof y.filter=="function"||a(y.filter))&&(E=y.filter);var C;if(y.arrayFormat in i?C=y.arrayFormat:"indices"in y?C=y.indices?"indices":"repeat":C=d.arrayFormat,"commaRoundTrip"in y&&typeof y.commaRoundTrip!="boolean")throw new TypeError("`commaRoundTrip` must be a boolean, or absent");var I=typeof y.allowDots>"u"?y.encodeDotInKeys===!0?!0:d.allowDots:!!y.allowDots;return{addQueryPrefix:typeof y.addQueryPrefix=="boolean"?y.addQueryPrefix:d.addQueryPrefix,allowDots:I,allowEmptyArrays:typeof y.allowEmptyArrays=="boolean"?!!y.allowEmptyArrays:d.allowEmptyArrays,arrayFormat:C,charset:x,charsetSentinel:typeof y.charsetSentinel=="boolean"?y.charsetSentinel:d.charsetSentinel,commaRoundTrip:!!y.commaRoundTrip,delimiter:typeof y.delimiter>"u"?d.delimiter:y.delimiter,encode:typeof y.encode=="boolean"?y.encode:d.encode,encodeDotInKeys:typeof y.encodeDotInKeys=="boolean"?y.encodeDotInKeys:d.encodeDotInKeys,encoder:typeof y.encoder=="function"?y.encoder:d.encoder,encodeValuesOnly:typeof y.encodeValuesOnly=="boolean"?y.encodeValuesOnly:d.encodeValuesOnly,filter:E,format:w,formatter:S,serializeDate:typeof y.serializeDate=="function"?y.serializeDate:d.serializeDate,skipNulls:typeof y.skipNulls=="boolean"?y.skipNulls:d.skipNulls,sort:typeof y.sort=="function"?y.sort:null,strictNullHandling:typeof y.strictNullHandling=="boolean"?y.strictNullHandling:d.strictNullHandling}};return pg=function(b,y){var x=b,w=v(y),S,E;typeof w.filter=="function"?(E=w.filter,x=E("",x)):a(w.filter)&&(E=w.filter,S=E);var C=[];if(typeof x!="object"||x===null)return"";var I=i[w.arrayFormat],T=I==="comma"&&w.commaRoundTrip;S||(S=Object.keys(x)),w.sort&&S.sort(w.sort);for(var D=t(),P=0;P<S.length;++P){var L=S[P];if(!(typeof L>"u"||L===null)){var F=x[L];w.skipNulls&&F===null||o(C,m(F,L,I,T,w.allowEmptyArrays,w.strictNullHandling,w.skipNulls,w.encodeDotInKeys,w.encode?w.encoder:null,w.filter,w.sort,w.allowDots,w.serializeDate,w.format,w.formatter,w.encodeValuesOnly,w.charset,D))}}var H=C.join(w.delimiter),X=w.addQueryPrefix===!0?"?":"";return w.charsetSentinel&&(w.charset==="iso-8859-1"?X+="utf8=%26%2310003%3B"+w.delimiter:X+="utf8=%E2%9C%93"+w.delimiter),H.length>0?X+H:""},pg}var gg,OT;function b5(){if(OT)return gg;OT=1;var t=pD(),e=Object.prototype.hasOwnProperty,r=Array.isArray,n={allowDots:!1,allowEmptyArrays:!1,allowPrototypes:!1,allowSparse:!1,arrayLimit:20,charset:"utf-8",charsetSentinel:!1,comma:!1,decodeDotInKeys:!1,decoder:t.decode,delimiter:"&",depth:5,duplicates:"combine",ignoreQueryPrefix:!1,interpretNumericEntities:!1,parameterLimit:1e3,parseArrays:!0,plainObjects:!1,strictDepth:!1,strictMerge:!0,strictNullHandling:!1,throwOnLimitExceeded:!1},i=function(m){return m.replace(/&#(\d+);/g,function(v,b){return String.fromCharCode(parseInt(b,10))})},a=function(m,v,b){if(m&&typeof m=="string"&&v.comma&&m.indexOf(",")>-1)return m.split(",");if(v.throwOnLimitExceeded&&b>=v.arrayLimit)throw new RangeError("Array limit exceeded. Only "+v.arrayLimit+" element"+(v.arrayLimit===1?"":"s")+" allowed in an array.");return m},s="utf8=%26%2310003%3B",o="utf8=%E2%9C%93",l=function(v,b){var y={__proto__:null},x=b.ignoreQueryPrefix?v.replace(/^\?/,""):v;x=x.replace(/%5B/gi,"[").replace(/%5D/gi,"]");var w=b.parameterLimit===1/0?void 0:b.parameterLimit,S=x.split(b.delimiter,b.throwOnLimitExceeded&&typeof w<"u"?w+1:w);if(b.throwOnLimitExceeded&&typeof w<"u"&&S.length>w)throw new RangeError("Parameter limit exceeded. Only "+w+" parameter"+(w===1?"":"s")+" allowed.");var E=-1,C,I=b.charset;if(b.charsetSentinel)for(C=0;C<S.length;++C)S[C].indexOf("utf8=")===0&&(S[C]===o?I="utf-8":S[C]===s&&(I="iso-8859-1"),E=C,C=S.length);for(C=0;C<S.length;++C)if(C!==E){var T=S[C],D=T.indexOf("]="),P=D===-1?T.indexOf("="):D+1,L,F;if(P===-1?(L=b.decoder(T,n.decoder,I,"key"),F=b.strictNullHandling?null:""):(L=b.decoder(T.slice(0,P),n.decoder,I,"key"),L!==null&&(F=t.maybeMap(a(T.slice(P+1),b,r(y[L])?y[L].length:0),function(X){return b.decoder(X,n.decoder,I,"value")}))),F&&b.interpretNumericEntities&&I==="iso-8859-1"&&(F=i(String(F))),T.indexOf("[]=")>-1&&(F=r(F)?[F]:F),b.comma&&r(F)&&F.length>b.arrayLimit){if(b.throwOnLimitExceeded)throw new RangeError("Array limit exceeded. Only "+b.arrayLimit+" element"+(b.arrayLimit===1?"":"s")+" allowed in an array.");F=t.combine([],F,b.arrayLimit,b.plainObjects)}if(L!==null){var H=e.call(y,L);H&&(b.duplicates==="combine"||T.indexOf("[]=")>-1)?y[L]=t.combine(y[L],F,b.arrayLimit,b.plainObjects):(!H||b.duplicates==="last")&&(y[L]=F)}}return y},c=function(m,v,b,y){var x=0;if(m.length>0&&m[m.length-1]==="[]"){var w=m.slice(0,-1).join("");x=Array.isArray(v)&&v[w]?v[w].length:0}for(var S=y?v:a(v,b,x),E=m.length-1;E>=0;--E){var C,I=m[E];if(I==="[]"&&b.parseArrays)t.isOverflow(S)?C=S:C=b.allowEmptyArrays&&(S===""||b.strictNullHandling&&S===null)?[]:t.combine([],S,b.arrayLimit,b.plainObjects);else{C=b.plainObjects?{__proto__:null}:{};var T=I.charAt(0)==="["&&I.charAt(I.length-1)==="]"?I.slice(1,-1):I,D=b.decodeDotInKeys?T.replace(/%2E/g,"."):T,P=parseInt(D,10),L=!isNaN(P)&&I!==D&&String(P)===D&&P>=0&&b.parseArrays;if(!b.parseArrays&&D==="")C={0:S};else if(L&&P<b.arrayLimit)C=[],C[P]=S;else{if(L&&b.throwOnLimitExceeded)throw new RangeError("Array limit exceeded. Only "+b.arrayLimit+" element"+(b.arrayLimit===1?"":"s")+" allowed in an array.");L?(C[P]=S,t.markOverflow(C,P)):D!=="__proto__"&&(C[D]=S)}}S=C}return S},d=function(v,b){var y=b.allowDots?v.replace(/\.([^.[]+)/g,"[$1]"):v;if(b.depth<=0)return!b.plainObjects&&e.call(Object.prototype,y)&&!b.allowPrototypes?void 0:[y];var x=[],w=y.indexOf("["),S=w>=0?y.slice(0,w):y;if(S){if(!b.plainObjects&&e.call(Object.prototype,S)&&!b.allowPrototypes)return;x[x.length]=S}for(var E=y.length,C=w,I=0;C>=0&&I<b.depth;){for(var T=1,D=C+1,P=-1;D<E&&P<0;){var L=y.charCodeAt(D);L===91?T+=1:L===93&&(T-=1,T===0&&(P=D)),D+=1}if(P<0)return x[x.length]="["+y.slice(C)+"]",x;var F=y.slice(C,P+1),H=F.slice(1,-1);if(!b.plainObjects&&e.call(Object.prototype,H)&&!b.allowPrototypes)return;x[x.length]=F,I+=1,C=y.indexOf("[",P+1)}if(C>=0){if(b.strictDepth===!0)throw new RangeError("Input depth exceeded depth option of "+b.depth+" and strictDepth is true");x[x.length]="["+y.slice(C)+"]"}return x},h=function(v,b,y,x){if(v){var w=d(v,y);if(w)return c(w,b,y,x)}},g=function(v){if(!v)return n;if(typeof v.allowEmptyArrays<"u"&&typeof v.allowEmptyArrays!="boolean")throw new TypeError("`allowEmptyArrays` option can only be `true` or `false`, when provided");if(typeof v.decodeDotInKeys<"u"&&typeof v.decodeDotInKeys!="boolean")throw new TypeError("`decodeDotInKeys` option can only be `true` or `false`, when provided");if(v.decoder!==null&&typeof v.decoder<"u"&&typeof v.decoder!="function")throw new TypeError("Decoder has to be a function.");if(typeof v.charset<"u"&&v.charset!=="utf-8"&&v.charset!=="iso-8859-1")throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");if(typeof v.throwOnLimitExceeded<"u"&&typeof v.throwOnLimitExceeded!="boolean")throw new TypeError("`throwOnLimitExceeded` option must be a boolean");var b=typeof v.charset>"u"?n.charset:v.charset,y=typeof v.duplicates>"u"?n.duplicates:v.duplicates;if(y!=="combine"&&y!=="first"&&y!=="last")throw new TypeError("The duplicates option must be either combine, first, or last");var x=typeof v.allowDots>"u"?v.decodeDotInKeys===!0?!0:n.allowDots:!!v.allowDots;return{allowDots:x,allowEmptyArrays:typeof v.allowEmptyArrays=="boolean"?!!v.allowEmptyArrays:n.allowEmptyArrays,allowPrototypes:typeof v.allowPrototypes=="boolean"?v.allowPrototypes:n.allowPrototypes,allowSparse:typeof v.allowSparse=="boolean"?v.allowSparse:n.allowSparse,arrayLimit:typeof v.arrayLimit=="number"?v.arrayLimit:n.arrayLimit,charset:b,charsetSentinel:typeof v.charsetSentinel=="boolean"?v.charsetSentinel:n.charsetSentinel,comma:typeof v.comma=="boolean"?v.comma:n.comma,decodeDotInKeys:typeof v.decodeDotInKeys=="boolean"?v.decodeDotInKeys:n.decodeDotInKeys,decoder:typeof v.decoder=="function"?v.decoder:n.decoder,delimiter:typeof v.delimiter=="string"||t.isRegExp(v.delimiter)?v.delimiter:n.delimiter,depth:typeof v.depth=="number"||v.depth===!1?+v.depth:n.depth,duplicates:y,ignoreQueryPrefix:v.ignoreQueryPrefix===!0,interpretNumericEntities:typeof v.interpretNumericEntities=="boolean"?v.interpretNumericEntities:n.interpretNumericEntities,parameterLimit:typeof v.parameterLimit=="number"?v.parameterLimit:n.parameterLimit,parseArrays:v.parseArrays!==!1,plainObjects:typeof v.plainObjects=="boolean"?v.plainObjects:n.plainObjects,strictDepth:typeof v.strictDepth=="boolean"?!!v.strictDepth:n.strictDepth,strictMerge:typeof v.strictMerge=="boolean"?!!v.strictMerge:n.strictMerge,strictNullHandling:typeof v.strictNullHandling=="boolean"?v.strictNullHandling:n.strictNullHandling,throwOnLimitExceeded:typeof v.throwOnLimitExceeded=="boolean"?v.throwOnLimitExceeded:!1}};return gg=function(m,v){var b=g(v);if(m===""||m===null||typeof m>"u")return b.plainObjects?{__proto__:null}:{};for(var y=typeof m=="string"?l(m,b):m,x=b.plainObjects?{__proto__:null}:{},w=Object.keys(y),S=0;S<w.length;++S){var E=w[S],C=h(E,y[E],b,typeof m=="string");x=t.merge(x,C,b)}return b.allowSparse===!0?x:t.compact(x)},gg}var mg,AT;function _5(){if(AT)return mg;AT=1;var t=y5(),e=b5(),r=Q0();return mg={formats:r,parse:e,stringify:t},mg}var x5=_5();const Pd=vi(x5),gD=({children:t,style:e,...r})=>{const n=Ve(Et("md"));return A.jsx("div",{style:{...n?{padding:"0px 24px"}:null,...e},...r,children:t})},w5={margin:0,fontFamily:"var(--root-secondary-font, 'Red Hat Display', sans-serif)",fontWeight:"bold"},T5=({children:t,style:e,...r})=>{const n=Ve(Et("md"));return A.jsx("p",{style:{...w5,...n?{fontSize:20,lineHeight:"24px",letterSpacing:"0.15px"}:{fontSize:34,lineHeight:"40px",letterSpacing:"0.35px"},...e},...r,children:t})},S5=({children:t,style:e,...r})=>{const n=Ve(Et("md"));return A.jsx("div",{style:{display:"flex",flexDirection:n?"column":"row",alignItems:"baseline",columnGap:16,marginBottom:n?16:32,...e},...r,children:t})},C5=({children:t,...e})=>A.jsx(lt,{variant:"h4",component:"p",...e,children:t}),mD=12,E5=["xs","sm","md","lg","xl"],vD=(t,e)=>{let r;return E5.forEach(n=>{t[n]!==void 0&&e[n]&&(r=t[n])}),r},O5=(t,e)=>t===void 0?0:typeof t=="number"?t*8:(vD(t,e)??0)*8,yD=()=>({xs:!0,sm:Ve(pa("sm")),md:Ve(pa("md")),lg:Ve(pa("lg")),xl:Ve(pa("xl"))}),Xf=({spacing:t,children:e,style:r,...n})=>{const i=yD(),a={display:"grid",gridTemplateColumns:`repeat(${mD}, minmax(0, 1fr))`,gap:O5(t,i),width:"100%"};return A.jsx("div",{style:{...a,...r},...n,children:e})},zr=({xs:t,sm:e,md:r,lg:n,xl:i,children:a,style:s,...o})=>{const l=yD(),c=vD({xs:t,sm:e,md:r,lg:n,xl:i},l)??mD;return A.jsx("div",{style:{gridColumn:`span ${c}`,minWidth:0,...s},...o,children:a})},eb=({children:t,style:e,...r})=>{const n=Ve(Et("md"));return A.jsx("div",{style:{height:"100%",...n?{padding:"0px 24px"}:null,...e},...r,children:t})},bD=({children:t,style:e,...r})=>{const n=Ve(Et("sm"));return A.jsx("div",{style:{display:"flex",alignItems:"baseline",columnGap:16,flexDirection:n?"column":"row",marginBottom:n?16:32,...e},...r,children:t})},A5=({children:t,style:e,...r})=>A.jsx("div",{style:{display:"flex",justifyContent:"space-between",...e},...r,children:t}),_D=({children:t,...e})=>A.jsx(Xf,{...e,children:t}),tb=({children:t,...e})=>A.jsx(_D,{...e,children:t}),rb=({assetName:t,sitecode:e})=>{const{t:r}=Qt("location"),n=vs(),i=/\balert\b/.test(n.pathname);return A.jsxs(A5,{children:[A.jsxs(bD,{children:[A.jsx(C5,{children:t}),e&&A.jsx(lt,{variant:"subtitle1",children:e})]}),i&&A.jsx(YH,{to:{pathname:"/alerts-definitions",search:n.search},children:A.jsxs(xd,{appearance:"filled",hasIcon:!0,style:{display:"inline-flex"},children:[A.jsx(Hi,{slot:"icon",children:"settings"}),r("alerts.configure-alerts-button")]})})]})},I5=async({alertId:t,...e})=>{const r=ri({pathname:`/dcim-custom-alerts/${t}/threshold`});return await ni.put(r,e)},R5=t=>I0(fn.EDIT_NOTIFICATION,I5,t),D5=async t=>{const e=ri({pathname:"/dcim-custom-alerts"});return await ni.post(e,t)},M5=t=>I0(fn.CREATE_NOTIFICATION,D5,t),P5=async({alertId:t,...e})=>{const r=ri({pathname:`/dcim-custom-alerts/${t}/preference`});return await ni.put(r,e)},L5=t=>I0(fn.EDIT_NOTIFICATION,P5,t),N5=t=>{const{leasedSpaceName:e,sort:r,order:n}=t,i=Object.assign({},mr.fromPairs(mr.entries(t).filter(([o,l])=>!!l)));delete i.leasedSpaceName,i.sort=r?[r,n==null?void 0:n.toUpperCase()].join(","):void 0;const a=btoa(e),s=ri({pathname:`dcim-devices/customer-known-name-space/${a}/alerts`,searchParams:i});return ni.get(s)},Yf=(t,e)=>Ui([fn.DCIM_ALERTS,t],()=>N5(t),{...e,refetchOnWindowFocus:!1}),Zf=t=>{let e;if(t instanceof Array)return t.map(r=>(typeof r=="object"&&(r=Zf(r)),r));e={};for(const r in t)if(t.hasOwnProperty(r)){const n=mr.camelCase(r);let i=t[r];(i instanceof Array||i!==null&&i.constructor===Object)&&(i=Zf(i)),e[n]=i}return e},F5=1,xD=1e3*F5,wD=60*xD,k5=(t=new Date)=>{const e=new Date(t);return e.setSeconds(0),e.setMilliseconds(0),e},j5=async({leasedSpaceName:t,...e})=>{const r=btoa(t),n=ri({pathname:`dcim-devices/customer-known-name-space/${r}/chart-data`,searchParams:e}),i=await ni.get(n);return Zf(i)},TD=(t,e={})=>{const r=wD*15,n={cacheTime:r,refetchInterval:0,refetchOnMount:!1,retry:!1,staleTime:r,...e};return Ui([fn.DCIM_CHART_DATA,t],()=>j5(t),n)},$5=async t=>{const e=btoa(t),r=ri({pathname:`/dcim-devices/customer-known-name-space/${e}/chart-metadata`}),n=await ni.get(r);return Zf(n)},SD=(t,e={})=>{const n={cacheTime:wD*15,refetchInterval:0,...e};return Ui([fn.DCIM_CHART_METADATA],()=>$5(t),n)},CD=({leasedSpaceName:t,size:e,page:r,sort:n,order:i,...a})=>{const s=Object.assign({},mr.fromPairs(mr.entries(a).filter(([c,d])=>!!d)));s.size=e,s.page=r,s.sort=n?[n,i].join(","):"";const o=btoa(t),l=ri({pathname:`dcim-devices/customer-known-name-space/${o}/historical-alerts`,searchParams:s});return ni.get(l)},ED=(t,e)=>Ui([fn.DCIM_HISTORICAL_ALERTS,t],()=>CD(t),{placeholderData:[],refetchInterval:0,...e}),OD=t=>{const{sort:e,order:r,leasedSpaceName:n}=t,i=Object.assign({},mr.fromPairs(mr.entries(t).filter(([o,l])=>!!l)));delete i.leasedSpaceName,i.sort=e?[e,r==null?void 0:r.toUpperCase()].join(","):void 0;const a=btoa(n),s=ri({pathname:`dcim-devices/customer-known-name-space/${a}/alert-instances`,searchParams:i});return ni.get(s)},Uy=(t,e)=>Ui([fn.DCIM_ALERT_INSTANCES,t],()=>OD(t),{placeholderData:[],refetchInterval:0,...e}),U5=t=>{const e=ri({pathname:`dcim-historical-alert-instances/${t}`});return ni.get(e)},q5=(t,e)=>Ui([fn.DCIM_HISTORICAL_ALERT_INSTANCE_DETAILS],()=>U5(t),{...e,refetchOnWindowFocus:!1}),H5=async(t,e,r,n)=>{const i=ri({pathname:"/dcim-devices/planned-site-maintenance",searchParams:{location:t,site:e,startDate:r,endDate:n}});return await ni.get(i)},W5=(t,e,r,n,i)=>Ui([fn.PLANNED_SITE_MAINTENANCE,t,e,r,n],()=>H5(t,e,r,n),{...i,refetchOnWindowFocus:!1}),B5=t=>{const e=ri({pathname:`dcim-alert-instances/${t}`});return ni.get(e)},z5=(t,e)=>Ui([fn.DCIM_ALERT_INSTANCE_DETAILS],()=>B5(t),{...e,refetchOnWindowFocus:!1}),V5=({$isVisible:t=!0,children:e,style:r,...n})=>A.jsx("div",{style:{display:"flex",flexDirection:"column",visibility:t?"visible":"hidden",...r},...n,children:e}),G5=({children:t,style:e,...r})=>A.jsx("div",{style:{display:"flex",...e},...r,children:t}),K5=({children:t,style:e,...r})=>A.jsx(lt,{style:{wordBreak:"break-word",...e},...r,children:t}),X5=(t,e="-")=>{const{t:r}=Qt("common"),{formatDateTime:n}=z0();return ER(t)||t===""?e:typeof t=="boolean"?r(t.toString()):typeof t=="number"?String(t):OR(t)?n(t):t},Ri=({title:t,titleColor:e,value:r,emptyValue:n="-",whiteSpace:i,isVisible:a,icon:s,...o})=>{const l=o["data-testid"],c=X5(r,n);return A.jsxs(V5,{$isVisible:a,children:[A.jsxs(G5,{children:[A.jsx(lt,{variant:"subtitle2",component:"h5",style:{whiteSpace:i?"nowrap":"normal",color:e},children:t}),s]}),typeof c=="string"?A.jsx(K5,{"data-testid":l,variant:"subtitle1",children:c}):c]})};var kr=(t=>(t.POWER="power",t.ENVIRONMENTAL="environmental",t.AUXILIARY="auxiliary",t))(kr||{}),on=(t=>(t.CRITICAL="critical",t.CUSTOM="custom",t))(on||{});const Y5=["critical","custom"];var ti=(t=>(t.HISTORY="history",t.DEFINITIONS="definitions",t.INSTANCES="instances",t))(ti||{});const Z5=t=>({height:32,display:"flex",flexDirection:"row",alignItems:"center",background:t||"#ffffff",borderRadius:68,width:"fit-content",padding:"4px 16px 4px 4px",gap:8}),J5=({background:t,children:e,style:r,...n})=>A.jsx("div",{style:{...Z5(t),...r},...n,children:e}),Q5=({children:t,style:e,...r})=>A.jsx(J5,{style:{padding:"3px 10px",height:"fit-content",...e},...r,children:t}),e4={[kr.POWER]:{background:Ye.warning,color:Ye.onPrimary},[kr.ENVIRONMENTAL]:{background:Ye.success,color:Ye.onPrimary},[kr.AUXILIARY]:{background:Ye.info,color:Ye.onPrimary}},t4={background:Ye.outline,color:Ye.onSurface},Jf=({title:t})=>{const{background:e,color:r}=e4[t]||t4;return A.jsx(Q5,{background:e,"data-testid":`alert-badge-${t}`,children:A.jsx(lt,{style:{fontSize:13,lineHeight:"18px",color:r},children:mr.startCase(t)})})},vg=({children:t,style:e,...r})=>{const n=Ve(Et("lg"));return A.jsx("div",{style:{maxWidth:828,marginRight:32,background:"#ffffff",borderRadius:"12px 12px 0 0",width:"100%",...n?{border:0,padding:0}:{border:"1px solid rgb(0 0 0 / 12%)",padding:24,height:"calc(100vh - 100px)",overflow:"auto"},...e},...r,children:t})},IT=({children:t,style:e,...r})=>A.jsx("div",{style:{display:"flex",flexDirection:"column",gap:16,...e},...r,children:t}),r4=({children:t,style:e,...r})=>{const n=Ve(Et("lg"));return A.jsx("h5",{style:{margin:0,fontFamily:"var(--root-secondary-font, 'Red Hat Display', sans-serif)",fontWeight:700,...n?{fontSize:34,lineHeight:"40px"}:{fontSize:24,lineHeight:"32px"},...e},...r,children:t})},n4=()=>{const t=Ve(Et("lg"));return A.jsx(cW,{style:{"--md-divider-color":Ye.outline,margin:t?"36px 0 24px 0":"24px 0"}})},i4=({children:t,style:e,...r})=>A.jsx("div",{style:{display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",height:"100%",...e},...r,children:t});var Jl={exports:{}},Ql={exports:{}},yg={exports:{}},RT;function ir(){return RT||(RT=1,(function(t){function e(r){return r&&r.__esModule?r:{default:r}}t.exports=e,t.exports.__esModule=!0,t.exports.default=t.exports})(yg)),yg.exports}var ec={exports:{}},DT;function a4(){return DT||(DT=1,(function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=r;function r(n,i){if(n==null)throw new TypeError("assign requires that input parameter not be null or undefined");for(var a in i)Object.prototype.hasOwnProperty.call(i,a)&&(n[a]=i[a]);return n}t.exports=e.default})(ec,ec.exports)),ec.exports}var MT;function s4(){return MT||(MT=1,(function(t,e){var r=ir().default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=i;var n=r(a4());function i(a){return(0,n.default)({},a)}t.exports=e.default})(Ql,Ql.exports)),Ql.exports}var tc={exports:{}},rc={exports:{}},nc={exports:{}},ic={exports:{}},bg={exports:{}},PT;function AD(){return PT||(PT=1,(function(t){function e(r){"@babel/helpers - typeof";return t.exports=e=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(n){return typeof n}:function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},t.exports.__esModule=!0,t.exports.default=t.exports,e(r)}t.exports=e,t.exports.__esModule=!0,t.exports.default=t.exports})(bg)),bg.exports}var ac={exports:{}},LT;function Xr(){return LT||(LT=1,(function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=r;function r(n,i){if(i.length<n)throw new TypeError(n+" argument"+(n>1?"s":"")+" required, but only "+i.length+" present")}t.exports=e.default})(ac,ac.exports)),ac.exports}var NT;function o4(){return NT||(NT=1,(function(t,e){var r=ir().default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=a;var n=r(AD()),i=r(Xr());function a(s){return(0,i.default)(1,arguments),s instanceof Date||(0,n.default)(s)==="object"&&Object.prototype.toString.call(s)==="[object Date]"}t.exports=e.default})(ic,ic.exports)),ic.exports}var sc={exports:{}},FT;function yi(){return FT||(FT=1,(function(t,e){var r=ir().default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=a;var n=r(AD()),i=r(Xr());function a(s){(0,i.default)(1,arguments);var o=Object.prototype.toString.call(s);return s instanceof Date||(0,n.default)(s)==="object"&&o==="[object Date]"?new Date(s.getTime()):typeof s=="number"||o==="[object Number]"?new Date(s):((typeof s=="string"||o==="[object String]")&&typeof console<"u"&&(console.warn("Starting with v2.0.0-beta.1 date-fns doesn't accept strings as date arguments. Please use `parseISO` to parse strings. See: https://github.com/date-fns/date-fns/blob/master/docs/upgradeGuide.md#string-arguments"),console.warn(new Error().stack)),new Date(NaN))}t.exports=e.default})(sc,sc.exports)),sc.exports}var kT;function u4(){return kT||(kT=1,(function(t,e){var r=ir().default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=s;var n=r(o4()),i=r(yi()),a=r(Xr());function s(o){if((0,a.default)(1,arguments),!(0,n.default)(o)&&typeof o!="number")return!1;var l=(0,i.default)(o);return!isNaN(Number(l))}t.exports=e.default})(nc,nc.exports)),nc.exports}var oc={exports:{}},uc={exports:{}},lc={exports:{}},jT;function ys(){return jT||(jT=1,(function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=r;function r(n){if(n===null||n===!0||n===!1)return NaN;var i=Number(n);return isNaN(i)?i:i<0?Math.ceil(i):Math.floor(i)}t.exports=e.default})(lc,lc.exports)),lc.exports}var $T;function l4(){return $T||($T=1,(function(t,e){var r=ir().default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=s;var n=r(ys()),i=r(yi()),a=r(Xr());function s(o,l){(0,a.default)(2,arguments);var c=(0,i.default)(o).getTime(),d=(0,n.default)(l);return new Date(c+d)}t.exports=e.default})(uc,uc.exports)),uc.exports}var UT;function c4(){return UT||(UT=1,(function(t,e){var r=ir().default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=s;var n=r(l4()),i=r(Xr()),a=r(ys());function s(o,l){(0,i.default)(2,arguments);var c=(0,a.default)(l);return(0,n.default)(o,-c)}t.exports=e.default})(oc,oc.exports)),oc.exports}var cc={exports:{}},fc={exports:{}},qT;function f4(){return qT||(qT=1,(function(t,e){var r=ir().default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=s;var n=r(yi()),i=r(Xr()),a=864e5;function s(o){(0,i.default)(1,arguments);var l=(0,n.default)(o),c=l.getTime();l.setUTCMonth(0,1),l.setUTCHours(0,0,0,0);var d=l.getTime(),h=c-d;return Math.floor(h/a)+1}t.exports=e.default})(fc,fc.exports)),fc.exports}var dc={exports:{}},hc={exports:{}},HT;function nb(){return HT||(HT=1,(function(t,e){var r=ir().default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=a;var n=r(yi()),i=r(Xr());function a(s){(0,i.default)(1,arguments);var o=1,l=(0,n.default)(s),c=l.getUTCDay(),d=(c<o?7:0)+c-o;return l.setUTCDate(l.getUTCDate()-d),l.setUTCHours(0,0,0,0),l}t.exports=e.default})(hc,hc.exports)),hc.exports}var pc={exports:{}},gc={exports:{}},WT;function ID(){return WT||(WT=1,(function(t,e){var r=ir().default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=s;var n=r(yi()),i=r(Xr()),a=r(nb());function s(o){(0,i.default)(1,arguments);var l=(0,n.default)(o),c=l.getUTCFullYear(),d=new Date(0);d.setUTCFullYear(c+1,0,4),d.setUTCHours(0,0,0,0);var h=(0,a.default)(d),g=new Date(0);g.setUTCFullYear(c,0,4),g.setUTCHours(0,0,0,0);var m=(0,a.default)(g);return l.getTime()>=h.getTime()?c+1:l.getTime()>=m.getTime()?c:c-1}t.exports=e.default})(gc,gc.exports)),gc.exports}var BT;function d4(){return BT||(BT=1,(function(t,e){var r=ir().default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=s;var n=r(ID()),i=r(nb()),a=r(Xr());function s(o){(0,a.default)(1,arguments);var l=(0,n.default)(o),c=new Date(0);c.setUTCFullYear(l,0,4),c.setUTCHours(0,0,0,0);var d=(0,i.default)(c);return d}t.exports=e.default})(pc,pc.exports)),pc.exports}var zT;function h4(){return zT||(zT=1,(function(t,e){var r=ir().default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=l;var n=r(yi()),i=r(nb()),a=r(d4()),s=r(Xr()),o=6048e5;function l(c){(0,s.default)(1,arguments);var d=(0,n.default)(c),h=(0,i.default)(d).getTime()-(0,a.default)(d).getTime();return Math.round(h/o)+1}t.exports=e.default})(dc,dc.exports)),dc.exports}var mc={exports:{}},vc={exports:{}},nu={},VT;function Ld(){if(VT)return nu;VT=1,Object.defineProperty(nu,"__esModule",{value:!0}),nu.getDefaultOptions=e,nu.setDefaultOptions=r;var t={};function e(){return t}function r(n){t=n}return nu}var GT;function ib(){return GT||(GT=1,(function(t,e){var r=ir().default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var n=r(yi()),i=r(Xr()),a=r(ys()),s=Ld();function o(l,c){var d,h,g,m,v,b,y,x;(0,i.default)(1,arguments);var w=(0,s.getDefaultOptions)(),S=(0,a.default)((d=(h=(g=(m=c==null?void 0:c.weekStartsOn)!==null&&m!==void 0?m:c==null||(v=c.locale)===null||v===void 0||(b=v.options)===null||b===void 0?void 0:b.weekStartsOn)!==null&&g!==void 0?g:w.weekStartsOn)!==null&&h!==void 0?h:(y=w.locale)===null||y===void 0||(x=y.options)===null||x===void 0?void 0:x.weekStartsOn)!==null&&d!==void 0?d:0);if(!(S>=0&&S<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var E=(0,n.default)(l),C=E.getUTCDay(),I=(C<S?7:0)+C-S;return E.setUTCDate(E.getUTCDate()-I),E.setUTCHours(0,0,0,0),E}t.exports=e.default})(vc,vc.exports)),vc.exports}var yc={exports:{}},bc={exports:{}},KT;function RD(){return KT||(KT=1,(function(t,e){var r=ir().default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=l;var n=r(yi()),i=r(Xr()),a=r(ib()),s=r(ys()),o=Ld();function l(c,d){var h,g,m,v,b,y,x,w;(0,i.default)(1,arguments);var S=(0,n.default)(c),E=S.getUTCFullYear(),C=(0,o.getDefaultOptions)(),I=(0,s.default)((h=(g=(m=(v=d==null?void 0:d.firstWeekContainsDate)!==null&&v!==void 0?v:d==null||(b=d.locale)===null||b===void 0||(y=b.options)===null||y===void 0?void 0:y.firstWeekContainsDate)!==null&&m!==void 0?m:C.firstWeekContainsDate)!==null&&g!==void 0?g:(x=C.locale)===null||x===void 0||(w=x.options)===null||w===void 0?void 0:w.firstWeekContainsDate)!==null&&h!==void 0?h:1);if(!(I>=1&&I<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var T=new Date(0);T.setUTCFullYear(E+1,0,I),T.setUTCHours(0,0,0,0);var D=(0,a.default)(T,d),P=new Date(0);P.setUTCFullYear(E,0,I),P.setUTCHours(0,0,0,0);var L=(0,a.default)(P,d);return S.getTime()>=D.getTime()?E+1:S.getTime()>=L.getTime()?E:E-1}t.exports=e.default})(bc,bc.exports)),bc.exports}var XT;function p4(){return XT||(XT=1,(function(t,e){var r=ir().default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=l;var n=r(RD()),i=r(Xr()),a=r(ib()),s=r(ys()),o=Ld();function l(c,d){var h,g,m,v,b,y,x,w;(0,i.default)(1,arguments);var S=(0,o.getDefaultOptions)(),E=(0,s.default)((h=(g=(m=(v=d==null?void 0:d.firstWeekContainsDate)!==null&&v!==void 0?v:d==null||(b=d.locale)===null||b===void 0||(y=b.options)===null||y===void 0?void 0:y.firstWeekContainsDate)!==null&&m!==void 0?m:S.firstWeekContainsDate)!==null&&g!==void 0?g:(x=S.locale)===null||x===void 0||(w=x.options)===null||w===void 0?void 0:w.firstWeekContainsDate)!==null&&h!==void 0?h:1),C=(0,n.default)(c,d),I=new Date(0);I.setUTCFullYear(C,0,E),I.setUTCHours(0,0,0,0);var T=(0,a.default)(I,d);return T}t.exports=e.default})(yc,yc.exports)),yc.exports}var YT;function g4(){return YT||(YT=1,(function(t,e){var r=ir().default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=l;var n=r(yi()),i=r(ib()),a=r(p4()),s=r(Xr()),o=6048e5;function l(c,d){(0,s.default)(1,arguments);var h=(0,n.default)(c),g=(0,i.default)(h,d).getTime()-(0,a.default)(h,d).getTime();return Math.round(g/o)+1}t.exports=e.default})(mc,mc.exports)),mc.exports}var _c={exports:{}},ZT;function DD(){return ZT||(ZT=1,(function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=r;function r(n,i){for(var a=n<0?"-":"",s=Math.abs(n).toString();s.length<i;)s="0"+s;return a+s}t.exports=e.default})(_c,_c.exports)),_c.exports}var xc={exports:{}},JT;function m4(){return JT||(JT=1,(function(t,e){var r=ir().default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n=r(DD()),i={y:function(o,l){var c=o.getUTCFullYear(),d=c>0?c:1-c;return(0,n.default)(l==="yy"?d%100:d,l.length)},M:function(o,l){var c=o.getUTCMonth();return l==="M"?String(c+1):(0,n.default)(c+1,2)},d:function(o,l){return(0,n.default)(o.getUTCDate(),l.length)},a:function(o,l){var c=o.getUTCHours()/12>=1?"pm":"am";switch(l){case"a":case"aa":return c.toUpperCase();case"aaa":return c;case"aaaaa":return c[0];case"aaaa":default:return c==="am"?"a.m.":"p.m."}},h:function(o,l){return(0,n.default)(o.getUTCHours()%12||12,l.length)},H:function(o,l){return(0,n.default)(o.getUTCHours(),l.length)},m:function(o,l){return(0,n.default)(o.getUTCMinutes(),l.length)},s:function(o,l){return(0,n.default)(o.getUTCSeconds(),l.length)},S:function(o,l){var c=l.length,d=o.getUTCMilliseconds(),h=Math.floor(d*Math.pow(10,c-3));return(0,n.default)(h,l.length)}},a=i;e.default=a,t.exports=e.default})(xc,xc.exports)),xc.exports}var QT;function v4(){return QT||(QT=1,(function(t,e){var r=ir().default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n=r(f4()),i=r(h4()),a=r(ID()),s=r(g4()),o=r(RD()),l=r(DD()),c=r(m4()),d={midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},h={G:function(x,w,S){var E=x.getUTCFullYear()>0?1:0;switch(w){case"G":case"GG":case"GGG":return S.era(E,{width:"abbreviated"});case"GGGGG":return S.era(E,{width:"narrow"});case"GGGG":default:return S.era(E,{width:"wide"})}},y:function(x,w,S){if(w==="yo"){var E=x.getUTCFullYear(),C=E>0?E:1-E;return S.ordinalNumber(C,{unit:"year"})}return c.default.y(x,w)},Y:function(x,w,S,E){var C=(0,o.default)(x,E),I=C>0?C:1-C;if(w==="YY"){var T=I%100;return(0,l.default)(T,2)}return w==="Yo"?S.ordinalNumber(I,{unit:"year"}):(0,l.default)(I,w.length)},R:function(x,w){var S=(0,a.default)(x);return(0,l.default)(S,w.length)},u:function(x,w){var S=x.getUTCFullYear();return(0,l.default)(S,w.length)},Q:function(x,w,S){var E=Math.ceil((x.getUTCMonth()+1)/3);switch(w){case"Q":return String(E);case"QQ":return(0,l.default)(E,2);case"Qo":return S.ordinalNumber(E,{unit:"quarter"});case"QQQ":return S.quarter(E,{width:"abbreviated",context:"formatting"});case"QQQQQ":return S.quarter(E,{width:"narrow",context:"formatting"});case"QQQQ":default:return S.quarter(E,{width:"wide",context:"formatting"})}},q:function(x,w,S){var E=Math.ceil((x.getUTCMonth()+1)/3);switch(w){case"q":return String(E);case"qq":return(0,l.default)(E,2);case"qo":return S.ordinalNumber(E,{unit:"quarter"});case"qqq":return S.quarter(E,{width:"abbreviated",context:"standalone"});case"qqqqq":return S.quarter(E,{width:"narrow",context:"standalone"});case"qqqq":default:return S.quarter(E,{width:"wide",context:"standalone"})}},M:function(x,w,S){var E=x.getUTCMonth();switch(w){case"M":case"MM":return c.default.M(x,w);case"Mo":return S.ordinalNumber(E+1,{unit:"month"});case"MMM":return S.month(E,{width:"abbreviated",context:"formatting"});case"MMMMM":return S.month(E,{width:"narrow",context:"formatting"});case"MMMM":default:return S.month(E,{width:"wide",context:"formatting"})}},L:function(x,w,S){var E=x.getUTCMonth();switch(w){case"L":return String(E+1);case"LL":return(0,l.default)(E+1,2);case"Lo":return S.ordinalNumber(E+1,{unit:"month"});case"LLL":return S.month(E,{width:"abbreviated",context:"standalone"});case"LLLLL":return S.month(E,{width:"narrow",context:"standalone"});case"LLLL":default:return S.month(E,{width:"wide",context:"standalone"})}},w:function(x,w,S,E){var C=(0,s.default)(x,E);return w==="wo"?S.ordinalNumber(C,{unit:"week"}):(0,l.default)(C,w.length)},I:function(x,w,S){var E=(0,i.default)(x);return w==="Io"?S.ordinalNumber(E,{unit:"week"}):(0,l.default)(E,w.length)},d:function(x,w,S){return w==="do"?S.ordinalNumber(x.getUTCDate(),{unit:"date"}):c.default.d(x,w)},D:function(x,w,S){var E=(0,n.default)(x);return w==="Do"?S.ordinalNumber(E,{unit:"dayOfYear"}):(0,l.default)(E,w.length)},E:function(x,w,S){var E=x.getUTCDay();switch(w){case"E":case"EE":case"EEE":return S.day(E,{width:"abbreviated",context:"formatting"});case"EEEEE":return S.day(E,{width:"narrow",context:"formatting"});case"EEEEEE":return S.day(E,{width:"short",context:"formatting"});case"EEEE":default:return S.day(E,{width:"wide",context:"formatting"})}},e:function(x,w,S,E){var C=x.getUTCDay(),I=(C-E.weekStartsOn+8)%7||7;switch(w){case"e":return String(I);case"ee":return(0,l.default)(I,2);case"eo":return S.ordinalNumber(I,{unit:"day"});case"eee":return S.day(C,{width:"abbreviated",context:"formatting"});case"eeeee":return S.day(C,{width:"narrow",context:"formatting"});case"eeeeee":return S.day(C,{width:"short",context:"formatting"});case"eeee":default:return S.day(C,{width:"wide",context:"formatting"})}},c:function(x,w,S,E){var C=x.getUTCDay(),I=(C-E.weekStartsOn+8)%7||7;switch(w){case"c":return String(I);case"cc":return(0,l.default)(I,w.length);case"co":return S.ordinalNumber(I,{unit:"day"});case"ccc":return S.day(C,{width:"abbreviated",context:"standalone"});case"ccccc":return S.day(C,{width:"narrow",context:"standalone"});case"cccccc":return S.day(C,{width:"short",context:"standalone"});case"cccc":default:return S.day(C,{width:"wide",context:"standalone"})}},i:function(x,w,S){var E=x.getUTCDay(),C=E===0?7:E;switch(w){case"i":return String(C);case"ii":return(0,l.default)(C,w.length);case"io":return S.ordinalNumber(C,{unit:"day"});case"iii":return S.day(E,{width:"abbreviated",context:"formatting"});case"iiiii":return S.day(E,{width:"narrow",context:"formatting"});case"iiiiii":return S.day(E,{width:"short",context:"formatting"});case"iiii":default:return S.day(E,{width:"wide",context:"formatting"})}},a:function(x,w,S){var E=x.getUTCHours(),C=E/12>=1?"pm":"am";switch(w){case"a":case"aa":return S.dayPeriod(C,{width:"abbreviated",context:"formatting"});case"aaa":return S.dayPeriod(C,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return S.dayPeriod(C,{width:"narrow",context:"formatting"});case"aaaa":default:return S.dayPeriod(C,{width:"wide",context:"formatting"})}},b:function(x,w,S){var E=x.getUTCHours(),C;switch(E===12?C=d.noon:E===0?C=d.midnight:C=E/12>=1?"pm":"am",w){case"b":case"bb":return S.dayPeriod(C,{width:"abbreviated",context:"formatting"});case"bbb":return S.dayPeriod(C,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return S.dayPeriod(C,{width:"narrow",context:"formatting"});case"bbbb":default:return S.dayPeriod(C,{width:"wide",context:"formatting"})}},B:function(x,w,S){var E=x.getUTCHours(),C;switch(E>=17?C=d.evening:E>=12?C=d.afternoon:E>=4?C=d.morning:C=d.night,w){case"B":case"BB":case"BBB":return S.dayPeriod(C,{width:"abbreviated",context:"formatting"});case"BBBBB":return S.dayPeriod(C,{width:"narrow",context:"formatting"});case"BBBB":default:return S.dayPeriod(C,{width:"wide",context:"formatting"})}},h:function(x,w,S){if(w==="ho"){var E=x.getUTCHours()%12;return E===0&&(E=12),S.ordinalNumber(E,{unit:"hour"})}return c.default.h(x,w)},H:function(x,w,S){return w==="Ho"?S.ordinalNumber(x.getUTCHours(),{unit:"hour"}):c.default.H(x,w)},K:function(x,w,S){var E=x.getUTCHours()%12;return w==="Ko"?S.ordinalNumber(E,{unit:"hour"}):(0,l.default)(E,w.length)},k:function(x,w,S){var E=x.getUTCHours();return E===0&&(E=24),w==="ko"?S.ordinalNumber(E,{unit:"hour"}):(0,l.default)(E,w.length)},m:function(x,w,S){return w==="mo"?S.ordinalNumber(x.getUTCMinutes(),{unit:"minute"}):c.default.m(x,w)},s:function(x,w,S){return w==="so"?S.ordinalNumber(x.getUTCSeconds(),{unit:"second"}):c.default.s(x,w)},S:function(x,w){return c.default.S(x,w)},X:function(x,w,S,E){var C=E._originalDate||x,I=C.getTimezoneOffset();if(I===0)return"Z";switch(w){case"X":return m(I);case"XXXX":case"XX":return v(I);case"XXXXX":case"XXX":default:return v(I,":")}},x:function(x,w,S,E){var C=E._originalDate||x,I=C.getTimezoneOffset();switch(w){case"x":return m(I);case"xxxx":case"xx":return v(I);case"xxxxx":case"xxx":default:return v(I,":")}},O:function(x,w,S,E){var C=E._originalDate||x,I=C.getTimezoneOffset();switch(w){case"O":case"OO":case"OOO":return"GMT"+g(I,":");case"OOOO":default:return"GMT"+v(I,":")}},z:function(x,w,S,E){var C=E._originalDate||x,I=C.getTimezoneOffset();switch(w){case"z":case"zz":case"zzz":return"GMT"+g(I,":");case"zzzz":default:return"GMT"+v(I,":")}},t:function(x,w,S,E){var C=E._originalDate||x,I=Math.floor(C.getTime()/1e3);return(0,l.default)(I,w.length)},T:function(x,w,S,E){var C=E._originalDate||x,I=C.getTime();return(0,l.default)(I,w.length)}};function g(y,x){var w=y>0?"-":"+",S=Math.abs(y),E=Math.floor(S/60),C=S%60;if(C===0)return w+String(E);var I=x;return w+String(E)+I+(0,l.default)(C,2)}function m(y,x){if(y%60===0){var w=y>0?"-":"+";return w+(0,l.default)(Math.abs(y)/60,2)}return v(y,x)}function v(y,x){var w=x||"",S=y>0?"-":"+",E=Math.abs(y),C=(0,l.default)(Math.floor(E/60),2),I=(0,l.default)(E%60,2);return S+C+w+I}var b=h;e.default=b,t.exports=e.default})(cc,cc.exports)),cc.exports}var wc={exports:{}},eS;function y4(){return eS||(eS=1,(function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var r=function(l,c){switch(l){case"P":return c.date({width:"short"});case"PP":return c.date({width:"medium"});case"PPP":return c.date({width:"long"});case"PPPP":default:return c.date({width:"full"})}},n=function(l,c){switch(l){case"p":return c.time({width:"short"});case"pp":return c.time({width:"medium"});case"ppp":return c.time({width:"long"});case"pppp":default:return c.time({width:"full"})}},i=function(l,c){var d=l.match(/(P+)(p+)?/)||[],h=d[1],g=d[2];if(!g)return r(l,c);var m;switch(h){case"P":m=c.dateTime({width:"short"});break;case"PP":m=c.dateTime({width:"medium"});break;case"PPP":m=c.dateTime({width:"long"});break;case"PPPP":default:m=c.dateTime({width:"full"});break}return m.replace("{{date}}",r(h,c)).replace("{{time}}",n(g,c))},a={p:n,P:i},s=a;e.default=s,t.exports=e.default})(wc,wc.exports)),wc.exports}var Tc={exports:{}},tS;function MD(){return tS||(tS=1,(function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=r;function r(n){var i=new Date(Date.UTC(n.getFullYear(),n.getMonth(),n.getDate(),n.getHours(),n.getMinutes(),n.getSeconds(),n.getMilliseconds()));return i.setUTCFullYear(n.getFullYear()),n.getTime()-i.getTime()}t.exports=e.default})(Tc,Tc.exports)),Tc.exports}var Gs={},rS;function b4(){if(rS)return Gs;rS=1,Object.defineProperty(Gs,"__esModule",{value:!0}),Gs.isProtectedDayOfYearToken=r,Gs.isProtectedWeekYearToken=n,Gs.throwProtectedError=i;var t=["D","DD"],e=["YY","YYYY"];function r(a){return t.indexOf(a)!==-1}function n(a){return e.indexOf(a)!==-1}function i(a,s,o){if(a==="YYYY")throw new RangeError("Use `yyyy` instead of `YYYY` (in `".concat(s,"`) for formatting years to the input `").concat(o,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(a==="YY")throw new RangeError("Use `yy` instead of `YY` (in `".concat(s,"`) for formatting years to the input `").concat(o,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(a==="D")throw new RangeError("Use `d` instead of `D` (in `".concat(s,"`) for formatting days of the month to the input `").concat(o,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(a==="DD")throw new RangeError("Use `dd` instead of `DD` (in `".concat(s,"`) for formatting days of the month to the input `").concat(o,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"))}return Gs}var Sc={exports:{}},Cc={exports:{}},Ec={exports:{}},nS;function _4(){return nS||(nS=1,(function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var r={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},n=function(s,o,l){var c,d=r[s];return typeof d=="string"?c=d:o===1?c=d.one:c=d.other.replace("{{count}}",o.toString()),l!=null&&l.addSuffix?l.comparison&&l.comparison>0?"in "+c:c+" ago":c},i=n;e.default=i,t.exports=e.default})(Ec,Ec.exports)),Ec.exports}var Oc={exports:{}},Ac={exports:{}},iS;function x4(){return iS||(iS=1,(function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=r;function r(n){return function(){var i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},a=i.width?String(i.width):n.defaultWidth,s=n.formats[a]||n.formats[n.defaultWidth];return s}}t.exports=e.default})(Ac,Ac.exports)),Ac.exports}var aS;function w4(){return aS||(aS=1,(function(t,e){var r=ir().default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n=r(x4()),i={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},a={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},s={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},o={date:(0,n.default)({formats:i,defaultWidth:"full"}),time:(0,n.default)({formats:a,defaultWidth:"full"}),dateTime:(0,n.default)({formats:s,defaultWidth:"full"})},l=o;e.default=l,t.exports=e.default})(Oc,Oc.exports)),Oc.exports}var Ic={exports:{}},sS;function T4(){return sS||(sS=1,(function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var r={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},n=function(s,o,l,c){return r[s]},i=n;e.default=i,t.exports=e.default})(Ic,Ic.exports)),Ic.exports}var Rc={exports:{}},Dc={exports:{}},oS;function S4(){return oS||(oS=1,(function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=r;function r(n){return function(i,a){var s=a!=null&&a.context?String(a.context):"standalone",o;if(s==="formatting"&&n.formattingValues){var l=n.defaultFormattingWidth||n.defaultWidth,c=a!=null&&a.width?String(a.width):l;o=n.formattingValues[c]||n.formattingValues[l]}else{var d=n.defaultWidth,h=a!=null&&a.width?String(a.width):n.defaultWidth;o=n.values[h]||n.values[d]}var g=n.argumentCallback?n.argumentCallback(i):i;return o[g]}}t.exports=e.default})(Dc,Dc.exports)),Dc.exports}var uS;function C4(){return uS||(uS=1,(function(t,e){var r=ir().default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n=r(S4()),i={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},a={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},s={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},o={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},l={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},c={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},d=function(v,b){var y=Number(v),x=y%100;if(x>20||x<10)switch(x%10){case 1:return y+"st";case 2:return y+"nd";case 3:return y+"rd"}return y+"th"},h={ordinalNumber:d,era:(0,n.default)({values:i,defaultWidth:"wide"}),quarter:(0,n.default)({values:a,defaultWidth:"wide",argumentCallback:function(v){return v-1}}),month:(0,n.default)({values:s,defaultWidth:"wide"}),day:(0,n.default)({values:o,defaultWidth:"wide"}),dayPeriod:(0,n.default)({values:l,defaultWidth:"wide",formattingValues:c,defaultFormattingWidth:"wide"})},g=h;e.default=g,t.exports=e.default})(Rc,Rc.exports)),Rc.exports}var Mc={exports:{}},Pc={exports:{}},lS;function E4(){return lS||(lS=1,(function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=r;function r(a){return function(s){var o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},l=o.width,c=l&&a.matchPatterns[l]||a.matchPatterns[a.defaultMatchWidth],d=s.match(c);if(!d)return null;var h=d[0],g=l&&a.parsePatterns[l]||a.parsePatterns[a.defaultParseWidth],m=Array.isArray(g)?i(g,function(y){return y.test(h)}):n(g,function(y){return y.test(h)}),v;v=a.valueCallback?a.valueCallback(m):m,v=o.valueCallback?o.valueCallback(v):v;var b=s.slice(h.length);return{value:v,rest:b}}}function n(a,s){for(var o in a)if(a.hasOwnProperty(o)&&s(a[o]))return o}function i(a,s){for(var o=0;o<a.length;o++)if(s(a[o]))return o}t.exports=e.default})(Pc,Pc.exports)),Pc.exports}var Lc={exports:{}},cS;function O4(){return cS||(cS=1,(function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=r;function r(n){return function(i){var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},s=i.match(n.matchPattern);if(!s)return null;var o=s[0],l=i.match(n.parsePattern);if(!l)return null;var c=n.valueCallback?n.valueCallback(l[0]):l[0];c=a.valueCallback?a.valueCallback(c):c;var d=i.slice(o.length);return{value:c,rest:d}}}t.exports=e.default})(Lc,Lc.exports)),Lc.exports}var fS;function A4(){return fS||(fS=1,(function(t,e){var r=ir().default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n=r(E4()),i=r(O4()),a=/^(\d+)(th|st|nd|rd)?/i,s=/\d+/i,o={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},l={any:[/^b/i,/^(a|c)/i]},c={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},d={any:[/1/i,/2/i,/3/i,/4/i]},h={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},g={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},m={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},v={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},b={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},y={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},x={ordinalNumber:(0,i.default)({matchPattern:a,parsePattern:s,valueCallback:function(E){return parseInt(E,10)}}),era:(0,n.default)({matchPatterns:o,defaultMatchWidth:"wide",parsePatterns:l,defaultParseWidth:"any"}),quarter:(0,n.default)({matchPatterns:c,defaultMatchWidth:"wide",parsePatterns:d,defaultParseWidth:"any",valueCallback:function(E){return E+1}}),month:(0,n.default)({matchPatterns:h,defaultMatchWidth:"wide",parsePatterns:g,defaultParseWidth:"any"}),day:(0,n.default)({matchPatterns:m,defaultMatchWidth:"wide",parsePatterns:v,defaultParseWidth:"any"}),dayPeriod:(0,n.default)({matchPatterns:b,defaultMatchWidth:"any",parsePatterns:y,defaultParseWidth:"any"})},w=x;e.default=w,t.exports=e.default})(Mc,Mc.exports)),Mc.exports}var dS;function I4(){return dS||(dS=1,(function(t,e){var r=ir().default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n=r(_4()),i=r(w4()),a=r(T4()),s=r(C4()),o=r(A4()),l={code:"en-US",formatDistance:n.default,formatLong:i.default,formatRelative:a.default,localize:s.default,match:o.default,options:{weekStartsOn:0,firstWeekContainsDate:1}},c=l;e.default=c,t.exports=e.default})(Cc,Cc.exports)),Cc.exports}var hS;function R4(){return hS||(hS=1,(function(t,e){var r=ir().default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var n=r(I4()),i=n.default;e.default=i,t.exports=e.default})(Sc,Sc.exports)),Sc.exports}var pS;function D4(){return pS||(pS=1,(function(t,e){var r=ir().default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=S;var n=r(u4()),i=r(c4()),a=r(yi()),s=r(v4()),o=r(y4()),l=r(MD()),c=b4(),d=r(ys()),h=r(Xr()),g=Ld(),m=r(R4()),v=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,b=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,y=/^'([^]*?)'?$/,x=/''/g,w=/[a-zA-Z]/;function S(C,I,T){var D,P,L,F,H,X,ee,J,te,ce,B,ae,Ce,Ae,ve,ct,Ge,Le;(0,h.default)(2,arguments);var Ue=String(I),ht=(0,g.getDefaultOptions)(),We=(D=(P=T==null?void 0:T.locale)!==null&&P!==void 0?P:ht.locale)!==null&&D!==void 0?D:m.default,Se=(0,d.default)((L=(F=(H=(X=T==null?void 0:T.firstWeekContainsDate)!==null&&X!==void 0?X:T==null||(ee=T.locale)===null||ee===void 0||(J=ee.options)===null||J===void 0?void 0:J.firstWeekContainsDate)!==null&&H!==void 0?H:ht.firstWeekContainsDate)!==null&&F!==void 0?F:(te=ht.locale)===null||te===void 0||(ce=te.options)===null||ce===void 0?void 0:ce.firstWeekContainsDate)!==null&&L!==void 0?L:1);if(!(Se>=1&&Se<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var xe=(0,d.default)((B=(ae=(Ce=(Ae=T==null?void 0:T.weekStartsOn)!==null&&Ae!==void 0?Ae:T==null||(ve=T.locale)===null||ve===void 0||(ct=ve.options)===null||ct===void 0?void 0:ct.weekStartsOn)!==null&&Ce!==void 0?Ce:ht.weekStartsOn)!==null&&ae!==void 0?ae:(Ge=ht.locale)===null||Ge===void 0||(Le=Ge.options)===null||Le===void 0?void 0:Le.weekStartsOn)!==null&&B!==void 0?B:0);if(!(xe>=0&&xe<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(!We.localize)throw new RangeError("locale must contain localize property");if(!We.formatLong)throw new RangeError("locale must contain formatLong property");var Ze=(0,a.default)(C);if(!(0,n.default)(Ze))throw new RangeError("Invalid time value");var Oe=(0,l.default)(Ze),Je=(0,i.default)(Ze,Oe),Rt={firstWeekContainsDate:Se,weekStartsOn:xe,locale:We,_originalDate:Ze},ft=Ue.match(b).map(function(Ne){var Nt=Ne[0];if(Nt==="p"||Nt==="P"){var Ot=o.default[Nt];return Ot(Ne,We.formatLong)}return Ne}).join("").match(v).map(function(Ne){if(Ne==="''")return"'";var Nt=Ne[0];if(Nt==="'")return E(Ne);var Ot=s.default[Nt];if(Ot)return!(T!=null&&T.useAdditionalWeekYearTokens)&&(0,c.isProtectedWeekYearToken)(Ne)&&(0,c.throwProtectedError)(Ne,I,String(C)),!(T!=null&&T.useAdditionalDayOfYearTokens)&&(0,c.isProtectedDayOfYearToken)(Ne)&&(0,c.throwProtectedError)(Ne,I,String(C)),Ot(Je,Ne,We.localize,Rt);if(Nt.match(w))throw new RangeError("Format string contains an unescaped latin alphabet character `"+Nt+"`");return Ne}).join("");return ft}function E(C){var I=C.match(y);return I?I[1].replace(x,"'"):C}t.exports=e.default})(rc,rc.exports)),rc.exports}var Nc={exports:{}},Fc={exports:{}},gS;function M4(){return gS||(gS=1,(function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=r;function r(s,o,l){var c=a(s,l.timeZone,l.locale);return c.formatToParts?n(c,o):i(c,o)}function n(s,o){for(var l=s.formatToParts(o),c=l.length-1;c>=0;--c)if(l[c].type==="timeZoneName")return l[c].value}function i(s,o){var l=s.format(o).replace(/\u200E/g,""),c=/ [\w-+ ]+$/.exec(l);return c?c[0].substr(1):""}function a(s,o,l){if(l&&!l.code)throw new Error("date-fns-tz error: Please set a language code on the locale object imported from date-fns, e.g. `locale.code = 'en-US'`");return new Intl.DateTimeFormat(l?[l.code,"en-US"]:void 0,{timeZone:o,timeZoneName:s})}t.exports=e.default})(Fc,Fc.exports)),Fc.exports}var kc={exports:{}},jc={exports:{}},mS;function P4(){return mS||(mS=1,(function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=r;function r(l,c){var d=o(c);return d.formatToParts?i(d,l):a(d,l)}var n={year:0,month:1,day:2,hour:3,minute:4,second:5};function i(l,c){try{for(var d=l.formatToParts(c),h=[],g=0;g<d.length;g++){var m=n[d[g].type];m>=0&&(h[m]=parseInt(d[g].value,10))}return h}catch(v){if(v instanceof RangeError)return[NaN];throw v}}function a(l,c){var d=l.format(c).replace(/\u200E/g,""),h=/(\d+)\/(\d+)\/(\d+),? (\d+):(\d+):(\d+)/.exec(d);return[h[3],h[1],h[2],h[4],h[5],h[6]]}var s={};function o(l){if(!s[l]){var c=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:"America/New_York",year:"numeric",month:"numeric",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit"}).format(new Date("2014-06-25T04:00:00.123Z")),d=c==="06/25/2014, 00:00:00"||c==="06/25/2014 00:00:00";s[l]=d?new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:l,year:"numeric",month:"numeric",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit"}):new Intl.DateTimeFormat("en-US",{hourCycle:"h23",timeZone:l,year:"numeric",month:"numeric",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit"})}return s[l]}t.exports=e.default})(jc,jc.exports)),jc.exports}var $c={exports:{}},vS;function L4(){return vS||(vS=1,(function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=r;function r(n,i,a,s,o,l,c){var d=new Date(0);return d.setUTCFullYear(n,i,a),d.setUTCHours(s,o,l,c),d}t.exports=e.default})($c,$c.exports)),$c.exports}var yS;function ab(){return yS||(yS=1,(function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=l;var r=i(P4()),n=i(L4());function i(b){return b&&b.__esModule?b:{default:b}}var a=36e5,s=6e4,o={timezoneZ:/^(Z)$/,timezoneHH:/^([+-]\d{2})$/,timezoneHHMM:/^([+-]\d{2}):?(\d{2})$/};function l(b,y,x){var w,S;if(!b||(w=o.timezoneZ.exec(b),w))return 0;var E;if(w=o.timezoneHH.exec(b),w)return E=parseInt(w[1],10),g(E)?-(E*a):NaN;if(w=o.timezoneHHMM.exec(b),w){E=parseInt(w[1],10);var C=parseInt(w[2],10);return g(E,C)?(S=Math.abs(E)*a+C*s,E>0?-S:S):NaN}if(v(b)){y=new Date(y||Date.now());var I=x?y:c(y),T=d(I,b),D=x?T:h(y,T,b);return-D}return NaN}function c(b){return(0,n.default)(b.getFullYear(),b.getMonth(),b.getDate(),b.getHours(),b.getMinutes(),b.getSeconds(),b.getMilliseconds())}function d(b,y){var x=(0,r.default)(b,y),w=(0,n.default)(x[0],x[1]-1,x[2],x[3]%24,x[4],x[5],0).getTime(),S=b.getTime(),E=S%1e3;return S-=E>=0?E:1e3+E,w-S}function h(b,y,x){var w=b.getTime(),S=w-y,E=d(new Date(S),x);if(y===E)return y;S-=E-y;var C=d(new Date(S),x);return E===C?E:Math.max(E,C)}function g(b,y){return-23<=b&&b<=23&&(y==null||0<=y&&y<=59)}var m={};function v(b){if(m[b])return!0;try{return new Intl.DateTimeFormat(void 0,{timeZone:b}),m[b]=!0,!0}catch{return!1}}t.exports=e.default})(kc,kc.exports)),kc.exports}var bS;function N4(){return bS||(bS=1,(function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var r=i(M4()),n=i(ab());function i(m){return m&&m.__esModule?m:{default:m}}var a=60*1e3,s={X:function(m,v,b,y){var x=o(y.timeZone,y._originalDate||m);if(x===0)return"Z";switch(v){case"X":return d(x);case"XXXX":case"XX":return c(x);case"XXXXX":case"XXX":default:return c(x,":")}},x:function(m,v,b,y){var x=o(y.timeZone,y._originalDate||m);switch(v){case"x":return d(x);case"xxxx":case"xx":return c(x);case"xxxxx":case"xxx":default:return c(x,":")}},O:function(m,v,b,y){var x=o(y.timeZone,y._originalDate||m);switch(v){case"O":case"OO":case"OOO":return"GMT"+h(x,":");case"OOOO":default:return"GMT"+c(x,":")}},z:function(m,v,b,y){var x=y._originalDate||m;switch(v){case"z":case"zz":case"zzz":return(0,r.default)("short",x,y);case"zzzz":default:return(0,r.default)("long",x,y)}}};function o(m,v){var b=m?(0,n.default)(m,v,!0)/a:v.getTimezoneOffset();if(Number.isNaN(b))throw new RangeError("Invalid time zone specified: "+m);return b}function l(m,v){for(var b=m<0?"-":"",y=Math.abs(m).toString();y.length<v;)y="0"+y;return b+y}function c(m,v){var b=v||"",y=m>0?"-":"+",x=Math.abs(m),w=l(Math.floor(x/60),2),S=l(Math.floor(x%60),2);return y+w+b+S}function d(m,v){if(m%60===0){var b=m>0?"-":"+";return b+l(Math.abs(m)/60,2)}return c(m,v)}function h(m,v){var b=m>0?"-":"+",y=Math.abs(m),x=Math.floor(y/60),w=y%60;if(w===0)return b+String(x);var S=v;return b+String(x)+S+l(w,2)}var g=s;e.default=g,t.exports=e.default})(Nc,Nc.exports)),Nc.exports}var Uc={exports:{}},qc={exports:{}},_S;function F4(){return _S||(_S=1,(function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var r=/(Z|[+-]\d{2}(?::?\d{2})?| UTC| [a-zA-Z]+\/[a-zA-Z_]+(?:\/[a-zA-Z_]+)?)$/,n=r;e.default=n,t.exports=e.default})(qc,qc.exports)),qc.exports}var xS;function PD(){return xS||(xS=1,(function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=h;var r=s(ys()),n=s(MD()),i=s(ab()),a=s(F4());function s(D){return D&&D.__esModule?D:{default:D}}var o=36e5,l=6e4,c=2,d={dateTimePattern:/^([0-9W+-]+)(T| )(.*)/,datePattern:/^([0-9W+-]+)(.*)/,YY:/^(\d{2})$/,YYY:[/^([+-]\d{2})$/,/^([+-]\d{3})$/,/^([+-]\d{4})$/],YYYY:/^(\d{4})/,YYYYY:[/^([+-]\d{4})/,/^([+-]\d{5})/,/^([+-]\d{6})/],MM:/^-(\d{2})$/,DDD:/^-?(\d{3})$/,MMDD:/^-?(\d{2})-?(\d{2})$/,Www:/^-?W(\d{2})$/,WwwD:/^-?W(\d{2})-?(\d{1})$/,HH:/^(\d{2}([.,]\d*)?)$/,HHMM:/^(\d{2}):?(\d{2}([.,]\d*)?)$/,HHMMSS:/^(\d{2}):?(\d{2}):?(\d{2}([.,]\d*)?)$/,timeZone:a.default};function h(D,P){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");if(D===null)return new Date(NaN);var L=P||{},F=L.additionalDigits==null?c:(0,r.default)(L.additionalDigits);if(F!==2&&F!==1&&F!==0)throw new RangeError("additionalDigits must be 0, 1 or 2");if(D instanceof Date||typeof D=="object"&&Object.prototype.toString.call(D)==="[object Date]")return new Date(D.getTime());if(typeof D=="number"||Object.prototype.toString.call(D)==="[object Number]")return new Date(D);if(!(typeof D=="string"||Object.prototype.toString.call(D)==="[object String]"))return new Date(NaN);var H=g(D),X=m(H.date,F),ee=X.year,J=X.restDateString,te=v(J,ee);if(isNaN(te))return new Date(NaN);if(te){var ce=te.getTime(),B=0,ae;if(H.time&&(B=b(H.time),isNaN(B)))return new Date(NaN);if(H.timeZone||L.timeZone){if(ae=(0,i.default)(H.timeZone||L.timeZone,new Date(ce+B)),isNaN(ae))return new Date(NaN)}else ae=(0,n.default)(new Date(ce+B)),ae=(0,n.default)(new Date(ce+B+ae));return new Date(ce+B+ae)}else return new Date(NaN)}function g(D){var P={},L=d.dateTimePattern.exec(D),F;if(L?(P.date=L[1],F=L[3]):(L=d.datePattern.exec(D),L?(P.date=L[1],F=L[2]):(P.date=null,F=D)),F){var H=d.timeZone.exec(F);H?(P.time=F.replace(H[1],""),P.timeZone=H[1].trim()):P.time=F}return P}function m(D,P){var L=d.YYY[P],F=d.YYYYY[P],H;if(H=d.YYYY.exec(D)||F.exec(D),H){var X=H[1];return{year:parseInt(X,10),restDateString:D.slice(X.length)}}if(H=d.YY.exec(D)||L.exec(D),H){var ee=H[1];return{year:parseInt(ee,10)*100,restDateString:D.slice(ee.length)}}return{year:null}}function v(D,P){if(P===null)return null;var L,F,H,X;if(D.length===0)return F=new Date(0),F.setUTCFullYear(P),F;if(L=d.MM.exec(D),L)return F=new Date(0),H=parseInt(L[1],10)-1,E(P,H)?(F.setUTCFullYear(P,H),F):new Date(NaN);if(L=d.DDD.exec(D),L){F=new Date(0);var ee=parseInt(L[1],10);return C(P,ee)?(F.setUTCFullYear(P,0,ee),F):new Date(NaN)}if(L=d.MMDD.exec(D),L){F=new Date(0),H=parseInt(L[1],10)-1;var J=parseInt(L[2],10);return E(P,H,J)?(F.setUTCFullYear(P,H,J),F):new Date(NaN)}if(L=d.Www.exec(D),L)return X=parseInt(L[1],10)-1,I(P,X)?y(P,X):new Date(NaN);if(L=d.WwwD.exec(D),L){X=parseInt(L[1],10)-1;var te=parseInt(L[2],10)-1;return I(P,X,te)?y(P,X,te):new Date(NaN)}return null}function b(D){var P,L,F;if(P=d.HH.exec(D),P)return L=parseFloat(P[1].replace(",",".")),T(L)?L%24*o:NaN;if(P=d.HHMM.exec(D),P)return L=parseInt(P[1],10),F=parseFloat(P[2].replace(",",".")),T(L,F)?L%24*o+F*l:NaN;if(P=d.HHMMSS.exec(D),P){L=parseInt(P[1],10),F=parseInt(P[2],10);var H=parseFloat(P[3].replace(",","."));return T(L,F,H)?L%24*o+F*l+H*1e3:NaN}return null}function y(D,P,L){P=P||0,L=L||0;var F=new Date(0);F.setUTCFullYear(D,0,4);var H=F.getUTCDay()||7,X=P*7+L+1-H;return F.setUTCDate(F.getUTCDate()+X),F}var x=[31,28,31,30,31,30,31,31,30,31,30,31],w=[31,29,31,30,31,30,31,31,30,31,30,31];function S(D){return D%400===0||D%4===0&&D%100!==0}function E(D,P,L){if(P<0||P>11)return!1;if(L!=null){if(L<1)return!1;var F=S(D);if(F&&L>w[P]||!F&&L>x[P])return!1}return!0}function C(D,P){if(P<1)return!1;var L=S(D);return!(L&&P>366||!L&&P>365)}function I(D,P,L){return!(P<0||P>52||L!=null&&(L<0||L>6))}function T(D,P,L){return!(D!=null&&(D<0||D>=25)||P!=null&&(P<0||P>=60)||L!=null&&(L<0||L>=60))}t.exports=e.default})(Uc,Uc.exports)),Uc.exports}var wS;function LD(){return wS||(wS=1,(function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=o;var r=a(D4()),n=a(N4()),i=a(PD());function a(l){return l&&l.__esModule?l:{default:l}}var s=/([xXOz]+)|''|'(''|[^'])+('|$)/g;function o(l,c,d){var h=String(c),g=d||{},m=h.match(s);if(m){var v=(0,i.default)(l,g);h=m.reduce(function(b,y){if(y[0]==="'")return b;var x=b.indexOf(y),w=b[x-1]==="'",S=b.replace(y,"'"+n.default[y[0]](v,y,null,g)+"'");return w?S.substring(0,x-1)+S.substring(x+1):S},h)}return(0,r.default)(l,h,g)}t.exports=e.default})(tc,tc.exports)),tc.exports}var Hc={exports:{}},TS;function k4(){return TS||(TS=1,(function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=a;var r=i(ab()),n=i(PD());function i(s){return s&&s.__esModule?s:{default:s}}function a(s,o,l){var c=(0,n.default)(s,l),d=(0,r.default)(o,c,!0),h=new Date(c.getTime()-d),g=new Date(0);return g.setFullYear(h.getUTCFullYear(),h.getUTCMonth(),h.getUTCDate()),g.setHours(h.getUTCHours(),h.getUTCMinutes(),h.getUTCSeconds(),h.getUTCMilliseconds()),g}t.exports=e.default})(Hc,Hc.exports)),Hc.exports}var SS;function j4(){return SS||(SS=1,(function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=s;var r=a(s4()),n=a(LD()),i=a(k4());function a(o){return o&&o.__esModule?o:{default:o}}function s(o,l,c,d){var h=(0,r.default)(d);return h.timeZone=l,(0,n.default)((0,i.default)(o,l),c,h)}t.exports=e.default})(Jl,Jl.exports)),Jl.exports}var $4=j4();const ND=vi($4),FD=({isFetching:t,isError:e,alert:r})=>{const{t:n}=Qt("location",{keyPrefix:"alerts.details"}),{dateTimeFormatPreferences:i,getTimeFormatString:a}=Id(),s=a(!0),o=l=>l?ND(l,"UTC",`${i.preferredDateFormat} ${s} (zzz)`):"";return t?A.jsx(vg,{"data-testid":"loader-container",children:A.jsx(i4,{children:A.jsx(Ff,{linear:!1,indeterminate:!0,role:"progressbar","aria-label":"Loading...","aria-busy":"true",style:{"--md-circular-progress-size":"40px"}})})}):e?A.jsx(vg,{children:A.jsxs(X0,{children:[A.jsx(Hi,{filled:!0,style:{"--ix-icon-font-size":"45px",color:"var(--clr-critical, #db0028)"},children:"warning"}),A.jsx(lt,{variant:"body1",children:n("error")})]})}):A.jsxs(vg,{"data-testid":"alert-details-container",children:[A.jsxs("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"center"},children:[A.jsx(r4,{children:r.alertName}),A.jsxs("div",{style:{display:"flex",gap:"10px"},children:[A.jsx(Jf,{title:r.alertType||""}),!!r.alertCategory&&A.jsx(Jf,{title:r.alertCategory})]})]}),A.jsx(n4,{}),A.jsxs(IT,{children:[A.jsx(Ri,{title:n("alert-number"),value:r.alertId,"data-testid":"alert-details--alert-number"}),A.jsxs(Xf,{children:[A.jsx(zr,{xs:6,children:A.jsx(Ri,{title:n("site"),value:r.site,"data-testid":"alert-details--site"})}),A.jsx(zr,{xs:6,children:A.jsx(Ri,{title:n("location"),value:r.location,"data-testid":"alert-details--location"})})]}),A.jsxs(Xf,{children:[A.jsx(zr,{xs:6,children:A.jsx(Ri,{title:n("total-load"),value:r.functionValue,"data-testid":"alert-details--total-load"})}),A.jsx(zr,{xs:6,children:A.jsx(Ri,{title:n("threshold-value"),value:r.alertThreshold,"data-testid":"alert-details--threshold-value"})})]}),A.jsx(Ri,{title:n("affected-ci"),value:r.deviceMetric,"data-testid":"alert-details--affected-ci"}),A.jsx(Ri,{title:n("description"),value:r.deviceName,"data-testid":"alert-details--description"}),A.jsxs("div",{children:[A.jsx(lt,{variant:"subtitle2",component:"h5",style:{marginBottom:"4px"},children:n("alert-timeline-summary")}),A.jsxs(IT,{children:[A.jsx(Ri,{title:n("alert-generated-on"),titleColor:Ye.onSurfaceVariant,value:o(r.alertTimeStamp),"data-testid":"alert-details--alert-generated-on"}),r.alertDuration&&A.jsx(Ri,{title:n("duration"),titleColor:Ye.onSurfaceVariant,value:r.alertDuration,"data-testid":"alert-details--duration"})]})]})]})]})},U4=({alertInstanceId:t})=>{const{data:e,isError:r,isFetching:n,refetch:i}=q5(t,{enabled:!!t,refetchOnWindowFocus:!1});ut(()=>{i()},[t,i]);const a=(e==null?void 0:e.at(0))||{};return A.jsx(FD,{alert:a,isFetching:n,isError:r})},q4=({alertInstanceId:t})=>{const{data:e,isError:r,isFetching:n,refetch:i}=z5(t,{enabled:!!t,refetchOnWindowFocus:!1});ut(()=>{i()},[t,i]);const a=(e==null?void 0:e.at(0))||{};return A.jsx(FD,{alert:a,isFetching:n,isError:r})},kD=({alertInstanceId:t,isHistorical:e})=>e?A.jsx(U4,{alertInstanceId:t}):A.jsx(q4,{alertInstanceId:t}),H4=({alertInstanceId:t,isOpen:e,isHistorical:r,handleClose:n})=>A.jsx(yV,{open:e,onClose:n,children:A.jsxs("div",{style:{padding:"32px 40px"},children:[A.jsx("div",{style:{display:"flex",justifyContent:"flex-end"},children:A.jsx(hW,{icon:"close",onClick:n,style:{marginRight:"-20px"}})}),A.jsx(kD,{alertInstanceId:t,isHistorical:r})]})}),co="all",sb="history",jD=t=>t===ti.INSTANCES?Uy:t===ti.HISTORY?ED:(t===ti.DEFINITIONS,Yf),W4=({$active:t,children:e,style:r,...n})=>A.jsx("button",{style:{...Ea,display:"flex",flex:1,justifyContent:"space-between",padding:"8px 12px",borderRadius:12,background:t?Ye.onSurface:Ye.outline,color:t?Ye.onPrimary:Ye.onSurface,...r},...n,children:e}),B4={display:"flex",flex:1,justifyContent:"space-between",alignItems:"center",padding:"3px 10px",borderRadius:16,fontFamily:"'Roboto', sans-serif",fontSize:13,lineHeight:"18px",letterSpacing:"0.16px"},z4=({$background:t,$color:e,children:r,style:n,...i})=>A.jsx("div",{style:{...B4,background:t||Ye.onPrimary,color:e||Ye.onSurface,...n},...i,children:r}),V4={[kr.POWER]:Ye.warning,[kr.ENVIRONMENTAL]:Ye.success,[kr.AUXILIARY]:Ye.info},qy=({active:t,count:e,title:r,onClick:n})=>{const i=V4[r.toLowerCase()],a=i&&Ye.onPrimary;return A.jsxs(W4,{type:"button",onClick:()=>n(),"data-testid":`alert-filter-button-${r}`,$active:!!t,children:[A.jsxs("div",{style:{display:"flex",columnGap:34,overflow:"hidden"},children:[A.jsx(z4,{$background:i,$color:a,"data-testid":`alert-filter-count-${r}`,children:e}),A.jsx(lt,{style:{color:"inherit"},children:r})]}),A.jsx(Hi,{style:{"--ix-icon-font-size":"24px"},children:"chevron_right"})]})},G4=({children:t,style:e,...r})=>{const n=Ve(Et("sm"));return A.jsx("div",{style:{display:"flex",flexDirection:"column",rowGap:n?10:22,...e},...r,children:t})},$D=({children:t,style:e,...r})=>A.jsx("div",{style:{display:"flex",flexDirection:"column",rowGap:12,...e},...r,children:t}),K4=({title:t,items:e,selected:r,handleClose:n})=>{const{t:i}=Qt("location"),a=[{label:t,mobileLabel:A.jsx(lt,{variant:"h6",style:{fontSize:14},children:t}),trigger:()=>n()},{label:i("cancel"),mobileLabel:A.jsx(Hi,{style:{"--ix-icon-font-size":"24px",color:"rgba(0, 0, 0, 0.54)",marginRight:"-32px"},children:"close"}),trigger:()=>n()}];return A.jsx(G0,{actions:a,open:!0,fullWidth:!0,fullScreen:!0,children:A.jsx($D,{"data-testid":"alert-filter-list",children:e.map(s=>A.jsx(qy,{count:s.count,title:s.title,onClick:()=>{n(),s.onClick()},active:s.title.toLowerCase()===r},s.title))})})},UD=({title:t,selected:e,items:r})=>{const n=Ve(Et("sm")),[i,a]=rD(),s=yr(()=>r.find(l=>l.title.toLowerCase()===e)||r[0],[r,e]),o=()=>{a(),i(A.jsx(K4,{title:t,items:r,selected:e,handleClose:a}))};return A.jsxs(G4,{children:[A.jsx(lt,{variant:"h6",children:t}),n?A.jsx(qy,{count:s.count,title:s.title,onClick:o,active:!0}):A.jsx($D,{"data-testid":"alert-filter-list",children:r.map(l=>A.jsx(qy,{count:l.count,title:l.title,onClick:l.onClick,active:l.title.toLowerCase()===e},l.title))})]})},qD=({leasedSpaceName:t,filters:e,disableOptionAll:r=!1,title:n,handleFilters:i,isDefinitionsView:a=!1})=>{const{t:s}=Qt("location"),o=S=>({leasedSpaceName:t,...S&&{alertCategory:S},...Y5.includes(e.type)&&{alertType:e.type}}),l=yr(()=>a?ti.DEFINITIONS:e.type===ti.HISTORY?ti.HISTORY:ti.INSTANCES,[e.type,a]),c=yr(()=>jD(l),[l]),{data:d}=c(o()),{data:h}=c(o(kr.POWER)),{data:g}=c(o(kr.ENVIRONMENTAL)),{data:m}=c(o(kr.AUXILIARY)),v=(d==null?void 0:d.totalElements)??0,b=(h==null?void 0:h.totalElements)??0,y=(g==null?void 0:g.totalElements)??0,x=(m==null?void 0:m.totalElements)??0,w=yr(()=>{const S=[{title:s("alerts.categories.power"),count:b,onClick:()=>i("category",kr.POWER)},{title:s("alerts.categories.environmental"),count:y,onClick:()=>i("category",kr.ENVIRONMENTAL)},{title:s("alerts.categories.auxiliary"),count:x,onClick:()=>i("category",kr.AUXILIARY)}];return r||S.unshift({title:s("alerts.categories.all"),count:v,onClick:()=>i("category",co)}),S},[s,b,y,x,r,v,i]);return A.jsx(UD,{title:n||s("alerts.categories.title"),items:w,selected:e.category})},ob=({leasedSpaceName:t,filters:e,disableOptionAll:r=!1,disableOptionHistory:n=!1,title:i,handleFilters:a,isDefinitionsView:s=!1})=>{const{t:o}=Qt("location"),l=S=>({leasedSpaceName:t,alertType:S}),c=S=>{if(!S)return 0;const{totalElements:E}=S;return E||0},{data:d}=Uy(l(on.CRITICAL),{enabled:!s}),{data:h}=Uy(l(on.CUSTOM),{enabled:!s}),{data:g}=Yf(l(on.CRITICAL),{enabled:s}),{data:m}=Yf(l(on.CUSTOM),{enabled:s}),{data:v}=ED({leasedSpaceName:t},{enabled:!n}),b=yr(()=>c(s?g:d),[g,d,s]),y=yr(()=>c(s?m:h),[m,h,s]),x=yr(()=>c(v),[v]),w=yr(()=>{const S=[{title:o("alerts.types.critical"),count:b,onClick:()=>a("type",on.CRITICAL)},{title:o("alerts.types.custom"),count:y,onClick:()=>a("type",on.CUSTOM)}];return r||S.unshift({title:o("alerts.types.all"),count:b+y,onClick:()=>a("type",co)}),n||S.push({title:o("alerts.types.history"),count:x,onClick:()=>a("type",sb)}),S},[b,y,r,n,a,x,o]);return A.jsx(UD,{title:i||o("alerts.types.title"),items:w,selected:e.type})},X4={display:"flex",flexDirection:"column",alignItems:"center",height:"calc(100vh - 300px)",overflowY:"auto"},Y4=({children:t,style:e,...r})=>A.jsx("div",{style:{...X4,...e},...r,children:t}),Z4=({children:t,style:e,...r})=>{const n=Ve(Et("sm"));return A.jsx("div",{style:{display:"flex",alignItems:n?"flex-start":"center",justifyContent:"space-between",marginBottom:20,...n?{flexDirection:"column",gap:10}:null,...e},...r,children:t})},J4=t=>(t=t==null?void 0:t.toLowerCase(),[kr.AUXILIARY,kr.ENVIRONMENTAL,kr.POWER].find(e=>e.toLowerCase()===t)),Q4=t=>(t=t==null?void 0:t.toLowerCase(),[on.CRITICAL,on.CUSTOM].find(e=>e.toLowerCase()===t)),HD=({children:t,style:e,...r})=>A.jsx("div",{style:{marginBottom:15,width:"100%",display:"flex",flexDirection:"row",alignItems:"center",justifyContent:"space-between",...e},...r,children:t}),WD=({children:t,...e})=>A.jsx(lt,{...e,children:t}),e8={display:"flex",flexDirection:"column",alignItems:"flex-start",background:"#ffffff",padding:16,borderRadius:8,marginBottom:8,width:"100%",boxShadow:"0px 12px 20px -12px rgba(0, 0, 0, 0.12), inset 0px 0px 0px 1px #e1e4e8"},BD=({$canBeClicked:t,$selected:e,children:r,style:n,...i})=>A.jsx("div",{style:{...e8,...t?{cursor:"pointer"}:null,...e?{border:"1px solid black"}:null,...n},...i,children:r}),zD=({children:t,style:e,...r})=>A.jsx("div",{style:{display:"flex",flexDirection:"column",gap:4,alignItems:"flex-start",...e},...r,children:t}),t8=({children:t,style:e,...r})=>A.jsx("div",{style:{display:"flex",flexDirection:"row",gap:8,alignItems:"flex-start",...e},...r,children:t}),VD={fontFamily:"'Open Sans', sans-serif",fontStyle:"normal",fontSize:14,lineHeight:"24px",color:"#000000"},r8=({children:t,style:e,...r})=>A.jsx(lt,{...r,style:{...VD,fontWeight:700,letterSpacing:"0.1px",...e},children:t}),n8=({children:t,style:e,...r})=>A.jsx(lt,{...r,style:{...VD,fontWeight:400,letterSpacing:"0.25px",...e},children:t}),i8=({children:t,style:e,...r})=>A.jsx("div",{style:{display:"flex",...e},...r,children:t}),a8=({children:t,style:e,...r})=>{const n=Ve(Et("sm"));return A.jsx("div",{style:{display:"flex",justifyContent:"space-between",width:"100%",...n?{flexDirection:"column",gap:12}:null,...e},...r,children:t})},s8=({children:t,style:e,...r})=>{const n=Ve(Et("sm"));return A.jsx("div",{style:{display:"flex",flexWrap:"wrap",alignItems:"center",columnGap:24,...n?{justifyContent:"space-between"}:null,...e},...r,children:t})},o8=({children:t,style:e,...r})=>A.jsx("label",{style:{display:"flex",alignItems:"center",gap:8,...e},...r,children:t}),u8=({"data-testid":t,...e})=>{const{t:r}=Qt("common");return A.jsx(xd,{...e,appearance:"filled","data-testid":t,children:r("customize")})},l8=({alert:t,onClickCustomize:e})=>{const{t:r}=Qt("location"),n=[{label:r("customize-alert-dialog.email-alerts"),selected:!!t.emailEnabledSubscription,testId:"email-alerts-switch"},{label:r("customize-alert-dialog.sms-alerts"),selected:!!t.smsEnabledSubscription,testId:"sms-alerts-switch"}];return A.jsxs(a8,{children:[A.jsx(s8,{children:n.map(({label:i,selected:a,testId:s})=>A.jsxs(o8,{children:[A.jsx(k0,{"aria-label":i,"data-testid":s,disabled:!0,selected:a}),A.jsx(lt,{variant:"body2",style:{color:"var(--clr-on-surface, #092241)"},children:i})]},s))}),A.jsx(u8,{onClick:e,"data-testid":"customize-button"})]})},c8=(t,e)=>{switch(e){case on.CUSTOM:return t("customize-alert-dialog.success-custom-updated");case on.CRITICAL:return t("customize-alert-dialog.success-critical-updated");default:return t("customize-alert-dialog.success-updated")}},f8=(t,e)=>{switch(e){case"THRESHOLD_VALIDATION_ERROR":return t("customize-alert-dialog.threshold-validation-error");case"CRITICAL_ENROLLMENT_OPERATOR_AND_THRESHOLD_EMPTY":return t("customize-alert-dialog.critical-enrollment-operator-and-threshold-empty");default:return t("customize-alert-dialog.server-error")}};var d8=function(e){return h8(e)&&!p8(e)};function h8(t){return!!t&&typeof t=="object"}function p8(t){var e=Object.prototype.toString.call(t);return e==="[object RegExp]"||e==="[object Date]"||v8(t)}var g8=typeof Symbol=="function"&&Symbol.for,m8=g8?Symbol.for("react.element"):60103;function v8(t){return t.$$typeof===m8}function y8(t){return Array.isArray(t)?[]:{}}function Qf(t,e){return e.clone!==!1&&e.isMergeableObject(t)?Nu(y8(t),t,e):t}function b8(t,e,r){return t.concat(e).map(function(n){return Qf(n,r)})}function _8(t,e,r){var n={};return r.isMergeableObject(t)&&Object.keys(t).forEach(function(i){n[i]=Qf(t[i],r)}),Object.keys(e).forEach(function(i){!r.isMergeableObject(e[i])||!t[i]?n[i]=Qf(e[i],r):n[i]=Nu(t[i],e[i],r)}),n}function Nu(t,e,r){r=r||{},r.arrayMerge=r.arrayMerge||b8,r.isMergeableObject=r.isMergeableObject||d8;var n=Array.isArray(e),i=Array.isArray(t),a=n===i;return a?n?r.arrayMerge(t,e,r):_8(t,e,r):Qf(e,r)}Nu.all=function(e,r){if(!Array.isArray(e))throw new Error("first argument should be an array");return e.reduce(function(n,i){return Nu(n,i,r)},{})};var Hy=Nu,GD=typeof global=="object"&&global&&global.Object===Object&&global,x8=typeof self=="object"&&self&&self.Object===Object&&self,bi=GD||x8||Function("return this")(),xa=bi.Symbol,KD=Object.prototype,w8=KD.hasOwnProperty,T8=KD.toString,iu=xa?xa.toStringTag:void 0;function S8(t){var e=w8.call(t,iu),r=t[iu];try{t[iu]=void 0;var n=!0}catch{}var i=T8.call(t);return n&&(e?t[iu]=r:delete t[iu]),i}var C8=Object.prototype,E8=C8.toString;function O8(t){return E8.call(t)}var A8="[object Null]",I8="[object Undefined]",CS=xa?xa.toStringTag:void 0;function bs(t){return t==null?t===void 0?I8:A8:CS&&CS in Object(t)?S8(t):O8(t)}function XD(t,e){return function(r){return t(e(r))}}var ub=XD(Object.getPrototypeOf,Object);function _s(t){return t!=null&&typeof t=="object"}var R8="[object Object]",D8=Function.prototype,M8=Object.prototype,YD=D8.toString,P8=M8.hasOwnProperty,L8=YD.call(Object);function ES(t){if(!_s(t)||bs(t)!=R8)return!1;var e=ub(t);if(e===null)return!0;var r=P8.call(e,"constructor")&&e.constructor;return typeof r=="function"&&r instanceof r&&YD.call(r)==L8}function N8(){this.__data__=[],this.size=0}function ZD(t,e){return t===e||t!==t&&e!==e}function Nd(t,e){for(var r=t.length;r--;)if(ZD(t[r][0],e))return r;return-1}var F8=Array.prototype,k8=F8.splice;function j8(t){var e=this.__data__,r=Nd(e,t);if(r<0)return!1;var n=e.length-1;return r==n?e.pop():k8.call(e,r,1),--this.size,!0}function $8(t){var e=this.__data__,r=Nd(e,t);return r<0?void 0:e[r][1]}function U8(t){return Nd(this.__data__,t)>-1}function q8(t,e){var r=this.__data__,n=Nd(r,t);return n<0?(++this.size,r.push([t,e])):r[n][1]=e,this}function Bi(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}Bi.prototype.clear=N8;Bi.prototype.delete=j8;Bi.prototype.get=$8;Bi.prototype.has=U8;Bi.prototype.set=q8;function H8(){this.__data__=new Bi,this.size=0}function W8(t){var e=this.__data__,r=e.delete(t);return this.size=e.size,r}function B8(t){return this.__data__.get(t)}function z8(t){return this.__data__.has(t)}function Zu(t){var e=typeof t;return t!=null&&(e=="object"||e=="function")}var V8="[object AsyncFunction]",G8="[object Function]",K8="[object GeneratorFunction]",X8="[object Proxy]";function JD(t){if(!Zu(t))return!1;var e=bs(t);return e==G8||e==K8||e==V8||e==X8}var _g=bi["__core-js_shared__"],OS=(function(){var t=/[^.]+$/.exec(_g&&_g.keys&&_g.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""})();function Y8(t){return!!OS&&OS in t}var Z8=Function.prototype,J8=Z8.toString;function xs(t){if(t!=null){try{return J8.call(t)}catch{}try{return t+""}catch{}}return""}var Q8=/[\\^$.*+?()[\]{}|]/g,eG=/^\[object .+?Constructor\]$/,tG=Function.prototype,rG=Object.prototype,nG=tG.toString,iG=rG.hasOwnProperty,aG=RegExp("^"+nG.call(iG).replace(Q8,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function sG(t){if(!Zu(t)||Y8(t))return!1;var e=JD(t)?aG:eG;return e.test(xs(t))}function oG(t,e){return t==null?void 0:t[e]}function ws(t,e){var r=oG(t,e);return sG(r)?r:void 0}var Fu=ws(bi,"Map"),ku=ws(Object,"create");function uG(){this.__data__=ku?ku(null):{},this.size=0}function lG(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e}var cG="__lodash_hash_undefined__",fG=Object.prototype,dG=fG.hasOwnProperty;function hG(t){var e=this.__data__;if(ku){var r=e[t];return r===cG?void 0:r}return dG.call(e,t)?e[t]:void 0}var pG=Object.prototype,gG=pG.hasOwnProperty;function mG(t){var e=this.__data__;return ku?e[t]!==void 0:gG.call(e,t)}var vG="__lodash_hash_undefined__";function yG(t,e){var r=this.__data__;return this.size+=this.has(t)?0:1,r[t]=ku&&e===void 0?vG:e,this}function hs(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}hs.prototype.clear=uG;hs.prototype.delete=lG;hs.prototype.get=hG;hs.prototype.has=mG;hs.prototype.set=yG;function bG(){this.size=0,this.__data__={hash:new hs,map:new(Fu||Bi),string:new hs}}function _G(t){var e=typeof t;return e=="string"||e=="number"||e=="symbol"||e=="boolean"?t!=="__proto__":t===null}function Fd(t,e){var r=t.__data__;return _G(e)?r[typeof e=="string"?"string":"hash"]:r.map}function xG(t){var e=Fd(this,t).delete(t);return this.size-=e?1:0,e}function wG(t){return Fd(this,t).get(t)}function TG(t){return Fd(this,t).has(t)}function SG(t,e){var r=Fd(this,t),n=r.size;return r.set(t,e),this.size+=r.size==n?0:1,this}function Oa(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}Oa.prototype.clear=bG;Oa.prototype.delete=xG;Oa.prototype.get=wG;Oa.prototype.has=TG;Oa.prototype.set=SG;var CG=200;function EG(t,e){var r=this.__data__;if(r instanceof Bi){var n=r.__data__;if(!Fu||n.length<CG-1)return n.push([t,e]),this.size=++r.size,this;r=this.__data__=new Oa(n)}return r.set(t,e),this.size=r.size,this}function Co(t){var e=this.__data__=new Bi(t);this.size=e.size}Co.prototype.clear=H8;Co.prototype.delete=W8;Co.prototype.get=B8;Co.prototype.has=z8;Co.prototype.set=EG;function OG(t,e){for(var r=-1,n=t==null?0:t.length;++r<n&&e(t[r],r,t)!==!1;);return t}var AS=(function(){try{var t=ws(Object,"defineProperty");return t({},"",{}),t}catch{}})();function QD(t,e,r){e=="__proto__"&&AS?AS(t,e,{configurable:!0,enumerable:!0,value:r,writable:!0}):t[e]=r}var AG=Object.prototype,IG=AG.hasOwnProperty;function eM(t,e,r){var n=t[e];(!(IG.call(t,e)&&ZD(n,r))||r===void 0&&!(e in t))&&QD(t,e,r)}function kd(t,e,r,n){var i=!r;r||(r={});for(var a=-1,s=e.length;++a<s;){var o=e[a],l=void 0;l===void 0&&(l=t[o]),i?QD(r,o,l):eM(r,o,l)}return r}function RG(t,e){for(var r=-1,n=Array(t);++r<t;)n[r]=e(r);return n}var DG="[object Arguments]";function IS(t){return _s(t)&&bs(t)==DG}var tM=Object.prototype,MG=tM.hasOwnProperty,PG=tM.propertyIsEnumerable,LG=IS((function(){return arguments})())?IS:function(t){return _s(t)&&MG.call(t,"callee")&&!PG.call(t,"callee")},Ju=Array.isArray;function NG(){return!1}var rM=typeof exports=="object"&&exports&&!exports.nodeType&&exports,RS=rM&&typeof module=="object"&&module&&!module.nodeType&&module,FG=RS&&RS.exports===rM,DS=FG?bi.Buffer:void 0,kG=DS?DS.isBuffer:void 0,nM=kG||NG,jG=9007199254740991,$G=/^(?:0|[1-9]\d*)$/;function UG(t,e){var r=typeof t;return e=e??jG,!!e&&(r=="number"||r!="symbol"&&$G.test(t))&&t>-1&&t%1==0&&t<e}var qG=9007199254740991;function iM(t){return typeof t=="number"&&t>-1&&t%1==0&&t<=qG}var HG="[object Arguments]",WG="[object Array]",BG="[object Boolean]",zG="[object Date]",VG="[object Error]",GG="[object Function]",KG="[object Map]",XG="[object Number]",YG="[object Object]",ZG="[object RegExp]",JG="[object Set]",QG="[object String]",e7="[object WeakMap]",t7="[object ArrayBuffer]",r7="[object DataView]",n7="[object Float32Array]",i7="[object Float64Array]",a7="[object Int8Array]",s7="[object Int16Array]",o7="[object Int32Array]",u7="[object Uint8Array]",l7="[object Uint8ClampedArray]",c7="[object Uint16Array]",f7="[object Uint32Array]",Kt={};Kt[n7]=Kt[i7]=Kt[a7]=Kt[s7]=Kt[o7]=Kt[u7]=Kt[l7]=Kt[c7]=Kt[f7]=!0;Kt[HG]=Kt[WG]=Kt[t7]=Kt[BG]=Kt[r7]=Kt[zG]=Kt[VG]=Kt[GG]=Kt[KG]=Kt[XG]=Kt[YG]=Kt[ZG]=Kt[JG]=Kt[QG]=Kt[e7]=!1;function d7(t){return _s(t)&&iM(t.length)&&!!Kt[bs(t)]}function lb(t){return function(e){return t(e)}}var aM=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Cu=aM&&typeof module=="object"&&module&&!module.nodeType&&module,h7=Cu&&Cu.exports===aM,xg=h7&&GD.process,fo=(function(){try{var t=Cu&&Cu.require&&Cu.require("util").types;return t||xg&&xg.binding&&xg.binding("util")}catch{}})(),MS=fo&&fo.isTypedArray,p7=MS?lb(MS):d7,g7=Object.prototype,m7=g7.hasOwnProperty;function sM(t,e){var r=Ju(t),n=!r&&LG(t),i=!r&&!n&&nM(t),a=!r&&!n&&!i&&p7(t),s=r||n||i||a,o=s?RG(t.length,String):[],l=o.length;for(var c in t)(e||m7.call(t,c))&&!(s&&(c=="length"||i&&(c=="offset"||c=="parent")||a&&(c=="buffer"||c=="byteLength"||c=="byteOffset")||UG(c,l)))&&o.push(c);return o}var v7=Object.prototype;function cb(t){var e=t&&t.constructor,r=typeof e=="function"&&e.prototype||v7;return t===r}var y7=XD(Object.keys,Object),b7=Object.prototype,_7=b7.hasOwnProperty;function x7(t){if(!cb(t))return y7(t);var e=[];for(var r in Object(t))_7.call(t,r)&&r!="constructor"&&e.push(r);return e}function oM(t){return t!=null&&iM(t.length)&&!JD(t)}function fb(t){return oM(t)?sM(t):x7(t)}function w7(t,e){return t&&kd(e,fb(e),t)}function T7(t){var e=[];if(t!=null)for(var r in Object(t))e.push(r);return e}var S7=Object.prototype,C7=S7.hasOwnProperty;function E7(t){if(!Zu(t))return T7(t);var e=cb(t),r=[];for(var n in t)n=="constructor"&&(e||!C7.call(t,n))||r.push(n);return r}function db(t){return oM(t)?sM(t,!0):E7(t)}function O7(t,e){return t&&kd(e,db(e),t)}var uM=typeof exports=="object"&&exports&&!exports.nodeType&&exports,PS=uM&&typeof module=="object"&&module&&!module.nodeType&&module,A7=PS&&PS.exports===uM,LS=A7?bi.Buffer:void 0,NS=LS?LS.allocUnsafe:void 0;function I7(t,e){if(e)return t.slice();var r=t.length,n=NS?NS(r):new t.constructor(r);return t.copy(n),n}function lM(t,e){var r=-1,n=t.length;for(e||(e=Array(n));++r<n;)e[r]=t[r];return e}function R7(t,e){for(var r=-1,n=t==null?0:t.length,i=0,a=[];++r<n;){var s=t[r];e(s,r,t)&&(a[i++]=s)}return a}function cM(){return[]}var D7=Object.prototype,M7=D7.propertyIsEnumerable,FS=Object.getOwnPropertySymbols,hb=FS?function(t){return t==null?[]:(t=Object(t),R7(FS(t),function(e){return M7.call(t,e)}))}:cM;function P7(t,e){return kd(t,hb(t),e)}function fM(t,e){for(var r=-1,n=e.length,i=t.length;++r<n;)t[i+r]=e[r];return t}var L7=Object.getOwnPropertySymbols,dM=L7?function(t){for(var e=[];t;)fM(e,hb(t)),t=ub(t);return e}:cM;function N7(t,e){return kd(t,dM(t),e)}function hM(t,e,r){var n=e(t);return Ju(t)?n:fM(n,r(t))}function F7(t){return hM(t,fb,hb)}function k7(t){return hM(t,db,dM)}var Wy=ws(bi,"DataView"),By=ws(bi,"Promise"),zy=ws(bi,"Set"),Vy=ws(bi,"WeakMap"),kS="[object Map]",j7="[object Object]",jS="[object Promise]",$S="[object Set]",US="[object WeakMap]",qS="[object DataView]",$7=xs(Wy),U7=xs(Fu),q7=xs(By),H7=xs(zy),W7=xs(Vy),Ni=bs;(Wy&&Ni(new Wy(new ArrayBuffer(1)))!=qS||Fu&&Ni(new Fu)!=kS||By&&Ni(By.resolve())!=jS||zy&&Ni(new zy)!=$S||Vy&&Ni(new Vy)!=US)&&(Ni=function(t){var e=bs(t),r=e==j7?t.constructor:void 0,n=r?xs(r):"";if(n)switch(n){case $7:return qS;case U7:return kS;case q7:return jS;case H7:return $S;case W7:return US}return e});var B7=Object.prototype,z7=B7.hasOwnProperty;function V7(t){var e=t.length,r=new t.constructor(e);return e&&typeof t[0]=="string"&&z7.call(t,"index")&&(r.index=t.index,r.input=t.input),r}var HS=bi.Uint8Array;function pb(t){var e=new t.constructor(t.byteLength);return new HS(e).set(new HS(t)),e}function G7(t,e){var r=e?pb(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.byteLength)}var K7=/\w*$/;function X7(t){var e=new t.constructor(t.source,K7.exec(t));return e.lastIndex=t.lastIndex,e}var WS=xa?xa.prototype:void 0,BS=WS?WS.valueOf:void 0;function Y7(t){return BS?Object(BS.call(t)):{}}function Z7(t,e){var r=e?pb(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.length)}var J7="[object Boolean]",Q7="[object Date]",e9="[object Map]",t9="[object Number]",r9="[object RegExp]",n9="[object Set]",i9="[object String]",a9="[object Symbol]",s9="[object ArrayBuffer]",o9="[object DataView]",u9="[object Float32Array]",l9="[object Float64Array]",c9="[object Int8Array]",f9="[object Int16Array]",d9="[object Int32Array]",h9="[object Uint8Array]",p9="[object Uint8ClampedArray]",g9="[object Uint16Array]",m9="[object Uint32Array]";function v9(t,e,r){var n=t.constructor;switch(e){case s9:return pb(t);case J7:case Q7:return new n(+t);case o9:return G7(t,r);case u9:case l9:case c9:case f9:case d9:case h9:case p9:case g9:case m9:return Z7(t,r);case e9:return new n;case t9:case i9:return new n(t);case r9:return X7(t);case n9:return new n;case a9:return Y7(t)}}var zS=Object.create,y9=(function(){function t(){}return function(e){if(!Zu(e))return{};if(zS)return zS(e);t.prototype=e;var r=new t;return t.prototype=void 0,r}})();function b9(t){return typeof t.constructor=="function"&&!cb(t)?y9(ub(t)):{}}var _9="[object Map]";function x9(t){return _s(t)&&Ni(t)==_9}var VS=fo&&fo.isMap,w9=VS?lb(VS):x9,T9="[object Set]";function S9(t){return _s(t)&&Ni(t)==T9}var GS=fo&&fo.isSet,C9=GS?lb(GS):S9,E9=1,O9=2,A9=4,pM="[object Arguments]",I9="[object Array]",R9="[object Boolean]",D9="[object Date]",M9="[object Error]",gM="[object Function]",P9="[object GeneratorFunction]",L9="[object Map]",N9="[object Number]",mM="[object Object]",F9="[object RegExp]",k9="[object Set]",j9="[object String]",$9="[object Symbol]",U9="[object WeakMap]",q9="[object ArrayBuffer]",H9="[object DataView]",W9="[object Float32Array]",B9="[object Float64Array]",z9="[object Int8Array]",V9="[object Int16Array]",G9="[object Int32Array]",K9="[object Uint8Array]",X9="[object Uint8ClampedArray]",Y9="[object Uint16Array]",Z9="[object Uint32Array]",zt={};zt[pM]=zt[I9]=zt[q9]=zt[H9]=zt[R9]=zt[D9]=zt[W9]=zt[B9]=zt[z9]=zt[V9]=zt[G9]=zt[L9]=zt[N9]=zt[mM]=zt[F9]=zt[k9]=zt[j9]=zt[$9]=zt[K9]=zt[X9]=zt[Y9]=zt[Z9]=!0;zt[M9]=zt[gM]=zt[U9]=!1;function Eu(t,e,r,n,i,a){var s,o=e&E9,l=e&O9,c=e&A9;if(s!==void 0)return s;if(!Zu(t))return t;var d=Ju(t);if(d){if(s=V7(t),!o)return lM(t,s)}else{var h=Ni(t),g=h==gM||h==P9;if(nM(t))return I7(t,o);if(h==mM||h==pM||g&&!i){if(s=l||g?{}:b9(t),!o)return l?N7(t,O7(s,t)):P7(t,w7(s,t))}else{if(!zt[h])return i?t:{};s=v9(t,h,o)}}a||(a=new Co);var m=a.get(t);if(m)return m;a.set(t,s),C9(t)?t.forEach(function(y){s.add(Eu(y,e,r,y,t,a))}):w9(t)&&t.forEach(function(y,x){s.set(x,Eu(y,e,r,x,t,a))});var v=c?l?k7:F7:l?db:fb,b=d?void 0:v(t);return OG(b||t,function(y,x){b&&(x=y,y=t[x]),eM(s,x,Eu(y,e,r,x,t,a))}),s}var J9=1,Q9=4;function Wc(t){return Eu(t,J9|Q9)}var wg,KS;function eK(){if(KS)return wg;KS=1;var t=Array.isArray,e=Object.keys,r=Object.prototype.hasOwnProperty,n=typeof Element<"u";function i(a,s){if(a===s)return!0;if(a&&s&&typeof a=="object"&&typeof s=="object"){var o=t(a),l=t(s),c,d,h;if(o&&l){if(d=a.length,d!=s.length)return!1;for(c=d;c--!==0;)if(!i(a[c],s[c]))return!1;return!0}if(o!=l)return!1;var g=a instanceof Date,m=s instanceof Date;if(g!=m)return!1;if(g&&m)return a.getTime()==s.getTime();var v=a instanceof RegExp,b=s instanceof RegExp;if(v!=b)return!1;if(v&&b)return a.toString()==s.toString();var y=e(a);if(d=y.length,d!==e(s).length)return!1;for(c=d;c--!==0;)if(!r.call(s,y[c]))return!1;if(n&&a instanceof Element&&s instanceof Element)return a===s;for(c=d;c--!==0;)if(h=y[c],!(h==="_owner"&&a.$$typeof)&&!i(a[h],s[h]))return!1;return!0}return a!==a&&s!==s}return wg=function(s,o){try{return i(s,o)}catch(l){if(l.message&&l.message.match(/stack|recursion/i)||l.number===-2146828260)return console.warn("Warning: react-fast-compare does not handle circular references.",l.name,l.message),!1;throw l}},wg}var tK=eK();const Ga=vi(tK);var rK=4;function XS(t){return Eu(t,rK)}function vM(t,e){for(var r=-1,n=t==null?0:t.length,i=Array(n);++r<n;)i[r]=e(t[r],r,t);return i}var nK="[object Symbol]";function gb(t){return typeof t=="symbol"||_s(t)&&bs(t)==nK}var iK="Expected a function";function mb(t,e){if(typeof t!="function"||e!=null&&typeof e!="function")throw new TypeError(iK);var r=function(){var n=arguments,i=e?e.apply(this,n):n[0],a=r.cache;if(a.has(i))return a.get(i);var s=t.apply(this,n);return r.cache=a.set(i,s)||a,s};return r.cache=new(mb.Cache||Oa),r}mb.Cache=Oa;var aK=500;function sK(t){var e=mb(t,function(n){return r.size===aK&&r.clear(),n}),r=e.cache;return e}var oK=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,uK=/\\(\\)?/g,lK=sK(function(t){var e=[];return t.charCodeAt(0)===46&&e.push(""),t.replace(oK,function(r,n,i,a){e.push(i?a.replace(uK,"$1"):n||r)}),e});function cK(t){if(typeof t=="string"||gb(t))return t;var e=t+"";return e=="0"&&1/t==-1/0?"-0":e}var YS=xa?xa.prototype:void 0,ZS=YS?YS.toString:void 0;function yM(t){if(typeof t=="string")return t;if(Ju(t))return vM(t,yM)+"";if(gb(t))return ZS?ZS.call(t):"";var e=t+"";return e=="0"&&1/t==-1/0?"-0":e}function fK(t){return t==null?"":yM(t)}function bM(t){return Ju(t)?vM(t,cK):gb(t)?[t]:lM(lK(fK(t)))}var Tg={exports:{}},Lt={};/** @license React v16.13.1
|
|
73
|
+
* react-is.production.min.js
|
|
74
|
+
*
|
|
75
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
76
|
+
*
|
|
77
|
+
* This source code is licensed under the MIT license found in the
|
|
78
|
+
* LICENSE file in the root directory of this source tree.
|
|
79
|
+
*/var JS;function dK(){if(JS)return Lt;JS=1;var t=typeof Symbol=="function"&&Symbol.for,e=t?Symbol.for("react.element"):60103,r=t?Symbol.for("react.portal"):60106,n=t?Symbol.for("react.fragment"):60107,i=t?Symbol.for("react.strict_mode"):60108,a=t?Symbol.for("react.profiler"):60114,s=t?Symbol.for("react.provider"):60109,o=t?Symbol.for("react.context"):60110,l=t?Symbol.for("react.async_mode"):60111,c=t?Symbol.for("react.concurrent_mode"):60111,d=t?Symbol.for("react.forward_ref"):60112,h=t?Symbol.for("react.suspense"):60113,g=t?Symbol.for("react.suspense_list"):60120,m=t?Symbol.for("react.memo"):60115,v=t?Symbol.for("react.lazy"):60116,b=t?Symbol.for("react.block"):60121,y=t?Symbol.for("react.fundamental"):60117,x=t?Symbol.for("react.responder"):60118,w=t?Symbol.for("react.scope"):60119;function S(C){if(typeof C=="object"&&C!==null){var I=C.$$typeof;switch(I){case e:switch(C=C.type,C){case l:case c:case n:case a:case i:case h:return C;default:switch(C=C&&C.$$typeof,C){case o:case d:case v:case m:case s:return C;default:return I}}case r:return I}}}function E(C){return S(C)===c}return Lt.AsyncMode=l,Lt.ConcurrentMode=c,Lt.ContextConsumer=o,Lt.ContextProvider=s,Lt.Element=e,Lt.ForwardRef=d,Lt.Fragment=n,Lt.Lazy=v,Lt.Memo=m,Lt.Portal=r,Lt.Profiler=a,Lt.StrictMode=i,Lt.Suspense=h,Lt.isAsyncMode=function(C){return E(C)||S(C)===l},Lt.isConcurrentMode=E,Lt.isContextConsumer=function(C){return S(C)===o},Lt.isContextProvider=function(C){return S(C)===s},Lt.isElement=function(C){return typeof C=="object"&&C!==null&&C.$$typeof===e},Lt.isForwardRef=function(C){return S(C)===d},Lt.isFragment=function(C){return S(C)===n},Lt.isLazy=function(C){return S(C)===v},Lt.isMemo=function(C){return S(C)===m},Lt.isPortal=function(C){return S(C)===r},Lt.isProfiler=function(C){return S(C)===a},Lt.isStrictMode=function(C){return S(C)===i},Lt.isSuspense=function(C){return S(C)===h},Lt.isValidElementType=function(C){return typeof C=="string"||typeof C=="function"||C===n||C===c||C===a||C===i||C===h||C===g||typeof C=="object"&&C!==null&&(C.$$typeof===v||C.$$typeof===m||C.$$typeof===s||C.$$typeof===o||C.$$typeof===d||C.$$typeof===y||C.$$typeof===x||C.$$typeof===w||C.$$typeof===b)},Lt.typeOf=S,Lt}var QS;function hK(){return QS||(QS=1,Tg.exports=dK()),Tg.exports}var Sg,eC;function pK(){if(eC)return Sg;eC=1;var t=hK(),e={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},r={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},n={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},i={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},a={};a[t.ForwardRef]=n,a[t.Memo]=i;function s(v){return t.isMemo(v)?i:a[v.$$typeof]||e}var o=Object.defineProperty,l=Object.getOwnPropertyNames,c=Object.getOwnPropertySymbols,d=Object.getOwnPropertyDescriptor,h=Object.getPrototypeOf,g=Object.prototype;function m(v,b,y){if(typeof b!="string"){if(g){var x=h(b);x&&x!==g&&m(v,x,y)}var w=l(b);c&&(w=w.concat(c(b)));for(var S=s(v),E=s(b),C=0;C<w.length;++C){var I=w[C];if(!r[I]&&!(y&&y[I])&&!(E&&E[I])&&!(S&&S[I])){var T=d(b,I);try{o(v,I,T)}catch{}}}}return v}return Sg=m,Sg}pK();function Er(){return Er=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},Er.apply(this,arguments)}function _M(t,e){if(t==null)return{};var r={},n=Object.keys(t),i,a;for(a=0;a<n.length;a++)i=n[a],!(e.indexOf(i)>=0)&&(r[i]=t[i]);return r}var jd=md(void 0);jd.displayName="FormikContext";var gK=jd.Provider;jd.Consumer;function mK(){var t=zu(jd);return t}var $n=function(e){return typeof e=="function"},$d=function(e){return e!==null&&typeof e=="object"},vK=function(e){return String(Math.floor(Number(e)))===e},Cg=function(e){return Object.prototype.toString.call(e)==="[object String]"},Eg=function(e){return $d(e)&&$n(e.then)};function an(t,e,r,n){n===void 0&&(n=0);for(var i=bM(e);t&&n<i.length;)t=t[i[n++]];return n!==i.length&&!t||t===void 0?r:t}function ss(t,e,r){for(var n=XS(t),i=n,a=0,s=bM(e);a<s.length-1;a++){var o=s[a],l=an(t,s.slice(0,a+1));if(l&&($d(l)||Array.isArray(l)))i=i[o]=XS(l);else{var c=s[a+1];i=i[o]=vK(c)&&Number(c)>=0?[]:{}}}return(a===0?t:i)[s[a]]===r?t:(r===void 0?delete i[s[a]]:i[s[a]]=r,a===0&&r===void 0&&delete n[s[a]],n)}function xM(t,e,r,n){r===void 0&&(r=new WeakMap),n===void 0&&(n={});for(var i=0,a=Object.keys(t);i<a.length;i++){var s=a[i],o=t[s];$d(o)?r.get(o)||(r.set(o,!0),n[s]=Array.isArray(o)?[]:{},xM(o,e,r,n[s])):n[s]=e}return n}function yK(t,e){switch(e.type){case"SET_VALUES":return Er({},t,{values:e.payload});case"SET_TOUCHED":return Er({},t,{touched:e.payload});case"SET_ERRORS":return Ga(t.errors,e.payload)?t:Er({},t,{errors:e.payload});case"SET_STATUS":return Er({},t,{status:e.payload});case"SET_ISSUBMITTING":return Er({},t,{isSubmitting:e.payload});case"SET_ISVALIDATING":return Er({},t,{isValidating:e.payload});case"SET_FIELD_VALUE":return Er({},t,{values:ss(t.values,e.payload.field,e.payload.value)});case"SET_FIELD_TOUCHED":return Er({},t,{touched:ss(t.touched,e.payload.field,e.payload.value)});case"SET_FIELD_ERROR":return Er({},t,{errors:ss(t.errors,e.payload.field,e.payload.value)});case"RESET_FORM":return Er({},t,e.payload);case"SET_FORMIK_STATE":return e.payload(t);case"SUBMIT_ATTEMPT":return Er({},t,{touched:xM(t.values,!0),isSubmitting:!0,submitCount:t.submitCount+1});case"SUBMIT_FAILURE":return Er({},t,{isSubmitting:!1});case"SUBMIT_SUCCESS":return Er({},t,{isSubmitting:!1});default:return t}}var Wa={},Bc={};function bK(t){var e=t.validateOnChange,r=e===void 0?!0:e,n=t.validateOnBlur,i=n===void 0?!0:n,a=t.validateOnMount,s=a===void 0?!1:a,o=t.isInitialValid,l=t.enableReinitialize,c=l===void 0?!1:l,d=t.onSubmit,h=_M(t,["validateOnChange","validateOnBlur","validateOnMount","isInitialValid","enableReinitialize","onSubmit"]),g=Er({validateOnChange:r,validateOnBlur:i,validateOnMount:s,onSubmit:d},h),m=$t(g.initialValues),v=$t(g.initialErrors||Wa),b=$t(g.initialTouched||Bc),y=$t(g.initialStatus),x=$t(!1),w=$t({});ut(function(){return x.current=!0,function(){x.current=!1}},[]);var S=or(0),E=S[1],C=$t({values:Wc(g.initialValues),errors:Wc(g.initialErrors)||Wa,touched:Wc(g.initialTouched)||Bc,status:Wc(g.initialStatus),isSubmitting:!1,isValidating:!1,submitCount:0}),I=C.current,T=rt(function(W){var se=C.current;C.current=yK(se,W),se!==C.current&&E(function(ue){return ue+1})},[]),D=rt(function(W,se){return new Promise(function(ue,_e){var Re=g.validate(W,se);Re==null?ue(Wa):Eg(Re)?Re.then(function(Qe){ue(Qe||Wa)},function(Qe){_e(Qe)}):ue(Re)})},[g.validate]),P=rt(function(W,se){var ue=g.validationSchema,_e=$n(ue)?ue(se):ue,Re=se&&_e.validateAt?_e.validateAt(se,W):xK(W,_e);return new Promise(function(Qe,St){Re.then(function(){Qe(Wa)},function(Ct){Ct.name==="ValidationError"?Qe(_K(Ct)):St(Ct)})})},[g.validationSchema]),L=rt(function(W,se){return new Promise(function(ue){return ue(w.current[W].validate(se))})},[]),F=rt(function(W){var se=Object.keys(w.current).filter(function(_e){return $n(w.current[_e].validate)}),ue=se.length>0?se.map(function(_e){return L(_e,an(W,_e))}):[Promise.resolve("DO_NOT_DELETE_YOU_WILL_BE_FIRED")];return Promise.all(ue).then(function(_e){return _e.reduce(function(Re,Qe,St){return Qe==="DO_NOT_DELETE_YOU_WILL_BE_FIRED"||Qe&&(Re=ss(Re,se[St],Qe)),Re},{})})},[L]),H=rt(function(W){return Promise.all([F(W),g.validationSchema?P(W):{},g.validate?D(W):{}]).then(function(se){var ue=se[0],_e=se[1],Re=se[2],Qe=Hy.all([ue,_e,Re],{arrayMerge:wK});return Qe})},[g.validate,g.validationSchema,F,D,P]),X=kn(function(W){return W===void 0&&(W=I.values),T({type:"SET_ISVALIDATING",payload:!0}),H(W).then(function(se){return x.current&&(T({type:"SET_ISVALIDATING",payload:!1}),T({type:"SET_ERRORS",payload:se})),se})});ut(function(){s&&x.current===!0&&Ga(m.current,g.initialValues)&&X(m.current)},[s,X]);var ee=rt(function(W){var se=W&&W.values?W.values:m.current,ue=W&&W.errors?W.errors:v.current?v.current:g.initialErrors||{},_e=W&&W.touched?W.touched:b.current?b.current:g.initialTouched||{},Re=W&&W.status?W.status:y.current?y.current:g.initialStatus;m.current=se,v.current=ue,b.current=_e,y.current=Re;var Qe=function(){T({type:"RESET_FORM",payload:{isSubmitting:!!W&&!!W.isSubmitting,errors:ue,touched:_e,status:Re,values:se,isValidating:!!W&&!!W.isValidating,submitCount:W&&W.submitCount&&typeof W.submitCount=="number"?W.submitCount:0}})};if(g.onReset){var St=g.onReset(I.values,Je);Eg(St)?St.then(Qe):Qe()}else Qe()},[g.initialErrors,g.initialStatus,g.initialTouched,g.onReset]);ut(function(){x.current===!0&&!Ga(m.current,g.initialValues)&&c&&(m.current=g.initialValues,ee(),s&&X(m.current))},[c,g.initialValues,ee,s,X]),ut(function(){c&&x.current===!0&&!Ga(v.current,g.initialErrors)&&(v.current=g.initialErrors||Wa,T({type:"SET_ERRORS",payload:g.initialErrors||Wa}))},[c,g.initialErrors]),ut(function(){c&&x.current===!0&&!Ga(b.current,g.initialTouched)&&(b.current=g.initialTouched||Bc,T({type:"SET_TOUCHED",payload:g.initialTouched||Bc}))},[c,g.initialTouched]),ut(function(){c&&x.current===!0&&!Ga(y.current,g.initialStatus)&&(y.current=g.initialStatus,T({type:"SET_STATUS",payload:g.initialStatus}))},[c,g.initialStatus,g.initialTouched]);var J=kn(function(W){if(w.current[W]&&$n(w.current[W].validate)){var se=an(I.values,W),ue=w.current[W].validate(se);return Eg(ue)?(T({type:"SET_ISVALIDATING",payload:!0}),ue.then(function(_e){return _e}).then(function(_e){T({type:"SET_FIELD_ERROR",payload:{field:W,value:_e}}),T({type:"SET_ISVALIDATING",payload:!1})})):(T({type:"SET_FIELD_ERROR",payload:{field:W,value:ue}}),Promise.resolve(ue))}else if(g.validationSchema)return T({type:"SET_ISVALIDATING",payload:!0}),P(I.values,W).then(function(_e){return _e}).then(function(_e){T({type:"SET_FIELD_ERROR",payload:{field:W,value:an(_e,W)}}),T({type:"SET_ISVALIDATING",payload:!1})});return Promise.resolve()}),te=rt(function(W,se){var ue=se.validate;w.current[W]={validate:ue}},[]),ce=rt(function(W){delete w.current[W]},[]),B=kn(function(W,se){T({type:"SET_TOUCHED",payload:W});var ue=se===void 0?i:se;return ue?X(I.values):Promise.resolve()}),ae=rt(function(W){T({type:"SET_ERRORS",payload:W})},[]),Ce=kn(function(W,se){var ue=$n(W)?W(I.values):W;T({type:"SET_VALUES",payload:ue});var _e=se===void 0?r:se;return _e?X(ue):Promise.resolve()}),Ae=rt(function(W,se){T({type:"SET_FIELD_ERROR",payload:{field:W,value:se}})},[]),ve=kn(function(W,se,ue){var _e=$n(se)?se(an(I.values,W)):se;T({type:"SET_FIELD_VALUE",payload:{field:W,value:_e}});var Re=ue===void 0?r:ue;return Re?X(ss(I.values,W,_e)):Promise.resolve()}),ct=rt(function(W,se){var ue=se,_e=W,Re;if(!Cg(W)){W.persist&&W.persist();var Qe=W.target?W.target:W.currentTarget,St=Qe.type,Ct=Qe.name,Zr=Qe.id,Ur=Qe.value,_i=Qe.checked;Qe.outerHTML;var Rr=Qe.options,En=Qe.multiple;ue=se||Ct||Zr,_e=/number|range/.test(St)?(Re=parseFloat(Ur),isNaN(Re)?"":Re):/checkbox/.test(St)?SK(an(I.values,ue),_i,Ur):Rr&&En?TK(Rr):Ur}ue&&ve(ue,_e)},[ve,I.values]),Ge=kn(function(W){if(Cg(W))return function(se){return ct(se,W)};ct(W)}),Le=kn(function(W,se,ue){se===void 0&&(se=!0),T({type:"SET_FIELD_TOUCHED",payload:{field:W,value:se}});var _e=ue===void 0?i:ue;return _e?X(I.values):Promise.resolve()}),Ue=rt(function(W,se){W.persist&&W.persist();var ue=W.target,_e=ue.name,Re=ue.id;ue.outerHTML;var Qe=se||_e||Re;Le(Qe,!0)},[Le]),ht=kn(function(W){if(Cg(W))return function(se){return Ue(se,W)};Ue(W)}),We=rt(function(W){$n(W)?T({type:"SET_FORMIK_STATE",payload:W}):T({type:"SET_FORMIK_STATE",payload:function(){return W}})},[]),Se=rt(function(W){T({type:"SET_STATUS",payload:W})},[]),xe=rt(function(W){T({type:"SET_ISSUBMITTING",payload:W})},[]),Ze=kn(function(){return T({type:"SUBMIT_ATTEMPT"}),X().then(function(W){var se=W instanceof Error,ue=!se&&Object.keys(W).length===0;if(ue){var _e;try{if(_e=Rt(),_e===void 0)return}catch(Re){throw Re}return Promise.resolve(_e).then(function(Re){return x.current&&T({type:"SUBMIT_SUCCESS"}),Re}).catch(function(Re){if(x.current)throw T({type:"SUBMIT_FAILURE"}),Re})}else if(x.current&&(T({type:"SUBMIT_FAILURE"}),se))throw W})}),Oe=kn(function(W){W&&W.preventDefault&&$n(W.preventDefault)&&W.preventDefault(),W&&W.stopPropagation&&$n(W.stopPropagation)&&W.stopPropagation(),Ze().catch(function(se){console.warn("Warning: An unhandled error was caught from submitForm()",se)})}),Je={resetForm:ee,validateForm:X,validateField:J,setErrors:ae,setFieldError:Ae,setFieldTouched:Le,setFieldValue:ve,setStatus:Se,setSubmitting:xe,setTouched:B,setValues:Ce,setFormikState:We,submitForm:Ze},Rt=kn(function(){return d(I.values,Je)}),ft=kn(function(W){W&&W.preventDefault&&$n(W.preventDefault)&&W.preventDefault(),W&&W.stopPropagation&&$n(W.stopPropagation)&&W.stopPropagation(),ee()}),Ne=rt(function(W){return{value:an(I.values,W),error:an(I.errors,W),touched:!!an(I.touched,W),initialValue:an(m.current,W),initialTouched:!!an(b.current,W),initialError:an(v.current,W)}},[I.errors,I.touched,I.values]),Nt=rt(function(W){return{setValue:function(ue,_e){return ve(W,ue,_e)},setTouched:function(ue,_e){return Le(W,ue,_e)},setError:function(ue){return Ae(W,ue)}}},[ve,Le,Ae]),Ot=rt(function(W){var se=$d(W),ue=se?W.name:W,_e=an(I.values,ue),Re={name:ue,value:_e,onChange:Ge,onBlur:ht};if(se){var Qe=W.type,St=W.value,Ct=W.as,Zr=W.multiple;Qe==="checkbox"?St===void 0?Re.checked=!!_e:(Re.checked=!!(Array.isArray(_e)&&~_e.indexOf(St)),Re.value=St):Qe==="radio"?(Re.checked=_e===St,Re.value=St):Ct==="select"&&Zr&&(Re.value=Re.value||[],Re.multiple=!0)}return Re},[ht,Ge,I.values]),Lr=yr(function(){return!Ga(m.current,I.values)},[m.current,I.values]),Yr=yr(function(){return typeof o<"u"?Lr?I.errors&&Object.keys(I.errors).length===0:o!==!1&&$n(o)?o(g):o:I.errors&&Object.keys(I.errors).length===0},[o,Lr,I.errors,g]),fr=Er({},I,{initialValues:m.current,initialErrors:v.current,initialTouched:b.current,initialStatus:y.current,handleBlur:ht,handleChange:Ge,handleReset:ft,handleSubmit:Oe,resetForm:ee,setErrors:ae,setFormikState:We,setFieldTouched:Le,setFieldValue:ve,setFieldError:Ae,setStatus:Se,setSubmitting:xe,setTouched:B,setValues:Ce,submitForm:Ze,validateForm:X,validateField:J,isValid:Yr,dirty:Lr,unregisterField:ce,registerField:te,getFieldProps:Ot,getFieldMeta:Ne,getFieldHelpers:Nt,validateOnBlur:i,validateOnChange:r,validateOnMount:s});return fr}function _K(t){var e={};if(t.inner){if(t.inner.length===0)return ss(e,t.path,t.message);for(var i=t.inner,r=Array.isArray(i),n=0,i=r?i:i[Symbol.iterator]();;){var a;if(r){if(n>=i.length)break;a=i[n++]}else{if(n=i.next(),n.done)break;a=n.value}var s=a;an(e,s.path)||(e=ss(e,s.path,s.message))}}return e}function xK(t,e,r,n){r===void 0&&(r=!1);var i=Gy(t);return e[r?"validateSync":"validate"](i,{abortEarly:!1,context:i})}function Gy(t){var e=Array.isArray(t)?[]:{};for(var r in t)if(Object.prototype.hasOwnProperty.call(t,r)){var n=String(r);Array.isArray(t[n])===!0?e[n]=t[n].map(function(i){return Array.isArray(i)===!0||ES(i)?Gy(i):i!==""?i:void 0}):ES(t[n])?e[n]=Gy(t[n]):e[n]=t[n]!==""?t[n]:void 0}return e}function wK(t,e,r){var n=t.slice();return e.forEach(function(a,s){if(typeof n[s]>"u"){var o=r.clone!==!1,l=o&&r.isMergeableObject(a);n[s]=l?Hy(Array.isArray(a)?[]:{},a,r):a}else r.isMergeableObject(a)?n[s]=Hy(t[s],a,r):t.indexOf(a)===-1&&n.push(a)}),n}function TK(t){return Array.from(t).filter(function(e){return e.selected}).map(function(e){return e.value})}function SK(t,e,r){if(typeof t=="boolean")return!!e;var n=[],i=!1,a=-1;if(Array.isArray(t))n=t,a=t.indexOf(r),i=a>=0;else if(!r||r=="true"||r=="false")return!!e;return e&&r&&!i?n.concat(r):i?n.slice(0,a).concat(n.slice(a+1)):n}var CK=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u"?Bu:ut;function kn(t){var e=$t(t);return CK(function(){e.current=t}),rt(function(){for(var r=arguments.length,n=new Array(r),i=0;i<r;i++)n[i]=arguments[i];return e.current.apply(void 0,n)},[])}var EK=Cn(function(t,e){var r=t.action,n=_M(t,["action"]),i=r??"#",a=mK(),s=a.handleReset,o=a.handleSubmit;return to("form",Er({onSubmit:o,ref:e,onReset:s,action:i},n))});EK.displayName="Form";function wM(t){var e,r,n="";if(typeof t=="string"||typeof t=="number")n+=t;else if(typeof t=="object")if(Array.isArray(t))for(e=0;e<t.length;e++)t[e]&&(r=wM(t[e]))&&(n&&(n+=" "),n+=r);else for(e in t)t[e]&&(n&&(n+=" "),n+=e);return n}function Ud(){for(var t,e,r=0,n="";r<arguments.length;)(t=arguments[r++])&&(e=wM(t))&&(n&&(n+=" "),n+=e);return n}let OK={data:""},AK=t=>{if(typeof window=="object"){let e=(t?t.querySelector("#_goober"):window._goober)||Object.assign(document.createElement("style"),{innerHTML:" ",id:"_goober"});return e.nonce=window.__nonce__,e.parentNode||(t||document.head).appendChild(e),e.firstChild}return t||OK},IK=/(?:([\u0080-\uFFFF\w-%@]+) *:? *([^{;]+?);|([^;}{]*?) *{)|(}\s*)/g,RK=/\/\*[^]*?\*\/| +/g,tC=/\n+/g,es=(t,e)=>{let r="",n="",i="";for(let a in t){let s=t[a];a[0]=="@"?a[1]=="i"?r=a+" "+s+";":n+=a[1]=="f"?es(s,a):a+"{"+es(s,a[1]=="k"?"":e)+"}":typeof s=="object"?n+=es(s,e?e.replace(/([^,])+/g,o=>a.replace(/([^,]*:\S+\([^)]*\))|([^,])+/g,l=>/&/.test(l)?l.replace(/&/g,o):o?o+" "+l:l)):a):s!=null&&(a=a[1]=="-"?a:a.replace(/[A-Z]/g,"-$&").toLowerCase(),i+=es.p?es.p(a,s):a+":"+s+";")}return r+(e&&i?e+"{"+i+"}":i)+n},sa={},TM=t=>{if(typeof t=="object"){let e="";for(let r in t)e+=r+TM(t[r]);return e}return t},DK=(t,e,r,n,i)=>{let a=TM(t),s=sa[a]||(sa[a]=(l=>{let c=0,d=11;for(;c<l.length;)d=101*d+l.charCodeAt(c++)>>>0;return"go"+d})(a));if(!sa[s]){let l=a!==t?t:(c=>{let d,h,g=[{}];for(;d=IK.exec(c.replace(RK,""));)d[4]?g.shift():d[3]?(h=d[3].replace(tC," ").trim(),g.unshift(g[0][h]=g[0][h]||{})):g[0][d[1]]=d[2].replace(tC," ").trim();return g[0]})(t);sa[s]=es(i?{["@keyframes "+s]:l}:l,r?"":"."+s)}let o=r&&sa.g;return r&&(sa.g=sa[s]),((l,c,d,h)=>{h?c.data=c.data.replace(h,l):c.data.indexOf(l)===-1&&(c.data=d?l+c.data:c.data+l)})(sa[s],e,n,o),s},MK=(t,e,r)=>t.reduce((n,i,a)=>{let s=e[a];if(s&&s.call){let o=s(r),l=o&&o.props&&o.props.className||/^go/.test(o)&&o;s=l?"."+l:o&&typeof o=="object"?o.props?"":es(o,""):o===!1?"":o}return n+i+(s??"")},"");function vb(t){let e=this||{},r=t.call?t(e.p):t;return DK(r.unshift?r.raw?MK(r,[].slice.call(arguments,1),e.p):r.reduce((n,i)=>Object.assign(n,i&&i.call?i(e.p):i),{}):r,AK(e.target),e.g,e.o,e.k)}vb.bind({g:1});vb.bind({k:1});function PK(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function LK(t,e,r){return e&&PK(t.prototype,e),t}function ga(){return ga=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},ga.apply(this,arguments)}function NK(t,e){t.prototype=Object.create(e.prototype),t.prototype.constructor=t,t.__proto__=e}function yb(t,e){if(t==null)return{};var r={},n=Object.keys(t),i,a;for(a=0;a<n.length;a++)i=n[a],!(e.indexOf(i)>=0)&&(r[i]=t[i]);return r}var rC=function(){return""},FK=He.createContext({enqueueSnackbar:rC,closeSnackbar:rC}),Ka={downXs:"@media (max-width:599.95px)",upSm:"@media (min-width:600px)"},zc="unmounted",Ks="exited",Xs="entering",au="entered",nC="exiting",bb=(function(t){NK(e,t);function e(n){var i;i=t.call(this,n)||this;var a=n.appear,s;return i.appearStatus=null,n.in?a?(s=Ks,i.appearStatus=Xs):s=au:n.unmountOnExit||n.mountOnEnter?s=zc:s=Ks,i.state={status:s},i.nextCallback=null,i}e.getDerivedStateFromProps=function(i,a){var s=i.in;return s&&a.status===zc?{status:Ks}:null};var r=e.prototype;return r.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},r.componentDidUpdate=function(i){var a=null;if(i!==this.props){var s=this.state.status;this.props.in?s!==Xs&&s!==au&&(a=Xs):(s===Xs||s===au)&&(a=nC)}this.updateStatus(!1,a)},r.componentWillUnmount=function(){this.cancelNextCallback()},r.getTimeouts=function(){var i=this.props.timeout,a=i,s=i;return i!=null&&typeof i!="number"&&typeof i!="string"&&(s=i.exit,a=i.enter),{exit:s,enter:a}},r.updateStatus=function(i,a){i===void 0&&(i=!1),a!==null?(this.cancelNextCallback(),a===Xs?this.performEnter(i):this.performExit()):this.props.unmountOnExit&&this.state.status===Ks&&this.setState({status:zc})},r.performEnter=function(i){var a=this,s=this.props.enter,o=i,l=this.getTimeouts();if(!i&&!s){this.safeSetState({status:au},function(){a.props.onEntered&&a.props.onEntered(a.node,o)});return}this.props.onEnter&&this.props.onEnter(this.node,o),this.safeSetState({status:Xs},function(){a.props.onEntering&&a.props.onEntering(a.node,o),a.onTransitionEnd(l.enter,function(){a.safeSetState({status:au},function(){a.props.onEntered&&a.props.onEntered(a.node,o)})})})},r.performExit=function(){var i=this,a=this.props.exit,s=this.getTimeouts();if(!a){this.safeSetState({status:Ks},function(){i.props.onExited&&i.props.onExited(i.node)});return}this.props.onExit&&this.props.onExit(this.node),this.safeSetState({status:nC},function(){i.props.onExiting&&i.props.onExiting(i.node),i.onTransitionEnd(s.exit,function(){i.safeSetState({status:Ks},function(){i.props.onExited&&i.props.onExited(i.node)})})})},r.cancelNextCallback=function(){this.nextCallback!==null&&this.nextCallback.cancel&&(this.nextCallback.cancel(),this.nextCallback=null)},r.safeSetState=function(i,a){a=this.setNextCallback(a),this.setState(i,a)},r.setNextCallback=function(i){var a=this,s=!0;return this.nextCallback=function(){s&&(s=!1,a.nextCallback=null,i())},this.nextCallback.cancel=function(){s=!1},this.nextCallback},r.onTransitionEnd=function(i,a){this.setNextCallback(a);var s=i==null&&!this.props.addEndListener;if(!this.node||s){setTimeout(this.nextCallback,0);return}this.props.addEndListener&&this.props.addEndListener(this.node,this.nextCallback),i!=null&&setTimeout(this.nextCallback,i)},r.render=function(){var i=this.state.status;if(i===zc)return null;var a=this.props,s=a.children,o=yb(a,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return s(i,o)},LK(e,[{key:"node",get:function(){var i,a=(i=this.props.nodeRef)===null||i===void 0?void 0:i.current;if(!a)throw new Error("notistack - Custom snackbar is not refForwarding");return a}}]),e})(He.Component);function Ys(){}bb.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:Ys,onEntering:Ys,onEntered:Ys,onExit:Ys,onExiting:Ys,onExited:Ys};function iC(t,e){typeof t=="function"?t(e):t&&(t.current=e)}function Ky(t,e){return yr(function(){return t==null&&e==null?null:function(r){iC(t,r),iC(e,r)}},[t,e])}function ed(t){var e=t.timeout,r=t.style,n=r===void 0?{}:r,i=t.mode;return{duration:typeof e=="object"?e[i]||0:e,easing:n.transitionTimingFunction,delay:n.transitionDelay}}var Xy={easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"},SM=function(e){e.scrollTop=e.scrollTop},aC=function(e){return Math.round(e)+"ms"};function Js(t,e){t===void 0&&(t=["all"]);var r=e||{},n=r.duration,i=n===void 0?300:n,a=r.easing,s=a===void 0?Xy.easeInOut:a,o=r.delay,l=o===void 0?0:o,c=Array.isArray(t)?t:[t];return c.map(function(d){var h=typeof i=="string"?i:aC(i),g=typeof l=="string"?l:aC(l);return d+" "+h+" "+s+" "+g}).join(",")}function kK(t){return t&&t.ownerDocument||document}function CM(t){var e=kK(t);return e.defaultView||window}function jK(t,e){e===void 0&&(e=166);var r;function n(){for(var i=this,a=arguments.length,s=new Array(a),o=0;o<a;o++)s[o]=arguments[o];var l=function(){t.apply(i,s)};clearTimeout(r),r=setTimeout(l,e)}return n.clear=function(){clearTimeout(r)},n}function $K(t,e){var r=e.getBoundingClientRect(),n=CM(e),i;if(e.fakeTransform)i=e.fakeTransform;else{var a=n.getComputedStyle(e);i=a.getPropertyValue("-webkit-transform")||a.getPropertyValue("transform")}var s=0,o=0;if(i&&i!=="none"&&typeof i=="string"){var l=i.split("(")[1].split(")")[0].split(",");s=parseInt(l[4],10),o=parseInt(l[5],10)}switch(t){case"left":return"translateX("+(n.innerWidth+s-r.left)+"px)";case"right":return"translateX(-"+(r.left+r.width-s)+"px)";case"up":return"translateY("+(n.innerHeight+o-r.top)+"px)";default:return"translateY(-"+(r.top+r.height-o)+"px)"}}function Vc(t,e){if(e){var r=$K(t,e);r&&(e.style.webkitTransform=r,e.style.transform=r)}}var UK=Cn(function(t,e){var r=t.children,n=t.direction,i=n===void 0?"down":n,a=t.in,s=t.style,o=t.timeout,l=o===void 0?0:o,c=t.onEnter,d=t.onEntered,h=t.onExit,g=t.onExited,m=yb(t,["children","direction","in","style","timeout","onEnter","onEntered","onExit","onExited"]),v=$t(null),b=Ky(r.ref,v),y=Ky(b,e),x=function(T,D){Vc(i,T),SM(T),c&&c(T,D)},w=function(T){var D=(s==null?void 0:s.transitionTimingFunction)||Xy.easeOut,P=ed({timeout:l,mode:"enter",style:ga({},s,{transitionTimingFunction:D})});T.style.webkitTransition=Js("-webkit-transform",P),T.style.transition=Js("transform",P),T.style.webkitTransform="none",T.style.transform="none"},S=function(T){var D=(s==null?void 0:s.transitionTimingFunction)||Xy.sharp,P=ed({timeout:l,mode:"exit",style:ga({},s,{transitionTimingFunction:D})});T.style.webkitTransition=Js("-webkit-transform",P),T.style.transition=Js("transform",P),Vc(i,T),h&&h(T)},E=function(T){T.style.webkitTransition="",T.style.transition="",g&&g(T)},C=rt(function(){v.current&&Vc(i,v.current)},[i]);return ut(function(){if(!(a||i==="down"||i==="right")){var I=jK(function(){v.current&&Vc(i,v.current)}),T=CM(v.current);return T.addEventListener("resize",I),function(){I.clear(),T.removeEventListener("resize",I)}}},[i,a]),ut(function(){a||C()},[a,C]),to(bb,Object.assign({appear:!0,nodeRef:v,onEnter:x,onEntered:d,onEntering:w,onExit:S,onExited:E,in:a,timeout:l},m),function(I,T){return IU(r,ga({ref:y,style:ga({visibility:I==="exited"&&!a?"hidden":void 0},s,{},r.props.style)},T))})});UK.displayName="Slide";function qd(t){return Object.entries(t).reduce(function(e,r){var n,i=r[0],a=r[1];return ga({},e,(n={},n[i]=vb(a),n))},{})}var ju={SnackbarContainer:"notistack-SnackbarContainer",Snackbar:"notistack-Snackbar",CollapseWrapper:"notistack-CollapseWrapper",MuiContent:"notistack-MuiContent",MuiContentVariant:function(e){return"notistack-MuiContent-"+e}},sC=qd({root:{height:0},entered:{height:"auto"}}),Og="0px",Ag=175,qK=Cn(function(t,e){var r=t.children,n=t.in,i=t.onExited,a=$t(null),s=$t(null),o=Ky(e,s),l=function(){return a.current?a.current.clientHeight:0},c=function(b){b.style.height=Og},d=function(b){var y=l(),x=ed({timeout:Ag,mode:"enter"}),w=x.duration,S=x.easing;b.style.transitionDuration=typeof w=="string"?w:w+"ms",b.style.height=y+"px",b.style.transitionTimingFunction=S||""},h=function(b){b.style.height="auto"},g=function(b){b.style.height=l()+"px"},m=function(b){SM(b);var y=ed({timeout:Ag,mode:"exit"}),x=y.duration,w=y.easing;b.style.transitionDuration=typeof x=="string"?x:x+"ms",b.style.height=Og,b.style.transitionTimingFunction=w||""};return to(bb,{in:n,unmountOnExit:!0,onEnter:c,onEntered:h,onEntering:d,onExit:g,onExited:i,onExiting:m,nodeRef:s,timeout:Ag},function(v,b){return to("div",Object.assign({ref:o,className:Ud(sC.root,v==="entered"&&sC.entered),style:ga({pointerEvents:"all",overflow:"hidden",minHeight:Og,transition:Js("height")},v==="entered"&&{overflow:"visible"},{},v==="exited"&&!n&&{visibility:"hidden"})},b),to("div",{ref:a,className:ju.CollapseWrapper,style:{display:"flex",width:"100%"}},r))})});qK.displayName="Collapse";var HK=typeof window<"u"?Bu:ut;function oC(t){var e=$t(t);return HK(function(){e.current=t}),rt(function(){return e.current.apply(void 0,arguments)},[])}var WK=Cn(function(t,e){var r=t.children,n=t.className,i=t.autoHideDuration,a=t.disableWindowBlurListener,s=a===void 0?!1:a,o=t.onClose,l=t.id,c=t.open,d=t.SnackbarProps,h=d===void 0?{}:d,g=$t(),m=oC(function(){o&&o.apply(void 0,arguments)}),v=oC(function(S){!o||S==null||(g.current&&clearTimeout(g.current),g.current=setTimeout(function(){m(null,"timeout",l)},S))});ut(function(){return c&&v(i),function(){g.current&&clearTimeout(g.current)}},[c,i,v]);var b=function(){g.current&&clearTimeout(g.current)},y=rt(function(){i!=null&&v(i*.5)},[i,v]),x=function(E){h.onMouseEnter&&h.onMouseEnter(E),b()},w=function(E){h.onMouseLeave&&h.onMouseLeave(E),y()};return ut(function(){if(!s&&c)return window.addEventListener("focus",y),window.addEventListener("blur",b),function(){window.removeEventListener("focus",y),window.removeEventListener("blur",b)}},[s,y,c]),to("div",Object.assign({ref:e},h,{className:Ud(ju.Snackbar,n),onMouseEnter:x,onMouseLeave:w}),r)});WK.displayName="Snackbar";var Ig,BK=qd({root:(Ig={display:"flex",flexWrap:"wrap",flexGrow:1},Ig[Ka.upSm]={flexGrow:"initial",minWidth:"288px"},Ig)}),EM=Cn(function(t,e){var r=t.className,n=yb(t,["className"]);return He.createElement("div",Object.assign({ref:e,className:Ud(BK.root,r)},n))});EM.displayName="SnackbarContent";var su=qd({root:{backgroundColor:"#313131",fontSize:"0.875rem",lineHeight:1.43,letterSpacing:"0.01071em",color:"#fff",alignItems:"center",padding:"6px 16px",borderRadius:"4px",boxShadow:"0px 3px 5px -1px rgba(0,0,0,0.2),0px 6px 10px 0px rgba(0,0,0,0.14),0px 1px 18px 0px rgba(0,0,0,0.12)"},lessPadding:{paddingLeft:8*2.5+"px"},default:{backgroundColor:"#313131"},success:{backgroundColor:"#43a047"},error:{backgroundColor:"#d32f2f"},warning:{backgroundColor:"#ff9800"},info:{backgroundColor:"#2196f3"},message:{display:"flex",alignItems:"center",padding:"8px 0"},action:{display:"flex",alignItems:"center",marginLeft:"auto",paddingLeft:"16px",marginRight:"-8px"}}),uC="notistack-snackbar",zK=Cn(function(t,e){var r=t.id,n=t.message,i=t.action,a=t.iconVariant,s=t.variant,o=t.hideIconVariant,l=t.style,c=t.className,d=a[s],h=i;return typeof h=="function"&&(h=h(r)),He.createElement(EM,{ref:e,role:"alert","aria-describedby":uC,style:l,className:Ud(ju.MuiContent,ju.MuiContentVariant(s),su.root,su[s],c,!o&&d&&su.lessPadding)},He.createElement("div",{id:uC,className:su.message},o?null:d,n),h&&He.createElement("div",{className:su.action},h))});zK.displayName="MaterialDesignContent";var ou,Rg,Gc,Kc,Dg,Di={view:{default:20},snackbar:{default:6,dense:2}},lC="."+ju.CollapseWrapper,Mg=16;ou={boxSizing:"border-box",display:"flex",maxHeight:"100%",position:"fixed",zIndex:1400,height:"auto",width:"auto",transition:Js(["top","right","bottom","left","max-width"],{duration:300,easing:"ease"}),pointerEvents:"none"},ou[lC]={padding:Di.snackbar.default+"px 0px",transition:"padding 300ms ease 0ms"},ou.maxWidth="calc(100% - "+Di.view.default*2+"px)",ou[Ka.downXs]={width:"100%",maxWidth:"calc(100% - "+Mg*2+"px)"},Rg={},Rg[lC]={padding:Di.snackbar.dense+"px 0px"},Di.view.default-Di.snackbar.default+"",Di.view.default-Di.snackbar.default+"",Gc={left:Di.view.default+"px"},Gc[Ka.upSm]={alignItems:"flex-start"},Gc[Ka.downXs]={left:Mg+"px"},Kc={right:Di.view.default+"px"},Kc[Ka.upSm]={alignItems:"flex-end"},Kc[Ka.downXs]={right:Mg+"px"},Dg={left:"50%",transform:"translateX(-50%)"},Dg[Ka.upSm]={alignItems:"center"};var VK=(function(){return zu(FK)}),Yy;try{Yy=Map}catch{}var Zy;try{Zy=Set}catch{}function OM(t,e,r){if(!t||typeof t!="object"||typeof t=="function")return t;if(t.nodeType&&"cloneNode"in t)return t.cloneNode(!0);if(t instanceof Date)return new Date(t.getTime());if(t instanceof RegExp)return new RegExp(t);if(Array.isArray(t))return t.map(Jy);if(Yy&&t instanceof Yy)return new Map(Array.from(t.entries()));if(Zy&&t instanceof Zy)return new Set(Array.from(t.values()));if(t instanceof Object){e.push(t);var n=Object.create(t);r.push(n);for(var i in t){var a=e.findIndex(function(s){return s===t[i]});n[i]=a>-1?r[a]:OM(t[i],e,r)}return n}return t}function Jy(t){return OM(t,[],[])}const GK=Object.prototype.toString,KK=Error.prototype.toString,XK=RegExp.prototype.toString,YK=typeof Symbol<"u"?Symbol.prototype.toString:()=>"",ZK=/^Symbol\((.*)\)(.*)$/;function JK(t){return t!=+t?"NaN":t===0&&1/t<0?"-0":""+t}function cC(t,e=!1){if(t==null||t===!0||t===!1)return""+t;const r=typeof t;if(r==="number")return JK(t);if(r==="string")return e?`"${t}"`:t;if(r==="function")return"[Function "+(t.name||"anonymous")+"]";if(r==="symbol")return YK.call(t).replace(ZK,"Symbol($1)");const n=GK.call(t).slice(8,-1);return n==="Date"?isNaN(t.getTime())?""+t:t.toISOString(t):n==="Error"||t instanceof Error?"["+KK.call(t)+"]":n==="RegExp"?XK.call(t):null}function ho(t,e){let r=cC(t,e);return r!==null?r:JSON.stringify(t,function(n,i){let a=cC(this[n],e);return a!==null?a:i},2)}let Xa={default:"${path} is invalid",required:"${path} is a required field",oneOf:"${path} must be one of the following values: ${values}",notOneOf:"${path} must not be one of the following values: ${values}",notType:({path:t,type:e,value:r,originalValue:n})=>{let i=n!=null&&n!==r,a=`${t} must be a \`${e}\` type, but the final value was: \`${ho(r,!0)}\``+(i?` (cast from the value \`${ho(n,!0)}\`).`:".");return r===null&&(a+='\n If "null" is intended as an empty value be sure to mark the schema as `.nullable()`'),a},defined:"${path} must be defined"},Jn={length:"${path} must be exactly ${length} characters",min:"${path} must be at least ${min} characters",max:"${path} must be at most ${max} characters",matches:'${path} must match the following: "${regex}"',email:"${path} must be a valid email",url:"${path} must be a valid URL",uuid:"${path} must be a valid UUID",trim:"${path} must be a trimmed string",lowercase:"${path} must be a lowercase string",uppercase:"${path} must be a upper case string"},ca={min:"${path} must be greater than or equal to ${min}",max:"${path} must be less than or equal to ${max}",lessThan:"${path} must be less than ${less}",moreThan:"${path} must be greater than ${more}",positive:"${path} must be a positive number",negative:"${path} must be a negative number",integer:"${path} must be an integer"},Qy={min:"${path} field must be later than ${min}",max:"${path} field must be at earlier than ${max}"},e0={isValue:"${path} field must be ${value}"},t0={noUnknown:"${path} field has unspecified keys: ${unknown}"},_f={min:"${path} field must have at least ${min} items",max:"${path} field must have less than or equal to ${max} items",length:"${path} must have ${length} items"};const QK=Object.assign(Object.create(null),{mixed:Xa,string:Jn,number:ca,date:Qy,object:t0,array:_f,boolean:e0});var Pg,fC;function eX(){if(fC)return Pg;fC=1;var t=Object.prototype,e=t.hasOwnProperty;function r(n,i){return n!=null&&e.call(n,i)}return Pg=r,Pg}var Lg,dC;function Aa(){if(dC)return Lg;dC=1;var t=Array.isArray;return Lg=t,Lg}var Ng,hC;function AM(){if(hC)return Ng;hC=1;var t=typeof pi=="object"&&pi&&pi.Object===Object&πreturn Ng=t,Ng}var Fg,pC;function zi(){if(pC)return Fg;pC=1;var t=AM(),e=typeof self=="object"&&self&&self.Object===Object&&self,r=t||e||Function("return this")();return Fg=r,Fg}var kg,gC;function Hd(){if(gC)return kg;gC=1;var t=zi(),e=t.Symbol;return kg=e,kg}var jg,mC;function tX(){if(mC)return jg;mC=1;var t=Hd(),e=Object.prototype,r=e.hasOwnProperty,n=e.toString,i=t?t.toStringTag:void 0;function a(s){var o=r.call(s,i),l=s[i];try{s[i]=void 0;var c=!0}catch{}var d=n.call(s);return c&&(o?s[i]=l:delete s[i]),d}return jg=a,jg}var $g,vC;function rX(){if(vC)return $g;vC=1;var t=Object.prototype,e=t.toString;function r(n){return e.call(n)}return $g=r,$g}var Ug,yC;function Qu(){if(yC)return Ug;yC=1;var t=Hd(),e=tX(),r=rX(),n="[object Null]",i="[object Undefined]",a=t?t.toStringTag:void 0;function s(o){return o==null?o===void 0?i:n:a&&a in Object(o)?e(o):r(o)}return Ug=s,Ug}var qg,bC;function el(){if(bC)return qg;bC=1;function t(e){return e!=null&&typeof e=="object"}return qg=t,qg}var Hg,_C;function _b(){if(_C)return Hg;_C=1;var t=Qu(),e=el(),r="[object Symbol]";function n(i){return typeof i=="symbol"||e(i)&&t(i)==r}return Hg=n,Hg}var Wg,xC;function xb(){if(xC)return Wg;xC=1;var t=Aa(),e=_b(),r=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,n=/^\w*$/;function i(a,s){if(t(a))return!1;var o=typeof a;return o=="number"||o=="symbol"||o=="boolean"||a==null||e(a)?!0:n.test(a)||!r.test(a)||s!=null&&a in Object(s)}return Wg=i,Wg}var Bg,wC;function wb(){if(wC)return Bg;wC=1;function t(e){var r=typeof e;return e!=null&&(r=="object"||r=="function")}return Bg=t,Bg}var zg,TC;function IM(){if(TC)return zg;TC=1;var t=Qu(),e=wb(),r="[object AsyncFunction]",n="[object Function]",i="[object GeneratorFunction]",a="[object Proxy]";function s(o){if(!e(o))return!1;var l=t(o);return l==n||l==i||l==r||l==a}return zg=s,zg}var Vg,SC;function nX(){if(SC)return Vg;SC=1;var t=zi(),e=t["__core-js_shared__"];return Vg=e,Vg}var Gg,CC;function iX(){if(CC)return Gg;CC=1;var t=nX(),e=(function(){var n=/[^.]+$/.exec(t&&t.keys&&t.keys.IE_PROTO||"");return n?"Symbol(src)_1."+n:""})();function r(n){return!!e&&e in n}return Gg=r,Gg}var Kg,EC;function RM(){if(EC)return Kg;EC=1;var t=Function.prototype,e=t.toString;function r(n){if(n!=null){try{return e.call(n)}catch{}try{return n+""}catch{}}return""}return Kg=r,Kg}var Xg,OC;function aX(){if(OC)return Xg;OC=1;var t=IM(),e=iX(),r=wb(),n=RM(),i=/[\\^$.*+?()[\]{}|]/g,a=/^\[object .+?Constructor\]$/,s=Function.prototype,o=Object.prototype,l=s.toString,c=o.hasOwnProperty,d=RegExp("^"+l.call(c).replace(i,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function h(g){if(!r(g)||e(g))return!1;var m=t(g)?d:a;return m.test(n(g))}return Xg=h,Xg}var Yg,AC;function sX(){if(AC)return Yg;AC=1;function t(e,r){return e==null?void 0:e[r]}return Yg=t,Yg}var Zg,IC;function Ts(){if(IC)return Zg;IC=1;var t=aX(),e=sX();function r(n,i){var a=e(n,i);return t(a)?a:void 0}return Zg=r,Zg}var Jg,RC;function Wd(){if(RC)return Jg;RC=1;var t=Ts(),e=t(Object,"create");return Jg=e,Jg}var Qg,DC;function oX(){if(DC)return Qg;DC=1;var t=Wd();function e(){this.__data__=t?t(null):{},this.size=0}return Qg=e,Qg}var em,MC;function uX(){if(MC)return em;MC=1;function t(e){var r=this.has(e)&&delete this.__data__[e];return this.size-=r?1:0,r}return em=t,em}var tm,PC;function lX(){if(PC)return tm;PC=1;var t=Wd(),e="__lodash_hash_undefined__",r=Object.prototype,n=r.hasOwnProperty;function i(a){var s=this.__data__;if(t){var o=s[a];return o===e?void 0:o}return n.call(s,a)?s[a]:void 0}return tm=i,tm}var rm,LC;function cX(){if(LC)return rm;LC=1;var t=Wd(),e=Object.prototype,r=e.hasOwnProperty;function n(i){var a=this.__data__;return t?a[i]!==void 0:r.call(a,i)}return rm=n,rm}var nm,NC;function fX(){if(NC)return nm;NC=1;var t=Wd(),e="__lodash_hash_undefined__";function r(n,i){var a=this.__data__;return this.size+=this.has(n)?0:1,a[n]=t&&i===void 0?e:i,this}return nm=r,nm}var im,FC;function dX(){if(FC)return im;FC=1;var t=oX(),e=uX(),r=lX(),n=cX(),i=fX();function a(s){var o=-1,l=s==null?0:s.length;for(this.clear();++o<l;){var c=s[o];this.set(c[0],c[1])}}return a.prototype.clear=t,a.prototype.delete=e,a.prototype.get=r,a.prototype.has=n,a.prototype.set=i,im=a,im}var am,kC;function hX(){if(kC)return am;kC=1;function t(){this.__data__=[],this.size=0}return am=t,am}var sm,jC;function DM(){if(jC)return sm;jC=1;function t(e,r){return e===r||e!==e&&r!==r}return sm=t,sm}var om,$C;function Bd(){if($C)return om;$C=1;var t=DM();function e(r,n){for(var i=r.length;i--;)if(t(r[i][0],n))return i;return-1}return om=e,om}var um,UC;function pX(){if(UC)return um;UC=1;var t=Bd(),e=Array.prototype,r=e.splice;function n(i){var a=this.__data__,s=t(a,i);if(s<0)return!1;var o=a.length-1;return s==o?a.pop():r.call(a,s,1),--this.size,!0}return um=n,um}var lm,qC;function gX(){if(qC)return lm;qC=1;var t=Bd();function e(r){var n=this.__data__,i=t(n,r);return i<0?void 0:n[i][1]}return lm=e,lm}var cm,HC;function mX(){if(HC)return cm;HC=1;var t=Bd();function e(r){return t(this.__data__,r)>-1}return cm=e,cm}var fm,WC;function vX(){if(WC)return fm;WC=1;var t=Bd();function e(r,n){var i=this.__data__,a=t(i,r);return a<0?(++this.size,i.push([r,n])):i[a][1]=n,this}return fm=e,fm}var dm,BC;function zd(){if(BC)return dm;BC=1;var t=hX(),e=pX(),r=gX(),n=mX(),i=vX();function a(s){var o=-1,l=s==null?0:s.length;for(this.clear();++o<l;){var c=s[o];this.set(c[0],c[1])}}return a.prototype.clear=t,a.prototype.delete=e,a.prototype.get=r,a.prototype.has=n,a.prototype.set=i,dm=a,dm}var hm,zC;function Tb(){if(zC)return hm;zC=1;var t=Ts(),e=zi(),r=t(e,"Map");return hm=r,hm}var pm,VC;function yX(){if(VC)return pm;VC=1;var t=dX(),e=zd(),r=Tb();function n(){this.size=0,this.__data__={hash:new t,map:new(r||e),string:new t}}return pm=n,pm}var gm,GC;function bX(){if(GC)return gm;GC=1;function t(e){var r=typeof e;return r=="string"||r=="number"||r=="symbol"||r=="boolean"?e!=="__proto__":e===null}return gm=t,gm}var mm,KC;function Vd(){if(KC)return mm;KC=1;var t=bX();function e(r,n){var i=r.__data__;return t(n)?i[typeof n=="string"?"string":"hash"]:i.map}return mm=e,mm}var vm,XC;function _X(){if(XC)return vm;XC=1;var t=Vd();function e(r){var n=t(this,r).delete(r);return this.size-=n?1:0,n}return vm=e,vm}var ym,YC;function xX(){if(YC)return ym;YC=1;var t=Vd();function e(r){return t(this,r).get(r)}return ym=e,ym}var bm,ZC;function wX(){if(ZC)return bm;ZC=1;var t=Vd();function e(r){return t(this,r).has(r)}return bm=e,bm}var _m,JC;function TX(){if(JC)return _m;JC=1;var t=Vd();function e(r,n){var i=t(this,r),a=i.size;return i.set(r,n),this.size+=i.size==a?0:1,this}return _m=e,_m}var xm,QC;function Sb(){if(QC)return xm;QC=1;var t=yX(),e=_X(),r=xX(),n=wX(),i=TX();function a(s){var o=-1,l=s==null?0:s.length;for(this.clear();++o<l;){var c=s[o];this.set(c[0],c[1])}}return a.prototype.clear=t,a.prototype.delete=e,a.prototype.get=r,a.prototype.has=n,a.prototype.set=i,xm=a,xm}var wm,eE;function SX(){if(eE)return wm;eE=1;var t=Sb(),e="Expected a function";function r(n,i){if(typeof n!="function"||i!=null&&typeof i!="function")throw new TypeError(e);var a=function(){var s=arguments,o=i?i.apply(this,s):s[0],l=a.cache;if(l.has(o))return l.get(o);var c=n.apply(this,s);return a.cache=l.set(o,c)||l,c};return a.cache=new(r.Cache||t),a}return r.Cache=t,wm=r,wm}var Tm,tE;function CX(){if(tE)return Tm;tE=1;var t=SX(),e=500;function r(n){var i=t(n,function(s){return a.size===e&&a.clear(),s}),a=i.cache;return i}return Tm=r,Tm}var Sm,rE;function EX(){if(rE)return Sm;rE=1;var t=CX(),e=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,r=/\\(\\)?/g,n=t(function(i){var a=[];return i.charCodeAt(0)===46&&a.push(""),i.replace(e,function(s,o,l,c){a.push(l?c.replace(r,"$1"):o||s)}),a});return Sm=n,Sm}var Cm,nE;function OX(){if(nE)return Cm;nE=1;function t(e,r){for(var n=-1,i=e==null?0:e.length,a=Array(i);++n<i;)a[n]=r(e[n],n,e);return a}return Cm=t,Cm}var Em,iE;function AX(){if(iE)return Em;iE=1;var t=Hd(),e=OX(),r=Aa(),n=_b(),i=t?t.prototype:void 0,a=i?i.toString:void 0;function s(o){if(typeof o=="string")return o;if(r(o))return e(o,s)+"";if(n(o))return a?a.call(o):"";var l=o+"";return l=="0"&&1/o==-1/0?"-0":l}return Em=s,Em}var Om,aE;function tl(){if(aE)return Om;aE=1;var t=AX();function e(r){return r==null?"":t(r)}return Om=e,Om}var Am,sE;function MM(){if(sE)return Am;sE=1;var t=Aa(),e=xb(),r=EX(),n=tl();function i(a,s){return t(a)?a:e(a,s)?[a]:r(n(a))}return Am=i,Am}var Im,oE;function IX(){if(oE)return Im;oE=1;var t=Qu(),e=el(),r="[object Arguments]";function n(i){return e(i)&&t(i)==r}return Im=n,Im}var Rm,uE;function PM(){if(uE)return Rm;uE=1;var t=IX(),e=el(),r=Object.prototype,n=r.hasOwnProperty,i=r.propertyIsEnumerable,a=t((function(){return arguments})())?t:function(s){return e(s)&&n.call(s,"callee")&&!i.call(s,"callee")};return Rm=a,Rm}var Dm,lE;function LM(){if(lE)return Dm;lE=1;var t=9007199254740991,e=/^(?:0|[1-9]\d*)$/;function r(n,i){var a=typeof n;return i=i??t,!!i&&(a=="number"||a!="symbol"&&e.test(n))&&n>-1&&n%1==0&&n<i}return Dm=r,Dm}var Mm,cE;function Cb(){if(cE)return Mm;cE=1;var t=9007199254740991;function e(r){return typeof r=="number"&&r>-1&&r%1==0&&r<=t}return Mm=e,Mm}var Pm,fE;function Gd(){if(fE)return Pm;fE=1;var t=_b();function e(r){if(typeof r=="string"||t(r))return r;var n=r+"";return n=="0"&&1/r==-1/0?"-0":n}return Pm=e,Pm}var Lm,dE;function NM(){if(dE)return Lm;dE=1;var t=MM(),e=PM(),r=Aa(),n=LM(),i=Cb(),a=Gd();function s(o,l,c){l=t(l,o);for(var d=-1,h=l.length,g=!1;++d<h;){var m=a(l[d]);if(!(g=o!=null&&c(o,m)))break;o=o[m]}return g||++d!=h?g:(h=o==null?0:o.length,!!h&&i(h)&&n(m,h)&&(r(o)||e(o)))}return Lm=s,Lm}var Nm,hE;function RX(){if(hE)return Nm;hE=1;var t=eX(),e=NM();function r(n,i){return n!=null&&e(n,i,t)}return Nm=r,Nm}var DX=RX();const td=vi(DX),Eo=t=>t&&t.__isYupSchema__;class MX{constructor(e,r){if(this.fn=void 0,this.refs=e,this.refs=e,typeof r=="function"){this.fn=r;return}if(!td(r,"is"))throw new TypeError("`is:` is required for `when()` conditions");if(!r.then&&!r.otherwise)throw new TypeError("either `then:` or `otherwise:` is required for `when()` conditions");let{is:n,then:i,otherwise:a}=r,s=typeof n=="function"?n:(...o)=>o.every(l=>l===n);this.fn=function(...o){let l=o.pop(),c=o.pop(),d=s(...o)?i:a;if(d)return typeof d=="function"?d(c):c.concat(d.resolve(l))}}resolve(e,r){let n=this.refs.map(a=>a.getValue(r==null?void 0:r.value,r==null?void 0:r.parent,r==null?void 0:r.context)),i=this.fn.apply(e,n.concat(e,r));if(i===void 0||i===e)return e;if(!Eo(i))throw new TypeError("conditions must return a schema object");return i.resolve(r)}}function FM(t){return t==null?[]:[].concat(t)}function r0(){return r0=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},r0.apply(this,arguments)}let PX=/\$\{\s*(\w+)\s*\}/g;class Vr extends Error{static formatError(e,r){const n=r.label||r.path||"this";return n!==r.path&&(r=r0({},r,{path:n})),typeof e=="string"?e.replace(PX,(i,a)=>ho(r[a])):typeof e=="function"?e(r):e}static isError(e){return e&&e.name==="ValidationError"}constructor(e,r,n,i){super(),this.value=void 0,this.path=void 0,this.type=void 0,this.errors=void 0,this.params=void 0,this.inner=void 0,this.name="ValidationError",this.value=r,this.path=n,this.type=i,this.errors=[],this.inner=[],FM(e).forEach(a=>{Vr.isError(a)?(this.errors.push(...a.errors),this.inner=this.inner.concat(a.inner.length?a.inner:a)):this.errors.push(a)}),this.message=this.errors.length>1?`${this.errors.length} errors occurred`:this.errors[0],Error.captureStackTrace&&Error.captureStackTrace(this,Vr)}}const LX=t=>{let e=!1;return(...r)=>{e||(e=!0,t(...r))}};function rd(t,e){let{endEarly:r,tests:n,args:i,value:a,errors:s,sort:o,path:l}=t,c=LX(e),d=n.length;const h=[];if(s=s||[],!d)return s.length?c(new Vr(s,a,l)):c(null,a);for(let g=0;g<n.length;g++){const m=n[g];m(i,function(b){if(b){if(!Vr.isError(b))return c(b,a);if(r)return b.value=a,c(b,a);h.push(b)}if(--d<=0){if(h.length&&(o&&h.sort(o),s.length&&h.push(...s),s=h),s.length){c(new Vr(s,a,l),a);return}c(null,a)}})}}var Fm,pE;function NX(){if(pE)return Fm;pE=1;var t=Ts(),e=(function(){try{var r=t(Object,"defineProperty");return r({},"",{}),r}catch{}})();return Fm=e,Fm}var km,gE;function kM(){if(gE)return km;gE=1;var t=NX();function e(r,n,i){n=="__proto__"&&t?t(r,n,{configurable:!0,enumerable:!0,value:i,writable:!0}):r[n]=i}return km=e,km}var jm,mE;function FX(){if(mE)return jm;mE=1;function t(e){return function(r,n,i){for(var a=-1,s=Object(r),o=i(r),l=o.length;l--;){var c=o[e?l:++a];if(n(s[c],c,s)===!1)break}return r}}return jm=t,jm}var $m,vE;function kX(){if(vE)return $m;vE=1;var t=FX(),e=t();return $m=e,$m}var Um,yE;function jX(){if(yE)return Um;yE=1;function t(e,r){for(var n=-1,i=Array(e);++n<e;)i[n]=r(n);return i}return Um=t,Um}var mu={exports:{}},qm,bE;function $X(){if(bE)return qm;bE=1;function t(){return!1}return qm=t,qm}mu.exports;var _E;function jM(){return _E||(_E=1,(function(t,e){var r=zi(),n=$X(),i=e&&!e.nodeType&&e,a=i&&!0&&t&&!t.nodeType&&t,s=a&&a.exports===i,o=s?r.Buffer:void 0,l=o?o.isBuffer:void 0,c=l||n;t.exports=c})(mu,mu.exports)),mu.exports}var Hm,xE;function UX(){if(xE)return Hm;xE=1;var t=Qu(),e=Cb(),r=el(),n="[object Arguments]",i="[object Array]",a="[object Boolean]",s="[object Date]",o="[object Error]",l="[object Function]",c="[object Map]",d="[object Number]",h="[object Object]",g="[object RegExp]",m="[object Set]",v="[object String]",b="[object WeakMap]",y="[object ArrayBuffer]",x="[object DataView]",w="[object Float32Array]",S="[object Float64Array]",E="[object Int8Array]",C="[object Int16Array]",I="[object Int32Array]",T="[object Uint8Array]",D="[object Uint8ClampedArray]",P="[object Uint16Array]",L="[object Uint32Array]",F={};F[w]=F[S]=F[E]=F[C]=F[I]=F[T]=F[D]=F[P]=F[L]=!0,F[n]=F[i]=F[y]=F[a]=F[x]=F[s]=F[o]=F[l]=F[c]=F[d]=F[h]=F[g]=F[m]=F[v]=F[b]=!1;function H(X){return r(X)&&e(X.length)&&!!F[t(X)]}return Hm=H,Hm}var Wm,wE;function qX(){if(wE)return Wm;wE=1;function t(e){return function(r){return e(r)}}return Wm=t,Wm}var vu={exports:{}};vu.exports;var TE;function HX(){return TE||(TE=1,(function(t,e){var r=AM(),n=e&&!e.nodeType&&e,i=n&&!0&&t&&!t.nodeType&&t,a=i&&i.exports===n,s=a&&r.process,o=(function(){try{var l=i&&i.require&&i.require("util").types;return l||s&&s.binding&&s.binding("util")}catch{}})();t.exports=o})(vu,vu.exports)),vu.exports}var Bm,SE;function $M(){if(SE)return Bm;SE=1;var t=UX(),e=qX(),r=HX(),n=r&&r.isTypedArray,i=n?e(n):t;return Bm=i,Bm}var zm,CE;function WX(){if(CE)return zm;CE=1;var t=jX(),e=PM(),r=Aa(),n=jM(),i=LM(),a=$M(),s=Object.prototype,o=s.hasOwnProperty;function l(c,d){var h=r(c),g=!h&&e(c),m=!h&&!g&&n(c),v=!h&&!g&&!m&&a(c),b=h||g||m||v,y=b?t(c.length,String):[],x=y.length;for(var w in c)(d||o.call(c,w))&&!(b&&(w=="length"||m&&(w=="offset"||w=="parent")||v&&(w=="buffer"||w=="byteLength"||w=="byteOffset")||i(w,x)))&&y.push(w);return y}return zm=l,zm}var Vm,EE;function BX(){if(EE)return Vm;EE=1;var t=Object.prototype;function e(r){var n=r&&r.constructor,i=typeof n=="function"&&n.prototype||t;return r===i}return Vm=e,Vm}var Gm,OE;function zX(){if(OE)return Gm;OE=1;function t(e,r){return function(n){return e(r(n))}}return Gm=t,Gm}var Km,AE;function VX(){if(AE)return Km;AE=1;var t=zX(),e=t(Object.keys,Object);return Km=e,Km}var Xm,IE;function GX(){if(IE)return Xm;IE=1;var t=BX(),e=VX(),r=Object.prototype,n=r.hasOwnProperty;function i(a){if(!t(a))return e(a);var s=[];for(var o in Object(a))n.call(a,o)&&o!="constructor"&&s.push(o);return s}return Xm=i,Xm}var Ym,RE;function KX(){if(RE)return Ym;RE=1;var t=IM(),e=Cb();function r(n){return n!=null&&e(n.length)&&!t(n)}return Ym=r,Ym}var Zm,DE;function Eb(){if(DE)return Zm;DE=1;var t=WX(),e=GX(),r=KX();function n(i){return r(i)?t(i):e(i)}return Zm=n,Zm}var Jm,ME;function UM(){if(ME)return Jm;ME=1;var t=kX(),e=Eb();function r(n,i){return n&&t(n,i,e)}return Jm=r,Jm}var Qm,PE;function XX(){if(PE)return Qm;PE=1;var t=zd();function e(){this.__data__=new t,this.size=0}return Qm=e,Qm}var ev,LE;function YX(){if(LE)return ev;LE=1;function t(e){var r=this.__data__,n=r.delete(e);return this.size=r.size,n}return ev=t,ev}var tv,NE;function ZX(){if(NE)return tv;NE=1;function t(e){return this.__data__.get(e)}return tv=t,tv}var rv,FE;function JX(){if(FE)return rv;FE=1;function t(e){return this.__data__.has(e)}return rv=t,rv}var nv,kE;function QX(){if(kE)return nv;kE=1;var t=zd(),e=Tb(),r=Sb(),n=200;function i(a,s){var o=this.__data__;if(o instanceof t){var l=o.__data__;if(!e||l.length<n-1)return l.push([a,s]),this.size=++o.size,this;o=this.__data__=new r(l)}return o.set(a,s),this.size=o.size,this}return nv=i,nv}var iv,jE;function qM(){if(jE)return iv;jE=1;var t=zd(),e=XX(),r=YX(),n=ZX(),i=JX(),a=QX();function s(o){var l=this.__data__=new t(o);this.size=l.size}return s.prototype.clear=e,s.prototype.delete=r,s.prototype.get=n,s.prototype.has=i,s.prototype.set=a,iv=s,iv}var av,$E;function eY(){if($E)return av;$E=1;var t="__lodash_hash_undefined__";function e(r){return this.__data__.set(r,t),this}return av=e,av}var sv,UE;function tY(){if(UE)return sv;UE=1;function t(e){return this.__data__.has(e)}return sv=t,sv}var ov,qE;function rY(){if(qE)return ov;qE=1;var t=Sb(),e=eY(),r=tY();function n(i){var a=-1,s=i==null?0:i.length;for(this.__data__=new t;++a<s;)this.add(i[a])}return n.prototype.add=n.prototype.push=e,n.prototype.has=r,ov=n,ov}var uv,HE;function nY(){if(HE)return uv;HE=1;function t(e,r){for(var n=-1,i=e==null?0:e.length;++n<i;)if(r(e[n],n,e))return!0;return!1}return uv=t,uv}var lv,WE;function iY(){if(WE)return lv;WE=1;function t(e,r){return e.has(r)}return lv=t,lv}var cv,BE;function HM(){if(BE)return cv;BE=1;var t=rY(),e=nY(),r=iY(),n=1,i=2;function a(s,o,l,c,d,h){var g=l&n,m=s.length,v=o.length;if(m!=v&&!(g&&v>m))return!1;var b=h.get(s),y=h.get(o);if(b&&y)return b==o&&y==s;var x=-1,w=!0,S=l&i?new t:void 0;for(h.set(s,o),h.set(o,s);++x<m;){var E=s[x],C=o[x];if(c)var I=g?c(C,E,x,o,s,h):c(E,C,x,s,o,h);if(I!==void 0){if(I)continue;w=!1;break}if(S){if(!e(o,function(T,D){if(!r(S,D)&&(E===T||d(E,T,l,c,h)))return S.push(D)})){w=!1;break}}else if(!(E===C||d(E,C,l,c,h))){w=!1;break}}return h.delete(s),h.delete(o),w}return cv=a,cv}var fv,zE;function aY(){if(zE)return fv;zE=1;var t=zi(),e=t.Uint8Array;return fv=e,fv}var dv,VE;function sY(){if(VE)return dv;VE=1;function t(e){var r=-1,n=Array(e.size);return e.forEach(function(i,a){n[++r]=[a,i]}),n}return dv=t,dv}var hv,GE;function oY(){if(GE)return hv;GE=1;function t(e){var r=-1,n=Array(e.size);return e.forEach(function(i){n[++r]=i}),n}return hv=t,hv}var pv,KE;function uY(){if(KE)return pv;KE=1;var t=Hd(),e=aY(),r=DM(),n=HM(),i=sY(),a=oY(),s=1,o=2,l="[object Boolean]",c="[object Date]",d="[object Error]",h="[object Map]",g="[object Number]",m="[object RegExp]",v="[object Set]",b="[object String]",y="[object Symbol]",x="[object ArrayBuffer]",w="[object DataView]",S=t?t.prototype:void 0,E=S?S.valueOf:void 0;function C(I,T,D,P,L,F,H){switch(D){case w:if(I.byteLength!=T.byteLength||I.byteOffset!=T.byteOffset)return!1;I=I.buffer,T=T.buffer;case x:return!(I.byteLength!=T.byteLength||!F(new e(I),new e(T)));case l:case c:case g:return r(+I,+T);case d:return I.name==T.name&&I.message==T.message;case m:case b:return I==T+"";case h:var X=i;case v:var ee=P&s;if(X||(X=a),I.size!=T.size&&!ee)return!1;var J=H.get(I);if(J)return J==T;P|=o,H.set(I,T);var te=n(X(I),X(T),P,L,F,H);return H.delete(I),te;case y:if(E)return E.call(I)==E.call(T)}return!1}return pv=C,pv}var gv,XE;function lY(){if(XE)return gv;XE=1;function t(e,r){for(var n=-1,i=r.length,a=e.length;++n<i;)e[a+n]=r[n];return e}return gv=t,gv}var mv,YE;function cY(){if(YE)return mv;YE=1;var t=lY(),e=Aa();function r(n,i,a){var s=i(n);return e(n)?s:t(s,a(n))}return mv=r,mv}var vv,ZE;function fY(){if(ZE)return vv;ZE=1;function t(e,r){for(var n=-1,i=e==null?0:e.length,a=0,s=[];++n<i;){var o=e[n];r(o,n,e)&&(s[a++]=o)}return s}return vv=t,vv}var yv,JE;function dY(){if(JE)return yv;JE=1;function t(){return[]}return yv=t,yv}var bv,QE;function hY(){if(QE)return bv;QE=1;var t=fY(),e=dY(),r=Object.prototype,n=r.propertyIsEnumerable,i=Object.getOwnPropertySymbols,a=i?function(s){return s==null?[]:(s=Object(s),t(i(s),function(o){return n.call(s,o)}))}:e;return bv=a,bv}var _v,eO;function pY(){if(eO)return _v;eO=1;var t=cY(),e=hY(),r=Eb();function n(i){return t(i,r,e)}return _v=n,_v}var xv,tO;function gY(){if(tO)return xv;tO=1;var t=pY(),e=1,r=Object.prototype,n=r.hasOwnProperty;function i(a,s,o,l,c,d){var h=o&e,g=t(a),m=g.length,v=t(s),b=v.length;if(m!=b&&!h)return!1;for(var y=m;y--;){var x=g[y];if(!(h?x in s:n.call(s,x)))return!1}var w=d.get(a),S=d.get(s);if(w&&S)return w==s&&S==a;var E=!0;d.set(a,s),d.set(s,a);for(var C=h;++y<m;){x=g[y];var I=a[x],T=s[x];if(l)var D=h?l(T,I,x,s,a,d):l(I,T,x,a,s,d);if(!(D===void 0?I===T||c(I,T,o,l,d):D)){E=!1;break}C||(C=x=="constructor")}if(E&&!C){var P=a.constructor,L=s.constructor;P!=L&&"constructor"in a&&"constructor"in s&&!(typeof P=="function"&&P instanceof P&&typeof L=="function"&&L instanceof L)&&(E=!1)}return d.delete(a),d.delete(s),E}return xv=i,xv}var wv,rO;function mY(){if(rO)return wv;rO=1;var t=Ts(),e=zi(),r=t(e,"DataView");return wv=r,wv}var Tv,nO;function vY(){if(nO)return Tv;nO=1;var t=Ts(),e=zi(),r=t(e,"Promise");return Tv=r,Tv}var Sv,iO;function yY(){if(iO)return Sv;iO=1;var t=Ts(),e=zi(),r=t(e,"Set");return Sv=r,Sv}var Cv,aO;function bY(){if(aO)return Cv;aO=1;var t=Ts(),e=zi(),r=t(e,"WeakMap");return Cv=r,Cv}var Ev,sO;function _Y(){if(sO)return Ev;sO=1;var t=mY(),e=Tb(),r=vY(),n=yY(),i=bY(),a=Qu(),s=RM(),o="[object Map]",l="[object Object]",c="[object Promise]",d="[object Set]",h="[object WeakMap]",g="[object DataView]",m=s(t),v=s(e),b=s(r),y=s(n),x=s(i),w=a;return(t&&w(new t(new ArrayBuffer(1)))!=g||e&&w(new e)!=o||r&&w(r.resolve())!=c||n&&w(new n)!=d||i&&w(new i)!=h)&&(w=function(S){var E=a(S),C=E==l?S.constructor:void 0,I=C?s(C):"";if(I)switch(I){case m:return g;case v:return o;case b:return c;case y:return d;case x:return h}return E}),Ev=w,Ev}var Ov,oO;function xY(){if(oO)return Ov;oO=1;var t=qM(),e=HM(),r=uY(),n=gY(),i=_Y(),a=Aa(),s=jM(),o=$M(),l=1,c="[object Arguments]",d="[object Array]",h="[object Object]",g=Object.prototype,m=g.hasOwnProperty;function v(b,y,x,w,S,E){var C=a(b),I=a(y),T=C?d:i(b),D=I?d:i(y);T=T==c?h:T,D=D==c?h:D;var P=T==h,L=D==h,F=T==D;if(F&&s(b)){if(!s(y))return!1;C=!0,P=!1}if(F&&!P)return E||(E=new t),C||o(b)?e(b,y,x,w,S,E):r(b,y,T,x,w,S,E);if(!(x&l)){var H=P&&m.call(b,"__wrapped__"),X=L&&m.call(y,"__wrapped__");if(H||X){var ee=H?b.value():b,J=X?y.value():y;return E||(E=new t),S(ee,J,x,w,E)}}return F?(E||(E=new t),n(b,y,x,w,S,E)):!1}return Ov=v,Ov}var Av,uO;function WM(){if(uO)return Av;uO=1;var t=xY(),e=el();function r(n,i,a,s,o){return n===i?!0:n==null||i==null||!e(n)&&!e(i)?n!==n&&i!==i:t(n,i,a,s,r,o)}return Av=r,Av}var Iv,lO;function wY(){if(lO)return Iv;lO=1;var t=qM(),e=WM(),r=1,n=2;function i(a,s,o,l){var c=o.length,d=c,h=!l;if(a==null)return!d;for(a=Object(a);c--;){var g=o[c];if(h&&g[2]?g[1]!==a[g[0]]:!(g[0]in a))return!1}for(;++c<d;){g=o[c];var m=g[0],v=a[m],b=g[1];if(h&&g[2]){if(v===void 0&&!(m in a))return!1}else{var y=new t;if(l)var x=l(v,b,m,a,s,y);if(!(x===void 0?e(b,v,r|n,l,y):x))return!1}}return!0}return Iv=i,Iv}var Rv,cO;function BM(){if(cO)return Rv;cO=1;var t=wb();function e(r){return r===r&&!t(r)}return Rv=e,Rv}var Dv,fO;function TY(){if(fO)return Dv;fO=1;var t=BM(),e=Eb();function r(n){for(var i=e(n),a=i.length;a--;){var s=i[a],o=n[s];i[a]=[s,o,t(o)]}return i}return Dv=r,Dv}var Mv,dO;function zM(){if(dO)return Mv;dO=1;function t(e,r){return function(n){return n==null?!1:n[e]===r&&(r!==void 0||e in Object(n))}}return Mv=t,Mv}var Pv,hO;function SY(){if(hO)return Pv;hO=1;var t=wY(),e=TY(),r=zM();function n(i){var a=e(i);return a.length==1&&a[0][2]?r(a[0][0],a[0][1]):function(s){return s===i||t(s,i,a)}}return Pv=n,Pv}var Lv,pO;function VM(){if(pO)return Lv;pO=1;var t=MM(),e=Gd();function r(n,i){i=t(i,n);for(var a=0,s=i.length;n!=null&&a<s;)n=n[e(i[a++])];return a&&a==s?n:void 0}return Lv=r,Lv}var Nv,gO;function CY(){if(gO)return Nv;gO=1;var t=VM();function e(r,n,i){var a=r==null?void 0:t(r,n);return a===void 0?i:a}return Nv=e,Nv}var Fv,mO;function EY(){if(mO)return Fv;mO=1;function t(e,r){return e!=null&&r in Object(e)}return Fv=t,Fv}var kv,vO;function OY(){if(vO)return kv;vO=1;var t=EY(),e=NM();function r(n,i){return n!=null&&e(n,i,t)}return kv=r,kv}var jv,yO;function AY(){if(yO)return jv;yO=1;var t=WM(),e=CY(),r=OY(),n=xb(),i=BM(),a=zM(),s=Gd(),o=1,l=2;function c(d,h){return n(d)&&i(h)?a(s(d),h):function(g){var m=e(g,d);return m===void 0&&m===h?r(g,d):t(h,m,o|l)}}return jv=c,jv}var $v,bO;function IY(){if(bO)return $v;bO=1;function t(e){return e}return $v=t,$v}var Uv,_O;function RY(){if(_O)return Uv;_O=1;function t(e){return function(r){return r==null?void 0:r[e]}}return Uv=t,Uv}var qv,xO;function DY(){if(xO)return qv;xO=1;var t=VM();function e(r){return function(n){return t(n,r)}}return qv=e,qv}var Hv,wO;function MY(){if(wO)return Hv;wO=1;var t=RY(),e=DY(),r=xb(),n=Gd();function i(a){return r(a)?t(n(a)):e(a)}return Hv=i,Hv}var Wv,TO;function GM(){if(TO)return Wv;TO=1;var t=SY(),e=AY(),r=IY(),n=Aa(),i=MY();function a(s){return typeof s=="function"?s:s==null?r:typeof s=="object"?n(s)?e(s[0],s[1]):t(s):i(s)}return Wv=a,Wv}var Bv,SO;function PY(){if(SO)return Bv;SO=1;var t=kM(),e=UM(),r=GM();function n(i,a){var s={};return a=r(a,3),e(i,function(o,l,c){t(s,l,a(o,l,c))}),s}return Bv=n,Bv}var LY=PY();const KM=vi(LY);var zv,CO;function NY(){if(CO)return zv;CO=1;function t(x){this._maxSize=x,this.clear()}t.prototype.clear=function(){this._size=0,this._values=Object.create(null)},t.prototype.get=function(x){return this._values[x]},t.prototype.set=function(x,w){return this._size>=this._maxSize&&this.clear(),x in this._values||this._size++,this._values[x]=w};var e=/[^.^\]^[]+|(?=\[\]|\.\.)/g,r=/^\d+$/,n=/^\d/,i=/[~`!#$%\^&*+=\-\[\]\\';,/{}|\\":<>\?]/g,a=/^\s*(['"]?)(.*?)(\1)\s*$/,s=512,o=new t(s),l=new t(s),c=new t(s);zv={Cache:t,split:h,normalizePath:d,setter:function(x){var w=d(x);return l.get(x)||l.set(x,function(E,C){for(var I=0,T=w.length,D=E;I<T-1;){var P=w[I];if(P==="__proto__"||P==="constructor"||P==="prototype")return E;D=D[w[I++]]}D[w[I]]=C})},getter:function(x,w){var S=d(x);return c.get(x)||c.set(x,function(C){for(var I=0,T=S.length;I<T;)if(C!=null||!w)C=C[S[I++]];else return;return C})},join:function(x){return x.reduce(function(w,S){return w+(m(S)||r.test(S)?"["+S+"]":(w?".":"")+S)},"")},forEach:function(x,w,S){g(Array.isArray(x)?x:h(x),w,S)}};function d(x){return o.get(x)||o.set(x,h(x).map(function(w){return w.replace(a,"$2")}))}function h(x){return x.match(e)||[""]}function g(x,w,S){var E=x.length,C,I,T,D;for(I=0;I<E;I++)C=x[I],C&&(y(C)&&(C='"'+C+'"'),D=m(C),T=!D&&/^\d+$/.test(C),w.call(S,C,D,T,I,x))}function m(x){return typeof x=="string"&&x&&["'",'"'].indexOf(x.charAt(0))!==-1}function v(x){return x.match(n)&&!x.match(r)}function b(x){return i.test(x)}function y(x){return!m(x)&&(v(x)||b(x))}return zv}var Kd=NY();const Xc={context:"$",value:"."};function FY(t,e){return new ji(t,e)}class ji{constructor(e,r={}){if(this.key=void 0,this.isContext=void 0,this.isValue=void 0,this.isSibling=void 0,this.path=void 0,this.getter=void 0,this.map=void 0,typeof e!="string")throw new TypeError("ref must be a string, got: "+e);if(this.key=e.trim(),e==="")throw new TypeError("ref must be a non-empty string");this.isContext=this.key[0]===Xc.context,this.isValue=this.key[0]===Xc.value,this.isSibling=!this.isContext&&!this.isValue;let n=this.isContext?Xc.context:this.isValue?Xc.value:"";this.path=this.key.slice(n.length),this.getter=this.path&&Kd.getter(this.path,!0),this.map=r.map}getValue(e,r,n){let i=this.isContext?n:this.isValue?e:r;return this.getter&&(i=this.getter(i||{})),this.map&&(i=this.map(i)),i}cast(e,r){return this.getValue(e,r==null?void 0:r.parent,r==null?void 0:r.context)}resolve(){return this}describe(){return{type:"ref",key:this.key}}toString(){return`Ref(${this.key})`}static isRef(e){return e&&e.__isYupRef}}ji.prototype.__isYupRef=!0;function nd(){return nd=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},nd.apply(this,arguments)}function kY(t,e){if(t==null)return{};var r={},n=Object.keys(t),i,a;for(a=0;a<n.length;a++)i=n[a],!(e.indexOf(i)>=0)&&(r[i]=t[i]);return r}function Yc(t){function e(r,n){let{value:i,path:a="",label:s,options:o,originalValue:l,sync:c}=r,d=kY(r,["value","path","label","options","originalValue","sync"]);const{name:h,test:g,params:m,message:v}=t;let{parent:b,context:y}=o;function x(I){return ji.isRef(I)?I.getValue(i,b,y):I}function w(I={}){const T=KM(nd({value:i,originalValue:l,label:s,path:I.path||a},m,I.params),x),D=new Vr(Vr.formatError(I.message||v,T),i,T.path,I.type||h);return D.params=T,D}let S=nd({path:a,parent:b,type:h,createError:w,resolve:x,options:o,originalValue:l},d);if(!c){try{Promise.resolve(g.call(S,i,S)).then(I=>{Vr.isError(I)?n(I):I?n(null,I):n(w())}).catch(n)}catch(I){n(I)}return}let E;try{var C;if(E=g.call(S,i,S),typeof((C=E)==null?void 0:C.then)=="function")throw new Error(`Validation test of type: "${S.type}" returned a Promise during a synchronous validate. This test will finish after the validate call has returned`)}catch(I){n(I);return}Vr.isError(E)?n(E):E?n(null,E):n(w())}return e.OPTIONS=t,e}let jY=t=>t.substr(0,t.length-1).substr(1);function XM(t,e,r,n=r){let i,a,s;return e?(Kd.forEach(e,(o,l,c)=>{let d=l?jY(o):o;if(t=t.resolve({context:n,parent:i,value:r}),t.innerType){let h=c?parseInt(d,10):0;if(r&&h>=r.length)throw new Error(`Yup.reach cannot resolve an array item at index: ${o}, in the path: ${e}. because there is no value at that index. `);i=r,r=r&&r[h],t=t.innerType}if(!c){if(!t.fields||!t.fields[d])throw new Error(`The schema does not contain the path: ${e}. (failed at: ${s} which is a type: "${t._type}")`);i=r,r=r&&r[d],t=t.fields[d]}a=d,s=l?"["+o+"]":"."+o}),{schema:t,parent:i,parentPath:a}):{parent:i,parentPath:e,schema:t}}const $Y=(t,e,r,n)=>XM(t,e,r,n).schema;class id{constructor(){this.list=void 0,this.refs=void 0,this.list=new Set,this.refs=new Map}get size(){return this.list.size+this.refs.size}describe(){const e=[];for(const r of this.list)e.push(r);for(const[,r]of this.refs)e.push(r.describe());return e}toArray(){return Array.from(this.list).concat(Array.from(this.refs.values()))}resolveAll(e){return this.toArray().reduce((r,n)=>r.concat(ji.isRef(n)?e(n):n),[])}add(e){ji.isRef(e)?this.refs.set(e.key,e):this.list.add(e)}delete(e){ji.isRef(e)?this.refs.delete(e.key):this.list.delete(e)}clone(){const e=new id;return e.list=new Set(this.list),e.refs=new Map(this.refs),e}merge(e,r){const n=this.clone();return e.list.forEach(i=>n.add(i)),e.refs.forEach(i=>n.add(i)),r.list.forEach(i=>n.delete(i)),r.refs.forEach(i=>n.delete(i)),n}}function Un(){return Un=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},Un.apply(this,arguments)}class Ar{constructor(e){this.deps=[],this.tests=void 0,this.transforms=void 0,this.conditions=[],this._mutate=void 0,this._typeError=void 0,this._whitelist=new id,this._blacklist=new id,this.exclusiveTests=Object.create(null),this.spec=void 0,this.tests=[],this.transforms=[],this.withMutation(()=>{this.typeError(Xa.notType)}),this.type=(e==null?void 0:e.type)||"mixed",this.spec=Un({strip:!1,strict:!1,abortEarly:!0,recursive:!0,nullable:!1,presence:"optional"},e==null?void 0:e.spec)}get _type(){return this.type}_typeCheck(e){return!0}clone(e){if(this._mutate)return e&&Object.assign(this.spec,e),this;const r=Object.create(Object.getPrototypeOf(this));return r.type=this.type,r._typeError=this._typeError,r._whitelistError=this._whitelistError,r._blacklistError=this._blacklistError,r._whitelist=this._whitelist.clone(),r._blacklist=this._blacklist.clone(),r.exclusiveTests=Un({},this.exclusiveTests),r.deps=[...this.deps],r.conditions=[...this.conditions],r.tests=[...this.tests],r.transforms=[...this.transforms],r.spec=Jy(Un({},this.spec,e)),r}label(e){let r=this.clone();return r.spec.label=e,r}meta(...e){if(e.length===0)return this.spec.meta;let r=this.clone();return r.spec.meta=Object.assign(r.spec.meta||{},e[0]),r}withMutation(e){let r=this._mutate;this._mutate=!0;let n=e(this);return this._mutate=r,n}concat(e){if(!e||e===this)return this;if(e.type!==this.type&&this.type!=="mixed")throw new TypeError(`You cannot \`concat()\` schema's of different types: ${this.type} and ${e.type}`);let r=this,n=e.clone();const i=Un({},r.spec,n.spec);return n.spec=i,n._typeError||(n._typeError=r._typeError),n._whitelistError||(n._whitelistError=r._whitelistError),n._blacklistError||(n._blacklistError=r._blacklistError),n._whitelist=r._whitelist.merge(e._whitelist,e._blacklist),n._blacklist=r._blacklist.merge(e._blacklist,e._whitelist),n.tests=r.tests,n.exclusiveTests=r.exclusiveTests,n.withMutation(a=>{e.tests.forEach(s=>{a.test(s.OPTIONS)})}),n.transforms=[...r.transforms,...n.transforms],n}isType(e){return this.spec.nullable&&e===null?!0:this._typeCheck(e)}resolve(e){let r=this;if(r.conditions.length){let n=r.conditions;r=r.clone(),r.conditions=[],r=n.reduce((i,a)=>a.resolve(i,e),r),r=r.resolve(e)}return r}cast(e,r={}){let n=this.resolve(Un({value:e},r)),i=n._cast(e,r);if(e!==void 0&&r.assert!==!1&&n.isType(i)!==!0){let a=ho(e),s=ho(i);throw new TypeError(`The value of ${r.path||"field"} could not be cast to a value that satisfies the schema type: "${n._type}".
|
|
80
|
+
|
|
81
|
+
attempted value: ${a}
|
|
82
|
+
`+(s!==a?`result of cast: ${s}`:""))}return i}_cast(e,r){let n=e===void 0?e:this.transforms.reduce((i,a)=>a.call(this,i,e,this),e);return n===void 0&&(n=this.getDefault()),n}_validate(e,r={},n){let{sync:i,path:a,from:s=[],originalValue:o=e,strict:l=this.spec.strict,abortEarly:c=this.spec.abortEarly}=r,d=e;l||(d=this._cast(d,Un({assert:!1},r)));let h={value:d,path:a,options:r,originalValue:o,schema:this,label:this.spec.label,sync:i,from:s},g=[];this._typeError&&g.push(this._typeError);let m=[];this._whitelistError&&m.push(this._whitelistError),this._blacklistError&&m.push(this._blacklistError),rd({args:h,value:d,path:a,tests:g,endEarly:c},v=>{if(v)return void n(v,d);rd({tests:this.tests.concat(m),args:h,path:a,sync:i,value:d,endEarly:c},n)})}validate(e,r,n){let i=this.resolve(Un({},r,{value:e}));return typeof n=="function"?i._validate(e,r,n):new Promise((a,s)=>i._validate(e,r,(o,l)=>{o?s(o):a(l)}))}validateSync(e,r){let n=this.resolve(Un({},r,{value:e})),i;return n._validate(e,Un({},r,{sync:!0}),(a,s)=>{if(a)throw a;i=s}),i}isValid(e,r){return this.validate(e,r).then(()=>!0,n=>{if(Vr.isError(n))return!1;throw n})}isValidSync(e,r){try{return this.validateSync(e,r),!0}catch(n){if(Vr.isError(n))return!1;throw n}}_getDefault(){let e=this.spec.default;return e==null?e:typeof e=="function"?e.call(this):Jy(e)}getDefault(e){return this.resolve(e||{})._getDefault()}default(e){return arguments.length===0?this._getDefault():this.clone({default:e})}strict(e=!0){let r=this.clone();return r.spec.strict=e,r}_isPresent(e){return e!=null}defined(e=Xa.defined){return this.test({message:e,name:"defined",exclusive:!0,test(r){return r!==void 0}})}required(e=Xa.required){return this.clone({presence:"required"}).withMutation(r=>r.test({message:e,name:"required",exclusive:!0,test(n){return this.schema._isPresent(n)}}))}notRequired(){let e=this.clone({presence:"optional"});return e.tests=e.tests.filter(r=>r.OPTIONS.name!=="required"),e}nullable(e=!0){return this.clone({nullable:e!==!1})}transform(e){let r=this.clone();return r.transforms.push(e),r}test(...e){let r;if(e.length===1?typeof e[0]=="function"?r={test:e[0]}:r=e[0]:e.length===2?r={name:e[0],test:e[1]}:r={name:e[0],message:e[1],test:e[2]},r.message===void 0&&(r.message=Xa.default),typeof r.test!="function")throw new TypeError("`test` is a required parameters");let n=this.clone(),i=Yc(r),a=r.exclusive||r.name&&n.exclusiveTests[r.name]===!0;if(r.exclusive&&!r.name)throw new TypeError("Exclusive tests must provide a unique `name` identifying the test");return r.name&&(n.exclusiveTests[r.name]=!!r.exclusive),n.tests=n.tests.filter(s=>!(s.OPTIONS.name===r.name&&(a||s.OPTIONS.test===i.OPTIONS.test))),n.tests.push(i),n}when(e,r){!Array.isArray(e)&&typeof e!="string"&&(r=e,e=".");let n=this.clone(),i=FM(e).map(a=>new ji(a));return i.forEach(a=>{a.isSibling&&n.deps.push(a.key)}),n.conditions.push(new MX(i,r)),n}typeError(e){let r=this.clone();return r._typeError=Yc({message:e,name:"typeError",test(n){return n!==void 0&&!this.schema.isType(n)?this.createError({params:{type:this.schema._type}}):!0}}),r}oneOf(e,r=Xa.oneOf){let n=this.clone();return e.forEach(i=>{n._whitelist.add(i),n._blacklist.delete(i)}),n._whitelistError=Yc({message:r,name:"oneOf",test(i){if(i===void 0)return!0;let a=this.schema._whitelist,s=a.resolveAll(this.resolve);return s.includes(i)?!0:this.createError({params:{values:a.toArray().join(", "),resolved:s}})}}),n}notOneOf(e,r=Xa.notOneOf){let n=this.clone();return e.forEach(i=>{n._blacklist.add(i),n._whitelist.delete(i)}),n._blacklistError=Yc({message:r,name:"notOneOf",test(i){let a=this.schema._blacklist,s=a.resolveAll(this.resolve);return s.includes(i)?this.createError({params:{values:a.toArray().join(", "),resolved:s}}):!0}}),n}strip(e=!0){let r=this.clone();return r.spec.strip=e,r}describe(){const e=this.clone(),{label:r,meta:n}=e.spec;return{meta:n,label:r,type:e.type,oneOf:e._whitelist.describe(),notOneOf:e._blacklist.describe(),tests:e.tests.map(a=>({name:a.OPTIONS.name,params:a.OPTIONS.params})).filter((a,s,o)=>o.findIndex(l=>l.name===a.name)===s)}}}Ar.prototype.__isYupSchema__=!0;for(const t of["validate","validateSync"])Ar.prototype[`${t}At`]=function(e,r,n={}){const{parent:i,parentPath:a,schema:s}=XM(this,e,r,n.context);return s[t](i&&i[a],Un({},n,{parent:i,path:e}))};for(const t of["equals","is"])Ar.prototype[t]=Ar.prototype.oneOf;for(const t of["not","nope"])Ar.prototype[t]=Ar.prototype.notOneOf;Ar.prototype.optional=Ar.prototype.notRequired;const Ob=Ar;function YM(){return new Ob}YM.prototype=Ob.prototype;const rr=t=>t==null;function n0(){return new Ab}class Ab extends Ar{constructor(){super({type:"boolean"}),this.withMutation(()=>{this.transform(function(e){if(!this.isType(e)){if(/^(true|1)$/i.test(String(e)))return!0;if(/^(false|0)$/i.test(String(e)))return!1}return e})})}_typeCheck(e){return e instanceof Boolean&&(e=e.valueOf()),typeof e=="boolean"}isTrue(e=e0.isValue){return this.test({message:e,name:"is-value",exclusive:!0,params:{value:"true"},test(r){return rr(r)||r===!0}})}isFalse(e=e0.isValue){return this.test({message:e,name:"is-value",exclusive:!0,params:{value:"false"},test(r){return rr(r)||r===!1}})}}n0.prototype=Ab.prototype;let UY=/^((([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+(\.([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+)*)|((\x22)((((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(([\x01-\x08\x0b\x0c\x0e-\x1f\x7f]|\x21|[\x23-\x5b]|[\x5d-\x7e]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(\\([\x01-\x09\x0b\x0c\x0d-\x7f]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]))))*(((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(\x22)))@((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))$/i,qY=/^((https?|ftp):)?\/\/(((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/i,HY=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i,WY=t=>rr(t)||t===t.trim(),BY={}.toString();function Ib(){return new Rb}class Rb extends Ar{constructor(){super({type:"string"}),this.withMutation(()=>{this.transform(function(e){if(this.isType(e)||Array.isArray(e))return e;const r=e!=null&&e.toString?e.toString():e;return r===BY?e:r})})}_typeCheck(e){return e instanceof String&&(e=e.valueOf()),typeof e=="string"}_isPresent(e){return super._isPresent(e)&&!!e.length}length(e,r=Jn.length){return this.test({message:r,name:"length",exclusive:!0,params:{length:e},test(n){return rr(n)||n.length===this.resolve(e)}})}min(e,r=Jn.min){return this.test({message:r,name:"min",exclusive:!0,params:{min:e},test(n){return rr(n)||n.length>=this.resolve(e)}})}max(e,r=Jn.max){return this.test({name:"max",exclusive:!0,message:r,params:{max:e},test(n){return rr(n)||n.length<=this.resolve(e)}})}matches(e,r){let n=!1,i,a;return r&&(typeof r=="object"?{excludeEmptyString:n=!1,message:i,name:a}=r:i=r),this.test({name:a||"matches",message:i||Jn.matches,params:{regex:e},test:s=>rr(s)||s===""&&n||s.search(e)!==-1})}email(e=Jn.email){return this.matches(UY,{name:"email",message:e,excludeEmptyString:!0})}url(e=Jn.url){return this.matches(qY,{name:"url",message:e,excludeEmptyString:!0})}uuid(e=Jn.uuid){return this.matches(HY,{name:"uuid",message:e,excludeEmptyString:!1})}ensure(){return this.default("").transform(e=>e===null?"":e)}trim(e=Jn.trim){return this.transform(r=>r!=null?r.trim():r).test({message:e,name:"trim",test:WY})}lowercase(e=Jn.lowercase){return this.transform(r=>rr(r)?r:r.toLowerCase()).test({message:e,name:"string_case",exclusive:!0,test:r=>rr(r)||r===r.toLowerCase()})}uppercase(e=Jn.uppercase){return this.transform(r=>rr(r)?r:r.toUpperCase()).test({message:e,name:"string_case",exclusive:!0,test:r=>rr(r)||r===r.toUpperCase()})}}Ib.prototype=Rb.prototype;let zY=t=>t!=+t;function ZM(){return new Db}class Db extends Ar{constructor(){super({type:"number"}),this.withMutation(()=>{this.transform(function(e){let r=e;if(typeof r=="string"){if(r=r.replace(/\s/g,""),r==="")return NaN;r=+r}return this.isType(r)?r:parseFloat(r)})})}_typeCheck(e){return e instanceof Number&&(e=e.valueOf()),typeof e=="number"&&!zY(e)}min(e,r=ca.min){return this.test({message:r,name:"min",exclusive:!0,params:{min:e},test(n){return rr(n)||n>=this.resolve(e)}})}max(e,r=ca.max){return this.test({message:r,name:"max",exclusive:!0,params:{max:e},test(n){return rr(n)||n<=this.resolve(e)}})}lessThan(e,r=ca.lessThan){return this.test({message:r,name:"max",exclusive:!0,params:{less:e},test(n){return rr(n)||n<this.resolve(e)}})}moreThan(e,r=ca.moreThan){return this.test({message:r,name:"min",exclusive:!0,params:{more:e},test(n){return rr(n)||n>this.resolve(e)}})}positive(e=ca.positive){return this.moreThan(0,e)}negative(e=ca.negative){return this.lessThan(0,e)}integer(e=ca.integer){return this.test({name:"integer",message:e,test:r=>rr(r)||Number.isInteger(r)})}truncate(){return this.transform(e=>rr(e)?e:e|0)}round(e){var r;let n=["ceil","floor","round","trunc"];if(e=((r=e)==null?void 0:r.toLowerCase())||"round",e==="trunc")return this.truncate();if(n.indexOf(e.toLowerCase())===-1)throw new TypeError("Only valid options for round() are: "+n.join(", "));return this.transform(i=>rr(i)?i:Math[e](i))}}ZM.prototype=Db.prototype;var VY=/^(\d{4}|[+\-]\d{6})(?:-?(\d{2})(?:-?(\d{2}))?)?(?:[ T]?(\d{2}):?(\d{2})(?::?(\d{2})(?:[,\.](\d{1,}))?)?(?:(Z)|([+\-])(\d{2})(?::?(\d{2}))?)?)?$/;function GY(t){var e=[1,4,5,6,7,10,11],r=0,n,i;if(i=VY.exec(t)){for(var a=0,s;s=e[a];++a)i[s]=+i[s]||0;i[2]=(+i[2]||1)-1,i[3]=+i[3]||1,i[7]=i[7]?String(i[7]).substr(0,3):0,(i[8]===void 0||i[8]==="")&&(i[9]===void 0||i[9]==="")?n=+new Date(i[1],i[2],i[3],i[4],i[5],i[6],i[7]):(i[8]!=="Z"&&i[9]!==void 0&&(r=i[10]*60+i[11],i[9]==="+"&&(r=0-r)),n=Date.UTC(i[1],i[2],i[3],i[4],i[5]+r,i[6],i[7]))}else n=Date.parse?Date.parse(t):NaN;return n}let Mb=new Date(""),KY=t=>Object.prototype.toString.call(t)==="[object Date]";function Pb(){return new Xd}class Xd extends Ar{constructor(){super({type:"date"}),this.withMutation(()=>{this.transform(function(e){return this.isType(e)?e:(e=GY(e),isNaN(e)?Mb:new Date(e))})})}_typeCheck(e){return KY(e)&&!isNaN(e.getTime())}prepareParam(e,r){let n;if(ji.isRef(e))n=e;else{let i=this.cast(e);if(!this._typeCheck(i))throw new TypeError(`\`${r}\` must be a Date or a value that can be \`cast()\` to a Date`);n=i}return n}min(e,r=Qy.min){let n=this.prepareParam(e,"min");return this.test({message:r,name:"min",exclusive:!0,params:{min:e},test(i){return rr(i)||i>=this.resolve(n)}})}max(e,r=Qy.max){let n=this.prepareParam(e,"max");return this.test({message:r,name:"max",exclusive:!0,params:{max:e},test(i){return rr(i)||i<=this.resolve(n)}})}}Xd.INVALID_DATE=Mb;Pb.prototype=Xd.prototype;Pb.INVALID_DATE=Mb;var Vv,EO;function XY(){if(EO)return Vv;EO=1;function t(e,r,n,i){var a=-1,s=e==null?0:e.length;for(i&&s&&(n=e[++a]);++a<s;)n=r(n,e[a],a,e);return n}return Vv=t,Vv}var Gv,OO;function YY(){if(OO)return Gv;OO=1;function t(e){return function(r){return e==null?void 0:e[r]}}return Gv=t,Gv}var Kv,AO;function ZY(){if(AO)return Kv;AO=1;var t=YY(),e={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},r=t(e);return Kv=r,Kv}var Xv,IO;function JY(){if(IO)return Xv;IO=1;var t=ZY(),e=tl(),r=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,n="\\u0300-\\u036f",i="\\ufe20-\\ufe2f",a="\\u20d0-\\u20ff",s=n+i+a,o="["+s+"]",l=RegExp(o,"g");function c(d){return d=e(d),d&&d.replace(r,t).replace(l,"")}return Xv=c,Xv}var Yv,RO;function QY(){if(RO)return Yv;RO=1;var t=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;function e(r){return r.match(t)||[]}return Yv=e,Yv}var Zv,DO;function eZ(){if(DO)return Zv;DO=1;var t=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;function e(r){return t.test(r)}return Zv=e,Zv}var Jv,MO;function tZ(){if(MO)return Jv;MO=1;var t="\\ud800-\\udfff",e="\\u0300-\\u036f",r="\\ufe20-\\ufe2f",n="\\u20d0-\\u20ff",i=e+r+n,a="\\u2700-\\u27bf",s="a-z\\xdf-\\xf6\\xf8-\\xff",o="\\xac\\xb1\\xd7\\xf7",l="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",c="\\u2000-\\u206f",d=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",h="A-Z\\xc0-\\xd6\\xd8-\\xde",g="\\ufe0e\\ufe0f",m=o+l+c+d,v="['’]",b="["+m+"]",y="["+i+"]",x="\\d+",w="["+a+"]",S="["+s+"]",E="[^"+t+m+x+a+s+h+"]",C="\\ud83c[\\udffb-\\udfff]",I="(?:"+y+"|"+C+")",T="[^"+t+"]",D="(?:\\ud83c[\\udde6-\\uddff]){2}",P="[\\ud800-\\udbff][\\udc00-\\udfff]",L="["+h+"]",F="\\u200d",H="(?:"+S+"|"+E+")",X="(?:"+L+"|"+E+")",ee="(?:"+v+"(?:d|ll|m|re|s|t|ve))?",J="(?:"+v+"(?:D|LL|M|RE|S|T|VE))?",te=I+"?",ce="["+g+"]?",B="(?:"+F+"(?:"+[T,D,P].join("|")+")"+ce+te+")*",ae="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",Ce="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",Ae=ce+te+B,ve="(?:"+[w,D,P].join("|")+")"+Ae,ct=RegExp([L+"?"+S+"+"+ee+"(?="+[b,L,"$"].join("|")+")",X+"+"+J+"(?="+[b,L+H,"$"].join("|")+")",L+"?"+H+"+"+ee,L+"+"+J,Ce,ae,x,ve].join("|"),"g");function Ge(Le){return Le.match(ct)||[]}return Jv=Ge,Jv}var Qv,PO;function rZ(){if(PO)return Qv;PO=1;var t=QY(),e=eZ(),r=tl(),n=tZ();function i(a,s,o){return a=r(a),s=o?void 0:s,s===void 0?e(a)?n(a):t(a):a.match(s)||[]}return Qv=i,Qv}var ey,LO;function JM(){if(LO)return ey;LO=1;var t=XY(),e=JY(),r=rZ(),n="['’]",i=RegExp(n,"g");function a(s){return function(o){return t(r(e(o).replace(i,"")),s,"")}}return ey=a,ey}var ty,NO;function nZ(){if(NO)return ty;NO=1;var t=JM(),e=t(function(r,n,i){return r+(i?"_":"")+n.toLowerCase()});return ty=e,ty}var iZ=nZ();const FO=vi(iZ);var ry,kO;function aZ(){if(kO)return ry;kO=1;function t(e,r,n){var i=-1,a=e.length;r<0&&(r=-r>a?0:a+r),n=n>a?a:n,n<0&&(n+=a),a=r>n?0:n-r>>>0,r>>>=0;for(var s=Array(a);++i<a;)s[i]=e[i+r];return s}return ry=t,ry}var ny,jO;function sZ(){if(jO)return ny;jO=1;var t=aZ();function e(r,n,i){var a=r.length;return i=i===void 0?a:i,!n&&i>=a?r:t(r,n,i)}return ny=e,ny}var iy,$O;function QM(){if($O)return iy;$O=1;var t="\\ud800-\\udfff",e="\\u0300-\\u036f",r="\\ufe20-\\ufe2f",n="\\u20d0-\\u20ff",i=e+r+n,a="\\ufe0e\\ufe0f",s="\\u200d",o=RegExp("["+s+t+i+a+"]");function l(c){return o.test(c)}return iy=l,iy}var ay,UO;function oZ(){if(UO)return ay;UO=1;function t(e){return e.split("")}return ay=t,ay}var sy,qO;function uZ(){if(qO)return sy;qO=1;var t="\\ud800-\\udfff",e="\\u0300-\\u036f",r="\\ufe20-\\ufe2f",n="\\u20d0-\\u20ff",i=e+r+n,a="\\ufe0e\\ufe0f",s="["+t+"]",o="["+i+"]",l="\\ud83c[\\udffb-\\udfff]",c="(?:"+o+"|"+l+")",d="[^"+t+"]",h="(?:\\ud83c[\\udde6-\\uddff]){2}",g="[\\ud800-\\udbff][\\udc00-\\udfff]",m="\\u200d",v=c+"?",b="["+a+"]?",y="(?:"+m+"(?:"+[d,h,g].join("|")+")"+b+v+")*",x=b+v+y,w="(?:"+[d+o+"?",o,h,g,s].join("|")+")",S=RegExp(l+"(?="+l+")|"+w+x,"g");function E(C){return C.match(S)||[]}return sy=E,sy}var oy,HO;function lZ(){if(HO)return oy;HO=1;var t=oZ(),e=QM(),r=uZ();function n(i){return e(i)?r(i):t(i)}return oy=n,oy}var uy,WO;function cZ(){if(WO)return uy;WO=1;var t=sZ(),e=QM(),r=lZ(),n=tl();function i(a){return function(s){s=n(s);var o=e(s)?r(s):void 0,l=o?o[0]:s.charAt(0),c=o?t(o,1).join(""):s.slice(1);return l[a]()+c}}return uy=i,uy}var ly,BO;function fZ(){if(BO)return ly;BO=1;var t=cZ(),e=t("toUpperCase");return ly=e,ly}var cy,zO;function dZ(){if(zO)return cy;zO=1;var t=tl(),e=fZ();function r(n){return e(t(n).toLowerCase())}return cy=r,cy}var fy,VO;function hZ(){if(VO)return fy;VO=1;var t=dZ(),e=JM(),r=e(function(n,i,a){return i=i.toLowerCase(),n+(a?t(i):i)});return fy=r,fy}var pZ=hZ();const gZ=vi(pZ);var dy,GO;function mZ(){if(GO)return dy;GO=1;var t=kM(),e=UM(),r=GM();function n(i,a){var s={};return a=r(a,3),e(i,function(o,l,c){t(s,a(o,l,c),o)}),s}return dy=n,dy}var vZ=mZ();const yZ=vi(vZ);var Zc={exports:{}},KO;function bZ(){if(KO)return Zc.exports;KO=1,Zc.exports=function(i){return t(e(i),i)},Zc.exports.array=t;function t(i,a){var s=i.length,o=new Array(s),l={},c=s,d=r(a),h=n(i);for(a.forEach(function(m){if(!h.has(m[0])||!h.has(m[1]))throw new Error("Unknown node. There is an unknown node in the supplied edges.")});c--;)l[c]||g(i[c],c,new Set);return o;function g(m,v,b){if(b.has(m)){var y;try{y=", node was:"+JSON.stringify(m)}catch{y=""}throw new Error("Cyclic dependency"+y)}if(!h.has(m))throw new Error("Found unknown node. Make sure to provided all involved nodes. Unknown node: "+JSON.stringify(m));if(!l[v]){l[v]=!0;var x=d.get(m)||new Set;if(x=Array.from(x),v=x.length){b.add(m);do{var w=x[--v];g(w,h.get(w),b)}while(v);b.delete(m)}o[--s]=m}}}function e(i){for(var a=new Set,s=0,o=i.length;s<o;s++){var l=i[s];a.add(l[0]),a.add(l[1])}return Array.from(a)}function r(i){for(var a=new Map,s=0,o=i.length;s<o;s++){var l=i[s];a.has(l[0])||a.set(l[0],new Set),a.has(l[1])||a.set(l[1],new Set),a.get(l[0]).add(l[1])}return a}function n(i){for(var a=new Map,s=0,o=i.length;s<o;s++)a.set(i[s],s);return a}return Zc.exports}var _Z=bZ();const xZ=vi(_Z);function wZ(t,e=[]){let r=[],n=new Set,i=new Set(e.map(([s,o])=>`${s}-${o}`));function a(s,o){let l=Kd.split(s)[0];n.add(l),i.has(`${o}-${l}`)||r.push([o,l])}for(const s in t)if(td(t,s)){let o=t[s];n.add(s),ji.isRef(o)&&o.isSibling?a(o.path,s):Eo(o)&&"deps"in o&&o.deps.forEach(l=>a(l,s))}return xZ.array(Array.from(n),r).reverse()}function XO(t,e){let r=1/0;return t.some((n,i)=>{var a;if(((a=e.path)==null?void 0:a.indexOf(n))!==-1)return r=i,!0}),r}function eP(t){return(e,r)=>XO(t,e)-XO(t,r)}function Qs(){return Qs=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},Qs.apply(this,arguments)}let YO=t=>Object.prototype.toString.call(t)==="[object Object]";function TZ(t,e){let r=Object.keys(t.fields);return Object.keys(e).filter(n=>r.indexOf(n)===-1)}const SZ=eP([]);class Lb extends Ar{constructor(e){super({type:"object"}),this.fields=Object.create(null),this._sortErrors=SZ,this._nodes=[],this._excludedEdges=[],this.withMutation(()=>{this.transform(function(n){if(typeof n=="string")try{n=JSON.parse(n)}catch{n=null}return this.isType(n)?n:null}),e&&this.shape(e)})}_typeCheck(e){return YO(e)||typeof e=="function"}_cast(e,r={}){var n;let i=super._cast(e,r);if(i===void 0)return this.getDefault();if(!this._typeCheck(i))return i;let a=this.fields,s=(n=r.stripUnknown)!=null?n:this.spec.noUnknown,o=this._nodes.concat(Object.keys(i).filter(h=>this._nodes.indexOf(h)===-1)),l={},c=Qs({},r,{parent:l,__validating:r.__validating||!1}),d=!1;for(const h of o){let g=a[h],m=td(i,h);if(g){let v,b=i[h];c.path=(r.path?`${r.path}.`:"")+h,g=g.resolve({value:b,context:r.context,parent:l});let y="spec"in g?g.spec:void 0,x=y==null?void 0:y.strict;if(y!=null&&y.strip){d=d||h in i;continue}v=!r.__validating||!x?g.cast(i[h],c):i[h],v!==void 0&&(l[h]=v)}else m&&!s&&(l[h]=i[h]);l[h]!==i[h]&&(d=!0)}return d?l:i}_validate(e,r={},n){let i=[],{sync:a,from:s=[],originalValue:o=e,abortEarly:l=this.spec.abortEarly,recursive:c=this.spec.recursive}=r;s=[{schema:this,value:o},...s],r.__validating=!0,r.originalValue=o,r.from=s,super._validate(e,r,(d,h)=>{if(d){if(!Vr.isError(d)||l)return void n(d,h);i.push(d)}if(!c||!YO(h)){n(i[0]||null,h);return}o=o||h;let g=this._nodes.map(m=>(v,b)=>{let y=m.indexOf(".")===-1?(r.path?`${r.path}.`:"")+m:`${r.path||""}["${m}"]`,x=this.fields[m];if(x&&"validate"in x){x.validate(h[m],Qs({},r,{path:y,from:s,strict:!0,parent:h,originalValue:o[m]}),b);return}b(null)});rd({tests:g,value:h,errors:i,endEarly:l,sort:this._sortErrors,path:r.path},n)})}clone(e){const r=super.clone(e);return r.fields=Qs({},this.fields),r._nodes=this._nodes,r._excludedEdges=this._excludedEdges,r._sortErrors=this._sortErrors,r}concat(e){let r=super.concat(e),n=r.fields;for(let[i,a]of Object.entries(this.fields)){const s=n[i];s===void 0?n[i]=a:s instanceof Ar&&a instanceof Ar&&(n[i]=a.concat(s))}return r.withMutation(()=>r.shape(n,this._excludedEdges))}getDefaultFromShape(){let e={};return this._nodes.forEach(r=>{const n=this.fields[r];e[r]="default"in n?n.getDefault():void 0}),e}_getDefault(){if("default"in this.spec)return super._getDefault();if(this._nodes.length)return this.getDefaultFromShape()}shape(e,r=[]){let n=this.clone(),i=Object.assign(n.fields,e);return n.fields=i,n._sortErrors=eP(Object.keys(i)),r.length&&(Array.isArray(r[0])||(r=[r]),n._excludedEdges=[...n._excludedEdges,...r]),n._nodes=wZ(i,n._excludedEdges),n}pick(e){const r={};for(const n of e)this.fields[n]&&(r[n]=this.fields[n]);return this.clone().withMutation(n=>(n.fields={},n.shape(r)))}omit(e){const r=this.clone(),n=r.fields;r.fields={};for(const i of e)delete n[i];return r.withMutation(()=>r.shape(n))}from(e,r,n){let i=Kd.getter(e,!0);return this.transform(a=>{if(a==null)return a;let s=a;return td(a,e)&&(s=Qs({},a),n||delete s[e],s[r]=i(a)),s})}noUnknown(e=!0,r=t0.noUnknown){typeof e=="string"&&(r=e,e=!0);let n=this.test({name:"noUnknown",exclusive:!0,message:r,test(i){if(i==null)return!0;const a=TZ(this.schema,i);return!e||a.length===0||this.createError({params:{unknown:a.join(", ")}})}});return n.spec.noUnknown=e,n}unknown(e=!0,r=t0.noUnknown){return this.noUnknown(!e,r)}transformKeys(e){return this.transform(r=>r&&yZ(r,(n,i)=>e(i)))}camelCase(){return this.transformKeys(gZ)}snakeCase(){return this.transformKeys(FO)}constantCase(){return this.transformKeys(e=>FO(e).toUpperCase())}describe(){let e=super.describe();return e.fields=KM(this.fields,r=>r.describe()),e}}function tP(t){return new Lb(t)}tP.prototype=Lb.prototype;function ad(){return ad=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},ad.apply(this,arguments)}function rP(t){return new Nb(t)}class Nb extends Ar{constructor(e){super({type:"array"}),this.innerType=void 0,this.innerType=e,this.withMutation(()=>{this.transform(function(r){if(typeof r=="string")try{r=JSON.parse(r)}catch{r=null}return this.isType(r)?r:null})})}_typeCheck(e){return Array.isArray(e)}get _subType(){return this.innerType}_cast(e,r){const n=super._cast(e,r);if(!this._typeCheck(n)||!this.innerType)return n;let i=!1;const a=n.map((s,o)=>{const l=this.innerType.cast(s,ad({},r,{path:`${r.path||""}[${o}]`}));return l!==s&&(i=!0),l});return i?a:n}_validate(e,r={},n){var i,a;let s=[];r.sync;let o=r.path,l=this.innerType,c=(i=r.abortEarly)!=null?i:this.spec.abortEarly,d=(a=r.recursive)!=null?a:this.spec.recursive,h=r.originalValue!=null?r.originalValue:e;super._validate(e,r,(g,m)=>{if(g){if(!Vr.isError(g)||c)return void n(g,m);s.push(g)}if(!d||!l||!this._typeCheck(m)){n(s[0]||null,m);return}h=h||m;let v=new Array(m.length);for(let b=0;b<m.length;b++){let y=m[b],x=`${r.path||""}[${b}]`,w=ad({},r,{path:x,strict:!0,parent:m,index:b,originalValue:h[b]});v[b]=(S,E)=>l.validate(y,w,E)}rd({path:o,value:m,errors:s,endEarly:c,tests:v},n)})}clone(e){const r=super.clone(e);return r.innerType=this.innerType,r}concat(e){let r=super.concat(e);return r.innerType=this.innerType,e.innerType&&(r.innerType=r.innerType?r.innerType.concat(e.innerType):e.innerType),r}of(e){let r=this.clone();if(!Eo(e))throw new TypeError("`array.of()` sub-schema must be a valid yup schema not: "+ho(e));return r.innerType=e,r}length(e,r=_f.length){return this.test({message:r,name:"length",exclusive:!0,params:{length:e},test(n){return rr(n)||n.length===this.resolve(e)}})}min(e,r){return r=r||_f.min,this.test({message:r,name:"min",exclusive:!0,params:{min:e},test(n){return rr(n)||n.length>=this.resolve(e)}})}max(e,r){return r=r||_f.max,this.test({message:r,name:"max",exclusive:!0,params:{max:e},test(n){return rr(n)||n.length<=this.resolve(e)}})}ensure(){return this.default(()=>[]).transform((e,r)=>this._typeCheck(e)?e:r==null?[]:[].concat(r))}compact(e){let r=e?(n,i,a)=>!e(n,i,a):n=>!!n;return this.transform(n=>n!=null?n.filter(r):n)}describe(){let e=super.describe();return this.innerType&&(e.innerType=this.innerType.describe()),e}nullable(e=!0){return super.nullable(e)}defined(){return super.defined()}required(e){return super.required(e)}}rP.prototype=Nb.prototype;function CZ(t){return new EZ(t)}class EZ{constructor(e){this.type="lazy",this.__isYupSchema__=!0,this.__inputType=void 0,this.__outputType=void 0,this._resolve=(r,n={})=>{let i=this.builder(r,n);if(!Eo(i))throw new TypeError("lazy() functions must return a valid schema");return i.resolve(n)},this.builder=e}resolve(e){return this._resolve(e.value,e)}cast(e,r){return this._resolve(e,r).cast(e,r)}validate(e,r,n){return this._resolve(e,r).validate(e,r,n)}validateSync(e,r){return this._resolve(e,r).validateSync(e,r)}validateAt(e,r,n){return this._resolve(r,n).validateAt(e,r,n)}validateSyncAt(e,r,n){return this._resolve(r,n).validateSyncAt(e,r,n)}describe(){return null}isValid(e,r){return this._resolve(e,r).isValid(e,r)}isValidSync(e,r){return this._resolve(e,r).isValidSync(e,r)}}function nP(t){Object.keys(t).forEach(e=>{Object.keys(t[e]).forEach(r=>{QK[e][r]=t[e][r]})})}function iP(t,e,r){if(!t||!Eo(t.prototype))throw new TypeError("You must provide a yup schema constructor function");if(typeof e!="string")throw new TypeError("A Method name must be provided");if(typeof r!="function")throw new TypeError("Method function must be provided");t.prototype[e]=r}const ZO=Object.freeze(Object.defineProperty({__proto__:null,ArraySchema:Nb,BaseSchema:Ar,BooleanSchema:Ab,DateSchema:Xd,MixedSchema:Ob,NumberSchema:Db,ObjectSchema:Lb,StringSchema:Rb,ValidationError:Vr,addMethod:iP,array:rP,bool:n0,boolean:n0,date:Pb,isSchema:Eo,lazy:CZ,mixed:YM,number:ZM,object:tP,reach:$Y,ref:FY,setLocale:nP,string:Ib},Symbol.toStringTag,{value:"Module"})),OZ={mixed:{required:"validation:required"},string:{email:"validation:invalid_email",max:"validation:maximum_of_characters"}};nP(OZ);const AZ=/^[^\s].*[^\s]$/i;iP(Ib,"noSurroundingSpaces",function(){return this.test("is-string-trimmed","validation:no_surrounding_spaces",t=>!t||mr.isEmpty(t)?!0:t.length<3?/^[\S]*$/i.test(t):AZ.test(t))});const IZ=ZO.object({alertThreshold:ZO.number().required()}),RZ=({handleClose:t,onUpdate:e,alert:r,t:n})=>{const{enqueueSnackbar:i}=VK(),a=R5(),s=L5(),o=M5(),l=()=>{o.mutate({alertType:on.CUSTOM,email:S.emailEnabledSubscription,sms:S.smsEnabledSubscription,enrollment:r==null?void 0:r.number,threshold:+S.alertThreshold},{onSuccess:v,onError:y})},c=()=>{a.mutate({alertId:r==null?void 0:r.number,sms:S.smsEnabledSubscription,email:S.emailEnabledSubscription,threshold:+S.alertThreshold},{onSuccess:d,onError:y})},d=()=>{s.mutate({alertId:r.number,alertType:r.alertType,sms:S.smsEnabledSubscription,email:S.emailEnabledSubscription,threshold:+S.alertThreshold,enrollment:r.number},{onSuccess:b,onError:y})},h=()=>{S.alertThreshold!==r.threshold?l():d()},g=()=>{r.alertType===on.CRITICAL?h():c()},m=(C,I=void 0)=>{const T=new CustomEvent("add-toast",{detail:{id:"custom-alerts-toast",content:$U`
|
|
83
|
+
<style>
|
|
84
|
+
.custom-alerts-toast {
|
|
85
|
+
white-space: nowrap;
|
|
86
|
+
}
|
|
87
|
+
</style>
|
|
88
|
+
<ix-message-toast
|
|
89
|
+
class="custom-alerts-toast"
|
|
90
|
+
toastId="custom-alerts-toast"
|
|
91
|
+
.hasClose=${!1}
|
|
92
|
+
type=${UU(I)}
|
|
93
|
+
>
|
|
94
|
+
${C}
|
|
95
|
+
</ix-message-toast>
|
|
96
|
+
`,autoClose:5e3,vertical:"bottom",horizontal:"center",animated:!0,durationOut:333,above:!1}});window.dispatchEvent(T)},v=()=>{i(n("customize-alert-dialog.success-custom-created"),{variant:"success"}),m("Custom alert created"),e&&e(),t()},b=()=>{i(c8(n,r.alertType),{variant:"success"}),m("Custom alert updated"),e&&e(),t()},y=C=>{const I=f8(n,C==null?void 0:C.message);i(I,{variant:"error"}),m("An error occurred, please try again","error"),E(!1)},w=bK({initialValues:{emailEnabledSubscription:r==null?void 0:r.emailEnabledSubscription,smsEnabledSubscription:r==null?void 0:r.smsEnabledSubscription,alertThreshold:(r==null?void 0:r.threshold)||0},onSubmit:g,validationSchema:IZ}),{values:S,setSubmitting:E}=w;return{formik:w,handleSave:g,handleCreateSuccess:v,handleUpdateSuccess:b,handleError:y,createCustomAlert:l,saveCriticalAlert:h}},DZ=({handleClose:t,onUpdate:e,isOpen:r,alert:n})=>{const{t:i}=Qt(["location"]),{formik:a}=RZ({handleClose:t,onUpdate:e,alert:n,t:i}),{values:s,handleSubmit:o,setFieldValue:l,isValid:c,isSubmitting:d,errors:h}=a,g=[{label:i("customize-alert-dialog.cancel-button"),mobileLabel:A.jsx(Hi,{style:{"--ix-icon-font-size":"24px"},children:"close"}),trigger:t},{label:i("customize-alert-dialog.save-button"),mobileLabel:i("create-button"),trigger:o,disabled:!c,loading:d}];return A.jsx(gK,{value:a,children:A.jsxs(G0,{title:i("customize-alert-dialog.title"),actions:g,open:r,children:[A.jsx(lt,{variant:"body1",style:{color:Ye.onSurfaceVariant,margin:0,maxWidth:512},children:i("customize-alert-dialog.message")}),A.jsx(lt,{variant:"body1",style:{margin:"21px 0"},children:i("customize-alert-dialog.it-load-level")}),A.jsx(TW,{id:"alertThreshold",name:"alertThreshold",label:i("customize-alert-dialog.threshold"),prefixText:`${n.functionName} ${n.comparisonOperator}`,value:String(s.alertThreshold??""),onTextInput:m=>l("alertThreshold",wW(m)),error:!!h.alertThreshold}),A.jsx("div",{style:{display:"flex",alignItems:"center",columnGap:25,marginTop:"20px"},children:["emailEnabledSubscription","smsEnabledSubscription"].map(m=>{const v=i(m==="emailEnabledSubscription"?"customize-alert-dialog.email-alerts":"customize-alert-dialog.sms-alerts");return A.jsxs("label",{style:{display:"flex",alignItems:"center",gap:8},children:[A.jsx(k0,{"aria-label":v,id:m,selected:!!s[m],onSwitchChange:b=>l(m,b.target.selected)}),A.jsx(lt,{variant:"body1",noWrap:!0,children:v})]},m)})}),A.jsx(lt,{variant:"body2",style:{maxWidth:"512px",fontSize:"12px",marginTop:"20px"},children:i("customize-alert-dialog.bottom-message")})]})})},MZ=(t,e=1)=>{if(e>1&&(e=1),t.startsWith("#")){e=Math.floor(255*e);const r=t.split("#").pop(),n=t.substring(0,1),i=e>0?e.toString(16):"FF";return n+(i+r).toUpperCase()}return t.startsWith("rgb")?`rgba(${t.split(/\D/i).filter(Boolean).join(",")},${e})`:t},i0=(t,e)=>{const r=a=>parseInt(a,16),n=a=>parseInt(a+a,16);t=t.substring(1);const i=(a=255)=>e===void 0?a:e;if(t.length===3){const[a,s,o]=t.match(/\w/g).map(n);return`rgba(${a},${s},${o},${i()})`}if(t.length===4){const[a,s,o,l]=t.match(/\w/g).map(n);return`rgba(${s},${o},${l},${i(a/255)})`}if(t.length===6){const[a,s,o]=t.match(/\w{2}/g).map(r);return`rgba(${a},${s},${o},${i()})`}if(t.length===8){const[a,s,o,l]=t.match(/\w{2}/g).map(r);return`rgba(${s},${o},${l},${i(a/255)})`}return t},JO=(t,e=[])=>Object.entries(t).map(([r,n])=>`${mr.kebabCase(r)}:${n}`).concat(e).join(";"),PZ=(t,e)=>{if(!t)return"transparent";const{ctx:r,chartArea:{height:n}}=t,i=i0(e,.25),a=i0(e,0),s=r==null?void 0:r.createLinearGradient(0,0,0,n);return s==null||s.addColorStop(0,i),s==null||s.addColorStop(1,a),s},LZ=(t,{options:e})=>!t||!t.length?[]:t.map(({trendData:r,deviceName:n},i)=>{let a=[];return r.forEach(({pointValue:s,utcPollDateTime:o})=>{const l=cn(o).getTime();a.push({x:l,y:Number(s)})}),a=a.sort((s,o)=>s.x-o.x),{label:n,data:a,hidden:i>0,pointBorderColor:Tn.pointBorder,pointRadius:3,animation:{duration:500,easing:"easeInOutCubic"},...e}});var NZ=LD();const FZ=vi(NZ),kZ=(t,e)=>{const r=/\d{4}-\d{2}-\d{2}/;if(t){if(wo(cn(t))&&r.test(String(t)))return t.search(/[a-z]/i)===-1?FZ(new Date(t),e,{timeZone:"UTC"}):ND(new Date(t),"UTC",e)}else return"-";return t},aP=({label:t,value:e})=>{const{dateTimeFormatPreferences:r,getTimeFormatString:n}=Id(),i=n(!0),a=`${r.preferredDateFormat} ${i} (zzz)`;return A.jsxs(t8,{children:[A.jsx(r8,{variant:"body1","data-testid":`datapoint-label-${t}`,children:t}),A.jsx(i8,{children:A.jsx(n8,{"data-testid":`datapoint-value-${e}`,children:kZ(e,a)})})]})},jZ=({alert:t,t:e,translationKey:r,onUpdate:n})=>{const[i,a]=rD(),s=t.threshold?`${t.functionName} ${t.comparisonOperator} ${t.threshold}`:"",o={deviceName:t.functionName,threshold:s,liveValue:t.functionValue,timeStamp:t.alertTimestamp},l=Object.entries(o).map(d=>({key:d[0],value:d[1]})),c=()=>{a(),i(A.jsx(DZ,{alert:t,handleClose:a,onUpdate:n,isOpen:!0}))};return A.jsxs(BD,{"data-testid":"alert-definition",children:[A.jsxs(HD,{children:[A.jsx(WD,{variant:"h6","data-testid":`alert-title-${t.number}`,children:e(t.functionName)}),t.alertCategory&&A.jsx(Jf,{title:t.alertCategory})]}),A.jsx(zD,{children:l.map(({key:d,value:h})=>A.jsx(aP,{label:e(`${r}.${d}`),value:h},d))}),A.jsx(l8,{alert:t,onClickCustomize:c})]})},$Z=({alert:t,t:e,translationKey:r,selectedAlert:n,alertInstanceClickHandler:i})=>{const a={deviceName:t.alertName,configurationItem:t.deviceName,functionValue:t.functionValue,alertTimeStamp:t.alertTimeStamp},s=Object.entries(a).map(o=>({key:o[0],value:o[1]}));return A.jsxs(BD,{$canBeClicked:!0,$selected:n===t.alertId,"data-testid":"alert-instance",onClick:()=>i==null?void 0:i(t.alertId),children:[A.jsxs(HD,{children:[A.jsx(WD,{variant:"h6","data-testid":`alert-title-${t.alertId}`,children:e(t.alertName)}),!!t.alertCategory&&A.jsx(Jf,{title:t.alertCategory})]}),A.jsx(zD,{children:s.map(({key:o,value:l})=>A.jsx(aP,{label:o==="functionValue"?e(`${r}.${o}`,{device:t.alertName}):e(`${r}.${o}`),value:l},o))})]})},UZ=(t,e,r,n,i)=>(a,s)=>{if(e){const{ddid:l,alertCategory:c}=a,d=`${l}-${mr.kebabCase(c)}-${s}`;return A.jsx(jZ,{alert:a,t,translationKey:"alert-definition",onUpdate:n},d)}const{alertId:o}=a;return A.jsx($Z,{alert:a,selectedAlert:r,t,translationKey:"alert-instance",alertInstanceClickHandler:i},o)},qZ=[10,25,50,100],sP=({leasedSpaceName:t,alertType:e,alertCategory:r,title:n,isDefinitionsView:i,selectedAlertInstance:a,alertInstanceClickHandler:s})=>{const{t:o}=Qt(["location"]),[l,c]=He.useState(0),[d,h]=He.useState(la.DEVICE_NAME),[g,m]=He.useState(10),[v,b]=He.useState(0),y=XR.ASC,x={leasedSpaceName:t,order:y,sort:d,size:g,page:l,alertType:Q4(e),alertCategory:J4(r)};ut(()=>{c(0),b(0)},[e,r]);const w=[{id:la.DEVICE_NAME,name:o(`alert-list.${la.DEVICE_NAME}`)},{id:la.FUNCTION_VALUE,name:o(`alert-list.${la.FUNCTION_VALUE}`)},...i?[{id:la.THRESHOLD,name:o(`alert-list.${la.THRESHOLD}`)}]:[]],S=yr(()=>i?ti.DEFINITIONS:e===sb?ti.HISTORY:ti.INSTANCES,[e,i]),E=yr(()=>jD(S),[S]),{data:C,isFetching:I,isError:T,refetch:D}=E(x,{onSuccess(X){b((X==null?void 0:X.totalElements)||0)}}),P=I?!1:(C==null?void 0:C.totalElements)<=0,L=X=>{c(0),h(X)},F=({detail:X})=>{m(X.pageSize),c(X.page-1)},H=UZ(o,i,a,D,s);return A.jsxs(A.Fragment,{children:[A.jsxs(Z4,{children:[A.jsx(lt,{variant:"h6",children:n}),A.jsxs("div",{style:{display:"flex",alignItems:"center"},children:[A.jsx(lt,{variant:"body1",style:{marginRight:"8px"},children:o("alert-list.sort-by")}),A.jsx(K0,{ariaLabel:o("alert-list.sort-by"),name:"sort",value:d,options:w,onChange:L})]})]}),A.jsxs(Y4,{"data-testid":"alert-list-container",children:[I&&A.jsx(Ff,{linear:!1,indeterminate:!0,role:"progressbar","aria-label":"Loading...","aria-busy":"true",style:{"--md-circular-progress-size":"25px"}}),(T||P)&&A.jsx(X0,{children:A.jsx(lt,{variant:"body1",children:o("no-dcim-data-available")})}),!T&&!I&&(C==null?void 0:C.content.map(H))]}),A.jsx(gW,{"data-testid":"alert-pagination",style:{display:"block"},recordCount:v,page:(l||0)+1,pageSize:g,pageSizes:qZ,onUpdatePagination:F})]})},HZ=({children:t,style:e,...r})=>{const n=Ve(Et("md"));return A.jsx("div",{style:{display:"flex",flexDirection:"column",gap:n?26:42,...e},...r,children:t})},WZ=()=>{const{t}=Qt("location"),e=window.location.search.slice(1),r=Pd.parse(e),{alertId:n,assetName:i,leasedSpaceName:a,sitecode:s,type:o}=r,l=typeof n=="string"?n:"",[c,d]=or({category:co,type:o||co}),[h,g]=or(!!l),[m,v]=or(l),b=Ve(Et("lg")),y=(S,E)=>{v(""),d(C=>({...C,[S]:E}))},x=S=>{v(S),b&&g(!0)},w=yr(()=>c.type===sb,[c]);return A.jsx(eb,{children:A.jsxs(gD,{children:[A.jsx(rb,{assetName:i,sitecode:s}),A.jsxs(tb,{spacing:{xs:2.5,md:3},children:[A.jsx(zr,{xs:12,sm:4,md:3,lg:2,children:A.jsxs(HZ,{children:[A.jsx(ob,{leasedSpaceName:a,filters:c,handleFilters:y}),A.jsx(qD,{leasedSpaceName:a,filters:c,handleFilters:y})]})}),A.jsx(zr,{xs:12,sm:8,md:9,lg:5,children:A.jsx(sP,{alertCategory:c.category,alertInstanceClickHandler:x,alertType:c.type,leasedSpaceName:a,title:t("alerts.details.title"),selectedAlertInstance:m})}),A.jsx(zr,{xs:12,lg:5,children:!!m&&A.jsx(A.Fragment,{children:b?A.jsx(H4,{alertInstanceId:m,isOpen:h,handleClose:()=>g(!1),isHistorical:w}):A.jsx(kD,{alertInstanceId:m,isHistorical:w})})})]})]})})},Yd="location-changed",BZ=()=>(ut(()=>{window.dispatchEvent(new CustomEvent(Yd,{detail:{location:{route:{hideAccountSwitcher:!0}}}}))},[]),A.jsx(WZ,{}));var ei=(t=>(t.Day="day",t.Hour="hour",t.FifteenMinutes="15 minute",t.FiveMinutes="5 minute",t.Minute="minute",t))(ei||{});const zZ=({children:t,style:e,...r})=>A.jsx("div",{style:{gridColumn:"1 / -1",paddingTop:"1rem",width:"100%",...e},...r,children:t});/*!
|
|
97
|
+
* @kurkle/color v0.3.4
|
|
98
|
+
* https://github.com/kurkle/color#readme
|
|
99
|
+
* (c) 2024 Jukka Kurkela
|
|
100
|
+
* Released under the MIT License
|
|
101
|
+
*/function rl(t){return t+.5|0}const ma=(t,e,r)=>Math.max(Math.min(t,r),e);function yu(t){return ma(rl(t*2.55),0,255)}function ba(t){return ma(rl(t*255),0,255)}function Fi(t){return ma(rl(t/2.55)/100,0,1)}function QO(t){return ma(rl(t*100),0,100)}const jn={0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,A:10,B:11,C:12,D:13,E:14,F:15,a:10,b:11,c:12,d:13,e:14,f:15},a0=[..."0123456789ABCDEF"],VZ=t=>a0[t&15],GZ=t=>a0[(t&240)>>4]+a0[t&15],Jc=t=>(t&240)>>4===(t&15),KZ=t=>Jc(t.r)&&Jc(t.g)&&Jc(t.b)&&Jc(t.a);function XZ(t){var e=t.length,r;return t[0]==="#"&&(e===4||e===5?r={r:255&jn[t[1]]*17,g:255&jn[t[2]]*17,b:255&jn[t[3]]*17,a:e===5?jn[t[4]]*17:255}:(e===7||e===9)&&(r={r:jn[t[1]]<<4|jn[t[2]],g:jn[t[3]]<<4|jn[t[4]],b:jn[t[5]]<<4|jn[t[6]],a:e===9?jn[t[7]]<<4|jn[t[8]]:255})),r}const YZ=(t,e)=>t<255?e(t):"";function ZZ(t){var e=KZ(t)?VZ:GZ;return t?"#"+e(t.r)+e(t.g)+e(t.b)+YZ(t.a,e):void 0}const JZ=/^(hsla?|hwb|hsv)\(\s*([-+.e\d]+)(?:deg)?[\s,]+([-+.e\d]+)%[\s,]+([-+.e\d]+)%(?:[\s,]+([-+.e\d]+)(%)?)?\s*\)$/;function oP(t,e,r){const n=e*Math.min(r,1-r),i=(a,s=(a+t/30)%12)=>r-n*Math.max(Math.min(s-3,9-s,1),-1);return[i(0),i(8),i(4)]}function QZ(t,e,r){const n=(i,a=(i+t/60)%6)=>r-r*e*Math.max(Math.min(a,4-a,1),0);return[n(5),n(3),n(1)]}function eJ(t,e,r){const n=oP(t,1,.5);let i;for(e+r>1&&(i=1/(e+r),e*=i,r*=i),i=0;i<3;i++)n[i]*=1-e-r,n[i]+=e;return n}function tJ(t,e,r,n,i){return t===i?(e-r)/n+(e<r?6:0):e===i?(r-t)/n+2:(t-e)/n+4}function Fb(t){const r=t.r/255,n=t.g/255,i=t.b/255,a=Math.max(r,n,i),s=Math.min(r,n,i),o=(a+s)/2;let l,c,d;return a!==s&&(d=a-s,c=o>.5?d/(2-a-s):d/(a+s),l=tJ(r,n,i,d,a),l=l*60+.5),[l|0,c||0,o]}function kb(t,e,r,n){return(Array.isArray(e)?t(e[0],e[1],e[2]):t(e,r,n)).map(ba)}function jb(t,e,r){return kb(oP,t,e,r)}function rJ(t,e,r){return kb(eJ,t,e,r)}function nJ(t,e,r){return kb(QZ,t,e,r)}function uP(t){return(t%360+360)%360}function iJ(t){const e=JZ.exec(t);let r=255,n;if(!e)return;e[5]!==n&&(r=e[6]?yu(+e[5]):ba(+e[5]));const i=uP(+e[2]),a=+e[3]/100,s=+e[4]/100;return e[1]==="hwb"?n=rJ(i,a,s):e[1]==="hsv"?n=nJ(i,a,s):n=jb(i,a,s),{r:n[0],g:n[1],b:n[2],a:r}}function aJ(t,e){var r=Fb(t);r[0]=uP(r[0]+e),r=jb(r),t.r=r[0],t.g=r[1],t.b=r[2]}function sJ(t){if(!t)return;const e=Fb(t),r=e[0],n=QO(e[1]),i=QO(e[2]);return t.a<255?`hsla(${r}, ${n}%, ${i}%, ${Fi(t.a)})`:`hsl(${r}, ${n}%, ${i}%)`}const eA={x:"dark",Z:"light",Y:"re",X:"blu",W:"gr",V:"medium",U:"slate",A:"ee",T:"ol",S:"or",B:"ra",C:"lateg",D:"ights",R:"in",Q:"turquois",E:"hi",P:"ro",O:"al",N:"le",M:"de",L:"yello",F:"en",K:"ch",G:"arks",H:"ea",I:"ightg",J:"wh"},tA={OiceXe:"f0f8ff",antiquewEte:"faebd7",aqua:"ffff",aquamarRe:"7fffd4",azuY:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"0",blanKedOmond:"ffebcd",Xe:"ff",XeviTet:"8a2be2",bPwn:"a52a2a",burlywood:"deb887",caMtXe:"5f9ea0",KartYuse:"7fff00",KocTate:"d2691e",cSO:"ff7f50",cSnflowerXe:"6495ed",cSnsilk:"fff8dc",crimson:"dc143c",cyan:"ffff",xXe:"8b",xcyan:"8b8b",xgTMnPd:"b8860b",xWay:"a9a9a9",xgYF:"6400",xgYy:"a9a9a9",xkhaki:"bdb76b",xmagFta:"8b008b",xTivegYF:"556b2f",xSange:"ff8c00",xScEd:"9932cc",xYd:"8b0000",xsOmon:"e9967a",xsHgYF:"8fbc8f",xUXe:"483d8b",xUWay:"2f4f4f",xUgYy:"2f4f4f",xQe:"ced1",xviTet:"9400d3",dAppRk:"ff1493",dApskyXe:"bfff",dimWay:"696969",dimgYy:"696969",dodgerXe:"1e90ff",fiYbrick:"b22222",flSOwEte:"fffaf0",foYstWAn:"228b22",fuKsia:"ff00ff",gaRsbSo:"dcdcdc",ghostwEte:"f8f8ff",gTd:"ffd700",gTMnPd:"daa520",Way:"808080",gYF:"8000",gYFLw:"adff2f",gYy:"808080",honeyMw:"f0fff0",hotpRk:"ff69b4",RdianYd:"cd5c5c",Rdigo:"4b0082",ivSy:"fffff0",khaki:"f0e68c",lavFMr:"e6e6fa",lavFMrXsh:"fff0f5",lawngYF:"7cfc00",NmoncEffon:"fffacd",ZXe:"add8e6",ZcSO:"f08080",Zcyan:"e0ffff",ZgTMnPdLw:"fafad2",ZWay:"d3d3d3",ZgYF:"90ee90",ZgYy:"d3d3d3",ZpRk:"ffb6c1",ZsOmon:"ffa07a",ZsHgYF:"20b2aa",ZskyXe:"87cefa",ZUWay:"778899",ZUgYy:"778899",ZstAlXe:"b0c4de",ZLw:"ffffe0",lime:"ff00",limegYF:"32cd32",lRF:"faf0e6",magFta:"ff00ff",maPon:"800000",VaquamarRe:"66cdaa",VXe:"cd",VScEd:"ba55d3",VpurpN:"9370db",VsHgYF:"3cb371",VUXe:"7b68ee",VsprRggYF:"fa9a",VQe:"48d1cc",VviTetYd:"c71585",midnightXe:"191970",mRtcYam:"f5fffa",mistyPse:"ffe4e1",moccasR:"ffe4b5",navajowEte:"ffdead",navy:"80",Tdlace:"fdf5e6",Tive:"808000",TivedBb:"6b8e23",Sange:"ffa500",SangeYd:"ff4500",ScEd:"da70d6",pOegTMnPd:"eee8aa",pOegYF:"98fb98",pOeQe:"afeeee",pOeviTetYd:"db7093",papayawEp:"ffefd5",pHKpuff:"ffdab9",peru:"cd853f",pRk:"ffc0cb",plum:"dda0dd",powMrXe:"b0e0e6",purpN:"800080",YbeccapurpN:"663399",Yd:"ff0000",Psybrown:"bc8f8f",PyOXe:"4169e1",saddNbPwn:"8b4513",sOmon:"fa8072",sandybPwn:"f4a460",sHgYF:"2e8b57",sHshell:"fff5ee",siFna:"a0522d",silver:"c0c0c0",skyXe:"87ceeb",UXe:"6a5acd",UWay:"708090",UgYy:"708090",snow:"fffafa",sprRggYF:"ff7f",stAlXe:"4682b4",tan:"d2b48c",teO:"8080",tEstN:"d8bfd8",tomato:"ff6347",Qe:"40e0d0",viTet:"ee82ee",JHt:"f5deb3",wEte:"ffffff",wEtesmoke:"f5f5f5",Lw:"ffff00",LwgYF:"9acd32"};function oJ(){const t={},e=Object.keys(tA),r=Object.keys(eA);let n,i,a,s,o;for(n=0;n<e.length;n++){for(s=o=e[n],i=0;i<r.length;i++)a=r[i],o=o.replace(a,eA[a]);a=parseInt(tA[s],16),t[o]=[a>>16&255,a>>8&255,a&255]}return t}let Qc;function uJ(t){Qc||(Qc=oJ(),Qc.transparent=[0,0,0,0]);const e=Qc[t.toLowerCase()];return e&&{r:e[0],g:e[1],b:e[2],a:e.length===4?e[3]:255}}const lJ=/^rgba?\(\s*([-+.\d]+)(%)?[\s,]+([-+.e\d]+)(%)?[\s,]+([-+.e\d]+)(%)?(?:[\s,/]+([-+.e\d]+)(%)?)?\s*\)$/;function cJ(t){const e=lJ.exec(t);let r=255,n,i,a;if(e){if(e[7]!==n){const s=+e[7];r=e[8]?yu(s):ma(s*255,0,255)}return n=+e[1],i=+e[3],a=+e[5],n=255&(e[2]?yu(n):ma(n,0,255)),i=255&(e[4]?yu(i):ma(i,0,255)),a=255&(e[6]?yu(a):ma(a,0,255)),{r:n,g:i,b:a,a:r}}}function fJ(t){return t&&(t.a<255?`rgba(${t.r}, ${t.g}, ${t.b}, ${Fi(t.a)})`:`rgb(${t.r}, ${t.g}, ${t.b})`)}const hy=t=>t<=.0031308?t*12.92:Math.pow(t,1/2.4)*1.055-.055,Zs=t=>t<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4);function dJ(t,e,r){const n=Zs(Fi(t.r)),i=Zs(Fi(t.g)),a=Zs(Fi(t.b));return{r:ba(hy(n+r*(Zs(Fi(e.r))-n))),g:ba(hy(i+r*(Zs(Fi(e.g))-i))),b:ba(hy(a+r*(Zs(Fi(e.b))-a))),a:t.a+r*(e.a-t.a)}}function ef(t,e,r){if(t){let n=Fb(t);n[e]=Math.max(0,Math.min(n[e]+n[e]*r,e===0?360:1)),n=jb(n),t.r=n[0],t.g=n[1],t.b=n[2]}}function lP(t,e){return t&&Object.assign(e||{},t)}function rA(t){var e={r:0,g:0,b:0,a:255};return Array.isArray(t)?t.length>=3&&(e={r:t[0],g:t[1],b:t[2],a:255},t.length>3&&(e.a=ba(t[3]))):(e=lP(t,{r:0,g:0,b:0,a:1}),e.a=ba(e.a)),e}function hJ(t){return t.charAt(0)==="r"?cJ(t):iJ(t)}class $u{constructor(e){if(e instanceof $u)return e;const r=typeof e;let n;r==="object"?n=rA(e):r==="string"&&(n=XZ(e)||uJ(e)||hJ(e)),this._rgb=n,this._valid=!!n}get valid(){return this._valid}get rgb(){var e=lP(this._rgb);return e&&(e.a=Fi(e.a)),e}set rgb(e){this._rgb=rA(e)}rgbString(){return this._valid?fJ(this._rgb):void 0}hexString(){return this._valid?ZZ(this._rgb):void 0}hslString(){return this._valid?sJ(this._rgb):void 0}mix(e,r){if(e){const n=this.rgb,i=e.rgb;let a;const s=r===a?.5:r,o=2*s-1,l=n.a-i.a,c=((o*l===-1?o:(o+l)/(1+o*l))+1)/2;a=1-c,n.r=255&c*n.r+a*i.r+.5,n.g=255&c*n.g+a*i.g+.5,n.b=255&c*n.b+a*i.b+.5,n.a=s*n.a+(1-s)*i.a,this.rgb=n}return this}interpolate(e,r){return e&&(this._rgb=dJ(this._rgb,e._rgb,r)),this}clone(){return new $u(this.rgb)}alpha(e){return this._rgb.a=ba(e),this}clearer(e){const r=this._rgb;return r.a*=1-e,this}greyscale(){const e=this._rgb,r=rl(e.r*.3+e.g*.59+e.b*.11);return e.r=e.g=e.b=r,this}opaquer(e){const r=this._rgb;return r.a*=1+e,this}negate(){const e=this._rgb;return e.r=255-e.r,e.g=255-e.g,e.b=255-e.b,this}lighten(e){return ef(this._rgb,2,e),this}darken(e){return ef(this._rgb,2,-e),this}saturate(e){return ef(this._rgb,1,e),this}desaturate(e){return ef(this._rgb,1,-e),this}rotate(e){return aJ(this._rgb,e),this}}/*!
|
|
102
|
+
* Chart.js v4.4.0
|
|
103
|
+
* https://www.chartjs.org
|
|
104
|
+
* (c) 2023 Chart.js Contributors
|
|
105
|
+
* Released under the MIT License
|
|
106
|
+
*/function Mi(){}const pJ=(()=>{let t=0;return()=>t++})();function ur(t){return t===null||typeof t>"u"}function Xt(t){if(Array.isArray&&Array.isArray(t))return!0;const e=Object.prototype.toString.call(t);return e.slice(0,7)==="[object"&&e.slice(-6)==="Array]"}function it(t){return t!==null&&Object.prototype.toString.call(t)==="[object Object]"}function Ir(t){return(typeof t=="number"||t instanceof Number)&&isFinite(+t)}function oi(t,e){return Ir(t)?t:e}function Xe(t,e){return typeof t>"u"?e:t}const gJ=(t,e)=>typeof t=="string"&&t.endsWith("%")?parseFloat(t)/100*e:+t;function Ut(t,e,r){if(t&&typeof t.call=="function")return t.apply(r,e)}function jt(t,e,r,n){let i,a,s;if(Xt(t))for(a=t.length,i=0;i<a;i++)e.call(r,t[i],i);else if(it(t))for(s=Object.keys(t),a=s.length,i=0;i<a;i++)e.call(r,t[s[i]],s[i])}function sd(t,e){let r,n,i,a;if(!t||!e||t.length!==e.length)return!1;for(r=0,n=t.length;r<n;++r)if(i=t[r],a=e[r],i.datasetIndex!==a.datasetIndex||i.index!==a.index)return!1;return!0}function od(t){if(Xt(t))return t.map(od);if(it(t)){const e=Object.create(null),r=Object.keys(t),n=r.length;let i=0;for(;i<n;++i)e[r[i]]=od(t[r[i]]);return e}return t}function cP(t){return["__proto__","prototype","constructor"].indexOf(t)===-1}function mJ(t,e,r,n){if(!cP(t))return;const i=e[t],a=r[t];it(i)&&it(a)?Uu(i,a,n):e[t]=od(a)}function Uu(t,e,r){const n=Xt(e)?e:[e],i=n.length;if(!it(t))return t;r=r||{};const a=r.merger||mJ;let s;for(let o=0;o<i;++o){if(s=n[o],!it(s))continue;const l=Object.keys(s);for(let c=0,d=l.length;c<d;++c)a(l[c],t,s,r)}return t}function Ou(t,e){return Uu(t,e,{merger:vJ})}function vJ(t,e,r){if(!cP(t))return;const n=e[t],i=r[t];it(n)&&it(i)?Ou(n,i):Object.prototype.hasOwnProperty.call(e,t)||(e[t]=od(i))}const nA={"":t=>t,x:t=>t.x,y:t=>t.y};function yJ(t){const e=t.split("."),r=[];let n="";for(const i of e)n+=i,n.endsWith("\\")?n=n.slice(0,-1)+".":(r.push(n),n="");return r}function bJ(t){const e=yJ(t);return r=>{for(const n of e){if(n==="")break;r=r&&r[n]}return r}}function ud(t,e){return(nA[e]||(nA[e]=bJ(e)))(t)}function $b(t){return t.charAt(0).toUpperCase()+t.slice(1)}const Sn=t=>typeof t<"u",ln=t=>typeof t=="function",iA=(t,e)=>{if(t.size!==e.size)return!1;for(const r of t)if(!e.has(r))return!1;return!0};function _J(t){return t.type==="mouseup"||t.type==="click"||t.type==="contextmenu"}const Ht=Math.PI,Wn=2*Ht,xJ=Wn+Ht,ld=Number.POSITIVE_INFINITY,Ub=Ht/180,Gr=Ht/2,qn=Ht/4,cd=Ht*2/3,fP=Math.log10,po=Math.sign;function Au(t,e,r){return Math.abs(t-e)<r}function aA(t){const e=Math.round(t);t=Au(t,e,t/1e3)?e:t;const r=Math.pow(10,Math.floor(fP(t))),n=t/r;return(n<=1?1:n<=2?2:n<=5?5:10)*r}function wJ(t){const e=[],r=Math.sqrt(t);let n;for(n=1;n<r;n++)t%n===0&&(e.push(n),e.push(t/n));return r===(r|0)&&e.push(r),e.sort((i,a)=>i-a).pop(),e}function ps(t){return!isNaN(parseFloat(t))&&isFinite(t)}function TJ(t,e){const r=Math.round(t);return r-e<=t&&r+e>=t}function SJ(t,e,r){let n,i,a;for(n=0,i=t.length;n<i;n++)a=t[n][r],isNaN(a)||(e.min=Math.min(e.min,a),e.max=Math.max(e.max,a))}function jr(t){return t*(Ht/180)}function dP(t){return t*(180/Ht)}function sA(t){if(!Ir(t))return;let e=1,r=0;for(;Math.round(t*e)/e!==t;)e*=10,r++;return r}function CJ(t,e){const r=e.x-t.x,n=e.y-t.y,i=Math.sqrt(r*r+n*n);let a=Math.atan2(n,r);return a<-.5*Ht&&(a+=Wn),{angle:a,distance:i}}function go(t,e){return Math.sqrt(Math.pow(e.x-t.x,2)+Math.pow(e.y-t.y,2))}function EJ(t,e){return(t-e+xJ)%Wn-Ht}function fi(t){return(t%Wn+Wn)%Wn}function hP(t,e,r,n){const i=fi(t),a=fi(e),s=fi(r),o=fi(a-i),l=fi(s-i),c=fi(i-a),d=fi(i-s);return i===a||i===s||n&&a===s||o>l&&c<d}function Hn(t,e,r){return Math.max(e,Math.min(r,t))}function OJ(t){return Hn(t,-32768,32767)}function eo(t,e,r,n=1e-6){return t>=Math.min(e,r)-n&&t<=Math.max(e,r)+n}function qb(t,e,r){r=r||(s=>t[s]<e);let n=t.length-1,i=0,a;for(;n-i>1;)a=i+n>>1,r(a)?i=a:n=a;return{lo:i,hi:n}}const ns=(t,e,r,n)=>qb(t,r,n?i=>{const a=t[i][e];return a<r||a===r&&t[i+1][e]===r}:i=>t[i][e]<r),AJ=(t,e,r)=>qb(t,r,n=>t[n][e]>=r);function IJ(t,e,r){let n=0,i=t.length;for(;n<i&&t[n]<e;)n++;for(;i>n&&t[i-1]>r;)i--;return n>0||i<t.length?t.slice(n,i):t}const pP=["push","pop","shift","splice","unshift"];function RJ(t,e){if(t._chartjs){t._chartjs.listeners.push(e);return}Object.defineProperty(t,"_chartjs",{configurable:!0,enumerable:!1,value:{listeners:[e]}}),pP.forEach(r=>{const n="_onData"+$b(r),i=t[r];Object.defineProperty(t,r,{configurable:!0,enumerable:!1,value(...a){const s=i.apply(this,a);return t._chartjs.listeners.forEach(o=>{typeof o[n]=="function"&&o[n](...a)}),s}})})}function oA(t,e){const r=t._chartjs;if(!r)return;const n=r.listeners,i=n.indexOf(e);i!==-1&&n.splice(i,1),!(n.length>0)&&(pP.forEach(a=>{delete t[a]}),delete t._chartjs)}function DJ(t){const e=new Set(t);return e.size===t.length?t:Array.from(e)}const gP=(function(){return typeof window>"u"?function(t){return t()}:window.requestAnimationFrame})();function mP(t,e){let r=[],n=!1;return function(...i){r=i,n||(n=!0,gP.call(window,()=>{n=!1,t.apply(e,r)}))}}function MJ(t,e){let r;return function(...n){return e?(clearTimeout(r),r=setTimeout(t,e,n)):t.apply(this,n),e}}const vP=t=>t==="start"?"left":t==="end"?"right":"center",xn=(t,e,r)=>t==="start"?e:t==="end"?r:(e+r)/2,PJ=(t,e,r,n)=>t===(n?"left":"right")?r:t==="center"?(e+r)/2:e;function LJ(t,e,r){const n=e.length;let i=0,a=n;if(t._sorted){const{iScale:s,_parsed:o}=t,l=s.axis,{min:c,max:d,minDefined:h,maxDefined:g}=s.getUserBounds();h&&(i=Hn(Math.min(ns(o,l,c).lo,r?n:ns(e,l,s.getPixelForValue(c)).lo),0,n-1)),g?a=Hn(Math.max(ns(o,s.axis,d,!0).hi+1,r?0:ns(e,l,s.getPixelForValue(d),!0).hi+1),i,n)-i:a=n-i}return{start:i,count:a}}function NJ(t){const{xScale:e,yScale:r,_scaleRanges:n}=t,i={xmin:e.min,xmax:e.max,ymin:r.min,ymax:r.max};if(!n)return t._scaleRanges=i,!0;const a=n.xmin!==e.min||n.xmax!==e.max||n.ymin!==r.min||n.ymax!==r.max;return Object.assign(n,i),a}const tf=t=>t===0||t===1,uA=(t,e,r)=>-(Math.pow(2,10*(t-=1))*Math.sin((t-e)*Wn/r)),lA=(t,e,r)=>Math.pow(2,-10*t)*Math.sin((t-e)*Wn/r)+1,Iu={linear:t=>t,easeInQuad:t=>t*t,easeOutQuad:t=>-t*(t-2),easeInOutQuad:t=>(t/=.5)<1?.5*t*t:-.5*(--t*(t-2)-1),easeInCubic:t=>t*t*t,easeOutCubic:t=>(t-=1)*t*t+1,easeInOutCubic:t=>(t/=.5)<1?.5*t*t*t:.5*((t-=2)*t*t+2),easeInQuart:t=>t*t*t*t,easeOutQuart:t=>-((t-=1)*t*t*t-1),easeInOutQuart:t=>(t/=.5)<1?.5*t*t*t*t:-.5*((t-=2)*t*t*t-2),easeInQuint:t=>t*t*t*t*t,easeOutQuint:t=>(t-=1)*t*t*t*t+1,easeInOutQuint:t=>(t/=.5)<1?.5*t*t*t*t*t:.5*((t-=2)*t*t*t*t+2),easeInSine:t=>-Math.cos(t*Gr)+1,easeOutSine:t=>Math.sin(t*Gr),easeInOutSine:t=>-.5*(Math.cos(Ht*t)-1),easeInExpo:t=>t===0?0:Math.pow(2,10*(t-1)),easeOutExpo:t=>t===1?1:-Math.pow(2,-10*t)+1,easeInOutExpo:t=>tf(t)?t:t<.5?.5*Math.pow(2,10*(t*2-1)):.5*(-Math.pow(2,-10*(t*2-1))+2),easeInCirc:t=>t>=1?t:-(Math.sqrt(1-t*t)-1),easeOutCirc:t=>Math.sqrt(1-(t-=1)*t),easeInOutCirc:t=>(t/=.5)<1?-.5*(Math.sqrt(1-t*t)-1):.5*(Math.sqrt(1-(t-=2)*t)+1),easeInElastic:t=>tf(t)?t:uA(t,.075,.3),easeOutElastic:t=>tf(t)?t:lA(t,.075,.3),easeInOutElastic(t){return tf(t)?t:t<.5?.5*uA(t*2,.1125,.45):.5+.5*lA(t*2-1,.1125,.45)},easeInBack(t){return t*t*((1.70158+1)*t-1.70158)},easeOutBack(t){return(t-=1)*t*((1.70158+1)*t+1.70158)+1},easeInOutBack(t){let e=1.70158;return(t/=.5)<1?.5*(t*t*(((e*=1.525)+1)*t-e)):.5*((t-=2)*t*(((e*=1.525)+1)*t+e)+2)},easeInBounce:t=>1-Iu.easeOutBounce(1-t),easeOutBounce(t){return t<1/2.75?7.5625*t*t:t<2/2.75?7.5625*(t-=1.5/2.75)*t+.75:t<2.5/2.75?7.5625*(t-=2.25/2.75)*t+.9375:7.5625*(t-=2.625/2.75)*t+.984375},easeInOutBounce:t=>t<.5?Iu.easeInBounce(t*2)*.5:Iu.easeOutBounce(t*2-1)*.5+.5};function Hb(t){if(t&&typeof t=="object"){const e=t.toString();return e==="[object CanvasPattern]"||e==="[object CanvasGradient]"}return!1}function cA(t){return Hb(t)?t:new $u(t)}function py(t){return Hb(t)?t:new $u(t).saturate(.5).darken(.1).hexString()}const FJ=["x","y","borderWidth","radius","tension"],kJ=["color","borderColor","backgroundColor"];function jJ(t){t.set("animation",{delay:void 0,duration:1e3,easing:"easeOutQuart",fn:void 0,from:void 0,loop:void 0,to:void 0,type:void 0}),t.describe("animation",{_fallback:!1,_indexable:!1,_scriptable:e=>e!=="onProgress"&&e!=="onComplete"&&e!=="fn"}),t.set("animations",{colors:{type:"color",properties:kJ},numbers:{type:"number",properties:FJ}}),t.describe("animations",{_fallback:"animation"}),t.set("transitions",{active:{animation:{duration:400}},resize:{animation:{duration:0}},show:{animations:{colors:{from:"transparent"},visible:{type:"boolean",duration:0}}},hide:{animations:{colors:{to:"transparent"},visible:{type:"boolean",easing:"linear",fn:e=>e|0}}}})}function $J(t){t.set("layout",{autoPadding:!0,padding:{top:0,right:0,bottom:0,left:0}})}const fA=new Map;function UJ(t,e){e=e||{};const r=t+JSON.stringify(e);let n=fA.get(r);return n||(n=new Intl.NumberFormat(t,e),fA.set(r,n)),n}function yP(t,e,r){return UJ(e,r).format(t)}const qJ={values(t){return Xt(t)?t:""+t},numeric(t,e,r){if(t===0)return"0";const n=this.chart.options.locale;let i,a=t;if(r.length>1){const c=Math.max(Math.abs(r[0].value),Math.abs(r[r.length-1].value));(c<1e-4||c>1e15)&&(i="scientific"),a=HJ(t,r)}const s=fP(Math.abs(a)),o=isNaN(s)?1:Math.max(Math.min(-1*Math.floor(s),20),0),l={notation:i,minimumFractionDigits:o,maximumFractionDigits:o};return Object.assign(l,this.options.ticks.format),yP(t,n,l)}};function HJ(t,e){let r=e.length>3?e[2].value-e[1].value:e[1].value-e[0].value;return Math.abs(r)>=1&&t!==Math.floor(t)&&(r=t-Math.floor(t)),r}var bP={formatters:qJ};function WJ(t){t.set("scale",{display:!0,offset:!1,reverse:!1,beginAtZero:!1,bounds:"ticks",clip:!0,grace:0,grid:{display:!0,lineWidth:1,drawOnChartArea:!0,drawTicks:!0,tickLength:8,tickWidth:(e,r)=>r.lineWidth,tickColor:(e,r)=>r.color,offset:!1},border:{display:!0,dash:[],dashOffset:0,width:1},title:{display:!1,text:"",padding:{top:4,bottom:4}},ticks:{minRotation:0,maxRotation:50,mirror:!1,textStrokeWidth:0,textStrokeColor:"",padding:3,display:!0,autoSkip:!0,autoSkipPadding:3,labelOffset:0,callback:bP.formatters.values,minor:{},major:{},align:"center",crossAlign:"near",showLabelBackdrop:!1,backdropColor:"rgba(255, 255, 255, 0.75)",backdropPadding:2}}),t.route("scale.ticks","color","","color"),t.route("scale.grid","color","","borderColor"),t.route("scale.border","color","","borderColor"),t.route("scale.title","color","","color"),t.describe("scale",{_fallback:!1,_scriptable:e=>!e.startsWith("before")&&!e.startsWith("after")&&e!=="callback"&&e!=="parser",_indexable:e=>e!=="borderDash"&&e!=="tickBorderDash"&&e!=="dash"}),t.describe("scales",{_fallback:"scale"}),t.describe("scale.ticks",{_scriptable:e=>e!=="backdropPadding"&&e!=="callback",_indexable:e=>e!=="backdropPadding"})}const gs=Object.create(null),s0=Object.create(null);function Ru(t,e){if(!e)return t;const r=e.split(".");for(let n=0,i=r.length;n<i;++n){const a=r[n];t=t[a]||(t[a]=Object.create(null))}return t}function gy(t,e,r){return typeof e=="string"?Uu(Ru(t,e),r):Uu(Ru(t,""),e)}class BJ{constructor(e,r){this.animation=void 0,this.backgroundColor="rgba(0,0,0,0.1)",this.borderColor="rgba(0,0,0,0.1)",this.color="#666",this.datasets={},this.devicePixelRatio=n=>n.chart.platform.getDevicePixelRatio(),this.elements={},this.events=["mousemove","mouseout","click","touchstart","touchmove"],this.font={family:"'Helvetica Neue', 'Helvetica', 'Arial', sans-serif",size:12,style:"normal",lineHeight:1.2,weight:null},this.hover={},this.hoverBackgroundColor=(n,i)=>py(i.backgroundColor),this.hoverBorderColor=(n,i)=>py(i.borderColor),this.hoverColor=(n,i)=>py(i.color),this.indexAxis="x",this.interaction={mode:"nearest",intersect:!0,includeInvisible:!1},this.maintainAspectRatio=!0,this.onHover=null,this.onClick=null,this.parsing=!0,this.plugins={},this.responsive=!0,this.scale=void 0,this.scales={},this.showLine=!0,this.drawActiveElementsOnTop=!0,this.describe(e),this.apply(r)}set(e,r){return gy(this,e,r)}get(e){return Ru(this,e)}describe(e,r){return gy(s0,e,r)}override(e,r){return gy(gs,e,r)}route(e,r,n,i){const a=Ru(this,e),s=Ru(this,n),o="_"+r;Object.defineProperties(a,{[o]:{value:a[r],writable:!0},[r]:{enumerable:!0,get(){const l=this[o],c=s[i];return it(l)?Object.assign({},c,l):Xe(l,c)},set(l){this[o]=l}}})}apply(e){e.forEach(r=>r(this))}}var lr=new BJ({_scriptable:t=>!t.startsWith("on"),_indexable:t=>t!=="events",hover:{_fallback:"interaction"},interaction:{_scriptable:!1,_indexable:!1}},[jJ,$J,WJ]);function zJ(t){return!t||ur(t.size)||ur(t.family)?null:(t.style?t.style+" ":"")+(t.weight?t.weight+" ":"")+t.size+"px "+t.family}function dA(t,e,r,n,i){let a=e[i];return a||(a=e[i]=t.measureText(i).width,r.push(i)),a>n&&(n=a),n}function Ba(t,e,r){const n=t.currentDevicePixelRatio,i=r!==0?Math.max(r/2,.5):0;return Math.round((e-i)*n)/n+i}function hA(t,e){e=e||t.getContext("2d"),e.save(),e.resetTransform(),e.clearRect(0,0,t.width,t.height),e.restore()}function o0(t,e,r,n){_P(t,e,r,n,null)}function _P(t,e,r,n,i){let a,s,o,l,c,d,h,g;const m=e.pointStyle,v=e.rotation,b=e.radius;let y=(v||0)*Ub;if(m&&typeof m=="object"&&(a=m.toString(),a==="[object HTMLImageElement]"||a==="[object HTMLCanvasElement]")){t.save(),t.translate(r,n),t.rotate(y),t.drawImage(m,-m.width/2,-m.height/2,m.width,m.height),t.restore();return}if(!(isNaN(b)||b<=0)){switch(t.beginPath(),m){default:i?t.ellipse(r,n,i/2,b,0,0,Wn):t.arc(r,n,b,0,Wn),t.closePath();break;case"triangle":d=i?i/2:b,t.moveTo(r+Math.sin(y)*d,n-Math.cos(y)*b),y+=cd,t.lineTo(r+Math.sin(y)*d,n-Math.cos(y)*b),y+=cd,t.lineTo(r+Math.sin(y)*d,n-Math.cos(y)*b),t.closePath();break;case"rectRounded":c=b*.516,l=b-c,s=Math.cos(y+qn)*l,h=Math.cos(y+qn)*(i?i/2-c:l),o=Math.sin(y+qn)*l,g=Math.sin(y+qn)*(i?i/2-c:l),t.arc(r-h,n-o,c,y-Ht,y-Gr),t.arc(r+g,n-s,c,y-Gr,y),t.arc(r+h,n+o,c,y,y+Gr),t.arc(r-g,n+s,c,y+Gr,y+Ht),t.closePath();break;case"rect":if(!v){l=Math.SQRT1_2*b,d=i?i/2:l,t.rect(r-d,n-l,2*d,2*l);break}y+=qn;case"rectRot":h=Math.cos(y)*(i?i/2:b),s=Math.cos(y)*b,o=Math.sin(y)*b,g=Math.sin(y)*(i?i/2:b),t.moveTo(r-h,n-o),t.lineTo(r+g,n-s),t.lineTo(r+h,n+o),t.lineTo(r-g,n+s),t.closePath();break;case"crossRot":y+=qn;case"cross":h=Math.cos(y)*(i?i/2:b),s=Math.cos(y)*b,o=Math.sin(y)*b,g=Math.sin(y)*(i?i/2:b),t.moveTo(r-h,n-o),t.lineTo(r+h,n+o),t.moveTo(r+g,n-s),t.lineTo(r-g,n+s);break;case"star":h=Math.cos(y)*(i?i/2:b),s=Math.cos(y)*b,o=Math.sin(y)*b,g=Math.sin(y)*(i?i/2:b),t.moveTo(r-h,n-o),t.lineTo(r+h,n+o),t.moveTo(r+g,n-s),t.lineTo(r-g,n+s),y+=qn,h=Math.cos(y)*(i?i/2:b),s=Math.cos(y)*b,o=Math.sin(y)*b,g=Math.sin(y)*(i?i/2:b),t.moveTo(r-h,n-o),t.lineTo(r+h,n+o),t.moveTo(r+g,n-s),t.lineTo(r-g,n+s);break;case"line":s=i?i/2:Math.cos(y)*b,o=Math.sin(y)*b,t.moveTo(r-s,n-o),t.lineTo(r+s,n+o);break;case"dash":t.moveTo(r,n),t.lineTo(r+Math.cos(y)*(i?i/2:b),n+Math.sin(y)*b);break;case!1:t.closePath();break}t.fill(),e.borderWidth>0&&t.stroke()}}function qu(t,e,r){return r=r||.5,!e||t&&t.x>e.left-r&&t.x<e.right+r&&t.y>e.top-r&&t.y<e.bottom+r}function nl(t,e){t.save(),t.beginPath(),t.rect(e.left,e.top,e.right-e.left,e.bottom-e.top),t.clip()}function il(t){t.restore()}function VJ(t,e,r,n,i){if(!e)return t.lineTo(r.x,r.y);if(i==="middle"){const a=(e.x+r.x)/2;t.lineTo(a,e.y),t.lineTo(a,r.y)}else i==="after"!=!!n?t.lineTo(e.x,r.y):t.lineTo(r.x,e.y);t.lineTo(r.x,r.y)}function GJ(t,e,r,n){if(!e)return t.lineTo(r.x,r.y);t.bezierCurveTo(n?e.cp1x:e.cp2x,n?e.cp1y:e.cp2y,n?r.cp2x:r.cp1x,n?r.cp2y:r.cp1y,r.x,r.y)}function KJ(t,e){e.translation&&t.translate(e.translation[0],e.translation[1]),ur(e.rotation)||t.rotate(e.rotation),e.color&&(t.fillStyle=e.color),e.textAlign&&(t.textAlign=e.textAlign),e.textBaseline&&(t.textBaseline=e.textBaseline)}function XJ(t,e,r,n,i){if(i.strikethrough||i.underline){const a=t.measureText(n),s=e-a.actualBoundingBoxLeft,o=e+a.actualBoundingBoxRight,l=r-a.actualBoundingBoxAscent,c=r+a.actualBoundingBoxDescent,d=i.strikethrough?(l+c)/2:c;t.strokeStyle=t.fillStyle,t.beginPath(),t.lineWidth=i.decorationWidth||2,t.moveTo(s,d),t.lineTo(o,d),t.stroke()}}function YJ(t,e){const r=t.fillStyle;t.fillStyle=e.color,t.fillRect(e.left,e.top,e.width,e.height),t.fillStyle=r}function fd(t,e,r,n,i,a={}){const s=Xt(e)?e:[e],o=a.strokeWidth>0&&a.strokeColor!=="";let l,c;for(t.save(),t.font=i.string,KJ(t,a),l=0;l<s.length;++l)c=s[l],a.backdrop&&YJ(t,a.backdrop),o&&(a.strokeColor&&(t.strokeStyle=a.strokeColor),ur(a.strokeWidth)||(t.lineWidth=a.strokeWidth),t.strokeText(c,r,n,a.maxWidth)),t.fillText(c,r,n,a.maxWidth),XJ(t,r,n,c,a),n+=Number(i.lineHeight);t.restore()}function dd(t,e){const{x:r,y:n,w:i,h:a,radius:s}=e;t.arc(r+s.topLeft,n+s.topLeft,s.topLeft,1.5*Ht,Ht,!0),t.lineTo(r,n+a-s.bottomLeft),t.arc(r+s.bottomLeft,n+a-s.bottomLeft,s.bottomLeft,Ht,Gr,!0),t.lineTo(r+i-s.bottomRight,n+a),t.arc(r+i-s.bottomRight,n+a-s.bottomRight,s.bottomRight,Gr,0,!0),t.lineTo(r+i,n+s.topRight),t.arc(r+i-s.topRight,n+s.topRight,s.topRight,0,-Gr,!0),t.lineTo(r+s.topLeft,n)}const ZJ=/^(normal|(\d+(?:\.\d+)?)(px|em|%)?)$/,JJ=/^(normal|italic|initial|inherit|unset|(oblique( -?[0-9]?[0-9]deg)?))$/;function QJ(t,e){const r=(""+t).match(ZJ);if(!r||r[1]==="normal")return e*1.2;switch(t=+r[2],r[3]){case"px":return t;case"%":t/=100;break}return e*t}const eQ=t=>+t||0;function xP(t,e){const r={},n=it(e),i=n?Object.keys(e):e,a=it(t)?n?s=>Xe(t[s],t[e[s]]):s=>t[s]:()=>t;for(const s of i)r[s]=eQ(a(s));return r}function tQ(t){return xP(t,{top:"y",right:"x",bottom:"y",left:"x"})}function no(t){return xP(t,["topLeft","topRight","bottomLeft","bottomRight"])}function Kr(t){const e=tQ(t);return e.width=e.left+e.right,e.height=e.top+e.bottom,e}function Or(t,e){t=t||{},e=e||lr.font;let r=Xe(t.size,e.size);typeof r=="string"&&(r=parseInt(r,10));let n=Xe(t.style,e.style);n&&!(""+n).match(JJ)&&(console.warn('Invalid font style specified: "'+n+'"'),n=void 0);const i={family:Xe(t.family,e.family),lineHeight:QJ(Xe(t.lineHeight,e.lineHeight),r),size:r,style:n,weight:Xe(t.weight,e.weight),string:""};return i.string=zJ(i),i}function rf(t,e,r,n){let i,a,s;for(i=0,a=t.length;i<a;++i)if(s=t[i],s!==void 0&&s!==void 0)return s}function rQ(t,e,r){const{min:n,max:i}=t,a=gJ(e,(i-n)/2),s=(o,l)=>r&&o===0?0:o+l;return{min:s(n,-Math.abs(a)),max:s(i,a)}}function Ss(t,e){return Object.assign(Object.create(t),e)}function Wb(t,e=[""],r,n,i=()=>t[0]){const a=r||t;typeof n>"u"&&(n=CP("_fallback",t));const s={[Symbol.toStringTag]:"Object",_cacheable:!0,_scopes:t,_rootScopes:a,_fallback:n,_getTarget:i,override:o=>Wb([o,...t],e,a,n)};return new Proxy(s,{deleteProperty(o,l){return delete o[l],delete o._keys,delete t[0][l],!0},get(o,l){return TP(o,l,()=>cQ(l,e,t,o))},getOwnPropertyDescriptor(o,l){return Reflect.getOwnPropertyDescriptor(o._scopes[0],l)},getPrototypeOf(){return Reflect.getPrototypeOf(t[0])},has(o,l){return gA(o).includes(l)},ownKeys(o){return gA(o)},set(o,l,c){const d=o._storage||(o._storage=i());return o[l]=d[l]=c,delete o._keys,!0}})}function mo(t,e,r,n){const i={_cacheable:!1,_proxy:t,_context:e,_subProxy:r,_stack:new Set,_descriptors:wP(t,n),setContext:a=>mo(t,a,r,n),override:a=>mo(t.override(a),e,r,n)};return new Proxy(i,{deleteProperty(a,s){return delete a[s],delete t[s],!0},get(a,s,o){return TP(a,s,()=>iQ(a,s,o))},getOwnPropertyDescriptor(a,s){return a._descriptors.allKeys?Reflect.has(t,s)?{enumerable:!0,configurable:!0}:void 0:Reflect.getOwnPropertyDescriptor(t,s)},getPrototypeOf(){return Reflect.getPrototypeOf(t)},has(a,s){return Reflect.has(t,s)},ownKeys(){return Reflect.ownKeys(t)},set(a,s,o){return t[s]=o,delete a[s],!0}})}function wP(t,e={scriptable:!0,indexable:!0}){const{_scriptable:r=e.scriptable,_indexable:n=e.indexable,_allKeys:i=e.allKeys}=t;return{allKeys:i,scriptable:r,indexable:n,isScriptable:ln(r)?r:()=>r,isIndexable:ln(n)?n:()=>n}}const nQ=(t,e)=>t?t+$b(e):e,Bb=(t,e)=>it(e)&&t!=="adapters"&&(Object.getPrototypeOf(e)===null||e.constructor===Object);function TP(t,e,r){if(Object.prototype.hasOwnProperty.call(t,e))return t[e];const n=r();return t[e]=n,n}function iQ(t,e,r){const{_proxy:n,_context:i,_subProxy:a,_descriptors:s}=t;let o=n[e];return ln(o)&&s.isScriptable(e)&&(o=aQ(e,o,t,r)),Xt(o)&&o.length&&(o=sQ(e,o,t,s.isIndexable)),Bb(e,o)&&(o=mo(o,i,a&&a[e],s)),o}function aQ(t,e,r,n){const{_proxy:i,_context:a,_subProxy:s,_stack:o}=r;if(o.has(t))throw new Error("Recursion detected: "+Array.from(o).join("->")+"->"+t);o.add(t);let l=e(a,s||n);return o.delete(t),Bb(t,l)&&(l=zb(i._scopes,i,t,l)),l}function sQ(t,e,r,n){const{_proxy:i,_context:a,_subProxy:s,_descriptors:o}=r;if(typeof a.index<"u"&&n(t))return e[a.index%e.length];if(it(e[0])){const l=e,c=i._scopes.filter(d=>d!==l);e=[];for(const d of l){const h=zb(c,i,t,d);e.push(mo(h,a,s&&s[t],o))}}return e}function SP(t,e,r){return ln(t)?t(e,r):t}const oQ=(t,e)=>t===!0?e:typeof t=="string"?ud(e,t):void 0;function uQ(t,e,r,n,i){for(const a of e){const s=oQ(r,a);if(s){t.add(s);const o=SP(s._fallback,r,i);if(typeof o<"u"&&o!==r&&o!==n)return o}else if(s===!1&&typeof n<"u"&&r!==n)return null}return!1}function zb(t,e,r,n){const i=e._rootScopes,a=SP(e._fallback,r,n),s=[...t,...i],o=new Set;o.add(n);let l=pA(o,s,r,a||r,n);return l===null||typeof a<"u"&&a!==r&&(l=pA(o,s,a,l,n),l===null)?!1:Wb(Array.from(o),[""],i,a,()=>lQ(e,r,n))}function pA(t,e,r,n,i){for(;r;)r=uQ(t,e,r,n,i);return r}function lQ(t,e,r){const n=t._getTarget();e in n||(n[e]={});const i=n[e];return Xt(i)&&it(r)?r:i||{}}function cQ(t,e,r,n){let i;for(const a of e)if(i=CP(nQ(a,t),r),typeof i<"u")return Bb(t,i)?zb(r,n,t,i):i}function CP(t,e){for(const r of e){if(!r)continue;const n=r[t];if(typeof n<"u")return n}}function gA(t){let e=t._keys;return e||(e=t._keys=fQ(t._scopes)),e}function fQ(t){const e=new Set;for(const r of t)for(const n of Object.keys(r).filter(i=>!i.startsWith("_")))e.add(n);return Array.from(e)}const dQ=Number.EPSILON||1e-14,vo=(t,e)=>e<t.length&&!t[e].skip&&t[e],EP=t=>t==="x"?"y":"x";function hQ(t,e,r,n){const i=t.skip?e:t,a=e,s=r.skip?e:r,o=go(a,i),l=go(s,a);let c=o/(o+l),d=l/(o+l);c=isNaN(c)?0:c,d=isNaN(d)?0:d;const h=n*c,g=n*d;return{previous:{x:a.x-h*(s.x-i.x),y:a.y-h*(s.y-i.y)},next:{x:a.x+g*(s.x-i.x),y:a.y+g*(s.y-i.y)}}}function pQ(t,e,r){const n=t.length;let i,a,s,o,l,c=vo(t,0);for(let d=0;d<n-1;++d)if(l=c,c=vo(t,d+1),!(!l||!c)){if(Au(e[d],0,dQ)){r[d]=r[d+1]=0;continue}i=r[d]/e[d],a=r[d+1]/e[d],o=Math.pow(i,2)+Math.pow(a,2),!(o<=9)&&(s=3/Math.sqrt(o),r[d]=i*s*e[d],r[d+1]=a*s*e[d])}}function gQ(t,e,r="x"){const n=EP(r),i=t.length;let a,s,o,l=vo(t,0);for(let c=0;c<i;++c){if(s=o,o=l,l=vo(t,c+1),!o)continue;const d=o[r],h=o[n];s&&(a=(d-s[r])/3,o[`cp1${r}`]=d-a,o[`cp1${n}`]=h-a*e[c]),l&&(a=(l[r]-d)/3,o[`cp2${r}`]=d+a,o[`cp2${n}`]=h+a*e[c])}}function mQ(t,e="x"){const r=EP(e),n=t.length,i=Array(n).fill(0),a=Array(n);let s,o,l,c=vo(t,0);for(s=0;s<n;++s)if(o=l,l=c,c=vo(t,s+1),!!l){if(c){const d=c[e]-l[e];i[s]=d!==0?(c[r]-l[r])/d:0}a[s]=o?c?po(i[s-1])!==po(i[s])?0:(i[s-1]+i[s])/2:i[s-1]:i[s]}pQ(t,i,a),gQ(t,a,e)}function nf(t,e,r){return Math.max(Math.min(t,r),e)}function vQ(t,e){let r,n,i,a,s,o=qu(t[0],e);for(r=0,n=t.length;r<n;++r)s=a,a=o,o=r<n-1&&qu(t[r+1],e),a&&(i=t[r],s&&(i.cp1x=nf(i.cp1x,e.left,e.right),i.cp1y=nf(i.cp1y,e.top,e.bottom)),o&&(i.cp2x=nf(i.cp2x,e.left,e.right),i.cp2y=nf(i.cp2y,e.top,e.bottom)))}function yQ(t,e,r,n,i){let a,s,o,l;if(e.spanGaps&&(t=t.filter(c=>!c.skip)),e.cubicInterpolationMode==="monotone")mQ(t,i);else{let c=n?t[t.length-1]:t[0];for(a=0,s=t.length;a<s;++a)o=t[a],l=hQ(c,o,t[Math.min(a+1,s-(n?0:1))%s],e.tension),o.cp1x=l.previous.x,o.cp1y=l.previous.y,o.cp2x=l.next.x,o.cp2y=l.next.y,c=o}e.capBezierPoints&&vQ(t,r)}function OP(){return typeof window<"u"&&typeof document<"u"}function Vb(t){let e=t.parentNode;return e&&e.toString()==="[object ShadowRoot]"&&(e=e.host),e}function hd(t,e,r){let n;return typeof t=="string"?(n=parseInt(t,10),t.indexOf("%")!==-1&&(n=n/100*e.parentNode[r])):n=t,n}const Zd=t=>t.ownerDocument.defaultView.getComputedStyle(t,null);function bQ(t,e){return Zd(t).getPropertyValue(e)}const _Q=["top","right","bottom","left"];function os(t,e,r){const n={};r=r?"-"+r:"";for(let i=0;i<4;i++){const a=_Q[i];n[a]=parseFloat(t[e+"-"+a+r])||0}return n.width=n.left+n.right,n.height=n.top+n.bottom,n}const xQ=(t,e,r)=>(t>0||e>0)&&(!r||!r.shadowRoot);function wQ(t,e){const r=t.touches,n=r&&r.length?r[0]:t,{offsetX:i,offsetY:a}=n;let s=!1,o,l;if(xQ(i,a,t.target))o=i,l=a;else{const c=e.getBoundingClientRect();o=n.clientX-c.left,l=n.clientY-c.top,s=!0}return{x:o,y:l,box:s}}function Ya(t,e){if("native"in t)return t;const{canvas:r,currentDevicePixelRatio:n}=e,i=Zd(r),a=i.boxSizing==="border-box",s=os(i,"padding"),o=os(i,"border","width"),{x:l,y:c,box:d}=wQ(t,r),h=s.left+(d&&o.left),g=s.top+(d&&o.top);let{width:m,height:v}=e;return a&&(m-=s.width+o.width,v-=s.height+o.height),{x:Math.round((l-h)/m*r.width/n),y:Math.round((c-g)/v*r.height/n)}}function TQ(t,e,r){let n,i;if(e===void 0||r===void 0){const a=Vb(t);if(!a)e=t.clientWidth,r=t.clientHeight;else{const s=a.getBoundingClientRect(),o=Zd(a),l=os(o,"border","width"),c=os(o,"padding");e=s.width-c.width-l.width,r=s.height-c.height-l.height,n=hd(o.maxWidth,a,"clientWidth"),i=hd(o.maxHeight,a,"clientHeight")}}return{width:e,height:r,maxWidth:n||ld,maxHeight:i||ld}}const af=t=>Math.round(t*10)/10;function SQ(t,e,r,n){const i=Zd(t),a=os(i,"margin"),s=hd(i.maxWidth,t,"clientWidth")||ld,o=hd(i.maxHeight,t,"clientHeight")||ld,l=TQ(t,e,r);let{width:c,height:d}=l;if(i.boxSizing==="content-box"){const g=os(i,"border","width"),m=os(i,"padding");c-=m.width+g.width,d-=m.height+g.height}return c=Math.max(0,c-a.width),d=Math.max(0,n?c/n:d-a.height),c=af(Math.min(c,s,l.maxWidth)),d=af(Math.min(d,o,l.maxHeight)),c&&!d&&(d=af(c/2)),(e!==void 0||r!==void 0)&&n&&l.height&&d>l.height&&(d=l.height,c=af(Math.floor(d*n))),{width:c,height:d}}function mA(t,e,r){const n=e||1,i=Math.floor(t.height*n),a=Math.floor(t.width*n);t.height=Math.floor(t.height),t.width=Math.floor(t.width);const s=t.canvas;return s.style&&(r||!s.style.height&&!s.style.width)&&(s.style.height=`${t.height}px`,s.style.width=`${t.width}px`),t.currentDevicePixelRatio!==n||s.height!==i||s.width!==a?(t.currentDevicePixelRatio=n,s.height=i,s.width=a,t.ctx.setTransform(n,0,0,n,0,0),!0):!1}const CQ=(function(){let t=!1;try{const e={get passive(){return t=!0,!1}};window.addEventListener("test",null,e),window.removeEventListener("test",null,e)}catch{}return t})();function vA(t,e){const r=bQ(t,e),n=r&&r.match(/^(\d+)(\.\d+)?px$/);return n?+n[1]:void 0}function Za(t,e,r,n){return{x:t.x+r*(e.x-t.x),y:t.y+r*(e.y-t.y)}}function EQ(t,e,r,n){return{x:t.x+r*(e.x-t.x),y:n==="middle"?r<.5?t.y:e.y:n==="after"?r<1?t.y:e.y:r>0?e.y:t.y}}function OQ(t,e,r,n){const i={x:t.cp2x,y:t.cp2y},a={x:e.cp1x,y:e.cp1y},s=Za(t,i,r),o=Za(i,a,r),l=Za(a,e,r),c=Za(s,o,r),d=Za(o,l,r);return Za(c,d,r)}const AQ=function(t,e){return{x(r){return t+t+e-r},setWidth(r){e=r},textAlign(r){return r==="center"?r:r==="right"?"left":"right"},xPlus(r,n){return r-n},leftForLtr(r,n){return r-n}}},IQ=function(){return{x(t){return t},setWidth(t){},textAlign(t){return t},xPlus(t,e){return t+e},leftForLtr(t,e){return t}}};function io(t,e,r){return t?AQ(e,r):IQ()}function AP(t,e){let r,n;(e==="ltr"||e==="rtl")&&(r=t.canvas.style,n=[r.getPropertyValue("direction"),r.getPropertyPriority("direction")],r.setProperty("direction",e,"important"),t.prevTextDirection=n)}function IP(t,e){e!==void 0&&(delete t.prevTextDirection,t.canvas.style.setProperty("direction",e[0],e[1]))}function RP(t){return t==="angle"?{between:hP,compare:EJ,normalize:fi}:{between:eo,compare:(e,r)=>e-r,normalize:e=>e}}function yA({start:t,end:e,count:r,loop:n,style:i}){return{start:t%r,end:e%r,loop:n&&(e-t+1)%r===0,style:i}}function RQ(t,e,r){const{property:n,start:i,end:a}=r,{between:s,normalize:o}=RP(n),l=e.length;let{start:c,end:d,loop:h}=t,g,m;if(h){for(c+=l,d+=l,g=0,m=l;g<m&&s(o(e[c%l][n]),i,a);++g)c--,d--;c%=l,d%=l}return d<c&&(d+=l),{start:c,end:d,loop:h,style:t.style}}function DP(t,e,r){if(!r)return[t];const{property:n,start:i,end:a}=r,s=e.length,{compare:o,between:l,normalize:c}=RP(n),{start:d,end:h,loop:g,style:m}=RQ(t,e,r),v=[];let b=!1,y=null,x,w,S;const E=()=>l(i,S,x)&&o(i,S)!==0,C=()=>o(a,x)===0||l(a,S,x),I=()=>b||E(),T=()=>!b||C();for(let D=d,P=d;D<=h;++D)w=e[D%s],!w.skip&&(x=c(w[n]),x!==S&&(b=l(x,i,a),y===null&&I()&&(y=o(x,i)===0?D:P),y!==null&&T()&&(v.push(yA({start:y,end:D,loop:g,count:s,style:m})),y=null),P=D,S=x));return y!==null&&v.push(yA({start:y,end:h,loop:g,count:s,style:m})),v}function MP(t,e){const r=[],n=t.segments;for(let i=0;i<n.length;i++){const a=DP(n[i],t.points,e);a.length&&r.push(...a)}return r}function DQ(t,e,r,n){let i=0,a=e-1;if(r&&!n)for(;i<e&&!t[i].skip;)i++;for(;i<e&&t[i].skip;)i++;for(i%=e,r&&(a+=i);a>i&&t[a%e].skip;)a--;return a%=e,{start:i,end:a}}function MQ(t,e,r,n){const i=t.length,a=[];let s=e,o=t[e],l;for(l=e+1;l<=r;++l){const c=t[l%i];c.skip||c.stop?o.skip||(n=!1,a.push({start:e%i,end:(l-1)%i,loop:n}),e=s=c.stop?l:null):(s=l,o.skip&&(e=l)),o=c}return s!==null&&a.push({start:e%i,end:s%i,loop:n}),a}function PQ(t,e){const r=t.points,n=t.options.spanGaps,i=r.length;if(!i)return[];const a=!!t._loop,{start:s,end:o}=DQ(r,i,a,n);if(n===!0)return bA(t,[{start:s,end:o,loop:a}],r,e);const l=o<s?o+i:o,c=!!t._fullLoop&&s===0&&o===i-1;return bA(t,MQ(r,s,l,c),r,e)}function bA(t,e,r,n){return!n||!n.setContext||!r?e:LQ(t,e,r,n)}function LQ(t,e,r,n){const i=t._chart.getContext(),a=_A(t.options),{_datasetIndex:s,options:{spanGaps:o}}=t,l=r.length,c=[];let d=a,h=e[0].start,g=h;function m(v,b,y,x){const w=o?-1:1;if(v!==b){for(v+=l;r[v%l].skip;)v-=w;for(;r[b%l].skip;)b+=w;v%l!==b%l&&(c.push({start:v%l,end:b%l,loop:y,style:x}),d=x,h=b%l)}}for(const v of e){h=o?h:v.start;let b=r[h%l],y;for(g=h+1;g<=v.end;g++){const x=r[g%l];y=_A(n.setContext(Ss(i,{type:"segment",p0:b,p1:x,p0DataIndex:(g-1)%l,p1DataIndex:g%l,datasetIndex:s}))),NQ(y,d)&&m(h,g-1,v.loop,d),b=x,d=y}h<g-1&&m(h,g-1,v.loop,d)}return c}function _A(t){return{backgroundColor:t.backgroundColor,borderCapStyle:t.borderCapStyle,borderDash:t.borderDash,borderDashOffset:t.borderDashOffset,borderJoinStyle:t.borderJoinStyle,borderWidth:t.borderWidth,borderColor:t.borderColor}}function NQ(t,e){if(!e)return!1;const r=[],n=function(i,a){return Hb(a)?(r.includes(a)||r.push(a),r.indexOf(a)):a};return JSON.stringify(t,n)!==JSON.stringify(e,n)}/*!
|
|
107
|
+
* Chart.js v4.4.0
|
|
108
|
+
* https://www.chartjs.org
|
|
109
|
+
* (c) 2023 Chart.js Contributors
|
|
110
|
+
* Released under the MIT License
|
|
111
|
+
*/class FQ{constructor(){this._request=null,this._charts=new Map,this._running=!1,this._lastDate=void 0}_notify(e,r,n,i){const a=r.listeners[i],s=r.duration;a.forEach(o=>o({chart:e,initial:r.initial,numSteps:s,currentStep:Math.min(n-r.start,s)}))}_refresh(){this._request||(this._running=!0,this._request=gP.call(window,()=>{this._update(),this._request=null,this._running&&this._refresh()}))}_update(e=Date.now()){let r=0;this._charts.forEach((n,i)=>{if(!n.running||!n.items.length)return;const a=n.items;let s=a.length-1,o=!1,l;for(;s>=0;--s)l=a[s],l._active?(l._total>n.duration&&(n.duration=l._total),l.tick(e),o=!0):(a[s]=a[a.length-1],a.pop());o&&(i.draw(),this._notify(i,n,e,"progress")),a.length||(n.running=!1,this._notify(i,n,e,"complete"),n.initial=!1),r+=a.length}),this._lastDate=e,r===0&&(this._running=!1)}_getAnims(e){const r=this._charts;let n=r.get(e);return n||(n={running:!1,initial:!0,items:[],listeners:{complete:[],progress:[]}},r.set(e,n)),n}listen(e,r,n){this._getAnims(e).listeners[r].push(n)}add(e,r){!r||!r.length||this._getAnims(e).items.push(...r)}has(e){return this._getAnims(e).items.length>0}start(e){const r=this._charts.get(e);r&&(r.running=!0,r.start=Date.now(),r.duration=r.items.reduce((n,i)=>Math.max(n,i._duration),0),this._refresh())}running(e){if(!this._running)return!1;const r=this._charts.get(e);return!(!r||!r.running||!r.items.length)}stop(e){const r=this._charts.get(e);if(!r||!r.items.length)return;const n=r.items;let i=n.length-1;for(;i>=0;--i)n[i].cancel();r.items=[],this._notify(e,r,Date.now(),"complete")}remove(e){return this._charts.delete(e)}}var Pi=new FQ;const xA="transparent",kQ={boolean(t,e,r){return r>.5?e:t},color(t,e,r){const n=cA(t||xA),i=n.valid&&cA(e||xA);return i&&i.valid?i.mix(n,r).hexString():e},number(t,e,r){return t+(e-t)*r}};class jQ{constructor(e,r,n,i){const a=r[n];i=rf([e.to,i,a,e.from]);const s=rf([e.from,a,i]);this._active=!0,this._fn=e.fn||kQ[e.type||typeof s],this._easing=Iu[e.easing]||Iu.linear,this._start=Math.floor(Date.now()+(e.delay||0)),this._duration=this._total=Math.floor(e.duration),this._loop=!!e.loop,this._target=r,this._prop=n,this._from=s,this._to=i,this._promises=void 0}active(){return this._active}update(e,r,n){if(this._active){this._notify(!1);const i=this._target[this._prop],a=n-this._start,s=this._duration-a;this._start=n,this._duration=Math.floor(Math.max(s,e.duration)),this._total+=a,this._loop=!!e.loop,this._to=rf([e.to,r,i,e.from]),this._from=rf([e.from,i,r])}}cancel(){this._active&&(this.tick(Date.now()),this._active=!1,this._notify(!1))}tick(e){const r=e-this._start,n=this._duration,i=this._prop,a=this._from,s=this._loop,o=this._to;let l;if(this._active=a!==o&&(s||r<n),!this._active){this._target[i]=o,this._notify(!0);return}if(r<0){this._target[i]=a;return}l=r/n%2,l=s&&l>1?2-l:l,l=this._easing(Math.min(1,Math.max(0,l))),this._target[i]=this._fn(a,o,l)}wait(){const e=this._promises||(this._promises=[]);return new Promise((r,n)=>{e.push({res:r,rej:n})})}_notify(e){const r=e?"res":"rej",n=this._promises||[];for(let i=0;i<n.length;i++)n[i][r]()}}class Gb{constructor(e,r){this._chart=e,this._properties=new Map,this.configure(r)}configure(e){if(!it(e))return;const r=Object.keys(lr.animation),n=this._properties;Object.getOwnPropertyNames(e).forEach(i=>{const a=e[i];if(!it(a))return;const s={};for(const o of r)s[o]=a[o];(Xt(a.properties)&&a.properties||[i]).forEach(o=>{(o===i||!n.has(o))&&n.set(o,s)})})}_animateOptions(e,r){const n=r.options,i=UQ(e,n);if(!i)return[];const a=this._createAnimations(i,n);return n.$shared&&$Q(e.options.$animations,n).then(()=>{e.options=n},()=>{}),a}_createAnimations(e,r){const n=this._properties,i=[],a=e.$animations||(e.$animations={}),s=Object.keys(r),o=Date.now();let l;for(l=s.length-1;l>=0;--l){const c=s[l];if(c.charAt(0)==="$")continue;if(c==="options"){i.push(...this._animateOptions(e,r));continue}const d=r[c];let h=a[c];const g=n.get(c);if(h)if(g&&h.active()){h.update(g,d,o);continue}else h.cancel();if(!g||!g.duration){e[c]=d;continue}a[c]=h=new jQ(g,e,c,d),i.push(h)}return i}update(e,r){if(this._properties.size===0){Object.assign(e,r);return}const n=this._createAnimations(e,r);if(n.length)return Pi.add(this._chart,n),!0}}function $Q(t,e){const r=[],n=Object.keys(e);for(let i=0;i<n.length;i++){const a=t[n[i]];a&&a.active()&&r.push(a.wait())}return Promise.all(r)}function UQ(t,e){if(!e)return;let r=t.options;if(!r){t.options=e;return}return r.$shared&&(t.options=r=Object.assign({},r,{$shared:!1,$animations:{}})),r}function wA(t,e){const r=t&&t.options||{},n=r.reverse,i=r.min===void 0?e:0,a=r.max===void 0?e:0;return{start:n?a:i,end:n?i:a}}function qQ(t,e,r){if(r===!1)return!1;const n=wA(t,r),i=wA(e,r);return{top:i.end,right:n.end,bottom:i.start,left:n.start}}function HQ(t){let e,r,n,i;return it(t)?(e=t.top,r=t.right,n=t.bottom,i=t.left):e=r=n=i=t,{top:e,right:r,bottom:n,left:i,disabled:t===!1}}function PP(t,e){const r=[],n=t._getSortedDatasetMetas(e);let i,a;for(i=0,a=n.length;i<a;++i)r.push(n[i].index);return r}function TA(t,e,r,n={}){const i=t.keys,a=n.mode==="single";let s,o,l,c;if(e!==null){for(s=0,o=i.length;s<o;++s){if(l=+i[s],l===r){if(n.all)continue;break}c=t.values[l],Ir(c)&&(a||e===0||po(e)===po(c))&&(e+=c)}return e}}function WQ(t){const e=Object.keys(t),r=new Array(e.length);let n,i,a;for(n=0,i=e.length;n<i;++n)a=e[n],r[n]={x:a,y:t[a]};return r}function SA(t,e){const r=t&&t.options.stacked;return r||r===void 0&&e.stack!==void 0}function BQ(t,e,r){return`${t.id}.${e.id}.${r.stack||r.type}`}function zQ(t){const{min:e,max:r,minDefined:n,maxDefined:i}=t.getUserBounds();return{min:n?e:Number.NEGATIVE_INFINITY,max:i?r:Number.POSITIVE_INFINITY}}function VQ(t,e,r){const n=t[e]||(t[e]={});return n[r]||(n[r]={})}function CA(t,e,r,n){for(const i of e.getMatchingVisibleMetas(n).reverse()){const a=t[i.index];if(r&&a>0||!r&&a<0)return i.index}return null}function EA(t,e){const{chart:r,_cachedMeta:n}=t,i=r._stacks||(r._stacks={}),{iScale:a,vScale:s,index:o}=n,l=a.axis,c=s.axis,d=BQ(a,s,n),h=e.length;let g;for(let m=0;m<h;++m){const v=e[m],{[l]:b,[c]:y}=v,x=v._stacks||(v._stacks={});g=x[c]=VQ(i,d,b),g[o]=y,g._top=CA(g,s,!0,n.type),g._bottom=CA(g,s,!1,n.type);const w=g._visualValues||(g._visualValues={});w[o]=y}}function my(t,e){const r=t.scales;return Object.keys(r).filter(n=>r[n].axis===e).shift()}function GQ(t,e){return Ss(t,{active:!1,dataset:void 0,datasetIndex:e,index:e,mode:"default",type:"dataset"})}function KQ(t,e,r){return Ss(t,{active:!1,dataIndex:e,parsed:void 0,raw:void 0,element:r,index:e,mode:"default",type:"data"})}function uu(t,e){const r=t.controller.index,n=t.vScale&&t.vScale.axis;if(n){e=e||t._parsed;for(const i of e){const a=i._stacks;if(!a||a[n]===void 0||a[n][r]===void 0)return;delete a[n][r],a[n]._visualValues!==void 0&&a[n]._visualValues[r]!==void 0&&delete a[n]._visualValues[r]}}}const vy=t=>t==="reset"||t==="none",OA=(t,e)=>e?t:Object.assign({},t),XQ=(t,e,r)=>t&&!e.hidden&&e._stacked&&{keys:PP(r,!0),values:null};class Du{constructor(e,r){this.chart=e,this._ctx=e.ctx,this.index=r,this._cachedDataOpts={},this._cachedMeta=this.getMeta(),this._type=this._cachedMeta.type,this.options=void 0,this._parsing=!1,this._data=void 0,this._objectData=void 0,this._sharedOptions=void 0,this._drawStart=void 0,this._drawCount=void 0,this.enableOptionSharing=!1,this.supportsDecimation=!1,this.$context=void 0,this._syncList=[],this.datasetElementType=new.target.datasetElementType,this.dataElementType=new.target.dataElementType,this.initialize()}initialize(){const e=this._cachedMeta;this.configure(),this.linkScales(),e._stacked=SA(e.vScale,e),this.addElements(),this.options.fill&&!this.chart.isPluginEnabled("filler")&&console.warn("Tried to use the 'fill' option without the 'Filler' plugin enabled. Please import and register the 'Filler' plugin and make sure it is not disabled in the options")}updateIndex(e){this.index!==e&&uu(this._cachedMeta),this.index=e}linkScales(){const e=this.chart,r=this._cachedMeta,n=this.getDataset(),i=(h,g,m,v)=>h==="x"?g:h==="r"?v:m,a=r.xAxisID=Xe(n.xAxisID,my(e,"x")),s=r.yAxisID=Xe(n.yAxisID,my(e,"y")),o=r.rAxisID=Xe(n.rAxisID,my(e,"r")),l=r.indexAxis,c=r.iAxisID=i(l,a,s,o),d=r.vAxisID=i(l,s,a,o);r.xScale=this.getScaleForId(a),r.yScale=this.getScaleForId(s),r.rScale=this.getScaleForId(o),r.iScale=this.getScaleForId(c),r.vScale=this.getScaleForId(d)}getDataset(){return this.chart.data.datasets[this.index]}getMeta(){return this.chart.getDatasetMeta(this.index)}getScaleForId(e){return this.chart.scales[e]}_getOtherScale(e){const r=this._cachedMeta;return e===r.iScale?r.vScale:r.iScale}reset(){this._update("reset")}_destroy(){const e=this._cachedMeta;this._data&&oA(this._data,this),e._stacked&&uu(e)}_dataCheck(){const e=this.getDataset(),r=e.data||(e.data=[]),n=this._data;if(it(r))this._data=WQ(r);else if(n!==r){if(n){oA(n,this);const i=this._cachedMeta;uu(i),i._parsed=[]}r&&Object.isExtensible(r)&&RJ(r,this),this._syncList=[],this._data=r}}addElements(){const e=this._cachedMeta;this._dataCheck(),this.datasetElementType&&(e.dataset=new this.datasetElementType)}buildOrUpdateElements(e){const r=this._cachedMeta,n=this.getDataset();let i=!1;this._dataCheck();const a=r._stacked;r._stacked=SA(r.vScale,r),r.stack!==n.stack&&(i=!0,uu(r),r.stack=n.stack),this._resyncElements(e),(i||a!==r._stacked)&&EA(this,r._parsed)}configure(){const e=this.chart.config,r=e.datasetScopeKeys(this._type),n=e.getOptionScopes(this.getDataset(),r,!0);this.options=e.createResolver(n,this.getContext()),this._parsing=this.options.parsing,this._cachedDataOpts={}}parse(e,r){const{_cachedMeta:n,_data:i}=this,{iScale:a,_stacked:s}=n,o=a.axis;let l=e===0&&r===i.length?!0:n._sorted,c=e>0&&n._parsed[e-1],d,h,g;if(this._parsing===!1)n._parsed=i,n._sorted=!0,g=i;else{Xt(i[e])?g=this.parseArrayData(n,i,e,r):it(i[e])?g=this.parseObjectData(n,i,e,r):g=this.parsePrimitiveData(n,i,e,r);const m=()=>h[o]===null||c&&h[o]<c[o];for(d=0;d<r;++d)n._parsed[d+e]=h=g[d],l&&(m()&&(l=!1),c=h);n._sorted=l}s&&EA(this,g)}parsePrimitiveData(e,r,n,i){const{iScale:a,vScale:s}=e,o=a.axis,l=s.axis,c=a.getLabels(),d=a===s,h=new Array(i);let g,m,v;for(g=0,m=i;g<m;++g)v=g+n,h[g]={[o]:d||a.parse(c[v],v),[l]:s.parse(r[v],v)};return h}parseArrayData(e,r,n,i){const{xScale:a,yScale:s}=e,o=new Array(i);let l,c,d,h;for(l=0,c=i;l<c;++l)d=l+n,h=r[d],o[l]={x:a.parse(h[0],d),y:s.parse(h[1],d)};return o}parseObjectData(e,r,n,i){const{xScale:a,yScale:s}=e,{xAxisKey:o="x",yAxisKey:l="y"}=this._parsing,c=new Array(i);let d,h,g,m;for(d=0,h=i;d<h;++d)g=d+n,m=r[g],c[d]={x:a.parse(ud(m,o),g),y:s.parse(ud(m,l),g)};return c}getParsed(e){return this._cachedMeta._parsed[e]}getDataElement(e){return this._cachedMeta.data[e]}applyStack(e,r,n){const i=this.chart,a=this._cachedMeta,s=r[e.axis],o={keys:PP(i,!0),values:r._stacks[e.axis]._visualValues};return TA(o,s,a.index,{mode:n})}updateRangeFromParsed(e,r,n,i){const a=n[r.axis];let s=a===null?NaN:a;const o=i&&n._stacks[r.axis];i&&o&&(i.values=o,s=TA(i,a,this._cachedMeta.index)),e.min=Math.min(e.min,s),e.max=Math.max(e.max,s)}getMinMax(e,r){const n=this._cachedMeta,i=n._parsed,a=n._sorted&&e===n.iScale,s=i.length,o=this._getOtherScale(e),l=XQ(r,n,this.chart),c={min:Number.POSITIVE_INFINITY,max:Number.NEGATIVE_INFINITY},{min:d,max:h}=zQ(o);let g,m;function v(){m=i[g];const b=m[o.axis];return!Ir(m[e.axis])||d>b||h<b}for(g=0;g<s&&!(!v()&&(this.updateRangeFromParsed(c,e,m,l),a));++g);if(a){for(g=s-1;g>=0;--g)if(!v()){this.updateRangeFromParsed(c,e,m,l);break}}return c}getAllParsedValues(e){const r=this._cachedMeta._parsed,n=[];let i,a,s;for(i=0,a=r.length;i<a;++i)s=r[i][e.axis],Ir(s)&&n.push(s);return n}getMaxOverflow(){return!1}getLabelAndValue(e){const r=this._cachedMeta,n=r.iScale,i=r.vScale,a=this.getParsed(e);return{label:n?""+n.getLabelForValue(a[n.axis]):"",value:i?""+i.getLabelForValue(a[i.axis]):""}}_update(e){const r=this._cachedMeta;this.update(e||"default"),r._clip=HQ(Xe(this.options.clip,qQ(r.xScale,r.yScale,this.getMaxOverflow())))}update(e){}draw(){const e=this._ctx,r=this.chart,n=this._cachedMeta,i=n.data||[],a=r.chartArea,s=[],o=this._drawStart||0,l=this._drawCount||i.length-o,c=this.options.drawActiveElementsOnTop;let d;for(n.dataset&&n.dataset.draw(e,a,o,l),d=o;d<o+l;++d){const h=i[d];h.hidden||(h.active&&c?s.push(h):h.draw(e,a))}for(d=0;d<s.length;++d)s[d].draw(e,a)}getStyle(e,r){const n=r?"active":"default";return e===void 0&&this._cachedMeta.dataset?this.resolveDatasetElementOptions(n):this.resolveDataElementOptions(e||0,n)}getContext(e,r,n){const i=this.getDataset();let a;if(e>=0&&e<this._cachedMeta.data.length){const s=this._cachedMeta.data[e];a=s.$context||(s.$context=KQ(this.getContext(),e,s)),a.parsed=this.getParsed(e),a.raw=i.data[e],a.index=a.dataIndex=e}else a=this.$context||(this.$context=GQ(this.chart.getContext(),this.index)),a.dataset=i,a.index=a.datasetIndex=this.index;return a.active=!!r,a.mode=n,a}resolveDatasetElementOptions(e){return this._resolveElementOptions(this.datasetElementType.id,e)}resolveDataElementOptions(e,r){return this._resolveElementOptions(this.dataElementType.id,r,e)}_resolveElementOptions(e,r="default",n){const i=r==="active",a=this._cachedDataOpts,s=e+"-"+r,o=a[s],l=this.enableOptionSharing&&Sn(n);if(o)return OA(o,l);const c=this.chart.config,d=c.datasetElementScopeKeys(this._type,e),h=i?[`${e}Hover`,"hover",e,""]:[e,""],g=c.getOptionScopes(this.getDataset(),d),m=Object.keys(lr.elements[e]),v=()=>this.getContext(n,i,r),b=c.resolveNamedOptions(g,m,v,h);return b.$shared&&(b.$shared=l,a[s]=Object.freeze(OA(b,l))),b}_resolveAnimations(e,r,n){const i=this.chart,a=this._cachedDataOpts,s=`animation-${r}`,o=a[s];if(o)return o;let l;if(i.options.animation!==!1){const d=this.chart.config,h=d.datasetAnimationScopeKeys(this._type,r),g=d.getOptionScopes(this.getDataset(),h);l=d.createResolver(g,this.getContext(e,n,r))}const c=new Gb(i,l&&l.animations);return l&&l._cacheable&&(a[s]=Object.freeze(c)),c}getSharedOptions(e){if(e.$shared)return this._sharedOptions||(this._sharedOptions=Object.assign({},e))}includeOptions(e,r){return!r||vy(e)||this.chart._animationsDisabled}_getSharedOptions(e,r){const n=this.resolveDataElementOptions(e,r),i=this._sharedOptions,a=this.getSharedOptions(n),s=this.includeOptions(r,a)||a!==i;return this.updateSharedOptions(a,r,n),{sharedOptions:a,includeOptions:s}}updateElement(e,r,n,i){vy(i)?Object.assign(e,n):this._resolveAnimations(r,i).update(e,n)}updateSharedOptions(e,r,n){e&&!vy(r)&&this._resolveAnimations(void 0,r).update(e,n)}_setStyle(e,r,n,i){e.active=i;const a=this.getStyle(r,i);this._resolveAnimations(r,n,i).update(e,{options:!i&&this.getSharedOptions(a)||a})}removeHoverStyle(e,r,n){this._setStyle(e,n,"active",!1)}setHoverStyle(e,r,n){this._setStyle(e,n,"active",!0)}_removeDatasetHoverStyle(){const e=this._cachedMeta.dataset;e&&this._setStyle(e,void 0,"active",!1)}_setDatasetHoverStyle(){const e=this._cachedMeta.dataset;e&&this._setStyle(e,void 0,"active",!0)}_resyncElements(e){const r=this._data,n=this._cachedMeta.data;for(const[o,l,c]of this._syncList)this[o](l,c);this._syncList=[];const i=n.length,a=r.length,s=Math.min(a,i);s&&this.parse(0,s),a>i?this._insertElements(i,a-i,e):a<i&&this._removeElements(a,i-a)}_insertElements(e,r,n=!0){const i=this._cachedMeta,a=i.data,s=e+r;let o;const l=c=>{for(c.length+=r,o=c.length-1;o>=s;o--)c[o]=c[o-r]};for(l(a),o=e;o<s;++o)a[o]=new this.dataElementType;this._parsing&&l(i._parsed),this.parse(e,r),n&&this.updateElements(a,e,r,"reset")}updateElements(e,r,n,i){}_removeElements(e,r){const n=this._cachedMeta;if(this._parsing){const i=n._parsed.splice(e,r);n._stacked&&uu(n,i)}n.data.splice(e,r)}_sync(e){if(this._parsing)this._syncList.push(e);else{const[r,n,i]=e;this[r](n,i)}this.chart._dataChanges.push([this.index,...e])}_onDataPush(){const e=arguments.length;this._sync(["_insertElements",this.getDataset().data.length-e,e])}_onDataPop(){this._sync(["_removeElements",this._cachedMeta.data.length-1,1])}_onDataShift(){this._sync(["_removeElements",0,1])}_onDataSplice(e,r){r&&this._sync(["_removeElements",e,r]);const n=arguments.length-2;n&&this._sync(["_insertElements",e,n])}_onDataUnshift(){this._sync(["_insertElements",0,arguments.length])}}qe(Du,"defaults",{}),qe(Du,"datasetElementType",null),qe(Du,"dataElementType",null);class ao extends Du{initialize(){this.enableOptionSharing=!0,this.supportsDecimation=!0,super.initialize()}update(e){const r=this._cachedMeta,{dataset:n,data:i=[],_dataset:a}=r,s=this.chart._animationsDisabled;let{start:o,count:l}=LJ(r,i,s);this._drawStart=o,this._drawCount=l,NJ(r)&&(o=0,l=i.length),n._chart=this.chart,n._datasetIndex=this.index,n._decimated=!!a._decimated,n.points=i;const c=this.resolveDatasetElementOptions(e);this.options.showLine||(c.borderWidth=0),c.segment=this.options.segment,this.updateElement(n,void 0,{animated:!s,options:c},e),this.updateElements(i,o,l,e)}updateElements(e,r,n,i){const a=i==="reset",{iScale:s,vScale:o,_stacked:l,_dataset:c}=this._cachedMeta,{sharedOptions:d,includeOptions:h}=this._getSharedOptions(r,i),g=s.axis,m=o.axis,{spanGaps:v,segment:b}=this.options,y=ps(v)?v:Number.POSITIVE_INFINITY,x=this.chart._animationsDisabled||a||i==="none",w=r+n,S=e.length;let E=r>0&&this.getParsed(r-1);for(let C=0;C<S;++C){const I=e[C],T=x?I:{};if(C<r||C>=w){T.skip=!0;continue}const D=this.getParsed(C),P=ur(D[m]),L=T[g]=s.getPixelForValue(D[g],C),F=T[m]=a||P?o.getBasePixel():o.getPixelForValue(l?this.applyStack(o,D,l):D[m],C);T.skip=isNaN(L)||isNaN(F)||P,T.stop=C>0&&Math.abs(D[g]-E[g])>y,b&&(T.parsed=D,T.raw=c.data[C]),h&&(T.options=d||this.resolveDataElementOptions(C,I.active?"active":i)),x||this.updateElement(I,C,T,i),E=D}}getMaxOverflow(){const e=this._cachedMeta,r=e.dataset,n=r.options&&r.options.borderWidth||0,i=e.data||[];if(!i.length)return n;const a=i[0].size(this.resolveDataElementOptions(0)),s=i[i.length-1].size(this.resolveDataElementOptions(i.length-1));return Math.max(n,a,s)/2}draw(){const e=this._cachedMeta;e.dataset.updateControlPoints(this.chart.chartArea,e.iScale.axis),super.draw()}}qe(ao,"id","line"),qe(ao,"defaults",{datasetElementType:"line",dataElementType:"point",showLine:!0,spanGaps:!1}),qe(ao,"overrides",{scales:{_index_:{type:"category"},_value_:{type:"linear"}}});function za(){throw new Error("This method is not implemented: Check that a complete date adapter is provided.")}class Kb{constructor(e){qe(this,"options");this.options=e||{}}static override(e){Object.assign(Kb.prototype,e)}init(){}formats(){return za()}parse(){return za()}format(){return za()}add(){return za()}diff(){return za()}startOf(){return za()}endOf(){return za()}}var LP={_date:Kb};function YQ(t,e,r,n){const{controller:i,data:a,_sorted:s}=t,o=i._cachedMeta.iScale;if(o&&e===o.axis&&e!=="r"&&s&&a.length){const l=o._reversePixels?AJ:ns;if(n){if(i._sharedOptions){const c=a[0],d=typeof c.getRange=="function"&&c.getRange(e);if(d){const h=l(a,e,r-d),g=l(a,e,r+d);return{lo:h.lo,hi:g.hi}}}}else return l(a,e,r)}return{lo:0,hi:a.length-1}}function Jd(t,e,r,n,i){const a=t.getSortedVisibleDatasetMetas(),s=r[e];for(let o=0,l=a.length;o<l;++o){const{index:c,data:d}=a[o],{lo:h,hi:g}=YQ(a[o],e,s,i);for(let m=h;m<=g;++m){const v=d[m];v.skip||n(v,c,m)}}}function ZQ(t){const e=t.indexOf("x")!==-1,r=t.indexOf("y")!==-1;return function(n,i){const a=e?Math.abs(n.x-i.x):0,s=r?Math.abs(n.y-i.y):0;return Math.sqrt(Math.pow(a,2)+Math.pow(s,2))}}function yy(t,e,r,n,i){const a=[];return!i&&!t.isPointInArea(e)||Jd(t,r,e,function(o,l,c){!i&&!qu(o,t.chartArea,0)||o.inRange(e.x,e.y,n)&&a.push({element:o,datasetIndex:l,index:c})},!0),a}function JQ(t,e,r,n){let i=[];function a(s,o,l){const{startAngle:c,endAngle:d}=s.getProps(["startAngle","endAngle"],n),{angle:h}=CJ(s,{x:e.x,y:e.y});hP(h,c,d)&&i.push({element:s,datasetIndex:o,index:l})}return Jd(t,r,e,a),i}function QQ(t,e,r,n,i,a){let s=[];const o=ZQ(r);let l=Number.POSITIVE_INFINITY;function c(d,h,g){const m=d.inRange(e.x,e.y,i);if(n&&!m)return;const v=d.getCenterPoint(i);if(!(!!a||t.isPointInArea(v))&&!m)return;const y=o(e,v);y<l?(s=[{element:d,datasetIndex:h,index:g}],l=y):y===l&&s.push({element:d,datasetIndex:h,index:g})}return Jd(t,r,e,c),s}function by(t,e,r,n,i,a){return!a&&!t.isPointInArea(e)?[]:r==="r"&&!n?JQ(t,e,r,i):QQ(t,e,r,n,i,a)}function AA(t,e,r,n,i){const a=[],s=r==="x"?"inXRange":"inYRange";let o=!1;return Jd(t,r,e,(l,c,d)=>{l[s](e[r],i)&&(a.push({element:l,datasetIndex:c,index:d}),o=o||l.inRange(e.x,e.y,i))}),n&&!o?[]:a}var eee={modes:{index(t,e,r,n){const i=Ya(e,t),a=r.axis||"x",s=r.includeInvisible||!1,o=r.intersect?yy(t,i,a,n,s):by(t,i,a,!1,n,s),l=[];return o.length?(t.getSortedVisibleDatasetMetas().forEach(c=>{const d=o[0].index,h=c.data[d];h&&!h.skip&&l.push({element:h,datasetIndex:c.index,index:d})}),l):[]},dataset(t,e,r,n){const i=Ya(e,t),a=r.axis||"xy",s=r.includeInvisible||!1;let o=r.intersect?yy(t,i,a,n,s):by(t,i,a,!1,n,s);if(o.length>0){const l=o[0].datasetIndex,c=t.getDatasetMeta(l).data;o=[];for(let d=0;d<c.length;++d)o.push({element:c[d],datasetIndex:l,index:d})}return o},point(t,e,r,n){const i=Ya(e,t),a=r.axis||"xy",s=r.includeInvisible||!1;return yy(t,i,a,n,s)},nearest(t,e,r,n){const i=Ya(e,t),a=r.axis||"xy",s=r.includeInvisible||!1;return by(t,i,a,r.intersect,n,s)},x(t,e,r,n){const i=Ya(e,t);return AA(t,i,"x",r.intersect,n)},y(t,e,r,n){const i=Ya(e,t);return AA(t,i,"y",r.intersect,n)}}};const NP=["left","top","right","bottom"];function lu(t,e){return t.filter(r=>r.pos===e)}function IA(t,e){return t.filter(r=>NP.indexOf(r.pos)===-1&&r.box.axis===e)}function cu(t,e){return t.sort((r,n)=>{const i=e?n:r,a=e?r:n;return i.weight===a.weight?i.index-a.index:i.weight-a.weight})}function tee(t){const e=[];let r,n,i,a,s,o;for(r=0,n=(t||[]).length;r<n;++r)i=t[r],{position:a,options:{stack:s,stackWeight:o=1}}=i,e.push({index:r,box:i,pos:a,horizontal:i.isHorizontal(),weight:i.weight,stack:s&&a+s,stackWeight:o});return e}function ree(t){const e={};for(const r of t){const{stack:n,pos:i,stackWeight:a}=r;if(!n||!NP.includes(i))continue;const s=e[n]||(e[n]={count:0,placed:0,weight:0,size:0});s.count++,s.weight+=a}return e}function nee(t,e){const r=ree(t),{vBoxMaxWidth:n,hBoxMaxHeight:i}=e;let a,s,o;for(a=0,s=t.length;a<s;++a){o=t[a];const{fullSize:l}=o.box,c=r[o.stack],d=c&&o.stackWeight/c.weight;o.horizontal?(o.width=d?d*n:l&&e.availableWidth,o.height=i):(o.width=n,o.height=d?d*i:l&&e.availableHeight)}return r}function iee(t){const e=tee(t),r=cu(e.filter(c=>c.box.fullSize),!0),n=cu(lu(e,"left"),!0),i=cu(lu(e,"right")),a=cu(lu(e,"top"),!0),s=cu(lu(e,"bottom")),o=IA(e,"x"),l=IA(e,"y");return{fullSize:r,leftAndTop:n.concat(a),rightAndBottom:i.concat(l).concat(s).concat(o),chartArea:lu(e,"chartArea"),vertical:n.concat(i).concat(l),horizontal:a.concat(s).concat(o)}}function RA(t,e,r,n){return Math.max(t[r],e[r])+Math.max(t[n],e[n])}function FP(t,e){t.top=Math.max(t.top,e.top),t.left=Math.max(t.left,e.left),t.bottom=Math.max(t.bottom,e.bottom),t.right=Math.max(t.right,e.right)}function aee(t,e,r,n){const{pos:i,box:a}=r,s=t.maxPadding;if(!it(i)){r.size&&(t[i]-=r.size);const h=n[r.stack]||{size:0,count:1};h.size=Math.max(h.size,r.horizontal?a.height:a.width),r.size=h.size/h.count,t[i]+=r.size}a.getPadding&&FP(s,a.getPadding());const o=Math.max(0,e.outerWidth-RA(s,t,"left","right")),l=Math.max(0,e.outerHeight-RA(s,t,"top","bottom")),c=o!==t.w,d=l!==t.h;return t.w=o,t.h=l,r.horizontal?{same:c,other:d}:{same:d,other:c}}function see(t){const e=t.maxPadding;function r(n){const i=Math.max(e[n]-t[n],0);return t[n]+=i,i}t.y+=r("top"),t.x+=r("left"),r("right"),r("bottom")}function oee(t,e){const r=e.maxPadding;function n(i){const a={left:0,top:0,right:0,bottom:0};return i.forEach(s=>{a[s]=Math.max(e[s],r[s])}),a}return n(t?["left","right"]:["top","bottom"])}function bu(t,e,r,n){const i=[];let a,s,o,l,c,d;for(a=0,s=t.length,c=0;a<s;++a){o=t[a],l=o.box,l.update(o.width||e.w,o.height||e.h,oee(o.horizontal,e));const{same:h,other:g}=aee(e,r,o,n);c|=h&&i.length,d=d||g,l.fullSize||i.push(o)}return c&&bu(i,e,r,n)||d}function sf(t,e,r,n,i){t.top=r,t.left=e,t.right=e+n,t.bottom=r+i,t.width=n,t.height=i}function DA(t,e,r,n){const i=r.padding;let{x:a,y:s}=e;for(const o of t){const l=o.box,c=n[o.stack]||{placed:0,weight:1},d=o.stackWeight/c.weight||1;if(o.horizontal){const h=e.w*d,g=c.size||l.height;Sn(c.start)&&(s=c.start),l.fullSize?sf(l,i.left,s,r.outerWidth-i.right-i.left,g):sf(l,e.left+c.placed,s,h,g),c.start=s,c.placed+=h,s=l.bottom}else{const h=e.h*d,g=c.size||l.width;Sn(c.start)&&(a=c.start),l.fullSize?sf(l,a,i.top,g,r.outerHeight-i.bottom-i.top):sf(l,a,e.top+c.placed,g,h),c.start=a,c.placed+=h,a=l.right}}e.x=a,e.y=s}var va={addBox(t,e){t.boxes||(t.boxes=[]),e.fullSize=e.fullSize||!1,e.position=e.position||"top",e.weight=e.weight||0,e._layers=e._layers||function(){return[{z:0,draw(r){e.draw(r)}}]},t.boxes.push(e)},removeBox(t,e){const r=t.boxes?t.boxes.indexOf(e):-1;r!==-1&&t.boxes.splice(r,1)},configure(t,e,r){e.fullSize=r.fullSize,e.position=r.position,e.weight=r.weight},update(t,e,r,n){if(!t)return;const i=Kr(t.options.layout.padding),a=Math.max(e-i.width,0),s=Math.max(r-i.height,0),o=iee(t.boxes),l=o.vertical,c=o.horizontal;jt(t.boxes,b=>{typeof b.beforeLayout=="function"&&b.beforeLayout()});const d=l.reduce((b,y)=>y.box.options&&y.box.options.display===!1?b:b+1,0)||1,h=Object.freeze({outerWidth:e,outerHeight:r,padding:i,availableWidth:a,availableHeight:s,vBoxMaxWidth:a/2/d,hBoxMaxHeight:s/2}),g=Object.assign({},i);FP(g,Kr(n));const m=Object.assign({maxPadding:g,w:a,h:s,x:i.left,y:i.top},i),v=nee(l.concat(c),h);bu(o.fullSize,m,h,v),bu(l,m,h,v),bu(c,m,h,v)&&bu(l,m,h,v),see(m),DA(o.leftAndTop,m,h,v),m.x+=m.w,m.y+=m.h,DA(o.rightAndBottom,m,h,v),t.chartArea={left:m.left,top:m.top,right:m.left+m.w,bottom:m.top+m.h,height:m.h,width:m.w},jt(o.chartArea,b=>{const y=b.box;Object.assign(y,t.chartArea),y.update(m.w,m.h,{left:0,top:0,right:0,bottom:0})})}};class kP{acquireContext(e,r){}releaseContext(e){return!1}addEventListener(e,r,n){}removeEventListener(e,r,n){}getDevicePixelRatio(){return 1}getMaximumSize(e,r,n,i){return r=Math.max(0,r||e.width),n=n||e.height,{width:r,height:Math.max(0,i?Math.floor(r/i):n)}}isAttached(e){return!0}updateConfig(e){}}class uee extends kP{acquireContext(e){return e&&e.getContext&&e.getContext("2d")||null}updateConfig(e){e.options.animation=!1}}const xf="$chartjs",lee={touchstart:"mousedown",touchmove:"mousemove",touchend:"mouseup",pointerenter:"mouseenter",pointerdown:"mousedown",pointermove:"mousemove",pointerup:"mouseup",pointerleave:"mouseout",pointerout:"mouseout"},MA=t=>t===null||t==="";function cee(t,e){const r=t.style,n=t.getAttribute("height"),i=t.getAttribute("width");if(t[xf]={initial:{height:n,width:i,style:{display:r.display,height:r.height,width:r.width}}},r.display=r.display||"block",r.boxSizing=r.boxSizing||"border-box",MA(i)){const a=vA(t,"width");a!==void 0&&(t.width=a)}if(MA(n))if(t.style.height==="")t.height=t.width/(e||2);else{const a=vA(t,"height");a!==void 0&&(t.height=a)}return t}const jP=CQ?{passive:!0}:!1;function fee(t,e,r){t.addEventListener(e,r,jP)}function dee(t,e,r){t.canvas.removeEventListener(e,r,jP)}function hee(t,e){const r=lee[t.type]||t.type,{x:n,y:i}=Ya(t,e);return{type:r,chart:e,native:t,x:n!==void 0?n:null,y:i!==void 0?i:null}}function pd(t,e){for(const r of t)if(r===e||r.contains(e))return!0}function pee(t,e,r){const n=t.canvas,i=new MutationObserver(a=>{let s=!1;for(const o of a)s=s||pd(o.addedNodes,n),s=s&&!pd(o.removedNodes,n);s&&r()});return i.observe(document,{childList:!0,subtree:!0}),i}function gee(t,e,r){const n=t.canvas,i=new MutationObserver(a=>{let s=!1;for(const o of a)s=s||pd(o.removedNodes,n),s=s&&!pd(o.addedNodes,n);s&&r()});return i.observe(document,{childList:!0,subtree:!0}),i}const Hu=new Map;let PA=0;function $P(){const t=window.devicePixelRatio;t!==PA&&(PA=t,Hu.forEach((e,r)=>{r.currentDevicePixelRatio!==t&&e()}))}function mee(t,e){Hu.size||window.addEventListener("resize",$P),Hu.set(t,e)}function vee(t){Hu.delete(t),Hu.size||window.removeEventListener("resize",$P)}function yee(t,e,r){const n=t.canvas,i=n&&Vb(n);if(!i)return;const a=mP((o,l)=>{const c=i.clientWidth;r(o,l),c<i.clientWidth&&r()},window),s=new ResizeObserver(o=>{const l=o[0],c=l.contentRect.width,d=l.contentRect.height;c===0&&d===0||a(c,d)});return s.observe(i),mee(t,a),s}function _y(t,e,r){r&&r.disconnect(),e==="resize"&&vee(t)}function bee(t,e,r){const n=t.canvas,i=mP(a=>{t.ctx!==null&&r(hee(a,t))},t);return fee(n,e,i),i}class _ee extends kP{acquireContext(e,r){const n=e&&e.getContext&&e.getContext("2d");return n&&n.canvas===e?(cee(e,r),n):null}releaseContext(e){const r=e.canvas;if(!r[xf])return!1;const n=r[xf].initial;["height","width"].forEach(a=>{const s=n[a];ur(s)?r.removeAttribute(a):r.setAttribute(a,s)});const i=n.style||{};return Object.keys(i).forEach(a=>{r.style[a]=i[a]}),r.width=r.width,delete r[xf],!0}addEventListener(e,r,n){this.removeEventListener(e,r);const i=e.$proxies||(e.$proxies={}),s={attach:pee,detach:gee,resize:yee}[r]||bee;i[r]=s(e,r,n)}removeEventListener(e,r){const n=e.$proxies||(e.$proxies={}),i=n[r];if(!i)return;({attach:_y,detach:_y,resize:_y}[r]||dee)(e,r,i),n[r]=void 0}getDevicePixelRatio(){return window.devicePixelRatio}getMaximumSize(e,r,n,i){return SQ(e,r,n,i)}isAttached(e){const r=Vb(e);return!!(r&&r.isConnected)}}function xee(t){return!OP()||typeof OffscreenCanvas<"u"&&t instanceof OffscreenCanvas?uee:_ee}var pf;let Bn=(pf=class{constructor(){qe(this,"x");qe(this,"y");qe(this,"active",!1);qe(this,"options");qe(this,"$animations")}tooltipPosition(e){const{x:r,y:n}=this.getProps(["x","y"],e);return{x:r,y:n}}hasValue(){return ps(this.x)&&ps(this.y)}getProps(e,r){const n=this.$animations;if(!r||!n)return this;const i={};return e.forEach(a=>{i[a]=n[a]&&n[a].active()?n[a]._to:this[a]}),i}},qe(pf,"defaults",{}),qe(pf,"defaultRoutes"),pf);function wee(t,e){const r=t.options.ticks,n=Tee(t),i=Math.min(r.maxTicksLimit||n,n),a=r.major.enabled?Cee(e):[],s=a.length,o=a[0],l=a[s-1],c=[];if(s>i)return Eee(e,c,a,s/i),c;const d=See(a,e,i);if(s>0){let h,g;const m=s>1?Math.round((l-o)/(s-1)):null;for(of(e,c,d,ur(m)?0:o-m,o),h=0,g=s-1;h<g;h++)of(e,c,d,a[h],a[h+1]);return of(e,c,d,l,ur(m)?e.length:l+m),c}return of(e,c,d),c}function Tee(t){const e=t.options.offset,r=t._tickSize(),n=t._length/r+(e?0:1),i=t._maxLength/r;return Math.floor(Math.min(n,i))}function See(t,e,r){const n=Oee(t),i=e.length/r;if(!n)return Math.max(i,1);const a=wJ(n);for(let s=0,o=a.length-1;s<o;s++){const l=a[s];if(l>i)return l}return Math.max(i,1)}function Cee(t){const e=[];let r,n;for(r=0,n=t.length;r<n;r++)t[r].major&&e.push(r);return e}function Eee(t,e,r,n){let i=0,a=r[0],s;for(n=Math.ceil(n),s=0;s<t.length;s++)s===a&&(e.push(t[s]),i++,a=r[i*n])}function of(t,e,r,n,i){const a=Xe(n,0),s=Math.min(Xe(i,t.length),t.length);let o=0,l,c,d;for(r=Math.ceil(r),i&&(l=i-n,r=l/Math.floor(l/r)),d=a;d<0;)o++,d=Math.round(a+o*r);for(c=Math.max(a,0);c<s;c++)c===d&&(e.push(t[c]),o++,d=Math.round(a+o*r))}function Oee(t){const e=t.length;let r,n;if(e<2)return!1;for(n=t[0],r=1;r<e;++r)if(t[r]-t[r-1]!==n)return!1;return n}const Aee=t=>t==="left"?"right":t==="right"?"left":t,LA=(t,e,r)=>e==="top"||e==="left"?t[e]+r:t[e]-r,NA=(t,e)=>Math.min(e||t,t);function FA(t,e){const r=[],n=t.length/e,i=t.length;let a=0;for(;a<i;a+=n)r.push(t[Math.floor(a)]);return r}function Iee(t,e,r){const n=t.ticks.length,i=Math.min(e,n-1),a=t._startPixel,s=t._endPixel,o=1e-6;let l=t.getPixelForTick(i),c;if(!(r&&(n===1?c=Math.max(l-a,s-l):e===0?c=(t.getPixelForTick(1)-l)/2:c=(l-t.getPixelForTick(i-1))/2,l+=i<e?c:-c,l<a-o||l>s+o)))return l}function Ree(t,e){jt(t,r=>{const n=r.gc,i=n.length/2;let a;if(i>e){for(a=0;a<i;++a)delete r.data[n[a]];n.splice(0,i)}})}function fu(t){return t.drawTicks?t.tickLength:0}function kA(t,e){if(!t.display)return 0;const r=Or(t.font,e),n=Kr(t.padding);return(Xt(t.text)?t.text.length:1)*r.lineHeight+n.height}function Dee(t,e){return Ss(t,{scale:e,type:"scale"})}function Mee(t,e,r){return Ss(t,{tick:r,index:e,type:"tick"})}function Pee(t,e,r){let n=vP(t);return(r&&e!=="right"||!r&&e==="right")&&(n=Aee(n)),n}function Lee(t,e,r,n){const{top:i,left:a,bottom:s,right:o,chart:l}=t,{chartArea:c,scales:d}=l;let h=0,g,m,v;const b=s-i,y=o-a;if(t.isHorizontal()){if(m=xn(n,a,o),it(r)){const x=Object.keys(r)[0],w=r[x];v=d[x].getPixelForValue(w)+b-e}else r==="center"?v=(c.bottom+c.top)/2+b-e:v=LA(t,r,e);g=o-a}else{if(it(r)){const x=Object.keys(r)[0],w=r[x];m=d[x].getPixelForValue(w)-y+e}else r==="center"?m=(c.left+c.right)/2-y+e:m=LA(t,r,e);v=xn(n,s,i),h=r==="left"?-Gr:Gr}return{titleX:m,titleY:v,maxWidth:g,rotation:h}}class Oo extends Bn{constructor(e){super(),this.id=e.id,this.type=e.type,this.options=void 0,this.ctx=e.ctx,this.chart=e.chart,this.top=void 0,this.bottom=void 0,this.left=void 0,this.right=void 0,this.width=void 0,this.height=void 0,this._margins={left:0,right:0,top:0,bottom:0},this.maxWidth=void 0,this.maxHeight=void 0,this.paddingTop=void 0,this.paddingBottom=void 0,this.paddingLeft=void 0,this.paddingRight=void 0,this.axis=void 0,this.labelRotation=void 0,this.min=void 0,this.max=void 0,this._range=void 0,this.ticks=[],this._gridLineItems=null,this._labelItems=null,this._labelSizes=null,this._length=0,this._maxLength=0,this._longestTextCache={},this._startPixel=void 0,this._endPixel=void 0,this._reversePixels=!1,this._userMax=void 0,this._userMin=void 0,this._suggestedMax=void 0,this._suggestedMin=void 0,this._ticksLength=0,this._borderValue=0,this._cache={},this._dataLimitsCached=!1,this.$context=void 0}init(e){this.options=e.setContext(this.getContext()),this.axis=e.axis,this._userMin=this.parse(e.min),this._userMax=this.parse(e.max),this._suggestedMin=this.parse(e.suggestedMin),this._suggestedMax=this.parse(e.suggestedMax)}parse(e,r){return e}getUserBounds(){let{_userMin:e,_userMax:r,_suggestedMin:n,_suggestedMax:i}=this;return e=oi(e,Number.POSITIVE_INFINITY),r=oi(r,Number.NEGATIVE_INFINITY),n=oi(n,Number.POSITIVE_INFINITY),i=oi(i,Number.NEGATIVE_INFINITY),{min:oi(e,n),max:oi(r,i),minDefined:Ir(e),maxDefined:Ir(r)}}getMinMax(e){let{min:r,max:n,minDefined:i,maxDefined:a}=this.getUserBounds(),s;if(i&&a)return{min:r,max:n};const o=this.getMatchingVisibleMetas();for(let l=0,c=o.length;l<c;++l)s=o[l].controller.getMinMax(this,e),i||(r=Math.min(r,s.min)),a||(n=Math.max(n,s.max));return r=a&&r>n?n:r,n=i&&r>n?r:n,{min:oi(r,oi(n,r)),max:oi(n,oi(r,n))}}getPadding(){return{left:this.paddingLeft||0,top:this.paddingTop||0,right:this.paddingRight||0,bottom:this.paddingBottom||0}}getTicks(){return this.ticks}getLabels(){const e=this.chart.data;return this.options.labels||(this.isHorizontal()?e.xLabels:e.yLabels)||e.labels||[]}getLabelItems(e=this.chart.chartArea){return this._labelItems||(this._labelItems=this._computeLabelItems(e))}beforeLayout(){this._cache={},this._dataLimitsCached=!1}beforeUpdate(){Ut(this.options.beforeUpdate,[this])}update(e,r,n){const{beginAtZero:i,grace:a,ticks:s}=this.options,o=s.sampleSize;this.beforeUpdate(),this.maxWidth=e,this.maxHeight=r,this._margins=n=Object.assign({left:0,right:0,top:0,bottom:0},n),this.ticks=null,this._labelSizes=null,this._gridLineItems=null,this._labelItems=null,this.beforeSetDimensions(),this.setDimensions(),this.afterSetDimensions(),this._maxLength=this.isHorizontal()?this.width+n.left+n.right:this.height+n.top+n.bottom,this._dataLimitsCached||(this.beforeDataLimits(),this.determineDataLimits(),this.afterDataLimits(),this._range=rQ(this,a,i),this._dataLimitsCached=!0),this.beforeBuildTicks(),this.ticks=this.buildTicks()||[],this.afterBuildTicks();const l=o<this.ticks.length;this._convertTicksToLabels(l?FA(this.ticks,o):this.ticks),this.configure(),this.beforeCalculateLabelRotation(),this.calculateLabelRotation(),this.afterCalculateLabelRotation(),s.display&&(s.autoSkip||s.source==="auto")&&(this.ticks=wee(this,this.ticks),this._labelSizes=null,this.afterAutoSkip()),l&&this._convertTicksToLabels(this.ticks),this.beforeFit(),this.fit(),this.afterFit(),this.afterUpdate()}configure(){let e=this.options.reverse,r,n;this.isHorizontal()?(r=this.left,n=this.right):(r=this.top,n=this.bottom,e=!e),this._startPixel=r,this._endPixel=n,this._reversePixels=e,this._length=n-r,this._alignToPixels=this.options.alignToPixels}afterUpdate(){Ut(this.options.afterUpdate,[this])}beforeSetDimensions(){Ut(this.options.beforeSetDimensions,[this])}setDimensions(){this.isHorizontal()?(this.width=this.maxWidth,this.left=0,this.right=this.width):(this.height=this.maxHeight,this.top=0,this.bottom=this.height),this.paddingLeft=0,this.paddingTop=0,this.paddingRight=0,this.paddingBottom=0}afterSetDimensions(){Ut(this.options.afterSetDimensions,[this])}_callHooks(e){this.chart.notifyPlugins(e,this.getContext()),Ut(this.options[e],[this])}beforeDataLimits(){this._callHooks("beforeDataLimits")}determineDataLimits(){}afterDataLimits(){this._callHooks("afterDataLimits")}beforeBuildTicks(){this._callHooks("beforeBuildTicks")}buildTicks(){return[]}afterBuildTicks(){this._callHooks("afterBuildTicks")}beforeTickToLabelConversion(){Ut(this.options.beforeTickToLabelConversion,[this])}generateTickLabels(e){const r=this.options.ticks;let n,i,a;for(n=0,i=e.length;n<i;n++)a=e[n],a.label=Ut(r.callback,[a.value,n,e],this)}afterTickToLabelConversion(){Ut(this.options.afterTickToLabelConversion,[this])}beforeCalculateLabelRotation(){Ut(this.options.beforeCalculateLabelRotation,[this])}calculateLabelRotation(){const e=this.options,r=e.ticks,n=NA(this.ticks.length,e.ticks.maxTicksLimit),i=r.minRotation||0,a=r.maxRotation;let s=i,o,l,c;if(!this._isVisible()||!r.display||i>=a||n<=1||!this.isHorizontal()){this.labelRotation=i;return}const d=this._getLabelSizes(),h=d.widest.width,g=d.highest.height,m=Hn(this.chart.width-h,0,this.maxWidth);o=e.offset?this.maxWidth/n:m/(n-1),h+6>o&&(o=m/(n-(e.offset?.5:1)),l=this.maxHeight-fu(e.grid)-r.padding-kA(e.title,this.chart.options.font),c=Math.sqrt(h*h+g*g),s=dP(Math.min(Math.asin(Hn((d.highest.height+6)/o,-1,1)),Math.asin(Hn(l/c,-1,1))-Math.asin(Hn(g/c,-1,1)))),s=Math.max(i,Math.min(a,s))),this.labelRotation=s}afterCalculateLabelRotation(){Ut(this.options.afterCalculateLabelRotation,[this])}afterAutoSkip(){}beforeFit(){Ut(this.options.beforeFit,[this])}fit(){const e={width:0,height:0},{chart:r,options:{ticks:n,title:i,grid:a}}=this,s=this._isVisible(),o=this.isHorizontal();if(s){const l=kA(i,r.options.font);if(o?(e.width=this.maxWidth,e.height=fu(a)+l):(e.height=this.maxHeight,e.width=fu(a)+l),n.display&&this.ticks.length){const{first:c,last:d,widest:h,highest:g}=this._getLabelSizes(),m=n.padding*2,v=jr(this.labelRotation),b=Math.cos(v),y=Math.sin(v);if(o){const x=n.mirror?0:y*h.width+b*g.height;e.height=Math.min(this.maxHeight,e.height+x+m)}else{const x=n.mirror?0:b*h.width+y*g.height;e.width=Math.min(this.maxWidth,e.width+x+m)}this._calculatePadding(c,d,y,b)}}this._handleMargins(),o?(this.width=this._length=r.width-this._margins.left-this._margins.right,this.height=e.height):(this.width=e.width,this.height=this._length=r.height-this._margins.top-this._margins.bottom)}_calculatePadding(e,r,n,i){const{ticks:{align:a,padding:s},position:o}=this.options,l=this.labelRotation!==0,c=o!=="top"&&this.axis==="x";if(this.isHorizontal()){const d=this.getPixelForTick(0)-this.left,h=this.right-this.getPixelForTick(this.ticks.length-1);let g=0,m=0;l?c?(g=i*e.width,m=n*r.height):(g=n*e.height,m=i*r.width):a==="start"?m=r.width:a==="end"?g=e.width:a!=="inner"&&(g=e.width/2,m=r.width/2),this.paddingLeft=Math.max((g-d+s)*this.width/(this.width-d),0),this.paddingRight=Math.max((m-h+s)*this.width/(this.width-h),0)}else{let d=r.height/2,h=e.height/2;a==="start"?(d=0,h=e.height):a==="end"&&(d=r.height,h=0),this.paddingTop=d+s,this.paddingBottom=h+s}}_handleMargins(){this._margins&&(this._margins.left=Math.max(this.paddingLeft,this._margins.left),this._margins.top=Math.max(this.paddingTop,this._margins.top),this._margins.right=Math.max(this.paddingRight,this._margins.right),this._margins.bottom=Math.max(this.paddingBottom,this._margins.bottom))}afterFit(){Ut(this.options.afterFit,[this])}isHorizontal(){const{axis:e,position:r}=this.options;return r==="top"||r==="bottom"||e==="x"}isFullSize(){return this.options.fullSize}_convertTicksToLabels(e){this.beforeTickToLabelConversion(),this.generateTickLabels(e);let r,n;for(r=0,n=e.length;r<n;r++)ur(e[r].label)&&(e.splice(r,1),n--,r--);this.afterTickToLabelConversion()}_getLabelSizes(){let e=this._labelSizes;if(!e){const r=this.options.ticks.sampleSize;let n=this.ticks;r<n.length&&(n=FA(n,r)),this._labelSizes=e=this._computeLabelSizes(n,n.length,this.options.ticks.maxTicksLimit)}return e}_computeLabelSizes(e,r,n){const{ctx:i,_longestTextCache:a}=this,s=[],o=[],l=Math.floor(r/NA(r,n));let c=0,d=0,h,g,m,v,b,y,x,w,S,E,C;for(h=0;h<r;h+=l){if(v=e[h].label,b=this._resolveTickFontOptions(h),i.font=y=b.string,x=a[y]=a[y]||{data:{},gc:[]},w=b.lineHeight,S=E=0,!ur(v)&&!Xt(v))S=dA(i,x.data,x.gc,S,v),E=w;else if(Xt(v))for(g=0,m=v.length;g<m;++g)C=v[g],!ur(C)&&!Xt(C)&&(S=dA(i,x.data,x.gc,S,C),E+=w);s.push(S),o.push(E),c=Math.max(S,c),d=Math.max(E,d)}Ree(a,r);const I=s.indexOf(c),T=o.indexOf(d),D=P=>({width:s[P]||0,height:o[P]||0});return{first:D(0),last:D(r-1),widest:D(I),highest:D(T),widths:s,heights:o}}getLabelForValue(e){return e}getPixelForValue(e,r){return NaN}getValueForPixel(e){}getPixelForTick(e){const r=this.ticks;return e<0||e>r.length-1?null:this.getPixelForValue(r[e].value)}getPixelForDecimal(e){this._reversePixels&&(e=1-e);const r=this._startPixel+e*this._length;return OJ(this._alignToPixels?Ba(this.chart,r,0):r)}getDecimalForPixel(e){const r=(e-this._startPixel)/this._length;return this._reversePixels?1-r:r}getBasePixel(){return this.getPixelForValue(this.getBaseValue())}getBaseValue(){const{min:e,max:r}=this;return e<0&&r<0?r:e>0&&r>0?e:0}getContext(e){const r=this.ticks||[];if(e>=0&&e<r.length){const n=r[e];return n.$context||(n.$context=Mee(this.getContext(),e,n))}return this.$context||(this.$context=Dee(this.chart.getContext(),this))}_tickSize(){const e=this.options.ticks,r=jr(this.labelRotation),n=Math.abs(Math.cos(r)),i=Math.abs(Math.sin(r)),a=this._getLabelSizes(),s=e.autoSkipPadding||0,o=a?a.widest.width+s:0,l=a?a.highest.height+s:0;return this.isHorizontal()?l*n>o*i?o/n:l/i:l*i<o*n?l/n:o/i}_isVisible(){const e=this.options.display;return e!=="auto"?!!e:this.getMatchingVisibleMetas().length>0}_computeGridLineItems(e){const r=this.axis,n=this.chart,i=this.options,{grid:a,position:s,border:o}=i,l=a.offset,c=this.isHorizontal(),h=this.ticks.length+(l?1:0),g=fu(a),m=[],v=o.setContext(this.getContext()),b=v.display?v.width:0,y=b/2,x=function(te){return Ba(n,te,b)};let w,S,E,C,I,T,D,P,L,F,H,X;if(s==="top")w=x(this.bottom),T=this.bottom-g,P=w-y,F=x(e.top)+y,X=e.bottom;else if(s==="bottom")w=x(this.top),F=e.top,X=x(e.bottom)-y,T=w+y,P=this.top+g;else if(s==="left")w=x(this.right),I=this.right-g,D=w-y,L=x(e.left)+y,H=e.right;else if(s==="right")w=x(this.left),L=e.left,H=x(e.right)-y,I=w+y,D=this.left+g;else if(r==="x"){if(s==="center")w=x((e.top+e.bottom)/2+.5);else if(it(s)){const te=Object.keys(s)[0],ce=s[te];w=x(this.chart.scales[te].getPixelForValue(ce))}F=e.top,X=e.bottom,T=w+y,P=T+g}else if(r==="y"){if(s==="center")w=x((e.left+e.right)/2);else if(it(s)){const te=Object.keys(s)[0],ce=s[te];w=x(this.chart.scales[te].getPixelForValue(ce))}I=w-y,D=I-g,L=e.left,H=e.right}const ee=Xe(i.ticks.maxTicksLimit,h),J=Math.max(1,Math.ceil(h/ee));for(S=0;S<h;S+=J){const te=this.getContext(S),ce=a.setContext(te),B=o.setContext(te),ae=ce.lineWidth,Ce=ce.color,Ae=B.dash||[],ve=B.dashOffset,ct=ce.tickWidth,Ge=ce.tickColor,Le=ce.tickBorderDash||[],Ue=ce.tickBorderDashOffset;E=Iee(this,S,l),E!==void 0&&(C=Ba(n,E,ae),c?I=D=L=H=C:T=P=F=X=C,m.push({tx1:I,ty1:T,tx2:D,ty2:P,x1:L,y1:F,x2:H,y2:X,width:ae,color:Ce,borderDash:Ae,borderDashOffset:ve,tickWidth:ct,tickColor:Ge,tickBorderDash:Le,tickBorderDashOffset:Ue}))}return this._ticksLength=h,this._borderValue=w,m}_computeLabelItems(e){const r=this.axis,n=this.options,{position:i,ticks:a}=n,s=this.isHorizontal(),o=this.ticks,{align:l,crossAlign:c,padding:d,mirror:h}=a,g=fu(n.grid),m=g+d,v=h?-d:m,b=-jr(this.labelRotation),y=[];let x,w,S,E,C,I,T,D,P,L,F,H,X="middle";if(i==="top")I=this.bottom-v,T=this._getXAxisLabelAlignment();else if(i==="bottom")I=this.top+v,T=this._getXAxisLabelAlignment();else if(i==="left"){const J=this._getYAxisLabelAlignment(g);T=J.textAlign,C=J.x}else if(i==="right"){const J=this._getYAxisLabelAlignment(g);T=J.textAlign,C=J.x}else if(r==="x"){if(i==="center")I=(e.top+e.bottom)/2+m;else if(it(i)){const J=Object.keys(i)[0],te=i[J];I=this.chart.scales[J].getPixelForValue(te)+m}T=this._getXAxisLabelAlignment()}else if(r==="y"){if(i==="center")C=(e.left+e.right)/2-m;else if(it(i)){const J=Object.keys(i)[0],te=i[J];C=this.chart.scales[J].getPixelForValue(te)}T=this._getYAxisLabelAlignment(g).textAlign}r==="y"&&(l==="start"?X="top":l==="end"&&(X="bottom"));const ee=this._getLabelSizes();for(x=0,w=o.length;x<w;++x){S=o[x],E=S.label;const J=a.setContext(this.getContext(x));D=this.getPixelForTick(x)+a.labelOffset,P=this._resolveTickFontOptions(x),L=P.lineHeight,F=Xt(E)?E.length:1;const te=F/2,ce=J.color,B=J.textStrokeColor,ae=J.textStrokeWidth;let Ce=T;s?(C=D,T==="inner"&&(x===w-1?Ce=this.options.reverse?"left":"right":x===0?Ce=this.options.reverse?"right":"left":Ce="center"),i==="top"?c==="near"||b!==0?H=-F*L+L/2:c==="center"?H=-ee.highest.height/2-te*L+L:H=-ee.highest.height+L/2:c==="near"||b!==0?H=L/2:c==="center"?H=ee.highest.height/2-te*L:H=ee.highest.height-F*L,h&&(H*=-1),b!==0&&!J.showLabelBackdrop&&(C+=L/2*Math.sin(b))):(I=D,H=(1-F)*L/2);let Ae;if(J.showLabelBackdrop){const ve=Kr(J.backdropPadding),ct=ee.heights[x],Ge=ee.widths[x];let Le=H-ve.top,Ue=0-ve.left;switch(X){case"middle":Le-=ct/2;break;case"bottom":Le-=ct;break}switch(T){case"center":Ue-=Ge/2;break;case"right":Ue-=Ge;break}Ae={left:Ue,top:Le,width:Ge+ve.width,height:ct+ve.height,color:J.backdropColor}}y.push({label:E,font:P,textOffset:H,options:{rotation:b,color:ce,strokeColor:B,strokeWidth:ae,textAlign:Ce,textBaseline:X,translation:[C,I],backdrop:Ae}})}return y}_getXAxisLabelAlignment(){const{position:e,ticks:r}=this.options;if(-jr(this.labelRotation))return e==="top"?"left":"right";let i="center";return r.align==="start"?i="left":r.align==="end"?i="right":r.align==="inner"&&(i="inner"),i}_getYAxisLabelAlignment(e){const{position:r,ticks:{crossAlign:n,mirror:i,padding:a}}=this.options,s=this._getLabelSizes(),o=e+a,l=s.widest.width;let c,d;return r==="left"?i?(d=this.right+a,n==="near"?c="left":n==="center"?(c="center",d+=l/2):(c="right",d+=l)):(d=this.right-o,n==="near"?c="right":n==="center"?(c="center",d-=l/2):(c="left",d=this.left)):r==="right"?i?(d=this.left+a,n==="near"?c="right":n==="center"?(c="center",d-=l/2):(c="left",d-=l)):(d=this.left+o,n==="near"?c="left":n==="center"?(c="center",d+=l/2):(c="right",d=this.right)):c="right",{textAlign:c,x:d}}_computeLabelArea(){if(this.options.ticks.mirror)return;const e=this.chart,r=this.options.position;if(r==="left"||r==="right")return{top:0,left:this.left,bottom:e.height,right:this.right};if(r==="top"||r==="bottom")return{top:this.top,left:0,bottom:this.bottom,right:e.width}}drawBackground(){const{ctx:e,options:{backgroundColor:r},left:n,top:i,width:a,height:s}=this;r&&(e.save(),e.fillStyle=r,e.fillRect(n,i,a,s),e.restore())}getLineWidthForValue(e){const r=this.options.grid;if(!this._isVisible()||!r.display)return 0;const i=this.ticks.findIndex(a=>a.value===e);return i>=0?r.setContext(this.getContext(i)).lineWidth:0}drawGrid(e){const r=this.options.grid,n=this.ctx,i=this._gridLineItems||(this._gridLineItems=this._computeGridLineItems(e));let a,s;const o=(l,c,d)=>{!d.width||!d.color||(n.save(),n.lineWidth=d.width,n.strokeStyle=d.color,n.setLineDash(d.borderDash||[]),n.lineDashOffset=d.borderDashOffset,n.beginPath(),n.moveTo(l.x,l.y),n.lineTo(c.x,c.y),n.stroke(),n.restore())};if(r.display)for(a=0,s=i.length;a<s;++a){const l=i[a];r.drawOnChartArea&&o({x:l.x1,y:l.y1},{x:l.x2,y:l.y2},l),r.drawTicks&&o({x:l.tx1,y:l.ty1},{x:l.tx2,y:l.ty2},{color:l.tickColor,width:l.tickWidth,borderDash:l.tickBorderDash,borderDashOffset:l.tickBorderDashOffset})}}drawBorder(){const{chart:e,ctx:r,options:{border:n,grid:i}}=this,a=n.setContext(this.getContext()),s=n.display?a.width:0;if(!s)return;const o=i.setContext(this.getContext(0)).lineWidth,l=this._borderValue;let c,d,h,g;this.isHorizontal()?(c=Ba(e,this.left,s)-s/2,d=Ba(e,this.right,o)+o/2,h=g=l):(h=Ba(e,this.top,s)-s/2,g=Ba(e,this.bottom,o)+o/2,c=d=l),r.save(),r.lineWidth=a.width,r.strokeStyle=a.color,r.beginPath(),r.moveTo(c,h),r.lineTo(d,g),r.stroke(),r.restore()}drawLabels(e){if(!this.options.ticks.display)return;const n=this.ctx,i=this._computeLabelArea();i&&nl(n,i);const a=this.getLabelItems(e);for(const s of a){const o=s.options,l=s.font,c=s.label,d=s.textOffset;fd(n,c,0,d,l,o)}i&&il(n)}drawTitle(){const{ctx:e,options:{position:r,title:n,reverse:i}}=this;if(!n.display)return;const a=Or(n.font),s=Kr(n.padding),o=n.align;let l=a.lineHeight/2;r==="bottom"||r==="center"||it(r)?(l+=s.bottom,Xt(n.text)&&(l+=a.lineHeight*(n.text.length-1))):l+=s.top;const{titleX:c,titleY:d,maxWidth:h,rotation:g}=Lee(this,l,r,o);fd(e,n.text,0,0,a,{color:n.color,maxWidth:h,rotation:g,textAlign:Pee(o,r,i),textBaseline:"middle",translation:[c,d]})}draw(e){this._isVisible()&&(this.drawBackground(),this.drawGrid(e),this.drawBorder(),this.drawTitle(),this.drawLabels(e))}_layers(){const e=this.options,r=e.ticks&&e.ticks.z||0,n=Xe(e.grid&&e.grid.z,-1),i=Xe(e.border&&e.border.z,0);return!this._isVisible()||this.draw!==Oo.prototype.draw?[{z:r,draw:a=>{this.draw(a)}}]:[{z:n,draw:a=>{this.drawBackground(),this.drawGrid(a),this.drawTitle()}},{z:i,draw:()=>{this.drawBorder()}},{z:r,draw:a=>{this.drawLabels(a)}}]}getMatchingVisibleMetas(e){const r=this.chart.getSortedVisibleDatasetMetas(),n=this.axis+"AxisID",i=[];let a,s;for(a=0,s=r.length;a<s;++a){const o=r[a];o[n]===this.id&&(!e||o.type===e)&&i.push(o)}return i}_resolveTickFontOptions(e){const r=this.options.ticks.setContext(this.getContext(e));return Or(r.font)}_maxDigits(){const e=this._resolveTickFontOptions(0).lineHeight;return(this.isHorizontal()?this.width:this.height)/e}}class uf{constructor(e,r,n){this.type=e,this.scope=r,this.override=n,this.items=Object.create(null)}isForType(e){return Object.prototype.isPrototypeOf.call(this.type.prototype,e.prototype)}register(e){const r=Object.getPrototypeOf(e);let n;kee(r)&&(n=this.register(r));const i=this.items,a=e.id,s=this.scope+"."+a;if(!a)throw new Error("class does not have id: "+e);return a in i||(i[a]=e,Nee(e,s,n),this.override&&lr.override(e.id,e.overrides)),s}get(e){return this.items[e]}unregister(e){const r=this.items,n=e.id,i=this.scope;n in r&&delete r[n],i&&n in lr[i]&&(delete lr[i][n],this.override&&delete gs[n])}}function Nee(t,e,r){const n=Uu(Object.create(null),[r?lr.get(r):{},lr.get(e),t.defaults]);lr.set(e,n),t.defaultRoutes&&Fee(e,t.defaultRoutes),t.descriptors&&lr.describe(e,t.descriptors)}function Fee(t,e){Object.keys(e).forEach(r=>{const n=r.split("."),i=n.pop(),a=[t].concat(n).join("."),s=e[r].split("."),o=s.pop(),l=s.join(".");lr.route(a,i,l,o)})}function kee(t){return"id"in t&&"defaults"in t}class jee{constructor(){this.controllers=new uf(Du,"datasets",!0),this.elements=new uf(Bn,"elements"),this.plugins=new uf(Object,"plugins"),this.scales=new uf(Oo,"scales"),this._typedRegistries=[this.controllers,this.scales,this.elements]}add(...e){this._each("register",e)}remove(...e){this._each("unregister",e)}addControllers(...e){this._each("register",e,this.controllers)}addElements(...e){this._each("register",e,this.elements)}addPlugins(...e){this._each("register",e,this.plugins)}addScales(...e){this._each("register",e,this.scales)}getController(e){return this._get(e,this.controllers,"controller")}getElement(e){return this._get(e,this.elements,"element")}getPlugin(e){return this._get(e,this.plugins,"plugin")}getScale(e){return this._get(e,this.scales,"scale")}removeControllers(...e){this._each("unregister",e,this.controllers)}removeElements(...e){this._each("unregister",e,this.elements)}removePlugins(...e){this._each("unregister",e,this.plugins)}removeScales(...e){this._each("unregister",e,this.scales)}_each(e,r,n){[...r].forEach(i=>{const a=n||this._getRegistryForType(i);n||a.isForType(i)||a===this.plugins&&i.id?this._exec(e,a,i):jt(i,s=>{const o=n||this._getRegistryForType(s);this._exec(e,o,s)})})}_exec(e,r,n){const i=$b(e);Ut(n["before"+i],[],n),r[e](n),Ut(n["after"+i],[],n)}_getRegistryForType(e){for(let r=0;r<this._typedRegistries.length;r++){const n=this._typedRegistries[r];if(n.isForType(e))return n}return this.plugins}_get(e,r,n){const i=r.get(e);if(i===void 0)throw new Error('"'+e+'" is not a registered '+n+".");return i}}var ci=new jee;class $ee{constructor(){this._init=[]}notify(e,r,n,i){r==="beforeInit"&&(this._init=this._createDescriptors(e,!0),this._notify(this._init,e,"install"));const a=i?this._descriptors(e).filter(i):this._descriptors(e),s=this._notify(a,e,r,n);return r==="afterDestroy"&&(this._notify(a,e,"stop"),this._notify(this._init,e,"uninstall")),s}_notify(e,r,n,i){i=i||{};for(const a of e){const s=a.plugin,o=s[n],l=[r,i,a.options];if(Ut(o,l,s)===!1&&i.cancelable)return!1}return!0}invalidate(){ur(this._cache)||(this._oldCache=this._cache,this._cache=void 0)}_descriptors(e){if(this._cache)return this._cache;const r=this._cache=this._createDescriptors(e);return this._notifyStateChanges(e),r}_createDescriptors(e,r){const n=e&&e.config,i=Xe(n.options&&n.options.plugins,{}),a=Uee(n);return i===!1&&!r?[]:Hee(e,a,i,r)}_notifyStateChanges(e){const r=this._oldCache||[],n=this._cache,i=(a,s)=>a.filter(o=>!s.some(l=>o.plugin.id===l.plugin.id));this._notify(i(r,n),e,"stop"),this._notify(i(n,r),e,"start")}}function Uee(t){const e={},r=[],n=Object.keys(ci.plugins.items);for(let a=0;a<n.length;a++)r.push(ci.getPlugin(n[a]));const i=t.plugins||[];for(let a=0;a<i.length;a++){const s=i[a];r.indexOf(s)===-1&&(r.push(s),e[s.id]=!0)}return{plugins:r,localIds:e}}function qee(t,e){return!e&&t===!1?null:t===!0?{}:t}function Hee(t,{plugins:e,localIds:r},n,i){const a=[],s=t.getContext();for(const o of e){const l=o.id,c=qee(n[l],i);c!==null&&a.push({plugin:o,options:Wee(t.config,{plugin:o,local:r[l]},c,s)})}return a}function Wee(t,{plugin:e,local:r},n,i){const a=t.pluginScopeKeys(e),s=t.getOptionScopes(n,a);return r&&e.defaults&&s.push(e.defaults),t.createResolver(s,i,[""],{scriptable:!1,indexable:!1,allKeys:!0})}function u0(t,e){const r=lr.datasets[t]||{};return((e.datasets||{})[t]||{}).indexAxis||e.indexAxis||r.indexAxis||"x"}function Bee(t,e){let r=t;return t==="_index_"?r=e:t==="_value_"&&(r=e==="x"?"y":"x"),r}function zee(t,e){return t===e?"_index_":"_value_"}function jA(t){if(t==="x"||t==="y"||t==="r")return t}function Vee(t){if(t==="top"||t==="bottom")return"x";if(t==="left"||t==="right")return"y"}function l0(t,...e){if(jA(t))return t;for(const r of e){const n=r.axis||Vee(r.position)||t.length>1&&jA(t[0].toLowerCase());if(n)return n}throw new Error(`Cannot determine type of '${t}' axis. Please provide 'axis' or 'position' option.`)}function $A(t,e,r){if(r[e+"AxisID"]===t)return{axis:e}}function Gee(t,e){if(e.data&&e.data.datasets){const r=e.data.datasets.filter(n=>n.xAxisID===t||n.yAxisID===t);if(r.length)return $A(t,"x",r[0])||$A(t,"y",r[0])}return{}}function Kee(t,e){const r=gs[t.type]||{scales:{}},n=e.scales||{},i=u0(t.type,e),a=Object.create(null);return Object.keys(n).forEach(s=>{const o=n[s];if(!it(o))return console.error(`Invalid scale configuration for scale: ${s}`);if(o._proxy)return console.warn(`Ignoring resolver passed as options for scale: ${s}`);const l=l0(s,o,Gee(s,t),lr.scales[o.type]),c=zee(l,i),d=r.scales||{};a[s]=Ou(Object.create(null),[{axis:l},o,d[l],d[c]])}),t.data.datasets.forEach(s=>{const o=s.type||t.type,l=s.indexAxis||u0(o,e),d=(gs[o]||{}).scales||{};Object.keys(d).forEach(h=>{const g=Bee(h,l),m=s[g+"AxisID"]||g;a[m]=a[m]||Object.create(null),Ou(a[m],[{axis:g},n[m],d[h]])})}),Object.keys(a).forEach(s=>{const o=a[s];Ou(o,[lr.scales[o.type],lr.scale])}),a}function UP(t){const e=t.options||(t.options={});e.plugins=Xe(e.plugins,{}),e.scales=Kee(t,e)}function qP(t){return t=t||{},t.datasets=t.datasets||[],t.labels=t.labels||[],t}function Xee(t){return t=t||{},t.data=qP(t.data),UP(t),t}const UA=new Map,HP=new Set;function lf(t,e){let r=UA.get(t);return r||(r=e(),UA.set(t,r),HP.add(r)),r}const du=(t,e,r)=>{const n=ud(e,r);n!==void 0&&t.add(n)};class Yee{constructor(e){this._config=Xee(e),this._scopeCache=new Map,this._resolverCache=new Map}get platform(){return this._config.platform}get type(){return this._config.type}set type(e){this._config.type=e}get data(){return this._config.data}set data(e){this._config.data=qP(e)}get options(){return this._config.options}set options(e){this._config.options=e}get plugins(){return this._config.plugins}update(){const e=this._config;this.clearCache(),UP(e)}clearCache(){this._scopeCache.clear(),this._resolverCache.clear()}datasetScopeKeys(e){return lf(e,()=>[[`datasets.${e}`,""]])}datasetAnimationScopeKeys(e,r){return lf(`${e}.transition.${r}`,()=>[[`datasets.${e}.transitions.${r}`,`transitions.${r}`],[`datasets.${e}`,""]])}datasetElementScopeKeys(e,r){return lf(`${e}-${r}`,()=>[[`datasets.${e}.elements.${r}`,`datasets.${e}`,`elements.${r}`,""]])}pluginScopeKeys(e){const r=e.id,n=this.type;return lf(`${n}-plugin-${r}`,()=>[[`plugins.${r}`,...e.additionalOptionScopes||[]]])}_cachedScopes(e,r){const n=this._scopeCache;let i=n.get(e);return(!i||r)&&(i=new Map,n.set(e,i)),i}getOptionScopes(e,r,n){const{options:i,type:a}=this,s=this._cachedScopes(e,n),o=s.get(r);if(o)return o;const l=new Set;r.forEach(d=>{e&&(l.add(e),d.forEach(h=>du(l,e,h))),d.forEach(h=>du(l,i,h)),d.forEach(h=>du(l,gs[a]||{},h)),d.forEach(h=>du(l,lr,h)),d.forEach(h=>du(l,s0,h))});const c=Array.from(l);return c.length===0&&c.push(Object.create(null)),HP.has(r)&&s.set(r,c),c}chartOptionScopes(){const{options:e,type:r}=this;return[e,gs[r]||{},lr.datasets[r]||{},{type:r},lr,s0]}resolveNamedOptions(e,r,n,i=[""]){const a={$shared:!0},{resolver:s,subPrefixes:o}=qA(this._resolverCache,e,i);let l=s;if(Jee(s,r)){a.$shared=!1,n=ln(n)?n():n;const c=this.createResolver(e,n,o);l=mo(s,n,c)}for(const c of r)a[c]=l[c];return a}createResolver(e,r,n=[""],i){const{resolver:a}=qA(this._resolverCache,e,n);return it(r)?mo(a,r,void 0,i):a}}function qA(t,e,r){let n=t.get(e);n||(n=new Map,t.set(e,n));const i=r.join();let a=n.get(i);return a||(a={resolver:Wb(e,r),subPrefixes:r.filter(o=>!o.toLowerCase().includes("hover"))},n.set(i,a)),a}const Zee=t=>it(t)&&Object.getOwnPropertyNames(t).reduce((e,r)=>e||ln(t[r]),!1);function Jee(t,e){const{isScriptable:r,isIndexable:n}=wP(t);for(const i of e){const a=r(i),s=n(i),o=(s||a)&&t[i];if(a&&(ln(o)||Zee(o))||s&&Xt(o))return!0}return!1}var Qee="4.4.0";const ete=["top","bottom","left","right","chartArea"];function HA(t,e){return t==="top"||t==="bottom"||ete.indexOf(t)===-1&&e==="x"}function WA(t,e){return function(r,n){return r[t]===n[t]?r[e]-n[e]:r[t]-n[t]}}function BA(t){const e=t.chart,r=e.options.animation;e.notifyPlugins("afterRender"),Ut(r&&r.onComplete,[t],e)}function tte(t){const e=t.chart,r=e.options.animation;Ut(r&&r.onProgress,[t],e)}function WP(t){return OP()&&typeof t=="string"?t=document.getElementById(t):t&&t.length&&(t=t[0]),t&&t.canvas&&(t=t.canvas),t}const wf={},zA=t=>{const e=WP(t);return Object.values(wf).filter(r=>r.canvas===e).pop()};function rte(t,e,r){const n=Object.keys(t);for(const i of n){const a=+i;if(a>=e){const s=t[i];delete t[i],(r>0||a>e)&&(t[a+r]=s)}}}function nte(t,e,r,n){return!r||t.type==="mouseout"?null:n?e:t}function cf(t,e,r){return t.options.clip?t[r]:e[r]}function ite(t,e){const{xScale:r,yScale:n}=t;return r&&n?{left:cf(r,e,"left"),right:cf(r,e,"right"),top:cf(n,e,"top"),bottom:cf(n,e,"bottom")}:e}var oa;let us=(oa=class{static register(...e){ci.add(...e),VA()}static unregister(...e){ci.remove(...e),VA()}constructor(e,r){const n=this.config=new Yee(r),i=WP(e),a=zA(i);if(a)throw new Error("Canvas is already in use. Chart with ID '"+a.id+"' must be destroyed before the canvas with ID '"+a.canvas.id+"' can be reused.");const s=n.createResolver(n.chartOptionScopes(),this.getContext());this.platform=new(n.platform||xee(i)),this.platform.updateConfig(n);const o=this.platform.acquireContext(i,s.aspectRatio),l=o&&o.canvas,c=l&&l.height,d=l&&l.width;if(this.id=pJ(),this.ctx=o,this.canvas=l,this.width=d,this.height=c,this._options=s,this._aspectRatio=this.aspectRatio,this._layers=[],this._metasets=[],this._stacks=void 0,this.boxes=[],this.currentDevicePixelRatio=void 0,this.chartArea=void 0,this._active=[],this._lastEvent=void 0,this._listeners={},this._responsiveListeners=void 0,this._sortedMetasets=[],this.scales={},this._plugins=new $ee,this.$proxies={},this._hiddenIndices={},this.attached=!1,this._animationsDisabled=void 0,this.$context=void 0,this._doResize=MJ(h=>this.update(h),s.resizeDelay||0),this._dataChanges=[],wf[this.id]=this,!o||!l){console.error("Failed to create chart: can't acquire context from the given item");return}Pi.listen(this,"complete",BA),Pi.listen(this,"progress",tte),this._initialize(),this.attached&&this.update()}get aspectRatio(){const{options:{aspectRatio:e,maintainAspectRatio:r},width:n,height:i,_aspectRatio:a}=this;return ur(e)?r&&a?a:i?n/i:null:e}get data(){return this.config.data}set data(e){this.config.data=e}get options(){return this._options}set options(e){this.config.options=e}get registry(){return ci}_initialize(){return this.notifyPlugins("beforeInit"),this.options.responsive?this.resize():mA(this,this.options.devicePixelRatio),this.bindEvents(),this.notifyPlugins("afterInit"),this}clear(){return hA(this.canvas,this.ctx),this}stop(){return Pi.stop(this),this}resize(e,r){Pi.running(this)?this._resizeBeforeDraw={width:e,height:r}:this._resize(e,r)}_resize(e,r){const n=this.options,i=this.canvas,a=n.maintainAspectRatio&&this.aspectRatio,s=this.platform.getMaximumSize(i,e,r,a),o=n.devicePixelRatio||this.platform.getDevicePixelRatio(),l=this.width?"resize":"attach";this.width=s.width,this.height=s.height,this._aspectRatio=this.aspectRatio,mA(this,o,!0)&&(this.notifyPlugins("resize",{size:s}),Ut(n.onResize,[this,s],this),this.attached&&this._doResize(l)&&this.render())}ensureScalesHaveIDs(){const r=this.options.scales||{};jt(r,(n,i)=>{n.id=i})}buildOrUpdateScales(){const e=this.options,r=e.scales,n=this.scales,i=Object.keys(n).reduce((s,o)=>(s[o]=!1,s),{});let a=[];r&&(a=a.concat(Object.keys(r).map(s=>{const o=r[s],l=l0(s,o),c=l==="r",d=l==="x";return{options:o,dposition:c?"chartArea":d?"bottom":"left",dtype:c?"radialLinear":d?"category":"linear"}}))),jt(a,s=>{const o=s.options,l=o.id,c=l0(l,o),d=Xe(o.type,s.dtype);(o.position===void 0||HA(o.position,c)!==HA(s.dposition))&&(o.position=s.dposition),i[l]=!0;let h=null;if(l in n&&n[l].type===d)h=n[l];else{const g=ci.getScale(d);h=new g({id:l,type:d,ctx:this.ctx,chart:this}),n[h.id]=h}h.init(o,e)}),jt(i,(s,o)=>{s||delete n[o]}),jt(n,s=>{va.configure(this,s,s.options),va.addBox(this,s)})}_updateMetasets(){const e=this._metasets,r=this.data.datasets.length,n=e.length;if(e.sort((i,a)=>i.index-a.index),n>r){for(let i=r;i<n;++i)this._destroyDatasetMeta(i);e.splice(r,n-r)}this._sortedMetasets=e.slice(0).sort(WA("order","index"))}_removeUnreferencedMetasets(){const{_metasets:e,data:{datasets:r}}=this;e.length>r.length&&delete this._stacks,e.forEach((n,i)=>{r.filter(a=>a===n._dataset).length===0&&this._destroyDatasetMeta(i)})}buildOrUpdateControllers(){const e=[],r=this.data.datasets;let n,i;for(this._removeUnreferencedMetasets(),n=0,i=r.length;n<i;n++){const a=r[n];let s=this.getDatasetMeta(n);const o=a.type||this.config.type;if(s.type&&s.type!==o&&(this._destroyDatasetMeta(n),s=this.getDatasetMeta(n)),s.type=o,s.indexAxis=a.indexAxis||u0(o,this.options),s.order=a.order||0,s.index=n,s.label=""+a.label,s.visible=this.isDatasetVisible(n),s.controller)s.controller.updateIndex(n),s.controller.linkScales();else{const l=ci.getController(o),{datasetElementType:c,dataElementType:d}=lr.datasets[o];Object.assign(l,{dataElementType:ci.getElement(d),datasetElementType:c&&ci.getElement(c)}),s.controller=new l(this,n),e.push(s.controller)}}return this._updateMetasets(),e}_resetElements(){jt(this.data.datasets,(e,r)=>{this.getDatasetMeta(r).controller.reset()},this)}reset(){this._resetElements(),this.notifyPlugins("reset")}update(e){const r=this.config;r.update();const n=this._options=r.createResolver(r.chartOptionScopes(),this.getContext()),i=this._animationsDisabled=!n.animation;if(this._updateScales(),this._checkEventBindings(),this._updateHiddenIndices(),this._plugins.invalidate(),this.notifyPlugins("beforeUpdate",{mode:e,cancelable:!0})===!1)return;const a=this.buildOrUpdateControllers();this.notifyPlugins("beforeElementsUpdate");let s=0;for(let c=0,d=this.data.datasets.length;c<d;c++){const{controller:h}=this.getDatasetMeta(c),g=!i&&a.indexOf(h)===-1;h.buildOrUpdateElements(g),s=Math.max(+h.getMaxOverflow(),s)}s=this._minPadding=n.layout.autoPadding?s:0,this._updateLayout(s),i||jt(a,c=>{c.reset()}),this._updateDatasets(e),this.notifyPlugins("afterUpdate",{mode:e}),this._layers.sort(WA("z","_idx"));const{_active:o,_lastEvent:l}=this;l?this._eventHandler(l,!0):o.length&&this._updateHoverStyles(o,o,!0),this.render()}_updateScales(){jt(this.scales,e=>{va.removeBox(this,e)}),this.ensureScalesHaveIDs(),this.buildOrUpdateScales()}_checkEventBindings(){const e=this.options,r=new Set(Object.keys(this._listeners)),n=new Set(e.events);(!iA(r,n)||!!this._responsiveListeners!==e.responsive)&&(this.unbindEvents(),this.bindEvents())}_updateHiddenIndices(){const{_hiddenIndices:e}=this,r=this._getUniformDataChanges()||[];for(const{method:n,start:i,count:a}of r){const s=n==="_removeElements"?-a:a;rte(e,i,s)}}_getUniformDataChanges(){const e=this._dataChanges;if(!e||!e.length)return;this._dataChanges=[];const r=this.data.datasets.length,n=a=>new Set(e.filter(s=>s[0]===a).map((s,o)=>o+","+s.splice(1).join(","))),i=n(0);for(let a=1;a<r;a++)if(!iA(i,n(a)))return;return Array.from(i).map(a=>a.split(",")).map(a=>({method:a[1],start:+a[2],count:+a[3]}))}_updateLayout(e){if(this.notifyPlugins("beforeLayout",{cancelable:!0})===!1)return;va.update(this,this.width,this.height,e);const r=this.chartArea,n=r.width<=0||r.height<=0;this._layers=[],jt(this.boxes,i=>{n&&i.position==="chartArea"||(i.configure&&i.configure(),this._layers.push(...i._layers()))},this),this._layers.forEach((i,a)=>{i._idx=a}),this.notifyPlugins("afterLayout")}_updateDatasets(e){if(this.notifyPlugins("beforeDatasetsUpdate",{mode:e,cancelable:!0})!==!1){for(let r=0,n=this.data.datasets.length;r<n;++r)this.getDatasetMeta(r).controller.configure();for(let r=0,n=this.data.datasets.length;r<n;++r)this._updateDataset(r,ln(e)?e({datasetIndex:r}):e);this.notifyPlugins("afterDatasetsUpdate",{mode:e})}}_updateDataset(e,r){const n=this.getDatasetMeta(e),i={meta:n,index:e,mode:r,cancelable:!0};this.notifyPlugins("beforeDatasetUpdate",i)!==!1&&(n.controller._update(r),i.cancelable=!1,this.notifyPlugins("afterDatasetUpdate",i))}render(){this.notifyPlugins("beforeRender",{cancelable:!0})!==!1&&(Pi.has(this)?this.attached&&!Pi.running(this)&&Pi.start(this):(this.draw(),BA({chart:this})))}draw(){let e;if(this._resizeBeforeDraw){const{width:n,height:i}=this._resizeBeforeDraw;this._resize(n,i),this._resizeBeforeDraw=null}if(this.clear(),this.width<=0||this.height<=0||this.notifyPlugins("beforeDraw",{cancelable:!0})===!1)return;const r=this._layers;for(e=0;e<r.length&&r[e].z<=0;++e)r[e].draw(this.chartArea);for(this._drawDatasets();e<r.length;++e)r[e].draw(this.chartArea);this.notifyPlugins("afterDraw")}_getSortedDatasetMetas(e){const r=this._sortedMetasets,n=[];let i,a;for(i=0,a=r.length;i<a;++i){const s=r[i];(!e||s.visible)&&n.push(s)}return n}getSortedVisibleDatasetMetas(){return this._getSortedDatasetMetas(!0)}_drawDatasets(){if(this.notifyPlugins("beforeDatasetsDraw",{cancelable:!0})===!1)return;const e=this.getSortedVisibleDatasetMetas();for(let r=e.length-1;r>=0;--r)this._drawDataset(e[r]);this.notifyPlugins("afterDatasetsDraw")}_drawDataset(e){const r=this.ctx,n=e._clip,i=!n.disabled,a=ite(e,this.chartArea),s={meta:e,index:e.index,cancelable:!0};this.notifyPlugins("beforeDatasetDraw",s)!==!1&&(i&&nl(r,{left:n.left===!1?0:a.left-n.left,right:n.right===!1?this.width:a.right+n.right,top:n.top===!1?0:a.top-n.top,bottom:n.bottom===!1?this.height:a.bottom+n.bottom}),e.controller.draw(),i&&il(r),s.cancelable=!1,this.notifyPlugins("afterDatasetDraw",s))}isPointInArea(e){return qu(e,this.chartArea,this._minPadding)}getElementsAtEventForMode(e,r,n,i){const a=eee.modes[r];return typeof a=="function"?a(this,e,n,i):[]}getDatasetMeta(e){const r=this.data.datasets[e],n=this._metasets;let i=n.filter(a=>a&&a._dataset===r).pop();return i||(i={type:null,data:[],dataset:null,controller:null,hidden:null,xAxisID:null,yAxisID:null,order:r&&r.order||0,index:e,_dataset:r,_parsed:[],_sorted:!1},n.push(i)),i}getContext(){return this.$context||(this.$context=Ss(null,{chart:this,type:"chart"}))}getVisibleDatasetCount(){return this.getSortedVisibleDatasetMetas().length}isDatasetVisible(e){const r=this.data.datasets[e];if(!r)return!1;const n=this.getDatasetMeta(e);return typeof n.hidden=="boolean"?!n.hidden:!r.hidden}setDatasetVisibility(e,r){const n=this.getDatasetMeta(e);n.hidden=!r}toggleDataVisibility(e){this._hiddenIndices[e]=!this._hiddenIndices[e]}getDataVisibility(e){return!this._hiddenIndices[e]}_updateVisibility(e,r,n){const i=n?"show":"hide",a=this.getDatasetMeta(e),s=a.controller._resolveAnimations(void 0,i);Sn(r)?(a.data[r].hidden=!n,this.update()):(this.setDatasetVisibility(e,n),s.update(a,{visible:n}),this.update(o=>o.datasetIndex===e?i:void 0))}hide(e,r){this._updateVisibility(e,r,!1)}show(e,r){this._updateVisibility(e,r,!0)}_destroyDatasetMeta(e){const r=this._metasets[e];r&&r.controller&&r.controller._destroy(),delete this._metasets[e]}_stop(){let e,r;for(this.stop(),Pi.remove(this),e=0,r=this.data.datasets.length;e<r;++e)this._destroyDatasetMeta(e)}destroy(){this.notifyPlugins("beforeDestroy");const{canvas:e,ctx:r}=this;this._stop(),this.config.clearCache(),e&&(this.unbindEvents(),hA(e,r),this.platform.releaseContext(r),this.canvas=null,this.ctx=null),delete wf[this.id],this.notifyPlugins("afterDestroy")}toBase64Image(...e){return this.canvas.toDataURL(...e)}bindEvents(){this.bindUserEvents(),this.options.responsive?this.bindResponsiveEvents():this.attached=!0}bindUserEvents(){const e=this._listeners,r=this.platform,n=(a,s)=>{r.addEventListener(this,a,s),e[a]=s},i=(a,s,o)=>{a.offsetX=s,a.offsetY=o,this._eventHandler(a)};jt(this.options.events,a=>n(a,i))}bindResponsiveEvents(){this._responsiveListeners||(this._responsiveListeners={});const e=this._responsiveListeners,r=this.platform,n=(l,c)=>{r.addEventListener(this,l,c),e[l]=c},i=(l,c)=>{e[l]&&(r.removeEventListener(this,l,c),delete e[l])},a=(l,c)=>{this.canvas&&this.resize(l,c)};let s;const o=()=>{i("attach",o),this.attached=!0,this.resize(),n("resize",a),n("detach",s)};s=()=>{this.attached=!1,i("resize",a),this._stop(),this._resize(0,0),n("attach",o)},r.isAttached(this.canvas)?o():s()}unbindEvents(){jt(this._listeners,(e,r)=>{this.platform.removeEventListener(this,r,e)}),this._listeners={},jt(this._responsiveListeners,(e,r)=>{this.platform.removeEventListener(this,r,e)}),this._responsiveListeners=void 0}updateHoverStyle(e,r,n){const i=n?"set":"remove";let a,s,o,l;for(r==="dataset"&&(a=this.getDatasetMeta(e[0].datasetIndex),a.controller["_"+i+"DatasetHoverStyle"]()),o=0,l=e.length;o<l;++o){s=e[o];const c=s&&this.getDatasetMeta(s.datasetIndex).controller;c&&c[i+"HoverStyle"](s.element,s.datasetIndex,s.index)}}getActiveElements(){return this._active||[]}setActiveElements(e){const r=this._active||[],n=e.map(({datasetIndex:a,index:s})=>{const o=this.getDatasetMeta(a);if(!o)throw new Error("No dataset found at index "+a);return{datasetIndex:a,element:o.data[s],index:s}});!sd(n,r)&&(this._active=n,this._lastEvent=null,this._updateHoverStyles(n,r))}notifyPlugins(e,r,n){return this._plugins.notify(this,e,r,n)}isPluginEnabled(e){return this._plugins._cache.filter(r=>r.plugin.id===e).length===1}_updateHoverStyles(e,r,n){const i=this.options.hover,a=(l,c)=>l.filter(d=>!c.some(h=>d.datasetIndex===h.datasetIndex&&d.index===h.index)),s=a(r,e),o=n?e:a(e,r);s.length&&this.updateHoverStyle(s,i.mode,!1),o.length&&i.mode&&this.updateHoverStyle(o,i.mode,!0)}_eventHandler(e,r){const n={event:e,replay:r,cancelable:!0,inChartArea:this.isPointInArea(e)},i=s=>(s.options.events||this.options.events).includes(e.native.type);if(this.notifyPlugins("beforeEvent",n,i)===!1)return;const a=this._handleEvent(e,r,n.inChartArea);return n.cancelable=!1,this.notifyPlugins("afterEvent",n,i),(a||n.changed)&&this.render(),this}_handleEvent(e,r,n){const{_active:i=[],options:a}=this,s=r,o=this._getActiveElements(e,i,n,s),l=_J(e),c=nte(e,this._lastEvent,n,l);n&&(this._lastEvent=null,Ut(a.onHover,[e,o,this],this),l&&Ut(a.onClick,[e,o,this],this));const d=!sd(o,i);return(d||r)&&(this._active=o,this._updateHoverStyles(o,i,r)),this._lastEvent=c,d}_getActiveElements(e,r,n,i){if(e.type==="mouseout")return[];if(!n)return r;const a=this.options.hover;return this.getElementsAtEventForMode(e,a.mode,a,i)}},qe(oa,"defaults",lr),qe(oa,"instances",wf),qe(oa,"overrides",gs),qe(oa,"registry",ci),qe(oa,"version",Qee),qe(oa,"getChart",zA),oa);function VA(){return jt(us.instances,t=>t._plugins.invalidate())}function BP(t,e,r=e){t.lineCap=Xe(r.borderCapStyle,e.borderCapStyle),t.setLineDash(Xe(r.borderDash,e.borderDash)),t.lineDashOffset=Xe(r.borderDashOffset,e.borderDashOffset),t.lineJoin=Xe(r.borderJoinStyle,e.borderJoinStyle),t.lineWidth=Xe(r.borderWidth,e.borderWidth),t.strokeStyle=Xe(r.borderColor,e.borderColor)}function ate(t,e,r){t.lineTo(r.x,r.y)}function ste(t){return t.stepped?VJ:t.tension||t.cubicInterpolationMode==="monotone"?GJ:ate}function zP(t,e,r={}){const n=t.length,{start:i=0,end:a=n-1}=r,{start:s,end:o}=e,l=Math.max(i,s),c=Math.min(a,o),d=i<s&&a<s||i>o&&a>o;return{count:n,start:l,loop:e.loop,ilen:c<l&&!d?n+c-l:c-l}}function ote(t,e,r,n){const{points:i,options:a}=e,{count:s,start:o,loop:l,ilen:c}=zP(i,r,n),d=ste(a);let{move:h=!0,reverse:g}=n||{},m,v,b;for(m=0;m<=c;++m)v=i[(o+(g?c-m:m))%s],!v.skip&&(h?(t.moveTo(v.x,v.y),h=!1):d(t,b,v,g,a.stepped),b=v);return l&&(v=i[(o+(g?c:0))%s],d(t,b,v,g,a.stepped)),!!l}function ute(t,e,r,n){const i=e.points,{count:a,start:s,ilen:o}=zP(i,r,n),{move:l=!0,reverse:c}=n||{};let d=0,h=0,g,m,v,b,y,x;const w=E=>(s+(c?o-E:E))%a,S=()=>{b!==y&&(t.lineTo(d,y),t.lineTo(d,b),t.lineTo(d,x))};for(l&&(m=i[w(0)],t.moveTo(m.x,m.y)),g=0;g<=o;++g){if(m=i[w(g)],m.skip)continue;const E=m.x,C=m.y,I=E|0;I===v?(C<b?b=C:C>y&&(y=C),d=(h*d+E)/++h):(S(),t.lineTo(E,C),v=I,h=0,b=y=C),x=C}S()}function c0(t){const e=t.options,r=e.borderDash&&e.borderDash.length;return!t._decimated&&!t._loop&&!e.tension&&e.cubicInterpolationMode!=="monotone"&&!e.stepped&&!r?ute:ote}function lte(t){return t.stepped?EQ:t.tension||t.cubicInterpolationMode==="monotone"?OQ:Za}function cte(t,e,r,n){let i=e._path;i||(i=e._path=new Path2D,e.path(i,r,n)&&i.closePath()),BP(t,e.options),t.stroke(i)}function fte(t,e,r,n){const{segments:i,options:a}=e,s=c0(e);for(const o of i)BP(t,a,o.style),t.beginPath(),s(t,e,o,{start:r,end:r+n-1})&&t.closePath(),t.stroke()}const dte=typeof Path2D=="function";function hte(t,e,r,n){dte&&!e.options.segment?cte(t,e,r,n):fte(t,e,r,n)}class ya extends Bn{constructor(e){super(),this.animated=!0,this.options=void 0,this._chart=void 0,this._loop=void 0,this._fullLoop=void 0,this._path=void 0,this._points=void 0,this._segments=void 0,this._decimated=!1,this._pointsUpdated=!1,this._datasetIndex=void 0,e&&Object.assign(this,e)}updateControlPoints(e,r){const n=this.options;if((n.tension||n.cubicInterpolationMode==="monotone")&&!n.stepped&&!this._pointsUpdated){const i=n.spanGaps?this._loop:this._fullLoop;yQ(this._points,n,e,i,r),this._pointsUpdated=!0}}set points(e){this._points=e,delete this._segments,delete this._path,this._pointsUpdated=!1}get points(){return this._points}get segments(){return this._segments||(this._segments=PQ(this,this.options.segment))}first(){const e=this.segments,r=this.points;return e.length&&r[e[0].start]}last(){const e=this.segments,r=this.points,n=e.length;return n&&r[e[n-1].end]}interpolate(e,r){const n=this.options,i=e[r],a=this.points,s=MP(this,{property:r,start:i,end:i});if(!s.length)return;const o=[],l=lte(n);let c,d;for(c=0,d=s.length;c<d;++c){const{start:h,end:g}=s[c],m=a[h],v=a[g];if(m===v){o.push(m);continue}const b=Math.abs((i-m[r])/(v[r]-m[r])),y=l(m,v,b,n.stepped);y[r]=e[r],o.push(y)}return o.length===1?o[0]:o}pathSegment(e,r,n){return c0(this)(e,this,r,n)}path(e,r,n){const i=this.segments,a=c0(this);let s=this._loop;r=r||0,n=n||this.points.length-r;for(const o of i)s&=a(e,this,o,{start:r,end:r+n-1});return!!s}draw(e,r,n,i){const a=this.options||{};(this.points||[]).length&&a.borderWidth&&(e.save(),hte(e,this,n,i),e.restore()),this.animated&&(this._pointsUpdated=!1,this._path=void 0)}}qe(ya,"id","line"),qe(ya,"defaults",{borderCapStyle:"butt",borderDash:[],borderDashOffset:0,borderJoinStyle:"miter",borderWidth:3,capBezierPoints:!0,cubicInterpolationMode:"default",fill:!1,spanGaps:!1,stepped:!1,tension:0}),qe(ya,"defaultRoutes",{backgroundColor:"backgroundColor",borderColor:"borderColor"}),qe(ya,"descriptors",{_scriptable:!0,_indexable:e=>e!=="borderDash"&&e!=="fill"});function GA(t,e,r,n){const i=t.options,{[r]:a}=t.getProps([r],n);return Math.abs(e-a)<i.radius+i.hitRadius}class Tf extends Bn{constructor(r){super();qe(this,"parsed");qe(this,"skip");qe(this,"stop");this.options=void 0,this.parsed=void 0,this.skip=void 0,this.stop=void 0,r&&Object.assign(this,r)}inRange(r,n,i){const a=this.options,{x:s,y:o}=this.getProps(["x","y"],i);return Math.pow(r-s,2)+Math.pow(n-o,2)<Math.pow(a.hitRadius+a.radius,2)}inXRange(r,n){return GA(this,r,"x",n)}inYRange(r,n){return GA(this,r,"y",n)}getCenterPoint(r){const{x:n,y:i}=this.getProps(["x","y"],r);return{x:n,y:i}}size(r){r=r||this.options||{};let n=r.radius||0;n=Math.max(n,n&&r.hoverRadius||0);const i=n&&r.borderWidth||0;return(n+i)*2}draw(r,n){const i=this.options;this.skip||i.radius<.1||!qu(this,n,this.size(i)/2)||(r.strokeStyle=i.borderColor,r.lineWidth=i.borderWidth,r.fillStyle=i.backgroundColor,o0(r,i,this.x,this.y))}getRange(){const r=this.options||{};return r.radius+r.hitRadius}}qe(Tf,"id","point"),qe(Tf,"defaults",{borderWidth:1,hitRadius:1,hoverBorderWidth:1,hoverRadius:4,pointStyle:"circle",radius:3,rotation:0}),qe(Tf,"defaultRoutes",{backgroundColor:"backgroundColor",borderColor:"borderColor"});function pte(t,e,r){const n=t.segments,i=t.points,a=e.points,s=[];for(const o of n){let{start:l,end:c}=o;c=Xb(l,c,i);const d=f0(r,i[l],i[c],o.loop);if(!e.segments){s.push({source:o,target:d,start:i[l],end:i[c]});continue}const h=MP(e,d);for(const g of h){const m=f0(r,a[g.start],a[g.end],g.loop),v=DP(o,i,m);for(const b of v)s.push({source:b,target:g,start:{[r]:KA(d,m,"start",Math.max)},end:{[r]:KA(d,m,"end",Math.min)}})}}return s}function f0(t,e,r,n){if(n)return;let i=e[t],a=r[t];return t==="angle"&&(i=fi(i),a=fi(a)),{property:t,start:i,end:a}}function gte(t,e){const{x:r=null,y:n=null}=t||{},i=e.points,a=[];return e.segments.forEach(({start:s,end:o})=>{o=Xb(s,o,i);const l=i[s],c=i[o];n!==null?(a.push({x:l.x,y:n}),a.push({x:c.x,y:n})):r!==null&&(a.push({x:r,y:l.y}),a.push({x:r,y:c.y}))}),a}function Xb(t,e,r){for(;e>t;e--){const n=r[e];if(!isNaN(n.x)&&!isNaN(n.y))break}return e}function KA(t,e,r,n){return t&&e?n(t[r],e[r]):t?t[r]:e?e[r]:0}function VP(t,e){let r=[],n=!1;return Xt(t)?(n=!0,r=t):r=gte(t,e),r.length?new ya({points:r,options:{tension:0},_loop:n,_fullLoop:n}):null}function XA(t){return t&&t.fill!==!1}function mte(t,e,r){let i=t[e].fill;const a=[e];let s;if(!r)return i;for(;i!==!1&&a.indexOf(i)===-1;){if(!Ir(i))return i;if(s=t[i],!s)return!1;if(s.visible)return i;a.push(i),i=s.fill}return!1}function vte(t,e,r){const n=xte(t);if(it(n))return isNaN(n.value)?!1:n;let i=parseFloat(n);return Ir(i)&&Math.floor(i)===i?yte(n[0],e,i,r):["origin","start","end","stack","shape"].indexOf(n)>=0&&n}function yte(t,e,r,n){return(t==="-"||t==="+")&&(r=e+r),r===e||r<0||r>=n?!1:r}function bte(t,e){let r=null;return t==="start"?r=e.bottom:t==="end"?r=e.top:it(t)?r=e.getPixelForValue(t.value):e.getBasePixel&&(r=e.getBasePixel()),r}function _te(t,e,r){let n;return t==="start"?n=r:t==="end"?n=e.options.reverse?e.min:e.max:it(t)?n=t.value:n=e.getBaseValue(),n}function xte(t){const e=t.options,r=e.fill;let n=Xe(r&&r.target,r);return n===void 0&&(n=!!e.backgroundColor),n===!1||n===null?!1:n===!0?"origin":n}function wte(t){const{scale:e,index:r,line:n}=t,i=[],a=n.segments,s=n.points,o=Tte(e,r);o.push(VP({x:null,y:e.bottom},n));for(let l=0;l<a.length;l++){const c=a[l];for(let d=c.start;d<=c.end;d++)Ste(i,s[d],o)}return new ya({points:i,options:{}})}function Tte(t,e){const r=[],n=t.getMatchingVisibleMetas("line");for(let i=0;i<n.length;i++){const a=n[i];if(a.index===e)break;a.hidden||r.unshift(a.dataset)}return r}function Ste(t,e,r){const n=[];for(let i=0;i<r.length;i++){const a=r[i],{first:s,last:o,point:l}=Cte(a,e,"x");if(!(!l||s&&o)){if(s)n.unshift(l);else if(t.push(l),!o)break}}t.push(...n)}function Cte(t,e,r){const n=t.interpolate(e,r);if(!n)return{};const i=n[r],a=t.segments,s=t.points;let o=!1,l=!1;for(let c=0;c<a.length;c++){const d=a[c],h=s[d.start][r],g=s[d.end][r];if(eo(i,h,g)){o=i===h,l=i===g;break}}return{first:o,last:l,point:n}}class GP{constructor(e){this.x=e.x,this.y=e.y,this.radius=e.radius}pathSegment(e,r,n){const{x:i,y:a,radius:s}=this;return r=r||{start:0,end:Wn},e.arc(i,a,s,r.end,r.start,!0),!n.bounds}interpolate(e){const{x:r,y:n,radius:i}=this,a=e.angle;return{x:r+Math.cos(a)*i,y:n+Math.sin(a)*i,angle:a}}}function Ete(t){const{chart:e,fill:r,line:n}=t;if(Ir(r))return Ote(e,r);if(r==="stack")return wte(t);if(r==="shape")return!0;const i=Ate(t);return i instanceof GP?i:VP(i,n)}function Ote(t,e){const r=t.getDatasetMeta(e);return r&&t.isDatasetVisible(e)?r.dataset:null}function Ate(t){return(t.scale||{}).getPointPositionForValue?Rte(t):Ite(t)}function Ite(t){const{scale:e={},fill:r}=t,n=bte(r,e);if(Ir(n)){const i=e.isHorizontal();return{x:i?n:null,y:i?null:n}}return null}function Rte(t){const{scale:e,fill:r}=t,n=e.options,i=e.getLabels().length,a=n.reverse?e.max:e.min,s=_te(r,e,a),o=[];if(n.grid.circular){const l=e.getPointPositionForValue(0,a);return new GP({x:l.x,y:l.y,radius:e.getDistanceFromCenterForValue(s)})}for(let l=0;l<i;++l)o.push(e.getPointPositionForValue(l,s));return o}function xy(t,e,r){const n=Ete(e),{line:i,scale:a,axis:s}=e,o=i.options,l=o.fill,c=o.backgroundColor,{above:d=c,below:h=c}=l||{};n&&i.points.length&&(nl(t,r),Dte(t,{line:i,target:n,above:d,below:h,area:r,scale:a,axis:s}),il(t))}function Dte(t,e){const{line:r,target:n,above:i,below:a,area:s,scale:o}=e,l=r._loop?"angle":e.axis;t.save(),l==="x"&&a!==i&&(YA(t,n,s.top),ZA(t,{line:r,target:n,color:i,scale:o,property:l}),t.restore(),t.save(),YA(t,n,s.bottom)),ZA(t,{line:r,target:n,color:a,scale:o,property:l}),t.restore()}function YA(t,e,r){const{segments:n,points:i}=e;let a=!0,s=!1;t.beginPath();for(const o of n){const{start:l,end:c}=o,d=i[l],h=i[Xb(l,c,i)];a?(t.moveTo(d.x,d.y),a=!1):(t.lineTo(d.x,r),t.lineTo(d.x,d.y)),s=!!e.pathSegment(t,o,{move:s}),s?t.closePath():t.lineTo(h.x,r)}t.lineTo(e.first().x,r),t.closePath(),t.clip()}function ZA(t,e){const{line:r,target:n,property:i,color:a,scale:s}=e,o=pte(r,n,i);for(const{source:l,target:c,start:d,end:h}of o){const{style:{backgroundColor:g=a}={}}=l,m=n!==!0;t.save(),t.fillStyle=g,Mte(t,s,m&&f0(i,d,h)),t.beginPath();const v=!!r.pathSegment(t,l);let b;if(m){v?t.closePath():JA(t,n,h,i);const y=!!n.pathSegment(t,c,{move:v,reverse:!0});b=v&&y,b||JA(t,n,d,i)}t.closePath(),t.fill(b?"evenodd":"nonzero"),t.restore()}}function Mte(t,e,r){const{top:n,bottom:i}=e.chart.chartArea,{property:a,start:s,end:o}=r||{};a==="x"&&(t.beginPath(),t.rect(s,n,o-s,i-n),t.clip())}function JA(t,e,r,n){const i=e.interpolate(r,n);i&&t.lineTo(i.x,i.y)}var Pte={id:"filler",afterDatasetsUpdate(t,e,r){const n=(t.data.datasets||[]).length,i=[];let a,s,o,l;for(s=0;s<n;++s)a=t.getDatasetMeta(s),o=a.dataset,l=null,o&&o.options&&o instanceof ya&&(l={visible:t.isDatasetVisible(s),index:s,fill:vte(o,s,n),chart:t,axis:a.controller.options.indexAxis,scale:a.vScale,line:o}),a.$filler=l,i.push(l);for(s=0;s<n;++s)l=i[s],!(!l||l.fill===!1)&&(l.fill=mte(i,s,r.propagate))},beforeDraw(t,e,r){const n=r.drawTime==="beforeDraw",i=t.getSortedVisibleDatasetMetas(),a=t.chartArea;for(let s=i.length-1;s>=0;--s){const o=i[s].$filler;o&&(o.line.updateControlPoints(a,o.axis),n&&o.fill&&xy(t.ctx,o,a))}},beforeDatasetsDraw(t,e,r){if(r.drawTime!=="beforeDatasetsDraw")return;const n=t.getSortedVisibleDatasetMetas();for(let i=n.length-1;i>=0;--i){const a=n[i].$filler;XA(a)&&xy(t.ctx,a,t.chartArea)}},beforeDatasetDraw(t,e,r){const n=e.meta.$filler;!XA(n)||r.drawTime!=="beforeDatasetDraw"||xy(t.ctx,n,t.chartArea)},defaults:{propagate:!0,drawTime:"beforeDatasetDraw"}};const QA=(t,e)=>{let{boxHeight:r=e,boxWidth:n=e}=t;return t.usePointStyle&&(r=Math.min(r,e),n=t.pointStyleWidth||Math.min(n,e)),{boxWidth:n,boxHeight:r,itemHeight:Math.max(e,r)}},Lte=(t,e)=>t!==null&&e!==null&&t.datasetIndex===e.datasetIndex&&t.index===e.index;class eI extends Bn{constructor(e){super(),this._added=!1,this.legendHitBoxes=[],this._hoveredItem=null,this.doughnutMode=!1,this.chart=e.chart,this.options=e.options,this.ctx=e.ctx,this.legendItems=void 0,this.columnSizes=void 0,this.lineWidths=void 0,this.maxHeight=void 0,this.maxWidth=void 0,this.top=void 0,this.bottom=void 0,this.left=void 0,this.right=void 0,this.height=void 0,this.width=void 0,this._margins=void 0,this.position=void 0,this.weight=void 0,this.fullSize=void 0}update(e,r,n){this.maxWidth=e,this.maxHeight=r,this._margins=n,this.setDimensions(),this.buildLabels(),this.fit()}setDimensions(){this.isHorizontal()?(this.width=this.maxWidth,this.left=this._margins.left,this.right=this.width):(this.height=this.maxHeight,this.top=this._margins.top,this.bottom=this.height)}buildLabels(){const e=this.options.labels||{};let r=Ut(e.generateLabels,[this.chart],this)||[];e.filter&&(r=r.filter(n=>e.filter(n,this.chart.data))),e.sort&&(r=r.sort((n,i)=>e.sort(n,i,this.chart.data))),this.options.reverse&&r.reverse(),this.legendItems=r}fit(){const{options:e,ctx:r}=this;if(!e.display){this.width=this.height=0;return}const n=e.labels,i=Or(n.font),a=i.size,s=this._computeTitleHeight(),{boxWidth:o,itemHeight:l}=QA(n,a);let c,d;r.font=i.string,this.isHorizontal()?(c=this.maxWidth,d=this._fitRows(s,a,o,l)+10):(d=this.maxHeight,c=this._fitCols(s,i,o,l)+10),this.width=Math.min(c,e.maxWidth||this.maxWidth),this.height=Math.min(d,e.maxHeight||this.maxHeight)}_fitRows(e,r,n,i){const{ctx:a,maxWidth:s,options:{labels:{padding:o}}}=this,l=this.legendHitBoxes=[],c=this.lineWidths=[0],d=i+o;let h=e;a.textAlign="left",a.textBaseline="middle";let g=-1,m=-d;return this.legendItems.forEach((v,b)=>{const y=n+r/2+a.measureText(v.text).width;(b===0||c[c.length-1]+y+2*o>s)&&(h+=d,c[c.length-(b>0?0:1)]=0,m+=d,g++),l[b]={left:0,top:m,row:g,width:y,height:i},c[c.length-1]+=y+o}),h}_fitCols(e,r,n,i){const{ctx:a,maxHeight:s,options:{labels:{padding:o}}}=this,l=this.legendHitBoxes=[],c=this.columnSizes=[],d=s-e;let h=o,g=0,m=0,v=0,b=0;return this.legendItems.forEach((y,x)=>{const{itemWidth:w,itemHeight:S}=Nte(n,r,a,y,i);x>0&&m+S+2*o>d&&(h+=g+o,c.push({width:g,height:m}),v+=g+o,b++,g=m=0),l[x]={left:v,top:m,col:b,width:w,height:S},g=Math.max(g,w),m+=S+o}),h+=g,c.push({width:g,height:m}),h}adjustHitBoxes(){if(!this.options.display)return;const e=this._computeTitleHeight(),{legendHitBoxes:r,options:{align:n,labels:{padding:i},rtl:a}}=this,s=io(a,this.left,this.width);if(this.isHorizontal()){let o=0,l=xn(n,this.left+i,this.right-this.lineWidths[o]);for(const c of r)o!==c.row&&(o=c.row,l=xn(n,this.left+i,this.right-this.lineWidths[o])),c.top+=this.top+e+i,c.left=s.leftForLtr(s.x(l),c.width),l+=c.width+i}else{let o=0,l=xn(n,this.top+e+i,this.bottom-this.columnSizes[o].height);for(const c of r)c.col!==o&&(o=c.col,l=xn(n,this.top+e+i,this.bottom-this.columnSizes[o].height)),c.top=l,c.left+=this.left+i,c.left=s.leftForLtr(s.x(c.left),c.width),l+=c.height+i}}isHorizontal(){return this.options.position==="top"||this.options.position==="bottom"}draw(){if(this.options.display){const e=this.ctx;nl(e,this),this._draw(),il(e)}}_draw(){const{options:e,columnSizes:r,lineWidths:n,ctx:i}=this,{align:a,labels:s}=e,o=lr.color,l=io(e.rtl,this.left,this.width),c=Or(s.font),{padding:d}=s,h=c.size,g=h/2;let m;this.drawTitle(),i.textAlign=l.textAlign("left"),i.textBaseline="middle",i.lineWidth=.5,i.font=c.string;const{boxWidth:v,boxHeight:b,itemHeight:y}=QA(s,h),x=function(I,T,D){if(isNaN(v)||v<=0||isNaN(b)||b<0)return;i.save();const P=Xe(D.lineWidth,1);if(i.fillStyle=Xe(D.fillStyle,o),i.lineCap=Xe(D.lineCap,"butt"),i.lineDashOffset=Xe(D.lineDashOffset,0),i.lineJoin=Xe(D.lineJoin,"miter"),i.lineWidth=P,i.strokeStyle=Xe(D.strokeStyle,o),i.setLineDash(Xe(D.lineDash,[])),s.usePointStyle){const L={radius:b*Math.SQRT2/2,pointStyle:D.pointStyle,rotation:D.rotation,borderWidth:P},F=l.xPlus(I,v/2),H=T+g;_P(i,L,F,H,s.pointStyleWidth&&v)}else{const L=T+Math.max((h-b)/2,0),F=l.leftForLtr(I,v),H=no(D.borderRadius);i.beginPath(),Object.values(H).some(X=>X!==0)?dd(i,{x:F,y:L,w:v,h:b,radius:H}):i.rect(F,L,v,b),i.fill(),P!==0&&i.stroke()}i.restore()},w=function(I,T,D){fd(i,D.text,I,T+y/2,c,{strikethrough:D.hidden,textAlign:l.textAlign(D.textAlign)})},S=this.isHorizontal(),E=this._computeTitleHeight();S?m={x:xn(a,this.left+d,this.right-n[0]),y:this.top+d+E,line:0}:m={x:this.left+d,y:xn(a,this.top+E+d,this.bottom-r[0].height),line:0},AP(this.ctx,e.textDirection);const C=y+d;this.legendItems.forEach((I,T)=>{i.strokeStyle=I.fontColor,i.fillStyle=I.fontColor;const D=i.measureText(I.text).width,P=l.textAlign(I.textAlign||(I.textAlign=s.textAlign)),L=v+g+D;let F=m.x,H=m.y;l.setWidth(this.width),S?T>0&&F+L+d>this.right&&(H=m.y+=C,m.line++,F=m.x=xn(a,this.left+d,this.right-n[m.line])):T>0&&H+C>this.bottom&&(F=m.x=F+r[m.line].width+d,m.line++,H=m.y=xn(a,this.top+E+d,this.bottom-r[m.line].height));const X=l.x(F);if(x(X,H,I),F=PJ(P,F+v+g,S?F+L:this.right,e.rtl),w(l.x(F),H,I),S)m.x+=L+d;else if(typeof I.text!="string"){const ee=c.lineHeight;m.y+=KP(I,ee)+d}else m.y+=C}),IP(this.ctx,e.textDirection)}drawTitle(){const e=this.options,r=e.title,n=Or(r.font),i=Kr(r.padding);if(!r.display)return;const a=io(e.rtl,this.left,this.width),s=this.ctx,o=r.position,l=n.size/2,c=i.top+l;let d,h=this.left,g=this.width;if(this.isHorizontal())g=Math.max(...this.lineWidths),d=this.top+c,h=xn(e.align,h,this.right-g);else{const v=this.columnSizes.reduce((b,y)=>Math.max(b,y.height),0);d=c+xn(e.align,this.top,this.bottom-v-e.labels.padding-this._computeTitleHeight())}const m=xn(o,h,h+g);s.textAlign=a.textAlign(vP(o)),s.textBaseline="middle",s.strokeStyle=r.color,s.fillStyle=r.color,s.font=n.string,fd(s,r.text,m,d,n)}_computeTitleHeight(){const e=this.options.title,r=Or(e.font),n=Kr(e.padding);return e.display?r.lineHeight+n.height:0}_getLegendItemAt(e,r){let n,i,a;if(eo(e,this.left,this.right)&&eo(r,this.top,this.bottom)){for(a=this.legendHitBoxes,n=0;n<a.length;++n)if(i=a[n],eo(e,i.left,i.left+i.width)&&eo(r,i.top,i.top+i.height))return this.legendItems[n]}return null}handleEvent(e){const r=this.options;if(!jte(e.type,r))return;const n=this._getLegendItemAt(e.x,e.y);if(e.type==="mousemove"||e.type==="mouseout"){const i=this._hoveredItem,a=Lte(i,n);i&&!a&&Ut(r.onLeave,[e,i,this],this),this._hoveredItem=n,n&&!a&&Ut(r.onHover,[e,n,this],this)}else n&&Ut(r.onClick,[e,n,this],this)}}function Nte(t,e,r,n,i){const a=Fte(n,t,e,r),s=kte(i,n,e.lineHeight);return{itemWidth:a,itemHeight:s}}function Fte(t,e,r,n){let i=t.text;return i&&typeof i!="string"&&(i=i.reduce((a,s)=>a.length>s.length?a:s)),e+r.size/2+n.measureText(i).width}function kte(t,e,r){let n=t;return typeof e.text!="string"&&(n=KP(e,r)),n}function KP(t,e){const r=t.text?t.text.length:0;return e*r}function jte(t,e){return!!((t==="mousemove"||t==="mouseout")&&(e.onHover||e.onLeave)||e.onClick&&(t==="click"||t==="mouseup"))}var $te={id:"legend",_element:eI,start(t,e,r){const n=t.legend=new eI({ctx:t.ctx,options:r,chart:t});va.configure(t,n,r),va.addBox(t,n)},stop(t){va.removeBox(t,t.legend),delete t.legend},beforeUpdate(t,e,r){const n=t.legend;va.configure(t,n,r),n.options=r},afterUpdate(t){const e=t.legend;e.buildLabels(),e.adjustHitBoxes()},afterEvent(t,e){e.replay||t.legend.handleEvent(e.event)},defaults:{display:!0,position:"top",align:"center",fullSize:!0,reverse:!1,weight:1e3,onClick(t,e,r){const n=e.datasetIndex,i=r.chart;i.isDatasetVisible(n)?(i.hide(n),e.hidden=!0):(i.show(n),e.hidden=!1)},onHover:null,onLeave:null,labels:{color:t=>t.chart.options.color,boxWidth:40,padding:10,generateLabels(t){const e=t.data.datasets,{labels:{usePointStyle:r,pointStyle:n,textAlign:i,color:a,useBorderRadius:s,borderRadius:o}}=t.legend.options;return t._getSortedDatasetMetas().map(l=>{const c=l.controller.getStyle(r?0:void 0),d=Kr(c.borderWidth);return{text:e[l.index].label,fillStyle:c.backgroundColor,fontColor:a,hidden:!l.visible,lineCap:c.borderCapStyle,lineDash:c.borderDash,lineDashOffset:c.borderDashOffset,lineJoin:c.borderJoinStyle,lineWidth:(d.width+d.height)/4,strokeStyle:c.borderColor,pointStyle:n||c.pointStyle,rotation:c.rotation,textAlign:i||c.textAlign,borderRadius:s&&(o||c.borderRadius),datasetIndex:l.index}},this)}},title:{color:t=>t.chart.options.color,display:!1,position:"center",text:""}},descriptors:{_scriptable:t=>!t.startsWith("on"),labels:{_scriptable:t=>!["generateLabels","filter","sort"].includes(t)}}};const _u={average(t){if(!t.length)return!1;let e,r,n=0,i=0,a=0;for(e=0,r=t.length;e<r;++e){const s=t[e].element;if(s&&s.hasValue()){const o=s.tooltipPosition();n+=o.x,i+=o.y,++a}}return{x:n/a,y:i/a}},nearest(t,e){if(!t.length)return!1;let r=e.x,n=e.y,i=Number.POSITIVE_INFINITY,a,s,o;for(a=0,s=t.length;a<s;++a){const l=t[a].element;if(l&&l.hasValue()){const c=l.getCenterPoint(),d=go(e,c);d<i&&(i=d,o=l)}}if(o){const l=o.tooltipPosition();r=l.x,n=l.y}return{x:r,y:n}}};function li(t,e){return e&&(Xt(e)?Array.prototype.push.apply(t,e):t.push(e)),t}function Li(t){return(typeof t=="string"||t instanceof String)&&t.indexOf(`
|
|
112
|
+
`)>-1?t.split(`
|
|
113
|
+
`):t}function Ute(t,e){const{element:r,datasetIndex:n,index:i}=e,a=t.getDatasetMeta(n).controller,{label:s,value:o}=a.getLabelAndValue(i);return{chart:t,label:s,parsed:a.getParsed(i),raw:t.data.datasets[n].data[i],formattedValue:o,dataset:a.getDataset(),dataIndex:i,datasetIndex:n,element:r}}function tI(t,e){const r=t.chart.ctx,{body:n,footer:i,title:a}=t,{boxWidth:s,boxHeight:o}=e,l=Or(e.bodyFont),c=Or(e.titleFont),d=Or(e.footerFont),h=a.length,g=i.length,m=n.length,v=Kr(e.padding);let b=v.height,y=0,x=n.reduce((E,C)=>E+C.before.length+C.lines.length+C.after.length,0);if(x+=t.beforeBody.length+t.afterBody.length,h&&(b+=h*c.lineHeight+(h-1)*e.titleSpacing+e.titleMarginBottom),x){const E=e.displayColors?Math.max(o,l.lineHeight):l.lineHeight;b+=m*E+(x-m)*l.lineHeight+(x-1)*e.bodySpacing}g&&(b+=e.footerMarginTop+g*d.lineHeight+(g-1)*e.footerSpacing);let w=0;const S=function(E){y=Math.max(y,r.measureText(E).width+w)};return r.save(),r.font=c.string,jt(t.title,S),r.font=l.string,jt(t.beforeBody.concat(t.afterBody),S),w=e.displayColors?s+2+e.boxPadding:0,jt(n,E=>{jt(E.before,S),jt(E.lines,S),jt(E.after,S)}),w=0,r.font=d.string,jt(t.footer,S),r.restore(),y+=v.width,{width:y,height:b}}function qte(t,e){const{y:r,height:n}=e;return r<n/2?"top":r>t.height-n/2?"bottom":"center"}function Hte(t,e,r,n){const{x:i,width:a}=n,s=r.caretSize+r.caretPadding;if(t==="left"&&i+a+s>e.width||t==="right"&&i-a-s<0)return!0}function Wte(t,e,r,n){const{x:i,width:a}=r,{width:s,chartArea:{left:o,right:l}}=t;let c="center";return n==="center"?c=i<=(o+l)/2?"left":"right":i<=a/2?c="left":i>=s-a/2&&(c="right"),Hte(c,t,e,r)&&(c="center"),c}function rI(t,e,r){const n=r.yAlign||e.yAlign||qte(t,r);return{xAlign:r.xAlign||e.xAlign||Wte(t,e,r,n),yAlign:n}}function Bte(t,e){let{x:r,width:n}=t;return e==="right"?r-=n:e==="center"&&(r-=n/2),r}function zte(t,e,r){let{y:n,height:i}=t;return e==="top"?n+=r:e==="bottom"?n-=i+r:n-=i/2,n}function nI(t,e,r,n){const{caretSize:i,caretPadding:a,cornerRadius:s}=t,{xAlign:o,yAlign:l}=r,c=i+a,{topLeft:d,topRight:h,bottomLeft:g,bottomRight:m}=no(s);let v=Bte(e,o);const b=zte(e,l,c);return l==="center"?o==="left"?v+=c:o==="right"&&(v-=c):o==="left"?v-=Math.max(d,g)+i:o==="right"&&(v+=Math.max(h,m)+i),{x:Hn(v,0,n.width-e.width),y:Hn(b,0,n.height-e.height)}}function ff(t,e,r){const n=Kr(r.padding);return e==="center"?t.x+t.width/2:e==="right"?t.x+t.width-n.right:t.x+n.left}function iI(t){return li([],Li(t))}function Vte(t,e,r){return Ss(t,{tooltip:e,tooltipItems:r,type:"tooltip"})}function aI(t,e){const r=e&&e.dataset&&e.dataset.tooltip&&e.dataset.tooltip.callbacks;return r?t.override(r):t}const XP={beforeTitle:Mi,title(t){if(t.length>0){const e=t[0],r=e.chart.data.labels,n=r?r.length:0;if(this&&this.options&&this.options.mode==="dataset")return e.dataset.label||"";if(e.label)return e.label;if(n>0&&e.dataIndex<n)return r[e.dataIndex]}return""},afterTitle:Mi,beforeBody:Mi,beforeLabel:Mi,label(t){if(this&&this.options&&this.options.mode==="dataset")return t.label+": "+t.formattedValue||t.formattedValue;let e=t.dataset.label||"";e&&(e+=": ");const r=t.formattedValue;return ur(r)||(e+=r),e},labelColor(t){const r=t.chart.getDatasetMeta(t.datasetIndex).controller.getStyle(t.dataIndex);return{borderColor:r.borderColor,backgroundColor:r.backgroundColor,borderWidth:r.borderWidth,borderDash:r.borderDash,borderDashOffset:r.borderDashOffset,borderRadius:0}},labelTextColor(){return this.options.bodyColor},labelPointStyle(t){const r=t.chart.getDatasetMeta(t.datasetIndex).controller.getStyle(t.dataIndex);return{pointStyle:r.pointStyle,rotation:r.rotation}},afterLabel:Mi,afterBody:Mi,beforeFooter:Mi,footer:Mi,afterFooter:Mi};function nn(t,e,r,n){const i=t[e].call(r,n);return typeof i>"u"?XP[e].call(r,n):i}class d0 extends Bn{constructor(e){super(),this.opacity=0,this._active=[],this._eventPosition=void 0,this._size=void 0,this._cachedAnimations=void 0,this._tooltipItems=[],this.$animations=void 0,this.$context=void 0,this.chart=e.chart,this.options=e.options,this.dataPoints=void 0,this.title=void 0,this.beforeBody=void 0,this.body=void 0,this.afterBody=void 0,this.footer=void 0,this.xAlign=void 0,this.yAlign=void 0,this.x=void 0,this.y=void 0,this.height=void 0,this.width=void 0,this.caretX=void 0,this.caretY=void 0,this.labelColors=void 0,this.labelPointStyles=void 0,this.labelTextColors=void 0}initialize(e){this.options=e,this._cachedAnimations=void 0,this.$context=void 0}_resolveAnimations(){const e=this._cachedAnimations;if(e)return e;const r=this.chart,n=this.options.setContext(this.getContext()),i=n.enabled&&r.options.animation&&n.animations,a=new Gb(this.chart,i);return i._cacheable&&(this._cachedAnimations=Object.freeze(a)),a}getContext(){return this.$context||(this.$context=Vte(this.chart.getContext(),this,this._tooltipItems))}getTitle(e,r){const{callbacks:n}=r,i=nn(n,"beforeTitle",this,e),a=nn(n,"title",this,e),s=nn(n,"afterTitle",this,e);let o=[];return o=li(o,Li(i)),o=li(o,Li(a)),o=li(o,Li(s)),o}getBeforeBody(e,r){return iI(nn(r.callbacks,"beforeBody",this,e))}getBody(e,r){const{callbacks:n}=r,i=[];return jt(e,a=>{const s={before:[],lines:[],after:[]},o=aI(n,a);li(s.before,Li(nn(o,"beforeLabel",this,a))),li(s.lines,nn(o,"label",this,a)),li(s.after,Li(nn(o,"afterLabel",this,a))),i.push(s)}),i}getAfterBody(e,r){return iI(nn(r.callbacks,"afterBody",this,e))}getFooter(e,r){const{callbacks:n}=r,i=nn(n,"beforeFooter",this,e),a=nn(n,"footer",this,e),s=nn(n,"afterFooter",this,e);let o=[];return o=li(o,Li(i)),o=li(o,Li(a)),o=li(o,Li(s)),o}_createItems(e){const r=this._active,n=this.chart.data,i=[],a=[],s=[];let o=[],l,c;for(l=0,c=r.length;l<c;++l)o.push(Ute(this.chart,r[l]));return e.filter&&(o=o.filter((d,h,g)=>e.filter(d,h,g,n))),e.itemSort&&(o=o.sort((d,h)=>e.itemSort(d,h,n))),jt(o,d=>{const h=aI(e.callbacks,d);i.push(nn(h,"labelColor",this,d)),a.push(nn(h,"labelPointStyle",this,d)),s.push(nn(h,"labelTextColor",this,d))}),this.labelColors=i,this.labelPointStyles=a,this.labelTextColors=s,this.dataPoints=o,o}update(e,r){const n=this.options.setContext(this.getContext()),i=this._active;let a,s=[];if(!i.length)this.opacity!==0&&(a={opacity:0});else{const o=_u[n.position].call(this,i,this._eventPosition);s=this._createItems(n),this.title=this.getTitle(s,n),this.beforeBody=this.getBeforeBody(s,n),this.body=this.getBody(s,n),this.afterBody=this.getAfterBody(s,n),this.footer=this.getFooter(s,n);const l=this._size=tI(this,n),c=Object.assign({},o,l),d=rI(this.chart,n,c),h=nI(n,c,d,this.chart);this.xAlign=d.xAlign,this.yAlign=d.yAlign,a={opacity:1,x:h.x,y:h.y,width:l.width,height:l.height,caretX:o.x,caretY:o.y}}this._tooltipItems=s,this.$context=void 0,a&&this._resolveAnimations().update(this,a),e&&n.external&&n.external.call(this,{chart:this.chart,tooltip:this,replay:r})}drawCaret(e,r,n,i){const a=this.getCaretPosition(e,n,i);r.lineTo(a.x1,a.y1),r.lineTo(a.x2,a.y2),r.lineTo(a.x3,a.y3)}getCaretPosition(e,r,n){const{xAlign:i,yAlign:a}=this,{caretSize:s,cornerRadius:o}=n,{topLeft:l,topRight:c,bottomLeft:d,bottomRight:h}=no(o),{x:g,y:m}=e,{width:v,height:b}=r;let y,x,w,S,E,C;return a==="center"?(E=m+b/2,i==="left"?(y=g,x=y-s,S=E+s,C=E-s):(y=g+v,x=y+s,S=E-s,C=E+s),w=y):(i==="left"?x=g+Math.max(l,d)+s:i==="right"?x=g+v-Math.max(c,h)-s:x=this.caretX,a==="top"?(S=m,E=S-s,y=x-s,w=x+s):(S=m+b,E=S+s,y=x+s,w=x-s),C=S),{x1:y,x2:x,x3:w,y1:S,y2:E,y3:C}}drawTitle(e,r,n){const i=this.title,a=i.length;let s,o,l;if(a){const c=io(n.rtl,this.x,this.width);for(e.x=ff(this,n.titleAlign,n),r.textAlign=c.textAlign(n.titleAlign),r.textBaseline="middle",s=Or(n.titleFont),o=n.titleSpacing,r.fillStyle=n.titleColor,r.font=s.string,l=0;l<a;++l)r.fillText(i[l],c.x(e.x),e.y+s.lineHeight/2),e.y+=s.lineHeight+o,l+1===a&&(e.y+=n.titleMarginBottom-o)}}_drawColorBox(e,r,n,i,a){const s=this.labelColors[n],o=this.labelPointStyles[n],{boxHeight:l,boxWidth:c}=a,d=Or(a.bodyFont),h=ff(this,"left",a),g=i.x(h),m=l<d.lineHeight?(d.lineHeight-l)/2:0,v=r.y+m;if(a.usePointStyle){const b={radius:Math.min(c,l)/2,pointStyle:o.pointStyle,rotation:o.rotation,borderWidth:1},y=i.leftForLtr(g,c)+c/2,x=v+l/2;e.strokeStyle=a.multiKeyBackground,e.fillStyle=a.multiKeyBackground,o0(e,b,y,x),e.strokeStyle=s.borderColor,e.fillStyle=s.backgroundColor,o0(e,b,y,x)}else{e.lineWidth=it(s.borderWidth)?Math.max(...Object.values(s.borderWidth)):s.borderWidth||1,e.strokeStyle=s.borderColor,e.setLineDash(s.borderDash||[]),e.lineDashOffset=s.borderDashOffset||0;const b=i.leftForLtr(g,c),y=i.leftForLtr(i.xPlus(g,1),c-2),x=no(s.borderRadius);Object.values(x).some(w=>w!==0)?(e.beginPath(),e.fillStyle=a.multiKeyBackground,dd(e,{x:b,y:v,w:c,h:l,radius:x}),e.fill(),e.stroke(),e.fillStyle=s.backgroundColor,e.beginPath(),dd(e,{x:y,y:v+1,w:c-2,h:l-2,radius:x}),e.fill()):(e.fillStyle=a.multiKeyBackground,e.fillRect(b,v,c,l),e.strokeRect(b,v,c,l),e.fillStyle=s.backgroundColor,e.fillRect(y,v+1,c-2,l-2))}e.fillStyle=this.labelTextColors[n]}drawBody(e,r,n){const{body:i}=this,{bodySpacing:a,bodyAlign:s,displayColors:o,boxHeight:l,boxWidth:c,boxPadding:d}=n,h=Or(n.bodyFont);let g=h.lineHeight,m=0;const v=io(n.rtl,this.x,this.width),b=function(D){r.fillText(D,v.x(e.x+m),e.y+g/2),e.y+=g+a},y=v.textAlign(s);let x,w,S,E,C,I,T;for(r.textAlign=s,r.textBaseline="middle",r.font=h.string,e.x=ff(this,y,n),r.fillStyle=n.bodyColor,jt(this.beforeBody,b),m=o&&y!=="right"?s==="center"?c/2+d:c+2+d:0,E=0,I=i.length;E<I;++E){for(x=i[E],w=this.labelTextColors[E],r.fillStyle=w,jt(x.before,b),S=x.lines,o&&S.length&&(this._drawColorBox(r,e,E,v,n),g=Math.max(h.lineHeight,l)),C=0,T=S.length;C<T;++C)b(S[C]),g=h.lineHeight;jt(x.after,b)}m=0,g=h.lineHeight,jt(this.afterBody,b),e.y-=a}drawFooter(e,r,n){const i=this.footer,a=i.length;let s,o;if(a){const l=io(n.rtl,this.x,this.width);for(e.x=ff(this,n.footerAlign,n),e.y+=n.footerMarginTop,r.textAlign=l.textAlign(n.footerAlign),r.textBaseline="middle",s=Or(n.footerFont),r.fillStyle=n.footerColor,r.font=s.string,o=0;o<a;++o)r.fillText(i[o],l.x(e.x),e.y+s.lineHeight/2),e.y+=s.lineHeight+n.footerSpacing}}drawBackground(e,r,n,i){const{xAlign:a,yAlign:s}=this,{x:o,y:l}=e,{width:c,height:d}=n,{topLeft:h,topRight:g,bottomLeft:m,bottomRight:v}=no(i.cornerRadius);r.fillStyle=i.backgroundColor,r.strokeStyle=i.borderColor,r.lineWidth=i.borderWidth,r.beginPath(),r.moveTo(o+h,l),s==="top"&&this.drawCaret(e,r,n,i),r.lineTo(o+c-g,l),r.quadraticCurveTo(o+c,l,o+c,l+g),s==="center"&&a==="right"&&this.drawCaret(e,r,n,i),r.lineTo(o+c,l+d-v),r.quadraticCurveTo(o+c,l+d,o+c-v,l+d),s==="bottom"&&this.drawCaret(e,r,n,i),r.lineTo(o+m,l+d),r.quadraticCurveTo(o,l+d,o,l+d-m),s==="center"&&a==="left"&&this.drawCaret(e,r,n,i),r.lineTo(o,l+h),r.quadraticCurveTo(o,l,o+h,l),r.closePath(),r.fill(),i.borderWidth>0&&r.stroke()}_updateAnimationTarget(e){const r=this.chart,n=this.$animations,i=n&&n.x,a=n&&n.y;if(i||a){const s=_u[e.position].call(this,this._active,this._eventPosition);if(!s)return;const o=this._size=tI(this,e),l=Object.assign({},s,this._size),c=rI(r,e,l),d=nI(e,l,c,r);(i._to!==d.x||a._to!==d.y)&&(this.xAlign=c.xAlign,this.yAlign=c.yAlign,this.width=o.width,this.height=o.height,this.caretX=s.x,this.caretY=s.y,this._resolveAnimations().update(this,d))}}_willRender(){return!!this.opacity}draw(e){const r=this.options.setContext(this.getContext());let n=this.opacity;if(!n)return;this._updateAnimationTarget(r);const i={width:this.width,height:this.height},a={x:this.x,y:this.y};n=Math.abs(n)<.001?0:n;const s=Kr(r.padding),o=this.title.length||this.beforeBody.length||this.body.length||this.afterBody.length||this.footer.length;r.enabled&&o&&(e.save(),e.globalAlpha=n,this.drawBackground(a,e,i,r),AP(e,r.textDirection),a.y+=s.top,this.drawTitle(a,e,r),this.drawBody(a,e,r),this.drawFooter(a,e,r),IP(e,r.textDirection),e.restore())}getActiveElements(){return this._active||[]}setActiveElements(e,r){const n=this._active,i=e.map(({datasetIndex:o,index:l})=>{const c=this.chart.getDatasetMeta(o);if(!c)throw new Error("Cannot find a dataset at index "+o);return{datasetIndex:o,element:c.data[l],index:l}}),a=!sd(n,i),s=this._positionChanged(i,r);(a||s)&&(this._active=i,this._eventPosition=r,this._ignoreReplayEvents=!0,this.update(!0))}handleEvent(e,r,n=!0){if(r&&this._ignoreReplayEvents)return!1;this._ignoreReplayEvents=!1;const i=this.options,a=this._active||[],s=this._getActiveElements(e,a,r,n),o=this._positionChanged(s,e),l=r||!sd(s,a)||o;return l&&(this._active=s,(i.enabled||i.external)&&(this._eventPosition={x:e.x,y:e.y},this.update(!0,r))),l}_getActiveElements(e,r,n,i){const a=this.options;if(e.type==="mouseout")return[];if(!i)return r;const s=this.chart.getElementsAtEventForMode(e,a.mode,a,n);return a.reverse&&s.reverse(),s}_positionChanged(e,r){const{caretX:n,caretY:i,options:a}=this,s=_u[a.position].call(this,e,r);return s!==!1&&(n!==s.x||i!==s.y)}}qe(d0,"positioners",_u);var Gte={id:"tooltip",_element:d0,positioners:_u,afterInit(t,e,r){r&&(t.tooltip=new d0({chart:t,options:r}))},beforeUpdate(t,e,r){t.tooltip&&t.tooltip.initialize(r)},reset(t,e,r){t.tooltip&&t.tooltip.initialize(r)},afterDraw(t){const e=t.tooltip;if(e&&e._willRender()){const r={tooltip:e};if(t.notifyPlugins("beforeTooltipDraw",{...r,cancelable:!0})===!1)return;e.draw(t.ctx),t.notifyPlugins("afterTooltipDraw",r)}},afterEvent(t,e){if(t.tooltip){const r=e.replay;t.tooltip.handleEvent(e.event,r,e.inChartArea)&&(e.changed=!0)}},defaults:{enabled:!0,external:null,position:"average",backgroundColor:"rgba(0,0,0,0.8)",titleColor:"#fff",titleFont:{weight:"bold"},titleSpacing:2,titleMarginBottom:6,titleAlign:"left",bodyColor:"#fff",bodySpacing:2,bodyFont:{},bodyAlign:"left",footerColor:"#fff",footerSpacing:2,footerMarginTop:6,footerFont:{weight:"bold"},footerAlign:"left",padding:6,caretPadding:2,caretSize:5,cornerRadius:6,boxHeight:(t,e)=>e.bodyFont.size,boxWidth:(t,e)=>e.bodyFont.size,multiKeyBackground:"#fff",displayColors:!0,boxPadding:0,borderColor:"rgba(0,0,0,0)",borderWidth:0,animation:{duration:400,easing:"easeOutQuart"},animations:{numbers:{type:"number",properties:["x","y","width","height","caretX","caretY"]},opacity:{easing:"linear",duration:200}},callbacks:XP},defaultRoutes:{bodyFont:"font",footerFont:"font",titleFont:"font"},descriptors:{_scriptable:t=>t!=="filter"&&t!=="itemSort"&&t!=="external",_indexable:!1,callbacks:{_scriptable:!1,_indexable:!1},animation:{_fallback:!1},animations:{_fallback:"animation"}},additionalOptionScopes:["interaction"]};const Kte=(t,e,r,n)=>(typeof e=="string"?(r=t.push(e)-1,n.unshift({index:r,label:e})):isNaN(e)&&(r=null),r);function Xte(t,e,r,n){const i=t.indexOf(e);if(i===-1)return Kte(t,e,r,n);const a=t.lastIndexOf(e);return i!==a?r:i}const Yte=(t,e)=>t===null?null:Hn(Math.round(t),0,e);function sI(t){const e=this.getLabels();return t>=0&&t<e.length?e[t]:t}class h0 extends Oo{constructor(e){super(e),this._startValue=void 0,this._valueRange=0,this._addedLabels=[]}init(e){const r=this._addedLabels;if(r.length){const n=this.getLabels();for(const{index:i,label:a}of r)n[i]===a&&n.splice(i,1);this._addedLabels=[]}super.init(e)}parse(e,r){if(ur(e))return null;const n=this.getLabels();return r=isFinite(r)&&n[r]===e?r:Xte(n,e,Xe(r,e),this._addedLabels),Yte(r,n.length-1)}determineDataLimits(){const{minDefined:e,maxDefined:r}=this.getUserBounds();let{min:n,max:i}=this.getMinMax(!0);this.options.bounds==="ticks"&&(e||(n=0),r||(i=this.getLabels().length-1)),this.min=n,this.max=i}buildTicks(){const e=this.min,r=this.max,n=this.options.offset,i=[];let a=this.getLabels();a=e===0&&r===a.length-1?a:a.slice(e,r+1),this._valueRange=Math.max(a.length-(n?0:1),1),this._startValue=this.min-(n?.5:0);for(let s=e;s<=r;s++)i.push({value:s});return i}getLabelForValue(e){return sI.call(this,e)}configure(){super.configure(),this.isHorizontal()||(this._reversePixels=!this._reversePixels)}getPixelForValue(e){return typeof e!="number"&&(e=this.parse(e)),e===null?NaN:this.getPixelForDecimal((e-this._startValue)/this._valueRange)}getPixelForTick(e){const r=this.ticks;return e<0||e>r.length-1?null:this.getPixelForValue(r[e].value)}getValueForPixel(e){return Math.round(this._startValue+this.getDecimalForPixel(e)*this._valueRange)}getBasePixel(){return this.bottom}}qe(h0,"id","category"),qe(h0,"defaults",{ticks:{callback:sI}});function Zte(t,e){const r=[],{bounds:i,step:a,min:s,max:o,precision:l,count:c,maxTicks:d,maxDigits:h,includeBounds:g}=t,m=a||1,v=d-1,{min:b,max:y}=e,x=!ur(s),w=!ur(o),S=!ur(c),E=(y-b)/(h+1);let C=aA((y-b)/v/m)*m,I,T,D,P;if(C<1e-14&&!x&&!w)return[{value:b},{value:y}];P=Math.ceil(y/C)-Math.floor(b/C),P>v&&(C=aA(P*C/v/m)*m),ur(l)||(I=Math.pow(10,l),C=Math.ceil(C*I)/I),i==="ticks"?(T=Math.floor(b/C)*C,D=Math.ceil(y/C)*C):(T=b,D=y),x&&w&&a&&TJ((o-s)/a,C/1e3)?(P=Math.round(Math.min((o-s)/C,d)),C=(o-s)/P,T=s,D=o):S?(T=x?s:T,D=w?o:D,P=c-1,C=(D-T)/P):(P=(D-T)/C,Au(P,Math.round(P),C/1e3)?P=Math.round(P):P=Math.ceil(P));const L=Math.max(sA(C),sA(T));I=Math.pow(10,ur(l)?L:l),T=Math.round(T*I)/I,D=Math.round(D*I)/I;let F=0;for(x&&(g&&T!==s?(r.push({value:s}),T<s&&F++,Au(Math.round((T+F*C)*I)/I,s,oI(s,E,t))&&F++):T<s&&F++);F<P;++F){const H=Math.round((T+F*C)*I)/I;if(w&&H>o)break;r.push({value:H})}return w&&g&&D!==o?r.length&&Au(r[r.length-1].value,o,oI(o,E,t))?r[r.length-1].value=o:r.push({value:o}):(!w||D===o)&&r.push({value:D}),r}function oI(t,e,{horizontal:r,minRotation:n}){const i=jr(n),a=(r?Math.sin(i):Math.cos(i))||.001,s=.75*e*(""+t).length;return Math.min(e/a,s)}class Jte extends Oo{constructor(e){super(e),this.start=void 0,this.end=void 0,this._startValue=void 0,this._endValue=void 0,this._valueRange=0}parse(e,r){return ur(e)||(typeof e=="number"||e instanceof Number)&&!isFinite(+e)?null:+e}handleTickRangeOptions(){const{beginAtZero:e}=this.options,{minDefined:r,maxDefined:n}=this.getUserBounds();let{min:i,max:a}=this;const s=l=>i=r?i:l,o=l=>a=n?a:l;if(e){const l=po(i),c=po(a);l<0&&c<0?o(0):l>0&&c>0&&s(0)}if(i===a){let l=a===0?1:Math.abs(a*.05);o(a+l),e||s(i-l)}this.min=i,this.max=a}getTickLimit(){const e=this.options.ticks;let{maxTicksLimit:r,stepSize:n}=e,i;return n?(i=Math.ceil(this.max/n)-Math.floor(this.min/n)+1,i>1e3&&(console.warn(`scales.${this.id}.ticks.stepSize: ${n} would result generating up to ${i} ticks. Limiting to 1000.`),i=1e3)):(i=this.computeTickLimit(),r=r||11),r&&(i=Math.min(r,i)),i}computeTickLimit(){return Number.POSITIVE_INFINITY}buildTicks(){const e=this.options,r=e.ticks;let n=this.getTickLimit();n=Math.max(2,n);const i={maxTicks:n,bounds:e.bounds,min:e.min,max:e.max,precision:r.precision,step:r.stepSize,count:r.count,maxDigits:this._maxDigits(),horizontal:this.isHorizontal(),minRotation:r.minRotation||0,includeBounds:r.includeBounds!==!1},a=this._range||this,s=Zte(i,a);return e.bounds==="ticks"&&SJ(s,this,"value"),e.reverse?(s.reverse(),this.start=this.max,this.end=this.min):(this.start=this.min,this.end=this.max),s}configure(){const e=this.ticks;let r=this.min,n=this.max;if(super.configure(),this.options.offset&&e.length){const i=(n-r)/Math.max(e.length-1,1)/2;r-=i,n+=i}this._startValue=r,this._endValue=n,this._valueRange=n-r}getLabelForValue(e){return yP(e,this.chart.options.locale,this.options.ticks.format)}}class p0 extends Jte{determineDataLimits(){const{min:e,max:r}=this.getMinMax(!0);this.min=Ir(e)?e:0,this.max=Ir(r)?r:1,this.handleTickRangeOptions()}computeTickLimit(){const e=this.isHorizontal(),r=e?this.width:this.height,n=jr(this.options.ticks.minRotation),i=(e?Math.sin(n):Math.cos(n))||.001,a=this._resolveTickFontOptions(0);return Math.ceil(r/Math.min(40,a.lineHeight/i))}getPixelForValue(e){return e===null?NaN:this.getPixelForDecimal((e-this._startValue)/this._valueRange)}getValueForPixel(e){return this._startValue+this.getDecimalForPixel(e)*this._valueRange}}qe(p0,"id","linear"),qe(p0,"defaults",{ticks:{callback:bP.formatters.numeric}});const Qd={millisecond:{common:!0,size:1,steps:1e3},second:{common:!0,size:1e3,steps:60},minute:{common:!0,size:6e4,steps:60},hour:{common:!0,size:36e5,steps:24},day:{common:!0,size:864e5,steps:30},week:{common:!1,size:6048e5,steps:4},month:{common:!0,size:2628e6,steps:12},quarter:{common:!1,size:7884e6,steps:4},year:{common:!0,size:3154e7}},un=Object.keys(Qd);function uI(t,e){return t-e}function lI(t,e){if(ur(e))return null;const r=t._adapter,{parser:n,round:i,isoWeekday:a}=t._parseOpts;let s=e;return typeof n=="function"&&(s=n(s)),Ir(s)||(s=typeof n=="string"?r.parse(s,n):r.parse(s)),s===null?null:(i&&(s=i==="week"&&(ps(a)||a===!0)?r.startOf(s,"isoWeek",a):r.startOf(s,i)),+s)}function cI(t,e,r,n){const i=un.length;for(let a=un.indexOf(t);a<i-1;++a){const s=Qd[un[a]],o=s.steps?s.steps:Number.MAX_SAFE_INTEGER;if(s.common&&Math.ceil((r-e)/(o*s.size))<=n)return un[a]}return un[i-1]}function Qte(t,e,r,n,i){for(let a=un.length-1;a>=un.indexOf(r);a--){const s=un[a];if(Qd[s].common&&t._adapter.diff(i,n,s)>=e-1)return s}return un[r?un.indexOf(r):0]}function ere(t){for(let e=un.indexOf(t)+1,r=un.length;e<r;++e)if(Qd[un[e]].common)return un[e]}function fI(t,e,r){if(!r)t[e]=!0;else if(r.length){const{lo:n,hi:i}=qb(r,e),a=r[n]>=e?r[n]:r[i];t[a]=!0}}function tre(t,e,r,n){const i=t._adapter,a=+i.startOf(e[0].value,n),s=e[e.length-1].value;let o,l;for(o=a;o<=s;o=+i.add(o,1,n))l=r[o],l>=0&&(e[l].major=!0);return e}function dI(t,e,r){const n=[],i={},a=e.length;let s,o;for(s=0;s<a;++s)o=e[s],i[o]=s,n.push({value:o,major:!1});return a===0||!r?n:tre(t,n,i,r)}class Wu extends Oo{constructor(e){super(e),this._cache={data:[],labels:[],all:[]},this._unit="day",this._majorUnit=void 0,this._offsets={},this._normalized=!1,this._parseOpts=void 0}init(e,r={}){const n=e.time||(e.time={}),i=this._adapter=new LP._date(e.adapters.date);i.init(r),Ou(n.displayFormats,i.formats()),this._parseOpts={parser:n.parser,round:n.round,isoWeekday:n.isoWeekday},super.init(e),this._normalized=r.normalized}parse(e,r){return e===void 0?null:lI(this,e)}beforeLayout(){super.beforeLayout(),this._cache={data:[],labels:[],all:[]}}determineDataLimits(){const e=this.options,r=this._adapter,n=e.time.unit||"day";let{min:i,max:a,minDefined:s,maxDefined:o}=this.getUserBounds();function l(c){!s&&!isNaN(c.min)&&(i=Math.min(i,c.min)),!o&&!isNaN(c.max)&&(a=Math.max(a,c.max))}(!s||!o)&&(l(this._getLabelBounds()),(e.bounds!=="ticks"||e.ticks.source!=="labels")&&l(this.getMinMax(!1))),i=Ir(i)&&!isNaN(i)?i:+r.startOf(Date.now(),n),a=Ir(a)&&!isNaN(a)?a:+r.endOf(Date.now(),n)+1,this.min=Math.min(i,a-1),this.max=Math.max(i+1,a)}_getLabelBounds(){const e=this.getLabelTimestamps();let r=Number.POSITIVE_INFINITY,n=Number.NEGATIVE_INFINITY;return e.length&&(r=e[0],n=e[e.length-1]),{min:r,max:n}}buildTicks(){const e=this.options,r=e.time,n=e.ticks,i=n.source==="labels"?this.getLabelTimestamps():this._generate();e.bounds==="ticks"&&i.length&&(this.min=this._userMin||i[0],this.max=this._userMax||i[i.length-1]);const a=this.min,s=this.max,o=IJ(i,a,s);return this._unit=r.unit||(n.autoSkip?cI(r.minUnit,this.min,this.max,this._getLabelCapacity(a)):Qte(this,o.length,r.minUnit,this.min,this.max)),this._majorUnit=!n.major.enabled||this._unit==="year"?void 0:ere(this._unit),this.initOffsets(i),e.reverse&&o.reverse(),dI(this,o,this._majorUnit)}afterAutoSkip(){this.options.offsetAfterAutoskip&&this.initOffsets(this.ticks.map(e=>+e.value))}initOffsets(e=[]){let r=0,n=0,i,a;this.options.offset&&e.length&&(i=this.getDecimalForValue(e[0]),e.length===1?r=1-i:r=(this.getDecimalForValue(e[1])-i)/2,a=this.getDecimalForValue(e[e.length-1]),e.length===1?n=a:n=(a-this.getDecimalForValue(e[e.length-2]))/2);const s=e.length<3?.5:.25;r=Hn(r,0,s),n=Hn(n,0,s),this._offsets={start:r,end:n,factor:1/(r+1+n)}}_generate(){const e=this._adapter,r=this.min,n=this.max,i=this.options,a=i.time,s=a.unit||cI(a.minUnit,r,n,this._getLabelCapacity(r)),o=Xe(i.ticks.stepSize,1),l=s==="week"?a.isoWeekday:!1,c=ps(l)||l===!0,d={};let h=r,g,m;if(c&&(h=+e.startOf(h,"isoWeek",l)),h=+e.startOf(h,c?"day":s),e.diff(n,r,s)>1e5*o)throw new Error(r+" and "+n+" are too far apart with stepSize of "+o+" "+s);const v=i.ticks.source==="data"&&this.getDataTimestamps();for(g=h,m=0;g<n;g=+e.add(g,o,s),m++)fI(d,g,v);return(g===n||i.bounds==="ticks"||m===1)&&fI(d,g,v),Object.keys(d).sort(uI).map(b=>+b)}getLabelForValue(e){const r=this._adapter,n=this.options.time;return n.tooltipFormat?r.format(e,n.tooltipFormat):r.format(e,n.displayFormats.datetime)}format(e,r){const i=this.options.time.displayFormats,a=this._unit,s=r||i[a];return this._adapter.format(e,s)}_tickFormatFunction(e,r,n,i){const a=this.options,s=a.ticks.callback;if(s)return Ut(s,[e,r,n],this);const o=a.time.displayFormats,l=this._unit,c=this._majorUnit,d=l&&o[l],h=c&&o[c],g=n[r],m=c&&h&&g&&g.major;return this._adapter.format(e,i||(m?h:d))}generateTickLabels(e){let r,n,i;for(r=0,n=e.length;r<n;++r)i=e[r],i.label=this._tickFormatFunction(i.value,r,e)}getDecimalForValue(e){return e===null?NaN:(e-this.min)/(this.max-this.min)}getPixelForValue(e){const r=this._offsets,n=this.getDecimalForValue(e);return this.getPixelForDecimal((r.start+n)*r.factor)}getValueForPixel(e){const r=this._offsets,n=this.getDecimalForPixel(e)/r.factor-r.end;return this.min+n*(this.max-this.min)}_getLabelSize(e){const r=this.options.ticks,n=this.ctx.measureText(e).width,i=jr(this.isHorizontal()?r.maxRotation:r.minRotation),a=Math.cos(i),s=Math.sin(i),o=this._resolveTickFontOptions(0).size;return{w:n*a+o*s,h:n*s+o*a}}_getLabelCapacity(e){const r=this.options.time,n=r.displayFormats,i=n[r.unit]||n.millisecond,a=this._tickFormatFunction(e,0,dI(this,[e],this._majorUnit),i),s=this._getLabelSize(a),o=Math.floor(this.isHorizontal()?this.width/s.w:this.height/s.h)-1;return o>0?o:1}getDataTimestamps(){let e=this._cache.data||[],r,n;if(e.length)return e;const i=this.getMatchingVisibleMetas();if(this._normalized&&i.length)return this._cache.data=i[0].controller.getAllParsedValues(this);for(r=0,n=i.length;r<n;++r)e=e.concat(i[r].controller.getAllParsedValues(this));return this._cache.data=this.normalize(e)}getLabelTimestamps(){const e=this._cache.labels||[];let r,n;if(e.length)return e;const i=this.getLabels();for(r=0,n=i.length;r<n;++r)e.push(lI(this,i[r]));return this._cache.labels=this._normalized?e:this.normalize(e)}normalize(e){return DJ(e.sort(uI))}}qe(Wu,"id","time"),qe(Wu,"defaults",{bounds:"data",adapters:{},time:{parser:!1,unit:!1,round:!1,isoWeekday:!1,minUnit:"millisecond",displayFormats:{}},ticks:{source:"auto",callback:!1,major:{enabled:!1}}});function df(t,e,r){let n=0,i=t.length-1,a,s,o,l;r?(e>=t[n].pos&&e<=t[i].pos&&({lo:n,hi:i}=ns(t,"pos",e)),{pos:a,time:o}=t[n],{pos:s,time:l}=t[i]):(e>=t[n].time&&e<=t[i].time&&({lo:n,hi:i}=ns(t,"time",e)),{time:a,pos:o}=t[n],{time:s,pos:l}=t[i]);const c=s-a;return c?o+(l-o)*(e-a)/c:o}class hI extends Wu{constructor(e){super(e),this._table=[],this._minPos=void 0,this._tableRange=void 0}initOffsets(){const e=this._getTimestampsForTable(),r=this._table=this.buildLookupTable(e);this._minPos=df(r,this.min),this._tableRange=df(r,this.max)-this._minPos,super.initOffsets(e)}buildLookupTable(e){const{min:r,max:n}=this,i=[],a=[];let s,o,l,c,d;for(s=0,o=e.length;s<o;++s)c=e[s],c>=r&&c<=n&&i.push(c);if(i.length<2)return[{time:r,pos:0},{time:n,pos:1}];for(s=0,o=i.length;s<o;++s)d=i[s+1],l=i[s-1],c=i[s],Math.round((d+l)/2)!==c&&a.push({time:c,pos:s/(o-1)});return a}_generate(){const e=this.min,r=this.max;let n=super.getDataTimestamps();return(!n.includes(e)||!n.length)&&n.splice(0,0,e),(!n.includes(r)||n.length===1)&&n.push(r),n.sort((i,a)=>i-a)}_getTimestampsForTable(){let e=this._cache.all||[];if(e.length)return e;const r=this.getDataTimestamps(),n=this.getLabelTimestamps();return r.length&&n.length?e=this.normalize(r.concat(n)):e=r.length?r:n,e=this._cache.all=e,e}getDecimalForValue(e){return(df(this._table,e)-this._minPos)/this._tableRange}getValueForPixel(e){const r=this._offsets,n=this.getDecimalForPixel(e)/r.factor-r.end;return df(this._table,n*this._tableRange+this._minPos,!0)}}qe(hI,"id","timeseries"),qe(hI,"defaults",Wu.defaults);const YP="label";function pI(t,e){typeof t=="function"?t(e):t&&(t.current=e)}function rre(t,e){const r=t.options;r&&e&&Object.assign(r,e)}function ZP(t,e){t.labels=e}function JP(t,e,r=YP){const n=[];t.datasets=e.map(i=>{const a=t.datasets.find(s=>s[r]===i[r]);return!a||!i.data||n.includes(a)?{...i}:(n.push(a),Object.assign(a,i),a)})}function nre(t,e=YP){const r={labels:[],datasets:[]};return ZP(r,t.labels),JP(r,t.datasets,e),r}function ire(t,e){const{height:r=150,width:n=300,redraw:i=!1,datasetIdKey:a,type:s,data:o,options:l,plugins:c=[],fallbackContent:d,updateMode:h,...g}=t,m=$t(null),v=$t(null),b=()=>{m.current&&(v.current=new us(m.current,{type:s,data:nre(o,a),options:l&&{...l},plugins:c}),pI(e,v.current))},y=()=>{pI(e,null),v.current&&(v.current.destroy(),v.current=null)};return ut(()=>{!i&&v.current&&l&&rre(v.current,l)},[i,l]),ut(()=>{!i&&v.current&&ZP(v.current.config.data,o.labels)},[i,o.labels]),ut(()=>{!i&&v.current&&o.datasets&&JP(v.current.config.data,o.datasets,a)},[i,o.datasets]),ut(()=>{v.current&&(i?(y(),setTimeout(b)):v.current.update(h))},[i,l,o.labels,o.datasets,h]),ut(()=>{v.current&&(y(),setTimeout(b))},[s]),ut(()=>(b(),()=>y()),[]),A.jsx("canvas",{ref:m,role:"img",height:r,width:n,...g,children:d})}const QP=Cn(ire);function are(t,e){return us.register(e),Cn((r,n)=>A.jsx(QP,{...r,ref:n,type:t}))}const eL=are("line",ao),sre=(t,e)=>({maintainAspectRatio:!1,scales:{x:{ticks:{display:!1},grid:{display:!1},type:"time",time:{unit:ei.Hour},border:{display:!1}},y:{ticks:{display:!1},grid:{display:!1},border:{display:!1}},y1:{position:"right",title:{display:!0,text:e,font:Wf},ticks:{display:!1},grid:{display:!1},border:{display:!1}}},font:Wf,borderColor:Tn.primary,elements:{line:{borderWidth:1}},backgroundColor:PZ(t,Tn.primary),plugins:{legend:{display:!1},tooltip:{enabled:!1}}}),ore="0px 2px 1px -1px rgba(0, 0, 0, 0.2), 0px 1px 1px 0px rgba(0, 0, 0, 0.14), 0px 1px 3px 0px rgba(0, 0, 0, 0.12)",ure={backgroundColor:Ye.surface,borderRadius:12,boxSizing:"border-box",color:Ye.onSurface,overflow:"hidden"},Yb=({elevation:t=1,children:e,style:r,...n})=>A.jsx("div",{style:{...ure,boxShadow:t?ore:"none",...r},...n,children:e}),lre=[{opacity:1,easing:"ease-in-out"},{opacity:.4,easing:"ease-in-out"},{opacity:1}],cre=t=>t==="circular"?"50%":t==="rounded"?"4px":"0",gI=t=>typeof t=="number"?`${t}px`:t,so=({variant:t="rectangular",width:e,height:r,style:n,...i})=>{const a=$t(null);return ut(()=>{var o,l;const s=(l=(o=a.current)==null?void 0:o.animate)==null?void 0:l.call(o,lre,{duration:2e3,delay:500,iterations:1/0});return()=>s==null?void 0:s.cancel()},[]),A.jsx("span",{ref:a,style:{display:"block",backgroundColor:"rgba(9, 34, 65, 0.11)",height:gI(r)||"1.2em",width:gI(e)||"auto",borderRadius:cre(t),...n},...i})},wy=({children:t,style:e,...r})=>A.jsx(Yb,{style:{borderRadius:8,boxShadow:"0px 12px 20px -12px rgba(0, 0, 0, 0.12), inset 0px 0px 0px 1px #e1e4e8",cursor:"pointer",height:216,padding:16,width:"100%",...e},...r,children:t}),fre=({style:t,...e})=>A.jsx(so,{style:{height:144,padding:16,width:"100%",...t},...e}),dre=({children:t,style:e,...r})=>A.jsx("div",{style:{display:"flex",alignItems:"center",flexDirection:"row",gap:8,justifyContent:"space-between",...e},...r,children:t}),Ty=({children:t,style:e,...r})=>A.jsx(lt,{variant:"subtitle2",style:{marginBottom:12,...e},...r,children:t}),hre=({children:t,style:e,...r})=>A.jsx("div",{style:{alignItems:"center",cursor:"not-allowed",display:"flex",height:118,flexDirection:"column",justifyContent:"center",...e},...r,children:t}),pre=()=>A.jsx(Hi,{style:{"--ix-icon-font-size":"3rem",color:"var(--clr-warning, #ff9800)",display:"block"},children:"error"}),gre=({children:t,style:e,...r})=>A.jsx(lt,{variant:"body2",style:{marginTop:8,...e},...r,children:t}),mre=({endDate:t,functionName:e,interval:r,leasedSpaceName:n,onClick:i,startDate:a,subCategory:s})=>{var v;const{t:o}=Qt("location"),[l,c]=or(),d=sre(l,e),h=TD({endDate:t,functionName:e,interval:r,leasedSpaceName:n,startDate:a,subCategory:s}),m={datasets:LZ((v=h.data)==null?void 0:v.portalTrendData,{options:{fill:!0,pointStyle:!1}})};return h.isLoading?A.jsxs(wy,{children:[A.jsx(Ty,{children:s}),A.jsx(fre,{variant:"rectangular"})]}):h.isError?A.jsxs(wy,{children:[A.jsx(Ty,{children:s}),A.jsxs(hre,{children:[A.jsx(pre,{}),A.jsx(gre,{children:o("dcim-chart.load-fail.title")})]})]}):A.jsxs(wy,{onClick:i,children:[A.jsx(Ty,{children:s}),A.jsx(dre,{children:m&&A.jsx(eL,{ref:c,options:d,data:m,width:"100%"})})]})},vre=t=>{const{assetName:e,endDate:r,functionName:n,interval:i,leasedSpaceName:a,sitecode:s,startDate:o,subCategory:l,tdcid:c}=t;return`/chart/?${[`assetName=${e}`,`endDate=${r.toISOString()}`,`functionName=${encodeURIComponent(n)}`,`interval=${i}`,`leasedSpaceName=${a}`,`sitecode=${s}`,`startDate=${o.toISOString()}`,`subCategory=${l}`,`tdcid=${c}`].join("&")}`},yre=({assetName:t,endDate:e,interval:r,leasedSpaceName:n,metadata:i,metadataIsLoading:a,metadataIsFetching:s,sitecode:o,startDate:l})=>{const c=bd();if(a||s)return A.jsx(zZ,{children:A.jsx(_V,{})});const d=(i||[]).sort((h,g)=>h.displayOrder-g.displayOrder);return A.jsx(A.Fragment,{children:d.map(h=>{const g=`${h.tdcid}-${h.subCategory}-${h.defaultFunctionAliasName}`,m={assetName:t,endDate:e,functionName:h.defaultFunctionAliasName,interval:r,leasedSpaceName:n,sitecode:o,startDate:l,subCategory:h.subCategory,tdcid:h.tdcid};return A.jsx(zr,{xs:12,sm:6,lg:4,xl:3,children:A.jsx(mre,{endDate:e.toISOString(),functionName:h.defaultFunctionAliasName,interval:r,leasedSpaceName:n,onClick:()=>{const v=vre(m);c(`${v}`)},startDate:l.toISOString(),subCategory:h.subCategory,tdcid:h.tdcid})},g)})})},bre=({assetName:t,leasedSpaceName:e,date:r,sitecode:n})=>{const i=bd(),{t:a}=Qt("location"),s=k5(r),o=wz(s,{days:7}),l=s,c=SD(e,{enabled:!!n&&!!t});return A.jsxs(eb,{children:[A.jsx(rb,{assetName:t,sitecode:n}),A.jsxs(tb,{spacing:{xs:2.5,md:3},children:[A.jsx(zr,{xs:12,md:12,lg:12,xl:3,children:A.jsx(ob,{disableOptionAll:!0,filters:{type:co},handleFilters:(d,h)=>{const g=`/alert?assetName=${t}&sitecode=${n}&leasedSpaceName=${e}&type=${h}`;i(g)},leasedSpaceName:e,title:a("alerts.title")})}),A.jsx(zr,{xs:12,md:12,lg:12,xl:9,children:A.jsxs("div",{children:[A.jsxs(bD,{children:[A.jsx(lt,{variant:"h6",children:a("title")}),A.jsx(lt,{variant:"body2",children:a("subtitle")})]}),A.jsx(_D,{spacing:{xs:2,md:3},children:A.jsx(yre,{assetName:t,endDate:l,interval:ei.Hour,leasedSpaceName:e,metadata:c.data,metadataIsLoading:c.isLoading,metadataIsFetching:c.isFetching,sitecode:n,startDate:o})})]})})]})]})},_re={...Ea,flex:1,display:"grid",gridTemplateColumns:"minmax(28px, 50px) 1fr 24px",columnGap:20,textAlign:"left",padding:"8px 12px",borderRadius:12,lineHeight:"18px",backgroundColor:Ye.outline,color:Ye.onSurface},xre=({children:t,style:e,...r})=>A.jsx("button",{style:{..._re,...e},...r,children:t}),wre={width:"min-content",padding:"3px 10px",backgroundColor:Ye.onPrimary,borderRadius:16,fontFamily:"'Roboto', sans-serif",fontSize:13,lineHeight:"18px",letterSpacing:"0.16px",textAlign:"center"},Tre=({children:t,style:e,...r})=>A.jsx("div",{style:{...wre,...e},...r,children:t}),Sre=({count:t,title:e,onClick:r})=>A.jsxs(xre,{type:"button",onClick:r,children:[A.jsx(Tre,{children:t}),A.jsx(lt,{children:e}),A.jsx(Hi,{style:{"--ix-icon-font-size":"1em"},children:"chevron_right"})]}),Cre=({children:t,style:e,...r})=>A.jsx("div",{style:{display:"inline-block",width:16,height:16,backgroundColor:Ye.onSurface,border:`2px solid ${Ye.pointBorder}`,borderRadius:16,...e},...r,children:t}),Ao=({columnGap:t,children:e,style:r,...n})=>A.jsx("div",{style:{alignItems:"center",columnGap:t||"8px",display:"flex",flexDirection:"row",...r},...n,children:e}),Ere=({children:t,style:e,...r})=>{const n=Ve(Et("md"));return A.jsx(Ao,{style:{flex:1,flexWrap:"wrap",justifyContent:"space-between",marginBottom:20,rowGap:16,columnGap:32,...n?{flexDirection:"column",alignItems:"flex-start"}:null,...e},...r,children:t})},Ore=({children:t,style:e,...r})=>A.jsx("div",{style:{display:"flex",flexDirection:"row",alignItems:"center",alignSelf:"stretch",justifyContent:"space-between",columnGap:32,...e},...r,children:t}),Are=({children:t,style:e,...r})=>A.jsx(Yb,{style:{padding:"18px 16px 24px",borderRadius:0,...e},...r,children:t}),tL=({children:t,style:e,...r})=>{const n=Ve(Et("md"));return A.jsx("div",{style:{minHeight:n?"40vh":"60vh",position:"relative",width:"99%",...e},...r,children:t})},rL="(max-width:1399.95px)",Ire=({children:t,style:e,...r})=>{const n=Ve(rL),i=Ve(Et("sm"));return A.jsx("div",{style:{display:"flex",flexDirection:i?"column":"row",flexWrap:"wrap",alignItems:i?"flex-start":"center",justifyContent:"space-between",marginBottom:12,rowGap:16,...n?{columnGap:32}:null,...e},...r,children:t})},Rre=({children:t,style:e,...r})=>{const n=Ve(Et("sm")),i=Ve(rL);return A.jsx(Ao,{style:{gap:n?16:24,justifyContent:"flex-start",flexWrap:"wrap",...i?{order:1,margin:"0 auto"}:null,...e},...r,children:t})},Dre={...Ea,backgroundColor:MZ("#1456e0",.05),border:`1px solid ${Ye.onSurface}`,padding:"2px 4px 3px",...Bf.caption},Mre=({children:t,style:e,...r})=>A.jsx("button",{style:{...Dre,...e},...r,children:t}),Pre=({color:t,children:e,style:r,...n})=>A.jsx("div",{style:{backgroundColor:t||"unset",height:4,width:16,...r},...n,children:e}),Lre=({children:t,style:e,...r})=>A.jsx(Ao,{style:{flex:1,justifyContent:"space-between",minWidth:0,...e},...r,children:t}),Nre=({children:t,style:e,...r})=>A.jsx(lt,{style:{minWidth:0,wordWrap:"break-word",...e},...r,children:t}),Fre=({children:t,style:e,...r})=>A.jsx("label",{style:{display:"flex",alignItems:"center",gap:8,width:"100%",cursor:"pointer",...e},...r,children:t}),mI=({children:t,style:e,...r})=>{const n=Ve(pa("md"));return A.jsx("div",{style:{...n?{marginBottom:20}:null,...e},...r,children:t})},kre=({children:t,style:e,...r})=>A.jsx("div",{style:{display:"flex",flexDirection:"column",gap:10,margin:0,...e},...r,children:t}),jre={...Ea,alignSelf:"flex-start",...Bf.small,color:Ye.primary,textDecoration:"underline"},vI=({children:t,style:e,...r})=>A.jsx("button",{style:{...jre,...e},...r,children:t}),$re=(t,e)=>({onDeselectAllDevices:()=>{const a=t.map(s=>({...s,selected:!1}));e(a)},onSelectAllDevices:()=>{const a=t.map(s=>({...s,selected:!0}));e(a)},onSelectDevice:a=>{const s=t.map(o=>{const l={...o};return l.id===a&&(l.selected=!l.selected),l});e(s)}}),Ure=({devices:t=[],isLoading:e,setDevices:r=()=>{},title:n})=>{const{t:i}=Qt("location"),{isMobile:a}=To(),s=$re(t,r),[o,l]=or(!1),d=`${t.filter(m=>m.selected).length}/${t.length}`,h=t.every(m=>m.selected),g=e&&A.jsx(A.Fragment,{children:[1,2,3].map(m=>A.jsx(so,{},m))})||A.jsxs("div",{style:{display:"flex",flexDirection:"column",flexWrap:"wrap"},children:[h?A.jsx(vI,{type:"button",onClick:s.onDeselectAllDevices,children:i("dcim-chart.device-selector.deselect-all")}):A.jsx(vI,{type:"button",onClick:s.onSelectAllDevices,children:i("dcim-chart.device-selector.select-all")}),t.map(({color:m,id:v,name:b,selected:y})=>A.jsxs(Fre,{children:[A.jsx(F0,{"aria-label":b,checked:y,name:b,onCheckboxChange:()=>s.onSelectDevice(v)}),A.jsxs(Lre,{children:[A.jsx(Nre,{children:b}),A.jsx(Pre,{color:m})]})]},b))]});if(a){const m=[{label:i("common:close"),mobileLabel:A.jsx(Hi,{style:{"--ix-icon-font-size":"24px"},children:"close"}),trigger:()=>l(!1)}];return A.jsxs(A.Fragment,{children:[A.jsx(G0,{actions:m,fullScreen:!0,open:o,title:i("dcim-chart.device-selector.label"),children:g}),A.jsxs(kre,{children:[A.jsx(mI,{children:A.jsx(lt,{variant:"h6",children:n})}),A.jsx(Sre,{count:d,onClick:()=>l(!0),title:i("dcim-chart.device-selector.label")})]})]})}return A.jsxs("div",{role:"group","aria-label":n,style:{display:"flex",flexDirection:"column",minWidth:0,width:"100%"},children:[A.jsx(mI,{children:A.jsx(lt,{variant:"h6",children:n})}),g]})},qre=({children:t,style:e,...r})=>{const n=Ve(Et("md"));return A.jsx("div",{style:{position:"relative",minHeight:n?"40vh":"60vh",width:"99%",...e},...r,children:t})},Hre=({children:t,style:e,...r})=>A.jsx(Yb,{style:{padding:"18px 16px 24px",borderRadius:0,...e},...r,children:t}),g0=({columnGap:t,children:e,style:r,...n})=>A.jsx("div",{style:{display:"flex",flexDirection:"row",alignItems:"center",columnGap:t||"8px",...r},...n,children:e}),Wre=({children:t,style:e,...r})=>{const n=Ve(pa("md")),i=Ve(Et("md"));return A.jsx(g0,{style:{...n?{flex:1}:null,...i?{alignItems:"flex-start",flexDirection:"column"}:null,...e},...r,children:t})},ui={Day:1350,Hour:15e3,FifteenMinutes:5e4,FiveMinutes:60480,Minute:60480},Bre=(t,e,r)=>{const s=(e.valueOf()-t.valueOf())/xD/60;let l=s/1440*r;const c={datapointsForDuration:l,intervalType:ei.Day,limit:ui.Day,numberOfDevices:r,isValid:l<=ui.Day};l=s/60*r;const h={datapointsForDuration:l,intervalType:ei.Hour,limit:ui.Hour,numberOfDevices:r,isValid:l<=ui.Hour};l=s/15*r;const m={datapointsForDuration:l,intervalType:ei.FifteenMinutes,limit:ui.FifteenMinutes,numberOfDevices:r,isValid:l<=ui.FifteenMinutes};l=s/5*r;const b={datapointsForDuration:l,intervalType:ei.FiveMinutes,limit:ui.FiveMinutes,numberOfDevices:r,isValid:l<=ui.FiveMinutes};l=s/1*r;const x={datapointsForDuration:l,intervalType:ei.Minute,limit:ui.Minute,numberOfDevices:r,isValid:l<=ui.Minute};return{Day:c,Hour:h,FifteenMinutes:m,FiveMinutes:b,Minute:x}},zre=(t,e,r)=>{const n=Bre(t,e,r);return[{disabled:!n.Day.isValid,value:n.Day.intervalType},{disabled:!n.Hour.isValid,value:n.Hour.intervalType},{disabled:!n.FifteenMinutes.isValid,value:n.FifteenMinutes.intervalType},{disabled:!n.FiveMinutes.isValid,value:n.FiveMinutes.intervalType},{disabled:!n.Minute.isValid,value:n.Minute.intervalType}]},Vre=({interval:t,startDate:e,endDate:r,numberOfDevices:n,setInterval:i})=>{const{t:a}=Qt("location"),{isMobile:s}=To(),o=zre(e,r,n);return A.jsxs(Wre,{children:[A.jsx(lt,{variant:"body2",children:a("dcim-chart.increments.label")}),A.jsx(K0,{ariaLabel:a("dcim-chart.increments.label"),getOptionDisabled:l=>l.disabled,getOptionLabel:l=>a(`dcim-chart.increments.${mr.kebabCase(l.value)}`),getOptionValue:l=>l.value,onChange:l=>i(l),options:o,style:s?{width:"100%"}:void 0,trailingIcon:"av_timer",value:t})]})};var wr=(t=>(t.Daily="daily",t.Trend="trend",t))(wr||{});const Gre=({children:t,...e})=>A.jsx("div",{role:"tablist",...e,children:A.jsx("div",{style:{borderRadius:12,display:"inline-flex"},children:t})}),Kre={...Ea,backgroundColor:"transparent",border:`1px solid ${Ye.outlineVariant}`,boxSizing:"border-box",color:Ye.onSurfaceVariant,display:"block",fontFamily:"var(--root-secondary-font, 'Red Hat Display', sans-serif)",fontSize:10,fontWeight:700,letterSpacing:"1.25px",lineHeight:"16px",minWidth:90,padding:"4px 6px",textAlign:"center",textTransform:"uppercase"},Xre={backgroundColor:Ye.primary,borderColor:Ye.primary,color:Ye.surface},nL=Cn(({selected:t,position:e,children:r,style:n,...i},a)=>A.jsx("button",{ref:a,type:"button",role:"tab","aria-selected":t,tabIndex:t?0:-1,style:{...Kre,borderRadius:e==="first"?"3px 0 0 3px":"0 3px 3px 0",...t?Xre:null,...n},...i,children:r}));nL.displayName="TabButton";const yI=[wr.Trend,wr.Daily],m0=(t,e)=>`${t}-tab-${e}`,v0=(t,e)=>`${t}-panel-${e}`,Yre=({idPrefix:t,onChange:e,viewType:r})=>{const{t:n}=Qt("location"),i=$t([]),a={[wr.Trend]:n("dcim-chart.view.trend"),[wr.Daily]:n("dcim-chart.view.daily")},s=(o,l)=>{var h;const c=yI.length-1,d={ArrowRight:l===c?0:l+1,ArrowLeft:l===0?c:l-1,Home:0,End:c};o.key in d&&(o.preventDefault(),(h=i.current[d[o.key]])==null||h.focus())};return A.jsx(Gre,{"aria-orientation":"horizontal",children:yI.map((o,l)=>A.jsx(nL,{ref:c=>{i.current[l]=c},id:m0(t,o),"aria-controls":v0(t,o),selected:o===r,position:l===0?"first":"last",onClick:()=>e(o),onKeyDown:c=>s(c,l),children:a[o]},o))})},Zre=t=>A.jsx("svg",{width:"1em",height:"1em",fill:"currentColor",focusable:"false","aria-hidden":"true",...t,children:A.jsx("path",{d:"M10 0H0V20H16V6L10 0ZM3 16L5.5 12.667L7 14.667L9.5 11.334L13 16H3ZM9 7V1.5L14.5 7H9Z"})}),Jre=t=>A.jsx("svg",{width:"1em",height:"1em",fill:"currentColor",focusable:"false","aria-hidden":"true",...t,children:A.jsx("path",{d:"M10 0L0 2V16L10 18V0ZM12 2V4H14V6H12V8H14V10H12V12H14V14H12V16H20V2H12ZM16 4H18V6H16V4ZM2.17578 5.29688H3.95312L4.87695 7.51172C4.95195 7.69272 5.00841 7.90262 5.06641 8.14062H5.0918C5.1248 7.99762 5.19197 7.77914 5.29297 7.49414L6.32227 5.29688H7.94336L6.00781 8.9668L8 12.7031H6.27148L5.1582 10.2891C5.1162 10.2041 5.06639 10.0329 5.02539 9.79492H5.00977C4.98477 9.90892 4.93438 10.0796 4.85938 10.3086L3.73633 12.7031H2L4.06055 8.99609L2.17578 5.29688ZM16 8H18V10H16V8ZM16 12H18V14H16V12Z"})}),Qre={...Ea,display:"inline-flex",alignItems:"center",justifyContent:"center",padding:2,borderRadius:"50%"},bI=({$color:t,children:e,disabled:r,style:n,...i})=>{const[a,s]=or(!1);return A.jsx("button",{disabled:r,onMouseEnter:()=>s(!0),onMouseLeave:()=>s(!1),style:{...Qre,color:r?"rgba(0, 0, 0, 0.26)":t,...r?{cursor:"default"}:null,...a&&!r?{backgroundColor:"rgba(9, 34, 65, 0.04)"}:null,...n},...i,children:e})};function Sy(t){return t==null?"":`${t}`}function ene(t={}){const{separator:e,decimals:r}=t;return e?r?n=>n.toFixed(r).replace(".",e):n=>`${n}`.replace(".",e):r?n=>n.toFixed(r):n=>`${n}`}function Zb(t={}){const e=typeof t.quote=="string"?t.quote:'"',r=typeof t.escapedQuote=="string"?t.escapedQuote:`${e}${e}`;if(!e||e===r)return i=>i;const n=new RegExp(e,"g");return i=>(i.includes(e)&&(i=i.replace(n,r)),`${e}${i}${e}`)}function tne(t={stringFormatter:Zb()}){return e=>t.stringFormatter(e.toString().slice(7,-1))}function rne(t={stringFormatter:Zb()}){return e=>{if(e===null)return"";let r=JSON.stringify(e);return r===void 0?"":(r[0]==='"'&&(r=r.replace(/^"(.+)"$/,"$1")),t.stringFormatter(r))}}const nne=RegExp(`[^.[\\]]+|\\[(?:([^"'][^[]*)|(["'])((?:(?!\\2)[^\\\\]|\\\\.)*?)\\2)\\]|(?=(?:\\.|\\[\\])(?:\\.|\\[\\]|$))`,"g");function ine(t){var e,r,n;const i=[];let a;for(;a=nne.exec(t);)i.push((n=(e=a[3])!==null&&e!==void 0?e:(r=a[1])===null||r===void 0?void 0:r.trim())!==null&&n!==void 0?n:a[0]);return i}function _I(t,e,r){if(e in t){const a=t[e];return a===void 0?r:a}const n=Array.isArray(e)?e:ine(e);let i=t;for(const a of n)if(i=i==null?void 0:i[a],i===void 0)return r;return i}function iL(t,e){try{return Array.isArray(e)?t.push(...e):t.push(e),t}catch{return t.concat(e)}}function y0(t,e){let r=!0;return t.reduce((n,i)=>(i==null&&(i=""),r?(r=!1,`${i}`):`${n}${e}${i}`),"")}var xI;(function(t){t.header="header",t.undefined="undefined",t.boolean="boolean",t.number="number",t.bigint="bigint",t.string="string",t.symbol="symbol",t.function="function",t.object="object"})(xI||(xI={}));class ane{constructor(e){this.opts=this.preprocessOpts(e)}preprocessOpts(e){const r=Object.assign({},e);r.fields&&(r.fields=this.preprocessFieldsInfo(r.fields,r.defaultValue)),r.transforms=r.transforms||[];const n=r.formatters&&r.formatters.string||Zb(),i=rne({stringFormatter:n}),a={header:n,undefined:Sy,boolean:Sy,number:ene(),bigint:Sy,string:n,symbol:tne({stringFormatter:n}),function:i,object:i};return r.formatters=Object.assign(Object.assign({},a),r.formatters),r.delimiter=r.delimiter||",",r.eol=r.eol||`
|
|
114
|
+
`,r.header=r.header!==!1,r.includeEmptyRows=r.includeEmptyRows||!1,r.withBOM=r.withBOM||!1,r}preprocessFieldsInfo(e,r){return e.map(n=>{if(typeof n=="string")return{label:n,value:i=>_I(i,n,r)};if(typeof n=="object"){const i="default"in n?n.default:r;if(typeof n.value=="string"){const a=n.value;return{label:n.label||n.value,value:s=>_I(s,a,i)}}if(typeof n.value=="function"){const a=n.label||n.value.name||"",s={label:a,default:i},o=n.value;return{label:a,value(l){const c=o(l,s);return c===void 0?i:c}}}}throw new Error("Invalid field info option. "+JSON.stringify(n))})}getHeader(){return y0(this.opts.fields.map(e=>this.opts.formatters.header(e.label)),this.opts.delimiter)}preprocessRow(e){return this.opts.transforms.reduce((r,n)=>r.map(i=>n(i)).reduce(iL,[]),[e])}processRow(e){if(!e)return;const r=this.opts.fields.map(n=>this.processCell(e,n));if(!(!this.opts.includeEmptyRows&&r.every(n=>n==="")))return y0(r,this.opts.delimiter)}processCell(e,r){return this.processValue(r.value(e))}processValue(e){const r=this.opts.formatters[typeof e];return r(e)}}class sne extends ane{constructor(e){super(e)}parse(e){const r=this.preprocessData(e);this.opts.fields=this.opts.fields||this.preprocessFieldsInfo(r.reduce((s,o)=>(Object.keys(o).forEach(l=>{s.includes(l)||s.push(l)}),s),[]),this.opts.defaultValue);const n=this.opts.header?this.getHeader():"",i=this.processData(r);return(this.opts.withBOM?"\uFEFF":"")+n+(n&&i?this.opts.eol:"")+i}preprocessData(e){const r=Array.isArray(e)?e:[e];if(!this.opts.fields){if(e==null||r.length===0)throw new Error('Data should not be empty or the "fields" option should be included');if(typeof r[0]!="object")throw new Error('Data items should be objects or the "fields" option should be included')}return this.opts.transforms.length===0?r:r.map(n=>this.preprocessRow(n)).reduce(iL,[])}processData(e){return y0(e.map(r=>this.processRow(r)).filter(r=>r),this.opts.eol)}}var Cr;(function(t){t[t.BACKSPACE=8]="BACKSPACE",t[t.FORM_FEED=12]="FORM_FEED",t[t.NEWLINE=10]="NEWLINE",t[t.CARRIAGE_RETURN=13]="CARRIAGE_RETURN",t[t.TAB=9]="TAB",t[t.SPACE=32]="SPACE",t[t.EXCLAMATION_MARK=33]="EXCLAMATION_MARK",t[t.QUOTATION_MARK=34]="QUOTATION_MARK",t[t.NUMBER_SIGN=35]="NUMBER_SIGN",t[t.DOLLAR_SIGN=36]="DOLLAR_SIGN",t[t.PERCENT_SIGN=37]="PERCENT_SIGN",t[t.AMPERSAND=38]="AMPERSAND",t[t.APOSTROPHE=39]="APOSTROPHE",t[t.LEFT_PARENTHESIS=40]="LEFT_PARENTHESIS",t[t.RIGHT_PARENTHESIS=41]="RIGHT_PARENTHESIS",t[t.ASTERISK=42]="ASTERISK",t[t.PLUS_SIGN=43]="PLUS_SIGN",t[t.COMMA=44]="COMMA",t[t.HYPHEN_MINUS=45]="HYPHEN_MINUS",t[t.FULL_STOP=46]="FULL_STOP",t[t.SOLIDUS=47]="SOLIDUS",t[t.DIGIT_ZERO=48]="DIGIT_ZERO",t[t.DIGIT_ONE=49]="DIGIT_ONE",t[t.DIGIT_TWO=50]="DIGIT_TWO",t[t.DIGIT_THREE=51]="DIGIT_THREE",t[t.DIGIT_FOUR=52]="DIGIT_FOUR",t[t.DIGIT_FIVE=53]="DIGIT_FIVE",t[t.DIGIT_SIX=54]="DIGIT_SIX",t[t.DIGIT_SEVEN=55]="DIGIT_SEVEN",t[t.DIGIT_EIGHT=56]="DIGIT_EIGHT",t[t.DIGIT_NINE=57]="DIGIT_NINE",t[t.COLON=58]="COLON",t[t.SEMICOLON=59]="SEMICOLON",t[t.LESS_THAN_SIGN=60]="LESS_THAN_SIGN",t[t.EQUALS_SIGN=61]="EQUALS_SIGN",t[t.GREATER_THAN_SIGN=62]="GREATER_THAN_SIGN",t[t.QUESTION_MARK=63]="QUESTION_MARK",t[t.COMMERCIAL_AT=64]="COMMERCIAL_AT",t[t.LATIN_CAPITAL_LETTER_A=65]="LATIN_CAPITAL_LETTER_A",t[t.LATIN_CAPITAL_LETTER_B=66]="LATIN_CAPITAL_LETTER_B",t[t.LATIN_CAPITAL_LETTER_C=67]="LATIN_CAPITAL_LETTER_C",t[t.LATIN_CAPITAL_LETTER_D=68]="LATIN_CAPITAL_LETTER_D",t[t.LATIN_CAPITAL_LETTER_E=69]="LATIN_CAPITAL_LETTER_E",t[t.LATIN_CAPITAL_LETTER_F=70]="LATIN_CAPITAL_LETTER_F",t[t.LATIN_CAPITAL_LETTER_G=71]="LATIN_CAPITAL_LETTER_G",t[t.LATIN_CAPITAL_LETTER_H=72]="LATIN_CAPITAL_LETTER_H",t[t.LATIN_CAPITAL_LETTER_I=73]="LATIN_CAPITAL_LETTER_I",t[t.LATIN_CAPITAL_LETTER_J=74]="LATIN_CAPITAL_LETTER_J",t[t.LATIN_CAPITAL_LETTER_K=75]="LATIN_CAPITAL_LETTER_K",t[t.LATIN_CAPITAL_LETTER_L=76]="LATIN_CAPITAL_LETTER_L",t[t.LATIN_CAPITAL_LETTER_M=77]="LATIN_CAPITAL_LETTER_M",t[t.LATIN_CAPITAL_LETTER_N=78]="LATIN_CAPITAL_LETTER_N",t[t.LATIN_CAPITAL_LETTER_O=79]="LATIN_CAPITAL_LETTER_O",t[t.LATIN_CAPITAL_LETTER_P=80]="LATIN_CAPITAL_LETTER_P",t[t.LATIN_CAPITAL_LETTER_Q=81]="LATIN_CAPITAL_LETTER_Q",t[t.LATIN_CAPITAL_LETTER_R=82]="LATIN_CAPITAL_LETTER_R",t[t.LATIN_CAPITAL_LETTER_S=83]="LATIN_CAPITAL_LETTER_S",t[t.LATIN_CAPITAL_LETTER_T=84]="LATIN_CAPITAL_LETTER_T",t[t.LATIN_CAPITAL_LETTER_U=85]="LATIN_CAPITAL_LETTER_U",t[t.LATIN_CAPITAL_LETTER_V=86]="LATIN_CAPITAL_LETTER_V",t[t.LATIN_CAPITAL_LETTER_W=87]="LATIN_CAPITAL_LETTER_W",t[t.LATIN_CAPITAL_LETTER_X=88]="LATIN_CAPITAL_LETTER_X",t[t.LATIN_CAPITAL_LETTER_Y=89]="LATIN_CAPITAL_LETTER_Y",t[t.LATIN_CAPITAL_LETTER_Z=90]="LATIN_CAPITAL_LETTER_Z",t[t.LEFT_SQUARE_BRACKET=91]="LEFT_SQUARE_BRACKET",t[t.REVERSE_SOLIDUS=92]="REVERSE_SOLIDUS",t[t.RIGHT_SQUARE_BRACKET=93]="RIGHT_SQUARE_BRACKET",t[t.CIRCUMFLEX_ACCENT=94]="CIRCUMFLEX_ACCENT",t[t.LOW_LINE=95]="LOW_LINE",t[t.GRAVE_ACCENT=96]="GRAVE_ACCENT",t[t.LATIN_SMALL_LETTER_A=97]="LATIN_SMALL_LETTER_A",t[t.LATIN_SMALL_LETTER_B=98]="LATIN_SMALL_LETTER_B",t[t.LATIN_SMALL_LETTER_C=99]="LATIN_SMALL_LETTER_C",t[t.LATIN_SMALL_LETTER_D=100]="LATIN_SMALL_LETTER_D",t[t.LATIN_SMALL_LETTER_E=101]="LATIN_SMALL_LETTER_E",t[t.LATIN_SMALL_LETTER_F=102]="LATIN_SMALL_LETTER_F",t[t.LATIN_SMALL_LETTER_G=103]="LATIN_SMALL_LETTER_G",t[t.LATIN_SMALL_LETTER_H=104]="LATIN_SMALL_LETTER_H",t[t.LATIN_SMALL_LETTER_I=105]="LATIN_SMALL_LETTER_I",t[t.LATIN_SMALL_LETTER_J=106]="LATIN_SMALL_LETTER_J",t[t.LATIN_SMALL_LETTER_K=107]="LATIN_SMALL_LETTER_K",t[t.LATIN_SMALL_LETTER_L=108]="LATIN_SMALL_LETTER_L",t[t.LATIN_SMALL_LETTER_M=109]="LATIN_SMALL_LETTER_M",t[t.LATIN_SMALL_LETTER_N=110]="LATIN_SMALL_LETTER_N",t[t.LATIN_SMALL_LETTER_O=111]="LATIN_SMALL_LETTER_O",t[t.LATIN_SMALL_LETTER_P=112]="LATIN_SMALL_LETTER_P",t[t.LATIN_SMALL_LETTER_Q=113]="LATIN_SMALL_LETTER_Q",t[t.LATIN_SMALL_LETTER_R=114]="LATIN_SMALL_LETTER_R",t[t.LATIN_SMALL_LETTER_S=115]="LATIN_SMALL_LETTER_S",t[t.LATIN_SMALL_LETTER_T=116]="LATIN_SMALL_LETTER_T",t[t.LATIN_SMALL_LETTER_U=117]="LATIN_SMALL_LETTER_U",t[t.LATIN_SMALL_LETTER_V=118]="LATIN_SMALL_LETTER_V",t[t.LATIN_SMALL_LETTER_W=119]="LATIN_SMALL_LETTER_W",t[t.LATIN_SMALL_LETTER_X=120]="LATIN_SMALL_LETTER_X",t[t.LATIN_SMALL_LETTER_Y=121]="LATIN_SMALL_LETTER_Y",t[t.LATIN_SMALL_LETTER_Z=122]="LATIN_SMALL_LETTER_Z",t[t.LEFT_CURLY_BRACKET=123]="LEFT_CURLY_BRACKET",t[t.VERTICAL_LINE=124]="VERTICAL_LINE",t[t.RIGHT_CURLY_BRACKET=125]="RIGHT_CURLY_BRACKET",t[t.TILDE=126]="TILDE"})(Cr||(Cr={}));Cr.QUOTATION_MARK+"",Cr.QUOTATION_MARK,Cr.REVERSE_SOLIDUS+"",Cr.REVERSE_SOLIDUS,Cr.SOLIDUS+"",Cr.SOLIDUS,Cr.LATIN_SMALL_LETTER_B+"",Cr.BACKSPACE,Cr.LATIN_SMALL_LETTER_F+"",Cr.FORM_FEED,Cr.LATIN_SMALL_LETTER_N+"",Cr.NEWLINE,Cr.LATIN_SMALL_LETTER_R+"",Cr.CARRIAGE_RETURN,Cr.LATIN_SMALL_LETTER_T+"",Cr.TAB;var wI;(function(t){t[t.LEFT_BRACE=0]="LEFT_BRACE",t[t.RIGHT_BRACE=1]="RIGHT_BRACE",t[t.LEFT_BRACKET=2]="LEFT_BRACKET",t[t.RIGHT_BRACKET=3]="RIGHT_BRACKET",t[t.COLON=4]="COLON",t[t.COMMA=5]="COMMA",t[t.TRUE=6]="TRUE",t[t.FALSE=7]="FALSE",t[t.NULL=8]="NULL",t[t.STRING=9]="STRING",t[t.NUMBER=10]="NUMBER",t[t.SEPARATOR=11]="SEPARATOR"})(wI||(wI={}));var TI;(function(t){t[t.START=0]="START",t[t.ENDED=1]="ENDED",t[t.ERROR=2]="ERROR",t[t.TRUE1=3]="TRUE1",t[t.TRUE2=4]="TRUE2",t[t.TRUE3=5]="TRUE3",t[t.FALSE1=6]="FALSE1",t[t.FALSE2=7]="FALSE2",t[t.FALSE3=8]="FALSE3",t[t.FALSE4=9]="FALSE4",t[t.NULL1=10]="NULL1",t[t.NULL2=11]="NULL2",t[t.NULL3=12]="NULL3",t[t.STRING_DEFAULT=13]="STRING_DEFAULT",t[t.STRING_AFTER_BACKSLASH=14]="STRING_AFTER_BACKSLASH",t[t.STRING_UNICODE_DIGIT_1=15]="STRING_UNICODE_DIGIT_1",t[t.STRING_UNICODE_DIGIT_2=16]="STRING_UNICODE_DIGIT_2",t[t.STRING_UNICODE_DIGIT_3=17]="STRING_UNICODE_DIGIT_3",t[t.STRING_UNICODE_DIGIT_4=18]="STRING_UNICODE_DIGIT_4",t[t.STRING_INCOMPLETE_CHAR=19]="STRING_INCOMPLETE_CHAR",t[t.NUMBER_AFTER_INITIAL_MINUS=20]="NUMBER_AFTER_INITIAL_MINUS",t[t.NUMBER_AFTER_INITIAL_ZERO=21]="NUMBER_AFTER_INITIAL_ZERO",t[t.NUMBER_AFTER_INITIAL_NON_ZERO=22]="NUMBER_AFTER_INITIAL_NON_ZERO",t[t.NUMBER_AFTER_FULL_STOP=23]="NUMBER_AFTER_FULL_STOP",t[t.NUMBER_AFTER_DECIMAL=24]="NUMBER_AFTER_DECIMAL",t[t.NUMBER_AFTER_E=25]="NUMBER_AFTER_E",t[t.NUMBER_AFTER_E_AND_SIGN=26]="NUMBER_AFTER_E_AND_SIGN",t[t.NUMBER_AFTER_E_AND_DIGIT=27]="NUMBER_AFTER_E_AND_DIGIT",t[t.SEPARATOR=28]="SEPARATOR",t[t.BOM_OR_START=29]="BOM_OR_START",t[t.BOM=30]="BOM"})(TI||(TI={}));var SI;(function(t){t[t.OBJECT=0]="OBJECT",t[t.ARRAY=1]="ARRAY"})(SI||(SI={}));var CI;(function(t){t[t.VALUE=0]="VALUE",t[t.KEY=1]="KEY",t[t.COLON=2]="COLON",t[t.COMMA=3]="COMMA",t[t.ENDED=4]="ENDED",t[t.ERROR=5]="ERROR",t[t.SEPARATOR=6]="SEPARATOR"})(CI||(CI={}));const one=t=>[{value:"deviceDataId",label:t("dcim-chart.export.header.deviceDataId")},{value:"deviceName",label:t("dcim-chart.export.header.deviceName")},{value:"date",label:t("dcim-chart.export.header.date")},{value:"minValue",label:t("dcim-chart.export.header.minValue")},{value:"maxValue",label:t("dcim-chart.export.header.maxValue")},{value:"pointValue",label:t("dcim-chart.export.header.pointValue")}],aL=t=>{let e=document.getElementById("chartjs-tooltip");e||(e=document.createElement("div"),e.id="chartjs-tooltip",document.body.appendChild(e));const r=t.tooltip;if(r.opacity===0){e.style.opacity="0";return}if(e.classList.remove("above","below","no-transform"),r.yAlign?e.classList.add(r.yAlign):e.classList.add("no-transform"),r.body){const o=r.title,[l]=r.body.map(({lines:h})=>h),c=JO(Bf.smallBold,["margin-block:0px"]),d=JO(Bf.small,["margin-block:0px"]);e.replaceChildren(),o.forEach(h=>{const g=document.createElement("h3");g.setAttribute("style",c);const m=document.createElement("strong");m.textContent=h,g.appendChild(m),e.appendChild(g)}),l.forEach(h=>{const g=document.createElement("p");g.setAttribute("style",d),g.textContent=h,e.appendChild(g)})}const n=t.chart.canvas.getBoundingClientRect();let i=!1;r.caretX>r.chart.width*.9&&(i=!0);const a=i?"unset":n.left+window.scrollX+r.caretX+"px",s=i?n.width+window.scrollX-r.caretX+110+"px":"unset";e.style.opacity="1",e.style.position="absolute",e.style.left=a,e.style.right=s,e.style.top=n.top+window.scrollY+r.caretY+"px",e.style.padding="8px 12px",e.style.pointerEvents="none",e.style.backgroundColor=Tn.surface,e.style.boxShadow="0px 0px 0px 1px "+Tn.onSurfaceVariant,e.style.borderRadius="12px"},une=(t,e,r,n)=>{if(!t)return[];const i=[];return t.forEach(a=>{const s=e.find(o=>o.id===a.deviceDataId);s!=null&&s.selected&&i.push(a)}),i.map(a=>{const{deviceDataId:s,deviceName:o,trendData:l}=a;return l.map(c=>{const{maxValue:d,minValue:h,pointValue:g}=c;let{pollDateTime:m}=c;r&&(m=m.replace(" ","T"));const v=n(m,r);return{deviceDataId:s,deviceName:o,date:v,minValue:h,maxValue:d,pointValue:g}})}).flat()};async function lne(t,e){const r=new Blob([t]),n=URL.createObjectURL(r),i=document.createElement("a");i.download=`${e}.csv`,i.href=n,i.target="_blank",document.body.appendChild(i),i.click(),document.body.removeChild(i)}function cne(t,e,r=!1){const n=document.createElement("a");n.download=e,r?n.href=t:n.href="data:application/octet-stream;base64,"+t,n.target="_blank",n.click()}const fne=t=>{const{assetName:e,chartType:r,dailyRef:n,data:i,devices:a,sitecode:s,trendRef:o}=t,{t:l}=Qt("location"),{formatDateTime:c}=z0(),d=()=>`${l("dcim-chart.export.file-name",{location:e,site:s,view:mr.startCase(r)})}`;return{createFileName:d,exportCsv:()=>{const m=new sne({fields:one(l)}),v=r===wr.Trend,b=une(i,a,v,c),y=m.parse(b),x=d();lne(y,x)},exportImage:()=>{const v=(r===wr.Trend?o:n).toBase64Image()||"",b=d();cne(v,`${b}.png`,!0)}}},dne=t=>{const{disabled:e}=t,r=fne(t);return A.jsxs(Ao,{children:[A.jsx(bI,{type:"button",disabled:e,onClick:r.exportImage,$color:"var(--clr-primary, #1456e0)",children:A.jsx(Zre,{width:20,height:20})}),A.jsx(bI,{type:"button",disabled:e,onClick:r.exportCsv,$color:"var(--clr-success, #4caf50)",children:A.jsx(Jre,{width:20,height:20})})]})},hne="ohlc",pne=(t,e,r,n)=>r.length?{datasets:r.map(a=>{const{deviceDataId:s,trendData:o,deviceName:l}=a;let c=[];const d=n.find(g=>g.id===s);return o.forEach(({maxValue:g,minValue:m,pointValue:v,utcPollDateTime:b})=>{const y=[],x=cn(b).getTime(),w=mr.chain(t).filter(S=>S.ddid===s).findLast(({alertTimeStamp:S})=>xB(x,cn(S))).value();w&&y.push({x,y:Number(w.functionValue),alert:w}),y.push({x,y:Number(v)},{x,y:Number(m)},{x,y:Number(g)}),c=c.concat(y.map((S,E)=>({...S,index:E,hasAlert:w!==void 0})))}),c=c.sort((g,m)=>g.x-m.x),{animation:{duration:500,easing:"easeInOutCubic"},data:c,hidden:!(d!=null&&d.selected),label:l,pointBackgroundColor:g=>{const m=g.raw;return m.alert?Tn.critical:m.index===0||m.hasAlert&&m.index===1?Tn.onSurface:Tn.surface},pointBorderColor:g=>{const m=g.raw,{borderColor:v}=g.dataset;return m.alert?Tn.critical:m.index===0?v==null?void 0:v.toString():Tn.onSurface},...e}})}:{datasets:[]},sL=(t=!1,e,r,n,i)=>({maintainAspectRatio:!1,animation:!1,scales:{x:{type:"time",time:{unit:"hour",tooltipFormat:`EEE, MMM dd, yyyy ${n}`},ticks:{minRotation:t?90:45,maxTicksLimit:t?12:24,callback:a=>Yu(Number(a),`${n} dd MMM`,{locale:e})}},y:{type:"linear"},y1:{axis:"y",type:"linear",position:"right",border:{display:!1},grid:{display:!1},ticks:{display:!1},title:{display:!0,text:r,padding:{bottom:32},font:Wf}}},font:Wf,plugins:{legend:{display:!1},colors:{enabled:!1},annotation:i?{annotations:[{backgroundColor:Tn.outlineVariant,borderColor:i0("#000",.5),type:"box",xMin:cn(i.startDate).getTime(),xMax:cn(i.endDate).getTime()}]}:{}}}),gne=(t,e,r)=>{const{t:n}=Qt("location"),{adapterLocale:i}=CR(),{getTimeFormatString:a}=z0(),{isMobile:s}=To(),o=sL(s,i,r,a(!1),t),l=mne(n,e,a(!1));return mr.merge(o,l)},mne=(t,e,r)=>{const n=t("dcim-chart.point-value.daily-avg"),i=t("dcim-chart.point-value.daily-min"),a=t("dcim-chart.point-value.daily-max"),s=t("dcim-chart.point-value.current");return{scales:{x:{ticks:{source:"data"}}},plugins:{tooltip:{callbacks:{title:()=>[e],label:l=>{const c=l.raw,d=[n,i,a];c.hasAlert&&d.unshift("");let h=l.label,g=" ";if(c.alert){const{alertType:v,alertCategory:b,alertTimeStamp:y}=c.alert;g=t("dcim-chart.point-value.alert",{type:mr.upperFirst(v),category:mr.upperFirst(b)}),d.unshift(g),h=Yu(cn(y),`EEE, MMM dd, yyyy ${r}`)}const m=d[c.index];return[h,m,`${s}: ${l.formattedValue}`]}},enabled:!1,external:l=>aL(l)}}}},vne=({alerts:t=[],data:e=[],deviceList:r=[],plannedMaintenance:n,setChartRef:i,title:a="",yAxisLabel:s})=>{const o=gne(n,a,s),l=pne(t,o,e,r);return A.jsx(tL,{children:A.jsx(QP,{data:l,options:o,ref:i,type:hne,width:"100%"})})},yne=(t,e,r=[],n)=>r.length?{datasets:r.map(a=>{const{deviceDataId:s,trendData:o,deviceName:l}=a,c=[],d=n.find(h=>h.id===s);return o.forEach(({pointValue:h,utcPollDateTime:g})=>{const m=cn(g).getTime();c.push({x:m,y:Number(h)})}),t==null||t.filter(h=>h.ddid===s).forEach(h=>{c.push({x:cn(h.alertTimeStamp).getTime(),y:Number(h.functionValue),alert:h})}),c.sort((h,g)=>h.x-g.x),{animation:{duration:500,easing:"easeInOutCubic"},borderColor:d==null?void 0:d.color,borderJoinStyle:"bevel",data:c,hidden:!(d!=null&&d.selected),label:l,pointBackgroundColor:h=>EI(h.raw),pointBorderColor:h=>EI(h.raw),pointBorderWidth:h=>h.raw.alert?2:0,pointRadius:2,...e}})}:{datasets:[]};function EI(t){return t.alert?Tn.critical:Tn.onSurface}const bne=(t,e,r,n)=>{const{t:i}=Qt("location"),{adapterLocale:a}=CR(),{getTimeFormatString:s}=Id(),{isMobile:o}=To(),l=sL(o,a,n,s(!1),t),c=_ne(e,r,i("dcim-chart.point-value.current"));return mr.merge(l,c)},_ne=(t,e,r)=>({elements:{line:{borderWidth:2}},plugins:{tooltip:{callbacks:{title:()=>[t],label:i=>[i.label,e,`${r}: ${i.formattedValue}`]},enabled:!1,external:i=>aL(i)}},scales:{x:{ticks:{source:"data"}}}}),xne=({alerts:t=[],data:e=[],deviceList:r=[],plannedMaintenance:n,setChartRef:i,title:a="",unitInfo:s="",yAxisLabel:o})=>{const l=bne(n,a,s,o),c=yne(t,l,e,r);return A.jsx(tL,{children:A.jsx(eL,{data:c,options:l,ref:i,width:"100%"})})},wne=({children:t,style:e,...r})=>{const n=Ve(Et("sm"));return A.jsx("div",{style:{display:"flex",flexDirection:n?"column":"row",alignItems:"inherit",gap:8,...e},...r,children:t})},OI=t=>t,Tne=({isMobile:t,metric:e,options:r,setMetric:n,title:i})=>A.jsxs(wne,{children:[A.jsx(lt,{variant:"body2",style:{whiteSpace:"nowrap"},children:i}),A.jsx(K0,{ariaLabel:i,getOptionLabel:OI,getOptionValue:OI,onChange:n,options:r,style:t?{width:"100%"}:void 0,value:e})]}),Sne=({children:t,style:e,...r})=>A.jsx(qre,{style:{paddingTop:"40%",...e},...r,children:t}),Cne=({style:t,...e})=>A.jsx(so,{style:{position:"absolute",top:0,left:0,width:"100%",height:"100%",...t},...e}),Ene=()=>A.jsxs(Hre,{children:[A.jsxs("div",{style:{display:"flex",flexDirection:"row",alignItems:"center",justifyContent:"space-between",marginBottom:24},children:[A.jsx(g0,{children:A.jsx(so,{width:125,variant:"rectangular"})}),A.jsx(g0,{children:A.jsx(so,{width:"30vw",variant:"rectangular"})}),A.jsx(so,{width:125,variant:"rectangular"})]}),A.jsx(Sne,{children:A.jsx(Cne,{variant:"rectangular",style:{position:"absolute",top:0,left:0,width:"100%",height:"100%"}})})]}),One=t=>{const{label:e,setShowAlerts:r,showAlerts:n}=t;return A.jsx(F0,{checked:n,label:e,onCheckboxChange:i=>r(i.target.checked)})},Ane=t=>AI[t%AI.length],AI=["#1f77b4","#aec7e8","#ff7f0e","#ffbb78","#2ca02c","#98df8a","#d62728","#ff9896","#9467bd","#c5b0d5","#8c564b","#c49c94","#e377c2","#f7b6d2","#7f7f7f","#c7c7c7","#bcbd22","#dbdb8d","#17becf","#9edae5","#393b79","#5254a3","#6b6ecf","#9c9ede","#637939","#8ca252","#b5cf6b","#cedb9c","#8c6d31","#bd9e39","#e7ba52","#e7cb94","#843c39","#ad494a","#d6616b","#e7969c","#7b4173","#a55194","#ce6dbd","#de9ed6","#3182bd","#6baed6","#9ecae1","#c6dbef","#e6550d","#fd8d3c","#fdae6b","#fdd0a2","#31a354","#74c476"],Ine=({children:t,style:e,...r})=>{const n=Ve(Et("sm"));return A.jsx(Ao,{style:{...n?{alignItems:"center",flexWrap:"wrap",rowGap:20}:null,...e},...r,children:t})},Rne=()=>({height:48,...Ve(Et("sm"))?{width:"auto"}:{minWidth:180}}),Dne="yyyy-MM-dd",Mne=/^\d{4}-\d{2}-\d{2}$/,Cy=t=>wo(t)?Yu(t,Dne):"",II=t=>t&&Mne.test(t)&&wo(cn(t))?t:"",oL=({from:t,to:e},r)=>{const n=t?t>r?"future":"":"from-required";let i="";return e?e>r?i="future":t&&e<t&&(i="to-before-from"):i="to-required",{from:n,to:i}},RI=(t,e)=>{const r=oL(t,e);return!r.from&&!r.to},Pne=(t,e)=>{const{t:r}=Qt("location",{keyPrefix:"dcim-chart.date-range.errors"}),[n,i]=or(null),a=Cy(new Date),s={from:Cy(t.startDate),to:Cy(t.endDate)},o=n??s,l=n?oL(n,a):{from:"",to:""},c=m=>{i(null),!(m.from===s.from&&m.to===s.to)&&e({startDate:fs(cn(m.from)),endDate:Od(cn(m.to))})},d=m=>{const v=II(m);v!==o.from&&i({from:v,to:v&&o.to&&v>o.to?"":o.to})},h=m=>{const v=II(m);if(v===o.to)return;const b={from:o.from,to:v};RI(b,a)?c(b):i(b)},g=()=>{n&&(RI(n,a)?c(n):i(null))};return{endDateErrorText:l.to?r(l.to):"",endDateValue:o.to,isStaged:n!==null,maxEndDate:a,maxStartDate:a,minEndDate:o.from,onEndDateChanged:h,onLeave:g,onStartDateChanged:d,startDateErrorText:l.from?r(l.from):"",startDateValue:o.from}},DI="vaadin-date-picker-overlay",Lne=(t,e,r)=>{const n=$t(r);n.current=r,ut(()=>{if(!t)return;const i=e.map(l=>l.current).filter(l=>!!l),a=l=>l instanceof Element&&(l.localName===DI||!!l.closest(DI)||i.some(c=>c===l||c.contains(l))),s=l=>{l.composedPath().some(a)||n.current()},o=l=>{l.relatedTarget&&!a(l.relatedTarget)&&n.current()};return document.addEventListener("pointerdown",s,!0),i.forEach(l=>l.addEventListener("focusout",o)),()=>{document.removeEventListener("pointerdown",s,!0),i.forEach(l=>l.removeEventListener("focusout",o))}},[t,e])},Nne=({dateInterval:t,setDateInterval:e})=>{const{t:r}=Qt("location"),{dateTimeFormatPreferences:n}=Id(),{isMobile:i}=To(),a=Rne(),s=$t(null),o=$t(null),l=yr(()=>[s,o],[]),{endDateErrorText:c,endDateValue:d,isStaged:h,maxEndDate:g,maxStartDate:m,minEndDate:v,onEndDateChanged:b,onLeave:y,onStartDateChanged:x,startDateErrorText:w,startDateValue:S}=Pne(t,e);return Lne(h,l,y),A.jsxs(Ine,{children:[A.jsx(Ny,{ref:s,style:a,errorText:w,format:n.preferredDateFormat,label:r("dcim-chart.date-range.from"),max:m,onChanged:x,showCalendarOnMouseDown:!0,timezone:"UTC",value:S}),i&&A.jsx(lt,{variant:"caption",children:r("dcim-chart.utc")}),A.jsx(Ny,{ref:o,style:a,errorText:c,format:n.preferredDateFormat,label:r("dcim-chart.date-range.to"),max:g,min:v,onChanged:b,showCalendarOnMouseDown:!0,timezone:"UTC",value:d}),A.jsx(lt,{variant:"caption",children:r("dcim-chart.utc")})]})},Fne=async t=>{let e=[];try{const r=await OD({...t,leasedSpaceName:t.leasedSpaceName}),n=await CD(t);e=(r==null?void 0:r.content)||[],e=e.concat(n==null?void 0:n.content)}catch{return e}return e},kne=(t,e)=>{const r=`${fn.DCIM_ALERTS}-${fn.DCIM_HISTORICAL_ALERTS}`;return Ui([r,t],()=>Fne(t),{refetchOnWindowFocus:!1,...e})},jne=(t,e,r)=>{const n=[];return t&&e&&n.push(a3(new Date(t),new Date(e))),r&&n.push(r),n.join(" ")},$ne=t=>{const{t:e}=Qt(["location","notifications"]),{isMobile:r}=To(),{assetName:n,endDate:i,functionName:a,interval:s,leasedSpaceName:o,sitecode:l,startDate:c,subCategory:d=""}=t,[h,g]=or({startDate:fs(Date.parse(c)),endDate:Od(Date.parse(i))}),[m,v]=or(wr.Trend),b=RU(),[y,x]=or(!0),[w,S]=or(a),[E,C]=or([]),[I,T]=or(s||ei.Hour),[D,P]=or([]);ut(()=>{I===ei.Day&&v(wr.Daily)},[I,T]);const[L,F]=or(null),[H,X]=or(null),ee=SD(o,{enabled:!!l&&!!n}),J=TD({endDate:h.endDate.toISOString(),functionName:a,interval:I,leasedSpaceName:o,startDate:h.startDate.toISOString(),subCategory:d},{enabled:ee.isSuccess}),te=kne({endDate:h.endDate.toISOString(),leasedSpaceName:o,startDate:h.startDate.toISOString()}),ce=W5(l,n,h.startDate.toISOString(),h.endDate.toISOString());ut(()=>{var Ge;const ve=((Ge=J.data)==null?void 0:Ge.portalTrendData)||[],ct=ve.map((Le,Ue)=>({color:Ane(Ue),id:Le.deviceDataId,name:Le.deviceName,selected:Ue===0}));C(ct),P(ve)},[J.data]);const B=rt(ve=>{v(ve),ve===wr.Trend&&T(ei.Hour)},[]),ae=jne(c,i,a),Ce=J.isLoading||ee.isLoading||te.isLoading,Ae=E.filter(ve=>ve.selected).length;return A.jsxs(eb,{children:[A.jsx(rb,{assetName:n,sitecode:l}),A.jsxs(tb,{spacing:{xs:2.5,md:0},children:[A.jsx(zr,{xs:12,sm:3,md:2,lg:2,children:A.jsx(Ure,{devices:E,isLoading:Ce,setDevices:C,title:d})}),A.jsx(zr,{xs:12,sm:9,md:10,lg:10,children:A.jsx("div",{children:A.jsxs(A.Fragment,{children:[A.jsxs(Ere,{children:[A.jsx(Nne,{dateInterval:h,setDateInterval:g}),m===wr.Trend&&A.jsx(Vre,{endDate:h.endDate,interval:I,numberOfDevices:E.length,setInterval:T,startDate:h.startDate}),A.jsxs(Ore,{children:[A.jsx(Yre,{idPrefix:b,onChange:B,viewType:m}),A.jsx(dne,{assetName:n,chartType:m,dailyRef:H,data:D,devices:E,disabled:J.isLoading||Ae===0,sitecode:l||"",trendRef:L})]})]}),Ce?A.jsx(Ene,{}):A.jsxs(Are,{elevation:r?0:1,children:[A.jsxs(Ire,{children:[A.jsx(Tne,{isMobile:r,metric:w,options:[a],setMetric:S,title:e("dcim-chart.y-axis-metric")}),A.jsxs(Rre,{children:[A.jsxs(Ao,{children:[A.jsx(Cre,{}),A.jsx(lt,{variant:"caption",children:ae})]}),A.jsx(Mre,{type:"button",children:e("notifications:type.planned_site_maintenance")}),A.jsx(lt,{variant:"caption",children:e("dcim-chart.timezone.utc")})]}),A.jsx(One,{label:e("dcim-chart.show-alert-data"),setShowAlerts:x,showAlerts:y})]}),A.jsx("div",{role:"tabpanel",id:v0(b,wr.Trend),"aria-labelledby":m0(b,wr.Trend),hidden:m!==wr.Trend,children:m===wr.Trend&&A.jsx(xne,{alerts:y?te.data:[],data:D,deviceList:E,plannedMaintenance:ce.data,setChartRef:F,title:`${d} | UTC`,unitInfo:ae,yAxisLabel:a})}),A.jsx("div",{role:"tabpanel",id:v0(b,wr.Daily),"aria-labelledby":m0(b,wr.Daily),hidden:m!==wr.Daily,children:m===wr.Daily&&A.jsx(vne,{alerts:y?te.data:[],data:D,deviceList:E,plannedMaintenance:ce.data,setChartRef:X,title:`${d} | UTC`,yAxisLabel:a})})]})]})})})]})]})},Une=()=>{const t=window.location.search.slice(1),e=Pd.parse(t),{assetName:r,endDate:n,functionName:i,interval:a,sitecode:s,startDate:o,subCategory:l}=e,c=`${s}-${r}`;return ut(()=>{window.dispatchEvent(new CustomEvent(Yd,{detail:{location:{route:{hideAccountSwitcher:!0}}}}))},[]),A.jsx(Y0,{children:A.jsx($ne,{assetName:r,endDate:n,functionName:i,interval:a,leasedSpaceName:c,sitecode:s,startDate:o,subCategory:l})})},qne=()=>{const t=window.location.search.slice(1),e=Pd.parse(t),{assetName:r,sitecode:n}=e,i=`${n}-${r}`;return ut(()=>{window.dispatchEvent(new CustomEvent(Yd,{detail:{location:{route:{hideAccountSwitcher:!0}}}}))},[]),A.jsx(Y0,{children:A.jsx(bre,{assetName:r,date:new Date,leasedSpaceName:i,sitecode:n})})},Hne=({children:t,style:e,...r})=>{const n=Ve(Et("md"));return A.jsx("div",{style:{display:"flex",flexDirection:"column",gap:n?26:42,...e},...r,children:t})},MI=({children:t,style:e,...r})=>{const n=Ve(Et("lg")),i=Ve(pa("lg"));return A.jsx("p",{style:{margin:0,fontFamily:`var(--root-primary-font, ${Tu})`,fontSize:12,lineHeight:"16px",maxWidth:n?"100%":240,...i?{paddingTop:47}:null,...e},...r,children:t})},Wne=({assetName:t,leasedSpaceName:e,sitecode:r,type:n})=>{const{t:i}=Qt("location"),a=Ve(Et("sm")),s=Ve(Et("lg")),[o,l]=or({category:co,type:n||on.CUSTOM}),c=(d,h)=>{l(g=>({...g,[d]:h}))};return A.jsx("div",{children:A.jsxs(gD,{children:[A.jsxs(S5,{children:[A.jsx(T5,{children:t}),A.jsx(lt,{variant:"subtitle1",children:r})]}),A.jsxs(Xf,{spacing:{xs:2.5,md:3},children:[A.jsx(zr,{xs:12,sm:4,md:4,lg:3,xl:2,children:A.jsxs(Hne,{children:[A.jsx(ob,{leasedSpaceName:e,filters:o,handleFilters:c,disableOptionHistory:!0,disableOptionAll:!0,isDefinitionsView:!0}),A.jsx(qD,{leasedSpaceName:e,filters:o,handleFilters:c,isDefinitionsView:!0}),s&&!a&&A.jsx(MI,{children:i("alerts.definitions.warning-message")})]})}),A.jsx(zr,{xs:12,sm:8,md:8,lg:7,xl:7,children:A.jsx(sP,{leasedSpaceName:e,alertType:o.type,alertCategory:o.category,title:i("alerts.definitions.title"),isDefinitionsView:!0})}),!s&&A.jsx(zr,{xs:12,lg:2,xl:3,children:A.jsx(MI,{children:i("alerts.definitions.warning-message")})})]})]})})},Bne=()=>{const t=window.location.search.slice(1),e=Pd.parse(t),{assetName:r,sitecode:n,type:i}=e,a=`${n}-${r}`;return ut(()=>{window.dispatchEvent(new CustomEvent(Yd,{detail:{location:{route:{hideAccountSwitcher:!0}}}}))},[]),A.jsx(Y0,{children:A.jsx(Wne,{assetName:r,date:new Date,leasedSpaceName:a,sitecode:n,type:i})})},zae=[{path:"/details",element:A.jsx(qne,{})},{path:"/chart",element:A.jsx(Une,{})},{path:"/alert",element:A.jsx(BZ,{})},{path:"/alerts-definitions",element:A.jsx(Bne,{})},{path:"/*",element:A.jsx(RH,{to:"/details",replace:!0})}];class Jb extends ao{draw(){const{data:e}=this.getMeta(),r=Object.values(mr.groupBy(e,"x")),{radius:n,borderColor:i}=e[0].options,a=this.chart.ctx;a.strokeStyle=i,a.lineWidth=1,a.beginPath(),r.forEach(s=>{const[o,l]=s.slice(-2);a.moveTo(o.x,o.y-n),a.lineTo(l.x,l.y+n),a.stroke()}),super.draw()}}Jb.id="ohlc";Jb.defaults=ao.defaults;/*!
|
|
115
|
+
* chartjs-plugin-annotation v2.2.1
|
|
116
|
+
* https://www.chartjs.org/chartjs-plugin-annotation/index
|
|
117
|
+
* (c) 2023 chartjs-plugin-annotation Contributors
|
|
118
|
+
* Released under the MIT License
|
|
119
|
+
*/const PI={modes:{point(t,e){return Sf(t,e,{intersect:!0})},nearest(t,e,r){return Gne(t,e,r)},x(t,e,r){return Sf(t,e,{intersect:r.intersect,axis:"x"})},y(t,e,r){return Sf(t,e,{intersect:r.intersect,axis:"y"})}}};function Qb(t,e,r){return(PI.modes[r.mode]||PI.modes.nearest)(t,e,r)}function zne(t,e,r){return r!=="x"&&r!=="y"?t.inRange(e.x,e.y,"x",!0)||t.inRange(e.x,e.y,"y",!0):t.inRange(e.x,e.y,r,!0)}function Vne(t,e,r){return r==="x"?{x:t.x,y:e.y}:r==="y"?{x:e.x,y:t.y}:e}function Sf(t,e,r){return t.visibleElements.filter(n=>r.intersect?n.inRange(e.x,e.y):zne(n,e,r.axis))}function Gne(t,e,r){let n=Number.POSITIVE_INFINITY;return Sf(t,e,r).reduce((i,a)=>{const s=a.getCenterPoint(),o=Vne(e,s,r.axis),l=go(e,o);return l<n?(i=[a],n=l):l===n&&i.push(a),i},[]).sort((i,a)=>i._index-a._index).slice(0,1)}const Kne=(t,e)=>e>t||t.length>e.length&&t.slice(0,e.length)===e,is=.001,eh=(t,e,r)=>Math.min(r,Math.max(e,t));function Xne(t,e,r){for(const n of Object.keys(t))t[n]=eh(t[n],e,r);return t}function Yne(t,e,r,n){if(!t||!e||r<=0)return!1;const i=n/2;return Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2)<=Math.pow(r+i,2)}function uL(t,{x:e,y:r,x2:n,y2:i},a,s){const o=s/2,l=t.x>=e-o-is&&t.x<=n+o+is,c=t.y>=r-o-is&&t.y<=i+o+is;return a==="x"?l:(a==="y"||l)&&c}function Io(t,e){const{centerX:r,centerY:n}=t.getProps(["centerX","centerY"],e);return{x:r,y:n}}function Zne(t,e,r,n=!0){const i=r.split(".");let a=0;for(const s of e.split(".")){const o=i[a++];if(parseInt(s,10)<parseInt(o,10))break;if(Kne(o,s)){if(n)throw new Error(`${t} v${r} is not supported. v${e} or newer is required.`);return!1}}return!0}const lL=t=>typeof t=="string"&&t.endsWith("%"),cL=t=>parseFloat(t)/100,fL=t=>eh(cL(t),0,1);function e_(t,e){return e==="start"?0:e==="end"?t:lL(e)?fL(e)*t:t/2}function wa(t,e,r=!0){return typeof e=="number"?e:lL(e)?(r?fL(e):cL(e))*t:t}function Jne(t,e){const{x:r,width:n}=t,i=e.textAlign;return i==="center"?r+n/2:i==="end"||i==="right"?r+n:r}function t_(t,e="center"){return it(t)?{x:Xe(t.x,e),y:Xe(t.y,e)}:(t=Xe(t,e),{x:t,y:t})}function dL(t){return t&&(Sn(t.xValue)||Sn(t.yValue))}function al(t,e,r,n=!1){const i=r.init;if(i){if(i===!0)return pL(e,n)}else return;return Qne(e,n,Ut(i,[{chart:t,properties:e,options:r}]))}function hL(t,e,r){let n=!1;return e.forEach(i=>{ln(t[i])?(n=!0,r[i]=t[i]):Sn(r[i])&&delete r[i]}),n}function pL({centerX:t,centerY:e},r){return r?{centerX:t,centerY:e,radius:0,width:0,height:0}:{x:t,y:e,x2:t,y2:e,width:0,height:0}}function Qne(t,e,r){if(r===!0)return pL(t,e);if(it(r))return r}const Ey=new Map,eie=t=>isNaN(t)||t<=0,tie=t=>t.reduce(function(e,r){return e+=r.string,e},"");function th(t){if(t&&typeof t=="object"){const e=t.toString();return e==="[object HTMLImageElement]"||e==="[object HTMLCanvasElement]"}}function r_(t,{x:e,y:r},n){n&&(t.translate(e,r),t.rotate(jr(n)),t.translate(-e,-r))}function Ta(t,e){if(e&&e.borderWidth)return t.lineCap=e.borderCapStyle,t.setLineDash(e.borderDash),t.lineDashOffset=e.borderDashOffset,t.lineJoin=e.borderJoinStyle,t.lineWidth=e.borderWidth,t.strokeStyle=e.borderColor,!0}function Ro(t,e){t.shadowColor=e.backgroundShadowColor,t.shadowBlur=e.shadowBlur,t.shadowOffsetX=e.shadowOffsetX,t.shadowOffsetY=e.shadowOffsetY}function n_(t,e){const r=e.content;if(th(r))return{width:wa(r.width,e.width),height:wa(r.height,e.height)};const n=e.font,i=Xt(n)?n.map(l=>Or(l)):[Or(n)],a=e.textStrokeWidth,s=Xt(r)?r:[r],o=s.join()+tie(i)+a+(t._measureText?"-spriting":"");return Ey.has(o)||Ey.set(o,sie(t,s,i,a)),Ey.get(o)}function gL(t,e,r){const{x:n,y:i,width:a,height:s}=e;t.save(),Ro(t,r);const o=Ta(t,r);t.fillStyle=r.backgroundColor,t.beginPath(),dd(t,{x:n,y:i,w:a,h:s,radius:Xne(no(r.borderRadius),0,Math.min(a,s)/2)}),t.closePath(),t.fill(),o&&(t.shadowColor=r.borderShadowColor,t.stroke()),t.restore()}function rie(t,e,r){const n=r.content;if(th(n)){t.save(),t.globalAlpha=lie(r.opacity,n.style.opacity),t.drawImage(n,e.x,e.y,e.width,e.height),t.restore();return}const i=Xt(n)?n:[n],a=r.font,s=Xt(a)?a.map(h=>Or(h)):[Or(a)],o=r.color,l=Xt(o)?o:[o],c=Jne(e,r),d=e.y+r.textStrokeWidth/2;t.save(),t.textBaseline="middle",t.textAlign=r.textAlign,nie(t,r)&&oie(t,{x:c,y:d},i,s),uie(t,{x:c,y:d},i,{fonts:s,colors:l}),t.restore()}function nie(t,e){if(e.textStrokeWidth>0)return t.lineJoin="round",t.miterLimit=2,t.lineWidth=e.textStrokeWidth,t.strokeStyle=e.textStrokeColor,!0}function iie(t,e,r,n){const{radius:i,options:a}=e,s=a.pointStyle,o=a.rotation;let l=(o||0)*Ub;if(th(s)){t.save(),t.translate(r,n),t.rotate(l),t.drawImage(s,-s.width/2,-s.height/2,s.width,s.height),t.restore();return}eie(i)||aie(t,{x:r,y:n,radius:i,rotation:o,style:s,rad:l})}function aie(t,{x:e,y:r,radius:n,rotation:i,style:a,rad:s}){let o,l,c,d;switch(t.beginPath(),a){default:t.arc(e,r,n,0,Wn),t.closePath();break;case"triangle":t.moveTo(e+Math.sin(s)*n,r-Math.cos(s)*n),s+=cd,t.lineTo(e+Math.sin(s)*n,r-Math.cos(s)*n),s+=cd,t.lineTo(e+Math.sin(s)*n,r-Math.cos(s)*n),t.closePath();break;case"rectRounded":d=n*.516,c=n-d,o=Math.cos(s+qn)*c,l=Math.sin(s+qn)*c,t.arc(e-o,r-l,d,s-Ht,s-Gr),t.arc(e+l,r-o,d,s-Gr,s),t.arc(e+o,r+l,d,s,s+Gr),t.arc(e-l,r+o,d,s+Gr,s+Ht),t.closePath();break;case"rect":if(!i){c=Math.SQRT1_2*n,t.rect(e-c,r-c,2*c,2*c);break}s+=qn;case"rectRot":o=Math.cos(s)*n,l=Math.sin(s)*n,t.moveTo(e-o,r-l),t.lineTo(e+l,r-o),t.lineTo(e+o,r+l),t.lineTo(e-l,r+o),t.closePath();break;case"crossRot":s+=qn;case"cross":o=Math.cos(s)*n,l=Math.sin(s)*n,t.moveTo(e-o,r-l),t.lineTo(e+o,r+l),t.moveTo(e+l,r-o),t.lineTo(e-l,r+o);break;case"star":o=Math.cos(s)*n,l=Math.sin(s)*n,t.moveTo(e-o,r-l),t.lineTo(e+o,r+l),t.moveTo(e+l,r-o),t.lineTo(e-l,r+o),s+=qn,o=Math.cos(s)*n,l=Math.sin(s)*n,t.moveTo(e-o,r-l),t.lineTo(e+o,r+l),t.moveTo(e+l,r-o),t.lineTo(e-l,r+o);break;case"line":o=Math.cos(s)*n,l=Math.sin(s)*n,t.moveTo(e-o,r-l),t.lineTo(e+o,r+l);break;case"dash":t.moveTo(e,r),t.lineTo(e+Math.cos(s)*n,r+Math.sin(s)*n);break}t.fill()}function sie(t,e,r,n){t.save();const i=e.length;let a=0,s=n;for(let o=0;o<i;o++){const l=r[Math.min(o,r.length-1)];t.font=l.string;const c=e[o];a=Math.max(a,t.measureText(c).width+n),s+=l.lineHeight}return t.restore(),{width:a,height:s}}function oie(t,{x:e,y:r},n,i){t.beginPath();let a=0;n.forEach(function(s,o){const l=i[Math.min(o,i.length-1)],c=l.lineHeight;t.font=l.string,t.strokeText(s,e,r+c/2+a),a+=c}),t.stroke()}function uie(t,{x:e,y:r},n,{fonts:i,colors:a}){let s=0;n.forEach(function(o,l){const c=a[Math.min(l,a.length-1)],d=i[Math.min(l,i.length-1)],h=d.lineHeight;t.beginPath(),t.font=d.string,t.fillStyle=c,t.fillText(o,e,r+h/2+s),s+=h,t.fill()})}function lie(t,e){const r=ps(t)?t:e;return ps(r)?eh(r,0,1):1}const LI={xScaleID:{min:"xMin",max:"xMax",start:"left",end:"right",startProp:"x",endProp:"x2"},yScaleID:{min:"yMin",max:"yMax",start:"bottom",end:"top",startProp:"y",endProp:"y2"}};function yo(t,e,r){return e=typeof e=="number"?e:t.parse(e),Ir(e)?t.getPixelForValue(e):r}function ms(t,e,r){const n=e[r];if(n||r==="scaleID")return n;const i=r.charAt(0),a=Object.values(t).filter(s=>s.axis&&s.axis===i);return a.length?a[0].id:i}function mL(t,e){if(t){const r=t.options.reverse,n=yo(t,e.min,r?e.end:e.start),i=yo(t,e.max,r?e.start:e.end);return{start:n,end:i}}}function vL(t,e){const{chartArea:r,scales:n}=t,i=n[ms(n,e,"xScaleID")],a=n[ms(n,e,"yScaleID")];let s=r.width/2,o=r.height/2;return i&&(s=yo(i,e.xValue,i.left+i.width/2)),a&&(o=yo(a,e.yValue,a.top+a.height/2)),{x:s,y:o}}function i_(t,e){const r=t.scales,n=r[ms(r,e,"xScaleID")],i=r[ms(r,e,"yScaleID")];if(!n&&!i)return{};let{left:a,right:s}=n||t.chartArea,{top:o,bottom:l}=i||t.chartArea;const c=NI(n,{min:e.xMin,max:e.xMax,start:a,end:s});a=c.start,s=c.end;const d=NI(i,{min:e.yMin,max:e.yMax,start:l,end:o});return o=d.start,l=d.end,{x:a,y:o,x2:s,y2:l,width:s-a,height:l-o,centerX:a+(s-a)/2,centerY:o+(l-o)/2}}function yL(t,e){if(!dL(e)){const r=i_(t,e);let n=e.radius;(!n||isNaN(n))&&(n=Math.min(r.width,r.height)/2,e.radius=n);const i=n*2,a=r.centerX+e.xAdjust,s=r.centerY+e.yAdjust;return{x:a-n,y:s-n,x2:a+n,y2:s+n,centerX:a,centerY:s,width:i,height:i,radius:n}}return fie(t,e)}function cie(t,e){const{scales:r,chartArea:n}=t,i=r[e.scaleID],a={x:n.left,y:n.top,x2:n.right,y2:n.bottom};return i?die(i,a,e):hie(r,a,e),a}function bL(t,e,r){const n=i_(t,e);return n.initProperties=al(t,n,e,r),n.elements=[{type:"label",optionScope:"label",properties:mie(t,n,e),initProperties:n.initProperties}],n}function fie(t,e){const r=vL(t,e),n=e.radius*2;return{x:r.x-e.radius+e.xAdjust,y:r.y-e.radius+e.yAdjust,x2:r.x+e.radius+e.xAdjust,y2:r.y+e.radius+e.yAdjust,centerX:r.x+e.xAdjust,centerY:r.y+e.yAdjust,radius:e.radius,width:n,height:n}}function NI(t,e){const r=mL(t,e)||e;return{start:Math.min(r.start,r.end),end:Math.max(r.start,r.end)}}function die(t,e,r){const n=yo(t,r.value,NaN),i=yo(t,r.endValue,n);t.isHorizontal()?(e.x=n,e.x2=i):(e.y=n,e.y2=i)}function hie(t,e,r){for(const n of Object.keys(LI)){const i=t[ms(t,r,n)];if(i){const{min:a,max:s,start:o,end:l,startProp:c,endProp:d}=LI[n],h=mL(i,{min:r[a],max:r[s],start:i[o],end:i[l]});e[c]=h.start,e[d]=h.end}}}function pie({properties:t,options:e},r,n,i){const{x:a,x2:s,width:o}=t;return _L({start:a,end:s,borderWidth:e.borderWidth},{position:n.x,padding:{start:i.left,end:i.right},adjust:e.label.xAdjust,size:r.width})}function gie({properties:t,options:e},r,n,i){const{y:a,y2:s,height:o}=t;return _L({start:a,end:s,borderWidth:e.borderWidth},{position:n.y,padding:{start:i.top,end:i.bottom},adjust:e.label.yAdjust,size:r.height})}function _L(t,e){const{start:r,end:n,borderWidth:i}=t,{position:a,padding:{start:s,end:o},adjust:l}=e,c=n-i-r-s-o-e.size;return r+i/2+l+e_(c,a)}function mie(t,e,r){const n=r.label;n.backgroundColor="transparent",n.callout.display=!1;const i=t_(n.position),a=Kr(n.padding),s=n_(t.ctx,n),o=pie({properties:e,options:r},s,i,a),l=gie({properties:e,options:r},s,i,a),c=s.width+a.width,d=s.height+a.height;return{x:o,y:l,x2:o+c,y2:l+d,width:c,height:d,centerX:o+c/2,centerY:l+d/2,rotation:n.rotation}}function Cs(t,e,r){const n=Math.cos(r),i=Math.sin(r),a=e.x,s=e.y;return{x:a+n*(t.x-a)-i*(t.y-s),y:s+i*(t.x-a)+n*(t.y-s)}}const b0=["enter","leave"],a_=b0.concat("click");function vie(t,e,r){e.listened=hL(r,a_,e.listeners),e.moveListened=!1,e._getElements=Qb,b0.forEach(n=>{ln(r[n])&&(e.moveListened=!0)}),(!e.listened||!e.moveListened)&&e.annotations.forEach(n=>{!e.listened&&ln(n.click)&&(e.listened=!0),e.moveListened||b0.forEach(i=>{ln(n[i])&&(e.listened=!0,e.moveListened=!0)})})}function yie(t,e,r){if(t.listened)switch(e.type){case"mousemove":case"mouseout":return bie(t,e,r);case"click":return _ie(t,e,r)}}function bie(t,e,r){if(!t.moveListened)return;let n;e.type==="mousemove"?n=Qb(t,e,r.interaction):n=[];const i=t.hovered;t.hovered=n;const a={state:t,event:e};let s=FI(a,"leave",i,n);return FI(a,"enter",n,i)||s}function FI({state:t,event:e},r,n,i){let a;for(const s of n)i.indexOf(s)<0&&(a=xL(s.options[r]||t.listeners[r],s,e)||a);return a}function _ie(t,e,r){const n=t.listeners,i=Qb(t,e,r.interaction);let a;for(const s of i)a=xL(s.options.click||n.click,s,e)||a;return a}function xL(t,e,r){return Ut(t,[e.$context,r])===!0}const gd=["afterDraw","beforeDraw"];function xie(t,e,r){const n=e.visibleElements;e.hooked=hL(r,gd,e.hooks),e.hooked||n.forEach(i=>{e.hooked||gd.forEach(a=>{ln(i.options[a])&&(e.hooked=!0)})})}function kI(t,e,r){if(t.hooked){const n=e.options[r]||t.hooks[r];return Ut(n,[e.$context])}}function wie(t,e,r){const n=Oie(t.scales,e,r);let i=jI(e,n,"min","suggestedMin");i=jI(e,n,"max","suggestedMax")||i,i&&ln(e.handleTickRangeOptions)&&e.handleTickRangeOptions()}function Tie(t,e){for(const r of t)Cie(r,e)}function jI(t,e,r,n){if(Ir(e[r])&&!Sie(t.options,r,n)){const i=t[r]!==e[r];return t[r]=e[r],i}}function Sie(t,e,r){return Sn(t[e])||Sn(t[r])}function Cie(t,e){for(const r of["scaleID","xScaleID","yScaleID"]){const n=ms(e,t,r);n&&!e[n]&&Eie(t,r)&&console.warn(`No scale found with id '${n}' for annotation '${t.id}'`)}}function Eie(t,e){if(e==="scaleID")return!0;const r=e.charAt(0);for(const n of["Min","Max","Value"])if(Sn(t[r+n]))return!0;return!1}function Oie(t,e,r){const n=e.axis,i=e.id,a=n+"ScaleID",s={min:Xe(e.min,Number.NEGATIVE_INFINITY),max:Xe(e.max,Number.POSITIVE_INFINITY)};for(const o of r)o.scaleID===i?$I(o,e,["value","endValue"],s):ms(t,o,a)===i&&$I(o,e,[n+"Min",n+"Max",n+"Value"],s);return s}function $I(t,e,r,n){for(const i of r){const a=t[i];if(Sn(a)){const s=e.parse(a);n.min=Math.min(n.min,s),n.max=Math.max(n.max,s)}}}class Do extends Bn{inRange(e,r,n,i){const{x:a,y:s}=Cs({x:e,y:r},this.getCenterPoint(i),jr(-this.options.rotation));return uL({x:a,y:s},this.getProps(["x","y","x2","y2"],i),n,this.options.borderWidth)}getCenterPoint(e){return Io(this,e)}draw(e){e.save(),r_(e,this.getCenterPoint(),this.options.rotation),gL(e,this,this.options),e.restore()}get label(){return this.elements&&this.elements[0]}resolveElementProperties(e,r){return bL(e,r)}}Do.id="boxAnnotation";Do.defaults={adjustScaleRange:!0,backgroundShadowColor:"transparent",borderCapStyle:"butt",borderDash:[],borderDashOffset:0,borderJoinStyle:"miter",borderRadius:0,borderShadowColor:"transparent",borderWidth:1,display:!0,init:void 0,label:{backgroundColor:"transparent",borderWidth:0,callout:{display:!1},color:"black",content:null,display:!1,drawTime:void 0,font:{family:void 0,lineHeight:void 0,size:void 0,style:void 0,weight:"bold"},height:void 0,opacity:void 0,padding:6,position:"center",rotation:void 0,textAlign:"start",textStrokeColor:void 0,textStrokeWidth:0,width:void 0,xAdjust:0,yAdjust:0,z:void 0},rotation:0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,xMax:void 0,xMin:void 0,xScaleID:void 0,yMax:void 0,yMin:void 0,yScaleID:void 0,z:0};Do.defaultRoutes={borderColor:"color",backgroundColor:"color"};Do.descriptors={label:{_fallback:!0}};const wL=["left","bottom","top","right"];class sl extends Bn{inRange(e,r,n,i){const{x:a,y:s}=Cs({x:e,y:r},this.getCenterPoint(i),jr(-this.rotation));return uL({x:a,y:s},this.getProps(["x","y","x2","y2"],i),n,this.options.borderWidth)}getCenterPoint(e){return Io(this,e)}draw(e){const r=this.options,n=!Sn(this._visible)||this._visible;!r.display||!r.content||!n||(e.save(),r_(e,this.getCenterPoint(),this.rotation),Iie(e,this),gL(e,this,r),rie(e,Fie(this),r),e.restore())}resolveElementProperties(e,r){let n;if(dL(r))n=vL(e,r);else{const{centerX:o,centerY:l}=i_(e,r);n={x:o,y:l}}const i=Kr(r.padding),a=n_(e.ctx,r),s=Aie(n,a,r,i);return{initProperties:al(e,s,r),pointX:n.x,pointY:n.y,...s,rotation:r.rotation}}}sl.id="labelAnnotation";sl.defaults={adjustScaleRange:!0,backgroundColor:"transparent",backgroundShadowColor:"transparent",borderCapStyle:"butt",borderDash:[],borderDashOffset:0,borderJoinStyle:"miter",borderRadius:0,borderShadowColor:"transparent",borderWidth:0,callout:{borderCapStyle:"butt",borderColor:void 0,borderDash:[],borderDashOffset:0,borderJoinStyle:"miter",borderWidth:1,display:!1,margin:5,position:"auto",side:5,start:"50%"},color:"black",content:null,display:!0,font:{family:void 0,lineHeight:void 0,size:void 0,style:void 0,weight:void 0},height:void 0,init:void 0,opacity:void 0,padding:6,position:"center",rotation:0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,textAlign:"center",textStrokeColor:void 0,textStrokeWidth:0,width:void 0,xAdjust:0,xMax:void 0,xMin:void 0,xScaleID:void 0,xValue:void 0,yAdjust:0,yMax:void 0,yMin:void 0,yScaleID:void 0,yValue:void 0,z:0};sl.defaultRoutes={borderColor:"color"};function Aie(t,e,r,n){const i=e.width+n.width+r.borderWidth,a=e.height+n.height+r.borderWidth,s=t_(r.position,"center"),o=UI(t.x,i,r.xAdjust,s.x),l=UI(t.y,a,r.yAdjust,s.y);return{x:o,y:l,x2:o+i,y2:l+a,width:i,height:a,centerX:o+i/2,centerY:l+a/2}}function UI(t,e,r=0,n){return t-e_(e,n)+r}function Iie(t,e){const{pointX:r,pointY:n,options:i}=e,a=i.callout,s=a&&a.display&&Lie(e,a);if(!s||kie(e,a,s))return;if(t.save(),t.beginPath(),!Ta(t,a))return t.restore();const{separatorStart:l,separatorEnd:c}=Rie(e,s),{sideStart:d,sideEnd:h}=Mie(e,s,l);(a.margin>0||i.borderWidth===0)&&(t.moveTo(l.x,l.y),t.lineTo(c.x,c.y)),t.moveTo(d.x,d.y),t.lineTo(h.x,h.y);const g=Cs({x:r,y:n},e.getCenterPoint(),jr(-e.rotation));t.lineTo(g.x,g.y),t.stroke(),t.restore()}function Rie(t,e){const{x:r,y:n,x2:i,y2:a}=t,s=Die(t,e);let o,l;return e==="left"||e==="right"?(o={x:r+s,y:n},l={x:o.x,y:a}):(o={x:r,y:n+s},l={x:i,y:o.y}),{separatorStart:o,separatorEnd:l}}function Die(t,e){const{width:r,height:n,options:i}=t,a=i.callout.margin+i.borderWidth/2;return e==="right"?r+a:e==="bottom"?n+a:-a}function Mie(t,e,r){const{y:n,width:i,height:a,options:s}=t,o=s.callout.start,l=Pie(e,s.callout);let c,d;return e==="left"||e==="right"?(c={x:r.x,y:n+wa(a,o)},d={x:c.x+l,y:c.y}):(c={x:r.x+wa(i,o),y:r.y},d={x:c.x,y:c.y+l}),{sideStart:c,sideEnd:d}}function Pie(t,e){const r=e.side;return t==="left"||t==="top"?-r:r}function Lie(t,e){const r=e.position;return wL.includes(r)?r:Nie(t,e)}function Nie(t,e){const{x:r,y:n,x2:i,y2:a,width:s,height:o,pointX:l,pointY:c,centerX:d,centerY:h,rotation:g}=t,m={x:d,y:h},v=e.start,b=wa(s,v),y=wa(o,v),x=[r,r+b,r+b,i],w=[n+y,a,n,a],S=[];for(let E=0;E<4;E++){const C=Cs({x:x[E],y:w[E]},m,jr(g));S.push({position:wL[E],distance:go(C,{x:l,y:c})})}return S.sort((E,C)=>E.distance-C.distance)[0].position}function Fie({x:t,y:e,width:r,height:n,options:i}){const a=i.borderWidth/2,s=Kr(i.padding);return{x:t+s.left+a,y:e+s.top+a,width:r-s.left-s.right-i.borderWidth,height:n-s.top-s.bottom-i.borderWidth}}function kie(t,e,r){const{pointX:n,pointY:i}=t,a=e.margin;let s=n,o=i;return r==="left"?s+=a:r==="right"?s-=a:r==="top"?o+=a:r==="bottom"&&(o-=a),t.inRange(s,o)}const s_=(t,e,r)=>({x:t.x+r*(e.x-t.x),y:t.y+r*(e.y-t.y)}),_0=(t,e,r)=>s_(e,r,Math.abs((t-e.y)/(r.y-e.y))).x,qI=(t,e,r)=>s_(e,r,Math.abs((t-e.x)/(r.x-e.x))).y,xu=t=>t*t,jie=(t,e,{x:r,y:n,x2:i,y2:a},s)=>s==="y"?{start:Math.min(n,a),end:Math.max(n,a),value:e}:{start:Math.min(r,i),end:Math.max(r,i),value:t},HI=(t,e,r,n)=>(1-n)*(1-n)*t+2*(1-n)*n*e+n*n*r,x0=(t,e,r,n)=>({x:HI(t.x,e.x,r.x,n),y:HI(t.y,e.y,r.y,n)}),WI=(t,e,r,n)=>2*(1-n)*(e-t)+2*n*(r-e),BI=(t,e,r,n)=>-Math.atan2(WI(t.x,e.x,r.x,n),WI(t.y,e.y,r.y,n))+.5*Ht;class ol extends Bn{inRange(e,r,n,i){const a=this.options.borderWidth/2;if(n!=="x"&&n!=="y"){const s={mouseX:e,mouseY:r},{path:o,ctx:l}=this;if(o){Ta(l,this.options);const{chart:d}=this.$context,h=e*d.currentDevicePixelRatio,g=r*d.currentDevicePixelRatio,m=l.isPointInStroke(o,h,g)||w0(this,s,i);return l.restore(),m}const c=xu(a);return Hie(this,s,c,i)||w0(this,s,i)}return $ie(this,{mouseX:e,mouseY:r},n,{hBorderWidth:a,useFinalPosition:i})}getCenterPoint(e){return Io(this,e)}draw(e){const{x:r,y:n,x2:i,y2:a,cp:s,options:o}=this;if(e.save(),!Ta(e,o))return e.restore();Ro(e,o);const l=Math.sqrt(Math.pow(i-r,2)+Math.pow(a-n,2));if(o.curve&&s)return Yie(e,this,s,l),e.restore();const{startOpts:c,endOpts:d,startAdjust:h,endAdjust:g}=TL(this),m=Math.atan2(a-n,i-r);e.translate(r,n),e.rotate(m),e.beginPath(),e.moveTo(0+h,0),e.lineTo(l-g,0),e.shadowColor=o.borderShadowColor,e.stroke(),T0(e,0,h,c),T0(e,l,-g,d),e.restore()}get label(){return this.elements&&this.elements[0]}resolveElementProperties(e,r){const n=cie(e,r),{x:i,y:a,x2:s,y2:o}=n,l=Uie(n,e.chartArea),c=l?qie({x:i,y:a},{x:s,y:o},e.chartArea):{x:i,y:a,x2:s,y2:o,width:Math.abs(s-i),height:Math.abs(o-a)};if(c.centerX=(s+i)/2,c.centerY=(o+a)/2,c.initProperties=al(e,c,r),r.curve){const h={x:c.x,y:c.y},g={x:c.x2,y:c.y2};c.cp=Xie(c,r,go(h,g))}const d=Wie(e,c,r.label);return d._visible=l,c.elements=[{type:"label",optionScope:"label",properties:d,initProperties:c.initProperties}],c}}ol.id="lineAnnotation";const zI={backgroundColor:void 0,backgroundShadowColor:void 0,borderColor:void 0,borderDash:void 0,borderDashOffset:void 0,borderShadowColor:void 0,borderWidth:void 0,display:void 0,fill:void 0,length:void 0,shadowBlur:void 0,shadowOffsetX:void 0,shadowOffsetY:void 0,width:void 0};ol.defaults={adjustScaleRange:!0,arrowHeads:{display:!1,end:Object.assign({},zI),fill:!1,length:12,start:Object.assign({},zI),width:6},borderDash:[],borderDashOffset:0,borderShadowColor:"transparent",borderWidth:2,curve:!1,controlPoint:{y:"-50%"},display:!0,endValue:void 0,init:void 0,label:{backgroundColor:"rgba(0,0,0,0.8)",backgroundShadowColor:"transparent",borderCapStyle:"butt",borderColor:"black",borderDash:[],borderDashOffset:0,borderJoinStyle:"miter",borderRadius:6,borderShadowColor:"transparent",borderWidth:0,callout:Object.assign({},sl.defaults.callout),color:"#fff",content:null,display:!1,drawTime:void 0,font:{family:void 0,lineHeight:void 0,size:void 0,style:void 0,weight:"bold"},height:void 0,opacity:void 0,padding:6,position:"center",rotation:0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,textAlign:"center",textStrokeColor:void 0,textStrokeWidth:0,width:void 0,xAdjust:0,yAdjust:0,z:void 0},scaleID:void 0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,value:void 0,xMax:void 0,xMin:void 0,xScaleID:void 0,yMax:void 0,yMin:void 0,yScaleID:void 0,z:0};ol.descriptors={arrowHeads:{start:{_fallback:!0},end:{_fallback:!0},_fallback:!0}};ol.defaultRoutes={borderColor:"color"};function $ie(t,{mouseX:e,mouseY:r},n,{hBorderWidth:i,useFinalPosition:a}){const s=jie(e,r,t.getProps(["x","y","x2","y2"],a),n);return s.value>=s.start-i&&s.value<=s.end+i||w0(t,{mouseX:e,mouseY:r},a,n)}function Uie({x:t,y:e,x2:r,y2:n},{top:i,right:a,bottom:s,left:o}){return!(t<o&&r<o||t>a&&r>a||e<i&&n<i||e>s&&n>s)}function VI({x:t,y:e},r,{top:n,right:i,bottom:a,left:s}){return t<s&&(e=qI(s,{x:t,y:e},r),t=s),t>i&&(e=qI(i,{x:t,y:e},r),t=i),e<n&&(t=_0(n,{x:t,y:e},r),e=n),e>a&&(t=_0(a,{x:t,y:e},r),e=a),{x:t,y:e}}function qie(t,e,r){const{x:n,y:i}=VI(t,e,r),{x:a,y:s}=VI(e,t,r);return{x:n,y:i,x2:a,y2:s,width:Math.abs(a-n),height:Math.abs(s-i)}}function Hie(t,{mouseX:e,mouseY:r},n=is,i){const{x:a,y:s,x2:o,y2:l}=t.getProps(["x","y","x2","y2"],i),c=o-a,d=l-s,h=xu(c)+xu(d),g=h===0?-1:((e-a)*c+(r-s)*d)/h;let m,v;return g<0?(m=a,v=s):g>1?(m=o,v=l):(m=a+g*c,v=s+g*d),xu(e-m)+xu(r-v)<=n}function w0(t,{mouseX:e,mouseY:r},n,i){const a=t.label;return a.options.display&&a.inRange(e,r,i,n)}function Wie(t,e,r){const n=r.borderWidth,i=Kr(r.padding),a=n_(t.ctx,r),s=a.width+i.width+n,o=a.height+i.height+n;return zie(e,r,{width:s,height:o,padding:i},t.chartArea)}function Bie(t){const{x:e,y:r,x2:n,y2:i}=t,a=Math.atan2(i-r,n-e);return a>Ht/2?a-Ht:a<Ht/-2?a+Ht:a}function zie(t,e,r,n){const{width:i,height:a,padding:s}=r,{xAdjust:o,yAdjust:l}=e,c={x:t.x,y:t.y},d={x:t.x2,y:t.y2},h=e.rotation==="auto"?Bie(t):jr(e.rotation),g=Vie(i,a,h),m=Gie(t,e,{labelSize:g,padding:s},n),v=t.cp?x0(c,t.cp,d,m):s_(c,d,m),b={size:g.w,min:n.left,max:n.right,padding:s.left},y={size:g.h,min:n.top,max:n.bottom,padding:s.top},x=KI(v.x,b)+o,w=KI(v.y,y)+l;return{x:x-i/2,y:w-a/2,x2:x+i/2,y2:w+a/2,centerX:x,centerY:w,pointX:v.x,pointY:v.y,width:i,height:a,rotation:dP(h)}}function Vie(t,e,r){const n=Math.cos(r),i=Math.sin(r);return{w:Math.abs(t*n)+Math.abs(e*i),h:Math.abs(t*i)+Math.abs(e*n)}}function Gie(t,e,r,n){let i;const a=Kie(t,n);return e.position==="start"?i=GI({w:t.x2-t.x,h:t.y2-t.y},r,e,a):e.position==="end"?i=1-GI({w:t.x-t.x2,h:t.y-t.y2},r,e,a):i=e_(1,e.position),i}function GI(t,e,r,n){const{labelSize:i,padding:a}=e,s=t.w*n.dx,o=t.h*n.dy,l=s>0&&(i.w/2+a.left-n.x)/s,c=o>0&&(i.h/2+a.top-n.y)/o;return eh(Math.max(l,c),0,.25)}function Kie(t,e){const{x:r,x2:n,y:i,y2:a}=t,s=Math.min(i,a)-e.top,o=Math.min(r,n)-e.left,l=e.bottom-Math.max(i,a),c=e.right-Math.max(r,n);return{x:Math.min(o,c),y:Math.min(s,l),dx:o<=c?1:-1,dy:s<=l?1:-1}}function KI(t,e){const{size:r,min:n,max:i,padding:a}=e,s=r/2;return r>i-n?(i+n)/2:(n>=t-a-s&&(t=n+a+s),i<=t+a+s&&(t=i-a-s),t)}function TL(t){const e=t.options,r=e.arrowHeads&&e.arrowHeads.start,n=e.arrowHeads&&e.arrowHeads.end;return{startOpts:r,endOpts:n,startAdjust:XI(t,r),endAdjust:XI(t,n)}}function XI(t,e){if(!e||!e.display)return 0;const{length:r,width:n}=e,i=t.options.borderWidth/2,a={x:r,y:n+i};return Math.abs(_0(0,a,{x:0,y:i}))}function T0(t,e,r,n){if(!n||!n.display)return;const{length:i,width:a,fill:s,backgroundColor:o,borderColor:l}=n,c=Math.abs(e-i)+r;t.beginPath(),Ro(t,n),Ta(t,n),t.moveTo(c,-a),t.lineTo(e+r,0),t.lineTo(c,a),s===!0?(t.fillStyle=o||l,t.closePath(),t.fill(),t.shadowColor="transparent"):t.shadowColor=n.borderShadowColor,t.stroke()}function Xie(t,e,r){const{x:n,y:i,x2:a,y2:s,centerX:o,centerY:l}=t,c=Math.atan2(s-i,a-n),d=t_(e.controlPoint,0),h={x:o+wa(r,d.x,!1),y:l+wa(r,d.y,!1)};return Cs(h,{x:o,y:l},c)}function YI(t,{x:e,y:r},{angle:n,adjust:i},a){!a||!a.display||(t.save(),t.translate(e,r),t.rotate(n),T0(t,0,-i,a),t.restore())}function Yie(t,e,r,n){const{x:i,y:a,x2:s,y2:o,options:l}=e,{startOpts:c,endOpts:d,startAdjust:h,endAdjust:g}=TL(e),m={x:i,y:a},v={x:s,y:o},b=BI(m,r,v,0),y=BI(m,r,v,1)-Ht,x=x0(m,r,v,h/n),w=x0(m,r,v,1-g/n),S=new Path2D;t.beginPath(),S.moveTo(x.x,x.y),S.quadraticCurveTo(r.x,r.y,w.x,w.y),t.shadowColor=l.borderShadowColor,t.stroke(S),e.path=S,e.ctx=t,YI(t,x,{angle:b,adjust:h},c),YI(t,w,{angle:y,adjust:g},d)}class ul extends Bn{inRange(e,r,n,i){const a=this.options.rotation,s=this.options.borderWidth;if(n!=="x"&&n!=="y")return Zie({x:e,y:r},this.getProps(["width","height","centerX","centerY"],i),a,s);const{x:o,y:l,x2:c,y2:d}=this.getProps(["x","y","x2","y2"],i),h=s/2,g=n==="y"?{start:l,end:d}:{start:o,end:c},m=Cs({x:e,y:r},this.getCenterPoint(i),jr(-a));return m[n]>=g.start-h-is&&m[n]<=g.end+h+is}getCenterPoint(e){return Io(this,e)}draw(e){const{width:r,height:n,centerX:i,centerY:a,options:s}=this;e.save(),r_(e,this.getCenterPoint(),s.rotation),Ro(e,this.options),e.beginPath(),e.fillStyle=s.backgroundColor;const o=Ta(e,s);e.ellipse(i,a,n/2,r/2,Ht/2,0,2*Ht),e.fill(),o&&(e.shadowColor=s.borderShadowColor,e.stroke()),e.restore()}get label(){return this.elements&&this.elements[0]}resolveElementProperties(e,r){return bL(e,r,!0)}}ul.id="ellipseAnnotation";ul.defaults={adjustScaleRange:!0,backgroundShadowColor:"transparent",borderDash:[],borderDashOffset:0,borderShadowColor:"transparent",borderWidth:1,display:!0,init:void 0,label:Object.assign({},Do.defaults.label),rotation:0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,xMax:void 0,xMin:void 0,xScaleID:void 0,yMax:void 0,yMin:void 0,yScaleID:void 0,z:0};ul.defaultRoutes={borderColor:"color",backgroundColor:"color"};ul.descriptors={label:{_fallback:!0}};function Zie(t,e,r,n){const{width:i,height:a,centerX:s,centerY:o}=e,l=i/2,c=a/2;if(l<=0||c<=0)return!1;const d=jr(r||0),h=n/2||0,g=Math.cos(d),m=Math.sin(d),v=Math.pow(g*(t.x-s)+m*(t.y-o),2),b=Math.pow(m*(t.x-s)-g*(t.y-o),2);return v/Math.pow(l+h,2)+b/Math.pow(c+h,2)<=1.0001}class rh extends Bn{inRange(e,r,n,i){const{x:a,y:s,x2:o,y2:l,width:c}=this.getProps(["x","y","x2","y2","width"],i),d=this.options.borderWidth;if(n!=="x"&&n!=="y")return Yne({x:e,y:r},this.getCenterPoint(i),c/2,d);const h=d/2,g=n==="y"?{start:s,end:l,value:r}:{start:a,end:o,value:e};return g.value>=g.start-h&&g.value<=g.end+h}getCenterPoint(e){return Io(this,e)}draw(e){const r=this.options,n=r.borderWidth;if(r.radius<.1)return;e.save(),e.fillStyle=r.backgroundColor,Ro(e,r);const i=Ta(e,r);iie(e,this,this.centerX,this.centerY),i&&!th(r.pointStyle)&&(e.shadowColor=r.borderShadowColor,e.stroke()),e.restore(),r.borderWidth=n}resolveElementProperties(e,r){const n=yL(e,r);return n.initProperties=al(e,n,r,!0),n}}rh.id="pointAnnotation";rh.defaults={adjustScaleRange:!0,backgroundShadowColor:"transparent",borderDash:[],borderDashOffset:0,borderShadowColor:"transparent",borderWidth:1,display:!0,init:void 0,pointStyle:"circle",radius:10,rotation:0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,xAdjust:0,xMax:void 0,xMin:void 0,xScaleID:void 0,xValue:void 0,yAdjust:0,yMax:void 0,yMin:void 0,yScaleID:void 0,yValue:void 0,z:0};rh.defaultRoutes={borderColor:"color",backgroundColor:"color"};class nh extends Bn{inRange(e,r,n,i){if(n!=="x"&&n!=="y")return this.options.radius>=.1&&this.elements.length>1&&Qie(this.elements,e,r,i);const a=Cs({x:e,y:r},this.getCenterPoint(i),jr(-this.options.rotation)),s=this.elements.map(c=>n==="y"?c.bY:c.bX),o=Math.min(...s),l=Math.max(...s);return a[n]>=o&&a[n]<=l}getCenterPoint(e){return Io(this,e)}draw(e){const{elements:r,options:n}=this;e.save(),e.beginPath(),e.fillStyle=n.backgroundColor,Ro(e,n);const i=Ta(e,n);let a=!0;for(const s of r)a?(e.moveTo(s.x,s.y),a=!1):e.lineTo(s.x,s.y);e.closePath(),e.fill(),i&&(e.shadowColor=n.borderShadowColor,e.stroke()),e.restore()}resolveElementProperties(e,r){const n=yL(e,r),{sides:i,rotation:a}=r,s=[],o=2*Ht/i;let l=a*Ub;for(let c=0;c<i;c++,l+=o){const d=Jie(n,r,l);d.initProperties=al(e,n,r),s.push(d)}return n.elements=s,n}}nh.id="polygonAnnotation";nh.defaults={adjustScaleRange:!0,backgroundShadowColor:"transparent",borderCapStyle:"butt",borderDash:[],borderDashOffset:0,borderJoinStyle:"miter",borderShadowColor:"transparent",borderWidth:1,display:!0,init:void 0,point:{radius:0},radius:10,rotation:0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,sides:3,xAdjust:0,xMax:void 0,xMin:void 0,xScaleID:void 0,xValue:void 0,yAdjust:0,yMax:void 0,yMin:void 0,yScaleID:void 0,yValue:void 0,z:0};nh.defaultRoutes={borderColor:"color",backgroundColor:"color"};function Jie({centerX:t,centerY:e},{radius:r,borderWidth:n},i){const a=n/2,s=Math.sin(i),o=Math.cos(i),l={x:t+s*r,y:e-o*r};return{type:"point",optionScope:"point",properties:{x:l.x,y:l.y,centerX:l.x,centerY:l.y,bX:t+s*(r+a),bY:e-o*(r+a)}}}function Qie(t,e,r,n){let i=!1,a=t[t.length-1].getProps(["bX","bY"],n);for(const s of t){const o=s.getProps(["bX","bY"],n);o.bY>r!=a.bY>r&&e<(a.bX-o.bX)*(r-o.bY)/(a.bY-o.bY)+o.bX&&(i=!i),a=o}return i}const _a={box:Do,ellipse:ul,label:sl,line:ol,point:rh,polygon:nh};Object.keys(_a).forEach(t=>{lr.describe(`elements.${_a[t].id}`,{_fallback:"plugins.annotation.common"})});const eae={update:Object.assign},tae=a_.concat(gd),ZI=(t,e)=>it(e)?C0(t,e):t,S0=t=>t==="color"||t==="font";function o_(t="line"){return _a[t]?t:(console.warn(`Unknown annotation type: '${t}', defaulting to 'line'`),"line")}function rae(t,e,r,n){const i=iae(t,r.animations,n),a=e.annotations,s=oae(e.elements,a);for(let o=0;o<a.length;o++){const l=a[o],c=SL(s,o,l.type),d=l.setContext(sae(t,c,l)),h=c.resolveElementProperties(t,d);h.skip=nae(h),"elements"in h&&(aae(c,h.elements,d,i),delete h.elements),Sn(c.x)||Object.assign(c,h),Object.assign(c,h.initProperties),h.options=CL(d),i.update(c,h)}}function nae(t){return isNaN(t.x)||isNaN(t.y)}function iae(t,e,r){return r==="reset"||r==="none"||r==="resize"?eae:new Gb(t,e)}function aae(t,e,r,n){const i=t.elements||(t.elements=[]);i.length=e.length;for(let a=0;a<e.length;a++){const s=e[a],o=s.properties,l=SL(i,a,s.type,s.initProperties),c=r[s.optionScope].override(s);o.options=CL(c),n.update(l,o)}}function SL(t,e,r,n){const i=_a[o_(r)];let a=t[e];return(!a||!(a instanceof i))&&(a=t[e]=new i,Object.assign(a,n)),a}function CL(t){const e=_a[o_(t.type)],r={};r.id=t.id,r.type=t.type,r.drawTime=t.drawTime,Object.assign(r,C0(t,e.defaults),C0(t,e.defaultRoutes));for(const n of tae)r[n]=t[n];return r}function C0(t,e){const r={};for(const n of Object.keys(e)){const i=e[n],a=t[n];S0(n)&&Xt(a)?r[n]=a.map(s=>ZI(s,i)):r[n]=ZI(a,i)}return r}function sae(t,e,r){return e.$context||(e.$context=Object.assign(Object.create(t.getContext()),{element:e,id:r.id,type:"annotation"}))}function oae(t,e){const r=e.length,n=t.length;if(n<r){const i=r-n;t.splice(n,0,...new Array(i))}else n>r&&t.splice(r,n-r);return t}var uae="2.2.1";const fa=new Map,lae=a_.concat(gd);var cae={id:"annotation",version:uae,beforeRegister(){Zne("chart.js","3.7",us.version)},afterRegister(){us.register(_a)},afterUnregister(){us.unregister(_a)},beforeInit(t){fa.set(t,{annotations:[],elements:[],visibleElements:[],listeners:{},listened:!1,moveListened:!1,hooks:{},hooked:!1,hovered:[]})},beforeUpdate(t,e,r){const n=fa.get(t),i=n.annotations=[];let a=r.annotations;it(a)?Object.keys(a).forEach(s=>{const o=a[s];it(o)&&(o.id=s,i.push(o))}):Xt(a)&&i.push(...a),Tie(i,t.scales)},afterDataLimits(t,e){const r=fa.get(t);wie(t,e.scale,r.annotations.filter(n=>n.display&&n.adjustScaleRange))},afterUpdate(t,e,r){const n=fa.get(t);vie(t,n,r),rae(t,n,r,e.mode),n.visibleElements=n.elements.filter(i=>!i.skip&&i.options.display),xie(t,n,r)},beforeDatasetsDraw(t,e,r){hf(t,"beforeDatasetsDraw",r.clip)},afterDatasetsDraw(t,e,r){hf(t,"afterDatasetsDraw",r.clip)},beforeDraw(t,e,r){hf(t,"beforeDraw",r.clip)},afterDraw(t,e,r){hf(t,"afterDraw",r.clip)},beforeEvent(t,e,r){const n=fa.get(t);yie(n,e.event,r)&&(e.changed=!0)},afterDestroy(t){fa.delete(t)},_getState(t){return fa.get(t)},defaults:{animations:{numbers:{properties:["x","y","x2","y2","width","height","centerX","centerY","pointX","pointY","radius"],type:"number"}},clip:!0,interaction:{mode:void 0,axis:void 0,intersect:void 0},common:{drawTime:"afterDatasetsDraw",init:!1,label:{}}},descriptors:{_indexable:!1,_scriptable:t=>!lae.includes(t)&&t!=="init",annotations:{_allKeys:!1,_fallback:(t,e)=>`elements.${_a[o_(e.type)].id}`},interaction:{_fallback:!0},common:{label:{_indexable:S0,_fallback:!0},_indexable:S0}},additionalOptionScopes:[""]};function hf(t,e,r){const{ctx:n,chartArea:i}=t,a=fa.get(t);r&&nl(n,i);const s=fae(a.visibleElements,e).sort((o,l)=>o.element.options.z-l.element.options.z);for(const o of s)dae(n,i,a,o);r&&il(n)}function fae(t,e){const r=[];for(const n of t)if(n.options.drawTime===e&&r.push({element:n,main:!0}),n.elements&&n.elements.length)for(const i of n.elements)i.options.display&&i.options.drawTime===e&&r.push({element:i});return r}function dae(t,e,r,n){const i=n.element;n.main?(kI(r,i,"beforeDraw"),i.draw(t,e),kI(r,i,"afterDraw")):i.draw(t,e)}const hae={id:"chartBackground",beforeDraw:(t,e,r)=>{const{ctx:n,height:i,width:a}=t;n.save(),n.globalCompositeOperation="destination-over",n.fillStyle=r.color||"#FFFFFF",n.fillRect(0,0,a,i),n.restore()}};/*!
|
|
120
|
+
* chartjs-adapter-date-fns v3.0.0
|
|
121
|
+
* https://www.chartjs.org
|
|
122
|
+
* (c) 2022 chartjs-adapter-date-fns Contributors
|
|
123
|
+
* Released under the MIT license
|
|
124
|
+
*/const pae={datetime:"MMM d, yyyy, h:mm:ss aaaa",millisecond:"h:mm:ss.SSS aaaa",second:"h:mm:ss aaaa",minute:"h:mm aaaa",hour:"ha",day:"MMM d",week:"PP",month:"MMM yyyy",quarter:"qqq - yyyy",year:"yyyy"};LP._date.override({_id:"date-fns",formats:function(){return pae},parse:function(t,e){if(t===null||typeof t>"u")return null;const r=typeof t;return r==="number"||t instanceof Date?t=Ee(t):r==="string"&&(typeof e=="string"?t=BR(t,e,new Date,this.options):t=cn(t,this.options)),wo(t)?t.getTime():null},format:function(t,e){return Yu(t,e,this.options)},add:function(t,e,r){switch(r){case"millisecond":return Ku(t,e);case"second":return vB(t,e);case"minute":return gB(t,e);case"hour":return cB(t,e);case"day":return $0(t,e);case"week":return yB(t,e);case"month":return Td(t,e);case"quarter":return mB(t,e);case"year":return bB(t,e);default:return t}},diff:function(t,e,r){switch(r){case"millisecond":return Ed(t,e);case"second":return IB(t,e);case"minute":return EB(t,e);case"hour":return CB(t,e);case"day":return AR(t,e);case"week":return RB(t,e);case"month":return RR(t,e);case"quarter":return AB(t,e);case"year":return DB(t,e);default:return 0}},startOf:function(t,e,r){switch(e){case"second":return iz(t);case"minute":return MB(t);case"hour":return nz(t);case"day":return fs(t);case"week":return u1(t);case"isoWeek":return u1(t,{weekStartsOn:+r});case"month":return LB(t);case"quarter":return PB(t);case"year":return FB(t);default:return t}},endOf:function(t,e){switch(e){case"second":return qB(t);case"minute":return $B(t);case"hour":return kB(t);case"day":return Od(t);case"week":return jB(t);case"month":return IR(t);case"quarter":return UB(t);case"year":return NB(t);default:return t}}});us.register(h0,p0,ya,Jb,Tf,Wu,cae,hae,Pte,$te,Gte);export{Uae as D,$ae as E,_V as L,Nae as Q,kae as R,VR as S,qae as a,Fae as c,vi as g,A as j,Hae as q,zae as r,jae as u};
|