anarock-widgets 1.0.396 → 1.0.397
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/index.cjs.js +22 -22
- package/dist/index.es.js +119 -119
- package/dist/index.umd.js +22 -22
- package/package.json +1 -1
package/dist/index.umd.js
CHANGED
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
*
|
|
15
15
|
* This source code is licensed under the MIT license found in the
|
|
16
16
|
* LICENSE file in the root directory of this source tree.
|
|
17
|
-
*/var K1;function xF(){return K1||(K1=1,process.env.NODE_ENV!=="production"&&(function(){var e=k,t=Symbol.for("react.element"),n=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),i=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),a=Symbol.for("react.provider"),s=Symbol.for("react.context"),l=Symbol.for("react.forward_ref"),c=Symbol.for("react.suspense"),u=Symbol.for("react.suspense_list"),d=Symbol.for("react.memo"),f=Symbol.for("react.lazy"),p=Symbol.for("react.offscreen"),m=Symbol.iterator,g="@@iterator";function v($){if($===null||typeof $!="object")return null;var te=m&&$[m]||$[g];return typeof te=="function"?te:null}var x=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function _($){{for(var te=arguments.length,fe=new Array(te>1?te-1:0),we=1;we<te;we++)fe[we-1]=arguments[we];w("error",$,fe)}}function w($,te,fe){{var we=x.ReactDebugCurrentFrame,qe=we.getStackAddendum();qe!==""&&(te+="%s",fe=fe.concat([qe]));var ut=fe.map(function(Ne){return String(Ne)});ut.unshift("Warning: "+te),Function.prototype.apply.call(console[$],console,ut)}}var y=!1,E=!1,S=!1,P=!1,D=!1,T;T=Symbol.for("react.module.reference");function I($){return!!(typeof $=="string"||typeof $=="function"||$===r||$===o||D||$===i||$===c||$===u||P||$===p||y||E||S||typeof $=="object"&&$!==null&&($.$$typeof===f||$.$$typeof===d||$.$$typeof===a||$.$$typeof===s||$.$$typeof===l||$.$$typeof===T||$.getModuleId!==void 0))}function A($,te,fe){var we=$.displayName;if(we)return we;var qe=te.displayName||te.name||"";return qe!==""?fe+"("+qe+")":fe}function C($){return $.displayName||"Context"}function j($){if($==null)return null;if(typeof $.tag=="number"&&_("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof $=="function")return $.displayName||$.name||null;if(typeof $=="string")return $;switch($){case r:return"Fragment";case n:return"Portal";case o:return"Profiler";case i:return"StrictMode";case c:return"Suspense";case u:return"SuspenseList"}if(typeof $=="object")switch($.$$typeof){case s:var te=$;return C(te)+".Consumer";case a:var fe=$;return C(fe._context)+".Provider";case l:return A($,$.render,"ForwardRef");case d:var we=$.displayName||null;return we!==null?we:j($.type)||"Memo";case f:{var qe=$,ut=qe._payload,Ne=qe._init;try{return j(Ne(ut))}catch{return null}}}return null}var N=Object.assign,M=0,R,B,V,z,W,Q,
|
|
17
|
+
*/var K1;function xF(){return K1||(K1=1,process.env.NODE_ENV!=="production"&&(function(){var e=k,t=Symbol.for("react.element"),n=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),i=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),a=Symbol.for("react.provider"),s=Symbol.for("react.context"),l=Symbol.for("react.forward_ref"),c=Symbol.for("react.suspense"),u=Symbol.for("react.suspense_list"),d=Symbol.for("react.memo"),f=Symbol.for("react.lazy"),p=Symbol.for("react.offscreen"),m=Symbol.iterator,g="@@iterator";function v($){if($===null||typeof $!="object")return null;var te=m&&$[m]||$[g];return typeof te=="function"?te:null}var x=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function _($){{for(var te=arguments.length,fe=new Array(te>1?te-1:0),we=1;we<te;we++)fe[we-1]=arguments[we];w("error",$,fe)}}function w($,te,fe){{var we=x.ReactDebugCurrentFrame,qe=we.getStackAddendum();qe!==""&&(te+="%s",fe=fe.concat([qe]));var ut=fe.map(function(Ne){return String(Ne)});ut.unshift("Warning: "+te),Function.prototype.apply.call(console[$],console,ut)}}var y=!1,E=!1,S=!1,P=!1,D=!1,T;T=Symbol.for("react.module.reference");function I($){return!!(typeof $=="string"||typeof $=="function"||$===r||$===o||D||$===i||$===c||$===u||P||$===p||y||E||S||typeof $=="object"&&$!==null&&($.$$typeof===f||$.$$typeof===d||$.$$typeof===a||$.$$typeof===s||$.$$typeof===l||$.$$typeof===T||$.getModuleId!==void 0))}function A($,te,fe){var we=$.displayName;if(we)return we;var qe=te.displayName||te.name||"";return qe!==""?fe+"("+qe+")":fe}function C($){return $.displayName||"Context"}function j($){if($==null)return null;if(typeof $.tag=="number"&&_("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof $=="function")return $.displayName||$.name||null;if(typeof $=="string")return $;switch($){case r:return"Fragment";case n:return"Portal";case o:return"Profiler";case i:return"StrictMode";case c:return"Suspense";case u:return"SuspenseList"}if(typeof $=="object")switch($.$$typeof){case s:var te=$;return C(te)+".Consumer";case a:var fe=$;return C(fe._context)+".Provider";case l:return A($,$.render,"ForwardRef");case d:var we=$.displayName||null;return we!==null?we:j($.type)||"Memo";case f:{var qe=$,ut=qe._payload,Ne=qe._init;try{return j(Ne(ut))}catch{return null}}}return null}var N=Object.assign,M=0,R,B,V,z,W,Q,G;function ie(){}ie.__reactDisabledLog=!0;function J(){{if(M===0){R=console.log,B=console.info,V=console.warn,z=console.error,W=console.group,Q=console.groupCollapsed,G=console.groupEnd;var $={configurable:!0,enumerable:!0,value:ie,writable:!0};Object.defineProperties(console,{info:$,log:$,warn:$,error:$,group:$,groupCollapsed:$,groupEnd:$})}M++}}function re(){{if(M--,M===0){var $={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:N({},$,{value:R}),info:N({},$,{value:B}),warn:N({},$,{value:V}),error:N({},$,{value:z}),group:N({},$,{value:W}),groupCollapsed:N({},$,{value:Q}),groupEnd:N({},$,{value:G})})}M<0&&_("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}}var se=x.ReactCurrentDispatcher,ce;function de($,te,fe){{if(ce===void 0)try{throw Error()}catch(qe){var we=qe.stack.trim().match(/\n( *(at )?)/);ce=we&&we[1]||""}return`
|
|
18
18
|
`+ce+$}}var K=!1,U;{var Z=typeof WeakMap=="function"?WeakMap:Map;U=new Z}function F($,te){if(!$||K)return"";{var fe=U.get($);if(fe!==void 0)return fe}var we;K=!0;var qe=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var ut;ut=se.current,se.current=null,J();try{if(te){var Ne=function(){throw Error()};if(Object.defineProperty(Ne.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(Ne,[])}catch(pr){we=pr}Reflect.construct($,[],Ne)}else{try{Ne.call()}catch(pr){we=pr}$.call(Ne.prototype)}}else{try{throw Error()}catch(pr){we=pr}$()}}catch(pr){if(pr&&we&&typeof pr.stack=="string"){for(var Te=pr.stack.split(`
|
|
19
19
|
`),Xn=we.stack.split(`
|
|
20
20
|
`),Ht=Te.length-1,Jt=Xn.length-1;Ht>=1&&Jt>=0&&Te[Ht]!==Xn[Jt];)Jt--;for(;Ht>=1&&Jt>=0;Ht--,Jt--)if(Te[Ht]!==Xn[Jt]){if(Ht!==1||Jt!==1)do if(Ht--,Jt--,Jt<0||Te[Ht]!==Xn[Jt]){var Jr=`
|
|
@@ -41,12 +41,12 @@ React keys must be passed directly to JSX without using spread:
|
|
|
41
41
|
*
|
|
42
42
|
* This source code is licensed under the MIT license found in the
|
|
43
43
|
* LICENSE file in the root directory of this source tree.
|
|
44
|
-
*/var Z1;function SF(){return Z1||(Z1=1,process.env.NODE_ENV!=="production"&&(function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,i=e?Symbol.for("react.strict_mode"):60108,o=e?Symbol.for("react.profiler"):60114,a=e?Symbol.for("react.provider"):60109,s=e?Symbol.for("react.context"):60110,l=e?Symbol.for("react.async_mode"):60111,c=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,d=e?Symbol.for("react.suspense"):60113,f=e?Symbol.for("react.suspense_list"):60120,p=e?Symbol.for("react.memo"):60115,m=e?Symbol.for("react.lazy"):60116,g=e?Symbol.for("react.block"):60121,v=e?Symbol.for("react.fundamental"):60117,x=e?Symbol.for("react.responder"):60118,_=e?Symbol.for("react.scope"):60119;function w(F){return typeof F=="string"||typeof F=="function"||F===r||F===c||F===o||F===i||F===d||F===f||typeof F=="object"&&F!==null&&(F.$$typeof===m||F.$$typeof===p||F.$$typeof===a||F.$$typeof===s||F.$$typeof===u||F.$$typeof===v||F.$$typeof===x||F.$$typeof===_||F.$$typeof===g)}function y(F){if(typeof F=="object"&&F!==null){var ge=F.$$typeof;switch(ge){case t:var oe=F.type;switch(oe){case l:case c:case r:case o:case i:case d:return oe;default:var ye=oe&&oe.$$typeof;switch(ye){case s:case u:case m:case p:case a:return ye;default:return ge}}case n:return ge}}}var E=l,S=c,P=s,D=a,T=t,I=u,A=r,C=m,j=p,N=n,M=o,R=i,B=d,V=!1;function z(F){return V||(V=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),W(F)||y(F)===l}function W(F){return y(F)===c}function Q(F){return y(F)===s}function
|
|
44
|
+
*/var Z1;function SF(){return Z1||(Z1=1,process.env.NODE_ENV!=="production"&&(function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,i=e?Symbol.for("react.strict_mode"):60108,o=e?Symbol.for("react.profiler"):60114,a=e?Symbol.for("react.provider"):60109,s=e?Symbol.for("react.context"):60110,l=e?Symbol.for("react.async_mode"):60111,c=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,d=e?Symbol.for("react.suspense"):60113,f=e?Symbol.for("react.suspense_list"):60120,p=e?Symbol.for("react.memo"):60115,m=e?Symbol.for("react.lazy"):60116,g=e?Symbol.for("react.block"):60121,v=e?Symbol.for("react.fundamental"):60117,x=e?Symbol.for("react.responder"):60118,_=e?Symbol.for("react.scope"):60119;function w(F){return typeof F=="string"||typeof F=="function"||F===r||F===c||F===o||F===i||F===d||F===f||typeof F=="object"&&F!==null&&(F.$$typeof===m||F.$$typeof===p||F.$$typeof===a||F.$$typeof===s||F.$$typeof===u||F.$$typeof===v||F.$$typeof===x||F.$$typeof===_||F.$$typeof===g)}function y(F){if(typeof F=="object"&&F!==null){var ge=F.$$typeof;switch(ge){case t:var oe=F.type;switch(oe){case l:case c:case r:case o:case i:case d:return oe;default:var ye=oe&&oe.$$typeof;switch(ye){case s:case u:case m:case p:case a:return ye;default:return ge}}case n:return ge}}}var E=l,S=c,P=s,D=a,T=t,I=u,A=r,C=m,j=p,N=n,M=o,R=i,B=d,V=!1;function z(F){return V||(V=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),W(F)||y(F)===l}function W(F){return y(F)===c}function Q(F){return y(F)===s}function G(F){return y(F)===a}function ie(F){return typeof F=="object"&&F!==null&&F.$$typeof===t}function J(F){return y(F)===u}function re(F){return y(F)===r}function se(F){return y(F)===m}function ce(F){return y(F)===p}function de(F){return y(F)===n}function K(F){return y(F)===o}function U(F){return y(F)===i}function Z(F){return y(F)===d}He.AsyncMode=E,He.ConcurrentMode=S,He.ContextConsumer=P,He.ContextProvider=D,He.Element=T,He.ForwardRef=I,He.Fragment=A,He.Lazy=C,He.Memo=j,He.Portal=N,He.Profiler=M,He.StrictMode=R,He.Suspense=B,He.isAsyncMode=z,He.isConcurrentMode=W,He.isContextConsumer=Q,He.isContextProvider=G,He.isElement=ie,He.isForwardRef=J,He.isFragment=re,He.isLazy=se,He.isMemo=ce,He.isPortal=de,He.isProfiler=K,He.isStrictMode=U,He.isSuspense=Z,He.isValidElementType=w,He.typeOf=y})()),He}var J1;function ew(){return J1||(J1=1,process.env.NODE_ENV==="production"?id.exports=EF():id.exports=SF()),id.exports}/*
|
|
45
45
|
object-assign
|
|
46
46
|
(c) Sindre Sorhus
|
|
47
47
|
@license MIT
|
|
48
|
-
*/var ym,tw;function OF(){if(tw)return ym;tw=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable;function r(o){if(o==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(o)}function i(){try{if(!Object.assign)return!1;var o=new String("abc");if(o[5]="de",Object.getOwnPropertyNames(o)[0]==="5")return!1;for(var a={},s=0;s<10;s++)a["_"+String.fromCharCode(s)]=s;var l=Object.getOwnPropertyNames(a).map(function(u){return a[u]});if(l.join("")!=="0123456789")return!1;var c={};return"abcdefghijklmnopqrst".split("").forEach(function(u){c[u]=u}),Object.keys(Object.assign({},c)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return ym=i()?Object.assign:function(o,a){for(var s,l=r(o),c,u=1;u<arguments.length;u++){s=Object(arguments[u]);for(var d in s)t.call(s,d)&&(l[d]=s[d]);if(e){c=e(s);for(var f=0;f<c.length;f++)n.call(s,c[f])&&(l[c[f]]=s[c[f]])}}return l},ym}var bm,nw;function xm(){if(nw)return bm;nw=1;var e="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return bm=e,bm}var wm,rw;function iw(){return rw||(rw=1,wm=Function.call.bind(Object.prototype.hasOwnProperty)),wm}var _m,ow;function CF(){if(ow)return _m;ow=1;var e=function(){};if(process.env.NODE_ENV!=="production"){var t=xm(),n={},r=iw();e=function(o){var a="Warning: "+o;typeof console<"u"&&console.error(a);try{throw new Error(a)}catch{}}}function i(o,a,s,l,c){if(process.env.NODE_ENV!=="production"){for(var u in o)if(r(o,u)){var d;try{if(typeof o[u]!="function"){var f=Error((l||"React class")+": "+s+" type `"+u+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof o[u]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw f.name="Invariant Violation",f}d=o[u](a,u,l,s,null,t)}catch(m){d=m}if(d&&!(d instanceof Error)&&e((l||"React class")+": type specification of "+s+" `"+u+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof d+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),d instanceof Error&&!(d.message in n)){n[d.message]=!0;var p=c?c():"";e("Failed "+s+" type: "+d.message+(p??""))}}}}return i.resetWarningCache=function(){process.env.NODE_ENV!=="production"&&(n={})},_m=i,_m}var Em,aw;function kF(){if(aw)return Em;aw=1;var e=ew(),t=OF(),n=xm(),r=iw(),i=CF(),o=function(){};process.env.NODE_ENV!=="production"&&(o=function(s){var l="Warning: "+s;typeof console<"u"&&console.error(l);try{throw new Error(l)}catch{}});function a(){return null}return Em=function(s,l){var c=typeof Symbol=="function"&&Symbol.iterator,u="@@iterator";function d(W){var Q=W&&(c&&W[c]||W[u]);if(typeof Q=="function")return Q}var f="<<anonymous>>",p={array:x("array"),bigint:x("bigint"),bool:x("boolean"),func:x("function"),number:x("number"),object:x("object"),string:x("string"),symbol:x("symbol"),any:_(),arrayOf:w,element:y(),elementType:E(),instanceOf:S,node:I(),objectOf:D,oneOf:P,oneOfType:T,shape:C,exact:j};function m(W,Q){return W===Q?W!==0||1/W===1/Q:W!==W&&Q!==Q}function g(W,Q){this.message=W,this.data=Q&&typeof Q=="object"?Q:{},this.stack=""}g.prototype=Error.prototype;function v(W){if(process.env.NODE_ENV!=="production")var Q={},
|
|
49
|
-
Valid keys: `+JSON.stringify(Object.keys(W),null," "));var F=Z(ce,U,J,re,se+"."+U,n);if(F)return F}return null}return v(Q)}function N(W){switch(typeof W){case"number":case"string":case"undefined":return!0;case"boolean":return!W;case"object":if(Array.isArray(W))return W.every(N);if(W===null||s(W))return!0;var Q=d(W);if(Q){var
|
|
48
|
+
*/var ym,tw;function OF(){if(tw)return ym;tw=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable;function r(o){if(o==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(o)}function i(){try{if(!Object.assign)return!1;var o=new String("abc");if(o[5]="de",Object.getOwnPropertyNames(o)[0]==="5")return!1;for(var a={},s=0;s<10;s++)a["_"+String.fromCharCode(s)]=s;var l=Object.getOwnPropertyNames(a).map(function(u){return a[u]});if(l.join("")!=="0123456789")return!1;var c={};return"abcdefghijklmnopqrst".split("").forEach(function(u){c[u]=u}),Object.keys(Object.assign({},c)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}return ym=i()?Object.assign:function(o,a){for(var s,l=r(o),c,u=1;u<arguments.length;u++){s=Object(arguments[u]);for(var d in s)t.call(s,d)&&(l[d]=s[d]);if(e){c=e(s);for(var f=0;f<c.length;f++)n.call(s,c[f])&&(l[c[f]]=s[c[f]])}}return l},ym}var bm,nw;function xm(){if(nw)return bm;nw=1;var e="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return bm=e,bm}var wm,rw;function iw(){return rw||(rw=1,wm=Function.call.bind(Object.prototype.hasOwnProperty)),wm}var _m,ow;function CF(){if(ow)return _m;ow=1;var e=function(){};if(process.env.NODE_ENV!=="production"){var t=xm(),n={},r=iw();e=function(o){var a="Warning: "+o;typeof console<"u"&&console.error(a);try{throw new Error(a)}catch{}}}function i(o,a,s,l,c){if(process.env.NODE_ENV!=="production"){for(var u in o)if(r(o,u)){var d;try{if(typeof o[u]!="function"){var f=Error((l||"React class")+": "+s+" type `"+u+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof o[u]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw f.name="Invariant Violation",f}d=o[u](a,u,l,s,null,t)}catch(m){d=m}if(d&&!(d instanceof Error)&&e((l||"React class")+": type specification of "+s+" `"+u+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof d+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),d instanceof Error&&!(d.message in n)){n[d.message]=!0;var p=c?c():"";e("Failed "+s+" type: "+d.message+(p??""))}}}}return i.resetWarningCache=function(){process.env.NODE_ENV!=="production"&&(n={})},_m=i,_m}var Em,aw;function kF(){if(aw)return Em;aw=1;var e=ew(),t=OF(),n=xm(),r=iw(),i=CF(),o=function(){};process.env.NODE_ENV!=="production"&&(o=function(s){var l="Warning: "+s;typeof console<"u"&&console.error(l);try{throw new Error(l)}catch{}});function a(){return null}return Em=function(s,l){var c=typeof Symbol=="function"&&Symbol.iterator,u="@@iterator";function d(W){var Q=W&&(c&&W[c]||W[u]);if(typeof Q=="function")return Q}var f="<<anonymous>>",p={array:x("array"),bigint:x("bigint"),bool:x("boolean"),func:x("function"),number:x("number"),object:x("object"),string:x("string"),symbol:x("symbol"),any:_(),arrayOf:w,element:y(),elementType:E(),instanceOf:S,node:I(),objectOf:D,oneOf:P,oneOfType:T,shape:C,exact:j};function m(W,Q){return W===Q?W!==0||1/W===1/Q:W!==W&&Q!==Q}function g(W,Q){this.message=W,this.data=Q&&typeof Q=="object"?Q:{},this.stack=""}g.prototype=Error.prototype;function v(W){if(process.env.NODE_ENV!=="production")var Q={},G=0;function ie(re,se,ce,de,K,U,Z){if(de=de||f,U=U||ce,Z!==n){if(l){var F=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types");throw F.name="Invariant Violation",F}else if(process.env.NODE_ENV!=="production"&&typeof console<"u"){var ge=de+":"+ce;!Q[ge]&&G<3&&(o("You are manually calling a React.PropTypes validation function for the `"+U+"` prop on `"+de+"`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."),Q[ge]=!0,G++)}}return se[ce]==null?re?se[ce]===null?new g("The "+K+" `"+U+"` is marked as required "+("in `"+de+"`, but its value is `null`.")):new g("The "+K+" `"+U+"` is marked as required in "+("`"+de+"`, but its value is `undefined`.")):null:W(se,ce,de,K,U)}var J=ie.bind(null,!1);return J.isRequired=ie.bind(null,!0),J}function x(W){function Q(G,ie,J,re,se,ce){var de=G[ie],K=R(de);if(K!==W){var U=B(de);return new g("Invalid "+re+" `"+se+"` of type "+("`"+U+"` supplied to `"+J+"`, expected ")+("`"+W+"`."),{expectedType:W})}return null}return v(Q)}function _(){return v(a)}function w(W){function Q(G,ie,J,re,se){if(typeof W!="function")return new g("Property `"+se+"` of component `"+J+"` has invalid PropType notation inside arrayOf.");var ce=G[ie];if(!Array.isArray(ce)){var de=R(ce);return new g("Invalid "+re+" `"+se+"` of type "+("`"+de+"` supplied to `"+J+"`, expected an array."))}for(var K=0;K<ce.length;K++){var U=W(ce,K,J,re,se+"["+K+"]",n);if(U instanceof Error)return U}return null}return v(Q)}function y(){function W(Q,G,ie,J,re){var se=Q[G];if(!s(se)){var ce=R(se);return new g("Invalid "+J+" `"+re+"` of type "+("`"+ce+"` supplied to `"+ie+"`, expected a single ReactElement."))}return null}return v(W)}function E(){function W(Q,G,ie,J,re){var se=Q[G];if(!e.isValidElementType(se)){var ce=R(se);return new g("Invalid "+J+" `"+re+"` of type "+("`"+ce+"` supplied to `"+ie+"`, expected a single ReactElement type."))}return null}return v(W)}function S(W){function Q(G,ie,J,re,se){if(!(G[ie]instanceof W)){var ce=W.name||f,de=z(G[ie]);return new g("Invalid "+re+" `"+se+"` of type "+("`"+de+"` supplied to `"+J+"`, expected ")+("instance of `"+ce+"`."))}return null}return v(Q)}function P(W){if(!Array.isArray(W))return process.env.NODE_ENV!=="production"&&(arguments.length>1?o("Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."):o("Invalid argument supplied to oneOf, expected an array.")),a;function Q(G,ie,J,re,se){for(var ce=G[ie],de=0;de<W.length;de++)if(m(ce,W[de]))return null;var K=JSON.stringify(W,function(Z,F){var ge=B(F);return ge==="symbol"?String(F):F});return new g("Invalid "+re+" `"+se+"` of value `"+String(ce)+"` "+("supplied to `"+J+"`, expected one of "+K+"."))}return v(Q)}function D(W){function Q(G,ie,J,re,se){if(typeof W!="function")return new g("Property `"+se+"` of component `"+J+"` has invalid PropType notation inside objectOf.");var ce=G[ie],de=R(ce);if(de!=="object")return new g("Invalid "+re+" `"+se+"` of type "+("`"+de+"` supplied to `"+J+"`, expected an object."));for(var K in ce)if(r(ce,K)){var U=W(ce,K,J,re,se+"."+K,n);if(U instanceof Error)return U}return null}return v(Q)}function T(W){if(!Array.isArray(W))return process.env.NODE_ENV!=="production"&&o("Invalid argument supplied to oneOfType, expected an instance of array."),a;for(var Q=0;Q<W.length;Q++){var G=W[Q];if(typeof G!="function")return o("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+V(G)+" at index "+Q+"."),a}function ie(J,re,se,ce,de){for(var K=[],U=0;U<W.length;U++){var Z=W[U],F=Z(J,re,se,ce,de,n);if(F==null)return null;F.data&&r(F.data,"expectedType")&&K.push(F.data.expectedType)}var ge=K.length>0?", expected one of type ["+K.join(", ")+"]":"";return new g("Invalid "+ce+" `"+de+"` supplied to "+("`"+se+"`"+ge+"."))}return v(ie)}function I(){function W(Q,G,ie,J,re){return N(Q[G])?null:new g("Invalid "+J+" `"+re+"` supplied to "+("`"+ie+"`, expected a ReactNode."))}return v(W)}function A(W,Q,G,ie,J){return new g((W||"React class")+": "+Q+" type `"+G+"."+ie+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+J+"`.")}function C(W){function Q(G,ie,J,re,se){var ce=G[ie],de=R(ce);if(de!=="object")return new g("Invalid "+re+" `"+se+"` of type `"+de+"` "+("supplied to `"+J+"`, expected `object`."));for(var K in W){var U=W[K];if(typeof U!="function")return A(J,re,se,K,B(U));var Z=U(ce,K,J,re,se+"."+K,n);if(Z)return Z}return null}return v(Q)}function j(W){function Q(G,ie,J,re,se){var ce=G[ie],de=R(ce);if(de!=="object")return new g("Invalid "+re+" `"+se+"` of type `"+de+"` "+("supplied to `"+J+"`, expected `object`."));var K=t({},G[ie],W);for(var U in K){var Z=W[U];if(r(W,U)&&typeof Z!="function")return A(J,re,se,U,B(Z));if(!Z)return new g("Invalid "+re+" `"+se+"` key `"+U+"` supplied to `"+J+"`.\nBad object: "+JSON.stringify(G[ie],null," ")+`
|
|
49
|
+
Valid keys: `+JSON.stringify(Object.keys(W),null," "));var F=Z(ce,U,J,re,se+"."+U,n);if(F)return F}return null}return v(Q)}function N(W){switch(typeof W){case"number":case"string":case"undefined":return!0;case"boolean":return!W;case"object":if(Array.isArray(W))return W.every(N);if(W===null||s(W))return!0;var Q=d(W);if(Q){var G=Q.call(W),ie;if(Q!==W.entries){for(;!(ie=G.next()).done;)if(!N(ie.value))return!1}else for(;!(ie=G.next()).done;){var J=ie.value;if(J&&!N(J[1]))return!1}}else return!1;return!0;default:return!1}}function M(W,Q){return W==="symbol"?!0:Q?Q["@@toStringTag"]==="Symbol"||typeof Symbol=="function"&&Q instanceof Symbol:!1}function R(W){var Q=typeof W;return Array.isArray(W)?"array":W instanceof RegExp?"object":M(Q,W)?"symbol":Q}function B(W){if(typeof W>"u"||W===null)return""+W;var Q=R(W);if(Q==="object"){if(W instanceof Date)return"date";if(W instanceof RegExp)return"regexp"}return Q}function V(W){var Q=B(W);switch(Q){case"array":case"object":return"an "+Q;case"boolean":case"date":case"regexp":return"a "+Q;default:return Q}}function z(W){return!W.constructor||!W.constructor.name?f:W.constructor.name}return p.checkPropTypes=i,p.resetWarningCache=i.resetWarningCache,p.PropTypes=p,p},Em}var Sm,sw;function PF(){if(sw)return Sm;sw=1;var e=xm();function t(){}function n(){}return n.resetWarningCache=t,Sm=function(){function r(a,s,l,c,u,d){if(d!==e){var f=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw f.name="Invariant Violation",f}}r.isRequired=r;function i(){return r}var o={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:i,element:r,elementType:r,instanceOf:i,node:r,objectOf:i,oneOf:i,oneOfType:i,shape:i,exact:i,checkPropTypes:n,resetWarningCache:t};return o.PropTypes=o,o},Sm}var lw;function DF(){if(lw)return rd.exports;if(lw=1,process.env.NODE_ENV!=="production"){var e=ew(),t=!0;rd.exports=kF()(e.isElement,t)}else rd.exports=PF()();return rd.exports}var AF=DF();const b=Ki(AF);function cw(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var i=e.length;for(t=0;t<i;t++)e[t]&&(n=cw(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function ue(){for(var e,t,n=0,r="",i=arguments.length;n<i;n++)(e=arguments[n])&&(t=cw(e))&&(r&&(r+=" "),r+=t);return r}function kn(e,t,n=void 0){const r={};for(const i in e){const o=e[i];let a="",s=!0;for(let l=0;l<o.length;l+=1){const c=o[l];c&&(a+=(s===!0?"":" ")+t(c),s=!1,n&&n[c]&&(a+=" "+n[c]))}r[i]=a}return r}var od={exports:{}},nt={};/**
|
|
50
50
|
* @license React
|
|
51
51
|
* react-is.production.js
|
|
52
52
|
*
|
|
@@ -80,7 +80,7 @@ For example, \`@sm\` or \`@600\` or \`@40rem/sidebar\`.`:pi(18,`(${t})`));return
|
|
|
80
80
|
*
|
|
81
81
|
* This source code is licensed under the MIT license found in the
|
|
82
82
|
* LICENSE file in the root directory of this source tree.
|
|
83
|
-
*/var Tw;function tR(){return Tw||(Tw=1,process.env.NODE_ENV!=="production"&&(function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,i=e?Symbol.for("react.strict_mode"):60108,o=e?Symbol.for("react.profiler"):60114,a=e?Symbol.for("react.provider"):60109,s=e?Symbol.for("react.context"):60110,l=e?Symbol.for("react.async_mode"):60111,c=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,d=e?Symbol.for("react.suspense"):60113,f=e?Symbol.for("react.suspense_list"):60120,p=e?Symbol.for("react.memo"):60115,m=e?Symbol.for("react.lazy"):60116,g=e?Symbol.for("react.block"):60121,v=e?Symbol.for("react.fundamental"):60117,x=e?Symbol.for("react.responder"):60118,_=e?Symbol.for("react.scope"):60119;function w(F){return typeof F=="string"||typeof F=="function"||F===r||F===c||F===o||F===i||F===d||F===f||typeof F=="object"&&F!==null&&(F.$$typeof===m||F.$$typeof===p||F.$$typeof===a||F.$$typeof===s||F.$$typeof===u||F.$$typeof===v||F.$$typeof===x||F.$$typeof===_||F.$$typeof===g)}function y(F){if(typeof F=="object"&&F!==null){var ge=F.$$typeof;switch(ge){case t:var oe=F.type;switch(oe){case l:case c:case r:case o:case i:case d:return oe;default:var ye=oe&&oe.$$typeof;switch(ye){case s:case u:case m:case p:case a:return ye;default:return ge}}case n:return ge}}}var E=l,S=c,P=s,D=a,T=t,I=u,A=r,C=m,j=p,N=n,M=o,R=i,B=d,V=!1;function z(F){return V||(V=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),W(F)||y(F)===l}function W(F){return y(F)===c}function Q(F){return y(F)===s}function X(F){return y(F)===a}function ie(F){return typeof F=="object"&&F!==null&&F.$$typeof===t}function J(F){return y(F)===u}function re(F){return y(F)===r}function se(F){return y(F)===m}function ce(F){return y(F)===p}function de(F){return y(F)===n}function K(F){return y(F)===o}function U(F){return y(F)===i}function Z(F){return y(F)===d}Ue.AsyncMode=E,Ue.ConcurrentMode=S,Ue.ContextConsumer=P,Ue.ContextProvider=D,Ue.Element=T,Ue.ForwardRef=I,Ue.Fragment=A,Ue.Lazy=C,Ue.Memo=j,Ue.Portal=N,Ue.Profiler=M,Ue.StrictMode=R,Ue.Suspense=B,Ue.isAsyncMode=z,Ue.isConcurrentMode=W,Ue.isContextConsumer=Q,Ue.isContextProvider=X,Ue.isElement=ie,Ue.isForwardRef=J,Ue.isFragment=re,Ue.isLazy=se,Ue.isMemo=ce,Ue.isPortal=de,Ue.isProfiler=K,Ue.isStrictMode=U,Ue.isSuspense=Z,Ue.isValidElementType=w,Ue.typeOf=y})()),Ue}var Nw;function nR(){return Nw||(Nw=1,process.env.NODE_ENV==="production"?Od.exports=eR():Od.exports=tR()),Od.exports}var jm,jw;function rR(){if(jw)return jm;jw=1;var e=nR(),t={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},n={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},r={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},i={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},o={};o[e.ForwardRef]=r,o[e.Memo]=i;function a(m){return e.isMemo(m)?i:o[m.$$typeof]||t}var s=Object.defineProperty,l=Object.getOwnPropertyNames,c=Object.getOwnPropertySymbols,u=Object.getOwnPropertyDescriptor,d=Object.getPrototypeOf,f=Object.prototype;function p(m,g,v){if(typeof g!="string"){if(f){var x=d(g);x&&x!==f&&p(m,x,v)}var _=l(g);c&&(_=_.concat(c(g)));for(var w=a(m),y=a(g),E=0;E<_.length;++E){var S=_[E];if(!n[S]&&!(v&&v[S])&&!(y&&y[S])&&!(w&&w[S])){var P=u(g,S);try{s(m,S,P)}catch{}}}}return m}return jm=p,jm}rR();var iR=!0;function Mw(e,t,n){var r="";return n.split(" ").forEach(function(i){e[i]!==void 0?t.push(e[i]+";"):i&&(r+=i+" ")}),r}var Mm=function(t,n,r){var i=t.key+"-"+n.name;(r===!1||iR===!1)&&t.registered[i]===void 0&&(t.registered[i]=n.styles)},Im=function(t,n,r){Mm(t,n,r);var i=t.key+"-"+n.name;if(t.inserted[n.name]===void 0){var o=n;do t.insert(n===o?"."+i:"",o,t.sheet,!0),o=o.next;while(o!==void 0)}};function oR(e){for(var t=0,n,r=0,i=e.length;i>=4;++r,i-=4)n=e.charCodeAt(r)&255|(e.charCodeAt(++r)&255)<<8|(e.charCodeAt(++r)&255)<<16|(e.charCodeAt(++r)&255)<<24,n=(n&65535)*1540483477+((n>>>16)*59797<<16),n^=n>>>24,t=(n&65535)*1540483477+((n>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(i){case 3:t^=(e.charCodeAt(r+2)&255)<<16;case 2:t^=(e.charCodeAt(r+1)&255)<<8;case 1:t^=e.charCodeAt(r)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16)}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}var aR={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,scale:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},sR=/[A-Z]|^ms/g,lR=/_EMO_([^_]+?)_([^]*?)_EMO_/g,Iw=function(t){return t.charCodeAt(1)===45},Fw=function(t){return t!=null&&typeof t!="boolean"},Fm=kw(function(e){return Iw(e)?e:e.replace(sR,"-$&").toLowerCase()}),Lw=function(t,n){switch(t){case"animation":case"animationName":if(typeof n=="string")return n.replace(lR,function(r,i,o){return gi={name:i,styles:o,next:gi},i})}return aR[t]!==1&&!Iw(t)&&typeof n=="number"&&n!==0?n+"px":n};function Jl(e,t,n){if(n==null)return"";var r=n;if(r.__emotion_styles!==void 0)return r;switch(typeof n){case"boolean":return"";case"object":{var i=n;if(i.anim===1)return gi={name:i.name,styles:i.styles,next:gi},i.name;var o=n;if(o.styles!==void 0){var a=o.next;if(a!==void 0)for(;a!==void 0;)gi={name:a.name,styles:a.styles,next:gi},a=a.next;var s=o.styles+";";return s}return cR(e,t,n)}case"function":{if(e!==void 0){var l=gi,c=n(e);return gi=l,Jl(e,t,c)}break}}var u=n;if(t==null)return u;var d=t[u];return d!==void 0?d:u}function cR(e,t,n){var r="";if(Array.isArray(n))for(var i=0;i<n.length;i++)r+=Jl(e,t,n[i])+";";else for(var o in n){var a=n[o];if(typeof a!="object"){var s=a;t!=null&&t[s]!==void 0?r+=o+"{"+t[s]+"}":Fw(s)&&(r+=Fm(o)+":"+Lw(o,s)+";")}else if(Array.isArray(a)&&typeof a[0]=="string"&&(t==null||t[a[0]]===void 0))for(var l=0;l<a.length;l++)Fw(a[l])&&(r+=Fm(o)+":"+Lw(o,a[l])+";");else{var c=Jl(e,t,a);switch(o){case"animation":case"animationName":{r+=Fm(o)+":"+c+";";break}default:r+=o+"{"+c+"}"}}}return r}var Rw=/label:\s*([^\s;{]+)\s*(;|$)/g,gi;function Cd(e,t,n){if(e.length===1&&typeof e[0]=="object"&&e[0]!==null&&e[0].styles!==void 0)return e[0];var r=!0,i="";gi=void 0;var o=e[0];if(o==null||o.raw===void 0)r=!1,i+=Jl(n,t,o);else{var a=o;i+=a[0]}for(var s=1;s<e.length;s++)if(i+=Jl(n,t,e[s]),r){var l=o;i+=l[s]}Rw.lastIndex=0;for(var c="",u;(u=Rw.exec(i))!==null;)c+="-"+u[1];var d=oR(i)+c;return{name:d,styles:i,next:gi}}var uR=function(t){return t()},$w=O.useInsertionEffect?O.useInsertionEffect:!1,Bw=$w||uR,Ww=$w||O.useLayoutEffect,zw=O.createContext(typeof HTMLElement<"u"?JL({key:"css"}):null);zw.Provider;var Lm=function(t){return k.forwardRef(function(n,r){var i=k.useContext(zw);return t(n,i,r)})},kd=O.createContext({}),Rm={}.hasOwnProperty,$m="__EMOTION_TYPE_PLEASE_DO_NOT_USE__",dR=function(t,n){var r={};for(var i in n)Rm.call(n,i)&&(r[i]=n[i]);return r[$m]=t,r},fR=function(t){var n=t.cache,r=t.serialized,i=t.isStringTag;return Mm(n,r,i),Bw(function(){return Im(n,r,i)}),null},pR=Lm(function(e,t,n){var r=e.css;typeof r=="string"&&t.registered[r]!==void 0&&(r=t.registered[r]);var i=e[$m],o=[r],a="";typeof e.className=="string"?a=Mw(t.registered,o,e.className):e.className!=null&&(a=e.className+" ");var s=Cd(o,void 0,O.useContext(kd));a+=t.key+"-"+s.name;var l={};for(var c in e)Rm.call(e,c)&&c!=="css"&&c!==$m&&(l[c]=e[c]);return l.className=a,n&&(l.ref=n),O.createElement(O.Fragment,null,O.createElement(fR,{cache:t,serialized:s,isStringTag:typeof i=="string"}),O.createElement(i,l))}),hR=pR,Vw=function(t,n){var r=arguments;if(n==null||!Rm.call(n,"css"))return O.createElement.apply(void 0,r);var i=r.length,o=new Array(i);o[0]=hR,o[1]=dR(t,n);for(var a=2;a<i;a++)o[a]=r[a];return O.createElement.apply(null,o)};(function(e){var t;t||(t=e.JSX||(e.JSX={}))})(Vw||(Vw={}));var mR=Lm(function(e,t){var n=e.styles,r=Cd([n],void 0,O.useContext(kd)),i=O.useRef();return Ww(function(){var o=t.key+"-global",a=new t.sheet.constructor({key:o,nonce:t.sheet.nonce,container:t.sheet.container,speedy:t.sheet.isSpeedy}),s=!1,l=document.querySelector('style[data-emotion="'+o+" "+r.name+'"]');return t.sheet.tags.length&&(a.before=t.sheet.tags[0]),l!==null&&(s=!0,l.setAttribute("data-emotion",o),a.hydrate([l])),i.current=[a,s],function(){a.flush()}},[t]),Ww(function(){var o=i.current,a=o[0],s=o[1];if(s){o[1]=!1;return}if(r.next!==void 0&&Im(t,r.next,!0),a.tags.length){var l=a.tags[a.tags.length-1].nextElementSibling;a.before=l,a.flush()}t.insert("",r,a,!1)},[t,r.name]),null}),gR=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|disableRemotePlayback|download|draggable|encType|enterKeyHint|fetchpriority|fetchPriority|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|popover|popoverTarget|popoverTargetAction|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,vR=kw(function(e){return gR.test(e)||e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)<91}),yR=vR,bR=function(t){return t!=="theme"},Hw=function(t){return typeof t=="string"&&t.charCodeAt(0)>96?yR:bR},Yw=function(t,n,r){var i;if(n){var o=n.shouldForwardProp;i=t.__emotion_forwardProp&&o?function(a){return t.__emotion_forwardProp(a)&&o(a)}:o}return typeof i!="function"&&r&&(i=t.__emotion_forwardProp),i},xR=function(t){var n=t.cache,r=t.serialized,i=t.isStringTag;return Mm(n,r,i),Bw(function(){return Im(n,r,i)}),null},wR=function e(t,n){var r=t.__emotion_real===t,i=r&&t.__emotion_base||t,o,a;n!==void 0&&(o=n.label,a=n.target);var s=Yw(t,n,r),l=s||Hw(i),c=!l("as");return function(){var u=arguments,d=r&&t.__emotion_styles!==void 0?t.__emotion_styles.slice(0):[];if(o!==void 0&&d.push("label:"+o+";"),u[0]==null||u[0].raw===void 0)d.push.apply(d,u);else{var f=u[0];d.push(f[0]);for(var p=u.length,m=1;m<p;m++)d.push(u[m],f[m])}var g=Lm(function(v,x,_){var w=c&&v.as||i,y="",E=[],S=v;if(v.theme==null){S={};for(var P in v)S[P]=v[P];S.theme=O.useContext(kd)}typeof v.className=="string"?y=Mw(x.registered,E,v.className):v.className!=null&&(y=v.className+" ");var D=Cd(d.concat(E),x.registered,S);y+=x.key+"-"+D.name,a!==void 0&&(y+=" "+a);var T=c&&s===void 0?Hw(w):l,I={};for(var A in v)c&&A==="as"||T(A)&&(I[A]=v[A]);return I.className=y,_&&(I.ref=_),O.createElement(O.Fragment,null,O.createElement(xR,{cache:x,serialized:D,isStringTag:typeof w=="string"}),O.createElement(w,I))});return g.displayName=o!==void 0?o:"Styled("+(typeof i=="string"?i:i.displayName||i.name||"Component")+")",g.defaultProps=t.defaultProps,g.__emotion_real=g,g.__emotion_base=i,g.__emotion_styles=d,g.__emotion_forwardProp=s,Object.defineProperty(g,"toString",{value:function(){return"."+a}}),g.withComponent=function(v,x){var _=e(v,km({},n,x,{shouldForwardProp:Yw(g,x,!0)}));return _.apply(void 0,d)},g}},_R=["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","marquee","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"],Pd=wR.bind(null);_R.forEach(function(e){Pd[e]=Pd(e)});function ER(e){return e==null||Object.keys(e).length===0}function Uw(e){const{styles:t,defaultTheme:n={}}=e,r=typeof t=="function"?i=>t(ER(i)?n:i):t;return h.jsx(mR,{styles:r})}process.env.NODE_ENV!=="production"&&(Uw.propTypes={defaultTheme:b.object,styles:b.oneOfType([b.array,b.string,b.object,b.func])});/**
|
|
83
|
+
*/var Tw;function tR(){return Tw||(Tw=1,process.env.NODE_ENV!=="production"&&(function(){var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,i=e?Symbol.for("react.strict_mode"):60108,o=e?Symbol.for("react.profiler"):60114,a=e?Symbol.for("react.provider"):60109,s=e?Symbol.for("react.context"):60110,l=e?Symbol.for("react.async_mode"):60111,c=e?Symbol.for("react.concurrent_mode"):60111,u=e?Symbol.for("react.forward_ref"):60112,d=e?Symbol.for("react.suspense"):60113,f=e?Symbol.for("react.suspense_list"):60120,p=e?Symbol.for("react.memo"):60115,m=e?Symbol.for("react.lazy"):60116,g=e?Symbol.for("react.block"):60121,v=e?Symbol.for("react.fundamental"):60117,x=e?Symbol.for("react.responder"):60118,_=e?Symbol.for("react.scope"):60119;function w(F){return typeof F=="string"||typeof F=="function"||F===r||F===c||F===o||F===i||F===d||F===f||typeof F=="object"&&F!==null&&(F.$$typeof===m||F.$$typeof===p||F.$$typeof===a||F.$$typeof===s||F.$$typeof===u||F.$$typeof===v||F.$$typeof===x||F.$$typeof===_||F.$$typeof===g)}function y(F){if(typeof F=="object"&&F!==null){var ge=F.$$typeof;switch(ge){case t:var oe=F.type;switch(oe){case l:case c:case r:case o:case i:case d:return oe;default:var ye=oe&&oe.$$typeof;switch(ye){case s:case u:case m:case p:case a:return ye;default:return ge}}case n:return ge}}}var E=l,S=c,P=s,D=a,T=t,I=u,A=r,C=m,j=p,N=n,M=o,R=i,B=d,V=!1;function z(F){return V||(V=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),W(F)||y(F)===l}function W(F){return y(F)===c}function Q(F){return y(F)===s}function G(F){return y(F)===a}function ie(F){return typeof F=="object"&&F!==null&&F.$$typeof===t}function J(F){return y(F)===u}function re(F){return y(F)===r}function se(F){return y(F)===m}function ce(F){return y(F)===p}function de(F){return y(F)===n}function K(F){return y(F)===o}function U(F){return y(F)===i}function Z(F){return y(F)===d}Ue.AsyncMode=E,Ue.ConcurrentMode=S,Ue.ContextConsumer=P,Ue.ContextProvider=D,Ue.Element=T,Ue.ForwardRef=I,Ue.Fragment=A,Ue.Lazy=C,Ue.Memo=j,Ue.Portal=N,Ue.Profiler=M,Ue.StrictMode=R,Ue.Suspense=B,Ue.isAsyncMode=z,Ue.isConcurrentMode=W,Ue.isContextConsumer=Q,Ue.isContextProvider=G,Ue.isElement=ie,Ue.isForwardRef=J,Ue.isFragment=re,Ue.isLazy=se,Ue.isMemo=ce,Ue.isPortal=de,Ue.isProfiler=K,Ue.isStrictMode=U,Ue.isSuspense=Z,Ue.isValidElementType=w,Ue.typeOf=y})()),Ue}var Nw;function nR(){return Nw||(Nw=1,process.env.NODE_ENV==="production"?Od.exports=eR():Od.exports=tR()),Od.exports}var jm,jw;function rR(){if(jw)return jm;jw=1;var e=nR(),t={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},n={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},r={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},i={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},o={};o[e.ForwardRef]=r,o[e.Memo]=i;function a(m){return e.isMemo(m)?i:o[m.$$typeof]||t}var s=Object.defineProperty,l=Object.getOwnPropertyNames,c=Object.getOwnPropertySymbols,u=Object.getOwnPropertyDescriptor,d=Object.getPrototypeOf,f=Object.prototype;function p(m,g,v){if(typeof g!="string"){if(f){var x=d(g);x&&x!==f&&p(m,x,v)}var _=l(g);c&&(_=_.concat(c(g)));for(var w=a(m),y=a(g),E=0;E<_.length;++E){var S=_[E];if(!n[S]&&!(v&&v[S])&&!(y&&y[S])&&!(w&&w[S])){var P=u(g,S);try{s(m,S,P)}catch{}}}}return m}return jm=p,jm}rR();var iR=!0;function Mw(e,t,n){var r="";return n.split(" ").forEach(function(i){e[i]!==void 0?t.push(e[i]+";"):i&&(r+=i+" ")}),r}var Mm=function(t,n,r){var i=t.key+"-"+n.name;(r===!1||iR===!1)&&t.registered[i]===void 0&&(t.registered[i]=n.styles)},Im=function(t,n,r){Mm(t,n,r);var i=t.key+"-"+n.name;if(t.inserted[n.name]===void 0){var o=n;do t.insert(n===o?"."+i:"",o,t.sheet,!0),o=o.next;while(o!==void 0)}};function oR(e){for(var t=0,n,r=0,i=e.length;i>=4;++r,i-=4)n=e.charCodeAt(r)&255|(e.charCodeAt(++r)&255)<<8|(e.charCodeAt(++r)&255)<<16|(e.charCodeAt(++r)&255)<<24,n=(n&65535)*1540483477+((n>>>16)*59797<<16),n^=n>>>24,t=(n&65535)*1540483477+((n>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(i){case 3:t^=(e.charCodeAt(r+2)&255)<<16;case 2:t^=(e.charCodeAt(r+1)&255)<<8;case 1:t^=e.charCodeAt(r)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16)}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}var aR={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,scale:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},sR=/[A-Z]|^ms/g,lR=/_EMO_([^_]+?)_([^]*?)_EMO_/g,Iw=function(t){return t.charCodeAt(1)===45},Fw=function(t){return t!=null&&typeof t!="boolean"},Fm=kw(function(e){return Iw(e)?e:e.replace(sR,"-$&").toLowerCase()}),Lw=function(t,n){switch(t){case"animation":case"animationName":if(typeof n=="string")return n.replace(lR,function(r,i,o){return gi={name:i,styles:o,next:gi},i})}return aR[t]!==1&&!Iw(t)&&typeof n=="number"&&n!==0?n+"px":n};function Jl(e,t,n){if(n==null)return"";var r=n;if(r.__emotion_styles!==void 0)return r;switch(typeof n){case"boolean":return"";case"object":{var i=n;if(i.anim===1)return gi={name:i.name,styles:i.styles,next:gi},i.name;var o=n;if(o.styles!==void 0){var a=o.next;if(a!==void 0)for(;a!==void 0;)gi={name:a.name,styles:a.styles,next:gi},a=a.next;var s=o.styles+";";return s}return cR(e,t,n)}case"function":{if(e!==void 0){var l=gi,c=n(e);return gi=l,Jl(e,t,c)}break}}var u=n;if(t==null)return u;var d=t[u];return d!==void 0?d:u}function cR(e,t,n){var r="";if(Array.isArray(n))for(var i=0;i<n.length;i++)r+=Jl(e,t,n[i])+";";else for(var o in n){var a=n[o];if(typeof a!="object"){var s=a;t!=null&&t[s]!==void 0?r+=o+"{"+t[s]+"}":Fw(s)&&(r+=Fm(o)+":"+Lw(o,s)+";")}else if(Array.isArray(a)&&typeof a[0]=="string"&&(t==null||t[a[0]]===void 0))for(var l=0;l<a.length;l++)Fw(a[l])&&(r+=Fm(o)+":"+Lw(o,a[l])+";");else{var c=Jl(e,t,a);switch(o){case"animation":case"animationName":{r+=Fm(o)+":"+c+";";break}default:r+=o+"{"+c+"}"}}}return r}var Rw=/label:\s*([^\s;{]+)\s*(;|$)/g,gi;function Cd(e,t,n){if(e.length===1&&typeof e[0]=="object"&&e[0]!==null&&e[0].styles!==void 0)return e[0];var r=!0,i="";gi=void 0;var o=e[0];if(o==null||o.raw===void 0)r=!1,i+=Jl(n,t,o);else{var a=o;i+=a[0]}for(var s=1;s<e.length;s++)if(i+=Jl(n,t,e[s]),r){var l=o;i+=l[s]}Rw.lastIndex=0;for(var c="",u;(u=Rw.exec(i))!==null;)c+="-"+u[1];var d=oR(i)+c;return{name:d,styles:i,next:gi}}var uR=function(t){return t()},$w=O.useInsertionEffect?O.useInsertionEffect:!1,Bw=$w||uR,Ww=$w||O.useLayoutEffect,zw=O.createContext(typeof HTMLElement<"u"?JL({key:"css"}):null);zw.Provider;var Lm=function(t){return k.forwardRef(function(n,r){var i=k.useContext(zw);return t(n,i,r)})},kd=O.createContext({}),Rm={}.hasOwnProperty,$m="__EMOTION_TYPE_PLEASE_DO_NOT_USE__",dR=function(t,n){var r={};for(var i in n)Rm.call(n,i)&&(r[i]=n[i]);return r[$m]=t,r},fR=function(t){var n=t.cache,r=t.serialized,i=t.isStringTag;return Mm(n,r,i),Bw(function(){return Im(n,r,i)}),null},pR=Lm(function(e,t,n){var r=e.css;typeof r=="string"&&t.registered[r]!==void 0&&(r=t.registered[r]);var i=e[$m],o=[r],a="";typeof e.className=="string"?a=Mw(t.registered,o,e.className):e.className!=null&&(a=e.className+" ");var s=Cd(o,void 0,O.useContext(kd));a+=t.key+"-"+s.name;var l={};for(var c in e)Rm.call(e,c)&&c!=="css"&&c!==$m&&(l[c]=e[c]);return l.className=a,n&&(l.ref=n),O.createElement(O.Fragment,null,O.createElement(fR,{cache:t,serialized:s,isStringTag:typeof i=="string"}),O.createElement(i,l))}),hR=pR,Vw=function(t,n){var r=arguments;if(n==null||!Rm.call(n,"css"))return O.createElement.apply(void 0,r);var i=r.length,o=new Array(i);o[0]=hR,o[1]=dR(t,n);for(var a=2;a<i;a++)o[a]=r[a];return O.createElement.apply(null,o)};(function(e){var t;t||(t=e.JSX||(e.JSX={}))})(Vw||(Vw={}));var mR=Lm(function(e,t){var n=e.styles,r=Cd([n],void 0,O.useContext(kd)),i=O.useRef();return Ww(function(){var o=t.key+"-global",a=new t.sheet.constructor({key:o,nonce:t.sheet.nonce,container:t.sheet.container,speedy:t.sheet.isSpeedy}),s=!1,l=document.querySelector('style[data-emotion="'+o+" "+r.name+'"]');return t.sheet.tags.length&&(a.before=t.sheet.tags[0]),l!==null&&(s=!0,l.setAttribute("data-emotion",o),a.hydrate([l])),i.current=[a,s],function(){a.flush()}},[t]),Ww(function(){var o=i.current,a=o[0],s=o[1];if(s){o[1]=!1;return}if(r.next!==void 0&&Im(t,r.next,!0),a.tags.length){var l=a.tags[a.tags.length-1].nextElementSibling;a.before=l,a.flush()}t.insert("",r,a,!1)},[t,r.name]),null}),gR=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|disableRemotePlayback|download|draggable|encType|enterKeyHint|fetchpriority|fetchPriority|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|popover|popoverTarget|popoverTargetAction|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,vR=kw(function(e){return gR.test(e)||e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)<91}),yR=vR,bR=function(t){return t!=="theme"},Hw=function(t){return typeof t=="string"&&t.charCodeAt(0)>96?yR:bR},Yw=function(t,n,r){var i;if(n){var o=n.shouldForwardProp;i=t.__emotion_forwardProp&&o?function(a){return t.__emotion_forwardProp(a)&&o(a)}:o}return typeof i!="function"&&r&&(i=t.__emotion_forwardProp),i},xR=function(t){var n=t.cache,r=t.serialized,i=t.isStringTag;return Mm(n,r,i),Bw(function(){return Im(n,r,i)}),null},wR=function e(t,n){var r=t.__emotion_real===t,i=r&&t.__emotion_base||t,o,a;n!==void 0&&(o=n.label,a=n.target);var s=Yw(t,n,r),l=s||Hw(i),c=!l("as");return function(){var u=arguments,d=r&&t.__emotion_styles!==void 0?t.__emotion_styles.slice(0):[];if(o!==void 0&&d.push("label:"+o+";"),u[0]==null||u[0].raw===void 0)d.push.apply(d,u);else{var f=u[0];d.push(f[0]);for(var p=u.length,m=1;m<p;m++)d.push(u[m],f[m])}var g=Lm(function(v,x,_){var w=c&&v.as||i,y="",E=[],S=v;if(v.theme==null){S={};for(var P in v)S[P]=v[P];S.theme=O.useContext(kd)}typeof v.className=="string"?y=Mw(x.registered,E,v.className):v.className!=null&&(y=v.className+" ");var D=Cd(d.concat(E),x.registered,S);y+=x.key+"-"+D.name,a!==void 0&&(y+=" "+a);var T=c&&s===void 0?Hw(w):l,I={};for(var A in v)c&&A==="as"||T(A)&&(I[A]=v[A]);return I.className=y,_&&(I.ref=_),O.createElement(O.Fragment,null,O.createElement(xR,{cache:x,serialized:D,isStringTag:typeof w=="string"}),O.createElement(w,I))});return g.displayName=o!==void 0?o:"Styled("+(typeof i=="string"?i:i.displayName||i.name||"Component")+")",g.defaultProps=t.defaultProps,g.__emotion_real=g,g.__emotion_base=i,g.__emotion_styles=d,g.__emotion_forwardProp=s,Object.defineProperty(g,"toString",{value:function(){return"."+a}}),g.withComponent=function(v,x){var _=e(v,km({},n,x,{shouldForwardProp:Yw(g,x,!0)}));return _.apply(void 0,d)},g}},_R=["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","marquee","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"],Pd=wR.bind(null);_R.forEach(function(e){Pd[e]=Pd(e)});function ER(e){return e==null||Object.keys(e).length===0}function Uw(e){const{styles:t,defaultTheme:n={}}=e,r=typeof t=="function"?i=>t(ER(i)?n:i):t;return h.jsx(mR,{styles:r})}process.env.NODE_ENV!=="production"&&(Uw.propTypes={defaultTheme:b.object,styles:b.oneOfType([b.array,b.string,b.object,b.func])});/**
|
|
84
84
|
* @mui/styled-engine v7.3.2
|
|
85
85
|
*
|
|
86
86
|
* @license MIT
|
|
@@ -113,15 +113,15 @@ theme.breakpoints = createBreakpoints(theme.breakpoints || {});
|
|
|
113
113
|
theme.transitions = createTransitions(theme.transitions || {});
|
|
114
114
|
|
|
115
115
|
export default theme;`}function b_(e){return typeof e=="number"?`${(e*100).toFixed(0)}%`:`calc((${e}) * 100%)`}const k$=e=>{if(!Number.isNaN(+e))return+e;const t=e.match(/\d*\.?\d+/g);if(!t)return 0;let n=0;for(let r=0;r<t.length;r+=1)n+=+t[r];return n};function P$(e){Object.assign(e,{alpha(t,n){const r=this||e;return r.colorSpace?`oklch(from ${t} l c h / ${typeof n=="string"?`calc(${n})`:n})`:r.vars?`rgba(${t.replace(/var\(--([^,\s)]+)(?:,[^)]+)?\)+/g,"var(--$1Channel)")} / ${typeof n=="string"?`calc(${n})`:n})`:Td(t,k$(n))},lighten(t,n){const r=this||e;return r.colorSpace?`color-mix(in ${r.colorSpace}, ${t}, #fff ${b_(n)})`:jd(t,n)},darken(t,n){const r=this||e;return r.colorSpace?`color-mix(in ${r.colorSpace}, ${t}, #000 ${b_(n)})`:Nd(t,n)}})}function Xm(e={},...t){const{breakpoints:n,mixins:r={},spacing:i,palette:o={},transitions:a={},typography:s={},shape:l,colorSpace:c,...u}=e;if(e.vars&&e.generateThemeVars===void 0)throw new Error(process.env.NODE_ENV!=="production"?"MUI: `vars` is a private field used for CSS variables support.\nPlease use another name or follow the [docs](https://mui.com/material-ui/customization/css-theme-variables/usage/) to enable the feature.":pi(20));const d=Gm({...o,colorSpace:c}),f=Bm(e);let p=Pn(f,{mixins:h$(f.breakpoints,r),palette:d,shadows:x$.slice(),typography:g$(d,s),transitions:S$(a),zIndex:{...O$}});if(p=Pn(p,u),p=t.reduce((m,g)=>Pn(m,g),p),process.env.NODE_ENV!=="production"){const m=["active","checked","completed","disabled","error","expanded","focused","focusVisible","required","selected"],g=(v,x)=>{let _;for(_ in v){const w=v[_];if(m.includes(_)&&Object.keys(w).length>0){if(process.env.NODE_ENV!=="production"){const y=xn("",_);console.error([`MUI: The \`${x}\` component increases the CSS specificity of the \`${_}\` internal state.`,"You can not override it like this: ",JSON.stringify(v,null,2),"",`Instead, you need to use the '&.${y}' syntax:`,JSON.stringify({root:{[`&.${y}`]:w}},null,2),"","https://mui.com/r/state-classes-guide"].join(`
|
|
116
|
-
`))}v[_]={}}}};Object.keys(p.components).forEach(v=>{const x=p.components[v].styleOverrides;x&&v.startsWith("Mui")&&g(x,v)})}return p.unstable_sxConfig={...gd,...u?.unstable_sxConfig},p.unstable_sx=function(g){return Es({sx:g,theme:this})},p.toRuntimeSource=y_,P$(p),p}function Qm(e){let t;return e<1?t=5.11916*e**2:t=4.5*Math.log(e+1)+2,Math.round(t*10)/1e3}const D$=[...Array(25)].map((e,t)=>{if(t===0)return"none";const n=Qm(t);return`linear-gradient(rgba(255 255 255 / ${n}), rgba(255 255 255 / ${n}))`});function x_(e){return{inputPlaceholder:e==="dark"?.5:.42,inputUnderline:e==="dark"?.7:.42,switchTrackDisabled:e==="dark"?.2:.12,switchTrack:e==="dark"?.3:.38}}function w_(e){return e==="dark"?D$:[]}function A$(e){const{palette:t={mode:"light"},opacity:n,overlays:r,colorSpace:i,...o}=e,a=Gm({...t,colorSpace:i});return{palette:a,opacity:{...x_(a.mode),...n},overlays:r||w_(a.mode),...o}}function T$(e){return!!e[0].match(/(cssVarPrefix|colorSchemeSelector|modularCssLayers|rootSelector|typography|mixins|breakpoints|direction|transitions)/)||!!e[0].match(/sxConfig$/)||e[0]==="palette"&&!!e[1]?.match(/(mode|contrastThreshold|tonalOffset)/)}const N$=e=>[...[...Array(25)].map((t,n)=>`--${e?`${e}-`:""}overlays-${n}`),`--${e?`${e}-`:""}palette-AppBar-darkBg`,`--${e?`${e}-`:""}palette-AppBar-darkColor`],j$=e=>(t,n)=>{const r=e.rootSelector||":root",i=e.colorSchemeSelector;let o=i;if(i==="class"&&(o=".%s"),i==="data"&&(o="[data-%s]"),i?.startsWith("data-")&&!i.includes("%s")&&(o=`[${i}="%s"]`),e.defaultColorScheme===t){if(t==="dark"){const a={};return N$(e.cssVarPrefix).forEach(s=>{a[s]=n[s],delete n[s]}),o==="media"?{[r]:n,"@media (prefers-color-scheme: dark)":{[r]:a}}:o?{[o.replace("%s",t)]:a,[`${r}, ${o.replace("%s",t)}`]:n}:{[r]:{...n,...a}}}if(o&&o!=="media")return`${r}, ${o.replace("%s",String(t))}`}else if(t){if(o==="media")return{[`@media (prefers-color-scheme: ${String(t)})`]:{[r]:n}};if(o)return o.replace("%s",String(t))}return r};function M$(e,t){t.forEach(n=>{e[n]||(e[n]={})})}function
|
|
117
|
-
To suppress this warning, you need to explicitly provide the \`palette.${t}Channel\` as a string (in rgb format, for example "12 12 12") or undefined if you want to remove the channel token.`))}function I$(e){return typeof e=="number"?`${e}px`:typeof e=="string"||typeof e=="function"||Array.isArray(e)?e:"8px"}const vi=e=>{try{return e()}catch{}},F$=(e="mui")=>e$(e);function Zm(e,t,n,r,i){if(!n)return;n=n===!0?{}:n;const o=i==="dark"?"dark":"light";if(!r){t[i]=A$({...n,palette:{mode:o,...n?.palette},colorSpace:e});return}const{palette:a,...s}=Xm({...r,palette:{mode:o,...n?.palette},colorSpace:e});return t[i]={...n,palette:a,opacity:{...x_(o),...n?.opacity},overlays:n?.overlays||w_(o)},s}function L$(e={},...t){const{colorSchemes:n={light:!0},defaultColorScheme:r,disableCssColorScheme:i=!1,cssVarPrefix:o="mui",nativeColor:a=!1,shouldSkipGeneratingVar:s=T$,colorSchemeSelector:l=n.light&&n.dark?"media":void 0,rootSelector:c=":root",...u}=e,d=Object.keys(n)[0],f=r||(n.light&&d!=="light"?"light":d),p=F$(o),{[f]:m,light:g,dark:v,...x}=n,_={...x};let w=m;if((f==="dark"&&!("dark"in n)||f==="light"&&!("light"in n))&&(w=!0),!w)throw new Error(process.env.NODE_ENV!=="production"?`MUI: The \`colorSchemes.${f}\` option is either missing or invalid.`:pi(21,f));let y;a&&(y="oklch");const E=Zm(y,_,w,u,f);g&&!_.light&&Zm(y,_,g,void 0,"light"),v&&!_.dark&&Zm(y,_,v,void 0,"dark");let S={defaultColorScheme:f,...E,cssVarPrefix:o,colorSchemeSelector:l,rootSelector:c,getCssVar:p,colorSchemes:_,font:{...p$(E.typography),...E.font},spacing:I$(u.spacing)};Object.keys(S.colorSchemes).forEach(A=>{const C=S.colorSchemes[A].palette,j=M=>{const R=M.split("-"),B=R[1],V=R[2];return p(M,C[B][V])};C.mode==="light"&&(G(C.common,"background","#fff"),G(C.common,"onBackground","#000")),C.mode==="dark"&&(G(C.common,"background","#000"),G(C.common,"onBackground","#fff"));function N(M,R,B){if(y){let V;return M===xa&&(V=`transparent ${((1-B)*100).toFixed(0)}%`),M===Ge&&(V=`#000 ${(B*100).toFixed(0)}%`),M===Xe&&(V=`#fff ${(B*100).toFixed(0)}%`),`color-mix(in ${y}, ${R}, ${V})`}return M(R,B)}if(M$(C,["Alert","AppBar","Avatar","Button","Chip","FilledInput","LinearProgress","Skeleton","Slider","SnackbarContent","SpeedDialAction","StepConnector","StepContent","Switch","TableCell","Tooltip"]),C.mode==="light"){G(C.Alert,"errorColor",N(Ge,C.error.light,.6)),G(C.Alert,"infoColor",N(Ge,C.info.light,.6)),G(C.Alert,"successColor",N(Ge,C.success.light,.6)),G(C.Alert,"warningColor",N(Ge,C.warning.light,.6)),G(C.Alert,"errorFilledBg",j("palette-error-main")),G(C.Alert,"infoFilledBg",j("palette-info-main")),G(C.Alert,"successFilledBg",j("palette-success-main")),G(C.Alert,"warningFilledBg",j("palette-warning-main")),G(C.Alert,"errorFilledColor",vi(()=>C.getContrastText(C.error.main))),G(C.Alert,"infoFilledColor",vi(()=>C.getContrastText(C.info.main))),G(C.Alert,"successFilledColor",vi(()=>C.getContrastText(C.success.main))),G(C.Alert,"warningFilledColor",vi(()=>C.getContrastText(C.warning.main))),G(C.Alert,"errorStandardBg",N(Xe,C.error.light,.9)),G(C.Alert,"infoStandardBg",N(Xe,C.info.light,.9)),G(C.Alert,"successStandardBg",N(Xe,C.success.light,.9)),G(C.Alert,"warningStandardBg",N(Xe,C.warning.light,.9)),G(C.Alert,"errorIconColor",j("palette-error-main")),G(C.Alert,"infoIconColor",j("palette-info-main")),G(C.Alert,"successIconColor",j("palette-success-main")),G(C.Alert,"warningIconColor",j("palette-warning-main")),G(C.AppBar,"defaultBg",j("palette-grey-100")),G(C.Avatar,"defaultBg",j("palette-grey-400")),G(C.Button,"inheritContainedBg",j("palette-grey-300")),G(C.Button,"inheritContainedHoverBg",j("palette-grey-A100")),G(C.Chip,"defaultBorder",j("palette-grey-400")),G(C.Chip,"defaultAvatarColor",j("palette-grey-700")),G(C.Chip,"defaultIconColor",j("palette-grey-700")),G(C.FilledInput,"bg","rgba(0, 0, 0, 0.06)"),G(C.FilledInput,"hoverBg","rgba(0, 0, 0, 0.09)"),G(C.FilledInput,"disabledBg","rgba(0, 0, 0, 0.12)"),G(C.LinearProgress,"primaryBg",N(Xe,C.primary.main,.62)),G(C.LinearProgress,"secondaryBg",N(Xe,C.secondary.main,.62)),G(C.LinearProgress,"errorBg",N(Xe,C.error.main,.62)),G(C.LinearProgress,"infoBg",N(Xe,C.info.main,.62)),G(C.LinearProgress,"successBg",N(Xe,C.success.main,.62)),G(C.LinearProgress,"warningBg",N(Xe,C.warning.main,.62)),G(C.Skeleton,"bg",y?N(xa,C.text.primary,.11):`rgba(${j("palette-text-primaryChannel")} / 0.11)`),G(C.Slider,"primaryTrack",N(Xe,C.primary.main,.62)),G(C.Slider,"secondaryTrack",N(Xe,C.secondary.main,.62)),G(C.Slider,"errorTrack",N(Xe,C.error.main,.62)),G(C.Slider,"infoTrack",N(Xe,C.info.main,.62)),G(C.Slider,"successTrack",N(Xe,C.success.main,.62)),G(C.Slider,"warningTrack",N(Xe,C.warning.main,.62));const M=y?N(Ge,C.background.default,.6825):Md(C.background.default,.8);G(C.SnackbarContent,"bg",M),G(C.SnackbarContent,"color",vi(()=>y?qm.text.primary:C.getContrastText(M))),G(C.SpeedDialAction,"fabHoverBg",Md(C.background.paper,.15)),G(C.StepConnector,"border",j("palette-grey-400")),G(C.StepContent,"border",j("palette-grey-400")),G(C.Switch,"defaultColor",j("palette-common-white")),G(C.Switch,"defaultDisabledColor",j("palette-grey-100")),G(C.Switch,"primaryDisabledColor",N(Xe,C.primary.main,.62)),G(C.Switch,"secondaryDisabledColor",N(Xe,C.secondary.main,.62)),G(C.Switch,"errorDisabledColor",N(Xe,C.error.main,.62)),G(C.Switch,"infoDisabledColor",N(Xe,C.info.main,.62)),G(C.Switch,"successDisabledColor",N(Xe,C.success.main,.62)),G(C.Switch,"warningDisabledColor",N(Xe,C.warning.main,.62)),G(C.TableCell,"border",N(Xe,N(xa,C.divider,1),.88)),G(C.Tooltip,"bg",N(xa,C.grey[700],.92))}if(C.mode==="dark"){G(C.Alert,"errorColor",N(Xe,C.error.light,.6)),G(C.Alert,"infoColor",N(Xe,C.info.light,.6)),G(C.Alert,"successColor",N(Xe,C.success.light,.6)),G(C.Alert,"warningColor",N(Xe,C.warning.light,.6)),G(C.Alert,"errorFilledBg",j("palette-error-dark")),G(C.Alert,"infoFilledBg",j("palette-info-dark")),G(C.Alert,"successFilledBg",j("palette-success-dark")),G(C.Alert,"warningFilledBg",j("palette-warning-dark")),G(C.Alert,"errorFilledColor",vi(()=>C.getContrastText(C.error.dark))),G(C.Alert,"infoFilledColor",vi(()=>C.getContrastText(C.info.dark))),G(C.Alert,"successFilledColor",vi(()=>C.getContrastText(C.success.dark))),G(C.Alert,"warningFilledColor",vi(()=>C.getContrastText(C.warning.dark))),G(C.Alert,"errorStandardBg",N(Ge,C.error.light,.9)),G(C.Alert,"infoStandardBg",N(Ge,C.info.light,.9)),G(C.Alert,"successStandardBg",N(Ge,C.success.light,.9)),G(C.Alert,"warningStandardBg",N(Ge,C.warning.light,.9)),G(C.Alert,"errorIconColor",j("palette-error-main")),G(C.Alert,"infoIconColor",j("palette-info-main")),G(C.Alert,"successIconColor",j("palette-success-main")),G(C.Alert,"warningIconColor",j("palette-warning-main")),G(C.AppBar,"defaultBg",j("palette-grey-900")),G(C.AppBar,"darkBg",j("palette-background-paper")),G(C.AppBar,"darkColor",j("palette-text-primary")),G(C.Avatar,"defaultBg",j("palette-grey-600")),G(C.Button,"inheritContainedBg",j("palette-grey-800")),G(C.Button,"inheritContainedHoverBg",j("palette-grey-700")),G(C.Chip,"defaultBorder",j("palette-grey-700")),G(C.Chip,"defaultAvatarColor",j("palette-grey-300")),G(C.Chip,"defaultIconColor",j("palette-grey-300")),G(C.FilledInput,"bg","rgba(255, 255, 255, 0.09)"),G(C.FilledInput,"hoverBg","rgba(255, 255, 255, 0.13)"),G(C.FilledInput,"disabledBg","rgba(255, 255, 255, 0.12)"),G(C.LinearProgress,"primaryBg",N(Ge,C.primary.main,.5)),G(C.LinearProgress,"secondaryBg",N(Ge,C.secondary.main,.5)),G(C.LinearProgress,"errorBg",N(Ge,C.error.main,.5)),G(C.LinearProgress,"infoBg",N(Ge,C.info.main,.5)),G(C.LinearProgress,"successBg",N(Ge,C.success.main,.5)),G(C.LinearProgress,"warningBg",N(Ge,C.warning.main,.5)),G(C.Skeleton,"bg",y?N(xa,C.text.primary,.13):`rgba(${j("palette-text-primaryChannel")} / 0.13)`),G(C.Slider,"primaryTrack",N(Ge,C.primary.main,.5)),G(C.Slider,"secondaryTrack",N(Ge,C.secondary.main,.5)),G(C.Slider,"errorTrack",N(Ge,C.error.main,.5)),G(C.Slider,"infoTrack",N(Ge,C.info.main,.5)),G(C.Slider,"successTrack",N(Ge,C.success.main,.5)),G(C.Slider,"warningTrack",N(Ge,C.warning.main,.5));const M=y?N(Xe,C.background.default,.985):Md(C.background.default,.98);G(C.SnackbarContent,"bg",M),G(C.SnackbarContent,"color",vi(()=>y?d_.text.primary:C.getContrastText(M))),G(C.SpeedDialAction,"fabHoverBg",Md(C.background.paper,.15)),G(C.StepConnector,"border",j("palette-grey-600")),G(C.StepContent,"border",j("palette-grey-600")),G(C.Switch,"defaultColor",j("palette-grey-300")),G(C.Switch,"defaultDisabledColor",j("palette-grey-600")),G(C.Switch,"primaryDisabledColor",N(Ge,C.primary.main,.55)),G(C.Switch,"secondaryDisabledColor",N(Ge,C.secondary.main,.55)),G(C.Switch,"errorDisabledColor",N(Ge,C.error.main,.55)),G(C.Switch,"infoDisabledColor",N(Ge,C.info.main,.55)),G(C.Switch,"successDisabledColor",N(Ge,C.success.main,.55)),G(C.Switch,"warningDisabledColor",N(Ge,C.warning.main,.55)),G(C.TableCell,"border",N(Ge,N(xa,C.divider,1),.68)),G(C.Tooltip,"bg",N(xa,C.grey[700],.92))}Qi(C.background,"default"),Qi(C.background,"paper"),Qi(C.common,"background"),Qi(C.common,"onBackground"),Qi(C,"divider"),Object.keys(C).forEach(M=>{const R=C[M];M!=="tonalOffset"&&R&&typeof R=="object"&&(R.main&&G(C[M],"mainChannel",ec(rc(R.main))),R.light&&G(C[M],"lightChannel",ec(rc(R.light))),R.dark&&G(C[M],"darkChannel",ec(rc(R.dark))),R.contrastText&&G(C[M],"contrastTextChannel",ec(rc(R.contrastText))),M==="text"&&(Qi(C[M],"primary"),Qi(C[M],"secondary")),M==="action"&&(R.active&&Qi(C[M],"active"),R.selected&&Qi(C[M],"selected")))})}),S=t.reduce((A,C)=>Pn(A,C),S);const P={prefix:o,disableCssColorScheme:i,shouldSkipGeneratingVar:s,getSelector:j$(S),enableContrastVars:a},{vars:D,generateThemeVars:T,generateStyleSheets:I}=r$(S,P);return S.vars=D,Object.entries(S.colorSchemes[S.defaultColorScheme]).forEach(([A,C])=>{S[A]=C}),S.generateThemeVars=T,S.generateStyleSheets=I,S.generateSpacing=function(){return qw(u.spacing,Om(this))},S.getColorSchemeSelector=i$(l),S.spacing=S.generateSpacing(),S.shouldSkipGeneratingVar=s,S.unstable_sxConfig={...gd,...u?.unstable_sxConfig},S.unstable_sx=function(C){return Es({sx:C,theme:this})},S.toRuntimeSource=y_,S}function __(e,t,n){e.colorSchemes&&n&&(e.colorSchemes[t]={...n!==!0&&n,palette:Gm({...n===!0?{}:n.palette,mode:t})})}function R$(e={},...t){const{palette:n,cssVariables:r=!1,colorSchemes:i=n?void 0:{light:!0},defaultColorScheme:o=n?.mode,...a}=e,s=o||"light",l=i?.[s],c={...i,...n?{[s]:{...typeof l!="boolean"&&l,palette:n}}:void 0};if(r===!1){if(!("colorSchemes"in e))return Xm(e,...t);let u=n;"palette"in e||c[s]&&(c[s]!==!0?u=c[s].palette:s==="dark"&&(u={mode:"dark"}));const d=Xm({...e,palette:u},...t);return d.defaultColorScheme=s,d.colorSchemes=c,d.palette.mode==="light"&&(d.colorSchemes.light={...c.light!==!0&&c.light,palette:d.palette},__(d,"dark",c.dark)),d.palette.mode==="dark"&&(d.colorSchemes.dark={...c.dark!==!0&&c.dark,palette:d.palette},__(d,"light",c.light)),d}return!n&&!("light"in c)&&s==="light"&&(c.light=!0),L$({...a,colorSchemes:c,defaultColorScheme:s,...typeof r!="boolean"&&r},...t)}const Jm=R$(),eg="$$material";function Id(){const e=Gw(Jm);return process.env.NODE_ENV!=="production"&&O.useDebugValue(e),e[eg]||e}function E_(e){return h.jsx(Xw,{...e,defaultTheme:Jm,themeId:eg})}process.env.NODE_ENV!=="production"&&(E_.propTypes={styles:b.oneOfType([b.array,b.func,b.number,b.object,b.string,b.bool])});function S_(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const Zi=e=>S_(e)&&e!=="classes",De=RR({themeId:eg,defaultTheme:Jm,rootShouldForwardProp:Zi});function $$(e){return function(n){return h.jsx(E_,{styles:typeof e=="function"?r=>e({theme:r,...n}):e})}}const Hn=JR;process.env.NODE_ENV!=="production"&&(b.node,b.object.isRequired);function Zn(e){return QR(e)}function B$(e){return xn("MuiSvgIcon",e)}Vn("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const W$=e=>{const{color:t,fontSize:n,classes:r}=e,i={root:["root",t!=="inherit"&&`color${yn(t)}`,`fontSize${yn(n)}`]};return kn(i,B$,r)},z$=De("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.color!=="inherit"&&t[`color${yn(n.color)}`],t[`fontSize${yn(n.fontSize)}`]]}})(Hn(({theme:e})=>({userSelect:"none",width:"1em",height:"1em",display:"inline-block",flexShrink:0,transition:e.transitions?.create?.("fill",{duration:(e.vars??e).transitions?.duration?.shorter}),variants:[{props:t=>!t.hasSvgAsChild,style:{fill:"currentColor"}},{props:{fontSize:"inherit"},style:{fontSize:"inherit"}},{props:{fontSize:"small"},style:{fontSize:e.typography?.pxToRem?.(20)||"1.25rem"}},{props:{fontSize:"medium"},style:{fontSize:e.typography?.pxToRem?.(24)||"1.5rem"}},{props:{fontSize:"large"},style:{fontSize:e.typography?.pxToRem?.(35)||"2.1875rem"}},...Object.entries((e.vars??e).palette).filter(([,t])=>t&&t.main).map(([t])=>({props:{color:t},style:{color:(e.vars??e).palette?.[t]?.main}})),{props:{color:"action"},style:{color:(e.vars??e).palette?.action?.active}},{props:{color:"disabled"},style:{color:(e.vars??e).palette?.action?.disabled}},{props:{color:"inherit"},style:{color:void 0}}]}))),Fd=O.forwardRef(function(t,n){const r=Zn({props:t,name:"MuiSvgIcon"}),{children:i,className:o,color:a="inherit",component:s="svg",fontSize:l="medium",htmlColor:c,inheritViewBox:u=!1,titleAccess:d,viewBox:f="0 0 24 24",...p}=r,m=O.isValidElement(i)&&i.type==="svg",g={...r,color:a,component:s,fontSize:l,instanceFontSize:t.fontSize,inheritViewBox:u,viewBox:f,hasSvgAsChild:m},v={};u||(v.viewBox=f);const x=W$(g);return h.jsxs(z$,{as:s,className:ue(x.root,o),focusable:"false",color:c,"aria-hidden":d?void 0:!0,role:d?"img":void 0,ref:n,...v,...p,...m&&i.props,ownerState:g,children:[m?i.props.children:i,d?h.jsx("title",{children:d}):null]})});process.env.NODE_ENV!=="production"&&(Fd.propTypes={children:b.node,classes:b.object,className:b.string,color:b.oneOfType([b.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),b.string]),component:b.elementType,fontSize:b.oneOfType([b.oneOf(["inherit","large","medium","small"]),b.string]),htmlColor:b.string,inheritViewBox:b.bool,shapeRendering:b.string,sx:b.oneOfType([b.arrayOf(b.oneOfType([b.func,b.object,b.bool])),b.func,b.object]),titleAccess:b.string,viewBox:b.string}),Fd.muiName="SvgIcon";function ic(e,t){function n(r,i){return h.jsx(Fd,{"data-testid":process.env.NODE_ENV!=="production"?`${t}Icon`:void 0,ref:i,...r,children:e})}return process.env.NODE_ENV!=="production"&&(n.displayName=`${t}Icon`),n.muiName=Fd.muiName,O.memo(O.forwardRef(n))}function O_(e,t=166){let n;function r(...i){const o=()=>{e.apply(this,i)};clearTimeout(n),n=setTimeout(o,t)}return r.clear=()=>{clearTimeout(n)},r}function gr(e){return e&&e.ownerDocument||document}function Ji(e){return gr(e).defaultView||window}function C_(e,t){typeof e=="function"?e(t):e&&(e.current=t)}function tg(e){const{controlled:t,default:n,name:r,state:i="value"}=e,{current:o}=O.useRef(t!==void 0),[a,s]=O.useState(n),l=o?t:a;if(process.env.NODE_ENV!=="production"){O.useEffect(()=>{o!==(t!==void 0)&&console.error([`MUI: A component is changing the ${o?"":"un"}controlled ${i} state of ${r} to be ${o?"un":""}controlled.`,"Elements should not switch from uncontrolled to controlled (or vice versa).",`Decide between using a controlled or uncontrolled ${r} element for the lifetime of the component.`,"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.","More info: https://fb.me/react-controlled-components"].join(`
|
|
116
|
+
`))}v[_]={}}}};Object.keys(p.components).forEach(v=>{const x=p.components[v].styleOverrides;x&&v.startsWith("Mui")&&g(x,v)})}return p.unstable_sxConfig={...gd,...u?.unstable_sxConfig},p.unstable_sx=function(g){return Es({sx:g,theme:this})},p.toRuntimeSource=y_,P$(p),p}function Qm(e){let t;return e<1?t=5.11916*e**2:t=4.5*Math.log(e+1)+2,Math.round(t*10)/1e3}const D$=[...Array(25)].map((e,t)=>{if(t===0)return"none";const n=Qm(t);return`linear-gradient(rgba(255 255 255 / ${n}), rgba(255 255 255 / ${n}))`});function x_(e){return{inputPlaceholder:e==="dark"?.5:.42,inputUnderline:e==="dark"?.7:.42,switchTrackDisabled:e==="dark"?.2:.12,switchTrack:e==="dark"?.3:.38}}function w_(e){return e==="dark"?D$:[]}function A$(e){const{palette:t={mode:"light"},opacity:n,overlays:r,colorSpace:i,...o}=e,a=Gm({...t,colorSpace:i});return{palette:a,opacity:{...x_(a.mode),...n},overlays:r||w_(a.mode),...o}}function T$(e){return!!e[0].match(/(cssVarPrefix|colorSchemeSelector|modularCssLayers|rootSelector|typography|mixins|breakpoints|direction|transitions)/)||!!e[0].match(/sxConfig$/)||e[0]==="palette"&&!!e[1]?.match(/(mode|contrastThreshold|tonalOffset)/)}const N$=e=>[...[...Array(25)].map((t,n)=>`--${e?`${e}-`:""}overlays-${n}`),`--${e?`${e}-`:""}palette-AppBar-darkBg`,`--${e?`${e}-`:""}palette-AppBar-darkColor`],j$=e=>(t,n)=>{const r=e.rootSelector||":root",i=e.colorSchemeSelector;let o=i;if(i==="class"&&(o=".%s"),i==="data"&&(o="[data-%s]"),i?.startsWith("data-")&&!i.includes("%s")&&(o=`[${i}="%s"]`),e.defaultColorScheme===t){if(t==="dark"){const a={};return N$(e.cssVarPrefix).forEach(s=>{a[s]=n[s],delete n[s]}),o==="media"?{[r]:n,"@media (prefers-color-scheme: dark)":{[r]:a}}:o?{[o.replace("%s",t)]:a,[`${r}, ${o.replace("%s",t)}`]:n}:{[r]:{...n,...a}}}if(o&&o!=="media")return`${r}, ${o.replace("%s",String(t))}`}else if(t){if(o==="media")return{[`@media (prefers-color-scheme: ${String(t)})`]:{[r]:n}};if(o)return o.replace("%s",String(t))}return r};function M$(e,t){t.forEach(n=>{e[n]||(e[n]={})})}function X(e,t,n){!e[t]&&n&&(e[t]=n)}function rc(e){return typeof e!="string"||!e.startsWith("hsl")?e:n_(e)}function Qi(e,t){`${t}Channel`in e||(e[`${t}Channel`]=ec(rc(e[t]),`MUI: Can't create \`palette.${t}Channel\` because \`palette.${t}\` is not one of these formats: #nnn, #nnnnnn, rgb(), rgba(), hsl(), hsla(), color().
|
|
117
|
+
To suppress this warning, you need to explicitly provide the \`palette.${t}Channel\` as a string (in rgb format, for example "12 12 12") or undefined if you want to remove the channel token.`))}function I$(e){return typeof e=="number"?`${e}px`:typeof e=="string"||typeof e=="function"||Array.isArray(e)?e:"8px"}const vi=e=>{try{return e()}catch{}},F$=(e="mui")=>e$(e);function Zm(e,t,n,r,i){if(!n)return;n=n===!0?{}:n;const o=i==="dark"?"dark":"light";if(!r){t[i]=A$({...n,palette:{mode:o,...n?.palette},colorSpace:e});return}const{palette:a,...s}=Xm({...r,palette:{mode:o,...n?.palette},colorSpace:e});return t[i]={...n,palette:a,opacity:{...x_(o),...n?.opacity},overlays:n?.overlays||w_(o)},s}function L$(e={},...t){const{colorSchemes:n={light:!0},defaultColorScheme:r,disableCssColorScheme:i=!1,cssVarPrefix:o="mui",nativeColor:a=!1,shouldSkipGeneratingVar:s=T$,colorSchemeSelector:l=n.light&&n.dark?"media":void 0,rootSelector:c=":root",...u}=e,d=Object.keys(n)[0],f=r||(n.light&&d!=="light"?"light":d),p=F$(o),{[f]:m,light:g,dark:v,...x}=n,_={...x};let w=m;if((f==="dark"&&!("dark"in n)||f==="light"&&!("light"in n))&&(w=!0),!w)throw new Error(process.env.NODE_ENV!=="production"?`MUI: The \`colorSchemes.${f}\` option is either missing or invalid.`:pi(21,f));let y;a&&(y="oklch");const E=Zm(y,_,w,u,f);g&&!_.light&&Zm(y,_,g,void 0,"light"),v&&!_.dark&&Zm(y,_,v,void 0,"dark");let S={defaultColorScheme:f,...E,cssVarPrefix:o,colorSchemeSelector:l,rootSelector:c,getCssVar:p,colorSchemes:_,font:{...p$(E.typography),...E.font},spacing:I$(u.spacing)};Object.keys(S.colorSchemes).forEach(A=>{const C=S.colorSchemes[A].palette,j=M=>{const R=M.split("-"),B=R[1],V=R[2];return p(M,C[B][V])};C.mode==="light"&&(X(C.common,"background","#fff"),X(C.common,"onBackground","#000")),C.mode==="dark"&&(X(C.common,"background","#000"),X(C.common,"onBackground","#fff"));function N(M,R,B){if(y){let V;return M===xa&&(V=`transparent ${((1-B)*100).toFixed(0)}%`),M===Ge&&(V=`#000 ${(B*100).toFixed(0)}%`),M===Xe&&(V=`#fff ${(B*100).toFixed(0)}%`),`color-mix(in ${y}, ${R}, ${V})`}return M(R,B)}if(M$(C,["Alert","AppBar","Avatar","Button","Chip","FilledInput","LinearProgress","Skeleton","Slider","SnackbarContent","SpeedDialAction","StepConnector","StepContent","Switch","TableCell","Tooltip"]),C.mode==="light"){X(C.Alert,"errorColor",N(Ge,C.error.light,.6)),X(C.Alert,"infoColor",N(Ge,C.info.light,.6)),X(C.Alert,"successColor",N(Ge,C.success.light,.6)),X(C.Alert,"warningColor",N(Ge,C.warning.light,.6)),X(C.Alert,"errorFilledBg",j("palette-error-main")),X(C.Alert,"infoFilledBg",j("palette-info-main")),X(C.Alert,"successFilledBg",j("palette-success-main")),X(C.Alert,"warningFilledBg",j("palette-warning-main")),X(C.Alert,"errorFilledColor",vi(()=>C.getContrastText(C.error.main))),X(C.Alert,"infoFilledColor",vi(()=>C.getContrastText(C.info.main))),X(C.Alert,"successFilledColor",vi(()=>C.getContrastText(C.success.main))),X(C.Alert,"warningFilledColor",vi(()=>C.getContrastText(C.warning.main))),X(C.Alert,"errorStandardBg",N(Xe,C.error.light,.9)),X(C.Alert,"infoStandardBg",N(Xe,C.info.light,.9)),X(C.Alert,"successStandardBg",N(Xe,C.success.light,.9)),X(C.Alert,"warningStandardBg",N(Xe,C.warning.light,.9)),X(C.Alert,"errorIconColor",j("palette-error-main")),X(C.Alert,"infoIconColor",j("palette-info-main")),X(C.Alert,"successIconColor",j("palette-success-main")),X(C.Alert,"warningIconColor",j("palette-warning-main")),X(C.AppBar,"defaultBg",j("palette-grey-100")),X(C.Avatar,"defaultBg",j("palette-grey-400")),X(C.Button,"inheritContainedBg",j("palette-grey-300")),X(C.Button,"inheritContainedHoverBg",j("palette-grey-A100")),X(C.Chip,"defaultBorder",j("palette-grey-400")),X(C.Chip,"defaultAvatarColor",j("palette-grey-700")),X(C.Chip,"defaultIconColor",j("palette-grey-700")),X(C.FilledInput,"bg","rgba(0, 0, 0, 0.06)"),X(C.FilledInput,"hoverBg","rgba(0, 0, 0, 0.09)"),X(C.FilledInput,"disabledBg","rgba(0, 0, 0, 0.12)"),X(C.LinearProgress,"primaryBg",N(Xe,C.primary.main,.62)),X(C.LinearProgress,"secondaryBg",N(Xe,C.secondary.main,.62)),X(C.LinearProgress,"errorBg",N(Xe,C.error.main,.62)),X(C.LinearProgress,"infoBg",N(Xe,C.info.main,.62)),X(C.LinearProgress,"successBg",N(Xe,C.success.main,.62)),X(C.LinearProgress,"warningBg",N(Xe,C.warning.main,.62)),X(C.Skeleton,"bg",y?N(xa,C.text.primary,.11):`rgba(${j("palette-text-primaryChannel")} / 0.11)`),X(C.Slider,"primaryTrack",N(Xe,C.primary.main,.62)),X(C.Slider,"secondaryTrack",N(Xe,C.secondary.main,.62)),X(C.Slider,"errorTrack",N(Xe,C.error.main,.62)),X(C.Slider,"infoTrack",N(Xe,C.info.main,.62)),X(C.Slider,"successTrack",N(Xe,C.success.main,.62)),X(C.Slider,"warningTrack",N(Xe,C.warning.main,.62));const M=y?N(Ge,C.background.default,.6825):Md(C.background.default,.8);X(C.SnackbarContent,"bg",M),X(C.SnackbarContent,"color",vi(()=>y?qm.text.primary:C.getContrastText(M))),X(C.SpeedDialAction,"fabHoverBg",Md(C.background.paper,.15)),X(C.StepConnector,"border",j("palette-grey-400")),X(C.StepContent,"border",j("palette-grey-400")),X(C.Switch,"defaultColor",j("palette-common-white")),X(C.Switch,"defaultDisabledColor",j("palette-grey-100")),X(C.Switch,"primaryDisabledColor",N(Xe,C.primary.main,.62)),X(C.Switch,"secondaryDisabledColor",N(Xe,C.secondary.main,.62)),X(C.Switch,"errorDisabledColor",N(Xe,C.error.main,.62)),X(C.Switch,"infoDisabledColor",N(Xe,C.info.main,.62)),X(C.Switch,"successDisabledColor",N(Xe,C.success.main,.62)),X(C.Switch,"warningDisabledColor",N(Xe,C.warning.main,.62)),X(C.TableCell,"border",N(Xe,N(xa,C.divider,1),.88)),X(C.Tooltip,"bg",N(xa,C.grey[700],.92))}if(C.mode==="dark"){X(C.Alert,"errorColor",N(Xe,C.error.light,.6)),X(C.Alert,"infoColor",N(Xe,C.info.light,.6)),X(C.Alert,"successColor",N(Xe,C.success.light,.6)),X(C.Alert,"warningColor",N(Xe,C.warning.light,.6)),X(C.Alert,"errorFilledBg",j("palette-error-dark")),X(C.Alert,"infoFilledBg",j("palette-info-dark")),X(C.Alert,"successFilledBg",j("palette-success-dark")),X(C.Alert,"warningFilledBg",j("palette-warning-dark")),X(C.Alert,"errorFilledColor",vi(()=>C.getContrastText(C.error.dark))),X(C.Alert,"infoFilledColor",vi(()=>C.getContrastText(C.info.dark))),X(C.Alert,"successFilledColor",vi(()=>C.getContrastText(C.success.dark))),X(C.Alert,"warningFilledColor",vi(()=>C.getContrastText(C.warning.dark))),X(C.Alert,"errorStandardBg",N(Ge,C.error.light,.9)),X(C.Alert,"infoStandardBg",N(Ge,C.info.light,.9)),X(C.Alert,"successStandardBg",N(Ge,C.success.light,.9)),X(C.Alert,"warningStandardBg",N(Ge,C.warning.light,.9)),X(C.Alert,"errorIconColor",j("palette-error-main")),X(C.Alert,"infoIconColor",j("palette-info-main")),X(C.Alert,"successIconColor",j("palette-success-main")),X(C.Alert,"warningIconColor",j("palette-warning-main")),X(C.AppBar,"defaultBg",j("palette-grey-900")),X(C.AppBar,"darkBg",j("palette-background-paper")),X(C.AppBar,"darkColor",j("palette-text-primary")),X(C.Avatar,"defaultBg",j("palette-grey-600")),X(C.Button,"inheritContainedBg",j("palette-grey-800")),X(C.Button,"inheritContainedHoverBg",j("palette-grey-700")),X(C.Chip,"defaultBorder",j("palette-grey-700")),X(C.Chip,"defaultAvatarColor",j("palette-grey-300")),X(C.Chip,"defaultIconColor",j("palette-grey-300")),X(C.FilledInput,"bg","rgba(255, 255, 255, 0.09)"),X(C.FilledInput,"hoverBg","rgba(255, 255, 255, 0.13)"),X(C.FilledInput,"disabledBg","rgba(255, 255, 255, 0.12)"),X(C.LinearProgress,"primaryBg",N(Ge,C.primary.main,.5)),X(C.LinearProgress,"secondaryBg",N(Ge,C.secondary.main,.5)),X(C.LinearProgress,"errorBg",N(Ge,C.error.main,.5)),X(C.LinearProgress,"infoBg",N(Ge,C.info.main,.5)),X(C.LinearProgress,"successBg",N(Ge,C.success.main,.5)),X(C.LinearProgress,"warningBg",N(Ge,C.warning.main,.5)),X(C.Skeleton,"bg",y?N(xa,C.text.primary,.13):`rgba(${j("palette-text-primaryChannel")} / 0.13)`),X(C.Slider,"primaryTrack",N(Ge,C.primary.main,.5)),X(C.Slider,"secondaryTrack",N(Ge,C.secondary.main,.5)),X(C.Slider,"errorTrack",N(Ge,C.error.main,.5)),X(C.Slider,"infoTrack",N(Ge,C.info.main,.5)),X(C.Slider,"successTrack",N(Ge,C.success.main,.5)),X(C.Slider,"warningTrack",N(Ge,C.warning.main,.5));const M=y?N(Xe,C.background.default,.985):Md(C.background.default,.98);X(C.SnackbarContent,"bg",M),X(C.SnackbarContent,"color",vi(()=>y?d_.text.primary:C.getContrastText(M))),X(C.SpeedDialAction,"fabHoverBg",Md(C.background.paper,.15)),X(C.StepConnector,"border",j("palette-grey-600")),X(C.StepContent,"border",j("palette-grey-600")),X(C.Switch,"defaultColor",j("palette-grey-300")),X(C.Switch,"defaultDisabledColor",j("palette-grey-600")),X(C.Switch,"primaryDisabledColor",N(Ge,C.primary.main,.55)),X(C.Switch,"secondaryDisabledColor",N(Ge,C.secondary.main,.55)),X(C.Switch,"errorDisabledColor",N(Ge,C.error.main,.55)),X(C.Switch,"infoDisabledColor",N(Ge,C.info.main,.55)),X(C.Switch,"successDisabledColor",N(Ge,C.success.main,.55)),X(C.Switch,"warningDisabledColor",N(Ge,C.warning.main,.55)),X(C.TableCell,"border",N(Ge,N(xa,C.divider,1),.68)),X(C.Tooltip,"bg",N(xa,C.grey[700],.92))}Qi(C.background,"default"),Qi(C.background,"paper"),Qi(C.common,"background"),Qi(C.common,"onBackground"),Qi(C,"divider"),Object.keys(C).forEach(M=>{const R=C[M];M!=="tonalOffset"&&R&&typeof R=="object"&&(R.main&&X(C[M],"mainChannel",ec(rc(R.main))),R.light&&X(C[M],"lightChannel",ec(rc(R.light))),R.dark&&X(C[M],"darkChannel",ec(rc(R.dark))),R.contrastText&&X(C[M],"contrastTextChannel",ec(rc(R.contrastText))),M==="text"&&(Qi(C[M],"primary"),Qi(C[M],"secondary")),M==="action"&&(R.active&&Qi(C[M],"active"),R.selected&&Qi(C[M],"selected")))})}),S=t.reduce((A,C)=>Pn(A,C),S);const P={prefix:o,disableCssColorScheme:i,shouldSkipGeneratingVar:s,getSelector:j$(S),enableContrastVars:a},{vars:D,generateThemeVars:T,generateStyleSheets:I}=r$(S,P);return S.vars=D,Object.entries(S.colorSchemes[S.defaultColorScheme]).forEach(([A,C])=>{S[A]=C}),S.generateThemeVars=T,S.generateStyleSheets=I,S.generateSpacing=function(){return qw(u.spacing,Om(this))},S.getColorSchemeSelector=i$(l),S.spacing=S.generateSpacing(),S.shouldSkipGeneratingVar=s,S.unstable_sxConfig={...gd,...u?.unstable_sxConfig},S.unstable_sx=function(C){return Es({sx:C,theme:this})},S.toRuntimeSource=y_,S}function __(e,t,n){e.colorSchemes&&n&&(e.colorSchemes[t]={...n!==!0&&n,palette:Gm({...n===!0?{}:n.palette,mode:t})})}function R$(e={},...t){const{palette:n,cssVariables:r=!1,colorSchemes:i=n?void 0:{light:!0},defaultColorScheme:o=n?.mode,...a}=e,s=o||"light",l=i?.[s],c={...i,...n?{[s]:{...typeof l!="boolean"&&l,palette:n}}:void 0};if(r===!1){if(!("colorSchemes"in e))return Xm(e,...t);let u=n;"palette"in e||c[s]&&(c[s]!==!0?u=c[s].palette:s==="dark"&&(u={mode:"dark"}));const d=Xm({...e,palette:u},...t);return d.defaultColorScheme=s,d.colorSchemes=c,d.palette.mode==="light"&&(d.colorSchemes.light={...c.light!==!0&&c.light,palette:d.palette},__(d,"dark",c.dark)),d.palette.mode==="dark"&&(d.colorSchemes.dark={...c.dark!==!0&&c.dark,palette:d.palette},__(d,"light",c.light)),d}return!n&&!("light"in c)&&s==="light"&&(c.light=!0),L$({...a,colorSchemes:c,defaultColorScheme:s,...typeof r!="boolean"&&r},...t)}const Jm=R$(),eg="$$material";function Id(){const e=Gw(Jm);return process.env.NODE_ENV!=="production"&&O.useDebugValue(e),e[eg]||e}function E_(e){return h.jsx(Xw,{...e,defaultTheme:Jm,themeId:eg})}process.env.NODE_ENV!=="production"&&(E_.propTypes={styles:b.oneOfType([b.array,b.func,b.number,b.object,b.string,b.bool])});function S_(e){return e!=="ownerState"&&e!=="theme"&&e!=="sx"&&e!=="as"}const Zi=e=>S_(e)&&e!=="classes",De=RR({themeId:eg,defaultTheme:Jm,rootShouldForwardProp:Zi});function $$(e){return function(n){return h.jsx(E_,{styles:typeof e=="function"?r=>e({theme:r,...n}):e})}}const Hn=JR;process.env.NODE_ENV!=="production"&&(b.node,b.object.isRequired);function Zn(e){return QR(e)}function B$(e){return xn("MuiSvgIcon",e)}Vn("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const W$=e=>{const{color:t,fontSize:n,classes:r}=e,i={root:["root",t!=="inherit"&&`color${yn(t)}`,`fontSize${yn(n)}`]};return kn(i,B$,r)},z$=De("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.color!=="inherit"&&t[`color${yn(n.color)}`],t[`fontSize${yn(n.fontSize)}`]]}})(Hn(({theme:e})=>({userSelect:"none",width:"1em",height:"1em",display:"inline-block",flexShrink:0,transition:e.transitions?.create?.("fill",{duration:(e.vars??e).transitions?.duration?.shorter}),variants:[{props:t=>!t.hasSvgAsChild,style:{fill:"currentColor"}},{props:{fontSize:"inherit"},style:{fontSize:"inherit"}},{props:{fontSize:"small"},style:{fontSize:e.typography?.pxToRem?.(20)||"1.25rem"}},{props:{fontSize:"medium"},style:{fontSize:e.typography?.pxToRem?.(24)||"1.5rem"}},{props:{fontSize:"large"},style:{fontSize:e.typography?.pxToRem?.(35)||"2.1875rem"}},...Object.entries((e.vars??e).palette).filter(([,t])=>t&&t.main).map(([t])=>({props:{color:t},style:{color:(e.vars??e).palette?.[t]?.main}})),{props:{color:"action"},style:{color:(e.vars??e).palette?.action?.active}},{props:{color:"disabled"},style:{color:(e.vars??e).palette?.action?.disabled}},{props:{color:"inherit"},style:{color:void 0}}]}))),Fd=O.forwardRef(function(t,n){const r=Zn({props:t,name:"MuiSvgIcon"}),{children:i,className:o,color:a="inherit",component:s="svg",fontSize:l="medium",htmlColor:c,inheritViewBox:u=!1,titleAccess:d,viewBox:f="0 0 24 24",...p}=r,m=O.isValidElement(i)&&i.type==="svg",g={...r,color:a,component:s,fontSize:l,instanceFontSize:t.fontSize,inheritViewBox:u,viewBox:f,hasSvgAsChild:m},v={};u||(v.viewBox=f);const x=W$(g);return h.jsxs(z$,{as:s,className:ue(x.root,o),focusable:"false",color:c,"aria-hidden":d?void 0:!0,role:d?"img":void 0,ref:n,...v,...p,...m&&i.props,ownerState:g,children:[m?i.props.children:i,d?h.jsx("title",{children:d}):null]})});process.env.NODE_ENV!=="production"&&(Fd.propTypes={children:b.node,classes:b.object,className:b.string,color:b.oneOfType([b.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),b.string]),component:b.elementType,fontSize:b.oneOfType([b.oneOf(["inherit","large","medium","small"]),b.string]),htmlColor:b.string,inheritViewBox:b.bool,shapeRendering:b.string,sx:b.oneOfType([b.arrayOf(b.oneOfType([b.func,b.object,b.bool])),b.func,b.object]),titleAccess:b.string,viewBox:b.string}),Fd.muiName="SvgIcon";function ic(e,t){function n(r,i){return h.jsx(Fd,{"data-testid":process.env.NODE_ENV!=="production"?`${t}Icon`:void 0,ref:i,...r,children:e})}return process.env.NODE_ENV!=="production"&&(n.displayName=`${t}Icon`),n.muiName=Fd.muiName,O.memo(O.forwardRef(n))}function O_(e,t=166){let n;function r(...i){const o=()=>{e.apply(this,i)};clearTimeout(n),n=setTimeout(o,t)}return r.clear=()=>{clearTimeout(n)},r}function gr(e){return e&&e.ownerDocument||document}function Ji(e){return gr(e).defaultView||window}function C_(e,t){typeof e=="function"?e(t):e&&(e.current=t)}function tg(e){const{controlled:t,default:n,name:r,state:i="value"}=e,{current:o}=O.useRef(t!==void 0),[a,s]=O.useState(n),l=o?t:a;if(process.env.NODE_ENV!=="production"){O.useEffect(()=>{o!==(t!==void 0)&&console.error([`MUI: A component is changing the ${o?"":"un"}controlled ${i} state of ${r} to be ${o?"un":""}controlled.`,"Elements should not switch from uncontrolled to controlled (or vice versa).",`Decide between using a controlled or uncontrolled ${r} element for the lifetime of the component.`,"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.","More info: https://fb.me/react-controlled-components"].join(`
|
|
118
118
|
`))},[i,r,t]);const{current:u}=O.useRef(n);O.useEffect(()=>{!o&&JSON.stringify(n)!==JSON.stringify(u)&&console.error([`MUI: A component is changing the default ${i} state of an uncontrolled ${r} after being initialized. To suppress this warning opt to use a controlled ${r}.`].join(`
|
|
119
119
|
`))},[JSON.stringify(n)])}const c=O.useCallback(u=>{o||s(u)},[]);return[l,c]}function oc(e){const t=O.useRef(e);return Xi(()=>{t.current=e}),O.useRef((...n)=>(0,t.current)(...n)).current}function Yn(...e){const t=O.useRef(void 0),n=O.useCallback(r=>{const i=e.map(o=>{if(o==null)return null;if(typeof o=="function"){const a=o,s=a(r);return typeof s=="function"?s:()=>{a(null)}}return o.current=r,()=>{o.current=null}});return()=>{i.forEach(o=>o?.())}},e);return O.useMemo(()=>e.every(r=>r==null)?null:r=>{t.current&&(t.current(),t.current=void 0),r!=null&&(t.current=n(r))},e)}function V$(e,t){const n=e.charCodeAt(2);return e[0]==="o"&&e[1]==="n"&&n>=65&&n<=90&&typeof t=="function"}function H$(e,t){if(!e)return t;function n(a,s){const l={};return Object.keys(s).forEach(c=>{V$(c,s[c])&&typeof a[c]=="function"&&(l[c]=(...u)=>{a[c](...u),s[c](...u)})}),l}if(typeof e=="function"||typeof t=="function")return a=>{const s=typeof t=="function"?t(a):t,l=typeof e=="function"?e({...a,...s}):e,c=ue(a?.className,s?.className,l?.className),u=n(l,s);return{...s,...l,...u,...!!c&&{className:c},...s?.style&&l?.style&&{style:{...s.style,...l.style}},...s?.sx&&l?.sx&&{sx:[...Array.isArray(s.sx)?s.sx:[s.sx],...Array.isArray(l.sx)?l.sx:[l.sx]]}}};const r=t,i=n(e,r),o=ue(r?.className,e?.className);return{...t,...e,...i,...!!o&&{className:o},...r?.style&&e?.style&&{style:{...r.style,...e.style}},...r?.sx&&e?.sx&&{sx:[...Array.isArray(r.sx)?r.sx:[r.sx],...Array.isArray(e.sx)?e.sx:[e.sx]]}}}const Y$=ic(h.jsx("path",{d:"M20 3h-1V1h-2v2H7V1H5v2H4c-1.1 0-2 .9-2 2v16c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2m0 18H4V10h16zm0-13H4V5h16z"}),"CalendarTodayOutlined"),Ld=ic(h.jsx("path",{d:"M8 16h8v2H8zm0-4h8v2H8zm6-10H6c-1.1 0-2 .9-2 2v16c0 1.1.89 2 1.99 2H18c1.1 0 2-.9 2-2V8zm4 18H6V4h7v5h5z"}),"DescriptionOutlined"),U$=ic(h.jsx("path",{d:"M18 15v3H6v-3H4v3c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2v-3zm-1-4-1.41-1.41L13 12.17V4h-2v8.17L8.41 9.59 7 11l5 5z"}),"FileDownloadOutlined"),K$=ic(h.jsx("path",{d:"M7.41 8.59 12 13.17l4.59-4.58L18 10l-6 6-6-6z"}),"KeyboardArrowDown"),k_=6048e5,q$=864e5,Rd=6e4,$d=36e5,G$=1e3,P_=Symbol.for("constructDateFrom");function Qe(e,t){return typeof e=="function"?e(t):e&&typeof e=="object"&&P_ in e?e[P_](t):e instanceof Date?new e.constructor(t):new Date(t)}function ve(e,t){return Qe(t||e,e)}function ei(e,t,n){const r=ve(e,n?.in);return isNaN(t)?Qe(n?.in||e,NaN):(t&&r.setDate(r.getDate()+t),r)}function ti(e,t,n){const r=ve(e,n?.in);if(isNaN(t))return Qe(e,NaN);if(!t)return r;const i=r.getDate(),o=Qe(e,r.getTime());o.setMonth(r.getMonth()+t+1,0);const a=o.getDate();return i>=a?o:(r.setFullYear(o.getFullYear(),o.getMonth(),i),r)}function D_(e,t,n){return Qe(e,+ve(e)+t)}function X$(e,t,n){return D_(e,t*$d)}let Q$={};function wa(){return Q$}function eo(e,t){const n=wa(),r=t?.weekStartsOn??t?.locale?.options?.weekStartsOn??n.weekStartsOn??n.locale?.options?.weekStartsOn??0,i=ve(e,t?.in),o=i.getDay(),a=(o<r?7:0)+o-r;return i.setDate(i.getDate()-a),i.setHours(0,0,0,0),i}function Ns(e,t){return eo(e,{...t,weekStartsOn:1})}function A_(e,t){const n=ve(e,t?.in),r=n.getFullYear(),i=Qe(n,0);i.setFullYear(r+1,0,4),i.setHours(0,0,0,0);const o=Ns(i),a=Qe(n,0);a.setFullYear(r,0,4),a.setHours(0,0,0,0);const s=Ns(a);return n.getTime()>=o.getTime()?r+1:n.getTime()>=s.getTime()?r:r-1}function Bd(e){const t=ve(e),n=new Date(Date.UTC(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()));return n.setUTCFullYear(t.getFullYear()),+e-+n}function to(e,...t){const n=Qe.bind(null,t.find(r=>typeof r=="object"));return t.map(n)}function _a(e,t){const n=ve(e,t?.in);return n.setHours(0,0,0,0),n}function js(e,t,n){const[r,i]=to(n?.in,e,t),o=_a(r),a=_a(i),s=+o-Bd(o),l=+a-Bd(a);return Math.round((s-l)/q$)}function Z$(e,t){const n=A_(e,t),r=Qe(e,0);return r.setFullYear(n,0,4),r.setHours(0,0,0,0),Ns(r)}function ac(e,t,n){const r=ve(e,n?.in);return r.setTime(r.getTime()+t*Rd),r}function ng(e,t,n){return ti(e,t*3,n)}function J$(e,t,n){return D_(e,t*1e3)}function Wd(e,t,n){return ei(e,t*7,n)}function ni(e,t,n){return ti(e,t*12,n)}function T_(e,t){let n,r=t?.in;return e.forEach(i=>{!r&&typeof i=="object"&&(r=Qe.bind(null,i));const o=ve(i,r);(!n||n<o||isNaN(+o))&&(n=o)}),Qe(r,n||NaN)}function N_(e,t){let n,r=t?.in;return e.forEach(i=>{!r&&typeof i=="object"&&(r=Qe.bind(null,i));const o=ve(i,r);(!n||n>o||isNaN(+o))&&(n=o)}),Qe(r,n||NaN)}function e5(e,t,n){const[r,i]=to(n?.in,e,t);return+_a(r)==+_a(i)}function yi(e){return e instanceof Date||typeof e=="object"&&Object.prototype.toString.call(e)==="[object Date]"}function Ms(e){return!(!yi(e)&&typeof e!="number"||isNaN(+ve(e)))}function zd(e,t,n){const[r,i]=to(n?.in,e,t),o=r.getFullYear()-i.getFullYear(),a=r.getMonth()-i.getMonth();return o*12+a}function Vo(e,t){const n=ve(e,t?.in);return Math.trunc(n.getMonth()/3)+1}function Vd(e,t,n){const[r,i]=to(n?.in,e,t),o=r.getFullYear()-i.getFullYear(),a=Vo(r)-Vo(i);return o*4+a}function Hd(e,t,n){const[r,i]=to(n?.in,e,t);return r.getFullYear()-i.getFullYear()}function t5(e,t,n){const[r,i]=to(n?.in,e,t),o=j_(r,i),a=Math.abs(js(r,i));r.setDate(r.getDate()-o*a);const s=+(j_(r,i)===-o),l=o*(a-s);return l===0?0:l}function j_(e,t){const n=e.getFullYear()-t.getFullYear()||e.getMonth()-t.getMonth()||e.getDate()-t.getDate()||e.getHours()-t.getHours()||e.getMinutes()-t.getMinutes()||e.getSeconds()-t.getSeconds()||e.getMilliseconds()-t.getMilliseconds();return n<0?-1:n>0?1:n}function M_(e,t){const n=ve(e,t?.in);return n.setHours(23,59,59,999),n}function I_(e,t){const n=ve(e,t?.in),r=n.getMonth();return n.setFullYear(n.getFullYear(),r+1,0),n.setHours(23,59,59,999),n}function rg(e,t){const n=ve(e,t?.in),r=n.getMonth(),i=r-r%3;return n.setMonth(i,1),n.setHours(0,0,0,0),n}function F_(e,t){const n=ve(e,t?.in);return n.setDate(1),n.setHours(0,0,0,0),n}function L_(e,t){const n=ve(e,t?.in),r=n.getFullYear();return n.setFullYear(r+1,0,0),n.setHours(23,59,59,999),n}function Yd(e,t){const n=ve(e,t?.in);return n.setFullYear(n.getFullYear(),0,1),n.setHours(0,0,0,0),n}function n5(e,t){const n=wa(),r=n.weekStartsOn??n.locale?.options?.weekStartsOn??0,i=ve(e,t?.in),o=i.getDay(),a=(o<r?-7:0)+6-(o-r);return i.setDate(i.getDate()+a),i.setHours(23,59,59,999),i}const r5={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"}},i5=(e,t,n)=>{let r;const i=r5[e];return typeof i=="string"?r=i:t===1?r=i.one:r=i.other.replace("{{count}}",t.toString()),n?.addSuffix?n.comparison&&n.comparison>0?"in "+r:r+" ago":r};function ig(e){return(t={})=>{const n=t.width?String(t.width):e.defaultWidth;return e.formats[n]||e.formats[e.defaultWidth]}}const o5={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},a5={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},s5={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},l5={date:ig({formats:o5,defaultWidth:"full"}),time:ig({formats:a5,defaultWidth:"full"}),dateTime:ig({formats:s5,defaultWidth:"full"})},c5={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},u5=(e,t,n,r)=>c5[e];function sc(e){return(t,n)=>{const r=n?.context?String(n.context):"standalone";let i;if(r==="formatting"&&e.formattingValues){const a=e.defaultFormattingWidth||e.defaultWidth,s=n?.width?String(n.width):a;i=e.formattingValues[s]||e.formattingValues[a]}else{const a=e.defaultWidth,s=n?.width?String(n.width):e.defaultWidth;i=e.values[s]||e.values[a]}const o=e.argumentCallback?e.argumentCallback(t):t;return i[o]}}const d5={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},f5={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},p5={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"]},h5={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"]},m5={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"}},g5={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"}},v5={ordinalNumber:(e,t)=>{const n=Number(e),r=n%100;if(r>20||r<10)switch(r%10){case 1:return n+"st";case 2:return n+"nd";case 3:return n+"rd"}return n+"th"},era:sc({values:d5,defaultWidth:"wide"}),quarter:sc({values:f5,defaultWidth:"wide",argumentCallback:e=>e-1}),month:sc({values:p5,defaultWidth:"wide"}),day:sc({values:h5,defaultWidth:"wide"}),dayPeriod:sc({values:m5,defaultWidth:"wide",formattingValues:g5,defaultFormattingWidth:"wide"})};function lc(e){return(t,n={})=>{const r=n.width,i=r&&e.matchPatterns[r]||e.matchPatterns[e.defaultMatchWidth],o=t.match(i);if(!o)return null;const a=o[0],s=r&&e.parsePatterns[r]||e.parsePatterns[e.defaultParseWidth],l=Array.isArray(s)?b5(s,d=>d.test(a)):y5(s,d=>d.test(a));let c;c=e.valueCallback?e.valueCallback(l):l,c=n.valueCallback?n.valueCallback(c):c;const u=t.slice(a.length);return{value:c,rest:u}}}function y5(e,t){for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&t(e[n]))return n}function b5(e,t){for(let n=0;n<e.length;n++)if(t(e[n]))return n}function x5(e){return(t,n={})=>{const r=t.match(e.matchPattern);if(!r)return null;const i=r[0],o=t.match(e.parsePattern);if(!o)return null;let a=e.valueCallback?e.valueCallback(o[0]):o[0];a=n.valueCallback?n.valueCallback(a):a;const s=t.slice(i.length);return{value:a,rest:s}}}const w5=/^(\d+)(th|st|nd|rd)?/i,_5=/\d+/i,E5={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},S5={any:[/^b/i,/^(a|c)/i]},O5={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},C5={any:[/1/i,/2/i,/3/i,/4/i]},k5={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},P5={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]},D5={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},A5={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]},T5={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},N5={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}},j5={ordinalNumber:x5({matchPattern:w5,parsePattern:_5,valueCallback:e=>parseInt(e,10)}),era:lc({matchPatterns:E5,defaultMatchWidth:"wide",parsePatterns:S5,defaultParseWidth:"any"}),quarter:lc({matchPatterns:O5,defaultMatchWidth:"wide",parsePatterns:C5,defaultParseWidth:"any",valueCallback:e=>e+1}),month:lc({matchPatterns:k5,defaultMatchWidth:"wide",parsePatterns:P5,defaultParseWidth:"any"}),day:lc({matchPatterns:D5,defaultMatchWidth:"wide",parsePatterns:A5,defaultParseWidth:"any"}),dayPeriod:lc({matchPatterns:T5,defaultMatchWidth:"any",parsePatterns:N5,defaultParseWidth:"any"})},R_={code:"en-US",formatDistance:i5,formatLong:l5,formatRelative:u5,localize:v5,match:j5,options:{weekStartsOn:0,firstWeekContainsDate:1}};function M5(e,t){const n=ve(e,t?.in);return js(n,Yd(n))+1}function og(e,t){const n=ve(e,t?.in),r=+Ns(n)-+Z$(n);return Math.round(r/k_)+1}function ag(e,t){const n=ve(e,t?.in),r=n.getFullYear(),i=wa(),o=t?.firstWeekContainsDate??t?.locale?.options?.firstWeekContainsDate??i.firstWeekContainsDate??i.locale?.options?.firstWeekContainsDate??1,a=Qe(t?.in||e,0);a.setFullYear(r+1,0,o),a.setHours(0,0,0,0);const s=eo(a,t),l=Qe(t?.in||e,0);l.setFullYear(r,0,o),l.setHours(0,0,0,0);const c=eo(l,t);return+n>=+s?r+1:+n>=+c?r:r-1}function I5(e,t){const n=wa(),r=t?.firstWeekContainsDate??t?.locale?.options?.firstWeekContainsDate??n.firstWeekContainsDate??n.locale?.options?.firstWeekContainsDate??1,i=ag(e,t),o=Qe(t?.in||e,0);return o.setFullYear(i,0,r),o.setHours(0,0,0,0),eo(o,t)}function $_(e,t){const n=ve(e,t?.in),r=+eo(n,t)-+I5(n,t);return Math.round(r/k_)+1}function Ze(e,t){const n=e<0?"-":"",r=Math.abs(e).toString().padStart(t,"0");return n+r}const Ho={y(e,t){const n=e.getFullYear(),r=n>0?n:1-n;return Ze(t==="yy"?r%100:r,t.length)},M(e,t){const n=e.getMonth();return t==="M"?String(n+1):Ze(n+1,2)},d(e,t){return Ze(e.getDate(),t.length)},a(e,t){const n=e.getHours()/12>=1?"pm":"am";switch(t){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(e,t){return Ze(e.getHours()%12||12,t.length)},H(e,t){return Ze(e.getHours(),t.length)},m(e,t){return Ze(e.getMinutes(),t.length)},s(e,t){return Ze(e.getSeconds(),t.length)},S(e,t){const n=t.length,r=e.getMilliseconds(),i=Math.trunc(r*Math.pow(10,n-3));return Ze(i,t.length)}},Is={midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},B_={G:function(e,t,n){const r=e.getFullYear()>0?1:0;switch(t){case"G":case"GG":case"GGG":return n.era(r,{width:"abbreviated"});case"GGGGG":return n.era(r,{width:"narrow"});case"GGGG":default:return n.era(r,{width:"wide"})}},y:function(e,t,n){if(t==="yo"){const r=e.getFullYear(),i=r>0?r:1-r;return n.ordinalNumber(i,{unit:"year"})}return Ho.y(e,t)},Y:function(e,t,n,r){const i=ag(e,r),o=i>0?i:1-i;if(t==="YY"){const a=o%100;return Ze(a,2)}return t==="Yo"?n.ordinalNumber(o,{unit:"year"}):Ze(o,t.length)},R:function(e,t){const n=A_(e);return Ze(n,t.length)},u:function(e,t){const n=e.getFullYear();return Ze(n,t.length)},Q:function(e,t,n){const r=Math.ceil((e.getMonth()+1)/3);switch(t){case"Q":return String(r);case"QQ":return Ze(r,2);case"Qo":return n.ordinalNumber(r,{unit:"quarter"});case"QQQ":return n.quarter(r,{width:"abbreviated",context:"formatting"});case"QQQQQ":return n.quarter(r,{width:"narrow",context:"formatting"});case"QQQQ":default:return n.quarter(r,{width:"wide",context:"formatting"})}},q:function(e,t,n){const r=Math.ceil((e.getMonth()+1)/3);switch(t){case"q":return String(r);case"qq":return Ze(r,2);case"qo":return n.ordinalNumber(r,{unit:"quarter"});case"qqq":return n.quarter(r,{width:"abbreviated",context:"standalone"});case"qqqqq":return n.quarter(r,{width:"narrow",context:"standalone"});case"qqqq":default:return n.quarter(r,{width:"wide",context:"standalone"})}},M:function(e,t,n){const r=e.getMonth();switch(t){case"M":case"MM":return Ho.M(e,t);case"Mo":return n.ordinalNumber(r+1,{unit:"month"});case"MMM":return n.month(r,{width:"abbreviated",context:"formatting"});case"MMMMM":return n.month(r,{width:"narrow",context:"formatting"});case"MMMM":default:return n.month(r,{width:"wide",context:"formatting"})}},L:function(e,t,n){const r=e.getMonth();switch(t){case"L":return String(r+1);case"LL":return Ze(r+1,2);case"Lo":return n.ordinalNumber(r+1,{unit:"month"});case"LLL":return n.month(r,{width:"abbreviated",context:"standalone"});case"LLLLL":return n.month(r,{width:"narrow",context:"standalone"});case"LLLL":default:return n.month(r,{width:"wide",context:"standalone"})}},w:function(e,t,n,r){const i=$_(e,r);return t==="wo"?n.ordinalNumber(i,{unit:"week"}):Ze(i,t.length)},I:function(e,t,n){const r=og(e);return t==="Io"?n.ordinalNumber(r,{unit:"week"}):Ze(r,t.length)},d:function(e,t,n){return t==="do"?n.ordinalNumber(e.getDate(),{unit:"date"}):Ho.d(e,t)},D:function(e,t,n){const r=M5(e);return t==="Do"?n.ordinalNumber(r,{unit:"dayOfYear"}):Ze(r,t.length)},E:function(e,t,n){const r=e.getDay();switch(t){case"E":case"EE":case"EEE":return n.day(r,{width:"abbreviated",context:"formatting"});case"EEEEE":return n.day(r,{width:"narrow",context:"formatting"});case"EEEEEE":return n.day(r,{width:"short",context:"formatting"});case"EEEE":default:return n.day(r,{width:"wide",context:"formatting"})}},e:function(e,t,n,r){const i=e.getDay(),o=(i-r.weekStartsOn+8)%7||7;switch(t){case"e":return String(o);case"ee":return Ze(o,2);case"eo":return n.ordinalNumber(o,{unit:"day"});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"})}},c:function(e,t,n,r){const i=e.getDay(),o=(i-r.weekStartsOn+8)%7||7;switch(t){case"c":return String(o);case"cc":return Ze(o,t.length);case"co":return n.ordinalNumber(o,{unit:"day"});case"ccc":return n.day(i,{width:"abbreviated",context:"standalone"});case"ccccc":return n.day(i,{width:"narrow",context:"standalone"});case"cccccc":return n.day(i,{width:"short",context:"standalone"});case"cccc":default:return n.day(i,{width:"wide",context:"standalone"})}},i:function(e,t,n){const r=e.getDay(),i=r===0?7:r;switch(t){case"i":return String(i);case"ii":return Ze(i,t.length);case"io":return n.ordinalNumber(i,{unit:"day"});case"iii":return n.day(r,{width:"abbreviated",context:"formatting"});case"iiiii":return n.day(r,{width:"narrow",context:"formatting"});case"iiiiii":return n.day(r,{width:"short",context:"formatting"});case"iiii":default:return n.day(r,{width:"wide",context:"formatting"})}},a:function(e,t,n){const i=e.getHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return n.dayPeriod(i,{width:"abbreviated",context:"formatting"});case"aaa":return n.dayPeriod(i,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return n.dayPeriod(i,{width:"narrow",context:"formatting"});case"aaaa":default:return n.dayPeriod(i,{width:"wide",context:"formatting"})}},b:function(e,t,n){const r=e.getHours();let i;switch(r===12?i=Is.noon:r===0?i=Is.midnight:i=r/12>=1?"pm":"am",t){case"b":case"bb":return n.dayPeriod(i,{width:"abbreviated",context:"formatting"});case"bbb":return n.dayPeriod(i,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return n.dayPeriod(i,{width:"narrow",context:"formatting"});case"bbbb":default:return n.dayPeriod(i,{width:"wide",context:"formatting"})}},B:function(e,t,n){const r=e.getHours();let i;switch(r>=17?i=Is.evening:r>=12?i=Is.afternoon:r>=4?i=Is.morning:i=Is.night,t){case"B":case"BB":case"BBB":return n.dayPeriod(i,{width:"abbreviated",context:"formatting"});case"BBBBB":return n.dayPeriod(i,{width:"narrow",context:"formatting"});case"BBBB":default:return n.dayPeriod(i,{width:"wide",context:"formatting"})}},h:function(e,t,n){if(t==="ho"){let r=e.getHours()%12;return r===0&&(r=12),n.ordinalNumber(r,{unit:"hour"})}return Ho.h(e,t)},H:function(e,t,n){return t==="Ho"?n.ordinalNumber(e.getHours(),{unit:"hour"}):Ho.H(e,t)},K:function(e,t,n){const r=e.getHours()%12;return t==="Ko"?n.ordinalNumber(r,{unit:"hour"}):Ze(r,t.length)},k:function(e,t,n){let r=e.getHours();return r===0&&(r=24),t==="ko"?n.ordinalNumber(r,{unit:"hour"}):Ze(r,t.length)},m:function(e,t,n){return t==="mo"?n.ordinalNumber(e.getMinutes(),{unit:"minute"}):Ho.m(e,t)},s:function(e,t,n){return t==="so"?n.ordinalNumber(e.getSeconds(),{unit:"second"}):Ho.s(e,t)},S:function(e,t){return Ho.S(e,t)},X:function(e,t,n){const r=e.getTimezoneOffset();if(r===0)return"Z";switch(t){case"X":return z_(r);case"XXXX":case"XX":return Ea(r);case"XXXXX":case"XXX":default:return Ea(r,":")}},x:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"x":return z_(r);case"xxxx":case"xx":return Ea(r);case"xxxxx":case"xxx":default:return Ea(r,":")}},O:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"O":case"OO":case"OOO":return"GMT"+W_(r,":");case"OOOO":default:return"GMT"+Ea(r,":")}},z:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"z":case"zz":case"zzz":return"GMT"+W_(r,":");case"zzzz":default:return"GMT"+Ea(r,":")}},t:function(e,t,n){const r=Math.trunc(+e/1e3);return Ze(r,t.length)},T:function(e,t,n){return Ze(+e,t.length)}};function W_(e,t=""){const n=e>0?"-":"+",r=Math.abs(e),i=Math.trunc(r/60),o=r%60;return o===0?n+String(i):n+String(i)+t+Ze(o,2)}function z_(e,t){return e%60===0?(e>0?"-":"+")+Ze(Math.abs(e)/60,2):Ea(e,t)}function Ea(e,t=""){const n=e>0?"-":"+",r=Math.abs(e),i=Ze(Math.trunc(r/60),2),o=Ze(r%60,2);return n+i+t+o}const V_=(e,t)=>{switch(e){case"P":return t.date({width:"short"});case"PP":return t.date({width:"medium"});case"PPP":return t.date({width:"long"});case"PPPP":default:return t.date({width:"full"})}},H_=(e,t)=>{switch(e){case"p":return t.time({width:"short"});case"pp":return t.time({width:"medium"});case"ppp":return t.time({width:"long"});case"pppp":default:return t.time({width:"full"})}},sg={p:H_,P:(e,t)=>{const n=e.match(/(P+)(p+)?/)||[],r=n[1],i=n[2];if(!i)return V_(e,t);let o;switch(r){case"P":o=t.dateTime({width:"short"});break;case"PP":o=t.dateTime({width:"medium"});break;case"PPP":o=t.dateTime({width:"long"});break;case"PPPP":default:o=t.dateTime({width:"full"});break}return o.replace("{{date}}",V_(r,t)).replace("{{time}}",H_(i,t))}},F5=/^D+$/,L5=/^Y+$/,R5=["D","DD","YY","YYYY"];function $5(e){return F5.test(e)}function B5(e){return L5.test(e)}function W5(e,t,n){const r=z5(e,t,n);if(console.warn(r),R5.includes(e))throw new RangeError(r)}function z5(e,t,n){const r=e[0]==="Y"?"years":"days of the month";return`Use \`${e.toLowerCase()}\` instead of \`${e}\` (in \`${t}\`) for formatting ${r} to the input \`${n}\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`}const V5=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,H5=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,Y5=/^'([^]*?)'?$/,U5=/''/g,K5=/[a-zA-Z]/;function Y_(e,t,n){const r=wa(),i=n?.locale??r.locale??R_,o=n?.firstWeekContainsDate??n?.locale?.options?.firstWeekContainsDate??r.firstWeekContainsDate??r.locale?.options?.firstWeekContainsDate??1,a=n?.weekStartsOn??n?.locale?.options?.weekStartsOn??r.weekStartsOn??r.locale?.options?.weekStartsOn??0,s=ve(e,n?.in);if(!Ms(s))throw new RangeError("Invalid time value");let l=t.match(H5).map(u=>{const d=u[0];if(d==="p"||d==="P"){const f=sg[d];return f(u,i.formatLong)}return u}).join("").match(V5).map(u=>{if(u==="''")return{isToken:!1,value:"'"};const d=u[0];if(d==="'")return{isToken:!1,value:q5(u)};if(B_[d])return{isToken:!0,value:u};if(d.match(K5))throw new RangeError("Format string contains an unescaped latin alphabet character `"+d+"`");return{isToken:!1,value:u}});i.localize.preprocessor&&(l=i.localize.preprocessor(s,l));const c={firstWeekContainsDate:o,weekStartsOn:a,locale:i};return l.map(u=>{if(!u.isToken)return u.value;const d=u.value;(!n?.useAdditionalWeekYearTokens&&B5(d)||!n?.useAdditionalDayOfYearTokens&&$5(d))&&W5(d,t,String(e));const f=B_[d[0]];return f(s,d,i.localize,c)}).join("")}function q5(e){const t=e.match(Y5);return t?t[1].replace(U5,"'"):e}function U_(e,t){return ve(e,t?.in).getDate()}function G5(e,t){return ve(e,t?.in).getDay()}function X5(e,t){const n=ve(e,t?.in),r=n.getFullYear(),i=n.getMonth(),o=Qe(n,0);return o.setFullYear(r,i+1,0),o.setHours(0,0,0,0),o.getDate()}function Q5(){return Object.assign({},wa())}function An(e,t){return ve(e,t?.in).getHours()}function Z5(e,t){const n=ve(e,t?.in).getDay();return n===0?7:n}function Tn(e,t){return ve(e,t?.in).getMinutes()}function Jn(e,t){return ve(e,t?.in).getMonth()}function Yo(e){return ve(e).getSeconds()}function lg(e){return+ve(e)}function Ce(e,t){return ve(e,t?.in).getFullYear()}function no(e,t){return+ve(e)>+ve(t)}function bi(e,t){return+ve(e)<+ve(t)}function J5(e,t){return+ve(e)==+ve(t)}function eB(e,t){const n=tB(t)?new t(0):Qe(t,0);return n.setFullYear(e.getFullYear(),e.getMonth(),e.getDate()),n.setHours(e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()),n}function tB(e){return typeof e=="function"&&e.prototype?.constructor===e}const nB=10;class K_{subPriority=0;validate(t,n){return!0}}class rB extends K_{constructor(t,n,r,i,o){super(),this.value=t,this.validateValue=n,this.setValue=r,this.priority=i,o&&(this.subPriority=o)}validate(t,n){return this.validateValue(t,this.value,n)}set(t,n,r){return this.setValue(t,n,this.value,r)}}class iB extends K_{priority=nB;subPriority=-1;constructor(t,n){super(),this.context=t||(r=>Qe(n,r))}set(t,n){return n.timestampIsSet?t:Qe(t,eB(t,this.context))}}class We{run(t,n,r,i){const o=this.parse(t,n,r,i);return o?{setter:new rB(o.value,this.validate,this.set,this.priority,this.subPriority),rest:o.rest}:null}validate(t,n,r){return!0}}class oB extends We{priority=140;parse(t,n,r){switch(n){case"G":case"GG":case"GGG":return r.era(t,{width:"abbreviated"})||r.era(t,{width:"narrow"});case"GGGGG":return r.era(t,{width:"narrow"});case"GGGG":default:return r.era(t,{width:"wide"})||r.era(t,{width:"abbreviated"})||r.era(t,{width:"narrow"})}}set(t,n,r){return n.era=r,t.setFullYear(r,0,1),t.setHours(0,0,0,0),t}incompatibleTokens=["R","u","t","T"]}const Rt={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}/},xi={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 $t(e,t){return e&&{value:t(e.value),rest:e.rest}}function At(e,t){const n=t.match(e);return n?{value:parseInt(n[0],10),rest:t.slice(n[0].length)}:null}function wi(e,t){const n=t.match(e);if(!n)return null;if(n[0]==="Z")return{value:0,rest:t.slice(1)};const r=n[1]==="+"?1:-1,i=n[2]?parseInt(n[2],10):0,o=n[3]?parseInt(n[3],10):0,a=n[5]?parseInt(n[5],10):0;return{value:r*(i*$d+o*Rd+a*G$),rest:t.slice(n[0].length)}}function q_(e){return At(Rt.anyDigitsSigned,e)}function Mt(e,t){switch(e){case 1:return At(Rt.singleDigit,t);case 2:return At(Rt.twoDigits,t);case 3:return At(Rt.threeDigits,t);case 4:return At(Rt.fourDigits,t);default:return At(new RegExp("^\\d{1,"+e+"}"),t)}}function Ud(e,t){switch(e){case 1:return At(Rt.singleDigitSigned,t);case 2:return At(Rt.twoDigitsSigned,t);case 3:return At(Rt.threeDigitsSigned,t);case 4:return At(Rt.fourDigitsSigned,t);default:return At(new RegExp("^-?\\d{1,"+e+"}"),t)}}function cg(e){switch(e){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 G_(e,t){const n=t>0,r=n?t:1-t;let i;if(r<=50)i=e||100;else{const o=r+50,a=Math.trunc(o/100)*100,s=e>=o%100;i=e+a-(s?100:0)}return n?i:1-i}function X_(e){return e%400===0||e%4===0&&e%100!==0}class aB extends We{priority=130;incompatibleTokens=["Y","R","u","w","I","i","e","c","t","T"];parse(t,n,r){const i=o=>({year:o,isTwoDigitYear:n==="yy"});switch(n){case"y":return $t(Mt(4,t),i);case"yo":return $t(r.ordinalNumber(t,{unit:"year"}),i);default:return $t(Mt(n.length,t),i)}}validate(t,n){return n.isTwoDigitYear||n.year>0}set(t,n,r){const i=t.getFullYear();if(r.isTwoDigitYear){const a=G_(r.year,i);return t.setFullYear(a,0,1),t.setHours(0,0,0,0),t}const o=!("era"in n)||n.era===1?r.year:1-r.year;return t.setFullYear(o,0,1),t.setHours(0,0,0,0),t}}class sB extends We{priority=130;parse(t,n,r){const i=o=>({year:o,isTwoDigitYear:n==="YY"});switch(n){case"Y":return $t(Mt(4,t),i);case"Yo":return $t(r.ordinalNumber(t,{unit:"year"}),i);default:return $t(Mt(n.length,t),i)}}validate(t,n){return n.isTwoDigitYear||n.year>0}set(t,n,r,i){const o=ag(t,i);if(r.isTwoDigitYear){const s=G_(r.year,o);return t.setFullYear(s,0,i.firstWeekContainsDate),t.setHours(0,0,0,0),eo(t,i)}const a=!("era"in n)||n.era===1?r.year:1-r.year;return t.setFullYear(a,0,i.firstWeekContainsDate),t.setHours(0,0,0,0),eo(t,i)}incompatibleTokens=["y","R","u","Q","q","M","L","I","d","D","i","t","T"]}class lB extends We{priority=130;parse(t,n){return Ud(n==="R"?4:n.length,t)}set(t,n,r){const i=Qe(t,0);return i.setFullYear(r,0,4),i.setHours(0,0,0,0),Ns(i)}incompatibleTokens=["G","y","Y","u","Q","q","M","L","w","d","D","e","c","t","T"]}class cB extends We{priority=130;parse(t,n){return Ud(n==="u"?4:n.length,t)}set(t,n,r){return t.setFullYear(r,0,1),t.setHours(0,0,0,0),t}incompatibleTokens=["G","y","Y","R","w","I","i","e","c","t","T"]}class uB extends We{priority=120;parse(t,n,r){switch(n){case"Q":case"QQ":return Mt(n.length,t);case"Qo":return r.ordinalNumber(t,{unit:"quarter"});case"QQQ":return r.quarter(t,{width:"abbreviated",context:"formatting"})||r.quarter(t,{width:"narrow",context:"formatting"});case"QQQQQ":return r.quarter(t,{width:"narrow",context:"formatting"});case"QQQQ":default:return r.quarter(t,{width:"wide",context:"formatting"})||r.quarter(t,{width:"abbreviated",context:"formatting"})||r.quarter(t,{width:"narrow",context:"formatting"})}}validate(t,n){return n>=1&&n<=4}set(t,n,r){return t.setMonth((r-1)*3,1),t.setHours(0,0,0,0),t}incompatibleTokens=["Y","R","q","M","L","w","I","d","D","i","e","c","t","T"]}class dB extends We{priority=120;parse(t,n,r){switch(n){case"q":case"qq":return Mt(n.length,t);case"qo":return r.ordinalNumber(t,{unit:"quarter"});case"qqq":return r.quarter(t,{width:"abbreviated",context:"standalone"})||r.quarter(t,{width:"narrow",context:"standalone"});case"qqqqq":return r.quarter(t,{width:"narrow",context:"standalone"});case"qqqq":default:return r.quarter(t,{width:"wide",context:"standalone"})||r.quarter(t,{width:"abbreviated",context:"standalone"})||r.quarter(t,{width:"narrow",context:"standalone"})}}validate(t,n){return n>=1&&n<=4}set(t,n,r){return t.setMonth((r-1)*3,1),t.setHours(0,0,0,0),t}incompatibleTokens=["Y","R","Q","M","L","w","I","d","D","i","e","c","t","T"]}class fB extends We{incompatibleTokens=["Y","R","q","Q","L","w","I","D","i","e","c","t","T"];priority=110;parse(t,n,r){const i=o=>o-1;switch(n){case"M":return $t(At(Rt.month,t),i);case"MM":return $t(Mt(2,t),i);case"Mo":return $t(r.ordinalNumber(t,{unit:"month"}),i);case"MMM":return r.month(t,{width:"abbreviated",context:"formatting"})||r.month(t,{width:"narrow",context:"formatting"});case"MMMMM":return r.month(t,{width:"narrow",context:"formatting"});case"MMMM":default:return r.month(t,{width:"wide",context:"formatting"})||r.month(t,{width:"abbreviated",context:"formatting"})||r.month(t,{width:"narrow",context:"formatting"})}}validate(t,n){return n>=0&&n<=11}set(t,n,r){return t.setMonth(r,1),t.setHours(0,0,0,0),t}}class pB extends We{priority=110;parse(t,n,r){const i=o=>o-1;switch(n){case"L":return $t(At(Rt.month,t),i);case"LL":return $t(Mt(2,t),i);case"Lo":return $t(r.ordinalNumber(t,{unit:"month"}),i);case"LLL":return r.month(t,{width:"abbreviated",context:"standalone"})||r.month(t,{width:"narrow",context:"standalone"});case"LLLLL":return r.month(t,{width:"narrow",context:"standalone"});case"LLLL":default:return r.month(t,{width:"wide",context:"standalone"})||r.month(t,{width:"abbreviated",context:"standalone"})||r.month(t,{width:"narrow",context:"standalone"})}}validate(t,n){return n>=0&&n<=11}set(t,n,r){return t.setMonth(r,1),t.setHours(0,0,0,0),t}incompatibleTokens=["Y","R","q","Q","M","w","I","D","i","e","c","t","T"]}function hB(e,t,n){const r=ve(e,n?.in),i=$_(r,n)-t;return r.setDate(r.getDate()-i*7),ve(r,n?.in)}class mB extends We{priority=100;parse(t,n,r){switch(n){case"w":return At(Rt.week,t);case"wo":return r.ordinalNumber(t,{unit:"week"});default:return Mt(n.length,t)}}validate(t,n){return n>=1&&n<=53}set(t,n,r,i){return eo(hB(t,r,i),i)}incompatibleTokens=["y","R","u","q","Q","M","L","I","d","D","i","t","T"]}function gB(e,t,n){const r=ve(e,n?.in),i=og(r,n)-t;return r.setDate(r.getDate()-i*7),r}class vB extends We{priority=100;parse(t,n,r){switch(n){case"I":return At(Rt.week,t);case"Io":return r.ordinalNumber(t,{unit:"week"});default:return Mt(n.length,t)}}validate(t,n){return n>=1&&n<=53}set(t,n,r){return Ns(gB(t,r))}incompatibleTokens=["y","Y","u","q","Q","M","L","w","d","D","e","c","t","T"]}const yB=[31,28,31,30,31,30,31,31,30,31,30,31],bB=[31,29,31,30,31,30,31,31,30,31,30,31];class xB extends We{priority=90;subPriority=1;parse(t,n,r){switch(n){case"d":return At(Rt.date,t);case"do":return r.ordinalNumber(t,{unit:"date"});default:return Mt(n.length,t)}}validate(t,n){const r=t.getFullYear(),i=X_(r),o=t.getMonth();return i?n>=1&&n<=bB[o]:n>=1&&n<=yB[o]}set(t,n,r){return t.setDate(r),t.setHours(0,0,0,0),t}incompatibleTokens=["Y","R","q","Q","w","I","D","i","e","c","t","T"]}class wB extends We{priority=90;subpriority=1;parse(t,n,r){switch(n){case"D":case"DD":return At(Rt.dayOfYear,t);case"Do":return r.ordinalNumber(t,{unit:"date"});default:return Mt(n.length,t)}}validate(t,n){const r=t.getFullYear();return X_(r)?n>=1&&n<=366:n>=1&&n<=365}set(t,n,r){return t.setMonth(0,r),t.setHours(0,0,0,0),t}incompatibleTokens=["Y","R","q","Q","M","L","w","I","d","E","i","e","c","t","T"]}function ug(e,t,n){const r=wa(),i=n?.weekStartsOn??n?.locale?.options?.weekStartsOn??r.weekStartsOn??r.locale?.options?.weekStartsOn??0,o=ve(e,n?.in),a=o.getDay(),l=(t%7+7)%7,c=7-i,u=t<0||t>6?t-(a+c)%7:(l+c)%7-(a+c)%7;return ei(o,u,n)}class _B extends We{priority=90;parse(t,n,r){switch(n){case"E":case"EE":case"EEE":return r.day(t,{width:"abbreviated",context:"formatting"})||r.day(t,{width:"short",context:"formatting"})||r.day(t,{width:"narrow",context:"formatting"});case"EEEEE":return r.day(t,{width:"narrow",context:"formatting"});case"EEEEEE":return r.day(t,{width:"short",context:"formatting"})||r.day(t,{width:"narrow",context:"formatting"});case"EEEE":default:return r.day(t,{width:"wide",context:"formatting"})||r.day(t,{width:"abbreviated",context:"formatting"})||r.day(t,{width:"short",context:"formatting"})||r.day(t,{width:"narrow",context:"formatting"})}}validate(t,n){return n>=0&&n<=6}set(t,n,r,i){return t=ug(t,r,i),t.setHours(0,0,0,0),t}incompatibleTokens=["D","i","e","c","t","T"]}class EB extends We{priority=90;parse(t,n,r,i){const o=a=>{const s=Math.floor((a-1)/7)*7;return(a+i.weekStartsOn+6)%7+s};switch(n){case"e":case"ee":return $t(Mt(n.length,t),o);case"eo":return $t(r.ordinalNumber(t,{unit:"day"}),o);case"eee":return r.day(t,{width:"abbreviated",context:"formatting"})||r.day(t,{width:"short",context:"formatting"})||r.day(t,{width:"narrow",context:"formatting"});case"eeeee":return r.day(t,{width:"narrow",context:"formatting"});case"eeeeee":return r.day(t,{width:"short",context:"formatting"})||r.day(t,{width:"narrow",context:"formatting"});case"eeee":default:return r.day(t,{width:"wide",context:"formatting"})||r.day(t,{width:"abbreviated",context:"formatting"})||r.day(t,{width:"short",context:"formatting"})||r.day(t,{width:"narrow",context:"formatting"})}}validate(t,n){return n>=0&&n<=6}set(t,n,r,i){return t=ug(t,r,i),t.setHours(0,0,0,0),t}incompatibleTokens=["y","R","u","q","Q","M","L","I","d","D","E","i","c","t","T"]}class SB extends We{priority=90;parse(t,n,r,i){const o=a=>{const s=Math.floor((a-1)/7)*7;return(a+i.weekStartsOn+6)%7+s};switch(n){case"c":case"cc":return $t(Mt(n.length,t),o);case"co":return $t(r.ordinalNumber(t,{unit:"day"}),o);case"ccc":return r.day(t,{width:"abbreviated",context:"standalone"})||r.day(t,{width:"short",context:"standalone"})||r.day(t,{width:"narrow",context:"standalone"});case"ccccc":return r.day(t,{width:"narrow",context:"standalone"});case"cccccc":return r.day(t,{width:"short",context:"standalone"})||r.day(t,{width:"narrow",context:"standalone"});case"cccc":default:return r.day(t,{width:"wide",context:"standalone"})||r.day(t,{width:"abbreviated",context:"standalone"})||r.day(t,{width:"short",context:"standalone"})||r.day(t,{width:"narrow",context:"standalone"})}}validate(t,n){return n>=0&&n<=6}set(t,n,r,i){return t=ug(t,r,i),t.setHours(0,0,0,0),t}incompatibleTokens=["y","R","u","q","Q","M","L","I","d","D","E","i","e","t","T"]}function OB(e,t,n){const r=ve(e,n?.in),i=Z5(r,n),o=t-i;return ei(r,o,n)}class CB extends We{priority=90;parse(t,n,r){const i=o=>o===0?7:o;switch(n){case"i":case"ii":return Mt(n.length,t);case"io":return r.ordinalNumber(t,{unit:"day"});case"iii":return $t(r.day(t,{width:"abbreviated",context:"formatting"})||r.day(t,{width:"short",context:"formatting"})||r.day(t,{width:"narrow",context:"formatting"}),i);case"iiiii":return $t(r.day(t,{width:"narrow",context:"formatting"}),i);case"iiiiii":return $t(r.day(t,{width:"short",context:"formatting"})||r.day(t,{width:"narrow",context:"formatting"}),i);case"iiii":default:return $t(r.day(t,{width:"wide",context:"formatting"})||r.day(t,{width:"abbreviated",context:"formatting"})||r.day(t,{width:"short",context:"formatting"})||r.day(t,{width:"narrow",context:"formatting"}),i)}}validate(t,n){return n>=1&&n<=7}set(t,n,r){return t=OB(t,r),t.setHours(0,0,0,0),t}incompatibleTokens=["y","Y","u","q","Q","M","L","w","d","D","E","e","c","t","T"]}class kB extends We{priority=80;parse(t,n,r){switch(n){case"a":case"aa":case"aaa":return r.dayPeriod(t,{width:"abbreviated",context:"formatting"})||r.dayPeriod(t,{width:"narrow",context:"formatting"});case"aaaaa":return r.dayPeriod(t,{width:"narrow",context:"formatting"});case"aaaa":default:return r.dayPeriod(t,{width:"wide",context:"formatting"})||r.dayPeriod(t,{width:"abbreviated",context:"formatting"})||r.dayPeriod(t,{width:"narrow",context:"formatting"})}}set(t,n,r){return t.setHours(cg(r),0,0,0),t}incompatibleTokens=["b","B","H","k","t","T"]}class PB extends We{priority=80;parse(t,n,r){switch(n){case"b":case"bb":case"bbb":return r.dayPeriod(t,{width:"abbreviated",context:"formatting"})||r.dayPeriod(t,{width:"narrow",context:"formatting"});case"bbbbb":return r.dayPeriod(t,{width:"narrow",context:"formatting"});case"bbbb":default:return r.dayPeriod(t,{width:"wide",context:"formatting"})||r.dayPeriod(t,{width:"abbreviated",context:"formatting"})||r.dayPeriod(t,{width:"narrow",context:"formatting"})}}set(t,n,r){return t.setHours(cg(r),0,0,0),t}incompatibleTokens=["a","B","H","k","t","T"]}class DB extends We{priority=80;parse(t,n,r){switch(n){case"B":case"BB":case"BBB":return r.dayPeriod(t,{width:"abbreviated",context:"formatting"})||r.dayPeriod(t,{width:"narrow",context:"formatting"});case"BBBBB":return r.dayPeriod(t,{width:"narrow",context:"formatting"});case"BBBB":default:return r.dayPeriod(t,{width:"wide",context:"formatting"})||r.dayPeriod(t,{width:"abbreviated",context:"formatting"})||r.dayPeriod(t,{width:"narrow",context:"formatting"})}}set(t,n,r){return t.setHours(cg(r),0,0,0),t}incompatibleTokens=["a","b","t","T"]}class AB extends We{priority=70;parse(t,n,r){switch(n){case"h":return At(Rt.hour12h,t);case"ho":return r.ordinalNumber(t,{unit:"hour"});default:return Mt(n.length,t)}}validate(t,n){return n>=1&&n<=12}set(t,n,r){const i=t.getHours()>=12;return i&&r<12?t.setHours(r+12,0,0,0):!i&&r===12?t.setHours(0,0,0,0):t.setHours(r,0,0,0),t}incompatibleTokens=["H","K","k","t","T"]}class TB extends We{priority=70;parse(t,n,r){switch(n){case"H":return At(Rt.hour23h,t);case"Ho":return r.ordinalNumber(t,{unit:"hour"});default:return Mt(n.length,t)}}validate(t,n){return n>=0&&n<=23}set(t,n,r){return t.setHours(r,0,0,0),t}incompatibleTokens=["a","b","h","K","k","t","T"]}class NB extends We{priority=70;parse(t,n,r){switch(n){case"K":return At(Rt.hour11h,t);case"Ko":return r.ordinalNumber(t,{unit:"hour"});default:return Mt(n.length,t)}}validate(t,n){return n>=0&&n<=11}set(t,n,r){return t.getHours()>=12&&r<12?t.setHours(r+12,0,0,0):t.setHours(r,0,0,0),t}incompatibleTokens=["h","H","k","t","T"]}class jB extends We{priority=70;parse(t,n,r){switch(n){case"k":return At(Rt.hour24h,t);case"ko":return r.ordinalNumber(t,{unit:"hour"});default:return Mt(n.length,t)}}validate(t,n){return n>=1&&n<=24}set(t,n,r){const i=r<=24?r%24:r;return t.setHours(i,0,0,0),t}incompatibleTokens=["a","b","h","H","K","t","T"]}class MB extends We{priority=60;parse(t,n,r){switch(n){case"m":return At(Rt.minute,t);case"mo":return r.ordinalNumber(t,{unit:"minute"});default:return Mt(n.length,t)}}validate(t,n){return n>=0&&n<=59}set(t,n,r){return t.setMinutes(r,0,0),t}incompatibleTokens=["t","T"]}class IB extends We{priority=50;parse(t,n,r){switch(n){case"s":return At(Rt.second,t);case"so":return r.ordinalNumber(t,{unit:"second"});default:return Mt(n.length,t)}}validate(t,n){return n>=0&&n<=59}set(t,n,r){return t.setSeconds(r,0),t}incompatibleTokens=["t","T"]}class FB extends We{priority=30;parse(t,n){const r=i=>Math.trunc(i*Math.pow(10,-n.length+3));return $t(Mt(n.length,t),r)}set(t,n,r){return t.setMilliseconds(r),t}incompatibleTokens=["t","T"]}class LB extends We{priority=10;parse(t,n){switch(n){case"X":return wi(xi.basicOptionalMinutes,t);case"XX":return wi(xi.basic,t);case"XXXX":return wi(xi.basicOptionalSeconds,t);case"XXXXX":return wi(xi.extendedOptionalSeconds,t);case"XXX":default:return wi(xi.extended,t)}}set(t,n,r){return n.timestampIsSet?t:Qe(t,t.getTime()-Bd(t)-r)}incompatibleTokens=["t","T","x"]}class RB extends We{priority=10;parse(t,n){switch(n){case"x":return wi(xi.basicOptionalMinutes,t);case"xx":return wi(xi.basic,t);case"xxxx":return wi(xi.basicOptionalSeconds,t);case"xxxxx":return wi(xi.extendedOptionalSeconds,t);case"xxx":default:return wi(xi.extended,t)}}set(t,n,r){return n.timestampIsSet?t:Qe(t,t.getTime()-Bd(t)-r)}incompatibleTokens=["t","T","X"]}class $B extends We{priority=40;parse(t){return q_(t)}set(t,n,r){return[Qe(t,r*1e3),{timestampIsSet:!0}]}incompatibleTokens="*"}class BB extends We{priority=20;parse(t){return q_(t)}set(t,n,r){return[Qe(t,r),{timestampIsSet:!0}]}incompatibleTokens="*"}const WB={G:new oB,y:new aB,Y:new sB,R:new lB,u:new cB,Q:new uB,q:new dB,M:new fB,L:new pB,w:new mB,I:new vB,d:new xB,D:new wB,E:new _B,e:new EB,c:new SB,i:new CB,a:new kB,b:new PB,B:new DB,h:new AB,H:new TB,K:new NB,k:new jB,m:new MB,s:new IB,S:new FB,X:new LB,x:new RB,t:new $B,T:new BB},zB=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,VB=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,HB=/^'([^]*?)'?$/,YB=/''/g,UB=/\S/,KB=/[a-zA-Z]/;function qB(e,t,n,r){const i=()=>Qe(r?.in||n,NaN),o=Q5(),a=r?.locale??o.locale??R_,s=r?.firstWeekContainsDate??r?.locale?.options?.firstWeekContainsDate??o.firstWeekContainsDate??o.locale?.options?.firstWeekContainsDate??1,l=r?.weekStartsOn??r?.locale?.options?.weekStartsOn??o.weekStartsOn??o.locale?.options?.weekStartsOn??0;if(!t)return e?i():ve(n,r?.in);const c={firstWeekContainsDate:s,weekStartsOn:l,locale:a},u=[new iB(r?.in,n)],d=t.match(VB).map(v=>{const x=v[0];if(x in sg){const _=sg[x];return _(v,a.formatLong)}return v}).join("").match(zB),f=[];for(let v of d){const x=v[0],_=WB[x];if(_){const{incompatibleTokens:w}=_;if(Array.isArray(w)){const E=f.find(S=>w.includes(S.token)||S.token===x);if(E)throw new RangeError(`The format string mustn't contain \`${E.fullToken}\` and \`${v}\` at the same time`)}else if(_.incompatibleTokens==="*"&&f.length>0)throw new RangeError(`The format string mustn't contain \`${v}\` and any other token at the same time`);f.push({token:x,fullToken:v});const y=_.run(e,v,a.match,c);if(!y)return i();u.push(y.setter),e=y.rest}else{if(x.match(KB))throw new RangeError("Format string contains an unescaped latin alphabet character `"+x+"`");if(v==="''"?v="'":x==="'"&&(v=GB(v)),e.indexOf(v)===0)e=e.slice(v.length);else return i()}}if(e.length>0&&UB.test(e))return i();const p=u.map(v=>v.priority).sort((v,x)=>x-v).filter((v,x,_)=>_.indexOf(v)===x).map(v=>u.filter(x=>x.priority===v).sort((x,_)=>_.subPriority-x.subPriority)).map(v=>v[0]);let m=ve(n,r?.in);if(isNaN(+m))return i();const g={};for(const v of p){if(!v.validate(m,c))return i();const x=v.set(m,g,c);Array.isArray(x)?(m=x[0],Object.assign(g,x[1])):m=x}return m}function GB(e){return e.match(HB)[1].replace(YB,"'")}function XB(e,t,n){const[r,i]=to(n?.in,e,t);return r.getFullYear()===i.getFullYear()&&r.getMonth()===i.getMonth()}function QB(e,t,n){const[r,i]=to(n?.in,e,t);return+rg(r)==+rg(i)}function ZB(e,t,n){const[r,i]=to(n?.in,e,t);return r.getFullYear()===i.getFullYear()}function cc(e,t,n){const r=+ve(e,n?.in),[i,o]=[+ve(t.start,n?.in),+ve(t.end,n?.in)].sort((a,s)=>a-s);return r>=i&&r<=o}function JB(e,t,n){return ei(e,-1,n)}function e6(e,t){const n=()=>Qe(t?.in,NaN),i=i6(e);let o;if(i.date){const c=o6(i.date,2);o=a6(c.restDateString,c.year)}if(!o||isNaN(+o))return n();const a=+o;let s=0,l;if(i.time&&(s=s6(i.time),isNaN(s)))return n();if(i.timezone){if(l=l6(i.timezone),isNaN(l))return n()}else{const c=new Date(a+s),u=ve(0,t?.in);return u.setFullYear(c.getUTCFullYear(),c.getUTCMonth(),c.getUTCDate()),u.setHours(c.getUTCHours(),c.getUTCMinutes(),c.getUTCSeconds(),c.getUTCMilliseconds()),u}return ve(a+s+l,t?.in)}const Kd={dateTimeDelimiter:/[T ]/,timeZoneDelimiter:/[Z ]/i,timezone:/([Z+-].*)$/},t6=/^-?(?:(\d{3})|(\d{2})(?:-?(\d{2}))?|W(\d{2})(?:-?(\d{1}))?|)$/,n6=/^(\d{2}(?:[.,]\d*)?)(?::?(\d{2}(?:[.,]\d*)?))?(?::?(\d{2}(?:[.,]\d*)?))?$/,r6=/^([+-])(\d{2})(?::?(\d{2}))?$/;function i6(e){const t={},n=e.split(Kd.dateTimeDelimiter);let r;if(n.length>2)return t;if(/:/.test(n[0])?r=n[0]:(t.date=n[0],r=n[1],Kd.timeZoneDelimiter.test(t.date)&&(t.date=e.split(Kd.timeZoneDelimiter)[0],r=e.substr(t.date.length,e.length))),r){const i=Kd.timezone.exec(r);i?(t.time=r.replace(i[1],""),t.timezone=i[1]):t.time=r}return t}function o6(e,t){const n=new RegExp("^(?:(\\d{4}|[+-]\\d{"+(4+t)+"})|(\\d{2}|[+-]\\d{"+(2+t)+"})$)"),r=e.match(n);if(!r)return{year:NaN,restDateString:""};const i=r[1]?parseInt(r[1]):null,o=r[2]?parseInt(r[2]):null;return{year:o===null?i:o*100,restDateString:e.slice((r[1]||r[2]).length)}}function a6(e,t){if(t===null)return new Date(NaN);const n=e.match(t6);if(!n)return new Date(NaN);const r=!!n[4],i=uc(n[1]),o=uc(n[2])-1,a=uc(n[3]),s=uc(n[4]),l=uc(n[5])-1;if(r)return p6(t,s,l)?c6(t,s,l):new Date(NaN);{const c=new Date(0);return!d6(t,o,a)||!f6(t,i)?new Date(NaN):(c.setUTCFullYear(t,o,Math.max(i,a)),c)}}function uc(e){return e?parseInt(e):1}function s6(e){const t=e.match(n6);if(!t)return NaN;const n=dg(t[1]),r=dg(t[2]),i=dg(t[3]);return h6(n,r,i)?n*$d+r*Rd+i*1e3:NaN}function dg(e){return e&&parseFloat(e.replace(",","."))||0}function l6(e){if(e==="Z")return 0;const t=e.match(r6);if(!t)return 0;const n=t[1]==="+"?-1:1,r=parseInt(t[2]),i=t[3]&&parseInt(t[3])||0;return m6(r,i)?n*(r*$d+i*Rd):NaN}function c6(e,t,n){const r=new Date(0);r.setUTCFullYear(e,0,4);const i=r.getUTCDay()||7,o=(t-1)*7+n+1-i;return r.setUTCDate(r.getUTCDate()+o),r}const u6=[31,null,31,30,31,30,31,31,30,31,30,31];function Q_(e){return e%400===0||e%4===0&&e%100!==0}function d6(e,t,n){return t>=0&&t<=11&&n>=1&&n<=(u6[t]||(Q_(e)?29:28))}function f6(e,t){return t>=1&&t<=(Q_(e)?366:365)}function p6(e,t,n){return t>=1&&t<=53&&n>=0&&n<=6}function h6(e,t,n){return e===24?t===0&&n===0:n>=0&&n<60&&t>=0&&t<60&&e>=0&&e<25}function m6(e,t){return t>=0&&t<=59}function vr(e,t,n){const r=ve(e,n?.in),i=r.getFullYear(),o=r.getDate(),a=Qe(e,0);a.setFullYear(i,t,15),a.setHours(0,0,0,0);const s=X5(a);return r.setMonth(t,Math.min(o,s)),r}function qd(e,t,n){const r=ve(e,n?.in);return r.setHours(t),r}function Gd(e,t,n){const r=ve(e,n?.in);return r.setMinutes(t),r}function Fs(e,t,n){const r=ve(e,n?.in),i=Math.trunc(r.getMonth()/3)+1,o=t-i;return vr(r,r.getMonth()+o*3)}function Xd(e,t,n){const r=ve(e,n?.in);return r.setSeconds(t),r}function _i(e,t,n){const r=ve(e,n?.in);return isNaN(+r)?Qe(e,NaN):(r.setFullYear(t),r)}function Sa(e,t,n){return ti(e,-t,n)}function Z_(e,t,n){return ng(e,-1,n)}function J_(e,t,n){return Wd(e,-1,n)}function Uo(e,t,n){return ni(e,-t,n)}function Qd(){return typeof window<"u"}function Ls(e){return eE(e)?(e.nodeName||"").toLowerCase():"#document"}function yr(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Ei(e){var t;return(t=(eE(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function eE(e){return Qd()?e instanceof Node||e instanceof yr(e).Node:!1}function Nn(e){return Qd()?e instanceof Element||e instanceof yr(e).Element:!1}function Si(e){return Qd()?e instanceof HTMLElement||e instanceof yr(e).HTMLElement:!1}function tE(e){return!Qd()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof yr(e).ShadowRoot}const g6=new Set(["inline","contents"]);function dc(e){const{overflow:t,overflowX:n,overflowY:r,display:i}=jr(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!g6.has(i)}const v6=new Set(["table","td","th"]);function y6(e){return v6.has(Ls(e))}const b6=[":popover-open",":modal"];function Zd(e){return b6.some(t=>{try{return e.matches(t)}catch{return!1}})}const x6=["transform","translate","scale","rotate","perspective"],w6=["transform","translate","scale","rotate","perspective","filter"],_6=["paint","layout","strict","content"];function fg(e){const t=pg(),n=Nn(e)?jr(e):e;return x6.some(r=>n[r]?n[r]!=="none":!1)||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||w6.some(r=>(n.willChange||"").includes(r))||_6.some(r=>(n.contain||"").includes(r))}function E6(e){let t=Ko(e);for(;Si(t)&&!Rs(t);){if(fg(t))return t;if(Zd(t))return null;t=Ko(t)}return null}function pg(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const S6=new Set(["html","body","#document"]);function Rs(e){return S6.has(Ls(e))}function jr(e){return yr(e).getComputedStyle(e)}function Jd(e){return Nn(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Ko(e){if(Ls(e)==="html")return e;const t=e.assignedSlot||e.parentNode||tE(e)&&e.host||Ei(e);return tE(t)?t.host:t}function nE(e){const t=Ko(e);return Rs(t)?e.ownerDocument?e.ownerDocument.body:e.body:Si(t)&&dc(t)?t:nE(t)}function fc(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const i=nE(e),o=i===((r=e.ownerDocument)==null?void 0:r.body),a=yr(i);if(o){const s=hg(a);return t.concat(a,a.visualViewport||[],dc(i)?i:[],s&&n?fc(s):[])}return t.concat(i,fc(i,[],n))}function hg(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}const $s=Math.min,Oa=Math.max,ef=Math.round,tf=Math.floor,Oi=e=>({x:e,y:e}),O6={left:"right",right:"left",bottom:"top",top:"bottom"},C6={start:"end",end:"start"};function k6(e,t,n){return Oa(e,$s(t,n))}function nf(e,t){return typeof e=="function"?e(t):e}function Bs(e){return e.split("-")[0]}function pc(e){return e.split("-")[1]}function P6(e){return e==="x"?"y":"x"}function mg(e){return e==="y"?"height":"width"}const D6=new Set(["top","bottom"]);function Ca(e){return D6.has(Bs(e))?"y":"x"}function gg(e){return P6(Ca(e))}function A6(e,t,n){n===void 0&&(n=!1);const r=pc(e),i=gg(e),o=mg(i);let a=i==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[o]>t.floating[o]&&(a=rf(a)),[a,rf(a)]}function T6(e){const t=rf(e);return[vg(e),t,vg(t)]}function vg(e){return e.replace(/start|end/g,t=>C6[t])}const rE=["left","right"],iE=["right","left"],N6=["top","bottom"],j6=["bottom","top"];function M6(e,t,n){switch(e){case"top":case"bottom":return n?t?iE:rE:t?rE:iE;case"left":case"right":return t?N6:j6;default:return[]}}function I6(e,t,n,r){const i=pc(e);let o=M6(Bs(e),n==="start",r);return i&&(o=o.map(a=>a+"-"+i),t&&(o=o.concat(o.map(vg)))),o}function rf(e){return e.replace(/left|right|bottom|top/g,t=>O6[t])}function F6(e){return{top:0,right:0,bottom:0,left:0,...e}}function oE(e){return typeof e!="number"?F6(e):{top:e,right:e,bottom:e,left:e}}function of(e){const{x:t,y:n,width:r,height:i}=e;return{width:r,height:i,top:n,left:t,right:t+r,bottom:n+i,x:t,y:n}}var L6=typeof document<"u",R6=function(){},af=L6?k.useLayoutEffect:R6;const $6={...O}.useInsertionEffect||(e=>e());function B6(e){const t=O.useRef(()=>{if(process.env.NODE_ENV!=="production")throw new Error("Cannot call an event handler while rendering.")});return $6(()=>{t.current=e}),O.useCallback(function(){for(var n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];return t.current==null?void 0:t.current(...r)},[])}function aE(e,t,n){let{reference:r,floating:i}=e;const o=Ca(t),a=gg(t),s=mg(a),l=Bs(t),c=o==="y",u=r.x+r.width/2-i.width/2,d=r.y+r.height/2-i.height/2,f=r[s]/2-i[s]/2;let p;switch(l){case"top":p={x:u,y:r.y-i.height};break;case"bottom":p={x:u,y:r.y+r.height};break;case"right":p={x:r.x+r.width,y:d};break;case"left":p={x:r.x-i.width,y:d};break;default:p={x:r.x,y:r.y}}switch(pc(t)){case"start":p[a]-=f*(n&&c?-1:1);break;case"end":p[a]+=f*(n&&c?-1:1);break}return p}const W6=async(e,t,n)=>{const{placement:r="bottom",strategy:i="absolute",middleware:o=[],platform:a}=n,s=o.filter(Boolean),l=await(a.isRTL==null?void 0:a.isRTL(t));let c=await a.getElementRects({reference:e,floating:t,strategy:i}),{x:u,y:d}=aE(c,r,l),f=r,p={},m=0;for(let g=0;g<s.length;g++){const{name:v,fn:x}=s[g],{x:_,y:w,data:y,reset:E}=await x({x:u,y:d,initialPlacement:r,placement:f,strategy:i,middlewareData:p,rects:c,platform:a,elements:{reference:e,floating:t}});u=_??u,d=w??d,p={...p,[v]:{...p[v],...y}},E&&m<=50&&(m++,typeof E=="object"&&(E.placement&&(f=E.placement),E.rects&&(c=E.rects===!0?await a.getElementRects({reference:e,floating:t,strategy:i}):E.rects),{x:u,y:d}=aE(c,f,l)),g=-1)}return{x:u,y:d,placement:f,strategy:i,middlewareData:p}};async function z6(e,t){var n;t===void 0&&(t={});const{x:r,y:i,platform:o,rects:a,elements:s,strategy:l}=e,{boundary:c="clippingAncestors",rootBoundary:u="viewport",elementContext:d="floating",altBoundary:f=!1,padding:p=0}=nf(t,e),m=oE(p),v=s[f?d==="floating"?"reference":"floating":d],x=of(await o.getClippingRect({element:(n=await(o.isElement==null?void 0:o.isElement(v)))==null||n?v:v.contextElement||await(o.getDocumentElement==null?void 0:o.getDocumentElement(s.floating)),boundary:c,rootBoundary:u,strategy:l})),_=d==="floating"?{x:r,y:i,width:a.floating.width,height:a.floating.height}:a.reference,w=await(o.getOffsetParent==null?void 0:o.getOffsetParent(s.floating)),y=await(o.isElement==null?void 0:o.isElement(w))?await(o.getScale==null?void 0:o.getScale(w))||{x:1,y:1}:{x:1,y:1},E=of(o.convertOffsetParentRelativeRectToViewportRelativeRect?await o.convertOffsetParentRelativeRectToViewportRelativeRect({elements:s,rect:_,offsetParent:w,strategy:l}):_);return{top:(x.top-E.top+m.top)/y.y,bottom:(E.bottom-x.bottom+m.bottom)/y.y,left:(x.left-E.left+m.left)/y.x,right:(E.right-x.right+m.right)/y.x}}const V6=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:i,rects:o,platform:a,elements:s,middlewareData:l}=t,{element:c,padding:u=0}=nf(e,t)||{};if(c==null)return{};const d=oE(u),f={x:n,y:r},p=gg(i),m=mg(p),g=await a.getDimensions(c),v=p==="y",x=v?"top":"left",_=v?"bottom":"right",w=v?"clientHeight":"clientWidth",y=o.reference[m]+o.reference[p]-f[p]-o.floating[m],E=f[p]-o.reference[p],S=await(a.getOffsetParent==null?void 0:a.getOffsetParent(c));let P=S?S[w]:0;(!P||!await(a.isElement==null?void 0:a.isElement(S)))&&(P=s.floating[w]||o.floating[m]);const D=y/2-E/2,T=P/2-g[m]/2-1,I=$s(d[x],T),A=$s(d[_],T),C=I,j=P-g[m]-A,N=P/2-g[m]/2+D,M=k6(C,N,j),R=!l.arrow&&pc(i)!=null&&N!==M&&o.reference[m]/2-(N<C?I:A)-g[m]/2<0,B=R?N<C?N-C:N-j:0;return{[p]:f[p]+B,data:{[p]:M,centerOffset:N-M-B,...R&&{alignmentOffset:B}},reset:R}}}),H6=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:i,middlewareData:o,rects:a,initialPlacement:s,platform:l,elements:c}=t,{mainAxis:u=!0,crossAxis:d=!0,fallbackPlacements:f,fallbackStrategy:p="bestFit",fallbackAxisSideDirection:m="none",flipAlignment:g=!0,...v}=nf(e,t);if((n=o.arrow)!=null&&n.alignmentOffset)return{};const x=Bs(i),_=Ca(s),w=Bs(s)===s,y=await(l.isRTL==null?void 0:l.isRTL(c.floating)),E=f||(w||!g?[rf(s)]:T6(s)),S=m!=="none";!f&&S&&E.push(...I6(s,g,m,y));const P=[s,...E],D=await z6(t,v),T=[];let I=((r=o.flip)==null?void 0:r.overflows)||[];if(u&&T.push(D[x]),d){const N=A6(i,a,y);T.push(D[N[0]],D[N[1]])}if(I=[...I,{placement:i,overflows:T}],!T.every(N=>N<=0)){var A,C;const N=(((A=o.flip)==null?void 0:A.index)||0)+1,M=P[N];if(M&&(!(d==="alignment"?_!==Ca(M):!1)||I.every(V=>Ca(V.placement)===_?V.overflows[0]>0:!0)))return{data:{index:N,overflows:I},reset:{placement:M}};let R=(C=I.filter(B=>B.overflows[0]<=0).sort((B,V)=>B.overflows[1]-V.overflows[1])[0])==null?void 0:C.placement;if(!R)switch(p){case"bestFit":{var j;const B=(j=I.filter(V=>{if(S){const z=Ca(V.placement);return z===_||z==="y"}return!0}).map(V=>[V.placement,V.overflows.filter(z=>z>0).reduce((z,W)=>z+W,0)]).sort((V,z)=>V[1]-z[1])[0])==null?void 0:j[0];B&&(R=B);break}case"initialPlacement":R=s;break}if(i!==R)return{reset:{placement:R}}}return{}}}},Y6=new Set(["left","top"]);async function U6(e,t){const{placement:n,platform:r,elements:i}=e,o=await(r.isRTL==null?void 0:r.isRTL(i.floating)),a=Bs(n),s=pc(n),l=Ca(n)==="y",c=Y6.has(a)?-1:1,u=o&&l?-1:1,d=nf(t,e);let{mainAxis:f,crossAxis:p,alignmentAxis:m}=typeof d=="number"?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return s&&typeof m=="number"&&(p=s==="end"?m*-1:m),l?{x:p*u,y:f*c}:{x:f*c,y:p*u}}const K6=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:i,y:o,placement:a,middlewareData:s}=t,l=await U6(t,e);return a===((n=s.offset)==null?void 0:n.placement)&&(r=s.arrow)!=null&&r.alignmentOffset?{}:{x:i+l.x,y:o+l.y,data:{...l,placement:a}}}}};function sE(e){const t=jr(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const i=Si(e),o=i?e.offsetWidth:n,a=i?e.offsetHeight:r,s=ef(n)!==o||ef(r)!==a;return s&&(n=o,r=a),{width:n,height:r,$:s}}function yg(e){return Nn(e)?e:e.contextElement}function Ws(e){const t=yg(e);if(!Si(t))return Oi(1);const n=t.getBoundingClientRect(),{width:r,height:i,$:o}=sE(t);let a=(o?ef(n.width):n.width)/r,s=(o?ef(n.height):n.height)/i;return(!a||!Number.isFinite(a))&&(a=1),(!s||!Number.isFinite(s))&&(s=1),{x:a,y:s}}const q6=Oi(0);function lE(e){const t=yr(e);return!pg()||!t.visualViewport?q6:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function G6(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==yr(e)?!1:t}function ka(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const i=e.getBoundingClientRect(),o=yg(e);let a=Oi(1);t&&(r?Nn(r)&&(a=Ws(r)):a=Ws(e));const s=G6(o,n,r)?lE(o):Oi(0);let l=(i.left+s.x)/a.x,c=(i.top+s.y)/a.y,u=i.width/a.x,d=i.height/a.y;if(o){const f=yr(o),p=r&&Nn(r)?yr(r):r;let m=f,g=hg(m);for(;g&&r&&p!==m;){const v=Ws(g),x=g.getBoundingClientRect(),_=jr(g),w=x.left+(g.clientLeft+parseFloat(_.paddingLeft))*v.x,y=x.top+(g.clientTop+parseFloat(_.paddingTop))*v.y;l*=v.x,c*=v.y,u*=v.x,d*=v.y,l+=w,c+=y,m=yr(g),g=hg(m)}}return of({width:u,height:d,x:l,y:c})}function sf(e,t){const n=Jd(e).scrollLeft;return t?t.left+n:ka(Ei(e)).left+n}function cE(e,t){const n=e.getBoundingClientRect(),r=n.left+t.scrollLeft-sf(e,n),i=n.top+t.scrollTop;return{x:r,y:i}}function X6(e){let{elements:t,rect:n,offsetParent:r,strategy:i}=e;const o=i==="fixed",a=Ei(r),s=t?Zd(t.floating):!1;if(r===a||s&&o)return n;let l={scrollLeft:0,scrollTop:0},c=Oi(1);const u=Oi(0),d=Si(r);if((d||!d&&!o)&&((Ls(r)!=="body"||dc(a))&&(l=Jd(r)),Si(r))){const p=ka(r);c=Ws(r),u.x=p.x+r.clientLeft,u.y=p.y+r.clientTop}const f=a&&!d&&!o?cE(a,l):Oi(0);return{width:n.width*c.x,height:n.height*c.y,x:n.x*c.x-l.scrollLeft*c.x+u.x+f.x,y:n.y*c.y-l.scrollTop*c.y+u.y+f.y}}function Q6(e){return Array.from(e.getClientRects())}function Z6(e){const t=Ei(e),n=Jd(e),r=e.ownerDocument.body,i=Oa(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),o=Oa(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let a=-n.scrollLeft+sf(e);const s=-n.scrollTop;return jr(r).direction==="rtl"&&(a+=Oa(t.clientWidth,r.clientWidth)-i),{width:i,height:o,x:a,y:s}}const uE=25;function J6(e,t){const n=yr(e),r=Ei(e),i=n.visualViewport;let o=r.clientWidth,a=r.clientHeight,s=0,l=0;if(i){o=i.width,a=i.height;const u=pg();(!u||u&&t==="fixed")&&(s=i.offsetLeft,l=i.offsetTop)}const c=sf(r);if(c<=0){const u=r.ownerDocument,d=u.body,f=getComputedStyle(d),p=u.compatMode==="CSS1Compat"&&parseFloat(f.marginLeft)+parseFloat(f.marginRight)||0,m=Math.abs(r.clientWidth-d.clientWidth-p);m<=uE&&(o-=m)}else c<=uE&&(o+=c);return{width:o,height:a,x:s,y:l}}const e3=new Set(["absolute","fixed"]);function t3(e,t){const n=ka(e,!0,t==="fixed"),r=n.top+e.clientTop,i=n.left+e.clientLeft,o=Si(e)?Ws(e):Oi(1),a=e.clientWidth*o.x,s=e.clientHeight*o.y,l=i*o.x,c=r*o.y;return{width:a,height:s,x:l,y:c}}function dE(e,t,n){let r;if(t==="viewport")r=J6(e,n);else if(t==="document")r=Z6(Ei(e));else if(Nn(t))r=t3(t,n);else{const i=lE(e);r={x:t.x-i.x,y:t.y-i.y,width:t.width,height:t.height}}return of(r)}function fE(e,t){const n=Ko(e);return n===t||!Nn(n)||Rs(n)?!1:jr(n).position==="fixed"||fE(n,t)}function n3(e,t){const n=t.get(e);if(n)return n;let r=fc(e,[],!1).filter(s=>Nn(s)&&Ls(s)!=="body"),i=null;const o=jr(e).position==="fixed";let a=o?Ko(e):e;for(;Nn(a)&&!Rs(a);){const s=jr(a),l=fg(a);!l&&s.position==="fixed"&&(i=null),(o?!l&&!i:!l&&s.position==="static"&&!!i&&e3.has(i.position)||dc(a)&&!l&&fE(e,a))?r=r.filter(u=>u!==a):i=s,a=Ko(a)}return t.set(e,r),r}function r3(e){let{element:t,boundary:n,rootBoundary:r,strategy:i}=e;const a=[...n==="clippingAncestors"?Zd(t)?[]:n3(t,this._c):[].concat(n),r],s=a[0],l=a.reduce((c,u)=>{const d=dE(t,u,i);return c.top=Oa(d.top,c.top),c.right=$s(d.right,c.right),c.bottom=$s(d.bottom,c.bottom),c.left=Oa(d.left,c.left),c},dE(t,s,i));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}}function i3(e){const{width:t,height:n}=sE(e);return{width:t,height:n}}function o3(e,t,n){const r=Si(t),i=Ei(t),o=n==="fixed",a=ka(e,!0,o,t);let s={scrollLeft:0,scrollTop:0};const l=Oi(0);function c(){l.x=sf(i)}if(r||!r&&!o)if((Ls(t)!=="body"||dc(i))&&(s=Jd(t)),r){const p=ka(t,!0,o,t);l.x=p.x+t.clientLeft,l.y=p.y+t.clientTop}else i&&c();o&&!r&&i&&c();const u=i&&!r&&!o?cE(i,s):Oi(0),d=a.left+s.scrollLeft-l.x-u.x,f=a.top+s.scrollTop-l.y-u.y;return{x:d,y:f,width:a.width,height:a.height}}function bg(e){return jr(e).position==="static"}function pE(e,t){if(!Si(e)||jr(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return Ei(e)===n&&(n=n.ownerDocument.body),n}function hE(e,t){const n=yr(e);if(Zd(e))return n;if(!Si(e)){let i=Ko(e);for(;i&&!Rs(i);){if(Nn(i)&&!bg(i))return i;i=Ko(i)}return n}let r=pE(e,t);for(;r&&y6(r)&&bg(r);)r=pE(r,t);return r&&Rs(r)&&bg(r)&&!fg(r)?n:r||E6(e)||n}const a3=async function(e){const t=this.getOffsetParent||hE,n=this.getDimensions,r=await n(e.floating);return{reference:o3(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function s3(e){return jr(e).direction==="rtl"}const l3={convertOffsetParentRelativeRectToViewportRelativeRect:X6,getDocumentElement:Ei,getClippingRect:r3,getOffsetParent:hE,getElementRects:a3,getClientRects:Q6,getDimensions:i3,getScale:Ws,isElement:Nn,isRTL:s3};function mE(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function c3(e,t){let n=null,r;const i=Ei(e);function o(){var s;clearTimeout(r),(s=n)==null||s.disconnect(),n=null}function a(s,l){s===void 0&&(s=!1),l===void 0&&(l=1),o();const c=e.getBoundingClientRect(),{left:u,top:d,width:f,height:p}=c;if(s||t(),!f||!p)return;const m=tf(d),g=tf(i.clientWidth-(u+f)),v=tf(i.clientHeight-(d+p)),x=tf(u),w={rootMargin:-m+"px "+-g+"px "+-v+"px "+-x+"px",threshold:Oa(0,$s(1,l))||1};let y=!0;function E(S){const P=S[0].intersectionRatio;if(P!==l){if(!y)return a();P?a(!1,P):r=setTimeout(()=>{a(!1,1e-7)},1e3)}P===1&&!mE(c,e.getBoundingClientRect())&&a(),y=!1}try{n=new IntersectionObserver(E,{...w,root:i.ownerDocument})}catch{n=new IntersectionObserver(E,w)}n.observe(e)}return a(!0),o}function u3(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:i=!0,ancestorResize:o=!0,elementResize:a=typeof ResizeObserver=="function",layoutShift:s=typeof IntersectionObserver=="function",animationFrame:l=!1}=r,c=yg(e),u=i||o?[...c?fc(c):[],...fc(t)]:[];u.forEach(x=>{i&&x.addEventListener("scroll",n,{passive:!0}),o&&x.addEventListener("resize",n)});const d=c&&s?c3(c,n):null;let f=-1,p=null;a&&(p=new ResizeObserver(x=>{let[_]=x;_&&_.target===c&&p&&(p.unobserve(t),cancelAnimationFrame(f),f=requestAnimationFrame(()=>{var w;(w=p)==null||w.observe(t)})),n()}),c&&!l&&p.observe(c),p.observe(t));let m,g=l?ka(e):null;l&&v();function v(){const x=ka(e);g&&!mE(g,x)&&n(),g=x,m=requestAnimationFrame(v)}return n(),()=>{var x;u.forEach(_=>{i&&_.removeEventListener("scroll",n),o&&_.removeEventListener("resize",n)}),d?.(),(x=p)==null||x.disconnect(),p=null,l&&cancelAnimationFrame(m)}}const d3=K6,f3=H6,gE=V6,p3=(e,t,n)=>{const r=new Map,i={platform:l3,...n},o={...i.platform,_c:r};return W6(e,t,{...i,platform:o})};var h3=typeof document<"u",m3=function(){},lf=h3?k.useLayoutEffect:m3;function cf(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,r,i;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;r--!==0;)if(!cf(e[r],t[r]))return!1;return!0}if(i=Object.keys(e),n=i.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,i[r]))return!1;for(r=n;r--!==0;){const o=i[r];if(!(o==="_owner"&&e.$$typeof)&&!cf(e[o],t[o]))return!1}return!0}return e!==e&&t!==t}function vE(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function yE(e,t){const n=vE(e);return Math.round(t*n)/n}function xg(e){const t=O.useRef(e);return lf(()=>{t.current=e}),t}function g3(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:i,elements:{reference:o,floating:a}={},transform:s=!0,whileElementsMounted:l,open:c}=e,[u,d]=O.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[f,p]=O.useState(r);cf(f,r)||p(r);const[m,g]=O.useState(null),[v,x]=O.useState(null),_=O.useCallback(V=>{V!==S.current&&(S.current=V,g(V))},[]),w=O.useCallback(V=>{V!==P.current&&(P.current=V,x(V))},[]),y=o||m,E=a||v,S=O.useRef(null),P=O.useRef(null),D=O.useRef(u),T=l!=null,I=xg(l),A=xg(i),C=xg(c),j=O.useCallback(()=>{if(!S.current||!P.current)return;const V={placement:t,strategy:n,middleware:f};A.current&&(V.platform=A.current),p3(S.current,P.current,V).then(z=>{const W={...z,isPositioned:C.current!==!1};N.current&&!cf(D.current,W)&&(D.current=W,Y1.flushSync(()=>{d(W)}))})},[f,t,n,A,C]);lf(()=>{c===!1&&D.current.isPositioned&&(D.current.isPositioned=!1,d(V=>({...V,isPositioned:!1})))},[c]);const N=O.useRef(!1);lf(()=>(N.current=!0,()=>{N.current=!1}),[]),lf(()=>{if(y&&(S.current=y),E&&(P.current=E),y&&E){if(I.current)return I.current(y,E,j);j()}},[y,E,j,I,T]);const M=O.useMemo(()=>({reference:S,floating:P,setReference:_,setFloating:w}),[_,w]),R=O.useMemo(()=>({reference:y,floating:E}),[y,E]),B=O.useMemo(()=>{const V={position:n,left:0,top:0};if(!R.floating)return V;const z=yE(R.floating,u.x),W=yE(R.floating,u.y);return s?{...V,transform:"translate("+z+"px, "+W+"px)",...vE(R.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:z,top:W}},[n,s,R.floating,u.x,u.y]);return O.useMemo(()=>({...u,update:j,refs:M,elements:R,floatingStyles:B}),[u,j,M,R,B])}const v3=e=>{function t(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:e,fn(n){const{element:r,padding:i}=typeof e=="function"?e(n):e;return r&&t(r)?r.current!=null?gE({element:r.current,padding:i}).fn(n):{}:r?gE({element:r,padding:i}).fn(n):{}}}},y3=(e,t)=>({...d3(e),options:[e,t]}),b3=(e,t)=>({...f3(e),options:[e,t]}),x3=(e,t)=>({...v3(e),options:[e,t]}),w3={...O};let bE=!1,_3=0;const xE=()=>"floating-ui-"+Math.random().toString(36).slice(2,6)+_3++;function E3(){const[e,t]=O.useState(()=>bE?xE():void 0);return af(()=>{e==null&&t(xE())},[]),O.useEffect(()=>{bE=!0},[]),e}const wE=w3.useId||E3;let hc;process.env.NODE_ENV!=="production"&&(hc=new Set);function S3(){for(var e,t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];const i="Floating UI: "+n.join(" ");if(!((e=hc)!=null&&e.has(i))){var o;(o=hc)==null||o.add(i),console.warn(i)}}function O3(){for(var e,t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];const i="Floating UI: "+n.join(" ");if(!((e=hc)!=null&&e.has(i))){var o;(o=hc)==null||o.add(i),console.error(i)}}const C3=O.forwardRef(function(t,n){const{context:{placement:r,elements:{floating:i},middlewareData:{arrow:o,shift:a}},width:s=14,height:l=7,tipRadius:c=0,strokeWidth:u=0,staticOffset:d,stroke:f,d:p,style:{transform:m,...g}={},...v}=t;process.env.NODE_ENV!=="production"&&(n||S3("The `ref` prop is required for `FloatingArrow`."));const x=wE(),[_,w]=O.useState(!1);if(af(()=>{if(!i)return;jr(i).direction==="rtl"&&w(!0)},[i]),!i)return null;const[y,E]=r.split("-"),S=y==="top"||y==="bottom";let P=d;(S&&a!=null&&a.x||!S&&a!=null&&a.y)&&(P=null);const D=u*2,T=D/2,I=s/2*(c/-8+1),A=l/2*c/4,C=!!p,j=P&&E==="end"?"bottom":"top";let N=P&&E==="end"?"right":"left";P&&_&&(N=E==="end"?"left":"right");const M=o?.x!=null?P||o.x:"",R=o?.y!=null?P||o.y:"",B=p||"M0,0"+(" H"+s)+(" L"+(s-I)+","+(l-A))+(" Q"+s/2+","+l+" "+I+","+(l-A))+" Z",V={top:C?"rotate(180deg)":"",left:C?"rotate(90deg)":"rotate(-90deg)",bottom:C?"":"rotate(180deg)",right:C?"rotate(-90deg)":"rotate(90deg)"}[y];return h.jsxs("svg",{...v,"aria-hidden":!0,ref:n,width:C?s:s+D,height:s,viewBox:"0 0 "+s+" "+(l>s?l:s),style:{position:"absolute",pointerEvents:"none",[N]:M,[j]:R,[y]:S||C?"100%":"calc(100% - "+D/2+"px)",transform:[V,m].filter(z=>!!z).join(" "),...g},children:[D>0&&h.jsx("path",{clipPath:"url(#"+x+")",fill:"none",stroke:f,strokeWidth:D+(p?0:1),d:B}),h.jsx("path",{stroke:D&&!p?v.fill:"none",d:B}),h.jsx("clipPath",{id:x,children:h.jsx("rect",{x:-T,y:T*(C?-1:1),width:s+D,height:s})})]})});function k3(){const e=new Map;return{emit(t,n){var r;(r=e.get(t))==null||r.forEach(i=>i(n))},on(t,n){e.has(t)||e.set(t,new Set),e.get(t).add(n)},off(t,n){var r;(r=e.get(t))==null||r.delete(n)}}}const P3=O.createContext(null),D3=O.createContext(null),A3=()=>{var e;return((e=O.useContext(P3))==null?void 0:e.id)||null},T3=()=>O.useContext(D3);function N3(e){const{open:t=!1,onOpenChange:n,elements:r}=e,i=wE(),o=O.useRef({}),[a]=O.useState(()=>k3()),s=A3()!=null;if(process.env.NODE_ENV!=="production"){const p=r.reference;p&&!Nn(p)&&O3("Cannot pass a virtual element to the `elements.reference` option,","as it must be a real DOM element. Use `refs.setPositionReference()`","instead.")}const[l,c]=O.useState(r.reference),u=B6((p,m,g)=>{o.current.openEvent=p?m:void 0,a.emit("openchange",{open:p,event:m,reason:g,nested:s}),n?.(p,m,g)}),d=O.useMemo(()=>({setPositionReference:c}),[]),f=O.useMemo(()=>({reference:l||r.reference||null,floating:r.floating||null,domReference:r.reference}),[l,r.reference,r.floating]);return O.useMemo(()=>({dataRef:o,open:t,onOpenChange:u,elements:f,events:a,floatingId:i,refs:d}),[t,u,f,a,i,d])}function j3(e){e===void 0&&(e={});const{nodeId:t}=e,n=N3({...e,elements:{reference:null,floating:null,...e.elements}}),r=e.rootContext||n,i=r.elements,[o,a]=O.useState(null),[s,l]=O.useState(null),u=i?.domReference||o,d=O.useRef(null),f=T3();af(()=>{u&&(d.current=u)},[u]);const p=g3({...e,elements:{...i,...s&&{reference:s}}}),m=O.useCallback(w=>{const y=Nn(w)?{getBoundingClientRect:()=>w.getBoundingClientRect(),getClientRects:()=>w.getClientRects(),contextElement:w}:w;l(y),p.refs.setReference(y)},[p.refs]),g=O.useCallback(w=>{(Nn(w)||w===null)&&(d.current=w,a(w)),(Nn(p.refs.reference.current)||p.refs.reference.current===null||w!==null&&!Nn(w))&&p.refs.setReference(w)},[p.refs]),v=O.useMemo(()=>({...p.refs,setReference:g,setPositionReference:m,domReference:d}),[p.refs,g,m]),x=O.useMemo(()=>({...p.elements,domReference:u}),[p.elements,u]),_=O.useMemo(()=>({...p,...r,refs:v,elements:x,nodeId:t}),[p,v,x,t,r]);return af(()=>{r.dataRef.current.floatingContext=_;const w=f?.nodesRef.current.find(y=>y.id===t);w&&(w.context=_)}),O.useMemo(()=>({...p,context:_,refs:v,elements:x}),[p,v,x,_])}/*!
|
|
120
120
|
react-datepicker v9.1.0
|
|
121
121
|
https://github.com/Hacker0x01/react-datepicker
|
|
122
122
|
Released under the MIT License.
|
|
123
123
|
*/var wg=function(t,n){return wg=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,i){r.__proto__=i}||function(r,i){for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(r[o]=i[o])},wg(t,n)};function wn(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");wg(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}var Se=function(){return Se=Object.assign||function(n){for(var r,i=1,o=arguments.length;i<o;i++){r=arguments[i];for(var a in r)Object.prototype.hasOwnProperty.call(r,a)&&(n[a]=r[a])}return n},Se.apply(this,arguments)};function Ci(e,t,n){if(n||arguments.length===2)for(var r=0,i=t.length,o;r<i;r++)(o||!(r in t))&&(o||(o=Array.prototype.slice.call(t,0,r)),o[r]=t[r]);return e.concat(o||Array.prototype.slice.call(t))}typeof SuppressedError=="function"&&SuppressedError;var M3=function(e){var t=e.showTimeSelectOnly,n=t===void 0?!1:t,r=e.showTime,i=r===void 0?!1:r,o=e.className,a=e.children,s=e.inline,l=n?"Choose Time":"Choose Date".concat(i?" and Time":"");return k.createElement("div",{className:o,"aria-label":l,role:s?void 0:"dialog","aria-modal":s?void 0:"true",translate:"no"},a)},I3=function(e,t){var n=k.useRef(null),r=k.useRef(e);k.useEffect(function(){r.current=e},[e]);var i=k.useCallback(function(o){var a,s=o.composed&&o.composedPath&&o.composedPath().find(function(l){return l instanceof Node})||o.target;n.current&&!n.current.contains(s)&&(t&&s instanceof HTMLElement&&s.classList.contains(t)||(a=r.current)===null||a===void 0||a.call(r,o))},[t]);return k.useEffect(function(){return document.addEventListener("mousedown",i),function(){document.removeEventListener("mousedown",i)}},[i]),n},uf=function(e){var t=e.children,n=e.onClickOutside,r=e.className,i=e.containerRef,o=e.style,a=e.ignoreClass,s=I3(n,a);return k.createElement("div",{className:r,style:o,ref:function(l){s.current=l,i&&(i.current=l)}},t)},df=null,_E=!1;function EE(){if(_E)return df;_E=!0;try{var e="date-fns-tz";df=require(e)}catch{df=null}return df}function SE(e,t){if(!t)return e;var n=EE();return n?n.toZonedTime(e,t):(process.env.NODE_ENV!=="production"&&console.warn('react-datepicker: timeZone prop requires "date-fns-tz" package. Please install it: npm install date-fns-tz'),e)}function ro(e,t){if(!t)return e;var n=EE();return n?n.fromZonedTime(e,t):(process.env.NODE_ENV!=="production"&&console.warn('react-datepicker: timeZone prop requires "date-fns-tz" package. Please install it: npm install date-fns-tz'),e)}var le;(function(e){e.ArrowUp="ArrowUp",e.ArrowDown="ArrowDown",e.ArrowLeft="ArrowLeft",e.ArrowRight="ArrowRight",e.PageUp="PageUp",e.PageDown="PageDown",e.Home="Home",e.End="End",e.Enter="Enter",e.Space=" ",e.Tab="Tab",e.Escape="Escape",e.Backspace="Backspace",e.X="x"})(le||(le={}));function OE(){var e=typeof window<"u"?window:globalThis;return e}var mc=12;function je(e){if(e==null)return new Date;var t=typeof e=="string"?e6(e):ve(e);return er(t)?t:new Date}function Pa(e,t,n,r,i){i===void 0&&(i=je());for(var o=zs(n)||zs(_g()),a=Array.isArray(t)?t:[t],s=0,l=a;s<l.length;s++){var c=l[s],u=qB(e,c,i,{locale:o});if(er(u)&&(!r||e===mt(u,c,n)))return u}if(!r&&e&&e.length>=8){var d=new Date(e);if(Ms(d))return d}return null}function F3(e,t){if(t===void 0&&(t=je()),!e)return null;var n=e.match(/\b(1\d{3}|2\d{3})\b/);if(!n||!n[1])return null;var r=parseInt(n[1],10),i=e.match(/(?:^|[/\-\s])?(0?[1-9]|1[0-2])(?:[/\-\s]|$)/),o=i&&i[1]?parseInt(i[1],10)-1:t.getMonth();return new Date(r,o,1)}function er(e){return Ms(e)}function Da(e){return e==null?null:yi(e)&&Ms(e)?e:null}function mt(e,t,n){if(n==="en")return Y_(e,t,{useAdditionalWeekYearTokens:!0,useAdditionalDayOfYearTokens:!0});var r=n?zs(n):void 0;return n&&!r&&console.warn('A locale object was not found for the provided string ["'.concat(n,'"].')),r=r||zs(_g()),Y_(e,t,{locale:r,useAdditionalWeekYearTokens:!0,useAdditionalDayOfYearTokens:!0})}function tr(e,t){var n=t.dateFormat,r=t.locale,i=Array.isArray(n)&&n.length>0?n[0]:n;return e&&mt(e,i,r)||""}var CE=" - ";function L3(e,t,n){if(!e&&!t)return"";var r=e?tr(e,n):"",i=t?tr(t,n):"",o=n.rangeSeparator||CE;return"".concat(r).concat(o).concat(i)}function R3(e,t){if(!e?.length)return"";var n=e[0]?tr(e[0],t):"";if(e.length===1)return n;if(e.length===2&&e[1]){var r=tr(e[1],t);return"".concat(n,", ").concat(r)}var i=e.length-1;return"".concat(n," (+").concat(i,")")}function io(e,t){var n=t.hour,r=n===void 0?0:n,i=t.minute,o=i===void 0?0:i,a=t.second,s=a===void 0?0:a;return qd(Gd(Xd(e,s),o),r)}function $3(e){return og(e)}function B3(e,t){return mt(e,"ddd",t)}function gc(e){return _a(e)}function qo(e,t,n){var r=zs(t||_g());return eo(e,{locale:r,weekStartsOn:n})}function oo(e){return F_(e)}function vc(e){return Yd(e)}function kE(e){return rg(e)}function PE(){return _a(je())}function DE(e){return M_(e)}function W3(e){return n5(e)}function z3(e){return I_(e)}function ki(e,t){return e&&t?ZB(e,t):!e&&!t}function Un(e,t){return e&&t?XB(e,t):!e&&!t}function ff(e,t){return e&&t?QB(e,t):!e&&!t}function Ae(e,t){return e&&t?e5(e,t):!e&&!t}function Aa(e,t){return e&&t?J5(e,t):!e&&!t}function Ta(e,t,n){var r,i=_a(t),o=M_(n);try{r=cc(e,{start:i,end:o})}catch{r=!1}return r}function _g(){var e=OE();return e.__localeId__}function zs(e){if(typeof e=="string"){var t=OE();return t.__localeData__?t.__localeData__[e]:void 0}else return e}function V3(e,t,n){return t(mt(e,"EEEE",n))}function H3(e,t){return mt(e,"EEEEEE",t)}function Y3(e,t){return mt(e,"EEE",t)}function Eg(e,t){return mt(vr(je(),e),"LLLL",t)}function AE(e,t){return mt(vr(je(),e),"LLL",t)}function U3(e,t){return mt(Fs(je(),e),"QQQ",t)}function Mr(e,t){var n=t===void 0?{}:t,r=n.minDate,i=n.maxDate,o=n.excludeDates,a=n.excludeDateIntervals,s=n.includeDates,l=n.includeDateIntervals,c=n.filterDate,u=n.disabled;return u?!0:yc(e,{minDate:r,maxDate:i})||o&&o.some(function(d){return d instanceof Date?Ae(e,d):Ae(e,d.date)})||a&&a.some(function(d){var f=d.start,p=d.end;return cc(e,{start:f,end:p})})||s&&!s.some(function(d){return Ae(e,d)})||l&&!l.some(function(d){var f=d.start,p=d.end;return cc(e,{start:f,end:p})})||c&&!c(je(e))||!1}function Sg(e,t){var n=t===void 0?{}:t,r=n.excludeDates,i=n.excludeDateIntervals;return i&&i.length>0?i.some(function(o){var a=o.start,s=o.end;return cc(e,{start:a,end:s})}):r&&r.some(function(o){var a;return o instanceof Date?Ae(e,o):Ae(e,(a=o.date)!==null&&a!==void 0?a:new Date)})||!1}function TE(e,t){var n=t===void 0?{}:t,r=n.minDate,i=n.maxDate,o=n.excludeDates,a=n.includeDates,s=n.filterDate;return yc(e,{minDate:r?F_(r):void 0,maxDate:i?I_(i):void 0})||o?.some(function(l){return Un(e,l instanceof Date?l:l.date)})||a&&!a.some(function(l){return Un(e,l)})||s&&!s(je(e))||!1}function pf(e,t,n,r){var i=Ce(e),o=Jn(e),a=Ce(t),s=Jn(t),l=Ce(r);return i===a&&i===l?o<=n&&n<=s:i<a?l===i&&o<=n||l===a&&s>=n||l<a&&l>i:!1}function K3(e,t){var n=t===void 0?{}:t,r=n.minDate,i=n.maxDate,o=n.excludeDates,a=n.includeDates;return yc(e,{minDate:r,maxDate:i})||o&&o.some(function(s){return Un(s instanceof Date?s:s.date,e)})||a&&!a.some(function(s){return Un(s,e)})||!1}function hf(e,t){var n=t===void 0?{}:t,r=n.minDate,i=n.maxDate,o=n.excludeDates,a=n.includeDates,s=n.filterDate,l=n.disabled;return l?!0:yc(e,{minDate:r,maxDate:i})||o?.some(function(c){return ff(e,c instanceof Date?c:c.date)})||a&&!a.some(function(c){return ff(e,c)})||s&&!s(je(e))||!1}function mf(e,t,n){if(!t||!n||!Ms(t)||!Ms(n))return!1;var r=Ce(t),i=Ce(n);return r<=e&&i>=e}function gf(e,t){var n=t===void 0?{}:t,r=n.minDate,i=n.maxDate,o=n.excludeDates,a=n.includeDates,s=n.filterDate,l=n.disabled;if(l)return!0;var c=new Date(e,0,1);return yc(c,{minDate:r?Yd(r):void 0,maxDate:i?L_(i):void 0})||o?.some(function(u){return ki(c,u instanceof Date?u:u.date)})||a&&!a.some(function(u){return ki(c,u)})||s&&!s(je(c))||!1}function vf(e,t,n,r){var i=Ce(e),o=Vo(e),a=Ce(t),s=Vo(t),l=Ce(r);return i===a&&i===l?o<=n&&n<=s:i<a?l===i&&o<=n||l===a&&s>=n||l<a&&l>i:!1}function yc(e,t){var n,r=t===void 0?{}:t,i=r.minDate,o=r.maxDate;return(n=i&&js(e,i)<0||o&&js(e,o)>0)!==null&&n!==void 0?n:!1}function NE(e,t){return t.some(function(n){return An(n)===An(e)&&Tn(n)===Tn(e)&&Yo(n)===Yo(e)})}function jE(e,t){var n=t===void 0?{}:t,r=n.excludeTimes,i=n.includeTimes,o=n.filterTime;return r&&NE(e,r)||i&&!NE(e,i)||o&&!o(e)||!1}function ME(e,t){var n=t.minTime,r=t.maxTime;if(!n||!r)throw new Error("Both minTime and maxTime props required");var i=je();i=qd(i,An(e)),i=Gd(i,Tn(e)),i=Xd(i,Yo(e));var o=je();o=qd(o,An(n)),o=Gd(o,Tn(n)),o=Xd(o,Yo(n));var a=je();a=qd(a,An(r)),a=Gd(a,Tn(r)),a=Xd(a,Yo(r));var s;try{s=!cc(i,{start:o,end:a})}catch{s=!1}return s}function IE(e,t){var n=t===void 0?{}:t,r=n.minDate,i=n.includeDates,o=Sa(e,1);return r&&zd(r,o)>0||i&&i.every(function(a){return zd(a,o)>0})||!1}function FE(e,t){var n=t===void 0?{}:t,r=n.maxDate,i=n.includeDates,o=ti(e,1);return r&&zd(o,r)>0||i&&i.every(function(a){return zd(o,a)>0})||!1}function q3(e,t){var n=t===void 0?{}:t,r=n.minDate,i=n.includeDates,o=Yd(e),a=Z_(o);return r&&Vd(r,a)>0||i&&i.every(function(s){return Vd(s,a)>0})||!1}function G3(e,t){var n=t===void 0?{}:t,r=n.maxDate,i=n.includeDates,o=L_(e),a=ng(o,1);return r&&Vd(a,r)>0||i&&i.every(function(s){return Vd(a,s)>0})||!1}function LE(e,t){var n=t===void 0?{}:t,r=n.minDate,i=n.includeDates,o=Uo(e,1);return r&&Hd(r,o)>0||i&&i.every(function(a){return Hd(a,o)>0})||!1}function X3(e,t){var n=t===void 0?{}:t,r=n.minDate,i=n.yearItemNumber,o=i===void 0?mc:i,a=vc(Uo(e,o)),s=ao(a,o).endPeriod,l=r&&Ce(r);return l&&l>s||!1}function RE(e,t){var n=t===void 0?{}:t,r=n.maxDate,i=n.includeDates,o=ni(e,1);return r&&Hd(o,r)>0||i&&i.every(function(a){return Hd(o,a)>0})||!1}function Q3(e,t){var n=t===void 0?{}:t,r=n.maxDate,i=n.yearItemNumber,o=i===void 0?mc:i,a=ni(e,o),s=ao(a,o).startPeriod,l=r&&Ce(r);return l&&l<s||!1}function $E(e){var t=e.minDate,n=e.includeDates;if(n&&t){var r=n.filter(function(i){return js(i,t)>=0});return N_(r)}else return n?N_(n):t}function BE(e){var t=e.maxDate,n=e.includeDates;if(n&&t){var r=n.filter(function(i){return js(i,t)<=0});return T_(r)}else return n?T_(n):t}function WE(e,t){var n;e===void 0&&(e=[]),t===void 0&&(t="react-datepicker__day--highlighted");for(var r=new Map,i=0,o=e.length;i<o;i++){var a=e[i];if(yi(a)){var s=mt(a,"MM.dd.yyyy"),l=r.get(s)||[];l.includes(t)||(l.push(t),r.set(s,l))}else if(typeof a=="object"){var c=Object.keys(a),u=(n=c[0])!==null&&n!==void 0?n:"",d=a[u];if(typeof u=="string"&&Array.isArray(d))for(var f=0,p=d.length;f<p;f++){var m=d[f];if(m){var s=mt(m,"MM.dd.yyyy"),l=r.get(s)||[];l.includes(u)||(l.push(u),r.set(s,l))}}}}return r}function Z3(e,t){return e.length!==t.length?!1:e.every(function(n,r){return n===t[r]})}function J3(e,t){e===void 0&&(e=[]),t===void 0&&(t="react-datepicker__day--holidays");var n=new Map;return e.forEach(function(r){var i=r.date,o=r.holidayName;if(yi(i)){var a=mt(i,"MM.dd.yyyy"),s=n.get(a)||{className:"",holidayNames:[]};if(!("className"in s&&s.className===t&&Z3(s.holidayNames,[o]))){s.className=t;var l=s.holidayNames;s.holidayNames=l?Ci(Ci([],l,!0),[o],!1):[o],n.set(a,s)}}}),n}function e8(e,t,n,r,i){for(var o=i.length,a=[],s=0;s<o;s++){var l=e,c=i[s];c&&(l=X$(l,An(c)),l=ac(l,Tn(c)),l=J$(l,Yo(c)));var u=ac(e,(n+1)*r);no(l,t)&&bi(l,u)&&c!=null&&a.push(c)}return a}function Vs(e){return e<10?"0".concat(e):"".concat(e)}function ao(e,t){t===void 0&&(t=mc);var n=Math.ceil(Ce(e)/t)*t,r=n-(t-1);return{startPeriod:r,endPeriod:n}}function t8(e){var t=new Date(e.getFullYear(),e.getMonth(),e.getDate()),n=new Date(e.getFullYear(),e.getMonth(),e.getDate(),24);return Math.round((+n-+t)/36e5)}function zE(e){var t=e.getSeconds(),n=e.getMilliseconds();return ve(e.getTime()-t*1e3-n)}function VE(e,t){return zE(e).getTime()===zE(t).getTime()}function HE(e){if(!yi(e))throw new Error("Invalid date");var t=new Date(e);return t.setHours(0,0,0,0),t}function Og(e,t){if(!yi(e)||!yi(t))throw new Error("Invalid date received");var n=HE(e),r=HE(t);return bi(n,r)}function YE(e){return e.key===le.Space}var Cg=(function(e){wn(t,e);function t(n){var r=e.call(this,n)||this;return r.inputRef=k.createRef(),r.onTimeChange=function(i){var o,a;r.setState({time:i});var s=r.props.date,l=s instanceof Date&&!isNaN(+s),c=l?s:new Date;if(i?.includes(":")){var u=i.split(":"),d=u[0],f=u[1];c.setHours(Number(d)),c.setMinutes(Number(f))}(a=(o=r.props).onChange)===null||a===void 0||a.call(o,c)},r.renderTimeInput=function(){var i=r.state.time,o=r.props,a=o.date,s=o.timeString,l=o.customTimeInput;return l?k.cloneElement(l,{date:a,value:i,onChange:r.onTimeChange}):k.createElement("input",{type:"time",className:"react-datepicker-time__input",placeholder:"Time",name:"time-input",ref:r.inputRef,onClick:function(){var c;(c=r.inputRef.current)===null||c===void 0||c.focus()},required:!0,value:i,onChange:function(c){r.onTimeChange(c.target.value||s)}})},r.state={time:r.props.timeString},r}return t.getDerivedStateFromProps=function(n,r){return n.timeString!==r.time?{time:n.timeString}:null},t.prototype.render=function(){return k.createElement("div",{className:"react-datepicker__input-time-container"},k.createElement("div",{className:"react-datepicker-time__caption"},this.props.timeInputLabel),k.createElement("div",{className:"react-datepicker-time__input-container"},k.createElement("div",{className:"react-datepicker-time__input"},this.renderTimeInput())))},t})(k.Component),n8=(function(e){wn(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.dayEl=k.createRef(),n.handleClick=function(r){!n.isDisabled()&&n.props.onClick&&n.props.onClick(r)},n.handleMouseEnter=function(r){!n.isDisabled()&&n.props.onMouseEnter&&n.props.onMouseEnter(r)},n.handleOnKeyDown=function(r){var i,o,a=r.key;a===le.Space&&(r.preventDefault(),r.key=le.Enter),(o=(i=n.props).handleOnKeyDown)===null||o===void 0||o.call(i,r)},n.isSameDay=function(r){return Ae(n.props.day,r)},n.isKeyboardSelected=function(){var r;if(n.props.disabledKeyboardNavigation)return!1;var i=n.props.selectsMultiple?(r=n.props.selectedDates)===null||r===void 0?void 0:r.some(function(a){return n.isSameDayOrWeek(a)}):n.isSameDayOrWeek(n.props.selected),o=n.props.preSelection&&n.isDisabled(n.props.preSelection);return!i&&n.isSameDayOrWeek(n.props.preSelection)&&!o},n.isDisabled=function(r){return r===void 0&&(r=n.props.day),Mr(r,{minDate:n.props.minDate,maxDate:n.props.maxDate,excludeDates:n.props.excludeDates,excludeDateIntervals:n.props.excludeDateIntervals,includeDateIntervals:n.props.includeDateIntervals,includeDates:n.props.includeDates,filterDate:n.props.filterDate,disabled:n.props.disabled})},n.isExcluded=function(){return Sg(n.props.day,{excludeDates:n.props.excludeDates,excludeDateIntervals:n.props.excludeDateIntervals})},n.isStartOfWeek=function(){return Ae(n.props.day,qo(n.props.day,n.props.locale,n.props.calendarStartDay))},n.isSameWeek=function(r){return n.props.showWeekPicker&&Ae(r,qo(n.props.day,n.props.locale,n.props.calendarStartDay))},n.isSameDayOrWeek=function(r){return n.isSameDay(r)||n.isSameWeek(r)},n.getHighLightedClass=function(){var r=n.props,i=r.day,o=r.highlightDates;if(!o)return!1;var a=mt(i,"MM.dd.yyyy");return o.get(a)},n.getHolidaysClass=function(){var r,i=n.props,o=i.day,a=i.holidays;if(!a)return[void 0];var s=mt(o,"MM.dd.yyyy");return a.has(s)?[(r=a.get(s))===null||r===void 0?void 0:r.className]:[void 0]},n.isInRange=function(){var r=n.props,i=r.day,o=r.startDate,a=r.endDate;return!o||!a?!1:Ta(i,o,a)},n.isInSelectingRange=function(){var r,i=n.props,o=i.day,a=i.selectsStart,s=i.selectsEnd,l=i.selectsRange,c=i.selectsDisabledDaysInRange,u=i.startDate,d=i.swapRange,f=i.endDate,p=(r=n.props.selectingDate)!==null&&r!==void 0?r:n.props.preSelection;if(n.isAfterMonth()||n.isBeforeMonth()||!(a||s||l)||!p||!c&&n.isDisabled())return!1;if(a&&f&&(bi(p,f)||Aa(p,f)))return Ta(o,p,f);if(s&&u&&(no(p,u)||Aa(p,u)))return Ta(o,u,p);if(l&&u&&!f){if(Aa(p,u)||no(p,u))return Ta(o,u,p);if(d&&bi(p,u))return Ta(o,p,u)}return!1},n.isSelectingRangeStart=function(){var r;if(!n.isInSelectingRange())return!1;var i=n.props,o=i.day,a=i.startDate,s=i.selectsStart,l=i.swapRange,c=i.selectsRange,u=(r=n.props.selectingDate)!==null&&r!==void 0?r:n.props.preSelection;return s?Ae(o,u):c&&l&&a&&u?Ae(o,bi(u,a)?u:a):Ae(o,a)},n.isSelectingRangeEnd=function(){var r;if(!n.isInSelectingRange())return!1;var i=n.props,o=i.day,a=i.endDate,s=i.selectsEnd,l=i.selectsRange,c=i.swapRange,u=i.startDate,d=(r=n.props.selectingDate)!==null&&r!==void 0?r:n.props.preSelection;return s?Ae(o,d):l&&c&&u&&d?Ae(o,bi(d,u)?u:d):l?Ae(o,d):Ae(o,a)},n.isRangeStart=function(){var r=n.props,i=r.day,o=r.startDate,a=r.endDate;return!o||!a?!1:Ae(o,i)},n.isRangeEnd=function(){var r=n.props,i=r.day,o=r.startDate,a=r.endDate;return!o||!a?!1:Ae(a,i)},n.isWeekend=function(){var r=G5(n.props.day);return r===0||r===6},n.isAfterMonth=function(){return n.props.month!==void 0&&(n.props.month+1)%12===Jn(n.props.day)},n.isBeforeMonth=function(){return n.props.month!==void 0&&(Jn(n.props.day)+1)%12===n.props.month},n.isCurrentDay=function(){return n.isSameDay(je())},n.isSelected=function(){var r;return n.props.selectsMultiple?(r=n.props.selectedDates)===null||r===void 0?void 0:r.some(function(i){return n.isSameDayOrWeek(i)}):n.isSameDayOrWeek(n.props.selected)},n.getClassNames=function(r){var i=n.props.dayClassName?n.props.dayClassName(r):void 0;return ue("react-datepicker__day",i,"react-datepicker__day--"+B3(n.props.day),{"react-datepicker__day--disabled":n.isDisabled(),"react-datepicker__day--excluded":n.isExcluded(),"react-datepicker__day--selected":n.isSelected(),"react-datepicker__day--keyboard-selected":n.isKeyboardSelected(),"react-datepicker__day--range-start":n.isRangeStart(),"react-datepicker__day--range-end":n.isRangeEnd(),"react-datepicker__day--in-range":n.isInRange(),"react-datepicker__day--in-selecting-range":n.isInSelectingRange(),"react-datepicker__day--selecting-range-start":n.isSelectingRangeStart(),"react-datepicker__day--selecting-range-end":n.isSelectingRangeEnd(),"react-datepicker__day--today":n.isCurrentDay(),"react-datepicker__day--weekend":n.isWeekend(),"react-datepicker__day--outside-month":n.isAfterMonth()||n.isBeforeMonth()},n.getHighLightedClass(),n.getHolidaysClass())},n.getAriaLabel=function(){var r=n.props,i=r.day,o=r.ariaLabelPrefixWhenEnabled,a=o===void 0?"Choose":o,s=r.ariaLabelPrefixWhenDisabled,l=s===void 0?"Not available":s,c=n.isDisabled()||n.isExcluded()?l:a;return"".concat(c," ").concat(mt(i,"PPPP",n.props.locale))},n.getTitle=function(){var r=n.props,i=r.day,o=r.holidays,a=o===void 0?new Map:o,s=r.excludeDates,l=mt(i,"MM.dd.yyyy"),c=[];return a.has(l)&&c.push.apply(c,a.get(l).holidayNames),n.isExcluded()&&c.push(s?.filter(function(u){return u instanceof Date?Ae(u,i):Ae(u?.date,i)}).map(function(u){if(!(u instanceof Date))return u?.message})),c.join(", ")},n.getTabIndex=function(){var r=n.props.selected,i=n.props.preSelection,o=!(n.props.showWeekPicker&&(n.props.showWeekNumber||!n.isStartOfWeek()))&&(n.isKeyboardSelected()||n.isSameDay(r)&&Ae(i,r))?0:-1;return o},n.handleFocusDay=function(){var r;n.shouldFocusDay()&&((r=n.dayEl.current)===null||r===void 0||r.focus({preventScroll:!0}))},n.renderDayContents=function(){return n.props.monthShowsDuplicateDaysEnd&&n.isAfterMonth()||n.props.monthShowsDuplicateDaysStart&&n.isBeforeMonth()?null:n.props.renderDayContents?n.props.renderDayContents(U_(n.props.day),n.props.day):U_(n.props.day)},n.render=function(){return k.createElement("div",{ref:n.dayEl,className:n.getClassNames(n.props.day),onKeyDown:n.handleOnKeyDown,onClick:n.handleClick,onMouseEnter:n.props.usePointerEvent?void 0:n.handleMouseEnter,onPointerEnter:n.props.usePointerEvent?n.handleMouseEnter:void 0,tabIndex:n.getTabIndex(),"aria-label":n.getAriaLabel(),role:"gridcell",title:n.getTitle(),"aria-disabled":n.isDisabled(),"aria-current":n.isCurrentDay()?"date":void 0,"aria-selected":n.isSelected()||n.isInRange()},n.renderDayContents(),n.getTitle()!==""&&k.createElement("span",{className:"overlay"},n.getTitle()))},n}return t.prototype.componentDidMount=function(){this.handleFocusDay()},t.prototype.componentDidUpdate=function(){this.handleFocusDay()},t.prototype.shouldFocusDay=function(){var n=!1;return this.getTabIndex()===0&&this.isSameDay(this.props.preSelection)&&((!document.activeElement||document.activeElement===document.body)&&(n=!0),this.props.inline&&!this.props.shouldFocusDayInline&&(n=!1),this.isDayActiveElement()&&(n=!0),this.isDuplicateDay()&&(n=!1)),n},t.prototype.isDayActiveElement=function(){var n,r,i;return((r=(n=this.props.containerRef)===null||n===void 0?void 0:n.current)===null||r===void 0?void 0:r.contains(document.activeElement))&&((i=document.activeElement)===null||i===void 0?void 0:i.classList.contains("react-datepicker__day"))},t.prototype.isDuplicateDay=function(){return this.props.monthShowsDuplicateDaysEnd&&this.isAfterMonth()||this.props.monthShowsDuplicateDaysStart&&this.isBeforeMonth()},t})(k.Component),r8=(function(e){wn(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.weekNumberEl=k.createRef(),n.handleClick=function(r){n.props.onClick&&n.props.onClick(r)},n.handleOnKeyDown=function(r){var i,o,a=r.key;a===le.Space&&(r.preventDefault(),r.key=le.Enter),(o=(i=n.props).handleOnKeyDown)===null||o===void 0||o.call(i,r)},n.isKeyboardSelected=function(){return!n.props.disabledKeyboardNavigation&&!Ae(n.props.date,n.props.selected)&&Ae(n.props.date,n.props.preSelection)},n.getTabIndex=function(){return n.props.showWeekPicker&&n.props.showWeekNumber&&(n.isKeyboardSelected()||Ae(n.props.date,n.props.selected)&&Ae(n.props.preSelection,n.props.selected))?0:-1},n.handleFocusWeekNumber=function(r){var i=!1;n.getTabIndex()===0&&!r?.isInputFocused&&Ae(n.props.date,n.props.preSelection)&&((!document.activeElement||document.activeElement===document.body)&&(i=!0),n.props.inline&&!n.props.shouldFocusDayInline&&(i=!1),n.props.containerRef&&n.props.containerRef.current&&n.props.containerRef.current.contains(document.activeElement)&&document.activeElement&&document.activeElement.classList.contains("react-datepicker__week-number")&&(i=!0)),i&&n.weekNumberEl.current&&n.weekNumberEl.current.focus({preventScroll:!0})},n}return Object.defineProperty(t,"defaultProps",{get:function(){return{ariaLabelPrefix:"week "}},enumerable:!1,configurable:!0}),t.prototype.componentDidMount=function(){this.handleFocusWeekNumber()},t.prototype.componentDidUpdate=function(n){this.handleFocusWeekNumber(n)},t.prototype.render=function(){var n=this.props,r=n.weekNumber,i=n.isWeekDisabled,o=n.ariaLabelPrefix,a=o===void 0?t.defaultProps.ariaLabelPrefix:o,s=n.onClick,l={"react-datepicker__week-number":!0,"react-datepicker__week-number--clickable":!!s&&!i,"react-datepicker__week-number--selected":!!s&&Ae(this.props.date,this.props.selected)};return k.createElement("div",{ref:this.weekNumberEl,className:ue(l),"aria-label":"".concat(a," ").concat(this.props.weekNumber),onClick:this.handleClick,onKeyDown:this.handleOnKeyDown,tabIndex:this.getTabIndex(),role:"gridcell"},r)},t})(k.Component),i8=(function(e){wn(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.isDisabled=function(r){return Mr(r,{minDate:n.props.minDate,maxDate:n.props.maxDate,excludeDates:n.props.excludeDates,excludeDateIntervals:n.props.excludeDateIntervals,includeDateIntervals:n.props.includeDateIntervals,includeDates:n.props.includeDates,filterDate:n.props.filterDate})},n.handleDayClick=function(r,i){n.props.onDayClick&&n.props.onDayClick(r,i)},n.handleDayMouseEnter=function(r){n.props.onDayMouseEnter&&n.props.onDayMouseEnter(r)},n.handleWeekClick=function(r,i,o){for(var a,s,l,c=new Date(r),u=0;u<7;u++){var d=new Date(r);d.setDate(d.getDate()+u);var f=!n.isDisabled(d);if(f){c=d;break}}typeof n.props.onWeekSelect=="function"&&n.props.onWeekSelect(c,i,o),n.props.showWeekPicker&&n.handleDayClick(c,o),((a=n.props.shouldCloseOnSelect)!==null&&a!==void 0?a:t.defaultProps.shouldCloseOnSelect)&&((l=(s=n.props).setOpen)===null||l===void 0||l.call(s,!1))},n.formatWeekNumber=function(r){return n.props.formatWeekNumber?n.props.formatWeekNumber(r):$3(r)},n.isWeekDisabled=function(){for(var r=n.startOfWeek(),i=ei(r,6),o=new Date(r);o<=i;){if(!n.isDisabled(o))return!1;o=ei(o,1)}return!0},n.renderDays=function(){var r=n.startOfWeek(),i=[],o=n.formatWeekNumber(r);if(n.props.showWeekNumber){var a=n.props.onWeekSelect||n.props.showWeekPicker?n.handleWeekClick.bind(n,r,o):void 0;i.push(k.createElement(r8,Se({key:"W"},t.defaultProps,n.props,{weekNumber:o,isWeekDisabled:n.isWeekDisabled(),date:r,onClick:a})))}return i.concat([0,1,2,3,4,5,6].map(function(s){var l=ei(r,s);return k.createElement(n8,Se({},t.defaultProps,n.props,{ariaLabelPrefixWhenEnabled:n.props.chooseDayAriaLabelPrefix,ariaLabelPrefixWhenDisabled:n.props.disabledDayAriaLabelPrefix,key:l.valueOf(),day:l,onClick:n.handleDayClick.bind(n,l),onMouseEnter:n.handleDayMouseEnter.bind(n,l)}))}))},n.startOfWeek=function(){return qo(n.props.day,n.props.locale,n.props.calendarStartDay)},n.isKeyboardSelected=function(){return!n.props.disabledKeyboardNavigation&&!Ae(n.startOfWeek(),n.props.selected)&&Ae(n.startOfWeek(),n.props.preSelection)},n}return Object.defineProperty(t,"defaultProps",{get:function(){return{shouldCloseOnSelect:!0}},enumerable:!1,configurable:!0}),t.prototype.render=function(){var n={"react-datepicker__week":!0,"react-datepicker__week--selected":Ae(this.startOfWeek(),this.props.selected),"react-datepicker__week--keyboard-selected":this.isKeyboardSelected()},r=this.props.weekClassName?this.props.weekClassName(this.startOfWeek()):void 0;return k.createElement("div",{className:ue(n,r),role:"row"},this.renderDays())},t})(k.Component),bc,o8=6,Hs={TWO_COLUMNS:"two_columns",THREE_COLUMNS:"three_columns",FOUR_COLUMNS:"four_columns"},kg=(bc={},bc[Hs.TWO_COLUMNS]={grid:[[0,1],[2,3],[4,5],[6,7],[8,9],[10,11]],verticalNavigationOffset:2},bc[Hs.THREE_COLUMNS]={grid:[[0,1,2],[3,4,5],[6,7,8],[9,10,11]],verticalNavigationOffset:3},bc[Hs.FOUR_COLUMNS]={grid:[[0,1,2,3],[4,5,6,7],[8,9,10,11]],verticalNavigationOffset:4},bc),yf=1;function UE(e,t){return e?Hs.FOUR_COLUMNS:t?Hs.TWO_COLUMNS:Hs.THREE_COLUMNS}var a8=(function(e){wn(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.MONTH_REFS=Ci([],Array(12),!0).map(function(){return k.createRef()}),n.QUARTER_REFS=Ci([],Array(4),!0).map(function(){return k.createRef()}),n.isDisabled=function(r){return Mr(r,{minDate:n.props.minDate,maxDate:n.props.maxDate,excludeDates:n.props.excludeDates,excludeDateIntervals:n.props.excludeDateIntervals,includeDateIntervals:n.props.includeDateIntervals,includeDates:n.props.includeDates,filterDate:n.props.filterDate,disabled:n.props.disabled})},n.isExcluded=function(r){return Sg(r,{excludeDates:n.props.excludeDates,excludeDateIntervals:n.props.excludeDateIntervals})},n.handleDayClick=function(r,i){var o,a;(a=(o=n.props).onDayClick)===null||a===void 0||a.call(o,r,i,n.props.orderInDisplay)},n.handleDayMouseEnter=function(r){var i,o;(o=(i=n.props).onDayMouseEnter)===null||o===void 0||o.call(i,r)},n.handleMouseLeave=function(){var r,i;(i=(r=n.props).onMouseLeave)===null||i===void 0||i.call(r)},n.isRangeStartMonth=function(r){var i=n.props,o=i.day,a=i.startDate,s=i.endDate;return!a||!s?!1:Un(vr(o,r),a)},n.isRangeStartQuarter=function(r){var i=n.props,o=i.day,a=i.startDate,s=i.endDate;return!a||!s?!1:ff(Fs(o,r),a)},n.isRangeEndMonth=function(r){var i=n.props,o=i.day,a=i.startDate,s=i.endDate;return!a||!s?!1:Un(vr(o,r),s)},n.isRangeEndQuarter=function(r){var i=n.props,o=i.day,a=i.startDate,s=i.endDate;return!a||!s?!1:ff(Fs(o,r),s)},n.isInSelectingRangeMonth=function(r){var i,o=n.props,a=o.day,s=o.selectsStart,l=o.selectsEnd,c=o.selectsRange,u=o.startDate,d=o.endDate,f=(i=n.props.selectingDate)!==null&&i!==void 0?i:n.props.preSelection;return!(s||l||c)||!f?!1:s&&d?pf(f,d,r,a):l&&u||c&&u&&!d?pf(u,f,r,a):!1},n.isSelectingMonthRangeStart=function(r){var i;if(!n.isInSelectingRangeMonth(r))return!1;var o=n.props,a=o.day,s=o.startDate,l=o.selectsStart,c=vr(a,r),u=(i=n.props.selectingDate)!==null&&i!==void 0?i:n.props.preSelection;return l?Un(c,u):Un(c,s)},n.isSelectingMonthRangeEnd=function(r){var i;if(!n.isInSelectingRangeMonth(r))return!1;var o=n.props,a=o.day,s=o.endDate,l=o.selectsEnd,c=o.selectsRange,u=vr(a,r),d=(i=n.props.selectingDate)!==null&&i!==void 0?i:n.props.preSelection;return l||c?Un(u,d):Un(u,s)},n.isInSelectingRangeQuarter=function(r){var i,o=n.props,a=o.day,s=o.selectsStart,l=o.selectsEnd,c=o.selectsRange,u=o.startDate,d=o.endDate,f=(i=n.props.selectingDate)!==null&&i!==void 0?i:n.props.preSelection;return!(s||l||c)||!f?!1:s&&d?vf(f,d,r,a):l&&u||c&&u&&!d?vf(u,f,r,a):!1},n.isWeekInMonth=function(r){var i=n.props.day,o=ei(r,6);return Un(r,i)||Un(o,i)},n.isCurrentMonth=function(r,i){return Ce(r)===Ce(je())&&i===Jn(je())},n.isCurrentQuarter=function(r,i){return Ce(r)===Ce(je())&&i===Vo(je())},n.isSelectedMonth=function(r,i,o){return Jn(o)===i&&Ce(r)===Ce(o)},n.isSelectMonthInList=function(r,i,o){return o.some(function(a){return n.isSelectedMonth(r,i,a)})},n.isSelectedQuarter=function(r,i,o){return Vo(o)===i&&Ce(r)===Ce(o)},n.isSelectQuarterInList=function(r,i,o){return o.some(function(a){return n.isSelectedQuarter(r,i,a)})},n.isMonthSelected=function(){var r=n.props,i=r.day,o=r.selected,a=r.selectedDates,s=r.selectsMultiple,l=Jn(i);return s?a?.some(function(c){return n.isSelectedMonth(i,l,c)}):!!o&&n.isSelectedMonth(i,l,o)},n.isQuarterSelected=function(){var r=n.props,i=r.day,o=r.selected,a=r.selectedDates,s=r.selectsMultiple,l=Vo(i);return s?a?.some(function(c){return n.isSelectedQuarter(i,l,c)}):!!o&&n.isSelectedQuarter(i,l,o)},n.renderWeeks=function(){if(!er(n.props.day))return[];for(var r=[],i=n.props.fixedHeight,o=0,a=!1,s=qo(oo(n.props.day),n.props.locale,n.props.calendarStartDay),l=function(m){return n.props.showWeekPicker?qo(m,n.props.locale,n.props.calendarStartDay):n.props.preSelection},c=function(m){return n.props.showWeekPicker?qo(m,n.props.locale,n.props.calendarStartDay):n.props.selected},u=n.props.selected?c(n.props.selected):void 0,d=n.props.preSelection?l(n.props.preSelection):void 0;r.push(k.createElement(i8,Se({},n.props,{ariaLabelPrefix:n.props.weekAriaLabelPrefix,key:o,day:s,month:Jn(n.props.day),onDayClick:n.handleDayClick,onDayMouseEnter:n.handleDayMouseEnter,selected:u,preSelection:d,showWeekNumber:n.props.showWeekNumbers}))),!a;){o++,s=Wd(s,1);var f=i&&o>=o8,p=!i&&!n.isWeekInMonth(s);if(f||p)if(n.props.peekNextMonth)a=!0;else break}return r},n.onMonthClick=function(r,i){var o=n.isMonthDisabledForLabelDate(i),a=o.isDisabled,s=o.labelDate;a||n.handleDayClick(oo(s),r)},n.onMonthMouseEnter=function(r){var i=n.isMonthDisabledForLabelDate(r),o=i.isDisabled,a=i.labelDate;o||n.handleDayMouseEnter(oo(a))},n.handleMonthNavigation=function(r,i){var o,a,s,l;(a=(o=n.props).setPreSelection)===null||a===void 0||a.call(o,i),(l=(s=n.MONTH_REFS[r])===null||s===void 0?void 0:s.current)===null||l===void 0||l.focus()},n.handleKeyboardNavigation=function(r,i,o){var a,s=n.props,l=s.selected,c=s.preSelection,u=s.setPreSelection,d=s.minDate,f=s.maxDate,p=s.showFourColumnMonthYearPicker,m=s.showTwoColumnMonthYearPicker;if(c){var g=UE(p,m),v=n.getVerticalOffset(g),x=(a=kg[g])===null||a===void 0?void 0:a.grid,_=function(P,D,T){var I,A,C=D,j=T;switch(P){case le.ArrowRight:C=ti(D,yf),j=T===11?0:T+yf;break;case le.ArrowLeft:C=Sa(D,yf),j=T===0?11:T-yf;break;case le.ArrowUp:C=Sa(D,v),j=!((I=x?.[0])===null||I===void 0)&&I.includes(T)?T+12-v:T-v;break;case le.ArrowDown:C=ti(D,v),j=!((A=x?.[x.length-1])===null||A===void 0)&&A.includes(T)?T-12+v:T+v;break}return{newCalculatedDate:C,newCalculatedMonth:j}},w=function(P,D,T){for(var I=40,A=P,C=!1,j=0,N=_(A,D,T),M=N.newCalculatedDate,R=N.newCalculatedMonth;!C;){if(j>=I){M=D,R=T;break}if(d&&M<d){A=le.ArrowRight;var B=_(A,M,R);M=B.newCalculatedDate,R=B.newCalculatedMonth}if(f&&M>f){A=le.ArrowLeft;var B=_(A,M,R);M=B.newCalculatedDate,R=B.newCalculatedMonth}if(K3(M,n.props)){var B=_(A,M,R);M=B.newCalculatedDate,R=B.newCalculatedMonth}else C=!0;j++}return{newCalculatedDate:M,newCalculatedMonth:R}};if(i===le.Enter){n.isMonthDisabled(o)||(n.onMonthClick(r,o),u?.(l));return}var y=w(i,c,o),E=y.newCalculatedDate,S=y.newCalculatedMonth;switch(i){case le.ArrowRight:case le.ArrowLeft:case le.ArrowUp:case le.ArrowDown:n.handleMonthNavigation(S,E);break}}},n.getVerticalOffset=function(r){var i,o;return(o=(i=kg[r])===null||i===void 0?void 0:i.verticalNavigationOffset)!==null&&o!==void 0?o:0},n.onMonthKeyDown=function(r,i){var o=n.props,a=o.disabledKeyboardNavigation,s=o.handleOnMonthKeyDown,l=r.key;l!==le.Tab&&r.preventDefault(),a||n.handleKeyboardNavigation(r,l,i),s&&s(r)},n.onQuarterClick=function(r,i){var o=Fs(n.props.day,i);hf(o,n.props)||n.handleDayClick(kE(o),r)},n.onQuarterMouseEnter=function(r){var i=Fs(n.props.day,r);hf(i,n.props)||n.handleDayMouseEnter(kE(i))},n.handleQuarterNavigation=function(r,i){var o,a,s,l;n.isDisabled(i)||n.isExcluded(i)||((a=(o=n.props).setPreSelection)===null||a===void 0||a.call(o,i),(l=(s=n.QUARTER_REFS[r-1])===null||s===void 0?void 0:s.current)===null||l===void 0||l.focus())},n.onQuarterKeyDown=function(r,i){var o,a,s=r.key;if(!n.props.disabledKeyboardNavigation)switch(s){case le.Enter:n.onQuarterClick(r,i),(a=(o=n.props).setPreSelection)===null||a===void 0||a.call(o,n.props.selected);break;case le.ArrowRight:if(!n.props.preSelection)break;n.handleQuarterNavigation(i===4?1:i+1,ng(n.props.preSelection,1));break;case le.ArrowLeft:if(!n.props.preSelection)break;n.handleQuarterNavigation(i===1?4:i-1,Z_(n.props.preSelection));break}},n.isMonthDisabledForLabelDate=function(r){var i,o=n.props,a=o.day,s=o.disabled,l=o.minDate,c=o.maxDate,u=o.excludeDates,d=o.includeDates,f=vr(a,r);return s?{isDisabled:!0,labelDate:vr(a,r)}:{isDisabled:(i=(l||c||u||d)&&TE(f,n.props))!==null&&i!==void 0?i:!1,labelDate:f}},n.isMonthDisabled=function(r){var i=n.isMonthDisabledForLabelDate(r).isDisabled;return i},n.getMonthClassNames=function(r){var i=n.props,o=i.day,a=i.startDate,s=i.endDate,l=i.preSelection,c=i.monthClassName,u=c?c(vr(o,r)):void 0,d=n.getSelection();return ue("react-datepicker__month-text","react-datepicker__month-".concat(r),u,{"react-datepicker__month-text--disabled":n.isMonthDisabled(r),"react-datepicker__month-text--selected":d?n.isSelectMonthInList(o,r,d):void 0,"react-datepicker__month-text--keyboard-selected":!n.props.disabledKeyboardNavigation&&l&&n.isSelectedMonth(o,r,l)&&!n.isMonthSelected()&&!n.isMonthDisabled(r),"react-datepicker__month-text--in-selecting-range":n.isInSelectingRangeMonth(r),"react-datepicker__month-text--in-range":a&&s?pf(a,s,r,o):void 0,"react-datepicker__month-text--range-start":n.isRangeStartMonth(r),"react-datepicker__month-text--range-end":n.isRangeEndMonth(r),"react-datepicker__month-text--selecting-range-start":n.isSelectingMonthRangeStart(r),"react-datepicker__month-text--selecting-range-end":n.isSelectingMonthRangeEnd(r),"react-datepicker__month-text--today":n.isCurrentMonth(o,r)})},n.getTabIndex=function(r){if(n.props.preSelection==null)return"-1";var i=Jn(n.props.preSelection),o=n.isMonthDisabledForLabelDate(i).isDisabled,a=r===i&&!(o||n.props.disabledKeyboardNavigation)?"0":"-1";return a},n.getQuarterTabIndex=function(r){if(n.props.preSelection==null)return"-1";var i=Vo(n.props.preSelection),o=hf(n.props.day,n.props),a=r===i&&!(o||n.props.disabledKeyboardNavigation)?"0":"-1";return a},n.getAriaLabel=function(r){var i=n.props,o=i.chooseDayAriaLabelPrefix,a=o===void 0?"Choose":o,s=i.disabledDayAriaLabelPrefix,l=s===void 0?"Not available":s,c=i.day,u=i.locale,d=vr(c,r),f=n.isDisabled(d)||n.isExcluded(d)?l:a;return"".concat(f," ").concat(mt(d,"MMMM yyyy",u))},n.getQuarterClassNames=function(r){var i=n.props,o=i.day,a=i.startDate,s=i.endDate,l=i.minDate,c=i.maxDate,u=i.excludeDates,d=i.includeDates,f=i.filterDate,p=i.preSelection,m=i.disabledKeyboardNavigation,g=i.disabled,v=(l||c||u||d||f||g)&&hf(Fs(o,r),n.props),x=n.getSelection();return ue("react-datepicker__quarter-text","react-datepicker__quarter-".concat(r),{"react-datepicker__quarter-text--disabled":v,"react-datepicker__quarter-text--selected":x?n.isSelectQuarterInList(o,r,x):void 0,"react-datepicker__quarter-text--keyboard-selected":!m&&p&&n.isSelectedQuarter(o,r,p)&&!n.isQuarterSelected()&&!v,"react-datepicker__quarter-text--in-selecting-range":n.isInSelectingRangeQuarter(r),"react-datepicker__quarter-text--in-range":a&&s?vf(a,s,r,o):void 0,"react-datepicker__quarter-text--range-start":n.isRangeStartQuarter(r),"react-datepicker__quarter-text--range-end":n.isRangeEndQuarter(r),"react-datepicker__quarter-text--today":n.isCurrentQuarter(o,r)})},n.getMonthContent=function(r){var i=n.props,o=i.showFullMonthYearPicker,a=i.renderMonthContent,s=i.locale,l=i.day,c=AE(r,s),u=Eg(r,s);return a?a(r,c,u,l):o?u:c},n.getQuarterContent=function(r){var i,o=n.props,a=o.renderQuarterContent,s=o.locale,l=U3(r,s);return(i=a?.(r,l))!==null&&i!==void 0?i:l},n.renderMonths=function(){var r,i=n.props,o=i.showTwoColumnMonthYearPicker,a=i.showFourColumnMonthYearPicker,s=i.day,l=i.selected,c=(r=kg[UE(a,o)])===null||r===void 0?void 0:r.grid;return c?.map(function(u,d){return k.createElement("div",{className:"react-datepicker__month-wrapper",key:d},u.map(function(f,p){return k.createElement("div",{ref:n.MONTH_REFS[f],key:p,onClick:function(m){n.onMonthClick(m,f)},onKeyDown:function(m){YE(m)&&(m.preventDefault(),m.key=le.Enter),n.onMonthKeyDown(m,f)},onMouseEnter:n.props.usePointerEvent?void 0:function(){return n.onMonthMouseEnter(f)},onPointerEnter:n.props.usePointerEvent?function(){return n.onMonthMouseEnter(f)}:void 0,tabIndex:Number(n.getTabIndex(f)),className:n.getMonthClassNames(f),"aria-disabled":n.isMonthDisabled(f),role:"option","aria-label":n.getAriaLabel(f),"aria-current":n.isCurrentMonth(s,f)?"date":void 0,"aria-selected":l?n.isSelectedMonth(s,f,l):void 0},n.getMonthContent(f))}))})},n.renderQuarters=function(){var r=n.props,i=r.day,o=r.selected,a=[1,2,3,4];return k.createElement("div",{className:"react-datepicker__quarter-wrapper"},a.map(function(s,l){return k.createElement("div",{key:l,ref:n.QUARTER_REFS[l],role:"option",onClick:function(c){n.onQuarterClick(c,s)},onKeyDown:function(c){n.onQuarterKeyDown(c,s)},onMouseEnter:n.props.usePointerEvent?void 0:function(){return n.onQuarterMouseEnter(s)},onPointerEnter:n.props.usePointerEvent?function(){return n.onQuarterMouseEnter(s)}:void 0,className:n.getQuarterClassNames(s),"aria-selected":o?n.isSelectedQuarter(i,s,o):void 0,tabIndex:Number(n.getQuarterTabIndex(s)),"aria-current":n.isCurrentQuarter(i,s)?"date":void 0},n.getQuarterContent(s))}))},n.getClassNames=function(){var r=n.props,i=r.selectingDate,o=r.selectsStart,a=r.selectsEnd,s=r.showMonthYearPicker,l=r.showQuarterYearPicker,c=r.showWeekPicker;return ue("react-datepicker__month",{"react-datepicker__month--selecting-range":i&&(o||a)},{"react-datepicker__monthPicker":s},{"react-datepicker__quarterPicker":l},{"react-datepicker__weekPicker":c})},n}return t.prototype.getSelection=function(){var n=this.props,r=n.selected,i=n.selectedDates,o=n.selectsMultiple;if(o)return i;if(r)return[r]},t.prototype.render=function(){var n=this.props,r=n.showMonthYearPicker,i=n.showQuarterYearPicker,o=n.day,a=n.ariaLabelPrefix,s=a===void 0?"Month ":a,l=s?s.trim()+" ":"",c=er(o)?"".concat(l).concat(mt(o,"MMMM, yyyy",this.props.locale)):"",u=r||i;return u?k.createElement("div",{className:this.getClassNames(),onMouseLeave:this.props.usePointerEvent?void 0:this.handleMouseLeave,onPointerLeave:this.props.usePointerEvent?this.handleMouseLeave:void 0,"aria-label":c,role:"listbox"},r?this.renderMonths():this.renderQuarters()):k.createElement("div",{role:"table"},this.props.dayNamesHeader&&k.createElement("div",{role:"rowgroup"},this.props.dayNamesHeader),this.props.monthHeader&&k.createElement("div",{role:"rowgroup"},this.props.monthHeader),k.createElement("div",{className:this.getClassNames(),onMouseLeave:this.props.usePointerEvent?void 0:this.handleMouseLeave,onPointerLeave:this.props.usePointerEvent?this.handleMouseLeave:void 0,"aria-label":c,role:"rowgroup"},this.renderWeeks()),this.props.monthFooter&&k.createElement("div",{role:"rowgroup"},this.props.monthFooter))},t})(k.Component),s8=(function(e){wn(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.monthOptionButtonsRef={},n.isSelectedMonth=function(r){return n.props.month===r},n.handleOptionKeyDown=function(r,i){var o;switch(i.key){case"Enter":i.preventDefault(),n.onChange(r);break;case"Escape":i.preventDefault(),n.props.onCancel();break;case"ArrowUp":case"ArrowDown":{i.preventDefault();var a=(r+(i.key==="ArrowUp"?-1:1)+n.props.monthNames.length)%n.props.monthNames.length;(o=n.monthOptionButtonsRef[a])===null||o===void 0||o.focus();break}}},n.renderOptions=function(){return n.monthOptionButtonsRef={},n.props.monthNames.map(function(r,i){return k.createElement("div",{ref:function(o){n.monthOptionButtonsRef[i]=o,n.isSelectedMonth(i)&&o?.focus()},role:"button",tabIndex:0,className:n.isSelectedMonth(i)?"react-datepicker__month-option react-datepicker__month-option--selected_month":"react-datepicker__month-option",key:r,onClick:n.onChange.bind(n,i),onKeyDown:n.handleOptionKeyDown.bind(n,i),"aria-selected":n.isSelectedMonth(i)?"true":void 0},n.isSelectedMonth(i)?k.createElement("span",{className:"react-datepicker__month-option--selected"},"✓"):"",r)})},n.onChange=function(r){return n.props.onChange(r)},n.handleClickOutside=function(){return n.props.onCancel()},n}return t.prototype.render=function(){return k.createElement(uf,{className:"react-datepicker__month-dropdown",onClickOutside:this.handleClickOutside},this.renderOptions())},t})(k.Component),l8=(function(e){wn(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.state={dropdownVisible:!1},n.renderSelectOptions=function(r){return r.map(function(i,o){return k.createElement("option",{key:i,value:o},i)})},n.renderSelectMode=function(r){return k.createElement("select",{value:n.props.month,className:"react-datepicker__month-select",onChange:function(i){return n.onChange(parseInt(i.target.value))}},n.renderSelectOptions(r))},n.renderReadView=function(r,i){return k.createElement("button",{key:"read",type:"button",style:{visibility:r?"visible":"hidden"},className:"react-datepicker__month-read-view",onClick:n.toggleDropdown},k.createElement("span",{className:"react-datepicker__month-read-view--down-arrow"}),k.createElement("span",{className:"react-datepicker__month-read-view--selected-month"},i[n.props.month]))},n.renderDropdown=function(r){return k.createElement(s8,Se({key:"dropdown"},n.props,{monthNames:r,onChange:n.onChange,onCancel:n.toggleDropdown}))},n.renderScrollMode=function(r){var i=n.state.dropdownVisible,o=[n.renderReadView(!i,r)];return i&&o.unshift(n.renderDropdown(r)),o},n.onChange=function(r){n.toggleDropdown(),r!==n.props.month&&n.props.onChange(r)},n.toggleDropdown=function(){return n.setState({dropdownVisible:!n.state.dropdownVisible})},n}return t.prototype.render=function(){var n=this,r=[0,1,2,3,4,5,6,7,8,9,10,11].map(this.props.useShortMonthInDropdown?function(o){return AE(o,n.props.locale)}:function(o){return Eg(o,n.props.locale)}),i;switch(this.props.dropdownMode){case"scroll":i=this.renderScrollMode(r);break;case"select":i=this.renderSelectMode(r);break}return k.createElement("div",{className:"react-datepicker__month-dropdown-container react-datepicker__month-dropdown-container--".concat(this.props.dropdownMode)},i)},t})(k.Component),KE=5;function c8(e,t,n){for(var r=[],i=e??Uo(n,KE),o=t??ni(n,KE),a=oo(i),s=oo(o);!no(a,s);)r.push(je(a)),a=ti(a,1);return r}var u8=(function(e){wn(t,e);function t(n){var r=e.call(this,n)||this;return r.renderOptions=function(){return r.state.monthYearsList.map(function(i){var o=lg(i),a=ki(r.props.date,i)&&Un(r.props.date,i);return k.createElement("div",{className:a?"react-datepicker__month-year-option--selected_month-year":"react-datepicker__month-year-option",key:o,onClick:r.onChange.bind(r,o),"aria-selected":a?"true":void 0},a?k.createElement("span",{className:"react-datepicker__month-year-option--selected"},"✓"):"",mt(i,r.props.dateFormat,r.props.locale))})},r.onChange=function(i){return r.props.onChange(i)},r.handleClickOutside=function(){r.props.onCancel()},r.state={monthYearsList:c8(r.props.minDate,r.props.maxDate,r.props.date)},r}return t.prototype.render=function(){var n=ue({"react-datepicker__month-year-dropdown":!0,"react-datepicker__month-year-dropdown--scrollable":this.props.scrollableMonthYearDropdown});return k.createElement(uf,{className:n,onClickOutside:this.handleClickOutside},this.renderOptions())},t})(k.Component),qE=5,d8=(function(e){wn(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.state={dropdownVisible:!1},n.renderSelectOptions=function(){for(var r,i,o=(r=n.props.minDate)!==null&&r!==void 0?r:Uo(n.props.date,qE),a=(i=n.props.maxDate)!==null&&i!==void 0?i:ni(n.props.date,qE),s=oo(o),l=oo(a),c=[];!no(s,l);){var u=lg(s);c.push(k.createElement("option",{key:u,value:u},mt(s,n.props.dateFormat,n.props.locale))),s=ti(s,1)}return c},n.onSelectChange=function(r){n.onChange(parseInt(r.target.value))},n.renderSelectMode=function(){return k.createElement("select",{value:lg(oo(n.props.date)),className:"react-datepicker__month-year-select",onChange:n.onSelectChange},n.renderSelectOptions())},n.renderReadView=function(r){var i=mt(n.props.date,n.props.dateFormat,n.props.locale);return k.createElement("div",{key:"read",style:{visibility:r?"visible":"hidden"},className:"react-datepicker__month-year-read-view",onClick:n.toggleDropdown},k.createElement("span",{className:"react-datepicker__month-year-read-view--down-arrow"}),k.createElement("span",{className:"react-datepicker__month-year-read-view--selected-month-year"},i))},n.renderDropdown=function(){return k.createElement(u8,Se({key:"dropdown"},n.props,{onChange:n.onChange,onCancel:n.toggleDropdown}))},n.renderScrollMode=function(){var r=n.state.dropdownVisible,i=[n.renderReadView(!r)];return r&&i.unshift(n.renderDropdown()),i},n.onChange=function(r){n.toggleDropdown();var i=je(r);ki(n.props.date,i)&&Un(n.props.date,i)||n.props.onChange(i)},n.toggleDropdown=function(){return n.setState({dropdownVisible:!n.state.dropdownVisible})},n}return t.prototype.render=function(){var n;switch(this.props.dropdownMode){case"scroll":n=this.renderScrollMode();break;case"select":n=this.renderSelectMode();break}return k.createElement("div",{className:"react-datepicker__month-year-dropdown-container react-datepicker__month-year-dropdown-container--".concat(this.props.dropdownMode)},n)},t})(k.Component),f8=(function(e){wn(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.state={height:null},n.scrollToTheSelectedTime=function(){requestAnimationFrame(function(){var r,i,o;n.list&&(n.list.scrollTop=(o=n.centerLi&&t.calcCenterPosition(n.props.monthRef?n.props.monthRef.clientHeight-((i=(r=n.header)===null||r===void 0?void 0:r.clientHeight)!==null&&i!==void 0?i:0):n.list.clientHeight,n.centerLi))!==null&&o!==void 0?o:0)})},n.handleClick=function(r){var i,o;(n.props.minTime||n.props.maxTime)&&ME(r,n.props)||(n.props.excludeTimes||n.props.includeTimes||n.props.filterTime)&&jE(r,n.props)||(o=(i=n.props).onChange)===null||o===void 0||o.call(i,r)},n.isSelectedTime=function(r){var i=Da(n.props.selected);return i&&VE(i,r)},n.isDisabledTime=function(r){return(n.props.minTime||n.props.maxTime)&&ME(r,n.props)||(n.props.excludeTimes||n.props.includeTimes||n.props.filterTime)&&jE(r,n.props)},n.liClasses=function(r){var i,o=["react-datepicker__time-list-item",n.props.timeClassName?n.props.timeClassName(r):void 0];return n.isSelectedTime(r)&&o.push("react-datepicker__time-list-item--selected"),n.isDisabledTime(r)&&o.push("react-datepicker__time-list-item--disabled"),n.props.injectTimes&&(An(r)*3600+Tn(r)*60+Yo(r))%(((i=n.props.intervals)!==null&&i!==void 0?i:t.defaultProps.intervals)*60)!==0&&o.push("react-datepicker__time-list-item--injected"),o.join(" ")},n.handleOnKeyDown=function(r,i){var o,a;r.key===le.Space&&(r.preventDefault(),r.key=le.Enter),(r.key===le.ArrowUp||r.key===le.ArrowLeft)&&r.target instanceof HTMLElement&&r.target.previousSibling&&(r.preventDefault(),r.target.previousSibling instanceof HTMLElement&&r.target.previousSibling.focus()),(r.key===le.ArrowDown||r.key===le.ArrowRight)&&r.target instanceof HTMLElement&&r.target.nextSibling&&(r.preventDefault(),r.target.nextSibling instanceof HTMLElement&&r.target.nextSibling.focus()),r.key===le.Enter&&n.handleClick(i),(a=(o=n.props).handleOnKeyDown)===null||a===void 0||a.call(o,r)},n.renderTimes=function(){for(var r,i=[],o=typeof n.props.format=="string"?n.props.format:"p",a=(r=n.props.intervals)!==null&&r!==void 0?r:t.defaultProps.intervals,s=Da(n.props.selected)||Da(n.props.openToDate)||je(),l=gc(s),c=n.props.injectTimes&&n.props.injectTimes.sort(function(v,x){return v.getTime()-x.getTime()}),u=60*t8(s),d=u/a,f=0;f<d;f++){var p=ac(l,f*a);if(i.push(p),c){var m=e8(l,p,f,a,c);i=i.concat(m)}}var g=i.reduce(function(v,x){return x.getTime()<=s.getTime()?x:v},i[0]);return i.map(function(v){return k.createElement("li",{key:v.valueOf(),onClick:n.handleClick.bind(n,v),className:n.liClasses(v),ref:function(x){v===g&&(n.centerLi=x)},onKeyDown:function(x){n.handleOnKeyDown(x,v)},tabIndex:v===g?0:-1,role:"option","aria-selected":n.isSelectedTime(v)?"true":void 0,"aria-disabled":n.isDisabledTime(v)?"true":void 0},mt(v,o,n.props.locale))})},n.renderTimeCaption=function(){return n.props.showTimeCaption===!1?k.createElement(k.Fragment,null):k.createElement("div",{className:"react-datepicker__header react-datepicker__header--time ".concat(n.props.showTimeSelectOnly?"react-datepicker__header--time--only":""),ref:function(r){n.header=r}},k.createElement("div",{className:"react-datepicker-time__header"},n.props.timeCaption))},n}return Object.defineProperty(t,"defaultProps",{get:function(){return{intervals:30,todayButton:null,timeCaption:"Time",showTimeCaption:!0}},enumerable:!1,configurable:!0}),t.prototype.componentDidMount=function(){this.scrollToTheSelectedTime(),this.observeDatePickerHeightChanges()},t.prototype.componentWillUnmount=function(){var n;(n=this.resizeObserver)===null||n===void 0||n.disconnect()},t.prototype.observeDatePickerHeightChanges=function(){var n=this,r=this.props.monthRef;this.updateContainerHeight(),r&&(this.resizeObserver=new ResizeObserver(function(){n.updateContainerHeight()}),this.resizeObserver.observe(r))},t.prototype.updateContainerHeight=function(){if(this.props.monthRef&&this.header){var n=this.props.monthRef.clientHeight-this.header.clientHeight;this.state.height!==n&&this.setState({height:n})}},t.prototype.render=function(){var n=this,r,i=this.state.height;return k.createElement("div",{className:"react-datepicker__time-container ".concat(((r=this.props.todayButton)!==null&&r!==void 0?r:t.defaultProps.todayButton)?"react-datepicker__time-container--with-today-button":"")},this.renderTimeCaption(),k.createElement("div",{className:"react-datepicker__time"},k.createElement("div",{className:"react-datepicker__time-box"},k.createElement("ul",{className:"react-datepicker__time-list",ref:function(o){n.list=o},style:i?{height:i}:{},role:"listbox","aria-label":this.props.timeCaption},this.renderTimes()))))},t.calcCenterPosition=function(n,r){return r.offsetTop-(n/2-r.clientHeight/2)},t})(k.Component),GE=3,p8=(function(e){wn(t,e);function t(n){var r=e.call(this,n)||this;return r.YEAR_REFS=Ci([],Array(r.props.yearItemNumber),!0).map(function(){return k.createRef()}),r.isDisabled=function(i){return Mr(i,{minDate:r.props.minDate,maxDate:r.props.maxDate,excludeDates:r.props.excludeDates,includeDates:r.props.includeDates,filterDate:r.props.filterDate})},r.isExcluded=function(i){return Sg(i,{excludeDates:r.props.excludeDates})},r.selectingDate=function(){var i;return(i=r.props.selectingDate)!==null&&i!==void 0?i:r.props.preSelection},r.updateFocusOnPaginate=function(i){var o=function(){var a,s;(s=(a=r.YEAR_REFS[i])===null||a===void 0?void 0:a.current)===null||s===void 0||s.focus()};window.requestAnimationFrame(o)},r.handleYearClick=function(i,o){r.props.onDayClick&&r.props.onDayClick(i,o)},r.handleYearNavigation=function(i,o){var a,s,l,c,u=r.props,d=u.date,f=u.yearItemNumber;if(!(d===void 0||f===void 0)){var p=ao(d,f).startPeriod;r.isDisabled(o)||r.isExcluded(o)||((s=(a=r.props).setPreSelection)===null||s===void 0||s.call(a,o),i-p<0?r.updateFocusOnPaginate(f-(p-i)):i-p>=f?r.updateFocusOnPaginate(Math.abs(f-(i-p))):(c=(l=r.YEAR_REFS[i-p])===null||l===void 0?void 0:l.current)===null||c===void 0||c.focus())}},r.isSameDay=function(i,o){return Ae(i,o)},r.isCurrentYear=function(i){return i===Ce(je())},r.isRangeStart=function(i){return r.props.startDate&&r.props.endDate&&ki(_i(je(),i),r.props.startDate)},r.isRangeEnd=function(i){return r.props.startDate&&r.props.endDate&&ki(_i(je(),i),r.props.endDate)},r.isInRange=function(i){return mf(i,r.props.startDate,r.props.endDate)},r.isInSelectingRange=function(i){var o=r.props,a=o.selectsStart,s=o.selectsEnd,l=o.selectsRange,c=o.startDate,u=o.endDate;return!(a||s||l)||!r.selectingDate()?!1:a&&u?mf(i,r.selectingDate(),u):s&&c||l&&c&&!u?mf(i,c,r.selectingDate()):!1},r.isSelectingRangeStart=function(i){var o;if(!r.isInSelectingRange(i))return!1;var a=r.props,s=a.startDate,l=a.selectsStart,c=_i(je(),i);return l?ki(c,(o=r.selectingDate())!==null&&o!==void 0?o:null):ki(c,s??null)},r.isSelectingRangeEnd=function(i){var o;if(!r.isInSelectingRange(i))return!1;var a=r.props,s=a.endDate,l=a.selectsEnd,c=a.selectsRange,u=_i(je(),i);return l||c?ki(u,(o=r.selectingDate())!==null&&o!==void 0?o:null):ki(u,s??null)},r.isKeyboardSelected=function(i){if(!(r.props.disabledKeyboardNavigation||r.props.date===void 0||r.props.preSelection==null)){var o=r.props,a=o.minDate,s=o.maxDate,l=o.excludeDates,c=o.includeDates,u=o.filterDate,d=o.selected,f=vc(_i(r.props.date,i)),p=(a||s||l||c||u)&&gf(i,r.props),m=!!d&&Ae(f,vc(d)),g=Ae(f,vc(r.props.preSelection));return!r.props.inline&&!m&&g&&!p}},r.isSelectedYear=function(i){var o=r.props,a=o.selectsMultiple,s=o.selected,l=o.selectedDates;return a?l?.some(function(c){return i===Ce(c)}):!!s&&i===Ce(s)},r.onYearClick=function(i,o){var a=r.props.date;a!==void 0&&r.handleYearClick(vc(_i(a,o)),i)},r.onYearKeyDown=function(i,o){var a,s,l=i.key,c=r.props,u=c.date,d=c.yearItemNumber,f=c.handleOnKeyDown;if(l!==le.Tab&&i.preventDefault(),!r.props.disabledKeyboardNavigation)switch(l){case le.Enter:if(r.props.selected==null)break;r.onYearClick(i,o),(s=(a=r.props).setPreSelection)===null||s===void 0||s.call(a,r.props.selected);break;case le.ArrowRight:if(r.props.preSelection==null)break;r.handleYearNavigation(o+1,ni(r.props.preSelection,1));break;case le.ArrowLeft:if(r.props.preSelection==null)break;r.handleYearNavigation(o-1,Uo(r.props.preSelection,1));break;case le.ArrowUp:{if(u===void 0||d===void 0||r.props.preSelection==null)break;var p=ao(u,d).startPeriod,m=GE,g=o-m;if(g<p){var v=d%m;o>=p&&o<p+v?m=v:m+=v,g=o-m}r.handleYearNavigation(g,Uo(r.props.preSelection,m));break}case le.ArrowDown:{if(u===void 0||d===void 0||r.props.preSelection==null)break;var x=ao(u,d).endPeriod,m=GE,g=o+m;if(g>x){var v=d%m;o<=x&&o>x-v?m=v:m+=v,g=o+m}r.handleYearNavigation(g,ni(r.props.preSelection,m));break}}f&&f(i)},r.getYearClassNames=function(i){var o=r.props,a=o.date,s=o.disabled,l=o.minDate,c=o.maxDate,u=o.excludeDates,d=o.includeDates,f=o.filterDate,p=o.yearClassName;return ue("react-datepicker__year-text","react-datepicker__year-".concat(i),a?p?.(_i(a,i)):void 0,{"react-datepicker__year-text--selected":r.isSelectedYear(i),"react-datepicker__year-text--disabled":(l||c||u||d||f||s)&&gf(i,r.props),"react-datepicker__year-text--keyboard-selected":r.isKeyboardSelected(i),"react-datepicker__year-text--range-start":r.isRangeStart(i),"react-datepicker__year-text--range-end":r.isRangeEnd(i),"react-datepicker__year-text--in-range":r.isInRange(i),"react-datepicker__year-text--in-selecting-range":r.isInSelectingRange(i),"react-datepicker__year-text--selecting-range-start":r.isSelectingRangeStart(i),"react-datepicker__year-text--selecting-range-end":r.isSelectingRangeEnd(i),"react-datepicker__year-text--today":r.isCurrentYear(i)})},r.getYearTabIndex=function(i){if(r.props.disabledKeyboardNavigation||r.props.preSelection==null)return"-1";var o=Ce(r.props.preSelection),a=gf(i,r.props);return i===o&&!a?"0":"-1"},r.getYearContent=function(i){return r.props.renderYearContent?r.props.renderYearContent(i):i},r}return t.prototype.render=function(){var n=this,r=[],i=this.props,o=i.date,a=i.yearItemNumber,s=i.onYearMouseEnter,l=i.onYearMouseLeave;if(o===void 0)return null;for(var c=ao(o,a),u=c.startPeriod,d=c.endPeriod,f=function(g){r.push(k.createElement("div",{ref:p.YEAR_REFS[g-u],onClick:function(v){n.onYearClick(v,g)},onKeyDown:function(v){YE(v)&&(v.preventDefault(),v.key=le.Enter),n.onYearKeyDown(v,g)},tabIndex:Number(p.getYearTabIndex(g)),className:p.getYearClassNames(g),onMouseEnter:p.props.usePointerEvent?void 0:function(v){return s(v,g)},onPointerEnter:p.props.usePointerEvent?function(v){return s(v,g)}:void 0,onMouseLeave:p.props.usePointerEvent?void 0:function(v){return l(v,g)},onPointerLeave:p.props.usePointerEvent?function(v){return l(v,g)}:void 0,key:g,"aria-current":p.isCurrentYear(g)?"date":void 0},p.getYearContent(g)))},p=this,m=u;m<=d;m++)f(m);return k.createElement("div",{className:"react-datepicker__year"},k.createElement("div",{className:"react-datepicker__year-wrapper",onMouseLeave:this.props.usePointerEvent?void 0:this.props.clearSelectingDate,onPointerLeave:this.props.usePointerEvent?this.props.clearSelectingDate:void 0},r))},t})(k.Component);function h8(e,t,n,r){for(var i=[],o=0;o<2*t+1;o++){var a=e+t-o,s=!0;n&&(s=Ce(n)<=a),r&&s&&(s=Ce(r)>=a),s&&i.push(a)}return i}var m8=(function(e){wn(t,e);function t(n){var r=e.call(this,n)||this;r.yearOptionButtonsRef={},r.handleOptionKeyDown=function(s,l){var c;switch(l.key){case"Enter":l.preventDefault(),r.onChange(s);break;case"Escape":l.preventDefault(),r.props.onCancel();break;case"ArrowUp":case"ArrowDown":{l.preventDefault();var u=s+(l.key==="ArrowUp"?1:-1);r.yearOptionButtonsRef[u]&&((c=r.yearOptionButtonsRef[u])===null||c===void 0||c.focus());break}}},r.renderOptions=function(){r.yearOptionButtonsRef={};var s=r.props.year,l=r.state.yearsList.map(function(d){return k.createElement("div",{ref:function(f){r.yearOptionButtonsRef[d]=f,d===s&&f?.focus()},role:"button",tabIndex:0,className:s===d?"react-datepicker__year-option react-datepicker__year-option--selected_year":"react-datepicker__year-option",key:d,onClick:r.onChange.bind(r,d),onKeyDown:r.handleOptionKeyDown.bind(r,d),"aria-selected":s===d?"true":void 0},s===d?k.createElement("span",{className:"react-datepicker__year-option--selected"},"✓"):"",d)}),c=r.props.minDate?Ce(r.props.minDate):null,u=r.props.maxDate?Ce(r.props.maxDate):null;return(!u||!r.state.yearsList.find(function(d){return d===u}))&&l.unshift(k.createElement("div",{className:"react-datepicker__year-option",key:"upcoming",onClick:r.incrementYears},k.createElement("a",{className:"react-datepicker__navigation react-datepicker__navigation--years react-datepicker__navigation--years-upcoming"}))),(!c||!r.state.yearsList.find(function(d){return d===c}))&&l.push(k.createElement("div",{className:"react-datepicker__year-option",key:"previous",onClick:r.decrementYears},k.createElement("a",{className:"react-datepicker__navigation react-datepicker__navigation--years react-datepicker__navigation--years-previous"}))),l},r.onChange=function(s){r.props.onChange(s)},r.handleClickOutside=function(){r.props.onCancel()},r.shiftYears=function(s){var l=r.state.yearsList.map(function(c){return c+s});r.setState({yearsList:l})},r.incrementYears=function(){return r.shiftYears(1)},r.decrementYears=function(){return r.shiftYears(-1)};var i=n.yearDropdownItemNumber,o=n.scrollableYearDropdown,a=i||(o?10:5);return r.state={yearsList:h8(r.props.year,a,r.props.minDate,r.props.maxDate)},r.dropdownRef=k.createRef(),r}return t.prototype.componentDidMount=function(){var n=this.dropdownRef.current;if(n){var r=n.children?Array.from(n.children):null,i=r?r.find(function(o){return o.ariaSelected}):null;n.scrollTop=i&&i instanceof HTMLElement?i.offsetTop+(i.clientHeight-n.clientHeight)/2:(n.scrollHeight-n.clientHeight)/2}},t.prototype.render=function(){var n=ue({"react-datepicker__year-dropdown":!0,"react-datepicker__year-dropdown--scrollable":this.props.scrollableYearDropdown});return k.createElement(uf,{className:n,containerRef:this.dropdownRef,onClickOutside:this.handleClickOutside},this.renderOptions())},t})(k.Component),g8=(function(e){wn(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.state={dropdownVisible:!1},n.renderSelectOptions=function(){for(var r=n.props.minDate?Ce(n.props.minDate):1900,i=n.props.maxDate?Ce(n.props.maxDate):2100,o=[],a=r;a<=i;a++)o.push(k.createElement("option",{key:a,value:a},a));return o},n.onSelectChange=function(r){n.onChange(parseInt(r.target.value))},n.renderSelectMode=function(){return k.createElement("select",{value:n.props.year,className:"react-datepicker__year-select",onChange:n.onSelectChange},n.renderSelectOptions())},n.renderReadView=function(r){return k.createElement("button",{key:"read",type:"button",style:{visibility:r?"visible":"hidden"},className:"react-datepicker__year-read-view",onClick:n.toggleDropdown},k.createElement("span",{className:"react-datepicker__year-read-view--down-arrow"}),k.createElement("span",{className:"react-datepicker__year-read-view--selected-year"},n.props.year))},n.renderDropdown=function(){return k.createElement(m8,Se({key:"dropdown"},n.props,{onChange:n.onChange,onCancel:n.toggleDropdown}))},n.renderScrollMode=function(){var r=n.state.dropdownVisible,i=[n.renderReadView(!r)];return r&&i.unshift(n.renderDropdown()),i},n.onChange=function(r){n.toggleDropdown(),r!==n.props.year&&n.props.onChange(r)},n.toggleDropdown=function(r){n.setState({dropdownVisible:!n.state.dropdownVisible},function(){n.props.adjustDateOnChange&&n.handleYearChange(n.props.date,r)})},n.handleYearChange=function(r,i){var o;(o=n.onSelect)===null||o===void 0||o.call(n,r,i),n.setOpen()},n.onSelect=function(r,i){var o,a;(a=(o=n.props).onSelect)===null||a===void 0||a.call(o,r,i)},n.setOpen=function(){var r,i;(i=(r=n.props).setOpen)===null||i===void 0||i.call(r,!0)},n}return t.prototype.render=function(){var n;switch(this.props.dropdownMode){case"scroll":n=this.renderScrollMode();break;case"select":n=this.renderSelectMode();break}return k.createElement("div",{className:"react-datepicker__year-dropdown-container react-datepicker__year-dropdown-container--".concat(this.props.dropdownMode)},n)},t})(k.Component),v8=["react-datepicker__year-select","react-datepicker__month-select","react-datepicker__month-year-select"],XE="react-datepicker-ignore-onclickoutside",y8=function(e){var t=(e.className||"").split(/\s+/);return v8.some(function(n){return t.indexOf(n)>=0})},b8=(function(e){wn(t,e);function t(n){var r=e.call(this,n)||this;return r.monthContainer=void 0,r.handleClickOutside=function(i){r.props.onClickOutside(i)},r.setClickOutsideRef=function(){return r.containerRef.current},r.handleDropdownFocus=function(i){var o,a;y8(i.target)&&((a=(o=r.props).onDropdownFocus)===null||a===void 0||a.call(o,i))},r.getDateInView=function(){var i=r.props,o=i.preSelection,a=i.selected,s=i.openToDate,l=$E(r.props),c=BE(r.props),u=je(),d=s||a||o;return d||(l&&bi(u,l)?l:c&&no(u,c)?c:u)},r.increaseMonth=function(){r.setState(function(i){var o=i.date;return{date:ti(o,1)}},function(){return r.handleMonthChange(r.state.date)})},r.decreaseMonth=function(){r.setState(function(i){var o=i.date;return{date:Sa(o,1)}},function(){return r.handleMonthChange(r.state.date)})},r.handleDayClick=function(i,o,a){r.props.onSelect(i,o,a),r.props.setPreSelection&&r.props.setPreSelection(i)},r.handleDayMouseEnter=function(i){r.setState({selectingDate:i}),r.props.onDayMouseEnter&&r.props.onDayMouseEnter(i)},r.handleMonthMouseLeave=function(){r.setState({selectingDate:void 0}),r.props.onMonthMouseLeave&&r.props.onMonthMouseLeave()},r.handleYearMouseEnter=function(i,o){r.setState({selectingDate:_i(je(),o)}),r.props.onYearMouseEnter&&r.props.onYearMouseEnter(i,o)},r.handleYearMouseLeave=function(i,o){r.props.onYearMouseLeave&&r.props.onYearMouseLeave(i,o)},r.handleYearChange=function(i){var o,a,s,l;(a=(o=r.props).onYearChange)===null||a===void 0||a.call(o,i),r.setState({isRenderAriaLiveMessage:!0}),r.props.adjustDateOnChange&&(r.props.onSelect(i),(l=(s=r.props).setOpen)===null||l===void 0||l.call(s,!0)),r.props.setPreSelection&&r.props.setPreSelection(i)},r.getEnabledPreSelectionDateForMonth=function(i){if(!Mr(i,r.props))return i;for(var o=oo(i),a=z3(i),s=t5(a,o),l=null,c=0;c<=s;c++){var u=ei(o,c);if(!Mr(u,r.props)){l=u;break}}return l},r.handleMonthChange=function(i){var o,a,s,l=(o=r.getEnabledPreSelectionDateForMonth(i))!==null&&o!==void 0?o:i;r.handleCustomMonthChange(l),r.props.adjustDateOnChange&&(r.props.onSelect(l),(s=(a=r.props).setOpen)===null||s===void 0||s.call(a,!0)),r.props.setPreSelection&&r.props.setPreSelection(l)},r.handleCustomMonthChange=function(i){var o,a;(a=(o=r.props).onMonthChange)===null||a===void 0||a.call(o,i),r.setState({isRenderAriaLiveMessage:!0})},r.handleMonthYearChange=function(i){r.handleYearChange(i),r.handleMonthChange(i)},r.changeYear=function(i){r.setState(function(o){var a=o.date;return{date:_i(a,Number(i))}},function(){return r.handleYearChange(r.state.date)})},r.changeMonth=function(i){r.setState(function(o){var a=o.date;return{date:vr(a,Number(i))}},function(){var o,a;r.handleMonthChange(r.state.date),(a=(o=r.props).onMonthSelectedInChange)===null||a===void 0||a.call(o,0)})},r.changeMonthYear=function(i){r.setState(function(o){var a=o.date;return{date:_i(vr(a,Jn(i)),Ce(i))}},function(){return r.handleMonthYearChange(r.state.date)})},r.header=function(i,o){if(i===void 0&&(i=r.state.date),o===void 0&&(o=0),!er(i))return[];var a=r.props.disabled,s=qo(i,r.props.locale,r.props.calendarStartDay),l=[];return r.props.showWeekNumbers&&l.push(k.createElement("div",{key:"W",className:"react-datepicker__day-name ".concat(a?"react-datepicker__day-name--disabled":""),role:"columnheader"},k.createElement("span",{className:"react-datepicker__sr-only"},"Week number"),k.createElement("span",{"aria-hidden":"true"},r.props.weekLabel||"#"))),l.concat([0,1,2,3,4,5,6].map(function(c){var u=ei(s,c),d=r.formatWeekday(u,r.props.locale),f=mt(u,"EEEE",r.props.locale),p=r.props.weekDayClassName?r.props.weekDayClassName(u):void 0;if(r.props.renderCustomDayName){var m=r.props.renderCustomDayName({day:u,shortName:d,fullName:f,locale:r.props.locale,customDayNameCount:o});return k.createElement("div",{key:c,role:"columnheader",className:ue("react-datepicker__day-name",p,a?"react-datepicker__day-name--disabled":"")},m)}return k.createElement("div",{key:c,role:"columnheader",className:ue("react-datepicker__day-name",p,a?"react-datepicker__day-name--disabled":"")},k.createElement("span",{className:"react-datepicker__sr-only"},f),k.createElement("span",{"aria-hidden":"true"},d))}))},r.formatWeekday=function(i,o){return r.props.formatWeekDay?V3(i,r.props.formatWeekDay,o):r.props.useWeekdaysShort?Y3(i,o):H3(i,o)},r.decreaseYear=function(){r.setState(function(i){var o,a=i.date;return{date:Uo(a,r.props.showYearPicker?(o=r.props.yearItemNumber)!==null&&o!==void 0?o:t.defaultProps.yearItemNumber:1)}},function(){return r.handleYearChange(r.state.date)})},r.clearSelectingDate=function(){r.setState({selectingDate:void 0})},r.renderPreviousButton=function(){var i,o,a;if(!r.props.renderCustomHeader){var s=(i=r.props.monthsShown)!==null&&i!==void 0?i:t.defaultProps.monthsShown,l=r.props.showPreviousMonths?s-1:0,c=(o=r.props.monthSelectedIn)!==null&&o!==void 0?o:l,u=Sa(r.state.date,c),d;switch(!0){case r.props.disabled:d=!0;break;case r.props.showMonthYearPicker:d=LE(r.state.date,r.props);break;case r.props.showYearPicker:d=X3(r.state.date,r.props);break;case r.props.showQuarterYearPicker:d=q3(r.state.date,r.props);break;default:d=IE(u,r.props);break}if(!(!((a=r.props.forceShowMonthNavigation)!==null&&a!==void 0?a:t.defaultProps.forceShowMonthNavigation)&&!r.props.showDisabledMonthNavigation&&d||r.props.showTimeSelectOnly)){var f=["react-datepicker__navigation-icon","react-datepicker__navigation-icon--previous"],p=["react-datepicker__navigation","react-datepicker__navigation--previous"],m=r.decreaseMonth;(r.props.showMonthYearPicker||r.props.showQuarterYearPicker||r.props.showYearPicker)&&(m=r.decreaseYear),d&&r.props.showDisabledMonthNavigation&&(p.push("react-datepicker__navigation--previous--disabled"),m=void 0);var g=r.props.showMonthYearPicker||r.props.showQuarterYearPicker||r.props.showYearPicker,v=r.props,x=v.previousMonthButtonLabel,_=x===void 0?t.defaultProps.previousMonthButtonLabel:x,w=v.previousYearButtonLabel,y=w===void 0?t.defaultProps.previousYearButtonLabel:w,E=r.props,S=E.previousMonthAriaLabel,P=S===void 0?typeof _=="string"?_:"Previous Month":S,D=E.previousYearAriaLabel,T=D===void 0?typeof y=="string"?y:"Previous Year":D;return k.createElement("button",{type:"button",className:p.join(" "),onClick:m,onKeyDown:r.props.handleOnKeyDown,"aria-label":g?T:P},k.createElement("span",{className:f.join(" ")},g?y:_))}}},r.increaseYear=function(){r.setState(function(i){var o,a=i.date;return{date:ni(a,r.props.showYearPicker?(o=r.props.yearItemNumber)!==null&&o!==void 0?o:t.defaultProps.yearItemNumber:1)}},function(){return r.handleYearChange(r.state.date)})},r.renderNextButton=function(){var i;if(!r.props.renderCustomHeader){var o;switch(!0){case r.props.disabled:o=!0;break;case r.props.showMonthYearPicker:o=RE(r.state.date,r.props);break;case r.props.showYearPicker:o=Q3(r.state.date,r.props);break;case r.props.showQuarterYearPicker:o=G3(r.state.date,r.props);break;default:o=FE(r.state.date,r.props);break}if(!(!((i=r.props.forceShowMonthNavigation)!==null&&i!==void 0?i:t.defaultProps.forceShowMonthNavigation)&&!r.props.showDisabledMonthNavigation&&o||r.props.showTimeSelectOnly)){var a=["react-datepicker__navigation","react-datepicker__navigation--next"],s=["react-datepicker__navigation-icon","react-datepicker__navigation-icon--next"];r.props.showTimeSelect&&a.push("react-datepicker__navigation--next--with-time"),r.props.todayButton&&a.push("react-datepicker__navigation--next--with-today-button");var l=r.increaseMonth;(r.props.showMonthYearPicker||r.props.showQuarterYearPicker||r.props.showYearPicker)&&(l=r.increaseYear),o&&r.props.showDisabledMonthNavigation&&(a.push("react-datepicker__navigation--next--disabled"),l=void 0);var c=r.props.showMonthYearPicker||r.props.showQuarterYearPicker||r.props.showYearPicker,u=r.props,d=u.nextMonthButtonLabel,f=d===void 0?t.defaultProps.nextMonthButtonLabel:d,p=u.nextYearButtonLabel,m=p===void 0?t.defaultProps.nextYearButtonLabel:p,g=r.props,v=g.nextMonthAriaLabel,x=v===void 0?typeof f=="string"?f:"Next Month":v,_=g.nextYearAriaLabel,w=_===void 0?typeof m=="string"?m:"Next Year":_;return k.createElement("button",{type:"button",className:a.join(" "),onClick:l,onKeyDown:r.props.handleOnKeyDown,"aria-label":c?w:x},k.createElement("span",{className:s.join(" ")},c?m:f))}}},r.renderCurrentMonth=function(i){i===void 0&&(i=r.state.date);var o=["react-datepicker__current-month"];return r.props.showYearDropdown&&o.push("react-datepicker__current-month--hasYearDropdown"),r.props.showMonthDropdown&&o.push("react-datepicker__current-month--hasMonthDropdown"),r.props.showMonthYearDropdown&&o.push("react-datepicker__current-month--hasMonthYearDropdown"),k.createElement("h2",{className:o.join(" ")},er(i)?mt(i,r.props.dateFormat,r.props.locale):"")},r.renderYearDropdown=function(i){if(i===void 0&&(i=!1),!(!r.props.showYearDropdown||i))return k.createElement(g8,Se({},t.defaultProps,r.props,{date:r.state.date,onChange:r.changeYear,year:Ce(r.state.date)}))},r.renderMonthDropdown=function(i){if(i===void 0&&(i=!1),!(!r.props.showMonthDropdown||i))return k.createElement(l8,Se({},t.defaultProps,r.props,{month:Jn(r.state.date),onChange:r.changeMonth}))},r.renderMonthYearDropdown=function(i){if(i===void 0&&(i=!1),!(!r.props.showMonthYearDropdown||i))return k.createElement(d8,Se({},t.defaultProps,r.props,{date:r.state.date,onChange:r.changeMonthYear}))},r.handleTodayButtonClick=function(i){r.props.onSelect(PE(),i),r.props.setPreSelection&&r.props.setPreSelection(PE())},r.renderTodayButton=function(){if(!(!r.props.todayButton||r.props.showTimeSelectOnly))return k.createElement("div",{className:"react-datepicker__today-button",onClick:r.handleTodayButtonClick},r.props.todayButton)},r.renderDayNamesHeader=function(i,o){return o===void 0&&(o=0),k.createElement("div",{className:"react-datepicker__day-names",role:"row"},r.header(i,o))},r.renderDefaultHeader=function(i){var o=i.monthDate,a=i.i,s=k.createElement("div",{className:ue("react-datepicker__header",{"react-datepicker__header--has-time-select":r.props.showTimeSelect,"react-datepicker__header--middle":r.props.monthHeaderPosition==="middle","react-datepicker__header--bottom":r.props.monthHeaderPosition==="bottom"})},r.renderCurrentMonth(o),k.createElement("div",{className:"react-datepicker__header__dropdown react-datepicker__header__dropdown--".concat(r.props.dropdownMode),onFocus:r.handleDropdownFocus},r.renderMonthDropdown(a!==0),r.renderMonthYearDropdown(a!==0),r.renderYearDropdown(a!==0)));return r.props.monthHeaderPosition==="top"?s:k.createElement("div",{className:"react-datepicker__header-wrapper"},r.renderPreviousButton()||null,r.renderNextButton()||null,s)},r.renderCustomHeader=function(i){var o,a,s=i.monthDate,l=i.i;if(r.props.showTimeSelect&&!r.state.monthContainer||r.props.showTimeSelectOnly)return null;var c=r.props,u=c.showYearPicker,d=c.yearItemNumber,f;if(u){var p=ao(s,d),m=p.startPeriod,g=p.endPeriod;f={startYear:m,endYear:g}}var v=IE(r.state.date,r.props),x=FE(r.state.date,r.props),_=LE(r.state.date,r.props),w=RE(r.state.date,r.props);return k.createElement("div",{className:"react-datepicker__header react-datepicker__header--custom",onFocus:r.props.onDropdownFocus},(a=(o=r.props).renderCustomHeader)===null||a===void 0?void 0:a.call(o,Se(Se(Se({},r.state),u&&{visibleYearsRange:f}),{customHeaderCount:l,monthDate:s,changeMonth:r.changeMonth,changeYear:r.changeYear,decreaseMonth:r.decreaseMonth,increaseMonth:r.increaseMonth,decreaseYear:r.decreaseYear,increaseYear:r.increaseYear,prevMonthButtonDisabled:v,nextMonthButtonDisabled:x,prevYearButtonDisabled:_,nextYearButtonDisabled:w})))},r.renderYearHeader=function(i){var o=i.monthDate,a=r.props,s=a.showYearPicker,l=a.yearItemNumber,c=l===void 0?t.defaultProps.yearItemNumber:l,u=ao(o,c),d=u.startPeriod,f=u.endPeriod;return k.createElement("div",{className:"react-datepicker__header react-datepicker-year-header"},s?"".concat(d," - ").concat(f):Ce(o))},r.renderHeader=function(i){var o=i.monthDate,a=i.i,s=a===void 0?0:a,l={monthDate:o,i:s};switch(!0){case r.props.renderCustomHeader!==void 0:return r.renderCustomHeader(l);case(r.props.showMonthYearPicker||r.props.showQuarterYearPicker||r.props.showYearPicker):return r.renderYearHeader(l);default:return r.renderDefaultHeader(l)}},r.renderMonths=function(){var i,o;if(!(r.props.showTimeSelectOnly||r.props.showYearPicker)){for(var a=[],s=(i=r.props.monthsShown)!==null&&i!==void 0?i:t.defaultProps.monthsShown,l=r.props.showPreviousMonths?s-1:0,c=r.props.showMonthYearPicker||r.props.showQuarterYearPicker?ni(r.state.date,l):Sa(r.state.date,l),u=(o=r.props.monthSelectedIn)!==null&&o!==void 0?o:l,d=0;d<s;++d){var f=d-u+l,p=r.props.showMonthYearPicker||r.props.showQuarterYearPicker?ni(c,f):ti(c,f),m="month-".concat(d),g=d<s-1,v=d>0;a.push(k.createElement("div",{key:m,ref:function(x){r.monthContainer=x??void 0},className:"react-datepicker__month-container"},r.props.monthHeaderPosition==="top"&&r.renderHeader({monthDate:p,i:d}),k.createElement(a8,Se({},t.defaultProps,r.props,{containerRef:r.containerRef,ariaLabelPrefix:r.props.monthAriaLabelPrefix,day:p,onDayClick:r.handleDayClick,handleOnKeyDown:r.props.handleOnDayKeyDown,handleOnMonthKeyDown:r.props.handleOnKeyDown,onDayMouseEnter:r.handleDayMouseEnter,onMouseLeave:r.handleMonthMouseLeave,orderInDisplay:d,selectingDate:r.state.selectingDate,monthShowsDuplicateDaysEnd:g,monthShowsDuplicateDaysStart:v,dayNamesHeader:r.renderDayNamesHeader(p,d),monthHeader:r.props.monthHeaderPosition==="middle"?r.renderHeader({monthDate:p,i:d}):void 0,monthFooter:r.props.monthHeaderPosition==="bottom"?r.renderHeader({monthDate:p,i:d}):void 0}))))}return a}},r.renderYears=function(){if(!r.props.showTimeSelectOnly&&r.props.showYearPicker)return k.createElement("div",{className:"react-datepicker__year--container"},r.renderHeader({monthDate:r.state.date}),k.createElement(p8,Se({},t.defaultProps,r.props,{selectingDate:r.state.selectingDate,date:r.state.date,onDayClick:r.handleDayClick,clearSelectingDate:r.clearSelectingDate,onYearMouseEnter:r.handleYearMouseEnter,onYearMouseLeave:r.handleYearMouseLeave})))},r.renderTimeSection=function(){if(r.props.showTimeSelect&&(r.state.monthContainer||r.props.showTimeSelectOnly))return k.createElement(f8,Se({},t.defaultProps,r.props,{onChange:r.props.onTimeChange,format:r.props.timeFormat,intervals:r.props.timeIntervals,monthRef:r.state.monthContainer}))},r.renderInputTimeSection=function(){var i,o;if(r.props.showTimeInput){if(r.props.selectsRange){var a=r.props,s=a.startDate,l=a.endDate,c=s?new Date(s):void 0,u=c&&er(c)&&!!s,d=u?"".concat(Vs(c.getHours()),":").concat(Vs(c.getMinutes())):"",f=l?new Date(l):void 0,p=f&&er(f)&&!!l,m=p?"".concat(Vs(f.getHours()),":").concat(Vs(f.getMinutes())):"";return k.createElement(k.Fragment,null,k.createElement(Cg,Se({},t.defaultProps,r.props,{date:c,timeString:d,onChange:function(_){var w,y;(y=(w=r.props).onTimeChange)===null||y===void 0||y.call(w,_,"start")},timeInputLabel:((i=r.props.timeInputLabel)!==null&&i!==void 0?i:"Time")+" (Start)"})),k.createElement(Cg,Se({},t.defaultProps,r.props,{date:f,timeString:m,onChange:function(_){var w,y;(y=(w=r.props).onTimeChange)===null||y===void 0||y.call(w,_,"end")},timeInputLabel:((o=r.props.timeInputLabel)!==null&&o!==void 0?o:"Time")+" (End)"})))}var g=r.props.selected?new Date(r.props.selected):void 0,v=g&&er(g)&&!!r.props.selected,x=v?"".concat(Vs(g.getHours()),":").concat(Vs(g.getMinutes())):"";return k.createElement(Cg,Se({},t.defaultProps,r.props,{date:g,timeString:x,onChange:function(_){var w,y;(y=(w=r.props).onTimeChange)===null||y===void 0||y.call(w,_)}}))}},r.renderAriaLiveRegion=function(){var i;if(!er(r.state.date))return k.createElement("span",{role:"alert","aria-live":"polite",className:"react-datepicker__aria-live"});var o=ao(r.state.date,(i=r.props.yearItemNumber)!==null&&i!==void 0?i:t.defaultProps.yearItemNumber),a=o.startPeriod,s=o.endPeriod,l;return r.props.showYearPicker?l="".concat(a," - ").concat(s):r.props.showMonthYearPicker||r.props.showQuarterYearPicker?l=Ce(r.state.date):l="".concat(Eg(Jn(r.state.date),r.props.locale)," ").concat(Ce(r.state.date)),k.createElement("span",{role:"alert","aria-live":"polite",className:"react-datepicker__aria-live"},r.state.isRenderAriaLiveMessage&&l)},r.renderChildren=function(){if(r.props.children)return k.createElement("div",{className:"react-datepicker__children-container"},r.props.children)},r.containerRef=k.createRef(),r.state={date:r.getDateInView(),selectingDate:void 0,monthContainer:void 0,isRenderAriaLiveMessage:!1},r}return Object.defineProperty(t,"defaultProps",{get:function(){return{monthsShown:1,forceShowMonthNavigation:!1,outsideClickIgnoreClass:XE,timeCaption:"Time",previousYearButtonLabel:"Previous Year",nextYearButtonLabel:"Next Year",previousMonthButtonLabel:"Previous Month",nextMonthButtonLabel:"Next Month",yearItemNumber:mc,monthHeaderPosition:"top"}},enumerable:!1,configurable:!0}),t.prototype.componentDidMount=function(){var n=this;this.props.showTimeSelect&&(this.assignMonthContainer=(function(){n.setState({monthContainer:n.monthContainer})})())},t.prototype.componentDidUpdate=function(n){var r=this;if(this.props.preSelection&&er(this.props.preSelection)&&(!Ae(this.props.preSelection,n.preSelection)||this.props.monthSelectedIn!==n.monthSelectedIn)){var i=!Un(this.state.date,this.props.preSelection);this.setState({date:this.props.preSelection},function(){return i&&r.handleCustomMonthChange(r.state.date)})}else this.props.openToDate&&!Ae(this.props.openToDate,n.openToDate)&&this.setState({date:this.props.openToDate})},t.prototype.render=function(){var n=this.props.container||M3;return k.createElement(uf,{onClickOutside:this.handleClickOutside,style:{display:"contents"},ignoreClass:this.props.outsideClickIgnoreClass},k.createElement("div",{style:{display:"contents"},ref:this.containerRef},k.createElement(n,{className:ue("react-datepicker",this.props.className,{"react-datepicker--time-only":this.props.showTimeSelectOnly}),showTime:this.props.showTimeSelect||this.props.showTimeInput,showTimeSelectOnly:this.props.showTimeSelectOnly,inline:this.props.inline},this.renderAriaLiveRegion(),this.props.monthHeaderPosition==="top"&&this.renderPreviousButton(),this.props.monthHeaderPosition==="top"&&this.renderNextButton(),this.renderMonths(),this.renderYears(),this.renderTodayButton(),this.renderTimeSection(),this.renderInputTimeSection(),this.renderChildren())))},t})(k.Component),x8=function(e){var t=e.icon,n=e.className,r=n===void 0?"":n,i=e.onClick,o="react-datepicker__calendar-icon";if(typeof t=="string")return k.createElement("i",{className:"".concat(o," ").concat(t," ").concat(r),"aria-hidden":"true",onClick:i});if(k.isValidElement(t)){var a=t;return k.cloneElement(a,{className:"".concat(a.props.className||""," ").concat(o," ").concat(r),onClick:function(s){typeof a.props.onClick=="function"&&a.props.onClick(s),typeof i=="function"&&i(s)}})}return k.createElement("svg",{className:"".concat(o," ").concat(r),xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 448 512",onClick:i},k.createElement("path",{d:"M96 32V64H48C21.5 64 0 85.5 0 112v48H448V112c0-26.5-21.5-48-48-48H352V32c0-17.7-14.3-32-32-32s-32 14.3-32 32V64H160V32c0-17.7-14.3-32-32-32S96 14.3 96 32zM448 192H0V464c0 26.5 21.5 48 48 48H400c26.5 0 48-21.5 48-48V192z"}))},QE=(function(e){wn(t,e);function t(n){var r=e.call(this,n)||this;return r.portalRoot=null,r.el=document.createElement("div"),r}return t.prototype.componentDidMount=function(){this.portalRoot=(this.props.portalHost||document).getElementById(this.props.portalId),this.portalRoot||(this.portalRoot=document.createElement("div"),this.portalRoot.setAttribute("id",this.props.portalId),(this.props.portalHost||document.body).appendChild(this.portalRoot)),this.portalRoot.appendChild(this.el)},t.prototype.componentWillUnmount=function(){this.portalRoot&&this.portalRoot.removeChild(this.el)},t.prototype.render=function(){return fi.createPortal(this.props.children,this.el)},t})(k.Component),w8="[tabindex], a, button, input, select, textarea",_8=function(e){return(e instanceof HTMLAnchorElement||!e.disabled)&&e.tabIndex!==-1},ZE=(function(e){wn(t,e);function t(n){var r=e.call(this,n)||this;return r.getTabChildren=function(){var i;return Array.prototype.slice.call((i=r.tabLoopRef.current)===null||i===void 0?void 0:i.querySelectorAll(w8),1,-1).filter(_8)},r.handleFocusStart=function(){var i=r.getTabChildren();i&&i.length>1&&i[i.length-1].focus()},r.handleFocusEnd=function(){var i=r.getTabChildren();i&&i.length>1&&i[0].focus()},r.tabLoopRef=k.createRef(),r}return t.prototype.render=function(){var n;return((n=this.props.enableTabLoop)!==null&&n!==void 0?n:t.defaultProps.enableTabLoop)?k.createElement("div",{className:"react-datepicker__tab-loop",ref:this.tabLoopRef},k.createElement("div",{className:"react-datepicker__tab-loop__start",tabIndex:0,onFocus:this.handleFocusStart}),this.props.children,k.createElement("div",{className:"react-datepicker__tab-loop__end",tabIndex:0,onFocus:this.handleFocusEnd})):this.props.children},t.defaultProps={enableTabLoop:!0},t})(k.Component);function E8(e){function t(n){var r,i=typeof n.hidePopper=="boolean"?n.hidePopper:!0,o=k.useRef(null),a=j3(Se({open:!i,whileElementsMounted:u3,placement:n.popperPlacement,middleware:Ci([b3({padding:15}),y3(10),x3({element:o})],(r=n.popperModifiers)!==null&&r!==void 0?r:[],!0)},n.popperProps)),s=Se(Se({},n),{hidePopper:i,popperProps:Se(Se({},a),{arrowRef:o})});return k.createElement(e,Se({},s))}return t.displayName="withFloating(".concat(e.displayName||e.name||"Component",")"),t}var S8=function(e){var t=e.className,n=e.wrapperClassName,r=e.hidePopper,i=r===void 0?!0:r,o=e.popperComponent,a=e.targetComponent,s=e.enableTabLoop,l=e.popperOnKeyDown,c=e.portalId,u=e.portalHost,d=e.popperProps,f=e.showArrow,p=e.popperTargetRef,m=e.monthHeaderPosition;k.useEffect(function(){p?.current&&d.refs.setPositionReference(p.current)},[p,d.refs]);var g=void 0;if(!i){var v=ue("react-datepicker-popper",!f&&"react-datepicker-popper-offset",m==="middle"&&"react-datepicker-popper--header-middle",m==="bottom"&&"react-datepicker-popper--header-bottom",t);g=k.createElement(ZE,{enableTabLoop:s},k.createElement("div",{ref:d.refs.setFloating,style:d.floatingStyles,className:v,"data-placement":d.placement,onKeyDown:l},o,f&&k.createElement(C3,{ref:d.arrowRef,context:d.context,fill:"currentColor",strokeWidth:1,height:8,width:16,style:{transform:"translateY(-1px)"},className:"react-datepicker__triangle"})))}e.popperContainer&&(g=k.createElement(e.popperContainer,{},g)),c&&!i&&(g=k.createElement(QE,{portalId:c,portalHost:u},g));var x=ue("react-datepicker-wrapper",n);return k.createElement(k.Fragment,null,k.createElement("div",{ref:d.refs.setReference,className:x},a),g)},O8=E8(S8);function JE(e,t){return e&&t?Jn(e)!==Jn(t)||Ce(e)!==Ce(t):e!==t}var Pg="Date input not valid.",eS=(function(e){wn(t,e);function t(n){var r=e.call(this,n)||this;return r.calendar=null,r.input=null,r.getPreSelection=function(){var i=r.props.timeZone,o=r.props.openToDate?r.props.openToDate:r.props.selectsEnd&&r.props.startDate?r.props.startDate:r.props.selectsStart&&r.props.endDate?r.props.endDate:je();return i?SE(o,i):o},r.modifyHolidays=function(){var i;return(i=r.props.holidays)===null||i===void 0?void 0:i.reduce(function(o,a){var s=Pa(a.date,"yyyy-MM-dd",void 0,!1);return s?Ci(Ci([],o,!0),[Se(Se({},a),{date:s})],!1):o},[])},r.calcInitialState=function(){var i=r.props.timeZone,o=r.getPreSelection(),a=$E(r.props),s=BE(r.props),l=a&&bi(o,gc(a))?a:s&&no(o,DE(s))?s:o,c=r.props.selectsRange?r.props.startDate:r.props.selected;return c&&i&&(c=SE(c,i)),{open:r.props.startOpen||!1,preventFocus:!1,inputValue:null,preSelection:c??l,highlightDates:WE(r.props.highlightDates),focused:!1,shouldFocusDayInline:!1,isRenderAriaLiveMessage:!1,wasHidden:!1}},r.getInputValue=function(){var i,o=r.props,a=o.locale,s=o.startDate,l=o.endDate,c=o.rangeSeparator,u=o.selected,d=o.selectedDates,f=o.selectsMultiple,p=o.selectsRange,m=o.formatMultipleDates,g=o.value,v=(i=r.props.dateFormat)!==null&&i!==void 0?i:t.defaultProps.dateFormat,x=r.state.inputValue;if(typeof g=="string")return g;if(typeof x=="string")return x;if(p)return L3(s,l,{dateFormat:v,locale:a,rangeSeparator:c});if(f){if(m){var _=function(w){return tr(w,{dateFormat:v,locale:a})};return m(d??[],_)}return R3(d??[],{dateFormat:v,locale:a})}return tr(u,{dateFormat:v,locale:a})},r.resetHiddenStatus=function(){r.setState(Se(Se({},r.state),{wasHidden:!1}))},r.setHiddenStatus=function(){r.setState(Se(Se({},r.state),{wasHidden:!0}))},r.setHiddenStateOnVisibilityHidden=function(){document.visibilityState==="hidden"&&r.setHiddenStatus()},r.clearPreventFocusTimeout=function(){r.preventFocusTimeout&&clearTimeout(r.preventFocusTimeout)},r.setFocus=function(){var i,o;(o=(i=r.input)===null||i===void 0?void 0:i.focus)===null||o===void 0||o.call(i,{preventScroll:!0})},r.setBlur=function(){var i,o;(o=(i=r.input)===null||i===void 0?void 0:i.blur)===null||o===void 0||o.call(i),r.cancelFocusInput()},r.deferBlur=function(){requestAnimationFrame(function(){r.setBlur()})},r.setOpen=function(i,o){o===void 0&&(o=!1),r.setState({open:i,preSelection:i&&r.state.open?r.state.preSelection:r.calcInitialState().preSelection,lastPreSelectChange:Dg},function(){i||r.setState(function(a){return{focused:o?a.focused:!1}},function(){!o&&r.deferBlur(),r.setState({inputValue:null})})})},r.inputOk=function(){return yi(r.state.preSelection)},r.isCalendarOpen=function(){return r.props.open===void 0?r.state.open&&!r.props.disabled&&!r.props.readOnly:r.props.open},r.handleFocus=function(i){var o,a,s=r.state.wasHidden,l=s?r.state.open:!0;s&&r.resetHiddenStatus(),r.state.preventFocus||((a=(o=r.props).onFocus)===null||a===void 0||a.call(o,i),l&&!r.props.preventOpenOnFocus&&!r.props.readOnly&&r.setOpen(!0)),r.setState({focused:!0})},r.sendFocusBackToInput=function(){r.preventFocusTimeout&&r.clearPreventFocusTimeout(),r.setState({preventFocus:!0},function(){r.preventFocusTimeout=setTimeout(function(){r.setFocus(),r.setState({preventFocus:!1})})})},r.cancelFocusInput=function(){clearTimeout(r.inputFocusTimeout),r.inputFocusTimeout=void 0},r.deferFocusInput=function(){r.cancelFocusInput(),r.inputFocusTimeout=setTimeout(function(){return r.setFocus()},1)},r.handleDropdownFocus=function(){r.cancelFocusInput()},r.resetInputValue=function(){r.setState(Se(Se({},r.state),{inputValue:null}))},r.handleBlur=function(i){var o,a;(!r.state.open||r.props.withPortal||r.props.showTimeInput)&&((a=(o=r.props).onBlur)===null||a===void 0||a.call(o,i));var s=r.state.inputValue;if(typeof s=="string"&&s.length>0){var l=/[a-zA-Z0-9]/.test(s);!l&&r.props.selected&&r.setSelected(null,void 0,!0)}r.resetInputValue(),r.state.open&&r.props.open===!1&&r.setOpen(!1),r.setState({focused:!1})},r.handleCalendarClickOutside=function(i){var o,a;(a=(o=r.props).onClickOutside)===null||a===void 0||a.call(o,i),!r.props.inline&&!i.defaultPrevented&&r.setOpen(!1),r.props.withPortal&&i.preventDefault()},r.handleChange=function(){for(var i,o,a,s,l,c,u,d,f=[],p=0;p<arguments.length;p++)f[p]=arguments[p];var m=f[0];if(!(r.props.onChangeRaw&&(r.props.onChangeRaw.apply(r,f),!m||typeof m.isDefaultPrevented!="function"||m.isDefaultPrevented()))){r.setState({inputValue:m?.target instanceof HTMLInputElement?m.target.value:null,lastPreSelectChange:C8});var g=r.props,v=g.selectsRange,x=g.startDate,_=g.endDate,w=(i=r.props.dateFormat)!==null&&i!==void 0?i:t.defaultProps.dateFormat,y=(o=r.props.strictParsing)!==null&&o!==void 0?o:t.defaultProps.strictParsing,E=m?.target instanceof HTMLInputElement?m.target.value:"";if(v){var S=r.props.rangeSeparator,P=S.trim(),D=E.split(w.includes(P)?S:P,2).map(function(B){return B.trim()}),T=D[0],I=D[1],A=Pa(T??"",w,r.props.locale,y),C=A?Pa(I??"",w,r.props.locale,y):null,j=((a=Da(x))===null||a===void 0?void 0:a.getTime())!==A?.getTime(),N=((s=Da(_))===null||s===void 0?void 0:s.getTime())!==C?.getTime();if(!j&&!N||A&&Mr(A,r.props)||C&&Mr(C,r.props))return;A&&r.setState({preSelection:A}),(c=(l=r.props).onChange)===null||c===void 0||c.call(l,[A,C],m)}else{var M=Pa(E,w,r.props.locale,y,(u=r.props.selected)!==null&&u!==void 0?u:void 0);if(M||!E)r.setSelected(M,m,!0);else if(!r.props.inline){var R=F3(E,(d=r.state.preSelection)!==null&&d!==void 0?d:void 0);R&&(!r.props.minDate||!bi(R,r.props.minDate))&&(!r.props.maxDate||!no(R,r.props.maxDate))&&r.setState({preSelection:R})}}}},r.handleSelect=function(i,o,a){var s;if(!r.props.readOnly){var l=r.props,c=l.selectsRange,u=l.startDate,d=l.endDate,f=l.locale,p=l.swapRange,m=(s=r.props.dateFormat)!==null&&s!==void 0?s:t.defaultProps.dateFormat,g=!c||u&&!d&&(p||!Og(i,u));if(r.props.shouldCloseOnSelect&&!r.props.showTimeSelect&&g&&r.sendFocusBackToInput(),r.props.onChangeRaw){var v=tr(i,{dateFormat:m,locale:f});r.props.onChangeRaw(o,{date:i,formattedDate:v})}r.setSelected(i,o,!1,a),r.props.showDateSelect&&r.setState({isRenderAriaLiveMessage:!0}),!r.props.shouldCloseOnSelect||r.props.showTimeSelect?r.setPreSelection(i):g&&r.setOpen(!1)}},r.setSelected=function(i,o,a,s){var l,c,u=r.props.timeZone,d=i;if(d&&u&&(d=ro(d,u)),r.props.showYearPicker){if(d!==null&&gf(Ce(d),r.props))return}else if(r.props.showMonthYearPicker){if(d!==null&&TE(d,r.props))return}else if(d!==null&&Mr(d,r.props))return;var f=r.props,p=f.onChange,m=f.selectsRange,g=f.startDate,v=f.endDate,x=f.selectsMultiple,_=f.selectedDates,w=f.minTime,y=f.swapRange;if(!Aa(r.props.selected,d)||r.props.allowSameDay||m||x)if(d!==null&&(r.props.selected&&(!a||!r.props.showTimeSelect&&!r.props.showTimeSelectOnly&&!r.props.showTimeInput)&&(d=io(d,{hour:An(r.props.selected),minute:Tn(r.props.selected),second:Yo(r.props.selected)})),!a&&(r.props.showTimeSelect||r.props.showTimeSelectOnly)&&w&&(d=io(d,{hour:w.getHours(),minute:w.getMinutes(),second:w.getSeconds()})),r.props.inline||r.setState({preSelection:d}),r.props.focusSelectedMonth||r.setState({monthSelectedIn:s})),m){var E=p,S=!g&&!v,P=g&&!v,D=!g&&!!v,T=g&&v;S?E?.([d,null],o):P?d===null?E?.([null,null],o):Og(d,g)?E?.(y?[d,g]:[d,null],o):E?.([g,d],o):D&&(d&&Og(d,v)?E?.([d,v],o):E?.([d,null],o)),T&&E?.([d,null],o)}else if(x){var I=p;if(d!==null)if(!_?.length)I?.([d],o);else{var A=_.some(function(j){return Ae(j,d)});if(A){var C=_.filter(function(j){return!Ae(j,d)});I?.(C,o)}else I?.(Ci(Ci([],_,!0),[d],!1),o)}}else p?.(d,o);a||((c=(l=r.props).onSelect)===null||c===void 0||c.call(l,d,o),r.setState({inputValue:null}))},r.setPreSelection=function(i){if(!r.props.readOnly){var o=yi(r.props.minDate),a=yi(r.props.maxDate),s=!0;if(i){var l=gc(i);if(o&&a)s=Ta(i,r.props.minDate,r.props.maxDate);else if(o){var c=gc(r.props.minDate);s=no(i,c)||Aa(l,c)}else if(a){var u=DE(r.props.maxDate);s=bi(i,u)||Aa(l,u)}}s&&r.setState({preSelection:i})}},r.toggleCalendar=function(){r.setOpen(!r.state.open)},r.handleTimeChange=function(i,o){var a,s;if(!r.props.selectsMultiple){var l=r.props,c=l.selectsRange,u=l.startDate,d=l.endDate,f=l.onChange,p=l.timeZone;if(c){var m=f;if(o==="start"){if(u){var g=io(u,{hour:An(i),minute:Tn(i)});r.setState({preSelection:g}),p&&(g=ro(g,p)),m?.([g,d?p?ro(d,p):d:null],void 0)}}else if(o==="end"){if(d){var v=io(d,{hour:An(i),minute:Tn(i)});r.setState({preSelection:v}),p&&(v=ro(v,p)),m?.([u?p?ro(u,p):u:null,v],void 0)}}else{var x=u&&!d;if(x){var g=io(u,{hour:An(i),minute:Tn(i)});r.setState({preSelection:g}),p&&(g=ro(g,p)),m?.([g,null],void 0)}else if(u&&d){var v=io(d,{hour:An(i),minute:Tn(i)});r.setState({preSelection:v}),p&&(v=ro(v,p)),m?.([p?ro(u,p):u,v],void 0)}else{var _=io(r.getPreSelection(),{hour:An(i),minute:Tn(i)});r.setState({preSelection:_})}}}else{var w=r.props.selected?r.props.selected:r.getPreSelection(),_=r.props.selected?i:io(w,{hour:An(i),minute:Tn(i)});r.setState({preSelection:_}),_&&p&&(_=ro(_,p)),(s=(a=r.props).onChange)===null||s===void 0||s.call(a,_)}r.props.shouldCloseOnSelect&&!r.props.showTimeInput&&(r.sendFocusBackToInput(),r.setOpen(!1)),r.props.showTimeInput&&r.setOpen(!0),(r.props.showTimeSelectOnly||r.props.showTimeSelect)&&r.setState({isRenderAriaLiveMessage:!0}),r.setState({inputValue:null})}},r.onInputClick=function(){var i,o;!r.props.disabled&&!r.props.readOnly&&r.setOpen(!0),(o=(i=r.props).onInputClick)===null||o===void 0||o.call(i)},r.handleTimeOnlyArrowKey=function(i){var o,a,s,l,c=Da(r.props.selected)||r.state.preSelection||je(),u=(o=r.props.timeIntervals)!==null&&o!==void 0?o:30,d=(a=r.props.dateFormat)!==null&&a!==void 0?a:t.defaultProps.dateFormat,f=Array.isArray(d)?d[0]:d,p=gc(c),m=An(c)*60+Tn(c),g=1440-u,v;if(i===le.ArrowUp){var x=Math.max(0,m-u);v=ac(p,x)}else{var x=Math.min(g,m+u);v=ac(p,x)}var _=mt(v,f||t.defaultProps.dateFormat,r.props.locale);if(r.setState({preSelection:v,inputValue:_}),!(r.props.selectsRange||r.props.selectsMultiple)){var w=r.props.selected?r.props.selected:r.getPreSelection(),y=r.props.selected?v:io(w,{hour:An(v),minute:Tn(v)});(l=(s=r.props).onChange)===null||l===void 0||l.call(s,y),(r.props.showTimeSelectOnly||r.props.showTimeSelect)&&r.setState({isRenderAriaLiveMessage:!0}),requestAnimationFrame(function(){r.scrollToTimeOption(v)})}},r.handleTimeOnlyEnterKey=function(i){var o,a,s,l,c=i.target,u=c.value,d=(o=r.props.dateFormat)!==null&&o!==void 0?o:t.defaultProps.dateFormat,f=r.props.timeFormat||"p",p=r.state.preSelection||Da(r.props.selected)||je(),m=Pa(u,d,r.props.locale,(a=r.props.strictParsing)!==null&&a!==void 0?a:!1,p),g=p;if(m&&er(m))g=m;else{var v=((s=r.calendar)===null||s===void 0?void 0:s.containerRef.current)instanceof Element&&r.calendar.containerRef.current.querySelector(".react-datepicker__time-list-item[tabindex='0']");if(v instanceof HTMLElement){var x=(l=v.textContent)===null||l===void 0?void 0:l.trim();if(x){var _=Pa(x,f,r.props.locale,!1,p);_&&er(_)&&(g=_)}}}r.handleTimeChange(g),r.setOpen(!1),r.sendFocusBackToInput()},r.scrollToTimeOption=function(i){var o,a;if(!((o=r.calendar)===null||o===void 0)&&o.containerRef.current){for(var s=r.calendar.containerRef.current,l=Array.from(s.querySelectorAll(".react-datepicker__time-list-item")),c=null,u=1/0,d=r.props.timeFormat||"p",f=0,p=l;f<p.length;f++){var m=p[f],g=(a=m.textContent)===null||a===void 0?void 0:a.trim();if(g){var v=Pa(g,d,r.props.locale,!1,i);if(v&&er(v)){if(VE(v,i)){c=m;break}var x=Math.abs(v.getTime()-i.getTime());x<u&&(u=x,c=m)}}}c&&(l.forEach(function(_){_.setAttribute("tabindex","-1")}),c.setAttribute("tabindex","0"),c.scrollIntoView({behavior:"smooth",block:"center"}))}},r.onInputKeyDown=function(i){var o,a,s,l,c,u;(a=(o=r.props).onKeyDown)===null||a===void 0||a.call(o,i);var d=i.key;if(!r.state.open&&!r.props.inline&&!r.props.preventOpenOnFocus){(d===le.ArrowDown||d===le.ArrowUp||d===le.Enter)&&((s=r.onInputClick)===null||s===void 0||s.call(r));return}if(r.state.open&&r.props.showTimeSelectOnly){if(d===le.ArrowDown||d===le.ArrowUp){i.preventDefault(),r.handleTimeOnlyArrowKey(d);return}if(d===le.Enter){i.preventDefault(),r.handleTimeOnlyEnterKey(i);return}}if(r.state.open){if(d===le.ArrowDown||d===le.ArrowUp){i.preventDefault();var f=r.props.showTimeSelectOnly?".react-datepicker__time-list-item[tabindex='0']":r.props.showWeekPicker&&r.props.showWeekNumbers?'.react-datepicker__week-number[tabindex="0"]':r.props.showFullMonthYearPicker||r.props.showMonthYearPicker?'.react-datepicker__month-text[tabindex="0"]':'.react-datepicker__day[tabindex="0"]',p=((l=r.calendar)===null||l===void 0?void 0:l.containerRef.current)instanceof Element&&r.calendar.containerRef.current.querySelector(f);p instanceof HTMLElement&&p.focus({preventScroll:!0});return}var m=je(r.state.preSelection);d===le.Enter?(i.preventDefault(),i.target.blur(),r.inputOk()&&r.state.lastPreSelectChange===Dg?(r.handleSelect(m,i),!r.props.shouldCloseOnSelect&&r.setPreSelection(m)):r.setOpen(!1)):d===le.Escape?(i.preventDefault(),i.target.blur(),r.sendFocusBackToInput(),r.setOpen(!1)):d===le.Tab&&r.setOpen(!1),r.inputOk()||(u=(c=r.props).onInputError)===null||u===void 0||u.call(c,{code:1,msg:Pg})}},r.onPortalKeyDown=function(i){var o=i.key;o===le.Escape&&(i.preventDefault(),r.setState({preventFocus:!0},function(){r.setOpen(!1),setTimeout(function(){r.setFocus(),r.setState({preventFocus:!1})})}))},r.onDayKeyDown=function(i){var o,a,s,l,c,u,d=r.props,f=d.minDate,p=d.maxDate,m=d.disabledKeyboardNavigation,g=d.showWeekPicker,v=d.shouldCloseOnSelect,x=d.locale,_=d.calendarStartDay,w=d.adjustDateOnChange,y=d.inline;if((a=(o=r.props).onKeyDown)===null||a===void 0||a.call(o,i),!m){var E=i.key,S=i.shiftKey,P=je(r.state.preSelection),D=function(A,C){var j=C;switch(A){case le.ArrowRight:j=g?Wd(C,1):ei(C,1);break;case le.ArrowLeft:j=g?J_(C):JB(C);break;case le.ArrowUp:j=J_(C);break;case le.ArrowDown:j=Wd(C,1);break;case le.PageUp:j=S?Uo(C,1):Sa(C,1);break;case le.PageDown:j=S?ni(C,1):ti(C,1);break;case le.Home:j=qo(C,x,_);break;case le.End:j=W3(C);break}return j},T=function(A,C){for(var j=40,N=A,M=!1,R=0,B=D(A,C);!M;){if(R>=j){B=C;break}f&&B<f&&(N=le.ArrowRight,B=Mr(f,r.props)?D(N,B):f),p&&B>p&&(N=le.ArrowLeft,B=Mr(p,r.props)?D(N,B):p),Mr(B,r.props)?((N===le.PageUp||N===le.Home)&&(N=le.ArrowRight),(N===le.PageDown||N===le.End)&&(N=le.ArrowLeft),B=D(N,B)):M=!0,R++}return B};if(E===le.Enter){i.preventDefault(),r.handleSelect(P,i),!v&&r.setPreSelection(P);return}else if(E===le.Escape){i.preventDefault(),r.setOpen(!1),r.inputOk()||(l=(s=r.props).onInputError)===null||l===void 0||l.call(s,{code:1,msg:Pg});return}var I=null;switch(E){case le.ArrowLeft:case le.ArrowRight:case le.ArrowUp:case le.ArrowDown:case le.PageUp:case le.PageDown:case le.Home:case le.End:I=T(E,P);break}if(!I){(u=(c=r.props).onInputError)===null||u===void 0||u.call(c,{code:1,msg:Pg});return}i.preventDefault(),r.setState({lastPreSelectChange:Dg}),w&&r.setSelected(I),r.setPreSelection(I),y&&r.setState({shouldFocusDayInline:!0})}},r.onPopperKeyDown=function(i){var o=i.key;o===le.Escape&&(i.preventDefault(),r.sendFocusBackToInput(),r.setOpen(!1))},r.onClearClick=function(i){i&&i.preventDefault&&i.preventDefault(),r.sendFocusBackToInput();var o=r.props,a=o.selectsRange,s=o.onChange;s?.(a?[null,null]:null,i),r.setState({inputValue:null})},r.clear=function(){r.onClearClick()},r.onScroll=function(i){typeof r.props.closeOnScroll=="boolean"&&r.props.closeOnScroll?(i.target===document||i.target===document.documentElement||i.target===document.body)&&r.setOpen(!1):typeof r.props.closeOnScroll=="function"&&r.props.closeOnScroll(i)&&r.setOpen(!1)},r.handleMonthSelectedInChange=function(i){r.setState({monthSelectedIn:i})},r.renderCalendar=function(){var i,o;return!r.props.inline&&!r.isCalendarOpen()?null:k.createElement(b8,Se({showMonthYearDropdown:void 0,ref:function(a){r.calendar=a}},r.props,r.state,{setOpen:r.setOpen,dateFormat:(i=r.props.dateFormatCalendar)!==null&&i!==void 0?i:t.defaultProps.dateFormatCalendar,onSelect:r.handleSelect,onClickOutside:r.handleCalendarClickOutside,holidays:J3(r.modifyHolidays()),outsideClickIgnoreClass:r.props.outsideClickIgnoreClass,onDropdownFocus:r.handleDropdownFocus,onTimeChange:r.handleTimeChange,className:r.props.calendarClassName,container:r.props.calendarContainer,handleOnKeyDown:r.props.onKeyDown,handleOnDayKeyDown:r.onDayKeyDown,setPreSelection:r.setPreSelection,dropdownMode:(o=r.props.dropdownMode)!==null&&o!==void 0?o:t.defaultProps.dropdownMode,onMonthSelectedInChange:r.handleMonthSelectedInChange}),r.props.children)},r.renderAriaLiveRegion=function(){var i,o=r.props.locale,a=(i=r.props.dateFormat)!==null&&i!==void 0?i:t.defaultProps.dateFormat,s=r.props.showTimeInput||r.props.showTimeSelect,l=s?"PPPPp":"PPPP",c;return r.props.selectsRange?c="Selected start date: ".concat(tr(r.props.startDate,{dateFormat:l,locale:o}),". ").concat(r.props.endDate?"End date: "+tr(r.props.endDate,{dateFormat:l,locale:o}):""):r.props.showTimeSelectOnly?c="Selected time: ".concat(tr(r.props.selected,{dateFormat:a,locale:o})):r.props.showYearPicker?c="Selected year: ".concat(tr(r.props.selected,{dateFormat:"yyyy",locale:o})):r.props.showMonthYearPicker?c="Selected month: ".concat(tr(r.props.selected,{dateFormat:"MMMM yyyy",locale:o})):r.props.showQuarterYearPicker?c="Selected quarter: ".concat(tr(r.props.selected,{dateFormat:"yyyy, QQQ",locale:o})):c="Selected date: ".concat(tr(r.props.selected,{dateFormat:l,locale:o})),k.createElement("span",{role:"alert","aria-live":"polite",className:"react-datepicker__aria-live"},c)},r.renderDateInput=function(){var i,o,a,s,l,c,u,d=ue(r.props.className,(i={},i[r.props.outsideClickIgnoreClass||t.defaultProps.outsideClickIgnoreClass]=r.state.open,i)),f=r.props.customInput||k.createElement("input",{type:"text"}),p=r.props.customInputRef||"ref",m={},g=(a=r.props["aria-describedby"])!==null&&a!==void 0?a:r.props.ariaDescribedBy,v=(s=r.props["aria-invalid"])!==null&&s!==void 0?s:r.props.ariaInvalid,x=(l=r.props["aria-label"])!==null&&l!==void 0?l:r.props.ariaLabel,_=(c=r.props["aria-labelledby"])!==null&&c!==void 0?c:r.props.ariaLabelledBy,w=(u=r.props["aria-required"])!==null&&u!==void 0?u:r.props.ariaRequired;return g!=null&&(m["aria-describedby"]=g),v!=null&&(m["aria-invalid"]=v),x!=null&&(m["aria-label"]=x),_!=null&&(m["aria-labelledby"]=_),w!=null&&(m["aria-required"]=w),k.cloneElement(f,Se((o={},o[p]=function(y){r.input=y},o.value=r.getInputValue(),o.onBlur=r.handleBlur,o.onChange=r.handleChange,o.onClick=r.onInputClick,o.onFocus=r.handleFocus,o.onKeyDown=r.onInputKeyDown,o.id=r.props.id,o.name=r.props.name,o.form=r.props.form,o.autoFocus=r.props.autoFocus,o.placeholder=r.props.placeholderText,o.disabled=r.props.disabled,o.autoComplete=r.props.autoComplete,o.className=ue(f.props.className,d),o.title=r.props.title,o.readOnly=r.props.readOnly,o.required=r.props.required,o.tabIndex=r.props.tabIndex,o),m))},r.renderClearButton=function(){var i=r.props,o=i.isClearable,a=i.disabled,s=i.selected,l=i.startDate,c=i.endDate,u=i.clearButtonTitle,d=i.clearButtonClassName,f=d===void 0?"":d,p=i.ariaLabelClose,m=p===void 0?"Close":p,g=i.selectedDates,v=i.readOnly;return o&&!v&&(s!=null||l!=null||c!=null||g?.length)?k.createElement("button",{type:"button",className:ue("react-datepicker__close-icon",f,{"react-datepicker__close-icon--disabled":a}),disabled:a,"aria-label":m,onClick:r.onClearClick,title:u,tabIndex:-1}):null},r.state=r.calcInitialState(),r.preventFocusTimeout=void 0,r}return Object.defineProperty(t,"defaultProps",{get:function(){return{allowSameDay:!1,dateFormat:"MM/dd/yyyy",dateFormatCalendar:"LLLL yyyy",disabled:!1,disabledKeyboardNavigation:!1,dropdownMode:"scroll",preventOpenOnFocus:!1,monthsShown:1,outsideClickIgnoreClass:XE,readOnly:!1,rangeSeparator:CE,withPortal:!1,selectsDisabledDaysInRange:!1,shouldCloseOnSelect:!0,showTimeSelect:!1,showTimeInput:!1,showPreviousMonths:!1,showMonthYearPicker:!1,showFullMonthYearPicker:!1,showTwoColumnMonthYearPicker:!1,showFourColumnMonthYearPicker:!1,showYearPicker:!1,showQuarterYearPicker:!1,showWeekPicker:!1,strictParsing:!1,swapRange:!1,timeIntervals:30,timeCaption:"Time",previousMonthAriaLabel:"Previous Month",previousMonthButtonLabel:"Previous Month",nextMonthAriaLabel:"Next Month",nextMonthButtonLabel:"Next Month",previousYearAriaLabel:"Previous Year",previousYearButtonLabel:"Previous Year",nextYearAriaLabel:"Next Year",nextYearButtonLabel:"Next Year",timeInputLabel:"Time",enableTabLoop:!0,yearItemNumber:mc,focusSelectedMonth:!1,showPopperArrow:!0,excludeScrollbar:!0,customTimeInput:null,calendarStartDay:void 0,toggleCalendarOnIconClick:!1,usePointerEvent:!1}},enumerable:!1,configurable:!0}),t.prototype.componentDidMount=function(){window.addEventListener("scroll",this.onScroll,!0),document.addEventListener("visibilitychange",this.setHiddenStateOnVisibilityHidden)},t.prototype.componentDidUpdate=function(n,r){var i,o,a,s;this.props.selectsRange&&JE(n.startDate,this.props.startDate)?this.setPreSelection(this.props.startDate):JE(n.selected,this.props.selected)&&this.setPreSelection(this.props.selected),this.state.monthSelectedIn!==void 0&&n.monthsShown!==this.props.monthsShown&&this.setState({monthSelectedIn:0}),this.props.selectsRange&&r.open===!1&&this.state.open===!0&&this.state.monthSelectedIn!==0&&this.setState({monthSelectedIn:0}),n.highlightDates!==this.props.highlightDates&&this.setState({highlightDates:WE(this.props.highlightDates)}),!r.focused&&!Aa(n.selected,this.props.selected)&&this.setState({inputValue:null}),r.open!==this.state.open&&(r.open===!1&&this.state.open===!0&&((o=(i=this.props).onCalendarOpen)===null||o===void 0||o.call(i)),r.open===!0&&this.state.open===!1&&((s=(a=this.props).onCalendarClose)===null||s===void 0||s.call(a)))},t.prototype.componentWillUnmount=function(){this.clearPreventFocusTimeout(),window.removeEventListener("scroll",this.onScroll,!0),document.removeEventListener("visibilitychange",this.setHiddenStateOnVisibilityHidden)},t.prototype.renderInputContainer=function(){var n=this.props,r=n.showIcon,i=n.icon,o=n.calendarIconClassname,a=n.calendarIconClassName,s=n.toggleCalendarOnIconClick,l=this.state.open;return o&&console.warn("calendarIconClassname props is deprecated. should use calendarIconClassName props."),k.createElement("div",{className:"react-datepicker__input-container".concat(r?" react-datepicker__view-calendar-icon":"")},r&&k.createElement(x8,Se({icon:i,className:ue(a,!a&&o,l&&"react-datepicker-ignore-onclickoutside")},s?{onClick:this.toggleCalendar}:null)),this.state.isRenderAriaLiveMessage&&this.renderAriaLiveRegion(),this.renderDateInput(),this.renderClearButton())},t.prototype.render=function(){var n=this.renderCalendar();if(this.props.inline)return n;if(this.props.withPortal){var r=this.state.open?k.createElement(ZE,{enableTabLoop:this.props.enableTabLoop},k.createElement("div",{className:"react-datepicker__portal",tabIndex:-1,onKeyDown:this.onPortalKeyDown},n)):null;return this.state.open&&this.props.portalId&&(r=k.createElement(QE,Se({portalId:this.props.portalId},this.props),r)),k.createElement(k.Fragment,null,this.renderInputContainer(),r)}return k.createElement(O8,Se({},this.props,{className:this.props.popperClassName,hidePopper:!this.isCalendarOpen(),targetComponent:this.renderInputContainer(),popperComponent:n,popperOnKeyDown:this.onPopperKeyDown,showArrow:this.props.showPopperArrow,monthHeaderPosition:this.props.monthHeaderPosition}))},t})(k.Component),C8="input",Dg="navigate";const tS=e=>String(e).padStart(2,"0"),Ys=(e,t="start")=>e?`${[e.getFullYear(),tS(e.getMonth()+1),tS(e.getDate())].join("-")} ${t==="end"?"23:59:59":"00:00:00"}`:"";function k8({title:e,description:t,onExport:n}){const[r,i]=k.useState(!1),[o,a]=k.useState(!1),[s,l]=k.useState("Last 7 Days"),[c,u]=k.useState(null),[d,f]=k.useState(null),[p,m]=k.useState(!1),[g,v]=k.useState(!1),x=k.useRef(null),_=k.useRef(null),w=["Last 7 Days","Last 30 Days","This Month","Previous Month","Custom Range"],y=[{label:"Export as Excel",value:"xlsx"},{label:"Export as PDF",value:"pdf"}];k.useEffect(()=>{const A=C=>{x.current&&!x.current.contains(C.target)&&(i(!1),m(!1)),_.current&&!_.current.contains(C.target)&&a(!1)};return document.addEventListener("mousedown",A),()=>document.removeEventListener("mousedown",A)},[]),k.useEffect(()=>{const A=new URLSearchParams(window.location.search),C=A.get(`${e.toLowerCase()}start_date`),j=A.get(`${e.toLowerCase()}end_date`);C&&j&&(u(new Date(C)),f(new Date(j)),l("Custom Range"))},[e]);const E=A=>{const C=new Date;C.setHours(0,0,0,0);let j,N;switch(A){case"Last 7 Days":j=new Date(C),j.setDate(C.getDate()-6),N=C;break;case"Last 30 Days":j=new Date(C),j.setDate(C.getDate()-29),N=C;break;case"This Month":j=new Date(C.getFullYear(),C.getMonth(),1),N=C;break;case"Previous Month":j=new Date(C.getFullYear(),C.getMonth()-1,1),N=new Date(C.getFullYear(),C.getMonth(),0);break;default:return null}return{start:Ys(j,"start"),end:Ys(N,"end")}},S=(A,C)=>{const j=new URLSearchParams(window.location.search);j.set(`${e.toLowerCase()}start_date`,A),j.set(`${e.toLowerCase()}end_date`,C),window.history.pushState({},"",`${window.location.pathname}?${j.toString()}`),window.dispatchEvent(new Event("dateRangeChange"))},P=A=>{if(A==="Custom Range"){l(A),m(!0),u(null),f(null);return}const C=E(A);C&&(l(A),i(!1),m(!1),S(C.start,C.end))},D=()=>{!c||!d||(S(Ys(c,"start"),Ys(d,"end")),i(!1),m(!1))},T=()=>s==="Custom Range"&&c&&d?`${c.toLocaleDateString()} - ${d.toLocaleDateString()}`:s,I=async A=>{v(!0),a(!1);try{let C,j;if(s==="Custom Range")C=Ys(c,"start"),j=Ys(d,"end");else{const N=E(s);C=N?.start,j=N?.end}await n?.({format:A,section:e,start:C,end:j})}finally{v(!1)}};return h.jsxs("div",{className:"flex items-center justify-between px-[24px] my-6",children:[h.jsxs("div",{children:[h.jsx("div",{className:"text-[24px] font-semibold text-[#121212]",children:e}),h.jsx("div",{className:"text-gray-500 text-sm",children:t})]}),h.jsxs("div",{className:"flex gap-[12px]",children:[h.jsxs("div",{className:"relative",ref:x,children:[h.jsxs("button",{onClick:()=>i(A=>!A),className:"flex items-center gap-[8px] bg-gray-50 px-[16px] py-[8px].5 rounded-[8px] border border-gray-200 text-sm font-medium text-gray-700 hover:bg-gray-100 transition-colors",children:[h.jsx(Y$,{fontSize:"small",className:"text-gray-600"}),T(),h.jsx(K$,{className:"text-gray-500"})]}),r&&h.jsx("div",{className:"absolute right-0 mt-2 bg-white rounded-[8px] shadow-xl border border-gray-200 z-50",children:p?h.jsxs("div",{className:"p-[16px] w-[360px]",children:[h.jsx(eS,{inline:!0,selectsRange:!0,startDate:c,endDate:d,onChange:([A,C])=>{u(A),f(C)},maxDate:new Date,showYearDropdown:!0,scrollableYearDropdown:!0,yearDropdownItemNumber:40}),h.jsxs("div",{className:"flex justify-between mt-4 gap-[8px]",children:[h.jsx("button",{onClick:()=>m(!1),className:"px-[16px] py-[8px] border border-gray-300 rounded-[8px] text-sm font-medium text-gray-700 hover:bg-gray-50 transition-colors",children:"Cancel"}),h.jsx("button",{onClick:D,disabled:!c||!d,className:"px-[16px] py-[8px] bg-purple-600 text-white rounded-[8px] text-sm font-medium hover:bg-purple-700 disabled:bg-gray-300 disabled:cursor-not-allowed transition-colors",children:"Apply"})]})]}):h.jsx("div",{className:"min-w-[200px] py-[4px]",children:w.map(A=>h.jsx("button",{onClick:()=>P(A),className:`w-full text-left px-[16px] py-[8px].5 text-sm hover:bg-purple-50 transition-colors ${s===A?"bg-purple-50 text-purple-600 font-medium":"text-gray-700"}`,children:A},A))})})]}),h.jsxs("div",{className:"relative",ref:_,children:[h.jsxs("button",{disabled:g,onClick:()=>a(A=>!A),className:"flex items-center gap-[8px] px-[16px] py-[8px].5 rounded-[8px] bg-purple-600 text-white font-medium text-sm hover:bg-purple-700 transition-colors disabled:bg-gray-400 disabled:cursor-not-allowed",children:[g?"Exporting...":"Export Report",h.jsx(U$,{fontSize:"small"})]}),o&&h.jsx("div",{className:"absolute right-0 mt-2 bg-white border border-gray-200 rounded-[8px] shadow-lg z-50 min-w-[180px]",children:y.map(A=>h.jsx("button",{onClick:()=>I(A.value),className:"block px-[16px] py-[8px].5 text-sm hover:bg-purple-50 w-full text-left text-gray-700 transition-colors first:rounded-t-lg last:rounded-b-lg",children:A.label},A.value))})]})]})]})}var nS={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},rS=k.createContext&&k.createContext(nS),P8=["attr","size","title"];function D8(e,t){if(e==null)return{};var n=A8(e,t),r,i;if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(i=0;i<o.length;i++)r=o[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}function A8(e,t){if(e==null)return{};var n={};for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function bf(){return bf=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},bf.apply(this,arguments)}function iS(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function xf(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?iS(Object(n),!0).forEach(function(r){T8(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):iS(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function T8(e,t,n){return t=N8(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function N8(e){var t=j8(e,"string");return typeof t=="symbol"?t:t+""}function j8(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function oS(e){return e&&e.map((t,n)=>k.createElement(t.tag,xf({key:n},t.attr),oS(t.child)))}function gt(e){return t=>k.createElement(M8,bf({attr:xf({},e.attr)},t),oS(e.child))}function M8(e){var t=n=>{var{attr:r,size:i,title:o}=e,a=D8(e,P8),s=i||n.size||"1em",l;return n.className&&(l=n.className),e.className&&(l=(l?l+" ":"")+e.className),k.createElement("svg",bf({stroke:"currentColor",fill:"currentColor",strokeWidth:"0"},n.attr,r,a,{className:l,style:xf(xf({color:e.color||n.color},n.style),e.style),height:s,width:s,xmlns:"http://www.w3.org/2000/svg"}),o&&k.createElement("title",null,o),e.children)};return rS!==void 0?k.createElement(rS.Consumer,null,n=>t(n)):t(nS)}function Go(e){return gt({attr:{viewBox:"0 0 320 512"},child:[{tag:"path",attr:{d:"M31.3 192h257.3c17.8 0 26.7 21.5 14.1 34.1L174.1 354.8c-7.8 7.8-20.5 7.8-28.3 0L17.2 226.1C4.6 213.5 13.5 192 31.3 192z"},child:[]}]})(e)}function Xo(e){return gt({attr:{viewBox:"0 0 320 512"},child:[{tag:"path",attr:{d:"M288.662 352H31.338c-17.818 0-26.741-21.543-14.142-34.142l128.662-128.662c7.81-7.81 20.474-7.81 28.284 0l128.662 128.662c12.6 12.599 3.676 34.142-14.142 34.142z"},child:[]}]})(e)}function I8(e){return gt({attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M192 208c0-17.67-14.33-32-32-32h-16c-35.35 0-64 28.65-64 64v48c0 35.35 28.65 64 64 64h16c17.67 0 32-14.33 32-32V208zm176 144c35.35 0 64-28.65 64-64v-48c0-35.35-28.65-64-64-64h-16c-17.67 0-32 14.33-32 32v112c0 17.67 14.33 32 32 32h16zM256 0C113.18 0 4.58 118.83 0 256v16c0 8.84 7.16 16 16 16h16c8.84 0 16-7.16 16-16v-16c0-114.69 93.31-208 208-208s208 93.31 208 208h-.12c.08 2.43.12 165.72.12 165.72 0 23.35-18.93 42.28-42.28 42.28H320c0-26.51-21.49-48-48-48h-32c-26.51 0-48 21.49-48 48s21.49 48 48 48h181.72c49.86 0 90.28-40.42 90.28-90.28V256C507.42 118.83 398.82 0 256 0z"},child:[]}]})(e)}function aS(e){return gt({attr:{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},child:[{tag:"rect",attr:{width:"16",height:"20",x:"4",y:"2",rx:"2",ry:"2"},child:[]},{tag:"path",attr:{d:"M9 22v-4h6v4"},child:[]},{tag:"path",attr:{d:"M8 6h.01"},child:[]},{tag:"path",attr:{d:"M16 6h.01"},child:[]},{tag:"path",attr:{d:"M12 6h.01"},child:[]},{tag:"path",attr:{d:"M12 10h.01"},child:[]},{tag:"path",attr:{d:"M12 14h.01"},child:[]},{tag:"path",attr:{d:"M16 10h.01"},child:[]},{tag:"path",attr:{d:"M16 14h.01"},child:[]},{tag:"path",attr:{d:"M8 10h.01"},child:[]},{tag:"path",attr:{d:"M8 14h.01"},child:[]}]})(e)}function F8(e){return gt({attr:{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},child:[{tag:"path",attr:{d:"M19 17h2c.6 0 1-.4 1-1v-3c0-.9-.7-1.7-1.5-1.9C18.7 10.6 16 10 16 10s-1.3-1.4-2.2-2.3c-.5-.4-1.1-.7-1.8-.7H5c-.6 0-1.1.4-1.4.9l-1.4 2.9A3.7 3.7 0 0 0 2 12v4c0 .6.4 1 1 1h2"},child:[]},{tag:"circle",attr:{cx:"7",cy:"17",r:"2"},child:[]},{tag:"path",attr:{d:"M9 17h6"},child:[]},{tag:"circle",attr:{cx:"17",cy:"17",r:"2"},child:[]}]})(e)}function Ag(e){return gt({attr:{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},child:[{tag:"path",attr:{d:"M13 4h3a2 2 0 0 1 2 2v14"},child:[]},{tag:"path",attr:{d:"M2 20h3"},child:[]},{tag:"path",attr:{d:"M13 20h9"},child:[]},{tag:"path",attr:{d:"M10 12v.01"},child:[]},{tag:"path",attr:{d:"M13 4.562v16.157a1 1 0 0 1-1.242.97L5 20V5.562a2 2 0 0 1 1.515-1.94l4-1A2 2 0 0 1 13 4.561Z"},child:[]}]})(e)}function sS(e){return gt({attr:{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},child:[{tag:"path",attr:{d:"M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z"},child:[]}]})(e)}function wf(e){return gt({attr:{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},child:[{tag:"path",attr:{d:"M4 2v20l2-1 2 1 2-1 2 1 2-1 2 1 2-1 2 1V2l-2 1-2-1-2 1-2-1-2 1-2-1-2 1Z"},child:[]},{tag:"path",attr:{d:"M14 8H8"},child:[]},{tag:"path",attr:{d:"M16 12H8"},child:[]},{tag:"path",attr:{d:"M13 16H8"},child:[]}]})(e)}function lS(e){return gt({attr:{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},child:[{tag:"path",attr:{d:"M2 9a3 3 0 0 1 0 6v2a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-2a3 3 0 0 1 0-6V7a2 2 0 0 0-2-2H4a2 2 0 0 0-2 2Z"},child:[]},{tag:"path",attr:{d:"m9 12 2 2 4-4"},child:[]}]})(e)}function Tg(e){return gt({attr:{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},child:[{tag:"path",attr:{d:"M2 6c.6.5 1.2 1 2.5 1C7 7 7 5 9.5 5c2.6 0 2.4 2 5 2 2.5 0 2.5-2 5-2 1.3 0 1.9.5 2.5 1"},child:[]},{tag:"path",attr:{d:"M2 12c.6.5 1.2 1 2.5 1 2.5 0 2.5-2 5-2 2.6 0 2.4 2 5 2 2.5 0 2.5-2 5-2 1.3 0 1.9.5 2.5 1"},child:[]},{tag:"path",attr:{d:"M2 18c.6.5 1.2 1 2.5 1 2.5 0 2.5-2 5-2 2.6 0 2.4 2 5 2 2.5 0 2.5-2 5-2 1.3 0 1.9.5 2.5 1"},child:[]}]})(e)}function L8(e){return gt({attr:{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},child:[{tag:"path",attr:{d:"M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.77-3.77a6 6 0 0 1-7.94 7.94l-6.91 6.91a2.12 2.12 0 0 1-3-3l6.91-6.91a6 6 0 0 1 7.94-7.94l-3.76 3.76z"},child:[]}]})(e)}function cS(e){return gt({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M11.03 2.59a1.501 1.501 0 0 1 1.94 0l7.5 6.363a1.5 1.5 0 0 1 .53 1.144V19.5a1.5 1.5 0 0 1-1.5 1.5h-5.75a.75.75 0 0 1-.75-.75V14h-2v6.25a.75.75 0 0 1-.75.75H4.5A1.5 1.5 0 0 1 3 19.5v-9.403c0-.44.194-.859.53-1.144ZM12 3.734l-7.5 6.363V19.5h5v-6.25a.75.75 0 0 1 .75-.75h3.5a.75.75 0 0 1 .75.75v6.25h5v-9.403Z"},child:[]}]})(e)}function Ng(e){return gt({attr:{viewBox:"0 0 24 24"},child:[{tag:"path",attr:{d:"M3.5 8a5.5 5.5 0 1 1 8.596 4.547 9.005 9.005 0 0 1 5.9 8.18.751.751 0 0 1-1.5.045 7.5 7.5 0 0 0-14.993 0 .75.75 0 0 1-1.499-.044 9.005 9.005 0 0 1 5.9-8.181A5.496 5.496 0 0 1 3.5 8ZM9 4a4 4 0 1 0 0 8 4 4 0 0 0 0-8Zm8.29 4c-.148 0-.292.01-.434.03a.75.75 0 1 1-.212-1.484 4.53 4.53 0 0 1 3.38 8.097 6.69 6.69 0 0 1 3.956 6.107.75.75 0 0 1-1.5 0 5.193 5.193 0 0 0-3.696-4.972l-.534-.16v-1.676l.41-.209A3.03 3.03 0 0 0 17.29 8Z"},child:[]}]})(e)}function R8(e){return gt({attr:{viewBox:"0 0 32 32"},child:[{tag:"path",attr:{d:"M 2 7 L 2 24 L 30 24 L 30 7 L 2 7 z M 6 9 L 26 9 C 26 10.105 26.895 11 28 11 L 28 20 C 26.895 20 26 20.895 26 22 L 6 22 C 6 20.895 5.105 20 4 20 L 4 11 C 5.105 11 6 10.105 6 9 z M 16 11 C 13.789 11 12 13.016 12 15.5 C 12 17.984 13.789 20 16 20 C 18.211 20 20 17.984 20 15.5 C 20 13.016 18.211 11 16 11 z M 16 13 C 17.102 13 18 14.121 18 15.5 C 18 16.879 17.102 18 16 18 C 14.898 18 14 16.879 14 15.5 C 14 14.121 14.898 13 16 13 z M 8.5 14 C 7.672 14 7 14.672 7 15.5 C 7 16.328 7.672 17 8.5 17 C 9.328 17 10 16.328 10 15.5 C 10 14.672 9.328 14 8.5 14 z M 23.5 14 C 22.672 14 22 14.672 22 15.5 C 22 16.328 22.672 17 23.5 17 C 24.328 17 25 16.328 25 15.5 C 25 14.672 24.328 14 23.5 14 z"},child:[]}]})(e)}const $8=[{name:"Overview",icon:cS},{name:"Community",icon:aS},{name:"Financials",icon:R8},{name:"Facilities",icon:Ag},{name:"Gate & Security",icon:Tg},{name:"Helpdesk",icon:I8},{name:"Engagement",icon:sS}];function B8(){const[e,t]=k.useState("Overview");return h.jsx("div",{className:"flex gap-[8px] p-[12px]",children:$8.map(n=>{const r=n.icon,i=e===n.name;return h.jsxs("button",{onClick:()=>t(n.name),className:`flex items-center gap-[8px] rounded px-[16px] py-[12px] text-[14px] leading-[16px] font-medium transition
|
|
124
|
-
${i?"bg-[#FBF5FF] text-[#884EA7]":"bg-white text-[#64748B] hover:bg-gray-50"}`,children:[h.jsx(r,{className:"h-[15px] w-[15px] font-bold"}),n.name]},n.name)})})}function W8(e){return gt({attr:{viewBox:"0 0 576 512"},child:[{tag:"path",attr:{d:"M384 160c-17.7 0-32-14.3-32-32s14.3-32 32-32l160 0c17.7 0 32 14.3 32 32l0 160c0 17.7-14.3 32-32 32s-32-14.3-32-32l0-82.7L342.6 374.6c-12.5 12.5-32.8 12.5-45.3 0L192 269.3 54.6 406.6c-12.5 12.5-32.8 12.5-45.3 0s-12.5-32.8 0-45.3l160-160c12.5-12.5 32.8-12.5 45.3 0L320 306.7 466.7 160 384 160z"},child:[]}]})(e)}function z8(e){return gt({attr:{viewBox:"0 0 576 512"},child:[{tag:"path",attr:{d:"M151.6 42.4C145.5 35.8 137 32 128 32s-17.5 3.8-23.6 10.4l-88 96c-11.9 13-11.1 33.3 2 45.2s33.3 11.1 45.2-2L96 146.3 96 448c0 17.7 14.3 32 32 32s32-14.3 32-32l0-301.7 32.4 35.4c11.9 13 32.2 13.9 45.2 2s13.9-32.2 2-45.2l-88-96zM320 32c-17.7 0-32 14.3-32 32s14.3 32 32 32l32 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-32 0zm0 128c-17.7 0-32 14.3-32 32s14.3 32 32 32l96 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-96 0zm0 128c-17.7 0-32 14.3-32 32s14.3 32 32 32l160 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-160 0zm0 128c-17.7 0-32 14.3-32 32s14.3 32 32 32l224 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-224 0z"},child:[]}]})(e)}function V8(e){return gt({attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M464 256A208 208 0 1 1 48 256a208 208 0 1 1 416 0zM0 256a256 256 0 1 0 512 0A256 256 0 1 0 0 256zM232 120l0 136c0 8 4 15.5 10.7 20l96 64c11 7.4 25.9 4.4 33.3-6.7s4.4-25.9-6.7-33.3L280 243.2 280 120c0-13.3-10.7-24-24-24s-24 10.7-24 24z"},child:[]}]})(e)}var nr="top",Ir="bottom",Fr="right",rr="left",jg="auto",xc=[nr,Ir,Fr,rr],Us="start",wc="end",H8="clippingParents",uS="viewport",_c="popper",Y8="reference",dS=xc.reduce(function(e,t){return e.concat([t+"-"+Us,t+"-"+wc])},[]),fS=[].concat(xc,[jg]).reduce(function(e,t){return e.concat([t,t+"-"+Us,t+"-"+wc])},[]),U8="beforeRead",K8="read",q8="afterRead",G8="beforeMain",X8="main",Q8="afterMain",Z8="beforeWrite",J8="write",eW="afterWrite",tW=[U8,K8,q8,G8,X8,Q8,Z8,J8,eW];function Pi(e){return e?(e.nodeName||"").toLowerCase():null}function br(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function Na(e){var t=br(e).Element;return e instanceof t||e instanceof Element}function Lr(e){var t=br(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function Mg(e){if(typeof ShadowRoot>"u")return!1;var t=br(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function nW(e){var t=e.state;Object.keys(t.elements).forEach(function(n){var r=t.styles[n]||{},i=t.attributes[n]||{},o=t.elements[n];!Lr(o)||!Pi(o)||(Object.assign(o.style,r),Object.keys(i).forEach(function(a){var s=i[a];s===!1?o.removeAttribute(a):o.setAttribute(a,s===!0?"":s)}))})}function rW(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach(function(r){var i=t.elements[r],o=t.attributes[r]||{},a=Object.keys(t.styles.hasOwnProperty(r)?t.styles[r]:n[r]),s=a.reduce(function(l,c){return l[c]="",l},{});!Lr(i)||!Pi(i)||(Object.assign(i.style,s),Object.keys(o).forEach(function(l){i.removeAttribute(l)}))})}}const Ig={name:"applyStyles",enabled:!0,phase:"write",fn:nW,effect:rW,requires:["computeStyles"]};function Di(e){return e.split("-")[0]}var ja=Math.max,_f=Math.min,Ks=Math.round;function Fg(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function pS(){return!/^((?!chrome|android).)*safari/i.test(Fg())}function qs(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!1);var r=e.getBoundingClientRect(),i=1,o=1;t&&Lr(e)&&(i=e.offsetWidth>0&&Ks(r.width)/e.offsetWidth||1,o=e.offsetHeight>0&&Ks(r.height)/e.offsetHeight||1);var a=Na(e)?br(e):window,s=a.visualViewport,l=!pS()&&n,c=(r.left+(l&&s?s.offsetLeft:0))/i,u=(r.top+(l&&s?s.offsetTop:0))/o,d=r.width/i,f=r.height/o;return{width:d,height:f,top:u,right:c+d,bottom:u+f,left:c,x:c,y:u}}function Lg(e){var t=qs(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-r)<=1&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function hS(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&Mg(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function so(e){return br(e).getComputedStyle(e)}function iW(e){return["table","td","th"].indexOf(Pi(e))>=0}function Qo(e){return((Na(e)?e.ownerDocument:e.document)||window.document).documentElement}function Ef(e){return Pi(e)==="html"?e:e.assignedSlot||e.parentNode||(Mg(e)?e.host:null)||Qo(e)}function mS(e){return!Lr(e)||so(e).position==="fixed"?null:e.offsetParent}function oW(e){var t=/firefox/i.test(Fg()),n=/Trident/i.test(Fg());if(n&&Lr(e)){var r=so(e);if(r.position==="fixed")return null}var i=Ef(e);for(Mg(i)&&(i=i.host);Lr(i)&&["html","body"].indexOf(Pi(i))<0;){var o=so(i);if(o.transform!=="none"||o.perspective!=="none"||o.contain==="paint"||["transform","perspective"].indexOf(o.willChange)!==-1||t&&o.willChange==="filter"||t&&o.filter&&o.filter!=="none")return i;i=i.parentNode}return null}function Ec(e){for(var t=br(e),n=mS(e);n&&iW(n)&&so(n).position==="static";)n=mS(n);return n&&(Pi(n)==="html"||Pi(n)==="body"&&so(n).position==="static")?t:n||oW(e)||t}function Rg(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function Sc(e,t,n){return ja(e,_f(t,n))}function aW(e,t,n){var r=Sc(e,t,n);return r>n?n:r}function gS(){return{top:0,right:0,bottom:0,left:0}}function vS(e){return Object.assign({},gS(),e)}function yS(e,t){return t.reduce(function(n,r){return n[r]=e,n},{})}var sW=function(t,n){return t=typeof t=="function"?t(Object.assign({},n.rects,{placement:n.placement})):t,vS(typeof t!="number"?t:yS(t,xc))};function lW(e){var t,n=e.state,r=e.name,i=e.options,o=n.elements.arrow,a=n.modifiersData.popperOffsets,s=Di(n.placement),l=Rg(s),c=[rr,Fr].indexOf(s)>=0,u=c?"height":"width";if(!(!o||!a)){var d=sW(i.padding,n),f=Lg(o),p=l==="y"?nr:rr,m=l==="y"?Ir:Fr,g=n.rects.reference[u]+n.rects.reference[l]-a[l]-n.rects.popper[u],v=a[l]-n.rects.reference[l],x=Ec(o),_=x?l==="y"?x.clientHeight||0:x.clientWidth||0:0,w=g/2-v/2,y=d[p],E=_-f[u]-d[m],S=_/2-f[u]/2+w,P=Sc(y,S,E),D=l;n.modifiersData[r]=(t={},t[D]=P,t.centerOffset=P-S,t)}}function cW(e){var t=e.state,n=e.options,r=n.element,i=r===void 0?"[data-popper-arrow]":r;i!=null&&(typeof i=="string"&&(i=t.elements.popper.querySelector(i),!i)||hS(t.elements.popper,i)&&(t.elements.arrow=i))}const uW={name:"arrow",enabled:!0,phase:"main",fn:lW,effect:cW,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function Gs(e){return e.split("-")[1]}var dW={top:"auto",right:"auto",bottom:"auto",left:"auto"};function fW(e,t){var n=e.x,r=e.y,i=t.devicePixelRatio||1;return{x:Ks(n*i)/i||0,y:Ks(r*i)/i||0}}function bS(e){var t,n=e.popper,r=e.popperRect,i=e.placement,o=e.variation,a=e.offsets,s=e.position,l=e.gpuAcceleration,c=e.adaptive,u=e.roundOffsets,d=e.isFixed,f=a.x,p=f===void 0?0:f,m=a.y,g=m===void 0?0:m,v=typeof u=="function"?u({x:p,y:g}):{x:p,y:g};p=v.x,g=v.y;var x=a.hasOwnProperty("x"),_=a.hasOwnProperty("y"),w=rr,y=nr,E=window;if(c){var S=Ec(n),P="clientHeight",D="clientWidth";if(S===br(n)&&(S=Qo(n),so(S).position!=="static"&&s==="absolute"&&(P="scrollHeight",D="scrollWidth")),S=S,i===nr||(i===rr||i===Fr)&&o===wc){y=Ir;var T=d&&S===E&&E.visualViewport?E.visualViewport.height:S[P];g-=T-r.height,g*=l?1:-1}if(i===rr||(i===nr||i===Ir)&&o===wc){w=Fr;var I=d&&S===E&&E.visualViewport?E.visualViewport.width:S[D];p-=I-r.width,p*=l?1:-1}}var A=Object.assign({position:s},c&&dW),C=u===!0?fW({x:p,y:g},br(n)):{x:p,y:g};if(p=C.x,g=C.y,l){var j;return Object.assign({},A,(j={},j[y]=_?"0":"",j[w]=x?"0":"",j.transform=(E.devicePixelRatio||1)<=1?"translate("+p+"px, "+g+"px)":"translate3d("+p+"px, "+g+"px, 0)",j))}return Object.assign({},A,(t={},t[y]=_?g+"px":"",t[w]=x?p+"px":"",t.transform="",t))}function pW(e){var t=e.state,n=e.options,r=n.gpuAcceleration,i=r===void 0?!0:r,o=n.adaptive,a=o===void 0?!0:o,s=n.roundOffsets,l=s===void 0?!0:s,c={placement:Di(t.placement),variation:Gs(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:i,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,bS(Object.assign({},c,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:a,roundOffsets:l})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,bS(Object.assign({},c,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:l})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const hW={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:pW,data:{}};var Sf={passive:!0};function mW(e){var t=e.state,n=e.instance,r=e.options,i=r.scroll,o=i===void 0?!0:i,a=r.resize,s=a===void 0?!0:a,l=br(t.elements.popper),c=[].concat(t.scrollParents.reference,t.scrollParents.popper);return o&&c.forEach(function(u){u.addEventListener("scroll",n.update,Sf)}),s&&l.addEventListener("resize",n.update,Sf),function(){o&&c.forEach(function(u){u.removeEventListener("scroll",n.update,Sf)}),s&&l.removeEventListener("resize",n.update,Sf)}}const gW={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:mW,data:{}};var vW={left:"right",right:"left",bottom:"top",top:"bottom"};function Of(e){return e.replace(/left|right|bottom|top/g,function(t){return vW[t]})}var yW={start:"end",end:"start"};function xS(e){return e.replace(/start|end/g,function(t){return yW[t]})}function $g(e){var t=br(e),n=t.pageXOffset,r=t.pageYOffset;return{scrollLeft:n,scrollTop:r}}function Bg(e){return qs(Qo(e)).left+$g(e).scrollLeft}function bW(e,t){var n=br(e),r=Qo(e),i=n.visualViewport,o=r.clientWidth,a=r.clientHeight,s=0,l=0;if(i){o=i.width,a=i.height;var c=pS();(c||!c&&t==="fixed")&&(s=i.offsetLeft,l=i.offsetTop)}return{width:o,height:a,x:s+Bg(e),y:l}}function xW(e){var t,n=Qo(e),r=$g(e),i=(t=e.ownerDocument)==null?void 0:t.body,o=ja(n.scrollWidth,n.clientWidth,i?i.scrollWidth:0,i?i.clientWidth:0),a=ja(n.scrollHeight,n.clientHeight,i?i.scrollHeight:0,i?i.clientHeight:0),s=-r.scrollLeft+Bg(e),l=-r.scrollTop;return so(i||n).direction==="rtl"&&(s+=ja(n.clientWidth,i?i.clientWidth:0)-o),{width:o,height:a,x:s,y:l}}function Wg(e){var t=so(e),n=t.overflow,r=t.overflowX,i=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+i+r)}function wS(e){return["html","body","#document"].indexOf(Pi(e))>=0?e.ownerDocument.body:Lr(e)&&Wg(e)?e:wS(Ef(e))}function Oc(e,t){var n;t===void 0&&(t=[]);var r=wS(e),i=r===((n=e.ownerDocument)==null?void 0:n.body),o=br(r),a=i?[o].concat(o.visualViewport||[],Wg(r)?r:[]):r,s=t.concat(a);return i?s:s.concat(Oc(Ef(a)))}function zg(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function wW(e,t){var n=qs(e,!1,t==="fixed");return n.top=n.top+e.clientTop,n.left=n.left+e.clientLeft,n.bottom=n.top+e.clientHeight,n.right=n.left+e.clientWidth,n.width=e.clientWidth,n.height=e.clientHeight,n.x=n.left,n.y=n.top,n}function _S(e,t,n){return t===uS?zg(bW(e,n)):Na(t)?wW(t,n):zg(xW(Qo(e)))}function _W(e){var t=Oc(Ef(e)),n=["absolute","fixed"].indexOf(so(e).position)>=0,r=n&&Lr(e)?Ec(e):e;return Na(r)?t.filter(function(i){return Na(i)&&hS(i,r)&&Pi(i)!=="body"}):[]}function EW(e,t,n,r){var i=t==="clippingParents"?_W(e):[].concat(t),o=[].concat(i,[n]),a=o[0],s=o.reduce(function(l,c){var u=_S(e,c,r);return l.top=ja(u.top,l.top),l.right=_f(u.right,l.right),l.bottom=_f(u.bottom,l.bottom),l.left=ja(u.left,l.left),l},_S(e,a,r));return s.width=s.right-s.left,s.height=s.bottom-s.top,s.x=s.left,s.y=s.top,s}function ES(e){var t=e.reference,n=e.element,r=e.placement,i=r?Di(r):null,o=r?Gs(r):null,a=t.x+t.width/2-n.width/2,s=t.y+t.height/2-n.height/2,l;switch(i){case nr:l={x:a,y:t.y-n.height};break;case Ir:l={x:a,y:t.y+t.height};break;case Fr:l={x:t.x+t.width,y:s};break;case rr:l={x:t.x-n.width,y:s};break;default:l={x:t.x,y:t.y}}var c=i?Rg(i):null;if(c!=null){var u=c==="y"?"height":"width";switch(o){case Us:l[c]=l[c]-(t[u]/2-n[u]/2);break;case wc:l[c]=l[c]+(t[u]/2-n[u]/2);break}}return l}function Cc(e,t){t===void 0&&(t={});var n=t,r=n.placement,i=r===void 0?e.placement:r,o=n.strategy,a=o===void 0?e.strategy:o,s=n.boundary,l=s===void 0?H8:s,c=n.rootBoundary,u=c===void 0?uS:c,d=n.elementContext,f=d===void 0?_c:d,p=n.altBoundary,m=p===void 0?!1:p,g=n.padding,v=g===void 0?0:g,x=vS(typeof v!="number"?v:yS(v,xc)),_=f===_c?Y8:_c,w=e.rects.popper,y=e.elements[m?_:f],E=EW(Na(y)?y:y.contextElement||Qo(e.elements.popper),l,u,a),S=qs(e.elements.reference),P=ES({reference:S,element:w,placement:i}),D=zg(Object.assign({},w,P)),T=f===_c?D:S,I={top:E.top-T.top+x.top,bottom:T.bottom-E.bottom+x.bottom,left:E.left-T.left+x.left,right:T.right-E.right+x.right},A=e.modifiersData.offset;if(f===_c&&A){var C=A[i];Object.keys(I).forEach(function(j){var N=[Fr,Ir].indexOf(j)>=0?1:-1,M=[nr,Ir].indexOf(j)>=0?"y":"x";I[j]+=C[M]*N})}return I}function SW(e,t){t===void 0&&(t={});var n=t,r=n.placement,i=n.boundary,o=n.rootBoundary,a=n.padding,s=n.flipVariations,l=n.allowedAutoPlacements,c=l===void 0?fS:l,u=Gs(r),d=u?s?dS:dS.filter(function(m){return Gs(m)===u}):xc,f=d.filter(function(m){return c.indexOf(m)>=0});f.length===0&&(f=d);var p=f.reduce(function(m,g){return m[g]=Cc(e,{placement:g,boundary:i,rootBoundary:o,padding:a})[Di(g)],m},{});return Object.keys(p).sort(function(m,g){return p[m]-p[g]})}function OW(e){if(Di(e)===jg)return[];var t=Of(e);return[xS(e),t,xS(t)]}function CW(e){var t=e.state,n=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var i=n.mainAxis,o=i===void 0?!0:i,a=n.altAxis,s=a===void 0?!0:a,l=n.fallbackPlacements,c=n.padding,u=n.boundary,d=n.rootBoundary,f=n.altBoundary,p=n.flipVariations,m=p===void 0?!0:p,g=n.allowedAutoPlacements,v=t.options.placement,x=Di(v),_=x===v,w=l||(_||!m?[Of(v)]:OW(v)),y=[v].concat(w).reduce(function(J,re){return J.concat(Di(re)===jg?SW(t,{placement:re,boundary:u,rootBoundary:d,padding:c,flipVariations:m,allowedAutoPlacements:g}):re)},[]),E=t.rects.reference,S=t.rects.popper,P=new Map,D=!0,T=y[0],I=0;I<y.length;I++){var A=y[I],C=Di(A),j=Gs(A)===Us,N=[nr,Ir].indexOf(C)>=0,M=N?"width":"height",R=Cc(t,{placement:A,boundary:u,rootBoundary:d,altBoundary:f,padding:c}),B=N?j?Fr:rr:j?Ir:nr;E[M]>S[M]&&(B=Of(B));var V=Of(B),z=[];if(o&&z.push(R[C]<=0),s&&z.push(R[B]<=0,R[V]<=0),z.every(function(J){return J})){T=A,D=!1;break}P.set(A,z)}if(D)for(var W=m?3:1,Q=function(re){var se=y.find(function(ce){var de=P.get(ce);if(de)return de.slice(0,re).every(function(K){return K})});if(se)return T=se,"break"},X=W;X>0;X--){var ie=Q(X);if(ie==="break")break}t.placement!==T&&(t.modifiersData[r]._skip=!0,t.placement=T,t.reset=!0)}}const kW={name:"flip",enabled:!0,phase:"main",fn:CW,requiresIfExists:["offset"],data:{_skip:!1}};function SS(e,t,n){return n===void 0&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function OS(e){return[nr,Fr,Ir,rr].some(function(t){return e[t]>=0})}function PW(e){var t=e.state,n=e.name,r=t.rects.reference,i=t.rects.popper,o=t.modifiersData.preventOverflow,a=Cc(t,{elementContext:"reference"}),s=Cc(t,{altBoundary:!0}),l=SS(a,r),c=SS(s,i,o),u=OS(l),d=OS(c);t.modifiersData[n]={referenceClippingOffsets:l,popperEscapeOffsets:c,isReferenceHidden:u,hasPopperEscaped:d},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":u,"data-popper-escaped":d})}const DW={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:PW};function AW(e,t,n){var r=Di(e),i=[rr,nr].indexOf(r)>=0?-1:1,o=typeof n=="function"?n(Object.assign({},t,{placement:e})):n,a=o[0],s=o[1];return a=a||0,s=(s||0)*i,[rr,Fr].indexOf(r)>=0?{x:s,y:a}:{x:a,y:s}}function TW(e){var t=e.state,n=e.options,r=e.name,i=n.offset,o=i===void 0?[0,0]:i,a=fS.reduce(function(u,d){return u[d]=AW(d,t.rects,o),u},{}),s=a[t.placement],l=s.x,c=s.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=l,t.modifiersData.popperOffsets.y+=c),t.modifiersData[r]=a}const NW={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:TW};function jW(e){var t=e.state,n=e.name;t.modifiersData[n]=ES({reference:t.rects.reference,element:t.rects.popper,placement:t.placement})}const MW={name:"popperOffsets",enabled:!0,phase:"read",fn:jW,data:{}};function IW(e){return e==="x"?"y":"x"}function FW(e){var t=e.state,n=e.options,r=e.name,i=n.mainAxis,o=i===void 0?!0:i,a=n.altAxis,s=a===void 0?!1:a,l=n.boundary,c=n.rootBoundary,u=n.altBoundary,d=n.padding,f=n.tether,p=f===void 0?!0:f,m=n.tetherOffset,g=m===void 0?0:m,v=Cc(t,{boundary:l,rootBoundary:c,padding:d,altBoundary:u}),x=Di(t.placement),_=Gs(t.placement),w=!_,y=Rg(x),E=IW(y),S=t.modifiersData.popperOffsets,P=t.rects.reference,D=t.rects.popper,T=typeof g=="function"?g(Object.assign({},t.rects,{placement:t.placement})):g,I=typeof T=="number"?{mainAxis:T,altAxis:T}:Object.assign({mainAxis:0,altAxis:0},T),A=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,C={x:0,y:0};if(S){if(o){var j,N=y==="y"?nr:rr,M=y==="y"?Ir:Fr,R=y==="y"?"height":"width",B=S[y],V=B+v[N],z=B-v[M],W=p?-D[R]/2:0,Q=_===Us?P[R]:D[R],X=_===Us?-D[R]:-P[R],ie=t.elements.arrow,J=p&&ie?Lg(ie):{width:0,height:0},re=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:gS(),se=re[N],ce=re[M],de=Sc(0,P[R],J[R]),K=w?P[R]/2-W-de-se-I.mainAxis:Q-de-se-I.mainAxis,U=w?-P[R]/2+W+de+ce+I.mainAxis:X+de+ce+I.mainAxis,Z=t.elements.arrow&&Ec(t.elements.arrow),F=Z?y==="y"?Z.clientTop||0:Z.clientLeft||0:0,ge=(j=A?.[y])!=null?j:0,oe=B+K-ge-F,ye=B+U-ge,_e=Sc(p?_f(V,oe):V,B,p?ja(z,ye):z);S[y]=_e,C[y]=_e-B}if(s){var Ie,tt=y==="x"?nr:rr,pt=y==="x"?Ir:Fr,ct=S[E],Fe=E==="y"?"height":"width",Pt=ct+v[tt],Dt=ct-v[pt],ht=[nr,rr].indexOf(x)!==-1,mn=(Ie=A?.[E])!=null?Ie:0,sn=ht?Pt:ct-P[Fe]-D[Fe]-mn+I.altAxis,gn=ht?ct+P[Fe]+D[Fe]-mn-I.altAxis:Dt,Wn=p&&ht?aW(sn,ct,gn):Sc(p?sn:Pt,ct,p?gn:Dt);S[E]=Wn,C[E]=Wn-ct}t.modifiersData[r]=C}}const LW={name:"preventOverflow",enabled:!0,phase:"main",fn:FW,requiresIfExists:["offset"]};function RW(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function $W(e){return e===br(e)||!Lr(e)?$g(e):RW(e)}function BW(e){var t=e.getBoundingClientRect(),n=Ks(t.width)/e.offsetWidth||1,r=Ks(t.height)/e.offsetHeight||1;return n!==1||r!==1}function WW(e,t,n){n===void 0&&(n=!1);var r=Lr(t),i=Lr(t)&&BW(t),o=Qo(t),a=qs(e,i,n),s={scrollLeft:0,scrollTop:0},l={x:0,y:0};return(r||!r&&!n)&&((Pi(t)!=="body"||Wg(o))&&(s=$W(t)),Lr(t)?(l=qs(t,!0),l.x+=t.clientLeft,l.y+=t.clientTop):o&&(l.x=Bg(o))),{x:a.left+s.scrollLeft-l.x,y:a.top+s.scrollTop-l.y,width:a.width,height:a.height}}function zW(e){var t=new Map,n=new Set,r=[];e.forEach(function(o){t.set(o.name,o)});function i(o){n.add(o.name);var a=[].concat(o.requires||[],o.requiresIfExists||[]);a.forEach(function(s){if(!n.has(s)){var l=t.get(s);l&&i(l)}}),r.push(o)}return e.forEach(function(o){n.has(o.name)||i(o)}),r}function VW(e){var t=zW(e);return tW.reduce(function(n,r){return n.concat(t.filter(function(i){return i.phase===r}))},[])}function HW(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function YW(e){var t=e.reduce(function(n,r){var i=n[r.name];return n[r.name]=i?Object.assign({},i,r,{options:Object.assign({},i.options,r.options),data:Object.assign({},i.data,r.data)}):r,n},{});return Object.keys(t).map(function(n){return t[n]})}var CS={placement:"bottom",modifiers:[],strategy:"absolute"};function kS(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return!t.some(function(r){return!(r&&typeof r.getBoundingClientRect=="function")})}function UW(e){e===void 0&&(e={});var t=e,n=t.defaultModifiers,r=n===void 0?[]:n,i=t.defaultOptions,o=i===void 0?CS:i;return function(s,l,c){c===void 0&&(c=o);var u={placement:"bottom",orderedModifiers:[],options:Object.assign({},CS,o),modifiersData:{},elements:{reference:s,popper:l},attributes:{},styles:{}},d=[],f=!1,p={state:u,setOptions:function(x){var _=typeof x=="function"?x(u.options):x;g(),u.options=Object.assign({},o,u.options,_),u.scrollParents={reference:Na(s)?Oc(s):s.contextElement?Oc(s.contextElement):[],popper:Oc(l)};var w=VW(YW([].concat(r,u.options.modifiers)));return u.orderedModifiers=w.filter(function(y){return y.enabled}),m(),p.update()},forceUpdate:function(){if(!f){var x=u.elements,_=x.reference,w=x.popper;if(kS(_,w)){u.rects={reference:WW(_,Ec(w),u.options.strategy==="fixed"),popper:Lg(w)},u.reset=!1,u.placement=u.options.placement,u.orderedModifiers.forEach(function(I){return u.modifiersData[I.name]=Object.assign({},I.data)});for(var y=0;y<u.orderedModifiers.length;y++){if(u.reset===!0){u.reset=!1,y=-1;continue}var E=u.orderedModifiers[y],S=E.fn,P=E.options,D=P===void 0?{}:P,T=E.name;typeof S=="function"&&(u=S({state:u,options:D,name:T,instance:p})||u)}}}},update:HW(function(){return new Promise(function(v){p.forceUpdate(),v(u)})}),destroy:function(){g(),f=!0}};if(!kS(s,l))return p;p.setOptions(c).then(function(v){!f&&c.onFirstUpdate&&c.onFirstUpdate(v)});function m(){u.orderedModifiers.forEach(function(v){var x=v.name,_=v.options,w=_===void 0?{}:_,y=v.effect;if(typeof y=="function"){var E=y({state:u,name:x,instance:p,options:w}),S=function(){};d.push(E||S)}})}function g(){d.forEach(function(v){return v()}),d=[]}return p}}var KW=[gW,MW,hW,Ig,NW,kW,LW,uW,DW],Vg=UW({defaultModifiers:KW}),qW="tippy-box",PS="tippy-content",GW="tippy-backdrop",DS="tippy-arrow",AS="tippy-svg-arrow",Ma={passive:!0,capture:!0},TS=function(){return document.body};function XW(e,t){return{}.hasOwnProperty.call(e,t)}function Hg(e,t,n){if(Array.isArray(e)){var r=e[t];return r??(Array.isArray(n)?n[t]:n)}return e}function Yg(e,t){var n={}.toString.call(e);return n.indexOf("[object")===0&&n.indexOf(t+"]")>-1}function NS(e,t){return typeof e=="function"?e.apply(void 0,t):e}function jS(e,t){if(t===0)return e;var n;return function(r){clearTimeout(n),n=setTimeout(function(){e(r)},t)}}function QW(e,t){var n=Object.assign({},e);return t.forEach(function(r){delete n[r]}),n}function ZW(e){return e.split(/\s+/).filter(Boolean)}function Xs(e){return[].concat(e)}function MS(e,t){e.indexOf(t)===-1&&e.push(t)}function JW(e){return e.filter(function(t,n){return e.indexOf(t)===n})}function ez(e){return e.split("-")[0]}function Cf(e){return[].slice.call(e)}function IS(e){return Object.keys(e).reduce(function(t,n){return e[n]!==void 0&&(t[n]=e[n]),t},{})}function kc(){return document.createElement("div")}function Pc(e){return["Element","Fragment"].some(function(t){return Yg(e,t)})}function tz(e){return Yg(e,"NodeList")}function nz(e){return Yg(e,"MouseEvent")}function rz(e){return!!(e&&e._tippy&&e._tippy.reference===e)}function iz(e){return Pc(e)?[e]:tz(e)?Cf(e):Array.isArray(e)?e:Cf(document.querySelectorAll(e))}function Ug(e,t){e.forEach(function(n){n&&(n.style.transitionDuration=t+"ms")})}function FS(e,t){e.forEach(function(n){n&&n.setAttribute("data-state",t)})}function oz(e){var t,n=Xs(e),r=n[0];return r!=null&&(t=r.ownerDocument)!=null&&t.body?r.ownerDocument:document}function az(e,t){var n=t.clientX,r=t.clientY;return e.every(function(i){var o=i.popperRect,a=i.popperState,s=i.props,l=s.interactiveBorder,c=ez(a.placement),u=a.modifiersData.offset;if(!u)return!0;var d=c==="bottom"?u.top.y:0,f=c==="top"?u.bottom.y:0,p=c==="right"?u.left.x:0,m=c==="left"?u.right.x:0,g=o.top-r+d>l,v=r-o.bottom-f>l,x=o.left-n+p>l,_=n-o.right-m>l;return g||v||x||_})}function Kg(e,t,n){var r=t+"EventListener";["transitionend","webkitTransitionEnd"].forEach(function(i){e[r](i,n)})}function LS(e,t){for(var n=t;n;){var r;if(e.contains(n))return!0;n=n.getRootNode==null||(r=n.getRootNode())==null?void 0:r.host}return!1}var Ai={isTouch:!1},RS=0;function sz(){Ai.isTouch||(Ai.isTouch=!0,window.performance&&document.addEventListener("mousemove",$S))}function $S(){var e=performance.now();e-RS<20&&(Ai.isTouch=!1,document.removeEventListener("mousemove",$S)),RS=e}function lz(){var e=document.activeElement;if(rz(e)){var t=e._tippy;e.blur&&!t.state.isVisible&&e.blur()}}function cz(){document.addEventListener("touchstart",sz,Ma),window.addEventListener("blur",lz)}var uz=typeof window<"u"&&typeof document<"u",dz=uz?!!window.msCrypto:!1;function Qs(e){var t=e==="destroy"?"n already-":" ";return[e+"() was called on a"+t+"destroyed instance. This is a no-op but","indicates a potential memory leak."].join(" ")}function BS(e){var t=/[ \t]{2,}/g,n=/^[ \t]*/gm;return e.replace(t," ").replace(n,"").trim()}function fz(e){return BS(`
|
|
124
|
+
${i?"bg-[#FBF5FF] text-[#884EA7]":"bg-white text-[#64748B] hover:bg-gray-50"}`,children:[h.jsx(r,{className:"h-[15px] w-[15px] font-bold"}),n.name]},n.name)})})}function W8(e){return gt({attr:{viewBox:"0 0 576 512"},child:[{tag:"path",attr:{d:"M384 160c-17.7 0-32-14.3-32-32s14.3-32 32-32l160 0c17.7 0 32 14.3 32 32l0 160c0 17.7-14.3 32-32 32s-32-14.3-32-32l0-82.7L342.6 374.6c-12.5 12.5-32.8 12.5-45.3 0L192 269.3 54.6 406.6c-12.5 12.5-32.8 12.5-45.3 0s-12.5-32.8 0-45.3l160-160c12.5-12.5 32.8-12.5 45.3 0L320 306.7 466.7 160 384 160z"},child:[]}]})(e)}function z8(e){return gt({attr:{viewBox:"0 0 576 512"},child:[{tag:"path",attr:{d:"M151.6 42.4C145.5 35.8 137 32 128 32s-17.5 3.8-23.6 10.4l-88 96c-11.9 13-11.1 33.3 2 45.2s33.3 11.1 45.2-2L96 146.3 96 448c0 17.7 14.3 32 32 32s32-14.3 32-32l0-301.7 32.4 35.4c11.9 13 32.2 13.9 45.2 2s13.9-32.2 2-45.2l-88-96zM320 32c-17.7 0-32 14.3-32 32s14.3 32 32 32l32 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-32 0zm0 128c-17.7 0-32 14.3-32 32s14.3 32 32 32l96 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-96 0zm0 128c-17.7 0-32 14.3-32 32s14.3 32 32 32l160 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-160 0zm0 128c-17.7 0-32 14.3-32 32s14.3 32 32 32l224 0c17.7 0 32-14.3 32-32s-14.3-32-32-32l-224 0z"},child:[]}]})(e)}function V8(e){return gt({attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M464 256A208 208 0 1 1 48 256a208 208 0 1 1 416 0zM0 256a256 256 0 1 0 512 0A256 256 0 1 0 0 256zM232 120l0 136c0 8 4 15.5 10.7 20l96 64c11 7.4 25.9 4.4 33.3-6.7s4.4-25.9-6.7-33.3L280 243.2 280 120c0-13.3-10.7-24-24-24s-24 10.7-24 24z"},child:[]}]})(e)}var nr="top",Ir="bottom",Fr="right",rr="left",jg="auto",xc=[nr,Ir,Fr,rr],Us="start",wc="end",H8="clippingParents",uS="viewport",_c="popper",Y8="reference",dS=xc.reduce(function(e,t){return e.concat([t+"-"+Us,t+"-"+wc])},[]),fS=[].concat(xc,[jg]).reduce(function(e,t){return e.concat([t,t+"-"+Us,t+"-"+wc])},[]),U8="beforeRead",K8="read",q8="afterRead",G8="beforeMain",X8="main",Q8="afterMain",Z8="beforeWrite",J8="write",eW="afterWrite",tW=[U8,K8,q8,G8,X8,Q8,Z8,J8,eW];function Pi(e){return e?(e.nodeName||"").toLowerCase():null}function br(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function Na(e){var t=br(e).Element;return e instanceof t||e instanceof Element}function Lr(e){var t=br(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function Mg(e){if(typeof ShadowRoot>"u")return!1;var t=br(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function nW(e){var t=e.state;Object.keys(t.elements).forEach(function(n){var r=t.styles[n]||{},i=t.attributes[n]||{},o=t.elements[n];!Lr(o)||!Pi(o)||(Object.assign(o.style,r),Object.keys(i).forEach(function(a){var s=i[a];s===!1?o.removeAttribute(a):o.setAttribute(a,s===!0?"":s)}))})}function rW(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach(function(r){var i=t.elements[r],o=t.attributes[r]||{},a=Object.keys(t.styles.hasOwnProperty(r)?t.styles[r]:n[r]),s=a.reduce(function(l,c){return l[c]="",l},{});!Lr(i)||!Pi(i)||(Object.assign(i.style,s),Object.keys(o).forEach(function(l){i.removeAttribute(l)}))})}}const Ig={name:"applyStyles",enabled:!0,phase:"write",fn:nW,effect:rW,requires:["computeStyles"]};function Di(e){return e.split("-")[0]}var ja=Math.max,_f=Math.min,Ks=Math.round;function Fg(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function pS(){return!/^((?!chrome|android).)*safari/i.test(Fg())}function qs(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!1);var r=e.getBoundingClientRect(),i=1,o=1;t&&Lr(e)&&(i=e.offsetWidth>0&&Ks(r.width)/e.offsetWidth||1,o=e.offsetHeight>0&&Ks(r.height)/e.offsetHeight||1);var a=Na(e)?br(e):window,s=a.visualViewport,l=!pS()&&n,c=(r.left+(l&&s?s.offsetLeft:0))/i,u=(r.top+(l&&s?s.offsetTop:0))/o,d=r.width/i,f=r.height/o;return{width:d,height:f,top:u,right:c+d,bottom:u+f,left:c,x:c,y:u}}function Lg(e){var t=qs(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-r)<=1&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function hS(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&Mg(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function so(e){return br(e).getComputedStyle(e)}function iW(e){return["table","td","th"].indexOf(Pi(e))>=0}function Qo(e){return((Na(e)?e.ownerDocument:e.document)||window.document).documentElement}function Ef(e){return Pi(e)==="html"?e:e.assignedSlot||e.parentNode||(Mg(e)?e.host:null)||Qo(e)}function mS(e){return!Lr(e)||so(e).position==="fixed"?null:e.offsetParent}function oW(e){var t=/firefox/i.test(Fg()),n=/Trident/i.test(Fg());if(n&&Lr(e)){var r=so(e);if(r.position==="fixed")return null}var i=Ef(e);for(Mg(i)&&(i=i.host);Lr(i)&&["html","body"].indexOf(Pi(i))<0;){var o=so(i);if(o.transform!=="none"||o.perspective!=="none"||o.contain==="paint"||["transform","perspective"].indexOf(o.willChange)!==-1||t&&o.willChange==="filter"||t&&o.filter&&o.filter!=="none")return i;i=i.parentNode}return null}function Ec(e){for(var t=br(e),n=mS(e);n&&iW(n)&&so(n).position==="static";)n=mS(n);return n&&(Pi(n)==="html"||Pi(n)==="body"&&so(n).position==="static")?t:n||oW(e)||t}function Rg(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function Sc(e,t,n){return ja(e,_f(t,n))}function aW(e,t,n){var r=Sc(e,t,n);return r>n?n:r}function gS(){return{top:0,right:0,bottom:0,left:0}}function vS(e){return Object.assign({},gS(),e)}function yS(e,t){return t.reduce(function(n,r){return n[r]=e,n},{})}var sW=function(t,n){return t=typeof t=="function"?t(Object.assign({},n.rects,{placement:n.placement})):t,vS(typeof t!="number"?t:yS(t,xc))};function lW(e){var t,n=e.state,r=e.name,i=e.options,o=n.elements.arrow,a=n.modifiersData.popperOffsets,s=Di(n.placement),l=Rg(s),c=[rr,Fr].indexOf(s)>=0,u=c?"height":"width";if(!(!o||!a)){var d=sW(i.padding,n),f=Lg(o),p=l==="y"?nr:rr,m=l==="y"?Ir:Fr,g=n.rects.reference[u]+n.rects.reference[l]-a[l]-n.rects.popper[u],v=a[l]-n.rects.reference[l],x=Ec(o),_=x?l==="y"?x.clientHeight||0:x.clientWidth||0:0,w=g/2-v/2,y=d[p],E=_-f[u]-d[m],S=_/2-f[u]/2+w,P=Sc(y,S,E),D=l;n.modifiersData[r]=(t={},t[D]=P,t.centerOffset=P-S,t)}}function cW(e){var t=e.state,n=e.options,r=n.element,i=r===void 0?"[data-popper-arrow]":r;i!=null&&(typeof i=="string"&&(i=t.elements.popper.querySelector(i),!i)||hS(t.elements.popper,i)&&(t.elements.arrow=i))}const uW={name:"arrow",enabled:!0,phase:"main",fn:lW,effect:cW,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function Gs(e){return e.split("-")[1]}var dW={top:"auto",right:"auto",bottom:"auto",left:"auto"};function fW(e,t){var n=e.x,r=e.y,i=t.devicePixelRatio||1;return{x:Ks(n*i)/i||0,y:Ks(r*i)/i||0}}function bS(e){var t,n=e.popper,r=e.popperRect,i=e.placement,o=e.variation,a=e.offsets,s=e.position,l=e.gpuAcceleration,c=e.adaptive,u=e.roundOffsets,d=e.isFixed,f=a.x,p=f===void 0?0:f,m=a.y,g=m===void 0?0:m,v=typeof u=="function"?u({x:p,y:g}):{x:p,y:g};p=v.x,g=v.y;var x=a.hasOwnProperty("x"),_=a.hasOwnProperty("y"),w=rr,y=nr,E=window;if(c){var S=Ec(n),P="clientHeight",D="clientWidth";if(S===br(n)&&(S=Qo(n),so(S).position!=="static"&&s==="absolute"&&(P="scrollHeight",D="scrollWidth")),S=S,i===nr||(i===rr||i===Fr)&&o===wc){y=Ir;var T=d&&S===E&&E.visualViewport?E.visualViewport.height:S[P];g-=T-r.height,g*=l?1:-1}if(i===rr||(i===nr||i===Ir)&&o===wc){w=Fr;var I=d&&S===E&&E.visualViewport?E.visualViewport.width:S[D];p-=I-r.width,p*=l?1:-1}}var A=Object.assign({position:s},c&&dW),C=u===!0?fW({x:p,y:g},br(n)):{x:p,y:g};if(p=C.x,g=C.y,l){var j;return Object.assign({},A,(j={},j[y]=_?"0":"",j[w]=x?"0":"",j.transform=(E.devicePixelRatio||1)<=1?"translate("+p+"px, "+g+"px)":"translate3d("+p+"px, "+g+"px, 0)",j))}return Object.assign({},A,(t={},t[y]=_?g+"px":"",t[w]=x?p+"px":"",t.transform="",t))}function pW(e){var t=e.state,n=e.options,r=n.gpuAcceleration,i=r===void 0?!0:r,o=n.adaptive,a=o===void 0?!0:o,s=n.roundOffsets,l=s===void 0?!0:s,c={placement:Di(t.placement),variation:Gs(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:i,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,bS(Object.assign({},c,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:a,roundOffsets:l})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,bS(Object.assign({},c,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:l})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const hW={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:pW,data:{}};var Sf={passive:!0};function mW(e){var t=e.state,n=e.instance,r=e.options,i=r.scroll,o=i===void 0?!0:i,a=r.resize,s=a===void 0?!0:a,l=br(t.elements.popper),c=[].concat(t.scrollParents.reference,t.scrollParents.popper);return o&&c.forEach(function(u){u.addEventListener("scroll",n.update,Sf)}),s&&l.addEventListener("resize",n.update,Sf),function(){o&&c.forEach(function(u){u.removeEventListener("scroll",n.update,Sf)}),s&&l.removeEventListener("resize",n.update,Sf)}}const gW={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:mW,data:{}};var vW={left:"right",right:"left",bottom:"top",top:"bottom"};function Of(e){return e.replace(/left|right|bottom|top/g,function(t){return vW[t]})}var yW={start:"end",end:"start"};function xS(e){return e.replace(/start|end/g,function(t){return yW[t]})}function $g(e){var t=br(e),n=t.pageXOffset,r=t.pageYOffset;return{scrollLeft:n,scrollTop:r}}function Bg(e){return qs(Qo(e)).left+$g(e).scrollLeft}function bW(e,t){var n=br(e),r=Qo(e),i=n.visualViewport,o=r.clientWidth,a=r.clientHeight,s=0,l=0;if(i){o=i.width,a=i.height;var c=pS();(c||!c&&t==="fixed")&&(s=i.offsetLeft,l=i.offsetTop)}return{width:o,height:a,x:s+Bg(e),y:l}}function xW(e){var t,n=Qo(e),r=$g(e),i=(t=e.ownerDocument)==null?void 0:t.body,o=ja(n.scrollWidth,n.clientWidth,i?i.scrollWidth:0,i?i.clientWidth:0),a=ja(n.scrollHeight,n.clientHeight,i?i.scrollHeight:0,i?i.clientHeight:0),s=-r.scrollLeft+Bg(e),l=-r.scrollTop;return so(i||n).direction==="rtl"&&(s+=ja(n.clientWidth,i?i.clientWidth:0)-o),{width:o,height:a,x:s,y:l}}function Wg(e){var t=so(e),n=t.overflow,r=t.overflowX,i=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+i+r)}function wS(e){return["html","body","#document"].indexOf(Pi(e))>=0?e.ownerDocument.body:Lr(e)&&Wg(e)?e:wS(Ef(e))}function Oc(e,t){var n;t===void 0&&(t=[]);var r=wS(e),i=r===((n=e.ownerDocument)==null?void 0:n.body),o=br(r),a=i?[o].concat(o.visualViewport||[],Wg(r)?r:[]):r,s=t.concat(a);return i?s:s.concat(Oc(Ef(a)))}function zg(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function wW(e,t){var n=qs(e,!1,t==="fixed");return n.top=n.top+e.clientTop,n.left=n.left+e.clientLeft,n.bottom=n.top+e.clientHeight,n.right=n.left+e.clientWidth,n.width=e.clientWidth,n.height=e.clientHeight,n.x=n.left,n.y=n.top,n}function _S(e,t,n){return t===uS?zg(bW(e,n)):Na(t)?wW(t,n):zg(xW(Qo(e)))}function _W(e){var t=Oc(Ef(e)),n=["absolute","fixed"].indexOf(so(e).position)>=0,r=n&&Lr(e)?Ec(e):e;return Na(r)?t.filter(function(i){return Na(i)&&hS(i,r)&&Pi(i)!=="body"}):[]}function EW(e,t,n,r){var i=t==="clippingParents"?_W(e):[].concat(t),o=[].concat(i,[n]),a=o[0],s=o.reduce(function(l,c){var u=_S(e,c,r);return l.top=ja(u.top,l.top),l.right=_f(u.right,l.right),l.bottom=_f(u.bottom,l.bottom),l.left=ja(u.left,l.left),l},_S(e,a,r));return s.width=s.right-s.left,s.height=s.bottom-s.top,s.x=s.left,s.y=s.top,s}function ES(e){var t=e.reference,n=e.element,r=e.placement,i=r?Di(r):null,o=r?Gs(r):null,a=t.x+t.width/2-n.width/2,s=t.y+t.height/2-n.height/2,l;switch(i){case nr:l={x:a,y:t.y-n.height};break;case Ir:l={x:a,y:t.y+t.height};break;case Fr:l={x:t.x+t.width,y:s};break;case rr:l={x:t.x-n.width,y:s};break;default:l={x:t.x,y:t.y}}var c=i?Rg(i):null;if(c!=null){var u=c==="y"?"height":"width";switch(o){case Us:l[c]=l[c]-(t[u]/2-n[u]/2);break;case wc:l[c]=l[c]+(t[u]/2-n[u]/2);break}}return l}function Cc(e,t){t===void 0&&(t={});var n=t,r=n.placement,i=r===void 0?e.placement:r,o=n.strategy,a=o===void 0?e.strategy:o,s=n.boundary,l=s===void 0?H8:s,c=n.rootBoundary,u=c===void 0?uS:c,d=n.elementContext,f=d===void 0?_c:d,p=n.altBoundary,m=p===void 0?!1:p,g=n.padding,v=g===void 0?0:g,x=vS(typeof v!="number"?v:yS(v,xc)),_=f===_c?Y8:_c,w=e.rects.popper,y=e.elements[m?_:f],E=EW(Na(y)?y:y.contextElement||Qo(e.elements.popper),l,u,a),S=qs(e.elements.reference),P=ES({reference:S,element:w,placement:i}),D=zg(Object.assign({},w,P)),T=f===_c?D:S,I={top:E.top-T.top+x.top,bottom:T.bottom-E.bottom+x.bottom,left:E.left-T.left+x.left,right:T.right-E.right+x.right},A=e.modifiersData.offset;if(f===_c&&A){var C=A[i];Object.keys(I).forEach(function(j){var N=[Fr,Ir].indexOf(j)>=0?1:-1,M=[nr,Ir].indexOf(j)>=0?"y":"x";I[j]+=C[M]*N})}return I}function SW(e,t){t===void 0&&(t={});var n=t,r=n.placement,i=n.boundary,o=n.rootBoundary,a=n.padding,s=n.flipVariations,l=n.allowedAutoPlacements,c=l===void 0?fS:l,u=Gs(r),d=u?s?dS:dS.filter(function(m){return Gs(m)===u}):xc,f=d.filter(function(m){return c.indexOf(m)>=0});f.length===0&&(f=d);var p=f.reduce(function(m,g){return m[g]=Cc(e,{placement:g,boundary:i,rootBoundary:o,padding:a})[Di(g)],m},{});return Object.keys(p).sort(function(m,g){return p[m]-p[g]})}function OW(e){if(Di(e)===jg)return[];var t=Of(e);return[xS(e),t,xS(t)]}function CW(e){var t=e.state,n=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var i=n.mainAxis,o=i===void 0?!0:i,a=n.altAxis,s=a===void 0?!0:a,l=n.fallbackPlacements,c=n.padding,u=n.boundary,d=n.rootBoundary,f=n.altBoundary,p=n.flipVariations,m=p===void 0?!0:p,g=n.allowedAutoPlacements,v=t.options.placement,x=Di(v),_=x===v,w=l||(_||!m?[Of(v)]:OW(v)),y=[v].concat(w).reduce(function(J,re){return J.concat(Di(re)===jg?SW(t,{placement:re,boundary:u,rootBoundary:d,padding:c,flipVariations:m,allowedAutoPlacements:g}):re)},[]),E=t.rects.reference,S=t.rects.popper,P=new Map,D=!0,T=y[0],I=0;I<y.length;I++){var A=y[I],C=Di(A),j=Gs(A)===Us,N=[nr,Ir].indexOf(C)>=0,M=N?"width":"height",R=Cc(t,{placement:A,boundary:u,rootBoundary:d,altBoundary:f,padding:c}),B=N?j?Fr:rr:j?Ir:nr;E[M]>S[M]&&(B=Of(B));var V=Of(B),z=[];if(o&&z.push(R[C]<=0),s&&z.push(R[B]<=0,R[V]<=0),z.every(function(J){return J})){T=A,D=!1;break}P.set(A,z)}if(D)for(var W=m?3:1,Q=function(re){var se=y.find(function(ce){var de=P.get(ce);if(de)return de.slice(0,re).every(function(K){return K})});if(se)return T=se,"break"},G=W;G>0;G--){var ie=Q(G);if(ie==="break")break}t.placement!==T&&(t.modifiersData[r]._skip=!0,t.placement=T,t.reset=!0)}}const kW={name:"flip",enabled:!0,phase:"main",fn:CW,requiresIfExists:["offset"],data:{_skip:!1}};function SS(e,t,n){return n===void 0&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function OS(e){return[nr,Fr,Ir,rr].some(function(t){return e[t]>=0})}function PW(e){var t=e.state,n=e.name,r=t.rects.reference,i=t.rects.popper,o=t.modifiersData.preventOverflow,a=Cc(t,{elementContext:"reference"}),s=Cc(t,{altBoundary:!0}),l=SS(a,r),c=SS(s,i,o),u=OS(l),d=OS(c);t.modifiersData[n]={referenceClippingOffsets:l,popperEscapeOffsets:c,isReferenceHidden:u,hasPopperEscaped:d},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":u,"data-popper-escaped":d})}const DW={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:PW};function AW(e,t,n){var r=Di(e),i=[rr,nr].indexOf(r)>=0?-1:1,o=typeof n=="function"?n(Object.assign({},t,{placement:e})):n,a=o[0],s=o[1];return a=a||0,s=(s||0)*i,[rr,Fr].indexOf(r)>=0?{x:s,y:a}:{x:a,y:s}}function TW(e){var t=e.state,n=e.options,r=e.name,i=n.offset,o=i===void 0?[0,0]:i,a=fS.reduce(function(u,d){return u[d]=AW(d,t.rects,o),u},{}),s=a[t.placement],l=s.x,c=s.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=l,t.modifiersData.popperOffsets.y+=c),t.modifiersData[r]=a}const NW={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:TW};function jW(e){var t=e.state,n=e.name;t.modifiersData[n]=ES({reference:t.rects.reference,element:t.rects.popper,placement:t.placement})}const MW={name:"popperOffsets",enabled:!0,phase:"read",fn:jW,data:{}};function IW(e){return e==="x"?"y":"x"}function FW(e){var t=e.state,n=e.options,r=e.name,i=n.mainAxis,o=i===void 0?!0:i,a=n.altAxis,s=a===void 0?!1:a,l=n.boundary,c=n.rootBoundary,u=n.altBoundary,d=n.padding,f=n.tether,p=f===void 0?!0:f,m=n.tetherOffset,g=m===void 0?0:m,v=Cc(t,{boundary:l,rootBoundary:c,padding:d,altBoundary:u}),x=Di(t.placement),_=Gs(t.placement),w=!_,y=Rg(x),E=IW(y),S=t.modifiersData.popperOffsets,P=t.rects.reference,D=t.rects.popper,T=typeof g=="function"?g(Object.assign({},t.rects,{placement:t.placement})):g,I=typeof T=="number"?{mainAxis:T,altAxis:T}:Object.assign({mainAxis:0,altAxis:0},T),A=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,C={x:0,y:0};if(S){if(o){var j,N=y==="y"?nr:rr,M=y==="y"?Ir:Fr,R=y==="y"?"height":"width",B=S[y],V=B+v[N],z=B-v[M],W=p?-D[R]/2:0,Q=_===Us?P[R]:D[R],G=_===Us?-D[R]:-P[R],ie=t.elements.arrow,J=p&&ie?Lg(ie):{width:0,height:0},re=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:gS(),se=re[N],ce=re[M],de=Sc(0,P[R],J[R]),K=w?P[R]/2-W-de-se-I.mainAxis:Q-de-se-I.mainAxis,U=w?-P[R]/2+W+de+ce+I.mainAxis:G+de+ce+I.mainAxis,Z=t.elements.arrow&&Ec(t.elements.arrow),F=Z?y==="y"?Z.clientTop||0:Z.clientLeft||0:0,ge=(j=A?.[y])!=null?j:0,oe=B+K-ge-F,ye=B+U-ge,_e=Sc(p?_f(V,oe):V,B,p?ja(z,ye):z);S[y]=_e,C[y]=_e-B}if(s){var Ie,tt=y==="x"?nr:rr,pt=y==="x"?Ir:Fr,ct=S[E],Fe=E==="y"?"height":"width",Pt=ct+v[tt],Dt=ct-v[pt],ht=[nr,rr].indexOf(x)!==-1,mn=(Ie=A?.[E])!=null?Ie:0,sn=ht?Pt:ct-P[Fe]-D[Fe]-mn+I.altAxis,gn=ht?ct+P[Fe]+D[Fe]-mn-I.altAxis:Dt,Wn=p&&ht?aW(sn,ct,gn):Sc(p?sn:Pt,ct,p?gn:Dt);S[E]=Wn,C[E]=Wn-ct}t.modifiersData[r]=C}}const LW={name:"preventOverflow",enabled:!0,phase:"main",fn:FW,requiresIfExists:["offset"]};function RW(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function $W(e){return e===br(e)||!Lr(e)?$g(e):RW(e)}function BW(e){var t=e.getBoundingClientRect(),n=Ks(t.width)/e.offsetWidth||1,r=Ks(t.height)/e.offsetHeight||1;return n!==1||r!==1}function WW(e,t,n){n===void 0&&(n=!1);var r=Lr(t),i=Lr(t)&&BW(t),o=Qo(t),a=qs(e,i,n),s={scrollLeft:0,scrollTop:0},l={x:0,y:0};return(r||!r&&!n)&&((Pi(t)!=="body"||Wg(o))&&(s=$W(t)),Lr(t)?(l=qs(t,!0),l.x+=t.clientLeft,l.y+=t.clientTop):o&&(l.x=Bg(o))),{x:a.left+s.scrollLeft-l.x,y:a.top+s.scrollTop-l.y,width:a.width,height:a.height}}function zW(e){var t=new Map,n=new Set,r=[];e.forEach(function(o){t.set(o.name,o)});function i(o){n.add(o.name);var a=[].concat(o.requires||[],o.requiresIfExists||[]);a.forEach(function(s){if(!n.has(s)){var l=t.get(s);l&&i(l)}}),r.push(o)}return e.forEach(function(o){n.has(o.name)||i(o)}),r}function VW(e){var t=zW(e);return tW.reduce(function(n,r){return n.concat(t.filter(function(i){return i.phase===r}))},[])}function HW(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function YW(e){var t=e.reduce(function(n,r){var i=n[r.name];return n[r.name]=i?Object.assign({},i,r,{options:Object.assign({},i.options,r.options),data:Object.assign({},i.data,r.data)}):r,n},{});return Object.keys(t).map(function(n){return t[n]})}var CS={placement:"bottom",modifiers:[],strategy:"absolute"};function kS(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return!t.some(function(r){return!(r&&typeof r.getBoundingClientRect=="function")})}function UW(e){e===void 0&&(e={});var t=e,n=t.defaultModifiers,r=n===void 0?[]:n,i=t.defaultOptions,o=i===void 0?CS:i;return function(s,l,c){c===void 0&&(c=o);var u={placement:"bottom",orderedModifiers:[],options:Object.assign({},CS,o),modifiersData:{},elements:{reference:s,popper:l},attributes:{},styles:{}},d=[],f=!1,p={state:u,setOptions:function(x){var _=typeof x=="function"?x(u.options):x;g(),u.options=Object.assign({},o,u.options,_),u.scrollParents={reference:Na(s)?Oc(s):s.contextElement?Oc(s.contextElement):[],popper:Oc(l)};var w=VW(YW([].concat(r,u.options.modifiers)));return u.orderedModifiers=w.filter(function(y){return y.enabled}),m(),p.update()},forceUpdate:function(){if(!f){var x=u.elements,_=x.reference,w=x.popper;if(kS(_,w)){u.rects={reference:WW(_,Ec(w),u.options.strategy==="fixed"),popper:Lg(w)},u.reset=!1,u.placement=u.options.placement,u.orderedModifiers.forEach(function(I){return u.modifiersData[I.name]=Object.assign({},I.data)});for(var y=0;y<u.orderedModifiers.length;y++){if(u.reset===!0){u.reset=!1,y=-1;continue}var E=u.orderedModifiers[y],S=E.fn,P=E.options,D=P===void 0?{}:P,T=E.name;typeof S=="function"&&(u=S({state:u,options:D,name:T,instance:p})||u)}}}},update:HW(function(){return new Promise(function(v){p.forceUpdate(),v(u)})}),destroy:function(){g(),f=!0}};if(!kS(s,l))return p;p.setOptions(c).then(function(v){!f&&c.onFirstUpdate&&c.onFirstUpdate(v)});function m(){u.orderedModifiers.forEach(function(v){var x=v.name,_=v.options,w=_===void 0?{}:_,y=v.effect;if(typeof y=="function"){var E=y({state:u,name:x,instance:p,options:w}),S=function(){};d.push(E||S)}})}function g(){d.forEach(function(v){return v()}),d=[]}return p}}var KW=[gW,MW,hW,Ig,NW,kW,LW,uW,DW],Vg=UW({defaultModifiers:KW}),qW="tippy-box",PS="tippy-content",GW="tippy-backdrop",DS="tippy-arrow",AS="tippy-svg-arrow",Ma={passive:!0,capture:!0},TS=function(){return document.body};function XW(e,t){return{}.hasOwnProperty.call(e,t)}function Hg(e,t,n){if(Array.isArray(e)){var r=e[t];return r??(Array.isArray(n)?n[t]:n)}return e}function Yg(e,t){var n={}.toString.call(e);return n.indexOf("[object")===0&&n.indexOf(t+"]")>-1}function NS(e,t){return typeof e=="function"?e.apply(void 0,t):e}function jS(e,t){if(t===0)return e;var n;return function(r){clearTimeout(n),n=setTimeout(function(){e(r)},t)}}function QW(e,t){var n=Object.assign({},e);return t.forEach(function(r){delete n[r]}),n}function ZW(e){return e.split(/\s+/).filter(Boolean)}function Xs(e){return[].concat(e)}function MS(e,t){e.indexOf(t)===-1&&e.push(t)}function JW(e){return e.filter(function(t,n){return e.indexOf(t)===n})}function ez(e){return e.split("-")[0]}function Cf(e){return[].slice.call(e)}function IS(e){return Object.keys(e).reduce(function(t,n){return e[n]!==void 0&&(t[n]=e[n]),t},{})}function kc(){return document.createElement("div")}function Pc(e){return["Element","Fragment"].some(function(t){return Yg(e,t)})}function tz(e){return Yg(e,"NodeList")}function nz(e){return Yg(e,"MouseEvent")}function rz(e){return!!(e&&e._tippy&&e._tippy.reference===e)}function iz(e){return Pc(e)?[e]:tz(e)?Cf(e):Array.isArray(e)?e:Cf(document.querySelectorAll(e))}function Ug(e,t){e.forEach(function(n){n&&(n.style.transitionDuration=t+"ms")})}function FS(e,t){e.forEach(function(n){n&&n.setAttribute("data-state",t)})}function oz(e){var t,n=Xs(e),r=n[0];return r!=null&&(t=r.ownerDocument)!=null&&t.body?r.ownerDocument:document}function az(e,t){var n=t.clientX,r=t.clientY;return e.every(function(i){var o=i.popperRect,a=i.popperState,s=i.props,l=s.interactiveBorder,c=ez(a.placement),u=a.modifiersData.offset;if(!u)return!0;var d=c==="bottom"?u.top.y:0,f=c==="top"?u.bottom.y:0,p=c==="right"?u.left.x:0,m=c==="left"?u.right.x:0,g=o.top-r+d>l,v=r-o.bottom-f>l,x=o.left-n+p>l,_=n-o.right-m>l;return g||v||x||_})}function Kg(e,t,n){var r=t+"EventListener";["transitionend","webkitTransitionEnd"].forEach(function(i){e[r](i,n)})}function LS(e,t){for(var n=t;n;){var r;if(e.contains(n))return!0;n=n.getRootNode==null||(r=n.getRootNode())==null?void 0:r.host}return!1}var Ai={isTouch:!1},RS=0;function sz(){Ai.isTouch||(Ai.isTouch=!0,window.performance&&document.addEventListener("mousemove",$S))}function $S(){var e=performance.now();e-RS<20&&(Ai.isTouch=!1,document.removeEventListener("mousemove",$S)),RS=e}function lz(){var e=document.activeElement;if(rz(e)){var t=e._tippy;e.blur&&!t.state.isVisible&&e.blur()}}function cz(){document.addEventListener("touchstart",sz,Ma),window.addEventListener("blur",lz)}var uz=typeof window<"u"&&typeof document<"u",dz=uz?!!window.msCrypto:!1;function Qs(e){var t=e==="destroy"?"n already-":" ";return[e+"() was called on a"+t+"destroyed instance. This is a no-op but","indicates a potential memory leak."].join(" ")}function BS(e){var t=/[ \t]{2,}/g,n=/^[ \t]*/gm;return e.replace(t," ").replace(n,"").trim()}function fz(e){return BS(`
|
|
125
125
|
%ctippy.js
|
|
126
126
|
|
|
127
127
|
%c`+BS(e)+`
|
|
@@ -130,7 +130,7 @@ To suppress this warning, you need to explicitly provide the \`palette.${t}Chann
|
|
|
130
130
|
`)}function WS(e){return[fz(e),"color: #00C584; font-size: 1.3em; font-weight: bold;","line-height: 1.5","color: #a6a095;"]}var Dc;process.env.NODE_ENV!=="production"&&pz();function pz(){Dc=new Set}function lo(e,t){if(e&&!Dc.has(t)){var n;Dc.add(t),(n=console).warn.apply(n,WS(t))}}function qg(e,t){if(e&&!Dc.has(t)){var n;Dc.add(t),(n=console).error.apply(n,WS(t))}}function hz(e){var t=!e,n=Object.prototype.toString.call(e)==="[object Object]"&&!e.addEventListener;qg(t,["tippy() was passed","`"+String(e)+"`","as its targets (first) argument. Valid types are: String, Element,","Element[], or NodeList."].join(" ")),qg(n,["tippy() was passed a plain object which is not supported as an argument","for virtual positioning. Use props.getReferenceClientRect instead."].join(" "))}var zS={animateFill:!1,followCursor:!1,inlinePositioning:!1,sticky:!1},mz={allowHTML:!1,animation:"fade",arrow:!0,content:"",inertia:!1,maxWidth:350,role:"tooltip",theme:"",zIndex:9999},xr=Object.assign({appendTo:TS,aria:{content:"auto",expanded:"auto"},delay:0,duration:[300,250],getReferenceClientRect:null,hideOnClick:!0,ignoreAttributes:!1,interactive:!1,interactiveBorder:2,interactiveDebounce:0,moveTransition:"",offset:[0,10],onAfterUpdate:function(){},onBeforeUpdate:function(){},onCreate:function(){},onDestroy:function(){},onHidden:function(){},onHide:function(){},onMount:function(){},onShow:function(){},onShown:function(){},onTrigger:function(){},onUntrigger:function(){},onClickOutside:function(){},placement:"top",plugins:[],popperOptions:{},render:null,showOnCreate:!1,touch:!0,trigger:"mouseenter focus",triggerTarget:null},zS,mz),gz=Object.keys(xr),vz=function(t){process.env.NODE_ENV!=="production"&&YS(t,[]);var n=Object.keys(t);n.forEach(function(r){xr[r]=t[r]})};function VS(e){var t=e.plugins||[],n=t.reduce(function(r,i){var o=i.name,a=i.defaultValue;if(o){var s;r[o]=e[o]!==void 0?e[o]:(s=xr[o])!=null?s:a}return r},{});return Object.assign({},e,n)}function yz(e,t){var n=t?Object.keys(VS(Object.assign({},xr,{plugins:t}))):gz,r=n.reduce(function(i,o){var a=(e.getAttribute("data-tippy-"+o)||"").trim();if(!a)return i;if(o==="content")i[o]=a;else try{i[o]=JSON.parse(a)}catch{i[o]=a}return i},{});return r}function HS(e,t){var n=Object.assign({},t,{content:NS(t.content,[e])},t.ignoreAttributes?{}:yz(e,t.plugins));return n.aria=Object.assign({},xr.aria,n.aria),n.aria={expanded:n.aria.expanded==="auto"?t.interactive:n.aria.expanded,content:n.aria.content==="auto"?t.interactive?null:"describedby":n.aria.content},n}function YS(e,t){e===void 0&&(e={}),t===void 0&&(t=[]);var n=Object.keys(e);n.forEach(function(r){var i=QW(xr,Object.keys(zS)),o=!XW(i,r);o&&(o=t.filter(function(a){return a.name===r}).length===0),lo(o,["`"+r+"`","is not a valid prop. You may have spelled it incorrectly, or if it's","a plugin, forgot to pass it in an array as props.plugins.",`
|
|
131
131
|
|
|
132
132
|
`,`All props: https://atomiks.github.io/tippyjs/v6/all-props/
|
|
133
|
-
`,"Plugins: https://atomiks.github.io/tippyjs/v6/plugins/"].join(" "))})}var bz=function(){return"innerHTML"};function Gg(e,t){e[bz()]=t}function US(e){var t=kc();return e===!0?t.className=DS:(t.className=AS,Pc(e)?t.appendChild(e):Gg(t,e)),t}function KS(e,t){Pc(t.content)?(Gg(e,""),e.appendChild(t.content)):typeof t.content!="function"&&(t.allowHTML?Gg(e,t.content):e.textContent=t.content)}function Xg(e){var t=e.firstElementChild,n=Cf(t.children);return{box:t,content:n.find(function(r){return r.classList.contains(PS)}),arrow:n.find(function(r){return r.classList.contains(DS)||r.classList.contains(AS)}),backdrop:n.find(function(r){return r.classList.contains(GW)})}}function qS(e){var t=kc(),n=kc();n.className=qW,n.setAttribute("data-state","hidden"),n.setAttribute("tabindex","-1");var r=kc();r.className=PS,r.setAttribute("data-state","hidden"),KS(r,e.props),t.appendChild(n),n.appendChild(r),i(e.props,e.props);function i(o,a){var s=Xg(t),l=s.box,c=s.content,u=s.arrow;a.theme?l.setAttribute("data-theme",a.theme):l.removeAttribute("data-theme"),typeof a.animation=="string"?l.setAttribute("data-animation",a.animation):l.removeAttribute("data-animation"),a.inertia?l.setAttribute("data-inertia",""):l.removeAttribute("data-inertia"),l.style.maxWidth=typeof a.maxWidth=="number"?a.maxWidth+"px":a.maxWidth,a.role?l.setAttribute("role",a.role):l.removeAttribute("role"),(o.content!==a.content||o.allowHTML!==a.allowHTML)&&KS(c,e.props),a.arrow?u?o.arrow!==a.arrow&&(l.removeChild(u),l.appendChild(US(a.arrow))):l.appendChild(US(a.arrow)):u&&l.removeChild(u)}return{popper:t,onUpdate:i}}qS.$$tippy=!0;var xz=1,kf=[],Qg=[];function wz(e,t){var n=HS(e,Object.assign({},xr,VS(IS(t)))),r,i,o,a=!1,s=!1,l=!1,c=!1,u,d,f,p=[],m=jS(oe,n.interactiveDebounce),g,v=xz++,x=null,_=JW(n.plugins),w={isEnabled:!0,isVisible:!1,isDestroyed:!1,isMounted:!1,isShown:!1},y={id:v,reference:e,popper:kc(),popperInstance:x,props:n,state:w,plugins:_,clearDelayTimeouts:sn,setProps:gn,setContent:Wn,show:Xt,hide:zn,hideWithInteractivity:be,enable:ht,disable:mn,unmount:vn,destroy:Qt};if(!n.render)return process.env.NODE_ENV!=="production"&&qg(!0,"render() function has not been supplied."),y;var E=n.render(y),S=E.popper,P=E.onUpdate;S.setAttribute("data-tippy-root",""),S.id="tippy-"+y.id,y.popper=S,e._tippy=y,S._tippy=y;var D=_.map(function(L){return L.fn(y)}),T=e.hasAttribute("aria-expanded");return Z(),W(),B(),V("onCreate",[y]),n.showOnCreate&&Pt(),S.addEventListener("mouseenter",function(){y.props.interactive&&y.state.isVisible&&y.clearDelayTimeouts()}),S.addEventListener("mouseleave",function(){y.props.interactive&&y.props.trigger.indexOf("mouseenter")>=0&&N().addEventListener("mousemove",m)}),y;function I(){var L=y.props.touch;return Array.isArray(L)?L:[L,0]}function A(){return I()[0]==="hold"}function C(){var L;return!!((L=y.props.render)!=null&&L.$$tippy)}function j(){return g||e}function N(){var L=j().parentNode;return L?oz(L):document}function M(){return Xg(S)}function R(L){return y.state.isMounted&&!y.state.isVisible||Ai.isTouch||u&&u.type==="focus"?0:Hg(y.props.delay,L?0:1,xr.delay)}function B(L){L===void 0&&(L=!1),S.style.pointerEvents=y.props.interactive&&!L?"":"none",S.style.zIndex=""+y.props.zIndex}function V(L,q,Y){if(Y===void 0&&(Y=!0),D.forEach(function(ne){ne[L]&&ne[L].apply(ne,q)}),Y){var ee;(ee=y.props)[L].apply(ee,q)}}function z(){var L=y.props.aria;if(L.content){var q="aria-"+L.content,Y=S.id,ee=Xs(y.props.triggerTarget||e);ee.forEach(function(ne){var Ee=ne.getAttribute(q);if(y.state.isVisible)ne.setAttribute(q,Ee?Ee+" "+Y:Y);else{var Pe=Ee&&Ee.replace(Y,"").trim();Pe?ne.setAttribute(q,Pe):ne.removeAttribute(q)}})}}function W(){if(!(T||!y.props.aria.expanded)){var L=Xs(y.props.triggerTarget||e);L.forEach(function(q){y.props.interactive?q.setAttribute("aria-expanded",y.state.isVisible&&q===j()?"true":"false"):q.removeAttribute("aria-expanded")})}}function Q(){N().removeEventListener("mousemove",m),kf=kf.filter(function(L){return L!==m})}function
|
|
133
|
+
`,"Plugins: https://atomiks.github.io/tippyjs/v6/plugins/"].join(" "))})}var bz=function(){return"innerHTML"};function Gg(e,t){e[bz()]=t}function US(e){var t=kc();return e===!0?t.className=DS:(t.className=AS,Pc(e)?t.appendChild(e):Gg(t,e)),t}function KS(e,t){Pc(t.content)?(Gg(e,""),e.appendChild(t.content)):typeof t.content!="function"&&(t.allowHTML?Gg(e,t.content):e.textContent=t.content)}function Xg(e){var t=e.firstElementChild,n=Cf(t.children);return{box:t,content:n.find(function(r){return r.classList.contains(PS)}),arrow:n.find(function(r){return r.classList.contains(DS)||r.classList.contains(AS)}),backdrop:n.find(function(r){return r.classList.contains(GW)})}}function qS(e){var t=kc(),n=kc();n.className=qW,n.setAttribute("data-state","hidden"),n.setAttribute("tabindex","-1");var r=kc();r.className=PS,r.setAttribute("data-state","hidden"),KS(r,e.props),t.appendChild(n),n.appendChild(r),i(e.props,e.props);function i(o,a){var s=Xg(t),l=s.box,c=s.content,u=s.arrow;a.theme?l.setAttribute("data-theme",a.theme):l.removeAttribute("data-theme"),typeof a.animation=="string"?l.setAttribute("data-animation",a.animation):l.removeAttribute("data-animation"),a.inertia?l.setAttribute("data-inertia",""):l.removeAttribute("data-inertia"),l.style.maxWidth=typeof a.maxWidth=="number"?a.maxWidth+"px":a.maxWidth,a.role?l.setAttribute("role",a.role):l.removeAttribute("role"),(o.content!==a.content||o.allowHTML!==a.allowHTML)&&KS(c,e.props),a.arrow?u?o.arrow!==a.arrow&&(l.removeChild(u),l.appendChild(US(a.arrow))):l.appendChild(US(a.arrow)):u&&l.removeChild(u)}return{popper:t,onUpdate:i}}qS.$$tippy=!0;var xz=1,kf=[],Qg=[];function wz(e,t){var n=HS(e,Object.assign({},xr,VS(IS(t)))),r,i,o,a=!1,s=!1,l=!1,c=!1,u,d,f,p=[],m=jS(oe,n.interactiveDebounce),g,v=xz++,x=null,_=JW(n.plugins),w={isEnabled:!0,isVisible:!1,isDestroyed:!1,isMounted:!1,isShown:!1},y={id:v,reference:e,popper:kc(),popperInstance:x,props:n,state:w,plugins:_,clearDelayTimeouts:sn,setProps:gn,setContent:Wn,show:Xt,hide:zn,hideWithInteractivity:be,enable:ht,disable:mn,unmount:vn,destroy:Qt};if(!n.render)return process.env.NODE_ENV!=="production"&&qg(!0,"render() function has not been supplied."),y;var E=n.render(y),S=E.popper,P=E.onUpdate;S.setAttribute("data-tippy-root",""),S.id="tippy-"+y.id,y.popper=S,e._tippy=y,S._tippy=y;var D=_.map(function(L){return L.fn(y)}),T=e.hasAttribute("aria-expanded");return Z(),W(),B(),V("onCreate",[y]),n.showOnCreate&&Pt(),S.addEventListener("mouseenter",function(){y.props.interactive&&y.state.isVisible&&y.clearDelayTimeouts()}),S.addEventListener("mouseleave",function(){y.props.interactive&&y.props.trigger.indexOf("mouseenter")>=0&&N().addEventListener("mousemove",m)}),y;function I(){var L=y.props.touch;return Array.isArray(L)?L:[L,0]}function A(){return I()[0]==="hold"}function C(){var L;return!!((L=y.props.render)!=null&&L.$$tippy)}function j(){return g||e}function N(){var L=j().parentNode;return L?oz(L):document}function M(){return Xg(S)}function R(L){return y.state.isMounted&&!y.state.isVisible||Ai.isTouch||u&&u.type==="focus"?0:Hg(y.props.delay,L?0:1,xr.delay)}function B(L){L===void 0&&(L=!1),S.style.pointerEvents=y.props.interactive&&!L?"":"none",S.style.zIndex=""+y.props.zIndex}function V(L,q,Y){if(Y===void 0&&(Y=!0),D.forEach(function(ne){ne[L]&&ne[L].apply(ne,q)}),Y){var ee;(ee=y.props)[L].apply(ee,q)}}function z(){var L=y.props.aria;if(L.content){var q="aria-"+L.content,Y=S.id,ee=Xs(y.props.triggerTarget||e);ee.forEach(function(ne){var Ee=ne.getAttribute(q);if(y.state.isVisible)ne.setAttribute(q,Ee?Ee+" "+Y:Y);else{var Pe=Ee&&Ee.replace(Y,"").trim();Pe?ne.setAttribute(q,Pe):ne.removeAttribute(q)}})}}function W(){if(!(T||!y.props.aria.expanded)){var L=Xs(y.props.triggerTarget||e);L.forEach(function(q){y.props.interactive?q.setAttribute("aria-expanded",y.state.isVisible&&q===j()?"true":"false"):q.removeAttribute("aria-expanded")})}}function Q(){N().removeEventListener("mousemove",m),kf=kf.filter(function(L){return L!==m})}function G(L){if(!(Ai.isTouch&&(l||L.type==="mousedown"))){var q=L.composedPath&&L.composedPath()[0]||L.target;if(!(y.props.interactive&&LS(S,q))){if(Xs(y.props.triggerTarget||e).some(function(Y){return LS(Y,q)})){if(Ai.isTouch||y.state.isVisible&&y.props.trigger.indexOf("click")>=0)return}else V("onClickOutside",[y,L]);y.props.hideOnClick===!0&&(y.clearDelayTimeouts(),y.hide(),s=!0,setTimeout(function(){s=!1}),y.state.isMounted||se())}}}function ie(){l=!0}function J(){l=!1}function re(){var L=N();L.addEventListener("mousedown",G,!0),L.addEventListener("touchend",G,Ma),L.addEventListener("touchstart",J,Ma),L.addEventListener("touchmove",ie,Ma)}function se(){var L=N();L.removeEventListener("mousedown",G,!0),L.removeEventListener("touchend",G,Ma),L.removeEventListener("touchstart",J,Ma),L.removeEventListener("touchmove",ie,Ma)}function ce(L,q){K(L,function(){!y.state.isVisible&&S.parentNode&&S.parentNode.contains(S)&&q()})}function de(L,q){K(L,q)}function K(L,q){var Y=M().box;function ee(ne){ne.target===Y&&(Kg(Y,"remove",ee),q())}if(L===0)return q();Kg(Y,"remove",d),Kg(Y,"add",ee),d=ee}function U(L,q,Y){Y===void 0&&(Y=!1);var ee=Xs(y.props.triggerTarget||e);ee.forEach(function(ne){ne.addEventListener(L,q,Y),p.push({node:ne,eventType:L,handler:q,options:Y})})}function Z(){A()&&(U("touchstart",ge,{passive:!0}),U("touchend",ye,{passive:!0})),ZW(y.props.trigger).forEach(function(L){if(L!=="manual")switch(U(L,ge),L){case"mouseenter":U("mouseleave",ye);break;case"focus":U(dz?"focusout":"blur",_e);break;case"focusin":U("focusout",_e);break}})}function F(){p.forEach(function(L){var q=L.node,Y=L.eventType,ee=L.handler,ne=L.options;q.removeEventListener(Y,ee,ne)}),p=[]}function ge(L){var q,Y=!1;if(!(!y.state.isEnabled||Ie(L)||s)){var ee=((q=u)==null?void 0:q.type)==="focus";u=L,g=L.currentTarget,W(),!y.state.isVisible&&nz(L)&&kf.forEach(function(ne){return ne(L)}),L.type==="click"&&(y.props.trigger.indexOf("mouseenter")<0||a)&&y.props.hideOnClick!==!1&&y.state.isVisible?Y=!0:Pt(L),L.type==="click"&&(a=!Y),Y&&!ee&&Dt(L)}}function oe(L){var q=L.target,Y=j().contains(q)||S.contains(q);if(!(L.type==="mousemove"&&Y)){var ee=Fe().concat(S).map(function(ne){var Ee,Pe=ne._tippy,ln=(Ee=Pe.popperInstance)==null?void 0:Ee.state;return ln?{popperRect:ne.getBoundingClientRect(),popperState:ln,props:n}:null}).filter(Boolean);az(ee,L)&&(Q(),Dt(L))}}function ye(L){var q=Ie(L)||y.props.trigger.indexOf("click")>=0&&a;if(!q){if(y.props.interactive){y.hideWithInteractivity(L);return}Dt(L)}}function _e(L){y.props.trigger.indexOf("focusin")<0&&L.target!==j()||y.props.interactive&&L.relatedTarget&&S.contains(L.relatedTarget)||Dt(L)}function Ie(L){return Ai.isTouch?A()!==L.type.indexOf("touch")>=0:!1}function tt(){pt();var L=y.props,q=L.popperOptions,Y=L.placement,ee=L.offset,ne=L.getReferenceClientRect,Ee=L.moveTransition,Pe=C()?Xg(S).arrow:null,ln=ne?{getBoundingClientRect:ne,contextElement:ne.contextElement||j()}:e,ci={name:"$$tippy",enabled:!0,phase:"beforeWrite",requires:["computeStyles"],fn:function(fr){var Cn=fr.state;if(C()){var xe=M(),cn=xe.box;["placement","reference-hidden","escaped"].forEach(function(di){di==="placement"?cn.setAttribute("data-placement",Cn.placement):Cn.attributes.popper["data-popper-"+di]?cn.setAttribute("data-"+di,""):cn.removeAttribute("data-"+di)}),Cn.attributes.popper={}}}},Zt=[{name:"offset",options:{offset:ee}},{name:"preventOverflow",options:{padding:{top:2,bottom:2,left:5,right:5}}},{name:"flip",options:{padding:5}},{name:"computeStyles",options:{adaptive:!Ee}},ci];C()&&Pe&&Zt.push({name:"arrow",options:{element:Pe,padding:3}}),Zt.push.apply(Zt,q?.modifiers||[]),y.popperInstance=Vg(ln,S,Object.assign({},q,{placement:Y,onFirstUpdate:f,modifiers:Zt}))}function pt(){y.popperInstance&&(y.popperInstance.destroy(),y.popperInstance=null)}function ct(){var L=y.props.appendTo,q,Y=j();y.props.interactive&&L===TS||L==="parent"?q=Y.parentNode:q=NS(L,[Y]),q.contains(S)||q.appendChild(S),y.state.isMounted=!0,tt(),process.env.NODE_ENV!=="production"&&lo(y.props.interactive&&L===xr.appendTo&&Y.nextElementSibling!==S,["Interactive tippy element may not be accessible via keyboard","navigation because it is not directly after the reference element","in the DOM source order.",`
|
|
134
134
|
|
|
135
135
|
`,"Using a wrapper <div> or <span> tag around the reference element","solves this by creating a new parentNode context.",`
|
|
136
136
|
|
|
@@ -217,7 +217,7 @@ Take a look at the reducer(s) handling this action type: ${p.type}.
|
|
|
217
217
|
`);if(r>0){var{circleTangency:w,lineTangency:y,theta:E}=vp({cx:t,cy:n,radius:r,angle:l,sign:u,isExternal:!0,cornerRadius:o,cornerIsExternal:s}),{circleTangency:S,lineTangency:P,theta:D}=vp({cx:t,cy:n,radius:r,angle:c,sign:-u,isExternal:!0,cornerRadius:o,cornerIsExternal:s}),T=s?Math.abs(l-c):Math.abs(l-c)-E-D;if(T<0&&o===0)return"".concat(_,"L").concat(t,",").concat(n,"Z");_+="L".concat(P.x,",").concat(P.y,`
|
|
218
218
|
A`).concat(o,",").concat(o,",0,0,").concat(+(u<0),",").concat(S.x,",").concat(S.y,`
|
|
219
219
|
A`).concat(r,",").concat(r,",0,").concat(+(T>180),",").concat(+(u>0),",").concat(w.x,",").concat(w.y,`
|
|
220
|
-
A`).concat(o,",").concat(o,",0,0,").concat(+(u<0),",").concat(y.x,",").concat(y.y,"Z")}else _+="L".concat(t,",").concat(n,"Z");return _},tU={cx:0,cy:0,innerRadius:0,outerRadius:0,startAngle:0,endAngle:0,cornerRadius:0,forceCornerRadius:!1,cornerIsExternal:!1},Dk=e=>{var t=tn(e,tU),{cx:n,cy:r,innerRadius:i,outerRadius:o,cornerRadius:a,forceCornerRadius:s,cornerIsExternal:l,startAngle:c,endAngle:u,className:d}=t;if(o<i||c===u)return null;var f=ue("recharts-sector",d),p=o-i,m=Mn(a,p,0,!0),g;return m>0&&Math.abs(c-u)<360?g=eU({cx:n,cy:r,innerRadius:i,outerRadius:o,cornerRadius:Math.min(m,p/2),forceCornerRadius:s,cornerIsExternal:l,startAngle:c,endAngle:u}):g=Pk({cx:n,cy:r,innerRadius:i,outerRadius:o,startAngle:c,endAngle:u}),O.createElement("path",Gy({},dt(t,!0),{className:f,d:g}))};function nU(e,t,n){var r,i,o,a;if(e==="horizontal")r=t.x,o=r,i=n.top,a=n.top+n.height;else if(e==="vertical")i=t.y,a=i,r=n.left,o=n.left+n.width;else if(t.cx!=null&&t.cy!=null)if(e==="centric"){var{cx:s,cy:l,innerRadius:c,outerRadius:u,angle:d}=t,f=Kt(s,l,c,d),p=Kt(s,l,u,d);r=f.x,i=f.y,o=p.x,a=p.y}else return kk(t);return[{x:r,y:i},{x:o,y:a}]}var Xy={},Qy={},Zy={},Ak;function rU(){return Ak||(Ak=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=$O();function n(r){return t.isSymbol(r)?NaN:Number(r)}e.toNumber=n})(Zy)),Zy}var Tk;function iU(){return Tk||(Tk=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=rU();function n(r){return r?(r=t.toNumber(r),r===1/0||r===-1/0?(r<0?-1:1)*Number.MAX_VALUE:r===r?r:0):r===0?r:0}e.toFinite=n})(Qy)),Qy}var Nk;function oU(){return Nk||(Nk=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=HO(),n=iU();function r(i,o,a){a&&typeof a!="number"&&t.isIterateeCall(i,o,a)&&(o=a=void 0),i=n.toFinite(i),o===void 0?(o=i,i=0):o=n.toFinite(o),a=a===void 0?i<o?1:-1:n.toFinite(a);const s=Math.max(Math.ceil((o-i)/(a||1)),0),l=new Array(s);for(let c=0;c<s;c++)l[c]=i,i+=a;return l}e.range=r})(Xy)),Xy}var Jy,jk;function aU(){return jk||(jk=1,Jy=oU().range),Jy}var sU=aU();const Mk=Ki(sU);function ea(e,t){return e==null||t==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function lU(e,t){return e==null||t==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function eb(e){let t,n,r;e.length!==2?(t=ea,n=(s,l)=>ea(e(s),l),r=(s,l)=>e(s)-l):(t=e===ea||e===lU?e:cU,n=e,r=e);function i(s,l,c=0,u=s.length){if(c<u){if(t(l,l)!==0)return u;do{const d=c+u>>>1;n(s[d],l)<0?c=d+1:u=d}while(c<u)}return c}function o(s,l,c=0,u=s.length){if(c<u){if(t(l,l)!==0)return u;do{const d=c+u>>>1;n(s[d],l)<=0?c=d+1:u=d}while(c<u)}return c}function a(s,l,c=0,u=s.length){const d=i(s,l,c,u-1);return d>c&&r(s[d-1],l)>-r(s[d],l)?d-1:d}return{left:i,center:a,right:o}}function cU(){return 0}function Ik(e){return e===null?NaN:+e}function*uU(e,t){for(let n of e)n!=null&&(n=+n)>=n&&(yield n)}const qc=eb(ea).right;eb(Ik).center;class Fk extends Map{constructor(t,n=pU){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:n}}),t!=null)for(const[r,i]of t)this.set(r,i)}get(t){return super.get(Lk(this,t))}has(t){return super.has(Lk(this,t))}set(t,n){return super.set(dU(this,t),n)}delete(t){return super.delete(fU(this,t))}}function Lk({_intern:e,_key:t},n){const r=t(n);return e.has(r)?e.get(r):n}function dU({_intern:e,_key:t},n){const r=t(n);return e.has(r)?e.get(r):(e.set(r,n),n)}function fU({_intern:e,_key:t},n){const r=t(n);return e.has(r)&&(n=e.get(r),e.delete(r)),n}function pU(e){return e!==null&&typeof e=="object"?e.valueOf():e}function hU(e=ea){if(e===ea)return Rk;if(typeof e!="function")throw new TypeError("compare is not a function");return(t,n)=>{const r=e(t,n);return r||r===0?r:(e(n,n)===0)-(e(t,t)===0)}}function Rk(e,t){return(e==null||!(e>=e))-(t==null||!(t>=t))||(e<t?-1:e>t?1:0)}const mU=Math.sqrt(50),gU=Math.sqrt(10),vU=Math.sqrt(2);function yp(e,t,n){const r=(t-e)/Math.max(0,n),i=Math.floor(Math.log10(r)),o=r/Math.pow(10,i),a=o>=mU?10:o>=gU?5:o>=vU?2:1;let s,l,c;return i<0?(c=Math.pow(10,-i)/a,s=Math.round(e*c),l=Math.round(t*c),s/c<e&&++s,l/c>t&&--l,c=-c):(c=Math.pow(10,i)*a,s=Math.round(e/c),l=Math.round(t/c),s*c<e&&++s,l*c>t&&--l),l<s&&.5<=n&&n<2?yp(e,t,n*2):[s,l,c]}function tb(e,t,n){if(t=+t,e=+e,n=+n,!(n>0))return[];if(e===t)return[e];const r=t<e,[i,o,a]=r?yp(t,e,n):yp(e,t,n);if(!(o>=i))return[];const s=o-i+1,l=new Array(s);if(r)if(a<0)for(let c=0;c<s;++c)l[c]=(o-c)/-a;else for(let c=0;c<s;++c)l[c]=(o-c)*a;else if(a<0)for(let c=0;c<s;++c)l[c]=(i+c)/-a;else for(let c=0;c<s;++c)l[c]=(i+c)*a;return l}function nb(e,t,n){return t=+t,e=+e,n=+n,yp(e,t,n)[2]}function rb(e,t,n){t=+t,e=+e,n=+n;const r=t<e,i=r?nb(t,e,n):nb(e,t,n);return(r?-1:1)*(i<0?1/-i:i)}function $k(e,t){let n;for(const r of e)r!=null&&(n<r||n===void 0&&r>=r)&&(n=r);return n}function Bk(e,t){let n;for(const r of e)r!=null&&(n>r||n===void 0&&r>=r)&&(n=r);return n}function Wk(e,t,n=0,r=1/0,i){if(t=Math.floor(t),n=Math.floor(Math.max(0,n)),r=Math.floor(Math.min(e.length-1,r)),!(n<=t&&t<=r))return e;for(i=i===void 0?Rk:hU(i);r>n;){if(r-n>600){const l=r-n+1,c=t-n+1,u=Math.log(l),d=.5*Math.exp(2*u/3),f=.5*Math.sqrt(u*d*(l-d)/l)*(c-l/2<0?-1:1),p=Math.max(n,Math.floor(t-c*d/l+f)),m=Math.min(r,Math.floor(t+(l-c)*d/l+f));Wk(e,t,p,m,i)}const o=e[t];let a=n,s=r;for(Gc(e,n,t),i(e[r],o)>0&&Gc(e,n,r);a<s;){for(Gc(e,a,s),++a,--s;i(e[a],o)<0;)++a;for(;i(e[s],o)>0;)--s}i(e[n],o)===0?Gc(e,n,s):(++s,Gc(e,s,r)),s<=t&&(n=s+1),t<=s&&(r=s-1)}return e}function Gc(e,t,n){const r=e[t];e[t]=e[n],e[n]=r}function yU(e,t,n){if(e=Float64Array.from(uU(e)),!(!(r=e.length)||isNaN(t=+t))){if(t<=0||r<2)return Bk(e);if(t>=1)return $k(e);var r,i=(r-1)*t,o=Math.floor(i),a=$k(Wk(e,o).subarray(0,o+1)),s=Bk(e.subarray(o+1));return a+(s-a)*(i-o)}}function bU(e,t,n=Ik){if(!(!(r=e.length)||isNaN(t=+t))){if(t<=0||r<2)return+n(e[0],0,e);if(t>=1)return+n(e[r-1],r-1,e);var r,i=(r-1)*t,o=Math.floor(i),a=+n(e[o],o,e),s=+n(e[o+1],o+1,e);return a+(s-a)*(i-o)}}function xU(e,t,n){e=+e,t=+t,n=(i=arguments.length)<2?(t=e,e=0,1):i<3?1:+n;for(var r=-1,i=Math.max(0,Math.ceil((t-e)/n))|0,o=new Array(i);++r<i;)o[r]=e+r*n;return o}function Ur(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e);break}return this}function mo(e,t){switch(arguments.length){case 0:break;case 1:{typeof e=="function"?this.interpolator(e):this.range(e);break}default:{this.domain(e),typeof t=="function"?this.interpolator(t):this.range(t);break}}return this}const ib=Symbol("implicit");function ob(){var e=new Fk,t=[],n=[],r=ib;function i(o){let a=e.get(o);if(a===void 0){if(r!==ib)return r;e.set(o,a=t.push(o)-1)}return n[a%n.length]}return i.domain=function(o){if(!arguments.length)return t.slice();t=[],e=new Fk;for(const a of o)e.has(a)||e.set(a,t.push(a)-1);return i},i.range=function(o){return arguments.length?(n=Array.from(o),i):n.slice()},i.unknown=function(o){return arguments.length?(r=o,i):r},i.copy=function(){return ob(t,n).unknown(r)},Ur.apply(i,arguments),i}function ab(){var e=ob().unknown(void 0),t=e.domain,n=e.range,r=0,i=1,o,a,s=!1,l=0,c=0,u=.5;delete e.unknown;function d(){var f=t().length,p=i<r,m=p?i:r,g=p?r:i;o=(g-m)/Math.max(1,f-l+c*2),s&&(o=Math.floor(o)),m+=(g-m-o*(f-l))*u,a=o*(1-l),s&&(m=Math.round(m),a=Math.round(a));var v=xU(f).map(function(x){return m+o*x});return n(p?v.reverse():v)}return e.domain=function(f){return arguments.length?(t(f),d()):t()},e.range=function(f){return arguments.length?([r,i]=f,r=+r,i=+i,d()):[r,i]},e.rangeRound=function(f){return[r,i]=f,r=+r,i=+i,s=!0,d()},e.bandwidth=function(){return a},e.step=function(){return o},e.round=function(f){return arguments.length?(s=!!f,d()):s},e.padding=function(f){return arguments.length?(l=Math.min(1,c=+f),d()):l},e.paddingInner=function(f){return arguments.length?(l=Math.min(1,f),d()):l},e.paddingOuter=function(f){return arguments.length?(c=+f,d()):c},e.align=function(f){return arguments.length?(u=Math.max(0,Math.min(1,f)),d()):u},e.copy=function(){return ab(t(),[r,i]).round(s).paddingInner(l).paddingOuter(c).align(u)},Ur.apply(d(),arguments)}function zk(e){var t=e.copy;return e.padding=e.paddingOuter,delete e.paddingInner,delete e.paddingOuter,e.copy=function(){return zk(t())},e}function wU(){return zk(ab.apply(null,arguments).paddingInner(1))}function sb(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function Vk(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}function Xc(){}var Qc=.7,bp=1/Qc,ll="\\s*([+-]?\\d+)\\s*",Zc="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",Ni="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",_U=/^#([0-9a-f]{3,8})$/,EU=new RegExp(`^rgb\\(${ll},${ll},${ll}\\)$`),SU=new RegExp(`^rgb\\(${Ni},${Ni},${Ni}\\)$`),OU=new RegExp(`^rgba\\(${ll},${ll},${ll},${Zc}\\)$`),CU=new RegExp(`^rgba\\(${Ni},${Ni},${Ni},${Zc}\\)$`),kU=new RegExp(`^hsl\\(${Zc},${Ni},${Ni}\\)$`),PU=new RegExp(`^hsla\\(${Zc},${Ni},${Ni},${Zc}\\)$`),Hk={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};sb(Xc,Jc,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:Yk,formatHex:Yk,formatHex8:DU,formatHsl:AU,formatRgb:Uk,toString:Uk});function Yk(){return this.rgb().formatHex()}function DU(){return this.rgb().formatHex8()}function AU(){return Qk(this).formatHsl()}function Uk(){return this.rgb().formatRgb()}function Jc(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=_U.exec(e))?(n=t[1].length,t=parseInt(t[1],16),n===6?Kk(t):n===3?new or(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):n===8?xp(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):n===4?xp(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|t&240,((t&15)<<4|t&15)/255):null):(t=EU.exec(e))?new or(t[1],t[2],t[3],1):(t=SU.exec(e))?new or(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=OU.exec(e))?xp(t[1],t[2],t[3],t[4]):(t=CU.exec(e))?xp(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=kU.exec(e))?Xk(t[1],t[2]/100,t[3]/100,1):(t=PU.exec(e))?Xk(t[1],t[2]/100,t[3]/100,t[4]):Hk.hasOwnProperty(e)?Kk(Hk[e]):e==="transparent"?new or(NaN,NaN,NaN,0):null}function Kk(e){return new or(e>>16&255,e>>8&255,e&255,1)}function xp(e,t,n,r){return r<=0&&(e=t=n=NaN),new or(e,t,n,r)}function TU(e){return e instanceof Xc||(e=Jc(e)),e?(e=e.rgb(),new or(e.r,e.g,e.b,e.opacity)):new or}function lb(e,t,n,r){return arguments.length===1?TU(e):new or(e,t,n,r??1)}function or(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}sb(or,lb,Vk(Xc,{brighter(e){return e=e==null?bp:Math.pow(bp,e),new or(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?Qc:Math.pow(Qc,e),new or(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new or(Ua(this.r),Ua(this.g),Ua(this.b),wp(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:qk,formatHex:qk,formatHex8:NU,formatRgb:Gk,toString:Gk}));function qk(){return`#${Ka(this.r)}${Ka(this.g)}${Ka(this.b)}`}function NU(){return`#${Ka(this.r)}${Ka(this.g)}${Ka(this.b)}${Ka((isNaN(this.opacity)?1:this.opacity)*255)}`}function Gk(){const e=wp(this.opacity);return`${e===1?"rgb(":"rgba("}${Ua(this.r)}, ${Ua(this.g)}, ${Ua(this.b)}${e===1?")":`, ${e})`}`}function wp(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function Ua(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function Ka(e){return e=Ua(e),(e<16?"0":"")+e.toString(16)}function Xk(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new oi(e,t,n,r)}function Qk(e){if(e instanceof oi)return new oi(e.h,e.s,e.l,e.opacity);if(e instanceof Xc||(e=Jc(e)),!e)return new oi;if(e instanceof oi)return e;e=e.rgb();var t=e.r/255,n=e.g/255,r=e.b/255,i=Math.min(t,n,r),o=Math.max(t,n,r),a=NaN,s=o-i,l=(o+i)/2;return s?(t===o?a=(n-r)/s+(n<r)*6:n===o?a=(r-t)/s+2:a=(t-n)/s+4,s/=l<.5?o+i:2-o-i,a*=60):s=l>0&&l<1?0:a,new oi(a,s,l,e.opacity)}function jU(e,t,n,r){return arguments.length===1?Qk(e):new oi(e,t,n,r??1)}function oi(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}sb(oi,jU,Vk(Xc,{brighter(e){return e=e==null?bp:Math.pow(bp,e),new oi(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?Qc:Math.pow(Qc,e),new oi(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+(this.h<0)*360,t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*t,i=2*n-r;return new or(cb(e>=240?e-240:e+120,i,r),cb(e,i,r),cb(e<120?e+240:e-120,i,r),this.opacity)},clamp(){return new oi(Zk(this.h),_p(this.s),_p(this.l),wp(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=wp(this.opacity);return`${e===1?"hsl(":"hsla("}${Zk(this.h)}, ${_p(this.s)*100}%, ${_p(this.l)*100}%${e===1?")":`, ${e})`}`}}));function Zk(e){return e=(e||0)%360,e<0?e+360:e}function _p(e){return Math.max(0,Math.min(1,e||0))}function cb(e,t,n){return(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)*255}const ub=e=>()=>e;function MU(e,t){return function(n){return e+n*t}}function IU(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(r){return Math.pow(e+r*t,n)}}function FU(e){return(e=+e)==1?Jk:function(t,n){return n-t?IU(t,n,e):ub(isNaN(t)?n:t)}}function Jk(e,t){var n=t-e;return n?MU(e,n):ub(isNaN(e)?t:e)}const eP=(function e(t){var n=FU(t);function r(i,o){var a=n((i=lb(i)).r,(o=lb(o)).r),s=n(i.g,o.g),l=n(i.b,o.b),c=Jk(i.opacity,o.opacity);return function(u){return i.r=a(u),i.g=s(u),i.b=l(u),i.opacity=c(u),i+""}}return r.gamma=e,r})(1);function LU(e,t){t||(t=[]);var n=e?Math.min(t.length,e.length):0,r=t.slice(),i;return function(o){for(i=0;i<n;++i)r[i]=e[i]*(1-o)+t[i]*o;return r}}function RU(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function $U(e,t){var n=t?t.length:0,r=e?Math.min(n,e.length):0,i=new Array(r),o=new Array(n),a;for(a=0;a<r;++a)i[a]=cl(e[a],t[a]);for(;a<n;++a)o[a]=t[a];return function(s){for(a=0;a<r;++a)o[a]=i[a](s);return o}}function BU(e,t){var n=new Date;return e=+e,t=+t,function(r){return n.setTime(e*(1-r)+t*r),n}}function Ep(e,t){return e=+e,t=+t,function(n){return e*(1-n)+t*n}}function WU(e,t){var n={},r={},i;(e===null||typeof e!="object")&&(e={}),(t===null||typeof t!="object")&&(t={});for(i in t)i in e?n[i]=cl(e[i],t[i]):r[i]=t[i];return function(o){for(i in n)r[i]=n[i](o);return r}}var db=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,fb=new RegExp(db.source,"g");function zU(e){return function(){return e}}function VU(e){return function(t){return e(t)+""}}function HU(e,t){var n=db.lastIndex=fb.lastIndex=0,r,i,o,a=-1,s=[],l=[];for(e=e+"",t=t+"";(r=db.exec(e))&&(i=fb.exec(t));)(o=i.index)>n&&(o=t.slice(n,o),s[a]?s[a]+=o:s[++a]=o),(r=r[0])===(i=i[0])?s[a]?s[a]+=i:s[++a]=i:(s[++a]=null,l.push({i:a,x:Ep(r,i)})),n=fb.lastIndex;return n<t.length&&(o=t.slice(n),s[a]?s[a]+=o:s[++a]=o),s.length<2?l[0]?VU(l[0].x):zU(t):(t=l.length,function(c){for(var u=0,d;u<t;++u)s[(d=l[u]).i]=d.x(c);return s.join("")})}function cl(e,t){var n=typeof t,r;return t==null||n==="boolean"?ub(t):(n==="number"?Ep:n==="string"?(r=Jc(t))?(t=r,eP):HU:t instanceof Jc?eP:t instanceof Date?BU:RU(t)?LU:Array.isArray(t)?$U:typeof t.valueOf!="function"&&typeof t.toString!="function"||isNaN(t)?WU:Ep)(e,t)}function pb(e,t){return e=+e,t=+t,function(n){return Math.round(e*(1-n)+t*n)}}function YU(e,t){t===void 0&&(t=e,e=cl);for(var n=0,r=t.length-1,i=t[0],o=new Array(r<0?0:r);n<r;)o[n]=e(i,i=t[++n]);return function(a){var s=Math.max(0,Math.min(r-1,Math.floor(a*=r)));return o[s](a-s)}}function UU(e){return function(){return e}}function Sp(e){return+e}var tP=[0,1];function Kn(e){return e}function hb(e,t){return(t-=e=+e)?function(n){return(n-e)/t}:UU(isNaN(t)?NaN:.5)}function KU(e,t){var n;return e>t&&(n=e,e=t,t=n),function(r){return Math.max(e,Math.min(t,r))}}function qU(e,t,n){var r=e[0],i=e[1],o=t[0],a=t[1];return i<r?(r=hb(i,r),o=n(a,o)):(r=hb(r,i),o=n(o,a)),function(s){return o(r(s))}}function GU(e,t,n){var r=Math.min(e.length,t.length)-1,i=new Array(r),o=new Array(r),a=-1;for(e[r]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++a<r;)i[a]=hb(e[a],e[a+1]),o[a]=n(t[a],t[a+1]);return function(s){var l=qc(e,s,1,r)-1;return o[l](i[l](s))}}function eu(e,t){return t.domain(e.domain()).range(e.range()).interpolate(e.interpolate()).clamp(e.clamp()).unknown(e.unknown())}function Op(){var e=tP,t=tP,n=cl,r,i,o,a=Kn,s,l,c;function u(){var f=Math.min(e.length,t.length);return a!==Kn&&(a=KU(e[0],e[f-1])),s=f>2?GU:qU,l=c=null,d}function d(f){return f==null||isNaN(f=+f)?o:(l||(l=s(e.map(r),t,n)))(r(a(f)))}return d.invert=function(f){return a(i((c||(c=s(t,e.map(r),Ep)))(f)))},d.domain=function(f){return arguments.length?(e=Array.from(f,Sp),u()):e.slice()},d.range=function(f){return arguments.length?(t=Array.from(f),u()):t.slice()},d.rangeRound=function(f){return t=Array.from(f),n=pb,u()},d.clamp=function(f){return arguments.length?(a=f?!0:Kn,u()):a!==Kn},d.interpolate=function(f){return arguments.length?(n=f,u()):n},d.unknown=function(f){return arguments.length?(o=f,d):o},function(f,p){return r=f,i=p,u()}}function mb(){return Op()(Kn,Kn)}function XU(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function Cp(e,t){if((n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"))<0)return null;var n,r=e.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+e.slice(n+1)]}function ul(e){return e=Cp(Math.abs(e)),e?e[1]:NaN}function QU(e,t){return function(n,r){for(var i=n.length,o=[],a=0,s=e[0],l=0;i>0&&s>0&&(l+s+1>r&&(s=Math.max(1,r-l)),o.push(n.substring(i-=s,i+s)),!((l+=s+1)>r));)s=e[a=(a+1)%e.length];return o.reverse().join(t)}}function ZU(e){return function(t){return t.replace(/[0-9]/g,function(n){return e[+n]})}}var JU=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function tu(e){if(!(t=JU.exec(e)))throw new Error("invalid format: "+e);var t;return new gb({fill:t[1],align:t[2],sign:t[3],symbol:t[4],zero:t[5],width:t[6],comma:t[7],precision:t[8]&&t[8].slice(1),trim:t[9],type:t[10]})}tu.prototype=gb.prototype;function gb(e){this.fill=e.fill===void 0?" ":e.fill+"",this.align=e.align===void 0?">":e.align+"",this.sign=e.sign===void 0?"-":e.sign+"",this.symbol=e.symbol===void 0?"":e.symbol+"",this.zero=!!e.zero,this.width=e.width===void 0?void 0:+e.width,this.comma=!!e.comma,this.precision=e.precision===void 0?void 0:+e.precision,this.trim=!!e.trim,this.type=e.type===void 0?"":e.type+""}gb.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(this.width===void 0?"":Math.max(1,this.width|0))+(this.comma?",":"")+(this.precision===void 0?"":"."+Math.max(0,this.precision|0))+(this.trim?"~":"")+this.type};function eK(e){e:for(var t=e.length,n=1,r=-1,i;n<t;++n)switch(e[n]){case".":r=i=n;break;case"0":r===0&&(r=n),i=n;break;default:if(!+e[n])break e;r>0&&(r=0);break}return r>0?e.slice(0,r)+e.slice(i+1):e}var nP;function tK(e,t){var n=Cp(e,t);if(!n)return e+"";var r=n[0],i=n[1],o=i-(nP=Math.max(-8,Math.min(8,Math.floor(i/3)))*3)+1,a=r.length;return o===a?r:o>a?r+new Array(o-a+1).join("0"):o>0?r.slice(0,o)+"."+r.slice(o):"0."+new Array(1-o).join("0")+Cp(e,Math.max(0,t+o-1))[0]}function rP(e,t){var n=Cp(e,t);if(!n)return e+"";var r=n[0],i=n[1];return i<0?"0."+new Array(-i).join("0")+r:r.length>i+1?r.slice(0,i+1)+"."+r.slice(i+1):r+new Array(i-r.length+2).join("0")}const iP={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:XU,e:(e,t)=>e.toExponential(t),f:(e,t)=>e.toFixed(t),g:(e,t)=>e.toPrecision(t),o:e=>Math.round(e).toString(8),p:(e,t)=>rP(e*100,t),r:rP,s:tK,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function oP(e){return e}var aP=Array.prototype.map,sP=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function nK(e){var t=e.grouping===void 0||e.thousands===void 0?oP:QU(aP.call(e.grouping,Number),e.thousands+""),n=e.currency===void 0?"":e.currency[0]+"",r=e.currency===void 0?"":e.currency[1]+"",i=e.decimal===void 0?".":e.decimal+"",o=e.numerals===void 0?oP:ZU(aP.call(e.numerals,String)),a=e.percent===void 0?"%":e.percent+"",s=e.minus===void 0?"−":e.minus+"",l=e.nan===void 0?"NaN":e.nan+"";function c(d){d=tu(d);var f=d.fill,p=d.align,m=d.sign,g=d.symbol,v=d.zero,x=d.width,_=d.comma,w=d.precision,y=d.trim,E=d.type;E==="n"?(_=!0,E="g"):iP[E]||(w===void 0&&(w=12),y=!0,E="g"),(v||f==="0"&&p==="=")&&(v=!0,f="0",p="=");var S=g==="$"?n:g==="#"&&/[boxX]/.test(E)?"0"+E.toLowerCase():"",P=g==="$"?r:/[%p]/.test(E)?a:"",D=iP[E],T=/[defgprs%]/.test(E);w=w===void 0?6:/[gprs]/.test(E)?Math.max(1,Math.min(21,w)):Math.max(0,Math.min(20,w));function I(A){var C=S,j=P,N,M,R;if(E==="c")j=D(A)+j,A="";else{A=+A;var B=A<0||1/A<0;if(A=isNaN(A)?l:D(Math.abs(A),w),y&&(A=eK(A)),B&&+A==0&&m!=="+"&&(B=!1),C=(B?m==="("?m:s:m==="-"||m==="("?"":m)+C,j=(E==="s"?sP[8+nP/3]:"")+j+(B&&m==="("?")":""),T){for(N=-1,M=A.length;++N<M;)if(R=A.charCodeAt(N),48>R||R>57){j=(R===46?i+A.slice(N+1):A.slice(N))+j,A=A.slice(0,N);break}}}_&&!v&&(A=t(A,1/0));var V=C.length+A.length+j.length,z=V<x?new Array(x-V+1).join(f):"";switch(_&&v&&(A=t(z+A,z.length?x-j.length:1/0),z=""),p){case"<":A=C+A+j+z;break;case"=":A=C+z+A+j;break;case"^":A=z.slice(0,V=z.length>>1)+C+A+j+z.slice(V);break;default:A=z+C+A+j;break}return o(A)}return I.toString=function(){return d+""},I}function u(d,f){var p=c((d=tu(d),d.type="f",d)),m=Math.max(-8,Math.min(8,Math.floor(ul(f)/3)))*3,g=Math.pow(10,-m),v=sP[8+m/3];return function(x){return p(g*x)+v}}return{format:c,formatPrefix:u}}var kp,vb,lP;rK({thousands:",",grouping:[3],currency:["$",""]});function rK(e){return kp=nK(e),vb=kp.format,lP=kp.formatPrefix,kp}function iK(e){return Math.max(0,-ul(Math.abs(e)))}function oK(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(ul(t)/3)))*3-ul(Math.abs(e)))}function aK(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,ul(t)-ul(e))+1}function cP(e,t,n,r){var i=rb(e,t,n),o;switch(r=tu(r??",f"),r.type){case"s":{var a=Math.max(Math.abs(e),Math.abs(t));return r.precision==null&&!isNaN(o=oK(i,a))&&(r.precision=o),lP(r,a)}case"":case"e":case"g":case"p":case"r":{r.precision==null&&!isNaN(o=aK(i,Math.max(Math.abs(e),Math.abs(t))))&&(r.precision=o-(r.type==="e"));break}case"f":case"%":{r.precision==null&&!isNaN(o=iK(i))&&(r.precision=o-(r.type==="%")*2);break}}return vb(r)}function ta(e){var t=e.domain;return e.ticks=function(n){var r=t();return tb(r[0],r[r.length-1],n??10)},e.tickFormat=function(n,r){var i=t();return cP(i[0],i[i.length-1],n??10,r)},e.nice=function(n){n==null&&(n=10);var r=t(),i=0,o=r.length-1,a=r[i],s=r[o],l,c,u=10;for(s<a&&(c=a,a=s,s=c,c=i,i=o,o=c);u-- >0;){if(c=nb(a,s,n),c===l)return r[i]=a,r[o]=s,t(r);if(c>0)a=Math.floor(a/c)*c,s=Math.ceil(s/c)*c;else if(c<0)a=Math.ceil(a*c)/c,s=Math.floor(s*c)/c;else break;l=c}return e},e}function uP(){var e=mb();return e.copy=function(){return eu(e,uP())},Ur.apply(e,arguments),ta(e)}function dP(e){var t;function n(r){return r==null||isNaN(r=+r)?t:r}return n.invert=n,n.domain=n.range=function(r){return arguments.length?(e=Array.from(r,Sp),n):e.slice()},n.unknown=function(r){return arguments.length?(t=r,n):t},n.copy=function(){return dP(e).unknown(t)},e=arguments.length?Array.from(e,Sp):[0,1],ta(n)}function fP(e,t){e=e.slice();var n=0,r=e.length-1,i=e[n],o=e[r],a;return o<i&&(a=n,n=r,r=a,a=i,i=o,o=a),e[n]=t.floor(i),e[r]=t.ceil(o),e}function pP(e){return Math.log(e)}function hP(e){return Math.exp(e)}function sK(e){return-Math.log(-e)}function lK(e){return-Math.exp(-e)}function cK(e){return isFinite(e)?+("1e"+e):e<0?0:e}function uK(e){return e===10?cK:e===Math.E?Math.exp:t=>Math.pow(e,t)}function dK(e){return e===Math.E?Math.log:e===10&&Math.log10||e===2&&Math.log2||(e=Math.log(e),t=>Math.log(t)/e)}function mP(e){return(t,n)=>-e(-t,n)}function yb(e){const t=e(pP,hP),n=t.domain;let r=10,i,o;function a(){return i=dK(r),o=uK(r),n()[0]<0?(i=mP(i),o=mP(o),e(sK,lK)):e(pP,hP),t}return t.base=function(s){return arguments.length?(r=+s,a()):r},t.domain=function(s){return arguments.length?(n(s),a()):n()},t.ticks=s=>{const l=n();let c=l[0],u=l[l.length-1];const d=u<c;d&&([c,u]=[u,c]);let f=i(c),p=i(u),m,g;const v=s==null?10:+s;let x=[];if(!(r%1)&&p-f<v){if(f=Math.floor(f),p=Math.ceil(p),c>0){for(;f<=p;++f)for(m=1;m<r;++m)if(g=f<0?m/o(-f):m*o(f),!(g<c)){if(g>u)break;x.push(g)}}else for(;f<=p;++f)for(m=r-1;m>=1;--m)if(g=f>0?m/o(-f):m*o(f),!(g<c)){if(g>u)break;x.push(g)}x.length*2<v&&(x=tb(c,u,v))}else x=tb(f,p,Math.min(p-f,v)).map(o);return d?x.reverse():x},t.tickFormat=(s,l)=>{if(s==null&&(s=10),l==null&&(l=r===10?"s":","),typeof l!="function"&&(!(r%1)&&(l=tu(l)).precision==null&&(l.trim=!0),l=vb(l)),s===1/0)return l;const c=Math.max(1,r*s/t.ticks().length);return u=>{let d=u/o(Math.round(i(u)));return d*r<r-.5&&(d*=r),d<=c?l(u):""}},t.nice=()=>n(fP(n(),{floor:s=>o(Math.floor(i(s))),ceil:s=>o(Math.ceil(i(s)))})),t}function gP(){const e=yb(Op()).domain([1,10]);return e.copy=()=>eu(e,gP()).base(e.base()),Ur.apply(e,arguments),e}function vP(e){return function(t){return Math.sign(t)*Math.log1p(Math.abs(t/e))}}function yP(e){return function(t){return Math.sign(t)*Math.expm1(Math.abs(t))*e}}function bb(e){var t=1,n=e(vP(t),yP(t));return n.constant=function(r){return arguments.length?e(vP(t=+r),yP(t)):t},ta(n)}function bP(){var e=bb(Op());return e.copy=function(){return eu(e,bP()).constant(e.constant())},Ur.apply(e,arguments)}function xP(e){return function(t){return t<0?-Math.pow(-t,e):Math.pow(t,e)}}function fK(e){return e<0?-Math.sqrt(-e):Math.sqrt(e)}function pK(e){return e<0?-e*e:e*e}function xb(e){var t=e(Kn,Kn),n=1;function r(){return n===1?e(Kn,Kn):n===.5?e(fK,pK):e(xP(n),xP(1/n))}return t.exponent=function(i){return arguments.length?(n=+i,r()):n},ta(t)}function wb(){var e=xb(Op());return e.copy=function(){return eu(e,wb()).exponent(e.exponent())},Ur.apply(e,arguments),e}function hK(){return wb.apply(null,arguments).exponent(.5)}function wP(e){return Math.sign(e)*e*e}function mK(e){return Math.sign(e)*Math.sqrt(Math.abs(e))}function _P(){var e=mb(),t=[0,1],n=!1,r;function i(o){var a=mK(e(o));return isNaN(a)?r:n?Math.round(a):a}return i.invert=function(o){return e.invert(wP(o))},i.domain=function(o){return arguments.length?(e.domain(o),i):e.domain()},i.range=function(o){return arguments.length?(e.range((t=Array.from(o,Sp)).map(wP)),i):t.slice()},i.rangeRound=function(o){return i.range(o).round(!0)},i.round=function(o){return arguments.length?(n=!!o,i):n},i.clamp=function(o){return arguments.length?(e.clamp(o),i):e.clamp()},i.unknown=function(o){return arguments.length?(r=o,i):r},i.copy=function(){return _P(e.domain(),t).round(n).clamp(e.clamp()).unknown(r)},Ur.apply(i,arguments),ta(i)}function EP(){var e=[],t=[],n=[],r;function i(){var a=0,s=Math.max(1,t.length);for(n=new Array(s-1);++a<s;)n[a-1]=bU(e,a/s);return o}function o(a){return a==null||isNaN(a=+a)?r:t[qc(n,a)]}return o.invertExtent=function(a){var s=t.indexOf(a);return s<0?[NaN,NaN]:[s>0?n[s-1]:e[0],s<n.length?n[s]:e[e.length-1]]},o.domain=function(a){if(!arguments.length)return e.slice();e=[];for(let s of a)s!=null&&!isNaN(s=+s)&&e.push(s);return e.sort(ea),i()},o.range=function(a){return arguments.length?(t=Array.from(a),i()):t.slice()},o.unknown=function(a){return arguments.length?(r=a,o):r},o.quantiles=function(){return n.slice()},o.copy=function(){return EP().domain(e).range(t).unknown(r)},Ur.apply(o,arguments)}function SP(){var e=0,t=1,n=1,r=[.5],i=[0,1],o;function a(l){return l!=null&&l<=l?i[qc(r,l,0,n)]:o}function s(){var l=-1;for(r=new Array(n);++l<n;)r[l]=((l+1)*t-(l-n)*e)/(n+1);return a}return a.domain=function(l){return arguments.length?([e,t]=l,e=+e,t=+t,s()):[e,t]},a.range=function(l){return arguments.length?(n=(i=Array.from(l)).length-1,s()):i.slice()},a.invertExtent=function(l){var c=i.indexOf(l);return c<0?[NaN,NaN]:c<1?[e,r[0]]:c>=n?[r[n-1],t]:[r[c-1],r[c]]},a.unknown=function(l){return arguments.length&&(o=l),a},a.thresholds=function(){return r.slice()},a.copy=function(){return SP().domain([e,t]).range(i).unknown(o)},Ur.apply(ta(a),arguments)}function OP(){var e=[.5],t=[0,1],n,r=1;function i(o){return o!=null&&o<=o?t[qc(e,o,0,r)]:n}return i.domain=function(o){return arguments.length?(e=Array.from(o),r=Math.min(e.length,t.length-1),i):e.slice()},i.range=function(o){return arguments.length?(t=Array.from(o),r=Math.min(e.length,t.length-1),i):t.slice()},i.invertExtent=function(o){var a=t.indexOf(o);return[e[a-1],e[a]]},i.unknown=function(o){return arguments.length?(n=o,i):n},i.copy=function(){return OP().domain(e).range(t).unknown(n)},Ur.apply(i,arguments)}const _b=new Date,Eb=new Date;function nn(e,t,n,r){function i(o){return e(o=arguments.length===0?new Date:new Date(+o)),o}return i.floor=o=>(e(o=new Date(+o)),o),i.ceil=o=>(e(o=new Date(o-1)),t(o,1),e(o),o),i.round=o=>{const a=i(o),s=i.ceil(o);return o-a<s-o?a:s},i.offset=(o,a)=>(t(o=new Date(+o),a==null?1:Math.floor(a)),o),i.range=(o,a,s)=>{const l=[];if(o=i.ceil(o),s=s==null?1:Math.floor(s),!(o<a)||!(s>0))return l;let c;do l.push(c=new Date(+o)),t(o,s),e(o);while(c<o&&o<a);return l},i.filter=o=>nn(a=>{if(a>=a)for(;e(a),!o(a);)a.setTime(a-1)},(a,s)=>{if(a>=a)if(s<0)for(;++s<=0;)for(;t(a,-1),!o(a););else for(;--s>=0;)for(;t(a,1),!o(a););}),n&&(i.count=(o,a)=>(_b.setTime(+o),Eb.setTime(+a),e(_b),e(Eb),Math.floor(n(_b,Eb))),i.every=o=>(o=Math.floor(o),!isFinite(o)||!(o>0)?null:o>1?i.filter(r?a=>r(a)%o===0:a=>i.count(0,a)%o===0):i)),i}const Pp=nn(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);Pp.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?nn(t=>{t.setTime(Math.floor(t/e)*e)},(t,n)=>{t.setTime(+t+n*e)},(t,n)=>(n-t)/e):Pp),Pp.range;const go=1e3,Kr=go*60,vo=Kr*60,yo=vo*24,Sb=yo*7,CP=yo*30,Ob=yo*365,qa=nn(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*go)},(e,t)=>(t-e)/go,e=>e.getUTCSeconds());qa.range;const Cb=nn(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*go)},(e,t)=>{e.setTime(+e+t*Kr)},(e,t)=>(t-e)/Kr,e=>e.getMinutes());Cb.range;const kb=nn(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*Kr)},(e,t)=>(t-e)/Kr,e=>e.getUTCMinutes());kb.range;const Pb=nn(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*go-e.getMinutes()*Kr)},(e,t)=>{e.setTime(+e+t*vo)},(e,t)=>(t-e)/vo,e=>e.getHours());Pb.range;const Db=nn(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*vo)},(e,t)=>(t-e)/vo,e=>e.getUTCHours());Db.range;const nu=nn(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*Kr)/yo,e=>e.getDate()-1);nu.range;const Dp=nn(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/yo,e=>e.getUTCDate()-1);Dp.range;const kP=nn(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/yo,e=>Math.floor(e/yo));kP.range;function Ga(e){return nn(t=>{t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)},(t,n)=>{t.setDate(t.getDate()+n*7)},(t,n)=>(n-t-(n.getTimezoneOffset()-t.getTimezoneOffset())*Kr)/Sb)}const Ap=Ga(0),Tp=Ga(1),gK=Ga(2),vK=Ga(3),dl=Ga(4),yK=Ga(5),bK=Ga(6);Ap.range,Tp.range,gK.range,vK.range,dl.range,yK.range,bK.range;function Xa(e){return nn(t=>{t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)},(t,n)=>{t.setUTCDate(t.getUTCDate()+n*7)},(t,n)=>(n-t)/Sb)}const Np=Xa(0),jp=Xa(1),xK=Xa(2),wK=Xa(3),fl=Xa(4),_K=Xa(5),EK=Xa(6);Np.range,jp.range,xK.range,wK.range,fl.range,_K.range,EK.range;const Ab=nn(e=>{e.setDate(1),e.setHours(0,0,0,0)},(e,t)=>{e.setMonth(e.getMonth()+t)},(e,t)=>t.getMonth()-e.getMonth()+(t.getFullYear()-e.getFullYear())*12,e=>e.getMonth());Ab.range;const Tb=nn(e=>{e.setUTCDate(1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCMonth(e.getUTCMonth()+t)},(e,t)=>t.getUTCMonth()-e.getUTCMonth()+(t.getUTCFullYear()-e.getUTCFullYear())*12,e=>e.getUTCMonth());Tb.range;const bo=nn(e=>{e.setMonth(0,1),e.setHours(0,0,0,0)},(e,t)=>{e.setFullYear(e.getFullYear()+t)},(e,t)=>t.getFullYear()-e.getFullYear(),e=>e.getFullYear());bo.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:nn(t=>{t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)},(t,n)=>{t.setFullYear(t.getFullYear()+n*e)}),bo.range;const xo=nn(e=>{e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCFullYear(e.getUTCFullYear()+t)},(e,t)=>t.getUTCFullYear()-e.getUTCFullYear(),e=>e.getUTCFullYear());xo.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:nn(t=>{t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},(t,n)=>{t.setUTCFullYear(t.getUTCFullYear()+n*e)}),xo.range;function PP(e,t,n,r,i,o){const a=[[qa,1,go],[qa,5,5*go],[qa,15,15*go],[qa,30,30*go],[o,1,Kr],[o,5,5*Kr],[o,15,15*Kr],[o,30,30*Kr],[i,1,vo],[i,3,3*vo],[i,6,6*vo],[i,12,12*vo],[r,1,yo],[r,2,2*yo],[n,1,Sb],[t,1,CP],[t,3,3*CP],[e,1,Ob]];function s(c,u,d){const f=u<c;f&&([c,u]=[u,c]);const p=d&&typeof d.range=="function"?d:l(c,u,d),m=p?p.range(c,+u+1):[];return f?m.reverse():m}function l(c,u,d){const f=Math.abs(u-c)/d,p=eb(([,,v])=>v).right(a,f);if(p===a.length)return e.every(rb(c/Ob,u/Ob,d));if(p===0)return Pp.every(Math.max(rb(c,u,d),1));const[m,g]=a[f/a[p-1][2]<a[p][2]/f?p-1:p];return m.every(g)}return[s,l]}const[SK,OK]=PP(xo,Tb,Np,kP,Db,kb),[CK,kK]=PP(bo,Ab,Ap,nu,Pb,Cb);function Nb(e){if(0<=e.y&&e.y<100){var t=new Date(-1,e.m,e.d,e.H,e.M,e.S,e.L);return t.setFullYear(e.y),t}return new Date(e.y,e.m,e.d,e.H,e.M,e.S,e.L)}function jb(e){if(0<=e.y&&e.y<100){var t=new Date(Date.UTC(-1,e.m,e.d,e.H,e.M,e.S,e.L));return t.setUTCFullYear(e.y),t}return new Date(Date.UTC(e.y,e.m,e.d,e.H,e.M,e.S,e.L))}function ru(e,t,n){return{y:e,m:t,d:n,H:0,M:0,S:0,L:0}}function PK(e){var t=e.dateTime,n=e.date,r=e.time,i=e.periods,o=e.days,a=e.shortDays,s=e.months,l=e.shortMonths,c=iu(i),u=ou(i),d=iu(o),f=ou(o),p=iu(a),m=ou(a),g=iu(s),v=ou(s),x=iu(l),_=ou(l),w={a:B,A:V,b:z,B:W,c:null,d:MP,e:MP,f:QK,g:sq,G:cq,H:qK,I:GK,j:XK,L:IP,m:ZK,M:JK,p:Q,q:X,Q:WP,s:zP,S:eq,u:tq,U:nq,V:rq,w:iq,W:oq,x:null,X:null,y:aq,Y:lq,Z:uq,"%":BP},y={a:ie,A:J,b:re,B:se,c:null,d:LP,e:LP,f:hq,g:Sq,G:Cq,H:dq,I:fq,j:pq,L:RP,m:mq,M:gq,p:ce,q:de,Q:WP,s:zP,S:vq,u:yq,U:bq,V:xq,w:wq,W:_q,x:null,X:null,y:Eq,Y:Oq,Z:kq,"%":BP},E={a:I,A,b:C,B:j,c:N,d:NP,e:NP,f:HK,g:TP,G:AP,H:jP,I:jP,j:BK,L:VK,m:$K,M:WK,p:T,q:RK,Q:UK,s:KK,S:zK,u:jK,U:MK,V:IK,w:NK,W:FK,x:M,X:R,y:TP,Y:AP,Z:LK,"%":YK};w.x=S(n,w),w.X=S(r,w),w.c=S(t,w),y.x=S(n,y),y.X=S(r,y),y.c=S(t,y);function S(K,U){return function(Z){var F=[],ge=-1,oe=0,ye=K.length,_e,Ie,tt;for(Z instanceof Date||(Z=new Date(+Z));++ge<ye;)K.charCodeAt(ge)===37&&(F.push(K.slice(oe,ge)),(Ie=DP[_e=K.charAt(++ge)])!=null?_e=K.charAt(++ge):Ie=_e==="e"?" ":"0",(tt=U[_e])&&(_e=tt(Z,Ie)),F.push(_e),oe=ge+1);return F.push(K.slice(oe,ge)),F.join("")}}function P(K,U){return function(Z){var F=ru(1900,void 0,1),ge=D(F,K,Z+="",0),oe,ye;if(ge!=Z.length)return null;if("Q"in F)return new Date(F.Q);if("s"in F)return new Date(F.s*1e3+("L"in F?F.L:0));if(U&&!("Z"in F)&&(F.Z=0),"p"in F&&(F.H=F.H%12+F.p*12),F.m===void 0&&(F.m="q"in F?F.q:0),"V"in F){if(F.V<1||F.V>53)return null;"w"in F||(F.w=1),"Z"in F?(oe=jb(ru(F.y,0,1)),ye=oe.getUTCDay(),oe=ye>4||ye===0?jp.ceil(oe):jp(oe),oe=Dp.offset(oe,(F.V-1)*7),F.y=oe.getUTCFullYear(),F.m=oe.getUTCMonth(),F.d=oe.getUTCDate()+(F.w+6)%7):(oe=Nb(ru(F.y,0,1)),ye=oe.getDay(),oe=ye>4||ye===0?Tp.ceil(oe):Tp(oe),oe=nu.offset(oe,(F.V-1)*7),F.y=oe.getFullYear(),F.m=oe.getMonth(),F.d=oe.getDate()+(F.w+6)%7)}else("W"in F||"U"in F)&&("w"in F||(F.w="u"in F?F.u%7:"W"in F?1:0),ye="Z"in F?jb(ru(F.y,0,1)).getUTCDay():Nb(ru(F.y,0,1)).getDay(),F.m=0,F.d="W"in F?(F.w+6)%7+F.W*7-(ye+5)%7:F.w+F.U*7-(ye+6)%7);return"Z"in F?(F.H+=F.Z/100|0,F.M+=F.Z%100,jb(F)):Nb(F)}}function D(K,U,Z,F){for(var ge=0,oe=U.length,ye=Z.length,_e,Ie;ge<oe;){if(F>=ye)return-1;if(_e=U.charCodeAt(ge++),_e===37){if(_e=U.charAt(ge++),Ie=E[_e in DP?U.charAt(ge++):_e],!Ie||(F=Ie(K,Z,F))<0)return-1}else if(_e!=Z.charCodeAt(F++))return-1}return F}function T(K,U,Z){var F=c.exec(U.slice(Z));return F?(K.p=u.get(F[0].toLowerCase()),Z+F[0].length):-1}function I(K,U,Z){var F=p.exec(U.slice(Z));return F?(K.w=m.get(F[0].toLowerCase()),Z+F[0].length):-1}function A(K,U,Z){var F=d.exec(U.slice(Z));return F?(K.w=f.get(F[0].toLowerCase()),Z+F[0].length):-1}function C(K,U,Z){var F=x.exec(U.slice(Z));return F?(K.m=_.get(F[0].toLowerCase()),Z+F[0].length):-1}function j(K,U,Z){var F=g.exec(U.slice(Z));return F?(K.m=v.get(F[0].toLowerCase()),Z+F[0].length):-1}function N(K,U,Z){return D(K,t,U,Z)}function M(K,U,Z){return D(K,n,U,Z)}function R(K,U,Z){return D(K,r,U,Z)}function B(K){return a[K.getDay()]}function V(K){return o[K.getDay()]}function z(K){return l[K.getMonth()]}function W(K){return s[K.getMonth()]}function Q(K){return i[+(K.getHours()>=12)]}function X(K){return 1+~~(K.getMonth()/3)}function ie(K){return a[K.getUTCDay()]}function J(K){return o[K.getUTCDay()]}function re(K){return l[K.getUTCMonth()]}function se(K){return s[K.getUTCMonth()]}function ce(K){return i[+(K.getUTCHours()>=12)]}function de(K){return 1+~~(K.getUTCMonth()/3)}return{format:function(K){var U=S(K+="",w);return U.toString=function(){return K},U},parse:function(K){var U=P(K+="",!1);return U.toString=function(){return K},U},utcFormat:function(K){var U=S(K+="",y);return U.toString=function(){return K},U},utcParse:function(K){var U=P(K+="",!0);return U.toString=function(){return K},U}}}var DP={"-":"",_:" ",0:"0"},dn=/^\s*\d+/,DK=/^%/,AK=/[\\^$*+?|[\]().{}]/g;function Re(e,t,n){var r=e<0?"-":"",i=(r?-e:e)+"",o=i.length;return r+(o<n?new Array(n-o+1).join(t)+i:i)}function TK(e){return e.replace(AK,"\\$&")}function iu(e){return new RegExp("^(?:"+e.map(TK).join("|")+")","i")}function ou(e){return new Map(e.map((t,n)=>[t.toLowerCase(),n]))}function NK(e,t,n){var r=dn.exec(t.slice(n,n+1));return r?(e.w=+r[0],n+r[0].length):-1}function jK(e,t,n){var r=dn.exec(t.slice(n,n+1));return r?(e.u=+r[0],n+r[0].length):-1}function MK(e,t,n){var r=dn.exec(t.slice(n,n+2));return r?(e.U=+r[0],n+r[0].length):-1}function IK(e,t,n){var r=dn.exec(t.slice(n,n+2));return r?(e.V=+r[0],n+r[0].length):-1}function FK(e,t,n){var r=dn.exec(t.slice(n,n+2));return r?(e.W=+r[0],n+r[0].length):-1}function AP(e,t,n){var r=dn.exec(t.slice(n,n+4));return r?(e.y=+r[0],n+r[0].length):-1}function TP(e,t,n){var r=dn.exec(t.slice(n,n+2));return r?(e.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function LK(e,t,n){var r=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(t.slice(n,n+6));return r?(e.Z=r[1]?0:-(r[2]+(r[3]||"00")),n+r[0].length):-1}function RK(e,t,n){var r=dn.exec(t.slice(n,n+1));return r?(e.q=r[0]*3-3,n+r[0].length):-1}function $K(e,t,n){var r=dn.exec(t.slice(n,n+2));return r?(e.m=r[0]-1,n+r[0].length):-1}function NP(e,t,n){var r=dn.exec(t.slice(n,n+2));return r?(e.d=+r[0],n+r[0].length):-1}function BK(e,t,n){var r=dn.exec(t.slice(n,n+3));return r?(e.m=0,e.d=+r[0],n+r[0].length):-1}function jP(e,t,n){var r=dn.exec(t.slice(n,n+2));return r?(e.H=+r[0],n+r[0].length):-1}function WK(e,t,n){var r=dn.exec(t.slice(n,n+2));return r?(e.M=+r[0],n+r[0].length):-1}function zK(e,t,n){var r=dn.exec(t.slice(n,n+2));return r?(e.S=+r[0],n+r[0].length):-1}function VK(e,t,n){var r=dn.exec(t.slice(n,n+3));return r?(e.L=+r[0],n+r[0].length):-1}function HK(e,t,n){var r=dn.exec(t.slice(n,n+6));return r?(e.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function YK(e,t,n){var r=DK.exec(t.slice(n,n+1));return r?n+r[0].length:-1}function UK(e,t,n){var r=dn.exec(t.slice(n));return r?(e.Q=+r[0],n+r[0].length):-1}function KK(e,t,n){var r=dn.exec(t.slice(n));return r?(e.s=+r[0],n+r[0].length):-1}function MP(e,t){return Re(e.getDate(),t,2)}function qK(e,t){return Re(e.getHours(),t,2)}function GK(e,t){return Re(e.getHours()%12||12,t,2)}function XK(e,t){return Re(1+nu.count(bo(e),e),t,3)}function IP(e,t){return Re(e.getMilliseconds(),t,3)}function QK(e,t){return IP(e,t)+"000"}function ZK(e,t){return Re(e.getMonth()+1,t,2)}function JK(e,t){return Re(e.getMinutes(),t,2)}function eq(e,t){return Re(e.getSeconds(),t,2)}function tq(e){var t=e.getDay();return t===0?7:t}function nq(e,t){return Re(Ap.count(bo(e)-1,e),t,2)}function FP(e){var t=e.getDay();return t>=4||t===0?dl(e):dl.ceil(e)}function rq(e,t){return e=FP(e),Re(dl.count(bo(e),e)+(bo(e).getDay()===4),t,2)}function iq(e){return e.getDay()}function oq(e,t){return Re(Tp.count(bo(e)-1,e),t,2)}function aq(e,t){return Re(e.getFullYear()%100,t,2)}function sq(e,t){return e=FP(e),Re(e.getFullYear()%100,t,2)}function lq(e,t){return Re(e.getFullYear()%1e4,t,4)}function cq(e,t){var n=e.getDay();return e=n>=4||n===0?dl(e):dl.ceil(e),Re(e.getFullYear()%1e4,t,4)}function uq(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+Re(t/60|0,"0",2)+Re(t%60,"0",2)}function LP(e,t){return Re(e.getUTCDate(),t,2)}function dq(e,t){return Re(e.getUTCHours(),t,2)}function fq(e,t){return Re(e.getUTCHours()%12||12,t,2)}function pq(e,t){return Re(1+Dp.count(xo(e),e),t,3)}function RP(e,t){return Re(e.getUTCMilliseconds(),t,3)}function hq(e,t){return RP(e,t)+"000"}function mq(e,t){return Re(e.getUTCMonth()+1,t,2)}function gq(e,t){return Re(e.getUTCMinutes(),t,2)}function vq(e,t){return Re(e.getUTCSeconds(),t,2)}function yq(e){var t=e.getUTCDay();return t===0?7:t}function bq(e,t){return Re(Np.count(xo(e)-1,e),t,2)}function $P(e){var t=e.getUTCDay();return t>=4||t===0?fl(e):fl.ceil(e)}function xq(e,t){return e=$P(e),Re(fl.count(xo(e),e)+(xo(e).getUTCDay()===4),t,2)}function wq(e){return e.getUTCDay()}function _q(e,t){return Re(jp.count(xo(e)-1,e),t,2)}function Eq(e,t){return Re(e.getUTCFullYear()%100,t,2)}function Sq(e,t){return e=$P(e),Re(e.getUTCFullYear()%100,t,2)}function Oq(e,t){return Re(e.getUTCFullYear()%1e4,t,4)}function Cq(e,t){var n=e.getUTCDay();return e=n>=4||n===0?fl(e):fl.ceil(e),Re(e.getUTCFullYear()%1e4,t,4)}function kq(){return"+0000"}function BP(){return"%"}function WP(e){return+e}function zP(e){return Math.floor(+e/1e3)}var pl,VP,HP;Pq({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});function Pq(e){return pl=PK(e),VP=pl.format,pl.parse,HP=pl.utcFormat,pl.utcParse,pl}function Dq(e){return new Date(e)}function Aq(e){return e instanceof Date?+e:+new Date(+e)}function Mb(e,t,n,r,i,o,a,s,l,c){var u=mb(),d=u.invert,f=u.domain,p=c(".%L"),m=c(":%S"),g=c("%I:%M"),v=c("%I %p"),x=c("%a %d"),_=c("%b %d"),w=c("%B"),y=c("%Y");function E(S){return(l(S)<S?p:s(S)<S?m:a(S)<S?g:o(S)<S?v:r(S)<S?i(S)<S?x:_:n(S)<S?w:y)(S)}return u.invert=function(S){return new Date(d(S))},u.domain=function(S){return arguments.length?f(Array.from(S,Aq)):f().map(Dq)},u.ticks=function(S){var P=f();return e(P[0],P[P.length-1],S??10)},u.tickFormat=function(S,P){return P==null?E:c(P)},u.nice=function(S){var P=f();return(!S||typeof S.range!="function")&&(S=t(P[0],P[P.length-1],S??10)),S?f(fP(P,S)):u},u.copy=function(){return eu(u,Mb(e,t,n,r,i,o,a,s,l,c))},u}function Tq(){return Ur.apply(Mb(CK,kK,bo,Ab,Ap,nu,Pb,Cb,qa,VP).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}function Nq(){return Ur.apply(Mb(SK,OK,xo,Tb,Np,Dp,Db,kb,qa,HP).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)]),arguments)}function Mp(){var e=0,t=1,n,r,i,o,a=Kn,s=!1,l;function c(d){return d==null||isNaN(d=+d)?l:a(i===0?.5:(d=(o(d)-n)*i,s?Math.max(0,Math.min(1,d)):d))}c.domain=function(d){return arguments.length?([e,t]=d,n=o(e=+e),r=o(t=+t),i=n===r?0:1/(r-n),c):[e,t]},c.clamp=function(d){return arguments.length?(s=!!d,c):s},c.interpolator=function(d){return arguments.length?(a=d,c):a};function u(d){return function(f){var p,m;return arguments.length?([p,m]=f,a=d(p,m),c):[a(0),a(1)]}}return c.range=u(cl),c.rangeRound=u(pb),c.unknown=function(d){return arguments.length?(l=d,c):l},function(d){return o=d,n=d(e),r=d(t),i=n===r?0:1/(r-n),c}}function na(e,t){return t.domain(e.domain()).interpolator(e.interpolator()).clamp(e.clamp()).unknown(e.unknown())}function YP(){var e=ta(Mp()(Kn));return e.copy=function(){return na(e,YP())},mo.apply(e,arguments)}function UP(){var e=yb(Mp()).domain([1,10]);return e.copy=function(){return na(e,UP()).base(e.base())},mo.apply(e,arguments)}function KP(){var e=bb(Mp());return e.copy=function(){return na(e,KP()).constant(e.constant())},mo.apply(e,arguments)}function Ib(){var e=xb(Mp());return e.copy=function(){return na(e,Ib()).exponent(e.exponent())},mo.apply(e,arguments)}function jq(){return Ib.apply(null,arguments).exponent(.5)}function qP(){var e=[],t=Kn;function n(r){if(r!=null&&!isNaN(r=+r))return t((qc(e,r,1)-1)/(e.length-1))}return n.domain=function(r){if(!arguments.length)return e.slice();e=[];for(let i of r)i!=null&&!isNaN(i=+i)&&e.push(i);return e.sort(ea),n},n.interpolator=function(r){return arguments.length?(t=r,n):t},n.range=function(){return e.map((r,i)=>t(i/(e.length-1)))},n.quantiles=function(r){return Array.from({length:r+1},(i,o)=>yU(e,o/r))},n.copy=function(){return qP(t).domain(e)},mo.apply(n,arguments)}function Ip(){var e=0,t=.5,n=1,r=1,i,o,a,s,l,c=Kn,u,d=!1,f;function p(g){return isNaN(g=+g)?f:(g=.5+((g=+u(g))-o)*(r*g<r*o?s:l),c(d?Math.max(0,Math.min(1,g)):g))}p.domain=function(g){return arguments.length?([e,t,n]=g,i=u(e=+e),o=u(t=+t),a=u(n=+n),s=i===o?0:.5/(o-i),l=o===a?0:.5/(a-o),r=o<i?-1:1,p):[e,t,n]},p.clamp=function(g){return arguments.length?(d=!!g,p):d},p.interpolator=function(g){return arguments.length?(c=g,p):c};function m(g){return function(v){var x,_,w;return arguments.length?([x,_,w]=v,c=YU(g,[x,_,w]),p):[c(0),c(.5),c(1)]}}return p.range=m(cl),p.rangeRound=m(pb),p.unknown=function(g){return arguments.length?(f=g,p):f},function(g){return u=g,i=g(e),o=g(t),a=g(n),s=i===o?0:.5/(o-i),l=o===a?0:.5/(a-o),r=o<i?-1:1,p}}function GP(){var e=ta(Ip()(Kn));return e.copy=function(){return na(e,GP())},mo.apply(e,arguments)}function XP(){var e=yb(Ip()).domain([.1,1,10]);return e.copy=function(){return na(e,XP()).base(e.base())},mo.apply(e,arguments)}function QP(){var e=bb(Ip());return e.copy=function(){return na(e,QP()).constant(e.constant())},mo.apply(e,arguments)}function Fb(){var e=xb(Ip());return e.copy=function(){return na(e,Fb()).exponent(e.exponent())},mo.apply(e,arguments)}function Mq(){return Fb.apply(null,arguments).exponent(.5)}const au=Object.freeze(Object.defineProperty({__proto__:null,scaleBand:ab,scaleDiverging:GP,scaleDivergingLog:XP,scaleDivergingPow:Fb,scaleDivergingSqrt:Mq,scaleDivergingSymlog:QP,scaleIdentity:dP,scaleImplicit:ib,scaleLinear:uP,scaleLog:gP,scaleOrdinal:ob,scalePoint:wU,scalePow:wb,scaleQuantile:EP,scaleQuantize:SP,scaleRadial:_P,scaleSequential:YP,scaleSequentialLog:UP,scaleSequentialPow:Ib,scaleSequentialQuantile:qP,scaleSequentialSqrt:jq,scaleSequentialSymlog:KP,scaleSqrt:hK,scaleSymlog:bP,scaleThreshold:OP,scaleTime:Tq,scaleUtc:Nq,tickFormat:cP},Symbol.toStringTag,{value:"Module"}));var ra=e=>e.chartData,Lb=H([ra],e=>{var t=e.chartData!=null?e.chartData.length-1:0;return{chartData:e.chartData,computedData:e.computedData,dataEndIndex:t,dataStartIndex:0}}),su=(e,t,n,r)=>r?Lb(e):ra(e);function hl(e){if(Array.isArray(e)&&e.length===2){var[t,n]=e;if(Sn(t)&&Sn(n))return!0}return!1}function ZP(e,t,n){return n?e:[Math.min(e[0],t[0]),Math.max(e[1],t[1])]}function Iq(e,t){if(t&&typeof e!="function"&&Array.isArray(e)&&e.length===2){var[n,r]=e,i,o;if(Sn(n))i=n;else if(typeof n=="function")return;if(Sn(r))o=r;else if(typeof r=="function")return;var a=[i,o];if(hl(a))return a}}function Fq(e,t,n){if(!(!n&&t==null)){if(typeof e=="function"&&t!=null)try{var r=e(t,n);if(hl(r))return ZP(r,t,n)}catch{}if(Array.isArray(e)&&e.length===2){var[i,o]=e,a,s;if(i==="auto")t!=null&&(a=Math.min(...t));else if(me(i))a=i;else if(typeof i=="function")try{t!=null&&(a=i(t?.[0]))}catch{}else if(typeof i=="string"&&YC.test(i)){var l=YC.exec(i);if(l==null||t==null)a=void 0;else{var c=+l[1];a=t[0]-c}}else a=t?.[0];if(o==="auto")t!=null&&(s=Math.max(...t));else if(me(o))s=o;else if(typeof o=="function")try{t!=null&&(s=o(t?.[1]))}catch{}else if(typeof o=="string"&&UC.test(o)){var u=UC.exec(o);if(u==null||t==null)s=void 0;else{var d=+u[1];s=t[1]+d}}else s=t?.[1];var f=[a,s];if(hl(f))return t==null?f:ZP(f,t,n)}}}var ml=1e9,Lq={precision:20,rounding:4,toExpNeg:-7,toExpPos:21,LN10:"2.302585092994045684017991454684364207601101488628772976033327900967572609677352480235997205089598298341967784042286"},Bb,_t=!0,qr="[DecimalError] ",Qa=qr+"Invalid argument: ",Rb=qr+"Exponent out of range: ",gl=Math.floor,Za=Math.pow,Rq=/^(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,Er,fn=1e7,yt=7,JP=9007199254740991,Fp=gl(JP/yt),he={};he.absoluteValue=he.abs=function(){var e=new this.constructor(this);return e.s&&(e.s=1),e},he.comparedTo=he.cmp=function(e){var t,n,r,i,o=this;if(e=new o.constructor(e),o.s!==e.s)return o.s||-e.s;if(o.e!==e.e)return o.e>e.e^o.s<0?1:-1;for(r=o.d.length,i=e.d.length,t=0,n=r<i?r:i;t<n;++t)if(o.d[t]!==e.d[t])return o.d[t]>e.d[t]^o.s<0?1:-1;return r===i?0:r>i^o.s<0?1:-1},he.decimalPlaces=he.dp=function(){var e=this,t=e.d.length-1,n=(t-e.e)*yt;if(t=e.d[t],t)for(;t%10==0;t/=10)n--;return n<0?0:n},he.dividedBy=he.div=function(e){return wo(this,new this.constructor(e))},he.dividedToIntegerBy=he.idiv=function(e){var t=this,n=t.constructor;return at(wo(t,new n(e),0,1),n.precision)},he.equals=he.eq=function(e){return!this.cmp(e)},he.exponent=function(){return qt(this)},he.greaterThan=he.gt=function(e){return this.cmp(e)>0},he.greaterThanOrEqualTo=he.gte=function(e){return this.cmp(e)>=0},he.isInteger=he.isint=function(){return this.e>this.d.length-2},he.isNegative=he.isneg=function(){return this.s<0},he.isPositive=he.ispos=function(){return this.s>0},he.isZero=function(){return this.s===0},he.lessThan=he.lt=function(e){return this.cmp(e)<0},he.lessThanOrEqualTo=he.lte=function(e){return this.cmp(e)<1},he.logarithm=he.log=function(e){var t,n=this,r=n.constructor,i=r.precision,o=i+5;if(e===void 0)e=new r(10);else if(e=new r(e),e.s<1||e.eq(Er))throw Error(qr+"NaN");if(n.s<1)throw Error(qr+(n.s?"NaN":"-Infinity"));return n.eq(Er)?new r(0):(_t=!1,t=wo(lu(n,o),lu(e,o),o),_t=!0,at(t,i))},he.minus=he.sub=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?rD(t,e):eD(t,(e.s=-e.s,e))},he.modulo=he.mod=function(e){var t,n=this,r=n.constructor,i=r.precision;if(e=new r(e),!e.s)throw Error(qr+"NaN");return n.s?(_t=!1,t=wo(n,e,0,1).times(e),_t=!0,n.minus(t)):at(new r(n),i)},he.naturalExponential=he.exp=function(){return tD(this)},he.naturalLogarithm=he.ln=function(){return lu(this)},he.negated=he.neg=function(){var e=new this.constructor(this);return e.s=-e.s||0,e},he.plus=he.add=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?eD(t,e):rD(t,(e.s=-e.s,e))},he.precision=he.sd=function(e){var t,n,r,i=this;if(e!==void 0&&e!==!!e&&e!==1&&e!==0)throw Error(Qa+e);if(t=qt(i)+1,r=i.d.length-1,n=r*yt+1,r=i.d[r],r){for(;r%10==0;r/=10)n--;for(r=i.d[0];r>=10;r/=10)n++}return e&&t>n?t:n},he.squareRoot=he.sqrt=function(){var e,t,n,r,i,o,a,s=this,l=s.constructor;if(s.s<1){if(!s.s)return new l(0);throw Error(qr+"NaN")}for(e=qt(s),_t=!1,i=Math.sqrt(+s),i==0||i==1/0?(t=Mi(s.d),(t.length+e)%2==0&&(t+="0"),i=Math.sqrt(t),e=gl((e+1)/2)-(e<0||e%2),i==1/0?t="5e"+e:(t=i.toExponential(),t=t.slice(0,t.indexOf("e")+1)+e),r=new l(t)):r=new l(i.toString()),n=l.precision,i=a=n+3;;)if(o=r,r=o.plus(wo(s,o,a+2)).times(.5),Mi(o.d).slice(0,a)===(t=Mi(r.d)).slice(0,a)){if(t=t.slice(a-3,a+1),i==a&&t=="4999"){if(at(o,n+1,0),o.times(o).eq(s)){r=o;break}}else if(t!="9999")break;a+=4}return _t=!0,at(r,n)},he.times=he.mul=function(e){var t,n,r,i,o,a,s,l,c,u=this,d=u.constructor,f=u.d,p=(e=new d(e)).d;if(!u.s||!e.s)return new d(0);for(e.s*=u.s,n=u.e+e.e,l=f.length,c=p.length,l<c&&(o=f,f=p,p=o,a=l,l=c,c=a),o=[],a=l+c,r=a;r--;)o.push(0);for(r=c;--r>=0;){for(t=0,i=l+r;i>r;)s=o[i]+p[r]*f[i-r-1]+t,o[i--]=s%fn|0,t=s/fn|0;o[i]=(o[i]+t)%fn|0}for(;!o[--a];)o.pop();return t?++n:o.shift(),e.d=o,e.e=n,_t?at(e,d.precision):e},he.toDecimalPlaces=he.todp=function(e,t){var n=this,r=n.constructor;return n=new r(n),e===void 0?n:(ji(e,0,ml),t===void 0?t=r.rounding:ji(t,0,8),at(n,e+qt(n)+1,t))},he.toExponential=function(e,t){var n,r=this,i=r.constructor;return e===void 0?n=Ja(r,!0):(ji(e,0,ml),t===void 0?t=i.rounding:ji(t,0,8),r=at(new i(r),e+1,t),n=Ja(r,!0,e+1)),n},he.toFixed=function(e,t){var n,r,i=this,o=i.constructor;return e===void 0?Ja(i):(ji(e,0,ml),t===void 0?t=o.rounding:ji(t,0,8),r=at(new o(i),e+qt(i)+1,t),n=Ja(r.abs(),!1,e+qt(r)+1),i.isneg()&&!i.isZero()?"-"+n:n)},he.toInteger=he.toint=function(){var e=this,t=e.constructor;return at(new t(e),qt(e)+1,t.rounding)},he.toNumber=function(){return+this},he.toPower=he.pow=function(e){var t,n,r,i,o,a,s=this,l=s.constructor,c=12,u=+(e=new l(e));if(!e.s)return new l(Er);if(s=new l(s),!s.s){if(e.s<1)throw Error(qr+"Infinity");return s}if(s.eq(Er))return s;if(r=l.precision,e.eq(Er))return at(s,r);if(t=e.e,n=e.d.length-1,a=t>=n,o=s.s,a){if((n=u<0?-u:u)<=JP){for(i=new l(Er),t=Math.ceil(r/yt+4),_t=!1;n%2&&(i=i.times(s),iD(i.d,t)),n=gl(n/2),n!==0;)s=s.times(s),iD(s.d,t);return _t=!0,e.s<0?new l(Er).div(i):at(i,r)}}else if(o<0)throw Error(qr+"NaN");return o=o<0&&e.d[Math.max(t,n)]&1?-1:1,s.s=1,_t=!1,i=e.times(lu(s,r+c)),_t=!0,i=tD(i),i.s=o,i},he.toPrecision=function(e,t){var n,r,i=this,o=i.constructor;return e===void 0?(n=qt(i),r=Ja(i,n<=o.toExpNeg||n>=o.toExpPos)):(ji(e,1,ml),t===void 0?t=o.rounding:ji(t,0,8),i=at(new o(i),e,t),n=qt(i),r=Ja(i,e<=n||n<=o.toExpNeg,e)),r},he.toSignificantDigits=he.tosd=function(e,t){var n=this,r=n.constructor;return e===void 0?(e=r.precision,t=r.rounding):(ji(e,1,ml),t===void 0?t=r.rounding:ji(t,0,8)),at(new r(n),e,t)},he.toString=he.valueOf=he.val=he.toJSON=he[Symbol.for("nodejs.util.inspect.custom")]=function(){var e=this,t=qt(e),n=e.constructor;return Ja(e,t<=n.toExpNeg||t>=n.toExpPos)};function eD(e,t){var n,r,i,o,a,s,l,c,u=e.constructor,d=u.precision;if(!e.s||!t.s)return t.s||(t=new u(e)),_t?at(t,d):t;if(l=e.d,c=t.d,a=e.e,i=t.e,l=l.slice(),o=a-i,o){for(o<0?(r=l,o=-o,s=c.length):(r=c,i=a,s=l.length),a=Math.ceil(d/yt),s=a>s?a+1:s+1,o>s&&(o=s,r.length=1),r.reverse();o--;)r.push(0);r.reverse()}for(s=l.length,o=c.length,s-o<0&&(o=s,r=c,c=l,l=r),n=0;o;)n=(l[--o]=l[o]+c[o]+n)/fn|0,l[o]%=fn;for(n&&(l.unshift(n),++i),s=l.length;l[--s]==0;)l.pop();return t.d=l,t.e=i,_t?at(t,d):t}function ji(e,t,n){if(e!==~~e||e<t||e>n)throw Error(Qa+e)}function Mi(e){var t,n,r,i=e.length-1,o="",a=e[0];if(i>0){for(o+=a,t=1;t<i;t++)r=e[t]+"",n=yt-r.length,n&&(o+=ia(n)),o+=r;a=e[t],r=a+"",n=yt-r.length,n&&(o+=ia(n))}else if(a===0)return"0";for(;a%10===0;)a/=10;return o+a}var wo=(function(){function e(r,i){var o,a=0,s=r.length;for(r=r.slice();s--;)o=r[s]*i+a,r[s]=o%fn|0,a=o/fn|0;return a&&r.unshift(a),r}function t(r,i,o,a){var s,l;if(o!=a)l=o>a?1:-1;else for(s=l=0;s<o;s++)if(r[s]!=i[s]){l=r[s]>i[s]?1:-1;break}return l}function n(r,i,o){for(var a=0;o--;)r[o]-=a,a=r[o]<i[o]?1:0,r[o]=a*fn+r[o]-i[o];for(;!r[0]&&r.length>1;)r.shift()}return function(r,i,o,a){var s,l,c,u,d,f,p,m,g,v,x,_,w,y,E,S,P,D,T=r.constructor,I=r.s==i.s?1:-1,A=r.d,C=i.d;if(!r.s)return new T(r);if(!i.s)throw Error(qr+"Division by zero");for(l=r.e-i.e,P=C.length,E=A.length,p=new T(I),m=p.d=[],c=0;C[c]==(A[c]||0);)++c;if(C[c]>(A[c]||0)&&--l,o==null?_=o=T.precision:a?_=o+(qt(r)-qt(i))+1:_=o,_<0)return new T(0);if(_=_/yt+2|0,c=0,P==1)for(u=0,C=C[0],_++;(c<E||u)&&_--;c++)w=u*fn+(A[c]||0),m[c]=w/C|0,u=w%C|0;else{for(u=fn/(C[0]+1)|0,u>1&&(C=e(C,u),A=e(A,u),P=C.length,E=A.length),y=P,g=A.slice(0,P),v=g.length;v<P;)g[v++]=0;D=C.slice(),D.unshift(0),S=C[0],C[1]>=fn/2&&++S;do u=0,s=t(C,g,P,v),s<0?(x=g[0],P!=v&&(x=x*fn+(g[1]||0)),u=x/S|0,u>1?(u>=fn&&(u=fn-1),d=e(C,u),f=d.length,v=g.length,s=t(d,g,f,v),s==1&&(u--,n(d,P<f?D:C,f))):(u==0&&(s=u=1),d=C.slice()),f=d.length,f<v&&d.unshift(0),n(g,d,v),s==-1&&(v=g.length,s=t(C,g,P,v),s<1&&(u++,n(g,P<v?D:C,v))),v=g.length):s===0&&(u++,g=[0]),m[c++]=u,s&&g[0]?g[v++]=A[y]||0:(g=[A[y]],v=1);while((y++<E||g[0]!==void 0)&&_--)}return m[0]||m.shift(),p.e=l,at(p,a?o+qt(p)+1:o)}})();function tD(e,t){var n,r,i,o,a,s,l=0,c=0,u=e.constructor,d=u.precision;if(qt(e)>16)throw Error(Rb+qt(e));if(!e.s)return new u(Er);for(_t=!1,s=d,a=new u(.03125);e.abs().gte(.1);)e=e.times(a),c+=5;for(r=Math.log(Za(2,c))/Math.LN10*2+5|0,s+=r,n=i=o=new u(Er),u.precision=s;;){if(i=at(i.times(e),s),n=n.times(++l),a=o.plus(wo(i,n,s)),Mi(a.d).slice(0,s)===Mi(o.d).slice(0,s)){for(;c--;)o=at(o.times(o),s);return u.precision=d,t==null?(_t=!0,at(o,d)):o}o=a}}function qt(e){for(var t=e.e*yt,n=e.d[0];n>=10;n/=10)t++;return t}function $b(e,t,n){if(t>e.LN10.sd())throw _t=!0,n&&(e.precision=n),Error(qr+"LN10 precision limit exceeded");return at(new e(e.LN10),t)}function ia(e){for(var t="";e--;)t+="0";return t}function lu(e,t){var n,r,i,o,a,s,l,c,u,d=1,f=10,p=e,m=p.d,g=p.constructor,v=g.precision;if(p.s<1)throw Error(qr+(p.s?"NaN":"-Infinity"));if(p.eq(Er))return new g(0);if(t==null?(_t=!1,c=v):c=t,p.eq(10))return t==null&&(_t=!0),$b(g,c);if(c+=f,g.precision=c,n=Mi(m),r=n.charAt(0),o=qt(p),Math.abs(o)<15e14){for(;r<7&&r!=1||r==1&&n.charAt(1)>3;)p=p.times(e),n=Mi(p.d),r=n.charAt(0),d++;o=qt(p),r>1?(p=new g("0."+n),o++):p=new g(r+"."+n.slice(1))}else return l=$b(g,c+2,v).times(o+""),p=lu(new g(r+"."+n.slice(1)),c-f).plus(l),g.precision=v,t==null?(_t=!0,at(p,v)):p;for(s=a=p=wo(p.minus(Er),p.plus(Er),c),u=at(p.times(p),c),i=3;;){if(a=at(a.times(u),c),l=s.plus(wo(a,new g(i),c)),Mi(l.d).slice(0,c)===Mi(s.d).slice(0,c))return s=s.times(2),o!==0&&(s=s.plus($b(g,c+2,v).times(o+""))),s=wo(s,new g(d),c),g.precision=v,t==null?(_t=!0,at(s,v)):s;s=l,i+=2}}function nD(e,t){var n,r,i;for((n=t.indexOf("."))>-1&&(t=t.replace(".","")),(r=t.search(/e/i))>0?(n<0&&(n=r),n+=+t.slice(r+1),t=t.substring(0,r)):n<0&&(n=t.length),r=0;t.charCodeAt(r)===48;)++r;for(i=t.length;t.charCodeAt(i-1)===48;)--i;if(t=t.slice(r,i),t){if(i-=r,n=n-r-1,e.e=gl(n/yt),e.d=[],r=(n+1)%yt,n<0&&(r+=yt),r<i){for(r&&e.d.push(+t.slice(0,r)),i-=yt;r<i;)e.d.push(+t.slice(r,r+=yt));t=t.slice(r),r=yt-t.length}else r-=i;for(;r--;)t+="0";if(e.d.push(+t),_t&&(e.e>Fp||e.e<-Fp))throw Error(Rb+n)}else e.s=0,e.e=0,e.d=[0];return e}function at(e,t,n){var r,i,o,a,s,l,c,u,d=e.d;for(a=1,o=d[0];o>=10;o/=10)a++;if(r=t-a,r<0)r+=yt,i=t,c=d[u=0];else{if(u=Math.ceil((r+1)/yt),o=d.length,u>=o)return e;for(c=o=d[u],a=1;o>=10;o/=10)a++;r%=yt,i=r-yt+a}if(n!==void 0&&(o=Za(10,a-i-1),s=c/o%10|0,l=t<0||d[u+1]!==void 0||c%o,l=n<4?(s||l)&&(n==0||n==(e.s<0?3:2)):s>5||s==5&&(n==4||l||n==6&&(r>0?i>0?c/Za(10,a-i):0:d[u-1])%10&1||n==(e.s<0?8:7))),t<1||!d[0])return l?(o=qt(e),d.length=1,t=t-o-1,d[0]=Za(10,(yt-t%yt)%yt),e.e=gl(-t/yt)||0):(d.length=1,d[0]=e.e=e.s=0),e;if(r==0?(d.length=u,o=1,u--):(d.length=u+1,o=Za(10,yt-r),d[u]=i>0?(c/Za(10,a-i)%Za(10,i)|0)*o:0),l)for(;;)if(u==0){(d[0]+=o)==fn&&(d[0]=1,++e.e);break}else{if(d[u]+=o,d[u]!=fn)break;d[u--]=0,o=1}for(r=d.length;d[--r]===0;)d.pop();if(_t&&(e.e>Fp||e.e<-Fp))throw Error(Rb+qt(e));return e}function rD(e,t){var n,r,i,o,a,s,l,c,u,d,f=e.constructor,p=f.precision;if(!e.s||!t.s)return t.s?t.s=-t.s:t=new f(e),_t?at(t,p):t;if(l=e.d,d=t.d,r=t.e,c=e.e,l=l.slice(),a=c-r,a){for(u=a<0,u?(n=l,a=-a,s=d.length):(n=d,r=c,s=l.length),i=Math.max(Math.ceil(p/yt),s)+2,a>i&&(a=i,n.length=1),n.reverse(),i=a;i--;)n.push(0);n.reverse()}else{for(i=l.length,s=d.length,u=i<s,u&&(s=i),i=0;i<s;i++)if(l[i]!=d[i]){u=l[i]<d[i];break}a=0}for(u&&(n=l,l=d,d=n,t.s=-t.s),s=l.length,i=d.length-s;i>0;--i)l[s++]=0;for(i=d.length;i>a;){if(l[--i]<d[i]){for(o=i;o&&l[--o]===0;)l[o]=fn-1;--l[o],l[i]+=fn}l[i]-=d[i]}for(;l[--s]===0;)l.pop();for(;l[0]===0;l.shift())--r;return l[0]?(t.d=l,t.e=r,_t?at(t,p):t):new f(0)}function Ja(e,t,n){var r,i=qt(e),o=Mi(e.d),a=o.length;return t?(n&&(r=n-a)>0?o=o.charAt(0)+"."+o.slice(1)+ia(r):a>1&&(o=o.charAt(0)+"."+o.slice(1)),o=o+(i<0?"e":"e+")+i):i<0?(o="0."+ia(-i-1)+o,n&&(r=n-a)>0&&(o+=ia(r))):i>=a?(o+=ia(i+1-a),n&&(r=n-i-1)>0&&(o=o+"."+ia(r))):((r=i+1)<a&&(o=o.slice(0,r)+"."+o.slice(r)),n&&(r=n-a)>0&&(i+1===a&&(o+="."),o+=ia(r))),e.s<0?"-"+o:o}function iD(e,t){if(e.length>t)return e.length=t,!0}function oD(e){var t,n,r;function i(o){var a=this;if(!(a instanceof i))return new i(o);if(a.constructor=i,o instanceof i){a.s=o.s,a.e=o.e,a.d=(o=o.d)?o.slice():o;return}if(typeof o=="number"){if(o*0!==0)throw Error(Qa+o);if(o>0)a.s=1;else if(o<0)o=-o,a.s=-1;else{a.s=0,a.e=0,a.d=[0];return}if(o===~~o&&o<1e7){a.e=0,a.d=[o];return}return nD(a,o.toString())}else if(typeof o!="string")throw Error(Qa+o);if(o.charCodeAt(0)===45?(o=o.slice(1),a.s=-1):a.s=1,Rq.test(o))nD(a,o);else throw Error(Qa+o)}if(i.prototype=he,i.ROUND_UP=0,i.ROUND_DOWN=1,i.ROUND_CEIL=2,i.ROUND_FLOOR=3,i.ROUND_HALF_UP=4,i.ROUND_HALF_DOWN=5,i.ROUND_HALF_EVEN=6,i.ROUND_HALF_CEIL=7,i.ROUND_HALF_FLOOR=8,i.clone=oD,i.config=i.set=$q,e===void 0&&(e={}),e)for(r=["precision","rounding","toExpNeg","toExpPos","LN10"],t=0;t<r.length;)e.hasOwnProperty(n=r[t++])||(e[n]=this[n]);return i.config(e),i}function $q(e){if(!e||typeof e!="object")throw Error(qr+"Object expected");var t,n,r,i=["precision",1,ml,"rounding",0,8,"toExpNeg",-1/0,0,"toExpPos",0,1/0];for(t=0;t<i.length;t+=3)if((r=e[n=i[t]])!==void 0)if(gl(r)===r&&r>=i[t+1]&&r<=i[t+2])this[n]=r;else throw Error(Qa+n+": "+r);if((r=e[n="LN10"])!==void 0)if(r==Math.LN10)this[n]=new this(r);else throw Error(Qa+n+": "+r);return this}var Bb=oD(Lq);Er=new Bb(1);const Je=Bb;var Bq=e=>e,aD={},sD=e=>e===aD,lD=e=>function t(){return arguments.length===0||arguments.length===1&&sD(arguments.length<=0?void 0:arguments[0])?t:e(...arguments)},cD=(e,t)=>e===1?t:lD(function(){for(var n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];var o=r.filter(a=>a!==aD).length;return o>=e?t(...r):cD(e-o,lD(function(){for(var a=arguments.length,s=new Array(a),l=0;l<a;l++)s[l]=arguments[l];var c=r.map(u=>sD(u)?s.shift():u);return t(...c,...s)}))}),Lp=e=>cD(e.length,e),Wb=(e,t)=>{for(var n=[],r=e;r<t;++r)n[r-e]=r;return n},Wq=Lp((e,t)=>Array.isArray(t)?t.map(e):Object.keys(t).map(n=>t[n]).map(e)),zq=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];if(!n.length)return Bq;var i=n.reverse(),o=i[0],a=i.slice(1);return function(){return a.reduce((s,l)=>l(s),o(...arguments))}},zb=e=>Array.isArray(e)?e.reverse():e.split("").reverse().join(""),uD=e=>{var t=null,n=null;return function(){for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return t&&i.every((a,s)=>{var l;return a===((l=t)===null||l===void 0?void 0:l[s])})||(t=i,n=e(...i)),n}};function dD(e){var t;return e===0?t=1:t=Math.floor(new Je(e).abs().log(10).toNumber())+1,t}function fD(e,t,n){for(var r=new Je(e),i=0,o=[];r.lt(t)&&i<1e5;)o.push(r.toNumber()),r=r.add(n),i++;return o}Lp((e,t,n)=>{var r=+e,i=+t;return r+n*(i-r)}),Lp((e,t,n)=>{var r=t-+e;return r=r||1/0,(n-e)/r}),Lp((e,t,n)=>{var r=t-+e;return r=r||1/0,Math.max(0,Math.min(1,(n-e)/r))});var pD=e=>{var[t,n]=e,[r,i]=[t,n];return t>n&&([r,i]=[n,t]),[r,i]},hD=(e,t,n)=>{if(e.lte(0))return new Je(0);var r=dD(e.toNumber()),i=new Je(10).pow(r),o=e.div(i),a=r!==1?.05:.1,s=new Je(Math.ceil(o.div(a).toNumber())).add(n).mul(a),l=s.mul(i);return t?new Je(l.toNumber()):new Je(Math.ceil(l.toNumber()))},Vq=(e,t,n)=>{var r=new Je(1),i=new Je(e);if(!i.isint()&&n){var o=Math.abs(e);o<1?(r=new Je(10).pow(dD(e)-1),i=new Je(Math.floor(i.div(r).toNumber())).mul(r)):o>1&&(i=new Je(Math.floor(e)))}else e===0?i=new Je(Math.floor((t-1)/2)):n||(i=new Je(Math.floor(e)));var a=Math.floor((t-1)/2),s=zq(Wq(l=>i.add(new Je(l-a).mul(r)).toNumber()),Wb);return s(0,t)},mD=function(t,n,r,i){var o=arguments.length>4&&arguments[4]!==void 0?arguments[4]:0;if(!Number.isFinite((n-t)/(r-1)))return{step:new Je(0),tickMin:new Je(0),tickMax:new Je(0)};var a=hD(new Je(n).sub(t).div(r-1),i,o),s;t<=0&&n>=0?s=new Je(0):(s=new Je(t).add(n).div(2),s=s.sub(new Je(s).mod(a)));var l=Math.ceil(s.sub(t).div(a).toNumber()),c=Math.ceil(new Je(n).sub(s).div(a).toNumber()),u=l+c+1;return u>r?mD(t,n,r,i,o+1):(u<r&&(c=n>0?c+(r-u):c,l=n>0?l:l+(r-u)),{step:a,tickMin:s.sub(new Je(l).mul(a)),tickMax:s.add(new Je(c).mul(a))})};function Hq(e){var[t,n]=e,r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:6,i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,o=Math.max(r,2),[a,s]=pD([t,n]);if(a===-1/0||s===1/0){var l=s===1/0?[a,...Wb(0,r-1).map(()=>1/0)]:[...Wb(0,r-1).map(()=>-1/0),s];return t>n?zb(l):l}if(a===s)return Vq(a,r,i);var{step:c,tickMin:u,tickMax:d}=mD(a,s,o,i,0),f=fD(u,d.add(new Je(.1).mul(c)),c);return t>n?zb(f):f}function Yq(e,t){var[n,r]=e,i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,[o,a]=pD([n,r]);if(o===-1/0||a===1/0)return[n,r];if(o===a)return[o];var s=Math.max(t,2),l=hD(new Je(a).sub(o).div(s-1),i,0),c=[...fD(new Je(o),new Je(a),l),a];return i===!1&&(c=c.map(u=>Math.round(u))),n>r?zb(c):c}var Uq=uD(Hq),Kq=uD(Yq),gD=e=>e.rootProps.maxBarSize,qq=e=>e.rootProps.barGap,vD=e=>e.rootProps.barCategoryGap,Gq=e=>e.rootProps.barSize,cu=e=>e.rootProps.stackOffset,Vb=e=>e.options.chartName,Hb=e=>e.rootProps.syncId,yD=e=>e.rootProps.syncMethod,Yb=e=>e.options.eventEmitter,_o={allowDuplicatedCategory:!0,angleAxisId:0,reversed:!1,scale:"auto",tick:!0,type:"category"},Sr={allowDataOverflow:!1,allowDuplicatedCategory:!0,radiusAxisId:0,scale:"auto",tick:!0,tickCount:5,type:"number"},Rp=(e,t)=>{if(!(!e||!t))return e!=null&&e.reversed?[t[1],t[0]]:t},Xq={allowDataOverflow:!1,allowDecimals:!1,allowDuplicatedCategory:!1,dataKey:void 0,domain:void 0,id:_o.angleAxisId,includeHidden:!1,name:void 0,reversed:_o.reversed,scale:_o.scale,tick:_o.tick,tickCount:void 0,ticks:void 0,type:_o.type,unit:void 0},Qq={allowDataOverflow:Sr.allowDataOverflow,allowDecimals:!1,allowDuplicatedCategory:Sr.allowDuplicatedCategory,dataKey:void 0,domain:void 0,id:Sr.radiusAxisId,includeHidden:!1,name:void 0,reversed:!1,scale:Sr.scale,tick:Sr.tick,tickCount:Sr.tickCount,ticks:void 0,type:Sr.type,unit:void 0},Zq={allowDataOverflow:!1,allowDecimals:!1,allowDuplicatedCategory:_o.allowDuplicatedCategory,dataKey:void 0,domain:void 0,id:_o.angleAxisId,includeHidden:!1,name:void 0,reversed:!1,scale:_o.scale,tick:_o.tick,tickCount:void 0,ticks:void 0,type:"number",unit:void 0},Jq={allowDataOverflow:Sr.allowDataOverflow,allowDecimals:!1,allowDuplicatedCategory:Sr.allowDuplicatedCategory,dataKey:void 0,domain:void 0,id:Sr.radiusAxisId,includeHidden:!1,name:void 0,reversed:!1,scale:Sr.scale,tick:Sr.tick,tickCount:Sr.tickCount,ticks:void 0,type:"category",unit:void 0},Ub=(e,t)=>e.polarAxis.angleAxis[t]!=null?e.polarAxis.angleAxis[t]:e.layout.layoutType==="radial"?Zq:Xq,Kb=(e,t)=>e.polarAxis.radiusAxis[t]!=null?e.polarAxis.radiusAxis[t]:e.layout.layoutType==="radial"?Jq:Qq,$p=e=>e.polarOptions,qb=H([fo,po,en],LC),bD=H([$p,qb],(e,t)=>{if(e!=null)return Mn(e.innerRadius,t,0)}),xD=H([$p,qb],(e,t)=>{if(e!=null)return Mn(e.outerRadius,t,t*.8)}),eG=e=>{if(e==null)return[0,0];var{startAngle:t,endAngle:n}=e;return[t,n]},wD=H([$p],eG);H([Ub,wD],Rp);var _D=H([qb,bD,xD],(e,t,n)=>{if(!(e==null||t==null||n==null))return[t,n]});H([Kb,_D],Rp);var ED=H([ke,$p,bD,xD,fo,po],(e,t,n,r,i,o)=>{if(!(e!=="centric"&&e!=="radial"||t==null||n==null||r==null)){var{cx:a,cy:s,startAngle:l,endAngle:c}=t;return{cx:Mn(a,i,i/2),cy:Mn(s,o,o/2),innerRadius:n,outerRadius:r,startAngle:l,endAngle:c,clockWise:!1}}}),Et=(e,t)=>t,uu=(e,t,n)=>n;function Bp(e){return e?.id}var rn=e=>{var t=ke(e);return t==="horizontal"?"xAxis":t==="vertical"?"yAxis":t==="centric"?"angleAxis":"radiusAxis"},vl=e=>e.tooltip.settings.axisId,pn=e=>{var t=rn(e),n=vl(e);return du(e,t,n)},SD=H([pn],e=>e?.dataKey);function OD(e,t,n){var{chartData:r=[]}=t,{allowDuplicatedCategory:i,dataKey:o}=n,a=new Map;return e.forEach(s=>{var l,c=(l=s.data)!==null&&l!==void 0?l:r;if(!(c==null||c.length===0)){var u=Bp(s);c.forEach((d,f)=>{var p=o==null||i?f:String(ot(d,o,null)),m=ot(d,s.dataKey,0),g;a.has(p)?g=a.get(p):g={},Object.assign(g,{[u]:m}),a.set(p,g)})}}),Array.from(a.values())}function Wp(e){return e.stackId!=null&&e.dataKey!=null}function CD(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function zp(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?CD(Object(n),!0).forEach(function(r){tG(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):CD(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function tG(e,t,n){return(t=nG(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function nG(e){var t=rG(e,"string");return typeof t=="symbol"?t:t+""}function rG(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Gb=[0,"auto"],Or={allowDataOverflow:!1,allowDecimals:!0,allowDuplicatedCategory:!0,angle:0,dataKey:void 0,domain:void 0,height:30,hide:!0,id:0,includeHidden:!1,interval:"preserveEnd",minTickGap:5,mirror:!1,name:void 0,orientation:"bottom",padding:{left:0,right:0},reversed:!1,scale:"auto",tick:!0,tickCount:5,tickFormatter:void 0,ticks:void 0,type:"category",unit:void 0},kD=(e,t)=>e.cartesianAxis.xAxis[t],Ii=(e,t)=>{var n=kD(e,t);return n??Or},Cr={allowDataOverflow:!1,allowDecimals:!0,allowDuplicatedCategory:!0,angle:0,dataKey:void 0,domain:Gb,hide:!0,id:0,includeHidden:!1,interval:"preserveEnd",minTickGap:5,mirror:!1,name:void 0,orientation:"left",padding:{top:0,bottom:0},reversed:!1,scale:"auto",tick:!0,tickCount:5,tickFormatter:void 0,ticks:void 0,type:"number",unit:void 0,width:zc},PD=(e,t)=>e.cartesianAxis.yAxis[t],Fi=(e,t)=>{var n=PD(e,t);return n??Cr},iG={domain:[0,"auto"],includeHidden:!1,reversed:!1,allowDataOverflow:!1,allowDuplicatedCategory:!1,dataKey:void 0,id:0,name:"",range:[64,64],scale:"auto",type:"number",unit:""},Xb=(e,t)=>{var n=e.cartesianAxis.zAxis[t];return n??iG},Bt=(e,t,n)=>{switch(t){case"xAxis":return Ii(e,n);case"yAxis":return Fi(e,n);case"zAxis":return Xb(e,n);case"angleAxis":return Ub(e,n);case"radiusAxis":return Kb(e,n);default:throw new Error("Unexpected axis type: ".concat(t))}},oG=(e,t,n)=>{switch(t){case"xAxis":return Ii(e,n);case"yAxis":return Fi(e,n);default:throw new Error("Unexpected axis type: ".concat(t))}},du=(e,t,n)=>{switch(t){case"xAxis":return Ii(e,n);case"yAxis":return Fi(e,n);case"angleAxis":return Ub(e,n);case"radiusAxis":return Kb(e,n);default:throw new Error("Unexpected axis type: ".concat(t))}},DD=e=>e.graphicalItems.cartesianItems.some(t=>t.type==="bar")||e.graphicalItems.polarItems.some(t=>t.type==="radialBar");function Qb(e,t){return n=>{switch(e){case"xAxis":return"xAxisId"in n&&n.xAxisId===t;case"yAxis":return"yAxisId"in n&&n.yAxisId===t;case"zAxis":return"zAxisId"in n&&n.zAxisId===t;case"angleAxis":return"angleAxisId"in n&&n.angleAxisId===t;case"radiusAxis":return"radiusAxisId"in n&&n.radiusAxisId===t;default:return!1}}}var fu=e=>e.graphicalItems.cartesianItems,aG=H([Et,uu],Qb),Zb=(e,t,n)=>e.filter(n).filter(r=>t?.includeHidden===!0?!0:!r.hide),pu=H([fu,Bt,aG],Zb),AD=H([pu],e=>e.filter(t=>t.type==="area"||t.type==="bar").filter(Wp)),TD=e=>e.filter(t=>!("stackId"in t)||t.stackId===void 0),ND=H([pu],TD),Jb=e=>e.map(t=>t.data).filter(Boolean).flat(1),sG=H([pu],Jb),e0=(e,t)=>{var{chartData:n=[],dataStartIndex:r,dataEndIndex:i}=t;return e.length>0?e:n.slice(r,i+1)},t0=H([sG,su],e0),n0=(e,t,n)=>t?.dataKey!=null?e.map(r=>({value:ot(r,t.dataKey)})):n.length>0?n.map(r=>r.dataKey).flatMap(r=>e.map(i=>({value:ot(i,r)}))):e.map(r=>({value:r})),Vp=H([t0,Bt,pu],n0);function jD(e,t){switch(e){case"xAxis":return t.direction==="x";case"yAxis":return t.direction==="y";default:return!1}}function es(e){return e.filter(t=>$r(t)||t instanceof Date).map(Number).filter(t=>jn(t)===!1)}function lG(e,t,n){return!n||typeof t!="number"||jn(t)?[]:n.length?es(n.flatMap(r=>{var i=ot(e,r.dataKey),o,a;if(Array.isArray(i)?[o,a]=i:o=a=i,!(!Sn(o)||!Sn(a)))return[t-o,t+a]})):[]}var cG=H([AD,su,pn],OD),MD=(e,t,n)=>{var r={},i=t.reduce((o,a)=>(a.stackId==null||(o[a.stackId]==null&&(o[a.stackId]=[]),o[a.stackId].push(a)),o),r);return Object.fromEntries(Object.entries(i).map(o=>{var[a,s]=o,l=s.map(Bp);return[a,{stackedData:mY(e,l,n),graphicalItems:s}]}))},hu=H([cG,AD,cu],MD),ID=(e,t,n)=>{var{dataStartIndex:r,dataEndIndex:i}=t;if(n!=="zAxis"){var o=bY(e,r,i);if(!(o!=null&&o[0]===0&&o[1]===0))return o}},uG=H([hu,ra,Et],ID),FD=(e,t,n,r,i)=>n.length>0?e.flatMap(o=>n.flatMap(a=>{var s,l,c=(s=r[a.id])===null||s===void 0?void 0:s.filter(d=>jD(i,d)),u=ot(o,(l=t.dataKey)!==null&&l!==void 0?l:a.dataKey);return{value:u,errorDomain:lG(o,u,c)}})).filter(Boolean):t?.dataKey!=null?e.map(o=>({value:ot(o,t.dataKey),errorDomain:[]})):e.map(o=>({value:o,errorDomain:[]})),Hp=e=>e.errorBars,LD=(e,t,n)=>e.flatMap(r=>t[r.id]).filter(Boolean).filter(r=>jD(n,r));H([ND,Hp,Et],LD);var dG=H([t0,Bt,ND,Hp,Et],FD);function fG(e){var{value:t}=e;if($r(t)||t instanceof Date)return t}var RD=e=>{var t=e.flatMap(r=>[r.value,r.errorDomain]).flat(1),n=es(t);if(n.length!==0)return[Math.min(...n),Math.max(...n)]},pG=(e,t,n)=>{var r=e.map(fG).filter(i=>i!=null);return n&&(t.dataKey==null||t.allowDuplicatedCategory&&u2(r))?Mk(0,e.length):t.allowDuplicatedCategory?r:Array.from(new Set(r))},r0=e=>{var t;if(e==null||!("domain"in e))return Gb;if(e.domain!=null)return e.domain;if(e.ticks!=null){if(e.type==="number"){var n=es(e.ticks);return[Math.min(...n),Math.max(...n)]}if(e.type==="category")return e.ticks.map(String)}return(t=e?.domain)!==null&&t!==void 0?t:Gb},Yp=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var i=n.filter(Boolean);if(i.length!==0){var o=i.flat(),a=Math.min(...o),s=Math.max(...o);return[a,s]}},$D=e=>e.referenceElements.dots,yl=(e,t,n)=>e.filter(r=>r.ifOverflow==="extendDomain").filter(r=>t==="xAxis"?r.xAxisId===n:r.yAxisId===n),hG=H([$D,Et,uu],yl),BD=e=>e.referenceElements.areas,mG=H([BD,Et,uu],yl),WD=e=>e.referenceElements.lines,gG=H([WD,Et,uu],yl),zD=(e,t)=>{var n=es(e.map(r=>t==="xAxis"?r.x:r.y));if(n.length!==0)return[Math.min(...n),Math.max(...n)]},vG=H(hG,Et,zD),VD=(e,t)=>{var n=es(e.flatMap(r=>[t==="xAxis"?r.x1:r.y1,t==="xAxis"?r.x2:r.y2]));if(n.length!==0)return[Math.min(...n),Math.max(...n)]},yG=H([mG,Et],VD),HD=(e,t)=>{var n=es(e.map(r=>t==="xAxis"?r.x:r.y));if(n.length!==0)return[Math.min(...n),Math.max(...n)]},bG=H(gG,Et,HD),xG=H(vG,bG,yG,(e,t,n)=>Yp(e,n,t)),YD=H([Bt],r0),i0=(e,t,n,r,i,o,a)=>{var s=Iq(t,e.allowDataOverflow);if(s!=null)return s;var l=o==="vertical"&&a==="xAxis"||o==="horizontal"&&a==="yAxis",c=l?Yp(n,i,RD(r)):Yp(i,RD(r));return Fq(t,c,e.allowDataOverflow)},wG=H([Bt,YD,uG,dG,xG,ke,Et],i0),_G=[0,1],o0=(e,t,n,r,i,o,a)=>{if(!((e==null||n==null||n.length===0)&&a===void 0)){var{dataKey:s,type:l}=e,c=Ti(t,o);return c&&s==null?Mk(0,n.length):l==="category"?pG(r,e,c):i==="expand"?_G:a}},a0=H([Bt,ke,t0,Vp,cu,Et,wG],o0),UD=(e,t,n,r,i)=>{if(e!=null){var{scale:o,type:a}=e;if(o==="auto")return t==="radial"&&i==="radiusAxis"?"band":t==="radial"&&i==="angleAxis"?"linear":a==="category"&&r&&(r.indexOf("LineChart")>=0||r.indexOf("AreaChart")>=0||r.indexOf("ComposedChart")>=0&&!n)?"point":a==="category"?"band":"linear";if(typeof o=="string"){var s="scale".concat(Mc(o));return s in au?s:"point"}}},bl=H([Bt,ke,DD,Vb,Et],UD);function EG(e){if(e!=null){if(e in au)return au[e]();var t="scale".concat(Mc(e));if(t in au)return au[t]()}}function s0(e,t,n,r){if(!(n==null||r==null)){if(typeof e.scale=="function")return e.scale.copy().domain(n).range(r);var i=EG(t);if(i!=null){var o=i.domain(n).range(r);return uY(o),o}}}var l0=(e,t,n)=>{var r=r0(t);if(!(n!=="auto"&&n!=="linear")){if(t!=null&&t.tickCount&&Array.isArray(r)&&(r[0]==="auto"||r[1]==="auto")&&hl(e))return Uq(e,t.tickCount,t.allowDecimals);if(t!=null&&t.tickCount&&t.type==="number"&&hl(e))return Kq(e,t.tickCount,t.allowDecimals)}},c0=H([a0,du,bl],l0),u0=(e,t,n,r)=>{if(r!=="angleAxis"&&e?.type==="number"&&hl(t)&&Array.isArray(n)&&n.length>0){var i=t[0],o=n[0],a=t[1],s=n[n.length-1];return[Math.min(i,o),Math.max(a,s)]}return t},SG=H([Bt,a0,c0,Et],u0),OG=H(Vp,Bt,(e,t)=>{if(!(!t||t.type!=="number")){var n=1/0,r=Array.from(es(e.map(s=>s.value))).sort((s,l)=>s-l);if(r.length<2)return 1/0;var i=r[r.length-1]-r[0];if(i===0)return 1/0;for(var o=0;o<r.length-1;o++){var a=r[o+1]-r[o];n=Math.min(n,a)}return n/i}}),KD=H(OG,ke,vD,en,(e,t,n,r)=>r,(e,t,n,r,i)=>{if(!Sn(e))return 0;var o=t==="vertical"?r.height:r.width;if(i==="gap")return e*o/2;if(i==="no-gap"){var a=Mn(n,e*o),s=e*o/2;return s-a-(s-a)/o*a}return 0}),CG=(e,t)=>{var n=Ii(e,t);return n==null||typeof n.padding!="string"?0:KD(e,"xAxis",t,n.padding)},kG=(e,t)=>{var n=Fi(e,t);return n==null||typeof n.padding!="string"?0:KD(e,"yAxis",t,n.padding)},PG=H(Ii,CG,(e,t)=>{var n,r;if(e==null)return{left:0,right:0};var{padding:i}=e;return typeof i=="string"?{left:t,right:t}:{left:((n=i.left)!==null&&n!==void 0?n:0)+t,right:((r=i.right)!==null&&r!==void 0?r:0)+t}}),DG=H(Fi,kG,(e,t)=>{var n,r;if(e==null)return{top:0,bottom:0};var{padding:i}=e;return typeof i=="string"?{top:t,bottom:t}:{top:((n=i.top)!==null&&n!==void 0?n:0)+t,bottom:((r=i.bottom)!==null&&r!==void 0?r:0)+t}}),AG=H([en,PG,up,cp,(e,t,n)=>n],(e,t,n,r,i)=>{var{padding:o}=r;return i?[o.left,n.width-o.right]:[e.left+t.left,e.left+e.width-t.right]}),TG=H([en,ke,DG,up,cp,(e,t,n)=>n],(e,t,n,r,i,o)=>{var{padding:a}=i;return o?[r.height-a.bottom,a.top]:t==="horizontal"?[e.top+e.height-n.bottom,e.top+n.top]:[e.top+n.top,e.top+e.height-n.bottom]}),mu=(e,t,n,r)=>{var i;switch(t){case"xAxis":return AG(e,n,r);case"yAxis":return TG(e,n,r);case"zAxis":return(i=Xb(e,n))===null||i===void 0?void 0:i.range;case"angleAxis":return wD(e);case"radiusAxis":return _D(e,n);default:return}},qD=H([Bt,mu],Rp),oa=H([Bt,bl,SG,qD],s0);H([pu,Hp,Et],LD);function GD(e,t){return e.id<t.id?-1:e.id>t.id?1:0}var Up=(e,t)=>t,Kp=(e,t,n)=>n,NG=H(ap,Up,Kp,(e,t,n)=>e.filter(r=>r.orientation===t).filter(r=>r.mirror===n).sort(GD)),jG=H(sp,Up,Kp,(e,t,n)=>e.filter(r=>r.orientation===t).filter(r=>r.mirror===n).sort(GD)),XD=(e,t)=>({width:e.width,height:t.height}),MG=(e,t)=>{var n=typeof t.width=="number"?t.width:zc;return{width:n,height:e.height}},QD=H(en,Ii,XD),IG=(e,t,n)=>{switch(t){case"top":return e.top;case"bottom":return n-e.bottom;default:return 0}},FG=(e,t,n)=>{switch(t){case"left":return e.left;case"right":return n-e.right;default:return 0}},LG=H(po,en,NG,Up,Kp,(e,t,n,r,i)=>{var o={},a;return n.forEach(s=>{var l=XD(t,s);a==null&&(a=IG(t,r,e));var c=r==="top"&&!i||r==="bottom"&&i;o[s.id]=a-Number(c)*l.height,a+=(c?-1:1)*l.height}),o}),RG=H(fo,en,jG,Up,Kp,(e,t,n,r,i)=>{var o={},a;return n.forEach(s=>{var l=MG(t,s);a==null&&(a=FG(t,r,e));var c=r==="left"&&!i||r==="right"&&i;o[s.id]=a-Number(c)*l.width,a+=(c?-1:1)*l.width}),o}),$G=(e,t)=>{var n=Ii(e,t);if(n!=null)return LG(e,n.orientation,n.mirror)},BG=H([en,Ii,$G,(e,t)=>t],(e,t,n,r)=>{if(t!=null){var i=n?.[r];return i==null?{x:e.left,y:0}:{x:e.left,y:i}}}),WG=(e,t)=>{var n=Fi(e,t);if(n!=null)return RG(e,n.orientation,n.mirror)},zG=H([en,Fi,WG,(e,t)=>t],(e,t,n,r)=>{if(t!=null){var i=n?.[r];return i==null?{x:0,y:e.top}:{x:i,y:e.top}}}),ZD=H(en,Fi,(e,t)=>{var n=typeof t.width=="number"?t.width:zc;return{width:n,height:e.height}}),JD=(e,t,n)=>{switch(t){case"xAxis":return QD(e,n).width;case"yAxis":return ZD(e,n).height;default:return}},eA=(e,t,n,r)=>{if(n!=null){var{allowDuplicatedCategory:i,type:o,dataKey:a}=n,s=Ti(e,r),l=t.map(c=>c.value);if(a&&s&&o==="category"&&i&&u2(l))return l}},d0=H([ke,Vp,Bt,Et],eA),tA=(e,t,n,r)=>{if(!(n==null||n.dataKey==null)){var{type:i,scale:o}=n,a=Ti(e,r);if(a&&(i==="number"||o!=="auto"))return t.map(s=>s.value)}},f0=H([ke,Vp,du,Et],tA),nA=H([ke,oG,bl,oa,d0,f0,mu,c0,Et],(e,t,n,r,i,o,a,s,l)=>{if(t==null)return null;var c=Ti(e,l);return{angle:t.angle,interval:t.interval,minTickGap:t.minTickGap,orientation:t.orientation,tick:t.tick,tickCount:t.tickCount,tickFormatter:t.tickFormatter,ticks:t.ticks,type:t.type,unit:t.unit,axisType:l,categoricalDomain:o,duplicateDomain:i,isCategorical:c,niceTicks:s,range:a,realScaleType:n,scale:r}}),VG=(e,t,n,r,i,o,a,s,l)=>{if(!(t==null||r==null)){var c=Ti(e,l),{type:u,ticks:d,tickCount:f}=t,p=n==="scaleBand"&&typeof r.bandwidth=="function"?r.bandwidth()/2:2,m=u==="category"&&r.bandwidth?r.bandwidth()/p:0;m=l==="angleAxis"&&o!=null&&o.length>=2?un(o[0]-o[1])*2*m:m;var g=d||i;if(g){var v=g.map((x,_)=>{var w=a?a.indexOf(x):x;return{index:_,coordinate:r(w)+m,value:x,offset:m}});return v.filter(x=>!jn(x.coordinate))}return c&&s?s.map((x,_)=>({coordinate:r(x)+m,value:x,index:_,offset:m})):r.ticks?r.ticks(f).map(x=>({coordinate:r(x)+m,value:x,offset:m})):r.domain().map((x,_)=>({coordinate:r(x)+m,value:a?a[x]:x,index:_,offset:m}))}},rA=H([ke,du,bl,oa,c0,mu,d0,f0,Et],VG),HG=(e,t,n,r,i,o,a)=>{if(!(t==null||n==null||r==null||r[0]===r[1])){var s=Ti(e,a),{tickCount:l}=t,c=0;return c=a==="angleAxis"&&r?.length>=2?un(r[0]-r[1])*2*c:c,s&&o?o.map((u,d)=>({coordinate:n(u)+c,value:u,index:d,offset:c})):n.ticks?n.ticks(l).map(u=>({coordinate:n(u)+c,value:u,offset:c})):n.domain().map((u,d)=>({coordinate:n(u)+c,value:i?i[u]:u,index:d,offset:c}))}},Li=H([ke,du,oa,mu,d0,f0,Et],HG),Ri=H(Bt,oa,(e,t)=>{if(!(e==null||t==null))return zp(zp({},e),{},{scale:t})}),YG=H([Bt,bl,a0,qD],s0);H((e,t,n)=>Xb(e,n),YG,(e,t)=>{if(!(e==null||t==null))return zp(zp({},e),{},{scale:t})});var UG=H([ke,ap,sp],(e,t,n)=>{switch(e){case"horizontal":return t.some(r=>r.reversed)?"right-to-left":"left-to-right";case"vertical":return n.some(r=>r.reversed)?"bottom-to-top":"top-to-bottom";case"centric":case"radial":return"left-to-right";default:return}}),iA=e=>e.options.defaultTooltipEventType,oA=e=>e.options.validateTooltipEventTypes;function aA(e,t,n){if(e==null)return t;var r=e?"axis":"item";return n==null?t:n.includes(r)?r:t}function p0(e,t){var n=iA(e),r=oA(e);return aA(t,n,r)}function KG(e){return pe(t=>p0(t,e))}var sA=(e,t)=>{var n,r=Number(t);if(!(jn(r)||t==null))return r>=0?e==null||(n=e[r])===null||n===void 0?void 0:n.value:void 0},qG=e=>e.tooltip.settings,aa={active:!1,index:null,dataKey:void 0,coordinate:void 0},GG={itemInteraction:{click:aa,hover:aa},axisInteraction:{click:aa,hover:aa},keyboardInteraction:aa,syncInteraction:{active:!1,index:null,dataKey:void 0,label:void 0,coordinate:void 0},tooltipItemPayloads:[],settings:{shared:void 0,trigger:"hover",axisId:0,active:!1,defaultIndex:void 0}},lA=_r({name:"tooltip",initialState:GG,reducers:{addTooltipEntrySettings(e,t){e.tooltipItemPayloads.push(t.payload)},removeTooltipEntrySettings(e,t){var n=uo(e).tooltipItemPayloads.indexOf(t.payload);n>-1&&e.tooltipItemPayloads.splice(n,1)},setTooltipSettingsState(e,t){e.settings=t.payload},setActiveMouseOverItemIndex(e,t){e.syncInteraction.active=!1,e.keyboardInteraction.active=!1,e.itemInteraction.hover.active=!0,e.itemInteraction.hover.index=t.payload.activeIndex,e.itemInteraction.hover.dataKey=t.payload.activeDataKey,e.itemInteraction.hover.coordinate=t.payload.activeCoordinate},mouseLeaveChart(e){e.itemInteraction.hover.active=!1,e.axisInteraction.hover.active=!1},mouseLeaveItem(e){e.itemInteraction.hover.active=!1},setActiveClickItemIndex(e,t){e.syncInteraction.active=!1,e.itemInteraction.click.active=!0,e.keyboardInteraction.active=!1,e.itemInteraction.click.index=t.payload.activeIndex,e.itemInteraction.click.dataKey=t.payload.activeDataKey,e.itemInteraction.click.coordinate=t.payload.activeCoordinate},setMouseOverAxisIndex(e,t){e.syncInteraction.active=!1,e.axisInteraction.hover.active=!0,e.keyboardInteraction.active=!1,e.axisInteraction.hover.index=t.payload.activeIndex,e.axisInteraction.hover.dataKey=t.payload.activeDataKey,e.axisInteraction.hover.coordinate=t.payload.activeCoordinate},setMouseClickAxisIndex(e,t){e.syncInteraction.active=!1,e.keyboardInteraction.active=!1,e.axisInteraction.click.active=!0,e.axisInteraction.click.index=t.payload.activeIndex,e.axisInteraction.click.dataKey=t.payload.activeDataKey,e.axisInteraction.click.coordinate=t.payload.activeCoordinate},setSyncInteraction(e,t){e.syncInteraction=t.payload},setKeyboardInteraction(e,t){e.keyboardInteraction.active=t.payload.active,e.keyboardInteraction.index=t.payload.activeIndex,e.keyboardInteraction.coordinate=t.payload.activeCoordinate,e.keyboardInteraction.dataKey=t.payload.activeDataKey}}}),{addTooltipEntrySettings:XG,removeTooltipEntrySettings:QG,setTooltipSettingsState:ZG,setActiveMouseOverItemIndex:cA,mouseLeaveItem:JG,mouseLeaveChart:uA,setActiveClickItemIndex:eX,setMouseOverAxisIndex:dA,setMouseClickAxisIndex:tX,setSyncInteraction:h0,setKeyboardInteraction:m0}=lA.actions,nX=lA.reducer;function fA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function qp(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?fA(Object(n),!0).forEach(function(r){rX(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):fA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function rX(e,t,n){return(t=iX(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function iX(e){var t=oX(e,"string");return typeof t=="symbol"?t:t+""}function oX(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function aX(e,t,n){return t==="axis"?n==="click"?e.axisInteraction.click:e.axisInteraction.hover:n==="click"?e.itemInteraction.click:e.itemInteraction.hover}function sX(e){return e.index!=null}var pA=(e,t,n,r)=>{if(t==null)return aa;var i=aX(e,t,n);if(i==null)return aa;if(i.active)return i;if(e.keyboardInteraction.active)return e.keyboardInteraction;if(e.syncInteraction.active&&e.syncInteraction.index!=null)return e.syncInteraction;var o=e.settings.active===!0;if(sX(i)){if(o)return qp(qp({},i),{},{active:!0})}else if(r!=null)return{active:!0,coordinate:void 0,dataKey:void 0,index:r};return qp(qp({},aa),{},{coordinate:i.coordinate})},g0=(e,t)=>{var n=e?.index;if(n==null)return null;var r=Number(n);if(!Sn(r))return n;var i=0,o=1/0;return t.length>0&&(o=t.length-1),String(Math.max(i,Math.min(r,o)))},hA=(e,t,n,r,i,o,a,s)=>{if(!(o==null||s==null)){var l=a[0],c=l==null?void 0:s(l.positions,o);if(c!=null)return c;var u=i?.[Number(o)];if(u)switch(n){case"horizontal":return{x:u.coordinate,y:(r.top+t)/2};default:return{x:(r.left+e)/2,y:u.coordinate}}}},mA=(e,t,n,r)=>{if(t==="axis")return e.tooltipItemPayloads;if(e.tooltipItemPayloads.length===0)return[];var i;return n==="hover"?i=e.itemInteraction.hover.dataKey:i=e.itemInteraction.click.dataKey,i==null&&r!=null?[e.tooltipItemPayloads[0]]:e.tooltipItemPayloads.filter(o=>{var a;return((a=o.settings)===null||a===void 0?void 0:a.dataKey)===i})},gu=e=>e.options.tooltipPayloadSearcher,xl=e=>e.tooltip;function gA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function vA(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?gA(Object(n),!0).forEach(function(r){lX(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):gA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function lX(e,t,n){return(t=cX(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function cX(e){var t=uX(e,"string");return typeof t=="symbol"?t:t+""}function uX(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function dX(e,t){return e??t}var yA=(e,t,n,r,i,o,a)=>{if(!(t==null||o==null)){var{chartData:s,computedData:l,dataStartIndex:c,dataEndIndex:u}=n,d=[];return e.reduce((f,p)=>{var m,{dataDefinedOnItem:g,settings:v}=p,x=dX(g,s),_=Array.isArray(x)?RC(x,c,u):x,w=(m=v?.dataKey)!==null&&m!==void 0?m:r,y=v?.nameKey,E;if(r&&Array.isArray(_)&&!Array.isArray(_[0])&&a==="axis"?E=d2(_,r,i):E=o(_,t,l,y),Array.isArray(E))E.forEach(P=>{var D=vA(vA({},v),{},{name:P.name,unit:P.unit,color:void 0,fill:void 0});f.push(KC({tooltipEntrySettings:D,dataKey:P.dataKey,payload:P.payload,value:ot(P.payload,P.dataKey),name:P.name}))});else{var S;f.push(KC({tooltipEntrySettings:v,dataKey:w,payload:E,value:ot(E,w),name:(S=ot(E,y))!==null&&S!==void 0?S:v?.name}))}return f},d)}},v0=H([pn,ke,DD,Vb,rn],UD),fX=H([e=>e.graphicalItems.cartesianItems,e=>e.graphicalItems.polarItems],(e,t)=>[...e,...t]),pX=H([rn,vl],Qb),vu=H([fX,pn,pX],Zb),hX=H([vu],e=>e.filter(Wp)),mX=H([vu],Jb),wl=H([mX,ra],e0),gX=H([hX,ra,pn],OD),y0=H([wl,pn,vu],n0),vX=H([pn],r0),yX=H([vu],e=>e.filter(Wp)),bX=H([gX,yX,cu],MD),xX=H([bX,ra,rn],ID),wX=H([vu],TD),_X=H([wl,pn,wX,Hp,rn],FD),EX=H([$D,rn,vl],yl),SX=H([EX,rn],zD),OX=H([BD,rn,vl],yl),CX=H([OX,rn],VD),kX=H([WD,rn,vl],yl),PX=H([kX,rn],HD),DX=H([SX,PX,CX],Yp),AX=H([pn,vX,xX,_X,DX,ke,rn],i0),bA=H([pn,ke,wl,y0,cu,rn,AX],o0),TX=H([bA,pn,v0],l0),NX=H([pn,bA,TX,rn],u0),xA=e=>{var t=rn(e),n=vl(e),r=!1;return mu(e,t,n,r)},wA=H([pn,xA],Rp),_A=H([pn,v0,NX,wA],s0),jX=H([ke,y0,pn,rn],eA),MX=H([ke,y0,pn,rn],tA),IX=(e,t,n,r,i,o,a,s)=>{if(t){var{type:l}=t,c=Ti(e,s);if(r){var u=n==="scaleBand"&&r.bandwidth?r.bandwidth()/2:2,d=l==="category"&&r.bandwidth?r.bandwidth()/u:0;return d=s==="angleAxis"&&i!=null&&i?.length>=2?un(i[0]-i[1])*2*d:d,c&&a?a.map((f,p)=>({coordinate:r(f)+d,value:f,index:p,offset:d})):r.domain().map((f,p)=>({coordinate:r(f)+d,value:o?o[f]:f,index:p,offset:d}))}}},Eo=H([ke,pn,v0,_A,xA,jX,MX,rn],IX),b0=H([iA,oA,qG],(e,t,n)=>aA(n.shared,e,t)),EA=e=>e.tooltip.settings.trigger,x0=e=>e.tooltip.settings.defaultIndex,Gp=H([xl,b0,EA,x0],pA),sa=H([Gp,wl],g0),SA=H([Eo,sa],sA),OA=H([Gp],e=>{if(e)return e.dataKey}),CA=H([xl,b0,EA,x0],mA),FX=H([fo,po,ke,en,Eo,x0,CA,gu],hA),LX=H([Gp,FX],(e,t)=>e!=null&&e.coordinate?e.coordinate:t),RX=H([Gp],e=>e.active),$X=H([CA,sa,ra,SD,SA,gu,b0],yA),BX=H([$X],e=>{if(e!=null){var t=e.map(n=>n.payload).filter(n=>n!=null);return Array.from(new Set(t))}});function kA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function PA(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?kA(Object(n),!0).forEach(function(r){WX(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):kA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function WX(e,t,n){return(t=zX(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function zX(e){var t=VX(e,"string");return typeof t=="symbol"?t:t+""}function VX(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var HX=()=>pe(pn),YX=()=>{var e=HX(),t=pe(Eo),n=pe(_A);return Ya(PA(PA({},e),{},{scale:n}),t)},DA=()=>pe(Vb),w0=(e,t)=>t,AA=(e,t,n)=>n,_0=(e,t,n,r)=>r,UX=H(Eo,e=>zf(e,t=>t.coordinate)),E0=H([xl,w0,AA,_0],pA),TA=H([E0,wl],g0),KX=(e,t,n)=>{if(t!=null){var r=xl(e);return t==="axis"?n==="hover"?r.axisInteraction.hover.dataKey:r.axisInteraction.click.dataKey:n==="hover"?r.itemInteraction.hover.dataKey:r.itemInteraction.click.dataKey}},NA=H([xl,w0,AA,_0],mA),Xp=H([fo,po,ke,en,Eo,_0,NA,gu],hA),qX=H([E0,Xp],(e,t)=>{var n;return(n=e.coordinate)!==null&&n!==void 0?n:t}),jA=H(Eo,TA,sA),GX=H([NA,TA,ra,SD,jA,gu,w0],yA),XX=H([E0],e=>({isActive:e.active,activeIndex:e.index})),QX=(e,t,n,r,i,o,a,s)=>{if(!(!e||!t||!r||!i||!o)){var l=xY(e.chartX,e.chartY,t,n,s);if(l){var c=_Y(l,t),u=lY(c,a,o,r,i),d=wY(t,o,u,l);return{activeIndex:String(u),activeCoordinate:d}}}};function S0(){return S0=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},S0.apply(null,arguments)}function MA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Qp(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?MA(Object(n),!0).forEach(function(r){ZX(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):MA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function ZX(e,t,n){return(t=JX(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function JX(e){var t=eQ(e,"string");return typeof t=="symbol"?t:t+""}function eQ(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function tQ(e){var{coordinate:t,payload:n,index:r,offset:i,tooltipAxisBandSize:o,layout:a,cursor:s,tooltipEventType:l,chartName:c}=e,u=t,d=n,f=r;if(!s||!u||c!=="ScatterChart"&&l!=="axis")return null;var p,m;if(c==="ScatterChart")p=u,m=_9;else if(c==="BarChart")p=E9(a,u,i,o),m=Ck;else if(a==="radial"){var{cx:g,cy:v,radius:x,startAngle:_,endAngle:w}=kk(u);p={cx:g,cy:v,startAngle:_,endAngle:w,innerRadius:x,outerRadius:x},m=Dk}else p={points:nU(a,u,i)},m=ol;var y=typeof s=="object"&&"className"in s?s.className:void 0,E=Qp(Qp(Qp(Qp({stroke:"#ccc",pointerEvents:"none"},i),p),dt(s,!1)),{},{payload:d,payloadIndex:f,className:ue("recharts-tooltip-cursor",y)});return k.isValidElement(s)?k.cloneElement(s,E):k.createElement(m,E)}function nQ(e){var t=YX(),n=ZC(),r=Vc(),i=DA();return O.createElement(tQ,S0({},e,{coordinate:e.coordinate,index:e.index,payload:e.payload,offset:n,layout:r,tooltipAxisBandSize:t,chartName:i}))}var IA=k.createContext(null),rQ=()=>k.useContext(IA),O0={exports:{}},FA;function iQ(){return FA||(FA=1,(function(e){var t=Object.prototype.hasOwnProperty,n="~";function r(){}Object.create&&(r.prototype=Object.create(null),new r().__proto__||(n=!1));function i(l,c,u){this.fn=l,this.context=c,this.once=u||!1}function o(l,c,u,d,f){if(typeof u!="function")throw new TypeError("The listener must be a function");var p=new i(u,d||l,f),m=n?n+c:c;return l._events[m]?l._events[m].fn?l._events[m]=[l._events[m],p]:l._events[m].push(p):(l._events[m]=p,l._eventsCount++),l}function a(l,c){--l._eventsCount===0?l._events=new r:delete l._events[c]}function s(){this._events=new r,this._eventsCount=0}s.prototype.eventNames=function(){var c=[],u,d;if(this._eventsCount===0)return c;for(d in u=this._events)t.call(u,d)&&c.push(n?d.slice(1):d);return Object.getOwnPropertySymbols?c.concat(Object.getOwnPropertySymbols(u)):c},s.prototype.listeners=function(c){var u=n?n+c:c,d=this._events[u];if(!d)return[];if(d.fn)return[d.fn];for(var f=0,p=d.length,m=new Array(p);f<p;f++)m[f]=d[f].fn;return m},s.prototype.listenerCount=function(c){var u=n?n+c:c,d=this._events[u];return d?d.fn?1:d.length:0},s.prototype.emit=function(c,u,d,f,p,m){var g=n?n+c:c;if(!this._events[g])return!1;var v=this._events[g],x=arguments.length,_,w;if(v.fn){switch(v.once&&this.removeListener(c,v.fn,void 0,!0),x){case 1:return v.fn.call(v.context),!0;case 2:return v.fn.call(v.context,u),!0;case 3:return v.fn.call(v.context,u,d),!0;case 4:return v.fn.call(v.context,u,d,f),!0;case 5:return v.fn.call(v.context,u,d,f,p),!0;case 6:return v.fn.call(v.context,u,d,f,p,m),!0}for(w=1,_=new Array(x-1);w<x;w++)_[w-1]=arguments[w];v.fn.apply(v.context,_)}else{var y=v.length,E;for(w=0;w<y;w++)switch(v[w].once&&this.removeListener(c,v[w].fn,void 0,!0),x){case 1:v[w].fn.call(v[w].context);break;case 2:v[w].fn.call(v[w].context,u);break;case 3:v[w].fn.call(v[w].context,u,d);break;case 4:v[w].fn.call(v[w].context,u,d,f);break;default:if(!_)for(E=1,_=new Array(x-1);E<x;E++)_[E-1]=arguments[E];v[w].fn.apply(v[w].context,_)}}return!0},s.prototype.on=function(c,u,d){return o(this,c,u,d,!1)},s.prototype.once=function(c,u,d){return o(this,c,u,d,!0)},s.prototype.removeListener=function(c,u,d,f){var p=n?n+c:c;if(!this._events[p])return this;if(!u)return a(this,p),this;var m=this._events[p];if(m.fn)m.fn===u&&(!f||m.once)&&(!d||m.context===d)&&a(this,p);else{for(var g=0,v=[],x=m.length;g<x;g++)(m[g].fn!==u||f&&!m[g].once||d&&m[g].context!==d)&&v.push(m[g]);v.length?this._events[p]=v.length===1?v[0]:v:a(this,p)}return this},s.prototype.removeAllListeners=function(c){var u;return c?(u=n?n+c:c,this._events[u]&&a(this,u)):(this._events=new r,this._eventsCount=0),this},s.prototype.off=s.prototype.removeListener,s.prototype.addListener=s.prototype.on,s.prefixed=n,s.EventEmitter=s,e.exports=s})(O0)),O0.exports}var oQ=iQ();const aQ=Ki(oQ);var yu=new aQ,C0="recharts.syncEvent.tooltip",LA="recharts.syncEvent.brush";function Zp(e,t){if(t){var n=Number.parseInt(t,10);if(!jn(n))return e?.[n]}}var sQ={chartName:"",tooltipPayloadSearcher:void 0,eventEmitter:void 0,defaultTooltipEventType:"axis"},RA=_r({name:"options",initialState:sQ,reducers:{createEventEmitter:e=>{e.eventEmitter==null&&(e.eventEmitter=Symbol("rechartsEventEmitter"))}}}),lQ=RA.reducer,{createEventEmitter:cQ}=RA.actions;function uQ(e){return e.tooltip.syncInteraction}var dQ={chartData:void 0,computedData:void 0,dataStartIndex:0,dataEndIndex:0},$A=_r({name:"chartData",initialState:dQ,reducers:{setChartData(e,t){if(e.chartData=t.payload,t.payload==null){e.dataStartIndex=0,e.dataEndIndex=0;return}t.payload.length>0&&e.dataEndIndex!==t.payload.length-1&&(e.dataEndIndex=t.payload.length-1)},setComputedData(e,t){e.computedData=t.payload},setDataStartEndIndexes(e,t){var{startIndex:n,endIndex:r}=t.payload;n!=null&&(e.dataStartIndex=n),r!=null&&(e.dataEndIndex=r)}}}),{setChartData:BA,setDataStartEndIndexes:fQ,setComputedData:Jhe}=$A.actions,pQ=$A.reducer,hQ=["x","y"];function WA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function ts(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?WA(Object(n),!0).forEach(function(r){mQ(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):WA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function mQ(e,t,n){return(t=gQ(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function gQ(e){var t=vQ(e,"string");return typeof t=="symbol"?t:t+""}function vQ(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function yQ(e,t){if(e==null)return{};var n,r,i=bQ(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function bQ(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}var zA=()=>{};function xQ(){var e=pe(Hb),t=pe(Yb),n=wt(),r=pe(yD),i=pe(Eo),o=Vc(),a=dp(),s=pe(l=>l.rootProps.className);k.useEffect(()=>{if(e==null)return zA;var l=(c,u,d)=>{if(t!==d&&e===c){if(r==="index"){var f;if(a&&u!==null&&u!==void 0&&(f=u.payload)!==null&&f!==void 0&&f.coordinate){var p=u.payload.coordinate,{x:m,y:g}=p,v=yQ(p,hQ),x=ts(ts(ts({},v),typeof m=="number"&&{x:Math.max(a.x,Math.min(m,a.x+a.width))}),typeof g=="number"&&{y:Math.max(a.y,Math.min(g,a.y+a.height))}),_=ts(ts({},u),{},{payload:ts(ts({},u.payload),{},{coordinate:x})});n(_)}else n(u);return}if(i!=null){var w;if(typeof r=="function"){var y={activeTooltipIndex:u.payload.index==null?void 0:Number(u.payload.index),isTooltipActive:u.payload.active,activeIndex:u.payload.index==null?void 0:Number(u.payload.index),activeLabel:u.payload.label,activeDataKey:u.payload.dataKey,activeCoordinate:u.payload.coordinate},E=r(i,y);w=i[E]}else r==="value"&&(w=i.find(j=>String(j.value)===u.payload.label));var{coordinate:S}=u.payload;if(w==null||u.payload.active===!1||S==null||a==null){n(h0({active:!1,coordinate:void 0,dataKey:void 0,index:null,label:void 0}));return}var{x:P,y:D}=S,T=Math.min(P,a.x+a.width),I=Math.min(D,a.y+a.height),A={x:o==="horizontal"?w.coordinate:T,y:o==="horizontal"?I:w.coordinate},C=h0({active:u.payload.active,coordinate:A,dataKey:u.payload.dataKey,index:String(w.index),label:u.payload.label});n(C)}}};return yu.on(C0,l),()=>{yu.off(C0,l)}},[s,n,t,e,r,i,o,a])}function wQ(){var e=pe(Hb),t=pe(Yb),n=wt();k.useEffect(()=>{if(e==null)return zA;var r=(i,o,a)=>{t!==a&&e===i&&n(fQ(o))};return yu.on(LA,r),()=>{yu.off(LA,r)}},[n,t,e])}function _Q(){var e=wt();k.useEffect(()=>{e(cQ())},[e]),xQ(),wQ()}function EQ(e,t,n,r,i,o){var a=pe(f=>KX(f,e,t)),s=pe(Yb),l=pe(Hb),c=pe(yD),u=pe(uQ),d=u?.active;k.useEffect(()=>{if(!d&&l!=null&&s!=null){var f=h0({active:o,coordinate:n,dataKey:a,index:i,label:typeof r=="number"?String(r):r});yu.emit(C0,l,f,s)}},[d,n,a,i,r,s,l,c,o])}function VA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function HA(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?VA(Object(n),!0).forEach(function(r){SQ(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):VA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function SQ(e,t,n){return(t=OQ(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function OQ(e){var t=CQ(e,"string");return typeof t=="symbol"?t:t+""}function CQ(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function kQ(e){return e.dataKey}function PQ(e,t){return O.isValidElement(e)?O.cloneElement(e,t):typeof e=="function"?O.createElement(e,t):O.createElement(e9,t)}var YA=[],DQ={allowEscapeViewBox:{x:!1,y:!1},animationDuration:400,animationEasing:"ease",axisId:0,contentStyle:{},cursor:!0,filterNull:!0,isAnimationActive:!ho.isSsr,itemSorter:"name",itemStyle:{},labelStyle:{},offset:10,reverseDirection:{x:!1,y:!1},separator:" : ",trigger:"hover",useTranslate3d:!1,wrapperStyle:{}};function St(e){var t=tn(e,DQ),{active:n,allowEscapeViewBox:r,animationDuration:i,animationEasing:o,content:a,filterNull:s,isAnimationActive:l,offset:c,payloadUniqBy:u,position:d,reverseDirection:f,useTranslate3d:p,wrapperStyle:m,cursor:g,shared:v,trigger:x,defaultIndex:_,portal:w,axisId:y}=t,E=wt(),S=typeof _=="number"?String(_):_;k.useEffect(()=>{E(ZG({shared:v,trigger:x,axisId:y,active:n,defaultIndex:S}))},[E,v,x,y,n,S]);var P=dp(),D=sk(),T=KG(v),{activeIndex:I,isActive:A}=pe(re=>XX(re,T,x,S)),C=pe(re=>GX(re,T,x,S)),j=pe(re=>jA(re,T,x,S)),N=pe(re=>qX(re,T,x,S)),M=C,R=rQ(),B=n??A,[V,z]=qO([M,B]),W=T==="axis"?j:void 0;EQ(T,x,N,W,I,B);var Q=w??R;if(Q==null)return null;var X=M??YA;B||(X=YA),s&&X.length&&(X=OO(M.filter(re=>re.value!=null&&(re.hide!==!0||t.includeHidden)),u,kQ));var ie=X.length>0,J=O.createElement(s9,{allowEscapeViewBox:r,animationDuration:i,animationEasing:o,isAnimationActive:l,active:B,coordinate:N,hasPayload:ie,offset:c,position:d,reverseDirection:f,useTranslate3d:p,viewBox:P,wrapperStyle:m,lastBoundingBox:V,innerRef:z,hasPortalFromProps:!!w},PQ(a,HA(HA({},t),{},{payload:X,label:W,active:B,coordinate:N,accessibilityLayer:D})));return O.createElement(O.Fragment,null,fi.createPortal(J,Q),B&&O.createElement(nQ,{cursor:g,tooltipEventType:T,coordinate:N,payload:M,index:I}))}var k0={},P0={},D0={},UA;function AQ(){return UA||(UA=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n,r,{signal:i,edges:o}={}){let a,s=null;const l=o!=null&&o.includes("leading"),c=o==null||o.includes("trailing"),u=()=>{s!==null&&(n.apply(a,s),a=void 0,s=null)},d=()=>{c&&u(),g()};let f=null;const p=()=>{f!=null&&clearTimeout(f),f=setTimeout(()=>{f=null,d()},r)},m=()=>{f!==null&&(clearTimeout(f),f=null)},g=()=>{m(),a=void 0,s=null},v=()=>{u()},x=function(..._){if(i?.aborted)return;a=this,s=_;const w=f==null;p(),l&&w&&u()};return x.schedule=p,x.cancel=g,x.flush=v,i?.addEventListener("abort",g,{once:!0}),x}e.debounce=t})(D0)),D0}var KA;function TQ(){return KA||(KA=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=AQ();function n(r,i=0,o={}){typeof o!="object"&&(o={});const{leading:a=!1,trailing:s=!0,maxWait:l}=o,c=Array(2);a&&(c[0]="leading"),s&&(c[1]="trailing");let u,d=null;const f=t.debounce(function(...g){u=r.apply(this,g),d=null},i,{edges:c}),p=function(...g){return l!=null&&(d===null&&(d=Date.now()),Date.now()-d>=l)?(u=r.apply(this,g),d=Date.now(),f.cancel(),f.schedule(),u):(f.apply(this,g),u)},m=()=>(f.flush(),u);return p.cancel=f.cancel,p.flush=m,p}e.debounce=n})(P0)),P0}var qA;function NQ(){return qA||(qA=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=TQ();function n(r,i=0,o={}){const{leading:a=!0,trailing:s=!0}=o;return t.debounce(r,i,{leading:a,maxWait:i,trailing:s})}e.throttle=n})(k0)),k0}var A0,GA;function jQ(){return GA||(GA=1,A0=NQ().throttle),A0}var MQ=jQ();const IQ=Ki(MQ);var FQ=process.env.NODE_ENV!=="production",bu=function(t,n){for(var r=arguments.length,i=new Array(r>2?r-2:0),o=2;o<r;o++)i[o-2]=arguments[o];if(FQ&&typeof console<"u"&&console.warn&&(n===void 0&&console.warn("LogUtils requires an error message argument"),!t))if(n===void 0)console.warn("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var a=0;console.warn(n.replace(/%s/g,()=>i[a++]))}};function XA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function T0(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?XA(Object(n),!0).forEach(function(r){LQ(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):XA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function LQ(e,t,n){return(t=RQ(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function RQ(e){var t=$Q(e,"string");return typeof t=="symbol"?t:t+""}function $Q(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Ot=k.forwardRef((e,t)=>{var{aspect:n,initialDimension:r={width:-1,height:-1},width:i="100%",height:o="100%",minWidth:a=0,minHeight:s,maxHeight:l,children:c,debounce:u=0,id:d,className:f,onResize:p,style:m={}}=e,g=k.useRef(null),v=k.useRef();v.current=p,k.useImperativeHandle(t,()=>g.current);var[x,_]=k.useState({containerWidth:r.width,containerHeight:r.height}),w=k.useCallback((E,S)=>{_(P=>{var D=Math.round(E),T=Math.round(S);return P.containerWidth===D&&P.containerHeight===T?P:{containerWidth:D,containerHeight:T}})},[]);k.useEffect(()=>{var E=T=>{var I,{width:A,height:C}=T[0].contentRect;w(A,C),(I=v.current)===null||I===void 0||I.call(v,A,C)};u>0&&(E=IQ(E,u,{trailing:!0,leading:!1}));var S=new ResizeObserver(E),{width:P,height:D}=g.current.getBoundingClientRect();return w(P,D),S.observe(g.current),()=>{S.disconnect()}},[w,u]);var y=k.useMemo(()=>{var{containerWidth:E,containerHeight:S}=x;if(E<0||S<0)return null;bu(La(i)||La(o),`The width(%s) and height(%s) are both fixed numbers,
|
|
220
|
+
A`).concat(o,",").concat(o,",0,0,").concat(+(u<0),",").concat(y.x,",").concat(y.y,"Z")}else _+="L".concat(t,",").concat(n,"Z");return _},tU={cx:0,cy:0,innerRadius:0,outerRadius:0,startAngle:0,endAngle:0,cornerRadius:0,forceCornerRadius:!1,cornerIsExternal:!1},Dk=e=>{var t=tn(e,tU),{cx:n,cy:r,innerRadius:i,outerRadius:o,cornerRadius:a,forceCornerRadius:s,cornerIsExternal:l,startAngle:c,endAngle:u,className:d}=t;if(o<i||c===u)return null;var f=ue("recharts-sector",d),p=o-i,m=Mn(a,p,0,!0),g;return m>0&&Math.abs(c-u)<360?g=eU({cx:n,cy:r,innerRadius:i,outerRadius:o,cornerRadius:Math.min(m,p/2),forceCornerRadius:s,cornerIsExternal:l,startAngle:c,endAngle:u}):g=Pk({cx:n,cy:r,innerRadius:i,outerRadius:o,startAngle:c,endAngle:u}),O.createElement("path",Gy({},dt(t,!0),{className:f,d:g}))};function nU(e,t,n){var r,i,o,a;if(e==="horizontal")r=t.x,o=r,i=n.top,a=n.top+n.height;else if(e==="vertical")i=t.y,a=i,r=n.left,o=n.left+n.width;else if(t.cx!=null&&t.cy!=null)if(e==="centric"){var{cx:s,cy:l,innerRadius:c,outerRadius:u,angle:d}=t,f=Kt(s,l,c,d),p=Kt(s,l,u,d);r=f.x,i=f.y,o=p.x,a=p.y}else return kk(t);return[{x:r,y:i},{x:o,y:a}]}var Xy={},Qy={},Zy={},Ak;function rU(){return Ak||(Ak=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=$O();function n(r){return t.isSymbol(r)?NaN:Number(r)}e.toNumber=n})(Zy)),Zy}var Tk;function iU(){return Tk||(Tk=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=rU();function n(r){return r?(r=t.toNumber(r),r===1/0||r===-1/0?(r<0?-1:1)*Number.MAX_VALUE:r===r?r:0):r===0?r:0}e.toFinite=n})(Qy)),Qy}var Nk;function oU(){return Nk||(Nk=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=HO(),n=iU();function r(i,o,a){a&&typeof a!="number"&&t.isIterateeCall(i,o,a)&&(o=a=void 0),i=n.toFinite(i),o===void 0?(o=i,i=0):o=n.toFinite(o),a=a===void 0?i<o?1:-1:n.toFinite(a);const s=Math.max(Math.ceil((o-i)/(a||1)),0),l=new Array(s);for(let c=0;c<s;c++)l[c]=i,i+=a;return l}e.range=r})(Xy)),Xy}var Jy,jk;function aU(){return jk||(jk=1,Jy=oU().range),Jy}var sU=aU();const Mk=Ki(sU);function ea(e,t){return e==null||t==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function lU(e,t){return e==null||t==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function eb(e){let t,n,r;e.length!==2?(t=ea,n=(s,l)=>ea(e(s),l),r=(s,l)=>e(s)-l):(t=e===ea||e===lU?e:cU,n=e,r=e);function i(s,l,c=0,u=s.length){if(c<u){if(t(l,l)!==0)return u;do{const d=c+u>>>1;n(s[d],l)<0?c=d+1:u=d}while(c<u)}return c}function o(s,l,c=0,u=s.length){if(c<u){if(t(l,l)!==0)return u;do{const d=c+u>>>1;n(s[d],l)<=0?c=d+1:u=d}while(c<u)}return c}function a(s,l,c=0,u=s.length){const d=i(s,l,c,u-1);return d>c&&r(s[d-1],l)>-r(s[d],l)?d-1:d}return{left:i,center:a,right:o}}function cU(){return 0}function Ik(e){return e===null?NaN:+e}function*uU(e,t){for(let n of e)n!=null&&(n=+n)>=n&&(yield n)}const qc=eb(ea).right;eb(Ik).center;class Fk extends Map{constructor(t,n=pU){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:n}}),t!=null)for(const[r,i]of t)this.set(r,i)}get(t){return super.get(Lk(this,t))}has(t){return super.has(Lk(this,t))}set(t,n){return super.set(dU(this,t),n)}delete(t){return super.delete(fU(this,t))}}function Lk({_intern:e,_key:t},n){const r=t(n);return e.has(r)?e.get(r):n}function dU({_intern:e,_key:t},n){const r=t(n);return e.has(r)?e.get(r):(e.set(r,n),n)}function fU({_intern:e,_key:t},n){const r=t(n);return e.has(r)&&(n=e.get(r),e.delete(r)),n}function pU(e){return e!==null&&typeof e=="object"?e.valueOf():e}function hU(e=ea){if(e===ea)return Rk;if(typeof e!="function")throw new TypeError("compare is not a function");return(t,n)=>{const r=e(t,n);return r||r===0?r:(e(n,n)===0)-(e(t,t)===0)}}function Rk(e,t){return(e==null||!(e>=e))-(t==null||!(t>=t))||(e<t?-1:e>t?1:0)}const mU=Math.sqrt(50),gU=Math.sqrt(10),vU=Math.sqrt(2);function yp(e,t,n){const r=(t-e)/Math.max(0,n),i=Math.floor(Math.log10(r)),o=r/Math.pow(10,i),a=o>=mU?10:o>=gU?5:o>=vU?2:1;let s,l,c;return i<0?(c=Math.pow(10,-i)/a,s=Math.round(e*c),l=Math.round(t*c),s/c<e&&++s,l/c>t&&--l,c=-c):(c=Math.pow(10,i)*a,s=Math.round(e/c),l=Math.round(t/c),s*c<e&&++s,l*c>t&&--l),l<s&&.5<=n&&n<2?yp(e,t,n*2):[s,l,c]}function tb(e,t,n){if(t=+t,e=+e,n=+n,!(n>0))return[];if(e===t)return[e];const r=t<e,[i,o,a]=r?yp(t,e,n):yp(e,t,n);if(!(o>=i))return[];const s=o-i+1,l=new Array(s);if(r)if(a<0)for(let c=0;c<s;++c)l[c]=(o-c)/-a;else for(let c=0;c<s;++c)l[c]=(o-c)*a;else if(a<0)for(let c=0;c<s;++c)l[c]=(i+c)/-a;else for(let c=0;c<s;++c)l[c]=(i+c)*a;return l}function nb(e,t,n){return t=+t,e=+e,n=+n,yp(e,t,n)[2]}function rb(e,t,n){t=+t,e=+e,n=+n;const r=t<e,i=r?nb(t,e,n):nb(e,t,n);return(r?-1:1)*(i<0?1/-i:i)}function $k(e,t){let n;for(const r of e)r!=null&&(n<r||n===void 0&&r>=r)&&(n=r);return n}function Bk(e,t){let n;for(const r of e)r!=null&&(n>r||n===void 0&&r>=r)&&(n=r);return n}function Wk(e,t,n=0,r=1/0,i){if(t=Math.floor(t),n=Math.floor(Math.max(0,n)),r=Math.floor(Math.min(e.length-1,r)),!(n<=t&&t<=r))return e;for(i=i===void 0?Rk:hU(i);r>n;){if(r-n>600){const l=r-n+1,c=t-n+1,u=Math.log(l),d=.5*Math.exp(2*u/3),f=.5*Math.sqrt(u*d*(l-d)/l)*(c-l/2<0?-1:1),p=Math.max(n,Math.floor(t-c*d/l+f)),m=Math.min(r,Math.floor(t+(l-c)*d/l+f));Wk(e,t,p,m,i)}const o=e[t];let a=n,s=r;for(Gc(e,n,t),i(e[r],o)>0&&Gc(e,n,r);a<s;){for(Gc(e,a,s),++a,--s;i(e[a],o)<0;)++a;for(;i(e[s],o)>0;)--s}i(e[n],o)===0?Gc(e,n,s):(++s,Gc(e,s,r)),s<=t&&(n=s+1),t<=s&&(r=s-1)}return e}function Gc(e,t,n){const r=e[t];e[t]=e[n],e[n]=r}function yU(e,t,n){if(e=Float64Array.from(uU(e)),!(!(r=e.length)||isNaN(t=+t))){if(t<=0||r<2)return Bk(e);if(t>=1)return $k(e);var r,i=(r-1)*t,o=Math.floor(i),a=$k(Wk(e,o).subarray(0,o+1)),s=Bk(e.subarray(o+1));return a+(s-a)*(i-o)}}function bU(e,t,n=Ik){if(!(!(r=e.length)||isNaN(t=+t))){if(t<=0||r<2)return+n(e[0],0,e);if(t>=1)return+n(e[r-1],r-1,e);var r,i=(r-1)*t,o=Math.floor(i),a=+n(e[o],o,e),s=+n(e[o+1],o+1,e);return a+(s-a)*(i-o)}}function xU(e,t,n){e=+e,t=+t,n=(i=arguments.length)<2?(t=e,e=0,1):i<3?1:+n;for(var r=-1,i=Math.max(0,Math.ceil((t-e)/n))|0,o=new Array(i);++r<i;)o[r]=e+r*n;return o}function Ur(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e);break}return this}function mo(e,t){switch(arguments.length){case 0:break;case 1:{typeof e=="function"?this.interpolator(e):this.range(e);break}default:{this.domain(e),typeof t=="function"?this.interpolator(t):this.range(t);break}}return this}const ib=Symbol("implicit");function ob(){var e=new Fk,t=[],n=[],r=ib;function i(o){let a=e.get(o);if(a===void 0){if(r!==ib)return r;e.set(o,a=t.push(o)-1)}return n[a%n.length]}return i.domain=function(o){if(!arguments.length)return t.slice();t=[],e=new Fk;for(const a of o)e.has(a)||e.set(a,t.push(a)-1);return i},i.range=function(o){return arguments.length?(n=Array.from(o),i):n.slice()},i.unknown=function(o){return arguments.length?(r=o,i):r},i.copy=function(){return ob(t,n).unknown(r)},Ur.apply(i,arguments),i}function ab(){var e=ob().unknown(void 0),t=e.domain,n=e.range,r=0,i=1,o,a,s=!1,l=0,c=0,u=.5;delete e.unknown;function d(){var f=t().length,p=i<r,m=p?i:r,g=p?r:i;o=(g-m)/Math.max(1,f-l+c*2),s&&(o=Math.floor(o)),m+=(g-m-o*(f-l))*u,a=o*(1-l),s&&(m=Math.round(m),a=Math.round(a));var v=xU(f).map(function(x){return m+o*x});return n(p?v.reverse():v)}return e.domain=function(f){return arguments.length?(t(f),d()):t()},e.range=function(f){return arguments.length?([r,i]=f,r=+r,i=+i,d()):[r,i]},e.rangeRound=function(f){return[r,i]=f,r=+r,i=+i,s=!0,d()},e.bandwidth=function(){return a},e.step=function(){return o},e.round=function(f){return arguments.length?(s=!!f,d()):s},e.padding=function(f){return arguments.length?(l=Math.min(1,c=+f),d()):l},e.paddingInner=function(f){return arguments.length?(l=Math.min(1,f),d()):l},e.paddingOuter=function(f){return arguments.length?(c=+f,d()):c},e.align=function(f){return arguments.length?(u=Math.max(0,Math.min(1,f)),d()):u},e.copy=function(){return ab(t(),[r,i]).round(s).paddingInner(l).paddingOuter(c).align(u)},Ur.apply(d(),arguments)}function zk(e){var t=e.copy;return e.padding=e.paddingOuter,delete e.paddingInner,delete e.paddingOuter,e.copy=function(){return zk(t())},e}function wU(){return zk(ab.apply(null,arguments).paddingInner(1))}function sb(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function Vk(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}function Xc(){}var Qc=.7,bp=1/Qc,ll="\\s*([+-]?\\d+)\\s*",Zc="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",Ni="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",_U=/^#([0-9a-f]{3,8})$/,EU=new RegExp(`^rgb\\(${ll},${ll},${ll}\\)$`),SU=new RegExp(`^rgb\\(${Ni},${Ni},${Ni}\\)$`),OU=new RegExp(`^rgba\\(${ll},${ll},${ll},${Zc}\\)$`),CU=new RegExp(`^rgba\\(${Ni},${Ni},${Ni},${Zc}\\)$`),kU=new RegExp(`^hsl\\(${Zc},${Ni},${Ni}\\)$`),PU=new RegExp(`^hsla\\(${Zc},${Ni},${Ni},${Zc}\\)$`),Hk={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};sb(Xc,Jc,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:Yk,formatHex:Yk,formatHex8:DU,formatHsl:AU,formatRgb:Uk,toString:Uk});function Yk(){return this.rgb().formatHex()}function DU(){return this.rgb().formatHex8()}function AU(){return Qk(this).formatHsl()}function Uk(){return this.rgb().formatRgb()}function Jc(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=_U.exec(e))?(n=t[1].length,t=parseInt(t[1],16),n===6?Kk(t):n===3?new or(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):n===8?xp(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):n===4?xp(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|t&240,((t&15)<<4|t&15)/255):null):(t=EU.exec(e))?new or(t[1],t[2],t[3],1):(t=SU.exec(e))?new or(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=OU.exec(e))?xp(t[1],t[2],t[3],t[4]):(t=CU.exec(e))?xp(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=kU.exec(e))?Xk(t[1],t[2]/100,t[3]/100,1):(t=PU.exec(e))?Xk(t[1],t[2]/100,t[3]/100,t[4]):Hk.hasOwnProperty(e)?Kk(Hk[e]):e==="transparent"?new or(NaN,NaN,NaN,0):null}function Kk(e){return new or(e>>16&255,e>>8&255,e&255,1)}function xp(e,t,n,r){return r<=0&&(e=t=n=NaN),new or(e,t,n,r)}function TU(e){return e instanceof Xc||(e=Jc(e)),e?(e=e.rgb(),new or(e.r,e.g,e.b,e.opacity)):new or}function lb(e,t,n,r){return arguments.length===1?TU(e):new or(e,t,n,r??1)}function or(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}sb(or,lb,Vk(Xc,{brighter(e){return e=e==null?bp:Math.pow(bp,e),new or(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?Qc:Math.pow(Qc,e),new or(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new or(Ua(this.r),Ua(this.g),Ua(this.b),wp(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:qk,formatHex:qk,formatHex8:NU,formatRgb:Gk,toString:Gk}));function qk(){return`#${Ka(this.r)}${Ka(this.g)}${Ka(this.b)}`}function NU(){return`#${Ka(this.r)}${Ka(this.g)}${Ka(this.b)}${Ka((isNaN(this.opacity)?1:this.opacity)*255)}`}function Gk(){const e=wp(this.opacity);return`${e===1?"rgb(":"rgba("}${Ua(this.r)}, ${Ua(this.g)}, ${Ua(this.b)}${e===1?")":`, ${e})`}`}function wp(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function Ua(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function Ka(e){return e=Ua(e),(e<16?"0":"")+e.toString(16)}function Xk(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new oi(e,t,n,r)}function Qk(e){if(e instanceof oi)return new oi(e.h,e.s,e.l,e.opacity);if(e instanceof Xc||(e=Jc(e)),!e)return new oi;if(e instanceof oi)return e;e=e.rgb();var t=e.r/255,n=e.g/255,r=e.b/255,i=Math.min(t,n,r),o=Math.max(t,n,r),a=NaN,s=o-i,l=(o+i)/2;return s?(t===o?a=(n-r)/s+(n<r)*6:n===o?a=(r-t)/s+2:a=(t-n)/s+4,s/=l<.5?o+i:2-o-i,a*=60):s=l>0&&l<1?0:a,new oi(a,s,l,e.opacity)}function jU(e,t,n,r){return arguments.length===1?Qk(e):new oi(e,t,n,r??1)}function oi(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}sb(oi,jU,Vk(Xc,{brighter(e){return e=e==null?bp:Math.pow(bp,e),new oi(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?Qc:Math.pow(Qc,e),new oi(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+(this.h<0)*360,t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*t,i=2*n-r;return new or(cb(e>=240?e-240:e+120,i,r),cb(e,i,r),cb(e<120?e+240:e-120,i,r),this.opacity)},clamp(){return new oi(Zk(this.h),_p(this.s),_p(this.l),wp(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=wp(this.opacity);return`${e===1?"hsl(":"hsla("}${Zk(this.h)}, ${_p(this.s)*100}%, ${_p(this.l)*100}%${e===1?")":`, ${e})`}`}}));function Zk(e){return e=(e||0)%360,e<0?e+360:e}function _p(e){return Math.max(0,Math.min(1,e||0))}function cb(e,t,n){return(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)*255}const ub=e=>()=>e;function MU(e,t){return function(n){return e+n*t}}function IU(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(r){return Math.pow(e+r*t,n)}}function FU(e){return(e=+e)==1?Jk:function(t,n){return n-t?IU(t,n,e):ub(isNaN(t)?n:t)}}function Jk(e,t){var n=t-e;return n?MU(e,n):ub(isNaN(e)?t:e)}const eP=(function e(t){var n=FU(t);function r(i,o){var a=n((i=lb(i)).r,(o=lb(o)).r),s=n(i.g,o.g),l=n(i.b,o.b),c=Jk(i.opacity,o.opacity);return function(u){return i.r=a(u),i.g=s(u),i.b=l(u),i.opacity=c(u),i+""}}return r.gamma=e,r})(1);function LU(e,t){t||(t=[]);var n=e?Math.min(t.length,e.length):0,r=t.slice(),i;return function(o){for(i=0;i<n;++i)r[i]=e[i]*(1-o)+t[i]*o;return r}}function RU(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function $U(e,t){var n=t?t.length:0,r=e?Math.min(n,e.length):0,i=new Array(r),o=new Array(n),a;for(a=0;a<r;++a)i[a]=cl(e[a],t[a]);for(;a<n;++a)o[a]=t[a];return function(s){for(a=0;a<r;++a)o[a]=i[a](s);return o}}function BU(e,t){var n=new Date;return e=+e,t=+t,function(r){return n.setTime(e*(1-r)+t*r),n}}function Ep(e,t){return e=+e,t=+t,function(n){return e*(1-n)+t*n}}function WU(e,t){var n={},r={},i;(e===null||typeof e!="object")&&(e={}),(t===null||typeof t!="object")&&(t={});for(i in t)i in e?n[i]=cl(e[i],t[i]):r[i]=t[i];return function(o){for(i in n)r[i]=n[i](o);return r}}var db=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,fb=new RegExp(db.source,"g");function zU(e){return function(){return e}}function VU(e){return function(t){return e(t)+""}}function HU(e,t){var n=db.lastIndex=fb.lastIndex=0,r,i,o,a=-1,s=[],l=[];for(e=e+"",t=t+"";(r=db.exec(e))&&(i=fb.exec(t));)(o=i.index)>n&&(o=t.slice(n,o),s[a]?s[a]+=o:s[++a]=o),(r=r[0])===(i=i[0])?s[a]?s[a]+=i:s[++a]=i:(s[++a]=null,l.push({i:a,x:Ep(r,i)})),n=fb.lastIndex;return n<t.length&&(o=t.slice(n),s[a]?s[a]+=o:s[++a]=o),s.length<2?l[0]?VU(l[0].x):zU(t):(t=l.length,function(c){for(var u=0,d;u<t;++u)s[(d=l[u]).i]=d.x(c);return s.join("")})}function cl(e,t){var n=typeof t,r;return t==null||n==="boolean"?ub(t):(n==="number"?Ep:n==="string"?(r=Jc(t))?(t=r,eP):HU:t instanceof Jc?eP:t instanceof Date?BU:RU(t)?LU:Array.isArray(t)?$U:typeof t.valueOf!="function"&&typeof t.toString!="function"||isNaN(t)?WU:Ep)(e,t)}function pb(e,t){return e=+e,t=+t,function(n){return Math.round(e*(1-n)+t*n)}}function YU(e,t){t===void 0&&(t=e,e=cl);for(var n=0,r=t.length-1,i=t[0],o=new Array(r<0?0:r);n<r;)o[n]=e(i,i=t[++n]);return function(a){var s=Math.max(0,Math.min(r-1,Math.floor(a*=r)));return o[s](a-s)}}function UU(e){return function(){return e}}function Sp(e){return+e}var tP=[0,1];function Kn(e){return e}function hb(e,t){return(t-=e=+e)?function(n){return(n-e)/t}:UU(isNaN(t)?NaN:.5)}function KU(e,t){var n;return e>t&&(n=e,e=t,t=n),function(r){return Math.max(e,Math.min(t,r))}}function qU(e,t,n){var r=e[0],i=e[1],o=t[0],a=t[1];return i<r?(r=hb(i,r),o=n(a,o)):(r=hb(r,i),o=n(o,a)),function(s){return o(r(s))}}function GU(e,t,n){var r=Math.min(e.length,t.length)-1,i=new Array(r),o=new Array(r),a=-1;for(e[r]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++a<r;)i[a]=hb(e[a],e[a+1]),o[a]=n(t[a],t[a+1]);return function(s){var l=qc(e,s,1,r)-1;return o[l](i[l](s))}}function eu(e,t){return t.domain(e.domain()).range(e.range()).interpolate(e.interpolate()).clamp(e.clamp()).unknown(e.unknown())}function Op(){var e=tP,t=tP,n=cl,r,i,o,a=Kn,s,l,c;function u(){var f=Math.min(e.length,t.length);return a!==Kn&&(a=KU(e[0],e[f-1])),s=f>2?GU:qU,l=c=null,d}function d(f){return f==null||isNaN(f=+f)?o:(l||(l=s(e.map(r),t,n)))(r(a(f)))}return d.invert=function(f){return a(i((c||(c=s(t,e.map(r),Ep)))(f)))},d.domain=function(f){return arguments.length?(e=Array.from(f,Sp),u()):e.slice()},d.range=function(f){return arguments.length?(t=Array.from(f),u()):t.slice()},d.rangeRound=function(f){return t=Array.from(f),n=pb,u()},d.clamp=function(f){return arguments.length?(a=f?!0:Kn,u()):a!==Kn},d.interpolate=function(f){return arguments.length?(n=f,u()):n},d.unknown=function(f){return arguments.length?(o=f,d):o},function(f,p){return r=f,i=p,u()}}function mb(){return Op()(Kn,Kn)}function XU(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function Cp(e,t){if((n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"))<0)return null;var n,r=e.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+e.slice(n+1)]}function ul(e){return e=Cp(Math.abs(e)),e?e[1]:NaN}function QU(e,t){return function(n,r){for(var i=n.length,o=[],a=0,s=e[0],l=0;i>0&&s>0&&(l+s+1>r&&(s=Math.max(1,r-l)),o.push(n.substring(i-=s,i+s)),!((l+=s+1)>r));)s=e[a=(a+1)%e.length];return o.reverse().join(t)}}function ZU(e){return function(t){return t.replace(/[0-9]/g,function(n){return e[+n]})}}var JU=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function tu(e){if(!(t=JU.exec(e)))throw new Error("invalid format: "+e);var t;return new gb({fill:t[1],align:t[2],sign:t[3],symbol:t[4],zero:t[5],width:t[6],comma:t[7],precision:t[8]&&t[8].slice(1),trim:t[9],type:t[10]})}tu.prototype=gb.prototype;function gb(e){this.fill=e.fill===void 0?" ":e.fill+"",this.align=e.align===void 0?">":e.align+"",this.sign=e.sign===void 0?"-":e.sign+"",this.symbol=e.symbol===void 0?"":e.symbol+"",this.zero=!!e.zero,this.width=e.width===void 0?void 0:+e.width,this.comma=!!e.comma,this.precision=e.precision===void 0?void 0:+e.precision,this.trim=!!e.trim,this.type=e.type===void 0?"":e.type+""}gb.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(this.width===void 0?"":Math.max(1,this.width|0))+(this.comma?",":"")+(this.precision===void 0?"":"."+Math.max(0,this.precision|0))+(this.trim?"~":"")+this.type};function eK(e){e:for(var t=e.length,n=1,r=-1,i;n<t;++n)switch(e[n]){case".":r=i=n;break;case"0":r===0&&(r=n),i=n;break;default:if(!+e[n])break e;r>0&&(r=0);break}return r>0?e.slice(0,r)+e.slice(i+1):e}var nP;function tK(e,t){var n=Cp(e,t);if(!n)return e+"";var r=n[0],i=n[1],o=i-(nP=Math.max(-8,Math.min(8,Math.floor(i/3)))*3)+1,a=r.length;return o===a?r:o>a?r+new Array(o-a+1).join("0"):o>0?r.slice(0,o)+"."+r.slice(o):"0."+new Array(1-o).join("0")+Cp(e,Math.max(0,t+o-1))[0]}function rP(e,t){var n=Cp(e,t);if(!n)return e+"";var r=n[0],i=n[1];return i<0?"0."+new Array(-i).join("0")+r:r.length>i+1?r.slice(0,i+1)+"."+r.slice(i+1):r+new Array(i-r.length+2).join("0")}const iP={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:XU,e:(e,t)=>e.toExponential(t),f:(e,t)=>e.toFixed(t),g:(e,t)=>e.toPrecision(t),o:e=>Math.round(e).toString(8),p:(e,t)=>rP(e*100,t),r:rP,s:tK,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function oP(e){return e}var aP=Array.prototype.map,sP=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function nK(e){var t=e.grouping===void 0||e.thousands===void 0?oP:QU(aP.call(e.grouping,Number),e.thousands+""),n=e.currency===void 0?"":e.currency[0]+"",r=e.currency===void 0?"":e.currency[1]+"",i=e.decimal===void 0?".":e.decimal+"",o=e.numerals===void 0?oP:ZU(aP.call(e.numerals,String)),a=e.percent===void 0?"%":e.percent+"",s=e.minus===void 0?"−":e.minus+"",l=e.nan===void 0?"NaN":e.nan+"";function c(d){d=tu(d);var f=d.fill,p=d.align,m=d.sign,g=d.symbol,v=d.zero,x=d.width,_=d.comma,w=d.precision,y=d.trim,E=d.type;E==="n"?(_=!0,E="g"):iP[E]||(w===void 0&&(w=12),y=!0,E="g"),(v||f==="0"&&p==="=")&&(v=!0,f="0",p="=");var S=g==="$"?n:g==="#"&&/[boxX]/.test(E)?"0"+E.toLowerCase():"",P=g==="$"?r:/[%p]/.test(E)?a:"",D=iP[E],T=/[defgprs%]/.test(E);w=w===void 0?6:/[gprs]/.test(E)?Math.max(1,Math.min(21,w)):Math.max(0,Math.min(20,w));function I(A){var C=S,j=P,N,M,R;if(E==="c")j=D(A)+j,A="";else{A=+A;var B=A<0||1/A<0;if(A=isNaN(A)?l:D(Math.abs(A),w),y&&(A=eK(A)),B&&+A==0&&m!=="+"&&(B=!1),C=(B?m==="("?m:s:m==="-"||m==="("?"":m)+C,j=(E==="s"?sP[8+nP/3]:"")+j+(B&&m==="("?")":""),T){for(N=-1,M=A.length;++N<M;)if(R=A.charCodeAt(N),48>R||R>57){j=(R===46?i+A.slice(N+1):A.slice(N))+j,A=A.slice(0,N);break}}}_&&!v&&(A=t(A,1/0));var V=C.length+A.length+j.length,z=V<x?new Array(x-V+1).join(f):"";switch(_&&v&&(A=t(z+A,z.length?x-j.length:1/0),z=""),p){case"<":A=C+A+j+z;break;case"=":A=C+z+A+j;break;case"^":A=z.slice(0,V=z.length>>1)+C+A+j+z.slice(V);break;default:A=z+C+A+j;break}return o(A)}return I.toString=function(){return d+""},I}function u(d,f){var p=c((d=tu(d),d.type="f",d)),m=Math.max(-8,Math.min(8,Math.floor(ul(f)/3)))*3,g=Math.pow(10,-m),v=sP[8+m/3];return function(x){return p(g*x)+v}}return{format:c,formatPrefix:u}}var kp,vb,lP;rK({thousands:",",grouping:[3],currency:["$",""]});function rK(e){return kp=nK(e),vb=kp.format,lP=kp.formatPrefix,kp}function iK(e){return Math.max(0,-ul(Math.abs(e)))}function oK(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(ul(t)/3)))*3-ul(Math.abs(e)))}function aK(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,ul(t)-ul(e))+1}function cP(e,t,n,r){var i=rb(e,t,n),o;switch(r=tu(r??",f"),r.type){case"s":{var a=Math.max(Math.abs(e),Math.abs(t));return r.precision==null&&!isNaN(o=oK(i,a))&&(r.precision=o),lP(r,a)}case"":case"e":case"g":case"p":case"r":{r.precision==null&&!isNaN(o=aK(i,Math.max(Math.abs(e),Math.abs(t))))&&(r.precision=o-(r.type==="e"));break}case"f":case"%":{r.precision==null&&!isNaN(o=iK(i))&&(r.precision=o-(r.type==="%")*2);break}}return vb(r)}function ta(e){var t=e.domain;return e.ticks=function(n){var r=t();return tb(r[0],r[r.length-1],n??10)},e.tickFormat=function(n,r){var i=t();return cP(i[0],i[i.length-1],n??10,r)},e.nice=function(n){n==null&&(n=10);var r=t(),i=0,o=r.length-1,a=r[i],s=r[o],l,c,u=10;for(s<a&&(c=a,a=s,s=c,c=i,i=o,o=c);u-- >0;){if(c=nb(a,s,n),c===l)return r[i]=a,r[o]=s,t(r);if(c>0)a=Math.floor(a/c)*c,s=Math.ceil(s/c)*c;else if(c<0)a=Math.ceil(a*c)/c,s=Math.floor(s*c)/c;else break;l=c}return e},e}function uP(){var e=mb();return e.copy=function(){return eu(e,uP())},Ur.apply(e,arguments),ta(e)}function dP(e){var t;function n(r){return r==null||isNaN(r=+r)?t:r}return n.invert=n,n.domain=n.range=function(r){return arguments.length?(e=Array.from(r,Sp),n):e.slice()},n.unknown=function(r){return arguments.length?(t=r,n):t},n.copy=function(){return dP(e).unknown(t)},e=arguments.length?Array.from(e,Sp):[0,1],ta(n)}function fP(e,t){e=e.slice();var n=0,r=e.length-1,i=e[n],o=e[r],a;return o<i&&(a=n,n=r,r=a,a=i,i=o,o=a),e[n]=t.floor(i),e[r]=t.ceil(o),e}function pP(e){return Math.log(e)}function hP(e){return Math.exp(e)}function sK(e){return-Math.log(-e)}function lK(e){return-Math.exp(-e)}function cK(e){return isFinite(e)?+("1e"+e):e<0?0:e}function uK(e){return e===10?cK:e===Math.E?Math.exp:t=>Math.pow(e,t)}function dK(e){return e===Math.E?Math.log:e===10&&Math.log10||e===2&&Math.log2||(e=Math.log(e),t=>Math.log(t)/e)}function mP(e){return(t,n)=>-e(-t,n)}function yb(e){const t=e(pP,hP),n=t.domain;let r=10,i,o;function a(){return i=dK(r),o=uK(r),n()[0]<0?(i=mP(i),o=mP(o),e(sK,lK)):e(pP,hP),t}return t.base=function(s){return arguments.length?(r=+s,a()):r},t.domain=function(s){return arguments.length?(n(s),a()):n()},t.ticks=s=>{const l=n();let c=l[0],u=l[l.length-1];const d=u<c;d&&([c,u]=[u,c]);let f=i(c),p=i(u),m,g;const v=s==null?10:+s;let x=[];if(!(r%1)&&p-f<v){if(f=Math.floor(f),p=Math.ceil(p),c>0){for(;f<=p;++f)for(m=1;m<r;++m)if(g=f<0?m/o(-f):m*o(f),!(g<c)){if(g>u)break;x.push(g)}}else for(;f<=p;++f)for(m=r-1;m>=1;--m)if(g=f>0?m/o(-f):m*o(f),!(g<c)){if(g>u)break;x.push(g)}x.length*2<v&&(x=tb(c,u,v))}else x=tb(f,p,Math.min(p-f,v)).map(o);return d?x.reverse():x},t.tickFormat=(s,l)=>{if(s==null&&(s=10),l==null&&(l=r===10?"s":","),typeof l!="function"&&(!(r%1)&&(l=tu(l)).precision==null&&(l.trim=!0),l=vb(l)),s===1/0)return l;const c=Math.max(1,r*s/t.ticks().length);return u=>{let d=u/o(Math.round(i(u)));return d*r<r-.5&&(d*=r),d<=c?l(u):""}},t.nice=()=>n(fP(n(),{floor:s=>o(Math.floor(i(s))),ceil:s=>o(Math.ceil(i(s)))})),t}function gP(){const e=yb(Op()).domain([1,10]);return e.copy=()=>eu(e,gP()).base(e.base()),Ur.apply(e,arguments),e}function vP(e){return function(t){return Math.sign(t)*Math.log1p(Math.abs(t/e))}}function yP(e){return function(t){return Math.sign(t)*Math.expm1(Math.abs(t))*e}}function bb(e){var t=1,n=e(vP(t),yP(t));return n.constant=function(r){return arguments.length?e(vP(t=+r),yP(t)):t},ta(n)}function bP(){var e=bb(Op());return e.copy=function(){return eu(e,bP()).constant(e.constant())},Ur.apply(e,arguments)}function xP(e){return function(t){return t<0?-Math.pow(-t,e):Math.pow(t,e)}}function fK(e){return e<0?-Math.sqrt(-e):Math.sqrt(e)}function pK(e){return e<0?-e*e:e*e}function xb(e){var t=e(Kn,Kn),n=1;function r(){return n===1?e(Kn,Kn):n===.5?e(fK,pK):e(xP(n),xP(1/n))}return t.exponent=function(i){return arguments.length?(n=+i,r()):n},ta(t)}function wb(){var e=xb(Op());return e.copy=function(){return eu(e,wb()).exponent(e.exponent())},Ur.apply(e,arguments),e}function hK(){return wb.apply(null,arguments).exponent(.5)}function wP(e){return Math.sign(e)*e*e}function mK(e){return Math.sign(e)*Math.sqrt(Math.abs(e))}function _P(){var e=mb(),t=[0,1],n=!1,r;function i(o){var a=mK(e(o));return isNaN(a)?r:n?Math.round(a):a}return i.invert=function(o){return e.invert(wP(o))},i.domain=function(o){return arguments.length?(e.domain(o),i):e.domain()},i.range=function(o){return arguments.length?(e.range((t=Array.from(o,Sp)).map(wP)),i):t.slice()},i.rangeRound=function(o){return i.range(o).round(!0)},i.round=function(o){return arguments.length?(n=!!o,i):n},i.clamp=function(o){return arguments.length?(e.clamp(o),i):e.clamp()},i.unknown=function(o){return arguments.length?(r=o,i):r},i.copy=function(){return _P(e.domain(),t).round(n).clamp(e.clamp()).unknown(r)},Ur.apply(i,arguments),ta(i)}function EP(){var e=[],t=[],n=[],r;function i(){var a=0,s=Math.max(1,t.length);for(n=new Array(s-1);++a<s;)n[a-1]=bU(e,a/s);return o}function o(a){return a==null||isNaN(a=+a)?r:t[qc(n,a)]}return o.invertExtent=function(a){var s=t.indexOf(a);return s<0?[NaN,NaN]:[s>0?n[s-1]:e[0],s<n.length?n[s]:e[e.length-1]]},o.domain=function(a){if(!arguments.length)return e.slice();e=[];for(let s of a)s!=null&&!isNaN(s=+s)&&e.push(s);return e.sort(ea),i()},o.range=function(a){return arguments.length?(t=Array.from(a),i()):t.slice()},o.unknown=function(a){return arguments.length?(r=a,o):r},o.quantiles=function(){return n.slice()},o.copy=function(){return EP().domain(e).range(t).unknown(r)},Ur.apply(o,arguments)}function SP(){var e=0,t=1,n=1,r=[.5],i=[0,1],o;function a(l){return l!=null&&l<=l?i[qc(r,l,0,n)]:o}function s(){var l=-1;for(r=new Array(n);++l<n;)r[l]=((l+1)*t-(l-n)*e)/(n+1);return a}return a.domain=function(l){return arguments.length?([e,t]=l,e=+e,t=+t,s()):[e,t]},a.range=function(l){return arguments.length?(n=(i=Array.from(l)).length-1,s()):i.slice()},a.invertExtent=function(l){var c=i.indexOf(l);return c<0?[NaN,NaN]:c<1?[e,r[0]]:c>=n?[r[n-1],t]:[r[c-1],r[c]]},a.unknown=function(l){return arguments.length&&(o=l),a},a.thresholds=function(){return r.slice()},a.copy=function(){return SP().domain([e,t]).range(i).unknown(o)},Ur.apply(ta(a),arguments)}function OP(){var e=[.5],t=[0,1],n,r=1;function i(o){return o!=null&&o<=o?t[qc(e,o,0,r)]:n}return i.domain=function(o){return arguments.length?(e=Array.from(o),r=Math.min(e.length,t.length-1),i):e.slice()},i.range=function(o){return arguments.length?(t=Array.from(o),r=Math.min(e.length,t.length-1),i):t.slice()},i.invertExtent=function(o){var a=t.indexOf(o);return[e[a-1],e[a]]},i.unknown=function(o){return arguments.length?(n=o,i):n},i.copy=function(){return OP().domain(e).range(t).unknown(n)},Ur.apply(i,arguments)}const _b=new Date,Eb=new Date;function nn(e,t,n,r){function i(o){return e(o=arguments.length===0?new Date:new Date(+o)),o}return i.floor=o=>(e(o=new Date(+o)),o),i.ceil=o=>(e(o=new Date(o-1)),t(o,1),e(o),o),i.round=o=>{const a=i(o),s=i.ceil(o);return o-a<s-o?a:s},i.offset=(o,a)=>(t(o=new Date(+o),a==null?1:Math.floor(a)),o),i.range=(o,a,s)=>{const l=[];if(o=i.ceil(o),s=s==null?1:Math.floor(s),!(o<a)||!(s>0))return l;let c;do l.push(c=new Date(+o)),t(o,s),e(o);while(c<o&&o<a);return l},i.filter=o=>nn(a=>{if(a>=a)for(;e(a),!o(a);)a.setTime(a-1)},(a,s)=>{if(a>=a)if(s<0)for(;++s<=0;)for(;t(a,-1),!o(a););else for(;--s>=0;)for(;t(a,1),!o(a););}),n&&(i.count=(o,a)=>(_b.setTime(+o),Eb.setTime(+a),e(_b),e(Eb),Math.floor(n(_b,Eb))),i.every=o=>(o=Math.floor(o),!isFinite(o)||!(o>0)?null:o>1?i.filter(r?a=>r(a)%o===0:a=>i.count(0,a)%o===0):i)),i}const Pp=nn(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);Pp.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?nn(t=>{t.setTime(Math.floor(t/e)*e)},(t,n)=>{t.setTime(+t+n*e)},(t,n)=>(n-t)/e):Pp),Pp.range;const go=1e3,Kr=go*60,vo=Kr*60,yo=vo*24,Sb=yo*7,CP=yo*30,Ob=yo*365,qa=nn(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*go)},(e,t)=>(t-e)/go,e=>e.getUTCSeconds());qa.range;const Cb=nn(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*go)},(e,t)=>{e.setTime(+e+t*Kr)},(e,t)=>(t-e)/Kr,e=>e.getMinutes());Cb.range;const kb=nn(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*Kr)},(e,t)=>(t-e)/Kr,e=>e.getUTCMinutes());kb.range;const Pb=nn(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*go-e.getMinutes()*Kr)},(e,t)=>{e.setTime(+e+t*vo)},(e,t)=>(t-e)/vo,e=>e.getHours());Pb.range;const Db=nn(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*vo)},(e,t)=>(t-e)/vo,e=>e.getUTCHours());Db.range;const nu=nn(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*Kr)/yo,e=>e.getDate()-1);nu.range;const Dp=nn(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/yo,e=>e.getUTCDate()-1);Dp.range;const kP=nn(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/yo,e=>Math.floor(e/yo));kP.range;function Ga(e){return nn(t=>{t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)},(t,n)=>{t.setDate(t.getDate()+n*7)},(t,n)=>(n-t-(n.getTimezoneOffset()-t.getTimezoneOffset())*Kr)/Sb)}const Ap=Ga(0),Tp=Ga(1),gK=Ga(2),vK=Ga(3),dl=Ga(4),yK=Ga(5),bK=Ga(6);Ap.range,Tp.range,gK.range,vK.range,dl.range,yK.range,bK.range;function Xa(e){return nn(t=>{t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)},(t,n)=>{t.setUTCDate(t.getUTCDate()+n*7)},(t,n)=>(n-t)/Sb)}const Np=Xa(0),jp=Xa(1),xK=Xa(2),wK=Xa(3),fl=Xa(4),_K=Xa(5),EK=Xa(6);Np.range,jp.range,xK.range,wK.range,fl.range,_K.range,EK.range;const Ab=nn(e=>{e.setDate(1),e.setHours(0,0,0,0)},(e,t)=>{e.setMonth(e.getMonth()+t)},(e,t)=>t.getMonth()-e.getMonth()+(t.getFullYear()-e.getFullYear())*12,e=>e.getMonth());Ab.range;const Tb=nn(e=>{e.setUTCDate(1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCMonth(e.getUTCMonth()+t)},(e,t)=>t.getUTCMonth()-e.getUTCMonth()+(t.getUTCFullYear()-e.getUTCFullYear())*12,e=>e.getUTCMonth());Tb.range;const bo=nn(e=>{e.setMonth(0,1),e.setHours(0,0,0,0)},(e,t)=>{e.setFullYear(e.getFullYear()+t)},(e,t)=>t.getFullYear()-e.getFullYear(),e=>e.getFullYear());bo.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:nn(t=>{t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)},(t,n)=>{t.setFullYear(t.getFullYear()+n*e)}),bo.range;const xo=nn(e=>{e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCFullYear(e.getUTCFullYear()+t)},(e,t)=>t.getUTCFullYear()-e.getUTCFullYear(),e=>e.getUTCFullYear());xo.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:nn(t=>{t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},(t,n)=>{t.setUTCFullYear(t.getUTCFullYear()+n*e)}),xo.range;function PP(e,t,n,r,i,o){const a=[[qa,1,go],[qa,5,5*go],[qa,15,15*go],[qa,30,30*go],[o,1,Kr],[o,5,5*Kr],[o,15,15*Kr],[o,30,30*Kr],[i,1,vo],[i,3,3*vo],[i,6,6*vo],[i,12,12*vo],[r,1,yo],[r,2,2*yo],[n,1,Sb],[t,1,CP],[t,3,3*CP],[e,1,Ob]];function s(c,u,d){const f=u<c;f&&([c,u]=[u,c]);const p=d&&typeof d.range=="function"?d:l(c,u,d),m=p?p.range(c,+u+1):[];return f?m.reverse():m}function l(c,u,d){const f=Math.abs(u-c)/d,p=eb(([,,v])=>v).right(a,f);if(p===a.length)return e.every(rb(c/Ob,u/Ob,d));if(p===0)return Pp.every(Math.max(rb(c,u,d),1));const[m,g]=a[f/a[p-1][2]<a[p][2]/f?p-1:p];return m.every(g)}return[s,l]}const[SK,OK]=PP(xo,Tb,Np,kP,Db,kb),[CK,kK]=PP(bo,Ab,Ap,nu,Pb,Cb);function Nb(e){if(0<=e.y&&e.y<100){var t=new Date(-1,e.m,e.d,e.H,e.M,e.S,e.L);return t.setFullYear(e.y),t}return new Date(e.y,e.m,e.d,e.H,e.M,e.S,e.L)}function jb(e){if(0<=e.y&&e.y<100){var t=new Date(Date.UTC(-1,e.m,e.d,e.H,e.M,e.S,e.L));return t.setUTCFullYear(e.y),t}return new Date(Date.UTC(e.y,e.m,e.d,e.H,e.M,e.S,e.L))}function ru(e,t,n){return{y:e,m:t,d:n,H:0,M:0,S:0,L:0}}function PK(e){var t=e.dateTime,n=e.date,r=e.time,i=e.periods,o=e.days,a=e.shortDays,s=e.months,l=e.shortMonths,c=iu(i),u=ou(i),d=iu(o),f=ou(o),p=iu(a),m=ou(a),g=iu(s),v=ou(s),x=iu(l),_=ou(l),w={a:B,A:V,b:z,B:W,c:null,d:MP,e:MP,f:QK,g:sq,G:cq,H:qK,I:GK,j:XK,L:IP,m:ZK,M:JK,p:Q,q:G,Q:WP,s:zP,S:eq,u:tq,U:nq,V:rq,w:iq,W:oq,x:null,X:null,y:aq,Y:lq,Z:uq,"%":BP},y={a:ie,A:J,b:re,B:se,c:null,d:LP,e:LP,f:hq,g:Sq,G:Cq,H:dq,I:fq,j:pq,L:RP,m:mq,M:gq,p:ce,q:de,Q:WP,s:zP,S:vq,u:yq,U:bq,V:xq,w:wq,W:_q,x:null,X:null,y:Eq,Y:Oq,Z:kq,"%":BP},E={a:I,A,b:C,B:j,c:N,d:NP,e:NP,f:HK,g:TP,G:AP,H:jP,I:jP,j:BK,L:VK,m:$K,M:WK,p:T,q:RK,Q:UK,s:KK,S:zK,u:jK,U:MK,V:IK,w:NK,W:FK,x:M,X:R,y:TP,Y:AP,Z:LK,"%":YK};w.x=S(n,w),w.X=S(r,w),w.c=S(t,w),y.x=S(n,y),y.X=S(r,y),y.c=S(t,y);function S(K,U){return function(Z){var F=[],ge=-1,oe=0,ye=K.length,_e,Ie,tt;for(Z instanceof Date||(Z=new Date(+Z));++ge<ye;)K.charCodeAt(ge)===37&&(F.push(K.slice(oe,ge)),(Ie=DP[_e=K.charAt(++ge)])!=null?_e=K.charAt(++ge):Ie=_e==="e"?" ":"0",(tt=U[_e])&&(_e=tt(Z,Ie)),F.push(_e),oe=ge+1);return F.push(K.slice(oe,ge)),F.join("")}}function P(K,U){return function(Z){var F=ru(1900,void 0,1),ge=D(F,K,Z+="",0),oe,ye;if(ge!=Z.length)return null;if("Q"in F)return new Date(F.Q);if("s"in F)return new Date(F.s*1e3+("L"in F?F.L:0));if(U&&!("Z"in F)&&(F.Z=0),"p"in F&&(F.H=F.H%12+F.p*12),F.m===void 0&&(F.m="q"in F?F.q:0),"V"in F){if(F.V<1||F.V>53)return null;"w"in F||(F.w=1),"Z"in F?(oe=jb(ru(F.y,0,1)),ye=oe.getUTCDay(),oe=ye>4||ye===0?jp.ceil(oe):jp(oe),oe=Dp.offset(oe,(F.V-1)*7),F.y=oe.getUTCFullYear(),F.m=oe.getUTCMonth(),F.d=oe.getUTCDate()+(F.w+6)%7):(oe=Nb(ru(F.y,0,1)),ye=oe.getDay(),oe=ye>4||ye===0?Tp.ceil(oe):Tp(oe),oe=nu.offset(oe,(F.V-1)*7),F.y=oe.getFullYear(),F.m=oe.getMonth(),F.d=oe.getDate()+(F.w+6)%7)}else("W"in F||"U"in F)&&("w"in F||(F.w="u"in F?F.u%7:"W"in F?1:0),ye="Z"in F?jb(ru(F.y,0,1)).getUTCDay():Nb(ru(F.y,0,1)).getDay(),F.m=0,F.d="W"in F?(F.w+6)%7+F.W*7-(ye+5)%7:F.w+F.U*7-(ye+6)%7);return"Z"in F?(F.H+=F.Z/100|0,F.M+=F.Z%100,jb(F)):Nb(F)}}function D(K,U,Z,F){for(var ge=0,oe=U.length,ye=Z.length,_e,Ie;ge<oe;){if(F>=ye)return-1;if(_e=U.charCodeAt(ge++),_e===37){if(_e=U.charAt(ge++),Ie=E[_e in DP?U.charAt(ge++):_e],!Ie||(F=Ie(K,Z,F))<0)return-1}else if(_e!=Z.charCodeAt(F++))return-1}return F}function T(K,U,Z){var F=c.exec(U.slice(Z));return F?(K.p=u.get(F[0].toLowerCase()),Z+F[0].length):-1}function I(K,U,Z){var F=p.exec(U.slice(Z));return F?(K.w=m.get(F[0].toLowerCase()),Z+F[0].length):-1}function A(K,U,Z){var F=d.exec(U.slice(Z));return F?(K.w=f.get(F[0].toLowerCase()),Z+F[0].length):-1}function C(K,U,Z){var F=x.exec(U.slice(Z));return F?(K.m=_.get(F[0].toLowerCase()),Z+F[0].length):-1}function j(K,U,Z){var F=g.exec(U.slice(Z));return F?(K.m=v.get(F[0].toLowerCase()),Z+F[0].length):-1}function N(K,U,Z){return D(K,t,U,Z)}function M(K,U,Z){return D(K,n,U,Z)}function R(K,U,Z){return D(K,r,U,Z)}function B(K){return a[K.getDay()]}function V(K){return o[K.getDay()]}function z(K){return l[K.getMonth()]}function W(K){return s[K.getMonth()]}function Q(K){return i[+(K.getHours()>=12)]}function G(K){return 1+~~(K.getMonth()/3)}function ie(K){return a[K.getUTCDay()]}function J(K){return o[K.getUTCDay()]}function re(K){return l[K.getUTCMonth()]}function se(K){return s[K.getUTCMonth()]}function ce(K){return i[+(K.getUTCHours()>=12)]}function de(K){return 1+~~(K.getUTCMonth()/3)}return{format:function(K){var U=S(K+="",w);return U.toString=function(){return K},U},parse:function(K){var U=P(K+="",!1);return U.toString=function(){return K},U},utcFormat:function(K){var U=S(K+="",y);return U.toString=function(){return K},U},utcParse:function(K){var U=P(K+="",!0);return U.toString=function(){return K},U}}}var DP={"-":"",_:" ",0:"0"},dn=/^\s*\d+/,DK=/^%/,AK=/[\\^$*+?|[\]().{}]/g;function Re(e,t,n){var r=e<0?"-":"",i=(r?-e:e)+"",o=i.length;return r+(o<n?new Array(n-o+1).join(t)+i:i)}function TK(e){return e.replace(AK,"\\$&")}function iu(e){return new RegExp("^(?:"+e.map(TK).join("|")+")","i")}function ou(e){return new Map(e.map((t,n)=>[t.toLowerCase(),n]))}function NK(e,t,n){var r=dn.exec(t.slice(n,n+1));return r?(e.w=+r[0],n+r[0].length):-1}function jK(e,t,n){var r=dn.exec(t.slice(n,n+1));return r?(e.u=+r[0],n+r[0].length):-1}function MK(e,t,n){var r=dn.exec(t.slice(n,n+2));return r?(e.U=+r[0],n+r[0].length):-1}function IK(e,t,n){var r=dn.exec(t.slice(n,n+2));return r?(e.V=+r[0],n+r[0].length):-1}function FK(e,t,n){var r=dn.exec(t.slice(n,n+2));return r?(e.W=+r[0],n+r[0].length):-1}function AP(e,t,n){var r=dn.exec(t.slice(n,n+4));return r?(e.y=+r[0],n+r[0].length):-1}function TP(e,t,n){var r=dn.exec(t.slice(n,n+2));return r?(e.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function LK(e,t,n){var r=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(t.slice(n,n+6));return r?(e.Z=r[1]?0:-(r[2]+(r[3]||"00")),n+r[0].length):-1}function RK(e,t,n){var r=dn.exec(t.slice(n,n+1));return r?(e.q=r[0]*3-3,n+r[0].length):-1}function $K(e,t,n){var r=dn.exec(t.slice(n,n+2));return r?(e.m=r[0]-1,n+r[0].length):-1}function NP(e,t,n){var r=dn.exec(t.slice(n,n+2));return r?(e.d=+r[0],n+r[0].length):-1}function BK(e,t,n){var r=dn.exec(t.slice(n,n+3));return r?(e.m=0,e.d=+r[0],n+r[0].length):-1}function jP(e,t,n){var r=dn.exec(t.slice(n,n+2));return r?(e.H=+r[0],n+r[0].length):-1}function WK(e,t,n){var r=dn.exec(t.slice(n,n+2));return r?(e.M=+r[0],n+r[0].length):-1}function zK(e,t,n){var r=dn.exec(t.slice(n,n+2));return r?(e.S=+r[0],n+r[0].length):-1}function VK(e,t,n){var r=dn.exec(t.slice(n,n+3));return r?(e.L=+r[0],n+r[0].length):-1}function HK(e,t,n){var r=dn.exec(t.slice(n,n+6));return r?(e.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function YK(e,t,n){var r=DK.exec(t.slice(n,n+1));return r?n+r[0].length:-1}function UK(e,t,n){var r=dn.exec(t.slice(n));return r?(e.Q=+r[0],n+r[0].length):-1}function KK(e,t,n){var r=dn.exec(t.slice(n));return r?(e.s=+r[0],n+r[0].length):-1}function MP(e,t){return Re(e.getDate(),t,2)}function qK(e,t){return Re(e.getHours(),t,2)}function GK(e,t){return Re(e.getHours()%12||12,t,2)}function XK(e,t){return Re(1+nu.count(bo(e),e),t,3)}function IP(e,t){return Re(e.getMilliseconds(),t,3)}function QK(e,t){return IP(e,t)+"000"}function ZK(e,t){return Re(e.getMonth()+1,t,2)}function JK(e,t){return Re(e.getMinutes(),t,2)}function eq(e,t){return Re(e.getSeconds(),t,2)}function tq(e){var t=e.getDay();return t===0?7:t}function nq(e,t){return Re(Ap.count(bo(e)-1,e),t,2)}function FP(e){var t=e.getDay();return t>=4||t===0?dl(e):dl.ceil(e)}function rq(e,t){return e=FP(e),Re(dl.count(bo(e),e)+(bo(e).getDay()===4),t,2)}function iq(e){return e.getDay()}function oq(e,t){return Re(Tp.count(bo(e)-1,e),t,2)}function aq(e,t){return Re(e.getFullYear()%100,t,2)}function sq(e,t){return e=FP(e),Re(e.getFullYear()%100,t,2)}function lq(e,t){return Re(e.getFullYear()%1e4,t,4)}function cq(e,t){var n=e.getDay();return e=n>=4||n===0?dl(e):dl.ceil(e),Re(e.getFullYear()%1e4,t,4)}function uq(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+Re(t/60|0,"0",2)+Re(t%60,"0",2)}function LP(e,t){return Re(e.getUTCDate(),t,2)}function dq(e,t){return Re(e.getUTCHours(),t,2)}function fq(e,t){return Re(e.getUTCHours()%12||12,t,2)}function pq(e,t){return Re(1+Dp.count(xo(e),e),t,3)}function RP(e,t){return Re(e.getUTCMilliseconds(),t,3)}function hq(e,t){return RP(e,t)+"000"}function mq(e,t){return Re(e.getUTCMonth()+1,t,2)}function gq(e,t){return Re(e.getUTCMinutes(),t,2)}function vq(e,t){return Re(e.getUTCSeconds(),t,2)}function yq(e){var t=e.getUTCDay();return t===0?7:t}function bq(e,t){return Re(Np.count(xo(e)-1,e),t,2)}function $P(e){var t=e.getUTCDay();return t>=4||t===0?fl(e):fl.ceil(e)}function xq(e,t){return e=$P(e),Re(fl.count(xo(e),e)+(xo(e).getUTCDay()===4),t,2)}function wq(e){return e.getUTCDay()}function _q(e,t){return Re(jp.count(xo(e)-1,e),t,2)}function Eq(e,t){return Re(e.getUTCFullYear()%100,t,2)}function Sq(e,t){return e=$P(e),Re(e.getUTCFullYear()%100,t,2)}function Oq(e,t){return Re(e.getUTCFullYear()%1e4,t,4)}function Cq(e,t){var n=e.getUTCDay();return e=n>=4||n===0?fl(e):fl.ceil(e),Re(e.getUTCFullYear()%1e4,t,4)}function kq(){return"+0000"}function BP(){return"%"}function WP(e){return+e}function zP(e){return Math.floor(+e/1e3)}var pl,VP,HP;Pq({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});function Pq(e){return pl=PK(e),VP=pl.format,pl.parse,HP=pl.utcFormat,pl.utcParse,pl}function Dq(e){return new Date(e)}function Aq(e){return e instanceof Date?+e:+new Date(+e)}function Mb(e,t,n,r,i,o,a,s,l,c){var u=mb(),d=u.invert,f=u.domain,p=c(".%L"),m=c(":%S"),g=c("%I:%M"),v=c("%I %p"),x=c("%a %d"),_=c("%b %d"),w=c("%B"),y=c("%Y");function E(S){return(l(S)<S?p:s(S)<S?m:a(S)<S?g:o(S)<S?v:r(S)<S?i(S)<S?x:_:n(S)<S?w:y)(S)}return u.invert=function(S){return new Date(d(S))},u.domain=function(S){return arguments.length?f(Array.from(S,Aq)):f().map(Dq)},u.ticks=function(S){var P=f();return e(P[0],P[P.length-1],S??10)},u.tickFormat=function(S,P){return P==null?E:c(P)},u.nice=function(S){var P=f();return(!S||typeof S.range!="function")&&(S=t(P[0],P[P.length-1],S??10)),S?f(fP(P,S)):u},u.copy=function(){return eu(u,Mb(e,t,n,r,i,o,a,s,l,c))},u}function Tq(){return Ur.apply(Mb(CK,kK,bo,Ab,Ap,nu,Pb,Cb,qa,VP).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}function Nq(){return Ur.apply(Mb(SK,OK,xo,Tb,Np,Dp,Db,kb,qa,HP).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)]),arguments)}function Mp(){var e=0,t=1,n,r,i,o,a=Kn,s=!1,l;function c(d){return d==null||isNaN(d=+d)?l:a(i===0?.5:(d=(o(d)-n)*i,s?Math.max(0,Math.min(1,d)):d))}c.domain=function(d){return arguments.length?([e,t]=d,n=o(e=+e),r=o(t=+t),i=n===r?0:1/(r-n),c):[e,t]},c.clamp=function(d){return arguments.length?(s=!!d,c):s},c.interpolator=function(d){return arguments.length?(a=d,c):a};function u(d){return function(f){var p,m;return arguments.length?([p,m]=f,a=d(p,m),c):[a(0),a(1)]}}return c.range=u(cl),c.rangeRound=u(pb),c.unknown=function(d){return arguments.length?(l=d,c):l},function(d){return o=d,n=d(e),r=d(t),i=n===r?0:1/(r-n),c}}function na(e,t){return t.domain(e.domain()).interpolator(e.interpolator()).clamp(e.clamp()).unknown(e.unknown())}function YP(){var e=ta(Mp()(Kn));return e.copy=function(){return na(e,YP())},mo.apply(e,arguments)}function UP(){var e=yb(Mp()).domain([1,10]);return e.copy=function(){return na(e,UP()).base(e.base())},mo.apply(e,arguments)}function KP(){var e=bb(Mp());return e.copy=function(){return na(e,KP()).constant(e.constant())},mo.apply(e,arguments)}function Ib(){var e=xb(Mp());return e.copy=function(){return na(e,Ib()).exponent(e.exponent())},mo.apply(e,arguments)}function jq(){return Ib.apply(null,arguments).exponent(.5)}function qP(){var e=[],t=Kn;function n(r){if(r!=null&&!isNaN(r=+r))return t((qc(e,r,1)-1)/(e.length-1))}return n.domain=function(r){if(!arguments.length)return e.slice();e=[];for(let i of r)i!=null&&!isNaN(i=+i)&&e.push(i);return e.sort(ea),n},n.interpolator=function(r){return arguments.length?(t=r,n):t},n.range=function(){return e.map((r,i)=>t(i/(e.length-1)))},n.quantiles=function(r){return Array.from({length:r+1},(i,o)=>yU(e,o/r))},n.copy=function(){return qP(t).domain(e)},mo.apply(n,arguments)}function Ip(){var e=0,t=.5,n=1,r=1,i,o,a,s,l,c=Kn,u,d=!1,f;function p(g){return isNaN(g=+g)?f:(g=.5+((g=+u(g))-o)*(r*g<r*o?s:l),c(d?Math.max(0,Math.min(1,g)):g))}p.domain=function(g){return arguments.length?([e,t,n]=g,i=u(e=+e),o=u(t=+t),a=u(n=+n),s=i===o?0:.5/(o-i),l=o===a?0:.5/(a-o),r=o<i?-1:1,p):[e,t,n]},p.clamp=function(g){return arguments.length?(d=!!g,p):d},p.interpolator=function(g){return arguments.length?(c=g,p):c};function m(g){return function(v){var x,_,w;return arguments.length?([x,_,w]=v,c=YU(g,[x,_,w]),p):[c(0),c(.5),c(1)]}}return p.range=m(cl),p.rangeRound=m(pb),p.unknown=function(g){return arguments.length?(f=g,p):f},function(g){return u=g,i=g(e),o=g(t),a=g(n),s=i===o?0:.5/(o-i),l=o===a?0:.5/(a-o),r=o<i?-1:1,p}}function GP(){var e=ta(Ip()(Kn));return e.copy=function(){return na(e,GP())},mo.apply(e,arguments)}function XP(){var e=yb(Ip()).domain([.1,1,10]);return e.copy=function(){return na(e,XP()).base(e.base())},mo.apply(e,arguments)}function QP(){var e=bb(Ip());return e.copy=function(){return na(e,QP()).constant(e.constant())},mo.apply(e,arguments)}function Fb(){var e=xb(Ip());return e.copy=function(){return na(e,Fb()).exponent(e.exponent())},mo.apply(e,arguments)}function Mq(){return Fb.apply(null,arguments).exponent(.5)}const au=Object.freeze(Object.defineProperty({__proto__:null,scaleBand:ab,scaleDiverging:GP,scaleDivergingLog:XP,scaleDivergingPow:Fb,scaleDivergingSqrt:Mq,scaleDivergingSymlog:QP,scaleIdentity:dP,scaleImplicit:ib,scaleLinear:uP,scaleLog:gP,scaleOrdinal:ob,scalePoint:wU,scalePow:wb,scaleQuantile:EP,scaleQuantize:SP,scaleRadial:_P,scaleSequential:YP,scaleSequentialLog:UP,scaleSequentialPow:Ib,scaleSequentialQuantile:qP,scaleSequentialSqrt:jq,scaleSequentialSymlog:KP,scaleSqrt:hK,scaleSymlog:bP,scaleThreshold:OP,scaleTime:Tq,scaleUtc:Nq,tickFormat:cP},Symbol.toStringTag,{value:"Module"}));var ra=e=>e.chartData,Lb=H([ra],e=>{var t=e.chartData!=null?e.chartData.length-1:0;return{chartData:e.chartData,computedData:e.computedData,dataEndIndex:t,dataStartIndex:0}}),su=(e,t,n,r)=>r?Lb(e):ra(e);function hl(e){if(Array.isArray(e)&&e.length===2){var[t,n]=e;if(Sn(t)&&Sn(n))return!0}return!1}function ZP(e,t,n){return n?e:[Math.min(e[0],t[0]),Math.max(e[1],t[1])]}function Iq(e,t){if(t&&typeof e!="function"&&Array.isArray(e)&&e.length===2){var[n,r]=e,i,o;if(Sn(n))i=n;else if(typeof n=="function")return;if(Sn(r))o=r;else if(typeof r=="function")return;var a=[i,o];if(hl(a))return a}}function Fq(e,t,n){if(!(!n&&t==null)){if(typeof e=="function"&&t!=null)try{var r=e(t,n);if(hl(r))return ZP(r,t,n)}catch{}if(Array.isArray(e)&&e.length===2){var[i,o]=e,a,s;if(i==="auto")t!=null&&(a=Math.min(...t));else if(me(i))a=i;else if(typeof i=="function")try{t!=null&&(a=i(t?.[0]))}catch{}else if(typeof i=="string"&&YC.test(i)){var l=YC.exec(i);if(l==null||t==null)a=void 0;else{var c=+l[1];a=t[0]-c}}else a=t?.[0];if(o==="auto")t!=null&&(s=Math.max(...t));else if(me(o))s=o;else if(typeof o=="function")try{t!=null&&(s=o(t?.[1]))}catch{}else if(typeof o=="string"&&UC.test(o)){var u=UC.exec(o);if(u==null||t==null)s=void 0;else{var d=+u[1];s=t[1]+d}}else s=t?.[1];var f=[a,s];if(hl(f))return t==null?f:ZP(f,t,n)}}}var ml=1e9,Lq={precision:20,rounding:4,toExpNeg:-7,toExpPos:21,LN10:"2.302585092994045684017991454684364207601101488628772976033327900967572609677352480235997205089598298341967784042286"},Bb,_t=!0,qr="[DecimalError] ",Qa=qr+"Invalid argument: ",Rb=qr+"Exponent out of range: ",gl=Math.floor,Za=Math.pow,Rq=/^(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,Er,fn=1e7,yt=7,JP=9007199254740991,Fp=gl(JP/yt),he={};he.absoluteValue=he.abs=function(){var e=new this.constructor(this);return e.s&&(e.s=1),e},he.comparedTo=he.cmp=function(e){var t,n,r,i,o=this;if(e=new o.constructor(e),o.s!==e.s)return o.s||-e.s;if(o.e!==e.e)return o.e>e.e^o.s<0?1:-1;for(r=o.d.length,i=e.d.length,t=0,n=r<i?r:i;t<n;++t)if(o.d[t]!==e.d[t])return o.d[t]>e.d[t]^o.s<0?1:-1;return r===i?0:r>i^o.s<0?1:-1},he.decimalPlaces=he.dp=function(){var e=this,t=e.d.length-1,n=(t-e.e)*yt;if(t=e.d[t],t)for(;t%10==0;t/=10)n--;return n<0?0:n},he.dividedBy=he.div=function(e){return wo(this,new this.constructor(e))},he.dividedToIntegerBy=he.idiv=function(e){var t=this,n=t.constructor;return at(wo(t,new n(e),0,1),n.precision)},he.equals=he.eq=function(e){return!this.cmp(e)},he.exponent=function(){return qt(this)},he.greaterThan=he.gt=function(e){return this.cmp(e)>0},he.greaterThanOrEqualTo=he.gte=function(e){return this.cmp(e)>=0},he.isInteger=he.isint=function(){return this.e>this.d.length-2},he.isNegative=he.isneg=function(){return this.s<0},he.isPositive=he.ispos=function(){return this.s>0},he.isZero=function(){return this.s===0},he.lessThan=he.lt=function(e){return this.cmp(e)<0},he.lessThanOrEqualTo=he.lte=function(e){return this.cmp(e)<1},he.logarithm=he.log=function(e){var t,n=this,r=n.constructor,i=r.precision,o=i+5;if(e===void 0)e=new r(10);else if(e=new r(e),e.s<1||e.eq(Er))throw Error(qr+"NaN");if(n.s<1)throw Error(qr+(n.s?"NaN":"-Infinity"));return n.eq(Er)?new r(0):(_t=!1,t=wo(lu(n,o),lu(e,o),o),_t=!0,at(t,i))},he.minus=he.sub=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?rD(t,e):eD(t,(e.s=-e.s,e))},he.modulo=he.mod=function(e){var t,n=this,r=n.constructor,i=r.precision;if(e=new r(e),!e.s)throw Error(qr+"NaN");return n.s?(_t=!1,t=wo(n,e,0,1).times(e),_t=!0,n.minus(t)):at(new r(n),i)},he.naturalExponential=he.exp=function(){return tD(this)},he.naturalLogarithm=he.ln=function(){return lu(this)},he.negated=he.neg=function(){var e=new this.constructor(this);return e.s=-e.s||0,e},he.plus=he.add=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?eD(t,e):rD(t,(e.s=-e.s,e))},he.precision=he.sd=function(e){var t,n,r,i=this;if(e!==void 0&&e!==!!e&&e!==1&&e!==0)throw Error(Qa+e);if(t=qt(i)+1,r=i.d.length-1,n=r*yt+1,r=i.d[r],r){for(;r%10==0;r/=10)n--;for(r=i.d[0];r>=10;r/=10)n++}return e&&t>n?t:n},he.squareRoot=he.sqrt=function(){var e,t,n,r,i,o,a,s=this,l=s.constructor;if(s.s<1){if(!s.s)return new l(0);throw Error(qr+"NaN")}for(e=qt(s),_t=!1,i=Math.sqrt(+s),i==0||i==1/0?(t=Mi(s.d),(t.length+e)%2==0&&(t+="0"),i=Math.sqrt(t),e=gl((e+1)/2)-(e<0||e%2),i==1/0?t="5e"+e:(t=i.toExponential(),t=t.slice(0,t.indexOf("e")+1)+e),r=new l(t)):r=new l(i.toString()),n=l.precision,i=a=n+3;;)if(o=r,r=o.plus(wo(s,o,a+2)).times(.5),Mi(o.d).slice(0,a)===(t=Mi(r.d)).slice(0,a)){if(t=t.slice(a-3,a+1),i==a&&t=="4999"){if(at(o,n+1,0),o.times(o).eq(s)){r=o;break}}else if(t!="9999")break;a+=4}return _t=!0,at(r,n)},he.times=he.mul=function(e){var t,n,r,i,o,a,s,l,c,u=this,d=u.constructor,f=u.d,p=(e=new d(e)).d;if(!u.s||!e.s)return new d(0);for(e.s*=u.s,n=u.e+e.e,l=f.length,c=p.length,l<c&&(o=f,f=p,p=o,a=l,l=c,c=a),o=[],a=l+c,r=a;r--;)o.push(0);for(r=c;--r>=0;){for(t=0,i=l+r;i>r;)s=o[i]+p[r]*f[i-r-1]+t,o[i--]=s%fn|0,t=s/fn|0;o[i]=(o[i]+t)%fn|0}for(;!o[--a];)o.pop();return t?++n:o.shift(),e.d=o,e.e=n,_t?at(e,d.precision):e},he.toDecimalPlaces=he.todp=function(e,t){var n=this,r=n.constructor;return n=new r(n),e===void 0?n:(ji(e,0,ml),t===void 0?t=r.rounding:ji(t,0,8),at(n,e+qt(n)+1,t))},he.toExponential=function(e,t){var n,r=this,i=r.constructor;return e===void 0?n=Ja(r,!0):(ji(e,0,ml),t===void 0?t=i.rounding:ji(t,0,8),r=at(new i(r),e+1,t),n=Ja(r,!0,e+1)),n},he.toFixed=function(e,t){var n,r,i=this,o=i.constructor;return e===void 0?Ja(i):(ji(e,0,ml),t===void 0?t=o.rounding:ji(t,0,8),r=at(new o(i),e+qt(i)+1,t),n=Ja(r.abs(),!1,e+qt(r)+1),i.isneg()&&!i.isZero()?"-"+n:n)},he.toInteger=he.toint=function(){var e=this,t=e.constructor;return at(new t(e),qt(e)+1,t.rounding)},he.toNumber=function(){return+this},he.toPower=he.pow=function(e){var t,n,r,i,o,a,s=this,l=s.constructor,c=12,u=+(e=new l(e));if(!e.s)return new l(Er);if(s=new l(s),!s.s){if(e.s<1)throw Error(qr+"Infinity");return s}if(s.eq(Er))return s;if(r=l.precision,e.eq(Er))return at(s,r);if(t=e.e,n=e.d.length-1,a=t>=n,o=s.s,a){if((n=u<0?-u:u)<=JP){for(i=new l(Er),t=Math.ceil(r/yt+4),_t=!1;n%2&&(i=i.times(s),iD(i.d,t)),n=gl(n/2),n!==0;)s=s.times(s),iD(s.d,t);return _t=!0,e.s<0?new l(Er).div(i):at(i,r)}}else if(o<0)throw Error(qr+"NaN");return o=o<0&&e.d[Math.max(t,n)]&1?-1:1,s.s=1,_t=!1,i=e.times(lu(s,r+c)),_t=!0,i=tD(i),i.s=o,i},he.toPrecision=function(e,t){var n,r,i=this,o=i.constructor;return e===void 0?(n=qt(i),r=Ja(i,n<=o.toExpNeg||n>=o.toExpPos)):(ji(e,1,ml),t===void 0?t=o.rounding:ji(t,0,8),i=at(new o(i),e,t),n=qt(i),r=Ja(i,e<=n||n<=o.toExpNeg,e)),r},he.toSignificantDigits=he.tosd=function(e,t){var n=this,r=n.constructor;return e===void 0?(e=r.precision,t=r.rounding):(ji(e,1,ml),t===void 0?t=r.rounding:ji(t,0,8)),at(new r(n),e,t)},he.toString=he.valueOf=he.val=he.toJSON=he[Symbol.for("nodejs.util.inspect.custom")]=function(){var e=this,t=qt(e),n=e.constructor;return Ja(e,t<=n.toExpNeg||t>=n.toExpPos)};function eD(e,t){var n,r,i,o,a,s,l,c,u=e.constructor,d=u.precision;if(!e.s||!t.s)return t.s||(t=new u(e)),_t?at(t,d):t;if(l=e.d,c=t.d,a=e.e,i=t.e,l=l.slice(),o=a-i,o){for(o<0?(r=l,o=-o,s=c.length):(r=c,i=a,s=l.length),a=Math.ceil(d/yt),s=a>s?a+1:s+1,o>s&&(o=s,r.length=1),r.reverse();o--;)r.push(0);r.reverse()}for(s=l.length,o=c.length,s-o<0&&(o=s,r=c,c=l,l=r),n=0;o;)n=(l[--o]=l[o]+c[o]+n)/fn|0,l[o]%=fn;for(n&&(l.unshift(n),++i),s=l.length;l[--s]==0;)l.pop();return t.d=l,t.e=i,_t?at(t,d):t}function ji(e,t,n){if(e!==~~e||e<t||e>n)throw Error(Qa+e)}function Mi(e){var t,n,r,i=e.length-1,o="",a=e[0];if(i>0){for(o+=a,t=1;t<i;t++)r=e[t]+"",n=yt-r.length,n&&(o+=ia(n)),o+=r;a=e[t],r=a+"",n=yt-r.length,n&&(o+=ia(n))}else if(a===0)return"0";for(;a%10===0;)a/=10;return o+a}var wo=(function(){function e(r,i){var o,a=0,s=r.length;for(r=r.slice();s--;)o=r[s]*i+a,r[s]=o%fn|0,a=o/fn|0;return a&&r.unshift(a),r}function t(r,i,o,a){var s,l;if(o!=a)l=o>a?1:-1;else for(s=l=0;s<o;s++)if(r[s]!=i[s]){l=r[s]>i[s]?1:-1;break}return l}function n(r,i,o){for(var a=0;o--;)r[o]-=a,a=r[o]<i[o]?1:0,r[o]=a*fn+r[o]-i[o];for(;!r[0]&&r.length>1;)r.shift()}return function(r,i,o,a){var s,l,c,u,d,f,p,m,g,v,x,_,w,y,E,S,P,D,T=r.constructor,I=r.s==i.s?1:-1,A=r.d,C=i.d;if(!r.s)return new T(r);if(!i.s)throw Error(qr+"Division by zero");for(l=r.e-i.e,P=C.length,E=A.length,p=new T(I),m=p.d=[],c=0;C[c]==(A[c]||0);)++c;if(C[c]>(A[c]||0)&&--l,o==null?_=o=T.precision:a?_=o+(qt(r)-qt(i))+1:_=o,_<0)return new T(0);if(_=_/yt+2|0,c=0,P==1)for(u=0,C=C[0],_++;(c<E||u)&&_--;c++)w=u*fn+(A[c]||0),m[c]=w/C|0,u=w%C|0;else{for(u=fn/(C[0]+1)|0,u>1&&(C=e(C,u),A=e(A,u),P=C.length,E=A.length),y=P,g=A.slice(0,P),v=g.length;v<P;)g[v++]=0;D=C.slice(),D.unshift(0),S=C[0],C[1]>=fn/2&&++S;do u=0,s=t(C,g,P,v),s<0?(x=g[0],P!=v&&(x=x*fn+(g[1]||0)),u=x/S|0,u>1?(u>=fn&&(u=fn-1),d=e(C,u),f=d.length,v=g.length,s=t(d,g,f,v),s==1&&(u--,n(d,P<f?D:C,f))):(u==0&&(s=u=1),d=C.slice()),f=d.length,f<v&&d.unshift(0),n(g,d,v),s==-1&&(v=g.length,s=t(C,g,P,v),s<1&&(u++,n(g,P<v?D:C,v))),v=g.length):s===0&&(u++,g=[0]),m[c++]=u,s&&g[0]?g[v++]=A[y]||0:(g=[A[y]],v=1);while((y++<E||g[0]!==void 0)&&_--)}return m[0]||m.shift(),p.e=l,at(p,a?o+qt(p)+1:o)}})();function tD(e,t){var n,r,i,o,a,s,l=0,c=0,u=e.constructor,d=u.precision;if(qt(e)>16)throw Error(Rb+qt(e));if(!e.s)return new u(Er);for(_t=!1,s=d,a=new u(.03125);e.abs().gte(.1);)e=e.times(a),c+=5;for(r=Math.log(Za(2,c))/Math.LN10*2+5|0,s+=r,n=i=o=new u(Er),u.precision=s;;){if(i=at(i.times(e),s),n=n.times(++l),a=o.plus(wo(i,n,s)),Mi(a.d).slice(0,s)===Mi(o.d).slice(0,s)){for(;c--;)o=at(o.times(o),s);return u.precision=d,t==null?(_t=!0,at(o,d)):o}o=a}}function qt(e){for(var t=e.e*yt,n=e.d[0];n>=10;n/=10)t++;return t}function $b(e,t,n){if(t>e.LN10.sd())throw _t=!0,n&&(e.precision=n),Error(qr+"LN10 precision limit exceeded");return at(new e(e.LN10),t)}function ia(e){for(var t="";e--;)t+="0";return t}function lu(e,t){var n,r,i,o,a,s,l,c,u,d=1,f=10,p=e,m=p.d,g=p.constructor,v=g.precision;if(p.s<1)throw Error(qr+(p.s?"NaN":"-Infinity"));if(p.eq(Er))return new g(0);if(t==null?(_t=!1,c=v):c=t,p.eq(10))return t==null&&(_t=!0),$b(g,c);if(c+=f,g.precision=c,n=Mi(m),r=n.charAt(0),o=qt(p),Math.abs(o)<15e14){for(;r<7&&r!=1||r==1&&n.charAt(1)>3;)p=p.times(e),n=Mi(p.d),r=n.charAt(0),d++;o=qt(p),r>1?(p=new g("0."+n),o++):p=new g(r+"."+n.slice(1))}else return l=$b(g,c+2,v).times(o+""),p=lu(new g(r+"."+n.slice(1)),c-f).plus(l),g.precision=v,t==null?(_t=!0,at(p,v)):p;for(s=a=p=wo(p.minus(Er),p.plus(Er),c),u=at(p.times(p),c),i=3;;){if(a=at(a.times(u),c),l=s.plus(wo(a,new g(i),c)),Mi(l.d).slice(0,c)===Mi(s.d).slice(0,c))return s=s.times(2),o!==0&&(s=s.plus($b(g,c+2,v).times(o+""))),s=wo(s,new g(d),c),g.precision=v,t==null?(_t=!0,at(s,v)):s;s=l,i+=2}}function nD(e,t){var n,r,i;for((n=t.indexOf("."))>-1&&(t=t.replace(".","")),(r=t.search(/e/i))>0?(n<0&&(n=r),n+=+t.slice(r+1),t=t.substring(0,r)):n<0&&(n=t.length),r=0;t.charCodeAt(r)===48;)++r;for(i=t.length;t.charCodeAt(i-1)===48;)--i;if(t=t.slice(r,i),t){if(i-=r,n=n-r-1,e.e=gl(n/yt),e.d=[],r=(n+1)%yt,n<0&&(r+=yt),r<i){for(r&&e.d.push(+t.slice(0,r)),i-=yt;r<i;)e.d.push(+t.slice(r,r+=yt));t=t.slice(r),r=yt-t.length}else r-=i;for(;r--;)t+="0";if(e.d.push(+t),_t&&(e.e>Fp||e.e<-Fp))throw Error(Rb+n)}else e.s=0,e.e=0,e.d=[0];return e}function at(e,t,n){var r,i,o,a,s,l,c,u,d=e.d;for(a=1,o=d[0];o>=10;o/=10)a++;if(r=t-a,r<0)r+=yt,i=t,c=d[u=0];else{if(u=Math.ceil((r+1)/yt),o=d.length,u>=o)return e;for(c=o=d[u],a=1;o>=10;o/=10)a++;r%=yt,i=r-yt+a}if(n!==void 0&&(o=Za(10,a-i-1),s=c/o%10|0,l=t<0||d[u+1]!==void 0||c%o,l=n<4?(s||l)&&(n==0||n==(e.s<0?3:2)):s>5||s==5&&(n==4||l||n==6&&(r>0?i>0?c/Za(10,a-i):0:d[u-1])%10&1||n==(e.s<0?8:7))),t<1||!d[0])return l?(o=qt(e),d.length=1,t=t-o-1,d[0]=Za(10,(yt-t%yt)%yt),e.e=gl(-t/yt)||0):(d.length=1,d[0]=e.e=e.s=0),e;if(r==0?(d.length=u,o=1,u--):(d.length=u+1,o=Za(10,yt-r),d[u]=i>0?(c/Za(10,a-i)%Za(10,i)|0)*o:0),l)for(;;)if(u==0){(d[0]+=o)==fn&&(d[0]=1,++e.e);break}else{if(d[u]+=o,d[u]!=fn)break;d[u--]=0,o=1}for(r=d.length;d[--r]===0;)d.pop();if(_t&&(e.e>Fp||e.e<-Fp))throw Error(Rb+qt(e));return e}function rD(e,t){var n,r,i,o,a,s,l,c,u,d,f=e.constructor,p=f.precision;if(!e.s||!t.s)return t.s?t.s=-t.s:t=new f(e),_t?at(t,p):t;if(l=e.d,d=t.d,r=t.e,c=e.e,l=l.slice(),a=c-r,a){for(u=a<0,u?(n=l,a=-a,s=d.length):(n=d,r=c,s=l.length),i=Math.max(Math.ceil(p/yt),s)+2,a>i&&(a=i,n.length=1),n.reverse(),i=a;i--;)n.push(0);n.reverse()}else{for(i=l.length,s=d.length,u=i<s,u&&(s=i),i=0;i<s;i++)if(l[i]!=d[i]){u=l[i]<d[i];break}a=0}for(u&&(n=l,l=d,d=n,t.s=-t.s),s=l.length,i=d.length-s;i>0;--i)l[s++]=0;for(i=d.length;i>a;){if(l[--i]<d[i]){for(o=i;o&&l[--o]===0;)l[o]=fn-1;--l[o],l[i]+=fn}l[i]-=d[i]}for(;l[--s]===0;)l.pop();for(;l[0]===0;l.shift())--r;return l[0]?(t.d=l,t.e=r,_t?at(t,p):t):new f(0)}function Ja(e,t,n){var r,i=qt(e),o=Mi(e.d),a=o.length;return t?(n&&(r=n-a)>0?o=o.charAt(0)+"."+o.slice(1)+ia(r):a>1&&(o=o.charAt(0)+"."+o.slice(1)),o=o+(i<0?"e":"e+")+i):i<0?(o="0."+ia(-i-1)+o,n&&(r=n-a)>0&&(o+=ia(r))):i>=a?(o+=ia(i+1-a),n&&(r=n-i-1)>0&&(o=o+"."+ia(r))):((r=i+1)<a&&(o=o.slice(0,r)+"."+o.slice(r)),n&&(r=n-a)>0&&(i+1===a&&(o+="."),o+=ia(r))),e.s<0?"-"+o:o}function iD(e,t){if(e.length>t)return e.length=t,!0}function oD(e){var t,n,r;function i(o){var a=this;if(!(a instanceof i))return new i(o);if(a.constructor=i,o instanceof i){a.s=o.s,a.e=o.e,a.d=(o=o.d)?o.slice():o;return}if(typeof o=="number"){if(o*0!==0)throw Error(Qa+o);if(o>0)a.s=1;else if(o<0)o=-o,a.s=-1;else{a.s=0,a.e=0,a.d=[0];return}if(o===~~o&&o<1e7){a.e=0,a.d=[o];return}return nD(a,o.toString())}else if(typeof o!="string")throw Error(Qa+o);if(o.charCodeAt(0)===45?(o=o.slice(1),a.s=-1):a.s=1,Rq.test(o))nD(a,o);else throw Error(Qa+o)}if(i.prototype=he,i.ROUND_UP=0,i.ROUND_DOWN=1,i.ROUND_CEIL=2,i.ROUND_FLOOR=3,i.ROUND_HALF_UP=4,i.ROUND_HALF_DOWN=5,i.ROUND_HALF_EVEN=6,i.ROUND_HALF_CEIL=7,i.ROUND_HALF_FLOOR=8,i.clone=oD,i.config=i.set=$q,e===void 0&&(e={}),e)for(r=["precision","rounding","toExpNeg","toExpPos","LN10"],t=0;t<r.length;)e.hasOwnProperty(n=r[t++])||(e[n]=this[n]);return i.config(e),i}function $q(e){if(!e||typeof e!="object")throw Error(qr+"Object expected");var t,n,r,i=["precision",1,ml,"rounding",0,8,"toExpNeg",-1/0,0,"toExpPos",0,1/0];for(t=0;t<i.length;t+=3)if((r=e[n=i[t]])!==void 0)if(gl(r)===r&&r>=i[t+1]&&r<=i[t+2])this[n]=r;else throw Error(Qa+n+": "+r);if((r=e[n="LN10"])!==void 0)if(r==Math.LN10)this[n]=new this(r);else throw Error(Qa+n+": "+r);return this}var Bb=oD(Lq);Er=new Bb(1);const Je=Bb;var Bq=e=>e,aD={},sD=e=>e===aD,lD=e=>function t(){return arguments.length===0||arguments.length===1&&sD(arguments.length<=0?void 0:arguments[0])?t:e(...arguments)},cD=(e,t)=>e===1?t:lD(function(){for(var n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];var o=r.filter(a=>a!==aD).length;return o>=e?t(...r):cD(e-o,lD(function(){for(var a=arguments.length,s=new Array(a),l=0;l<a;l++)s[l]=arguments[l];var c=r.map(u=>sD(u)?s.shift():u);return t(...c,...s)}))}),Lp=e=>cD(e.length,e),Wb=(e,t)=>{for(var n=[],r=e;r<t;++r)n[r-e]=r;return n},Wq=Lp((e,t)=>Array.isArray(t)?t.map(e):Object.keys(t).map(n=>t[n]).map(e)),zq=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];if(!n.length)return Bq;var i=n.reverse(),o=i[0],a=i.slice(1);return function(){return a.reduce((s,l)=>l(s),o(...arguments))}},zb=e=>Array.isArray(e)?e.reverse():e.split("").reverse().join(""),uD=e=>{var t=null,n=null;return function(){for(var r=arguments.length,i=new Array(r),o=0;o<r;o++)i[o]=arguments[o];return t&&i.every((a,s)=>{var l;return a===((l=t)===null||l===void 0?void 0:l[s])})||(t=i,n=e(...i)),n}};function dD(e){var t;return e===0?t=1:t=Math.floor(new Je(e).abs().log(10).toNumber())+1,t}function fD(e,t,n){for(var r=new Je(e),i=0,o=[];r.lt(t)&&i<1e5;)o.push(r.toNumber()),r=r.add(n),i++;return o}Lp((e,t,n)=>{var r=+e,i=+t;return r+n*(i-r)}),Lp((e,t,n)=>{var r=t-+e;return r=r||1/0,(n-e)/r}),Lp((e,t,n)=>{var r=t-+e;return r=r||1/0,Math.max(0,Math.min(1,(n-e)/r))});var pD=e=>{var[t,n]=e,[r,i]=[t,n];return t>n&&([r,i]=[n,t]),[r,i]},hD=(e,t,n)=>{if(e.lte(0))return new Je(0);var r=dD(e.toNumber()),i=new Je(10).pow(r),o=e.div(i),a=r!==1?.05:.1,s=new Je(Math.ceil(o.div(a).toNumber())).add(n).mul(a),l=s.mul(i);return t?new Je(l.toNumber()):new Je(Math.ceil(l.toNumber()))},Vq=(e,t,n)=>{var r=new Je(1),i=new Je(e);if(!i.isint()&&n){var o=Math.abs(e);o<1?(r=new Je(10).pow(dD(e)-1),i=new Je(Math.floor(i.div(r).toNumber())).mul(r)):o>1&&(i=new Je(Math.floor(e)))}else e===0?i=new Je(Math.floor((t-1)/2)):n||(i=new Je(Math.floor(e)));var a=Math.floor((t-1)/2),s=zq(Wq(l=>i.add(new Je(l-a).mul(r)).toNumber()),Wb);return s(0,t)},mD=function(t,n,r,i){var o=arguments.length>4&&arguments[4]!==void 0?arguments[4]:0;if(!Number.isFinite((n-t)/(r-1)))return{step:new Je(0),tickMin:new Je(0),tickMax:new Je(0)};var a=hD(new Je(n).sub(t).div(r-1),i,o),s;t<=0&&n>=0?s=new Je(0):(s=new Je(t).add(n).div(2),s=s.sub(new Je(s).mod(a)));var l=Math.ceil(s.sub(t).div(a).toNumber()),c=Math.ceil(new Je(n).sub(s).div(a).toNumber()),u=l+c+1;return u>r?mD(t,n,r,i,o+1):(u<r&&(c=n>0?c+(r-u):c,l=n>0?l:l+(r-u)),{step:a,tickMin:s.sub(new Je(l).mul(a)),tickMax:s.add(new Je(c).mul(a))})};function Hq(e){var[t,n]=e,r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:6,i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,o=Math.max(r,2),[a,s]=pD([t,n]);if(a===-1/0||s===1/0){var l=s===1/0?[a,...Wb(0,r-1).map(()=>1/0)]:[...Wb(0,r-1).map(()=>-1/0),s];return t>n?zb(l):l}if(a===s)return Vq(a,r,i);var{step:c,tickMin:u,tickMax:d}=mD(a,s,o,i,0),f=fD(u,d.add(new Je(.1).mul(c)),c);return t>n?zb(f):f}function Yq(e,t){var[n,r]=e,i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,[o,a]=pD([n,r]);if(o===-1/0||a===1/0)return[n,r];if(o===a)return[o];var s=Math.max(t,2),l=hD(new Je(a).sub(o).div(s-1),i,0),c=[...fD(new Je(o),new Je(a),l),a];return i===!1&&(c=c.map(u=>Math.round(u))),n>r?zb(c):c}var Uq=uD(Hq),Kq=uD(Yq),gD=e=>e.rootProps.maxBarSize,qq=e=>e.rootProps.barGap,vD=e=>e.rootProps.barCategoryGap,Gq=e=>e.rootProps.barSize,cu=e=>e.rootProps.stackOffset,Vb=e=>e.options.chartName,Hb=e=>e.rootProps.syncId,yD=e=>e.rootProps.syncMethod,Yb=e=>e.options.eventEmitter,_o={allowDuplicatedCategory:!0,angleAxisId:0,reversed:!1,scale:"auto",tick:!0,type:"category"},Sr={allowDataOverflow:!1,allowDuplicatedCategory:!0,radiusAxisId:0,scale:"auto",tick:!0,tickCount:5,type:"number"},Rp=(e,t)=>{if(!(!e||!t))return e!=null&&e.reversed?[t[1],t[0]]:t},Xq={allowDataOverflow:!1,allowDecimals:!1,allowDuplicatedCategory:!1,dataKey:void 0,domain:void 0,id:_o.angleAxisId,includeHidden:!1,name:void 0,reversed:_o.reversed,scale:_o.scale,tick:_o.tick,tickCount:void 0,ticks:void 0,type:_o.type,unit:void 0},Qq={allowDataOverflow:Sr.allowDataOverflow,allowDecimals:!1,allowDuplicatedCategory:Sr.allowDuplicatedCategory,dataKey:void 0,domain:void 0,id:Sr.radiusAxisId,includeHidden:!1,name:void 0,reversed:!1,scale:Sr.scale,tick:Sr.tick,tickCount:Sr.tickCount,ticks:void 0,type:Sr.type,unit:void 0},Zq={allowDataOverflow:!1,allowDecimals:!1,allowDuplicatedCategory:_o.allowDuplicatedCategory,dataKey:void 0,domain:void 0,id:_o.angleAxisId,includeHidden:!1,name:void 0,reversed:!1,scale:_o.scale,tick:_o.tick,tickCount:void 0,ticks:void 0,type:"number",unit:void 0},Jq={allowDataOverflow:Sr.allowDataOverflow,allowDecimals:!1,allowDuplicatedCategory:Sr.allowDuplicatedCategory,dataKey:void 0,domain:void 0,id:Sr.radiusAxisId,includeHidden:!1,name:void 0,reversed:!1,scale:Sr.scale,tick:Sr.tick,tickCount:Sr.tickCount,ticks:void 0,type:"category",unit:void 0},Ub=(e,t)=>e.polarAxis.angleAxis[t]!=null?e.polarAxis.angleAxis[t]:e.layout.layoutType==="radial"?Zq:Xq,Kb=(e,t)=>e.polarAxis.radiusAxis[t]!=null?e.polarAxis.radiusAxis[t]:e.layout.layoutType==="radial"?Jq:Qq,$p=e=>e.polarOptions,qb=H([fo,po,en],LC),bD=H([$p,qb],(e,t)=>{if(e!=null)return Mn(e.innerRadius,t,0)}),xD=H([$p,qb],(e,t)=>{if(e!=null)return Mn(e.outerRadius,t,t*.8)}),eG=e=>{if(e==null)return[0,0];var{startAngle:t,endAngle:n}=e;return[t,n]},wD=H([$p],eG);H([Ub,wD],Rp);var _D=H([qb,bD,xD],(e,t,n)=>{if(!(e==null||t==null||n==null))return[t,n]});H([Kb,_D],Rp);var ED=H([ke,$p,bD,xD,fo,po],(e,t,n,r,i,o)=>{if(!(e!=="centric"&&e!=="radial"||t==null||n==null||r==null)){var{cx:a,cy:s,startAngle:l,endAngle:c}=t;return{cx:Mn(a,i,i/2),cy:Mn(s,o,o/2),innerRadius:n,outerRadius:r,startAngle:l,endAngle:c,clockWise:!1}}}),Et=(e,t)=>t,uu=(e,t,n)=>n;function Bp(e){return e?.id}var rn=e=>{var t=ke(e);return t==="horizontal"?"xAxis":t==="vertical"?"yAxis":t==="centric"?"angleAxis":"radiusAxis"},vl=e=>e.tooltip.settings.axisId,pn=e=>{var t=rn(e),n=vl(e);return du(e,t,n)},SD=H([pn],e=>e?.dataKey);function OD(e,t,n){var{chartData:r=[]}=t,{allowDuplicatedCategory:i,dataKey:o}=n,a=new Map;return e.forEach(s=>{var l,c=(l=s.data)!==null&&l!==void 0?l:r;if(!(c==null||c.length===0)){var u=Bp(s);c.forEach((d,f)=>{var p=o==null||i?f:String(ot(d,o,null)),m=ot(d,s.dataKey,0),g;a.has(p)?g=a.get(p):g={},Object.assign(g,{[u]:m}),a.set(p,g)})}}),Array.from(a.values())}function Wp(e){return e.stackId!=null&&e.dataKey!=null}function CD(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function zp(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?CD(Object(n),!0).forEach(function(r){tG(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):CD(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function tG(e,t,n){return(t=nG(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function nG(e){var t=rG(e,"string");return typeof t=="symbol"?t:t+""}function rG(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Gb=[0,"auto"],Or={allowDataOverflow:!1,allowDecimals:!0,allowDuplicatedCategory:!0,angle:0,dataKey:void 0,domain:void 0,height:30,hide:!0,id:0,includeHidden:!1,interval:"preserveEnd",minTickGap:5,mirror:!1,name:void 0,orientation:"bottom",padding:{left:0,right:0},reversed:!1,scale:"auto",tick:!0,tickCount:5,tickFormatter:void 0,ticks:void 0,type:"category",unit:void 0},kD=(e,t)=>e.cartesianAxis.xAxis[t],Ii=(e,t)=>{var n=kD(e,t);return n??Or},Cr={allowDataOverflow:!1,allowDecimals:!0,allowDuplicatedCategory:!0,angle:0,dataKey:void 0,domain:Gb,hide:!0,id:0,includeHidden:!1,interval:"preserveEnd",minTickGap:5,mirror:!1,name:void 0,orientation:"left",padding:{top:0,bottom:0},reversed:!1,scale:"auto",tick:!0,tickCount:5,tickFormatter:void 0,ticks:void 0,type:"number",unit:void 0,width:zc},PD=(e,t)=>e.cartesianAxis.yAxis[t],Fi=(e,t)=>{var n=PD(e,t);return n??Cr},iG={domain:[0,"auto"],includeHidden:!1,reversed:!1,allowDataOverflow:!1,allowDuplicatedCategory:!1,dataKey:void 0,id:0,name:"",range:[64,64],scale:"auto",type:"number",unit:""},Xb=(e,t)=>{var n=e.cartesianAxis.zAxis[t];return n??iG},Bt=(e,t,n)=>{switch(t){case"xAxis":return Ii(e,n);case"yAxis":return Fi(e,n);case"zAxis":return Xb(e,n);case"angleAxis":return Ub(e,n);case"radiusAxis":return Kb(e,n);default:throw new Error("Unexpected axis type: ".concat(t))}},oG=(e,t,n)=>{switch(t){case"xAxis":return Ii(e,n);case"yAxis":return Fi(e,n);default:throw new Error("Unexpected axis type: ".concat(t))}},du=(e,t,n)=>{switch(t){case"xAxis":return Ii(e,n);case"yAxis":return Fi(e,n);case"angleAxis":return Ub(e,n);case"radiusAxis":return Kb(e,n);default:throw new Error("Unexpected axis type: ".concat(t))}},DD=e=>e.graphicalItems.cartesianItems.some(t=>t.type==="bar")||e.graphicalItems.polarItems.some(t=>t.type==="radialBar");function Qb(e,t){return n=>{switch(e){case"xAxis":return"xAxisId"in n&&n.xAxisId===t;case"yAxis":return"yAxisId"in n&&n.yAxisId===t;case"zAxis":return"zAxisId"in n&&n.zAxisId===t;case"angleAxis":return"angleAxisId"in n&&n.angleAxisId===t;case"radiusAxis":return"radiusAxisId"in n&&n.radiusAxisId===t;default:return!1}}}var fu=e=>e.graphicalItems.cartesianItems,aG=H([Et,uu],Qb),Zb=(e,t,n)=>e.filter(n).filter(r=>t?.includeHidden===!0?!0:!r.hide),pu=H([fu,Bt,aG],Zb),AD=H([pu],e=>e.filter(t=>t.type==="area"||t.type==="bar").filter(Wp)),TD=e=>e.filter(t=>!("stackId"in t)||t.stackId===void 0),ND=H([pu],TD),Jb=e=>e.map(t=>t.data).filter(Boolean).flat(1),sG=H([pu],Jb),e0=(e,t)=>{var{chartData:n=[],dataStartIndex:r,dataEndIndex:i}=t;return e.length>0?e:n.slice(r,i+1)},t0=H([sG,su],e0),n0=(e,t,n)=>t?.dataKey!=null?e.map(r=>({value:ot(r,t.dataKey)})):n.length>0?n.map(r=>r.dataKey).flatMap(r=>e.map(i=>({value:ot(i,r)}))):e.map(r=>({value:r})),Vp=H([t0,Bt,pu],n0);function jD(e,t){switch(e){case"xAxis":return t.direction==="x";case"yAxis":return t.direction==="y";default:return!1}}function es(e){return e.filter(t=>$r(t)||t instanceof Date).map(Number).filter(t=>jn(t)===!1)}function lG(e,t,n){return!n||typeof t!="number"||jn(t)?[]:n.length?es(n.flatMap(r=>{var i=ot(e,r.dataKey),o,a;if(Array.isArray(i)?[o,a]=i:o=a=i,!(!Sn(o)||!Sn(a)))return[t-o,t+a]})):[]}var cG=H([AD,su,pn],OD),MD=(e,t,n)=>{var r={},i=t.reduce((o,a)=>(a.stackId==null||(o[a.stackId]==null&&(o[a.stackId]=[]),o[a.stackId].push(a)),o),r);return Object.fromEntries(Object.entries(i).map(o=>{var[a,s]=o,l=s.map(Bp);return[a,{stackedData:mY(e,l,n),graphicalItems:s}]}))},hu=H([cG,AD,cu],MD),ID=(e,t,n)=>{var{dataStartIndex:r,dataEndIndex:i}=t;if(n!=="zAxis"){var o=bY(e,r,i);if(!(o!=null&&o[0]===0&&o[1]===0))return o}},uG=H([hu,ra,Et],ID),FD=(e,t,n,r,i)=>n.length>0?e.flatMap(o=>n.flatMap(a=>{var s,l,c=(s=r[a.id])===null||s===void 0?void 0:s.filter(d=>jD(i,d)),u=ot(o,(l=t.dataKey)!==null&&l!==void 0?l:a.dataKey);return{value:u,errorDomain:lG(o,u,c)}})).filter(Boolean):t?.dataKey!=null?e.map(o=>({value:ot(o,t.dataKey),errorDomain:[]})):e.map(o=>({value:o,errorDomain:[]})),Hp=e=>e.errorBars,LD=(e,t,n)=>e.flatMap(r=>t[r.id]).filter(Boolean).filter(r=>jD(n,r));H([ND,Hp,Et],LD);var dG=H([t0,Bt,ND,Hp,Et],FD);function fG(e){var{value:t}=e;if($r(t)||t instanceof Date)return t}var RD=e=>{var t=e.flatMap(r=>[r.value,r.errorDomain]).flat(1),n=es(t);if(n.length!==0)return[Math.min(...n),Math.max(...n)]},pG=(e,t,n)=>{var r=e.map(fG).filter(i=>i!=null);return n&&(t.dataKey==null||t.allowDuplicatedCategory&&u2(r))?Mk(0,e.length):t.allowDuplicatedCategory?r:Array.from(new Set(r))},r0=e=>{var t;if(e==null||!("domain"in e))return Gb;if(e.domain!=null)return e.domain;if(e.ticks!=null){if(e.type==="number"){var n=es(e.ticks);return[Math.min(...n),Math.max(...n)]}if(e.type==="category")return e.ticks.map(String)}return(t=e?.domain)!==null&&t!==void 0?t:Gb},Yp=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var i=n.filter(Boolean);if(i.length!==0){var o=i.flat(),a=Math.min(...o),s=Math.max(...o);return[a,s]}},$D=e=>e.referenceElements.dots,yl=(e,t,n)=>e.filter(r=>r.ifOverflow==="extendDomain").filter(r=>t==="xAxis"?r.xAxisId===n:r.yAxisId===n),hG=H([$D,Et,uu],yl),BD=e=>e.referenceElements.areas,mG=H([BD,Et,uu],yl),WD=e=>e.referenceElements.lines,gG=H([WD,Et,uu],yl),zD=(e,t)=>{var n=es(e.map(r=>t==="xAxis"?r.x:r.y));if(n.length!==0)return[Math.min(...n),Math.max(...n)]},vG=H(hG,Et,zD),VD=(e,t)=>{var n=es(e.flatMap(r=>[t==="xAxis"?r.x1:r.y1,t==="xAxis"?r.x2:r.y2]));if(n.length!==0)return[Math.min(...n),Math.max(...n)]},yG=H([mG,Et],VD),HD=(e,t)=>{var n=es(e.map(r=>t==="xAxis"?r.x:r.y));if(n.length!==0)return[Math.min(...n),Math.max(...n)]},bG=H(gG,Et,HD),xG=H(vG,bG,yG,(e,t,n)=>Yp(e,n,t)),YD=H([Bt],r0),i0=(e,t,n,r,i,o,a)=>{var s=Iq(t,e.allowDataOverflow);if(s!=null)return s;var l=o==="vertical"&&a==="xAxis"||o==="horizontal"&&a==="yAxis",c=l?Yp(n,i,RD(r)):Yp(i,RD(r));return Fq(t,c,e.allowDataOverflow)},wG=H([Bt,YD,uG,dG,xG,ke,Et],i0),_G=[0,1],o0=(e,t,n,r,i,o,a)=>{if(!((e==null||n==null||n.length===0)&&a===void 0)){var{dataKey:s,type:l}=e,c=Ti(t,o);return c&&s==null?Mk(0,n.length):l==="category"?pG(r,e,c):i==="expand"?_G:a}},a0=H([Bt,ke,t0,Vp,cu,Et,wG],o0),UD=(e,t,n,r,i)=>{if(e!=null){var{scale:o,type:a}=e;if(o==="auto")return t==="radial"&&i==="radiusAxis"?"band":t==="radial"&&i==="angleAxis"?"linear":a==="category"&&r&&(r.indexOf("LineChart")>=0||r.indexOf("AreaChart")>=0||r.indexOf("ComposedChart")>=0&&!n)?"point":a==="category"?"band":"linear";if(typeof o=="string"){var s="scale".concat(Mc(o));return s in au?s:"point"}}},bl=H([Bt,ke,DD,Vb,Et],UD);function EG(e){if(e!=null){if(e in au)return au[e]();var t="scale".concat(Mc(e));if(t in au)return au[t]()}}function s0(e,t,n,r){if(!(n==null||r==null)){if(typeof e.scale=="function")return e.scale.copy().domain(n).range(r);var i=EG(t);if(i!=null){var o=i.domain(n).range(r);return uY(o),o}}}var l0=(e,t,n)=>{var r=r0(t);if(!(n!=="auto"&&n!=="linear")){if(t!=null&&t.tickCount&&Array.isArray(r)&&(r[0]==="auto"||r[1]==="auto")&&hl(e))return Uq(e,t.tickCount,t.allowDecimals);if(t!=null&&t.tickCount&&t.type==="number"&&hl(e))return Kq(e,t.tickCount,t.allowDecimals)}},c0=H([a0,du,bl],l0),u0=(e,t,n,r)=>{if(r!=="angleAxis"&&e?.type==="number"&&hl(t)&&Array.isArray(n)&&n.length>0){var i=t[0],o=n[0],a=t[1],s=n[n.length-1];return[Math.min(i,o),Math.max(a,s)]}return t},SG=H([Bt,a0,c0,Et],u0),OG=H(Vp,Bt,(e,t)=>{if(!(!t||t.type!=="number")){var n=1/0,r=Array.from(es(e.map(s=>s.value))).sort((s,l)=>s-l);if(r.length<2)return 1/0;var i=r[r.length-1]-r[0];if(i===0)return 1/0;for(var o=0;o<r.length-1;o++){var a=r[o+1]-r[o];n=Math.min(n,a)}return n/i}}),KD=H(OG,ke,vD,en,(e,t,n,r)=>r,(e,t,n,r,i)=>{if(!Sn(e))return 0;var o=t==="vertical"?r.height:r.width;if(i==="gap")return e*o/2;if(i==="no-gap"){var a=Mn(n,e*o),s=e*o/2;return s-a-(s-a)/o*a}return 0}),CG=(e,t)=>{var n=Ii(e,t);return n==null||typeof n.padding!="string"?0:KD(e,"xAxis",t,n.padding)},kG=(e,t)=>{var n=Fi(e,t);return n==null||typeof n.padding!="string"?0:KD(e,"yAxis",t,n.padding)},PG=H(Ii,CG,(e,t)=>{var n,r;if(e==null)return{left:0,right:0};var{padding:i}=e;return typeof i=="string"?{left:t,right:t}:{left:((n=i.left)!==null&&n!==void 0?n:0)+t,right:((r=i.right)!==null&&r!==void 0?r:0)+t}}),DG=H(Fi,kG,(e,t)=>{var n,r;if(e==null)return{top:0,bottom:0};var{padding:i}=e;return typeof i=="string"?{top:t,bottom:t}:{top:((n=i.top)!==null&&n!==void 0?n:0)+t,bottom:((r=i.bottom)!==null&&r!==void 0?r:0)+t}}),AG=H([en,PG,up,cp,(e,t,n)=>n],(e,t,n,r,i)=>{var{padding:o}=r;return i?[o.left,n.width-o.right]:[e.left+t.left,e.left+e.width-t.right]}),TG=H([en,ke,DG,up,cp,(e,t,n)=>n],(e,t,n,r,i,o)=>{var{padding:a}=i;return o?[r.height-a.bottom,a.top]:t==="horizontal"?[e.top+e.height-n.bottom,e.top+n.top]:[e.top+n.top,e.top+e.height-n.bottom]}),mu=(e,t,n,r)=>{var i;switch(t){case"xAxis":return AG(e,n,r);case"yAxis":return TG(e,n,r);case"zAxis":return(i=Xb(e,n))===null||i===void 0?void 0:i.range;case"angleAxis":return wD(e);case"radiusAxis":return _D(e,n);default:return}},qD=H([Bt,mu],Rp),oa=H([Bt,bl,SG,qD],s0);H([pu,Hp,Et],LD);function GD(e,t){return e.id<t.id?-1:e.id>t.id?1:0}var Up=(e,t)=>t,Kp=(e,t,n)=>n,NG=H(ap,Up,Kp,(e,t,n)=>e.filter(r=>r.orientation===t).filter(r=>r.mirror===n).sort(GD)),jG=H(sp,Up,Kp,(e,t,n)=>e.filter(r=>r.orientation===t).filter(r=>r.mirror===n).sort(GD)),XD=(e,t)=>({width:e.width,height:t.height}),MG=(e,t)=>{var n=typeof t.width=="number"?t.width:zc;return{width:n,height:e.height}},QD=H(en,Ii,XD),IG=(e,t,n)=>{switch(t){case"top":return e.top;case"bottom":return n-e.bottom;default:return 0}},FG=(e,t,n)=>{switch(t){case"left":return e.left;case"right":return n-e.right;default:return 0}},LG=H(po,en,NG,Up,Kp,(e,t,n,r,i)=>{var o={},a;return n.forEach(s=>{var l=XD(t,s);a==null&&(a=IG(t,r,e));var c=r==="top"&&!i||r==="bottom"&&i;o[s.id]=a-Number(c)*l.height,a+=(c?-1:1)*l.height}),o}),RG=H(fo,en,jG,Up,Kp,(e,t,n,r,i)=>{var o={},a;return n.forEach(s=>{var l=MG(t,s);a==null&&(a=FG(t,r,e));var c=r==="left"&&!i||r==="right"&&i;o[s.id]=a-Number(c)*l.width,a+=(c?-1:1)*l.width}),o}),$G=(e,t)=>{var n=Ii(e,t);if(n!=null)return LG(e,n.orientation,n.mirror)},BG=H([en,Ii,$G,(e,t)=>t],(e,t,n,r)=>{if(t!=null){var i=n?.[r];return i==null?{x:e.left,y:0}:{x:e.left,y:i}}}),WG=(e,t)=>{var n=Fi(e,t);if(n!=null)return RG(e,n.orientation,n.mirror)},zG=H([en,Fi,WG,(e,t)=>t],(e,t,n,r)=>{if(t!=null){var i=n?.[r];return i==null?{x:0,y:e.top}:{x:i,y:e.top}}}),ZD=H(en,Fi,(e,t)=>{var n=typeof t.width=="number"?t.width:zc;return{width:n,height:e.height}}),JD=(e,t,n)=>{switch(t){case"xAxis":return QD(e,n).width;case"yAxis":return ZD(e,n).height;default:return}},eA=(e,t,n,r)=>{if(n!=null){var{allowDuplicatedCategory:i,type:o,dataKey:a}=n,s=Ti(e,r),l=t.map(c=>c.value);if(a&&s&&o==="category"&&i&&u2(l))return l}},d0=H([ke,Vp,Bt,Et],eA),tA=(e,t,n,r)=>{if(!(n==null||n.dataKey==null)){var{type:i,scale:o}=n,a=Ti(e,r);if(a&&(i==="number"||o!=="auto"))return t.map(s=>s.value)}},f0=H([ke,Vp,du,Et],tA),nA=H([ke,oG,bl,oa,d0,f0,mu,c0,Et],(e,t,n,r,i,o,a,s,l)=>{if(t==null)return null;var c=Ti(e,l);return{angle:t.angle,interval:t.interval,minTickGap:t.minTickGap,orientation:t.orientation,tick:t.tick,tickCount:t.tickCount,tickFormatter:t.tickFormatter,ticks:t.ticks,type:t.type,unit:t.unit,axisType:l,categoricalDomain:o,duplicateDomain:i,isCategorical:c,niceTicks:s,range:a,realScaleType:n,scale:r}}),VG=(e,t,n,r,i,o,a,s,l)=>{if(!(t==null||r==null)){var c=Ti(e,l),{type:u,ticks:d,tickCount:f}=t,p=n==="scaleBand"&&typeof r.bandwidth=="function"?r.bandwidth()/2:2,m=u==="category"&&r.bandwidth?r.bandwidth()/p:0;m=l==="angleAxis"&&o!=null&&o.length>=2?un(o[0]-o[1])*2*m:m;var g=d||i;if(g){var v=g.map((x,_)=>{var w=a?a.indexOf(x):x;return{index:_,coordinate:r(w)+m,value:x,offset:m}});return v.filter(x=>!jn(x.coordinate))}return c&&s?s.map((x,_)=>({coordinate:r(x)+m,value:x,index:_,offset:m})):r.ticks?r.ticks(f).map(x=>({coordinate:r(x)+m,value:x,offset:m})):r.domain().map((x,_)=>({coordinate:r(x)+m,value:a?a[x]:x,index:_,offset:m}))}},rA=H([ke,du,bl,oa,c0,mu,d0,f0,Et],VG),HG=(e,t,n,r,i,o,a)=>{if(!(t==null||n==null||r==null||r[0]===r[1])){var s=Ti(e,a),{tickCount:l}=t,c=0;return c=a==="angleAxis"&&r?.length>=2?un(r[0]-r[1])*2*c:c,s&&o?o.map((u,d)=>({coordinate:n(u)+c,value:u,index:d,offset:c})):n.ticks?n.ticks(l).map(u=>({coordinate:n(u)+c,value:u,offset:c})):n.domain().map((u,d)=>({coordinate:n(u)+c,value:i?i[u]:u,index:d,offset:c}))}},Li=H([ke,du,oa,mu,d0,f0,Et],HG),Ri=H(Bt,oa,(e,t)=>{if(!(e==null||t==null))return zp(zp({},e),{},{scale:t})}),YG=H([Bt,bl,a0,qD],s0);H((e,t,n)=>Xb(e,n),YG,(e,t)=>{if(!(e==null||t==null))return zp(zp({},e),{},{scale:t})});var UG=H([ke,ap,sp],(e,t,n)=>{switch(e){case"horizontal":return t.some(r=>r.reversed)?"right-to-left":"left-to-right";case"vertical":return n.some(r=>r.reversed)?"bottom-to-top":"top-to-bottom";case"centric":case"radial":return"left-to-right";default:return}}),iA=e=>e.options.defaultTooltipEventType,oA=e=>e.options.validateTooltipEventTypes;function aA(e,t,n){if(e==null)return t;var r=e?"axis":"item";return n==null?t:n.includes(r)?r:t}function p0(e,t){var n=iA(e),r=oA(e);return aA(t,n,r)}function KG(e){return pe(t=>p0(t,e))}var sA=(e,t)=>{var n,r=Number(t);if(!(jn(r)||t==null))return r>=0?e==null||(n=e[r])===null||n===void 0?void 0:n.value:void 0},qG=e=>e.tooltip.settings,aa={active:!1,index:null,dataKey:void 0,coordinate:void 0},GG={itemInteraction:{click:aa,hover:aa},axisInteraction:{click:aa,hover:aa},keyboardInteraction:aa,syncInteraction:{active:!1,index:null,dataKey:void 0,label:void 0,coordinate:void 0},tooltipItemPayloads:[],settings:{shared:void 0,trigger:"hover",axisId:0,active:!1,defaultIndex:void 0}},lA=_r({name:"tooltip",initialState:GG,reducers:{addTooltipEntrySettings(e,t){e.tooltipItemPayloads.push(t.payload)},removeTooltipEntrySettings(e,t){var n=uo(e).tooltipItemPayloads.indexOf(t.payload);n>-1&&e.tooltipItemPayloads.splice(n,1)},setTooltipSettingsState(e,t){e.settings=t.payload},setActiveMouseOverItemIndex(e,t){e.syncInteraction.active=!1,e.keyboardInteraction.active=!1,e.itemInteraction.hover.active=!0,e.itemInteraction.hover.index=t.payload.activeIndex,e.itemInteraction.hover.dataKey=t.payload.activeDataKey,e.itemInteraction.hover.coordinate=t.payload.activeCoordinate},mouseLeaveChart(e){e.itemInteraction.hover.active=!1,e.axisInteraction.hover.active=!1},mouseLeaveItem(e){e.itemInteraction.hover.active=!1},setActiveClickItemIndex(e,t){e.syncInteraction.active=!1,e.itemInteraction.click.active=!0,e.keyboardInteraction.active=!1,e.itemInteraction.click.index=t.payload.activeIndex,e.itemInteraction.click.dataKey=t.payload.activeDataKey,e.itemInteraction.click.coordinate=t.payload.activeCoordinate},setMouseOverAxisIndex(e,t){e.syncInteraction.active=!1,e.axisInteraction.hover.active=!0,e.keyboardInteraction.active=!1,e.axisInteraction.hover.index=t.payload.activeIndex,e.axisInteraction.hover.dataKey=t.payload.activeDataKey,e.axisInteraction.hover.coordinate=t.payload.activeCoordinate},setMouseClickAxisIndex(e,t){e.syncInteraction.active=!1,e.keyboardInteraction.active=!1,e.axisInteraction.click.active=!0,e.axisInteraction.click.index=t.payload.activeIndex,e.axisInteraction.click.dataKey=t.payload.activeDataKey,e.axisInteraction.click.coordinate=t.payload.activeCoordinate},setSyncInteraction(e,t){e.syncInteraction=t.payload},setKeyboardInteraction(e,t){e.keyboardInteraction.active=t.payload.active,e.keyboardInteraction.index=t.payload.activeIndex,e.keyboardInteraction.coordinate=t.payload.activeCoordinate,e.keyboardInteraction.dataKey=t.payload.activeDataKey}}}),{addTooltipEntrySettings:XG,removeTooltipEntrySettings:QG,setTooltipSettingsState:ZG,setActiveMouseOverItemIndex:cA,mouseLeaveItem:JG,mouseLeaveChart:uA,setActiveClickItemIndex:eX,setMouseOverAxisIndex:dA,setMouseClickAxisIndex:tX,setSyncInteraction:h0,setKeyboardInteraction:m0}=lA.actions,nX=lA.reducer;function fA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function qp(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?fA(Object(n),!0).forEach(function(r){rX(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):fA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function rX(e,t,n){return(t=iX(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function iX(e){var t=oX(e,"string");return typeof t=="symbol"?t:t+""}function oX(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function aX(e,t,n){return t==="axis"?n==="click"?e.axisInteraction.click:e.axisInteraction.hover:n==="click"?e.itemInteraction.click:e.itemInteraction.hover}function sX(e){return e.index!=null}var pA=(e,t,n,r)=>{if(t==null)return aa;var i=aX(e,t,n);if(i==null)return aa;if(i.active)return i;if(e.keyboardInteraction.active)return e.keyboardInteraction;if(e.syncInteraction.active&&e.syncInteraction.index!=null)return e.syncInteraction;var o=e.settings.active===!0;if(sX(i)){if(o)return qp(qp({},i),{},{active:!0})}else if(r!=null)return{active:!0,coordinate:void 0,dataKey:void 0,index:r};return qp(qp({},aa),{},{coordinate:i.coordinate})},g0=(e,t)=>{var n=e?.index;if(n==null)return null;var r=Number(n);if(!Sn(r))return n;var i=0,o=1/0;return t.length>0&&(o=t.length-1),String(Math.max(i,Math.min(r,o)))},hA=(e,t,n,r,i,o,a,s)=>{if(!(o==null||s==null)){var l=a[0],c=l==null?void 0:s(l.positions,o);if(c!=null)return c;var u=i?.[Number(o)];if(u)switch(n){case"horizontal":return{x:u.coordinate,y:(r.top+t)/2};default:return{x:(r.left+e)/2,y:u.coordinate}}}},mA=(e,t,n,r)=>{if(t==="axis")return e.tooltipItemPayloads;if(e.tooltipItemPayloads.length===0)return[];var i;return n==="hover"?i=e.itemInteraction.hover.dataKey:i=e.itemInteraction.click.dataKey,i==null&&r!=null?[e.tooltipItemPayloads[0]]:e.tooltipItemPayloads.filter(o=>{var a;return((a=o.settings)===null||a===void 0?void 0:a.dataKey)===i})},gu=e=>e.options.tooltipPayloadSearcher,xl=e=>e.tooltip;function gA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function vA(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?gA(Object(n),!0).forEach(function(r){lX(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):gA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function lX(e,t,n){return(t=cX(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function cX(e){var t=uX(e,"string");return typeof t=="symbol"?t:t+""}function uX(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function dX(e,t){return e??t}var yA=(e,t,n,r,i,o,a)=>{if(!(t==null||o==null)){var{chartData:s,computedData:l,dataStartIndex:c,dataEndIndex:u}=n,d=[];return e.reduce((f,p)=>{var m,{dataDefinedOnItem:g,settings:v}=p,x=dX(g,s),_=Array.isArray(x)?RC(x,c,u):x,w=(m=v?.dataKey)!==null&&m!==void 0?m:r,y=v?.nameKey,E;if(r&&Array.isArray(_)&&!Array.isArray(_[0])&&a==="axis"?E=d2(_,r,i):E=o(_,t,l,y),Array.isArray(E))E.forEach(P=>{var D=vA(vA({},v),{},{name:P.name,unit:P.unit,color:void 0,fill:void 0});f.push(KC({tooltipEntrySettings:D,dataKey:P.dataKey,payload:P.payload,value:ot(P.payload,P.dataKey),name:P.name}))});else{var S;f.push(KC({tooltipEntrySettings:v,dataKey:w,payload:E,value:ot(E,w),name:(S=ot(E,y))!==null&&S!==void 0?S:v?.name}))}return f},d)}},v0=H([pn,ke,DD,Vb,rn],UD),fX=H([e=>e.graphicalItems.cartesianItems,e=>e.graphicalItems.polarItems],(e,t)=>[...e,...t]),pX=H([rn,vl],Qb),vu=H([fX,pn,pX],Zb),hX=H([vu],e=>e.filter(Wp)),mX=H([vu],Jb),wl=H([mX,ra],e0),gX=H([hX,ra,pn],OD),y0=H([wl,pn,vu],n0),vX=H([pn],r0),yX=H([vu],e=>e.filter(Wp)),bX=H([gX,yX,cu],MD),xX=H([bX,ra,rn],ID),wX=H([vu],TD),_X=H([wl,pn,wX,Hp,rn],FD),EX=H([$D,rn,vl],yl),SX=H([EX,rn],zD),OX=H([BD,rn,vl],yl),CX=H([OX,rn],VD),kX=H([WD,rn,vl],yl),PX=H([kX,rn],HD),DX=H([SX,PX,CX],Yp),AX=H([pn,vX,xX,_X,DX,ke,rn],i0),bA=H([pn,ke,wl,y0,cu,rn,AX],o0),TX=H([bA,pn,v0],l0),NX=H([pn,bA,TX,rn],u0),xA=e=>{var t=rn(e),n=vl(e),r=!1;return mu(e,t,n,r)},wA=H([pn,xA],Rp),_A=H([pn,v0,NX,wA],s0),jX=H([ke,y0,pn,rn],eA),MX=H([ke,y0,pn,rn],tA),IX=(e,t,n,r,i,o,a,s)=>{if(t){var{type:l}=t,c=Ti(e,s);if(r){var u=n==="scaleBand"&&r.bandwidth?r.bandwidth()/2:2,d=l==="category"&&r.bandwidth?r.bandwidth()/u:0;return d=s==="angleAxis"&&i!=null&&i?.length>=2?un(i[0]-i[1])*2*d:d,c&&a?a.map((f,p)=>({coordinate:r(f)+d,value:f,index:p,offset:d})):r.domain().map((f,p)=>({coordinate:r(f)+d,value:o?o[f]:f,index:p,offset:d}))}}},Eo=H([ke,pn,v0,_A,xA,jX,MX,rn],IX),b0=H([iA,oA,qG],(e,t,n)=>aA(n.shared,e,t)),EA=e=>e.tooltip.settings.trigger,x0=e=>e.tooltip.settings.defaultIndex,Gp=H([xl,b0,EA,x0],pA),sa=H([Gp,wl],g0),SA=H([Eo,sa],sA),OA=H([Gp],e=>{if(e)return e.dataKey}),CA=H([xl,b0,EA,x0],mA),FX=H([fo,po,ke,en,Eo,x0,CA,gu],hA),LX=H([Gp,FX],(e,t)=>e!=null&&e.coordinate?e.coordinate:t),RX=H([Gp],e=>e.active),$X=H([CA,sa,ra,SD,SA,gu,b0],yA),BX=H([$X],e=>{if(e!=null){var t=e.map(n=>n.payload).filter(n=>n!=null);return Array.from(new Set(t))}});function kA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function PA(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?kA(Object(n),!0).forEach(function(r){WX(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):kA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function WX(e,t,n){return(t=zX(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function zX(e){var t=VX(e,"string");return typeof t=="symbol"?t:t+""}function VX(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var HX=()=>pe(pn),YX=()=>{var e=HX(),t=pe(Eo),n=pe(_A);return Ya(PA(PA({},e),{},{scale:n}),t)},DA=()=>pe(Vb),w0=(e,t)=>t,AA=(e,t,n)=>n,_0=(e,t,n,r)=>r,UX=H(Eo,e=>zf(e,t=>t.coordinate)),E0=H([xl,w0,AA,_0],pA),TA=H([E0,wl],g0),KX=(e,t,n)=>{if(t!=null){var r=xl(e);return t==="axis"?n==="hover"?r.axisInteraction.hover.dataKey:r.axisInteraction.click.dataKey:n==="hover"?r.itemInteraction.hover.dataKey:r.itemInteraction.click.dataKey}},NA=H([xl,w0,AA,_0],mA),Xp=H([fo,po,ke,en,Eo,_0,NA,gu],hA),qX=H([E0,Xp],(e,t)=>{var n;return(n=e.coordinate)!==null&&n!==void 0?n:t}),jA=H(Eo,TA,sA),GX=H([NA,TA,ra,SD,jA,gu,w0],yA),XX=H([E0],e=>({isActive:e.active,activeIndex:e.index})),QX=(e,t,n,r,i,o,a,s)=>{if(!(!e||!t||!r||!i||!o)){var l=xY(e.chartX,e.chartY,t,n,s);if(l){var c=_Y(l,t),u=lY(c,a,o,r,i),d=wY(t,o,u,l);return{activeIndex:String(u),activeCoordinate:d}}}};function S0(){return S0=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},S0.apply(null,arguments)}function MA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Qp(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?MA(Object(n),!0).forEach(function(r){ZX(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):MA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function ZX(e,t,n){return(t=JX(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function JX(e){var t=eQ(e,"string");return typeof t=="symbol"?t:t+""}function eQ(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function tQ(e){var{coordinate:t,payload:n,index:r,offset:i,tooltipAxisBandSize:o,layout:a,cursor:s,tooltipEventType:l,chartName:c}=e,u=t,d=n,f=r;if(!s||!u||c!=="ScatterChart"&&l!=="axis")return null;var p,m;if(c==="ScatterChart")p=u,m=_9;else if(c==="BarChart")p=E9(a,u,i,o),m=Ck;else if(a==="radial"){var{cx:g,cy:v,radius:x,startAngle:_,endAngle:w}=kk(u);p={cx:g,cy:v,startAngle:_,endAngle:w,innerRadius:x,outerRadius:x},m=Dk}else p={points:nU(a,u,i)},m=ol;var y=typeof s=="object"&&"className"in s?s.className:void 0,E=Qp(Qp(Qp(Qp({stroke:"#ccc",pointerEvents:"none"},i),p),dt(s,!1)),{},{payload:d,payloadIndex:f,className:ue("recharts-tooltip-cursor",y)});return k.isValidElement(s)?k.cloneElement(s,E):k.createElement(m,E)}function nQ(e){var t=YX(),n=ZC(),r=Vc(),i=DA();return O.createElement(tQ,S0({},e,{coordinate:e.coordinate,index:e.index,payload:e.payload,offset:n,layout:r,tooltipAxisBandSize:t,chartName:i}))}var IA=k.createContext(null),rQ=()=>k.useContext(IA),O0={exports:{}},FA;function iQ(){return FA||(FA=1,(function(e){var t=Object.prototype.hasOwnProperty,n="~";function r(){}Object.create&&(r.prototype=Object.create(null),new r().__proto__||(n=!1));function i(l,c,u){this.fn=l,this.context=c,this.once=u||!1}function o(l,c,u,d,f){if(typeof u!="function")throw new TypeError("The listener must be a function");var p=new i(u,d||l,f),m=n?n+c:c;return l._events[m]?l._events[m].fn?l._events[m]=[l._events[m],p]:l._events[m].push(p):(l._events[m]=p,l._eventsCount++),l}function a(l,c){--l._eventsCount===0?l._events=new r:delete l._events[c]}function s(){this._events=new r,this._eventsCount=0}s.prototype.eventNames=function(){var c=[],u,d;if(this._eventsCount===0)return c;for(d in u=this._events)t.call(u,d)&&c.push(n?d.slice(1):d);return Object.getOwnPropertySymbols?c.concat(Object.getOwnPropertySymbols(u)):c},s.prototype.listeners=function(c){var u=n?n+c:c,d=this._events[u];if(!d)return[];if(d.fn)return[d.fn];for(var f=0,p=d.length,m=new Array(p);f<p;f++)m[f]=d[f].fn;return m},s.prototype.listenerCount=function(c){var u=n?n+c:c,d=this._events[u];return d?d.fn?1:d.length:0},s.prototype.emit=function(c,u,d,f,p,m){var g=n?n+c:c;if(!this._events[g])return!1;var v=this._events[g],x=arguments.length,_,w;if(v.fn){switch(v.once&&this.removeListener(c,v.fn,void 0,!0),x){case 1:return v.fn.call(v.context),!0;case 2:return v.fn.call(v.context,u),!0;case 3:return v.fn.call(v.context,u,d),!0;case 4:return v.fn.call(v.context,u,d,f),!0;case 5:return v.fn.call(v.context,u,d,f,p),!0;case 6:return v.fn.call(v.context,u,d,f,p,m),!0}for(w=1,_=new Array(x-1);w<x;w++)_[w-1]=arguments[w];v.fn.apply(v.context,_)}else{var y=v.length,E;for(w=0;w<y;w++)switch(v[w].once&&this.removeListener(c,v[w].fn,void 0,!0),x){case 1:v[w].fn.call(v[w].context);break;case 2:v[w].fn.call(v[w].context,u);break;case 3:v[w].fn.call(v[w].context,u,d);break;case 4:v[w].fn.call(v[w].context,u,d,f);break;default:if(!_)for(E=1,_=new Array(x-1);E<x;E++)_[E-1]=arguments[E];v[w].fn.apply(v[w].context,_)}}return!0},s.prototype.on=function(c,u,d){return o(this,c,u,d,!1)},s.prototype.once=function(c,u,d){return o(this,c,u,d,!0)},s.prototype.removeListener=function(c,u,d,f){var p=n?n+c:c;if(!this._events[p])return this;if(!u)return a(this,p),this;var m=this._events[p];if(m.fn)m.fn===u&&(!f||m.once)&&(!d||m.context===d)&&a(this,p);else{for(var g=0,v=[],x=m.length;g<x;g++)(m[g].fn!==u||f&&!m[g].once||d&&m[g].context!==d)&&v.push(m[g]);v.length?this._events[p]=v.length===1?v[0]:v:a(this,p)}return this},s.prototype.removeAllListeners=function(c){var u;return c?(u=n?n+c:c,this._events[u]&&a(this,u)):(this._events=new r,this._eventsCount=0),this},s.prototype.off=s.prototype.removeListener,s.prototype.addListener=s.prototype.on,s.prefixed=n,s.EventEmitter=s,e.exports=s})(O0)),O0.exports}var oQ=iQ();const aQ=Ki(oQ);var yu=new aQ,C0="recharts.syncEvent.tooltip",LA="recharts.syncEvent.brush";function Zp(e,t){if(t){var n=Number.parseInt(t,10);if(!jn(n))return e?.[n]}}var sQ={chartName:"",tooltipPayloadSearcher:void 0,eventEmitter:void 0,defaultTooltipEventType:"axis"},RA=_r({name:"options",initialState:sQ,reducers:{createEventEmitter:e=>{e.eventEmitter==null&&(e.eventEmitter=Symbol("rechartsEventEmitter"))}}}),lQ=RA.reducer,{createEventEmitter:cQ}=RA.actions;function uQ(e){return e.tooltip.syncInteraction}var dQ={chartData:void 0,computedData:void 0,dataStartIndex:0,dataEndIndex:0},$A=_r({name:"chartData",initialState:dQ,reducers:{setChartData(e,t){if(e.chartData=t.payload,t.payload==null){e.dataStartIndex=0,e.dataEndIndex=0;return}t.payload.length>0&&e.dataEndIndex!==t.payload.length-1&&(e.dataEndIndex=t.payload.length-1)},setComputedData(e,t){e.computedData=t.payload},setDataStartEndIndexes(e,t){var{startIndex:n,endIndex:r}=t.payload;n!=null&&(e.dataStartIndex=n),r!=null&&(e.dataEndIndex=r)}}}),{setChartData:BA,setDataStartEndIndexes:fQ,setComputedData:Jhe}=$A.actions,pQ=$A.reducer,hQ=["x","y"];function WA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function ts(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?WA(Object(n),!0).forEach(function(r){mQ(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):WA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function mQ(e,t,n){return(t=gQ(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function gQ(e){var t=vQ(e,"string");return typeof t=="symbol"?t:t+""}function vQ(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function yQ(e,t){if(e==null)return{};var n,r,i=bQ(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function bQ(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}var zA=()=>{};function xQ(){var e=pe(Hb),t=pe(Yb),n=wt(),r=pe(yD),i=pe(Eo),o=Vc(),a=dp(),s=pe(l=>l.rootProps.className);k.useEffect(()=>{if(e==null)return zA;var l=(c,u,d)=>{if(t!==d&&e===c){if(r==="index"){var f;if(a&&u!==null&&u!==void 0&&(f=u.payload)!==null&&f!==void 0&&f.coordinate){var p=u.payload.coordinate,{x:m,y:g}=p,v=yQ(p,hQ),x=ts(ts(ts({},v),typeof m=="number"&&{x:Math.max(a.x,Math.min(m,a.x+a.width))}),typeof g=="number"&&{y:Math.max(a.y,Math.min(g,a.y+a.height))}),_=ts(ts({},u),{},{payload:ts(ts({},u.payload),{},{coordinate:x})});n(_)}else n(u);return}if(i!=null){var w;if(typeof r=="function"){var y={activeTooltipIndex:u.payload.index==null?void 0:Number(u.payload.index),isTooltipActive:u.payload.active,activeIndex:u.payload.index==null?void 0:Number(u.payload.index),activeLabel:u.payload.label,activeDataKey:u.payload.dataKey,activeCoordinate:u.payload.coordinate},E=r(i,y);w=i[E]}else r==="value"&&(w=i.find(j=>String(j.value)===u.payload.label));var{coordinate:S}=u.payload;if(w==null||u.payload.active===!1||S==null||a==null){n(h0({active:!1,coordinate:void 0,dataKey:void 0,index:null,label:void 0}));return}var{x:P,y:D}=S,T=Math.min(P,a.x+a.width),I=Math.min(D,a.y+a.height),A={x:o==="horizontal"?w.coordinate:T,y:o==="horizontal"?I:w.coordinate},C=h0({active:u.payload.active,coordinate:A,dataKey:u.payload.dataKey,index:String(w.index),label:u.payload.label});n(C)}}};return yu.on(C0,l),()=>{yu.off(C0,l)}},[s,n,t,e,r,i,o,a])}function wQ(){var e=pe(Hb),t=pe(Yb),n=wt();k.useEffect(()=>{if(e==null)return zA;var r=(i,o,a)=>{t!==a&&e===i&&n(fQ(o))};return yu.on(LA,r),()=>{yu.off(LA,r)}},[n,t,e])}function _Q(){var e=wt();k.useEffect(()=>{e(cQ())},[e]),xQ(),wQ()}function EQ(e,t,n,r,i,o){var a=pe(f=>KX(f,e,t)),s=pe(Yb),l=pe(Hb),c=pe(yD),u=pe(uQ),d=u?.active;k.useEffect(()=>{if(!d&&l!=null&&s!=null){var f=h0({active:o,coordinate:n,dataKey:a,index:i,label:typeof r=="number"?String(r):r});yu.emit(C0,l,f,s)}},[d,n,a,i,r,s,l,c,o])}function VA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function HA(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?VA(Object(n),!0).forEach(function(r){SQ(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):VA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function SQ(e,t,n){return(t=OQ(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function OQ(e){var t=CQ(e,"string");return typeof t=="symbol"?t:t+""}function CQ(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function kQ(e){return e.dataKey}function PQ(e,t){return O.isValidElement(e)?O.cloneElement(e,t):typeof e=="function"?O.createElement(e,t):O.createElement(e9,t)}var YA=[],DQ={allowEscapeViewBox:{x:!1,y:!1},animationDuration:400,animationEasing:"ease",axisId:0,contentStyle:{},cursor:!0,filterNull:!0,isAnimationActive:!ho.isSsr,itemSorter:"name",itemStyle:{},labelStyle:{},offset:10,reverseDirection:{x:!1,y:!1},separator:" : ",trigger:"hover",useTranslate3d:!1,wrapperStyle:{}};function St(e){var t=tn(e,DQ),{active:n,allowEscapeViewBox:r,animationDuration:i,animationEasing:o,content:a,filterNull:s,isAnimationActive:l,offset:c,payloadUniqBy:u,position:d,reverseDirection:f,useTranslate3d:p,wrapperStyle:m,cursor:g,shared:v,trigger:x,defaultIndex:_,portal:w,axisId:y}=t,E=wt(),S=typeof _=="number"?String(_):_;k.useEffect(()=>{E(ZG({shared:v,trigger:x,axisId:y,active:n,defaultIndex:S}))},[E,v,x,y,n,S]);var P=dp(),D=sk(),T=KG(v),{activeIndex:I,isActive:A}=pe(re=>XX(re,T,x,S)),C=pe(re=>GX(re,T,x,S)),j=pe(re=>jA(re,T,x,S)),N=pe(re=>qX(re,T,x,S)),M=C,R=rQ(),B=n??A,[V,z]=qO([M,B]),W=T==="axis"?j:void 0;EQ(T,x,N,W,I,B);var Q=w??R;if(Q==null)return null;var G=M??YA;B||(G=YA),s&&G.length&&(G=OO(M.filter(re=>re.value!=null&&(re.hide!==!0||t.includeHidden)),u,kQ));var ie=G.length>0,J=O.createElement(s9,{allowEscapeViewBox:r,animationDuration:i,animationEasing:o,isAnimationActive:l,active:B,coordinate:N,hasPayload:ie,offset:c,position:d,reverseDirection:f,useTranslate3d:p,viewBox:P,wrapperStyle:m,lastBoundingBox:V,innerRef:z,hasPortalFromProps:!!w},PQ(a,HA(HA({},t),{},{payload:G,label:W,active:B,coordinate:N,accessibilityLayer:D})));return O.createElement(O.Fragment,null,fi.createPortal(J,Q),B&&O.createElement(nQ,{cursor:g,tooltipEventType:T,coordinate:N,payload:M,index:I}))}var k0={},P0={},D0={},UA;function AQ(){return UA||(UA=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});function t(n,r,{signal:i,edges:o}={}){let a,s=null;const l=o!=null&&o.includes("leading"),c=o==null||o.includes("trailing"),u=()=>{s!==null&&(n.apply(a,s),a=void 0,s=null)},d=()=>{c&&u(),g()};let f=null;const p=()=>{f!=null&&clearTimeout(f),f=setTimeout(()=>{f=null,d()},r)},m=()=>{f!==null&&(clearTimeout(f),f=null)},g=()=>{m(),a=void 0,s=null},v=()=>{u()},x=function(..._){if(i?.aborted)return;a=this,s=_;const w=f==null;p(),l&&w&&u()};return x.schedule=p,x.cancel=g,x.flush=v,i?.addEventListener("abort",g,{once:!0}),x}e.debounce=t})(D0)),D0}var KA;function TQ(){return KA||(KA=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=AQ();function n(r,i=0,o={}){typeof o!="object"&&(o={});const{leading:a=!1,trailing:s=!0,maxWait:l}=o,c=Array(2);a&&(c[0]="leading"),s&&(c[1]="trailing");let u,d=null;const f=t.debounce(function(...g){u=r.apply(this,g),d=null},i,{edges:c}),p=function(...g){return l!=null&&(d===null&&(d=Date.now()),Date.now()-d>=l)?(u=r.apply(this,g),d=Date.now(),f.cancel(),f.schedule(),u):(f.apply(this,g),u)},m=()=>(f.flush(),u);return p.cancel=f.cancel,p.flush=m,p}e.debounce=n})(P0)),P0}var qA;function NQ(){return qA||(qA=1,(function(e){Object.defineProperty(e,Symbol.toStringTag,{value:"Module"});const t=TQ();function n(r,i=0,o={}){const{leading:a=!0,trailing:s=!0}=o;return t.debounce(r,i,{leading:a,maxWait:i,trailing:s})}e.throttle=n})(k0)),k0}var A0,GA;function jQ(){return GA||(GA=1,A0=NQ().throttle),A0}var MQ=jQ();const IQ=Ki(MQ);var FQ=process.env.NODE_ENV!=="production",bu=function(t,n){for(var r=arguments.length,i=new Array(r>2?r-2:0),o=2;o<r;o++)i[o-2]=arguments[o];if(FQ&&typeof console<"u"&&console.warn&&(n===void 0&&console.warn("LogUtils requires an error message argument"),!t))if(n===void 0)console.warn("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var a=0;console.warn(n.replace(/%s/g,()=>i[a++]))}};function XA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function T0(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?XA(Object(n),!0).forEach(function(r){LQ(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):XA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function LQ(e,t,n){return(t=RQ(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function RQ(e){var t=$Q(e,"string");return typeof t=="symbol"?t:t+""}function $Q(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Ot=k.forwardRef((e,t)=>{var{aspect:n,initialDimension:r={width:-1,height:-1},width:i="100%",height:o="100%",minWidth:a=0,minHeight:s,maxHeight:l,children:c,debounce:u=0,id:d,className:f,onResize:p,style:m={}}=e,g=k.useRef(null),v=k.useRef();v.current=p,k.useImperativeHandle(t,()=>g.current);var[x,_]=k.useState({containerWidth:r.width,containerHeight:r.height}),w=k.useCallback((E,S)=>{_(P=>{var D=Math.round(E),T=Math.round(S);return P.containerWidth===D&&P.containerHeight===T?P:{containerWidth:D,containerHeight:T}})},[]);k.useEffect(()=>{var E=T=>{var I,{width:A,height:C}=T[0].contentRect;w(A,C),(I=v.current)===null||I===void 0||I.call(v,A,C)};u>0&&(E=IQ(E,u,{trailing:!0,leading:!1}));var S=new ResizeObserver(E),{width:P,height:D}=g.current.getBoundingClientRect();return w(P,D),S.observe(g.current),()=>{S.disconnect()}},[w,u]);var y=k.useMemo(()=>{var{containerWidth:E,containerHeight:S}=x;if(E<0||S<0)return null;bu(La(i)||La(o),`The width(%s) and height(%s) are both fixed numbers,
|
|
221
221
|
maybe you don't need to use a ResponsiveContainer.`,i,o),bu(!n||n>0,"The aspect(%s) must be greater than zero.",n);var P=La(i)?E:i,D=La(o)?S:o;return n&&n>0&&(P?D=P/n:D&&(P=D*n),l&&D>l&&(D=l)),bu(P>0||D>0,`The width(%s) and height(%s) of chart should be greater than 0,
|
|
222
222
|
please check the style of container, or the props width(%s) and height(%s),
|
|
223
223
|
or add a minWidth(%s) or minHeight(%s) or use aspect(%s) to control the
|
|
@@ -239,27 +239,27 @@ Take a look at the reducer(s) handling this action type: ${p.type}.
|
|
|
239
239
|
*
|
|
240
240
|
* This source code is licensed under the MIT license found in the
|
|
241
241
|
* LICENSE file in the root directory of this source tree.
|
|
242
|
-
*/var IN;function nie(){return IN||(IN=1,process.env.NODE_ENV!=="production"&&(function(){function e(l,c){return l===c&&(l!==0||1/l===1/c)||l!==l&&c!==c}typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());var t=k,n=typeof Object.is=="function"?Object.is:e,r=t.useSyncExternalStore,i=t.useRef,o=t.useEffect,a=t.useMemo,s=t.useDebugValue;yx.useSyncExternalStoreWithSelector=function(l,c,u,d,f){var p=i(null);if(p.current===null){var m={hasValue:!1,value:null};p.current=m}else m=p.current;p=a(function(){function v(E){if(!x){if(x=!0,_=E,E=d(E),f!==void 0&&m.hasValue){var S=m.value;if(f(S,E))return w=S}return w=E}if(S=w,n(_,E))return S;var P=d(E);return f!==void 0&&f(S,P)?(_=E,S):(_=E,w=P)}var x=!1,_,w,y=u===void 0?null:u;return[function(){return v(c())},y===null?void 0:function(){return v(y())}]},[c,u,d,f]);var g=r(l,p[0],p[1]);return o(function(){m.hasValue=!0,m.value=g},[g]),s(g),g},typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error())})()),yx}var FN;function rie(){return FN||(FN=1,process.env.NODE_ENV==="production"?yh.exports=tie():yh.exports=nie()),yh.exports}rie();function iie(e){e()}function oie(){let e=null,t=null;return{clear(){e=null,t=null},notify(){iie(()=>{let n=e;for(;n;)n.callback(),n=n.next})},get(){const n=[];let r=e;for(;r;)n.push(r),r=r.next;return n},subscribe(n){let r=!0;const i=t={callback:n,next:null,prev:t};return i.prev?i.prev.next=i:e=i,function(){!r||e===null||(r=!1,i.next?i.next.prev=i.prev:t=i.prev,i.prev?i.prev.next=i.next:e=i.next)}}}}var LN={notify(){},get:()=>[]};function aie(e,t){let n,r=LN,i=0,o=!1;function a(g){u();const v=r.subscribe(g);let x=!1;return()=>{x||(x=!0,v(),d())}}function s(){r.notify()}function l(){m.onStateChange&&m.onStateChange()}function c(){return o}function u(){i++,n||(n=e.subscribe(l),r=oie())}function d(){i--,n&&i===0&&(n(),n=void 0,r.clear(),r=LN)}function f(){o||(o=!0,u())}function p(){o&&(o=!1,d())}const m={addNestedSub:a,notifyNestedSubs:s,handleChangeWrapper:l,isSubscribed:c,trySubscribe:f,tryUnsubscribe:p,getListeners:()=>r};return m}var sie=()=>typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",lie=sie(),cie=()=>typeof navigator<"u"&&navigator.product==="ReactNative",uie=cie(),die=()=>lie||uie?O.useLayoutEffect:O.useEffect,fie=die(),pie=Symbol.for("react-redux-context"),hie=typeof globalThis<"u"?globalThis:{};function mie(){if(!O.createContext)return{};const e=hie[pie]??=new Map;let t=e.get(O.createContext);return t||(t=O.createContext(null),process.env.NODE_ENV!=="production"&&(t.displayName="ReactRedux"),e.set(O.createContext,t)),t}var gie=mie();function vie(e){const{children:t,context:n,serverState:r,store:i}=e,o=O.useMemo(()=>{const l=aie(i),c={store:i,subscription:l,getServerState:r?()=>r:void 0};if(process.env.NODE_ENV==="production")return c;{const{identityFunctionCheck:u="once",stabilityCheck:d="once"}=e;return Object.assign(c,{stabilityCheck:d,identityFunctionCheck:u})}},[i,r]),a=O.useMemo(()=>i.getState(),[i]);fie(()=>{const{subscription:l}=o;return l.onStateChange=l.notifyNestedSubs,l.trySubscribe(),a!==i.getState()&&l.notifyNestedSubs(),()=>{l.tryUnsubscribe(),l.onStateChange=void 0}},[o,a]);const s=n||gie;return O.createElement(s.Provider,{value:o},t)}var yie=vie,bie=(e,t)=>t,bx=H([bie,ke,ED,rn,wA,Eo,UX,en],QX),xx=e=>{var t=e.currentTarget.getBoundingClientRect(),n=t.width/e.currentTarget.offsetWidth,r=t.height/e.currentTarget.offsetHeight;return{chartX:Math.round((e.clientX-t.left)/n),chartY:Math.round((e.clientY-t.top)/r)}},RN=Hr("mouseClick"),$N=Wc();$N.startListening({actionCreator:RN,effect:(e,t)=>{var n=e.payload,r=bx(t.getState(),xx(n));r?.activeIndex!=null&&t.dispatch(tX({activeIndex:r.activeIndex,activeDataKey:void 0,activeCoordinate:r.activeCoordinate}))}});var wx=Hr("mouseMove"),BN=Wc();BN.startListening({actionCreator:wx,effect:(e,t)=>{var n=e.payload,r=t.getState(),i=p0(r,r.tooltip.settings.shared),o=bx(r,xx(n));i==="axis"&&(o?.activeIndex!=null?t.dispatch(dA({activeIndex:o.activeIndex,activeDataKey:void 0,activeCoordinate:o.activeCoordinate})):t.dispatch(uA()))}});var WN={accessibilityLayer:!0,barCategoryGap:"10%",barGap:4,barSize:void 0,className:void 0,maxBarSize:void 0,stackOffset:"none",syncId:void 0,syncMethod:"index"},zN=_r({name:"rootProps",initialState:WN,reducers:{updateOptions:(e,t)=>{var n;e.accessibilityLayer=t.payload.accessibilityLayer,e.barCategoryGap=t.payload.barCategoryGap,e.barGap=(n=t.payload.barGap)!==null&&n!==void 0?n:WN.barGap,e.barSize=t.payload.barSize,e.maxBarSize=t.payload.maxBarSize,e.stackOffset=t.payload.stackOffset,e.syncId=t.payload.syncId,e.syncMethod=t.payload.syncMethod,e.className=t.payload.className}}}),xie=zN.reducer,{updateOptions:wie}=zN.actions,VN=_r({name:"polarOptions",initialState:null,reducers:{updatePolarOptions:(e,t)=>t.payload}}),{updatePolarOptions:_ie}=VN.actions,Eie=VN.reducer,HN=Hr("keyDown"),YN=Hr("focus"),_x=Wc();_x.startListening({actionCreator:HN,effect:(e,t)=>{var n=t.getState(),r=n.rootProps.accessibilityLayer!==!1;if(r){var{keyboardInteraction:i}=n.tooltip,o=e.payload;if(!(o!=="ArrowRight"&&o!=="ArrowLeft"&&o!=="Enter")){var a=Number(g0(i,wl(n))),s=Eo(n);if(o==="Enter"){var l=Xp(n,"axis","hover",String(i.index));t.dispatch(m0({active:!i.active,activeIndex:i.index,activeDataKey:i.dataKey,activeCoordinate:l}));return}var c=UG(n),u=c==="left-to-right"?1:-1,d=o==="ArrowRight"?1:-1,f=a+d*u;if(!(s==null||f>=s.length||f<0)){var p=Xp(n,"axis","hover",String(f));t.dispatch(m0({active:!0,activeIndex:f.toString(),activeDataKey:void 0,activeCoordinate:p}))}}}}}),_x.startListening({actionCreator:YN,effect:(e,t)=>{var n=t.getState(),r=n.rootProps.accessibilityLayer!==!1;if(r){var{keyboardInteraction:i}=n.tooltip;if(!i.active&&i.index==null){var o="0",a=Xp(n,"axis","hover",String(o));t.dispatch(m0({activeDataKey:void 0,active:!0,activeIndex:o,activeCoordinate:a}))}}}});var Gr=Hr("externalEvent"),UN=Wc();UN.startListening({actionCreator:Gr,effect:(e,t)=>{if(e.payload.handler!=null){var n=t.getState(),r={activeCoordinate:LX(n),activeDataKey:OA(n),activeIndex:sa(n),activeLabel:SA(n),activeTooltipIndex:sa(n),isTooltipActive:RX(n)};e.payload.handler(r,e.payload.reactEvent)}}});var Sie=H([xl],e=>e.tooltipItemPayloads),Oie=H([Sie,gu,(e,t,n)=>t,(e,t,n)=>n],(e,t,n,r)=>{var i=e.find(s=>s.settings.dataKey===r);if(i!=null){var{positions:o}=i;if(o!=null){var a=t(o,n);return a}}}),KN=Hr("touchMove"),qN=Wc();qN.startListening({actionCreator:KN,effect:(e,t)=>{var n=e.payload,r=t.getState(),i=p0(r,r.tooltip.settings.shared);if(i==="axis"){var o=bx(r,xx({clientX:n.touches[0].clientX,clientY:n.touches[0].clientY,currentTarget:n.currentTarget}));o?.activeIndex!=null&&t.dispatch(dA({activeIndex:o.activeIndex,activeDataKey:void 0,activeCoordinate:o.activeCoordinate}))}else if(i==="item"){var a,s=n.touches[0],l=document.elementFromPoint(s.clientX,s.clientY);if(!l||!l.getAttribute)return;var c=l.getAttribute(GC),u=(a=l.getAttribute(XC))!==null&&a!==void 0?a:void 0,d=Oie(t.getState(),c,u);t.dispatch(cA({activeDataKey:u,activeIndex:c,activeCoordinate:d}))}}});var Cie=ZO({brush:kte,cartesianAxis:lee,chartData:pQ,errorBars:Cee,graphicalItems:kJ,layout:GH,legend:RY,options:lQ,polarAxis:HZ,polarOptions:Eie,referenceElements:Rte,rootProps:xie,tooltip:nX}),kie=function(t){return xH({reducer:Cie,preloadedState:t,middleware:n=>n({serializableCheck:!1}).concat([$N.middleware,BN.middleware,_x.middleware,UN.middleware,qN.middleware]),devTools:ho.devToolsEnabled})};function GN(e){var{preloadedState:t,children:n,reduxStoreName:r}=e,i=En(),o=k.useRef(null);if(i)return n;o.current==null&&(o.current=kie(t));var a=dy;return O.createElement(yie,{context:a,store:o.current},n)}function XN(e){var{layout:t,width:n,height:r,margin:i}=e,o=wt(),a=En();return k.useEffect(()=>{a||(o(UH(t)),o(KH({width:n,height:r})),o(YH(i)))},[o,a,t,n,r,i]),null}function QN(e){var t=wt();return k.useEffect(()=>{t(wie(e))},[t,e]),null}var Pie=["children"];function Die(e,t){if(e==null)return{};var n,r,i=Aie(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Aie(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}function bh(){return bh=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},bh.apply(null,arguments)}var Tie={width:"100%",height:"100%"},Nie=k.forwardRef((e,t)=>{var n=Ry(),r=$y(),i=sk();if(!il(n)||!il(r))return null;var{children:o,otherAttributes:a,title:s,desc:l}=e,c,u;return typeof a.tabIndex=="number"?c=a.tabIndex:c=i?0:void 0,typeof a.role=="string"?u=a.role:u=i?"application":void 0,O.createElement(mv,bh({},a,{title:s,desc:l,role:u,tabIndex:c,width:n,height:r,style:Tie,ref:t}),o)}),jie=e=>{var{children:t}=e,n=pe(up);if(!n)return null;var{width:r,height:i,y:o,x:a}=n;return O.createElement(mv,{width:r,height:i,x:a,y:o},t)},ZN=k.forwardRef((e,t)=>{var{children:n}=e,r=Die(e,Pie),i=En();return i?O.createElement(jie,null,n):O.createElement(Nie,bh({ref:t},r),n)});function Mie(){var e=wt(),[t,n]=k.useState(null),r=pe(EY);return k.useEffect(()=>{if(t!=null){var i=t.getBoundingClientRect(),o=i.width/t.offsetWidth;Sn(o)&&o!==r&&e(qH(o))}},[t,e,r]),n}function JN(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Iie(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?JN(Object(n),!0).forEach(function(r){Fie(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):JN(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Fie(e,t,n){return(t=Lie(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Lie(e){var t=Rie(e,"string");return typeof t=="symbol"?t:t+""}function Rie(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var $ie=k.forwardRef((e,t)=>{var{children:n,className:r,height:i,onClick:o,onContextMenu:a,onDoubleClick:s,onMouseDown:l,onMouseEnter:c,onMouseLeave:u,onMouseMove:d,onMouseUp:f,onTouchEnd:p,onTouchMove:m,onTouchStart:g,style:v,width:x}=e,_=wt(),[w,y]=k.useState(null),[E,S]=k.useState(null);_Q();var P=Mie(),D=k.useCallback(X=>{P(X),typeof t=="function"&&t(X),y(X),S(X)},[P,t,y,S]),T=k.useCallback(X=>{_(RN(X)),_(Gr({handler:o,reactEvent:X}))},[_,o]),I=k.useCallback(X=>{_(wx(X)),_(Gr({handler:c,reactEvent:X}))},[_,c]),A=k.useCallback(X=>{_(uA()),_(Gr({handler:u,reactEvent:X}))},[_,u]),C=k.useCallback(X=>{_(wx(X)),_(Gr({handler:d,reactEvent:X}))},[_,d]),j=k.useCallback(()=>{_(YN())},[_]),N=k.useCallback(X=>{_(HN(X.key))},[_]),M=k.useCallback(X=>{_(Gr({handler:a,reactEvent:X}))},[_,a]),R=k.useCallback(X=>{_(Gr({handler:s,reactEvent:X}))},[_,s]),B=k.useCallback(X=>{_(Gr({handler:l,reactEvent:X}))},[_,l]),V=k.useCallback(X=>{_(Gr({handler:f,reactEvent:X}))},[_,f]),z=k.useCallback(X=>{_(Gr({handler:g,reactEvent:X}))},[_,g]),W=k.useCallback(X=>{_(KN(X)),_(Gr({handler:m,reactEvent:X}))},[_,m]),Q=k.useCallback(X=>{_(Gr({handler:p,reactEvent:X}))},[_,p]);return O.createElement(IA.Provider,{value:w},O.createElement(v2.Provider,{value:E},O.createElement("div",{className:ue("recharts-wrapper",r),style:Iie({position:"relative",cursor:"default",width:x,height:i},v),onClick:T,onContextMenu:M,onDoubleClick:R,onFocus:j,onKeyDown:N,onMouseDown:B,onMouseEnter:I,onMouseLeave:A,onMouseMove:C,onMouseUp:V,onTouchEnd:Q,onTouchMove:W,onTouchStart:z,ref:D},n)))}),Bie=["children","className","width","height","style","compact","title","desc"];function Wie(e,t){if(e==null)return{};var n,r,i=zie(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function zie(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}var ej=k.forwardRef((e,t)=>{var{children:n,className:r,width:i,height:o,style:a,compact:s,title:l,desc:c}=e,u=Wie(e,Bie),d=Br(u);return s?O.createElement(ZN,{otherAttributes:d,title:l,desc:c},n):O.createElement($ie,{className:r,style:a,width:i,height:o,onClick:e.onClick,onMouseLeave:e.onMouseLeave,onMouseEnter:e.onMouseEnter,onMouseMove:e.onMouseMove,onMouseDown:e.onMouseDown,onMouseUp:e.onMouseUp,onContextMenu:e.onContextMenu,onDoubleClick:e.onDoubleClick,onTouchStart:e.onTouchStart,onTouchMove:e.onTouchMove,onTouchEnd:e.onTouchEnd},O.createElement(ZN,{otherAttributes:d,title:l,desc:c,ref:t},O.createElement($te,null,n)))}),Vie=["width","height"];function Ex(){return Ex=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ex.apply(null,arguments)}function Hie(e,t){if(e==null)return{};var n,r,i=Yie(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Yie(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}var Uie={top:5,right:5,bottom:5,left:5},Kie={accessibilityLayer:!0,layout:"horizontal",stackOffset:"none",barCategoryGap:"10%",barGap:4,margin:Uie,reverseStackOrder:!1,syncMethod:"index"},Sx=k.forwardRef(function(t,n){var r,i=tn(t.categoricalChartProps,Kie),{width:o,height:a}=i,s=Hie(i,Vie);if(!il(o)||!il(a))return null;var{chartName:l,defaultTooltipEventType:c,validateTooltipEventTypes:u,tooltipPayloadSearcher:d,categoricalChartProps:f}=t,p={chartName:l,defaultTooltipEventType:c,validateTooltipEventTypes:u,tooltipPayloadSearcher:d,eventEmitter:void 0};return O.createElement(GN,{preloadedState:{options:p},reduxStoreName:(r=f.id)!==null&&r!==void 0?r:l},O.createElement(rN,{chartData:f.data}),O.createElement(XN,{width:o,height:a,layout:i.layout,margin:i.margin}),O.createElement(QN,{accessibilityLayer:i.accessibilityLayer,barCategoryGap:i.barCategoryGap,maxBarSize:i.maxBarSize,stackOffset:i.stackOffset,barGap:i.barGap,barSize:i.barSize,syncId:i.syncId,syncMethod:i.syncMethod,className:i.className}),O.createElement(ej,Ex({},s,{width:o,height:a,ref:n})))}),qie=["axis"],Ox=k.forwardRef((e,t)=>O.createElement(Sx,{chartName:"LineChart",defaultTooltipEventType:"axis",validateTooltipEventTypes:qie,tooltipPayloadSearcher:Zp,categoricalChartProps:e,ref:t})),Gie=["axis","item"],ko=k.forwardRef((e,t)=>O.createElement(Sx,{chartName:"BarChart",defaultTooltipEventType:"axis",validateTooltipEventTypes:Gie,tooltipPayloadSearcher:Zp,categoricalChartProps:e,ref:t}));function Xie(e){var t=wt();return k.useEffect(()=>{t(_ie(e))},[t,e]),null}var Qie=["width","height","layout"];function Cx(){return Cx=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Cx.apply(null,arguments)}function Zie(e,t){if(e==null)return{};var n,r,i=Jie(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Jie(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}var eoe={top:5,right:5,bottom:5,left:5},toe={accessibilityLayer:!0,stackOffset:"none",barCategoryGap:"10%",barGap:4,margin:eoe,reverseStackOrder:!1,syncMethod:"index",layout:"radial"},noe=k.forwardRef(function(t,n){var r,i=tn(t.categoricalChartProps,toe),{width:o,height:a,layout:s}=i,l=Zie(i,Qie);if(!il(o)||!il(a))return null;var{chartName:c,defaultTooltipEventType:u,validateTooltipEventTypes:d,tooltipPayloadSearcher:f}=t,p={chartName:c,defaultTooltipEventType:u,validateTooltipEventTypes:d,tooltipPayloadSearcher:f,eventEmitter:void 0};return O.createElement(GN,{preloadedState:{options:p},reduxStoreName:(r=i.id)!==null&&r!==void 0?r:c},O.createElement(rN,{chartData:i.data}),O.createElement(XN,{width:o,height:a,layout:s,margin:i.margin}),O.createElement(QN,{accessibilityLayer:i.accessibilityLayer,barCategoryGap:i.barCategoryGap,maxBarSize:i.maxBarSize,stackOffset:i.stackOffset,barGap:i.barGap,barSize:i.barSize,syncId:i.syncId,syncMethod:i.syncMethod,className:i.className}),O.createElement(Xie,{cx:i.cx,cy:i.cy,startAngle:i.startAngle,endAngle:i.endAngle,innerRadius:i.innerRadius,outerRadius:i.outerRadius}),O.createElement(ej,Cx({width:o,height:a},l,{ref:n})))}),roe=["item"],ioe={layout:"centric",startAngle:0,endAngle:360,cx:"50%",cy:"50%",innerRadius:0,outerRadius:"80%"},$i=k.forwardRef((e,t)=>{var n=tn(e,ioe);return O.createElement(noe,{chartName:"PieChart",defaultTooltipEventType:"item",validateTooltipEventTypes:roe,tooltipPayloadSearcher:Zp,categoricalChartProps:n,ref:t})}),ooe=["axis"],tj=k.forwardRef((e,t)=>O.createElement(Sx,{chartName:"AreaChart",defaultTooltipEventType:"axis",validateTooltipEventTypes:ooe,tooltipPayloadSearcher:Zp,categoricalChartProps:e,ref:t}));function Sl(e,t){return process.env.NODE_ENV==="production"?()=>null:function(...r){return e(...r)||t(...r)}}function aoe(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}function kx(e,t){return kx=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,r){return n.__proto__=r,n},kx(e,t)}function soe(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,kx(e,t)}const nj={disabled:!1};var loe=process.env.NODE_ENV!=="production"?b.oneOfType([b.number,b.shape({enter:b.number,exit:b.number,appear:b.number}).isRequired]):null;process.env.NODE_ENV!=="production"&&b.oneOfType([b.string,b.shape({enter:b.string,exit:b.string,active:b.string}),b.shape({enter:b.string,enterDone:b.string,enterActive:b.string,exit:b.string,exitDone:b.string,exitActive:b.string})]);const rj=k.createContext(null);var coe=function(t){return t.scrollTop},Eu="unmounted",os="exited",as="entering",Ol="entered",Px="exiting",Bi=(function(e){soe(t,e);function t(r,i){var o;o=e.call(this,r,i)||this;var a=i,s=a&&!a.isMounting?r.enter:r.appear,l;return o.appearStatus=null,r.in?s?(l=os,o.appearStatus=as):l=Ol:r.unmountOnExit||r.mountOnEnter?l=Eu:l=os,o.state={status:l},o.nextCallback=null,o}t.getDerivedStateFromProps=function(i,o){var a=i.in;return a&&o.status===Eu?{status:os}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(i){var o=null;if(i!==this.props){var a=this.state.status;this.props.in?a!==as&&a!==Ol&&(o=as):(a===as||a===Ol)&&(o=Px)}this.updateStatus(!1,o)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var i=this.props.timeout,o,a,s;return o=a=s=i,i!=null&&typeof i!="number"&&(o=i.exit,a=i.enter,s=i.appear!==void 0?i.appear:a),{exit:o,enter:a,appear:s}},n.updateStatus=function(i,o){if(i===void 0&&(i=!1),o!==null)if(this.cancelNextCallback(),o===as){if(this.props.unmountOnExit||this.props.mountOnEnter){var a=this.props.nodeRef?this.props.nodeRef.current:fi.findDOMNode(this);a&&coe(a)}this.performEnter(i)}else this.performExit();else this.props.unmountOnExit&&this.state.status===os&&this.setState({status:Eu})},n.performEnter=function(i){var o=this,a=this.props.enter,s=this.context?this.context.isMounting:i,l=this.props.nodeRef?[s]:[fi.findDOMNode(this),s],c=l[0],u=l[1],d=this.getTimeouts(),f=s?d.appear:d.enter;if(!i&&!a||nj.disabled){this.safeSetState({status:Ol},function(){o.props.onEntered(c)});return}this.props.onEnter(c,u),this.safeSetState({status:as},function(){o.props.onEntering(c,u),o.onTransitionEnd(f,function(){o.safeSetState({status:Ol},function(){o.props.onEntered(c,u)})})})},n.performExit=function(){var i=this,o=this.props.exit,a=this.getTimeouts(),s=this.props.nodeRef?void 0:fi.findDOMNode(this);if(!o||nj.disabled){this.safeSetState({status:os},function(){i.props.onExited(s)});return}this.props.onExit(s),this.safeSetState({status:Px},function(){i.props.onExiting(s),i.onTransitionEnd(a.exit,function(){i.safeSetState({status:os},function(){i.props.onExited(s)})})})},n.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(i,o){o=this.setNextCallback(o),this.setState(i,o)},n.setNextCallback=function(i){var o=this,a=!0;return this.nextCallback=function(s){a&&(a=!1,o.nextCallback=null,i(s))},this.nextCallback.cancel=function(){a=!1},this.nextCallback},n.onTransitionEnd=function(i,o){this.setNextCallback(o);var a=this.props.nodeRef?this.props.nodeRef.current:fi.findDOMNode(this),s=i==null&&!this.props.addEndListener;if(!a||s){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var l=this.props.nodeRef?[this.nextCallback]:[a,this.nextCallback],c=l[0],u=l[1];this.props.addEndListener(c,u)}i!=null&&setTimeout(this.nextCallback,i)},n.render=function(){var i=this.state.status;if(i===Eu)return null;var o=this.props,a=o.children;o.in,o.mountOnEnter,o.unmountOnExit,o.appear,o.enter,o.exit,o.timeout,o.addEndListener,o.onEnter,o.onEntering,o.onEntered,o.onExit,o.onExiting,o.onExited,o.nodeRef;var s=aoe(o,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return k.createElement(rj.Provider,{value:null},typeof a=="function"?a(i,s):k.cloneElement(k.Children.only(a),s))},t})(k.Component);Bi.contextType=rj,Bi.propTypes=process.env.NODE_ENV!=="production"?{nodeRef:b.shape({current:typeof Element>"u"?b.any:function(e,t,n,r,i,o){var a=e[t];return b.instanceOf(a&&"ownerDocument"in a?a.ownerDocument.defaultView.Element:Element)(e,t,n,r,i,o)}}),children:b.oneOfType([b.func.isRequired,b.element.isRequired]).isRequired,in:b.bool,mountOnEnter:b.bool,unmountOnExit:b.bool,appear:b.bool,enter:b.bool,exit:b.bool,timeout:function(t){var n=loe;t.addEndListener||(n=n.isRequired);for(var r=arguments.length,i=new Array(r>1?r-1:0),o=1;o<r;o++)i[o-1]=arguments[o];return n.apply(void 0,[t].concat(i))},addEndListener:b.func,onEnter:b.func,onEntering:b.func,onEntered:b.func,onExit:b.func,onExiting:b.func,onExited:b.func}:{};function Cl(){}Bi.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:Cl,onEntering:Cl,onEntered:Cl,onExit:Cl,onExiting:Cl,onExited:Cl},Bi.UNMOUNTED=Eu,Bi.EXITED=os,Bi.ENTERING=as,Bi.ENTERED=Ol,Bi.EXITING=Px;const ij={};function uoe(e,t){const n=O.useRef(ij);return n.current===ij&&(n.current=e(t)),n}const doe=[];function foe(e){O.useEffect(e,doe)}class xh{static create(){return new xh}currentId=null;start(t,n){this.clear(),this.currentId=setTimeout(()=>{this.currentId=null,n()},t)}clear=()=>{this.currentId!==null&&(clearTimeout(this.currentId),this.currentId=null)};disposeEffect=()=>this.clear}function Su(){const e=uoe(xh.create).current;return foe(e.disposeEffect),e}function poe(e){const{prototype:t={}}=e;return!!t.isReactComponent}function hoe(e,t,n,r,i){const o=e[t],a=i||t;if(o==null||typeof window>"u")return null;let s;return typeof o=="function"&&!poe(o)&&(s="Did you accidentally provide a plain function component instead?"),s!==void 0?new Error(`Invalid ${r} \`${a}\` supplied to \`${n}\`. Expected an element type that can hold a ref. ${s} For more information see https://mui.com/r/caveat-with-refs-guide`):null}const oj=Sl(b.elementType,hoe),aj=e=>e.scrollTop;function wh(e,t){const{timeout:n,easing:r,style:i={}}=e;return{duration:i.transitionDuration??(typeof n=="number"?n:n[t.mode]||0),easing:i.transitionTimingFunction??(typeof r=="object"?r[t.mode]:r),delay:i.transitionDelay}}function moe(e){const t=typeof e;switch(t){case"number":return Number.isNaN(e)?"NaN":Number.isFinite(e)?e!==Math.floor(e)?"float":"number":"Infinity";case"object":return e===null?"null":e.constructor.name;default:return t}}function sj(e,t,n,r){const i=e[t];if(i==null||!Number.isInteger(i)){const o=moe(i);return new RangeError(`Invalid ${r} \`${t}\` of type \`${o}\` supplied to \`${n}\`, expected \`integer\`.`)}return null}function lj(e,t,n,r){return e[t]===void 0?null:sj(e,t,n,r)}function Dx(){return null}lj.isRequired=sj,Dx.isRequired=Dx;const cj=process.env.NODE_ENV==="production"?Dx:lj;function goe(e){return xn("MuiPaper",e)}Vn("MuiPaper",["root","rounded","outlined","elevation","elevation0","elevation1","elevation2","elevation3","elevation4","elevation5","elevation6","elevation7","elevation8","elevation9","elevation10","elevation11","elevation12","elevation13","elevation14","elevation15","elevation16","elevation17","elevation18","elevation19","elevation20","elevation21","elevation22","elevation23","elevation24"]);const voe=e=>{const{square:t,elevation:n,variant:r,classes:i}=e,o={root:["root",r,!t&&"rounded",r==="elevation"&&`elevation${n}`]};return kn(o,goe,i)},yoe=De("div",{name:"MuiPaper",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,t[n.variant],!n.square&&t.rounded,n.variant==="elevation"&&t[`elevation${n.elevation}`]]}})(Hn(({theme:e})=>({backgroundColor:(e.vars||e).palette.background.paper,color:(e.vars||e).palette.text.primary,transition:e.transitions.create("box-shadow"),variants:[{props:({ownerState:t})=>!t.square,style:{borderRadius:e.shape.borderRadius}},{props:{variant:"outlined"},style:{border:`1px solid ${(e.vars||e).palette.divider}`}},{props:{variant:"elevation"},style:{boxShadow:"var(--Paper-shadow)",backgroundImage:"var(--Paper-overlay)"}}]}))),uj=O.forwardRef(function(t,n){const r=Zn({props:t,name:"MuiPaper"}),i=Id(),{className:o,component:a="div",elevation:s=1,square:l=!1,variant:c="elevation",...u}=r,d={...r,component:a,elevation:s,square:l,variant:c},f=voe(d);return process.env.NODE_ENV!=="production"&&i.shadows[s]===void 0&&console.error([`MUI: The elevation provided <Paper elevation={${s}}> is not available in the theme.`,`Please make sure that \`theme.shadows[${s}]\` is defined.`].join(`
|
|
242
|
+
*/var IN;function nie(){return IN||(IN=1,process.env.NODE_ENV!=="production"&&(function(){function e(l,c){return l===c&&(l!==0||1/l===1/c)||l!==l&&c!==c}typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());var t=k,n=typeof Object.is=="function"?Object.is:e,r=t.useSyncExternalStore,i=t.useRef,o=t.useEffect,a=t.useMemo,s=t.useDebugValue;yx.useSyncExternalStoreWithSelector=function(l,c,u,d,f){var p=i(null);if(p.current===null){var m={hasValue:!1,value:null};p.current=m}else m=p.current;p=a(function(){function v(E){if(!x){if(x=!0,_=E,E=d(E),f!==void 0&&m.hasValue){var S=m.value;if(f(S,E))return w=S}return w=E}if(S=w,n(_,E))return S;var P=d(E);return f!==void 0&&f(S,P)?(_=E,S):(_=E,w=P)}var x=!1,_,w,y=u===void 0?null:u;return[function(){return v(c())},y===null?void 0:function(){return v(y())}]},[c,u,d,f]);var g=r(l,p[0],p[1]);return o(function(){m.hasValue=!0,m.value=g},[g]),s(g),g},typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"&&typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop=="function"&&__REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error())})()),yx}var FN;function rie(){return FN||(FN=1,process.env.NODE_ENV==="production"?yh.exports=tie():yh.exports=nie()),yh.exports}rie();function iie(e){e()}function oie(){let e=null,t=null;return{clear(){e=null,t=null},notify(){iie(()=>{let n=e;for(;n;)n.callback(),n=n.next})},get(){const n=[];let r=e;for(;r;)n.push(r),r=r.next;return n},subscribe(n){let r=!0;const i=t={callback:n,next:null,prev:t};return i.prev?i.prev.next=i:e=i,function(){!r||e===null||(r=!1,i.next?i.next.prev=i.prev:t=i.prev,i.prev?i.prev.next=i.next:e=i.next)}}}}var LN={notify(){},get:()=>[]};function aie(e,t){let n,r=LN,i=0,o=!1;function a(g){u();const v=r.subscribe(g);let x=!1;return()=>{x||(x=!0,v(),d())}}function s(){r.notify()}function l(){m.onStateChange&&m.onStateChange()}function c(){return o}function u(){i++,n||(n=e.subscribe(l),r=oie())}function d(){i--,n&&i===0&&(n(),n=void 0,r.clear(),r=LN)}function f(){o||(o=!0,u())}function p(){o&&(o=!1,d())}const m={addNestedSub:a,notifyNestedSubs:s,handleChangeWrapper:l,isSubscribed:c,trySubscribe:f,tryUnsubscribe:p,getListeners:()=>r};return m}var sie=()=>typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",lie=sie(),cie=()=>typeof navigator<"u"&&navigator.product==="ReactNative",uie=cie(),die=()=>lie||uie?O.useLayoutEffect:O.useEffect,fie=die(),pie=Symbol.for("react-redux-context"),hie=typeof globalThis<"u"?globalThis:{};function mie(){if(!O.createContext)return{};const e=hie[pie]??=new Map;let t=e.get(O.createContext);return t||(t=O.createContext(null),process.env.NODE_ENV!=="production"&&(t.displayName="ReactRedux"),e.set(O.createContext,t)),t}var gie=mie();function vie(e){const{children:t,context:n,serverState:r,store:i}=e,o=O.useMemo(()=>{const l=aie(i),c={store:i,subscription:l,getServerState:r?()=>r:void 0};if(process.env.NODE_ENV==="production")return c;{const{identityFunctionCheck:u="once",stabilityCheck:d="once"}=e;return Object.assign(c,{stabilityCheck:d,identityFunctionCheck:u})}},[i,r]),a=O.useMemo(()=>i.getState(),[i]);fie(()=>{const{subscription:l}=o;return l.onStateChange=l.notifyNestedSubs,l.trySubscribe(),a!==i.getState()&&l.notifyNestedSubs(),()=>{l.tryUnsubscribe(),l.onStateChange=void 0}},[o,a]);const s=n||gie;return O.createElement(s.Provider,{value:o},t)}var yie=vie,bie=(e,t)=>t,bx=H([bie,ke,ED,rn,wA,Eo,UX,en],QX),xx=e=>{var t=e.currentTarget.getBoundingClientRect(),n=t.width/e.currentTarget.offsetWidth,r=t.height/e.currentTarget.offsetHeight;return{chartX:Math.round((e.clientX-t.left)/n),chartY:Math.round((e.clientY-t.top)/r)}},RN=Hr("mouseClick"),$N=Wc();$N.startListening({actionCreator:RN,effect:(e,t)=>{var n=e.payload,r=bx(t.getState(),xx(n));r?.activeIndex!=null&&t.dispatch(tX({activeIndex:r.activeIndex,activeDataKey:void 0,activeCoordinate:r.activeCoordinate}))}});var wx=Hr("mouseMove"),BN=Wc();BN.startListening({actionCreator:wx,effect:(e,t)=>{var n=e.payload,r=t.getState(),i=p0(r,r.tooltip.settings.shared),o=bx(r,xx(n));i==="axis"&&(o?.activeIndex!=null?t.dispatch(dA({activeIndex:o.activeIndex,activeDataKey:void 0,activeCoordinate:o.activeCoordinate})):t.dispatch(uA()))}});var WN={accessibilityLayer:!0,barCategoryGap:"10%",barGap:4,barSize:void 0,className:void 0,maxBarSize:void 0,stackOffset:"none",syncId:void 0,syncMethod:"index"},zN=_r({name:"rootProps",initialState:WN,reducers:{updateOptions:(e,t)=>{var n;e.accessibilityLayer=t.payload.accessibilityLayer,e.barCategoryGap=t.payload.barCategoryGap,e.barGap=(n=t.payload.barGap)!==null&&n!==void 0?n:WN.barGap,e.barSize=t.payload.barSize,e.maxBarSize=t.payload.maxBarSize,e.stackOffset=t.payload.stackOffset,e.syncId=t.payload.syncId,e.syncMethod=t.payload.syncMethod,e.className=t.payload.className}}}),xie=zN.reducer,{updateOptions:wie}=zN.actions,VN=_r({name:"polarOptions",initialState:null,reducers:{updatePolarOptions:(e,t)=>t.payload}}),{updatePolarOptions:_ie}=VN.actions,Eie=VN.reducer,HN=Hr("keyDown"),YN=Hr("focus"),_x=Wc();_x.startListening({actionCreator:HN,effect:(e,t)=>{var n=t.getState(),r=n.rootProps.accessibilityLayer!==!1;if(r){var{keyboardInteraction:i}=n.tooltip,o=e.payload;if(!(o!=="ArrowRight"&&o!=="ArrowLeft"&&o!=="Enter")){var a=Number(g0(i,wl(n))),s=Eo(n);if(o==="Enter"){var l=Xp(n,"axis","hover",String(i.index));t.dispatch(m0({active:!i.active,activeIndex:i.index,activeDataKey:i.dataKey,activeCoordinate:l}));return}var c=UG(n),u=c==="left-to-right"?1:-1,d=o==="ArrowRight"?1:-1,f=a+d*u;if(!(s==null||f>=s.length||f<0)){var p=Xp(n,"axis","hover",String(f));t.dispatch(m0({active:!0,activeIndex:f.toString(),activeDataKey:void 0,activeCoordinate:p}))}}}}}),_x.startListening({actionCreator:YN,effect:(e,t)=>{var n=t.getState(),r=n.rootProps.accessibilityLayer!==!1;if(r){var{keyboardInteraction:i}=n.tooltip;if(!i.active&&i.index==null){var o="0",a=Xp(n,"axis","hover",String(o));t.dispatch(m0({activeDataKey:void 0,active:!0,activeIndex:o,activeCoordinate:a}))}}}});var Gr=Hr("externalEvent"),UN=Wc();UN.startListening({actionCreator:Gr,effect:(e,t)=>{if(e.payload.handler!=null){var n=t.getState(),r={activeCoordinate:LX(n),activeDataKey:OA(n),activeIndex:sa(n),activeLabel:SA(n),activeTooltipIndex:sa(n),isTooltipActive:RX(n)};e.payload.handler(r,e.payload.reactEvent)}}});var Sie=H([xl],e=>e.tooltipItemPayloads),Oie=H([Sie,gu,(e,t,n)=>t,(e,t,n)=>n],(e,t,n,r)=>{var i=e.find(s=>s.settings.dataKey===r);if(i!=null){var{positions:o}=i;if(o!=null){var a=t(o,n);return a}}}),KN=Hr("touchMove"),qN=Wc();qN.startListening({actionCreator:KN,effect:(e,t)=>{var n=e.payload,r=t.getState(),i=p0(r,r.tooltip.settings.shared);if(i==="axis"){var o=bx(r,xx({clientX:n.touches[0].clientX,clientY:n.touches[0].clientY,currentTarget:n.currentTarget}));o?.activeIndex!=null&&t.dispatch(dA({activeIndex:o.activeIndex,activeDataKey:void 0,activeCoordinate:o.activeCoordinate}))}else if(i==="item"){var a,s=n.touches[0],l=document.elementFromPoint(s.clientX,s.clientY);if(!l||!l.getAttribute)return;var c=l.getAttribute(GC),u=(a=l.getAttribute(XC))!==null&&a!==void 0?a:void 0,d=Oie(t.getState(),c,u);t.dispatch(cA({activeDataKey:u,activeIndex:c,activeCoordinate:d}))}}});var Cie=ZO({brush:kte,cartesianAxis:lee,chartData:pQ,errorBars:Cee,graphicalItems:kJ,layout:GH,legend:RY,options:lQ,polarAxis:HZ,polarOptions:Eie,referenceElements:Rte,rootProps:xie,tooltip:nX}),kie=function(t){return xH({reducer:Cie,preloadedState:t,middleware:n=>n({serializableCheck:!1}).concat([$N.middleware,BN.middleware,_x.middleware,UN.middleware,qN.middleware]),devTools:ho.devToolsEnabled})};function GN(e){var{preloadedState:t,children:n,reduxStoreName:r}=e,i=En(),o=k.useRef(null);if(i)return n;o.current==null&&(o.current=kie(t));var a=dy;return O.createElement(yie,{context:a,store:o.current},n)}function XN(e){var{layout:t,width:n,height:r,margin:i}=e,o=wt(),a=En();return k.useEffect(()=>{a||(o(UH(t)),o(KH({width:n,height:r})),o(YH(i)))},[o,a,t,n,r,i]),null}function QN(e){var t=wt();return k.useEffect(()=>{t(wie(e))},[t,e]),null}var Pie=["children"];function Die(e,t){if(e==null)return{};var n,r,i=Aie(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Aie(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}function bh(){return bh=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},bh.apply(null,arguments)}var Tie={width:"100%",height:"100%"},Nie=k.forwardRef((e,t)=>{var n=Ry(),r=$y(),i=sk();if(!il(n)||!il(r))return null;var{children:o,otherAttributes:a,title:s,desc:l}=e,c,u;return typeof a.tabIndex=="number"?c=a.tabIndex:c=i?0:void 0,typeof a.role=="string"?u=a.role:u=i?"application":void 0,O.createElement(mv,bh({},a,{title:s,desc:l,role:u,tabIndex:c,width:n,height:r,style:Tie,ref:t}),o)}),jie=e=>{var{children:t}=e,n=pe(up);if(!n)return null;var{width:r,height:i,y:o,x:a}=n;return O.createElement(mv,{width:r,height:i,x:a,y:o},t)},ZN=k.forwardRef((e,t)=>{var{children:n}=e,r=Die(e,Pie),i=En();return i?O.createElement(jie,null,n):O.createElement(Nie,bh({ref:t},r),n)});function Mie(){var e=wt(),[t,n]=k.useState(null),r=pe(EY);return k.useEffect(()=>{if(t!=null){var i=t.getBoundingClientRect(),o=i.width/t.offsetWidth;Sn(o)&&o!==r&&e(qH(o))}},[t,e,r]),n}function JN(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),n.push.apply(n,r)}return n}function Iie(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?JN(Object(n),!0).forEach(function(r){Fie(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):JN(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function Fie(e,t,n){return(t=Lie(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Lie(e){var t=Rie(e,"string");return typeof t=="symbol"?t:t+""}function Rie(e,t){if(typeof e!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var $ie=k.forwardRef((e,t)=>{var{children:n,className:r,height:i,onClick:o,onContextMenu:a,onDoubleClick:s,onMouseDown:l,onMouseEnter:c,onMouseLeave:u,onMouseMove:d,onMouseUp:f,onTouchEnd:p,onTouchMove:m,onTouchStart:g,style:v,width:x}=e,_=wt(),[w,y]=k.useState(null),[E,S]=k.useState(null);_Q();var P=Mie(),D=k.useCallback(G=>{P(G),typeof t=="function"&&t(G),y(G),S(G)},[P,t,y,S]),T=k.useCallback(G=>{_(RN(G)),_(Gr({handler:o,reactEvent:G}))},[_,o]),I=k.useCallback(G=>{_(wx(G)),_(Gr({handler:c,reactEvent:G}))},[_,c]),A=k.useCallback(G=>{_(uA()),_(Gr({handler:u,reactEvent:G}))},[_,u]),C=k.useCallback(G=>{_(wx(G)),_(Gr({handler:d,reactEvent:G}))},[_,d]),j=k.useCallback(()=>{_(YN())},[_]),N=k.useCallback(G=>{_(HN(G.key))},[_]),M=k.useCallback(G=>{_(Gr({handler:a,reactEvent:G}))},[_,a]),R=k.useCallback(G=>{_(Gr({handler:s,reactEvent:G}))},[_,s]),B=k.useCallback(G=>{_(Gr({handler:l,reactEvent:G}))},[_,l]),V=k.useCallback(G=>{_(Gr({handler:f,reactEvent:G}))},[_,f]),z=k.useCallback(G=>{_(Gr({handler:g,reactEvent:G}))},[_,g]),W=k.useCallback(G=>{_(KN(G)),_(Gr({handler:m,reactEvent:G}))},[_,m]),Q=k.useCallback(G=>{_(Gr({handler:p,reactEvent:G}))},[_,p]);return O.createElement(IA.Provider,{value:w},O.createElement(v2.Provider,{value:E},O.createElement("div",{className:ue("recharts-wrapper",r),style:Iie({position:"relative",cursor:"default",width:x,height:i},v),onClick:T,onContextMenu:M,onDoubleClick:R,onFocus:j,onKeyDown:N,onMouseDown:B,onMouseEnter:I,onMouseLeave:A,onMouseMove:C,onMouseUp:V,onTouchEnd:Q,onTouchMove:W,onTouchStart:z,ref:D},n)))}),Bie=["children","className","width","height","style","compact","title","desc"];function Wie(e,t){if(e==null)return{};var n,r,i=zie(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function zie(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}var ej=k.forwardRef((e,t)=>{var{children:n,className:r,width:i,height:o,style:a,compact:s,title:l,desc:c}=e,u=Wie(e,Bie),d=Br(u);return s?O.createElement(ZN,{otherAttributes:d,title:l,desc:c},n):O.createElement($ie,{className:r,style:a,width:i,height:o,onClick:e.onClick,onMouseLeave:e.onMouseLeave,onMouseEnter:e.onMouseEnter,onMouseMove:e.onMouseMove,onMouseDown:e.onMouseDown,onMouseUp:e.onMouseUp,onContextMenu:e.onContextMenu,onDoubleClick:e.onDoubleClick,onTouchStart:e.onTouchStart,onTouchMove:e.onTouchMove,onTouchEnd:e.onTouchEnd},O.createElement(ZN,{otherAttributes:d,title:l,desc:c,ref:t},O.createElement($te,null,n)))}),Vie=["width","height"];function Ex(){return Ex=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ex.apply(null,arguments)}function Hie(e,t){if(e==null)return{};var n,r,i=Yie(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Yie(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}var Uie={top:5,right:5,bottom:5,left:5},Kie={accessibilityLayer:!0,layout:"horizontal",stackOffset:"none",barCategoryGap:"10%",barGap:4,margin:Uie,reverseStackOrder:!1,syncMethod:"index"},Sx=k.forwardRef(function(t,n){var r,i=tn(t.categoricalChartProps,Kie),{width:o,height:a}=i,s=Hie(i,Vie);if(!il(o)||!il(a))return null;var{chartName:l,defaultTooltipEventType:c,validateTooltipEventTypes:u,tooltipPayloadSearcher:d,categoricalChartProps:f}=t,p={chartName:l,defaultTooltipEventType:c,validateTooltipEventTypes:u,tooltipPayloadSearcher:d,eventEmitter:void 0};return O.createElement(GN,{preloadedState:{options:p},reduxStoreName:(r=f.id)!==null&&r!==void 0?r:l},O.createElement(rN,{chartData:f.data}),O.createElement(XN,{width:o,height:a,layout:i.layout,margin:i.margin}),O.createElement(QN,{accessibilityLayer:i.accessibilityLayer,barCategoryGap:i.barCategoryGap,maxBarSize:i.maxBarSize,stackOffset:i.stackOffset,barGap:i.barGap,barSize:i.barSize,syncId:i.syncId,syncMethod:i.syncMethod,className:i.className}),O.createElement(ej,Ex({},s,{width:o,height:a,ref:n})))}),qie=["axis"],Ox=k.forwardRef((e,t)=>O.createElement(Sx,{chartName:"LineChart",defaultTooltipEventType:"axis",validateTooltipEventTypes:qie,tooltipPayloadSearcher:Zp,categoricalChartProps:e,ref:t})),Gie=["axis","item"],ko=k.forwardRef((e,t)=>O.createElement(Sx,{chartName:"BarChart",defaultTooltipEventType:"axis",validateTooltipEventTypes:Gie,tooltipPayloadSearcher:Zp,categoricalChartProps:e,ref:t}));function Xie(e){var t=wt();return k.useEffect(()=>{t(_ie(e))},[t,e]),null}var Qie=["width","height","layout"];function Cx(){return Cx=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Cx.apply(null,arguments)}function Zie(e,t){if(e==null)return{};var n,r,i=Jie(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Jie(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}var eoe={top:5,right:5,bottom:5,left:5},toe={accessibilityLayer:!0,stackOffset:"none",barCategoryGap:"10%",barGap:4,margin:eoe,reverseStackOrder:!1,syncMethod:"index",layout:"radial"},noe=k.forwardRef(function(t,n){var r,i=tn(t.categoricalChartProps,toe),{width:o,height:a,layout:s}=i,l=Zie(i,Qie);if(!il(o)||!il(a))return null;var{chartName:c,defaultTooltipEventType:u,validateTooltipEventTypes:d,tooltipPayloadSearcher:f}=t,p={chartName:c,defaultTooltipEventType:u,validateTooltipEventTypes:d,tooltipPayloadSearcher:f,eventEmitter:void 0};return O.createElement(GN,{preloadedState:{options:p},reduxStoreName:(r=i.id)!==null&&r!==void 0?r:c},O.createElement(rN,{chartData:i.data}),O.createElement(XN,{width:o,height:a,layout:s,margin:i.margin}),O.createElement(QN,{accessibilityLayer:i.accessibilityLayer,barCategoryGap:i.barCategoryGap,maxBarSize:i.maxBarSize,stackOffset:i.stackOffset,barGap:i.barGap,barSize:i.barSize,syncId:i.syncId,syncMethod:i.syncMethod,className:i.className}),O.createElement(Xie,{cx:i.cx,cy:i.cy,startAngle:i.startAngle,endAngle:i.endAngle,innerRadius:i.innerRadius,outerRadius:i.outerRadius}),O.createElement(ej,Cx({width:o,height:a},l,{ref:n})))}),roe=["item"],ioe={layout:"centric",startAngle:0,endAngle:360,cx:"50%",cy:"50%",innerRadius:0,outerRadius:"80%"},$i=k.forwardRef((e,t)=>{var n=tn(e,ioe);return O.createElement(noe,{chartName:"PieChart",defaultTooltipEventType:"item",validateTooltipEventTypes:roe,tooltipPayloadSearcher:Zp,categoricalChartProps:n,ref:t})}),ooe=["axis"],tj=k.forwardRef((e,t)=>O.createElement(Sx,{chartName:"AreaChart",defaultTooltipEventType:"axis",validateTooltipEventTypes:ooe,tooltipPayloadSearcher:Zp,categoricalChartProps:e,ref:t}));function Sl(e,t){return process.env.NODE_ENV==="production"?()=>null:function(...r){return e(...r)||t(...r)}}function aoe(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}function kx(e,t){return kx=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,r){return n.__proto__=r,n},kx(e,t)}function soe(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,kx(e,t)}const nj={disabled:!1};var loe=process.env.NODE_ENV!=="production"?b.oneOfType([b.number,b.shape({enter:b.number,exit:b.number,appear:b.number}).isRequired]):null;process.env.NODE_ENV!=="production"&&b.oneOfType([b.string,b.shape({enter:b.string,exit:b.string,active:b.string}),b.shape({enter:b.string,enterDone:b.string,enterActive:b.string,exit:b.string,exitDone:b.string,exitActive:b.string})]);const rj=k.createContext(null);var coe=function(t){return t.scrollTop},Eu="unmounted",os="exited",as="entering",Ol="entered",Px="exiting",Bi=(function(e){soe(t,e);function t(r,i){var o;o=e.call(this,r,i)||this;var a=i,s=a&&!a.isMounting?r.enter:r.appear,l;return o.appearStatus=null,r.in?s?(l=os,o.appearStatus=as):l=Ol:r.unmountOnExit||r.mountOnEnter?l=Eu:l=os,o.state={status:l},o.nextCallback=null,o}t.getDerivedStateFromProps=function(i,o){var a=i.in;return a&&o.status===Eu?{status:os}:null};var n=t.prototype;return n.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},n.componentDidUpdate=function(i){var o=null;if(i!==this.props){var a=this.state.status;this.props.in?a!==as&&a!==Ol&&(o=as):(a===as||a===Ol)&&(o=Px)}this.updateStatus(!1,o)},n.componentWillUnmount=function(){this.cancelNextCallback()},n.getTimeouts=function(){var i=this.props.timeout,o,a,s;return o=a=s=i,i!=null&&typeof i!="number"&&(o=i.exit,a=i.enter,s=i.appear!==void 0?i.appear:a),{exit:o,enter:a,appear:s}},n.updateStatus=function(i,o){if(i===void 0&&(i=!1),o!==null)if(this.cancelNextCallback(),o===as){if(this.props.unmountOnExit||this.props.mountOnEnter){var a=this.props.nodeRef?this.props.nodeRef.current:fi.findDOMNode(this);a&&coe(a)}this.performEnter(i)}else this.performExit();else this.props.unmountOnExit&&this.state.status===os&&this.setState({status:Eu})},n.performEnter=function(i){var o=this,a=this.props.enter,s=this.context?this.context.isMounting:i,l=this.props.nodeRef?[s]:[fi.findDOMNode(this),s],c=l[0],u=l[1],d=this.getTimeouts(),f=s?d.appear:d.enter;if(!i&&!a||nj.disabled){this.safeSetState({status:Ol},function(){o.props.onEntered(c)});return}this.props.onEnter(c,u),this.safeSetState({status:as},function(){o.props.onEntering(c,u),o.onTransitionEnd(f,function(){o.safeSetState({status:Ol},function(){o.props.onEntered(c,u)})})})},n.performExit=function(){var i=this,o=this.props.exit,a=this.getTimeouts(),s=this.props.nodeRef?void 0:fi.findDOMNode(this);if(!o||nj.disabled){this.safeSetState({status:os},function(){i.props.onExited(s)});return}this.props.onExit(s),this.safeSetState({status:Px},function(){i.props.onExiting(s),i.onTransitionEnd(a.exit,function(){i.safeSetState({status:os},function(){i.props.onExited(s)})})})},n.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},n.safeSetState=function(i,o){o=this.setNextCallback(o),this.setState(i,o)},n.setNextCallback=function(i){var o=this,a=!0;return this.nextCallback=function(s){a&&(a=!1,o.nextCallback=null,i(s))},this.nextCallback.cancel=function(){a=!1},this.nextCallback},n.onTransitionEnd=function(i,o){this.setNextCallback(o);var a=this.props.nodeRef?this.props.nodeRef.current:fi.findDOMNode(this),s=i==null&&!this.props.addEndListener;if(!a||s){setTimeout(this.nextCallback,0);return}if(this.props.addEndListener){var l=this.props.nodeRef?[this.nextCallback]:[a,this.nextCallback],c=l[0],u=l[1];this.props.addEndListener(c,u)}i!=null&&setTimeout(this.nextCallback,i)},n.render=function(){var i=this.state.status;if(i===Eu)return null;var o=this.props,a=o.children;o.in,o.mountOnEnter,o.unmountOnExit,o.appear,o.enter,o.exit,o.timeout,o.addEndListener,o.onEnter,o.onEntering,o.onEntered,o.onExit,o.onExiting,o.onExited,o.nodeRef;var s=aoe(o,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return k.createElement(rj.Provider,{value:null},typeof a=="function"?a(i,s):k.cloneElement(k.Children.only(a),s))},t})(k.Component);Bi.contextType=rj,Bi.propTypes=process.env.NODE_ENV!=="production"?{nodeRef:b.shape({current:typeof Element>"u"?b.any:function(e,t,n,r,i,o){var a=e[t];return b.instanceOf(a&&"ownerDocument"in a?a.ownerDocument.defaultView.Element:Element)(e,t,n,r,i,o)}}),children:b.oneOfType([b.func.isRequired,b.element.isRequired]).isRequired,in:b.bool,mountOnEnter:b.bool,unmountOnExit:b.bool,appear:b.bool,enter:b.bool,exit:b.bool,timeout:function(t){var n=loe;t.addEndListener||(n=n.isRequired);for(var r=arguments.length,i=new Array(r>1?r-1:0),o=1;o<r;o++)i[o-1]=arguments[o];return n.apply(void 0,[t].concat(i))},addEndListener:b.func,onEnter:b.func,onEntering:b.func,onEntered:b.func,onExit:b.func,onExiting:b.func,onExited:b.func}:{};function Cl(){}Bi.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:Cl,onEntering:Cl,onEntered:Cl,onExit:Cl,onExiting:Cl,onExited:Cl},Bi.UNMOUNTED=Eu,Bi.EXITED=os,Bi.ENTERING=as,Bi.ENTERED=Ol,Bi.EXITING=Px;const ij={};function uoe(e,t){const n=O.useRef(ij);return n.current===ij&&(n.current=e(t)),n}const doe=[];function foe(e){O.useEffect(e,doe)}class xh{static create(){return new xh}currentId=null;start(t,n){this.clear(),this.currentId=setTimeout(()=>{this.currentId=null,n()},t)}clear=()=>{this.currentId!==null&&(clearTimeout(this.currentId),this.currentId=null)};disposeEffect=()=>this.clear}function Su(){const e=uoe(xh.create).current;return foe(e.disposeEffect),e}function poe(e){const{prototype:t={}}=e;return!!t.isReactComponent}function hoe(e,t,n,r,i){const o=e[t],a=i||t;if(o==null||typeof window>"u")return null;let s;return typeof o=="function"&&!poe(o)&&(s="Did you accidentally provide a plain function component instead?"),s!==void 0?new Error(`Invalid ${r} \`${a}\` supplied to \`${n}\`. Expected an element type that can hold a ref. ${s} For more information see https://mui.com/r/caveat-with-refs-guide`):null}const oj=Sl(b.elementType,hoe),aj=e=>e.scrollTop;function wh(e,t){const{timeout:n,easing:r,style:i={}}=e;return{duration:i.transitionDuration??(typeof n=="number"?n:n[t.mode]||0),easing:i.transitionTimingFunction??(typeof r=="object"?r[t.mode]:r),delay:i.transitionDelay}}function moe(e){const t=typeof e;switch(t){case"number":return Number.isNaN(e)?"NaN":Number.isFinite(e)?e!==Math.floor(e)?"float":"number":"Infinity";case"object":return e===null?"null":e.constructor.name;default:return t}}function sj(e,t,n,r){const i=e[t];if(i==null||!Number.isInteger(i)){const o=moe(i);return new RangeError(`Invalid ${r} \`${t}\` of type \`${o}\` supplied to \`${n}\`, expected \`integer\`.`)}return null}function lj(e,t,n,r){return e[t]===void 0?null:sj(e,t,n,r)}function Dx(){return null}lj.isRequired=sj,Dx.isRequired=Dx;const cj=process.env.NODE_ENV==="production"?Dx:lj;function goe(e){return xn("MuiPaper",e)}Vn("MuiPaper",["root","rounded","outlined","elevation","elevation0","elevation1","elevation2","elevation3","elevation4","elevation5","elevation6","elevation7","elevation8","elevation9","elevation10","elevation11","elevation12","elevation13","elevation14","elevation15","elevation16","elevation17","elevation18","elevation19","elevation20","elevation21","elevation22","elevation23","elevation24"]);const voe=e=>{const{square:t,elevation:n,variant:r,classes:i}=e,o={root:["root",r,!t&&"rounded",r==="elevation"&&`elevation${n}`]};return kn(o,goe,i)},yoe=De("div",{name:"MuiPaper",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,t[n.variant],!n.square&&t.rounded,n.variant==="elevation"&&t[`elevation${n.elevation}`]]}})(Hn(({theme:e})=>({backgroundColor:(e.vars||e).palette.background.paper,color:(e.vars||e).palette.text.primary,transition:e.transitions.create("box-shadow"),variants:[{props:({ownerState:t})=>!t.square,style:{borderRadius:e.shape.borderRadius}},{props:{variant:"outlined"},style:{border:`1px solid ${(e.vars||e).palette.divider}`}},{props:{variant:"elevation"},style:{boxShadow:"var(--Paper-shadow)",backgroundImage:"var(--Paper-overlay)"}}]}))),uj=O.forwardRef(function(t,n){const r=Zn({props:t,name:"MuiPaper"}),i=Id(),{className:o,component:a="div",elevation:s=1,square:l=!1,variant:c="elevation",...u}=r,d={...r,component:a,elevation:s,square:l,variant:c},f=voe(d);return process.env.NODE_ENV!=="production"&&i.shadows[s]===void 0&&console.error([`MUI: The elevation provided <Paper elevation={${s}}> is not available in the theme.`,`Please make sure that \`theme.shadows[${s}]\` is defined.`].join(`
|
|
243
243
|
`)),h.jsx(yoe,{as:a,ownerState:d,className:ue(f.root,o),ref:n,...u,style:{...c==="elevation"&&{"--Paper-shadow":(i.vars||i).shadows[s],...i.vars&&{"--Paper-overlay":i.vars.overlays?.[s]},...!i.vars&&i.palette.mode==="dark"&&{"--Paper-overlay":`linear-gradient(${Td("#fff",Qm(s))}, ${Td("#fff",Qm(s))})`}},...u.style}})});process.env.NODE_ENV!=="production"&&(uj.propTypes={children:b.node,classes:b.object,className:b.string,component:b.elementType,elevation:Sl(cj,e=>{const{elevation:t,variant:n}=e;return t>0&&n==="outlined"?new Error(`MUI: Combining \`elevation={${t}}\` with \`variant="${n}"\` has no effect. Either use \`elevation={0}\` or use a different \`variant\`.`):null}),square:b.bool,style:b.object,sx:b.oneOfType([b.arrayOf(b.oneOfType([b.func,b.object,b.bool])),b.func,b.object]),variant:b.oneOfType([b.oneOf(["elevation","outlined"]),b.string])});function _h(e){return typeof e=="string"}function dj(e,t,n){return e===void 0||_h(e)?t:{...t,ownerState:{...t.ownerState,...n}}}function fj(e,t,n){return typeof e=="function"?e(t,n):e}function pj(e,t=[]){if(e===void 0)return{};const n={};return Object.keys(e).filter(r=>r.match(/^on[A-Z]/)&&typeof e[r]=="function"&&!t.includes(r)).forEach(r=>{n[r]=e[r]}),n}function hj(e){if(e===void 0)return{};const t={};return Object.keys(e).filter(n=>!(n.match(/^on[A-Z]/)&&typeof e[n]=="function")).forEach(n=>{t[n]=e[n]}),t}function mj(e){const{getSlotProps:t,additionalProps:n,externalSlotProps:r,externalForwardedProps:i,className:o}=e;if(!t){const p=ue(n?.className,o,i?.className,r?.className),m={...n?.style,...i?.style,...r?.style},g={...n,...i,...r};return p.length>0&&(g.className=p),Object.keys(m).length>0&&(g.style=m),{props:g,internalRef:void 0}}const a=pj({...i,...r}),s=hj(r),l=hj(i),c=t(a),u=ue(c?.className,n?.className,o,i?.className,r?.className),d={...c?.style,...n?.style,...i?.style,...r?.style},f={...c,...n,...l,...s};return u.length>0&&(f.className=u),Object.keys(d).length>0&&(f.style=d),{props:f,internalRef:c.ref}}function lr(e,t){const{className:n,elementType:r,ownerState:i,externalForwardedProps:o,internalForwardedProps:a,shouldForwardComponentProp:s=!1,...l}=t,{component:c,slots:u={[e]:void 0},slotProps:d={[e]:void 0},...f}=o,p=u[e]||r,m=fj(d[e],i),{props:{component:g,...v},internalRef:x}=mj({className:n,...l,externalForwardedProps:e==="root"?f:void 0,externalSlotProps:m}),_=Yn(x,m?.ref,t.ref),w=e==="root"?g||c:g,y=dj(p,{...e==="root"&&!c&&!u[e]&&a,...e!=="root"&&!u[e]&&a,...v,...w&&!s&&{as:w},...w&&s&&{component:w},ref:_},i);return[p,y]}const Po=b.oneOfType([b.func,b.object]);function gj(e){try{return e.matches(":focus-visible")}catch{process.env.NODE_ENV!=="production"&&!/jsdom/.test(window.navigator.userAgent)&&console.warn(["MUI: The `:focus-visible` pseudo class is not supported in this browser.","Some components rely on this feature to work properly."].join(`
|
|
244
244
|
`))}return!1}function boe(e){return typeof e.main=="string"}function xoe(e,t=[]){if(!boe(e))return!1;for(const n of t)if(!e.hasOwnProperty(n)||typeof e[n]!="string")return!1;return!0}function Ax(e=[]){return([,t])=>t&&xoe(t,e)}function Do(e,t,n,r,i){if(process.env.NODE_ENV==="production")return null;const o=e[t],a=i||t;return o==null?null:o&&o.nodeType!==1?new Error(`Invalid ${r} \`${a}\` supplied to \`${n}\`. Expected an HTMLElement.`):null}function vj(e){const{elementType:t,externalSlotProps:n,ownerState:r,skipResolvingSlotProps:i=!1,...o}=e,a=i?{}:fj(n,r),{props:s,internalRef:l}=mj({...o,externalSlotProps:a}),c=Yn(l,a?.ref,e.additionalProps?.ref);return dj(t,{...s,ref:c},r)}function kl(e){return parseInt(O.version,10)>=19?e?.props?.ref||null:e?.ref||null}function woe(e){return typeof e=="function"?e():e}const Ou=O.forwardRef(function(t,n){const{children:r,container:i,disablePortal:o=!1}=t,[a,s]=O.useState(null),l=Yn(O.isValidElement(r)?kl(r):null,n);if(Xi(()=>{o||s(woe(i)||document.body)},[i,o]),Xi(()=>{if(a&&!o)return C_(n,a),()=>{C_(n,null)}},[n,a,o]),o){if(O.isValidElement(r)){const c={ref:l};return O.cloneElement(r,c)}return r}return a&&Y1.createPortal(r,a)});process.env.NODE_ENV!=="production"&&(Ou.propTypes={children:b.node,container:b.oneOfType([Do,b.func]),disablePortal:b.bool}),process.env.NODE_ENV!=="production"&&(Ou.propTypes=i_(Ou.propTypes));function _oe(e){return xn("MuiPopper",e)}Vn("MuiPopper",["root"]);function Eoe(e,t){if(t==="ltr")return e;switch(e){case"bottom-end":return"bottom-start";case"bottom-start":return"bottom-end";case"top-end":return"top-start";case"top-start":return"top-end";default:return e}}function Eh(e){return typeof e=="function"?e():e}function Sh(e){return e.nodeType!==void 0}function Soe(e){return!Sh(e)}const Ooe=e=>{const{classes:t}=e;return kn({root:["root"]},_oe,t)},Coe={},koe=O.forwardRef(function(t,n){const{anchorEl:r,children:i,direction:o,disablePortal:a,modifiers:s,open:l,placement:c,popperOptions:u,popperRef:d,slotProps:f={},slots:p={},TransitionProps:m,ownerState:g,...v}=t,x=O.useRef(null),_=Yn(x,n),w=O.useRef(null),y=Yn(w,d),E=O.useRef(y);Xi(()=>{E.current=y},[y]),O.useImperativeHandle(d,()=>w.current,[]);const S=Eoe(c,o),[P,D]=O.useState(S),[T,I]=O.useState(Eh(r));O.useEffect(()=>{w.current&&w.current.forceUpdate()}),O.useEffect(()=>{r&&I(Eh(r))},[r]),Xi(()=>{if(!T||!l)return;const M=V=>{D(V.placement)};if(process.env.NODE_ENV!=="production"&&T&&Sh(T)&&T.nodeType===1){const V=T.getBoundingClientRect();process.env.NODE_ENV!=="test"&&V.top===0&&V.left===0&&V.right===0&&V.bottom===0&&console.warn(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(`
|
|
245
245
|
`))}let R=[{name:"preventOverflow",options:{altBoundary:a}},{name:"flip",options:{altBoundary:a}},{name:"onUpdate",enabled:!0,phase:"afterWrite",fn:({state:V})=>{M(V)}}];s!=null&&(R=R.concat(s)),u&&u.modifiers!=null&&(R=R.concat(u.modifiers));const B=Vg(T,x.current,{placement:S,...u,modifiers:R});return E.current(B),()=>{B.destroy(),E.current(null)}},[T,a,s,l,u,S]);const A={placement:P};m!==null&&(A.TransitionProps=m);const C=Ooe(t),j=p.root??"div",N=vj({elementType:j,externalSlotProps:f.root,externalForwardedProps:v,additionalProps:{role:"tooltip",ref:_},ownerState:t,className:C.root});return h.jsx(j,{...N,children:typeof i=="function"?i(A):i})}),yj=O.forwardRef(function(t,n){const{anchorEl:r,children:i,container:o,direction:a="ltr",disablePortal:s=!1,keepMounted:l=!1,modifiers:c,open:u,placement:d="bottom",popperOptions:f=Coe,popperRef:p,style:m,transition:g=!1,slotProps:v={},slots:x={},..._}=t,[w,y]=O.useState(!0),E=()=>{y(!1)},S=()=>{y(!0)};if(!l&&!u&&(!g||w))return null;let P;if(o)P=o;else if(r){const I=Eh(r);P=I&&Sh(I)?gr(I).body:gr(null).body}const D=!u&&l&&(!g||w)?"none":void 0,T=g?{in:u,onEnter:E,onExited:S}:void 0;return h.jsx(Ou,{disablePortal:s,container:P,children:h.jsx(koe,{anchorEl:r,direction:a,disablePortal:s,modifiers:c,ref:n,open:g?!w:u,placement:d,popperOptions:f,popperRef:p,slotProps:v,slots:x,..._,style:{position:"fixed",top:0,left:0,display:D,...m},TransitionProps:T,children:i})})});process.env.NODE_ENV!=="production"&&(yj.propTypes={anchorEl:Sl(b.oneOfType([Do,b.object,b.func]),e=>{if(e.open){const t=Eh(e.anchorEl);if(t&&Sh(t)&&t.nodeType===1){const n=t.getBoundingClientRect();if(process.env.NODE_ENV!=="test"&&n.top===0&&n.left===0&&n.right===0&&n.bottom===0)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(`
|
|
246
246
|
`))}else if(!t||typeof t.getBoundingClientRect!="function"||Soe(t)&&t.contextElement!=null&&t.contextElement.nodeType!==1)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","It should be an HTML element instance or a virtualElement ","(https://popper.js.org/docs/v2/virtual-elements/)."].join(`
|
|
247
247
|
`))}return null}),children:b.oneOfType([b.node,b.func]),container:b.oneOfType([Do,b.func]),direction:b.oneOf(["ltr","rtl"]),disablePortal:b.bool,keepMounted:b.bool,modifiers:b.arrayOf(b.shape({data:b.object,effect:b.func,enabled:b.bool,fn:b.func,name:b.any,options:b.object,phase:b.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:b.arrayOf(b.string),requiresIfExists:b.arrayOf(b.string)})),open:b.bool.isRequired,placement:b.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:b.shape({modifiers:b.array,onFirstUpdate:b.func,placement:b.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:b.oneOf(["absolute","fixed"])}),popperRef:Po,slotProps:b.shape({root:b.oneOfType([b.func,b.object])}),slots:b.shape({root:b.elementType}),transition:b.bool});const Poe=De(yj,{name:"MuiPopper",slot:"Root"})({}),Tx=O.forwardRef(function(t,n){const r=Um(),i=Zn({props:t,name:"MuiPopper"}),{anchorEl:o,component:a,components:s,componentsProps:l,container:c,disablePortal:u,keepMounted:d,modifiers:f,open:p,placement:m,popperOptions:g,popperRef:v,transition:x,slots:_,slotProps:w,...y}=i,E=_?.root??s?.Root,S={anchorEl:o,container:c,disablePortal:u,keepMounted:d,modifiers:f,open:p,placement:m,popperOptions:g,popperRef:v,transition:x,...y};return h.jsx(Poe,{as:a,direction:r?"rtl":"ltr",slots:{root:E},slotProps:w??l,...S,ref:n})});process.env.NODE_ENV!=="production"&&(Tx.propTypes={anchorEl:b.oneOfType([Do,b.object,b.func]),children:b.oneOfType([b.node,b.func]),component:b.elementType,components:b.shape({Root:b.elementType}),componentsProps:b.shape({root:b.oneOfType([b.func,b.object])}),container:b.oneOfType([Do,b.func]),disablePortal:b.bool,keepMounted:b.bool,modifiers:b.arrayOf(b.shape({data:b.object,effect:b.func,enabled:b.bool,fn:b.func,name:b.any,options:b.object,phase:b.oneOf(["afterMain","afterRead","afterWrite","beforeMain","beforeRead","beforeWrite","main","read","write"]),requires:b.arrayOf(b.string),requiresIfExists:b.arrayOf(b.string)})),open:b.bool.isRequired,placement:b.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),popperOptions:b.shape({modifiers:b.array,onFirstUpdate:b.func,placement:b.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),strategy:b.oneOf(["absolute","fixed"])}),popperRef:Po,slotProps:b.shape({root:b.oneOfType([b.func,b.object])}),slots:b.shape({root:b.elementType}),sx:b.oneOfType([b.arrayOf(b.oneOfType([b.func,b.object,b.bool])),b.func,b.object]),transition:b.bool});function Oh(e){return parseInt(e,10)||0}const Doe={shadow:{visibility:"hidden",position:"absolute",overflow:"hidden",height:0,top:0,left:0,transform:"translateZ(0)"}};function Aoe(e){for(const t in e)return!1;return!0}function bj(e){return Aoe(e)||e.outerHeightStyle===0&&!e.overflowing}const xj=O.forwardRef(function(t,n){const{onChange:r,maxRows:i,minRows:o=1,style:a,value:s,...l}=t,{current:c}=O.useRef(s!=null),u=O.useRef(null),d=Yn(n,u),f=O.useRef(null),p=O.useRef(null),m=O.useCallback(()=>{const w=u.current,y=p.current;if(!w||!y)return;const S=Ji(w).getComputedStyle(w);if(S.width==="0px")return{outerHeightStyle:0,overflowing:!1};y.style.width=S.width,y.value=w.value||t.placeholder||"x",y.value.slice(-1)===`
|
|
248
248
|
`&&(y.value+=" ");const P=S.boxSizing,D=Oh(S.paddingBottom)+Oh(S.paddingTop),T=Oh(S.borderBottomWidth)+Oh(S.borderTopWidth),I=y.scrollHeight;y.value="x";const A=y.scrollHeight;let C=I;o&&(C=Math.max(Number(o)*A,C)),i&&(C=Math.min(Number(i)*A,C)),C=Math.max(C,A);const j=C+(P==="border-box"?D+T:0),N=Math.abs(C-I)<=1;return{outerHeightStyle:j,overflowing:N}},[i,o,t.placeholder]),g=oc(()=>{const w=u.current,y=m();if(!w||!y||bj(y))return!1;const E=y.outerHeightStyle;return f.current!=null&&f.current!==E}),v=O.useCallback(()=>{const w=u.current,y=m();if(!w||!y||bj(y))return;const E=y.outerHeightStyle;f.current!==E&&(f.current=E,w.style.height=`${E}px`),w.style.overflow=y.overflowing?"hidden":""},[m]),x=O.useRef(-1);Xi(()=>{const w=O_(v),y=u?.current;if(!y)return;const E=Ji(y);E.addEventListener("resize",w);let S;return typeof ResizeObserver<"u"&&(S=new ResizeObserver(()=>{g()&&(S.unobserve(y),cancelAnimationFrame(x.current),v(),x.current=requestAnimationFrame(()=>{S.observe(y)}))}),S.observe(y)),()=>{w.clear(),cancelAnimationFrame(x.current),E.removeEventListener("resize",w),S&&S.disconnect()}},[m,v,g]),Xi(()=>{v()});const _=w=>{c||v();const y=w.target,E=y.value.length,S=y.value.endsWith(`
|
|
249
|
-
`),P=y.selectionStart===E;S&&P&&y.setSelectionRange(E,E),r&&r(w)};return h.jsxs(O.Fragment,{children:[h.jsx("textarea",{value:s,onChange:_,ref:d,rows:o,style:a,...l}),h.jsx("textarea",{"aria-hidden":!0,className:t.className,readOnly:!0,ref:p,tabIndex:-1,style:{...Doe.shadow,...a,paddingTop:0,paddingBottom:0}})]})});process.env.NODE_ENV!=="production"&&(xj.propTypes={className:b.string,maxRows:b.oneOfType([b.number,b.string]),minRows:b.oneOfType([b.number,b.string]),onChange:b.func,placeholder:b.string,style:b.object,value:b.oneOfType([b.arrayOf(b.string),b.number,b.string])});function Nx({props:e,states:t,muiFormControl:n}){return t.reduce((r,i)=>(r[i]=e[i],n&&typeof e[i]>"u"&&(r[i]=n[i]),r),{})}const jx=O.createContext(void 0);process.env.NODE_ENV!=="production"&&(jx.displayName="FormControlContext");function Mx(){return O.useContext(jx)}function wj(e){return e!=null&&!(Array.isArray(e)&&e.length===0)}function _j(e,t=!1){return e&&(wj(e.value)&&e.value!==""||t&&wj(e.defaultValue)&&e.defaultValue!=="")}function Toe(e){return xn("MuiInputBase",e)}const Pl=Vn("MuiInputBase",["root","formControl","focused","disabled","adornedStart","adornedEnd","error","sizeSmall","multiline","colorSecondary","fullWidth","hiddenLabel","readOnly","input","inputSizeSmall","inputMultiline","inputTypeSearch","inputAdornedStart","inputAdornedEnd","inputHiddenLabel"]);var Ej;const Ch=(e,t)=>{const{ownerState:n}=e;return[t.root,n.formControl&&t.formControl,n.startAdornment&&t.adornedStart,n.endAdornment&&t.adornedEnd,n.error&&t.error,n.size==="small"&&t.sizeSmall,n.multiline&&t.multiline,n.color&&t[`color${yn(n.color)}`],n.fullWidth&&t.fullWidth,n.hiddenLabel&&t.hiddenLabel]},kh=(e,t)=>{const{ownerState:n}=e;return[t.input,n.size==="small"&&t.inputSizeSmall,n.multiline&&t.inputMultiline,n.type==="search"&&t.inputTypeSearch,n.startAdornment&&t.inputAdornedStart,n.endAdornment&&t.inputAdornedEnd,n.hiddenLabel&&t.inputHiddenLabel]},Noe=e=>{const{classes:t,color:n,disabled:r,error:i,endAdornment:o,focused:a,formControl:s,fullWidth:l,hiddenLabel:c,multiline:u,readOnly:d,size:f,startAdornment:p,type:m}=e,g={root:["root",`color${yn(n)}`,r&&"disabled",i&&"error",l&&"fullWidth",a&&"focused",s&&"formControl",f&&f!=="medium"&&`size${yn(f)}`,u&&"multiline",p&&"adornedStart",o&&"adornedEnd",c&&"hiddenLabel",d&&"readOnly"],input:["input",r&&"disabled",m==="search"&&"inputTypeSearch",u&&"inputMultiline",f==="small"&&"inputSizeSmall",c&&"inputHiddenLabel",p&&"inputAdornedStart",o&&"inputAdornedEnd",d&&"readOnly"]};return kn(g,Toe,t)},Ph=De("div",{name:"MuiInputBase",slot:"Root",overridesResolver:Ch})(Hn(({theme:e})=>({...e.typography.body1,color:(e.vars||e).palette.text.primary,lineHeight:"1.4375em",boxSizing:"border-box",position:"relative",cursor:"text",display:"inline-flex",alignItems:"center",[`&.${Pl.disabled}`]:{color:(e.vars||e).palette.text.disabled,cursor:"default"},variants:[{props:({ownerState:t})=>t.multiline,style:{padding:"4px 0 5px"}},{props:({ownerState:t,size:n})=>t.multiline&&n==="small",style:{paddingTop:1}},{props:({ownerState:t})=>t.fullWidth,style:{width:"100%"}}]}))),Dh=De("input",{name:"MuiInputBase",slot:"Input",overridesResolver:kh})(Hn(({theme:e})=>{const t=e.palette.mode==="light",n={color:"currentColor",...e.vars?{opacity:e.vars.opacity.inputPlaceholder}:{opacity:t?.42:.5},transition:e.transitions.create("opacity",{duration:e.transitions.duration.shorter})},r={opacity:"0 !important"},i=e.vars?{opacity:e.vars.opacity.inputPlaceholder}:{opacity:t?.42:.5};return{font:"inherit",letterSpacing:"inherit",color:"currentColor",padding:"4px 0 5px",border:0,boxSizing:"content-box",background:"none",height:"1.4375em",margin:0,WebkitTapHighlightColor:"transparent",display:"block",minWidth:0,width:"100%","&::-webkit-input-placeholder":n,"&::-moz-placeholder":n,"&::-ms-input-placeholder":n,"&:focus":{outline:0},"&:invalid":{boxShadow:"none"},"&::-webkit-search-decoration":{WebkitAppearance:"none"},[`label[data-shrink=false] + .${Pl.formControl} &`]:{"&::-webkit-input-placeholder":r,"&::-moz-placeholder":r,"&::-ms-input-placeholder":r,"&:focus::-webkit-input-placeholder":i,"&:focus::-moz-placeholder":i,"&:focus::-ms-input-placeholder":i},[`&.${Pl.disabled}`]:{opacity:1,WebkitTextFillColor:(e.vars||e).palette.text.disabled},variants:[{props:({ownerState:o})=>!o.disableInjectingGlobalStyles,style:{animationName:"mui-auto-fill-cancel",animationDuration:"10ms","&:-webkit-autofill":{animationDuration:"5000s",animationName:"mui-auto-fill"}}},{props:{size:"small"},style:{paddingTop:1}},{props:({ownerState:o})=>o.multiline,style:{height:"auto",resize:"none",padding:0,paddingTop:0}},{props:{type:"search"},style:{MozAppearance:"textfield"}}]}})),Sj=$$({"@keyframes mui-auto-fill":{from:{display:"block"}},"@keyframes mui-auto-fill-cancel":{from:{display:"block"}}}),Ah=O.forwardRef(function(t,n){const r=Zn({props:t,name:"MuiInputBase"}),{"aria-describedby":i,autoComplete:o,autoFocus:a,className:s,color:l,components:c={},componentsProps:u={},defaultValue:d,disabled:f,disableInjectingGlobalStyles:p,endAdornment:m,error:g,fullWidth:v=!1,id:x,inputComponent:_="input",inputProps:w={},inputRef:y,margin:E,maxRows:S,minRows:P,multiline:D=!1,name:T,onBlur:I,onChange:A,onClick:C,onFocus:j,onKeyDown:N,onKeyUp:M,placeholder:R,readOnly:B,renderSuffix:V,rows:z,size:W,slotProps:Q={},slots:
|
|
250
|
-
`))},[]),Z=Yn(K,y,w.ref,U),[F,ge]=O.useState(!1),oe=Mx();process.env.NODE_ENV!=="production"&&O.useEffect(()=>{if(oe)return oe.registerEffect()},[oe]);const ye=Nx({props:r,muiFormControl:oe,states:["color","disabled","error","hiddenLabel","size","required","filled"]});ye.focused=oe?oe.focused:F,O.useEffect(()=>{!oe&&f&&F&&(ge(!1),I&&I())},[oe,f,F,I]);const _e=oe&&oe.onFilled,Ie=oe&&oe.onEmpty,tt=O.useCallback(be=>{_j(be)?_e&&_e():Ie&&Ie()},[_e,Ie]);Xi(()=>{de&&tt({value:ce})},[ce,tt,de]);const pt=be=>{j&&j(be),w.onFocus&&w.onFocus(be),oe&&oe.onFocus?oe.onFocus(be):ge(!0)},ct=be=>{I&&I(be),w.onBlur&&w.onBlur(be),oe&&oe.onBlur?oe.onBlur(be):ge(!1)},Fe=(be,...vn)=>{if(!de){const Qt=be.target||K.current;if(Qt==null)throw new Error(process.env.NODE_ENV!=="production"?"MUI: Expected valid input target. Did you use a custom `inputComponent` and forget to forward refs? See https://mui.com/r/input-component-ref-interface for more info.":pi(1));tt({value:Qt.value})}w.onChange&&w.onChange(be,...vn),A&&A(be,...vn)};O.useEffect(()=>{tt(K.current)},[]);const Pt=be=>{K.current&&be.currentTarget===be.target&&K.current.focus(),C&&C(be)};let Dt=_,ht=w;D&&Dt==="input"&&(z?(process.env.NODE_ENV!=="production"&&(P||S)&&console.warn("MUI: You can not use the `minRows` or `maxRows` props when the input `rows` prop is set."),ht={type:void 0,minRows:z,maxRows:z,...ht}):ht={type:void 0,maxRows:S,minRows:P,...ht},Dt=xj);const mn=be=>{tt(be.animationName==="mui-auto-fill-cancel"?K.current:{value:"x"})};O.useEffect(()=>{oe&&oe.setAdornedStart(!!ie)},[oe,ie]);const sn={...r,color:ye.color||"primary",disabled:ye.disabled,endAdornment:m,error:ye.error,focused:ye.focused,formControl:oe,fullWidth:v,hiddenLabel:ye.hiddenLabel,multiline:D,size:ye.size,startAdornment:ie,type:J},gn=Noe(sn),Wn=X.root||c.Root||Ph,Xt=Q.root||u.root||{},zn=X.input||c.Input||Dh;return ht={...ht,...Q.input??u.input},h.jsxs(O.Fragment,{children:[!p&&typeof Sj=="function"&&(Ej||(Ej=h.jsx(Sj,{}))),h.jsxs(Wn,{...Xt,ref:n,onClick:Pt,...se,...!_h(Wn)&&{ownerState:{...sn,...Xt.ownerState}},className:ue(gn.root,Xt.className,s,B&&"MuiInputBase-readOnly"),children:[ie,h.jsx(jx.Provider,{value:null,children:h.jsx(zn,{"aria-invalid":ye.error,"aria-describedby":i,autoComplete:o,autoFocus:a,defaultValue:d,disabled:ye.disabled,id:x,onAnimationStart:mn,name:T,placeholder:R,readOnly:B,required:ye.required,rows:z,value:ce,onKeyDown:N,onKeyUp:M,type:J,...ht,...!_h(zn)&&{as:Dt,ownerState:{...sn,...ht.ownerState}},ref:Z,className:ue(gn.input,ht.className,B&&"MuiInputBase-readOnly"),onBlur:ct,onChange:Fe,onFocus:pt})}),m,V?V({...ye,startAdornment:ie}):null]})]})});process.env.NODE_ENV!=="production"&&(Ah.propTypes={"aria-describedby":b.string,autoComplete:b.string,autoFocus:b.bool,classes:b.object,className:b.string,color:b.oneOfType([b.oneOf(["primary","secondary","error","info","success","warning"]),b.string]),components:b.shape({Input:b.elementType,Root:b.elementType}),componentsProps:b.shape({input:b.object,root:b.object}),defaultValue:b.any,disabled:b.bool,disableInjectingGlobalStyles:b.bool,endAdornment:b.node,error:b.bool,fullWidth:b.bool,id:b.string,inputComponent:oj,inputProps:b.object,inputRef:Po,margin:b.oneOf(["dense","none"]),maxRows:b.oneOfType([b.number,b.string]),minRows:b.oneOfType([b.number,b.string]),multiline:b.bool,name:b.string,onBlur:b.func,onChange:b.func,onClick:b.func,onFocus:b.func,onInvalid:b.func,onKeyDown:b.func,onKeyUp:b.func,placeholder:b.string,readOnly:b.bool,renderSuffix:b.func,required:b.bool,rows:b.oneOfType([b.number,b.string]),size:b.oneOfType([b.oneOf(["medium","small"]),b.string]),slotProps:b.shape({input:b.object,root:b.object}),slots:b.shape({input:b.elementType,root:b.elementType}),startAdornment:b.node,sx:b.oneOfType([b.arrayOf(b.oneOfType([b.func,b.object,b.bool])),b.func,b.object]),type:b.string,value:b.any});function joe(e){return xn("MuiInput",e)}const Cu={...Pl,...Vn("MuiInput",["root","underline","input"])};function Moe(e){return xn("MuiOutlinedInput",e)}const Wi={...Pl,...Vn("MuiOutlinedInput",["root","notchedOutline","input"])};function Ioe(e){return xn("MuiFilledInput",e)}const ss={...Pl,...Vn("MuiFilledInput",["root","underline","input","adornedStart","adornedEnd","sizeSmall","multiline","hiddenLabel"])},Foe=ic(h.jsx("path",{d:"M7 10l5 5 5-5z"}),"ArrowDropDown");function Loe(e){const{prototype:t={}}=e;return!!t.isReactComponent}function Oj(e,t,n,r,i){const o=e[t],a=i||t;if(o==null||typeof window>"u")return null;let s;const l=o.type;return typeof l=="function"&&!Loe(l)&&(s="Did you accidentally use a plain function component for an element instead?"),s!==void 0?new Error(`Invalid ${r} \`${a}\` supplied to \`${n}\`. Expected an element that can hold a ref. ${s} For more information see https://mui.com/r/caveat-with-refs-guide`):null}const Dl=Sl(b.element,Oj);Dl.isRequired=Sl(b.element.isRequired,Oj);const Roe={entering:{opacity:1},entered:{opacity:1}},Cj=O.forwardRef(function(t,n){const r=Id(),i={enter:r.transitions.duration.enteringScreen,exit:r.transitions.duration.leavingScreen},{addEndListener:o,appear:a=!0,children:s,easing:l,in:c,onEnter:u,onEntered:d,onEntering:f,onExit:p,onExited:m,onExiting:g,style:v,timeout:x=i,TransitionComponent:_=Bi,...w}=t,y=O.useRef(null),E=Yn(y,kl(s),n),S=N=>M=>{if(N){const R=y.current;M===void 0?N(R):N(R,M)}},P=S(f),D=S((N,M)=>{aj(N);const R=wh({style:v,timeout:x,easing:l},{mode:"enter"});N.style.webkitTransition=r.transitions.create("opacity",R),N.style.transition=r.transitions.create("opacity",R),u&&u(N,M)}),T=S(d),I=S(g),A=S(N=>{const M=wh({style:v,timeout:x,easing:l},{mode:"exit"});N.style.webkitTransition=r.transitions.create("opacity",M),N.style.transition=r.transitions.create("opacity",M),p&&p(N)}),C=S(m),j=N=>{o&&o(y.current,N)};return h.jsx(_,{appear:a,in:c,nodeRef:y,onEnter:D,onEntered:T,onEntering:P,onExit:A,onExited:C,onExiting:I,addEndListener:j,timeout:x,...w,children:(N,{ownerState:M,...R})=>O.cloneElement(s,{style:{opacity:0,visibility:N==="exited"&&!c?"hidden":void 0,...Roe[N],...v,...s.props.style},ref:E,...R})})});process.env.NODE_ENV!=="production"&&(Cj.propTypes={addEndListener:b.func,appear:b.bool,children:Dl.isRequired,easing:b.oneOfType([b.shape({enter:b.string,exit:b.string}),b.string]),in:b.bool,onEnter:b.func,onEntered:b.func,onEntering:b.func,onExit:b.func,onExited:b.func,onExiting:b.func,style:b.object,timeout:b.oneOfType([b.number,b.shape({appear:b.number,enter:b.number,exit:b.number})])});function $oe(e){return xn("MuiBackdrop",e)}Vn("MuiBackdrop",["root","invisible"]);const Boe=e=>{const{classes:t,invisible:n}=e;return kn({root:["root",n&&"invisible"]},$oe,t)},Woe=De("div",{name:"MuiBackdrop",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.invisible&&t.invisible]}})({position:"fixed",display:"flex",alignItems:"center",justifyContent:"center",right:0,bottom:0,top:0,left:0,backgroundColor:"rgba(0, 0, 0, 0.5)",WebkitTapHighlightColor:"transparent",variants:[{props:{invisible:!0},style:{backgroundColor:"transparent"}}]}),kj=O.forwardRef(function(t,n){const r=Zn({props:t,name:"MuiBackdrop"}),{children:i,className:o,component:a="div",invisible:s=!1,open:l,components:c={},componentsProps:u={},slotProps:d={},slots:f={},TransitionComponent:p,transitionDuration:m,...g}=r,v={...r,component:a,invisible:s},x=Boe(v),_={transition:p,root:c.Root,...f},w={...u,...d},y={component:a,slots:_,slotProps:w},[E,S]=lr("root",{elementType:Woe,externalForwardedProps:y,className:ue(x.root,o),ownerState:v}),[P,D]=lr("transition",{elementType:Cj,externalForwardedProps:y,ownerState:v});return h.jsx(P,{in:l,timeout:m,...g,...D,children:h.jsx(E,{"aria-hidden":!0,...S,classes:x,ref:n,children:i})})});process.env.NODE_ENV!=="production"&&(kj.propTypes={children:b.node,classes:b.object,className:b.string,component:b.elementType,components:b.shape({Root:b.elementType}),componentsProps:b.shape({root:b.object}),invisible:b.bool,open:b.bool.isRequired,slotProps:b.shape({root:b.oneOfType([b.func,b.object]),transition:b.oneOfType([b.func,b.object])}),slots:b.shape({root:b.elementType,transition:b.elementType}),sx:b.oneOfType([b.arrayOf(b.oneOfType([b.func,b.object,b.bool])),b.func,b.object]),TransitionComponent:b.elementType,transitionDuration:b.oneOfType([b.number,b.shape({appear:b.number,enter:b.number,exit:b.number})])});function Pj(e=window){const t=e.document.documentElement.clientWidth;return e.innerWidth-t}function zoe(e){const t=gr(e);return t.body===e?Ji(e).innerWidth>t.documentElement.clientWidth:e.scrollHeight>e.clientHeight}function ku(e,t){t?e.setAttribute("aria-hidden","true"):e.removeAttribute("aria-hidden")}function Dj(e){return parseInt(Ji(e).getComputedStyle(e).paddingRight,10)||0}function Voe(e){const n=["TEMPLATE","SCRIPT","STYLE","LINK","MAP","META","NOSCRIPT","PICTURE","COL","COLGROUP","PARAM","SLOT","SOURCE","TRACK"].includes(e.tagName),r=e.tagName==="INPUT"&&e.getAttribute("type")==="hidden";return n||r}function Aj(e,t,n,r,i){const o=[t,n,...r];[].forEach.call(e.children,a=>{const s=!o.includes(a),l=!Voe(a);s&&l&&ku(a,i)})}function Ix(e,t){let n=-1;return e.some((r,i)=>t(r)?(n=i,!0):!1),n}function Hoe(e,t){const n=[],r=e.container;if(!t.disableScrollLock){if(zoe(r)){const a=Pj(Ji(r));n.push({value:r.style.paddingRight,property:"padding-right",el:r}),r.style.paddingRight=`${Dj(r)+a}px`;const s=gr(r).querySelectorAll(".mui-fixed");[].forEach.call(s,l=>{n.push({value:l.style.paddingRight,property:"padding-right",el:l}),l.style.paddingRight=`${Dj(l)+a}px`})}let o;if(r.parentNode instanceof DocumentFragment)o=gr(r).body;else{const a=r.parentElement,s=Ji(r);o=a?.nodeName==="HTML"&&s.getComputedStyle(a).overflowY==="scroll"?a:r}n.push({value:o.style.overflow,property:"overflow",el:o},{value:o.style.overflowX,property:"overflow-x",el:o},{value:o.style.overflowY,property:"overflow-y",el:o}),o.style.overflow="hidden"}return()=>{n.forEach(({value:o,el:a,property:s})=>{o?a.style.setProperty(s,o):a.style.removeProperty(s)})}}function Yoe(e){const t=[];return[].forEach.call(e.children,n=>{n.getAttribute("aria-hidden")==="true"&&t.push(n)}),t}class Uoe{constructor(){this.modals=[],this.containers=[]}add(t,n){let r=this.modals.indexOf(t);if(r!==-1)return r;r=this.modals.length,this.modals.push(t),t.modalRef&&ku(t.modalRef,!1);const i=Yoe(n);Aj(n,t.mount,t.modalRef,i,!0);const o=Ix(this.containers,a=>a.container===n);return o!==-1?(this.containers[o].modals.push(t),r):(this.containers.push({modals:[t],container:n,restore:null,hiddenSiblings:i}),r)}mount(t,n){const r=Ix(this.containers,o=>o.modals.includes(t)),i=this.containers[r];i.restore||(i.restore=Hoe(i,n))}remove(t,n=!0){const r=this.modals.indexOf(t);if(r===-1)return r;const i=Ix(this.containers,a=>a.modals.includes(t)),o=this.containers[i];if(o.modals.splice(o.modals.indexOf(t),1),this.modals.splice(r,1),o.modals.length===0)o.restore&&o.restore(),t.modalRef&&ku(t.modalRef,n),Aj(o.container,t.mount,t.modalRef,o.hiddenSiblings,!1),this.containers.splice(i,1);else{const a=o.modals[o.modals.length-1];a.modalRef&&ku(a.modalRef,!1)}return r}isTopModal(t){return this.modals.length>0&&this.modals[this.modals.length-1]===t}}const Koe=["input","select","textarea","a[href]","button","[tabindex]","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable="false"])'].join(",");function qoe(e){const t=parseInt(e.getAttribute("tabindex")||"",10);return Number.isNaN(t)?e.contentEditable==="true"||(e.nodeName==="AUDIO"||e.nodeName==="VIDEO"||e.nodeName==="DETAILS")&&e.getAttribute("tabindex")===null?0:e.tabIndex:t}function Goe(e){if(e.tagName!=="INPUT"||e.type!=="radio"||!e.name)return!1;const t=r=>e.ownerDocument.querySelector(`input[type="radio"]${r}`);let n=t(`[name="${e.name}"]:checked`);return n||(n=t(`[name="${e.name}"]`)),n!==e}function Xoe(e){return!(e.disabled||e.tagName==="INPUT"&&e.type==="hidden"||Goe(e))}function Qoe(e){const t=[],n=[];return Array.from(e.querySelectorAll(Koe)).forEach((r,i)=>{const o=qoe(r);o===-1||!Xoe(r)||(o===0?t.push(r):n.push({documentOrder:i,tabIndex:o,node:r}))}),n.sort((r,i)=>r.tabIndex===i.tabIndex?r.documentOrder-i.documentOrder:r.tabIndex-i.tabIndex).map(r=>r.node).concat(t)}function Zoe(){return!0}function Th(e){const{children:t,disableAutoFocus:n=!1,disableEnforceFocus:r=!1,disableRestoreFocus:i=!1,getTabbable:o=Qoe,isEnabled:a=Zoe,open:s}=e,l=O.useRef(!1),c=O.useRef(null),u=O.useRef(null),d=O.useRef(null),f=O.useRef(null),p=O.useRef(!1),m=O.useRef(null),g=Yn(kl(t),m),v=O.useRef(null);O.useEffect(()=>{!s||!m.current||(p.current=!n)},[n,s]),O.useEffect(()=>{if(!s||!m.current)return;const w=gr(m.current);return m.current.contains(w.activeElement)||(m.current.hasAttribute("tabIndex")||(process.env.NODE_ENV!=="production"&&console.error(["MUI: The modal content node does not accept focus.",'For the benefit of assistive technologies, the tabIndex of the node is being set to "-1".'].join(`
|
|
251
|
-
`)),m.current.setAttribute("tabIndex","-1")),p.current&&m.current.focus()),()=>{i||(d.current&&d.current.focus&&(l.current=!0,d.current.focus()),d.current=null)}},[s]),O.useEffect(()=>{if(!s||!m.current)return;const w=gr(m.current),y=P=>{v.current=P,!(r||!a()||P.key!=="Tab")&&w.activeElement===m.current&&P.shiftKey&&(l.current=!0,u.current&&u.current.focus())},E=()=>{const P=m.current;if(P===null)return;if(!w.hasFocus()||!a()||l.current){l.current=!1;return}if(P.contains(w.activeElement)||r&&w.activeElement!==c.current&&w.activeElement!==u.current)return;if(w.activeElement!==f.current)f.current=null;else if(f.current!==null)return;if(!p.current)return;let D=[];if((w.activeElement===c.current||w.activeElement===u.current)&&(D=o(m.current)),D.length>0){const T=!!(v.current?.shiftKey&&v.current?.key==="Tab"),I=D[0],A=D[D.length-1];typeof I!="string"&&typeof A!="string"&&(T?A.focus():I.focus())}else P.focus()};w.addEventListener("focusin",E),w.addEventListener("keydown",y,!0);const S=setInterval(()=>{w.activeElement&&w.activeElement.tagName==="BODY"&&E()},50);return()=>{clearInterval(S),w.removeEventListener("focusin",E),w.removeEventListener("keydown",y,!0)}},[n,r,i,a,s,o]);const x=w=>{d.current===null&&(d.current=w.relatedTarget),p.current=!0,f.current=w.target;const y=t.props.onFocus;y&&y(w)},_=w=>{d.current===null&&(d.current=w.relatedTarget),p.current=!0};return h.jsxs(O.Fragment,{children:[h.jsx("div",{tabIndex:s?0:-1,onFocus:_,ref:c,"data-testid":"sentinelStart"}),O.cloneElement(t,{ref:g,onFocus:x}),h.jsx("div",{tabIndex:s?0:-1,onFocus:_,ref:u,"data-testid":"sentinelEnd"})]})}process.env.NODE_ENV!=="production"&&(Th.propTypes={children:Dl,disableAutoFocus:b.bool,disableEnforceFocus:b.bool,disableRestoreFocus:b.bool,getTabbable:b.func,isEnabled:b.func,open:b.bool.isRequired}),process.env.NODE_ENV!=="production"&&(Th.propTypes=i_(Th.propTypes));function Joe(e){return typeof e=="function"?e():e}function eae(e){return e?e.props.hasOwnProperty("in"):!1}const Tj=()=>{},Nh=new Uoe;function tae(e){const{container:t,disableEscapeKeyDown:n=!1,disableScrollLock:r=!1,closeAfterTransition:i=!1,onTransitionEnter:o,onTransitionExited:a,children:s,onClose:l,open:c,rootRef:u}=e,d=O.useRef({}),f=O.useRef(null),p=O.useRef(null),m=Yn(p,u),[g,v]=O.useState(!c),x=eae(s);let _=!0;(e["aria-hidden"]==="false"||e["aria-hidden"]===!1)&&(_=!1);const w=()=>gr(f.current),y=()=>(d.current.modalRef=p.current,d.current.mount=f.current,d.current),E=()=>{Nh.mount(y(),{disableScrollLock:r}),p.current&&(p.current.scrollTop=0)},S=oc(()=>{const M=Joe(t)||w().body;Nh.add(y(),M),p.current&&E()}),P=()=>Nh.isTopModal(y()),D=oc(M=>{f.current=M,M&&(c&&P()?E():p.current&&ku(p.current,_))}),T=O.useCallback(()=>{Nh.remove(y(),_)},[_]);O.useEffect(()=>()=>{T()},[T]),O.useEffect(()=>{c?S():(!x||!i)&&T()},[c,T,x,i,S]);const I=M=>R=>{M.onKeyDown?.(R),!(R.key!=="Escape"||R.which===229||!P())&&(n||(R.stopPropagation(),l&&l(R,"escapeKeyDown")))},A=M=>R=>{M.onClick?.(R),R.target===R.currentTarget&&l&&l(R,"backdropClick")};return{getRootProps:(M={})=>{const R=pj(e);delete R.onTransitionEnter,delete R.onTransitionExited;const B={...R,...M};return{role:"presentation",...B,onKeyDown:I(B),ref:m}},getBackdropProps:(M={})=>{const R=M;return{"aria-hidden":!0,...R,onClick:A(R),open:c}},getTransitionProps:()=>{const M=()=>{v(!1),o&&o()},R=()=>{v(!0),a&&a(),i&&T()};return{onEnter:X1(M,s?.props.onEnter??Tj),onExited:X1(R,s?.props.onExited??Tj)}},rootRef:m,portalRef:D,isTopModal:P,exited:g,hasTransition:x}}function nae(e){return xn("MuiModal",e)}Vn("MuiModal",["root","hidden","backdrop"]);const rae=e=>{const{open:t,exited:n,classes:r}=e;return kn({root:["root",!t&&n&&"hidden"],backdrop:["backdrop"]},nae,r)},iae=De("div",{name:"MuiModal",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,!n.open&&n.exited&&t.hidden]}})(Hn(({theme:e})=>({position:"fixed",zIndex:(e.vars||e).zIndex.modal,right:0,bottom:0,top:0,left:0,variants:[{props:({ownerState:t})=>!t.open&&t.exited,style:{visibility:"hidden"}}]}))),oae=De(kj,{name:"MuiModal",slot:"Backdrop"})({zIndex:-1}),Nj=O.forwardRef(function(t,n){const r=Zn({name:"MuiModal",props:t}),{BackdropComponent:i=oae,BackdropProps:o,classes:a,className:s,closeAfterTransition:l=!1,children:c,container:u,component:d,components:f={},componentsProps:p={},disableAutoFocus:m=!1,disableEnforceFocus:g=!1,disableEscapeKeyDown:v=!1,disablePortal:x=!1,disableRestoreFocus:_=!1,disableScrollLock:w=!1,hideBackdrop:y=!1,keepMounted:E=!1,onClose:S,onTransitionEnter:P,onTransitionExited:D,open:T,slotProps:I={},slots:A={},theme:C,...j}=r,N={...r,closeAfterTransition:l,disableAutoFocus:m,disableEnforceFocus:g,disableEscapeKeyDown:v,disablePortal:x,disableRestoreFocus:_,disableScrollLock:w,hideBackdrop:y,keepMounted:E},{getRootProps:M,getBackdropProps:R,getTransitionProps:B,portalRef:V,isTopModal:z,exited:W,hasTransition:Q}=tae({...N,rootRef:n}),X={...N,exited:W},ie=rae(X),J={};if(c.props.tabIndex===void 0&&(J.tabIndex="-1"),Q){const{onEnter:U,onExited:Z}=B();J.onEnter=U,J.onExited=Z}const re={slots:{root:f.Root,backdrop:f.Backdrop,...A},slotProps:{...p,...I}},[se,ce]=lr("root",{ref:n,elementType:iae,externalForwardedProps:{...re,...j,component:d},getSlotProps:M,ownerState:X,className:ue(s,ie?.root,!X.open&&X.exited&&ie?.hidden)}),[de,K]=lr("backdrop",{ref:o?.ref,elementType:i,externalForwardedProps:re,shouldForwardComponentProp:!0,additionalProps:o,getSlotProps:U=>R({...U,onClick:Z=>{U?.onClick&&U.onClick(Z)}}),className:ue(o?.className,ie?.backdrop),ownerState:X});return!E&&!T&&(!Q||W)?null:h.jsx(Ou,{ref:V,container:u,disablePortal:x,children:h.jsxs(se,{...ce,children:[!y&&i?h.jsx(de,{...K}):null,h.jsx(Th,{disableEnforceFocus:g,disableAutoFocus:m,disableRestoreFocus:_,isEnabled:z,open:T,children:O.cloneElement(c,J)})]})})});process.env.NODE_ENV!=="production"&&(Nj.propTypes={BackdropComponent:b.elementType,BackdropProps:b.object,children:Dl.isRequired,classes:b.object,className:b.string,closeAfterTransition:b.bool,component:b.elementType,components:b.shape({Backdrop:b.elementType,Root:b.elementType}),componentsProps:b.shape({backdrop:b.oneOfType([b.func,b.object]),root:b.oneOfType([b.func,b.object])}),container:b.oneOfType([Do,b.func]),disableAutoFocus:b.bool,disableEnforceFocus:b.bool,disableEscapeKeyDown:b.bool,disablePortal:b.bool,disableRestoreFocus:b.bool,disableScrollLock:b.bool,hideBackdrop:b.bool,keepMounted:b.bool,onClose:b.func,onTransitionEnter:b.func,onTransitionExited:b.func,open:b.bool.isRequired,slotProps:b.shape({backdrop:b.oneOfType([b.func,b.object]),root:b.oneOfType([b.func,b.object])}),slots:b.shape({backdrop:b.elementType,root:b.elementType}),sx:b.oneOfType([b.arrayOf(b.oneOfType([b.func,b.object,b.bool])),b.func,b.object])});const aae=e=>{const{classes:t,disableUnderline:n,startAdornment:r,endAdornment:i,size:o,hiddenLabel:a,multiline:s}=e,l={root:["root",!n&&"underline",r&&"adornedStart",i&&"adornedEnd",o==="small"&&`size${yn(o)}`,a&&"hiddenLabel",s&&"multiline"],input:["input"]},c=kn(l,Ioe,t);return{...t,...c}},sae=De(Ph,{shouldForwardProp:e=>Zi(e)||e==="classes",name:"MuiFilledInput",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[...Ch(e,t),!n.disableUnderline&&t.underline]}})(Hn(({theme:e})=>{const t=e.palette.mode==="light",n=t?"rgba(0, 0, 0, 0.42)":"rgba(255, 255, 255, 0.7)",r=t?"rgba(0, 0, 0, 0.06)":"rgba(255, 255, 255, 0.09)",i=t?"rgba(0, 0, 0, 0.09)":"rgba(255, 255, 255, 0.13)",o=t?"rgba(0, 0, 0, 0.12)":"rgba(255, 255, 255, 0.12)";return{position:"relative",backgroundColor:e.vars?e.vars.palette.FilledInput.bg:r,borderTopLeftRadius:(e.vars||e).shape.borderRadius,borderTopRightRadius:(e.vars||e).shape.borderRadius,transition:e.transitions.create("background-color",{duration:e.transitions.duration.shorter,easing:e.transitions.easing.easeOut}),"&:hover":{backgroundColor:e.vars?e.vars.palette.FilledInput.hoverBg:i,"@media (hover: none)":{backgroundColor:e.vars?e.vars.palette.FilledInput.bg:r}},[`&.${ss.focused}`]:{backgroundColor:e.vars?e.vars.palette.FilledInput.bg:r},[`&.${ss.disabled}`]:{backgroundColor:e.vars?e.vars.palette.FilledInput.disabledBg:o},variants:[{props:({ownerState:a})=>!a.disableUnderline,style:{"&::after":{left:0,bottom:0,content:'""',position:"absolute",right:0,transform:"scaleX(0)",transition:e.transitions.create("transform",{duration:e.transitions.duration.shorter,easing:e.transitions.easing.easeOut}),pointerEvents:"none"},[`&.${ss.focused}:after`]:{transform:"scaleX(1) translateX(0)"},[`&.${ss.error}`]:{"&::before, &::after":{borderBottomColor:(e.vars||e).palette.error.main}},"&::before":{borderBottom:`1px solid ${e.vars?e.alpha(e.vars.palette.common.onBackground,e.vars.opacity.inputUnderline):n}`,left:0,bottom:0,content:'"\\00a0"',position:"absolute",right:0,transition:e.transitions.create("border-bottom-color",{duration:e.transitions.duration.shorter}),pointerEvents:"none"},[`&:hover:not(.${ss.disabled}, .${ss.error}):before`]:{borderBottom:`1px solid ${(e.vars||e).palette.text.primary}`},[`&.${ss.disabled}:before`]:{borderBottomStyle:"dotted"}}},...Object.entries(e.palette).filter(Ax()).map(([a])=>({props:{disableUnderline:!1,color:a},style:{"&::after":{borderBottom:`2px solid ${(e.vars||e).palette[a]?.main}`}}})),{props:({ownerState:a})=>a.startAdornment,style:{paddingLeft:12}},{props:({ownerState:a})=>a.endAdornment,style:{paddingRight:12}},{props:({ownerState:a})=>a.multiline,style:{padding:"25px 12px 8px"}},{props:({ownerState:a,size:s})=>a.multiline&&s==="small",style:{paddingTop:21,paddingBottom:4}},{props:({ownerState:a})=>a.multiline&&a.hiddenLabel,style:{paddingTop:16,paddingBottom:17}},{props:({ownerState:a})=>a.multiline&&a.hiddenLabel&&a.size==="small",style:{paddingTop:8,paddingBottom:9}}]}})),lae=De(Dh,{name:"MuiFilledInput",slot:"Input",overridesResolver:kh})(Hn(({theme:e})=>({paddingTop:25,paddingRight:12,paddingBottom:8,paddingLeft:12,...!e.vars&&{"&:-webkit-autofill":{WebkitBoxShadow:e.palette.mode==="light"?null:"0 0 0 100px #266798 inset",WebkitTextFillColor:e.palette.mode==="light"?null:"#fff",caretColor:e.palette.mode==="light"?null:"#fff",borderTopLeftRadius:"inherit",borderTopRightRadius:"inherit"}},...e.vars&&{"&:-webkit-autofill":{borderTopLeftRadius:"inherit",borderTopRightRadius:"inherit"},[e.getColorSchemeSelector("dark")]:{"&:-webkit-autofill":{WebkitBoxShadow:"0 0 0 100px #266798 inset",WebkitTextFillColor:"#fff",caretColor:"#fff"}}},variants:[{props:{size:"small"},style:{paddingTop:21,paddingBottom:4}},{props:({ownerState:t})=>t.hiddenLabel,style:{paddingTop:16,paddingBottom:17}},{props:({ownerState:t})=>t.startAdornment,style:{paddingLeft:0}},{props:({ownerState:t})=>t.endAdornment,style:{paddingRight:0}},{props:({ownerState:t})=>t.hiddenLabel&&t.size==="small",style:{paddingTop:8,paddingBottom:9}},{props:({ownerState:t})=>t.multiline,style:{paddingTop:0,paddingBottom:0,paddingLeft:0,paddingRight:0}}]}))),Fx=O.forwardRef(function(t,n){const r=Zn({props:t,name:"MuiFilledInput"}),{disableUnderline:i=!1,components:o={},componentsProps:a,fullWidth:s=!1,hiddenLabel:l,inputComponent:c="input",multiline:u=!1,slotProps:d,slots:f={},type:p="text",...m}=r,g={...r,disableUnderline:i,fullWidth:s,inputComponent:c,multiline:u,type:p},v=aae(r),x={root:{ownerState:g},input:{ownerState:g}},_=d??a?Pn(x,d??a):x,w=f.root??o.Root??sae,y=f.input??o.Input??lae;return h.jsx(Ah,{slots:{root:w,input:y},slotProps:_,fullWidth:s,inputComponent:c,multiline:u,ref:n,type:p,...m,classes:v})});process.env.NODE_ENV!=="production"&&(Fx.propTypes={autoComplete:b.string,autoFocus:b.bool,classes:b.object,color:b.oneOfType([b.oneOf(["primary","secondary"]),b.string]),components:b.shape({Input:b.elementType,Root:b.elementType}),componentsProps:b.shape({input:b.object,root:b.object}),defaultValue:b.any,disabled:b.bool,disableUnderline:b.bool,endAdornment:b.node,error:b.bool,fullWidth:b.bool,hiddenLabel:b.bool,id:b.string,inputComponent:b.elementType,inputProps:b.object,inputRef:Po,margin:b.oneOf(["dense","none"]),maxRows:b.oneOfType([b.number,b.string]),minRows:b.oneOfType([b.number,b.string]),multiline:b.bool,name:b.string,onChange:b.func,placeholder:b.string,readOnly:b.bool,required:b.bool,rows:b.oneOfType([b.number,b.string]),slotProps:b.shape({input:b.object,root:b.object}),slots:b.shape({input:b.elementType,root:b.elementType}),startAdornment:b.node,sx:b.oneOfType([b.arrayOf(b.oneOfType([b.func,b.object,b.bool])),b.func,b.object]),type:b.string,value:b.any}),Fx.muiName="Input";function Lx(e){return`scale(${e}, ${e**2})`}const cae={entering:{opacity:1,transform:Lx(1)},entered:{opacity:1,transform:"none"}},Rx=typeof navigator<"u"&&/^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent)&&/(os |version\/)15(.|_)4/i.test(navigator.userAgent),Pu=O.forwardRef(function(t,n){const{addEndListener:r,appear:i=!0,children:o,easing:a,in:s,onEnter:l,onEntered:c,onEntering:u,onExit:d,onExited:f,onExiting:p,style:m,timeout:g="auto",TransitionComponent:v=Bi,...x}=t,_=Su(),w=O.useRef(),y=Id(),E=O.useRef(null),S=Yn(E,kl(o),n),P=M=>R=>{if(M){const B=E.current;R===void 0?M(B):M(B,R)}},D=P(u),T=P((M,R)=>{aj(M);const{duration:B,delay:V,easing:z}=wh({style:m,timeout:g,easing:a},{mode:"enter"});let W;g==="auto"?(W=y.transitions.getAutoHeightDuration(M.clientHeight),w.current=W):W=B,M.style.transition=[y.transitions.create("opacity",{duration:W,delay:V}),y.transitions.create("transform",{duration:Rx?W:W*.666,delay:V,easing:z})].join(","),l&&l(M,R)}),I=P(c),A=P(p),C=P(M=>{const{duration:R,delay:B,easing:V}=wh({style:m,timeout:g,easing:a},{mode:"exit"});let z;g==="auto"?(z=y.transitions.getAutoHeightDuration(M.clientHeight),w.current=z):z=R,M.style.transition=[y.transitions.create("opacity",{duration:z,delay:B}),y.transitions.create("transform",{duration:Rx?z:z*.666,delay:Rx?B:B||z*.333,easing:V})].join(","),M.style.opacity=0,M.style.transform=Lx(.75),d&&d(M)}),j=P(f),N=M=>{g==="auto"&&_.start(w.current||0,M),r&&r(E.current,M)};return h.jsx(v,{appear:i,in:s,nodeRef:E,onEnter:T,onEntered:I,onEntering:D,onExit:C,onExited:j,onExiting:A,addEndListener:N,timeout:g==="auto"?null:g,...x,children:(M,{ownerState:R,...B})=>O.cloneElement(o,{style:{opacity:0,transform:Lx(.75),visibility:M==="exited"&&!s?"hidden":void 0,...cae[M],...m,...o.props.style},ref:S,...B})})});process.env.NODE_ENV!=="production"&&(Pu.propTypes={addEndListener:b.func,appear:b.bool,children:Dl.isRequired,easing:b.oneOfType([b.shape({enter:b.string,exit:b.string}),b.string]),in:b.bool,onEnter:b.func,onEntered:b.func,onEntering:b.func,onExit:b.func,onExited:b.func,onExiting:b.func,style:b.object,timeout:b.oneOfType([b.oneOf(["auto"]),b.number,b.shape({appear:b.number,enter:b.number,exit:b.number})])}),Pu&&(Pu.muiSupportAuto=!0);const uae=e=>{const{classes:t,disableUnderline:n}=e,i=kn({root:["root",!n&&"underline"],input:["input"]},joe,t);return{...t,...i}},dae=De(Ph,{shouldForwardProp:e=>Zi(e)||e==="classes",name:"MuiInput",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[...Ch(e,t),!n.disableUnderline&&t.underline]}})(Hn(({theme:e})=>{let n=e.palette.mode==="light"?"rgba(0, 0, 0, 0.42)":"rgba(255, 255, 255, 0.7)";return e.vars&&(n=e.alpha(e.vars.palette.common.onBackground,e.vars.opacity.inputUnderline)),{position:"relative",variants:[{props:({ownerState:r})=>r.formControl,style:{"label + &":{marginTop:16}}},{props:({ownerState:r})=>!r.disableUnderline,style:{"&::after":{left:0,bottom:0,content:'""',position:"absolute",right:0,transform:"scaleX(0)",transition:e.transitions.create("transform",{duration:e.transitions.duration.shorter,easing:e.transitions.easing.easeOut}),pointerEvents:"none"},[`&.${Cu.focused}:after`]:{transform:"scaleX(1) translateX(0)"},[`&.${Cu.error}`]:{"&::before, &::after":{borderBottomColor:(e.vars||e).palette.error.main}},"&::before":{borderBottom:`1px solid ${n}`,left:0,bottom:0,content:'"\\00a0"',position:"absolute",right:0,transition:e.transitions.create("border-bottom-color",{duration:e.transitions.duration.shorter}),pointerEvents:"none"},[`&:hover:not(.${Cu.disabled}, .${Cu.error}):before`]:{borderBottom:`2px solid ${(e.vars||e).palette.text.primary}`,"@media (hover: none)":{borderBottom:`1px solid ${n}`}},[`&.${Cu.disabled}:before`]:{borderBottomStyle:"dotted"}}},...Object.entries(e.palette).filter(Ax()).map(([r])=>({props:{color:r,disableUnderline:!1},style:{"&::after":{borderBottom:`2px solid ${(e.vars||e).palette[r].main}`}}}))]}})),fae=De(Dh,{name:"MuiInput",slot:"Input",overridesResolver:kh})({}),$x=O.forwardRef(function(t,n){const r=Zn({props:t,name:"MuiInput"}),{disableUnderline:i=!1,components:o={},componentsProps:a,fullWidth:s=!1,inputComponent:l="input",multiline:c=!1,slotProps:u,slots:d={},type:f="text",...p}=r,m=uae(r),v={root:{ownerState:{disableUnderline:i}}},x=u??a?Pn(u??a,v):v,_=d.root??o.Root??dae,w=d.input??o.Input??fae;return h.jsx(Ah,{slots:{root:_,input:w},slotProps:x,fullWidth:s,inputComponent:l,multiline:c,ref:n,type:f,...p,classes:m})});process.env.NODE_ENV!=="production"&&($x.propTypes={autoComplete:b.string,autoFocus:b.bool,classes:b.object,color:b.oneOfType([b.oneOf(["primary","secondary"]),b.string]),components:b.shape({Input:b.elementType,Root:b.elementType}),componentsProps:b.shape({input:b.object,root:b.object}),defaultValue:b.any,disabled:b.bool,disableUnderline:b.bool,endAdornment:b.node,error:b.bool,fullWidth:b.bool,id:b.string,inputComponent:b.elementType,inputProps:b.object,inputRef:Po,margin:b.oneOf(["dense","none"]),maxRows:b.oneOfType([b.number,b.string]),minRows:b.oneOfType([b.number,b.string]),multiline:b.bool,name:b.string,onChange:b.func,placeholder:b.string,readOnly:b.bool,required:b.bool,rows:b.oneOfType([b.number,b.string]),slotProps:b.shape({input:b.object,root:b.object}),slots:b.shape({input:b.elementType,root:b.elementType}),startAdornment:b.node,sx:b.oneOfType([b.arrayOf(b.oneOfType([b.func,b.object,b.bool])),b.func,b.object]),type:b.string,value:b.any}),$x.muiName="Input";const jj=O.createContext({});process.env.NODE_ENV!=="production"&&(jj.displayName="ListContext");function pae(e){return xn("MuiList",e)}Vn("MuiList",["root","padding","dense","subheader"]);const hae=e=>{const{classes:t,disablePadding:n,dense:r,subheader:i}=e;return kn({root:["root",!n&&"padding",r&&"dense",i&&"subheader"]},pae,t)},mae=De("ul",{name:"MuiList",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,!n.disablePadding&&t.padding,n.dense&&t.dense,n.subheader&&t.subheader]}})({listStyle:"none",margin:0,padding:0,position:"relative",variants:[{props:({ownerState:e})=>!e.disablePadding,style:{paddingTop:8,paddingBottom:8}},{props:({ownerState:e})=>e.subheader,style:{paddingTop:0}}]}),Mj=O.forwardRef(function(t,n){const r=Zn({props:t,name:"MuiList"}),{children:i,className:o,component:a="ul",dense:s=!1,disablePadding:l=!1,subheader:c,...u}=r,d=O.useMemo(()=>({dense:s}),[s]),f={...r,component:a,dense:s,disablePadding:l},p=hae(f);return h.jsx(jj.Provider,{value:d,children:h.jsxs(mae,{as:a,className:ue(p.root,o),ref:n,ownerState:f,...u,children:[c,i]})})});process.env.NODE_ENV!=="production"&&(Mj.propTypes={children:b.node,classes:b.object,className:b.string,component:b.elementType,dense:b.bool,disablePadding:b.bool,subheader:b.node,sx:b.oneOfType([b.arrayOf(b.oneOfType([b.func,b.object,b.bool])),b.func,b.object])});function Bx(e,t,n){return e===t?e.firstChild:t&&t.nextElementSibling?t.nextElementSibling:n?null:e.firstChild}function Ij(e,t,n){return e===t?n?e.firstChild:e.lastChild:t&&t.previousElementSibling?t.previousElementSibling:n?null:e.lastChild}function Fj(e,t){if(t===void 0)return!0;let n=e.innerText;return n===void 0&&(n=e.textContent),n=n.trim().toLowerCase(),n.length===0?!1:t.repeating?n[0]===t.keys[0]:n.startsWith(t.keys.join(""))}function Du(e,t,n,r,i,o){let a=!1,s=i(e,t,t?n:!1);for(;s;){if(s===e.firstChild){if(a)return!1;a=!0}const l=r?!1:s.disabled||s.getAttribute("aria-disabled")==="true";if(!s.hasAttribute("tabindex")||!Fj(s,o)||l)s=i(e,s,n);else return s.focus(),!0}return!1}const Lj=O.forwardRef(function(t,n){const{actions:r,autoFocus:i=!1,autoFocusItem:o=!1,children:a,className:s,disabledItemsFocusable:l=!1,disableListWrap:c=!1,onKeyDown:u,variant:d="selectedMenu",...f}=t,p=O.useRef(null),m=O.useRef({keys:[],repeating:!0,previousKeyMatched:!0,lastTime:null});Xi(()=>{i&&p.current.focus()},[i]),O.useImperativeHandle(r,()=>({adjustStyleForScrollbar:(w,{direction:y})=>{const E=!p.current.style.width;if(w.clientHeight<p.current.clientHeight&&E){const S=`${Pj(Ji(w))}px`;p.current.style[y==="rtl"?"paddingLeft":"paddingRight"]=S,p.current.style.width=`calc(100% + ${S})`}return p.current}}),[]);const g=w=>{const y=p.current,E=w.key;if(w.ctrlKey||w.metaKey||w.altKey){u&&u(w);return}const P=gr(y).activeElement;if(E==="ArrowDown")w.preventDefault(),Du(y,P,c,l,Bx);else if(E==="ArrowUp")w.preventDefault(),Du(y,P,c,l,Ij);else if(E==="Home")w.preventDefault(),Du(y,null,c,l,Bx);else if(E==="End")w.preventDefault(),Du(y,null,c,l,Ij);else if(E.length===1){const D=m.current,T=E.toLowerCase(),I=performance.now();D.keys.length>0&&(I-D.lastTime>500?(D.keys=[],D.repeating=!0,D.previousKeyMatched=!0):D.repeating&&T!==D.keys[0]&&(D.repeating=!1)),D.lastTime=I,D.keys.push(T);const A=P&&!D.repeating&&Fj(P,D);D.previousKeyMatched&&(A||Du(y,P,!1,l,Bx,D))?w.preventDefault():D.previousKeyMatched=!1}u&&u(w)},v=Yn(p,n);let x=-1;O.Children.forEach(a,(w,y)=>{if(!O.isValidElement(w)){x===y&&(x+=1,x>=a.length&&(x=-1));return}process.env.NODE_ENV!=="production"&&$o.isFragment(w)&&console.error(["MUI: The Menu component doesn't accept a Fragment as a child.","Consider providing an array instead."].join(`
|
|
249
|
+
`),P=y.selectionStart===E;S&&P&&y.setSelectionRange(E,E),r&&r(w)};return h.jsxs(O.Fragment,{children:[h.jsx("textarea",{value:s,onChange:_,ref:d,rows:o,style:a,...l}),h.jsx("textarea",{"aria-hidden":!0,className:t.className,readOnly:!0,ref:p,tabIndex:-1,style:{...Doe.shadow,...a,paddingTop:0,paddingBottom:0}})]})});process.env.NODE_ENV!=="production"&&(xj.propTypes={className:b.string,maxRows:b.oneOfType([b.number,b.string]),minRows:b.oneOfType([b.number,b.string]),onChange:b.func,placeholder:b.string,style:b.object,value:b.oneOfType([b.arrayOf(b.string),b.number,b.string])});function Nx({props:e,states:t,muiFormControl:n}){return t.reduce((r,i)=>(r[i]=e[i],n&&typeof e[i]>"u"&&(r[i]=n[i]),r),{})}const jx=O.createContext(void 0);process.env.NODE_ENV!=="production"&&(jx.displayName="FormControlContext");function Mx(){return O.useContext(jx)}function wj(e){return e!=null&&!(Array.isArray(e)&&e.length===0)}function _j(e,t=!1){return e&&(wj(e.value)&&e.value!==""||t&&wj(e.defaultValue)&&e.defaultValue!=="")}function Toe(e){return xn("MuiInputBase",e)}const Pl=Vn("MuiInputBase",["root","formControl","focused","disabled","adornedStart","adornedEnd","error","sizeSmall","multiline","colorSecondary","fullWidth","hiddenLabel","readOnly","input","inputSizeSmall","inputMultiline","inputTypeSearch","inputAdornedStart","inputAdornedEnd","inputHiddenLabel"]);var Ej;const Ch=(e,t)=>{const{ownerState:n}=e;return[t.root,n.formControl&&t.formControl,n.startAdornment&&t.adornedStart,n.endAdornment&&t.adornedEnd,n.error&&t.error,n.size==="small"&&t.sizeSmall,n.multiline&&t.multiline,n.color&&t[`color${yn(n.color)}`],n.fullWidth&&t.fullWidth,n.hiddenLabel&&t.hiddenLabel]},kh=(e,t)=>{const{ownerState:n}=e;return[t.input,n.size==="small"&&t.inputSizeSmall,n.multiline&&t.inputMultiline,n.type==="search"&&t.inputTypeSearch,n.startAdornment&&t.inputAdornedStart,n.endAdornment&&t.inputAdornedEnd,n.hiddenLabel&&t.inputHiddenLabel]},Noe=e=>{const{classes:t,color:n,disabled:r,error:i,endAdornment:o,focused:a,formControl:s,fullWidth:l,hiddenLabel:c,multiline:u,readOnly:d,size:f,startAdornment:p,type:m}=e,g={root:["root",`color${yn(n)}`,r&&"disabled",i&&"error",l&&"fullWidth",a&&"focused",s&&"formControl",f&&f!=="medium"&&`size${yn(f)}`,u&&"multiline",p&&"adornedStart",o&&"adornedEnd",c&&"hiddenLabel",d&&"readOnly"],input:["input",r&&"disabled",m==="search"&&"inputTypeSearch",u&&"inputMultiline",f==="small"&&"inputSizeSmall",c&&"inputHiddenLabel",p&&"inputAdornedStart",o&&"inputAdornedEnd",d&&"readOnly"]};return kn(g,Toe,t)},Ph=De("div",{name:"MuiInputBase",slot:"Root",overridesResolver:Ch})(Hn(({theme:e})=>({...e.typography.body1,color:(e.vars||e).palette.text.primary,lineHeight:"1.4375em",boxSizing:"border-box",position:"relative",cursor:"text",display:"inline-flex",alignItems:"center",[`&.${Pl.disabled}`]:{color:(e.vars||e).palette.text.disabled,cursor:"default"},variants:[{props:({ownerState:t})=>t.multiline,style:{padding:"4px 0 5px"}},{props:({ownerState:t,size:n})=>t.multiline&&n==="small",style:{paddingTop:1}},{props:({ownerState:t})=>t.fullWidth,style:{width:"100%"}}]}))),Dh=De("input",{name:"MuiInputBase",slot:"Input",overridesResolver:kh})(Hn(({theme:e})=>{const t=e.palette.mode==="light",n={color:"currentColor",...e.vars?{opacity:e.vars.opacity.inputPlaceholder}:{opacity:t?.42:.5},transition:e.transitions.create("opacity",{duration:e.transitions.duration.shorter})},r={opacity:"0 !important"},i=e.vars?{opacity:e.vars.opacity.inputPlaceholder}:{opacity:t?.42:.5};return{font:"inherit",letterSpacing:"inherit",color:"currentColor",padding:"4px 0 5px",border:0,boxSizing:"content-box",background:"none",height:"1.4375em",margin:0,WebkitTapHighlightColor:"transparent",display:"block",minWidth:0,width:"100%","&::-webkit-input-placeholder":n,"&::-moz-placeholder":n,"&::-ms-input-placeholder":n,"&:focus":{outline:0},"&:invalid":{boxShadow:"none"},"&::-webkit-search-decoration":{WebkitAppearance:"none"},[`label[data-shrink=false] + .${Pl.formControl} &`]:{"&::-webkit-input-placeholder":r,"&::-moz-placeholder":r,"&::-ms-input-placeholder":r,"&:focus::-webkit-input-placeholder":i,"&:focus::-moz-placeholder":i,"&:focus::-ms-input-placeholder":i},[`&.${Pl.disabled}`]:{opacity:1,WebkitTextFillColor:(e.vars||e).palette.text.disabled},variants:[{props:({ownerState:o})=>!o.disableInjectingGlobalStyles,style:{animationName:"mui-auto-fill-cancel",animationDuration:"10ms","&:-webkit-autofill":{animationDuration:"5000s",animationName:"mui-auto-fill"}}},{props:{size:"small"},style:{paddingTop:1}},{props:({ownerState:o})=>o.multiline,style:{height:"auto",resize:"none",padding:0,paddingTop:0}},{props:{type:"search"},style:{MozAppearance:"textfield"}}]}})),Sj=$$({"@keyframes mui-auto-fill":{from:{display:"block"}},"@keyframes mui-auto-fill-cancel":{from:{display:"block"}}}),Ah=O.forwardRef(function(t,n){const r=Zn({props:t,name:"MuiInputBase"}),{"aria-describedby":i,autoComplete:o,autoFocus:a,className:s,color:l,components:c={},componentsProps:u={},defaultValue:d,disabled:f,disableInjectingGlobalStyles:p,endAdornment:m,error:g,fullWidth:v=!1,id:x,inputComponent:_="input",inputProps:w={},inputRef:y,margin:E,maxRows:S,minRows:P,multiline:D=!1,name:T,onBlur:I,onChange:A,onClick:C,onFocus:j,onKeyDown:N,onKeyUp:M,placeholder:R,readOnly:B,renderSuffix:V,rows:z,size:W,slotProps:Q={},slots:G={},startAdornment:ie,type:J="text",value:re,...se}=r,ce=w.value!=null?w.value:re,{current:de}=O.useRef(ce!=null),K=O.useRef(),U=O.useCallback(be=>{process.env.NODE_ENV!=="production"&&be&&be.nodeName!=="INPUT"&&!be.focus&&console.error(["MUI: You have provided a `inputComponent` to the input component","that does not correctly handle the `ref` prop.","Make sure the `ref` prop is called with a HTMLInputElement."].join(`
|
|
250
|
+
`))},[]),Z=Yn(K,y,w.ref,U),[F,ge]=O.useState(!1),oe=Mx();process.env.NODE_ENV!=="production"&&O.useEffect(()=>{if(oe)return oe.registerEffect()},[oe]);const ye=Nx({props:r,muiFormControl:oe,states:["color","disabled","error","hiddenLabel","size","required","filled"]});ye.focused=oe?oe.focused:F,O.useEffect(()=>{!oe&&f&&F&&(ge(!1),I&&I())},[oe,f,F,I]);const _e=oe&&oe.onFilled,Ie=oe&&oe.onEmpty,tt=O.useCallback(be=>{_j(be)?_e&&_e():Ie&&Ie()},[_e,Ie]);Xi(()=>{de&&tt({value:ce})},[ce,tt,de]);const pt=be=>{j&&j(be),w.onFocus&&w.onFocus(be),oe&&oe.onFocus?oe.onFocus(be):ge(!0)},ct=be=>{I&&I(be),w.onBlur&&w.onBlur(be),oe&&oe.onBlur?oe.onBlur(be):ge(!1)},Fe=(be,...vn)=>{if(!de){const Qt=be.target||K.current;if(Qt==null)throw new Error(process.env.NODE_ENV!=="production"?"MUI: Expected valid input target. Did you use a custom `inputComponent` and forget to forward refs? See https://mui.com/r/input-component-ref-interface for more info.":pi(1));tt({value:Qt.value})}w.onChange&&w.onChange(be,...vn),A&&A(be,...vn)};O.useEffect(()=>{tt(K.current)},[]);const Pt=be=>{K.current&&be.currentTarget===be.target&&K.current.focus(),C&&C(be)};let Dt=_,ht=w;D&&Dt==="input"&&(z?(process.env.NODE_ENV!=="production"&&(P||S)&&console.warn("MUI: You can not use the `minRows` or `maxRows` props when the input `rows` prop is set."),ht={type:void 0,minRows:z,maxRows:z,...ht}):ht={type:void 0,maxRows:S,minRows:P,...ht},Dt=xj);const mn=be=>{tt(be.animationName==="mui-auto-fill-cancel"?K.current:{value:"x"})};O.useEffect(()=>{oe&&oe.setAdornedStart(!!ie)},[oe,ie]);const sn={...r,color:ye.color||"primary",disabled:ye.disabled,endAdornment:m,error:ye.error,focused:ye.focused,formControl:oe,fullWidth:v,hiddenLabel:ye.hiddenLabel,multiline:D,size:ye.size,startAdornment:ie,type:J},gn=Noe(sn),Wn=G.root||c.Root||Ph,Xt=Q.root||u.root||{},zn=G.input||c.Input||Dh;return ht={...ht,...Q.input??u.input},h.jsxs(O.Fragment,{children:[!p&&typeof Sj=="function"&&(Ej||(Ej=h.jsx(Sj,{}))),h.jsxs(Wn,{...Xt,ref:n,onClick:Pt,...se,...!_h(Wn)&&{ownerState:{...sn,...Xt.ownerState}},className:ue(gn.root,Xt.className,s,B&&"MuiInputBase-readOnly"),children:[ie,h.jsx(jx.Provider,{value:null,children:h.jsx(zn,{"aria-invalid":ye.error,"aria-describedby":i,autoComplete:o,autoFocus:a,defaultValue:d,disabled:ye.disabled,id:x,onAnimationStart:mn,name:T,placeholder:R,readOnly:B,required:ye.required,rows:z,value:ce,onKeyDown:N,onKeyUp:M,type:J,...ht,...!_h(zn)&&{as:Dt,ownerState:{...sn,...ht.ownerState}},ref:Z,className:ue(gn.input,ht.className,B&&"MuiInputBase-readOnly"),onBlur:ct,onChange:Fe,onFocus:pt})}),m,V?V({...ye,startAdornment:ie}):null]})]})});process.env.NODE_ENV!=="production"&&(Ah.propTypes={"aria-describedby":b.string,autoComplete:b.string,autoFocus:b.bool,classes:b.object,className:b.string,color:b.oneOfType([b.oneOf(["primary","secondary","error","info","success","warning"]),b.string]),components:b.shape({Input:b.elementType,Root:b.elementType}),componentsProps:b.shape({input:b.object,root:b.object}),defaultValue:b.any,disabled:b.bool,disableInjectingGlobalStyles:b.bool,endAdornment:b.node,error:b.bool,fullWidth:b.bool,id:b.string,inputComponent:oj,inputProps:b.object,inputRef:Po,margin:b.oneOf(["dense","none"]),maxRows:b.oneOfType([b.number,b.string]),minRows:b.oneOfType([b.number,b.string]),multiline:b.bool,name:b.string,onBlur:b.func,onChange:b.func,onClick:b.func,onFocus:b.func,onInvalid:b.func,onKeyDown:b.func,onKeyUp:b.func,placeholder:b.string,readOnly:b.bool,renderSuffix:b.func,required:b.bool,rows:b.oneOfType([b.number,b.string]),size:b.oneOfType([b.oneOf(["medium","small"]),b.string]),slotProps:b.shape({input:b.object,root:b.object}),slots:b.shape({input:b.elementType,root:b.elementType}),startAdornment:b.node,sx:b.oneOfType([b.arrayOf(b.oneOfType([b.func,b.object,b.bool])),b.func,b.object]),type:b.string,value:b.any});function joe(e){return xn("MuiInput",e)}const Cu={...Pl,...Vn("MuiInput",["root","underline","input"])};function Moe(e){return xn("MuiOutlinedInput",e)}const Wi={...Pl,...Vn("MuiOutlinedInput",["root","notchedOutline","input"])};function Ioe(e){return xn("MuiFilledInput",e)}const ss={...Pl,...Vn("MuiFilledInput",["root","underline","input","adornedStart","adornedEnd","sizeSmall","multiline","hiddenLabel"])},Foe=ic(h.jsx("path",{d:"M7 10l5 5 5-5z"}),"ArrowDropDown");function Loe(e){const{prototype:t={}}=e;return!!t.isReactComponent}function Oj(e,t,n,r,i){const o=e[t],a=i||t;if(o==null||typeof window>"u")return null;let s;const l=o.type;return typeof l=="function"&&!Loe(l)&&(s="Did you accidentally use a plain function component for an element instead?"),s!==void 0?new Error(`Invalid ${r} \`${a}\` supplied to \`${n}\`. Expected an element that can hold a ref. ${s} For more information see https://mui.com/r/caveat-with-refs-guide`):null}const Dl=Sl(b.element,Oj);Dl.isRequired=Sl(b.element.isRequired,Oj);const Roe={entering:{opacity:1},entered:{opacity:1}},Cj=O.forwardRef(function(t,n){const r=Id(),i={enter:r.transitions.duration.enteringScreen,exit:r.transitions.duration.leavingScreen},{addEndListener:o,appear:a=!0,children:s,easing:l,in:c,onEnter:u,onEntered:d,onEntering:f,onExit:p,onExited:m,onExiting:g,style:v,timeout:x=i,TransitionComponent:_=Bi,...w}=t,y=O.useRef(null),E=Yn(y,kl(s),n),S=N=>M=>{if(N){const R=y.current;M===void 0?N(R):N(R,M)}},P=S(f),D=S((N,M)=>{aj(N);const R=wh({style:v,timeout:x,easing:l},{mode:"enter"});N.style.webkitTransition=r.transitions.create("opacity",R),N.style.transition=r.transitions.create("opacity",R),u&&u(N,M)}),T=S(d),I=S(g),A=S(N=>{const M=wh({style:v,timeout:x,easing:l},{mode:"exit"});N.style.webkitTransition=r.transitions.create("opacity",M),N.style.transition=r.transitions.create("opacity",M),p&&p(N)}),C=S(m),j=N=>{o&&o(y.current,N)};return h.jsx(_,{appear:a,in:c,nodeRef:y,onEnter:D,onEntered:T,onEntering:P,onExit:A,onExited:C,onExiting:I,addEndListener:j,timeout:x,...w,children:(N,{ownerState:M,...R})=>O.cloneElement(s,{style:{opacity:0,visibility:N==="exited"&&!c?"hidden":void 0,...Roe[N],...v,...s.props.style},ref:E,...R})})});process.env.NODE_ENV!=="production"&&(Cj.propTypes={addEndListener:b.func,appear:b.bool,children:Dl.isRequired,easing:b.oneOfType([b.shape({enter:b.string,exit:b.string}),b.string]),in:b.bool,onEnter:b.func,onEntered:b.func,onEntering:b.func,onExit:b.func,onExited:b.func,onExiting:b.func,style:b.object,timeout:b.oneOfType([b.number,b.shape({appear:b.number,enter:b.number,exit:b.number})])});function $oe(e){return xn("MuiBackdrop",e)}Vn("MuiBackdrop",["root","invisible"]);const Boe=e=>{const{classes:t,invisible:n}=e;return kn({root:["root",n&&"invisible"]},$oe,t)},Woe=De("div",{name:"MuiBackdrop",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,n.invisible&&t.invisible]}})({position:"fixed",display:"flex",alignItems:"center",justifyContent:"center",right:0,bottom:0,top:0,left:0,backgroundColor:"rgba(0, 0, 0, 0.5)",WebkitTapHighlightColor:"transparent",variants:[{props:{invisible:!0},style:{backgroundColor:"transparent"}}]}),kj=O.forwardRef(function(t,n){const r=Zn({props:t,name:"MuiBackdrop"}),{children:i,className:o,component:a="div",invisible:s=!1,open:l,components:c={},componentsProps:u={},slotProps:d={},slots:f={},TransitionComponent:p,transitionDuration:m,...g}=r,v={...r,component:a,invisible:s},x=Boe(v),_={transition:p,root:c.Root,...f},w={...u,...d},y={component:a,slots:_,slotProps:w},[E,S]=lr("root",{elementType:Woe,externalForwardedProps:y,className:ue(x.root,o),ownerState:v}),[P,D]=lr("transition",{elementType:Cj,externalForwardedProps:y,ownerState:v});return h.jsx(P,{in:l,timeout:m,...g,...D,children:h.jsx(E,{"aria-hidden":!0,...S,classes:x,ref:n,children:i})})});process.env.NODE_ENV!=="production"&&(kj.propTypes={children:b.node,classes:b.object,className:b.string,component:b.elementType,components:b.shape({Root:b.elementType}),componentsProps:b.shape({root:b.object}),invisible:b.bool,open:b.bool.isRequired,slotProps:b.shape({root:b.oneOfType([b.func,b.object]),transition:b.oneOfType([b.func,b.object])}),slots:b.shape({root:b.elementType,transition:b.elementType}),sx:b.oneOfType([b.arrayOf(b.oneOfType([b.func,b.object,b.bool])),b.func,b.object]),TransitionComponent:b.elementType,transitionDuration:b.oneOfType([b.number,b.shape({appear:b.number,enter:b.number,exit:b.number})])});function Pj(e=window){const t=e.document.documentElement.clientWidth;return e.innerWidth-t}function zoe(e){const t=gr(e);return t.body===e?Ji(e).innerWidth>t.documentElement.clientWidth:e.scrollHeight>e.clientHeight}function ku(e,t){t?e.setAttribute("aria-hidden","true"):e.removeAttribute("aria-hidden")}function Dj(e){return parseInt(Ji(e).getComputedStyle(e).paddingRight,10)||0}function Voe(e){const n=["TEMPLATE","SCRIPT","STYLE","LINK","MAP","META","NOSCRIPT","PICTURE","COL","COLGROUP","PARAM","SLOT","SOURCE","TRACK"].includes(e.tagName),r=e.tagName==="INPUT"&&e.getAttribute("type")==="hidden";return n||r}function Aj(e,t,n,r,i){const o=[t,n,...r];[].forEach.call(e.children,a=>{const s=!o.includes(a),l=!Voe(a);s&&l&&ku(a,i)})}function Ix(e,t){let n=-1;return e.some((r,i)=>t(r)?(n=i,!0):!1),n}function Hoe(e,t){const n=[],r=e.container;if(!t.disableScrollLock){if(zoe(r)){const a=Pj(Ji(r));n.push({value:r.style.paddingRight,property:"padding-right",el:r}),r.style.paddingRight=`${Dj(r)+a}px`;const s=gr(r).querySelectorAll(".mui-fixed");[].forEach.call(s,l=>{n.push({value:l.style.paddingRight,property:"padding-right",el:l}),l.style.paddingRight=`${Dj(l)+a}px`})}let o;if(r.parentNode instanceof DocumentFragment)o=gr(r).body;else{const a=r.parentElement,s=Ji(r);o=a?.nodeName==="HTML"&&s.getComputedStyle(a).overflowY==="scroll"?a:r}n.push({value:o.style.overflow,property:"overflow",el:o},{value:o.style.overflowX,property:"overflow-x",el:o},{value:o.style.overflowY,property:"overflow-y",el:o}),o.style.overflow="hidden"}return()=>{n.forEach(({value:o,el:a,property:s})=>{o?a.style.setProperty(s,o):a.style.removeProperty(s)})}}function Yoe(e){const t=[];return[].forEach.call(e.children,n=>{n.getAttribute("aria-hidden")==="true"&&t.push(n)}),t}class Uoe{constructor(){this.modals=[],this.containers=[]}add(t,n){let r=this.modals.indexOf(t);if(r!==-1)return r;r=this.modals.length,this.modals.push(t),t.modalRef&&ku(t.modalRef,!1);const i=Yoe(n);Aj(n,t.mount,t.modalRef,i,!0);const o=Ix(this.containers,a=>a.container===n);return o!==-1?(this.containers[o].modals.push(t),r):(this.containers.push({modals:[t],container:n,restore:null,hiddenSiblings:i}),r)}mount(t,n){const r=Ix(this.containers,o=>o.modals.includes(t)),i=this.containers[r];i.restore||(i.restore=Hoe(i,n))}remove(t,n=!0){const r=this.modals.indexOf(t);if(r===-1)return r;const i=Ix(this.containers,a=>a.modals.includes(t)),o=this.containers[i];if(o.modals.splice(o.modals.indexOf(t),1),this.modals.splice(r,1),o.modals.length===0)o.restore&&o.restore(),t.modalRef&&ku(t.modalRef,n),Aj(o.container,t.mount,t.modalRef,o.hiddenSiblings,!1),this.containers.splice(i,1);else{const a=o.modals[o.modals.length-1];a.modalRef&&ku(a.modalRef,!1)}return r}isTopModal(t){return this.modals.length>0&&this.modals[this.modals.length-1]===t}}const Koe=["input","select","textarea","a[href]","button","[tabindex]","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable="false"])'].join(",");function qoe(e){const t=parseInt(e.getAttribute("tabindex")||"",10);return Number.isNaN(t)?e.contentEditable==="true"||(e.nodeName==="AUDIO"||e.nodeName==="VIDEO"||e.nodeName==="DETAILS")&&e.getAttribute("tabindex")===null?0:e.tabIndex:t}function Goe(e){if(e.tagName!=="INPUT"||e.type!=="radio"||!e.name)return!1;const t=r=>e.ownerDocument.querySelector(`input[type="radio"]${r}`);let n=t(`[name="${e.name}"]:checked`);return n||(n=t(`[name="${e.name}"]`)),n!==e}function Xoe(e){return!(e.disabled||e.tagName==="INPUT"&&e.type==="hidden"||Goe(e))}function Qoe(e){const t=[],n=[];return Array.from(e.querySelectorAll(Koe)).forEach((r,i)=>{const o=qoe(r);o===-1||!Xoe(r)||(o===0?t.push(r):n.push({documentOrder:i,tabIndex:o,node:r}))}),n.sort((r,i)=>r.tabIndex===i.tabIndex?r.documentOrder-i.documentOrder:r.tabIndex-i.tabIndex).map(r=>r.node).concat(t)}function Zoe(){return!0}function Th(e){const{children:t,disableAutoFocus:n=!1,disableEnforceFocus:r=!1,disableRestoreFocus:i=!1,getTabbable:o=Qoe,isEnabled:a=Zoe,open:s}=e,l=O.useRef(!1),c=O.useRef(null),u=O.useRef(null),d=O.useRef(null),f=O.useRef(null),p=O.useRef(!1),m=O.useRef(null),g=Yn(kl(t),m),v=O.useRef(null);O.useEffect(()=>{!s||!m.current||(p.current=!n)},[n,s]),O.useEffect(()=>{if(!s||!m.current)return;const w=gr(m.current);return m.current.contains(w.activeElement)||(m.current.hasAttribute("tabIndex")||(process.env.NODE_ENV!=="production"&&console.error(["MUI: The modal content node does not accept focus.",'For the benefit of assistive technologies, the tabIndex of the node is being set to "-1".'].join(`
|
|
251
|
+
`)),m.current.setAttribute("tabIndex","-1")),p.current&&m.current.focus()),()=>{i||(d.current&&d.current.focus&&(l.current=!0,d.current.focus()),d.current=null)}},[s]),O.useEffect(()=>{if(!s||!m.current)return;const w=gr(m.current),y=P=>{v.current=P,!(r||!a()||P.key!=="Tab")&&w.activeElement===m.current&&P.shiftKey&&(l.current=!0,u.current&&u.current.focus())},E=()=>{const P=m.current;if(P===null)return;if(!w.hasFocus()||!a()||l.current){l.current=!1;return}if(P.contains(w.activeElement)||r&&w.activeElement!==c.current&&w.activeElement!==u.current)return;if(w.activeElement!==f.current)f.current=null;else if(f.current!==null)return;if(!p.current)return;let D=[];if((w.activeElement===c.current||w.activeElement===u.current)&&(D=o(m.current)),D.length>0){const T=!!(v.current?.shiftKey&&v.current?.key==="Tab"),I=D[0],A=D[D.length-1];typeof I!="string"&&typeof A!="string"&&(T?A.focus():I.focus())}else P.focus()};w.addEventListener("focusin",E),w.addEventListener("keydown",y,!0);const S=setInterval(()=>{w.activeElement&&w.activeElement.tagName==="BODY"&&E()},50);return()=>{clearInterval(S),w.removeEventListener("focusin",E),w.removeEventListener("keydown",y,!0)}},[n,r,i,a,s,o]);const x=w=>{d.current===null&&(d.current=w.relatedTarget),p.current=!0,f.current=w.target;const y=t.props.onFocus;y&&y(w)},_=w=>{d.current===null&&(d.current=w.relatedTarget),p.current=!0};return h.jsxs(O.Fragment,{children:[h.jsx("div",{tabIndex:s?0:-1,onFocus:_,ref:c,"data-testid":"sentinelStart"}),O.cloneElement(t,{ref:g,onFocus:x}),h.jsx("div",{tabIndex:s?0:-1,onFocus:_,ref:u,"data-testid":"sentinelEnd"})]})}process.env.NODE_ENV!=="production"&&(Th.propTypes={children:Dl,disableAutoFocus:b.bool,disableEnforceFocus:b.bool,disableRestoreFocus:b.bool,getTabbable:b.func,isEnabled:b.func,open:b.bool.isRequired}),process.env.NODE_ENV!=="production"&&(Th.propTypes=i_(Th.propTypes));function Joe(e){return typeof e=="function"?e():e}function eae(e){return e?e.props.hasOwnProperty("in"):!1}const Tj=()=>{},Nh=new Uoe;function tae(e){const{container:t,disableEscapeKeyDown:n=!1,disableScrollLock:r=!1,closeAfterTransition:i=!1,onTransitionEnter:o,onTransitionExited:a,children:s,onClose:l,open:c,rootRef:u}=e,d=O.useRef({}),f=O.useRef(null),p=O.useRef(null),m=Yn(p,u),[g,v]=O.useState(!c),x=eae(s);let _=!0;(e["aria-hidden"]==="false"||e["aria-hidden"]===!1)&&(_=!1);const w=()=>gr(f.current),y=()=>(d.current.modalRef=p.current,d.current.mount=f.current,d.current),E=()=>{Nh.mount(y(),{disableScrollLock:r}),p.current&&(p.current.scrollTop=0)},S=oc(()=>{const M=Joe(t)||w().body;Nh.add(y(),M),p.current&&E()}),P=()=>Nh.isTopModal(y()),D=oc(M=>{f.current=M,M&&(c&&P()?E():p.current&&ku(p.current,_))}),T=O.useCallback(()=>{Nh.remove(y(),_)},[_]);O.useEffect(()=>()=>{T()},[T]),O.useEffect(()=>{c?S():(!x||!i)&&T()},[c,T,x,i,S]);const I=M=>R=>{M.onKeyDown?.(R),!(R.key!=="Escape"||R.which===229||!P())&&(n||(R.stopPropagation(),l&&l(R,"escapeKeyDown")))},A=M=>R=>{M.onClick?.(R),R.target===R.currentTarget&&l&&l(R,"backdropClick")};return{getRootProps:(M={})=>{const R=pj(e);delete R.onTransitionEnter,delete R.onTransitionExited;const B={...R,...M};return{role:"presentation",...B,onKeyDown:I(B),ref:m}},getBackdropProps:(M={})=>{const R=M;return{"aria-hidden":!0,...R,onClick:A(R),open:c}},getTransitionProps:()=>{const M=()=>{v(!1),o&&o()},R=()=>{v(!0),a&&a(),i&&T()};return{onEnter:X1(M,s?.props.onEnter??Tj),onExited:X1(R,s?.props.onExited??Tj)}},rootRef:m,portalRef:D,isTopModal:P,exited:g,hasTransition:x}}function nae(e){return xn("MuiModal",e)}Vn("MuiModal",["root","hidden","backdrop"]);const rae=e=>{const{open:t,exited:n,classes:r}=e;return kn({root:["root",!t&&n&&"hidden"],backdrop:["backdrop"]},nae,r)},iae=De("div",{name:"MuiModal",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,!n.open&&n.exited&&t.hidden]}})(Hn(({theme:e})=>({position:"fixed",zIndex:(e.vars||e).zIndex.modal,right:0,bottom:0,top:0,left:0,variants:[{props:({ownerState:t})=>!t.open&&t.exited,style:{visibility:"hidden"}}]}))),oae=De(kj,{name:"MuiModal",slot:"Backdrop"})({zIndex:-1}),Nj=O.forwardRef(function(t,n){const r=Zn({name:"MuiModal",props:t}),{BackdropComponent:i=oae,BackdropProps:o,classes:a,className:s,closeAfterTransition:l=!1,children:c,container:u,component:d,components:f={},componentsProps:p={},disableAutoFocus:m=!1,disableEnforceFocus:g=!1,disableEscapeKeyDown:v=!1,disablePortal:x=!1,disableRestoreFocus:_=!1,disableScrollLock:w=!1,hideBackdrop:y=!1,keepMounted:E=!1,onClose:S,onTransitionEnter:P,onTransitionExited:D,open:T,slotProps:I={},slots:A={},theme:C,...j}=r,N={...r,closeAfterTransition:l,disableAutoFocus:m,disableEnforceFocus:g,disableEscapeKeyDown:v,disablePortal:x,disableRestoreFocus:_,disableScrollLock:w,hideBackdrop:y,keepMounted:E},{getRootProps:M,getBackdropProps:R,getTransitionProps:B,portalRef:V,isTopModal:z,exited:W,hasTransition:Q}=tae({...N,rootRef:n}),G={...N,exited:W},ie=rae(G),J={};if(c.props.tabIndex===void 0&&(J.tabIndex="-1"),Q){const{onEnter:U,onExited:Z}=B();J.onEnter=U,J.onExited=Z}const re={slots:{root:f.Root,backdrop:f.Backdrop,...A},slotProps:{...p,...I}},[se,ce]=lr("root",{ref:n,elementType:iae,externalForwardedProps:{...re,...j,component:d},getSlotProps:M,ownerState:G,className:ue(s,ie?.root,!G.open&&G.exited&&ie?.hidden)}),[de,K]=lr("backdrop",{ref:o?.ref,elementType:i,externalForwardedProps:re,shouldForwardComponentProp:!0,additionalProps:o,getSlotProps:U=>R({...U,onClick:Z=>{U?.onClick&&U.onClick(Z)}}),className:ue(o?.className,ie?.backdrop),ownerState:G});return!E&&!T&&(!Q||W)?null:h.jsx(Ou,{ref:V,container:u,disablePortal:x,children:h.jsxs(se,{...ce,children:[!y&&i?h.jsx(de,{...K}):null,h.jsx(Th,{disableEnforceFocus:g,disableAutoFocus:m,disableRestoreFocus:_,isEnabled:z,open:T,children:O.cloneElement(c,J)})]})})});process.env.NODE_ENV!=="production"&&(Nj.propTypes={BackdropComponent:b.elementType,BackdropProps:b.object,children:Dl.isRequired,classes:b.object,className:b.string,closeAfterTransition:b.bool,component:b.elementType,components:b.shape({Backdrop:b.elementType,Root:b.elementType}),componentsProps:b.shape({backdrop:b.oneOfType([b.func,b.object]),root:b.oneOfType([b.func,b.object])}),container:b.oneOfType([Do,b.func]),disableAutoFocus:b.bool,disableEnforceFocus:b.bool,disableEscapeKeyDown:b.bool,disablePortal:b.bool,disableRestoreFocus:b.bool,disableScrollLock:b.bool,hideBackdrop:b.bool,keepMounted:b.bool,onClose:b.func,onTransitionEnter:b.func,onTransitionExited:b.func,open:b.bool.isRequired,slotProps:b.shape({backdrop:b.oneOfType([b.func,b.object]),root:b.oneOfType([b.func,b.object])}),slots:b.shape({backdrop:b.elementType,root:b.elementType}),sx:b.oneOfType([b.arrayOf(b.oneOfType([b.func,b.object,b.bool])),b.func,b.object])});const aae=e=>{const{classes:t,disableUnderline:n,startAdornment:r,endAdornment:i,size:o,hiddenLabel:a,multiline:s}=e,l={root:["root",!n&&"underline",r&&"adornedStart",i&&"adornedEnd",o==="small"&&`size${yn(o)}`,a&&"hiddenLabel",s&&"multiline"],input:["input"]},c=kn(l,Ioe,t);return{...t,...c}},sae=De(Ph,{shouldForwardProp:e=>Zi(e)||e==="classes",name:"MuiFilledInput",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[...Ch(e,t),!n.disableUnderline&&t.underline]}})(Hn(({theme:e})=>{const t=e.palette.mode==="light",n=t?"rgba(0, 0, 0, 0.42)":"rgba(255, 255, 255, 0.7)",r=t?"rgba(0, 0, 0, 0.06)":"rgba(255, 255, 255, 0.09)",i=t?"rgba(0, 0, 0, 0.09)":"rgba(255, 255, 255, 0.13)",o=t?"rgba(0, 0, 0, 0.12)":"rgba(255, 255, 255, 0.12)";return{position:"relative",backgroundColor:e.vars?e.vars.palette.FilledInput.bg:r,borderTopLeftRadius:(e.vars||e).shape.borderRadius,borderTopRightRadius:(e.vars||e).shape.borderRadius,transition:e.transitions.create("background-color",{duration:e.transitions.duration.shorter,easing:e.transitions.easing.easeOut}),"&:hover":{backgroundColor:e.vars?e.vars.palette.FilledInput.hoverBg:i,"@media (hover: none)":{backgroundColor:e.vars?e.vars.palette.FilledInput.bg:r}},[`&.${ss.focused}`]:{backgroundColor:e.vars?e.vars.palette.FilledInput.bg:r},[`&.${ss.disabled}`]:{backgroundColor:e.vars?e.vars.palette.FilledInput.disabledBg:o},variants:[{props:({ownerState:a})=>!a.disableUnderline,style:{"&::after":{left:0,bottom:0,content:'""',position:"absolute",right:0,transform:"scaleX(0)",transition:e.transitions.create("transform",{duration:e.transitions.duration.shorter,easing:e.transitions.easing.easeOut}),pointerEvents:"none"},[`&.${ss.focused}:after`]:{transform:"scaleX(1) translateX(0)"},[`&.${ss.error}`]:{"&::before, &::after":{borderBottomColor:(e.vars||e).palette.error.main}},"&::before":{borderBottom:`1px solid ${e.vars?e.alpha(e.vars.palette.common.onBackground,e.vars.opacity.inputUnderline):n}`,left:0,bottom:0,content:'"\\00a0"',position:"absolute",right:0,transition:e.transitions.create("border-bottom-color",{duration:e.transitions.duration.shorter}),pointerEvents:"none"},[`&:hover:not(.${ss.disabled}, .${ss.error}):before`]:{borderBottom:`1px solid ${(e.vars||e).palette.text.primary}`},[`&.${ss.disabled}:before`]:{borderBottomStyle:"dotted"}}},...Object.entries(e.palette).filter(Ax()).map(([a])=>({props:{disableUnderline:!1,color:a},style:{"&::after":{borderBottom:`2px solid ${(e.vars||e).palette[a]?.main}`}}})),{props:({ownerState:a})=>a.startAdornment,style:{paddingLeft:12}},{props:({ownerState:a})=>a.endAdornment,style:{paddingRight:12}},{props:({ownerState:a})=>a.multiline,style:{padding:"25px 12px 8px"}},{props:({ownerState:a,size:s})=>a.multiline&&s==="small",style:{paddingTop:21,paddingBottom:4}},{props:({ownerState:a})=>a.multiline&&a.hiddenLabel,style:{paddingTop:16,paddingBottom:17}},{props:({ownerState:a})=>a.multiline&&a.hiddenLabel&&a.size==="small",style:{paddingTop:8,paddingBottom:9}}]}})),lae=De(Dh,{name:"MuiFilledInput",slot:"Input",overridesResolver:kh})(Hn(({theme:e})=>({paddingTop:25,paddingRight:12,paddingBottom:8,paddingLeft:12,...!e.vars&&{"&:-webkit-autofill":{WebkitBoxShadow:e.palette.mode==="light"?null:"0 0 0 100px #266798 inset",WebkitTextFillColor:e.palette.mode==="light"?null:"#fff",caretColor:e.palette.mode==="light"?null:"#fff",borderTopLeftRadius:"inherit",borderTopRightRadius:"inherit"}},...e.vars&&{"&:-webkit-autofill":{borderTopLeftRadius:"inherit",borderTopRightRadius:"inherit"},[e.getColorSchemeSelector("dark")]:{"&:-webkit-autofill":{WebkitBoxShadow:"0 0 0 100px #266798 inset",WebkitTextFillColor:"#fff",caretColor:"#fff"}}},variants:[{props:{size:"small"},style:{paddingTop:21,paddingBottom:4}},{props:({ownerState:t})=>t.hiddenLabel,style:{paddingTop:16,paddingBottom:17}},{props:({ownerState:t})=>t.startAdornment,style:{paddingLeft:0}},{props:({ownerState:t})=>t.endAdornment,style:{paddingRight:0}},{props:({ownerState:t})=>t.hiddenLabel&&t.size==="small",style:{paddingTop:8,paddingBottom:9}},{props:({ownerState:t})=>t.multiline,style:{paddingTop:0,paddingBottom:0,paddingLeft:0,paddingRight:0}}]}))),Fx=O.forwardRef(function(t,n){const r=Zn({props:t,name:"MuiFilledInput"}),{disableUnderline:i=!1,components:o={},componentsProps:a,fullWidth:s=!1,hiddenLabel:l,inputComponent:c="input",multiline:u=!1,slotProps:d,slots:f={},type:p="text",...m}=r,g={...r,disableUnderline:i,fullWidth:s,inputComponent:c,multiline:u,type:p},v=aae(r),x={root:{ownerState:g},input:{ownerState:g}},_=d??a?Pn(x,d??a):x,w=f.root??o.Root??sae,y=f.input??o.Input??lae;return h.jsx(Ah,{slots:{root:w,input:y},slotProps:_,fullWidth:s,inputComponent:c,multiline:u,ref:n,type:p,...m,classes:v})});process.env.NODE_ENV!=="production"&&(Fx.propTypes={autoComplete:b.string,autoFocus:b.bool,classes:b.object,color:b.oneOfType([b.oneOf(["primary","secondary"]),b.string]),components:b.shape({Input:b.elementType,Root:b.elementType}),componentsProps:b.shape({input:b.object,root:b.object}),defaultValue:b.any,disabled:b.bool,disableUnderline:b.bool,endAdornment:b.node,error:b.bool,fullWidth:b.bool,hiddenLabel:b.bool,id:b.string,inputComponent:b.elementType,inputProps:b.object,inputRef:Po,margin:b.oneOf(["dense","none"]),maxRows:b.oneOfType([b.number,b.string]),minRows:b.oneOfType([b.number,b.string]),multiline:b.bool,name:b.string,onChange:b.func,placeholder:b.string,readOnly:b.bool,required:b.bool,rows:b.oneOfType([b.number,b.string]),slotProps:b.shape({input:b.object,root:b.object}),slots:b.shape({input:b.elementType,root:b.elementType}),startAdornment:b.node,sx:b.oneOfType([b.arrayOf(b.oneOfType([b.func,b.object,b.bool])),b.func,b.object]),type:b.string,value:b.any}),Fx.muiName="Input";function Lx(e){return`scale(${e}, ${e**2})`}const cae={entering:{opacity:1,transform:Lx(1)},entered:{opacity:1,transform:"none"}},Rx=typeof navigator<"u"&&/^((?!chrome|android).)*(safari|mobile)/i.test(navigator.userAgent)&&/(os |version\/)15(.|_)4/i.test(navigator.userAgent),Pu=O.forwardRef(function(t,n){const{addEndListener:r,appear:i=!0,children:o,easing:a,in:s,onEnter:l,onEntered:c,onEntering:u,onExit:d,onExited:f,onExiting:p,style:m,timeout:g="auto",TransitionComponent:v=Bi,...x}=t,_=Su(),w=O.useRef(),y=Id(),E=O.useRef(null),S=Yn(E,kl(o),n),P=M=>R=>{if(M){const B=E.current;R===void 0?M(B):M(B,R)}},D=P(u),T=P((M,R)=>{aj(M);const{duration:B,delay:V,easing:z}=wh({style:m,timeout:g,easing:a},{mode:"enter"});let W;g==="auto"?(W=y.transitions.getAutoHeightDuration(M.clientHeight),w.current=W):W=B,M.style.transition=[y.transitions.create("opacity",{duration:W,delay:V}),y.transitions.create("transform",{duration:Rx?W:W*.666,delay:V,easing:z})].join(","),l&&l(M,R)}),I=P(c),A=P(p),C=P(M=>{const{duration:R,delay:B,easing:V}=wh({style:m,timeout:g,easing:a},{mode:"exit"});let z;g==="auto"?(z=y.transitions.getAutoHeightDuration(M.clientHeight),w.current=z):z=R,M.style.transition=[y.transitions.create("opacity",{duration:z,delay:B}),y.transitions.create("transform",{duration:Rx?z:z*.666,delay:Rx?B:B||z*.333,easing:V})].join(","),M.style.opacity=0,M.style.transform=Lx(.75),d&&d(M)}),j=P(f),N=M=>{g==="auto"&&_.start(w.current||0,M),r&&r(E.current,M)};return h.jsx(v,{appear:i,in:s,nodeRef:E,onEnter:T,onEntered:I,onEntering:D,onExit:C,onExited:j,onExiting:A,addEndListener:N,timeout:g==="auto"?null:g,...x,children:(M,{ownerState:R,...B})=>O.cloneElement(o,{style:{opacity:0,transform:Lx(.75),visibility:M==="exited"&&!s?"hidden":void 0,...cae[M],...m,...o.props.style},ref:S,...B})})});process.env.NODE_ENV!=="production"&&(Pu.propTypes={addEndListener:b.func,appear:b.bool,children:Dl.isRequired,easing:b.oneOfType([b.shape({enter:b.string,exit:b.string}),b.string]),in:b.bool,onEnter:b.func,onEntered:b.func,onEntering:b.func,onExit:b.func,onExited:b.func,onExiting:b.func,style:b.object,timeout:b.oneOfType([b.oneOf(["auto"]),b.number,b.shape({appear:b.number,enter:b.number,exit:b.number})])}),Pu&&(Pu.muiSupportAuto=!0);const uae=e=>{const{classes:t,disableUnderline:n}=e,i=kn({root:["root",!n&&"underline"],input:["input"]},joe,t);return{...t,...i}},dae=De(Ph,{shouldForwardProp:e=>Zi(e)||e==="classes",name:"MuiInput",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[...Ch(e,t),!n.disableUnderline&&t.underline]}})(Hn(({theme:e})=>{let n=e.palette.mode==="light"?"rgba(0, 0, 0, 0.42)":"rgba(255, 255, 255, 0.7)";return e.vars&&(n=e.alpha(e.vars.palette.common.onBackground,e.vars.opacity.inputUnderline)),{position:"relative",variants:[{props:({ownerState:r})=>r.formControl,style:{"label + &":{marginTop:16}}},{props:({ownerState:r})=>!r.disableUnderline,style:{"&::after":{left:0,bottom:0,content:'""',position:"absolute",right:0,transform:"scaleX(0)",transition:e.transitions.create("transform",{duration:e.transitions.duration.shorter,easing:e.transitions.easing.easeOut}),pointerEvents:"none"},[`&.${Cu.focused}:after`]:{transform:"scaleX(1) translateX(0)"},[`&.${Cu.error}`]:{"&::before, &::after":{borderBottomColor:(e.vars||e).palette.error.main}},"&::before":{borderBottom:`1px solid ${n}`,left:0,bottom:0,content:'"\\00a0"',position:"absolute",right:0,transition:e.transitions.create("border-bottom-color",{duration:e.transitions.duration.shorter}),pointerEvents:"none"},[`&:hover:not(.${Cu.disabled}, .${Cu.error}):before`]:{borderBottom:`2px solid ${(e.vars||e).palette.text.primary}`,"@media (hover: none)":{borderBottom:`1px solid ${n}`}},[`&.${Cu.disabled}:before`]:{borderBottomStyle:"dotted"}}},...Object.entries(e.palette).filter(Ax()).map(([r])=>({props:{color:r,disableUnderline:!1},style:{"&::after":{borderBottom:`2px solid ${(e.vars||e).palette[r].main}`}}}))]}})),fae=De(Dh,{name:"MuiInput",slot:"Input",overridesResolver:kh})({}),$x=O.forwardRef(function(t,n){const r=Zn({props:t,name:"MuiInput"}),{disableUnderline:i=!1,components:o={},componentsProps:a,fullWidth:s=!1,inputComponent:l="input",multiline:c=!1,slotProps:u,slots:d={},type:f="text",...p}=r,m=uae(r),v={root:{ownerState:{disableUnderline:i}}},x=u??a?Pn(u??a,v):v,_=d.root??o.Root??dae,w=d.input??o.Input??fae;return h.jsx(Ah,{slots:{root:_,input:w},slotProps:x,fullWidth:s,inputComponent:l,multiline:c,ref:n,type:f,...p,classes:m})});process.env.NODE_ENV!=="production"&&($x.propTypes={autoComplete:b.string,autoFocus:b.bool,classes:b.object,color:b.oneOfType([b.oneOf(["primary","secondary"]),b.string]),components:b.shape({Input:b.elementType,Root:b.elementType}),componentsProps:b.shape({input:b.object,root:b.object}),defaultValue:b.any,disabled:b.bool,disableUnderline:b.bool,endAdornment:b.node,error:b.bool,fullWidth:b.bool,id:b.string,inputComponent:b.elementType,inputProps:b.object,inputRef:Po,margin:b.oneOf(["dense","none"]),maxRows:b.oneOfType([b.number,b.string]),minRows:b.oneOfType([b.number,b.string]),multiline:b.bool,name:b.string,onChange:b.func,placeholder:b.string,readOnly:b.bool,required:b.bool,rows:b.oneOfType([b.number,b.string]),slotProps:b.shape({input:b.object,root:b.object}),slots:b.shape({input:b.elementType,root:b.elementType}),startAdornment:b.node,sx:b.oneOfType([b.arrayOf(b.oneOfType([b.func,b.object,b.bool])),b.func,b.object]),type:b.string,value:b.any}),$x.muiName="Input";const jj=O.createContext({});process.env.NODE_ENV!=="production"&&(jj.displayName="ListContext");function pae(e){return xn("MuiList",e)}Vn("MuiList",["root","padding","dense","subheader"]);const hae=e=>{const{classes:t,disablePadding:n,dense:r,subheader:i}=e;return kn({root:["root",!n&&"padding",r&&"dense",i&&"subheader"]},pae,t)},mae=De("ul",{name:"MuiList",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.root,!n.disablePadding&&t.padding,n.dense&&t.dense,n.subheader&&t.subheader]}})({listStyle:"none",margin:0,padding:0,position:"relative",variants:[{props:({ownerState:e})=>!e.disablePadding,style:{paddingTop:8,paddingBottom:8}},{props:({ownerState:e})=>e.subheader,style:{paddingTop:0}}]}),Mj=O.forwardRef(function(t,n){const r=Zn({props:t,name:"MuiList"}),{children:i,className:o,component:a="ul",dense:s=!1,disablePadding:l=!1,subheader:c,...u}=r,d=O.useMemo(()=>({dense:s}),[s]),f={...r,component:a,dense:s,disablePadding:l},p=hae(f);return h.jsx(jj.Provider,{value:d,children:h.jsxs(mae,{as:a,className:ue(p.root,o),ref:n,ownerState:f,...u,children:[c,i]})})});process.env.NODE_ENV!=="production"&&(Mj.propTypes={children:b.node,classes:b.object,className:b.string,component:b.elementType,dense:b.bool,disablePadding:b.bool,subheader:b.node,sx:b.oneOfType([b.arrayOf(b.oneOfType([b.func,b.object,b.bool])),b.func,b.object])});function Bx(e,t,n){return e===t?e.firstChild:t&&t.nextElementSibling?t.nextElementSibling:n?null:e.firstChild}function Ij(e,t,n){return e===t?n?e.firstChild:e.lastChild:t&&t.previousElementSibling?t.previousElementSibling:n?null:e.lastChild}function Fj(e,t){if(t===void 0)return!0;let n=e.innerText;return n===void 0&&(n=e.textContent),n=n.trim().toLowerCase(),n.length===0?!1:t.repeating?n[0]===t.keys[0]:n.startsWith(t.keys.join(""))}function Du(e,t,n,r,i,o){let a=!1,s=i(e,t,t?n:!1);for(;s;){if(s===e.firstChild){if(a)return!1;a=!0}const l=r?!1:s.disabled||s.getAttribute("aria-disabled")==="true";if(!s.hasAttribute("tabindex")||!Fj(s,o)||l)s=i(e,s,n);else return s.focus(),!0}return!1}const Lj=O.forwardRef(function(t,n){const{actions:r,autoFocus:i=!1,autoFocusItem:o=!1,children:a,className:s,disabledItemsFocusable:l=!1,disableListWrap:c=!1,onKeyDown:u,variant:d="selectedMenu",...f}=t,p=O.useRef(null),m=O.useRef({keys:[],repeating:!0,previousKeyMatched:!0,lastTime:null});Xi(()=>{i&&p.current.focus()},[i]),O.useImperativeHandle(r,()=>({adjustStyleForScrollbar:(w,{direction:y})=>{const E=!p.current.style.width;if(w.clientHeight<p.current.clientHeight&&E){const S=`${Pj(Ji(w))}px`;p.current.style[y==="rtl"?"paddingLeft":"paddingRight"]=S,p.current.style.width=`calc(100% + ${S})`}return p.current}}),[]);const g=w=>{const y=p.current,E=w.key;if(w.ctrlKey||w.metaKey||w.altKey){u&&u(w);return}const P=gr(y).activeElement;if(E==="ArrowDown")w.preventDefault(),Du(y,P,c,l,Bx);else if(E==="ArrowUp")w.preventDefault(),Du(y,P,c,l,Ij);else if(E==="Home")w.preventDefault(),Du(y,null,c,l,Bx);else if(E==="End")w.preventDefault(),Du(y,null,c,l,Ij);else if(E.length===1){const D=m.current,T=E.toLowerCase(),I=performance.now();D.keys.length>0&&(I-D.lastTime>500?(D.keys=[],D.repeating=!0,D.previousKeyMatched=!0):D.repeating&&T!==D.keys[0]&&(D.repeating=!1)),D.lastTime=I,D.keys.push(T);const A=P&&!D.repeating&&Fj(P,D);D.previousKeyMatched&&(A||Du(y,P,!1,l,Bx,D))?w.preventDefault():D.previousKeyMatched=!1}u&&u(w)},v=Yn(p,n);let x=-1;O.Children.forEach(a,(w,y)=>{if(!O.isValidElement(w)){x===y&&(x+=1,x>=a.length&&(x=-1));return}process.env.NODE_ENV!=="production"&&$o.isFragment(w)&&console.error(["MUI: The Menu component doesn't accept a Fragment as a child.","Consider providing an array instead."].join(`
|
|
252
252
|
`)),w.props.disabled||(d==="selectedMenu"&&w.props.selected||x===-1)&&(x=y),x===y&&(w.props.disabled||w.props.muiSkipListHighlight||w.type.muiSkipListHighlight)&&(x+=1,x>=a.length&&(x=-1))});const _=O.Children.map(a,(w,y)=>{if(y===x){const E={};return o&&(E.autoFocus=!0),w.props.tabIndex===void 0&&d==="selectedMenu"&&(E.tabIndex=0),O.cloneElement(w,E)}return w});return h.jsx(Mj,{role:"menu",ref:v,className:s,onKeyDown:g,tabIndex:i?0:-1,...f,children:_})});process.env.NODE_ENV!=="production"&&(Lj.propTypes={autoFocus:b.bool,autoFocusItem:b.bool,children:b.node,className:b.string,disabledItemsFocusable:b.bool,disableListWrap:b.bool,onKeyDown:b.func,variant:b.oneOf(["menu","selectedMenu"])});function gae(e){return xn("MuiPopover",e)}Vn("MuiPopover",["root","paper"]);function Rj(e,t){let n=0;return typeof t=="number"?n=t:t==="center"?n=e.height/2:t==="bottom"&&(n=e.height),n}function $j(e,t){let n=0;return typeof t=="number"?n=t:t==="center"?n=e.width/2:t==="right"&&(n=e.width),n}function Bj(e){return[e.horizontal,e.vertical].map(t=>typeof t=="number"?`${t}px`:t).join(" ")}function Au(e){return typeof e=="function"?e():e}const vae=e=>{const{classes:t}=e;return kn({root:["root"],paper:["paper"]},gae,t)},yae=De(Nj,{name:"MuiPopover",slot:"Root"})({}),Wj=De(uj,{name:"MuiPopover",slot:"Paper"})({position:"absolute",overflowY:"auto",overflowX:"hidden",minWidth:16,minHeight:16,maxWidth:"calc(100% - 32px)",maxHeight:"calc(100% - 32px)",outline:0}),zj=O.forwardRef(function(t,n){const r=Zn({props:t,name:"MuiPopover"}),{action:i,anchorEl:o,anchorOrigin:a={vertical:"top",horizontal:"left"},anchorPosition:s,anchorReference:l="anchorEl",children:c,className:u,container:d,elevation:f=8,marginThreshold:p=16,open:m,PaperProps:g={},slots:v={},slotProps:x={},transformOrigin:_={vertical:"top",horizontal:"left"},TransitionComponent:w,transitionDuration:y="auto",TransitionProps:E={},disableScrollLock:S=!1,...P}=r,D=O.useRef(),T={...r,anchorOrigin:a,anchorReference:l,elevation:f,marginThreshold:p,transformOrigin:_,TransitionComponent:w,transitionDuration:y,TransitionProps:E},I=vae(T),A=O.useCallback(()=>{if(l==="anchorPosition")return process.env.NODE_ENV!=="production"&&(s||console.error('MUI: You need to provide a `anchorPosition` prop when using <Popover anchorReference="anchorPosition" />.')),s;const U=Au(o),Z=U&&U.nodeType===1?U:gr(D.current).body,F=Z.getBoundingClientRect();if(process.env.NODE_ENV!=="production"){const ge=Z.getBoundingClientRect();process.env.NODE_ENV!=="test"&&ge.top===0&&ge.left===0&&ge.right===0&&ge.bottom===0&&console.warn(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(`
|
|
253
253
|
`))}return{top:F.top+Rj(F,a.vertical),left:F.left+$j(F,a.horizontal)}},[o,a.horizontal,a.vertical,s,l]),C=O.useCallback(U=>({vertical:Rj(U,_.vertical),horizontal:$j(U,_.horizontal)}),[_.horizontal,_.vertical]),j=O.useCallback(U=>{const Z={width:U.offsetWidth,height:U.offsetHeight},F=C(Z);if(l==="none")return{top:null,left:null,transformOrigin:Bj(F)};const ge=A();let oe=ge.top-F.vertical,ye=ge.left-F.horizontal;const _e=oe+Z.height,Ie=ye+Z.width,tt=Ji(Au(o)),pt=tt.innerHeight-p,ct=tt.innerWidth-p;if(p!==null&&oe<p){const Fe=oe-p;oe-=Fe,F.vertical+=Fe}else if(p!==null&&_e>pt){const Fe=_e-pt;oe-=Fe,F.vertical+=Fe}if(process.env.NODE_ENV!=="production"&&Z.height>pt&&Z.height&&pt&&console.error(["MUI: The popover component is too tall.",`Some part of it can not be seen on the screen (${Z.height-pt}px).`,"Please consider adding a `max-height` to improve the user-experience."].join(`
|
|
254
|
-
`)),p!==null&&ye<p){const Fe=ye-p;ye-=Fe,F.horizontal+=Fe}else if(Ie>ct){const Fe=Ie-ct;ye-=Fe,F.horizontal+=Fe}return{top:`${Math.round(oe)}px`,left:`${Math.round(ye)}px`,transformOrigin:Bj(F)}},[o,l,A,C,p]),[N,M]=O.useState(m),R=O.useCallback(()=>{const U=D.current;if(!U)return;const Z=j(U);Z.top!==null&&U.style.setProperty("top",Z.top),Z.left!==null&&(U.style.left=Z.left),U.style.transformOrigin=Z.transformOrigin,M(!0)},[j]);O.useEffect(()=>(S&&window.addEventListener("scroll",R),()=>window.removeEventListener("scroll",R)),[o,S,R]);const B=()=>{R()},V=()=>{M(!1)};O.useEffect(()=>{m&&R()}),O.useImperativeHandle(i,()=>m?{updatePosition:()=>{R()}}:null,[m,R]),O.useEffect(()=>{if(!m)return;const U=O_(()=>{R()}),Z=Ji(Au(o));return Z.addEventListener("resize",U),()=>{U.clear(),Z.removeEventListener("resize",U)}},[o,m,R]);let z=y;const W={slots:{transition:w,...v},slotProps:{transition:E,paper:g,...x}},[Q,
|
|
254
|
+
`)),p!==null&&ye<p){const Fe=ye-p;ye-=Fe,F.horizontal+=Fe}else if(Ie>ct){const Fe=Ie-ct;ye-=Fe,F.horizontal+=Fe}return{top:`${Math.round(oe)}px`,left:`${Math.round(ye)}px`,transformOrigin:Bj(F)}},[o,l,A,C,p]),[N,M]=O.useState(m),R=O.useCallback(()=>{const U=D.current;if(!U)return;const Z=j(U);Z.top!==null&&U.style.setProperty("top",Z.top),Z.left!==null&&(U.style.left=Z.left),U.style.transformOrigin=Z.transformOrigin,M(!0)},[j]);O.useEffect(()=>(S&&window.addEventListener("scroll",R),()=>window.removeEventListener("scroll",R)),[o,S,R]);const B=()=>{R()},V=()=>{M(!1)};O.useEffect(()=>{m&&R()}),O.useImperativeHandle(i,()=>m?{updatePosition:()=>{R()}}:null,[m,R]),O.useEffect(()=>{if(!m)return;const U=O_(()=>{R()}),Z=Ji(Au(o));return Z.addEventListener("resize",U),()=>{U.clear(),Z.removeEventListener("resize",U)}},[o,m,R]);let z=y;const W={slots:{transition:w,...v},slotProps:{transition:E,paper:g,...x}},[Q,G]=lr("transition",{elementType:Pu,externalForwardedProps:W,ownerState:T,getSlotProps:U=>({...U,onEntering:(Z,F)=>{U.onEntering?.(Z,F),B()},onExited:Z=>{U.onExited?.(Z),V()}}),additionalProps:{appear:!0,in:m}});y==="auto"&&!Q.muiSupportAuto&&(z=void 0);const ie=d||(o?gr(Au(o)).body:void 0),[J,{slots:re,slotProps:se,...ce}]=lr("root",{ref:n,elementType:yae,externalForwardedProps:{...W,...P},shouldForwardComponentProp:!0,additionalProps:{slots:{backdrop:v.backdrop},slotProps:{backdrop:H$(typeof x.backdrop=="function"?x.backdrop(T):x.backdrop,{invisible:!0})},container:ie,open:m},ownerState:T,className:ue(I.root,u)}),[de,K]=lr("paper",{ref:D,className:I.paper,elementType:Wj,externalForwardedProps:W,shouldForwardComponentProp:!0,additionalProps:{elevation:f,style:N?void 0:{opacity:0}},ownerState:T});return h.jsx(J,{...ce,...!_h(J)&&{slots:re,slotProps:se,disableScrollLock:S},children:h.jsx(Q,{...G,timeout:z,children:h.jsx(de,{...K,children:c})})})});process.env.NODE_ENV!=="production"&&(zj.propTypes={action:Po,anchorEl:Sl(b.oneOfType([Do,b.func]),e=>{if(e.open&&(!e.anchorReference||e.anchorReference==="anchorEl")){const t=Au(e.anchorEl);if(t&&t.nodeType===1){const n=t.getBoundingClientRect();if(process.env.NODE_ENV!=="test"&&n.top===0&&n.left===0&&n.right===0&&n.bottom===0)return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.","The anchor element should be part of the document layout.","Make sure the element is present in the document or that it's not display none."].join(`
|
|
255
255
|
`))}else return new Error(["MUI: The `anchorEl` prop provided to the component is invalid.",`It should be an Element or PopoverVirtualElement instance but it's \`${t}\` instead.`].join(`
|
|
256
256
|
`))}return null}),anchorOrigin:b.shape({horizontal:b.oneOfType([b.oneOf(["center","left","right"]),b.number]).isRequired,vertical:b.oneOfType([b.oneOf(["bottom","center","top"]),b.number]).isRequired}),anchorPosition:b.shape({left:b.number.isRequired,top:b.number.isRequired}),anchorReference:b.oneOf(["anchorEl","anchorPosition","none"]),BackdropComponent:b.elementType,BackdropProps:b.object,children:b.node,classes:b.object,className:b.string,container:b.oneOfType([Do,b.func]),disableScrollLock:b.bool,elevation:cj,marginThreshold:b.number,onClose:b.func,open:b.bool.isRequired,PaperProps:b.shape({component:oj}),slotProps:b.shape({backdrop:b.oneOfType([b.func,b.object]),paper:b.oneOfType([b.func,b.object]),root:b.oneOfType([b.func,b.object]),transition:b.oneOfType([b.func,b.object])}),slots:b.shape({backdrop:b.elementType,paper:b.elementType,root:b.elementType,transition:b.elementType}),sx:b.oneOfType([b.arrayOf(b.oneOfType([b.func,b.object,b.bool])),b.func,b.object]),transformOrigin:b.shape({horizontal:b.oneOfType([b.oneOf(["center","left","right"]),b.number]).isRequired,vertical:b.oneOfType([b.oneOf(["bottom","center","top"]),b.number]).isRequired}),TransitionComponent:b.elementType,transitionDuration:b.oneOfType([b.oneOf(["auto"]),b.number,b.shape({appear:b.number,enter:b.number,exit:b.number})]),TransitionProps:b.object});function bae(e){return xn("MuiMenu",e)}Vn("MuiMenu",["root","paper","list"]);const xae={vertical:"top",horizontal:"right"},wae={vertical:"top",horizontal:"left"},_ae=e=>{const{classes:t}=e;return kn({root:["root"],paper:["paper"],list:["list"]},bae,t)},Eae=De(zj,{shouldForwardProp:e=>Zi(e)||e==="classes",name:"MuiMenu",slot:"Root"})({}),Sae=De(Wj,{name:"MuiMenu",slot:"Paper"})({maxHeight:"calc(100% - 96px)",WebkitOverflowScrolling:"touch"}),Oae=De(Lj,{name:"MuiMenu",slot:"List"})({outline:0}),Vj=O.forwardRef(function(t,n){const r=Zn({props:t,name:"MuiMenu"}),{autoFocus:i=!0,children:o,className:a,disableAutoFocusItem:s=!1,MenuListProps:l={},onClose:c,open:u,PaperProps:d={},PopoverClasses:f,transitionDuration:p="auto",TransitionProps:{onEntering:m,...g}={},variant:v="selectedMenu",slots:x={},slotProps:_={},...w}=r,y=Um(),E={...r,autoFocus:i,disableAutoFocusItem:s,MenuListProps:l,onEntering:m,PaperProps:d,transitionDuration:p,TransitionProps:g,variant:v},S=_ae(E),P=i&&!s&&u,D=O.useRef(null),T=(z,W)=>{D.current&&D.current.adjustStyleForScrollbar(z,{direction:y?"rtl":"ltr"}),m&&m(z,W)},I=z=>{z.key==="Tab"&&(z.preventDefault(),c&&c(z,"tabKeyDown"))};let A=-1;O.Children.map(o,(z,W)=>{O.isValidElement(z)&&(process.env.NODE_ENV!=="production"&&$o.isFragment(z)&&console.error(["MUI: The Menu component doesn't accept a Fragment as a child.","Consider providing an array instead."].join(`
|
|
257
|
-
`)),z.props.disabled||(v==="selectedMenu"&&z.props.selected||A===-1)&&(A=W))});const C={slots:x,slotProps:{list:l,transition:g,paper:d,..._}},j=vj({elementType:x.root,externalSlotProps:_.root,ownerState:E,className:[S.root,a]}),[N,M]=lr("paper",{className:S.paper,elementType:Sae,externalForwardedProps:C,shouldForwardComponentProp:!0,ownerState:E}),[R,B]=lr("list",{className:ue(S.list,l.className),elementType:Oae,shouldForwardComponentProp:!0,externalForwardedProps:C,getSlotProps:z=>({...z,onKeyDown:W=>{I(W),z.onKeyDown?.(W)}}),ownerState:E}),V=typeof C.slotProps.transition=="function"?C.slotProps.transition(E):C.slotProps.transition;return h.jsx(Eae,{onClose:c,anchorOrigin:{vertical:"bottom",horizontal:y?"right":"left"},transformOrigin:y?xae:wae,slots:{root:x.root,paper:N,backdrop:x.backdrop,...x.transition&&{transition:x.transition}},slotProps:{root:j,paper:M,backdrop:typeof _.backdrop=="function"?_.backdrop(E):_.backdrop,transition:{...V,onEntering:(...z)=>{T(...z),V?.onEntering?.(...z)}}},open:u,ref:n,transitionDuration:p,ownerState:E,...w,classes:f,children:h.jsx(R,{actions:D,autoFocus:i&&(A===-1||s),autoFocusItem:P,variant:v,...B,children:o})})});process.env.NODE_ENV!=="production"&&(Vj.propTypes={anchorEl:b.oneOfType([Do,b.func]),autoFocus:b.bool,children:b.node,classes:b.object,className:b.string,disableAutoFocusItem:b.bool,MenuListProps:b.object,onClose:b.func,open:b.bool.isRequired,PaperProps:b.object,PopoverClasses:b.object,slotProps:b.shape({backdrop:b.oneOfType([b.func,b.object]),list:b.oneOfType([b.func,b.object]),paper:b.oneOfType([b.func,b.object]),root:b.oneOfType([b.func,b.object]),transition:b.oneOfType([b.func,b.object])}),slots:b.shape({backdrop:b.elementType,list:b.elementType,paper:b.elementType,root:b.elementType,transition:b.elementType}),sx:b.oneOfType([b.arrayOf(b.oneOfType([b.func,b.object,b.bool])),b.func,b.object]),transitionDuration:b.oneOfType([b.oneOf(["auto"]),b.number,b.shape({appear:b.number,enter:b.number,exit:b.number})]),TransitionProps:b.object,variant:b.oneOf(["menu","selectedMenu"])});function Cae(e){return xn("MuiNativeSelect",e)}const Wx=Vn("MuiNativeSelect",["root","select","multiple","filled","outlined","standard","disabled","icon","iconOpen","iconFilled","iconOutlined","iconStandard","nativeInput","error"]),kae=e=>{const{classes:t,variant:n,disabled:r,multiple:i,open:o,error:a}=e,s={select:["select",n,r&&"disabled",i&&"multiple",a&&"error"],icon:["icon",`icon${yn(n)}`,o&&"iconOpen",r&&"disabled"]};return kn(s,Cae,t)},Hj=De("select",{name:"MuiNativeSelect"})(({theme:e})=>({MozAppearance:"none",WebkitAppearance:"none",userSelect:"none",borderRadius:0,cursor:"pointer","&:focus":{borderRadius:0},[`&.${Wx.disabled}`]:{cursor:"default"},"&[multiple]":{height:"auto"},"&:not([multiple]) option, &:not([multiple]) optgroup":{backgroundColor:(e.vars||e).palette.background.paper},variants:[{props:({ownerState:t})=>t.variant!=="filled"&&t.variant!=="outlined",style:{"&&&":{paddingRight:24,minWidth:16}}},{props:{variant:"filled"},style:{"&&&":{paddingRight:32}}},{props:{variant:"outlined"},style:{borderRadius:(e.vars||e).shape.borderRadius,"&:focus":{borderRadius:(e.vars||e).shape.borderRadius},"&&&":{paddingRight:32}}}]})),Pae=De(Hj,{name:"MuiNativeSelect",slot:"Select",shouldForwardProp:Zi,overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.select,t[n.variant],n.error&&t.error,{[`&.${Wx.multiple}`]:t.multiple}]}})({}),Yj=De("svg",{name:"MuiNativeSelect"})(({theme:e})=>({position:"absolute",right:0,top:"calc(50% - .5em)",pointerEvents:"none",color:(e.vars||e).palette.action.active,[`&.${Wx.disabled}`]:{color:(e.vars||e).palette.action.disabled},variants:[{props:({ownerState:t})=>t.open,style:{transform:"rotate(180deg)"}},{props:{variant:"filled"},style:{right:7}},{props:{variant:"outlined"},style:{right:7}}]})),Dae=De(Yj,{name:"MuiNativeSelect",slot:"Icon",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.icon,n.variant&&t[`icon${yn(n.variant)}`],n.open&&t.iconOpen]}})({}),Uj=O.forwardRef(function(t,n){const{className:r,disabled:i,error:o,IconComponent:a,inputRef:s,variant:l="standard",...c}=t,u={...t,disabled:i,variant:l,error:o},d=kae(u);return h.jsxs(O.Fragment,{children:[h.jsx(Pae,{ownerState:u,className:ue(d.select,r),disabled:i,ref:s||n,...c}),t.multiple?null:h.jsx(Dae,{as:a,ownerState:u,className:d.icon})]})});process.env.NODE_ENV!=="production"&&(Uj.propTypes={children:b.node,classes:b.object,className:b.string,disabled:b.bool,error:b.bool,IconComponent:b.elementType.isRequired,inputRef:Po,multiple:b.bool,name:b.string,onChange:b.func,value:b.any,variant:b.oneOf(["standard","outlined","filled"])});var Kj;const Aae=De("fieldset",{name:"MuiNotchedOutlined",shouldForwardProp:Zi})({textAlign:"left",position:"absolute",bottom:0,right:0,top:-5,left:0,margin:0,padding:"0 8px",pointerEvents:"none",borderRadius:"inherit",borderStyle:"solid",borderWidth:1,overflow:"hidden",minWidth:"0%"}),Tae=De("legend",{name:"MuiNotchedOutlined",shouldForwardProp:Zi})(Hn(({theme:e})=>({float:"unset",width:"auto",overflow:"hidden",variants:[{props:({ownerState:t})=>!t.withLabel,style:{padding:0,lineHeight:"11px",transition:e.transitions.create("width",{duration:150,easing:e.transitions.easing.easeOut})}},{props:({ownerState:t})=>t.withLabel,style:{display:"block",padding:0,height:11,fontSize:"0.75em",visibility:"hidden",maxWidth:.01,transition:e.transitions.create("max-width",{duration:50,easing:e.transitions.easing.easeOut}),whiteSpace:"nowrap","& > span":{paddingLeft:5,paddingRight:5,display:"inline-block",opacity:0,visibility:"visible"}}},{props:({ownerState:t})=>t.withLabel&&t.notched,style:{maxWidth:"100%",transition:e.transitions.create("max-width",{duration:100,easing:e.transitions.easing.easeOut,delay:50})}}]})));function qj(e){const{children:t,classes:n,className:r,label:i,notched:o,...a}=e,s=i!=null&&i!=="",l={...e,notched:o,withLabel:s};return h.jsx(Aae,{"aria-hidden":!0,className:r,ownerState:l,...a,children:h.jsx(Tae,{ownerState:l,children:s?h.jsx("span",{children:i}):Kj||(Kj=h.jsx("span",{className:"notranslate","aria-hidden":!0,children:""}))})})}process.env.NODE_ENV!=="production"&&(qj.propTypes={children:b.node,classes:b.object,className:b.string,label:b.node,notched:b.bool.isRequired,style:b.object});const Nae=e=>{const{classes:t}=e,r=kn({root:["root"],notchedOutline:["notchedOutline"],input:["input"]},Moe,t);return{...t,...r}},jae=De(Ph,{shouldForwardProp:e=>Zi(e)||e==="classes",name:"MuiOutlinedInput",slot:"Root",overridesResolver:Ch})(Hn(({theme:e})=>{const t=e.palette.mode==="light"?"rgba(0, 0, 0, 0.23)":"rgba(255, 255, 255, 0.23)";return{position:"relative",borderRadius:(e.vars||e).shape.borderRadius,[`&:hover .${Wi.notchedOutline}`]:{borderColor:(e.vars||e).palette.text.primary},"@media (hover: none)":{[`&:hover .${Wi.notchedOutline}`]:{borderColor:e.vars?e.alpha(e.vars.palette.common.onBackground,.23):t}},[`&.${Wi.focused} .${Wi.notchedOutline}`]:{borderWidth:2},variants:[...Object.entries(e.palette).filter(Ax()).map(([n])=>({props:{color:n},style:{[`&.${Wi.focused} .${Wi.notchedOutline}`]:{borderColor:(e.vars||e).palette[n].main}}})),{props:{},style:{[`&.${Wi.error} .${Wi.notchedOutline}`]:{borderColor:(e.vars||e).palette.error.main},[`&.${Wi.disabled} .${Wi.notchedOutline}`]:{borderColor:(e.vars||e).palette.action.disabled}}},{props:({ownerState:n})=>n.startAdornment,style:{paddingLeft:14}},{props:({ownerState:n})=>n.endAdornment,style:{paddingRight:14}},{props:({ownerState:n})=>n.multiline,style:{padding:"16.5px 14px"}},{props:({ownerState:n,size:r})=>n.multiline&&r==="small",style:{padding:"8.5px 14px"}}]}})),Mae=De(qj,{name:"MuiOutlinedInput",slot:"NotchedOutline"})(Hn(({theme:e})=>{const t=e.palette.mode==="light"?"rgba(0, 0, 0, 0.23)":"rgba(255, 255, 255, 0.23)";return{borderColor:e.vars?e.alpha(e.vars.palette.common.onBackground,.23):t}})),Iae=De(Dh,{name:"MuiOutlinedInput",slot:"Input",overridesResolver:kh})(Hn(({theme:e})=>({padding:"16.5px 14px",...!e.vars&&{"&:-webkit-autofill":{WebkitBoxShadow:e.palette.mode==="light"?null:"0 0 0 100px #266798 inset",WebkitTextFillColor:e.palette.mode==="light"?null:"#fff",caretColor:e.palette.mode==="light"?null:"#fff",borderRadius:"inherit"}},...e.vars&&{"&:-webkit-autofill":{borderRadius:"inherit"},[e.getColorSchemeSelector("dark")]:{"&:-webkit-autofill":{WebkitBoxShadow:"0 0 0 100px #266798 inset",WebkitTextFillColor:"#fff",caretColor:"#fff"}}},variants:[{props:{size:"small"},style:{padding:"8.5px 14px"}},{props:({ownerState:t})=>t.multiline,style:{padding:0}},{props:({ownerState:t})=>t.startAdornment,style:{paddingLeft:0}},{props:({ownerState:t})=>t.endAdornment,style:{paddingRight:0}}]}))),zx=O.forwardRef(function(t,n){const r=Zn({props:t,name:"MuiOutlinedInput"}),{components:i={},fullWidth:o=!1,inputComponent:a="input",label:s,multiline:l=!1,notched:c,slots:u={},slotProps:d={},type:f="text",...p}=r,m=Nae(r),g=Mx(),v=Nx({props:r,muiFormControl:g,states:["color","disabled","error","focused","hiddenLabel","size","required"]}),x={...r,color:v.color||"primary",disabled:v.disabled,error:v.error,focused:v.focused,formControl:g,fullWidth:o,hiddenLabel:v.hiddenLabel,multiline:l,size:v.size,type:f},_=u.root??i.Root??jae,w=u.input??i.Input??Iae,[y,E]=lr("notchedOutline",{elementType:Mae,className:m.notchedOutline,shouldForwardComponentProp:!0,ownerState:x,externalForwardedProps:{slots:u,slotProps:d},additionalProps:{label:s!=null&&s!==""&&v.required?h.jsxs(O.Fragment,{children:[s," ","*"]}):s}});return h.jsx(Ah,{slots:{root:_,input:w},slotProps:d,renderSuffix:S=>h.jsx(y,{...E,notched:typeof c<"u"?c:!!(S.startAdornment||S.filled||S.focused)}),fullWidth:o,inputComponent:a,multiline:l,ref:n,type:f,...p,classes:{...m,notchedOutline:null}})});process.env.NODE_ENV!=="production"&&(zx.propTypes={autoComplete:b.string,autoFocus:b.bool,classes:b.object,color:b.oneOfType([b.oneOf(["primary","secondary"]),b.string]),components:b.shape({Input:b.elementType,Root:b.elementType}),defaultValue:b.any,disabled:b.bool,endAdornment:b.node,error:b.bool,fullWidth:b.bool,id:b.string,inputComponent:b.elementType,inputProps:b.object,inputRef:Po,label:b.node,margin:b.oneOf(["dense","none"]),maxRows:b.oneOfType([b.number,b.string]),minRows:b.oneOfType([b.number,b.string]),multiline:b.bool,name:b.string,notched:b.bool,onChange:b.func,placeholder:b.string,readOnly:b.bool,required:b.bool,rows:b.oneOfType([b.number,b.string]),slotProps:b.shape({input:b.object,notchedOutline:b.oneOfType([b.func,b.object]),root:b.object}),slots:b.shape({input:b.elementType,notchedOutline:b.elementType,root:b.elementType}),startAdornment:b.node,sx:b.oneOfType([b.arrayOf(b.oneOfType([b.func,b.object,b.bool])),b.func,b.object]),type:b.string,value:b.any}),zx.muiName="Input";function Gj(e){return xn("MuiSelect",e)}const Tu=Vn("MuiSelect",["root","select","multiple","filled","outlined","standard","disabled","focused","icon","iconOpen","iconFilled","iconOutlined","iconStandard","nativeInput","error"]);var Xj;const Fae=De(Hj,{name:"MuiSelect",slot:"Select",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[{[`&.${Tu.select}`]:t.select},{[`&.${Tu.select}`]:t[n.variant]},{[`&.${Tu.error}`]:t.error},{[`&.${Tu.multiple}`]:t.multiple}]}})({[`&.${Tu.select}`]:{height:"auto",minHeight:"1.4375em",textOverflow:"ellipsis",whiteSpace:"nowrap",overflow:"hidden"}}),Lae=De(Yj,{name:"MuiSelect",slot:"Icon",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.icon,n.variant&&t[`icon${yn(n.variant)}`],n.open&&t.iconOpen]}})({}),Rae=De("input",{shouldForwardProp:e=>S_(e)&&e!=="classes",name:"MuiSelect",slot:"NativeInput"})({bottom:0,left:0,position:"absolute",opacity:0,pointerEvents:"none",width:"100%",boxSizing:"border-box"});function Qj(e,t){return typeof t=="object"&&t!==null?e===t:String(e)===String(t)}function $ae(e){return e==null||typeof e=="string"&&!e.trim()}const Bae=e=>{const{classes:t,variant:n,disabled:r,multiple:i,open:o,error:a}=e,s={select:["select",n,r&&"disabled",i&&"multiple",a&&"error"],icon:["icon",`icon${yn(n)}`,o&&"iconOpen",r&&"disabled"],nativeInput:["nativeInput"]};return kn(s,Gj,t)},Zj=O.forwardRef(function(t,n){const{"aria-describedby":r,"aria-label":i,autoFocus:o,autoWidth:a,children:s,className:l,defaultOpen:c,defaultValue:u,disabled:d,displayEmpty:f,error:p=!1,IconComponent:m,inputRef:g,labelId:v,MenuProps:x={},multiple:_,name:w,onBlur:y,onChange:E,onClose:S,onFocus:P,onOpen:D,open:T,readOnly:I,renderValue:A,required:C,SelectDisplayProps:j={},tabIndex:N,type:M,value:R,variant:B="standard",...V}=t,[z,W]=tg({controlled:R,default:u,name:"Select"}),[Q,X]=tg({controlled:T,default:c,name:"Select"}),ie=O.useRef(null),J=O.useRef(null),[re,se]=O.useState(null),{current:ce}=O.useRef(T!=null),[de,K]=O.useState(),U=Yn(n,g),Z=O.useCallback(Y=>{J.current=Y,Y&&se(Y)},[]),F=re?.parentNode;O.useImperativeHandle(U,()=>({focus:()=>{J.current.focus()},node:ie.current,value:z}),[z]),O.useEffect(()=>{c&&Q&&re&&!ce&&(K(a?null:F.clientWidth),J.current.focus())},[re,a]),O.useEffect(()=>{o&&J.current.focus()},[o]),O.useEffect(()=>{if(!v)return;const Y=gr(J.current).getElementById(v);if(Y){const ee=()=>{getSelection().isCollapsed&&J.current.focus()};return Y.addEventListener("click",ee),()=>{Y.removeEventListener("click",ee)}}},[v]);const ge=(Y,ee)=>{Y?D&&D(ee):S&&S(ee),ce||(K(a?null:F.clientWidth),X(Y))},oe=Y=>{Y.button===0&&(Y.preventDefault(),J.current.focus(),ge(!0,Y))},ye=Y=>{ge(!1,Y)},_e=O.Children.toArray(s),Ie=Y=>{const ee=_e.find(ne=>ne.props.value===Y.target.value);ee!==void 0&&(W(ee.props.value),E&&E(Y,ee))},tt=Y=>ee=>{let ne;if(ee.currentTarget.hasAttribute("tabindex")){if(_){ne=Array.isArray(z)?z.slice():[];const Ee=z.indexOf(Y.props.value);Ee===-1?ne.push(Y.props.value):ne.splice(Ee,1)}else ne=Y.props.value;if(Y.props.onClick&&Y.props.onClick(ee),z!==ne&&(W(ne),E)){const Ee=ee.nativeEvent||ee,Pe=new Ee.constructor(Ee.type,Ee);Object.defineProperty(Pe,"target",{writable:!0,value:{value:ne,name:w}}),E(Pe,Y)}_||ge(!1,ee)}},pt=Y=>{I||[" ","ArrowUp","ArrowDown","Enter"].includes(Y.key)&&(Y.preventDefault(),ge(!0,Y))},ct=re!==null&&Q,Fe=Y=>{!ct&&y&&(Object.defineProperty(Y,"target",{writable:!0,value:{value:z,name:w}}),y(Y))};delete V["aria-invalid"];let Pt,Dt;const ht=[];let mn=!1,sn=!1;(_j({value:z})||f)&&(A?Pt=A(z):mn=!0);const gn=_e.map(Y=>{if(!O.isValidElement(Y))return null;process.env.NODE_ENV!=="production"&&$o.isFragment(Y)&&console.error(["MUI: The Select component doesn't accept a Fragment as a child.","Consider providing an array instead."].join(`
|
|
257
|
+
`)),z.props.disabled||(v==="selectedMenu"&&z.props.selected||A===-1)&&(A=W))});const C={slots:x,slotProps:{list:l,transition:g,paper:d,..._}},j=vj({elementType:x.root,externalSlotProps:_.root,ownerState:E,className:[S.root,a]}),[N,M]=lr("paper",{className:S.paper,elementType:Sae,externalForwardedProps:C,shouldForwardComponentProp:!0,ownerState:E}),[R,B]=lr("list",{className:ue(S.list,l.className),elementType:Oae,shouldForwardComponentProp:!0,externalForwardedProps:C,getSlotProps:z=>({...z,onKeyDown:W=>{I(W),z.onKeyDown?.(W)}}),ownerState:E}),V=typeof C.slotProps.transition=="function"?C.slotProps.transition(E):C.slotProps.transition;return h.jsx(Eae,{onClose:c,anchorOrigin:{vertical:"bottom",horizontal:y?"right":"left"},transformOrigin:y?xae:wae,slots:{root:x.root,paper:N,backdrop:x.backdrop,...x.transition&&{transition:x.transition}},slotProps:{root:j,paper:M,backdrop:typeof _.backdrop=="function"?_.backdrop(E):_.backdrop,transition:{...V,onEntering:(...z)=>{T(...z),V?.onEntering?.(...z)}}},open:u,ref:n,transitionDuration:p,ownerState:E,...w,classes:f,children:h.jsx(R,{actions:D,autoFocus:i&&(A===-1||s),autoFocusItem:P,variant:v,...B,children:o})})});process.env.NODE_ENV!=="production"&&(Vj.propTypes={anchorEl:b.oneOfType([Do,b.func]),autoFocus:b.bool,children:b.node,classes:b.object,className:b.string,disableAutoFocusItem:b.bool,MenuListProps:b.object,onClose:b.func,open:b.bool.isRequired,PaperProps:b.object,PopoverClasses:b.object,slotProps:b.shape({backdrop:b.oneOfType([b.func,b.object]),list:b.oneOfType([b.func,b.object]),paper:b.oneOfType([b.func,b.object]),root:b.oneOfType([b.func,b.object]),transition:b.oneOfType([b.func,b.object])}),slots:b.shape({backdrop:b.elementType,list:b.elementType,paper:b.elementType,root:b.elementType,transition:b.elementType}),sx:b.oneOfType([b.arrayOf(b.oneOfType([b.func,b.object,b.bool])),b.func,b.object]),transitionDuration:b.oneOfType([b.oneOf(["auto"]),b.number,b.shape({appear:b.number,enter:b.number,exit:b.number})]),TransitionProps:b.object,variant:b.oneOf(["menu","selectedMenu"])});function Cae(e){return xn("MuiNativeSelect",e)}const Wx=Vn("MuiNativeSelect",["root","select","multiple","filled","outlined","standard","disabled","icon","iconOpen","iconFilled","iconOutlined","iconStandard","nativeInput","error"]),kae=e=>{const{classes:t,variant:n,disabled:r,multiple:i,open:o,error:a}=e,s={select:["select",n,r&&"disabled",i&&"multiple",a&&"error"],icon:["icon",`icon${yn(n)}`,o&&"iconOpen",r&&"disabled"]};return kn(s,Cae,t)},Hj=De("select",{name:"MuiNativeSelect"})(({theme:e})=>({MozAppearance:"none",WebkitAppearance:"none",userSelect:"none",borderRadius:0,cursor:"pointer","&:focus":{borderRadius:0},[`&.${Wx.disabled}`]:{cursor:"default"},"&[multiple]":{height:"auto"},"&:not([multiple]) option, &:not([multiple]) optgroup":{backgroundColor:(e.vars||e).palette.background.paper},variants:[{props:({ownerState:t})=>t.variant!=="filled"&&t.variant!=="outlined",style:{"&&&":{paddingRight:24,minWidth:16}}},{props:{variant:"filled"},style:{"&&&":{paddingRight:32}}},{props:{variant:"outlined"},style:{borderRadius:(e.vars||e).shape.borderRadius,"&:focus":{borderRadius:(e.vars||e).shape.borderRadius},"&&&":{paddingRight:32}}}]})),Pae=De(Hj,{name:"MuiNativeSelect",slot:"Select",shouldForwardProp:Zi,overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.select,t[n.variant],n.error&&t.error,{[`&.${Wx.multiple}`]:t.multiple}]}})({}),Yj=De("svg",{name:"MuiNativeSelect"})(({theme:e})=>({position:"absolute",right:0,top:"calc(50% - .5em)",pointerEvents:"none",color:(e.vars||e).palette.action.active,[`&.${Wx.disabled}`]:{color:(e.vars||e).palette.action.disabled},variants:[{props:({ownerState:t})=>t.open,style:{transform:"rotate(180deg)"}},{props:{variant:"filled"},style:{right:7}},{props:{variant:"outlined"},style:{right:7}}]})),Dae=De(Yj,{name:"MuiNativeSelect",slot:"Icon",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.icon,n.variant&&t[`icon${yn(n.variant)}`],n.open&&t.iconOpen]}})({}),Uj=O.forwardRef(function(t,n){const{className:r,disabled:i,error:o,IconComponent:a,inputRef:s,variant:l="standard",...c}=t,u={...t,disabled:i,variant:l,error:o},d=kae(u);return h.jsxs(O.Fragment,{children:[h.jsx(Pae,{ownerState:u,className:ue(d.select,r),disabled:i,ref:s||n,...c}),t.multiple?null:h.jsx(Dae,{as:a,ownerState:u,className:d.icon})]})});process.env.NODE_ENV!=="production"&&(Uj.propTypes={children:b.node,classes:b.object,className:b.string,disabled:b.bool,error:b.bool,IconComponent:b.elementType.isRequired,inputRef:Po,multiple:b.bool,name:b.string,onChange:b.func,value:b.any,variant:b.oneOf(["standard","outlined","filled"])});var Kj;const Aae=De("fieldset",{name:"MuiNotchedOutlined",shouldForwardProp:Zi})({textAlign:"left",position:"absolute",bottom:0,right:0,top:-5,left:0,margin:0,padding:"0 8px",pointerEvents:"none",borderRadius:"inherit",borderStyle:"solid",borderWidth:1,overflow:"hidden",minWidth:"0%"}),Tae=De("legend",{name:"MuiNotchedOutlined",shouldForwardProp:Zi})(Hn(({theme:e})=>({float:"unset",width:"auto",overflow:"hidden",variants:[{props:({ownerState:t})=>!t.withLabel,style:{padding:0,lineHeight:"11px",transition:e.transitions.create("width",{duration:150,easing:e.transitions.easing.easeOut})}},{props:({ownerState:t})=>t.withLabel,style:{display:"block",padding:0,height:11,fontSize:"0.75em",visibility:"hidden",maxWidth:.01,transition:e.transitions.create("max-width",{duration:50,easing:e.transitions.easing.easeOut}),whiteSpace:"nowrap","& > span":{paddingLeft:5,paddingRight:5,display:"inline-block",opacity:0,visibility:"visible"}}},{props:({ownerState:t})=>t.withLabel&&t.notched,style:{maxWidth:"100%",transition:e.transitions.create("max-width",{duration:100,easing:e.transitions.easing.easeOut,delay:50})}}]})));function qj(e){const{children:t,classes:n,className:r,label:i,notched:o,...a}=e,s=i!=null&&i!=="",l={...e,notched:o,withLabel:s};return h.jsx(Aae,{"aria-hidden":!0,className:r,ownerState:l,...a,children:h.jsx(Tae,{ownerState:l,children:s?h.jsx("span",{children:i}):Kj||(Kj=h.jsx("span",{className:"notranslate","aria-hidden":!0,children:""}))})})}process.env.NODE_ENV!=="production"&&(qj.propTypes={children:b.node,classes:b.object,className:b.string,label:b.node,notched:b.bool.isRequired,style:b.object});const Nae=e=>{const{classes:t}=e,r=kn({root:["root"],notchedOutline:["notchedOutline"],input:["input"]},Moe,t);return{...t,...r}},jae=De(Ph,{shouldForwardProp:e=>Zi(e)||e==="classes",name:"MuiOutlinedInput",slot:"Root",overridesResolver:Ch})(Hn(({theme:e})=>{const t=e.palette.mode==="light"?"rgba(0, 0, 0, 0.23)":"rgba(255, 255, 255, 0.23)";return{position:"relative",borderRadius:(e.vars||e).shape.borderRadius,[`&:hover .${Wi.notchedOutline}`]:{borderColor:(e.vars||e).palette.text.primary},"@media (hover: none)":{[`&:hover .${Wi.notchedOutline}`]:{borderColor:e.vars?e.alpha(e.vars.palette.common.onBackground,.23):t}},[`&.${Wi.focused} .${Wi.notchedOutline}`]:{borderWidth:2},variants:[...Object.entries(e.palette).filter(Ax()).map(([n])=>({props:{color:n},style:{[`&.${Wi.focused} .${Wi.notchedOutline}`]:{borderColor:(e.vars||e).palette[n].main}}})),{props:{},style:{[`&.${Wi.error} .${Wi.notchedOutline}`]:{borderColor:(e.vars||e).palette.error.main},[`&.${Wi.disabled} .${Wi.notchedOutline}`]:{borderColor:(e.vars||e).palette.action.disabled}}},{props:({ownerState:n})=>n.startAdornment,style:{paddingLeft:14}},{props:({ownerState:n})=>n.endAdornment,style:{paddingRight:14}},{props:({ownerState:n})=>n.multiline,style:{padding:"16.5px 14px"}},{props:({ownerState:n,size:r})=>n.multiline&&r==="small",style:{padding:"8.5px 14px"}}]}})),Mae=De(qj,{name:"MuiOutlinedInput",slot:"NotchedOutline"})(Hn(({theme:e})=>{const t=e.palette.mode==="light"?"rgba(0, 0, 0, 0.23)":"rgba(255, 255, 255, 0.23)";return{borderColor:e.vars?e.alpha(e.vars.palette.common.onBackground,.23):t}})),Iae=De(Dh,{name:"MuiOutlinedInput",slot:"Input",overridesResolver:kh})(Hn(({theme:e})=>({padding:"16.5px 14px",...!e.vars&&{"&:-webkit-autofill":{WebkitBoxShadow:e.palette.mode==="light"?null:"0 0 0 100px #266798 inset",WebkitTextFillColor:e.palette.mode==="light"?null:"#fff",caretColor:e.palette.mode==="light"?null:"#fff",borderRadius:"inherit"}},...e.vars&&{"&:-webkit-autofill":{borderRadius:"inherit"},[e.getColorSchemeSelector("dark")]:{"&:-webkit-autofill":{WebkitBoxShadow:"0 0 0 100px #266798 inset",WebkitTextFillColor:"#fff",caretColor:"#fff"}}},variants:[{props:{size:"small"},style:{padding:"8.5px 14px"}},{props:({ownerState:t})=>t.multiline,style:{padding:0}},{props:({ownerState:t})=>t.startAdornment,style:{paddingLeft:0}},{props:({ownerState:t})=>t.endAdornment,style:{paddingRight:0}}]}))),zx=O.forwardRef(function(t,n){const r=Zn({props:t,name:"MuiOutlinedInput"}),{components:i={},fullWidth:o=!1,inputComponent:a="input",label:s,multiline:l=!1,notched:c,slots:u={},slotProps:d={},type:f="text",...p}=r,m=Nae(r),g=Mx(),v=Nx({props:r,muiFormControl:g,states:["color","disabled","error","focused","hiddenLabel","size","required"]}),x={...r,color:v.color||"primary",disabled:v.disabled,error:v.error,focused:v.focused,formControl:g,fullWidth:o,hiddenLabel:v.hiddenLabel,multiline:l,size:v.size,type:f},_=u.root??i.Root??jae,w=u.input??i.Input??Iae,[y,E]=lr("notchedOutline",{elementType:Mae,className:m.notchedOutline,shouldForwardComponentProp:!0,ownerState:x,externalForwardedProps:{slots:u,slotProps:d},additionalProps:{label:s!=null&&s!==""&&v.required?h.jsxs(O.Fragment,{children:[s," ","*"]}):s}});return h.jsx(Ah,{slots:{root:_,input:w},slotProps:d,renderSuffix:S=>h.jsx(y,{...E,notched:typeof c<"u"?c:!!(S.startAdornment||S.filled||S.focused)}),fullWidth:o,inputComponent:a,multiline:l,ref:n,type:f,...p,classes:{...m,notchedOutline:null}})});process.env.NODE_ENV!=="production"&&(zx.propTypes={autoComplete:b.string,autoFocus:b.bool,classes:b.object,color:b.oneOfType([b.oneOf(["primary","secondary"]),b.string]),components:b.shape({Input:b.elementType,Root:b.elementType}),defaultValue:b.any,disabled:b.bool,endAdornment:b.node,error:b.bool,fullWidth:b.bool,id:b.string,inputComponent:b.elementType,inputProps:b.object,inputRef:Po,label:b.node,margin:b.oneOf(["dense","none"]),maxRows:b.oneOfType([b.number,b.string]),minRows:b.oneOfType([b.number,b.string]),multiline:b.bool,name:b.string,notched:b.bool,onChange:b.func,placeholder:b.string,readOnly:b.bool,required:b.bool,rows:b.oneOfType([b.number,b.string]),slotProps:b.shape({input:b.object,notchedOutline:b.oneOfType([b.func,b.object]),root:b.object}),slots:b.shape({input:b.elementType,notchedOutline:b.elementType,root:b.elementType}),startAdornment:b.node,sx:b.oneOfType([b.arrayOf(b.oneOfType([b.func,b.object,b.bool])),b.func,b.object]),type:b.string,value:b.any}),zx.muiName="Input";function Gj(e){return xn("MuiSelect",e)}const Tu=Vn("MuiSelect",["root","select","multiple","filled","outlined","standard","disabled","focused","icon","iconOpen","iconFilled","iconOutlined","iconStandard","nativeInput","error"]);var Xj;const Fae=De(Hj,{name:"MuiSelect",slot:"Select",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[{[`&.${Tu.select}`]:t.select},{[`&.${Tu.select}`]:t[n.variant]},{[`&.${Tu.error}`]:t.error},{[`&.${Tu.multiple}`]:t.multiple}]}})({[`&.${Tu.select}`]:{height:"auto",minHeight:"1.4375em",textOverflow:"ellipsis",whiteSpace:"nowrap",overflow:"hidden"}}),Lae=De(Yj,{name:"MuiSelect",slot:"Icon",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.icon,n.variant&&t[`icon${yn(n.variant)}`],n.open&&t.iconOpen]}})({}),Rae=De("input",{shouldForwardProp:e=>S_(e)&&e!=="classes",name:"MuiSelect",slot:"NativeInput"})({bottom:0,left:0,position:"absolute",opacity:0,pointerEvents:"none",width:"100%",boxSizing:"border-box"});function Qj(e,t){return typeof t=="object"&&t!==null?e===t:String(e)===String(t)}function $ae(e){return e==null||typeof e=="string"&&!e.trim()}const Bae=e=>{const{classes:t,variant:n,disabled:r,multiple:i,open:o,error:a}=e,s={select:["select",n,r&&"disabled",i&&"multiple",a&&"error"],icon:["icon",`icon${yn(n)}`,o&&"iconOpen",r&&"disabled"],nativeInput:["nativeInput"]};return kn(s,Gj,t)},Zj=O.forwardRef(function(t,n){const{"aria-describedby":r,"aria-label":i,autoFocus:o,autoWidth:a,children:s,className:l,defaultOpen:c,defaultValue:u,disabled:d,displayEmpty:f,error:p=!1,IconComponent:m,inputRef:g,labelId:v,MenuProps:x={},multiple:_,name:w,onBlur:y,onChange:E,onClose:S,onFocus:P,onOpen:D,open:T,readOnly:I,renderValue:A,required:C,SelectDisplayProps:j={},tabIndex:N,type:M,value:R,variant:B="standard",...V}=t,[z,W]=tg({controlled:R,default:u,name:"Select"}),[Q,G]=tg({controlled:T,default:c,name:"Select"}),ie=O.useRef(null),J=O.useRef(null),[re,se]=O.useState(null),{current:ce}=O.useRef(T!=null),[de,K]=O.useState(),U=Yn(n,g),Z=O.useCallback(Y=>{J.current=Y,Y&&se(Y)},[]),F=re?.parentNode;O.useImperativeHandle(U,()=>({focus:()=>{J.current.focus()},node:ie.current,value:z}),[z]),O.useEffect(()=>{c&&Q&&re&&!ce&&(K(a?null:F.clientWidth),J.current.focus())},[re,a]),O.useEffect(()=>{o&&J.current.focus()},[o]),O.useEffect(()=>{if(!v)return;const Y=gr(J.current).getElementById(v);if(Y){const ee=()=>{getSelection().isCollapsed&&J.current.focus()};return Y.addEventListener("click",ee),()=>{Y.removeEventListener("click",ee)}}},[v]);const ge=(Y,ee)=>{Y?D&&D(ee):S&&S(ee),ce||(K(a?null:F.clientWidth),G(Y))},oe=Y=>{Y.button===0&&(Y.preventDefault(),J.current.focus(),ge(!0,Y))},ye=Y=>{ge(!1,Y)},_e=O.Children.toArray(s),Ie=Y=>{const ee=_e.find(ne=>ne.props.value===Y.target.value);ee!==void 0&&(W(ee.props.value),E&&E(Y,ee))},tt=Y=>ee=>{let ne;if(ee.currentTarget.hasAttribute("tabindex")){if(_){ne=Array.isArray(z)?z.slice():[];const Ee=z.indexOf(Y.props.value);Ee===-1?ne.push(Y.props.value):ne.splice(Ee,1)}else ne=Y.props.value;if(Y.props.onClick&&Y.props.onClick(ee),z!==ne&&(W(ne),E)){const Ee=ee.nativeEvent||ee,Pe=new Ee.constructor(Ee.type,Ee);Object.defineProperty(Pe,"target",{writable:!0,value:{value:ne,name:w}}),E(Pe,Y)}_||ge(!1,ee)}},pt=Y=>{I||[" ","ArrowUp","ArrowDown","Enter"].includes(Y.key)&&(Y.preventDefault(),ge(!0,Y))},ct=re!==null&&Q,Fe=Y=>{!ct&&y&&(Object.defineProperty(Y,"target",{writable:!0,value:{value:z,name:w}}),y(Y))};delete V["aria-invalid"];let Pt,Dt;const ht=[];let mn=!1,sn=!1;(_j({value:z})||f)&&(A?Pt=A(z):mn=!0);const gn=_e.map(Y=>{if(!O.isValidElement(Y))return null;process.env.NODE_ENV!=="production"&&$o.isFragment(Y)&&console.error(["MUI: The Select component doesn't accept a Fragment as a child.","Consider providing an array instead."].join(`
|
|
258
258
|
`));let ee;if(_){if(!Array.isArray(z))throw new Error(process.env.NODE_ENV!=="production"?"MUI: The `value` prop must be an array when using the `Select` component with `multiple`.":pi(2));ee=z.some(ne=>Qj(ne,Y.props.value)),ee&&mn&&ht.push(Y.props.children)}else ee=Qj(z,Y.props.value),ee&&mn&&(Dt=Y.props.children);return ee&&(sn=!0),O.cloneElement(Y,{"aria-selected":ee?"true":"false",onClick:tt(Y),onKeyUp:ne=>{ne.key===" "&&ne.preventDefault(),Y.props.onKeyUp&&Y.props.onKeyUp(ne)},role:"option",selected:ee,value:void 0,"data-value":Y.props.value})});process.env.NODE_ENV!=="production"&&O.useEffect(()=>{if(!sn&&!_&&z!==""){const Y=_e.map(ee=>ee.props.value);console.warn([`MUI: You have provided an out-of-range value \`${z}\` for the select ${w?`(name="${w}") `:""}component.`,"Consider providing a value that matches one of the available options or ''.",`The available values are ${Y.filter(ee=>ee!=null).map(ee=>`\`${ee}\``).join(", ")||'""'}.`].join(`
|
|
259
|
-
`))}},[sn,_e,_,w,z]),mn&&(_?ht.length===0?Pt=null:Pt=ht.reduce((Y,ee,ne)=>(Y.push(ee),ne<ht.length-1&&Y.push(", "),Y),[]):Pt=Dt);let Wn=de;!a&&ce&&re&&(Wn=F.clientWidth);let Xt;typeof N<"u"?Xt=N:Xt=d?null:0;const zn=j.id||(w?`mui-component-select-${w}`:void 0),be={...t,variant:B,value:z,open:ct,error:p},vn=Bae(be),Qt={...x.PaperProps,...typeof x.slotProps?.paper=="function"?x.slotProps.paper(be):x.slotProps?.paper},L={...x.MenuListProps,...typeof x.slotProps?.list=="function"?x.slotProps.list(be):x.slotProps?.list},q=s_();return h.jsxs(O.Fragment,{children:[h.jsx(Fae,{as:"div",ref:Z,tabIndex:Xt,role:"combobox","aria-controls":ct?q:void 0,"aria-disabled":d?"true":void 0,"aria-expanded":ct?"true":"false","aria-haspopup":"listbox","aria-label":i,"aria-labelledby":[v,zn].filter(Boolean).join(" ")||void 0,"aria-describedby":r,"aria-required":C?"true":void 0,"aria-invalid":p?"true":void 0,onKeyDown:pt,onMouseDown:d||I?null:oe,onBlur:Fe,onFocus:P,...j,ownerState:be,className:ue(j.className,vn.select,l),id:zn,children:$ae(Pt)?Xj||(Xj=h.jsx("span",{className:"notranslate","aria-hidden":!0,children:""})):Pt}),h.jsx(Rae,{"aria-invalid":p,value:Array.isArray(z)?z.join(","):z,name:w,ref:ie,"aria-hidden":!0,onChange:Ie,tabIndex:-1,disabled:d,className:vn.nativeInput,autoFocus:o,required:C,...V,ownerState:be}),h.jsx(Lae,{as:m,className:vn.icon,ownerState:be}),h.jsx(Vj,{id:`menu-${w||""}`,anchorEl:F,open:ct,onClose:ye,anchorOrigin:{vertical:"bottom",horizontal:"center"},transformOrigin:{vertical:"top",horizontal:"center"},...x,slotProps:{...x.slotProps,list:{"aria-labelledby":v,role:"listbox","aria-multiselectable":_?"true":void 0,disableListWrap:!0,id:q,...L},paper:{...Qt,style:{minWidth:Wn,...Qt!=null?Qt.style:null}}},children:gn})]})});process.env.NODE_ENV!=="production"&&(Zj.propTypes={"aria-describedby":b.string,"aria-label":b.string,autoFocus:b.bool,autoWidth:b.bool,children:b.node,classes:b.object,className:b.string,defaultOpen:b.bool,defaultValue:b.any,disabled:b.bool,displayEmpty:b.bool,error:b.bool,IconComponent:b.elementType.isRequired,inputRef:Po,labelId:b.string,MenuProps:b.object,multiple:b.bool,name:b.string,onBlur:b.func,onChange:b.func,onClose:b.func,onFocus:b.func,onOpen:b.func,open:b.bool,readOnly:b.bool,renderValue:b.func,required:b.bool,SelectDisplayProps:b.object,tabIndex:b.oneOfType([b.number,b.string]),type:b.any,value:b.any,variant:b.oneOf(["standard","outlined","filled"])});const Wae=e=>{const{classes:t}=e,r=kn({root:["root"]},Gj,t);return{...t,...r}},Vx={name:"MuiSelect",slot:"Root",shouldForwardProp:e=>Zi(e)&&e!=="variant"},zae=De($x,Vx)(""),Vae=De(zx,Vx)(""),Hae=De(Fx,Vx)(""),Hx=O.forwardRef(function(t,n){const r=Zn({name:"MuiSelect",props:t}),{autoWidth:i=!1,children:o,classes:a={},className:s,defaultOpen:l=!1,displayEmpty:c=!1,IconComponent:u=Foe,id:d,input:f,inputProps:p,label:m,labelId:g,MenuProps:v,multiple:x=!1,native:_=!1,onClose:w,onOpen:y,open:E,renderValue:S,SelectDisplayProps:P,variant:D="outlined",...T}=r,I=_?Uj:Zj,A=Mx(),C=Nx({props:r,muiFormControl:A,states:["variant","error"]}),j=C.variant||D,N={...r,variant:j,classes:a},M=Wae(N),{root:R,...B}=M,V=f||{standard:h.jsx(zae,{ownerState:N}),outlined:h.jsx(Vae,{label:m,ownerState:N}),filled:h.jsx(Hae,{ownerState:N})}[j],z=Yn(n,kl(V));return h.jsx(O.Fragment,{children:O.cloneElement(V,{inputComponent:I,inputProps:{children:o,error:C.error,IconComponent:u,variant:j,type:void 0,multiple:x,..._?{id:d}:{autoWidth:i,defaultOpen:l,displayEmpty:c,labelId:g,MenuProps:v,onClose:w,onOpen:y,open:E,renderValue:S,SelectDisplayProps:{id:d,...P}},...p,classes:p?Pn(B,p.classes):B,...f?f.props.inputProps:{}},...(x&&_||c)&&j==="outlined"?{notched:!0}:{},ref:z,className:ue(V.props.className,s,M.root),...!f&&{variant:j},...T})})});process.env.NODE_ENV!=="production"&&(Hx.propTypes={autoWidth:b.bool,children:b.node,classes:b.object,className:b.string,defaultOpen:b.bool,defaultValue:b.any,displayEmpty:b.bool,IconComponent:b.elementType,id:b.string,input:b.element,inputProps:b.object,label:b.node,labelId:b.string,MenuProps:b.object,multiple:b.bool,native:b.bool,onChange:b.func,onClose:b.func,onOpen:b.func,open:b.bool,renderValue:b.func,SelectDisplayProps:b.object,sx:b.oneOfType([b.arrayOf(b.oneOfType([b.func,b.object,b.bool])),b.func,b.object]),value:b.oneOfType([b.oneOf([""]),b.any]),variant:b.oneOf(["filled","outlined","standard"])}),Hx.muiName="Select";function Yae(e){return xn("MuiTooltip",e)}const It=Vn("MuiTooltip",["popper","popperInteractive","popperArrow","popperClose","tooltip","tooltipArrow","touch","tooltipPlacementLeft","tooltipPlacementRight","tooltipPlacementTop","tooltipPlacementBottom","arrow"]);function Uae(e){return Math.round(e*1e5)/1e5}const Kae=e=>{const{classes:t,disableInteractive:n,arrow:r,touch:i,placement:o}=e,a={popper:["popper",!n&&"popperInteractive",r&&"popperArrow"],tooltip:["tooltip",r&&"tooltipArrow",i&&"touch",`tooltipPlacement${yn(o.split("-")[0])}`],arrow:["arrow"]};return kn(a,Yae,t)},qae=De(Tx,{name:"MuiTooltip",slot:"Popper",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.popper,!n.disableInteractive&&t.popperInteractive,n.arrow&&t.popperArrow,!n.open&&t.popperClose]}})(Hn(({theme:e})=>({zIndex:(e.vars||e).zIndex.tooltip,pointerEvents:"none",variants:[{props:({ownerState:t})=>!t.disableInteractive,style:{pointerEvents:"auto"}},{props:({open:t})=>!t,style:{pointerEvents:"none"}},{props:({ownerState:t})=>t.arrow,style:{[`&[data-popper-placement*="bottom"] .${It.arrow}`]:{top:0,marginTop:"-0.71em","&::before":{transformOrigin:"0 100%"}},[`&[data-popper-placement*="top"] .${It.arrow}`]:{bottom:0,marginBottom:"-0.71em","&::before":{transformOrigin:"100% 0"}},[`&[data-popper-placement*="right"] .${It.arrow}`]:{height:"1em",width:"0.71em","&::before":{transformOrigin:"100% 100%"}},[`&[data-popper-placement*="left"] .${It.arrow}`]:{height:"1em",width:"0.71em","&::before":{transformOrigin:"0 0"}}}},{props:({ownerState:t})=>t.arrow&&!t.isRtl,style:{[`&[data-popper-placement*="right"] .${It.arrow}`]:{left:0,marginLeft:"-0.71em"}}},{props:({ownerState:t})=>t.arrow&&!!t.isRtl,style:{[`&[data-popper-placement*="right"] .${It.arrow}`]:{right:0,marginRight:"-0.71em"}}},{props:({ownerState:t})=>t.arrow&&!t.isRtl,style:{[`&[data-popper-placement*="left"] .${It.arrow}`]:{right:0,marginRight:"-0.71em"}}},{props:({ownerState:t})=>t.arrow&&!!t.isRtl,style:{[`&[data-popper-placement*="left"] .${It.arrow}`]:{left:0,marginLeft:"-0.71em"}}}]}))),Gae=De("div",{name:"MuiTooltip",slot:"Tooltip",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.tooltip,n.touch&&t.touch,n.arrow&&t.tooltipArrow,t[`tooltipPlacement${yn(n.placement.split("-")[0])}`]]}})(Hn(({theme:e})=>({backgroundColor:e.vars?e.vars.palette.Tooltip.bg:e.alpha(e.palette.grey[700],.92),borderRadius:(e.vars||e).shape.borderRadius,color:(e.vars||e).palette.common.white,fontFamily:e.typography.fontFamily,padding:"4px 8px",fontSize:e.typography.pxToRem(11),maxWidth:300,margin:2,wordWrap:"break-word",fontWeight:e.typography.fontWeightMedium,[`.${It.popper}[data-popper-placement*="left"] &`]:{transformOrigin:"right center"},[`.${It.popper}[data-popper-placement*="right"] &`]:{transformOrigin:"left center"},[`.${It.popper}[data-popper-placement*="top"] &`]:{transformOrigin:"center bottom",marginBottom:"14px"},[`.${It.popper}[data-popper-placement*="bottom"] &`]:{transformOrigin:"center top",marginTop:"14px"},variants:[{props:({ownerState:t})=>t.arrow,style:{position:"relative",margin:0}},{props:({ownerState:t})=>t.touch,style:{padding:"8px 16px",fontSize:e.typography.pxToRem(14),lineHeight:`${Uae(16/14)}em`,fontWeight:e.typography.fontWeightRegular}},{props:({ownerState:t})=>!t.isRtl,style:{[`.${It.popper}[data-popper-placement*="left"] &`]:{marginRight:"14px"},[`.${It.popper}[data-popper-placement*="right"] &`]:{marginLeft:"14px"}}},{props:({ownerState:t})=>!t.isRtl&&t.touch,style:{[`.${It.popper}[data-popper-placement*="left"] &`]:{marginRight:"24px"},[`.${It.popper}[data-popper-placement*="right"] &`]:{marginLeft:"24px"}}},{props:({ownerState:t})=>!!t.isRtl,style:{[`.${It.popper}[data-popper-placement*="left"] &`]:{marginLeft:"14px"},[`.${It.popper}[data-popper-placement*="right"] &`]:{marginRight:"14px"}}},{props:({ownerState:t})=>!!t.isRtl&&t.touch,style:{[`.${It.popper}[data-popper-placement*="left"] &`]:{marginLeft:"24px"},[`.${It.popper}[data-popper-placement*="right"] &`]:{marginRight:"24px"}}},{props:({ownerState:t})=>t.touch,style:{[`.${It.popper}[data-popper-placement*="top"] &`]:{marginBottom:"24px"}}},{props:({ownerState:t})=>t.touch,style:{[`.${It.popper}[data-popper-placement*="bottom"] &`]:{marginTop:"24px"}}}]}))),Xae=De("span",{name:"MuiTooltip",slot:"Arrow"})(Hn(({theme:e})=>({overflow:"hidden",position:"absolute",width:"1em",height:"0.71em",boxSizing:"border-box",color:e.vars?e.vars.palette.Tooltip.bg:e.alpha(e.palette.grey[700],.9),"&::before":{content:'""',margin:"auto",display:"block",width:"100%",height:"100%",backgroundColor:"currentColor",transform:"rotate(45deg)"}})));let jh=!1;const Jj=new xh;let Nu={x:0,y:0};function Mh(e,t){return(n,...r)=>{t&&t(n,...r),e(n,...r)}}const eM=O.forwardRef(function(t,n){const r=Zn({props:t,name:"MuiTooltip"}),{arrow:i=!1,children:o,classes:a,components:s={},componentsProps:l={},describeChild:c=!1,disableFocusListener:u=!1,disableHoverListener:d=!1,disableInteractive:f=!1,disableTouchListener:p=!1,enterDelay:m=100,enterNextDelay:g=0,enterTouchDelay:v=700,followCursor:x=!1,id:_,leaveDelay:w=0,leaveTouchDelay:y=1500,onClose:E,onOpen:S,open:P,placement:D="bottom",PopperComponent:T,PopperProps:I={},slotProps:A={},slots:C={},title:j,TransitionComponent:N,TransitionProps:M,...R}=r,B=O.isValidElement(o)?o:h.jsx("span",{children:o}),V=Id(),z=Um(),[W,Q]=O.useState(),[X,ie]=O.useState(null),J=O.useRef(!1),re=f||x,se=Su(),ce=Su(),de=Su(),K=Su(),[U,Z]=tg({controlled:P,default:!1,name:"Tooltip",state:"open"});let F=U;if(process.env.NODE_ENV!=="production"){const{current:xe}=O.useRef(P!==void 0);O.useEffect(()=>{W&&W.disabled&&!xe&&j!==""&&W.tagName.toLowerCase()==="button"&&console.warn(["MUI: You are providing a disabled `button` child to the Tooltip component.","A disabled element does not fire events.","Tooltip needs to listen to the child element's events to display the title.","","Add a simple wrapper element, such as a `span`."].join(`
|
|
259
|
+
`))}},[sn,_e,_,w,z]),mn&&(_?ht.length===0?Pt=null:Pt=ht.reduce((Y,ee,ne)=>(Y.push(ee),ne<ht.length-1&&Y.push(", "),Y),[]):Pt=Dt);let Wn=de;!a&&ce&&re&&(Wn=F.clientWidth);let Xt;typeof N<"u"?Xt=N:Xt=d?null:0;const zn=j.id||(w?`mui-component-select-${w}`:void 0),be={...t,variant:B,value:z,open:ct,error:p},vn=Bae(be),Qt={...x.PaperProps,...typeof x.slotProps?.paper=="function"?x.slotProps.paper(be):x.slotProps?.paper},L={...x.MenuListProps,...typeof x.slotProps?.list=="function"?x.slotProps.list(be):x.slotProps?.list},q=s_();return h.jsxs(O.Fragment,{children:[h.jsx(Fae,{as:"div",ref:Z,tabIndex:Xt,role:"combobox","aria-controls":ct?q:void 0,"aria-disabled":d?"true":void 0,"aria-expanded":ct?"true":"false","aria-haspopup":"listbox","aria-label":i,"aria-labelledby":[v,zn].filter(Boolean).join(" ")||void 0,"aria-describedby":r,"aria-required":C?"true":void 0,"aria-invalid":p?"true":void 0,onKeyDown:pt,onMouseDown:d||I?null:oe,onBlur:Fe,onFocus:P,...j,ownerState:be,className:ue(j.className,vn.select,l),id:zn,children:$ae(Pt)?Xj||(Xj=h.jsx("span",{className:"notranslate","aria-hidden":!0,children:""})):Pt}),h.jsx(Rae,{"aria-invalid":p,value:Array.isArray(z)?z.join(","):z,name:w,ref:ie,"aria-hidden":!0,onChange:Ie,tabIndex:-1,disabled:d,className:vn.nativeInput,autoFocus:o,required:C,...V,ownerState:be}),h.jsx(Lae,{as:m,className:vn.icon,ownerState:be}),h.jsx(Vj,{id:`menu-${w||""}`,anchorEl:F,open:ct,onClose:ye,anchorOrigin:{vertical:"bottom",horizontal:"center"},transformOrigin:{vertical:"top",horizontal:"center"},...x,slotProps:{...x.slotProps,list:{"aria-labelledby":v,role:"listbox","aria-multiselectable":_?"true":void 0,disableListWrap:!0,id:q,...L},paper:{...Qt,style:{minWidth:Wn,...Qt!=null?Qt.style:null}}},children:gn})]})});process.env.NODE_ENV!=="production"&&(Zj.propTypes={"aria-describedby":b.string,"aria-label":b.string,autoFocus:b.bool,autoWidth:b.bool,children:b.node,classes:b.object,className:b.string,defaultOpen:b.bool,defaultValue:b.any,disabled:b.bool,displayEmpty:b.bool,error:b.bool,IconComponent:b.elementType.isRequired,inputRef:Po,labelId:b.string,MenuProps:b.object,multiple:b.bool,name:b.string,onBlur:b.func,onChange:b.func,onClose:b.func,onFocus:b.func,onOpen:b.func,open:b.bool,readOnly:b.bool,renderValue:b.func,required:b.bool,SelectDisplayProps:b.object,tabIndex:b.oneOfType([b.number,b.string]),type:b.any,value:b.any,variant:b.oneOf(["standard","outlined","filled"])});const Wae=e=>{const{classes:t}=e,r=kn({root:["root"]},Gj,t);return{...t,...r}},Vx={name:"MuiSelect",slot:"Root",shouldForwardProp:e=>Zi(e)&&e!=="variant"},zae=De($x,Vx)(""),Vae=De(zx,Vx)(""),Hae=De(Fx,Vx)(""),Hx=O.forwardRef(function(t,n){const r=Zn({name:"MuiSelect",props:t}),{autoWidth:i=!1,children:o,classes:a={},className:s,defaultOpen:l=!1,displayEmpty:c=!1,IconComponent:u=Foe,id:d,input:f,inputProps:p,label:m,labelId:g,MenuProps:v,multiple:x=!1,native:_=!1,onClose:w,onOpen:y,open:E,renderValue:S,SelectDisplayProps:P,variant:D="outlined",...T}=r,I=_?Uj:Zj,A=Mx(),C=Nx({props:r,muiFormControl:A,states:["variant","error"]}),j=C.variant||D,N={...r,variant:j,classes:a},M=Wae(N),{root:R,...B}=M,V=f||{standard:h.jsx(zae,{ownerState:N}),outlined:h.jsx(Vae,{label:m,ownerState:N}),filled:h.jsx(Hae,{ownerState:N})}[j],z=Yn(n,kl(V));return h.jsx(O.Fragment,{children:O.cloneElement(V,{inputComponent:I,inputProps:{children:o,error:C.error,IconComponent:u,variant:j,type:void 0,multiple:x,..._?{id:d}:{autoWidth:i,defaultOpen:l,displayEmpty:c,labelId:g,MenuProps:v,onClose:w,onOpen:y,open:E,renderValue:S,SelectDisplayProps:{id:d,...P}},...p,classes:p?Pn(B,p.classes):B,...f?f.props.inputProps:{}},...(x&&_||c)&&j==="outlined"?{notched:!0}:{},ref:z,className:ue(V.props.className,s,M.root),...!f&&{variant:j},...T})})});process.env.NODE_ENV!=="production"&&(Hx.propTypes={autoWidth:b.bool,children:b.node,classes:b.object,className:b.string,defaultOpen:b.bool,defaultValue:b.any,displayEmpty:b.bool,IconComponent:b.elementType,id:b.string,input:b.element,inputProps:b.object,label:b.node,labelId:b.string,MenuProps:b.object,multiple:b.bool,native:b.bool,onChange:b.func,onClose:b.func,onOpen:b.func,open:b.bool,renderValue:b.func,SelectDisplayProps:b.object,sx:b.oneOfType([b.arrayOf(b.oneOfType([b.func,b.object,b.bool])),b.func,b.object]),value:b.oneOfType([b.oneOf([""]),b.any]),variant:b.oneOf(["filled","outlined","standard"])}),Hx.muiName="Select";function Yae(e){return xn("MuiTooltip",e)}const It=Vn("MuiTooltip",["popper","popperInteractive","popperArrow","popperClose","tooltip","tooltipArrow","touch","tooltipPlacementLeft","tooltipPlacementRight","tooltipPlacementTop","tooltipPlacementBottom","arrow"]);function Uae(e){return Math.round(e*1e5)/1e5}const Kae=e=>{const{classes:t,disableInteractive:n,arrow:r,touch:i,placement:o}=e,a={popper:["popper",!n&&"popperInteractive",r&&"popperArrow"],tooltip:["tooltip",r&&"tooltipArrow",i&&"touch",`tooltipPlacement${yn(o.split("-")[0])}`],arrow:["arrow"]};return kn(a,Yae,t)},qae=De(Tx,{name:"MuiTooltip",slot:"Popper",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.popper,!n.disableInteractive&&t.popperInteractive,n.arrow&&t.popperArrow,!n.open&&t.popperClose]}})(Hn(({theme:e})=>({zIndex:(e.vars||e).zIndex.tooltip,pointerEvents:"none",variants:[{props:({ownerState:t})=>!t.disableInteractive,style:{pointerEvents:"auto"}},{props:({open:t})=>!t,style:{pointerEvents:"none"}},{props:({ownerState:t})=>t.arrow,style:{[`&[data-popper-placement*="bottom"] .${It.arrow}`]:{top:0,marginTop:"-0.71em","&::before":{transformOrigin:"0 100%"}},[`&[data-popper-placement*="top"] .${It.arrow}`]:{bottom:0,marginBottom:"-0.71em","&::before":{transformOrigin:"100% 0"}},[`&[data-popper-placement*="right"] .${It.arrow}`]:{height:"1em",width:"0.71em","&::before":{transformOrigin:"100% 100%"}},[`&[data-popper-placement*="left"] .${It.arrow}`]:{height:"1em",width:"0.71em","&::before":{transformOrigin:"0 0"}}}},{props:({ownerState:t})=>t.arrow&&!t.isRtl,style:{[`&[data-popper-placement*="right"] .${It.arrow}`]:{left:0,marginLeft:"-0.71em"}}},{props:({ownerState:t})=>t.arrow&&!!t.isRtl,style:{[`&[data-popper-placement*="right"] .${It.arrow}`]:{right:0,marginRight:"-0.71em"}}},{props:({ownerState:t})=>t.arrow&&!t.isRtl,style:{[`&[data-popper-placement*="left"] .${It.arrow}`]:{right:0,marginRight:"-0.71em"}}},{props:({ownerState:t})=>t.arrow&&!!t.isRtl,style:{[`&[data-popper-placement*="left"] .${It.arrow}`]:{left:0,marginLeft:"-0.71em"}}}]}))),Gae=De("div",{name:"MuiTooltip",slot:"Tooltip",overridesResolver:(e,t)=>{const{ownerState:n}=e;return[t.tooltip,n.touch&&t.touch,n.arrow&&t.tooltipArrow,t[`tooltipPlacement${yn(n.placement.split("-")[0])}`]]}})(Hn(({theme:e})=>({backgroundColor:e.vars?e.vars.palette.Tooltip.bg:e.alpha(e.palette.grey[700],.92),borderRadius:(e.vars||e).shape.borderRadius,color:(e.vars||e).palette.common.white,fontFamily:e.typography.fontFamily,padding:"4px 8px",fontSize:e.typography.pxToRem(11),maxWidth:300,margin:2,wordWrap:"break-word",fontWeight:e.typography.fontWeightMedium,[`.${It.popper}[data-popper-placement*="left"] &`]:{transformOrigin:"right center"},[`.${It.popper}[data-popper-placement*="right"] &`]:{transformOrigin:"left center"},[`.${It.popper}[data-popper-placement*="top"] &`]:{transformOrigin:"center bottom",marginBottom:"14px"},[`.${It.popper}[data-popper-placement*="bottom"] &`]:{transformOrigin:"center top",marginTop:"14px"},variants:[{props:({ownerState:t})=>t.arrow,style:{position:"relative",margin:0}},{props:({ownerState:t})=>t.touch,style:{padding:"8px 16px",fontSize:e.typography.pxToRem(14),lineHeight:`${Uae(16/14)}em`,fontWeight:e.typography.fontWeightRegular}},{props:({ownerState:t})=>!t.isRtl,style:{[`.${It.popper}[data-popper-placement*="left"] &`]:{marginRight:"14px"},[`.${It.popper}[data-popper-placement*="right"] &`]:{marginLeft:"14px"}}},{props:({ownerState:t})=>!t.isRtl&&t.touch,style:{[`.${It.popper}[data-popper-placement*="left"] &`]:{marginRight:"24px"},[`.${It.popper}[data-popper-placement*="right"] &`]:{marginLeft:"24px"}}},{props:({ownerState:t})=>!!t.isRtl,style:{[`.${It.popper}[data-popper-placement*="left"] &`]:{marginLeft:"14px"},[`.${It.popper}[data-popper-placement*="right"] &`]:{marginRight:"14px"}}},{props:({ownerState:t})=>!!t.isRtl&&t.touch,style:{[`.${It.popper}[data-popper-placement*="left"] &`]:{marginLeft:"24px"},[`.${It.popper}[data-popper-placement*="right"] &`]:{marginRight:"24px"}}},{props:({ownerState:t})=>t.touch,style:{[`.${It.popper}[data-popper-placement*="top"] &`]:{marginBottom:"24px"}}},{props:({ownerState:t})=>t.touch,style:{[`.${It.popper}[data-popper-placement*="bottom"] &`]:{marginTop:"24px"}}}]}))),Xae=De("span",{name:"MuiTooltip",slot:"Arrow"})(Hn(({theme:e})=>({overflow:"hidden",position:"absolute",width:"1em",height:"0.71em",boxSizing:"border-box",color:e.vars?e.vars.palette.Tooltip.bg:e.alpha(e.palette.grey[700],.9),"&::before":{content:'""',margin:"auto",display:"block",width:"100%",height:"100%",backgroundColor:"currentColor",transform:"rotate(45deg)"}})));let jh=!1;const Jj=new xh;let Nu={x:0,y:0};function Mh(e,t){return(n,...r)=>{t&&t(n,...r),e(n,...r)}}const eM=O.forwardRef(function(t,n){const r=Zn({props:t,name:"MuiTooltip"}),{arrow:i=!1,children:o,classes:a,components:s={},componentsProps:l={},describeChild:c=!1,disableFocusListener:u=!1,disableHoverListener:d=!1,disableInteractive:f=!1,disableTouchListener:p=!1,enterDelay:m=100,enterNextDelay:g=0,enterTouchDelay:v=700,followCursor:x=!1,id:_,leaveDelay:w=0,leaveTouchDelay:y=1500,onClose:E,onOpen:S,open:P,placement:D="bottom",PopperComponent:T,PopperProps:I={},slotProps:A={},slots:C={},title:j,TransitionComponent:N,TransitionProps:M,...R}=r,B=O.isValidElement(o)?o:h.jsx("span",{children:o}),V=Id(),z=Um(),[W,Q]=O.useState(),[G,ie]=O.useState(null),J=O.useRef(!1),re=f||x,se=Su(),ce=Su(),de=Su(),K=Su(),[U,Z]=tg({controlled:P,default:!1,name:"Tooltip",state:"open"});let F=U;if(process.env.NODE_ENV!=="production"){const{current:xe}=O.useRef(P!==void 0);O.useEffect(()=>{W&&W.disabled&&!xe&&j!==""&&W.tagName.toLowerCase()==="button"&&console.warn(["MUI: You are providing a disabled `button` child to the Tooltip component.","A disabled element does not fire events.","Tooltip needs to listen to the child element's events to display the title.","","Add a simple wrapper element, such as a `span`."].join(`
|
|
260
260
|
`))},[j,W,xe])}const ge=s_(_),oe=O.useRef(),ye=oc(()=>{oe.current!==void 0&&(document.body.style.WebkitUserSelect=oe.current,oe.current=void 0),K.clear()});O.useEffect(()=>ye,[ye]);const _e=xe=>{Jj.clear(),jh=!0,Z(!0),S&&!F&&S(xe)},Ie=oc(xe=>{Jj.start(800+w,()=>{jh=!1}),Z(!1),E&&F&&E(xe),se.start(V.transitions.duration.shortest,()=>{J.current=!1})}),tt=xe=>{J.current&&xe.type!=="touchstart"||(W&&W.removeAttribute("title"),ce.clear(),de.clear(),m||jh&&g?ce.start(jh?g:m,()=>{_e(xe)}):_e(xe))},pt=xe=>{ce.clear(),de.start(w,()=>{Ie(xe)})},[,ct]=O.useState(!1),Fe=xe=>{gj(xe.target)||(ct(!1),pt(xe))},Pt=xe=>{W||Q(xe.currentTarget),gj(xe.target)&&(ct(!0),tt(xe))},Dt=xe=>{J.current=!0;const cn=B.props;cn.onTouchStart&&cn.onTouchStart(xe)},ht=xe=>{Dt(xe),de.clear(),se.clear(),ye(),oe.current=document.body.style.WebkitUserSelect,document.body.style.WebkitUserSelect="none",K.start(v,()=>{document.body.style.WebkitUserSelect=oe.current,tt(xe)})},mn=xe=>{B.props.onTouchEnd&&B.props.onTouchEnd(xe),ye(),de.start(y,()=>{Ie(xe)})};O.useEffect(()=>{if(!F)return;function xe(cn){cn.key==="Escape"&&Ie(cn)}return document.addEventListener("keydown",xe),()=>{document.removeEventListener("keydown",xe)}},[Ie,F]);const sn=Yn(kl(B),Q,n);!j&&j!==0&&(F=!1);const gn=O.useRef(),Wn=xe=>{const cn=B.props;cn.onMouseMove&&cn.onMouseMove(xe),Nu={x:xe.clientX,y:xe.clientY},gn.current&&gn.current.update()},Xt={},zn=typeof j=="string";c?(Xt.title=!F&&zn&&!d?j:null,Xt["aria-describedby"]=F?ge:null):(Xt["aria-label"]=zn?j:null,Xt["aria-labelledby"]=F&&!zn?ge:null);const be={...Xt,...R,...B.props,className:ue(R.className,B.props.className),onTouchStart:Dt,ref:sn,...x?{onMouseMove:Wn}:{}};process.env.NODE_ENV!=="production"&&(be["data-mui-internal-clone-element"]=!0,O.useEffect(()=>{W&&!W.getAttribute("data-mui-internal-clone-element")&&console.error(["MUI: The `children` component of the Tooltip is not forwarding its props correctly.","Please make sure that props are spread on the same element that the ref is applied to."].join(`
|
|
261
261
|
`))},[W]));const vn={};p||(be.onTouchStart=ht,be.onTouchEnd=mn),d||(be.onMouseOver=Mh(tt,be.onMouseOver),be.onMouseLeave=Mh(pt,be.onMouseLeave),re||(vn.onMouseOver=tt,vn.onMouseLeave=pt)),u||(be.onFocus=Mh(Pt,be.onFocus),be.onBlur=Mh(Fe,be.onBlur),re||(vn.onFocus=Pt,vn.onBlur=Fe)),process.env.NODE_ENV!=="production"&&B.props.title&&console.error(["MUI: You have provided a `title` prop to the child of <Tooltip />.",`Remove this title prop \`${B.props.title}\` or the Tooltip component.`].join(`
|
|
262
|
-
`));const Qt={...r,isRtl:z,arrow:i,disableInteractive:re,placement:D,PopperComponentProp:T,touch:J.current},L=typeof A.popper=="function"?A.popper(Qt):A.popper,q=O.useMemo(()=>{let xe=[{name:"arrow",enabled:!!X,options:{element:X,padding:4}}];return I.popperOptions?.modifiers&&(xe=xe.concat(I.popperOptions.modifiers)),L?.popperOptions?.modifiers&&(xe=xe.concat(L.popperOptions.modifiers)),{...I.popperOptions,...L?.popperOptions,modifiers:xe}},[X,I.popperOptions,L?.popperOptions]),Y=Kae(Qt),ee=typeof A.transition=="function"?A.transition(Qt):A.transition,ne={slots:{popper:s.Popper,transition:s.Transition??N,tooltip:s.Tooltip,arrow:s.Arrow,...C},slotProps:{arrow:A.arrow??l.arrow,popper:{...I,...L??l.popper},tooltip:A.tooltip??l.tooltip,transition:{...M,...ee??l.transition}}},[Ee,Pe]=lr("popper",{elementType:qae,externalForwardedProps:ne,ownerState:Qt,className:ue(Y.popper,I?.className)}),[ln,ci]=lr("transition",{elementType:Pu,externalForwardedProps:ne,ownerState:Qt}),[Zt,ui]=lr("tooltip",{elementType:Gae,className:Y.tooltip,externalForwardedProps:ne,ownerState:Qt}),[fr,Cn]=lr("arrow",{elementType:Xae,className:Y.arrow,externalForwardedProps:ne,ownerState:Qt,ref:ie});return h.jsxs(O.Fragment,{children:[O.cloneElement(B,be),h.jsx(Ee,{as:T??Tx,placement:D,anchorEl:x?{getBoundingClientRect:()=>({top:Nu.y,left:Nu.x,right:Nu.x,bottom:Nu.y,width:0,height:0})}:W,popperRef:gn,open:W?F:!1,id:ge,transition:!0,...vn,...Pe,popperOptions:q,children:({TransitionProps:xe})=>h.jsx(ln,{timeout:V.transitions.duration.shorter,...xe,...ci,children:h.jsxs(Zt,{...ui,children:[j,i?h.jsx(fr,{...Cn}):null]})})})]})});process.env.NODE_ENV!=="production"&&(eM.propTypes={arrow:b.bool,children:Dl.isRequired,classes:b.object,className:b.string,components:b.shape({Arrow:b.elementType,Popper:b.elementType,Tooltip:b.elementType,Transition:b.elementType}),componentsProps:b.shape({arrow:b.object,popper:b.object,tooltip:b.object,transition:b.object}),describeChild:b.bool,disableFocusListener:b.bool,disableHoverListener:b.bool,disableInteractive:b.bool,disableTouchListener:b.bool,enterDelay:b.number,enterNextDelay:b.number,enterTouchDelay:b.number,followCursor:b.bool,id:b.string,leaveDelay:b.number,leaveTouchDelay:b.number,onClose:b.func,onOpen:b.func,open:b.bool,placement:b.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),PopperComponent:b.elementType,PopperProps:b.object,slotProps:b.shape({arrow:b.oneOfType([b.func,b.object]),popper:b.oneOfType([b.func,b.object]),tooltip:b.oneOfType([b.func,b.object]),transition:b.oneOfType([b.func,b.object])}),slots:b.shape({arrow:b.elementType,popper:b.elementType,tooltip:b.elementType,transition:b.elementType}),sx:b.oneOfType([b.arrayOf(b.oneOfType([b.func,b.object,b.bool])),b.func,b.object]),title:b.node,TransitionComponent:b.elementType,TransitionProps:b.object});function Qae(e){return gt({attr:{viewBox:"0 0 24 24"},child:[{tag:"g",attr:{id:"Export"},child:[{tag:"g",attr:{},child:[{tag:"path",attr:{d:"M5.552,20.968a2.577,2.577,0,0,1-2.5-2.73c-.012-2.153,0-4.306,0-6.459a.5.5,0,0,1,1,0c0,2.2-.032,4.4,0,6.6.016,1.107.848,1.589,1.838,1.589H18.353A1.546,1.546,0,0,0,19.825,19a3.023,3.023,0,0,0,.1-1.061V11.779h0a.5.5,0,0,1,1,0c0,2.224.085,4.465,0,6.687a2.567,2.567,0,0,1-2.67,2.5Z"},child:[]},{tag:"path",attr:{d:"M12.337,3.176a.455.455,0,0,0-.311-.138c-.015,0-.028,0-.043-.006s-.027,0-.041.006a.457.457,0,0,0-.312.138L7.961,6.845a.5.5,0,0,0,.707.707l2.816-2.815V15.479a.5.5,0,0,0,1,0V4.737L15.3,7.552a.5.5,0,0,0,.707-.707Z"},child:[]}]}]}]})(e)}function Zae(e){return gt({attr:{viewBox:"0 0 24 24"},child:[{tag:"g",attr:{id:"Warning"},child:[{tag:"g",attr:{},child:[{tag:"g",attr:{},child:[{tag:"path",attr:{d:"M12.5,8.752a.5.5,0,0,0-1,0h0v6a.5.5,0,0,0,1,0Z"},child:[]},{tag:"circle",attr:{cx:"11.999",cy:"16.736",r:"0.5"},child:[]}]},{tag:"path",attr:{d:"M18.642,20.934H5.385A2.5,2.5,0,0,1,3.163,17.29L9.792,4.421a2.5,2.5,0,0,1,4.444,0L20.865,17.29a2.5,2.5,0,0,1-2.223,3.644ZM12.014,4.065a1.478,1.478,0,0,0-1.334.814L4.052,17.748a1.5,1.5,0,0,0,1.333,2.186H18.642a1.5,1.5,0,0,0,1.334-2.186L13.348,4.879A1.478,1.478,0,0,0,12.014,4.065Z"},child:[]}]}]}]})(e)}Pd(Hx)(()=>({width:"fit-content",maxWidth:"100px",height:"28px",padding:"0 6px",display:"flex",fontSize:"12px",alignItems:"center","& .MuiSelect-select":{padding:0},"& .MuiOutlinedInput-notchedOutline":{borderColor:"#C6C6C6",transition:"all 0.2s ease"},"&:hover .MuiOutlinedInput-notchedOutline":{borderColor:"#B084CC"},"&.Mui-focused .MuiOutlinedInput-notchedOutline":{borderColor:"#884EA7 !important",boxShadow:"0 0 0 3px rgba(136, 78, 167, 0.2)"}}));function Al({widgetId:e,options:t=[],defaultValue:n=["all"],onFilterChange:r=()=>{},onExport:i=()=>{}}){const o=JSON.parse(sessionStorage.getItem("community_id"))||[],[a,s]=k.useState(o),[l,c]=k.useState("");t.filter(d=>d.community_name.toLowerCase().includes(l.toLowerCase()));const u=()=>{e2("widget_id",e),e2("export",!0),i()};return h.jsx("div",{className:"flex items-center gap-[8px]",children:h.jsx(eM,{title:"Export CSV for this widget",children:h.jsx("button",{onClick:u,className:"px-[12px] py-[8px] bg-[#FBF5FF] rounded cursor-pointer",children:h.jsx(Qae,{className:"stroke-[#884EA7] stroke-[1.4]"})})})})}function Jae({isStatic:e,data:t}){const n=Number(t?.thisMonthMoveIns??t?.lastMonthMoveIns??0),r=Number(t?.thisMonthMoveOuts??t?.lastMonthMoveOuts??0),i=Number(t?.moveInPercentChange??t?.moveInChange??0),o=Number(t?.moveOutPercentChange??t?.moveOutChange??0),a=["#8B5CF6","#EBE4F9"],s=[{name:"Move-ins",value:n,color:a[0]},{name:"Move-outs",value:r,color:a[1]}];function l(c,u){return((Number(c)+Number(u))/2).toFixed(2)+"%"}return h.jsx(Ia,{title:"Community",period:"This Month",icon:h.jsx(aS,{className:"!text-[24px] text-[#329DFF]"}),className:`${e&&"max-h-[184px]"} h-[184px] mb-4 break-inside-avoid gap-[20px]`,actionButtons:h.jsx(Al,{widgetId:t?.widget_id,options:t?.communities}),children:h.jsxs("div",{className:"flex",children:[h.jsxs("div",{className:"w-[50%] flex flex-col gap-[28px]",children:[h.jsxs("div",{className:"flex flex-col gap-[8px]",children:[h.jsx("div",{className:"!m-0 !text-[12px] !leading-[16px] !text-[#64748B]",children:"Move-in/Out Count"}),h.jsx("div",{className:"!m-0 !text-[28px] !leading-[32px] !font-medium !text-[#8B5CF6]",children:n+r})]}),h.jsxs("div",{className:"!m-0 !text-[10px] !leading-[14px] !text-[#64748B] flex items-center gap-[4px]",children:[h.jsx(Tc,{value:l(i,o)}),h.jsx("div",{className:"whitespace-nowrap",children:"Compared to last month"})]})]}),h.jsx("div",{className:"w-[50%] h-[111px] flex justify-end",children:h.jsx(Ot,{width:"75%",height:"100%",children:h.jsxs($i,{children:[h.jsxs(ai,{data:s,innerRadius:36,outerRadius:52,paddingAngle:2,dataKey:"value",children:[h.jsx(In,{fill:a[0]}),h.jsx(In,{fill:a[1]})]}),h.jsx(St,{content:Nc({data:s})})]})})})]})})}function tM({isStatic:e,data:t,communities:n}){const r=["#8B5CF6","#22C55E","#3B82F6","#F59E0B"],i=[{name:"Notice",value:Number(t?.total_notices||0),fill:r[0]},{name:"Post",value:Number(t?.total_topics||t?.total_forum_topics||0),fill:r[1]},{name:"Poll",value:Number(t?.total_polls||t?.total_poll_detail||0),fill:r[2]},{name:"Survey",value:Number(t?.total_surveys||t?.total_survey_detail||0),fill:r[3]}],o=t?.widget==="commercial";return h.jsx(Ia,{title:"Engagement",period:"This Month",icon:h.jsx(sS,{className:"!text-[20px] text-[#DBB467]"}),className:`${e&&"max-h-[303px]"} ${o?"h-[324px]":"h-[303px]"} `,childrenClassName:`${o?"mt-[52px]":"mt-0"}`,actionButtons:!o&&h.jsx(Al,{widgetId:t?.widget_id,options:t?.communities}),children:h.jsx("div",{className:`w-full ${o?"h-[220px]":"h-[260px]"}`,children:h.jsx(Ot,{width:"100%",height:"100%",children:h.jsxs(ko,{data:i,layout:"vertical",margin:{top:4,right:8,left:0,bottom:0},children:[h.jsx(sr,{stroke:"#e5e7eb",strokeDasharray:"3 3",horizontal:!1}),h.jsx(Rn,{type:"category",dataKey:"name",width:40,axisLine:!1,tickLine:!1,tick:{fontSize:10,lineHeight:14,fill:"#121212",fontWeight:400}}),h.jsx(Gn,{type:"number",allowDecimals:!1,axisLine:!1,tickLine:!1,tick:{fontSize:10,lineHeight:14,fill:"#64748B",fontWeight:400}}),h.jsx(St,{cursor:{fill:"transparent"},wrapperStyle:{outline:"none"},position:{x:160,y:0},allowEscapeViewBox:{x:!0,y:!0},content:a=>a.active?h.jsx(Ut,{...a,data:i,children:h.jsx(Rr,{...a})}):null}),h.jsx(Gt,{dataKey:"value",barSize:40,isAnimationActive:!1,children:i.map((a,s)=>h.jsx(In,{fill:r[s],dataKey:"value"},a.name))})]})})})})}function ese({isStatic:e,data:t}){const n=Number(t?.totalBookings||0),r=Number(t?.averageUtilizationPercentage||0),i=k.useMemo(()=>{if(!t?.graph)return[];const{labels:s=[],bookings:l=[],utilization:c=[]}=t.graph;return s.map((u,d)=>({time:u,bookings:l[d]||0,utilization:c[d]||0}))},[t]),o=s=>["12 AM","6 AM","12 PM","6 PM","11 PM"].includes(s)?s:"",a=i.length?i:Array.from({length:24},(s,l)=>({time:`${l%12||12} ${l>=12?"PM":"AM"}`,bookings:0,utilization:0}));return h.jsxs(Ia,{title:"Facilities",period:"Today",icon:h.jsx(Ag,{className:"!text-[24px] text-[#8B5CF6]"}),className:`${e&&"max-h-[305px]"} h-[305px] mb-4 break-inside-avoid`,actionButtons:h.jsx(Al,{widgetId:t?.widget_id,options:t?.communities}),children:[h.jsxs("div",{className:"grid grid-cols-2 gap-[24px] mt-[16px] mb-[16px]",children:[h.jsxs("div",{children:[h.jsx("div",{className:"!text-[12px] text-[#64748B]",children:"Bookings"}),h.jsx("div",{className:"!text-[24px] font-medium text-[#8B5CF6]",children:n})]}),h.jsxs("div",{children:[h.jsx("div",{className:"!text-[12px] text-[#64748B]",children:"Utilisation Rate"}),h.jsxs("div",{className:"!text-[24px] font-medium text-[#329DFF]",children:[r.toFixed(2),"%"]})]})]}),h.jsx("div",{className:"w-full h-[170px]",children:h.jsx(Ot,{width:"100%",height:"100%",children:h.jsxs(Ox,{data:a,margin:{top:5,right:-30,left:-35,bottom:0},children:[h.jsx(sr,{strokeDasharray:"3 3",stroke:"#EBEBEB"}),h.jsx(Gn,{dataKey:"time",interval:0,tickFormatter:o,tick:{fontSize:10,fill:"#121212",fontWeight:400},axisLine:!1,tickLine:!1,minTickGap:0}),h.jsx(Rn,{yAxisId:"left",tick:{fontSize:10,fill:"#64748B"},axisLine:!1,tickLine:!1}),h.jsx(Rn,{yAxisId:"right",orientation:"right",domain:[0,100],ticks:[0,20,40,60,80,100],tickFormatter:s=>`${s}%`,tick:{fontSize:10,fill:"#64748B"},axisLine:!1,tickLine:!1}),h.jsx(St,{cursor:{stroke:"transparent"},wrapperStyle:{outline:"none"},allowEscapeViewBox:{x:!0,y:!0},content:Nc({data:a})}),h.jsx(da,{yAxisId:"left",type:"monotone",dataKey:"bookings",name:"Bookings",stroke:"#8B5CF6",strokeWidth:2,dot:!1,isAnimationActive:!1}),h.jsx(da,{yAxisId:"right",type:"monotone",dataKey:"utilization",name:"Utilization Rate",stroke:"#329DFF",strokeWidth:2,dot:!1,strokeDasharray:"2 4",isAnimationActive:!1})]})})})]})}function tse({data:e}){const t=e?.incomeSummary||{},n=e?.expenditureSummary||{},r=["AED","USD","EUR"],i=["Rs","INR","₹"];function o(s){if(s==null||isNaN(s))return"0";const l=Number(s),c=Math.abs(l),u=l<0?"-":"";return c>=1e9?u+(c/1e9).toFixed(c%1e9===0?0:2)+"B":c>=1e6?u+(c/1e6).toFixed(c%1e6===0?0:2)+"M":c>=1e3?u+(c/1e3).toFixed(c%1e3===0?0:2)+"K":u+c.toFixed(c%1===0?0:2)}function a(s,l){return l?i.includes(l)?`${l} ${o(s)}`:r.includes(l)?`${o(s)} ${l}`:`${o(s)} ${l}`:o(s)}return h.jsx(Ia,{title:"Income",period:"This Month",icon:h.jsx(wf,{className:"!text-[24px] text-green-600"}),className:"!gap-[16px] break-inside-avoid h-[232px] overflow-hidden",actionButtons:h.jsx(Al,{widgetId:e?.widget_id,options:e?.communities}),children:h.jsxs("div",{children:[h.jsxs("div",{className:"grid grid-cols-4 !text-[12px] text-[#64748B] mb-[8px]",children:[h.jsx("div",{children:"Opening"}),h.jsx("div",{children:"Income"}),h.jsx("div",{children:"Collection"}),h.jsx("div",{children:"Closing"})]}),h.jsxs("div",{className:"grid grid-cols-4 !text-[12px] font-medium text-[#121212] mb-[8px]",children:[h.jsx("div",{children:a(t.opening_balance,t?.currency_type)}),h.jsx("div",{children:a(t.income,t?.currency_type)}),h.jsx("div",{children:a(t.collection,t?.currency_type)}),h.jsx("div",{children:a(t.closing_balance,t?.currency_type)})]}),h.jsx("hr",{className:"my-4 border-t border-dashed border-gray-300"}),h.jsx("div",{className:"flex items-center justify-between",children:h.jsxs("div",{className:"flex items-center gap-[12px]",children:[h.jsx(wf,{className:"!text-[24px] text-red-600"}),h.jsx("div",{className:"!my-0 !font-medium !text-[16px] !leading-[20px] !text-[#121212]",children:"Expenditure"})]})}),h.jsxs("div",{className:"grid grid-cols-4 !text-[12px] text-[#64748B] mt-4 mb-[8px]",children:[h.jsx("div",{children:"Opening"}),h.jsx("div",{children:"Expenditure"}),h.jsx("div",{children:"Payment"}),h.jsx("div",{children:"Outstanding"})]}),h.jsxs("div",{className:"grid grid-cols-4 !text-[12px] font-medium text-[#121212]",children:[h.jsx("div",{children:a(n.opening_balance,n?.currency_type)}),h.jsx("div",{children:a(n.expenditure,n?.currency_type)}),h.jsx("div",{children:a(n.payment,n?.currency_type)}),h.jsx("div",{children:a(n.outstanding,n?.currency_type)})]})]})})}var nse="tippy-content",rse="tippy-backdrop",ise="tippy-arrow",ose="tippy-svg-arrow",ls={passive:!0,capture:!0},nM=function(){return document.body};function ase(e,t){return{}.hasOwnProperty.call(e,t)}function Yx(e,t,n){if(Array.isArray(e)){var r=e[t];return r??(Array.isArray(n)?n[t]:n)}return e}function Ux(e,t){var n={}.toString.call(e);return n.indexOf("[object")===0&&n.indexOf(t+"]")>-1}function rM(e,t){return typeof e=="function"?e.apply(void 0,t):e}function iM(e,t){if(t===0)return e;var n;return function(r){clearTimeout(n),n=setTimeout(function(){e(r)},t)}}function sse(e,t){var n=Object.assign({},e);return t.forEach(function(r){delete n[r]}),n}function lse(e){return e.split(/\s+/).filter(Boolean)}function Tl(e){return[].concat(e)}function oM(e,t){e.indexOf(t)===-1&&e.push(t)}function cse(e){return e.filter(function(t,n){return e.indexOf(t)===n})}function use(e){return e.split("-")[0]}function Ih(e){return[].slice.call(e)}function aM(e){return Object.keys(e).reduce(function(t,n){return e[n]!==void 0&&(t[n]=e[n]),t},{})}function dse(){return document.createElement("div")}function Kx(e){return["Element","Fragment"].some(function(t){return Ux(e,t)})}function fse(e){return Ux(e,"NodeList")}function pse(e){return Ux(e,"MouseEvent")}function hse(e){return!!(e&&e._tippy&&e._tippy.reference===e)}function mse(e){return Kx(e)?[e]:fse(e)?Ih(e):Array.isArray(e)?e:Ih(document.querySelectorAll(e))}function qx(e,t){e.forEach(function(n){n&&(n.style.transitionDuration=t+"ms")})}function sM(e,t){e.forEach(function(n){n&&n.setAttribute("data-state",t)})}function gse(e){var t,n=Tl(e),r=n[0];return r!=null&&(t=r.ownerDocument)!=null&&t.body?r.ownerDocument:document}function vse(e,t){var n=t.clientX,r=t.clientY;return e.every(function(i){var o=i.popperRect,a=i.popperState,s=i.props,l=s.interactiveBorder,c=use(a.placement),u=a.modifiersData.offset;if(!u)return!0;var d=c==="bottom"?u.top.y:0,f=c==="top"?u.bottom.y:0,p=c==="right"?u.left.x:0,m=c==="left"?u.right.x:0,g=o.top-r+d>l,v=r-o.bottom-f>l,x=o.left-n+p>l,_=n-o.right-m>l;return g||v||x||_})}function Gx(e,t,n){var r=t+"EventListener";["transitionend","webkitTransitionEnd"].forEach(function(i){e[r](i,n)})}function lM(e,t){for(var n=t;n;){var r;if(e.contains(n))return!0;n=n.getRootNode==null||(r=n.getRootNode())==null?void 0:r.host}return!1}var zi={isTouch:!1},cM=0;function yse(){zi.isTouch||(zi.isTouch=!0,window.performance&&document.addEventListener("mousemove",uM))}function uM(){var e=performance.now();e-cM<20&&(zi.isTouch=!1,document.removeEventListener("mousemove",uM)),cM=e}function bse(){var e=document.activeElement;if(hse(e)){var t=e._tippy;e.blur&&!t.state.isVisible&&e.blur()}}function xse(){document.addEventListener("touchstart",yse,ls),window.addEventListener("blur",bse)}var wse=typeof window<"u"&&typeof document<"u",_se=wse?!!window.msCrypto:!1;function Nl(e){var t=e==="destroy"?"n already-":" ";return[e+"() was called on a"+t+"destroyed instance. This is a no-op but","indicates a potential memory leak."].join(" ")}function dM(e){var t=/[ \t]{2,}/g,n=/^[ \t]*/gm;return e.replace(t," ").replace(n,"").trim()}function Ese(e){return dM(`
|
|
262
|
+
`));const Qt={...r,isRtl:z,arrow:i,disableInteractive:re,placement:D,PopperComponentProp:T,touch:J.current},L=typeof A.popper=="function"?A.popper(Qt):A.popper,q=O.useMemo(()=>{let xe=[{name:"arrow",enabled:!!G,options:{element:G,padding:4}}];return I.popperOptions?.modifiers&&(xe=xe.concat(I.popperOptions.modifiers)),L?.popperOptions?.modifiers&&(xe=xe.concat(L.popperOptions.modifiers)),{...I.popperOptions,...L?.popperOptions,modifiers:xe}},[G,I.popperOptions,L?.popperOptions]),Y=Kae(Qt),ee=typeof A.transition=="function"?A.transition(Qt):A.transition,ne={slots:{popper:s.Popper,transition:s.Transition??N,tooltip:s.Tooltip,arrow:s.Arrow,...C},slotProps:{arrow:A.arrow??l.arrow,popper:{...I,...L??l.popper},tooltip:A.tooltip??l.tooltip,transition:{...M,...ee??l.transition}}},[Ee,Pe]=lr("popper",{elementType:qae,externalForwardedProps:ne,ownerState:Qt,className:ue(Y.popper,I?.className)}),[ln,ci]=lr("transition",{elementType:Pu,externalForwardedProps:ne,ownerState:Qt}),[Zt,ui]=lr("tooltip",{elementType:Gae,className:Y.tooltip,externalForwardedProps:ne,ownerState:Qt}),[fr,Cn]=lr("arrow",{elementType:Xae,className:Y.arrow,externalForwardedProps:ne,ownerState:Qt,ref:ie});return h.jsxs(O.Fragment,{children:[O.cloneElement(B,be),h.jsx(Ee,{as:T??Tx,placement:D,anchorEl:x?{getBoundingClientRect:()=>({top:Nu.y,left:Nu.x,right:Nu.x,bottom:Nu.y,width:0,height:0})}:W,popperRef:gn,open:W?F:!1,id:ge,transition:!0,...vn,...Pe,popperOptions:q,children:({TransitionProps:xe})=>h.jsx(ln,{timeout:V.transitions.duration.shorter,...xe,...ci,children:h.jsxs(Zt,{...ui,children:[j,i?h.jsx(fr,{...Cn}):null]})})})]})});process.env.NODE_ENV!=="production"&&(eM.propTypes={arrow:b.bool,children:Dl.isRequired,classes:b.object,className:b.string,components:b.shape({Arrow:b.elementType,Popper:b.elementType,Tooltip:b.elementType,Transition:b.elementType}),componentsProps:b.shape({arrow:b.object,popper:b.object,tooltip:b.object,transition:b.object}),describeChild:b.bool,disableFocusListener:b.bool,disableHoverListener:b.bool,disableInteractive:b.bool,disableTouchListener:b.bool,enterDelay:b.number,enterNextDelay:b.number,enterTouchDelay:b.number,followCursor:b.bool,id:b.string,leaveDelay:b.number,leaveTouchDelay:b.number,onClose:b.func,onOpen:b.func,open:b.bool,placement:b.oneOf(["auto-end","auto-start","auto","bottom-end","bottom-start","bottom","left-end","left-start","left","right-end","right-start","right","top-end","top-start","top"]),PopperComponent:b.elementType,PopperProps:b.object,slotProps:b.shape({arrow:b.oneOfType([b.func,b.object]),popper:b.oneOfType([b.func,b.object]),tooltip:b.oneOfType([b.func,b.object]),transition:b.oneOfType([b.func,b.object])}),slots:b.shape({arrow:b.elementType,popper:b.elementType,tooltip:b.elementType,transition:b.elementType}),sx:b.oneOfType([b.arrayOf(b.oneOfType([b.func,b.object,b.bool])),b.func,b.object]),title:b.node,TransitionComponent:b.elementType,TransitionProps:b.object});function Qae(e){return gt({attr:{viewBox:"0 0 24 24"},child:[{tag:"g",attr:{id:"Export"},child:[{tag:"g",attr:{},child:[{tag:"path",attr:{d:"M5.552,20.968a2.577,2.577,0,0,1-2.5-2.73c-.012-2.153,0-4.306,0-6.459a.5.5,0,0,1,1,0c0,2.2-.032,4.4,0,6.6.016,1.107.848,1.589,1.838,1.589H18.353A1.546,1.546,0,0,0,19.825,19a3.023,3.023,0,0,0,.1-1.061V11.779h0a.5.5,0,0,1,1,0c0,2.224.085,4.465,0,6.687a2.567,2.567,0,0,1-2.67,2.5Z"},child:[]},{tag:"path",attr:{d:"M12.337,3.176a.455.455,0,0,0-.311-.138c-.015,0-.028,0-.043-.006s-.027,0-.041.006a.457.457,0,0,0-.312.138L7.961,6.845a.5.5,0,0,0,.707.707l2.816-2.815V15.479a.5.5,0,0,0,1,0V4.737L15.3,7.552a.5.5,0,0,0,.707-.707Z"},child:[]}]}]}]})(e)}function Zae(e){return gt({attr:{viewBox:"0 0 24 24"},child:[{tag:"g",attr:{id:"Warning"},child:[{tag:"g",attr:{},child:[{tag:"g",attr:{},child:[{tag:"path",attr:{d:"M12.5,8.752a.5.5,0,0,0-1,0h0v6a.5.5,0,0,0,1,0Z"},child:[]},{tag:"circle",attr:{cx:"11.999",cy:"16.736",r:"0.5"},child:[]}]},{tag:"path",attr:{d:"M18.642,20.934H5.385A2.5,2.5,0,0,1,3.163,17.29L9.792,4.421a2.5,2.5,0,0,1,4.444,0L20.865,17.29a2.5,2.5,0,0,1-2.223,3.644ZM12.014,4.065a1.478,1.478,0,0,0-1.334.814L4.052,17.748a1.5,1.5,0,0,0,1.333,2.186H18.642a1.5,1.5,0,0,0,1.334-2.186L13.348,4.879A1.478,1.478,0,0,0,12.014,4.065Z"},child:[]}]}]}]})(e)}Pd(Hx)(()=>({width:"fit-content",maxWidth:"100px",height:"28px",padding:"0 6px",display:"flex",fontSize:"12px",alignItems:"center","& .MuiSelect-select":{padding:0},"& .MuiOutlinedInput-notchedOutline":{borderColor:"#C6C6C6",transition:"all 0.2s ease"},"&:hover .MuiOutlinedInput-notchedOutline":{borderColor:"#B084CC"},"&.Mui-focused .MuiOutlinedInput-notchedOutline":{borderColor:"#884EA7 !important",boxShadow:"0 0 0 3px rgba(136, 78, 167, 0.2)"}}));function Al({widgetId:e,options:t=[],defaultValue:n=["all"],onFilterChange:r=()=>{},onExport:i=()=>{}}){const o=JSON.parse(sessionStorage.getItem("community_id"))||[],[a,s]=k.useState(o),[l,c]=k.useState("");t.filter(d=>d.community_name.toLowerCase().includes(l.toLowerCase()));const u=()=>{e2("widget_id",e),e2("export",!0),i()};return h.jsx("div",{className:"flex items-center gap-[8px]",children:h.jsx(eM,{title:"Export CSV for this widget",children:h.jsx("button",{onClick:u,className:"px-[12px] py-[8px] bg-[#FBF5FF] rounded cursor-pointer",children:h.jsx(Qae,{className:"stroke-[#884EA7] stroke-[1.4]"})})})})}function Jae({isStatic:e,data:t}){const n=Number(t?.thisMonthMoveIns??t?.lastMonthMoveIns??0),r=Number(t?.thisMonthMoveOuts??t?.lastMonthMoveOuts??0),i=Number(t?.moveInPercentChange??t?.moveInChange??0),o=Number(t?.moveOutPercentChange??t?.moveOutChange??0),a=["#8B5CF6","#EBE4F9"],s=[{name:"Move-ins",value:n,color:a[0]},{name:"Move-outs",value:r,color:a[1]}];function l(c,u){return((Number(c)+Number(u))/2).toFixed(2)+"%"}return h.jsx(Ia,{title:"Community",period:"This Month",icon:h.jsx(aS,{className:"!text-[24px] text-[#329DFF]"}),className:`${e&&"max-h-[184px]"} h-[184px] mb-4 break-inside-avoid gap-[20px]`,actionButtons:h.jsx(Al,{widgetId:t?.widget_id,options:t?.communities}),children:h.jsxs("div",{className:"flex",children:[h.jsxs("div",{className:"w-[50%] flex flex-col gap-[28px]",children:[h.jsxs("div",{className:"flex flex-col gap-[8px]",children:[h.jsx("div",{className:"!m-0 !text-[12px] !leading-[16px] !text-[#64748B]",children:"Move-in/Out Count"}),h.jsx("div",{className:"!m-0 !text-[28px] !leading-[32px] !font-medium !text-[#8B5CF6]",children:n+r})]}),h.jsxs("div",{className:"!m-0 !text-[10px] !leading-[14px] !text-[#64748B] flex items-center gap-[4px]",children:[h.jsx(Tc,{value:l(i,o)}),h.jsx("div",{className:"whitespace-nowrap",children:"Compared to last month"})]})]}),h.jsx("div",{className:"w-[50%] h-[111px] flex justify-end",children:h.jsx(Ot,{width:"75%",height:"100%",children:h.jsxs($i,{children:[h.jsxs(ai,{data:s,innerRadius:36,outerRadius:52,paddingAngle:2,dataKey:"value",children:[h.jsx(In,{fill:a[0]}),h.jsx(In,{fill:a[1]})]}),h.jsx(St,{content:Nc({data:s})})]})})})]})})}function tM({isStatic:e,data:t,communities:n}){const r=["#8B5CF6","#22C55E","#3B82F6","#F59E0B"],i=[{name:"Notice",value:Number(t?.total_notices||0),fill:r[0]},{name:"Post",value:Number(t?.total_topics||t?.total_forum_topics||0),fill:r[1]},{name:"Poll",value:Number(t?.total_polls||t?.total_poll_detail||0),fill:r[2]},{name:"Survey",value:Number(t?.total_surveys||t?.total_survey_detail||0),fill:r[3]}],o=t?.widget==="commercial";return h.jsx(Ia,{title:"Engagement",period:"This Month",icon:h.jsx(sS,{className:"!text-[20px] text-[#DBB467]"}),className:`${e&&"max-h-[303px]"} ${o?"h-[324px]":"h-[303px]"} `,childrenClassName:`${o?"mt-[52px]":"mt-0"}`,actionButtons:!o&&h.jsx(Al,{widgetId:t?.widget_id,options:t?.communities}),children:h.jsx("div",{className:`w-full ${o?"h-[220px]":"h-[260px]"}`,children:h.jsx(Ot,{width:"100%",height:"100%",children:h.jsxs(ko,{data:i,layout:"vertical",margin:{top:4,right:8,left:0,bottom:0},children:[h.jsx(sr,{stroke:"#e5e7eb",strokeDasharray:"3 3",horizontal:!1}),h.jsx(Rn,{type:"category",dataKey:"name",width:40,axisLine:!1,tickLine:!1,tick:{fontSize:10,lineHeight:14,fill:"#121212",fontWeight:400}}),h.jsx(Gn,{type:"number",allowDecimals:!1,axisLine:!1,tickLine:!1,tick:{fontSize:10,lineHeight:14,fill:"#64748B",fontWeight:400}}),h.jsx(St,{cursor:{fill:"transparent"},wrapperStyle:{outline:"none"},position:{x:160,y:0},allowEscapeViewBox:{x:!0,y:!0},content:a=>a.active?h.jsx(Ut,{...a,data:i,children:h.jsx(Rr,{...a})}):null}),h.jsx(Gt,{dataKey:"value",barSize:40,isAnimationActive:!1,children:i.map((a,s)=>h.jsx(In,{fill:r[s],dataKey:"value"},a.name))})]})})})})}function ese({isStatic:e,data:t}){const n=Number(t?.totalBookings||0),r=Number(t?.averageUtilizationPercentage||0),i=k.useMemo(()=>{if(!t?.graph)return[];const{labels:s=[],bookings:l=[],utilization:c=[]}=t.graph;return s.map((u,d)=>({time:u,bookings:l[d]||0,utilization:c[d]||0}))},[t]),o=s=>["12 AM","6 AM","12 PM","6 PM","11 PM"].includes(s)?s:"",a=i.length?i:Array.from({length:24},(s,l)=>({time:`${l%12||12} ${l>=12?"PM":"AM"}`,bookings:0,utilization:0}));return h.jsxs(Ia,{title:"Facilities",period:"Today",icon:h.jsx(Ag,{className:"!text-[24px] text-[#8B5CF6]"}),className:`${e&&"max-h-[305px]"} h-[305px] mb-4 break-inside-avoid`,actionButtons:h.jsx(Al,{widgetId:t?.widget_id,options:t?.communities}),children:[h.jsxs("div",{className:"grid grid-cols-2 gap-[24px] mt-[16px] mb-[16px]",children:[h.jsxs("div",{children:[h.jsx("div",{className:"!text-[12px] text-[#64748B]",children:"Bookings"}),h.jsx("div",{className:"!text-[24px] font-medium text-[#8B5CF6]",children:n})]}),h.jsxs("div",{children:[h.jsx("div",{className:"!text-[12px] text-[#64748B]",children:"Utilisation Rate"}),h.jsxs("div",{className:"!text-[24px] font-medium text-[#329DFF]",children:[r.toFixed(2),"%"]})]})]}),h.jsx("div",{className:"w-full h-[170px]",children:h.jsx(Ot,{width:"100%",height:"100%",children:h.jsxs(Ox,{data:a,margin:{top:5,right:-30,left:-35,bottom:0},children:[h.jsx(sr,{strokeDasharray:"3 3",stroke:"#EBEBEB"}),h.jsx(Gn,{dataKey:"time",interval:0,tickFormatter:o,tick:{fontSize:10,fill:"#121212",fontWeight:400},axisLine:!1,tickLine:!1,minTickGap:0}),h.jsx(Rn,{yAxisId:"left",tick:{fontSize:10,fill:"#64748B"},axisLine:!1,tickLine:!1}),h.jsx(Rn,{yAxisId:"right",orientation:"right",domain:[0,100],ticks:[0,20,40,60,80,100],tickFormatter:s=>`${s}%`,tick:{fontSize:10,fill:"#64748B"},axisLine:!1,tickLine:!1}),h.jsx(St,{cursor:{stroke:"transparent"},wrapperStyle:{outline:"none"},allowEscapeViewBox:{x:!0,y:!0},content:Nc({data:a})}),h.jsx(da,{yAxisId:"left",type:"monotone",dataKey:"bookings",name:"Bookings",stroke:"#8B5CF6",strokeWidth:2,dot:!1,isAnimationActive:!1}),h.jsx(da,{yAxisId:"right",type:"monotone",dataKey:"utilization",name:"Utilization Rate",stroke:"#329DFF",strokeWidth:2,dot:!1,strokeDasharray:"2 4",isAnimationActive:!1})]})})})]})}function tse({data:e}){const t=e?.incomeSummary||{},n=e?.expenditureSummary||{},r=["AED","USD","EUR"],i=["Rs","INR","₹"];function o(s){if(s==null||isNaN(s))return"0";const l=Number(s),c=Math.abs(l),u=l<0?"-":"";return c>=1e9?u+(c/1e9).toFixed(c%1e9===0?0:2)+"B":c>=1e6?u+(c/1e6).toFixed(c%1e6===0?0:2)+"M":c>=1e3?u+(c/1e3).toFixed(c%1e3===0?0:2)+"K":u+c.toFixed(c%1===0?0:2)}function a(s,l){return l?i.includes(l)?`${l} ${o(s)}`:r.includes(l)?`${o(s)} ${l}`:`${o(s)} ${l}`:o(s)}return h.jsx(Ia,{title:"Income",period:"This Month",icon:h.jsx(wf,{className:"!text-[24px] text-green-600"}),className:"!gap-[16px] break-inside-avoid h-[232px] overflow-hidden",actionButtons:h.jsx(Al,{widgetId:e?.widget_id,options:e?.communities}),children:h.jsxs("div",{children:[h.jsxs("div",{className:"grid grid-cols-4 !text-[12px] text-[#64748B] mb-[8px]",children:[h.jsx("div",{children:"Opening"}),h.jsx("div",{children:"Income"}),h.jsx("div",{children:"Collection"}),h.jsx("div",{children:"Closing"})]}),h.jsxs("div",{className:"grid grid-cols-4 !text-[12px] font-medium text-[#121212] mb-[8px]",children:[h.jsx("div",{children:a(t.opening_balance,t?.currency_type)}),h.jsx("div",{children:a(t.income,t?.currency_type)}),h.jsx("div",{children:a(t.collection,t?.currency_type)}),h.jsx("div",{children:a(t.closing_balance,t?.currency_type)})]}),h.jsx("hr",{className:"my-4 border-t border-dashed border-gray-300"}),h.jsx("div",{className:"flex items-center justify-between",children:h.jsxs("div",{className:"flex items-center gap-[12px]",children:[h.jsx(wf,{className:"!text-[24px] text-red-600"}),h.jsx("div",{className:"!my-0 !font-medium !text-[16px] !leading-[20px] !text-[#121212]",children:"Expenditure"})]})}),h.jsxs("div",{className:"grid grid-cols-4 !text-[12px] text-[#64748B] mt-4 mb-[8px]",children:[h.jsx("div",{children:"Opening"}),h.jsx("div",{children:"Expenditure"}),h.jsx("div",{children:"Payment"}),h.jsx("div",{children:"Outstanding"})]}),h.jsxs("div",{className:"grid grid-cols-4 !text-[12px] font-medium text-[#121212]",children:[h.jsx("div",{children:a(n.opening_balance,n?.currency_type)}),h.jsx("div",{children:a(n.expenditure,n?.currency_type)}),h.jsx("div",{children:a(n.payment,n?.currency_type)}),h.jsx("div",{children:a(n.outstanding,n?.currency_type)})]})]})})}var nse="tippy-content",rse="tippy-backdrop",ise="tippy-arrow",ose="tippy-svg-arrow",ls={passive:!0,capture:!0},nM=function(){return document.body};function ase(e,t){return{}.hasOwnProperty.call(e,t)}function Yx(e,t,n){if(Array.isArray(e)){var r=e[t];return r??(Array.isArray(n)?n[t]:n)}return e}function Ux(e,t){var n={}.toString.call(e);return n.indexOf("[object")===0&&n.indexOf(t+"]")>-1}function rM(e,t){return typeof e=="function"?e.apply(void 0,t):e}function iM(e,t){if(t===0)return e;var n;return function(r){clearTimeout(n),n=setTimeout(function(){e(r)},t)}}function sse(e,t){var n=Object.assign({},e);return t.forEach(function(r){delete n[r]}),n}function lse(e){return e.split(/\s+/).filter(Boolean)}function Tl(e){return[].concat(e)}function oM(e,t){e.indexOf(t)===-1&&e.push(t)}function cse(e){return e.filter(function(t,n){return e.indexOf(t)===n})}function use(e){return e.split("-")[0]}function Ih(e){return[].slice.call(e)}function aM(e){return Object.keys(e).reduce(function(t,n){return e[n]!==void 0&&(t[n]=e[n]),t},{})}function dse(){return document.createElement("div")}function Kx(e){return["Element","Fragment"].some(function(t){return Ux(e,t)})}function fse(e){return Ux(e,"NodeList")}function pse(e){return Ux(e,"MouseEvent")}function hse(e){return!!(e&&e._tippy&&e._tippy.reference===e)}function mse(e){return Kx(e)?[e]:fse(e)?Ih(e):Array.isArray(e)?e:Ih(document.querySelectorAll(e))}function qx(e,t){e.forEach(function(n){n&&(n.style.transitionDuration=t+"ms")})}function sM(e,t){e.forEach(function(n){n&&n.setAttribute("data-state",t)})}function gse(e){var t,n=Tl(e),r=n[0];return r!=null&&(t=r.ownerDocument)!=null&&t.body?r.ownerDocument:document}function vse(e,t){var n=t.clientX,r=t.clientY;return e.every(function(i){var o=i.popperRect,a=i.popperState,s=i.props,l=s.interactiveBorder,c=use(a.placement),u=a.modifiersData.offset;if(!u)return!0;var d=c==="bottom"?u.top.y:0,f=c==="top"?u.bottom.y:0,p=c==="right"?u.left.x:0,m=c==="left"?u.right.x:0,g=o.top-r+d>l,v=r-o.bottom-f>l,x=o.left-n+p>l,_=n-o.right-m>l;return g||v||x||_})}function Gx(e,t,n){var r=t+"EventListener";["transitionend","webkitTransitionEnd"].forEach(function(i){e[r](i,n)})}function lM(e,t){for(var n=t;n;){var r;if(e.contains(n))return!0;n=n.getRootNode==null||(r=n.getRootNode())==null?void 0:r.host}return!1}var zi={isTouch:!1},cM=0;function yse(){zi.isTouch||(zi.isTouch=!0,window.performance&&document.addEventListener("mousemove",uM))}function uM(){var e=performance.now();e-cM<20&&(zi.isTouch=!1,document.removeEventListener("mousemove",uM)),cM=e}function bse(){var e=document.activeElement;if(hse(e)){var t=e._tippy;e.blur&&!t.state.isVisible&&e.blur()}}function xse(){document.addEventListener("touchstart",yse,ls),window.addEventListener("blur",bse)}var wse=typeof window<"u"&&typeof document<"u",_se=wse?!!window.msCrypto:!1;function Nl(e){var t=e==="destroy"?"n already-":" ";return[e+"() was called on a"+t+"destroyed instance. This is a no-op but","indicates a potential memory leak."].join(" ")}function dM(e){var t=/[ \t]{2,}/g,n=/^[ \t]*/gm;return e.replace(t," ").replace(n,"").trim()}function Ese(e){return dM(`
|
|
263
263
|
%ctippy.js
|
|
264
264
|
|
|
265
265
|
%c`+dM(e)+`
|
|
@@ -268,7 +268,7 @@ Take a look at the reducer(s) handling this action type: ${p.type}.
|
|
|
268
268
|
`)}function fM(e){return[Ese(e),"color: #00C584; font-size: 1.3em; font-weight: bold;","line-height: 1.5","color: #a6a095;"]}var ju;process.env.NODE_ENV!=="production"&&Sse();function Sse(){ju=new Set}function Ao(e,t){if(e&&!ju.has(t)){var n;ju.add(t),(n=console).warn.apply(n,fM(t))}}function Xx(e,t){if(e&&!ju.has(t)){var n;ju.add(t),(n=console).error.apply(n,fM(t))}}function Ose(e){var t=!e,n=Object.prototype.toString.call(e)==="[object Object]"&&!e.addEventListener;Xx(t,["tippy() was passed","`"+String(e)+"`","as its targets (first) argument. Valid types are: String, Element,","Element[], or NodeList."].join(" ")),Xx(n,["tippy() was passed a plain object which is not supported as an argument","for virtual positioning. Use props.getReferenceClientRect instead."].join(" "))}var pM={animateFill:!1,followCursor:!1,inlinePositioning:!1,sticky:!1},Cse={allowHTML:!1,animation:"fade",arrow:!0,content:"",inertia:!1,maxWidth:350,role:"tooltip",theme:"",zIndex:9999},Pr=Object.assign({appendTo:nM,aria:{content:"auto",expanded:"auto"},delay:0,duration:[300,250],getReferenceClientRect:null,hideOnClick:!0,ignoreAttributes:!1,interactive:!1,interactiveBorder:2,interactiveDebounce:0,moveTransition:"",offset:[0,10],onAfterUpdate:function(){},onBeforeUpdate:function(){},onCreate:function(){},onDestroy:function(){},onHidden:function(){},onHide:function(){},onMount:function(){},onShow:function(){},onShown:function(){},onTrigger:function(){},onUntrigger:function(){},onClickOutside:function(){},placement:"top",plugins:[],popperOptions:{},render:null,showOnCreate:!1,touch:!0,trigger:"mouseenter focus",triggerTarget:null},pM,Cse),kse=Object.keys(Pr),Pse=function(t){process.env.NODE_ENV!=="production"&&gM(t,[]);var n=Object.keys(t);n.forEach(function(r){Pr[r]=t[r]})};function hM(e){var t=e.plugins||[],n=t.reduce(function(r,i){var o=i.name,a=i.defaultValue;if(o){var s;r[o]=e[o]!==void 0?e[o]:(s=Pr[o])!=null?s:a}return r},{});return Object.assign({},e,n)}function Dse(e,t){var n=t?Object.keys(hM(Object.assign({},Pr,{plugins:t}))):kse,r=n.reduce(function(i,o){var a=(e.getAttribute("data-tippy-"+o)||"").trim();if(!a)return i;if(o==="content")i[o]=a;else try{i[o]=JSON.parse(a)}catch{i[o]=a}return i},{});return r}function mM(e,t){var n=Object.assign({},t,{content:rM(t.content,[e])},t.ignoreAttributes?{}:Dse(e,t.plugins));return n.aria=Object.assign({},Pr.aria,n.aria),n.aria={expanded:n.aria.expanded==="auto"?t.interactive:n.aria.expanded,content:n.aria.content==="auto"?t.interactive?null:"describedby":n.aria.content},n}function gM(e,t){e===void 0&&(e={}),t===void 0&&(t=[]);var n=Object.keys(e);n.forEach(function(r){var i=sse(Pr,Object.keys(pM)),o=!ase(i,r);o&&(o=t.filter(function(a){return a.name===r}).length===0),Ao(o,["`"+r+"`","is not a valid prop. You may have spelled it incorrectly, or if it's","a plugin, forgot to pass it in an array as props.plugins.",`
|
|
269
269
|
|
|
270
270
|
`,`All props: https://atomiks.github.io/tippyjs/v6/all-props/
|
|
271
|
-
`,"Plugins: https://atomiks.github.io/tippyjs/v6/plugins/"].join(" "))})}function vM(e){var t=e.firstElementChild,n=Ih(t.children);return{box:t,content:n.find(function(r){return r.classList.contains(nse)}),arrow:n.find(function(r){return r.classList.contains(ise)||r.classList.contains(ose)}),backdrop:n.find(function(r){return r.classList.contains(rse)})}}var Ase=1,Fh=[],Qx=[];function Tse(e,t){var n=mM(e,Object.assign({},Pr,hM(aM(t)))),r,i,o,a=!1,s=!1,l=!1,c=!1,u,d,f,p=[],m=iM(oe,n.interactiveDebounce),g,v=Ase++,x=null,_=cse(n.plugins),w={isEnabled:!0,isVisible:!1,isDestroyed:!1,isMounted:!1,isShown:!1},y={id:v,reference:e,popper:dse(),popperInstance:x,props:n,state:w,plugins:_,clearDelayTimeouts:sn,setProps:gn,setContent:Wn,show:Xt,hide:zn,hideWithInteractivity:be,enable:ht,disable:mn,unmount:vn,destroy:Qt};if(!n.render)return process.env.NODE_ENV!=="production"&&Xx(!0,"render() function has not been supplied."),y;var E=n.render(y),S=E.popper,P=E.onUpdate;S.setAttribute("data-tippy-root",""),S.id="tippy-"+y.id,y.popper=S,e._tippy=y,S._tippy=y;var D=_.map(function(L){return L.fn(y)}),T=e.hasAttribute("aria-expanded");return Z(),W(),B(),V("onCreate",[y]),n.showOnCreate&&Pt(),S.addEventListener("mouseenter",function(){y.props.interactive&&y.state.isVisible&&y.clearDelayTimeouts()}),S.addEventListener("mouseleave",function(){y.props.interactive&&y.props.trigger.indexOf("mouseenter")>=0&&N().addEventListener("mousemove",m)}),y;function I(){var L=y.props.touch;return Array.isArray(L)?L:[L,0]}function A(){return I()[0]==="hold"}function C(){var L;return!!((L=y.props.render)!=null&&L.$$tippy)}function j(){return g||e}function N(){var L=j().parentNode;return L?gse(L):document}function M(){return vM(S)}function R(L){return y.state.isMounted&&!y.state.isVisible||zi.isTouch||u&&u.type==="focus"?0:Yx(y.props.delay,L?0:1,Pr.delay)}function B(L){L===void 0&&(L=!1),S.style.pointerEvents=y.props.interactive&&!L?"":"none",S.style.zIndex=""+y.props.zIndex}function V(L,q,Y){if(Y===void 0&&(Y=!0),D.forEach(function(ne){ne[L]&&ne[L].apply(ne,q)}),Y){var ee;(ee=y.props)[L].apply(ee,q)}}function z(){var L=y.props.aria;if(L.content){var q="aria-"+L.content,Y=S.id,ee=Tl(y.props.triggerTarget||e);ee.forEach(function(ne){var Ee=ne.getAttribute(q);if(y.state.isVisible)ne.setAttribute(q,Ee?Ee+" "+Y:Y);else{var Pe=Ee&&Ee.replace(Y,"").trim();Pe?ne.setAttribute(q,Pe):ne.removeAttribute(q)}})}}function W(){if(!(T||!y.props.aria.expanded)){var L=Tl(y.props.triggerTarget||e);L.forEach(function(q){y.props.interactive?q.setAttribute("aria-expanded",y.state.isVisible&&q===j()?"true":"false"):q.removeAttribute("aria-expanded")})}}function Q(){N().removeEventListener("mousemove",m),Fh=Fh.filter(function(L){return L!==m})}function
|
|
271
|
+
`,"Plugins: https://atomiks.github.io/tippyjs/v6/plugins/"].join(" "))})}function vM(e){var t=e.firstElementChild,n=Ih(t.children);return{box:t,content:n.find(function(r){return r.classList.contains(nse)}),arrow:n.find(function(r){return r.classList.contains(ise)||r.classList.contains(ose)}),backdrop:n.find(function(r){return r.classList.contains(rse)})}}var Ase=1,Fh=[],Qx=[];function Tse(e,t){var n=mM(e,Object.assign({},Pr,hM(aM(t)))),r,i,o,a=!1,s=!1,l=!1,c=!1,u,d,f,p=[],m=iM(oe,n.interactiveDebounce),g,v=Ase++,x=null,_=cse(n.plugins),w={isEnabled:!0,isVisible:!1,isDestroyed:!1,isMounted:!1,isShown:!1},y={id:v,reference:e,popper:dse(),popperInstance:x,props:n,state:w,plugins:_,clearDelayTimeouts:sn,setProps:gn,setContent:Wn,show:Xt,hide:zn,hideWithInteractivity:be,enable:ht,disable:mn,unmount:vn,destroy:Qt};if(!n.render)return process.env.NODE_ENV!=="production"&&Xx(!0,"render() function has not been supplied."),y;var E=n.render(y),S=E.popper,P=E.onUpdate;S.setAttribute("data-tippy-root",""),S.id="tippy-"+y.id,y.popper=S,e._tippy=y,S._tippy=y;var D=_.map(function(L){return L.fn(y)}),T=e.hasAttribute("aria-expanded");return Z(),W(),B(),V("onCreate",[y]),n.showOnCreate&&Pt(),S.addEventListener("mouseenter",function(){y.props.interactive&&y.state.isVisible&&y.clearDelayTimeouts()}),S.addEventListener("mouseleave",function(){y.props.interactive&&y.props.trigger.indexOf("mouseenter")>=0&&N().addEventListener("mousemove",m)}),y;function I(){var L=y.props.touch;return Array.isArray(L)?L:[L,0]}function A(){return I()[0]==="hold"}function C(){var L;return!!((L=y.props.render)!=null&&L.$$tippy)}function j(){return g||e}function N(){var L=j().parentNode;return L?gse(L):document}function M(){return vM(S)}function R(L){return y.state.isMounted&&!y.state.isVisible||zi.isTouch||u&&u.type==="focus"?0:Yx(y.props.delay,L?0:1,Pr.delay)}function B(L){L===void 0&&(L=!1),S.style.pointerEvents=y.props.interactive&&!L?"":"none",S.style.zIndex=""+y.props.zIndex}function V(L,q,Y){if(Y===void 0&&(Y=!0),D.forEach(function(ne){ne[L]&&ne[L].apply(ne,q)}),Y){var ee;(ee=y.props)[L].apply(ee,q)}}function z(){var L=y.props.aria;if(L.content){var q="aria-"+L.content,Y=S.id,ee=Tl(y.props.triggerTarget||e);ee.forEach(function(ne){var Ee=ne.getAttribute(q);if(y.state.isVisible)ne.setAttribute(q,Ee?Ee+" "+Y:Y);else{var Pe=Ee&&Ee.replace(Y,"").trim();Pe?ne.setAttribute(q,Pe):ne.removeAttribute(q)}})}}function W(){if(!(T||!y.props.aria.expanded)){var L=Tl(y.props.triggerTarget||e);L.forEach(function(q){y.props.interactive?q.setAttribute("aria-expanded",y.state.isVisible&&q===j()?"true":"false"):q.removeAttribute("aria-expanded")})}}function Q(){N().removeEventListener("mousemove",m),Fh=Fh.filter(function(L){return L!==m})}function G(L){if(!(zi.isTouch&&(l||L.type==="mousedown"))){var q=L.composedPath&&L.composedPath()[0]||L.target;if(!(y.props.interactive&&lM(S,q))){if(Tl(y.props.triggerTarget||e).some(function(Y){return lM(Y,q)})){if(zi.isTouch||y.state.isVisible&&y.props.trigger.indexOf("click")>=0)return}else V("onClickOutside",[y,L]);y.props.hideOnClick===!0&&(y.clearDelayTimeouts(),y.hide(),s=!0,setTimeout(function(){s=!1}),y.state.isMounted||se())}}}function ie(){l=!0}function J(){l=!1}function re(){var L=N();L.addEventListener("mousedown",G,!0),L.addEventListener("touchend",G,ls),L.addEventListener("touchstart",J,ls),L.addEventListener("touchmove",ie,ls)}function se(){var L=N();L.removeEventListener("mousedown",G,!0),L.removeEventListener("touchend",G,ls),L.removeEventListener("touchstart",J,ls),L.removeEventListener("touchmove",ie,ls)}function ce(L,q){K(L,function(){!y.state.isVisible&&S.parentNode&&S.parentNode.contains(S)&&q()})}function de(L,q){K(L,q)}function K(L,q){var Y=M().box;function ee(ne){ne.target===Y&&(Gx(Y,"remove",ee),q())}if(L===0)return q();Gx(Y,"remove",d),Gx(Y,"add",ee),d=ee}function U(L,q,Y){Y===void 0&&(Y=!1);var ee=Tl(y.props.triggerTarget||e);ee.forEach(function(ne){ne.addEventListener(L,q,Y),p.push({node:ne,eventType:L,handler:q,options:Y})})}function Z(){A()&&(U("touchstart",ge,{passive:!0}),U("touchend",ye,{passive:!0})),lse(y.props.trigger).forEach(function(L){if(L!=="manual")switch(U(L,ge),L){case"mouseenter":U("mouseleave",ye);break;case"focus":U(_se?"focusout":"blur",_e);break;case"focusin":U("focusout",_e);break}})}function F(){p.forEach(function(L){var q=L.node,Y=L.eventType,ee=L.handler,ne=L.options;q.removeEventListener(Y,ee,ne)}),p=[]}function ge(L){var q,Y=!1;if(!(!y.state.isEnabled||Ie(L)||s)){var ee=((q=u)==null?void 0:q.type)==="focus";u=L,g=L.currentTarget,W(),!y.state.isVisible&&pse(L)&&Fh.forEach(function(ne){return ne(L)}),L.type==="click"&&(y.props.trigger.indexOf("mouseenter")<0||a)&&y.props.hideOnClick!==!1&&y.state.isVisible?Y=!0:Pt(L),L.type==="click"&&(a=!Y),Y&&!ee&&Dt(L)}}function oe(L){var q=L.target,Y=j().contains(q)||S.contains(q);if(!(L.type==="mousemove"&&Y)){var ee=Fe().concat(S).map(function(ne){var Ee,Pe=ne._tippy,ln=(Ee=Pe.popperInstance)==null?void 0:Ee.state;return ln?{popperRect:ne.getBoundingClientRect(),popperState:ln,props:n}:null}).filter(Boolean);vse(ee,L)&&(Q(),Dt(L))}}function ye(L){var q=Ie(L)||y.props.trigger.indexOf("click")>=0&&a;if(!q){if(y.props.interactive){y.hideWithInteractivity(L);return}Dt(L)}}function _e(L){y.props.trigger.indexOf("focusin")<0&&L.target!==j()||y.props.interactive&&L.relatedTarget&&S.contains(L.relatedTarget)||Dt(L)}function Ie(L){return zi.isTouch?A()!==L.type.indexOf("touch")>=0:!1}function tt(){pt();var L=y.props,q=L.popperOptions,Y=L.placement,ee=L.offset,ne=L.getReferenceClientRect,Ee=L.moveTransition,Pe=C()?vM(S).arrow:null,ln=ne?{getBoundingClientRect:ne,contextElement:ne.contextElement||j()}:e,ci={name:"$$tippy",enabled:!0,phase:"beforeWrite",requires:["computeStyles"],fn:function(fr){var Cn=fr.state;if(C()){var xe=M(),cn=xe.box;["placement","reference-hidden","escaped"].forEach(function(di){di==="placement"?cn.setAttribute("data-placement",Cn.placement):Cn.attributes.popper["data-popper-"+di]?cn.setAttribute("data-"+di,""):cn.removeAttribute("data-"+di)}),Cn.attributes.popper={}}}},Zt=[{name:"offset",options:{offset:ee}},{name:"preventOverflow",options:{padding:{top:2,bottom:2,left:5,right:5}}},{name:"flip",options:{padding:5}},{name:"computeStyles",options:{adaptive:!Ee}},ci];C()&&Pe&&Zt.push({name:"arrow",options:{element:Pe,padding:3}}),Zt.push.apply(Zt,q?.modifiers||[]),y.popperInstance=Vg(ln,S,Object.assign({},q,{placement:Y,onFirstUpdate:f,modifiers:Zt}))}function pt(){y.popperInstance&&(y.popperInstance.destroy(),y.popperInstance=null)}function ct(){var L=y.props.appendTo,q,Y=j();y.props.interactive&&L===nM||L==="parent"?q=Y.parentNode:q=rM(L,[Y]),q.contains(S)||q.appendChild(S),y.state.isMounted=!0,tt(),process.env.NODE_ENV!=="production"&&Ao(y.props.interactive&&L===Pr.appendTo&&Y.nextElementSibling!==S,["Interactive tippy element may not be accessible via keyboard","navigation because it is not directly after the reference element","in the DOM source order.",`
|
|
272
272
|
|
|
273
273
|
`,"Using a wrapper <div> or <span> tag around the reference element","solves this by creating a new parentNode context.",`
|
|
274
274
|
|
|
@@ -294,9 +294,9 @@ Take a look at the reducer(s) handling this action type: ${p.type}.
|
|
|
294
294
|
* https://www.chartjs.org
|
|
295
295
|
* (c) 2025 Chart.js Contributors
|
|
296
296
|
* Released under the MIT License
|
|
297
|
-
*/class Rce{constructor(){this._request=null,this._charts=new Map,this._running=!1,this._lastDate=void 0}_notify(t,n,r,i){const o=n.listeners[i],a=n.duration;o.forEach(s=>s({chart:t,initial:n.initial,numSteps:a,currentStep:Math.min(r-n.start,a)}))}_refresh(){this._request||(this._running=!0,this._request=VM.call(window,()=>{this._update(),this._request=null,this._running&&this._refresh()}))}_update(t=Date.now()){let n=0;this._charts.forEach((r,i)=>{if(!r.running||!r.items.length)return;const o=r.items;let a=o.length-1,s=!1,l;for(;a>=0;--a)l=o[a],l._active?(l._total>r.duration&&(r.duration=l._total),l.tick(t),s=!0):(o[a]=o[o.length-1],o.pop());s&&(i.draw(),this._notify(i,r,t,"progress")),o.length||(r.running=!1,this._notify(i,r,t,"complete"),r.initial=!1),n+=o.length}),this._lastDate=t,n===0&&(this._running=!1)}_getAnims(t){const n=this._charts;let r=n.get(t);return r||(r={running:!1,initial:!0,items:[],listeners:{complete:[],progress:[]}},n.set(t,r)),r}listen(t,n,r){this._getAnims(t).listeners[n].push(r)}add(t,n){!n||!n.length||this._getAnims(t).items.push(...n)}has(t){return this._getAnims(t).items.length>0}start(t){const n=this._charts.get(t);n&&(n.running=!0,n.start=Date.now(),n.duration=n.items.reduce((r,i)=>Math.max(r,i._duration),0),this._refresh())}running(t){if(!this._running)return!1;const n=this._charts.get(t);return!(!n||!n.running||!n.items.length)}stop(t){const n=this._charts.get(t);if(!n||!n.items.length)return;const r=n.items;let i=r.length-1;for(;i>=0;--i)r[i].cancel();n.items=[],this._notify(t,n,Date.now(),"complete")}remove(t){return this._charts.delete(t)}}var Mo=new Rce;const gI="transparent",$ce={boolean(e,t,n){return n>.5?t:e},color(e,t,n){const r=qM(e||gI),i=r.valid&&qM(t||gI);return i&&i.valid?i.mix(r,n).hexString():t},number(e,t,n){return e+(t-e)*n}};class Bce{constructor(t,n,r,i){const o=n[r];i=Uh([t.to,i,o,t.from]);const a=Uh([t.from,o,i]);this._active=!0,this._fn=t.fn||$ce[t.type||typeof a],this._easing=Hu[t.easing]||Hu.linear,this._start=Math.floor(Date.now()+(t.delay||0)),this._duration=this._total=Math.floor(t.duration),this._loop=!!t.loop,this._target=n,this._prop=r,this._from=a,this._to=i,this._promises=void 0}active(){return this._active}update(t,n,r){if(this._active){this._notify(!1);const i=this._target[this._prop],o=r-this._start,a=this._duration-o;this._start=r,this._duration=Math.floor(Math.max(a,t.duration)),this._total+=o,this._loop=!!t.loop,this._to=Uh([t.to,n,i,t.from]),this._from=Uh([t.from,i,n])}}cancel(){this._active&&(this.tick(Date.now()),this._active=!1,this._notify(!1))}tick(t){const n=t-this._start,r=this._duration,i=this._prop,o=this._from,a=this._loop,s=this._to;let l;if(this._active=o!==s&&(a||n<r),!this._active){this._target[i]=s,this._notify(!0);return}if(n<0){this._target[i]=o;return}l=n/r%2,l=a&&l>1?2-l:l,l=this._easing(Math.min(1,Math.max(0,l))),this._target[i]=this._fn(o,s,l)}wait(){const t=this._promises||(this._promises=[]);return new Promise((n,r)=>{t.push({res:n,rej:r})})}_notify(t){const n=t?"res":"rej",r=this._promises||[];for(let i=0;i<r.length;i++)r[i][n]()}}class vI{constructor(t,n){this._chart=t,this._properties=new Map,this.configure(n)}configure(t){if(!Me(t))return;const n=Object.keys(zt.animation),r=this._properties;Object.getOwnPropertyNames(t).forEach(i=>{const o=t[i];if(!Me(o))return;const a={};for(const s of n)a[s]=o[s];(hn(o.properties)&&o.properties||[i]).forEach(s=>{(s===i||!r.has(s))&&r.set(s,a)})})}_animateOptions(t,n){const r=n.options,i=zce(t,r);if(!i)return[];const o=this._createAnimations(i,r);return r.$shared&&Wce(t.options.$animations,r).then(()=>{t.options=r},()=>{}),o}_createAnimations(t,n){const r=this._properties,i=[],o=t.$animations||(t.$animations={}),a=Object.keys(n),s=Date.now();let l;for(l=a.length-1;l>=0;--l){const c=a[l];if(c.charAt(0)==="$")continue;if(c==="options"){i.push(...this._animateOptions(t,n));continue}const u=n[c];let d=o[c];const f=r.get(c);if(d)if(f&&d.active()){d.update(f,u,s);continue}else d.cancel();if(!f||!f.duration){t[c]=u;continue}o[c]=d=new Bce(f,t,c,u),i.push(d)}return i}update(t,n){if(this._properties.size===0){Object.assign(t,n);return}const r=this._createAnimations(t,n);if(r.length)return Mo.add(this._chart,r),!0}}function Wce(e,t){const n=[],r=Object.keys(t);for(let i=0;i<r.length;i++){const o=e[r[i]];o&&o.active()&&n.push(o.wait())}return Promise.all(n)}function zce(e,t){if(!t)return;let n=e.options;if(!n){e.options=t;return}return n.$shared&&(e.options=n=Object.assign({},n,{$shared:!1,$animations:{}})),n}function yI(e,t){const n=e&&e.options||{},r=n.reverse,i=n.min===void 0?t:0,o=n.max===void 0?t:0;return{start:r?o:i,end:r?i:o}}function Vce(e,t,n){if(n===!1)return!1;const r=yI(e,n),i=yI(t,n);return{top:i.end,right:r.end,bottom:i.start,left:r.start}}function Hce(e){let t,n,r,i;return Me(e)?(t=e.top,n=e.right,r=e.bottom,i=e.left):t=n=r=i=e,{top:t,right:n,bottom:r,left:i,disabled:e===!1}}function bI(e,t){const n=[],r=e._getSortedDatasetMetas(t);let i,o;for(i=0,o=r.length;i<o;++i)n.push(r[i].index);return n}function xI(e,t,n,r={}){const i=e.keys,o=r.mode==="single";let a,s,l,c;if(t===null)return;let u=!1;for(a=0,s=i.length;a<s;++a){if(l=+i[a],l===n){if(u=!0,r.all)continue;break}c=e.values[l],Qr(c)&&(o||t===0||Hi(t)===Hi(c))&&(t+=c)}return!u&&!r.all?0:t}function Yce(e,t){const{iScale:n,vScale:r}=t,i=n.axis==="x"?"x":"y",o=r.axis==="x"?"x":"y",a=Object.keys(e),s=new Array(a.length);let l,c,u;for(l=0,c=a.length;l<c;++l)u=a[l],s[l]={[i]:u,[o]:e[u]};return s}function _1(e,t){const n=e&&e.options.stacked;return n||n===void 0&&t.stack!==void 0}function Uce(e,t,n){return`${e.id}.${t.id}.${n.stack||n.type}`}function Kce(e){const{min:t,max:n,minDefined:r,maxDefined:i}=e.getUserBounds();return{min:r?t:Number.NEGATIVE_INFINITY,max:i?n:Number.POSITIVE_INFINITY}}function qce(e,t,n){const r=e[t]||(e[t]={});return r[n]||(r[n]={})}function wI(e,t,n,r){for(const i of t.getMatchingVisibleMetas(r).reverse()){const o=e[i.index];if(n&&o>0||!n&&o<0)return i.index}return null}function _I(e,t){const{chart:n,_cachedMeta:r}=e,i=n._stacks||(n._stacks={}),{iScale:o,vScale:a,index:s}=r,l=o.axis,c=a.axis,u=Uce(o,a,r),d=t.length;let f;for(let p=0;p<d;++p){const m=t[p],{[l]:g,[c]:v}=m,x=m._stacks||(m._stacks={});f=x[c]=qce(i,u,g),f[s]=v,f._top=wI(f,a,!0,r.type),f._bottom=wI(f,a,!1,r.type);const _=f._visualValues||(f._visualValues={});_[s]=v}}function E1(e,t){const n=e.scales;return Object.keys(n).filter(r=>n[r].axis===t).shift()}function Gce(e,t){return hs(e,{active:!1,dataset:void 0,datasetIndex:t,index:t,mode:"default",type:"dataset"})}function Xce(e,t,n){return hs(e,{active:!1,dataIndex:t,parsed:void 0,raw:void 0,element:n,index:t,mode:"default",type:"data"})}function Ku(e,t){const n=e.controller.index,r=e.vScale&&e.vScale.axis;if(r){t=t||e._parsed;for(const i of t){const o=i._stacks;if(!o||o[r]===void 0||o[r][n]===void 0)return;delete o[r][n],o[r]._visualValues!==void 0&&o[r]._visualValues[n]!==void 0&&delete o[r]._visualValues[n]}}}const S1=e=>e==="reset"||e==="none",EI=(e,t)=>t?e:Object.assign({},e),Qce=(e,t,n)=>e&&!t.hidden&&t._stacked&&{keys:bI(n,!0),values:null};class Zh{static defaults={};static datasetElementType=null;static dataElementType=null;constructor(t,n){this.chart=t,this._ctx=t.ctx,this.index=n,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 t=this._cachedMeta;this.configure(),this.linkScales(),t._stacked=_1(t.vScale,t),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(t){this.index!==t&&Ku(this._cachedMeta),this.index=t}linkScales(){const t=this.chart,n=this._cachedMeta,r=this.getDataset(),i=(d,f,p,m)=>d==="x"?f:d==="r"?m:p,o=n.xAxisID=Oe(r.xAxisID,E1(t,"x")),a=n.yAxisID=Oe(r.yAxisID,E1(t,"y")),s=n.rAxisID=Oe(r.rAxisID,E1(t,"r")),l=n.indexAxis,c=n.iAxisID=i(l,o,a,s),u=n.vAxisID=i(l,a,o,s);n.xScale=this.getScaleForId(o),n.yScale=this.getScaleForId(a),n.rScale=this.getScaleForId(s),n.iScale=this.getScaleForId(c),n.vScale=this.getScaleForId(u)}getDataset(){return this.chart.data.datasets[this.index]}getMeta(){return this.chart.getDatasetMeta(this.index)}getScaleForId(t){return this.chart.scales[t]}_getOtherScale(t){const n=this._cachedMeta;return t===n.iScale?n.vScale:n.iScale}reset(){this._update("reset")}_destroy(){const t=this._cachedMeta;this._data&&WM(this._data,this),t._stacked&&Ku(t)}_dataCheck(){const t=this.getDataset(),n=t.data||(t.data=[]),r=this._data;if(Me(n)){const i=this._cachedMeta;this._data=Yce(n,i)}else if(r!==n){if(r){WM(r,this);const i=this._cachedMeta;Ku(i),i._parsed=[]}n&&Object.isExtensible(n)&&Ale(n,this),this._syncList=[],this._data=n}}addElements(){const t=this._cachedMeta;this._dataCheck(),this.datasetElementType&&(t.dataset=new this.datasetElementType)}buildOrUpdateElements(t){const n=this._cachedMeta,r=this.getDataset();let i=!1;this._dataCheck();const o=n._stacked;n._stacked=_1(n.vScale,n),n.stack!==r.stack&&(i=!0,Ku(n),n.stack=r.stack),this._resyncElements(t),(i||o!==n._stacked)&&(_I(this,n._parsed),n._stacked=_1(n.vScale,n))}configure(){const t=this.chart.config,n=t.datasetScopeKeys(this._type),r=t.getOptionScopes(this.getDataset(),n,!0);this.options=t.createResolver(r,this.getContext()),this._parsing=this.options.parsing,this._cachedDataOpts={}}parse(t,n){const{_cachedMeta:r,_data:i}=this,{iScale:o,_stacked:a}=r,s=o.axis;let l=t===0&&n===i.length?!0:r._sorted,c=t>0&&r._parsed[t-1],u,d,f;if(this._parsing===!1)r._parsed=i,r._sorted=!0,f=i;else{hn(i[t])?f=this.parseArrayData(r,i,t,n):Me(i[t])?f=this.parseObjectData(r,i,t,n):f=this.parsePrimitiveData(r,i,t,n);const p=()=>d[s]===null||c&&d[s]<c[s];for(u=0;u<n;++u)r._parsed[u+t]=d=f[u],l&&(p()&&(l=!1),c=d);r._sorted=l}a&&_I(this,f)}parsePrimitiveData(t,n,r,i){const{iScale:o,vScale:a}=t,s=o.axis,l=a.axis,c=o.getLabels(),u=o===a,d=new Array(i);let f,p,m;for(f=0,p=i;f<p;++f)m=f+r,d[f]={[s]:u||o.parse(c[m],m),[l]:a.parse(n[m],m)};return d}parseArrayData(t,n,r,i){const{xScale:o,yScale:a}=t,s=new Array(i);let l,c,u,d;for(l=0,c=i;l<c;++l)u=l+r,d=n[u],s[l]={x:o.parse(d[0],u),y:a.parse(d[1],u)};return s}parseObjectData(t,n,r,i){const{xScale:o,yScale:a}=t,{xAxisKey:s="x",yAxisKey:l="y"}=this._parsing,c=new Array(i);let u,d,f,p;for(u=0,d=i;u<d;++u)f=u+r,p=n[f],c[u]={x:o.parse(cs(p,s),f),y:a.parse(cs(p,l),f)};return c}getParsed(t){return this._cachedMeta._parsed[t]}getDataElement(t){return this._cachedMeta.data[t]}applyStack(t,n,r){const i=this.chart,o=this._cachedMeta,a=n[t.axis],s={keys:bI(i,!0),values:n._stacks[t.axis]._visualValues};return xI(s,a,o.index,{mode:r})}updateRangeFromParsed(t,n,r,i){const o=r[n.axis];let a=o===null?NaN:o;const s=i&&r._stacks[n.axis];i&&s&&(i.values=s,a=xI(i,o,this._cachedMeta.index)),t.min=Math.min(t.min,a),t.max=Math.max(t.max,a)}getMinMax(t,n){const r=this._cachedMeta,i=r._parsed,o=r._sorted&&t===r.iScale,a=i.length,s=this._getOtherScale(t),l=Qce(n,r,this.chart),c={min:Number.POSITIVE_INFINITY,max:Number.NEGATIVE_INFINITY},{min:u,max:d}=Kce(s);let f,p;function m(){p=i[f];const g=p[s.axis];return!Qr(p[t.axis])||u>g||d<g}for(f=0;f<a&&!(!m()&&(this.updateRangeFromParsed(c,t,p,l),o));++f);if(o){for(f=a-1;f>=0;--f)if(!m()){this.updateRangeFromParsed(c,t,p,l);break}}return c}getAllParsedValues(t){const n=this._cachedMeta._parsed,r=[];let i,o,a;for(i=0,o=n.length;i<o;++i)a=n[i][t.axis],Qr(a)&&r.push(a);return r}getMaxOverflow(){return!1}getLabelAndValue(t){const n=this._cachedMeta,r=n.iScale,i=n.vScale,o=this.getParsed(t);return{label:r?""+r.getLabelForValue(o[r.axis]):"",value:i?""+i.getLabelForValue(o[i.axis]):""}}_update(t){const n=this._cachedMeta;this.update(t||"default"),n._clip=Hce(Oe(this.options.clip,Vce(n.xScale,n.yScale,this.getMaxOverflow())))}update(t){}draw(){const t=this._ctx,n=this.chart,r=this._cachedMeta,i=r.data||[],o=n.chartArea,a=[],s=this._drawStart||0,l=this._drawCount||i.length-s,c=this.options.drawActiveElementsOnTop;let u;for(r.dataset&&r.dataset.draw(t,o,s,l),u=s;u<s+l;++u){const d=i[u];d.hidden||(d.active&&c?a.push(d):d.draw(t,o))}for(u=0;u<a.length;++u)a[u].draw(t,o)}getStyle(t,n){const r=n?"active":"default";return t===void 0&&this._cachedMeta.dataset?this.resolveDatasetElementOptions(r):this.resolveDataElementOptions(t||0,r)}getContext(t,n,r){const i=this.getDataset();let o;if(t>=0&&t<this._cachedMeta.data.length){const a=this._cachedMeta.data[t];o=a.$context||(a.$context=Xce(this.getContext(),t,a)),o.parsed=this.getParsed(t),o.raw=i.data[t],o.index=o.dataIndex=t}else o=this.$context||(this.$context=Gce(this.chart.getContext(),this.index)),o.dataset=i,o.index=o.datasetIndex=this.index;return o.active=!!n,o.mode=r,o}resolveDatasetElementOptions(t){return this._resolveElementOptions(this.datasetElementType.id,t)}resolveDataElementOptions(t,n){return this._resolveElementOptions(this.dataElementType.id,n,t)}_resolveElementOptions(t,n="default",r){const i=n==="active",o=this._cachedDataOpts,a=t+"-"+n,s=o[a],l=this.enableOptionSharing&&Bu(r);if(s)return EI(s,l);const c=this.chart.config,u=c.datasetElementScopeKeys(this._type,t),d=i?[`${t}Hover`,"hover",t,""]:[t,""],f=c.getOptionScopes(this.getDataset(),u),p=Object.keys(zt.elements[t]),m=()=>this.getContext(r,i,n),g=c.resolveNamedOptions(f,p,m,d);return g.$shared&&(g.$shared=l,o[a]=Object.freeze(EI(g,l))),g}_resolveAnimations(t,n,r){const i=this.chart,o=this._cachedDataOpts,a=`animation-${n}`,s=o[a];if(s)return s;let l;if(i.options.animation!==!1){const u=this.chart.config,d=u.datasetAnimationScopeKeys(this._type,n),f=u.getOptionScopes(this.getDataset(),d);l=u.createResolver(f,this.getContext(t,r,n))}const c=new vI(i,l&&l.animations);return l&&l._cacheable&&(o[a]=Object.freeze(c)),c}getSharedOptions(t){if(t.$shared)return this._sharedOptions||(this._sharedOptions=Object.assign({},t))}includeOptions(t,n){return!n||S1(t)||this.chart._animationsDisabled}_getSharedOptions(t,n){const r=this.resolveDataElementOptions(t,n),i=this._sharedOptions,o=this.getSharedOptions(r),a=this.includeOptions(n,o)||o!==i;return this.updateSharedOptions(o,n,r),{sharedOptions:o,includeOptions:a}}updateElement(t,n,r,i){S1(i)?Object.assign(t,r):this._resolveAnimations(n,i).update(t,r)}updateSharedOptions(t,n,r){t&&!S1(n)&&this._resolveAnimations(void 0,n).update(t,r)}_setStyle(t,n,r,i){t.active=i;const o=this.getStyle(n,i);this._resolveAnimations(n,r,i).update(t,{options:!i&&this.getSharedOptions(o)||o})}removeHoverStyle(t,n,r){this._setStyle(t,r,"active",!1)}setHoverStyle(t,n,r){this._setStyle(t,r,"active",!0)}_removeDatasetHoverStyle(){const t=this._cachedMeta.dataset;t&&this._setStyle(t,void 0,"active",!1)}_setDatasetHoverStyle(){const t=this._cachedMeta.dataset;t&&this._setStyle(t,void 0,"active",!0)}_resyncElements(t){const n=this._data,r=this._cachedMeta.data;for(const[s,l,c]of this._syncList)this[s](l,c);this._syncList=[];const i=r.length,o=n.length,a=Math.min(o,i);a&&this.parse(0,a),o>i?this._insertElements(i,o-i,t):o<i&&this._removeElements(o,i-o)}_insertElements(t,n,r=!0){const i=this._cachedMeta,o=i.data,a=t+n;let s;const l=c=>{for(c.length+=n,s=c.length-1;s>=a;s--)c[s]=c[s-n]};for(l(o),s=t;s<a;++s)o[s]=new this.dataElementType;this._parsing&&l(i._parsed),this.parse(t,n),r&&this.updateElements(o,t,n,"reset")}updateElements(t,n,r,i){}_removeElements(t,n){const r=this._cachedMeta;if(this._parsing){const i=r._parsed.splice(t,n);r._stacked&&Ku(r,i)}r.data.splice(t,n)}_sync(t){if(this._parsing)this._syncList.push(t);else{const[n,r,i]=t;this[n](r,i)}this.chart._dataChanges.push([this.index,...t])}_onDataPush(){const t=arguments.length;this._sync(["_insertElements",this.getDataset().data.length-t,t])}_onDataPop(){this._sync(["_removeElements",this._cachedMeta.data.length-1,1])}_onDataShift(){this._sync(["_removeElements",0,1])}_onDataSplice(t,n){n&&this._sync(["_removeElements",t,n]);const r=arguments.length-2;r&&this._sync(["_insertElements",t,r])}_onDataUnshift(){this._sync(["_insertElements",0,arguments.length])}}function Zce(e,t){if(!e._cache.$bar){const n=e.getMatchingVisibleMetas(t);let r=[];for(let i=0,o=n.length;i<o;i++)r=r.concat(n[i].controller.getAllParsedValues(e));e._cache.$bar=zM(r.sort((i,o)=>i-o))}return e._cache.$bar}function Jce(e){const t=e.iScale,n=Zce(t,e.type);let r=t._length,i,o,a,s;const l=()=>{a===32767||a===-32768||(Bu(s)&&(r=Math.min(r,Math.abs(a-s)||r)),s=a)};for(i=0,o=n.length;i<o;++i)a=t.getPixelForValue(n[i]),l();for(s=void 0,i=0,o=t.ticks.length;i<o;++i)a=t.getPixelForTick(i),l();return r}function eue(e,t,n,r){const i=n.barThickness;let o,a;return Ke(i)?(o=t.min*n.categoryPercentage,a=n.barPercentage):(o=i*r,a=1),{chunk:o/r,ratio:a,start:t.pixels[e]-o/2}}function tue(e,t,n,r){const i=t.pixels,o=i[e];let a=e>0?i[e-1]:null,s=e<i.length-1?i[e+1]:null;const l=n.categoryPercentage;a===null&&(a=o-(s===null?t.end-t.start:s-o)),s===null&&(s=o+o-a);const c=o-(o-Math.min(a,s))/2*l;return{chunk:Math.abs(s-a)/2*l/r,ratio:n.barPercentage,start:c}}function nue(e,t,n,r){const i=n.parse(e[0],r),o=n.parse(e[1],r),a=Math.min(i,o),s=Math.max(i,o);let l=a,c=s;Math.abs(a)>Math.abs(s)&&(l=s,c=a),t[n.axis]=c,t._custom={barStart:l,barEnd:c,start:i,end:o,min:a,max:s}}function SI(e,t,n,r){return hn(e)?nue(e,t,n,r):t[n.axis]=n.parse(e,r),t}function OI(e,t,n,r){const i=e.iScale,o=e.vScale,a=i.getLabels(),s=i===o,l=[];let c,u,d,f;for(c=n,u=n+r;c<u;++c)f=t[c],d={},d[i.axis]=s||i.parse(a[c],c),l.push(SI(f,d,o,c));return l}function O1(e){return e&&e.barStart!==void 0&&e.barEnd!==void 0}function rue(e,t,n){return e!==0?Hi(e):(t.isHorizontal()?1:-1)*(t.min>=n?1:-1)}function iue(e){let t,n,r,i,o;return e.horizontal?(t=e.base>e.x,n="left",r="right"):(t=e.base<e.y,n="bottom",r="top"),t?(i="end",o="start"):(i="start",o="end"),{start:n,end:r,reverse:t,top:i,bottom:o}}function oue(e,t,n,r){let i=t.borderSkipped;const o={};if(!i){e.borderSkipped=o;return}if(i===!0){e.borderSkipped={top:!0,right:!0,bottom:!0,left:!0};return}const{start:a,end:s,reverse:l,top:c,bottom:u}=iue(e);i==="middle"&&n&&(e.enableBorderRadius=!0,(n._top||0)===r?i=c:(n._bottom||0)===r?i=u:(o[CI(u,a,s,l)]=!0,i=c)),o[CI(i,a,s,l)]=!0,e.borderSkipped=o}function CI(e,t,n,r){return r?(e=aue(e,t,n),e=kI(e,n,t)):e=kI(e,t,n),e}function aue(e,t,n){return e===t?n:e===n?t:e}function kI(e,t,n){return e==="start"?t:e==="end"?n:e}function sue(e,{inflateAmount:t},n){e.inflateAmount=t==="auto"?n===1?.33:0:t}class lue extends Zh{static id="bar";static defaults={datasetElementType:!1,dataElementType:"bar",categoryPercentage:.8,barPercentage:.9,grouped:!0,animations:{numbers:{type:"number",properties:["x","y","base","width","height"]}}};static overrides={scales:{_index_:{type:"category",offset:!0,grid:{offset:!0}},_value_:{type:"linear",beginAtZero:!0}}};parsePrimitiveData(t,n,r,i){return OI(t,n,r,i)}parseArrayData(t,n,r,i){return OI(t,n,r,i)}parseObjectData(t,n,r,i){const{iScale:o,vScale:a}=t,{xAxisKey:s="x",yAxisKey:l="y"}=this._parsing,c=o.axis==="x"?s:l,u=a.axis==="x"?s:l,d=[];let f,p,m,g;for(f=r,p=r+i;f<p;++f)g=n[f],m={},m[o.axis]=o.parse(cs(g,c),f),d.push(SI(cs(g,u),m,a,f));return d}updateRangeFromParsed(t,n,r,i){super.updateRangeFromParsed(t,n,r,i);const o=r._custom;o&&n===this._cachedMeta.vScale&&(t.min=Math.min(t.min,o.min),t.max=Math.max(t.max,o.max))}getMaxOverflow(){return 0}getLabelAndValue(t){const n=this._cachedMeta,{iScale:r,vScale:i}=n,o=this.getParsed(t),a=o._custom,s=O1(a)?"["+a.start+", "+a.end+"]":""+i.getLabelForValue(o[i.axis]);return{label:""+r.getLabelForValue(o[r.axis]),value:s}}initialize(){this.enableOptionSharing=!0,super.initialize();const t=this._cachedMeta;t.stack=this.getDataset().stack}update(t){const n=this._cachedMeta;this.updateElements(n.data,0,n.data.length,t)}updateElements(t,n,r,i){const o=i==="reset",{index:a,_cachedMeta:{vScale:s}}=this,l=s.getBasePixel(),c=s.isHorizontal(),u=this._getRuler(),{sharedOptions:d,includeOptions:f}=this._getSharedOptions(n,i);for(let p=n;p<n+r;p++){const m=this.getParsed(p),g=o||Ke(m[s.axis])?{base:l,head:l}:this._calculateBarValuePixels(p),v=this._calculateBarIndexPixels(p,u),x=(m._stacks||{})[s.axis],_={horizontal:c,base:g.base,enableBorderRadius:!x||O1(m._custom)||a===x._top||a===x._bottom,x:c?g.head:v.center,y:c?v.center:g.head,height:c?v.size:Math.abs(g.size),width:c?Math.abs(g.size):v.size};f&&(_.options=d||this.resolveDataElementOptions(p,t[p].active?"active":i));const w=_.options||t[p].options;oue(_,w,x,a),sue(_,w,u.ratio),this.updateElement(t[p],p,_,i)}}_getStacks(t,n){const{iScale:r}=this._cachedMeta,i=r.getMatchingVisibleMetas(this._type).filter(u=>u.controller.options.grouped),o=r.options.stacked,a=[],s=this._cachedMeta.controller.getParsed(n),l=s&&s[r.axis],c=u=>{const d=u._parsed.find(p=>p[r.axis]===l),f=d&&d[u.vScale.axis];if(Ke(f)||isNaN(f))return!0};for(const u of i)if(!(n!==void 0&&c(u))&&((o===!1||a.indexOf(u.stack)===-1||o===void 0&&u.stack===void 0)&&a.push(u.stack),u.index===t))break;return a.length||a.push(void 0),a}_getStackCount(t){return this._getStacks(void 0,t).length}_getAxisCount(){return this._getAxis().length}getFirstScaleIdForIndexAxis(){const t=this.chart.scales,n=this.chart.options.indexAxis;return Object.keys(t).filter(r=>t[r].axis===n).shift()}_getAxis(){const t={},n=this.getFirstScaleIdForIndexAxis();for(const r of this.chart.data.datasets)t[Oe(this.chart.options.indexAxis==="x"?r.xAxisID:r.yAxisID,n)]=!0;return Object.keys(t)}_getStackIndex(t,n,r){const i=this._getStacks(t,r),o=n!==void 0?i.indexOf(n):-1;return o===-1?i.length-1:o}_getRuler(){const t=this.options,n=this._cachedMeta,r=n.iScale,i=[];let o,a;for(o=0,a=n.data.length;o<a;++o)i.push(r.getPixelForValue(this.getParsed(o)[r.axis],o));const s=t.barThickness;return{min:s||Jce(n),pixels:i,start:r._startPixel,end:r._endPixel,stackCount:this._getStackCount(),scale:r,grouped:t.grouped,ratio:s?1:t.categoryPercentage*t.barPercentage}}_calculateBarValuePixels(t){const{_cachedMeta:{vScale:n,_stacked:r,index:i},options:{base:o,minBarLength:a}}=this,s=o||0,l=this.getParsed(t),c=l._custom,u=O1(c);let d=l[n.axis],f=0,p=r?this.applyStack(n,l,r):d,m,g;p!==d&&(f=p-d,p=d),u&&(d=c.barStart,p=c.barEnd-c.barStart,d!==0&&Hi(d)!==Hi(c.barEnd)&&(f=0),f+=d);const v=!Ke(o)&&!u?o:f;let x=n.getPixelForValue(v);if(this.chart.getDataVisibility(t)?m=n.getPixelForValue(f+p):m=x,g=m-x,Math.abs(g)<a){g=rue(g,n,s)*a,d===s&&(x-=g/2);const _=n.getPixelForDecimal(0),w=n.getPixelForDecimal(1),y=Math.min(_,w),E=Math.max(_,w);x=Math.max(Math.min(x,E),y),m=x+g,r&&!u&&(l._stacks[n.axis]._visualValues[i]=n.getValueForPixel(m)-n.getValueForPixel(x))}if(x===n.getPixelForValue(s)){const _=Hi(g)*n.getLineWidthForValue(s)/2;x+=_,g-=_}return{size:g,base:x,head:m,center:m+g/2}}_calculateBarIndexPixels(t,n){const r=n.scale,i=this.options,o=i.skipNull,a=Oe(i.maxBarThickness,1/0);let s,l;const c=this._getAxisCount();if(n.grouped){const u=o?this._getStackCount(t):n.stackCount,d=i.barThickness==="flex"?tue(t,n,i,u*c):eue(t,n,i,u*c),f=this.chart.options.indexAxis==="x"?this.getDataset().xAxisID:this.getDataset().yAxisID,p=this._getAxis().indexOf(Oe(f,this.getFirstScaleIdForIndexAxis())),m=this._getStackIndex(this.index,this._cachedMeta.stack,o?t:void 0)+p;s=d.start+d.chunk*m+d.chunk/2,l=Math.min(a,d.chunk*d.ratio)}else s=r.getPixelForValue(this.getParsed(t)[r.axis],t),l=Math.min(a,n.min*n.ratio);return{base:s-l/2,head:s+l/2,center:s,size:l}}draw(){const t=this._cachedMeta,n=t.vScale,r=t.data,i=r.length;let o=0;for(;o<i;++o)this.getParsed(o)[n.axis]!==null&&!r[o].hidden&&r[o].draw(this._ctx)}}function cue(e,t,n){let r=1,i=1,o=0,a=0;if(t<Ft){const s=e,l=s+t,c=Math.cos(s),u=Math.sin(s),d=Math.cos(l),f=Math.sin(l),p=(w,y,E)=>Vu(w,s,l,!0)?1:Math.max(y,y*n,E,E*n),m=(w,y,E)=>Vu(w,s,l,!0)?-1:Math.min(y,y*n,E,E*n),g=p(0,c,d),v=p(an,u,f),x=m(st,c,d),_=m(st+an,u,f);r=(g-x)/2,i=(v-_)/2,o=-(g+x)/2,a=-(v+_)/2}return{ratioX:r,ratioY:i,offsetX:o,offsetY:a}}class uue extends Zh{static id="doughnut";static defaults={datasetElementType:!1,dataElementType:"arc",animation:{animateRotate:!0,animateScale:!1},animations:{numbers:{type:"number",properties:["circumference","endAngle","innerRadius","outerRadius","startAngle","x","y","offset","borderWidth","spacing"]}},cutout:"50%",rotation:0,circumference:360,radius:"100%",spacing:0,indexAxis:"r"};static descriptors={_scriptable:t=>t!=="spacing",_indexable:t=>t!=="spacing"&&!t.startsWith("borderDash")&&!t.startsWith("hoverBorderDash")};static overrides={aspectRatio:1,plugins:{legend:{labels:{generateLabels(t){const n=t.data;if(n.labels.length&&n.datasets.length){const{labels:{pointStyle:r,color:i}}=t.legend.options;return n.labels.map((o,a)=>{const l=t.getDatasetMeta(0).controller.getStyle(a);return{text:o,fillStyle:l.backgroundColor,strokeStyle:l.borderColor,fontColor:i,lineWidth:l.borderWidth,pointStyle:r,hidden:!t.getDataVisibility(a),index:a}})}return[]}},onClick(t,n,r){r.chart.toggleDataVisibility(n.index),r.chart.update()}}}};constructor(t,n){super(t,n),this.enableOptionSharing=!0,this.innerRadius=void 0,this.outerRadius=void 0,this.offsetX=void 0,this.offsetY=void 0}linkScales(){}parse(t,n){const r=this.getDataset().data,i=this._cachedMeta;if(this._parsing===!1)i._parsed=r;else{let o=l=>+r[l];if(Me(r[t])){const{key:l="value"}=this._parsing;o=c=>+cs(r[c],l)}let a,s;for(a=t,s=t+n;a<s;++a)i._parsed[a]=o(a)}}_getRotation(){return jo(this.options.rotation-90)}_getCircumference(){return jo(this.options.circumference)}_getRotationExtents(){let t=Ft,n=-Ft;for(let r=0;r<this.chart.data.datasets.length;++r)if(this.chart.isDatasetVisible(r)&&this.chart.getDatasetMeta(r).type===this._type){const i=this.chart.getDatasetMeta(r).controller,o=i._getRotation(),a=i._getCircumference();t=Math.min(t,o),n=Math.max(n,o+a)}return{rotation:t,circumference:n-t}}update(t){const n=this.chart,{chartArea:r}=n,i=this._cachedMeta,o=i.data,a=this.getMaxBorderWidth()+this.getMaxOffset(o)+this.options.spacing,s=Math.max((Math.min(r.width,r.height)-a)/2,0),l=Math.min(ple(this.options.cutout,s),1),c=this._getRingWeight(this.index),{circumference:u,rotation:d}=this._getRotationExtents(),{ratioX:f,ratioY:p,offsetX:m,offsetY:g}=cue(d,u,l),v=(r.width-a)/f,x=(r.height-a)/p,_=Math.max(Math.min(v,x)/2,0),w=TM(this.options.radius,_),y=Math.max(w*l,0),E=(w-y)/this._getVisibleDatasetWeightTotal();this.offsetX=m*w,this.offsetY=g*w,i.total=this.calculateTotal(),this.outerRadius=w-E*this._getRingWeightOffset(this.index),this.innerRadius=Math.max(this.outerRadius-E*c,0),this.updateElements(o,0,o.length,t)}_circumference(t,n){const r=this.options,i=this._cachedMeta,o=this._getCircumference();return n&&r.animation.animateRotate||!this.chart.getDataVisibility(t)||i._parsed[t]===null||i.data[t].hidden?0:this.calculateCircumference(i._parsed[t]*o/Ft)}updateElements(t,n,r,i){const o=i==="reset",a=this.chart,s=a.chartArea,c=a.options.animation,u=(s.left+s.right)/2,d=(s.top+s.bottom)/2,f=o&&c.animateScale,p=f?0:this.innerRadius,m=f?0:this.outerRadius,{sharedOptions:g,includeOptions:v}=this._getSharedOptions(n,i);let x=this._getRotation(),_;for(_=0;_<n;++_)x+=this._circumference(_,o);for(_=n;_<n+r;++_){const w=this._circumference(_,o),y=t[_],E={x:u+this.offsetX,y:d+this.offsetY,startAngle:x,endAngle:x+w,circumference:w,outerRadius:m,innerRadius:p};v&&(E.options=g||this.resolveDataElementOptions(_,y.active?"active":i)),x+=w,this.updateElement(y,_,E,i)}}calculateTotal(){const t=this._cachedMeta,n=t.data;let r=0,i;for(i=0;i<n.length;i++){const o=t._parsed[i];o!==null&&!isNaN(o)&&this.chart.getDataVisibility(i)&&!n[i].hidden&&(r+=Math.abs(o))}return r}calculateCircumference(t){const n=this._cachedMeta.total;return n>0&&!isNaN(t)?Ft*(Math.abs(t)/n):0}getLabelAndValue(t){const n=this._cachedMeta,r=this.chart,i=r.data.labels||[],o=u1(n._parsed[t],r.options.locale);return{label:i[t]||"",value:o}}getMaxBorderWidth(t){let n=0;const r=this.chart;let i,o,a,s,l;if(!t){for(i=0,o=r.data.datasets.length;i<o;++i)if(r.isDatasetVisible(i)){a=r.getDatasetMeta(i),t=a.data,s=a.controller;break}}if(!t)return 0;for(i=0,o=t.length;i<o;++i)l=s.resolveDataElementOptions(i),l.borderAlign!=="inner"&&(n=Math.max(n,l.borderWidth||0,l.hoverBorderWidth||0));return n}getMaxOffset(t){let n=0;for(let r=0,i=t.length;r<i;++r){const o=this.resolveDataElementOptions(r);n=Math.max(n,o.offset||0,o.hoverOffset||0)}return n}_getRingWeightOffset(t){let n=0;for(let r=0;r<t;++r)this.chart.isDatasetVisible(r)&&(n+=this._getRingWeight(r));return n}_getRingWeight(t){return Math.max(Oe(this.chart.data.datasets[t].weight,1),0)}_getVisibleDatasetWeightTotal(){return this._getRingWeightOffset(this.chart.data.datasets.length)||1}}class due extends Zh{static id="line";static defaults={datasetElementType:"line",dataElementType:"point",showLine:!0,spanGaps:!1};static overrides={scales:{_index_:{type:"category"},_value_:{type:"linear"}}};initialize(){this.enableOptionSharing=!0,this.supportsDecimation=!0,super.initialize()}update(t){const n=this._cachedMeta,{dataset:r,data:i=[],_dataset:o}=n,a=this.chart._animationsDisabled;let{start:s,count:l}=jle(n,i,a);this._drawStart=s,this._drawCount=l,Mle(n)&&(s=0,l=i.length),r._chart=this.chart,r._datasetIndex=this.index,r._decimated=!!o._decimated,r.points=i;const c=this.resolveDatasetElementOptions(t);this.options.showLine||(c.borderWidth=0),c.segment=this.options.segment,this.updateElement(r,void 0,{animated:!a,options:c},t),this.updateElements(i,s,l,t)}updateElements(t,n,r,i){const o=i==="reset",{iScale:a,vScale:s,_stacked:l,_dataset:c}=this._cachedMeta,{sharedOptions:u,includeOptions:d}=this._getSharedOptions(n,i),f=a.axis,p=s.axis,{spanGaps:m,segment:g}=this.options,v=zu(m)?m:Number.POSITIVE_INFINITY,x=this.chart._animationsDisabled||o||i==="none",_=n+r,w=t.length;let y=n>0&&this.getParsed(n-1);for(let E=0;E<w;++E){const S=t[E],P=x?S:{};if(E<n||E>=_){P.skip=!0;continue}const D=this.getParsed(E),T=Ke(D[p]),I=P[f]=a.getPixelForValue(D[f],E),A=P[p]=o||T?s.getBasePixel():s.getPixelForValue(l?this.applyStack(s,D,l):D[p],E);P.skip=isNaN(I)||isNaN(A)||T,P.stop=E>0&&Math.abs(D[f]-y[f])>v,g&&(P.parsed=D,P.raw=c.data[E]),d&&(P.options=u||this.resolveDataElementOptions(E,S.active?"active":i)),x||this.updateElement(S,E,P,i),y=D}}getMaxOverflow(){const t=this._cachedMeta,n=t.dataset,r=n.options&&n.options.borderWidth||0,i=t.data||[];if(!i.length)return r;const o=i[0].size(this.resolveDataElementOptions(0)),a=i[i.length-1].size(this.resolveDataElementOptions(i.length-1));return Math.max(r,o,a)/2}draw(){const t=this._cachedMeta;t.dataset.updateControlPoints(this.chart.chartArea,t.iScale.axis),super.draw()}}function ys(){throw new Error("This method is not implemented: Check that a complete date adapter is provided.")}class C1{static override(t){Object.assign(C1.prototype,t)}options;constructor(t){this.options=t||{}}init(){}formats(){return ys()}parse(){return ys()}format(){return ys()}add(){return ys()}diff(){return ys()}startOf(){return ys()}endOf(){return ys()}}var fue={_date:C1};function pue(e,t,n,r){const{controller:i,data:o,_sorted:a}=e,s=i._cachedMeta.iScale,l=e.dataset&&e.dataset.options?e.dataset.options.spanGaps:null;if(s&&t===s.axis&&t!=="r"&&a&&o.length){const c=s._reversePixels?Ple:ds;if(r){if(i._sharedOptions){const u=o[0],d=typeof u.getRange=="function"&&u.getRange(t);if(d){const f=c(o,t,n-d),p=c(o,t,n+d);return{lo:f.lo,hi:p.hi}}}}else{const u=c(o,t,n);if(l){const{vScale:d}=i._cachedMeta,{_parsed:f}=e,p=f.slice(0,u.lo+1).reverse().findIndex(g=>!Ke(g[d.axis]));u.lo-=Math.max(0,p);const m=f.slice(u.hi).findIndex(g=>!Ke(g[d.axis]));u.hi+=Math.max(0,m)}return u}}return{lo:0,hi:o.length-1}}function Jh(e,t,n,r,i){const o=e.getSortedVisibleDatasetMetas(),a=n[t];for(let s=0,l=o.length;s<l;++s){const{index:c,data:u}=o[s],{lo:d,hi:f}=pue(o[s],t,a,i);for(let p=d;p<=f;++p){const m=u[p];m.skip||r(m,c,p)}}}function hue(e){const t=e.indexOf("x")!==-1,n=e.indexOf("y")!==-1;return function(r,i){const o=t?Math.abs(r.x-i.x):0,a=n?Math.abs(r.y-i.y):0;return Math.sqrt(Math.pow(o,2)+Math.pow(a,2))}}function k1(e,t,n,r,i){const o=[];return!i&&!e.isPointInArea(t)||Jh(e,n,t,function(s,l,c){!i&&!Uu(s,e.chartArea,0)||s.inRange(t.x,t.y,r)&&o.push({element:s,datasetIndex:l,index:c})},!0),o}function mue(e,t,n,r){let i=[];function o(a,s,l){const{startAngle:c,endAngle:u}=a.getProps(["startAngle","endAngle"],r),{angle:d}=$M(a,{x:t.x,y:t.y});Vu(d,c,u)&&i.push({element:a,datasetIndex:s,index:l})}return Jh(e,n,t,o),i}function gue(e,t,n,r,i,o){let a=[];const s=hue(n);let l=Number.POSITIVE_INFINITY;function c(u,d,f){const p=u.inRange(t.x,t.y,i);if(r&&!p)return;const m=u.getCenterPoint(i);if(!(!!o||e.isPointInArea(m))&&!p)return;const v=s(t,m);v<l?(a=[{element:u,datasetIndex:d,index:f}],l=v):v===l&&a.push({element:u,datasetIndex:d,index:f})}return Jh(e,n,t,c),a}function P1(e,t,n,r,i,o){return!o&&!e.isPointInArea(t)?[]:n==="r"&&!r?mue(e,t,n,i):gue(e,t,n,r,i,o)}function PI(e,t,n,r,i){const o=[],a=n==="x"?"inXRange":"inYRange";let s=!1;return Jh(e,n,t,(l,c,u)=>{l[a]&&l[a](t[n],i)&&(o.push({element:l,datasetIndex:c,index:u}),s=s||l.inRange(t.x,t.y,i))}),r&&!s?[]:o}var vue={modes:{index(e,t,n,r){const i=gs(t,e),o=n.axis||"x",a=n.includeInvisible||!1,s=n.intersect?k1(e,i,o,r,a):P1(e,i,o,!1,r,a),l=[];return s.length?(e.getSortedVisibleDatasetMetas().forEach(c=>{const u=s[0].index,d=c.data[u];d&&!d.skip&&l.push({element:d,datasetIndex:c.index,index:u})}),l):[]},dataset(e,t,n,r){const i=gs(t,e),o=n.axis||"xy",a=n.includeInvisible||!1;let s=n.intersect?k1(e,i,o,r,a):P1(e,i,o,!1,r,a);if(s.length>0){const l=s[0].datasetIndex,c=e.getDatasetMeta(l).data;s=[];for(let u=0;u<c.length;++u)s.push({element:c[u],datasetIndex:l,index:u})}return s},point(e,t,n,r){const i=gs(t,e),o=n.axis||"xy",a=n.includeInvisible||!1;return k1(e,i,o,r,a)},nearest(e,t,n,r){const i=gs(t,e),o=n.axis||"xy",a=n.includeInvisible||!1;return P1(e,i,o,n.intersect,r,a)},x(e,t,n,r){const i=gs(t,e);return PI(e,i,"x",n.intersect,r)},y(e,t,n,r){const i=gs(t,e);return PI(e,i,"y",n.intersect,r)}}};const DI=["left","top","right","bottom"];function qu(e,t){return e.filter(n=>n.pos===t)}function AI(e,t){return e.filter(n=>DI.indexOf(n.pos)===-1&&n.box.axis===t)}function Gu(e,t){return e.sort((n,r)=>{const i=t?r:n,o=t?n:r;return i.weight===o.weight?i.index-o.index:i.weight-o.weight})}function yue(e){const t=[];let n,r,i,o,a,s;for(n=0,r=(e||[]).length;n<r;++n)i=e[n],{position:o,options:{stack:a,stackWeight:s=1}}=i,t.push({index:n,box:i,pos:o,horizontal:i.isHorizontal(),weight:i.weight,stack:a&&o+a,stackWeight:s});return t}function bue(e){const t={};for(const n of e){const{stack:r,pos:i,stackWeight:o}=n;if(!r||!DI.includes(i))continue;const a=t[r]||(t[r]={count:0,placed:0,weight:0,size:0});a.count++,a.weight+=o}return t}function xue(e,t){const n=bue(e),{vBoxMaxWidth:r,hBoxMaxHeight:i}=t;let o,a,s;for(o=0,a=e.length;o<a;++o){s=e[o];const{fullSize:l}=s.box,c=n[s.stack],u=c&&s.stackWeight/c.weight;s.horizontal?(s.width=u?u*r:l&&t.availableWidth,s.height=i):(s.width=r,s.height=u?u*i:l&&t.availableHeight)}return n}function wue(e){const t=yue(e),n=Gu(t.filter(c=>c.box.fullSize),!0),r=Gu(qu(t,"left"),!0),i=Gu(qu(t,"right")),o=Gu(qu(t,"top"),!0),a=Gu(qu(t,"bottom")),s=AI(t,"x"),l=AI(t,"y");return{fullSize:n,leftAndTop:r.concat(o),rightAndBottom:i.concat(l).concat(a).concat(s),chartArea:qu(t,"chartArea"),vertical:r.concat(i).concat(l),horizontal:o.concat(a).concat(s)}}function TI(e,t,n,r){return Math.max(e[n],t[n])+Math.max(e[r],t[r])}function NI(e,t){e.top=Math.max(e.top,t.top),e.left=Math.max(e.left,t.left),e.bottom=Math.max(e.bottom,t.bottom),e.right=Math.max(e.right,t.right)}function _ue(e,t,n,r){const{pos:i,box:o}=n,a=e.maxPadding;if(!Me(i)){n.size&&(e[i]-=n.size);const d=r[n.stack]||{size:0,count:1};d.size=Math.max(d.size,n.horizontal?o.height:o.width),n.size=d.size/d.count,e[i]+=n.size}o.getPadding&&NI(a,o.getPadding());const s=Math.max(0,t.outerWidth-TI(a,e,"left","right")),l=Math.max(0,t.outerHeight-TI(a,e,"top","bottom")),c=s!==e.w,u=l!==e.h;return e.w=s,e.h=l,n.horizontal?{same:c,other:u}:{same:u,other:c}}function Eue(e){const t=e.maxPadding;function n(r){const i=Math.max(t[r]-e[r],0);return e[r]+=i,i}e.y+=n("top"),e.x+=n("left"),n("right"),n("bottom")}function Sue(e,t){const n=t.maxPadding;function r(i){const o={left:0,top:0,right:0,bottom:0};return i.forEach(a=>{o[a]=Math.max(t[a],n[a])}),o}return r(e?["left","right"]:["top","bottom"])}function Xu(e,t,n,r){const i=[];let o,a,s,l,c,u;for(o=0,a=e.length,c=0;o<a;++o){s=e[o],l=s.box,l.update(s.width||t.w,s.height||t.h,Sue(s.horizontal,t));const{same:d,other:f}=_ue(t,n,s,r);c|=d&&i.length,u=u||f,l.fullSize||i.push(s)}return c&&Xu(i,t,n,r)||u}function em(e,t,n,r,i){e.top=n,e.left=t,e.right=t+r,e.bottom=n+i,e.width=r,e.height=i}function jI(e,t,n,r){const i=n.padding;let{x:o,y:a}=t;for(const s of e){const l=s.box,c=r[s.stack]||{placed:0,weight:1},u=s.stackWeight/c.weight||1;if(s.horizontal){const d=t.w*u,f=c.size||l.height;Bu(c.start)&&(a=c.start),l.fullSize?em(l,i.left,a,n.outerWidth-i.right-i.left,f):em(l,t.left+c.placed,a,d,f),c.start=a,c.placed+=d,a=l.bottom}else{const d=t.h*u,f=c.size||l.width;Bu(c.start)&&(o=c.start),l.fullSize?em(l,o,i.top,f,n.outerHeight-i.bottom-i.top):em(l,o,t.top+c.placed,f,d),c.start=o,c.placed+=d,o=l.right}}t.x=o,t.y=a}var ga={addBox(e,t){e.boxes||(e.boxes=[]),t.fullSize=t.fullSize||!1,t.position=t.position||"top",t.weight=t.weight||0,t._layers=t._layers||function(){return[{z:0,draw(n){t.draw(n)}}]},e.boxes.push(t)},removeBox(e,t){const n=e.boxes?e.boxes.indexOf(t):-1;n!==-1&&e.boxes.splice(n,1)},configure(e,t,n){t.fullSize=n.fullSize,t.position=n.position,t.weight=n.weight},update(e,t,n,r){if(!e)return;const i=li(e.options.layout.padding),o=Math.max(t-i.width,0),a=Math.max(n-i.height,0),s=wue(e.boxes),l=s.vertical,c=s.horizontal;et(e.boxes,g=>{typeof g.beforeLayout=="function"&&g.beforeLayout()});const u=l.reduce((g,v)=>v.box.options&&v.box.options.display===!1?g:g+1,0)||1,d=Object.freeze({outerWidth:t,outerHeight:n,padding:i,availableWidth:o,availableHeight:a,vBoxMaxWidth:o/2/u,hBoxMaxHeight:a/2}),f=Object.assign({},i);NI(f,li(r));const p=Object.assign({maxPadding:f,w:o,h:a,x:i.left,y:i.top},i),m=xue(l.concat(c),d);Xu(s.fullSize,p,d,m),Xu(l,p,d,m),Xu(c,p,d,m)&&Xu(l,p,d,m),Eue(p),jI(s.leftAndTop,p,d,m),p.x+=p.w,p.y+=p.h,jI(s.rightAndBottom,p,d,m),e.chartArea={left:p.left,top:p.top,right:p.left+p.w,bottom:p.top+p.h,height:p.h,width:p.w},et(s.chartArea,g=>{const v=g.box;Object.assign(v,e.chartArea),v.update(p.w,p.h,{left:0,top:0,right:0,bottom:0})})}};class MI{acquireContext(t,n){}releaseContext(t){return!1}addEventListener(t,n,r){}removeEventListener(t,n,r){}getDevicePixelRatio(){return 1}getMaximumSize(t,n,r,i){return n=Math.max(0,n||t.width),r=r||t.height,{width:n,height:Math.max(0,i?Math.floor(n/i):r)}}isAttached(t){return!0}updateConfig(t){}}class Oue extends MI{acquireContext(t){return t&&t.getContext&&t.getContext("2d")||null}updateConfig(t){t.options.animation=!1}}const tm="$chartjs",Cue={touchstart:"mousedown",touchmove:"mousemove",touchend:"mouseup",pointerenter:"mouseenter",pointerdown:"mousedown",pointermove:"mousemove",pointerup:"mouseup",pointerleave:"mouseout",pointerout:"mouseout"},II=e=>e===null||e==="";function kue(e,t){const n=e.style,r=e.getAttribute("height"),i=e.getAttribute("width");if(e[tm]={initial:{height:r,width:i,style:{display:n.display,height:n.height,width:n.width}}},n.display=n.display||"block",n.boxSizing=n.boxSizing||"border-box",II(i)){const o=cI(e,"width");o!==void 0&&(e.width=o)}if(II(r))if(e.style.height==="")e.height=e.width/(t||2);else{const o=cI(e,"height");o!==void 0&&(e.height=o)}return e}const FI=Ece?{passive:!0}:!1;function Pue(e,t,n){e&&e.addEventListener(t,n,FI)}function Due(e,t,n){e&&e.canvas&&e.canvas.removeEventListener(t,n,FI)}function Aue(e,t){const n=Cue[e.type]||e.type,{x:r,y:i}=gs(e,t);return{type:n,chart:t,native:e,x:r!==void 0?r:null,y:i!==void 0?i:null}}function nm(e,t){for(const n of e)if(n===t||n.contains(t))return!0}function Tue(e,t,n){const r=e.canvas,i=new MutationObserver(o=>{let a=!1;for(const s of o)a=a||nm(s.addedNodes,r),a=a&&!nm(s.removedNodes,r);a&&n()});return i.observe(document,{childList:!0,subtree:!0}),i}function Nue(e,t,n){const r=e.canvas,i=new MutationObserver(o=>{let a=!1;for(const s of o)a=a||nm(s.removedNodes,r),a=a&&!nm(s.addedNodes,r);a&&n()});return i.observe(document,{childList:!0,subtree:!0}),i}const Qu=new Map;let LI=0;function RI(){const e=window.devicePixelRatio;e!==LI&&(LI=e,Qu.forEach((t,n)=>{n.currentDevicePixelRatio!==e&&t()}))}function jue(e,t){Qu.size||window.addEventListener("resize",RI),Qu.set(e,t)}function Mue(e){Qu.delete(e),Qu.size||window.removeEventListener("resize",RI)}function Iue(e,t,n){const r=e.canvas,i=r&&w1(r);if(!i)return;const o=HM((s,l)=>{const c=i.clientWidth;n(s,l),c<i.clientWidth&&n()},window),a=new ResizeObserver(s=>{const l=s[0],c=l.contentRect.width,u=l.contentRect.height;c===0&&u===0||o(c,u)});return a.observe(i),jue(e,o),a}function D1(e,t,n){n&&n.disconnect(),t==="resize"&&Mue(e)}function Fue(e,t,n){const r=e.canvas,i=HM(o=>{e.ctx!==null&&n(Aue(o,e))},e);return Pue(r,t,i),i}class Lue extends MI{acquireContext(t,n){const r=t&&t.getContext&&t.getContext("2d");return r&&r.canvas===t?(kue(t,n),r):null}releaseContext(t){const n=t.canvas;if(!n[tm])return!1;const r=n[tm].initial;["height","width"].forEach(o=>{const a=r[o];Ke(a)?n.removeAttribute(o):n.setAttribute(o,a)});const i=r.style||{};return Object.keys(i).forEach(o=>{n.style[o]=i[o]}),n.width=n.width,delete n[tm],!0}addEventListener(t,n,r){this.removeEventListener(t,n);const i=t.$proxies||(t.$proxies={}),a={attach:Tue,detach:Nue,resize:Iue}[n]||Fue;i[n]=a(t,n,r)}removeEventListener(t,n){const r=t.$proxies||(t.$proxies={}),i=r[n];if(!i)return;({attach:D1,detach:D1,resize:D1}[n]||Due)(t,n,i),r[n]=void 0}getDevicePixelRatio(){return window.devicePixelRatio}getMaximumSize(t,n,r,i){return _ce(t,n,r,i)}isAttached(t){const n=t&&w1(t);return!!(n&&n.isConnected)}}function Rue(e){return!x1()||typeof OffscreenCanvas<"u"&&e instanceof OffscreenCanvas?Oue:Lue}let va=class{static defaults={};static defaultRoutes=void 0;x;y;active=!1;options;$animations;tooltipPosition(t){const{x:n,y:r}=this.getProps(["x","y"],t);return{x:n,y:r}}hasValue(){return zu(this.x)&&zu(this.y)}getProps(t,n){const r=this.$animations;if(!n||!r)return this;const i={};return t.forEach(o=>{i[o]=r[o]&&r[o].active()?r[o]._to:this[o]}),i}};function $ue(e,t){const n=e.options.ticks,r=Bue(e),i=Math.min(n.maxTicksLimit||r,r),o=n.major.enabled?zue(t):[],a=o.length,s=o[0],l=o[a-1],c=[];if(a>i)return Vue(t,c,o,a/i),c;const u=Wue(o,t,i);if(a>0){let d,f;const p=a>1?Math.round((l-s)/(a-1)):null;for(rm(t,c,u,Ke(p)?0:s-p,s),d=0,f=a-1;d<f;d++)rm(t,c,u,o[d],o[d+1]);return rm(t,c,u,l,Ke(p)?t.length:l+p),c}return rm(t,c,u),c}function Bue(e){const t=e.options.offset,n=e._tickSize(),r=e._length/n+(t?0:1),i=e._maxLength/n;return Math.floor(Math.min(r,i))}function Wue(e,t,n){const r=Hue(e),i=t.length/n;if(!r)return Math.max(i,1);const o=wle(r);for(let a=0,s=o.length-1;a<s;a++){const l=o[a];if(l>i)return l}return Math.max(i,1)}function zue(e){const t=[];let n,r;for(n=0,r=e.length;n<r;n++)e[n].major&&t.push(n);return t}function Vue(e,t,n,r){let i=0,o=n[0],a;for(r=Math.ceil(r),a=0;a<e.length;a++)a===o&&(t.push(e[a]),i++,o=n[i*r])}function rm(e,t,n,r,i){const o=Oe(r,0),a=Math.min(Oe(i,e.length),e.length);let s=0,l,c,u;for(n=Math.ceil(n),i&&(l=i-r,n=l/Math.floor(l/n)),u=o;u<0;)s++,u=Math.round(o+s*n);for(c=Math.max(o,0);c<a;c++)c===u&&(t.push(e[c]),s++,u=Math.round(o+s*n))}function Hue(e){const t=e.length;let n,r;if(t<2)return!1;for(r=e[0],n=1;n<t;++n)if(e[n]-e[n-1]!==r)return!1;return r}const Yue=e=>e==="left"?"right":e==="right"?"left":e,$I=(e,t,n)=>t==="top"||t==="left"?e[t]+n:e[t]-n,BI=(e,t)=>Math.min(t||e,e);function WI(e,t){const n=[],r=e.length/t,i=e.length;let o=0;for(;o<i;o+=r)n.push(e[Math.floor(o)]);return n}function Uue(e,t,n){const r=e.ticks.length,i=Math.min(t,r-1),o=e._startPixel,a=e._endPixel,s=1e-6;let l=e.getPixelForTick(i),c;if(!(n&&(r===1?c=Math.max(l-o,a-l):t===0?c=(e.getPixelForTick(1)-l)/2:c=(l-e.getPixelForTick(i-1))/2,l+=i<t?c:-c,l<o-s||l>a+s)))return l}function Kue(e,t){et(e,n=>{const r=n.gc,i=r.length/2;let o;if(i>t){for(o=0;o<i;++o)delete n.data[r[o]];r.splice(0,i)}})}function Zu(e){return e.drawTicks?e.tickLength:0}function zI(e,t){if(!e.display)return 0;const n=cr(e.font,t),r=li(e.padding);return(hn(e.text)?e.text.length:1)*n.lineHeight+r.height}function que(e,t){return hs(e,{scale:t,type:"scale"})}function Gue(e,t,n){return hs(e,{tick:n,index:t,type:"tick"})}function Xue(e,t,n){let r=YM(e);return(n&&t!=="right"||!n&&t==="right")&&(r=Yue(r)),r}function Que(e,t,n,r){const{top:i,left:o,bottom:a,right:s,chart:l}=e,{chartArea:c,scales:u}=l;let d=0,f,p,m;const g=a-i,v=s-o;if(e.isHorizontal()){if(p=Dr(r,o,s),Me(n)){const x=Object.keys(n)[0],_=n[x];m=u[x].getPixelForValue(_)+g-t}else n==="center"?m=(c.bottom+c.top)/2+g-t:m=$I(e,n,t);f=s-o}else{if(Me(n)){const x=Object.keys(n)[0],_=n[x];p=u[x].getPixelForValue(_)-v+t}else n==="center"?p=(c.left+c.right)/2-v+t:p=$I(e,n,t);m=Dr(r,a,i),d=n==="left"?-an:an}return{titleX:p,titleY:m,maxWidth:f,rotation:d}}class $l extends va{constructor(t){super(),this.id=t.id,this.type=t.type,this.options=void 0,this.ctx=t.ctx,this.chart=t.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(t){this.options=t.setContext(this.getContext()),this.axis=t.axis,this._userMin=this.parse(t.min),this._userMax=this.parse(t.max),this._suggestedMin=this.parse(t.suggestedMin),this._suggestedMax=this.parse(t.suggestedMax)}parse(t,n){return t}getUserBounds(){let{_userMin:t,_userMax:n,_suggestedMin:r,_suggestedMax:i}=this;return t=Vi(t,Number.POSITIVE_INFINITY),n=Vi(n,Number.NEGATIVE_INFINITY),r=Vi(r,Number.POSITIVE_INFINITY),i=Vi(i,Number.NEGATIVE_INFINITY),{min:Vi(t,r),max:Vi(n,i),minDefined:Qr(t),maxDefined:Qr(n)}}getMinMax(t){let{min:n,max:r,minDefined:i,maxDefined:o}=this.getUserBounds(),a;if(i&&o)return{min:n,max:r};const s=this.getMatchingVisibleMetas();for(let l=0,c=s.length;l<c;++l)a=s[l].controller.getMinMax(this,t),i||(n=Math.min(n,a.min)),o||(r=Math.max(r,a.max));return n=o&&n>r?r:n,r=i&&n>r?n:r,{min:Vi(n,Vi(r,n)),max:Vi(r,Vi(n,r))}}getPadding(){return{left:this.paddingLeft||0,top:this.paddingTop||0,right:this.paddingRight||0,bottom:this.paddingBottom||0}}getTicks(){return this.ticks}getLabels(){const t=this.chart.data;return this.options.labels||(this.isHorizontal()?t.xLabels:t.yLabels)||t.labels||[]}getLabelItems(t=this.chart.chartArea){return this._labelItems||(this._labelItems=this._computeLabelItems(t))}beforeLayout(){this._cache={},this._dataLimitsCached=!1}beforeUpdate(){bt(this.options.beforeUpdate,[this])}update(t,n,r){const{beginAtZero:i,grace:o,ticks:a}=this.options,s=a.sampleSize;this.beforeUpdate(),this.maxWidth=t,this.maxHeight=n,this._margins=r=Object.assign({left:0,right:0,top:0,bottom:0},r),this.ticks=null,this._labelSizes=null,this._gridLineItems=null,this._labelItems=null,this.beforeSetDimensions(),this.setDimensions(),this.afterSetDimensions(),this._maxLength=this.isHorizontal()?this.width+r.left+r.right:this.height+r.top+r.bottom,this._dataLimitsCached||(this.beforeDataLimits(),this.determineDataLimits(),this.afterDataLimits(),this._range=ece(this,o,i),this._dataLimitsCached=!0),this.beforeBuildTicks(),this.ticks=this.buildTicks()||[],this.afterBuildTicks();const l=s<this.ticks.length;this._convertTicksToLabels(l?WI(this.ticks,s):this.ticks),this.configure(),this.beforeCalculateLabelRotation(),this.calculateLabelRotation(),this.afterCalculateLabelRotation(),a.display&&(a.autoSkip||a.source==="auto")&&(this.ticks=$ue(this,this.ticks),this._labelSizes=null,this.afterAutoSkip()),l&&this._convertTicksToLabels(this.ticks),this.beforeFit(),this.fit(),this.afterFit(),this.afterUpdate()}configure(){let t=this.options.reverse,n,r;this.isHorizontal()?(n=this.left,r=this.right):(n=this.top,r=this.bottom,t=!t),this._startPixel=n,this._endPixel=r,this._reversePixels=t,this._length=r-n,this._alignToPixels=this.options.alignToPixels}afterUpdate(){bt(this.options.afterUpdate,[this])}beforeSetDimensions(){bt(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(){bt(this.options.afterSetDimensions,[this])}_callHooks(t){this.chart.notifyPlugins(t,this.getContext()),bt(this.options[t],[this])}beforeDataLimits(){this._callHooks("beforeDataLimits")}determineDataLimits(){}afterDataLimits(){this._callHooks("afterDataLimits")}beforeBuildTicks(){this._callHooks("beforeBuildTicks")}buildTicks(){return[]}afterBuildTicks(){this._callHooks("afterBuildTicks")}beforeTickToLabelConversion(){bt(this.options.beforeTickToLabelConversion,[this])}generateTickLabels(t){const n=this.options.ticks;let r,i,o;for(r=0,i=t.length;r<i;r++)o=t[r],o.label=bt(n.callback,[o.value,r,t],this)}afterTickToLabelConversion(){bt(this.options.afterTickToLabelConversion,[this])}beforeCalculateLabelRotation(){bt(this.options.beforeCalculateLabelRotation,[this])}calculateLabelRotation(){const t=this.options,n=t.ticks,r=BI(this.ticks.length,t.ticks.maxTicksLimit),i=n.minRotation||0,o=n.maxRotation;let a=i,s,l,c;if(!this._isVisible()||!n.display||i>=o||r<=1||!this.isHorizontal()){this.labelRotation=i;return}const u=this._getLabelSizes(),d=u.widest.width,f=u.highest.height,p=$n(this.chart.width-d,0,this.maxWidth);s=t.offset?this.maxWidth/r:p/(r-1),d+6>s&&(s=p/(r-(t.offset?.5:1)),l=this.maxHeight-Zu(t.grid)-n.padding-zI(t.title,this.chart.options.font),c=Math.sqrt(d*d+f*f),a=Ole(Math.min(Math.asin($n((u.highest.height+6)/s,-1,1)),Math.asin($n(l/c,-1,1))-Math.asin($n(f/c,-1,1)))),a=Math.max(i,Math.min(o,a))),this.labelRotation=a}afterCalculateLabelRotation(){bt(this.options.afterCalculateLabelRotation,[this])}afterAutoSkip(){}beforeFit(){bt(this.options.beforeFit,[this])}fit(){const t={width:0,height:0},{chart:n,options:{ticks:r,title:i,grid:o}}=this,a=this._isVisible(),s=this.isHorizontal();if(a){const l=zI(i,n.options.font);if(s?(t.width=this.maxWidth,t.height=Zu(o)+l):(t.height=this.maxHeight,t.width=Zu(o)+l),r.display&&this.ticks.length){const{first:c,last:u,widest:d,highest:f}=this._getLabelSizes(),p=r.padding*2,m=jo(this.labelRotation),g=Math.cos(m),v=Math.sin(m);if(s){const x=r.mirror?0:v*d.width+g*f.height;t.height=Math.min(this.maxHeight,t.height+x+p)}else{const x=r.mirror?0:g*d.width+v*f.height;t.width=Math.min(this.maxWidth,t.width+x+p)}this._calculatePadding(c,u,v,g)}}this._handleMargins(),s?(this.width=this._length=n.width-this._margins.left-this._margins.right,this.height=t.height):(this.width=t.width,this.height=this._length=n.height-this._margins.top-this._margins.bottom)}_calculatePadding(t,n,r,i){const{ticks:{align:o,padding:a},position:s}=this.options,l=this.labelRotation!==0,c=s!=="top"&&this.axis==="x";if(this.isHorizontal()){const u=this.getPixelForTick(0)-this.left,d=this.right-this.getPixelForTick(this.ticks.length-1);let f=0,p=0;l?c?(f=i*t.width,p=r*n.height):(f=r*t.height,p=i*n.width):o==="start"?p=n.width:o==="end"?f=t.width:o!=="inner"&&(f=t.width/2,p=n.width/2),this.paddingLeft=Math.max((f-u+a)*this.width/(this.width-u),0),this.paddingRight=Math.max((p-d+a)*this.width/(this.width-d),0)}else{let u=n.height/2,d=t.height/2;o==="start"?(u=0,d=t.height):o==="end"&&(u=n.height,d=0),this.paddingTop=u+a,this.paddingBottom=d+a}}_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(){bt(this.options.afterFit,[this])}isHorizontal(){const{axis:t,position:n}=this.options;return n==="top"||n==="bottom"||t==="x"}isFullSize(){return this.options.fullSize}_convertTicksToLabels(t){this.beforeTickToLabelConversion(),this.generateTickLabels(t);let n,r;for(n=0,r=t.length;n<r;n++)Ke(t[n].label)&&(t.splice(n,1),r--,n--);this.afterTickToLabelConversion()}_getLabelSizes(){let t=this._labelSizes;if(!t){const n=this.options.ticks.sampleSize;let r=this.ticks;n<r.length&&(r=WI(r,n)),this._labelSizes=t=this._computeLabelSizes(r,r.length,this.options.ticks.maxTicksLimit)}return t}_computeLabelSizes(t,n,r){const{ctx:i,_longestTextCache:o}=this,a=[],s=[],l=Math.floor(n/BI(n,r));let c=0,u=0,d,f,p,m,g,v,x,_,w,y,E;for(d=0;d<n;d+=l){if(m=t[d].label,g=this._resolveTickFontOptions(d),i.font=v=g.string,x=o[v]=o[v]||{data:{},gc:[]},_=g.lineHeight,w=y=0,!Ke(m)&&!hn(m))w=QM(i,x.data,x.gc,w,m),y=_;else if(hn(m))for(f=0,p=m.length;f<p;++f)E=m[f],!Ke(E)&&!hn(E)&&(w=QM(i,x.data,x.gc,w,E),y+=_);a.push(w),s.push(y),c=Math.max(w,c),u=Math.max(y,u)}Kue(o,n);const S=a.indexOf(c),P=s.indexOf(u),D=T=>({width:a[T]||0,height:s[T]||0});return{first:D(0),last:D(n-1),widest:D(S),highest:D(P),widths:a,heights:s}}getLabelForValue(t){return t}getPixelForValue(t,n){return NaN}getValueForPixel(t){}getPixelForTick(t){const n=this.ticks;return t<0||t>n.length-1?null:this.getPixelForValue(n[t].value)}getPixelForDecimal(t){this._reversePixels&&(t=1-t);const n=this._startPixel+t*this._length;return kle(this._alignToPixels?ps(this.chart,n,0):n)}getDecimalForPixel(t){const n=(t-this._startPixel)/this._length;return this._reversePixels?1-n:n}getBasePixel(){return this.getPixelForValue(this.getBaseValue())}getBaseValue(){const{min:t,max:n}=this;return t<0&&n<0?n:t>0&&n>0?t:0}getContext(t){const n=this.ticks||[];if(t>=0&&t<n.length){const r=n[t];return r.$context||(r.$context=Gue(this.getContext(),t,r))}return this.$context||(this.$context=que(this.chart.getContext(),this))}_tickSize(){const t=this.options.ticks,n=jo(this.labelRotation),r=Math.abs(Math.cos(n)),i=Math.abs(Math.sin(n)),o=this._getLabelSizes(),a=t.autoSkipPadding||0,s=o?o.widest.width+a:0,l=o?o.highest.height+a:0;return this.isHorizontal()?l*r>s*i?s/r:l/i:l*i<s*r?l/r:s/i}_isVisible(){const t=this.options.display;return t!=="auto"?!!t:this.getMatchingVisibleMetas().length>0}_computeGridLineItems(t){const n=this.axis,r=this.chart,i=this.options,{grid:o,position:a,border:s}=i,l=o.offset,c=this.isHorizontal(),d=this.ticks.length+(l?1:0),f=Zu(o),p=[],m=s.setContext(this.getContext()),g=m.display?m.width:0,v=g/2,x=function(R){return ps(r,R,g)};let _,w,y,E,S,P,D,T,I,A,C,j;if(a==="top")_=x(this.bottom),P=this.bottom-f,T=_-v,A=x(t.top)+v,j=t.bottom;else if(a==="bottom")_=x(this.top),A=t.top,j=x(t.bottom)-v,P=_+v,T=this.top+f;else if(a==="left")_=x(this.right),S=this.right-f,D=_-v,I=x(t.left)+v,C=t.right;else if(a==="right")_=x(this.left),I=t.left,C=x(t.right)-v,S=_+v,D=this.left+f;else if(n==="x"){if(a==="center")_=x((t.top+t.bottom)/2+.5);else if(Me(a)){const R=Object.keys(a)[0],B=a[R];_=x(this.chart.scales[R].getPixelForValue(B))}A=t.top,j=t.bottom,P=_+v,T=P+f}else if(n==="y"){if(a==="center")_=x((t.left+t.right)/2);else if(Me(a)){const R=Object.keys(a)[0],B=a[R];_=x(this.chart.scales[R].getPixelForValue(B))}S=_-v,D=S-f,I=t.left,C=t.right}const N=Oe(i.ticks.maxTicksLimit,d),M=Math.max(1,Math.ceil(d/N));for(w=0;w<d;w+=M){const R=this.getContext(w),B=o.setContext(R),V=s.setContext(R),z=B.lineWidth,W=B.color,Q=V.dash||[],X=V.dashOffset,ie=B.tickWidth,J=B.tickColor,re=B.tickBorderDash||[],se=B.tickBorderDashOffset;y=Uue(this,w,l),y!==void 0&&(E=ps(r,y,z),c?S=D=I=C=E:P=T=A=j=E,p.push({tx1:S,ty1:P,tx2:D,ty2:T,x1:I,y1:A,x2:C,y2:j,width:z,color:W,borderDash:Q,borderDashOffset:X,tickWidth:ie,tickColor:J,tickBorderDash:re,tickBorderDashOffset:se}))}return this._ticksLength=d,this._borderValue=_,p}_computeLabelItems(t){const n=this.axis,r=this.options,{position:i,ticks:o}=r,a=this.isHorizontal(),s=this.ticks,{align:l,crossAlign:c,padding:u,mirror:d}=o,f=Zu(r.grid),p=f+u,m=d?-u:p,g=-jo(this.labelRotation),v=[];let x,_,w,y,E,S,P,D,T,I,A,C,j="middle";if(i==="top")S=this.bottom-m,P=this._getXAxisLabelAlignment();else if(i==="bottom")S=this.top+m,P=this._getXAxisLabelAlignment();else if(i==="left"){const M=this._getYAxisLabelAlignment(f);P=M.textAlign,E=M.x}else if(i==="right"){const M=this._getYAxisLabelAlignment(f);P=M.textAlign,E=M.x}else if(n==="x"){if(i==="center")S=(t.top+t.bottom)/2+p;else if(Me(i)){const M=Object.keys(i)[0],R=i[M];S=this.chart.scales[M].getPixelForValue(R)+p}P=this._getXAxisLabelAlignment()}else if(n==="y"){if(i==="center")E=(t.left+t.right)/2-p;else if(Me(i)){const M=Object.keys(i)[0],R=i[M];E=this.chart.scales[M].getPixelForValue(R)}P=this._getYAxisLabelAlignment(f).textAlign}n==="y"&&(l==="start"?j="top":l==="end"&&(j="bottom"));const N=this._getLabelSizes();for(x=0,_=s.length;x<_;++x){w=s[x],y=w.label;const M=o.setContext(this.getContext(x));D=this.getPixelForTick(x)+o.labelOffset,T=this._resolveTickFontOptions(x),I=T.lineHeight,A=hn(y)?y.length:1;const R=A/2,B=M.color,V=M.textStrokeColor,z=M.textStrokeWidth;let W=P;a?(E=D,P==="inner"&&(x===_-1?W=this.options.reverse?"left":"right":x===0?W=this.options.reverse?"right":"left":W="center"),i==="top"?c==="near"||g!==0?C=-A*I+I/2:c==="center"?C=-N.highest.height/2-R*I+I:C=-N.highest.height+I/2:c==="near"||g!==0?C=I/2:c==="center"?C=N.highest.height/2-R*I:C=N.highest.height-A*I,d&&(C*=-1),g!==0&&!M.showLabelBackdrop&&(E+=I/2*Math.sin(g))):(S=D,C=(1-A)*I/2);let Q;if(M.showLabelBackdrop){const X=li(M.backdropPadding),ie=N.heights[x],J=N.widths[x];let re=C-X.top,se=0-X.left;switch(j){case"middle":re-=ie/2;break;case"bottom":re-=ie;break}switch(P){case"center":se-=J/2;break;case"right":se-=J;break;case"inner":x===_-1?se-=J:x>0&&(se-=J/2);break}Q={left:se,top:re,width:J+X.width,height:ie+X.height,color:M.backdropColor}}v.push({label:y,font:T,textOffset:C,options:{rotation:g,color:B,strokeColor:V,strokeWidth:z,textAlign:W,textBaseline:j,translation:[E,S],backdrop:Q}})}return v}_getXAxisLabelAlignment(){const{position:t,ticks:n}=this.options;if(-jo(this.labelRotation))return t==="top"?"left":"right";let i="center";return n.align==="start"?i="left":n.align==="end"?i="right":n.align==="inner"&&(i="inner"),i}_getYAxisLabelAlignment(t){const{position:n,ticks:{crossAlign:r,mirror:i,padding:o}}=this.options,a=this._getLabelSizes(),s=t+o,l=a.widest.width;let c,u;return n==="left"?i?(u=this.right+o,r==="near"?c="left":r==="center"?(c="center",u+=l/2):(c="right",u+=l)):(u=this.right-s,r==="near"?c="right":r==="center"?(c="center",u-=l/2):(c="left",u=this.left)):n==="right"?i?(u=this.left+o,r==="near"?c="right":r==="center"?(c="center",u-=l/2):(c="left",u-=l)):(u=this.left+s,r==="near"?c="left":r==="center"?(c="center",u+=l/2):(c="right",u=this.right)):c="right",{textAlign:c,x:u}}_computeLabelArea(){if(this.options.ticks.mirror)return;const t=this.chart,n=this.options.position;if(n==="left"||n==="right")return{top:0,left:this.left,bottom:t.height,right:this.right};if(n==="top"||n==="bottom")return{top:this.top,left:0,bottom:this.bottom,right:t.width}}drawBackground(){const{ctx:t,options:{backgroundColor:n},left:r,top:i,width:o,height:a}=this;n&&(t.save(),t.fillStyle=n,t.fillRect(r,i,o,a),t.restore())}getLineWidthForValue(t){const n=this.options.grid;if(!this._isVisible()||!n.display)return 0;const i=this.ticks.findIndex(o=>o.value===t);return i>=0?n.setContext(this.getContext(i)).lineWidth:0}drawGrid(t){const n=this.options.grid,r=this.ctx,i=this._gridLineItems||(this._gridLineItems=this._computeGridLineItems(t));let o,a;const s=(l,c,u)=>{!u.width||!u.color||(r.save(),r.lineWidth=u.width,r.strokeStyle=u.color,r.setLineDash(u.borderDash||[]),r.lineDashOffset=u.borderDashOffset,r.beginPath(),r.moveTo(l.x,l.y),r.lineTo(c.x,c.y),r.stroke(),r.restore())};if(n.display)for(o=0,a=i.length;o<a;++o){const l=i[o];n.drawOnChartArea&&s({x:l.x1,y:l.y1},{x:l.x2,y:l.y2},l),n.drawTicks&&s({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:t,ctx:n,options:{border:r,grid:i}}=this,o=r.setContext(this.getContext()),a=r.display?o.width:0;if(!a)return;const s=i.setContext(this.getContext(0)).lineWidth,l=this._borderValue;let c,u,d,f;this.isHorizontal()?(c=ps(t,this.left,a)-a/2,u=ps(t,this.right,s)+s/2,d=f=l):(d=ps(t,this.top,a)-a/2,f=ps(t,this.bottom,s)+s/2,c=u=l),n.save(),n.lineWidth=o.width,n.strokeStyle=o.color,n.beginPath(),n.moveTo(c,d),n.lineTo(u,f),n.stroke(),n.restore()}drawLabels(t){if(!this.options.ticks.display)return;const r=this.ctx,i=this._computeLabelArea();i&&h1(r,i);const o=this.getLabelItems(t);for(const a of o){const s=a.options,l=a.font,c=a.label,u=a.textOffset;Hh(r,c,0,u,l,s)}i&&m1(r)}drawTitle(){const{ctx:t,options:{position:n,title:r,reverse:i}}=this;if(!r.display)return;const o=cr(r.font),a=li(r.padding),s=r.align;let l=o.lineHeight/2;n==="bottom"||n==="center"||Me(n)?(l+=a.bottom,hn(r.text)&&(l+=o.lineHeight*(r.text.length-1))):l+=a.top;const{titleX:c,titleY:u,maxWidth:d,rotation:f}=Que(this,l,n,s);Hh(t,r.text,0,0,o,{color:r.color,maxWidth:d,rotation:f,textAlign:Xue(s,n,i),textBaseline:"middle",translation:[c,u]})}draw(t){this._isVisible()&&(this.drawBackground(),this.drawGrid(t),this.drawBorder(),this.drawTitle(),this.drawLabels(t))}_layers(){const t=this.options,n=t.ticks&&t.ticks.z||0,r=Oe(t.grid&&t.grid.z,-1),i=Oe(t.border&&t.border.z,0);return!this._isVisible()||this.draw!==$l.prototype.draw?[{z:n,draw:o=>{this.draw(o)}}]:[{z:r,draw:o=>{this.drawBackground(),this.drawGrid(o),this.drawTitle()}},{z:i,draw:()=>{this.drawBorder()}},{z:n,draw:o=>{this.drawLabels(o)}}]}getMatchingVisibleMetas(t){const n=this.chart.getSortedVisibleDatasetMetas(),r=this.axis+"AxisID",i=[];let o,a;for(o=0,a=n.length;o<a;++o){const s=n[o];s[r]===this.id&&(!t||s.type===t)&&i.push(s)}return i}_resolveTickFontOptions(t){const n=this.options.ticks.setContext(this.getContext(t));return cr(n.font)}_maxDigits(){const t=this._resolveTickFontOptions(0).lineHeight;return(this.isHorizontal()?this.width:this.height)/t}}class im{constructor(t,n,r){this.type=t,this.scope=n,this.override=r,this.items=Object.create(null)}isForType(t){return Object.prototype.isPrototypeOf.call(this.type.prototype,t.prototype)}register(t){const n=Object.getPrototypeOf(t);let r;ede(n)&&(r=this.register(n));const i=this.items,o=t.id,a=this.scope+"."+o;if(!o)throw new Error("class does not have id: "+t);return o in i||(i[o]=t,Zue(t,a,r),this.override&&zt.override(t.id,t.overrides)),a}get(t){return this.items[t]}unregister(t){const n=this.items,r=t.id,i=this.scope;r in n&&delete n[r],i&&r in zt[i]&&(delete zt[i][r],this.override&&delete fs[r])}}function Zue(e,t,n){const r=Ru(Object.create(null),[n?zt.get(n):{},zt.get(t),e.defaults]);zt.set(t,r),e.defaultRoutes&&Jue(t,e.defaultRoutes),e.descriptors&&zt.describe(t,e.descriptors)}function Jue(e,t){Object.keys(t).forEach(n=>{const r=n.split("."),i=r.pop(),o=[e].concat(r).join("."),a=t[n].split("."),s=a.pop(),l=a.join(".");zt.route(o,i,l,s)})}function ede(e){return"id"in e&&"defaults"in e}class tde{constructor(){this.controllers=new im(Zh,"datasets",!0),this.elements=new im(va,"elements"),this.plugins=new im(Object,"plugins"),this.scales=new im($l,"scales"),this._typedRegistries=[this.controllers,this.scales,this.elements]}add(...t){this._each("register",t)}remove(...t){this._each("unregister",t)}addControllers(...t){this._each("register",t,this.controllers)}addElements(...t){this._each("register",t,this.elements)}addPlugins(...t){this._each("register",t,this.plugins)}addScales(...t){this._each("register",t,this.scales)}getController(t){return this._get(t,this.controllers,"controller")}getElement(t){return this._get(t,this.elements,"element")}getPlugin(t){return this._get(t,this.plugins,"plugin")}getScale(t){return this._get(t,this.scales,"scale")}removeControllers(...t){this._each("unregister",t,this.controllers)}removeElements(...t){this._each("unregister",t,this.elements)}removePlugins(...t){this._each("unregister",t,this.plugins)}removeScales(...t){this._each("unregister",t,this.scales)}_each(t,n,r){[...n].forEach(i=>{const o=r||this._getRegistryForType(i);r||o.isForType(i)||o===this.plugins&&i.id?this._exec(t,o,i):et(i,a=>{const s=r||this._getRegistryForType(a);this._exec(t,s,a)})})}_exec(t,n,r){const i=o1(t);bt(r["before"+i],[],r),n[t](r),bt(r["after"+i],[],r)}_getRegistryForType(t){for(let n=0;n<this._typedRegistries.length;n++){const r=this._typedRegistries[n];if(r.isForType(t))return r}return this.plugins}_get(t,n,r){const i=n.get(t);if(i===void 0)throw new Error('"'+t+'" is not a registered '+r+".");return i}}var Yi=new tde;class nde{constructor(){this._init=[]}notify(t,n,r,i){n==="beforeInit"&&(this._init=this._createDescriptors(t,!0),this._notify(this._init,t,"install"));const o=i?this._descriptors(t).filter(i):this._descriptors(t),a=this._notify(o,t,n,r);return n==="afterDestroy"&&(this._notify(o,t,"stop"),this._notify(this._init,t,"uninstall")),a}_notify(t,n,r,i){i=i||{};for(const o of t){const a=o.plugin,s=a[r],l=[n,i,o.options];if(bt(s,l,a)===!1&&i.cancelable)return!1}return!0}invalidate(){Ke(this._cache)||(this._oldCache=this._cache,this._cache=void 0)}_descriptors(t){if(this._cache)return this._cache;const n=this._cache=this._createDescriptors(t);return this._notifyStateChanges(t),n}_createDescriptors(t,n){const r=t&&t.config,i=Oe(r.options&&r.options.plugins,{}),o=rde(r);return i===!1&&!n?[]:ode(t,o,i,n)}_notifyStateChanges(t){const n=this._oldCache||[],r=this._cache,i=(o,a)=>o.filter(s=>!a.some(l=>s.plugin.id===l.plugin.id));this._notify(i(n,r),t,"stop"),this._notify(i(r,n),t,"start")}}function rde(e){const t={},n=[],r=Object.keys(Yi.plugins.items);for(let o=0;o<r.length;o++)n.push(Yi.getPlugin(r[o]));const i=e.plugins||[];for(let o=0;o<i.length;o++){const a=i[o];n.indexOf(a)===-1&&(n.push(a),t[a.id]=!0)}return{plugins:n,localIds:t}}function ide(e,t){return!t&&e===!1?null:e===!0?{}:e}function ode(e,{plugins:t,localIds:n},r,i){const o=[],a=e.getContext();for(const s of t){const l=s.id,c=ide(r[l],i);c!==null&&o.push({plugin:s,options:ade(e.config,{plugin:s,local:n[l]},c,a)})}return o}function ade(e,{plugin:t,local:n},r,i){const o=e.pluginScopeKeys(t),a=e.getOptionScopes(r,o);return n&&t.defaults&&a.push(t.defaults),e.createResolver(a,i,[""],{scriptable:!1,indexable:!1,allKeys:!0})}function A1(e,t){const n=zt.datasets[e]||{};return((t.datasets||{})[e]||{}).indexAxis||t.indexAxis||n.indexAxis||"x"}function sde(e,t){let n=e;return e==="_index_"?n=t:e==="_value_"&&(n=t==="x"?"y":"x"),n}function lde(e,t){return e===t?"_index_":"_value_"}function VI(e){if(e==="x"||e==="y"||e==="r")return e}function cde(e){if(e==="top"||e==="bottom")return"x";if(e==="left"||e==="right")return"y"}function T1(e,...t){if(VI(e))return e;for(const n of t){const r=n.axis||cde(n.position)||e.length>1&&VI(e[0].toLowerCase());if(r)return r}throw new Error(`Cannot determine type of '${e}' axis. Please provide 'axis' or 'position' option.`)}function HI(e,t,n){if(n[t+"AxisID"]===e)return{axis:t}}function ude(e,t){if(t.data&&t.data.datasets){const n=t.data.datasets.filter(r=>r.xAxisID===e||r.yAxisID===e);if(n.length)return HI(e,"x",n[0])||HI(e,"y",n[0])}return{}}function dde(e,t){const n=fs[e.type]||{scales:{}},r=t.scales||{},i=A1(e.type,t),o=Object.create(null);return Object.keys(r).forEach(a=>{const s=r[a];if(!Me(s))return console.error(`Invalid scale configuration for scale: ${a}`);if(s._proxy)return console.warn(`Ignoring resolver passed as options for scale: ${a}`);const l=T1(a,s,ude(a,e),zt.scales[s.type]),c=lde(l,i),u=n.scales||{};o[a]=$u(Object.create(null),[{axis:l},s,u[l],u[c]])}),e.data.datasets.forEach(a=>{const s=a.type||e.type,l=a.indexAxis||A1(s,t),u=(fs[s]||{}).scales||{};Object.keys(u).forEach(d=>{const f=sde(d,l),p=a[f+"AxisID"]||f;o[p]=o[p]||Object.create(null),$u(o[p],[{axis:f},r[p],u[d]])})}),Object.keys(o).forEach(a=>{const s=o[a];$u(s,[zt.scales[s.type],zt.scale])}),o}function YI(e){const t=e.options||(e.options={});t.plugins=Oe(t.plugins,{}),t.scales=dde(e,t)}function UI(e){return e=e||{},e.datasets=e.datasets||[],e.labels=e.labels||[],e}function fde(e){return e=e||{},e.data=UI(e.data),YI(e),e}const KI=new Map,qI=new Set;function om(e,t){let n=KI.get(e);return n||(n=t(),KI.set(e,n),qI.add(n)),n}const Ju=(e,t,n)=>{const r=cs(t,n);r!==void 0&&e.add(r)};class pde{constructor(t){this._config=fde(t),this._scopeCache=new Map,this._resolverCache=new Map}get platform(){return this._config.platform}get type(){return this._config.type}set type(t){this._config.type=t}get data(){return this._config.data}set data(t){this._config.data=UI(t)}get options(){return this._config.options}set options(t){this._config.options=t}get plugins(){return this._config.plugins}update(){const t=this._config;this.clearCache(),YI(t)}clearCache(){this._scopeCache.clear(),this._resolverCache.clear()}datasetScopeKeys(t){return om(t,()=>[[`datasets.${t}`,""]])}datasetAnimationScopeKeys(t,n){return om(`${t}.transition.${n}`,()=>[[`datasets.${t}.transitions.${n}`,`transitions.${n}`],[`datasets.${t}`,""]])}datasetElementScopeKeys(t,n){return om(`${t}-${n}`,()=>[[`datasets.${t}.elements.${n}`,`datasets.${t}`,`elements.${n}`,""]])}pluginScopeKeys(t){const n=t.id,r=this.type;return om(`${r}-plugin-${n}`,()=>[[`plugins.${n}`,...t.additionalOptionScopes||[]]])}_cachedScopes(t,n){const r=this._scopeCache;let i=r.get(t);return(!i||n)&&(i=new Map,r.set(t,i)),i}getOptionScopes(t,n,r){const{options:i,type:o}=this,a=this._cachedScopes(t,r),s=a.get(n);if(s)return s;const l=new Set;n.forEach(u=>{t&&(l.add(t),u.forEach(d=>Ju(l,t,d))),u.forEach(d=>Ju(l,i,d)),u.forEach(d=>Ju(l,fs[o]||{},d)),u.forEach(d=>Ju(l,zt,d)),u.forEach(d=>Ju(l,d1,d))});const c=Array.from(l);return c.length===0&&c.push(Object.create(null)),qI.has(n)&&a.set(n,c),c}chartOptionScopes(){const{options:t,type:n}=this;return[t,fs[n]||{},zt.datasets[n]||{},{type:n},zt,d1]}resolveNamedOptions(t,n,r,i=[""]){const o={$shared:!0},{resolver:a,subPrefixes:s}=GI(this._resolverCache,t,i);let l=a;if(mde(a,n)){o.$shared=!1,r=ha(r)?r():r;const c=this.createResolver(t,r,s);l=Fl(a,r,c)}for(const c of n)o[c]=l[c];return o}createResolver(t,n,r=[""],i){const{resolver:o}=GI(this._resolverCache,t,r);return Me(n)?Fl(o,n,void 0,i):o}}function GI(e,t,n){let r=e.get(t);r||(r=new Map,e.set(t,r));const i=n.join();let o=r.get(i);return o||(o={resolver:v1(t,n),subPrefixes:n.filter(s=>!s.toLowerCase().includes("hover"))},r.set(i,o)),o}const hde=e=>Me(e)&&Object.getOwnPropertyNames(e).some(t=>ha(e[t]));function mde(e,t){const{isScriptable:n,isIndexable:r}=tI(e);for(const i of t){const o=n(i),a=r(i),s=(a||o)&&e[i];if(o&&(ha(s)||hde(s))||a&&hn(s))return!0}return!1}var gde="4.5.0";const vde=["top","bottom","left","right","chartArea"];function XI(e,t){return e==="top"||e==="bottom"||vde.indexOf(e)===-1&&t==="x"}function QI(e,t){return function(n,r){return n[e]===r[e]?n[t]-r[t]:n[e]-r[e]}}function ZI(e){const t=e.chart,n=t.options.animation;t.notifyPlugins("afterRender"),bt(n&&n.onComplete,[e],t)}function yde(e){const t=e.chart,n=t.options.animation;bt(n&&n.onProgress,[e],t)}function JI(e){return x1()&&typeof e=="string"?e=document.getElementById(e):e&&e.length&&(e=e[0]),e&&e.canvas&&(e=e.canvas),e}const am={},e4=e=>{const t=JI(e);return Object.values(am).filter(n=>n.canvas===t).pop()};function bde(e,t,n){const r=Object.keys(e);for(const i of r){const o=+i;if(o>=t){const a=e[i];delete e[i],(n>0||o>t)&&(e[o+n]=a)}}}function xde(e,t,n,r){return!n||e.type==="mouseout"?null:r?t:e}let Bn=class{static defaults=zt;static instances=am;static overrides=fs;static registry=Yi;static version=gde;static getChart=e4;static register(...t){Yi.add(...t),t4()}static unregister(...t){Yi.remove(...t),t4()}constructor(t,n){const r=this.config=new pde(n),i=JI(t),o=e4(i);if(o)throw new Error("Canvas is already in use. Chart with ID '"+o.id+"' must be destroyed before the canvas with ID '"+o.canvas.id+"' can be reused.");const a=r.createResolver(r.chartOptionScopes(),this.getContext());this.platform=new(r.platform||Rue(i)),this.platform.updateConfig(r);const s=this.platform.acquireContext(i,a.aspectRatio),l=s&&s.canvas,c=l&&l.height,u=l&&l.width;if(this.id=fle(),this.ctx=s,this.canvas=l,this.width=u,this.height=c,this._options=a,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 nde,this.$proxies={},this._hiddenIndices={},this.attached=!1,this._animationsDisabled=void 0,this.$context=void 0,this._doResize=Tle(d=>this.update(d),a.resizeDelay||0),this._dataChanges=[],am[this.id]=this,!s||!l){console.error("Failed to create chart: can't acquire context from the given item");return}Mo.listen(this,"complete",ZI),Mo.listen(this,"progress",yde),this._initialize(),this.attached&&this.update()}get aspectRatio(){const{options:{aspectRatio:t,maintainAspectRatio:n},width:r,height:i,_aspectRatio:o}=this;return Ke(t)?n&&o?o:i?r/i:null:t}get data(){return this.config.data}set data(t){this.config.data=t}get options(){return this._options}set options(t){this.config.options=t}get registry(){return Yi}_initialize(){return this.notifyPlugins("beforeInit"),this.options.responsive?this.resize():lI(this,this.options.devicePixelRatio),this.bindEvents(),this.notifyPlugins("afterInit"),this}clear(){return ZM(this.canvas,this.ctx),this}stop(){return Mo.stop(this),this}resize(t,n){Mo.running(this)?this._resizeBeforeDraw={width:t,height:n}:this._resize(t,n)}_resize(t,n){const r=this.options,i=this.canvas,o=r.maintainAspectRatio&&this.aspectRatio,a=this.platform.getMaximumSize(i,t,n,o),s=r.devicePixelRatio||this.platform.getDevicePixelRatio(),l=this.width?"resize":"attach";this.width=a.width,this.height=a.height,this._aspectRatio=this.aspectRatio,lI(this,s,!0)&&(this.notifyPlugins("resize",{size:a}),bt(r.onResize,[this,a],this),this.attached&&this._doResize(l)&&this.render())}ensureScalesHaveIDs(){const n=this.options.scales||{};et(n,(r,i)=>{r.id=i})}buildOrUpdateScales(){const t=this.options,n=t.scales,r=this.scales,i=Object.keys(r).reduce((a,s)=>(a[s]=!1,a),{});let o=[];n&&(o=o.concat(Object.keys(n).map(a=>{const s=n[a],l=T1(a,s),c=l==="r",u=l==="x";return{options:s,dposition:c?"chartArea":u?"bottom":"left",dtype:c?"radialLinear":u?"category":"linear"}}))),et(o,a=>{const s=a.options,l=s.id,c=T1(l,s),u=Oe(s.type,a.dtype);(s.position===void 0||XI(s.position,c)!==XI(a.dposition))&&(s.position=a.dposition),i[l]=!0;let d=null;if(l in r&&r[l].type===u)d=r[l];else{const f=Yi.getScale(u);d=new f({id:l,type:u,ctx:this.ctx,chart:this}),r[d.id]=d}d.init(s,t)}),et(i,(a,s)=>{a||delete r[s]}),et(r,a=>{ga.configure(this,a,a.options),ga.addBox(this,a)})}_updateMetasets(){const t=this._metasets,n=this.data.datasets.length,r=t.length;if(t.sort((i,o)=>i.index-o.index),r>n){for(let i=n;i<r;++i)this._destroyDatasetMeta(i);t.splice(n,r-n)}this._sortedMetasets=t.slice(0).sort(QI("order","index"))}_removeUnreferencedMetasets(){const{_metasets:t,data:{datasets:n}}=this;t.length>n.length&&delete this._stacks,t.forEach((r,i)=>{n.filter(o=>o===r._dataset).length===0&&this._destroyDatasetMeta(i)})}buildOrUpdateControllers(){const t=[],n=this.data.datasets;let r,i;for(this._removeUnreferencedMetasets(),r=0,i=n.length;r<i;r++){const o=n[r];let a=this.getDatasetMeta(r);const s=o.type||this.config.type;if(a.type&&a.type!==s&&(this._destroyDatasetMeta(r),a=this.getDatasetMeta(r)),a.type=s,a.indexAxis=o.indexAxis||A1(s,this.options),a.order=o.order||0,a.index=r,a.label=""+o.label,a.visible=this.isDatasetVisible(r),a.controller)a.controller.updateIndex(r),a.controller.linkScales();else{const l=Yi.getController(s),{datasetElementType:c,dataElementType:u}=zt.datasets[s];Object.assign(l,{dataElementType:Yi.getElement(u),datasetElementType:c&&Yi.getElement(c)}),a.controller=new l(this,r),t.push(a.controller)}}return this._updateMetasets(),t}_resetElements(){et(this.data.datasets,(t,n)=>{this.getDatasetMeta(n).controller.reset()},this)}reset(){this._resetElements(),this.notifyPlugins("reset")}update(t){const n=this.config;n.update();const r=this._options=n.createResolver(n.chartOptionScopes(),this.getContext()),i=this._animationsDisabled=!r.animation;if(this._updateScales(),this._checkEventBindings(),this._updateHiddenIndices(),this._plugins.invalidate(),this.notifyPlugins("beforeUpdate",{mode:t,cancelable:!0})===!1)return;const o=this.buildOrUpdateControllers();this.notifyPlugins("beforeElementsUpdate");let a=0;for(let c=0,u=this.data.datasets.length;c<u;c++){const{controller:d}=this.getDatasetMeta(c),f=!i&&o.indexOf(d)===-1;d.buildOrUpdateElements(f),a=Math.max(+d.getMaxOverflow(),a)}a=this._minPadding=r.layout.autoPadding?a:0,this._updateLayout(a),i||et(o,c=>{c.reset()}),this._updateDatasets(t),this.notifyPlugins("afterUpdate",{mode:t}),this._layers.sort(QI("z","_idx"));const{_active:s,_lastEvent:l}=this;l?this._eventHandler(l,!0):s.length&&this._updateHoverStyles(s,s,!0),this.render()}_updateScales(){et(this.scales,t=>{ga.removeBox(this,t)}),this.ensureScalesHaveIDs(),this.buildOrUpdateScales()}_checkEventBindings(){const t=this.options,n=new Set(Object.keys(this._listeners)),r=new Set(t.events);(!MM(n,r)||!!this._responsiveListeners!==t.responsive)&&(this.unbindEvents(),this.bindEvents())}_updateHiddenIndices(){const{_hiddenIndices:t}=this,n=this._getUniformDataChanges()||[];for(const{method:r,start:i,count:o}of n){const a=r==="_removeElements"?-o:o;bde(t,i,a)}}_getUniformDataChanges(){const t=this._dataChanges;if(!t||!t.length)return;this._dataChanges=[];const n=this.data.datasets.length,r=o=>new Set(t.filter(a=>a[0]===o).map((a,s)=>s+","+a.splice(1).join(","))),i=r(0);for(let o=1;o<n;o++)if(!MM(i,r(o)))return;return Array.from(i).map(o=>o.split(",")).map(o=>({method:o[1],start:+o[2],count:+o[3]}))}_updateLayout(t){if(this.notifyPlugins("beforeLayout",{cancelable:!0})===!1)return;ga.update(this,this.width,this.height,t);const n=this.chartArea,r=n.width<=0||n.height<=0;this._layers=[],et(this.boxes,i=>{r&&i.position==="chartArea"||(i.configure&&i.configure(),this._layers.push(...i._layers()))},this),this._layers.forEach((i,o)=>{i._idx=o}),this.notifyPlugins("afterLayout")}_updateDatasets(t){if(this.notifyPlugins("beforeDatasetsUpdate",{mode:t,cancelable:!0})!==!1){for(let n=0,r=this.data.datasets.length;n<r;++n)this.getDatasetMeta(n).controller.configure();for(let n=0,r=this.data.datasets.length;n<r;++n)this._updateDataset(n,ha(t)?t({datasetIndex:n}):t);this.notifyPlugins("afterDatasetsUpdate",{mode:t})}}_updateDataset(t,n){const r=this.getDatasetMeta(t),i={meta:r,index:t,mode:n,cancelable:!0};this.notifyPlugins("beforeDatasetUpdate",i)!==!1&&(r.controller._update(n),i.cancelable=!1,this.notifyPlugins("afterDatasetUpdate",i))}render(){this.notifyPlugins("beforeRender",{cancelable:!0})!==!1&&(Mo.has(this)?this.attached&&!Mo.running(this)&&Mo.start(this):(this.draw(),ZI({chart:this})))}draw(){let t;if(this._resizeBeforeDraw){const{width:r,height:i}=this._resizeBeforeDraw;this._resizeBeforeDraw=null,this._resize(r,i)}if(this.clear(),this.width<=0||this.height<=0||this.notifyPlugins("beforeDraw",{cancelable:!0})===!1)return;const n=this._layers;for(t=0;t<n.length&&n[t].z<=0;++t)n[t].draw(this.chartArea);for(this._drawDatasets();t<n.length;++t)n[t].draw(this.chartArea);this.notifyPlugins("afterDraw")}_getSortedDatasetMetas(t){const n=this._sortedMetasets,r=[];let i,o;for(i=0,o=n.length;i<o;++i){const a=n[i];(!t||a.visible)&&r.push(a)}return r}getSortedVisibleDatasetMetas(){return this._getSortedDatasetMetas(!0)}_drawDatasets(){if(this.notifyPlugins("beforeDatasetsDraw",{cancelable:!0})===!1)return;const t=this.getSortedVisibleDatasetMetas();for(let n=t.length-1;n>=0;--n)this._drawDataset(t[n]);this.notifyPlugins("afterDatasetsDraw")}_drawDataset(t){const n=this.ctx,r={meta:t,index:t.index,cancelable:!0},i=Lce(this,t);this.notifyPlugins("beforeDatasetDraw",r)!==!1&&(i&&h1(n,i),t.controller.draw(),i&&m1(n),r.cancelable=!1,this.notifyPlugins("afterDatasetDraw",r))}isPointInArea(t){return Uu(t,this.chartArea,this._minPadding)}getElementsAtEventForMode(t,n,r,i){const o=vue.modes[n];return typeof o=="function"?o(this,t,r,i):[]}getDatasetMeta(t){const n=this.data.datasets[t],r=this._metasets;let i=r.filter(o=>o&&o._dataset===n).pop();return i||(i={type:null,data:[],dataset:null,controller:null,hidden:null,xAxisID:null,yAxisID:null,order:n&&n.order||0,index:t,_dataset:n,_parsed:[],_sorted:!1},r.push(i)),i}getContext(){return this.$context||(this.$context=hs(null,{chart:this,type:"chart"}))}getVisibleDatasetCount(){return this.getSortedVisibleDatasetMetas().length}isDatasetVisible(t){const n=this.data.datasets[t];if(!n)return!1;const r=this.getDatasetMeta(t);return typeof r.hidden=="boolean"?!r.hidden:!n.hidden}setDatasetVisibility(t,n){const r=this.getDatasetMeta(t);r.hidden=!n}toggleDataVisibility(t){this._hiddenIndices[t]=!this._hiddenIndices[t]}getDataVisibility(t){return!this._hiddenIndices[t]}_updateVisibility(t,n,r){const i=r?"show":"hide",o=this.getDatasetMeta(t),a=o.controller._resolveAnimations(void 0,i);Bu(n)?(o.data[n].hidden=!r,this.update()):(this.setDatasetVisibility(t,r),a.update(o,{visible:r}),this.update(s=>s.datasetIndex===t?i:void 0))}hide(t,n){this._updateVisibility(t,n,!1)}show(t,n){this._updateVisibility(t,n,!0)}_destroyDatasetMeta(t){const n=this._metasets[t];n&&n.controller&&n.controller._destroy(),delete this._metasets[t]}_stop(){let t,n;for(this.stop(),Mo.remove(this),t=0,n=this.data.datasets.length;t<n;++t)this._destroyDatasetMeta(t)}destroy(){this.notifyPlugins("beforeDestroy");const{canvas:t,ctx:n}=this;this._stop(),this.config.clearCache(),t&&(this.unbindEvents(),ZM(t,n),this.platform.releaseContext(n),this.canvas=null,this.ctx=null),delete am[this.id],this.notifyPlugins("afterDestroy")}toBase64Image(...t){return this.canvas.toDataURL(...t)}bindEvents(){this.bindUserEvents(),this.options.responsive?this.bindResponsiveEvents():this.attached=!0}bindUserEvents(){const t=this._listeners,n=this.platform,r=(o,a)=>{n.addEventListener(this,o,a),t[o]=a},i=(o,a,s)=>{o.offsetX=a,o.offsetY=s,this._eventHandler(o)};et(this.options.events,o=>r(o,i))}bindResponsiveEvents(){this._responsiveListeners||(this._responsiveListeners={});const t=this._responsiveListeners,n=this.platform,r=(l,c)=>{n.addEventListener(this,l,c),t[l]=c},i=(l,c)=>{t[l]&&(n.removeEventListener(this,l,c),delete t[l])},o=(l,c)=>{this.canvas&&this.resize(l,c)};let a;const s=()=>{i("attach",s),this.attached=!0,this.resize(),r("resize",o),r("detach",a)};a=()=>{this.attached=!1,i("resize",o),this._stop(),this._resize(0,0),r("attach",s)},n.isAttached(this.canvas)?s():a()}unbindEvents(){et(this._listeners,(t,n)=>{this.platform.removeEventListener(this,n,t)}),this._listeners={},et(this._responsiveListeners,(t,n)=>{this.platform.removeEventListener(this,n,t)}),this._responsiveListeners=void 0}updateHoverStyle(t,n,r){const i=r?"set":"remove";let o,a,s,l;for(n==="dataset"&&(o=this.getDatasetMeta(t[0].datasetIndex),o.controller["_"+i+"DatasetHoverStyle"]()),s=0,l=t.length;s<l;++s){a=t[s];const c=a&&this.getDatasetMeta(a.datasetIndex).controller;c&&c[i+"HoverStyle"](a.element,a.datasetIndex,a.index)}}getActiveElements(){return this._active||[]}setActiveElements(t){const n=this._active||[],r=t.map(({datasetIndex:o,index:a})=>{const s=this.getDatasetMeta(o);if(!s)throw new Error("No dataset found at index "+o);return{datasetIndex:o,element:s.data[a],index:a}});!Bh(r,n)&&(this._active=r,this._lastEvent=null,this._updateHoverStyles(r,n))}notifyPlugins(t,n,r){return this._plugins.notify(this,t,n,r)}isPluginEnabled(t){return this._plugins._cache.filter(n=>n.plugin.id===t).length===1}_updateHoverStyles(t,n,r){const i=this.options.hover,o=(l,c)=>l.filter(u=>!c.some(d=>u.datasetIndex===d.datasetIndex&&u.index===d.index)),a=o(n,t),s=r?t:o(t,n);a.length&&this.updateHoverStyle(a,i.mode,!1),s.length&&i.mode&&this.updateHoverStyle(s,i.mode,!0)}_eventHandler(t,n){const r={event:t,replay:n,cancelable:!0,inChartArea:this.isPointInArea(t)},i=a=>(a.options.events||this.options.events).includes(t.native.type);if(this.notifyPlugins("beforeEvent",r,i)===!1)return;const o=this._handleEvent(t,n,r.inChartArea);return r.cancelable=!1,this.notifyPlugins("afterEvent",r,i),(o||r.changed)&&this.render(),this}_handleEvent(t,n,r){const{_active:i=[],options:o}=this,a=n,s=this._getActiveElements(t,i,r,a),l=yle(t),c=xde(t,this._lastEvent,r,l);r&&(this._lastEvent=null,bt(o.onHover,[t,s,this],this),l&&bt(o.onClick,[t,s,this],this));const u=!Bh(s,i);return(u||n)&&(this._active=s,this._updateHoverStyles(s,i,n)),this._lastEvent=c,u}_getActiveElements(t,n,r,i){if(t.type==="mouseout")return[];if(!r)return n;const o=this.options.hover;return this.getElementsAtEventForMode(t,o.mode,o,i)}};function t4(){return et(Bn.instances,e=>e._plugins.invalidate())}function wde(e,t,n){const{startAngle:r,x:i,y:o,outerRadius:a,innerRadius:s,options:l}=t,{borderWidth:c,borderJoinStyle:u}=l,d=Math.min(c/a,si(r-n));if(e.beginPath(),e.arc(i,o,a-c/2,r+d/2,n-d/2),s>0){const f=Math.min(c/s,si(r-n));e.arc(i,o,s+c/2,n-f/2,r+f/2,!0)}else{const f=Math.min(c/2,a*si(r-n));if(u==="round")e.arc(i,o,f,n-st/2,r+st/2,!0);else if(u==="bevel"){const p=2*f*f,m=-p*Math.cos(n+st/2)+i,g=-p*Math.sin(n+st/2)+o,v=p*Math.cos(r+st/2)+i,x=p*Math.sin(r+st/2)+o;e.lineTo(m,g),e.lineTo(v,x)}}e.closePath(),e.moveTo(0,0),e.rect(0,0,e.canvas.width,e.canvas.height),e.clip("evenodd")}function _de(e,t,n){const{startAngle:r,pixelMargin:i,x:o,y:a,outerRadius:s,innerRadius:l}=t;let c=i/s;e.beginPath(),e.arc(o,a,s,r-c,n+c),l>i?(c=i/l,e.arc(o,a,l,n+c,r-c,!0)):e.arc(o,a,i,n+an,r-an),e.closePath(),e.clip()}function Ede(e){return g1(e,["outerStart","outerEnd","innerStart","innerEnd"])}function Sde(e,t,n,r){const i=Ede(e.options.borderRadius),o=(n-t)/2,a=Math.min(o,r*t/2),s=l=>{const c=(n-Math.min(o,l))*r/2;return $n(l,0,Math.min(o,c))};return{outerStart:s(i.outerStart),outerEnd:s(i.outerEnd),innerStart:$n(i.innerStart,0,a),innerEnd:$n(i.innerEnd,0,a)}}function Bl(e,t,n,r){return{x:n+e*Math.cos(t),y:r+e*Math.sin(t)}}function sm(e,t,n,r,i,o){const{x:a,y:s,startAngle:l,pixelMargin:c,innerRadius:u}=t,d=Math.max(t.outerRadius+r+n-c,0),f=u>0?u+r+n+c:0;let p=0;const m=i-l;if(r){const M=u>0?u-r:0,R=d>0?d-r:0,B=(M+R)/2,V=B!==0?m*B/(B+r):m;p=(m-V)/2}const g=Math.max(.001,m*d-n/st)/d,v=(m-g)/2,x=l+v+p,_=i-v-p,{outerStart:w,outerEnd:y,innerStart:E,innerEnd:S}=Sde(t,f,d,_-x),P=d-w,D=d-y,T=x+w/P,I=_-y/D,A=f+E,C=f+S,j=x+E/A,N=_-S/C;if(e.beginPath(),o){const M=(T+I)/2;if(e.arc(a,s,d,T,M),e.arc(a,s,d,M,I),y>0){const z=Bl(D,I,a,s);e.arc(z.x,z.y,y,I,_+an)}const R=Bl(C,_,a,s);if(e.lineTo(R.x,R.y),S>0){const z=Bl(C,N,a,s);e.arc(z.x,z.y,S,_+an,N+Math.PI)}const B=(_-S/f+(x+E/f))/2;if(e.arc(a,s,f,_-S/f,B,!0),e.arc(a,s,f,B,x+E/f,!0),E>0){const z=Bl(A,j,a,s);e.arc(z.x,z.y,E,j+Math.PI,x-an)}const V=Bl(P,x,a,s);if(e.lineTo(V.x,V.y),w>0){const z=Bl(P,T,a,s);e.arc(z.x,z.y,w,x-an,T)}}else{e.moveTo(a,s);const M=Math.cos(T)*d+a,R=Math.sin(T)*d+s;e.lineTo(M,R);const B=Math.cos(I)*d+a,V=Math.sin(I)*d+s;e.lineTo(B,V)}e.closePath()}function Ode(e,t,n,r,i){const{fullCircles:o,startAngle:a,circumference:s}=t;let l=t.endAngle;if(o){sm(e,t,n,r,l,i);for(let c=0;c<o;++c)e.fill();isNaN(s)||(l=a+(s%Ft||Ft))}return sm(e,t,n,r,l,i),e.fill(),l}function Cde(e,t,n,r,i){const{fullCircles:o,startAngle:a,circumference:s,options:l}=t,{borderWidth:c,borderJoinStyle:u,borderDash:d,borderDashOffset:f,borderRadius:p}=l,m=l.borderAlign==="inner";if(!c)return;e.setLineDash(d||[]),e.lineDashOffset=f,m?(e.lineWidth=c*2,e.lineJoin=u||"round"):(e.lineWidth=c,e.lineJoin=u||"bevel");let g=t.endAngle;if(o){sm(e,t,n,r,g,i);for(let v=0;v<o;++v)e.stroke();isNaN(s)||(g=a+(s%Ft||Ft))}m&&_de(e,t,g),l.selfJoin&&g-a>=st&&p===0&&u!=="miter"&&wde(e,t,g),o||(sm(e,t,n,r,g,i),e.stroke())}class lm extends va{static id="arc";static defaults={borderAlign:"center",borderColor:"#fff",borderDash:[],borderDashOffset:0,borderJoinStyle:void 0,borderRadius:0,borderWidth:2,offset:0,spacing:0,angle:void 0,circular:!0,selfJoin:!1};static defaultRoutes={backgroundColor:"backgroundColor"};static descriptors={_scriptable:!0,_indexable:t=>t!=="borderDash"};circumference;endAngle;fullCircles;innerRadius;outerRadius;pixelMargin;startAngle;constructor(t){super(),this.options=void 0,this.circumference=void 0,this.startAngle=void 0,this.endAngle=void 0,this.innerRadius=void 0,this.outerRadius=void 0,this.pixelMargin=0,this.fullCircles=0,t&&Object.assign(this,t)}inRange(t,n,r){const i=this.getProps(["x","y"],r),{angle:o,distance:a}=$M(i,{x:t,y:n}),{startAngle:s,endAngle:l,innerRadius:c,outerRadius:u,circumference:d}=this.getProps(["startAngle","endAngle","innerRadius","outerRadius","circumference"],r),f=(this.options.spacing+this.options.borderWidth)/2,p=Oe(d,l-s),m=Vu(o,s,l)&&s!==l,g=p>=Ft||m,v=ma(a,c+f,u+f);return g&&v}getCenterPoint(t){const{x:n,y:r,startAngle:i,endAngle:o,innerRadius:a,outerRadius:s}=this.getProps(["x","y","startAngle","endAngle","innerRadius","outerRadius"],t),{offset:l,spacing:c}=this.options,u=(i+o)/2,d=(a+s+c+l)/2;return{x:n+Math.cos(u)*d,y:r+Math.sin(u)*d}}tooltipPosition(t){return this.getCenterPoint(t)}draw(t){const{options:n,circumference:r}=this,i=(n.offset||0)/4,o=(n.spacing||0)/2,a=n.circular;if(this.pixelMargin=n.borderAlign==="inner"?.33:0,this.fullCircles=r>Ft?Math.floor(r/Ft):0,r===0||this.innerRadius<0||this.outerRadius<0)return;t.save();const s=(this.startAngle+this.endAngle)/2;t.translate(Math.cos(s)*i,Math.sin(s)*i);const l=1-Math.sin(Math.min(st,r||0)),c=i*l;t.fillStyle=n.backgroundColor,t.strokeStyle=n.borderColor,Ode(t,this,c,o,a),Cde(t,this,c,o,a),t.restore()}}function n4(e,t,n=t){e.lineCap=Oe(n.borderCapStyle,t.borderCapStyle),e.setLineDash(Oe(n.borderDash,t.borderDash)),e.lineDashOffset=Oe(n.borderDashOffset,t.borderDashOffset),e.lineJoin=Oe(n.borderJoinStyle,t.borderJoinStyle),e.lineWidth=Oe(n.borderWidth,t.borderWidth),e.strokeStyle=Oe(n.borderColor,t.borderColor)}function kde(e,t,n){e.lineTo(n.x,n.y)}function Pde(e){return e.stepped?Yle:e.tension||e.cubicInterpolationMode==="monotone"?Ule:kde}function r4(e,t,n={}){const r=e.length,{start:i=0,end:o=r-1}=n,{start:a,end:s}=t,l=Math.max(i,a),c=Math.min(o,s),u=i<a&&o<a||i>s&&o>s;return{count:r,start:l,loop:t.loop,ilen:c<l&&!u?r+c-l:c-l}}function Dde(e,t,n,r){const{points:i,options:o}=t,{count:a,start:s,loop:l,ilen:c}=r4(i,n,r),u=Pde(o);let{move:d=!0,reverse:f}=r||{},p,m,g;for(p=0;p<=c;++p)m=i[(s+(f?c-p:p))%a],!m.skip&&(d?(e.moveTo(m.x,m.y),d=!1):u(e,g,m,f,o.stepped),g=m);return l&&(m=i[(s+(f?c:0))%a],u(e,g,m,f,o.stepped)),!!l}function Ade(e,t,n,r){const i=t.points,{count:o,start:a,ilen:s}=r4(i,n,r),{move:l=!0,reverse:c}=r||{};let u=0,d=0,f,p,m,g,v,x;const _=y=>(a+(c?s-y:y))%o,w=()=>{g!==v&&(e.lineTo(u,v),e.lineTo(u,g),e.lineTo(u,x))};for(l&&(p=i[_(0)],e.moveTo(p.x,p.y)),f=0;f<=s;++f){if(p=i[_(f)],p.skip)continue;const y=p.x,E=p.y,S=y|0;S===m?(E<g?g=E:E>v&&(v=E),u=(d*u+y)/++d):(w(),e.lineTo(y,E),m=S,d=0,g=v=E),x=E}w()}function N1(e){const t=e.options,n=t.borderDash&&t.borderDash.length;return!e._decimated&&!e._loop&&!t.tension&&t.cubicInterpolationMode!=="monotone"&&!t.stepped&&!n?Ade:Dde}function Tde(e){return e.stepped?Sce:e.tension||e.cubicInterpolationMode==="monotone"?Oce:vs}function Nde(e,t,n,r){let i=t._path;i||(i=t._path=new Path2D,t.path(i,n,r)&&i.closePath()),n4(e,t.options),e.stroke(i)}function jde(e,t,n,r){const{segments:i,options:o}=t,a=N1(t);for(const s of i)n4(e,o,s.style),e.beginPath(),a(e,t,s,{start:n,end:n+r-1})&&e.closePath(),e.stroke()}const Mde=typeof Path2D=="function";function Ide(e,t,n,r){Mde&&!t.options.segment?Nde(e,t,n,r):jde(e,t,n,r)}class j1 extends va{static id="line";static defaults={borderCapStyle:"butt",borderDash:[],borderDashOffset:0,borderJoinStyle:"miter",borderWidth:3,capBezierPoints:!0,cubicInterpolationMode:"default",fill:!1,spanGaps:!1,stepped:!1,tension:0};static defaultRoutes={backgroundColor:"backgroundColor",borderColor:"borderColor"};static descriptors={_scriptable:!0,_indexable:t=>t!=="borderDash"&&t!=="fill"};constructor(t){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,t&&Object.assign(this,t)}updateControlPoints(t,n){const r=this.options;if((r.tension||r.cubicInterpolationMode==="monotone")&&!r.stepped&&!this._pointsUpdated){const i=r.spanGaps?this._loop:this._fullLoop;gce(this._points,r,t,i,n),this._pointsUpdated=!0}}set points(t){this._points=t,delete this._segments,delete this._path,this._pointsUpdated=!1}get points(){return this._points}get segments(){return this._segments||(this._segments=jce(this,this.options.segment))}first(){const t=this.segments,n=this.points;return t.length&&n[t[0].start]}last(){const t=this.segments,n=this.points,r=t.length;return r&&n[t[r-1].end]}interpolate(t,n){const r=this.options,i=t[n],o=this.points,a=Ace(this,{property:n,start:i,end:i});if(!a.length)return;const s=[],l=Tde(r);let c,u;for(c=0,u=a.length;c<u;++c){const{start:d,end:f}=a[c],p=o[d],m=o[f];if(p===m){s.push(p);continue}const g=Math.abs((i-p[n])/(m[n]-p[n])),v=l(p,m,g,r.stepped);v[n]=t[n],s.push(v)}return s.length===1?s[0]:s}pathSegment(t,n,r){return N1(this)(t,this,n,r)}path(t,n,r){const i=this.segments,o=N1(this);let a=this._loop;n=n||0,r=r||this.points.length-n;for(const s of i)a&=o(t,this,s,{start:n,end:n+r-1});return!!a}draw(t,n,r,i){const o=this.options||{};(this.points||[]).length&&o.borderWidth&&(t.save(),Ide(t,this,r,i),t.restore()),this.animated&&(this._pointsUpdated=!1,this._path=void 0)}}function i4(e,t,n,r){const i=e.options,{[n]:o}=e.getProps([n],r);return Math.abs(t-o)<i.radius+i.hitRadius}class M1 extends va{static id="point";parsed;skip;stop;static defaults={borderWidth:1,hitRadius:1,hoverBorderWidth:1,hoverRadius:4,pointStyle:"circle",radius:3,rotation:0};static defaultRoutes={backgroundColor:"backgroundColor",borderColor:"borderColor"};constructor(t){super(),this.options=void 0,this.parsed=void 0,this.skip=void 0,this.stop=void 0,t&&Object.assign(this,t)}inRange(t,n,r){const i=this.options,{x:o,y:a}=this.getProps(["x","y"],r);return Math.pow(t-o,2)+Math.pow(n-a,2)<Math.pow(i.hitRadius+i.radius,2)}inXRange(t,n){return i4(this,t,"x",n)}inYRange(t,n){return i4(this,t,"y",n)}getCenterPoint(t){const{x:n,y:r}=this.getProps(["x","y"],t);return{x:n,y:r}}size(t){t=t||this.options||{};let n=t.radius||0;n=Math.max(n,n&&t.hoverRadius||0);const r=n&&t.borderWidth||0;return(n+r)*2}draw(t,n){const r=this.options;this.skip||r.radius<.1||!Uu(this,n,this.size(r)/2)||(t.strokeStyle=r.borderColor,t.lineWidth=r.borderWidth,t.fillStyle=r.backgroundColor,p1(t,r,this.x,this.y))}getRange(){const t=this.options||{};return t.radius+t.hitRadius}}function o4(e,t){const{x:n,y:r,base:i,width:o,height:a}=e.getProps(["x","y","base","width","height"],t);let s,l,c,u,d;return e.horizontal?(d=a/2,s=Math.min(n,i),l=Math.max(n,i),c=r-d,u=r+d):(d=o/2,s=n-d,l=n+d,c=Math.min(r,i),u=Math.max(r,i)),{left:s,top:c,right:l,bottom:u}}function ya(e,t,n,r){return e?0:$n(t,n,r)}function Fde(e,t,n){const r=e.options.borderWidth,i=e.borderSkipped,o=eI(r);return{t:ya(i.top,o.top,0,n),r:ya(i.right,o.right,0,t),b:ya(i.bottom,o.bottom,0,n),l:ya(i.left,o.left,0,t)}}function Lde(e,t,n){const{enableBorderRadius:r}=e.getProps(["enableBorderRadius"]),i=e.options.borderRadius,o=Il(i),a=Math.min(t,n),s=e.borderSkipped,l=r||Me(i);return{topLeft:ya(!l||s.top||s.left,o.topLeft,0,a),topRight:ya(!l||s.top||s.right,o.topRight,0,a),bottomLeft:ya(!l||s.bottom||s.left,o.bottomLeft,0,a),bottomRight:ya(!l||s.bottom||s.right,o.bottomRight,0,a)}}function Rde(e){const t=o4(e),n=t.right-t.left,r=t.bottom-t.top,i=Fde(e,n/2,r/2),o=Lde(e,n/2,r/2);return{outer:{x:t.left,y:t.top,w:n,h:r,radius:o},inner:{x:t.left+i.l,y:t.top+i.t,w:n-i.l-i.r,h:r-i.t-i.b,radius:{topLeft:Math.max(0,o.topLeft-Math.max(i.t,i.l)),topRight:Math.max(0,o.topRight-Math.max(i.t,i.r)),bottomLeft:Math.max(0,o.bottomLeft-Math.max(i.b,i.l)),bottomRight:Math.max(0,o.bottomRight-Math.max(i.b,i.r))}}}}function I1(e,t,n,r){const i=t===null,o=n===null,s=e&&!(i&&o)&&o4(e,r);return s&&(i||ma(t,s.left,s.right))&&(o||ma(n,s.top,s.bottom))}function $de(e){return e.topLeft||e.topRight||e.bottomLeft||e.bottomRight}function Bde(e,t){e.rect(t.x,t.y,t.w,t.h)}function F1(e,t,n={}){const r=e.x!==n.x?-t:0,i=e.y!==n.y?-t:0,o=(e.x+e.w!==n.x+n.w?t:0)-r,a=(e.y+e.h!==n.y+n.h?t:0)-i;return{x:e.x+r,y:e.y+i,w:e.w+o,h:e.h+a,radius:e.radius}}class Wl extends va{static id="bar";static defaults={borderSkipped:"start",borderWidth:0,borderRadius:0,inflateAmount:"auto",pointStyle:void 0};static defaultRoutes={backgroundColor:"backgroundColor",borderColor:"borderColor"};constructor(t){super(),this.options=void 0,this.horizontal=void 0,this.base=void 0,this.width=void 0,this.height=void 0,this.inflateAmount=void 0,t&&Object.assign(this,t)}draw(t){const{inflateAmount:n,options:{borderColor:r,backgroundColor:i}}=this,{inner:o,outer:a}=Rde(this),s=$de(a.radius)?Yh:Bde;t.save(),(a.w!==o.w||a.h!==o.h)&&(t.beginPath(),s(t,F1(a,n,o)),t.clip(),s(t,F1(o,-n,a)),t.fillStyle=r,t.fill("evenodd")),t.beginPath(),s(t,F1(o,n)),t.fillStyle=i,t.fill(),t.restore()}inRange(t,n,r){return I1(this,t,n,r)}inXRange(t,n){return I1(this,t,null,n)}inYRange(t,n){return I1(this,null,t,n)}getCenterPoint(t){const{x:n,y:r,base:i,horizontal:o}=this.getProps(["x","y","base","horizontal"],t);return{x:o?(n+i)/2:n,y:o?r:(r+i)/2}}getRange(t){return t==="x"?this.width/2:this.height/2}}const a4=(e,t)=>{let{boxHeight:n=t,boxWidth:r=t}=e;return e.usePointStyle&&(n=Math.min(n,t),r=e.pointStyleWidth||Math.min(r,t)),{boxWidth:r,boxHeight:n,itemHeight:Math.max(t,n)}},Wde=(e,t)=>e!==null&&t!==null&&e.datasetIndex===t.datasetIndex&&e.index===t.index;class s4 extends va{constructor(t){super(),this._added=!1,this.legendHitBoxes=[],this._hoveredItem=null,this.doughnutMode=!1,this.chart=t.chart,this.options=t.options,this.ctx=t.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(t,n,r){this.maxWidth=t,this.maxHeight=n,this._margins=r,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 t=this.options.labels||{};let n=bt(t.generateLabels,[this.chart],this)||[];t.filter&&(n=n.filter(r=>t.filter(r,this.chart.data))),t.sort&&(n=n.sort((r,i)=>t.sort(r,i,this.chart.data))),this.options.reverse&&n.reverse(),this.legendItems=n}fit(){const{options:t,ctx:n}=this;if(!t.display){this.width=this.height=0;return}const r=t.labels,i=cr(r.font),o=i.size,a=this._computeTitleHeight(),{boxWidth:s,itemHeight:l}=a4(r,o);let c,u;n.font=i.string,this.isHorizontal()?(c=this.maxWidth,u=this._fitRows(a,o,s,l)+10):(u=this.maxHeight,c=this._fitCols(a,i,s,l)+10),this.width=Math.min(c,t.maxWidth||this.maxWidth),this.height=Math.min(u,t.maxHeight||this.maxHeight)}_fitRows(t,n,r,i){const{ctx:o,maxWidth:a,options:{labels:{padding:s}}}=this,l=this.legendHitBoxes=[],c=this.lineWidths=[0],u=i+s;let d=t;o.textAlign="left",o.textBaseline="middle";let f=-1,p=-u;return this.legendItems.forEach((m,g)=>{const v=r+n/2+o.measureText(m.text).width;(g===0||c[c.length-1]+v+2*s>a)&&(d+=u,c[c.length-(g>0?0:1)]=0,p+=u,f++),l[g]={left:0,top:p,row:f,width:v,height:i},c[c.length-1]+=v+s}),d}_fitCols(t,n,r,i){const{ctx:o,maxHeight:a,options:{labels:{padding:s}}}=this,l=this.legendHitBoxes=[],c=this.columnSizes=[],u=a-t;let d=s,f=0,p=0,m=0,g=0;return this.legendItems.forEach((v,x)=>{const{itemWidth:_,itemHeight:w}=zde(r,n,o,v,i);x>0&&p+w+2*s>u&&(d+=f+s,c.push({width:f,height:p}),m+=f+s,g++,f=p=0),l[x]={left:m,top:p,col:g,width:_,height:w},f=Math.max(f,_),p+=w+s}),d+=f,c.push({width:f,height:p}),d}adjustHitBoxes(){if(!this.options.display)return;const t=this._computeTitleHeight(),{legendHitBoxes:n,options:{align:r,labels:{padding:i},rtl:o}}=this,a=Rl(o,this.left,this.width);if(this.isHorizontal()){let s=0,l=Dr(r,this.left+i,this.right-this.lineWidths[s]);for(const c of n)s!==c.row&&(s=c.row,l=Dr(r,this.left+i,this.right-this.lineWidths[s])),c.top+=this.top+t+i,c.left=a.leftForLtr(a.x(l),c.width),l+=c.width+i}else{let s=0,l=Dr(r,this.top+t+i,this.bottom-this.columnSizes[s].height);for(const c of n)c.col!==s&&(s=c.col,l=Dr(r,this.top+t+i,this.bottom-this.columnSizes[s].height)),c.top=l,c.left+=this.left+i,c.left=a.leftForLtr(a.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 t=this.ctx;h1(t,this),this._draw(),m1(t)}}_draw(){const{options:t,columnSizes:n,lineWidths:r,ctx:i}=this,{align:o,labels:a}=t,s=zt.color,l=Rl(t.rtl,this.left,this.width),c=cr(a.font),{padding:u}=a,d=c.size,f=d/2;let p;this.drawTitle(),i.textAlign=l.textAlign("left"),i.textBaseline="middle",i.lineWidth=.5,i.font=c.string;const{boxWidth:m,boxHeight:g,itemHeight:v}=a4(a,d),x=function(S,P,D){if(isNaN(m)||m<=0||isNaN(g)||g<0)return;i.save();const T=Oe(D.lineWidth,1);if(i.fillStyle=Oe(D.fillStyle,s),i.lineCap=Oe(D.lineCap,"butt"),i.lineDashOffset=Oe(D.lineDashOffset,0),i.lineJoin=Oe(D.lineJoin,"miter"),i.lineWidth=T,i.strokeStyle=Oe(D.strokeStyle,s),i.setLineDash(Oe(D.lineDash,[])),a.usePointStyle){const I={radius:g*Math.SQRT2/2,pointStyle:D.pointStyle,rotation:D.rotation,borderWidth:T},A=l.xPlus(S,m/2),C=P+f;JM(i,I,A,C,a.pointStyleWidth&&m)}else{const I=P+Math.max((d-g)/2,0),A=l.leftForLtr(S,m),C=Il(D.borderRadius);i.beginPath(),Object.values(C).some(j=>j!==0)?Yh(i,{x:A,y:I,w:m,h:g,radius:C}):i.rect(A,I,m,g),i.fill(),T!==0&&i.stroke()}i.restore()},_=function(S,P,D){Hh(i,D.text,S,P+v/2,c,{strikethrough:D.hidden,textAlign:l.textAlign(D.textAlign)})},w=this.isHorizontal(),y=this._computeTitleHeight();w?p={x:Dr(o,this.left+u,this.right-r[0]),y:this.top+u+y,line:0}:p={x:this.left+u,y:Dr(o,this.top+y+u,this.bottom-n[0].height),line:0},uI(this.ctx,t.textDirection);const E=v+u;this.legendItems.forEach((S,P)=>{i.strokeStyle=S.fontColor,i.fillStyle=S.fontColor;const D=i.measureText(S.text).width,T=l.textAlign(S.textAlign||(S.textAlign=a.textAlign)),I=m+f+D;let A=p.x,C=p.y;l.setWidth(this.width),w?P>0&&A+I+u>this.right&&(C=p.y+=E,p.line++,A=p.x=Dr(o,this.left+u,this.right-r[p.line])):P>0&&C+E>this.bottom&&(A=p.x=A+n[p.line].width+u,p.line++,C=p.y=Dr(o,this.top+y+u,this.bottom-n[p.line].height));const j=l.x(A);if(x(j,C,S),A=Nle(T,A+m+f,w?A+I:this.right,t.rtl),_(l.x(A),C,S),w)p.x+=I+u;else if(typeof S.text!="string"){const N=c.lineHeight;p.y+=l4(S,N)+u}else p.y+=E}),dI(this.ctx,t.textDirection)}drawTitle(){const t=this.options,n=t.title,r=cr(n.font),i=li(n.padding);if(!n.display)return;const o=Rl(t.rtl,this.left,this.width),a=this.ctx,s=n.position,l=r.size/2,c=i.top+l;let u,d=this.left,f=this.width;if(this.isHorizontal())f=Math.max(...this.lineWidths),u=this.top+c,d=Dr(t.align,d,this.right-f);else{const m=this.columnSizes.reduce((g,v)=>Math.max(g,v.height),0);u=c+Dr(t.align,this.top,this.bottom-m-t.labels.padding-this._computeTitleHeight())}const p=Dr(s,d,d+f);a.textAlign=o.textAlign(YM(s)),a.textBaseline="middle",a.strokeStyle=n.color,a.fillStyle=n.color,a.font=r.string,Hh(a,n.text,p,u,r)}_computeTitleHeight(){const t=this.options.title,n=cr(t.font),r=li(t.padding);return t.display?n.lineHeight+r.height:0}_getLegendItemAt(t,n){let r,i,o;if(ma(t,this.left,this.right)&&ma(n,this.top,this.bottom)){for(o=this.legendHitBoxes,r=0;r<o.length;++r)if(i=o[r],ma(t,i.left,i.left+i.width)&&ma(n,i.top,i.top+i.height))return this.legendItems[r]}return null}handleEvent(t){const n=this.options;if(!Yde(t.type,n))return;const r=this._getLegendItemAt(t.x,t.y);if(t.type==="mousemove"||t.type==="mouseout"){const i=this._hoveredItem,o=Wde(i,r);i&&!o&&bt(n.onLeave,[t,i,this],this),this._hoveredItem=r,r&&!o&&bt(n.onHover,[t,r,this],this)}else r&&bt(n.onClick,[t,r,this],this)}}function zde(e,t,n,r,i){const o=Vde(r,e,t,n),a=Hde(i,r,t.lineHeight);return{itemWidth:o,itemHeight:a}}function Vde(e,t,n,r){let i=e.text;return i&&typeof i!="string"&&(i=i.reduce((o,a)=>o.length>a.length?o:a)),t+n.size/2+r.measureText(i).width}function Hde(e,t,n){let r=e;return typeof t.text!="string"&&(r=l4(t,n)),r}function l4(e,t){const n=e.text?e.text.length:0;return t*n}function Yde(e,t){return!!((e==="mousemove"||e==="mouseout")&&(t.onHover||t.onLeave)||t.onClick&&(e==="click"||e==="mouseup"))}var Zr={id:"legend",_element:s4,start(e,t,n){const r=e.legend=new s4({ctx:e.ctx,options:n,chart:e});ga.configure(e,r,n),ga.addBox(e,r)},stop(e){ga.removeBox(e,e.legend),delete e.legend},beforeUpdate(e,t,n){const r=e.legend;ga.configure(e,r,n),r.options=n},afterUpdate(e){const t=e.legend;t.buildLabels(),t.adjustHitBoxes()},afterEvent(e,t){t.replay||e.legend.handleEvent(t.event)},defaults:{display:!0,position:"top",align:"center",fullSize:!0,reverse:!1,weight:1e3,onClick(e,t,n){const r=t.datasetIndex,i=n.chart;i.isDatasetVisible(r)?(i.hide(r),t.hidden=!0):(i.show(r),t.hidden=!1)},onHover:null,onLeave:null,labels:{color:e=>e.chart.options.color,boxWidth:40,padding:10,generateLabels(e){const t=e.data.datasets,{labels:{usePointStyle:n,pointStyle:r,textAlign:i,color:o,useBorderRadius:a,borderRadius:s}}=e.legend.options;return e._getSortedDatasetMetas().map(l=>{const c=l.controller.getStyle(n?0:void 0),u=li(c.borderWidth);return{text:t[l.index].label,fillStyle:c.backgroundColor,fontColor:o,hidden:!l.visible,lineCap:c.borderCapStyle,lineDash:c.borderDash,lineDashOffset:c.borderDashOffset,lineJoin:c.borderJoinStyle,lineWidth:(u.width+u.height)/4,strokeStyle:c.borderColor,pointStyle:r||c.pointStyle,rotation:c.rotation,textAlign:i||c.textAlign,borderRadius:a&&(s||c.borderRadius),datasetIndex:l.index}},this)}},title:{color:e=>e.chart.options.color,display:!1,position:"center",text:""}},descriptors:{_scriptable:e=>!e.startsWith("on"),labels:{_scriptable:e=>!["generateLabels","filter","sort"].includes(e)}}};const ed={average(e){if(!e.length)return!1;let t,n,r=new Set,i=0,o=0;for(t=0,n=e.length;t<n;++t){const s=e[t].element;if(s&&s.hasValue()){const l=s.tooltipPosition();r.add(l.x),i+=l.y,++o}}return o===0||r.size===0?!1:{x:[...r].reduce((s,l)=>s+l)/r.size,y:i/o}},nearest(e,t){if(!e.length)return!1;let n=t.x,r=t.y,i=Number.POSITIVE_INFINITY,o,a,s;for(o=0,a=e.length;o<a;++o){const l=e[o].element;if(l&&l.hasValue()){const c=l.getCenterPoint(),u=a1(t,c);u<i&&(i=u,s=l)}}if(s){const l=s.tooltipPosition();n=l.x,r=l.y}return{x:n,y:r}}};function Ui(e,t){return t&&(hn(t)?Array.prototype.push.apply(e,t):e.push(t)),e}function Io(e){return(typeof e=="string"||e instanceof String)&&e.indexOf(`
|
|
297
|
+
*/class Rce{constructor(){this._request=null,this._charts=new Map,this._running=!1,this._lastDate=void 0}_notify(t,n,r,i){const o=n.listeners[i],a=n.duration;o.forEach(s=>s({chart:t,initial:n.initial,numSteps:a,currentStep:Math.min(r-n.start,a)}))}_refresh(){this._request||(this._running=!0,this._request=VM.call(window,()=>{this._update(),this._request=null,this._running&&this._refresh()}))}_update(t=Date.now()){let n=0;this._charts.forEach((r,i)=>{if(!r.running||!r.items.length)return;const o=r.items;let a=o.length-1,s=!1,l;for(;a>=0;--a)l=o[a],l._active?(l._total>r.duration&&(r.duration=l._total),l.tick(t),s=!0):(o[a]=o[o.length-1],o.pop());s&&(i.draw(),this._notify(i,r,t,"progress")),o.length||(r.running=!1,this._notify(i,r,t,"complete"),r.initial=!1),n+=o.length}),this._lastDate=t,n===0&&(this._running=!1)}_getAnims(t){const n=this._charts;let r=n.get(t);return r||(r={running:!1,initial:!0,items:[],listeners:{complete:[],progress:[]}},n.set(t,r)),r}listen(t,n,r){this._getAnims(t).listeners[n].push(r)}add(t,n){!n||!n.length||this._getAnims(t).items.push(...n)}has(t){return this._getAnims(t).items.length>0}start(t){const n=this._charts.get(t);n&&(n.running=!0,n.start=Date.now(),n.duration=n.items.reduce((r,i)=>Math.max(r,i._duration),0),this._refresh())}running(t){if(!this._running)return!1;const n=this._charts.get(t);return!(!n||!n.running||!n.items.length)}stop(t){const n=this._charts.get(t);if(!n||!n.items.length)return;const r=n.items;let i=r.length-1;for(;i>=0;--i)r[i].cancel();n.items=[],this._notify(t,n,Date.now(),"complete")}remove(t){return this._charts.delete(t)}}var Mo=new Rce;const gI="transparent",$ce={boolean(e,t,n){return n>.5?t:e},color(e,t,n){const r=qM(e||gI),i=r.valid&&qM(t||gI);return i&&i.valid?i.mix(r,n).hexString():t},number(e,t,n){return e+(t-e)*n}};class Bce{constructor(t,n,r,i){const o=n[r];i=Uh([t.to,i,o,t.from]);const a=Uh([t.from,o,i]);this._active=!0,this._fn=t.fn||$ce[t.type||typeof a],this._easing=Hu[t.easing]||Hu.linear,this._start=Math.floor(Date.now()+(t.delay||0)),this._duration=this._total=Math.floor(t.duration),this._loop=!!t.loop,this._target=n,this._prop=r,this._from=a,this._to=i,this._promises=void 0}active(){return this._active}update(t,n,r){if(this._active){this._notify(!1);const i=this._target[this._prop],o=r-this._start,a=this._duration-o;this._start=r,this._duration=Math.floor(Math.max(a,t.duration)),this._total+=o,this._loop=!!t.loop,this._to=Uh([t.to,n,i,t.from]),this._from=Uh([t.from,i,n])}}cancel(){this._active&&(this.tick(Date.now()),this._active=!1,this._notify(!1))}tick(t){const n=t-this._start,r=this._duration,i=this._prop,o=this._from,a=this._loop,s=this._to;let l;if(this._active=o!==s&&(a||n<r),!this._active){this._target[i]=s,this._notify(!0);return}if(n<0){this._target[i]=o;return}l=n/r%2,l=a&&l>1?2-l:l,l=this._easing(Math.min(1,Math.max(0,l))),this._target[i]=this._fn(o,s,l)}wait(){const t=this._promises||(this._promises=[]);return new Promise((n,r)=>{t.push({res:n,rej:r})})}_notify(t){const n=t?"res":"rej",r=this._promises||[];for(let i=0;i<r.length;i++)r[i][n]()}}class vI{constructor(t,n){this._chart=t,this._properties=new Map,this.configure(n)}configure(t){if(!Me(t))return;const n=Object.keys(zt.animation),r=this._properties;Object.getOwnPropertyNames(t).forEach(i=>{const o=t[i];if(!Me(o))return;const a={};for(const s of n)a[s]=o[s];(hn(o.properties)&&o.properties||[i]).forEach(s=>{(s===i||!r.has(s))&&r.set(s,a)})})}_animateOptions(t,n){const r=n.options,i=zce(t,r);if(!i)return[];const o=this._createAnimations(i,r);return r.$shared&&Wce(t.options.$animations,r).then(()=>{t.options=r},()=>{}),o}_createAnimations(t,n){const r=this._properties,i=[],o=t.$animations||(t.$animations={}),a=Object.keys(n),s=Date.now();let l;for(l=a.length-1;l>=0;--l){const c=a[l];if(c.charAt(0)==="$")continue;if(c==="options"){i.push(...this._animateOptions(t,n));continue}const u=n[c];let d=o[c];const f=r.get(c);if(d)if(f&&d.active()){d.update(f,u,s);continue}else d.cancel();if(!f||!f.duration){t[c]=u;continue}o[c]=d=new Bce(f,t,c,u),i.push(d)}return i}update(t,n){if(this._properties.size===0){Object.assign(t,n);return}const r=this._createAnimations(t,n);if(r.length)return Mo.add(this._chart,r),!0}}function Wce(e,t){const n=[],r=Object.keys(t);for(let i=0;i<r.length;i++){const o=e[r[i]];o&&o.active()&&n.push(o.wait())}return Promise.all(n)}function zce(e,t){if(!t)return;let n=e.options;if(!n){e.options=t;return}return n.$shared&&(e.options=n=Object.assign({},n,{$shared:!1,$animations:{}})),n}function yI(e,t){const n=e&&e.options||{},r=n.reverse,i=n.min===void 0?t:0,o=n.max===void 0?t:0;return{start:r?o:i,end:r?i:o}}function Vce(e,t,n){if(n===!1)return!1;const r=yI(e,n),i=yI(t,n);return{top:i.end,right:r.end,bottom:i.start,left:r.start}}function Hce(e){let t,n,r,i;return Me(e)?(t=e.top,n=e.right,r=e.bottom,i=e.left):t=n=r=i=e,{top:t,right:n,bottom:r,left:i,disabled:e===!1}}function bI(e,t){const n=[],r=e._getSortedDatasetMetas(t);let i,o;for(i=0,o=r.length;i<o;++i)n.push(r[i].index);return n}function xI(e,t,n,r={}){const i=e.keys,o=r.mode==="single";let a,s,l,c;if(t===null)return;let u=!1;for(a=0,s=i.length;a<s;++a){if(l=+i[a],l===n){if(u=!0,r.all)continue;break}c=e.values[l],Qr(c)&&(o||t===0||Hi(t)===Hi(c))&&(t+=c)}return!u&&!r.all?0:t}function Yce(e,t){const{iScale:n,vScale:r}=t,i=n.axis==="x"?"x":"y",o=r.axis==="x"?"x":"y",a=Object.keys(e),s=new Array(a.length);let l,c,u;for(l=0,c=a.length;l<c;++l)u=a[l],s[l]={[i]:u,[o]:e[u]};return s}function _1(e,t){const n=e&&e.options.stacked;return n||n===void 0&&t.stack!==void 0}function Uce(e,t,n){return`${e.id}.${t.id}.${n.stack||n.type}`}function Kce(e){const{min:t,max:n,minDefined:r,maxDefined:i}=e.getUserBounds();return{min:r?t:Number.NEGATIVE_INFINITY,max:i?n:Number.POSITIVE_INFINITY}}function qce(e,t,n){const r=e[t]||(e[t]={});return r[n]||(r[n]={})}function wI(e,t,n,r){for(const i of t.getMatchingVisibleMetas(r).reverse()){const o=e[i.index];if(n&&o>0||!n&&o<0)return i.index}return null}function _I(e,t){const{chart:n,_cachedMeta:r}=e,i=n._stacks||(n._stacks={}),{iScale:o,vScale:a,index:s}=r,l=o.axis,c=a.axis,u=Uce(o,a,r),d=t.length;let f;for(let p=0;p<d;++p){const m=t[p],{[l]:g,[c]:v}=m,x=m._stacks||(m._stacks={});f=x[c]=qce(i,u,g),f[s]=v,f._top=wI(f,a,!0,r.type),f._bottom=wI(f,a,!1,r.type);const _=f._visualValues||(f._visualValues={});_[s]=v}}function E1(e,t){const n=e.scales;return Object.keys(n).filter(r=>n[r].axis===t).shift()}function Gce(e,t){return hs(e,{active:!1,dataset:void 0,datasetIndex:t,index:t,mode:"default",type:"dataset"})}function Xce(e,t,n){return hs(e,{active:!1,dataIndex:t,parsed:void 0,raw:void 0,element:n,index:t,mode:"default",type:"data"})}function Ku(e,t){const n=e.controller.index,r=e.vScale&&e.vScale.axis;if(r){t=t||e._parsed;for(const i of t){const o=i._stacks;if(!o||o[r]===void 0||o[r][n]===void 0)return;delete o[r][n],o[r]._visualValues!==void 0&&o[r]._visualValues[n]!==void 0&&delete o[r]._visualValues[n]}}}const S1=e=>e==="reset"||e==="none",EI=(e,t)=>t?e:Object.assign({},e),Qce=(e,t,n)=>e&&!t.hidden&&t._stacked&&{keys:bI(n,!0),values:null};class Zh{static defaults={};static datasetElementType=null;static dataElementType=null;constructor(t,n){this.chart=t,this._ctx=t.ctx,this.index=n,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 t=this._cachedMeta;this.configure(),this.linkScales(),t._stacked=_1(t.vScale,t),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(t){this.index!==t&&Ku(this._cachedMeta),this.index=t}linkScales(){const t=this.chart,n=this._cachedMeta,r=this.getDataset(),i=(d,f,p,m)=>d==="x"?f:d==="r"?m:p,o=n.xAxisID=Oe(r.xAxisID,E1(t,"x")),a=n.yAxisID=Oe(r.yAxisID,E1(t,"y")),s=n.rAxisID=Oe(r.rAxisID,E1(t,"r")),l=n.indexAxis,c=n.iAxisID=i(l,o,a,s),u=n.vAxisID=i(l,a,o,s);n.xScale=this.getScaleForId(o),n.yScale=this.getScaleForId(a),n.rScale=this.getScaleForId(s),n.iScale=this.getScaleForId(c),n.vScale=this.getScaleForId(u)}getDataset(){return this.chart.data.datasets[this.index]}getMeta(){return this.chart.getDatasetMeta(this.index)}getScaleForId(t){return this.chart.scales[t]}_getOtherScale(t){const n=this._cachedMeta;return t===n.iScale?n.vScale:n.iScale}reset(){this._update("reset")}_destroy(){const t=this._cachedMeta;this._data&&WM(this._data,this),t._stacked&&Ku(t)}_dataCheck(){const t=this.getDataset(),n=t.data||(t.data=[]),r=this._data;if(Me(n)){const i=this._cachedMeta;this._data=Yce(n,i)}else if(r!==n){if(r){WM(r,this);const i=this._cachedMeta;Ku(i),i._parsed=[]}n&&Object.isExtensible(n)&&Ale(n,this),this._syncList=[],this._data=n}}addElements(){const t=this._cachedMeta;this._dataCheck(),this.datasetElementType&&(t.dataset=new this.datasetElementType)}buildOrUpdateElements(t){const n=this._cachedMeta,r=this.getDataset();let i=!1;this._dataCheck();const o=n._stacked;n._stacked=_1(n.vScale,n),n.stack!==r.stack&&(i=!0,Ku(n),n.stack=r.stack),this._resyncElements(t),(i||o!==n._stacked)&&(_I(this,n._parsed),n._stacked=_1(n.vScale,n))}configure(){const t=this.chart.config,n=t.datasetScopeKeys(this._type),r=t.getOptionScopes(this.getDataset(),n,!0);this.options=t.createResolver(r,this.getContext()),this._parsing=this.options.parsing,this._cachedDataOpts={}}parse(t,n){const{_cachedMeta:r,_data:i}=this,{iScale:o,_stacked:a}=r,s=o.axis;let l=t===0&&n===i.length?!0:r._sorted,c=t>0&&r._parsed[t-1],u,d,f;if(this._parsing===!1)r._parsed=i,r._sorted=!0,f=i;else{hn(i[t])?f=this.parseArrayData(r,i,t,n):Me(i[t])?f=this.parseObjectData(r,i,t,n):f=this.parsePrimitiveData(r,i,t,n);const p=()=>d[s]===null||c&&d[s]<c[s];for(u=0;u<n;++u)r._parsed[u+t]=d=f[u],l&&(p()&&(l=!1),c=d);r._sorted=l}a&&_I(this,f)}parsePrimitiveData(t,n,r,i){const{iScale:o,vScale:a}=t,s=o.axis,l=a.axis,c=o.getLabels(),u=o===a,d=new Array(i);let f,p,m;for(f=0,p=i;f<p;++f)m=f+r,d[f]={[s]:u||o.parse(c[m],m),[l]:a.parse(n[m],m)};return d}parseArrayData(t,n,r,i){const{xScale:o,yScale:a}=t,s=new Array(i);let l,c,u,d;for(l=0,c=i;l<c;++l)u=l+r,d=n[u],s[l]={x:o.parse(d[0],u),y:a.parse(d[1],u)};return s}parseObjectData(t,n,r,i){const{xScale:o,yScale:a}=t,{xAxisKey:s="x",yAxisKey:l="y"}=this._parsing,c=new Array(i);let u,d,f,p;for(u=0,d=i;u<d;++u)f=u+r,p=n[f],c[u]={x:o.parse(cs(p,s),f),y:a.parse(cs(p,l),f)};return c}getParsed(t){return this._cachedMeta._parsed[t]}getDataElement(t){return this._cachedMeta.data[t]}applyStack(t,n,r){const i=this.chart,o=this._cachedMeta,a=n[t.axis],s={keys:bI(i,!0),values:n._stacks[t.axis]._visualValues};return xI(s,a,o.index,{mode:r})}updateRangeFromParsed(t,n,r,i){const o=r[n.axis];let a=o===null?NaN:o;const s=i&&r._stacks[n.axis];i&&s&&(i.values=s,a=xI(i,o,this._cachedMeta.index)),t.min=Math.min(t.min,a),t.max=Math.max(t.max,a)}getMinMax(t,n){const r=this._cachedMeta,i=r._parsed,o=r._sorted&&t===r.iScale,a=i.length,s=this._getOtherScale(t),l=Qce(n,r,this.chart),c={min:Number.POSITIVE_INFINITY,max:Number.NEGATIVE_INFINITY},{min:u,max:d}=Kce(s);let f,p;function m(){p=i[f];const g=p[s.axis];return!Qr(p[t.axis])||u>g||d<g}for(f=0;f<a&&!(!m()&&(this.updateRangeFromParsed(c,t,p,l),o));++f);if(o){for(f=a-1;f>=0;--f)if(!m()){this.updateRangeFromParsed(c,t,p,l);break}}return c}getAllParsedValues(t){const n=this._cachedMeta._parsed,r=[];let i,o,a;for(i=0,o=n.length;i<o;++i)a=n[i][t.axis],Qr(a)&&r.push(a);return r}getMaxOverflow(){return!1}getLabelAndValue(t){const n=this._cachedMeta,r=n.iScale,i=n.vScale,o=this.getParsed(t);return{label:r?""+r.getLabelForValue(o[r.axis]):"",value:i?""+i.getLabelForValue(o[i.axis]):""}}_update(t){const n=this._cachedMeta;this.update(t||"default"),n._clip=Hce(Oe(this.options.clip,Vce(n.xScale,n.yScale,this.getMaxOverflow())))}update(t){}draw(){const t=this._ctx,n=this.chart,r=this._cachedMeta,i=r.data||[],o=n.chartArea,a=[],s=this._drawStart||0,l=this._drawCount||i.length-s,c=this.options.drawActiveElementsOnTop;let u;for(r.dataset&&r.dataset.draw(t,o,s,l),u=s;u<s+l;++u){const d=i[u];d.hidden||(d.active&&c?a.push(d):d.draw(t,o))}for(u=0;u<a.length;++u)a[u].draw(t,o)}getStyle(t,n){const r=n?"active":"default";return t===void 0&&this._cachedMeta.dataset?this.resolveDatasetElementOptions(r):this.resolveDataElementOptions(t||0,r)}getContext(t,n,r){const i=this.getDataset();let o;if(t>=0&&t<this._cachedMeta.data.length){const a=this._cachedMeta.data[t];o=a.$context||(a.$context=Xce(this.getContext(),t,a)),o.parsed=this.getParsed(t),o.raw=i.data[t],o.index=o.dataIndex=t}else o=this.$context||(this.$context=Gce(this.chart.getContext(),this.index)),o.dataset=i,o.index=o.datasetIndex=this.index;return o.active=!!n,o.mode=r,o}resolveDatasetElementOptions(t){return this._resolveElementOptions(this.datasetElementType.id,t)}resolveDataElementOptions(t,n){return this._resolveElementOptions(this.dataElementType.id,n,t)}_resolveElementOptions(t,n="default",r){const i=n==="active",o=this._cachedDataOpts,a=t+"-"+n,s=o[a],l=this.enableOptionSharing&&Bu(r);if(s)return EI(s,l);const c=this.chart.config,u=c.datasetElementScopeKeys(this._type,t),d=i?[`${t}Hover`,"hover",t,""]:[t,""],f=c.getOptionScopes(this.getDataset(),u),p=Object.keys(zt.elements[t]),m=()=>this.getContext(r,i,n),g=c.resolveNamedOptions(f,p,m,d);return g.$shared&&(g.$shared=l,o[a]=Object.freeze(EI(g,l))),g}_resolveAnimations(t,n,r){const i=this.chart,o=this._cachedDataOpts,a=`animation-${n}`,s=o[a];if(s)return s;let l;if(i.options.animation!==!1){const u=this.chart.config,d=u.datasetAnimationScopeKeys(this._type,n),f=u.getOptionScopes(this.getDataset(),d);l=u.createResolver(f,this.getContext(t,r,n))}const c=new vI(i,l&&l.animations);return l&&l._cacheable&&(o[a]=Object.freeze(c)),c}getSharedOptions(t){if(t.$shared)return this._sharedOptions||(this._sharedOptions=Object.assign({},t))}includeOptions(t,n){return!n||S1(t)||this.chart._animationsDisabled}_getSharedOptions(t,n){const r=this.resolveDataElementOptions(t,n),i=this._sharedOptions,o=this.getSharedOptions(r),a=this.includeOptions(n,o)||o!==i;return this.updateSharedOptions(o,n,r),{sharedOptions:o,includeOptions:a}}updateElement(t,n,r,i){S1(i)?Object.assign(t,r):this._resolveAnimations(n,i).update(t,r)}updateSharedOptions(t,n,r){t&&!S1(n)&&this._resolveAnimations(void 0,n).update(t,r)}_setStyle(t,n,r,i){t.active=i;const o=this.getStyle(n,i);this._resolveAnimations(n,r,i).update(t,{options:!i&&this.getSharedOptions(o)||o})}removeHoverStyle(t,n,r){this._setStyle(t,r,"active",!1)}setHoverStyle(t,n,r){this._setStyle(t,r,"active",!0)}_removeDatasetHoverStyle(){const t=this._cachedMeta.dataset;t&&this._setStyle(t,void 0,"active",!1)}_setDatasetHoverStyle(){const t=this._cachedMeta.dataset;t&&this._setStyle(t,void 0,"active",!0)}_resyncElements(t){const n=this._data,r=this._cachedMeta.data;for(const[s,l,c]of this._syncList)this[s](l,c);this._syncList=[];const i=r.length,o=n.length,a=Math.min(o,i);a&&this.parse(0,a),o>i?this._insertElements(i,o-i,t):o<i&&this._removeElements(o,i-o)}_insertElements(t,n,r=!0){const i=this._cachedMeta,o=i.data,a=t+n;let s;const l=c=>{for(c.length+=n,s=c.length-1;s>=a;s--)c[s]=c[s-n]};for(l(o),s=t;s<a;++s)o[s]=new this.dataElementType;this._parsing&&l(i._parsed),this.parse(t,n),r&&this.updateElements(o,t,n,"reset")}updateElements(t,n,r,i){}_removeElements(t,n){const r=this._cachedMeta;if(this._parsing){const i=r._parsed.splice(t,n);r._stacked&&Ku(r,i)}r.data.splice(t,n)}_sync(t){if(this._parsing)this._syncList.push(t);else{const[n,r,i]=t;this[n](r,i)}this.chart._dataChanges.push([this.index,...t])}_onDataPush(){const t=arguments.length;this._sync(["_insertElements",this.getDataset().data.length-t,t])}_onDataPop(){this._sync(["_removeElements",this._cachedMeta.data.length-1,1])}_onDataShift(){this._sync(["_removeElements",0,1])}_onDataSplice(t,n){n&&this._sync(["_removeElements",t,n]);const r=arguments.length-2;r&&this._sync(["_insertElements",t,r])}_onDataUnshift(){this._sync(["_insertElements",0,arguments.length])}}function Zce(e,t){if(!e._cache.$bar){const n=e.getMatchingVisibleMetas(t);let r=[];for(let i=0,o=n.length;i<o;i++)r=r.concat(n[i].controller.getAllParsedValues(e));e._cache.$bar=zM(r.sort((i,o)=>i-o))}return e._cache.$bar}function Jce(e){const t=e.iScale,n=Zce(t,e.type);let r=t._length,i,o,a,s;const l=()=>{a===32767||a===-32768||(Bu(s)&&(r=Math.min(r,Math.abs(a-s)||r)),s=a)};for(i=0,o=n.length;i<o;++i)a=t.getPixelForValue(n[i]),l();for(s=void 0,i=0,o=t.ticks.length;i<o;++i)a=t.getPixelForTick(i),l();return r}function eue(e,t,n,r){const i=n.barThickness;let o,a;return Ke(i)?(o=t.min*n.categoryPercentage,a=n.barPercentage):(o=i*r,a=1),{chunk:o/r,ratio:a,start:t.pixels[e]-o/2}}function tue(e,t,n,r){const i=t.pixels,o=i[e];let a=e>0?i[e-1]:null,s=e<i.length-1?i[e+1]:null;const l=n.categoryPercentage;a===null&&(a=o-(s===null?t.end-t.start:s-o)),s===null&&(s=o+o-a);const c=o-(o-Math.min(a,s))/2*l;return{chunk:Math.abs(s-a)/2*l/r,ratio:n.barPercentage,start:c}}function nue(e,t,n,r){const i=n.parse(e[0],r),o=n.parse(e[1],r),a=Math.min(i,o),s=Math.max(i,o);let l=a,c=s;Math.abs(a)>Math.abs(s)&&(l=s,c=a),t[n.axis]=c,t._custom={barStart:l,barEnd:c,start:i,end:o,min:a,max:s}}function SI(e,t,n,r){return hn(e)?nue(e,t,n,r):t[n.axis]=n.parse(e,r),t}function OI(e,t,n,r){const i=e.iScale,o=e.vScale,a=i.getLabels(),s=i===o,l=[];let c,u,d,f;for(c=n,u=n+r;c<u;++c)f=t[c],d={},d[i.axis]=s||i.parse(a[c],c),l.push(SI(f,d,o,c));return l}function O1(e){return e&&e.barStart!==void 0&&e.barEnd!==void 0}function rue(e,t,n){return e!==0?Hi(e):(t.isHorizontal()?1:-1)*(t.min>=n?1:-1)}function iue(e){let t,n,r,i,o;return e.horizontal?(t=e.base>e.x,n="left",r="right"):(t=e.base<e.y,n="bottom",r="top"),t?(i="end",o="start"):(i="start",o="end"),{start:n,end:r,reverse:t,top:i,bottom:o}}function oue(e,t,n,r){let i=t.borderSkipped;const o={};if(!i){e.borderSkipped=o;return}if(i===!0){e.borderSkipped={top:!0,right:!0,bottom:!0,left:!0};return}const{start:a,end:s,reverse:l,top:c,bottom:u}=iue(e);i==="middle"&&n&&(e.enableBorderRadius=!0,(n._top||0)===r?i=c:(n._bottom||0)===r?i=u:(o[CI(u,a,s,l)]=!0,i=c)),o[CI(i,a,s,l)]=!0,e.borderSkipped=o}function CI(e,t,n,r){return r?(e=aue(e,t,n),e=kI(e,n,t)):e=kI(e,t,n),e}function aue(e,t,n){return e===t?n:e===n?t:e}function kI(e,t,n){return e==="start"?t:e==="end"?n:e}function sue(e,{inflateAmount:t},n){e.inflateAmount=t==="auto"?n===1?.33:0:t}class lue extends Zh{static id="bar";static defaults={datasetElementType:!1,dataElementType:"bar",categoryPercentage:.8,barPercentage:.9,grouped:!0,animations:{numbers:{type:"number",properties:["x","y","base","width","height"]}}};static overrides={scales:{_index_:{type:"category",offset:!0,grid:{offset:!0}},_value_:{type:"linear",beginAtZero:!0}}};parsePrimitiveData(t,n,r,i){return OI(t,n,r,i)}parseArrayData(t,n,r,i){return OI(t,n,r,i)}parseObjectData(t,n,r,i){const{iScale:o,vScale:a}=t,{xAxisKey:s="x",yAxisKey:l="y"}=this._parsing,c=o.axis==="x"?s:l,u=a.axis==="x"?s:l,d=[];let f,p,m,g;for(f=r,p=r+i;f<p;++f)g=n[f],m={},m[o.axis]=o.parse(cs(g,c),f),d.push(SI(cs(g,u),m,a,f));return d}updateRangeFromParsed(t,n,r,i){super.updateRangeFromParsed(t,n,r,i);const o=r._custom;o&&n===this._cachedMeta.vScale&&(t.min=Math.min(t.min,o.min),t.max=Math.max(t.max,o.max))}getMaxOverflow(){return 0}getLabelAndValue(t){const n=this._cachedMeta,{iScale:r,vScale:i}=n,o=this.getParsed(t),a=o._custom,s=O1(a)?"["+a.start+", "+a.end+"]":""+i.getLabelForValue(o[i.axis]);return{label:""+r.getLabelForValue(o[r.axis]),value:s}}initialize(){this.enableOptionSharing=!0,super.initialize();const t=this._cachedMeta;t.stack=this.getDataset().stack}update(t){const n=this._cachedMeta;this.updateElements(n.data,0,n.data.length,t)}updateElements(t,n,r,i){const o=i==="reset",{index:a,_cachedMeta:{vScale:s}}=this,l=s.getBasePixel(),c=s.isHorizontal(),u=this._getRuler(),{sharedOptions:d,includeOptions:f}=this._getSharedOptions(n,i);for(let p=n;p<n+r;p++){const m=this.getParsed(p),g=o||Ke(m[s.axis])?{base:l,head:l}:this._calculateBarValuePixels(p),v=this._calculateBarIndexPixels(p,u),x=(m._stacks||{})[s.axis],_={horizontal:c,base:g.base,enableBorderRadius:!x||O1(m._custom)||a===x._top||a===x._bottom,x:c?g.head:v.center,y:c?v.center:g.head,height:c?v.size:Math.abs(g.size),width:c?Math.abs(g.size):v.size};f&&(_.options=d||this.resolveDataElementOptions(p,t[p].active?"active":i));const w=_.options||t[p].options;oue(_,w,x,a),sue(_,w,u.ratio),this.updateElement(t[p],p,_,i)}}_getStacks(t,n){const{iScale:r}=this._cachedMeta,i=r.getMatchingVisibleMetas(this._type).filter(u=>u.controller.options.grouped),o=r.options.stacked,a=[],s=this._cachedMeta.controller.getParsed(n),l=s&&s[r.axis],c=u=>{const d=u._parsed.find(p=>p[r.axis]===l),f=d&&d[u.vScale.axis];if(Ke(f)||isNaN(f))return!0};for(const u of i)if(!(n!==void 0&&c(u))&&((o===!1||a.indexOf(u.stack)===-1||o===void 0&&u.stack===void 0)&&a.push(u.stack),u.index===t))break;return a.length||a.push(void 0),a}_getStackCount(t){return this._getStacks(void 0,t).length}_getAxisCount(){return this._getAxis().length}getFirstScaleIdForIndexAxis(){const t=this.chart.scales,n=this.chart.options.indexAxis;return Object.keys(t).filter(r=>t[r].axis===n).shift()}_getAxis(){const t={},n=this.getFirstScaleIdForIndexAxis();for(const r of this.chart.data.datasets)t[Oe(this.chart.options.indexAxis==="x"?r.xAxisID:r.yAxisID,n)]=!0;return Object.keys(t)}_getStackIndex(t,n,r){const i=this._getStacks(t,r),o=n!==void 0?i.indexOf(n):-1;return o===-1?i.length-1:o}_getRuler(){const t=this.options,n=this._cachedMeta,r=n.iScale,i=[];let o,a;for(o=0,a=n.data.length;o<a;++o)i.push(r.getPixelForValue(this.getParsed(o)[r.axis],o));const s=t.barThickness;return{min:s||Jce(n),pixels:i,start:r._startPixel,end:r._endPixel,stackCount:this._getStackCount(),scale:r,grouped:t.grouped,ratio:s?1:t.categoryPercentage*t.barPercentage}}_calculateBarValuePixels(t){const{_cachedMeta:{vScale:n,_stacked:r,index:i},options:{base:o,minBarLength:a}}=this,s=o||0,l=this.getParsed(t),c=l._custom,u=O1(c);let d=l[n.axis],f=0,p=r?this.applyStack(n,l,r):d,m,g;p!==d&&(f=p-d,p=d),u&&(d=c.barStart,p=c.barEnd-c.barStart,d!==0&&Hi(d)!==Hi(c.barEnd)&&(f=0),f+=d);const v=!Ke(o)&&!u?o:f;let x=n.getPixelForValue(v);if(this.chart.getDataVisibility(t)?m=n.getPixelForValue(f+p):m=x,g=m-x,Math.abs(g)<a){g=rue(g,n,s)*a,d===s&&(x-=g/2);const _=n.getPixelForDecimal(0),w=n.getPixelForDecimal(1),y=Math.min(_,w),E=Math.max(_,w);x=Math.max(Math.min(x,E),y),m=x+g,r&&!u&&(l._stacks[n.axis]._visualValues[i]=n.getValueForPixel(m)-n.getValueForPixel(x))}if(x===n.getPixelForValue(s)){const _=Hi(g)*n.getLineWidthForValue(s)/2;x+=_,g-=_}return{size:g,base:x,head:m,center:m+g/2}}_calculateBarIndexPixels(t,n){const r=n.scale,i=this.options,o=i.skipNull,a=Oe(i.maxBarThickness,1/0);let s,l;const c=this._getAxisCount();if(n.grouped){const u=o?this._getStackCount(t):n.stackCount,d=i.barThickness==="flex"?tue(t,n,i,u*c):eue(t,n,i,u*c),f=this.chart.options.indexAxis==="x"?this.getDataset().xAxisID:this.getDataset().yAxisID,p=this._getAxis().indexOf(Oe(f,this.getFirstScaleIdForIndexAxis())),m=this._getStackIndex(this.index,this._cachedMeta.stack,o?t:void 0)+p;s=d.start+d.chunk*m+d.chunk/2,l=Math.min(a,d.chunk*d.ratio)}else s=r.getPixelForValue(this.getParsed(t)[r.axis],t),l=Math.min(a,n.min*n.ratio);return{base:s-l/2,head:s+l/2,center:s,size:l}}draw(){const t=this._cachedMeta,n=t.vScale,r=t.data,i=r.length;let o=0;for(;o<i;++o)this.getParsed(o)[n.axis]!==null&&!r[o].hidden&&r[o].draw(this._ctx)}}function cue(e,t,n){let r=1,i=1,o=0,a=0;if(t<Ft){const s=e,l=s+t,c=Math.cos(s),u=Math.sin(s),d=Math.cos(l),f=Math.sin(l),p=(w,y,E)=>Vu(w,s,l,!0)?1:Math.max(y,y*n,E,E*n),m=(w,y,E)=>Vu(w,s,l,!0)?-1:Math.min(y,y*n,E,E*n),g=p(0,c,d),v=p(an,u,f),x=m(st,c,d),_=m(st+an,u,f);r=(g-x)/2,i=(v-_)/2,o=-(g+x)/2,a=-(v+_)/2}return{ratioX:r,ratioY:i,offsetX:o,offsetY:a}}class uue extends Zh{static id="doughnut";static defaults={datasetElementType:!1,dataElementType:"arc",animation:{animateRotate:!0,animateScale:!1},animations:{numbers:{type:"number",properties:["circumference","endAngle","innerRadius","outerRadius","startAngle","x","y","offset","borderWidth","spacing"]}},cutout:"50%",rotation:0,circumference:360,radius:"100%",spacing:0,indexAxis:"r"};static descriptors={_scriptable:t=>t!=="spacing",_indexable:t=>t!=="spacing"&&!t.startsWith("borderDash")&&!t.startsWith("hoverBorderDash")};static overrides={aspectRatio:1,plugins:{legend:{labels:{generateLabels(t){const n=t.data;if(n.labels.length&&n.datasets.length){const{labels:{pointStyle:r,color:i}}=t.legend.options;return n.labels.map((o,a)=>{const l=t.getDatasetMeta(0).controller.getStyle(a);return{text:o,fillStyle:l.backgroundColor,strokeStyle:l.borderColor,fontColor:i,lineWidth:l.borderWidth,pointStyle:r,hidden:!t.getDataVisibility(a),index:a}})}return[]}},onClick(t,n,r){r.chart.toggleDataVisibility(n.index),r.chart.update()}}}};constructor(t,n){super(t,n),this.enableOptionSharing=!0,this.innerRadius=void 0,this.outerRadius=void 0,this.offsetX=void 0,this.offsetY=void 0}linkScales(){}parse(t,n){const r=this.getDataset().data,i=this._cachedMeta;if(this._parsing===!1)i._parsed=r;else{let o=l=>+r[l];if(Me(r[t])){const{key:l="value"}=this._parsing;o=c=>+cs(r[c],l)}let a,s;for(a=t,s=t+n;a<s;++a)i._parsed[a]=o(a)}}_getRotation(){return jo(this.options.rotation-90)}_getCircumference(){return jo(this.options.circumference)}_getRotationExtents(){let t=Ft,n=-Ft;for(let r=0;r<this.chart.data.datasets.length;++r)if(this.chart.isDatasetVisible(r)&&this.chart.getDatasetMeta(r).type===this._type){const i=this.chart.getDatasetMeta(r).controller,o=i._getRotation(),a=i._getCircumference();t=Math.min(t,o),n=Math.max(n,o+a)}return{rotation:t,circumference:n-t}}update(t){const n=this.chart,{chartArea:r}=n,i=this._cachedMeta,o=i.data,a=this.getMaxBorderWidth()+this.getMaxOffset(o)+this.options.spacing,s=Math.max((Math.min(r.width,r.height)-a)/2,0),l=Math.min(ple(this.options.cutout,s),1),c=this._getRingWeight(this.index),{circumference:u,rotation:d}=this._getRotationExtents(),{ratioX:f,ratioY:p,offsetX:m,offsetY:g}=cue(d,u,l),v=(r.width-a)/f,x=(r.height-a)/p,_=Math.max(Math.min(v,x)/2,0),w=TM(this.options.radius,_),y=Math.max(w*l,0),E=(w-y)/this._getVisibleDatasetWeightTotal();this.offsetX=m*w,this.offsetY=g*w,i.total=this.calculateTotal(),this.outerRadius=w-E*this._getRingWeightOffset(this.index),this.innerRadius=Math.max(this.outerRadius-E*c,0),this.updateElements(o,0,o.length,t)}_circumference(t,n){const r=this.options,i=this._cachedMeta,o=this._getCircumference();return n&&r.animation.animateRotate||!this.chart.getDataVisibility(t)||i._parsed[t]===null||i.data[t].hidden?0:this.calculateCircumference(i._parsed[t]*o/Ft)}updateElements(t,n,r,i){const o=i==="reset",a=this.chart,s=a.chartArea,c=a.options.animation,u=(s.left+s.right)/2,d=(s.top+s.bottom)/2,f=o&&c.animateScale,p=f?0:this.innerRadius,m=f?0:this.outerRadius,{sharedOptions:g,includeOptions:v}=this._getSharedOptions(n,i);let x=this._getRotation(),_;for(_=0;_<n;++_)x+=this._circumference(_,o);for(_=n;_<n+r;++_){const w=this._circumference(_,o),y=t[_],E={x:u+this.offsetX,y:d+this.offsetY,startAngle:x,endAngle:x+w,circumference:w,outerRadius:m,innerRadius:p};v&&(E.options=g||this.resolveDataElementOptions(_,y.active?"active":i)),x+=w,this.updateElement(y,_,E,i)}}calculateTotal(){const t=this._cachedMeta,n=t.data;let r=0,i;for(i=0;i<n.length;i++){const o=t._parsed[i];o!==null&&!isNaN(o)&&this.chart.getDataVisibility(i)&&!n[i].hidden&&(r+=Math.abs(o))}return r}calculateCircumference(t){const n=this._cachedMeta.total;return n>0&&!isNaN(t)?Ft*(Math.abs(t)/n):0}getLabelAndValue(t){const n=this._cachedMeta,r=this.chart,i=r.data.labels||[],o=u1(n._parsed[t],r.options.locale);return{label:i[t]||"",value:o}}getMaxBorderWidth(t){let n=0;const r=this.chart;let i,o,a,s,l;if(!t){for(i=0,o=r.data.datasets.length;i<o;++i)if(r.isDatasetVisible(i)){a=r.getDatasetMeta(i),t=a.data,s=a.controller;break}}if(!t)return 0;for(i=0,o=t.length;i<o;++i)l=s.resolveDataElementOptions(i),l.borderAlign!=="inner"&&(n=Math.max(n,l.borderWidth||0,l.hoverBorderWidth||0));return n}getMaxOffset(t){let n=0;for(let r=0,i=t.length;r<i;++r){const o=this.resolveDataElementOptions(r);n=Math.max(n,o.offset||0,o.hoverOffset||0)}return n}_getRingWeightOffset(t){let n=0;for(let r=0;r<t;++r)this.chart.isDatasetVisible(r)&&(n+=this._getRingWeight(r));return n}_getRingWeight(t){return Math.max(Oe(this.chart.data.datasets[t].weight,1),0)}_getVisibleDatasetWeightTotal(){return this._getRingWeightOffset(this.chart.data.datasets.length)||1}}class due extends Zh{static id="line";static defaults={datasetElementType:"line",dataElementType:"point",showLine:!0,spanGaps:!1};static overrides={scales:{_index_:{type:"category"},_value_:{type:"linear"}}};initialize(){this.enableOptionSharing=!0,this.supportsDecimation=!0,super.initialize()}update(t){const n=this._cachedMeta,{dataset:r,data:i=[],_dataset:o}=n,a=this.chart._animationsDisabled;let{start:s,count:l}=jle(n,i,a);this._drawStart=s,this._drawCount=l,Mle(n)&&(s=0,l=i.length),r._chart=this.chart,r._datasetIndex=this.index,r._decimated=!!o._decimated,r.points=i;const c=this.resolveDatasetElementOptions(t);this.options.showLine||(c.borderWidth=0),c.segment=this.options.segment,this.updateElement(r,void 0,{animated:!a,options:c},t),this.updateElements(i,s,l,t)}updateElements(t,n,r,i){const o=i==="reset",{iScale:a,vScale:s,_stacked:l,_dataset:c}=this._cachedMeta,{sharedOptions:u,includeOptions:d}=this._getSharedOptions(n,i),f=a.axis,p=s.axis,{spanGaps:m,segment:g}=this.options,v=zu(m)?m:Number.POSITIVE_INFINITY,x=this.chart._animationsDisabled||o||i==="none",_=n+r,w=t.length;let y=n>0&&this.getParsed(n-1);for(let E=0;E<w;++E){const S=t[E],P=x?S:{};if(E<n||E>=_){P.skip=!0;continue}const D=this.getParsed(E),T=Ke(D[p]),I=P[f]=a.getPixelForValue(D[f],E),A=P[p]=o||T?s.getBasePixel():s.getPixelForValue(l?this.applyStack(s,D,l):D[p],E);P.skip=isNaN(I)||isNaN(A)||T,P.stop=E>0&&Math.abs(D[f]-y[f])>v,g&&(P.parsed=D,P.raw=c.data[E]),d&&(P.options=u||this.resolveDataElementOptions(E,S.active?"active":i)),x||this.updateElement(S,E,P,i),y=D}}getMaxOverflow(){const t=this._cachedMeta,n=t.dataset,r=n.options&&n.options.borderWidth||0,i=t.data||[];if(!i.length)return r;const o=i[0].size(this.resolveDataElementOptions(0)),a=i[i.length-1].size(this.resolveDataElementOptions(i.length-1));return Math.max(r,o,a)/2}draw(){const t=this._cachedMeta;t.dataset.updateControlPoints(this.chart.chartArea,t.iScale.axis),super.draw()}}function ys(){throw new Error("This method is not implemented: Check that a complete date adapter is provided.")}class C1{static override(t){Object.assign(C1.prototype,t)}options;constructor(t){this.options=t||{}}init(){}formats(){return ys()}parse(){return ys()}format(){return ys()}add(){return ys()}diff(){return ys()}startOf(){return ys()}endOf(){return ys()}}var fue={_date:C1};function pue(e,t,n,r){const{controller:i,data:o,_sorted:a}=e,s=i._cachedMeta.iScale,l=e.dataset&&e.dataset.options?e.dataset.options.spanGaps:null;if(s&&t===s.axis&&t!=="r"&&a&&o.length){const c=s._reversePixels?Ple:ds;if(r){if(i._sharedOptions){const u=o[0],d=typeof u.getRange=="function"&&u.getRange(t);if(d){const f=c(o,t,n-d),p=c(o,t,n+d);return{lo:f.lo,hi:p.hi}}}}else{const u=c(o,t,n);if(l){const{vScale:d}=i._cachedMeta,{_parsed:f}=e,p=f.slice(0,u.lo+1).reverse().findIndex(g=>!Ke(g[d.axis]));u.lo-=Math.max(0,p);const m=f.slice(u.hi).findIndex(g=>!Ke(g[d.axis]));u.hi+=Math.max(0,m)}return u}}return{lo:0,hi:o.length-1}}function Jh(e,t,n,r,i){const o=e.getSortedVisibleDatasetMetas(),a=n[t];for(let s=0,l=o.length;s<l;++s){const{index:c,data:u}=o[s],{lo:d,hi:f}=pue(o[s],t,a,i);for(let p=d;p<=f;++p){const m=u[p];m.skip||r(m,c,p)}}}function hue(e){const t=e.indexOf("x")!==-1,n=e.indexOf("y")!==-1;return function(r,i){const o=t?Math.abs(r.x-i.x):0,a=n?Math.abs(r.y-i.y):0;return Math.sqrt(Math.pow(o,2)+Math.pow(a,2))}}function k1(e,t,n,r,i){const o=[];return!i&&!e.isPointInArea(t)||Jh(e,n,t,function(s,l,c){!i&&!Uu(s,e.chartArea,0)||s.inRange(t.x,t.y,r)&&o.push({element:s,datasetIndex:l,index:c})},!0),o}function mue(e,t,n,r){let i=[];function o(a,s,l){const{startAngle:c,endAngle:u}=a.getProps(["startAngle","endAngle"],r),{angle:d}=$M(a,{x:t.x,y:t.y});Vu(d,c,u)&&i.push({element:a,datasetIndex:s,index:l})}return Jh(e,n,t,o),i}function gue(e,t,n,r,i,o){let a=[];const s=hue(n);let l=Number.POSITIVE_INFINITY;function c(u,d,f){const p=u.inRange(t.x,t.y,i);if(r&&!p)return;const m=u.getCenterPoint(i);if(!(!!o||e.isPointInArea(m))&&!p)return;const v=s(t,m);v<l?(a=[{element:u,datasetIndex:d,index:f}],l=v):v===l&&a.push({element:u,datasetIndex:d,index:f})}return Jh(e,n,t,c),a}function P1(e,t,n,r,i,o){return!o&&!e.isPointInArea(t)?[]:n==="r"&&!r?mue(e,t,n,i):gue(e,t,n,r,i,o)}function PI(e,t,n,r,i){const o=[],a=n==="x"?"inXRange":"inYRange";let s=!1;return Jh(e,n,t,(l,c,u)=>{l[a]&&l[a](t[n],i)&&(o.push({element:l,datasetIndex:c,index:u}),s=s||l.inRange(t.x,t.y,i))}),r&&!s?[]:o}var vue={modes:{index(e,t,n,r){const i=gs(t,e),o=n.axis||"x",a=n.includeInvisible||!1,s=n.intersect?k1(e,i,o,r,a):P1(e,i,o,!1,r,a),l=[];return s.length?(e.getSortedVisibleDatasetMetas().forEach(c=>{const u=s[0].index,d=c.data[u];d&&!d.skip&&l.push({element:d,datasetIndex:c.index,index:u})}),l):[]},dataset(e,t,n,r){const i=gs(t,e),o=n.axis||"xy",a=n.includeInvisible||!1;let s=n.intersect?k1(e,i,o,r,a):P1(e,i,o,!1,r,a);if(s.length>0){const l=s[0].datasetIndex,c=e.getDatasetMeta(l).data;s=[];for(let u=0;u<c.length;++u)s.push({element:c[u],datasetIndex:l,index:u})}return s},point(e,t,n,r){const i=gs(t,e),o=n.axis||"xy",a=n.includeInvisible||!1;return k1(e,i,o,r,a)},nearest(e,t,n,r){const i=gs(t,e),o=n.axis||"xy",a=n.includeInvisible||!1;return P1(e,i,o,n.intersect,r,a)},x(e,t,n,r){const i=gs(t,e);return PI(e,i,"x",n.intersect,r)},y(e,t,n,r){const i=gs(t,e);return PI(e,i,"y",n.intersect,r)}}};const DI=["left","top","right","bottom"];function qu(e,t){return e.filter(n=>n.pos===t)}function AI(e,t){return e.filter(n=>DI.indexOf(n.pos)===-1&&n.box.axis===t)}function Gu(e,t){return e.sort((n,r)=>{const i=t?r:n,o=t?n:r;return i.weight===o.weight?i.index-o.index:i.weight-o.weight})}function yue(e){const t=[];let n,r,i,o,a,s;for(n=0,r=(e||[]).length;n<r;++n)i=e[n],{position:o,options:{stack:a,stackWeight:s=1}}=i,t.push({index:n,box:i,pos:o,horizontal:i.isHorizontal(),weight:i.weight,stack:a&&o+a,stackWeight:s});return t}function bue(e){const t={};for(const n of e){const{stack:r,pos:i,stackWeight:o}=n;if(!r||!DI.includes(i))continue;const a=t[r]||(t[r]={count:0,placed:0,weight:0,size:0});a.count++,a.weight+=o}return t}function xue(e,t){const n=bue(e),{vBoxMaxWidth:r,hBoxMaxHeight:i}=t;let o,a,s;for(o=0,a=e.length;o<a;++o){s=e[o];const{fullSize:l}=s.box,c=n[s.stack],u=c&&s.stackWeight/c.weight;s.horizontal?(s.width=u?u*r:l&&t.availableWidth,s.height=i):(s.width=r,s.height=u?u*i:l&&t.availableHeight)}return n}function wue(e){const t=yue(e),n=Gu(t.filter(c=>c.box.fullSize),!0),r=Gu(qu(t,"left"),!0),i=Gu(qu(t,"right")),o=Gu(qu(t,"top"),!0),a=Gu(qu(t,"bottom")),s=AI(t,"x"),l=AI(t,"y");return{fullSize:n,leftAndTop:r.concat(o),rightAndBottom:i.concat(l).concat(a).concat(s),chartArea:qu(t,"chartArea"),vertical:r.concat(i).concat(l),horizontal:o.concat(a).concat(s)}}function TI(e,t,n,r){return Math.max(e[n],t[n])+Math.max(e[r],t[r])}function NI(e,t){e.top=Math.max(e.top,t.top),e.left=Math.max(e.left,t.left),e.bottom=Math.max(e.bottom,t.bottom),e.right=Math.max(e.right,t.right)}function _ue(e,t,n,r){const{pos:i,box:o}=n,a=e.maxPadding;if(!Me(i)){n.size&&(e[i]-=n.size);const d=r[n.stack]||{size:0,count:1};d.size=Math.max(d.size,n.horizontal?o.height:o.width),n.size=d.size/d.count,e[i]+=n.size}o.getPadding&&NI(a,o.getPadding());const s=Math.max(0,t.outerWidth-TI(a,e,"left","right")),l=Math.max(0,t.outerHeight-TI(a,e,"top","bottom")),c=s!==e.w,u=l!==e.h;return e.w=s,e.h=l,n.horizontal?{same:c,other:u}:{same:u,other:c}}function Eue(e){const t=e.maxPadding;function n(r){const i=Math.max(t[r]-e[r],0);return e[r]+=i,i}e.y+=n("top"),e.x+=n("left"),n("right"),n("bottom")}function Sue(e,t){const n=t.maxPadding;function r(i){const o={left:0,top:0,right:0,bottom:0};return i.forEach(a=>{o[a]=Math.max(t[a],n[a])}),o}return r(e?["left","right"]:["top","bottom"])}function Xu(e,t,n,r){const i=[];let o,a,s,l,c,u;for(o=0,a=e.length,c=0;o<a;++o){s=e[o],l=s.box,l.update(s.width||t.w,s.height||t.h,Sue(s.horizontal,t));const{same:d,other:f}=_ue(t,n,s,r);c|=d&&i.length,u=u||f,l.fullSize||i.push(s)}return c&&Xu(i,t,n,r)||u}function em(e,t,n,r,i){e.top=n,e.left=t,e.right=t+r,e.bottom=n+i,e.width=r,e.height=i}function jI(e,t,n,r){const i=n.padding;let{x:o,y:a}=t;for(const s of e){const l=s.box,c=r[s.stack]||{placed:0,weight:1},u=s.stackWeight/c.weight||1;if(s.horizontal){const d=t.w*u,f=c.size||l.height;Bu(c.start)&&(a=c.start),l.fullSize?em(l,i.left,a,n.outerWidth-i.right-i.left,f):em(l,t.left+c.placed,a,d,f),c.start=a,c.placed+=d,a=l.bottom}else{const d=t.h*u,f=c.size||l.width;Bu(c.start)&&(o=c.start),l.fullSize?em(l,o,i.top,f,n.outerHeight-i.bottom-i.top):em(l,o,t.top+c.placed,f,d),c.start=o,c.placed+=d,o=l.right}}t.x=o,t.y=a}var ga={addBox(e,t){e.boxes||(e.boxes=[]),t.fullSize=t.fullSize||!1,t.position=t.position||"top",t.weight=t.weight||0,t._layers=t._layers||function(){return[{z:0,draw(n){t.draw(n)}}]},e.boxes.push(t)},removeBox(e,t){const n=e.boxes?e.boxes.indexOf(t):-1;n!==-1&&e.boxes.splice(n,1)},configure(e,t,n){t.fullSize=n.fullSize,t.position=n.position,t.weight=n.weight},update(e,t,n,r){if(!e)return;const i=li(e.options.layout.padding),o=Math.max(t-i.width,0),a=Math.max(n-i.height,0),s=wue(e.boxes),l=s.vertical,c=s.horizontal;et(e.boxes,g=>{typeof g.beforeLayout=="function"&&g.beforeLayout()});const u=l.reduce((g,v)=>v.box.options&&v.box.options.display===!1?g:g+1,0)||1,d=Object.freeze({outerWidth:t,outerHeight:n,padding:i,availableWidth:o,availableHeight:a,vBoxMaxWidth:o/2/u,hBoxMaxHeight:a/2}),f=Object.assign({},i);NI(f,li(r));const p=Object.assign({maxPadding:f,w:o,h:a,x:i.left,y:i.top},i),m=xue(l.concat(c),d);Xu(s.fullSize,p,d,m),Xu(l,p,d,m),Xu(c,p,d,m)&&Xu(l,p,d,m),Eue(p),jI(s.leftAndTop,p,d,m),p.x+=p.w,p.y+=p.h,jI(s.rightAndBottom,p,d,m),e.chartArea={left:p.left,top:p.top,right:p.left+p.w,bottom:p.top+p.h,height:p.h,width:p.w},et(s.chartArea,g=>{const v=g.box;Object.assign(v,e.chartArea),v.update(p.w,p.h,{left:0,top:0,right:0,bottom:0})})}};class MI{acquireContext(t,n){}releaseContext(t){return!1}addEventListener(t,n,r){}removeEventListener(t,n,r){}getDevicePixelRatio(){return 1}getMaximumSize(t,n,r,i){return n=Math.max(0,n||t.width),r=r||t.height,{width:n,height:Math.max(0,i?Math.floor(n/i):r)}}isAttached(t){return!0}updateConfig(t){}}class Oue extends MI{acquireContext(t){return t&&t.getContext&&t.getContext("2d")||null}updateConfig(t){t.options.animation=!1}}const tm="$chartjs",Cue={touchstart:"mousedown",touchmove:"mousemove",touchend:"mouseup",pointerenter:"mouseenter",pointerdown:"mousedown",pointermove:"mousemove",pointerup:"mouseup",pointerleave:"mouseout",pointerout:"mouseout"},II=e=>e===null||e==="";function kue(e,t){const n=e.style,r=e.getAttribute("height"),i=e.getAttribute("width");if(e[tm]={initial:{height:r,width:i,style:{display:n.display,height:n.height,width:n.width}}},n.display=n.display||"block",n.boxSizing=n.boxSizing||"border-box",II(i)){const o=cI(e,"width");o!==void 0&&(e.width=o)}if(II(r))if(e.style.height==="")e.height=e.width/(t||2);else{const o=cI(e,"height");o!==void 0&&(e.height=o)}return e}const FI=Ece?{passive:!0}:!1;function Pue(e,t,n){e&&e.addEventListener(t,n,FI)}function Due(e,t,n){e&&e.canvas&&e.canvas.removeEventListener(t,n,FI)}function Aue(e,t){const n=Cue[e.type]||e.type,{x:r,y:i}=gs(e,t);return{type:n,chart:t,native:e,x:r!==void 0?r:null,y:i!==void 0?i:null}}function nm(e,t){for(const n of e)if(n===t||n.contains(t))return!0}function Tue(e,t,n){const r=e.canvas,i=new MutationObserver(o=>{let a=!1;for(const s of o)a=a||nm(s.addedNodes,r),a=a&&!nm(s.removedNodes,r);a&&n()});return i.observe(document,{childList:!0,subtree:!0}),i}function Nue(e,t,n){const r=e.canvas,i=new MutationObserver(o=>{let a=!1;for(const s of o)a=a||nm(s.removedNodes,r),a=a&&!nm(s.addedNodes,r);a&&n()});return i.observe(document,{childList:!0,subtree:!0}),i}const Qu=new Map;let LI=0;function RI(){const e=window.devicePixelRatio;e!==LI&&(LI=e,Qu.forEach((t,n)=>{n.currentDevicePixelRatio!==e&&t()}))}function jue(e,t){Qu.size||window.addEventListener("resize",RI),Qu.set(e,t)}function Mue(e){Qu.delete(e),Qu.size||window.removeEventListener("resize",RI)}function Iue(e,t,n){const r=e.canvas,i=r&&w1(r);if(!i)return;const o=HM((s,l)=>{const c=i.clientWidth;n(s,l),c<i.clientWidth&&n()},window),a=new ResizeObserver(s=>{const l=s[0],c=l.contentRect.width,u=l.contentRect.height;c===0&&u===0||o(c,u)});return a.observe(i),jue(e,o),a}function D1(e,t,n){n&&n.disconnect(),t==="resize"&&Mue(e)}function Fue(e,t,n){const r=e.canvas,i=HM(o=>{e.ctx!==null&&n(Aue(o,e))},e);return Pue(r,t,i),i}class Lue extends MI{acquireContext(t,n){const r=t&&t.getContext&&t.getContext("2d");return r&&r.canvas===t?(kue(t,n),r):null}releaseContext(t){const n=t.canvas;if(!n[tm])return!1;const r=n[tm].initial;["height","width"].forEach(o=>{const a=r[o];Ke(a)?n.removeAttribute(o):n.setAttribute(o,a)});const i=r.style||{};return Object.keys(i).forEach(o=>{n.style[o]=i[o]}),n.width=n.width,delete n[tm],!0}addEventListener(t,n,r){this.removeEventListener(t,n);const i=t.$proxies||(t.$proxies={}),a={attach:Tue,detach:Nue,resize:Iue}[n]||Fue;i[n]=a(t,n,r)}removeEventListener(t,n){const r=t.$proxies||(t.$proxies={}),i=r[n];if(!i)return;({attach:D1,detach:D1,resize:D1}[n]||Due)(t,n,i),r[n]=void 0}getDevicePixelRatio(){return window.devicePixelRatio}getMaximumSize(t,n,r,i){return _ce(t,n,r,i)}isAttached(t){const n=t&&w1(t);return!!(n&&n.isConnected)}}function Rue(e){return!x1()||typeof OffscreenCanvas<"u"&&e instanceof OffscreenCanvas?Oue:Lue}let va=class{static defaults={};static defaultRoutes=void 0;x;y;active=!1;options;$animations;tooltipPosition(t){const{x:n,y:r}=this.getProps(["x","y"],t);return{x:n,y:r}}hasValue(){return zu(this.x)&&zu(this.y)}getProps(t,n){const r=this.$animations;if(!n||!r)return this;const i={};return t.forEach(o=>{i[o]=r[o]&&r[o].active()?r[o]._to:this[o]}),i}};function $ue(e,t){const n=e.options.ticks,r=Bue(e),i=Math.min(n.maxTicksLimit||r,r),o=n.major.enabled?zue(t):[],a=o.length,s=o[0],l=o[a-1],c=[];if(a>i)return Vue(t,c,o,a/i),c;const u=Wue(o,t,i);if(a>0){let d,f;const p=a>1?Math.round((l-s)/(a-1)):null;for(rm(t,c,u,Ke(p)?0:s-p,s),d=0,f=a-1;d<f;d++)rm(t,c,u,o[d],o[d+1]);return rm(t,c,u,l,Ke(p)?t.length:l+p),c}return rm(t,c,u),c}function Bue(e){const t=e.options.offset,n=e._tickSize(),r=e._length/n+(t?0:1),i=e._maxLength/n;return Math.floor(Math.min(r,i))}function Wue(e,t,n){const r=Hue(e),i=t.length/n;if(!r)return Math.max(i,1);const o=wle(r);for(let a=0,s=o.length-1;a<s;a++){const l=o[a];if(l>i)return l}return Math.max(i,1)}function zue(e){const t=[];let n,r;for(n=0,r=e.length;n<r;n++)e[n].major&&t.push(n);return t}function Vue(e,t,n,r){let i=0,o=n[0],a;for(r=Math.ceil(r),a=0;a<e.length;a++)a===o&&(t.push(e[a]),i++,o=n[i*r])}function rm(e,t,n,r,i){const o=Oe(r,0),a=Math.min(Oe(i,e.length),e.length);let s=0,l,c,u;for(n=Math.ceil(n),i&&(l=i-r,n=l/Math.floor(l/n)),u=o;u<0;)s++,u=Math.round(o+s*n);for(c=Math.max(o,0);c<a;c++)c===u&&(t.push(e[c]),s++,u=Math.round(o+s*n))}function Hue(e){const t=e.length;let n,r;if(t<2)return!1;for(r=e[0],n=1;n<t;++n)if(e[n]-e[n-1]!==r)return!1;return r}const Yue=e=>e==="left"?"right":e==="right"?"left":e,$I=(e,t,n)=>t==="top"||t==="left"?e[t]+n:e[t]-n,BI=(e,t)=>Math.min(t||e,e);function WI(e,t){const n=[],r=e.length/t,i=e.length;let o=0;for(;o<i;o+=r)n.push(e[Math.floor(o)]);return n}function Uue(e,t,n){const r=e.ticks.length,i=Math.min(t,r-1),o=e._startPixel,a=e._endPixel,s=1e-6;let l=e.getPixelForTick(i),c;if(!(n&&(r===1?c=Math.max(l-o,a-l):t===0?c=(e.getPixelForTick(1)-l)/2:c=(l-e.getPixelForTick(i-1))/2,l+=i<t?c:-c,l<o-s||l>a+s)))return l}function Kue(e,t){et(e,n=>{const r=n.gc,i=r.length/2;let o;if(i>t){for(o=0;o<i;++o)delete n.data[r[o]];r.splice(0,i)}})}function Zu(e){return e.drawTicks?e.tickLength:0}function zI(e,t){if(!e.display)return 0;const n=cr(e.font,t),r=li(e.padding);return(hn(e.text)?e.text.length:1)*n.lineHeight+r.height}function que(e,t){return hs(e,{scale:t,type:"scale"})}function Gue(e,t,n){return hs(e,{tick:n,index:t,type:"tick"})}function Xue(e,t,n){let r=YM(e);return(n&&t!=="right"||!n&&t==="right")&&(r=Yue(r)),r}function Que(e,t,n,r){const{top:i,left:o,bottom:a,right:s,chart:l}=e,{chartArea:c,scales:u}=l;let d=0,f,p,m;const g=a-i,v=s-o;if(e.isHorizontal()){if(p=Dr(r,o,s),Me(n)){const x=Object.keys(n)[0],_=n[x];m=u[x].getPixelForValue(_)+g-t}else n==="center"?m=(c.bottom+c.top)/2+g-t:m=$I(e,n,t);f=s-o}else{if(Me(n)){const x=Object.keys(n)[0],_=n[x];p=u[x].getPixelForValue(_)-v+t}else n==="center"?p=(c.left+c.right)/2-v+t:p=$I(e,n,t);m=Dr(r,a,i),d=n==="left"?-an:an}return{titleX:p,titleY:m,maxWidth:f,rotation:d}}class $l extends va{constructor(t){super(),this.id=t.id,this.type=t.type,this.options=void 0,this.ctx=t.ctx,this.chart=t.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(t){this.options=t.setContext(this.getContext()),this.axis=t.axis,this._userMin=this.parse(t.min),this._userMax=this.parse(t.max),this._suggestedMin=this.parse(t.suggestedMin),this._suggestedMax=this.parse(t.suggestedMax)}parse(t,n){return t}getUserBounds(){let{_userMin:t,_userMax:n,_suggestedMin:r,_suggestedMax:i}=this;return t=Vi(t,Number.POSITIVE_INFINITY),n=Vi(n,Number.NEGATIVE_INFINITY),r=Vi(r,Number.POSITIVE_INFINITY),i=Vi(i,Number.NEGATIVE_INFINITY),{min:Vi(t,r),max:Vi(n,i),minDefined:Qr(t),maxDefined:Qr(n)}}getMinMax(t){let{min:n,max:r,minDefined:i,maxDefined:o}=this.getUserBounds(),a;if(i&&o)return{min:n,max:r};const s=this.getMatchingVisibleMetas();for(let l=0,c=s.length;l<c;++l)a=s[l].controller.getMinMax(this,t),i||(n=Math.min(n,a.min)),o||(r=Math.max(r,a.max));return n=o&&n>r?r:n,r=i&&n>r?n:r,{min:Vi(n,Vi(r,n)),max:Vi(r,Vi(n,r))}}getPadding(){return{left:this.paddingLeft||0,top:this.paddingTop||0,right:this.paddingRight||0,bottom:this.paddingBottom||0}}getTicks(){return this.ticks}getLabels(){const t=this.chart.data;return this.options.labels||(this.isHorizontal()?t.xLabels:t.yLabels)||t.labels||[]}getLabelItems(t=this.chart.chartArea){return this._labelItems||(this._labelItems=this._computeLabelItems(t))}beforeLayout(){this._cache={},this._dataLimitsCached=!1}beforeUpdate(){bt(this.options.beforeUpdate,[this])}update(t,n,r){const{beginAtZero:i,grace:o,ticks:a}=this.options,s=a.sampleSize;this.beforeUpdate(),this.maxWidth=t,this.maxHeight=n,this._margins=r=Object.assign({left:0,right:0,top:0,bottom:0},r),this.ticks=null,this._labelSizes=null,this._gridLineItems=null,this._labelItems=null,this.beforeSetDimensions(),this.setDimensions(),this.afterSetDimensions(),this._maxLength=this.isHorizontal()?this.width+r.left+r.right:this.height+r.top+r.bottom,this._dataLimitsCached||(this.beforeDataLimits(),this.determineDataLimits(),this.afterDataLimits(),this._range=ece(this,o,i),this._dataLimitsCached=!0),this.beforeBuildTicks(),this.ticks=this.buildTicks()||[],this.afterBuildTicks();const l=s<this.ticks.length;this._convertTicksToLabels(l?WI(this.ticks,s):this.ticks),this.configure(),this.beforeCalculateLabelRotation(),this.calculateLabelRotation(),this.afterCalculateLabelRotation(),a.display&&(a.autoSkip||a.source==="auto")&&(this.ticks=$ue(this,this.ticks),this._labelSizes=null,this.afterAutoSkip()),l&&this._convertTicksToLabels(this.ticks),this.beforeFit(),this.fit(),this.afterFit(),this.afterUpdate()}configure(){let t=this.options.reverse,n,r;this.isHorizontal()?(n=this.left,r=this.right):(n=this.top,r=this.bottom,t=!t),this._startPixel=n,this._endPixel=r,this._reversePixels=t,this._length=r-n,this._alignToPixels=this.options.alignToPixels}afterUpdate(){bt(this.options.afterUpdate,[this])}beforeSetDimensions(){bt(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(){bt(this.options.afterSetDimensions,[this])}_callHooks(t){this.chart.notifyPlugins(t,this.getContext()),bt(this.options[t],[this])}beforeDataLimits(){this._callHooks("beforeDataLimits")}determineDataLimits(){}afterDataLimits(){this._callHooks("afterDataLimits")}beforeBuildTicks(){this._callHooks("beforeBuildTicks")}buildTicks(){return[]}afterBuildTicks(){this._callHooks("afterBuildTicks")}beforeTickToLabelConversion(){bt(this.options.beforeTickToLabelConversion,[this])}generateTickLabels(t){const n=this.options.ticks;let r,i,o;for(r=0,i=t.length;r<i;r++)o=t[r],o.label=bt(n.callback,[o.value,r,t],this)}afterTickToLabelConversion(){bt(this.options.afterTickToLabelConversion,[this])}beforeCalculateLabelRotation(){bt(this.options.beforeCalculateLabelRotation,[this])}calculateLabelRotation(){const t=this.options,n=t.ticks,r=BI(this.ticks.length,t.ticks.maxTicksLimit),i=n.minRotation||0,o=n.maxRotation;let a=i,s,l,c;if(!this._isVisible()||!n.display||i>=o||r<=1||!this.isHorizontal()){this.labelRotation=i;return}const u=this._getLabelSizes(),d=u.widest.width,f=u.highest.height,p=$n(this.chart.width-d,0,this.maxWidth);s=t.offset?this.maxWidth/r:p/(r-1),d+6>s&&(s=p/(r-(t.offset?.5:1)),l=this.maxHeight-Zu(t.grid)-n.padding-zI(t.title,this.chart.options.font),c=Math.sqrt(d*d+f*f),a=Ole(Math.min(Math.asin($n((u.highest.height+6)/s,-1,1)),Math.asin($n(l/c,-1,1))-Math.asin($n(f/c,-1,1)))),a=Math.max(i,Math.min(o,a))),this.labelRotation=a}afterCalculateLabelRotation(){bt(this.options.afterCalculateLabelRotation,[this])}afterAutoSkip(){}beforeFit(){bt(this.options.beforeFit,[this])}fit(){const t={width:0,height:0},{chart:n,options:{ticks:r,title:i,grid:o}}=this,a=this._isVisible(),s=this.isHorizontal();if(a){const l=zI(i,n.options.font);if(s?(t.width=this.maxWidth,t.height=Zu(o)+l):(t.height=this.maxHeight,t.width=Zu(o)+l),r.display&&this.ticks.length){const{first:c,last:u,widest:d,highest:f}=this._getLabelSizes(),p=r.padding*2,m=jo(this.labelRotation),g=Math.cos(m),v=Math.sin(m);if(s){const x=r.mirror?0:v*d.width+g*f.height;t.height=Math.min(this.maxHeight,t.height+x+p)}else{const x=r.mirror?0:g*d.width+v*f.height;t.width=Math.min(this.maxWidth,t.width+x+p)}this._calculatePadding(c,u,v,g)}}this._handleMargins(),s?(this.width=this._length=n.width-this._margins.left-this._margins.right,this.height=t.height):(this.width=t.width,this.height=this._length=n.height-this._margins.top-this._margins.bottom)}_calculatePadding(t,n,r,i){const{ticks:{align:o,padding:a},position:s}=this.options,l=this.labelRotation!==0,c=s!=="top"&&this.axis==="x";if(this.isHorizontal()){const u=this.getPixelForTick(0)-this.left,d=this.right-this.getPixelForTick(this.ticks.length-1);let f=0,p=0;l?c?(f=i*t.width,p=r*n.height):(f=r*t.height,p=i*n.width):o==="start"?p=n.width:o==="end"?f=t.width:o!=="inner"&&(f=t.width/2,p=n.width/2),this.paddingLeft=Math.max((f-u+a)*this.width/(this.width-u),0),this.paddingRight=Math.max((p-d+a)*this.width/(this.width-d),0)}else{let u=n.height/2,d=t.height/2;o==="start"?(u=0,d=t.height):o==="end"&&(u=n.height,d=0),this.paddingTop=u+a,this.paddingBottom=d+a}}_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(){bt(this.options.afterFit,[this])}isHorizontal(){const{axis:t,position:n}=this.options;return n==="top"||n==="bottom"||t==="x"}isFullSize(){return this.options.fullSize}_convertTicksToLabels(t){this.beforeTickToLabelConversion(),this.generateTickLabels(t);let n,r;for(n=0,r=t.length;n<r;n++)Ke(t[n].label)&&(t.splice(n,1),r--,n--);this.afterTickToLabelConversion()}_getLabelSizes(){let t=this._labelSizes;if(!t){const n=this.options.ticks.sampleSize;let r=this.ticks;n<r.length&&(r=WI(r,n)),this._labelSizes=t=this._computeLabelSizes(r,r.length,this.options.ticks.maxTicksLimit)}return t}_computeLabelSizes(t,n,r){const{ctx:i,_longestTextCache:o}=this,a=[],s=[],l=Math.floor(n/BI(n,r));let c=0,u=0,d,f,p,m,g,v,x,_,w,y,E;for(d=0;d<n;d+=l){if(m=t[d].label,g=this._resolveTickFontOptions(d),i.font=v=g.string,x=o[v]=o[v]||{data:{},gc:[]},_=g.lineHeight,w=y=0,!Ke(m)&&!hn(m))w=QM(i,x.data,x.gc,w,m),y=_;else if(hn(m))for(f=0,p=m.length;f<p;++f)E=m[f],!Ke(E)&&!hn(E)&&(w=QM(i,x.data,x.gc,w,E),y+=_);a.push(w),s.push(y),c=Math.max(w,c),u=Math.max(y,u)}Kue(o,n);const S=a.indexOf(c),P=s.indexOf(u),D=T=>({width:a[T]||0,height:s[T]||0});return{first:D(0),last:D(n-1),widest:D(S),highest:D(P),widths:a,heights:s}}getLabelForValue(t){return t}getPixelForValue(t,n){return NaN}getValueForPixel(t){}getPixelForTick(t){const n=this.ticks;return t<0||t>n.length-1?null:this.getPixelForValue(n[t].value)}getPixelForDecimal(t){this._reversePixels&&(t=1-t);const n=this._startPixel+t*this._length;return kle(this._alignToPixels?ps(this.chart,n,0):n)}getDecimalForPixel(t){const n=(t-this._startPixel)/this._length;return this._reversePixels?1-n:n}getBasePixel(){return this.getPixelForValue(this.getBaseValue())}getBaseValue(){const{min:t,max:n}=this;return t<0&&n<0?n:t>0&&n>0?t:0}getContext(t){const n=this.ticks||[];if(t>=0&&t<n.length){const r=n[t];return r.$context||(r.$context=Gue(this.getContext(),t,r))}return this.$context||(this.$context=que(this.chart.getContext(),this))}_tickSize(){const t=this.options.ticks,n=jo(this.labelRotation),r=Math.abs(Math.cos(n)),i=Math.abs(Math.sin(n)),o=this._getLabelSizes(),a=t.autoSkipPadding||0,s=o?o.widest.width+a:0,l=o?o.highest.height+a:0;return this.isHorizontal()?l*r>s*i?s/r:l/i:l*i<s*r?l/r:s/i}_isVisible(){const t=this.options.display;return t!=="auto"?!!t:this.getMatchingVisibleMetas().length>0}_computeGridLineItems(t){const n=this.axis,r=this.chart,i=this.options,{grid:o,position:a,border:s}=i,l=o.offset,c=this.isHorizontal(),d=this.ticks.length+(l?1:0),f=Zu(o),p=[],m=s.setContext(this.getContext()),g=m.display?m.width:0,v=g/2,x=function(R){return ps(r,R,g)};let _,w,y,E,S,P,D,T,I,A,C,j;if(a==="top")_=x(this.bottom),P=this.bottom-f,T=_-v,A=x(t.top)+v,j=t.bottom;else if(a==="bottom")_=x(this.top),A=t.top,j=x(t.bottom)-v,P=_+v,T=this.top+f;else if(a==="left")_=x(this.right),S=this.right-f,D=_-v,I=x(t.left)+v,C=t.right;else if(a==="right")_=x(this.left),I=t.left,C=x(t.right)-v,S=_+v,D=this.left+f;else if(n==="x"){if(a==="center")_=x((t.top+t.bottom)/2+.5);else if(Me(a)){const R=Object.keys(a)[0],B=a[R];_=x(this.chart.scales[R].getPixelForValue(B))}A=t.top,j=t.bottom,P=_+v,T=P+f}else if(n==="y"){if(a==="center")_=x((t.left+t.right)/2);else if(Me(a)){const R=Object.keys(a)[0],B=a[R];_=x(this.chart.scales[R].getPixelForValue(B))}S=_-v,D=S-f,I=t.left,C=t.right}const N=Oe(i.ticks.maxTicksLimit,d),M=Math.max(1,Math.ceil(d/N));for(w=0;w<d;w+=M){const R=this.getContext(w),B=o.setContext(R),V=s.setContext(R),z=B.lineWidth,W=B.color,Q=V.dash||[],G=V.dashOffset,ie=B.tickWidth,J=B.tickColor,re=B.tickBorderDash||[],se=B.tickBorderDashOffset;y=Uue(this,w,l),y!==void 0&&(E=ps(r,y,z),c?S=D=I=C=E:P=T=A=j=E,p.push({tx1:S,ty1:P,tx2:D,ty2:T,x1:I,y1:A,x2:C,y2:j,width:z,color:W,borderDash:Q,borderDashOffset:G,tickWidth:ie,tickColor:J,tickBorderDash:re,tickBorderDashOffset:se}))}return this._ticksLength=d,this._borderValue=_,p}_computeLabelItems(t){const n=this.axis,r=this.options,{position:i,ticks:o}=r,a=this.isHorizontal(),s=this.ticks,{align:l,crossAlign:c,padding:u,mirror:d}=o,f=Zu(r.grid),p=f+u,m=d?-u:p,g=-jo(this.labelRotation),v=[];let x,_,w,y,E,S,P,D,T,I,A,C,j="middle";if(i==="top")S=this.bottom-m,P=this._getXAxisLabelAlignment();else if(i==="bottom")S=this.top+m,P=this._getXAxisLabelAlignment();else if(i==="left"){const M=this._getYAxisLabelAlignment(f);P=M.textAlign,E=M.x}else if(i==="right"){const M=this._getYAxisLabelAlignment(f);P=M.textAlign,E=M.x}else if(n==="x"){if(i==="center")S=(t.top+t.bottom)/2+p;else if(Me(i)){const M=Object.keys(i)[0],R=i[M];S=this.chart.scales[M].getPixelForValue(R)+p}P=this._getXAxisLabelAlignment()}else if(n==="y"){if(i==="center")E=(t.left+t.right)/2-p;else if(Me(i)){const M=Object.keys(i)[0],R=i[M];E=this.chart.scales[M].getPixelForValue(R)}P=this._getYAxisLabelAlignment(f).textAlign}n==="y"&&(l==="start"?j="top":l==="end"&&(j="bottom"));const N=this._getLabelSizes();for(x=0,_=s.length;x<_;++x){w=s[x],y=w.label;const M=o.setContext(this.getContext(x));D=this.getPixelForTick(x)+o.labelOffset,T=this._resolveTickFontOptions(x),I=T.lineHeight,A=hn(y)?y.length:1;const R=A/2,B=M.color,V=M.textStrokeColor,z=M.textStrokeWidth;let W=P;a?(E=D,P==="inner"&&(x===_-1?W=this.options.reverse?"left":"right":x===0?W=this.options.reverse?"right":"left":W="center"),i==="top"?c==="near"||g!==0?C=-A*I+I/2:c==="center"?C=-N.highest.height/2-R*I+I:C=-N.highest.height+I/2:c==="near"||g!==0?C=I/2:c==="center"?C=N.highest.height/2-R*I:C=N.highest.height-A*I,d&&(C*=-1),g!==0&&!M.showLabelBackdrop&&(E+=I/2*Math.sin(g))):(S=D,C=(1-A)*I/2);let Q;if(M.showLabelBackdrop){const G=li(M.backdropPadding),ie=N.heights[x],J=N.widths[x];let re=C-G.top,se=0-G.left;switch(j){case"middle":re-=ie/2;break;case"bottom":re-=ie;break}switch(P){case"center":se-=J/2;break;case"right":se-=J;break;case"inner":x===_-1?se-=J:x>0&&(se-=J/2);break}Q={left:se,top:re,width:J+G.width,height:ie+G.height,color:M.backdropColor}}v.push({label:y,font:T,textOffset:C,options:{rotation:g,color:B,strokeColor:V,strokeWidth:z,textAlign:W,textBaseline:j,translation:[E,S],backdrop:Q}})}return v}_getXAxisLabelAlignment(){const{position:t,ticks:n}=this.options;if(-jo(this.labelRotation))return t==="top"?"left":"right";let i="center";return n.align==="start"?i="left":n.align==="end"?i="right":n.align==="inner"&&(i="inner"),i}_getYAxisLabelAlignment(t){const{position:n,ticks:{crossAlign:r,mirror:i,padding:o}}=this.options,a=this._getLabelSizes(),s=t+o,l=a.widest.width;let c,u;return n==="left"?i?(u=this.right+o,r==="near"?c="left":r==="center"?(c="center",u+=l/2):(c="right",u+=l)):(u=this.right-s,r==="near"?c="right":r==="center"?(c="center",u-=l/2):(c="left",u=this.left)):n==="right"?i?(u=this.left+o,r==="near"?c="right":r==="center"?(c="center",u-=l/2):(c="left",u-=l)):(u=this.left+s,r==="near"?c="left":r==="center"?(c="center",u+=l/2):(c="right",u=this.right)):c="right",{textAlign:c,x:u}}_computeLabelArea(){if(this.options.ticks.mirror)return;const t=this.chart,n=this.options.position;if(n==="left"||n==="right")return{top:0,left:this.left,bottom:t.height,right:this.right};if(n==="top"||n==="bottom")return{top:this.top,left:0,bottom:this.bottom,right:t.width}}drawBackground(){const{ctx:t,options:{backgroundColor:n},left:r,top:i,width:o,height:a}=this;n&&(t.save(),t.fillStyle=n,t.fillRect(r,i,o,a),t.restore())}getLineWidthForValue(t){const n=this.options.grid;if(!this._isVisible()||!n.display)return 0;const i=this.ticks.findIndex(o=>o.value===t);return i>=0?n.setContext(this.getContext(i)).lineWidth:0}drawGrid(t){const n=this.options.grid,r=this.ctx,i=this._gridLineItems||(this._gridLineItems=this._computeGridLineItems(t));let o,a;const s=(l,c,u)=>{!u.width||!u.color||(r.save(),r.lineWidth=u.width,r.strokeStyle=u.color,r.setLineDash(u.borderDash||[]),r.lineDashOffset=u.borderDashOffset,r.beginPath(),r.moveTo(l.x,l.y),r.lineTo(c.x,c.y),r.stroke(),r.restore())};if(n.display)for(o=0,a=i.length;o<a;++o){const l=i[o];n.drawOnChartArea&&s({x:l.x1,y:l.y1},{x:l.x2,y:l.y2},l),n.drawTicks&&s({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:t,ctx:n,options:{border:r,grid:i}}=this,o=r.setContext(this.getContext()),a=r.display?o.width:0;if(!a)return;const s=i.setContext(this.getContext(0)).lineWidth,l=this._borderValue;let c,u,d,f;this.isHorizontal()?(c=ps(t,this.left,a)-a/2,u=ps(t,this.right,s)+s/2,d=f=l):(d=ps(t,this.top,a)-a/2,f=ps(t,this.bottom,s)+s/2,c=u=l),n.save(),n.lineWidth=o.width,n.strokeStyle=o.color,n.beginPath(),n.moveTo(c,d),n.lineTo(u,f),n.stroke(),n.restore()}drawLabels(t){if(!this.options.ticks.display)return;const r=this.ctx,i=this._computeLabelArea();i&&h1(r,i);const o=this.getLabelItems(t);for(const a of o){const s=a.options,l=a.font,c=a.label,u=a.textOffset;Hh(r,c,0,u,l,s)}i&&m1(r)}drawTitle(){const{ctx:t,options:{position:n,title:r,reverse:i}}=this;if(!r.display)return;const o=cr(r.font),a=li(r.padding),s=r.align;let l=o.lineHeight/2;n==="bottom"||n==="center"||Me(n)?(l+=a.bottom,hn(r.text)&&(l+=o.lineHeight*(r.text.length-1))):l+=a.top;const{titleX:c,titleY:u,maxWidth:d,rotation:f}=Que(this,l,n,s);Hh(t,r.text,0,0,o,{color:r.color,maxWidth:d,rotation:f,textAlign:Xue(s,n,i),textBaseline:"middle",translation:[c,u]})}draw(t){this._isVisible()&&(this.drawBackground(),this.drawGrid(t),this.drawBorder(),this.drawTitle(),this.drawLabels(t))}_layers(){const t=this.options,n=t.ticks&&t.ticks.z||0,r=Oe(t.grid&&t.grid.z,-1),i=Oe(t.border&&t.border.z,0);return!this._isVisible()||this.draw!==$l.prototype.draw?[{z:n,draw:o=>{this.draw(o)}}]:[{z:r,draw:o=>{this.drawBackground(),this.drawGrid(o),this.drawTitle()}},{z:i,draw:()=>{this.drawBorder()}},{z:n,draw:o=>{this.drawLabels(o)}}]}getMatchingVisibleMetas(t){const n=this.chart.getSortedVisibleDatasetMetas(),r=this.axis+"AxisID",i=[];let o,a;for(o=0,a=n.length;o<a;++o){const s=n[o];s[r]===this.id&&(!t||s.type===t)&&i.push(s)}return i}_resolveTickFontOptions(t){const n=this.options.ticks.setContext(this.getContext(t));return cr(n.font)}_maxDigits(){const t=this._resolveTickFontOptions(0).lineHeight;return(this.isHorizontal()?this.width:this.height)/t}}class im{constructor(t,n,r){this.type=t,this.scope=n,this.override=r,this.items=Object.create(null)}isForType(t){return Object.prototype.isPrototypeOf.call(this.type.prototype,t.prototype)}register(t){const n=Object.getPrototypeOf(t);let r;ede(n)&&(r=this.register(n));const i=this.items,o=t.id,a=this.scope+"."+o;if(!o)throw new Error("class does not have id: "+t);return o in i||(i[o]=t,Zue(t,a,r),this.override&&zt.override(t.id,t.overrides)),a}get(t){return this.items[t]}unregister(t){const n=this.items,r=t.id,i=this.scope;r in n&&delete n[r],i&&r in zt[i]&&(delete zt[i][r],this.override&&delete fs[r])}}function Zue(e,t,n){const r=Ru(Object.create(null),[n?zt.get(n):{},zt.get(t),e.defaults]);zt.set(t,r),e.defaultRoutes&&Jue(t,e.defaultRoutes),e.descriptors&&zt.describe(t,e.descriptors)}function Jue(e,t){Object.keys(t).forEach(n=>{const r=n.split("."),i=r.pop(),o=[e].concat(r).join("."),a=t[n].split("."),s=a.pop(),l=a.join(".");zt.route(o,i,l,s)})}function ede(e){return"id"in e&&"defaults"in e}class tde{constructor(){this.controllers=new im(Zh,"datasets",!0),this.elements=new im(va,"elements"),this.plugins=new im(Object,"plugins"),this.scales=new im($l,"scales"),this._typedRegistries=[this.controllers,this.scales,this.elements]}add(...t){this._each("register",t)}remove(...t){this._each("unregister",t)}addControllers(...t){this._each("register",t,this.controllers)}addElements(...t){this._each("register",t,this.elements)}addPlugins(...t){this._each("register",t,this.plugins)}addScales(...t){this._each("register",t,this.scales)}getController(t){return this._get(t,this.controllers,"controller")}getElement(t){return this._get(t,this.elements,"element")}getPlugin(t){return this._get(t,this.plugins,"plugin")}getScale(t){return this._get(t,this.scales,"scale")}removeControllers(...t){this._each("unregister",t,this.controllers)}removeElements(...t){this._each("unregister",t,this.elements)}removePlugins(...t){this._each("unregister",t,this.plugins)}removeScales(...t){this._each("unregister",t,this.scales)}_each(t,n,r){[...n].forEach(i=>{const o=r||this._getRegistryForType(i);r||o.isForType(i)||o===this.plugins&&i.id?this._exec(t,o,i):et(i,a=>{const s=r||this._getRegistryForType(a);this._exec(t,s,a)})})}_exec(t,n,r){const i=o1(t);bt(r["before"+i],[],r),n[t](r),bt(r["after"+i],[],r)}_getRegistryForType(t){for(let n=0;n<this._typedRegistries.length;n++){const r=this._typedRegistries[n];if(r.isForType(t))return r}return this.plugins}_get(t,n,r){const i=n.get(t);if(i===void 0)throw new Error('"'+t+'" is not a registered '+r+".");return i}}var Yi=new tde;class nde{constructor(){this._init=[]}notify(t,n,r,i){n==="beforeInit"&&(this._init=this._createDescriptors(t,!0),this._notify(this._init,t,"install"));const o=i?this._descriptors(t).filter(i):this._descriptors(t),a=this._notify(o,t,n,r);return n==="afterDestroy"&&(this._notify(o,t,"stop"),this._notify(this._init,t,"uninstall")),a}_notify(t,n,r,i){i=i||{};for(const o of t){const a=o.plugin,s=a[r],l=[n,i,o.options];if(bt(s,l,a)===!1&&i.cancelable)return!1}return!0}invalidate(){Ke(this._cache)||(this._oldCache=this._cache,this._cache=void 0)}_descriptors(t){if(this._cache)return this._cache;const n=this._cache=this._createDescriptors(t);return this._notifyStateChanges(t),n}_createDescriptors(t,n){const r=t&&t.config,i=Oe(r.options&&r.options.plugins,{}),o=rde(r);return i===!1&&!n?[]:ode(t,o,i,n)}_notifyStateChanges(t){const n=this._oldCache||[],r=this._cache,i=(o,a)=>o.filter(s=>!a.some(l=>s.plugin.id===l.plugin.id));this._notify(i(n,r),t,"stop"),this._notify(i(r,n),t,"start")}}function rde(e){const t={},n=[],r=Object.keys(Yi.plugins.items);for(let o=0;o<r.length;o++)n.push(Yi.getPlugin(r[o]));const i=e.plugins||[];for(let o=0;o<i.length;o++){const a=i[o];n.indexOf(a)===-1&&(n.push(a),t[a.id]=!0)}return{plugins:n,localIds:t}}function ide(e,t){return!t&&e===!1?null:e===!0?{}:e}function ode(e,{plugins:t,localIds:n},r,i){const o=[],a=e.getContext();for(const s of t){const l=s.id,c=ide(r[l],i);c!==null&&o.push({plugin:s,options:ade(e.config,{plugin:s,local:n[l]},c,a)})}return o}function ade(e,{plugin:t,local:n},r,i){const o=e.pluginScopeKeys(t),a=e.getOptionScopes(r,o);return n&&t.defaults&&a.push(t.defaults),e.createResolver(a,i,[""],{scriptable:!1,indexable:!1,allKeys:!0})}function A1(e,t){const n=zt.datasets[e]||{};return((t.datasets||{})[e]||{}).indexAxis||t.indexAxis||n.indexAxis||"x"}function sde(e,t){let n=e;return e==="_index_"?n=t:e==="_value_"&&(n=t==="x"?"y":"x"),n}function lde(e,t){return e===t?"_index_":"_value_"}function VI(e){if(e==="x"||e==="y"||e==="r")return e}function cde(e){if(e==="top"||e==="bottom")return"x";if(e==="left"||e==="right")return"y"}function T1(e,...t){if(VI(e))return e;for(const n of t){const r=n.axis||cde(n.position)||e.length>1&&VI(e[0].toLowerCase());if(r)return r}throw new Error(`Cannot determine type of '${e}' axis. Please provide 'axis' or 'position' option.`)}function HI(e,t,n){if(n[t+"AxisID"]===e)return{axis:t}}function ude(e,t){if(t.data&&t.data.datasets){const n=t.data.datasets.filter(r=>r.xAxisID===e||r.yAxisID===e);if(n.length)return HI(e,"x",n[0])||HI(e,"y",n[0])}return{}}function dde(e,t){const n=fs[e.type]||{scales:{}},r=t.scales||{},i=A1(e.type,t),o=Object.create(null);return Object.keys(r).forEach(a=>{const s=r[a];if(!Me(s))return console.error(`Invalid scale configuration for scale: ${a}`);if(s._proxy)return console.warn(`Ignoring resolver passed as options for scale: ${a}`);const l=T1(a,s,ude(a,e),zt.scales[s.type]),c=lde(l,i),u=n.scales||{};o[a]=$u(Object.create(null),[{axis:l},s,u[l],u[c]])}),e.data.datasets.forEach(a=>{const s=a.type||e.type,l=a.indexAxis||A1(s,t),u=(fs[s]||{}).scales||{};Object.keys(u).forEach(d=>{const f=sde(d,l),p=a[f+"AxisID"]||f;o[p]=o[p]||Object.create(null),$u(o[p],[{axis:f},r[p],u[d]])})}),Object.keys(o).forEach(a=>{const s=o[a];$u(s,[zt.scales[s.type],zt.scale])}),o}function YI(e){const t=e.options||(e.options={});t.plugins=Oe(t.plugins,{}),t.scales=dde(e,t)}function UI(e){return e=e||{},e.datasets=e.datasets||[],e.labels=e.labels||[],e}function fde(e){return e=e||{},e.data=UI(e.data),YI(e),e}const KI=new Map,qI=new Set;function om(e,t){let n=KI.get(e);return n||(n=t(),KI.set(e,n),qI.add(n)),n}const Ju=(e,t,n)=>{const r=cs(t,n);r!==void 0&&e.add(r)};class pde{constructor(t){this._config=fde(t),this._scopeCache=new Map,this._resolverCache=new Map}get platform(){return this._config.platform}get type(){return this._config.type}set type(t){this._config.type=t}get data(){return this._config.data}set data(t){this._config.data=UI(t)}get options(){return this._config.options}set options(t){this._config.options=t}get plugins(){return this._config.plugins}update(){const t=this._config;this.clearCache(),YI(t)}clearCache(){this._scopeCache.clear(),this._resolverCache.clear()}datasetScopeKeys(t){return om(t,()=>[[`datasets.${t}`,""]])}datasetAnimationScopeKeys(t,n){return om(`${t}.transition.${n}`,()=>[[`datasets.${t}.transitions.${n}`,`transitions.${n}`],[`datasets.${t}`,""]])}datasetElementScopeKeys(t,n){return om(`${t}-${n}`,()=>[[`datasets.${t}.elements.${n}`,`datasets.${t}`,`elements.${n}`,""]])}pluginScopeKeys(t){const n=t.id,r=this.type;return om(`${r}-plugin-${n}`,()=>[[`plugins.${n}`,...t.additionalOptionScopes||[]]])}_cachedScopes(t,n){const r=this._scopeCache;let i=r.get(t);return(!i||n)&&(i=new Map,r.set(t,i)),i}getOptionScopes(t,n,r){const{options:i,type:o}=this,a=this._cachedScopes(t,r),s=a.get(n);if(s)return s;const l=new Set;n.forEach(u=>{t&&(l.add(t),u.forEach(d=>Ju(l,t,d))),u.forEach(d=>Ju(l,i,d)),u.forEach(d=>Ju(l,fs[o]||{},d)),u.forEach(d=>Ju(l,zt,d)),u.forEach(d=>Ju(l,d1,d))});const c=Array.from(l);return c.length===0&&c.push(Object.create(null)),qI.has(n)&&a.set(n,c),c}chartOptionScopes(){const{options:t,type:n}=this;return[t,fs[n]||{},zt.datasets[n]||{},{type:n},zt,d1]}resolveNamedOptions(t,n,r,i=[""]){const o={$shared:!0},{resolver:a,subPrefixes:s}=GI(this._resolverCache,t,i);let l=a;if(mde(a,n)){o.$shared=!1,r=ha(r)?r():r;const c=this.createResolver(t,r,s);l=Fl(a,r,c)}for(const c of n)o[c]=l[c];return o}createResolver(t,n,r=[""],i){const{resolver:o}=GI(this._resolverCache,t,r);return Me(n)?Fl(o,n,void 0,i):o}}function GI(e,t,n){let r=e.get(t);r||(r=new Map,e.set(t,r));const i=n.join();let o=r.get(i);return o||(o={resolver:v1(t,n),subPrefixes:n.filter(s=>!s.toLowerCase().includes("hover"))},r.set(i,o)),o}const hde=e=>Me(e)&&Object.getOwnPropertyNames(e).some(t=>ha(e[t]));function mde(e,t){const{isScriptable:n,isIndexable:r}=tI(e);for(const i of t){const o=n(i),a=r(i),s=(a||o)&&e[i];if(o&&(ha(s)||hde(s))||a&&hn(s))return!0}return!1}var gde="4.5.0";const vde=["top","bottom","left","right","chartArea"];function XI(e,t){return e==="top"||e==="bottom"||vde.indexOf(e)===-1&&t==="x"}function QI(e,t){return function(n,r){return n[e]===r[e]?n[t]-r[t]:n[e]-r[e]}}function ZI(e){const t=e.chart,n=t.options.animation;t.notifyPlugins("afterRender"),bt(n&&n.onComplete,[e],t)}function yde(e){const t=e.chart,n=t.options.animation;bt(n&&n.onProgress,[e],t)}function JI(e){return x1()&&typeof e=="string"?e=document.getElementById(e):e&&e.length&&(e=e[0]),e&&e.canvas&&(e=e.canvas),e}const am={},e4=e=>{const t=JI(e);return Object.values(am).filter(n=>n.canvas===t).pop()};function bde(e,t,n){const r=Object.keys(e);for(const i of r){const o=+i;if(o>=t){const a=e[i];delete e[i],(n>0||o>t)&&(e[o+n]=a)}}}function xde(e,t,n,r){return!n||e.type==="mouseout"?null:r?t:e}let Bn=class{static defaults=zt;static instances=am;static overrides=fs;static registry=Yi;static version=gde;static getChart=e4;static register(...t){Yi.add(...t),t4()}static unregister(...t){Yi.remove(...t),t4()}constructor(t,n){const r=this.config=new pde(n),i=JI(t),o=e4(i);if(o)throw new Error("Canvas is already in use. Chart with ID '"+o.id+"' must be destroyed before the canvas with ID '"+o.canvas.id+"' can be reused.");const a=r.createResolver(r.chartOptionScopes(),this.getContext());this.platform=new(r.platform||Rue(i)),this.platform.updateConfig(r);const s=this.platform.acquireContext(i,a.aspectRatio),l=s&&s.canvas,c=l&&l.height,u=l&&l.width;if(this.id=fle(),this.ctx=s,this.canvas=l,this.width=u,this.height=c,this._options=a,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 nde,this.$proxies={},this._hiddenIndices={},this.attached=!1,this._animationsDisabled=void 0,this.$context=void 0,this._doResize=Tle(d=>this.update(d),a.resizeDelay||0),this._dataChanges=[],am[this.id]=this,!s||!l){console.error("Failed to create chart: can't acquire context from the given item");return}Mo.listen(this,"complete",ZI),Mo.listen(this,"progress",yde),this._initialize(),this.attached&&this.update()}get aspectRatio(){const{options:{aspectRatio:t,maintainAspectRatio:n},width:r,height:i,_aspectRatio:o}=this;return Ke(t)?n&&o?o:i?r/i:null:t}get data(){return this.config.data}set data(t){this.config.data=t}get options(){return this._options}set options(t){this.config.options=t}get registry(){return Yi}_initialize(){return this.notifyPlugins("beforeInit"),this.options.responsive?this.resize():lI(this,this.options.devicePixelRatio),this.bindEvents(),this.notifyPlugins("afterInit"),this}clear(){return ZM(this.canvas,this.ctx),this}stop(){return Mo.stop(this),this}resize(t,n){Mo.running(this)?this._resizeBeforeDraw={width:t,height:n}:this._resize(t,n)}_resize(t,n){const r=this.options,i=this.canvas,o=r.maintainAspectRatio&&this.aspectRatio,a=this.platform.getMaximumSize(i,t,n,o),s=r.devicePixelRatio||this.platform.getDevicePixelRatio(),l=this.width?"resize":"attach";this.width=a.width,this.height=a.height,this._aspectRatio=this.aspectRatio,lI(this,s,!0)&&(this.notifyPlugins("resize",{size:a}),bt(r.onResize,[this,a],this),this.attached&&this._doResize(l)&&this.render())}ensureScalesHaveIDs(){const n=this.options.scales||{};et(n,(r,i)=>{r.id=i})}buildOrUpdateScales(){const t=this.options,n=t.scales,r=this.scales,i=Object.keys(r).reduce((a,s)=>(a[s]=!1,a),{});let o=[];n&&(o=o.concat(Object.keys(n).map(a=>{const s=n[a],l=T1(a,s),c=l==="r",u=l==="x";return{options:s,dposition:c?"chartArea":u?"bottom":"left",dtype:c?"radialLinear":u?"category":"linear"}}))),et(o,a=>{const s=a.options,l=s.id,c=T1(l,s),u=Oe(s.type,a.dtype);(s.position===void 0||XI(s.position,c)!==XI(a.dposition))&&(s.position=a.dposition),i[l]=!0;let d=null;if(l in r&&r[l].type===u)d=r[l];else{const f=Yi.getScale(u);d=new f({id:l,type:u,ctx:this.ctx,chart:this}),r[d.id]=d}d.init(s,t)}),et(i,(a,s)=>{a||delete r[s]}),et(r,a=>{ga.configure(this,a,a.options),ga.addBox(this,a)})}_updateMetasets(){const t=this._metasets,n=this.data.datasets.length,r=t.length;if(t.sort((i,o)=>i.index-o.index),r>n){for(let i=n;i<r;++i)this._destroyDatasetMeta(i);t.splice(n,r-n)}this._sortedMetasets=t.slice(0).sort(QI("order","index"))}_removeUnreferencedMetasets(){const{_metasets:t,data:{datasets:n}}=this;t.length>n.length&&delete this._stacks,t.forEach((r,i)=>{n.filter(o=>o===r._dataset).length===0&&this._destroyDatasetMeta(i)})}buildOrUpdateControllers(){const t=[],n=this.data.datasets;let r,i;for(this._removeUnreferencedMetasets(),r=0,i=n.length;r<i;r++){const o=n[r];let a=this.getDatasetMeta(r);const s=o.type||this.config.type;if(a.type&&a.type!==s&&(this._destroyDatasetMeta(r),a=this.getDatasetMeta(r)),a.type=s,a.indexAxis=o.indexAxis||A1(s,this.options),a.order=o.order||0,a.index=r,a.label=""+o.label,a.visible=this.isDatasetVisible(r),a.controller)a.controller.updateIndex(r),a.controller.linkScales();else{const l=Yi.getController(s),{datasetElementType:c,dataElementType:u}=zt.datasets[s];Object.assign(l,{dataElementType:Yi.getElement(u),datasetElementType:c&&Yi.getElement(c)}),a.controller=new l(this,r),t.push(a.controller)}}return this._updateMetasets(),t}_resetElements(){et(this.data.datasets,(t,n)=>{this.getDatasetMeta(n).controller.reset()},this)}reset(){this._resetElements(),this.notifyPlugins("reset")}update(t){const n=this.config;n.update();const r=this._options=n.createResolver(n.chartOptionScopes(),this.getContext()),i=this._animationsDisabled=!r.animation;if(this._updateScales(),this._checkEventBindings(),this._updateHiddenIndices(),this._plugins.invalidate(),this.notifyPlugins("beforeUpdate",{mode:t,cancelable:!0})===!1)return;const o=this.buildOrUpdateControllers();this.notifyPlugins("beforeElementsUpdate");let a=0;for(let c=0,u=this.data.datasets.length;c<u;c++){const{controller:d}=this.getDatasetMeta(c),f=!i&&o.indexOf(d)===-1;d.buildOrUpdateElements(f),a=Math.max(+d.getMaxOverflow(),a)}a=this._minPadding=r.layout.autoPadding?a:0,this._updateLayout(a),i||et(o,c=>{c.reset()}),this._updateDatasets(t),this.notifyPlugins("afterUpdate",{mode:t}),this._layers.sort(QI("z","_idx"));const{_active:s,_lastEvent:l}=this;l?this._eventHandler(l,!0):s.length&&this._updateHoverStyles(s,s,!0),this.render()}_updateScales(){et(this.scales,t=>{ga.removeBox(this,t)}),this.ensureScalesHaveIDs(),this.buildOrUpdateScales()}_checkEventBindings(){const t=this.options,n=new Set(Object.keys(this._listeners)),r=new Set(t.events);(!MM(n,r)||!!this._responsiveListeners!==t.responsive)&&(this.unbindEvents(),this.bindEvents())}_updateHiddenIndices(){const{_hiddenIndices:t}=this,n=this._getUniformDataChanges()||[];for(const{method:r,start:i,count:o}of n){const a=r==="_removeElements"?-o:o;bde(t,i,a)}}_getUniformDataChanges(){const t=this._dataChanges;if(!t||!t.length)return;this._dataChanges=[];const n=this.data.datasets.length,r=o=>new Set(t.filter(a=>a[0]===o).map((a,s)=>s+","+a.splice(1).join(","))),i=r(0);for(let o=1;o<n;o++)if(!MM(i,r(o)))return;return Array.from(i).map(o=>o.split(",")).map(o=>({method:o[1],start:+o[2],count:+o[3]}))}_updateLayout(t){if(this.notifyPlugins("beforeLayout",{cancelable:!0})===!1)return;ga.update(this,this.width,this.height,t);const n=this.chartArea,r=n.width<=0||n.height<=0;this._layers=[],et(this.boxes,i=>{r&&i.position==="chartArea"||(i.configure&&i.configure(),this._layers.push(...i._layers()))},this),this._layers.forEach((i,o)=>{i._idx=o}),this.notifyPlugins("afterLayout")}_updateDatasets(t){if(this.notifyPlugins("beforeDatasetsUpdate",{mode:t,cancelable:!0})!==!1){for(let n=0,r=this.data.datasets.length;n<r;++n)this.getDatasetMeta(n).controller.configure();for(let n=0,r=this.data.datasets.length;n<r;++n)this._updateDataset(n,ha(t)?t({datasetIndex:n}):t);this.notifyPlugins("afterDatasetsUpdate",{mode:t})}}_updateDataset(t,n){const r=this.getDatasetMeta(t),i={meta:r,index:t,mode:n,cancelable:!0};this.notifyPlugins("beforeDatasetUpdate",i)!==!1&&(r.controller._update(n),i.cancelable=!1,this.notifyPlugins("afterDatasetUpdate",i))}render(){this.notifyPlugins("beforeRender",{cancelable:!0})!==!1&&(Mo.has(this)?this.attached&&!Mo.running(this)&&Mo.start(this):(this.draw(),ZI({chart:this})))}draw(){let t;if(this._resizeBeforeDraw){const{width:r,height:i}=this._resizeBeforeDraw;this._resizeBeforeDraw=null,this._resize(r,i)}if(this.clear(),this.width<=0||this.height<=0||this.notifyPlugins("beforeDraw",{cancelable:!0})===!1)return;const n=this._layers;for(t=0;t<n.length&&n[t].z<=0;++t)n[t].draw(this.chartArea);for(this._drawDatasets();t<n.length;++t)n[t].draw(this.chartArea);this.notifyPlugins("afterDraw")}_getSortedDatasetMetas(t){const n=this._sortedMetasets,r=[];let i,o;for(i=0,o=n.length;i<o;++i){const a=n[i];(!t||a.visible)&&r.push(a)}return r}getSortedVisibleDatasetMetas(){return this._getSortedDatasetMetas(!0)}_drawDatasets(){if(this.notifyPlugins("beforeDatasetsDraw",{cancelable:!0})===!1)return;const t=this.getSortedVisibleDatasetMetas();for(let n=t.length-1;n>=0;--n)this._drawDataset(t[n]);this.notifyPlugins("afterDatasetsDraw")}_drawDataset(t){const n=this.ctx,r={meta:t,index:t.index,cancelable:!0},i=Lce(this,t);this.notifyPlugins("beforeDatasetDraw",r)!==!1&&(i&&h1(n,i),t.controller.draw(),i&&m1(n),r.cancelable=!1,this.notifyPlugins("afterDatasetDraw",r))}isPointInArea(t){return Uu(t,this.chartArea,this._minPadding)}getElementsAtEventForMode(t,n,r,i){const o=vue.modes[n];return typeof o=="function"?o(this,t,r,i):[]}getDatasetMeta(t){const n=this.data.datasets[t],r=this._metasets;let i=r.filter(o=>o&&o._dataset===n).pop();return i||(i={type:null,data:[],dataset:null,controller:null,hidden:null,xAxisID:null,yAxisID:null,order:n&&n.order||0,index:t,_dataset:n,_parsed:[],_sorted:!1},r.push(i)),i}getContext(){return this.$context||(this.$context=hs(null,{chart:this,type:"chart"}))}getVisibleDatasetCount(){return this.getSortedVisibleDatasetMetas().length}isDatasetVisible(t){const n=this.data.datasets[t];if(!n)return!1;const r=this.getDatasetMeta(t);return typeof r.hidden=="boolean"?!r.hidden:!n.hidden}setDatasetVisibility(t,n){const r=this.getDatasetMeta(t);r.hidden=!n}toggleDataVisibility(t){this._hiddenIndices[t]=!this._hiddenIndices[t]}getDataVisibility(t){return!this._hiddenIndices[t]}_updateVisibility(t,n,r){const i=r?"show":"hide",o=this.getDatasetMeta(t),a=o.controller._resolveAnimations(void 0,i);Bu(n)?(o.data[n].hidden=!r,this.update()):(this.setDatasetVisibility(t,r),a.update(o,{visible:r}),this.update(s=>s.datasetIndex===t?i:void 0))}hide(t,n){this._updateVisibility(t,n,!1)}show(t,n){this._updateVisibility(t,n,!0)}_destroyDatasetMeta(t){const n=this._metasets[t];n&&n.controller&&n.controller._destroy(),delete this._metasets[t]}_stop(){let t,n;for(this.stop(),Mo.remove(this),t=0,n=this.data.datasets.length;t<n;++t)this._destroyDatasetMeta(t)}destroy(){this.notifyPlugins("beforeDestroy");const{canvas:t,ctx:n}=this;this._stop(),this.config.clearCache(),t&&(this.unbindEvents(),ZM(t,n),this.platform.releaseContext(n),this.canvas=null,this.ctx=null),delete am[this.id],this.notifyPlugins("afterDestroy")}toBase64Image(...t){return this.canvas.toDataURL(...t)}bindEvents(){this.bindUserEvents(),this.options.responsive?this.bindResponsiveEvents():this.attached=!0}bindUserEvents(){const t=this._listeners,n=this.platform,r=(o,a)=>{n.addEventListener(this,o,a),t[o]=a},i=(o,a,s)=>{o.offsetX=a,o.offsetY=s,this._eventHandler(o)};et(this.options.events,o=>r(o,i))}bindResponsiveEvents(){this._responsiveListeners||(this._responsiveListeners={});const t=this._responsiveListeners,n=this.platform,r=(l,c)=>{n.addEventListener(this,l,c),t[l]=c},i=(l,c)=>{t[l]&&(n.removeEventListener(this,l,c),delete t[l])},o=(l,c)=>{this.canvas&&this.resize(l,c)};let a;const s=()=>{i("attach",s),this.attached=!0,this.resize(),r("resize",o),r("detach",a)};a=()=>{this.attached=!1,i("resize",o),this._stop(),this._resize(0,0),r("attach",s)},n.isAttached(this.canvas)?s():a()}unbindEvents(){et(this._listeners,(t,n)=>{this.platform.removeEventListener(this,n,t)}),this._listeners={},et(this._responsiveListeners,(t,n)=>{this.platform.removeEventListener(this,n,t)}),this._responsiveListeners=void 0}updateHoverStyle(t,n,r){const i=r?"set":"remove";let o,a,s,l;for(n==="dataset"&&(o=this.getDatasetMeta(t[0].datasetIndex),o.controller["_"+i+"DatasetHoverStyle"]()),s=0,l=t.length;s<l;++s){a=t[s];const c=a&&this.getDatasetMeta(a.datasetIndex).controller;c&&c[i+"HoverStyle"](a.element,a.datasetIndex,a.index)}}getActiveElements(){return this._active||[]}setActiveElements(t){const n=this._active||[],r=t.map(({datasetIndex:o,index:a})=>{const s=this.getDatasetMeta(o);if(!s)throw new Error("No dataset found at index "+o);return{datasetIndex:o,element:s.data[a],index:a}});!Bh(r,n)&&(this._active=r,this._lastEvent=null,this._updateHoverStyles(r,n))}notifyPlugins(t,n,r){return this._plugins.notify(this,t,n,r)}isPluginEnabled(t){return this._plugins._cache.filter(n=>n.plugin.id===t).length===1}_updateHoverStyles(t,n,r){const i=this.options.hover,o=(l,c)=>l.filter(u=>!c.some(d=>u.datasetIndex===d.datasetIndex&&u.index===d.index)),a=o(n,t),s=r?t:o(t,n);a.length&&this.updateHoverStyle(a,i.mode,!1),s.length&&i.mode&&this.updateHoverStyle(s,i.mode,!0)}_eventHandler(t,n){const r={event:t,replay:n,cancelable:!0,inChartArea:this.isPointInArea(t)},i=a=>(a.options.events||this.options.events).includes(t.native.type);if(this.notifyPlugins("beforeEvent",r,i)===!1)return;const o=this._handleEvent(t,n,r.inChartArea);return r.cancelable=!1,this.notifyPlugins("afterEvent",r,i),(o||r.changed)&&this.render(),this}_handleEvent(t,n,r){const{_active:i=[],options:o}=this,a=n,s=this._getActiveElements(t,i,r,a),l=yle(t),c=xde(t,this._lastEvent,r,l);r&&(this._lastEvent=null,bt(o.onHover,[t,s,this],this),l&&bt(o.onClick,[t,s,this],this));const u=!Bh(s,i);return(u||n)&&(this._active=s,this._updateHoverStyles(s,i,n)),this._lastEvent=c,u}_getActiveElements(t,n,r,i){if(t.type==="mouseout")return[];if(!r)return n;const o=this.options.hover;return this.getElementsAtEventForMode(t,o.mode,o,i)}};function t4(){return et(Bn.instances,e=>e._plugins.invalidate())}function wde(e,t,n){const{startAngle:r,x:i,y:o,outerRadius:a,innerRadius:s,options:l}=t,{borderWidth:c,borderJoinStyle:u}=l,d=Math.min(c/a,si(r-n));if(e.beginPath(),e.arc(i,o,a-c/2,r+d/2,n-d/2),s>0){const f=Math.min(c/s,si(r-n));e.arc(i,o,s+c/2,n-f/2,r+f/2,!0)}else{const f=Math.min(c/2,a*si(r-n));if(u==="round")e.arc(i,o,f,n-st/2,r+st/2,!0);else if(u==="bevel"){const p=2*f*f,m=-p*Math.cos(n+st/2)+i,g=-p*Math.sin(n+st/2)+o,v=p*Math.cos(r+st/2)+i,x=p*Math.sin(r+st/2)+o;e.lineTo(m,g),e.lineTo(v,x)}}e.closePath(),e.moveTo(0,0),e.rect(0,0,e.canvas.width,e.canvas.height),e.clip("evenodd")}function _de(e,t,n){const{startAngle:r,pixelMargin:i,x:o,y:a,outerRadius:s,innerRadius:l}=t;let c=i/s;e.beginPath(),e.arc(o,a,s,r-c,n+c),l>i?(c=i/l,e.arc(o,a,l,n+c,r-c,!0)):e.arc(o,a,i,n+an,r-an),e.closePath(),e.clip()}function Ede(e){return g1(e,["outerStart","outerEnd","innerStart","innerEnd"])}function Sde(e,t,n,r){const i=Ede(e.options.borderRadius),o=(n-t)/2,a=Math.min(o,r*t/2),s=l=>{const c=(n-Math.min(o,l))*r/2;return $n(l,0,Math.min(o,c))};return{outerStart:s(i.outerStart),outerEnd:s(i.outerEnd),innerStart:$n(i.innerStart,0,a),innerEnd:$n(i.innerEnd,0,a)}}function Bl(e,t,n,r){return{x:n+e*Math.cos(t),y:r+e*Math.sin(t)}}function sm(e,t,n,r,i,o){const{x:a,y:s,startAngle:l,pixelMargin:c,innerRadius:u}=t,d=Math.max(t.outerRadius+r+n-c,0),f=u>0?u+r+n+c:0;let p=0;const m=i-l;if(r){const M=u>0?u-r:0,R=d>0?d-r:0,B=(M+R)/2,V=B!==0?m*B/(B+r):m;p=(m-V)/2}const g=Math.max(.001,m*d-n/st)/d,v=(m-g)/2,x=l+v+p,_=i-v-p,{outerStart:w,outerEnd:y,innerStart:E,innerEnd:S}=Sde(t,f,d,_-x),P=d-w,D=d-y,T=x+w/P,I=_-y/D,A=f+E,C=f+S,j=x+E/A,N=_-S/C;if(e.beginPath(),o){const M=(T+I)/2;if(e.arc(a,s,d,T,M),e.arc(a,s,d,M,I),y>0){const z=Bl(D,I,a,s);e.arc(z.x,z.y,y,I,_+an)}const R=Bl(C,_,a,s);if(e.lineTo(R.x,R.y),S>0){const z=Bl(C,N,a,s);e.arc(z.x,z.y,S,_+an,N+Math.PI)}const B=(_-S/f+(x+E/f))/2;if(e.arc(a,s,f,_-S/f,B,!0),e.arc(a,s,f,B,x+E/f,!0),E>0){const z=Bl(A,j,a,s);e.arc(z.x,z.y,E,j+Math.PI,x-an)}const V=Bl(P,x,a,s);if(e.lineTo(V.x,V.y),w>0){const z=Bl(P,T,a,s);e.arc(z.x,z.y,w,x-an,T)}}else{e.moveTo(a,s);const M=Math.cos(T)*d+a,R=Math.sin(T)*d+s;e.lineTo(M,R);const B=Math.cos(I)*d+a,V=Math.sin(I)*d+s;e.lineTo(B,V)}e.closePath()}function Ode(e,t,n,r,i){const{fullCircles:o,startAngle:a,circumference:s}=t;let l=t.endAngle;if(o){sm(e,t,n,r,l,i);for(let c=0;c<o;++c)e.fill();isNaN(s)||(l=a+(s%Ft||Ft))}return sm(e,t,n,r,l,i),e.fill(),l}function Cde(e,t,n,r,i){const{fullCircles:o,startAngle:a,circumference:s,options:l}=t,{borderWidth:c,borderJoinStyle:u,borderDash:d,borderDashOffset:f,borderRadius:p}=l,m=l.borderAlign==="inner";if(!c)return;e.setLineDash(d||[]),e.lineDashOffset=f,m?(e.lineWidth=c*2,e.lineJoin=u||"round"):(e.lineWidth=c,e.lineJoin=u||"bevel");let g=t.endAngle;if(o){sm(e,t,n,r,g,i);for(let v=0;v<o;++v)e.stroke();isNaN(s)||(g=a+(s%Ft||Ft))}m&&_de(e,t,g),l.selfJoin&&g-a>=st&&p===0&&u!=="miter"&&wde(e,t,g),o||(sm(e,t,n,r,g,i),e.stroke())}class lm extends va{static id="arc";static defaults={borderAlign:"center",borderColor:"#fff",borderDash:[],borderDashOffset:0,borderJoinStyle:void 0,borderRadius:0,borderWidth:2,offset:0,spacing:0,angle:void 0,circular:!0,selfJoin:!1};static defaultRoutes={backgroundColor:"backgroundColor"};static descriptors={_scriptable:!0,_indexable:t=>t!=="borderDash"};circumference;endAngle;fullCircles;innerRadius;outerRadius;pixelMargin;startAngle;constructor(t){super(),this.options=void 0,this.circumference=void 0,this.startAngle=void 0,this.endAngle=void 0,this.innerRadius=void 0,this.outerRadius=void 0,this.pixelMargin=0,this.fullCircles=0,t&&Object.assign(this,t)}inRange(t,n,r){const i=this.getProps(["x","y"],r),{angle:o,distance:a}=$M(i,{x:t,y:n}),{startAngle:s,endAngle:l,innerRadius:c,outerRadius:u,circumference:d}=this.getProps(["startAngle","endAngle","innerRadius","outerRadius","circumference"],r),f=(this.options.spacing+this.options.borderWidth)/2,p=Oe(d,l-s),m=Vu(o,s,l)&&s!==l,g=p>=Ft||m,v=ma(a,c+f,u+f);return g&&v}getCenterPoint(t){const{x:n,y:r,startAngle:i,endAngle:o,innerRadius:a,outerRadius:s}=this.getProps(["x","y","startAngle","endAngle","innerRadius","outerRadius"],t),{offset:l,spacing:c}=this.options,u=(i+o)/2,d=(a+s+c+l)/2;return{x:n+Math.cos(u)*d,y:r+Math.sin(u)*d}}tooltipPosition(t){return this.getCenterPoint(t)}draw(t){const{options:n,circumference:r}=this,i=(n.offset||0)/4,o=(n.spacing||0)/2,a=n.circular;if(this.pixelMargin=n.borderAlign==="inner"?.33:0,this.fullCircles=r>Ft?Math.floor(r/Ft):0,r===0||this.innerRadius<0||this.outerRadius<0)return;t.save();const s=(this.startAngle+this.endAngle)/2;t.translate(Math.cos(s)*i,Math.sin(s)*i);const l=1-Math.sin(Math.min(st,r||0)),c=i*l;t.fillStyle=n.backgroundColor,t.strokeStyle=n.borderColor,Ode(t,this,c,o,a),Cde(t,this,c,o,a),t.restore()}}function n4(e,t,n=t){e.lineCap=Oe(n.borderCapStyle,t.borderCapStyle),e.setLineDash(Oe(n.borderDash,t.borderDash)),e.lineDashOffset=Oe(n.borderDashOffset,t.borderDashOffset),e.lineJoin=Oe(n.borderJoinStyle,t.borderJoinStyle),e.lineWidth=Oe(n.borderWidth,t.borderWidth),e.strokeStyle=Oe(n.borderColor,t.borderColor)}function kde(e,t,n){e.lineTo(n.x,n.y)}function Pde(e){return e.stepped?Yle:e.tension||e.cubicInterpolationMode==="monotone"?Ule:kde}function r4(e,t,n={}){const r=e.length,{start:i=0,end:o=r-1}=n,{start:a,end:s}=t,l=Math.max(i,a),c=Math.min(o,s),u=i<a&&o<a||i>s&&o>s;return{count:r,start:l,loop:t.loop,ilen:c<l&&!u?r+c-l:c-l}}function Dde(e,t,n,r){const{points:i,options:o}=t,{count:a,start:s,loop:l,ilen:c}=r4(i,n,r),u=Pde(o);let{move:d=!0,reverse:f}=r||{},p,m,g;for(p=0;p<=c;++p)m=i[(s+(f?c-p:p))%a],!m.skip&&(d?(e.moveTo(m.x,m.y),d=!1):u(e,g,m,f,o.stepped),g=m);return l&&(m=i[(s+(f?c:0))%a],u(e,g,m,f,o.stepped)),!!l}function Ade(e,t,n,r){const i=t.points,{count:o,start:a,ilen:s}=r4(i,n,r),{move:l=!0,reverse:c}=r||{};let u=0,d=0,f,p,m,g,v,x;const _=y=>(a+(c?s-y:y))%o,w=()=>{g!==v&&(e.lineTo(u,v),e.lineTo(u,g),e.lineTo(u,x))};for(l&&(p=i[_(0)],e.moveTo(p.x,p.y)),f=0;f<=s;++f){if(p=i[_(f)],p.skip)continue;const y=p.x,E=p.y,S=y|0;S===m?(E<g?g=E:E>v&&(v=E),u=(d*u+y)/++d):(w(),e.lineTo(y,E),m=S,d=0,g=v=E),x=E}w()}function N1(e){const t=e.options,n=t.borderDash&&t.borderDash.length;return!e._decimated&&!e._loop&&!t.tension&&t.cubicInterpolationMode!=="monotone"&&!t.stepped&&!n?Ade:Dde}function Tde(e){return e.stepped?Sce:e.tension||e.cubicInterpolationMode==="monotone"?Oce:vs}function Nde(e,t,n,r){let i=t._path;i||(i=t._path=new Path2D,t.path(i,n,r)&&i.closePath()),n4(e,t.options),e.stroke(i)}function jde(e,t,n,r){const{segments:i,options:o}=t,a=N1(t);for(const s of i)n4(e,o,s.style),e.beginPath(),a(e,t,s,{start:n,end:n+r-1})&&e.closePath(),e.stroke()}const Mde=typeof Path2D=="function";function Ide(e,t,n,r){Mde&&!t.options.segment?Nde(e,t,n,r):jde(e,t,n,r)}class j1 extends va{static id="line";static defaults={borderCapStyle:"butt",borderDash:[],borderDashOffset:0,borderJoinStyle:"miter",borderWidth:3,capBezierPoints:!0,cubicInterpolationMode:"default",fill:!1,spanGaps:!1,stepped:!1,tension:0};static defaultRoutes={backgroundColor:"backgroundColor",borderColor:"borderColor"};static descriptors={_scriptable:!0,_indexable:t=>t!=="borderDash"&&t!=="fill"};constructor(t){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,t&&Object.assign(this,t)}updateControlPoints(t,n){const r=this.options;if((r.tension||r.cubicInterpolationMode==="monotone")&&!r.stepped&&!this._pointsUpdated){const i=r.spanGaps?this._loop:this._fullLoop;gce(this._points,r,t,i,n),this._pointsUpdated=!0}}set points(t){this._points=t,delete this._segments,delete this._path,this._pointsUpdated=!1}get points(){return this._points}get segments(){return this._segments||(this._segments=jce(this,this.options.segment))}first(){const t=this.segments,n=this.points;return t.length&&n[t[0].start]}last(){const t=this.segments,n=this.points,r=t.length;return r&&n[t[r-1].end]}interpolate(t,n){const r=this.options,i=t[n],o=this.points,a=Ace(this,{property:n,start:i,end:i});if(!a.length)return;const s=[],l=Tde(r);let c,u;for(c=0,u=a.length;c<u;++c){const{start:d,end:f}=a[c],p=o[d],m=o[f];if(p===m){s.push(p);continue}const g=Math.abs((i-p[n])/(m[n]-p[n])),v=l(p,m,g,r.stepped);v[n]=t[n],s.push(v)}return s.length===1?s[0]:s}pathSegment(t,n,r){return N1(this)(t,this,n,r)}path(t,n,r){const i=this.segments,o=N1(this);let a=this._loop;n=n||0,r=r||this.points.length-n;for(const s of i)a&=o(t,this,s,{start:n,end:n+r-1});return!!a}draw(t,n,r,i){const o=this.options||{};(this.points||[]).length&&o.borderWidth&&(t.save(),Ide(t,this,r,i),t.restore()),this.animated&&(this._pointsUpdated=!1,this._path=void 0)}}function i4(e,t,n,r){const i=e.options,{[n]:o}=e.getProps([n],r);return Math.abs(t-o)<i.radius+i.hitRadius}class M1 extends va{static id="point";parsed;skip;stop;static defaults={borderWidth:1,hitRadius:1,hoverBorderWidth:1,hoverRadius:4,pointStyle:"circle",radius:3,rotation:0};static defaultRoutes={backgroundColor:"backgroundColor",borderColor:"borderColor"};constructor(t){super(),this.options=void 0,this.parsed=void 0,this.skip=void 0,this.stop=void 0,t&&Object.assign(this,t)}inRange(t,n,r){const i=this.options,{x:o,y:a}=this.getProps(["x","y"],r);return Math.pow(t-o,2)+Math.pow(n-a,2)<Math.pow(i.hitRadius+i.radius,2)}inXRange(t,n){return i4(this,t,"x",n)}inYRange(t,n){return i4(this,t,"y",n)}getCenterPoint(t){const{x:n,y:r}=this.getProps(["x","y"],t);return{x:n,y:r}}size(t){t=t||this.options||{};let n=t.radius||0;n=Math.max(n,n&&t.hoverRadius||0);const r=n&&t.borderWidth||0;return(n+r)*2}draw(t,n){const r=this.options;this.skip||r.radius<.1||!Uu(this,n,this.size(r)/2)||(t.strokeStyle=r.borderColor,t.lineWidth=r.borderWidth,t.fillStyle=r.backgroundColor,p1(t,r,this.x,this.y))}getRange(){const t=this.options||{};return t.radius+t.hitRadius}}function o4(e,t){const{x:n,y:r,base:i,width:o,height:a}=e.getProps(["x","y","base","width","height"],t);let s,l,c,u,d;return e.horizontal?(d=a/2,s=Math.min(n,i),l=Math.max(n,i),c=r-d,u=r+d):(d=o/2,s=n-d,l=n+d,c=Math.min(r,i),u=Math.max(r,i)),{left:s,top:c,right:l,bottom:u}}function ya(e,t,n,r){return e?0:$n(t,n,r)}function Fde(e,t,n){const r=e.options.borderWidth,i=e.borderSkipped,o=eI(r);return{t:ya(i.top,o.top,0,n),r:ya(i.right,o.right,0,t),b:ya(i.bottom,o.bottom,0,n),l:ya(i.left,o.left,0,t)}}function Lde(e,t,n){const{enableBorderRadius:r}=e.getProps(["enableBorderRadius"]),i=e.options.borderRadius,o=Il(i),a=Math.min(t,n),s=e.borderSkipped,l=r||Me(i);return{topLeft:ya(!l||s.top||s.left,o.topLeft,0,a),topRight:ya(!l||s.top||s.right,o.topRight,0,a),bottomLeft:ya(!l||s.bottom||s.left,o.bottomLeft,0,a),bottomRight:ya(!l||s.bottom||s.right,o.bottomRight,0,a)}}function Rde(e){const t=o4(e),n=t.right-t.left,r=t.bottom-t.top,i=Fde(e,n/2,r/2),o=Lde(e,n/2,r/2);return{outer:{x:t.left,y:t.top,w:n,h:r,radius:o},inner:{x:t.left+i.l,y:t.top+i.t,w:n-i.l-i.r,h:r-i.t-i.b,radius:{topLeft:Math.max(0,o.topLeft-Math.max(i.t,i.l)),topRight:Math.max(0,o.topRight-Math.max(i.t,i.r)),bottomLeft:Math.max(0,o.bottomLeft-Math.max(i.b,i.l)),bottomRight:Math.max(0,o.bottomRight-Math.max(i.b,i.r))}}}}function I1(e,t,n,r){const i=t===null,o=n===null,s=e&&!(i&&o)&&o4(e,r);return s&&(i||ma(t,s.left,s.right))&&(o||ma(n,s.top,s.bottom))}function $de(e){return e.topLeft||e.topRight||e.bottomLeft||e.bottomRight}function Bde(e,t){e.rect(t.x,t.y,t.w,t.h)}function F1(e,t,n={}){const r=e.x!==n.x?-t:0,i=e.y!==n.y?-t:0,o=(e.x+e.w!==n.x+n.w?t:0)-r,a=(e.y+e.h!==n.y+n.h?t:0)-i;return{x:e.x+r,y:e.y+i,w:e.w+o,h:e.h+a,radius:e.radius}}class Wl extends va{static id="bar";static defaults={borderSkipped:"start",borderWidth:0,borderRadius:0,inflateAmount:"auto",pointStyle:void 0};static defaultRoutes={backgroundColor:"backgroundColor",borderColor:"borderColor"};constructor(t){super(),this.options=void 0,this.horizontal=void 0,this.base=void 0,this.width=void 0,this.height=void 0,this.inflateAmount=void 0,t&&Object.assign(this,t)}draw(t){const{inflateAmount:n,options:{borderColor:r,backgroundColor:i}}=this,{inner:o,outer:a}=Rde(this),s=$de(a.radius)?Yh:Bde;t.save(),(a.w!==o.w||a.h!==o.h)&&(t.beginPath(),s(t,F1(a,n,o)),t.clip(),s(t,F1(o,-n,a)),t.fillStyle=r,t.fill("evenodd")),t.beginPath(),s(t,F1(o,n)),t.fillStyle=i,t.fill(),t.restore()}inRange(t,n,r){return I1(this,t,n,r)}inXRange(t,n){return I1(this,t,null,n)}inYRange(t,n){return I1(this,null,t,n)}getCenterPoint(t){const{x:n,y:r,base:i,horizontal:o}=this.getProps(["x","y","base","horizontal"],t);return{x:o?(n+i)/2:n,y:o?r:(r+i)/2}}getRange(t){return t==="x"?this.width/2:this.height/2}}const a4=(e,t)=>{let{boxHeight:n=t,boxWidth:r=t}=e;return e.usePointStyle&&(n=Math.min(n,t),r=e.pointStyleWidth||Math.min(r,t)),{boxWidth:r,boxHeight:n,itemHeight:Math.max(t,n)}},Wde=(e,t)=>e!==null&&t!==null&&e.datasetIndex===t.datasetIndex&&e.index===t.index;class s4 extends va{constructor(t){super(),this._added=!1,this.legendHitBoxes=[],this._hoveredItem=null,this.doughnutMode=!1,this.chart=t.chart,this.options=t.options,this.ctx=t.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(t,n,r){this.maxWidth=t,this.maxHeight=n,this._margins=r,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 t=this.options.labels||{};let n=bt(t.generateLabels,[this.chart],this)||[];t.filter&&(n=n.filter(r=>t.filter(r,this.chart.data))),t.sort&&(n=n.sort((r,i)=>t.sort(r,i,this.chart.data))),this.options.reverse&&n.reverse(),this.legendItems=n}fit(){const{options:t,ctx:n}=this;if(!t.display){this.width=this.height=0;return}const r=t.labels,i=cr(r.font),o=i.size,a=this._computeTitleHeight(),{boxWidth:s,itemHeight:l}=a4(r,o);let c,u;n.font=i.string,this.isHorizontal()?(c=this.maxWidth,u=this._fitRows(a,o,s,l)+10):(u=this.maxHeight,c=this._fitCols(a,i,s,l)+10),this.width=Math.min(c,t.maxWidth||this.maxWidth),this.height=Math.min(u,t.maxHeight||this.maxHeight)}_fitRows(t,n,r,i){const{ctx:o,maxWidth:a,options:{labels:{padding:s}}}=this,l=this.legendHitBoxes=[],c=this.lineWidths=[0],u=i+s;let d=t;o.textAlign="left",o.textBaseline="middle";let f=-1,p=-u;return this.legendItems.forEach((m,g)=>{const v=r+n/2+o.measureText(m.text).width;(g===0||c[c.length-1]+v+2*s>a)&&(d+=u,c[c.length-(g>0?0:1)]=0,p+=u,f++),l[g]={left:0,top:p,row:f,width:v,height:i},c[c.length-1]+=v+s}),d}_fitCols(t,n,r,i){const{ctx:o,maxHeight:a,options:{labels:{padding:s}}}=this,l=this.legendHitBoxes=[],c=this.columnSizes=[],u=a-t;let d=s,f=0,p=0,m=0,g=0;return this.legendItems.forEach((v,x)=>{const{itemWidth:_,itemHeight:w}=zde(r,n,o,v,i);x>0&&p+w+2*s>u&&(d+=f+s,c.push({width:f,height:p}),m+=f+s,g++,f=p=0),l[x]={left:m,top:p,col:g,width:_,height:w},f=Math.max(f,_),p+=w+s}),d+=f,c.push({width:f,height:p}),d}adjustHitBoxes(){if(!this.options.display)return;const t=this._computeTitleHeight(),{legendHitBoxes:n,options:{align:r,labels:{padding:i},rtl:o}}=this,a=Rl(o,this.left,this.width);if(this.isHorizontal()){let s=0,l=Dr(r,this.left+i,this.right-this.lineWidths[s]);for(const c of n)s!==c.row&&(s=c.row,l=Dr(r,this.left+i,this.right-this.lineWidths[s])),c.top+=this.top+t+i,c.left=a.leftForLtr(a.x(l),c.width),l+=c.width+i}else{let s=0,l=Dr(r,this.top+t+i,this.bottom-this.columnSizes[s].height);for(const c of n)c.col!==s&&(s=c.col,l=Dr(r,this.top+t+i,this.bottom-this.columnSizes[s].height)),c.top=l,c.left+=this.left+i,c.left=a.leftForLtr(a.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 t=this.ctx;h1(t,this),this._draw(),m1(t)}}_draw(){const{options:t,columnSizes:n,lineWidths:r,ctx:i}=this,{align:o,labels:a}=t,s=zt.color,l=Rl(t.rtl,this.left,this.width),c=cr(a.font),{padding:u}=a,d=c.size,f=d/2;let p;this.drawTitle(),i.textAlign=l.textAlign("left"),i.textBaseline="middle",i.lineWidth=.5,i.font=c.string;const{boxWidth:m,boxHeight:g,itemHeight:v}=a4(a,d),x=function(S,P,D){if(isNaN(m)||m<=0||isNaN(g)||g<0)return;i.save();const T=Oe(D.lineWidth,1);if(i.fillStyle=Oe(D.fillStyle,s),i.lineCap=Oe(D.lineCap,"butt"),i.lineDashOffset=Oe(D.lineDashOffset,0),i.lineJoin=Oe(D.lineJoin,"miter"),i.lineWidth=T,i.strokeStyle=Oe(D.strokeStyle,s),i.setLineDash(Oe(D.lineDash,[])),a.usePointStyle){const I={radius:g*Math.SQRT2/2,pointStyle:D.pointStyle,rotation:D.rotation,borderWidth:T},A=l.xPlus(S,m/2),C=P+f;JM(i,I,A,C,a.pointStyleWidth&&m)}else{const I=P+Math.max((d-g)/2,0),A=l.leftForLtr(S,m),C=Il(D.borderRadius);i.beginPath(),Object.values(C).some(j=>j!==0)?Yh(i,{x:A,y:I,w:m,h:g,radius:C}):i.rect(A,I,m,g),i.fill(),T!==0&&i.stroke()}i.restore()},_=function(S,P,D){Hh(i,D.text,S,P+v/2,c,{strikethrough:D.hidden,textAlign:l.textAlign(D.textAlign)})},w=this.isHorizontal(),y=this._computeTitleHeight();w?p={x:Dr(o,this.left+u,this.right-r[0]),y:this.top+u+y,line:0}:p={x:this.left+u,y:Dr(o,this.top+y+u,this.bottom-n[0].height),line:0},uI(this.ctx,t.textDirection);const E=v+u;this.legendItems.forEach((S,P)=>{i.strokeStyle=S.fontColor,i.fillStyle=S.fontColor;const D=i.measureText(S.text).width,T=l.textAlign(S.textAlign||(S.textAlign=a.textAlign)),I=m+f+D;let A=p.x,C=p.y;l.setWidth(this.width),w?P>0&&A+I+u>this.right&&(C=p.y+=E,p.line++,A=p.x=Dr(o,this.left+u,this.right-r[p.line])):P>0&&C+E>this.bottom&&(A=p.x=A+n[p.line].width+u,p.line++,C=p.y=Dr(o,this.top+y+u,this.bottom-n[p.line].height));const j=l.x(A);if(x(j,C,S),A=Nle(T,A+m+f,w?A+I:this.right,t.rtl),_(l.x(A),C,S),w)p.x+=I+u;else if(typeof S.text!="string"){const N=c.lineHeight;p.y+=l4(S,N)+u}else p.y+=E}),dI(this.ctx,t.textDirection)}drawTitle(){const t=this.options,n=t.title,r=cr(n.font),i=li(n.padding);if(!n.display)return;const o=Rl(t.rtl,this.left,this.width),a=this.ctx,s=n.position,l=r.size/2,c=i.top+l;let u,d=this.left,f=this.width;if(this.isHorizontal())f=Math.max(...this.lineWidths),u=this.top+c,d=Dr(t.align,d,this.right-f);else{const m=this.columnSizes.reduce((g,v)=>Math.max(g,v.height),0);u=c+Dr(t.align,this.top,this.bottom-m-t.labels.padding-this._computeTitleHeight())}const p=Dr(s,d,d+f);a.textAlign=o.textAlign(YM(s)),a.textBaseline="middle",a.strokeStyle=n.color,a.fillStyle=n.color,a.font=r.string,Hh(a,n.text,p,u,r)}_computeTitleHeight(){const t=this.options.title,n=cr(t.font),r=li(t.padding);return t.display?n.lineHeight+r.height:0}_getLegendItemAt(t,n){let r,i,o;if(ma(t,this.left,this.right)&&ma(n,this.top,this.bottom)){for(o=this.legendHitBoxes,r=0;r<o.length;++r)if(i=o[r],ma(t,i.left,i.left+i.width)&&ma(n,i.top,i.top+i.height))return this.legendItems[r]}return null}handleEvent(t){const n=this.options;if(!Yde(t.type,n))return;const r=this._getLegendItemAt(t.x,t.y);if(t.type==="mousemove"||t.type==="mouseout"){const i=this._hoveredItem,o=Wde(i,r);i&&!o&&bt(n.onLeave,[t,i,this],this),this._hoveredItem=r,r&&!o&&bt(n.onHover,[t,r,this],this)}else r&&bt(n.onClick,[t,r,this],this)}}function zde(e,t,n,r,i){const o=Vde(r,e,t,n),a=Hde(i,r,t.lineHeight);return{itemWidth:o,itemHeight:a}}function Vde(e,t,n,r){let i=e.text;return i&&typeof i!="string"&&(i=i.reduce((o,a)=>o.length>a.length?o:a)),t+n.size/2+r.measureText(i).width}function Hde(e,t,n){let r=e;return typeof t.text!="string"&&(r=l4(t,n)),r}function l4(e,t){const n=e.text?e.text.length:0;return t*n}function Yde(e,t){return!!((e==="mousemove"||e==="mouseout")&&(t.onHover||t.onLeave)||t.onClick&&(e==="click"||e==="mouseup"))}var Zr={id:"legend",_element:s4,start(e,t,n){const r=e.legend=new s4({ctx:e.ctx,options:n,chart:e});ga.configure(e,r,n),ga.addBox(e,r)},stop(e){ga.removeBox(e,e.legend),delete e.legend},beforeUpdate(e,t,n){const r=e.legend;ga.configure(e,r,n),r.options=n},afterUpdate(e){const t=e.legend;t.buildLabels(),t.adjustHitBoxes()},afterEvent(e,t){t.replay||e.legend.handleEvent(t.event)},defaults:{display:!0,position:"top",align:"center",fullSize:!0,reverse:!1,weight:1e3,onClick(e,t,n){const r=t.datasetIndex,i=n.chart;i.isDatasetVisible(r)?(i.hide(r),t.hidden=!0):(i.show(r),t.hidden=!1)},onHover:null,onLeave:null,labels:{color:e=>e.chart.options.color,boxWidth:40,padding:10,generateLabels(e){const t=e.data.datasets,{labels:{usePointStyle:n,pointStyle:r,textAlign:i,color:o,useBorderRadius:a,borderRadius:s}}=e.legend.options;return e._getSortedDatasetMetas().map(l=>{const c=l.controller.getStyle(n?0:void 0),u=li(c.borderWidth);return{text:t[l.index].label,fillStyle:c.backgroundColor,fontColor:o,hidden:!l.visible,lineCap:c.borderCapStyle,lineDash:c.borderDash,lineDashOffset:c.borderDashOffset,lineJoin:c.borderJoinStyle,lineWidth:(u.width+u.height)/4,strokeStyle:c.borderColor,pointStyle:r||c.pointStyle,rotation:c.rotation,textAlign:i||c.textAlign,borderRadius:a&&(s||c.borderRadius),datasetIndex:l.index}},this)}},title:{color:e=>e.chart.options.color,display:!1,position:"center",text:""}},descriptors:{_scriptable:e=>!e.startsWith("on"),labels:{_scriptable:e=>!["generateLabels","filter","sort"].includes(e)}}};const ed={average(e){if(!e.length)return!1;let t,n,r=new Set,i=0,o=0;for(t=0,n=e.length;t<n;++t){const s=e[t].element;if(s&&s.hasValue()){const l=s.tooltipPosition();r.add(l.x),i+=l.y,++o}}return o===0||r.size===0?!1:{x:[...r].reduce((s,l)=>s+l)/r.size,y:i/o}},nearest(e,t){if(!e.length)return!1;let n=t.x,r=t.y,i=Number.POSITIVE_INFINITY,o,a,s;for(o=0,a=e.length;o<a;++o){const l=e[o].element;if(l&&l.hasValue()){const c=l.getCenterPoint(),u=a1(t,c);u<i&&(i=u,s=l)}}if(s){const l=s.tooltipPosition();n=l.x,r=l.y}return{x:n,y:r}}};function Ui(e,t){return t&&(hn(t)?Array.prototype.push.apply(e,t):e.push(t)),e}function Io(e){return(typeof e=="string"||e instanceof String)&&e.indexOf(`
|
|
298
298
|
`)>-1?e.split(`
|
|
299
|
-
`):e}function Ude(e,t){const{element:n,datasetIndex:r,index:i}=t,o=e.getDatasetMeta(r).controller,{label:a,value:s}=o.getLabelAndValue(i);return{chart:e,label:a,parsed:o.getParsed(i),raw:e.data.datasets[r].data[i],formattedValue:s,dataset:o.getDataset(),dataIndex:i,datasetIndex:r,element:n}}function c4(e,t){const n=e.chart.ctx,{body:r,footer:i,title:o}=e,{boxWidth:a,boxHeight:s}=t,l=cr(t.bodyFont),c=cr(t.titleFont),u=cr(t.footerFont),d=o.length,f=i.length,p=r.length,m=li(t.padding);let g=m.height,v=0,x=r.reduce((y,E)=>y+E.before.length+E.lines.length+E.after.length,0);if(x+=e.beforeBody.length+e.afterBody.length,d&&(g+=d*c.lineHeight+(d-1)*t.titleSpacing+t.titleMarginBottom),x){const y=t.displayColors?Math.max(s,l.lineHeight):l.lineHeight;g+=p*y+(x-p)*l.lineHeight+(x-1)*t.bodySpacing}f&&(g+=t.footerMarginTop+f*u.lineHeight+(f-1)*t.footerSpacing);let _=0;const w=function(y){v=Math.max(v,n.measureText(y).width+_)};return n.save(),n.font=c.string,et(e.title,w),n.font=l.string,et(e.beforeBody.concat(e.afterBody),w),_=t.displayColors?a+2+t.boxPadding:0,et(r,y=>{et(y.before,w),et(y.lines,w),et(y.after,w)}),_=0,n.font=u.string,et(e.footer,w),n.restore(),v+=m.width,{width:v,height:g}}function Kde(e,t){const{y:n,height:r}=t;return n<r/2?"top":n>e.height-r/2?"bottom":"center"}function qde(e,t,n,r){const{x:i,width:o}=r,a=n.caretSize+n.caretPadding;if(e==="left"&&i+o+a>t.width||e==="right"&&i-o-a<0)return!0}function Gde(e,t,n,r){const{x:i,width:o}=n,{width:a,chartArea:{left:s,right:l}}=e;let c="center";return r==="center"?c=i<=(s+l)/2?"left":"right":i<=o/2?c="left":i>=a-o/2&&(c="right"),qde(c,e,t,n)&&(c="center"),c}function u4(e,t,n){const r=n.yAlign||t.yAlign||Kde(e,n);return{xAlign:n.xAlign||t.xAlign||Gde(e,t,n,r),yAlign:r}}function Xde(e,t){let{x:n,width:r}=e;return t==="right"?n-=r:t==="center"&&(n-=r/2),n}function Qde(e,t,n){let{y:r,height:i}=e;return t==="top"?r+=n:t==="bottom"?r-=i+n:r-=i/2,r}function d4(e,t,n,r){const{caretSize:i,caretPadding:o,cornerRadius:a}=e,{xAlign:s,yAlign:l}=n,c=i+o,{topLeft:u,topRight:d,bottomLeft:f,bottomRight:p}=Il(a);let m=Xde(t,s);const g=Qde(t,l,c);return l==="center"?s==="left"?m+=c:s==="right"&&(m-=c):s==="left"?m-=Math.max(u,f)+i:s==="right"&&(m+=Math.max(d,p)+i),{x:$n(m,0,r.width-t.width),y:$n(g,0,r.height-t.height)}}function cm(e,t,n){const r=li(n.padding);return t==="center"?e.x+e.width/2:t==="right"?e.x+e.width-r.right:e.x+r.left}function f4(e){return Ui([],Io(e))}function Zde(e,t,n){return hs(e,{tooltip:t,tooltipItems:n,type:"tooltip"})}function p4(e,t){const n=t&&t.dataset&&t.dataset.tooltip&&t.dataset.tooltip.callbacks;return n?e.override(n):e}const h4={beforeTitle:No,title(e){if(e.length>0){const t=e[0],n=t.chart.data.labels,r=n?n.length:0;if(this&&this.options&&this.options.mode==="dataset")return t.dataset.label||"";if(t.label)return t.label;if(r>0&&t.dataIndex<r)return n[t.dataIndex]}return""},afterTitle:No,beforeBody:No,beforeLabel:No,label(e){if(this&&this.options&&this.options.mode==="dataset")return e.label+": "+e.formattedValue||e.formattedValue;let t=e.dataset.label||"";t&&(t+=": ");const n=e.formattedValue;return Ke(n)||(t+=n),t},labelColor(e){const n=e.chart.getDatasetMeta(e.datasetIndex).controller.getStyle(e.dataIndex);return{borderColor:n.borderColor,backgroundColor:n.backgroundColor,borderWidth:n.borderWidth,borderDash:n.borderDash,borderDashOffset:n.borderDashOffset,borderRadius:0}},labelTextColor(){return this.options.bodyColor},labelPointStyle(e){const n=e.chart.getDatasetMeta(e.datasetIndex).controller.getStyle(e.dataIndex);return{pointStyle:n.pointStyle,rotation:n.rotation}},afterLabel:No,afterBody:No,beforeFooter:No,footer:No,afterFooter:No};function ur(e,t,n,r){const i=e[t].call(n,r);return typeof i>"u"?h4[t].call(n,r):i}class m4 extends va{static positioners=ed;constructor(t){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=t.chart,this.options=t.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(t){this.options=t,this._cachedAnimations=void 0,this.$context=void 0}_resolveAnimations(){const t=this._cachedAnimations;if(t)return t;const n=this.chart,r=this.options.setContext(this.getContext()),i=r.enabled&&n.options.animation&&r.animations,o=new vI(this.chart,i);return i._cacheable&&(this._cachedAnimations=Object.freeze(o)),o}getContext(){return this.$context||(this.$context=Zde(this.chart.getContext(),this,this._tooltipItems))}getTitle(t,n){const{callbacks:r}=n,i=ur(r,"beforeTitle",this,t),o=ur(r,"title",this,t),a=ur(r,"afterTitle",this,t);let s=[];return s=Ui(s,Io(i)),s=Ui(s,Io(o)),s=Ui(s,Io(a)),s}getBeforeBody(t,n){return f4(ur(n.callbacks,"beforeBody",this,t))}getBody(t,n){const{callbacks:r}=n,i=[];return et(t,o=>{const a={before:[],lines:[],after:[]},s=p4(r,o);Ui(a.before,Io(ur(s,"beforeLabel",this,o))),Ui(a.lines,ur(s,"label",this,o)),Ui(a.after,Io(ur(s,"afterLabel",this,o))),i.push(a)}),i}getAfterBody(t,n){return f4(ur(n.callbacks,"afterBody",this,t))}getFooter(t,n){const{callbacks:r}=n,i=ur(r,"beforeFooter",this,t),o=ur(r,"footer",this,t),a=ur(r,"afterFooter",this,t);let s=[];return s=Ui(s,Io(i)),s=Ui(s,Io(o)),s=Ui(s,Io(a)),s}_createItems(t){const n=this._active,r=this.chart.data,i=[],o=[],a=[];let s=[],l,c;for(l=0,c=n.length;l<c;++l)s.push(Ude(this.chart,n[l]));return t.filter&&(s=s.filter((u,d,f)=>t.filter(u,d,f,r))),t.itemSort&&(s=s.sort((u,d)=>t.itemSort(u,d,r))),et(s,u=>{const d=p4(t.callbacks,u);i.push(ur(d,"labelColor",this,u)),o.push(ur(d,"labelPointStyle",this,u)),a.push(ur(d,"labelTextColor",this,u))}),this.labelColors=i,this.labelPointStyles=o,this.labelTextColors=a,this.dataPoints=s,s}update(t,n){const r=this.options.setContext(this.getContext()),i=this._active;let o,a=[];if(!i.length)this.opacity!==0&&(o={opacity:0});else{const s=ed[r.position].call(this,i,this._eventPosition);a=this._createItems(r),this.title=this.getTitle(a,r),this.beforeBody=this.getBeforeBody(a,r),this.body=this.getBody(a,r),this.afterBody=this.getAfterBody(a,r),this.footer=this.getFooter(a,r);const l=this._size=c4(this,r),c=Object.assign({},s,l),u=u4(this.chart,r,c),d=d4(r,c,u,this.chart);this.xAlign=u.xAlign,this.yAlign=u.yAlign,o={opacity:1,x:d.x,y:d.y,width:l.width,height:l.height,caretX:s.x,caretY:s.y}}this._tooltipItems=a,this.$context=void 0,o&&this._resolveAnimations().update(this,o),t&&r.external&&r.external.call(this,{chart:this.chart,tooltip:this,replay:n})}drawCaret(t,n,r,i){const o=this.getCaretPosition(t,r,i);n.lineTo(o.x1,o.y1),n.lineTo(o.x2,o.y2),n.lineTo(o.x3,o.y3)}getCaretPosition(t,n,r){const{xAlign:i,yAlign:o}=this,{caretSize:a,cornerRadius:s}=r,{topLeft:l,topRight:c,bottomLeft:u,bottomRight:d}=Il(s),{x:f,y:p}=t,{width:m,height:g}=n;let v,x,_,w,y,E;return o==="center"?(y=p+g/2,i==="left"?(v=f,x=v-a,w=y+a,E=y-a):(v=f+m,x=v+a,w=y-a,E=y+a),_=v):(i==="left"?x=f+Math.max(l,u)+a:i==="right"?x=f+m-Math.max(c,d)-a:x=this.caretX,o==="top"?(w=p,y=w-a,v=x-a,_=x+a):(w=p+g,y=w+a,v=x+a,_=x-a),E=w),{x1:v,x2:x,x3:_,y1:w,y2:y,y3:E}}drawTitle(t,n,r){const i=this.title,o=i.length;let a,s,l;if(o){const c=Rl(r.rtl,this.x,this.width);for(t.x=cm(this,r.titleAlign,r),n.textAlign=c.textAlign(r.titleAlign),n.textBaseline="middle",a=cr(r.titleFont),s=r.titleSpacing,n.fillStyle=r.titleColor,n.font=a.string,l=0;l<o;++l)n.fillText(i[l],c.x(t.x),t.y+a.lineHeight/2),t.y+=a.lineHeight+s,l+1===o&&(t.y+=r.titleMarginBottom-s)}}_drawColorBox(t,n,r,i,o){const a=this.labelColors[r],s=this.labelPointStyles[r],{boxHeight:l,boxWidth:c}=o,u=cr(o.bodyFont),d=cm(this,"left",o),f=i.x(d),p=l<u.lineHeight?(u.lineHeight-l)/2:0,m=n.y+p;if(o.usePointStyle){const g={radius:Math.min(c,l)/2,pointStyle:s.pointStyle,rotation:s.rotation,borderWidth:1},v=i.leftForLtr(f,c)+c/2,x=m+l/2;t.strokeStyle=o.multiKeyBackground,t.fillStyle=o.multiKeyBackground,p1(t,g,v,x),t.strokeStyle=a.borderColor,t.fillStyle=a.backgroundColor,p1(t,g,v,x)}else{t.lineWidth=Me(a.borderWidth)?Math.max(...Object.values(a.borderWidth)):a.borderWidth||1,t.strokeStyle=a.borderColor,t.setLineDash(a.borderDash||[]),t.lineDashOffset=a.borderDashOffset||0;const g=i.leftForLtr(f,c),v=i.leftForLtr(i.xPlus(f,1),c-2),x=Il(a.borderRadius);Object.values(x).some(_=>_!==0)?(t.beginPath(),t.fillStyle=o.multiKeyBackground,Yh(t,{x:g,y:m,w:c,h:l,radius:x}),t.fill(),t.stroke(),t.fillStyle=a.backgroundColor,t.beginPath(),Yh(t,{x:v,y:m+1,w:c-2,h:l-2,radius:x}),t.fill()):(t.fillStyle=o.multiKeyBackground,t.fillRect(g,m,c,l),t.strokeRect(g,m,c,l),t.fillStyle=a.backgroundColor,t.fillRect(v,m+1,c-2,l-2))}t.fillStyle=this.labelTextColors[r]}drawBody(t,n,r){const{body:i}=this,{bodySpacing:o,bodyAlign:a,displayColors:s,boxHeight:l,boxWidth:c,boxPadding:u}=r,d=cr(r.bodyFont);let f=d.lineHeight,p=0;const m=Rl(r.rtl,this.x,this.width),g=function(D){n.fillText(D,m.x(t.x+p),t.y+f/2),t.y+=f+o},v=m.textAlign(a);let x,_,w,y,E,S,P;for(n.textAlign=a,n.textBaseline="middle",n.font=d.string,t.x=cm(this,v,r),n.fillStyle=r.bodyColor,et(this.beforeBody,g),p=s&&v!=="right"?a==="center"?c/2+u:c+2+u:0,y=0,S=i.length;y<S;++y){for(x=i[y],_=this.labelTextColors[y],n.fillStyle=_,et(x.before,g),w=x.lines,s&&w.length&&(this._drawColorBox(n,t,y,m,r),f=Math.max(d.lineHeight,l)),E=0,P=w.length;E<P;++E)g(w[E]),f=d.lineHeight;et(x.after,g)}p=0,f=d.lineHeight,et(this.afterBody,g),t.y-=o}drawFooter(t,n,r){const i=this.footer,o=i.length;let a,s;if(o){const l=Rl(r.rtl,this.x,this.width);for(t.x=cm(this,r.footerAlign,r),t.y+=r.footerMarginTop,n.textAlign=l.textAlign(r.footerAlign),n.textBaseline="middle",a=cr(r.footerFont),n.fillStyle=r.footerColor,n.font=a.string,s=0;s<o;++s)n.fillText(i[s],l.x(t.x),t.y+a.lineHeight/2),t.y+=a.lineHeight+r.footerSpacing}}drawBackground(t,n,r,i){const{xAlign:o,yAlign:a}=this,{x:s,y:l}=t,{width:c,height:u}=r,{topLeft:d,topRight:f,bottomLeft:p,bottomRight:m}=Il(i.cornerRadius);n.fillStyle=i.backgroundColor,n.strokeStyle=i.borderColor,n.lineWidth=i.borderWidth,n.beginPath(),n.moveTo(s+d,l),a==="top"&&this.drawCaret(t,n,r,i),n.lineTo(s+c-f,l),n.quadraticCurveTo(s+c,l,s+c,l+f),a==="center"&&o==="right"&&this.drawCaret(t,n,r,i),n.lineTo(s+c,l+u-m),n.quadraticCurveTo(s+c,l+u,s+c-m,l+u),a==="bottom"&&this.drawCaret(t,n,r,i),n.lineTo(s+p,l+u),n.quadraticCurveTo(s,l+u,s,l+u-p),a==="center"&&o==="left"&&this.drawCaret(t,n,r,i),n.lineTo(s,l+d),n.quadraticCurveTo(s,l,s+d,l),n.closePath(),n.fill(),i.borderWidth>0&&n.stroke()}_updateAnimationTarget(t){const n=this.chart,r=this.$animations,i=r&&r.x,o=r&&r.y;if(i||o){const a=ed[t.position].call(this,this._active,this._eventPosition);if(!a)return;const s=this._size=c4(this,t),l=Object.assign({},a,this._size),c=u4(n,t,l),u=d4(t,l,c,n);(i._to!==u.x||o._to!==u.y)&&(this.xAlign=c.xAlign,this.yAlign=c.yAlign,this.width=s.width,this.height=s.height,this.caretX=a.x,this.caretY=a.y,this._resolveAnimations().update(this,u))}}_willRender(){return!!this.opacity}draw(t){const n=this.options.setContext(this.getContext());let r=this.opacity;if(!r)return;this._updateAnimationTarget(n);const i={width:this.width,height:this.height},o={x:this.x,y:this.y};r=Math.abs(r)<.001?0:r;const a=li(n.padding),s=this.title.length||this.beforeBody.length||this.body.length||this.afterBody.length||this.footer.length;n.enabled&&s&&(t.save(),t.globalAlpha=r,this.drawBackground(o,t,i,n),uI(t,n.textDirection),o.y+=a.top,this.drawTitle(o,t,n),this.drawBody(o,t,n),this.drawFooter(o,t,n),dI(t,n.textDirection),t.restore())}getActiveElements(){return this._active||[]}setActiveElements(t,n){const r=this._active,i=t.map(({datasetIndex:s,index:l})=>{const c=this.chart.getDatasetMeta(s);if(!c)throw new Error("Cannot find a dataset at index "+s);return{datasetIndex:s,element:c.data[l],index:l}}),o=!Bh(r,i),a=this._positionChanged(i,n);(o||a)&&(this._active=i,this._eventPosition=n,this._ignoreReplayEvents=!0,this.update(!0))}handleEvent(t,n,r=!0){if(n&&this._ignoreReplayEvents)return!1;this._ignoreReplayEvents=!1;const i=this.options,o=this._active||[],a=this._getActiveElements(t,o,n,r),s=this._positionChanged(a,t),l=n||!Bh(a,o)||s;return l&&(this._active=a,(i.enabled||i.external)&&(this._eventPosition={x:t.x,y:t.y},this.update(!0,n))),l}_getActiveElements(t,n,r,i){const o=this.options;if(t.type==="mouseout")return[];if(!i)return n.filter(s=>this.chart.data.datasets[s.datasetIndex]&&this.chart.getDatasetMeta(s.datasetIndex).controller.getParsed(s.index)!==void 0);const a=this.chart.getElementsAtEventForMode(t,o.mode,o,r);return o.reverse&&a.reverse(),a}_positionChanged(t,n){const{caretX:r,caretY:i,options:o}=this,a=ed[o.position].call(this,t,n);return a!==!1&&(r!==a.x||i!==a.y)}}var Ar={id:"tooltip",_element:m4,positioners:ed,afterInit(e,t,n){n&&(e.tooltip=new m4({chart:e,options:n}))},beforeUpdate(e,t,n){e.tooltip&&e.tooltip.initialize(n)},reset(e,t,n){e.tooltip&&e.tooltip.initialize(n)},afterDraw(e){const t=e.tooltip;if(t&&t._willRender()){const n={tooltip:t};if(e.notifyPlugins("beforeTooltipDraw",{...n,cancelable:!0})===!1)return;t.draw(e.ctx),e.notifyPlugins("afterTooltipDraw",n)}},afterEvent(e,t){if(e.tooltip){const n=t.replay;e.tooltip.handleEvent(t.event,n,t.inChartArea)&&(t.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:(e,t)=>t.bodyFont.size,boxWidth:(e,t)=>t.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:h4},defaultRoutes:{bodyFont:"font",footerFont:"font",titleFont:"font"},descriptors:{_scriptable:e=>e!=="filter"&&e!=="itemSort"&&e!=="external",_indexable:!1,callbacks:{_scriptable:!1,_indexable:!1},animation:{_fallback:!1},animations:{_fallback:"animation"}},additionalOptionScopes:["interaction"]};const Jde=(e,t,n,r)=>(typeof t=="string"?(n=e.push(t)-1,r.unshift({index:n,label:t})):isNaN(t)&&(n=null),n);function efe(e,t,n,r){const i=e.indexOf(t);if(i===-1)return Jde(e,t,n,r);const o=e.lastIndexOf(t);return i!==o?n:i}const tfe=(e,t)=>e===null?null:$n(Math.round(e),0,t);function g4(e){const t=this.getLabels();return e>=0&&e<t.length?t[e]:e}class Fo extends $l{static id="category";static defaults={ticks:{callback:g4}};constructor(t){super(t),this._startValue=void 0,this._valueRange=0,this._addedLabels=[]}init(t){const n=this._addedLabels;if(n.length){const r=this.getLabels();for(const{index:i,label:o}of n)r[i]===o&&r.splice(i,1);this._addedLabels=[]}super.init(t)}parse(t,n){if(Ke(t))return null;const r=this.getLabels();return n=isFinite(n)&&r[n]===t?n:efe(r,t,Oe(n,t),this._addedLabels),tfe(n,r.length-1)}determineDataLimits(){const{minDefined:t,maxDefined:n}=this.getUserBounds();let{min:r,max:i}=this.getMinMax(!0);this.options.bounds==="ticks"&&(t||(r=0),n||(i=this.getLabels().length-1)),this.min=r,this.max=i}buildTicks(){const t=this.min,n=this.max,r=this.options.offset,i=[];let o=this.getLabels();o=t===0&&n===o.length-1?o:o.slice(t,n+1),this._valueRange=Math.max(o.length-(r?0:1),1),this._startValue=this.min-(r?.5:0);for(let a=t;a<=n;a++)i.push({value:a});return i}getLabelForValue(t){return g4.call(this,t)}configure(){super.configure(),this.isHorizontal()||(this._reversePixels=!this._reversePixels)}getPixelForValue(t){return typeof t!="number"&&(t=this.parse(t)),t===null?NaN:this.getPixelForDecimal((t-this._startValue)/this._valueRange)}getPixelForTick(t){const n=this.ticks;return t<0||t>n.length-1?null:this.getPixelForValue(n[t].value)}getValueForPixel(t){return Math.round(this._startValue+this.getDecimalForPixel(t)*this._valueRange)}getBasePixel(){return this.bottom}}function nfe(e,t){const n=[],{bounds:i,step:o,min:a,max:s,precision:l,count:c,maxTicks:u,maxDigits:d,includeBounds:f}=e,p=o||1,m=u-1,{min:g,max:v}=t,x=!Ke(a),_=!Ke(s),w=!Ke(c),y=(v-g)/(d+1);let E=LM((v-g)/m/p)*p,S,P,D,T;if(E<1e-14&&!x&&!_)return[{value:g},{value:v}];T=Math.ceil(v/E)-Math.floor(g/E),T>m&&(E=LM(T*E/m/p)*p),Ke(l)||(S=Math.pow(10,l),E=Math.ceil(E*S)/S),i==="ticks"?(P=Math.floor(g/E)*E,D=Math.ceil(v/E)*E):(P=g,D=v),x&&_&&o&&Ele((s-a)/o,E/1e3)?(T=Math.round(Math.min((s-a)/E,u)),E=(s-a)/T,P=a,D=s):w?(P=x?a:P,D=_?s:D,T=c-1,E=(D-P)/T):(T=(D-P)/E,Wu(T,Math.round(T),E/1e3)?T=Math.round(T):T=Math.ceil(T));const I=Math.max(RM(E),RM(P));S=Math.pow(10,Ke(l)?I:l),P=Math.round(P*S)/S,D=Math.round(D*S)/S;let A=0;for(x&&(f&&P!==a?(n.push({value:a}),P<a&&A++,Wu(Math.round((P+A*E)*S)/S,a,v4(a,y,e))&&A++):P<a&&A++);A<T;++A){const C=Math.round((P+A*E)*S)/S;if(_&&C>s)break;n.push({value:C})}return _&&f&&D!==s?n.length&&Wu(n[n.length-1].value,s,v4(s,y,e))?n[n.length-1].value=s:n.push({value:s}):(!_||D===s)&&n.push({value:D}),n}function v4(e,t,{horizontal:n,minRotation:r}){const i=jo(r),o=(n?Math.sin(i):Math.cos(i))||.001,a=.75*t*(""+e).length;return Math.min(t/o,a)}class rfe extends $l{constructor(t){super(t),this.start=void 0,this.end=void 0,this._startValue=void 0,this._endValue=void 0,this._valueRange=0}parse(t,n){return Ke(t)||(typeof t=="number"||t instanceof Number)&&!isFinite(+t)?null:+t}handleTickRangeOptions(){const{beginAtZero:t}=this.options,{minDefined:n,maxDefined:r}=this.getUserBounds();let{min:i,max:o}=this;const a=l=>i=n?i:l,s=l=>o=r?o:l;if(t){const l=Hi(i),c=Hi(o);l<0&&c<0?s(0):l>0&&c>0&&a(0)}if(i===o){let l=o===0?1:Math.abs(o*.05);s(o+l),t||a(i-l)}this.min=i,this.max=o}getTickLimit(){const t=this.options.ticks;let{maxTicksLimit:n,stepSize:r}=t,i;return r?(i=Math.ceil(this.max/r)-Math.floor(this.min/r)+1,i>1e3&&(console.warn(`scales.${this.id}.ticks.stepSize: ${r} would result generating up to ${i} ticks. Limiting to 1000.`),i=1e3)):(i=this.computeTickLimit(),n=n||11),n&&(i=Math.min(n,i)),i}computeTickLimit(){return Number.POSITIVE_INFINITY}buildTicks(){const t=this.options,n=t.ticks;let r=this.getTickLimit();r=Math.max(2,r);const i={maxTicks:r,bounds:t.bounds,min:t.min,max:t.max,precision:n.precision,step:n.stepSize,count:n.count,maxDigits:this._maxDigits(),horizontal:this.isHorizontal(),minRotation:n.minRotation||0,includeBounds:n.includeBounds!==!1},o=this._range||this,a=nfe(i,o);return t.bounds==="ticks"&&Sle(a,this,"value"),t.reverse?(a.reverse(),this.start=this.max,this.end=this.min):(this.start=this.min,this.end=this.max),a}configure(){const t=this.ticks;let n=this.min,r=this.max;if(super.configure(),this.options.offset&&t.length){const i=(r-n)/Math.max(t.length-1,1)/2;n-=i,r+=i}this._startValue=n,this._endValue=r,this._valueRange=r-n}getLabelForValue(t){return u1(t,this.chart.options.locale,this.options.ticks.format)}}class Lo extends rfe{static id="linear";static defaults={ticks:{callback:XM.formatters.numeric}};determineDataLimits(){const{min:t,max:n}=this.getMinMax(!0);this.min=Qr(t)?t:0,this.max=Qr(n)?n:1,this.handleTickRangeOptions()}computeTickLimit(){const t=this.isHorizontal(),n=t?this.width:this.height,r=jo(this.options.ticks.minRotation),i=(t?Math.sin(r):Math.cos(r))||.001,o=this._resolveTickFontOptions(0);return Math.ceil(n/Math.min(40,o.lineHeight/i))}getPixelForValue(t){return t===null?NaN:this.getPixelForDecimal((t-this._startValue)/this._valueRange)}getValueForPixel(t){return this._startValue+this.getDecimalForPixel(t)*this._valueRange}}const um={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}},dr=Object.keys(um);function y4(e,t){return e-t}function b4(e,t){if(Ke(t))return null;const n=e._adapter,{parser:r,round:i,isoWeekday:o}=e._parseOpts;let a=t;return typeof r=="function"&&(a=r(a)),Qr(a)||(a=typeof r=="string"?n.parse(a,r):n.parse(a)),a===null?null:(i&&(a=i==="week"&&(zu(o)||o===!0)?n.startOf(a,"isoWeek",o):n.startOf(a,i)),+a)}function x4(e,t,n,r){const i=dr.length;for(let o=dr.indexOf(e);o<i-1;++o){const a=um[dr[o]],s=a.steps?a.steps:Number.MAX_SAFE_INTEGER;if(a.common&&Math.ceil((n-t)/(s*a.size))<=r)return dr[o]}return dr[i-1]}function ife(e,t,n,r,i){for(let o=dr.length-1;o>=dr.indexOf(n);o--){const a=dr[o];if(um[a].common&&e._adapter.diff(i,r,a)>=t-1)return a}return dr[n?dr.indexOf(n):0]}function ofe(e){for(let t=dr.indexOf(e)+1,n=dr.length;t<n;++t)if(um[dr[t]].common)return dr[t]}function w4(e,t,n){if(!n)e[t]=!0;else if(n.length){const{lo:r,hi:i}=s1(n,t),o=n[r]>=t?n[r]:n[i];e[o]=!0}}function afe(e,t,n,r){const i=e._adapter,o=+i.startOf(t[0].value,r),a=t[t.length-1].value;let s,l;for(s=o;s<=a;s=+i.add(s,1,r))l=n[s],l>=0&&(t[l].major=!0);return t}function _4(e,t,n){const r=[],i={},o=t.length;let a,s;for(a=0;a<o;++a)s=t[a],i[s]=a,r.push({value:s,major:!1});return o===0||!n?r:afe(e,r,i,n)}class E4 extends $l{static id="time";static defaults={bounds:"data",adapters:{},time:{parser:!1,unit:!1,round:!1,isoWeekday:!1,minUnit:"millisecond",displayFormats:{}},ticks:{source:"auto",callback:!1,major:{enabled:!1}}};constructor(t){super(t),this._cache={data:[],labels:[],all:[]},this._unit="day",this._majorUnit=void 0,this._offsets={},this._normalized=!1,this._parseOpts=void 0}init(t,n={}){const r=t.time||(t.time={}),i=this._adapter=new fue._date(t.adapters.date);i.init(n),$u(r.displayFormats,i.formats()),this._parseOpts={parser:r.parser,round:r.round,isoWeekday:r.isoWeekday},super.init(t),this._normalized=n.normalized}parse(t,n){return t===void 0?null:b4(this,t)}beforeLayout(){super.beforeLayout(),this._cache={data:[],labels:[],all:[]}}determineDataLimits(){const t=this.options,n=this._adapter,r=t.time.unit||"day";let{min:i,max:o,minDefined:a,maxDefined:s}=this.getUserBounds();function l(c){!a&&!isNaN(c.min)&&(i=Math.min(i,c.min)),!s&&!isNaN(c.max)&&(o=Math.max(o,c.max))}(!a||!s)&&(l(this._getLabelBounds()),(t.bounds!=="ticks"||t.ticks.source!=="labels")&&l(this.getMinMax(!1))),i=Qr(i)&&!isNaN(i)?i:+n.startOf(Date.now(),r),o=Qr(o)&&!isNaN(o)?o:+n.endOf(Date.now(),r)+1,this.min=Math.min(i,o-1),this.max=Math.max(i+1,o)}_getLabelBounds(){const t=this.getLabelTimestamps();let n=Number.POSITIVE_INFINITY,r=Number.NEGATIVE_INFINITY;return t.length&&(n=t[0],r=t[t.length-1]),{min:n,max:r}}buildTicks(){const t=this.options,n=t.time,r=t.ticks,i=r.source==="labels"?this.getLabelTimestamps():this._generate();t.bounds==="ticks"&&i.length&&(this.min=this._userMin||i[0],this.max=this._userMax||i[i.length-1]);const o=this.min,a=this.max,s=Dle(i,o,a);return this._unit=n.unit||(r.autoSkip?x4(n.minUnit,this.min,this.max,this._getLabelCapacity(o)):ife(this,s.length,n.minUnit,this.min,this.max)),this._majorUnit=!r.major.enabled||this._unit==="year"?void 0:ofe(this._unit),this.initOffsets(i),t.reverse&&s.reverse(),_4(this,s,this._majorUnit)}afterAutoSkip(){this.options.offsetAfterAutoskip&&this.initOffsets(this.ticks.map(t=>+t.value))}initOffsets(t=[]){let n=0,r=0,i,o;this.options.offset&&t.length&&(i=this.getDecimalForValue(t[0]),t.length===1?n=1-i:n=(this.getDecimalForValue(t[1])-i)/2,o=this.getDecimalForValue(t[t.length-1]),t.length===1?r=o:r=(o-this.getDecimalForValue(t[t.length-2]))/2);const a=t.length<3?.5:.25;n=$n(n,0,a),r=$n(r,0,a),this._offsets={start:n,end:r,factor:1/(n+1+r)}}_generate(){const t=this._adapter,n=this.min,r=this.max,i=this.options,o=i.time,a=o.unit||x4(o.minUnit,n,r,this._getLabelCapacity(n)),s=Oe(i.ticks.stepSize,1),l=a==="week"?o.isoWeekday:!1,c=zu(l)||l===!0,u={};let d=n,f,p;if(c&&(d=+t.startOf(d,"isoWeek",l)),d=+t.startOf(d,c?"day":a),t.diff(r,n,a)>1e5*s)throw new Error(n+" and "+r+" are too far apart with stepSize of "+s+" "+a);const m=i.ticks.source==="data"&&this.getDataTimestamps();for(f=d,p=0;f<r;f=+t.add(f,s,a),p++)w4(u,f,m);return(f===r||i.bounds==="ticks"||p===1)&&w4(u,f,m),Object.keys(u).sort(y4).map(g=>+g)}getLabelForValue(t){const n=this._adapter,r=this.options.time;return r.tooltipFormat?n.format(t,r.tooltipFormat):n.format(t,r.displayFormats.datetime)}format(t,n){const i=this.options.time.displayFormats,o=this._unit,a=n||i[o];return this._adapter.format(t,a)}_tickFormatFunction(t,n,r,i){const o=this.options,a=o.ticks.callback;if(a)return bt(a,[t,n,r],this);const s=o.time.displayFormats,l=this._unit,c=this._majorUnit,u=l&&s[l],d=c&&s[c],f=r[n],p=c&&d&&f&&f.major;return this._adapter.format(t,i||(p?d:u))}generateTickLabels(t){let n,r,i;for(n=0,r=t.length;n<r;++n)i=t[n],i.label=this._tickFormatFunction(i.value,n,t)}getDecimalForValue(t){return t===null?NaN:(t-this.min)/(this.max-this.min)}getPixelForValue(t){const n=this._offsets,r=this.getDecimalForValue(t);return this.getPixelForDecimal((n.start+r)*n.factor)}getValueForPixel(t){const n=this._offsets,r=this.getDecimalForPixel(t)/n.factor-n.end;return this.min+r*(this.max-this.min)}_getLabelSize(t){const n=this.options.ticks,r=this.ctx.measureText(t).width,i=jo(this.isHorizontal()?n.maxRotation:n.minRotation),o=Math.cos(i),a=Math.sin(i),s=this._resolveTickFontOptions(0).size;return{w:r*o+s*a,h:r*a+s*o}}_getLabelCapacity(t){const n=this.options.time,r=n.displayFormats,i=r[n.unit]||r.millisecond,o=this._tickFormatFunction(t,0,_4(this,[t],this._majorUnit),i),a=this._getLabelSize(o),s=Math.floor(this.isHorizontal()?this.width/a.w:this.height/a.h)-1;return s>0?s:1}getDataTimestamps(){let t=this._cache.data||[],n,r;if(t.length)return t;const i=this.getMatchingVisibleMetas();if(this._normalized&&i.length)return this._cache.data=i[0].controller.getAllParsedValues(this);for(n=0,r=i.length;n<r;++n)t=t.concat(i[n].controller.getAllParsedValues(this));return this._cache.data=this.normalize(t)}getLabelTimestamps(){const t=this._cache.labels||[];let n,r;if(t.length)return t;const i=this.getLabels();for(n=0,r=i.length;n<r;++n)t.push(b4(this,i[n]));return this._cache.labels=this._normalized?t:this.normalize(t)}normalize(t){return zM(t.sort(y4))}}function dm(e,t,n){let r=0,i=e.length-1,o,a,s,l;n?(t>=e[r].pos&&t<=e[i].pos&&({lo:r,hi:i}=ds(e,"pos",t)),{pos:o,time:s}=e[r],{pos:a,time:l}=e[i]):(t>=e[r].time&&t<=e[i].time&&({lo:r,hi:i}=ds(e,"time",t)),{time:o,pos:s}=e[r],{time:a,pos:l}=e[i]);const c=a-o;return c?s+(l-s)*(t-o)/c:s}class hme extends E4{static id="timeseries";static defaults=E4.defaults;constructor(t){super(t),this._table=[],this._minPos=void 0,this._tableRange=void 0}initOffsets(){const t=this._getTimestampsForTable(),n=this._table=this.buildLookupTable(t);this._minPos=dm(n,this.min),this._tableRange=dm(n,this.max)-this._minPos,super.initOffsets(t)}buildLookupTable(t){const{min:n,max:r}=this,i=[],o=[];let a,s,l,c,u;for(a=0,s=t.length;a<s;++a)c=t[a],c>=n&&c<=r&&i.push(c);if(i.length<2)return[{time:n,pos:0},{time:r,pos:1}];for(a=0,s=i.length;a<s;++a)u=i[a+1],l=i[a-1],c=i[a],Math.round((u+l)/2)!==c&&o.push({time:c,pos:a/(s-1)});return o}_generate(){const t=this.min,n=this.max;let r=super.getDataTimestamps();return(!r.includes(t)||!r.length)&&r.splice(0,0,t),(!r.includes(n)||r.length===1)&&r.push(n),r.sort((i,o)=>i-o)}_getTimestampsForTable(){let t=this._cache.all||[];if(t.length)return t;const n=this.getDataTimestamps(),r=this.getLabelTimestamps();return n.length&&r.length?t=this.normalize(n.concat(r)):t=n.length?n:r,t=this._cache.all=t,t}getDecimalForValue(t){return(dm(this._table,t)-this._minPos)/this._tableRange}getValueForPixel(t){const n=this._offsets,r=this.getDecimalForPixel(t)/n.factor-n.end;return dm(this._table,r*this._tableRange+this._minPos,!0)}}const S4="label";function O4(e,t){typeof e=="function"?e(t):e&&(e.current=t)}function sfe(e,t){const n=e.options;n&&t&&Object.assign(n,t)}function C4(e,t){e.labels=t}function k4(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:S4;const r=[];e.datasets=t.map(i=>{const o=e.datasets.find(a=>a[n]===i[n]);return!o||!i.data||r.includes(o)?{...i}:(r.push(o),Object.assign(o,i),o)})}function lfe(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:S4;const n={labels:[],datasets:[]};return C4(n,e.labels),k4(n,e.datasets,t),n}function cfe(e,t){const{height:n=150,width:r=300,redraw:i=!1,datasetIdKey:o,type:a,data:s,options:l,plugins:c=[],fallbackContent:u,updateMode:d,...f}=e,p=k.useRef(null),m=k.useRef(null),g=()=>{p.current&&(m.current=new Bn(p.current,{type:a,data:lfe(s,o),options:l&&{...l},plugins:c}),O4(t,m.current))},v=()=>{O4(t,null),m.current&&(m.current.destroy(),m.current=null)};return k.useEffect(()=>{!i&&m.current&&l&&sfe(m.current,l)},[i,l]),k.useEffect(()=>{!i&&m.current&&C4(m.current.config.data,s.labels)},[i,s.labels]),k.useEffect(()=>{!i&&m.current&&s.datasets&&k4(m.current.config.data,s.datasets,o)},[i,s.datasets]),k.useEffect(()=>{m.current&&(i?(v(),setTimeout(g)):m.current.update(d))},[i,l,s.labels,s.datasets,d]),k.useEffect(()=>{m.current&&(v(),setTimeout(g))},[a]),k.useEffect(()=>(g(),()=>v()),[]),k.createElement("canvas",{ref:p,role:"img",height:n,width:r,...f},u)}const ufe=k.forwardRef(cfe);function L1(e,t){return Bn.register(t),k.forwardRef((n,r)=>k.createElement(ufe,{...n,ref:r,type:e}))}const R1=L1("line",due),zl=L1("bar",lue),fm=L1("doughnut",uue);function Vt({image:e="https://cdni.iconscout.com/illustration/premium/thumb/businessman-sad-for-no-data-in-folder-illustration-svg-download-png-10155562.png",title:t="No Data Available",description:n="Catch up all the data. Change the date range to see the data."}){return h.jsxs("div",{className:"flex flex-col items-center justify-center h-full text-center px-[16px]",children:[h.jsx("img",{src:e,alt:"no data",className:"w-32 h-32 mb-4 opacity-80"}),h.jsx("div",{className:"text-[16px] font-semibold text-gray-900 mb-[4px]",children:t}),h.jsx("div",{className:"text-[12px] text-gray-500 max-w-[260px]",children:n})]})}Bn.register(lm,Ar,Zr);const dfe={id:"bottomGlow",afterDatasetsDraw(e,t,n){if(!n?.enabled)return;const r=e.getDatasetMeta(0);if(!r?.data?.[0])return;const{ctx:i}=e,{x:o,y:a,innerRadius:s}=r.data[0],l=Math.max(s-2,0),c=a+l*.9,u=i.createRadialGradient(o,c,0,o,c,l*1.08);u.addColorStop(0,n.color??"rgba(186, 230, 253, 0.72)"),u.addColorStop(.3,"rgba(186, 230, 253, 0.4)"),u.addColorStop(.58,"rgba(186, 230, 253, 0.16)"),u.addColorStop(1,"rgba(186, 230, 253, 0)"),i.save(),i.beginPath(),i.arc(o,a,l,0,Math.PI*2),i.clip(),i.fillStyle=u,i.beginPath(),i.ellipse(o,c,l*1.08,l*.52,0,0,Math.PI*2),i.fill(),i.restore()}},ffe=({title:e="Tickets",icon:t,firstLabel:n="First",firstValue:r=0,firstColor:i="#12B981",secondLabel:o="Second",secondValue:a=0,secondColor:s="#AB0000",growthPercentage:l="+0%",growthText:c="Compared to last month",totalLabel:u="Total",centerTopColor:d="#0F172A",centerBottomColor:f="#64748B",centerTopSize:p,centerBottomSize:m,showBottomGlow:g=!1,bottomGlowColor:v="rgba(186, 230, 253, 0.75)",showEmptyStateWhenZero:x=!1,widgetType:_="",resolvedWidgetType:w="",data:y})=>{const E=y?.title??e,S=y?.icon??t,P=y?.firstLabel??n,D=Number(y?.firstValue??r??0),T=y?.firstColor??i,I=y?.secondLabel??o,A=Number(y?.secondValue??a??0),C=y?.secondColor??s,j=y?.growthPercentage??l??"+0%",N=y?.growthText??c,M=y?.totalLabel??u,R=y?.widgetType??_??w,B=y?.centerTopSize??p??(R==="commercial"?34:24),V=y?.centerBottomSize??m??(R==="commercial"?14:9),z=y?.showBottomGlow??g,W=y?.bottomGlowColor??v,Q=y?.showEmptyStateWhenZero??x??y?.total_units!==void 0,X=Number(y?.total_units?.current??ie),ie=D+A,J=Q&&ie===0&&X===0,re={labels:[P,I],datasets:[{data:[D,A],backgroundColor:[T,C],borderWidth:2,hoverOffset:4}]},se={responsive:!0,maintainAspectRatio:!1,cutout:"68%",plugins:{legend:{display:!1},tooltip:{enabled:!1,external:ri()},bottomGlow:{enabled:z,color:W}}},ce=[{label:P,value:D,color:T},{label:I,value:A,color:C}],de=j.toString().includes("+"),K=j.toString().includes("-"),U=de?"#1FA05B":"#AB0000";return h.jsx(Le,{title:E,icon:S,className:`${R==="commercial"?"h-[362px]":"h-[238px]"} !gap-[24px]`,childrenClassName:J?"h-full":"!flex-none",children:J?h.jsx("div",{className:"w-full h-full flex items-center justify-center",children:h.jsx(Vt,{})}):h.jsxs("div",{className:"grid grid-cols-12 gap-[16px] items-center",children:[h.jsxs("div",{className:"col-span-5 flex flex-1 flex-col h-full gap-[12px]",children:[ce.map((Z,F)=>h.jsxs("div",{children:[h.jsx("div",{className:"mb-[8px] text-[12px] text-[#64748B]",children:Z.label}),h.jsx("div",{className:"text-[28px] leading-[32px] font-medium",style:{color:Z.color},children:Z.value})]},F)),h.jsxs("div",{className:`py-[4px] text-[10px] leading-[14px] flex gap-[4px] ${R==="commercial"?"mt-[20px]":""} items-center`,style:{color:U},children:[de&&h.jsx(Xo,{}),K&&h.jsx(Go,{}),h.jsx("div",{children:j.replace("+","").replace("-","")}),h.jsx("div",{className:"text-[#64748B] text-[10px] leading-[14px] ml-[4px] whitespace-nowrap",children:N})]})]}),h.jsx("div",{className:"col-span-7",children:h.jsxs("div",{className:`${R==="commercial"?"h-[260px] max-w-[263px]":"h-[162px] w-[162px]"} relative ml-auto mr-2`,children:[h.jsx(fm,{data:re,options:se,plugins:[dfe]}),h.jsxs("div",{className:"pointer-events-none absolute inset-0 flex flex-col items-center justify-center text-center",children:[h.jsx("div",{style:{color:d,fontSize:B,fontWeight:500,lineHeight:"28px"},children:ie}),h.jsx("div",{style:{color:f,fontSize:V,fontWeight:400,lineHeight:"11px",marginTop:R==="commercial"?10:5},children:M})]})]})})]})})},P4=({value:e=0,total:t=1,colorClass:n="",label:r=""})=>{const i=Math.max(0,Math.min(100,e/(t||1)*100)),o=n==="bg-[#8B5CF6]"?"text-[#8B5CF6]":n==="bg-[#12B981]"?"text-[#12B981]":"text-slate-600";return h.jsxs("div",{className:"flex flex-col gap-[4.5px] items-start",children:[h.jsx("div",{className:"w-2/3 min-w-[80px] h-[11px] rounded-full overflow-hidden",children:h.jsx("div",{className:`h-3 rounded-full ${n}`,style:{width:`${i}%`}})}),h.jsx("div",{className:`${o} !text-[12px] !leading-[16px] font-bold`,children:e}),h.jsx("div",{className:"!text-[12px] !leading-[16px] text-[#64748B]",children:r})]})},D4=({title:e,value:t,suffix:n,valueClass:r=""})=>h.jsxs("div",{className:"bg-white rounded-[12px] shadow-[0_0_12px_0_#EAF2FF] h-[98px] p-[16px] flex flex-col gap-[4px] justify-center",children:[h.jsx("div",{className:"!text-[12px] leading-[16px] text-[#121212] mb-[4px]",children:e}),h.jsxs("div",{className:`text-[28px] leading-[32px] flex item gap-[4px] font-medium ${r}`,children:[t," ",n&&h.jsx("div",{className:"text-[28px] leading-[32px] font-medium",children:n})]})]}),pfe=({data:e,totalUnits:t=847,occupiedUnits:n=756,ownerCount:r=700,tenantCount:i=56,avgResidents:o=4.4,avgLeaseMonths:a=18})=>{const s=Number(e?.totalUnits??t??0),l=Number(e?.occupiedUnits??n??0),c=Number(e?.ownerCount??r??0),u=Number(e?.tenantCount??i??0),d=e?.avgResidents??o,f=e?.avgLeaseMonths??a,p=c+u;return h.jsxs("div",{children:[h.jsxs("div",{className:"bg-white rounded-[12px] shadow-[0_0_12px_0_#EAF2FF] h-[128px] p-[16px] !mb-4",children:[h.jsxs("div",{className:"flex items-center gap-[8px] mb-[24px]",children:[h.jsx(Ng,{className:"h-[20px] w-[20px] text-[#329DFF]"}),h.jsx("div",{className:"font-medium text-[16px] leading-[20px] text-[#121212]",children:"Occupancy Overview"})]}),h.jsxs("div",{className:"flex items-center justify-between",children:[h.jsxs("div",{className:"flex flex-col gap-[4px]",children:[h.jsx("div",{className:"leading-[16px] text-[12px] text-[#64748B]",children:"Occupied Units"}),h.jsxs("div",{className:"flex items-baseline",children:[h.jsx("div",{className:"text-[28px] leading-[32px] font-medium text-[#121212]",children:l}),h.jsxs("div",{className:"text-[#64748B] text-[20px] leading-[32px]",children:["/",s]})]})]}),h.jsxs("div",{className:"flex items-end",children:[h.jsx(P4,{value:c,total:p,colorClass:"bg-[#8B5CF6]",label:"Owner"}),h.jsx(P4,{value:u,total:p,colorClass:"bg-[#12B981]",label:"Tenant"})]})]})]}),h.jsxs("div",{className:"mt-2.5 grid grid-cols-2 gap-[12px]",children:[h.jsx(D4,{title:"Avg Residents Per Unit",value:d,valueClass:"text-[#8B5CF6]"}),h.jsx(D4,{title:"Avg Lease Period",value:f,suffix:"months",valueClass:"text-[#E7A015]"})]})]})};Bn.register(lm,Ar,Zr);const hfe=({data:e,ownerCount:t=1e3,tenantCount:n=200,nonResidingOwners:r=26,growthPct:i="+9.1%"})=>{const o=Number(e?.ownerCount??t??0),a=Number(e?.tenantCount??n??0),s=Number(e?.nonResidingOwners??r??0),l=e?.growthPct??i,c=Math.max(o-s,0),u=o+a,d={labels:["Owners","Tenants","Non-residing Owner"],datasets:[{data:[c,a,s],backgroundColor:["#3C81F6","#08B6D4","#8B5CF6"],borderWidth:2,hoverOffset:4}]},f={responsive:!0,maintainAspectRatio:!1,cutout:"68%",plugins:{legend:{display:!1},tooltip:{enabled:!1,external:ri()}}};return h.jsx(Le,{title:"Resident Overview",icon:h.jsx(cS,{className:"h-[20px] w-[20px] text-[#8B5CF6]"}),className:"h-[238px] !gap-[24px]",children:h.jsxs("div",{className:" flex-1 min-h-0 grid grid-cols-12 gap-[16px] items-center",children:[h.jsxs("div",{className:"col-span-5 flex flex-1 flex-col h-full gap-[12px]",children:[h.jsxs("div",{children:[h.jsx("div",{className:"!text-[12px] text-[#64748B] leading-[16px] mb-[8px]",children:"Total Owners"}),h.jsx("div",{className:"text-[28px] leading-[32px] font-medium text-[#3C81F6]",children:o})]}),h.jsxs("div",{children:[h.jsx("div",{className:"!text-[12px] text-[#64748B] leading-[16px] mb-[8px]",children:"Total Tenants"}),h.jsx("div",{className:"text-[28px] leading-[32px] font-medium text-[#08B6D4]",children:a})]}),h.jsxs("div",{className:"py-[4px] text-[10px] leading-[14px] flex gap-[4px] text-[#1FA05B] items-center",children:[h.jsx("div",{children:l}),h.jsx("div",{className:"text-[#64748B] text-[10px] leading-[14px] ml-[4px] whitespace-nowrap",children:"Compared to last month"})]})]}),h.jsx("div",{className:"col-span-7",children:h.jsxs("div",{className:"relative h-[162px] w-[162px] ml-auto mr-2",children:[h.jsx(fm,{data:d,options:f}),h.jsxs("div",{className:"pointer-events-none absolute inset-0 flex flex-col gap-[5.5px] items-center justify-center text-center",children:[h.jsx("div",{style:{color:"#121212",fontSize:24,fontWeight:600,lineHeight:"28px"},children:u}),h.jsx("div",{style:{color:"#64748B",fontSize:9,fontWeight:400,lineHeight:"11.5px"},children:"Total Members"})]})]})})]})})};Bn.register(Fo,Lo,Wl,Ar,Zr);const mfe=[{label:"Owner",color:"#3C81F6"},{label:"Rented",color:"#8B5CF6"},{label:"Vacant",color:"#08B6D4"}],gfe=({data:e,blocks:t=[{name:"Block A",owner:110,rented:24,vacant:8},{name:"Block B",owner:95,rented:18,vacant:6},{name:"Block C",owner:65,rented:12,vacant:18},{name:"Block D",owner:78,rented:16,vacant:30}]})=>{const n=Array.isArray(e?.blocks)&&e.blocks.length>0?e.blocks:Array.isArray(e)&&e.length>0?e:t,r=n.map(c=>c.name),i=n.map(c=>Number(c.owner??0)),o=n.map(c=>Number(c.rented??0)),a=n.map(c=>Number(c.vacant??0)),s={labels:r,datasets:[{label:"Owner",data:i,backgroundColor:"#3C81F6",barThickness:40},{label:"",data:i.map(()=>2),backgroundColor:"transparent",barThickness:40},{label:"Rented",data:o,backgroundColor:"#8B5CF6",barThickness:40},{label:"",data:o.map(()=>2),backgroundColor:"transparent",barThickness:40},{label:"Vacant",data:a,backgroundColor:"#08B6D4",barThickness:40}]},l={responsive:!0,maintainAspectRatio:!1,plugins:{legend:{display:!1},tooltip:{enabled:!1,external:ri({hideTitleForSingle:!1})}},scales:{x:{stacked:!0,grid:{display:!1},ticks:{color:"#64748B"}},y:{stacked:!0,beginAtZero:!0,suggestedMax:180,grid:{color:"#F1F5F9"},ticks:{color:"#64748B",stepSize:20}}}};return h.jsx(Le,{title:"Block-wise Occupancy",className:"w-full h-[360px]",titleClassName:"!text-[20px] !leading-[24px] !font-semibold",children:h.jsxs("div",{className:"h-full flex flex-col",children:[h.jsx("div",{className:"flex-1 min-h-0",children:h.jsx(zl,{data:s,options:l})}),h.jsx("div",{className:"flex items-center justify-around pt-[12px]",children:mfe.map(c=>h.jsxs("div",{className:"flex items-center gap-[6px]",children:[h.jsx("div",{className:"w-[10px] h-[10px] rotate-45",style:{backgroundColor:c.color}}),h.jsx("span",{className:"text-[14px] leading-[18px] text-[#64748B]",children:c.label})]},c.label))})]})})};Bn.register(Fo,Lo,M1,j1,Ar,Zr);const vfe=[{label:"Move-in",color:"#12B981"},{label:"Move-out",color:"#8B5CF6"}],yfe=e=>{const[t,n]=String(e).split(" ");return`${{Jan:"January",Feb:"February",Mar:"March",Apr:"April",May:"May",Jun:"June",Jul:"July",Aug:"August",Sep:"September",Oct:"October",Nov:"November",Dec:"December"}[t]||t} 20${n}`},bfe=({data:e,labels:t=["Jan 25","Feb 25","Mar 25","Apr 25","May 25"],moveIn:n=[24,27,20,26,23],moveOut:r=[12,17,8,5,16]})=>{const i=Array.isArray(e?.labels)&&e.labels.length>0?e.labels:t,o=Array.isArray(e?.moveIn)&&e.moveIn.length>0?e.moveIn:n,a=Array.isArray(e?.moveOut)&&e.moveOut.length>0?e.moveOut:r,s={labels:i,datasets:[{label:"Move-in",data:o,borderColor:"#12B981",backgroundColor:"rgba(16,185,129,0.15)",pointBackgroundColor:"#12B981",pointStyle:"rectRot",fill:!1},{label:"Move-out",data:a,borderColor:"#8B5CF6",backgroundColor:"rgba(124,58,237,0.15)",pointBackgroundColor:"#8B5CF6",pointStyle:"rectRot",fill:!1}]},l={responsive:!0,maintainAspectRatio:!1,interaction:{mode:"index",intersect:!1},plugins:{legend:{display:!1},tooltip:{enabled:!1,external:ri({titleFormatter:c=>c.title?.[0]?yfe(c.title[0]):"",hideTitleForSingle:!1})}},scales:{x:{grid:{color:"#F1F5F9"},ticks:{color:"#64748B"}},y:{beginAtZero:!0,suggestedMax:28,grid:{color:"#F1F5F9"},ticks:{color:"#64748B",stepSize:4,precision:0}}},elements:{line:{borderWidth:2,tension:0},point:{radius:0,hoverRadius:3,hitRadius:10}}};return h.jsx(Le,{title:"Move-in/Out Trends",className:"w-full h-[360px]",titleClassName:"!text-[20px] !leading-[24px] !font-semibold",children:h.jsxs("div",{className:"h-full flex flex-col",children:[h.jsx("div",{className:"flex-1 min-h-0",children:h.jsx(R1,{data:s,options:l})}),h.jsx("div",{className:"flex items-center justify-around pt-[12px]",children:vfe.map(c=>h.jsxs("div",{className:"flex items-center gap-[6px]",children:[h.jsx("div",{className:"w-[10px] h-[10px] rotate-45",style:{backgroundColor:c.color}}),h.jsx("span",{className:"text-[14px] leading-[18px] text-[#64748B]",children:c.label})]},c.label))})]})})};Bn.register(Fo,Lo,M1,j1,Ar,Zr);const xfe=[{label:"Income",className:"bg-gradient-to-r from-[#8CEAE5] to-[#40A39E]"},{label:"Expenditure",className:"bg-gradient-to-r from-[#D86E6E] to-[#AB0000]"}],wfe=e=>{const[t,n]=String(e).split(" ");return`${{Jan:"January",Feb:"February",Mar:"March",Apr:"April",May:"May",Jun:"June",Jul:"July",Aug:"August",Sep:"September",Oct:"October",Nov:"November",Dec:"December"}[t]||t} 20${n}`},_fe=["Jan 25","Feb 25","Mar 25","Apr 25","May 25"],Efe=[24,27,20,26,23],Sfe=[4,17,8,5,16],A4=({data:e,labels:t,moveIn:n,moveOut:r})=>{const i=Array.isArray(e?.labels)&&e.labels.length>0?e.labels:Array.isArray(t)&&t.length>0?t:_fe,o=Array.isArray(e?.moveIn)&&e.moveIn.length>0?e.moveIn:Array.isArray(n)&&n.length>0?n:Efe,a=Array.isArray(e?.moveOut)&&e.moveOut.length>0?e.moveOut:Array.isArray(r)&&r.length>0?r:Sfe,s={labels:i,datasets:[{label:"Income",data:o,borderColor:"#10B981",backgroundColor:"rgba(16,185,129,0.15)",pointBackgroundColor:"#10B981",pointStyle:"rectRot",fill:!1},{label:"Expenditure",data:a,borderColor:"#AB0000",backgroundColor:"rgba(124,58,237,0.15)",pointBackgroundColor:"#AB0000",pointStyle:"rectRot",fill:!1}]},l={responsive:!0,maintainAspectRatio:!1,interaction:{mode:"index",intersect:!1},plugins:{legend:{display:!1},tooltip:{enabled:!1,external:ri({titleFormatter:c=>c.title?.[0]?wfe(c.title[0]):"",hideTitleForSingle:!1})}},scales:{x:{grid:{color:"#F1F5F9"},ticks:{color:"#64748B"}},y:{beginAtZero:!0,suggestedMax:28,grid:{color:"#F1F5F9"},ticks:{color:"#64748B",stepSize:4,precision:0}}},elements:{line:{borderWidth:2,tension:0},point:{radius:0,hoverRadius:3,hitRadius:10}}};return h.jsxs("div",{className:"h-full flex flex-col",children:[h.jsx("div",{className:"flex-1 min-h-0",children:h.jsx(R1,{data:s,options:l})}),h.jsx("div",{className:"flex items-center justify-around mt-[16px]",children:xfe.map(c=>h.jsxs("div",{className:"flex items-center gap-[8px]",children:[h.jsx("div",{className:`size-[7px] rotate-45 ${c.className}`,style:{backgroundColor:c.color}}),h.jsx("span",{className:"text-[14px] leading-[20px] text-[#64748B]",children:c.label})]},c.label))})]})};function T4({label:e,value:t,positive:n,bgColor:r,delta:i,deltaLabel:o,textColor:a}){return h.jsxs("div",{className:`rounded-[12px] p-[16px] ${r} !border !border-[#EBEBEB] !pr-[0px] !mr-[0px] h-[126px]`,children:[h.jsx("div",{className:`text-[16px] leading-[20px] ${a}`,children:e}),h.jsx("div",{className:"mt-[16px] leading-[28px] !text-[24px] font-medium text-[#121212]",children:t}),h.jsxs("div",{className:"mt-[8px] flex items-center gap-[4px] leading-[14px] text-[10px]",children:[h.jsx("div",{className:`
|
|
299
|
+
`):e}function Ude(e,t){const{element:n,datasetIndex:r,index:i}=t,o=e.getDatasetMeta(r).controller,{label:a,value:s}=o.getLabelAndValue(i);return{chart:e,label:a,parsed:o.getParsed(i),raw:e.data.datasets[r].data[i],formattedValue:s,dataset:o.getDataset(),dataIndex:i,datasetIndex:r,element:n}}function c4(e,t){const n=e.chart.ctx,{body:r,footer:i,title:o}=e,{boxWidth:a,boxHeight:s}=t,l=cr(t.bodyFont),c=cr(t.titleFont),u=cr(t.footerFont),d=o.length,f=i.length,p=r.length,m=li(t.padding);let g=m.height,v=0,x=r.reduce((y,E)=>y+E.before.length+E.lines.length+E.after.length,0);if(x+=e.beforeBody.length+e.afterBody.length,d&&(g+=d*c.lineHeight+(d-1)*t.titleSpacing+t.titleMarginBottom),x){const y=t.displayColors?Math.max(s,l.lineHeight):l.lineHeight;g+=p*y+(x-p)*l.lineHeight+(x-1)*t.bodySpacing}f&&(g+=t.footerMarginTop+f*u.lineHeight+(f-1)*t.footerSpacing);let _=0;const w=function(y){v=Math.max(v,n.measureText(y).width+_)};return n.save(),n.font=c.string,et(e.title,w),n.font=l.string,et(e.beforeBody.concat(e.afterBody),w),_=t.displayColors?a+2+t.boxPadding:0,et(r,y=>{et(y.before,w),et(y.lines,w),et(y.after,w)}),_=0,n.font=u.string,et(e.footer,w),n.restore(),v+=m.width,{width:v,height:g}}function Kde(e,t){const{y:n,height:r}=t;return n<r/2?"top":n>e.height-r/2?"bottom":"center"}function qde(e,t,n,r){const{x:i,width:o}=r,a=n.caretSize+n.caretPadding;if(e==="left"&&i+o+a>t.width||e==="right"&&i-o-a<0)return!0}function Gde(e,t,n,r){const{x:i,width:o}=n,{width:a,chartArea:{left:s,right:l}}=e;let c="center";return r==="center"?c=i<=(s+l)/2?"left":"right":i<=o/2?c="left":i>=a-o/2&&(c="right"),qde(c,e,t,n)&&(c="center"),c}function u4(e,t,n){const r=n.yAlign||t.yAlign||Kde(e,n);return{xAlign:n.xAlign||t.xAlign||Gde(e,t,n,r),yAlign:r}}function Xde(e,t){let{x:n,width:r}=e;return t==="right"?n-=r:t==="center"&&(n-=r/2),n}function Qde(e,t,n){let{y:r,height:i}=e;return t==="top"?r+=n:t==="bottom"?r-=i+n:r-=i/2,r}function d4(e,t,n,r){const{caretSize:i,caretPadding:o,cornerRadius:a}=e,{xAlign:s,yAlign:l}=n,c=i+o,{topLeft:u,topRight:d,bottomLeft:f,bottomRight:p}=Il(a);let m=Xde(t,s);const g=Qde(t,l,c);return l==="center"?s==="left"?m+=c:s==="right"&&(m-=c):s==="left"?m-=Math.max(u,f)+i:s==="right"&&(m+=Math.max(d,p)+i),{x:$n(m,0,r.width-t.width),y:$n(g,0,r.height-t.height)}}function cm(e,t,n){const r=li(n.padding);return t==="center"?e.x+e.width/2:t==="right"?e.x+e.width-r.right:e.x+r.left}function f4(e){return Ui([],Io(e))}function Zde(e,t,n){return hs(e,{tooltip:t,tooltipItems:n,type:"tooltip"})}function p4(e,t){const n=t&&t.dataset&&t.dataset.tooltip&&t.dataset.tooltip.callbacks;return n?e.override(n):e}const h4={beforeTitle:No,title(e){if(e.length>0){const t=e[0],n=t.chart.data.labels,r=n?n.length:0;if(this&&this.options&&this.options.mode==="dataset")return t.dataset.label||"";if(t.label)return t.label;if(r>0&&t.dataIndex<r)return n[t.dataIndex]}return""},afterTitle:No,beforeBody:No,beforeLabel:No,label(e){if(this&&this.options&&this.options.mode==="dataset")return e.label+": "+e.formattedValue||e.formattedValue;let t=e.dataset.label||"";t&&(t+=": ");const n=e.formattedValue;return Ke(n)||(t+=n),t},labelColor(e){const n=e.chart.getDatasetMeta(e.datasetIndex).controller.getStyle(e.dataIndex);return{borderColor:n.borderColor,backgroundColor:n.backgroundColor,borderWidth:n.borderWidth,borderDash:n.borderDash,borderDashOffset:n.borderDashOffset,borderRadius:0}},labelTextColor(){return this.options.bodyColor},labelPointStyle(e){const n=e.chart.getDatasetMeta(e.datasetIndex).controller.getStyle(e.dataIndex);return{pointStyle:n.pointStyle,rotation:n.rotation}},afterLabel:No,afterBody:No,beforeFooter:No,footer:No,afterFooter:No};function ur(e,t,n,r){const i=e[t].call(n,r);return typeof i>"u"?h4[t].call(n,r):i}class m4 extends va{static positioners=ed;constructor(t){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=t.chart,this.options=t.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(t){this.options=t,this._cachedAnimations=void 0,this.$context=void 0}_resolveAnimations(){const t=this._cachedAnimations;if(t)return t;const n=this.chart,r=this.options.setContext(this.getContext()),i=r.enabled&&n.options.animation&&r.animations,o=new vI(this.chart,i);return i._cacheable&&(this._cachedAnimations=Object.freeze(o)),o}getContext(){return this.$context||(this.$context=Zde(this.chart.getContext(),this,this._tooltipItems))}getTitle(t,n){const{callbacks:r}=n,i=ur(r,"beforeTitle",this,t),o=ur(r,"title",this,t),a=ur(r,"afterTitle",this,t);let s=[];return s=Ui(s,Io(i)),s=Ui(s,Io(o)),s=Ui(s,Io(a)),s}getBeforeBody(t,n){return f4(ur(n.callbacks,"beforeBody",this,t))}getBody(t,n){const{callbacks:r}=n,i=[];return et(t,o=>{const a={before:[],lines:[],after:[]},s=p4(r,o);Ui(a.before,Io(ur(s,"beforeLabel",this,o))),Ui(a.lines,ur(s,"label",this,o)),Ui(a.after,Io(ur(s,"afterLabel",this,o))),i.push(a)}),i}getAfterBody(t,n){return f4(ur(n.callbacks,"afterBody",this,t))}getFooter(t,n){const{callbacks:r}=n,i=ur(r,"beforeFooter",this,t),o=ur(r,"footer",this,t),a=ur(r,"afterFooter",this,t);let s=[];return s=Ui(s,Io(i)),s=Ui(s,Io(o)),s=Ui(s,Io(a)),s}_createItems(t){const n=this._active,r=this.chart.data,i=[],o=[],a=[];let s=[],l,c;for(l=0,c=n.length;l<c;++l)s.push(Ude(this.chart,n[l]));return t.filter&&(s=s.filter((u,d,f)=>t.filter(u,d,f,r))),t.itemSort&&(s=s.sort((u,d)=>t.itemSort(u,d,r))),et(s,u=>{const d=p4(t.callbacks,u);i.push(ur(d,"labelColor",this,u)),o.push(ur(d,"labelPointStyle",this,u)),a.push(ur(d,"labelTextColor",this,u))}),this.labelColors=i,this.labelPointStyles=o,this.labelTextColors=a,this.dataPoints=s,s}update(t,n){const r=this.options.setContext(this.getContext()),i=this._active;let o,a=[];if(!i.length)this.opacity!==0&&(o={opacity:0});else{const s=ed[r.position].call(this,i,this._eventPosition);a=this._createItems(r),this.title=this.getTitle(a,r),this.beforeBody=this.getBeforeBody(a,r),this.body=this.getBody(a,r),this.afterBody=this.getAfterBody(a,r),this.footer=this.getFooter(a,r);const l=this._size=c4(this,r),c=Object.assign({},s,l),u=u4(this.chart,r,c),d=d4(r,c,u,this.chart);this.xAlign=u.xAlign,this.yAlign=u.yAlign,o={opacity:1,x:d.x,y:d.y,width:l.width,height:l.height,caretX:s.x,caretY:s.y}}this._tooltipItems=a,this.$context=void 0,o&&this._resolveAnimations().update(this,o),t&&r.external&&r.external.call(this,{chart:this.chart,tooltip:this,replay:n})}drawCaret(t,n,r,i){const o=this.getCaretPosition(t,r,i);n.lineTo(o.x1,o.y1),n.lineTo(o.x2,o.y2),n.lineTo(o.x3,o.y3)}getCaretPosition(t,n,r){const{xAlign:i,yAlign:o}=this,{caretSize:a,cornerRadius:s}=r,{topLeft:l,topRight:c,bottomLeft:u,bottomRight:d}=Il(s),{x:f,y:p}=t,{width:m,height:g}=n;let v,x,_,w,y,E;return o==="center"?(y=p+g/2,i==="left"?(v=f,x=v-a,w=y+a,E=y-a):(v=f+m,x=v+a,w=y-a,E=y+a),_=v):(i==="left"?x=f+Math.max(l,u)+a:i==="right"?x=f+m-Math.max(c,d)-a:x=this.caretX,o==="top"?(w=p,y=w-a,v=x-a,_=x+a):(w=p+g,y=w+a,v=x+a,_=x-a),E=w),{x1:v,x2:x,x3:_,y1:w,y2:y,y3:E}}drawTitle(t,n,r){const i=this.title,o=i.length;let a,s,l;if(o){const c=Rl(r.rtl,this.x,this.width);for(t.x=cm(this,r.titleAlign,r),n.textAlign=c.textAlign(r.titleAlign),n.textBaseline="middle",a=cr(r.titleFont),s=r.titleSpacing,n.fillStyle=r.titleColor,n.font=a.string,l=0;l<o;++l)n.fillText(i[l],c.x(t.x),t.y+a.lineHeight/2),t.y+=a.lineHeight+s,l+1===o&&(t.y+=r.titleMarginBottom-s)}}_drawColorBox(t,n,r,i,o){const a=this.labelColors[r],s=this.labelPointStyles[r],{boxHeight:l,boxWidth:c}=o,u=cr(o.bodyFont),d=cm(this,"left",o),f=i.x(d),p=l<u.lineHeight?(u.lineHeight-l)/2:0,m=n.y+p;if(o.usePointStyle){const g={radius:Math.min(c,l)/2,pointStyle:s.pointStyle,rotation:s.rotation,borderWidth:1},v=i.leftForLtr(f,c)+c/2,x=m+l/2;t.strokeStyle=o.multiKeyBackground,t.fillStyle=o.multiKeyBackground,p1(t,g,v,x),t.strokeStyle=a.borderColor,t.fillStyle=a.backgroundColor,p1(t,g,v,x)}else{t.lineWidth=Me(a.borderWidth)?Math.max(...Object.values(a.borderWidth)):a.borderWidth||1,t.strokeStyle=a.borderColor,t.setLineDash(a.borderDash||[]),t.lineDashOffset=a.borderDashOffset||0;const g=i.leftForLtr(f,c),v=i.leftForLtr(i.xPlus(f,1),c-2),x=Il(a.borderRadius);Object.values(x).some(_=>_!==0)?(t.beginPath(),t.fillStyle=o.multiKeyBackground,Yh(t,{x:g,y:m,w:c,h:l,radius:x}),t.fill(),t.stroke(),t.fillStyle=a.backgroundColor,t.beginPath(),Yh(t,{x:v,y:m+1,w:c-2,h:l-2,radius:x}),t.fill()):(t.fillStyle=o.multiKeyBackground,t.fillRect(g,m,c,l),t.strokeRect(g,m,c,l),t.fillStyle=a.backgroundColor,t.fillRect(v,m+1,c-2,l-2))}t.fillStyle=this.labelTextColors[r]}drawBody(t,n,r){const{body:i}=this,{bodySpacing:o,bodyAlign:a,displayColors:s,boxHeight:l,boxWidth:c,boxPadding:u}=r,d=cr(r.bodyFont);let f=d.lineHeight,p=0;const m=Rl(r.rtl,this.x,this.width),g=function(D){n.fillText(D,m.x(t.x+p),t.y+f/2),t.y+=f+o},v=m.textAlign(a);let x,_,w,y,E,S,P;for(n.textAlign=a,n.textBaseline="middle",n.font=d.string,t.x=cm(this,v,r),n.fillStyle=r.bodyColor,et(this.beforeBody,g),p=s&&v!=="right"?a==="center"?c/2+u:c+2+u:0,y=0,S=i.length;y<S;++y){for(x=i[y],_=this.labelTextColors[y],n.fillStyle=_,et(x.before,g),w=x.lines,s&&w.length&&(this._drawColorBox(n,t,y,m,r),f=Math.max(d.lineHeight,l)),E=0,P=w.length;E<P;++E)g(w[E]),f=d.lineHeight;et(x.after,g)}p=0,f=d.lineHeight,et(this.afterBody,g),t.y-=o}drawFooter(t,n,r){const i=this.footer,o=i.length;let a,s;if(o){const l=Rl(r.rtl,this.x,this.width);for(t.x=cm(this,r.footerAlign,r),t.y+=r.footerMarginTop,n.textAlign=l.textAlign(r.footerAlign),n.textBaseline="middle",a=cr(r.footerFont),n.fillStyle=r.footerColor,n.font=a.string,s=0;s<o;++s)n.fillText(i[s],l.x(t.x),t.y+a.lineHeight/2),t.y+=a.lineHeight+r.footerSpacing}}drawBackground(t,n,r,i){const{xAlign:o,yAlign:a}=this,{x:s,y:l}=t,{width:c,height:u}=r,{topLeft:d,topRight:f,bottomLeft:p,bottomRight:m}=Il(i.cornerRadius);n.fillStyle=i.backgroundColor,n.strokeStyle=i.borderColor,n.lineWidth=i.borderWidth,n.beginPath(),n.moveTo(s+d,l),a==="top"&&this.drawCaret(t,n,r,i),n.lineTo(s+c-f,l),n.quadraticCurveTo(s+c,l,s+c,l+f),a==="center"&&o==="right"&&this.drawCaret(t,n,r,i),n.lineTo(s+c,l+u-m),n.quadraticCurveTo(s+c,l+u,s+c-m,l+u),a==="bottom"&&this.drawCaret(t,n,r,i),n.lineTo(s+p,l+u),n.quadraticCurveTo(s,l+u,s,l+u-p),a==="center"&&o==="left"&&this.drawCaret(t,n,r,i),n.lineTo(s,l+d),n.quadraticCurveTo(s,l,s+d,l),n.closePath(),n.fill(),i.borderWidth>0&&n.stroke()}_updateAnimationTarget(t){const n=this.chart,r=this.$animations,i=r&&r.x,o=r&&r.y;if(i||o){const a=ed[t.position].call(this,this._active,this._eventPosition);if(!a)return;const s=this._size=c4(this,t),l=Object.assign({},a,this._size),c=u4(n,t,l),u=d4(t,l,c,n);(i._to!==u.x||o._to!==u.y)&&(this.xAlign=c.xAlign,this.yAlign=c.yAlign,this.width=s.width,this.height=s.height,this.caretX=a.x,this.caretY=a.y,this._resolveAnimations().update(this,u))}}_willRender(){return!!this.opacity}draw(t){const n=this.options.setContext(this.getContext());let r=this.opacity;if(!r)return;this._updateAnimationTarget(n);const i={width:this.width,height:this.height},o={x:this.x,y:this.y};r=Math.abs(r)<.001?0:r;const a=li(n.padding),s=this.title.length||this.beforeBody.length||this.body.length||this.afterBody.length||this.footer.length;n.enabled&&s&&(t.save(),t.globalAlpha=r,this.drawBackground(o,t,i,n),uI(t,n.textDirection),o.y+=a.top,this.drawTitle(o,t,n),this.drawBody(o,t,n),this.drawFooter(o,t,n),dI(t,n.textDirection),t.restore())}getActiveElements(){return this._active||[]}setActiveElements(t,n){const r=this._active,i=t.map(({datasetIndex:s,index:l})=>{const c=this.chart.getDatasetMeta(s);if(!c)throw new Error("Cannot find a dataset at index "+s);return{datasetIndex:s,element:c.data[l],index:l}}),o=!Bh(r,i),a=this._positionChanged(i,n);(o||a)&&(this._active=i,this._eventPosition=n,this._ignoreReplayEvents=!0,this.update(!0))}handleEvent(t,n,r=!0){if(n&&this._ignoreReplayEvents)return!1;this._ignoreReplayEvents=!1;const i=this.options,o=this._active||[],a=this._getActiveElements(t,o,n,r),s=this._positionChanged(a,t),l=n||!Bh(a,o)||s;return l&&(this._active=a,(i.enabled||i.external)&&(this._eventPosition={x:t.x,y:t.y},this.update(!0,n))),l}_getActiveElements(t,n,r,i){const o=this.options;if(t.type==="mouseout")return[];if(!i)return n.filter(s=>this.chart.data.datasets[s.datasetIndex]&&this.chart.getDatasetMeta(s.datasetIndex).controller.getParsed(s.index)!==void 0);const a=this.chart.getElementsAtEventForMode(t,o.mode,o,r);return o.reverse&&a.reverse(),a}_positionChanged(t,n){const{caretX:r,caretY:i,options:o}=this,a=ed[o.position].call(this,t,n);return a!==!1&&(r!==a.x||i!==a.y)}}var Ar={id:"tooltip",_element:m4,positioners:ed,afterInit(e,t,n){n&&(e.tooltip=new m4({chart:e,options:n}))},beforeUpdate(e,t,n){e.tooltip&&e.tooltip.initialize(n)},reset(e,t,n){e.tooltip&&e.tooltip.initialize(n)},afterDraw(e){const t=e.tooltip;if(t&&t._willRender()){const n={tooltip:t};if(e.notifyPlugins("beforeTooltipDraw",{...n,cancelable:!0})===!1)return;t.draw(e.ctx),e.notifyPlugins("afterTooltipDraw",n)}},afterEvent(e,t){if(e.tooltip){const n=t.replay;e.tooltip.handleEvent(t.event,n,t.inChartArea)&&(t.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:(e,t)=>t.bodyFont.size,boxWidth:(e,t)=>t.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:h4},defaultRoutes:{bodyFont:"font",footerFont:"font",titleFont:"font"},descriptors:{_scriptable:e=>e!=="filter"&&e!=="itemSort"&&e!=="external",_indexable:!1,callbacks:{_scriptable:!1,_indexable:!1},animation:{_fallback:!1},animations:{_fallback:"animation"}},additionalOptionScopes:["interaction"]};const Jde=(e,t,n,r)=>(typeof t=="string"?(n=e.push(t)-1,r.unshift({index:n,label:t})):isNaN(t)&&(n=null),n);function efe(e,t,n,r){const i=e.indexOf(t);if(i===-1)return Jde(e,t,n,r);const o=e.lastIndexOf(t);return i!==o?n:i}const tfe=(e,t)=>e===null?null:$n(Math.round(e),0,t);function g4(e){const t=this.getLabels();return e>=0&&e<t.length?t[e]:e}class Fo extends $l{static id="category";static defaults={ticks:{callback:g4}};constructor(t){super(t),this._startValue=void 0,this._valueRange=0,this._addedLabels=[]}init(t){const n=this._addedLabels;if(n.length){const r=this.getLabels();for(const{index:i,label:o}of n)r[i]===o&&r.splice(i,1);this._addedLabels=[]}super.init(t)}parse(t,n){if(Ke(t))return null;const r=this.getLabels();return n=isFinite(n)&&r[n]===t?n:efe(r,t,Oe(n,t),this._addedLabels),tfe(n,r.length-1)}determineDataLimits(){const{minDefined:t,maxDefined:n}=this.getUserBounds();let{min:r,max:i}=this.getMinMax(!0);this.options.bounds==="ticks"&&(t||(r=0),n||(i=this.getLabels().length-1)),this.min=r,this.max=i}buildTicks(){const t=this.min,n=this.max,r=this.options.offset,i=[];let o=this.getLabels();o=t===0&&n===o.length-1?o:o.slice(t,n+1),this._valueRange=Math.max(o.length-(r?0:1),1),this._startValue=this.min-(r?.5:0);for(let a=t;a<=n;a++)i.push({value:a});return i}getLabelForValue(t){return g4.call(this,t)}configure(){super.configure(),this.isHorizontal()||(this._reversePixels=!this._reversePixels)}getPixelForValue(t){return typeof t!="number"&&(t=this.parse(t)),t===null?NaN:this.getPixelForDecimal((t-this._startValue)/this._valueRange)}getPixelForTick(t){const n=this.ticks;return t<0||t>n.length-1?null:this.getPixelForValue(n[t].value)}getValueForPixel(t){return Math.round(this._startValue+this.getDecimalForPixel(t)*this._valueRange)}getBasePixel(){return this.bottom}}function nfe(e,t){const n=[],{bounds:i,step:o,min:a,max:s,precision:l,count:c,maxTicks:u,maxDigits:d,includeBounds:f}=e,p=o||1,m=u-1,{min:g,max:v}=t,x=!Ke(a),_=!Ke(s),w=!Ke(c),y=(v-g)/(d+1);let E=LM((v-g)/m/p)*p,S,P,D,T;if(E<1e-14&&!x&&!_)return[{value:g},{value:v}];T=Math.ceil(v/E)-Math.floor(g/E),T>m&&(E=LM(T*E/m/p)*p),Ke(l)||(S=Math.pow(10,l),E=Math.ceil(E*S)/S),i==="ticks"?(P=Math.floor(g/E)*E,D=Math.ceil(v/E)*E):(P=g,D=v),x&&_&&o&&Ele((s-a)/o,E/1e3)?(T=Math.round(Math.min((s-a)/E,u)),E=(s-a)/T,P=a,D=s):w?(P=x?a:P,D=_?s:D,T=c-1,E=(D-P)/T):(T=(D-P)/E,Wu(T,Math.round(T),E/1e3)?T=Math.round(T):T=Math.ceil(T));const I=Math.max(RM(E),RM(P));S=Math.pow(10,Ke(l)?I:l),P=Math.round(P*S)/S,D=Math.round(D*S)/S;let A=0;for(x&&(f&&P!==a?(n.push({value:a}),P<a&&A++,Wu(Math.round((P+A*E)*S)/S,a,v4(a,y,e))&&A++):P<a&&A++);A<T;++A){const C=Math.round((P+A*E)*S)/S;if(_&&C>s)break;n.push({value:C})}return _&&f&&D!==s?n.length&&Wu(n[n.length-1].value,s,v4(s,y,e))?n[n.length-1].value=s:n.push({value:s}):(!_||D===s)&&n.push({value:D}),n}function v4(e,t,{horizontal:n,minRotation:r}){const i=jo(r),o=(n?Math.sin(i):Math.cos(i))||.001,a=.75*t*(""+e).length;return Math.min(t/o,a)}class rfe extends $l{constructor(t){super(t),this.start=void 0,this.end=void 0,this._startValue=void 0,this._endValue=void 0,this._valueRange=0}parse(t,n){return Ke(t)||(typeof t=="number"||t instanceof Number)&&!isFinite(+t)?null:+t}handleTickRangeOptions(){const{beginAtZero:t}=this.options,{minDefined:n,maxDefined:r}=this.getUserBounds();let{min:i,max:o}=this;const a=l=>i=n?i:l,s=l=>o=r?o:l;if(t){const l=Hi(i),c=Hi(o);l<0&&c<0?s(0):l>0&&c>0&&a(0)}if(i===o){let l=o===0?1:Math.abs(o*.05);s(o+l),t||a(i-l)}this.min=i,this.max=o}getTickLimit(){const t=this.options.ticks;let{maxTicksLimit:n,stepSize:r}=t,i;return r?(i=Math.ceil(this.max/r)-Math.floor(this.min/r)+1,i>1e3&&(console.warn(`scales.${this.id}.ticks.stepSize: ${r} would result generating up to ${i} ticks. Limiting to 1000.`),i=1e3)):(i=this.computeTickLimit(),n=n||11),n&&(i=Math.min(n,i)),i}computeTickLimit(){return Number.POSITIVE_INFINITY}buildTicks(){const t=this.options,n=t.ticks;let r=this.getTickLimit();r=Math.max(2,r);const i={maxTicks:r,bounds:t.bounds,min:t.min,max:t.max,precision:n.precision,step:n.stepSize,count:n.count,maxDigits:this._maxDigits(),horizontal:this.isHorizontal(),minRotation:n.minRotation||0,includeBounds:n.includeBounds!==!1},o=this._range||this,a=nfe(i,o);return t.bounds==="ticks"&&Sle(a,this,"value"),t.reverse?(a.reverse(),this.start=this.max,this.end=this.min):(this.start=this.min,this.end=this.max),a}configure(){const t=this.ticks;let n=this.min,r=this.max;if(super.configure(),this.options.offset&&t.length){const i=(r-n)/Math.max(t.length-1,1)/2;n-=i,r+=i}this._startValue=n,this._endValue=r,this._valueRange=r-n}getLabelForValue(t){return u1(t,this.chart.options.locale,this.options.ticks.format)}}class Lo extends rfe{static id="linear";static defaults={ticks:{callback:XM.formatters.numeric}};determineDataLimits(){const{min:t,max:n}=this.getMinMax(!0);this.min=Qr(t)?t:0,this.max=Qr(n)?n:1,this.handleTickRangeOptions()}computeTickLimit(){const t=this.isHorizontal(),n=t?this.width:this.height,r=jo(this.options.ticks.minRotation),i=(t?Math.sin(r):Math.cos(r))||.001,o=this._resolveTickFontOptions(0);return Math.ceil(n/Math.min(40,o.lineHeight/i))}getPixelForValue(t){return t===null?NaN:this.getPixelForDecimal((t-this._startValue)/this._valueRange)}getValueForPixel(t){return this._startValue+this.getDecimalForPixel(t)*this._valueRange}}const um={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}},dr=Object.keys(um);function y4(e,t){return e-t}function b4(e,t){if(Ke(t))return null;const n=e._adapter,{parser:r,round:i,isoWeekday:o}=e._parseOpts;let a=t;return typeof r=="function"&&(a=r(a)),Qr(a)||(a=typeof r=="string"?n.parse(a,r):n.parse(a)),a===null?null:(i&&(a=i==="week"&&(zu(o)||o===!0)?n.startOf(a,"isoWeek",o):n.startOf(a,i)),+a)}function x4(e,t,n,r){const i=dr.length;for(let o=dr.indexOf(e);o<i-1;++o){const a=um[dr[o]],s=a.steps?a.steps:Number.MAX_SAFE_INTEGER;if(a.common&&Math.ceil((n-t)/(s*a.size))<=r)return dr[o]}return dr[i-1]}function ife(e,t,n,r,i){for(let o=dr.length-1;o>=dr.indexOf(n);o--){const a=dr[o];if(um[a].common&&e._adapter.diff(i,r,a)>=t-1)return a}return dr[n?dr.indexOf(n):0]}function ofe(e){for(let t=dr.indexOf(e)+1,n=dr.length;t<n;++t)if(um[dr[t]].common)return dr[t]}function w4(e,t,n){if(!n)e[t]=!0;else if(n.length){const{lo:r,hi:i}=s1(n,t),o=n[r]>=t?n[r]:n[i];e[o]=!0}}function afe(e,t,n,r){const i=e._adapter,o=+i.startOf(t[0].value,r),a=t[t.length-1].value;let s,l;for(s=o;s<=a;s=+i.add(s,1,r))l=n[s],l>=0&&(t[l].major=!0);return t}function _4(e,t,n){const r=[],i={},o=t.length;let a,s;for(a=0;a<o;++a)s=t[a],i[s]=a,r.push({value:s,major:!1});return o===0||!n?r:afe(e,r,i,n)}class E4 extends $l{static id="time";static defaults={bounds:"data",adapters:{},time:{parser:!1,unit:!1,round:!1,isoWeekday:!1,minUnit:"millisecond",displayFormats:{}},ticks:{source:"auto",callback:!1,major:{enabled:!1}}};constructor(t){super(t),this._cache={data:[],labels:[],all:[]},this._unit="day",this._majorUnit=void 0,this._offsets={},this._normalized=!1,this._parseOpts=void 0}init(t,n={}){const r=t.time||(t.time={}),i=this._adapter=new fue._date(t.adapters.date);i.init(n),$u(r.displayFormats,i.formats()),this._parseOpts={parser:r.parser,round:r.round,isoWeekday:r.isoWeekday},super.init(t),this._normalized=n.normalized}parse(t,n){return t===void 0?null:b4(this,t)}beforeLayout(){super.beforeLayout(),this._cache={data:[],labels:[],all:[]}}determineDataLimits(){const t=this.options,n=this._adapter,r=t.time.unit||"day";let{min:i,max:o,minDefined:a,maxDefined:s}=this.getUserBounds();function l(c){!a&&!isNaN(c.min)&&(i=Math.min(i,c.min)),!s&&!isNaN(c.max)&&(o=Math.max(o,c.max))}(!a||!s)&&(l(this._getLabelBounds()),(t.bounds!=="ticks"||t.ticks.source!=="labels")&&l(this.getMinMax(!1))),i=Qr(i)&&!isNaN(i)?i:+n.startOf(Date.now(),r),o=Qr(o)&&!isNaN(o)?o:+n.endOf(Date.now(),r)+1,this.min=Math.min(i,o-1),this.max=Math.max(i+1,o)}_getLabelBounds(){const t=this.getLabelTimestamps();let n=Number.POSITIVE_INFINITY,r=Number.NEGATIVE_INFINITY;return t.length&&(n=t[0],r=t[t.length-1]),{min:n,max:r}}buildTicks(){const t=this.options,n=t.time,r=t.ticks,i=r.source==="labels"?this.getLabelTimestamps():this._generate();t.bounds==="ticks"&&i.length&&(this.min=this._userMin||i[0],this.max=this._userMax||i[i.length-1]);const o=this.min,a=this.max,s=Dle(i,o,a);return this._unit=n.unit||(r.autoSkip?x4(n.minUnit,this.min,this.max,this._getLabelCapacity(o)):ife(this,s.length,n.minUnit,this.min,this.max)),this._majorUnit=!r.major.enabled||this._unit==="year"?void 0:ofe(this._unit),this.initOffsets(i),t.reverse&&s.reverse(),_4(this,s,this._majorUnit)}afterAutoSkip(){this.options.offsetAfterAutoskip&&this.initOffsets(this.ticks.map(t=>+t.value))}initOffsets(t=[]){let n=0,r=0,i,o;this.options.offset&&t.length&&(i=this.getDecimalForValue(t[0]),t.length===1?n=1-i:n=(this.getDecimalForValue(t[1])-i)/2,o=this.getDecimalForValue(t[t.length-1]),t.length===1?r=o:r=(o-this.getDecimalForValue(t[t.length-2]))/2);const a=t.length<3?.5:.25;n=$n(n,0,a),r=$n(r,0,a),this._offsets={start:n,end:r,factor:1/(n+1+r)}}_generate(){const t=this._adapter,n=this.min,r=this.max,i=this.options,o=i.time,a=o.unit||x4(o.minUnit,n,r,this._getLabelCapacity(n)),s=Oe(i.ticks.stepSize,1),l=a==="week"?o.isoWeekday:!1,c=zu(l)||l===!0,u={};let d=n,f,p;if(c&&(d=+t.startOf(d,"isoWeek",l)),d=+t.startOf(d,c?"day":a),t.diff(r,n,a)>1e5*s)throw new Error(n+" and "+r+" are too far apart with stepSize of "+s+" "+a);const m=i.ticks.source==="data"&&this.getDataTimestamps();for(f=d,p=0;f<r;f=+t.add(f,s,a),p++)w4(u,f,m);return(f===r||i.bounds==="ticks"||p===1)&&w4(u,f,m),Object.keys(u).sort(y4).map(g=>+g)}getLabelForValue(t){const n=this._adapter,r=this.options.time;return r.tooltipFormat?n.format(t,r.tooltipFormat):n.format(t,r.displayFormats.datetime)}format(t,n){const i=this.options.time.displayFormats,o=this._unit,a=n||i[o];return this._adapter.format(t,a)}_tickFormatFunction(t,n,r,i){const o=this.options,a=o.ticks.callback;if(a)return bt(a,[t,n,r],this);const s=o.time.displayFormats,l=this._unit,c=this._majorUnit,u=l&&s[l],d=c&&s[c],f=r[n],p=c&&d&&f&&f.major;return this._adapter.format(t,i||(p?d:u))}generateTickLabels(t){let n,r,i;for(n=0,r=t.length;n<r;++n)i=t[n],i.label=this._tickFormatFunction(i.value,n,t)}getDecimalForValue(t){return t===null?NaN:(t-this.min)/(this.max-this.min)}getPixelForValue(t){const n=this._offsets,r=this.getDecimalForValue(t);return this.getPixelForDecimal((n.start+r)*n.factor)}getValueForPixel(t){const n=this._offsets,r=this.getDecimalForPixel(t)/n.factor-n.end;return this.min+r*(this.max-this.min)}_getLabelSize(t){const n=this.options.ticks,r=this.ctx.measureText(t).width,i=jo(this.isHorizontal()?n.maxRotation:n.minRotation),o=Math.cos(i),a=Math.sin(i),s=this._resolveTickFontOptions(0).size;return{w:r*o+s*a,h:r*a+s*o}}_getLabelCapacity(t){const n=this.options.time,r=n.displayFormats,i=r[n.unit]||r.millisecond,o=this._tickFormatFunction(t,0,_4(this,[t],this._majorUnit),i),a=this._getLabelSize(o),s=Math.floor(this.isHorizontal()?this.width/a.w:this.height/a.h)-1;return s>0?s:1}getDataTimestamps(){let t=this._cache.data||[],n,r;if(t.length)return t;const i=this.getMatchingVisibleMetas();if(this._normalized&&i.length)return this._cache.data=i[0].controller.getAllParsedValues(this);for(n=0,r=i.length;n<r;++n)t=t.concat(i[n].controller.getAllParsedValues(this));return this._cache.data=this.normalize(t)}getLabelTimestamps(){const t=this._cache.labels||[];let n,r;if(t.length)return t;const i=this.getLabels();for(n=0,r=i.length;n<r;++n)t.push(b4(this,i[n]));return this._cache.labels=this._normalized?t:this.normalize(t)}normalize(t){return zM(t.sort(y4))}}function dm(e,t,n){let r=0,i=e.length-1,o,a,s,l;n?(t>=e[r].pos&&t<=e[i].pos&&({lo:r,hi:i}=ds(e,"pos",t)),{pos:o,time:s}=e[r],{pos:a,time:l}=e[i]):(t>=e[r].time&&t<=e[i].time&&({lo:r,hi:i}=ds(e,"time",t)),{time:o,pos:s}=e[r],{time:a,pos:l}=e[i]);const c=a-o;return c?s+(l-s)*(t-o)/c:s}class hme extends E4{static id="timeseries";static defaults=E4.defaults;constructor(t){super(t),this._table=[],this._minPos=void 0,this._tableRange=void 0}initOffsets(){const t=this._getTimestampsForTable(),n=this._table=this.buildLookupTable(t);this._minPos=dm(n,this.min),this._tableRange=dm(n,this.max)-this._minPos,super.initOffsets(t)}buildLookupTable(t){const{min:n,max:r}=this,i=[],o=[];let a,s,l,c,u;for(a=0,s=t.length;a<s;++a)c=t[a],c>=n&&c<=r&&i.push(c);if(i.length<2)return[{time:n,pos:0},{time:r,pos:1}];for(a=0,s=i.length;a<s;++a)u=i[a+1],l=i[a-1],c=i[a],Math.round((u+l)/2)!==c&&o.push({time:c,pos:a/(s-1)});return o}_generate(){const t=this.min,n=this.max;let r=super.getDataTimestamps();return(!r.includes(t)||!r.length)&&r.splice(0,0,t),(!r.includes(n)||r.length===1)&&r.push(n),r.sort((i,o)=>i-o)}_getTimestampsForTable(){let t=this._cache.all||[];if(t.length)return t;const n=this.getDataTimestamps(),r=this.getLabelTimestamps();return n.length&&r.length?t=this.normalize(n.concat(r)):t=n.length?n:r,t=this._cache.all=t,t}getDecimalForValue(t){return(dm(this._table,t)-this._minPos)/this._tableRange}getValueForPixel(t){const n=this._offsets,r=this.getDecimalForPixel(t)/n.factor-n.end;return dm(this._table,r*this._tableRange+this._minPos,!0)}}const S4="label";function O4(e,t){typeof e=="function"?e(t):e&&(e.current=t)}function sfe(e,t){const n=e.options;n&&t&&Object.assign(n,t)}function C4(e,t){e.labels=t}function k4(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:S4;const r=[];e.datasets=t.map(i=>{const o=e.datasets.find(a=>a[n]===i[n]);return!o||!i.data||r.includes(o)?{...i}:(r.push(o),Object.assign(o,i),o)})}function lfe(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:S4;const n={labels:[],datasets:[]};return C4(n,e.labels),k4(n,e.datasets,t),n}function cfe(e,t){const{height:n=150,width:r=300,redraw:i=!1,datasetIdKey:o,type:a,data:s,options:l,plugins:c=[],fallbackContent:u,updateMode:d,...f}=e,p=k.useRef(null),m=k.useRef(null),g=()=>{p.current&&(m.current=new Bn(p.current,{type:a,data:lfe(s,o),options:l&&{...l},plugins:c}),O4(t,m.current))},v=()=>{O4(t,null),m.current&&(m.current.destroy(),m.current=null)};return k.useEffect(()=>{!i&&m.current&&l&&sfe(m.current,l)},[i,l]),k.useEffect(()=>{!i&&m.current&&C4(m.current.config.data,s.labels)},[i,s.labels]),k.useEffect(()=>{!i&&m.current&&s.datasets&&k4(m.current.config.data,s.datasets,o)},[i,s.datasets]),k.useEffect(()=>{m.current&&(i?(v(),setTimeout(g)):m.current.update(d))},[i,l,s.labels,s.datasets,d]),k.useEffect(()=>{m.current&&(v(),setTimeout(g))},[a]),k.useEffect(()=>(g(),()=>v()),[]),k.createElement("canvas",{ref:p,role:"img",height:n,width:r,...f},u)}const ufe=k.forwardRef(cfe);function L1(e,t){return Bn.register(t),k.forwardRef((n,r)=>k.createElement(ufe,{...n,ref:r,type:e}))}const R1=L1("line",due),zl=L1("bar",lue),fm=L1("doughnut",uue);function Vt({image:e="https://cdni.iconscout.com/illustration/premium/thumb/businessman-sad-for-no-data-in-folder-illustration-svg-download-png-10155562.png",title:t="No Data Available",description:n="Catch up all the data. Change the date range to see the data."}){return h.jsxs("div",{className:"flex flex-col items-center justify-center h-full text-center px-[16px]",children:[h.jsx("img",{src:e,alt:"no data",className:"w-32 h-32 mb-4 opacity-80"}),h.jsx("div",{className:"text-[16px] font-semibold text-gray-900 mb-[4px]",children:t}),h.jsx("div",{className:"text-[12px] text-gray-500 max-w-[260px]",children:n})]})}Bn.register(lm,Ar,Zr);const dfe={id:"bottomGlow",afterDatasetsDraw(e,t,n){if(!n?.enabled)return;const r=e.getDatasetMeta(0);if(!r?.data?.[0])return;const{ctx:i}=e,{x:o,y:a,innerRadius:s}=r.data[0],l=Math.max(s-2,0),c=a+l*.9,u=i.createRadialGradient(o,c,0,o,c,l*1.08);u.addColorStop(0,n.color??"rgba(186, 230, 253, 0.72)"),u.addColorStop(.3,"rgba(186, 230, 253, 0.4)"),u.addColorStop(.58,"rgba(186, 230, 253, 0.16)"),u.addColorStop(1,"rgba(186, 230, 253, 0)"),i.save(),i.beginPath(),i.arc(o,a,l,0,Math.PI*2),i.clip(),i.fillStyle=u,i.beginPath(),i.ellipse(o,c,l*1.08,l*.52,0,0,Math.PI*2),i.fill(),i.restore()}},ffe=({title:e="Tickets",icon:t,firstLabel:n="First",firstValue:r=0,firstColor:i="#12B981",secondLabel:o="Second",secondValue:a=0,secondColor:s="#AB0000",growthPercentage:l="+0%",growthText:c="Compared to last month",totalLabel:u="Total",centerTopColor:d="#0F172A",centerBottomColor:f="#64748B",centerTopSize:p,centerBottomSize:m,showBottomGlow:g=!1,bottomGlowColor:v="rgba(186, 230, 253, 0.75)",showEmptyStateWhenZero:x=!1,widgetType:_="",resolvedWidgetType:w="",data:y})=>{const E=y?.title??e,S=y?.icon??t,P=y?.firstLabel??n,D=Number(y?.firstValue??r??0),T=y?.firstColor??i,I=y?.secondLabel??o,A=Number(y?.secondValue??a??0),C=y?.secondColor??s,j=y?.growthPercentage??l??"+0%",N=y?.growthText??c,M=y?.totalLabel??u,R=y?.widgetType??_??w,B=y?.centerTopSize??p??(R==="commercial"?34:24),V=y?.centerBottomSize??m??(R==="commercial"?14:9),z=y?.showBottomGlow??g,W=y?.bottomGlowColor??v,Q=y?.showEmptyStateWhenZero??x??y?.total_units!==void 0,G=D+A,ie=Number(y?.total_units?.current??G),J=Q&&G===0&&ie===0,re={labels:[P,I],datasets:[{data:[D,A],backgroundColor:[T,C],borderWidth:2,hoverOffset:4}]},se={responsive:!0,maintainAspectRatio:!1,cutout:"68%",plugins:{legend:{display:!1},tooltip:{enabled:!1,external:ri()},bottomGlow:{enabled:z,color:W}}},ce=[{label:P,value:D,color:T},{label:I,value:A,color:C}],de=j.toString().includes("+"),K=j.toString().includes("-"),U=de?"#1FA05B":"#AB0000";return h.jsx(Le,{title:E,icon:S,className:`${R==="commercial"?"h-[362px]":"h-[238px]"} !gap-[24px]`,childrenClassName:J?"h-full":"!flex-none",children:J?h.jsx("div",{className:"w-full h-full flex items-center justify-center",children:h.jsx(Vt,{})}):h.jsxs("div",{className:"grid grid-cols-12 gap-[16px] items-center",children:[h.jsxs("div",{className:"col-span-5 flex flex-1 flex-col h-full gap-[12px]",children:[ce.map((Z,F)=>h.jsxs("div",{children:[h.jsx("div",{className:"mb-[8px] text-[12px] text-[#64748B]",children:Z.label}),h.jsx("div",{className:"text-[28px] leading-[32px] font-medium",style:{color:Z.color},children:Z.value})]},F)),h.jsxs("div",{className:`py-[4px] text-[10px] leading-[14px] flex gap-[4px] ${R==="commercial"?"mt-[20px]":""} items-center`,style:{color:U},children:[de&&h.jsx(Xo,{}),K&&h.jsx(Go,{}),h.jsx("div",{children:j.replace("+","").replace("-","")}),h.jsx("div",{className:"text-[#64748B] text-[10px] leading-[14px] ml-[4px] whitespace-nowrap",children:N})]})]}),h.jsx("div",{className:"col-span-7",children:h.jsxs("div",{className:`${R==="commercial"?"h-[260px] max-w-[263px]":"h-[162px] w-[162px]"} relative ml-auto mr-2`,children:[h.jsx(fm,{data:re,options:se,plugins:[dfe]}),h.jsxs("div",{className:"pointer-events-none absolute inset-0 flex flex-col items-center justify-center text-center",children:[h.jsx("div",{style:{color:d,fontSize:B,fontWeight:500,lineHeight:"28px"},children:G}),h.jsx("div",{style:{color:f,fontSize:V,fontWeight:400,lineHeight:"11px",marginTop:R==="commercial"?10:5},children:M})]})]})})]})})},P4=({value:e=0,total:t=1,colorClass:n="",label:r=""})=>{const i=Math.max(0,Math.min(100,e/(t||1)*100)),o=n==="bg-[#8B5CF6]"?"text-[#8B5CF6]":n==="bg-[#12B981]"?"text-[#12B981]":"text-slate-600";return h.jsxs("div",{className:"flex flex-col gap-[4.5px] items-start",children:[h.jsx("div",{className:"w-2/3 min-w-[80px] h-[11px] rounded-full overflow-hidden",children:h.jsx("div",{className:`h-3 rounded-full ${n}`,style:{width:`${i}%`}})}),h.jsx("div",{className:`${o} !text-[12px] !leading-[16px] font-bold`,children:e}),h.jsx("div",{className:"!text-[12px] !leading-[16px] text-[#64748B]",children:r})]})},D4=({title:e,value:t,suffix:n,valueClass:r=""})=>h.jsxs("div",{className:"bg-white rounded-[12px] shadow-[0_0_12px_0_#EAF2FF] h-[98px] p-[16px] flex flex-col gap-[4px] justify-center",children:[h.jsx("div",{className:"!text-[12px] leading-[16px] text-[#121212] mb-[4px]",children:e}),h.jsxs("div",{className:`text-[28px] leading-[32px] flex item gap-[4px] font-medium ${r}`,children:[t," ",n&&h.jsx("div",{className:"text-[28px] leading-[32px] font-medium",children:n})]})]}),pfe=({data:e,totalUnits:t=847,occupiedUnits:n=756,ownerCount:r=700,tenantCount:i=56,avgResidents:o=4.4,avgLeaseMonths:a=18})=>{const s=Number(e?.totalUnits??t??0),l=Number(e?.occupiedUnits??n??0),c=Number(e?.ownerCount??r??0),u=Number(e?.tenantCount??i??0),d=e?.avgResidents??o,f=e?.avgLeaseMonths??a,p=c+u;return h.jsxs("div",{children:[h.jsxs("div",{className:"bg-white rounded-[12px] shadow-[0_0_12px_0_#EAF2FF] h-[128px] p-[16px] !mb-4",children:[h.jsxs("div",{className:"flex items-center gap-[8px] mb-[24px]",children:[h.jsx(Ng,{className:"h-[20px] w-[20px] text-[#329DFF]"}),h.jsx("div",{className:"font-medium text-[16px] leading-[20px] text-[#121212]",children:"Occupancy Overview"})]}),h.jsxs("div",{className:"flex items-center justify-between",children:[h.jsxs("div",{className:"flex flex-col gap-[4px]",children:[h.jsx("div",{className:"leading-[16px] text-[12px] text-[#64748B]",children:"Occupied Units"}),h.jsxs("div",{className:"flex items-baseline",children:[h.jsx("div",{className:"text-[28px] leading-[32px] font-medium text-[#121212]",children:l}),h.jsxs("div",{className:"text-[#64748B] text-[20px] leading-[32px]",children:["/",s]})]})]}),h.jsxs("div",{className:"flex items-end",children:[h.jsx(P4,{value:c,total:p,colorClass:"bg-[#8B5CF6]",label:"Owner"}),h.jsx(P4,{value:u,total:p,colorClass:"bg-[#12B981]",label:"Tenant"})]})]})]}),h.jsxs("div",{className:"mt-2.5 grid grid-cols-2 gap-[12px]",children:[h.jsx(D4,{title:"Avg Residents Per Unit",value:d,valueClass:"text-[#8B5CF6]"}),h.jsx(D4,{title:"Avg Lease Period",value:f,suffix:"months",valueClass:"text-[#E7A015]"})]})]})};Bn.register(lm,Ar,Zr);const hfe=({data:e,ownerCount:t=1e3,tenantCount:n=200,nonResidingOwners:r=26,growthPct:i="+9.1%"})=>{const o=Number(e?.ownerCount??t??0),a=Number(e?.tenantCount??n??0),s=Number(e?.nonResidingOwners??r??0),l=e?.growthPct??i,c=Math.max(o-s,0),u=o+a,d={labels:["Owners","Tenants","Non-residing Owner"],datasets:[{data:[c,a,s],backgroundColor:["#3C81F6","#08B6D4","#8B5CF6"],borderWidth:2,hoverOffset:4}]},f={responsive:!0,maintainAspectRatio:!1,cutout:"68%",plugins:{legend:{display:!1},tooltip:{enabled:!1,external:ri()}}};return h.jsx(Le,{title:"Resident Overview",icon:h.jsx(cS,{className:"h-[20px] w-[20px] text-[#8B5CF6]"}),className:"h-[238px] !gap-[24px]",children:h.jsxs("div",{className:" flex-1 min-h-0 grid grid-cols-12 gap-[16px] items-center",children:[h.jsxs("div",{className:"col-span-5 flex flex-1 flex-col h-full gap-[12px]",children:[h.jsxs("div",{children:[h.jsx("div",{className:"!text-[12px] text-[#64748B] leading-[16px] mb-[8px]",children:"Total Owners"}),h.jsx("div",{className:"text-[28px] leading-[32px] font-medium text-[#3C81F6]",children:o})]}),h.jsxs("div",{children:[h.jsx("div",{className:"!text-[12px] text-[#64748B] leading-[16px] mb-[8px]",children:"Total Tenants"}),h.jsx("div",{className:"text-[28px] leading-[32px] font-medium text-[#08B6D4]",children:a})]}),h.jsxs("div",{className:"py-[4px] text-[10px] leading-[14px] flex gap-[4px] text-[#1FA05B] items-center",children:[h.jsx("div",{children:l}),h.jsx("div",{className:"text-[#64748B] text-[10px] leading-[14px] ml-[4px] whitespace-nowrap",children:"Compared to last month"})]})]}),h.jsx("div",{className:"col-span-7",children:h.jsxs("div",{className:"relative h-[162px] w-[162px] ml-auto mr-2",children:[h.jsx(fm,{data:d,options:f}),h.jsxs("div",{className:"pointer-events-none absolute inset-0 flex flex-col gap-[5.5px] items-center justify-center text-center",children:[h.jsx("div",{style:{color:"#121212",fontSize:24,fontWeight:600,lineHeight:"28px"},children:u}),h.jsx("div",{style:{color:"#64748B",fontSize:9,fontWeight:400,lineHeight:"11.5px"},children:"Total Members"})]})]})})]})})};Bn.register(Fo,Lo,Wl,Ar,Zr);const mfe=[{label:"Owner",color:"#3C81F6"},{label:"Rented",color:"#8B5CF6"},{label:"Vacant",color:"#08B6D4"}],gfe=({data:e,blocks:t=[{name:"Block A",owner:110,rented:24,vacant:8},{name:"Block B",owner:95,rented:18,vacant:6},{name:"Block C",owner:65,rented:12,vacant:18},{name:"Block D",owner:78,rented:16,vacant:30}]})=>{const n=Array.isArray(e?.blocks)&&e.blocks.length>0?e.blocks:Array.isArray(e)&&e.length>0?e:t,r=n.map(c=>c.name),i=n.map(c=>Number(c.owner??0)),o=n.map(c=>Number(c.rented??0)),a=n.map(c=>Number(c.vacant??0)),s={labels:r,datasets:[{label:"Owner",data:i,backgroundColor:"#3C81F6",barThickness:40},{label:"",data:i.map(()=>2),backgroundColor:"transparent",barThickness:40},{label:"Rented",data:o,backgroundColor:"#8B5CF6",barThickness:40},{label:"",data:o.map(()=>2),backgroundColor:"transparent",barThickness:40},{label:"Vacant",data:a,backgroundColor:"#08B6D4",barThickness:40}]},l={responsive:!0,maintainAspectRatio:!1,plugins:{legend:{display:!1},tooltip:{enabled:!1,external:ri({hideTitleForSingle:!1})}},scales:{x:{stacked:!0,grid:{display:!1},ticks:{color:"#64748B"}},y:{stacked:!0,beginAtZero:!0,suggestedMax:180,grid:{color:"#F1F5F9"},ticks:{color:"#64748B",stepSize:20}}}};return h.jsx(Le,{title:"Block-wise Occupancy",className:"w-full h-[360px]",titleClassName:"!text-[20px] !leading-[24px] !font-semibold",children:h.jsxs("div",{className:"h-full flex flex-col",children:[h.jsx("div",{className:"flex-1 min-h-0",children:h.jsx(zl,{data:s,options:l})}),h.jsx("div",{className:"flex items-center justify-around pt-[12px]",children:mfe.map(c=>h.jsxs("div",{className:"flex items-center gap-[6px]",children:[h.jsx("div",{className:"w-[10px] h-[10px] rotate-45",style:{backgroundColor:c.color}}),h.jsx("span",{className:"text-[14px] leading-[18px] text-[#64748B]",children:c.label})]},c.label))})]})})};Bn.register(Fo,Lo,M1,j1,Ar,Zr);const vfe=[{label:"Move-in",color:"#12B981"},{label:"Move-out",color:"#8B5CF6"}],yfe=e=>{const[t,n]=String(e).split(" ");return`${{Jan:"January",Feb:"February",Mar:"March",Apr:"April",May:"May",Jun:"June",Jul:"July",Aug:"August",Sep:"September",Oct:"October",Nov:"November",Dec:"December"}[t]||t} 20${n}`},bfe=({data:e,labels:t=["Jan 25","Feb 25","Mar 25","Apr 25","May 25"],moveIn:n=[24,27,20,26,23],moveOut:r=[12,17,8,5,16]})=>{const i=Array.isArray(e?.labels)&&e.labels.length>0?e.labels:t,o=Array.isArray(e?.moveIn)&&e.moveIn.length>0?e.moveIn:n,a=Array.isArray(e?.moveOut)&&e.moveOut.length>0?e.moveOut:r,s={labels:i,datasets:[{label:"Move-in",data:o,borderColor:"#12B981",backgroundColor:"rgba(16,185,129,0.15)",pointBackgroundColor:"#12B981",pointStyle:"rectRot",fill:!1},{label:"Move-out",data:a,borderColor:"#8B5CF6",backgroundColor:"rgba(124,58,237,0.15)",pointBackgroundColor:"#8B5CF6",pointStyle:"rectRot",fill:!1}]},l={responsive:!0,maintainAspectRatio:!1,interaction:{mode:"index",intersect:!1},plugins:{legend:{display:!1},tooltip:{enabled:!1,external:ri({titleFormatter:c=>c.title?.[0]?yfe(c.title[0]):"",hideTitleForSingle:!1})}},scales:{x:{grid:{color:"#F1F5F9"},ticks:{color:"#64748B"}},y:{beginAtZero:!0,suggestedMax:28,grid:{color:"#F1F5F9"},ticks:{color:"#64748B",stepSize:4,precision:0}}},elements:{line:{borderWidth:2,tension:0},point:{radius:0,hoverRadius:3,hitRadius:10}}};return h.jsx(Le,{title:"Move-in/Out Trends",className:"w-full h-[360px]",titleClassName:"!text-[20px] !leading-[24px] !font-semibold",children:h.jsxs("div",{className:"h-full flex flex-col",children:[h.jsx("div",{className:"flex-1 min-h-0",children:h.jsx(R1,{data:s,options:l})}),h.jsx("div",{className:"flex items-center justify-around pt-[12px]",children:vfe.map(c=>h.jsxs("div",{className:"flex items-center gap-[6px]",children:[h.jsx("div",{className:"w-[10px] h-[10px] rotate-45",style:{backgroundColor:c.color}}),h.jsx("span",{className:"text-[14px] leading-[18px] text-[#64748B]",children:c.label})]},c.label))})]})})};Bn.register(Fo,Lo,M1,j1,Ar,Zr);const xfe=[{label:"Income",className:"bg-gradient-to-r from-[#8CEAE5] to-[#40A39E]"},{label:"Expenditure",className:"bg-gradient-to-r from-[#D86E6E] to-[#AB0000]"}],wfe=e=>{const[t,n]=String(e).split(" ");return`${{Jan:"January",Feb:"February",Mar:"March",Apr:"April",May:"May",Jun:"June",Jul:"July",Aug:"August",Sep:"September",Oct:"October",Nov:"November",Dec:"December"}[t]||t} 20${n}`},_fe=["Jan 25","Feb 25","Mar 25","Apr 25","May 25"],Efe=[24,27,20,26,23],Sfe=[4,17,8,5,16],A4=({data:e,labels:t,moveIn:n,moveOut:r})=>{const i=Array.isArray(e?.labels)&&e.labels.length>0?e.labels:Array.isArray(t)&&t.length>0?t:_fe,o=Array.isArray(e?.moveIn)&&e.moveIn.length>0?e.moveIn:Array.isArray(n)&&n.length>0?n:Efe,a=Array.isArray(e?.moveOut)&&e.moveOut.length>0?e.moveOut:Array.isArray(r)&&r.length>0?r:Sfe,s={labels:i,datasets:[{label:"Income",data:o,borderColor:"#10B981",backgroundColor:"rgba(16,185,129,0.15)",pointBackgroundColor:"#10B981",pointStyle:"rectRot",fill:!1},{label:"Expenditure",data:a,borderColor:"#AB0000",backgroundColor:"rgba(124,58,237,0.15)",pointBackgroundColor:"#AB0000",pointStyle:"rectRot",fill:!1}]},l={responsive:!0,maintainAspectRatio:!1,interaction:{mode:"index",intersect:!1},plugins:{legend:{display:!1},tooltip:{enabled:!1,external:ri({titleFormatter:c=>c.title?.[0]?wfe(c.title[0]):"",hideTitleForSingle:!1})}},scales:{x:{grid:{color:"#F1F5F9"},ticks:{color:"#64748B"}},y:{beginAtZero:!0,suggestedMax:28,grid:{color:"#F1F5F9"},ticks:{color:"#64748B",stepSize:4,precision:0}}},elements:{line:{borderWidth:2,tension:0},point:{radius:0,hoverRadius:3,hitRadius:10}}};return h.jsxs("div",{className:"h-full flex flex-col",children:[h.jsx("div",{className:"flex-1 min-h-0",children:h.jsx(R1,{data:s,options:l})}),h.jsx("div",{className:"flex items-center justify-around mt-[16px]",children:xfe.map(c=>h.jsxs("div",{className:"flex items-center gap-[8px]",children:[h.jsx("div",{className:`size-[7px] rotate-45 ${c.className}`,style:{backgroundColor:c.color}}),h.jsx("span",{className:"text-[14px] leading-[20px] text-[#64748B]",children:c.label})]},c.label))})]})};function T4({label:e,value:t,positive:n,bgColor:r,delta:i,deltaLabel:o,textColor:a}){return h.jsxs("div",{className:`rounded-[12px] p-[16px] ${r} !border !border-[#EBEBEB] !pr-[0px] !mr-[0px] h-[126px]`,children:[h.jsx("div",{className:`text-[16px] leading-[20px] ${a}`,children:e}),h.jsx("div",{className:"mt-[16px] leading-[28px] !text-[24px] font-medium text-[#121212]",children:t}),h.jsxs("div",{className:"mt-[8px] flex items-center gap-[4px] leading-[14px] text-[10px]",children:[h.jsx("div",{className:`
|
|
300
300
|
${n?"bg-[#F7FEFA] text-[#1FA05B]":"bg-[#FBF4F4] text-[#EF4444]"} p-[4px] rounded-[4px] font-medium
|
|
301
301
|
`,children:i}),h.jsx("div",{className:"text-[#64748B] ",children:o})]})]})}function Ofe({data:e={}}){const t=e?.incomeCard??{label:"Total Income",value:"AED 5.68M",delta:"+4.4%",positive:!0,bgColor:"bg-gradient-to-b from-[#FCFAFC] to-[#FFFFFF]/0",deltaLabel:"Compared to last month",textColor:"text-[#1FA05B]"},n=e?.expenditureCard??{label:"Total Expenditure",value:"AED 1.83M",delta:"-1.1%",positive:!1,bgColor:"bg-gradient-to-b from-[#FCFAFC] to-[#FFFFFF]/0",deltaLabel:"Compared to last month",textColor:"text-[#AB0000]"};return h.jsxs(Le,{title:"Accounting",className:"w-full h-[523px] gap-[35.5px]! p-[24px]!",titleClassName:"!text-[20px] !leading-[24px] font-semibold!",children:[h.jsxs("div",{className:"grid grid-cols-2 gap-[16px]",children:[h.jsx(T4,{...t}),h.jsx(T4,{...n})]}),h.jsx("div",{className:"h-[254px] mt-[35.5px]",children:h.jsx(A4,{data:e?.incomeExpenditure})})]})}Bn.register(Fo,Lo,Wl,Ar,Zr);const Cfe=[{label:"Budget",color:"#B4DBFF"},{label:"Actual",color:"#3C82F6"}],kfe=["Maintenance","Security","Utilities","Housekeeping","Administration","Others"],Pfe=[55e3,56e3,64e3,38e3,54e3,65e3],Dfe=[63e3,48e3,51300,28e3,42e3,35e3],Afe=({data:e={}})=>{const t=Array.isArray(e?.labels)&&e.labels.length>0?e.labels:kfe,n=Array.isArray(e?.budgetValues)&&e.budgetValues.length>0?e.budgetValues:Pfe,r=Array.isArray(e?.actualValues)&&e.actualValues.length>0?e.actualValues:Dfe,i={labels:t,datasets:[{label:"Budget",data:n,backgroundColor:"#93C5FD",barThickness:60},{label:"Actual",data:r,backgroundColor:"#3B82F6",barThickness:60}]},o={responsive:!0,maintainAspectRatio:!1,plugins:{legend:{display:!1},tooltip:{enabled:!1,external:ri({titleFormatter:a=>a.title?.[0]||"",hideTitleForSingle:!1,rowsFormatter:a=>(a.dataPoints||[]).map(s=>({label:s.dataset.label||s.label,value:`AED ${(Number(s.raw??0)/1e3).toFixed(1)}K`,color:s.dataset.backgroundColor}))})}},scales:{x:{grid:{display:!1},ticks:{color:"#64748B"}},y:{beginAtZero:!0,grid:{color:"#F1F5F9"},ticks:{color:"#64748B",callback:a=>`${a/1e3}K`}}}};return h.jsx(Le,{title:"Budget vs Actuals",className:"w-full h-[362px] !p-[24px] !gap-[20px]",titleClassName:"!text-[20px] !leading-[24px] font-semibold!",children:h.jsxs("div",{className:"h-full flex flex-col",children:[h.jsx("div",{className:"flex-1 min-h-0",children:h.jsx(zl,{data:i,options:o})}),h.jsx("div",{className:"flex items-center justify-center gap-20 pt-[12px]",children:Cfe.map(a=>h.jsxs("div",{className:"flex items-center gap-[6px]",children:[h.jsx("div",{className:"w-[10px] h-[10px] rotate-45",style:{backgroundColor:a.color}}),h.jsx("span",{className:"text-[14px] leading-[18px] text-[#64748B]",children:a.label})]},a.label))})]})})},Tfe=[{title:"Primary Account",amount:285e4,subtitle:"Savings"},{title:"Emergency Fund",amount:12e5,subtitle:"Fixed deposit"},{title:"Maintenance Fund",amount:68e4,subtitle:"Current"}],Nfe=({data:e})=>{const t=Array.isArray(e?.accounts)&&e.accounts.length>0?e.accounts:Array.isArray(e)&&e.length>0?e:Tfe,n=t.reduce((i,o)=>i+o.amount,0),r=i=>i>=1e6?`AED ${(i/1e6).toFixed(2)}M`:i>=1e3?`AED ${(i/1e3).toFixed(1)}K`:`AED ${i}`;return h.jsxs(Le,{title:"Cash & Bank Balance",className:"w-full h-[362px] !p-[24px] relative",titleClassName:"!text-[20px] !leading-[24px] font-semibold!",childrenClassName:"!space-y-[0px]",children:[h.jsx("div",{className:"flex flex-col gap-[16px] pb-[16px] max-h-[230px] overflow-y-auto hide-scrollbar",children:t.map((i,o)=>h.jsxs("div",{className:"flex items-center justify-between bg-gradient-to-b from-[#FCFAFC] to-[#FFFFFF]/0 border-[0.5px] border-[#EBEBEB] rounded-[12px] p-[12px]",children:[h.jsxs("div",{className:"flex flex-col gap-[8px]",children:[h.jsx("div",{className:"text-[16px] leading-[20px] font-semibold text-[#121212]",children:i.title}),h.jsx("div",{className:"!text-[12px] leading-[16px] text-[#64748B]",children:i?.subtitle})]}),h.jsx("div",{className:"flex flex-col items-end",children:h.jsx("div",{className:"text-[16px] leading-[20px] font-semibold text-[#1FA05B]",children:r(i.amount)})})]},o))}),h.jsx("div",{className:"absolute left-0 bottom-[66px] w-full border-t border-[#EBEBEB]"}),h.jsx("div",{className:"w-full absolute left-0 bottom-[12px]",children:h.jsxs("div",{className:"pt-[20px] px-[34px] p-[12px] flex items-center justify-between",children:[h.jsx("div",{className:"text-[16px] leading-[20px] font-semibold text-[#121212]",children:"Total"}),h.jsx("div",{className:"text-[16px] leading-[20px] font-semibold text-[#1FA05B]",children:r(n)})]})})]})};Bn.register(Fo,Lo,Wl,Ar,Zr);const jfe=[{label:"Current Month",value:13e3,units:18},{label:"1-3 Months",value:9400,units:12},{label:"3-6 Months",value:8800,units:18},{label:"6+ Months",value:7200,units:6}],Mfe=({data:e})=>{const t=Array.isArray(e?.items)&&e.items.length>0?e.items:Array.isArray(e)&&e.length>0?e:jfe,n=t.map(s=>s.label),r=t.map(s=>Number(s.value??0)),i=t.map(s=>Number(s.units??0)),o={labels:n,datasets:[{label:"Due",data:r,backgroundColor:"#EF4444",barThickness:60}]},a={responsive:!0,maintainAspectRatio:!1,plugins:{legend:{display:!1},tooltip:{enabled:!1,external:ri({titleFormatter:s=>s.title?.[0]||"",hideTitleForSingle:!1,rowsFormatter:s=>{const l=s.dataPoints?.[0];return l?[{label:"Due",value:`AED ${(Number(l.raw??0)/1e3).toFixed(1)}K`,color:l.dataset.backgroundColor},{label:"Units Count",value:`${i[l.dataIndex]??0}`,color:l.dataset.backgroundColor}]:[]}})}},scales:{x:{grid:{display:!1},ticks:{color:"#64748B"}},y:{beginAtZero:!0,grid:{color:"#F1F5F9"},ticks:{color:"#64748B",callback:s=>`${s/1e3}K`}}}};return h.jsxs(Le,{title:"Dues Ageing",className:"w-full h-[362px] !gap-[24px] !p-[24px]",titleClassName:"!text-[20px] !leading-[24px] font-semibold!",childrenClassName:"!space-y-[24px]",children:[h.jsx("div",{className:"grid grid-cols-4 md:grid-cols-4 gap-[12px]",children:n.map((s,l)=>h.jsx("div",{className:"p-[8px] rounded-[4px] bg-[#F8FAFC]",children:h.jsxs("div",{className:"flex justify-between items-start",children:[h.jsx("div",{className:"font-medium !leading-[16px] !text-[12px] rounded",children:s}),h.jsxs("div",{className:"text-right",children:[h.jsxs("div",{className:"text-[#AB0000] font-medium !leading-[16px] !text-[12px]",children:["AED ",(r[l]/1e3).toFixed(1),"K"]}),h.jsxs("div",{className:"mt-[2px] text-[#64748B] !leading-[14px] !text-[10px] tracking-[-2%]",children:[i[l]," Units"]})]})]})},s))}),h.jsx("div",{className:"h-[192px]",children:h.jsx(zl,{data:o,options:a})})]})};Bn.register(lm,Ar,Zr);const Ife=[{label:"Maintenance",value:45e4,color:"#08B6D4"},{label:"Utilities",value:32e4,color:"#8B5CF6"},{label:"Security",value:28e4,color:"#EF4444"},{label:"Administration",value:18e4,color:"#F69E0A"},{label:"Others",value:12e4,color:"#12B981"}],Ffe=({data:e})=>{const t=Array.isArray(e?.items)&&e.items.length>0?e.items:Array.isArray(e)&&e.length>0?e:Ife,n=t.map(l=>l.label),r=t.map(l=>Number(l.value??0)),i=t.map(l=>l.color),o={labels:n,datasets:[{label:"Expenses",data:r,backgroundColor:i,borderColor:"#FFFFFF",borderWidth:2,cutout:"70%"}]},a=r.reduce((l,c)=>l+c,0),s={responsive:!0,maintainAspectRatio:!1,plugins:{legend:{display:!1},tooltip:{enabled:!1,external:ri({rowsFormatter:l=>(l.dataPoints||[]).map(c=>({label:c.label,value:`AED ${c.formattedValue}`,color:Array.isArray(c.dataset.backgroundColor)?c.dataset.backgroundColor[c.dataIndex]:c.dataset.backgroundColor}))})}}};return h.jsxs(Le,{title:"Expense Categories",className:"w-full h-[523px] p-[24px]!",titleClassName:"!text-[20px] !leading-[24px] font-semibold!",children:[h.jsxs("div",{className:"relative h-[259px] flex justify-center items-center",children:[h.jsx(fm,{data:o,options:s}),h.jsxs("div",{className:"absolute text-center",children:[h.jsxs("div",{className:"!text-[24px] font-medium leading-[28px] text-[#121212]",children:["AED ",(a/1e6).toFixed(2),"M"]}),h.jsx("div",{className:"text-[#121212] leading-[18px] text-[14px] mt-[8px]",children:"Total Expenses"})]})]}),h.jsx("div",{className:"space-y-[16px]",children:n.map((l,c)=>h.jsxs("div",{className:"flex justify-between items-center text-[14px]",children:[h.jsxs("div",{className:"flex items-center gap-[8px] !text-[12px] leading-[16px] text-[#64748B] tracking-[-2%]",children:[h.jsx("div",{className:"w-[7px] h-[7px] rotate-45",style:{backgroundColor:o.datasets[0].backgroundColor[c]}}),l]}),h.jsxs("div",{className:"leading-[16px] !text-[12px] text-[#64748B] tracking-[-2%]",children:["AED ",(r[c]/1e3).toFixed(0),"K"]})]},l))})]})},Lfe=[{name:"Gym Equipment",value:1e6,color:"#08B6D4"},{name:"Security",value:8e5,color:"#EF4444"},{name:"Others",value:6e5,color:"#F59E0B"},{name:"Pool Maintenance",value:7e5,color:"#8B5CF6"},{name:"Administration",value:52e4,color:"#10B981"}];function Rfe({data:e,currency:t="AED"}){const n=Array.isArray(e)&&e.length>0?e:Lfe,r=n.reduce((o,a)=>o+Number(a.value??0),0);let i="";return r>=1e6?i=`${(r/1e6).toFixed(2)}M`:r>=1e3?i=`${(r/1e3).toFixed(2)}K`:i=r.toString(),h.jsx(Le,{title:"Asset Value Breakdown",className:"w-full h-[362px]",titleClassName:"!text-[20px] !leading-[24px] font-semibold!",children:r>0?h.jsxs("div",{className:"flex flex-col items-center justify-center",children:[h.jsxs("div",{className:"w-[214px] h-[181px] relative",children:[h.jsx(Ot,{width:"100%",height:"100%",children:h.jsxs($i,{children:[h.jsx(ai,{data:n,innerRadius:60,outerRadius:90,paddingAngle:2,dataKey:"value",nameKey:"name",children:n.map((o,a)=>h.jsx(In,{fill:o.color},`cell-${a}`))}),h.jsx(St,{cursor:{fill:"transparent"},wrapperStyle:{outline:"none",zIndex:9999},allowEscapeViewBox:{x:!0,y:!0},content:Nc({data:n,formatter:o=>`${t} ${Number(o).toLocaleString()}`})})]})}),h.jsx("div",{className:"absolute inset-0 pointer-events-none flex flex-col items-center justify-center",children:h.jsxs("div",{className:"flex flex-col items-center justify-center",children:[h.jsxs("div",{className:"font-semibold text-[18px] leading-[12px] mb-[6px]",children:[t," ",i]}),h.jsx("div",{className:"text-[10px] leading-[12.59px] text-[#121212] mt-[6px]",children:"Total Assets"})]})})]}),h.jsxs("div",{className:"flex justify-between w-full px-[8px] sm:px-[12px] mt-4 text-[14px]",children:[h.jsx("div",{className:"flex flex-col gap-[12px]",children:n.slice(0,3).map(o=>h.jsxs("div",{className:"flex items-center gap-[8px]",children:[h.jsx("div",{className:"inline-block h-[7px] w-[7px] rotate-45",style:{backgroundColor:o.color}}),h.jsx("div",{className:"text-[#64748B] leading-[16px] !text-[12px]",children:o.name})]},o.name))}),h.jsx("div",{className:"flex flex-col gap-[12px] items-start",children:n.slice(3).map(o=>h.jsxs("div",{className:"flex items-center gap-[8px]",children:[h.jsx("div",{className:"inline-block h-[7px] w-[7px] rotate-45",style:{backgroundColor:o.color}}),h.jsx("div",{className:"text-[#64748B] !leading-[16px] !text-[12px] ",children:o.name})]},o.name))})]})]}):h.jsx("div",{className:"h-full flex items-center justify-center",children:h.jsx(Vt,{})})})}Bn.register(Fo,Lo,Wl,Ar,Zr);const $fe=[{label:"Gym",value:13e3,units:18},{label:"Parking",value:9400,units:12},{label:"Swimming Pool",value:8800,units:18},{label:"Community Hall",value:7200,units:6},{label:"Tennis Court",value:6e3,units:10}],Bfe=({data:e})=>{const t=Array.isArray(e)&&e.length>0?e:$fe,n=t.map(u=>u.label),r=t.map(u=>Number(u.value??0)),i=t.map(u=>Number(u.units??0)),o=Math.max(...r,0),a=o<=1e3?1e3:Math.ceil(o/1e3)*1e3,s=a<=1e3?100:a/5,l={labels:n,datasets:[{label:"Due",data:r,backgroundColor:"#8B5CF6",barThickness:60}]},c={responsive:!0,maintainAspectRatio:!1,plugins:{legend:{display:!1},tooltip:{enabled:!1,external:ri({titleFormatter:u=>u.title?.[0]||"",hideTitleForSingle:!1,rowsFormatter:u=>{const d=u.dataPoints?.[0];return d?[{label:"Revenue",value:`AED ${(Number(d.raw??0)/1e3).toFixed(1)}K`,color:d.dataset.backgroundColor},{label:"Units Count",value:`${i[d.dataIndex]??0}`,color:d.dataset.backgroundColor}]:[]}})}},scales:{x:{grid:{display:!1},ticks:{color:"#64748B"}},y:{beginAtZero:!0,max:a,grid:{color:"#F1F5F9"},ticks:{color:"#64748B",stepSize:s,callback:u=>`${Number(u)/1e3}K`}}}};return h.jsx(Le,{title:"Revenue by Category",className:"w-full h-[362px] p-[24px]! gap-[29px]!",titleClassName:"!text-[20px] !leading-[24px] font-semibold!",children:h.jsx(zl,{data:l,options:c})})};function Wfe(e){return gt({attr:{viewBox:"0 0 1024 1024"},child:[{tag:"path",attr:{d:"M855.7 210.8l-42.4-42.4a8.03 8.03 0 0 0-11.3 0L168.3 801.9a8.03 8.03 0 0 0 0 11.3l42.4 42.4c3.1 3.1 8.2 3.1 11.3 0L855.6 222c3.2-3 3.2-8.1.1-11.2zM304 448c79.4 0 144-64.6 144-144s-64.6-144-144-144-144 64.6-144 144 64.6 144 144 144zm0-216c39.7 0 72 32.3 72 72s-32.3 72-72 72-72-32.3-72-72 32.3-72 72-72zm416 344c-79.4 0-144 64.6-144 144s64.6 144 144 144 144-64.6 144-144-64.6-144-144-144zm0 216c-39.7 0-72-32.3-72-72s32.3-72 72-72 72 32.3 72 72-32.3 72-72 72z"},child:[]}]})(e)}/**
|
|
302
302
|
* @license lucide-react v0.564.0 - ISC
|
|
@@ -477,6 +477,6 @@ Take a look at the reducer(s) handling this action type: ${p.type}.
|
|
|
477
477
|
${i?"bg-[#F7FEFA] text-[#1FA05B]":"bg-[#FBF4F4] text-[#EF4444]"} p-[4px] rounded-[4px] font-medium
|
|
478
478
|
`,children:n}),h.jsx("div",{className:"text-slate-500",children:r})]})]})}const hpe=[{title:"Total Bookings",value:160,delta:"+11.0%",deltaLabel:"Compared to last month",positive:!0,Icon:lS,iconColor:"text-emerald-600"},{title:"Utilisation Rate",value:73,delta:"+2.0%",deltaLabel:"Compared to last month",positive:!0,Icon:Wfe,iconColor:"text-[#329DFF]"},{title:"Revenue",value:3,delta:"+11.0%",deltaLabel:"Compared to last month",positive:!0,Icon:R4,iconColor:"text-[#FA7E28]"},{title:"Pending Dues",value:5,delta:"-8.0%",deltaLabel:"Compared to last month",positive:!1,Icon:M4,iconColor:"text-[#AB0000]"}];function mpe({data:e}){const t=Array.isArray(e)&&e.length>0?e:hpe;return console.log(e,"carrrr"),h.jsx("div",{className:"px-[20px] grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-4 gap-[24px]",children:t.map((n,r)=>h.jsx(ppe,{...n},r))})}const kt=({title:e,icon:t,period:n,isDateSelector:r=!1,children:i,footer:o,className:a="",titleWeight:s,titleColor:l,iconClassName:c,titleClassName:u,childrenClassName:d,rightContent:f,onCalendarClick:p,onPrevClick:m,onNextClick:g})=>{const v=s==="semi-bold"?600:500;return h.jsxs("div",{className:`relative bg-white p-[24px] !border-[0.5px] !border-[#EBEBEB] !rounded-[12px] !shadow-[0_0_12px_0_#EAF2FF] ${a}`,children:[h.jsxs("div",{className:"flex items-center justify-between",children:[h.jsxs("div",{className:"flex items-center gap-[8px]",children:[t&&h.jsx("div",{className:c,children:t}),h.jsx("div",{style:{fontWeight:v,color:l||"#121212"},className:u||"text-[20px] leading-[24px]",children:e})]}),h.jsxs("div",{className:"flex items-center gap-[12px]",children:[f&&f,n&&!r&&h.jsx("div",{className:"text-[12px] leading-[16px] text-[#64748B]",children:n}),r&&h.jsxs("div",{className:"flex items-center gap-[12px] px-[16px] py-[8px] rounded-[8px] bg-white text-sm text-[#64748B]",children:[h.jsx(qfe,{size:16,className:"text-[#64748B] cursor-pointer",onClick:p}),h.jsx($1,{size:16,className:"cursor-pointer",onClick:m}),h.jsx("span",{className:"text-[12px] leading-[16px] text-[#64748B]",children:n}),h.jsx(B1,{size:16,className:"cursor-pointer",onClick:g})]})]})]}),h.jsx("div",{className:`flex-1 min-h-0 mt-4 ${d}`,children:i}),o&&h.jsx("div",{className:"mt-4 pt-4 border-t border-gray-100 text-[12px] text-[#64748B]",children:o})]})},gpe={completed:18,not_completed:6,missed:4};function vpe({data:e={}}){const t=e&&Object.keys(e).length>0?e:gpe,n=[{name:"Completed",value:Number(t?.completed??0),color:"#12B981"},{name:"Delayed",value:Number(t?.not_completed??0),color:"#EF4444"},{name:"Missed",value:Number(t?.missed??0),color:"#F69E0A"}],r=Number(t?.completed??0)+Number(t?.not_completed??0)+Number(t?.missed??0),i=Number(t?.completed??0);return h.jsx(kt,{title:"Guard Patrols",className:"h-[362px]",titleClassName:"!text-[20px] !leading-[24px] font-semibold!",children:h.jsxs("div",{className:"flex flex-col items-center justify-center",children:[h.jsxs("div",{className:"w-[215px] h-[182px] relative",children:[h.jsx(Ot,{width:"100%",height:"100%",children:h.jsxs($i,{children:[h.jsx(ai,{data:n??[],innerRadius:60,outerRadius:90,paddingAngle:2,dataKey:"value",nameKey:"name",children:n?.map?.((o,a)=>h.jsx(In,{fill:o?.color??"#ccc"},`cell-${a}`))}),h.jsx(St,{cursor:{fill:"transparent"},wrapperStyle:{outline:"none",zIndex:9999},allowEscapeViewBox:{x:!0,y:!0},content:Nc({data:n})})]})}),h.jsxs("div",{className:"absolute inset-0 flex flex-col items-center justify-center pointer-events-none",children:[h.jsxs("div",{className:"font-medium text-[19.35px] leading-[23.65px]",children:[i??0,"/",r??0]}),h.jsx("div",{className:"text-[10.75px] leading-[15.05px] text-[#64748B]",children:"Completed"})]})]}),h.jsx("div",{className:"flex flex-col w-full text-[14px]",children:n?.length?n?.map?.((o,a)=>h.jsxs("div",{className:`flex items-center justify-between py-[10px] ${a!==(n?.length??0)-1,""}`,children:[h.jsxs("div",{className:"flex items-center gap-[8px]",children:[h.jsx("div",{className:"inline-block h-[7px] w-[7px] rotate-45",style:{backgroundColor:o.color}}),h.jsx("div",{className:"text-[#64748B] leading-[16px] !text-[12px]",children:o.name})]},o.name),h.jsx("div",{className:"leading-[16.09px] text-[12.07px] text-[#64748B]",children:o?.value??0})]},o?.name??a)):h.jsx("div",{className:"text-center text-gray-400 text-sm py-[24px]",children:"No patrol data"})})]})})}Bn.register(Fo,Lo,M1,j1,Ar,Zr);const ype=["10 AM","12 PM","2 PM","4 PM","6 PM","8 PM","10 PM"],pm={guest:[9,5,12,7,3,6,4],cab:[15,12,10,14,7,12,8],delivery:[22,18,16,20,22,14,17],service:[13,12,8,9,5,10,7]},bpe=[{key:"Guest",datasetIndex:0,color:"#EF4444"},{key:"Cab",datasetIndex:1,color:"#7C3AED"},{key:"Delivery",datasetIndex:2,color:"#10B981"},{key:"Service",datasetIndex:3,color:"#F59E0B"}],xpe=({color:e,size:t=12})=>h.jsx("div",{className:"inline-block h-[7px] w-[7px] rotate-45",style:{backgroundColor:e}}),wpe=({chartRef:e})=>{const[t,n]=k.useState({}),r=i=>{const o=e.current;if(!o)return;const a=o.getDatasetMeta(i),s=!!a.hidden;a.hidden=!s,o.update(),n(l=>({...l,[i]:!s}))};return h.jsx("div",{style:{display:"flex",flexDirection:"row",justifyContent:"center",alignItems:"center",gap:"76px",marginTop:"10px",paddingBottom:"8px",flexWrap:"wrap"},children:bpe.map(({key:i,datasetIndex:o,color:a})=>{const s=!!t[o];return h.jsxs("div",{onClick:()=>r(o),style:{display:"flex",alignItems:"center",gap:"6px",cursor:"pointer",userSelect:"none",opacity:s?.45:1,transition:"opacity 0.2s ease"},children:[h.jsx(xpe,{color:a,size:12}),h.jsx("span",{style:{fontSize:"13px",color:"#64748B",fontWeight:400,lineHeight:1,textDecoration:s?"line-through":"none",transition:"text-decoration 0.15s ease"},children:i})]},i)})})},_pe=({data:e})=>{const t=k.useRef(null),r={labels:Array.isArray(e?.labels)&&e.labels.length>0?e.labels:ype,datasets:[{label:"Guest",data:Array.isArray(e?.guest)&&e.guest.length>0?e.guest:pm.guest,borderColor:"#EF4444",backgroundColor:"rgba(239,68,68,0.15)",pointBackgroundColor:"#EF4444",pointStyle:"rectRot",fill:!1},{label:"Cab",data:Array.isArray(e?.cab)&&e.cab.length>0?e.cab:pm.cab,borderColor:"#7C3AED",backgroundColor:"rgba(124,58,237,0.15)",pointBackgroundColor:"#7C3AED",pointStyle:"rectRot",fill:!1},{label:"Delivery",data:Array.isArray(e?.delivery)&&e.delivery.length>0?e.delivery:pm.delivery,borderColor:"#10B981",backgroundColor:"rgba(16,185,129,0.15)",pointBackgroundColor:"#10B981",pointStyle:"rectRot",fill:!1},{label:"Service",data:Array.isArray(e?.service)&&e.service.length>0?e.service:pm.service,borderColor:"#F59E0B",backgroundColor:"rgba(245,158,11,0.15)",pointBackgroundColor:"#F59E0B",pointStyle:"rectRot",fill:!1}]},i={responsive:!0,maintainAspectRatio:!1,interaction:{mode:"index",intersect:!1},plugins:{legend:{display:!1},tooltip:{enabled:!1,external:ri({titleFormatter:o=>o.title?.[0]||"",hideTitleForSingle:!1})}},scales:{x:{grid:{color:"#F1F5F9"},ticks:{color:"#64748B"}},y:{beginAtZero:!0,suggestedMax:28,grid:{color:"#F1F5F9"},ticks:{color:"#64748B",stepSize:4,precision:0}}},elements:{line:{borderWidth:2,tension:0},point:{radius:0,hoverRadius:3,hitRadius:10}}};return h.jsxs(Le,{title:"Hourly Traffic Flow",className:"w-full h-[362px] gap-[36px]! p-[24px]!",titleClassName:"!text-[20px] !leading-[24px] font-semibold!",children:[h.jsx("div",{style:{height:"calc(100% - 44px)",width:"100%"},children:h.jsx(R1,{ref:t,data:r,options:i})}),h.jsx(wpe,{chartRef:t})]})},Epe={open:4,in_progress:7,closed:12},Spe=[{incident_code:"INC-401",severity_level:"L1",severity:"Danger"},{incident_code:"INC-402",severity_level:"L2",severity:"High"},{incident_code:"INC-403",severity_level:"L3",severity:"Low"}];function Ope({incidentReports:e={},incidentReportsDetails:t=[]}){const n=e&&Object.keys(e).length>0?e:Epe,r=Array.isArray(t)?t:Spe,i=Number(n?.open??0),o=Number(n?.in_progress??0),a=Number(n?.closed??0);return h.jsxs(kt,{title:"Incident Reports",className:"h-[362px] space-y-[24px]!",childrenClassName:"mt-0! h-full",titleClassName:"!text-[20px] !leading-[24px] font-semibold!",children:[h.jsxs("div",{className:"flex w-full text-center gap-[16px]",children:[h.jsxs("div",{className:"flex-1 p-[12px] space-y-[8px]! bg-[#FBF4F4] h-[76px] rounded",children:[h.jsx("div",{className:"!text-[24px] leading-[28px] font-medium text-[#AB0000]",children:i??0}),h.jsx("div",{className:"!text-[12px] leading-[16px] text-[#AB0000]",children:"Open"})]}),h.jsxs("div",{className:"flex-1 p-[12px] space-y-[8px]! bg-[#FFFBF2] h-[76px] rounded",children:[h.jsx("div",{className:"!text-[24px] leading-[28px] font-medium text-[#E7A015]",children:o??0}),h.jsx("div",{className:"!text-[12px] leading-[16px] text-[#E7A015]",children:"In-progress"})]}),h.jsxs("div",{className:"flex-1 p-[12px] space-y-[8px]! bg-[#F7FEFA] h-[76px] rounded",children:[h.jsx("div",{className:"!text-[24px] leading-[28px] font-medium text-[#1FA05B]",children:a??0}),h.jsx("div",{className:"!text-[12px] leading-[16px] text-[#1FA05B]",children:"Closed"})]})]}),h.jsx("div",{className:"h-full space-y-2",children:r?.length?r?.map?.((s,l)=>{const c=s?.severity==="Danger"?"text-[#AB0000]":s?.severity==="High"?"text-[#E7A015]":"text-[#1FA05B]";return h.jsxs("div",{className:"flex items-center justify-between p-[8px] bg-[#FAFBFD] rounded-[4px]!",children:[h.jsx("div",{className:"flex items-center gap-[8px]",children:h.jsx("div",{className:"text-[!121212] font-medium text-[14px]! leading-[18px]!",children:s?.incident_code??"-"})}),h.jsx("div",{className:`!text-[12px] leading-[16px]! font-semibold flex items-center gap-[4px] ${c}`,children:h.jsxs("div",{children:[s?.severity_level??"-"," - ",s?.severity??"-"]})})]},l)}):h.jsx("div",{className:"h-[calc(100%-116px)] flex flex-1 justify-center items-center text-center text-[#64748B] text-[12px] ",children:"No incidents found"})})]})}const Cpe=[{total_staff:42,absent_staff:6}],kpe=[{staff_role_name:"Security Guard",total_staff:18,present_staff:16},{staff_role_name:"Supervisor",total_staff:8,present_staff:7},{staff_role_name:"Technician",total_staff:10,present_staff:9},{staff_role_name:"Technician",total_staff:10,present_staff:9}];function $4({staffPresentAbsent:e,staffPresentByRole:t}){const n=Array.isArray(e)&&e.length>0?e:Cpe,r=Array.isArray(t)&&t.length>0?t:kpe,i=n?.[0]?.total_staff??0,o=n?.[0]?.absent_staff??0,a=(i??0)-(o??0);return h.jsx(kt,{title:"Staff Attendance",className:"h-[362px] overflow-hidden",titleClassName:"!text-[20px] !leading-[24px] font-semibold!",children:h.jsxs("div",{children:[h.jsxs("div",{className:"flex gap-[16px] text-center mt-[24px]",children:[h.jsxs("div",{className:"flex-1 p-[12px] space-y-[8px]! bg-[#F7FEFA] rounded",children:[h.jsx("div",{className:"text-[24px] leading-[28px] font-medium text-[#1FA05B]",children:a??0}),h.jsx("div",{className:"text-[12px] leading-[16px] text-[#1FA05B]",children:"Present"})]}),h.jsxs("div",{className:"flex-1 p-[12px] space-y-[8px]! bg-[#FBF4F4] rounded h-[76px]",children:[h.jsx("div",{className:"text-[24px] leading-[28px] font-medium text-[#AB0000]",children:o??0}),h.jsx("div",{className:"text-[12px] leading-[16px] text-[#AB0000]",children:"Absent"})]})]}),h.jsx("div",{className:"mt-[24px] pb-[16px] space-y-[12px] overflow-y-auto max-h-[200px] hide-scrollbar",children:r?.length?r?.map?.((s,l)=>{const c=Number(s?.total_staff??0),u=Number(s?.present_staff??0);return h.jsxs("div",{className:"flex items-center justify-between p-[12px] bg-[#F8FAFC] rounded-md",children:[h.jsx("div",{className:"text-[#121212] text-[14px] leading-[18px] font-medium",children:s?.staff_role_name??"-"}),h.jsxs("div",{className:"text-[14px] leading-[20px] text-[#64748B]",children:[u??0,"/",c??0]})]},l)}):h.jsx(h.Fragment,{})})]})})}function Ppe(e){return gt({attr:{viewBox:"0 0 256 256",fill:"currentColor"},child:[{tag:"path",attr:{d:"M116,132V96a12,12,0,0,1,24,0v36a12,12,0,0,1-24,0Zm12,56a16,16,0,1,0-16-16A16,16,0,0,0,128,188ZM228,56v56c0,54.29-26.32,87.22-48.4,105.29-23.71,19.39-47.44,26-48.44,26.29a12.1,12.1,0,0,1-6.32,0c-1-.28-24.73-6.9-48.44-26.29C54.32,199.22,28,166.29,28,112V56A20,20,0,0,1,48,36H208A20,20,0,0,1,228,56Zm-24,4H52v52c0,35.71,13.09,64.69,38.91,86.15A126.14,126.14,0,0,0,128,219.38a126.28,126.28,0,0,0,37.09-21.23C190.91,176.69,204,147.71,204,112Z"},child:[]}]})(e)}function Dpe({title:e,value:t,delta:n,deltaLabel:r,positive:i=!0,Icon:o=Ld,iconColor:a="text-emerald-600",iconBg:s="bg-emerald-50"}){return h.jsxs(Le,{title:e,icon:h.jsx("div",{className:"size-[20px] grid place-items-center",children:h.jsx(o,{className:`size-[20px] ${a}`})}),titleClassName:"!text-[#64748B] !leading-[20px] tracking-[-2%]",childrenClassName:"!space-y-[8px]",children:[h.jsx("div",{className:"!text-[28px] !leading-[32px] font-semibold tracking-tight text-[#121212]",children:t}),h.jsxs("div",{className:"flex items-center gap-[4px] leading-[16px] text-[12px]",children:[h.jsx("div",{className:`
|
|
479
479
|
${i?"bg-[#F7FEFA] text-[#1FA05B]":"bg-[#FBF4F4] text-[#EF4444]"} p-[4px] rounded-[4px] font-medium
|
|
480
|
-
`,children:n}),h.jsx("div",{className:"!text-[#64748B]",children:r})]})]})}const Ape=[{title:"Total Visitors",value:160,delta:"+11.0%",deltaLabel:"Compared to last month",positive:!0,Icon:Ng,iconColor:"text-[#329DFF]"},{title:"Active Incidents",value:73,delta:"+2.0%",deltaLabel:"Compared to last month",positive:!0,Icon:Zae,iconColor:"text-[#F69E0A]"},{title:"Missed Patrols",value:3,delta:"+11.0%",deltaLabel:"Compared to last month",positive:!0,Icon:Ppe,iconColor:"text-[#AB0000]"},{title:"Parking Usage",value:5,delta:"-8.0%",deltaLabel:"Compared to last month",positive:!1,Icon:F8,iconColor:"text-[#36AB6C]"}];function Tpe({data:e}){const t=Array.isArray(e)&&e.length>0?e:Ape;return h.jsx("div",{className:"px-[20px] grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-4 gap-[24px]",children:t.map((n,r)=>h.jsx(Dpe,{...n},r))})}const Npe=[{title:"Maintenance",total:12,pending:3},{title:"Security",total:8,pending:1},{title:"Housekeeping",total:6,pending:2},{title:"Utilities",total:10,pending:4}],jpe=(e="")=>e.replace(/</g,"<").replace(/>/g,">").replace(/<[^>]*>/g,"").trim();function Mpe({data:e}){const t=Array.isArray(e?.complaints_by_category)&&e.complaints_by_category.length>0?e.complaints_by_category.map(n=>({title:jpe(n.category_name)||"—",total:n.total||0,pending:n.pending||0})):Npe;return h.jsx(Le,{title:"Complaints",titleClassName:"!text-[20px] !leading-[24px] font-semibold!",className:"w-full h-[362px] p-[24px]!",children:h.jsx("div",{className:"flex flex-col gap-[12px] max-h-full overflow-y-auto hide-scrollbar",children:t.map((n,r)=>h.jsxs("div",{className:"flex items-center justify-between bg-[#F8FAFC] rounded-[4px] p-[12px]",children:[h.jsxs("div",{className:"flex flex-col gap-[4px]",children:[h.jsx("div",{className:"text-[14px] leading-[18px] font-medium text-[#121212] capitalize",children:n.title}),h.jsxs("div",{className:"text-[12px] leading-[16px] text-[#64748B]",children:["Total: ",n.total]})]}),h.jsxs("div",{className:"flex flex-col items-end gap-[4px]",children:[h.jsx("div",{className:"text-[14px] leading-[18px] font-medium text-[#AB0000]",children:String(n.pending).padStart(2,"0")}),h.jsx("div",{className:"text-[12px] leading-[16px] text-[#64748B]",children:"Pending"})]})]},r))})})}const Ipe=[{level:"Level 1",open_count:3,in_progress_count:4,closed_count:5,total:12},{level:"Level 2",open_count:1,in_progress_count:1,closed_count:1,total:3},{level:"Level 3",open_count:5,in_progress_count:2,closed_count:3,total:10}],Fpe=()=>{const e=[{label:"Open",color:"#EF4444"},{label:"In Progress",color:"#F59D0D"},{label:"Closed",color:"#12B981"}];return h.jsx("div",{style:{display:"flex",justifyContent:"space-between",gap:"15px"},children:e.map(t=>h.jsxs("div",{style:{display:"flex",alignItems:"center",gap:"6px"},children:[h.jsx("div",{style:{width:"6px",height:"6px",backgroundColor:t.color,transform:"rotate(45deg)"}}),h.jsx("span",{style:{fontSize:"14px"},children:t.label})]},t.label))})},Lpe=({data:e})=>{const t=k.useMemo(()=>(Array.isArray(e?.complaints_by_level)&&e.complaints_by_level.some(l=>Number(l.total)>0)?e.complaints_by_level:Ipe).map(l=>({level:l.level||"—",open_count:Number(l.open_count)||0,in_progress_count:Number(l.in_progress_count)||0,closed_count:Number(l.closed_count)||0,total:Number(l.total)||0})),[e]),n=k.useMemo(()=>Math.max(...t.map(a=>a.total),5),[t]),r=Math.ceil(n*1.2),i=6,o=Math.max(Math.ceil(n/i),1);return h.jsxs(Le,{title:"Complaints by Level",className:"w-full h-[362px] p-[24px]! gap-[18px]!",titleClassName:"!text-[20px] !leading-[24px] font-semibold!",children:[h.jsx(Ot,{width:"100%",height:"85%",children:h.jsxs(ko,{data:t,margin:{top:5,right:-25,left:-30,bottom:5},children:[h.jsx(sr,{strokeDasharray:"0",vertical:!1}),h.jsx(Gn,{dataKey:"level"}),h.jsx(Rn,{domain:[0,r],ticks:Array.from({length:i+1},(a,s)=>s*o)}),h.jsx(St,{cursor:{fill:"rgba(148, 163, 184, 0.12)"},allowEscapeViewBox:{x:!0,y:!0},content:a=>!a.active||!a.payload||!a.payload.length?null:h.jsx(Ut,{...a,data:t,children:h.jsxs("div",{className:"bg-[#121212] rounded-[10px] px-[14px] py-[10px] text-[12px] text-white",children:[h.jsx("div",{className:"mb-[6px] font-semibold",children:a.label}),a.payload.map((s,l)=>{const c=s.color||s.fill||"#fff";return h.jsxs("div",{className:"flex items-center gap-[6px]",children:[h.jsx("span",{className:"w-2 h-2 rounded-full inline-block",style:{backgroundColor:c}}),h.jsx("span",{className:"text-[#D1D3D4]",children:s.name}),h.jsx("span",{className:"text-white font-semibold",children:s.value})]},l)})]})})}),h.jsx(Gt,{dataKey:"open_count",name:"Open",stackId:"a",fill:"#EF4444",barSize:44,radius:[0,0,0,0]}),h.jsx(Gt,{dataKey:"in_progress_count",name:"In Progress",stackId:"a",fill:"#F59D0D",barSize:44,radius:[0,0,0,0]}),h.jsx(Gt,{dataKey:"closed_count",name:"Closed",stackId:"a",fill:"#12B981",barSize:44,radius:[0,0,0,0]})]})}),h.jsx(Fpe,{})]})},Rpe=[{title:"Maintenance",total:18,pending:4},{title:"Security",total:11,pending:2},{title:"Housekeeping",total:9,pending:3},{title:"Utilities",total:14,pending:5}];function $pe({data:e}){const t=Array.isArray(e?.request_box_by_type)&&e.request_box_by_type.length>0?e.request_box_by_type.map(n=>({title:n.category_name||"—",total:Number(n.total)||0,pending:Number(n.pending)||0})):Rpe;return h.jsx(Le,{title:"Request Box",titleClassName:"!text-[20px] !leading-[24px] font-semibold!",className:"w-full h-[362px] p-[24px]!",children:h.jsx("div",{className:"flex flex-col gap-[12px] max-h-full overflow-y-auto hide-scrollbar",children:t.map((n,r)=>h.jsxs("div",{className:"flex items-center justify-between bg-[#F8FAFC] rounded-[4px] p-[12px]",children:[h.jsxs("div",{className:"flex flex-col gap-[4px]",children:[h.jsx("div",{className:"text-[14px] leading-[18px] font-medium text-[#121212] capitalize",children:n.title}),h.jsxs("div",{className:"text-[12px] leading-[16px] text-[#64748B]",children:["Total: ",n.total]})]}),h.jsxs("div",{className:"flex flex-col items-end gap-[4px]",children:[h.jsx("div",{className:"text-[14px] leading-[18px] font-medium text-[#AB0000]",children:String(n.pending).padStart(2,"0")}),h.jsx("div",{className:"text-[12px] leading-[16px] text-[#64748B]",children:"Pending"})]})]},`${n.title}-${r}`))})})}function Bpe(e){return gt({attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{fill:"none",strokeLinejoin:"round",strokeWidth:"32",d:"M416 221.25V416a48 48 0 0 1-48 48H144a48 48 0 0 1-48-48V96a48 48 0 0 1 48-48h98.75a32 32 0 0 1 22.62 9.37l141.26 141.26a32 32 0 0 1 9.37 22.62z"},child:[]},{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"32",d:"M256 56v120a32 32 0 0 0 32 32h120m-232 80h160m-160 80h160"},child:[]}]})(e)}const Wpe=["open_complaints","pending_requests","avg_response_time","resolution_rate"],zpe={open_complaints:{title:"Open Complaints",Icon:lS,iconColor:"#AB0000",deltaLabel:"Compared to last month"},pending_requests:{title:"Pending Requests",Icon:Bpe,iconColor:"#E7A015",deltaLabel:"Compared to last month"},avg_response_time:{title:"Avg Response Time",Icon:V8,iconColor:"#1FA05B",deltaLabel:"Compared to last month"},resolution_rate:{title:"Resolution Rate",Icon:W8,iconColor:"#329DFF",deltaLabel:"Compared to last month"}},Vpe=({children:e,size:t=28,lineHeight:n=32,weight:r=500,color:i="#121212"})=>h.jsx("div",{style:{fontWeight:r,fontSize:`${t}px`,lineHeight:`${n}px`,color:i},children:e}),Hpe={primary:{size:28,lineHeight:32,weight:500}},Ype={open_complaints:{current:24,trend_percent:"-8%",direction:"bad"},pending_requests:{current:17,trend_percent:"-5%",direction:"bad"},avg_response_time:{current:"2.4 h",trend_percent:"+6%",direction:"good"},resolution_rate:{current:"89%",trend_percent:"+4%",direction:"good"}};function Upe({id:e,data:t}){return e&&t&&!t[e]&&t.current!==void 0?h.jsx(B4,{id:e,data:t}):h.jsx("div",{className:"px-[20px] grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-4 gap-[16px]",children:Wpe.map(n=>h.jsx(B4,{id:n},n))})}function B4({id:e,data:t}){const n=zpe[e];if(!n)return null;const r=(d,f)=>f==null?"—":d==="avg_response_time"?typeof f=="number"?`${f} h`:f:d==="resolution_rate"&&typeof f=="number"?`${f}%`:f,{title:i,Icon:o=Ld,iconColor:a,deltaLabel:s}=n,l=t&&Object.keys(t).length>0?t:Ype[e],c=r(e,l?.current),u=l?.trend_percent??"—";return l?.direction==="good"||l?.direction,h.jsx("div",{className:"h-[132px]",children:h.jsxs(Le,{title:i,titleColor:a,icon:h.jsx("div",{className:"h-[20px] w-[20px] flex items-center justify-center",children:h.jsx(o,{className:"h-[20px] w-[20px]",style:{color:a}})}),childrenClassName:"!space-y-[12px]",iconClassName:"!gap-[12px]",children:[h.jsx(Vpe,{...Hpe.primary,children:c}),h.jsxs("div",{className:"flex items-center gap-[8px] text-[12px] leading-[16px]",children:[h.jsx(Tc,{value:u}),h.jsx("div",{className:"text-[#64748B] text-[12px] leading-[16px]",children:s})]})]})})}const Kpe=[{title:"Holi Celebration",date:"25 Jun 2025",rsvp:"78/100",utilisation:71,status:"Upcoming"},{title:"Maintenance Meeting",date:"25 Jun 2025",rsvp:"45/60",utilisation:75,status:"Completed"},{title:"Maintenance Meeting",date:"25 Jun 2025",rsvp:"45/60",utilisation:75,status:"Completed"},{title:"Maintenance Meeting",date:"25 Jun 2025",rsvp:"45/60",utilisation:75,status:"Completed"}];function qpe({title:e,date:t,rsvp:n,utilisation:r,status:i}){return h.jsxs("div",{className:"bg-[#F8FAFC] p-[12px] rounded-[4px]",children:[h.jsxs("div",{className:"flex items-center justify-between",children:[h.jsx("div",{className:"text-[16px] leading-[20px] font-semibold text-[#121212]",children:e}),h.jsx("div",{className:`!text-[12px] leading-[16px] font-medium p-[4px] rounded-[4px] ${i==="Completed"?"text-[#36AB6C] bg-[#E6F7EE]":i==="Upcoming"?"text-[#329DFF] bg-[#E6F2FF]":"text-slate-500 bg-slate-100"}`,children:i})]}),h.jsx("div",{className:"text-[14px] leading-[18px] text-[#64748B]",children:t}),h.jsxs("div",{className:"mt-[8px] flex justify-between items-center",children:[h.jsxs("div",{className:"text-[14px] leading-[18px] text-[#64748B]",children:[n," RSVP"]}),h.jsxs("div",{className:"text-[#3C82F6] text-[14px] leading-[18px] font-medium",children:[r,"% utilisation"]})]}),h.jsx("div",{className:"mt-[8px] w-full bg-[#F8FAFC] h-[6px] rounded",children:h.jsx("div",{className:"h-[6px] rounded bg-[#3C82F6]",style:{width:`${r}%`}})})]})}function Gpe({data:e}){const t=Array.isArray(e)&&e.length===0,n=Array.isArray(e)?e:Kpe;return h.jsx(Le,{title:"Events Utilisation",className:"w-full h-[360px] p-[24px]!",childrenClassName:t?"h-full":"overflow-y-auto hide-scrollbar",titleClassName:"!text-[20px] !leading-[24px] font-semibold!",children:h.jsx("div",{className:`w-full h-full ${t?"flex items-center justify-center":"space-y-[12px]"}`,children:n?.length>0?n.map((r,i)=>h.jsx(qpe,{...r},`${r.title}-${i}`)):h.jsx(Vt,{})})})}const Xpe=[{label:"Active",value:138,subLabel:"3 expiring soon",bgColor:"bg-[#F0FFF7]",textColor:"text-[#1FA05B]"},{label:"Scheduled",value:13,subLabel:"4 this week",bgColor:"bg-[#FFFBF2]",textColor:"text-[#E7A015]"},{label:"Recurring",value:3,subLabel:"All active",bgColor:"bg-[#EDF6FF]",textColor:"text-[#329DFF]"},{label:"Expired",value:7,subLabel:"4 recent",bgColor:"bg-[#F6F6F6]",textColor:"text-[#64748B]"}];function Qpe({label:e,value:t,subLabel:n,bgColor:r,textColor:i}){return h.jsxs("div",{className:`border-[0.5px] border-[#EBEBEB] rounded-[12px] p-[16px] ${r} h-[124px]`,children:[h.jsx("div",{className:`text-[16px] leading-[20px]! tracking-[-2%] font-medium ${i}`,children:e}),h.jsx("div",{className:"mt-[16px] text-[28px] leading-[32px] font-semibold text-[#121212]",children:t}),h.jsx("div",{className:"mt-[8px] !text-[12px] leading-[16px] text-[#64748B]",children:n})]})}function Zpe({data:e}){const t=Array.isArray(e)&&e.length>0?e:Xpe;return h.jsx(Le,{title:"Notice Board Status",className:"w-full h-[360px] !p-[24px]",titleClassName:"!text-[20px] !leading-[24px] font-semibold!",children:h.jsx("div",{className:"grid grid-cols-2 gap-[24px]",children:t.map((n,r)=>h.jsx(Qpe,{...n},`${n.label}-${r}`))})})}function Jpe({title:e,value:t,delta:n,deltaLabel:r,positive:i=!0,Icon:o=Ld,iconColor:a="text-emerald-600",iconBg:s="bg-emerald-50",iconUrl:l}){return h.jsx(Le,{title:e,icon:h.jsx("div",{className:"grid place-items-center ",children:l?h.jsx("img",{src:l,alt:"icon",className:"h-8 w-8 object-contain"}):h.jsx(o,{className:`h-8 w-8 ${a}`})}),className:"h-[132px]",children:h.jsxs("div",{children:[h.jsx("div",{className:"text-[28px] leading-[32px] font-medium text-[#121212]",children:t}),h.jsxs("div",{className:"flex items-center gap-[8px] pt-[8px] !text-[12px] leading-[16px]",children:[h.jsx(Tc,{value:n}),h.jsx("div",{className:"text-[#64748B]",children:r})]})]})})}function ehe({data:e}){const t=[{title:e?.title||"Total Bookings",value:e?.value??0,delta:e?.delta??"0%",deltaLabel:e?.deltaLabel||"Compared to last month",positive:e?.positive??!1,Icon:e?.Icon,iconUrl:e?.iconUrl,iconColor:e?.iconColor||"text-emerald-600",iconBg:e?.iconBg||"bg-emerald-50"}];return h.jsx("div",{className:"h-full",children:t.map((n,r)=>h.jsx(Jpe,{...n},r))})}function the({title:e,value:t,delta:n,deltaLabel:r,positive:i=!0,icon:o,iconColor:a="text-emerald-600",iconBg:s="bg-emerald-50"}){return h.jsxs(Le,{title:e,icon:h.jsx("div",{className:"size-[20px] grid place-items-center",children:h.jsx("img",{src:o,alt:e})}),className:"h-[132px]",titleClassName:"text-[#64748B]! leading-[20px]",childrenClassName:"space-y-[8px]!",children:[h.jsx("div",{className:"text-[28px] leading-[32px] font-medium text-[#121212]",children:t}),h.jsxs("div",{className:"flex items-center gap-[8px] text-[12px] leading-[16px]",children:[h.jsx(Tc,{value:n}),h.jsx("div",{className:"text-[#64748B] text-[12px] leading-[16px]",children:r})]})]})}const nhe=[{title:"Notice",value:160,delta:"+11.0%",deltaLabel:"Compared to last month",positive:!0,icon:"https://res.cloudinary.com/dzqlw1ixr/image/upload/v1773902569/notice_djcorh.svg"},{title:"Post",value:83,delta:"+2.0%",deltaLabel:"Compared to last month",positive:!0,icon:"https://res.cloudinary.com/dzqlw1ixr/image/upload/v1773902568/post_rivboo.svg"},{title:"Poll",value:3,delta:"+11.0%",deltaLabel:"Compared to last month",positive:!0,icon:"https://res.cloudinary.com/dzqlw1ixr/image/upload/v1773902569/poll_b43jo0.svg"},{title:"Survey",value:5,delta:"-8.0%",deltaLabel:"Compared to last month",positive:!1,icon:"https://res.cloudinary.com/dzqlw1ixr/image/upload/v1773902568/survey_yevzwi.svg"}];function rhe({data:e}){const t=Array.isArray(e)&&e.length>0?e:nhe;return h.jsx("div",{className:"px-[20px] grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-4 gap-[24px]",children:t.map((n,r)=>h.jsx(the,{...n},r))})}const W4=({value:e=0,total:t=1,colorClass:n="",label:r=""})=>{const i=Number(e)||0,o=Number(t)||1,a=Math.max(0,Math.min(100,i/o*100)),s=n==="bg-[#3C81F6]"?"text-[#8B5CF6]":n==="bg-[#8B5CF6]"?"text-[#12B981]":"text-slate-600";return h.jsxs("div",{className:"flex flex-col items-start",children:[h.jsx("div",{className:"w-2/3 min-w-[80px] h-5 rounded-full overflow-hidden",children:h.jsx("div",{className:`h-[11px] rounded-full ${n||""}`,style:{width:n==="bg-[#12B981]"?`${a+45}%`:`${a}%`}})}),h.jsx("div",{className:`${s} !text-[12px] font-bold mt-1`,children:i??0}),h.jsx("div",{className:"!text-[12px] leading-[16px] text-[#64748B] mt-1",children:r??""})]})},z4=({data:e,occupiedUnits:t=1,EmployeesCount:n=8910,AdminsCount:r=910})=>{const i=e?.total_occupants!==void 0&&e?.total_occupants!==null?Number(e?.total_occupants)||0:Number(t)||0,o=e?.total_members!==void 0&&e?.total_members!==null?Number(e?.total_members)||0:Number(n)||0,a=e?.total_admins!==void 0&&e?.total_admins!==null?Number(e?.total_admins)||0:Number(r)||0,s=(o||0)+(a||0);return h.jsx("div",{children:h.jsxs("div",{className:"bg-white !border-[0.5px] !border-[#EBEBEB] rounded-[12px] shadow-[0_0_12px_0_#EAF2FF] p-[16px] h-[128px]",children:[h.jsxs("div",{className:"flex items-center gap-[12px] h-[20px]",style:{marginBottom:"24px"},children:[h.jsx(Ng,{className:"!text-[20px] text-[#329DFF]"}),h.jsx("div",{className:"font-medium text-[#121212] text-[16px] leading-[20px]",children:"Occupancy Overview"})]}),h.jsxs("div",{className:"flex items-start justify-between",children:[h.jsxs("div",{className:"flex flex-col gap-[4px]",children:[h.jsx("div",{className:"text-[12px] leading-[16px] text-[#64748B] font-normal",children:"Total Occupants"}),h.jsx("div",{className:"text-[28px] leading-[32px] font-medium text-[#121212]",children:i??0})]}),h.jsxs("div",{className:"flex items-end gap-[4px]",children:[h.jsx(W4,{value:o??0,total:s||1,colorClass:"bg-[#3C81F6]",label:(o??0)<=1?"Employee":"Employees"}),h.jsx(W4,{value:a??0,total:s||1,colorClass:"bg-[#8B5CF6]",label:(a??0)<=1?"Admin":"Admins"})]})]})]})})};Bn.register(Fo,Lo,Wl,Ar);const V4=({data:e})=>{const t=e!=null,n=e?.employee_data,r=["HP","Adobe","Anarock","Swiggy","Infosys","Zepto"],i=[2e3,1700,1500,1200,900,800],o=[],a=[];if(t){if(n&&n.length>0)for(let d=0;d<n.length;d++)o.push(n[d].name),a.push(n[d].employees)}else for(let d=0;d<r.length;d++)o.push(r[d]),a.push(i[d]);let s=!1;if(t)if(!n||n.length===0)s=!0;else{s=!0;for(let d=0;d<n.length;d++)if(n[d].employees!==0){s=!1;break}}let l=0;for(let d=0;d<a.length;d++)a[d]>l&&(l=a[d]);const c={labels:o,datasets:[{data:a,backgroundColor:[],barThickness:34}]};for(let d=0;d<a.length;d++)c.datasets[0].backgroundColor.push("#3C81F6");const u={responsive:!0,maintainAspectRatio:!1,plugins:{legend:{display:!1},tooltip:{backgroundColor:"#0F172A",titleColor:"#fff",bodyColor:"#fff",displayColors:!1,callbacks:{label:d=>`Employees: ${d.parsed.y}`}}},scales:{x:{grid:{display:!1},ticks:{color:"#64748B",font:{size:12}}},y:{beginAtZero:!0,min:0,max:l>0?l+5:2e3,ticks:{stepSize:l>0?Math.ceil((l+5)/5):500,color:"#64748B",callback:d=>d},grid:{display:!1,color:"#E5E7EB",borderDash:[4,4],drawBorder:!1}}}};return t&&s?h.jsx(Le,{className:"w-full h-[238px]",title:"Employee Footfall",period:"Today",icon:h.jsx(I4,{className:"!text-[24px] text-[#8B5CF6]"}),children:h.jsx("div",{className:"h-full flex items-center justify-center",children:h.jsx(Vt,{title:"No Employee footfall Found",description:"Catch up all the data. Change the date range to see the data."})})}):h.jsxs(Le,{className:"w-full h-[238px]",title:"Employee Footfall",period:"Today",icon:h.jsx(I4,{className:"!text-[24px] text-[#8B5CF6]"}),children:[h.jsxs("div",{className:"mb-[10px] mt-[8px] flex flex-col gap-[4px]!",children:[h.jsx("div",{className:"text-[12px] leading-[16px] text-[#64748B]",children:"Employees Inside"}),h.jsx("div",{className:"text-[20px] leading-[24px] font-medium text-[#3C81F6]",children:t?e.total_employees:7500})]}),h.jsx("div",{className:"h-[110px]",children:h.jsx(zl,{data:c,options:u})})]})},ihe="Rs",H4=["bg-blue-500","bg-red-500","bg-purple-700"],bs={title:"Food & Beverages (Static Data)",period:"Today",summary:{totalOrders:247,revenueGenerated:"82K",growthPercentage:8,growthTotalPercentage:0},outlets:[{name:"HP",orders:120,revenue:"45K",percentage:70,color:"bg-[#3C81F6]"},{name:"Adobe",orders:85,revenue:"23K",percentage:50,color:"bg-[#3C81F6]"},{name:"Anarock",orders:42,revenue:"14K",percentage:25,color:"bg-[#3C81F6]"}]};function hm(e,t=null){if(typeof e=="number")return e;if(typeof e=="string"){const n=Number(e.replace("%","").trim());return Number.isNaN(n)?t:n}return t}function Y4(e){if(e==null||e==="")return"0";if(typeof e=="number")return t2(e);const t=Number(e);return Number.isNaN(t)?String(e):t2(t)}function ohe(e){const t=e?.food_beverage_summary?{title:e?.title,period:e?.period,summary:{totalOrders:e?.food_beverage_summary?.total_orders,revenueGenerated:e?.food_beverage_summary?.revenue_generated,growthPercentage:e?.food_beverage_summary?.growth_percentage??e?.food_beverage_summary?.revenue_growth,growthTotalPercentage:e?.food_beverage_summary?.order_growth,currencyType:e?.food_beverage_summary?.currency_type},outlets:e?.chart_data}:e||{},n=t?.summary||{},i=(Array.isArray(t?.outlets)?t.outlets:[]).map((f,p)=>({name:f?.name||f?.outlet_name||f?.tenant_name||f?.company_name||"Unknown",orders:f?.orders??f?.total_orders??f?.count??0,revenue:f?.revenue??f?.revenue_generated??f?.total_revenue??0,percentage:f?.percentage,color:f?.color||H4[p%H4.length]})),o=n?.totalOrders??n?.orders??bs.summary.totalOrders,a=n?.revenueGenerated??n?.revenue??bs.summary.revenueGenerated,s=hm(n?.growthPercentage??n?.revenueGrowth,bs.summary.growthPercentage),l=hm(n?.growthTotalPercentage??n?.orderGrowth,bs.summary.growthTotalPercentage),c=n?.currencyType||n?.currency||ihe,u=i.reduce((f,p)=>f+(Number(p?.orders)||0),0),d=i.map(f=>({...f,percentage:f?.percentage!==null&&f?.percentage!==void 0?Number(f.percentage)||0:u>0?Math.round((Number(f?.orders)||0)/u*100):0}));return{title:t?.title||bs.title,period:t?.period||bs.period,summary:{totalOrders:o,revenueGenerated:a,growthPercentage:s,growthTotalPercentage:l,currencyType:c},outlets:d.length>0?d:bs.outlets}}function U4({data:e,title:t,period:n,icon:r}){const i=ohe(e),o=t||i.title,a=n||i.period,s=r||h.jsx(dpe,{className:"!text-[24px] text-[#FA7E28]"}),l=i.summary.totalOrders??0,c=Y4(i.summary.revenueGenerated),u=hm(i.summary.growthPercentage,0),d=hm(i.summary.growthTotalPercentage,0),f=u>=0,p=d>=0;return h.jsx(Le,{className:"h-[324px]",title:o,period:a,icon:s,children:h.jsxs("div",{className:"flex flex-col h-full",children:[h.jsxs("div",{className:"flex gap-[24px]",children:[h.jsxs("div",{className:"w-full flex flex-col gap-[8px]!",children:[h.jsx("div",{className:"text-[12px] leading-[16px] text-[#64748B]",children:"Total Orders"}),h.jsx("div",{className:"text-[28px] leading-[32px] font-medium text-[#8B5CF6]",children:l}),h.jsxs("div",{className:`w-fit inline-flex items-center gap-[4px] text-[10px] leading-[14px] p-[4px] rounded-[4px] ${p?"text-[#1FA05B] bg-green-50":"text-red-600 bg-red-50"}`,children:[p?h.jsx(Xo,{}):h.jsx(Go,{}),d,"%",h.jsx("span",{children:"from last month"})]})]}),h.jsx("div",{className:"w-full flex justify-end",children:h.jsxs("div",{className:"flex flex-col gap-[8px]",children:[h.jsx("div",{className:"text-[12px] leading-[16px] text-[#64748B] whitespace-nowrap",children:"Revenue Generated"}),h.jsxs("div",{className:"text-[28px] leading-[32px] font-medium text-[#329DFF] whitespace-nowrap",children:[i.summary.currencyType," ",c]}),h.jsxs("div",{className:`w-fit inline-flex items-center gap-[4px] text-[10px] leading-[14px] p-[4px] rounded-[4px] whitespace-nowrap ${f?"text-[#1FA05B] bg-green-50":"text-red-600 bg-red-50"}`,children:[f?h.jsx(Xo,{}):h.jsx(Go,{}),u,"%",h.jsx("span",{children:"from last month"})]})]})})]}),h.jsx("div",{className:"mt-[16px]",children:i.outlets.map((m,g)=>h.jsxs("div",{className:g===i.outlets.length-1?"":"mb-[16px]",children:[h.jsxs("div",{className:"flex justify-between text-sm mb-[8px]",children:[h.jsx("div",{className:"text-[#64748B] text-[12px] leading-[16px]",children:m.name}),h.jsxs("div",{className:"font-medium text-[12px] leading-[16px] flex items-center",children:[h.jsxs("div",{className:"text-[#64748B] inline-block",children:[m.orders," orders"]}),h.jsxs("div",{className:"mx-2 text-[#121212] inline-block",children:[i.summary.currencyType," ",Y4(m.revenue)]})]})]}),h.jsx("div",{className:"h-[11px] bg-gray-100 rounded-full",children:h.jsx("div",{className:`h-[11px] rounded-full ${m.color}`,style:{width:`${m.percentage}%`}})})]},`${m.name}-${g}`))})]})})}function K4({data:e}){const t=e?.amenity_summary?{amenitySummary:{totalBookings:e?.amenity_summary?.total_bookings??0,todayPaidRevenue:e?.amenity_summary?.today_paid_revenue??"0.00",growthPercentage:e?.amenity_summary?.growth_percentage??null,bookingGrowth:e?.amenity_summary?.booking_growth??null,currencyType:e?.amenity_summary?.currency_type??"Rs"},chartData:Array.isArray(e?.chart_data)?e.chart_data.map(m=>({facility_name:m?.facility_name,total_bookings:m?.total_bookings??0,paid_revenue:m?.paid_revenue??"0",isPaid:m?.is_paid===!0})):[]}:e||{},n=t?.amenitySummary||{},i=(Array.isArray(t?.chartData)?t.chartData:[]).map(m=>({...m,isPaid:m?.isPaid===!0})),o=i.length>0&&i.every(m=>m?.isPaid===!1),a=n?.totalBookings||0,s=n?.bookingGrowth;let l=0;if(typeof s=="number")l=s;else if(typeof s=="string"){const m=s.replace("%","").trim(),g=Number(m);l=isNaN(g)?0:g}const c=i.reduce((m,g)=>{const v=g?.total_bookings||0;return m+v},0),u=i.map(m=>{const g=m?.total_bookings||0,v=m?.isPaid?`${n?.currencyType||"Rs"} ${m?.paid_revenue||"0.00"}`:"",x=c>0?Math.round(g/c*100):0;return{name:m?.facility_name||"Unknown",bookings:g,revenue:v,percentage:x,color:"bg-[#3C81F6]",isPaid:m?.isPaid}}),d=n?.growthPercentage;let f=null;if(typeof d=="number")f=d;else if(typeof d=="string"){const m=d.replace("%","").trim(),g=Number(m);f=isNaN(g)?null:g}const p=f!==null?f>=0:!0;return h.jsx(Le,{className:"h-[324px]",title:"Amenities",period:"Today",icon:h.jsx(fpe,{className:"!text-[24px] text-[#8B5CF6]"}),children:h.jsxs("div",{className:"flex flex-col h-full",children:[h.jsxs("div",{className:"flex gap-[24px]",children:[h.jsxs("div",{className:"w-full flex flex-col gap-[8px]!",children:[h.jsx("div",{className:"text-[12px] leading-[16px] text-[#64748B]",children:"Total Bookings"}),h.jsx("div",{className:"text-[28px] leading-[32px] font-medium text-[#8B5CF6]",children:a}),h.jsxs("div",{className:`w-fit inline-flex items-center gap-[4px] text-[10px] leading-[14px] p-[4px] rounded-[4px] ${l>=0?"text-[#1FA05B] bg-green-50":"text-red-600 bg-red-50"}`,children:[l>=0?h.jsx(Xo,{}):h.jsx(Go,{}),l,"%",h.jsx("span",{children:"from last month"})]})]}),!o&&h.jsx("div",{className:"w-full flex justify-end",children:h.jsxs("div",{className:"flex flex-col gap-[8px]",children:[h.jsx("div",{className:"text-[12px] leading-[16px] text-[#64748B] whitespace-nowrap",children:"Revenue Generated"}),h.jsxs("div",{className:"text-[28px] leading-[32px] font-medium text-[#329DFF] whitespace-nowrap",children:[n?.currencyType||"Rs"," ",n?.todayPaidRevenue??"0.00"]}),f!==null&&h.jsxs("div",{className:`w-fit inline-flex items-center gap-[4px] text-[10px] leading-[14px] p-[4px] rounded-[4px] whitespace-nowrap ${p?"text-[#1FA05B] bg-green-50":"text-red-600 bg-red-50"}`,children:[p?h.jsx(Xo,{}):h.jsx(Go,{}),f,"%",h.jsx("span",{children:"from last month"})]})]})})]}),h.jsx("div",{className:"mt-[16px]",children:u.length>0?u.map((m,g)=>h.jsxs("div",{className:g===u.length-1?"":"mb-[16px]",children:[h.jsxs("div",{className:"flex justify-between text-sm mb-[8px]",children:[h.jsx("div",{className:"text-[#64748B] text-[12px] leading-[16px]",children:m?.name}),h.jsxs("div",{className:"font-medium text-[12px] leading-[16px]",children:[h.jsxs("div",{className:"text-[#64748B] inline",children:[m?.bookings," ",m?.bookings<=1?"booking":"bookings"]}),m?.isPaid&&h.jsx("div",{className:"mx-2 text-[#121212] inline",children:m?.revenue})]})]}),h.jsx("div",{className:"h-[11px] bg-gray-100 rounded-full",children:h.jsx("div",{className:`h-[11px] rounded-full ${m?.color}`,style:{width:`${m?.percentage}%`}})})]},g)):h.jsx("div",{className:"flex items-center justify-center h-[120px]",children:h.jsx("div",{className:"text-[12px] text-[#94A3B8]",children:"No amenity usage data available"})})})]})})}Bn.register(Fo,Lo,Wl,Ar,Zr);function q4({data:e=[]}){const t=[{level:"L1",open:55,in_progress:22,on_hold:15,closed:6},{level:"L2",open:45,in_progress:25,on_hold:18,closed:5},{level:"L3",open:58,in_progress:23,on_hold:14,closed:6}],n=e.length>0?e:t,r=[],i=[],o=[],a=[],s=[];for(let u=0;u<n.length;u++)r.push(n[u].level),i.push(Number(n[u].open)),o.push(Number(n[u].in_progress)),a.push(Number(n[u].on_hold)),s.push(Number(n[u].cancelled));const l={labels:r,datasets:[{label:"Open",data:i,backgroundColor:"#3B82F6",borderColor:"#FFFFFF",borderWidth:2,barThickness:38,stack:"tickets"},{label:"In Progress",data:o,backgroundColor:"#F59E0B",borderColor:"#FFFFFF",borderWidth:2,barThickness:38,stack:"tickets"},{label:"On-Hold",data:a,backgroundColor:"#64748B",borderColor:"#FFFFFF",borderWidth:2,barThickness:38,stack:"tickets"},{label:"Cancelled",data:s,backgroundColor:"#FB2C36",borderColor:"#FFFFFF",borderWidth:2,barThickness:38,stack:"tickets"}]},c={responsive:!0,maintainAspectRatio:!1,plugins:{legend:{position:"bottom",labels:{usePointStyle:!1,pointStyle:"rect",padding:12,boxWidth:20,boxHeight:8,color:"#64748B"}},tooltip:{backgroundColor:"#0F172A",titleColor:"#fff",bodyColor:"#fff"}},scales:{x:{stacked:!0,grid:{display:!1},ticks:{color:"#64748B"}},y:{stacked:!0,beginAtZero:!0,grid:{display:!1,color:"#E5E7EB",borderDash:[4,4],drawBorder:!1},ticks:{color:"#64748B",stepSize:1,precision:0,callback:u=>Math.round(u)}}}};return h.jsx(Le,{className:"h-[267px]",title:"Ticket Escalation Levels",period:"Today",icon:h.jsx(z8,{className:"!text-[24px] text-[#3C81F6]"}),children:h.jsx("div",{className:"h-full",children:h.jsx(zl,{data:l,options:c})})})}const ahe=({active:e,payload:t})=>{if(!e||!t||!t.length)return null;const n=t[0],r=n.payload.color;return h.jsx("div",{style:{backgroundColor:"#000000",color:"#ffffff",padding:"8px 10px",borderRadius:"8px",fontSize:"12px"},children:h.jsxs("div",{className:"flex items-center gap-[8px] font-medium",children:[h.jsx("div",{style:{width:"8px",height:"8px",borderRadius:"50%",backgroundColor:r}}),h.jsx("div",{children:n.name}),h.jsx("div",{className:"ml-2",children:n.value})]})})};function G4({data:e=null}){const n=e||{open:12,on_hold:5,cancelled:3,completed:156,in_progress:8,total_complaints:184},r=a=>{const s=Number(a);return isNaN(s)?0:s},i=[{name:"Completed",value:r(n.completed),color:"#10B981"},{name:"Open",value:r(n.open),color:"#3B82F6"},{name:"In Progress",value:r(n.in_progress),color:"#F59E0B"},{name:"On Hold",value:r(n.on_hold),color:"#6B7280"},{name:"Cancelled",value:r(n.cancelled),color:"#EF4444"}],o=r(n.total_complaints);return h.jsx(Le,{className:"h-[267px]",title:"Ticket Status",period:"Today",icon:h.jsx(wf,{className:"!text-[24px] text-[#EF4444]"}),children:h.jsxs("div",{className:"flex h-full items-center gap-[16px]",children:[h.jsxs("div",{className:"w-[202px] h-[170px] relative",children:[h.jsx(Ot,{width:"100%",height:"100%",children:h.jsxs($i,{children:[h.jsx(ai,{data:i,innerRadius:55,outerRadius:85,dataKey:"value",stroke:"#FFFFFF",strokeWidth:2,children:i.map((a,s)=>h.jsx(In,{fill:a.color},s))}),h.jsx(St,{content:a=>h.jsx(Ut,{...a,data:i,children:h.jsx(ahe,{...a})})})]})}),h.jsxs("div",{className:"absolute inset-0 flex flex-col items-center justify-center pointer-events-none",children:[h.jsxs("div",{className:"flex items-baseline text-[18px] leading-[22px] font-medium text-[#121212]",children:[h.jsx("div",{children:r(n.completed)}),h.jsxs("div",{className:"text-[18.18px] leading-[22.22px] text-[#121212]",children:["/",o]})]}),h.jsx("div",{className:"text-[10.1px] leading-[14.14px] text-[#64748B]",children:"Completed"})]})]}),h.jsx("div",{className:"flex-1 space-y-2",children:i.map(a=>h.jsxs("div",{className:"flex items-center justify-between text-[12px] leading-[17px] mt-[12px]",children:[h.jsxs("div",{className:"flex items-center gap-[8px]",children:[h.jsx("div",{className:"h-[7px] w-[16px]",style:{backgroundColor:a.color}}),h.jsx("div",{className:"text-[12px] leading-[16px] text-[#64748B]",children:a.name})]}),h.jsx("div",{className:"text-[#64748B] text-[12px] leading-[16px] font-medium",children:a.value})]},a.name))})]})})}const X4={visitorSummary:{totalVisitorsToday:150,peakTime:"2:00 - 4:00PM",peakCount:50,activeWalkins:18,preApprovedCheckins:3},popupData:{walkins:{currently_inside:18,total_visited_today:58},preApproved:{completed_visits:3,total_expected_today:5}},chart_data:[{hour:10,walkins:22,preApproved:30},{hour:12,walkins:15,preApproved:28},{hour:14,walkins:30,preApproved:38},{hour:16,walkins:45,preApproved:50},{hour:18,walkins:25,preApproved:40}]};function she(e){const t=e>=12?"PM":"AM";let n=e%12;return n===0&&(n=12),`${n} ${t}`}function lhe(e){if(typeof e=="number"&&e>=0&&e<=23)return e;if(typeof e=="string"){const t=e.trim().toUpperCase(),n=t.match(/^(\d{1,2})(?::\d{2})?\s*(AM|PM)$/);if(n){let i=Number(n[1])%12;return n[2]==="PM"&&(i+=12),i}const r=Number(t);if(!Number.isNaN(r)&&r>=0&&r<=23)return r}return null}function che(e=[]){return Array.from({length:24},(t,n)=>{const r=e.find(i=>lhe(i?.hour)===n)||{};return{hour:n,time:she(n),walkins:Number(r?.walkins??0),approved:Number(r?.pre_approved??r?.preApproved??r?.approved??0)}})}function Q4({title:e,color:t,rows:n=[],children:r}){const i=h.jsxs("div",{className:"bg-white rounded-[12px] min-w-[260px] p-[16px] border-[0.5px] border-[#EBEBEB] shadow-[0px_0px_12px_0px_#EAF2FF]",children:[h.jsx("div",{className:"flex items-center gap-[8px] font-medium text-[#121212]",children:h.jsx("div",{children:e??""})}),h.jsx("div",{className:"mt-[16px] pt-[16px] border-t border-dashed border-[#EBEBEB] space-y-[16px]",children:n?.map(({label:o,value:a,valueColor:s})=>h.jsxs("div",{className:"flex justify-between text-[14px] leading-[18px]",children:[h.jsx("div",{className:"text-[#64748B]",children:o??""}),h.jsx("div",{className:"font-semibold",style:{color:s||"#121212"},children:a??0})]},o))})]});return h.jsx(EM,{placement:"right-start",interactive:!0,delay:[100,0],offset:[6,0],appendTo:()=>document.body,maxWidth:"none",render:o=>h.jsx("div",{tabIndex:"-1",...o,children:i}),children:r})}function uhe({active:e,payload:t}){return!e||!t?.length?null:h.jsx("div",{className:"rounded-[8px] bg-[#121212] px-[12px] py-[8px] text-[12px] text-white shadow-lg",children:t.map(n=>h.jsxs("div",{className:"flex items-center gap-[8px]",children:[h.jsx("span",{className:"h-2 w-2 rounded-full",style:{backgroundColor:n.stroke}}),h.jsx("span",{className:"min-w-[82px] text-[#D1D3D4]",children:n.name}),h.jsx("span",{className:"font-semibold",children:n.value})]},n.dataKey))})}function Z4({data:e}){const t=e&&Object.keys(e).length?e:X4,n=t?.visitor_summary?{totalVisitorsToday:t?.visitor_summary?.total_visitors_today??0,peakTime:t?.visitor_summary?.peak_time??"-"}:t?.visitorSummary??{},r=t?.walkins_popup_data?{walkins:{currently_inside:Number(t?.walkins_popup_data?.walkins_inside??0),total_visited_today:Number(t?.walkins_popup_data?.total_walkins??0)},preApproved:{completed_visits:Number(t?.pre_approved_popup_data?.pre_approved_check_ins??0),total_expected_today:Number(t?.pre_approved_popup_data?.total_pre_approved_check_ins??0)}}:t?.popupData??{},i=k.useMemo(()=>{const l=t?.chart_data??[];return che(l.length?l:X4.chart_data)},[t]),{yAxisTicks:o,yAxisMax:a}=k.useMemo(()=>{const l=Math.max(...i.map(u=>Math.max(u.walkins,u.approved))),c=l>0?l:5;return{yAxisTicks:[0,Math.ceil(c/2),c],yAxisMax:c}},[i]),s=new Date().toLocaleTimeString("en-IN",{hour:"2-digit",minute:"2-digit",hour12:!0});return h.jsx(Le,{className:"h-[377px]",title:"Visitor Updates",period:`Today at ${s}`,icon:h.jsx(Ag,{className:"!text-[24px] text-[#8B5CF6]"}),children:h.jsxs("div",{className:"flex flex-col gap-[24px]",children:[h.jsxs("div",{className:"grid grid-cols-2 gap-y-4 gap-x-6",children:[h.jsxs("div",{className:"flex flex-col gap-[8px]!",children:[h.jsx("div",{className:"text-[10px] text-[#64748B]",children:"Total Visitors"}),h.jsx("div",{className:"text-[20px] font-medium text-[#08B6D4]",children:n?.totalVisitorsToday??0})]}),h.jsxs("div",{className:"flex flex-col gap-[8px]!",children:[h.jsx("div",{className:"text-[10px] text-[#64748B]",children:"Peak Time"}),h.jsx("div",{className:"text-[20px] font-medium text-[#8B5CF6]",children:n?.peakTime??"-"})]}),h.jsxs("div",{className:"mt-2 flex flex-col gap-[8px]!",children:[h.jsx("div",{className:"text-[10px] text-[#64748B]",children:"Active Walk-ins"}),h.jsxs("div",{className:"flex items-baseline text-xl font-medium leading-[32px]",children:[h.jsx("div",{className:"text-[28px] text-[#1FA05B] leading-[32px]",children:r?.walkins?.currently_inside??0}),h.jsx(Q4,{title:"Active Walk-ins",color:"text-[#1FA05B]",rows:[{label:"Currently Inside",value:r?.walkins?.currently_inside??0,valueColor:"#1FA05B"},{label:"Total Visited Today",value:r?.walkins?.total_visited_today??0}],children:h.jsxs("div",{className:"text-[#64748B] cursor-pointer text-[20px] leading-[32px]",children:["/",r?.walkins?.total_visited_today??0]})})]})]}),h.jsxs("div",{className:"mt-2 flex flex-col gap-[8px]!",children:[h.jsx("div",{className:"text-[10px] text-[#64748B]",children:"Pre-approved Check-ins"}),h.jsxs("div",{className:"flex items-baseline text-xl font-medium leading-[32px]",children:[h.jsx("div",{className:"text-[28px] text-[#E7A015] leading-[32px]",children:r?.preApproved?.completed_visits??0}),h.jsx(Q4,{title:"Pre-approved Check-ins",color:"text-[#E7A015]",rows:[{label:"Completed Visits",value:r?.preApproved?.completed_visits??0,valueColor:"#E7A015"},{label:"Total Expected Check-ins Today",value:r?.preApproved?.total_expected_today??0}],children:h.jsxs("div",{className:"text-[#64748B] cursor-pointer text-[20px] leading-[32px]",children:["/",r?.preApproved?.total_expected_today??0]})})]})]})]}),h.jsx("div",{className:"w-full h-[149px]",children:h.jsx(Ot,{width:"100%",height:"100%",children:h.jsxs(Ox,{data:i??[],margin:{top:5,right:0,left:0,bottom:-10},children:[h.jsx(sr,{stroke:"#E5E7EB",strokeDasharray:"4 4",vertical:!1}),h.jsx(Gn,{dataKey:"time",tickFormatter:(l,c)=>c%4===0?l:"",axisLine:!1,tickLine:!1,tick:{fill:"#121212",fontSize:10,fontWeight:400}}),h.jsx(Rn,{width:24,axisLine:!1,tickLine:!1,allowDecimals:!1,ticks:o,domain:[0,a],tick:{fill:"#64748B",fontSize:10,fontWeight:400}}),h.jsx(St,{content:l=>h.jsx(Ut,{...l,data:i,children:h.jsx(uhe,{...l})})}),h.jsx(da,{type:"monotone",dataKey:"walkins",stroke:"#22C55E",strokeWidth:2,dot:!1,name:"Walk-ins",isAnimationActive:!1}),h.jsx(da,{type:"monotone",dataKey:"approved",stroke:"#F59E0B",strokeWidth:2,strokeDasharray:"5 5",dot:!1,name:"Pre-approved",isAnimationActive:!1})]})})})]})})}function dhe(){return h.jsxs(h.Fragment,{children:[h.jsxs("div",{className:"px-[20px] grid grid-cols-1 lg:grid-cols-[minmax(0,1fr)_minmax(0,2fr)] gap-[24px] mt-6 auto-rows-fr",children:[h.jsx(z4,{}),h.jsx(V4,{})]}),h.jsxs("div",{className:"px-[20px] grid grid-cols-1 lg:grid-cols-3 gap-[24px] mt-6 auto-rows-fr",children:[h.jsx("div",{className:"mt-[-115px]",children:h.jsx(Z4,{})}),h.jsx(G4,{}),h.jsx(q4,{})]}),h.jsxs("div",{className:"px-[20px] grid grid-cols-1 lg:grid-cols-3 gap-[24px] mt-6 auto-rows-fr",children:[h.jsx(tM,{}),h.jsx(K4,{}),h.jsx(U4,{})]})]})}function J4({data:e=null}){const t={total_entries:79.6,entries:59350,exit:40950},n=e&&Object.keys(e).length>0?e:t,r=c=>{const u=Number(c);return isNaN(u)?0:u},i=r(n.entries),o=r(n.exit),a=e&&Object.keys(e).length>0&&Number(e.entries)===0&&Number(e.exit)===0,s=[{name:"Entries",value:i,color:"#8B5CF6"},{name:"Exit",value:o,color:"#329DFF"}],l=r(n.total_entries);return h.jsx(kt,{className:"h-[362px]",title:"Access Overview",titleWeight:"semi-bold",children:a?h.jsx("div",{className:"h-[300px] flex items-center justify-center",children:h.jsx(Vt,{title:"No access Point Found",description:"Catch up all the data. Change the date range to see the data."})}):h.jsxs("div",{className:"flex flex-col items-center mt-[16px]",children:[h.jsxs("div",{className:"relative w-[212px] h-[212px]",children:[h.jsx("div",{className:"absolute inset-0 flex items-center justify-center",children:h.jsx("div",{className:"w-[130px] h-[130px] rounded-full shadow-[0px_12px_35px_rgba(0,0,0,0.12)]"})}),h.jsx("div",{className:"h-[212px]",children:h.jsx(Ot,{width:"100%",height:"100%",children:h.jsxs($i,{children:[h.jsx(ai,{data:s,dataKey:"value",innerRadius:65,outerRadius:100,startAngle:360,endAngle:-180,paddingAngle:1,stroke:"transparent",children:s.map((c,u)=>h.jsx(In,{fill:c.color},u))}),h.jsx(St,{content:c=>h.jsx(Ut,{...c,data:s,children:h.jsx(Rr,{...c})})})]})})}),h.jsxs("div",{className:"absolute inset-0 flex flex-col items-center justify-center pointer-events-none",children:[h.jsx("div",{className:"text-[22px] leading-[27px] font-medium text-[#121212]",children:l}),h.jsx("div",{className:"text-[12px] leading-[17px] text-[#64748B]",children:"Total Access"})]})]}),h.jsxs("div",{className:"mt-[28px] flex justify-between w-full px-[20px]",children:[h.jsxs("div",{className:"flex flex-col items-center",children:[h.jsxs("div",{className:"flex items-center gap-[6px]",children:[h.jsx("div",{className:"w-[14px] h-[6px] bg-[#8B5CF6]"}),h.jsx("div",{className:"text-[12px] leading-[16px] text-[#64748B]",children:"Entries"})]}),h.jsx("div",{className:"text-[18px] font-medium text-[#8B5CF6] mt-[4px]",children:i.toLocaleString()})]}),h.jsxs("div",{className:"flex flex-col items-center",children:[h.jsxs("div",{className:"flex items-center gap-[6px]",children:[h.jsx("div",{className:"w-[14px] h-[6px] bg-[#329DFF]"}),h.jsx("div",{className:"text-[12px] leading-[16px] text-[#64748B]",children:"Exit"})]}),h.jsx("div",{className:"text-[18px] font-medium text-[#329DFF] mt-[4px]",children:o.toLocaleString()})]})]})]})})}function eF({title:e="Access",data:t=[],height:n="h-[362px]"}){const r=i=>i==null?"0":Number(i).toLocaleString();return h.jsx(kt,{className:n,title:e,titleWeight:"semi-bold",children:h.jsxs("div",{className:"rounded-[12px] overflow-hidden mt-[16px]",children:[h.jsxs("div",{className:"grid grid-cols-2 bg-[#F8FAFC] py-[8px] px-[12px] text-[12px] leading-[16px] font-medium text-[#64748B]",children:[h.jsx("div",{children:"Point"}),h.jsx("div",{className:"text-right",children:"Access"})]}),t.map((i,o)=>h.jsxs("div",{className:"grid grid-cols-2 p-[12px] text-[14px] border-t border-[#E2E8F0]",children:[h.jsx("div",{className:"text-[12px] leading-[16px] text-[#64748B]",children:i.label}),h.jsx("div",{className:"text-[12px] leading-[16px] text-right font-medium",style:{color:i.color||"#000"},children:r(i.value)})]},o))]})})}function tF({data:e=[]}){const[t,n]=k.useState([]),r=e&&e.length?e:[],i=!e||e.length===0,o=e&&e.length>0&&e.every(c=>Number(c.entries)===0&&Number(c.exit)===0),a=i||o,s=c=>c>=1e3?`${c/1e3}K`:c,l=c=>{n(u=>u.includes(c)?u.filter(d=>d!==c):[...u,c])};return h.jsx(kt,{title:"Access Points Usage",titleWeight:"semi-bold",className:"h-[362px]",children:a?h.jsx("div",{className:"h-[270px] flex items-center justify-center",children:h.jsx(Vt,{title:"No access Point Found",description:"Catch up all the data. Change the date range to see the data."})}):h.jsx("div",{className:"mt-[24px] h-[270px] w-full",children:h.jsx(Ot,{width:"100%",height:"100%",children:h.jsxs(ko,{data:r,barSize:54,margin:{top:0,right:0,left:-20,bottom:0},children:[h.jsx(sr,{strokeDasharray:"8 8",vertical:!1}),h.jsx(lx,{y:0,stroke:"#EBEBEB"}),h.jsx(Gn,{dataKey:"block_name",tick:{fontSize:12,fill:"#64748B"},axisLine:!1,tickLine:!1}),h.jsx(Rn,{tickFormatter:s,tick:{fontSize:12,fill:"#64748B"},axisLine:!1,tickLine:!1}),h.jsx(St,{cursor:!1,content:c=>h.jsx(Ut,{...c,data:r,children:(()=>{if(!c.active||!c.label)return null;const u=r.find(d=>d.block_name===c.label);return h.jsxs("div",{className:"bg-[#111] text-white px-[14px] py-[8px] rounded-[6px] flex flex-col gap-[6px] text-[13px]",children:[h.jsx("div",{className:"font-semibold",children:c.label}),!t.includes("entries")&&h.jsxs("div",{className:"flex items-center gap-[8px]",children:[h.jsx("div",{className:"w-2 h-2 rounded-full bg-[#329DFF]"}),h.jsx("div",{className:"text-[#aaa]",children:"Entries"}),h.jsx("div",{className:"font-bold",children:u?.entries??0})]}),!t.includes("exit")&&h.jsxs("div",{className:"flex items-center gap-[8px]",children:[h.jsx("div",{className:"w-2 h-2 rounded-full bg-[#76BDFF]"}),h.jsx("div",{className:"text-[#aaa]",children:"Exit"}),h.jsx("div",{className:"font-bold",children:u?.exit??0})]})]})})()})}),h.jsx(rl,{verticalAlign:"bottom",height:36,content:()=>{const c=[{key:"entries",label:"Entries",color:"#329DFF"},{key:"exit",label:"Exit",color:"#76BDFF"}];return h.jsx("div",{style:{display:"flex",gap:"20px",justifyContent:"center",marginTop:"20px"},children:c.map((u,d)=>{const f=t.includes(u.key);return h.jsxs("div",{onClick:()=>l(u.key),style:{display:"flex",alignItems:"center",gap:"8px",cursor:"pointer",opacity:f?.4:1},children:[h.jsx("div",{style:{width:"20px",height:"8px",backgroundColor:u.color}}),h.jsx("div",{style:{fontSize:"12px",color:"#64748B"},children:u.label})]},d)})})}}),h.jsx(Gt,{dataKey:"entries",stackId:"a",fill:"#329DFF",hide:t.includes("entries")}),h.jsx(Gt,{dataKey:"exit",stackId:"a",fill:"#76BDFF",hide:t.includes("exit")})]})})})})}function fhe(e){return gt({attr:{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},child:[{tag:"rect",attr:{x:"3",y:"4",width:"18",height:"18",rx:"2",ry:"2"},child:[]},{tag:"line",attr:{x1:"16",y1:"2",x2:"16",y2:"6"},child:[]},{tag:"line",attr:{x1:"8",y1:"2",x2:"8",y2:"6"},child:[]},{tag:"line",attr:{x1:"3",y1:"10",x2:"21",y2:"10"},child:[]}]})(e)}function phe(e){return gt({attr:{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},child:[{tag:"polyline",attr:{points:"6 9 12 15 18 9"},child:[]}]})(e)}function hhe(e){return gt({attr:{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},child:[{tag:"path",attr:{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4"},child:[]},{tag:"polyline",attr:{points:"7 10 12 15 17 10"},child:[]},{tag:"line",attr:{x1:"12",y1:"15",x2:"12",y2:"3"},child:[]}]})(e)}function xs({text:e="Smart Access",Icon:t,iconColor:n="#329DFF"}){return h.jsxs("div",{className:"px-[20px] pt-6",children:[h.jsxs("div",{className:"flex items-center justify-between",children:[h.jsxs("div",{className:"flex items-center gap-[8px]",children:[t?h.jsx("div",{className:"flex items-center justify-center",children:h.jsx(t,{size:20,style:{color:n}})}):null,h.jsx("div",{className:"text-[24px] leading-[32px] font-semibold text-[#121212]",children:e})]}),h.jsxs("div",{className:"flex items-center gap-[12px]",children:[h.jsxs("div",{className:"flex items-center gap-[8px] bg-white px-[16px] py-[8px].5 rounded-[8px] border border-[#EBEBEB] text-sm font-medium text-[#64748B] hover:bg-gray-100 transition-colors cursor-pointer",children:[h.jsx("div",{className:"flex items-center",children:h.jsx(fhe,{size:16})}),h.jsx("div",{children:"Today"}),h.jsx("div",{className:"flex items-center",children:h.jsx(phe,{size:16})})]}),h.jsxs("div",{className:"flex items-center gap-[8px] px-[12px] py-[8px] rounded-[8px] border border-[#EBEBEB] bg-white text-[#7C3AED] text-[14px] font-medium hover:bg-[#E9D5FF] transition cursor-pointer",children:[h.jsx("div",{children:"Export Report"}),h.jsx("div",{className:"flex items-center",children:h.jsx(hhe,{size:16})})]})]})]}),h.jsx("div",{className:"mt-4 border-t border-dashed border-[#E2E8F0]"})]})}function mhe(){return h.jsxs(h.Fragment,{children:[h.jsx(xs,{text:"Smart Access",Icon:spe}),h.jsxs("div",{className:"px-[20px] grid grid-cols-1 lg:grid-cols-3 gap-[24px] mt-6 auto-rows-fr",children:[h.jsx(J4,{}),h.jsx(tF,{})]}),h.jsx("div",{className:"mt-7 px-[20px]"})]})}Bn.register(lm,Ar,Zr);const W1=e=>{const t=Number(e);return Number.isFinite(t)?t:0},ghe={id:"bottomGlow",afterDatasetsDraw(e,t,n){if(!n?.enabled)return;const r=e.getDatasetMeta(0);if(!r?.data?.[0])return;const{ctx:i}=e,{x:o,y:a,innerRadius:s}=r.data[0],l=Math.max(s-2,0),c=a+l*.9,u=i.createRadialGradient(o,c,0,o,c,l*1.08);u.addColorStop(0,n.color??"rgba(186, 230, 253, 0.72)"),u.addColorStop(.3,"rgba(186, 230, 253, 0.4)"),u.addColorStop(.58,"rgba(186, 230, 253, 0.16)"),u.addColorStop(1,"rgba(186, 230, 253, 0)"),i.save(),i.beginPath(),i.arc(o,a,l,0,Math.PI*2),i.clip(),i.fillStyle=u,i.beginPath(),i.ellipse(o,c,l*1.08,l*.52,0,0,Math.PI*2),i.fill(),i.restore()}},vhe={id:"centerText",afterDraw(e,t,n){const{ctx:r}=e,i=e.getDatasetMeta(0);if(!i?.data?.[0])return;const{x:o,y:a}=i.data[0],{top:s="",bottom:l="",topSize:c=24,bottomSize:u=9,topColor:d="#121212",bottomColor:f="#121212"}=n||{};r.save(),r.textAlign="center",r.textBaseline="middle",r.fillStyle=d,r.font=`600 ${c}px Inter, system-ui, -apple-system, Segoe UI, Roboto, sans-serif`,r.fillText(s,o,a-6),r.fillStyle=f,r.font=`500 ${u}px Inter, system-ui, -apple-system, Segoe UI, Roboto, sans-serif`,r.fillText(l,o,a+22),r.restore()}},nF=({title:e="Tickets",icon:t,firstLabel:n="First",firstValue:r=0,firstColor:i="#12B981",secondLabel:o="Second",secondValue:a=0,secondColor:s="#AB0000",growthPercentage:l="+0%",growthText:c="Compared to last month",totalLabel:u="Total",centerTopColor:d="#0F172A",centerBottomColor:f="#64748B",centerTopSize:p,centerBottomSize:m,showBottomGlow:g=!1,bottomGlowColor:v="rgba(186, 230, 253, 0.75)",showEmptyStateWhenZero:x=!1,widgetType:_="",resolvedWidgetType:w="",data:y})=>{const E=y?.title??e;y?.icon;const S=y?.firstLabel??n,P=W1(y?.firstValue??y?.resolved?.current??y?.sold?.current??y?.first?.current??r??0),D=y?.firstColor??i,T=y?.secondLabel??o,I=W1(y?.secondValue??y?.open?.current??y?.unsold?.current??y?.second?.current??a??0),A=y?.secondColor??s,C=y?.growthPercentage??y?.trend_percent??l??"+0%",j=y?.growthText??c,N=y?.totalLabel??u,M=y?.widgetType??_??w,R=y?.centerTopSize??p??(M==="commercial"?34:20),B=y?.centerBottomSize??m??(M==="commercial"?14:10),V=y?.showBottomGlow??g,z=y?.bottomGlowColor??v,W=y?.showEmptyStateWhenZero??x,Q=P+I,X=W1(y?.total_tickets?.current??y?.total_units?.current??y?.total?.current??y?.current??Q),ie=W&&Q===0&&X===0,J={labels:[S,T],datasets:[{data:[P,I],backgroundColor:[D,A],borderWidth:2,hoverOffset:4}]},re={responsive:!0,maintainAspectRatio:!1,cutout:"68%",plugins:{legend:{display:!1},tooltip:{enabled:!1,external:ri()},centerText:{top:`${Q}`,bottom:N,topSize:R,bottomSize:B,topColor:d,bottomColor:f},bottomGlow:{enabled:V,color:z}}},se=[{label:S,value:P,color:D},{label:T,value:I,color:A}],ce=C.toString().includes("+"),de=C.toString().includes("-"),K=ce?"#1FA05B":"#AB0000";return h.jsx(kt,{title:E,className:"h-[362px] leading-[24px]",titleWeight:"semi-bold",childrenClassName:ie?"h-full":"",children:ie?h.jsx("div",{className:"w-full h-full flex items-center justify-center",children:h.jsx(Vt,{})}):h.jsxs("div",{className:"grid grid-cols-12 gap-[16px] items-center",children:[h.jsxs("div",{className:"col-span-5 space-y-[12px]",children:[se.map((U,Z)=>h.jsxs("div",{children:[h.jsx("div",{className:"text-[12px] text-[#64748B] mb-[8px]",children:U.label}),h.jsx("div",{className:"text-[28px] leading-[32px]",style:{color:U.color},children:U.value})]},Z)),h.jsxs("div",{className:`text-[12px] flex gap-[4px] ${M==="commercial"?"mt-[20px]":""} items-center`,style:{color:K},children:[ce&&h.jsx(Xo,{}),de&&h.jsx(Go,{}),h.jsx("div",{children:C.replace("+","").replace("-","")}),h.jsx("div",{className:"text-[#64748B] text-[12px] leading-[14px] ml-[4px] whitespace-nowrap",children:j})]})]}),h.jsx("div",{className:"col-span-7",children:h.jsx("div",{className:`${M==="commercial"?"h-[260px] max-w-[263px]":"h-[158px] w-[158px]"} ml-auto mr-2`,children:h.jsx(fm,{data:J,options:re,plugins:[ghe,vhe]})})})]})})},yhe=({x:e,y:t,payload:n})=>{const r=n.value.split(" ");return h.jsx("g",{transform:`translate(${e},${t})`,children:h.jsx("text",{x:-85,y:0,textAnchor:"start",fill:"#121212",fontSize:14,children:r.map((i,o)=>h.jsx("tspan",{x:-85,dy:o===0?0:16,children:i},o))})})};function rF({data:e=[]}){const t=e&&e.length>0,n=e.map(r=>({name:r.category_name,value:r.total_complaints,color:"#08B6D4"}));return h.jsx(kt,{title:"Tickets per Category",className:"h-[362px]",titleWeight:"semi-bold",childrenClassName:"h-full mt-[24px]!",children:t?h.jsx("div",{className:"w-full h-[262px]",children:h.jsx(Ot,{width:"100%",height:"100%",children:h.jsxs(ko,{data:n,layout:"vertical",margin:{top:0,right:8,left:-20,bottom:0},children:[h.jsx(sr,{strokeDasharray:"3 3",horizontal:!1,stroke:"#E5E7EB"}),h.jsx(Gn,{type:"number",tick:{fill:"#94A3B8",fontSize:12},axisLine:!0,tickLine:!1,tickMargin:10,allowDecimals:!1}),h.jsx(Rn,{type:"category",dataKey:"name",axisLine:!1,tickLine:!1,width:132,tick:h.jsx(yhe,{})}),h.jsx(St,{cursor:{fill:"transparent"},position:{x:300,y:0},allowEscapeViewBox:{x:!0,y:!0},content:r=>r.active?h.jsx(Ut,{...r,data:n,children:h.jsx(Rr,{...r})}):null}),h.jsx(Gt,{dataKey:"value",barSize:36,fill:"#08B6D4"})]})})}):h.jsx(Vt,{title:"No Tickets Found",description:"Catch up all the data. Change the date range to see the data."})})}function z1({icon:e,iconColor:t="#329DFF",title:n,value:r,percentage:i,percentageText:o}){const a=parseFloat(i),s=a>=0,l=s?"#16A34A":"#DC2626";return h.jsxs("div",{className:"relative bg-white !border-[0.5px] !border-[#EBEBEB] !rounded-[12px] !shadow-[0_0_12px_0_#EAF2FF] p-[16px] h-[132px]",children:[h.jsxs("div",{className:"flex items-center gap-[8px]",children:[e&&h.jsx("div",{className:"h-[20px] w-[20px]",style:{color:t,display:"flex",alignItems:"center",justifyContent:"center"},children:h.jsx(e,{className:"h-[20px] w-[20px]"})}),h.jsx("div",{className:"text-[16px] leading-[20px] tracking-[-2%] font-medium text-[#64748B]",children:n})]}),h.jsx("div",{className:"mt-[16px] text-[28px] leading-[32px] font-medium text-[#121212]",children:r}),(i||o)&&h.jsxs("div",{className:"mt-[12px] flex items-center gap-[8px]",children:[i&&h.jsxs("div",{className:"flex items-center gap-[4px] text-[12px] leading-[16px] font-medium",style:{color:l},children:[s?h.jsx(Xo,{}):h.jsx(Go,{}),Math.abs(a),"%"]}),o&&h.jsx("div",{className:"text-[12px] leading-[16px] text-[#64748B]",children:o})]})]})}function bhe(){const e=[{category_name:"Plumbing",total_complaints:12},{category_name:"Electrical Issues",total_complaints:8},{category_name:"Cleaning Services",total_complaints:15}];return h.jsxs(h.Fragment,{children:[h.jsx(xs,{text:"Helpdesk",Icon:Zfe,iconColor:"#12B981"}),h.jsxs("div",{className:"flex gap-[24px] mt-[24px] px-[16px]",children:[h.jsx("div",{className:"w-[380px] h-full space-y-[16px]",children:h.jsx(nF,{title:"Tickets",icon:h.jsx(wf,{className:"h-6 w-6 text-[#EF4444]"}),firstLabel:"Resolved",firstValue:779,firstColor:"#12B981",secondLabel:"Open",secondValue:83,secondColor:"#AB0000",growthPercentage:"+9.1%",growthColor:"#1FA05B",growthText:"Compared to last month",widgetType:"commercial",totalLabel:"Total",centerTopSize:34,centerBottomSize:14,showBottomGlow:!0,showEmptyStateWhenZero:!0})}),h.jsx("div",{className:"flex-1",children:h.jsx(rF,{data:e})})]})]})}const iF=e=>String(e).padStart(2,"0"),oF=(e,t="start")=>e?`${[e.getFullYear(),iF(e.getMonth()+1),iF(e.getDate())].join("-")} ${t==="end"?"23:59:59":"00:00:00"}`:"",aF=({data:e=[],onDateChange:t})=>{const[n,r]=k.useState(new Date),[i,o]=k.useState(!1),s=(v=>{const x=new Date(v);return x.setDate(x.getDate()-6),x})(n),l=v=>{try{return v.toLocaleDateString("en-GB",{day:"2-digit",month:"short"})}catch{return""}},c=v=>{const x=new Date(v),_=new Date(x);_.setDate(_.getDate()-6),t&&t(oF(_,"start"),oF(x,"end"))},u=()=>{const v=new Date(n);v.setDate(v.getDate()-7),r(v),c(v)},d=()=>{const v=new Date(n);v.setDate(v.getDate()+7),r(v),c(v)},f=()=>{o(v=>!v)},p=v=>{const x=v||new Date;r(x),c(x),o(!1)},m=Array.isArray(e)?e:[],g=!m.length||m.every(v=>v.no_of_visitors===0);return h.jsxs(kt,{title:"Weekly Visitor Pattern",period:`${l(s)} - ${l(n)}`,isDateSelector:!0,titleWeight:"semi-bold",className:"h-[360px]",childrenClassName:"mt-6",onPrevClick:u,onNextClick:d,onCalendarClick:f,children:[i&&h.jsx("div",{className:"anarock-datepicker absolute top-[70px] right-[24px] z-50",children:h.jsx(eS,{selected:n,onChange:p,inline:!0,maxDate:new Date,showYearDropdown:!0,scrollableYearDropdown:!0,yearDropdownItemNumber:40})}),g?h.jsx("div",{className:"w-full h-[280px] flex items-center justify-center",children:h.jsx(Vt,{title:"No Visitors Found",description:"Catch up all the data. Change the date range to see the data."})}):h.jsx("div",{className:"w-full h-[280px]",children:h.jsx(Ot,{width:"100%",height:"100%",children:h.jsxs(tj,{data:m,margin:{top:10,right:-10,left:-10,bottom:0},children:[h.jsx("defs",{children:h.jsxs("linearGradient",{id:"colorVisitors",x1:"0",y1:"0",x2:"0",y2:"1",children:[h.jsx("stop",{offset:"0%",stopColor:"#6366F1",stopOpacity:.25}),h.jsx("stop",{offset:"100%",stopColor:"#6366F1",stopOpacity:0})]})}),h.jsx(sr,{strokeDasharray:"3 3",vertical:!1,stroke:"#F1F5F9"}),h.jsx(Gn,{dataKey:"day",type:"category",scale:"point",padding:{left:20,right:20},tick:{fontSize:12,fill:"#64748B"},axisLine:!0,tickLine:!1,tickFormatter:v=>new Date(v).toLocaleDateString("en-GB",{day:"2-digit",month:"short"})}),h.jsx(Rn,{width:35,tick:{fontSize:12,fill:"#64748B"},axisLine:!1,tickLine:!1,allowDecimals:!1,domain:[0,"dataMax + 2"]}),h.jsx(St,{cursor:!1,content:v=>{const{active:x,payload:_,label:w}=v;if(!x||!_?.length)return null;const y=new Date(w).toLocaleDateString("en-GB",{day:"2-digit",month:"short"});return h.jsx(Ut,{...v,data:m,children:h.jsx(Rr,{active:x,payload:_,label:y})})}}),h.jsx(hx,{type:"monotone",dataKey:"no_of_visitors",stroke:"#6366F1",strokeWidth:2,fill:"url(#colorVisitors)",dot:{r:5,stroke:"#6366F1",strokeWidth:2,fill:"#fff"},activeDot:v=>{const{cx:x,cy:_,stroke:w}=v;return h.jsxs("g",{children:[h.jsx("circle",{cx:x,cy:_,r:6,fill:"#fff",stroke:"#6466F1",strokeWidth:2}),h.jsx("circle",{cx:x,cy:_,r:2.5,fill:"#6466F1"})]})}})]})})})]})},xhe=[{building_name:"Google",no_of_visitors:1e3},{building_name:"Uber",no_of_visitors:3500},{building_name:"ANAROCK",no_of_visitors:2e3},{building_name:"Flipkart",no_of_visitors:8e3},{building_name:"HP",no_of_visitors:1650}],sF=({data:e,title:t,bar:n})=>{const r=Array.isArray(e)&&e?.length===0,i=e==null?xhe:Array.isArray(e)?e:[];return h.jsx(kt,{title:t||"Organisation Wise Visitors",titleWeight:"semi-bold",className:"h-[360px]",childrenClassName:"mt-6",children:h.jsx("div",{className:"w-full h-[260px] flex items-center justify-center",children:r?h.jsx(Vt,{title:t||"Organisation Wise Visitors",description:"Catch up all the data. Change the date range to see the data."}):h.jsx(Ot,{width:"100%",height:"100%",children:h.jsxs(ko,{data:i||[],margin:{top:10,right:10,left:10,bottom:-10},barCategoryGap:35,children:[h.jsx(sr,{strokeDasharray:"3 3",vertical:!1,stroke:"#F1F5F9"}),h.jsx(Gn,{dataKey:"building_name",tick:{fontSize:12,fill:"#64748B"},axisLine:!0,tickLine:!1}),h.jsx(Rn,{width:40,tick:{fontSize:12,fill:"#64748B"},axisLine:!1,tickLine:!1,allowDecimals:!1}),h.jsx(St,{cursor:!1,content:o=>o.active?h.jsx(Ut,{...o,data:i,children:h.jsx(Rr,{...o})}):null}),h.jsx(Gt,{dataKey:"no_of_visitors",name:"Visitors",maxBarSize:55,fill:n||"#3C81F6"})]})})})})};function whe(){const e=[{day:"2026-03-05",no_of_visitors:0},{day:"2026-03-06",no_of_visitors:0},{day:"2026-03-07",no_of_visitors:0},{day:"2026-03-08",no_of_visitors:14},{day:"2026-03-09",no_of_visitors:0},{day:"2026-03-10",no_of_visitors:0},{day:"2026-03-11",no_of_visitors:0}];return h.jsxs(h.Fragment,{children:[h.jsx(xs,{text:"Visitors",Icon:Qfe,iconColor:"#884EA7"}),h.jsxs("div",{className:"grid grid-cols-2 gap-[24px] mt-[24px]",children:[h.jsx(z1,{icon:upe,iconColor:"#329DFF",title:"Visitors Expected",value:"1,247",percentage:"+11.0%",percentageText:"Compared to last month"}),h.jsx(z1,{icon:Kfe,iconColor:"#1FA05B",title:"Visitors Inside",value:"800",percentageText:"Across organisations"})]}),h.jsxs("div",{className:"grid grid-cols-2 gap-[24px] mt-[24px]",children:[h.jsx(aF,{data:e}),h.jsx(sF,{})]}),h.jsx("div",{})]})}function Ro({data:e}){return h.jsx("div",{className:"h-full",children:e.map((t,n)=>{const r=parseFloat(t.delta),i=r>=0;return h.jsx(Le,{iconClassName:"!gap-[8px]",title:h.jsx("div",{className:"text-[#64748B]",children:t.title}),icon:h.jsx(t.Icon,{className:"h-[20px] w-[20px]",style:{color:t.iconColor||"#000000"}}),className:`${t?.widget==="amenities"?"h-[139px]":"h-[124px]"}`,children:h.jsxs("div",{className:`flex flex-col gap-[8px] ${t?.widget==="amenities"?"mt-[3.5px]":"mt-0"}`,children:[h.jsx("div",{className:"text-[28px] leading-[32px] font-medium text-[#121212]",children:t.value}),h.jsxs("div",{className:`flex items-center text-[12px] leading-[16px] ${t.delta?"gap-[8px]":""}`,children:[t.delta&&h.jsxs("div",{className:`flex items-center gap-[4px] px-[6px] py-[2px] rounded-[4px] font-medium
|
|
480
|
+
`,children:n}),h.jsx("div",{className:"!text-[#64748B]",children:r})]})]})}const Ape=[{title:"Total Visitors",value:160,delta:"+11.0%",deltaLabel:"Compared to last month",positive:!0,Icon:Ng,iconColor:"text-[#329DFF]"},{title:"Active Incidents",value:73,delta:"+2.0%",deltaLabel:"Compared to last month",positive:!0,Icon:Zae,iconColor:"text-[#F69E0A]"},{title:"Missed Patrols",value:3,delta:"+11.0%",deltaLabel:"Compared to last month",positive:!0,Icon:Ppe,iconColor:"text-[#AB0000]"},{title:"Parking Usage",value:5,delta:"-8.0%",deltaLabel:"Compared to last month",positive:!1,Icon:F8,iconColor:"text-[#36AB6C]"}];function Tpe({data:e}){const t=Array.isArray(e)&&e.length>0?e:Ape;return h.jsx("div",{className:"px-[20px] grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-4 gap-[24px]",children:t.map((n,r)=>h.jsx(Dpe,{...n},r))})}const Npe=[{title:"Maintenance",total:12,pending:3},{title:"Security",total:8,pending:1},{title:"Housekeeping",total:6,pending:2},{title:"Utilities",total:10,pending:4}],jpe=(e="")=>e.replace(/</g,"<").replace(/>/g,">").replace(/<[^>]*>/g,"").trim();function Mpe({data:e}){const t=Array.isArray(e?.complaints_by_category)&&e.complaints_by_category.length>0?e.complaints_by_category.map(n=>({title:jpe(n.category_name)||"—",total:n.total||0,pending:n.pending||0})):Npe;return h.jsx(Le,{title:"Complaints",titleClassName:"!text-[20px] !leading-[24px] font-semibold!",className:"w-full h-[362px] p-[24px]!",children:h.jsx("div",{className:"flex flex-col gap-[12px] max-h-full overflow-y-auto hide-scrollbar",children:t.map((n,r)=>h.jsxs("div",{className:"flex items-center justify-between bg-[#F8FAFC] rounded-[4px] p-[12px]",children:[h.jsxs("div",{className:"flex flex-col gap-[4px]",children:[h.jsx("div",{className:"text-[14px] leading-[18px] font-medium text-[#121212] capitalize",children:n.title}),h.jsxs("div",{className:"text-[12px] leading-[16px] text-[#64748B]",children:["Total: ",n.total]})]}),h.jsxs("div",{className:"flex flex-col items-end gap-[4px]",children:[h.jsx("div",{className:"text-[14px] leading-[18px] font-medium text-[#AB0000]",children:String(n.pending).padStart(2,"0")}),h.jsx("div",{className:"text-[12px] leading-[16px] text-[#64748B]",children:"Pending"})]})]},r))})})}const Ipe=[{level:"Level 1",open_count:3,in_progress_count:4,closed_count:5,total:12},{level:"Level 2",open_count:1,in_progress_count:1,closed_count:1,total:3},{level:"Level 3",open_count:5,in_progress_count:2,closed_count:3,total:10}],Fpe=()=>{const e=[{label:"Open",color:"#EF4444"},{label:"In Progress",color:"#F59D0D"},{label:"Closed",color:"#12B981"}];return h.jsx("div",{style:{display:"flex",justifyContent:"space-between",gap:"15px"},children:e.map(t=>h.jsxs("div",{style:{display:"flex",alignItems:"center",gap:"6px"},children:[h.jsx("div",{style:{width:"6px",height:"6px",backgroundColor:t.color,transform:"rotate(45deg)"}}),h.jsx("span",{style:{fontSize:"14px"},children:t.label})]},t.label))})},Lpe=({data:e})=>{const t=k.useMemo(()=>(Array.isArray(e?.complaints_by_level)&&e.complaints_by_level.some(l=>Number(l.total)>0)?e.complaints_by_level:Ipe).map(l=>({level:l.level||"—",open_count:Number(l.open_count)||0,in_progress_count:Number(l.in_progress_count)||0,closed_count:Number(l.closed_count)||0,total:Number(l.total)||0})),[e]),n=k.useMemo(()=>Math.max(...t.map(a=>a.total),5),[t]),r=Math.ceil(n*1.2),i=6,o=Math.max(Math.ceil(n/i),1);return h.jsxs(Le,{title:"Complaints by Level",className:"w-full h-[362px] p-[24px]! gap-[18px]!",titleClassName:"!text-[20px] !leading-[24px] font-semibold!",children:[h.jsx(Ot,{width:"100%",height:"85%",children:h.jsxs(ko,{data:t,margin:{top:5,right:-25,left:-30,bottom:5},children:[h.jsx(sr,{strokeDasharray:"0",vertical:!1}),h.jsx(Gn,{dataKey:"level"}),h.jsx(Rn,{domain:[0,r],ticks:Array.from({length:i+1},(a,s)=>s*o)}),h.jsx(St,{cursor:{fill:"rgba(148, 163, 184, 0.12)"},allowEscapeViewBox:{x:!0,y:!0},content:a=>!a.active||!a.payload||!a.payload.length?null:h.jsx(Ut,{...a,data:t,children:h.jsxs("div",{className:"bg-[#121212] rounded-[10px] px-[14px] py-[10px] text-[12px] text-white",children:[h.jsx("div",{className:"mb-[6px] font-semibold",children:a.label}),a.payload.map((s,l)=>{const c=s.color||s.fill||"#fff";return h.jsxs("div",{className:"flex items-center gap-[6px]",children:[h.jsx("span",{className:"w-2 h-2 rounded-full inline-block",style:{backgroundColor:c}}),h.jsx("span",{className:"text-[#D1D3D4]",children:s.name}),h.jsx("span",{className:"text-white font-semibold",children:s.value})]},l)})]})})}),h.jsx(Gt,{dataKey:"open_count",name:"Open",stackId:"a",fill:"#EF4444",barSize:44,radius:[0,0,0,0]}),h.jsx(Gt,{dataKey:"in_progress_count",name:"In Progress",stackId:"a",fill:"#F59D0D",barSize:44,radius:[0,0,0,0]}),h.jsx(Gt,{dataKey:"closed_count",name:"Closed",stackId:"a",fill:"#12B981",barSize:44,radius:[0,0,0,0]})]})}),h.jsx(Fpe,{})]})},Rpe=[{title:"Maintenance",total:18,pending:4},{title:"Security",total:11,pending:2},{title:"Housekeeping",total:9,pending:3},{title:"Utilities",total:14,pending:5}];function $pe({data:e}){const t=Array.isArray(e?.request_box_by_type)&&e.request_box_by_type.length>0?e.request_box_by_type.map(n=>({title:n.category_name||"—",total:Number(n.total)||0,pending:Number(n.pending)||0})):Rpe;return h.jsx(Le,{title:"Request Box",titleClassName:"!text-[20px] !leading-[24px] font-semibold!",className:"w-full h-[362px] p-[24px]!",children:h.jsx("div",{className:"flex flex-col gap-[12px] max-h-full overflow-y-auto hide-scrollbar",children:t.map((n,r)=>h.jsxs("div",{className:"flex items-center justify-between bg-[#F8FAFC] rounded-[4px] p-[12px]",children:[h.jsxs("div",{className:"flex flex-col gap-[4px]",children:[h.jsx("div",{className:"text-[14px] leading-[18px] font-medium text-[#121212] capitalize",children:n.title}),h.jsxs("div",{className:"text-[12px] leading-[16px] text-[#64748B]",children:["Total: ",n.total]})]}),h.jsxs("div",{className:"flex flex-col items-end gap-[4px]",children:[h.jsx("div",{className:"text-[14px] leading-[18px] font-medium text-[#AB0000]",children:String(n.pending).padStart(2,"0")}),h.jsx("div",{className:"text-[12px] leading-[16px] text-[#64748B]",children:"Pending"})]})]},`${n.title}-${r}`))})})}function Bpe(e){return gt({attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{fill:"none",strokeLinejoin:"round",strokeWidth:"32",d:"M416 221.25V416a48 48 0 0 1-48 48H144a48 48 0 0 1-48-48V96a48 48 0 0 1 48-48h98.75a32 32 0 0 1 22.62 9.37l141.26 141.26a32 32 0 0 1 9.37 22.62z"},child:[]},{tag:"path",attr:{fill:"none",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"32",d:"M256 56v120a32 32 0 0 0 32 32h120m-232 80h160m-160 80h160"},child:[]}]})(e)}const Wpe=["open_complaints","pending_requests","avg_response_time","resolution_rate"],zpe={open_complaints:{title:"Open Complaints",Icon:lS,iconColor:"#AB0000",deltaLabel:"Compared to last month"},pending_requests:{title:"Pending Requests",Icon:Bpe,iconColor:"#E7A015",deltaLabel:"Compared to last month"},avg_response_time:{title:"Avg Response Time",Icon:V8,iconColor:"#1FA05B",deltaLabel:"Compared to last month"},resolution_rate:{title:"Resolution Rate",Icon:W8,iconColor:"#329DFF",deltaLabel:"Compared to last month"}},Vpe=({children:e,size:t=28,lineHeight:n=32,weight:r=500,color:i="#121212"})=>h.jsx("div",{style:{fontWeight:r,fontSize:`${t}px`,lineHeight:`${n}px`,color:i},children:e}),Hpe={primary:{size:28,lineHeight:32,weight:500}},Ype={open_complaints:{current:24,trend_percent:"-8%",direction:"bad"},pending_requests:{current:17,trend_percent:"-5%",direction:"bad"},avg_response_time:{current:"2.4 h",trend_percent:"+6%",direction:"good"},resolution_rate:{current:"89%",trend_percent:"+4%",direction:"good"}};function Upe({id:e,data:t}){return e&&t&&!t[e]&&t.current!==void 0?h.jsx(B4,{id:e,data:t}):h.jsx("div",{className:"px-[20px] grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-4 gap-[16px]",children:Wpe.map(n=>h.jsx(B4,{id:n},n))})}function B4({id:e,data:t}){const n=zpe[e];if(!n)return null;const r=(d,f)=>f==null?"—":d==="avg_response_time"?typeof f=="number"?`${f} h`:f:d==="resolution_rate"&&typeof f=="number"?`${f}%`:f,{title:i,Icon:o=Ld,iconColor:a,deltaLabel:s}=n,l=t&&Object.keys(t).length>0?t:Ype[e],c=r(e,l?.current),u=l?.trend_percent??"—";return l?.direction==="good"||l?.direction,h.jsx("div",{className:"h-[132px]",children:h.jsxs(Le,{title:i,titleColor:a,icon:h.jsx("div",{className:"h-[20px] w-[20px] flex items-center justify-center",children:h.jsx(o,{className:"h-[20px] w-[20px]",style:{color:a}})}),childrenClassName:"!space-y-[12px]",iconClassName:"!gap-[12px]",children:[h.jsx(Vpe,{...Hpe.primary,children:c}),h.jsxs("div",{className:"flex items-center gap-[8px] text-[12px] leading-[16px]",children:[h.jsx(Tc,{value:u}),h.jsx("div",{className:"text-[#64748B] text-[12px] leading-[16px]",children:s})]})]})})}const Kpe=[{title:"Holi Celebration",date:"25 Jun 2025",rsvp:"78/100",utilisation:71,status:"Upcoming"},{title:"Maintenance Meeting",date:"25 Jun 2025",rsvp:"45/60",utilisation:75,status:"Completed"},{title:"Maintenance Meeting",date:"25 Jun 2025",rsvp:"45/60",utilisation:75,status:"Completed"},{title:"Maintenance Meeting",date:"25 Jun 2025",rsvp:"45/60",utilisation:75,status:"Completed"}];function qpe({title:e,date:t,rsvp:n,utilisation:r,status:i}){return h.jsxs("div",{className:"bg-[#F8FAFC] p-[12px] rounded-[4px]",children:[h.jsxs("div",{className:"flex items-center justify-between",children:[h.jsx("div",{className:"text-[16px] leading-[20px] font-semibold text-[#121212]",children:e}),h.jsx("div",{className:`!text-[12px] leading-[16px] font-medium p-[4px] rounded-[4px] ${i==="Completed"?"text-[#36AB6C] bg-[#E6F7EE]":i==="Upcoming"?"text-[#329DFF] bg-[#E6F2FF]":"text-slate-500 bg-slate-100"}`,children:i})]}),h.jsx("div",{className:"text-[14px] leading-[18px] text-[#64748B]",children:t}),h.jsxs("div",{className:"mt-[8px] flex justify-between items-center",children:[h.jsxs("div",{className:"text-[14px] leading-[18px] text-[#64748B]",children:[n," RSVP"]}),h.jsxs("div",{className:"text-[#3C82F6] text-[14px] leading-[18px] font-medium",children:[r,"% utilisation"]})]}),h.jsx("div",{className:"mt-[8px] w-full bg-[#F8FAFC] h-[6px] rounded",children:h.jsx("div",{className:"h-[6px] rounded bg-[#3C82F6]",style:{width:`${r}%`}})})]})}function Gpe({data:e}){const t=Array.isArray(e)&&e.length===0,n=Array.isArray(e)?e:Kpe;return h.jsx(Le,{title:"Events Utilisation",className:"w-full h-[360px] p-[24px]!",childrenClassName:t?"h-full":"overflow-y-auto hide-scrollbar",titleClassName:"!text-[20px] !leading-[24px] font-semibold!",children:h.jsx("div",{className:`w-full h-full ${t?"flex items-center justify-center":"space-y-[12px]"}`,children:n?.length>0?n.map((r,i)=>h.jsx(qpe,{...r},`${r.title}-${i}`)):h.jsx(Vt,{})})})}const Xpe=[{label:"Active",value:138,subLabel:"3 expiring soon",bgColor:"bg-[#F0FFF7]",textColor:"text-[#1FA05B]"},{label:"Scheduled",value:13,subLabel:"4 this week",bgColor:"bg-[#FFFBF2]",textColor:"text-[#E7A015]"},{label:"Recurring",value:3,subLabel:"All active",bgColor:"bg-[#EDF6FF]",textColor:"text-[#329DFF]"},{label:"Expired",value:7,subLabel:"4 recent",bgColor:"bg-[#F6F6F6]",textColor:"text-[#64748B]"}];function Qpe({label:e,value:t,subLabel:n,bgColor:r,textColor:i}){return h.jsxs("div",{className:`border-[0.5px] border-[#EBEBEB] rounded-[12px] p-[16px] ${r} h-[124px]`,children:[h.jsx("div",{className:`text-[16px] leading-[20px]! tracking-[-2%] font-medium ${i}`,children:e}),h.jsx("div",{className:"mt-[16px] text-[28px] leading-[32px] font-semibold text-[#121212]",children:t}),h.jsx("div",{className:"mt-[8px] !text-[12px] leading-[16px] text-[#64748B]",children:n})]})}function Zpe({data:e}){const t=Array.isArray(e)&&e.length>0?e:Xpe;return h.jsx(Le,{title:"Notice Board Status",className:"w-full h-[360px] !p-[24px]",titleClassName:"!text-[20px] !leading-[24px] font-semibold!",children:h.jsx("div",{className:"grid grid-cols-2 gap-[24px]",children:t.map((n,r)=>h.jsx(Qpe,{...n},`${n.label}-${r}`))})})}function Jpe({title:e,value:t,delta:n,deltaLabel:r,positive:i=!0,Icon:o=Ld,iconColor:a="text-emerald-600",iconBg:s="bg-emerald-50",iconUrl:l}){return h.jsx(Le,{title:e,icon:h.jsx("div",{className:"grid place-items-center ",children:l?h.jsx("img",{src:l,alt:"icon",className:"h-8 w-8 object-contain"}):h.jsx(o,{className:`h-8 w-8 ${a}`})}),className:"h-[132px]",children:h.jsxs("div",{children:[h.jsx("div",{className:"text-[28px] leading-[32px] font-medium text-[#121212]",children:t}),h.jsxs("div",{className:"flex items-center gap-[8px] pt-[8px] !text-[12px] leading-[16px]",children:[h.jsx(Tc,{value:n}),h.jsx("div",{className:"text-[#64748B]",children:r})]})]})})}function ehe({data:e}){const t=[{title:e?.title||"Total Bookings",value:e?.value??0,delta:e?.delta??"0%",deltaLabel:e?.deltaLabel||"Compared to last month",positive:e?.positive??!1,Icon:e?.Icon,iconUrl:e?.iconUrl,iconColor:e?.iconColor||"text-emerald-600",iconBg:e?.iconBg||"bg-emerald-50"}];return h.jsx("div",{className:"h-full",children:t.map((n,r)=>h.jsx(Jpe,{...n},r))})}function the({title:e,value:t,delta:n,deltaLabel:r,positive:i=!0,icon:o,iconColor:a="text-emerald-600",iconBg:s="bg-emerald-50"}){return h.jsxs(Le,{title:e,icon:h.jsx("div",{className:"size-[20px] grid place-items-center",children:h.jsx("img",{src:o,alt:e})}),className:"h-[132px]",titleClassName:"text-[#64748B]! leading-[20px]",childrenClassName:"space-y-[8px]!",children:[h.jsx("div",{className:"text-[28px] leading-[32px] font-medium text-[#121212]",children:t}),h.jsxs("div",{className:"flex items-center gap-[8px] text-[12px] leading-[16px]",children:[h.jsx(Tc,{value:n}),h.jsx("div",{className:"text-[#64748B] text-[12px] leading-[16px]",children:r})]})]})}const nhe=[{title:"Notice",value:160,delta:"+11.0%",deltaLabel:"Compared to last month",positive:!0,icon:"https://res.cloudinary.com/dzqlw1ixr/image/upload/v1773902569/notice_djcorh.svg"},{title:"Post",value:83,delta:"+2.0%",deltaLabel:"Compared to last month",positive:!0,icon:"https://res.cloudinary.com/dzqlw1ixr/image/upload/v1773902568/post_rivboo.svg"},{title:"Poll",value:3,delta:"+11.0%",deltaLabel:"Compared to last month",positive:!0,icon:"https://res.cloudinary.com/dzqlw1ixr/image/upload/v1773902569/poll_b43jo0.svg"},{title:"Survey",value:5,delta:"-8.0%",deltaLabel:"Compared to last month",positive:!1,icon:"https://res.cloudinary.com/dzqlw1ixr/image/upload/v1773902568/survey_yevzwi.svg"}];function rhe({data:e}){const t=Array.isArray(e)&&e.length>0?e:nhe;return h.jsx("div",{className:"px-[20px] grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-4 gap-[24px]",children:t.map((n,r)=>h.jsx(the,{...n},r))})}const W4=({value:e=0,total:t=1,colorClass:n="",label:r=""})=>{const i=Number(e)||0,o=Number(t)||1,a=Math.max(0,Math.min(100,i/o*100)),s=n==="bg-[#3C81F6]"?"text-[#8B5CF6]":n==="bg-[#8B5CF6]"?"text-[#12B981]":"text-slate-600";return h.jsxs("div",{className:"flex flex-col items-start",children:[h.jsx("div",{className:"w-2/3 min-w-[80px] h-5 rounded-full overflow-hidden",children:h.jsx("div",{className:`h-[11px] rounded-full ${n||""}`,style:{width:n==="bg-[#12B981]"?`${a+45}%`:`${a}%`}})}),h.jsx("div",{className:`${s} !text-[12px] font-bold mt-1`,children:i??0}),h.jsx("div",{className:"!text-[12px] leading-[16px] text-[#64748B] mt-1",children:r??""})]})},z4=({data:e,occupiedUnits:t=1,EmployeesCount:n=8910,AdminsCount:r=910})=>{const i=e?.total_occupants!==void 0&&e?.total_occupants!==null?Number(e?.total_occupants)||0:Number(t)||0,o=e?.total_members!==void 0&&e?.total_members!==null?Number(e?.total_members)||0:Number(n)||0,a=e?.total_admins!==void 0&&e?.total_admins!==null?Number(e?.total_admins)||0:Number(r)||0,s=(o||0)+(a||0);return h.jsx("div",{children:h.jsxs("div",{className:"bg-white !border-[0.5px] !border-[#EBEBEB] rounded-[12px] shadow-[0_0_12px_0_#EAF2FF] p-[16px] h-[128px]",children:[h.jsxs("div",{className:"flex items-center gap-[12px] h-[20px]",style:{marginBottom:"24px"},children:[h.jsx(Ng,{className:"!text-[20px] text-[#329DFF]"}),h.jsx("div",{className:"font-medium text-[#121212] text-[16px] leading-[20px]",children:"Occupancy Overview"})]}),h.jsxs("div",{className:"flex items-start justify-between",children:[h.jsxs("div",{className:"flex flex-col gap-[4px]",children:[h.jsx("div",{className:"text-[12px] leading-[16px] text-[#64748B] font-normal",children:"Total Occupants"}),h.jsx("div",{className:"text-[28px] leading-[32px] font-medium text-[#121212]",children:i??0})]}),h.jsxs("div",{className:"flex items-end gap-[4px]",children:[h.jsx(W4,{value:o??0,total:s||1,colorClass:"bg-[#3C81F6]",label:(o??0)<=1?"Employee":"Employees"}),h.jsx(W4,{value:a??0,total:s||1,colorClass:"bg-[#8B5CF6]",label:(a??0)<=1?"Admin":"Admins"})]})]})]})})};Bn.register(Fo,Lo,Wl,Ar);const V4=({data:e})=>{const t=e!=null,n=e?.employee_data,r=["HP","Adobe","Anarock","Swiggy","Infosys","Zepto"],i=[2e3,1700,1500,1200,900,800],o=[],a=[];if(t){if(n&&n.length>0)for(let d=0;d<n.length;d++)o.push(n[d].name),a.push(n[d].employees)}else for(let d=0;d<r.length;d++)o.push(r[d]),a.push(i[d]);let s=!1;if(t)if(!n||n.length===0)s=!0;else{s=!0;for(let d=0;d<n.length;d++)if(n[d].employees!==0){s=!1;break}}let l=0;for(let d=0;d<a.length;d++)a[d]>l&&(l=a[d]);const c={labels:o,datasets:[{data:a,backgroundColor:[],barThickness:34}]};for(let d=0;d<a.length;d++)c.datasets[0].backgroundColor.push("#3C81F6");const u={responsive:!0,maintainAspectRatio:!1,plugins:{legend:{display:!1},tooltip:{backgroundColor:"#0F172A",titleColor:"#fff",bodyColor:"#fff",displayColors:!1,callbacks:{label:d=>`Employees: ${d.parsed.y}`}}},scales:{x:{grid:{display:!1},ticks:{color:"#64748B",font:{size:12}}},y:{beginAtZero:!0,min:0,max:l>0?l+5:2e3,ticks:{stepSize:l>0?Math.ceil((l+5)/5):500,color:"#64748B",callback:d=>d},grid:{display:!1,color:"#E5E7EB",borderDash:[4,4],drawBorder:!1}}}};return t&&s?h.jsx(Le,{className:"w-full h-[238px]",title:"Employee Footfall",period:"Today",icon:h.jsx(I4,{className:"!text-[24px] text-[#8B5CF6]"}),children:h.jsx("div",{className:"h-full flex items-center justify-center",children:h.jsx(Vt,{title:"No Employee footfall Found",description:"Catch up all the data. Change the date range to see the data."})})}):h.jsxs(Le,{className:"w-full h-[238px]",title:"Employee Footfall",period:"Today",icon:h.jsx(I4,{className:"!text-[24px] text-[#8B5CF6]"}),children:[h.jsxs("div",{className:"mb-[10px] mt-[8px] flex flex-col gap-[4px]!",children:[h.jsx("div",{className:"text-[12px] leading-[16px] text-[#64748B]",children:"Employees Inside"}),h.jsx("div",{className:"text-[20px] leading-[24px] font-medium text-[#3C81F6]",children:t?e.total_employees:7500})]}),h.jsx("div",{className:"h-[110px]",children:h.jsx(zl,{data:c,options:u})})]})},ihe="Rs",H4=["bg-blue-500","bg-red-500","bg-purple-700"],bs={title:"Food & Beverages (Static Data)",period:"Today",summary:{totalOrders:247,revenueGenerated:"82K",growthPercentage:8,growthTotalPercentage:0},outlets:[{name:"HP",orders:120,revenue:"45K",percentage:70,color:"bg-[#3C81F6]"},{name:"Adobe",orders:85,revenue:"23K",percentage:50,color:"bg-[#3C81F6]"},{name:"Anarock",orders:42,revenue:"14K",percentage:25,color:"bg-[#3C81F6]"}]};function hm(e,t=null){if(typeof e=="number")return e;if(typeof e=="string"){const n=Number(e.replace("%","").trim());return Number.isNaN(n)?t:n}return t}function Y4(e){if(e==null||e==="")return"0";if(typeof e=="number")return t2(e);const t=Number(e);return Number.isNaN(t)?String(e):t2(t)}function ohe(e){const t=e?.food_beverage_summary?{title:e?.title,period:e?.period,summary:{totalOrders:e?.food_beverage_summary?.total_orders,revenueGenerated:e?.food_beverage_summary?.revenue_generated,growthPercentage:e?.food_beverage_summary?.growth_percentage??e?.food_beverage_summary?.revenue_growth,growthTotalPercentage:e?.food_beverage_summary?.order_growth,currencyType:e?.food_beverage_summary?.currency_type},outlets:e?.chart_data}:e||{},n=t?.summary||{},i=(Array.isArray(t?.outlets)?t.outlets:[]).map((f,p)=>({name:f?.name||f?.outlet_name||f?.tenant_name||f?.company_name||"Unknown",orders:f?.orders??f?.total_orders??f?.count??0,revenue:f?.revenue??f?.revenue_generated??f?.total_revenue??0,percentage:f?.percentage,color:f?.color||H4[p%H4.length]})),o=n?.totalOrders??n?.orders??bs.summary.totalOrders,a=n?.revenueGenerated??n?.revenue??bs.summary.revenueGenerated,s=hm(n?.growthPercentage??n?.revenueGrowth,bs.summary.growthPercentage),l=hm(n?.growthTotalPercentage??n?.orderGrowth,bs.summary.growthTotalPercentage),c=n?.currencyType||n?.currency||ihe,u=i.reduce((f,p)=>f+(Number(p?.orders)||0),0),d=i.map(f=>({...f,percentage:f?.percentage!==null&&f?.percentage!==void 0?Number(f.percentage)||0:u>0?Math.round((Number(f?.orders)||0)/u*100):0}));return{title:t?.title||bs.title,period:t?.period||bs.period,summary:{totalOrders:o,revenueGenerated:a,growthPercentage:s,growthTotalPercentage:l,currencyType:c},outlets:d.length>0?d:bs.outlets}}function U4({data:e,title:t,period:n,icon:r}){const i=ohe(e),o=t||i.title,a=n||i.period,s=r||h.jsx(dpe,{className:"!text-[24px] text-[#FA7E28]"}),l=i.summary.totalOrders??0,c=Y4(i.summary.revenueGenerated),u=hm(i.summary.growthPercentage,0),d=hm(i.summary.growthTotalPercentage,0),f=u>=0,p=d>=0;return h.jsx(Le,{className:"h-[324px]",title:o,period:a,icon:s,children:h.jsxs("div",{className:"flex flex-col h-full",children:[h.jsxs("div",{className:"flex gap-[24px]",children:[h.jsxs("div",{className:"w-full flex flex-col gap-[8px]!",children:[h.jsx("div",{className:"text-[12px] leading-[16px] text-[#64748B]",children:"Total Orders"}),h.jsx("div",{className:"text-[28px] leading-[32px] font-medium text-[#8B5CF6]",children:l}),h.jsxs("div",{className:`w-fit inline-flex items-center gap-[4px] text-[10px] leading-[14px] p-[4px] rounded-[4px] ${p?"text-[#1FA05B] bg-green-50":"text-red-600 bg-red-50"}`,children:[p?h.jsx(Xo,{}):h.jsx(Go,{}),d,"%",h.jsx("span",{children:"from last month"})]})]}),h.jsx("div",{className:"w-full flex justify-end",children:h.jsxs("div",{className:"flex flex-col gap-[8px]",children:[h.jsx("div",{className:"text-[12px] leading-[16px] text-[#64748B] whitespace-nowrap",children:"Revenue Generated"}),h.jsxs("div",{className:"text-[28px] leading-[32px] font-medium text-[#329DFF] whitespace-nowrap",children:[i.summary.currencyType," ",c]}),h.jsxs("div",{className:`w-fit inline-flex items-center gap-[4px] text-[10px] leading-[14px] p-[4px] rounded-[4px] whitespace-nowrap ${f?"text-[#1FA05B] bg-green-50":"text-red-600 bg-red-50"}`,children:[f?h.jsx(Xo,{}):h.jsx(Go,{}),u,"%",h.jsx("span",{children:"from last month"})]})]})})]}),h.jsx("div",{className:"mt-[16px]",children:i.outlets.map((m,g)=>h.jsxs("div",{className:g===i.outlets.length-1?"":"mb-[16px]",children:[h.jsxs("div",{className:"flex justify-between text-sm mb-[8px]",children:[h.jsx("div",{className:"text-[#64748B] text-[12px] leading-[16px]",children:m.name}),h.jsxs("div",{className:"font-medium text-[12px] leading-[16px] flex items-center",children:[h.jsxs("div",{className:"text-[#64748B] inline-block",children:[m.orders," orders"]}),h.jsxs("div",{className:"mx-2 text-[#121212] inline-block",children:[i.summary.currencyType," ",Y4(m.revenue)]})]})]}),h.jsx("div",{className:"h-[11px] bg-gray-100 rounded-full",children:h.jsx("div",{className:`h-[11px] rounded-full ${m.color}`,style:{width:`${m.percentage}%`}})})]},`${m.name}-${g}`))})]})})}function K4({data:e}){const t=e?.amenity_summary?{amenitySummary:{totalBookings:e?.amenity_summary?.total_bookings??0,todayPaidRevenue:e?.amenity_summary?.today_paid_revenue??"0.00",growthPercentage:e?.amenity_summary?.growth_percentage??null,bookingGrowth:e?.amenity_summary?.booking_growth??null,currencyType:e?.amenity_summary?.currency_type??"Rs"},chartData:Array.isArray(e?.chart_data)?e.chart_data.map(m=>({facility_name:m?.facility_name,total_bookings:m?.total_bookings??0,paid_revenue:m?.paid_revenue??"0",isPaid:m?.is_paid===!0})):[]}:e||{},n=t?.amenitySummary||{},i=(Array.isArray(t?.chartData)?t.chartData:[]).map(m=>({...m,isPaid:m?.isPaid===!0})),o=i.length>0&&i.every(m=>m?.isPaid===!1),a=n?.totalBookings||0,s=n?.bookingGrowth;let l=0;if(typeof s=="number")l=s;else if(typeof s=="string"){const m=s.replace("%","").trim(),g=Number(m);l=isNaN(g)?0:g}const c=i.reduce((m,g)=>{const v=g?.total_bookings||0;return m+v},0),u=i.map(m=>{const g=m?.total_bookings||0,v=m?.isPaid?`${n?.currencyType||"Rs"} ${m?.paid_revenue||"0.00"}`:"",x=c>0?Math.round(g/c*100):0;return{name:m?.facility_name||"Unknown",bookings:g,revenue:v,percentage:x,color:"bg-[#3C81F6]",isPaid:m?.isPaid}}),d=n?.growthPercentage;let f=null;if(typeof d=="number")f=d;else if(typeof d=="string"){const m=d.replace("%","").trim(),g=Number(m);f=isNaN(g)?null:g}const p=f!==null?f>=0:!0;return h.jsx(Le,{className:"h-[324px]",title:"Amenities",period:"Today",icon:h.jsx(fpe,{className:"!text-[24px] text-[#8B5CF6]"}),children:h.jsxs("div",{className:"flex flex-col h-full",children:[h.jsxs("div",{className:"flex gap-[24px]",children:[h.jsxs("div",{className:"w-full flex flex-col gap-[8px]!",children:[h.jsx("div",{className:"text-[12px] leading-[16px] text-[#64748B]",children:"Total Bookings"}),h.jsx("div",{className:"text-[28px] leading-[32px] font-medium text-[#8B5CF6]",children:a}),h.jsxs("div",{className:`w-fit inline-flex items-center gap-[4px] text-[10px] leading-[14px] p-[4px] rounded-[4px] ${l>=0?"text-[#1FA05B] bg-green-50":"text-red-600 bg-red-50"}`,children:[l>=0?h.jsx(Xo,{}):h.jsx(Go,{}),l,"%",h.jsx("span",{children:"from last month"})]})]}),!o&&h.jsx("div",{className:"w-full flex justify-end",children:h.jsxs("div",{className:"flex flex-col gap-[8px]",children:[h.jsx("div",{className:"text-[12px] leading-[16px] text-[#64748B] whitespace-nowrap",children:"Revenue Generated"}),h.jsxs("div",{className:"text-[28px] leading-[32px] font-medium text-[#329DFF] whitespace-nowrap",children:[n?.currencyType||"Rs"," ",n?.todayPaidRevenue??"0.00"]}),f!==null&&h.jsxs("div",{className:`w-fit inline-flex items-center gap-[4px] text-[10px] leading-[14px] p-[4px] rounded-[4px] whitespace-nowrap ${p?"text-[#1FA05B] bg-green-50":"text-red-600 bg-red-50"}`,children:[p?h.jsx(Xo,{}):h.jsx(Go,{}),f,"%",h.jsx("span",{children:"from last month"})]})]})})]}),h.jsx("div",{className:"mt-[16px]",children:u.length>0?u.map((m,g)=>h.jsxs("div",{className:g===u.length-1?"":"mb-[16px]",children:[h.jsxs("div",{className:"flex justify-between text-sm mb-[8px]",children:[h.jsx("div",{className:"text-[#64748B] text-[12px] leading-[16px]",children:m?.name}),h.jsxs("div",{className:"font-medium text-[12px] leading-[16px]",children:[h.jsxs("div",{className:"text-[#64748B] inline",children:[m?.bookings," ",m?.bookings<=1?"booking":"bookings"]}),m?.isPaid&&h.jsx("div",{className:"mx-2 text-[#121212] inline",children:m?.revenue})]})]}),h.jsx("div",{className:"h-[11px] bg-gray-100 rounded-full",children:h.jsx("div",{className:`h-[11px] rounded-full ${m?.color}`,style:{width:`${m?.percentage}%`}})})]},g)):h.jsx("div",{className:"flex items-center justify-center h-[120px]",children:h.jsx("div",{className:"text-[12px] text-[#94A3B8]",children:"No amenity usage data available"})})})]})})}Bn.register(Fo,Lo,Wl,Ar,Zr);function q4({data:e=[]}){const t=[{level:"L1",open:55,in_progress:22,on_hold:15,closed:6},{level:"L2",open:45,in_progress:25,on_hold:18,closed:5},{level:"L3",open:58,in_progress:23,on_hold:14,closed:6}],n=e.length>0?e:t,r=[],i=[],o=[],a=[],s=[];for(let u=0;u<n.length;u++)r.push(n[u].level),i.push(Number(n[u].open)),o.push(Number(n[u].in_progress)),a.push(Number(n[u].on_hold)),s.push(Number(n[u].cancelled));const l={labels:r,datasets:[{label:"Open",data:i,backgroundColor:"#3B82F6",borderColor:"#FFFFFF",borderWidth:2,barThickness:38,stack:"tickets"},{label:"In Progress",data:o,backgroundColor:"#F59E0B",borderColor:"#FFFFFF",borderWidth:2,barThickness:38,stack:"tickets"},{label:"On-Hold",data:a,backgroundColor:"#64748B",borderColor:"#FFFFFF",borderWidth:2,barThickness:38,stack:"tickets"},{label:"Cancelled",data:s,backgroundColor:"#FB2C36",borderColor:"#FFFFFF",borderWidth:2,barThickness:38,stack:"tickets"}]},c={responsive:!0,maintainAspectRatio:!1,plugins:{legend:{position:"bottom",labels:{usePointStyle:!1,pointStyle:"rect",padding:12,boxWidth:20,boxHeight:8,color:"#64748B"}},tooltip:{backgroundColor:"#0F172A",titleColor:"#fff",bodyColor:"#fff"}},scales:{x:{stacked:!0,grid:{display:!1},ticks:{color:"#64748B"}},y:{stacked:!0,beginAtZero:!0,grid:{display:!1,color:"#E5E7EB",borderDash:[4,4],drawBorder:!1},ticks:{color:"#64748B",stepSize:1,precision:0,callback:u=>Math.round(u)}}}};return h.jsx(Le,{className:"h-[267px]",title:"Ticket Escalation Levels",period:"Today",icon:h.jsx(z8,{className:"!text-[24px] text-[#3C81F6]"}),children:h.jsx("div",{className:"h-full",children:h.jsx(zl,{data:l,options:c})})})}const ahe=({active:e,payload:t})=>{if(!e||!t||!t.length)return null;const n=t[0],r=n.payload.color;return h.jsx("div",{style:{backgroundColor:"#000000",color:"#ffffff",padding:"8px 10px",borderRadius:"8px",fontSize:"12px"},children:h.jsxs("div",{className:"flex items-center gap-[8px] font-medium",children:[h.jsx("div",{style:{width:"8px",height:"8px",borderRadius:"50%",backgroundColor:r}}),h.jsx("div",{children:n.name}),h.jsx("div",{className:"ml-2",children:n.value})]})})};function G4({data:e=null}){const n=e||{open:12,on_hold:5,cancelled:3,completed:156,in_progress:8,total_complaints:184},r=a=>{const s=Number(a);return isNaN(s)?0:s},i=[{name:"Completed",value:r(n.completed),color:"#10B981"},{name:"Open",value:r(n.open),color:"#3B82F6"},{name:"In Progress",value:r(n.in_progress),color:"#F59E0B"},{name:"On Hold",value:r(n.on_hold),color:"#6B7280"},{name:"Cancelled",value:r(n.cancelled),color:"#EF4444"}],o=r(n.total_complaints);return h.jsx(Le,{className:"h-[267px]",title:"Ticket Status",period:"Today",icon:h.jsx(wf,{className:"!text-[24px] text-[#EF4444]"}),children:h.jsxs("div",{className:"flex h-full items-center gap-[16px]",children:[h.jsxs("div",{className:"w-[202px] h-[170px] relative",children:[h.jsx(Ot,{width:"100%",height:"100%",children:h.jsxs($i,{children:[h.jsx(ai,{data:i,innerRadius:55,outerRadius:85,dataKey:"value",stroke:"#FFFFFF",strokeWidth:2,children:i.map((a,s)=>h.jsx(In,{fill:a.color},s))}),h.jsx(St,{content:a=>h.jsx(Ut,{...a,data:i,children:h.jsx(ahe,{...a})})})]})}),h.jsxs("div",{className:"absolute inset-0 flex flex-col items-center justify-center pointer-events-none",children:[h.jsxs("div",{className:"flex items-baseline text-[18px] leading-[22px] font-medium text-[#121212]",children:[h.jsx("div",{children:r(n.completed)}),h.jsxs("div",{className:"text-[18.18px] leading-[22.22px] text-[#121212]",children:["/",o]})]}),h.jsx("div",{className:"text-[10.1px] leading-[14.14px] text-[#64748B]",children:"Completed"})]})]}),h.jsx("div",{className:"flex-1 space-y-2",children:i.map(a=>h.jsxs("div",{className:"flex items-center justify-between text-[12px] leading-[17px] mt-[12px]",children:[h.jsxs("div",{className:"flex items-center gap-[8px]",children:[h.jsx("div",{className:"h-[7px] w-[16px]",style:{backgroundColor:a.color}}),h.jsx("div",{className:"text-[12px] leading-[16px] text-[#64748B]",children:a.name})]}),h.jsx("div",{className:"text-[#64748B] text-[12px] leading-[16px] font-medium",children:a.value})]},a.name))})]})})}const X4={visitorSummary:{totalVisitorsToday:150,peakTime:"2:00 - 4:00PM",peakCount:50,activeWalkins:18,preApprovedCheckins:3},popupData:{walkins:{currently_inside:18,total_visited_today:58},preApproved:{completed_visits:3,total_expected_today:5}},chart_data:[{hour:10,walkins:22,preApproved:30},{hour:12,walkins:15,preApproved:28},{hour:14,walkins:30,preApproved:38},{hour:16,walkins:45,preApproved:50},{hour:18,walkins:25,preApproved:40}]};function she(e){const t=e>=12?"PM":"AM";let n=e%12;return n===0&&(n=12),`${n} ${t}`}function lhe(e){if(typeof e=="number"&&e>=0&&e<=23)return e;if(typeof e=="string"){const t=e.trim().toUpperCase(),n=t.match(/^(\d{1,2})(?::\d{2})?\s*(AM|PM)$/);if(n){let i=Number(n[1])%12;return n[2]==="PM"&&(i+=12),i}const r=Number(t);if(!Number.isNaN(r)&&r>=0&&r<=23)return r}return null}function che(e=[]){return Array.from({length:24},(t,n)=>{const r=e.find(i=>lhe(i?.hour)===n)||{};return{hour:n,time:she(n),walkins:Number(r?.walkins??0),approved:Number(r?.pre_approved??r?.preApproved??r?.approved??0)}})}function Q4({title:e,color:t,rows:n=[],children:r}){const i=h.jsxs("div",{className:"bg-white rounded-[12px] min-w-[260px] p-[16px] border-[0.5px] border-[#EBEBEB] shadow-[0px_0px_12px_0px_#EAF2FF]",children:[h.jsx("div",{className:"flex items-center gap-[8px] font-medium text-[#121212]",children:h.jsx("div",{children:e??""})}),h.jsx("div",{className:"mt-[16px] pt-[16px] border-t border-dashed border-[#EBEBEB] space-y-[16px]",children:n?.map(({label:o,value:a,valueColor:s})=>h.jsxs("div",{className:"flex justify-between text-[14px] leading-[18px]",children:[h.jsx("div",{className:"text-[#64748B]",children:o??""}),h.jsx("div",{className:"font-semibold",style:{color:s||"#121212"},children:a??0})]},o))})]});return h.jsx(EM,{placement:"right-start",interactive:!0,delay:[100,0],offset:[6,0],appendTo:()=>document.body,maxWidth:"none",render:o=>h.jsx("div",{tabIndex:"-1",...o,children:i}),children:r})}function uhe({active:e,payload:t}){return!e||!t?.length?null:h.jsx("div",{className:"rounded-[8px] bg-[#121212] px-[12px] py-[8px] text-[12px] text-white shadow-lg",children:t.map(n=>h.jsxs("div",{className:"flex items-center gap-[8px]",children:[h.jsx("span",{className:"h-2 w-2 rounded-full",style:{backgroundColor:n.stroke}}),h.jsx("span",{className:"min-w-[82px] text-[#D1D3D4]",children:n.name}),h.jsx("span",{className:"font-semibold",children:n.value})]},n.dataKey))})}function Z4({data:e}){const t=e&&Object.keys(e).length?e:X4,n=t?.visitor_summary?{totalVisitorsToday:t?.visitor_summary?.total_visitors_today??0,peakTime:t?.visitor_summary?.peak_time??"-"}:t?.visitorSummary??{},r=t?.walkins_popup_data?{walkins:{currently_inside:Number(t?.walkins_popup_data?.walkins_inside??0),total_visited_today:Number(t?.walkins_popup_data?.total_walkins??0)},preApproved:{completed_visits:Number(t?.pre_approved_popup_data?.pre_approved_check_ins??0),total_expected_today:Number(t?.pre_approved_popup_data?.total_pre_approved_check_ins??0)}}:t?.popupData??{},i=k.useMemo(()=>{const l=t?.chart_data??[];return che(l.length?l:X4.chart_data)},[t]),{yAxisTicks:o,yAxisMax:a}=k.useMemo(()=>{const l=Math.max(...i.map(u=>Math.max(u.walkins,u.approved))),c=l>0?l:5;return{yAxisTicks:[0,Math.ceil(c/2),c],yAxisMax:c}},[i]),s=new Date().toLocaleTimeString("en-IN",{hour:"2-digit",minute:"2-digit",hour12:!0});return h.jsx(Le,{className:"h-[377px]",title:"Visitor Updates",period:`Today at ${s}`,icon:h.jsx(Ag,{className:"!text-[24px] text-[#8B5CF6]"}),children:h.jsxs("div",{className:"flex flex-col gap-[24px]",children:[h.jsxs("div",{className:"grid grid-cols-2 gap-y-4 gap-x-6",children:[h.jsxs("div",{className:"flex flex-col gap-[8px]!",children:[h.jsx("div",{className:"text-[10px] text-[#64748B]",children:"Total Visitors"}),h.jsx("div",{className:"text-[20px] font-medium text-[#08B6D4]",children:n?.totalVisitorsToday??0})]}),h.jsxs("div",{className:"flex flex-col gap-[8px]!",children:[h.jsx("div",{className:"text-[10px] text-[#64748B]",children:"Peak Time"}),h.jsx("div",{className:"text-[20px] font-medium text-[#8B5CF6]",children:n?.peakTime??"-"})]}),h.jsxs("div",{className:"mt-2 flex flex-col gap-[8px]!",children:[h.jsx("div",{className:"text-[10px] text-[#64748B]",children:"Active Walk-ins"}),h.jsxs("div",{className:"flex items-baseline text-xl font-medium leading-[32px]",children:[h.jsx("div",{className:"text-[28px] text-[#1FA05B] leading-[32px]",children:r?.walkins?.currently_inside??0}),h.jsx(Q4,{title:"Active Walk-ins",color:"text-[#1FA05B]",rows:[{label:"Currently Inside",value:r?.walkins?.currently_inside??0,valueColor:"#1FA05B"},{label:"Total Visited Today",value:r?.walkins?.total_visited_today??0}],children:h.jsxs("div",{className:"text-[#64748B] cursor-pointer text-[20px] leading-[32px]",children:["/",r?.walkins?.total_visited_today??0]})})]})]}),h.jsxs("div",{className:"mt-2 flex flex-col gap-[8px]!",children:[h.jsx("div",{className:"text-[10px] text-[#64748B]",children:"Pre-approved Check-ins"}),h.jsxs("div",{className:"flex items-baseline text-xl font-medium leading-[32px]",children:[h.jsx("div",{className:"text-[28px] text-[#E7A015] leading-[32px]",children:r?.preApproved?.completed_visits??0}),h.jsx(Q4,{title:"Pre-approved Check-ins",color:"text-[#E7A015]",rows:[{label:"Completed Visits",value:r?.preApproved?.completed_visits??0,valueColor:"#E7A015"},{label:"Total Expected Check-ins Today",value:r?.preApproved?.total_expected_today??0}],children:h.jsxs("div",{className:"text-[#64748B] cursor-pointer text-[20px] leading-[32px]",children:["/",r?.preApproved?.total_expected_today??0]})})]})]})]}),h.jsx("div",{className:"w-full h-[149px]",children:h.jsx(Ot,{width:"100%",height:"100%",children:h.jsxs(Ox,{data:i??[],margin:{top:5,right:0,left:0,bottom:-10},children:[h.jsx(sr,{stroke:"#E5E7EB",strokeDasharray:"4 4",vertical:!1}),h.jsx(Gn,{dataKey:"time",tickFormatter:(l,c)=>c%4===0?l:"",axisLine:!1,tickLine:!1,tick:{fill:"#121212",fontSize:10,fontWeight:400}}),h.jsx(Rn,{width:24,axisLine:!1,tickLine:!1,allowDecimals:!1,ticks:o,domain:[0,a],tick:{fill:"#64748B",fontSize:10,fontWeight:400}}),h.jsx(St,{content:l=>h.jsx(Ut,{...l,data:i,children:h.jsx(uhe,{...l})})}),h.jsx(da,{type:"monotone",dataKey:"walkins",stroke:"#22C55E",strokeWidth:2,dot:!1,name:"Walk-ins",isAnimationActive:!1}),h.jsx(da,{type:"monotone",dataKey:"approved",stroke:"#F59E0B",strokeWidth:2,strokeDasharray:"5 5",dot:!1,name:"Pre-approved",isAnimationActive:!1})]})})})]})})}function dhe(){return h.jsxs(h.Fragment,{children:[h.jsxs("div",{className:"px-[20px] grid grid-cols-1 lg:grid-cols-[minmax(0,1fr)_minmax(0,2fr)] gap-[24px] mt-6 auto-rows-fr",children:[h.jsx(z4,{}),h.jsx(V4,{})]}),h.jsxs("div",{className:"px-[20px] grid grid-cols-1 lg:grid-cols-3 gap-[24px] mt-6 auto-rows-fr",children:[h.jsx("div",{className:"mt-[-115px]",children:h.jsx(Z4,{})}),h.jsx(G4,{}),h.jsx(q4,{})]}),h.jsxs("div",{className:"px-[20px] grid grid-cols-1 lg:grid-cols-3 gap-[24px] mt-6 auto-rows-fr",children:[h.jsx(tM,{}),h.jsx(K4,{}),h.jsx(U4,{})]})]})}function J4({data:e=null}){const t={total_entries:79.6,entries:59350,exit:40950},n=e&&Object.keys(e).length>0?e:t,r=c=>{const u=Number(c);return isNaN(u)?0:u},i=r(n.entries),o=r(n.exit),a=e&&Object.keys(e).length>0&&Number(e.entries)===0&&Number(e.exit)===0,s=[{name:"Entries",value:i,color:"#8B5CF6"},{name:"Exit",value:o,color:"#329DFF"}],l=r(n.total_entries);return h.jsx(kt,{className:"h-[362px]",title:"Access Overview",titleWeight:"semi-bold",children:a?h.jsx("div",{className:"h-[300px] flex items-center justify-center",children:h.jsx(Vt,{title:"No access Point Found",description:"Catch up all the data. Change the date range to see the data."})}):h.jsxs("div",{className:"flex flex-col items-center mt-[16px]",children:[h.jsxs("div",{className:"relative w-[212px] h-[212px]",children:[h.jsx("div",{className:"absolute inset-0 flex items-center justify-center",children:h.jsx("div",{className:"w-[130px] h-[130px] rounded-full shadow-[0px_12px_35px_rgba(0,0,0,0.12)]"})}),h.jsx("div",{className:"h-[212px]",children:h.jsx(Ot,{width:"100%",height:"100%",children:h.jsxs($i,{children:[h.jsx(ai,{data:s,dataKey:"value",innerRadius:65,outerRadius:100,startAngle:360,endAngle:-180,paddingAngle:1,stroke:"transparent",children:s.map((c,u)=>h.jsx(In,{fill:c.color},u))}),h.jsx(St,{content:c=>h.jsx(Ut,{...c,data:s,children:h.jsx(Rr,{...c})})})]})})}),h.jsxs("div",{className:"absolute inset-0 flex flex-col items-center justify-center pointer-events-none",children:[h.jsx("div",{className:"text-[22px] leading-[27px] font-medium text-[#121212]",children:l}),h.jsx("div",{className:"text-[12px] leading-[17px] text-[#64748B]",children:"Total Access"})]})]}),h.jsxs("div",{className:"mt-[28px] flex justify-between w-full px-[20px]",children:[h.jsxs("div",{className:"flex flex-col items-center",children:[h.jsxs("div",{className:"flex items-center gap-[6px]",children:[h.jsx("div",{className:"w-[14px] h-[6px] bg-[#8B5CF6]"}),h.jsx("div",{className:"text-[12px] leading-[16px] text-[#64748B]",children:"Entries"})]}),h.jsx("div",{className:"text-[18px] font-medium text-[#8B5CF6] mt-[4px]",children:i.toLocaleString()})]}),h.jsxs("div",{className:"flex flex-col items-center",children:[h.jsxs("div",{className:"flex items-center gap-[6px]",children:[h.jsx("div",{className:"w-[14px] h-[6px] bg-[#329DFF]"}),h.jsx("div",{className:"text-[12px] leading-[16px] text-[#64748B]",children:"Exit"})]}),h.jsx("div",{className:"text-[18px] font-medium text-[#329DFF] mt-[4px]",children:o.toLocaleString()})]})]})]})})}function eF({title:e="Access",data:t=[],height:n="h-[362px]"}){const r=i=>i==null?"0":Number(i).toLocaleString();return h.jsx(kt,{className:n,title:e,titleWeight:"semi-bold",children:h.jsxs("div",{className:"rounded-[12px] overflow-hidden mt-[16px]",children:[h.jsxs("div",{className:"grid grid-cols-2 bg-[#F8FAFC] py-[8px] px-[12px] text-[12px] leading-[16px] font-medium text-[#64748B]",children:[h.jsx("div",{children:"Point"}),h.jsx("div",{className:"text-right",children:"Access"})]}),t.map((i,o)=>h.jsxs("div",{className:"grid grid-cols-2 p-[12px] text-[14px] border-t border-[#E2E8F0]",children:[h.jsx("div",{className:"text-[12px] leading-[16px] text-[#64748B]",children:i.label}),h.jsx("div",{className:"text-[12px] leading-[16px] text-right font-medium",style:{color:i.color||"#000"},children:r(i.value)})]},o))]})})}function tF({data:e=[]}){const[t,n]=k.useState([]),r=e&&e.length?e:[],i=!e||e.length===0,o=e&&e.length>0&&e.every(c=>Number(c.entries)===0&&Number(c.exit)===0),a=i||o,s=c=>c>=1e3?`${c/1e3}K`:c,l=c=>{n(u=>u.includes(c)?u.filter(d=>d!==c):[...u,c])};return h.jsx(kt,{title:"Access Points Usage",titleWeight:"semi-bold",className:"h-[362px]",children:a?h.jsx("div",{className:"h-[270px] flex items-center justify-center",children:h.jsx(Vt,{title:"No access Point Found",description:"Catch up all the data. Change the date range to see the data."})}):h.jsx("div",{className:"mt-[24px] h-[270px] w-full",children:h.jsx(Ot,{width:"100%",height:"100%",children:h.jsxs(ko,{data:r,barSize:54,margin:{top:0,right:0,left:-20,bottom:0},children:[h.jsx(sr,{strokeDasharray:"8 8",vertical:!1}),h.jsx(lx,{y:0,stroke:"#EBEBEB"}),h.jsx(Gn,{dataKey:"block_name",tick:{fontSize:12,fill:"#64748B"},axisLine:!1,tickLine:!1}),h.jsx(Rn,{tickFormatter:s,tick:{fontSize:12,fill:"#64748B"},axisLine:!1,tickLine:!1}),h.jsx(St,{cursor:!1,content:c=>h.jsx(Ut,{...c,data:r,children:(()=>{if(!c.active||!c.label)return null;const u=r.find(d=>d.block_name===c.label);return h.jsxs("div",{className:"bg-[#111] text-white px-[14px] py-[8px] rounded-[6px] flex flex-col gap-[6px] text-[13px]",children:[h.jsx("div",{className:"font-semibold",children:c.label}),!t.includes("entries")&&h.jsxs("div",{className:"flex items-center gap-[8px]",children:[h.jsx("div",{className:"w-2 h-2 rounded-full bg-[#329DFF]"}),h.jsx("div",{className:"text-[#aaa]",children:"Entries"}),h.jsx("div",{className:"font-bold",children:u?.entries??0})]}),!t.includes("exit")&&h.jsxs("div",{className:"flex items-center gap-[8px]",children:[h.jsx("div",{className:"w-2 h-2 rounded-full bg-[#76BDFF]"}),h.jsx("div",{className:"text-[#aaa]",children:"Exit"}),h.jsx("div",{className:"font-bold",children:u?.exit??0})]})]})})()})}),h.jsx(rl,{verticalAlign:"bottom",height:36,content:()=>{const c=[{key:"entries",label:"Entries",color:"#329DFF"},{key:"exit",label:"Exit",color:"#76BDFF"}];return h.jsx("div",{style:{display:"flex",gap:"20px",justifyContent:"center",marginTop:"20px"},children:c.map((u,d)=>{const f=t.includes(u.key);return h.jsxs("div",{onClick:()=>l(u.key),style:{display:"flex",alignItems:"center",gap:"8px",cursor:"pointer",opacity:f?.4:1},children:[h.jsx("div",{style:{width:"20px",height:"8px",backgroundColor:u.color}}),h.jsx("div",{style:{fontSize:"12px",color:"#64748B"},children:u.label})]},d)})})}}),h.jsx(Gt,{dataKey:"entries",stackId:"a",fill:"#329DFF",hide:t.includes("entries")}),h.jsx(Gt,{dataKey:"exit",stackId:"a",fill:"#76BDFF",hide:t.includes("exit")})]})})})})}function fhe(e){return gt({attr:{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},child:[{tag:"rect",attr:{x:"3",y:"4",width:"18",height:"18",rx:"2",ry:"2"},child:[]},{tag:"line",attr:{x1:"16",y1:"2",x2:"16",y2:"6"},child:[]},{tag:"line",attr:{x1:"8",y1:"2",x2:"8",y2:"6"},child:[]},{tag:"line",attr:{x1:"3",y1:"10",x2:"21",y2:"10"},child:[]}]})(e)}function phe(e){return gt({attr:{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},child:[{tag:"polyline",attr:{points:"6 9 12 15 18 9"},child:[]}]})(e)}function hhe(e){return gt({attr:{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},child:[{tag:"path",attr:{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4"},child:[]},{tag:"polyline",attr:{points:"7 10 12 15 17 10"},child:[]},{tag:"line",attr:{x1:"12",y1:"15",x2:"12",y2:"3"},child:[]}]})(e)}function xs({text:e="Smart Access",Icon:t,iconColor:n="#329DFF"}){return h.jsxs("div",{className:"px-[20px] pt-6",children:[h.jsxs("div",{className:"flex items-center justify-between",children:[h.jsxs("div",{className:"flex items-center gap-[8px]",children:[t?h.jsx("div",{className:"flex items-center justify-center",children:h.jsx(t,{size:20,style:{color:n}})}):null,h.jsx("div",{className:"text-[24px] leading-[32px] font-semibold text-[#121212]",children:e})]}),h.jsxs("div",{className:"flex items-center gap-[12px]",children:[h.jsxs("div",{className:"flex items-center gap-[8px] bg-white px-[16px] py-[8px].5 rounded-[8px] border border-[#EBEBEB] text-sm font-medium text-[#64748B] hover:bg-gray-100 transition-colors cursor-pointer",children:[h.jsx("div",{className:"flex items-center",children:h.jsx(fhe,{size:16})}),h.jsx("div",{children:"Today"}),h.jsx("div",{className:"flex items-center",children:h.jsx(phe,{size:16})})]}),h.jsxs("div",{className:"flex items-center gap-[8px] px-[12px] py-[8px] rounded-[8px] border border-[#EBEBEB] bg-white text-[#7C3AED] text-[14px] font-medium hover:bg-[#E9D5FF] transition cursor-pointer",children:[h.jsx("div",{children:"Export Report"}),h.jsx("div",{className:"flex items-center",children:h.jsx(hhe,{size:16})})]})]})]}),h.jsx("div",{className:"mt-4 border-t border-dashed border-[#E2E8F0]"})]})}function mhe(){return h.jsxs(h.Fragment,{children:[h.jsx(xs,{text:"Smart Access",Icon:spe}),h.jsxs("div",{className:"px-[20px] grid grid-cols-1 lg:grid-cols-3 gap-[24px] mt-6 auto-rows-fr",children:[h.jsx(J4,{}),h.jsx(tF,{})]}),h.jsx("div",{className:"mt-7 px-[20px]"})]})}Bn.register(lm,Ar,Zr);const W1=e=>{const t=Number(e);return Number.isFinite(t)?t:0},ghe={id:"bottomGlow",afterDatasetsDraw(e,t,n){if(!n?.enabled)return;const r=e.getDatasetMeta(0);if(!r?.data?.[0])return;const{ctx:i}=e,{x:o,y:a,innerRadius:s}=r.data[0],l=Math.max(s-2,0),c=a+l*.9,u=i.createRadialGradient(o,c,0,o,c,l*1.08);u.addColorStop(0,n.color??"rgba(186, 230, 253, 0.72)"),u.addColorStop(.3,"rgba(186, 230, 253, 0.4)"),u.addColorStop(.58,"rgba(186, 230, 253, 0.16)"),u.addColorStop(1,"rgba(186, 230, 253, 0)"),i.save(),i.beginPath(),i.arc(o,a,l,0,Math.PI*2),i.clip(),i.fillStyle=u,i.beginPath(),i.ellipse(o,c,l*1.08,l*.52,0,0,Math.PI*2),i.fill(),i.restore()}},vhe={id:"centerText",afterDraw(e,t,n){const{ctx:r}=e,i=e.getDatasetMeta(0);if(!i?.data?.[0])return;const{x:o,y:a}=i.data[0],{top:s="",bottom:l="",topSize:c=24,bottomSize:u=9,topColor:d="#121212",bottomColor:f="#121212"}=n||{};r.save(),r.textAlign="center",r.textBaseline="middle",r.fillStyle=d,r.font=`600 ${c}px Inter, system-ui, -apple-system, Segoe UI, Roboto, sans-serif`,r.fillText(s,o,a-6),r.fillStyle=f,r.font=`500 ${u}px Inter, system-ui, -apple-system, Segoe UI, Roboto, sans-serif`,r.fillText(l,o,a+22),r.restore()}},nF=({title:e="Tickets",icon:t,firstLabel:n="First",firstValue:r=0,firstColor:i="#12B981",secondLabel:o="Second",secondValue:a=0,secondColor:s="#AB0000",growthPercentage:l="+0%",growthText:c="Compared to last month",totalLabel:u="Total",centerTopColor:d="#0F172A",centerBottomColor:f="#64748B",centerTopSize:p,centerBottomSize:m,showBottomGlow:g=!1,bottomGlowColor:v="rgba(186, 230, 253, 0.75)",showEmptyStateWhenZero:x=!1,widgetType:_="",resolvedWidgetType:w="",data:y})=>{const E=y?.title??e;y?.icon;const S=y?.firstLabel??n,P=W1(y?.firstValue??y?.resolved?.current??y?.sold?.current??y?.first?.current??r??0),D=y?.firstColor??i,T=y?.secondLabel??o,I=W1(y?.secondValue??y?.open?.current??y?.unsold?.current??y?.second?.current??a??0),A=y?.secondColor??s,C=y?.growthPercentage??y?.trend_percent??l??"+0%",j=y?.growthText??c,N=y?.totalLabel??u,M=y?.widgetType??_??w,R=y?.centerTopSize??p??(M==="commercial"?34:20),B=y?.centerBottomSize??m??(M==="commercial"?14:10),V=y?.showBottomGlow??g,z=y?.bottomGlowColor??v,W=y?.showEmptyStateWhenZero??x,Q=P+I,G=W1(y?.total_tickets?.current??y?.total_units?.current??y?.total?.current??y?.current??Q),ie=W&&Q===0&&G===0,J={labels:[S,T],datasets:[{data:[P,I],backgroundColor:[D,A],borderWidth:2,hoverOffset:4}]},re={responsive:!0,maintainAspectRatio:!1,cutout:"68%",plugins:{legend:{display:!1},tooltip:{enabled:!1,external:ri()},centerText:{top:`${Q}`,bottom:N,topSize:R,bottomSize:B,topColor:d,bottomColor:f},bottomGlow:{enabled:V,color:z}}},se=[{label:S,value:P,color:D},{label:T,value:I,color:A}],ce=C.toString().includes("+"),de=C.toString().includes("-"),K=ce?"#1FA05B":"#AB0000";return h.jsx(kt,{title:E,className:"h-[362px] leading-[24px]",titleWeight:"semi-bold",childrenClassName:ie?"h-full":"",children:ie?h.jsx("div",{className:"w-full h-full flex items-center justify-center",children:h.jsx(Vt,{})}):h.jsxs("div",{className:"grid grid-cols-12 gap-[16px] items-center",children:[h.jsxs("div",{className:"col-span-5 space-y-[12px]",children:[se.map((U,Z)=>h.jsxs("div",{children:[h.jsx("div",{className:"text-[12px] text-[#64748B] mb-[8px]",children:U.label}),h.jsx("div",{className:"text-[28px] leading-[32px]",style:{color:U.color},children:U.value})]},Z)),h.jsxs("div",{className:`text-[12px] flex gap-[4px] ${M==="commercial"?"mt-[20px]":""} items-center`,style:{color:K},children:[ce&&h.jsx(Xo,{}),de&&h.jsx(Go,{}),h.jsx("div",{children:C.replace("+","").replace("-","")}),h.jsx("div",{className:"text-[#64748B] text-[12px] leading-[14px] ml-[4px] whitespace-nowrap",children:j})]})]}),h.jsx("div",{className:"col-span-7",children:h.jsx("div",{className:`${M==="commercial"?"h-[260px] max-w-[263px]":"h-[158px] w-[158px]"} ml-auto mr-2`,children:h.jsx(fm,{data:J,options:re,plugins:[ghe,vhe]})})})]})})},yhe=({x:e,y:t,payload:n})=>{const r=n.value.split(" ");return h.jsx("g",{transform:`translate(${e},${t})`,children:h.jsx("text",{x:-85,y:0,textAnchor:"start",fill:"#121212",fontSize:14,children:r.map((i,o)=>h.jsx("tspan",{x:-85,dy:o===0?0:16,children:i},o))})})};function rF({data:e=[]}){const t=e&&e.length>0,n=e.map(r=>({name:r.category_name,value:r.total_complaints,color:"#08B6D4"}));return h.jsx(kt,{title:"Tickets per Category",className:"h-[362px]",titleWeight:"semi-bold",childrenClassName:"h-full mt-[24px]!",children:t?h.jsx("div",{className:"w-full h-[262px]",children:h.jsx(Ot,{width:"100%",height:"100%",children:h.jsxs(ko,{data:n,layout:"vertical",margin:{top:0,right:8,left:-20,bottom:0},children:[h.jsx(sr,{strokeDasharray:"3 3",horizontal:!1,stroke:"#E5E7EB"}),h.jsx(Gn,{type:"number",tick:{fill:"#94A3B8",fontSize:12},axisLine:!0,tickLine:!1,tickMargin:10,allowDecimals:!1}),h.jsx(Rn,{type:"category",dataKey:"name",axisLine:!1,tickLine:!1,width:132,tick:h.jsx(yhe,{})}),h.jsx(St,{cursor:{fill:"transparent"},position:{x:300,y:0},allowEscapeViewBox:{x:!0,y:!0},content:r=>r.active?h.jsx(Ut,{...r,data:n,children:h.jsx(Rr,{...r})}):null}),h.jsx(Gt,{dataKey:"value",barSize:36,fill:"#08B6D4"})]})})}):h.jsx(Vt,{title:"No Tickets Found",description:"Catch up all the data. Change the date range to see the data."})})}function z1({icon:e,iconColor:t="#329DFF",title:n,value:r,percentage:i,percentageText:o}){const a=parseFloat(i),s=a>=0,l=s?"#16A34A":"#DC2626";return h.jsxs("div",{className:"relative bg-white !border-[0.5px] !border-[#EBEBEB] !rounded-[12px] !shadow-[0_0_12px_0_#EAF2FF] p-[16px] h-[132px]",children:[h.jsxs("div",{className:"flex items-center gap-[8px]",children:[e&&h.jsx("div",{className:"h-[20px] w-[20px]",style:{color:t,display:"flex",alignItems:"center",justifyContent:"center"},children:h.jsx(e,{className:"h-[20px] w-[20px]"})}),h.jsx("div",{className:"text-[16px] leading-[20px] tracking-[-2%] font-medium text-[#64748B]",children:n})]}),h.jsx("div",{className:"mt-[16px] text-[28px] leading-[32px] font-medium text-[#121212]",children:r}),(i||o)&&h.jsxs("div",{className:"mt-[12px] flex items-center gap-[8px]",children:[i&&h.jsxs("div",{className:"flex items-center gap-[4px] text-[12px] leading-[16px] font-medium",style:{color:l},children:[s?h.jsx(Xo,{}):h.jsx(Go,{}),Math.abs(a),"%"]}),o&&h.jsx("div",{className:"text-[12px] leading-[16px] text-[#64748B]",children:o})]})]})}function bhe(){const e=[{category_name:"Plumbing",total_complaints:12},{category_name:"Electrical Issues",total_complaints:8},{category_name:"Cleaning Services",total_complaints:15}];return h.jsxs(h.Fragment,{children:[h.jsx(xs,{text:"Helpdesk",Icon:Zfe,iconColor:"#12B981"}),h.jsxs("div",{className:"flex gap-[24px] mt-[24px] px-[16px]",children:[h.jsx("div",{className:"w-[380px] h-full space-y-[16px]",children:h.jsx(nF,{title:"Tickets",icon:h.jsx(wf,{className:"h-6 w-6 text-[#EF4444]"}),firstLabel:"Resolved",firstValue:779,firstColor:"#12B981",secondLabel:"Open",secondValue:83,secondColor:"#AB0000",growthPercentage:"+9.1%",growthColor:"#1FA05B",growthText:"Compared to last month",widgetType:"commercial",totalLabel:"Total",centerTopSize:34,centerBottomSize:14,showBottomGlow:!0,showEmptyStateWhenZero:!0})}),h.jsx("div",{className:"flex-1",children:h.jsx(rF,{data:e})})]})]})}const iF=e=>String(e).padStart(2,"0"),oF=(e,t="start")=>e?`${[e.getFullYear(),iF(e.getMonth()+1),iF(e.getDate())].join("-")} ${t==="end"?"23:59:59":"00:00:00"}`:"",aF=({data:e=[],onDateChange:t})=>{const[n,r]=k.useState(new Date),[i,o]=k.useState(!1),s=(v=>{const x=new Date(v);return x.setDate(x.getDate()-6),x})(n),l=v=>{try{return v.toLocaleDateString("en-GB",{day:"2-digit",month:"short"})}catch{return""}},c=v=>{const x=new Date(v),_=new Date(x);_.setDate(_.getDate()-6),t&&t(oF(_,"start"),oF(x,"end"))},u=()=>{const v=new Date(n);v.setDate(v.getDate()-7),r(v),c(v)},d=()=>{const v=new Date(n);v.setDate(v.getDate()+7),r(v),c(v)},f=()=>{o(v=>!v)},p=v=>{const x=v||new Date;r(x),c(x),o(!1)},m=Array.isArray(e)?e:[],g=!m.length||m.every(v=>v.no_of_visitors===0);return h.jsxs(kt,{title:"Weekly Visitor Pattern",period:`${l(s)} - ${l(n)}`,isDateSelector:!0,titleWeight:"semi-bold",className:"h-[360px]",childrenClassName:"mt-6",onPrevClick:u,onNextClick:d,onCalendarClick:f,children:[i&&h.jsx("div",{className:"anarock-datepicker absolute top-[70px] right-[24px] z-50",children:h.jsx(eS,{selected:n,onChange:p,inline:!0,maxDate:new Date,showYearDropdown:!0,scrollableYearDropdown:!0,yearDropdownItemNumber:40})}),g?h.jsx("div",{className:"w-full h-[280px] flex items-center justify-center",children:h.jsx(Vt,{title:"No Visitors Found",description:"Catch up all the data. Change the date range to see the data."})}):h.jsx("div",{className:"w-full h-[280px]",children:h.jsx(Ot,{width:"100%",height:"100%",children:h.jsxs(tj,{data:m,margin:{top:10,right:-10,left:-10,bottom:0},children:[h.jsx("defs",{children:h.jsxs("linearGradient",{id:"colorVisitors",x1:"0",y1:"0",x2:"0",y2:"1",children:[h.jsx("stop",{offset:"0%",stopColor:"#6366F1",stopOpacity:.25}),h.jsx("stop",{offset:"100%",stopColor:"#6366F1",stopOpacity:0})]})}),h.jsx(sr,{strokeDasharray:"3 3",vertical:!1,stroke:"#F1F5F9"}),h.jsx(Gn,{dataKey:"day",type:"category",scale:"point",padding:{left:20,right:20},tick:{fontSize:12,fill:"#64748B"},axisLine:!0,tickLine:!1,tickFormatter:v=>new Date(v).toLocaleDateString("en-GB",{day:"2-digit",month:"short"})}),h.jsx(Rn,{width:35,tick:{fontSize:12,fill:"#64748B"},axisLine:!1,tickLine:!1,allowDecimals:!1,domain:[0,"dataMax + 2"]}),h.jsx(St,{cursor:!1,content:v=>{const{active:x,payload:_,label:w}=v;if(!x||!_?.length)return null;const y=new Date(w).toLocaleDateString("en-GB",{day:"2-digit",month:"short"});return h.jsx(Ut,{...v,data:m,children:h.jsx(Rr,{active:x,payload:_,label:y})})}}),h.jsx(hx,{type:"monotone",dataKey:"no_of_visitors",stroke:"#6366F1",strokeWidth:2,fill:"url(#colorVisitors)",dot:{r:5,stroke:"#6366F1",strokeWidth:2,fill:"#fff"},activeDot:v=>{const{cx:x,cy:_,stroke:w}=v;return h.jsxs("g",{children:[h.jsx("circle",{cx:x,cy:_,r:6,fill:"#fff",stroke:"#6466F1",strokeWidth:2}),h.jsx("circle",{cx:x,cy:_,r:2.5,fill:"#6466F1"})]})}})]})})})]})},xhe=[{building_name:"Google",no_of_visitors:1e3},{building_name:"Uber",no_of_visitors:3500},{building_name:"ANAROCK",no_of_visitors:2e3},{building_name:"Flipkart",no_of_visitors:8e3},{building_name:"HP",no_of_visitors:1650}],sF=({data:e,title:t,bar:n})=>{const r=Array.isArray(e)&&e?.length===0,i=e==null?xhe:Array.isArray(e)?e:[];return h.jsx(kt,{title:t||"Organisation Wise Visitors",titleWeight:"semi-bold",className:"h-[360px]",childrenClassName:"mt-6",children:h.jsx("div",{className:"w-full h-[260px] flex items-center justify-center",children:r?h.jsx(Vt,{title:t||"Organisation Wise Visitors",description:"Catch up all the data. Change the date range to see the data."}):h.jsx(Ot,{width:"100%",height:"100%",children:h.jsxs(ko,{data:i||[],margin:{top:10,right:10,left:10,bottom:-10},barCategoryGap:35,children:[h.jsx(sr,{strokeDasharray:"3 3",vertical:!1,stroke:"#F1F5F9"}),h.jsx(Gn,{dataKey:"building_name",tick:{fontSize:12,fill:"#64748B"},axisLine:!0,tickLine:!1}),h.jsx(Rn,{width:40,tick:{fontSize:12,fill:"#64748B"},axisLine:!1,tickLine:!1,allowDecimals:!1}),h.jsx(St,{cursor:!1,content:o=>o.active?h.jsx(Ut,{...o,data:i,children:h.jsx(Rr,{...o})}):null}),h.jsx(Gt,{dataKey:"no_of_visitors",name:"Visitors",maxBarSize:55,fill:n||"#3C81F6"})]})})})})};function whe(){const e=[{day:"2026-03-05",no_of_visitors:0},{day:"2026-03-06",no_of_visitors:0},{day:"2026-03-07",no_of_visitors:0},{day:"2026-03-08",no_of_visitors:14},{day:"2026-03-09",no_of_visitors:0},{day:"2026-03-10",no_of_visitors:0},{day:"2026-03-11",no_of_visitors:0}];return h.jsxs(h.Fragment,{children:[h.jsx(xs,{text:"Visitors",Icon:Qfe,iconColor:"#884EA7"}),h.jsxs("div",{className:"grid grid-cols-2 gap-[24px] mt-[24px]",children:[h.jsx(z1,{icon:upe,iconColor:"#329DFF",title:"Visitors Expected",value:"1,247",percentage:"+11.0%",percentageText:"Compared to last month"}),h.jsx(z1,{icon:Kfe,iconColor:"#1FA05B",title:"Visitors Inside",value:"800",percentageText:"Across organisations"})]}),h.jsxs("div",{className:"grid grid-cols-2 gap-[24px] mt-[24px]",children:[h.jsx(aF,{data:e}),h.jsx(sF,{})]}),h.jsx("div",{})]})}function Ro({data:e}){return h.jsx("div",{className:"h-full",children:e.map((t,n)=>{const r=parseFloat(t.delta),i=r>=0;return h.jsx(Le,{iconClassName:"!gap-[8px]",title:h.jsx("div",{className:"text-[#64748B]",children:t.title}),icon:h.jsx(t.Icon,{className:"h-[20px] w-[20px]",style:{color:t.iconColor||"#000000"}}),className:`${t?.widget==="amenities"?"h-[139px]":"h-[124px]"}`,children:h.jsxs("div",{className:`flex flex-col gap-[8px] ${t?.widget==="amenities"?"mt-[3.5px]":"mt-0"}`,children:[h.jsx("div",{className:"text-[28px] leading-[32px] font-medium text-[#121212]",children:t.value}),h.jsxs("div",{className:`flex items-center text-[12px] leading-[16px] ${t.delta?"gap-[8px]":""}`,children:[t.delta&&h.jsxs("div",{className:`flex items-center gap-[4px] px-[6px] py-[2px] rounded-[4px] font-medium
|
|
481
481
|
${i?"text-[#1FA05B] bg-[#F7FEFA]":"text-[#E11D48] bg-[#FBF4F4]"}
|
|
482
482
|
`,children:[i?h.jsx(Xo,{}):h.jsx(Go,{}),Math.abs(r),"%"]}),h.jsx("div",{className:t.deltaColor?`text-[${t.deltaColor}] font-[600]`:"text-[#64748B]",children:t.deltaLabel})]})]})},n)})})}const _he=[{facility_name:"Table Tennis",total_booking:5},{facility_name:"Gym",total_booking:12},{facility_name:"Meeting Room A",total_booking:3},{facility_name:"Conference Hall",total_booking:8}],Ehe=({x:e,y:t,payload:n})=>h.jsx("foreignObject",{x:(e||0)-80,y:(t||0)-18,width:80,height:40,children:h.jsx("div",{className:"text-[12px] leading-[16px] text-[#121212]",style:{width:"80px",whiteSpace:"normal",wordBreak:"break-word",textAlign:"left"},children:n?.value||""})});function lF({data:e,bar:t}){const n=Array?.isArray(e)&&e?.length===0,i=(e==null?_he:Array?.isArray(e)?e:[]).map(o=>({...o,name:o.facility_name,color:"#8B5CF6"}));return h.jsx(Le,{title:"Bookings",icon:h.jsx(npe,{size:18,className:"text-[#DBB467]"}),className:"h-[288px]",children:h.jsx("div",{className:"w-full h-full flex items-center justify-center",children:n?h.jsx(Vt,{title:"No Booking Found",description:"Catch up all the data. Change the date range to see the data."}):h.jsx(Ot,{width:"100%",height:"100%",children:h.jsxs(ko,{data:i||[],layout:"vertical",margin:{top:0,right:10,left:-12,bottom:0},children:[h.jsx(Gn,{type:"number",allowDecimals:!1,tick:{fill:"#64748B",fontSize:12},axisLine:!0,tickLine:!1}),h.jsx(Rn,{type:"category",dataKey:"facility_name",axisLine:!1,tickLine:!1,width:100,tick:h.jsx(Ehe,{})}),h.jsx(St,{cursor:{fill:"transparent"},position:{x:300,y:0},allowEscapeViewBox:{x:!0,y:!0},content:o=>o.active?h.jsx(Ut,{...o,data:i,children:h.jsx(Rr,{...o})}):null}),h.jsx(Gt,{dataKey:"total_booking",barSize:40,fill:t||"#8B5CF6"})]})})})})}const She=[{building_name:"Google",no_of_booking:1},{building_name:"Uber",no_of_booking:2},{building_name:"ANAROCK",no_of_booking:4},{building_name:"Flipkart",no_of_booking:2},{building_name:"HP",no_of_booking:1}];function cF({data:e}){const t=Array.isArray(e)&&e?.length===0,n=e==null?She:Array.isArray(e)?e:[];return h.jsx(kt,{title:"Booking Trend by Organisation",titleWeight:"semi-bold",className:"h-[362px]",children:h.jsx("div",{className:"w-full h-[265px] mt-[28px] flex items-center justify-center",children:t?h.jsx(Vt,{title:"No Booking Found",description:"Catch up all the data. Change the date range to see the data."}):h.jsx(Ot,{width:"100%",height:"100%",children:h.jsxs(ko,{data:n||[],margin:{top:0,right:0,left:-30,bottom:0},children:[h.jsx(sr,{strokeDasharray:"3 3",vertical:!1,stroke:"#E5E7EB"}),h.jsx(Gn,{dataKey:"building_name",axisLine:!1,tickLine:!1,tick:{fill:"#64748B",fontSize:12}}),h.jsx(Rn,{allowDecimals:!1,axisLine:!1,tickLine:!1,tick:{fill:"#64748B",fontSize:12},tickFormatter:r=>`${r??0}`}),h.jsx(St,{cursor:!1,allowEscapeViewBox:{x:!0,y:!0},content:r=>r.active?h.jsx(Ut,{...r,data:n,children:h.jsx(Rr,{...r})}):null}),h.jsx(Gt,{dataKey:"no_of_booking",barSize:54,fill:"#12B981"})]})})})})}const Ohe=[{facility_name:"Table Tennis",paid_revenue:"24000.00"},{facility_name:"Games Room",paid_revenue:"14000.00"},{facility_name:"Badminton",paid_revenue:"10000.00"},{facility_name:"GYM",paid_revenue:"4000.00"}],mm=["#3C81F6","#60A5FA","#95BFFA","#BEDAFE","#DAE6FC"];function uF({data:e,currencyType:t}){const n=Array?.isArray(e)&&e?.length===0,r=e??Ohe,i=Array?.isArray(r)&&r?.length>0?r?.map(l=>({name:l?.facility_name||"Unknown",value:Number(l?.paid_revenue)||0})):[],a=(i?.length>0?i?.every(l=>l?.value===0):!1)?i?.map((l,c)=>({...l,value:c===0?1:0})):i,s=l=>`${t||"Rs"} ${l?.toLocaleString?.("en-IN")||0}`;return h.jsx(kt,{title:"Amenity Wise Revenue",titleWeight:"semi-bold",className:"h-[362px]",children:h.jsx("div",{className:"grid grid-cols-12 gap-[24px] items-center h-full mt-[16px]",children:n?h.jsx("div",{className:"col-span-12 flex items-center justify-center h-[240px]",children:h.jsx(Vt,{title:"No Amenity Found",description:"Catch up all the data. Change the date range to see the data."})}):h.jsxs(h.Fragment,{children:[h.jsx("div",{className:"col-span-6 h-[240px] w-full max-w-[240px]",children:h.jsx(Ot,{width:"100%",height:"100%",children:h.jsxs($i,{children:[h.jsx(ai,{data:a||[],dataKey:"value",nameKey:"name",cx:"50%",cy:"50%",outerRadius:95,stroke:"#fff",strokeWidth:1,children:a?.map?.((l,c)=>h.jsx(In,{fill:mm?.[c%mm?.length]},`cell-${c}`))}),h.jsx(St,{cursor:!1,allowEscapeViewBox:{x:!0,y:!0},content:l=>l.active?h.jsx(Ut,{...l,data:a,children:h.jsx(Rr,{...l,formatter:c=>s(c)})}):null})]})})}),h.jsx("div",{className:"col-span-6",children:h.jsxs("div",{className:"rounded-[12px] !overflow-hidden border border-[#E2E8F0] !border-r-1 border-r-[#E2E8F0]! !pr-0 !mr-0",children:[h.jsxs("div",{className:"grid grid-cols-2 px-[12px] py-[8px] bg-[#EBEBEB] text-[12px] leading-[16px] font-semibold text-[#64748B]",children:[h.jsx("div",{children:"Amenity"}),h.jsx("div",{className:"text-right",children:"Revenue"})]}),h.jsx("div",{className:"divide-y divide-[#F1F5F9] max-h-[238px] overflow-y-auto hide-scrollbar",children:i?.map?.((l,c)=>h.jsxs("div",{className:"grid grid-cols-2 px-[16px] py-[16px] text-[14px] text-[#121212]",children:[h.jsxs("div",{className:"flex items-center gap-[12px]",children:[h.jsx("span",{className:"w-[16px] h-[7px]",style:{backgroundColor:mm?.[c%mm?.length]}}),h.jsx("span",{className:"text-[#64748B] text-[12px] leading-[16px]",children:l?.name||"Unknown"})]}),h.jsx("div",{className:"text-right text-[12px] leading-[16px] text-[#64748B]",children:s(l?.value||0)})]},l?.name||c))})]})})]})})})}function Che(){return h.jsxs(h.Fragment,{children:[h.jsx(xs,{text:"Amenities",Icon:epe,iconColor:"#F59D0D"}),h.jsxs("div",{className:"p-[16px] grid grid-cols-2 mt-[24px] gap-[24px]",children:[h.jsxs("div",{className:"grid grid-cols-2 gap-[24px]",children:[h.jsx(Ro,{data:[{title:"Total Bookings",value:145,delta:"+11.0%",deltaLabel:"Compared to last month",Icon:cpe,iconColor:"#1FA05B",iconBg:"bg-emerald-50"}]}),h.jsx(Ro,{data:[{title:"Utilisation Rate",value:"73%",delta:"+11.0%",deltaLabel:"Compared to last month",Icon:ope,iconColor:"#329DFF"}]}),h.jsx(Ro,{data:[{title:"Most Popular",value:"Table Tennis",delta:"+11.0%",deltaLabel:"Compared to last month",Icon:R4,iconColor:"#FA7E28"}]}),h.jsx(Ro,{data:[{title:"Pending Approvals",value:23,delta:"-8.0%",deltaLabel:"Compared to last month",Icon:M4,iconColor:"#AB0000"}]})]}),h.jsx(lF,{})]}),h.jsxs("div",{className:"grid grid-cols-2 gap-[24px] px-[16px]",children:[h.jsx(cF,{}),h.jsx(uF,{})]})]})}const gm=["#8CB33E","#F59E0B","#3B82F6","#06B6D4","#CFCFCF"],khe=[{asset_group_name:"Lifts",asset_count:3},{asset_group_name:"Fire Systems",asset_count:16},{asset_group_name:"Generators",asset_count:16},{asset_group_name:"HVAC",asset_count:24},{asset_group_name:"Others",asset_count:97}],dF=({rows:e,totalAssets:t})=>{const n=k.useMemo(()=>e?e.length===0?[]:e.map((i,o)=>({name:i.asset_group_name,facility_name:i.asset_group_name,value:i.asset_count||0,fill:gm[o%gm.length]})):khe.map((i,o)=>({name:i.asset_group_name,facility_name:i.asset_group_name,value:i.asset_count||0,fill:gm[o%gm.length]})),[e]),r=t??n.reduce((i,o)=>i+o.value,0);return e&&e.length===0?h.jsx(kt,{title:"Assets by Type",titleWeight:"semi-bold",className:"h-[362px]",children:h.jsx("div",{className:"flex items-center justify-center h-[260px]",children:h.jsx(Vt,{title:"No Assets Found",description:"Catch up all the data. Change the date range to see the data."})})}):h.jsx(kt,{title:"Assets by Type",titleWeight:"semi-bold",className:"h-[362px]",children:h.jsxs("div",{className:"flex items-center justify-between h-full mt-[16px]",children:[h.jsxs("div",{className:"relative w-[252px] h-[273px]",children:[h.jsx(Ot,{width:"100%",height:"100%",children:h.jsxs($i,{children:[h.jsx(ai,{data:n,dataKey:"value",cx:"50%",cy:"50%",innerRadius:60,outerRadius:90,paddingAngle:2,stroke:"#FFFFFF",strokeWidth:2,startAngle:90,endAngle:-270,isAnimationActive:!1,children:n.map((i,o)=>h.jsx(In,{fill:i.fill},o))}),h.jsx(St,{cursor:!1,allowEscapeViewBox:{x:!0,y:!0},content:i=>i.active?h.jsx(Ut,{...i,data:n,children:h.jsx(Rr,{...i})}):null})]})}),h.jsxs("div",{className:"absolute inset-0 flex flex-col items-center justify-center pointer-events-none",children:[h.jsx("div",{className:"text-[24px] leading-[33px] font-medium text-[#121212]",children:r}),h.jsx("div",{className:"text-[12px] leading-[17px] text-[#64748B] mt-[2px]",children:"Total Assets"})]})]}),h.jsx("div",{className:"flex-1 max-w-[280px]",children:h.jsxs("div",{className:"rounded-[12px] overflow-hidden bg-white border border-[#E2E8F0] !border-r-1 border-r-[#E2E8F0]! !pr-0 !mr-0",children:[h.jsxs("div",{className:"flex items-center justify-between px-[16px] py-[12px] bg-[#F8FAFC]",children:[h.jsx("div",{className:"text-[12px] font-medium text-[#64748B]",children:"Asset"}),h.jsx("div",{className:"text-[12px] font-medium text-[#64748B]",children:"Count"})]}),n.map((i,o)=>h.jsxs("div",{className:"max-h-[205px] overflow-y-auto hide-scrollbar flex items-center justify-between px-[16px] py-[12px] border-t border-[#F1F5F9]",children:[h.jsxs("div",{className:"flex items-center gap-[8px]",children:[h.jsx("div",{className:"w-[16px] h-[7px]",style:{backgroundColor:i.fill}}),h.jsx("div",{className:"text-[13px] text-[#475569]",children:i.name})]}),h.jsx("div",{className:"text-[13px] text-[#64748B]",children:i.value})]},o))]})})]})})},fF=({data:e,title:t})=>{const[n,r]=k.useState({}),i=[{name:"Lifts",Cancelled:55,Closed:45,Open:50,OnHold:20,InProgress:10},{name:"Fire Systems",Cancelled:15,Closed:45,Open:15,OnHold:8,InProgress:5},{name:"Generators",Cancelled:12,Closed:45,Open:75,OnHold:18,InProgress:7},{name:"HVAC",Cancelled:45,Closed:80,Open:30,OnHold:22,InProgress:12},{name:"Others",Cancelled:18,Closed:18,Open:45,OnHold:9,InProgress:4}],o=k.useMemo(()=>e?Array.isArray(e)&&e.length===0?[]:e:i,[e]),a=s=>{const{dataKey:l}=s;r(c=>({...c,[l]:!c[l]}))};return Array.isArray(e)&&e.length===0?h.jsx(kt,{title:t||"Maintenance Status",titleWeight:"semi-bold",className:"h-[362px]",children:h.jsx("div",{className:"w-full h-[260px] flex items-center justify-center",children:h.jsx(Vt,{title:"No Maintenance Assets Status Found",description:"Catch up all the data. Change the date range to see the data."})})}):h.jsx(kt,{title:t||"Maintenance Status",titleWeight:"semi-bold",className:"h-[362px]",children:h.jsx("div",{className:"w-full h-[260px] flex items-center justify-center",children:Array.isArray(e)&&e.length===0?h.jsx("div",{className:"text-[#94A3B8] text-sm",children:"No Data Found"}):h.jsx("div",{className:`relative w-full ${t?"h-[261px]":"h-[297px]"} mt-[20px]`,children:h.jsx(Ot,{width:"100%",height:"100%",children:h.jsxs(ko,{data:o,barSize:54,barCategoryGap:"40%",margin:{top:20,right:20,left:-20,bottom:0},children:[h.jsx(sr,{strokeDasharray:"3 3",vertical:!1,stroke:"#E2E8F0"}),h.jsx(Gn,{dataKey:"name",tick:{fill:"#64748B",fontSize:12},axisLine:!1,tickLine:!1}),h.jsx(Rn,{tick:{fill:"#64748B",fontSize:12},axisLine:!1,tickLine:!1,allowDecimals:!1}),h.jsx(St,{cursor:{fill:"rgba(148, 163, 184, 0.12)"},allowEscapeViewBox:{x:!0,y:!0},content:s=>!s.active||!s.payload||!s.payload.length?null:h.jsx(Ut,{...s,data:o,children:h.jsxs("div",{className:"bg-[#121212] rounded-[10px] px-[14px] py-[10px] text-[12px] text-white",children:[h.jsx("div",{className:"mb-[6px] font-semibold",children:s.label}),s.payload.map((l,c)=>{const u=l.color||l.fill||"#fff";return h.jsxs("div",{className:"flex items-center gap-[6px]",children:[h.jsx("span",{className:"w-2 h-2 rounded-full inline-block",style:{backgroundColor:u}}),h.jsx("span",{className:"text-[#D1D3D4]",children:l.name}),h.jsx("span",{className:"text-white font-semibold",children:l.value})]},c)})]})})}),h.jsx(rl,{verticalAlign:"bottom",align:"center",onClick:a,content:({payload:s})=>h.jsx("div",{className:"flex items-center justify-center gap-[16px] pt-4 flex-wrap",children:s.map((l,c)=>h.jsxs("div",{onClick:()=>a({dataKey:l.dataKey}),className:"flex items-center gap-[8px] cursor-pointer",children:[h.jsx("div",{style:{width:"16px",height:"8px",backgroundColor:n[l.dataKey]?"#CBD5E1":l.color}}),h.jsx("span",{style:{fontSize:"12px",color:n[l.dataKey]?"#CBD5E1":"#64748B"},children:l.value})]},c))})}),h.jsx(Gt,{dataKey:"Open",stackId:"a",fill:"#3B82F6",hide:n.Open}),h.jsx(Gt,{dataKey:"Closed",stackId:"a",fill:"#10B981",hide:n.Closed}),h.jsx(Gt,{dataKey:"Cancelled",stackId:"a",fill:"#B91C1C",hide:n.Cancelled}),h.jsx(Gt,{dataKey:"OnHold",stackId:"a",fill:"#64748B",hide:n.OnHold,name:"On-Hold"}),h.jsx(Gt,{dataKey:"InProgress",stackId:"a",fill:"#F59E0B",hide:n.InProgress,name:"In Progress"})]})})})})})};function Phe(){return h.jsxs(h.Fragment,{children:[h.jsx(xs,{text:"Asset Management",Icon:ape,iconColor:"#A74E8A"}),h.jsxs("div",{className:"grid grid-cols-2 mt-4 gap-[24px]",children:[h.jsx(dF,{}),h.jsx(fF,{})]})]})}function pF({data:e}){const t=[{name:"Completed",value:Number(e?.completed||0),color:"#12B981"},{name:"Not - Completed",value:Number(e?.not_completed||0),color:"#F69E0A"},{name:"Missed",value:Number(e?.missed||0),color:"#EF4444"}],n=Number(e?.completed||0)+Number(e?.not_completed||0)+Number(e?.missed||0),r=Number(e?.completed||0);return h.jsx(kt,{title:"Patrol Status",className:"h-[362px]",titleWeight:"semi-bold",children:h.jsxs("div",{className:"flex flex-col items-center justify-center",children:[h.jsxs("div",{className:"w-[215px] h-[182px] relative",children:[h.jsx(Ot,{width:"100%",height:"100%",children:h.jsxs($i,{children:[h.jsx(ai,{data:t,innerRadius:60,outerRadius:90,paddingAngle:2,dataKey:"value",nameKey:"name",children:t.map((i,o)=>h.jsx(In,{fill:i.color},`cell-${o}`))}),h.jsx(St,{cursor:!1,allowEscapeViewBox:{x:!0,y:!0},content:i=>i.active?h.jsx(Ut,{...i,data:t,children:h.jsx(Rr,{...i})}):null})]})}),h.jsxs("div",{className:"absolute inset-0 flex flex-col items-center justify-center pointer-events-none",children:[h.jsxs("div",{className:"font-medium text-[19.35px] leading-[23.65px]",children:[r,"/",n]}),h.jsx("div",{className:"text-[10.75px] leading-[15.05px] text-[#64748B]",children:"Completed"})]})]}),h.jsx("div",{className:"flex flex-col w-full text-[14px]",children:t.map((i,o)=>h.jsxs("div",{className:`flex items-center justify-between py-[10px] ${o!==t.length-1?"border-b border-[#F1F5F9]":""}`,children:[h.jsxs("div",{className:"flex items-center gap-[10px]",children:[h.jsx("div",{className:"inline-block w-[16px] h-[7px]",style:{backgroundColor:i.color}}),h.jsx("div",{className:"leading-[16.09px] text-[12.07px] text-[#64748B]",children:i.name})]}),h.jsx("div",{className:"leading-[16.09px] text-[12.07px] text-[#64748B]",children:i.value})]},i.name))})]})})}function hF({incidentReports:e,incidentReportsDetails:t}){const n=Number(e?.open||0),r=Number(e?.in_progress||0),i=Number(e?.closed||0);return h.jsx(kt,{title:"Incident Reports",className:"h-[362px]",titleWeight:"semi-bold",children:h.jsxs("div",{children:[h.jsxs("div",{className:"flex w-full text-center gap-[16px] mt-[24px]",children:[h.jsxs("div",{className:"flex-1 flex flex-col items-center justify-center bg-[#FBF4F4] h-[76px] rounded",children:[h.jsx("div",{className:"text-[24px] leading-[28px] font-medium text-[#AB0000]",children:n}),h.jsx("div",{className:"text-[12px] leading-[16px] text-[#AB0000]",children:"Open"})]}),h.jsxs("div",{className:"flex-1 flex flex-col items-center justify-center bg-[#FFFBF2] h-[76px] rounded",children:[h.jsx("div",{className:"text-[24px] leading-[28px] font-medium text-[#F2A815]",children:r}),h.jsx("div",{className:"text-[12px] leading-[16px] text-[#F2A815]",children:"In-progress"})]}),h.jsxs("div",{className:"flex-1 flex flex-col items-center justify-center bg-[#F7FEFA] h-[76px] rounded",children:[h.jsx("div",{className:"text-[24px] leading-[28px] font-medium text-[#1FA05B]",children:i}),h.jsx("div",{className:"text-[12px] leading-[16px] text-[#1FA05B]",children:"Closed"})]})]}),h.jsx("div",{className:"mt-4 space-y-2",children:t?.length>0?t.map((o,a)=>{const s=o?.escalation_level==="Danger"?"text-[#AB0000]":o?.escalation_level==="High"?"text-[#E7A015]":"text-[#1FA05B]";return h.jsxs("div",{className:"flex items-center justify-between p-[12px] bg-[#FAFBFD] rounded-md",children:[h.jsx("div",{className:"flex items-center gap-[8px]",children:h.jsx("div",{className:"text-gray-700 font-medium",children:o?.incident_reporting_id})}),h.jsx("div",{className:`!text-[12px] font-semibold flex items-center gap-[4px] ${s}`,children:h.jsxs("div",{children:[o?.escalation_value," - ",o?.escalation_level]})})]},a)}):h.jsx(h.Fragment,{})})]})})}function Dhe(){return h.jsxs(h.Fragment,{children:[h.jsx(xs,{text:"Guard Petrol",Icon:lpe,iconColor:"#AB0000"}),h.jsxs("div",{className:"px-[16px] grid grid-cols-3 gap-[24px] mt-4",children:[h.jsx(pF,{}),h.jsx(hF,{}),h.jsx($4,{})]})]})}function Ahe(){return h.jsxs(h.Fragment,{children:[h.jsx(xs,{text:"Engagement",Icon:rpe,iconColor:"#3C81F6"}),h.jsxs("div",{className:"grid grid-cols-4 gap-[24px] mt-4",children:[h.jsx(Ro,{data:[{title:"Notice",value:20,deltaLabel:"Currently active",Icon:Xfe,iconColor:"#1FA05B"}]}),h.jsx(Ro,{data:[{title:"Discussion Forum",value:9,deltaLabel:"Active threads",Icon:Jfe,iconColor:"#329DFF"}]}),h.jsx(Ro,{data:[{title:"Polls",value:3,deltaLabel:"Currently active",Icon:tpe,iconColor:"#FA7E28"}]}),h.jsx(Ro,{data:[{title:"Surveys",value:8,deltaLabel:"Currently active",Icon:ipe,iconColor:"#DBB467"}]})]})]})}function mF({columns:e=[{key:"a",label:"Organisation"},{key:"b",label:"Item"},{key:"c",label:"Closed"},{key:"d",label:"Open"},{key:"e",label:"AOV"},{key:"f",label:"% Revenue"}],data:t=[{a:"Google",b:"Coffee",c:"34,908",d:"₹ 57,21,288",e:"₹ 450",f:"43.6%"},{a:"Uber",b:"Paneer Combo",c:"12,000",d:"₹ 12,00,000",e:"₹ 500",f:"100%"},{a:"Uber",b:"Paneer Combo",c:"12,000",d:"₹ 12,00,000",e:"₹ 500",f:"100%"},{a:"Uber",b:"Paneer Combo",c:"12,000",d:"₹ 12,00,000",e:"₹ 500",f:"100%"},{a:"Uber",b:"Paneer Combo",c:"12,000",d:"₹ 12,00,000",e:"₹ 500",f:"100%"},{a:"Uber",b:"Paneer Combo",c:"12,000",d:"₹ 12,00,000",e:"₹ 500",f:"100%"}],rowsPerPage:n=10,setRowsPerPage:r=()=>{},currentPage:i=1,setCurrentPage:o=()=>{},totalRows:a=0,totalPages:s=1,pageOptions:l=[10,20,30,40,50]}){const c=Array.isArray(t)?t:[],u=Array.isArray(e)?e:[],d=n>0?Math.ceil(c.length/n):1,f=s||d,p=c,m=a===0&&c.length===0,g=`repeat(${u.length}, 1fr)`;return h.jsxs("div",{className:"w-full bg-white rounded-[12px] h-[390px] !border-[0.5px] !border-[#EBEBEB] !shadow-[0_0_12px_0_#EAF2FF] overflow-hidden flex flex-col",children:[h.jsx("div",{className:"flex-1 overflow-auto hide-scrollbar",children:h.jsxs("div",{className:"h-full min-w-max",children:[h.jsx("div",{className:"grid bg-[#354A5E] text-white text-[16px] leading-[20px] font-medium sticky top-0 z-30",style:{gridTemplateColumns:g},children:u.map((v,x)=>h.jsx("div",{className:`px-[24px] py-[16px] whitespace-nowrap text-left ${x===0?"sticky left-0 z-40 bg-[#354A5E] text-[16px] leading-[20px] shadow-[2px_0_5px_rgba(0,0,0,0.1)] border-r border-[#2C3E50]":""}`,children:v.label},x))}),m?h.jsx("div",{className:"h-[calc(100%-50px)] flex items-center justify-center",children:h.jsx(Vt,{title:"No Data Found",description:"Catch up all the data. Change the date range to see the data."})}):p.map((v,x)=>h.jsx("div",{className:"grid",style:{gridTemplateColumns:g},children:u.map((_,w)=>{const y=v[_.key],E=_.label==="Closed",S=_.label==="Open",P=typeof y=="string"&&y.includes("%"),D=y==="100%"?"bg-[#F0FEF2] text-[#36AB6C]":"bg-[#FFF0F0] text-[#AB0000]";return h.jsx("div",{className:`px-[24px] py-[16px] flex items-center ${w===0?"bg-white sticky left-0 z-20 shadow-[2px_0_5px_rgba(0,0,0,0.05)] border-r border-gray-200":"bg-gray-50"} text-[#121212]`,children:E?h.jsx("div",{className:"text-[14px] font-medium",style:{color:"#36AB6C"},children:y??"-"}):S?h.jsx("div",{className:"text-[14px] font-medium",style:{color:"#AB0000"},children:y??"-"}):P?h.jsx("div",{className:`inline-block px-[12px] py-[4px] rounded-full text-[14px] font-medium ${D}`,children:y}):h.jsx("div",{children:y??"-"})},w)})},x))]})}),h.jsxs("div",{className:"flex justify-end items-center px-[24px] py-[16px] text-sm bg-white border-t border-[#F0F0F0] gap-[32px] shrink-0",children:[h.jsxs("div",{className:"flex items-center gap-[8px] text-gray-600 text-[14px]",children:[h.jsx("div",{children:"Rows per page:"}),h.jsx("select",{value:n,onChange:v=>{r(Number(v.target.value)),o(1)},className:"border rounded px-[8px] py-[4px]",children:l.map((v,x)=>h.jsx("option",{value:v,children:v},x))}),h.jsxs("div",{className:"ml-4 text-[14px]",children:[c?.length===0?"0–0":`1–${c?.length}`," of"," ",a||c?.length]})]}),h.jsxs("div",{className:"flex items-center space-x-2 text-gray-600 text-[14px]",children:[h.jsx("button",{onClick:()=>o(1),disabled:i===1,className:"p-[8px] rounded hover:bg-gray-100 disabled:opacity-40",children:h.jsx(F4,{size:18})}),h.jsx("button",{onClick:()=>o(v=>v-1),disabled:i===1,className:"p-[8px] rounded hover:bg-gray-100 disabled:opacity-40",children:h.jsx($1,{size:18})}),h.jsx("button",{onClick:()=>o(v=>v+1),disabled:i===f,className:"p-[8px] rounded hover:bg-gray-100 disabled:opacity-40",children:h.jsx(B1,{size:18})}),h.jsx("button",{onClick:()=>o(f),disabled:i===f,className:"p-[8px] rounded hover:bg-gray-100 disabled:opacity-40",children:h.jsx(L4,{size:18})})]})]})]})}const gF=({options:e=[],value:t,onChange:n})=>{const[r,i]=k.useState(!1),o=k.useRef(null);return k.useEffect(()=>{const a=s=>{o.current&&!o.current.contains(s.target)&&i(!1)};return document.addEventListener("mousedown",a),()=>{document.removeEventListener("mousedown",a)}},[]),h.jsxs("div",{ref:o,className:"relative h-[32px]",children:[h.jsxs("div",{className:"flex items-center justify-between gap-[10px] px-[12px] py-[8px] border border-[#E2E8F0] rounded-[4px] cursor-pointer min-w-[140px]",onClick:()=>i(!r),children:[h.jsx("div",{className:"text-[12px] leading-[16px] min-w-[109px] text-[#64748B]",children:t}),h.jsx(Gfe,{size:16,className:"text-[#64748B]"})]}),r&&h.jsx("div",{className:"absolute top-[110%] left-0 w-full bg-white border border-[#E2E8F0] rounded-[8px] shadow-md z-10",children:e.map((a,s)=>h.jsx("div",{className:"px-[12px] py-[8px] text-[14px] text-[#334155] hover:bg-[#F1F5F9] cursor-pointer",onClick:()=>{n(a),i(!1)},children:a},s))})]})},The=({data:e,communities:t,title:n})=>{const[r,i]=k.useState({}),[o,a]=k.useState(""),s=t?.map(d=>d?.community_name)||[];k.useEffect(()=>{s?.length>0&&!o&&a(s[0])},[s,o]);const l=[{community_name:"L1",Cancelled:55,Open:50,OnHold:20,InProgress:10},{community_name:"L2",Cancelled:15,Open:15,OnHold:8,InProgress:5},{community_name:"L3",Cancelled:12,Open:75,OnHold:18,InProgress:7}],c=k.useMemo(()=>e?Array.isArray(e)&&e.length===0?[]:e:l,[e]),u=d=>{const{dataKey:f}=d||{};i(p=>({...p,[f]:!p?.[f]}))};return Array.isArray(e)&&e.length===0?h.jsx(kt,{title:n||"Escalation Level By Building",titleWeight:"semi-bold",className:"h-[362px]",children:h.jsx("div",{className:"w-full flex items-center justify-center",children:h.jsx(Vt,{title:"No Maintenance Assets Status Found",description:"Catch up all the data. Change the date range to see the data."})})}):h.jsx(kt,{title:n||"Escalation Level By Building",titleWeight:"semi-bold",className:"h-[362px]",childrenClassName:"mt-[21px]",rightContent:h.jsx(gF,{options:s,value:o,onChange:d=>a(d)}),children:h.jsx("div",{className:"w-full flex items-center justify-center",children:Array.isArray(e)&&e.length===0?h.jsx("div",{className:"text-[#94A3B8] text-sm",children:"No Data Found"}):h.jsx("div",{className:"relative w-full h-[261px]",children:h.jsx(Ot,{width:"100%",height:"100%",children:h.jsxs(ko,{data:c,barSize:54,barCategoryGap:"40%",margin:{top:20,right:20,left:-20,bottom:0},children:[h.jsx(sr,{strokeDasharray:"3 3",vertical:!1,stroke:"#E2E8F0"}),h.jsx(Gn,{dataKey:"community_name",tick:{fill:"#64748B",fontSize:12},axisLine:!1,tickLine:!1}),h.jsx(Rn,{tick:{fill:"#64748B",fontSize:12},axisLine:!1,tickLine:!1,allowDecimals:!1}),h.jsx(St,{cursor:{fill:"rgba(148, 163, 184, 0.12)"},allowEscapeViewBox:{x:!0,y:!0},content:d=>!d?.active||!d?.payload?.length?null:h.jsx(Ut,{...d,data:c,children:h.jsxs("div",{className:"bg-black rounded-[10px] px-[14px] py-[10px] text-[12px] text-white",children:[h.jsx("div",{className:"mb-[6px] font-semibold",children:d?.label}),d?.payload?.map((f,p)=>{const m=f?.color||f?.fill||"#fff";return h.jsxs("div",{className:"flex items-center gap-[6px]",children:[h.jsx("span",{className:"w-[8px] h-[8px] rounded-full inline-block",style:{backgroundColor:m}}),h.jsx("span",{className:"text-[#D1D3D4]",children:f?.name}),h.jsx("span",{className:"text-white font-semibold",children:f?.value})]},p)})]})})}),h.jsx(rl,{verticalAlign:"bottom",align:"center",onClick:u,content:({payload:d})=>h.jsx("div",{className:"flex items-center justify-center gap-[16px] pt-4 flex-wrap",children:d?.map((f,p)=>h.jsxs("div",{onClick:()=>u({dataKey:f?.dataKey}),className:"flex items-center gap-[8px] cursor-pointer",children:[h.jsx("div",{className:`w-[16px] h-[8px] ${r?.[f?.dataKey]?"bg-slate-300":""}`,style:{backgroundColor:r?.[f?.dataKey]?"#CBD5E1":f?.color}}),h.jsx("span",{className:`text-[12px] ${r?.[f?.dataKey]?"text-[#CBD5E1]":"text-[#64748B]"}`,children:f?.value})]},p))})}),h.jsx(Gt,{dataKey:"Open",stackId:"a",fill:"#3B82F6",hide:r?.Open}),h.jsx(Gt,{dataKey:"Cancelled",stackId:"a",fill:"#B91C1C",hide:r?.Cancelled}),h.jsx(Gt,{dataKey:"OnHold",stackId:"a",fill:"#64748B",hide:r?.OnHold,name:"On-Hold"}),h.jsx(Gt,{dataKey:"InProgress",stackId:"a",fill:"#F59E0B",hide:r?.InProgress,name:"In Progress"})]})})})})})},Nhe=({data:e=[]})=>{const[t,n]=k.useState("Kosmo One"),r=["Kosmo One","Kosmo Two","Kosmo Three"],i=Array.isArray(e)?e:[],o=!i.length||i.every(a=>a.no_of_visitors===0);return h.jsx(kt,{title:"Top 5 Tenants by Visitors",titleWeight:"semi-bold",className:"h-[360px]",childrenClassName:"mt-[20px]",rightContent:h.jsx(gF,{options:r,value:t,onChange:a=>n(a)}),children:o?h.jsx("div",{className:"w-full h-[280px] flex items-center justify-center",children:h.jsx(Vt,{title:"No Visitors Found",description:"Catch up all the data. Change the date range to see the data."})}):h.jsx("div",{className:"w-full h-[280px]",children:h.jsx(Ot,{width:"100%",height:"100%",children:h.jsxs(tj,{data:i,margin:{top:10,right:-10,left:-10,bottom:0},children:[h.jsx("defs",{children:h.jsxs("linearGradient",{id:"colorVisitors",x1:"0",y1:"0",x2:"0",y2:"1",children:[h.jsx("stop",{offset:"0%",stopColor:"#6366F1",stopOpacity:.25}),h.jsx("stop",{offset:"100%",stopColor:"#6366F1",stopOpacity:0})]})}),h.jsx(sr,{strokeDasharray:"3 3",vertical:!1,stroke:"#F1F5F9"}),h.jsx(Gn,{dataKey:"day",type:"category",scale:"point",padding:{left:20,right:20},tick:{fontSize:12,fill:"#64748B"},axisLine:!0,tickLine:!1,tickFormatter:a=>a}),h.jsx(Rn,{width:35,tick:{fontSize:12,fill:"#64748B"},axisLine:!1,tickLine:!1,allowDecimals:!1,domain:[0,"dataMax + 2"]}),h.jsx(St,{cursor:!1,content:a=>h.jsx(Ut,{...a,data:i,children:(()=>{if(!a.active||!a.label)return null;const s=i.find(l=>l.day===a.label);return h.jsxs("div",{className:"bg-[#111] text-white px-[14px] py-[8px] rounded-[6px] flex flex-col gap-[6px] text-[13px]",children:[h.jsx("div",{className:"font-semibold",children:a.label}),h.jsxs("div",{className:"flex items-center gap-[8px]",children:[h.jsx("div",{className:"w-2 h-2 rounded-full bg-[#6366F1]"}),h.jsx("div",{className:"text-[#aaa]",children:"Visitors"}),h.jsx("div",{className:"font-bold",children:s?.no_of_visitors??0})]})]})})()})}),h.jsx(hx,{type:"monotone",dataKey:"no_of_visitors",stroke:"#6366F1",strokeWidth:2,fill:"url(#colorVisitors)",dot:{r:5,stroke:"#6366F1",strokeWidth:2,fill:"#fff"},activeDot:a=>{const{cx:s,cy:l}=a;return h.jsxs("g",{children:[h.jsx("circle",{cx:s,cy:l,r:6,fill:"#fff",stroke:"#6466F1",strokeWidth:2}),h.jsx("circle",{cx:s,cy:l,r:2.5,fill:"#6466F1"})]})}})]})})})})},jhe=({data:e})=>{const t=[{name:"Kosmo One",total:29,pending_approval:1,cancelled:2},{name:"OWC",total:23,pending_approval:9,cancelled:3},{name:"Exora",total:40,pending_approval:12,cancelled:1},{name:"OIC - T3",total:27,pending_approval:19,cancelled:8}],n=e==null?t:Array.isArray(e)?e:[],r=Array.isArray(n)&&n.length===0;return h.jsx(kt,{title:"Building Wise Approvals",titleWeight:"semi-bold",className:"h-[362px]",childrenClassName:"mt-[34px]",children:r?h.jsx("div",{className:"h-[250px] flex items-center justify-center",children:h.jsx(Vt,{title:"No Data Found",description:"Catch up all the data. Change the date range to see the data."})}):h.jsxs("div",{className:"w-full border border-[#EBEBEB] rounded-[10px] overflow-hidden",children:[h.jsxs("div",{className:"grid grid-cols-4 bg-[#FAFAFA] px-[12px] py-[8px] text-[12px] leading-[16px] font-semibold text-[#64748B]",children:[h.jsx("div",{children:"Tenant"}),h.jsx("div",{className:"flex justify-end",children:"Total"}),h.jsx("div",{className:"flex justify-end",children:"Pending"}),h.jsx("div",{className:"flex justify-end",children:"Cancelled"})]}),h.jsx("div",{className:"max-h-[280px] overflow-y-auto hide-scrollbar",children:n.map((i,o)=>h.jsxs("div",{className:"grid grid-cols-4 p-[12px] text-[12px] leading-[16px] border-t border-[#EBEBEB]",children:[h.jsx("div",{className:"text-[#475569]",children:i.name}),h.jsx("div",{className:"flex justify-end text-[#36AB6C]",children:i.total}),h.jsx("div",{className:"flex justify-end text-[#F2A815]",children:i.pending_approval}),h.jsx("div",{className:"flex justify-end text-[#AB0000]",children:i.cancelled})]},o))})]})})},vm=["#8CB33E","#F59E0B","#3B82F6","#06B6D4","#CFCFCF"],Mhe=[{asset_group_name:"Lifts",asset_count:3,investment:"₹ 45L"},{asset_group_name:"Fire Systems",asset_count:16,investment:"₹ 28L"},{asset_group_name:"Generators",asset_count:16,investment:"₹ 95L"},{asset_group_name:"HVAC",asset_count:24,investment:"₹ 1.2Cr"},{asset_group_name:"Others",asset_count:97,investment:"₹ 52L"}],Ihe=({rows:e,totalAssets:t})=>{const n=k.useMemo(()=>e?e.length===0?[]:e.map((i,o)=>({name:i.asset_group_name,facility_name:i.asset_group_name,value:i.asset_count||0,investment:i.investment||"-",fill:vm[o%vm.length]})):Mhe.map((i,o)=>({name:i.asset_group_name,facility_name:i.asset_group_name,value:i.asset_count||0,investment:i.investment||"-",fill:vm[o%vm.length]})),[e]),r=t??n.reduce((i,o)=>i+o.value,0);return e&&e.length===0?h.jsx(kt,{title:"Assets by Type",titleWeight:"semi-bold",className:"h-[362px]",children:h.jsx("div",{className:"flex items-center justify-center h-full",children:h.jsx(Vt,{title:"No Assets Found",description:"Catch up all the data. Change the date range to see the data."})})}):h.jsx(kt,{title:"Assets by Type",titleWeight:"semi-bold",className:"h-[362px]",children:h.jsxs("div",{className:"flex items-center justify-between h-full mt-[16px]",children:[h.jsxs("div",{className:"relative w-[252px] h-[273px]",children:[h.jsx(Ot,{width:"100%",height:"100%",children:h.jsxs($i,{children:[h.jsx(ai,{data:n,dataKey:"value",cx:"50%",cy:"50%",innerRadius:60,outerRadius:90,paddingAngle:2,stroke:"#FFFFFF",strokeWidth:2,startAngle:90,endAngle:-270,children:n.map((i,o)=>h.jsx(In,{fill:i.fill},o))}),h.jsx(St,{cursor:!1,allowEscapeViewBox:{x:!0,y:!0},content:i=>i.active?h.jsx(Ut,{...i,data:n,children:h.jsx(Rr,{...i})}):null})]})}),h.jsxs("div",{className:"absolute inset-0 flex flex-col items-center justify-center pointer-events-none",children:[h.jsx("div",{className:"text-[24px] leading-[33px] font-medium text-[#121212]",children:r}),h.jsx("div",{className:"text-[12px] leading-[17px] text-[#64748B] mt-[2px]",children:"Total Assets"})]})]}),h.jsx("div",{className:"flex-1 max-w-[280px]",children:h.jsxs("div",{className:"rounded-[12px] overflow-hidden bg-white border border-[#E2E8F0]",children:[h.jsxs("div",{className:"grid grid-cols-3 px-[16px] py-[12px] bg-[#F8FAFC]",children:[h.jsx("div",{className:"text-[12px] font-medium text-[#64748B]",children:"Asset"}),h.jsx("div",{className:"text-[12px] font-medium text-[#64748B] text-center",children:"Count"}),h.jsx("div",{className:"text-[12px] font-medium text-[#64748B] text-right",children:"Investment"})]}),h.jsx("div",{className:"max-h-[205px] overflow-y-auto hide-scrollbar",children:n.map((i,o)=>h.jsxs("div",{className:"grid grid-cols-3 px-[16px] py-[12px] border-t border-[#F1F5F9]",children:[h.jsxs("div",{className:"flex items-center gap-[8px]",children:[h.jsx("div",{className:"w-[16px] h-[7px]",style:{backgroundColor:i.fill}}),h.jsx("div",{className:"text-[13px] text-[#475569]",children:i.name})]}),h.jsx("div",{className:"text-[13px] text-[#64748B] text-center",children:i.value}),h.jsx("div",{className:"text-[13px] text-[#64748B] text-right",children:i.investment})]},o))})]})})]})})};function Fhe({columns:e=[],data:t=[],rowsPerPage:n=10,setRowsPerPage:r=()=>{},currentPage:i=1,setCurrentPage:o=()=>{},totalRows:a=0,totalPages:s=1,pageOptions:l=[10,20,30,40,50]}){const c=Array.isArray(t)?t:[],u=Array.isArray(e)?e:[],d=`200px repeat(${u.length-1}, 150px)`,f={};return u.forEach(p=>{if(p.key!=="name"){let m=0;for(let g=0;g<c.length;g++){const v=c[g][p.key];typeof v=="number"&&(m+=v)}f[p.key]=m}}),h.jsxs("div",{className:"w-full bg-white rounded-[12px] h-[390px] !border-[0.5px] !border-[#EBEBEB] !shadow-[0_0_12px_0_#EAF2FF] overflow-hidden flex flex-col",children:[h.jsx("div",{className:"flex-1 overflow-auto hide-scrollbar",children:c.length===0?h.jsx("div",{className:"h-full flex items-center justify-center",children:h.jsx(Vt,{title:"No Data Found",description:"Catch up all the data. Change the date range to see the data."})}):h.jsxs("div",{className:"min-w-max",children:[h.jsx("div",{className:"grid bg-[#354A5E] text-white text-[14px] font-medium sticky top-0 z-30",style:{gridTemplateColumns:d},children:u.map((p,m)=>h.jsx("div",{title:p.label,className:`px-[24px] py-[16px] whitespace-nowrap overflow-hidden text-ellipsis ${m===0?"sticky left-0 z-40 bg-[#354A5E] shadow-[2px_0_5px_rgba(0,0,0,0.1)] border-r border-[#2C3E50]":""}`,children:p.label},m))}),c.map((p,m)=>h.jsx("div",{className:"grid",style:{gridTemplateColumns:d},children:u.map((g,v)=>h.jsx("div",{className:`px-[24px] py-[14px] text-[14px] flex items-center ${v===0?"bg-white sticky left-0 z-20 font-medium shadow-[2px_0_5px_rgba(0,0,0,0.05)] border-r border-gray-200":"bg-gray-50"}`,children:p[g.key]??"-"},v))},m)),h.jsx("div",{className:"grid bg-[#F8FAFC] border-t border-[#F0F0F0] sticky bottom-0 z-30",style:{gridTemplateColumns:d},children:u.map((p,m)=>h.jsx("div",{className:`px-[24px] py-[16px] ${m===0?"sticky left-0 z-40 bg-[#F8FAFC] text-[#64748B] font-medium shadow-[2px_0_5px_rgba(0,0,0,0.05)] border-r border-gray-200":"text-[#64748B] font-medium"}`,children:p.key==="name"?"Grand Total":f[p.key]||0},m))})]})}),h.jsxs("div",{className:"flex justify-end items-center px-[24px] py-[16px] text-sm bg-white border-t border-[#F0F0F0] gap-[32px]",children:[h.jsxs("div",{className:"flex items-center gap-[8px] text-gray-600 text-[14px]",children:[h.jsx("div",{children:"Rows per page:"}),h.jsx("select",{value:n,onChange:p=>{r(Number(p.target.value)),o(1)},className:"border rounded px-[8px] py-[4px]",children:l.map((p,m)=>h.jsx("option",{value:p,children:p},m))}),h.jsxs("div",{className:"ml-4 text-[14px]",children:[c.length===0?"0–0":`1–${c.length}`," of"," ",a||c.length]})]}),h.jsxs("div",{className:"flex items-center space-x-2 text-gray-600 text-[14px]",children:[h.jsx("button",{onClick:()=>o(1),disabled:i===1,className:"p-[8px] rounded hover:bg-gray-100 disabled:opacity-40",children:h.jsx(F4,{size:18})}),h.jsx("button",{onClick:()=>o(p=>p-1),disabled:i===1,className:"p-[8px] rounded hover:bg-gray-100 disabled:opacity-40",children:h.jsx($1,{size:18})}),h.jsx("button",{onClick:()=>o(p=>p+1),disabled:i===s,className:"p-[8px] rounded hover:bg-gray-100 disabled:opacity-40",children:h.jsx(B1,{size:18})}),h.jsx("button",{onClick:()=>o(s),disabled:i===s,className:"p-[8px] rounded hover:bg-gray-100 disabled:opacity-40",children:h.jsx(L4,{size:18})})]})]})]})}ae.AccessPointsUsage=tF,ae.Accounting=Ofe,ae.Amenities=K4,ae.AmenitiesStatsCard=Ro,ae.AmenityWiseRevenue=uF,ae.AssetValueBreakdown=Rfe,ae.AssetsByType=dF,ae.BlockWiseOccupancy=gfe,ae.BookingTrendChart=cF,ae.Bookings=lF,ae.Budgets=Afe,ae.BuildingWiseApprovals=jhe,ae.Card=Le,ae.CardAccess=eF,ae.CashBankBalance=Nfe,ae.CommercialAccessOverview=J4,ae.CommercialAmenitiesDashboard=Che,ae.CommercialAssetManagementDashboard=Phe,ae.CommercialDashboard=dhe,ae.CommercialEngagementDashboard=Ahe,ae.CommercialGuardPatrols=pF,ae.CommercialGuardPetrolDashboard=Dhe,ae.CommercialHelpdeskDashboard=bhe,ae.CommercialIncidentReports=hF,ae.CommercialOccupancy=z4,ae.CommercialReportTable=mF,ae.CommercialSmartAccessDashboard=mhe,ae.CommercialTableDashboard=mF,ae.CommercialVisitorsDashboard=whe,ae.Community=Jae,ae.Complaints=Mpe,ae.ComplaintsByLevel=Lpe,ae.DuesAgeing=Mfe,ae.EmployeeFootfall=V4,ae.Engagement=tM,ae.EngagementStatsGrid=rhe,ae.EscalationLevel=The,ae.EventsUtilisation=Gpe,ae.ExpenseCategories=Ffe,ae.Facilities=ese,ae.FinanceSummary=tse,ae.FoodBeverages=U4,ae.GateAndSecurityStatsGrid=Tpe,ae.GateUpdates=zse,ae.GuardPatrols=vpe,ae.Header=k8,ae.Helpdesk=Vse,ae.HelpdeskStatsGrid=Upe,ae.HourlyTrafficFlow=_pe,ae.IncidentReports=Ope,ae.IncomeExpenditure=A4,ae.MainHeader=B8,ae.MaintenanceStatus=fF,ae.MetricCard=z1,ae.MobileAccess=eF,ae.MoveInOutTrends=bfe,ae.NoticeBoardStatus=Zpe,ae.OccupancyOverview=pfe,ae.OrganisationWiseVisitors=sF,ae.PortfolioAssetsByType=Ihe,ae.RequestBox=$pe,ae.ResidentOverview=hfe,ae.RevenuebyCategory=Bfe,ae.SingleStats=ehe,ae.StaffAttendance=$4,ae.StatsGrid=mpe,ae.TenantsByVisitors=Nhe,ae.TicketEscalation=q4,ae.TicketStatus=G4,ae.Tickets=nF,ae.TicketsperCategory=rF,ae.TotalCommercialTable=Fhe,ae.UnitStatus=ffe,ae.VisitorUpdates=Z4,ae.WeeklyVisitorPattern=aF,Object.defineProperty(ae,Symbol.toStringTag,{value:"Module"})}));
|