@eshal-bot/chat-widget 0.1.123 → 0.1.124
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/{chat-widget-MarkdownRenderer-B5jGiiT4.esm.js → chat-widget-MarkdownRenderer-Ceiq3ThN.esm.js} +1 -1
- package/dist/{chat-widget-index-Bn-k9Jjr.esm.js → chat-widget-index-DciHQpWo.esm.js} +1 -1
- package/dist/chat-widget.esm.js +1 -1
- package/dist/chat-widget.js +1 -1
- package/dist/chat-widget.min.js +1 -1
- package/dist/chat-widget.umd.js +1 -1
- package/package.json +1 -1
package/dist/chat-widget.umd.js
CHANGED
|
@@ -47,4 +47,4 @@ var ge={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24
|
|
|
47
47
|
object-assign
|
|
48
48
|
(c) Sindre Sorhus
|
|
49
49
|
@license MIT
|
|
50
|
-
*/function jH(){if(kH)return EH;kH=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable;return EH=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;if("0123456789"!==Object.getOwnPropertyNames(t).map(function(e){return t[e]}).join(""))return!1;var r={};return"abcdefghijklmnopqrst".split("").forEach(function(e){r[e]=e}),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},r)).join("")}catch(e){return!1}}()?Object.assign:function(r,o){for(var a,i,s=function(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}(r),l=1;l<arguments.length;l++){for(var c in a=Object(arguments[l]))t.call(a,c)&&(s[c]=a[c]);if(e){i=e(a);for(var u=0;u<i.length;u++)n.call(a,i[u])&&(s[i[u]]=a[i[u]])}}return s},EH}function FH(){if(TH)return AH;TH=1;return AH="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"}function BH(){return CH?OH:(CH=1,OH=Function.call.bind(Object.prototype.hasOwnProperty))}if("production"!==process.env.NODE_ENV){var UH=MH();yH.exports=function(){if(RH)return _H;RH=1;var e=MH(),t=jH(),n=FH(),r=BH(),o=function(){if(NH)return IH;NH=1;var e=function(){};if("production"!==process.env.NODE_ENV){var t=FH(),n={},r=BH();e=function(e){var t="Warning: "+e;"undefined"!=typeof console&&console.error(t);try{throw new Error(t)}catch(e){}}}function o(o,a,i,s,l){if("production"!==process.env.NODE_ENV)for(var c in o)if(r(o,c)){var u;try{if("function"!=typeof o[c]){var d=Error((s||"React class")+": "+i+" type `"+c+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof o[c]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw d.name="Invariant Violation",d}u=o[c](a,c,s,i,null,t)}catch(e){u=e}if(!u||u instanceof Error||e((s||"React class")+": type specification of "+i+" `"+c+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof u+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),u instanceof Error&&!(u.message in n)){n[u.message]=!0;var p=l?l():"";e("Failed "+i+" type: "+u.message+(null!=p?p:""))}}}return o.resetWarningCache=function(){"production"!==process.env.NODE_ENV&&(n={})},IH=o}(),a=function(){};function i(){return null}return"production"!==process.env.NODE_ENV&&(a=function(e){var t="Warning: "+e;"undefined"!=typeof console&&console.error(t);try{throw new Error(t)}catch(e){}}),_H=function(s,l){var c="function"==typeof Symbol&&Symbol.iterator,u="<<anonymous>>",d={array:h("array"),bigint:h("bigint"),bool:h("boolean"),func:h("function"),number:h("number"),object:h("object"),string:h("string"),symbol:h("symbol"),any:g(i),arrayOf:function(e){return g(function(t,r,o,a,i){if("function"!=typeof e)return new f("Property `"+i+"` of component `"+o+"` has invalid PropType notation inside arrayOf.");var s=t[r];if(!Array.isArray(s))return new f("Invalid "+a+" `"+i+"` of type `"+y(s)+"` supplied to `"+o+"`, expected an array.");for(var l=0;l<s.length;l++){var c=e(s,l,o,a,i+"["+l+"]",n);if(c instanceof Error)return c}return null})},element:g(function(e,t,n,r,o){var a=e[t];return s(a)?null:new f("Invalid "+r+" `"+o+"` of type `"+y(a)+"` supplied to `"+n+"`, expected a single ReactElement.")}),elementType:g(function(t,n,r,o,a){var i=t[n];return e.isValidElementType(i)?null:new f("Invalid "+o+" `"+a+"` of type `"+y(i)+"` supplied to `"+r+"`, expected a single ReactElement type.")}),instanceOf:function(e){return g(function(t,n,r,o,a){if(!(t[n]instanceof e)){var i=e.name||u;return new f("Invalid "+o+" `"+a+"` of type `"+((s=t[n]).constructor&&s.constructor.name?s.constructor.name:u)+"` supplied to `"+r+"`, expected instance of `"+i+"`.")}var s;return null})},node:g(function(e,t,n,r,o){return b(e[t])?null:new f("Invalid "+r+" `"+o+"` supplied to `"+n+"`, expected a ReactNode.")}),objectOf:function(e){return g(function(t,o,a,i,s){if("function"!=typeof e)return new f("Property `"+s+"` of component `"+a+"` has invalid PropType notation inside objectOf.");var l=t[o],c=y(l);if("object"!==c)return new f("Invalid "+i+" `"+s+"` of type `"+c+"` supplied to `"+a+"`, expected an object.");for(var u in l)if(r(l,u)){var d=e(l,u,a,i,s+"."+u,n);if(d instanceof Error)return d}return null})},oneOf:function(e){return Array.isArray(e)?g(function(t,n,r,o,a){for(var i=t[n],s=0;s<e.length;s++)if(p(i,e[s]))return null;var l=JSON.stringify(e,function(e,t){return"symbol"===v(t)?String(t):t});return new f("Invalid "+o+" `"+a+"` of value `"+String(i)+"` supplied to `"+r+"`, expected one of "+l+".")}):("production"!==process.env.NODE_ENV&&a(arguments.length>1?"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]).":"Invalid argument supplied to oneOf, expected an array."),i)},oneOfType:function(e){if(!Array.isArray(e))return"production"!==process.env.NODE_ENV&&a("Invalid argument supplied to oneOfType, expected an instance of array."),i;for(var t=0;t<e.length;t++){var o=e[t];if("function"!=typeof o)return a("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+w(o)+" at index "+t+"."),i}return g(function(t,o,a,i,s){for(var l=[],c=0;c<e.length;c++){var u=(0,e[c])(t,o,a,i,s,n);if(null==u)return null;u.data&&r(u.data,"expectedType")&&l.push(u.data.expectedType)}return new f("Invalid "+i+" `"+s+"` supplied to `"+a+"`"+(l.length>0?", expected one of type ["+l.join(", ")+"]":"")+".")})},shape:function(e){return g(function(t,r,o,a,i){var s=t[r],l=y(s);if("object"!==l)return new f("Invalid "+a+" `"+i+"` of type `"+l+"` supplied to `"+o+"`, expected `object`.");for(var c in e){var u=e[c];if("function"!=typeof u)return m(o,a,i,c,v(u));var d=u(s,c,o,a,i+"."+c,n);if(d)return d}return null})},exact:function(e){return g(function(o,a,i,s,l){var c=o[a],u=y(c);if("object"!==u)return new f("Invalid "+s+" `"+l+"` of type `"+u+"` supplied to `"+i+"`, expected `object`.");var d=t({},o[a],e);for(var p in d){var g=e[p];if(r(e,p)&&"function"!=typeof g)return m(i,s,l,p,v(g));if(!g)return new f("Invalid "+s+" `"+l+"` key `"+p+"` supplied to `"+i+"`.\nBad object: "+JSON.stringify(o[a],null," ")+"\nValid keys: "+JSON.stringify(Object.keys(e),null," "));var h=g(c,p,i,s,l+"."+p,n);if(h)return h}return null})}};function p(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}function f(e,t){this.message=e,this.data=t&&"object"==typeof t?t:{},this.stack=""}function g(e){if("production"!==process.env.NODE_ENV)var t={},r=0;function o(o,i,s,c,d,p,g){if(c=c||u,p=p||s,g!==n){if(l){var h=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 h.name="Invariant Violation",h}if("production"!==process.env.NODE_ENV&&"undefined"!=typeof console){var m=c+":"+s;!t[m]&&r<3&&(a("You are manually calling a React.PropTypes validation function for the `"+p+"` prop on `"+c+"`. 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."),t[m]=!0,r++)}}return null==i[s]?o?null===i[s]?new f("The "+d+" `"+p+"` is marked as required in `"+c+"`, but its value is `null`."):new f("The "+d+" `"+p+"` is marked as required in `"+c+"`, but its value is `undefined`."):null:e(i,s,c,d,p)}var i=o.bind(null,!1);return i.isRequired=o.bind(null,!0),i}function h(e){return g(function(t,n,r,o,a,i){var s=t[n];return y(s)!==e?new f("Invalid "+o+" `"+a+"` of type `"+v(s)+"` supplied to `"+r+"`, expected `"+e+"`.",{expectedType:e}):null})}function m(e,t,n,r,o){return new f((e||"React class")+": "+t+" type `"+n+"."+r+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+o+"`.")}function b(e){switch(typeof e){case"number":case"string":case"undefined":return!0;case"boolean":return!e;case"object":if(Array.isArray(e))return e.every(b);if(null===e||s(e))return!0;var t=function(e){var t=e&&(c&&e[c]||e["@@iterator"]);if("function"==typeof t)return t}(e);if(!t)return!1;var n,r=t.call(e);if(t!==e.entries){for(;!(n=r.next()).done;)if(!b(n.value))return!1}else for(;!(n=r.next()).done;){var o=n.value;if(o&&!b(o[1]))return!1}return!0;default:return!1}}function y(e){var t=typeof e;return Array.isArray(e)?"array":e instanceof RegExp?"object":function(e,t){return"symbol"===e||!!t&&("Symbol"===t["@@toStringTag"]||"function"==typeof Symbol&&t instanceof Symbol)}(t,e)?"symbol":t}function v(e){if(null==e)return""+e;var t=y(e);if("object"===t){if(e instanceof Date)return"date";if(e instanceof RegExp)return"regexp"}return t}function w(e){var t=v(e);switch(t){case"array":case"object":return"an "+t;case"boolean":case"date":case"regexp":return"a "+t;default:return t}}return f.prototype=Error.prototype,d.checkPropTypes=o,d.resetWarningCache=o.resetWarningCache,d.PropTypes=d,d},_H}()(UH.isElement,!0)}else yH.exports=function(){if(LH)return PH;LH=1;var e=FH();function t(){}function n(){}return n.resetWarningCache=t,PH=function(){function r(t,n,r,o,a,i){if(i!==e){var s=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 s.name="Invariant Violation",s}}function o(){return r}r.isRequired=r;var a={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:o,element:r,elementType:r,instanceOf:o,node:r,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:n,resetWarningCache:t};return a.PropTypes=a,a}}()();var zH=yH.exports;const{getOwnPropertyNames:$H,getOwnPropertySymbols:GH}=Object,{hasOwnProperty:qH}=Object.prototype;function HH(e,t){return function(n,r,o){return e(n,r,o)&&t(n,r,o)}}function VH(e){return function(t,n,r){if(!t||!n||"object"!=typeof t||"object"!=typeof n)return e(t,n,r);const{cache:o}=r,a=o.get(t),i=o.get(n);if(a&&i)return a===n&&i===t;o.set(t,n),o.set(n,t);const s=e(t,n,r);return o.delete(t),o.delete(n),s}}function WH(e){return $H(e).concat(GH(e))}const YH=Object.hasOwn||((e,t)=>qH.call(e,t));function KH(e,t){return e===t||!e&&!t&&e!=e&&t!=t}const{getOwnPropertyDescriptor:XH,keys:ZH}=Object;function QH(e,t){return e.byteLength===t.byteLength&&dV(new Uint8Array(e),new Uint8Array(t))}function JH(e,t,n){let r=e.length;if(t.length!==r)return!1;for(;r-- >0;)if(!n.equals(e[r],t[r],r,r,e,t,n))return!1;return!0}function eV(e,t){return e.byteLength===t.byteLength&&dV(new Uint8Array(e.buffer,e.byteOffset,e.byteLength),new Uint8Array(t.buffer,t.byteOffset,t.byteLength))}function tV(e,t){return KH(e.getTime(),t.getTime())}function nV(e,t){return e.name===t.name&&e.message===t.message&&e.cause===t.cause&&e.stack===t.stack}function rV(e,t){return e===t}function oV(e,t,n){const r=e.size;if(r!==t.size)return!1;if(!r)return!0;const o=new Array(r),a=e.entries();let i,s,l=0;for(;(i=a.next())&&!i.done;){const r=t.entries();let a=!1,c=0;for(;(s=r.next())&&!s.done;){if(o[c]){c++;continue}const r=i.value,u=s.value;if(n.equals(r[0],u[0],l,c,e,t,n)&&n.equals(r[1],u[1],r[0],u[0],e,t,n)){a=o[c]=!0;break}c++}if(!a)return!1;l++}return!0}const aV=KH;function iV(e,t,n){const r=ZH(e);let o=r.length;if(ZH(t).length!==o)return!1;for(;o-- >0;)if(!fV(e,t,n,r[o]))return!1;return!0}function sV(e,t,n){const r=WH(e);let o,a,i,s=r.length;if(WH(t).length!==s)return!1;for(;s-- >0;){if(o=r[s],!fV(e,t,n,o))return!1;if(a=XH(e,o),i=XH(t,o),(a||i)&&(!a||!i||a.configurable!==i.configurable||a.enumerable!==i.enumerable||a.writable!==i.writable))return!1}return!0}function lV(e,t){return KH(e.valueOf(),t.valueOf())}function cV(e,t){return e.source===t.source&&e.flags===t.flags}function uV(e,t,n){const r=e.size;if(r!==t.size)return!1;if(!r)return!0;const o=new Array(r),a=e.values();let i,s;for(;(i=a.next())&&!i.done;){const r=t.values();let a=!1,l=0;for(;(s=r.next())&&!s.done;){if(!o[l]&&n.equals(i.value,s.value,i.value,s.value,e,t,n)){a=o[l]=!0;break}l++}if(!a)return!1}return!0}function dV(e,t){let n=e.byteLength;if(t.byteLength!==n||e.byteOffset!==t.byteOffset)return!1;for(;n-- >0;)if(e[n]!==t[n])return!1;return!0}function pV(e,t){return e.hostname===t.hostname&&e.pathname===t.pathname&&e.protocol===t.protocol&&e.port===t.port&&e.hash===t.hash&&e.username===t.username&&e.password===t.password}function fV(e,t,n,r){return!("_owner"!==r&&"__o"!==r&&"__v"!==r||!e.$$typeof&&!t.$$typeof)||YH(t,r)&&n.equals(e[r],t[r],r,r,e,t,n)}const gV={"[object Int8Array]":!0,"[object Uint8Array]":!0,"[object Uint8ClampedArray]":!0,"[object Int16Array]":!0,"[object Uint16Array]":!0,"[object Int32Array]":!0,"[object Uint32Array]":!0,"[object Float16Array]":!0,"[object Float32Array]":!0,"[object Float64Array]":!0,"[object BigInt64Array]":!0,"[object BigUint64Array]":!0},hV=Object.prototype.toString;function mV({areArrayBuffersEqual:e,areArraysEqual:t,areDataViewsEqual:n,areDatesEqual:r,areErrorsEqual:o,areFunctionsEqual:a,areMapsEqual:i,areNumbersEqual:s,areObjectsEqual:l,arePrimitiveWrappersEqual:c,areRegExpsEqual:u,areSetsEqual:d,areTypedArraysEqual:p,areUrlsEqual:f,unknownTagComparators:g}){return function(h,m,b){if(h===m)return!0;if(null==h||null==m)return!1;const y=typeof h;if(y!==typeof m)return!1;if("object"!==y)return"number"===y?s(h,m,b):"function"===y&&a(h,m,b);const v=h.constructor;if(v!==m.constructor)return!1;if(v===Object)return l(h,m,b);if(Array.isArray(h))return t(h,m,b);if(v===Date)return r(h,m,b);if(v===RegExp)return u(h,m,b);if(v===Map)return i(h,m,b);if(v===Set)return d(h,m,b);const w=hV.call(h);if("[object Date]"===w)return r(h,m,b);if("[object RegExp]"===w)return u(h,m,b);if("[object Map]"===w)return i(h,m,b);if("[object Set]"===w)return d(h,m,b);if("[object Object]"===w)return"function"!=typeof h.then&&"function"!=typeof m.then&&l(h,m,b);if("[object URL]"===w)return f(h,m,b);if("[object Error]"===w)return o(h,m,b);if("[object Arguments]"===w)return l(h,m,b);if(gV[w])return p(h,m,b);if("[object ArrayBuffer]"===w)return e(h,m,b);if("[object DataView]"===w)return n(h,m,b);if("[object Boolean]"===w||"[object Number]"===w||"[object String]"===w)return c(h,m,b);if(g){let e=g[w];if(!e){const t=null!=(S=h)?S[Symbol.toStringTag]:void 0;t&&(e=g[t])}if(e)return e(h,m,b)}var S;return!1}}const bV=yV();function yV(e={}){const{circular:t=!1,createInternalComparator:n,createState:r,strict:o=!1}=e,a=function({circular:e,createCustomConfig:t,strict:n}){let r={areArrayBuffersEqual:QH,areArraysEqual:n?sV:JH,areDataViewsEqual:eV,areDatesEqual:tV,areErrorsEqual:nV,areFunctionsEqual:rV,areMapsEqual:n?HH(oV,sV):oV,areNumbersEqual:aV,areObjectsEqual:n?sV:iV,arePrimitiveWrappersEqual:lV,areRegExpsEqual:cV,areSetsEqual:n?HH(uV,sV):uV,areTypedArraysEqual:n?HH(dV,sV):dV,areUrlsEqual:pV,unknownTagComparators:void 0};if(t&&(r=Object.assign({},r,t(r))),e){const e=VH(r.areArraysEqual),t=VH(r.areMapsEqual),n=VH(r.areObjectsEqual),o=VH(r.areSetsEqual);r=Object.assign({},r,{areArraysEqual:e,areMapsEqual:t,areObjectsEqual:n,areSetsEqual:o})}return r}(e),i=mV(a),s=n?n(i):(l=i,function(e,t,n,r,o,a,i){return l(e,t,i)});var l;return function({circular:e,comparator:t,createState:n,equals:r,strict:o}){if(n)return function(a,i){const{cache:s=(e?new WeakMap:void 0),meta:l}=n();return t(a,i,{cache:s,equals:r,meta:l,strict:o})};if(e)return function(e,n){return t(e,n,{cache:new WeakMap,equals:r,meta:void 0,strict:o})};const a={cache:void 0,equals:r,meta:void 0,strict:o};return function(e,n){return t(e,n,a)}}({circular:t,comparator:i,createState:r,equals:s,strict:o})}function vV(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=-1;requestAnimationFrame(function r(o){n<0&&(n=o),o-n>t?(e(o),n=-1):function(e){"undefined"!=typeof requestAnimationFrame&&requestAnimationFrame(e)}(r)})}function wV(e){return wV="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},wV(e)}function SV(e){return function(e){if(Array.isArray(e))return e}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return xV(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return xV(e,t)}(e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function xV(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function EV(){var e=function(){return null},t=!1,n=function n(r){if(!t){if(Array.isArray(r)){if(!r.length)return;var o=SV(r),a=o[0],i=o.slice(1);return"number"==typeof a?void vV(n.bind(null,i),a):(n(a),void vV(n.bind(null,i)))}"object"===wV(r)&&e(r),"function"==typeof r&&r()}};return{stop:function(){t=!0},start:function(e){t=!1,n(e)},subscribe:function(t){return e=t,function(){e=function(){return null}}}}}function kV(e){return kV="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},kV(e)}function AV(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function TV(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?AV(Object(n),!0).forEach(function(t){OV(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):AV(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function OV(e,t,n){return(t=function(e){var t=function(e,t){if("object"!==kV(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!==kV(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"===kV(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}yV({strict:!0}),yV({circular:!0}),yV({circular:!0,strict:!0}),yV({createInternalComparator:()=>KH}),yV({strict:!0,createInternalComparator:()=>KH}),yV({circular:!0,createInternalComparator:()=>KH}),yV({circular:!0,createInternalComparator:()=>KH,strict:!0});var CV=function(e){return e},IV=function(e,t){return Object.keys(t).reduce(function(n,r){return TV(TV({},n),{},OV({},r,e(r,t[r])))},{})},NV=function(e,t,n){return e.map(function(e){return"".concat(function(e){return e.replace(/([A-Z])/g,function(e){return"-".concat(e.toLowerCase())})}(e)," ").concat(t,"ms ").concat(n)}).join(",")},_V="production"!==process.env.NODE_ENV,RV=function(e,t,n,r,o,a,i,s){if(_V&&"undefined"!=typeof console&&console.warn&&(void 0===t&&console.warn("LogUtils requires an error message argument"),!e))if(void 0===t)console.warn("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var l=[n,r,o,a,i,s],c=0;console.warn(t.replace(/%s/g,function(){return l[c++]}))}};function PV(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,a,i,s=[],l=!0,c=!1;try{if(a=(n=n.call(e)).next,0===t);else for(;!(l=(r=a.call(n)).done)&&(s.push(r.value),s.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(c)throw o}}return s}}(e,t)||DV(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function LV(e){return function(e){if(Array.isArray(e))return MV(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||DV(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function DV(e,t){if(e){if("string"==typeof e)return MV(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?MV(e,t):void 0}}function MV(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var jV=1e-4,FV=function(e,t){return[0,3*e,3*t-6*e,3*e-3*t+1]},BV=function(e,t){return e.map(function(e,n){return e*Math.pow(t,n)}).reduce(function(e,t){return e+t})},UV=function(e,t){return function(n){var r=FV(e,t);return BV(r,n)}},zV=function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=t[0],o=t[1],a=t[2],i=t[3];if(1===t.length)switch(t[0]){case"linear":r=0,o=0,a=1,i=1;break;case"ease":r=.25,o=.1,a=.25,i=1;break;case"ease-in":r=.42,o=0,a=1,i=1;break;case"ease-out":r=.42,o=0,a=.58,i=1;break;case"ease-in-out":r=0,o=0,a=.58,i=1;break;default:var s=t[0].split("(");if("cubic-bezier"===s[0]&&4===s[1].split(")")[0].split(",").length){var l=s[1].split(")")[0].split(",").map(function(e){return parseFloat(e)}),c=PV(l,4);r=c[0],o=c[1],a=c[2],i=c[3]}else RV(!1,"[configBezier]: arguments should be one of oneOf 'linear', 'ease', 'ease-in', 'ease-out', 'ease-in-out','cubic-bezier(x1,y1,x2,y2)', instead received %s",t)}RV([r,a,o,i].every(function(e){return"number"==typeof e&&e>=0&&e<=1}),"[configBezier]: arguments should be x1, y1, x2, y2 of [0, 1] instead received %s",t);var u,d,p=UV(r,a),f=UV(o,i),g=(u=r,d=a,function(e){var t=FV(u,d),n=[].concat(LV(t.map(function(e,t){return e*t}).slice(1)),[0]);return BV(n,e)}),h=function(e){return e>1?1:e<0?0:e},m=function(e){for(var t=e>1?1:e,n=t,r=0;r<8;++r){var o=p(n)-t,a=g(n);if(Math.abs(o-t)<jV||a<jV)return f(n);n=h(n-o/a)}return f(n)};return m.isStepper=!1,m},$V=function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=t[0];if("string"==typeof r)switch(r){case"ease":case"ease-in-out":case"ease-out":case"ease-in":case"linear":return zV(r);case"spring":return function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.stiff,n=void 0===t?100:t,r=e.damping,o=void 0===r?8:r,a=e.dt,i=void 0===a?17:a,s=function(e,t,r){var a=r+(-(e-t)*n-r*o)*i/1e3,s=r*i/1e3+e;return Math.abs(s-t)<jV&&Math.abs(a)<jV?[t,0]:[s,a]};return s.isStepper=!0,s.dt=i,s}();default:if("cubic-bezier"===r.split("(")[0])return zV(r);RV(!1,"[configEasing]: first argument should be one of 'ease', 'ease-in', 'ease-out', 'ease-in-out','cubic-bezier(x1,y1,x2,y2)', 'linear' and 'spring', instead received %s",t)}return"function"==typeof r?r:(RV(!1,"[configEasing]: first argument type should be function or string, instead received %s",t),null)};function GV(e){return GV="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},GV(e)}function qV(e){return function(e){if(Array.isArray(e))return XV(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||KV(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function HV(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function VV(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?HV(Object(n),!0).forEach(function(t){WV(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):HV(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function WV(e,t,n){return(t=function(e){var t=function(e,t){if("object"!==GV(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!==GV(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"===GV(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function YV(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,a,i,s=[],l=!0,c=!1;try{if(a=(n=n.call(e)).next,0===t);else for(;!(l=(r=a.call(n)).done)&&(s.push(r.value),s.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(c)throw o}}return s}}(e,t)||KV(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function KV(e,t){if(e){if("string"==typeof e)return XV(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?XV(e,t):void 0}}function XV(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var ZV=function(e,t,n){return e+(t-e)*n},QV=function(e){return e.from!==e.to},JV=function e(t,n,r){var o=IV(function(e,n){if(QV(n)){var r=YV(t(n.from,n.to,n.velocity),2),o=r[0],a=r[1];return VV(VV({},n),{},{from:o,velocity:a})}return n},n);return r<1?IV(function(e,t){return QV(t)?VV(VV({},t),{},{velocity:ZV(t.velocity,o[e].velocity,r),from:ZV(t.from,o[e].from,r)}):t},n):e(t,o,r-1)},eW=function(e,t,n,r,o){var a,i,s,l,c=(a=e,i=t,[Object.keys(a),Object.keys(i)].reduce(function(e,t){return e.filter(function(e){return t.includes(e)})})),u=c.reduce(function(n,r){return VV(VV({},n),{},WV({},r,[e[r],t[r]]))},{}),d=c.reduce(function(n,r){return VV(VV({},n),{},WV({},r,{from:e[r],velocity:0,to:t[r]}))},{}),p=-1,f=function(){return null};return f=n.isStepper?function(r){s||(s=r);var a=(r-s)/n.dt;d=JV(n,d,a),o(VV(VV(VV({},e),t),IV(function(e,t){return t.from},d))),s=r,Object.values(d).filter(QV).length&&(p=requestAnimationFrame(f))}:function(a){l||(l=a);var i=(a-l)/r,s=IV(function(e,t){return ZV.apply(void 0,qV(t).concat([n(i)]))},u);if(o(VV(VV(VV({},e),t),s)),i<1)p=requestAnimationFrame(f);else{var c=IV(function(e,t){return ZV.apply(void 0,qV(t).concat([n(1)]))},u);o(VV(VV(VV({},e),t),c))}},function(){return requestAnimationFrame(f),function(){cancelAnimationFrame(p)}}};function tW(e){return tW="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},tW(e)}var nW=["children","begin","duration","attributeName","easing","isActive","steps","from","to","canBegin","onAnimationEnd","shouldReAnimate","onAnimationReStart"];function rW(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},a=Object.keys(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function oW(e){return function(e){if(Array.isArray(e))return aW(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return aW(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return aW(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function aW(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function iW(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function sW(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?iW(Object(n),!0).forEach(function(t){lW(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):iW(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function lW(e,t,n){return(t=uW(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function cW(e,t,n){return t&&function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,uW(r.key),r)}}(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function uW(e){var t=function(e,t){if("object"!==tW(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!==tW(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"===tW(t)?t:String(t)}function dW(e,t){return dW=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},dW(e,t)}function pW(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}();return function(){var n,r=hW(e);if(t){var o=hW(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return fW(this,n)}}function fW(e,t){if(t&&("object"===tW(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return gW(e)}function gW(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function hW(e){return hW=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},hW(e)}var mW=function(t){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&dW(e,t)}(r,t);var n=pW(r);function r(e,t){var o;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,r);var a=(o=n.call(this,e,t)).props,i=a.isActive,s=a.attributeName,l=a.from,c=a.to,u=a.steps,d=a.children,p=a.duration;if(o.handleStyleChange=o.handleStyleChange.bind(gW(o)),o.changeStyle=o.changeStyle.bind(gW(o)),!i||p<=0)return o.state={style:{}},"function"==typeof d&&(o.state={style:c}),fW(o);if(u&&u.length)o.state={style:u[0].style};else if(l){if("function"==typeof d)return o.state={style:l},fW(o);o.state={style:s?lW({},s,l):l}}else o.state={style:{}};return o}return cW(r,[{key:"componentDidMount",value:function(){var e=this.props,t=e.isActive,n=e.canBegin;this.mounted=!0,t&&n&&this.runAnimation(this.props)}},{key:"componentDidUpdate",value:function(e){var t=this.props,n=t.isActive,r=t.canBegin,o=t.attributeName,a=t.shouldReAnimate,i=t.to,s=t.from,l=this.state.style;if(r)if(n){if(!(bV(e.to,i)&&e.canBegin&&e.isActive)){var c=!e.canBegin||!e.isActive;this.manager&&this.manager.stop(),this.stopJSAnimation&&this.stopJSAnimation();var u=c||a?s:e.to;if(this.state&&l){var d={style:o?lW({},o,u):u};(o&&l[o]!==u||!o&&l!==u)&&this.setState(d)}this.runAnimation(sW(sW({},this.props),{},{from:u,begin:0}))}}else{var p={style:o?lW({},o,i):i};this.state&&l&&(o&&l[o]!==i||!o&&l!==i)&&this.setState(p)}}},{key:"componentWillUnmount",value:function(){this.mounted=!1;var e=this.props.onAnimationEnd;this.unSubscribe&&this.unSubscribe(),this.manager&&(this.manager.stop(),this.manager=null),this.stopJSAnimation&&this.stopJSAnimation(),e&&e()}},{key:"handleStyleChange",value:function(e){this.changeStyle(e)}},{key:"changeStyle",value:function(e){this.mounted&&this.setState({style:e})}},{key:"runJSAnimation",value:function(e){var t=this,n=e.from,r=e.to,o=e.duration,a=e.easing,i=e.begin,s=e.onAnimationEnd,l=e.onAnimationStart,c=eW(n,r,$V(a),o,this.changeStyle);this.manager.start([l,i,function(){t.stopJSAnimation=c()},o,s])}},{key:"runStepAnimation",value:function(e){var t=this,n=e.steps,r=e.begin,o=e.onAnimationStart,a=n[0],i=a.style,s=a.duration,l=void 0===s?0:s;return this.manager.start([o].concat(oW(n.reduce(function(e,r,o){if(0===o)return e;var a=r.duration,i=r.easing,s=void 0===i?"ease":i,l=r.style,c=r.properties,u=r.onAnimationEnd,d=o>0?n[o-1]:r,p=c||Object.keys(l);if("function"==typeof s||"spring"===s)return[].concat(oW(e),[t.runJSAnimation.bind(t,{from:d.style,to:l,duration:a,easing:s}),a]);var f=NV(p,a,s),g=sW(sW(sW({},d.style),l),{},{transition:f});return[].concat(oW(e),[g,a,u]).filter(CV)},[i,Math.max(l,r)])),[e.onAnimationEnd]))}},{key:"runAnimation",value:function(e){this.manager||(this.manager=EV());var t=e.begin,n=e.duration,r=e.attributeName,o=e.to,a=e.easing,i=e.onAnimationStart,s=e.onAnimationEnd,l=e.steps,c=e.children,u=this.manager;if(this.unSubscribe=u.subscribe(this.handleStyleChange),"function"!=typeof a&&"function"!=typeof c&&"spring"!==a)if(l.length>1)this.runStepAnimation(e);else{var d=r?lW({},r,o):o,p=NV(Object.keys(d),n,a);u.start([i,t,sW(sW({},d),{},{transition:p}),n,s])}else this.runJSAnimation(e)}},{key:"render",value:function(){var t=this.props,n=t.children;t.begin;var r=t.duration;t.attributeName,t.easing;var o=t.isActive;t.steps,t.from,t.to,t.canBegin,t.onAnimationEnd,t.shouldReAnimate,t.onAnimationReStart;var a=rW(t,nW),i=e.Children.count(n),s=this.state.style;if("function"==typeof n)return n(s);if(!o||0===i||r<=0)return n;var l=function(t){var n=t.props,r=n.style,o=void 0===r?{}:r,i=n.className;return e.cloneElement(t,sW(sW({},a),{},{style:sW(sW({},o),s),className:i}))};return 1===i?l(e.Children.only(n)):e.createElement("div",null,e.Children.map(n,function(e){return l(e)}))}}]),r}(e.PureComponent);function bW(e){return bW="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},bW(e)}function yW(){return yW=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},yW.apply(this,arguments)}function vW(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,a,i,s=[],l=!0,c=!1;try{if(a=(n=n.call(e)).next,0===t);else for(;!(l=(r=a.call(n)).done)&&(s.push(r.value),s.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(c)throw o}}return s}}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return wW(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return wW(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function wW(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function SW(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function xW(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?SW(Object(n),!0).forEach(function(t){EW(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):SW(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function EW(e,t,n){var r;return r=function(e,t){if("object"!=bW(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=bW(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(t,"string"),(t="symbol"==bW(r)?r:r+"")in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}mW.displayName="Animate",mW.defaultProps={begin:0,duration:1e3,from:"",to:"",attributeName:"",easing:"ease",isActive:!0,canBegin:!0,steps:[],onAnimationEnd:function(){},onAnimationStart:function(){}},mW.propTypes={from:zH.oneOfType([zH.object,zH.string]),to:zH.oneOfType([zH.object,zH.string]),attributeName:zH.string,duration:zH.number,begin:zH.number,easing:zH.oneOfType([zH.string,zH.func]),steps:zH.arrayOf(zH.shape({duration:zH.number.isRequired,style:zH.object.isRequired,easing:zH.oneOfType([zH.oneOf(["ease","ease-in","ease-out","ease-in-out","linear"]),zH.func]),properties:zH.arrayOf("string"),onAnimationEnd:zH.func})),children:zH.oneOfType([zH.node,zH.func]),isActive:zH.bool,canBegin:zH.bool,onAnimationEnd:zH.func,shouldReAnimate:zH.bool,onAnimationStart:zH.func,onAnimationReStart:zH.func};var kW=function(e,t,n,r,o){var a,i=Math.min(Math.abs(n)/2,Math.abs(r)/2),s=r>=0?1:-1,l=n>=0?1:-1,c=r>=0&&n>=0||r<0&&n<0?1:0;if(i>0&&o instanceof Array){for(var u=[0,0,0,0],d=0;d<4;d++)u[d]=o[d]>i?i:o[d];a="M".concat(e,",").concat(t+s*u[0]),u[0]>0&&(a+="A ".concat(u[0],",").concat(u[0],",0,0,").concat(c,",").concat(e+l*u[0],",").concat(t)),a+="L ".concat(e+n-l*u[1],",").concat(t),u[1]>0&&(a+="A ".concat(u[1],",").concat(u[1],",0,0,").concat(c,",\n ").concat(e+n,",").concat(t+s*u[1])),a+="L ".concat(e+n,",").concat(t+r-s*u[2]),u[2]>0&&(a+="A ".concat(u[2],",").concat(u[2],",0,0,").concat(c,",\n ").concat(e+n-l*u[2],",").concat(t+r)),a+="L ".concat(e+l*u[3],",").concat(t+r),u[3]>0&&(a+="A ".concat(u[3],",").concat(u[3],",0,0,").concat(c,",\n ").concat(e,",").concat(t+r-s*u[3])),a+="Z"}else if(i>0&&o===+o&&o>0){var p=Math.min(i,o);a="M ".concat(e,",").concat(t+s*p,"\n A ").concat(p,",").concat(p,",0,0,").concat(c,",").concat(e+l*p,",").concat(t,"\n L ").concat(e+n-l*p,",").concat(t,"\n A ").concat(p,",").concat(p,",0,0,").concat(c,",").concat(e+n,",").concat(t+s*p,"\n L ").concat(e+n,",").concat(t+r-s*p,"\n A ").concat(p,",").concat(p,",0,0,").concat(c,",").concat(e+n-l*p,",").concat(t+r,"\n L ").concat(e+l*p,",").concat(t+r,"\n A ").concat(p,",").concat(p,",0,0,").concat(c,",").concat(e,",").concat(t+r-s*p," Z")}else a="M ".concat(e,",").concat(t," h ").concat(n," v ").concat(r," h ").concat(-n," Z");return a},AW=function(e,t){if(!e||!t)return!1;var n=e.x,r=e.y,o=t.x,a=t.y,i=t.width,s=t.height;if(Math.abs(i)>0&&Math.abs(s)>0){var l=Math.min(o,o+i),c=Math.max(o,o+i),u=Math.min(a,a+s),d=Math.max(a,a+s);return n>=l&&n<=c&&r>=u&&r<=d}return!1},TW={x:0,y:0,width:0,height:0,radius:0,isAnimationActive:!1,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:"ease"},OW=function(t){var n=xW(xW({},TW),t),r=e.useRef(),o=vW(e.useState(-1),2),a=o[0],i=o[1];e.useEffect(function(){if(r.current&&r.current.getTotalLength)try{var e=r.current.getTotalLength();e&&i(e)}catch(e){}},[]);var s=n.x,l=n.y,c=n.width,u=n.height,d=n.radius,p=n.className,f=n.animationEasing,g=n.animationDuration,h=n.animationBegin,m=n.isAnimationActive,b=n.isUpdateAnimationActive;if(s!==+s||l!==+l||c!==+c||u!==+u||0===c||0===u)return null;var y=hk("recharts-rectangle",p);return b?e.createElement(mW,{canBegin:a>0,from:{width:c,height:u,x:s,y:l},to:{width:c,height:u,x:s,y:l},duration:g,animationEasing:f,isActive:b},function(t){var o=t.width,i=t.height,s=t.x,l=t.y;return e.createElement(mW,{canBegin:a>0,from:"0px ".concat(-1===a?1:a,"px"),to:"".concat(a,"px 0px"),attributeName:"strokeDasharray",begin:h,duration:g,isActive:m,easing:f},e.createElement("path",yW({},FO(n,!0),{className:y,d:kW(s,l,o,i,d),ref:r})))}):e.createElement("path",yW({},FO(n,!0),{className:y,d:kW(s,l,c,u,d)}))},CW=["points","className","baseLinePoints","connectNulls"];function IW(){return IW=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},IW.apply(this,arguments)}function NW(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)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}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function _W(e){return function(e){if(Array.isArray(e))return RW(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return RW(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return RW(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function RW(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var PW=function(e){return e&&e.x===+e.x&&e.y===+e.y},LW=function(e,t){var n=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=[[]];return e.forEach(function(e){PW(e)?t[t.length-1].push(e):t[t.length-1].length>0&&t.push([])}),PW(e[0])&&t[t.length-1].push(e[0]),t[t.length-1].length<=0&&(t=t.slice(0,-1)),t}(e);t&&(n=[n.reduce(function(e,t){return[].concat(_W(e),_W(t))},[])]);var r=n.map(function(e){return e.reduce(function(e,t,n){return"".concat(e).concat(0===n?"M":"L").concat(t.x,",").concat(t.y)},"")}).join("");return 1===n.length?"".concat(r,"Z"):r},DW=function(t){var n=t.points,r=t.className,o=t.baseLinePoints,a=t.connectNulls,i=NW(t,CW);if(!n||!n.length)return null;var s=hk("recharts-polygon",r);if(o&&o.length){var l=i.stroke&&"none"!==i.stroke,c=function(e,t,n){var r=LW(e,n);return"".concat("Z"===r.slice(-1)?r.slice(0,-1):r,"L").concat(LW(t.reverse(),n).slice(1))}(n,o,a);return e.createElement("g",{className:s},e.createElement("path",IW({},FO(i,!0),{fill:"Z"===c.slice(-1)?i.fill:"none",stroke:"none",d:c})),l?e.createElement("path",IW({},FO(i,!0),{fill:"none",d:LW(n,a)})):null,l?e.createElement("path",IW({},FO(i,!0),{fill:"none",d:LW(o,a)})):null)}var u=LW(n,a);return e.createElement("path",IW({},FO(i,!0),{fill:"Z"===u.slice(-1)?i.fill:"none",className:s,d:u}))};function MW(){return MW=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},MW.apply(this,arguments)}var jW=function(e){var t=e.cx,n=e.cy,r=e.r,o=hk("recharts-dot",e.className);return t===+t&&n===+n&&r===+r?i.createElement("circle",MW({},FO(e,!1),xO(e),{className:o,cx:t,cy:n,r:r})):null};function FW(e){return FW="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},FW(e)}var BW=["x","y","top","left","width","height","className"];function UW(){return UW=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},UW.apply(this,arguments)}function zW(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function $W(e,t,n){var r;return r=function(e,t){if("object"!=FW(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=FW(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(t,"string"),(t="symbol"==FW(r)?r:r+"")in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function GW(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)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}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var qW=function(e,t,n,r,o,a){return"M".concat(e,",").concat(o,"v").concat(r,"M").concat(a,",").concat(t,"h").concat(n)},HW=function(t){var n=t.x,r=void 0===n?0:n,o=t.y,a=void 0===o?0:o,i=t.top,s=void 0===i?0:i,l=t.left,c=void 0===l?0:l,u=t.width,d=void 0===u?0:u,p=t.height,f=void 0===p?0:p,g=t.className,h=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?zW(Object(n),!0).forEach(function(t){$W(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):zW(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}({x:r,y:a,top:s,left:c,width:d,height:f},GW(t,BW));return sO(r)&&sO(a)&&sO(d)&&sO(f)&&sO(s)&&sO(c)?e.createElement("path",UW({},FO(h,!0),{className:hk("recharts-cross",g),d:qW(r,a,d,f,s,c)})):null},VW=Hz,WW=Vz,YW=kP;var KW=function(e,t){return e&&e.length?VW(e,YW(t),WW):void 0},XW=Hz,ZW=kP,QW=Zz;var JW=function(e,t){return e&&e.length?XW(e,ZW(t),QW):void 0},eY=["cx","cy","angle","ticks","axisLine"],tY=["ticks","tick","angle","tickFormatter","stroke"];function nY(e){return nY="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},nY(e)}function rY(){return rY=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},rY.apply(this,arguments)}function oY(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function aY(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?oY(Object(n),!0).forEach(function(t){pY(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):oY(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function iY(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)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}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function sY(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,fY(r.key),r)}}function lY(e,t,n){return t=uY(t),function(e,t){if(t&&("object"===nY(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,cY()?Reflect.construct(t,n||[],uY(e).constructor):t.apply(e,n))}function cY(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(cY=function(){return!!e})()}function uY(e){return uY=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},uY(e)}function dY(e,t){return dY=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},dY(e,t)}function pY(e,t,n){return(t=fY(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function fY(e){var t=function(e,t){if("object"!=nY(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=nY(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==nY(t)?t:t+""}var gY=function(t){function n(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n),lY(this,n,arguments)}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&dY(e,t)}(n,t),r=n,o=[{key:"getTickValueCoord",value:function(e){var t=e.coordinate,n=this.props,r=n.angle,o=n.cx,a=n.cy;return wq(o,a,t,r)}},{key:"getTickTextAnchor",value:function(){var e;switch(this.props.orientation){case"left":e="end";break;case"right":e="start";break;default:e="middle"}return e}},{key:"getViewBox",value:function(){var e=this.props,t=e.cx,n=e.cy,r=e.angle,o=e.ticks,a=KW(o,function(e){return e.coordinate||0});return{cx:t,cy:n,startAngle:r,endAngle:r,innerRadius:JW(o,function(e){return e.coordinate||0}).coordinate||0,outerRadius:a.coordinate||0}}},{key:"renderAxisLine",value:function(){var t=this.props,n=t.cx,r=t.cy,o=t.angle,a=t.ticks,i=t.axisLine,s=iY(t,eY),l=a.reduce(function(e,t){return[Math.min(e[0],t.coordinate),Math.max(e[1],t.coordinate)]},[1/0,-1/0]),c=wq(n,r,l[0],o),u=wq(n,r,l[1],o),d=aY(aY(aY({},FO(s,!1)),{},{fill:"none"},FO(i,!1)),{},{x1:c.x,y1:c.y,x2:u.x,y2:u.y});return e.createElement("line",rY({className:"recharts-polar-radius-axis-line"},d))}},{key:"renderTicks",value:function(){var t=this,r=this.props,o=r.ticks,a=r.tick,i=r.angle,s=r.tickFormatter,l=r.stroke,c=iY(r,tY),u=this.getTickTextAnchor(),d=FO(c,!1),p=FO(a,!1),f=o.map(function(r,o){var c=t.getTickValueCoord(r),f=aY(aY(aY(aY({textAnchor:u,transform:"rotate(".concat(90-i,", ").concat(c.x,", ").concat(c.y,")")},d),{},{stroke:"none",fill:l},p),{},{index:o},c),{},{payload:r});return e.createElement(KO,rY({className:hk("recharts-polar-radius-axis-tick",Aq(a)),key:"tick-".concat(r.coordinate)},EO(t.props,r,o)),n.renderTickItem(a,f,s?s(r.value,o):r.value))});return e.createElement(KO,{className:"recharts-polar-radius-axis-ticks"},f)}},{key:"render",value:function(){var t=this.props,n=t.ticks,r=t.axisLine,o=t.tick;return n&&n.length?e.createElement(KO,{className:hk("recharts-polar-radius-axis",this.props.className)},r&&this.renderAxisLine(),o&&this.renderTicks(),Mq.renderCallByParent(this.props,this.getViewBox())):null}}],a=[{key:"renderTickItem",value:function(t,n,r){return e.isValidElement(t)?e.cloneElement(t,n):Vk(t)?t(n):e.createElement(sj,rY({},n,{className:"recharts-polar-radius-axis-tick-value"}),r)}}],o&&sY(r.prototype,o),a&&sY(r,a),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,o,a}(e.PureComponent);function hY(e){return hY="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},hY(e)}function mY(){return mY=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},mY.apply(this,arguments)}function bY(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function yY(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?bY(Object(n),!0).forEach(function(t){kY(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):bY(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function vY(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,AY(r.key),r)}}function wY(e,t,n){return t=xY(t),function(e,t){if(t&&("object"===hY(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,SY()?Reflect.construct(t,n||[],xY(e).constructor):t.apply(e,n))}function SY(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(SY=function(){return!!e})()}function xY(e){return xY=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},xY(e)}function EY(e,t){return EY=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},EY(e,t)}function kY(e,t,n){return(t=AY(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function AY(e){var t=function(e,t){if("object"!=hY(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=hY(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==hY(t)?t:t+""}pY(gY,"displayName","PolarRadiusAxis"),pY(gY,"axisType","radiusAxis"),pY(gY,"defaultProps",{type:"number",radiusAxisId:0,cx:0,cy:0,angle:0,orientation:"right",stroke:"#ccc",axisLine:!0,tick:!0,tickCount:5,allowDataOverflow:!1,scale:"auto",allowDuplicatedCategory:!0});var TY=Math.PI/180,OY=1e-5,CY=function(t){function n(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n),wY(this,n,arguments)}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&EY(e,t)}(n,t),r=n,o=[{key:"getTickLineCoord",value:function(e){var t=this.props,n=t.cx,r=t.cy,o=t.radius,a=t.orientation,i=t.tickSize||8,s=wq(n,r,o,e.coordinate),l=wq(n,r,o+("inner"===a?-1:1)*i,e.coordinate);return{x1:s.x,y1:s.y,x2:l.x,y2:l.y}}},{key:"getTickTextAnchor",value:function(e){var t=this.props.orientation,n=Math.cos(-e.coordinate*TY);return n>OY?"outer"===t?"start":"end":n<-OY?"outer"===t?"end":"start":"middle"}},{key:"renderAxisLine",value:function(){var t=this.props,n=t.cx,r=t.cy,o=t.radius,a=t.axisLine,i=t.axisLineType,s=yY(yY({},FO(this.props,!1)),{},{fill:"none"},FO(a,!1));if("circle"===i)return e.createElement(jW,mY({className:"recharts-polar-angle-axis-line"},s,{cx:n,cy:r,r:o}));var l=this.props.ticks.map(function(e){return wq(n,r,o,e.coordinate)});return e.createElement(DW,mY({className:"recharts-polar-angle-axis-line"},s,{points:l}))}},{key:"renderTicks",value:function(){var t=this,r=this.props,o=r.ticks,a=r.tick,i=r.tickLine,s=r.tickFormatter,l=r.stroke,c=FO(this.props,!1),u=FO(a,!1),d=yY(yY({},c),{},{fill:"none"},FO(i,!1)),p=o.map(function(r,o){var p=t.getTickLineCoord(r),f=yY(yY(yY({textAnchor:t.getTickTextAnchor(r)},c),{},{stroke:"none",fill:l},u),{},{index:o,payload:r,x:p.x2,y:p.y2});return e.createElement(KO,mY({className:hk("recharts-polar-angle-axis-tick",Aq(a)),key:"tick-".concat(r.coordinate)},EO(t.props,r,o)),i&&e.createElement("line",mY({className:"recharts-polar-angle-axis-tick-line"},d,p)),a&&n.renderTickItem(a,f,s?s(r.value,o):r.value))});return e.createElement(KO,{className:"recharts-polar-angle-axis-ticks"},p)}},{key:"render",value:function(){var t=this.props,n=t.ticks,r=t.radius,o=t.axisLine;return r<=0||!n||!n.length?null:e.createElement(KO,{className:hk("recharts-polar-angle-axis",this.props.className)},o&&this.renderAxisLine(),this.renderTicks())}}],a=[{key:"renderTickItem",value:function(t,n,r){return e.isValidElement(t)?e.cloneElement(t,n):Vk(t)?t(n):e.createElement(sj,mY({},n,{className:"recharts-polar-angle-axis-tick-value"}),r)}}],o&&vY(r.prototype,o),a&&vY(r,a),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,o,a}(e.PureComponent);kY(CY,"displayName","PolarAngleAxis"),kY(CY,"axisType","angleAxis"),kY(CY,"defaultProps",{type:"category",angleAxisId:0,scale:"auto",cx:0,cy:0,orientation:"outer",axisLine:!0,tickLine:!0,tickSize:8,tick:!0,hide:!1,allowDuplicatedCategory:!0});var IY=I_(Object.getPrototypeOf,Object),NY=Rk,_Y=IY,RY=Pk,PY=Function.prototype,LY=Object.prototype,DY=PY.toString,MY=LY.hasOwnProperty,jY=DY.call(Object);var FY=function(e){if(!RY(e)||"[object Object]"!=NY(e))return!1;var t=_Y(e);if(null===t)return!0;var n=MY.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&DY.call(n)==jY},BY=Rk,UY=Pk;var zY=function(e){return!0===e||!1===e||UY(e)&&"[object Boolean]"==BY(e)};function $Y(e){return $Y="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},$Y(e)}function GY(){return GY=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},GY.apply(this,arguments)}function qY(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,a,i,s=[],l=!0,c=!1;try{if(a=(n=n.call(e)).next,0===t);else for(;!(l=(r=a.call(n)).done)&&(s.push(r.value),s.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(c)throw o}}return s}}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return HY(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return HY(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function HY(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function VY(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function WY(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?VY(Object(n),!0).forEach(function(t){YY(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):VY(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function YY(e,t,n){var r;return r=function(e,t){if("object"!=$Y(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=$Y(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(t,"string"),(t="symbol"==$Y(r)?r:r+"")in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var KY,XY=function(e,t,n,r,o){var a,i=n-r;return a="M ".concat(e,",").concat(t),a+="L ".concat(e+n,",").concat(t),a+="L ".concat(e+n-i/2,",").concat(t+o),a+="L ".concat(e+n-i/2-r,",").concat(t+o),a+="L ".concat(e,",").concat(t," Z")},ZY={x:0,y:0,upperWidth:0,lowerWidth:0,height:0,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:"ease"},QY=function(t){var n=WY(WY({},ZY),t),r=e.useRef(),o=qY(e.useState(-1),2),a=o[0],i=o[1];e.useEffect(function(){if(r.current&&r.current.getTotalLength)try{var e=r.current.getTotalLength();e&&i(e)}catch(e){}},[]);var s=n.x,l=n.y,c=n.upperWidth,u=n.lowerWidth,d=n.height,p=n.className,f=n.animationEasing,g=n.animationDuration,h=n.animationBegin,m=n.isUpdateAnimationActive;if(s!==+s||l!==+l||c!==+c||u!==+u||d!==+d||0===c&&0===u||0===d)return null;var b=hk("recharts-trapezoid",p);return m?e.createElement(mW,{canBegin:a>0,from:{upperWidth:0,lowerWidth:0,height:d,x:s,y:l},to:{upperWidth:c,lowerWidth:u,height:d,x:s,y:l},duration:g,animationEasing:f,isActive:m},function(t){var o=t.upperWidth,i=t.lowerWidth,s=t.height,l=t.x,c=t.y;return e.createElement(mW,{canBegin:a>0,from:"0px ".concat(-1===a?1:a,"px"),to:"".concat(a,"px 0px"),attributeName:"strokeDasharray",begin:h,duration:g,easing:f},e.createElement("path",GY({},FO(n,!0),{className:b,d:XY(l,c,o,i,s),ref:r})))}):e.createElement("g",null,e.createElement("path",GY({},FO(n,!0),{className:b,d:XY(s,l,c,u,d)})))},JY=["option","shapeType","propTransformer","activeClassName","isActive"];function eK(e){return eK="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},eK(e)}function tK(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)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}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function nK(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function rK(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?nK(Object(n),!0).forEach(function(t){oK(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):nK(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function oK(e,t,n){var r;return r=function(e,t){if("object"!=eK(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=eK(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(t,"string"),(t="symbol"==eK(r)?r:r+"")in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function aK(e,t){return rK(rK({},t),e)}function iK(t){var n=t.shapeType,r=t.elementProps;switch(n){case"rectangle":return e.createElement(OW,r);case"trapezoid":return e.createElement(QY,r);case"sector":return e.createElement(aH,r);case"symbols":if(function(e){return"symbols"===e}(n))return e.createElement(UI,r);break;default:return null}}function sK(t){var n,r=t.option,o=t.shapeType,a=t.propTransformer,i=void 0===a?aK:a,s=t.activeClassName,l=void 0===s?"recharts-active-shape":s,c=t.isActive,u=tK(t,JY);if(e.isValidElement(r))n=e.cloneElement(r,rK(rK({},u),function(t){return e.isValidElement(t)?t.props:t}(r)));else if(Vk(r))n=r(u);else if(FY(r)&&!zY(r)){var d=i(r,u);n=e.createElement(iK,{shapeType:o,elementProps:d})}else{var p=u;n=e.createElement(iK,{shapeType:o,elementProps:p})}return c?e.createElement(KO,{className:l},n):n}function lK(e,t){return null!=t&&"trapezoids"in e.props}function cK(e,t){return null!=t&&"sectors"in e.props}function uK(e,t){return null!=t&&"points"in e.props}function dK(e,t){var n,r,o=e.x===(null==t||null===(n=t.labelViewBox)||void 0===n?void 0:n.x)||e.x===t.x,a=e.y===(null==t||null===(r=t.labelViewBox)||void 0===r?void 0:r.y)||e.y===t.y;return o&&a}function pK(e,t){var n=e.endAngle===t.endAngle,r=e.startAngle===t.startAngle;return n&&r}function fK(e,t){var n=e.x===t.x,r=e.y===t.y,o=e.z===t.z;return n&&r&&o}function gK(e){var t=e.activeTooltipItem,n=e.graphicalItem,r=e.itemData,o=function(e,t){var n;return lK(e,t)?n="trapezoids":cK(e,t)?n="sectors":uK(e,t)&&(n="points"),n}(n,t),a=function(e,t){var n,r;return lK(e,t)?null===(n=t.tooltipPayload)||void 0===n||null===(n=n[0])||void 0===n||null===(n=n.payload)||void 0===n?void 0:n.payload:cK(e,t)?null===(r=t.tooltipPayload)||void 0===r||null===(r=r[0])||void 0===r||null===(r=r.payload)||void 0===r?void 0:r.payload:uK(e,t)?t.payload:{}}(n,t),i=r.filter(function(e,r){var i=d$(a,e),s=n.props[o].filter(function(e){var r=function(e,t){var n;return lK(e,t)?n=dK:cK(e,t)?n=pK:uK(e,t)&&(n=fK),n}(n,t);return r(e,t)}),l=n.props[o].indexOf(s[s.length-1]);return i&&r===l});return r.indexOf(i[i.length-1])}function hK(e){return hK="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},hK(e)}function mK(){return mK=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},mK.apply(this,arguments)}function bK(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function yK(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?bK(Object(n),!0).forEach(function(t){kK(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):bK(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function vK(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,AK(r.key),r)}}function wK(e,t,n){return t=xK(t),function(e,t){if(t&&("object"===hK(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,SK()?Reflect.construct(t,n||[],xK(e).constructor):t.apply(e,n))}function SK(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(SK=function(){return!!e})()}function xK(e){return xK=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},xK(e)}function EK(e,t){return EK=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},EK(e,t)}function kK(e,t,n){return(t=AK(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function AK(e){var t=function(e,t){if("object"!=hK(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=hK(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"==hK(t)?t:t+""}var TK=function(t){function n(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n),kK(t=wK(this,n,[e]),"pieRef",null),kK(t,"sectorRefs",[]),kK(t,"id",uO("recharts-pie-")),kK(t,"handleAnimationEnd",function(){var e=t.props.onAnimationEnd;t.setState({isAnimationFinished:!0}),Vk(e)&&e()}),kK(t,"handleAnimationStart",function(){var e=t.props.onAnimationStart;t.setState({isAnimationFinished:!1}),Vk(e)&&e()}),t.state={isAnimationFinished:!e.isAnimationActive,prevIsAnimationActive:e.isAnimationActive,prevAnimationId:e.animationId,sectorToFocus:0},t}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&EK(e,t)}(n,t),r=n,o=[{key:"isActiveIndex",value:function(e){var t=this.props.activeIndex;return Array.isArray(t)?-1!==t.indexOf(e):e===t}},{key:"hasActiveIndex",value:function(){var e=this.props.activeIndex;return Array.isArray(e)?0!==e.length:e||0===e}},{key:"renderLabels",value:function(t){if(this.props.isAnimationActive&&!this.state.isAnimationFinished)return null;var r=this.props,o=r.label,a=r.labelLine,i=r.dataKey,s=r.valueKey,l=FO(this.props,!1),c=FO(o,!1),u=FO(a,!1),d=o&&o.offsetRadius||20,p=t.map(function(t,r){var p=(t.startAngle+t.endAngle)/2,f=wq(t.cx,t.cy,t.outerRadius+d,p),g=yK(yK(yK(yK({},l),t),{},{stroke:"none"},c),{},{index:r,textAnchor:n.getTextAnchor(f.x,t.cx)},f),h=yK(yK(yK(yK({},l),t),{},{fill:"none",stroke:t.fill},u),{},{index:r,points:[wq(t.cx,t.cy,t.outerRadius,p),f]}),m=i;return GT(i)&>(s)?m="value":GT(i)&&(m=s),e.createElement(KO,{key:"label-".concat(t.startAngle,"-").concat(t.endAngle,"-").concat(t.midAngle,"-").concat(r)},a&&n.renderLabelLineItem(a,h,"line"),n.renderLabelItem(o,g,zG(t,m)))});return e.createElement(KO,{className:"recharts-pie-labels"},p)}},{key:"renderSectorsStatically",value:function(t){var n=this,r=this.props,o=r.activeShape,a=r.blendStroke,i=r.inactiveShape;return t.map(function(r,s){if(0===(null==r?void 0:r.startAngle)&&0===(null==r?void 0:r.endAngle)&&1!==t.length)return null;var l=n.isActiveIndex(s),c=i&&n.hasActiveIndex()?i:null,u=l?o:c,d=yK(yK({},r),{},{stroke:a?r.fill:r.stroke,tabIndex:-1});return e.createElement(KO,mK({ref:function(e){e&&!n.sectorRefs.includes(e)&&n.sectorRefs.push(e)},tabIndex:-1,className:"recharts-pie-sector"},EO(n.props,r,s),{key:"sector-".concat(null==r?void 0:r.startAngle,"-").concat(null==r?void 0:r.endAngle,"-").concat(r.midAngle,"-").concat(s)}),e.createElement(sK,mK({option:u,isActive:l,shapeType:"sector"},d)))})}},{key:"renderSectorsWithAnimation",value:function(){var t=this,n=this.props,r=n.sectors,o=n.isAnimationActive,a=n.animationBegin,i=n.animationDuration,s=n.animationEasing,l=n.animationId,c=this.state,u=c.prevSectors,d=c.prevIsAnimationActive;return e.createElement(mW,{begin:a,duration:i,isActive:o,easing:s,from:{t:0},to:{t:1},key:"pie-".concat(l,"-").concat(d),onAnimationStart:this.handleAnimationStart,onAnimationEnd:this.handleAnimationEnd},function(n){var o=n.t,a=[],i=(r&&r[0]).startAngle;return r.forEach(function(e,t){var n=u&&u[t],r=t>0?$T(e,"paddingAngle",0):0;if(n){var s=fO(n.endAngle-n.startAngle,e.endAngle-e.startAngle),l=yK(yK({},e),{},{startAngle:i+r,endAngle:i+s(o)+r});a.push(l),i=l.endAngle}else{var c=e.endAngle,d=e.startAngle,p=fO(0,c-d)(o),f=yK(yK({},e),{},{startAngle:i+r,endAngle:i+p+r});a.push(f),i=f.endAngle}}),e.createElement(KO,null,t.renderSectorsStatically(a))})}},{key:"attachKeyboardHandlers",value:function(e){var t=this;e.onkeydown=function(e){if(!e.altKey)switch(e.key){case"ArrowLeft":var n=++t.state.sectorToFocus%t.sectorRefs.length;t.sectorRefs[n].focus(),t.setState({sectorToFocus:n});break;case"ArrowRight":var r=--t.state.sectorToFocus<0?t.sectorRefs.length-1:t.state.sectorToFocus%t.sectorRefs.length;t.sectorRefs[r].focus(),t.setState({sectorToFocus:r});break;case"Escape":t.sectorRefs[t.state.sectorToFocus].blur(),t.setState({sectorToFocus:0})}}}},{key:"renderSectors",value:function(){var e=this.props,t=e.sectors,n=e.isAnimationActive,r=this.state.prevSectors;return!(n&&t&&t.length)||r&&d$(r,t)?this.renderSectorsStatically(t):this.renderSectorsWithAnimation()}},{key:"componentDidMount",value:function(){this.pieRef&&this.attachKeyboardHandlers(this.pieRef)}},{key:"render",value:function(){var t=this,n=this.props,r=n.hide,o=n.sectors,a=n.className,i=n.label,s=n.cx,l=n.cy,c=n.innerRadius,u=n.outerRadius,d=n.isAnimationActive,p=this.state.isAnimationFinished;if(r||!o||!o.length||!sO(s)||!sO(l)||!sO(c)||!sO(u))return null;var f=hk("recharts-pie",a);return e.createElement(KO,{tabIndex:this.props.rootTabIndex,className:f,ref:function(e){t.pieRef=e}},this.renderSectors(),i&&this.renderLabels(o),Mq.renderCallByParent(this.props,null,!1),(!d||p)&&Xq.renderCallByParent(this.props,o,!1))}}],a=[{key:"getDerivedStateFromProps",value:function(e,t){return t.prevIsAnimationActive!==e.isAnimationActive?{prevIsAnimationActive:e.isAnimationActive,prevAnimationId:e.animationId,curSectors:e.sectors,prevSectors:[],isAnimationFinished:!0}:e.isAnimationActive&&e.animationId!==t.prevAnimationId?{prevAnimationId:e.animationId,curSectors:e.sectors,prevSectors:t.curSectors,isAnimationFinished:!0}:e.sectors!==t.curSectors?{curSectors:e.sectors,isAnimationFinished:!0}:null}},{key:"getTextAnchor",value:function(e,t){return e>t?"start":e<t?"end":"middle"}},{key:"renderLabelLineItem",value:function(t,n,r){if(e.isValidElement(t))return e.cloneElement(t,n);if(Vk(t))return t(n);var o=hk("recharts-pie-label-line","boolean"!=typeof t?t.className:"");return e.createElement(bH,mK({},n,{key:r,type:"linear",className:o}))}},{key:"renderLabelItem",value:function(t,n,r){if(e.isValidElement(t))return e.cloneElement(t,n);var o=r;if(Vk(t)&&(o=t(n),e.isValidElement(o)))return o;var a=hk("recharts-pie-label-text","boolean"==typeof t||Vk(t)?"":t.className);return e.createElement(sj,mK({},n,{alignmentBaseline:"middle",className:a}),o)}}],o&&vK(r.prototype,o),a&&vK(r,a),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,o,a}(e.PureComponent);KY=TK,kK(TK,"displayName","Pie"),kK(TK,"defaultProps",{stroke:"#fff",fill:"#808080",legendType:"rect",cx:"50%",cy:"50%",startAngle:0,endAngle:360,innerRadius:0,outerRadius:"80%",paddingAngle:0,labelLine:!0,hide:!1,minAngle:0,isAnimationActive:!DD,animationBegin:400,animationDuration:1500,animationEasing:"ease",nameKey:"name",blendStroke:!1,rootTabIndex:0}),kK(TK,"parseDeltaAngle",function(e,t){return aO(t-e)*Math.min(Math.abs(t-e),360)}),kK(TK,"getRealPieData",function(e){var t=e.data,n=e.children,r=FO(e,!1),o=PO(n,kM);return t&&t.length?t.map(function(e,t){return yK(yK(yK({payload:e},r),e),o&&o[t]&&o[t].props)}):o&&o.length?o.map(function(e){return yK(yK({},r),e.props)}):[]}),kK(TK,"parseCoordinateOfPie",function(e,t){var n=t.top,r=t.left,o=t.width,a=t.height,i=Sq(o,a);return{cx:r+dO(e.cx,o,o/2),cy:n+dO(e.cy,a,a/2),innerRadius:dO(e.innerRadius,i,0),outerRadius:dO(e.outerRadius,i,.8*i),maxRadius:e.maxRadius||Math.sqrt(o*o+a*a)/2}}),kK(TK,"getComposedData",function(e){var t=e.item,n=e.offset,r=void 0!==t.type.defaultProps?yK(yK({},t.type.defaultProps),t.props):t.props,o=KY.getRealPieData(r);if(!o||!o.length)return null;var a=r.cornerRadius,i=r.startAngle,s=r.endAngle,l=r.paddingAngle,c=r.dataKey,u=r.nameKey,d=r.valueKey,p=r.tooltipType,f=Math.abs(r.minAngle),g=KY.parseCoordinateOfPie(r,n),h=KY.parseDeltaAngle(i,s),m=Math.abs(h),b=c;GT(c)&>(d)?(ZO(!1,'Use "dataKey" to specify the value of pie,\n the props "valueKey" will be deprecated in 1.1.0'),b="value"):GT(c)&&(ZO(!1,'Use "dataKey" to specify the value of pie,\n the props "valueKey" will be deprecated in 1.1.0'),b=d);var y,v,w=o.filter(function(e){return 0!==zG(e,b,0)}).length,S=m-w*f-(m>=360?w:w-1)*l,x=o.reduce(function(e,t){var n=zG(t,b,0);return e+(sO(n)?n:0)},0);x>0&&(y=o.map(function(e,t){var n,r=zG(e,b,0),o=zG(e,u,t),s=(sO(r)?r:0)/x,c=(n=t?v.endAngle+aO(h)*l*(0!==r?1:0):i)+aO(h)*((0!==r?f:0)+s*S),d=(n+c)/2,m=(g.innerRadius+g.outerRadius)/2,y=[{name:o,value:r,payload:e,dataKey:b,type:p}],w=wq(g.cx,g.cy,m,d);return v=yK(yK(yK({percent:s,cornerRadius:a,name:o,tooltipPayload:y,midAngle:d,middleRadius:m,tooltipPosition:w},e),g),{},{value:zG(e,b),startAngle:n,endAngle:c,payload:e,paddingAngle:aO(h)*l})}));return yK(yK({},g),{},{sectors:y,data:o})});var OK=Math.ceil,CK=Math.max;var IK=function(e,t,n,r){for(var o=-1,a=CK(OK((t-e)/(n||1)),0),i=Array(a);a--;)i[r?a:++o]=e,e+=n;return i},NK=sM,_K=1/0;var RK=function(e){return e?(e=NK(e))===_K||e===-1/0?17976931348623157e292*(e<0?-1:1):e==e?e:0:0===e?e:0},PK=IK,LK=oD,DK=RK;var MK=function(e){return function(t,n,r){return r&&"number"!=typeof r&&LK(t,n,r)&&(n=r=void 0),t=DK(t),void 0===n?(n=t,t=0):n=DK(n),r=void 0===r?t<n?1:-1:DK(r),PK(t,n,r,e)}}();function jK(e){return jK="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},jK(e)}function FK(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function BK(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?FK(Object(n),!0).forEach(function(t){UK(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):FK(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function UK(e,t,n){var r;return r=function(e,t){if("object"!=jK(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=jK(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(t,"string"),(t="symbol"==jK(r)?r:r+"")in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var zK=["Webkit","Moz","O","ms"];function $K(e){return $K="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},$K(e)}function GK(){return GK=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},GK.apply(this,arguments)}function qK(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function HK(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?qK(Object(n),!0).forEach(function(t){ZK(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):qK(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function VK(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,QK(r.key),r)}}function WK(e,t,n){return t=KK(t),function(e,t){if(t&&("object"===$K(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,YK()?Reflect.construct(t,n||[],KK(e).constructor):t.apply(e,n))}function YK(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(YK=function(){return!!e})()}function KK(e){return KK=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},KK(e)}function XK(e,t){return XK=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},XK(e,t)}function ZK(e,t,n){return(t=QK(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function QK(e){var t=function(e,t){if("object"!=$K(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=$K(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"==$K(t)?t:t+""}var JK=function(e){return e.changedTouches&&!!e.changedTouches.length},eX=function(t){function n(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n),ZK(t=WK(this,n,[e]),"handleDrag",function(e){t.leaveTimer&&(clearTimeout(t.leaveTimer),t.leaveTimer=null),t.state.isTravellerMoving?t.handleTravellerMove(e):t.state.isSlideMoving&&t.handleSlideDrag(e)}),ZK(t,"handleTouchMove",function(e){null!=e.changedTouches&&e.changedTouches.length>0&&t.handleDrag(e.changedTouches[0])}),ZK(t,"handleDragEnd",function(){t.setState({isTravellerMoving:!1,isSlideMoving:!1},function(){var e=t.props,n=e.endIndex,r=e.onDragEnd,o=e.startIndex;null==r||r({endIndex:n,startIndex:o})}),t.detachDragEndListener()}),ZK(t,"handleLeaveWrapper",function(){(t.state.isTravellerMoving||t.state.isSlideMoving)&&(t.leaveTimer=window.setTimeout(t.handleDragEnd,t.props.leaveTimeOut))}),ZK(t,"handleEnterSlideOrTraveller",function(){t.setState({isTextActive:!0})}),ZK(t,"handleLeaveSlideOrTraveller",function(){t.setState({isTextActive:!1})}),ZK(t,"handleSlideDragStart",function(e){var n=JK(e)?e.changedTouches[0]:e;t.setState({isTravellerMoving:!1,isSlideMoving:!0,slideMoveStartX:n.pageX}),t.attachDragEndListener()}),t.travellerDragStartHandlers={startX:t.handleTravellerDragStart.bind(t,"startX"),endX:t.handleTravellerDragStart.bind(t,"endX")},t.state={},t}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&XK(e,t)}(n,t),r=n,o=[{key:"componentWillUnmount",value:function(){this.leaveTimer&&(clearTimeout(this.leaveTimer),this.leaveTimer=null),this.detachDragEndListener()}},{key:"getIndex",value:function(e){var t=e.startX,r=e.endX,o=this.state.scaleValues,a=this.props,i=a.gap,s=a.data.length-1,l=Math.min(t,r),c=Math.max(t,r),u=n.getIndexInRange(o,l),d=n.getIndexInRange(o,c);return{startIndex:u-u%i,endIndex:d===s?s:d-d%i}}},{key:"getTextOfTick",value:function(e){var t=this.props,n=t.data,r=t.tickFormatter,o=t.dataKey,a=zG(n[e],o,e);return Vk(r)?r(a,e):a}},{key:"attachDragEndListener",value:function(){window.addEventListener("mouseup",this.handleDragEnd,!0),window.addEventListener("touchend",this.handleDragEnd,!0),window.addEventListener("mousemove",this.handleDrag,!0)}},{key:"detachDragEndListener",value:function(){window.removeEventListener("mouseup",this.handleDragEnd,!0),window.removeEventListener("touchend",this.handleDragEnd,!0),window.removeEventListener("mousemove",this.handleDrag,!0)}},{key:"handleSlideDrag",value:function(e){var t=this.state,n=t.slideMoveStartX,r=t.startX,o=t.endX,a=this.props,i=a.x,s=a.width,l=a.travellerWidth,c=a.startIndex,u=a.endIndex,d=a.onChange,p=e.pageX-n;p>0?p=Math.min(p,i+s-l-o,i+s-l-r):p<0&&(p=Math.max(p,i-r,i-o));var f=this.getIndex({startX:r+p,endX:o+p});f.startIndex===c&&f.endIndex===u||!d||d(f),this.setState({startX:r+p,endX:o+p,slideMoveStartX:e.pageX})}},{key:"handleTravellerDragStart",value:function(e,t){var n=JK(t)?t.changedTouches[0]:t;this.setState({isSlideMoving:!1,isTravellerMoving:!0,movingTravellerId:e,brushMoveStartX:n.pageX}),this.attachDragEndListener()}},{key:"handleTravellerMove",value:function(e){var t=this.state,n=t.brushMoveStartX,r=t.movingTravellerId,o=t.endX,a=t.startX,i=this.state[r],s=this.props,l=s.x,c=s.width,u=s.travellerWidth,d=s.onChange,p=s.gap,f=s.data,g={startX:this.state.startX,endX:this.state.endX},h=e.pageX-n;h>0?h=Math.min(h,l+c-u-i):h<0&&(h=Math.max(h,l-i)),g[r]=i+h;var m=this.getIndex(g),b=m.startIndex,y=m.endIndex;this.setState(ZK(ZK({},r,i+h),"brushMoveStartX",e.pageX),function(){var e;d&&(e=f.length-1,("startX"===r&&(o>a?b%p===0:y%p===0)||o<a&&y===e||"endX"===r&&(o>a?y%p===0:b%p===0)||o>a&&y===e)&&d(m))})}},{key:"handleTravellerMoveKeyboard",value:function(e,t){var n=this,r=this.state,o=r.scaleValues,a=r.startX,i=r.endX,s=this.state[t],l=o.indexOf(s);if(-1!==l){var c=l+e;if(!(-1===c||c>=o.length)){var u=o[c];"startX"===t&&u>=i||"endX"===t&&u<=a||this.setState(ZK({},t,u),function(){n.props.onChange(n.getIndex({startX:n.state.startX,endX:n.state.endX}))})}}}},{key:"renderBackground",value:function(){var t=this.props,n=t.x,r=t.y,o=t.width,a=t.height,i=t.fill,s=t.stroke;return e.createElement("rect",{stroke:s,fill:i,x:n,y:r,width:o,height:a})}},{key:"renderPanorama",value:function(){var t=this.props,n=t.x,r=t.y,o=t.width,a=t.height,i=t.data,s=t.children,l=t.padding,c=e.Children.only(s);return c?e.cloneElement(c,{x:n,y:r,width:o,height:a,margin:l,compact:!0,data:i}):null}},{key:"renderTravellerLayer",value:function(t,r){var o,a,i=this,s=this.props,l=s.y,c=s.travellerWidth,u=s.height,d=s.traveller,p=s.ariaLabel,f=s.data,g=s.startIndex,h=s.endIndex,m=Math.max(t,this.props.x),b=HK(HK({},FO(this.props,!1)),{},{x:m,y:l,width:c,height:u}),y=p||"Min value: ".concat(null===(o=f[g])||void 0===o?void 0:o.name,", Max value: ").concat(null===(a=f[h])||void 0===a?void 0:a.name);return e.createElement(KO,{tabIndex:0,role:"slider","aria-label":y,"aria-valuenow":t,className:"recharts-brush-traveller",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.travellerDragStartHandlers[r],onTouchStart:this.travellerDragStartHandlers[r],onKeyDown:function(e){["ArrowLeft","ArrowRight"].includes(e.key)&&(e.preventDefault(),e.stopPropagation(),i.handleTravellerMoveKeyboard("ArrowRight"===e.key?1:-1,r))},onFocus:function(){i.setState({isTravellerFocused:!0})},onBlur:function(){i.setState({isTravellerFocused:!1})},style:{cursor:"col-resize"}},n.renderTraveller(d,b))}},{key:"renderSlide",value:function(t,n){var r=this.props,o=r.y,a=r.height,i=r.stroke,s=r.travellerWidth,l=Math.min(t,n)+s,c=Math.max(Math.abs(n-t)-s,0);return e.createElement("rect",{className:"recharts-brush-slide",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.handleSlideDragStart,onTouchStart:this.handleSlideDragStart,style:{cursor:"move"},stroke:"none",fill:i,fillOpacity:.2,x:l,y:o,width:c,height:a})}},{key:"renderText",value:function(){var t=this.props,n=t.startIndex,r=t.endIndex,o=t.y,a=t.height,i=t.travellerWidth,s=t.stroke,l=this.state,c=l.startX,u=l.endX,d={pointerEvents:"none",fill:s};return e.createElement(KO,{className:"recharts-brush-texts"},e.createElement(sj,GK({textAnchor:"end",verticalAnchor:"middle",x:Math.min(c,u)-5,y:o+a/2},d),this.getTextOfTick(n)),e.createElement(sj,GK({textAnchor:"start",verticalAnchor:"middle",x:Math.max(c,u)+i+5,y:o+a/2},d),this.getTextOfTick(r)))}},{key:"render",value:function(){var t=this.props,n=t.data,r=t.className,o=t.children,a=t.x,i=t.y,s=t.width,l=t.height,c=t.alwaysShowText,u=this.state,d=u.startX,p=u.endX,f=u.isTextActive,g=u.isSlideMoving,h=u.isTravellerMoving,m=u.isTravellerFocused;if(!n||!n.length||!sO(a)||!sO(i)||!sO(s)||!sO(l)||s<=0||l<=0)return null;var b=hk("recharts-brush",r),y=1===e.Children.count(o),v=function(e,t){var n=e.replace(/(\w)/,function(e){return e.toUpperCase()}),r=zK.reduce(function(e,r){return BK(BK({},e),{},UK({},r+n,t))},{});return r[e]=t,r}("userSelect","none");return e.createElement(KO,{className:b,onMouseLeave:this.handleLeaveWrapper,onTouchMove:this.handleTouchMove,style:v},this.renderBackground(),y&&this.renderPanorama(),this.renderSlide(d,p),this.renderTravellerLayer(d,"startX"),this.renderTravellerLayer(p,"endX"),(f||g||h||m||c)&&this.renderText())}}],a=[{key:"renderDefaultTraveller",value:function(t){var n=t.x,r=t.y,o=t.width,a=t.height,i=t.stroke,s=Math.floor(r+a/2)-1;return e.createElement(e.Fragment,null,e.createElement("rect",{x:n,y:r,width:o,height:a,fill:i,stroke:"none"}),e.createElement("line",{x1:n+1,y1:s,x2:n+o-1,y2:s,fill:"none",stroke:"#fff"}),e.createElement("line",{x1:n+1,y1:s+2,x2:n+o-1,y2:s+2,fill:"none",stroke:"#fff"}))}},{key:"renderTraveller",value:function(t,r){return e.isValidElement(t)?e.cloneElement(t,r):Vk(t)?t(r):n.renderDefaultTraveller(r)}},{key:"getDerivedStateFromProps",value:function(e,t){var n=e.data,r=e.width,o=e.x,a=e.travellerWidth,i=e.updateId,s=e.startIndex,l=e.endIndex;if(n!==t.prevData||i!==t.prevUpdateId)return HK({prevData:n,prevTravellerWidth:a,prevUpdateId:i,prevX:o,prevWidth:r},n&&n.length?function(e){var t=e.data,n=e.startIndex,r=e.endIndex,o=e.x,a=e.width,i=e.travellerWidth;if(!t||!t.length)return{};var s=t.length,l=Mj().domain(MK(0,s)).range([o,o+a-i]),c=l.domain().map(function(e){return l(e)});return{isTextActive:!1,isSlideMoving:!1,isTravellerMoving:!1,isTravellerFocused:!1,startX:l(n),endX:l(r),scale:l,scaleValues:c}}({data:n,width:r,x:o,travellerWidth:a,startIndex:s,endIndex:l}):{scale:null,scaleValues:null});if(t.scale&&(r!==t.prevWidth||o!==t.prevX||a!==t.prevTravellerWidth)){t.scale.range([o,o+r-a]);var c=t.scale.domain().map(function(e){return t.scale(e)});return{prevData:n,prevTravellerWidth:a,prevUpdateId:i,prevX:o,prevWidth:r,startX:t.scale(e.startIndex),endX:t.scale(e.endIndex),scaleValues:c}}return null}},{key:"getIndexInRange",value:function(e,t){for(var n=0,r=e.length-1;r-n>1;){var o=Math.floor((n+r)/2);e[o]>t?r=o:n=o}return t>=e[r]?r:n}}],o&&VK(r.prototype,o),a&&VK(r,a),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,o,a}(e.PureComponent);ZK(eX,"displayName","Brush"),ZK(eX,"defaultProps",{height:40,travellerWidth:5,gap:1,fill:"#fff",stroke:"#666",padding:{top:1,right:1,bottom:1,left:1},leaveTimeOut:1e3,alwaysShowText:!1});var tX=wL;var nX=function(e,t){var n;return tX(e,function(e,r,o){return!(n=t(e,r,o))}),!!n},rX=yN,oX=kP,aX=nX,iX=mk,sX=oD;var lX=function(e,t,n){var r=iX(e)?rX:aX;return n&&sX(e,t,n)&&(t=void 0),r(e,oX(t))},cX=function(e,t){var n=e.alwaysShow,r=e.ifOverflow;return n&&(r="extendDomain"),r===t},uX=GL;var dX=function(e,t,n){"__proto__"==t&&uX?uX(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n},pX=dX,fX=bL,gX=kP;var hX=function(e,t){var n={};return t=gX(t),fX(e,function(e,r,o){pX(n,r,t(e,r,o))}),n};var mX=function(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(!t(e[n],n,e))return!1;return!0},bX=wL;var yX=function(e,t){var n=!0;return bX(e,function(e,r,o){return n=!!t(e,r,o)}),n},vX=mX,wX=yX,SX=kP,xX=mk,EX=oD;var kX=function(e,t,n){var r=xX(e)?vX:wX;return n&&EX(e,t,n)&&(t=void 0),r(e,SX(t))},AX=["x","y"];function TX(e){return TX="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},TX(e)}function OX(){return OX=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},OX.apply(this,arguments)}function CX(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function IX(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?CX(Object(n),!0).forEach(function(t){NX(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):CX(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function NX(e,t,n){var r;return r=function(e,t){if("object"!=TX(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=TX(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(t,"string"),(t="symbol"==TX(r)?r:r+"")in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function _X(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)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}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function RX(e,t){var n=e.x,r=e.y,o=_X(e,AX),a="".concat(n),i=parseInt(a,10),s="".concat(r),l=parseInt(s,10),c="".concat(t.height||o.height),u=parseInt(c,10),d="".concat(t.width||o.width),p=parseInt(d,10);return IX(IX(IX(IX(IX({},t),o),i?{x:i}:{}),l?{y:l}:{}),{},{height:u,width:p,name:t.name,radius:t.radius})}function PX(t){return e.createElement(sK,OX({shapeType:"rectangle",propTransformer:RX,activeClassName:"recharts-active-bar"},t))}var LX,DX=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return function(n,r){if("number"==typeof e)return e;var o=sO(n)||function(e){return GT(e)}(n);return o?e(n,r):(o||("production"!==process.env.NODE_ENV?hG(0,"minPointSize callback function received a value with type of ".concat(TX(n),". Currently only numbers or null/undefined are supported.")):hG()),t)}},MX=["value","background"];function jX(e){return jX="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},jX(e)}function FX(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)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}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function BX(){return BX=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},BX.apply(this,arguments)}function UX(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function zX(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?UX(Object(n),!0).forEach(function(t){WX(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):UX(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function $X(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,YX(r.key),r)}}function GX(e,t,n){return t=HX(t),function(e,t){if(t&&("object"===jX(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,qX()?Reflect.construct(t,n||[],HX(e).constructor):t.apply(e,n))}function qX(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(qX=function(){return!!e})()}function HX(e){return HX=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},HX(e)}function VX(e,t){return VX=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},VX(e,t)}function WX(e,t,n){return(t=YX(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function YX(e){var t=function(e,t){if("object"!=jX(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=jX(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"==jX(t)?t:t+""}var KX=function(t){function n(){var e;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n);for(var t=arguments.length,r=new Array(t),o=0;o<t;o++)r[o]=arguments[o];return WX(e=GX(this,n,[].concat(r)),"state",{isAnimationFinished:!1}),WX(e,"id",uO("recharts-bar-")),WX(e,"handleAnimationEnd",function(){var t=e.props.onAnimationEnd;e.setState({isAnimationFinished:!0}),t&&t()}),WX(e,"handleAnimationStart",function(){var t=e.props.onAnimationStart;e.setState({isAnimationFinished:!1}),t&&t()}),e}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&VX(e,t)}(n,t),r=n,o=[{key:"renderRectanglesStatically",value:function(t){var n=this,r=this.props,o=r.shape,a=r.dataKey,i=r.activeIndex,s=r.activeBar,l=FO(this.props,!1);return t&&t.map(function(t,r){var c=r===i,u=c?s:o,d=zX(zX(zX({},l),t),{},{isActive:c,option:u,index:r,dataKey:a,onAnimationStart:n.handleAnimationStart,onAnimationEnd:n.handleAnimationEnd});return e.createElement(KO,BX({className:"recharts-bar-rectangle"},EO(n.props,t,r),{key:"rectangle-".concat(null==t?void 0:t.x,"-").concat(null==t?void 0:t.y,"-").concat(null==t?void 0:t.value,"-").concat(r)}),e.createElement(PX,d))})}},{key:"renderRectanglesWithAnimation",value:function(){var t=this,n=this.props,r=n.data,o=n.layout,a=n.isAnimationActive,i=n.animationBegin,s=n.animationDuration,l=n.animationEasing,c=n.animationId,u=this.state.prevData;return e.createElement(mW,{begin:i,duration:s,isActive:a,easing:l,from:{t:0},to:{t:1},key:"bar-".concat(c),onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},function(n){var a=n.t,i=r.map(function(e,t){var n=u&&u[t];if(n){var r=fO(n.x,e.x),i=fO(n.y,e.y),s=fO(n.width,e.width),l=fO(n.height,e.height);return zX(zX({},e),{},{x:r(a),y:i(a),width:s(a),height:l(a)})}if("horizontal"===o){var c=fO(0,e.height)(a);return zX(zX({},e),{},{y:e.y+e.height-c,height:c})}var d=fO(0,e.width)(a);return zX(zX({},e),{},{width:d})});return e.createElement(KO,null,t.renderRectanglesStatically(i))})}},{key:"renderRectangles",value:function(){var e=this.props,t=e.data,n=e.isAnimationActive,r=this.state.prevData;return!(n&&t&&t.length)||r&&d$(r,t)?this.renderRectanglesStatically(t):this.renderRectanglesWithAnimation()}},{key:"renderBackground",value:function(){var t=this,n=this.props,r=n.data,o=n.dataKey,a=n.activeIndex,i=FO(this.props.background,!1);return r.map(function(n,r){n.value;var s=n.background,l=FX(n,MX);if(!s)return null;var c=zX(zX(zX(zX(zX({},l),{},{fill:"#eee"},s),i),EO(t.props,n,r)),{},{onAnimationStart:t.handleAnimationStart,onAnimationEnd:t.handleAnimationEnd,dataKey:o,index:r,className:"recharts-bar-background-rectangle"});return e.createElement(PX,BX({key:"background-bar-".concat(r),option:t.props.background,isActive:r===a},c))})}},{key:"renderErrorBar",value:function(t,n){if(this.props.isAnimationActive&&!this.state.isAnimationFinished)return null;var r=this.props,o=r.data,a=r.xAxis,i=r.yAxis,s=r.layout,l=PO(r.children,IG);if(!l)return null;var c="vertical"===s?o[0].height/2:o[0].width/2,u=function(e,t){var n=Array.isArray(e.value)?e.value[1]:e.value;return{x:e.x,y:e.y,value:n,errorVal:zG(e,t)}},d={clipPath:t?"url(#clipPath-".concat(n,")"):null};return e.createElement(KO,d,l.map(function(t){return e.cloneElement(t,{key:"error-bar-".concat(n,"-").concat(t.props.dataKey),data:o,xAxis:a,yAxis:i,layout:s,offset:c,dataPointFormatter:u})}))}},{key:"render",value:function(){var t=this.props,n=t.hide,r=t.data,o=t.className,a=t.xAxis,i=t.yAxis,s=t.left,l=t.top,c=t.width,u=t.height,d=t.isAnimationActive,p=t.background,f=t.id;if(n||!r||!r.length)return null;var g=this.state.isAnimationFinished,h=hk("recharts-bar",o),m=a&&a.allowDataOverflow,b=i&&i.allowDataOverflow,y=m||b,v=GT(f)?this.id:f;return e.createElement(KO,{className:h},m||b?e.createElement("defs",null,e.createElement("clipPath",{id:"clipPath-".concat(v)},e.createElement("rect",{x:m?s:s-c/2,y:b?l:l-u/2,width:m?c:2*c,height:b?u:2*u}))):null,e.createElement(KO,{className:"recharts-bar-rectangles",clipPath:y?"url(#clipPath-".concat(v,")"):null},p?this.renderBackground():null,this.renderRectangles()),this.renderErrorBar(y,v),(!d||g)&&Xq.renderCallByParent(this.props,r))}}],a=[{key:"getDerivedStateFromProps",value:function(e,t){return e.animationId!==t.prevAnimationId?{prevAnimationId:e.animationId,curData:e.data,prevData:t.curData}:e.data!==t.curData?{curData:e.data}:null}}],o&&$X(r.prototype,o),a&&$X(r,a),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,o,a}(e.PureComponent);function XX(e){return XX="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},XX(e)}function ZX(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,tZ(r.key),r)}}function QX(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function JX(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?QX(Object(n),!0).forEach(function(t){eZ(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):QX(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function eZ(e,t,n){return(t=tZ(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function tZ(e){var t=function(e,t){if("object"!=XX(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=XX(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==XX(t)?t:t+""}LX=KX,WX(KX,"displayName","Bar"),WX(KX,"defaultProps",{xAxisId:0,yAxisId:0,legendType:"rect",minPointSize:0,hide:!1,data:[],layout:"vertical",activeBar:!1,isAnimationActive:!DD,animationBegin:0,animationDuration:400,animationEasing:"ease"}),WX(KX,"getComposedData",function(e){var t=e.props,n=e.item,r=e.barPosition,o=e.bandSize,a=e.xAxis,i=e.yAxis,s=e.xAxisTicks,l=e.yAxisTicks,c=e.stackedData,u=e.dataStartIndex,d=e.displayedData,p=e.offset,f=function(e,t){if(!e)return null;for(var n=0,r=e.length;n<r;n++)if(e[n].item===t)return e[n].position;return null}(r,n);if(!f)return null;var g=t.layout,h=n.type.defaultProps,m=void 0!==h?zX(zX({},h),n.props):n.props,b=m.dataKey,y=m.children,v=m.minPointSize,w="horizontal"===g?i:a,S=c?w.scale.domain():null,x=function(e){var t=e.numericAxis,n=t.scale.domain();if("number"===t.type){var r=Math.min(n[0],n[1]),o=Math.max(n[0],n[1]);return r<=0&&o>=0?0:o<0?o:r}return n[0]}({numericAxis:w}),E=PO(y,kM),k=d.map(function(e,t){var r,d,p,h,m,y;c?r=function(e,t){if(!t||2!==t.length||!sO(t[0])||!sO(t[1]))return e;var n=Math.min(t[0],t[1]),r=Math.max(t[0],t[1]),o=[e[0],e[1]];return(!sO(e[0])||e[0]<n)&&(o[0]=n),(!sO(e[1])||e[1]>r)&&(o[1]=r),o[0]>r&&(o[0]=r),o[1]<n&&(o[1]=n),o}(c[u+t],S):(r=zG(e,b),Array.isArray(r)||(r=[x,r]));var w=DX(v,LX.defaultProps.minPointSize)(r[1],t);if("horizontal"===g){var k,A=[i.scale(r[0]),i.scale(r[1])],T=A[0],O=A[1];d=oq({axis:a,ticks:s,bandSize:o,offset:f.offset,entry:e,index:t}),p=null!==(k=null!=O?O:T)&&void 0!==k?k:void 0,h=f.size;var C=T-O;if(m=Number.isNaN(C)?0:C,y={x:d,y:i.y,width:h,height:i.height},Math.abs(w)>0&&Math.abs(m)<Math.abs(w)){var I=aO(m||w)*(Math.abs(w)-Math.abs(m));p-=I,m+=I}}else{var N=[a.scale(r[0]),a.scale(r[1])],_=N[0],R=N[1];if(d=_,p=oq({axis:i,ticks:l,bandSize:o,offset:f.offset,entry:e,index:t}),h=R-_,m=f.size,y={x:a.x,y:p,width:a.width,height:m},Math.abs(w)>0&&Math.abs(h)<Math.abs(w))h+=aO(h||w)*(Math.abs(w)-Math.abs(h))}return zX(zX(zX({},e),{},{x:d,y:p,width:h,height:m,value:c?r:r[1],payload:e,background:y},E&&E[t]&&E[t].props),{},{tooltipPayload:[dq(n,e)],tooltipPosition:{x:d+h/2,y:p+m/2}})});return zX({data:k,layout:g},p)});var nZ=function(e,t,n,r,o){var a=e.width,i=e.height,s=e.layout,l=e.children,c=Object.keys(t),u={left:n.left,leftMirror:n.left,right:a-n.right,rightMirror:a-n.right,top:n.top,topMirror:n.top,bottom:i-n.bottom,bottomMirror:i-n.bottom},d=!!LO(l,KX);return c.reduce(function(a,i){var l,c,p,f,g,h=t[i],m=h.orientation,b=h.domain,y=h.padding,v=void 0===y?{}:y,w=h.mirror,S=h.reversed,x="".concat(m).concat(w?"Mirror":"");if("number"===h.type&&("gap"===h.padding||"no-gap"===h.padding)){var E=b[1]-b[0],k=1/0,A=h.categoricalDomain.sort(hO);if(A.forEach(function(e,t){t>0&&(k=Math.min((e||0)-(A[t-1]||0),k))}),Number.isFinite(k)){var T=k/E,O="vertical"===h.layout?n.height:n.width;if("gap"===h.padding&&(l=T*O/2),"no-gap"===h.padding){var C=dO(e.barCategoryGap,T*O),I=T*O/2;l=I-C-(I-C)/O*C}}}c="xAxis"===r?[n.left+(v.left||0)+(l||0),n.left+n.width-(v.right||0)-(l||0)]:"yAxis"===r?"horizontal"===s?[n.top+n.height-(v.bottom||0),n.top+(v.top||0)]:[n.top+(v.top||0)+(l||0),n.top+n.height-(v.bottom||0)-(l||0)]:h.range,S&&(c=[c[1],c[0]]);var N=ZG(h,o,d),_=N.scale,R=N.realScaleType;_.domain(b).range(c),JG(_);var P=nq(_,JX(JX({},h),{},{realScaleType:R}));"xAxis"===r?(g="top"===m&&!w||"bottom"===m&&w,p=n.left,f=u[x]-g*h.height):"yAxis"===r&&(g="left"===m&&!w||"right"===m&&w,p=u[x]-g*h.width,f=n.top);var L=JX(JX(JX({},h),P),{},{realScaleType:R,x:p,y:f,scale:_,width:"xAxis"===r?n.width:h.width,height:"yAxis"===r?n.height:h.height});return L.bandSize=cq(L,P),h.hide||"xAxis"!==r?h.hide||(u[x]+=(g?-1:1)*L.width):u[x]+=(g?-1:1)*L.height,JX(JX({},a),{},eZ({},i,L))},{})},rZ=function(e,t){var n=e.x,r=e.y,o=t.x,a=t.y;return{x:Math.min(n,o),y:Math.min(r,a),width:Math.abs(o-n),height:Math.abs(a-r)}},oZ=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.scale=t}return t=e,n=[{key:"domain",get:function(){return this.scale.domain}},{key:"range",get:function(){return this.scale.range}},{key:"rangeMin",get:function(){return this.range()[0]}},{key:"rangeMax",get:function(){return this.range()[1]}},{key:"bandwidth",get:function(){return this.scale.bandwidth}},{key:"apply",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.bandAware,r=t.position;if(void 0!==e){if(r)switch(r){case"start":default:return this.scale(e);case"middle":var o=this.bandwidth?this.bandwidth()/2:0;return this.scale(e)+o;case"end":var a=this.bandwidth?this.bandwidth():0;return this.scale(e)+a}if(n){var i=this.bandwidth?this.bandwidth()/2:0;return this.scale(e)+i}return this.scale(e)}}},{key:"isInRange",value:function(e){var t=this.range(),n=t[0],r=t[t.length-1];return n<=r?e>=n&&e<=r:e>=r&&e<=n}}],r=[{key:"create",value:function(t){return new e(t)}}],n&&ZX(t.prototype,n),r&&ZX(t,r),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,n,r}();eZ(oZ,"EPS",1e-4);var aZ=function(e){var t=Object.keys(e).reduce(function(t,n){return JX(JX({},t),{},eZ({},n,oZ.create(e[n])))},{});return JX(JX({},t),{},{apply:function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=n.bandAware,o=n.position;return hX(e,function(e,n){return t[n].apply(e,{bandAware:r,position:o})})},isInRange:function(e){return kX(e,function(e,n){return t[n].isInRange(e)})}})};var iZ=kP,sZ=j_,lZ=z_;var cZ=function(e){return function(t,n,r){var o=Object(t);if(!sZ(t)){var a=iZ(n);t=lZ(t),n=function(e){return a(o[e],e,o)}}var i=e(t,n,r);return i>-1?o[a?t[i]:i]:void 0}},uZ=RK;var dZ=AP,pZ=kP,fZ=function(e){var t=uZ(e),n=t%1;return t==t?n?t-n:t:0},gZ=Math.max;var hZ=function(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var o=null==n?0:fZ(n);return o<0&&(o=gZ(r+o,0)),dZ(e,pZ(t),o)},mZ=cZ(hZ),bZ=mT(function(e){return{x:e.left,y:e.top,width:e.width,height:e.height}},function(e){return["l",e.left,"t",e.top,"w",e.width,"h",e.height].join("")});function yZ(e){return yZ="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},yZ(e)}var vZ=e.createContext(void 0),wZ=e.createContext(void 0),SZ=e.createContext(void 0),xZ=e.createContext({}),EZ=e.createContext(void 0),kZ=e.createContext(0),AZ=e.createContext(0),TZ=function(t){var n=t.state,r=n.xAxisMap,o=n.yAxisMap,a=n.offset,i=t.clipPathId,s=t.children,l=t.width,c=t.height,u=bZ(a);return e.createElement(vZ.Provider,{value:r},e.createElement(wZ.Provider,{value:o},e.createElement(xZ.Provider,{value:a},e.createElement(SZ.Provider,{value:u},e.createElement(EZ.Provider,{value:i},e.createElement(kZ.Provider,{value:c},e.createElement(AZ.Provider,{value:l},s)))))))};function OZ(e){var t=Object.keys(e);return 0===t.length?"There are no available ids.":"Available ids are: ".concat(t,".")}var CZ=function(t){var n=e.useContext(vZ);null==n&&("production"!==process.env.NODE_ENV?hG(0,"Could not find Recharts context; are you sure this is rendered inside a Recharts wrapper component?"):hG());var r=n[t];return null==r&&("production"!==process.env.NODE_ENV?hG(0,'Could not find xAxis by id "'.concat(t,'" [').concat(yZ(t),"]. ").concat(OZ(n))):hG()),r},IZ=function(t){var n=e.useContext(wZ);null==n&&("production"!==process.env.NODE_ENV?hG(0,"Could not find Recharts context; are you sure this is rendered inside a Recharts wrapper component?"):hG());var r=n[t];return null==r&&("production"!==process.env.NODE_ENV?hG(0,'Could not find yAxis by id "'.concat(t,'" [').concat(yZ(t),"]. ").concat(OZ(n))):hG()),r},NZ=function(){return e.useContext(AZ)},_Z=function(){return e.useContext(kZ)};function RZ(e){return RZ="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},RZ(e)}function PZ(e,t,n){return t&&function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,zZ(r.key),r)}}(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function LZ(e,t,n){return t=MZ(t),function(e,t){if(t&&("object"===RZ(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,DZ()?Reflect.construct(t,n||[],MZ(e).constructor):t.apply(e,n))}function DZ(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(DZ=function(){return!!e})()}function MZ(e){return MZ=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},MZ(e)}function jZ(e,t){return jZ=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},jZ(e,t)}function FZ(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function BZ(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?FZ(Object(n),!0).forEach(function(t){UZ(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):FZ(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function UZ(e,t,n){return(t=zZ(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function zZ(e){var t=function(e,t){if("object"!=RZ(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=RZ(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"==RZ(t)?t:t+""}function $Z(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,a,i,s=[],l=!0,c=!1;try{if(a=(n=n.call(e)).next,0===t);else for(;!(l=(r=a.call(n)).done)&&(s.push(r.value),s.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(c)throw o}}return s}}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return GZ(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return GZ(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function GZ(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function qZ(){return qZ=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},qZ.apply(this,arguments)}function HZ(t){var n=t.x,r=t.y,o=t.segment,a=t.xAxisId,i=t.yAxisId,s=t.shape,l=t.className,c=t.alwaysShow,u=e.useContext(EZ),d=CZ(a),p=IZ(i),f=e.useContext(SZ);if(!u||!f)return null;ZO(void 0===c,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.');var g=function(e,t,n,r,o,a,i,s,l){var c=o.x,u=o.y,d=o.width,p=o.height;if(n){var f=l.y,g=e.y.apply(f,{position:a});if(cX(l,"discard")&&!e.y.isInRange(g))return null;var h=[{x:c+d,y:g},{x:c,y:g}];return"left"===s?h.reverse():h}if(t){var m=l.x,b=e.x.apply(m,{position:a});if(cX(l,"discard")&&!e.x.isInRange(b))return null;var y=[{x:b,y:u+p},{x:b,y:u}];return"top"===i?y.reverse():y}if(r){var v=l.segment.map(function(t){return e.apply(t,{position:a})});return cX(l,"discard")&&lX(v,function(t){return!e.isInRange(t)})?null:v}return null}(aZ({x:d.scale,y:p.scale}),lO(n),lO(r),o&&2===o.length,f,t.position,d.orientation,p.orientation,t);if(!g)return null;var h=$Z(g,2),m=h[0],b=m.x,y=m.y,v=h[1],w=v.x,S=v.y,x=BZ(BZ({clipPath:cX(t,"hidden")?"url(#".concat(u,")"):void 0},FO(t,!0)),{},{x1:b,y1:y,x2:w,y2:S});return e.createElement(KO,{className:hk("recharts-reference-line",l)},function(t,n){return e.isValidElement(t)?e.cloneElement(t,n):Vk(t)?t(n):e.createElement("line",qZ({},n,{className:"recharts-reference-line-line"}))}(s,x),Mq.renderCallByParent(t,function(e){var t=e.x1,n=e.y1,r=e.x2,o=e.y2;return rZ({x:t,y:n},{x:r,y:o})}({x1:b,y1:y,x2:w,y2:S})))}var VZ=function(t){function n(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n),LZ(this,n,arguments)}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&jZ(e,t)}(n,t),PZ(n,[{key:"render",value:function(){return e.createElement(HZ,this.props)}}])}(e.Component);function WZ(){return WZ=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},WZ.apply(this,arguments)}function YZ(e){return YZ="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},YZ(e)}function KZ(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function XZ(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?KZ(Object(n),!0).forEach(function(t){nQ(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):KZ(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function ZZ(e,t,n){return t&&function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,rQ(r.key),r)}}(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function QZ(e,t,n){return t=eQ(t),function(e,t){if(t&&("object"===YZ(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,JZ()?Reflect.construct(t,n||[],eQ(e).constructor):t.apply(e,n))}function JZ(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(JZ=function(){return!!e})()}function eQ(e){return eQ=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},eQ(e)}function tQ(e,t){return tQ=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},tQ(e,t)}function nQ(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=function(e,t){if("object"!=YZ(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=YZ(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"==YZ(t)?t:t+""}UZ(VZ,"displayName","ReferenceLine"),UZ(VZ,"defaultProps",{isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,fill:"none",stroke:"#ccc",fillOpacity:1,strokeWidth:1,position:"middle"});var oQ=function(t){function n(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n),QZ(this,n,arguments)}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&tQ(e,t)}(n,t),ZZ(n,[{key:"render",value:function(){var t=this.props,r=t.x,o=t.y,a=t.r,i=t.alwaysShow,s=t.clipPathId,l=lO(r),c=lO(o);if(ZO(void 0===i,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.'),!l||!c)return null;var u=function(e){var t=e.x,n=e.y,r=e.xAxis,o=e.yAxis,a=aZ({x:r.scale,y:o.scale}),i=a.apply({x:t,y:n},{bandAware:!0});return cX(e,"discard")&&!a.isInRange(i)?null:i}(this.props);if(!u)return null;var d=u.x,p=u.y,f=this.props,g=f.shape,h=f.className,m=XZ(XZ({clipPath:cX(this.props,"hidden")?"url(#".concat(s,")"):void 0},FO(this.props,!0)),{},{cx:d,cy:p});return e.createElement(KO,{className:hk("recharts-reference-dot",h)},n.renderDot(g,m),Mq.renderCallByParent(this.props,{x:d-a,y:p-a,width:2*a,height:2*a}))}}])}(e.Component);function aQ(){return aQ=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},aQ.apply(this,arguments)}function iQ(e){return iQ="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},iQ(e)}function sQ(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function lQ(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?sQ(Object(n),!0).forEach(function(t){gQ(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):sQ(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function cQ(e,t,n){return t&&function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,hQ(r.key),r)}}(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function uQ(e,t,n){return t=pQ(t),function(e,t){if(t&&("object"===iQ(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,dQ()?Reflect.construct(t,n||[],pQ(e).constructor):t.apply(e,n))}function dQ(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(dQ=function(){return!!e})()}function pQ(e){return pQ=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},pQ(e)}function fQ(e,t){return fQ=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},fQ(e,t)}function gQ(e,t,n){return(t=hQ(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function hQ(e){var t=function(e,t){if("object"!=iQ(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=iQ(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"==iQ(t)?t:t+""}nQ(oQ,"displayName","ReferenceDot"),nQ(oQ,"defaultProps",{isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,r:10,fill:"#fff",stroke:"#ccc",fillOpacity:1,strokeWidth:1}),nQ(oQ,"renderDot",function(t,n){return e.isValidElement(t)?e.cloneElement(t,n):Vk(t)?t(n):e.createElement(jW,WZ({},n,{cx:n.cx,cy:n.cy,className:"recharts-reference-dot-dot"}))});var mQ=function(t){function n(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n),uQ(this,n,arguments)}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&fQ(e,t)}(n,t),cQ(n,[{key:"render",value:function(){var t=this.props,r=t.x1,o=t.x2,a=t.y1,i=t.y2,s=t.className,l=t.alwaysShow,c=t.clipPathId;ZO(void 0===l,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.');var u=lO(r),d=lO(o),p=lO(a),f=lO(i),g=this.props.shape;if(!(u||d||p||f||g))return null;var h=function(e,t,n,r,o){var a=o.x1,i=o.x2,s=o.y1,l=o.y2,c=o.xAxis,u=o.yAxis;if(!c||!u)return null;var d=aZ({x:c.scale,y:u.scale}),p={x:e?d.x.apply(a,{position:"start"}):d.x.rangeMin,y:n?d.y.apply(s,{position:"start"}):d.y.rangeMin},f={x:t?d.x.apply(i,{position:"end"}):d.x.rangeMax,y:r?d.y.apply(l,{position:"end"}):d.y.rangeMax};return!cX(o,"discard")||d.isInRange(p)&&d.isInRange(f)?rZ(p,f):null}(u,d,p,f,this.props);if(!h&&!g)return null;var m=cX(this.props,"hidden")?"url(#".concat(c,")"):void 0;return e.createElement(KO,{className:hk("recharts-reference-area",s)},n.renderRect(g,lQ(lQ({clipPath:m},FO(this.props,!0)),h)),Mq.renderCallByParent(this.props,h))}}])}(e.Component);function bQ(e,t,n){if(t<1)return[];if(1===t&&void 0===n)return e;for(var r=[],o=0;o<e.length;o+=t)r.push(e[o]);return r}function yQ(e,t,n){return function(e){var t=e.width,n=e.height,r=function(e){return(e%180+180)%180}(arguments.length>1&&void 0!==arguments[1]?arguments[1]:0),o=r*Math.PI/180,a=Math.atan(n/t),i=o>a&&o<Math.PI-a?n/Math.sin(o):t/Math.cos(o);return Math.abs(i)}({width:e.width+t.width,height:e.height+t.height},n)}function vQ(e,t,n,r,o){if(e*t<e*r||e*t>e*o)return!1;var a=n();return e*(t-e*a/2-r)>=0&&e*(t+e*a/2-o)<=0}function wQ(e){return wQ="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},wQ(e)}function SQ(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function xQ(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?SQ(Object(n),!0).forEach(function(t){EQ(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):SQ(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function EQ(e,t,n){var r;return r=function(e,t){if("object"!=wQ(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=wQ(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(t,"string"),(t="symbol"==wQ(r)?r:r+"")in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function kQ(e,t,n){var r=e.tick,o=e.ticks,a=e.viewBox,i=e.minTickGap,s=e.orientation,l=e.interval,c=e.tickFormatter,u=e.unit,d=e.angle;if(!o||!o.length||!r)return[];if(sO(l)||DD)return function(e,t){return bQ(e,t+1)}(o,"number"==typeof l&&sO(l)?l:0);var p=[],f="top"===s||"bottom"===s?"width":"height",g=u&&"width"===f?RM(u,{fontSize:t,letterSpacing:n}):{width:0,height:0},h=function(e,r){var o=Vk(c)?c(e.value,r):e.value;return"width"===f?yQ(RM(o,{fontSize:t,letterSpacing:n}),g,d):RM(o,{fontSize:t,letterSpacing:n})[f]},m=o.length>=2?aO(o[1].coordinate-o[0].coordinate):1,b=function(e,t,n){var r="width"===n,o=e.x,a=e.y,i=e.width,s=e.height;return 1===t?{start:r?o:a,end:r?o+i:a+s}:{start:r?o+i:a+s,end:r?o:a}}(a,m,f);return"equidistantPreserveStart"===l?function(e,t,n,r,o){for(var a,i=(r||[]).slice(),s=t.start,l=t.end,c=0,u=1,d=s,p=function(){var t=null==r?void 0:r[c];if(void 0===t)return{v:bQ(r,u)};var a,i=c,p=function(){return void 0===a&&(a=n(t,i)),a},f=t.coordinate,g=0===c||vQ(e,f,p,d,l);g||(c=0,d=s,u+=1),g&&(d=f+e*(p()/2+o),c+=u)};u<=i.length;)if(a=p())return a.v;return[]}(m,b,h,o,i):(p="preserveStart"===l||"preserveStartEnd"===l?function(e,t,n,r,o,a){var i=(r||[]).slice(),s=i.length,l=t.start,c=t.end;if(a){var u=r[s-1],d=n(u,s-1),p=e*(u.coordinate+e*d/2-c);i[s-1]=u=xQ(xQ({},u),{},{tickCoord:p>0?u.coordinate-p*e:u.coordinate}),vQ(e,u.tickCoord,function(){return d},l,c)&&(c=u.tickCoord-e*(d/2+o),i[s-1]=xQ(xQ({},u),{},{isShow:!0}))}for(var f=a?s-1:s,g=function(t){var r,a=i[t],s=function(){return void 0===r&&(r=n(a,t)),r};if(0===t){var u=e*(a.coordinate-e*s()/2-l);i[t]=a=xQ(xQ({},a),{},{tickCoord:u<0?a.coordinate-u*e:a.coordinate})}else i[t]=a=xQ(xQ({},a),{},{tickCoord:a.coordinate});vQ(e,a.tickCoord,s,l,c)&&(l=a.tickCoord+e*(s()/2+o),i[t]=xQ(xQ({},a),{},{isShow:!0}))},h=0;h<f;h++)g(h);return i}(m,b,h,o,i,"preserveStartEnd"===l):function(e,t,n,r,o){for(var a=(r||[]).slice(),i=a.length,s=t.start,l=t.end,c=function(t){var r,c=a[t],u=function(){return void 0===r&&(r=n(c,t)),r};if(t===i-1){var d=e*(c.coordinate+e*u()/2-l);a[t]=c=xQ(xQ({},c),{},{tickCoord:d>0?c.coordinate-d*e:c.coordinate})}else a[t]=c=xQ(xQ({},c),{},{tickCoord:c.coordinate});vQ(e,c.tickCoord,u,s,l)&&(l=c.tickCoord-e*(u()/2+o),a[t]=xQ(xQ({},c),{},{isShow:!0}))},u=i-1;u>=0;u--)c(u);return a}(m,b,h,o,i),p.filter(function(e){return e.isShow}))}gQ(mQ,"displayName","ReferenceArea"),gQ(mQ,"defaultProps",{isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,r:10,fill:"#ccc",fillOpacity:.5,stroke:"none",strokeWidth:1}),gQ(mQ,"renderRect",function(t,n){return e.isValidElement(t)?e.cloneElement(t,n):Vk(t)?t(n):e.createElement(OW,aQ({},n,{className:"recharts-reference-area-rect"}))});var AQ=["viewBox"],TQ=["viewBox"],OQ=["ticks"];function CQ(e){return CQ="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},CQ(e)}function IQ(){return IQ=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},IQ.apply(this,arguments)}function NQ(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function _Q(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?NQ(Object(n),!0).forEach(function(t){FQ(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):NQ(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function RQ(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)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}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function PQ(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,BQ(r.key),r)}}function LQ(e,t,n){return t=MQ(t),function(e,t){if(t&&("object"===CQ(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,DQ()?Reflect.construct(t,n||[],MQ(e).constructor):t.apply(e,n))}function DQ(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(DQ=function(){return!!e})()}function MQ(e){return MQ=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},MQ(e)}function jQ(e,t){return jQ=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},jQ(e,t)}function FQ(e,t,n){return(t=BQ(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function BQ(e){var t=function(e,t){if("object"!=CQ(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=CQ(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"==CQ(t)?t:t+""}var UQ=function(t){function n(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n),(t=LQ(this,n,[e])).state={fontSize:"",letterSpacing:""},t}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&jQ(e,t)}(n,t),r=n,o=[{key:"shouldComponentUpdate",value:function(e,t){var n=e.viewBox,r=RQ(e,AQ),o=this.props,a=o.viewBox,i=RQ(o,TQ);return!mO(n,a)||!mO(r,i)||!mO(t,this.state)}},{key:"componentDidMount",value:function(){var e=this.layerReference;if(e){var t=e.getElementsByClassName("recharts-cartesian-axis-tick-value")[0];t&&this.setState({fontSize:window.getComputedStyle(t).fontSize,letterSpacing:window.getComputedStyle(t).letterSpacing})}}},{key:"getTickLineCoord",value:function(e){var t,n,r,o,a,i,s=this.props,l=s.x,c=s.y,u=s.width,d=s.height,p=s.orientation,f=s.tickSize,g=s.mirror,h=s.tickMargin,m=g?-1:1,b=e.tickSize||f,y=sO(e.tickCoord)?e.tickCoord:e.coordinate;switch(p){case"top":t=n=e.coordinate,i=(r=(o=c+ +!g*d)-m*b)-m*h,a=y;break;case"left":r=o=e.coordinate,a=(t=(n=l+ +!g*u)-m*b)-m*h,i=y;break;case"right":r=o=e.coordinate,a=(t=(n=l+ +g*u)+m*b)+m*h,i=y;break;default:t=n=e.coordinate,i=(r=(o=c+ +g*d)+m*b)+m*h,a=y}return{line:{x1:t,y1:r,x2:n,y2:o},tick:{x:a,y:i}}}},{key:"getTickTextAnchor",value:function(){var e,t=this.props,n=t.orientation,r=t.mirror;switch(n){case"left":e=r?"start":"end";break;case"right":e=r?"end":"start";break;default:e="middle"}return e}},{key:"getTickVerticalAnchor",value:function(){var e=this.props,t=e.orientation,n=e.mirror,r="end";switch(t){case"left":case"right":r="middle";break;case"top":r=n?"start":"end";break;default:r=n?"end":"start"}return r}},{key:"renderAxisLine",value:function(){var t=this.props,n=t.x,r=t.y,o=t.width,a=t.height,i=t.orientation,s=t.mirror,l=t.axisLine,c=_Q(_Q(_Q({},FO(this.props,!1)),FO(l,!1)),{},{fill:"none"});if("top"===i||"bottom"===i){var u=+("top"===i&&!s||"bottom"===i&&s);c=_Q(_Q({},c),{},{x1:n,y1:r+u*a,x2:n+o,y2:r+u*a})}else{var d=+("left"===i&&!s||"right"===i&&s);c=_Q(_Q({},c),{},{x1:n+d*o,y1:r,x2:n+d*o,y2:r+a})}return e.createElement("line",IQ({},c,{className:hk("recharts-cartesian-axis-line",$T(l,"className"))}))}},{key:"renderTicks",value:function(t,r,o){var a=this,i=this.props,s=i.tickLine,l=i.stroke,c=i.tick,u=i.tickFormatter,d=i.unit,p=kQ(_Q(_Q({},this.props),{},{ticks:t}),r,o),f=this.getTickTextAnchor(),g=this.getTickVerticalAnchor(),h=FO(this.props,!1),m=FO(c,!1),b=_Q(_Q({},h),{},{fill:"none"},FO(s,!1)),y=p.map(function(t,r){var o=a.getTickLineCoord(t),i=o.line,y=o.tick,v=_Q(_Q(_Q(_Q({textAnchor:f,verticalAnchor:g},h),{},{stroke:"none",fill:l},m),y),{},{index:r,payload:t,visibleTicksCount:p.length,tickFormatter:u});return e.createElement(KO,IQ({className:"recharts-cartesian-axis-tick",key:"tick-".concat(t.value,"-").concat(t.coordinate,"-").concat(t.tickCoord)},EO(a.props,t,r)),s&&e.createElement("line",IQ({},b,i,{className:hk("recharts-cartesian-axis-tick-line",$T(s,"className"))})),c&&n.renderTickItem(c,v,"".concat(Vk(u)?u(t.value,r):t.value).concat(d||"")))});return e.createElement("g",{className:"recharts-cartesian-axis-ticks"},y)}},{key:"render",value:function(){var t=this,n=this.props,r=n.axisLine,o=n.width,a=n.height,i=n.ticksGenerator,s=n.className;if(n.hide)return null;var l=this.props,c=l.ticks,u=RQ(l,OQ),d=c;return Vk(i)&&(d=c&&c.length>0?i(this.props):i(u)),o<=0||a<=0||!d||!d.length?null:e.createElement(KO,{className:hk("recharts-cartesian-axis",s),ref:function(e){t.layerReference=e}},r&&this.renderAxisLine(),this.renderTicks(d,this.state.fontSize,this.state.letterSpacing),Mq.renderCallByParent(this.props))}}],a=[{key:"renderTickItem",value:function(t,n,r){var o=hk(n.className,"recharts-cartesian-axis-tick-value");return e.isValidElement(t)?e.cloneElement(t,_Q(_Q({},n),{},{className:o})):Vk(t)?t(_Q(_Q({},n),{},{className:o})):e.createElement(sj,IQ({},n,{className:"recharts-cartesian-axis-tick-value"}),r)}}],o&&PQ(r.prototype,o),a&&PQ(r,a),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,o,a}(e.Component);FQ(UQ,"displayName","CartesianAxis"),FQ(UQ,"defaultProps",{x:0,y:0,width:0,height:0,viewBox:{x:0,y:0,width:0,height:0},orientation:"bottom",ticks:[],stroke:"#666",tickLine:!0,axisLine:!0,tick:!0,mirror:!1,minTickGap:5,tickSize:6,tickMargin:2,interval:"preserveEnd"});var zQ=["x1","y1","x2","y2","key"],$Q=["offset"];function GQ(e){return GQ="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},GQ(e)}function qQ(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function HQ(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?qQ(Object(n),!0).forEach(function(t){VQ(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):qQ(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function VQ(e,t,n){var r;return r=function(e,t){if("object"!=GQ(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=GQ(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(t,"string"),(t="symbol"==GQ(r)?r:r+"")in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function WQ(){return WQ=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},WQ.apply(this,arguments)}function YQ(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)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}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var KQ=function(t){var n=t.fill;if(!n||"none"===n)return null;var r=t.fillOpacity,o=t.x,a=t.y,i=t.width,s=t.height,l=t.ry;return e.createElement("rect",{x:o,y:a,ry:l,width:i,height:s,stroke:"none",fill:n,fillOpacity:r,className:"recharts-cartesian-grid-bg"})};function XQ(t,n){var r;if(e.isValidElement(t))r=e.cloneElement(t,n);else if(Vk(t))r=t(n);else{var o=n.x1,a=n.y1,i=n.x2,s=n.y2,l=n.key,c=YQ(n,zQ),u=FO(c,!1);u.offset;var d=YQ(u,$Q);r=e.createElement("line",WQ({},d,{x1:o,y1:a,x2:i,y2:s,fill:"none",key:l}))}return r}function ZQ(t){var n=t.x,r=t.width,o=t.horizontal,a=void 0===o||o,i=t.horizontalPoints;if(!a||!i||!i.length)return null;var s=i.map(function(e,o){var i=HQ(HQ({},t),{},{x1:n,y1:e,x2:n+r,y2:e,key:"line-".concat(o),index:o});return XQ(a,i)});return e.createElement("g",{className:"recharts-cartesian-grid-horizontal"},s)}function QQ(t){var n=t.y,r=t.height,o=t.vertical,a=void 0===o||o,i=t.verticalPoints;if(!a||!i||!i.length)return null;var s=i.map(function(e,o){var i=HQ(HQ({},t),{},{x1:e,y1:n,x2:e,y2:n+r,key:"line-".concat(o),index:o});return XQ(a,i)});return e.createElement("g",{className:"recharts-cartesian-grid-vertical"},s)}function JQ(t){var n=t.horizontalFill,r=t.fillOpacity,o=t.x,a=t.y,i=t.width,s=t.height,l=t.horizontalPoints,c=t.horizontal;if(!(void 0===c||c)||!n||!n.length)return null;var u=l.map(function(e){return Math.round(e+a-a)}).sort(function(e,t){return e-t});a!==u[0]&&u.unshift(0);var d=u.map(function(t,l){var c=!u[l+1]?a+s-t:u[l+1]-t;if(c<=0)return null;var d=l%n.length;return e.createElement("rect",{key:"react-".concat(l),y:t,x:o,height:c,width:i,stroke:"none",fill:n[d],fillOpacity:r,className:"recharts-cartesian-grid-bg"})});return e.createElement("g",{className:"recharts-cartesian-gridstripes-horizontal"},d)}function eJ(t){var n=t.vertical,r=void 0===n||n,o=t.verticalFill,a=t.fillOpacity,i=t.x,s=t.y,l=t.width,c=t.height,u=t.verticalPoints;if(!r||!o||!o.length)return null;var d=u.map(function(e){return Math.round(e+i-i)}).sort(function(e,t){return e-t});i!==d[0]&&d.unshift(0);var p=d.map(function(t,n){var r=!d[n+1]?i+l-t:d[n+1]-t;if(r<=0)return null;var u=n%o.length;return e.createElement("rect",{key:"react-".concat(n),x:t,y:s,width:r,height:c,stroke:"none",fill:o[u],fillOpacity:a,className:"recharts-cartesian-grid-bg"})});return e.createElement("g",{className:"recharts-cartesian-gridstripes-vertical"},p)}var tJ=function(e,t){var n=e.xAxis,r=e.width,o=e.height,a=e.offset;return WG(kQ(HQ(HQ(HQ({},UQ.defaultProps),n),{},{ticks:YG(n,!0),viewBox:{x:0,y:0,width:r,height:o}})),a.left,a.left+a.width,t)},nJ=function(e,t){var n=e.yAxis,r=e.width,o=e.height,a=e.offset;return WG(kQ(HQ(HQ(HQ({},UQ.defaultProps),n),{},{ticks:YG(n,!0),viewBox:{x:0,y:0,width:r,height:o}})),a.top,a.top+a.height,t)},rJ={horizontal:!0,vertical:!0,stroke:"#ccc",fill:"none",verticalFill:[],horizontalFill:[]};function oJ(t){var n,r,o,a,i,s,l,c,u=NZ(),d=_Z(),p=e.useContext(xZ),f=HQ(HQ({},t),{},{stroke:null!==(n=t.stroke)&&void 0!==n?n:rJ.stroke,fill:null!==(r=t.fill)&&void 0!==r?r:rJ.fill,horizontal:null!==(o=t.horizontal)&&void 0!==o?o:rJ.horizontal,horizontalFill:null!==(a=t.horizontalFill)&&void 0!==a?a:rJ.horizontalFill,vertical:null!==(i=t.vertical)&&void 0!==i?i:rJ.vertical,verticalFill:null!==(s=t.verticalFill)&&void 0!==s?s:rJ.verticalFill,x:sO(t.x)?t.x:p.left,y:sO(t.y)?t.y:p.top,width:sO(t.width)?t.width:p.width,height:sO(t.height)?t.height:p.height}),g=f.x,h=f.y,m=f.width,b=f.height,y=f.syncWithTicks,v=f.horizontalValues,w=f.verticalValues,S=(l=e.useContext(vZ),pO(l)),x=(c=e.useContext(wZ),mZ(c,function(e){return kX(e.domain,Number.isFinite)})||pO(c));if(!sO(m)||m<=0||!sO(b)||b<=0||!sO(g)||g!==+g||!sO(h)||h!==+h)return null;var E=f.verticalCoordinatesGenerator||tJ,k=f.horizontalCoordinatesGenerator||nJ,A=f.horizontalPoints,T=f.verticalPoints;if((!A||!A.length)&&Vk(k)){var O=v&&v.length,C=k({yAxis:x?HQ(HQ({},x),{},{ticks:O?v:x.ticks}):void 0,width:u,height:d,offset:p},!!O||y);ZO(Array.isArray(C),"horizontalCoordinatesGenerator should return Array but instead it returned [".concat(GQ(C),"]")),Array.isArray(C)&&(A=C)}if((!T||!T.length)&&Vk(E)){var I=w&&w.length,N=E({xAxis:S?HQ(HQ({},S),{},{ticks:I?w:S.ticks}):void 0,width:u,height:d,offset:p},!!I||y);ZO(Array.isArray(N),"verticalCoordinatesGenerator should return Array but instead it returned [".concat(GQ(N),"]")),Array.isArray(N)&&(T=N)}return e.createElement("g",{className:"recharts-cartesian-grid"},e.createElement(KQ,{fill:f.fill,fillOpacity:f.fillOpacity,x:f.x,y:f.y,width:f.width,height:f.height,ry:f.ry}),e.createElement(ZQ,WQ({},f,{offset:p,horizontalPoints:A,xAxis:S,yAxis:x})),e.createElement(QQ,WQ({},f,{offset:p,verticalPoints:T,xAxis:S,yAxis:x})),e.createElement(JQ,WQ({},f,{horizontalPoints:A})),e.createElement(eJ,WQ({},f,{verticalPoints:T})))}oJ.displayName="CartesianGrid";var aJ=["type","layout","connectNulls","ref"],iJ=["key"];function sJ(e){return sJ="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},sJ(e)}function lJ(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)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}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function cJ(){return cJ=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},cJ.apply(this,arguments)}function uJ(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function dJ(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?uJ(Object(n),!0).forEach(function(t){vJ(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):uJ(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function pJ(e){return function(e){if(Array.isArray(e))return fJ(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return fJ(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return fJ(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function fJ(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function gJ(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,wJ(r.key),r)}}function hJ(e,t,n){return t=bJ(t),function(e,t){if(t&&("object"===sJ(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,mJ()?Reflect.construct(t,n||[],bJ(e).constructor):t.apply(e,n))}function mJ(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(mJ=function(){return!!e})()}function bJ(e){return bJ=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},bJ(e)}function yJ(e,t){return yJ=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},yJ(e,t)}function vJ(e,t,n){return(t=wJ(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function wJ(e){var t=function(e,t){if("object"!=sJ(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=sJ(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"==sJ(t)?t:t+""}var SJ=function(t){function n(){var e;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n);for(var t=arguments.length,r=new Array(t),o=0;o<t;o++)r[o]=arguments[o];return vJ(e=hJ(this,n,[].concat(r)),"state",{isAnimationFinished:!0,totalLength:0}),vJ(e,"generateSimpleStrokeDasharray",function(e,t){return"".concat(t,"px ").concat(e-t,"px")}),vJ(e,"getStrokeDasharray",function(t,r,o){var a=o.reduce(function(e,t){return e+t});if(!a)return e.generateSimpleStrokeDasharray(r,t);for(var i=Math.floor(t/a),s=t%a,l=r-t,c=[],u=0,d=0;u<o.length;d+=o[u],++u)if(d+o[u]>s){c=[].concat(pJ(o.slice(0,u)),[s-d]);break}var p=c.length%2==0?[0,l]:[l];return[].concat(pJ(n.repeat(o,i)),pJ(c),p).map(function(e){return"".concat(e,"px")}).join(", ")}),vJ(e,"id",uO("recharts-line-")),vJ(e,"pathRef",function(t){e.mainCurve=t}),vJ(e,"handleAnimationEnd",function(){e.setState({isAnimationFinished:!0}),e.props.onAnimationEnd&&e.props.onAnimationEnd()}),vJ(e,"handleAnimationStart",function(){e.setState({isAnimationFinished:!1}),e.props.onAnimationStart&&e.props.onAnimationStart()}),e}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&yJ(e,t)}(n,t),r=n,o=[{key:"componentDidMount",value:function(){if(this.props.isAnimationActive){var e=this.getTotalLength();this.setState({totalLength:e})}}},{key:"componentDidUpdate",value:function(){if(this.props.isAnimationActive){var e=this.getTotalLength();e!==this.state.totalLength&&this.setState({totalLength:e})}}},{key:"getTotalLength",value:function(){var e=this.mainCurve;try{return e&&e.getTotalLength&&e.getTotalLength()||0}catch(e){return 0}}},{key:"renderErrorBar",value:function(t,n){if(this.props.isAnimationActive&&!this.state.isAnimationFinished)return null;var r=this.props,o=r.points,a=r.xAxis,i=r.yAxis,s=r.layout,l=PO(r.children,IG);if(!l)return null;var c=function(e,t){return{x:e.x,y:e.y,value:e.value,errorVal:zG(e.payload,t)}},u={clipPath:t?"url(#clipPath-".concat(n,")"):null};return e.createElement(KO,u,l.map(function(t){return e.cloneElement(t,{key:"bar-".concat(t.props.dataKey),data:o,xAxis:a,yAxis:i,layout:s,dataPointFormatter:c})}))}},{key:"renderDots",value:function(t,r,o){if(this.props.isAnimationActive&&!this.state.isAnimationFinished)return null;var a=this.props,i=a.dot,s=a.points,l=a.dataKey,c=FO(this.props,!1),u=FO(i,!0),d=s.map(function(e,t){var r=dJ(dJ(dJ({key:"dot-".concat(t),r:3},c),u),{},{index:t,cx:e.x,cy:e.y,value:e.value,dataKey:l,payload:e.payload,points:s});return n.renderDotItem(i,r)}),p={clipPath:t?"url(#clipPath-".concat(r?"":"dots-").concat(o,")"):null};return e.createElement(KO,cJ({className:"recharts-line-dots",key:"dots"},p),d)}},{key:"renderCurveStatically",value:function(t,n,r,o){var a=this.props,i=a.type,s=a.layout,l=a.connectNulls;a.ref;var c=lJ(a,aJ),u=dJ(dJ(dJ({},FO(c,!0)),{},{fill:"none",className:"recharts-line-curve",clipPath:n?"url(#clipPath-".concat(r,")"):null,points:t},o),{},{type:i,layout:s,connectNulls:l});return e.createElement(bH,cJ({},u,{pathRef:this.pathRef}))}},{key:"renderCurveWithAnimation",value:function(t,n){var r=this,o=this.props,a=o.points,i=o.strokeDasharray,s=o.isAnimationActive,l=o.animationBegin,c=o.animationDuration,u=o.animationEasing,d=o.animationId,p=o.animateNewValues,f=o.width,g=o.height,h=this.state,m=h.prevPoints,b=h.totalLength;return e.createElement(mW,{begin:l,duration:c,isActive:s,easing:u,from:{t:0},to:{t:1},key:"line-".concat(d),onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},function(e){var o=e.t;if(m){var s=m.length/a.length,l=a.map(function(e,t){var n=Math.floor(t*s);if(m[n]){var r=m[n],a=fO(r.x,e.x),i=fO(r.y,e.y);return dJ(dJ({},e),{},{x:a(o),y:i(o)})}if(p){var l=fO(2*f,e.x),c=fO(g/2,e.y);return dJ(dJ({},e),{},{x:l(o),y:c(o)})}return dJ(dJ({},e),{},{x:e.x,y:e.y})});return r.renderCurveStatically(l,t,n)}var c,u=fO(0,b)(o);if(i){var d="".concat(i).split(/[,\s]+/gim).map(function(e){return parseFloat(e)});c=r.getStrokeDasharray(u,b,d)}else c=r.generateSimpleStrokeDasharray(b,u);return r.renderCurveStatically(a,t,n,{strokeDasharray:c})})}},{key:"renderCurve",value:function(e,t){var n=this.props,r=n.points,o=n.isAnimationActive,a=this.state,i=a.prevPoints,s=a.totalLength;return o&&r&&r.length&&(!i&&s>0||!d$(i,r))?this.renderCurveWithAnimation(e,t):this.renderCurveStatically(r,e,t)}},{key:"render",value:function(){var t,n=this.props,r=n.hide,o=n.dot,a=n.points,i=n.className,s=n.xAxis,l=n.yAxis,c=n.top,u=n.left,d=n.width,p=n.height,f=n.isAnimationActive,g=n.id;if(r||!a||!a.length)return null;var h=this.state.isAnimationFinished,m=1===a.length,b=hk("recharts-line",i),y=s&&s.allowDataOverflow,v=l&&l.allowDataOverflow,w=y||v,S=GT(g)?this.id:g,x=null!==(t=FO(o,!1))&&void 0!==t?t:{r:3,strokeWidth:2},E=x.r,k=void 0===E?3:E,A=x.strokeWidth,T=void 0===A?2:A,O=(jO(o)?o:{}).clipDot,C=void 0===O||O,I=2*k+T;return e.createElement(KO,{className:b},y||v?e.createElement("defs",null,e.createElement("clipPath",{id:"clipPath-".concat(S)},e.createElement("rect",{x:y?u:u-d/2,y:v?c:c-p/2,width:y?d:2*d,height:v?p:2*p})),!C&&e.createElement("clipPath",{id:"clipPath-dots-".concat(S)},e.createElement("rect",{x:u-I/2,y:c-I/2,width:d+I,height:p+I}))):null,!m&&this.renderCurve(w,S),this.renderErrorBar(w,S),(m||o)&&this.renderDots(w,C,S),(!f||h)&&Xq.renderCallByParent(this.props,a))}}],a=[{key:"getDerivedStateFromProps",value:function(e,t){return e.animationId!==t.prevAnimationId?{prevAnimationId:e.animationId,curPoints:e.points,prevPoints:t.curPoints}:e.points!==t.curPoints?{curPoints:e.points}:null}},{key:"repeat",value:function(e,t){for(var n=e.length%2!=0?[].concat(pJ(e),[0]):e,r=[],o=0;o<t;++o)r=[].concat(pJ(r),pJ(n));return r}},{key:"renderDotItem",value:function(t,n){var r;if(e.isValidElement(t))r=e.cloneElement(t,n);else if(Vk(t))r=t(n);else{var o=n.key,a=lJ(n,iJ),i=hk("recharts-line-dot","boolean"!=typeof t?t.className:"");r=e.createElement(jW,cJ({key:o},a,{className:i}))}return r}}],o&&gJ(r.prototype,o),a&&gJ(r,a),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,o,a}(e.PureComponent);vJ(SJ,"displayName","Line"),vJ(SJ,"defaultProps",{xAxisId:0,yAxisId:0,connectNulls:!1,activeDot:!0,dot:!0,legendType:"line",stroke:"#3182bd",strokeWidth:1,fill:"#fff",points:[],isAnimationActive:!DD,animateNewValues:!0,animationBegin:0,animationDuration:1500,animationEasing:"ease",hide:!1,label:!1}),vJ(SJ,"getComposedData",function(e){var t=e.props,n=e.xAxis,r=e.yAxis,o=e.xAxisTicks,a=e.yAxisTicks,i=e.dataKey,s=e.bandSize,l=e.displayedData,c=e.offset,u=t.layout,d=l.map(function(e,t){var l=zG(e,i);return"horizontal"===u?{x:rq({axis:n,ticks:o,bandSize:s,entry:e,index:t}),y:GT(l)?null:r.scale(l),value:l,payload:e}:{x:GT(l)?null:n.scale(l),y:rq({axis:r,ticks:a,bandSize:s,entry:e,index:t}),value:l,payload:e}});return dJ({points:d,layout:u},c)});var xJ,EJ=["layout","type","stroke","connectNulls","isRange","ref"],kJ=["key"];function AJ(e){return AJ="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},AJ(e)}function TJ(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)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}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function OJ(){return OJ=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},OJ.apply(this,arguments)}function CJ(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function IJ(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?CJ(Object(n),!0).forEach(function(t){DJ(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):CJ(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function NJ(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,MJ(r.key),r)}}function _J(e,t,n){return t=PJ(t),function(e,t){if(t&&("object"===AJ(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,RJ()?Reflect.construct(t,n||[],PJ(e).constructor):t.apply(e,n))}function RJ(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(RJ=function(){return!!e})()}function PJ(e){return PJ=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},PJ(e)}function LJ(e,t){return LJ=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},LJ(e,t)}function DJ(e,t,n){return(t=MJ(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function MJ(e){var t=function(e,t){if("object"!=AJ(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=AJ(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"==AJ(t)?t:t+""}var jJ=function(t){function n(){var e;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n);for(var t=arguments.length,r=new Array(t),o=0;o<t;o++)r[o]=arguments[o];return DJ(e=_J(this,n,[].concat(r)),"state",{isAnimationFinished:!0}),DJ(e,"id",uO("recharts-area-")),DJ(e,"handleAnimationEnd",function(){var t=e.props.onAnimationEnd;e.setState({isAnimationFinished:!0}),Vk(t)&&t()}),DJ(e,"handleAnimationStart",function(){var t=e.props.onAnimationStart;e.setState({isAnimationFinished:!1}),Vk(t)&&t()}),e}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&LJ(e,t)}(n,t),r=n,o=[{key:"renderDots",value:function(t,r,o){var a=this.props.isAnimationActive,i=this.state.isAnimationFinished;if(a&&!i)return null;var s=this.props,l=s.dot,c=s.points,u=s.dataKey,d=FO(this.props,!1),p=FO(l,!0),f=c.map(function(e,t){var r=IJ(IJ(IJ({key:"dot-".concat(t),r:3},d),p),{},{index:t,cx:e.x,cy:e.y,dataKey:u,value:e.value,payload:e.payload,points:c});return n.renderDotItem(l,r)}),g={clipPath:t?"url(#clipPath-".concat(r?"":"dots-").concat(o,")"):null};return e.createElement(KO,OJ({className:"recharts-area-dots"},g),f)}},{key:"renderHorizontalRect",value:function(t){var n=this.props,r=n.baseLine,o=n.points,a=n.strokeWidth,i=o[0].x,s=o[o.length-1].x,l=t*Math.abs(i-s),c=Xz(o.map(function(e){return e.y||0}));return sO(r)&&"number"==typeof r?c=Math.max(r,c):r&&Array.isArray(r)&&r.length&&(c=Math.max(Xz(r.map(function(e){return e.y||0})),c)),sO(c)?e.createElement("rect",{x:i<s?i:i-l,y:0,width:l,height:Math.floor(c+(a?parseInt("".concat(a),10):1))}):null}},{key:"renderVerticalRect",value:function(t){var n=this.props,r=n.baseLine,o=n.points,a=n.strokeWidth,i=o[0].y,s=o[o.length-1].y,l=t*Math.abs(i-s),c=Xz(o.map(function(e){return e.x||0}));return sO(r)&&"number"==typeof r?c=Math.max(r,c):r&&Array.isArray(r)&&r.length&&(c=Math.max(Xz(r.map(function(e){return e.x||0})),c)),sO(c)?e.createElement("rect",{x:0,y:i<s?i:i-l,width:c+(a?parseInt("".concat(a),10):1),height:Math.floor(l)}):null}},{key:"renderClipRect",value:function(e){return"vertical"===this.props.layout?this.renderVerticalRect(e):this.renderHorizontalRect(e)}},{key:"renderAreaStatically",value:function(t,n,r,o){var a=this.props,i=a.layout,s=a.type,l=a.stroke,c=a.connectNulls,u=a.isRange;a.ref;var d=TJ(a,EJ);return e.createElement(KO,{clipPath:r?"url(#clipPath-".concat(o,")"):null},e.createElement(bH,OJ({},FO(d,!0),{points:t,connectNulls:c,type:s,baseLine:n,layout:i,stroke:"none",className:"recharts-area-area"})),"none"!==l&&e.createElement(bH,OJ({},FO(this.props,!1),{className:"recharts-area-curve",layout:i,type:s,connectNulls:c,fill:"none",points:t})),"none"!==l&&u&&e.createElement(bH,OJ({},FO(this.props,!1),{className:"recharts-area-curve",layout:i,type:s,connectNulls:c,fill:"none",points:n})))}},{key:"renderAreaWithAnimation",value:function(t,n){var r=this,o=this.props,a=o.points,i=o.baseLine,s=o.isAnimationActive,l=o.animationBegin,c=o.animationDuration,u=o.animationEasing,d=o.animationId,p=this.state,f=p.prevPoints,g=p.prevBaseLine;return e.createElement(mW,{begin:l,duration:c,isActive:s,easing:u,from:{t:0},to:{t:1},key:"area-".concat(d),onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},function(o){var s=o.t;if(f){var l,c=f.length/a.length,u=a.map(function(e,t){var n=Math.floor(t*c);if(f[n]){var r=f[n],o=fO(r.x,e.x),a=fO(r.y,e.y);return IJ(IJ({},e),{},{x:o(s),y:a(s)})}return e});return l=sO(i)&&"number"==typeof i?fO(g,i)(s):GT(i)||oO(i)?fO(g,0)(s):i.map(function(e,t){var n=Math.floor(t*c);if(g[n]){var r=g[n],o=fO(r.x,e.x),a=fO(r.y,e.y);return IJ(IJ({},e),{},{x:o(s),y:a(s)})}return e}),r.renderAreaStatically(u,l,t,n)}return e.createElement(KO,null,e.createElement("defs",null,e.createElement("clipPath",{id:"animationClipPath-".concat(n)},r.renderClipRect(s))),e.createElement(KO,{clipPath:"url(#animationClipPath-".concat(n,")")},r.renderAreaStatically(a,i,t,n)))})}},{key:"renderArea",value:function(e,t){var n=this.props,r=n.points,o=n.baseLine,a=n.isAnimationActive,i=this.state,s=i.prevPoints,l=i.prevBaseLine,c=i.totalLength;return a&&r&&r.length&&(!s&&c>0||!d$(s,r)||!d$(l,o))?this.renderAreaWithAnimation(e,t):this.renderAreaStatically(r,o,e,t)}},{key:"render",value:function(){var t,n=this.props,r=n.hide,o=n.dot,a=n.points,i=n.className,s=n.top,l=n.left,c=n.xAxis,u=n.yAxis,d=n.width,p=n.height,f=n.isAnimationActive,g=n.id;if(r||!a||!a.length)return null;var h=this.state.isAnimationFinished,m=1===a.length,b=hk("recharts-area",i),y=c&&c.allowDataOverflow,v=u&&u.allowDataOverflow,w=y||v,S=GT(g)?this.id:g,x=null!==(t=FO(o,!1))&&void 0!==t?t:{r:3,strokeWidth:2},E=x.r,k=void 0===E?3:E,A=x.strokeWidth,T=void 0===A?2:A,O=(jO(o)?o:{}).clipDot,C=void 0===O||O,I=2*k+T;return e.createElement(KO,{className:b},y||v?e.createElement("defs",null,e.createElement("clipPath",{id:"clipPath-".concat(S)},e.createElement("rect",{x:y?l:l-d/2,y:v?s:s-p/2,width:y?d:2*d,height:v?p:2*p})),!C&&e.createElement("clipPath",{id:"clipPath-dots-".concat(S)},e.createElement("rect",{x:l-I/2,y:s-I/2,width:d+I,height:p+I}))):null,m?null:this.renderArea(w,S),(o||m)&&this.renderDots(w,C,S),(!f||h)&&Xq.renderCallByParent(this.props,a))}}],a=[{key:"getDerivedStateFromProps",value:function(e,t){return e.animationId!==t.prevAnimationId?{prevAnimationId:e.animationId,curPoints:e.points,curBaseLine:e.baseLine,prevPoints:t.curPoints,prevBaseLine:t.curBaseLine}:e.points!==t.curPoints||e.baseLine!==t.curBaseLine?{curPoints:e.points,curBaseLine:e.baseLine}:null}}],o&&NJ(r.prototype,o),a&&NJ(r,a),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,o,a}(e.PureComponent);function FJ(e){return FJ="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},FJ(e)}function BJ(e,t,n){return t&&function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,HJ(r.key),r)}}(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function UJ(e,t,n){return t=$J(t),function(e,t){if(t&&("object"===FJ(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,zJ()?Reflect.construct(t,n||[],$J(e).constructor):t.apply(e,n))}function zJ(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(zJ=function(){return!!e})()}function $J(e){return $J=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},$J(e)}function GJ(e,t){return GJ=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},GJ(e,t)}function qJ(e,t,n){return(t=HJ(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function HJ(e){var t=function(e,t){if("object"!=FJ(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=FJ(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"==FJ(t)?t:t+""}function VJ(){return VJ=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},VJ.apply(this,arguments)}function WJ(e){var t=e.xAxisId,n=NZ(),r=_Z(),o=CZ(t);return null==o?null:i.createElement(UQ,VJ({},o,{className:hk("recharts-".concat(o.axisType," ").concat(o.axisType),o.className),viewBox:{x:0,y:0,width:n,height:r},ticksGenerator:function(e){return YG(e,!0)}}))}xJ=jJ,DJ(jJ,"displayName","Area"),DJ(jJ,"defaultProps",{stroke:"#3182bd",fill:"#3182bd",fillOpacity:.6,xAxisId:0,yAxisId:0,legendType:"line",connectNulls:!1,points:[],dot:!1,activeDot:!0,hide:!1,isAnimationActive:!DD,animationBegin:0,animationDuration:1500,animationEasing:"ease"}),DJ(jJ,"getBaseValue",function(e,t,n,r){var o=e.layout,a=e.baseValue,i=t.props.baseValue,s=null!=i?i:a;if(sO(s)&&"number"==typeof s)return s;var l="horizontal"===o?r:n,c=l.scale.domain();if("number"===l.type){var u=Math.max(c[0],c[1]),d=Math.min(c[0],c[1]);return"dataMin"===s?d:"dataMax"===s||u<0?u:Math.max(Math.min(c[0],c[1]),0)}return"dataMin"===s?c[0]:"dataMax"===s?c[1]:c[0]}),DJ(jJ,"getComposedData",function(e){var t,n=e.props,r=e.item,o=e.xAxis,a=e.yAxis,i=e.xAxisTicks,s=e.yAxisTicks,l=e.bandSize,c=e.dataKey,u=e.stackedData,d=e.dataStartIndex,p=e.displayedData,f=e.offset,g=n.layout,h=u&&u.length,m=xJ.getBaseValue(n,r,o,a),b="horizontal"===g,y=!1,v=p.map(function(e,t){var n;h?n=u[d+t]:(n=zG(e,c),Array.isArray(n)?y=!0:n=[m,n]);var r=null==n[1]||h&&null==zG(e,c);return b?{x:rq({axis:o,ticks:i,bandSize:l,entry:e,index:t}),y:r?null:a.scale(n[1]),value:n,payload:e}:{x:r?null:o.scale(n[1]),y:rq({axis:a,ticks:s,bandSize:l,entry:e,index:t}),value:n,payload:e}});return t=h||y?v.map(function(e){var t=Array.isArray(e.value)?e.value[0]:null;return b?{x:e.x,y:null!=t&&null!=e.y?a.scale(t):null}:{x:null!=t?o.scale(t):null,y:e.y}}):b?a.scale(m):o.scale(m),IJ({points:v,baseLine:t,layout:g,isRange:y},f)}),DJ(jJ,"renderDotItem",function(t,n){var r;if(e.isValidElement(t))r=e.cloneElement(t,n);else if(Vk(t))r=t(n);else{var o=hk("recharts-area-dot","boolean"!=typeof t?t.className:""),a=n.key,i=TJ(n,kJ);r=e.createElement(jW,OJ({},i,{key:a,className:o}))}return r});var YJ=function(e){function t(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),UJ(this,t,arguments)}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&GJ(e,t)}(t,e),BJ(t,[{key:"render",value:function(){return i.createElement(WJ,this.props)}}])}(i.Component);function KJ(e){return KJ="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},KJ(e)}function XJ(e,t,n){return t&&function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,n0(r.key),r)}}(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function ZJ(e,t,n){return t=JJ(t),function(e,t){if(t&&("object"===KJ(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,QJ()?Reflect.construct(t,n||[],JJ(e).constructor):t.apply(e,n))}function QJ(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(QJ=function(){return!!e})()}function JJ(e){return JJ=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},JJ(e)}function e0(e,t){return e0=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},e0(e,t)}function t0(e,t,n){return(t=n0(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function n0(e){var t=function(e,t){if("object"!=KJ(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=KJ(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"==KJ(t)?t:t+""}function r0(){return r0=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},r0.apply(this,arguments)}qJ(YJ,"displayName","XAxis"),qJ(YJ,"defaultProps",{allowDecimals:!0,hide:!1,orientation:"bottom",width:0,height:30,mirror:!1,xAxisId:0,tickCount:5,type:"category",padding:{left:0,right:0},allowDataOverflow:!1,scale:"auto",reversed:!1,allowDuplicatedCategory:!0});var o0=function(e){var t=e.yAxisId,n=NZ(),r=_Z(),o=IZ(t);return null==o?null:i.createElement(UQ,r0({},o,{className:hk("recharts-".concat(o.axisType," ").concat(o.axisType),o.className),viewBox:{x:0,y:0,width:n,height:r},ticksGenerator:function(e){return YG(e,!0)}}))},a0=function(e){function t(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),ZJ(this,t,arguments)}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&e0(e,t)}(t,e),XJ(t,[{key:"render",value:function(){return i.createElement(o0,this.props)}}])}(i.Component);function i0(e){return function(e){if(Array.isArray(e))return s0(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return s0(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return s0(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function s0(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}t0(a0,"displayName","YAxis"),t0(a0,"defaultProps",{allowDuplicatedCategory:!0,allowDecimals:!0,hide:!1,orientation:"left",width:60,height:0,mirror:!1,yAxisId:0,tickCount:5,type:"number",padding:{top:0,bottom:0},allowDataOverflow:!1,scale:"auto",reversed:!1});var l0=function(e,t,n,r,o){var a=PO(e,VZ),i=PO(e,oQ),s=[].concat(i0(a),i0(i)),l=PO(e,mQ),c="".concat(r,"Id"),u=r[0],d=t;if(s.length&&(d=s.reduce(function(e,t){if(t.props[c]===n&&cX(t.props,"extendDomain")&&sO(t.props[u])){var r=t.props[u];return[Math.min(e[0],r),Math.max(e[1],r)]}return e},d)),l.length){var p="".concat(u,"1"),f="".concat(u,"2");d=l.reduce(function(e,t){if(t.props[c]===n&&cX(t.props,"extendDomain")&&sO(t.props[p])&&sO(t.props[f])){var r=t.props[p],o=t.props[f];return[Math.min(e[0],r,o),Math.max(e[1],r,o)]}return e},d)}return o&&o.length&&(d=o.reduce(function(e,t){return sO(t)?[Math.min(e[0],t),Math.max(e[1],t)]:e},d)),d},c0={exports:{}};!function(e){var t=Object.prototype.hasOwnProperty,n="~";function r(){}function o(e,t,n){this.fn=e,this.context=t,this.once=n||!1}function a(e,t,r,a,i){if("function"!=typeof r)throw new TypeError("The listener must be a function");var s=new o(r,a||e,i),l=n?n+t:t;return e._events[l]?e._events[l].fn?e._events[l]=[e._events[l],s]:e._events[l].push(s):(e._events[l]=s,e._eventsCount++),e}function i(e,t){0===--e._eventsCount?e._events=new r:delete e._events[t]}function s(){this._events=new r,this._eventsCount=0}Object.create&&(r.prototype=Object.create(null),(new r).__proto__||(n=!1)),s.prototype.eventNames=function(){var e,r,o=[];if(0===this._eventsCount)return o;for(r in e=this._events)t.call(e,r)&&o.push(n?r.slice(1):r);return Object.getOwnPropertySymbols?o.concat(Object.getOwnPropertySymbols(e)):o},s.prototype.listeners=function(e){var t=n?n+e:e,r=this._events[t];if(!r)return[];if(r.fn)return[r.fn];for(var o=0,a=r.length,i=new Array(a);o<a;o++)i[o]=r[o].fn;return i},s.prototype.listenerCount=function(e){var t=n?n+e:e,r=this._events[t];return r?r.fn?1:r.length:0},s.prototype.emit=function(e,t,r,o,a,i){var s=n?n+e:e;if(!this._events[s])return!1;var l,c,u=this._events[s],d=arguments.length;if(u.fn){switch(u.once&&this.removeListener(e,u.fn,void 0,!0),d){case 1:return u.fn.call(u.context),!0;case 2:return u.fn.call(u.context,t),!0;case 3:return u.fn.call(u.context,t,r),!0;case 4:return u.fn.call(u.context,t,r,o),!0;case 5:return u.fn.call(u.context,t,r,o,a),!0;case 6:return u.fn.call(u.context,t,r,o,a,i),!0}for(c=1,l=new Array(d-1);c<d;c++)l[c-1]=arguments[c];u.fn.apply(u.context,l)}else{var p,f=u.length;for(c=0;c<f;c++)switch(u[c].once&&this.removeListener(e,u[c].fn,void 0,!0),d){case 1:u[c].fn.call(u[c].context);break;case 2:u[c].fn.call(u[c].context,t);break;case 3:u[c].fn.call(u[c].context,t,r);break;case 4:u[c].fn.call(u[c].context,t,r,o);break;default:if(!l)for(p=1,l=new Array(d-1);p<d;p++)l[p-1]=arguments[p];u[c].fn.apply(u[c].context,l)}}return!0},s.prototype.on=function(e,t,n){return a(this,e,t,n,!1)},s.prototype.once=function(e,t,n){return a(this,e,t,n,!0)},s.prototype.removeListener=function(e,t,r,o){var a=n?n+e:e;if(!this._events[a])return this;if(!t)return i(this,a),this;var s=this._events[a];if(s.fn)s.fn!==t||o&&!s.once||r&&s.context!==r||i(this,a);else{for(var l=0,c=[],u=s.length;l<u;l++)(s[l].fn!==t||o&&!s[l].once||r&&s[l].context!==r)&&c.push(s[l]);c.length?this._events[a]=1===c.length?c[0]:c:i(this,a)}return this},s.prototype.removeAllListeners=function(e){var t;return e?(t=n?n+e:e,this._events[t]&&i(this,t)):(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}(c0);var u0=new(0,c0.exports),d0="recharts.syncMouseEvents";function p0(e){return p0="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},p0(e)}function f0(e,t,n){return t&&function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,h0(r.key),r)}}(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function g0(e,t,n){return(t=h0(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function h0(e){var t=function(e,t){if("object"!=p0(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=p0(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"==p0(t)?t:t+""}var m0=function(){return f0(function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),g0(this,"activeIndex",0),g0(this,"coordinateList",[]),g0(this,"layout","horizontal")},[{key:"setDetails",value:function(e){var t,n=e.coordinateList,r=void 0===n?null:n,o=e.container,a=void 0===o?null:o,i=e.layout,s=void 0===i?null:i,l=e.offset,c=void 0===l?null:l,u=e.mouseHandlerCallback,d=void 0===u?null:u;this.coordinateList=null!==(t=null!=r?r:this.coordinateList)&&void 0!==t?t:[],this.container=null!=a?a:this.container,this.layout=null!=s?s:this.layout,this.offset=null!=c?c:this.offset,this.mouseHandlerCallback=null!=d?d:this.mouseHandlerCallback,this.activeIndex=Math.min(Math.max(this.activeIndex,0),this.coordinateList.length-1)}},{key:"focus",value:function(){this.spoofMouse()}},{key:"keyboardEvent",value:function(e){if(0!==this.coordinateList.length)switch(e.key){case"ArrowRight":if("horizontal"!==this.layout)return;this.activeIndex=Math.min(this.activeIndex+1,this.coordinateList.length-1),this.spoofMouse();break;case"ArrowLeft":if("horizontal"!==this.layout)return;this.activeIndex=Math.max(this.activeIndex-1,0),this.spoofMouse()}}},{key:"setIndex",value:function(e){this.activeIndex=e}},{key:"spoofMouse",value:function(){var e,t;if("horizontal"===this.layout&&0!==this.coordinateList.length){var n=this.container.getBoundingClientRect(),r=n.x,o=n.y,a=n.height,i=this.coordinateList[this.activeIndex].coordinate,s=(null===(e=window)||void 0===e?void 0:e.scrollX)||0,l=(null===(t=window)||void 0===t?void 0:t.scrollY)||0,c=r+i+s,u=o+this.offset.top+a/2+l;this.mouseHandlerCallback({pageX:c,pageY:u})}}}])}();function b0(e){var t=e.cx,n=e.cy,r=e.radius,o=e.startAngle,a=e.endAngle;return{points:[wq(t,n,r,o),wq(t,n,r,a)],cx:t,cy:n,radius:r,startAngle:o,endAngle:a}}function y0(e,t,n){var r,o,a,i;if("horizontal"===e)a=r=t.x,o=n.top,i=n.top+n.height;else if("vertical"===e)i=o=t.y,r=n.left,a=n.left+n.width;else if(null!=t.cx&&null!=t.cy){if("centric"!==e)return b0(t);var s=t.cx,l=t.cy,c=t.innerRadius,u=t.outerRadius,d=t.angle,p=wq(s,l,c,d),f=wq(s,l,u,d);r=p.x,o=p.y,a=f.x,i=f.y}return[{x:r,y:o},{x:a,y:i}]}function v0(e){return v0="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},v0(e)}function w0(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function S0(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?w0(Object(n),!0).forEach(function(t){x0(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):w0(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function x0(e,t,n){var r;return r=function(e,t){if("object"!=v0(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=v0(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(t,"string"),(t="symbol"==v0(r)?r:r+"")in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function E0(t){var n,r,o,a=t.element,i=t.tooltipEventType,s=t.isActive,l=t.activeCoordinate,c=t.activePayload,u=t.offset,d=t.activeTooltipIndex,p=t.tooltipAxisBandSize,f=t.layout,g=t.chartName,h=null!==(n=a.props.cursor)&&void 0!==n?n:null===(r=a.type.defaultProps)||void 0===r?void 0:r.cursor;if(!a||!h||!s||!l||"ScatterChart"!==g&&"axis"!==i)return null;var m=bH;if("ScatterChart"===g)o=l,m=HW;else if("BarChart"===g)o=function(e,t,n,r){var o=r/2;return{stroke:"none",fill:"#ccc",x:"horizontal"===e?t.x-o:n.left+.5,y:"horizontal"===e?n.top+.5:t.y-o,width:"horizontal"===e?r:n.width-1,height:"horizontal"===e?n.height-1:r}}(f,l,u,p),m=OW;else if("radial"===f){var b=b0(l),y=b.cx,v=b.cy,w=b.radius;o={cx:y,cy:v,startAngle:b.startAngle,endAngle:b.endAngle,innerRadius:w,outerRadius:w},m=aH}else o={points:y0(f,l,u)},m=bH;var S=S0(S0(S0(S0({stroke:"#ccc",pointerEvents:"none"},u),o),FO(h,!1)),{},{payload:c,payloadIndex:d,className:hk("recharts-tooltip-cursor",h.className)});return e.isValidElement(h)?e.cloneElement(h,S):e.createElement(m,S)}var k0=["item"],A0=["children","className","width","height","style","compact","title","desc"];function T0(e){return T0="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},T0(e)}function O0(){return O0=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},O0.apply(this,arguments)}function C0(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,a,i,s=[],l=!0,c=!1;try{if(a=(n=n.call(e)).next,0===t);else for(;!(l=(r=a.call(n)).done)&&(s.push(r.value),s.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(c)throw o}}return s}}(e,t)||M0(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function I0(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)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}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function N0(e,t,n){return t&&function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,z0(r.key),r)}}(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function _0(e,t,n){return t=P0(t),function(e,t){if(t&&("object"===T0(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,R0()?Reflect.construct(t,n||[],P0(e).constructor):t.apply(e,n))}function R0(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(R0=function(){return!!e})()}function P0(e){return P0=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},P0(e)}function L0(e,t){return L0=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},L0(e,t)}function D0(e){return function(e){if(Array.isArray(e))return j0(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||M0(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function M0(e,t){if(e){if("string"==typeof e)return j0(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?j0(e,t):void 0}}function j0(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function F0(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function B0(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?F0(Object(n),!0).forEach(function(t){U0(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):F0(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function U0(e,t,n){return(t=z0(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function z0(e){var t=function(e,t){if("object"!=T0(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=T0(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==T0(t)?t:t+""}var $0={xAxis:["bottom","top"],yAxis:["left","right"]},G0={width:"100%",height:"100%"},q0={x:0,y:0};function H0(e){return e}var V0=function(e,t){var n=t.graphicalItems,r=t.dataStartIndex,o=t.dataEndIndex,a=(null!=n?n:[]).reduce(function(e,t){var n=t.props.data;return n&&n.length?[].concat(D0(e),D0(n)):e},[]);return a.length>0?a:e&&e.length&&sO(r)&&sO(o)?e.slice(r,o+1):[]};function W0(e){return"number"===e?[0,"auto"]:void 0}var Y0=function(e,t,n,r){var o=e.graphicalItems,a=e.tooltipAxis,i=V0(t,e);return n<0||!o||!o.length||n>=i.length?null:o.reduce(function(o,s){var l,c,u=null!==(l=s.props.data)&&void 0!==l?l:t;(u&&e.dataStartIndex+e.dataEndIndex!==0&&e.dataEndIndex-e.dataStartIndex>=n&&(u=u.slice(e.dataStartIndex,e.dataEndIndex+1)),a.dataKey&&!a.allowDuplicatedCategory)?c=gO(void 0===u?i:u,a.dataKey,r):c=u&&u[n]||i[n];return c?[].concat(D0(o),[dq(s,c)]):o},[])},K0=function(e,t,n,r){var o=r||{x:e.chartX,y:e.chartY},a=function(e,t){return"horizontal"===t?e.x:"vertical"===t?e.y:"centric"===t?e.angle:e.radius}(o,n),i=e.orderedTooltipTicks,s=e.tooltipAxis,l=e.tooltipTicks,c=function(e){var t,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],r=arguments.length>2?arguments[2]:void 0,o=arguments.length>3?arguments[3]:void 0,a=-1,i=null!==(t=null==n?void 0:n.length)&&void 0!==t?t:0;if(i<=1)return 0;if(o&&"angleAxis"===o.axisType&&Math.abs(Math.abs(o.range[1]-o.range[0])-360)<=1e-6)for(var s=o.range,l=0;l<i;l++){var c=l>0?r[l-1].coordinate:r[i-1].coordinate,u=r[l].coordinate,d=l>=i-1?r[0].coordinate:r[l+1].coordinate,p=void 0;if(aO(u-c)!==aO(d-u)){var f=[];if(aO(d-u)===aO(s[1]-s[0])){p=d;var g=u+s[1]-s[0];f[0]=Math.min(g,(g+c)/2),f[1]=Math.max(g,(g+c)/2)}else{p=c;var h=d+s[1]-s[0];f[0]=Math.min(u,(h+u)/2),f[1]=Math.max(u,(h+u)/2)}var m=[Math.min(u,(p+u)/2),Math.max(u,(p+u)/2)];if(e>m[0]&&e<=m[1]||e>=f[0]&&e<=f[1]){a=r[l].index;break}}else{var b=Math.min(c,d),y=Math.max(c,d);if(e>(b+u)/2&&e<=(y+u)/2){a=r[l].index;break}}}else for(var v=0;v<i;v++)if(0===v&&e<=(n[v].coordinate+n[v+1].coordinate)/2||v>0&&v<i-1&&e>(n[v].coordinate+n[v-1].coordinate)/2&&e<=(n[v].coordinate+n[v+1].coordinate)/2||v===i-1&&e>(n[v].coordinate+n[v-1].coordinate)/2){a=n[v].index;break}return a}(a,i,l,s);if(c>=0&&l){var u=l[c]&&l[c].value,d=Y0(e,t,c,u),p=function(e,t,n,r){var o=t.find(function(e){return e&&e.index===n});if(o){if("horizontal"===e)return{x:o.coordinate,y:r.y};if("vertical"===e)return{x:r.x,y:o.coordinate};if("centric"===e){var a=o.coordinate,i=r.radius;return B0(B0(B0({},r),wq(r.cx,r.cy,i,a)),{},{angle:a,radius:i})}var s=o.coordinate,l=r.angle;return B0(B0(B0({},r),wq(r.cx,r.cy,s,l)),{},{angle:l,radius:s})}return q0}(n,i,c,o);return{activeTooltipIndex:c,activeLabel:u,activePayload:d,activeCoordinate:p}}return null},X0=function(e,t){var n=t.axes,r=t.graphicalItems,o=t.axisType,a=t.axisIdKey,i=t.stackGroups,s=t.dataStartIndex,l=t.dataEndIndex,c=e.layout,u=e.children,d=e.stackOffset,p=VG(c,o);return n.reduce(function(t,n){var f,g=void 0!==n.type.defaultProps?B0(B0({},n.type.defaultProps),n.props):n.props,h=g.type,m=g.dataKey,b=g.allowDataOverflow,y=g.allowDuplicatedCategory,v=g.scale,w=g.ticks,S=g.includeHidden,x=g[a];if(t[x])return t;var E,k,A,T=V0(e.data,{graphicalItems:r.filter(function(e){var t;return(a in e.props?e.props[a]:null===(t=e.type.defaultProps)||void 0===t?void 0:t[a])===x}),dataStartIndex:s,dataEndIndex:l}),O=T.length;(function(e,t,n){if("number"===n&&!0===t&&Array.isArray(e)){var r=null==e?void 0:e[0],o=null==e?void 0:e[1];if(r&&o&&sO(r)&&sO(o))return!0}return!1})(g.domain,b,h)&&(E=lq(g.domain,null,b),!p||"number"!==h&&"auto"===v||(A=$G(T,m,"category")));var C=W0(h);if(!E||0===E.length){var I,N=null!==(I=g.domain)&&void 0!==I?I:C;if(m){if(E=$G(T,m,h),"category"===h&&p){var _=function(e){if(!Array.isArray(e))return!1;for(var t=e.length,n={},r=0;r<t;r++){if(n[e[r]])return!0;n[e[r]]=!0}return!1}(E);y&&_?(k=E,E=MK(0,O)):y||(E=uq(N,E,n).reduce(function(e,t){return e.indexOf(t)>=0?e:[].concat(D0(e),[t])},[]))}else if("category"===h)E=y?E.filter(function(e){return""!==e&&!GT(e)}):uq(N,E,n).reduce(function(e,t){return e.indexOf(t)>=0||""===t||GT(t)?e:[].concat(D0(e),[t])},[]);else if("number"===h){var R=function(e,t,n,r,o){var a=t.map(function(t){return qG(e,t,n,o,r)}).filter(function(e){return!GT(e)});return a&&a.length?a.reduce(function(e,t){return[Math.min(e[0],t[0]),Math.max(e[1],t[1])]},[1/0,-1/0]):null}(T,r.filter(function(e){var t,n,r=a in e.props?e.props[a]:null===(t=e.type.defaultProps)||void 0===t?void 0:t[a],o="hide"in e.props?e.props.hide:null===(n=e.type.defaultProps)||void 0===n?void 0:n.hide;return r===x&&(S||!o)}),m,o,c);R&&(E=R)}!p||"number"!==h&&"auto"===v||(A=$G(T,m,"category"))}else E=p?MK(0,O):i&&i[x]&&i[x].hasStack&&"number"===h?"expand"===d?[0,1]:aq(i[x].stackGroups,s,l):HG(T,r.filter(function(e){var t=a in e.props?e.props[a]:e.type.defaultProps[a],n="hide"in e.props?e.props.hide:e.type.defaultProps.hide;return t===x&&(S||!n)}),h,c,!0);if("number"===h)E=l0(u,E,x,o,w),N&&(E=lq(N,E,b));else if("category"===h&&N){var P=N;E.every(function(e){return P.indexOf(e)>=0})&&(E=P)}}return B0(B0({},t),{},U0({},x,B0(B0({},g),{},{axisType:o,domain:E,categoricalDomain:A,duplicateDomain:k,originalDomain:null!==(f=g.domain)&&void 0!==f?f:C,isCategorical:p,layout:c})))},{})},Z0=function(e,t){var n=t.axisType,r=void 0===n?"xAxis":n,o=t.AxisComp,a=t.graphicalItems,i=t.stackGroups,s=t.dataStartIndex,l=t.dataEndIndex,c=e.children,u="".concat(r,"Id"),d=PO(c,o),p={};return d&&d.length?p=X0(e,{axes:d,graphicalItems:a,axisType:r,axisIdKey:u,stackGroups:i,dataStartIndex:s,dataEndIndex:l}):a&&a.length&&(p=function(e,t){var n=t.graphicalItems,r=t.Axis,o=t.axisType,a=t.axisIdKey,i=t.stackGroups,s=t.dataStartIndex,l=t.dataEndIndex,c=e.layout,u=e.children,d=V0(e.data,{graphicalItems:n,dataStartIndex:s,dataEndIndex:l}),p=d.length,f=VG(c,o),g=-1;return n.reduce(function(e,t){var h,m=(void 0!==t.type.defaultProps?B0(B0({},t.type.defaultProps),t.props):t.props)[a],b=W0("number");return e[m]?e:(g++,f?h=MK(0,p):i&&i[m]&&i[m].hasStack?(h=aq(i[m].stackGroups,s,l),h=l0(u,h,m,o)):(h=lq(b,HG(d,n.filter(function(e){var t,n,r=a in e.props?e.props[a]:null===(t=e.type.defaultProps)||void 0===t?void 0:t[a],o="hide"in e.props?e.props.hide:null===(n=e.type.defaultProps)||void 0===n?void 0:n.hide;return r===m&&!o}),"number",c),r.defaultProps.allowDataOverflow),h=l0(u,h,m,o)),B0(B0({},e),{},U0({},m,B0(B0({axisType:o},r.defaultProps),{},{hide:!0,orientation:$T($0,"".concat(o,".").concat(g%2),null),domain:h,originalDomain:b,isCategorical:f,layout:c}))))},{})}(e,{Axis:o,graphicalItems:a,axisType:r,axisIdKey:u,stackGroups:i,dataStartIndex:s,dataEndIndex:l})),p},Q0=function(e){var t=e.children,n=e.defaultShowTooltip,r=LO(t,eX),o=0,a=0;return e.data&&0!==e.data.length&&(a=e.data.length-1),r&&r.props&&(r.props.startIndex>=0&&(o=r.props.startIndex),r.props.endIndex>=0&&(a=r.props.endIndex)),{chartX:0,chartY:0,dataStartIndex:o,dataEndIndex:a,activeTooltipIndex:-1,isTooltipActive:Boolean(n)}},J0=function(e){return"horizontal"===e?{numericAxisName:"yAxis",cateAxisName:"xAxis"}:"vertical"===e?{numericAxisName:"xAxis",cateAxisName:"yAxis"}:"centric"===e?{numericAxisName:"radiusAxis",cateAxisName:"angleAxis"}:{numericAxisName:"angleAxis",cateAxisName:"radiusAxis"}},e1=function(e,t){var n=e.props,r=(e.graphicalItems,e.xAxisMap),o=void 0===r?{}:r,a=e.yAxisMap,i=void 0===a?{}:a,s=n.width,l=n.height,c=n.children,u=n.margin||{},d=LO(c,eX),p=LO(c,sL),f=Object.keys(i).reduce(function(e,t){var n=i[t],r=n.orientation;return n.mirror||n.hide?e:B0(B0({},e),{},U0({},r,e[r]+n.width))},{left:u.left||0,right:u.right||0}),g=Object.keys(o).reduce(function(e,t){var n=o[t],r=n.orientation;return n.mirror||n.hide?e:B0(B0({},e),{},U0({},r,$T(e,"".concat(r))+n.height))},{top:u.top||0,bottom:u.bottom||0}),h=B0(B0({},g),f),m=h.bottom;d&&(h.bottom+=d.props.height||eX.defaultProps.height),p&&t&&(h=function(e,t,n,r){var o=n.children,a=n.width,i=n.margin,s=a-(i.left||0)-(i.right||0),l=LG({children:o,legendWidth:s});if(l){var c=r||{},u=c.width,d=c.height,p=l.align,f=l.verticalAlign,g=l.layout;if(("vertical"===g||"horizontal"===g&&"middle"===f)&&"center"!==p&&sO(e[p]))return BG(BG({},e),{},UG({},p,e[p]+(u||0)));if(("horizontal"===g||"vertical"===g&&"center"===p)&&"middle"!==f&&sO(e[f]))return BG(BG({},e),{},UG({},f,e[f]+(d||0)))}return e}(h,0,n,t));var b=s-h.left-h.right,y=l-h.top-h.bottom;return B0(B0({brushBottom:m},h),{},{width:Math.max(b,0),height:Math.max(y,0)})},t1=function(e,t){return"xAxis"===t?e[t].width:"yAxis"===t?e[t].height:void 0},n1=function(t){var n=t.chartName,r=t.GraphicalChild,o=t.defaultTooltipEventType,a=void 0===o?"axis":o,i=t.validateTooltipEventTypes,s=void 0===i?["axis"]:i,l=t.axisComponents,c=t.legendContent,u=t.formatAxisMap,d=t.defaultProps,p=function(e,t){var n=t.graphicalItems,r=t.stackGroups,o=t.offset,a=t.updateId,i=t.dataStartIndex,s=t.dataEndIndex,c=e.barSize,u=e.layout,d=e.barGap,p=e.barCategoryGap,f=e.maxBarSize,g=J0(u),h=g.numericAxisName,m=g.cateAxisName,b=function(e){return!(!e||!e.length)&&e.some(function(e){var t=IO(e&&e.type);return t&&t.indexOf("Bar")>=0})}(n),y=[];return n.forEach(function(n,g){var v=V0(e.data,{graphicalItems:[n],dataStartIndex:i,dataEndIndex:s}),w=void 0!==n.type.defaultProps?B0(B0({},n.type.defaultProps),n.props):n.props,S=w.dataKey,x=w.maxBarSize,E=w["".concat(h,"Id")],k=w["".concat(m,"Id")],A=l.reduce(function(e,r){var o,a,i=t["".concat(r.axisType,"Map")],s=w["".concat(r.axisType,"Id")];i&&i[s]||"zAxis"===r.axisType||("production"!==process.env.NODE_ENV?hG(0,"Specifying a(n) ".concat(r.axisType,"Id requires a corresponding ").concat(r.axisType,"Id on the targeted graphical component ").concat(null!==(o=null==n||null===(a=n.type)||void 0===a?void 0:a.displayName)&&void 0!==o?o:"")):hG());var l=i[s];return B0(B0({},e),{},U0(U0({},r.axisType,l),"".concat(r.axisType,"Ticks"),YG(l)))},{}),T=A[m],O=A["".concat(m,"Ticks")],C=r&&r[E]&&r[E].hasStack&&function(e,t){var n,r=(null!==(n=e.type)&&void 0!==n&&n.defaultProps?BG(BG({},e.type.defaultProps),e.props):e.props).stackId;if(lO(r)){var o=t[r];if(o){var a=o.items.indexOf(e);return a>=0?o.stackedData[a]:null}}return null}(n,r[E].stackGroups),I=IO(n.type).indexOf("Bar")>=0,N=cq(T,O),_=[],R=b&&function(e){var t=e.barSize,n=e.totalSize,r=e.stackGroups,o=void 0===r?{}:r;if(!o)return{};for(var a={},i=Object.keys(o),s=0,l=i.length;s<l;s++)for(var c=o[i[s]].stackGroups,u=Object.keys(c),d=0,p=u.length;d<p;d++){var f=c[u[d]],g=f.items,h=f.cateAxisId,m=g.filter(function(e){return IO(e.type).indexOf("Bar")>=0});if(m&&m.length){var b=m[0].type.defaultProps,y=void 0!==b?BG(BG({},b),m[0].props):m[0].props,v=y.barSize,w=y[h];a[w]||(a[w]=[]);var S=GT(v)?t:v;a[w].push({item:m[0],stackList:m.slice(1),barSize:GT(S)?void 0:dO(S,n,0)})}}return a}({barSize:c,stackGroups:r,totalSize:t1(A,m)});if(I){var P,L,D=GT(x)?f:x,M=null!==(P=null!==(L=cq(T,O,!0))&&void 0!==L?L:D)&&void 0!==P?P:0;_=function(e){var t=e.barGap,n=e.barCategoryGap,r=e.bandSize,o=e.sizeList,a=void 0===o?[]:o,i=e.maxBarSize,s=a.length;if(s<1)return null;var l,c=dO(t,r,0,!0),u=[];if(a[0].barSize===+a[0].barSize){var d=!1,p=r/s,f=a.reduce(function(e,t){return e+t.barSize||0},0);(f+=(s-1)*c)>=r&&(f-=(s-1)*c,c=0),f>=r&&p>0&&(d=!0,f=s*(p*=.9));var g={offset:((r-f)/2|0)-c,size:0};l=a.reduce(function(e,t){var n={item:t.item,position:{offset:g.offset+g.size+c,size:d?p:t.barSize}},r=[].concat(MG(e),[n]);return g=r[r.length-1].position,t.stackList&&t.stackList.length&&t.stackList.forEach(function(e){r.push({item:e,position:g})}),r},u)}else{var h=dO(n,r,0,!0);r-2*h-(s-1)*c<=0&&(c=0);var m=(r-2*h-(s-1)*c)/s;m>1&&(m>>=0);var b=i===+i?Math.min(m,i):m;l=a.reduce(function(e,t,n){var r=[].concat(MG(e),[{item:t.item,position:{offset:h+(m+c)*n+(m-b)/2,size:b}}]);return t.stackList&&t.stackList.length&&t.stackList.forEach(function(e){r.push({item:e,position:r[r.length-1].position})}),r},u)}return l}({barGap:d,barCategoryGap:p,bandSize:M!==N?M:N,sizeList:R[k],maxBarSize:D}),M!==N&&(_=_.map(function(e){return B0(B0({},e),{},{position:B0(B0({},e.position),{},{offset:e.position.offset-M/2})})}))}var j,F,B=n&&n.type&&n.type.getComposedData;B&&y.push({props:B0(B0({},B(B0(B0({},A),{},{displayedData:v,props:e,dataKey:S,item:n,bandSize:N,barPosition:_,offset:o,stackedData:C,layout:u,dataStartIndex:i,dataEndIndex:s}))),{},U0(U0(U0({key:n.key||"item-".concat(g)},h,A[h]),m,A[m]),"animationId",a)),childIndex:(j=n,F=e.children,RO(F).indexOf(j)),item:n})}),y},f=function(e,t){var o=e.props,a=e.dataStartIndex,i=e.dataEndIndex,s=e.updateId;if(!DO({props:o}))return null;var c=o.children,d=o.layout,f=o.stackOffset,g=o.data,h=o.reverseStackOrder,m=J0(d),b=m.numericAxisName,y=m.cateAxisName,v=PO(c,r),w=function(e,t,n,r,o,a){if(!e)return null;var i=(a?t.reverse():t).reduce(function(e,t){var o,a=null!==(o=t.type)&&void 0!==o&&o.defaultProps?BG(BG({},t.type.defaultProps),t.props):t.props,i=a.stackId;if(a.hide)return e;var s=a[n],l=e[s]||{hasStack:!1,stackGroups:{}};if(lO(i)){var c=l.stackGroups[i]||{numericAxisId:n,cateAxisId:r,items:[]};c.items.push(t),l.hasStack=!0,l.stackGroups[i]=c}else l.stackGroups[uO("_stackId_")]={numericAxisId:n,cateAxisId:r,items:[t]};return BG(BG({},e),{},UG({},s,l))},{});return Object.keys(i).reduce(function(t,a){var s=i[a];return s.hasStack&&(s.stackGroups=Object.keys(s.stackGroups).reduce(function(t,a){var i=s.stackGroups[a];return BG(BG({},t),{},UG({},a,{numericAxisId:n,cateAxisId:r,items:i.items,stackedData:tq(e,i.items,o)}))},{})),BG(BG({},t),{},UG({},a,s))},{})}(g,v,"".concat(b,"Id"),"".concat(y,"Id"),f,h),S=l.reduce(function(e,t){var n="".concat(t.axisType,"Map");return B0(B0({},e),{},U0({},n,Z0(o,B0(B0({},t),{},{graphicalItems:v,stackGroups:t.axisType===b&&w,dataStartIndex:a,dataEndIndex:i}))))},{}),x=e1(B0(B0({},S),{},{props:o,graphicalItems:v}),null==t?void 0:t.legendBBox);Object.keys(S).forEach(function(e){S[e]=u(o,S[e],x,e.replace("Map",""),n)});var E,k,A=S["".concat(y,"Map")],T=(E=pO(A),{tooltipTicks:k=YG(E,!1,!0),orderedTooltipTicks:lD(k,function(e){return e.coordinate}),tooltipAxis:E,tooltipAxisBandSize:cq(E,k)}),O=p(o,B0(B0({},S),{},{dataStartIndex:a,dataEndIndex:i,updateId:s,graphicalItems:v,stackGroups:w,offset:x}));return B0(B0({formattedGraphicalItems:O,graphicalItems:v,offset:x,stackGroups:w},T),S)},g=function(t){function r(t){var o,a,i;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,r),U0(i=_0(this,r,[t]),"eventEmitterSymbol",Symbol("rechartsEventEmitter")),U0(i,"accessibilityManager",new m0),U0(i,"handleLegendBBoxUpdate",function(e){if(e){var t=i.state,n=t.dataStartIndex,r=t.dataEndIndex,o=t.updateId;i.setState(B0({legendBBox:e},f({props:i.props,dataStartIndex:n,dataEndIndex:r,updateId:o},B0(B0({},i.state),{},{legendBBox:e}))))}}),U0(i,"handleReceiveSyncEvent",function(e,t,n){if(i.props.syncId===e){if(n===i.eventEmitterSymbol&&"function"!=typeof i.props.syncMethod)return;i.applySyncEvent(t)}}),U0(i,"handleBrushChange",function(e){var t=e.startIndex,n=e.endIndex;if(t!==i.state.dataStartIndex||n!==i.state.dataEndIndex){var r=i.state.updateId;i.setState(function(){return B0({dataStartIndex:t,dataEndIndex:n},f({props:i.props,dataStartIndex:t,dataEndIndex:n,updateId:r},i.state))}),i.triggerSyncEvent({dataStartIndex:t,dataEndIndex:n})}}),U0(i,"handleMouseEnter",function(e){var t=i.getMouseInfo(e);if(t){var n=B0(B0({},t),{},{isTooltipActive:!0});i.setState(n),i.triggerSyncEvent(n);var r=i.props.onMouseEnter;Vk(r)&&r(n,e)}}),U0(i,"triggeredAfterMouseMove",function(e){var t=i.getMouseInfo(e),n=t?B0(B0({},t),{},{isTooltipActive:!0}):{isTooltipActive:!1};i.setState(n),i.triggerSyncEvent(n);var r=i.props.onMouseMove;Vk(r)&&r(n,e)}),U0(i,"handleItemMouseEnter",function(e){i.setState(function(){return{isTooltipActive:!0,activeItem:e,activePayload:e.tooltipPayload,activeCoordinate:e.tooltipPosition||{x:e.cx,y:e.cy}}})}),U0(i,"handleItemMouseLeave",function(){i.setState(function(){return{isTooltipActive:!1}})}),U0(i,"handleMouseMove",function(e){e.persist(),i.throttleTriggeredAfterMouseMove(e)}),U0(i,"handleMouseLeave",function(e){i.throttleTriggeredAfterMouseMove.cancel();var t={isTooltipActive:!1};i.setState(t),i.triggerSyncEvent(t);var n=i.props.onMouseLeave;Vk(n)&&n(t,e)}),U0(i,"handleOuterEvent",function(e){var t,n=function(e){var t=e&&e.type;return t&&CO[t]?CO[t]:null}(e),r=$T(i.props,"".concat(n));n&&Vk(r)&&r(null!==(t=/.*touch.*/i.test(n)?i.getMouseInfo(e.changedTouches[0]):i.getMouseInfo(e))&&void 0!==t?t:{},e)}),U0(i,"handleClick",function(e){var t=i.getMouseInfo(e);if(t){var n=B0(B0({},t),{},{isTooltipActive:!0});i.setState(n),i.triggerSyncEvent(n);var r=i.props.onClick;Vk(r)&&r(n,e)}}),U0(i,"handleMouseDown",function(e){var t=i.props.onMouseDown;Vk(t)&&t(i.getMouseInfo(e),e)}),U0(i,"handleMouseUp",function(e){var t=i.props.onMouseUp;Vk(t)&&t(i.getMouseInfo(e),e)}),U0(i,"handleTouchMove",function(e){null!=e.changedTouches&&e.changedTouches.length>0&&i.throttleTriggeredAfterMouseMove(e.changedTouches[0])}),U0(i,"handleTouchStart",function(e){null!=e.changedTouches&&e.changedTouches.length>0&&i.handleMouseDown(e.changedTouches[0])}),U0(i,"handleTouchEnd",function(e){null!=e.changedTouches&&e.changedTouches.length>0&&i.handleMouseUp(e.changedTouches[0])}),U0(i,"handleDoubleClick",function(e){var t=i.props.onDoubleClick;Vk(t)&&t(i.getMouseInfo(e),e)}),U0(i,"handleContextMenu",function(e){var t=i.props.onContextMenu;Vk(t)&&t(i.getMouseInfo(e),e)}),U0(i,"triggerSyncEvent",function(e){void 0!==i.props.syncId&&u0.emit(d0,i.props.syncId,e,i.eventEmitterSymbol)}),U0(i,"applySyncEvent",function(e){var t=i.props,n=t.layout,r=t.syncMethod,o=i.state.updateId,a=e.dataStartIndex,s=e.dataEndIndex;if(void 0!==e.dataStartIndex||void 0!==e.dataEndIndex)i.setState(B0({dataStartIndex:a,dataEndIndex:s},f({props:i.props,dataStartIndex:a,dataEndIndex:s,updateId:o},i.state)));else if(void 0!==e.activeTooltipIndex){var l=e.chartX,c=e.chartY,u=e.activeTooltipIndex,d=i.state,p=d.offset,g=d.tooltipTicks;if(!p)return;if("function"==typeof r)u=r(g,e);else if("value"===r){u=-1;for(var h=0;h<g.length;h++)if(g[h].value===e.activeLabel){u=h;break}}var m=B0(B0({},p),{},{x:p.left,y:p.top}),b=Math.min(l,m.x+m.width),y=Math.min(c,m.y+m.height),v=g[u]&&g[u].value,w=Y0(i.state,i.props.data,u),S=g[u]?{x:"horizontal"===n?g[u].coordinate:b,y:"horizontal"===n?y:g[u].coordinate}:q0;i.setState(B0(B0({},e),{},{activeLabel:v,activeCoordinate:S,activePayload:w,activeTooltipIndex:u}))}else i.setState(e)}),U0(i,"renderCursor",function(t){var r,o=i.state,a=o.isTooltipActive,s=o.activeCoordinate,l=o.activePayload,c=o.offset,u=o.activeTooltipIndex,d=o.tooltipAxisBandSize,p=i.getTooltipEventType(),f=null!==(r=t.props.active)&&void 0!==r?r:a,g=i.props.layout,h=t.key||"_recharts-cursor";return e.createElement(E0,{key:h,activeCoordinate:s,activePayload:l,activeTooltipIndex:u,chartName:n,element:t,isActive:f,layout:g,offset:c,tooltipAxisBandSize:d,tooltipEventType:p})}),U0(i,"renderPolarAxis",function(t,n,r){var o=$T(t,"type.axisType"),a=$T(i.state,"".concat(o,"Map")),s=t.type.defaultProps,l=void 0!==s?B0(B0({},s),t.props):t.props,c=a&&a[l["".concat(o,"Id")]];return e.cloneElement(t,B0(B0({},c),{},{className:hk(o,c.className),key:t.key||"".concat(n,"-").concat(r),ticks:YG(c,!0)}))}),U0(i,"renderPolarGrid",function(t){var n=t.props,r=n.radialLines,o=n.polarAngles,a=n.polarRadius,s=i.state,l=s.radiusAxisMap,c=s.angleAxisMap,u=pO(l),d=pO(c),p=d.cx,f=d.cy,g=d.innerRadius,h=d.outerRadius;return e.cloneElement(t,{polarAngles:Array.isArray(o)?o:YG(d,!0).map(function(e){return e.coordinate}),polarRadius:Array.isArray(a)?a:YG(u,!0).map(function(e){return e.coordinate}),cx:p,cy:f,innerRadius:g,outerRadius:h,key:t.key||"polar-grid",radialLines:r})}),U0(i,"renderLegend",function(){var t=i.state.formattedGraphicalItems,n=i.props,r=n.children,o=n.width,a=n.height,s=i.props.margin||{},l=o-(s.left||0)-(s.right||0),u=LG({children:r,formattedGraphicalItems:t,legendWidth:l,legendContent:c});if(!u)return null;var d=u.item,p=I0(u,k0);return e.cloneElement(d,B0(B0({},p),{},{chartWidth:o,chartHeight:a,margin:s,onBBoxUpdate:i.handleLegendBBoxUpdate}))}),U0(i,"renderTooltip",function(){var t,n=i.props,r=n.children,o=n.accessibilityLayer,a=LO(r,WD);if(!a)return null;var s=i.state,l=s.isTooltipActive,c=s.activeCoordinate,u=s.activePayload,d=s.activeLabel,p=s.offset,f=null!==(t=a.props.active)&&void 0!==t?t:l;return e.cloneElement(a,{viewBox:B0(B0({},p),{},{x:p.left,y:p.top}),active:f,label:d,payload:f?u:[],coordinate:c,accessibilityLayer:o})}),U0(i,"renderBrush",function(t){var n=i.props,r=n.margin,o=n.data,a=i.state,s=a.offset,l=a.dataStartIndex,c=a.dataEndIndex,u=a.updateId;return e.cloneElement(t,{key:t.key||"_recharts-brush",onChange:XG(i.handleBrushChange,t.props.onChange),data:o,x:sO(t.props.x)?t.props.x:s.left,y:sO(t.props.y)?t.props.y:s.top+s.height+s.brushBottom-(r.bottom||0),width:sO(t.props.width)?t.props.width:s.width,startIndex:l,endIndex:c,updateId:"brush-".concat(u)})}),U0(i,"renderReferenceElement",function(t,n,r){if(!t)return null;var o=i.clipPathId,a=i.state,s=a.xAxisMap,l=a.yAxisMap,c=a.offset,u=t.type.defaultProps||{},d=t.props,p=d.xAxisId,f=void 0===p?u.xAxisId:p,g=d.yAxisId,h=void 0===g?u.yAxisId:g;return e.cloneElement(t,{key:t.key||"".concat(n,"-").concat(r),xAxis:s[f],yAxis:l[h],viewBox:{x:c.left,y:c.top,width:c.width,height:c.height},clipPathId:o})}),U0(i,"renderActivePoints",function(e){var t=e.item,n=e.activePoint,o=e.basePoint,a=e.childIndex,i=e.isRange,s=[],l=t.props.key,c=void 0!==t.item.type.defaultProps?B0(B0({},t.item.type.defaultProps),t.item.props):t.item.props,u=c.activeDot,d=B0(B0({index:a,dataKey:c.dataKey,cx:n.x,cy:n.y,r:4,fill:GG(t.item),strokeWidth:2,stroke:"#fff",payload:n.payload,value:n.value},FO(u,!1)),xO(u));return s.push(r.renderActiveDot(u,d,"".concat(l,"-activePoint-").concat(a))),o?s.push(r.renderActiveDot(u,B0(B0({},d),{},{cx:o.x,cy:o.y}),"".concat(l,"-basePoint-").concat(a))):i&&s.push(null),s}),U0(i,"renderGraphicChild",function(t,n,r){var o=i.filterFormatItem(t,n,r);if(!o)return null;var a=i.getTooltipEventType(),s=i.state,l=s.isTooltipActive,c=s.tooltipAxis,u=s.activeTooltipIndex,d=s.activeLabel,p=LO(i.props.children,WD),f=o.props,g=f.points,h=f.isRange,m=f.baseLine,b=void 0!==o.item.type.defaultProps?B0(B0({},o.item.type.defaultProps),o.item.props):o.item.props,y=b.activeDot,v=b.hide,w=b.activeBar,S=b.activeShape,x=Boolean(!v&&l&&p&&(y||w||S)),E={};"axis"!==a&&p&&"click"===p.props.trigger?E={onClick:XG(i.handleItemMouseEnter,t.props.onClick)}:"axis"!==a&&(E={onMouseLeave:XG(i.handleItemMouseLeave,t.props.onMouseLeave),onMouseEnter:XG(i.handleItemMouseEnter,t.props.onMouseEnter)});var k=e.cloneElement(t,B0(B0({},o.props),E));if(x){if(!(u>=0)){var A,T=(null!==(A=i.getItemByXY(i.state.activeCoordinate))&&void 0!==A?A:{graphicalItem:k}).graphicalItem,O=T.item,C=void 0===O?t:O,I=T.childIndex,N=B0(B0(B0({},o.props),E),{},{activeIndex:I});return[e.cloneElement(C,N),null,null]}var _,R;if(c.dataKey&&!c.allowDuplicatedCategory){var P="function"==typeof c.dataKey?function(e){return"function"==typeof c.dataKey?c.dataKey(e.payload):null}:"payload.".concat(c.dataKey.toString());_=gO(g,P,d),R=h&&m&&gO(m,P,d)}else _=null==g?void 0:g[u],R=h&&m&&m[u];if(S||w){var L=void 0!==t.props.activeIndex?t.props.activeIndex:u;return[e.cloneElement(t,B0(B0(B0({},o.props),E),{},{activeIndex:L})),null,null]}if(!GT(_))return[k].concat(D0(i.renderActivePoints({item:o,activePoint:_,basePoint:R,childIndex:u,isRange:h})))}return h?[k,null,null]:[k,null]}),U0(i,"renderCustomized",function(t,n,r){return e.cloneElement(t,B0(B0({key:"recharts-customized-".concat(r)},i.props),i.state))}),U0(i,"renderMap",{CartesianGrid:{handler:H0,once:!0},ReferenceArea:{handler:i.renderReferenceElement},ReferenceLine:{handler:H0},ReferenceDot:{handler:i.renderReferenceElement},XAxis:{handler:H0},YAxis:{handler:H0},Brush:{handler:i.renderBrush,once:!0},Bar:{handler:i.renderGraphicChild},Line:{handler:i.renderGraphicChild},Area:{handler:i.renderGraphicChild},Radar:{handler:i.renderGraphicChild},RadialBar:{handler:i.renderGraphicChild},Scatter:{handler:i.renderGraphicChild},Pie:{handler:i.renderGraphicChild},Funnel:{handler:i.renderGraphicChild},Tooltip:{handler:i.renderCursor,once:!0},PolarGrid:{handler:i.renderPolarGrid,once:!0},PolarAngleAxis:{handler:i.renderPolarAxis},PolarRadiusAxis:{handler:i.renderPolarAxis},Customized:{handler:i.renderCustomized}}),i.clipPathId="".concat(null!==(o=t.id)&&void 0!==o?o:uO("recharts"),"-clip"),i.throttleTriggeredAfterMouseMove=mM(i.triggeredAfterMouseMove,null!==(a=t.throttleDelay)&&void 0!==a?a:1e3/60),i.state={},i}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&L0(e,t)}(r,t),N0(r,[{key:"componentDidMount",value:function(){var e,t;this.addListener(),this.accessibilityManager.setDetails({container:this.container,offset:{left:null!==(e=this.props.margin.left)&&void 0!==e?e:0,top:null!==(t=this.props.margin.top)&&void 0!==t?t:0},coordinateList:this.state.tooltipTicks,mouseHandlerCallback:this.triggeredAfterMouseMove,layout:this.props.layout}),this.displayDefaultTooltip()}},{key:"displayDefaultTooltip",value:function(){var e=this.props,t=e.children,n=e.data,r=e.height,o=e.layout,a=LO(t,WD);if(a){var i=a.props.defaultIndex;if(!("number"!=typeof i||i<0||i>this.state.tooltipTicks.length-1)){var s=this.state.tooltipTicks[i]&&this.state.tooltipTicks[i].value,l=Y0(this.state,n,i,s),c=this.state.tooltipTicks[i].coordinate,u=(this.state.offset.top+r)/2,d="horizontal"===o?{x:c,y:u}:{y:c,x:u},p=this.state.formattedGraphicalItems.find(function(e){return"Scatter"===e.item.type.name});p&&(d=B0(B0({},d),p.props.points[i].tooltipPosition),l=p.props.points[i].tooltipPayload);var f={activeTooltipIndex:i,isTooltipActive:!0,activeLabel:s,activePayload:l,activeCoordinate:d};this.setState(f),this.renderCursor(a),this.accessibilityManager.setIndex(i)}}}},{key:"getSnapshotBeforeUpdate",value:function(e,t){if(!this.props.accessibilityLayer)return null;var n,r;(this.state.tooltipTicks!==t.tooltipTicks&&this.accessibilityManager.setDetails({coordinateList:this.state.tooltipTicks}),this.props.layout!==e.layout&&this.accessibilityManager.setDetails({layout:this.props.layout}),this.props.margin!==e.margin)&&this.accessibilityManager.setDetails({offset:{left:null!==(n=this.props.margin.left)&&void 0!==n?n:0,top:null!==(r=this.props.margin.top)&&void 0!==r?r:0}});return null}},{key:"componentDidUpdate",value:function(e){BO([LO(e.children,WD)],[LO(this.props.children,WD)])||this.displayDefaultTooltip()}},{key:"componentWillUnmount",value:function(){this.removeListener(),this.throttleTriggeredAfterMouseMove.cancel()}},{key:"getTooltipEventType",value:function(){var e=LO(this.props.children,WD);if(e&&"boolean"==typeof e.props.shared){var t=e.props.shared?"axis":"item";return s.indexOf(t)>=0?t:a}return a}},{key:"getMouseInfo",value:function(e){if(!this.container)return null;var t=this.container,n=t.getBoundingClientRect(),r=function(e){return{top:e.top+window.scrollY-document.documentElement.clientTop,left:e.left+window.scrollX-document.documentElement.clientLeft}}(n),o={chartX:Math.round(e.pageX-r.left),chartY:Math.round(e.pageY-r.top)},a=n.width/t.offsetWidth||1,i=this.inRange(o.chartX,o.chartY,a);if(!i)return null;var s=this.state,l=s.xAxisMap,c=s.yAxisMap,u=this.getTooltipEventType(),d=K0(this.state,this.props.data,this.props.layout,i);if("axis"!==u&&l&&c){var p=pO(l).scale,f=pO(c).scale,g=p&&p.invert?p.invert(o.chartX):null,h=f&&f.invert?f.invert(o.chartY):null;return B0(B0({},o),{},{xValue:g,yValue:h},d)}return d?B0(B0({},o),d):null}},{key:"inRange",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1,r=this.props.layout,o=e/n,a=t/n;if("horizontal"===r||"vertical"===r){var i=this.state.offset;return o>=i.left&&o<=i.left+i.width&&a>=i.top&&a<=i.top+i.height?{x:o,y:a}:null}var s=this.state,l=s.angleAxisMap,c=s.radiusAxisMap;if(l&&c){var u=pO(l);return kq({x:o,y:a},u)}return null}},{key:"parseEventsOfWrapper",value:function(){var e=this.props.children,t=this.getTooltipEventType(),n=LO(e,WD),r={};return n&&"axis"===t&&(r="click"===n.props.trigger?{onClick:this.handleClick}:{onMouseEnter:this.handleMouseEnter,onDoubleClick:this.handleDoubleClick,onMouseMove:this.handleMouseMove,onMouseLeave:this.handleMouseLeave,onTouchMove:this.handleTouchMove,onTouchStart:this.handleTouchStart,onTouchEnd:this.handleTouchEnd,onContextMenu:this.handleContextMenu}),B0(B0({},xO(this.props,this.handleOuterEvent)),r)}},{key:"addListener",value:function(){u0.on(d0,this.handleReceiveSyncEvent)}},{key:"removeListener",value:function(){u0.removeListener(d0,this.handleReceiveSyncEvent)}},{key:"filterFormatItem",value:function(e,t,n){for(var r=this.state.formattedGraphicalItems,o=0,a=r.length;o<a;o++){var i=r[o];if(i.item===e||i.props.key===e.key||t===IO(i.item.type)&&n===i.childIndex)return i}return null}},{key:"renderClipPath",value:function(){var t=this.clipPathId,n=this.state.offset,r=n.left,o=n.top,a=n.height,i=n.width;return e.createElement("defs",null,e.createElement("clipPath",{id:t},e.createElement("rect",{x:r,y:o,height:a,width:i})))}},{key:"getXScales",value:function(){var e=this.state.xAxisMap;return e?Object.entries(e).reduce(function(e,t){var n=C0(t,2),r=n[0],o=n[1];return B0(B0({},e),{},U0({},r,o.scale))},{}):null}},{key:"getYScales",value:function(){var e=this.state.yAxisMap;return e?Object.entries(e).reduce(function(e,t){var n=C0(t,2),r=n[0],o=n[1];return B0(B0({},e),{},U0({},r,o.scale))},{}):null}},{key:"getXScaleByAxisId",value:function(e){var t;return null===(t=this.state.xAxisMap)||void 0===t||null===(t=t[e])||void 0===t?void 0:t.scale}},{key:"getYScaleByAxisId",value:function(e){var t;return null===(t=this.state.yAxisMap)||void 0===t||null===(t=t[e])||void 0===t?void 0:t.scale}},{key:"getItemByXY",value:function(e){var t=this.state,n=t.formattedGraphicalItems,r=t.activeItem;if(n&&n.length)for(var o=0,a=n.length;o<a;o++){var i=n[o],s=i.props,l=i.item,c=void 0!==l.type.defaultProps?B0(B0({},l.type.defaultProps),l.props):l.props,u=IO(l.type);if("Bar"===u){var d=(s.data||[]).find(function(t){return AW(e,t)});if(d)return{graphicalItem:i,payload:d}}else if("RadialBar"===u){var p=(s.data||[]).find(function(t){return kq(e,t)});if(p)return{graphicalItem:i,payload:p}}else if(lK(i,r)||cK(i,r)||uK(i,r)){var f=gK({graphicalItem:i,activeTooltipItem:r,itemData:c.data}),g=void 0===c.activeIndex?f:c.activeIndex;return{graphicalItem:B0(B0({},i),{},{childIndex:g}),payload:uK(i,r)?c.data[f]:i.props.data[f]}}}return null}},{key:"render",value:function(){var t=this;if(!DO(this))return null;var n,r,o=this.props,a=o.children,i=o.className,s=o.width,l=o.height,c=o.style,u=o.compact,d=o.title,p=o.desc,f=I0(o,A0),g=FO(f,!1);if(u)return e.createElement(TZ,{state:this.state,width:this.props.width,height:this.props.height,clipPathId:this.clipPathId},e.createElement(HO,O0({},g,{width:s,height:l,title:d,desc:p}),this.renderClipPath(),zO(a,this.renderMap)));this.props.accessibilityLayer&&(g.tabIndex=null!==(n=this.props.tabIndex)&&void 0!==n?n:0,g.role=null!==(r=this.props.role)&&void 0!==r?r:"application",g.onKeyDown=function(e){t.accessibilityManager.keyboardEvent(e)},g.onFocus=function(){t.accessibilityManager.focus()});var h=this.parseEventsOfWrapper();return e.createElement(TZ,{state:this.state,width:this.props.width,height:this.props.height,clipPathId:this.clipPathId},e.createElement("div",O0({className:hk("recharts-wrapper",i),style:B0({position:"relative",cursor:"default",width:s,height:l},c)},h,{ref:function(e){t.container=e}}),e.createElement(HO,O0({},g,{width:s,height:l,title:d,desc:p,style:G0}),this.renderClipPath(),zO(a,this.renderMap)),this.renderLegend(),this.renderTooltip()))}}])}(e.Component);U0(g,"displayName",n),U0(g,"defaultProps",B0({layout:"horizontal",stackOffset:"none",barCategoryGap:"10%",barGap:4,margin:{top:5,right:5,bottom:5,left:5},reverseStackOrder:!1,syncMethod:"index"},d)),U0(g,"getDerivedStateFromProps",function(e,t){var n=e.dataKey,r=e.data,o=e.children,a=e.width,i=e.height,s=e.layout,l=e.stackOffset,c=e.margin,u=t.dataStartIndex,d=t.dataEndIndex;if(void 0===t.updateId){var p=Q0(e);return B0(B0(B0({},p),{},{updateId:0},f(B0(B0({props:e},p),{},{updateId:0}),t)),{},{prevDataKey:n,prevData:r,prevWidth:a,prevHeight:i,prevLayout:s,prevStackOffset:l,prevMargin:c,prevChildren:o})}if(n!==t.prevDataKey||r!==t.prevData||a!==t.prevWidth||i!==t.prevHeight||s!==t.prevLayout||l!==t.prevStackOffset||!mO(c,t.prevMargin)){var g=Q0(e),h={chartX:t.chartX,chartY:t.chartY,isTooltipActive:t.isTooltipActive},m=B0(B0({},K0(t,r,s)),{},{updateId:t.updateId+1}),b=B0(B0(B0({},g),h),m);return B0(B0(B0({},b),f(B0({props:e},b),t)),{},{prevDataKey:n,prevData:r,prevWidth:a,prevHeight:i,prevLayout:s,prevStackOffset:l,prevMargin:c,prevChildren:o})}if(!BO(o,t.prevChildren)){var y,v,w,S,x=LO(o,eX),E=x&&null!==(y=null===(v=x.props)||void 0===v?void 0:v.startIndex)&&void 0!==y?y:u,k=x&&null!==(w=null===(S=x.props)||void 0===S?void 0:S.endIndex)&&void 0!==w?w:d,A=E!==u||k!==d,T=!GT(r)&&!A?t.updateId:t.updateId+1;return B0(B0({updateId:T},f(B0(B0({props:e},t),{},{updateId:T,dataStartIndex:E,dataEndIndex:k}),t)),{},{prevChildren:o,dataStartIndex:E,dataEndIndex:k})}return null}),U0(g,"renderActiveDot",function(t,n,r){var o;return o=e.isValidElement(t)?e.cloneElement(t,n):Vk(t)?t(n):e.createElement(jW,n),e.createElement(KO,{className:"recharts-active-dot",key:r},o)});var h=e.forwardRef(function(t,n){return e.createElement(g,O0({},t,{ref:n}))});return h.displayName=g.displayName,h},r1=n1({chartName:"LineChart",GraphicalChild:SJ,axisComponents:[{axisType:"xAxis",AxisComp:YJ},{axisType:"yAxis",AxisComp:a0}],formatAxisMap:nZ}),o1=n1({chartName:"BarChart",GraphicalChild:KX,defaultTooltipEventType:"axis",validateTooltipEventTypes:["axis","item"],axisComponents:[{axisType:"xAxis",AxisComp:YJ},{axisType:"yAxis",AxisComp:a0}],formatAxisMap:nZ}),a1=n1({chartName:"PieChart",GraphicalChild:TK,validateTooltipEventTypes:["item"],defaultTooltipEventType:"item",legendContent:"children",axisComponents:[{axisType:"angleAxis",AxisComp:CY},{axisType:"radiusAxis",AxisComp:gY}],formatAxisMap:function(e,t,n,r,o){var a=e.width,i=e.height,s=e.startAngle,l=e.endAngle,c=dO(e.cx,a,a/2),u=dO(e.cy,i,i/2),d=Sq(a,i,n),p=dO(e.innerRadius,d,0),f=dO(e.outerRadius,d,.8*d);return Object.keys(t).reduce(function(e,n){var a,i=t[n],d=i.domain,g=i.reversed;if(GT(i.range))"angleAxis"===r?a=[s,l]:"radiusAxis"===r&&(a=[p,f]),g&&(a=[a[1],a[0]]);else{var h=mq(a=i.range,2);s=h[0],l=h[1]}var m=ZG(i,o),b=m.realScaleType,y=m.scale;y.domain(d).range(a),JG(y);var v=nq(y,gq(gq({},i),{},{realScaleType:b})),w=gq(gq(gq({},i),v),{},{range:a,radius:f,realScaleType:b,scale:y,cx:c,cy:u,innerRadius:p,outerRadius:f,startAngle:s,endAngle:l});return gq(gq({},e),{},hq({},n,w))},{})},defaultProps:{layout:"centric",startAngle:0,endAngle:360,cx:"50%",cy:"50%",innerRadius:0,outerRadius:"80%"}}),i1=n1({chartName:"AreaChart",GraphicalChild:jJ,axisComponents:[{axisType:"xAxis",AxisComp:YJ},{axisType:"yAxis",AxisComp:a0}],formatAxisMap:nZ});function s1(e){return e>=1e6?"".concat((e/1e6).toFixed(1),"M"):e>=1e3?"".concat((e/1e3).toFixed(1),"k"):String(e)}const l1=/(^|[_\W])(price|salary|cost|amount|revenue|expense|total|value|budget|spend|income|sale|balance)/i;function c1(e){return"string"==typeof e&&l1.test(e)}function u1(e){return"$".concat(s1(e))}function d1(e){return"$".concat(Number(e).toLocaleString("en-US",{maximumFractionDigits:2}))}function p1(e){let{props:t,isDark:r=!1}=e;const o=Array.isArray(t.data)?t.data:[],a=c1(t.yKey),i=t.valueLabel||void 0,s=r?"#374151":"#e2e8f0",l=r?"#1f2937":"#ffffff",c=r?"#9ca3af":"#64748b",u=r?"#f3f4f6":"#0f172a",d=r?"#374151":"#e2e8f0",p=r?"#111827":"#ffffff";if(0===o.length)return n.jsxs("div",{style:{borderRadius:8,border:"1px solid ".concat(s),background:l,padding:12,margin:"8px 0"},children:[t.title&&n.jsx("div",{style:{fontSize:13,fontWeight:600,color:u,marginBottom:8},children:t.title}),n.jsx("div",{style:{color:c,fontSize:12},children:"No chartable data"})]});const f=o.some(e=>{var t;return String(null!==(t=e.label)&&void 0!==t?t:"").length>10}),g=f?-35:0,h=f?"end":"middle",m=f?48:20,b=f?250:220;return n.jsxs("div",{style:{borderRadius:8,border:"1px solid ".concat(s),background:l,padding:12,margin:"8px 0"},children:[t.title&&n.jsx("h3",{style:{fontSize:13,fontWeight:600,color:u,marginBottom:8,marginTop:0},children:t.title}),n.jsx("div",{style:{height:b,width:"100%"},children:n.jsx(EM,{width:"100%",height:"100%",children:n.jsxs(o1,{data:o,margin:{top:16,right:12,left:12,bottom:m},children:[n.jsx(oJ,{strokeDasharray:"3 3",stroke:d}),n.jsx(YJ,{dataKey:"label",tick:{fontSize:11,fill:c},angle:g,textAnchor:h,interval:0,tickFormatter:e=>String(null!=e?e:"").replace(/[_\-]+/g," ").replace(/\b\w/g,e=>e.toUpperCase()),label:t.xAxisLabel?{value:t.xAxisLabel,position:"insideBottom",offset:-12,fontSize:11,fill:c}:void 0}),n.jsx(a0,{width:72,tick:{fontSize:11,fill:c},label:t.yAxisLabel?{value:t.yAxisLabel,angle:-90,position:"insideLeft",fontSize:11,fill:c}:void 0,tickFormatter:e=>a?u1(e):t.unit?"".concat(s1(e)," ").concat(t.unit):s1(e)}),n.jsx(WD,{formatter:e=>a?d1(e):t.unit?"".concat(Number(e).toLocaleString()," ").concat(t.unit):Number(e).toLocaleString(),contentStyle:{background:p,border:"1px solid ".concat(s),borderRadius:6,fontSize:12,color:u}}),n.jsx(KX,{dataKey:"value",name:i,fill:"#3b82f6",radius:[2,2,0,0],label:{position:"top",fill:c,fontSize:10,formatter:e=>a?u1(e):s1(e)}})]})})})]})}function f1(e){let{props:t,isDark:r=!1}=e;const o=t.trend,a="up"===o?"#059669":"down"===o?"#e11d48":"#64748b",i="up"===o?"↑":"down"===o?"↓":"flat"===o?"→":null,s=r?"#374151":"#e2e8f0",l=r?"#1f2937":"#ffffff",c=r?"#f3f4f6":"#0f172a";return n.jsxs("div",{style:{borderRadius:8,border:"1px solid ".concat(s),background:l,padding:12,margin:"8px 0"},children:[n.jsx("p",{style:{fontSize:11,fontWeight:500,color:"#64748b",textTransform:"uppercase",letterSpacing:"0.05em",margin:0},children:t.label}),n.jsx("p",{style:{marginTop:4,fontSize:28,fontWeight:700,color:c,lineHeight:1.1,marginBottom:0},children:t.value}),t.change&&n.jsxs("p",{style:{marginTop:4,fontSize:12,color:a,marginBottom:0},children:[i&&n.jsx("span",{style:{marginRight:4},children:i}),t.change]})]})}const g1=["#3b82f6","#10b981","#f59e0b","#ef4444","#8b5cf6","#ec4899","#14b8a6","#f97316","#6366f1","#84cc16","#06b6d4","#a855f7"];function h1(e){let{props:t,isDark:r=!1,donut:o=!1}=e;const a=Array.isArray(t.data)?t.data:[],i=c1(t.yKey),s=r?"#374151":"#e2e8f0",l=r?"#1f2937":"#ffffff",c=r?"#f3f4f6":"#0f172a",u=r?"#111827":"#ffffff",d=r?"#9ca3af":"#64748b",p=a.map(e=>({name:e.label,value:e.value})),f=Math.PI/180;return n.jsxs("div",{style:{borderRadius:8,border:"1px solid ".concat(s),background:l,padding:12,margin:"8px 0"},children:[t.title&&n.jsx("h3",{style:{fontSize:13,fontWeight:600,color:c,marginBottom:8,marginTop:0},children:t.title}),n.jsx("div",{style:{height:260,width:"100%"},children:n.jsx(EM,{width:"100%",height:"100%",children:n.jsxs(a1,{children:[n.jsx(TK,{data:p,dataKey:"value",nameKey:"name",cx:"50%",cy:"50%",outerRadius:72,innerRadius:o?40:0,paddingAngle:2,labelLine:!1,label:e=>{const t=Number(e&&e.value),a=(s=t,l=Number(e&&e.percent),Number.isFinite(s)&&0!==s?Number.isFinite(l)&&l<.08?"outside":"inside":"none");var s,l;if("none"===a)return null;const c=Number(e.innerRadius)||0,u=Number(e.outerRadius)||0,d=Number(e.cx),p=Number(e.cy),g=-Number(e.midAngle)*f,h=Math.cos(g),m=Math.sin(g),b=i?d1(t):Number(t).toLocaleString();if("inside"===a){const e=c+(u-c)*(o?.78:.6);return n.jsx("text",{x:d+e*h,y:p+e*m,fill:"#ffffff",textAnchor:"middle",dominantBaseline:"central",style:{fontSize:11,fontWeight:600,pointerEvents:"none"},children:b})}const y="string"==typeof e.fill&&e.fill?e.fill:r?"#9ca3af":"#64748b",v=u+8,w=d+v*h,S=p+v*m,x=h>=0,E=w+(x?6:-6);return n.jsxs("g",{style:{pointerEvents:"none"},children:[n.jsx("polyline",{points:"".concat(d+u*h,",").concat(p+u*m," ").concat(w,",").concat(S," ").concat(E,",").concat(S),stroke:y,strokeWidth:1,fill:"none"}),n.jsx("text",{x:E+(x?2:-2),y:S,fill:y,textAnchor:x?"start":"end",dominantBaseline:"central",style:{fontSize:10,fontWeight:600},children:b})]})},isAnimationActive:!1,children:p.map((e,t)=>n.jsx(kM,{fill:g1[t%g1.length]},t))}),n.jsx(WD,{formatter:e=>i?d1(e):Number(e).toLocaleString(),contentStyle:{background:u,border:"1px solid ".concat(s),borderRadius:6,fontSize:12,color:c}}),n.jsx(sL,{iconSize:10,iconType:"circle",wrapperStyle:{fontSize:11,color:d}})]})})})]})}function m1(e){let{props:t,isDark:r=!1,area:o=!1}=e;const a=Array.isArray(t.data)?t.data:[],i=c1(t.yKey),s=t.valueLabel||void 0,l=r?"#374151":"#e2e8f0",c=r?"#1f2937":"#ffffff",u=r?"#9ca3af":"#64748b",d=r?"#f3f4f6":"#0f172a",p=r?"#374151":"#e2e8f0",f=r?"#111827":"#ffffff";if(0===a.length)return n.jsxs("div",{style:{borderRadius:8,border:"1px solid ".concat(l),background:c,padding:12,margin:"8px 0"},children:[t.title&&n.jsx("div",{style:{fontSize:13,fontWeight:600,color:d,marginBottom:8},children:t.title}),n.jsx("div",{style:{color:u,fontSize:12},children:"No chartable data"})]});const g=o?i1:r1;return n.jsxs("div",{style:{borderRadius:8,border:"1px solid ".concat(l),background:c,padding:12,margin:"8px 0"},children:[t.title&&n.jsx("h3",{style:{fontSize:13,fontWeight:600,color:d,marginBottom:8,marginTop:0},children:t.title}),n.jsx("div",{style:{height:220,width:"100%"},children:n.jsx(EM,{width:"100%",height:"100%",children:n.jsxs(g,{data:a,margin:{top:8,right:12,left:12,bottom:20},children:[n.jsx(oJ,{strokeDasharray:"3 3",stroke:p}),n.jsx(YJ,{dataKey:"label",tick:{fontSize:11,fill:u},angle:0,textAnchor:"middle",interval:0,label:t.xAxisLabel?{value:t.xAxisLabel,position:"insideBottom",offset:-12,fontSize:11,fill:u}:void 0}),n.jsx(a0,{width:72,tick:{fontSize:11,fill:u},tickFormatter:e=>i?u1(e):t.unit?"".concat(s1(e)," ").concat(t.unit):s1(e)}),n.jsx(WD,{formatter:e=>i?d1(e):t.unit?"".concat(Number(e).toLocaleString()," ").concat(t.unit):Number(e).toLocaleString(),contentStyle:{background:f,border:"1px solid ".concat(l),borderRadius:6,fontSize:12,color:d}}),o?n.jsx(jJ,{type:"monotone",dataKey:"value",name:s,stroke:"#3b82f6",fill:"#3b82f6",fillOpacity:.15,strokeWidth:2,dot:{r:3,fill:"#3b82f6"}}):n.jsx(SJ,{type:"monotone",dataKey:"value",name:s,stroke:"#3b82f6",strokeWidth:2,dot:{r:3,fill:"#3b82f6"},activeDot:{r:5}})]})})})]})}const b1=/\b(?:field|fields|column|columns|table|tables|sql|summed?|aggregat\w*|averaged?|counted)\b/i,y1=/[A-Za-z_]\w*\.[A-Za-z_]\w*/;function v1(e){if("string"!=typeof e)return"";let t,n=e.trim();do{t=n,n=n.replace(/\s*\(([^()]*)\)\s*$/,(e,t)=>b1.test(t)||y1.test(t)?"":e).trim()}while(n!==t);return n}function w1(e){return"string"==typeof e&&/^https?:\/\//i.test(e)?e:void 0}function S1(e){let{spec:t,isDark:r=!1,onButtonClick:o}=e;if(!t||"object"!=typeof t)return null;t=c(c({},t),{},{title:v1(t.title)});const a=String(t.type||"").trim().toLowerCase().replace(/_/g,"-"),i=new Set(["bar","line","area","pie","donut","scatter","bubble","radar","radial-bar","radial","radialbar","treemap","funnel","sankey","composed","waterfall","gauge","histogram","kpi"]);if("revenue-insights"===a)return n.jsx(u2,{spec:t,isDark:r});if("impact-analysis"===a)return n.jsx(p2,{spec:t,isDark:r});if("deviation-analysis"===a)return n.jsx(f2,{spec:t,isDark:r});if("main-drivers"===a)return n.jsx(g2,{spec:t,isDark:r});if("key-observations"===a)return n.jsx(m2,{spec:t,isDark:r});if("recommendations"===a)return n.jsx(b2,{spec:t,isDark:r});if("kpi"===a){var s,l,u,d,p;const e=null!==(s=null!==(l=null!==(u=t.value)&&void 0!==u?u:t.amount)&&void 0!==l?l:t.metric)&&void 0!==s?s:t.kpi,o=null!=t.delta?Number(t.delta):null,a=null!==(d=t.change)&&void 0!==d?d:null!=o&&Number.isFinite(o)?o>=0?"+".concat(o):String(o):void 0,i=null!==(p=t.trend)&&void 0!==p?p:null!=o&&Number.isFinite(o)?o>0?"up":o<0?"down":"flat":void 0;return n.jsx(f1,{props:{label:t.label||t.title||"",value:null!=e?String(e):"-",change:a,trend:i},isDark:r})}return"table"===a?n.jsx(k1,{spec:t,isDark:r}):i.has(a)||Array.isArray(t.data)&&t.data.length>0?n.jsx(E1,{spec:t,type:a,isDark:r}):"alert"===a?n.jsx(A1,{spec:t,isDark:r}):"card"===a?n.jsx(C1,{spec:t,isDark:r,onButtonClick:o}):"button-group"===a?n.jsx(I1,{spec:t,isDark:r,onButtonClick:o}):"form"===a?n.jsx(N1,{spec:t,isDark:r}):"confirmation"===a?n.jsx(_1,{spec:t,isDark:r,onButtonClick:o}):"menu"===a?n.jsx(j1,{spec:t,isDark:r,onButtonClick:o}):"profile"===a?n.jsx(F1,{spec:t,isDark:r,onButtonClick:o}):"timeline"===a?n.jsx(B1,{spec:t,isDark:r}):"rating"===a?n.jsx(U1,{spec:t,isDark:r}):"comparison"===a?n.jsx(z1,{spec:t,isDark:r,onButtonClick:o}):"gallery"===a?n.jsx($1,{spec:t,isDark:r}):Array.isArray(t.data)&&t.data.length>0?n.jsx(E1,{spec:t,type:"bar",isDark:r}):null}const x1=e=>({border:e?"1px solid #374151":"1px solid #e5e7eb",background:e?"#1f2937":"#ffffff",borderRadius:8,padding:12,margin:"8px 0",fontSize:13,color:e?"#f3f4f6":"#111827"});function E1(e){let{spec:t,type:r,isDark:o}=e;const{x:a,y:i}=function(e,t,n){if(!Array.isArray(e)||0===e.length)return{x:"name",y:"value"};const r=e[0]||{};if(t&&Object.prototype.hasOwnProperty.call(r,t)&&n&&Object.prototype.hasOwnProperty.call(r,n))return{x:t,y:n};let o=t||null,a=n||null;for(const e of Object.keys(r)){const t=r[e];null!=o||"string"!=typeof t&&null!=t||(o=e),null==a&&"number"==typeof t&&Number.isFinite(t)&&(a=e)}return{x:o||"name",y:a||"value"}}(t.data,t.x,t.y),s=function(e,t,n){return(e||[]).map(e=>({label:Y1(null==e?void 0:e[t],t),value:Number(null==e?void 0:e[n])})).filter(e=>Number.isFinite(e.value))}(t.data,a,i),l=String(r||"").trim().toLowerCase(),c={title:t.title,data:s,unit:t.unit,xAxisLabel:t.xAxisLabel,yAxisLabel:t.yAxisLabel,yKey:i,valueLabel:V1(i)};return"pie"===l?n.jsx(h1,{props:c,isDark:o,donut:!1}):"donut"===l?n.jsx(h1,{props:c,isDark:o,donut:!0}):"line"===l?n.jsx(m1,{props:c,isDark:o,area:!1}):"area"===l?n.jsx(m1,{props:c,isDark:o,area:!0}):n.jsx(p1,{props:c,isDark:o})}function k1(e){let{spec:t,isDark:r}=e;const o=Array.isArray(t.columns)&&t.columns.length>0?t.columns:Array.isArray(t.data)&&t.data[0]?Object.keys(t.data[0]):[],a=Array.isArray(t.data)?t.data:Array.isArray(t.rows)?t.rows:[];if(0===o.length||0===a.length)return n.jsx("div",{style:x1(r),children:n.jsx("div",{style:{color:r?"#9ca3af":"#6b7280",fontSize:12},children:"Empty table"})});const i=r?"1px solid #374151":"1px solid #e5e7eb";return n.jsxs("div",{style:x1(r),children:[t.title&&n.jsx("div",{style:{fontWeight:600,marginBottom:8},children:t.title}),n.jsx("div",{style:{overflowX:"auto"},children:n.jsxs("table",{style:{borderCollapse:"collapse",width:"100%",fontSize:12},children:[n.jsx("thead",{children:n.jsx("tr",{children:o.map(e=>n.jsx("th",{style:{border:i,padding:"6px 8px",background:"transparent",textAlign:"left",fontWeight:600},children:V1(e)},e))})}),n.jsx("tbody",{children:a.map((e,t)=>n.jsx("tr",{children:o.map(t=>n.jsx("td",{style:{border:i,padding:"6px 8px"},children:e&&"object"==typeof e?e2(e[t],t):""},t))},t))})]})})]})}function A1(e){let{spec:t,isDark:r}=e;const o=String(t.level||"info").toLowerCase(),a={info:{bg:r?"hsl(204 33% 14%)":"hsl(204 100% 97%)",border:r?"hsl(199 89% 58%)":"hsl(199 89% 48%)",text:r?"#bae6fd":"#0c4a6e"},warn:{bg:r?"hsl(36 33% 14%)":"hsl(34 100% 95%)",border:r?"hsl(38 92% 60%)":"hsl(35 100% 50%)",text:r?"#fde68a":"#663c00"},error:{bg:r?"hsl(356 33% 16%)":"hsl(356 100% 97%)",border:r?"hsl(350 89% 65%)":"hsl(350 89% 60%)",text:r?"#fecdd3":"#9f1239"},success:{bg:r?"hsl(152 36% 14%)":"hsl(152 81% 96%)",border:r?"hsl(158 64% 52%)":"hsl(160 84% 39%)",text:r?"#a7f3d0":"#065f46"}};a.warning=a.warn;const i=a[o]||a.info;return n.jsxs("div",{style:c(c({},x1(r)),{},{background:i.bg,borderLeft:"4px solid ".concat(i.border),color:i.text}),children:[t.title&&n.jsx("div",{style:{fontWeight:600,marginBottom:4},children:t.title}),t.body&&n.jsx("div",{style:{fontSize:12,lineHeight:1.6,whiteSpace:"pre-wrap",wordBreak:"break-word"},children:String(t.body)})]})}const T1=e=>({success:{bg:e?"hsl(152 36% 14%)":"hsl(152 81% 96%)",fg:e?"hsl(158 64% 52%)":"hsl(160 84% 39%)"},warn:{bg:e?"hsl(36 33% 14%)":"hsl(34 100% 95%)",fg:e?"hsl(38 92% 60%)":"hsl(35 100% 50%)"},error:{bg:e?"hsl(356 33% 16%)":"hsl(356 100% 97%)",fg:e?"hsl(350 89% 65%)":"hsl(350 89% 60%)"},info:{bg:e?"hsl(204 33% 14%)":"hsl(204 100% 97%)",fg:e?"hsl(199 89% 58%)":"hsl(199 89% 48%)"}}),O1={calendar:ve,ticket:$e,check:ke};function C1(t){let{spec:r,isDark:o,onButtonClick:a}=t;const i=Array.isArray(r.fields)?r.fields:[],s=Array.isArray(r.actions)?r.actions:[],l=r.status,u=r.icon?O1[r.icon]:null,[d,p]=e.useState(!1),f=String(r.body||"").trim(),g=String(r.details||"").trim(),h=f.length>0&&g.length>f.length+2,m=w1(r.image),b=l&&l.label?T1(o)[l.variant||"success"]:null;return n.jsxs("div",{style:c(c({},x1(o)),{},{minWidth:0,overflow:"hidden"}),children:[m&&n.jsx("img",{src:m,alt:r.title||"",referrerPolicy:"no-referrer",onError:e=>{e.currentTarget.style.display="none"},style:{display:"block",margin:"-12px -12px 12px",width:"calc(100% + 24px)",height:140,objectFit:"contain",background:o?"rgba(31,41,55,0.4)":"#f9fafb"}}),(r.title||b)&&n.jsxs("div",{style:{display:"flex",alignItems:"center",justifyContent:"space-between",gap:8,marginBottom:8},children:[n.jsxs("div",{style:{display:"flex",alignItems:"center",gap:6,minWidth:0},children:[u&&n.jsx(u,{size:14,style:{flexShrink:0,color:o?"#60a5fa":R1}}),r.title&&n.jsx("div",{style:{fontWeight:600,minWidth:0,overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},children:r.title})]}),b&&n.jsx("span",{style:{flexShrink:0,borderRadius:999,padding:"1px 8px",fontSize:10,fontWeight:500,background:b.bg,color:b.fg},children:l.label})]}),(f||g)&&n.jsxs("div",{children:[n.jsx("div",{style:{fontSize:12,lineHeight:1.6,whiteSpace:"pre-wrap",wordBreak:"break-word"},children:d?g||f:f||g}),h&&n.jsx("button",{type:"button",onClick:()=>p(e=>!e),style:{marginTop:4,padding:0,border:"none",background:"none",fontSize:11,fontWeight:500,color:o?"#60a5fa":R1,cursor:"pointer"},children:d?"Show less":"Show more"})]}),i.length>0&&n.jsx("div",{style:{display:"grid",gridTemplateColumns:"auto 1fr",columnGap:12,rowGap:6,marginTop:f||g?12:0},children:i.map((t,r)=>n.jsxs(e.Fragment,{children:[n.jsx("div",{style:{fontSize:11,fontWeight:500,color:o?"#9ca3af":"#6b7280",whiteSpace:"nowrap"},children:t.label}),n.jsx("div",{style:{fontSize:12,minWidth:0,wordBreak:"break-word"},children:t.value})]},r))}),s.length>0&&n.jsx("div",{style:{display:"flex",flexWrap:"wrap",gap:8,marginTop:12},children:s.map((e,t)=>{const r="secondary"!==e.variant,i={display:"inline-flex",alignItems:"center",padding:"6px 12px",borderRadius:6,fontSize:11,fontWeight:500,textDecoration:"none",border:"1px solid "+(r?R1:o?"#4b5563":"#d1d5db"),background:r?R1:o?"#1f2937":"#ffffff",color:r?"#ffffff":o?"#e5e7eb":"#374151"},s=w1(e.url);if(s)return n.jsx("a",{href:s,target:"_blank",rel:"noopener noreferrer",style:i,children:e.label},t);const l=e.value||e.label;return n.jsx("button",{type:"button",onClick:a?()=>{var t;return a(String(null!=l?l:""),String(null!==(t=e.label)&&void 0!==t?t:""))}:void 0,disabled:!a,title:a?void 0:"Action (no handler wired)",style:c(c({},i),{},{cursor:a?"pointer":"default",opacity:a?1:.5}),children:e.label},t)})})]})}function I1(e){let{spec:t,isDark:r,onButtonClick:o}=e;const a=Array.isArray(t.buttons)?t.buttons:[];return 0===a.length?null:n.jsxs("div",{style:{margin:"8px 0"},children:[t.title&&n.jsx("div",{style:{fontSize:11,color:r?"#9ca3af":"#6b7280",textTransform:"uppercase",letterSpacing:"0.05em",marginBottom:6},children:t.title}),n.jsx("div",{style:{display:"flex",flexWrap:"wrap",gap:6},children:a.map((e,t)=>{var a,i;return n.jsx("button",{type:"button",onClick:o?()=>{var t,n,r,a;return o(String(null!==(t=null!==(n=e.value)&&void 0!==n?n:e.label)&&void 0!==t?t:""),String(null!==(r=null!==(a=e.label)&&void 0!==a?a:e.value)&&void 0!==r?r:""))}:void 0,disabled:!o,style:{border:"1px solid "+(r?"#374151":"#d1d5db"),background:r?"#1f2937":"#ffffff",color:r?"#f3f4f6":"#111827",padding:"6px 12px",borderRadius:6,fontSize:12,cursor:o?"pointer":"default",opacity:o?1:.6},children:String(null!==(a=null!==(i=e.label)&&void 0!==i?i:e.value)&&void 0!==a?a:"")},t)})})]})}function N1(e){let{spec:t,isDark:r}=e;const o=(Array.isArray(t.fields)?t.fields:[]).filter(e=>e&&"hidden"!==e.type);return n.jsxs("div",{style:x1(r),children:[t.title&&n.jsx("div",{style:{fontWeight:600,marginBottom:8},children:t.title}),o.map((e,t)=>{var o,a;return n.jsxs("div",{style:{marginBottom:4,fontSize:12},children:[n.jsxs("span",{style:{color:r?"#9ca3af":"#6b7280"},children:[e.label||e.name,": "]}),n.jsx("span",{children:String(null!==(o=null!==(a=e.value)&&void 0!==a?a:e.placeholder)&&void 0!==o?o:"")})]},t)})]})}function _1(e){let{spec:t,isDark:r,onButtonClick:o}=e;const a=t.yes||{label:"Yes",value:"yes"},i=t.no||{label:"No",value:"no"};return n.jsxs("div",{style:x1(r),children:[t.title&&n.jsx("div",{style:{fontWeight:600,marginBottom:6},children:t.title}),t.body&&n.jsx("div",{style:{fontSize:12,lineHeight:1.6,marginBottom:8,whiteSpace:"pre-wrap",wordBreak:"break-word"},children:String(t.body)}),n.jsx(I1,{spec:{buttons:[a,i]},isDark:r,onButtonClick:o})]})}const R1="#2563eb";function P1(e){return{display:"inline-flex",alignItems:"center",borderRadius:999,padding:"2px 8px",fontSize:10,fontWeight:600,background:e?"rgba(37,99,235,0.20)":"#eff6ff",color:e?"#93c5fd":"#1d4ed8"}}function L1(e,t){return{display:"inline-flex",alignItems:"center",justifyContent:"center",padding:"6px 12px",borderRadius:6,fontSize:12,fontWeight:600,border:"none",background:R1,color:"#ffffff",cursor:t?"default":"pointer",opacity:t?.5:1}}function D1(e,t){return{display:"inline-flex",alignItems:"center",justifyContent:"center",padding:"6px 12px",borderRadius:6,fontSize:12,fontWeight:600,border:"1px solid "+(e?"#374151":"#d1d5db"),background:e?"#1f2937":"#ffffff",color:e?"#f3f4f6":"#111827",textDecoration:"none",cursor:t?"default":"pointer",opacity:t?.5:1}}function M1(e){let{score:t,maxScore:r=5,size:o=14,isDark:a}=e;const i=[];for(let e=0;e<r;e+=1){const r=t>=e+1,s=!r&&t>e&&t<e+1;i.push(n.jsxs("svg",{width:o,height:o,viewBox:"0 0 24 24",fill:r?"#fbbf24":s?"url(#a2ui-half-star-".concat(e,")"):"none",stroke:r||s?"#fbbf24":a?"#4b5563":"#d1d5db",strokeWidth:"1.5",children:[s&&n.jsx("defs",{children:n.jsxs("linearGradient",{id:"a2ui-half-star-".concat(e),children:[n.jsx("stop",{offset:"50%",stopColor:"#fbbf24"}),n.jsx("stop",{offset:"50%",stopColor:"transparent"})]})}),n.jsx("polygon",{points:"12 2 15.09 8.26 22 9.27 17 14.14 18.18 21.02 12 17.77 5.82 21.02 7 14.14 2 9.27 8.91 8.26 12 2"})]},e))}return n.jsx("div",{style:{display:"flex",alignItems:"center",gap:1},children:i})}function j1(e){let{spec:t,isDark:r,onButtonClick:o}=e;const a=Array.isArray(t.items)?t.items:[];if(0===a.length)return null;const i=r?"1px solid #374151":"1px solid #e5e7eb",s=r?"#9ca3af":"#6b7280";return n.jsxs("div",{style:{margin:"8px 0"},children:[(t.title||t.subtitle)&&n.jsxs("div",{style:{marginBottom:8},children:[t.title&&n.jsx("div",{style:{fontSize:13,fontWeight:700},children:t.title}),t.subtitle&&n.jsx("div",{style:{fontSize:11,color:s},children:t.subtitle})]}),n.jsx("div",{style:{display:"grid",gridTemplateColumns:"repeat(auto-fit, minmax(160px, 1fr))",gap:10},children:a.map((e,t)=>n.jsxs("div",{style:{border:i,borderRadius:10,overflow:"hidden",background:r?"#1f2937":"#ffffff",display:"flex",flexDirection:"column"},children:[w1(e.image)&&n.jsx("img",{src:w1(e.image),alt:e.name||"",referrerPolicy:"no-referrer",onError:e=>{e.currentTarget.style.display="none"},style:{height:96,width:"100%",objectFit:"cover",background:r?"#111827":"#f9fafb"}}),n.jsxs("div",{style:{padding:10,display:"flex",flexDirection:"column",gap:6,flex:1},children:[n.jsxs("div",{style:{display:"flex",justifyContent:"space-between",gap:6,alignItems:"flex-start"},children:[n.jsx("div",{style:{fontSize:12,fontWeight:700,minWidth:0},children:e.name}),e.price&&n.jsx("div",{style:{fontSize:12,fontWeight:700,color:R1,flexShrink:0},children:e.price})]}),e.description&&n.jsx("div",{style:{fontSize:11,color:s,lineHeight:1.4},children:e.description}),Array.isArray(e.tags)&&e.tags.length>0&&n.jsx("div",{style:{display:"flex",flexWrap:"wrap",gap:4},children:e.tags.map((e,t)=>n.jsx("span",{style:P1(r),children:e},t))}),n.jsx("div",{style:{flex:1}}),e.actionLabel&&n.jsx("button",{type:"button",onClick:o?()=>{var t;return o(String(null!==(t=e.value)&&void 0!==t?t:e.actionLabel),String(e.actionLabel))}:void 0,disabled:!o,style:c(c({},L1(0,!o)),{},{alignSelf:"flex-start",marginTop:4}),children:e.actionLabel})]})]},t))})]})}function F1(e){let{spec:t,isDark:r,onButtonClick:o}=e;const a=Array.isArray(t.tags)?t.tags:[],i=Array.isArray(t.actions)?t.actions:[],s=r?"#9ca3af":"#6b7280";return n.jsxs("div",{style:x1(r),children:[n.jsxs("div",{style:{display:"flex",gap:10,alignItems:"flex-start"},children:[n.jsx("div",{style:{flexShrink:0,height:44,width:44,borderRadius:"50%",overflow:"hidden",background:r?"rgba(37,99,235,0.20)":"#eff6ff",color:r?"#93c5fd":R1,display:"flex",alignItems:"center",justifyContent:"center",fontWeight:700,fontSize:16},children:w1(t.avatar)?n.jsx("img",{src:w1(t.avatar),alt:t.name||"",referrerPolicy:"no-referrer",onError:e=>{e.currentTarget.style.display="none"},style:{height:"100%",width:"100%",objectFit:"cover"}}):String(t.name||"").charAt(0).toUpperCase()}),n.jsxs("div",{style:{minWidth:0,flex:1},children:[n.jsx("div",{style:{fontSize:13,fontWeight:700},children:t.name}),t.role&&n.jsx("div",{style:{fontSize:11,color:s},children:t.role}),"number"==typeof t.rating&&n.jsxs("div",{style:{marginTop:4,display:"flex",alignItems:"center",gap:6},children:[n.jsx(M1,{score:t.rating,size:11,isDark:r}),n.jsxs("span",{style:{fontSize:10,color:s},children:[t.rating.toFixed(1),"number"==typeof t.reviewCount?" (".concat(t.reviewCount,")"):""]})]})]})]}),a.length>0&&n.jsx("div",{style:{display:"flex",flexWrap:"wrap",gap:4,marginTop:8},children:a.map((e,t)=>n.jsx("span",{style:P1(r),children:e},t))}),t.bio&&n.jsx("div",{style:{marginTop:8,fontSize:12,lineHeight:1.5},children:t.bio}),i.length>0&&n.jsx("div",{style:{display:"flex",flexWrap:"wrap",gap:6,marginTop:10},children:i.map((e,t)=>{const a="secondary"!==e.variant,i=w1(e.url);if(i)return n.jsx("a",{href:i,target:"_blank",rel:"noopener noreferrer",style:D1(r,!1),children:e.label},t);const s=e.value||e.label;return n.jsx("button",{type:"button",onClick:o?()=>o(String(s),String(e.label)):void 0,disabled:!o,style:a?L1(0,!o):D1(r,!o),children:e.label},t)})})]})}function B1(e){let{spec:t,isDark:r}=e;const o=Array.isArray(t.steps)?t.steps:[];if(0===o.length)return null;const a=r?"#374151":"#e5e7eb",i=r?"#6b7280":"#9ca3af",s=e=>"done"===e?{background:"#10b981",border:"2px solid #10b981"}:"active"===e?{background:R1,border:"2px solid ".concat(R1),boxShadow:r?"0 0 0 4px rgba(37,99,235,0.25)":"0 0 0 4px #dbeafe"}:{background:r?"#1f2937":"#ffffff",border:"2px solid "+(r?"#4b5563":"#d1d5db")};return n.jsxs("div",{style:x1(r),children:[t.title&&n.jsx("div",{style:{fontWeight:700,fontSize:13,marginBottom:10},children:t.title}),n.jsx("div",{children:o.map((e,t)=>{const l=e.status||(0===t?"done":"pending"),u=t===o.length-1;return n.jsxs("div",{style:{display:"flex",gap:10},children:[n.jsxs("div",{style:{display:"flex",flexDirection:"column",alignItems:"center"},children:[n.jsx("div",{style:c({height:12,width:12,borderRadius:"50%",flexShrink:0},s(l))}),!u&&n.jsx("div",{style:{width:1,flex:1,background:a,minHeight:16,margin:"2px 0"}})]}),n.jsxs("div",{style:{minWidth:0,flex:1,paddingBottom:u?0:12},children:[n.jsxs("div",{style:{display:"flex",justifyContent:"space-between",gap:6},children:[n.jsx("span",{style:{fontSize:12,fontWeight:600,color:"pending"===l?i:r?"#f3f4f6":"#111827"},children:e.label}),e.timestamp&&n.jsx("span",{style:{fontSize:10,color:i,flexShrink:0},children:e.timestamp})]}),e.description&&n.jsx("div",{style:{fontSize:11,color:r?"#9ca3af":"#6b7280",marginTop:2},children:e.description})]})]},t)})})]})}function U1(e){let{spec:t,isDark:r}=e;const o=t.maxScore||5,a=r?"#9ca3af":"#6b7280";return n.jsxs("div",{style:x1(r),children:[t.title&&n.jsx("div",{style:{fontSize:11,textTransform:"uppercase",letterSpacing:"0.05em",color:a,marginBottom:4},children:t.title}),n.jsxs("div",{style:{display:"flex",alignItems:"center",gap:8},children:[n.jsx("span",{style:{fontSize:22,fontWeight:700},children:Number(t.score).toFixed(1)}),n.jsx(M1,{score:t.score,maxScore:o,size:15,isDark:r}),"number"==typeof t.reviewCount&&n.jsxs("span",{style:{fontSize:11,color:a},children:["(",t.reviewCount," review",1===t.reviewCount?"":"s",")"]})]}),t.review&&n.jsxs("div",{style:{marginTop:8,borderLeft:"2px solid "+(r?"#1e40af":"#bfdbfe"),paddingLeft:10,fontSize:12,fontStyle:"italic",color:r?"#d1d5db":"#374151",lineHeight:1.5},children:['"',t.review,'"',t.author&&n.jsxs("div",{style:{marginTop:4,fontStyle:"normal",fontSize:10,color:a},children:["- ",t.author]})]})]})}function z1(e){let{spec:t,isDark:r,onButtonClick:o}=e;const a=Array.isArray(t.plans)?t.plans:[];if(0===a.length)return null;const i=r?"#9ca3af":"#6b7280";return n.jsxs("div",{style:{margin:"8px 0"},children:[t.title&&n.jsx("div",{style:{fontWeight:700,fontSize:13,marginBottom:8},children:t.title}),n.jsx("div",{style:{display:"grid",gridTemplateColumns:"repeat(auto-fit, minmax(150px, 1fr))",gap:10},children:a.map((e,t)=>n.jsxs("div",{style:{border:e.highlight?"1px solid ".concat(R1):"1px solid "+(r?"#374151":"#e5e7eb"),background:e.highlight?r?"rgba(37,99,235,0.10)":"#eff6ff":r?"#1f2937":"#ffffff",borderRadius:10,padding:12,display:"flex",flexDirection:"column"},children:[e.highlight&&n.jsx("span",{style:{alignSelf:"flex-start",marginBottom:6,background:R1,color:"#ffffff",fontSize:9,fontWeight:700,padding:"2px 7px",borderRadius:999},children:"Recommended"}),n.jsx("div",{style:{fontSize:13,fontWeight:700},children:e.name}),e.price&&n.jsxs("div",{style:{marginTop:2,display:"flex",alignItems:"baseline",gap:3},children:[n.jsx("span",{style:{fontSize:18,fontWeight:700},children:e.price}),e.period&&n.jsxs("span",{style:{fontSize:11,color:i},children:["/",e.period]})]}),Array.isArray(e.features)&&e.features.length>0&&n.jsx("ul",{style:{listStyle:"none",padding:0,margin:"8px 0 0",display:"flex",flexDirection:"column",gap:6,flex:1},children:e.features.map((e,t)=>n.jsxs("li",{style:{display:"flex",gap:6,alignItems:"flex-start",fontSize:11,color:r?"#d1d5db":"#374151"},children:[n.jsx("svg",{width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"#10b981",strokeWidth:"3",strokeLinecap:"round",strokeLinejoin:"round",style:{marginTop:2,flexShrink:0},children:n.jsx("polyline",{points:"20 6 9 17 4 12"})}),n.jsx("span",{children:e})]},t))}),e.actionLabel&&n.jsx("button",{type:"button",onClick:o?()=>{var t;return o(String(null!==(t=e.value)&&void 0!==t?t:e.actionLabel),String(e.actionLabel))}:void 0,disabled:!o,style:c(c({},e.highlight?L1(0,!o):D1(r,!o)),{},{marginTop:10}),children:e.actionLabel})]},t))})]})}function $1(e){let{spec:t,isDark:r}=e;const o=Array.isArray(t.images)?t.images:[];if(0===o.length)return null;const a=r?"#9ca3af":"#6b7280";return n.jsxs("div",{style:{margin:"8px 0"},children:[t.title&&n.jsx("div",{style:{fontWeight:700,fontSize:13,marginBottom:8},children:t.title}),n.jsx("div",{className:"slim-scrollbar-x",style:{display:"flex",gap:8,overflowX:"auto",paddingBottom:4},children:o.map((e,t)=>n.jsxs("figure",{style:{flexShrink:0,width:140,margin:0,borderRadius:8,overflow:"hidden",border:"1px solid "+(r?"#374151":"#e5e7eb"),background:r?"#111827":"#f9fafb"},children:[n.jsx("img",{src:w1(e.url),alt:e.caption||"Image ".concat(t+1),referrerPolicy:"no-referrer",onError:e=>{e.currentTarget.style.display="none"},style:{height:96,width:"100%",objectFit:"cover"}}),e.caption&&n.jsx("figcaption",{style:{padding:"5px 8px",fontSize:10,color:a,whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis"},children:e.caption})]},t))})]})}const G1=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],q1=/(^|[_\W])(price|salary|cost|amount|revenue|expense|total|value|budget|spend|income|sale|balance)/i,H1=/(^|[_\W])month/i;function V1(e){if(null==e)return"";const t=String(e);return t?t.replace(/[_\-]+/g," ").replace(/([a-z])([A-Z])/g,"$1 $2").replace(/\s+/g," ").trim().split(" ").map(e=>e.charAt(0).toUpperCase()+e.slice(1).toLowerCase()).join(" "):""}const W1=/^(\d{4})-(\d{2})(?:-\d{2})?(?:[T\s]|$)/;function Y1(e,t){if("string"==typeof t&&H1.test(t)){const t="number"==typeof e?e:Number(e);if(Number.isInteger(t)&&t>=1&&t<=12)return G1[t-1]}const n=function(e){if("string"!=typeof e)return null;const t=e.match(W1);if(!t)return null;const n=parseInt(t[1],10),r=parseInt(t[2],10);return!Number.isInteger(r)||r<1||r>12?null:"".concat(G1[r-1]," '").concat(String(n).slice(-2))}(e);return n||V1(e)}const K1=/^[a-z]+(_[a-z]+)+$/;const X1=/^-?\d+(\.\d+)?$/,Z1=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],Q1=/^\d{4}-\d{2}-\d{2}([T ]\d{2}:\d{2}(:\d{2})?(\.\d+)?(Z|[+-]\d{2}:?\d{2})?)?$/;function J1(e){return Number.isInteger(e)?e.toLocaleString("en-US"):Number(e.toFixed(2)).toLocaleString("en-US")}function e2(e,t){if(null==e)return"";if("number"==typeof e)return J1(e);if("object"==typeof e)return JSON.stringify(e);const n=String(e).trim(),r=function(e){if("string"!=typeof e)return null;const t=e.trim();if(!Q1.test(t))return null;const n=/[T ]\d{2}:\d{2}/.test(t),r=/(Z|[+-]\d{2}:?\d{2})$/.test(t),o=n&&!r?"".concat(t.replace(" ","T"),"Z"):t,a=new Date(o);if(isNaN(a.getTime()))return null;const i=n&&(0!==a.getUTCHours()||0!==a.getUTCMinutes()||0!==a.getUTCSeconds()),s="".concat(Z1[a.getUTCMonth()]," ").concat(a.getUTCDate(),", ").concat(a.getUTCFullYear());if(!i)return s;const l=a.getUTCHours(),c=l>=12?"PM":"AM",u=l%12||12,d=String(a.getUTCMinutes()).padStart(2,"0");return"".concat(s,", ").concat(u,":").concat(d," ").concat(c)}(n);if(r)return r;if("string"==typeof(o=t)&&q1.test(o)&&X1.test(n)){const e=Number(n);if(Number.isFinite(e))return J1(e)}var o,a;return"string"!=typeof(a=e)?String(null!=a?a:""):a.length>40?a:K1.test(a)?V1(a):a}function t2(e){let{size:t=14}=e;return n.jsxs("svg",{width:t,height:t,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:[n.jsx("polyline",{points:"22 7 13.5 15.5 8.5 10.5 2 17"}),n.jsx("polyline",{points:"16 7 22 7 22 13"})]})}function n2(e){let{size:t=14}=e;return n.jsxs("svg",{width:t,height:t,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:[n.jsx("path",{d:"M16 16c0-1.7-2-3-2-3"}),n.jsx("path",{d:"M8 16c0-1.7 2-3 2-3"}),n.jsx("path",{d:"M7 21h10"}),n.jsx("path",{d:"M12 3v18"}),n.jsx("path",{d:"m17 7 5 9h-10z"}),n.jsx("path",{d:"m7 7-5 9h10z"})]})}function r2(e){let{size:t=14}=e;return n.jsxs("svg",{width:t,height:t,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:[n.jsx("circle",{cx:"5",cy:"6",r:"3"}),n.jsx("circle",{cx:"19",cy:"18",r:"3"}),n.jsx("path",{d:"M12 6h5a2 2 0 0 1 2 2v7"}),n.jsx("path",{d:"M12 18H7a2 2 0 0 1-2-2V9"})]})}function o2(e){let{size:t=14}=e;return n.jsx("svg",{width:t,height:t,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:n.jsx("polygon",{points:"13 2 3 14 12 14 11 22 21 10 12 10 13 2"})})}function a2(e){let{size:t=14}=e;return n.jsxs("svg",{width:t,height:t,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:[n.jsx("path",{d:"M15 14c.2-1 .7-1.7 1.5-2.5 1-.9 1.5-2.2 1.5-3.5A6 6 0 0 0 6 8c0 1 .2 2.2 1.5 3.5.7.7 1.3 1.5 1.5 2.5"}),n.jsx("path",{d:"M9 18h6"}),n.jsx("path",{d:"M10 22h4"})]})}function i2(e){let{size:t=14}=e;return n.jsxs("svg",{width:t,height:t,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:[n.jsx("circle",{cx:"12",cy:"12",r:"10"}),n.jsx("circle",{cx:"12",cy:"12",r:"6"}),n.jsx("circle",{cx:"12",cy:"12",r:"2"})]})}function s2(e){let{type:t,icon:r,title:o,count:a,isDark:i,children:s}=e;const{accent:l,iconBg:c,iconFg:u}=function(e,t){const n={"revenue-insights":t?["#10b981","#064e3b","#a7f3d0"]:["#10b981","#ecfdf5","#065f46"],"impact-analysis":t?["#f59e0b","#78350f","#fde68a"]:["#f59e0b","#fef3c7","#92400e"],"deviation-analysis":t?["#3b82f6","#1e3a8a","#bfdbfe"]:["#3b82f6","#dbeafe","#1e40af"],"main-drivers":t?["#8b5cf6","#4c1d95","#ddd6fe"]:["#8b5cf6","#ede9fe","#5b21b6"],"key-observations":t?["#059669","#064e3b","#a7f3d0"]:["#059669","#f0fdf4","#14532d"],recommendations:t?["#818cf8","#312e81","#c7d2fe"]:["#4f46e5","#eef2ff","#4f46e5"]},[r,o,a]=n[e]||["#64748b","#f1f5f9","#475569"];return{accent:r,iconBg:o,iconFg:a}}(t,i),d=i?"1px solid #374151":"1px solid #e5e7eb";return n.jsxs("div",{style:{background:i?"#1f2937":"#ffffff",border:d,borderRadius:12,overflow:"hidden",margin:"8px 0",color:i?"#f3f4f6":"#0f172a"},children:[n.jsx("div",{style:{height:4,background:l}}),n.jsxs("div",{style:{display:"flex",alignItems:"center",justifyContent:"space-between",gap:8,padding:"12px 14px 10px",borderBottom:d},children:[n.jsxs("div",{style:{display:"flex",alignItems:"center",gap:8,fontSize:13,fontWeight:700},children:[n.jsx("span",{style:{display:"inline-flex",alignItems:"center",justifyContent:"center",width:22,height:22,borderRadius:6,background:c,color:u},children:r}),o]}),null!=a&&n.jsx("div",{style:{fontSize:11,color:i?"#9ca3af":"#64748b",fontVariantNumeric:"tabular-nums"},children:a})]}),n.jsx("div",{style:{padding:"12px 14px 14px",fontSize:13,lineHeight:1.55},children:s})]})}function l2(e){let{delta:t,isDark:r}=e;if(!t)return null;const o=function(e){const t=String(e||"").trim();return t?t.startsWith("+")?"up":t.startsWith("-")||t.startsWith("−")?"dn":"flat":"flat"}(t),a=(r?{up:{bg:"#064e3b",fg:"#a7f3d0"},dn:{bg:"#7f1d1d",fg:"#fecaca"},flat:{bg:"#1f2937",fg:"#9ca3af"}}:{up:{bg:"#dcfce7",fg:"#166534"},dn:{bg:"#fee2e2",fg:"#991b1b"},flat:{bg:"#f1f5f9",fg:"#64748b"}})[o];return n.jsx("span",{style:{fontSize:9,fontWeight:600,padding:"1px 5px",borderRadius:3,marginLeft:4,background:a.bg,color:a.fg},children:t})}function c2(e){let{items:t,isDark:r}=e;if(!t||!t.length)return null;const o=r?"1px solid #374151":"1px solid #e5e7eb",a=r?"#9ca3af":"#64748b",i=r?"#f3f4f6":"#0f172a",s=r?"#111827":"#f8fafc";return n.jsx("div",{style:{display:"flex",flexWrap:"wrap",gap:6,marginTop:4},children:t.map((e,t)=>n.jsxs("span",{style:{display:"inline-flex",alignItems:"baseline",gap:4,fontSize:11,lineHeight:1,padding:"5px 8px",borderRadius:6,background:s,border:o},children:[e.label&&n.jsxs("span",{style:{color:a},children:[e.label,":"]}),n.jsx("span",{style:{fontWeight:700,color:i,fontVariantNumeric:"tabular-nums"},children:e.value}),n.jsx(l2,{delta:e.delta,isDark:r})]},t))})}function u2(e){let{spec:t,isDark:r}=e;const o=Array.isArray(t.totals)?t.totals:[],a=r?"#9ca3af":"#64748b";return n.jsxs(s2,{type:"revenue-insights",icon:n.jsx(t2,{}),title:t.title||"Revenue insights",count:null,isDark:r,children:[t.headline&&n.jsx("div",{style:{fontSize:18,fontWeight:700,marginBottom:4},children:t.headline}),t.narrative&&n.jsx("div",{style:{color:a,marginBottom:o.length?8:0},children:t.narrative}),o.length>0&&n.jsx("div",{style:{display:"grid",gridTemplateColumns:"repeat(auto-fit, minmax(140px, 1fr))",gap:8,marginTop:8},children:o.map((e,t)=>n.jsxs("div",{style:{background:r?"#111827":"#f8fafc",border:r?"1px solid #374151":"1px solid #e5e7eb",borderRadius:8,padding:"8px 10px"},children:[n.jsx("div",{style:{fontSize:11,color:a},children:e.label}),n.jsxs("div",{style:{fontSize:16,fontWeight:700,fontVariantNumeric:"tabular-nums"},children:[e.value,n.jsx(l2,{delta:e.delta,isDark:r})]})]},t))})]})}function d2(e){let{items:t,sentiment:r,isDark:o}=e;if(!t||0===t.length)return null;const a="positive"===r?"Positive impact":"negative"===r?"Negative impact":"Neutral",i=o?"#9ca3af":"#64748b",s="positive"===r?{bg:o?"rgba(16,185,129,0.10)":"#f0fdf4",bd:o?"rgba(52,211,153,0.30)":"#bbf7d0",tx:o?"#a7f3d0":"#14532d",dot:o?"#34d399":"#10b981"}:"negative"===r?{bg:o?"rgba(239,68,68,0.10)":"#fef2f2",bd:o?"rgba(248,113,113,0.30)":"#fecaca",tx:o?"#fecaca":"#7f1d1d",dot:o?"#f87171":"#ef4444"}:{bg:o?"#111827":"#f8fafc",bd:o?"#374151":"#e2e8f0",tx:o?"#f3f4f6":"#0f172a",dot:o?"#9ca3af":"#94a3b8"};return n.jsxs("div",{children:[n.jsx("div",{style:{fontSize:11,fontWeight:700,textTransform:"uppercase",letterSpacing:"0.4px",color:i,margin:"10px 0 6px"},children:a}),t.map((e,t)=>n.jsxs("div",{style:{background:s.bg,border:"1px solid ".concat(s.bd),borderRadius:8,padding:"8px 10px",margin:"4px 0",color:s.tx},children:[n.jsxs("div",{style:{fontWeight:700,display:"block",marginBottom:2},children:[n.jsx("span",{style:{display:"inline-block",width:7,height:7,borderRadius:"50%",background:s.dot,marginRight:6,verticalAlign:"middle"}}),e.title]}),n.jsx("div",{children:e.description}),n.jsx(c2,{items:e.metrics,isDark:o})]},t))]})}function p2(e){let{spec:t,isDark:r}=e;return n.jsxs(s2,{type:"impact-analysis",icon:n.jsx(n2,{}),title:t.title||"Impact analysis",count:null,isDark:r,children:[n.jsx(d2,{items:t.positive,sentiment:"positive",isDark:r}),n.jsx(d2,{items:t.negative,sentiment:"negative",isDark:r}),n.jsx(d2,{items:t.neutral,sentiment:"neutral",isDark:r})]})}function f2(e){let{spec:t,isDark:r}=e;const o=Array.isArray(t.deviations)?t.deviations:[],a=r?"1px solid #374151":"1px solid #e5e7eb",i=r?"#9ca3af":"#64748b",s=r?"#f3f4f6":"#0f172a";return n.jsxs(s2,{type:"deviation-analysis",icon:n.jsx(r2,{}),title:t.title||"Deviation analysis",count:null,isDark:r,children:[0===o.length?n.jsx("div",{style:{color:i,fontSize:12,padding:"14px 0",textAlign:"center"},children:"No deviations"}):n.jsx("div",{style:{overflowX:"auto"},children:n.jsxs("table",{style:{width:"100%",borderCollapse:"collapse",fontSize:12},children:[n.jsx("thead",{children:n.jsx("tr",{children:["Segment","Metric","Expected","Actual","Delta"].map(e=>n.jsx("th",{style:{padding:"7px 10px",borderBottom:a,textAlign:"left",fontSize:11,color:i,fontWeight:600,textTransform:"uppercase",letterSpacing:"0.3px"},children:e},e))})}),n.jsx("tbody",{children:o.map((e,t)=>{return n.jsxs("tr",{children:[n.jsx("td",{style:{padding:"7px 10px",borderBottom:a,color:s},children:e.segment}),n.jsx("td",{style:{padding:"7px 10px",borderBottom:a,color:s},children:e.metric}),n.jsx("td",{style:{padding:"7px 10px",borderBottom:a,color:s,fontVariantNumeric:"tabular-nums"},children:e.expected}),n.jsx("td",{style:{padding:"7px 10px",borderBottom:a,color:s,fontVariantNumeric:"tabular-nums"},children:e.actual}),n.jsx("td",{style:{padding:"7px 10px",borderBottom:a,color:(o=e.tone,"up"===o?r?"#34d399":"#15803d":"dn"===o?r?"#f87171":"#b91c1c":r?"#9ca3af":"#64748b"),fontWeight:700,fontVariantNumeric:"tabular-nums"},children:e.delta})]},t);var o})})]})}),t.summary&&n.jsx("div",{style:{background:r?"#111827":"#f8fafc",border:a,borderRadius:6,padding:"8px 10px",marginTop:10,fontSize:12,color:s},children:t.summary})]})}function g2(e){let{spec:t,isDark:r}=e;const o=Array.isArray(t.secondary)?t.secondary:[],a=r?"#9ca3af":"#64748b",i=r?"#9ca3af":"#64748b",s=t.primary;return n.jsxs(s2,{type:"main-drivers",icon:n.jsx(o2,{}),title:t.title||"Main drivers",count:null,isDark:r,children:[s&&n.jsxs("div",{style:{background:r?"rgba(139,92,246,0.10)":"#faf5ff",border:r?"1px solid rgba(167,139,250,0.30)":"1px solid #d8b4fe",borderRadius:8,padding:"10px 12px",marginBottom:o.length?10:0},children:[n.jsx("div",{style:{fontSize:10,fontWeight:700,textTransform:"uppercase",letterSpacing:"0.4px",color:r?"#c4b5fd":"#7c3aed",marginBottom:4},children:"Primary driver"}),n.jsx("div",{style:{fontWeight:600},children:s.factor}),s.evidence&&n.jsx("div",{style:{color:a,fontSize:12,marginTop:4},children:s.evidence}),s.metric&&n.jsxs("span",{style:{display:"inline-block",marginTop:6,background:r?"rgba(139,92,246,0.20)":"#ede9fe",color:r?"#ddd6fe":"#5b21b6",fontSize:11,fontWeight:600,padding:"2px 7px",borderRadius:6},children:[s.metric.label,": ",s.metric.value]})]}),o.length>0&&n.jsxs(n.Fragment,{children:[n.jsx("div",{style:{fontSize:11,fontWeight:700,textTransform:"uppercase",letterSpacing:"0.4px",color:i,margin:"10px 0 6px"},children:"Secondary drivers"}),n.jsx("ul",{style:{paddingLeft:20,margin:0},children:o.map((e,t)=>n.jsxs("li",{style:{marginBottom:6},children:[n.jsx("div",{style:{fontWeight:600},children:e.factor}),e.evidence&&n.jsx("div",{style:{color:a,fontSize:12,marginTop:2},children:e.evidence})]},t))})]})]})}function h2(e){let{rankBgFg:t,rank:r,chips:o,text:a,narrative:i,metrics:s,impactPill:l,isDark:c}=e;const u=c?"#9ca3af":"#64748b",d=c?"1px dashed #374151":"1px dashed #e5e7eb";return n.jsxs("div",{style:{display:"flex",gap:10,alignItems:"flex-start",padding:"10px 0",borderBottom:d},children:[n.jsx("div",{style:{flex:"0 0 22px",height:22,width:22,borderRadius:"50%",fontSize:11,fontWeight:700,display:"flex",alignItems:"center",justifyContent:"center",fontVariantNumeric:"tabular-nums",background:t.bg,color:t.fg},children:r}),n.jsxs("div",{style:{flex:"1 1 auto",minWidth:0,display:"flex",flexDirection:"column",gap:5},children:[o,a&&n.jsx("div",{style:{fontSize:13,fontWeight:600},children:a}),i&&n.jsx("div",{style:{fontSize:12,color:u},children:i}),n.jsx(c2,{items:s,isDark:c}),l]})]})}function m2(e){let{spec:t,isDark:r}=e;const o=Array.isArray(t.items)?[...t.items].sort((e,t)=>(e.rank||0)-(t.rank||0)):[],a=r?{bg:"#064e3b",fg:"#a7f3d0"}:{bg:"#f0fdf4",fg:"#14532d"};return n.jsx(s2,{type:"key-observations",icon:n.jsx(a2,{}),title:t.title||"Key observations",count:o.length?"".concat(o.length," item").concat(1===o.length?"":"s"):null,isDark:r,children:0===o.length?n.jsx("div",{style:{color:r?"#9ca3af":"#64748b",fontSize:12,padding:"14px 0",textAlign:"center"},children:"No observations available."}):o.map((e,t)=>{const o=[];return e.category&&o.push(n.jsx("span",{style:y2("cat",r),children:e.category},"cat")),e.priority&&o.push(n.jsx("span",{style:y2("prio-"+e.priority,r),children:e.priority},"prio")),n.jsx(h2,{rankBgFg:a,rank:e.rank||t+1,chips:o.length?n.jsx("div",{style:{display:"flex",flexWrap:"wrap",gap:5},children:o}):null,text:e.text,narrative:e.narrative,metrics:e.metrics,impactPill:null,isDark:r},t)})})}function b2(e){let{spec:t,isDark:r}=e;const o=Array.isArray(t.items)?[...t.items].sort((e,t)=>(e.rank||0)-(t.rank||0)):[],a=r?{bg:"#312e81",fg:"#c7d2fe"}:{bg:"#4f46e5",fg:"#ffffff"};return n.jsx(s2,{type:"recommendations",icon:n.jsx(i2,{}),title:t.title||"Recommendations",count:o.length?"".concat(o.length," item").concat(1===o.length?"":"s"):null,isDark:r,children:0===o.length?n.jsx("div",{style:{color:r?"#9ca3af":"#64748b",fontSize:12,padding:"14px 0",textAlign:"center"},children:"No recommendations available."}):o.map((e,t)=>{const o=(e.affected_segments||[]).map((e,t)=>n.jsx("span",{style:y2("seg",r),children:e},t)),i=e.expected_impact?n.jsxs("span",{style:{alignSelf:"flex-start",display:"inline-flex",alignItems:"center",gap:4,marginTop:2,background:r?"rgba(16,185,129,0.18)":"#dcfce7",color:r?"#a7f3d0":"#166534",fontSize:10,fontWeight:700,padding:"4px 9px",borderRadius:999,border:r?"1px solid rgba(52,211,153,0.30)":"1px solid #bbf7d0"},children:["↑ ",e.expected_impact]}):null;return n.jsx(h2,{rankBgFg:a,rank:e.rank||t+1,chips:o.length?n.jsx("div",{style:{display:"flex",flexWrap:"wrap",gap:5},children:o}):null,text:e.action,narrative:e.rationale,metrics:e.metrics,impactPill:i,isDark:r},t)})})}function y2(e,t){const n={display:"inline-flex",alignItems:"center",fontSize:10,fontWeight:600,lineHeight:1,padding:"3px 7px",borderRadius:999,border:t?"1px solid #374151":"1px solid #e5e7eb",background:t?"#111827":"#f8fafc",color:t?"#9ca3af":"#64748b"};return"cat"===e?c(c({},n),{},{background:t?"rgba(99,102,241,0.20)":"#eef2ff",color:t?"#c7d2fe":"#4f46e5",border:"1px solid transparent"}):"seg"===e?c(c({},n),{},{background:t?"#1f2937":"#f1f5f9",color:t?"#f3f4f6":"#0f172a"}):"prio-high"===e?c(c({},n),{},{background:t?"rgba(239,68,68,0.18)":"#fef2f2",color:t?"#fecaca":"#7f1d1d",border:t?"1px solid rgba(248,113,113,0.30)":"1px solid #fecaca"}):"prio-medium"===e?c(c({},n),{},{background:t?"rgba(99,102,241,0.20)":"#eef2ff",color:t?"#c7d2fe":"#4f46e5",border:"1px solid transparent"}):n}const v2=/\[([\d०-९][\d०-९\s,]*)\](?!\()/g,w2={"०":"0","१":"1","२":"2","३":"3","४":"4","५":"5","६":"6","७":"7","८":"8","९":"9"};function S2(e){const t=[];for(const n of function(e){return e.replace(/[०-९]/g,e=>{var t;return null!==(t=w2[e])&&void 0!==t?t:e})}(e).split(",")){const e=n.trim();if(/^\d+$/.test(e)){const n=parseInt(e,10);n>=1&&t.push(n)}}return t}function x2(e){const t=new Set,n=[];for(const r of e)t.has(r)||(t.add(r),n.push(r));return n}function E2(){return e=>{Ds(e,"text",(e,t,n)=>{if(null==t||null==n)return;if("element"===n.type&&("code"===n.tagName||"pre"===n.tagName))return;const r=function(e){if(!e)return[];const t=[];let n;for(v2.lastIndex=0;null!==(n=v2.exec(e));){const e=S2(n[1]);0!==e.length&&t.push({start:n.index,end:v2.lastIndex,indices:e})}if(0===t.length)return[{type:"text",value:e}];const r=[];for(const n of t){const t=r.length?r[r.length-1]:null;t&&/^\s*$/.test(e.slice(t.end,n.start))?(t.end=n.end,t.indices.push(...n.indices)):r.push({start:n.start,end:n.end,indices:[...n.indices]})}const o=[];let a=0;for(const t of r)t.start>a&&o.push({type:"text",value:e.slice(a,t.start)}),o.push({type:"cite",indices:x2(t.indices)}),a=t.end;return a<e.length&&o.push({type:"text",value:e.slice(a)}),o}(e.value);if(1===r.length&&"text"===r[0].type)return;const o=r.map((e,t)=>{if("text"===e.type){return{type:"text",value:t+1<r.length&&"cite"===r[t+1].type?e.value.replace(/[ \t]+$/," "):e.value}}return{type:"element",tagName:"span",properties:{dataEshalCitation:(n=e.indices,n.join(","))},children:[]};var n});return n.children.splice(t,1,...o),[Ps,t+o.length]})}}const k2=["node","children"],A2=["children"],T2=["node","children"],O2=["node","children"],C2=["node","children"],I2=["node","children","start"],N2=["node","children","data-ol-index"],_2=["node","children"],R2=["node","children"],P2=["node","children"],L2=["node","children"],D2=["node","children"],M2=["node","children"],j2=["node","children"],F2=["className","children"],B2=new Set(["eshal-ui","eshal-chart","chart"]);function U2(e,t){if(!t)return e;const n=/^```(?:eshal-ui|eshal-chart|chart)\b/m.exec(e);if(n){const t=e.slice(n.index+n[0].length).split("\n").some(e=>"```"===e.trim());if(!t)return e.slice(0,n.index).trimEnd()}const r=e.split("\n");let o=r.length-1;for(;o>0&&""===r[o].trim();)o--;if(!r[o].trim().startsWith("|"))return e;let a=o;for(;a>0&&(r[a-1].trim().startsWith("|")||""===r[a-1].trim());)a--;const i=r.slice(a,o+1).some(e=>/^\|[\s\-:|]+\|/.test(e.trim()));return i?e:r.slice(0,a).join("\n")}function z2(e){return e.replace(/(\d+\.\d{2})0+(?!\d)/g,"$1")}var $2=Object.freeze({__proto__:null,default:function(t){let{content:r,isStreaming:o,isDark:a=!1,isRtl:i=!1,textColor:s,fontFamily:l,fontSize:d,onButtonClick:p,provideCitations:f=!0}=t;return n.jsx(Ol,{className:"max-w-none [&>*:last-child]:!mb-0 [&>*:first-child]:!mt-0",remarkPlugins:[Su,Eu],rehypePlugins:f?[E2]:[],components:{span(e){var t;let{node:r,children:o}=e,a=u(e,k2);const i=null!==(t=a["data-eshal-citation"])&&void 0!==t?t:a.dataEshalCitation;if("string"==typeof i&&i.length>0){const e=function(e){if(!e)return[];const t=[];for(const n of String(e).split(",")){const e=parseInt(n.trim(),10);Number.isFinite(e)&&e>=1&&t.push(e)}return x2(t)}(i);if(e.length>0)return n.jsx(ut,{indices:e})}return n.jsx("span",c(c({},a),{},{children:o}))},pre(t){let{children:r}=t,o=u(t,A2);return function(t){return e.Children.toArray(t).some(t=>{var n;if(!e.isValidElement(t))return!1;const r=null===(n=t.props)||void 0===n?void 0:n.className;if("string"!=typeof r)return!1;const o=r.match(/language-([\w-]+)/);return!!o&&B2.has(o[1])})}(r)?n.jsx(n.Fragment,{children:r}):n.jsx("pre",c(c({},o),{},{children:r}))},a(e){let{node:t,children:r}=e,o=u(e,T2);return n.jsx("a",c(c({className:"underline hover:opacity-80",dir:"ltr",style:{color:s||(a?"#f3f4f6":"#1A1A1A"),unicodeBidi:"isolate"},target:"_blank",rel:"noopener noreferrer"},o),{},{children:r}))},p(e){var t;let{node:r,children:o}=e,i=u(e,O2);const p="li"===(null==r||null===(t=r.parent)||void 0===t?void 0:t.tagName);return n.jsx("p",c(c({className:"leading-relaxed [&:first-child]:!mt-0",style:{color:s||(a?"#f3f4f6":"#1A1A1A"),fontFamily:l||"Inter",fontSize:d||"14px",margin:0,marginTop:0,marginBottom:p?"0.125rem":"0.85rem",lineHeight:"1.6",padding:0}},i),{},{children:o}))},ul(e){let{node:t,children:r}=e,o=u(e,C2);return n.jsx("ul",c(c({className:"list-disc [&:first-child]:!mt-0",style:{marginTop:0,marginBottom:"0.6rem",paddingInlineStart:"1.2rem"}},o),{},{children:r}))},ol(t){let{node:r,children:o,start:a=1}=t,i=u(t,I2);const s=Number.isFinite(Number(a))?Number(a):1;let l=0;return n.jsx("ol",c(c({className:"[&:first-child]:!mt-0",style:{listStyle:"none",marginTop:0,marginBottom:"0.6rem",paddingInlineStart:0}},i),{},{children:e.Children.map(o,t=>{if(!e.isValidElement(t))return t;const n=s+l;return l+=1,e.cloneElement(t,{"data-ol-index":n})})}))},li(e){let{node:t,children:r,"data-ol-index":o}=e,i=u(e,N2);const p={color:s||(a?"#f3f4f6":"#1A1A1A"),fontFamily:l||"Inter",fontSize:d||"14px",marginBottom:"0.3rem",lineHeight:"1.5"};return null!=o?n.jsxs("li",c(c({style:c(c({},p),{},{listStyle:"none",display:"flex",alignItems:"baseline",gap:"0.4em"})},i),{},{children:[n.jsxs("span",{style:{flexShrink:0,fontFamily:'-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif',fontVariantNumeric:"tabular-nums",minWidth:"1.5em",color:"inherit"},"aria-hidden":"false",children:[o,"."]}),n.jsx("span",{style:{flex:"1 1 auto",minWidth:0},children:r})]})):n.jsx("li",c(c({className:"",style:p},i),{},{children:r}))},h1(e){let{node:t,children:r}=e,o=u(e,_2);return n.jsx("h1",c(c({className:"text-xl font-bold [&:first-child]:!mt-0",style:{color:s||(a?"#f3f4f6":"#1A1A1A"),fontFamily:l||"Inter",marginTop:"0.7rem",marginBottom:"0.45rem",lineHeight:"1.35"}},o),{},{children:r}))},h2(e){let{node:t,children:r}=e,o=u(e,R2);return n.jsx("h2",c(c({className:"text-lg font-semibold [&:first-child]:!mt-0",style:{color:s||(a?"#f3f4f6":"#1A1A1A"),fontFamily:l||"Inter",marginTop:"0.65rem",marginBottom:"0.4rem",lineHeight:"1.35"}},o),{},{children:r}))},h3(e){let{node:t,children:r}=e,o=u(e,P2);return n.jsx("h3",c(c({className:"text-base font-semibold [&:first-child]:!mt-0",style:{color:s||(a?"#f3f4f6":"#1A1A1A"),fontFamily:l||"Inter",marginTop:"0.6rem",marginBottom:"0.35rem",lineHeight:"1.35"}},o),{},{children:r}))},blockquote(e){let{node:t,children:r}=e,o=u(e,L2);return n.jsx("blockquote",c(c({className:"border-l-4 pl-4 italic ".concat(a?"border-gray-600 text-gray-300":"border-gray-300 text-gray-700")},o),{},{children:r}))},table(e){var t;let{node:r,children:o}=e,i=u(e,D2);if((null==r||null===(t=r.children)||void 0===t?void 0:t.length)>0){var s;function l(e){return e?"string"==typeof e.value?e.value:Array.isArray(e.children)?e.children.map(l).join(""):"":""}const d=r.children.find(e=>"thead"===e.tagName),p=r.children.find(e=>"tbody"===e.tagName),f=null==d||null===(s=d.children)||void 0===s?void 0:s.find(e=>"tr"===e.tagName),g=((null==f?void 0:f.children)||[]).filter(e=>"th"===e.tagName).map(e=>l(e)),h=((null==p?void 0:p.children)||[]).filter(e=>"tr"===e.tagName),m=h.map(e=>(e.children||[]).filter(e=>"td"===e.tagName).map(e=>l(e)));if(g.length>0&&m.length>0){const b=m.map(e=>Object.fromEntries(g.map((t,n)=>{var r;return[t,null!==(r=e[n])&&void 0!==r?r:""]})));return n.jsx(S1,{spec:{type:"table",columns:g,data:b},isDark:a})}}return n.jsx("div",{className:"overflow-x-auto my-3 rounded-lg border ".concat(a?"border-gray-700 bg-gray-900":"border-gray-200 bg-white"),children:n.jsx("table",c(c({className:"min-w-full border-collapse ".concat(a?"text-gray-100":"text-gray-900")},i),{},{children:o}))})},th(e){let{node:t,children:r}=e,o=u(e,M2);return n.jsx("th",c(c({className:"border px-3 py-2 text-left font-medium ".concat(a?"border-gray-700 bg-gray-800/50 text-gray-300":"border-gray-200 bg-gray-50 text-gray-700")},o),{},{children:r}))},td(e){let{node:t,children:r}=e,o=u(e,j2);return n.jsx("td",c(c({className:"border px-3 py-2 ".concat(a?"border-gray-700":"border-gray-200")},o),{},{children:r}))},code(e){let{className:t,children:r}=e,o=u(e,F2);const i=/language-([\w-]+)/.exec(t||""),s=i?i[1]:null;if(s&&B2.has(s)){const e=function(e){return"string"==typeof e?e:Array.isArray(e)?e.map(e=>"string"==typeof e?e:"").join(""):""}(r).trim();try{const t=JSON.parse(e);if(t&&"object"==typeof t)return n.jsx(S1,{spec:t,isDark:a,onButtonClick:p})}catch(e){return null}return null}return i?n.jsx(pk,c(c({style:fk,language:s,PreTag:"div",wrapLines:!0},o),{},{children:String(r).replace(/\n$/,"")})):n.jsx("code",c(c({className:t},o),{},{children:r}))}},children:z2(U2(r,o))})},sanitizeExcessDecimalPrecision:z2,sanitizeStreamingContent:U2});return function(r){const o=e.useRef(null),a=e.useRef(null);return e.useEffect(()=>{const e=o.current;if(!e||e.shadowRoot)return;const n=e.attachShadow({mode:"open"}),r=document.createElement("style");r.textContent=":host { all: initial; display: block; }",n.appendChild(r);const i=document.createElement("style");i.textContent='*,:after,:before{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }::backdrop{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }.chat-widget-root{--cw-primary:#2563eb;--cw-primary-hover:#1d4ed8;--cw-status-success:160 84% 39%;--cw-status-success-bg:152 81% 96%;--cw-status-warning:35 100% 50%;--cw-status-warning-bg:34 100% 95%;--cw-status-error:350 89% 60%;--cw-status-error-bg:356 100% 97%;--cw-status-info:199 89% 48%;--cw-status-info-bg:204 100% 97%;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,Fira Sans,Droid Sans,Helvetica Neue,sans-serif}.chat-widget-root.dark{--cw-status-success:158 64% 52%;--cw-status-success-bg:152 36% 14%;--cw-status-warning:38 92% 60%;--cw-status-warning-bg:36 33% 14%;--cw-status-error:350 89% 65%;--cw-status-error-bg:356 33% 16%;--cw-status-info:199 89% 58%;--cw-status-info-bg:204 33% 14%}.\\!container{width:100%!important}.container{width:100%}@media (min-width:640px){.\\!container{max-width:640px!important}.container{max-width:640px}}@media (min-width:768px){.\\!container{max-width:768px!important}.container{max-width:768px}}@media (min-width:1024px){.\\!container{max-width:1024px!important}.container{max-width:1024px}}@media (min-width:1280px){.\\!container{max-width:1280px!important}.container{max-width:1280px}}@media (min-width:1536px){.\\!container{max-width:1536px!important}.container{max-width:1536px}}#chat-widget-root .chat-widget-root *{box-sizing:border-box;margin:0;padding:0}#chat-widget-root .chat-messages::-webkit-scrollbar{width:6px}#chat-widget-root .chat-messages::-webkit-scrollbar-track{background:transparent}#chat-widget-root .chat-messages::-webkit-scrollbar-thumb{background:rgba(156,163,175,.5);border-radius:10px}#chat-widget-root .chat-messages::-webkit-scrollbar-thumb:hover{background:rgba(156,163,175,.7)}#chat-widget-root .dark .chat-messages::-webkit-scrollbar-thumb{background:rgba(75,85,99,.5)}#chat-widget-root .dark .chat-messages::-webkit-scrollbar-thumb:hover{background:rgba(75,85,99,.7)}#chat-widget-root .sr-only{clip:rect(0,0,0,0);border-width:0;height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;white-space:nowrap;width:1px}#chat-widget-root .pointer-events-none{pointer-events:none}#chat-widget-root .visible{visibility:visible}#chat-widget-root .collapse{visibility:collapse}#chat-widget-root .static{position:static}#chat-widget-root .fixed{position:fixed}#chat-widget-root .absolute{position:absolute}#chat-widget-root .relative{position:relative}#chat-widget-root .sticky{position:sticky}#chat-widget-root .inset-0{inset:0}#chat-widget-root .-top-8{top:-2rem}#chat-widget-root .bottom-0{bottom:0}#chat-widget-root .bottom-5{bottom:1.25rem}#chat-widget-root .bottom-full{bottom:100%}#chat-widget-root .left-0{left:0}#chat-widget-root .left-1\\/2{left:50%}#chat-widget-root .left-5{left:1.25rem}#chat-widget-root .right-0{right:0}#chat-widget-root .right-5{right:1.25rem}#chat-widget-root .top-0{top:0}#chat-widget-root .top-1\\/2{top:50%}#chat-widget-root .top-5{top:1.25rem}#chat-widget-root .top-full{top:100%}#chat-widget-root .isolate{isolation:isolate}#chat-widget-root .z-10{z-index:10}#chat-widget-root .z-50{z-index:50}#chat-widget-root .z-\\[60\\]{z-index:60}#chat-widget-root .z-\\[70\\]{z-index:70}#chat-widget-root .z-\\[71\\]{z-index:71}#chat-widget-root .z-\\[999999\\]{z-index:999999}#chat-widget-root .z-\\[9999\\]{z-index:9999}#chat-widget-root .m-0{margin:0}#chat-widget-root .mx-2{margin-left:.5rem;margin-right:.5rem}#chat-widget-root .my-3{margin-bottom:.75rem;margin-top:.75rem}#chat-widget-root .my-4{margin-bottom:1rem;margin-top:1rem}#chat-widget-root .-mb-px{margin-bottom:-1px}#chat-widget-root .mb-1{margin-bottom:.25rem}#chat-widget-root .mb-1\\.5{margin-bottom:.375rem}#chat-widget-root .mb-2{margin-bottom:.5rem}#chat-widget-root .mb-3{margin-bottom:.75rem}#chat-widget-root .mb-4{margin-bottom:1rem}#chat-widget-root .mb-5{margin-bottom:1.25rem}#chat-widget-root .ml-0\\.5{margin-left:.125rem}#chat-widget-root .ml-1{margin-left:.25rem}#chat-widget-root .mt-0\\.5{margin-top:.125rem}#chat-widget-root .mt-1{margin-top:.25rem}#chat-widget-root .mt-1\\.5{margin-top:.375rem}#chat-widget-root .mt-2{margin-top:.5rem}#chat-widget-root .mt-3{margin-top:.75rem}#chat-widget-root .mt-4{margin-top:1rem}#chat-widget-root .block{display:block}#chat-widget-root .inline-block{display:inline-block}#chat-widget-root .inline{display:inline}#chat-widget-root .flex{display:flex}#chat-widget-root .inline-flex{display:inline-flex}#chat-widget-root .table{display:table}#chat-widget-root .grid{display:grid}#chat-widget-root .hidden{display:none}#chat-widget-root .h-1\\.5{height:.375rem}#chat-widget-root .h-10{height:2.5rem}#chat-widget-root .h-11{height:2.75rem}#chat-widget-root .h-12{height:3rem}#chat-widget-root .h-14{height:3.5rem}#chat-widget-root .h-16{height:4rem}#chat-widget-root .h-2{height:.5rem}#chat-widget-root .h-3{height:.75rem}#chat-widget-root .h-3\\.5{height:.875rem}#chat-widget-root .h-4{height:1rem}#chat-widget-root .h-5{height:1.25rem}#chat-widget-root .h-6{height:1.5rem}#chat-widget-root .h-7{height:1.75rem}#chat-widget-root .h-8{height:2rem}#chat-widget-root .h-\\[650px\\]{height:650px}#chat-widget-root .h-auto{height:auto}#chat-widget-root .h-full{height:100%}#chat-widget-root .h-px{height:1px}#chat-widget-root .max-h-\\[85vh\\]{max-height:85vh}#chat-widget-root .min-h-0{min-height:0}#chat-widget-root .min-h-\\[48px\\]{min-height:48px}#chat-widget-root .w-1\\.5{width:.375rem}#chat-widget-root .w-10{width:2.5rem}#chat-widget-root .w-11{width:2.75rem}#chat-widget-root .w-12{width:3rem}#chat-widget-root .w-14{width:3.5rem}#chat-widget-root .w-16{width:4rem}#chat-widget-root .w-2{width:.5rem}#chat-widget-root .w-3{width:.75rem}#chat-widget-root .w-3\\.5{width:.875rem}#chat-widget-root .w-4{width:1rem}#chat-widget-root .w-44{width:11rem}#chat-widget-root .w-5{width:1.25rem}#chat-widget-root .w-6{width:1.5rem}#chat-widget-root .w-7{width:1.75rem}#chat-widget-root .w-8{width:2rem}#chat-widget-root .w-80{width:20rem}#chat-widget-root .w-96{width:24rem}#chat-widget-root .w-\\[380px\\]{width:380px}#chat-widget-root .w-full{width:100%}#chat-widget-root .min-w-0{min-width:0}#chat-widget-root .min-w-\\[60px\\]{min-width:60px}#chat-widget-root .min-w-full{min-width:100%}#chat-widget-root .max-w-\\[75\\%\\]{max-width:75%}#chat-widget-root .max-w-\\[92vw\\]{max-width:92vw}#chat-widget-root .max-w-full{max-width:100%}#chat-widget-root .max-w-none{max-width:none}#chat-widget-root .max-w-sm{max-width:24rem}#chat-widget-root .max-w-xs{max-width:20rem}#chat-widget-root .flex-1{flex:1 1 0%}#chat-widget-root .flex-shrink-0{flex-shrink:0}#chat-widget-root .grow{flex-grow:1}#chat-widget-root .border-collapse{border-collapse:collapse}#chat-widget-root .-translate-x-1\\/2{--tw-translate-x:-50%}#chat-widget-root .-translate-x-1\\/2,#chat-widget-root .-translate-y-1\\/2{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}#chat-widget-root .-translate-y-1\\/2{--tw-translate-y:-50%}#chat-widget-root .-rotate-90{--tw-rotate:-90deg}#chat-widget-root .-rotate-90,#chat-widget-root .rotate-180{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}#chat-widget-root .rotate-180{--tw-rotate:180deg}#chat-widget-root .rotate-90{--tw-rotate:90deg}#chat-widget-root .rotate-90,#chat-widget-root .scale-0{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}#chat-widget-root .scale-0{--tw-scale-x:0;--tw-scale-y:0}#chat-widget-root .scale-100{--tw-scale-x:1;--tw-scale-y:1}#chat-widget-root .scale-100,#chat-widget-root .scale-110{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}#chat-widget-root .scale-110{--tw-scale-x:1.1;--tw-scale-y:1.1}#chat-widget-root .scale-125{--tw-scale-x:1.25;--tw-scale-y:1.25}#chat-widget-root .scale-125,#chat-widget-root .scale-95{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}#chat-widget-root .scale-95{--tw-scale-x:.95;--tw-scale-y:.95}#chat-widget-root .transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@keyframes bounce{0%,to{animation-timing-function:cubic-bezier(.8,0,1,1);transform:translateY(-25%)}50%{animation-timing-function:cubic-bezier(0,0,.2,1);transform:none}}#chat-widget-root .animate-bounce{animation:bounce 1s infinite}@keyframes pulse{50%{opacity:.5}}#chat-widget-root .animate-pulse{animation:pulse 2s cubic-bezier(.4,0,.6,1) infinite}@keyframes spin{to{transform:rotate(1turn)}}#chat-widget-root .animate-spin{animation:spin 1s linear infinite}#chat-widget-root .cursor-ew-resize{cursor:ew-resize}#chat-widget-root .cursor-nesw-resize{cursor:nesw-resize}#chat-widget-root .cursor-not-allowed{cursor:not-allowed}#chat-widget-root .cursor-ns-resize{cursor:ns-resize}#chat-widget-root .cursor-nwse-resize{cursor:nwse-resize}#chat-widget-root .cursor-pointer{cursor:pointer}#chat-widget-root .resize-none{resize:none}#chat-widget-root .resize{resize:both}#chat-widget-root .list-decimal{list-style-type:decimal}#chat-widget-root .list-disc{list-style-type:disc}#chat-widget-root .list-none{list-style-type:none}#chat-widget-root .flex-row{flex-direction:row}#chat-widget-root .flex-row-reverse{flex-direction:row-reverse}#chat-widget-root .flex-col{flex-direction:column}#chat-widget-root .flex-wrap{flex-wrap:wrap}#chat-widget-root .items-start{align-items:flex-start}#chat-widget-root .items-end{align-items:flex-end}#chat-widget-root .items-center{align-items:center}#chat-widget-root .justify-start{justify-content:flex-start}#chat-widget-root .justify-end{justify-content:flex-end}#chat-widget-root .justify-center{justify-content:center}#chat-widget-root .justify-between{justify-content:space-between}#chat-widget-root .gap-0{gap:0}#chat-widget-root .gap-0\\.5{gap:.125rem}#chat-widget-root .gap-1{gap:.25rem}#chat-widget-root .gap-1\\.5{gap:.375rem}#chat-widget-root .gap-2{gap:.5rem}#chat-widget-root .gap-2\\.5{gap:.625rem}#chat-widget-root .gap-3{gap:.75rem}#chat-widget-root .gap-4{gap:1rem}#chat-widget-root .gap-6{gap:1.5rem}#chat-widget-root :is(.space-y-1>:not([hidden])~:not([hidden])){--tw-space-y-reverse:0;margin-bottom:calc(.25rem*var(--tw-space-y-reverse));margin-top:calc(.25rem*(1 - var(--tw-space-y-reverse)))}#chat-widget-root :is(.space-y-2>:not([hidden])~:not([hidden])){--tw-space-y-reverse:0;margin-bottom:calc(.5rem*var(--tw-space-y-reverse));margin-top:calc(.5rem*(1 - var(--tw-space-y-reverse)))}#chat-widget-root :is(.space-y-4>:not([hidden])~:not([hidden])){--tw-space-y-reverse:0;margin-bottom:calc(1rem*var(--tw-space-y-reverse));margin-top:calc(1rem*(1 - var(--tw-space-y-reverse)))}#chat-widget-root .overflow-hidden{overflow:hidden}#chat-widget-root .overflow-visible{overflow:visible}#chat-widget-root .overflow-x-auto{overflow-x:auto}#chat-widget-root .overflow-y-auto{overflow-y:auto}#chat-widget-root .truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}#chat-widget-root .whitespace-nowrap{white-space:nowrap}#chat-widget-root .whitespace-pre-wrap{white-space:pre-wrap}#chat-widget-root .break-words{overflow-wrap:break-word}#chat-widget-root .break-all{word-break:break-all}#chat-widget-root .rounded{border-radius:.25rem}#chat-widget-root .rounded-2xl{border-radius:1rem}#chat-widget-root .rounded-3xl{border-radius:1.5rem}#chat-widget-root .rounded-full{border-radius:9999px}#chat-widget-root .rounded-lg{border-radius:.5rem}#chat-widget-root .rounded-md{border-radius:.375rem}#chat-widget-root .rounded-xl{border-radius:.75rem}#chat-widget-root .rounded-t-2xl{border-top-left-radius:1rem;border-top-right-radius:1rem}#chat-widget-root .rounded-tl-sm{border-top-left-radius:.125rem}#chat-widget-root .rounded-tr-sm{border-top-right-radius:.125rem}#chat-widget-root .border{border-width:1px}#chat-widget-root .border-0{border-width:0}#chat-widget-root .border-b{border-bottom-width:1px}#chat-widget-root .border-l-4{border-left-width:4px}#chat-widget-root .border-t{border-top-width:1px}#chat-widget-root .border-t-2{border-top-width:2px}#chat-widget-root .border-dotted{border-style:dotted}#chat-widget-root .border-none{border-style:none}#chat-widget-root .\\!border-status-error{border-color:hsl(var(--cw-status-error))!important}#chat-widget-root .border-blue-200{--tw-border-opacity:1;border-color:rgb(191 219 254/var(--tw-border-opacity,1))}#chat-widget-root .border-blue-700\\/50{border-color:rgba(29,78,216,.5)}#chat-widget-root .border-gray-100{--tw-border-opacity:1;border-color:rgb(243 244 246/var(--tw-border-opacity,1))}#chat-widget-root .border-gray-200{--tw-border-opacity:1;border-color:rgb(229 231 235/var(--tw-border-opacity,1))}#chat-widget-root .border-gray-200\\/60{border-color:rgba(229,231,235,.6)}#chat-widget-root .border-gray-300{--tw-border-opacity:1;border-color:rgb(209 213 219/var(--tw-border-opacity,1))}#chat-widget-root .border-gray-600{--tw-border-opacity:1;border-color:rgb(75 85 99/var(--tw-border-opacity,1))}#chat-widget-root .border-gray-700{--tw-border-opacity:1;border-color:rgb(55 65 81/var(--tw-border-opacity,1))}#chat-widget-root .border-gray-700\\/50{border-color:rgba(55,65,81,.5)}#chat-widget-root .border-transparent{border-color:transparent}#chat-widget-root .bg-blue-50{--tw-bg-opacity:1;background-color:rgb(239 246 255/var(--tw-bg-opacity,1))}#chat-widget-root .bg-blue-500{--tw-bg-opacity:1;background-color:rgb(59 130 246/var(--tw-bg-opacity,1))}#chat-widget-root .bg-blue-900\\/30{background-color:rgba(30,58,138,.3)}#chat-widget-root .bg-current{background-color:currentColor}#chat-widget-root .bg-gray-100{--tw-bg-opacity:1;background-color:rgb(243 244 246/var(--tw-bg-opacity,1))}#chat-widget-root .bg-gray-400{--tw-bg-opacity:1;background-color:rgb(156 163 175/var(--tw-bg-opacity,1))}#chat-widget-root .bg-gray-50{--tw-bg-opacity:1;background-color:rgb(249 250 251/var(--tw-bg-opacity,1))}#chat-widget-root .bg-gray-500{--tw-bg-opacity:1;background-color:rgb(107 114 128/var(--tw-bg-opacity,1))}#chat-widget-root .bg-gray-700{--tw-bg-opacity:1;background-color:rgb(55 65 81/var(--tw-bg-opacity,1))}#chat-widget-root .bg-gray-700\\/50{background-color:rgba(55,65,81,.5)}#chat-widget-root .bg-gray-800{--tw-bg-opacity:1;background-color:rgb(31 41 55/var(--tw-bg-opacity,1))}#chat-widget-root .bg-gray-800\\/50{background-color:rgba(31,41,55,.5)}#chat-widget-root .bg-gray-900{--tw-bg-opacity:1;background-color:rgb(17 24 39/var(--tw-bg-opacity,1))}#chat-widget-root .bg-green-200{--tw-bg-opacity:1;background-color:rgb(187 247 208/var(--tw-bg-opacity,1))}#chat-widget-root .bg-orange-200{--tw-bg-opacity:1;background-color:rgb(254 215 170/var(--tw-bg-opacity,1))}#chat-widget-root .bg-pink-200{--tw-bg-opacity:1;background-color:rgb(251 207 232/var(--tw-bg-opacity,1))}#chat-widget-root .bg-red-200{--tw-bg-opacity:1;background-color:rgb(254 202 202/var(--tw-bg-opacity,1))}#chat-widget-root .bg-red-500{--tw-bg-opacity:1;background-color:rgb(239 68 68/var(--tw-bg-opacity,1))}#chat-widget-root .bg-slate-50\\/50{background-color:rgba(248,250,252,.5)}#chat-widget-root .bg-slate-800\\/50{background-color:rgba(30,41,59,.5)}#chat-widget-root .bg-transparent{background-color:transparent}#chat-widget-root .bg-white{--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity,1))}#chat-widget-root .bg-white\\/10{background-color:hsla(0,0%,100%,.1)}#chat-widget-root .bg-white\\/20{background-color:hsla(0,0%,100%,.2)}#chat-widget-root .bg-yellow-200{--tw-bg-opacity:1;background-color:rgb(254 240 138/var(--tw-bg-opacity,1))}#chat-widget-root .bg-gradient-to-b{background-image:linear-gradient(to bottom,var(--tw-gradient-stops))}#chat-widget-root .bg-gradient-to-br{background-image:linear-gradient(to bottom right,var(--tw-gradient-stops))}#chat-widget-root .from-gray-50\\/50{--tw-gradient-from:rgba(249,250,251,.5) var(--tw-gradient-from-position);--tw-gradient-to:rgba(249,250,251,0) var(--tw-gradient-to-position);--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)}#chat-widget-root .from-white\\/0{--tw-gradient-from:hsla(0,0%,100%,0) var(--tw-gradient-from-position);--tw-gradient-to:hsla(0,0%,100%,0) var(--tw-gradient-to-position);--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)}#chat-widget-root .from-white\\/10{--tw-gradient-from:hsla(0,0%,100%,.1) var(--tw-gradient-from-position);--tw-gradient-to:hsla(0,0%,100%,0) var(--tw-gradient-to-position);--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)}#chat-widget-root .from-yellow-200{--tw-gradient-from:#fef08a var(--tw-gradient-from-position);--tw-gradient-to:hsla(53,98%,77%,0) var(--tw-gradient-to-position);--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)}#chat-widget-root .via-white\\/5{--tw-gradient-to:hsla(0,0%,100%,0) var(--tw-gradient-to-position);--tw-gradient-stops:var(--tw-gradient-from),hsla(0,0%,100%,.05) var(--tw-gradient-via-position),var(--tw-gradient-to)}#chat-widget-root .to-white{--tw-gradient-to:#fff var(--tw-gradient-to-position)}#chat-widget-root .to-white\\/10{--tw-gradient-to:hsla(0,0%,100%,.1) var(--tw-gradient-to-position)}#chat-widget-root .to-yellow-400{--tw-gradient-to:#facc15 var(--tw-gradient-to-position)}#chat-widget-root .object-cover{-o-object-fit:cover;object-fit:cover}#chat-widget-root .p-0{padding:0}#chat-widget-root .p-0\\.5{padding:.125rem}#chat-widget-root .p-3{padding:.75rem}#chat-widget-root .p-5{padding:1.25rem}#chat-widget-root .p-6{padding:1.5rem}#chat-widget-root .p-8{padding:2rem}#chat-widget-root .px-1{padding-left:.25rem;padding-right:.25rem}#chat-widget-root .px-2{padding-left:.5rem;padding-right:.5rem}#chat-widget-root .px-2\\.5{padding-left:.625rem;padding-right:.625rem}#chat-widget-root .px-3{padding-left:.75rem;padding-right:.75rem}#chat-widget-root .px-4{padding-left:1rem;padding-right:1rem}#chat-widget-root .px-5{padding-left:1.25rem;padding-right:1.25rem}#chat-widget-root .py-1{padding-bottom:.25rem;padding-top:.25rem}#chat-widget-root .py-1\\.5{padding-bottom:.375rem;padding-top:.375rem}#chat-widget-root .py-12{padding-bottom:3rem;padding-top:3rem}#chat-widget-root .py-2{padding-bottom:.5rem;padding-top:.5rem}#chat-widget-root .py-2\\.5{padding-bottom:.625rem;padding-top:.625rem}#chat-widget-root .py-3{padding-bottom:.75rem;padding-top:.75rem}#chat-widget-root .py-3\\.5{padding-bottom:.875rem;padding-top:.875rem}#chat-widget-root .py-4{padding-bottom:1rem;padding-top:1rem}#chat-widget-root .pb-1{padding-bottom:.25rem}#chat-widget-root .pb-2{padding-bottom:.5rem}#chat-widget-root .pl-1{padding-left:.25rem}#chat-widget-root .pl-2{padding-left:.5rem}#chat-widget-root .pl-4{padding-left:1rem}#chat-widget-root .pl-\\[50px\\]{padding-left:50px}#chat-widget-root .pr-1{padding-right:.25rem}#chat-widget-root .pt-1{padding-top:.25rem}#chat-widget-root .text-left{text-align:left}#chat-widget-root .text-center{text-align:center}#chat-widget-root .text-right{text-align:right}#chat-widget-root .align-text-bottom{vertical-align:text-bottom}#chat-widget-root .font-sans{font-family:ui-sans-serif,system-ui,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji}#chat-widget-root .text-2xl{font-size:1.5rem;line-height:2rem}#chat-widget-root .text-\\[10px\\]{font-size:10px}#chat-widget-root .text-base{font-size:1rem;line-height:1.5rem}#chat-widget-root .text-chip{font-size:11px;letter-spacing:0;line-height:1.4}#chat-widget-root .text-h4{font-size:18px;letter-spacing:0;line-height:1.3}#chat-widget-root .text-lg{font-size:1.125rem;line-height:1.75rem}#chat-widget-root .text-sm{font-size:.875rem;line-height:1.25rem}#chat-widget-root .text-xl{font-size:1.25rem;line-height:1.75rem}#chat-widget-root .text-xs{font-size:.75rem;line-height:1rem}#chat-widget-root .font-bold{font-weight:700}#chat-widget-root .font-medium{font-weight:500}#chat-widget-root .font-semibold{font-weight:600}#chat-widget-root .uppercase{text-transform:uppercase}#chat-widget-root .lowercase{text-transform:lowercase}#chat-widget-root .italic{font-style:italic}#chat-widget-root .tabular-nums{--tw-numeric-spacing:tabular-nums;font-variant-numeric:var(--tw-ordinal) var(--tw-slashed-zero) var(--tw-numeric-figure) var(--tw-numeric-spacing) var(--tw-numeric-fraction)}#chat-widget-root .leading-5{line-height:1.25rem}#chat-widget-root .leading-none{line-height:1}#chat-widget-root .leading-normal{line-height:1.5}#chat-widget-root .leading-relaxed{line-height:1.625}#chat-widget-root .leading-snug{line-height:1.375}#chat-widget-root .tracking-wide{letter-spacing:.025em}#chat-widget-root .text-\\[\\#4A5568\\]{--tw-text-opacity:1;color:rgb(74 85 104/var(--tw-text-opacity,1))}#chat-widget-root .text-current{color:currentColor}#chat-widget-root .text-gray-100{--tw-text-opacity:1;color:rgb(243 244 246/var(--tw-text-opacity,1))}#chat-widget-root .text-gray-200{--tw-text-opacity:1;color:rgb(229 231 235/var(--tw-text-opacity,1))}#chat-widget-root .text-gray-300{--tw-text-opacity:1;color:rgb(209 213 219/var(--tw-text-opacity,1))}#chat-widget-root .text-gray-400{--tw-text-opacity:1;color:rgb(156 163 175/var(--tw-text-opacity,1))}#chat-widget-root .text-gray-500{--tw-text-opacity:1;color:rgb(107 114 128/var(--tw-text-opacity,1))}#chat-widget-root .text-gray-500\\/80{color:hsla(220,9%,46%,.8)}#chat-widget-root .text-gray-600{--tw-text-opacity:1;color:rgb(75 85 99/var(--tw-text-opacity,1))}#chat-widget-root .text-gray-700{--tw-text-opacity:1;color:rgb(55 65 81/var(--tw-text-opacity,1))}#chat-widget-root .text-gray-800{--tw-text-opacity:1;color:rgb(31 41 55/var(--tw-text-opacity,1))}#chat-widget-root .text-gray-900{--tw-text-opacity:1;color:rgb(17 24 39/var(--tw-text-opacity,1))}#chat-widget-root .text-green-500{--tw-text-opacity:1;color:rgb(34 197 94/var(--tw-text-opacity,1))}#chat-widget-root .text-red-500{--tw-text-opacity:1;color:rgb(239 68 68/var(--tw-text-opacity,1))}#chat-widget-root .text-slate-400{--tw-text-opacity:1;color:rgb(148 163 184/var(--tw-text-opacity,1))}#chat-widget-root .text-slate-500{--tw-text-opacity:1;color:rgb(100 116 139/var(--tw-text-opacity,1))}#chat-widget-root .text-status-error{color:hsl(var(--cw-status-error))}#chat-widget-root .text-status-success{color:hsl(var(--cw-status-success))}#chat-widget-root .text-white{--tw-text-opacity:1;color:rgb(255 255 255/var(--tw-text-opacity,1))}#chat-widget-root .text-yellow-400{--tw-text-opacity:1;color:rgb(250 204 21/var(--tw-text-opacity,1))}#chat-widget-root .underline{text-decoration-line:underline}#chat-widget-root .no-underline{text-decoration-line:none}#chat-widget-root .placeholder-gray-400::-moz-placeholder{--tw-placeholder-opacity:1;color:rgb(156 163 175/var(--tw-placeholder-opacity,1))}#chat-widget-root .placeholder-gray-400::placeholder{--tw-placeholder-opacity:1;color:rgb(156 163 175/var(--tw-placeholder-opacity,1))}#chat-widget-root .placeholder-gray-500::-moz-placeholder{--tw-placeholder-opacity:1;color:rgb(107 114 128/var(--tw-placeholder-opacity,1))}#chat-widget-root .placeholder-gray-500::placeholder{--tw-placeholder-opacity:1;color:rgb(107 114 128/var(--tw-placeholder-opacity,1))}#chat-widget-root .opacity-0{opacity:0}#chat-widget-root .opacity-25{opacity:.25}#chat-widget-root .opacity-50{opacity:.5}#chat-widget-root .opacity-60{opacity:.6}#chat-widget-root .opacity-70{opacity:.7}#chat-widget-root .opacity-75{opacity:.75}#chat-widget-root .opacity-80{opacity:.8}#chat-widget-root .shadow{--tw-shadow:0 1px 3px 0 rgba(0,0,0,.1),0 1px 2px -1px rgba(0,0,0,.1);--tw-shadow-colored:0 1px 3px 0 var(--tw-shadow-color),0 1px 2px -1px var(--tw-shadow-color)}#chat-widget-root .shadow,#chat-widget-root .shadow-2xl{box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}#chat-widget-root .shadow-2xl{--tw-shadow:0 25px 50px -12px rgba(0,0,0,.25);--tw-shadow-colored:0 25px 50px -12px var(--tw-shadow-color)}#chat-widget-root .shadow-lg{--tw-shadow:0 10px 15px -3px rgba(0,0,0,.1),0 4px 6px -4px rgba(0,0,0,.1);--tw-shadow-colored:0 10px 15px -3px var(--tw-shadow-color),0 4px 6px -4px var(--tw-shadow-color)}#chat-widget-root .shadow-lg,#chat-widget-root .shadow-md{box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}#chat-widget-root .shadow-md{--tw-shadow:0 4px 6px -1px rgba(0,0,0,.1),0 2px 4px -2px rgba(0,0,0,.1);--tw-shadow-colored:0 4px 6px -1px var(--tw-shadow-color),0 2px 4px -2px var(--tw-shadow-color)}#chat-widget-root .shadow-none{--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000}#chat-widget-root .shadow-none,#chat-widget-root .shadow-sm{box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}#chat-widget-root .shadow-sm{--tw-shadow:0 1px 2px 0 rgba(0,0,0,.05);--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color)}#chat-widget-root .shadow-xl{--tw-shadow:0 20px 25px -5px rgba(0,0,0,.1),0 8px 10px -6px rgba(0,0,0,.1);--tw-shadow-colored:0 20px 25px -5px var(--tw-shadow-color),0 8px 10px -6px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}#chat-widget-root .shadow-black\\/20{--tw-shadow-color:rgba(0,0,0,.2);--tw-shadow:var(--tw-shadow-colored)}#chat-widget-root .shadow-gray-200\\/80{--tw-shadow-color:rgba(229,231,235,.8);--tw-shadow:var(--tw-shadow-colored)}#chat-widget-root .outline-none{outline:2px solid transparent;outline-offset:2px}#chat-widget-root .outline{outline-style:solid}#chat-widget-root .ring{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(3px + var(--tw-ring-offset-width)) var(--tw-ring-color)}#chat-widget-root .ring,#chat-widget-root .ring-2{box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}#chat-widget-root .ring-2{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color)}#chat-widget-root .ring-blue-100{--tw-ring-opacity:1;--tw-ring-color:rgb(219 234 254/var(--tw-ring-opacity,1))}#chat-widget-root .ring-blue-300{--tw-ring-opacity:1;--tw-ring-color:rgb(147 197 253/var(--tw-ring-opacity,1))}#chat-widget-root .ring-white{--tw-ring-opacity:1;--tw-ring-color:rgb(255 255 255/var(--tw-ring-opacity,1))}#chat-widget-root .blur{--tw-blur:blur(8px)}#chat-widget-root .blur,#chat-widget-root .drop-shadow{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}#chat-widget-root .drop-shadow{--tw-drop-shadow:drop-shadow(0 1px 2px rgba(0,0,0,.1)) drop-shadow(0 1px 1px rgba(0,0,0,.06))}#chat-widget-root .drop-shadow-md{--tw-drop-shadow:drop-shadow(0 4px 3px rgba(0,0,0,.07)) drop-shadow(0 2px 2px rgba(0,0,0,.06))}#chat-widget-root .drop-shadow-md,#chat-widget-root .drop-shadow-sm{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}#chat-widget-root .drop-shadow-sm{--tw-drop-shadow:drop-shadow(0 1px 1px rgba(0,0,0,.05))}#chat-widget-root .grayscale-\\[0\\.3\\]{--tw-grayscale:grayscale(0.3)}#chat-widget-root .filter,#chat-widget-root .grayscale-\\[0\\.3\\]{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}#chat-widget-root .backdrop-blur-sm{--tw-backdrop-blur:blur(4px);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia)}#chat-widget-root .transition{transition-duration:.15s;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1)}#chat-widget-root .transition-all{transition-duration:.15s;transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1)}#chat-widget-root .transition-colors{transition-duration:.15s;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1)}#chat-widget-root .transition-opacity{transition-duration:.15s;transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1)}#chat-widget-root .transition-transform{transition-duration:.15s;transition-property:transform;transition-timing-function:cubic-bezier(.4,0,.2,1)}#chat-widget-root .duration-150{transition-duration:.15s}#chat-widget-root .duration-200{transition-duration:.2s}#chat-widget-root .duration-300{transition-duration:.3s}#chat-widget-root .duration-500{transition-duration:.5s}#chat-widget-root :is(#chat-widget-root .animate-in){animation:slideIn .3s ease-out}#chat-widget-root :is(#chat-widget-root .transition-all){transition-duration:.3s;transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1)}#chat-widget-root .\\[font-family\\:inherit\\]{font-family:inherit}#chat-widget-root .placeholder\\:text-\\[\\#8C8C8C\\]::-moz-placeholder{--tw-text-opacity:1;color:rgb(140 140 140/var(--tw-text-opacity,1))}#chat-widget-root .placeholder\\:text-\\[\\#8C8C8C\\]::placeholder{--tw-text-opacity:1;color:rgb(140 140 140/var(--tw-text-opacity,1))}#chat-widget-root .placeholder\\:text-\\[\\#A2A9B2\\]::-moz-placeholder{--tw-text-opacity:1;color:rgb(162 169 178/var(--tw-text-opacity,1))}#chat-widget-root .placeholder\\:text-\\[\\#A2A9B2\\]::placeholder{--tw-text-opacity:1;color:rgb(162 169 178/var(--tw-text-opacity,1))}#chat-widget-root .hover\\:scale-105:hover{--tw-scale-x:1.05;--tw-scale-y:1.05}#chat-widget-root .hover\\:scale-105:hover,#chat-widget-root .hover\\:scale-110:hover{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}#chat-widget-root .hover\\:scale-110:hover{--tw-scale-x:1.1;--tw-scale-y:1.1}#chat-widget-root .hover\\:scale-\\[1\\.02\\]:hover{--tw-scale-x:1.02;--tw-scale-y:1.02;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}#chat-widget-root .hover\\:border-blue-400:hover{--tw-border-opacity:1;border-color:rgb(96 165 250/var(--tw-border-opacity,1))}#chat-widget-root .hover\\:border-blue-600:hover{--tw-border-opacity:1;border-color:rgb(37 99 235/var(--tw-border-opacity,1))}#chat-widget-root .hover\\:bg-blue-50:hover{--tw-bg-opacity:1;background-color:rgb(239 246 255/var(--tw-bg-opacity,1))}#chat-widget-root .hover\\:bg-blue-500\\/20:hover{background-color:rgba(59,130,246,.2)}#chat-widget-root .hover\\:bg-blue-900\\/50:hover{background-color:rgba(30,58,138,.5)}#chat-widget-root .hover\\:bg-gray-100:hover{--tw-bg-opacity:1;background-color:rgb(243 244 246/var(--tw-bg-opacity,1))}#chat-widget-root .hover\\:bg-gray-200:hover{--tw-bg-opacity:1;background-color:rgb(229 231 235/var(--tw-bg-opacity,1))}#chat-widget-root .hover\\:bg-gray-50:hover{--tw-bg-opacity:1;background-color:rgb(249 250 251/var(--tw-bg-opacity,1))}#chat-widget-root .hover\\:bg-gray-600:hover{--tw-bg-opacity:1;background-color:rgb(75 85 99/var(--tw-bg-opacity,1))}#chat-widget-root .hover\\:bg-gray-700:hover{--tw-bg-opacity:1;background-color:rgb(55 65 81/var(--tw-bg-opacity,1))}#chat-widget-root .hover\\:bg-red-600:hover{--tw-bg-opacity:1;background-color:rgb(220 38 38/var(--tw-bg-opacity,1))}#chat-widget-root .hover\\:bg-transparent:hover{background-color:transparent}#chat-widget-root .hover\\:text-blue-500:hover{--tw-text-opacity:1;color:rgb(59 130 246/var(--tw-text-opacity,1))}#chat-widget-root .hover\\:text-gray-200:hover{--tw-text-opacity:1;color:rgb(229 231 235/var(--tw-text-opacity,1))}#chat-widget-root .hover\\:text-gray-300:hover{--tw-text-opacity:1;color:rgb(209 213 219/var(--tw-text-opacity,1))}#chat-widget-root .hover\\:text-gray-600:hover{--tw-text-opacity:1;color:rgb(75 85 99/var(--tw-text-opacity,1))}#chat-widget-root .hover\\:text-gray-700:hover{--tw-text-opacity:1;color:rgb(55 65 81/var(--tw-text-opacity,1))}#chat-widget-root .hover\\:underline:hover{text-decoration-line:underline}#chat-widget-root .hover\\:opacity-80:hover{opacity:.8}#chat-widget-root .hover\\:opacity-90:hover{opacity:.9}#chat-widget-root .hover\\:shadow-md:hover{--tw-shadow:0 4px 6px -1px rgba(0,0,0,.1),0 2px 4px -2px rgba(0,0,0,.1);--tw-shadow-colored:0 4px 6px -1px var(--tw-shadow-color),0 2px 4px -2px var(--tw-shadow-color)}#chat-widget-root .hover\\:shadow-md:hover,#chat-widget-root .hover\\:shadow-xl:hover{box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}#chat-widget-root .hover\\:shadow-xl:hover{--tw-shadow:0 20px 25px -5px rgba(0,0,0,.1),0 8px 10px -6px rgba(0,0,0,.1);--tw-shadow-colored:0 20px 25px -5px var(--tw-shadow-color),0 8px 10px -6px var(--tw-shadow-color)}#chat-widget-root .hover\\:grayscale-0:hover{--tw-grayscale:grayscale(0);filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}#chat-widget-root .focus\\:\\!border-status-error:focus{border-color:hsl(var(--cw-status-error))!important}#chat-widget-root .focus\\:border-\\[\\#5A6069\\]:focus{--tw-border-opacity:1;border-color:rgb(90 96 105/var(--tw-border-opacity,1))}#chat-widget-root .focus\\:border-\\[\\#B0B0B0\\]:focus{--tw-border-opacity:1;border-color:rgb(176 176 176/var(--tw-border-opacity,1))}#chat-widget-root .focus\\:outline-none:focus{outline:2px solid transparent;outline-offset:2px}#chat-widget-root .focus\\:ring-0:focus{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(var(--tw-ring-offset-width)) var(--tw-ring-color)}#chat-widget-root .focus\\:ring-0:focus,#chat-widget-root .focus\\:ring-1:focus{box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}#chat-widget-root .focus\\:ring-1:focus{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color)}#chat-widget-root .focus\\:ring-gray-300:focus{--tw-ring-opacity:1;--tw-ring-color:rgb(209 213 219/var(--tw-ring-opacity,1))}#chat-widget-root .focus\\:ring-gray-600:focus{--tw-ring-opacity:1;--tw-ring-color:rgb(75 85 99/var(--tw-ring-opacity,1))}#chat-widget-root .focus-visible\\:outline-none:focus-visible{outline:2px solid transparent;outline-offset:2px}#chat-widget-root .focus-visible\\:ring-2:focus-visible{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}#chat-widget-root .focus-visible\\:ring-white\\/40:focus-visible{--tw-ring-color:hsla(0,0%,100%,.4)}#chat-widget-root .active\\:scale-95:active{--tw-scale-x:.95;--tw-scale-y:.95}#chat-widget-root .active\\:scale-95:active,#chat-widget-root .active\\:scale-\\[0\\.97\\]:active{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}#chat-widget-root .active\\:scale-\\[0\\.97\\]:active{--tw-scale-x:0.97;--tw-scale-y:0.97}#chat-widget-root .active\\:scale-\\[0\\.98\\]:active{--tw-scale-x:0.98;--tw-scale-y:0.98}#chat-widget-root .active\\:scale-\\[0\\.98\\]:active,#chat-widget-root .active\\:scale-\\[0\\.99\\]:active{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}#chat-widget-root .active\\:scale-\\[0\\.99\\]:active{--tw-scale-x:0.99;--tw-scale-y:0.99}#chat-widget-root .active\\:outline-none:active{outline:2px solid transparent;outline-offset:2px}#chat-widget-root .active\\:ring-0:active{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}#chat-widget-root .disabled\\:cursor-not-allowed:disabled{cursor:not-allowed}#chat-widget-root .disabled\\:opacity-40:disabled{opacity:.4}#chat-widget-root .disabled\\:opacity-50:disabled{opacity:.5}#chat-widget-root .disabled\\:shadow-none:disabled{--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}#chat-widget-root :is(.group:hover .group-hover\\:scale-100){--tw-scale-x:1;--tw-scale-y:1;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}#chat-widget-root :is(.group:hover .group-hover\\:opacity-100){opacity:1}#chat-widget-root .dark\\:text-gray-300:is(.dark *){--tw-text-opacity:1;color:rgb(209 213 219/var(--tw-text-opacity,1))}#chat-widget-root .dark\\:text-gray-400:is(.dark *){--tw-text-opacity:1;color:rgb(156 163 175/var(--tw-text-opacity,1))}#chat-widget-root .rtl\\:rounded-tl-2xl:where([dir=rtl],[dir=rtl] *){border-top-left-radius:1rem}#chat-widget-root .rtl\\:rounded-tr-sm:where([dir=rtl],[dir=rtl] *){border-top-right-radius:.125rem}#chat-widget-root .\\[\\&\\:first-child\\]\\:\\!mt-0:first-child{margin-top:0!important}#chat-widget-root :is(.\\[\\&\\>\\*\\:first-child\\]\\:\\!mt-0>:first-child){margin-top:0!important}#chat-widget-root :is(.\\[\\&\\>\\*\\:last-child\\]\\:\\!mb-0>:last-child){margin-bottom:0!important}\n.chat-widget-root{position:fixed;z-index:999999}.chat-widget-container{color:var(--cw-text-color,inherit);font-family:var(\n --cw-font-family,-apple-system,BlinkMacSystemFont,"Segoe UI","Roboto","Oxygen","Ubuntu","Cantarell","Fira Sans","Droid Sans","Helvetica Neue",sans-serif\n )}#chat-widget-root .chat-messages p{overflow-wrap:anywhere;word-break:break-word}textarea#chat-widget-input::-moz-placeholder{border:none;line-height:48px;outline:none}textarea#chat-widget-input::placeholder{border:none;line-height:48px;outline:none}textarea#chat-widget-input{border:none;line-height:48px;outline:none}@keyframes slideIn{0%{opacity:0;transform:translateY(10px)}to{opacity:1;transform:translateY(0)}}@keyframes bounce{0%,to{transform:translateY(0)}50%{transform:translateY(-5px)}}#chat-widget-root .scrollbar-hide{-ms-overflow-style:none;scrollbar-width:none}#chat-widget-root .scrollbar-hide::-webkit-scrollbar{display:none}#chat-widget-root .slim-scrollbar-x{scrollbar-width:thin}#chat-widget-root .slim-scrollbar-x::-webkit-scrollbar{height:3px!important}#chat-widget-root .slim-scrollbar-x::-webkit-scrollbar-track{background:transparent!important}#chat-widget-root .slim-scrollbar-x::-webkit-scrollbar-thumb{background:#d1d5db!important;border-radius:2px!important}#chat-widget-root .slim-scrollbar-x::-webkit-scrollbar-thumb:hover{background:#9ca3af!important}@media print{.chat-widget-root{display:none!important}}',n.appendChild(i);const s=document.createElement("div");s.id="chat-widget-mount",n.appendChild(s),a.current=t.createRoot(s)},[]),e.useEffect(()=>{var t;null===(t=a.current)||void 0===t||t.render(e.createElement(bn,r))}),e.useEffect(()=>()=>{const e=a.current;a.current=null,queueMicrotask(()=>null==e?void 0:e.unmount())},[]),n.jsx("div",{ref:o,id:"chat-widget-host"})}});
|
|
50
|
+
*/function jH(){if(kH)return EH;kH=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable;return EH=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;if("0123456789"!==Object.getOwnPropertyNames(t).map(function(e){return t[e]}).join(""))return!1;var r={};return"abcdefghijklmnopqrst".split("").forEach(function(e){r[e]=e}),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},r)).join("")}catch(e){return!1}}()?Object.assign:function(r,o){for(var a,i,s=function(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}(r),l=1;l<arguments.length;l++){for(var c in a=Object(arguments[l]))t.call(a,c)&&(s[c]=a[c]);if(e){i=e(a);for(var u=0;u<i.length;u++)n.call(a,i[u])&&(s[i[u]]=a[i[u]])}}return s},EH}function FH(){if(TH)return AH;TH=1;return AH="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"}function BH(){return CH?OH:(CH=1,OH=Function.call.bind(Object.prototype.hasOwnProperty))}if("production"!==process.env.NODE_ENV){var UH=MH();yH.exports=function(){if(RH)return _H;RH=1;var e=MH(),t=jH(),n=FH(),r=BH(),o=function(){if(NH)return IH;NH=1;var e=function(){};if("production"!==process.env.NODE_ENV){var t=FH(),n={},r=BH();e=function(e){var t="Warning: "+e;"undefined"!=typeof console&&console.error(t);try{throw new Error(t)}catch(e){}}}function o(o,a,i,s,l){if("production"!==process.env.NODE_ENV)for(var c in o)if(r(o,c)){var u;try{if("function"!=typeof o[c]){var d=Error((s||"React class")+": "+i+" type `"+c+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof o[c]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw d.name="Invariant Violation",d}u=o[c](a,c,s,i,null,t)}catch(e){u=e}if(!u||u instanceof Error||e((s||"React class")+": type specification of "+i+" `"+c+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof u+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),u instanceof Error&&!(u.message in n)){n[u.message]=!0;var p=l?l():"";e("Failed "+i+" type: "+u.message+(null!=p?p:""))}}}return o.resetWarningCache=function(){"production"!==process.env.NODE_ENV&&(n={})},IH=o}(),a=function(){};function i(){return null}return"production"!==process.env.NODE_ENV&&(a=function(e){var t="Warning: "+e;"undefined"!=typeof console&&console.error(t);try{throw new Error(t)}catch(e){}}),_H=function(s,l){var c="function"==typeof Symbol&&Symbol.iterator,u="<<anonymous>>",d={array:h("array"),bigint:h("bigint"),bool:h("boolean"),func:h("function"),number:h("number"),object:h("object"),string:h("string"),symbol:h("symbol"),any:g(i),arrayOf:function(e){return g(function(t,r,o,a,i){if("function"!=typeof e)return new f("Property `"+i+"` of component `"+o+"` has invalid PropType notation inside arrayOf.");var s=t[r];if(!Array.isArray(s))return new f("Invalid "+a+" `"+i+"` of type `"+y(s)+"` supplied to `"+o+"`, expected an array.");for(var l=0;l<s.length;l++){var c=e(s,l,o,a,i+"["+l+"]",n);if(c instanceof Error)return c}return null})},element:g(function(e,t,n,r,o){var a=e[t];return s(a)?null:new f("Invalid "+r+" `"+o+"` of type `"+y(a)+"` supplied to `"+n+"`, expected a single ReactElement.")}),elementType:g(function(t,n,r,o,a){var i=t[n];return e.isValidElementType(i)?null:new f("Invalid "+o+" `"+a+"` of type `"+y(i)+"` supplied to `"+r+"`, expected a single ReactElement type.")}),instanceOf:function(e){return g(function(t,n,r,o,a){if(!(t[n]instanceof e)){var i=e.name||u;return new f("Invalid "+o+" `"+a+"` of type `"+((s=t[n]).constructor&&s.constructor.name?s.constructor.name:u)+"` supplied to `"+r+"`, expected instance of `"+i+"`.")}var s;return null})},node:g(function(e,t,n,r,o){return b(e[t])?null:new f("Invalid "+r+" `"+o+"` supplied to `"+n+"`, expected a ReactNode.")}),objectOf:function(e){return g(function(t,o,a,i,s){if("function"!=typeof e)return new f("Property `"+s+"` of component `"+a+"` has invalid PropType notation inside objectOf.");var l=t[o],c=y(l);if("object"!==c)return new f("Invalid "+i+" `"+s+"` of type `"+c+"` supplied to `"+a+"`, expected an object.");for(var u in l)if(r(l,u)){var d=e(l,u,a,i,s+"."+u,n);if(d instanceof Error)return d}return null})},oneOf:function(e){return Array.isArray(e)?g(function(t,n,r,o,a){for(var i=t[n],s=0;s<e.length;s++)if(p(i,e[s]))return null;var l=JSON.stringify(e,function(e,t){return"symbol"===v(t)?String(t):t});return new f("Invalid "+o+" `"+a+"` of value `"+String(i)+"` supplied to `"+r+"`, expected one of "+l+".")}):("production"!==process.env.NODE_ENV&&a(arguments.length>1?"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]).":"Invalid argument supplied to oneOf, expected an array."),i)},oneOfType:function(e){if(!Array.isArray(e))return"production"!==process.env.NODE_ENV&&a("Invalid argument supplied to oneOfType, expected an instance of array."),i;for(var t=0;t<e.length;t++){var o=e[t];if("function"!=typeof o)return a("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+w(o)+" at index "+t+"."),i}return g(function(t,o,a,i,s){for(var l=[],c=0;c<e.length;c++){var u=(0,e[c])(t,o,a,i,s,n);if(null==u)return null;u.data&&r(u.data,"expectedType")&&l.push(u.data.expectedType)}return new f("Invalid "+i+" `"+s+"` supplied to `"+a+"`"+(l.length>0?", expected one of type ["+l.join(", ")+"]":"")+".")})},shape:function(e){return g(function(t,r,o,a,i){var s=t[r],l=y(s);if("object"!==l)return new f("Invalid "+a+" `"+i+"` of type `"+l+"` supplied to `"+o+"`, expected `object`.");for(var c in e){var u=e[c];if("function"!=typeof u)return m(o,a,i,c,v(u));var d=u(s,c,o,a,i+"."+c,n);if(d)return d}return null})},exact:function(e){return g(function(o,a,i,s,l){var c=o[a],u=y(c);if("object"!==u)return new f("Invalid "+s+" `"+l+"` of type `"+u+"` supplied to `"+i+"`, expected `object`.");var d=t({},o[a],e);for(var p in d){var g=e[p];if(r(e,p)&&"function"!=typeof g)return m(i,s,l,p,v(g));if(!g)return new f("Invalid "+s+" `"+l+"` key `"+p+"` supplied to `"+i+"`.\nBad object: "+JSON.stringify(o[a],null," ")+"\nValid keys: "+JSON.stringify(Object.keys(e),null," "));var h=g(c,p,i,s,l+"."+p,n);if(h)return h}return null})}};function p(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}function f(e,t){this.message=e,this.data=t&&"object"==typeof t?t:{},this.stack=""}function g(e){if("production"!==process.env.NODE_ENV)var t={},r=0;function o(o,i,s,c,d,p,g){if(c=c||u,p=p||s,g!==n){if(l){var h=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 h.name="Invariant Violation",h}if("production"!==process.env.NODE_ENV&&"undefined"!=typeof console){var m=c+":"+s;!t[m]&&r<3&&(a("You are manually calling a React.PropTypes validation function for the `"+p+"` prop on `"+c+"`. 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."),t[m]=!0,r++)}}return null==i[s]?o?null===i[s]?new f("The "+d+" `"+p+"` is marked as required in `"+c+"`, but its value is `null`."):new f("The "+d+" `"+p+"` is marked as required in `"+c+"`, but its value is `undefined`."):null:e(i,s,c,d,p)}var i=o.bind(null,!1);return i.isRequired=o.bind(null,!0),i}function h(e){return g(function(t,n,r,o,a,i){var s=t[n];return y(s)!==e?new f("Invalid "+o+" `"+a+"` of type `"+v(s)+"` supplied to `"+r+"`, expected `"+e+"`.",{expectedType:e}):null})}function m(e,t,n,r,o){return new f((e||"React class")+": "+t+" type `"+n+"."+r+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+o+"`.")}function b(e){switch(typeof e){case"number":case"string":case"undefined":return!0;case"boolean":return!e;case"object":if(Array.isArray(e))return e.every(b);if(null===e||s(e))return!0;var t=function(e){var t=e&&(c&&e[c]||e["@@iterator"]);if("function"==typeof t)return t}(e);if(!t)return!1;var n,r=t.call(e);if(t!==e.entries){for(;!(n=r.next()).done;)if(!b(n.value))return!1}else for(;!(n=r.next()).done;){var o=n.value;if(o&&!b(o[1]))return!1}return!0;default:return!1}}function y(e){var t=typeof e;return Array.isArray(e)?"array":e instanceof RegExp?"object":function(e,t){return"symbol"===e||!!t&&("Symbol"===t["@@toStringTag"]||"function"==typeof Symbol&&t instanceof Symbol)}(t,e)?"symbol":t}function v(e){if(null==e)return""+e;var t=y(e);if("object"===t){if(e instanceof Date)return"date";if(e instanceof RegExp)return"regexp"}return t}function w(e){var t=v(e);switch(t){case"array":case"object":return"an "+t;case"boolean":case"date":case"regexp":return"a "+t;default:return t}}return f.prototype=Error.prototype,d.checkPropTypes=o,d.resetWarningCache=o.resetWarningCache,d.PropTypes=d,d},_H}()(UH.isElement,!0)}else yH.exports=function(){if(LH)return PH;LH=1;var e=FH();function t(){}function n(){}return n.resetWarningCache=t,PH=function(){function r(t,n,r,o,a,i){if(i!==e){var s=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 s.name="Invariant Violation",s}}function o(){return r}r.isRequired=r;var a={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:o,element:r,elementType:r,instanceOf:o,node:r,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:n,resetWarningCache:t};return a.PropTypes=a,a}}()();var zH=yH.exports;const{getOwnPropertyNames:$H,getOwnPropertySymbols:GH}=Object,{hasOwnProperty:qH}=Object.prototype;function HH(e,t){return function(n,r,o){return e(n,r,o)&&t(n,r,o)}}function VH(e){return function(t,n,r){if(!t||!n||"object"!=typeof t||"object"!=typeof n)return e(t,n,r);const{cache:o}=r,a=o.get(t),i=o.get(n);if(a&&i)return a===n&&i===t;o.set(t,n),o.set(n,t);const s=e(t,n,r);return o.delete(t),o.delete(n),s}}function WH(e){return $H(e).concat(GH(e))}const YH=Object.hasOwn||((e,t)=>qH.call(e,t));function KH(e,t){return e===t||!e&&!t&&e!=e&&t!=t}const{getOwnPropertyDescriptor:XH,keys:ZH}=Object;function QH(e,t){return e.byteLength===t.byteLength&&dV(new Uint8Array(e),new Uint8Array(t))}function JH(e,t,n){let r=e.length;if(t.length!==r)return!1;for(;r-- >0;)if(!n.equals(e[r],t[r],r,r,e,t,n))return!1;return!0}function eV(e,t){return e.byteLength===t.byteLength&&dV(new Uint8Array(e.buffer,e.byteOffset,e.byteLength),new Uint8Array(t.buffer,t.byteOffset,t.byteLength))}function tV(e,t){return KH(e.getTime(),t.getTime())}function nV(e,t){return e.name===t.name&&e.message===t.message&&e.cause===t.cause&&e.stack===t.stack}function rV(e,t){return e===t}function oV(e,t,n){const r=e.size;if(r!==t.size)return!1;if(!r)return!0;const o=new Array(r),a=e.entries();let i,s,l=0;for(;(i=a.next())&&!i.done;){const r=t.entries();let a=!1,c=0;for(;(s=r.next())&&!s.done;){if(o[c]){c++;continue}const r=i.value,u=s.value;if(n.equals(r[0],u[0],l,c,e,t,n)&&n.equals(r[1],u[1],r[0],u[0],e,t,n)){a=o[c]=!0;break}c++}if(!a)return!1;l++}return!0}const aV=KH;function iV(e,t,n){const r=ZH(e);let o=r.length;if(ZH(t).length!==o)return!1;for(;o-- >0;)if(!fV(e,t,n,r[o]))return!1;return!0}function sV(e,t,n){const r=WH(e);let o,a,i,s=r.length;if(WH(t).length!==s)return!1;for(;s-- >0;){if(o=r[s],!fV(e,t,n,o))return!1;if(a=XH(e,o),i=XH(t,o),(a||i)&&(!a||!i||a.configurable!==i.configurable||a.enumerable!==i.enumerable||a.writable!==i.writable))return!1}return!0}function lV(e,t){return KH(e.valueOf(),t.valueOf())}function cV(e,t){return e.source===t.source&&e.flags===t.flags}function uV(e,t,n){const r=e.size;if(r!==t.size)return!1;if(!r)return!0;const o=new Array(r),a=e.values();let i,s;for(;(i=a.next())&&!i.done;){const r=t.values();let a=!1,l=0;for(;(s=r.next())&&!s.done;){if(!o[l]&&n.equals(i.value,s.value,i.value,s.value,e,t,n)){a=o[l]=!0;break}l++}if(!a)return!1}return!0}function dV(e,t){let n=e.byteLength;if(t.byteLength!==n||e.byteOffset!==t.byteOffset)return!1;for(;n-- >0;)if(e[n]!==t[n])return!1;return!0}function pV(e,t){return e.hostname===t.hostname&&e.pathname===t.pathname&&e.protocol===t.protocol&&e.port===t.port&&e.hash===t.hash&&e.username===t.username&&e.password===t.password}function fV(e,t,n,r){return!("_owner"!==r&&"__o"!==r&&"__v"!==r||!e.$$typeof&&!t.$$typeof)||YH(t,r)&&n.equals(e[r],t[r],r,r,e,t,n)}const gV={"[object Int8Array]":!0,"[object Uint8Array]":!0,"[object Uint8ClampedArray]":!0,"[object Int16Array]":!0,"[object Uint16Array]":!0,"[object Int32Array]":!0,"[object Uint32Array]":!0,"[object Float16Array]":!0,"[object Float32Array]":!0,"[object Float64Array]":!0,"[object BigInt64Array]":!0,"[object BigUint64Array]":!0},hV=Object.prototype.toString;function mV({areArrayBuffersEqual:e,areArraysEqual:t,areDataViewsEqual:n,areDatesEqual:r,areErrorsEqual:o,areFunctionsEqual:a,areMapsEqual:i,areNumbersEqual:s,areObjectsEqual:l,arePrimitiveWrappersEqual:c,areRegExpsEqual:u,areSetsEqual:d,areTypedArraysEqual:p,areUrlsEqual:f,unknownTagComparators:g}){return function(h,m,b){if(h===m)return!0;if(null==h||null==m)return!1;const y=typeof h;if(y!==typeof m)return!1;if("object"!==y)return"number"===y?s(h,m,b):"function"===y&&a(h,m,b);const v=h.constructor;if(v!==m.constructor)return!1;if(v===Object)return l(h,m,b);if(Array.isArray(h))return t(h,m,b);if(v===Date)return r(h,m,b);if(v===RegExp)return u(h,m,b);if(v===Map)return i(h,m,b);if(v===Set)return d(h,m,b);const w=hV.call(h);if("[object Date]"===w)return r(h,m,b);if("[object RegExp]"===w)return u(h,m,b);if("[object Map]"===w)return i(h,m,b);if("[object Set]"===w)return d(h,m,b);if("[object Object]"===w)return"function"!=typeof h.then&&"function"!=typeof m.then&&l(h,m,b);if("[object URL]"===w)return f(h,m,b);if("[object Error]"===w)return o(h,m,b);if("[object Arguments]"===w)return l(h,m,b);if(gV[w])return p(h,m,b);if("[object ArrayBuffer]"===w)return e(h,m,b);if("[object DataView]"===w)return n(h,m,b);if("[object Boolean]"===w||"[object Number]"===w||"[object String]"===w)return c(h,m,b);if(g){let e=g[w];if(!e){const t=null!=(S=h)?S[Symbol.toStringTag]:void 0;t&&(e=g[t])}if(e)return e(h,m,b)}var S;return!1}}const bV=yV();function yV(e={}){const{circular:t=!1,createInternalComparator:n,createState:r,strict:o=!1}=e,a=function({circular:e,createCustomConfig:t,strict:n}){let r={areArrayBuffersEqual:QH,areArraysEqual:n?sV:JH,areDataViewsEqual:eV,areDatesEqual:tV,areErrorsEqual:nV,areFunctionsEqual:rV,areMapsEqual:n?HH(oV,sV):oV,areNumbersEqual:aV,areObjectsEqual:n?sV:iV,arePrimitiveWrappersEqual:lV,areRegExpsEqual:cV,areSetsEqual:n?HH(uV,sV):uV,areTypedArraysEqual:n?HH(dV,sV):dV,areUrlsEqual:pV,unknownTagComparators:void 0};if(t&&(r=Object.assign({},r,t(r))),e){const e=VH(r.areArraysEqual),t=VH(r.areMapsEqual),n=VH(r.areObjectsEqual),o=VH(r.areSetsEqual);r=Object.assign({},r,{areArraysEqual:e,areMapsEqual:t,areObjectsEqual:n,areSetsEqual:o})}return r}(e),i=mV(a),s=n?n(i):(l=i,function(e,t,n,r,o,a,i){return l(e,t,i)});var l;return function({circular:e,comparator:t,createState:n,equals:r,strict:o}){if(n)return function(a,i){const{cache:s=(e?new WeakMap:void 0),meta:l}=n();return t(a,i,{cache:s,equals:r,meta:l,strict:o})};if(e)return function(e,n){return t(e,n,{cache:new WeakMap,equals:r,meta:void 0,strict:o})};const a={cache:void 0,equals:r,meta:void 0,strict:o};return function(e,n){return t(e,n,a)}}({circular:t,comparator:i,createState:r,equals:s,strict:o})}function vV(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=-1;requestAnimationFrame(function r(o){n<0&&(n=o),o-n>t?(e(o),n=-1):function(e){"undefined"!=typeof requestAnimationFrame&&requestAnimationFrame(e)}(r)})}function wV(e){return wV="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},wV(e)}function SV(e){return function(e){if(Array.isArray(e))return e}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return xV(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return xV(e,t)}(e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function xV(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function EV(){var e=function(){return null},t=!1,n=function n(r){if(!t){if(Array.isArray(r)){if(!r.length)return;var o=SV(r),a=o[0],i=o.slice(1);return"number"==typeof a?void vV(n.bind(null,i),a):(n(a),void vV(n.bind(null,i)))}"object"===wV(r)&&e(r),"function"==typeof r&&r()}};return{stop:function(){t=!0},start:function(e){t=!1,n(e)},subscribe:function(t){return e=t,function(){e=function(){return null}}}}}function kV(e){return kV="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},kV(e)}function AV(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function TV(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?AV(Object(n),!0).forEach(function(t){OV(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):AV(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function OV(e,t,n){return(t=function(e){var t=function(e,t){if("object"!==kV(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!==kV(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"===kV(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}yV({strict:!0}),yV({circular:!0}),yV({circular:!0,strict:!0}),yV({createInternalComparator:()=>KH}),yV({strict:!0,createInternalComparator:()=>KH}),yV({circular:!0,createInternalComparator:()=>KH}),yV({circular:!0,createInternalComparator:()=>KH,strict:!0});var CV=function(e){return e},IV=function(e,t){return Object.keys(t).reduce(function(n,r){return TV(TV({},n),{},OV({},r,e(r,t[r])))},{})},NV=function(e,t,n){return e.map(function(e){return"".concat(function(e){return e.replace(/([A-Z])/g,function(e){return"-".concat(e.toLowerCase())})}(e)," ").concat(t,"ms ").concat(n)}).join(",")},_V="production"!==process.env.NODE_ENV,RV=function(e,t,n,r,o,a,i,s){if(_V&&"undefined"!=typeof console&&console.warn&&(void 0===t&&console.warn("LogUtils requires an error message argument"),!e))if(void 0===t)console.warn("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var l=[n,r,o,a,i,s],c=0;console.warn(t.replace(/%s/g,function(){return l[c++]}))}};function PV(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,a,i,s=[],l=!0,c=!1;try{if(a=(n=n.call(e)).next,0===t);else for(;!(l=(r=a.call(n)).done)&&(s.push(r.value),s.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(c)throw o}}return s}}(e,t)||DV(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function LV(e){return function(e){if(Array.isArray(e))return MV(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||DV(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function DV(e,t){if(e){if("string"==typeof e)return MV(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?MV(e,t):void 0}}function MV(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var jV=1e-4,FV=function(e,t){return[0,3*e,3*t-6*e,3*e-3*t+1]},BV=function(e,t){return e.map(function(e,n){return e*Math.pow(t,n)}).reduce(function(e,t){return e+t})},UV=function(e,t){return function(n){var r=FV(e,t);return BV(r,n)}},zV=function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=t[0],o=t[1],a=t[2],i=t[3];if(1===t.length)switch(t[0]){case"linear":r=0,o=0,a=1,i=1;break;case"ease":r=.25,o=.1,a=.25,i=1;break;case"ease-in":r=.42,o=0,a=1,i=1;break;case"ease-out":r=.42,o=0,a=.58,i=1;break;case"ease-in-out":r=0,o=0,a=.58,i=1;break;default:var s=t[0].split("(");if("cubic-bezier"===s[0]&&4===s[1].split(")")[0].split(",").length){var l=s[1].split(")")[0].split(",").map(function(e){return parseFloat(e)}),c=PV(l,4);r=c[0],o=c[1],a=c[2],i=c[3]}else RV(!1,"[configBezier]: arguments should be one of oneOf 'linear', 'ease', 'ease-in', 'ease-out', 'ease-in-out','cubic-bezier(x1,y1,x2,y2)', instead received %s",t)}RV([r,a,o,i].every(function(e){return"number"==typeof e&&e>=0&&e<=1}),"[configBezier]: arguments should be x1, y1, x2, y2 of [0, 1] instead received %s",t);var u,d,p=UV(r,a),f=UV(o,i),g=(u=r,d=a,function(e){var t=FV(u,d),n=[].concat(LV(t.map(function(e,t){return e*t}).slice(1)),[0]);return BV(n,e)}),h=function(e){return e>1?1:e<0?0:e},m=function(e){for(var t=e>1?1:e,n=t,r=0;r<8;++r){var o=p(n)-t,a=g(n);if(Math.abs(o-t)<jV||a<jV)return f(n);n=h(n-o/a)}return f(n)};return m.isStepper=!1,m},$V=function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=t[0];if("string"==typeof r)switch(r){case"ease":case"ease-in-out":case"ease-out":case"ease-in":case"linear":return zV(r);case"spring":return function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.stiff,n=void 0===t?100:t,r=e.damping,o=void 0===r?8:r,a=e.dt,i=void 0===a?17:a,s=function(e,t,r){var a=r+(-(e-t)*n-r*o)*i/1e3,s=r*i/1e3+e;return Math.abs(s-t)<jV&&Math.abs(a)<jV?[t,0]:[s,a]};return s.isStepper=!0,s.dt=i,s}();default:if("cubic-bezier"===r.split("(")[0])return zV(r);RV(!1,"[configEasing]: first argument should be one of 'ease', 'ease-in', 'ease-out', 'ease-in-out','cubic-bezier(x1,y1,x2,y2)', 'linear' and 'spring', instead received %s",t)}return"function"==typeof r?r:(RV(!1,"[configEasing]: first argument type should be function or string, instead received %s",t),null)};function GV(e){return GV="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},GV(e)}function qV(e){return function(e){if(Array.isArray(e))return XV(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||KV(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function HV(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function VV(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?HV(Object(n),!0).forEach(function(t){WV(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):HV(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function WV(e,t,n){return(t=function(e){var t=function(e,t){if("object"!==GV(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!==GV(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"===GV(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function YV(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,a,i,s=[],l=!0,c=!1;try{if(a=(n=n.call(e)).next,0===t);else for(;!(l=(r=a.call(n)).done)&&(s.push(r.value),s.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(c)throw o}}return s}}(e,t)||KV(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function KV(e,t){if(e){if("string"==typeof e)return XV(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?XV(e,t):void 0}}function XV(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var ZV=function(e,t,n){return e+(t-e)*n},QV=function(e){return e.from!==e.to},JV=function e(t,n,r){var o=IV(function(e,n){if(QV(n)){var r=YV(t(n.from,n.to,n.velocity),2),o=r[0],a=r[1];return VV(VV({},n),{},{from:o,velocity:a})}return n},n);return r<1?IV(function(e,t){return QV(t)?VV(VV({},t),{},{velocity:ZV(t.velocity,o[e].velocity,r),from:ZV(t.from,o[e].from,r)}):t},n):e(t,o,r-1)},eW=function(e,t,n,r,o){var a,i,s,l,c=(a=e,i=t,[Object.keys(a),Object.keys(i)].reduce(function(e,t){return e.filter(function(e){return t.includes(e)})})),u=c.reduce(function(n,r){return VV(VV({},n),{},WV({},r,[e[r],t[r]]))},{}),d=c.reduce(function(n,r){return VV(VV({},n),{},WV({},r,{from:e[r],velocity:0,to:t[r]}))},{}),p=-1,f=function(){return null};return f=n.isStepper?function(r){s||(s=r);var a=(r-s)/n.dt;d=JV(n,d,a),o(VV(VV(VV({},e),t),IV(function(e,t){return t.from},d))),s=r,Object.values(d).filter(QV).length&&(p=requestAnimationFrame(f))}:function(a){l||(l=a);var i=(a-l)/r,s=IV(function(e,t){return ZV.apply(void 0,qV(t).concat([n(i)]))},u);if(o(VV(VV(VV({},e),t),s)),i<1)p=requestAnimationFrame(f);else{var c=IV(function(e,t){return ZV.apply(void 0,qV(t).concat([n(1)]))},u);o(VV(VV(VV({},e),t),c))}},function(){return requestAnimationFrame(f),function(){cancelAnimationFrame(p)}}};function tW(e){return tW="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},tW(e)}var nW=["children","begin","duration","attributeName","easing","isActive","steps","from","to","canBegin","onAnimationEnd","shouldReAnimate","onAnimationReStart"];function rW(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},a=Object.keys(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function oW(e){return function(e){if(Array.isArray(e))return aW(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return aW(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return aW(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function aW(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function iW(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function sW(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?iW(Object(n),!0).forEach(function(t){lW(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):iW(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function lW(e,t,n){return(t=uW(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function cW(e,t,n){return t&&function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,uW(r.key),r)}}(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function uW(e){var t=function(e,t){if("object"!==tW(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!==tW(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"===tW(t)?t:String(t)}function dW(e,t){return dW=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},dW(e,t)}function pW(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}();return function(){var n,r=hW(e);if(t){var o=hW(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return fW(this,n)}}function fW(e,t){if(t&&("object"===tW(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return gW(e)}function gW(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function hW(e){return hW=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},hW(e)}var mW=function(t){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&dW(e,t)}(r,t);var n=pW(r);function r(e,t){var o;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,r);var a=(o=n.call(this,e,t)).props,i=a.isActive,s=a.attributeName,l=a.from,c=a.to,u=a.steps,d=a.children,p=a.duration;if(o.handleStyleChange=o.handleStyleChange.bind(gW(o)),o.changeStyle=o.changeStyle.bind(gW(o)),!i||p<=0)return o.state={style:{}},"function"==typeof d&&(o.state={style:c}),fW(o);if(u&&u.length)o.state={style:u[0].style};else if(l){if("function"==typeof d)return o.state={style:l},fW(o);o.state={style:s?lW({},s,l):l}}else o.state={style:{}};return o}return cW(r,[{key:"componentDidMount",value:function(){var e=this.props,t=e.isActive,n=e.canBegin;this.mounted=!0,t&&n&&this.runAnimation(this.props)}},{key:"componentDidUpdate",value:function(e){var t=this.props,n=t.isActive,r=t.canBegin,o=t.attributeName,a=t.shouldReAnimate,i=t.to,s=t.from,l=this.state.style;if(r)if(n){if(!(bV(e.to,i)&&e.canBegin&&e.isActive)){var c=!e.canBegin||!e.isActive;this.manager&&this.manager.stop(),this.stopJSAnimation&&this.stopJSAnimation();var u=c||a?s:e.to;if(this.state&&l){var d={style:o?lW({},o,u):u};(o&&l[o]!==u||!o&&l!==u)&&this.setState(d)}this.runAnimation(sW(sW({},this.props),{},{from:u,begin:0}))}}else{var p={style:o?lW({},o,i):i};this.state&&l&&(o&&l[o]!==i||!o&&l!==i)&&this.setState(p)}}},{key:"componentWillUnmount",value:function(){this.mounted=!1;var e=this.props.onAnimationEnd;this.unSubscribe&&this.unSubscribe(),this.manager&&(this.manager.stop(),this.manager=null),this.stopJSAnimation&&this.stopJSAnimation(),e&&e()}},{key:"handleStyleChange",value:function(e){this.changeStyle(e)}},{key:"changeStyle",value:function(e){this.mounted&&this.setState({style:e})}},{key:"runJSAnimation",value:function(e){var t=this,n=e.from,r=e.to,o=e.duration,a=e.easing,i=e.begin,s=e.onAnimationEnd,l=e.onAnimationStart,c=eW(n,r,$V(a),o,this.changeStyle);this.manager.start([l,i,function(){t.stopJSAnimation=c()},o,s])}},{key:"runStepAnimation",value:function(e){var t=this,n=e.steps,r=e.begin,o=e.onAnimationStart,a=n[0],i=a.style,s=a.duration,l=void 0===s?0:s;return this.manager.start([o].concat(oW(n.reduce(function(e,r,o){if(0===o)return e;var a=r.duration,i=r.easing,s=void 0===i?"ease":i,l=r.style,c=r.properties,u=r.onAnimationEnd,d=o>0?n[o-1]:r,p=c||Object.keys(l);if("function"==typeof s||"spring"===s)return[].concat(oW(e),[t.runJSAnimation.bind(t,{from:d.style,to:l,duration:a,easing:s}),a]);var f=NV(p,a,s),g=sW(sW(sW({},d.style),l),{},{transition:f});return[].concat(oW(e),[g,a,u]).filter(CV)},[i,Math.max(l,r)])),[e.onAnimationEnd]))}},{key:"runAnimation",value:function(e){this.manager||(this.manager=EV());var t=e.begin,n=e.duration,r=e.attributeName,o=e.to,a=e.easing,i=e.onAnimationStart,s=e.onAnimationEnd,l=e.steps,c=e.children,u=this.manager;if(this.unSubscribe=u.subscribe(this.handleStyleChange),"function"!=typeof a&&"function"!=typeof c&&"spring"!==a)if(l.length>1)this.runStepAnimation(e);else{var d=r?lW({},r,o):o,p=NV(Object.keys(d),n,a);u.start([i,t,sW(sW({},d),{},{transition:p}),n,s])}else this.runJSAnimation(e)}},{key:"render",value:function(){var t=this.props,n=t.children;t.begin;var r=t.duration;t.attributeName,t.easing;var o=t.isActive;t.steps,t.from,t.to,t.canBegin,t.onAnimationEnd,t.shouldReAnimate,t.onAnimationReStart;var a=rW(t,nW),i=e.Children.count(n),s=this.state.style;if("function"==typeof n)return n(s);if(!o||0===i||r<=0)return n;var l=function(t){var n=t.props,r=n.style,o=void 0===r?{}:r,i=n.className;return e.cloneElement(t,sW(sW({},a),{},{style:sW(sW({},o),s),className:i}))};return 1===i?l(e.Children.only(n)):e.createElement("div",null,e.Children.map(n,function(e){return l(e)}))}}]),r}(e.PureComponent);function bW(e){return bW="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},bW(e)}function yW(){return yW=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},yW.apply(this,arguments)}function vW(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,a,i,s=[],l=!0,c=!1;try{if(a=(n=n.call(e)).next,0===t);else for(;!(l=(r=a.call(n)).done)&&(s.push(r.value),s.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(c)throw o}}return s}}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return wW(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return wW(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function wW(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function SW(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function xW(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?SW(Object(n),!0).forEach(function(t){EW(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):SW(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function EW(e,t,n){var r;return r=function(e,t){if("object"!=bW(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=bW(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(t,"string"),(t="symbol"==bW(r)?r:r+"")in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}mW.displayName="Animate",mW.defaultProps={begin:0,duration:1e3,from:"",to:"",attributeName:"",easing:"ease",isActive:!0,canBegin:!0,steps:[],onAnimationEnd:function(){},onAnimationStart:function(){}},mW.propTypes={from:zH.oneOfType([zH.object,zH.string]),to:zH.oneOfType([zH.object,zH.string]),attributeName:zH.string,duration:zH.number,begin:zH.number,easing:zH.oneOfType([zH.string,zH.func]),steps:zH.arrayOf(zH.shape({duration:zH.number.isRequired,style:zH.object.isRequired,easing:zH.oneOfType([zH.oneOf(["ease","ease-in","ease-out","ease-in-out","linear"]),zH.func]),properties:zH.arrayOf("string"),onAnimationEnd:zH.func})),children:zH.oneOfType([zH.node,zH.func]),isActive:zH.bool,canBegin:zH.bool,onAnimationEnd:zH.func,shouldReAnimate:zH.bool,onAnimationStart:zH.func,onAnimationReStart:zH.func};var kW=function(e,t,n,r,o){var a,i=Math.min(Math.abs(n)/2,Math.abs(r)/2),s=r>=0?1:-1,l=n>=0?1:-1,c=r>=0&&n>=0||r<0&&n<0?1:0;if(i>0&&o instanceof Array){for(var u=[0,0,0,0],d=0;d<4;d++)u[d]=o[d]>i?i:o[d];a="M".concat(e,",").concat(t+s*u[0]),u[0]>0&&(a+="A ".concat(u[0],",").concat(u[0],",0,0,").concat(c,",").concat(e+l*u[0],",").concat(t)),a+="L ".concat(e+n-l*u[1],",").concat(t),u[1]>0&&(a+="A ".concat(u[1],",").concat(u[1],",0,0,").concat(c,",\n ").concat(e+n,",").concat(t+s*u[1])),a+="L ".concat(e+n,",").concat(t+r-s*u[2]),u[2]>0&&(a+="A ".concat(u[2],",").concat(u[2],",0,0,").concat(c,",\n ").concat(e+n-l*u[2],",").concat(t+r)),a+="L ".concat(e+l*u[3],",").concat(t+r),u[3]>0&&(a+="A ".concat(u[3],",").concat(u[3],",0,0,").concat(c,",\n ").concat(e,",").concat(t+r-s*u[3])),a+="Z"}else if(i>0&&o===+o&&o>0){var p=Math.min(i,o);a="M ".concat(e,",").concat(t+s*p,"\n A ").concat(p,",").concat(p,",0,0,").concat(c,",").concat(e+l*p,",").concat(t,"\n L ").concat(e+n-l*p,",").concat(t,"\n A ").concat(p,",").concat(p,",0,0,").concat(c,",").concat(e+n,",").concat(t+s*p,"\n L ").concat(e+n,",").concat(t+r-s*p,"\n A ").concat(p,",").concat(p,",0,0,").concat(c,",").concat(e+n-l*p,",").concat(t+r,"\n L ").concat(e+l*p,",").concat(t+r,"\n A ").concat(p,",").concat(p,",0,0,").concat(c,",").concat(e,",").concat(t+r-s*p," Z")}else a="M ".concat(e,",").concat(t," h ").concat(n," v ").concat(r," h ").concat(-n," Z");return a},AW=function(e,t){if(!e||!t)return!1;var n=e.x,r=e.y,o=t.x,a=t.y,i=t.width,s=t.height;if(Math.abs(i)>0&&Math.abs(s)>0){var l=Math.min(o,o+i),c=Math.max(o,o+i),u=Math.min(a,a+s),d=Math.max(a,a+s);return n>=l&&n<=c&&r>=u&&r<=d}return!1},TW={x:0,y:0,width:0,height:0,radius:0,isAnimationActive:!1,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:"ease"},OW=function(t){var n=xW(xW({},TW),t),r=e.useRef(),o=vW(e.useState(-1),2),a=o[0],i=o[1];e.useEffect(function(){if(r.current&&r.current.getTotalLength)try{var e=r.current.getTotalLength();e&&i(e)}catch(e){}},[]);var s=n.x,l=n.y,c=n.width,u=n.height,d=n.radius,p=n.className,f=n.animationEasing,g=n.animationDuration,h=n.animationBegin,m=n.isAnimationActive,b=n.isUpdateAnimationActive;if(s!==+s||l!==+l||c!==+c||u!==+u||0===c||0===u)return null;var y=hk("recharts-rectangle",p);return b?e.createElement(mW,{canBegin:a>0,from:{width:c,height:u,x:s,y:l},to:{width:c,height:u,x:s,y:l},duration:g,animationEasing:f,isActive:b},function(t){var o=t.width,i=t.height,s=t.x,l=t.y;return e.createElement(mW,{canBegin:a>0,from:"0px ".concat(-1===a?1:a,"px"),to:"".concat(a,"px 0px"),attributeName:"strokeDasharray",begin:h,duration:g,isActive:m,easing:f},e.createElement("path",yW({},FO(n,!0),{className:y,d:kW(s,l,o,i,d),ref:r})))}):e.createElement("path",yW({},FO(n,!0),{className:y,d:kW(s,l,c,u,d)}))},CW=["points","className","baseLinePoints","connectNulls"];function IW(){return IW=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},IW.apply(this,arguments)}function NW(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)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}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function _W(e){return function(e){if(Array.isArray(e))return RW(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return RW(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return RW(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function RW(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var PW=function(e){return e&&e.x===+e.x&&e.y===+e.y},LW=function(e,t){var n=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=[[]];return e.forEach(function(e){PW(e)?t[t.length-1].push(e):t[t.length-1].length>0&&t.push([])}),PW(e[0])&&t[t.length-1].push(e[0]),t[t.length-1].length<=0&&(t=t.slice(0,-1)),t}(e);t&&(n=[n.reduce(function(e,t){return[].concat(_W(e),_W(t))},[])]);var r=n.map(function(e){return e.reduce(function(e,t,n){return"".concat(e).concat(0===n?"M":"L").concat(t.x,",").concat(t.y)},"")}).join("");return 1===n.length?"".concat(r,"Z"):r},DW=function(t){var n=t.points,r=t.className,o=t.baseLinePoints,a=t.connectNulls,i=NW(t,CW);if(!n||!n.length)return null;var s=hk("recharts-polygon",r);if(o&&o.length){var l=i.stroke&&"none"!==i.stroke,c=function(e,t,n){var r=LW(e,n);return"".concat("Z"===r.slice(-1)?r.slice(0,-1):r,"L").concat(LW(t.reverse(),n).slice(1))}(n,o,a);return e.createElement("g",{className:s},e.createElement("path",IW({},FO(i,!0),{fill:"Z"===c.slice(-1)?i.fill:"none",stroke:"none",d:c})),l?e.createElement("path",IW({},FO(i,!0),{fill:"none",d:LW(n,a)})):null,l?e.createElement("path",IW({},FO(i,!0),{fill:"none",d:LW(o,a)})):null)}var u=LW(n,a);return e.createElement("path",IW({},FO(i,!0),{fill:"Z"===u.slice(-1)?i.fill:"none",className:s,d:u}))};function MW(){return MW=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},MW.apply(this,arguments)}var jW=function(e){var t=e.cx,n=e.cy,r=e.r,o=hk("recharts-dot",e.className);return t===+t&&n===+n&&r===+r?i.createElement("circle",MW({},FO(e,!1),xO(e),{className:o,cx:t,cy:n,r:r})):null};function FW(e){return FW="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},FW(e)}var BW=["x","y","top","left","width","height","className"];function UW(){return UW=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},UW.apply(this,arguments)}function zW(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function $W(e,t,n){var r;return r=function(e,t){if("object"!=FW(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=FW(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(t,"string"),(t="symbol"==FW(r)?r:r+"")in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function GW(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)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}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var qW=function(e,t,n,r,o,a){return"M".concat(e,",").concat(o,"v").concat(r,"M").concat(a,",").concat(t,"h").concat(n)},HW=function(t){var n=t.x,r=void 0===n?0:n,o=t.y,a=void 0===o?0:o,i=t.top,s=void 0===i?0:i,l=t.left,c=void 0===l?0:l,u=t.width,d=void 0===u?0:u,p=t.height,f=void 0===p?0:p,g=t.className,h=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?zW(Object(n),!0).forEach(function(t){$W(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):zW(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}({x:r,y:a,top:s,left:c,width:d,height:f},GW(t,BW));return sO(r)&&sO(a)&&sO(d)&&sO(f)&&sO(s)&&sO(c)?e.createElement("path",UW({},FO(h,!0),{className:hk("recharts-cross",g),d:qW(r,a,d,f,s,c)})):null},VW=Hz,WW=Vz,YW=kP;var KW=function(e,t){return e&&e.length?VW(e,YW(t),WW):void 0},XW=Hz,ZW=kP,QW=Zz;var JW=function(e,t){return e&&e.length?XW(e,ZW(t),QW):void 0},eY=["cx","cy","angle","ticks","axisLine"],tY=["ticks","tick","angle","tickFormatter","stroke"];function nY(e){return nY="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},nY(e)}function rY(){return rY=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},rY.apply(this,arguments)}function oY(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function aY(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?oY(Object(n),!0).forEach(function(t){pY(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):oY(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function iY(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)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}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function sY(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,fY(r.key),r)}}function lY(e,t,n){return t=uY(t),function(e,t){if(t&&("object"===nY(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,cY()?Reflect.construct(t,n||[],uY(e).constructor):t.apply(e,n))}function cY(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(cY=function(){return!!e})()}function uY(e){return uY=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},uY(e)}function dY(e,t){return dY=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},dY(e,t)}function pY(e,t,n){return(t=fY(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function fY(e){var t=function(e,t){if("object"!=nY(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=nY(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==nY(t)?t:t+""}var gY=function(t){function n(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n),lY(this,n,arguments)}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&dY(e,t)}(n,t),r=n,o=[{key:"getTickValueCoord",value:function(e){var t=e.coordinate,n=this.props,r=n.angle,o=n.cx,a=n.cy;return wq(o,a,t,r)}},{key:"getTickTextAnchor",value:function(){var e;switch(this.props.orientation){case"left":e="end";break;case"right":e="start";break;default:e="middle"}return e}},{key:"getViewBox",value:function(){var e=this.props,t=e.cx,n=e.cy,r=e.angle,o=e.ticks,a=KW(o,function(e){return e.coordinate||0});return{cx:t,cy:n,startAngle:r,endAngle:r,innerRadius:JW(o,function(e){return e.coordinate||0}).coordinate||0,outerRadius:a.coordinate||0}}},{key:"renderAxisLine",value:function(){var t=this.props,n=t.cx,r=t.cy,o=t.angle,a=t.ticks,i=t.axisLine,s=iY(t,eY),l=a.reduce(function(e,t){return[Math.min(e[0],t.coordinate),Math.max(e[1],t.coordinate)]},[1/0,-1/0]),c=wq(n,r,l[0],o),u=wq(n,r,l[1],o),d=aY(aY(aY({},FO(s,!1)),{},{fill:"none"},FO(i,!1)),{},{x1:c.x,y1:c.y,x2:u.x,y2:u.y});return e.createElement("line",rY({className:"recharts-polar-radius-axis-line"},d))}},{key:"renderTicks",value:function(){var t=this,r=this.props,o=r.ticks,a=r.tick,i=r.angle,s=r.tickFormatter,l=r.stroke,c=iY(r,tY),u=this.getTickTextAnchor(),d=FO(c,!1),p=FO(a,!1),f=o.map(function(r,o){var c=t.getTickValueCoord(r),f=aY(aY(aY(aY({textAnchor:u,transform:"rotate(".concat(90-i,", ").concat(c.x,", ").concat(c.y,")")},d),{},{stroke:"none",fill:l},p),{},{index:o},c),{},{payload:r});return e.createElement(KO,rY({className:hk("recharts-polar-radius-axis-tick",Aq(a)),key:"tick-".concat(r.coordinate)},EO(t.props,r,o)),n.renderTickItem(a,f,s?s(r.value,o):r.value))});return e.createElement(KO,{className:"recharts-polar-radius-axis-ticks"},f)}},{key:"render",value:function(){var t=this.props,n=t.ticks,r=t.axisLine,o=t.tick;return n&&n.length?e.createElement(KO,{className:hk("recharts-polar-radius-axis",this.props.className)},r&&this.renderAxisLine(),o&&this.renderTicks(),Mq.renderCallByParent(this.props,this.getViewBox())):null}}],a=[{key:"renderTickItem",value:function(t,n,r){return e.isValidElement(t)?e.cloneElement(t,n):Vk(t)?t(n):e.createElement(sj,rY({},n,{className:"recharts-polar-radius-axis-tick-value"}),r)}}],o&&sY(r.prototype,o),a&&sY(r,a),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,o,a}(e.PureComponent);function hY(e){return hY="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},hY(e)}function mY(){return mY=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},mY.apply(this,arguments)}function bY(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function yY(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?bY(Object(n),!0).forEach(function(t){kY(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):bY(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function vY(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,AY(r.key),r)}}function wY(e,t,n){return t=xY(t),function(e,t){if(t&&("object"===hY(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,SY()?Reflect.construct(t,n||[],xY(e).constructor):t.apply(e,n))}function SY(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(SY=function(){return!!e})()}function xY(e){return xY=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},xY(e)}function EY(e,t){return EY=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},EY(e,t)}function kY(e,t,n){return(t=AY(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function AY(e){var t=function(e,t){if("object"!=hY(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=hY(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==hY(t)?t:t+""}pY(gY,"displayName","PolarRadiusAxis"),pY(gY,"axisType","radiusAxis"),pY(gY,"defaultProps",{type:"number",radiusAxisId:0,cx:0,cy:0,angle:0,orientation:"right",stroke:"#ccc",axisLine:!0,tick:!0,tickCount:5,allowDataOverflow:!1,scale:"auto",allowDuplicatedCategory:!0});var TY=Math.PI/180,OY=1e-5,CY=function(t){function n(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n),wY(this,n,arguments)}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&EY(e,t)}(n,t),r=n,o=[{key:"getTickLineCoord",value:function(e){var t=this.props,n=t.cx,r=t.cy,o=t.radius,a=t.orientation,i=t.tickSize||8,s=wq(n,r,o,e.coordinate),l=wq(n,r,o+("inner"===a?-1:1)*i,e.coordinate);return{x1:s.x,y1:s.y,x2:l.x,y2:l.y}}},{key:"getTickTextAnchor",value:function(e){var t=this.props.orientation,n=Math.cos(-e.coordinate*TY);return n>OY?"outer"===t?"start":"end":n<-OY?"outer"===t?"end":"start":"middle"}},{key:"renderAxisLine",value:function(){var t=this.props,n=t.cx,r=t.cy,o=t.radius,a=t.axisLine,i=t.axisLineType,s=yY(yY({},FO(this.props,!1)),{},{fill:"none"},FO(a,!1));if("circle"===i)return e.createElement(jW,mY({className:"recharts-polar-angle-axis-line"},s,{cx:n,cy:r,r:o}));var l=this.props.ticks.map(function(e){return wq(n,r,o,e.coordinate)});return e.createElement(DW,mY({className:"recharts-polar-angle-axis-line"},s,{points:l}))}},{key:"renderTicks",value:function(){var t=this,r=this.props,o=r.ticks,a=r.tick,i=r.tickLine,s=r.tickFormatter,l=r.stroke,c=FO(this.props,!1),u=FO(a,!1),d=yY(yY({},c),{},{fill:"none"},FO(i,!1)),p=o.map(function(r,o){var p=t.getTickLineCoord(r),f=yY(yY(yY({textAnchor:t.getTickTextAnchor(r)},c),{},{stroke:"none",fill:l},u),{},{index:o,payload:r,x:p.x2,y:p.y2});return e.createElement(KO,mY({className:hk("recharts-polar-angle-axis-tick",Aq(a)),key:"tick-".concat(r.coordinate)},EO(t.props,r,o)),i&&e.createElement("line",mY({className:"recharts-polar-angle-axis-tick-line"},d,p)),a&&n.renderTickItem(a,f,s?s(r.value,o):r.value))});return e.createElement(KO,{className:"recharts-polar-angle-axis-ticks"},p)}},{key:"render",value:function(){var t=this.props,n=t.ticks,r=t.radius,o=t.axisLine;return r<=0||!n||!n.length?null:e.createElement(KO,{className:hk("recharts-polar-angle-axis",this.props.className)},o&&this.renderAxisLine(),this.renderTicks())}}],a=[{key:"renderTickItem",value:function(t,n,r){return e.isValidElement(t)?e.cloneElement(t,n):Vk(t)?t(n):e.createElement(sj,mY({},n,{className:"recharts-polar-angle-axis-tick-value"}),r)}}],o&&vY(r.prototype,o),a&&vY(r,a),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,o,a}(e.PureComponent);kY(CY,"displayName","PolarAngleAxis"),kY(CY,"axisType","angleAxis"),kY(CY,"defaultProps",{type:"category",angleAxisId:0,scale:"auto",cx:0,cy:0,orientation:"outer",axisLine:!0,tickLine:!0,tickSize:8,tick:!0,hide:!1,allowDuplicatedCategory:!0});var IY=I_(Object.getPrototypeOf,Object),NY=Rk,_Y=IY,RY=Pk,PY=Function.prototype,LY=Object.prototype,DY=PY.toString,MY=LY.hasOwnProperty,jY=DY.call(Object);var FY=function(e){if(!RY(e)||"[object Object]"!=NY(e))return!1;var t=_Y(e);if(null===t)return!0;var n=MY.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&DY.call(n)==jY},BY=Rk,UY=Pk;var zY=function(e){return!0===e||!1===e||UY(e)&&"[object Boolean]"==BY(e)};function $Y(e){return $Y="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},$Y(e)}function GY(){return GY=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},GY.apply(this,arguments)}function qY(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,a,i,s=[],l=!0,c=!1;try{if(a=(n=n.call(e)).next,0===t);else for(;!(l=(r=a.call(n)).done)&&(s.push(r.value),s.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(c)throw o}}return s}}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return HY(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return HY(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function HY(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function VY(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function WY(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?VY(Object(n),!0).forEach(function(t){YY(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):VY(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function YY(e,t,n){var r;return r=function(e,t){if("object"!=$Y(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=$Y(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(t,"string"),(t="symbol"==$Y(r)?r:r+"")in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var KY,XY=function(e,t,n,r,o){var a,i=n-r;return a="M ".concat(e,",").concat(t),a+="L ".concat(e+n,",").concat(t),a+="L ".concat(e+n-i/2,",").concat(t+o),a+="L ".concat(e+n-i/2-r,",").concat(t+o),a+="L ".concat(e,",").concat(t," Z")},ZY={x:0,y:0,upperWidth:0,lowerWidth:0,height:0,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:"ease"},QY=function(t){var n=WY(WY({},ZY),t),r=e.useRef(),o=qY(e.useState(-1),2),a=o[0],i=o[1];e.useEffect(function(){if(r.current&&r.current.getTotalLength)try{var e=r.current.getTotalLength();e&&i(e)}catch(e){}},[]);var s=n.x,l=n.y,c=n.upperWidth,u=n.lowerWidth,d=n.height,p=n.className,f=n.animationEasing,g=n.animationDuration,h=n.animationBegin,m=n.isUpdateAnimationActive;if(s!==+s||l!==+l||c!==+c||u!==+u||d!==+d||0===c&&0===u||0===d)return null;var b=hk("recharts-trapezoid",p);return m?e.createElement(mW,{canBegin:a>0,from:{upperWidth:0,lowerWidth:0,height:d,x:s,y:l},to:{upperWidth:c,lowerWidth:u,height:d,x:s,y:l},duration:g,animationEasing:f,isActive:m},function(t){var o=t.upperWidth,i=t.lowerWidth,s=t.height,l=t.x,c=t.y;return e.createElement(mW,{canBegin:a>0,from:"0px ".concat(-1===a?1:a,"px"),to:"".concat(a,"px 0px"),attributeName:"strokeDasharray",begin:h,duration:g,easing:f},e.createElement("path",GY({},FO(n,!0),{className:b,d:XY(l,c,o,i,s),ref:r})))}):e.createElement("g",null,e.createElement("path",GY({},FO(n,!0),{className:b,d:XY(s,l,c,u,d)})))},JY=["option","shapeType","propTransformer","activeClassName","isActive"];function eK(e){return eK="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},eK(e)}function tK(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)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}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function nK(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function rK(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?nK(Object(n),!0).forEach(function(t){oK(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):nK(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function oK(e,t,n){var r;return r=function(e,t){if("object"!=eK(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=eK(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(t,"string"),(t="symbol"==eK(r)?r:r+"")in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function aK(e,t){return rK(rK({},t),e)}function iK(t){var n=t.shapeType,r=t.elementProps;switch(n){case"rectangle":return e.createElement(OW,r);case"trapezoid":return e.createElement(QY,r);case"sector":return e.createElement(aH,r);case"symbols":if(function(e){return"symbols"===e}(n))return e.createElement(UI,r);break;default:return null}}function sK(t){var n,r=t.option,o=t.shapeType,a=t.propTransformer,i=void 0===a?aK:a,s=t.activeClassName,l=void 0===s?"recharts-active-shape":s,c=t.isActive,u=tK(t,JY);if(e.isValidElement(r))n=e.cloneElement(r,rK(rK({},u),function(t){return e.isValidElement(t)?t.props:t}(r)));else if(Vk(r))n=r(u);else if(FY(r)&&!zY(r)){var d=i(r,u);n=e.createElement(iK,{shapeType:o,elementProps:d})}else{var p=u;n=e.createElement(iK,{shapeType:o,elementProps:p})}return c?e.createElement(KO,{className:l},n):n}function lK(e,t){return null!=t&&"trapezoids"in e.props}function cK(e,t){return null!=t&&"sectors"in e.props}function uK(e,t){return null!=t&&"points"in e.props}function dK(e,t){var n,r,o=e.x===(null==t||null===(n=t.labelViewBox)||void 0===n?void 0:n.x)||e.x===t.x,a=e.y===(null==t||null===(r=t.labelViewBox)||void 0===r?void 0:r.y)||e.y===t.y;return o&&a}function pK(e,t){var n=e.endAngle===t.endAngle,r=e.startAngle===t.startAngle;return n&&r}function fK(e,t){var n=e.x===t.x,r=e.y===t.y,o=e.z===t.z;return n&&r&&o}function gK(e){var t=e.activeTooltipItem,n=e.graphicalItem,r=e.itemData,o=function(e,t){var n;return lK(e,t)?n="trapezoids":cK(e,t)?n="sectors":uK(e,t)&&(n="points"),n}(n,t),a=function(e,t){var n,r;return lK(e,t)?null===(n=t.tooltipPayload)||void 0===n||null===(n=n[0])||void 0===n||null===(n=n.payload)||void 0===n?void 0:n.payload:cK(e,t)?null===(r=t.tooltipPayload)||void 0===r||null===(r=r[0])||void 0===r||null===(r=r.payload)||void 0===r?void 0:r.payload:uK(e,t)?t.payload:{}}(n,t),i=r.filter(function(e,r){var i=d$(a,e),s=n.props[o].filter(function(e){var r=function(e,t){var n;return lK(e,t)?n=dK:cK(e,t)?n=pK:uK(e,t)&&(n=fK),n}(n,t);return r(e,t)}),l=n.props[o].indexOf(s[s.length-1]);return i&&r===l});return r.indexOf(i[i.length-1])}function hK(e){return hK="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},hK(e)}function mK(){return mK=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},mK.apply(this,arguments)}function bK(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function yK(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?bK(Object(n),!0).forEach(function(t){kK(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):bK(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function vK(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,AK(r.key),r)}}function wK(e,t,n){return t=xK(t),function(e,t){if(t&&("object"===hK(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,SK()?Reflect.construct(t,n||[],xK(e).constructor):t.apply(e,n))}function SK(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(SK=function(){return!!e})()}function xK(e){return xK=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},xK(e)}function EK(e,t){return EK=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},EK(e,t)}function kK(e,t,n){return(t=AK(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function AK(e){var t=function(e,t){if("object"!=hK(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=hK(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"==hK(t)?t:t+""}var TK=function(t){function n(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n),kK(t=wK(this,n,[e]),"pieRef",null),kK(t,"sectorRefs",[]),kK(t,"id",uO("recharts-pie-")),kK(t,"handleAnimationEnd",function(){var e=t.props.onAnimationEnd;t.setState({isAnimationFinished:!0}),Vk(e)&&e()}),kK(t,"handleAnimationStart",function(){var e=t.props.onAnimationStart;t.setState({isAnimationFinished:!1}),Vk(e)&&e()}),t.state={isAnimationFinished:!e.isAnimationActive,prevIsAnimationActive:e.isAnimationActive,prevAnimationId:e.animationId,sectorToFocus:0},t}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&EK(e,t)}(n,t),r=n,o=[{key:"isActiveIndex",value:function(e){var t=this.props.activeIndex;return Array.isArray(t)?-1!==t.indexOf(e):e===t}},{key:"hasActiveIndex",value:function(){var e=this.props.activeIndex;return Array.isArray(e)?0!==e.length:e||0===e}},{key:"renderLabels",value:function(t){if(this.props.isAnimationActive&&!this.state.isAnimationFinished)return null;var r=this.props,o=r.label,a=r.labelLine,i=r.dataKey,s=r.valueKey,l=FO(this.props,!1),c=FO(o,!1),u=FO(a,!1),d=o&&o.offsetRadius||20,p=t.map(function(t,r){var p=(t.startAngle+t.endAngle)/2,f=wq(t.cx,t.cy,t.outerRadius+d,p),g=yK(yK(yK(yK({},l),t),{},{stroke:"none"},c),{},{index:r,textAnchor:n.getTextAnchor(f.x,t.cx)},f),h=yK(yK(yK(yK({},l),t),{},{fill:"none",stroke:t.fill},u),{},{index:r,points:[wq(t.cx,t.cy,t.outerRadius,p),f]}),m=i;return GT(i)&>(s)?m="value":GT(i)&&(m=s),e.createElement(KO,{key:"label-".concat(t.startAngle,"-").concat(t.endAngle,"-").concat(t.midAngle,"-").concat(r)},a&&n.renderLabelLineItem(a,h,"line"),n.renderLabelItem(o,g,zG(t,m)))});return e.createElement(KO,{className:"recharts-pie-labels"},p)}},{key:"renderSectorsStatically",value:function(t){var n=this,r=this.props,o=r.activeShape,a=r.blendStroke,i=r.inactiveShape;return t.map(function(r,s){if(0===(null==r?void 0:r.startAngle)&&0===(null==r?void 0:r.endAngle)&&1!==t.length)return null;var l=n.isActiveIndex(s),c=i&&n.hasActiveIndex()?i:null,u=l?o:c,d=yK(yK({},r),{},{stroke:a?r.fill:r.stroke,tabIndex:-1});return e.createElement(KO,mK({ref:function(e){e&&!n.sectorRefs.includes(e)&&n.sectorRefs.push(e)},tabIndex:-1,className:"recharts-pie-sector"},EO(n.props,r,s),{key:"sector-".concat(null==r?void 0:r.startAngle,"-").concat(null==r?void 0:r.endAngle,"-").concat(r.midAngle,"-").concat(s)}),e.createElement(sK,mK({option:u,isActive:l,shapeType:"sector"},d)))})}},{key:"renderSectorsWithAnimation",value:function(){var t=this,n=this.props,r=n.sectors,o=n.isAnimationActive,a=n.animationBegin,i=n.animationDuration,s=n.animationEasing,l=n.animationId,c=this.state,u=c.prevSectors,d=c.prevIsAnimationActive;return e.createElement(mW,{begin:a,duration:i,isActive:o,easing:s,from:{t:0},to:{t:1},key:"pie-".concat(l,"-").concat(d),onAnimationStart:this.handleAnimationStart,onAnimationEnd:this.handleAnimationEnd},function(n){var o=n.t,a=[],i=(r&&r[0]).startAngle;return r.forEach(function(e,t){var n=u&&u[t],r=t>0?$T(e,"paddingAngle",0):0;if(n){var s=fO(n.endAngle-n.startAngle,e.endAngle-e.startAngle),l=yK(yK({},e),{},{startAngle:i+r,endAngle:i+s(o)+r});a.push(l),i=l.endAngle}else{var c=e.endAngle,d=e.startAngle,p=fO(0,c-d)(o),f=yK(yK({},e),{},{startAngle:i+r,endAngle:i+p+r});a.push(f),i=f.endAngle}}),e.createElement(KO,null,t.renderSectorsStatically(a))})}},{key:"attachKeyboardHandlers",value:function(e){var t=this;e.onkeydown=function(e){if(!e.altKey)switch(e.key){case"ArrowLeft":var n=++t.state.sectorToFocus%t.sectorRefs.length;t.sectorRefs[n].focus(),t.setState({sectorToFocus:n});break;case"ArrowRight":var r=--t.state.sectorToFocus<0?t.sectorRefs.length-1:t.state.sectorToFocus%t.sectorRefs.length;t.sectorRefs[r].focus(),t.setState({sectorToFocus:r});break;case"Escape":t.sectorRefs[t.state.sectorToFocus].blur(),t.setState({sectorToFocus:0})}}}},{key:"renderSectors",value:function(){var e=this.props,t=e.sectors,n=e.isAnimationActive,r=this.state.prevSectors;return!(n&&t&&t.length)||r&&d$(r,t)?this.renderSectorsStatically(t):this.renderSectorsWithAnimation()}},{key:"componentDidMount",value:function(){this.pieRef&&this.attachKeyboardHandlers(this.pieRef)}},{key:"render",value:function(){var t=this,n=this.props,r=n.hide,o=n.sectors,a=n.className,i=n.label,s=n.cx,l=n.cy,c=n.innerRadius,u=n.outerRadius,d=n.isAnimationActive,p=this.state.isAnimationFinished;if(r||!o||!o.length||!sO(s)||!sO(l)||!sO(c)||!sO(u))return null;var f=hk("recharts-pie",a);return e.createElement(KO,{tabIndex:this.props.rootTabIndex,className:f,ref:function(e){t.pieRef=e}},this.renderSectors(),i&&this.renderLabels(o),Mq.renderCallByParent(this.props,null,!1),(!d||p)&&Xq.renderCallByParent(this.props,o,!1))}}],a=[{key:"getDerivedStateFromProps",value:function(e,t){return t.prevIsAnimationActive!==e.isAnimationActive?{prevIsAnimationActive:e.isAnimationActive,prevAnimationId:e.animationId,curSectors:e.sectors,prevSectors:[],isAnimationFinished:!0}:e.isAnimationActive&&e.animationId!==t.prevAnimationId?{prevAnimationId:e.animationId,curSectors:e.sectors,prevSectors:t.curSectors,isAnimationFinished:!0}:e.sectors!==t.curSectors?{curSectors:e.sectors,isAnimationFinished:!0}:null}},{key:"getTextAnchor",value:function(e,t){return e>t?"start":e<t?"end":"middle"}},{key:"renderLabelLineItem",value:function(t,n,r){if(e.isValidElement(t))return e.cloneElement(t,n);if(Vk(t))return t(n);var o=hk("recharts-pie-label-line","boolean"!=typeof t?t.className:"");return e.createElement(bH,mK({},n,{key:r,type:"linear",className:o}))}},{key:"renderLabelItem",value:function(t,n,r){if(e.isValidElement(t))return e.cloneElement(t,n);var o=r;if(Vk(t)&&(o=t(n),e.isValidElement(o)))return o;var a=hk("recharts-pie-label-text","boolean"==typeof t||Vk(t)?"":t.className);return e.createElement(sj,mK({},n,{alignmentBaseline:"middle",className:a}),o)}}],o&&vK(r.prototype,o),a&&vK(r,a),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,o,a}(e.PureComponent);KY=TK,kK(TK,"displayName","Pie"),kK(TK,"defaultProps",{stroke:"#fff",fill:"#808080",legendType:"rect",cx:"50%",cy:"50%",startAngle:0,endAngle:360,innerRadius:0,outerRadius:"80%",paddingAngle:0,labelLine:!0,hide:!1,minAngle:0,isAnimationActive:!DD,animationBegin:400,animationDuration:1500,animationEasing:"ease",nameKey:"name",blendStroke:!1,rootTabIndex:0}),kK(TK,"parseDeltaAngle",function(e,t){return aO(t-e)*Math.min(Math.abs(t-e),360)}),kK(TK,"getRealPieData",function(e){var t=e.data,n=e.children,r=FO(e,!1),o=PO(n,kM);return t&&t.length?t.map(function(e,t){return yK(yK(yK({payload:e},r),e),o&&o[t]&&o[t].props)}):o&&o.length?o.map(function(e){return yK(yK({},r),e.props)}):[]}),kK(TK,"parseCoordinateOfPie",function(e,t){var n=t.top,r=t.left,o=t.width,a=t.height,i=Sq(o,a);return{cx:r+dO(e.cx,o,o/2),cy:n+dO(e.cy,a,a/2),innerRadius:dO(e.innerRadius,i,0),outerRadius:dO(e.outerRadius,i,.8*i),maxRadius:e.maxRadius||Math.sqrt(o*o+a*a)/2}}),kK(TK,"getComposedData",function(e){var t=e.item,n=e.offset,r=void 0!==t.type.defaultProps?yK(yK({},t.type.defaultProps),t.props):t.props,o=KY.getRealPieData(r);if(!o||!o.length)return null;var a=r.cornerRadius,i=r.startAngle,s=r.endAngle,l=r.paddingAngle,c=r.dataKey,u=r.nameKey,d=r.valueKey,p=r.tooltipType,f=Math.abs(r.minAngle),g=KY.parseCoordinateOfPie(r,n),h=KY.parseDeltaAngle(i,s),m=Math.abs(h),b=c;GT(c)&>(d)?(ZO(!1,'Use "dataKey" to specify the value of pie,\n the props "valueKey" will be deprecated in 1.1.0'),b="value"):GT(c)&&(ZO(!1,'Use "dataKey" to specify the value of pie,\n the props "valueKey" will be deprecated in 1.1.0'),b=d);var y,v,w=o.filter(function(e){return 0!==zG(e,b,0)}).length,S=m-w*f-(m>=360?w:w-1)*l,x=o.reduce(function(e,t){var n=zG(t,b,0);return e+(sO(n)?n:0)},0);x>0&&(y=o.map(function(e,t){var n,r=zG(e,b,0),o=zG(e,u,t),s=(sO(r)?r:0)/x,c=(n=t?v.endAngle+aO(h)*l*(0!==r?1:0):i)+aO(h)*((0!==r?f:0)+s*S),d=(n+c)/2,m=(g.innerRadius+g.outerRadius)/2,y=[{name:o,value:r,payload:e,dataKey:b,type:p}],w=wq(g.cx,g.cy,m,d);return v=yK(yK(yK({percent:s,cornerRadius:a,name:o,tooltipPayload:y,midAngle:d,middleRadius:m,tooltipPosition:w},e),g),{},{value:zG(e,b),startAngle:n,endAngle:c,payload:e,paddingAngle:aO(h)*l})}));return yK(yK({},g),{},{sectors:y,data:o})});var OK=Math.ceil,CK=Math.max;var IK=function(e,t,n,r){for(var o=-1,a=CK(OK((t-e)/(n||1)),0),i=Array(a);a--;)i[r?a:++o]=e,e+=n;return i},NK=sM,_K=1/0;var RK=function(e){return e?(e=NK(e))===_K||e===-1/0?17976931348623157e292*(e<0?-1:1):e==e?e:0:0===e?e:0},PK=IK,LK=oD,DK=RK;var MK=function(e){return function(t,n,r){return r&&"number"!=typeof r&&LK(t,n,r)&&(n=r=void 0),t=DK(t),void 0===n?(n=t,t=0):n=DK(n),r=void 0===r?t<n?1:-1:DK(r),PK(t,n,r,e)}}();function jK(e){return jK="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},jK(e)}function FK(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function BK(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?FK(Object(n),!0).forEach(function(t){UK(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):FK(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function UK(e,t,n){var r;return r=function(e,t){if("object"!=jK(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=jK(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(t,"string"),(t="symbol"==jK(r)?r:r+"")in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var zK=["Webkit","Moz","O","ms"];function $K(e){return $K="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},$K(e)}function GK(){return GK=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},GK.apply(this,arguments)}function qK(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function HK(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?qK(Object(n),!0).forEach(function(t){ZK(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):qK(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function VK(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,QK(r.key),r)}}function WK(e,t,n){return t=KK(t),function(e,t){if(t&&("object"===$K(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,YK()?Reflect.construct(t,n||[],KK(e).constructor):t.apply(e,n))}function YK(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(YK=function(){return!!e})()}function KK(e){return KK=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},KK(e)}function XK(e,t){return XK=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},XK(e,t)}function ZK(e,t,n){return(t=QK(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function QK(e){var t=function(e,t){if("object"!=$K(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=$K(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"==$K(t)?t:t+""}var JK=function(e){return e.changedTouches&&!!e.changedTouches.length},eX=function(t){function n(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n),ZK(t=WK(this,n,[e]),"handleDrag",function(e){t.leaveTimer&&(clearTimeout(t.leaveTimer),t.leaveTimer=null),t.state.isTravellerMoving?t.handleTravellerMove(e):t.state.isSlideMoving&&t.handleSlideDrag(e)}),ZK(t,"handleTouchMove",function(e){null!=e.changedTouches&&e.changedTouches.length>0&&t.handleDrag(e.changedTouches[0])}),ZK(t,"handleDragEnd",function(){t.setState({isTravellerMoving:!1,isSlideMoving:!1},function(){var e=t.props,n=e.endIndex,r=e.onDragEnd,o=e.startIndex;null==r||r({endIndex:n,startIndex:o})}),t.detachDragEndListener()}),ZK(t,"handleLeaveWrapper",function(){(t.state.isTravellerMoving||t.state.isSlideMoving)&&(t.leaveTimer=window.setTimeout(t.handleDragEnd,t.props.leaveTimeOut))}),ZK(t,"handleEnterSlideOrTraveller",function(){t.setState({isTextActive:!0})}),ZK(t,"handleLeaveSlideOrTraveller",function(){t.setState({isTextActive:!1})}),ZK(t,"handleSlideDragStart",function(e){var n=JK(e)?e.changedTouches[0]:e;t.setState({isTravellerMoving:!1,isSlideMoving:!0,slideMoveStartX:n.pageX}),t.attachDragEndListener()}),t.travellerDragStartHandlers={startX:t.handleTravellerDragStart.bind(t,"startX"),endX:t.handleTravellerDragStart.bind(t,"endX")},t.state={},t}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&XK(e,t)}(n,t),r=n,o=[{key:"componentWillUnmount",value:function(){this.leaveTimer&&(clearTimeout(this.leaveTimer),this.leaveTimer=null),this.detachDragEndListener()}},{key:"getIndex",value:function(e){var t=e.startX,r=e.endX,o=this.state.scaleValues,a=this.props,i=a.gap,s=a.data.length-1,l=Math.min(t,r),c=Math.max(t,r),u=n.getIndexInRange(o,l),d=n.getIndexInRange(o,c);return{startIndex:u-u%i,endIndex:d===s?s:d-d%i}}},{key:"getTextOfTick",value:function(e){var t=this.props,n=t.data,r=t.tickFormatter,o=t.dataKey,a=zG(n[e],o,e);return Vk(r)?r(a,e):a}},{key:"attachDragEndListener",value:function(){window.addEventListener("mouseup",this.handleDragEnd,!0),window.addEventListener("touchend",this.handleDragEnd,!0),window.addEventListener("mousemove",this.handleDrag,!0)}},{key:"detachDragEndListener",value:function(){window.removeEventListener("mouseup",this.handleDragEnd,!0),window.removeEventListener("touchend",this.handleDragEnd,!0),window.removeEventListener("mousemove",this.handleDrag,!0)}},{key:"handleSlideDrag",value:function(e){var t=this.state,n=t.slideMoveStartX,r=t.startX,o=t.endX,a=this.props,i=a.x,s=a.width,l=a.travellerWidth,c=a.startIndex,u=a.endIndex,d=a.onChange,p=e.pageX-n;p>0?p=Math.min(p,i+s-l-o,i+s-l-r):p<0&&(p=Math.max(p,i-r,i-o));var f=this.getIndex({startX:r+p,endX:o+p});f.startIndex===c&&f.endIndex===u||!d||d(f),this.setState({startX:r+p,endX:o+p,slideMoveStartX:e.pageX})}},{key:"handleTravellerDragStart",value:function(e,t){var n=JK(t)?t.changedTouches[0]:t;this.setState({isSlideMoving:!1,isTravellerMoving:!0,movingTravellerId:e,brushMoveStartX:n.pageX}),this.attachDragEndListener()}},{key:"handleTravellerMove",value:function(e){var t=this.state,n=t.brushMoveStartX,r=t.movingTravellerId,o=t.endX,a=t.startX,i=this.state[r],s=this.props,l=s.x,c=s.width,u=s.travellerWidth,d=s.onChange,p=s.gap,f=s.data,g={startX:this.state.startX,endX:this.state.endX},h=e.pageX-n;h>0?h=Math.min(h,l+c-u-i):h<0&&(h=Math.max(h,l-i)),g[r]=i+h;var m=this.getIndex(g),b=m.startIndex,y=m.endIndex;this.setState(ZK(ZK({},r,i+h),"brushMoveStartX",e.pageX),function(){var e;d&&(e=f.length-1,("startX"===r&&(o>a?b%p===0:y%p===0)||o<a&&y===e||"endX"===r&&(o>a?y%p===0:b%p===0)||o>a&&y===e)&&d(m))})}},{key:"handleTravellerMoveKeyboard",value:function(e,t){var n=this,r=this.state,o=r.scaleValues,a=r.startX,i=r.endX,s=this.state[t],l=o.indexOf(s);if(-1!==l){var c=l+e;if(!(-1===c||c>=o.length)){var u=o[c];"startX"===t&&u>=i||"endX"===t&&u<=a||this.setState(ZK({},t,u),function(){n.props.onChange(n.getIndex({startX:n.state.startX,endX:n.state.endX}))})}}}},{key:"renderBackground",value:function(){var t=this.props,n=t.x,r=t.y,o=t.width,a=t.height,i=t.fill,s=t.stroke;return e.createElement("rect",{stroke:s,fill:i,x:n,y:r,width:o,height:a})}},{key:"renderPanorama",value:function(){var t=this.props,n=t.x,r=t.y,o=t.width,a=t.height,i=t.data,s=t.children,l=t.padding,c=e.Children.only(s);return c?e.cloneElement(c,{x:n,y:r,width:o,height:a,margin:l,compact:!0,data:i}):null}},{key:"renderTravellerLayer",value:function(t,r){var o,a,i=this,s=this.props,l=s.y,c=s.travellerWidth,u=s.height,d=s.traveller,p=s.ariaLabel,f=s.data,g=s.startIndex,h=s.endIndex,m=Math.max(t,this.props.x),b=HK(HK({},FO(this.props,!1)),{},{x:m,y:l,width:c,height:u}),y=p||"Min value: ".concat(null===(o=f[g])||void 0===o?void 0:o.name,", Max value: ").concat(null===(a=f[h])||void 0===a?void 0:a.name);return e.createElement(KO,{tabIndex:0,role:"slider","aria-label":y,"aria-valuenow":t,className:"recharts-brush-traveller",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.travellerDragStartHandlers[r],onTouchStart:this.travellerDragStartHandlers[r],onKeyDown:function(e){["ArrowLeft","ArrowRight"].includes(e.key)&&(e.preventDefault(),e.stopPropagation(),i.handleTravellerMoveKeyboard("ArrowRight"===e.key?1:-1,r))},onFocus:function(){i.setState({isTravellerFocused:!0})},onBlur:function(){i.setState({isTravellerFocused:!1})},style:{cursor:"col-resize"}},n.renderTraveller(d,b))}},{key:"renderSlide",value:function(t,n){var r=this.props,o=r.y,a=r.height,i=r.stroke,s=r.travellerWidth,l=Math.min(t,n)+s,c=Math.max(Math.abs(n-t)-s,0);return e.createElement("rect",{className:"recharts-brush-slide",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.handleSlideDragStart,onTouchStart:this.handleSlideDragStart,style:{cursor:"move"},stroke:"none",fill:i,fillOpacity:.2,x:l,y:o,width:c,height:a})}},{key:"renderText",value:function(){var t=this.props,n=t.startIndex,r=t.endIndex,o=t.y,a=t.height,i=t.travellerWidth,s=t.stroke,l=this.state,c=l.startX,u=l.endX,d={pointerEvents:"none",fill:s};return e.createElement(KO,{className:"recharts-brush-texts"},e.createElement(sj,GK({textAnchor:"end",verticalAnchor:"middle",x:Math.min(c,u)-5,y:o+a/2},d),this.getTextOfTick(n)),e.createElement(sj,GK({textAnchor:"start",verticalAnchor:"middle",x:Math.max(c,u)+i+5,y:o+a/2},d),this.getTextOfTick(r)))}},{key:"render",value:function(){var t=this.props,n=t.data,r=t.className,o=t.children,a=t.x,i=t.y,s=t.width,l=t.height,c=t.alwaysShowText,u=this.state,d=u.startX,p=u.endX,f=u.isTextActive,g=u.isSlideMoving,h=u.isTravellerMoving,m=u.isTravellerFocused;if(!n||!n.length||!sO(a)||!sO(i)||!sO(s)||!sO(l)||s<=0||l<=0)return null;var b=hk("recharts-brush",r),y=1===e.Children.count(o),v=function(e,t){var n=e.replace(/(\w)/,function(e){return e.toUpperCase()}),r=zK.reduce(function(e,r){return BK(BK({},e),{},UK({},r+n,t))},{});return r[e]=t,r}("userSelect","none");return e.createElement(KO,{className:b,onMouseLeave:this.handleLeaveWrapper,onTouchMove:this.handleTouchMove,style:v},this.renderBackground(),y&&this.renderPanorama(),this.renderSlide(d,p),this.renderTravellerLayer(d,"startX"),this.renderTravellerLayer(p,"endX"),(f||g||h||m||c)&&this.renderText())}}],a=[{key:"renderDefaultTraveller",value:function(t){var n=t.x,r=t.y,o=t.width,a=t.height,i=t.stroke,s=Math.floor(r+a/2)-1;return e.createElement(e.Fragment,null,e.createElement("rect",{x:n,y:r,width:o,height:a,fill:i,stroke:"none"}),e.createElement("line",{x1:n+1,y1:s,x2:n+o-1,y2:s,fill:"none",stroke:"#fff"}),e.createElement("line",{x1:n+1,y1:s+2,x2:n+o-1,y2:s+2,fill:"none",stroke:"#fff"}))}},{key:"renderTraveller",value:function(t,r){return e.isValidElement(t)?e.cloneElement(t,r):Vk(t)?t(r):n.renderDefaultTraveller(r)}},{key:"getDerivedStateFromProps",value:function(e,t){var n=e.data,r=e.width,o=e.x,a=e.travellerWidth,i=e.updateId,s=e.startIndex,l=e.endIndex;if(n!==t.prevData||i!==t.prevUpdateId)return HK({prevData:n,prevTravellerWidth:a,prevUpdateId:i,prevX:o,prevWidth:r},n&&n.length?function(e){var t=e.data,n=e.startIndex,r=e.endIndex,o=e.x,a=e.width,i=e.travellerWidth;if(!t||!t.length)return{};var s=t.length,l=Mj().domain(MK(0,s)).range([o,o+a-i]),c=l.domain().map(function(e){return l(e)});return{isTextActive:!1,isSlideMoving:!1,isTravellerMoving:!1,isTravellerFocused:!1,startX:l(n),endX:l(r),scale:l,scaleValues:c}}({data:n,width:r,x:o,travellerWidth:a,startIndex:s,endIndex:l}):{scale:null,scaleValues:null});if(t.scale&&(r!==t.prevWidth||o!==t.prevX||a!==t.prevTravellerWidth)){t.scale.range([o,o+r-a]);var c=t.scale.domain().map(function(e){return t.scale(e)});return{prevData:n,prevTravellerWidth:a,prevUpdateId:i,prevX:o,prevWidth:r,startX:t.scale(e.startIndex),endX:t.scale(e.endIndex),scaleValues:c}}return null}},{key:"getIndexInRange",value:function(e,t){for(var n=0,r=e.length-1;r-n>1;){var o=Math.floor((n+r)/2);e[o]>t?r=o:n=o}return t>=e[r]?r:n}}],o&&VK(r.prototype,o),a&&VK(r,a),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,o,a}(e.PureComponent);ZK(eX,"displayName","Brush"),ZK(eX,"defaultProps",{height:40,travellerWidth:5,gap:1,fill:"#fff",stroke:"#666",padding:{top:1,right:1,bottom:1,left:1},leaveTimeOut:1e3,alwaysShowText:!1});var tX=wL;var nX=function(e,t){var n;return tX(e,function(e,r,o){return!(n=t(e,r,o))}),!!n},rX=yN,oX=kP,aX=nX,iX=mk,sX=oD;var lX=function(e,t,n){var r=iX(e)?rX:aX;return n&&sX(e,t,n)&&(t=void 0),r(e,oX(t))},cX=function(e,t){var n=e.alwaysShow,r=e.ifOverflow;return n&&(r="extendDomain"),r===t},uX=GL;var dX=function(e,t,n){"__proto__"==t&&uX?uX(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n},pX=dX,fX=bL,gX=kP;var hX=function(e,t){var n={};return t=gX(t),fX(e,function(e,r,o){pX(n,r,t(e,r,o))}),n};var mX=function(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(!t(e[n],n,e))return!1;return!0},bX=wL;var yX=function(e,t){var n=!0;return bX(e,function(e,r,o){return n=!!t(e,r,o)}),n},vX=mX,wX=yX,SX=kP,xX=mk,EX=oD;var kX=function(e,t,n){var r=xX(e)?vX:wX;return n&&EX(e,t,n)&&(t=void 0),r(e,SX(t))},AX=["x","y"];function TX(e){return TX="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},TX(e)}function OX(){return OX=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},OX.apply(this,arguments)}function CX(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function IX(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?CX(Object(n),!0).forEach(function(t){NX(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):CX(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function NX(e,t,n){var r;return r=function(e,t){if("object"!=TX(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=TX(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(t,"string"),(t="symbol"==TX(r)?r:r+"")in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function _X(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)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}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function RX(e,t){var n=e.x,r=e.y,o=_X(e,AX),a="".concat(n),i=parseInt(a,10),s="".concat(r),l=parseInt(s,10),c="".concat(t.height||o.height),u=parseInt(c,10),d="".concat(t.width||o.width),p=parseInt(d,10);return IX(IX(IX(IX(IX({},t),o),i?{x:i}:{}),l?{y:l}:{}),{},{height:u,width:p,name:t.name,radius:t.radius})}function PX(t){return e.createElement(sK,OX({shapeType:"rectangle",propTransformer:RX,activeClassName:"recharts-active-bar"},t))}var LX,DX=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return function(n,r){if("number"==typeof e)return e;var o=sO(n)||function(e){return GT(e)}(n);return o?e(n,r):(o||("production"!==process.env.NODE_ENV?hG(0,"minPointSize callback function received a value with type of ".concat(TX(n),". Currently only numbers or null/undefined are supported.")):hG()),t)}},MX=["value","background"];function jX(e){return jX="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},jX(e)}function FX(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)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}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function BX(){return BX=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},BX.apply(this,arguments)}function UX(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function zX(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?UX(Object(n),!0).forEach(function(t){WX(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):UX(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function $X(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,YX(r.key),r)}}function GX(e,t,n){return t=HX(t),function(e,t){if(t&&("object"===jX(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,qX()?Reflect.construct(t,n||[],HX(e).constructor):t.apply(e,n))}function qX(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(qX=function(){return!!e})()}function HX(e){return HX=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},HX(e)}function VX(e,t){return VX=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},VX(e,t)}function WX(e,t,n){return(t=YX(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function YX(e){var t=function(e,t){if("object"!=jX(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=jX(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"==jX(t)?t:t+""}var KX=function(t){function n(){var e;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n);for(var t=arguments.length,r=new Array(t),o=0;o<t;o++)r[o]=arguments[o];return WX(e=GX(this,n,[].concat(r)),"state",{isAnimationFinished:!1}),WX(e,"id",uO("recharts-bar-")),WX(e,"handleAnimationEnd",function(){var t=e.props.onAnimationEnd;e.setState({isAnimationFinished:!0}),t&&t()}),WX(e,"handleAnimationStart",function(){var t=e.props.onAnimationStart;e.setState({isAnimationFinished:!1}),t&&t()}),e}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&VX(e,t)}(n,t),r=n,o=[{key:"renderRectanglesStatically",value:function(t){var n=this,r=this.props,o=r.shape,a=r.dataKey,i=r.activeIndex,s=r.activeBar,l=FO(this.props,!1);return t&&t.map(function(t,r){var c=r===i,u=c?s:o,d=zX(zX(zX({},l),t),{},{isActive:c,option:u,index:r,dataKey:a,onAnimationStart:n.handleAnimationStart,onAnimationEnd:n.handleAnimationEnd});return e.createElement(KO,BX({className:"recharts-bar-rectangle"},EO(n.props,t,r),{key:"rectangle-".concat(null==t?void 0:t.x,"-").concat(null==t?void 0:t.y,"-").concat(null==t?void 0:t.value,"-").concat(r)}),e.createElement(PX,d))})}},{key:"renderRectanglesWithAnimation",value:function(){var t=this,n=this.props,r=n.data,o=n.layout,a=n.isAnimationActive,i=n.animationBegin,s=n.animationDuration,l=n.animationEasing,c=n.animationId,u=this.state.prevData;return e.createElement(mW,{begin:i,duration:s,isActive:a,easing:l,from:{t:0},to:{t:1},key:"bar-".concat(c),onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},function(n){var a=n.t,i=r.map(function(e,t){var n=u&&u[t];if(n){var r=fO(n.x,e.x),i=fO(n.y,e.y),s=fO(n.width,e.width),l=fO(n.height,e.height);return zX(zX({},e),{},{x:r(a),y:i(a),width:s(a),height:l(a)})}if("horizontal"===o){var c=fO(0,e.height)(a);return zX(zX({},e),{},{y:e.y+e.height-c,height:c})}var d=fO(0,e.width)(a);return zX(zX({},e),{},{width:d})});return e.createElement(KO,null,t.renderRectanglesStatically(i))})}},{key:"renderRectangles",value:function(){var e=this.props,t=e.data,n=e.isAnimationActive,r=this.state.prevData;return!(n&&t&&t.length)||r&&d$(r,t)?this.renderRectanglesStatically(t):this.renderRectanglesWithAnimation()}},{key:"renderBackground",value:function(){var t=this,n=this.props,r=n.data,o=n.dataKey,a=n.activeIndex,i=FO(this.props.background,!1);return r.map(function(n,r){n.value;var s=n.background,l=FX(n,MX);if(!s)return null;var c=zX(zX(zX(zX(zX({},l),{},{fill:"#eee"},s),i),EO(t.props,n,r)),{},{onAnimationStart:t.handleAnimationStart,onAnimationEnd:t.handleAnimationEnd,dataKey:o,index:r,className:"recharts-bar-background-rectangle"});return e.createElement(PX,BX({key:"background-bar-".concat(r),option:t.props.background,isActive:r===a},c))})}},{key:"renderErrorBar",value:function(t,n){if(this.props.isAnimationActive&&!this.state.isAnimationFinished)return null;var r=this.props,o=r.data,a=r.xAxis,i=r.yAxis,s=r.layout,l=PO(r.children,IG);if(!l)return null;var c="vertical"===s?o[0].height/2:o[0].width/2,u=function(e,t){var n=Array.isArray(e.value)?e.value[1]:e.value;return{x:e.x,y:e.y,value:n,errorVal:zG(e,t)}},d={clipPath:t?"url(#clipPath-".concat(n,")"):null};return e.createElement(KO,d,l.map(function(t){return e.cloneElement(t,{key:"error-bar-".concat(n,"-").concat(t.props.dataKey),data:o,xAxis:a,yAxis:i,layout:s,offset:c,dataPointFormatter:u})}))}},{key:"render",value:function(){var t=this.props,n=t.hide,r=t.data,o=t.className,a=t.xAxis,i=t.yAxis,s=t.left,l=t.top,c=t.width,u=t.height,d=t.isAnimationActive,p=t.background,f=t.id;if(n||!r||!r.length)return null;var g=this.state.isAnimationFinished,h=hk("recharts-bar",o),m=a&&a.allowDataOverflow,b=i&&i.allowDataOverflow,y=m||b,v=GT(f)?this.id:f;return e.createElement(KO,{className:h},m||b?e.createElement("defs",null,e.createElement("clipPath",{id:"clipPath-".concat(v)},e.createElement("rect",{x:m?s:s-c/2,y:b?l:l-u/2,width:m?c:2*c,height:b?u:2*u}))):null,e.createElement(KO,{className:"recharts-bar-rectangles",clipPath:y?"url(#clipPath-".concat(v,")"):null},p?this.renderBackground():null,this.renderRectangles()),this.renderErrorBar(y,v),(!d||g)&&Xq.renderCallByParent(this.props,r))}}],a=[{key:"getDerivedStateFromProps",value:function(e,t){return e.animationId!==t.prevAnimationId?{prevAnimationId:e.animationId,curData:e.data,prevData:t.curData}:e.data!==t.curData?{curData:e.data}:null}}],o&&$X(r.prototype,o),a&&$X(r,a),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,o,a}(e.PureComponent);function XX(e){return XX="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},XX(e)}function ZX(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,tZ(r.key),r)}}function QX(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function JX(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?QX(Object(n),!0).forEach(function(t){eZ(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):QX(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function eZ(e,t,n){return(t=tZ(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function tZ(e){var t=function(e,t){if("object"!=XX(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=XX(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==XX(t)?t:t+""}LX=KX,WX(KX,"displayName","Bar"),WX(KX,"defaultProps",{xAxisId:0,yAxisId:0,legendType:"rect",minPointSize:0,hide:!1,data:[],layout:"vertical",activeBar:!1,isAnimationActive:!DD,animationBegin:0,animationDuration:400,animationEasing:"ease"}),WX(KX,"getComposedData",function(e){var t=e.props,n=e.item,r=e.barPosition,o=e.bandSize,a=e.xAxis,i=e.yAxis,s=e.xAxisTicks,l=e.yAxisTicks,c=e.stackedData,u=e.dataStartIndex,d=e.displayedData,p=e.offset,f=function(e,t){if(!e)return null;for(var n=0,r=e.length;n<r;n++)if(e[n].item===t)return e[n].position;return null}(r,n);if(!f)return null;var g=t.layout,h=n.type.defaultProps,m=void 0!==h?zX(zX({},h),n.props):n.props,b=m.dataKey,y=m.children,v=m.minPointSize,w="horizontal"===g?i:a,S=c?w.scale.domain():null,x=function(e){var t=e.numericAxis,n=t.scale.domain();if("number"===t.type){var r=Math.min(n[0],n[1]),o=Math.max(n[0],n[1]);return r<=0&&o>=0?0:o<0?o:r}return n[0]}({numericAxis:w}),E=PO(y,kM),k=d.map(function(e,t){var r,d,p,h,m,y;c?r=function(e,t){if(!t||2!==t.length||!sO(t[0])||!sO(t[1]))return e;var n=Math.min(t[0],t[1]),r=Math.max(t[0],t[1]),o=[e[0],e[1]];return(!sO(e[0])||e[0]<n)&&(o[0]=n),(!sO(e[1])||e[1]>r)&&(o[1]=r),o[0]>r&&(o[0]=r),o[1]<n&&(o[1]=n),o}(c[u+t],S):(r=zG(e,b),Array.isArray(r)||(r=[x,r]));var w=DX(v,LX.defaultProps.minPointSize)(r[1],t);if("horizontal"===g){var k,A=[i.scale(r[0]),i.scale(r[1])],T=A[0],O=A[1];d=oq({axis:a,ticks:s,bandSize:o,offset:f.offset,entry:e,index:t}),p=null!==(k=null!=O?O:T)&&void 0!==k?k:void 0,h=f.size;var C=T-O;if(m=Number.isNaN(C)?0:C,y={x:d,y:i.y,width:h,height:i.height},Math.abs(w)>0&&Math.abs(m)<Math.abs(w)){var I=aO(m||w)*(Math.abs(w)-Math.abs(m));p-=I,m+=I}}else{var N=[a.scale(r[0]),a.scale(r[1])],_=N[0],R=N[1];if(d=_,p=oq({axis:i,ticks:l,bandSize:o,offset:f.offset,entry:e,index:t}),h=R-_,m=f.size,y={x:a.x,y:p,width:a.width,height:m},Math.abs(w)>0&&Math.abs(h)<Math.abs(w))h+=aO(h||w)*(Math.abs(w)-Math.abs(h))}return zX(zX(zX({},e),{},{x:d,y:p,width:h,height:m,value:c?r:r[1],payload:e,background:y},E&&E[t]&&E[t].props),{},{tooltipPayload:[dq(n,e)],tooltipPosition:{x:d+h/2,y:p+m/2}})});return zX({data:k,layout:g},p)});var nZ=function(e,t,n,r,o){var a=e.width,i=e.height,s=e.layout,l=e.children,c=Object.keys(t),u={left:n.left,leftMirror:n.left,right:a-n.right,rightMirror:a-n.right,top:n.top,topMirror:n.top,bottom:i-n.bottom,bottomMirror:i-n.bottom},d=!!LO(l,KX);return c.reduce(function(a,i){var l,c,p,f,g,h=t[i],m=h.orientation,b=h.domain,y=h.padding,v=void 0===y?{}:y,w=h.mirror,S=h.reversed,x="".concat(m).concat(w?"Mirror":"");if("number"===h.type&&("gap"===h.padding||"no-gap"===h.padding)){var E=b[1]-b[0],k=1/0,A=h.categoricalDomain.sort(hO);if(A.forEach(function(e,t){t>0&&(k=Math.min((e||0)-(A[t-1]||0),k))}),Number.isFinite(k)){var T=k/E,O="vertical"===h.layout?n.height:n.width;if("gap"===h.padding&&(l=T*O/2),"no-gap"===h.padding){var C=dO(e.barCategoryGap,T*O),I=T*O/2;l=I-C-(I-C)/O*C}}}c="xAxis"===r?[n.left+(v.left||0)+(l||0),n.left+n.width-(v.right||0)-(l||0)]:"yAxis"===r?"horizontal"===s?[n.top+n.height-(v.bottom||0),n.top+(v.top||0)]:[n.top+(v.top||0)+(l||0),n.top+n.height-(v.bottom||0)-(l||0)]:h.range,S&&(c=[c[1],c[0]]);var N=ZG(h,o,d),_=N.scale,R=N.realScaleType;_.domain(b).range(c),JG(_);var P=nq(_,JX(JX({},h),{},{realScaleType:R}));"xAxis"===r?(g="top"===m&&!w||"bottom"===m&&w,p=n.left,f=u[x]-g*h.height):"yAxis"===r&&(g="left"===m&&!w||"right"===m&&w,p=u[x]-g*h.width,f=n.top);var L=JX(JX(JX({},h),P),{},{realScaleType:R,x:p,y:f,scale:_,width:"xAxis"===r?n.width:h.width,height:"yAxis"===r?n.height:h.height});return L.bandSize=cq(L,P),h.hide||"xAxis"!==r?h.hide||(u[x]+=(g?-1:1)*L.width):u[x]+=(g?-1:1)*L.height,JX(JX({},a),{},eZ({},i,L))},{})},rZ=function(e,t){var n=e.x,r=e.y,o=t.x,a=t.y;return{x:Math.min(n,o),y:Math.min(r,a),width:Math.abs(o-n),height:Math.abs(a-r)}},oZ=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.scale=t}return t=e,n=[{key:"domain",get:function(){return this.scale.domain}},{key:"range",get:function(){return this.scale.range}},{key:"rangeMin",get:function(){return this.range()[0]}},{key:"rangeMax",get:function(){return this.range()[1]}},{key:"bandwidth",get:function(){return this.scale.bandwidth}},{key:"apply",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.bandAware,r=t.position;if(void 0!==e){if(r)switch(r){case"start":default:return this.scale(e);case"middle":var o=this.bandwidth?this.bandwidth()/2:0;return this.scale(e)+o;case"end":var a=this.bandwidth?this.bandwidth():0;return this.scale(e)+a}if(n){var i=this.bandwidth?this.bandwidth()/2:0;return this.scale(e)+i}return this.scale(e)}}},{key:"isInRange",value:function(e){var t=this.range(),n=t[0],r=t[t.length-1];return n<=r?e>=n&&e<=r:e>=r&&e<=n}}],r=[{key:"create",value:function(t){return new e(t)}}],n&&ZX(t.prototype,n),r&&ZX(t,r),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,n,r}();eZ(oZ,"EPS",1e-4);var aZ=function(e){var t=Object.keys(e).reduce(function(t,n){return JX(JX({},t),{},eZ({},n,oZ.create(e[n])))},{});return JX(JX({},t),{},{apply:function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=n.bandAware,o=n.position;return hX(e,function(e,n){return t[n].apply(e,{bandAware:r,position:o})})},isInRange:function(e){return kX(e,function(e,n){return t[n].isInRange(e)})}})};var iZ=kP,sZ=j_,lZ=z_;var cZ=function(e){return function(t,n,r){var o=Object(t);if(!sZ(t)){var a=iZ(n);t=lZ(t),n=function(e){return a(o[e],e,o)}}var i=e(t,n,r);return i>-1?o[a?t[i]:i]:void 0}},uZ=RK;var dZ=AP,pZ=kP,fZ=function(e){var t=uZ(e),n=t%1;return t==t?n?t-n:t:0},gZ=Math.max;var hZ=function(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var o=null==n?0:fZ(n);return o<0&&(o=gZ(r+o,0)),dZ(e,pZ(t),o)},mZ=cZ(hZ),bZ=mT(function(e){return{x:e.left,y:e.top,width:e.width,height:e.height}},function(e){return["l",e.left,"t",e.top,"w",e.width,"h",e.height].join("")});function yZ(e){return yZ="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},yZ(e)}var vZ=e.createContext(void 0),wZ=e.createContext(void 0),SZ=e.createContext(void 0),xZ=e.createContext({}),EZ=e.createContext(void 0),kZ=e.createContext(0),AZ=e.createContext(0),TZ=function(t){var n=t.state,r=n.xAxisMap,o=n.yAxisMap,a=n.offset,i=t.clipPathId,s=t.children,l=t.width,c=t.height,u=bZ(a);return e.createElement(vZ.Provider,{value:r},e.createElement(wZ.Provider,{value:o},e.createElement(xZ.Provider,{value:a},e.createElement(SZ.Provider,{value:u},e.createElement(EZ.Provider,{value:i},e.createElement(kZ.Provider,{value:c},e.createElement(AZ.Provider,{value:l},s)))))))};function OZ(e){var t=Object.keys(e);return 0===t.length?"There are no available ids.":"Available ids are: ".concat(t,".")}var CZ=function(t){var n=e.useContext(vZ);null==n&&("production"!==process.env.NODE_ENV?hG(0,"Could not find Recharts context; are you sure this is rendered inside a Recharts wrapper component?"):hG());var r=n[t];return null==r&&("production"!==process.env.NODE_ENV?hG(0,'Could not find xAxis by id "'.concat(t,'" [').concat(yZ(t),"]. ").concat(OZ(n))):hG()),r},IZ=function(t){var n=e.useContext(wZ);null==n&&("production"!==process.env.NODE_ENV?hG(0,"Could not find Recharts context; are you sure this is rendered inside a Recharts wrapper component?"):hG());var r=n[t];return null==r&&("production"!==process.env.NODE_ENV?hG(0,'Could not find yAxis by id "'.concat(t,'" [').concat(yZ(t),"]. ").concat(OZ(n))):hG()),r},NZ=function(){return e.useContext(AZ)},_Z=function(){return e.useContext(kZ)};function RZ(e){return RZ="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},RZ(e)}function PZ(e,t,n){return t&&function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,zZ(r.key),r)}}(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function LZ(e,t,n){return t=MZ(t),function(e,t){if(t&&("object"===RZ(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,DZ()?Reflect.construct(t,n||[],MZ(e).constructor):t.apply(e,n))}function DZ(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(DZ=function(){return!!e})()}function MZ(e){return MZ=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},MZ(e)}function jZ(e,t){return jZ=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},jZ(e,t)}function FZ(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function BZ(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?FZ(Object(n),!0).forEach(function(t){UZ(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):FZ(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function UZ(e,t,n){return(t=zZ(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function zZ(e){var t=function(e,t){if("object"!=RZ(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=RZ(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"==RZ(t)?t:t+""}function $Z(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,a,i,s=[],l=!0,c=!1;try{if(a=(n=n.call(e)).next,0===t);else for(;!(l=(r=a.call(n)).done)&&(s.push(r.value),s.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(c)throw o}}return s}}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return GZ(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return GZ(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function GZ(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function qZ(){return qZ=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},qZ.apply(this,arguments)}function HZ(t){var n=t.x,r=t.y,o=t.segment,a=t.xAxisId,i=t.yAxisId,s=t.shape,l=t.className,c=t.alwaysShow,u=e.useContext(EZ),d=CZ(a),p=IZ(i),f=e.useContext(SZ);if(!u||!f)return null;ZO(void 0===c,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.');var g=function(e,t,n,r,o,a,i,s,l){var c=o.x,u=o.y,d=o.width,p=o.height;if(n){var f=l.y,g=e.y.apply(f,{position:a});if(cX(l,"discard")&&!e.y.isInRange(g))return null;var h=[{x:c+d,y:g},{x:c,y:g}];return"left"===s?h.reverse():h}if(t){var m=l.x,b=e.x.apply(m,{position:a});if(cX(l,"discard")&&!e.x.isInRange(b))return null;var y=[{x:b,y:u+p},{x:b,y:u}];return"top"===i?y.reverse():y}if(r){var v=l.segment.map(function(t){return e.apply(t,{position:a})});return cX(l,"discard")&&lX(v,function(t){return!e.isInRange(t)})?null:v}return null}(aZ({x:d.scale,y:p.scale}),lO(n),lO(r),o&&2===o.length,f,t.position,d.orientation,p.orientation,t);if(!g)return null;var h=$Z(g,2),m=h[0],b=m.x,y=m.y,v=h[1],w=v.x,S=v.y,x=BZ(BZ({clipPath:cX(t,"hidden")?"url(#".concat(u,")"):void 0},FO(t,!0)),{},{x1:b,y1:y,x2:w,y2:S});return e.createElement(KO,{className:hk("recharts-reference-line",l)},function(t,n){return e.isValidElement(t)?e.cloneElement(t,n):Vk(t)?t(n):e.createElement("line",qZ({},n,{className:"recharts-reference-line-line"}))}(s,x),Mq.renderCallByParent(t,function(e){var t=e.x1,n=e.y1,r=e.x2,o=e.y2;return rZ({x:t,y:n},{x:r,y:o})}({x1:b,y1:y,x2:w,y2:S})))}var VZ=function(t){function n(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n),LZ(this,n,arguments)}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&jZ(e,t)}(n,t),PZ(n,[{key:"render",value:function(){return e.createElement(HZ,this.props)}}])}(e.Component);function WZ(){return WZ=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},WZ.apply(this,arguments)}function YZ(e){return YZ="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},YZ(e)}function KZ(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function XZ(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?KZ(Object(n),!0).forEach(function(t){nQ(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):KZ(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function ZZ(e,t,n){return t&&function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,rQ(r.key),r)}}(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function QZ(e,t,n){return t=eQ(t),function(e,t){if(t&&("object"===YZ(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,JZ()?Reflect.construct(t,n||[],eQ(e).constructor):t.apply(e,n))}function JZ(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(JZ=function(){return!!e})()}function eQ(e){return eQ=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},eQ(e)}function tQ(e,t){return tQ=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},tQ(e,t)}function nQ(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=function(e,t){if("object"!=YZ(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=YZ(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"==YZ(t)?t:t+""}UZ(VZ,"displayName","ReferenceLine"),UZ(VZ,"defaultProps",{isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,fill:"none",stroke:"#ccc",fillOpacity:1,strokeWidth:1,position:"middle"});var oQ=function(t){function n(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n),QZ(this,n,arguments)}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&tQ(e,t)}(n,t),ZZ(n,[{key:"render",value:function(){var t=this.props,r=t.x,o=t.y,a=t.r,i=t.alwaysShow,s=t.clipPathId,l=lO(r),c=lO(o);if(ZO(void 0===i,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.'),!l||!c)return null;var u=function(e){var t=e.x,n=e.y,r=e.xAxis,o=e.yAxis,a=aZ({x:r.scale,y:o.scale}),i=a.apply({x:t,y:n},{bandAware:!0});return cX(e,"discard")&&!a.isInRange(i)?null:i}(this.props);if(!u)return null;var d=u.x,p=u.y,f=this.props,g=f.shape,h=f.className,m=XZ(XZ({clipPath:cX(this.props,"hidden")?"url(#".concat(s,")"):void 0},FO(this.props,!0)),{},{cx:d,cy:p});return e.createElement(KO,{className:hk("recharts-reference-dot",h)},n.renderDot(g,m),Mq.renderCallByParent(this.props,{x:d-a,y:p-a,width:2*a,height:2*a}))}}])}(e.Component);function aQ(){return aQ=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},aQ.apply(this,arguments)}function iQ(e){return iQ="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},iQ(e)}function sQ(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function lQ(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?sQ(Object(n),!0).forEach(function(t){gQ(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):sQ(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function cQ(e,t,n){return t&&function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,hQ(r.key),r)}}(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function uQ(e,t,n){return t=pQ(t),function(e,t){if(t&&("object"===iQ(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,dQ()?Reflect.construct(t,n||[],pQ(e).constructor):t.apply(e,n))}function dQ(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(dQ=function(){return!!e})()}function pQ(e){return pQ=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},pQ(e)}function fQ(e,t){return fQ=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},fQ(e,t)}function gQ(e,t,n){return(t=hQ(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function hQ(e){var t=function(e,t){if("object"!=iQ(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=iQ(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"==iQ(t)?t:t+""}nQ(oQ,"displayName","ReferenceDot"),nQ(oQ,"defaultProps",{isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,r:10,fill:"#fff",stroke:"#ccc",fillOpacity:1,strokeWidth:1}),nQ(oQ,"renderDot",function(t,n){return e.isValidElement(t)?e.cloneElement(t,n):Vk(t)?t(n):e.createElement(jW,WZ({},n,{cx:n.cx,cy:n.cy,className:"recharts-reference-dot-dot"}))});var mQ=function(t){function n(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n),uQ(this,n,arguments)}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&fQ(e,t)}(n,t),cQ(n,[{key:"render",value:function(){var t=this.props,r=t.x1,o=t.x2,a=t.y1,i=t.y2,s=t.className,l=t.alwaysShow,c=t.clipPathId;ZO(void 0===l,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.');var u=lO(r),d=lO(o),p=lO(a),f=lO(i),g=this.props.shape;if(!(u||d||p||f||g))return null;var h=function(e,t,n,r,o){var a=o.x1,i=o.x2,s=o.y1,l=o.y2,c=o.xAxis,u=o.yAxis;if(!c||!u)return null;var d=aZ({x:c.scale,y:u.scale}),p={x:e?d.x.apply(a,{position:"start"}):d.x.rangeMin,y:n?d.y.apply(s,{position:"start"}):d.y.rangeMin},f={x:t?d.x.apply(i,{position:"end"}):d.x.rangeMax,y:r?d.y.apply(l,{position:"end"}):d.y.rangeMax};return!cX(o,"discard")||d.isInRange(p)&&d.isInRange(f)?rZ(p,f):null}(u,d,p,f,this.props);if(!h&&!g)return null;var m=cX(this.props,"hidden")?"url(#".concat(c,")"):void 0;return e.createElement(KO,{className:hk("recharts-reference-area",s)},n.renderRect(g,lQ(lQ({clipPath:m},FO(this.props,!0)),h)),Mq.renderCallByParent(this.props,h))}}])}(e.Component);function bQ(e,t,n){if(t<1)return[];if(1===t&&void 0===n)return e;for(var r=[],o=0;o<e.length;o+=t)r.push(e[o]);return r}function yQ(e,t,n){return function(e){var t=e.width,n=e.height,r=function(e){return(e%180+180)%180}(arguments.length>1&&void 0!==arguments[1]?arguments[1]:0),o=r*Math.PI/180,a=Math.atan(n/t),i=o>a&&o<Math.PI-a?n/Math.sin(o):t/Math.cos(o);return Math.abs(i)}({width:e.width+t.width,height:e.height+t.height},n)}function vQ(e,t,n,r,o){if(e*t<e*r||e*t>e*o)return!1;var a=n();return e*(t-e*a/2-r)>=0&&e*(t+e*a/2-o)<=0}function wQ(e){return wQ="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},wQ(e)}function SQ(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function xQ(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?SQ(Object(n),!0).forEach(function(t){EQ(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):SQ(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function EQ(e,t,n){var r;return r=function(e,t){if("object"!=wQ(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=wQ(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(t,"string"),(t="symbol"==wQ(r)?r:r+"")in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function kQ(e,t,n){var r=e.tick,o=e.ticks,a=e.viewBox,i=e.minTickGap,s=e.orientation,l=e.interval,c=e.tickFormatter,u=e.unit,d=e.angle;if(!o||!o.length||!r)return[];if(sO(l)||DD)return function(e,t){return bQ(e,t+1)}(o,"number"==typeof l&&sO(l)?l:0);var p=[],f="top"===s||"bottom"===s?"width":"height",g=u&&"width"===f?RM(u,{fontSize:t,letterSpacing:n}):{width:0,height:0},h=function(e,r){var o=Vk(c)?c(e.value,r):e.value;return"width"===f?yQ(RM(o,{fontSize:t,letterSpacing:n}),g,d):RM(o,{fontSize:t,letterSpacing:n})[f]},m=o.length>=2?aO(o[1].coordinate-o[0].coordinate):1,b=function(e,t,n){var r="width"===n,o=e.x,a=e.y,i=e.width,s=e.height;return 1===t?{start:r?o:a,end:r?o+i:a+s}:{start:r?o+i:a+s,end:r?o:a}}(a,m,f);return"equidistantPreserveStart"===l?function(e,t,n,r,o){for(var a,i=(r||[]).slice(),s=t.start,l=t.end,c=0,u=1,d=s,p=function(){var t=null==r?void 0:r[c];if(void 0===t)return{v:bQ(r,u)};var a,i=c,p=function(){return void 0===a&&(a=n(t,i)),a},f=t.coordinate,g=0===c||vQ(e,f,p,d,l);g||(c=0,d=s,u+=1),g&&(d=f+e*(p()/2+o),c+=u)};u<=i.length;)if(a=p())return a.v;return[]}(m,b,h,o,i):(p="preserveStart"===l||"preserveStartEnd"===l?function(e,t,n,r,o,a){var i=(r||[]).slice(),s=i.length,l=t.start,c=t.end;if(a){var u=r[s-1],d=n(u,s-1),p=e*(u.coordinate+e*d/2-c);i[s-1]=u=xQ(xQ({},u),{},{tickCoord:p>0?u.coordinate-p*e:u.coordinate}),vQ(e,u.tickCoord,function(){return d},l,c)&&(c=u.tickCoord-e*(d/2+o),i[s-1]=xQ(xQ({},u),{},{isShow:!0}))}for(var f=a?s-1:s,g=function(t){var r,a=i[t],s=function(){return void 0===r&&(r=n(a,t)),r};if(0===t){var u=e*(a.coordinate-e*s()/2-l);i[t]=a=xQ(xQ({},a),{},{tickCoord:u<0?a.coordinate-u*e:a.coordinate})}else i[t]=a=xQ(xQ({},a),{},{tickCoord:a.coordinate});vQ(e,a.tickCoord,s,l,c)&&(l=a.tickCoord+e*(s()/2+o),i[t]=xQ(xQ({},a),{},{isShow:!0}))},h=0;h<f;h++)g(h);return i}(m,b,h,o,i,"preserveStartEnd"===l):function(e,t,n,r,o){for(var a=(r||[]).slice(),i=a.length,s=t.start,l=t.end,c=function(t){var r,c=a[t],u=function(){return void 0===r&&(r=n(c,t)),r};if(t===i-1){var d=e*(c.coordinate+e*u()/2-l);a[t]=c=xQ(xQ({},c),{},{tickCoord:d>0?c.coordinate-d*e:c.coordinate})}else a[t]=c=xQ(xQ({},c),{},{tickCoord:c.coordinate});vQ(e,c.tickCoord,u,s,l)&&(l=c.tickCoord-e*(u()/2+o),a[t]=xQ(xQ({},c),{},{isShow:!0}))},u=i-1;u>=0;u--)c(u);return a}(m,b,h,o,i),p.filter(function(e){return e.isShow}))}gQ(mQ,"displayName","ReferenceArea"),gQ(mQ,"defaultProps",{isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,r:10,fill:"#ccc",fillOpacity:.5,stroke:"none",strokeWidth:1}),gQ(mQ,"renderRect",function(t,n){return e.isValidElement(t)?e.cloneElement(t,n):Vk(t)?t(n):e.createElement(OW,aQ({},n,{className:"recharts-reference-area-rect"}))});var AQ=["viewBox"],TQ=["viewBox"],OQ=["ticks"];function CQ(e){return CQ="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},CQ(e)}function IQ(){return IQ=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},IQ.apply(this,arguments)}function NQ(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function _Q(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?NQ(Object(n),!0).forEach(function(t){FQ(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):NQ(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function RQ(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)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}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function PQ(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,BQ(r.key),r)}}function LQ(e,t,n){return t=MQ(t),function(e,t){if(t&&("object"===CQ(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,DQ()?Reflect.construct(t,n||[],MQ(e).constructor):t.apply(e,n))}function DQ(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(DQ=function(){return!!e})()}function MQ(e){return MQ=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},MQ(e)}function jQ(e,t){return jQ=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},jQ(e,t)}function FQ(e,t,n){return(t=BQ(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function BQ(e){var t=function(e,t){if("object"!=CQ(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=CQ(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"==CQ(t)?t:t+""}var UQ=function(t){function n(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n),(t=LQ(this,n,[e])).state={fontSize:"",letterSpacing:""},t}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&jQ(e,t)}(n,t),r=n,o=[{key:"shouldComponentUpdate",value:function(e,t){var n=e.viewBox,r=RQ(e,AQ),o=this.props,a=o.viewBox,i=RQ(o,TQ);return!mO(n,a)||!mO(r,i)||!mO(t,this.state)}},{key:"componentDidMount",value:function(){var e=this.layerReference;if(e){var t=e.getElementsByClassName("recharts-cartesian-axis-tick-value")[0];t&&this.setState({fontSize:window.getComputedStyle(t).fontSize,letterSpacing:window.getComputedStyle(t).letterSpacing})}}},{key:"getTickLineCoord",value:function(e){var t,n,r,o,a,i,s=this.props,l=s.x,c=s.y,u=s.width,d=s.height,p=s.orientation,f=s.tickSize,g=s.mirror,h=s.tickMargin,m=g?-1:1,b=e.tickSize||f,y=sO(e.tickCoord)?e.tickCoord:e.coordinate;switch(p){case"top":t=n=e.coordinate,i=(r=(o=c+ +!g*d)-m*b)-m*h,a=y;break;case"left":r=o=e.coordinate,a=(t=(n=l+ +!g*u)-m*b)-m*h,i=y;break;case"right":r=o=e.coordinate,a=(t=(n=l+ +g*u)+m*b)+m*h,i=y;break;default:t=n=e.coordinate,i=(r=(o=c+ +g*d)+m*b)+m*h,a=y}return{line:{x1:t,y1:r,x2:n,y2:o},tick:{x:a,y:i}}}},{key:"getTickTextAnchor",value:function(){var e,t=this.props,n=t.orientation,r=t.mirror;switch(n){case"left":e=r?"start":"end";break;case"right":e=r?"end":"start";break;default:e="middle"}return e}},{key:"getTickVerticalAnchor",value:function(){var e=this.props,t=e.orientation,n=e.mirror,r="end";switch(t){case"left":case"right":r="middle";break;case"top":r=n?"start":"end";break;default:r=n?"end":"start"}return r}},{key:"renderAxisLine",value:function(){var t=this.props,n=t.x,r=t.y,o=t.width,a=t.height,i=t.orientation,s=t.mirror,l=t.axisLine,c=_Q(_Q(_Q({},FO(this.props,!1)),FO(l,!1)),{},{fill:"none"});if("top"===i||"bottom"===i){var u=+("top"===i&&!s||"bottom"===i&&s);c=_Q(_Q({},c),{},{x1:n,y1:r+u*a,x2:n+o,y2:r+u*a})}else{var d=+("left"===i&&!s||"right"===i&&s);c=_Q(_Q({},c),{},{x1:n+d*o,y1:r,x2:n+d*o,y2:r+a})}return e.createElement("line",IQ({},c,{className:hk("recharts-cartesian-axis-line",$T(l,"className"))}))}},{key:"renderTicks",value:function(t,r,o){var a=this,i=this.props,s=i.tickLine,l=i.stroke,c=i.tick,u=i.tickFormatter,d=i.unit,p=kQ(_Q(_Q({},this.props),{},{ticks:t}),r,o),f=this.getTickTextAnchor(),g=this.getTickVerticalAnchor(),h=FO(this.props,!1),m=FO(c,!1),b=_Q(_Q({},h),{},{fill:"none"},FO(s,!1)),y=p.map(function(t,r){var o=a.getTickLineCoord(t),i=o.line,y=o.tick,v=_Q(_Q(_Q(_Q({textAnchor:f,verticalAnchor:g},h),{},{stroke:"none",fill:l},m),y),{},{index:r,payload:t,visibleTicksCount:p.length,tickFormatter:u});return e.createElement(KO,IQ({className:"recharts-cartesian-axis-tick",key:"tick-".concat(t.value,"-").concat(t.coordinate,"-").concat(t.tickCoord)},EO(a.props,t,r)),s&&e.createElement("line",IQ({},b,i,{className:hk("recharts-cartesian-axis-tick-line",$T(s,"className"))})),c&&n.renderTickItem(c,v,"".concat(Vk(u)?u(t.value,r):t.value).concat(d||"")))});return e.createElement("g",{className:"recharts-cartesian-axis-ticks"},y)}},{key:"render",value:function(){var t=this,n=this.props,r=n.axisLine,o=n.width,a=n.height,i=n.ticksGenerator,s=n.className;if(n.hide)return null;var l=this.props,c=l.ticks,u=RQ(l,OQ),d=c;return Vk(i)&&(d=c&&c.length>0?i(this.props):i(u)),o<=0||a<=0||!d||!d.length?null:e.createElement(KO,{className:hk("recharts-cartesian-axis",s),ref:function(e){t.layerReference=e}},r&&this.renderAxisLine(),this.renderTicks(d,this.state.fontSize,this.state.letterSpacing),Mq.renderCallByParent(this.props))}}],a=[{key:"renderTickItem",value:function(t,n,r){var o=hk(n.className,"recharts-cartesian-axis-tick-value");return e.isValidElement(t)?e.cloneElement(t,_Q(_Q({},n),{},{className:o})):Vk(t)?t(_Q(_Q({},n),{},{className:o})):e.createElement(sj,IQ({},n,{className:"recharts-cartesian-axis-tick-value"}),r)}}],o&&PQ(r.prototype,o),a&&PQ(r,a),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,o,a}(e.Component);FQ(UQ,"displayName","CartesianAxis"),FQ(UQ,"defaultProps",{x:0,y:0,width:0,height:0,viewBox:{x:0,y:0,width:0,height:0},orientation:"bottom",ticks:[],stroke:"#666",tickLine:!0,axisLine:!0,tick:!0,mirror:!1,minTickGap:5,tickSize:6,tickMargin:2,interval:"preserveEnd"});var zQ=["x1","y1","x2","y2","key"],$Q=["offset"];function GQ(e){return GQ="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},GQ(e)}function qQ(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function HQ(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?qQ(Object(n),!0).forEach(function(t){VQ(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):qQ(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function VQ(e,t,n){var r;return r=function(e,t){if("object"!=GQ(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=GQ(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(t,"string"),(t="symbol"==GQ(r)?r:r+"")in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function WQ(){return WQ=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},WQ.apply(this,arguments)}function YQ(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)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}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var KQ=function(t){var n=t.fill;if(!n||"none"===n)return null;var r=t.fillOpacity,o=t.x,a=t.y,i=t.width,s=t.height,l=t.ry;return e.createElement("rect",{x:o,y:a,ry:l,width:i,height:s,stroke:"none",fill:n,fillOpacity:r,className:"recharts-cartesian-grid-bg"})};function XQ(t,n){var r;if(e.isValidElement(t))r=e.cloneElement(t,n);else if(Vk(t))r=t(n);else{var o=n.x1,a=n.y1,i=n.x2,s=n.y2,l=n.key,c=YQ(n,zQ),u=FO(c,!1);u.offset;var d=YQ(u,$Q);r=e.createElement("line",WQ({},d,{x1:o,y1:a,x2:i,y2:s,fill:"none",key:l}))}return r}function ZQ(t){var n=t.x,r=t.width,o=t.horizontal,a=void 0===o||o,i=t.horizontalPoints;if(!a||!i||!i.length)return null;var s=i.map(function(e,o){var i=HQ(HQ({},t),{},{x1:n,y1:e,x2:n+r,y2:e,key:"line-".concat(o),index:o});return XQ(a,i)});return e.createElement("g",{className:"recharts-cartesian-grid-horizontal"},s)}function QQ(t){var n=t.y,r=t.height,o=t.vertical,a=void 0===o||o,i=t.verticalPoints;if(!a||!i||!i.length)return null;var s=i.map(function(e,o){var i=HQ(HQ({},t),{},{x1:e,y1:n,x2:e,y2:n+r,key:"line-".concat(o),index:o});return XQ(a,i)});return e.createElement("g",{className:"recharts-cartesian-grid-vertical"},s)}function JQ(t){var n=t.horizontalFill,r=t.fillOpacity,o=t.x,a=t.y,i=t.width,s=t.height,l=t.horizontalPoints,c=t.horizontal;if(!(void 0===c||c)||!n||!n.length)return null;var u=l.map(function(e){return Math.round(e+a-a)}).sort(function(e,t){return e-t});a!==u[0]&&u.unshift(0);var d=u.map(function(t,l){var c=!u[l+1]?a+s-t:u[l+1]-t;if(c<=0)return null;var d=l%n.length;return e.createElement("rect",{key:"react-".concat(l),y:t,x:o,height:c,width:i,stroke:"none",fill:n[d],fillOpacity:r,className:"recharts-cartesian-grid-bg"})});return e.createElement("g",{className:"recharts-cartesian-gridstripes-horizontal"},d)}function eJ(t){var n=t.vertical,r=void 0===n||n,o=t.verticalFill,a=t.fillOpacity,i=t.x,s=t.y,l=t.width,c=t.height,u=t.verticalPoints;if(!r||!o||!o.length)return null;var d=u.map(function(e){return Math.round(e+i-i)}).sort(function(e,t){return e-t});i!==d[0]&&d.unshift(0);var p=d.map(function(t,n){var r=!d[n+1]?i+l-t:d[n+1]-t;if(r<=0)return null;var u=n%o.length;return e.createElement("rect",{key:"react-".concat(n),x:t,y:s,width:r,height:c,stroke:"none",fill:o[u],fillOpacity:a,className:"recharts-cartesian-grid-bg"})});return e.createElement("g",{className:"recharts-cartesian-gridstripes-vertical"},p)}var tJ=function(e,t){var n=e.xAxis,r=e.width,o=e.height,a=e.offset;return WG(kQ(HQ(HQ(HQ({},UQ.defaultProps),n),{},{ticks:YG(n,!0),viewBox:{x:0,y:0,width:r,height:o}})),a.left,a.left+a.width,t)},nJ=function(e,t){var n=e.yAxis,r=e.width,o=e.height,a=e.offset;return WG(kQ(HQ(HQ(HQ({},UQ.defaultProps),n),{},{ticks:YG(n,!0),viewBox:{x:0,y:0,width:r,height:o}})),a.top,a.top+a.height,t)},rJ={horizontal:!0,vertical:!0,stroke:"#ccc",fill:"none",verticalFill:[],horizontalFill:[]};function oJ(t){var n,r,o,a,i,s,l,c,u=NZ(),d=_Z(),p=e.useContext(xZ),f=HQ(HQ({},t),{},{stroke:null!==(n=t.stroke)&&void 0!==n?n:rJ.stroke,fill:null!==(r=t.fill)&&void 0!==r?r:rJ.fill,horizontal:null!==(o=t.horizontal)&&void 0!==o?o:rJ.horizontal,horizontalFill:null!==(a=t.horizontalFill)&&void 0!==a?a:rJ.horizontalFill,vertical:null!==(i=t.vertical)&&void 0!==i?i:rJ.vertical,verticalFill:null!==(s=t.verticalFill)&&void 0!==s?s:rJ.verticalFill,x:sO(t.x)?t.x:p.left,y:sO(t.y)?t.y:p.top,width:sO(t.width)?t.width:p.width,height:sO(t.height)?t.height:p.height}),g=f.x,h=f.y,m=f.width,b=f.height,y=f.syncWithTicks,v=f.horizontalValues,w=f.verticalValues,S=(l=e.useContext(vZ),pO(l)),x=(c=e.useContext(wZ),mZ(c,function(e){return kX(e.domain,Number.isFinite)})||pO(c));if(!sO(m)||m<=0||!sO(b)||b<=0||!sO(g)||g!==+g||!sO(h)||h!==+h)return null;var E=f.verticalCoordinatesGenerator||tJ,k=f.horizontalCoordinatesGenerator||nJ,A=f.horizontalPoints,T=f.verticalPoints;if((!A||!A.length)&&Vk(k)){var O=v&&v.length,C=k({yAxis:x?HQ(HQ({},x),{},{ticks:O?v:x.ticks}):void 0,width:u,height:d,offset:p},!!O||y);ZO(Array.isArray(C),"horizontalCoordinatesGenerator should return Array but instead it returned [".concat(GQ(C),"]")),Array.isArray(C)&&(A=C)}if((!T||!T.length)&&Vk(E)){var I=w&&w.length,N=E({xAxis:S?HQ(HQ({},S),{},{ticks:I?w:S.ticks}):void 0,width:u,height:d,offset:p},!!I||y);ZO(Array.isArray(N),"verticalCoordinatesGenerator should return Array but instead it returned [".concat(GQ(N),"]")),Array.isArray(N)&&(T=N)}return e.createElement("g",{className:"recharts-cartesian-grid"},e.createElement(KQ,{fill:f.fill,fillOpacity:f.fillOpacity,x:f.x,y:f.y,width:f.width,height:f.height,ry:f.ry}),e.createElement(ZQ,WQ({},f,{offset:p,horizontalPoints:A,xAxis:S,yAxis:x})),e.createElement(QQ,WQ({},f,{offset:p,verticalPoints:T,xAxis:S,yAxis:x})),e.createElement(JQ,WQ({},f,{horizontalPoints:A})),e.createElement(eJ,WQ({},f,{verticalPoints:T})))}oJ.displayName="CartesianGrid";var aJ=["type","layout","connectNulls","ref"],iJ=["key"];function sJ(e){return sJ="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},sJ(e)}function lJ(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)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}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function cJ(){return cJ=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},cJ.apply(this,arguments)}function uJ(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function dJ(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?uJ(Object(n),!0).forEach(function(t){vJ(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):uJ(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function pJ(e){return function(e){if(Array.isArray(e))return fJ(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return fJ(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return fJ(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function fJ(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function gJ(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,wJ(r.key),r)}}function hJ(e,t,n){return t=bJ(t),function(e,t){if(t&&("object"===sJ(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,mJ()?Reflect.construct(t,n||[],bJ(e).constructor):t.apply(e,n))}function mJ(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(mJ=function(){return!!e})()}function bJ(e){return bJ=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},bJ(e)}function yJ(e,t){return yJ=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},yJ(e,t)}function vJ(e,t,n){return(t=wJ(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function wJ(e){var t=function(e,t){if("object"!=sJ(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=sJ(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"==sJ(t)?t:t+""}var SJ=function(t){function n(){var e;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n);for(var t=arguments.length,r=new Array(t),o=0;o<t;o++)r[o]=arguments[o];return vJ(e=hJ(this,n,[].concat(r)),"state",{isAnimationFinished:!0,totalLength:0}),vJ(e,"generateSimpleStrokeDasharray",function(e,t){return"".concat(t,"px ").concat(e-t,"px")}),vJ(e,"getStrokeDasharray",function(t,r,o){var a=o.reduce(function(e,t){return e+t});if(!a)return e.generateSimpleStrokeDasharray(r,t);for(var i=Math.floor(t/a),s=t%a,l=r-t,c=[],u=0,d=0;u<o.length;d+=o[u],++u)if(d+o[u]>s){c=[].concat(pJ(o.slice(0,u)),[s-d]);break}var p=c.length%2==0?[0,l]:[l];return[].concat(pJ(n.repeat(o,i)),pJ(c),p).map(function(e){return"".concat(e,"px")}).join(", ")}),vJ(e,"id",uO("recharts-line-")),vJ(e,"pathRef",function(t){e.mainCurve=t}),vJ(e,"handleAnimationEnd",function(){e.setState({isAnimationFinished:!0}),e.props.onAnimationEnd&&e.props.onAnimationEnd()}),vJ(e,"handleAnimationStart",function(){e.setState({isAnimationFinished:!1}),e.props.onAnimationStart&&e.props.onAnimationStart()}),e}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&yJ(e,t)}(n,t),r=n,o=[{key:"componentDidMount",value:function(){if(this.props.isAnimationActive){var e=this.getTotalLength();this.setState({totalLength:e})}}},{key:"componentDidUpdate",value:function(){if(this.props.isAnimationActive){var e=this.getTotalLength();e!==this.state.totalLength&&this.setState({totalLength:e})}}},{key:"getTotalLength",value:function(){var e=this.mainCurve;try{return e&&e.getTotalLength&&e.getTotalLength()||0}catch(e){return 0}}},{key:"renderErrorBar",value:function(t,n){if(this.props.isAnimationActive&&!this.state.isAnimationFinished)return null;var r=this.props,o=r.points,a=r.xAxis,i=r.yAxis,s=r.layout,l=PO(r.children,IG);if(!l)return null;var c=function(e,t){return{x:e.x,y:e.y,value:e.value,errorVal:zG(e.payload,t)}},u={clipPath:t?"url(#clipPath-".concat(n,")"):null};return e.createElement(KO,u,l.map(function(t){return e.cloneElement(t,{key:"bar-".concat(t.props.dataKey),data:o,xAxis:a,yAxis:i,layout:s,dataPointFormatter:c})}))}},{key:"renderDots",value:function(t,r,o){if(this.props.isAnimationActive&&!this.state.isAnimationFinished)return null;var a=this.props,i=a.dot,s=a.points,l=a.dataKey,c=FO(this.props,!1),u=FO(i,!0),d=s.map(function(e,t){var r=dJ(dJ(dJ({key:"dot-".concat(t),r:3},c),u),{},{index:t,cx:e.x,cy:e.y,value:e.value,dataKey:l,payload:e.payload,points:s});return n.renderDotItem(i,r)}),p={clipPath:t?"url(#clipPath-".concat(r?"":"dots-").concat(o,")"):null};return e.createElement(KO,cJ({className:"recharts-line-dots",key:"dots"},p),d)}},{key:"renderCurveStatically",value:function(t,n,r,o){var a=this.props,i=a.type,s=a.layout,l=a.connectNulls;a.ref;var c=lJ(a,aJ),u=dJ(dJ(dJ({},FO(c,!0)),{},{fill:"none",className:"recharts-line-curve",clipPath:n?"url(#clipPath-".concat(r,")"):null,points:t},o),{},{type:i,layout:s,connectNulls:l});return e.createElement(bH,cJ({},u,{pathRef:this.pathRef}))}},{key:"renderCurveWithAnimation",value:function(t,n){var r=this,o=this.props,a=o.points,i=o.strokeDasharray,s=o.isAnimationActive,l=o.animationBegin,c=o.animationDuration,u=o.animationEasing,d=o.animationId,p=o.animateNewValues,f=o.width,g=o.height,h=this.state,m=h.prevPoints,b=h.totalLength;return e.createElement(mW,{begin:l,duration:c,isActive:s,easing:u,from:{t:0},to:{t:1},key:"line-".concat(d),onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},function(e){var o=e.t;if(m){var s=m.length/a.length,l=a.map(function(e,t){var n=Math.floor(t*s);if(m[n]){var r=m[n],a=fO(r.x,e.x),i=fO(r.y,e.y);return dJ(dJ({},e),{},{x:a(o),y:i(o)})}if(p){var l=fO(2*f,e.x),c=fO(g/2,e.y);return dJ(dJ({},e),{},{x:l(o),y:c(o)})}return dJ(dJ({},e),{},{x:e.x,y:e.y})});return r.renderCurveStatically(l,t,n)}var c,u=fO(0,b)(o);if(i){var d="".concat(i).split(/[,\s]+/gim).map(function(e){return parseFloat(e)});c=r.getStrokeDasharray(u,b,d)}else c=r.generateSimpleStrokeDasharray(b,u);return r.renderCurveStatically(a,t,n,{strokeDasharray:c})})}},{key:"renderCurve",value:function(e,t){var n=this.props,r=n.points,o=n.isAnimationActive,a=this.state,i=a.prevPoints,s=a.totalLength;return o&&r&&r.length&&(!i&&s>0||!d$(i,r))?this.renderCurveWithAnimation(e,t):this.renderCurveStatically(r,e,t)}},{key:"render",value:function(){var t,n=this.props,r=n.hide,o=n.dot,a=n.points,i=n.className,s=n.xAxis,l=n.yAxis,c=n.top,u=n.left,d=n.width,p=n.height,f=n.isAnimationActive,g=n.id;if(r||!a||!a.length)return null;var h=this.state.isAnimationFinished,m=1===a.length,b=hk("recharts-line",i),y=s&&s.allowDataOverflow,v=l&&l.allowDataOverflow,w=y||v,S=GT(g)?this.id:g,x=null!==(t=FO(o,!1))&&void 0!==t?t:{r:3,strokeWidth:2},E=x.r,k=void 0===E?3:E,A=x.strokeWidth,T=void 0===A?2:A,O=(jO(o)?o:{}).clipDot,C=void 0===O||O,I=2*k+T;return e.createElement(KO,{className:b},y||v?e.createElement("defs",null,e.createElement("clipPath",{id:"clipPath-".concat(S)},e.createElement("rect",{x:y?u:u-d/2,y:v?c:c-p/2,width:y?d:2*d,height:v?p:2*p})),!C&&e.createElement("clipPath",{id:"clipPath-dots-".concat(S)},e.createElement("rect",{x:u-I/2,y:c-I/2,width:d+I,height:p+I}))):null,!m&&this.renderCurve(w,S),this.renderErrorBar(w,S),(m||o)&&this.renderDots(w,C,S),(!f||h)&&Xq.renderCallByParent(this.props,a))}}],a=[{key:"getDerivedStateFromProps",value:function(e,t){return e.animationId!==t.prevAnimationId?{prevAnimationId:e.animationId,curPoints:e.points,prevPoints:t.curPoints}:e.points!==t.curPoints?{curPoints:e.points}:null}},{key:"repeat",value:function(e,t){for(var n=e.length%2!=0?[].concat(pJ(e),[0]):e,r=[],o=0;o<t;++o)r=[].concat(pJ(r),pJ(n));return r}},{key:"renderDotItem",value:function(t,n){var r;if(e.isValidElement(t))r=e.cloneElement(t,n);else if(Vk(t))r=t(n);else{var o=n.key,a=lJ(n,iJ),i=hk("recharts-line-dot","boolean"!=typeof t?t.className:"");r=e.createElement(jW,cJ({key:o},a,{className:i}))}return r}}],o&&gJ(r.prototype,o),a&&gJ(r,a),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,o,a}(e.PureComponent);vJ(SJ,"displayName","Line"),vJ(SJ,"defaultProps",{xAxisId:0,yAxisId:0,connectNulls:!1,activeDot:!0,dot:!0,legendType:"line",stroke:"#3182bd",strokeWidth:1,fill:"#fff",points:[],isAnimationActive:!DD,animateNewValues:!0,animationBegin:0,animationDuration:1500,animationEasing:"ease",hide:!1,label:!1}),vJ(SJ,"getComposedData",function(e){var t=e.props,n=e.xAxis,r=e.yAxis,o=e.xAxisTicks,a=e.yAxisTicks,i=e.dataKey,s=e.bandSize,l=e.displayedData,c=e.offset,u=t.layout,d=l.map(function(e,t){var l=zG(e,i);return"horizontal"===u?{x:rq({axis:n,ticks:o,bandSize:s,entry:e,index:t}),y:GT(l)?null:r.scale(l),value:l,payload:e}:{x:GT(l)?null:n.scale(l),y:rq({axis:r,ticks:a,bandSize:s,entry:e,index:t}),value:l,payload:e}});return dJ({points:d,layout:u},c)});var xJ,EJ=["layout","type","stroke","connectNulls","isRange","ref"],kJ=["key"];function AJ(e){return AJ="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},AJ(e)}function TJ(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)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}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function OJ(){return OJ=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},OJ.apply(this,arguments)}function CJ(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function IJ(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?CJ(Object(n),!0).forEach(function(t){DJ(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):CJ(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function NJ(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,MJ(r.key),r)}}function _J(e,t,n){return t=PJ(t),function(e,t){if(t&&("object"===AJ(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,RJ()?Reflect.construct(t,n||[],PJ(e).constructor):t.apply(e,n))}function RJ(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(RJ=function(){return!!e})()}function PJ(e){return PJ=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},PJ(e)}function LJ(e,t){return LJ=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},LJ(e,t)}function DJ(e,t,n){return(t=MJ(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function MJ(e){var t=function(e,t){if("object"!=AJ(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=AJ(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"==AJ(t)?t:t+""}var jJ=function(t){function n(){var e;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n);for(var t=arguments.length,r=new Array(t),o=0;o<t;o++)r[o]=arguments[o];return DJ(e=_J(this,n,[].concat(r)),"state",{isAnimationFinished:!0}),DJ(e,"id",uO("recharts-area-")),DJ(e,"handleAnimationEnd",function(){var t=e.props.onAnimationEnd;e.setState({isAnimationFinished:!0}),Vk(t)&&t()}),DJ(e,"handleAnimationStart",function(){var t=e.props.onAnimationStart;e.setState({isAnimationFinished:!1}),Vk(t)&&t()}),e}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&LJ(e,t)}(n,t),r=n,o=[{key:"renderDots",value:function(t,r,o){var a=this.props.isAnimationActive,i=this.state.isAnimationFinished;if(a&&!i)return null;var s=this.props,l=s.dot,c=s.points,u=s.dataKey,d=FO(this.props,!1),p=FO(l,!0),f=c.map(function(e,t){var r=IJ(IJ(IJ({key:"dot-".concat(t),r:3},d),p),{},{index:t,cx:e.x,cy:e.y,dataKey:u,value:e.value,payload:e.payload,points:c});return n.renderDotItem(l,r)}),g={clipPath:t?"url(#clipPath-".concat(r?"":"dots-").concat(o,")"):null};return e.createElement(KO,OJ({className:"recharts-area-dots"},g),f)}},{key:"renderHorizontalRect",value:function(t){var n=this.props,r=n.baseLine,o=n.points,a=n.strokeWidth,i=o[0].x,s=o[o.length-1].x,l=t*Math.abs(i-s),c=Xz(o.map(function(e){return e.y||0}));return sO(r)&&"number"==typeof r?c=Math.max(r,c):r&&Array.isArray(r)&&r.length&&(c=Math.max(Xz(r.map(function(e){return e.y||0})),c)),sO(c)?e.createElement("rect",{x:i<s?i:i-l,y:0,width:l,height:Math.floor(c+(a?parseInt("".concat(a),10):1))}):null}},{key:"renderVerticalRect",value:function(t){var n=this.props,r=n.baseLine,o=n.points,a=n.strokeWidth,i=o[0].y,s=o[o.length-1].y,l=t*Math.abs(i-s),c=Xz(o.map(function(e){return e.x||0}));return sO(r)&&"number"==typeof r?c=Math.max(r,c):r&&Array.isArray(r)&&r.length&&(c=Math.max(Xz(r.map(function(e){return e.x||0})),c)),sO(c)?e.createElement("rect",{x:0,y:i<s?i:i-l,width:c+(a?parseInt("".concat(a),10):1),height:Math.floor(l)}):null}},{key:"renderClipRect",value:function(e){return"vertical"===this.props.layout?this.renderVerticalRect(e):this.renderHorizontalRect(e)}},{key:"renderAreaStatically",value:function(t,n,r,o){var a=this.props,i=a.layout,s=a.type,l=a.stroke,c=a.connectNulls,u=a.isRange;a.ref;var d=TJ(a,EJ);return e.createElement(KO,{clipPath:r?"url(#clipPath-".concat(o,")"):null},e.createElement(bH,OJ({},FO(d,!0),{points:t,connectNulls:c,type:s,baseLine:n,layout:i,stroke:"none",className:"recharts-area-area"})),"none"!==l&&e.createElement(bH,OJ({},FO(this.props,!1),{className:"recharts-area-curve",layout:i,type:s,connectNulls:c,fill:"none",points:t})),"none"!==l&&u&&e.createElement(bH,OJ({},FO(this.props,!1),{className:"recharts-area-curve",layout:i,type:s,connectNulls:c,fill:"none",points:n})))}},{key:"renderAreaWithAnimation",value:function(t,n){var r=this,o=this.props,a=o.points,i=o.baseLine,s=o.isAnimationActive,l=o.animationBegin,c=o.animationDuration,u=o.animationEasing,d=o.animationId,p=this.state,f=p.prevPoints,g=p.prevBaseLine;return e.createElement(mW,{begin:l,duration:c,isActive:s,easing:u,from:{t:0},to:{t:1},key:"area-".concat(d),onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},function(o){var s=o.t;if(f){var l,c=f.length/a.length,u=a.map(function(e,t){var n=Math.floor(t*c);if(f[n]){var r=f[n],o=fO(r.x,e.x),a=fO(r.y,e.y);return IJ(IJ({},e),{},{x:o(s),y:a(s)})}return e});return l=sO(i)&&"number"==typeof i?fO(g,i)(s):GT(i)||oO(i)?fO(g,0)(s):i.map(function(e,t){var n=Math.floor(t*c);if(g[n]){var r=g[n],o=fO(r.x,e.x),a=fO(r.y,e.y);return IJ(IJ({},e),{},{x:o(s),y:a(s)})}return e}),r.renderAreaStatically(u,l,t,n)}return e.createElement(KO,null,e.createElement("defs",null,e.createElement("clipPath",{id:"animationClipPath-".concat(n)},r.renderClipRect(s))),e.createElement(KO,{clipPath:"url(#animationClipPath-".concat(n,")")},r.renderAreaStatically(a,i,t,n)))})}},{key:"renderArea",value:function(e,t){var n=this.props,r=n.points,o=n.baseLine,a=n.isAnimationActive,i=this.state,s=i.prevPoints,l=i.prevBaseLine,c=i.totalLength;return a&&r&&r.length&&(!s&&c>0||!d$(s,r)||!d$(l,o))?this.renderAreaWithAnimation(e,t):this.renderAreaStatically(r,o,e,t)}},{key:"render",value:function(){var t,n=this.props,r=n.hide,o=n.dot,a=n.points,i=n.className,s=n.top,l=n.left,c=n.xAxis,u=n.yAxis,d=n.width,p=n.height,f=n.isAnimationActive,g=n.id;if(r||!a||!a.length)return null;var h=this.state.isAnimationFinished,m=1===a.length,b=hk("recharts-area",i),y=c&&c.allowDataOverflow,v=u&&u.allowDataOverflow,w=y||v,S=GT(g)?this.id:g,x=null!==(t=FO(o,!1))&&void 0!==t?t:{r:3,strokeWidth:2},E=x.r,k=void 0===E?3:E,A=x.strokeWidth,T=void 0===A?2:A,O=(jO(o)?o:{}).clipDot,C=void 0===O||O,I=2*k+T;return e.createElement(KO,{className:b},y||v?e.createElement("defs",null,e.createElement("clipPath",{id:"clipPath-".concat(S)},e.createElement("rect",{x:y?l:l-d/2,y:v?s:s-p/2,width:y?d:2*d,height:v?p:2*p})),!C&&e.createElement("clipPath",{id:"clipPath-dots-".concat(S)},e.createElement("rect",{x:l-I/2,y:s-I/2,width:d+I,height:p+I}))):null,m?null:this.renderArea(w,S),(o||m)&&this.renderDots(w,C,S),(!f||h)&&Xq.renderCallByParent(this.props,a))}}],a=[{key:"getDerivedStateFromProps",value:function(e,t){return e.animationId!==t.prevAnimationId?{prevAnimationId:e.animationId,curPoints:e.points,curBaseLine:e.baseLine,prevPoints:t.curPoints,prevBaseLine:t.curBaseLine}:e.points!==t.curPoints||e.baseLine!==t.curBaseLine?{curPoints:e.points,curBaseLine:e.baseLine}:null}}],o&&NJ(r.prototype,o),a&&NJ(r,a),Object.defineProperty(r,"prototype",{writable:!1}),r;var r,o,a}(e.PureComponent);function FJ(e){return FJ="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},FJ(e)}function BJ(e,t,n){return t&&function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,HJ(r.key),r)}}(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function UJ(e,t,n){return t=$J(t),function(e,t){if(t&&("object"===FJ(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,zJ()?Reflect.construct(t,n||[],$J(e).constructor):t.apply(e,n))}function zJ(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(zJ=function(){return!!e})()}function $J(e){return $J=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},$J(e)}function GJ(e,t){return GJ=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},GJ(e,t)}function qJ(e,t,n){return(t=HJ(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function HJ(e){var t=function(e,t){if("object"!=FJ(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=FJ(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"==FJ(t)?t:t+""}function VJ(){return VJ=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},VJ.apply(this,arguments)}function WJ(e){var t=e.xAxisId,n=NZ(),r=_Z(),o=CZ(t);return null==o?null:i.createElement(UQ,VJ({},o,{className:hk("recharts-".concat(o.axisType," ").concat(o.axisType),o.className),viewBox:{x:0,y:0,width:n,height:r},ticksGenerator:function(e){return YG(e,!0)}}))}xJ=jJ,DJ(jJ,"displayName","Area"),DJ(jJ,"defaultProps",{stroke:"#3182bd",fill:"#3182bd",fillOpacity:.6,xAxisId:0,yAxisId:0,legendType:"line",connectNulls:!1,points:[],dot:!1,activeDot:!0,hide:!1,isAnimationActive:!DD,animationBegin:0,animationDuration:1500,animationEasing:"ease"}),DJ(jJ,"getBaseValue",function(e,t,n,r){var o=e.layout,a=e.baseValue,i=t.props.baseValue,s=null!=i?i:a;if(sO(s)&&"number"==typeof s)return s;var l="horizontal"===o?r:n,c=l.scale.domain();if("number"===l.type){var u=Math.max(c[0],c[1]),d=Math.min(c[0],c[1]);return"dataMin"===s?d:"dataMax"===s||u<0?u:Math.max(Math.min(c[0],c[1]),0)}return"dataMin"===s?c[0]:"dataMax"===s?c[1]:c[0]}),DJ(jJ,"getComposedData",function(e){var t,n=e.props,r=e.item,o=e.xAxis,a=e.yAxis,i=e.xAxisTicks,s=e.yAxisTicks,l=e.bandSize,c=e.dataKey,u=e.stackedData,d=e.dataStartIndex,p=e.displayedData,f=e.offset,g=n.layout,h=u&&u.length,m=xJ.getBaseValue(n,r,o,a),b="horizontal"===g,y=!1,v=p.map(function(e,t){var n;h?n=u[d+t]:(n=zG(e,c),Array.isArray(n)?y=!0:n=[m,n]);var r=null==n[1]||h&&null==zG(e,c);return b?{x:rq({axis:o,ticks:i,bandSize:l,entry:e,index:t}),y:r?null:a.scale(n[1]),value:n,payload:e}:{x:r?null:o.scale(n[1]),y:rq({axis:a,ticks:s,bandSize:l,entry:e,index:t}),value:n,payload:e}});return t=h||y?v.map(function(e){var t=Array.isArray(e.value)?e.value[0]:null;return b?{x:e.x,y:null!=t&&null!=e.y?a.scale(t):null}:{x:null!=t?o.scale(t):null,y:e.y}}):b?a.scale(m):o.scale(m),IJ({points:v,baseLine:t,layout:g,isRange:y},f)}),DJ(jJ,"renderDotItem",function(t,n){var r;if(e.isValidElement(t))r=e.cloneElement(t,n);else if(Vk(t))r=t(n);else{var o=hk("recharts-area-dot","boolean"!=typeof t?t.className:""),a=n.key,i=TJ(n,kJ);r=e.createElement(jW,OJ({},i,{key:a,className:o}))}return r});var YJ=function(e){function t(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),UJ(this,t,arguments)}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&GJ(e,t)}(t,e),BJ(t,[{key:"render",value:function(){return i.createElement(WJ,this.props)}}])}(i.Component);function KJ(e){return KJ="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},KJ(e)}function XJ(e,t,n){return t&&function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,n0(r.key),r)}}(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function ZJ(e,t,n){return t=JJ(t),function(e,t){if(t&&("object"===KJ(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,QJ()?Reflect.construct(t,n||[],JJ(e).constructor):t.apply(e,n))}function QJ(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(QJ=function(){return!!e})()}function JJ(e){return JJ=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},JJ(e)}function e0(e,t){return e0=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},e0(e,t)}function t0(e,t,n){return(t=n0(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function n0(e){var t=function(e,t){if("object"!=KJ(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=KJ(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"==KJ(t)?t:t+""}function r0(){return r0=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},r0.apply(this,arguments)}qJ(YJ,"displayName","XAxis"),qJ(YJ,"defaultProps",{allowDecimals:!0,hide:!1,orientation:"bottom",width:0,height:30,mirror:!1,xAxisId:0,tickCount:5,type:"category",padding:{left:0,right:0},allowDataOverflow:!1,scale:"auto",reversed:!1,allowDuplicatedCategory:!0});var o0=function(e){var t=e.yAxisId,n=NZ(),r=_Z(),o=IZ(t);return null==o?null:i.createElement(UQ,r0({},o,{className:hk("recharts-".concat(o.axisType," ").concat(o.axisType),o.className),viewBox:{x:0,y:0,width:n,height:r},ticksGenerator:function(e){return YG(e,!0)}}))},a0=function(e){function t(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),ZJ(this,t,arguments)}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&e0(e,t)}(t,e),XJ(t,[{key:"render",value:function(){return i.createElement(o0,this.props)}}])}(i.Component);function i0(e){return function(e){if(Array.isArray(e))return s0(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return s0(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return s0(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function s0(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}t0(a0,"displayName","YAxis"),t0(a0,"defaultProps",{allowDuplicatedCategory:!0,allowDecimals:!0,hide:!1,orientation:"left",width:60,height:0,mirror:!1,yAxisId:0,tickCount:5,type:"number",padding:{top:0,bottom:0},allowDataOverflow:!1,scale:"auto",reversed:!1});var l0=function(e,t,n,r,o){var a=PO(e,VZ),i=PO(e,oQ),s=[].concat(i0(a),i0(i)),l=PO(e,mQ),c="".concat(r,"Id"),u=r[0],d=t;if(s.length&&(d=s.reduce(function(e,t){if(t.props[c]===n&&cX(t.props,"extendDomain")&&sO(t.props[u])){var r=t.props[u];return[Math.min(e[0],r),Math.max(e[1],r)]}return e},d)),l.length){var p="".concat(u,"1"),f="".concat(u,"2");d=l.reduce(function(e,t){if(t.props[c]===n&&cX(t.props,"extendDomain")&&sO(t.props[p])&&sO(t.props[f])){var r=t.props[p],o=t.props[f];return[Math.min(e[0],r,o),Math.max(e[1],r,o)]}return e},d)}return o&&o.length&&(d=o.reduce(function(e,t){return sO(t)?[Math.min(e[0],t),Math.max(e[1],t)]:e},d)),d},c0={exports:{}};!function(e){var t=Object.prototype.hasOwnProperty,n="~";function r(){}function o(e,t,n){this.fn=e,this.context=t,this.once=n||!1}function a(e,t,r,a,i){if("function"!=typeof r)throw new TypeError("The listener must be a function");var s=new o(r,a||e,i),l=n?n+t:t;return e._events[l]?e._events[l].fn?e._events[l]=[e._events[l],s]:e._events[l].push(s):(e._events[l]=s,e._eventsCount++),e}function i(e,t){0===--e._eventsCount?e._events=new r:delete e._events[t]}function s(){this._events=new r,this._eventsCount=0}Object.create&&(r.prototype=Object.create(null),(new r).__proto__||(n=!1)),s.prototype.eventNames=function(){var e,r,o=[];if(0===this._eventsCount)return o;for(r in e=this._events)t.call(e,r)&&o.push(n?r.slice(1):r);return Object.getOwnPropertySymbols?o.concat(Object.getOwnPropertySymbols(e)):o},s.prototype.listeners=function(e){var t=n?n+e:e,r=this._events[t];if(!r)return[];if(r.fn)return[r.fn];for(var o=0,a=r.length,i=new Array(a);o<a;o++)i[o]=r[o].fn;return i},s.prototype.listenerCount=function(e){var t=n?n+e:e,r=this._events[t];return r?r.fn?1:r.length:0},s.prototype.emit=function(e,t,r,o,a,i){var s=n?n+e:e;if(!this._events[s])return!1;var l,c,u=this._events[s],d=arguments.length;if(u.fn){switch(u.once&&this.removeListener(e,u.fn,void 0,!0),d){case 1:return u.fn.call(u.context),!0;case 2:return u.fn.call(u.context,t),!0;case 3:return u.fn.call(u.context,t,r),!0;case 4:return u.fn.call(u.context,t,r,o),!0;case 5:return u.fn.call(u.context,t,r,o,a),!0;case 6:return u.fn.call(u.context,t,r,o,a,i),!0}for(c=1,l=new Array(d-1);c<d;c++)l[c-1]=arguments[c];u.fn.apply(u.context,l)}else{var p,f=u.length;for(c=0;c<f;c++)switch(u[c].once&&this.removeListener(e,u[c].fn,void 0,!0),d){case 1:u[c].fn.call(u[c].context);break;case 2:u[c].fn.call(u[c].context,t);break;case 3:u[c].fn.call(u[c].context,t,r);break;case 4:u[c].fn.call(u[c].context,t,r,o);break;default:if(!l)for(p=1,l=new Array(d-1);p<d;p++)l[p-1]=arguments[p];u[c].fn.apply(u[c].context,l)}}return!0},s.prototype.on=function(e,t,n){return a(this,e,t,n,!1)},s.prototype.once=function(e,t,n){return a(this,e,t,n,!0)},s.prototype.removeListener=function(e,t,r,o){var a=n?n+e:e;if(!this._events[a])return this;if(!t)return i(this,a),this;var s=this._events[a];if(s.fn)s.fn!==t||o&&!s.once||r&&s.context!==r||i(this,a);else{for(var l=0,c=[],u=s.length;l<u;l++)(s[l].fn!==t||o&&!s[l].once||r&&s[l].context!==r)&&c.push(s[l]);c.length?this._events[a]=1===c.length?c[0]:c:i(this,a)}return this},s.prototype.removeAllListeners=function(e){var t;return e?(t=n?n+e:e,this._events[t]&&i(this,t)):(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}(c0);var u0=new(0,c0.exports),d0="recharts.syncMouseEvents";function p0(e){return p0="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},p0(e)}function f0(e,t,n){return t&&function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,h0(r.key),r)}}(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function g0(e,t,n){return(t=h0(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function h0(e){var t=function(e,t){if("object"!=p0(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=p0(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"==p0(t)?t:t+""}var m0=function(){return f0(function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),g0(this,"activeIndex",0),g0(this,"coordinateList",[]),g0(this,"layout","horizontal")},[{key:"setDetails",value:function(e){var t,n=e.coordinateList,r=void 0===n?null:n,o=e.container,a=void 0===o?null:o,i=e.layout,s=void 0===i?null:i,l=e.offset,c=void 0===l?null:l,u=e.mouseHandlerCallback,d=void 0===u?null:u;this.coordinateList=null!==(t=null!=r?r:this.coordinateList)&&void 0!==t?t:[],this.container=null!=a?a:this.container,this.layout=null!=s?s:this.layout,this.offset=null!=c?c:this.offset,this.mouseHandlerCallback=null!=d?d:this.mouseHandlerCallback,this.activeIndex=Math.min(Math.max(this.activeIndex,0),this.coordinateList.length-1)}},{key:"focus",value:function(){this.spoofMouse()}},{key:"keyboardEvent",value:function(e){if(0!==this.coordinateList.length)switch(e.key){case"ArrowRight":if("horizontal"!==this.layout)return;this.activeIndex=Math.min(this.activeIndex+1,this.coordinateList.length-1),this.spoofMouse();break;case"ArrowLeft":if("horizontal"!==this.layout)return;this.activeIndex=Math.max(this.activeIndex-1,0),this.spoofMouse()}}},{key:"setIndex",value:function(e){this.activeIndex=e}},{key:"spoofMouse",value:function(){var e,t;if("horizontal"===this.layout&&0!==this.coordinateList.length){var n=this.container.getBoundingClientRect(),r=n.x,o=n.y,a=n.height,i=this.coordinateList[this.activeIndex].coordinate,s=(null===(e=window)||void 0===e?void 0:e.scrollX)||0,l=(null===(t=window)||void 0===t?void 0:t.scrollY)||0,c=r+i+s,u=o+this.offset.top+a/2+l;this.mouseHandlerCallback({pageX:c,pageY:u})}}}])}();function b0(e){var t=e.cx,n=e.cy,r=e.radius,o=e.startAngle,a=e.endAngle;return{points:[wq(t,n,r,o),wq(t,n,r,a)],cx:t,cy:n,radius:r,startAngle:o,endAngle:a}}function y0(e,t,n){var r,o,a,i;if("horizontal"===e)a=r=t.x,o=n.top,i=n.top+n.height;else if("vertical"===e)i=o=t.y,r=n.left,a=n.left+n.width;else if(null!=t.cx&&null!=t.cy){if("centric"!==e)return b0(t);var s=t.cx,l=t.cy,c=t.innerRadius,u=t.outerRadius,d=t.angle,p=wq(s,l,c,d),f=wq(s,l,u,d);r=p.x,o=p.y,a=f.x,i=f.y}return[{x:r,y:o},{x:a,y:i}]}function v0(e){return v0="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},v0(e)}function w0(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function S0(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?w0(Object(n),!0).forEach(function(t){x0(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):w0(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function x0(e,t,n){var r;return r=function(e,t){if("object"!=v0(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=v0(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(t,"string"),(t="symbol"==v0(r)?r:r+"")in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function E0(t){var n,r,o,a=t.element,i=t.tooltipEventType,s=t.isActive,l=t.activeCoordinate,c=t.activePayload,u=t.offset,d=t.activeTooltipIndex,p=t.tooltipAxisBandSize,f=t.layout,g=t.chartName,h=null!==(n=a.props.cursor)&&void 0!==n?n:null===(r=a.type.defaultProps)||void 0===r?void 0:r.cursor;if(!a||!h||!s||!l||"ScatterChart"!==g&&"axis"!==i)return null;var m=bH;if("ScatterChart"===g)o=l,m=HW;else if("BarChart"===g)o=function(e,t,n,r){var o=r/2;return{stroke:"none",fill:"#ccc",x:"horizontal"===e?t.x-o:n.left+.5,y:"horizontal"===e?n.top+.5:t.y-o,width:"horizontal"===e?r:n.width-1,height:"horizontal"===e?n.height-1:r}}(f,l,u,p),m=OW;else if("radial"===f){var b=b0(l),y=b.cx,v=b.cy,w=b.radius;o={cx:y,cy:v,startAngle:b.startAngle,endAngle:b.endAngle,innerRadius:w,outerRadius:w},m=aH}else o={points:y0(f,l,u)},m=bH;var S=S0(S0(S0(S0({stroke:"#ccc",pointerEvents:"none"},u),o),FO(h,!1)),{},{payload:c,payloadIndex:d,className:hk("recharts-tooltip-cursor",h.className)});return e.isValidElement(h)?e.cloneElement(h,S):e.createElement(m,S)}var k0=["item"],A0=["children","className","width","height","style","compact","title","desc"];function T0(e){return T0="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},T0(e)}function O0(){return O0=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},O0.apply(this,arguments)}function C0(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,a,i,s=[],l=!0,c=!1;try{if(a=(n=n.call(e)).next,0===t);else for(;!(l=(r=a.call(n)).done)&&(s.push(r.value),s.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(c)throw o}}return s}}(e,t)||M0(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function I0(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)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}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}function N0(e,t,n){return t&&function(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,z0(r.key),r)}}(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function _0(e,t,n){return t=P0(t),function(e,t){if(t&&("object"===T0(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,R0()?Reflect.construct(t,n||[],P0(e).constructor):t.apply(e,n))}function R0(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(R0=function(){return!!e})()}function P0(e){return P0=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},P0(e)}function L0(e,t){return L0=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},L0(e,t)}function D0(e){return function(e){if(Array.isArray(e))return j0(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||M0(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function M0(e,t){if(e){if("string"==typeof e)return j0(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?j0(e,t):void 0}}function j0(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function F0(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function B0(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?F0(Object(n),!0).forEach(function(t){U0(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):F0(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function U0(e,t,n){return(t=z0(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function z0(e){var t=function(e,t){if("object"!=T0(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t);if("object"!=T0(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==T0(t)?t:t+""}var $0={xAxis:["bottom","top"],yAxis:["left","right"]},G0={width:"100%",height:"100%"},q0={x:0,y:0};function H0(e){return e}var V0=function(e,t){var n=t.graphicalItems,r=t.dataStartIndex,o=t.dataEndIndex,a=(null!=n?n:[]).reduce(function(e,t){var n=t.props.data;return n&&n.length?[].concat(D0(e),D0(n)):e},[]);return a.length>0?a:e&&e.length&&sO(r)&&sO(o)?e.slice(r,o+1):[]};function W0(e){return"number"===e?[0,"auto"]:void 0}var Y0=function(e,t,n,r){var o=e.graphicalItems,a=e.tooltipAxis,i=V0(t,e);return n<0||!o||!o.length||n>=i.length?null:o.reduce(function(o,s){var l,c,u=null!==(l=s.props.data)&&void 0!==l?l:t;(u&&e.dataStartIndex+e.dataEndIndex!==0&&e.dataEndIndex-e.dataStartIndex>=n&&(u=u.slice(e.dataStartIndex,e.dataEndIndex+1)),a.dataKey&&!a.allowDuplicatedCategory)?c=gO(void 0===u?i:u,a.dataKey,r):c=u&&u[n]||i[n];return c?[].concat(D0(o),[dq(s,c)]):o},[])},K0=function(e,t,n,r){var o=r||{x:e.chartX,y:e.chartY},a=function(e,t){return"horizontal"===t?e.x:"vertical"===t?e.y:"centric"===t?e.angle:e.radius}(o,n),i=e.orderedTooltipTicks,s=e.tooltipAxis,l=e.tooltipTicks,c=function(e){var t,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],r=arguments.length>2?arguments[2]:void 0,o=arguments.length>3?arguments[3]:void 0,a=-1,i=null!==(t=null==n?void 0:n.length)&&void 0!==t?t:0;if(i<=1)return 0;if(o&&"angleAxis"===o.axisType&&Math.abs(Math.abs(o.range[1]-o.range[0])-360)<=1e-6)for(var s=o.range,l=0;l<i;l++){var c=l>0?r[l-1].coordinate:r[i-1].coordinate,u=r[l].coordinate,d=l>=i-1?r[0].coordinate:r[l+1].coordinate,p=void 0;if(aO(u-c)!==aO(d-u)){var f=[];if(aO(d-u)===aO(s[1]-s[0])){p=d;var g=u+s[1]-s[0];f[0]=Math.min(g,(g+c)/2),f[1]=Math.max(g,(g+c)/2)}else{p=c;var h=d+s[1]-s[0];f[0]=Math.min(u,(h+u)/2),f[1]=Math.max(u,(h+u)/2)}var m=[Math.min(u,(p+u)/2),Math.max(u,(p+u)/2)];if(e>m[0]&&e<=m[1]||e>=f[0]&&e<=f[1]){a=r[l].index;break}}else{var b=Math.min(c,d),y=Math.max(c,d);if(e>(b+u)/2&&e<=(y+u)/2){a=r[l].index;break}}}else for(var v=0;v<i;v++)if(0===v&&e<=(n[v].coordinate+n[v+1].coordinate)/2||v>0&&v<i-1&&e>(n[v].coordinate+n[v-1].coordinate)/2&&e<=(n[v].coordinate+n[v+1].coordinate)/2||v===i-1&&e>(n[v].coordinate+n[v-1].coordinate)/2){a=n[v].index;break}return a}(a,i,l,s);if(c>=0&&l){var u=l[c]&&l[c].value,d=Y0(e,t,c,u),p=function(e,t,n,r){var o=t.find(function(e){return e&&e.index===n});if(o){if("horizontal"===e)return{x:o.coordinate,y:r.y};if("vertical"===e)return{x:r.x,y:o.coordinate};if("centric"===e){var a=o.coordinate,i=r.radius;return B0(B0(B0({},r),wq(r.cx,r.cy,i,a)),{},{angle:a,radius:i})}var s=o.coordinate,l=r.angle;return B0(B0(B0({},r),wq(r.cx,r.cy,s,l)),{},{angle:l,radius:s})}return q0}(n,i,c,o);return{activeTooltipIndex:c,activeLabel:u,activePayload:d,activeCoordinate:p}}return null},X0=function(e,t){var n=t.axes,r=t.graphicalItems,o=t.axisType,a=t.axisIdKey,i=t.stackGroups,s=t.dataStartIndex,l=t.dataEndIndex,c=e.layout,u=e.children,d=e.stackOffset,p=VG(c,o);return n.reduce(function(t,n){var f,g=void 0!==n.type.defaultProps?B0(B0({},n.type.defaultProps),n.props):n.props,h=g.type,m=g.dataKey,b=g.allowDataOverflow,y=g.allowDuplicatedCategory,v=g.scale,w=g.ticks,S=g.includeHidden,x=g[a];if(t[x])return t;var E,k,A,T=V0(e.data,{graphicalItems:r.filter(function(e){var t;return(a in e.props?e.props[a]:null===(t=e.type.defaultProps)||void 0===t?void 0:t[a])===x}),dataStartIndex:s,dataEndIndex:l}),O=T.length;(function(e,t,n){if("number"===n&&!0===t&&Array.isArray(e)){var r=null==e?void 0:e[0],o=null==e?void 0:e[1];if(r&&o&&sO(r)&&sO(o))return!0}return!1})(g.domain,b,h)&&(E=lq(g.domain,null,b),!p||"number"!==h&&"auto"===v||(A=$G(T,m,"category")));var C=W0(h);if(!E||0===E.length){var I,N=null!==(I=g.domain)&&void 0!==I?I:C;if(m){if(E=$G(T,m,h),"category"===h&&p){var _=function(e){if(!Array.isArray(e))return!1;for(var t=e.length,n={},r=0;r<t;r++){if(n[e[r]])return!0;n[e[r]]=!0}return!1}(E);y&&_?(k=E,E=MK(0,O)):y||(E=uq(N,E,n).reduce(function(e,t){return e.indexOf(t)>=0?e:[].concat(D0(e),[t])},[]))}else if("category"===h)E=y?E.filter(function(e){return""!==e&&!GT(e)}):uq(N,E,n).reduce(function(e,t){return e.indexOf(t)>=0||""===t||GT(t)?e:[].concat(D0(e),[t])},[]);else if("number"===h){var R=function(e,t,n,r,o){var a=t.map(function(t){return qG(e,t,n,o,r)}).filter(function(e){return!GT(e)});return a&&a.length?a.reduce(function(e,t){return[Math.min(e[0],t[0]),Math.max(e[1],t[1])]},[1/0,-1/0]):null}(T,r.filter(function(e){var t,n,r=a in e.props?e.props[a]:null===(t=e.type.defaultProps)||void 0===t?void 0:t[a],o="hide"in e.props?e.props.hide:null===(n=e.type.defaultProps)||void 0===n?void 0:n.hide;return r===x&&(S||!o)}),m,o,c);R&&(E=R)}!p||"number"!==h&&"auto"===v||(A=$G(T,m,"category"))}else E=p?MK(0,O):i&&i[x]&&i[x].hasStack&&"number"===h?"expand"===d?[0,1]:aq(i[x].stackGroups,s,l):HG(T,r.filter(function(e){var t=a in e.props?e.props[a]:e.type.defaultProps[a],n="hide"in e.props?e.props.hide:e.type.defaultProps.hide;return t===x&&(S||!n)}),h,c,!0);if("number"===h)E=l0(u,E,x,o,w),N&&(E=lq(N,E,b));else if("category"===h&&N){var P=N;E.every(function(e){return P.indexOf(e)>=0})&&(E=P)}}return B0(B0({},t),{},U0({},x,B0(B0({},g),{},{axisType:o,domain:E,categoricalDomain:A,duplicateDomain:k,originalDomain:null!==(f=g.domain)&&void 0!==f?f:C,isCategorical:p,layout:c})))},{})},Z0=function(e,t){var n=t.axisType,r=void 0===n?"xAxis":n,o=t.AxisComp,a=t.graphicalItems,i=t.stackGroups,s=t.dataStartIndex,l=t.dataEndIndex,c=e.children,u="".concat(r,"Id"),d=PO(c,o),p={};return d&&d.length?p=X0(e,{axes:d,graphicalItems:a,axisType:r,axisIdKey:u,stackGroups:i,dataStartIndex:s,dataEndIndex:l}):a&&a.length&&(p=function(e,t){var n=t.graphicalItems,r=t.Axis,o=t.axisType,a=t.axisIdKey,i=t.stackGroups,s=t.dataStartIndex,l=t.dataEndIndex,c=e.layout,u=e.children,d=V0(e.data,{graphicalItems:n,dataStartIndex:s,dataEndIndex:l}),p=d.length,f=VG(c,o),g=-1;return n.reduce(function(e,t){var h,m=(void 0!==t.type.defaultProps?B0(B0({},t.type.defaultProps),t.props):t.props)[a],b=W0("number");return e[m]?e:(g++,f?h=MK(0,p):i&&i[m]&&i[m].hasStack?(h=aq(i[m].stackGroups,s,l),h=l0(u,h,m,o)):(h=lq(b,HG(d,n.filter(function(e){var t,n,r=a in e.props?e.props[a]:null===(t=e.type.defaultProps)||void 0===t?void 0:t[a],o="hide"in e.props?e.props.hide:null===(n=e.type.defaultProps)||void 0===n?void 0:n.hide;return r===m&&!o}),"number",c),r.defaultProps.allowDataOverflow),h=l0(u,h,m,o)),B0(B0({},e),{},U0({},m,B0(B0({axisType:o},r.defaultProps),{},{hide:!0,orientation:$T($0,"".concat(o,".").concat(g%2),null),domain:h,originalDomain:b,isCategorical:f,layout:c}))))},{})}(e,{Axis:o,graphicalItems:a,axisType:r,axisIdKey:u,stackGroups:i,dataStartIndex:s,dataEndIndex:l})),p},Q0=function(e){var t=e.children,n=e.defaultShowTooltip,r=LO(t,eX),o=0,a=0;return e.data&&0!==e.data.length&&(a=e.data.length-1),r&&r.props&&(r.props.startIndex>=0&&(o=r.props.startIndex),r.props.endIndex>=0&&(a=r.props.endIndex)),{chartX:0,chartY:0,dataStartIndex:o,dataEndIndex:a,activeTooltipIndex:-1,isTooltipActive:Boolean(n)}},J0=function(e){return"horizontal"===e?{numericAxisName:"yAxis",cateAxisName:"xAxis"}:"vertical"===e?{numericAxisName:"xAxis",cateAxisName:"yAxis"}:"centric"===e?{numericAxisName:"radiusAxis",cateAxisName:"angleAxis"}:{numericAxisName:"angleAxis",cateAxisName:"radiusAxis"}},e1=function(e,t){var n=e.props,r=(e.graphicalItems,e.xAxisMap),o=void 0===r?{}:r,a=e.yAxisMap,i=void 0===a?{}:a,s=n.width,l=n.height,c=n.children,u=n.margin||{},d=LO(c,eX),p=LO(c,sL),f=Object.keys(i).reduce(function(e,t){var n=i[t],r=n.orientation;return n.mirror||n.hide?e:B0(B0({},e),{},U0({},r,e[r]+n.width))},{left:u.left||0,right:u.right||0}),g=Object.keys(o).reduce(function(e,t){var n=o[t],r=n.orientation;return n.mirror||n.hide?e:B0(B0({},e),{},U0({},r,$T(e,"".concat(r))+n.height))},{top:u.top||0,bottom:u.bottom||0}),h=B0(B0({},g),f),m=h.bottom;d&&(h.bottom+=d.props.height||eX.defaultProps.height),p&&t&&(h=function(e,t,n,r){var o=n.children,a=n.width,i=n.margin,s=a-(i.left||0)-(i.right||0),l=LG({children:o,legendWidth:s});if(l){var c=r||{},u=c.width,d=c.height,p=l.align,f=l.verticalAlign,g=l.layout;if(("vertical"===g||"horizontal"===g&&"middle"===f)&&"center"!==p&&sO(e[p]))return BG(BG({},e),{},UG({},p,e[p]+(u||0)));if(("horizontal"===g||"vertical"===g&&"center"===p)&&"middle"!==f&&sO(e[f]))return BG(BG({},e),{},UG({},f,e[f]+(d||0)))}return e}(h,0,n,t));var b=s-h.left-h.right,y=l-h.top-h.bottom;return B0(B0({brushBottom:m},h),{},{width:Math.max(b,0),height:Math.max(y,0)})},t1=function(e,t){return"xAxis"===t?e[t].width:"yAxis"===t?e[t].height:void 0},n1=function(t){var n=t.chartName,r=t.GraphicalChild,o=t.defaultTooltipEventType,a=void 0===o?"axis":o,i=t.validateTooltipEventTypes,s=void 0===i?["axis"]:i,l=t.axisComponents,c=t.legendContent,u=t.formatAxisMap,d=t.defaultProps,p=function(e,t){var n=t.graphicalItems,r=t.stackGroups,o=t.offset,a=t.updateId,i=t.dataStartIndex,s=t.dataEndIndex,c=e.barSize,u=e.layout,d=e.barGap,p=e.barCategoryGap,f=e.maxBarSize,g=J0(u),h=g.numericAxisName,m=g.cateAxisName,b=function(e){return!(!e||!e.length)&&e.some(function(e){var t=IO(e&&e.type);return t&&t.indexOf("Bar")>=0})}(n),y=[];return n.forEach(function(n,g){var v=V0(e.data,{graphicalItems:[n],dataStartIndex:i,dataEndIndex:s}),w=void 0!==n.type.defaultProps?B0(B0({},n.type.defaultProps),n.props):n.props,S=w.dataKey,x=w.maxBarSize,E=w["".concat(h,"Id")],k=w["".concat(m,"Id")],A=l.reduce(function(e,r){var o,a,i=t["".concat(r.axisType,"Map")],s=w["".concat(r.axisType,"Id")];i&&i[s]||"zAxis"===r.axisType||("production"!==process.env.NODE_ENV?hG(0,"Specifying a(n) ".concat(r.axisType,"Id requires a corresponding ").concat(r.axisType,"Id on the targeted graphical component ").concat(null!==(o=null==n||null===(a=n.type)||void 0===a?void 0:a.displayName)&&void 0!==o?o:"")):hG());var l=i[s];return B0(B0({},e),{},U0(U0({},r.axisType,l),"".concat(r.axisType,"Ticks"),YG(l)))},{}),T=A[m],O=A["".concat(m,"Ticks")],C=r&&r[E]&&r[E].hasStack&&function(e,t){var n,r=(null!==(n=e.type)&&void 0!==n&&n.defaultProps?BG(BG({},e.type.defaultProps),e.props):e.props).stackId;if(lO(r)){var o=t[r];if(o){var a=o.items.indexOf(e);return a>=0?o.stackedData[a]:null}}return null}(n,r[E].stackGroups),I=IO(n.type).indexOf("Bar")>=0,N=cq(T,O),_=[],R=b&&function(e){var t=e.barSize,n=e.totalSize,r=e.stackGroups,o=void 0===r?{}:r;if(!o)return{};for(var a={},i=Object.keys(o),s=0,l=i.length;s<l;s++)for(var c=o[i[s]].stackGroups,u=Object.keys(c),d=0,p=u.length;d<p;d++){var f=c[u[d]],g=f.items,h=f.cateAxisId,m=g.filter(function(e){return IO(e.type).indexOf("Bar")>=0});if(m&&m.length){var b=m[0].type.defaultProps,y=void 0!==b?BG(BG({},b),m[0].props):m[0].props,v=y.barSize,w=y[h];a[w]||(a[w]=[]);var S=GT(v)?t:v;a[w].push({item:m[0],stackList:m.slice(1),barSize:GT(S)?void 0:dO(S,n,0)})}}return a}({barSize:c,stackGroups:r,totalSize:t1(A,m)});if(I){var P,L,D=GT(x)?f:x,M=null!==(P=null!==(L=cq(T,O,!0))&&void 0!==L?L:D)&&void 0!==P?P:0;_=function(e){var t=e.barGap,n=e.barCategoryGap,r=e.bandSize,o=e.sizeList,a=void 0===o?[]:o,i=e.maxBarSize,s=a.length;if(s<1)return null;var l,c=dO(t,r,0,!0),u=[];if(a[0].barSize===+a[0].barSize){var d=!1,p=r/s,f=a.reduce(function(e,t){return e+t.barSize||0},0);(f+=(s-1)*c)>=r&&(f-=(s-1)*c,c=0),f>=r&&p>0&&(d=!0,f=s*(p*=.9));var g={offset:((r-f)/2|0)-c,size:0};l=a.reduce(function(e,t){var n={item:t.item,position:{offset:g.offset+g.size+c,size:d?p:t.barSize}},r=[].concat(MG(e),[n]);return g=r[r.length-1].position,t.stackList&&t.stackList.length&&t.stackList.forEach(function(e){r.push({item:e,position:g})}),r},u)}else{var h=dO(n,r,0,!0);r-2*h-(s-1)*c<=0&&(c=0);var m=(r-2*h-(s-1)*c)/s;m>1&&(m>>=0);var b=i===+i?Math.min(m,i):m;l=a.reduce(function(e,t,n){var r=[].concat(MG(e),[{item:t.item,position:{offset:h+(m+c)*n+(m-b)/2,size:b}}]);return t.stackList&&t.stackList.length&&t.stackList.forEach(function(e){r.push({item:e,position:r[r.length-1].position})}),r},u)}return l}({barGap:d,barCategoryGap:p,bandSize:M!==N?M:N,sizeList:R[k],maxBarSize:D}),M!==N&&(_=_.map(function(e){return B0(B0({},e),{},{position:B0(B0({},e.position),{},{offset:e.position.offset-M/2})})}))}var j,F,B=n&&n.type&&n.type.getComposedData;B&&y.push({props:B0(B0({},B(B0(B0({},A),{},{displayedData:v,props:e,dataKey:S,item:n,bandSize:N,barPosition:_,offset:o,stackedData:C,layout:u,dataStartIndex:i,dataEndIndex:s}))),{},U0(U0(U0({key:n.key||"item-".concat(g)},h,A[h]),m,A[m]),"animationId",a)),childIndex:(j=n,F=e.children,RO(F).indexOf(j)),item:n})}),y},f=function(e,t){var o=e.props,a=e.dataStartIndex,i=e.dataEndIndex,s=e.updateId;if(!DO({props:o}))return null;var c=o.children,d=o.layout,f=o.stackOffset,g=o.data,h=o.reverseStackOrder,m=J0(d),b=m.numericAxisName,y=m.cateAxisName,v=PO(c,r),w=function(e,t,n,r,o,a){if(!e)return null;var i=(a?t.reverse():t).reduce(function(e,t){var o,a=null!==(o=t.type)&&void 0!==o&&o.defaultProps?BG(BG({},t.type.defaultProps),t.props):t.props,i=a.stackId;if(a.hide)return e;var s=a[n],l=e[s]||{hasStack:!1,stackGroups:{}};if(lO(i)){var c=l.stackGroups[i]||{numericAxisId:n,cateAxisId:r,items:[]};c.items.push(t),l.hasStack=!0,l.stackGroups[i]=c}else l.stackGroups[uO("_stackId_")]={numericAxisId:n,cateAxisId:r,items:[t]};return BG(BG({},e),{},UG({},s,l))},{});return Object.keys(i).reduce(function(t,a){var s=i[a];return s.hasStack&&(s.stackGroups=Object.keys(s.stackGroups).reduce(function(t,a){var i=s.stackGroups[a];return BG(BG({},t),{},UG({},a,{numericAxisId:n,cateAxisId:r,items:i.items,stackedData:tq(e,i.items,o)}))},{})),BG(BG({},t),{},UG({},a,s))},{})}(g,v,"".concat(b,"Id"),"".concat(y,"Id"),f,h),S=l.reduce(function(e,t){var n="".concat(t.axisType,"Map");return B0(B0({},e),{},U0({},n,Z0(o,B0(B0({},t),{},{graphicalItems:v,stackGroups:t.axisType===b&&w,dataStartIndex:a,dataEndIndex:i}))))},{}),x=e1(B0(B0({},S),{},{props:o,graphicalItems:v}),null==t?void 0:t.legendBBox);Object.keys(S).forEach(function(e){S[e]=u(o,S[e],x,e.replace("Map",""),n)});var E,k,A=S["".concat(y,"Map")],T=(E=pO(A),{tooltipTicks:k=YG(E,!1,!0),orderedTooltipTicks:lD(k,function(e){return e.coordinate}),tooltipAxis:E,tooltipAxisBandSize:cq(E,k)}),O=p(o,B0(B0({},S),{},{dataStartIndex:a,dataEndIndex:i,updateId:s,graphicalItems:v,stackGroups:w,offset:x}));return B0(B0({formattedGraphicalItems:O,graphicalItems:v,offset:x,stackGroups:w},T),S)},g=function(t){function r(t){var o,a,i;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,r),U0(i=_0(this,r,[t]),"eventEmitterSymbol",Symbol("rechartsEventEmitter")),U0(i,"accessibilityManager",new m0),U0(i,"handleLegendBBoxUpdate",function(e){if(e){var t=i.state,n=t.dataStartIndex,r=t.dataEndIndex,o=t.updateId;i.setState(B0({legendBBox:e},f({props:i.props,dataStartIndex:n,dataEndIndex:r,updateId:o},B0(B0({},i.state),{},{legendBBox:e}))))}}),U0(i,"handleReceiveSyncEvent",function(e,t,n){if(i.props.syncId===e){if(n===i.eventEmitterSymbol&&"function"!=typeof i.props.syncMethod)return;i.applySyncEvent(t)}}),U0(i,"handleBrushChange",function(e){var t=e.startIndex,n=e.endIndex;if(t!==i.state.dataStartIndex||n!==i.state.dataEndIndex){var r=i.state.updateId;i.setState(function(){return B0({dataStartIndex:t,dataEndIndex:n},f({props:i.props,dataStartIndex:t,dataEndIndex:n,updateId:r},i.state))}),i.triggerSyncEvent({dataStartIndex:t,dataEndIndex:n})}}),U0(i,"handleMouseEnter",function(e){var t=i.getMouseInfo(e);if(t){var n=B0(B0({},t),{},{isTooltipActive:!0});i.setState(n),i.triggerSyncEvent(n);var r=i.props.onMouseEnter;Vk(r)&&r(n,e)}}),U0(i,"triggeredAfterMouseMove",function(e){var t=i.getMouseInfo(e),n=t?B0(B0({},t),{},{isTooltipActive:!0}):{isTooltipActive:!1};i.setState(n),i.triggerSyncEvent(n);var r=i.props.onMouseMove;Vk(r)&&r(n,e)}),U0(i,"handleItemMouseEnter",function(e){i.setState(function(){return{isTooltipActive:!0,activeItem:e,activePayload:e.tooltipPayload,activeCoordinate:e.tooltipPosition||{x:e.cx,y:e.cy}}})}),U0(i,"handleItemMouseLeave",function(){i.setState(function(){return{isTooltipActive:!1}})}),U0(i,"handleMouseMove",function(e){e.persist(),i.throttleTriggeredAfterMouseMove(e)}),U0(i,"handleMouseLeave",function(e){i.throttleTriggeredAfterMouseMove.cancel();var t={isTooltipActive:!1};i.setState(t),i.triggerSyncEvent(t);var n=i.props.onMouseLeave;Vk(n)&&n(t,e)}),U0(i,"handleOuterEvent",function(e){var t,n=function(e){var t=e&&e.type;return t&&CO[t]?CO[t]:null}(e),r=$T(i.props,"".concat(n));n&&Vk(r)&&r(null!==(t=/.*touch.*/i.test(n)?i.getMouseInfo(e.changedTouches[0]):i.getMouseInfo(e))&&void 0!==t?t:{},e)}),U0(i,"handleClick",function(e){var t=i.getMouseInfo(e);if(t){var n=B0(B0({},t),{},{isTooltipActive:!0});i.setState(n),i.triggerSyncEvent(n);var r=i.props.onClick;Vk(r)&&r(n,e)}}),U0(i,"handleMouseDown",function(e){var t=i.props.onMouseDown;Vk(t)&&t(i.getMouseInfo(e),e)}),U0(i,"handleMouseUp",function(e){var t=i.props.onMouseUp;Vk(t)&&t(i.getMouseInfo(e),e)}),U0(i,"handleTouchMove",function(e){null!=e.changedTouches&&e.changedTouches.length>0&&i.throttleTriggeredAfterMouseMove(e.changedTouches[0])}),U0(i,"handleTouchStart",function(e){null!=e.changedTouches&&e.changedTouches.length>0&&i.handleMouseDown(e.changedTouches[0])}),U0(i,"handleTouchEnd",function(e){null!=e.changedTouches&&e.changedTouches.length>0&&i.handleMouseUp(e.changedTouches[0])}),U0(i,"handleDoubleClick",function(e){var t=i.props.onDoubleClick;Vk(t)&&t(i.getMouseInfo(e),e)}),U0(i,"handleContextMenu",function(e){var t=i.props.onContextMenu;Vk(t)&&t(i.getMouseInfo(e),e)}),U0(i,"triggerSyncEvent",function(e){void 0!==i.props.syncId&&u0.emit(d0,i.props.syncId,e,i.eventEmitterSymbol)}),U0(i,"applySyncEvent",function(e){var t=i.props,n=t.layout,r=t.syncMethod,o=i.state.updateId,a=e.dataStartIndex,s=e.dataEndIndex;if(void 0!==e.dataStartIndex||void 0!==e.dataEndIndex)i.setState(B0({dataStartIndex:a,dataEndIndex:s},f({props:i.props,dataStartIndex:a,dataEndIndex:s,updateId:o},i.state)));else if(void 0!==e.activeTooltipIndex){var l=e.chartX,c=e.chartY,u=e.activeTooltipIndex,d=i.state,p=d.offset,g=d.tooltipTicks;if(!p)return;if("function"==typeof r)u=r(g,e);else if("value"===r){u=-1;for(var h=0;h<g.length;h++)if(g[h].value===e.activeLabel){u=h;break}}var m=B0(B0({},p),{},{x:p.left,y:p.top}),b=Math.min(l,m.x+m.width),y=Math.min(c,m.y+m.height),v=g[u]&&g[u].value,w=Y0(i.state,i.props.data,u),S=g[u]?{x:"horizontal"===n?g[u].coordinate:b,y:"horizontal"===n?y:g[u].coordinate}:q0;i.setState(B0(B0({},e),{},{activeLabel:v,activeCoordinate:S,activePayload:w,activeTooltipIndex:u}))}else i.setState(e)}),U0(i,"renderCursor",function(t){var r,o=i.state,a=o.isTooltipActive,s=o.activeCoordinate,l=o.activePayload,c=o.offset,u=o.activeTooltipIndex,d=o.tooltipAxisBandSize,p=i.getTooltipEventType(),f=null!==(r=t.props.active)&&void 0!==r?r:a,g=i.props.layout,h=t.key||"_recharts-cursor";return e.createElement(E0,{key:h,activeCoordinate:s,activePayload:l,activeTooltipIndex:u,chartName:n,element:t,isActive:f,layout:g,offset:c,tooltipAxisBandSize:d,tooltipEventType:p})}),U0(i,"renderPolarAxis",function(t,n,r){var o=$T(t,"type.axisType"),a=$T(i.state,"".concat(o,"Map")),s=t.type.defaultProps,l=void 0!==s?B0(B0({},s),t.props):t.props,c=a&&a[l["".concat(o,"Id")]];return e.cloneElement(t,B0(B0({},c),{},{className:hk(o,c.className),key:t.key||"".concat(n,"-").concat(r),ticks:YG(c,!0)}))}),U0(i,"renderPolarGrid",function(t){var n=t.props,r=n.radialLines,o=n.polarAngles,a=n.polarRadius,s=i.state,l=s.radiusAxisMap,c=s.angleAxisMap,u=pO(l),d=pO(c),p=d.cx,f=d.cy,g=d.innerRadius,h=d.outerRadius;return e.cloneElement(t,{polarAngles:Array.isArray(o)?o:YG(d,!0).map(function(e){return e.coordinate}),polarRadius:Array.isArray(a)?a:YG(u,!0).map(function(e){return e.coordinate}),cx:p,cy:f,innerRadius:g,outerRadius:h,key:t.key||"polar-grid",radialLines:r})}),U0(i,"renderLegend",function(){var t=i.state.formattedGraphicalItems,n=i.props,r=n.children,o=n.width,a=n.height,s=i.props.margin||{},l=o-(s.left||0)-(s.right||0),u=LG({children:r,formattedGraphicalItems:t,legendWidth:l,legendContent:c});if(!u)return null;var d=u.item,p=I0(u,k0);return e.cloneElement(d,B0(B0({},p),{},{chartWidth:o,chartHeight:a,margin:s,onBBoxUpdate:i.handleLegendBBoxUpdate}))}),U0(i,"renderTooltip",function(){var t,n=i.props,r=n.children,o=n.accessibilityLayer,a=LO(r,WD);if(!a)return null;var s=i.state,l=s.isTooltipActive,c=s.activeCoordinate,u=s.activePayload,d=s.activeLabel,p=s.offset,f=null!==(t=a.props.active)&&void 0!==t?t:l;return e.cloneElement(a,{viewBox:B0(B0({},p),{},{x:p.left,y:p.top}),active:f,label:d,payload:f?u:[],coordinate:c,accessibilityLayer:o})}),U0(i,"renderBrush",function(t){var n=i.props,r=n.margin,o=n.data,a=i.state,s=a.offset,l=a.dataStartIndex,c=a.dataEndIndex,u=a.updateId;return e.cloneElement(t,{key:t.key||"_recharts-brush",onChange:XG(i.handleBrushChange,t.props.onChange),data:o,x:sO(t.props.x)?t.props.x:s.left,y:sO(t.props.y)?t.props.y:s.top+s.height+s.brushBottom-(r.bottom||0),width:sO(t.props.width)?t.props.width:s.width,startIndex:l,endIndex:c,updateId:"brush-".concat(u)})}),U0(i,"renderReferenceElement",function(t,n,r){if(!t)return null;var o=i.clipPathId,a=i.state,s=a.xAxisMap,l=a.yAxisMap,c=a.offset,u=t.type.defaultProps||{},d=t.props,p=d.xAxisId,f=void 0===p?u.xAxisId:p,g=d.yAxisId,h=void 0===g?u.yAxisId:g;return e.cloneElement(t,{key:t.key||"".concat(n,"-").concat(r),xAxis:s[f],yAxis:l[h],viewBox:{x:c.left,y:c.top,width:c.width,height:c.height},clipPathId:o})}),U0(i,"renderActivePoints",function(e){var t=e.item,n=e.activePoint,o=e.basePoint,a=e.childIndex,i=e.isRange,s=[],l=t.props.key,c=void 0!==t.item.type.defaultProps?B0(B0({},t.item.type.defaultProps),t.item.props):t.item.props,u=c.activeDot,d=B0(B0({index:a,dataKey:c.dataKey,cx:n.x,cy:n.y,r:4,fill:GG(t.item),strokeWidth:2,stroke:"#fff",payload:n.payload,value:n.value},FO(u,!1)),xO(u));return s.push(r.renderActiveDot(u,d,"".concat(l,"-activePoint-").concat(a))),o?s.push(r.renderActiveDot(u,B0(B0({},d),{},{cx:o.x,cy:o.y}),"".concat(l,"-basePoint-").concat(a))):i&&s.push(null),s}),U0(i,"renderGraphicChild",function(t,n,r){var o=i.filterFormatItem(t,n,r);if(!o)return null;var a=i.getTooltipEventType(),s=i.state,l=s.isTooltipActive,c=s.tooltipAxis,u=s.activeTooltipIndex,d=s.activeLabel,p=LO(i.props.children,WD),f=o.props,g=f.points,h=f.isRange,m=f.baseLine,b=void 0!==o.item.type.defaultProps?B0(B0({},o.item.type.defaultProps),o.item.props):o.item.props,y=b.activeDot,v=b.hide,w=b.activeBar,S=b.activeShape,x=Boolean(!v&&l&&p&&(y||w||S)),E={};"axis"!==a&&p&&"click"===p.props.trigger?E={onClick:XG(i.handleItemMouseEnter,t.props.onClick)}:"axis"!==a&&(E={onMouseLeave:XG(i.handleItemMouseLeave,t.props.onMouseLeave),onMouseEnter:XG(i.handleItemMouseEnter,t.props.onMouseEnter)});var k=e.cloneElement(t,B0(B0({},o.props),E));if(x){if(!(u>=0)){var A,T=(null!==(A=i.getItemByXY(i.state.activeCoordinate))&&void 0!==A?A:{graphicalItem:k}).graphicalItem,O=T.item,C=void 0===O?t:O,I=T.childIndex,N=B0(B0(B0({},o.props),E),{},{activeIndex:I});return[e.cloneElement(C,N),null,null]}var _,R;if(c.dataKey&&!c.allowDuplicatedCategory){var P="function"==typeof c.dataKey?function(e){return"function"==typeof c.dataKey?c.dataKey(e.payload):null}:"payload.".concat(c.dataKey.toString());_=gO(g,P,d),R=h&&m&&gO(m,P,d)}else _=null==g?void 0:g[u],R=h&&m&&m[u];if(S||w){var L=void 0!==t.props.activeIndex?t.props.activeIndex:u;return[e.cloneElement(t,B0(B0(B0({},o.props),E),{},{activeIndex:L})),null,null]}if(!GT(_))return[k].concat(D0(i.renderActivePoints({item:o,activePoint:_,basePoint:R,childIndex:u,isRange:h})))}return h?[k,null,null]:[k,null]}),U0(i,"renderCustomized",function(t,n,r){return e.cloneElement(t,B0(B0({key:"recharts-customized-".concat(r)},i.props),i.state))}),U0(i,"renderMap",{CartesianGrid:{handler:H0,once:!0},ReferenceArea:{handler:i.renderReferenceElement},ReferenceLine:{handler:H0},ReferenceDot:{handler:i.renderReferenceElement},XAxis:{handler:H0},YAxis:{handler:H0},Brush:{handler:i.renderBrush,once:!0},Bar:{handler:i.renderGraphicChild},Line:{handler:i.renderGraphicChild},Area:{handler:i.renderGraphicChild},Radar:{handler:i.renderGraphicChild},RadialBar:{handler:i.renderGraphicChild},Scatter:{handler:i.renderGraphicChild},Pie:{handler:i.renderGraphicChild},Funnel:{handler:i.renderGraphicChild},Tooltip:{handler:i.renderCursor,once:!0},PolarGrid:{handler:i.renderPolarGrid,once:!0},PolarAngleAxis:{handler:i.renderPolarAxis},PolarRadiusAxis:{handler:i.renderPolarAxis},Customized:{handler:i.renderCustomized}}),i.clipPathId="".concat(null!==(o=t.id)&&void 0!==o?o:uO("recharts"),"-clip"),i.throttleTriggeredAfterMouseMove=mM(i.triggeredAfterMouseMove,null!==(a=t.throttleDelay)&&void 0!==a?a:1e3/60),i.state={},i}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&L0(e,t)}(r,t),N0(r,[{key:"componentDidMount",value:function(){var e,t;this.addListener(),this.accessibilityManager.setDetails({container:this.container,offset:{left:null!==(e=this.props.margin.left)&&void 0!==e?e:0,top:null!==(t=this.props.margin.top)&&void 0!==t?t:0},coordinateList:this.state.tooltipTicks,mouseHandlerCallback:this.triggeredAfterMouseMove,layout:this.props.layout}),this.displayDefaultTooltip()}},{key:"displayDefaultTooltip",value:function(){var e=this.props,t=e.children,n=e.data,r=e.height,o=e.layout,a=LO(t,WD);if(a){var i=a.props.defaultIndex;if(!("number"!=typeof i||i<0||i>this.state.tooltipTicks.length-1)){var s=this.state.tooltipTicks[i]&&this.state.tooltipTicks[i].value,l=Y0(this.state,n,i,s),c=this.state.tooltipTicks[i].coordinate,u=(this.state.offset.top+r)/2,d="horizontal"===o?{x:c,y:u}:{y:c,x:u},p=this.state.formattedGraphicalItems.find(function(e){return"Scatter"===e.item.type.name});p&&(d=B0(B0({},d),p.props.points[i].tooltipPosition),l=p.props.points[i].tooltipPayload);var f={activeTooltipIndex:i,isTooltipActive:!0,activeLabel:s,activePayload:l,activeCoordinate:d};this.setState(f),this.renderCursor(a),this.accessibilityManager.setIndex(i)}}}},{key:"getSnapshotBeforeUpdate",value:function(e,t){if(!this.props.accessibilityLayer)return null;var n,r;(this.state.tooltipTicks!==t.tooltipTicks&&this.accessibilityManager.setDetails({coordinateList:this.state.tooltipTicks}),this.props.layout!==e.layout&&this.accessibilityManager.setDetails({layout:this.props.layout}),this.props.margin!==e.margin)&&this.accessibilityManager.setDetails({offset:{left:null!==(n=this.props.margin.left)&&void 0!==n?n:0,top:null!==(r=this.props.margin.top)&&void 0!==r?r:0}});return null}},{key:"componentDidUpdate",value:function(e){BO([LO(e.children,WD)],[LO(this.props.children,WD)])||this.displayDefaultTooltip()}},{key:"componentWillUnmount",value:function(){this.removeListener(),this.throttleTriggeredAfterMouseMove.cancel()}},{key:"getTooltipEventType",value:function(){var e=LO(this.props.children,WD);if(e&&"boolean"==typeof e.props.shared){var t=e.props.shared?"axis":"item";return s.indexOf(t)>=0?t:a}return a}},{key:"getMouseInfo",value:function(e){if(!this.container)return null;var t=this.container,n=t.getBoundingClientRect(),r=function(e){return{top:e.top+window.scrollY-document.documentElement.clientTop,left:e.left+window.scrollX-document.documentElement.clientLeft}}(n),o={chartX:Math.round(e.pageX-r.left),chartY:Math.round(e.pageY-r.top)},a=n.width/t.offsetWidth||1,i=this.inRange(o.chartX,o.chartY,a);if(!i)return null;var s=this.state,l=s.xAxisMap,c=s.yAxisMap,u=this.getTooltipEventType(),d=K0(this.state,this.props.data,this.props.layout,i);if("axis"!==u&&l&&c){var p=pO(l).scale,f=pO(c).scale,g=p&&p.invert?p.invert(o.chartX):null,h=f&&f.invert?f.invert(o.chartY):null;return B0(B0({},o),{},{xValue:g,yValue:h},d)}return d?B0(B0({},o),d):null}},{key:"inRange",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1,r=this.props.layout,o=e/n,a=t/n;if("horizontal"===r||"vertical"===r){var i=this.state.offset;return o>=i.left&&o<=i.left+i.width&&a>=i.top&&a<=i.top+i.height?{x:o,y:a}:null}var s=this.state,l=s.angleAxisMap,c=s.radiusAxisMap;if(l&&c){var u=pO(l);return kq({x:o,y:a},u)}return null}},{key:"parseEventsOfWrapper",value:function(){var e=this.props.children,t=this.getTooltipEventType(),n=LO(e,WD),r={};return n&&"axis"===t&&(r="click"===n.props.trigger?{onClick:this.handleClick}:{onMouseEnter:this.handleMouseEnter,onDoubleClick:this.handleDoubleClick,onMouseMove:this.handleMouseMove,onMouseLeave:this.handleMouseLeave,onTouchMove:this.handleTouchMove,onTouchStart:this.handleTouchStart,onTouchEnd:this.handleTouchEnd,onContextMenu:this.handleContextMenu}),B0(B0({},xO(this.props,this.handleOuterEvent)),r)}},{key:"addListener",value:function(){u0.on(d0,this.handleReceiveSyncEvent)}},{key:"removeListener",value:function(){u0.removeListener(d0,this.handleReceiveSyncEvent)}},{key:"filterFormatItem",value:function(e,t,n){for(var r=this.state.formattedGraphicalItems,o=0,a=r.length;o<a;o++){var i=r[o];if(i.item===e||i.props.key===e.key||t===IO(i.item.type)&&n===i.childIndex)return i}return null}},{key:"renderClipPath",value:function(){var t=this.clipPathId,n=this.state.offset,r=n.left,o=n.top,a=n.height,i=n.width;return e.createElement("defs",null,e.createElement("clipPath",{id:t},e.createElement("rect",{x:r,y:o,height:a,width:i})))}},{key:"getXScales",value:function(){var e=this.state.xAxisMap;return e?Object.entries(e).reduce(function(e,t){var n=C0(t,2),r=n[0],o=n[1];return B0(B0({},e),{},U0({},r,o.scale))},{}):null}},{key:"getYScales",value:function(){var e=this.state.yAxisMap;return e?Object.entries(e).reduce(function(e,t){var n=C0(t,2),r=n[0],o=n[1];return B0(B0({},e),{},U0({},r,o.scale))},{}):null}},{key:"getXScaleByAxisId",value:function(e){var t;return null===(t=this.state.xAxisMap)||void 0===t||null===(t=t[e])||void 0===t?void 0:t.scale}},{key:"getYScaleByAxisId",value:function(e){var t;return null===(t=this.state.yAxisMap)||void 0===t||null===(t=t[e])||void 0===t?void 0:t.scale}},{key:"getItemByXY",value:function(e){var t=this.state,n=t.formattedGraphicalItems,r=t.activeItem;if(n&&n.length)for(var o=0,a=n.length;o<a;o++){var i=n[o],s=i.props,l=i.item,c=void 0!==l.type.defaultProps?B0(B0({},l.type.defaultProps),l.props):l.props,u=IO(l.type);if("Bar"===u){var d=(s.data||[]).find(function(t){return AW(e,t)});if(d)return{graphicalItem:i,payload:d}}else if("RadialBar"===u){var p=(s.data||[]).find(function(t){return kq(e,t)});if(p)return{graphicalItem:i,payload:p}}else if(lK(i,r)||cK(i,r)||uK(i,r)){var f=gK({graphicalItem:i,activeTooltipItem:r,itemData:c.data}),g=void 0===c.activeIndex?f:c.activeIndex;return{graphicalItem:B0(B0({},i),{},{childIndex:g}),payload:uK(i,r)?c.data[f]:i.props.data[f]}}}return null}},{key:"render",value:function(){var t=this;if(!DO(this))return null;var n,r,o=this.props,a=o.children,i=o.className,s=o.width,l=o.height,c=o.style,u=o.compact,d=o.title,p=o.desc,f=I0(o,A0),g=FO(f,!1);if(u)return e.createElement(TZ,{state:this.state,width:this.props.width,height:this.props.height,clipPathId:this.clipPathId},e.createElement(HO,O0({},g,{width:s,height:l,title:d,desc:p}),this.renderClipPath(),zO(a,this.renderMap)));this.props.accessibilityLayer&&(g.tabIndex=null!==(n=this.props.tabIndex)&&void 0!==n?n:0,g.role=null!==(r=this.props.role)&&void 0!==r?r:"application",g.onKeyDown=function(e){t.accessibilityManager.keyboardEvent(e)},g.onFocus=function(){t.accessibilityManager.focus()});var h=this.parseEventsOfWrapper();return e.createElement(TZ,{state:this.state,width:this.props.width,height:this.props.height,clipPathId:this.clipPathId},e.createElement("div",O0({className:hk("recharts-wrapper",i),style:B0({position:"relative",cursor:"default",width:s,height:l},c)},h,{ref:function(e){t.container=e}}),e.createElement(HO,O0({},g,{width:s,height:l,title:d,desc:p,style:G0}),this.renderClipPath(),zO(a,this.renderMap)),this.renderLegend(),this.renderTooltip()))}}])}(e.Component);U0(g,"displayName",n),U0(g,"defaultProps",B0({layout:"horizontal",stackOffset:"none",barCategoryGap:"10%",barGap:4,margin:{top:5,right:5,bottom:5,left:5},reverseStackOrder:!1,syncMethod:"index"},d)),U0(g,"getDerivedStateFromProps",function(e,t){var n=e.dataKey,r=e.data,o=e.children,a=e.width,i=e.height,s=e.layout,l=e.stackOffset,c=e.margin,u=t.dataStartIndex,d=t.dataEndIndex;if(void 0===t.updateId){var p=Q0(e);return B0(B0(B0({},p),{},{updateId:0},f(B0(B0({props:e},p),{},{updateId:0}),t)),{},{prevDataKey:n,prevData:r,prevWidth:a,prevHeight:i,prevLayout:s,prevStackOffset:l,prevMargin:c,prevChildren:o})}if(n!==t.prevDataKey||r!==t.prevData||a!==t.prevWidth||i!==t.prevHeight||s!==t.prevLayout||l!==t.prevStackOffset||!mO(c,t.prevMargin)){var g=Q0(e),h={chartX:t.chartX,chartY:t.chartY,isTooltipActive:t.isTooltipActive},m=B0(B0({},K0(t,r,s)),{},{updateId:t.updateId+1}),b=B0(B0(B0({},g),h),m);return B0(B0(B0({},b),f(B0({props:e},b),t)),{},{prevDataKey:n,prevData:r,prevWidth:a,prevHeight:i,prevLayout:s,prevStackOffset:l,prevMargin:c,prevChildren:o})}if(!BO(o,t.prevChildren)){var y,v,w,S,x=LO(o,eX),E=x&&null!==(y=null===(v=x.props)||void 0===v?void 0:v.startIndex)&&void 0!==y?y:u,k=x&&null!==(w=null===(S=x.props)||void 0===S?void 0:S.endIndex)&&void 0!==w?w:d,A=E!==u||k!==d,T=!GT(r)&&!A?t.updateId:t.updateId+1;return B0(B0({updateId:T},f(B0(B0({props:e},t),{},{updateId:T,dataStartIndex:E,dataEndIndex:k}),t)),{},{prevChildren:o,dataStartIndex:E,dataEndIndex:k})}return null}),U0(g,"renderActiveDot",function(t,n,r){var o;return o=e.isValidElement(t)?e.cloneElement(t,n):Vk(t)?t(n):e.createElement(jW,n),e.createElement(KO,{className:"recharts-active-dot",key:r},o)});var h=e.forwardRef(function(t,n){return e.createElement(g,O0({},t,{ref:n}))});return h.displayName=g.displayName,h},r1=n1({chartName:"LineChart",GraphicalChild:SJ,axisComponents:[{axisType:"xAxis",AxisComp:YJ},{axisType:"yAxis",AxisComp:a0}],formatAxisMap:nZ}),o1=n1({chartName:"BarChart",GraphicalChild:KX,defaultTooltipEventType:"axis",validateTooltipEventTypes:["axis","item"],axisComponents:[{axisType:"xAxis",AxisComp:YJ},{axisType:"yAxis",AxisComp:a0}],formatAxisMap:nZ}),a1=n1({chartName:"PieChart",GraphicalChild:TK,validateTooltipEventTypes:["item"],defaultTooltipEventType:"item",legendContent:"children",axisComponents:[{axisType:"angleAxis",AxisComp:CY},{axisType:"radiusAxis",AxisComp:gY}],formatAxisMap:function(e,t,n,r,o){var a=e.width,i=e.height,s=e.startAngle,l=e.endAngle,c=dO(e.cx,a,a/2),u=dO(e.cy,i,i/2),d=Sq(a,i,n),p=dO(e.innerRadius,d,0),f=dO(e.outerRadius,d,.8*d);return Object.keys(t).reduce(function(e,n){var a,i=t[n],d=i.domain,g=i.reversed;if(GT(i.range))"angleAxis"===r?a=[s,l]:"radiusAxis"===r&&(a=[p,f]),g&&(a=[a[1],a[0]]);else{var h=mq(a=i.range,2);s=h[0],l=h[1]}var m=ZG(i,o),b=m.realScaleType,y=m.scale;y.domain(d).range(a),JG(y);var v=nq(y,gq(gq({},i),{},{realScaleType:b})),w=gq(gq(gq({},i),v),{},{range:a,radius:f,realScaleType:b,scale:y,cx:c,cy:u,innerRadius:p,outerRadius:f,startAngle:s,endAngle:l});return gq(gq({},e),{},hq({},n,w))},{})},defaultProps:{layout:"centric",startAngle:0,endAngle:360,cx:"50%",cy:"50%",innerRadius:0,outerRadius:"80%"}}),i1=n1({chartName:"AreaChart",GraphicalChild:jJ,axisComponents:[{axisType:"xAxis",AxisComp:YJ},{axisType:"yAxis",AxisComp:a0}],formatAxisMap:nZ});function s1(e){return e>=1e6?"".concat((e/1e6).toFixed(1),"M"):e>=1e3?"".concat((e/1e3).toFixed(1),"k"):String(e)}const l1=/(^|[_\W])(price|salary|cost|amount|revenue|expense|total|value|budget|spend|income|sale|balance)/i;function c1(e){return"string"==typeof e&&l1.test(e)}function u1(e){return"$".concat(s1(e))}function d1(e){return"$".concat(Number(e).toLocaleString("en-US",{maximumFractionDigits:2}))}function p1(e){let{props:t,isDark:r=!1}=e;const o=Array.isArray(t.data)?t.data:[],a=c1(t.yKey),i=t.valueLabel||void 0,s=r?"#374151":"#e2e8f0",l=r?"#1f2937":"#ffffff",c=r?"#9ca3af":"#64748b",u=r?"#f3f4f6":"#0f172a",d=r?"#374151":"#e2e8f0",p=r?"#111827":"#ffffff";if(0===o.length)return n.jsxs("div",{style:{borderRadius:8,border:"1px solid ".concat(s),background:l,padding:12,margin:"8px 0"},children:[t.title&&n.jsx("div",{style:{fontSize:13,fontWeight:600,color:u,marginBottom:8},children:t.title}),n.jsx("div",{style:{color:c,fontSize:12},children:"No chartable data"})]});const f=o.some(e=>{var t;return String(null!==(t=e.label)&&void 0!==t?t:"").length>10}),g=f?-35:0,h=f?"end":"middle",m=f?48:20,b=f?250:220;return n.jsxs("div",{style:{borderRadius:8,border:"1px solid ".concat(s),background:l,padding:12,margin:"8px 0"},children:[t.title&&n.jsx("h3",{style:{fontSize:13,fontWeight:600,color:u,marginBottom:8,marginTop:0},children:t.title}),n.jsx("div",{style:{height:b,width:"100%"},children:n.jsx(EM,{width:"100%",height:"100%",children:n.jsxs(o1,{data:o,margin:{top:16,right:12,left:12,bottom:m},children:[n.jsx(oJ,{strokeDasharray:"3 3",stroke:d}),n.jsx(YJ,{dataKey:"label",tick:{fontSize:11,fill:c},angle:g,textAnchor:h,interval:0,tickFormatter:e=>String(null!=e?e:"").replace(/[_\-]+/g," ").replace(/\b\w/g,e=>e.toUpperCase()),label:t.xAxisLabel?{value:t.xAxisLabel,position:"insideBottom",offset:-12,fontSize:11,fill:c}:void 0}),n.jsx(a0,{width:72,tick:{fontSize:11,fill:c},label:t.yAxisLabel?{value:t.yAxisLabel,angle:-90,position:"insideLeft",fontSize:11,fill:c}:void 0,tickFormatter:e=>a?u1(e):t.unit?"".concat(s1(e)," ").concat(t.unit):s1(e)}),n.jsx(WD,{formatter:e=>a?d1(e):t.unit?"".concat(Number(e).toLocaleString()," ").concat(t.unit):Number(e).toLocaleString(),contentStyle:{background:p,border:"1px solid ".concat(s),borderRadius:6,fontSize:12,color:u}}),n.jsx(KX,{dataKey:"value",name:i,fill:"#3b82f6",radius:[2,2,0,0],label:{position:"top",fill:c,fontSize:10,formatter:e=>a?u1(e):s1(e)}})]})})})]})}function f1(e){let{props:t,isDark:r=!1}=e;const o=t.trend,a="up"===o?"#059669":"down"===o?"#e11d48":"#64748b",i="up"===o?"↑":"down"===o?"↓":"flat"===o?"→":null,s=r?"#374151":"#e2e8f0",l=r?"#1f2937":"#ffffff",c=r?"#f3f4f6":"#0f172a";return n.jsxs("div",{style:{borderRadius:8,border:"1px solid ".concat(s),background:l,padding:12,margin:"8px 0"},children:[n.jsx("p",{style:{fontSize:11,fontWeight:500,color:"#64748b",textTransform:"uppercase",letterSpacing:"0.05em",margin:0},children:t.label}),n.jsx("p",{style:{marginTop:4,fontSize:28,fontWeight:700,color:c,lineHeight:1.1,marginBottom:0},children:t.value}),t.change&&n.jsxs("p",{style:{marginTop:4,fontSize:12,color:a,marginBottom:0},children:[i&&n.jsx("span",{style:{marginRight:4},children:i}),t.change]})]})}const g1=["#3b82f6","#10b981","#f59e0b","#ef4444","#8b5cf6","#ec4899","#14b8a6","#f97316","#6366f1","#84cc16","#06b6d4","#a855f7"];function h1(e){let{props:t,isDark:r=!1,donut:o=!1}=e;const a=Array.isArray(t.data)?t.data:[],i=c1(t.yKey),s=r?"#374151":"#e2e8f0",l=r?"#1f2937":"#ffffff",c=r?"#f3f4f6":"#0f172a",u=r?"#111827":"#ffffff",d=r?"#9ca3af":"#64748b",p=a.map(e=>({name:e.label,value:e.value})),f=Math.PI/180;return n.jsxs("div",{style:{borderRadius:8,border:"1px solid ".concat(s),background:l,padding:12,margin:"8px 0"},children:[t.title&&n.jsx("h3",{style:{fontSize:13,fontWeight:600,color:c,marginBottom:8,marginTop:0},children:t.title}),n.jsx("div",{style:{height:260,width:"100%"},children:n.jsx(EM,{width:"100%",height:"100%",children:n.jsxs(a1,{children:[n.jsx(TK,{data:p,dataKey:"value",nameKey:"name",cx:"50%",cy:"50%",outerRadius:72,innerRadius:o?40:0,paddingAngle:2,labelLine:!1,label:e=>{const t=Number(e&&e.value),a=(s=t,l=Number(e&&e.percent),Number.isFinite(s)&&0!==s?Number.isFinite(l)&&l<.08?"outside":"inside":"none");var s,l;if("none"===a)return null;const c=Number(e.innerRadius)||0,u=Number(e.outerRadius)||0,d=Number(e.cx),p=Number(e.cy),g=-Number(e.midAngle)*f,h=Math.cos(g),m=Math.sin(g),b=i?d1(t):Number(t).toLocaleString();if("inside"===a){const e=c+(u-c)*(o?.78:.6);return n.jsx("text",{x:d+e*h,y:p+e*m,fill:"#ffffff",textAnchor:"middle",dominantBaseline:"central",style:{fontSize:11,fontWeight:600,pointerEvents:"none"},children:b})}const y="string"==typeof e.fill&&e.fill?e.fill:r?"#9ca3af":"#64748b",v=u+8,w=d+v*h,S=p+v*m,x=h>=0,E=w+(x?6:-6);return n.jsxs("g",{style:{pointerEvents:"none"},children:[n.jsx("polyline",{points:"".concat(d+u*h,",").concat(p+u*m," ").concat(w,",").concat(S," ").concat(E,",").concat(S),stroke:y,strokeWidth:1,fill:"none"}),n.jsx("text",{x:E+(x?2:-2),y:S,fill:y,textAnchor:x?"start":"end",dominantBaseline:"central",style:{fontSize:10,fontWeight:600},children:b})]})},isAnimationActive:!1,children:p.map((e,t)=>n.jsx(kM,{fill:g1[t%g1.length]},t))}),n.jsx(WD,{formatter:e=>i?d1(e):Number(e).toLocaleString(),contentStyle:{background:u,border:"1px solid ".concat(s),borderRadius:6,fontSize:12,color:c}}),n.jsx(sL,{iconSize:10,iconType:"circle",wrapperStyle:{fontSize:11,color:d}})]})})})]})}function m1(e){let{props:t,isDark:r=!1,area:o=!1}=e;const a=Array.isArray(t.data)?t.data:[],i=c1(t.yKey),s=t.valueLabel||void 0,l=r?"#374151":"#e2e8f0",c=r?"#1f2937":"#ffffff",u=r?"#9ca3af":"#64748b",d=r?"#f3f4f6":"#0f172a",p=r?"#374151":"#e2e8f0",f=r?"#111827":"#ffffff";if(0===a.length)return n.jsxs("div",{style:{borderRadius:8,border:"1px solid ".concat(l),background:c,padding:12,margin:"8px 0"},children:[t.title&&n.jsx("div",{style:{fontSize:13,fontWeight:600,color:d,marginBottom:8},children:t.title}),n.jsx("div",{style:{color:u,fontSize:12},children:"No chartable data"})]});const g=o?i1:r1;return n.jsxs("div",{style:{borderRadius:8,border:"1px solid ".concat(l),background:c,padding:12,margin:"8px 0"},children:[t.title&&n.jsx("h3",{style:{fontSize:13,fontWeight:600,color:d,marginBottom:8,marginTop:0},children:t.title}),n.jsx("div",{style:{height:220,width:"100%"},children:n.jsx(EM,{width:"100%",height:"100%",children:n.jsxs(g,{data:a,margin:{top:8,right:12,left:12,bottom:20},children:[n.jsx(oJ,{strokeDasharray:"3 3",stroke:p}),n.jsx(YJ,{dataKey:"label",tick:{fontSize:11,fill:u},angle:0,textAnchor:"middle",interval:0,label:t.xAxisLabel?{value:t.xAxisLabel,position:"insideBottom",offset:-12,fontSize:11,fill:u}:void 0}),n.jsx(a0,{width:72,tick:{fontSize:11,fill:u},tickFormatter:e=>i?u1(e):t.unit?"".concat(s1(e)," ").concat(t.unit):s1(e)}),n.jsx(WD,{formatter:e=>i?d1(e):t.unit?"".concat(Number(e).toLocaleString()," ").concat(t.unit):Number(e).toLocaleString(),contentStyle:{background:f,border:"1px solid ".concat(l),borderRadius:6,fontSize:12,color:d}}),o?n.jsx(jJ,{type:"monotone",dataKey:"value",name:s,stroke:"#3b82f6",fill:"#3b82f6",fillOpacity:.15,strokeWidth:2,dot:{r:3,fill:"#3b82f6"}}):n.jsx(SJ,{type:"monotone",dataKey:"value",name:s,stroke:"#3b82f6",strokeWidth:2,dot:{r:3,fill:"#3b82f6"},activeDot:{r:5}})]})})})]})}const b1=/\b(?:field|fields|column|columns|table|tables|sql|summed?|aggregat\w*|averaged?|counted)\b/i,y1=/[A-Za-z_]\w*\.[A-Za-z_]\w*/;function v1(e){if("string"!=typeof e)return"";let t,n=e.trim();do{t=n,n=n.replace(/\s*\(([^()]*)\)\s*$/,(e,t)=>b1.test(t)||y1.test(t)?"":e).trim()}while(n!==t);return n}function w1(e){return"string"==typeof e&&/^https?:\/\//i.test(e)?e:void 0}function S1(e){let{spec:t,isDark:r=!1,onButtonClick:o}=e;if(!t||"object"!=typeof t)return null;t=c(c({},t),{},{title:v1(t.title)});const a=String(t.type||"").trim().toLowerCase().replace(/_/g,"-"),i=new Set(["bar","line","area","pie","donut","scatter","bubble","radar","radial-bar","radial","radialbar","treemap","funnel","sankey","composed","waterfall","gauge","histogram","kpi"]);if("revenue-insights"===a)return n.jsx(u2,{spec:t,isDark:r});if("impact-analysis"===a)return n.jsx(p2,{spec:t,isDark:r});if("deviation-analysis"===a)return n.jsx(f2,{spec:t,isDark:r});if("main-drivers"===a)return n.jsx(g2,{spec:t,isDark:r});if("key-observations"===a)return n.jsx(m2,{spec:t,isDark:r});if("recommendations"===a)return n.jsx(b2,{spec:t,isDark:r});if("kpi"===a){var s,l,u,d,p;const e=null!==(s=null!==(l=null!==(u=t.value)&&void 0!==u?u:t.amount)&&void 0!==l?l:t.metric)&&void 0!==s?s:t.kpi,o=null!=t.delta?Number(t.delta):null,a=null!==(d=t.change)&&void 0!==d?d:null!=o&&Number.isFinite(o)?o>=0?"+".concat(o):String(o):void 0,i=null!==(p=t.trend)&&void 0!==p?p:null!=o&&Number.isFinite(o)?o>0?"up":o<0?"down":"flat":void 0;return n.jsx(f1,{props:{label:t.label||t.title||"",value:null!=e?String(e):"-",change:a,trend:i},isDark:r})}return"table"===a?n.jsx(k1,{spec:t,isDark:r}):i.has(a)||Array.isArray(t.data)&&t.data.length>0?n.jsx(E1,{spec:t,type:a,isDark:r}):"alert"===a?n.jsx(A1,{spec:t,isDark:r}):"card"===a?n.jsx(C1,{spec:t,isDark:r,onButtonClick:o}):"button-group"===a?n.jsx(I1,{spec:t,isDark:r,onButtonClick:o}):"form"===a?n.jsx(N1,{spec:t,isDark:r}):"confirmation"===a?n.jsx(_1,{spec:t,isDark:r,onButtonClick:o}):"menu"===a?n.jsx(j1,{spec:t,isDark:r,onButtonClick:o}):"profile"===a?n.jsx(F1,{spec:t,isDark:r,onButtonClick:o}):"timeline"===a?n.jsx(B1,{spec:t,isDark:r}):"rating"===a?n.jsx(U1,{spec:t,isDark:r}):"comparison"===a?n.jsx(z1,{spec:t,isDark:r,onButtonClick:o}):"gallery"===a?n.jsx($1,{spec:t,isDark:r}):Array.isArray(t.data)&&t.data.length>0?n.jsx(E1,{spec:t,type:"bar",isDark:r}):null}const x1=e=>({border:e?"1px solid #374151":"1px solid #e5e7eb",background:e?"#1f2937":"#ffffff",borderRadius:8,padding:12,margin:"8px 0",fontSize:13,color:e?"#f3f4f6":"#111827"});function E1(e){let{spec:t,type:r,isDark:o}=e;const{x:a,y:i}=function(e,t,n){if(!Array.isArray(e)||0===e.length)return{x:"name",y:"value"};const r=e[0]||{};if(t&&Object.prototype.hasOwnProperty.call(r,t)&&n&&Object.prototype.hasOwnProperty.call(r,n))return{x:t,y:n};let o=t||null,a=n||null;for(const e of Object.keys(r)){const t=r[e];null!=o||"string"!=typeof t&&null!=t||(o=e),null==a&&"number"==typeof t&&Number.isFinite(t)&&(a=e)}return{x:o||"name",y:a||"value"}}(t.data,t.x,t.y),s=function(e,t,n){return(e||[]).map(e=>({label:Y1(null==e?void 0:e[t],t),value:Number(null==e?void 0:e[n])})).filter(e=>Number.isFinite(e.value))}(t.data,a,i),l=String(r||"").trim().toLowerCase(),c={title:t.title,data:s,unit:t.unit,xAxisLabel:t.xAxisLabel,yAxisLabel:t.yAxisLabel,yKey:i,valueLabel:V1(i)};return"pie"===l?n.jsx(h1,{props:c,isDark:o,donut:!1}):"donut"===l?n.jsx(h1,{props:c,isDark:o,donut:!0}):"line"===l?n.jsx(m1,{props:c,isDark:o,area:!1}):"area"===l?n.jsx(m1,{props:c,isDark:o,area:!0}):n.jsx(p1,{props:c,isDark:o})}function k1(e){let{spec:t,isDark:r}=e;const o=Array.isArray(t.columns)&&t.columns.length>0?t.columns:Array.isArray(t.data)&&t.data[0]?Object.keys(t.data[0]):[],a=Array.isArray(t.data)?t.data:Array.isArray(t.rows)?t.rows:[];if(0===o.length||0===a.length)return n.jsx("div",{style:x1(r),children:n.jsx("div",{style:{color:r?"#9ca3af":"#6b7280",fontSize:12},children:"Empty table"})});const i=r?"1px solid #374151":"1px solid #e5e7eb";return n.jsxs("div",{style:x1(r),children:[t.title&&n.jsx("div",{style:{fontWeight:600,marginBottom:8},children:t.title}),n.jsx("div",{style:{overflowX:"auto"},children:n.jsxs("table",{style:{borderCollapse:"collapse",width:"100%",fontSize:12},children:[n.jsx("thead",{children:n.jsx("tr",{children:o.map(e=>n.jsx("th",{style:{border:i,padding:"6px 8px",background:"transparent",textAlign:"left",fontWeight:600},children:V1(e)},e))})}),n.jsx("tbody",{children:a.map((e,t)=>n.jsx("tr",{children:o.map(t=>n.jsx("td",{style:{border:i,padding:"6px 8px"},children:e&&"object"==typeof e?e2(e[t],t):""},t))},t))})]})})]})}function A1(e){let{spec:t,isDark:r}=e;const o=String(t.level||"info").toLowerCase(),a={info:{bg:r?"hsl(204 33% 14%)":"hsl(204 100% 97%)",border:r?"hsl(199 89% 58%)":"hsl(199 89% 48%)",text:r?"#bae6fd":"#0c4a6e"},warn:{bg:r?"hsl(36 33% 14%)":"hsl(34 100% 95%)",border:r?"hsl(38 92% 60%)":"hsl(35 100% 50%)",text:r?"#fde68a":"#663c00"},error:{bg:r?"hsl(356 33% 16%)":"hsl(356 100% 97%)",border:r?"hsl(350 89% 65%)":"hsl(350 89% 60%)",text:r?"#fecdd3":"#9f1239"},success:{bg:r?"hsl(152 36% 14%)":"hsl(152 81% 96%)",border:r?"hsl(158 64% 52%)":"hsl(160 84% 39%)",text:r?"#a7f3d0":"#065f46"}};a.warning=a.warn;const i=a[o]||a.info;return n.jsxs("div",{style:c(c({},x1(r)),{},{background:i.bg,borderLeft:"4px solid ".concat(i.border),color:i.text}),children:[t.title&&n.jsx("div",{style:{fontWeight:600,marginBottom:4},children:t.title}),t.body&&n.jsx("div",{style:{fontSize:12,lineHeight:1.6,whiteSpace:"pre-wrap",wordBreak:"break-word"},children:String(t.body)})]})}const T1=e=>({success:{bg:e?"hsl(152 36% 14%)":"hsl(152 81% 96%)",fg:e?"hsl(158 64% 52%)":"hsl(160 84% 39%)"},warn:{bg:e?"hsl(36 33% 14%)":"hsl(34 100% 95%)",fg:e?"hsl(38 92% 60%)":"hsl(35 100% 50%)"},error:{bg:e?"hsl(356 33% 16%)":"hsl(356 100% 97%)",fg:e?"hsl(350 89% 65%)":"hsl(350 89% 60%)"},info:{bg:e?"hsl(204 33% 14%)":"hsl(204 100% 97%)",fg:e?"hsl(199 89% 58%)":"hsl(199 89% 48%)"}}),O1={calendar:ve,ticket:$e,check:ke};function C1(t){let{spec:r,isDark:o,onButtonClick:a}=t;const i=Array.isArray(r.fields)?r.fields:[],s=Array.isArray(r.actions)?r.actions:[],l=r.status,u=r.icon?O1[r.icon]:null,[d,p]=e.useState(!1),f=String(r.body||"").trim(),g=String(r.details||"").trim(),h=f.length>0&&g.length>f.length+2,m=w1(r.image),b=l&&l.label?T1(o)[l.variant||"success"]:null;return n.jsxs("div",{style:c(c({},x1(o)),{},{minWidth:0,overflow:"hidden"}),children:[m&&n.jsx("img",{src:m,alt:r.title||"",referrerPolicy:"no-referrer",onError:e=>{e.currentTarget.style.display="none"},style:{display:"block",margin:"-12px -12px 12px",width:"calc(100% + 24px)",height:140,objectFit:"contain",background:o?"rgba(31,41,55,0.4)":"#f9fafb"}}),(r.title||b)&&n.jsxs("div",{style:{display:"flex",alignItems:"center",justifyContent:"space-between",gap:8,marginBottom:8},children:[n.jsxs("div",{style:{display:"flex",alignItems:"center",gap:6,minWidth:0},children:[u&&n.jsx(u,{size:14,style:{flexShrink:0,color:o?"#60a5fa":R1}}),r.title&&n.jsx("div",{style:{fontWeight:600,minWidth:0,overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},children:r.title})]}),b&&n.jsx("span",{style:{flexShrink:0,borderRadius:999,padding:"1px 8px",fontSize:10,fontWeight:500,background:b.bg,color:b.fg},children:l.label})]}),(f||g)&&n.jsxs("div",{children:[n.jsx("div",{style:{fontSize:12,lineHeight:1.6,whiteSpace:"pre-wrap",wordBreak:"break-word"},children:d?g||f:f||g}),h&&n.jsx("button",{type:"button",onClick:()=>p(e=>!e),style:{marginTop:4,padding:0,border:"none",background:"none",fontSize:11,fontWeight:500,color:o?"#60a5fa":R1,cursor:"pointer"},children:d?"Show less":"Show more"})]}),i.length>0&&n.jsx("div",{style:{display:"grid",gridTemplateColumns:"auto 1fr",columnGap:12,rowGap:6,marginTop:f||g?12:0},children:i.map((t,r)=>n.jsxs(e.Fragment,{children:[n.jsx("div",{style:{fontSize:11,fontWeight:500,color:o?"#9ca3af":"#6b7280",whiteSpace:"nowrap"},children:t.label}),n.jsx("div",{style:{fontSize:12,minWidth:0,wordBreak:"break-word"},children:t.value})]},r))}),s.length>0&&n.jsx("div",{style:{display:"flex",flexWrap:"wrap",gap:8,marginTop:12},children:s.map((e,t)=>{const r="secondary"!==e.variant,i={display:"inline-flex",alignItems:"center",padding:"6px 12px",borderRadius:6,fontSize:11,fontWeight:500,textDecoration:"none",border:"1px solid "+(r?R1:o?"#4b5563":"#d1d5db"),background:r?R1:o?"#1f2937":"#ffffff",color:r?"#ffffff":o?"#e5e7eb":"#374151"},s=w1(e.url);if(s)return n.jsx("a",{href:s,target:"_blank",rel:"noopener noreferrer",style:i,children:e.label},t);const l=e.value||e.label;return n.jsx("button",{type:"button",onClick:a?()=>{var t;return a(String(null!=l?l:""),String(null!==(t=e.label)&&void 0!==t?t:""))}:void 0,disabled:!a,title:a?void 0:"Action (no handler wired)",style:c(c({},i),{},{cursor:a?"pointer":"default",opacity:a?1:.5}),children:e.label},t)})})]})}function I1(e){let{spec:t,isDark:r,onButtonClick:o}=e;const a=Array.isArray(t.buttons)?t.buttons:[];return 0===a.length?null:n.jsxs("div",{style:{margin:"8px 0"},children:[t.title&&n.jsx("div",{style:{fontSize:11,color:r?"#9ca3af":"#6b7280",textTransform:"uppercase",letterSpacing:"0.05em",marginBottom:6},children:t.title}),n.jsx("div",{style:{display:"flex",flexWrap:"wrap",gap:6},children:a.map((e,t)=>{var a,i;return n.jsx("button",{type:"button",onClick:o?()=>{var t,n,r,a;return o(String(null!==(t=null!==(n=e.value)&&void 0!==n?n:e.label)&&void 0!==t?t:""),String(null!==(r=null!==(a=e.label)&&void 0!==a?a:e.value)&&void 0!==r?r:""))}:void 0,disabled:!o,style:{border:"1px solid "+(r?"#374151":"#d1d5db"),background:r?"#1f2937":"#ffffff",color:r?"#f3f4f6":"#111827",padding:"6px 12px",borderRadius:6,fontSize:12,cursor:o?"pointer":"default",opacity:o?1:.6},children:String(null!==(a=null!==(i=e.label)&&void 0!==i?i:e.value)&&void 0!==a?a:"")},t)})})]})}function N1(e){let{spec:t,isDark:r}=e;const o=(Array.isArray(t.fields)?t.fields:[]).filter(e=>e&&"hidden"!==e.type);return n.jsxs("div",{style:x1(r),children:[t.title&&n.jsx("div",{style:{fontWeight:600,marginBottom:8},children:t.title}),o.map((e,t)=>{var o,a;return n.jsxs("div",{style:{marginBottom:4,fontSize:12},children:[n.jsxs("span",{style:{color:r?"#9ca3af":"#6b7280"},children:[e.label||e.name,": "]}),n.jsx("span",{children:String(null!==(o=null!==(a=e.value)&&void 0!==a?a:e.placeholder)&&void 0!==o?o:"")})]},t)})]})}function _1(e){let{spec:t,isDark:r,onButtonClick:o}=e;const a=t.yes||{label:"Yes",value:"yes"},i=t.no||{label:"No",value:"no"};return n.jsxs("div",{style:x1(r),children:[t.title&&n.jsx("div",{style:{fontWeight:600,marginBottom:6},children:t.title}),t.body&&n.jsx("div",{style:{fontSize:12,lineHeight:1.6,marginBottom:8,whiteSpace:"pre-wrap",wordBreak:"break-word"},children:String(t.body)}),n.jsx(I1,{spec:{buttons:[a,i]},isDark:r,onButtonClick:o})]})}const R1="#2563eb";function P1(e){return{display:"inline-flex",alignItems:"center",borderRadius:999,padding:"2px 8px",fontSize:10,fontWeight:600,background:e?"rgba(37,99,235,0.20)":"#eff6ff",color:e?"#93c5fd":"#1d4ed8"}}function L1(e,t){return{display:"inline-flex",alignItems:"center",justifyContent:"center",padding:"6px 12px",borderRadius:6,fontSize:12,fontWeight:600,border:"none",background:R1,color:"#ffffff",cursor:t?"default":"pointer",opacity:t?.5:1}}function D1(e,t){return{display:"inline-flex",alignItems:"center",justifyContent:"center",padding:"6px 12px",borderRadius:6,fontSize:12,fontWeight:600,border:"1px solid "+(e?"#374151":"#d1d5db"),background:e?"#1f2937":"#ffffff",color:e?"#f3f4f6":"#111827",textDecoration:"none",cursor:t?"default":"pointer",opacity:t?.5:1}}function M1(e){let{score:t,maxScore:r=5,size:o=14,isDark:a}=e;const i=[];for(let e=0;e<r;e+=1){const r=t>=e+1,s=!r&&t>e&&t<e+1;i.push(n.jsxs("svg",{width:o,height:o,viewBox:"0 0 24 24",fill:r?"#fbbf24":s?"url(#a2ui-half-star-".concat(e,")"):"none",stroke:r||s?"#fbbf24":a?"#4b5563":"#d1d5db",strokeWidth:"1.5",children:[s&&n.jsx("defs",{children:n.jsxs("linearGradient",{id:"a2ui-half-star-".concat(e),children:[n.jsx("stop",{offset:"50%",stopColor:"#fbbf24"}),n.jsx("stop",{offset:"50%",stopColor:"transparent"})]})}),n.jsx("polygon",{points:"12 2 15.09 8.26 22 9.27 17 14.14 18.18 21.02 12 17.77 5.82 21.02 7 14.14 2 9.27 8.91 8.26 12 2"})]},e))}return n.jsx("div",{style:{display:"flex",alignItems:"center",gap:1},children:i})}function j1(e){let{spec:t,isDark:r,onButtonClick:o}=e;const a=Array.isArray(t.items)?t.items:[];if(0===a.length)return null;const i=r?"1px solid #374151":"1px solid #e5e7eb",s=r?"#9ca3af":"#6b7280";return n.jsxs("div",{style:{margin:"8px 0"},children:[(t.title||t.subtitle)&&n.jsxs("div",{style:{marginBottom:8},children:[t.title&&n.jsx("div",{style:{fontSize:13,fontWeight:700},children:t.title}),t.subtitle&&n.jsx("div",{style:{fontSize:11,color:s},children:t.subtitle})]}),n.jsx("div",{style:{display:"grid",gridTemplateColumns:"repeat(auto-fit, minmax(160px, 1fr))",gap:10},children:a.map((e,t)=>n.jsxs("div",{style:{border:i,borderRadius:10,overflow:"hidden",background:r?"#1f2937":"#ffffff",display:"flex",flexDirection:"column"},children:[w1(e.image)&&n.jsx("img",{src:w1(e.image),alt:e.name||"",referrerPolicy:"no-referrer",onError:e=>{e.currentTarget.style.display="none"},style:{height:96,width:"100%",objectFit:"cover",background:r?"#111827":"#f9fafb"}}),n.jsxs("div",{style:{padding:10,display:"flex",flexDirection:"column",gap:6,flex:1},children:[n.jsxs("div",{style:{display:"flex",justifyContent:"space-between",gap:6,alignItems:"flex-start"},children:[n.jsx("div",{style:{fontSize:12,fontWeight:700,minWidth:0},children:e.name}),e.price&&n.jsx("div",{style:{fontSize:12,fontWeight:700,color:R1,flexShrink:0},children:e.price})]}),e.description&&n.jsx("div",{style:{fontSize:11,color:s,lineHeight:1.4},children:e.description}),Array.isArray(e.tags)&&e.tags.length>0&&n.jsx("div",{style:{display:"flex",flexWrap:"wrap",gap:4},children:e.tags.map((e,t)=>n.jsx("span",{style:P1(r),children:e},t))}),n.jsx("div",{style:{flex:1}}),e.actionLabel&&n.jsx("button",{type:"button",onClick:o?()=>{var t;return o(String(null!==(t=e.value)&&void 0!==t?t:e.actionLabel),String(e.actionLabel))}:void 0,disabled:!o,style:c(c({},L1(0,!o)),{},{alignSelf:"flex-start",marginTop:4}),children:e.actionLabel})]})]},t))})]})}function F1(e){let{spec:t,isDark:r,onButtonClick:o}=e;const a=Array.isArray(t.tags)?t.tags:[],i=Array.isArray(t.actions)?t.actions:[],s=r?"#9ca3af":"#6b7280";return n.jsxs("div",{style:x1(r),children:[n.jsxs("div",{style:{display:"flex",gap:10,alignItems:"flex-start"},children:[n.jsx("div",{style:{flexShrink:0,height:44,width:44,borderRadius:"50%",overflow:"hidden",background:r?"rgba(37,99,235,0.20)":"#eff6ff",color:r?"#93c5fd":R1,display:"flex",alignItems:"center",justifyContent:"center",fontWeight:700,fontSize:16},children:w1(t.avatar)?n.jsx("img",{src:w1(t.avatar),alt:t.name||"",referrerPolicy:"no-referrer",onError:e=>{e.currentTarget.style.display="none"},style:{height:"100%",width:"100%",objectFit:"cover"}}):String(t.name||"").charAt(0).toUpperCase()}),n.jsxs("div",{style:{minWidth:0,flex:1},children:[n.jsx("div",{style:{fontSize:13,fontWeight:700},children:t.name}),t.role&&n.jsx("div",{style:{fontSize:11,color:s},children:t.role}),"number"==typeof t.rating&&n.jsxs("div",{style:{marginTop:4,display:"flex",alignItems:"center",gap:6},children:[n.jsx(M1,{score:t.rating,size:11,isDark:r}),n.jsxs("span",{style:{fontSize:10,color:s},children:[t.rating.toFixed(1),"number"==typeof t.reviewCount?" (".concat(t.reviewCount,")"):""]})]})]})]}),a.length>0&&n.jsx("div",{style:{display:"flex",flexWrap:"wrap",gap:4,marginTop:8},children:a.map((e,t)=>n.jsx("span",{style:P1(r),children:e},t))}),t.bio&&n.jsx("div",{style:{marginTop:8,fontSize:12,lineHeight:1.5},children:t.bio}),i.length>0&&n.jsx("div",{style:{display:"flex",flexWrap:"wrap",gap:6,marginTop:10},children:i.map((e,t)=>{const a="secondary"!==e.variant,i=w1(e.url);if(i)return n.jsx("a",{href:i,target:"_blank",rel:"noopener noreferrer",style:D1(r,!1),children:e.label},t);const s=e.value||e.label;return n.jsx("button",{type:"button",onClick:o?()=>o(String(s),String(e.label)):void 0,disabled:!o,style:a?L1(0,!o):D1(r,!o),children:e.label},t)})})]})}function B1(e){let{spec:t,isDark:r}=e;const o=Array.isArray(t.steps)?t.steps:[];if(0===o.length)return null;const a=r?"#374151":"#e5e7eb",i=r?"#6b7280":"#9ca3af",s=e=>"done"===e?{background:"#10b981",border:"2px solid #10b981"}:"active"===e?{background:R1,border:"2px solid ".concat(R1),boxShadow:r?"0 0 0 4px rgba(37,99,235,0.25)":"0 0 0 4px #dbeafe"}:{background:r?"#1f2937":"#ffffff",border:"2px solid "+(r?"#4b5563":"#d1d5db")};return n.jsxs("div",{style:x1(r),children:[t.title&&n.jsx("div",{style:{fontWeight:700,fontSize:13,marginBottom:10},children:t.title}),n.jsx("div",{children:o.map((e,t)=>{const l=e.status||(0===t?"done":"pending"),u=t===o.length-1;return n.jsxs("div",{style:{display:"flex",gap:10},children:[n.jsxs("div",{style:{display:"flex",flexDirection:"column",alignItems:"center"},children:[n.jsx("div",{style:c({height:12,width:12,borderRadius:"50%",flexShrink:0},s(l))}),!u&&n.jsx("div",{style:{width:1,flex:1,background:a,minHeight:16,margin:"2px 0"}})]}),n.jsxs("div",{style:{minWidth:0,flex:1,paddingBottom:u?0:12},children:[n.jsxs("div",{style:{display:"flex",justifyContent:"space-between",gap:6},children:[n.jsx("span",{style:{fontSize:12,fontWeight:600,color:"pending"===l?i:r?"#f3f4f6":"#111827"},children:e.label}),e.timestamp&&n.jsx("span",{style:{fontSize:10,color:i,flexShrink:0},children:e.timestamp})]}),e.description&&n.jsx("div",{style:{fontSize:11,color:r?"#9ca3af":"#6b7280",marginTop:2},children:e.description})]})]},t)})})]})}function U1(e){let{spec:t,isDark:r}=e;const o=t.maxScore||5,a=r?"#9ca3af":"#6b7280";return n.jsxs("div",{style:x1(r),children:[t.title&&n.jsx("div",{style:{fontSize:11,textTransform:"uppercase",letterSpacing:"0.05em",color:a,marginBottom:4},children:t.title}),n.jsxs("div",{style:{display:"flex",alignItems:"center",gap:8},children:[n.jsx("span",{style:{fontSize:22,fontWeight:700},children:Number(t.score).toFixed(1)}),n.jsx(M1,{score:t.score,maxScore:o,size:15,isDark:r}),"number"==typeof t.reviewCount&&n.jsxs("span",{style:{fontSize:11,color:a},children:["(",t.reviewCount," review",1===t.reviewCount?"":"s",")"]})]}),t.review&&n.jsxs("div",{style:{marginTop:8,borderLeft:"2px solid "+(r?"#1e40af":"#bfdbfe"),paddingLeft:10,fontSize:12,fontStyle:"italic",color:r?"#d1d5db":"#374151",lineHeight:1.5},children:['"',t.review,'"',t.author&&n.jsxs("div",{style:{marginTop:4,fontStyle:"normal",fontSize:10,color:a},children:["- ",t.author]})]})]})}function z1(e){let{spec:t,isDark:r,onButtonClick:o}=e;const a=Array.isArray(t.plans)?t.plans:[];if(0===a.length)return null;const i=r?"#9ca3af":"#6b7280";return n.jsxs("div",{style:{margin:"8px 0"},children:[t.title&&n.jsx("div",{style:{fontWeight:700,fontSize:13,marginBottom:8},children:t.title}),n.jsx("div",{style:{display:"grid",gridTemplateColumns:"repeat(auto-fit, minmax(150px, 1fr))",gap:10},children:a.map((e,t)=>n.jsxs("div",{style:{border:e.highlight?"1px solid ".concat(R1):"1px solid "+(r?"#374151":"#e5e7eb"),background:e.highlight?r?"rgba(37,99,235,0.10)":"#eff6ff":r?"#1f2937":"#ffffff",borderRadius:10,padding:12,display:"flex",flexDirection:"column"},children:[e.highlight&&n.jsx("span",{style:{alignSelf:"flex-start",marginBottom:6,background:R1,color:"#ffffff",fontSize:9,fontWeight:700,padding:"2px 7px",borderRadius:999},children:"Recommended"}),n.jsx("div",{style:{fontSize:13,fontWeight:700},children:e.name}),e.price&&n.jsxs("div",{style:{marginTop:2,display:"flex",alignItems:"baseline",gap:3},children:[n.jsx("span",{style:{fontSize:18,fontWeight:700},children:e.price}),e.period&&n.jsxs("span",{style:{fontSize:11,color:i},children:["/",e.period]})]}),Array.isArray(e.features)&&e.features.length>0&&n.jsx("ul",{style:{listStyle:"none",padding:0,margin:"8px 0 0",display:"flex",flexDirection:"column",gap:6,flex:1},children:e.features.map((e,t)=>n.jsxs("li",{style:{display:"flex",gap:6,alignItems:"flex-start",fontSize:11,color:r?"#d1d5db":"#374151"},children:[n.jsx("svg",{width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"#10b981",strokeWidth:"3",strokeLinecap:"round",strokeLinejoin:"round",style:{marginTop:2,flexShrink:0},children:n.jsx("polyline",{points:"20 6 9 17 4 12"})}),n.jsx("span",{children:e})]},t))}),e.actionLabel&&n.jsx("button",{type:"button",onClick:o?()=>{var t;return o(String(null!==(t=e.value)&&void 0!==t?t:e.actionLabel),String(e.actionLabel))}:void 0,disabled:!o,style:c(c({},e.highlight?L1(0,!o):D1(r,!o)),{},{marginTop:10}),children:e.actionLabel})]},t))})]})}function $1(e){let{spec:t,isDark:r}=e;const o=Array.isArray(t.images)?t.images:[];if(0===o.length)return null;const a=r?"#9ca3af":"#6b7280";return n.jsxs("div",{style:{margin:"8px 0"},children:[t.title&&n.jsx("div",{style:{fontWeight:700,fontSize:13,marginBottom:8},children:t.title}),n.jsx("div",{className:"slim-scrollbar-x",style:{display:"flex",gap:8,overflowX:"auto",paddingBottom:4},children:o.map((e,t)=>n.jsxs("figure",{style:{flexShrink:0,width:140,margin:0,borderRadius:8,overflow:"hidden",border:"1px solid "+(r?"#374151":"#e5e7eb"),background:r?"#111827":"#f9fafb"},children:[n.jsx("img",{src:w1(e.url),alt:e.caption||"Image ".concat(t+1),referrerPolicy:"no-referrer",onError:e=>{e.currentTarget.style.display="none"},style:{height:96,width:"100%",objectFit:"cover"}}),e.caption&&n.jsx("figcaption",{style:{padding:"5px 8px",fontSize:10,color:a,whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis"},children:e.caption})]},t))})]})}const G1=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],q1=/(^|[_\W])(price|salary|cost|amount|revenue|expense|total|value|budget|spend|income|sale|balance)/i,H1=/(^|[_\W])month/i;function V1(e){if(null==e)return"";const t=String(e);return t?t.replace(/[_\-]+/g," ").replace(/([a-z])([A-Z])/g,"$1 $2").replace(/\s+/g," ").trim().split(" ").map(e=>e.charAt(0).toUpperCase()+e.slice(1).toLowerCase()).join(" "):""}const W1=/^(\d{4})-(\d{2})(?:-\d{2})?(?:[T\s]|$)/;function Y1(e,t){if("string"==typeof t&&H1.test(t)){const t="number"==typeof e?e:Number(e);if(Number.isInteger(t)&&t>=1&&t<=12)return G1[t-1]}const n=function(e){if("string"!=typeof e)return null;const t=e.match(W1);if(!t)return null;const n=parseInt(t[1],10),r=parseInt(t[2],10);return!Number.isInteger(r)||r<1||r>12?null:"".concat(G1[r-1]," '").concat(String(n).slice(-2))}(e);return n||V1(e)}const K1=/^[a-z]+(_[a-z]+)+$/;const X1=/^-?\d+(\.\d+)?$/,Z1=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],Q1=/^\d{4}-\d{2}-\d{2}([T ]\d{2}:\d{2}(:\d{2})?(\.\d+)?(Z|[+-]\d{2}:?\d{2})?)?$/;function J1(e){return Number.isInteger(e)?e.toLocaleString("en-US"):Number(e.toFixed(2)).toLocaleString("en-US")}function e2(e,t){if(null==e)return"";if("number"==typeof e)return J1(e);if("object"==typeof e)return JSON.stringify(e);const n=String(e).trim(),r=function(e){if("string"!=typeof e)return null;const t=e.trim();if(!Q1.test(t))return null;const n=/[T ]\d{2}:\d{2}/.test(t),r=/(Z|[+-]\d{2}:?\d{2})$/.test(t),o=n&&!r?"".concat(t.replace(" ","T"),"Z"):t,a=new Date(o);if(isNaN(a.getTime()))return null;const i=n&&(0!==a.getUTCHours()||0!==a.getUTCMinutes()||0!==a.getUTCSeconds()),s="".concat(Z1[a.getUTCMonth()]," ").concat(a.getUTCDate(),", ").concat(a.getUTCFullYear());if(!i)return s;const l=a.getUTCHours(),c=l>=12?"PM":"AM",u=l%12||12,d=String(a.getUTCMinutes()).padStart(2,"0");return"".concat(s,", ").concat(u,":").concat(d," ").concat(c)}(n);if(r)return r;if("string"==typeof(o=t)&&q1.test(o)&&X1.test(n)){const e=Number(n);if(Number.isFinite(e))return J1(e)}var o,a;return"string"!=typeof(a=e)?String(null!=a?a:""):a.length>40?a:K1.test(a)?V1(a):a}function t2(e){let{size:t=14}=e;return n.jsxs("svg",{width:t,height:t,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:[n.jsx("polyline",{points:"22 7 13.5 15.5 8.5 10.5 2 17"}),n.jsx("polyline",{points:"16 7 22 7 22 13"})]})}function n2(e){let{size:t=14}=e;return n.jsxs("svg",{width:t,height:t,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:[n.jsx("path",{d:"M16 16c0-1.7-2-3-2-3"}),n.jsx("path",{d:"M8 16c0-1.7 2-3 2-3"}),n.jsx("path",{d:"M7 21h10"}),n.jsx("path",{d:"M12 3v18"}),n.jsx("path",{d:"m17 7 5 9h-10z"}),n.jsx("path",{d:"m7 7-5 9h10z"})]})}function r2(e){let{size:t=14}=e;return n.jsxs("svg",{width:t,height:t,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:[n.jsx("circle",{cx:"5",cy:"6",r:"3"}),n.jsx("circle",{cx:"19",cy:"18",r:"3"}),n.jsx("path",{d:"M12 6h5a2 2 0 0 1 2 2v7"}),n.jsx("path",{d:"M12 18H7a2 2 0 0 1-2-2V9"})]})}function o2(e){let{size:t=14}=e;return n.jsx("svg",{width:t,height:t,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:n.jsx("polygon",{points:"13 2 3 14 12 14 11 22 21 10 12 10 13 2"})})}function a2(e){let{size:t=14}=e;return n.jsxs("svg",{width:t,height:t,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:[n.jsx("path",{d:"M15 14c.2-1 .7-1.7 1.5-2.5 1-.9 1.5-2.2 1.5-3.5A6 6 0 0 0 6 8c0 1 .2 2.2 1.5 3.5.7.7 1.3 1.5 1.5 2.5"}),n.jsx("path",{d:"M9 18h6"}),n.jsx("path",{d:"M10 22h4"})]})}function i2(e){let{size:t=14}=e;return n.jsxs("svg",{width:t,height:t,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",children:[n.jsx("circle",{cx:"12",cy:"12",r:"10"}),n.jsx("circle",{cx:"12",cy:"12",r:"6"}),n.jsx("circle",{cx:"12",cy:"12",r:"2"})]})}function s2(e){let{type:t,icon:r,title:o,count:a,isDark:i,children:s}=e;const{accent:l,iconBg:c,iconFg:u}=function(e,t){const n={"revenue-insights":t?["#10b981","#064e3b","#a7f3d0"]:["#10b981","#ecfdf5","#065f46"],"impact-analysis":t?["#f59e0b","#78350f","#fde68a"]:["#f59e0b","#fef3c7","#92400e"],"deviation-analysis":t?["#3b82f6","#1e3a8a","#bfdbfe"]:["#3b82f6","#dbeafe","#1e40af"],"main-drivers":t?["#8b5cf6","#4c1d95","#ddd6fe"]:["#8b5cf6","#ede9fe","#5b21b6"],"key-observations":t?["#059669","#064e3b","#a7f3d0"]:["#059669","#f0fdf4","#14532d"],recommendations:t?["#818cf8","#312e81","#c7d2fe"]:["#4f46e5","#eef2ff","#4f46e5"]},[r,o,a]=n[e]||["#64748b","#f1f5f9","#475569"];return{accent:r,iconBg:o,iconFg:a}}(t,i),d=i?"1px solid #374151":"1px solid #e5e7eb";return n.jsxs("div",{style:{background:i?"#1f2937":"#ffffff",border:d,borderRadius:12,overflow:"hidden",margin:"8px 0",color:i?"#f3f4f6":"#0f172a"},children:[n.jsx("div",{style:{height:4,background:l}}),n.jsxs("div",{style:{display:"flex",alignItems:"center",justifyContent:"space-between",gap:8,padding:"12px 14px 10px",borderBottom:d},children:[n.jsxs("div",{style:{display:"flex",alignItems:"center",gap:8,fontSize:13,fontWeight:700},children:[n.jsx("span",{style:{display:"inline-flex",alignItems:"center",justifyContent:"center",width:22,height:22,borderRadius:6,background:c,color:u},children:r}),o]}),null!=a&&n.jsx("div",{style:{fontSize:11,color:i?"#9ca3af":"#64748b",fontVariantNumeric:"tabular-nums"},children:a})]}),n.jsx("div",{style:{padding:"12px 14px 14px",fontSize:13,lineHeight:1.55},children:s})]})}function l2(e){let{delta:t,isDark:r}=e;if(!t)return null;const o=function(e){const t=String(e||"").trim();return t?t.startsWith("+")?"up":t.startsWith("-")||t.startsWith("−")?"dn":"flat":"flat"}(t),a=(r?{up:{bg:"#064e3b",fg:"#a7f3d0"},dn:{bg:"#7f1d1d",fg:"#fecaca"},flat:{bg:"#1f2937",fg:"#9ca3af"}}:{up:{bg:"#dcfce7",fg:"#166534"},dn:{bg:"#fee2e2",fg:"#991b1b"},flat:{bg:"#f1f5f9",fg:"#64748b"}})[o];return n.jsx("span",{style:{fontSize:9,fontWeight:600,padding:"1px 5px",borderRadius:3,marginLeft:4,background:a.bg,color:a.fg},children:t})}function c2(e){let{items:t,isDark:r}=e;if(!t||!t.length)return null;const o=r?"1px solid #374151":"1px solid #e5e7eb",a=r?"#9ca3af":"#64748b",i=r?"#f3f4f6":"#0f172a",s=r?"#111827":"#f8fafc";return n.jsx("div",{style:{display:"flex",flexWrap:"wrap",gap:6,marginTop:4},children:t.map((e,t)=>n.jsxs("span",{style:{display:"inline-flex",alignItems:"baseline",gap:4,fontSize:11,lineHeight:1,padding:"5px 8px",borderRadius:6,background:s,border:o},children:[e.label&&n.jsxs("span",{style:{color:a},children:[e.label,":"]}),n.jsx("span",{style:{fontWeight:700,color:i,fontVariantNumeric:"tabular-nums"},children:e.value}),n.jsx(l2,{delta:e.delta,isDark:r})]},t))})}function u2(e){let{spec:t,isDark:r}=e;const o=Array.isArray(t.totals)?t.totals:[],a=r?"#9ca3af":"#64748b";return n.jsxs(s2,{type:"revenue-insights",icon:n.jsx(t2,{}),title:t.title||"Revenue insights",count:null,isDark:r,children:[t.headline&&n.jsx("div",{style:{fontSize:18,fontWeight:700,marginBottom:4},children:t.headline}),t.narrative&&n.jsx("div",{style:{color:a,marginBottom:o.length?8:0},children:t.narrative}),o.length>0&&n.jsx("div",{style:{display:"grid",gridTemplateColumns:"repeat(auto-fit, minmax(140px, 1fr))",gap:8,marginTop:8},children:o.map((e,t)=>n.jsxs("div",{style:{background:r?"#111827":"#f8fafc",border:r?"1px solid #374151":"1px solid #e5e7eb",borderRadius:8,padding:"8px 10px"},children:[n.jsx("div",{style:{fontSize:11,color:a},children:e.label}),n.jsxs("div",{style:{fontSize:16,fontWeight:700,fontVariantNumeric:"tabular-nums"},children:[e.value,n.jsx(l2,{delta:e.delta,isDark:r})]})]},t))})]})}function d2(e){let{items:t,sentiment:r,isDark:o}=e;if(!t||0===t.length)return null;const a="positive"===r?"Positive impact":"negative"===r?"Negative impact":"Neutral",i=o?"#9ca3af":"#64748b",s="positive"===r?{bg:o?"rgba(16,185,129,0.10)":"#f0fdf4",bd:o?"rgba(52,211,153,0.30)":"#bbf7d0",tx:o?"#a7f3d0":"#14532d",dot:o?"#34d399":"#10b981"}:"negative"===r?{bg:o?"rgba(239,68,68,0.10)":"#fef2f2",bd:o?"rgba(248,113,113,0.30)":"#fecaca",tx:o?"#fecaca":"#7f1d1d",dot:o?"#f87171":"#ef4444"}:{bg:o?"#111827":"#f8fafc",bd:o?"#374151":"#e2e8f0",tx:o?"#f3f4f6":"#0f172a",dot:o?"#9ca3af":"#94a3b8"};return n.jsxs("div",{children:[n.jsx("div",{style:{fontSize:11,fontWeight:700,textTransform:"uppercase",letterSpacing:"0.4px",color:i,margin:"10px 0 6px"},children:a}),t.map((e,t)=>n.jsxs("div",{style:{background:s.bg,border:"1px solid ".concat(s.bd),borderRadius:8,padding:"8px 10px",margin:"4px 0",color:s.tx},children:[n.jsxs("div",{style:{fontWeight:700,display:"block",marginBottom:2},children:[n.jsx("span",{style:{display:"inline-block",width:7,height:7,borderRadius:"50%",background:s.dot,marginRight:6,verticalAlign:"middle"}}),e.title]}),n.jsx("div",{children:e.description}),n.jsx(c2,{items:e.metrics,isDark:o})]},t))]})}function p2(e){let{spec:t,isDark:r}=e;return n.jsxs(s2,{type:"impact-analysis",icon:n.jsx(n2,{}),title:t.title||"Impact analysis",count:null,isDark:r,children:[n.jsx(d2,{items:t.positive,sentiment:"positive",isDark:r}),n.jsx(d2,{items:t.negative,sentiment:"negative",isDark:r}),n.jsx(d2,{items:t.neutral,sentiment:"neutral",isDark:r})]})}function f2(e){let{spec:t,isDark:r}=e;const o=Array.isArray(t.deviations)?t.deviations:[],a=r?"1px solid #374151":"1px solid #e5e7eb",i=r?"#9ca3af":"#64748b",s=r?"#f3f4f6":"#0f172a";return n.jsxs(s2,{type:"deviation-analysis",icon:n.jsx(r2,{}),title:t.title||"Deviation analysis",count:null,isDark:r,children:[0===o.length?n.jsx("div",{style:{color:i,fontSize:12,padding:"14px 0",textAlign:"center"},children:"No deviations"}):n.jsx("div",{style:{overflowX:"auto"},children:n.jsxs("table",{style:{width:"100%",borderCollapse:"collapse",fontSize:12},children:[n.jsx("thead",{children:n.jsx("tr",{children:["Segment","Metric","Expected","Actual","Delta"].map(e=>n.jsx("th",{style:{padding:"7px 10px",borderBottom:a,textAlign:"left",fontSize:11,color:i,fontWeight:600,textTransform:"uppercase",letterSpacing:"0.3px"},children:e},e))})}),n.jsx("tbody",{children:o.map((e,t)=>{return n.jsxs("tr",{children:[n.jsx("td",{style:{padding:"7px 10px",borderBottom:a,color:s},children:e.segment}),n.jsx("td",{style:{padding:"7px 10px",borderBottom:a,color:s},children:e.metric}),n.jsx("td",{style:{padding:"7px 10px",borderBottom:a,color:s,fontVariantNumeric:"tabular-nums"},children:e.expected}),n.jsx("td",{style:{padding:"7px 10px",borderBottom:a,color:s,fontVariantNumeric:"tabular-nums"},children:e.actual}),n.jsx("td",{style:{padding:"7px 10px",borderBottom:a,color:(o=e.tone,"up"===o?r?"#34d399":"#15803d":"dn"===o?r?"#f87171":"#b91c1c":r?"#9ca3af":"#64748b"),fontWeight:700,fontVariantNumeric:"tabular-nums"},children:e.delta})]},t);var o})})]})}),t.summary&&n.jsx("div",{style:{background:r?"#111827":"#f8fafc",border:a,borderRadius:6,padding:"8px 10px",marginTop:10,fontSize:12,color:s},children:t.summary})]})}function g2(e){let{spec:t,isDark:r}=e;const o=Array.isArray(t.secondary)?t.secondary:[],a=r?"#9ca3af":"#64748b",i=r?"#9ca3af":"#64748b",s=t.primary;return n.jsxs(s2,{type:"main-drivers",icon:n.jsx(o2,{}),title:t.title||"Main drivers",count:null,isDark:r,children:[s&&n.jsxs("div",{style:{background:r?"rgba(139,92,246,0.10)":"#faf5ff",border:r?"1px solid rgba(167,139,250,0.30)":"1px solid #d8b4fe",borderRadius:8,padding:"10px 12px",marginBottom:o.length?10:0},children:[n.jsx("div",{style:{fontSize:10,fontWeight:700,textTransform:"uppercase",letterSpacing:"0.4px",color:r?"#c4b5fd":"#7c3aed",marginBottom:4},children:"Primary driver"}),n.jsx("div",{style:{fontWeight:600},children:s.factor}),s.evidence&&n.jsx("div",{style:{color:a,fontSize:12,marginTop:4},children:s.evidence}),s.metric&&n.jsxs("span",{style:{display:"inline-block",marginTop:6,background:r?"rgba(139,92,246,0.20)":"#ede9fe",color:r?"#ddd6fe":"#5b21b6",fontSize:11,fontWeight:600,padding:"2px 7px",borderRadius:6},children:[s.metric.label,": ",s.metric.value]})]}),o.length>0&&n.jsxs(n.Fragment,{children:[n.jsx("div",{style:{fontSize:11,fontWeight:700,textTransform:"uppercase",letterSpacing:"0.4px",color:i,margin:"10px 0 6px"},children:"Secondary drivers"}),n.jsx("ul",{style:{paddingLeft:20,margin:0},children:o.map((e,t)=>n.jsxs("li",{style:{marginBottom:6},children:[n.jsx("div",{style:{fontWeight:600},children:e.factor}),e.evidence&&n.jsx("div",{style:{color:a,fontSize:12,marginTop:2},children:e.evidence})]},t))})]})]})}function h2(e){let{rankBgFg:t,rank:r,chips:o,text:a,narrative:i,metrics:s,impactPill:l,isDark:c}=e;const u=c?"#9ca3af":"#64748b",d=c?"1px dashed #374151":"1px dashed #e5e7eb";return n.jsxs("div",{style:{display:"flex",gap:10,alignItems:"flex-start",padding:"10px 0",borderBottom:d},children:[n.jsx("div",{style:{flex:"0 0 22px",height:22,width:22,borderRadius:"50%",fontSize:11,fontWeight:700,display:"flex",alignItems:"center",justifyContent:"center",fontVariantNumeric:"tabular-nums",background:t.bg,color:t.fg},children:r}),n.jsxs("div",{style:{flex:"1 1 auto",minWidth:0,display:"flex",flexDirection:"column",gap:5},children:[o,a&&n.jsx("div",{style:{fontSize:13,fontWeight:600},children:a}),i&&n.jsx("div",{style:{fontSize:12,color:u},children:i}),n.jsx(c2,{items:s,isDark:c}),l]})]})}function m2(e){let{spec:t,isDark:r}=e;const o=Array.isArray(t.items)?[...t.items].sort((e,t)=>(e.rank||0)-(t.rank||0)):[],a=r?{bg:"#064e3b",fg:"#a7f3d0"}:{bg:"#f0fdf4",fg:"#14532d"};return n.jsx(s2,{type:"key-observations",icon:n.jsx(a2,{}),title:t.title||"Key observations",count:o.length?"".concat(o.length," item").concat(1===o.length?"":"s"):null,isDark:r,children:0===o.length?n.jsx("div",{style:{color:r?"#9ca3af":"#64748b",fontSize:12,padding:"14px 0",textAlign:"center"},children:"No observations available."}):o.map((e,t)=>{const o=[];return e.category&&o.push(n.jsx("span",{style:y2("cat",r),children:e.category},"cat")),e.priority&&o.push(n.jsx("span",{style:y2("prio-"+e.priority,r),children:e.priority},"prio")),n.jsx(h2,{rankBgFg:a,rank:e.rank||t+1,chips:o.length?n.jsx("div",{style:{display:"flex",flexWrap:"wrap",gap:5},children:o}):null,text:e.text,narrative:e.narrative,metrics:e.metrics,impactPill:null,isDark:r},t)})})}function b2(e){let{spec:t,isDark:r}=e;const o=Array.isArray(t.items)?[...t.items].sort((e,t)=>(e.rank||0)-(t.rank||0)):[],a=r?{bg:"#312e81",fg:"#c7d2fe"}:{bg:"#4f46e5",fg:"#ffffff"};return n.jsx(s2,{type:"recommendations",icon:n.jsx(i2,{}),title:t.title||"Recommendations",count:o.length?"".concat(o.length," item").concat(1===o.length?"":"s"):null,isDark:r,children:0===o.length?n.jsx("div",{style:{color:r?"#9ca3af":"#64748b",fontSize:12,padding:"14px 0",textAlign:"center"},children:"No recommendations available."}):o.map((e,t)=>{const o=(e.affected_segments||[]).map((e,t)=>n.jsx("span",{style:y2("seg",r),children:e},t)),i=e.expected_impact?n.jsxs("span",{style:{alignSelf:"flex-start",display:"inline-flex",alignItems:"center",gap:4,marginTop:2,background:r?"rgba(16,185,129,0.18)":"#dcfce7",color:r?"#a7f3d0":"#166534",fontSize:10,fontWeight:700,padding:"4px 9px",borderRadius:999,border:r?"1px solid rgba(52,211,153,0.30)":"1px solid #bbf7d0"},children:["↑ ",e.expected_impact]}):null;return n.jsx(h2,{rankBgFg:a,rank:e.rank||t+1,chips:o.length?n.jsx("div",{style:{display:"flex",flexWrap:"wrap",gap:5},children:o}):null,text:e.action,narrative:e.rationale,metrics:e.metrics,impactPill:i,isDark:r},t)})})}function y2(e,t){const n={display:"inline-flex",alignItems:"center",fontSize:10,fontWeight:600,lineHeight:1,padding:"3px 7px",borderRadius:999,border:t?"1px solid #374151":"1px solid #e5e7eb",background:t?"#111827":"#f8fafc",color:t?"#9ca3af":"#64748b"};return"cat"===e?c(c({},n),{},{background:t?"rgba(99,102,241,0.20)":"#eef2ff",color:t?"#c7d2fe":"#4f46e5",border:"1px solid transparent"}):"seg"===e?c(c({},n),{},{background:t?"#1f2937":"#f1f5f9",color:t?"#f3f4f6":"#0f172a"}):"prio-high"===e?c(c({},n),{},{background:t?"rgba(239,68,68,0.18)":"#fef2f2",color:t?"#fecaca":"#7f1d1d",border:t?"1px solid rgba(248,113,113,0.30)":"1px solid #fecaca"}):"prio-medium"===e?c(c({},n),{},{background:t?"rgba(99,102,241,0.20)":"#eef2ff",color:t?"#c7d2fe":"#4f46e5",border:"1px solid transparent"}):n}const v2=/\[([\d०-९][\d०-९\s,]*)\](?!\()/g,w2={"०":"0","१":"1","२":"2","३":"3","४":"4","५":"5","६":"6","७":"7","८":"8","९":"9"};function S2(e){const t=[];for(const n of function(e){return e.replace(/[०-९]/g,e=>{var t;return null!==(t=w2[e])&&void 0!==t?t:e})}(e).split(",")){const e=n.trim();if(/^\d+$/.test(e)){const n=parseInt(e,10);n>=1&&t.push(n)}}return t}function x2(e){const t=new Set,n=[];for(const r of e)t.has(r)||(t.add(r),n.push(r));return n}function E2(){return e=>{Ds(e,"text",(e,t,n)=>{if(null==t||null==n)return;if("element"===n.type&&("code"===n.tagName||"pre"===n.tagName))return;const r=function(e){if(!e)return[];const t=[];let n;for(v2.lastIndex=0;null!==(n=v2.exec(e));){const e=S2(n[1]);0!==e.length&&t.push({start:n.index,end:v2.lastIndex,indices:e})}if(0===t.length)return[{type:"text",value:e}];const r=[];for(const n of t){const t=r.length?r[r.length-1]:null;t&&/^\s*$/.test(e.slice(t.end,n.start))?(t.end=n.end,t.indices.push(...n.indices)):r.push({start:n.start,end:n.end,indices:[...n.indices]})}const o=[];let a=0;for(const t of r)t.start>a&&o.push({type:"text",value:e.slice(a,t.start)}),o.push({type:"cite",indices:x2(t.indices)}),a=t.end;return a<e.length&&o.push({type:"text",value:e.slice(a)}),o}(e.value);if(1===r.length&&"text"===r[0].type)return;const o=r.map((e,t)=>{if("text"===e.type){return{type:"text",value:t+1<r.length&&"cite"===r[t+1].type?e.value.replace(/[ \t]+$/," "):e.value}}return{type:"element",tagName:"span",properties:{dataEshalCitation:(n=e.indices,n.join(","))},children:[]};var n});return n.children.splice(t,1,...o),[Ps,t+o.length]})}}const k2=["node","children"],A2=["children"],T2=["node","children"],O2=["node","children"],C2=["node","children"],I2=["node","children","start"],N2=["node","children","data-ol-index"],_2=["node","children"],R2=["node","children"],P2=["node","children"],L2=["node","children"],D2=["node","children"],M2=["node","children"],j2=["node","children"],F2=["className","children"],B2=new Set(["eshal-ui","eshal-chart","chart"]);function U2(e,t){if(!t)return e;const n=/^```(?:eshal-ui|eshal-chart|chart)\b/m.exec(e);if(n){const t=e.slice(n.index+n[0].length).split("\n").some(e=>"```"===e.trim());if(!t)return e.slice(0,n.index).trimEnd()}const r=e.split("\n");let o=r.length-1;for(;o>0&&""===r[o].trim();)o--;if(!r[o].trim().startsWith("|"))return e;let a=o;for(;a>0&&(r[a-1].trim().startsWith("|")||""===r[a-1].trim());)a--;const i=r.slice(a,o+1).some(e=>/^\|[\s\-:|]+\|/.test(e.trim()));return i?e:r.slice(0,a).join("\n")}function z2(e){return e.replace(/(\d+\.\d{2})0+(?!\d)/g,"$1")}var $2=Object.freeze({__proto__:null,default:function(t){let{content:r,isStreaming:o,isDark:a=!1,isRtl:i=!1,textColor:s,fontFamily:l,fontSize:d,onButtonClick:p,provideCitations:f=!0}=t;return n.jsx(Ol,{className:"max-w-none [&>*:last-child]:!mb-0 [&>*:first-child]:!mt-0",remarkPlugins:[Su,Eu],rehypePlugins:f?[E2]:[],components:{span(e){var t;let{node:r,children:o}=e,a=u(e,k2);const i=null!==(t=a["data-eshal-citation"])&&void 0!==t?t:a.dataEshalCitation;if("string"==typeof i&&i.length>0){const e=function(e){if(!e)return[];const t=[];for(const n of String(e).split(",")){const e=parseInt(n.trim(),10);Number.isFinite(e)&&e>=1&&t.push(e)}return x2(t)}(i);if(e.length>0)return n.jsx(ut,{indices:e})}return n.jsx("span",c(c({},a),{},{children:o}))},pre(t){let{children:r}=t,o=u(t,A2);return function(t){return e.Children.toArray(t).some(t=>{var n;if(!e.isValidElement(t))return!1;const r=null===(n=t.props)||void 0===n?void 0:n.className;if("string"!=typeof r)return!1;const o=r.match(/language-([\w-]+)/);return!!o&&B2.has(o[1])})}(r)?n.jsx(n.Fragment,{children:r}):n.jsx("pre",c(c({},o),{},{children:r}))},a(e){let{node:t,children:r}=e,o=u(e,T2);return n.jsx("a",c(c({className:"underline hover:opacity-80",dir:"ltr",style:{color:s||(a?"#f3f4f6":"#1A1A1A"),unicodeBidi:"isolate"},target:"_blank",rel:"noopener noreferrer"},o),{},{children:r}))},p(e){var t;let{node:r,children:o}=e,i=u(e,O2);const p="li"===(null==r||null===(t=r.parent)||void 0===t?void 0:t.tagName);return n.jsx("p",c(c({className:"leading-relaxed [&:first-child]:!mt-0",style:{color:s||(a?"#f3f4f6":"#1A1A1A"),fontFamily:l||"Inter",fontSize:d||"14px",margin:0,marginTop:0,marginBottom:p?"0.125rem":"0.85rem",lineHeight:"1.6",padding:0}},i),{},{children:o}))},ul(e){let{node:t,children:r}=e,o=u(e,C2);return n.jsx("ul",c(c({className:"list-disc [&:first-child]:!mt-0",style:{marginTop:0,marginBottom:"0.6rem",paddingInlineStart:"1.2rem"}},o),{},{children:r}))},ol(t){let{node:r,children:o,start:a=1}=t,i=u(t,I2);const s=Number.isFinite(Number(a))?Number(a):1;let l=0;return n.jsx("ol",c(c({className:"[&:first-child]:!mt-0",style:{listStyle:"none",marginTop:0,marginBottom:"0.6rem",paddingInlineStart:0}},i),{},{children:e.Children.map(o,t=>{if(!e.isValidElement(t))return t;const n=s+l;return l+=1,e.cloneElement(t,{"data-ol-index":n})})}))},li(e){let{node:t,children:r,"data-ol-index":o}=e,i=u(e,N2);const p={color:s||(a?"#f3f4f6":"#1A1A1A"),fontFamily:l||"Inter",fontSize:d||"14px",marginBottom:"0.3rem",lineHeight:"1.5"};return null!=o?n.jsxs("li",c(c({style:c(c({},p),{},{listStyle:"none",display:"flex",alignItems:"baseline",gap:"0.4em"})},i),{},{children:[n.jsxs("span",{style:{flexShrink:0,fontFamily:'-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif',fontVariantNumeric:"tabular-nums",minWidth:"1.5em",color:"inherit"},"aria-hidden":"false",children:[o,"."]}),n.jsx("span",{style:{flex:"1 1 auto",minWidth:0},children:r})]})):n.jsx("li",c(c({className:"",style:p},i),{},{children:r}))},h1(e){let{node:t,children:r}=e,o=u(e,_2);return n.jsx("h1",c(c({className:"text-xl font-bold [&:first-child]:!mt-0",style:{color:s||(a?"#f3f4f6":"#1A1A1A"),fontFamily:l||"Inter",marginTop:"0.7rem",marginBottom:"0.45rem",lineHeight:"1.35"}},o),{},{children:r}))},h2(e){let{node:t,children:r}=e,o=u(e,R2);return n.jsx("h2",c(c({className:"text-lg font-semibold [&:first-child]:!mt-0",style:{color:s||(a?"#f3f4f6":"#1A1A1A"),fontFamily:l||"Inter",marginTop:"0.65rem",marginBottom:"0.4rem",lineHeight:"1.35"}},o),{},{children:r}))},h3(e){let{node:t,children:r}=e,o=u(e,P2);return n.jsx("h3",c(c({className:"text-base font-semibold [&:first-child]:!mt-0",style:{color:s||(a?"#f3f4f6":"#1A1A1A"),fontFamily:l||"Inter",marginTop:"0.6rem",marginBottom:"0.35rem",lineHeight:"1.35"}},o),{},{children:r}))},blockquote(e){let{node:t,children:r}=e,o=u(e,L2);return n.jsx("blockquote",c(c({className:"border-l-4 pl-4 italic ".concat(a?"border-gray-600 text-gray-300":"border-gray-300 text-gray-700")},o),{},{children:r}))},table(e){var t;let{node:r,children:o}=e,i=u(e,D2);if((null==r||null===(t=r.children)||void 0===t?void 0:t.length)>0){var s;function l(e){return e?"string"==typeof e.value?e.value:Array.isArray(e.children)?e.children.map(l).join(""):"":""}const d=r.children.find(e=>"thead"===e.tagName),p=r.children.find(e=>"tbody"===e.tagName),f=null==d||null===(s=d.children)||void 0===s?void 0:s.find(e=>"tr"===e.tagName),g=((null==f?void 0:f.children)||[]).filter(e=>"th"===e.tagName).map(e=>l(e)),h=((null==p?void 0:p.children)||[]).filter(e=>"tr"===e.tagName),m=h.map(e=>(e.children||[]).filter(e=>"td"===e.tagName).map(e=>l(e)));if(g.length>0&&m.length>0){const b=m.map(e=>Object.fromEntries(g.map((t,n)=>{var r;return[t,null!==(r=e[n])&&void 0!==r?r:""]})));return n.jsx(S1,{spec:{type:"table",columns:g,data:b},isDark:a})}}return n.jsx("div",{className:"overflow-x-auto my-3 rounded-lg border ".concat(a?"border-gray-700 bg-gray-900":"border-gray-200 bg-white"),children:n.jsx("table",c(c({className:"min-w-full border-collapse ".concat(a?"text-gray-100":"text-gray-900")},i),{},{children:o}))})},th(e){let{node:t,children:r}=e,o=u(e,M2);return n.jsx("th",c(c({className:"border px-3 py-2 text-left font-medium ".concat(a?"border-gray-700 bg-gray-800/50 text-gray-300":"border-gray-200 bg-gray-50 text-gray-700")},o),{},{children:r}))},td(e){let{node:t,children:r}=e,o=u(e,j2);return n.jsx("td",c(c({className:"border px-3 py-2 ".concat(a?"border-gray-700":"border-gray-200")},o),{},{children:r}))},code(e){let{className:t,children:r}=e,o=u(e,F2);const i=/language-([\w-]+)/.exec(t||""),s=i?i[1]:null;if(s&&B2.has(s)){const e=function(e){return"string"==typeof e?e:Array.isArray(e)?e.map(e=>"string"==typeof e?e:"").join(""):""}(r).trim();try{const t=JSON.parse(e);if(t&&"object"==typeof t)return n.jsx(S1,{spec:t,isDark:a,onButtonClick:p})}catch(e){return null}return null}return i?n.jsx(pk,c(c({style:fk,language:s,PreTag:"div",wrapLines:!0},o),{},{children:String(r).replace(/\n$/,"")})):n.jsx("code",c(c({className:t},o),{},{children:r}))}},children:z2(U2(r,o))})},sanitizeExcessDecimalPrecision:z2,sanitizeStreamingContent:U2});return function(r){const o=e.useRef(null),a=e.useRef(null);return e.useEffect(()=>{const e=o.current;if(!e||e.shadowRoot)return;const n=e.attachShadow({mode:"open"}),r=document.createElement("style");r.textContent=":host { all: initial; display: block; }",n.appendChild(r);const i=document.createElement("style");i.textContent='*,:after,:before{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }::backdrop{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }.chat-widget-root{--cw-primary:#1d4ed8;--cw-primary-hover:#1e40af;--cw-status-success:160 84% 39%;--cw-status-success-bg:152 81% 96%;--cw-status-warning:35 100% 50%;--cw-status-warning-bg:34 100% 95%;--cw-status-error:350 89% 60%;--cw-status-error-bg:356 100% 97%;--cw-status-info:199 89% 48%;--cw-status-info-bg:204 100% 97%;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,Fira Sans,Droid Sans,Helvetica Neue,sans-serif}.chat-widget-root.dark{--cw-status-success:158 64% 52%;--cw-status-success-bg:152 36% 14%;--cw-status-warning:38 92% 60%;--cw-status-warning-bg:36 33% 14%;--cw-status-error:350 89% 65%;--cw-status-error-bg:356 33% 16%;--cw-status-info:199 89% 58%;--cw-status-info-bg:204 33% 14%}.\\!container{width:100%!important}.container{width:100%}@media (min-width:640px){.\\!container{max-width:640px!important}.container{max-width:640px}}@media (min-width:768px){.\\!container{max-width:768px!important}.container{max-width:768px}}@media (min-width:1024px){.\\!container{max-width:1024px!important}.container{max-width:1024px}}@media (min-width:1280px){.\\!container{max-width:1280px!important}.container{max-width:1280px}}@media (min-width:1536px){.\\!container{max-width:1536px!important}.container{max-width:1536px}}#chat-widget-root .chat-widget-root *{box-sizing:border-box;margin:0;padding:0}#chat-widget-root .chat-messages::-webkit-scrollbar{width:6px}#chat-widget-root .chat-messages::-webkit-scrollbar-track{background:transparent}#chat-widget-root .chat-messages::-webkit-scrollbar-thumb{background:rgba(156,163,175,.5);border-radius:10px}#chat-widget-root .chat-messages::-webkit-scrollbar-thumb:hover{background:rgba(156,163,175,.7)}#chat-widget-root .dark .chat-messages::-webkit-scrollbar-thumb{background:rgba(75,85,99,.5)}#chat-widget-root .dark .chat-messages::-webkit-scrollbar-thumb:hover{background:rgba(75,85,99,.7)}#chat-widget-root .sr-only{clip:rect(0,0,0,0);border-width:0;height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;white-space:nowrap;width:1px}#chat-widget-root .pointer-events-none{pointer-events:none}#chat-widget-root .visible{visibility:visible}#chat-widget-root .collapse{visibility:collapse}#chat-widget-root .static{position:static}#chat-widget-root .fixed{position:fixed}#chat-widget-root .absolute{position:absolute}#chat-widget-root .relative{position:relative}#chat-widget-root .sticky{position:sticky}#chat-widget-root .inset-0{inset:0}#chat-widget-root .-top-8{top:-2rem}#chat-widget-root .bottom-0{bottom:0}#chat-widget-root .bottom-5{bottom:1.25rem}#chat-widget-root .bottom-full{bottom:100%}#chat-widget-root .left-0{left:0}#chat-widget-root .left-1\\/2{left:50%}#chat-widget-root .left-5{left:1.25rem}#chat-widget-root .right-0{right:0}#chat-widget-root .right-5{right:1.25rem}#chat-widget-root .top-0{top:0}#chat-widget-root .top-1\\/2{top:50%}#chat-widget-root .top-5{top:1.25rem}#chat-widget-root .top-full{top:100%}#chat-widget-root .isolate{isolation:isolate}#chat-widget-root .z-10{z-index:10}#chat-widget-root .z-50{z-index:50}#chat-widget-root .z-\\[60\\]{z-index:60}#chat-widget-root .z-\\[70\\]{z-index:70}#chat-widget-root .z-\\[71\\]{z-index:71}#chat-widget-root .z-\\[999999\\]{z-index:999999}#chat-widget-root .z-\\[9999\\]{z-index:9999}#chat-widget-root .m-0{margin:0}#chat-widget-root .mx-2{margin-left:.5rem;margin-right:.5rem}#chat-widget-root .my-3{margin-bottom:.75rem;margin-top:.75rem}#chat-widget-root .my-4{margin-bottom:1rem;margin-top:1rem}#chat-widget-root .-mb-px{margin-bottom:-1px}#chat-widget-root .mb-1{margin-bottom:.25rem}#chat-widget-root .mb-1\\.5{margin-bottom:.375rem}#chat-widget-root .mb-2{margin-bottom:.5rem}#chat-widget-root .mb-3{margin-bottom:.75rem}#chat-widget-root .mb-4{margin-bottom:1rem}#chat-widget-root .mb-5{margin-bottom:1.25rem}#chat-widget-root .ml-0\\.5{margin-left:.125rem}#chat-widget-root .ml-1{margin-left:.25rem}#chat-widget-root .mt-0\\.5{margin-top:.125rem}#chat-widget-root .mt-1{margin-top:.25rem}#chat-widget-root .mt-1\\.5{margin-top:.375rem}#chat-widget-root .mt-2{margin-top:.5rem}#chat-widget-root .mt-3{margin-top:.75rem}#chat-widget-root .mt-4{margin-top:1rem}#chat-widget-root .block{display:block}#chat-widget-root .inline-block{display:inline-block}#chat-widget-root .inline{display:inline}#chat-widget-root .flex{display:flex}#chat-widget-root .inline-flex{display:inline-flex}#chat-widget-root .table{display:table}#chat-widget-root .grid{display:grid}#chat-widget-root .hidden{display:none}#chat-widget-root .h-1\\.5{height:.375rem}#chat-widget-root .h-10{height:2.5rem}#chat-widget-root .h-11{height:2.75rem}#chat-widget-root .h-12{height:3rem}#chat-widget-root .h-14{height:3.5rem}#chat-widget-root .h-16{height:4rem}#chat-widget-root .h-2{height:.5rem}#chat-widget-root .h-3{height:.75rem}#chat-widget-root .h-3\\.5{height:.875rem}#chat-widget-root .h-4{height:1rem}#chat-widget-root .h-5{height:1.25rem}#chat-widget-root .h-6{height:1.5rem}#chat-widget-root .h-7{height:1.75rem}#chat-widget-root .h-8{height:2rem}#chat-widget-root .h-\\[650px\\]{height:650px}#chat-widget-root .h-auto{height:auto}#chat-widget-root .h-full{height:100%}#chat-widget-root .h-px{height:1px}#chat-widget-root .max-h-\\[85vh\\]{max-height:85vh}#chat-widget-root .min-h-0{min-height:0}#chat-widget-root .min-h-\\[48px\\]{min-height:48px}#chat-widget-root .w-1\\.5{width:.375rem}#chat-widget-root .w-10{width:2.5rem}#chat-widget-root .w-11{width:2.75rem}#chat-widget-root .w-12{width:3rem}#chat-widget-root .w-14{width:3.5rem}#chat-widget-root .w-16{width:4rem}#chat-widget-root .w-2{width:.5rem}#chat-widget-root .w-3{width:.75rem}#chat-widget-root .w-3\\.5{width:.875rem}#chat-widget-root .w-4{width:1rem}#chat-widget-root .w-44{width:11rem}#chat-widget-root .w-5{width:1.25rem}#chat-widget-root .w-6{width:1.5rem}#chat-widget-root .w-7{width:1.75rem}#chat-widget-root .w-8{width:2rem}#chat-widget-root .w-80{width:20rem}#chat-widget-root .w-96{width:24rem}#chat-widget-root .w-\\[380px\\]{width:380px}#chat-widget-root .w-full{width:100%}#chat-widget-root .min-w-0{min-width:0}#chat-widget-root .min-w-\\[60px\\]{min-width:60px}#chat-widget-root .min-w-full{min-width:100%}#chat-widget-root .max-w-\\[75\\%\\]{max-width:75%}#chat-widget-root .max-w-\\[92vw\\]{max-width:92vw}#chat-widget-root .max-w-full{max-width:100%}#chat-widget-root .max-w-none{max-width:none}#chat-widget-root .max-w-sm{max-width:24rem}#chat-widget-root .max-w-xs{max-width:20rem}#chat-widget-root .flex-1{flex:1 1 0%}#chat-widget-root .flex-shrink-0{flex-shrink:0}#chat-widget-root .grow{flex-grow:1}#chat-widget-root .border-collapse{border-collapse:collapse}#chat-widget-root .-translate-x-1\\/2{--tw-translate-x:-50%}#chat-widget-root .-translate-x-1\\/2,#chat-widget-root .-translate-y-1\\/2{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}#chat-widget-root .-translate-y-1\\/2{--tw-translate-y:-50%}#chat-widget-root .-rotate-90{--tw-rotate:-90deg}#chat-widget-root .-rotate-90,#chat-widget-root .rotate-180{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}#chat-widget-root .rotate-180{--tw-rotate:180deg}#chat-widget-root .rotate-90{--tw-rotate:90deg}#chat-widget-root .rotate-90,#chat-widget-root .scale-0{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}#chat-widget-root .scale-0{--tw-scale-x:0;--tw-scale-y:0}#chat-widget-root .scale-100{--tw-scale-x:1;--tw-scale-y:1}#chat-widget-root .scale-100,#chat-widget-root .scale-110{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}#chat-widget-root .scale-110{--tw-scale-x:1.1;--tw-scale-y:1.1}#chat-widget-root .scale-125{--tw-scale-x:1.25;--tw-scale-y:1.25}#chat-widget-root .scale-125,#chat-widget-root .scale-95{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}#chat-widget-root .scale-95{--tw-scale-x:.95;--tw-scale-y:.95}#chat-widget-root .transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@keyframes bounce{0%,to{animation-timing-function:cubic-bezier(.8,0,1,1);transform:translateY(-25%)}50%{animation-timing-function:cubic-bezier(0,0,.2,1);transform:none}}#chat-widget-root .animate-bounce{animation:bounce 1s infinite}@keyframes pulse{50%{opacity:.5}}#chat-widget-root .animate-pulse{animation:pulse 2s cubic-bezier(.4,0,.6,1) infinite}@keyframes spin{to{transform:rotate(1turn)}}#chat-widget-root .animate-spin{animation:spin 1s linear infinite}#chat-widget-root .cursor-ew-resize{cursor:ew-resize}#chat-widget-root .cursor-nesw-resize{cursor:nesw-resize}#chat-widget-root .cursor-not-allowed{cursor:not-allowed}#chat-widget-root .cursor-ns-resize{cursor:ns-resize}#chat-widget-root .cursor-nwse-resize{cursor:nwse-resize}#chat-widget-root .cursor-pointer{cursor:pointer}#chat-widget-root .resize-none{resize:none}#chat-widget-root .resize{resize:both}#chat-widget-root .list-decimal{list-style-type:decimal}#chat-widget-root .list-disc{list-style-type:disc}#chat-widget-root .list-none{list-style-type:none}#chat-widget-root .flex-row{flex-direction:row}#chat-widget-root .flex-row-reverse{flex-direction:row-reverse}#chat-widget-root .flex-col{flex-direction:column}#chat-widget-root .flex-wrap{flex-wrap:wrap}#chat-widget-root .items-start{align-items:flex-start}#chat-widget-root .items-end{align-items:flex-end}#chat-widget-root .items-center{align-items:center}#chat-widget-root .justify-start{justify-content:flex-start}#chat-widget-root .justify-end{justify-content:flex-end}#chat-widget-root .justify-center{justify-content:center}#chat-widget-root .justify-between{justify-content:space-between}#chat-widget-root .gap-0{gap:0}#chat-widget-root .gap-0\\.5{gap:.125rem}#chat-widget-root .gap-1{gap:.25rem}#chat-widget-root .gap-1\\.5{gap:.375rem}#chat-widget-root .gap-2{gap:.5rem}#chat-widget-root .gap-2\\.5{gap:.625rem}#chat-widget-root .gap-3{gap:.75rem}#chat-widget-root .gap-4{gap:1rem}#chat-widget-root .gap-6{gap:1.5rem}#chat-widget-root :is(.space-y-1>:not([hidden])~:not([hidden])){--tw-space-y-reverse:0;margin-bottom:calc(.25rem*var(--tw-space-y-reverse));margin-top:calc(.25rem*(1 - var(--tw-space-y-reverse)))}#chat-widget-root :is(.space-y-2>:not([hidden])~:not([hidden])){--tw-space-y-reverse:0;margin-bottom:calc(.5rem*var(--tw-space-y-reverse));margin-top:calc(.5rem*(1 - var(--tw-space-y-reverse)))}#chat-widget-root :is(.space-y-4>:not([hidden])~:not([hidden])){--tw-space-y-reverse:0;margin-bottom:calc(1rem*var(--tw-space-y-reverse));margin-top:calc(1rem*(1 - var(--tw-space-y-reverse)))}#chat-widget-root .overflow-hidden{overflow:hidden}#chat-widget-root .overflow-visible{overflow:visible}#chat-widget-root .overflow-x-auto{overflow-x:auto}#chat-widget-root .overflow-y-auto{overflow-y:auto}#chat-widget-root .truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}#chat-widget-root .whitespace-nowrap{white-space:nowrap}#chat-widget-root .whitespace-pre-wrap{white-space:pre-wrap}#chat-widget-root .break-words{overflow-wrap:break-word}#chat-widget-root .break-all{word-break:break-all}#chat-widget-root .rounded{border-radius:.25rem}#chat-widget-root .rounded-2xl{border-radius:1rem}#chat-widget-root .rounded-3xl{border-radius:1.5rem}#chat-widget-root .rounded-full{border-radius:9999px}#chat-widget-root .rounded-lg{border-radius:.5rem}#chat-widget-root .rounded-md{border-radius:.375rem}#chat-widget-root .rounded-xl{border-radius:.75rem}#chat-widget-root .rounded-t-2xl{border-top-left-radius:1rem;border-top-right-radius:1rem}#chat-widget-root .rounded-tl-sm{border-top-left-radius:.125rem}#chat-widget-root .rounded-tr-sm{border-top-right-radius:.125rem}#chat-widget-root .border{border-width:1px}#chat-widget-root .border-0{border-width:0}#chat-widget-root .border-b{border-bottom-width:1px}#chat-widget-root .border-l-4{border-left-width:4px}#chat-widget-root .border-t{border-top-width:1px}#chat-widget-root .border-t-2{border-top-width:2px}#chat-widget-root .border-dotted{border-style:dotted}#chat-widget-root .border-none{border-style:none}#chat-widget-root .\\!border-status-error{border-color:hsl(var(--cw-status-error))!important}#chat-widget-root .border-blue-200{--tw-border-opacity:1;border-color:rgb(191 219 254/var(--tw-border-opacity,1))}#chat-widget-root .border-blue-700\\/50{border-color:rgba(29,78,216,.5)}#chat-widget-root .border-gray-100{--tw-border-opacity:1;border-color:rgb(243 244 246/var(--tw-border-opacity,1))}#chat-widget-root .border-gray-200{--tw-border-opacity:1;border-color:rgb(229 231 235/var(--tw-border-opacity,1))}#chat-widget-root .border-gray-200\\/60{border-color:rgba(229,231,235,.6)}#chat-widget-root .border-gray-300{--tw-border-opacity:1;border-color:rgb(209 213 219/var(--tw-border-opacity,1))}#chat-widget-root .border-gray-600{--tw-border-opacity:1;border-color:rgb(75 85 99/var(--tw-border-opacity,1))}#chat-widget-root .border-gray-700{--tw-border-opacity:1;border-color:rgb(55 65 81/var(--tw-border-opacity,1))}#chat-widget-root .border-gray-700\\/50{border-color:rgba(55,65,81,.5)}#chat-widget-root .border-transparent{border-color:transparent}#chat-widget-root .bg-blue-50{--tw-bg-opacity:1;background-color:rgb(239 246 255/var(--tw-bg-opacity,1))}#chat-widget-root .bg-blue-500{--tw-bg-opacity:1;background-color:rgb(59 130 246/var(--tw-bg-opacity,1))}#chat-widget-root .bg-blue-900\\/30{background-color:rgba(30,58,138,.3)}#chat-widget-root .bg-current{background-color:currentColor}#chat-widget-root .bg-gray-100{--tw-bg-opacity:1;background-color:rgb(243 244 246/var(--tw-bg-opacity,1))}#chat-widget-root .bg-gray-400{--tw-bg-opacity:1;background-color:rgb(156 163 175/var(--tw-bg-opacity,1))}#chat-widget-root .bg-gray-50{--tw-bg-opacity:1;background-color:rgb(249 250 251/var(--tw-bg-opacity,1))}#chat-widget-root .bg-gray-500{--tw-bg-opacity:1;background-color:rgb(107 114 128/var(--tw-bg-opacity,1))}#chat-widget-root .bg-gray-700{--tw-bg-opacity:1;background-color:rgb(55 65 81/var(--tw-bg-opacity,1))}#chat-widget-root .bg-gray-700\\/50{background-color:rgba(55,65,81,.5)}#chat-widget-root .bg-gray-800{--tw-bg-opacity:1;background-color:rgb(31 41 55/var(--tw-bg-opacity,1))}#chat-widget-root .bg-gray-800\\/50{background-color:rgba(31,41,55,.5)}#chat-widget-root .bg-gray-900{--tw-bg-opacity:1;background-color:rgb(17 24 39/var(--tw-bg-opacity,1))}#chat-widget-root .bg-green-200{--tw-bg-opacity:1;background-color:rgb(187 247 208/var(--tw-bg-opacity,1))}#chat-widget-root .bg-orange-200{--tw-bg-opacity:1;background-color:rgb(254 215 170/var(--tw-bg-opacity,1))}#chat-widget-root .bg-pink-200{--tw-bg-opacity:1;background-color:rgb(251 207 232/var(--tw-bg-opacity,1))}#chat-widget-root .bg-red-200{--tw-bg-opacity:1;background-color:rgb(254 202 202/var(--tw-bg-opacity,1))}#chat-widget-root .bg-red-500{--tw-bg-opacity:1;background-color:rgb(239 68 68/var(--tw-bg-opacity,1))}#chat-widget-root .bg-slate-50\\/50{background-color:rgba(248,250,252,.5)}#chat-widget-root .bg-slate-800\\/50{background-color:rgba(30,41,59,.5)}#chat-widget-root .bg-transparent{background-color:transparent}#chat-widget-root .bg-white{--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity,1))}#chat-widget-root .bg-white\\/10{background-color:hsla(0,0%,100%,.1)}#chat-widget-root .bg-white\\/20{background-color:hsla(0,0%,100%,.2)}#chat-widget-root .bg-yellow-200{--tw-bg-opacity:1;background-color:rgb(254 240 138/var(--tw-bg-opacity,1))}#chat-widget-root .bg-gradient-to-b{background-image:linear-gradient(to bottom,var(--tw-gradient-stops))}#chat-widget-root .bg-gradient-to-br{background-image:linear-gradient(to bottom right,var(--tw-gradient-stops))}#chat-widget-root .from-gray-50\\/50{--tw-gradient-from:rgba(249,250,251,.5) var(--tw-gradient-from-position);--tw-gradient-to:rgba(249,250,251,0) var(--tw-gradient-to-position);--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)}#chat-widget-root .from-white\\/0{--tw-gradient-from:hsla(0,0%,100%,0) var(--tw-gradient-from-position);--tw-gradient-to:hsla(0,0%,100%,0) var(--tw-gradient-to-position);--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)}#chat-widget-root .from-white\\/10{--tw-gradient-from:hsla(0,0%,100%,.1) var(--tw-gradient-from-position);--tw-gradient-to:hsla(0,0%,100%,0) var(--tw-gradient-to-position);--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)}#chat-widget-root .from-yellow-200{--tw-gradient-from:#fef08a var(--tw-gradient-from-position);--tw-gradient-to:hsla(53,98%,77%,0) var(--tw-gradient-to-position);--tw-gradient-stops:var(--tw-gradient-from),var(--tw-gradient-to)}#chat-widget-root .via-white\\/5{--tw-gradient-to:hsla(0,0%,100%,0) var(--tw-gradient-to-position);--tw-gradient-stops:var(--tw-gradient-from),hsla(0,0%,100%,.05) var(--tw-gradient-via-position),var(--tw-gradient-to)}#chat-widget-root .to-white{--tw-gradient-to:#fff var(--tw-gradient-to-position)}#chat-widget-root .to-white\\/10{--tw-gradient-to:hsla(0,0%,100%,.1) var(--tw-gradient-to-position)}#chat-widget-root .to-yellow-400{--tw-gradient-to:#facc15 var(--tw-gradient-to-position)}#chat-widget-root .object-cover{-o-object-fit:cover;object-fit:cover}#chat-widget-root .p-0{padding:0}#chat-widget-root .p-0\\.5{padding:.125rem}#chat-widget-root .p-3{padding:.75rem}#chat-widget-root .p-5{padding:1.25rem}#chat-widget-root .p-6{padding:1.5rem}#chat-widget-root .p-8{padding:2rem}#chat-widget-root .px-1{padding-left:.25rem;padding-right:.25rem}#chat-widget-root .px-2{padding-left:.5rem;padding-right:.5rem}#chat-widget-root .px-2\\.5{padding-left:.625rem;padding-right:.625rem}#chat-widget-root .px-3{padding-left:.75rem;padding-right:.75rem}#chat-widget-root .px-4{padding-left:1rem;padding-right:1rem}#chat-widget-root .px-5{padding-left:1.25rem;padding-right:1.25rem}#chat-widget-root .py-1{padding-bottom:.25rem;padding-top:.25rem}#chat-widget-root .py-1\\.5{padding-bottom:.375rem;padding-top:.375rem}#chat-widget-root .py-12{padding-bottom:3rem;padding-top:3rem}#chat-widget-root .py-2{padding-bottom:.5rem;padding-top:.5rem}#chat-widget-root .py-2\\.5{padding-bottom:.625rem;padding-top:.625rem}#chat-widget-root .py-3{padding-bottom:.75rem;padding-top:.75rem}#chat-widget-root .py-3\\.5{padding-bottom:.875rem;padding-top:.875rem}#chat-widget-root .py-4{padding-bottom:1rem;padding-top:1rem}#chat-widget-root .pb-1{padding-bottom:.25rem}#chat-widget-root .pb-2{padding-bottom:.5rem}#chat-widget-root .pl-1{padding-left:.25rem}#chat-widget-root .pl-2{padding-left:.5rem}#chat-widget-root .pl-4{padding-left:1rem}#chat-widget-root .pl-\\[50px\\]{padding-left:50px}#chat-widget-root .pr-1{padding-right:.25rem}#chat-widget-root .pt-1{padding-top:.25rem}#chat-widget-root .text-left{text-align:left}#chat-widget-root .text-center{text-align:center}#chat-widget-root .text-right{text-align:right}#chat-widget-root .align-text-bottom{vertical-align:text-bottom}#chat-widget-root .font-sans{font-family:ui-sans-serif,system-ui,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji}#chat-widget-root .text-2xl{font-size:1.5rem;line-height:2rem}#chat-widget-root .text-\\[10px\\]{font-size:10px}#chat-widget-root .text-base{font-size:1rem;line-height:1.5rem}#chat-widget-root .text-chip{font-size:11px;letter-spacing:0;line-height:1.4}#chat-widget-root .text-h4{font-size:18px;letter-spacing:0;line-height:1.3}#chat-widget-root .text-lg{font-size:1.125rem;line-height:1.75rem}#chat-widget-root .text-sm{font-size:.875rem;line-height:1.25rem}#chat-widget-root .text-xl{font-size:1.25rem;line-height:1.75rem}#chat-widget-root .text-xs{font-size:.75rem;line-height:1rem}#chat-widget-root .font-bold{font-weight:700}#chat-widget-root .font-medium{font-weight:500}#chat-widget-root .font-semibold{font-weight:600}#chat-widget-root .uppercase{text-transform:uppercase}#chat-widget-root .lowercase{text-transform:lowercase}#chat-widget-root .italic{font-style:italic}#chat-widget-root .tabular-nums{--tw-numeric-spacing:tabular-nums;font-variant-numeric:var(--tw-ordinal) var(--tw-slashed-zero) var(--tw-numeric-figure) var(--tw-numeric-spacing) var(--tw-numeric-fraction)}#chat-widget-root .leading-5{line-height:1.25rem}#chat-widget-root .leading-none{line-height:1}#chat-widget-root .leading-normal{line-height:1.5}#chat-widget-root .leading-relaxed{line-height:1.625}#chat-widget-root .leading-snug{line-height:1.375}#chat-widget-root .tracking-wide{letter-spacing:.025em}#chat-widget-root .text-\\[\\#4A5568\\]{--tw-text-opacity:1;color:rgb(74 85 104/var(--tw-text-opacity,1))}#chat-widget-root .text-current{color:currentColor}#chat-widget-root .text-gray-100{--tw-text-opacity:1;color:rgb(243 244 246/var(--tw-text-opacity,1))}#chat-widget-root .text-gray-200{--tw-text-opacity:1;color:rgb(229 231 235/var(--tw-text-opacity,1))}#chat-widget-root .text-gray-300{--tw-text-opacity:1;color:rgb(209 213 219/var(--tw-text-opacity,1))}#chat-widget-root .text-gray-400{--tw-text-opacity:1;color:rgb(156 163 175/var(--tw-text-opacity,1))}#chat-widget-root .text-gray-500{--tw-text-opacity:1;color:rgb(107 114 128/var(--tw-text-opacity,1))}#chat-widget-root .text-gray-500\\/80{color:hsla(220,9%,46%,.8)}#chat-widget-root .text-gray-600{--tw-text-opacity:1;color:rgb(75 85 99/var(--tw-text-opacity,1))}#chat-widget-root .text-gray-700{--tw-text-opacity:1;color:rgb(55 65 81/var(--tw-text-opacity,1))}#chat-widget-root .text-gray-800{--tw-text-opacity:1;color:rgb(31 41 55/var(--tw-text-opacity,1))}#chat-widget-root .text-gray-900{--tw-text-opacity:1;color:rgb(17 24 39/var(--tw-text-opacity,1))}#chat-widget-root .text-green-500{--tw-text-opacity:1;color:rgb(34 197 94/var(--tw-text-opacity,1))}#chat-widget-root .text-red-500{--tw-text-opacity:1;color:rgb(239 68 68/var(--tw-text-opacity,1))}#chat-widget-root .text-slate-400{--tw-text-opacity:1;color:rgb(148 163 184/var(--tw-text-opacity,1))}#chat-widget-root .text-slate-500{--tw-text-opacity:1;color:rgb(100 116 139/var(--tw-text-opacity,1))}#chat-widget-root .text-status-error{color:hsl(var(--cw-status-error))}#chat-widget-root .text-status-success{color:hsl(var(--cw-status-success))}#chat-widget-root .text-white{--tw-text-opacity:1;color:rgb(255 255 255/var(--tw-text-opacity,1))}#chat-widget-root .text-yellow-400{--tw-text-opacity:1;color:rgb(250 204 21/var(--tw-text-opacity,1))}#chat-widget-root .underline{text-decoration-line:underline}#chat-widget-root .no-underline{text-decoration-line:none}#chat-widget-root .placeholder-gray-400::-moz-placeholder{--tw-placeholder-opacity:1;color:rgb(156 163 175/var(--tw-placeholder-opacity,1))}#chat-widget-root .placeholder-gray-400::placeholder{--tw-placeholder-opacity:1;color:rgb(156 163 175/var(--tw-placeholder-opacity,1))}#chat-widget-root .placeholder-gray-500::-moz-placeholder{--tw-placeholder-opacity:1;color:rgb(107 114 128/var(--tw-placeholder-opacity,1))}#chat-widget-root .placeholder-gray-500::placeholder{--tw-placeholder-opacity:1;color:rgb(107 114 128/var(--tw-placeholder-opacity,1))}#chat-widget-root .opacity-0{opacity:0}#chat-widget-root .opacity-25{opacity:.25}#chat-widget-root .opacity-50{opacity:.5}#chat-widget-root .opacity-60{opacity:.6}#chat-widget-root .opacity-70{opacity:.7}#chat-widget-root .opacity-75{opacity:.75}#chat-widget-root .opacity-80{opacity:.8}#chat-widget-root .shadow{--tw-shadow:0 1px 3px 0 rgba(0,0,0,.1),0 1px 2px -1px rgba(0,0,0,.1);--tw-shadow-colored:0 1px 3px 0 var(--tw-shadow-color),0 1px 2px -1px var(--tw-shadow-color)}#chat-widget-root .shadow,#chat-widget-root .shadow-2xl{box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}#chat-widget-root .shadow-2xl{--tw-shadow:0 25px 50px -12px rgba(0,0,0,.25);--tw-shadow-colored:0 25px 50px -12px var(--tw-shadow-color)}#chat-widget-root .shadow-lg{--tw-shadow:0 10px 15px -3px rgba(0,0,0,.1),0 4px 6px -4px rgba(0,0,0,.1);--tw-shadow-colored:0 10px 15px -3px var(--tw-shadow-color),0 4px 6px -4px var(--tw-shadow-color)}#chat-widget-root .shadow-lg,#chat-widget-root .shadow-md{box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}#chat-widget-root .shadow-md{--tw-shadow:0 4px 6px -1px rgba(0,0,0,.1),0 2px 4px -2px rgba(0,0,0,.1);--tw-shadow-colored:0 4px 6px -1px var(--tw-shadow-color),0 2px 4px -2px var(--tw-shadow-color)}#chat-widget-root .shadow-none{--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000}#chat-widget-root .shadow-none,#chat-widget-root .shadow-sm{box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}#chat-widget-root .shadow-sm{--tw-shadow:0 1px 2px 0 rgba(0,0,0,.05);--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color)}#chat-widget-root .shadow-xl{--tw-shadow:0 20px 25px -5px rgba(0,0,0,.1),0 8px 10px -6px rgba(0,0,0,.1);--tw-shadow-colored:0 20px 25px -5px var(--tw-shadow-color),0 8px 10px -6px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}#chat-widget-root .shadow-black\\/20{--tw-shadow-color:rgba(0,0,0,.2);--tw-shadow:var(--tw-shadow-colored)}#chat-widget-root .shadow-gray-200\\/80{--tw-shadow-color:rgba(229,231,235,.8);--tw-shadow:var(--tw-shadow-colored)}#chat-widget-root .outline-none{outline:2px solid transparent;outline-offset:2px}#chat-widget-root .outline{outline-style:solid}#chat-widget-root .ring{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(3px + var(--tw-ring-offset-width)) var(--tw-ring-color)}#chat-widget-root .ring,#chat-widget-root .ring-2{box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}#chat-widget-root .ring-2{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color)}#chat-widget-root .ring-blue-100{--tw-ring-opacity:1;--tw-ring-color:rgb(219 234 254/var(--tw-ring-opacity,1))}#chat-widget-root .ring-blue-300{--tw-ring-opacity:1;--tw-ring-color:rgb(147 197 253/var(--tw-ring-opacity,1))}#chat-widget-root .ring-white{--tw-ring-opacity:1;--tw-ring-color:rgb(255 255 255/var(--tw-ring-opacity,1))}#chat-widget-root .blur{--tw-blur:blur(8px)}#chat-widget-root .blur,#chat-widget-root .drop-shadow{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}#chat-widget-root .drop-shadow{--tw-drop-shadow:drop-shadow(0 1px 2px rgba(0,0,0,.1)) drop-shadow(0 1px 1px rgba(0,0,0,.06))}#chat-widget-root .drop-shadow-md{--tw-drop-shadow:drop-shadow(0 4px 3px rgba(0,0,0,.07)) drop-shadow(0 2px 2px rgba(0,0,0,.06))}#chat-widget-root .drop-shadow-md,#chat-widget-root .drop-shadow-sm{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}#chat-widget-root .drop-shadow-sm{--tw-drop-shadow:drop-shadow(0 1px 1px rgba(0,0,0,.05))}#chat-widget-root .grayscale-\\[0\\.3\\]{--tw-grayscale:grayscale(0.3)}#chat-widget-root .filter,#chat-widget-root .grayscale-\\[0\\.3\\]{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}#chat-widget-root .backdrop-blur-sm{--tw-backdrop-blur:blur(4px);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia)}#chat-widget-root .transition{transition-duration:.15s;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1)}#chat-widget-root .transition-all{transition-duration:.15s;transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1)}#chat-widget-root .transition-colors{transition-duration:.15s;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1)}#chat-widget-root .transition-opacity{transition-duration:.15s;transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1)}#chat-widget-root .transition-transform{transition-duration:.15s;transition-property:transform;transition-timing-function:cubic-bezier(.4,0,.2,1)}#chat-widget-root .duration-150{transition-duration:.15s}#chat-widget-root .duration-200{transition-duration:.2s}#chat-widget-root .duration-300{transition-duration:.3s}#chat-widget-root .duration-500{transition-duration:.5s}#chat-widget-root :is(#chat-widget-root .animate-in){animation:slideIn .3s ease-out}#chat-widget-root :is(#chat-widget-root .transition-all){transition-duration:.3s;transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1)}#chat-widget-root .\\[font-family\\:inherit\\]{font-family:inherit}#chat-widget-root .placeholder\\:text-\\[\\#8C8C8C\\]::-moz-placeholder{--tw-text-opacity:1;color:rgb(140 140 140/var(--tw-text-opacity,1))}#chat-widget-root .placeholder\\:text-\\[\\#8C8C8C\\]::placeholder{--tw-text-opacity:1;color:rgb(140 140 140/var(--tw-text-opacity,1))}#chat-widget-root .placeholder\\:text-\\[\\#A2A9B2\\]::-moz-placeholder{--tw-text-opacity:1;color:rgb(162 169 178/var(--tw-text-opacity,1))}#chat-widget-root .placeholder\\:text-\\[\\#A2A9B2\\]::placeholder{--tw-text-opacity:1;color:rgb(162 169 178/var(--tw-text-opacity,1))}#chat-widget-root .hover\\:scale-105:hover{--tw-scale-x:1.05;--tw-scale-y:1.05}#chat-widget-root .hover\\:scale-105:hover,#chat-widget-root .hover\\:scale-110:hover{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}#chat-widget-root .hover\\:scale-110:hover{--tw-scale-x:1.1;--tw-scale-y:1.1}#chat-widget-root .hover\\:scale-\\[1\\.02\\]:hover{--tw-scale-x:1.02;--tw-scale-y:1.02;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}#chat-widget-root .hover\\:border-blue-400:hover{--tw-border-opacity:1;border-color:rgb(96 165 250/var(--tw-border-opacity,1))}#chat-widget-root .hover\\:border-blue-600:hover{--tw-border-opacity:1;border-color:rgb(37 99 235/var(--tw-border-opacity,1))}#chat-widget-root .hover\\:bg-blue-50:hover{--tw-bg-opacity:1;background-color:rgb(239 246 255/var(--tw-bg-opacity,1))}#chat-widget-root .hover\\:bg-blue-500\\/20:hover{background-color:rgba(59,130,246,.2)}#chat-widget-root .hover\\:bg-blue-900\\/50:hover{background-color:rgba(30,58,138,.5)}#chat-widget-root .hover\\:bg-gray-100:hover{--tw-bg-opacity:1;background-color:rgb(243 244 246/var(--tw-bg-opacity,1))}#chat-widget-root .hover\\:bg-gray-200:hover{--tw-bg-opacity:1;background-color:rgb(229 231 235/var(--tw-bg-opacity,1))}#chat-widget-root .hover\\:bg-gray-50:hover{--tw-bg-opacity:1;background-color:rgb(249 250 251/var(--tw-bg-opacity,1))}#chat-widget-root .hover\\:bg-gray-600:hover{--tw-bg-opacity:1;background-color:rgb(75 85 99/var(--tw-bg-opacity,1))}#chat-widget-root .hover\\:bg-gray-700:hover{--tw-bg-opacity:1;background-color:rgb(55 65 81/var(--tw-bg-opacity,1))}#chat-widget-root .hover\\:bg-red-600:hover{--tw-bg-opacity:1;background-color:rgb(220 38 38/var(--tw-bg-opacity,1))}#chat-widget-root .hover\\:bg-transparent:hover{background-color:transparent}#chat-widget-root .hover\\:text-blue-500:hover{--tw-text-opacity:1;color:rgb(59 130 246/var(--tw-text-opacity,1))}#chat-widget-root .hover\\:text-gray-200:hover{--tw-text-opacity:1;color:rgb(229 231 235/var(--tw-text-opacity,1))}#chat-widget-root .hover\\:text-gray-300:hover{--tw-text-opacity:1;color:rgb(209 213 219/var(--tw-text-opacity,1))}#chat-widget-root .hover\\:text-gray-600:hover{--tw-text-opacity:1;color:rgb(75 85 99/var(--tw-text-opacity,1))}#chat-widget-root .hover\\:text-gray-700:hover{--tw-text-opacity:1;color:rgb(55 65 81/var(--tw-text-opacity,1))}#chat-widget-root .hover\\:underline:hover{text-decoration-line:underline}#chat-widget-root .hover\\:opacity-80:hover{opacity:.8}#chat-widget-root .hover\\:opacity-90:hover{opacity:.9}#chat-widget-root .hover\\:shadow-md:hover{--tw-shadow:0 4px 6px -1px rgba(0,0,0,.1),0 2px 4px -2px rgba(0,0,0,.1);--tw-shadow-colored:0 4px 6px -1px var(--tw-shadow-color),0 2px 4px -2px var(--tw-shadow-color)}#chat-widget-root .hover\\:shadow-md:hover,#chat-widget-root .hover\\:shadow-xl:hover{box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}#chat-widget-root .hover\\:shadow-xl:hover{--tw-shadow:0 20px 25px -5px rgba(0,0,0,.1),0 8px 10px -6px rgba(0,0,0,.1);--tw-shadow-colored:0 20px 25px -5px var(--tw-shadow-color),0 8px 10px -6px var(--tw-shadow-color)}#chat-widget-root .hover\\:grayscale-0:hover{--tw-grayscale:grayscale(0);filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}#chat-widget-root .focus\\:\\!border-status-error:focus{border-color:hsl(var(--cw-status-error))!important}#chat-widget-root .focus\\:border-\\[\\#5A6069\\]:focus{--tw-border-opacity:1;border-color:rgb(90 96 105/var(--tw-border-opacity,1))}#chat-widget-root .focus\\:border-\\[\\#B0B0B0\\]:focus{--tw-border-opacity:1;border-color:rgb(176 176 176/var(--tw-border-opacity,1))}#chat-widget-root .focus\\:outline-none:focus{outline:2px solid transparent;outline-offset:2px}#chat-widget-root .focus\\:ring-0:focus{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(var(--tw-ring-offset-width)) var(--tw-ring-color)}#chat-widget-root .focus\\:ring-0:focus,#chat-widget-root .focus\\:ring-1:focus{box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}#chat-widget-root .focus\\:ring-1:focus{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color)}#chat-widget-root .focus\\:ring-gray-300:focus{--tw-ring-opacity:1;--tw-ring-color:rgb(209 213 219/var(--tw-ring-opacity,1))}#chat-widget-root .focus\\:ring-gray-600:focus{--tw-ring-opacity:1;--tw-ring-color:rgb(75 85 99/var(--tw-ring-opacity,1))}#chat-widget-root .focus-visible\\:outline-none:focus-visible{outline:2px solid transparent;outline-offset:2px}#chat-widget-root .focus-visible\\:ring-2:focus-visible{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}#chat-widget-root .focus-visible\\:ring-white\\/40:focus-visible{--tw-ring-color:hsla(0,0%,100%,.4)}#chat-widget-root .active\\:scale-95:active{--tw-scale-x:.95;--tw-scale-y:.95}#chat-widget-root .active\\:scale-95:active,#chat-widget-root .active\\:scale-\\[0\\.97\\]:active{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}#chat-widget-root .active\\:scale-\\[0\\.97\\]:active{--tw-scale-x:0.97;--tw-scale-y:0.97}#chat-widget-root .active\\:scale-\\[0\\.98\\]:active{--tw-scale-x:0.98;--tw-scale-y:0.98}#chat-widget-root .active\\:scale-\\[0\\.98\\]:active,#chat-widget-root .active\\:scale-\\[0\\.99\\]:active{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}#chat-widget-root .active\\:scale-\\[0\\.99\\]:active{--tw-scale-x:0.99;--tw-scale-y:0.99}#chat-widget-root .active\\:outline-none:active{outline:2px solid transparent;outline-offset:2px}#chat-widget-root .active\\:ring-0:active{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}#chat-widget-root .disabled\\:cursor-not-allowed:disabled{cursor:not-allowed}#chat-widget-root .disabled\\:opacity-40:disabled{opacity:.4}#chat-widget-root .disabled\\:opacity-50:disabled{opacity:.5}#chat-widget-root .disabled\\:shadow-none:disabled{--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}#chat-widget-root :is(.group:hover .group-hover\\:scale-100){--tw-scale-x:1;--tw-scale-y:1;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}#chat-widget-root :is(.group:hover .group-hover\\:opacity-100){opacity:1}#chat-widget-root .dark\\:text-gray-300:is(.dark *){--tw-text-opacity:1;color:rgb(209 213 219/var(--tw-text-opacity,1))}#chat-widget-root .dark\\:text-gray-400:is(.dark *){--tw-text-opacity:1;color:rgb(156 163 175/var(--tw-text-opacity,1))}#chat-widget-root .rtl\\:rounded-tl-2xl:where([dir=rtl],[dir=rtl] *){border-top-left-radius:1rem}#chat-widget-root .rtl\\:rounded-tr-sm:where([dir=rtl],[dir=rtl] *){border-top-right-radius:.125rem}#chat-widget-root .\\[\\&\\:first-child\\]\\:\\!mt-0:first-child{margin-top:0!important}#chat-widget-root :is(.\\[\\&\\>\\*\\:first-child\\]\\:\\!mt-0>:first-child){margin-top:0!important}#chat-widget-root :is(.\\[\\&\\>\\*\\:last-child\\]\\:\\!mb-0>:last-child){margin-bottom:0!important}\n.chat-widget-root{position:fixed;z-index:999999}.chat-widget-container{color:var(--cw-text-color,inherit);font-family:var(\n --cw-font-family,-apple-system,BlinkMacSystemFont,"Segoe UI","Roboto","Oxygen","Ubuntu","Cantarell","Fira Sans","Droid Sans","Helvetica Neue",sans-serif\n )}#chat-widget-root .chat-messages p{overflow-wrap:anywhere;word-break:break-word}textarea#chat-widget-input::-moz-placeholder{border:none;line-height:48px;outline:none}textarea#chat-widget-input::placeholder{border:none;line-height:48px;outline:none}textarea#chat-widget-input{border:none;line-height:48px;outline:none}@keyframes slideIn{0%{opacity:0;transform:translateY(10px)}to{opacity:1;transform:translateY(0)}}@keyframes bounce{0%,to{transform:translateY(0)}50%{transform:translateY(-5px)}}#chat-widget-root .scrollbar-hide{-ms-overflow-style:none;scrollbar-width:none}#chat-widget-root .scrollbar-hide::-webkit-scrollbar{display:none}#chat-widget-root .slim-scrollbar-x{scrollbar-width:thin}#chat-widget-root .slim-scrollbar-x::-webkit-scrollbar{height:3px!important}#chat-widget-root .slim-scrollbar-x::-webkit-scrollbar-track{background:transparent!important}#chat-widget-root .slim-scrollbar-x::-webkit-scrollbar-thumb{background:#d1d5db!important;border-radius:2px!important}#chat-widget-root .slim-scrollbar-x::-webkit-scrollbar-thumb:hover{background:#9ca3af!important}@media print{.chat-widget-root{display:none!important}}',n.appendChild(i);const s=document.createElement("div");s.id="chat-widget-mount",n.appendChild(s),a.current=t.createRoot(s)},[]),e.useEffect(()=>{var t;null===(t=a.current)||void 0===t||t.render(e.createElement(bn,r))}),e.useEffect(()=>()=>{const e=a.current;a.current=null,queueMicrotask(()=>null==e?void 0:e.unmount())},[]),n.jsx("div",{ref:o,id:"chat-widget-host"})}});
|