From f28b818cc62c7fff67517a4147e64f08ebd73027 Mon Sep 17 00:00:00 2001 From: Determinant Date: Mon, 11 Feb 2019 01:09:51 -0500 Subject: fix regression bugs --- dist/background.js | 4 ++-- dist/index.js | 4 ++-- src/Analyze.js | 22 ++++++++++++++++------ src/PatternTable.js | 8 ++++---- src/RegexField.js | 10 +++++----- src/Settings.js | 1 - src/background.js | 34 ++++++++++++++++------------------ src/gapi.js | 2 +- 8 files changed, 46 insertions(+), 39 deletions(-) diff --git a/dist/background.js b/dist/background.js index 3474615..205226e 100644 --- a/dist/background.js +++ b/dist/background.js @@ -9,7 +9,7 @@ Licensed under the MIT License (MIT), see http://jedwatson.github.io/classnames */ -!function(){"use strict";var n={}.hasOwnProperty;function a(){for(var e=[],t=0;t=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}},function(e,t){e.exports=function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}},function(e,t){e.exports=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}},function(e,t){function n(e,t){for(var n=0;n1&&void 0!==arguments[1]?arguments[1]:{};return function(n){var r,m=t.withTheme,_=void 0!==m&&m,v=t.flip,M=void 0===v?null:v,w=t.name,E=(0,d.default)(t,["withTheme","flip","name"]),P=(0,x.default)(e),A=P.themingEnabled||"string"==typeof w||_;S+=1,P.options.index=S;var C=function(e){function t(e,n){var r;(0,o.default)(this,t),(r=(0,u.default)(this,(0,l.default)(t).call(this,e,n))).jss=n[y.default.jss]||T,r.sheetsManager=D,r.unsubscribeId=null;var a=n.muiThemeProviderOptions;return a&&(a.sheetsManager&&(r.sheetsManager=a.sheetsManager),r.sheetsCache=a.sheetsCache,r.disableStylesGeneration=a.disableStylesGeneration),r.stylesCreatorSaved=P,r.sheetOptions=(0,i.default)({generateClassName:Y},n[y.default.sheetOptions]),r.theme=A?k.default.initial(n)||j:O,r.attach(r.theme),r.cacheClasses={value:null,lastProp:null,lastJSS:{}},r}return(0,c.default)(t,e),(0,s.default)(t,[{key:"componentDidMount",value:function(){var e=this;A&&(this.unsubscribeId=k.default.subscribe(this.context,function(t){var n=e.theme;e.theme=t,e.attach(e.theme),e.setState({},function(){e.detach(n)})}))}},{key:"componentDidUpdate",value:function(){this.stylesCreatorSaved}},{key:"componentWillUnmount",value:function(){this.detach(this.theme),null!==this.unsubscribeId&&k.default.unsubscribe(this.context,this.unsubscribeId)}},{key:"getClasses",value:function(){if(this.disableStylesGeneration)return this.props.classes||{};var e=!1,t=b.default.get(this.sheetsManager,this.stylesCreatorSaved,this.theme);return t.sheet.classes!==this.cacheClasses.lastJSS&&(this.cacheClasses.lastJSS=t.sheet.classes,e=!0),this.props.classes!==this.cacheClasses.lastProp&&(this.cacheClasses.lastProp=this.props.classes,e=!0),e&&(this.cacheClasses.value=(0,g.default)({baseClasses:this.cacheClasses.lastJSS,newClasses:this.props.classes,Component:n})),this.cacheClasses.value}},{key:"attach",value:function(e){if(!this.disableStylesGeneration){var t=this.stylesCreatorSaved,n=b.default.get(this.sheetsManager,t,e);if(n||(n={refs:0,sheet:null},b.default.set(this.sheetsManager,t,e,n)),0===n.refs){var r;this.sheetsCache&&(r=b.default.get(this.sheetsCache,t,e)),r||((r=this.createSheet(e)).attach(),this.sheetsCache&&b.default.set(this.sheetsCache,t,e,r)),n.sheet=r;var a=this.context[y.default.sheetsRegistry];a&&a.add(r)}n.refs+=1}}},{key:"createSheet",value:function(e){var t=this.stylesCreatorSaved.create(e,w),r=w;return this.jss.createStyleSheet(t,(0,i.default)({meta:r,classNamePrefix:r,flip:"boolean"==typeof M?M:"rtl"===e.direction,link:!1},this.sheetOptions,this.stylesCreatorSaved.options,{name:w||n.displayName},E))}},{key:"detach",value:function(e){if(!this.disableStylesGeneration){var t=b.default.get(this.sheetsManager,this.stylesCreatorSaved,e);if(t.refs-=1,0===t.refs){b.default.delete(this.sheetsManager,this.stylesCreatorSaved,e),this.jss.removeStyleSheet(t.sheet);var n=this.context[y.default.sheetsRegistry];n&&n.remove(t.sheet)}}}},{key:"render",value:function(){var e=this.props,t=(e.classes,e.innerRef),r=(0,d.default)(e,["classes","innerRef"]),a=(0,L.default)({theme:this.theme,name:w,props:r});return _&&!a.theme&&(a.theme=this.theme),f.default.createElement(n,(0,i.default)({},a,{classes:this.getClasses(),ref:t}))}}]),t}(f.default.Component);return C.contextTypes=(0,i.default)((r={muiThemeProviderOptions:h.default.object},(0,a.default)(r,y.default.jss,h.default.object),(0,a.default)(r,y.default.sheetOptions,h.default.object),(0,a.default)(r,y.default.sheetsRegistry,h.default.object),r),A?k.default.contextTypes:{}),(0,p.default)(C,n),C}});t.default=function(e,t){return m.ponyfillGlobal.__MUI_STYLES__.withStyles(e,(0,i.default)({defaultTheme:j},t))}},function(e,t,n){var r=n(55),a=n(11);e.exports=function(e,t){return!t||"object"!==r(t)&&"function"!=typeof t?a(e):t}},function(e,t){function n(t){return e.exports=n=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},n(t)}e.exports=n},function(e,t,n){var r=n(343);e.exports=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}}),t&&r(e,t)}},function(e,t,n){"use strict";var r=function(){};e.exports=r},function(e,t){e.exports=function(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}},function(e,t,n){"use strict";var r=n(3);Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"createGenerateClassName",{enumerable:!0,get:function(){return a.default}}),Object.defineProperty(t,"createMuiTheme",{enumerable:!0,get:function(){return i.default}}),Object.defineProperty(t,"jssPreset",{enumerable:!0,get:function(){return o.default}}),Object.defineProperty(t,"MuiThemeProvider",{enumerable:!0,get:function(){return s.default}}),Object.defineProperty(t,"createStyles",{enumerable:!0,get:function(){return u.default}}),Object.defineProperty(t,"withStyles",{enumerable:!0,get:function(){return l.default}}),Object.defineProperty(t,"withTheme",{enumerable:!0,get:function(){return c.default}});var a=r(n(118)),i=r(n(87)),o=r(n(126)),s=r(n(394)),u=r(n(397)),l=r(n(15)),c=r(n(113))},,function(e,t,n){var r=n(261),a="object"==typeof self&&self&&self.Object===Object&&self,i=r||a||Function("return this")();e.exports=i},function(e,t,n){var r=n(432),a=n(478),i=n(43),o=n(8),s=n(487);e.exports=function(e){return"function"==typeof e?e:null==e?i:"object"==typeof e?o(e)?a(e[0],e[1]):r(e):s(e)}},function(e,t,n){"use strict";!function e(){if("undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE)try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(e){console.error(e)}}(),e.exports=n(340)},function(e,t,n){var r=n(100);e.exports=function(e,t){return r(e,t)}},function(e,t,n){"use strict";n.d(t,"c",function(){return y}),n.d(t,"a",function(){return g}),n.d(t,"b",function(){return b});var r=n(12),a=n.n(r),i=n(13),o=n.n(i),s=n(7),u=n.n(s),l="updatePatterns",c="getPatterns",d="updateCalendars",f="getCalendars",h="getCalEvents",p="updateConfig",m="getConfig",_="getGraphData",y=Object.freeze({updatePatterns:Symbol(l),getPatterns:Symbol(c),updateCalendars:Symbol(d),getCalendars:Symbol(f),getCalEvents:Symbol(h),updateConfig:Symbol(p),getConfig:Symbol(m),getGraphData:Symbol(_)});function v(e){switch(e){case y.updatePatterns:return l;case y.getPatterns:return c;case y.updateCalendars:return d;case y.getCalendars:return f;case y.getCalEvents:return h;case y.updateConfig:return p;case y.getConfig:return m;case y.getGraphData:return _;default:console.error("unreachable")}}var g=function(){function e(t,n,r){a()(this,e),this.id=t,this.type=n,this.data=r}return o()(e,[{key:"genResp",value:function(t){return new e(this.id,this.type,t)}},{key:"deflate",value:function(){return{id:this.id,type:v(this.type),data:this.data}}}]),e}();u()(g,"inflate",function(e){return new g(e.id,function(e){switch(e){case l:return y.updatePatterns;case c:return y.getPatterns;case d:return y.updateCalendars;case f:return y.getCalendars;case h:return y.getCalEvents;case p:return y.updateConfig;case m:return y.getConfig;case _:return y.getGraphData;default:console.error("unreachable")}}(e.type),e.data)});var b=function e(t){var n=this;a()(this,e),u()(this,"sendMsg",function(e){var t,r,a=e.type,i=e.data,o=n.requestCallback,s=new Promise(function(e){t=e});return r=o.ids.length>0?o.ids.pop():o.maxId++,o.inFlight[r]=t,n.port.postMessage(new g(r,a,i).deflate()),s});var r=chrome.runtime.connect({name:t});r.onMessage.addListener(function(e){console.log(e);var t=(e.type,n.requestCallback),r=t.inFlight[e.id];console.assert(void 0!==r),t.ids.push(e.id),r(e)}),this.port=r,this.requestCallback={inFlight:{},ids:[],maxId:0}}},function(e,t){e.exports=function(e){return null!=e&&"object"==typeof e}},function(e,t,n){var r=n(30),a=n(8),i=n(28),o="[object String]";e.exports=function(e){return"string"==typeof e||!a(e)&&i(e)&&r(e)==o}},function(e,t,n){var r=n(53),a=n(413),i=n(414),o="[object Null]",s="[object Undefined]",u=r?r.toStringTag:void 0;e.exports=function(e){return null==e?void 0===e?s:o:u&&u in Object(e)?a(e):i(e)}},function(e,t,n){(function(t){for(var r=n(519),a="undefined"==typeof window?t:window,i=["moz","webkit"],o="AnimationFrame",s=a["request"+o],u=a["cancel"+o]||a["cancelRequest"+o],l=0;!s&&l1&&void 0!==arguments[1]&&arguments[1];if(!Array.isArray(e))return e;var n="";if(Array.isArray(e[0]))for(var a=0;a0&&void 0!==arguments[0]?arguments[0]:"unnamed",t=arguments[1],n=arguments[2],o=n.jss,s=(0,i.default)(t),u=o.plugins.onCreateRule(e,s,n);if(u)return u;"@"===e[0]&&(0,r.default)(!1,"[JSS] Unknown at-rule %s",e);return new a.default(e,s,n)};var r=o(n(39)),a=o(n(40)),i=o(n(365));function o(e){return e&&e.__esModule?e:{default:e}}},function(e,t,n){"use strict";n.r(t),n.d(t,"isBrowser",function(){return a});var r="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},a="object"===("undefined"==typeof window?"undefined":r(window))&&"object"===("undefined"==typeof document?"undefined":r(document))&&9===document.nodeType;t.default=a},function(e,t,n){var r=n(263),a=n(431)(r);e.exports=a},function(e,t,n){var r=n(422),a=n(428),i=n(42);e.exports=function(e){return i(e)?r(e):a(e)}},function(e,t,n){var r=n(434),a=n(435),i=n(436),o=n(437),s=n(438);function u(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t1&&o(e,t[0],t[1])?t=[]:n>2&&o(t[0],t[1],t[2])&&(t=[t[0]]),a(e,r(t,1),[])});e.exports=s},function(e,t,n){"use strict";var r=s(n(530)),a=s(n(534)),i=s(n(107)),o=s(n(80));function s(e){return e&&e.__esModule?e:{default:e}}e.exports={Transition:o.default,TransitionGroup:i.default,ReplaceTransition:a.default,CSSTransition:r.default}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r={50:"#fff3e0",100:"#ffe0b2",200:"#ffcc80",300:"#ffb74d",400:"#ffa726",500:"#ff9800",600:"#fb8c00",700:"#f57c00",800:"#ef6c00",900:"#e65100",A100:"#ffd180",A200:"#ffab40",A400:"#ff9100",A700:"#ff6d00"};t.default=r},function(e,t,n){var r,a=n(511),i=n(512),o=n(514),s=100,u=/(\+|\-|\*|\\|[^a-z]|)(\s*)(\()/g;e.exports=function(e,t){function n(e,i,l){if(r++>s)throw r=0,new Error("Call stack overflow for "+l);if(""===e)throw new Error(i+"(): '"+l+"' must contain a non-whitespace string");var c=function(e){var t=[],n=[],r=/[\.0-9]([%a-z]+)/gi,a=r.exec(e);for(;a;)a&&a[1]&&(-1===n.indexOf(a[1].toLowerCase())&&(t.push(a[1]),n.push(a[1].toLowerCase())),a=r.exec(e));return t}(e=function(e,t){e=e.replace(/((?:\-[a-z]+\-)?calc)/g,"");var r,i="",o=e;for(;r=u.exec(o);){r[0].index>0&&(i+=o.substring(0,r[0].index));var s=a("(",")",o.substring([0].index));if(""===s.body)throw new Error("'"+e+"' must contain a non-whitespace string");var l=n(s.body,"",t);i+=s.pre+l,o=s.post}return i+o}(e,l));if(c.length>1||e.indexOf("var(")>-1)return i+"("+e+")";var d=c[0]||"";"%"===d&&(e=e.replace(/\b[0-9\.]+%/g,function(e){return.01*parseFloat(e.slice(0,-1))}));var f,h=e.replace(new RegExp(d,"gi"),"");try{f=o.eval(h)}catch(t){return i+"("+e+")"}return"%"===d&&(f*=100),(i.length||"%"===d)&&(f=Math.round(f*t)/t),f+=d}return r=0,t=Math.pow(10,void 0===t?5:t),e=e.replace(/\n+/g," "),i(e,/((?:\-[a-z]+\-)?calc)\(/,n)}},,,function(e,t,n){"use strict";t.__esModule=!0,t.default=t.EXITING=t.ENTERED=t.ENTERING=t.EXITED=t.UNMOUNTED=void 0;var r=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){var r=Object.defineProperty&&Object.getOwnPropertyDescriptor?Object.getOwnPropertyDescriptor(e,n):{};r.get||r.set?Object.defineProperty(t,n,r):t[n]=e[n]}return t.default=e,t}(n(0)),a=s(n(1)),i=s(n(25)),o=n(289);n(290);function s(e){return e&&e.__esModule?e:{default:e}}var u="unmounted";t.UNMOUNTED=u;var l="exited";t.EXITED=l;var c="entering";t.ENTERING=c;var d="entered";t.ENTERED=d;t.EXITING="exiting";var f=function(e){var t,n;function r(t,n){var r;r=e.call(this,t,n)||this;var a,i=n.transitionGroup,o=i&&!i.isMounting?t.enter:t.appear;return r.appearStatus=null,t.in?o?(a=l,r.appearStatus=c):a=d:a=t.unmountOnExit||t.mountOnEnter?u:l,r.state={status:a},r.nextCallback=null,r}n=e,(t=r).prototype=Object.create(n.prototype),t.prototype.constructor=t,t.__proto__=n;var o=r.prototype;return o.getChildContext=function(){return{transitionGroup:null}},r.getDerivedStateFromProps=function(e,t){return e.in&&t.status===u?{status:l}:null},o.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},o.componentDidUpdate=function(e){var t=null;if(e!==this.props){var n=this.state.status;this.props.in?n!==c&&n!==d&&(t=c):n!==c&&n!==d||(t="exiting")}this.updateStatus(!1,t)},o.componentWillUnmount=function(){this.cancelNextCallback()},o.getTimeouts=function(){var e,t,n,r=this.props.timeout;return e=t=n=r,null!=r&&"number"!=typeof r&&(e=r.exit,t=r.enter,n=r.appear),{exit:e,enter:t,appear:n}},o.updateStatus=function(e,t){if(void 0===e&&(e=!1),null!==t){this.cancelNextCallback();var n=i.default.findDOMNode(this);t===c?this.performEnter(n,e):this.performExit(n)}else this.props.unmountOnExit&&this.state.status===l&&this.setState({status:u})},o.performEnter=function(e,t){var n=this,r=this.props.enter,a=this.context.transitionGroup?this.context.transitionGroup.isMounting:t,i=this.getTimeouts();t||r?(this.props.onEnter(e,a),this.safeSetState({status:c},function(){n.props.onEntering(e,a),n.onTransitionEnd(e,i.enter,function(){n.safeSetState({status:d},function(){n.props.onEntered(e,a)})})})):this.safeSetState({status:d},function(){n.props.onEntered(e)})},o.performExit=function(e){var t=this,n=this.props.exit,r=this.getTimeouts();n?(this.props.onExit(e),this.safeSetState({status:"exiting"},function(){t.props.onExiting(e),t.onTransitionEnd(e,r.exit,function(){t.safeSetState({status:l},function(){t.props.onExited(e)})})})):this.safeSetState({status:l},function(){t.props.onExited(e)})},o.cancelNextCallback=function(){null!==this.nextCallback&&(this.nextCallback.cancel(),this.nextCallback=null)},o.safeSetState=function(e,t){t=this.setNextCallback(t),this.setState(e,t)},o.setNextCallback=function(e){var t=this,n=!0;return this.nextCallback=function(r){n&&(n=!1,t.nextCallback=null,e(r))},this.nextCallback.cancel=function(){n=!1},this.nextCallback},o.onTransitionEnd=function(e,t,n){this.setNextCallback(n),e?(this.props.addEndListener&&this.props.addEndListener(e,this.nextCallback),null!=t&&setTimeout(this.nextCallback,t)):setTimeout(this.nextCallback,0)},o.render=function(){var e=this.state.status;if(e===u)return null;var t=this.props,n=t.children,r=function(e,t){if(null==e)return{};var n,r,a={},i=Object.keys(e);for(r=0;r=0||(a[n]=e[n]);return a}(t,["children"]);if(delete r.in,delete r.mountOnEnter,delete r.unmountOnExit,delete r.appear,delete r.enter,delete r.exit,delete r.timeout,delete r.addEndListener,delete r.onEnter,delete r.onEntering,delete r.onEntered,delete r.onExit,delete r.onExiting,delete r.onExited,"function"==typeof n)return n(e,r);var i=a.default.Children.only(n);return a.default.cloneElement(i,r)},r}(a.default.Component);function h(){}f.contextTypes={transitionGroup:r.object},f.childContextTypes={transitionGroup:function(){}},f.propTypes={},f.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:h,onEntering:h,onEntered:h,onExit:h,onExiting:h,onExited:h},f.UNMOUNTED=0,f.EXITED=1,f.ENTERING=2,f.ENTERED=3,f.EXITING=4;var p=(0,o.polyfill)(f);t.default=p},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r={50:"#e0f7fa",100:"#b2ebf2",200:"#80deea",300:"#4dd0e1",400:"#26c6da",500:"#00bcd4",600:"#00acc1",700:"#0097a7",800:"#00838f",900:"#006064",A100:"#84ffff",A200:"#18ffff",A400:"#00e5ff",A700:"#00b8d4"};t.default=r},,function(e,t,n){"use strict";n.d(t,"e",function(){return v}),n.d(t,"b",function(){return g}),n.d(t,"f",function(){return b}),n.d(t,"g",function(){return M}),n.d(t,"c",function(){return k}),n.d(t,"d",function(){return w}),n.d(t,"a",function(){return L});var r=n(12),a=n.n(r),i=n(13),o=n.n(i),s=n(49),u=n.n(s),l=n(105),c=n.n(l),d=n(543),f=n.n(d),h="https://www.googleapis.com/calendar/v3",p=Object.freeze({invalidSyncToken:Symbol("invalidSyncToken"),notLoggedIn:Symbol("notLoggedIn"),notLoggedOut:Symbol("notLoggedOut"),otherError:Symbol("otherError")});function m(e){return Object.entries(e).filter(function(e){var t=c()(e,2);t[0];return t[1]}).map(function(e){var t=c()(e,2),n=t[0],r=t[1];return"".concat(encodeURIComponent(n),"=").concat(encodeURIComponent(r))}).join("&")}var _=null;function y(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];return new Promise(function(t){return chrome.identity.getAuthToken({interactive:e},function(e){return t([e,!chrome.runtime.lastError])})}).then(function(e){var t=c()(e,2),n=t[0];if(t[1])return n;throw p.notLoggedIn})}function v(){return null===_?y(!1).then(function(){return _=!0}).catch(function(){return _=!1}).then(function(){return _}):Promise.resolve(_)}function g(){return v().then(function(e){if(e)return y(!1);throw p.notLoggedIn})}function b(){return v().then(function(e){if(e)throw p.notLoggedOut;return y(!0).then(function(){return _=!0})})}function M(){return g().then(function(e){return fetch("https://accounts.google.com/o/oauth2/revoke?".concat(m({token:e})),{method:"GET",async:!0}).then(function(t){return function(e){return new Promise(function(t){return chrome.identity.removeCachedAuthToken({token:e},function(){return t()})})}(e)})}).then(function(){return _=!1})}function k(e){return fetch("".concat(h,"/users/me/calendarList?").concat(m({access_token:e})),{method:"GET",async:!0}).then(function(e){return e.json()}).then(function(e){return e.items})}function w(e){return fetch("".concat(h,"/colors?").concat(m({access_token:e})),{method:"GET",async:!0}).then(function(e){return e.json()})}function x(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null,i=arguments.length>5&&void 0!==arguments[5]?arguments[5]:100,o=[];return function n(s,l){return fetch("".concat(h,"/calendars/").concat(e,"/events?").concat(m({access_token:t,pageToken:s,syncToken:l,timeMin:r,timeMax:a,maxResults:i})),{method:"GET",async:!0}).then(function(e){if(200===e.status)return e.json();throw 410===e.status?p.invalidSyncToken:p.otherError}).then(function(e){return o.push.apply(o,u()(e.items)),e.nextPageToken?n(e.nextPageToken,""):{nextSyncToken:e.nextSyncToken,results:o}})}("",n)}var L=function(){function e(t,n){var r=this,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{maxCachedItems:100,nDaysPerSlot:10,largeQuery:10};a()(this,e),this.calId=t,this.name=n,this.syncToken="",this.cache=new f.a({max:i.maxCachedItems,dispose:function(e,t){return r.onRemoveSlot(e,t)}}),this.eventMeta={},this.options=i,this.divider=864e5*this.options.nDaysPerSlot}return o()(e,[{key:"dateToCacheKey",value:function(e){return Math.floor(e/this.divider)}},{key:"dateRangeToCacheKeys",value:function(e){return{start:this.dateToCacheKey(e.start),end:this.dateToCacheKey(new Date(e.end.getTime()-1))}}},{key:"getSlot",value:function(e){if(this.cache.has(e))return this.cache.get(e);var t={};return this.cache.set(e,t),t}},{key:"onRemoveSlot",value:function(e,t){for(var n in t){console.assert(this.eventMeta[n]);var r=this.eventMeta[n].keys;r.delete(e),0===r.size&&delete this.eventMeta[n]}}},{key:"slotStartDate",value:function(e){return new Date(e*this.divider)}},{key:"slotEndDate",value:function(e){return new Date((e+1)*this.divider)}},{key:"addEvent",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];this.eventMeta.hasOwnProperty(e.id)&&this.removeEvent(e);for(var n=this.dateRangeToCacheKeys(e),r=n.start,a=n.end,i=this.cache.length,o=new Set,s=r;s<=a;s++)o.add(s),this.cache.has(s)||i++;if(this.eventMeta[e.id]={keys:o,summary:e.summary},t||!(i>this.options.maxCachedItems))if(r===a)this.getSlot(r)[e.id]={start:e.start,end:e.end,id:e.id};else{this.getSlot(r)[e.id]={start:e.start,end:this.slotEndDate(r),id:e.id},this.getSlot(a)[e.id]={start:this.slotStartDate(a),end:e.end,id:e.id};for(var u=r+1;u=n||r[i].end<=t||a.push({id:i,start:r[i].startn?n:r[i].end,summary:this.eventMeta[i].summary});return a}},{key:"getCachedEvents",value:function(e){for(var t=this.dateRangeToCacheKeys(e),n=t.start,r=t.end,a=this.getSlotEvents(n,e.start,e.end),i=n+1;in&&a.push.apply(a,u()(this.getSlotEvents(r,e.start,e.end))),a}},{key:"sync",value:function(){var e=this;return this.token.then(function(t){return x(e.calId,t,e.syncToken).then(function(n){var r=n.results.map(function(n){return n.start?Promise.resolve(n):function(e,t,n){return fetch("".concat(h,"/calendars/").concat(e,"/events/").concat(t,"?").concat(m({access_token:n})),{method:"GET",async:!0}).then(function(e){return e.json()})}(e.calId,n.id,t)});return Promise.all(r).then(function(t){t.forEach(function(t){t.start=new Date(t.start.dateTime),t.end=new Date(t.end.dateTime),"confirmed"===t.status?e.addEvent(t):"cancelled"===t.status&&e.removeEvent(t)}),e.syncToken=n.nextSyncToken})})}).catch(function(t){if(t!==p.invalidSyncToken)throw t;e.syncToken="",e.sync()})}},{key:"getEvents",value:function(e,t){for(var n=this,r=this.dateRangeToCacheKeys({start:e,end:t}),a={},i=r.start;i<=r.end;i++)this.cache.has(i)||(a.hasOwnProperty("start")||(a.start=i),a.end=i);return console.log("start: ".concat(e," end: ").concat(t)),a.hasOwnProperty("start")?(console.assert(a.start<=a.end),a.end-a.start+1>this.options.largeQuery?(console.log("encounter large query, use direct fetch"),this.token.then(function(r){return x(n.calId,r,null,e.toISOString(),t.toISOString()).then(function(n){var r=[];return n.results.forEach(function(e){console.assert(e.start),e.start=new Date(e.start.dateTime),e.end=new Date(e.end.dateTime),r.push(e)}),r.filter(function(n){return!(n.start>=t||n.end<=e)}).map(function(n){return{id:n.id,start:n.startt?t:n.end,summary:n.summary}})})})):(console.log("fetching short event list"),this.token.then(function(e){return x(n.calId,e,null,n.slotStartDate(a.start).toISOString(),n.slotEndDate(a.end).toISOString()).then(function(e){e.results.forEach(function(e){"confirmed"===e.status&&(console.assert(e.start),e.start=new Date(e.start.dateTime),e.end=new Date(e.end.dateTime),n.addEvent(e,!0))}),""===n.syncToken&&(n.syncToken=e.nextSyncToken)})}).then(function(){return n.sync()}).then(function(){return n.getCachedEvents({start:e,end:t})}))):(console.log("cache hit"),this.sync().then(function(){return n.getCachedEvents({start:e,end:t})}))}},{key:"token",get:function(){return g()}}]),e}()},function(e,t,n){"use strict";var r=n(3);Object.defineProperty(t,"__esModule",{value:!0}),t.convertHexToRGB=i,t.rgbToHex=function(e){if(0===e.indexOf("#"))return e;var t=o(e).values;return t=t.map(function(e){return 1===(t=e.toString(16)).length?"0".concat(t):t;var t}),"#".concat(t.join(""))},t.decomposeColor=o,t.recomposeColor=s,t.getContrastRatio=function(e,t){var n=u(e),r=u(t);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)},t.getLuminance=u,t.emphasize=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:.15;return u(e)>.5?l(e,t):c(e,t)},t.fade=function(e,t){if(!e)return e;e=o(e),t=a(t),("rgb"===e.type||"hsl"===e.type)&&(e.type+="a");return e.values[3]=t,s(e)},t.darken=l,t.lighten=c;r(n(19));function a(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;return en?n:e}function i(e){e=e.substr(1);var t=new RegExp(".{1,".concat(e.length/3,"}"),"g"),n=e.match(t);return n&&1===n[0].length&&(n=n.map(function(e){return e+e})),n?"rgb(".concat(n.map(function(e){return parseInt(e,16)}).join(", "),")"):""}function o(e){if("#"===e.charAt(0))return o(i(e));var t=e.indexOf("("),n=e.substring(0,t),r=e.substring(t+1,e.length-1).split(",");return{type:n,values:r=r.map(function(e){return parseFloat(e)})}}function s(e){var t=e.type,n=e.values;return-1!==t.indexOf("rgb")&&(n=n.map(function(e,t){return t<3?parseInt(e,10):e})),-1!==t.indexOf("hsl")&&(n[1]="".concat(n[1],"%"),n[2]="".concat(n[2],"%")),"".concat(e.type,"(").concat(n.join(", "),")")}function u(e){var t=o(e);if(-1!==t.type.indexOf("rgb")){var n=t.values.map(function(e){return(e/=255)<=.03928?e/12.92:Math.pow((e+.055)/1.055,2.4)});return Number((.2126*n[0]+.7152*n[1]+.0722*n[2]).toFixed(3))}return t.values[2]/100}function l(e,t){if(!e)return e;if(e=o(e),t=a(t),-1!==e.type.indexOf("hsl"))e.values[2]*=1-t;else if(-1!==e.type.indexOf("rgb"))for(var n=0;n<3;n+=1)e.values[n]*=1-t;return s(e)}function c(e,t){if(!e)return e;if(e=o(e),t=a(t),-1!==e.type.indexOf("hsl"))e.values[2]+=(100-e.values[2])*t;else if(-1!==e.type.indexOf("rgb"))for(var n=0;n<3;n+=1)e.values[n]+=(255-e.values[n])*t;return s(e)}},,,function(e,t,n){"use strict";var r=n(3);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;r(n(7));var a=r(n(9)),i=r(n(10)),o=r(n(60)),s=r(n(347)),u=(r(n(19)),r(n(119))),l=r(n(349)),c=r(n(350)),d=r(n(356)),f=r(n(358)),h=r(n(359)),p=r(n(360)),m=r(n(111)),_=r(n(361));var y=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.breakpoints,n=void 0===t?{}:t,r=e.mixins,y=void 0===r?{}:r,v=e.palette,g=void 0===v?{}:v,b=e.shadows,M=e.spacing,k=void 0===M?{}:M,w=e.typography,x=void 0===w?{}:w,L=(0,i.default)(e,["breakpoints","mixins","palette","shadows","spacing","typography"]),T=(0,c.default)(g),Y=(0,u.default)(n),S=(0,a.default)({},p.default,k);return(0,a.default)({breakpoints:Y,direction:"ltr",mixins:(0,l.default)(Y,S,y),overrides:{},palette:T,props:{},shadows:b||f.default,typography:(0,d.default)(T,x)},(0,o.default)({shape:h.default,spacing:S,transitions:m.default,zIndex:_.default},L,{isMergeableObject:s.default}))};t.default=y},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r="";if(!t)return r;var a=n.indent,s=void 0===a?0:a,u=t.fallbacks;if(s++,u)if(Array.isArray(u))for(var l=0;l-1&&e%1==0&&e-1&&e%1==0&&e<=n}},function(e,t){e.exports=function(e){return function(t){return e(t)}}},function(e,t){e.exports=function(e,t){return e===t||e!=e&&t!=t}},function(e,t,n){var r=n(34)(n(23),"Map");e.exports=r},function(e,t,n){var r=n(448),a=n(455),i=n(457),o=n(458),s=n(459);function u(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t=0||(a[n]=e[n]);return a}(e,["component","childFactory"]),i=c(this.state.children).map(n);return delete r.appear,delete r.enter,delete r.exit,null===t?i:a.default.createElement(t,r,i)},r}(a.default.Component);d.childContextTypes={transitionGroup:r.default.object.isRequired},d.propTypes={},d.defaultProps={component:"div",childFactory:function(e){return e}};var f=(0,i.polyfill)(d);t.default=f,e.exports=t.default},function(e,t,n){var r=n(411),a=n(20),i="Expected a function";e.exports=function(e,t,n){var o=!0,s=!0;if("function"!=typeof e)throw new TypeError(i);return a(n)&&(o="leading"in n?!!n.leading:o,s="trailing"in n?!!n.trailing:s),r(e,t,{leading:o,maxWait:t,trailing:s})}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r={50:"#fbe9e7",100:"#ffccbc",200:"#ffab91",300:"#ff8a65",400:"#ff7043",500:"#ff5722",600:"#f4511e",700:"#e64a19",800:"#d84315",900:"#bf360c",A100:"#ff9e80",A200:"#ff6e40",A400:"#ff3d00",A700:"#dd2c00"};t.default=r},,function(e,t,n){"use strict";var r=n(3);Object.defineProperty(t,"__esModule",{value:!0}),t.default=t.isNumber=t.isString=t.formatMs=t.duration=t.easing=void 0;var a=r(n(10)),i=(r(n(19)),{easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",easeIn:"cubic-bezier(0.4, 0, 1, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"});t.easing=i;var o={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};t.duration=o;var s=function(e){return"".concat(Math.round(e),"ms")};t.formatMs=s;t.isString=function(e){return"string"==typeof e};t.isNumber=function(e){return!isNaN(parseFloat(e))};var u={easing:i,duration:o,create:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:["all"],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.duration,r=void 0===n?o.standard:n,u=t.easing,l=void 0===u?i.easeInOut:u,c=t.delay,d=void 0===c?0:c;(0,a.default)(t,["duration","easing","delay"]);return(Array.isArray(e)?e:[e]).map(function(e){return"".concat(e," ").concat("string"==typeof r?r:s(r)," ").concat(l," ").concat("string"==typeof d?d:s(d))}).join(",")},getAutoHeightDuration:function(e){if(!e)return 0;var t=e/36;return Math.round(10*(4+15*Math.pow(t,.25)+t/5))}};t.default=u},function(e,t,n){"use strict";var r=n(121),a={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},i={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},o={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},s={};function u(e){return r.isMemo(e)?o:s[e.$$typeof]||a}s[r.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0};var l=Object.defineProperty,c=Object.getOwnPropertyNames,d=Object.getOwnPropertySymbols,f=Object.getOwnPropertyDescriptor,h=Object.getPrototypeOf,p=Object.prototype;e.exports=function e(t,n,r){if("string"!=typeof n){if(p){var a=h(n);a&&a!==p&&e(t,a,r)}var o=c(n);d&&(o=o.concat(d(n)));for(var s=u(t),m=u(n),_=0;_0?1:-1},z=function(e){return O()(e)&&e.indexOf("%")===e.length-1},U=function(e){return W()(e)&&!I()(e)},B=function(e){return U(e)||O()(e)},G=0,V=function(e){var t=++G;return"".concat(e||"").concat(t)},J=function(e,t){var n,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,a=arguments.length>3&&void 0!==arguments[3]&&arguments[3];if(!U(e)&&!O()(e))return r;if(z(e)){var i=e.indexOf("%");n=t*parseFloat(e.slice(0,i))/100}else n=+e;return I()(n)&&(n=r),a&&n>t&&(n=t),n},q=function(e){if(!e)return null;var t=Object.keys(e);return t&&t.length?e[t[0]]:null},$=function(e,t){return U(e)&&U(t)?function(n){return e+n*(t-e)}:function(){return t}},K=function(e,t,n){return e&&e.length?e.find(function(e){return e&&H()(e,t)===n}):null};function X(e,t){for(var n in e)if({}.hasOwnProperty.call(e,n)&&(!{}.hasOwnProperty.call(t,n)||e[n]!==t[n]))return!1;for(var r in t)if({}.hasOwnProperty.call(t,r)&&!{}.hasOwnProperty.call(e,r))return!1;return!0}function Q(e,t){return!X(e,this.props)||!X(t,this.state)}function Z(e){e.prototype.shouldComponentUpdate=Q}function ee(e){return function(e){if(Array.isArray(e)){for(var t=0,n=new Array(e.length);t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var ne={alignmentBaseline:s.a.string,angle:s.a.number,baselineShift:s.a.string,clip:s.a.string,clipPath:s.a.string,clipRule:s.a.string,color:s.a.string,colorInterpolation:s.a.string,colorInterpolationFilters:s.a.string,colorProfile:s.a.string,colorRendering:s.a.string,cursor:s.a.string,direction:s.a.oneOf(["ltr","rtl","inherit"]),display:s.a.string,dominantBaseline:s.a.string,enableBackground:s.a.string,fill:s.a.string,fillOpacity:s.a.oneOfType([s.a.string,s.a.number]),fillRule:s.a.oneOf(["nonzero","evenodd","inherit"]),filter:s.a.string,floodColor:s.a.string,floodOpacity:s.a.oneOfType([s.a.string,s.a.number]),font:s.a.string,fontFamily:s.a.string,fontSize:s.a.oneOfType([s.a.number,s.a.string]),fontSizeAdjust:s.a.oneOfType([s.a.number,s.a.string]),fontStretch:s.a.oneOf(["normal","wider","narrower","ultra-condensed","extra-condensed","condensed","semi-condensed","semi-expanded","expanded","extra-expanded","ultra-expanded","inherit"]),fontStyle:s.a.oneOf(["normal","italic","oblique","inherit"]),fontVariant:s.a.oneOf(["normal","small-caps","inherit"]),fontWeight:s.a.oneOf(["normal","bold","bolder","lighter",100,200,300,400,500,600,700,800,900,"inherit"]),glyphOrientationHorizontal:s.a.string,glyphOrientationVertical:s.a.string,imageRendering:s.a.oneOf(["auto","optimizeSpeed","optimizeQuality","inherit"]),kerning:s.a.oneOfType([s.a.number,s.a.string]),letterSpacing:s.a.oneOfType([s.a.number,s.a.string]),lightingColor:s.a.string,lineHeight:s.a.oneOfType([s.a.number,s.a.string]),markerEnd:s.a.string,markerMid:s.a.string,markerStart:s.a.string,mask:s.a.string,opacity:s.a.oneOfType([s.a.number,s.a.string]),overflow:s.a.oneOf(["visible","hidden","scroll","auto","inherit"]),pointerEvents:s.a.oneOf(["visiblePainted","visibleFill","visibleStroke","visible","painted","fill","stroke","all","none","inherit"]),shapeRendering:s.a.oneOf(["auto","optimizeSpeed","crispEdges","geometricPrecision","inherit"]),stopColor:s.a.string,stopOpacity:s.a.oneOfType([s.a.number,s.a.string]),stroke:s.a.oneOfType([s.a.number,s.a.string]),strokeDasharray:s.a.string,strokeDashoffset:s.a.oneOfType([s.a.number,s.a.string]),strokeLinecap:s.a.oneOf(["butt","round","square","inherit"]),strokeLinejoin:s.a.oneOf(["miter","round","bevel","inherit"]),strokeMiterlimit:s.a.oneOfType([s.a.number,s.a.string]),strokeOpacity:s.a.oneOfType([s.a.number,s.a.string]),strokeWidth:s.a.oneOfType([s.a.number,s.a.string]),textAnchor:s.a.oneOf(["start","middle","end","inherit"]),textDecoration:s.a.oneOf(["none","underline","overline","line-through","blink","inherit"]),textRendering:s.a.oneOf(["auto","optimizeSpeed","optimizeLegibility","geometricPrecision","inherit"]),unicodeBidi:s.a.oneOf(["normal","embed","bidi-override","inherit"]),visibility:s.a.oneOf(["visible","hidden","collapse","inherit"]),wordSpacing:s.a.oneOfType([s.a.number,s.a.string]),writingMode:s.a.oneOf(["lr-tb","rl-tb","tb-rl","lr","rl","tb","inherit"]),transform:s.a.string,style:s.a.object,width:s.a.number,height:s.a.number,dx:s.a.number,dy:s.a.number,x:s.a.number,y:s.a.number,r:s.a.number,radius:s.a.oneOfType([s.a.number,s.a.array])},re={onClick:s.a.func,onMouseDown:s.a.func,onMouseUp:s.a.func,onMouseOver:s.a.func,onMouseMove:s.a.func,onMouseOut:s.a.func,onMouseEnter:s.a.func,onMouseLeave:s.a.func,onTouchEnd:s.a.func,onTouchMove:s.a.func,onTouchStart:s.a.func,onTouchCancel:s.a.func},ae={click:"onClick",mousedown:"onMouseDown",mouseup:"onMouseUp",mouseover:"onMouseOver",mousemove:"onMouseMove",mouseout:"onMouseOut",mouseenter:"onMouseEnter",mouseleave:"onMouseLeave",touchcancel:"onTouchCancel",touchend:"onTouchEnd",touchmove:"onTouchMove",touchstart:"onTouchStart"},ie=["plainline","line","square","rect","circle","cross","diamond","star","triangle","wye","none"],oe=function(e){return"string"==typeof e?e:e?e.displayName||e.name||"Component":""},se=function(e,t){var n=[],r=[];return r=A()(t)?t.map(function(e){return oe(e)}):[oe(t)],i.a.Children.forEach(e,function(e){var t=e&&e.type&&(e.type.displayName||e.type.name);-1!==r.indexOf(t)&&n.push(e)}),n},ue=function(e,t){var n=se(e,t);return n&&n[0]},le=function(e){if(!e||b()(e))return null;var t=i.a.isValidElement(e)?e.props:e;if(!E()(t))return null;var n=null;for(var r in t)({}).hasOwnProperty.call(t,r)&&ne[r]&&(n||(n={}),n[r]=t[r]);return n},ce=function(e,t){return function(n){return e(t,n),null}},de=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if(!e||b()(e))return null;var r=i.a.isValidElement(e)?e.props:e;if(!E()(r))return null;var a=null;for(var o in r)({}).hasOwnProperty.call(r,o)&&re[o]&&(a||(a={}),a[o]=t||(n?ce(r[o],r):r[o]));return a},fe=function(e,t,n){return function(r){return e(t,n,r),null}},he=function(e,t,n){if(!E()(e))return null;var r=null;for(var a in e)({}).hasOwnProperty.call(e,a)&&re[a]&&b()(e[a])&&(r||(r={}),r[a]=fe(e[a],t,n));return r},pe=function(e){if(!e||!e.props)return!1;var t=e.props,n=t.width,r=t.height;return!(!U(n)||n<=0||!U(r)||r<=0)},me=function(){return!("undefined"!=typeof window&&window.document&&window.document.createElement&&window.setTimeout)},_e=["a","altGlyph","altGlyphDef","altGlyphItem","animate","animateColor","animateMotion","animateTransform","circle","clipPath","color-profile","cursor","defs","desc","ellipse","feBlend","feColormatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","filter","font","font-face","font-face-format","font-face-name","font-face-url","foreignObject","g","glyph","glyphRef","hkern","image","line","lineGradient","marker","mask","metadata","missing-glyph","mpath","path","pattern","polygon","polyline","radialGradient","rect","script","set","stop","style","svg","switch","symbol","text","textPath","title","tref","tspan","use","view","vkern"],ye=function(e,t){if(T()(e)&&T()(t))return!0;if(!T()(e)&&!T()(t)){var n=e.props||{},r=n.children,a=te(n,["children"]),i=t.props||{},o=i.children,s=te(i,["children"]);return r&&o?X(a,s)&&ve(r,o):!r&&!o&&X(a,s)}return!1},ve=function e(t,n){if(t===n)return!0;if(a.Children.count(t)!==a.Children.count(n))return!1;var r=a.Children.count(t);if(0===r)return!0;if(1===r)return ye(A()(t)?t[0]:t,A()(n)?n[0]:n);for(var i=0;i=0}(e))n.push(e);else if(e&&t[oe(e.type)]){var i=oe(e.type),o=t[i],s=o.handler,u=o.once;if(u&&!r[i]||!u){var l=s(e,i,a);A()(l)?n=[n].concat(ee(l)):n.push(l),r[i]=!0}}}),n},be=function(e){var t=e&&e.type;return t&&ae[t]?ae[t]:null};function Me(){return(Me=Object.assign||function(e){for(var t=1;t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var we={width:s.a.number.isRequired,height:s.a.number.isRequired,viewBox:s.a.shape({x:s.a.number,y:s.a.number,width:s.a.number,height:s.a.number}),className:s.a.string,style:s.a.object,children:s.a.oneOfType([s.a.arrayOf(s.a.node),s.a.node])};function xe(e){var t=e.children,n=e.width,r=e.height,a=e.viewBox,o=e.className,s=e.style,u=ke(e,["children","width","height","viewBox","className","style"]),l=a||{width:n,height:r,x:0,y:0},c=S()("recharts-surface",o),d=le(u);return i.a.createElement("svg",Me({},d,{className:c,width:n,height:r,style:s,viewBox:"".concat(l.x," ").concat(l.y," ").concat(l.width," ").concat(l.height),version:"1.1"}),t)}xe.propTypes=we;var Le=xe;function Te(){return(Te=Object.assign||function(e){for(var t=1;t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var Se={className:s.a.string,children:s.a.oneOfType([s.a.arrayOf(s.a.node),s.a.node])};function De(e){var t=e.children,n=e.className,r=Ye(e,["children","className"]),a=S()("recharts-layer",n);return i.a.createElement("g",Te({className:a},r),t)}De.propTypes=Se;var Oe=De,je=n(26),Ee=n.n(je),Pe=n(31),Ae=n.n(Pe);function Ce(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=-1;Ae()(function r(a){n<0&&(n=a),a-n>t?(e(a),n=-1):Ae()(r)})}function He(e){return(He="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})(e)}function Ne(e){return function(e){if(Array.isArray(e))return e}(e)||function(e){if(Symbol.iterator in Object(e)||"[object Arguments]"===Object.prototype.toString.call(e))return Array.from(e)}(e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance")}()}function Ie(){var e=function(){return null},t=!1;return{stop:function(){t=!0},start:function(n){t=!1,function n(r){if(!t){if(Array.isArray(r)){if(!r.length)return;var a=Ne(r),i=a[0],o=a.slice(1);return"number"==typeof i?void Ce(n.bind(null,o),i):(n(i),void Ce(n.bind(null,o)))}"object"===He(r)&&e(r),"function"==typeof r&&r()}}(n)},subscribe:function(t){return e=t,function(){e=function(){return null}}}}}var Re=n(57),We=n.n(Re);function Fe(e){return(Fe="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})(e)}function ze(e,t){if(e===t)return!0;if("object"!==Fe(e)||null===e||"object"!==Fe(t)||null===t)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(var a=hasOwnProperty.bind(t),i=0;i=0&&e<=1});var s,u,l=it(r,i),c=it(a,o),d=(s=r,u=i,function(e){var t=nt(rt(s,u).map(function(e,t){return e*t}).slice(1)).concat([0]);return at(t,e)}),f=function(e){for(var t,n=e>1?1:e,r=n,a=0;a<8;++a){var i=l(r)-n,o=d(r);if(Math.abs(i-n)<1e-4||o<1e-4)return c(r);r=(t=r-i/o)>1?1:t<0?0:t}return c(r)};return f.isStepper=!1,f},st=function(){for(var e=arguments.length,t=new Array(e),n=0;n0&&void 0!==arguments[0]?arguments[0]:{},t=e.stiff,n=void 0===t?100:t,r=e.damping,a=void 0===r?8:r,i=e.dt,o=void 0===i?17:i,s=function(e,t,r){var i=r+(-(e-t)*n-r*a)*o/1e3,s=r*o/1e3+e;return Math.abs(s-t)<1e-4&&Math.abs(i)<1e-4?[t,0]:[s,i]};return s.isStepper=!0,s.dt=o,s}()}return"function"==typeof r?r:null},ut=n(301),lt=n.n(ut);function ct(e){return function(e){if(Array.isArray(e)){for(var t=0,n=new Array(e.length);t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}function kt(e){return function(e){if(Array.isArray(e)){for(var t=0,n=new Array(e.length);t0?n[a-1]:r,f=l||Object.keys(u);if("function"==typeof s||"spring"===s)return kt(e).concat([t.runJSAnimation.bind(t,{from:d.style,to:u,duration:i,easing:s}),i]);var h=tt(f,i,s),p=wt({},d.style,u,{transition:h});return kt(e).concat([p,i,c]).filter(Qe)},[o,Math.max(u,r)])),[e.onAnimationEnd]))}},{key:"runAnimation",value:function(e){this.manager||(this.manager=Ie());var t=e.begin,n=e.duration,r=e.attributeName,a=e.to,i=e.easing,o=e.onAnimationStart,s=e.onAnimationEnd,u=e.steps,l=e.children,c=this.manager;if(this.unSubscribe=c.subscribe(this.handleStyleChange),"function"!=typeof i&&"function"!=typeof l&&"spring"!==i)if(u.length>1)this.runStepAnimation(e);else{var d=r?xt({},r,a):a,f=tt(Object.keys(d),n,i);c.start([o,t,wt({},d,{transition:f}),n,s])}else this.runJSAnimation(e)}},{key:"handleStyleChange",value:function(e){this.changeStyle(e)}},{key:"changeStyle",value:function(e){this.mounted&&this.setState({style:e})}},{key:"render",value:function(){var e=this.props,t=e.children,n=(e.begin,e.duration,e.attributeName,e.easing,e.isActive),r=(e.steps,e.from,e.to,e.canBegin,e.onAnimationEnd,e.shouldReAnimate,e.onAnimationReStart,Mt(e,["children","begin","duration","attributeName","easing","isActive","steps","from","to","canBegin","onAnimationEnd","shouldReAnimate","onAnimationReStart"])),o=a.Children.count(t),s=et(this.state.style);if("function"==typeof t)return t(s);if(!n||0===o)return t;var u=function(e){var t=e.props,n=t.style,i=void 0===n?{}:n,o=t.className;return Object(a.cloneElement)(e,wt({},r,{style:wt({},i,s),className:o}))};return 1===o?u(a.Children.only(t)):i.a.createElement("div",null,a.Children.map(t,function(e){return u(e)}))}}])&&Lt(n.prototype,r),o&&Lt(n,o),t}(),mt.displayName="Animate",mt.propTypes={from:s.a.oneOfType([s.a.object,s.a.string]),to:s.a.oneOfType([s.a.object,s.a.string]),attributeName:s.a.string,duration:s.a.number,begin:s.a.number,easing:s.a.oneOfType([s.a.string,s.a.func]),steps:s.a.arrayOf(s.a.shape({duration:s.a.number.isRequired,style:s.a.object.isRequired,easing:s.a.oneOfType([s.a.oneOf(["ease","ease-in","ease-out","ease-in-out","linear"]),s.a.func]),properties:s.a.arrayOf("string"),onAnimationEnd:s.a.func})),children:s.a.oneOfType([s.a.node,s.a.func]),isActive:s.a.bool,canBegin:s.a.bool,onAnimationEnd:s.a.func,shouldReAnimate:s.a.bool,onAnimationStart:s.a.func,onAnimationReStart:s.a.func},mt.defaultProps={begin:0,duration:1e3,from:"",to:"",attributeName:"",easing:"ease",isActive:!0,canBegin:!0,steps:[],onAnimationEnd:function(){},onAnimationStart:function(){}},pt=_t))||pt,jt=n(75);function Et(e){return(Et="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})(e)}function Pt(){return(Pt=Object.assign||function(e){for(var t=1;t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}function Ct(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ht(e,t){for(var n=0;n0&&void 0!==arguments[0]?arguments[0]:{},t=e.steps,n=e.duration;return t&&t.length?t.reduce(function(e,t){return e+(W()(t.duration)&&t.duration>0?t.duration:0)},0):W()(n)?n:0},Ft=function(e){function t(){var e,n;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);for(var r=arguments.length,a=new Array(r),i=0;i1||Math.abs(r.height-n)>1)&&this.setState({boxWidth:r.width,boxHeight:r.height})}else-1===t&&-1===n||this.setState({boxWidth:-1,boxHeight:-1})}},{key:"render",value:function(){var e,t,n,r=this,a=this.props,o=a.payload,s=a.isAnimationActive,u=a.animationDuration,l=a.animationEasing,c=a.filterNull&&o&&o.length?o.filter(function(e){return!T()(e.value)}):o,d=c&&c.length,f=this.props,h=f.content,p=f.viewBox,m=f.coordinate,_=f.position,y=f.active,v=f.offset,g=un({pointerEvents:"none",visibility:y&&d?"visible":"hidden",position:"absolute",top:0},f.wrapperStyle);if(_&&U(_.x)&&U(_.y))t=_.x,n=_.y;else{var M=this.state,k=M.boxWidth,w=M.boxHeight;k>0&&w>0&&m?(t=_&&U(_.x)?_.x:Math.max(m.x+k+v>p.x+p.width?m.x-k-v:m.x+v,p.x),n=_&&U(_.y)?_.y:Math.max(m.y+w+v>p.y+p.height?m.y-w-v:m.y+v,p.y)):g.visibility="hidden"}g=un({},g,et({transform:this.props.useTranslate3d?"translate3d(".concat(t,"px, ").concat(n,"px, 0)"):"translate(".concat(t,"px, ").concat(n,"px)")})),s&&y&&(g=un({},g,et({transition:"transform ".concat(u,"ms ").concat(l)})));var x=S()(pn,(ln(e={},"".concat(pn,"-right"),U(t)&&m&&U(m.x)&&t>=m.x),ln(e,"".concat(pn,"-left"),U(t)&&m&&U(m.x)&&t=m.y),ln(e,"".concat(pn,"-top"),U(n)&&m&&U(m.y)&&n1e-6)if(Math.abs(c*s-u*l)>1e-6&&a){var f=n-i,h=r-o,p=s*s+u*u,m=f*f+h*h,_=Math.sqrt(p),y=Math.sqrt(d),v=a*Math.tan((vn-Math.acos((p+d-m)/(2*_*y)))/2),g=v/y,b=v/_;Math.abs(g-1)>1e-6&&(this._+="L"+(e+g*l)+","+(t+g*c)),this._+="A"+a+","+a+",0,0,"+ +(c*f>l*h)+","+(this._x1=e+b*s)+","+(this._y1=t+b*u)}else this._+="L"+(this._x1=e)+","+(this._y1=t);else;},arc:function(e,t,n,r,a,i){e=+e,t=+t;var o=(n=+n)*Math.cos(r),s=n*Math.sin(r),u=e+o,l=t+s,c=1^i,d=i?r-a:a-r;if(n<0)throw new Error("negative radius: "+n);null===this._x1?this._+="M"+u+","+l:(Math.abs(this._x1-u)>1e-6||Math.abs(this._y1-l)>1e-6)&&(this._+="L"+u+","+l),n&&(d<0&&(d=d%gn+gn),d>bn?this._+="A"+n+","+n+",0,1,"+c+","+(e-o)+","+(t-s)+"A"+n+","+n+",0,1,"+c+","+(this._x1=u)+","+(this._y1=l):d>1e-6&&(this._+="A"+n+","+n+",0,"+ +(d>=vn)+","+c+","+(this._x1=e+n*Math.cos(a))+","+(this._y1=t+n*Math.sin(a))))},rect:function(e,t,n,r){this._+="M"+(this._x0=this._x1=+e)+","+(this._y0=this._y1=+t)+"h"+ +n+"v"+ +r+"h"+-n+"Z"},toString:function(){return this._}};var wn=kn,xn=function(e){return function(){return e}},Ln=(Math.abs,Math.atan2,Math.cos,Math.max,Math.min,Math.sin,Math.sqrt,1e-12),Tn=Math.PI,Yn=2*Tn;function Sn(e){this._context=e}Sn.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:this._context.lineTo(e,t)}}};var Dn=function(e){return new Sn(e)};function On(e){return e[0]}function jn(e){return e[1]}var En=function(){var e=On,t=jn,n=xn(!0),r=null,a=Dn,i=null;function o(o){var s,u,l,c=o.length,d=!1;for(null==r&&(i=a(l=wn())),s=0;s<=c;++s)!(s=c;--d)s.point(_[d],y[d]);s.lineEnd(),s.areaEnd()}m&&(_[l]=+e(f,l,u),y[l]=+n(f,l,u),s.point(t?+t(f,l,u):_[l],r?+r(f,l,u):y[l]))}if(h)return s=null,h+""||null}function l(){return En().defined(a).curve(o).context(i)}return u.x=function(n){return arguments.length?(e="function"==typeof n?n:xn(+n),t=null,u):e},u.x0=function(t){return arguments.length?(e="function"==typeof t?t:xn(+t),u):e},u.x1=function(e){return arguments.length?(t=null==e?null:"function"==typeof e?e:xn(+e),u):t},u.y=function(e){return arguments.length?(n="function"==typeof e?e:xn(+e),r=null,u):n},u.y0=function(e){return arguments.length?(n="function"==typeof e?e:xn(+e),u):n},u.y1=function(e){return arguments.length?(r=null==e?null:"function"==typeof e?e:xn(+e),u):r},u.lineX0=u.lineY0=function(){return l().x(e).y(n)},u.lineY1=function(){return l().x(e).y(r)},u.lineX1=function(){return l().x(t).y(n)},u.defined=function(e){return arguments.length?(a="function"==typeof e?e:xn(!!e),u):a},u.curve=function(e){return arguments.length?(o=e,null!=i&&(s=o(i)),u):o},u.context=function(e){return arguments.length?(null==e?i=s=null:s=o(i=e),u):i},u};Cn(Dn);function An(e){this._curve=e}function Cn(e){function t(t){return new An(e(t))}return t._curve=e,t}An.prototype={areaStart:function(){this._curve.areaStart()},areaEnd:function(){this._curve.areaEnd()},lineStart:function(){this._curve.lineStart()},lineEnd:function(){this._curve.lineEnd()},point:function(e,t){this._curve.point(t*Math.sin(e),t*-Math.cos(e))}};var Hn=Array.prototype.slice;var Nn={draw:function(e,t){var n=Math.sqrt(t/Tn);e.moveTo(n,0),e.arc(0,0,n,0,Yn)}},In={draw:function(e,t){var n=Math.sqrt(t/5)/2;e.moveTo(-3*n,-n),e.lineTo(-n,-n),e.lineTo(-n,-3*n),e.lineTo(n,-3*n),e.lineTo(n,-n),e.lineTo(3*n,-n),e.lineTo(3*n,n),e.lineTo(n,n),e.lineTo(n,3*n),e.lineTo(-n,3*n),e.lineTo(-n,n),e.lineTo(-3*n,n),e.closePath()}},Rn=Math.sqrt(1/3),Wn=2*Rn,Fn={draw:function(e,t){var n=Math.sqrt(t/Wn),r=n*Rn;e.moveTo(0,-n),e.lineTo(r,0),e.lineTo(0,n),e.lineTo(-r,0),e.closePath()}},zn=Math.sin(Tn/10)/Math.sin(7*Tn/10),Un=Math.sin(Yn/10)*zn,Bn=-Math.cos(Yn/10)*zn,Gn={draw:function(e,t){var n=Math.sqrt(.8908130915292852*t),r=Un*n,a=Bn*n;e.moveTo(0,-n),e.lineTo(r,a);for(var i=1;i<5;++i){var o=Yn*i/5,s=Math.cos(o),u=Math.sin(o);e.lineTo(u*n,-s*n),e.lineTo(s*r-u*a,u*r+s*a)}e.closePath()}},Vn={draw:function(e,t){var n=Math.sqrt(t),r=-n/2;e.rect(r,r,n,n)}},Jn=Math.sqrt(3),qn={draw:function(e,t){var n=-Math.sqrt(t/(3*Jn));e.moveTo(0,2*n),e.lineTo(-Jn*n,-n),e.lineTo(Jn*n,-n),e.closePath()}},$n=Math.sqrt(3)/2,Kn=1/Math.sqrt(12),Xn=3*(Kn/2+1),Qn={draw:function(e,t){var n=Math.sqrt(t/Xn),r=n/2,a=n*Kn,i=r,o=n*Kn+n,s=-i,u=o;e.moveTo(r,a),e.lineTo(i,o),e.lineTo(s,u),e.lineTo(-.5*r-$n*a,$n*r+-.5*a),e.lineTo(-.5*i-$n*o,$n*i+-.5*o),e.lineTo(-.5*s-$n*u,$n*s+-.5*u),e.lineTo(-.5*r+$n*a,-.5*a-$n*r),e.lineTo(-.5*i+$n*o,-.5*o-$n*i),e.lineTo(-.5*s+$n*u,-.5*u-$n*s),e.closePath()}},Zn=function(){};function er(e,t,n){e._context.bezierCurveTo((2*e._x0+e._x1)/3,(2*e._y0+e._y1)/3,(e._x0+2*e._x1)/3,(e._y0+2*e._y1)/3,(e._x0+4*e._x1+t)/6,(e._y0+4*e._y1+n)/6)}function tr(e){this._context=e}tr.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:er(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:er(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function nr(e){this._context=e}nr.prototype={areaStart:Zn,areaEnd:Zn,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x2,this._y2),this._context.closePath();break;case 2:this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break;case 3:this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4)}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x2=e,this._y2=t;break;case 1:this._point=2,this._x3=e,this._y3=t;break;case 2:this._point=3,this._x4=e,this._y4=t,this._context.moveTo((this._x0+4*this._x1+e)/6,(this._y0+4*this._y1+t)/6);break;default:er(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function rr(e){this._context=e}rr.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var n=(this._x0+4*this._x1+e)/6,r=(this._y0+4*this._y1+t)/6;this._line?this._context.lineTo(n,r):this._context.moveTo(n,r);break;case 3:this._point=4;default:er(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function ar(e,t){this._basis=new tr(e),this._beta=t}ar.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var e=this._x,t=this._y,n=e.length-1;if(n>0)for(var r,a=e[0],i=t[0],o=e[n]-a,s=t[n]-i,u=-1;++u<=n;)r=u/n,this._basis.point(this._beta*e[u]+(1-this._beta)*(a+r*o),this._beta*t[u]+(1-this._beta)*(i+r*s));this._x=this._y=null,this._basis.lineEnd()},point:function(e,t){this._x.push(+e),this._y.push(+t)}};(function e(t){function n(e){return 1===t?new tr(e):new ar(e,t)}return n.beta=function(t){return e(+t)},n})(.85);function ir(e,t,n){e._context.bezierCurveTo(e._x1+e._k*(e._x2-e._x0),e._y1+e._k*(e._y2-e._y0),e._x2+e._k*(e._x1-t),e._y2+e._k*(e._y1-n),e._x2,e._y2)}function or(e,t){this._context=e,this._k=(1-t)/6}or.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:ir(this,this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2,this._x1=e,this._y1=t;break;case 2:this._point=3;default:ir(this,e,t)}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};(function e(t){function n(e){return new or(e,t)}return n.tension=function(t){return e(+t)},n})(0);function sr(e,t){this._context=e,this._k=(1-t)/6}sr.prototype={areaStart:Zn,areaEnd:Zn,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x3=e,this._y3=t;break;case 1:this._point=2,this._context.moveTo(this._x4=e,this._y4=t);break;case 2:this._point=3,this._x5=e,this._y5=t;break;default:ir(this,e,t)}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};(function e(t){function n(e){return new sr(e,t)}return n.tension=function(t){return e(+t)},n})(0);function ur(e,t){this._context=e,this._k=(1-t)/6}ur.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:ir(this,e,t)}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};(function e(t){function n(e){return new ur(e,t)}return n.tension=function(t){return e(+t)},n})(0);function lr(e,t,n){var r=e._x1,a=e._y1,i=e._x2,o=e._y2;if(e._l01_a>Ln){var s=2*e._l01_2a+3*e._l01_a*e._l12_a+e._l12_2a,u=3*e._l01_a*(e._l01_a+e._l12_a);r=(r*s-e._x0*e._l12_2a+e._x2*e._l01_2a)/u,a=(a*s-e._y0*e._l12_2a+e._y2*e._l01_2a)/u}if(e._l23_a>Ln){var l=2*e._l23_2a+3*e._l23_a*e._l12_a+e._l12_2a,c=3*e._l23_a*(e._l23_a+e._l12_a);i=(i*l+e._x1*e._l23_2a-t*e._l12_2a)/c,o=(o*l+e._y1*e._l23_2a-n*e._l12_2a)/c}e._context.bezierCurveTo(r,a,i,o,e._x2,e._y2)}function cr(e,t){this._context=e,this._alpha=t}cr.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:this.point(this._x2,this._y2)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){if(e=+e,t=+t,this._point){var n=this._x2-e,r=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3;default:lr(this,e,t)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};(function e(t){function n(e){return t?new cr(e,t):new or(e,0)}return n.alpha=function(t){return e(+t)},n})(.5);function dr(e,t){this._context=e,this._alpha=t}dr.prototype={areaStart:Zn,areaEnd:Zn,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(e,t){if(e=+e,t=+t,this._point){var n=this._x2-e,r=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1,this._x3=e,this._y3=t;break;case 1:this._point=2,this._context.moveTo(this._x4=e,this._y4=t);break;case 2:this._point=3,this._x5=e,this._y5=t;break;default:lr(this,e,t)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};(function e(t){function n(e){return t?new dr(e,t):new sr(e,0)}return n.alpha=function(t){return e(+t)},n})(.5);function fr(e,t){this._context=e,this._alpha=t}fr.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){if(e=+e,t=+t,this._point){var n=this._x2-e,r=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:lr(this,e,t)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};(function e(t){function n(e){return t?new fr(e,t):new ur(e,0)}return n.alpha=function(t){return e(+t)},n})(.5);function hr(e){this._context=e}hr.prototype={areaStart:Zn,areaEnd:Zn,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(e,t){e=+e,t=+t,this._point?this._context.lineTo(e,t):(this._point=1,this._context.moveTo(e,t))}};function pr(e){return e<0?-1:1}function mr(e,t,n){var r=e._x1-e._x0,a=t-e._x1,i=(e._y1-e._y0)/(r||a<0&&-0),o=(n-e._y1)/(a||r<0&&-0),s=(i*a+o*r)/(r+a);return(pr(i)+pr(o))*Math.min(Math.abs(i),Math.abs(o),.5*Math.abs(s))||0}function _r(e,t){var n=e._x1-e._x0;return n?(3*(e._y1-e._y0)/n-t)/2:t}function yr(e,t,n){var r=e._x0,a=e._y0,i=e._x1,o=e._y1,s=(i-r)/3;e._context.bezierCurveTo(r+s,a+s*t,i-s,o-s*n,i,o)}function vr(e){this._context=e}function gr(e){this._context=new br(e)}function br(e){this._context=e}function Mr(e){this._context=e}function kr(e){var t,n,r=e.length-1,a=new Array(r),i=new Array(r),o=new Array(r);for(a[0]=0,i[0]=2,o[0]=e[0]+2*e[1],t=1;t=0;--t)a[t]=(o[t]-a[t+1])/i[t];for(i[r-1]=(e[r]+a[r-1])/2,t=0;t=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:if(this._t<=0)this._context.lineTo(this._x,t),this._context.lineTo(e,t);else{var n=this._x*(1-this._t)+e*this._t;this._context.lineTo(n,this._y),this._context.lineTo(n,t)}}this._x=e,this._y=t}};var xr=function(e,t){if((a=e.length)>1)for(var n,r,a,i=1,o=e[t[0]],s=o.length;i=0;)n[t]=t;return n};function Tr(e,t){return e[t]}var Yr,Sr,Dr;function Or(e){return(Or="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})(e)}function jr(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Er(){return(Er=Object.assign||function(e){for(var t=1;t=0&&n>=0?{width:t,height:n}:null}},{key:"getDefaultPosition",value:function(e){var t,n,r=this.props,a=r.layout,i=r.align,o=r.verticalAlign,s=r.margin,u=r.chartWidth,l=r.chartHeight;e&&(void 0!==e.left&&null!==e.left||void 0!==e.right&&null!==e.right)||(t="center"===i&&"vertical"===a?{left:((u||0)-(this.getBBox()||{width:0}).width)/2}:"right"===i?{right:s&&s.right||0}:{left:s&&s.left||0});e&&(void 0!==e.top&&null!==e.top||void 0!==e.bottom&&null!==e.bottom)||(n="middle"===o?{top:((l||0)-(this.getBBox()||{height:0}).height)/2}:"bottom"===o?{bottom:s&&s.bottom||0}:{top:s&&s.top||0});return na({},t,n)}},{key:"updateBBox",value:function(){var e=this.state,t=e.boxWidth,n=e.boxHeight,r=this.props.onBBoxUpdate;if(this.wrapperNode&&this.wrapperNode.getBoundingClientRect){var a=this.wrapperNode.getBoundingClientRect();(Math.abs(a.width-t)>1||Math.abs(a.height-n)>1)&&this.setState({boxWidth:a.width,boxHeight:a.height},function(){r&&r(a)})}else-1===t&&-1===n||this.setState({boxWidth:-1,boxHeight:-1},function(){r&&r(null)})}},{key:"render",value:function(){var e=this,t=this.props,n=t.content,r=t.width,a=t.height,o=t.wrapperStyle,s=na({position:"absolute",width:r||"auto",height:a||"auto"},this.getDefaultPosition(o),o);return i.a.createElement("div",{className:"recharts-legend-wrapper",style:s,ref:function(t){e.wrapperNode=t}},function(e,t){return i.a.isValidElement(e)?i.a.cloneElement(e,t):b()(e)?e(t):i.a.createElement(ea,t)}(n,this.props))}}])&&aa(n.prototype,r),o&&aa(n,o),t}(),Xr.displayName="Legend",Xr.propTypes={content:s.a.oneOfType([s.a.element,s.a.func]),wrapperStyle:s.a.object,chartWidth:s.a.number,chartHeight:s.a.number,width:s.a.number,height:s.a.number,iconSize:s.a.number,iconType:s.a.oneOf(da),layout:s.a.oneOf(["horizontal","vertical"]),align:s.a.oneOf(["center","left","right"]),verticalAlign:s.a.oneOf(["top","bottom","middle"]),margin:s.a.shape({top:s.a.number,left:s.a.number,bottom:s.a.number,right:s.a.number}),payload:s.a.arrayOf(s.a.shape({value:s.a.any,id:s.a.any,type:s.a.oneOf(ie)})),formatter:s.a.func,onMouseEnter:s.a.func,onMouseLeave:s.a.func,onClick:s.a.func,onBBoxUpdate:s.a.func},Xr.defaultProps={iconSize:14,layout:"horizontal",align:"center",verticalAlign:"bottom"},Kr=Qr))||Kr;function ha(e){return(ha="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})(e)}function pa(){return(pa=Object.assign||function(e){for(var t=1;tt?1:e>=t?0:NaN},Ga=function(e){var t;return 1===e.length&&(t=e,e=function(e,n){return Ba(t(e),n)}),{left:function(t,n,r,a){for(null==r&&(r=0),null==a&&(a=t.length);r>>1;e(t[i],n)<0?r=i+1:a=i}return r},right:function(t,n,r,a){for(null==r&&(r=0),null==a&&(a=t.length);r>>1;e(t[i],n)>0?a=i:r=i+1}return r}}};var Va=Ga(Ba),Ja=Va.right,qa=(Va.left,Ja);var $a=function(e){return null===e?NaN:+e},Ka=Array.prototype,Xa=(Ka.slice,Ka.map,function(e,t,n){e=+e,t=+t,n=(a=arguments.length)<2?(t=e,e=0,1):a<3?1:+n;for(var r=-1,a=0|Math.max(0,Math.ceil((t-e)/n)),i=new Array(a);++r0)return[e];if((r=t0)for(e=Math.ceil(e/o),t=Math.floor(t/o),i=new Array(a=Math.ceil(t-e+1));++s=0?(i>=Qa?10:i>=Za?5:i>=ei?2:1)*Math.pow(10,a):-Math.pow(10,-a)/(i>=Qa?10:i>=Za?5:i>=ei?2:1)}function ri(e,t,n){var r=Math.abs(t-e)/Math.max(0,n),a=Math.pow(10,Math.floor(Math.log(r)/Math.LN10)),i=r/a;return i>=Qa?a*=10:i>=Za?a*=5:i>=ei&&(a*=2),t=1)return+n(e[r-1],r-1,e);var r,a=(r-1)*t,i=Math.floor(a),o=+n(e[i],i,e);return o+(+n(e[i+1],i+1,e)-o)*(a-i)}};function ii(){}function oi(e,t){var n=new ii;if(e instanceof ii)e.each(function(e,t){n.set(t,e)});else if(Array.isArray(e)){var r,a=-1,i=e.length;if(null==t)for(;++a>8&15|t>>4&240,t>>4&15|240&t,(15&t)<<4|15&t,1):(t=Li.exec(e))?Ai(parseInt(t[1],16)):(t=Ti.exec(e))?new Ii(t[1],t[2],t[3],1):(t=Yi.exec(e))?new Ii(255*t[1]/100,255*t[2]/100,255*t[3]/100,1):(t=Si.exec(e))?Ci(t[1],t[2],t[3],t[4]):(t=Di.exec(e))?Ci(255*t[1]/100,255*t[2]/100,255*t[3]/100,t[4]):(t=Oi.exec(e))?Wi(t[1],t[2]/100,t[3]/100,1):(t=ji.exec(e))?Wi(t[1],t[2]/100,t[3]/100,t[4]):Ei.hasOwnProperty(e)?Ai(Ei[e]):"transparent"===e?new Ii(NaN,NaN,NaN,0):null}function Ai(e){return new Ii(e>>16&255,e>>8&255,255&e,1)}function Ci(e,t,n,r){return r<=0&&(e=t=n=NaN),new Ii(e,t,n,r)}function Hi(e){return e instanceof bi||(e=Pi(e)),e?new Ii((e=e.rgb()).r,e.g,e.b,e.opacity):new Ii}function Ni(e,t,n,r){return 1===arguments.length?Hi(e):new Ii(e,t,n,null==r?1:r)}function Ii(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}function Ri(e){return((e=Math.max(0,Math.min(255,Math.round(e)||0)))<16?"0":"")+e.toString(16)}function Wi(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new zi(e,t,n,r)}function Fi(e,t,n,r){return 1===arguments.length?function(e){if(e instanceof zi)return new zi(e.h,e.s,e.l,e.opacity);if(e instanceof bi||(e=Pi(e)),!e)return new zi;if(e instanceof zi)return e;var t=(e=e.rgb()).r/255,n=e.g/255,r=e.b/255,a=Math.min(t,n,r),i=Math.max(t,n,r),o=NaN,s=i-a,u=(i+a)/2;return s?(o=t===i?(n-r)/s+6*(n0&&u<1?0:o,new zi(o,s,u,e.opacity)}(e):new zi(e,t,n,null==r?1:r)}function zi(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}function Ui(e,t,n){return 255*(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)}vi(bi,Pi,{displayable:function(){return this.rgb().displayable()},hex:function(){return this.rgb().hex()},toString:function(){return this.rgb()+""}}),vi(Ii,Ni,gi(bi,{brighter:function(e){return e=null==e?1/.7:Math.pow(1/.7,e),new Ii(this.r*e,this.g*e,this.b*e,this.opacity)},darker:function(e){return e=null==e?.7:Math.pow(.7,e),new Ii(this.r*e,this.g*e,this.b*e,this.opacity)},rgb:function(){return this},displayable:function(){return 0<=this.r&&this.r<=255&&0<=this.g&&this.g<=255&&0<=this.b&&this.b<=255&&0<=this.opacity&&this.opacity<=1},hex:function(){return"#"+Ri(this.r)+Ri(this.g)+Ri(this.b)},toString:function(){var e=this.opacity;return(1===(e=isNaN(e)?1:Math.max(0,Math.min(1,e)))?"rgb(":"rgba(")+Math.max(0,Math.min(255,Math.round(this.r)||0))+", "+Math.max(0,Math.min(255,Math.round(this.g)||0))+", "+Math.max(0,Math.min(255,Math.round(this.b)||0))+(1===e?")":", "+e+")")}})),vi(zi,Fi,gi(bi,{brighter:function(e){return e=null==e?1/.7:Math.pow(1/.7,e),new zi(this.h,this.s,this.l*e,this.opacity)},darker:function(e){return e=null==e?.7:Math.pow(.7,e),new zi(this.h,this.s,this.l*e,this.opacity)},rgb:function(){var e=this.h%360+360*(this.h<0),t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*t,a=2*n-r;return new Ii(Ui(e>=240?e-240:e+120,a,r),Ui(e,a,r),Ui(e<120?e+240:e-120,a,r),this.opacity)},displayable:function(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1}}));var Bi=Math.PI/180,Gi=180/Math.PI,Vi=.96422,Ji=1,qi=.82521,$i=4/29,Ki=6/29,Xi=3*Ki*Ki,Qi=Ki*Ki*Ki;function Zi(e){if(e instanceof to)return new to(e.l,e.a,e.b,e.opacity);if(e instanceof uo){if(isNaN(e.h))return new to(e.l,0,0,e.opacity);var t=e.h*Bi;return new to(e.l,Math.cos(t)*e.c,Math.sin(t)*e.c,e.opacity)}e instanceof Ii||(e=Hi(e));var n,r,a=io(e.r),i=io(e.g),o=io(e.b),s=no((.2225045*a+.7168786*i+.0606169*o)/Ji);return a===i&&i===o?n=r=s:(n=no((.4360747*a+.3850649*i+.1430804*o)/Vi),r=no((.0139322*a+.0971045*i+.7141733*o)/qi)),new to(116*s-16,500*(n-s),200*(s-r),e.opacity)}function eo(e,t,n,r){return 1===arguments.length?Zi(e):new to(e,t,n,null==r?1:r)}function to(e,t,n,r){this.l=+e,this.a=+t,this.b=+n,this.opacity=+r}function no(e){return e>Qi?Math.pow(e,1/3):e/Xi+$i}function ro(e){return e>Ki?e*e*e:Xi*(e-$i)}function ao(e){return 255*(e<=.0031308?12.92*e:1.055*Math.pow(e,1/2.4)-.055)}function io(e){return(e/=255)<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4)}function oo(e){if(e instanceof uo)return new uo(e.h,e.c,e.l,e.opacity);if(e instanceof to||(e=Zi(e)),0===e.a&&0===e.b)return new uo(NaN,0,e.l,e.opacity);var t=Math.atan2(e.b,e.a)*Gi;return new uo(t<0?t+360:t,Math.sqrt(e.a*e.a+e.b*e.b),e.l,e.opacity)}function so(e,t,n,r){return 1===arguments.length?oo(e):new uo(e,t,n,null==r?1:r)}function uo(e,t,n,r){this.h=+e,this.c=+t,this.l=+n,this.opacity=+r}vi(to,eo,gi(bi,{brighter:function(e){return new to(this.l+18*(null==e?1:e),this.a,this.b,this.opacity)},darker:function(e){return new to(this.l-18*(null==e?1:e),this.a,this.b,this.opacity)},rgb:function(){var e=(this.l+16)/116,t=isNaN(this.a)?e:e+this.a/500,n=isNaN(this.b)?e:e-this.b/200;return new Ii(ao(3.1338561*(t=Vi*ro(t))-1.6168667*(e=Ji*ro(e))-.4906146*(n=qi*ro(n))),ao(-.9787684*t+1.9161415*e+.033454*n),ao(.0719453*t-.2289914*e+1.4052427*n),this.opacity)}})),vi(uo,so,gi(bi,{brighter:function(e){return new uo(this.h,this.c,this.l+18*(null==e?1:e),this.opacity)},darker:function(e){return new uo(this.h,this.c,this.l-18*(null==e?1:e),this.opacity)},rgb:function(){return Zi(this).rgb()}}));var lo=-.14861,co=1.78277,fo=-.29227,ho=-.90649,po=1.97294,mo=po*ho,_o=po*co,yo=co*fo-ho*lo;function vo(e,t,n,r){return 1===arguments.length?function(e){if(e instanceof go)return new go(e.h,e.s,e.l,e.opacity);e instanceof Ii||(e=Hi(e));var t=e.r/255,n=e.g/255,r=e.b/255,a=(yo*r+mo*t-_o*n)/(yo+mo-_o),i=r-a,o=(po*(n-a)-fo*i)/ho,s=Math.sqrt(o*o+i*i)/(po*a*(1-a)),u=s?Math.atan2(o,i)*Gi-120:NaN;return new go(u<0?u+360:u,s,a,e.opacity)}(e):new go(e,t,n,null==r?1:r)}function go(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}function bo(e,t,n,r,a){var i=e*e,o=i*e;return((1-3*e+3*i-o)*t+(4-6*i+3*o)*n+(1+3*e+3*i-3*o)*r+o*a)/6}vi(go,vo,gi(bi,{brighter:function(e){return e=null==e?1/.7:Math.pow(1/.7,e),new go(this.h,this.s,this.l*e,this.opacity)},darker:function(e){return e=null==e?.7:Math.pow(.7,e),new go(this.h,this.s,this.l*e,this.opacity)},rgb:function(){var e=isNaN(this.h)?0:(this.h+120)*Bi,t=+this.l,n=isNaN(this.s)?0:this.s*t*(1-t),r=Math.cos(e),a=Math.sin(e);return new Ii(255*(t+n*(lo*r+co*a)),255*(t+n*(fo*r+ho*a)),255*(t+n*(po*r)),this.opacity)}}));var Mo=function(e){return function(){return e}};function ko(e,t){return function(n){return e+n*t}}function wo(e,t){var n=t-e;return n?ko(e,n>180||n<-180?n-360*Math.round(n/360):n):Mo(isNaN(e)?t:e)}function xo(e){return 1==(e=+e)?Lo:function(t,n){return n-t?function(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(r){return Math.pow(e+r*t,n)}}(t,n,e):Mo(isNaN(t)?n:t)}}function Lo(e,t){var n=t-e;return n?ko(e,n):Mo(isNaN(e)?t:e)}var To=function e(t){var n=xo(t);function r(e,t){var r=n((e=Ni(e)).r,(t=Ni(t)).r),a=n(e.g,t.g),i=n(e.b,t.b),o=Lo(e.opacity,t.opacity);return function(t){return e.r=r(t),e.g=a(t),e.b=i(t),e.opacity=o(t),e+""}}return r.gamma=e,r}(1);function Yo(e){return function(t){var n,r,a=t.length,i=new Array(a),o=new Array(a),s=new Array(a);for(n=0;n=1?(n=1,t-1):Math.floor(n*t),a=e[r],i=e[r+1],o=r>0?e[r-1]:2*a-i,s=ri&&(a=t.slice(i,a),s[o]?s[o]+=a:s[++o]=a),(n=n[0])===(r=r[0])?s[o]?s[o]+=r:s[++o]=r:(s[++o]=null,u.push({i:o,x:So(n,r)})),i=Oo.lastIndex;return i180?t+=360:t-e>180&&(e+=360),i.push({i:n.push(a(n)+"rotate(",null,r)-2,x:So(e,t)})):t&&n.push(a(n)+"rotate("+t+r)}(i.rotate,o.rotate,s,u),function(e,t,n,i){e!==t?i.push({i:n.push(a(n)+"skewX(",null,r)-2,x:So(e,t)}):t&&n.push(a(n)+"skewX("+t+r)}(i.skewX,o.skewX,s,u),function(e,t,n,r,i,o){if(e!==n||t!==r){var s=i.push(a(i)+"scale(",null,",",null,")");o.push({i:s-4,x:So(e,n)},{i:s-2,x:So(t,r)})}else 1===n&&1===r||i.push(a(i)+"scale("+n+","+r+")")}(i.scaleX,i.scaleY,o.scaleX,o.scaleY,s,u),i=o=null,function(e){for(var t,n=-1,r=u.length;++n2?$o:qo,r=a=null,c}function c(t){return(r||(r=n(i,o,u?function(e){return function(t,n){var r=e(t=+t,n=+n);return function(e){return e<=t?0:e>=n?1:r(e)}}}(e):e,s)))(+t)}return c.invert=function(e){return(a||(a=n(o,i,Jo,u?function(e){return function(t,n){var r=e(t=+t,n=+n);return function(e){return e<=0?t:e>=1?n:r(e)}}}(t):t)))(+e)},c.domain=function(e){return arguments.length?(i=fi.call(e,Go),l()):i.slice()},c.range=function(e){return arguments.length?(o=hi.call(e),l()):o.slice()},c.rangeRound=function(e){return o=hi.call(e),s=Ho,l()},c.clamp=function(e){return arguments.length?(u=!!e,l()):u},c.interpolate=function(e){return arguments.length?(s=e,l()):s},l()}var Qo=function(e,t){if((n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"))<0)return null;var n,r=e.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+e.slice(n+1)]},Zo=function(e){return(e=Qo(Math.abs(e)))?e[1]:NaN},es=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function ts(e){return new ns(e)}function ns(e){if(!(t=es.exec(e)))throw new Error("invalid format: "+e);var t;this.fill=t[1]||" ",this.align=t[2]||">",this.sign=t[3]||"-",this.symbol=t[4]||"",this.zero=!!t[5],this.width=t[6]&&+t[6],this.comma=!!t[7],this.precision=t[8]&&+t[8].slice(1),this.trim=!!t[9],this.type=t[10]||""}ts.prototype=ns.prototype,ns.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(null==this.width?"":Math.max(1,0|this.width))+(this.comma?",":"")+(null==this.precision?"":"."+Math.max(0,0|this.precision))+(this.trim?"~":"")+this.type};var rs,as,is,os,ss=function(e){e:for(var t,n=e.length,r=1,a=-1;r0){if(!+e[r])break e;a=0}}return a>0?e.slice(0,a)+e.slice(t+1):e},us=function(e,t){var n=Qo(e,t);if(!n)return e+"";var r=n[0],a=n[1];return a<0?"0."+new Array(-a).join("0")+r:r.length>a+1?r.slice(0,a+1)+"."+r.slice(a+1):r+new Array(a-r.length+2).join("0")},ls={"%":function(e,t){return(100*e).toFixed(t)},b:function(e){return Math.round(e).toString(2)},c:function(e){return e+""},d:function(e){return Math.round(e).toString(10)},e:function(e,t){return e.toExponential(t)},f:function(e,t){return e.toFixed(t)},g:function(e,t){return e.toPrecision(t)},o:function(e){return Math.round(e).toString(8)},p:function(e,t){return us(100*e,t)},r:us,s:function(e,t){var n=Qo(e,t);if(!n)return e+"";var r=n[0],a=n[1],i=a-(rs=3*Math.max(-8,Math.min(8,Math.floor(a/3))))+1,o=r.length;return i===o?r:i>o?r+new Array(i-o+1).join("0"):i>0?r.slice(0,i)+"."+r.slice(i):"0."+new Array(1-i).join("0")+Qo(e,Math.max(0,t+i-1))[0]},X:function(e){return Math.round(e).toString(16).toUpperCase()},x:function(e){return Math.round(e).toString(16)}},cs=function(e){return e},ds=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];as=function(e){var t,n,r=e.grouping&&e.thousands?(t=e.grouping,n=e.thousands,function(e,r){for(var a=e.length,i=[],o=0,s=t[0],u=0;a>0&&s>0&&(u+s+1>r&&(s=Math.max(1,r-u)),i.push(e.substring(a-=s,a+s)),!((u+=s+1)>r));)s=t[o=(o+1)%t.length];return i.reverse().join(n)}):cs,a=e.currency,i=e.decimal,o=e.numerals?function(e){return function(t){return t.replace(/[0-9]/g,function(t){return e[+t]})}}(e.numerals):cs,s=e.percent||"%";function u(e){var t=(e=ts(e)).fill,n=e.align,u=e.sign,l=e.symbol,c=e.zero,d=e.width,f=e.comma,h=e.precision,p=e.trim,m=e.type;"n"===m?(f=!0,m="g"):ls[m]||(null==h&&(h=12),p=!0,m="g"),(c||"0"===t&&"="===n)&&(c=!0,t="0",n="=");var _="$"===l?a[0]:"#"===l&&/[boxX]/.test(m)?"0"+m.toLowerCase():"",y="$"===l?a[1]:/[%p]/.test(m)?s:"",v=ls[m],g=/[defgprs%]/.test(m);function b(e){var a,s,l,b=_,M=y;if("c"===m)M=v(e)+M,e="";else{var k=(e=+e)<0;if(e=v(Math.abs(e),h),p&&(e=ss(e)),k&&0==+e&&(k=!1),b=(k?"("===u?u:"-":"-"===u||"("===u?"":u)+b,M=("s"===m?ds[8+rs/3]:"")+M+(k&&"("===u?")":""),g)for(a=-1,s=e.length;++a(l=e.charCodeAt(a))||l>57){M=(46===l?i+e.slice(a+1):e.slice(a))+M,e=e.slice(0,a);break}}f&&!c&&(e=r(e,1/0));var w=b.length+e.length+M.length,x=w>1)+b+e+M+x.slice(w);break;default:e=x+b+e+M}return o(e)}return h=null==h?6:/[gprs]/.test(m)?Math.max(1,Math.min(21,h)):Math.max(0,Math.min(20,h)),b.toString=function(){return e+""},b}return{format:u,formatPrefix:function(e,t){var n=u(((e=ts(e)).type="f",e)),r=3*Math.max(-8,Math.min(8,Math.floor(Zo(t)/3))),a=Math.pow(10,-r),i=ds[8+r/3];return function(e){return n(a*e)+i}}}}({decimal:".",thousands:",",grouping:[3],currency:["$",""]}),is=as.format,os=as.formatPrefix;var fs=function(e,t,n){var r,a=e[0],i=e[e.length-1],o=ri(a,i,null==t?10:t);switch((n=ts(null==n?",f":n)).type){case"s":var s=Math.max(Math.abs(a),Math.abs(i));return null!=n.precision||isNaN(r=function(e,t){return Math.max(0,3*Math.max(-8,Math.min(8,Math.floor(Zo(t)/3)))-Zo(Math.abs(e)))}(o,s))||(n.precision=r),os(n,s);case"":case"e":case"g":case"p":case"r":null!=n.precision||isNaN(r=function(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,Zo(t)-Zo(e))+1}(o,Math.max(Math.abs(a),Math.abs(i))))||(n.precision=r-("e"===n.type));break;case"f":case"%":null!=n.precision||isNaN(r=function(e){return Math.max(0,-Zo(Math.abs(e)))}(o))||(n.precision=r-2*("%"===n.type))}return is(n)};function hs(e){var t=e.domain;return e.ticks=function(e){var n=t();return ti(n[0],n[n.length-1],null==e?10:e)},e.tickFormat=function(e,n){return fs(t(),e,n)},e.nice=function(n){null==n&&(n=10);var r,a=t(),i=0,o=a.length-1,s=a[i],u=a[o];return u0?r=ni(s=Math.floor(s/r)*r,u=Math.ceil(u/r)*r,n):r<0&&(r=ni(s=Math.ceil(s*r)/r,u=Math.floor(u*r)/r,n)),r>0?(a[i]=Math.floor(s/r)*r,a[o]=Math.ceil(u/r)*r,t(a)):r<0&&(a[i]=Math.ceil(s*r)/r,a[o]=Math.floor(u*r)/r,t(a)),e},e}function ps(){var e=Xo(Jo,So);return e.copy=function(){return Ko(e,ps())},hs(e)}function ms(){var e=[0,1];function t(e){return+e}return t.invert=t,t.domain=t.range=function(n){return arguments.length?(e=fi.call(n,Go),t):e.slice()},t.copy=function(){return ms().domain(e)},hs(t)}var _s=function(e,t){var n,r=0,a=(e=e.slice()).length-1,i=e[r],o=e[a];return o0){for(;fu)break;m.push(d)}}else for(;f=1;--c)if(!((d=l*c)u)break;m.push(d)}}else m=ti(f,h,Math.min(h-f,p)).map(a);return i?m.reverse():m},e.tickFormat=function(t,i){if(null==i&&(i=10===n?".0e":","),"function"!=typeof i&&(i=is(i)),t===1/0)return i;null==t&&(t=10);var o=Math.max(1,n*t/e.ticks().length);return function(e){var t=e/a(Math.round(r(e)));return t*n0?n[a-1]:e[0],a=n?[r[n-1],t]:[r[o-1],r[o]]},i.copy=function(){return Ss().domain([e,t]).range(a)},hs(i)}function Ds(){var e=[.5],t=[0,1],n=1;function r(r){if(r<=r)return t[qa(e,r,0,n)]}return r.domain=function(a){return arguments.length?(e=hi.call(a),n=Math.min(e.length,t.length-1),r):e.slice()},r.range=function(a){return arguments.length?(t=hi.call(a),n=Math.min(e.length,t.length-1),r):t.slice()},r.invertExtent=function(n){var r=t.indexOf(n);return[e[r-1],e[r]]},r.copy=function(){return Ds().domain(e).range(t)},r}var Os=new Date,js=new Date;function Es(e,t,n,r){function a(t){return e(t=new Date(+t)),t}return a.floor=a,a.ceil=function(n){return e(n=new Date(n-1)),t(n,1),e(n),n},a.round=function(e){var t=a(e),n=a.ceil(e);return e-t0))return s;do{s.push(o=new Date(+n)),t(n,i),e(n)}while(o=t)for(;e(t),!n(t);)t.setTime(t-1)},function(e,r){if(e>=e)if(r<0)for(;++r<=0;)for(;t(e,-1),!n(e););else for(;--r>=0;)for(;t(e,1),!n(e););})},n&&(a.count=function(t,r){return Os.setTime(+t),js.setTime(+r),e(Os),e(js),Math.floor(n(Os,js))},a.every=function(e){return e=Math.floor(e),isFinite(e)&&e>0?e>1?a.filter(r?function(t){return r(t)%e==0}:function(t){return a.count(0,t)%e==0}):a:null}),a}var Ps=Es(function(){},function(e,t){e.setTime(+e+t)},function(e,t){return t-e});Ps.every=function(e){return e=Math.floor(e),isFinite(e)&&e>0?e>1?Es(function(t){t.setTime(Math.floor(t/e)*e)},function(t,n){t.setTime(+t+n*e)},function(t,n){return(n-t)/e}):Ps:null};var As=Ps,Cs=(Ps.range,6e4),Hs=6048e5,Ns=Es(function(e){e.setTime(e-e.getMilliseconds())},function(e,t){e.setTime(+e+1e3*t)},function(e,t){return(t-e)/1e3},function(e){return e.getUTCSeconds()}),Is=Ns,Rs=(Ns.range,Es(function(e){e.setTime(e-e.getMilliseconds()-1e3*e.getSeconds())},function(e,t){e.setTime(+e+t*Cs)},function(e,t){return(t-e)/Cs},function(e){return e.getMinutes()})),Ws=Rs,Fs=(Rs.range,Es(function(e){e.setTime(e-e.getMilliseconds()-1e3*e.getSeconds()-e.getMinutes()*Cs)},function(e,t){e.setTime(+e+36e5*t)},function(e,t){return(t-e)/36e5},function(e){return e.getHours()})),zs=Fs,Us=(Fs.range,Es(function(e){e.setHours(0,0,0,0)},function(e,t){e.setDate(e.getDate()+t)},function(e,t){return(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*Cs)/864e5},function(e){return e.getDate()-1})),Bs=Us;Us.range;function Gs(e){return Es(function(t){t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)},function(e,t){e.setDate(e.getDate()+7*t)},function(e,t){return(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*Cs)/Hs})}var Vs=Gs(0),Js=Gs(1),qs=Gs(2),$s=Gs(3),Ks=Gs(4),Xs=Gs(5),Qs=Gs(6),Zs=(Vs.range,Js.range,qs.range,$s.range,Ks.range,Xs.range,Qs.range,Es(function(e){e.setDate(1),e.setHours(0,0,0,0)},function(e,t){e.setMonth(e.getMonth()+t)},function(e,t){return t.getMonth()-e.getMonth()+12*(t.getFullYear()-e.getFullYear())},function(e){return e.getMonth()})),eu=Zs,tu=(Zs.range,Es(function(e){e.setMonth(0,1),e.setHours(0,0,0,0)},function(e,t){e.setFullYear(e.getFullYear()+t)},function(e,t){return t.getFullYear()-e.getFullYear()},function(e){return e.getFullYear()}));tu.every=function(e){return isFinite(e=Math.floor(e))&&e>0?Es(function(t){t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)},function(t,n){t.setFullYear(t.getFullYear()+n*e)}):null};var nu=tu,ru=(tu.range,Es(function(e){e.setUTCSeconds(0,0)},function(e,t){e.setTime(+e+t*Cs)},function(e,t){return(t-e)/Cs},function(e){return e.getUTCMinutes()})),au=ru,iu=(ru.range,Es(function(e){e.setUTCMinutes(0,0,0)},function(e,t){e.setTime(+e+36e5*t)},function(e,t){return(t-e)/36e5},function(e){return e.getUTCHours()})),ou=iu,su=(iu.range,Es(function(e){e.setUTCHours(0,0,0,0)},function(e,t){e.setUTCDate(e.getUTCDate()+t)},function(e,t){return(t-e)/864e5},function(e){return e.getUTCDate()-1})),uu=su;su.range;function lu(e){return Es(function(t){t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)},function(e,t){e.setUTCDate(e.getUTCDate()+7*t)},function(e,t){return(t-e)/Hs})}var cu=lu(0),du=lu(1),fu=lu(2),hu=lu(3),pu=lu(4),mu=lu(5),_u=lu(6),yu=(cu.range,du.range,fu.range,hu.range,pu.range,mu.range,_u.range,Es(function(e){e.setUTCDate(1),e.setUTCHours(0,0,0,0)},function(e,t){e.setUTCMonth(e.getUTCMonth()+t)},function(e,t){return t.getUTCMonth()-e.getUTCMonth()+12*(t.getUTCFullYear()-e.getUTCFullYear())},function(e){return e.getUTCMonth()})),vu=yu,gu=(yu.range,Es(function(e){e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},function(e,t){e.setUTCFullYear(e.getUTCFullYear()+t)},function(e,t){return t.getUTCFullYear()-e.getUTCFullYear()},function(e){return e.getUTCFullYear()}));gu.every=function(e){return isFinite(e=Math.floor(e))&&e>0?Es(function(t){t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},function(t,n){t.setUTCFullYear(t.getUTCFullYear()+n*e)}):null};var bu=gu;gu.range;function Mu(e){if(0<=e.y&&e.y<100){var t=new Date(-1,e.m,e.d,e.H,e.M,e.S,e.L);return t.setFullYear(e.y),t}return new Date(e.y,e.m,e.d,e.H,e.M,e.S,e.L)}function ku(e){if(0<=e.y&&e.y<100){var t=new Date(Date.UTC(-1,e.m,e.d,e.H,e.M,e.S,e.L));return t.setUTCFullYear(e.y),t}return new Date(Date.UTC(e.y,e.m,e.d,e.H,e.M,e.S,e.L))}function wu(e){return{y:e,m:0,d:1,H:0,M:0,S:0,L:0}}var xu,Lu,Tu,Yu,Su={"-":"",_:" ",0:"0"},Du=/^\s*\d+/,Ou=/^%/,ju=/[\\^$*+?|[\]().{}]/g;function Eu(e,t,n){var r=e<0?"-":"",a=(r?-e:e)+"",i=a.length;return r+(i68?1900:2e3),n+r[0].length):-1}function Uu(e,t,n){var r=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(t.slice(n,n+6));return r?(e.Z=r[1]?0:-(r[2]+(r[3]||"00")),n+r[0].length):-1}function Bu(e,t,n){var r=Du.exec(t.slice(n,n+2));return r?(e.m=r[0]-1,n+r[0].length):-1}function Gu(e,t,n){var r=Du.exec(t.slice(n,n+2));return r?(e.d=+r[0],n+r[0].length):-1}function Vu(e,t,n){var r=Du.exec(t.slice(n,n+3));return r?(e.m=0,e.d=+r[0],n+r[0].length):-1}function Ju(e,t,n){var r=Du.exec(t.slice(n,n+2));return r?(e.H=+r[0],n+r[0].length):-1}function qu(e,t,n){var r=Du.exec(t.slice(n,n+2));return r?(e.M=+r[0],n+r[0].length):-1}function $u(e,t,n){var r=Du.exec(t.slice(n,n+2));return r?(e.S=+r[0],n+r[0].length):-1}function Ku(e,t,n){var r=Du.exec(t.slice(n,n+3));return r?(e.L=+r[0],n+r[0].length):-1}function Xu(e,t,n){var r=Du.exec(t.slice(n,n+6));return r?(e.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function Qu(e,t,n){var r=Ou.exec(t.slice(n,n+1));return r?n+r[0].length:-1}function Zu(e,t,n){var r=Du.exec(t.slice(n));return r?(e.Q=+r[0],n+r[0].length):-1}function el(e,t,n){var r=Du.exec(t.slice(n));return r?(e.Q=1e3*+r[0],n+r[0].length):-1}function tl(e,t){return Eu(e.getDate(),t,2)}function nl(e,t){return Eu(e.getHours(),t,2)}function rl(e,t){return Eu(e.getHours()%12||12,t,2)}function al(e,t){return Eu(1+Bs.count(nu(e),e),t,3)}function il(e,t){return Eu(e.getMilliseconds(),t,3)}function ol(e,t){return il(e,t)+"000"}function sl(e,t){return Eu(e.getMonth()+1,t,2)}function ul(e,t){return Eu(e.getMinutes(),t,2)}function ll(e,t){return Eu(e.getSeconds(),t,2)}function cl(e){var t=e.getDay();return 0===t?7:t}function dl(e,t){return Eu(Vs.count(nu(e),e),t,2)}function fl(e,t){var n=e.getDay();return e=n>=4||0===n?Ks(e):Ks.ceil(e),Eu(Ks.count(nu(e),e)+(4===nu(e).getDay()),t,2)}function hl(e){return e.getDay()}function pl(e,t){return Eu(Js.count(nu(e),e),t,2)}function ml(e,t){return Eu(e.getFullYear()%100,t,2)}function _l(e,t){return Eu(e.getFullYear()%1e4,t,4)}function yl(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+Eu(t/60|0,"0",2)+Eu(t%60,"0",2)}function vl(e,t){return Eu(e.getUTCDate(),t,2)}function gl(e,t){return Eu(e.getUTCHours(),t,2)}function bl(e,t){return Eu(e.getUTCHours()%12||12,t,2)}function Ml(e,t){return Eu(1+uu.count(bu(e),e),t,3)}function kl(e,t){return Eu(e.getUTCMilliseconds(),t,3)}function wl(e,t){return kl(e,t)+"000"}function xl(e,t){return Eu(e.getUTCMonth()+1,t,2)}function Ll(e,t){return Eu(e.getUTCMinutes(),t,2)}function Tl(e,t){return Eu(e.getUTCSeconds(),t,2)}function Yl(e){var t=e.getUTCDay();return 0===t?7:t}function Sl(e,t){return Eu(cu.count(bu(e),e),t,2)}function Dl(e,t){var n=e.getUTCDay();return e=n>=4||0===n?pu(e):pu.ceil(e),Eu(pu.count(bu(e),e)+(4===bu(e).getUTCDay()),t,2)}function Ol(e){return e.getUTCDay()}function jl(e,t){return Eu(du.count(bu(e),e),t,2)}function El(e,t){return Eu(e.getUTCFullYear()%100,t,2)}function Pl(e,t){return Eu(e.getUTCFullYear()%1e4,t,4)}function Al(){return"+0000"}function Cl(){return"%"}function Hl(e){return+e}function Nl(e){return Math.floor(+e/1e3)}!function(e){xu=function(e){var t=e.dateTime,n=e.date,r=e.time,a=e.periods,i=e.days,o=e.shortDays,s=e.months,u=e.shortMonths,l=Au(a),c=Cu(a),d=Au(i),f=Cu(i),h=Au(o),p=Cu(o),m=Au(s),_=Cu(s),y=Au(u),v=Cu(u),g={a:function(e){return o[e.getDay()]},A:function(e){return i[e.getDay()]},b:function(e){return u[e.getMonth()]},B:function(e){return s[e.getMonth()]},c:null,d:tl,e:tl,f:ol,H:nl,I:rl,j:al,L:il,m:sl,M:ul,p:function(e){return a[+(e.getHours()>=12)]},Q:Hl,s:Nl,S:ll,u:cl,U:dl,V:fl,w:hl,W:pl,x:null,X:null,y:ml,Y:_l,Z:yl,"%":Cl},b={a:function(e){return o[e.getUTCDay()]},A:function(e){return i[e.getUTCDay()]},b:function(e){return u[e.getUTCMonth()]},B:function(e){return s[e.getUTCMonth()]},c:null,d:vl,e:vl,f:wl,H:gl,I:bl,j:Ml,L:kl,m:xl,M:Ll,p:function(e){return a[+(e.getUTCHours()>=12)]},Q:Hl,s:Nl,S:Tl,u:Yl,U:Sl,V:Dl,w:Ol,W:jl,x:null,X:null,y:El,Y:Pl,Z:Al,"%":Cl},M={a:function(e,t,n){var r=h.exec(t.slice(n));return r?(e.w=p[r[0].toLowerCase()],n+r[0].length):-1},A:function(e,t,n){var r=d.exec(t.slice(n));return r?(e.w=f[r[0].toLowerCase()],n+r[0].length):-1},b:function(e,t,n){var r=y.exec(t.slice(n));return r?(e.m=v[r[0].toLowerCase()],n+r[0].length):-1},B:function(e,t,n){var r=m.exec(t.slice(n));return r?(e.m=_[r[0].toLowerCase()],n+r[0].length):-1},c:function(e,n,r){return x(e,t,n,r)},d:Gu,e:Gu,f:Xu,H:Ju,I:Ju,j:Vu,L:Ku,m:Bu,M:qu,p:function(e,t,n){var r=l.exec(t.slice(n));return r?(e.p=c[r[0].toLowerCase()],n+r[0].length):-1},Q:Zu,s:el,S:$u,u:Nu,U:Iu,V:Ru,w:Hu,W:Wu,x:function(e,t,r){return x(e,n,t,r)},X:function(e,t,n){return x(e,r,t,n)},y:zu,Y:Fu,Z:Uu,"%":Qu};function k(e,t){return function(n){var r,a,i,o=[],s=-1,u=0,l=e.length;for(n instanceof Date||(n=new Date(+n));++s53)return null;"w"in i||(i.w=1),"Z"in i?(a=(r=ku(wu(i.y))).getUTCDay(),r=a>4||0===a?du.ceil(r):du(r),r=uu.offset(r,7*(i.V-1)),i.y=r.getUTCFullYear(),i.m=r.getUTCMonth(),i.d=r.getUTCDate()+(i.w+6)%7):(a=(r=t(wu(i.y))).getDay(),r=a>4||0===a?Js.ceil(r):Js(r),r=Bs.offset(r,7*(i.V-1)),i.y=r.getFullYear(),i.m=r.getMonth(),i.d=r.getDate()+(i.w+6)%7)}else("W"in i||"U"in i)&&("w"in i||(i.w="u"in i?i.u%7:"W"in i?1:0),a="Z"in i?ku(wu(i.y)).getUTCDay():t(wu(i.y)).getDay(),i.m=0,i.d="W"in i?(i.w+6)%7+7*i.W-(a+5)%7:i.w+7*i.U-(a+6)%7);return"Z"in i?(i.H+=i.Z/100|0,i.M+=i.Z%100,ku(i)):t(i)}}function x(e,t,n,r){for(var a,i,o=0,s=t.length,u=n.length;o=u)return-1;if(37===(a=t.charCodeAt(o++))){if(a=t.charAt(o++),!(i=M[a in Su?t.charAt(o++):a])||(r=i(e,n,r))<0)return-1}else if(a!=n.charCodeAt(r++))return-1}return r}return g.x=k(n,g),g.X=k(r,g),g.c=k(t,g),b.x=k(n,b),b.X=k(r,b),b.c=k(t,b),{format:function(e){var t=k(e+="",g);return t.toString=function(){return e},t},parse:function(e){var t=w(e+="",Mu);return t.toString=function(){return e},t},utcFormat:function(e){var t=k(e+="",b);return t.toString=function(){return e},t},utcParse:function(e){var t=w(e,ku);return t.toString=function(){return e},t}}}(e),Lu=xu.format,xu.parse,Tu=xu.utcFormat,Yu=xu.utcParse}({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});Date.prototype.toISOString||Tu("%Y-%m-%dT%H:%M:%S.%LZ");+new Date("2000-01-01T00:00:00.000Z")||Yu("%Y-%m-%dT%H:%M:%S.%LZ");var Il=1e3,Rl=60*Il,Wl=60*Rl,Fl=24*Wl,zl=7*Fl,Ul=30*Fl,Bl=365*Fl;function Gl(e){return new Date(e)}function Vl(e){return e instanceof Date?+e:+new Date(+e)}function Jl(e,t,n,r,a,i,o,s,u){var l=Xo(Jo,So),c=l.invert,d=l.domain,f=u(".%L"),h=u(":%S"),p=u("%I:%M"),m=u("%I %p"),_=u("%a %d"),y=u("%b %d"),v=u("%B"),g=u("%Y"),b=[[o,1,Il],[o,5,5*Il],[o,15,15*Il],[o,30,30*Il],[i,1,Rl],[i,5,5*Rl],[i,15,15*Rl],[i,30,30*Rl],[a,1,Wl],[a,3,3*Wl],[a,6,6*Wl],[a,12,12*Wl],[r,1,Fl],[r,2,2*Fl],[n,1,zl],[t,1,Ul],[t,3,3*Ul],[e,1,Bl]];function M(s){return(o(s)=0&&a===+a?"".concat(a,"px"):a),";");var r,a,i},"")},_c=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(null==e||me())return{width:0,height:0};var n="".concat(e),r=mc(t),a="".concat(n,"-").concat(r);if(fc.widthCache[a])return fc.widthCache[a];try{var i=document.getElementById("recharts_measurement_span");i||((i=document.createElement("span")).setAttribute("id","recharts_measurement_span"),document.body.appendChild(i));var o=function(e){for(var t=1;t2e3&&(fc.cacheCount=0,fc.widthCache={}),u}catch(e){return{width:0,height:0}}};function yc(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function vc(e){return(vc="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})(e)}function gc(){return(gc=Object.assign||function(e){for(var t=1;t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}function Mc(e,t){for(var n=0;n=0?1:-1;"insideStart"===o?(r=p+g*u,a=_):"insideEnd"===o?(r=m-g*u,a=!_):"end"===o&&(r=m+g*u,a=_),a=v<=0?a:!a;var b=If(c,d,y,r),M=If(c,d,y,r+359*(a?1:-1)),k="M".concat(b.x,",").concat(b.y,"\n A").concat(y,",").concat(y,",0,1,").concat(a?0:1,",\n ").concat(M.x,",").concat(M.y),w=T()(e.id)?V("recharts-radial-line-"):e.id;return i.a.createElement("text",Dc({},n,{dominantBaseline:"central",className:S()("recharts-radial-bar-label",l)}),i.a.createElement("defs",null,i.a.createElement("path",{id:w,d:k})),i.a.createElement("textPath",{xlinkHref:"#".concat(w)},t))},Hc=function(e){var t=e.viewBox,n=e.offset,r=e.position,a=t.cx,i=t.cy,o=t.innerRadius,s=t.outerRadius,u=(t.startAngle+t.endAngle)/2;if("outside"===r){var l=If(a,i,s+n,u),c=l.x;return{x:c,y:l.y,textAnchor:c>=a?"start":"end",verticalAnchor:"middle"}}if("center"===r)return{x:a,y:i,textAnchor:"middle",verticalAnchor:"middle"};if("centerTop"===r)return{x:a,y:i,textAnchor:"middle",verticalAnchor:"start"};if("centerBottom"===r)return{x:a,y:i,textAnchor:"middle",verticalAnchor:"end"};var d=If(a,i,(o+s)/2,u);return{x:d.x,y:d.y,textAnchor:"middle",verticalAnchor:"middle"}},Nc=function(e){var t=e.viewBox,n=e.offset,r=e.position,a=t.x,i=t.y,o=t.width,s=t.height,u=s>=0?1:-1;return"top"===r?{x:a+o/2,y:i-u*n,textAnchor:"middle",verticalAnchor:u>0?"end":"start"}:"bottom"===r?{x:a+o/2,y:i+s+u*n,textAnchor:"middle",verticalAnchor:"start"}:"left"===r?{x:a-n,y:i+s/2,textAnchor:"end",verticalAnchor:"middle"}:"right"===r?{x:a+o+n,y:i+s/2,textAnchor:"start",verticalAnchor:"middle"}:"insideLeft"===r?{x:a+n,y:i+s/2,textAnchor:"start",verticalAnchor:"middle"}:"insideRight"===r?{x:a+o-n,y:i+s/2,textAnchor:"end",verticalAnchor:"middle"}:"insideTop"===r?{x:a+o/2,y:i+u*n,textAnchor:"middle",verticalAnchor:"start"}:"insideBottom"===r?{x:a+o/2,y:i+s-u*n,textAnchor:"middle",verticalAnchor:"end"}:"insideTopLeft"===r?{x:a+n,y:i+u*n,textAnchor:"start",verticalAnchor:"start"}:"insideTopRight"===r?{x:a+o-n,y:i+u*n,textAnchor:"end",verticalAnchor:"start"}:"insideBottomLeft"===r?{x:a+n,y:i+s-u*n,textAnchor:"start",verticalAnchor:"end"}:"insideBottomRight"===r?{x:a+o-n,y:i+s-u*n,textAnchor:"end",verticalAnchor:"end"}:E()(r)&&(U(r.x)||z(r.x))&&(U(r.y)||z(r.y))?{x:a+J(r.x,o),y:i+J(r.y,s),textAnchor:"end",verticalAnchor:"end"}:{x:a+o/2,y:i+s/2,textAnchor:"middle",verticalAnchor:"middle"}},Ic=function(e){return U(e.cx)};function Rc(e){var t,n=e.viewBox,r=e.position,o=e.value,s=e.children,u=e.content,l=e.className,c=void 0===l?"":l;if(!n||T()(o)&&T()(s)&&!Object(a.isValidElement)(u)&&!b()(u))return null;if(Object(a.isValidElement)(u))return Object(a.cloneElement)(u,e);if(b()(u)){if(t=u(e),Object(a.isValidElement)(t))return t}else t=Ac(e);var d=Ic(n),f=le(e);if(d&&("insideStart"===r||"insideEnd"===r||"end"===r))return Cc(e,t,f);var h=d?Hc(e):Nc(e);return i.a.createElement(Yc,Dc({className:S()("recharts-label",c)},f,h),t)}Rc.displayName="Label",Rc.defaultProps={offset:5},Rc.propTypes=Pc;var Wc=function(e){var t=e.cx,n=e.cy,r=e.angle,a=e.startAngle,i=e.endAngle,o=e.r,s=e.radius,u=e.innerRadius,l=e.outerRadius,c=e.x,d=e.y,f=e.top,h=e.left,p=e.width,m=e.height,_=e.clockWise;if(U(p)&&U(m)){if(U(c)&&U(d))return{x:c,y:d,width:p,height:m};if(U(f)&&U(h))return{x:f,y:h,width:p,height:m}}return U(c)&&U(d)?{x:c,y:d,width:0,height:0}:U(t)&&U(n)?{cx:t,cy:n,startAngle:a||r||0,endAngle:i||r||0,innerRadius:u||0,outerRadius:l||s||o||0,clockWise:_}:e.viewBox?e.viewBox:{}};Rc.parseViewBox=Wc,Rc.renderCallByParent=function(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];if(!e||!e.children&&n&&!e.label)return null;var r=e.children,o=Wc(e),s=se(r,Rc).map(function(e,n){return Object(a.cloneElement)(e,{viewBox:t||o,key:"label-".concat(n)})});return n?[function(e,t){return e?!0===e?i.a.createElement(Rc,{key:"label-implicit",viewBox:t}):B(e)?i.a.createElement(Rc,{key:"label-implicit",viewBox:t,value:e}):Object(a.isValidElement)(e)||b()(e)?i.a.createElement(Rc,{key:"label-implicit",content:e,viewBox:t}):E()(e)?i.a.createElement(Rc,Dc({viewBox:t},e,{key:"label-implicit"})):null:null}(e.label,t||o)].concat(Sc(s)):s};var Fc=Rc,zc=n(104),Uc=n.n(zc);function Bc(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Gc(e,t){for(var n=0;n1&&void 0!==arguments[1]?arguments[1]:{}).bandAware;if(void 0!==e){if(t){var n=this.bandwidth?this.bandwidth()/2:0;return this.scale(e)+n}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}},{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}}]),e}();qc.EPS=1e-4;var $c,Kc,Xc,Qc=function(){function e(t){Bc(this,e),this.scales=Uc()(t,qc.create),Object.assign(this,this.scales)}return Vc(e,null,[{key:"create",value:function(e){return new this(e)}}]),Vc(e,[{key:"apply",value:function(e){var t=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).bandAware,n=this.scales;return Uc()(e,function(e,r){return n[r].apply(e,{bandAware:t})})}},{key:"isInRange",value:function(e){var t=this.scales;return p()(e,function(e,n){return t[n].isInRange(e)})}}]),e}();function Zc(e){return(Zc="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})(e)}function ed(){return(ed=Object.assign||function(e){for(var t=1;t=0?1:-1,u=r>=0?1:0;if(o>0&&a instanceof Array){for(var l=[],c=0;c<4;c++)l[c]=a[c]>o?o:a[c];i="M".concat(e,",").concat(t+s*l[0]),l[0]>0&&(i+="A ".concat(l[0],",").concat(l[0],",0,0,").concat(u,",").concat(e+l[0],",").concat(t)),i+="L ".concat(e+n-l[1],",").concat(t),l[1]>0&&(i+="A ".concat(l[1],",").concat(l[1],",0,0,").concat(u,",\n ").concat(e+n,",").concat(t+s*l[1])),i+="L ".concat(e+n,",").concat(t+r-s*l[2]),l[2]>0&&(i+="A ".concat(l[2],",").concat(l[2],",0,0,").concat(u,",\n ").concat(e+n-l[2],",").concat(t+r)),i+="L ".concat(e+l[3],",").concat(t+r),l[3]>0&&(i+="A ".concat(l[3],",").concat(l[3],",0,0,").concat(u,",\n ").concat(e,",").concat(t+r-s*l[3])),i+="Z"}else if(o>0&&a===+a&&a>0){var d=Math.min(o,a);i="M ".concat(e,",").concat(t+s*d,"\n A ").concat(d,",").concat(d,",0,0,").concat(u,",").concat(e+d,",").concat(t,"\n L ").concat(e+n-d,",").concat(t,"\n A ").concat(d,",").concat(d,",0,0,").concat(u,",").concat(e+n,",").concat(t+s*d,"\n L ").concat(e+n,",").concat(t+r-s*d,"\n A ").concat(d,",").concat(d,",0,0,").concat(u,",").concat(e+n-d,",").concat(t+r,"\n L ").concat(e+d,",").concat(t+r,"\n A ").concat(d,",").concat(d,",0,0,").concat(u,",").concat(e,",").concat(t+r-s*d," Z")}else i="M ".concat(e,",").concat(t," h ").concat(n," v ").concat(r," h ").concat(-n," Z");return i},Nd=Z((xd=wd=function(e){function t(){var e,n;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);for(var r=arguments.length,a=new Array(r),i=0;i0,from:{width:a,height:o,x:n,y:r},to:{width:a,height:o,x:n,y:r},duration:f,animationEasing:d,isActive:m},function(t){var n=t.width,r=t.height,a=t.x,o=t.y;return i.a.createElement(Jt,{canBegin:l>0,from:"0px ".concat(-1===l?1:l,"px"),to:"".concat(l,"px 0px"),attributeName:"strokeDasharray",begin:h,duration:f,isActive:p,easing:d},i.a.createElement("path",Sd({},le(e.props),de(e.props),{className:_,d:Hd(a,o,n,r,s),ref:function(t){e.node=t}})))}):i.a.createElement("path",Sd({},le(this.props),de(this.props),{className:_,d:Hd(n,r,a,o,s)}))}}])&&Dd(n.prototype,r),o&&Dd(n,o),t}(),wd.displayName="Rectangle",wd.propTypes=function(e){for(var t=1;t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}function Xd(e,t){for(var n=0;n=0});if(i&&i.length){var o=i.map(function(e){return e.props.dataKey});return e.reduce(function(e,t){var r=sf(t,n,0),a=A()(r)?[Wa()(r),Ia()(r)]:[r,r],i=o.reduce(function(e,n){var r=sf(t,n,0),i=a[0]-Math.abs(A()(r)?r[0]:r),o=a[1]+Math.abs(A()(r)?r[1]:r);return[Math.min(i,e[0]),Math.max(o,e[1])]},[1/0,-1/0]);return[Math.min(i[0],e[0]),Math.max(i[1],e[1])]},[1/0,-1/0])}return null},ff=function(e,t,n,r){var a=t.map(function(t){var a=t.props.dataKey;return"number"===n&&a&&df(e,t,a)||uf(e,a,n,r)});if("number"===n)return a.reduce(function(e,t){return[Math.min(e[0],t[0]),Math.max(e[1],t[1])]},[1/0,-1/0]);var i={};return a.reduce(function(e,t){for(var n=0,r=t.length;n=0||t.indexOf("AreaChart")>=0)?{scale:yi(),realScaleType:"point"}:"category"===a?{scale:_i(),realScaleType:"band"}:{scale:ps(),realScaleType:"linear"};if(O()(n)){var s="scale".concat(n.slice(0,1).toUpperCase()).concat(n.slice(1));return{scale:(r[s]||yi)(),realScaleType:r[s]?s:"point"}}return b()(n)?{scale:n}:{scale:yi(),realScaleType:"point"}},vf=function(e){var t=e.domain();if(t&&!(t.length<=2)){var n=t.length,r=e.range(),a=Math.min(r[0],r[1])-1e-4,i=Math.max(r[0],r[1])+1e-4,o=e(t[0]),s=e(t[n-1]);(oi||si)&&e.domain([t[0],t[n-1]])}},gf={sign:function(e){var t=e.length;if(!(t<=0))for(var n=0,r=e[0].length;n=0?(e[o][n][0]=a,e[o][n][1]=a+s,a=e[o][n][1]):(e[o][n][0]=i,e[o][n][1]=i+s,i=e[o][n][1])}},expand:function(e,t){if((r=e.length)>0){for(var n,r,a,i=0,o=e[0].length;i0){for(var n,r=0,a=e[t[0]],i=a.length;r0&&(r=(n=e[t[0]]).length)>0){for(var n,r,a,i=0,o=1;o=2){for(var n=v()(t,function(e){return e.coordinate}),r=1/0,a=1,i=n.length;a2&&void 0!==arguments[2]?arguments[2]:{top:0,right:0,bottom:0,left:0};return Math.min(Math.abs(e-(n.left||0)-(n.right||0)),Math.abs(t-(n.top||0)-(n.bottom||0)))/2},Wf=function(e,t){var n,r,a,i,o,s,u=e.x,l=e.y,c=t.cx,d=t.cy,f=(r={x:c,y:d},a=(n={x:u,y:l}).x,i=n.y,o=r.x,s=r.y,Math.sqrt(Math.pow(a-o,2)+Math.pow(i-s,2)));if(f<=0)return{radius:f};var h=(u-c)/f,p=Math.acos(h);return l>d&&(p=2*Math.PI-p),{radius:f,angle:Nf(p),angleInRadian:p}},Ff=function(e,t){var n=t.startAngle,r=t.endAngle,a=Math.floor(n/360),i=Math.floor(r/360);return e+360*Math.min(a,i)},zf=function(e,t){var n=e.x,r=e.y,a=Wf({x:n,y:r},t),i=a.radius,o=a.angle,s=t.innerRadius,u=t.outerRadius;if(iu)return!1;if(0===i)return!0;var l,c=function(e){var t=e.startAngle,n=e.endAngle,r=Math.floor(t/360),a=Math.floor(n/360),i=Math.min(r,a);return{startAngle:t-360*i,endAngle:n-360*i}}(t),d=c.startAngle,f=c.endAngle,h=o;if(d<=f){for(;h>f;)h-=360;for(;h=d&&h<=f}else{for(;h>d;)h-=360;for(;h=f&&h<=d}return l?Of({},t,{radius:i,angle:Ff(h,t)}):null};function Uf(e){return(Uf="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})(e)}function Bf(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Gf(){return(Gf=Object.assign||function(e){for(var t=1;t180),",").concat(+(i>s),",\n ").concat(l.x,",").concat(l.y,"\n ");if(r>0){var d=If(t,n,r,i),f=If(t,n,r,s);c+="L ".concat(f.x,",").concat(f.y,"\n A ").concat(r,",").concat(r,",0,\n ").concat(+(Math.abs(o)>180),",").concat(+(i<=s),",\n ").concat(d.x,",").concat(d.y," Z")}else c+="L ".concat(t,",").concat(n," Z");return c},Qf=Z((Cf=Af=function(e){function t(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),Jf(this,qf(t).apply(this,arguments))}var n,r,o;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}}),t&&$f(e,t)}(t,a["Component"]),n=t,(r=[{key:"render",value:function(){var e=this.props,t=e.cx,n=e.cy,r=e.innerRadius,a=e.outerRadius,o=e.cornerRadius,s=e.startAngle,u=e.endAngle,l=e.className;if(a0&&Math.abs(s-u)<360?function(e){var t=e.cx,n=e.cy,r=e.innerRadius,a=e.outerRadius,i=e.cornerRadius,o=e.startAngle,s=e.endAngle,u=F(s-o),l=Kf({cx:t,cy:n,radius:a,angle:o,sign:u,cornerRadius:i}),c=l.circleTangency,d=l.lineTangency,f=l.theta,h=Kf({cx:t,cy:n,radius:a,angle:s,sign:-u,cornerRadius:i}),p=h.circleTangency,m=h.lineTangency,_=h.theta,y=Math.abs(o-s)-f-_;if(y<0)return Xf({cx:t,cy:n,innerRadius:r,outerRadius:a,startAngle:o,endAngle:s});var v="M ".concat(d.x,",").concat(d.y,"\n A").concat(i,",").concat(i,",0,0,").concat(+(u<0),",").concat(c.x,",").concat(c.y,"\n A").concat(a,",").concat(a,",0,").concat(+(y>180),",").concat(+(u<0),",").concat(p.x,",").concat(p.y,"\n A").concat(i,",").concat(i,",0,0,").concat(+(u<0),",").concat(m.x,",").concat(m.y,"\n ");if(r>0){var g=Kf({cx:t,cy:n,radius:r,angle:o,sign:u,isExternal:!0,cornerRadius:i}),b=g.circleTangency,M=g.lineTangency,k=g.theta,w=Kf({cx:t,cy:n,radius:r,angle:s,sign:-u,isExternal:!0,cornerRadius:i}),x=w.circleTangency,L=w.lineTangency,T=w.theta,Y=Math.abs(o-s)-k-T;if(Y<0)return"".concat(v,"L").concat(t,",").concat(n,"Z");v+="L".concat(L.x,",").concat(L.y,"\n A").concat(i,",").concat(i,",0,0,").concat(+(u<0),",").concat(x.x,",").concat(x.y,"\n A").concat(r,",").concat(r,",0,").concat(+(Y>180),",").concat(+(u>0),",").concat(b.x,",").concat(b.y,"\n A").concat(i,",").concat(i,",0,0,").concat(+(u<0),",").concat(M.x,",").concat(M.y,"Z")}else v+="L".concat(t,",").concat(n,"Z");return v}({cx:t,cy:n,innerRadius:r,outerRadius:a,cornerRadius:Math.min(h,f/2),startAngle:s,endAngle:u}):Xf({cx:t,cy:n,innerRadius:r,outerRadius:a,startAngle:s,endAngle:u}),i.a.createElement("path",Gf({},le(this.props),de(this.props),{className:d,d:c}))}}])&&Vf(n.prototype,r),o&&Vf(n,o),t}(),Af.displayName="Sector",Af.propTypes=function(e){for(var t=1;t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}function ah(e,t){for(var n=0;n=2?F(m[1].coordinate-m[0].coordinate):1;if(1===v?(n="width"===p?c:d,r="width"===p?c+f:d+h):(n="width"===p?c+f:d+h,r="width"===p?c:d),t){var g=a[y-1],M=b()(i)?i(g.value):g.value,k=_c(M)[p]+_,w=v*(g.coordinate+v*k/2-r);m[y-1]=g=th({},g,{tickCoord:w>0?g.coordinate-w*v:g.coordinate}),v*(g.tickCoord-v*k/2-n)>=0&&v*(g.tickCoord+v*k/2-r)<=0&&(r=g.tickCoord-v*(k/2+u),m[y-1]=th({},g,{isShow:!0}))}for(var x=t?y-1:y,L=0;L=0&&v*(T.tickCoord+v*S/2-r)<=0&&(n=T.tickCoord+v*(S/2+u),m[L]=th({},T,{isShow:!0}))}return m.filter(function(e){return e.isShow})}},{key:"getTicksEnd",value:function(e){var t,n,r=e.ticks,a=e.tickFormatter,i=e.viewBox,o=e.orientation,s=e.minTickGap,u=e.unit,l=i.x,c=i.y,d=i.width,f=i.height,h="top"===o||"bottom"===o?"width":"height",p=u?_c(u)[h]:0,m=(r||[]).slice(),_=m.length,y=_>=2?F(m[1].coordinate-m[0].coordinate):1;1===y?(t="width"===h?l:c,n="width"===h?l+d:c+f):(t="width"===h?l+d:c+f,n="width"===h?l:c);for(var v=_-1;v>=0;v--){var g=m[v],M=b()(a)?a(g.value):g.value,k=_c(M)[h]+p;if(v===_-1){var w=y*(g.coordinate+y*k/2-n);m[v]=g=th({},g,{tickCoord:w>0?g.coordinate-w*y:g.coordinate})}else m[v]=g=th({},g,{tickCoord:g.coordinate});y*(g.tickCoord-y*k/2-t)>=0&&y*(g.tickCoord+y*k/2-n)<=0&&(n=g.tickCoord-y*(k/2+s),m[v]=th({},g,{isShow:!0}))}return m.filter(function(e){return e.isShow})}},{key:"renderTickItem",value:function(e,t,n){return i.a.isValidElement(e)?i.a.cloneElement(e,t):b()(e)?e(t):i.a.createElement(Yc,eh({},t,{className:"recharts-cartesian-axis-tick-value"}),n)}}],(r=[{key:"shouldComponentUpdate",value:function(e,t){var n=e.viewBox,r=rh(e,["viewBox"]),a=this.props,i=a.viewBox,o=rh(a,["viewBox"]);return!X(n,i)||!X(r,o)||!X(t,this.state)}},{key:"getTickLineCoord",value:function(e){var t,n,r,a,i,o,s=this.props,u=s.x,l=s.y,c=s.width,d=s.height,f=s.orientation,h=s.tickSize,p=s.mirror,m=s.tickMargin,_=p?-1:1,y=e.tickSize||h,v=U(e.tickCoord)?e.tickCoord:e.coordinate;switch(f){case"top":t=n=e.coordinate,o=(r=(a=l+!p*d)-_*y)-_*m,i=v;break;case"left":r=a=e.coordinate,i=(t=(n=u+!p*c)-_*y)-_*m,o=v;break;case"right":r=a=e.coordinate,i=(t=(n=u+p*c)+_*y)+_*m,o=v;break;default:t=n=e.coordinate,o=(r=(a=l+p*d)+_*y)+_*m,i=v}return{line:{x1:t,y1:r,x2:n,y2:a},tick:{x:i,y:o}}}},{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 e=this.props,t=e.x,n=e.y,r=e.width,a=e.height,o=e.orientation,s=e.axisLine,u=e.mirror,l=th({},le(this.props),{fill:"none"},le(s));if("top"===o||"bottom"===o){var c="top"===o&&!u||"bottom"===o&&u;l=th({},l,{x1:t,y1:n+c*a,x2:t+r,y2:n+c*a})}else{var d="left"===o&&!u||"right"===o&&u;l=th({},l,{x1:t+d*r,y1:n,x2:t+d*r,y2:n+a})}return i.a.createElement("line",eh({className:"recharts-cartesian-axis-line"},l))}},{key:"renderTicks",value:function(e){var n=this,r=this.props,a=r.tickLine,o=r.stroke,s=r.tick,u=r.tickFormatter,l=r.unit,c=t.getTicks(th({},this.props,{ticks:e})),d=this.getTickTextAnchor(),f=this.getTickVerticalAnchor(),h=le(this.props),p=le(s),m=th({},h,{fill:"none"},le(a)),_=c.map(function(e,t){var r=n.getTickLineCoord(e),_=r.line,y=r.tick,v=th({textAnchor:d,verticalAnchor:f},h,{stroke:"none",fill:o},p,y,{index:t,payload:e,visibleTicksCount:c.length});return i.a.createElement(Oe,eh({className:"recharts-cartesian-axis-tick",key:"tick-".concat(t)},he(n.props,e,t)),a&&i.a.createElement("line",eh({className:"recharts-cartesian-axis-tick-line"},m,_)),s&&n.constructor.renderTickItem(s,v,"".concat(b()(u)?u(e.value):e.value).concat(l||"")))});return i.a.createElement("g",{className:"recharts-cartesian-axis-ticks"},_)}},{key:"render",value:function(){var e=this.props,t=e.axisLine,n=e.width,r=e.height,a=e.ticksGenerator,o=e.className;if(e.hide)return null;var s=this.props,u=s.ticks,l=rh(s,["ticks"]),c=u;return b()(a)&&(c=u&&u.length>0?a(this.props):a(l)),n<=0||r<=0||!c||!c.length?null:i.a.createElement(Oe,{className:S()("recharts-cartesian-axis",o)},t&&this.renderAxisLine(),this.renderTicks(c),Fc.renderCallByParent(this.props))}}])&&ah(n.prototype,r),o&&ah(n,o),t}();uh.displayName="CartesianAxis",uh.propTypes=th({},ne,re,{className:s.a.string,x:s.a.number,y:s.a.number,width:s.a.number,height:s.a.number,orientation:s.a.oneOf(["top","bottom","left","right"]),viewBox:s.a.shape({x:s.a.number,y:s.a.number,width:s.a.number,height:s.a.number}),tick:s.a.oneOfType([s.a.bool,s.a.func,s.a.object,s.a.element]),axisLine:s.a.oneOfType([s.a.bool,s.a.object]),tickLine:s.a.oneOfType([s.a.bool,s.a.object]),mirror:s.a.bool,tickMargin:s.a.number.isRequired,minTickGap:s.a.number,ticks:s.a.array,tickSize:s.a.number,stroke:s.a.string,tickFormatter:s.a.func,ticksGenerator:s.a.func,interval:s.a.oneOfType([s.a.number,s.a.oneOf(["preserveStart","preserveEnd","preserveStartEnd"])])}),uh.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 lh=uh;function ch(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var dh,fh,hh,ph=["Webkit","Moz","O","ms"],mh=function(e,t){if(!e)return null;var n=e.replace(/(\w)/,function(e){return e.toUpperCase()}),r=ph.reduce(function(e,r){return function(e){for(var t=1;t0&&n.handleDrag(e.changedTouches[0])},n.handleDragEnd=function(){n.setState({isTravellerMoving:!1,isSlideMoving:!1})},n.handleLeaveWrapper=function(){(n.state.isTravellerMoving||n.state.isSlideMoving)&&(n.leaveTimer=setTimeout(n.handleDragEnd,1e3))},n.handleEnterSlideOrTraveller=function(){n.setState({isTextActive:!0})},n.handleLeaveSlideOrTraveller=function(){n.setState({isTextActive:!1})},n.handleSlideDragStart=function(e){var t=e.changedTouches&&e.changedTouches.length?e.changedTouches[0]:e;n.setState({isTravellerMoving:!1,isSlideMoving:!0,slideMoveStartX:t.pageX})},n.travellerDragStartHandlers={startX:n.handleTravellerDragStart.bind(kh(kh(n)),"startX"),endX:n.handleTravellerDragStart.bind(kh(kh(n)),"endX")},n.state=e.data&&e.data.length?n.updateScale(e):{},n}var n,r,o;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}}),t&&Mh(e,t)}(t,a["Component"]),n=t,o=[{key:"getIndexInRange",value:function(e,t){for(var n=0,r=e.length-1;r-n>1;){var a=Math.floor((n+r)/2);e[a]>t?r=a:n=a}return t>=e[r]?r:n}}],(r=[{key:"componentWillReceiveProps",value:function(e){var t=this,n=this.props,r=n.data,a=n.width,i=n.x,o=n.travellerWidth,s=n.updateId;(e.data!==r||e.updateId!==s)&&e.data&&e.data.length?this.setState(this.updateScale(e)):e.width===a&&e.x===i&&e.travellerWidth===o||(this.scale.range([e.x,e.x+e.width-e.travellerWidth]),this.scaleValues=this.scale.domain().map(function(e){return t.scale(e)}),this.setState({startX:this.scale(e.startIndex),endX:this.scale(e.endIndex)}))}},{key:"componentWillUnmount",value:function(){this.scale=null,this.scaleValues=null,this.leaveTimer&&(clearTimeout(this.leaveTimer),this.leaveTimer=null)}},{key:"getIndex",value:function(e){var t=e.startX,n=e.endX,r=this.props,a=r.gap,i=r.data.length-1,o=Math.min(t,n),s=Math.max(t,n),u=this.constructor.getIndexInRange(this.scaleValues,o),l=this.constructor.getIndexInRange(this.scaleValues,s);return{startIndex:u-u%a,endIndex:l===i?i:l-l%a}}},{key:"getTextOfTick",value:function(e){var t=this.props,n=t.data,r=t.tickFormatter,a=t.dataKey,i=sf(n[e],a,e);return b()(r)?r(i):i}},{key:"handleSlideDrag",value:function(e){var t=this.state,n=t.slideMoveStartX,r=t.startX,a=t.endX,i=this.props,o=i.x,s=i.width,u=i.travellerWidth,l=i.startIndex,c=i.endIndex,d=i.onChange,f=e.pageX-n;f>0?f=Math.min(f,o+s-u-a,o+s-u-r):f<0&&(f=Math.max(f,o-r,o-a));var h=this.getIndex({startX:r+f,endX:a+f});h.startIndex===l&&h.endIndex===c||!d||d(h),this.setState({startX:r+f,endX:a+f,slideMoveStartX:e.pageX})}},{key:"handleTravellerDragStart",value:function(e,t){var n=t.changedTouches&&t.changedTouches.length?t.changedTouches[0]:t;this.setState({isSlideMoving:!1,isTravellerMoving:!0,movingTravellerId:e,brushMoveStartX:n.pageX})}},{key:"handleTravellerMove",value:function(e){var t,n=this.state,r=n.brushMoveStartX,a=n.movingTravellerId,i=n.endX,o=n.startX,s=this.state[a],u=this.props,l=u.x,c=u.width,d=u.travellerWidth,f=u.onChange,h=u.gap,p=u.data,m={startX:this.state.startX,endX:this.state.endX},_=e.pageX-r;_>0?_=Math.min(_,l+c-d-s):_<0&&(_=Math.max(_,l-s)),m[a]=s+_;var y=this.getIndex(m),v=y.startIndex,g=y.endIndex;this.setState((vh(t={},a,s+_),vh(t,"brushMoveStartX",e.pageX),t),function(){var e;f&&(e=p.length-1,("startX"===a&&(i>o?v%h==0:g%h==0)||io?g%h==0:v%h==0)||i>o&&g===e)&&f(y))})}},{key:"updateScale",value:function(e){var t=this,n=e.data,r=e.startIndex,a=e.endIndex,i=e.x,o=e.width,s=e.travellerWidth,u=n.length;return this.scale=yi().domain(k()(0,u)).range([i,i+o-s]),this.scaleValues=this.scale.domain().map(function(e){return t.scale(e)}),{isTextActive:!1,isSlideMoving:!1,isTravellerMoving:!1,startX:this.scale(r),endX:this.scale(a)}}},{key:"renderBackground",value:function(){var e=this.props,t=e.x,n=e.y,r=e.width,a=e.height,o=e.fill,s=e.stroke;return i.a.createElement("rect",{stroke:s,fill:o,x:t,y:n,width:r,height:a})}},{key:"renderPanorama",value:function(){var e=this.props,t=e.x,n=e.y,r=e.width,o=e.height,s=e.data,u=e.children,l=e.padding,c=a.Children.only(u);return c?i.a.cloneElement(c,{x:t,y:n,width:r,height:o,margin:l,compact:!0,data:s}):null}},{key:"renderTraveller",value:function(e,t){var n=this.props,r=n.y,a=n.travellerWidth,o=n.height,s=n.stroke,u=Math.floor(r+o/2)-1,l=Math.max(e,this.props.x);return i.a.createElement(Oe,{className:"recharts-brush-traveller",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.travellerDragStartHandlers[t],onTouchStart:this.travellerDragStartHandlers[t],style:{cursor:"col-resize"}},i.a.createElement("rect",{x:l,y:r,width:a,height:o,fill:s,stroke:"none"}),i.a.createElement("line",{x1:l+1,y1:u,x2:l+a-1,y2:u,fill:"none",stroke:"#fff"}),i.a.createElement("line",{x1:l+1,y1:u+2,x2:l+a-1,y2:u+2,fill:"none",stroke:"#fff"}))}},{key:"renderSlide",value:function(e,t){var n=this.props,r=n.y,a=n.height,o=n.stroke;return i.a.createElement("rect",{className:"recharts-brush-slide",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.handleSlideDragStart,onTouchStart:this.handleSlideDragStart,style:{cursor:"move"},stroke:"none",fill:o,fillOpacity:.2,x:Math.min(e,t),y:r,width:Math.abs(t-e),height:a})}},{key:"renderText",value:function(){var e=this.props,t=e.startIndex,n=e.endIndex,r=e.y,a=e.height,o=e.travellerWidth,s=e.stroke,u=this.state,l=u.startX,c=u.endX,d={pointerEvents:"none",fill:s};return i.a.createElement(Oe,{className:"recharts-brush-texts"},i.a.createElement(Yc,yh({textAnchor:"end",verticalAnchor:"middle",x:Math.min(l,c)-5,y:r+a/2},d),this.getTextOfTick(t)),i.a.createElement(Yc,yh({textAnchor:"start",verticalAnchor:"middle",x:Math.max(l,c)+o+5,y:r+a/2},d),this.getTextOfTick(n)))}},{key:"render",value:function(){var e=this.props,t=e.data,n=e.className,r=e.children,a=e.x,o=e.y,s=e.width,u=e.height,l=this.state,c=l.startX,d=l.endX,f=l.isTextActive,h=l.isSlideMoving,p=l.isTravellerMoving;if(!t||!t.length||!U(a)||!U(o)||!U(s)||!U(u)||s<=0||u<=0)return null;var m=S()("recharts-brush",n),_=1===i.a.Children.count(r),y=mh("userSelect","none");return i.a.createElement(Oe,{className:m,onMouseMove:this.handleDrag,onMouseLeave:this.handleLeaveWrapper,onMouseUp:this.handleDragEnd,onTouchEnd:this.handleDragEnd,onTouchMove:this.handleTouchMove,style:y},this.renderBackground(),_&&this.renderPanorama(),this.renderSlide(c,d),this.renderTraveller(c,"startX"),this.renderTraveller(d,"endX"),(f||h||p)&&this.renderText())}}])&&gh(n.prototype,r),o&&gh(n,o),t}(),fh.displayName="Brush",fh.propTypes={className:s.a.string,fill:s.a.string,stroke:s.a.string,x:s.a.number,y:s.a.number,width:s.a.number,height:s.a.number.isRequired,travellerWidth:s.a.number,gap:s.a.number,padding:s.a.shape({top:s.a.number,right:s.a.number,bottom:s.a.number,left:s.a.number}),dataKey:s.a.oneOfType([s.a.string,s.a.number,s.a.func]),data:s.a.array,startIndex:s.a.number,endIndex:s.a.number,tickFormatter:s.a.func,children:s.a.node,onChange:s.a.func,updateId:s.a.oneOfType([s.a.string,s.a.number])},fh.defaultProps={height:40,travellerWidth:5,gap:1,fill:"#fff",stroke:"#666",padding:{top:1,right:1,bottom:1,left:1}},dh=hh))||dh,xh=n(302),Lh=new(n.n(xh).a);Lh.setMaxListeners&&Lh.setMaxListeners(10);var Th="recharts.syncMouseEvents";function Yh(e){return(Yh="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})(e)}function Sh(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},i=Object.keys(e);for(r=0;r=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}function Dh(){return(Dh=Object.assign||function(e){for(var t=1;t0&&n.handleMouseMove(e.changedTouches[0])},n.handleTouchStart=function(e){null!=e.changedTouches&&e.changedTouches.length>0&&n.handleMouseDown(e.changedTouches[0])},n.handleTouchEnd=function(e){null!=e.changedTouches&&e.changedTouches.length>0&&n.handleMouseUp(e.changedTouches[0])},n.verticalCoordinatesGenerator=function(e){var t=e.xAxis,n=e.width,r=e.height,a=e.offset;return pf(lh.getTicks(jh({},lh.defaultProps,t,{ticks:mf(t,!0),viewBox:{x:0,y:0,width:n,height:r}})),a.left,a.left+a.width)},n.horizontalCoordinatesGenerator=function(e){var t=e.yAxis,n=e.width,r=e.height,a=e.offset;return pf(lh.getTicks(jh({},lh.defaultProps,t,{ticks:mf(t,!0),viewBox:{x:0,y:0,width:n,height:r}})),a.top,a.top+a.height)},n.axesTicksGenerator=function(e){return mf(e,!0)},n.tooltipTicksGenerator=function(e){var t=q(e),n=mf(t,!1,!0);return{tooltipTicks:n,orderedTooltipTicks:v()(n,function(e){return e.coordinate}),tooltipAxis:t,tooltipAxisBandSize:Sf(t)}},n.renderCursor=function(e){var r=n.state,i=r.isTooltipActive,o=r.activeCoordinate,s=r.activePayload,u=r.offset;if(!(e&&e.props.cursor&&i&&o))return null;var l,c=n.props.layout,d=Sa;if("ScatterChart"===t)l=o,d=Ha;else if("BarChart"===t)l=n.getCursorRectangle(),d=Nd;else if("radial"===c){var f=n.getCursorPoints(),h=f.cx,p=f.cy,m=f.radius;l={cx:h,cy:p,startAngle:f.startAngle,endAngle:f.endAngle,innerRadius:m,outerRadius:m},d=Qf}else l={points:n.getCursorPoints()},d=Sa;var _=e.key||"_recharts-cursor",y=jh({stroke:"#ccc",pointerEvents:"none"},u,l,le(e.props.cursor),{payload:s,key:_,className:"recharts-tooltip-cursor"});return Object(a.isValidElement)(e.props.cursor)?Object(a.cloneElement)(e.props.cursor,y):Object(a.createElement)(d,y)},n.renderPolarAxis=function(e,t,r){var i=e.type.axisType,o=n.state["".concat(i,"Map")][e.props["".concat(i,"Id")]];return Object(a.cloneElement)(e,jh({},o,{className:i,key:e.key||"".concat(t,"-").concat(r),ticks:mf(o,!0)}))},n.renderXAxis=function(e,t,r){var a=n.state.xAxisMap[e.props.xAxisId];return n.renderAxis(a,e,t,r)},n.renderYAxis=function(e,t,r){var a=n.state.yAxisMap[e.props.yAxisId];return n.renderAxis(a,e,t,r)},n.renderGrid=function(e){var t=n.state,r=t.xAxisMap,i=t.yAxisMap,o=t.offset,s=n.props,u=s.width,l=s.height,c=q(r),d=_()(i,function(e){return p()(e.domain,Number.isFinite)})||q(i),f=e.props||{};return Object(a.cloneElement)(e,{key:e.key||"grid",x:U(f.x)?f.x:o.left,y:U(f.y)?f.y:o.top,width:U(f.width)?f.width:o.width,height:U(f.height)?f.height:o.height,xAxis:c,yAxis:d,offset:o,chartWidth:u,chartHeight:l,verticalCoordinatesGenerator:f.verticalCoordinatesGenerator||n.verticalCoordinatesGenerator,horizontalCoordinatesGenerator:f.horizontalCoordinatesGenerator||n.horizontalCoordinatesGenerator})},n.renderPolarGrid=function(e){var t=n.state,r=t.radiusAxisMap,i=t.angleAxisMap,o=q(r),s=q(i),u=s.cx,l=s.cy,c=s.innerRadius,d=s.outerRadius;return Object(a.cloneElement)(e,{polarAngles:mf(s,!0).map(function(e){return e.coordinate}),polarRadius:mf(o,!0).map(function(e){return e.coordinate}),cx:u,cy:l,innerRadius:c,outerRadius:d,key:e.key||"polar-grid"})},n.renderBrush=function(e){var t=n.props,r=t.margin,i=t.data,o=n.state,s=o.offset,u=o.dataStartIndex,l=o.dataEndIndex,c=o.updateId;return Object(a.cloneElement)(e,{key:e.key||"_recharts-brush",onChange:_f(n.handleBrushChange,null,e.props.onChange),data:i,x:U(e.props.x)?e.props.x:s.left,y:U(e.props.y)?e.props.y:s.top+s.height+s.brushBottom-(r.bottom||0),width:U(e.props.width)?e.props.width:s.width,startIndex:u,endIndex:l,updateId:"brush-".concat(c)})},n.renderReferenceElement=function(e,t,r){if(!e)return null;var i=Hh(Hh(n)).clipPathId,o=n.state,s=o.xAxisMap,u=o.yAxisMap,l=o.offset,c=e.props,d=c.xAxisId,f=c.yAxisId;return Object(a.cloneElement)(e,{key:e.key||"".concat(t,"-").concat(r),xAxis:s[d],yAxis:u[f],viewBox:{x:l.left,y:l.top,width:l.width,height:l.height},clipPathId:i})},n.renderGraphicChild=function(e,t,r){var i=n.filterFormatItem(e,t,r);if(!i)return null;var o,s,u=Object(a.cloneElement)(e,i.props),l=n.state,c=l.isTooltipActive,d=l.tooltipAxis,f=l.activeTooltipIndex,h=l.activeLabel,p=n.props.children,m=ue(p,yn),_=i.props,y=_.points,v=_.isRange,g=_.baseLine,b=i.item.props,M=b.activeDot;return!b.hide&&c&&m&&M&&f>=0&&(d.dataKey&&!d.allowDuplicatedCategory?(o=K(y,"payload.".concat(d.dataKey),h),s=v&&g&&K(g,"payload.".concat(d.dataKey),h)):(o=y[f],s=v&&g&&g[f]),!T()(o))?[u].concat(Oh(n.renderActivePoints({item:i,activePoint:o,basePoint:s,childIndex:f,isRange:v}))):v?[u,null,null]:[u,null]};var s=n.constructor.createDefaultState(e);return n.state=jh({},s,{updateId:0},n.updateStateOfAxisMapsOffsetAndStackGroups(jh({props:e},s,{updateId:0}))),n.uniqueChartId=T()(e.id)?V("recharts"):e.id,n.clipPathId="".concat(n.uniqueChartId,"-clip"),e.throttleDelay&&(n.triggeredAfterMouseMove=x()(n.triggeredAfterMouseMove,e.throttleDelay)),n}var s,d,f;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}}),t&&Ch(e,t)}(r,a.Component),s=r,f=[{key:"getAxisNameByLayout",value: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"}}},{key:"renderActiveDot",value:function(e,t){var n;return n=Object(a.isValidElement)(e)?Object(a.cloneElement)(e,t):b()(e)?e(t):i.a.createElement(sc,t),i.a.createElement(Oe,{className:"recharts-active-dot",key:t.key},n)}}],(d=[{key:"componentDidMount",value:function(){T()(this.props.syncId)||this.addListener()}},{key:"componentWillReceiveProps",value:function(e){var t=this,n=this.props,r=n.data,a=n.children,i=n.width,o=n.height,s=n.layout,u=n.stackOffset,l=n.margin,c=this.state.updateId;if(e.data===r&&e.width===i&&e.height===o&&e.layout===s&&e.stackOffset===u&&X(e.margin,l)){if(!ve(e.children,a)){var d=T()(e.data)?c+1:c;this.setState(function(n){return jh({updateId:d},t.updateStateOfAxisMapsOffsetAndStackGroups(jh({props:e},n,{updateId:d})))})}}else{var f=this.constructor.createDefaultState(e);this.setState(jh({},f,{updateId:c+1},this.updateStateOfAxisMapsOffsetAndStackGroups(jh({props:e},f,{updateId:c+1}))))}T()(this.props.syncId)&&!T()(e.syncId)&&this.addListener(),!T()(this.props.syncId)&&T()(e.syncId)&&this.removeListener()}},{key:"componentWillUnmount",value:function(){T()(this.props.syncId)||this.removeListener(),"function"==typeof this.triggeredAfterMouseMove.cancel&&this.triggeredAfterMouseMove.cancel()}},{key:"getAxisMap",value:function(e,t){var n=t.axisType,r=void 0===n?"xAxis":n,a=t.AxisComp,i=t.graphicalItems,o=t.stackGroups,s=t.dataStartIndex,u=t.dataEndIndex,l=e.children,c="".concat(r,"Id"),d=se(l,a),f={};return d&&d.length?f=this.getAxisMapByAxes(e,{axes:d,graphicalItems:i,axisType:r,axisIdKey:c,stackGroups:o,dataStartIndex:s,dataEndIndex:u}):i&&i.length&&(f=this.getAxisMapByItems(e,{Axis:a,graphicalItems:i,axisType:r,axisIdKey:c,stackGroups:o,dataStartIndex:s,dataEndIndex:u})),f}},{key:"getAxisMapByAxes",value:function(e,t){var n=this,r=t.axes,a=t.graphicalItems,i=t.axisType,o=t.axisIdKey,s=t.stackGroups,u=t.dataStartIndex,l=t.dataEndIndex,c=e.layout,d=e.children,f=e.stackOffset,h=hf(c,i);return r.reduce(function(t,r){var p=r.props,m=p.type,_=p.dataKey,y=p.allowDataOverflow,v=p.allowDuplicatedCategory,g=p.scale,b=p.ticks,M=r.props[o],w=n.constructor.getDisplayedData(e,{graphicalItems:a.filter(function(e){return e.props[o]===M}),dataStartIndex:u,dataEndIndex:l}),x=w.length;if(!t[M]){var L,Y,S;if(_){if(L=uf(w,_,m),"category"===m&&h){var D=function(e){if(!A()(e))return!1;for(var t=e.length,n={},r=0;r=0?e:Oh(e).concat([t])},[]))}else if("category"===m)L=v?L.filter(function(e){return""!==e&&!T()(e)}):Df(r.props.domain,L,r).reduce(function(e,t){return e.indexOf(t)>=0||""===t||T()(t)?e:Oh(e).concat([t])},[]);else if("number"===m){var O=function(e,t,n,r){var a=t.map(function(t){return df(e,t,n,r)}).filter(function(e){return!T()(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}(w,a.filter(function(e){return e.props[o]===M&&!e.props.hide}),_,i);O&&(L=O)}!h||"number"!==m&&"auto"===g||(S=uf(w,_,"category"))}else L=h?k()(0,x):s&&s[M]&&s[M].hasStack&&"number"===m?"expand"===f?[0,1]:xf(s[M].stackGroups,u,l):ff(w,a.filter(function(e){return e.props[o]===M&&!e.props.hide}),m,!0);return"number"===m&&(L=wf(d,L,M,i,b),r.props.domain&&(L=Yf(r.props.domain,L,y))),jh({},t,Eh({},M,jh({},r.props,{axisType:i,domain:L,categoricalDomain:S,duplicateDomain:Y,originalDomain:r.props.domain,isCategorial:h,layout:c})))}return t},{})}},{key:"getAxisMapByItems",value:function(e,t){var n=t.graphicalItems,r=t.Axis,a=t.axisType,i=t.axisIdKey,o=t.stackGroups,s=t.dataStartIndex,u=t.dataEndIndex,l=e.layout,c=e.children,d=this.constructor.getDisplayedData(e,{graphicalItems:n,dataStartIndex:s,dataEndIndex:u}),f=d.length,h=hf(l,a),p=-1;return n.reduce(function(e,t){var m,_=t.props[i];return e[_]?e:(p++,h?m=k()(0,f):o&&o[_]&&o[_].hasStack?(m=xf(o[_].stackGroups,s,u),m=wf(c,m,_,a)):(m=Yf(r.defaultProps.domain,ff(d,n.filter(function(e){return e.props[i]===_&&!e.props.hide}),"number"),r.defaultProps.allowDataOverflow),m=wf(c,m,_,a)),jh({},e,Eh({},_,jh({axisType:a},r.defaultProps,{hide:!0,orientation:Wh[a]&&Wh[a][p%2],domain:m,originalDomain:r.defaultProps.domain,isCategorial:h,layout:l}))))},{})}},{key:"getActiveCoordinate",value:function(e,t,n){var r=this.props.layout,a=e.find(function(e){return e&&e.index===t});if(a){if("horizontal"===r)return{x:a.coordinate,y:n.y};if("vertical"===r)return{x:n.x,y:a.coordinate};if("centric"===r){var i=a.coordinate,o=n.radius;return jh({},n,If(n.cx,n.cy,o,i),{angle:i,radius:o})}var s=a.coordinate,u=n.angle;return jh({},n,If(n.cx,n.cy,s,u),{angle:u,radius:s})}return Fh}},{key:"getMouseInfo",value:function(e){if(!this.container)return null;var t,n,r,a=function(e,t){return{chartX:Math.round(e.pageX-t.left),chartY:Math.round(e.pageY-t.top)}}(e,(t=this.container,n=t.ownerDocument.documentElement,r={top:0,left:0},void 0!==t.getBoundingClientRect&&(r=t.getBoundingClientRect()),{top:r.top+window.pageYOffset-n.clientTop,left:r.left+window.pageXOffset-n.clientLeft})),i=this.inRange(a.chartX,a.chartY);if(!i)return null;var s=this.state,u=s.xAxisMap,l=s.yAxisMap;if("axis"!==o&&u&&l){var c=q(u).scale,d=q(l).scale;return jh({},a,{xValue:c&&c.invert?c.invert(a.chartX):null,yValue:d&&d.invert?d.invert(a.chartY):null})}var f=this.state,h=f.orderedTooltipTicks,p=f.tooltipAxis,m=f.tooltipTicks,_=function(e,t,n,r){var a=-1,i=t.length;if(i>1){if(r&&"angleAxis"===r.axisType&&Math.abs(Math.abs(r.range[1]-r.range[0])-360)<=1e-6)for(var o=r.range,s=0;s0?n[s-1].coordinate:n[i-1].coordinate,l=n[s].coordinate,c=s>=i-1?n[0].coordinate:n[s+1].coordinate,d=void 0;if(F(l-u)!==F(c-l)){var f=[];if(F(c-l)===F(o[1]-o[0])){d=c;var h=l+o[1]-o[0];f[0]=Math.min(h,(h+u)/2),f[1]=Math.max(h,(h+u)/2)}else{d=u;var p=c+o[1]-o[0];f[0]=Math.min(l,(p+l)/2),f[1]=Math.max(l,(p+l)/2)}var m=[Math.min(l,(d+l)/2),Math.max(l,(d+l)/2)];if(e>m[0]&&e<=m[1]||e>=f[0]&&e<=f[1]){a=n[s].index;break}}else{var _=Math.min(u,c),y=Math.max(u,c);if(e>(_+l)/2&&e<=(y+l)/2){a=n[s].index;break}}}else for(var v=0;v0&&v(t[v].coordinate+t[v-1].coordinate)/2&&e<=(t[v].coordinate+t[v+1].coordinate)/2||v===i-1&&e>(t[v].coordinate+t[v-1].coordinate)/2){a=t[v].index;break}}else a=0;return a}(this.calculateTooltipPos(i),h,m,p);if(_>=0&&m){var y=m[_]&&m[_].value;return jh({},a,{activeTooltipIndex:_,activeLabel:y,activePayload:this.getTooltipContent(_,y),activeCoordinate:this.getActiveCoordinate(h,_,i)})}return null}},{key:"getTooltipContent",value:function(e,t){var n=this.state,r=n.graphicalItems,a=n.tooltipAxis,i=this.constructor.getDisplayedData(this.props,this.state);return e<0||!r||!r.length||e>=i.length?null:r.reduce(function(n,r){if(r.props.hide)return n;var o,s=r.props,u=s.dataKey,l=s.name,c=s.unit,d=s.formatter,f=s.data;return(o=a.dataKey&&!a.allowDuplicatedCategory?K(f||i,a.dataKey,t):i[e])?Oh(n).concat([jh({},le(r),{dataKey:u,unit:c,formatter:d,name:l||u,color:lf(r),value:sf(o,u),payload:o})]):n},[])}},{key:"getFormatItems",value:function(e,t){var n=this,r=t.graphicalItems,i=t.stackGroups,o=t.offset,s=t.updateId,l=t.dataStartIndex,c=t.dataEndIndex,d=e.barSize,f=e.layout,h=e.barGap,p=e.barCategoryGap,m=e.maxBarSize,_=this.constructor.getAxisNameByLayout(f),y=_.numericAxisName,v=_.cateAxisName,g=this.constructor.hasBar(r),b=g&&function(e){var t=e.barSize,n=e.stackGroups,r=void 0===n?{}:n;if(!r)return{};for(var a={},i=Object.keys(r),o=0,s=i.length;o=0});if(m&&m.length){var _=m[0].props.barSize,y=m[0].props[p];a[y]||(a[y]=[]),a[y].push({item:m[0],stackList:m.slice(1),barSize:T()(_)?t:_})}}return a}({barSize:d,stackGroups:i}),M=[];return r.forEach(function(r,d){var _,k,w,x,L=n.constructor.getDisplayedData(e,{dataStartIndex:l,dataEndIndex:c},r),Y=r.props,S=Y.dataKey,D=Y.maxBarSize,O=r.props["".concat(y,"Id")],j=r.props["".concat(v,"Id")],E=u.reduce(function(e,n){var a,i=t["".concat(n.axisType,"Map")],o=r.props["".concat(n.axisType,"Id")],s=i&&i[o];return jh({},e,(Eh(a={},n.axisType,s),Eh(a,"".concat(n.axisType,"Ticks"),mf(s)),a))},{}),P=E[v],A=E["".concat(v,"Ticks")],C=i&&i[O]&&i[O].hasStack&&function(e,t){var n=e.props.stackId;if(B(n)){var r=t[n];if(r&&r.items.length){for(var a=-1,i=0,o=r.items.length;i=0?r.stackedData[a]:null}}return null}(r,i[O].stackGroups),H=Sf(P,A),N=T()(D)?m:D,I=g&&function(e){var t=e.barGap,n=e.barCategoryGap,r=e.bandSize,a=e.sizeList,i=void 0===a?[]:a,o=e.maxBarSize,s=i.length;if(s<1)return null;var u,l=J(t,r,0,!0);if(i[0].barSize===+i[0].barSize){var c=!1,d=r/s,f=i.reduce(function(e,t){return e+t.barSize||0},0);(f+=(s-1)*l)>=r&&(f-=(s-1)*l,l=0),f>=r&&d>0&&(c=!0,f=s*(d*=.9));var h={offset:((r-f)/2>>0)-l,size:0};u=i.reduce(function(e,t){var n=rf(e).concat([{item:t.item,position:{offset:h.offset+h.size+l,size:c?d:t.barSize}}]);return h=n[n.length-1].position,t.stackList&&t.stackList.length&&t.stackList.forEach(function(e){n.push({item:e,position:h})}),n},[])}else{var p=J(n,r,0,!0);r-2*p-(s-1)*l<=0&&(l=0);var m=(r-2*p-(s-1)*l)/s;m>1&&(m>>=0);var _=o===+o?Math.min(m,o):m;u=i.reduce(function(e,t,n){var r=rf(e).concat([{item:t.item,position:{offset:p+(m+l)*n+(m-_)/2,size:_}}]);return t.stackList&&t.stackList.length&&t.stackList.forEach(function(e){r.push({item:e,position:r[r.length-1].position})}),r},[])}return u}({barGap:h,barCategoryGap:p,bandSize:H,sizeList:b[j],maxBarSize:N}),R=r&&r.type&&r.type.getComposedData;R&&M.push({props:jh({},R(jh({},E,{displayedData:L,props:e,dataKey:S,item:r,bandSize:H,barPosition:I,offset:o,stackedData:C,layout:f,dataStartIndex:l,dataEndIndex:c,onItemMouseLeave:_f(n.handleItemMouseLeave,null,r.props.onMouseLeave),onItemMouseEnter:_f(n.handleItemMouseEnter,null,r.props.onMouseEnter)})),(_={key:r.key||"item-".concat(d)},Eh(_,y,E[y]),Eh(_,v,E[v]),Eh(_,"animationId",s),_)),childIndex:(k=r,w=e.children,x=-1,a.Children.forEach(w,function(e,t){e===k&&(x=t)}),x),item:r})}),M}},{key:"getCursorRectangle",value:function(){var e=this.props.layout,t=this.state,n=t.activeCoordinate,r=t.offset,a=t.tooltipAxisBandSize,i=a/2;return{stroke:"none",fill:"#ccc",x:"horizontal"===e?n.x-i:r.left+.5,y:"horizontal"===e?r.top+.5:n.y-i,width:"horizontal"===e?a:r.width-1,height:"horizontal"===e?r.height-1:a}}},{key:"getCursorPoints",value:function(){var e,t,n,r,a=this.props.layout,i=this.state,o=i.activeCoordinate,s=i.offset;if("horizontal"===a)n=e=o.x,t=s.top,r=s.top+s.height;else if("vertical"===a)r=t=o.y,e=s.left,n=s.left+s.width;else if(!T()(o.cx)||!T()(o.cy)){if("centric"!==a){var u=o.cx,l=o.cy,c=o.radius,d=o.startAngle,f=o.endAngle;return{points:[If(u,l,c,d),If(u,l,c,f)],cx:u,cy:l,radius:c,startAngle:d,endAngle:f}}var h=o.cx,p=o.cy,m=o.innerRadius,_=o.outerRadius,y=o.angle,v=If(h,p,m,y),g=If(h,p,_,y);e=v.x,t=v.y,n=g.x,r=g.y}return[{x:e,y:t},{x:n,y:r}]}},{key:"calculateTooltipPos",value:function(e){var t=this.props.layout;return"horizontal"===t?e.x:"vertical"===t?e.y:"centric"===t?e.angle:e.radius}},{key:"inRange",value:function(e,t){var n=this.props.layout;if("horizontal"===n||"vertical"===n){var r=this.state.offset;return e>=r.left&&e<=r.left+r.width&&t>=r.top&&t<=r.top+r.height?{x:e,y:t}:null}var a=this.state,i=a.angleAxisMap,o=a.radiusAxisMap;if(i&&o){var s=q(i);return zf({x:e,y:t},s)}return null}},{key:"parseEventsOfWrapper",value:function(){var e=this.props.children,t=ue(e,yn)&&"axis"===o?{onMouseEnter:this.handleMouseEnter,onMouseMove:this.handleMouseMove,onMouseLeave:this.handleMouseLeave,onTouchMove:this.handleTouchMove,onTouchStart:this.handleTouchStart,onTouchEnd:this.handleTouchEnd}:{};return jh({},de(this.props,this.handleOuterEvent),t)}},{key:"updateStateOfAxisMapsOffsetAndStackGroups",value:function(e){var r=this,a=e.props,i=e.dataStartIndex,o=e.dataEndIndex,s=e.updateId;if(!pe({props:a}))return null;var l=a.children,d=a.layout,f=a.stackOffset,h=a.data,p=a.reverseStackOrder,m=this.constructor.getAxisNameByLayout(d),_=m.numericAxisName,y=m.cateAxisName,v=se(l,n),g=function(e,t,n,r,a,i){if(!e)return null;var o=(i?t.reverse():t).reduce(function(e,t){var a=t.props,i=a.stackId;if(a.hide)return e;var o=t.props[n],s=e[o]||{hasStack:!1,stackGroups:{}};if(B(i)){var u=s.stackGroups[i]||{numericAxisId:n,cateAxisId:r,items:[]};u.items.push(t),s.hasStack=!0,s.stackGroups[i]=u}else s.stackGroups[V("_stackId_")]={numericAxisId:n,cateAxisId:r,items:[t]};return af({},e,of({},o,s))},{});return Object.keys(o).reduce(function(t,i){var s=o[i];return s.hasStack&&(s.stackGroups=Object.keys(s.stackGroups).reduce(function(t,i){var o=s.stackGroups[i];return af({},t,of({},i,{numericAxisId:n,cateAxisId:r,items:o.items,stackedData:bf(e,o.items,a)}))},{})),af({},t,of({},i,s))},{})}(h,v,"".concat(_,"Id"),"".concat(y,"Id"),f,p),b=u.reduce(function(e,t){return jh({},e,Eh({},"".concat(t.axisType,"Map"),r.getAxisMap(a,jh({},t,{graphicalItems:v,stackGroups:t.axisType===_&&g,dataStartIndex:i,dataEndIndex:o}))))},{}),M=this.calculateOffset(jh({},b,{props:a,graphicalItems:v}));Object.keys(b).forEach(function(e){b[e]=c(a,b[e],M,e.replace("Map",""),t)});var k=b["".concat(y,"Map")],w=this.tooltipTicksGenerator(k),x=this.getFormatItems(a,jh({},b,{dataStartIndex:i,dataEndIndex:o,updateId:s,graphicalItems:v,stackGroups:g,offset:M}));return jh({formatedGraphicalItems:x,graphicalItems:v,offset:M,stackGroups:g},w,b)}},{key:"addListener",value:function(){Lh.on(Th,this.handleReceiveSyncEvent),Lh.setMaxListeners&&Lh._maxListeners&&Lh.setMaxListeners(Lh._maxListeners+1)}},{key:"removeListener",value:function(){Lh.removeListener(Th,this.handleReceiveSyncEvent),Lh.setMaxListeners&&Lh._maxListeners&&Lh.setMaxListeners(Lh._maxListeners-1)}},{key:"calculateOffset",value:function(e){var t=e.props,n=e.graphicalItems,r=e.xAxisMap,a=void 0===r?{}:r,i=e.yAxisMap,o=void 0===i?{}:i,s=t.width,u=t.height,l=t.children,c=t.margin||{},d=ue(l,wh),f=ue(l,fa),h=Object.keys(o).reduce(function(e,t){var n=o[t],r=n.orientation;return n.mirror||n.hide?e:jh({},e,Eh({},r,e[r]+n.width))},{left:c.left||0,right:c.right||0}),p=Object.keys(a).reduce(function(e,t){var n=a[t],r=n.orientation;return n.mirror||n.hide?e:jh({},e,Eh({},r,e[r]+n.height))},{top:c.top||0,bottom:c.bottom||0}),m=jh({},p,h),_=m.bottom;return d&&(m.bottom+=d.props.height||wh.defaultProps.height),f&&this.legendInstance&&(m=function(e,t,n,r){var a=n.children,i=n.width,o=n.height,s=n.margin,u=i-(s.left||0)-(s.right||0),l=o-(s.top||0)-(s.bottom||0),c=cf({children:a,items:t,legendWidth:u,legendHeight:l}),d=e;if(c){var f=r||{},h=c.align,p=c.verticalAlign,m=c.layout;("vertical"===m||"horizontal"===m&&"center"===p)&&U(e[h])&&(d=af({},e,of({},h,d[h]+(f.width||0)))),("horizontal"===m||"vertical"===m&&"center"===h)&&U(e[p])&&(d=af({},e,of({},p,d[p]+(f.height||0))))}return d}(m,n,t,this.legendInstance.getBBox())),jh({brushBottom:_},m,{width:s-m.left-m.right,height:u-m.top-m.bottom})}},{key:"triggerSyncEvent",value:function(e){var t=this.props.syncId;T()(t)||Lh.emit(Th,t,this.uniqueChartId,e)}},{key:"filterFormatItem",value:function(e,t,n){for(var r=this.state.formatedGraphicalItems,a=0,i=r.length;a=0})},h.getDisplayedData=function(e,t,n){var r=t.graphicalItems,a=t.dataStartIndex,i=t.dataEndIndex,o=(r||[]).reduce(function(e,t){var n=t.props.data;return n&&n.length?Oh(e).concat(Oh(n)):e},[]);if(o&&o.length>0)return o;if(n&&n.props&&n.props.data&&n.props.data.length>0)return n.props.data;var s=e.data;return s&&s.length&&U(a)&&U(i)?s.slice(a,i+1):[]},h};function Uh(e){return(Uh="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})(e)}function Bh(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Gh(){return(Gh=Object.assign||function(e){for(var t=1;t1e-5?"outer"===t?"start":"end":n<-1e-5?"outer"===t?"end":"start":"middle"}},{key:"renderAxisLine",value:function(){var e=this.props,t=e.cx,n=e.cy,r=e.radius,a=e.axisLine,o=e.axisLineType,s=rp({},le(this.props),{fill:"none"},le(a));if("circle"===o)return i.a.createElement(sc,np({className:"recharts-polar-angle-axis-line"},s,{cx:t,cy:n,r:r}));var u=this.props.ticks.map(function(e){return If(t,n,r,e.coordinate)});return i.a.createElement(ep,np({className:"recharts-polar-angle-axis-line"},s,{points:u}))}},{key:"renderTicks",value:function(){var e=this,t=this.props,n=t.ticks,r=t.tick,a=t.tickLine,o=t.tickFormatter,s=t.stroke,u=le(this.props),l=le(r),c=rp({},u,{fill:"none"},le(a)),d=n.map(function(t,n){var d=e.getTickLineCoord(t),f=rp({textAnchor:e.getTickTextAnchor(t)},u,{stroke:"none",fill:s},l,{index:n,payload:t,x:d.x2,y:d.y2});return i.a.createElement(Oe,np({className:"recharts-polar-angle-axis-tick",key:"tick-".concat(n)},he(e.props,t,n)),a&&i.a.createElement("line",np({className:"recharts-polar-angle-axis-tick-line"},c,d)),r&&e.constructor.renderTickItem(r,f,o?o(t.value):t.value))});return i.a.createElement(Oe,{className:"recharts-polar-angle-axis-ticks"},d)}},{key:"render",value:function(){var e=this.props,t=e.ticks,n=e.radius,r=e.axisLine;return n<=0||!t||!t.length?null:i.a.createElement(Oe,{className:"recharts-polar-angle-axis"},r&&this.renderAxisLine(),this.renderTicks())}}])&&ip(n.prototype,r),o&&ip(n,o),t}(),Xh.displayName="PolarAngleAxis",Xh.axisType="angleAxis",Xh.propTypes=rp({},ne,re,{type:s.a.oneOf(["number","category"]),angleAxisId:s.a.oneOfType([s.a.string,s.a.number]),dataKey:s.a.oneOfType([s.a.number,s.a.string,s.a.func]),cx:s.a.number,cy:s.a.number,radius:s.a.oneOfType([s.a.number,s.a.string]),hide:s.a.bool,scale:s.a.oneOfType([s.a.oneOf(["auto","linear","pow","sqrt","log","identity","time","band","point","ordinal","quantile","quantize","utc","sequential","threshold"]),s.a.func]),axisLine:s.a.oneOfType([s.a.bool,s.a.object]),axisLineType:s.a.oneOf(["polygon","circle"]),tickLine:s.a.oneOfType([s.a.bool,s.a.object]),tick:s.a.oneOfType([s.a.bool,s.a.func,s.a.object,s.a.element]),ticks:s.a.arrayOf(s.a.shape({value:s.a.any,coordinate:s.a.number})),stroke:s.a.string,orientation:s.a.oneOf(["inner","outer"]),tickFormatter:s.a.func,allowDuplicatedCategory:s.a.bool}),Xh.defaultProps={type:"category",angleAxisId:0,scale:"auto",cx:0,cy:0,domain:[0,"auto"],orientation:"outer",axisLine:!0,tickLine:!0,tick:!0,hide:!1,allowDuplicatedCategory:!0},Kh=Qh))||Kh,pp=n(304),mp=n.n(pp),_p=n(305),yp=n.n(_p);function vp(e){return(vp="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})(e)}function gp(){return(gp=Object.assign||function(e){for(var t=1;t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}function wp(e,t){for(var n=0;n=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var Cp={id:s.a.string,data:s.a.arrayOf(s.a.object),valueAccessor:s.a.func,clockWise:s.a.bool,dataKey:s.a.oneOfType([s.a.string,s.a.number,s.a.func])},Hp={valueAccessor:function(e){return A()(e.value)?Dp()(e.value):e.value}};function Np(e){var t=e.data,n=e.valueAccessor,r=e.dataKey,a=e.clockWise,o=e.id,s=Ap(e,["data","valueAccessor","dataKey","clockWise","id"]);return t&&t.length?i.a.createElement(Oe,{className:"recharts-label-list"},t.map(function(e,t){var u=T()(r)?n(e,t):sf(e&&e.payload,r),l=T()(o)?{}:{id:"".concat(o,"-").concat(t)};return i.a.createElement(Fc,jp({},le(e),s,l,{index:t,value:u,viewBox:Fc.parseViewBox(T()(a)?e:Ep({},e,{clockWise:a})),key:"label-".concat(t)}))})):null}Np.propTypes=Cp,Np.displayName="LabelList";Np.renderCallByParent=function(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];if(!e||!e.children&&n&&!e.label)return null;var r=e.children,o=se(r,Np).map(function(e,n){return Object(a.cloneElement)(e,{data:t,key:"labelList-".concat(n)})});return n?[function(e,t){return e?!0===e?i.a.createElement(Np,{key:"labelList-implicit",data:t}):i.a.isValidElement(e)||b()(e)?i.a.createElement(Np,{key:"labelList-implicit",data:t,content:e}):E()(e)?i.a.createElement(Np,jp({data:t},e,{key:"labelList-implicit"})):null:null}(e.label,t)].concat(Op(o)):o},Np.defaultProps=Hp;var Ip=Np;function Rp(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Wp(){return null}Wp.propTypes=function(e){for(var t=1;tt?"start":e0?e.paddingAngle:0;if(n){var s=$(n.endAngle-n.startAngle,e.endAngle-e.startAngle),u=Jp({},e,{startAngle:o+i,endAngle:o+s(r)+i});a.push(u),o=u.endAngle}else{var c=e.endAngle,d=e.startAngle,f=$(0,c-d)(r),h=Jp({},e,{startAngle:o+i,endAngle:o+f+i});a.push(h),o=h.endAngle}}),i.a.createElement(Oe,null,e.renderSectorsStatically(a))})}},{key:"renderSectors",value:function(){var e=this.props,t=e.sectors,n=e.isAnimationActive,r=this.state.prevSectors;return!(n&&t&&t.length)||r&&Ee()(r,t)?this.renderSectorsStatically(t):this.renderSectorsWithAnimation()}},{key:"render",value:function(){var e=this.props,t=e.hide,n=e.sectors,r=e.className,a=e.label,o=e.cx,s=e.cy,u=e.innerRadius,l=e.outerRadius,c=e.isAnimationActive,d=e.prevSectors,f=e.id;if(t||!n||!n.length||!U(o)||!U(s)||!U(u)||!U(l))return null;var h=S()("recharts-pie",r);return i.a.createElement(Oe,{className:h},i.a.createElement("g",{clipPath:"url(#".concat(T()(f)?this.id:f,")")},this.renderSectors()),a&&this.renderLabels(n),Fc.renderCallByParent(this.props,null,!1),(!c||d&&Ee()(d,n))&&Ip.renderCallByParent(this.props,n,!1))}}])&&$p(n.prototype,r),o&&$p(n,o),t}(),zp.displayName="Pie",zp.propTypes=Jp({},ne,re,{className:s.a.string,animationId:s.a.number,cx:s.a.oneOfType([s.a.number,s.a.string]),cy:s.a.oneOfType([s.a.number,s.a.string]),startAngle:s.a.number,endAngle:s.a.number,paddingAngle:s.a.number,innerRadius:s.a.oneOfType([s.a.number,s.a.string]),outerRadius:s.a.oneOfType([s.a.number,s.a.string]),cornerRadius:s.a.oneOfType([s.a.number,s.a.string]),dataKey:s.a.oneOfType([s.a.string,s.a.number,s.a.func]).isRequired,nameKey:s.a.oneOfType([s.a.string,s.a.number,s.a.func]),valueKey:s.a.oneOfType([s.a.string,s.a.number,s.a.func]),data:s.a.arrayOf(s.a.object),blendStroke:s.a.bool,minAngle:s.a.number,legendType:s.a.oneOf(ie),maxRadius:s.a.number,sectors:s.a.arrayOf(s.a.object),hide:s.a.bool,labelLine:s.a.oneOfType([s.a.object,s.a.func,s.a.element,s.a.bool]),label:s.a.oneOfType([s.a.shape({offsetRadius:s.a.number}),s.a.func,s.a.element,s.a.bool]),activeShape:s.a.oneOfType([s.a.object,s.a.func,s.a.element]),activeIndex:s.a.oneOfType([s.a.number,s.a.arrayOf(s.a.number)]),isAnimationActive:s.a.bool,animationBegin:s.a.number,animationDuration:s.a.number,animationEasing:s.a.oneOf(["ease","ease-in","ease-out","ease-in-out","spring","linear"]),id:s.a.string}),zp.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:!me(),animationBegin:400,animationDuration:1500,animationEasing:"ease",nameKey:"name",blendStroke:!1},zp.parseDeltaAngle=function(e){var t=e.startAngle,n=e.endAngle;return F(n-t)*Math.min(Math.abs(n-t),360)},zp.getRealPieData=function(e){var t=e.props,n=t.data,r=t.children,a=le(e.props),i=se(r,Bp);return n&&n.length?n.map(function(e,t){return Jp({payload:e},a,e,i&&i[t]&&i[t].props)}):i&&i.length?i.map(function(e){return Jp({},a,e.props)}):[]},zp.parseCoordinateOfPie=function(e,t){var n=t.top,r=t.left,a=t.width,i=t.height,o=Rf(a,i);return{cx:r+J(e.props.cx,a,a/2),cy:n+J(e.props.cy,i,i/2),innerRadius:J(e.props.innerRadius,o,0),outerRadius:J(e.props.outerRadius,o,.8*o),maxRadius:e.props.maxRadius||Math.sqrt(a*a+i*i)/2}},zp.getComposedData=function(e){var t=e.item,n=e.offset,r=e.onItemMouseLeave,a=e.onItemMouseEnter,i=Zp.getRealPieData(t);if(!i||!i.length)return[];var o=t.props,s=o.cornerRadius,u=o.startAngle,l=o.endAngle,c=o.paddingAngle,d=o.dataKey,f=o.nameKey,h=o.valueKey,p=Math.abs(t.props.minAngle),m=Zp.parseCoordinateOfPie(t,n),_=i.length,y=Zp.parseDeltaAngle({startAngle:u,endAngle:l}),v=Math.abs(y),g=v-_*p-(v>=360?_:_-1)*c,b=d;T()(d)&&T()(h)?b="value":T()(d)&&(b=h);var M,k,w=i.reduce(function(e,t){var n=sf(t,b,0);return e+(U(n)?n:0)},0);w>0&&(M=i.map(function(e,t){var n,r=sf(e,b,0),a=sf(e,f,t),i=(U(r)?r:0)/w,o=(n=t?k.endAngle+F(y)*c:u)+F(y)*(p+i*g),l=(n+o)/2,d=(m.innerRadius+m.outerRadius)/2,h=[{name:a,value:r,payload:e}],_=If(m.cx,m.cy,d,l);return k=Jp({percent:i,cornerRadius:s,name:a,tooltipPayload:h,midAngle:l,middleRadius:d,tooltipPosition:_},e,m,{value:sf(e,b),startAngle:n,endAngle:o,payload:e,paddingAngle:F(y)*c})}));return Jp({},m,{sectors:M,data:i,onMouseLeave:r,onMouseEnter:a})},Fp=Up))||Fp,em=Zp,tm=zh({chartName:"PieChart",GraphicalChild:em,eventType:"item",legendContent:"children",axisComponents:[{axisType:"angleAxis",AxisComp:hp},{axisType:"radiusAxis",AxisComp:Yp}],formatAxisMap:function(e,t,n,r,a){var i=e.width,o=e.height,s=e.startAngle,u=e.endAngle,l=J(e.cx,i,i/2),c=J(e.cy,o,o/2),d=Rf(i,o,n),f=J(e.innerRadius,d,0),h=J(e.outerRadius,d,.8*d);return Object.keys(t).reduce(function(e,n){var i,o=t[n],d=o.domain,p=o.reversed;if(T()(o.range))"angleAxis"===r?i=[s,u]:"radiusAxis"===r&&(i=[f,h]),p&&(i=[i[1],i[0]]);else{var m=Ef(i=o.range,2);s=m[0],u=m[1]}var _=yf(o,a),y=_.realScaleType,v=_.scale;v.domain(d).range(i),vf(v);var g=Mf(v,Of({},o,{realScaleType:y})),b=Of({},o,g,{range:i,radius:h,realScaleType:y,scale:v,cx:l,cy:c,innerRadius:f,outerRadius:h,startAngle:s,endAngle:u});return Of({},e,jf({},n,b))},{})},defaultProps:{layout:"centric",startAngle:0,endAngle:360,cx:"50%",cy:"50%",innerRadius:0,outerRadius:"80%"},propTypes:{layout:s.a.oneOf(["centric"]),startAngle:s.a.number,endAngle:s.a.number,cx:s.a.oneOfType([s.a.number,s.a.string]),cy:s.a.oneOfType([s.a.number,s.a.string]),innerRadius:s.a.oneOfType([s.a.number,s.a.string]),outerRadius:s.a.oneOfType([s.a.number,s.a.string])}}),nm=n(35);function rm(e,t,n,r,a){if(e>=t)return Promise.resolve({patternGraphData:[],calendarGraphData:[]});var i=[],o=function(o){if(!r[o].enabled)return"continue";var s=n.filter(function(e){return e.cal.regex.test(r[o].name)});s.length>0&&i.push(a(o,e,t).then(function(e){return{id:o,events:e,filtered:s}}))};for(var s in r)o(s);return Promise.all(i).then(function(a){var i={},o={},s={},u={};a.forEach(function(e){i[e.id]=e.events,o[e.id]=e.filtered});for(var l=0;lt+2&&(l=5,u="start"),an+2&&(c=10),i.a.createElement("text",{x:r,y:a,dx:l,dy:c,fill:o,textAnchor:u},"".concat(s))}var om=Object(u.withStyles)(am)(function(e){return i.a.createElement(c.a,{item:!0,xs:12,lg:6},i.a.createElement("div",{className:e.classes.patternTableWrapper},i.a.createElement(tm,{width:400,height:250,className:e.classes.pieChart},i.a.createElement(em,{data:e.data,dataKey:"value",cx:200,cy:125,outerRadius:60,fill:nm.a,isAnimationActive:!1,label:im},e.data.map(function(e,t){return i.a.createElement(Bp,{key:t,fill:e.color?e.color:nm.a})})),i.a.createElement(yn,{formatter:function(e){return"".concat(e.toFixed(2)," hr")}}))))});function sm(e){return i.a.createElement(c.a,{container:!0,spacing:0},i.a.createElement(om,{data:e.patternGraphData}),i.a.createElement(c.a,{item:!0,xs:12,lg:6},i.a.createElement("div",{className:e.classes.patternTableWrapper},i.a.createElement(tm,{width:400,height:250,className:e.classes.pieChart},i.a.createElement(em,{data:e.calendarGraphData,dataKey:"value",cx:200,cy:125,innerRadius:40,outerRadius:70,fill:f.a[300],isAnimationActive:!1,label:im},e.calendarGraphData.map(function(e,t){return i.a.createElement(Bp,{key:t,fill:e.color?e.color:f.a[300]})})),i.a.createElement(yn,{formatter:function(e){return"".concat(e.toFixed(2)," hr")}})))))}sm.propTypes={patternGraphData:s.a.array.isRequired,calendarGraphData:s.a.array.isRequired};var um=Object(u.withStyles)(am)(sm)},function(e,t,n){"use strict"; +!function(){"use strict";var n={}.hasOwnProperty;function a(){for(var e=[],t=0;t=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}},function(e,t){e.exports=function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}},function(e,t){e.exports=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}},function(e,t){function n(e,t){for(var n=0;n1&&void 0!==arguments[1]?arguments[1]:{};return function(n){var r,m=t.withTheme,_=void 0!==m&&m,v=t.flip,M=void 0===v?null:v,w=t.name,E=(0,d.default)(t,["withTheme","flip","name"]),P=(0,x.default)(e),A=P.themingEnabled||"string"==typeof w||_;S+=1,P.options.index=S;var C=function(e){function t(e,n){var r;(0,o.default)(this,t),(r=(0,u.default)(this,(0,l.default)(t).call(this,e,n))).jss=n[y.default.jss]||T,r.sheetsManager=D,r.unsubscribeId=null;var a=n.muiThemeProviderOptions;return a&&(a.sheetsManager&&(r.sheetsManager=a.sheetsManager),r.sheetsCache=a.sheetsCache,r.disableStylesGeneration=a.disableStylesGeneration),r.stylesCreatorSaved=P,r.sheetOptions=(0,i.default)({generateClassName:Y},n[y.default.sheetOptions]),r.theme=A?k.default.initial(n)||j:O,r.attach(r.theme),r.cacheClasses={value:null,lastProp:null,lastJSS:{}},r}return(0,c.default)(t,e),(0,s.default)(t,[{key:"componentDidMount",value:function(){var e=this;A&&(this.unsubscribeId=k.default.subscribe(this.context,function(t){var n=e.theme;e.theme=t,e.attach(e.theme),e.setState({},function(){e.detach(n)})}))}},{key:"componentDidUpdate",value:function(){this.stylesCreatorSaved}},{key:"componentWillUnmount",value:function(){this.detach(this.theme),null!==this.unsubscribeId&&k.default.unsubscribe(this.context,this.unsubscribeId)}},{key:"getClasses",value:function(){if(this.disableStylesGeneration)return this.props.classes||{};var e=!1,t=b.default.get(this.sheetsManager,this.stylesCreatorSaved,this.theme);return t.sheet.classes!==this.cacheClasses.lastJSS&&(this.cacheClasses.lastJSS=t.sheet.classes,e=!0),this.props.classes!==this.cacheClasses.lastProp&&(this.cacheClasses.lastProp=this.props.classes,e=!0),e&&(this.cacheClasses.value=(0,g.default)({baseClasses:this.cacheClasses.lastJSS,newClasses:this.props.classes,Component:n})),this.cacheClasses.value}},{key:"attach",value:function(e){if(!this.disableStylesGeneration){var t=this.stylesCreatorSaved,n=b.default.get(this.sheetsManager,t,e);if(n||(n={refs:0,sheet:null},b.default.set(this.sheetsManager,t,e,n)),0===n.refs){var r;this.sheetsCache&&(r=b.default.get(this.sheetsCache,t,e)),r||((r=this.createSheet(e)).attach(),this.sheetsCache&&b.default.set(this.sheetsCache,t,e,r)),n.sheet=r;var a=this.context[y.default.sheetsRegistry];a&&a.add(r)}n.refs+=1}}},{key:"createSheet",value:function(e){var t=this.stylesCreatorSaved.create(e,w),r=w;return this.jss.createStyleSheet(t,(0,i.default)({meta:r,classNamePrefix:r,flip:"boolean"==typeof M?M:"rtl"===e.direction,link:!1},this.sheetOptions,this.stylesCreatorSaved.options,{name:w||n.displayName},E))}},{key:"detach",value:function(e){if(!this.disableStylesGeneration){var t=b.default.get(this.sheetsManager,this.stylesCreatorSaved,e);if(t.refs-=1,0===t.refs){b.default.delete(this.sheetsManager,this.stylesCreatorSaved,e),this.jss.removeStyleSheet(t.sheet);var n=this.context[y.default.sheetsRegistry];n&&n.remove(t.sheet)}}}},{key:"render",value:function(){var e=this.props,t=(e.classes,e.innerRef),r=(0,d.default)(e,["classes","innerRef"]),a=(0,L.default)({theme:this.theme,name:w,props:r});return _&&!a.theme&&(a.theme=this.theme),f.default.createElement(n,(0,i.default)({},a,{classes:this.getClasses(),ref:t}))}}]),t}(f.default.Component);return C.contextTypes=(0,i.default)((r={muiThemeProviderOptions:h.default.object},(0,a.default)(r,y.default.jss,h.default.object),(0,a.default)(r,y.default.sheetOptions,h.default.object),(0,a.default)(r,y.default.sheetsRegistry,h.default.object),r),A?k.default.contextTypes:{}),(0,p.default)(C,n),C}});t.default=function(e,t){return m.ponyfillGlobal.__MUI_STYLES__.withStyles(e,(0,i.default)({defaultTheme:j},t))}},function(e,t,n){var r=n(55),a=n(11);e.exports=function(e,t){return!t||"object"!==r(t)&&"function"!=typeof t?a(e):t}},function(e,t){function n(t){return e.exports=n=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},n(t)}e.exports=n},function(e,t,n){var r=n(343);e.exports=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}}),t&&r(e,t)}},function(e,t,n){"use strict";var r=function(){};e.exports=r},function(e,t){e.exports=function(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}},function(e,t,n){"use strict";var r=n(3);Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"createGenerateClassName",{enumerable:!0,get:function(){return a.default}}),Object.defineProperty(t,"createMuiTheme",{enumerable:!0,get:function(){return i.default}}),Object.defineProperty(t,"jssPreset",{enumerable:!0,get:function(){return o.default}}),Object.defineProperty(t,"MuiThemeProvider",{enumerable:!0,get:function(){return s.default}}),Object.defineProperty(t,"createStyles",{enumerable:!0,get:function(){return u.default}}),Object.defineProperty(t,"withStyles",{enumerable:!0,get:function(){return l.default}}),Object.defineProperty(t,"withTheme",{enumerable:!0,get:function(){return c.default}});var a=r(n(118)),i=r(n(87)),o=r(n(126)),s=r(n(394)),u=r(n(397)),l=r(n(15)),c=r(n(113))},,function(e,t,n){var r=n(261),a="object"==typeof self&&self&&self.Object===Object&&self,i=r||a||Function("return this")();e.exports=i},function(e,t,n){var r=n(432),a=n(478),i=n(43),o=n(8),s=n(487);e.exports=function(e){return"function"==typeof e?e:null==e?i:"object"==typeof e?o(e)?a(e[0],e[1]):r(e):s(e)}},function(e,t,n){"use strict";!function e(){if("undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE)try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(e){console.error(e)}}(),e.exports=n(340)},function(e,t,n){var r=n(100);e.exports=function(e,t){return r(e,t)}},function(e,t,n){"use strict";n.d(t,"c",function(){return y}),n.d(t,"a",function(){return g}),n.d(t,"b",function(){return b});var r=n(12),a=n.n(r),i=n(13),o=n.n(i),s=n(7),u=n.n(s),l="updatePatterns",c="getPatterns",d="updateCalendars",f="getCalendars",h="getCalEvents",p="updateConfig",m="getConfig",_="getGraphData",y=Object.freeze({updatePatterns:Symbol(l),getPatterns:Symbol(c),updateCalendars:Symbol(d),getCalendars:Symbol(f),getCalEvents:Symbol(h),updateConfig:Symbol(p),getConfig:Symbol(m),getGraphData:Symbol(_)});function v(e){switch(e){case y.updatePatterns:return l;case y.getPatterns:return c;case y.updateCalendars:return d;case y.getCalendars:return f;case y.getCalEvents:return h;case y.updateConfig:return p;case y.getConfig:return m;case y.getGraphData:return _;default:console.error("unreachable")}}var g=function(){function e(t,n,r){a()(this,e),this.id=t,this.type=n,this.data=r}return o()(e,[{key:"genResp",value:function(t){return new e(this.id,this.type,t)}},{key:"deflate",value:function(){return{id:this.id,type:v(this.type),data:this.data}}}]),e}();u()(g,"inflate",function(e){return new g(e.id,function(e){switch(e){case l:return y.updatePatterns;case c:return y.getPatterns;case d:return y.updateCalendars;case f:return y.getCalendars;case h:return y.getCalEvents;case p:return y.updateConfig;case m:return y.getConfig;case _:return y.getGraphData;default:console.error("unreachable")}}(e.type),e.data)});var b=function e(t){var n=this;a()(this,e),u()(this,"sendMsg",function(e){var t,r,a=e.type,i=e.data,o=n.requestCallback,s=new Promise(function(e){t=e});return r=o.ids.length>0?o.ids.pop():o.maxId++,o.inFlight[r]=t,n.port.postMessage(new g(r,a,i).deflate()),s});var r=chrome.runtime.connect({name:t});r.onMessage.addListener(function(e){console.log(e);var t=(e.type,n.requestCallback),r=t.inFlight[e.id];console.assert(void 0!==r),t.ids.push(e.id),r(e)}),this.port=r,this.requestCallback={inFlight:{},ids:[],maxId:0}}},function(e,t){e.exports=function(e){return null!=e&&"object"==typeof e}},function(e,t,n){var r=n(30),a=n(8),i=n(28),o="[object String]";e.exports=function(e){return"string"==typeof e||!a(e)&&i(e)&&r(e)==o}},function(e,t,n){var r=n(53),a=n(413),i=n(414),o="[object Null]",s="[object Undefined]",u=r?r.toStringTag:void 0;e.exports=function(e){return null==e?void 0===e?s:o:u&&u in Object(e)?a(e):i(e)}},function(e,t,n){(function(t){for(var r=n(519),a="undefined"==typeof window?t:window,i=["moz","webkit"],o="AnimationFrame",s=a["request"+o],u=a["cancel"+o]||a["cancelRequest"+o],l=0;!s&&l1&&void 0!==arguments[1]&&arguments[1];if(!Array.isArray(e))return e;var n="";if(Array.isArray(e[0]))for(var a=0;a0&&void 0!==arguments[0]?arguments[0]:"unnamed",t=arguments[1],n=arguments[2],o=n.jss,s=(0,i.default)(t),u=o.plugins.onCreateRule(e,s,n);if(u)return u;"@"===e[0]&&(0,r.default)(!1,"[JSS] Unknown at-rule %s",e);return new a.default(e,s,n)};var r=o(n(39)),a=o(n(40)),i=o(n(365));function o(e){return e&&e.__esModule?e:{default:e}}},function(e,t,n){"use strict";n.r(t),n.d(t,"isBrowser",function(){return a});var r="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},a="object"===("undefined"==typeof window?"undefined":r(window))&&"object"===("undefined"==typeof document?"undefined":r(document))&&9===document.nodeType;t.default=a},function(e,t,n){var r=n(263),a=n(431)(r);e.exports=a},function(e,t,n){var r=n(422),a=n(428),i=n(42);e.exports=function(e){return i(e)?r(e):a(e)}},function(e,t,n){var r=n(434),a=n(435),i=n(436),o=n(437),s=n(438);function u(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t1&&o(e,t[0],t[1])?t=[]:n>2&&o(t[0],t[1],t[2])&&(t=[t[0]]),a(e,r(t,1),[])});e.exports=s},function(e,t,n){"use strict";var r=s(n(530)),a=s(n(534)),i=s(n(107)),o=s(n(80));function s(e){return e&&e.__esModule?e:{default:e}}e.exports={Transition:o.default,TransitionGroup:i.default,ReplaceTransition:a.default,CSSTransition:r.default}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r={50:"#fff3e0",100:"#ffe0b2",200:"#ffcc80",300:"#ffb74d",400:"#ffa726",500:"#ff9800",600:"#fb8c00",700:"#f57c00",800:"#ef6c00",900:"#e65100",A100:"#ffd180",A200:"#ffab40",A400:"#ff9100",A700:"#ff6d00"};t.default=r},function(e,t,n){var r,a=n(511),i=n(512),o=n(514),s=100,u=/(\+|\-|\*|\\|[^a-z]|)(\s*)(\()/g;e.exports=function(e,t){function n(e,i,l){if(r++>s)throw r=0,new Error("Call stack overflow for "+l);if(""===e)throw new Error(i+"(): '"+l+"' must contain a non-whitespace string");var c=function(e){var t=[],n=[],r=/[\.0-9]([%a-z]+)/gi,a=r.exec(e);for(;a;)a&&a[1]&&(-1===n.indexOf(a[1].toLowerCase())&&(t.push(a[1]),n.push(a[1].toLowerCase())),a=r.exec(e));return t}(e=function(e,t){e=e.replace(/((?:\-[a-z]+\-)?calc)/g,"");var r,i="",o=e;for(;r=u.exec(o);){r[0].index>0&&(i+=o.substring(0,r[0].index));var s=a("(",")",o.substring([0].index));if(""===s.body)throw new Error("'"+e+"' must contain a non-whitespace string");var l=n(s.body,"",t);i+=s.pre+l,o=s.post}return i+o}(e,l));if(c.length>1||e.indexOf("var(")>-1)return i+"("+e+")";var d=c[0]||"";"%"===d&&(e=e.replace(/\b[0-9\.]+%/g,function(e){return.01*parseFloat(e.slice(0,-1))}));var f,h=e.replace(new RegExp(d,"gi"),"");try{f=o.eval(h)}catch(t){return i+"("+e+")"}return"%"===d&&(f*=100),(i.length||"%"===d)&&(f=Math.round(f*t)/t),f+=d}return r=0,t=Math.pow(10,void 0===t?5:t),e=e.replace(/\n+/g," "),i(e,/((?:\-[a-z]+\-)?calc)\(/,n)}},,,function(e,t,n){"use strict";t.__esModule=!0,t.default=t.EXITING=t.ENTERED=t.ENTERING=t.EXITED=t.UNMOUNTED=void 0;var r=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){var r=Object.defineProperty&&Object.getOwnPropertyDescriptor?Object.getOwnPropertyDescriptor(e,n):{};r.get||r.set?Object.defineProperty(t,n,r):t[n]=e[n]}return t.default=e,t}(n(0)),a=s(n(1)),i=s(n(25)),o=n(289);n(290);function s(e){return e&&e.__esModule?e:{default:e}}var u="unmounted";t.UNMOUNTED=u;var l="exited";t.EXITED=l;var c="entering";t.ENTERING=c;var d="entered";t.ENTERED=d;t.EXITING="exiting";var f=function(e){var t,n;function r(t,n){var r;r=e.call(this,t,n)||this;var a,i=n.transitionGroup,o=i&&!i.isMounting?t.enter:t.appear;return r.appearStatus=null,t.in?o?(a=l,r.appearStatus=c):a=d:a=t.unmountOnExit||t.mountOnEnter?u:l,r.state={status:a},r.nextCallback=null,r}n=e,(t=r).prototype=Object.create(n.prototype),t.prototype.constructor=t,t.__proto__=n;var o=r.prototype;return o.getChildContext=function(){return{transitionGroup:null}},r.getDerivedStateFromProps=function(e,t){return e.in&&t.status===u?{status:l}:null},o.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},o.componentDidUpdate=function(e){var t=null;if(e!==this.props){var n=this.state.status;this.props.in?n!==c&&n!==d&&(t=c):n!==c&&n!==d||(t="exiting")}this.updateStatus(!1,t)},o.componentWillUnmount=function(){this.cancelNextCallback()},o.getTimeouts=function(){var e,t,n,r=this.props.timeout;return e=t=n=r,null!=r&&"number"!=typeof r&&(e=r.exit,t=r.enter,n=r.appear),{exit:e,enter:t,appear:n}},o.updateStatus=function(e,t){if(void 0===e&&(e=!1),null!==t){this.cancelNextCallback();var n=i.default.findDOMNode(this);t===c?this.performEnter(n,e):this.performExit(n)}else this.props.unmountOnExit&&this.state.status===l&&this.setState({status:u})},o.performEnter=function(e,t){var n=this,r=this.props.enter,a=this.context.transitionGroup?this.context.transitionGroup.isMounting:t,i=this.getTimeouts();t||r?(this.props.onEnter(e,a),this.safeSetState({status:c},function(){n.props.onEntering(e,a),n.onTransitionEnd(e,i.enter,function(){n.safeSetState({status:d},function(){n.props.onEntered(e,a)})})})):this.safeSetState({status:d},function(){n.props.onEntered(e)})},o.performExit=function(e){var t=this,n=this.props.exit,r=this.getTimeouts();n?(this.props.onExit(e),this.safeSetState({status:"exiting"},function(){t.props.onExiting(e),t.onTransitionEnd(e,r.exit,function(){t.safeSetState({status:l},function(){t.props.onExited(e)})})})):this.safeSetState({status:l},function(){t.props.onExited(e)})},o.cancelNextCallback=function(){null!==this.nextCallback&&(this.nextCallback.cancel(),this.nextCallback=null)},o.safeSetState=function(e,t){t=this.setNextCallback(t),this.setState(e,t)},o.setNextCallback=function(e){var t=this,n=!0;return this.nextCallback=function(r){n&&(n=!1,t.nextCallback=null,e(r))},this.nextCallback.cancel=function(){n=!1},this.nextCallback},o.onTransitionEnd=function(e,t,n){this.setNextCallback(n),e?(this.props.addEndListener&&this.props.addEndListener(e,this.nextCallback),null!=t&&setTimeout(this.nextCallback,t)):setTimeout(this.nextCallback,0)},o.render=function(){var e=this.state.status;if(e===u)return null;var t=this.props,n=t.children,r=function(e,t){if(null==e)return{};var n,r,a={},i=Object.keys(e);for(r=0;r=0||(a[n]=e[n]);return a}(t,["children"]);if(delete r.in,delete r.mountOnEnter,delete r.unmountOnExit,delete r.appear,delete r.enter,delete r.exit,delete r.timeout,delete r.addEndListener,delete r.onEnter,delete r.onEntering,delete r.onEntered,delete r.onExit,delete r.onExiting,delete r.onExited,"function"==typeof n)return n(e,r);var i=a.default.Children.only(n);return a.default.cloneElement(i,r)},r}(a.default.Component);function h(){}f.contextTypes={transitionGroup:r.object},f.childContextTypes={transitionGroup:function(){}},f.propTypes={},f.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:h,onEntering:h,onEntered:h,onExit:h,onExiting:h,onExited:h},f.UNMOUNTED=0,f.EXITED=1,f.ENTERING=2,f.ENTERED=3,f.EXITING=4;var p=(0,o.polyfill)(f);t.default=p},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r={50:"#e0f7fa",100:"#b2ebf2",200:"#80deea",300:"#4dd0e1",400:"#26c6da",500:"#00bcd4",600:"#00acc1",700:"#0097a7",800:"#00838f",900:"#006064",A100:"#84ffff",A200:"#18ffff",A400:"#00e5ff",A700:"#00b8d4"};t.default=r},,function(e,t,n){"use strict";n.d(t,"e",function(){return v}),n.d(t,"b",function(){return g}),n.d(t,"f",function(){return b}),n.d(t,"g",function(){return M}),n.d(t,"c",function(){return k}),n.d(t,"d",function(){return w}),n.d(t,"a",function(){return L});var r=n(12),a=n.n(r),i=n(13),o=n.n(i),s=n(49),u=n.n(s),l=n(105),c=n.n(l),d=n(543),f=n.n(d),h="https://www.googleapis.com/calendar/v3",p=Object.freeze({invalidSyncToken:Symbol("invalidSyncToken"),notLoggedIn:Symbol("notLoggedIn"),notLoggedOut:Symbol("notLoggedOut"),otherError:Symbol("otherError")});function m(e){return Object.entries(e).filter(function(e){var t=c()(e,2);t[0];return t[1]}).map(function(e){var t=c()(e,2),n=t[0],r=t[1];return"".concat(encodeURIComponent(n),"=").concat(encodeURIComponent(r))}).join("&")}var _=null;function y(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];return new Promise(function(t){return chrome.identity.getAuthToken({interactive:e},function(e){return t([e,!chrome.runtime.lastError])})}).then(function(e){var t=c()(e,2),n=t[0];if(t[1])return n;throw p.notLoggedIn})}function v(){return null===_?y(!1).then(function(){return _=!0}).catch(function(){return _=!1}).then(function(){return _}):Promise.resolve(_)}function g(){return v().then(function(e){if(e)return y(!1);throw p.notLoggedIn})}function b(){return v().then(function(e){if(e)throw p.notLoggedOut;return y(!0).then(function(){return _=!0})})}function M(){return g().then(function(e){return fetch("https://accounts.google.com/o/oauth2/revoke?".concat(m({token:e})),{method:"GET",async:!0}).then(function(t){return function(e){return new Promise(function(t){return chrome.identity.removeCachedAuthToken({token:e},function(){return t()})})}(e)})}).then(function(){return _=!1})}function k(e){return fetch("".concat(h,"/users/me/calendarList?").concat(m({access_token:e})),{method:"GET",async:!0}).then(function(e){return e.json()}).then(function(e){return e.items})}function w(e){return fetch("".concat(h,"/colors?").concat(m({access_token:e})),{method:"GET",async:!0}).then(function(e){return e.json()})}function x(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null,i=arguments.length>5&&void 0!==arguments[5]?arguments[5]:100,o=[];return function n(s,l){return fetch("".concat(h,"/calendars/").concat(e,"/events?").concat(m({access_token:t,pageToken:s,syncToken:l,timeMin:r,timeMax:a,maxResults:i})),{method:"GET",async:!0}).then(function(e){if(200===e.status)return e.json();throw 410===e.status?p.invalidSyncToken:p.otherError}).then(function(e){return o.push.apply(o,u()(e.items)),e.nextPageToken?n(e.nextPageToken,""):{nextSyncToken:e.nextSyncToken,results:o}})}("",n)}var L=function(){function e(t,n){var r=this,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{maxCachedItems:100,nDaysPerSlot:10,largeQuery:10};a()(this,e),this.calId=t,this.name=n,this.syncToken="",this.cache=new f.a({max:i.maxCachedItems,dispose:function(e,t){return r.onRemoveSlot(e,t)}}),this.eventMeta={},this.options=i,this.divider=864e5*this.options.nDaysPerSlot}return o()(e,[{key:"dateToCacheKey",value:function(e){return Math.floor(e/this.divider)}},{key:"dateRangeToCacheKeys",value:function(e){return{start:this.dateToCacheKey(e.start),end:this.dateToCacheKey(new Date(e.end.getTime()-1))}}},{key:"getSlot",value:function(e){if(this.cache.has(e))return this.cache.get(e);var t={};return this.cache.set(e,t),t}},{key:"onRemoveSlot",value:function(e,t){for(var n in t){console.assert(this.eventMeta[n]);var r=this.eventMeta[n].keys;r.delete(e),0===r.size&&delete this.eventMeta[n]}}},{key:"slotStartDate",value:function(e){return new Date(e*this.divider)}},{key:"slotEndDate",value:function(e){return new Date((e+1)*this.divider)}},{key:"addEvent",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];this.eventMeta.hasOwnProperty(e.id)&&this.removeEvent(e);for(var n=this.dateRangeToCacheKeys(e),r=n.start,a=n.end,i=this.cache.length,o=new Set,s=r;s<=a;s++)o.add(s),this.cache.has(s)||i++;if(this.eventMeta[e.id]={keys:o,summary:e.summary},t||!(i>this.options.maxCachedItems))if(r===a)this.getSlot(r)[e.id]={start:e.start,end:e.end,id:e.id};else{this.getSlot(r)[e.id]={start:e.start,end:this.slotEndDate(r),id:e.id},this.getSlot(a)[e.id]={start:this.slotStartDate(a),end:e.end,id:e.id};for(var u=r+1;u=n||r[i].end<=t||a.push({id:i,start:r[i].startn?n:r[i].end,summary:this.eventMeta[i].summary});return a}},{key:"getCachedEvents",value:function(e){for(var t=this.dateRangeToCacheKeys(e),n=t.start,r=t.end,a=this.getSlotEvents(n,e.start,e.end),i=n+1;in&&a.push.apply(a,u()(this.getSlotEvents(r,e.start,e.end))),a}},{key:"sync",value:function(){var e=this;return this.token.then(function(t){return x(e.calId,t,e.syncToken).then(function(n){var r=n.results.map(function(n){return n.start?Promise.resolve(n):function(e,t,n){return fetch("".concat(h,"/calendars/").concat(e,"/events/").concat(t,"?").concat(m({access_token:n})),{method:"GET",async:!0}).then(function(e){return e.json()})}(e.calId,n.id,t)});return Promise.all(r).then(function(t){t.forEach(function(t){t.start=new Date(t.start.dateTime),t.end=new Date(t.end.dateTime),"confirmed"===t.status?e.addEvent(t):"cancelled"===t.status&&e.removeEvent(t)}),e.syncToken=n.nextSyncToken})})}).catch(function(t){if(t!==p.invalidSyncToken)throw t;e.syncToken="",e.sync()})}},{key:"getEvents",value:function(e,t){for(var n=this,r=this.dateRangeToCacheKeys({start:e,end:t}),a={},i=r.start;i<=r.end;i++)this.cache.has(i)||(a.hasOwnProperty("start")||(a.start=i),a.end=i);return a.hasOwnProperty("start")?(console.assert(a.start<=a.end),a.end-a.start+1>this.options.largeQuery?(console.log("encounter large query, use direct fetch"),this.token.then(function(r){return x(n.calId,r,null,e.toISOString(),t.toISOString()).then(function(n){var r=[];return n.results.forEach(function(e){console.assert(e.start),e.start=new Date(e.start.dateTime),e.end=new Date(e.end.dateTime),r.push(e)}),r.filter(function(n){return!(n.start>=t||n.end<=e)}).map(function(n){return{id:n.id,start:n.startt?t:n.end,summary:n.summary}})})})):(console.log("fetching short event list"),this.token.then(function(e){return x(n.calId,e,null,n.slotStartDate(a.start).toISOString(),n.slotEndDate(a.end).toISOString()).then(function(e){e.results.forEach(function(e){"confirmed"===e.status&&(console.assert(e.start),e.start=new Date(e.start.dateTime),e.end=new Date(e.end.dateTime),n.addEvent(e,!0))}),""===n.syncToken&&(n.syncToken=e.nextSyncToken)})}).then(function(){return n.sync()}).then(function(){return n.getCachedEvents({start:e,end:t})}))):(console.log("cache hit"),this.sync().then(function(){return n.getCachedEvents({start:e,end:t})}))}},{key:"token",get:function(){return g()}}]),e}()},function(e,t,n){"use strict";var r=n(3);Object.defineProperty(t,"__esModule",{value:!0}),t.convertHexToRGB=i,t.rgbToHex=function(e){if(0===e.indexOf("#"))return e;var t=o(e).values;return t=t.map(function(e){return 1===(t=e.toString(16)).length?"0".concat(t):t;var t}),"#".concat(t.join(""))},t.decomposeColor=o,t.recomposeColor=s,t.getContrastRatio=function(e,t){var n=u(e),r=u(t);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)},t.getLuminance=u,t.emphasize=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:.15;return u(e)>.5?l(e,t):c(e,t)},t.fade=function(e,t){if(!e)return e;e=o(e),t=a(t),("rgb"===e.type||"hsl"===e.type)&&(e.type+="a");return e.values[3]=t,s(e)},t.darken=l,t.lighten=c;r(n(19));function a(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;return en?n:e}function i(e){e=e.substr(1);var t=new RegExp(".{1,".concat(e.length/3,"}"),"g"),n=e.match(t);return n&&1===n[0].length&&(n=n.map(function(e){return e+e})),n?"rgb(".concat(n.map(function(e){return parseInt(e,16)}).join(", "),")"):""}function o(e){if("#"===e.charAt(0))return o(i(e));var t=e.indexOf("("),n=e.substring(0,t),r=e.substring(t+1,e.length-1).split(",");return{type:n,values:r=r.map(function(e){return parseFloat(e)})}}function s(e){var t=e.type,n=e.values;return-1!==t.indexOf("rgb")&&(n=n.map(function(e,t){return t<3?parseInt(e,10):e})),-1!==t.indexOf("hsl")&&(n[1]="".concat(n[1],"%"),n[2]="".concat(n[2],"%")),"".concat(e.type,"(").concat(n.join(", "),")")}function u(e){var t=o(e);if(-1!==t.type.indexOf("rgb")){var n=t.values.map(function(e){return(e/=255)<=.03928?e/12.92:Math.pow((e+.055)/1.055,2.4)});return Number((.2126*n[0]+.7152*n[1]+.0722*n[2]).toFixed(3))}return t.values[2]/100}function l(e,t){if(!e)return e;if(e=o(e),t=a(t),-1!==e.type.indexOf("hsl"))e.values[2]*=1-t;else if(-1!==e.type.indexOf("rgb"))for(var n=0;n<3;n+=1)e.values[n]*=1-t;return s(e)}function c(e,t){if(!e)return e;if(e=o(e),t=a(t),-1!==e.type.indexOf("hsl"))e.values[2]+=(100-e.values[2])*t;else if(-1!==e.type.indexOf("rgb"))for(var n=0;n<3;n+=1)e.values[n]+=(255-e.values[n])*t;return s(e)}},,,function(e,t,n){"use strict";var r=n(3);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;r(n(7));var a=r(n(9)),i=r(n(10)),o=r(n(60)),s=r(n(347)),u=(r(n(19)),r(n(119))),l=r(n(349)),c=r(n(350)),d=r(n(356)),f=r(n(358)),h=r(n(359)),p=r(n(360)),m=r(n(111)),_=r(n(361));var y=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.breakpoints,n=void 0===t?{}:t,r=e.mixins,y=void 0===r?{}:r,v=e.palette,g=void 0===v?{}:v,b=e.shadows,M=e.spacing,k=void 0===M?{}:M,w=e.typography,x=void 0===w?{}:w,L=(0,i.default)(e,["breakpoints","mixins","palette","shadows","spacing","typography"]),T=(0,c.default)(g),Y=(0,u.default)(n),S=(0,a.default)({},p.default,k);return(0,a.default)({breakpoints:Y,direction:"ltr",mixins:(0,l.default)(Y,S,y),overrides:{},palette:T,props:{},shadows:b||f.default,typography:(0,d.default)(T,x)},(0,o.default)({shape:h.default,spacing:S,transitions:m.default,zIndex:_.default},L,{isMergeableObject:s.default}))};t.default=y},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r="";if(!t)return r;var a=n.indent,s=void 0===a?0:a,u=t.fallbacks;if(s++,u)if(Array.isArray(u))for(var l=0;l-1&&e%1==0&&e-1&&e%1==0&&e<=n}},function(e,t){e.exports=function(e){return function(t){return e(t)}}},function(e,t){e.exports=function(e,t){return e===t||e!=e&&t!=t}},function(e,t,n){var r=n(34)(n(23),"Map");e.exports=r},function(e,t,n){var r=n(448),a=n(455),i=n(457),o=n(458),s=n(459);function u(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t=0||(a[n]=e[n]);return a}(e,["component","childFactory"]),i=c(this.state.children).map(n);return delete r.appear,delete r.enter,delete r.exit,null===t?i:a.default.createElement(t,r,i)},r}(a.default.Component);d.childContextTypes={transitionGroup:r.default.object.isRequired},d.propTypes={},d.defaultProps={component:"div",childFactory:function(e){return e}};var f=(0,i.polyfill)(d);t.default=f,e.exports=t.default},function(e,t,n){var r=n(411),a=n(20),i="Expected a function";e.exports=function(e,t,n){var o=!0,s=!0;if("function"!=typeof e)throw new TypeError(i);return a(n)&&(o="leading"in n?!!n.leading:o,s="trailing"in n?!!n.trailing:s),r(e,t,{leading:o,maxWait:t,trailing:s})}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r={50:"#fbe9e7",100:"#ffccbc",200:"#ffab91",300:"#ff8a65",400:"#ff7043",500:"#ff5722",600:"#f4511e",700:"#e64a19",800:"#d84315",900:"#bf360c",A100:"#ff9e80",A200:"#ff6e40",A400:"#ff3d00",A700:"#dd2c00"};t.default=r},,function(e,t,n){"use strict";var r=n(3);Object.defineProperty(t,"__esModule",{value:!0}),t.default=t.isNumber=t.isString=t.formatMs=t.duration=t.easing=void 0;var a=r(n(10)),i=(r(n(19)),{easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",easeIn:"cubic-bezier(0.4, 0, 1, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"});t.easing=i;var o={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};t.duration=o;var s=function(e){return"".concat(Math.round(e),"ms")};t.formatMs=s;t.isString=function(e){return"string"==typeof e};t.isNumber=function(e){return!isNaN(parseFloat(e))};var u={easing:i,duration:o,create:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:["all"],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.duration,r=void 0===n?o.standard:n,u=t.easing,l=void 0===u?i.easeInOut:u,c=t.delay,d=void 0===c?0:c;(0,a.default)(t,["duration","easing","delay"]);return(Array.isArray(e)?e:[e]).map(function(e){return"".concat(e," ").concat("string"==typeof r?r:s(r)," ").concat(l," ").concat("string"==typeof d?d:s(d))}).join(",")},getAutoHeightDuration:function(e){if(!e)return 0;var t=e/36;return Math.round(10*(4+15*Math.pow(t,.25)+t/5))}};t.default=u},function(e,t,n){"use strict";var r=n(121),a={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},i={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},o={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},s={};function u(e){return r.isMemo(e)?o:s[e.$$typeof]||a}s[r.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0};var l=Object.defineProperty,c=Object.getOwnPropertyNames,d=Object.getOwnPropertySymbols,f=Object.getOwnPropertyDescriptor,h=Object.getPrototypeOf,p=Object.prototype;e.exports=function e(t,n,r){if("string"!=typeof n){if(p){var a=h(n);a&&a!==p&&e(t,a,r)}var o=c(n);d&&(o=o.concat(d(n)));for(var s=u(t),m=u(n),_=0;_0?1:-1},z=function(e){return O()(e)&&e.indexOf("%")===e.length-1},U=function(e){return W()(e)&&!I()(e)},B=function(e){return U(e)||O()(e)},G=0,V=function(e){var t=++G;return"".concat(e||"").concat(t)},J=function(e,t){var n,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,a=arguments.length>3&&void 0!==arguments[3]&&arguments[3];if(!U(e)&&!O()(e))return r;if(z(e)){var i=e.indexOf("%");n=t*parseFloat(e.slice(0,i))/100}else n=+e;return I()(n)&&(n=r),a&&n>t&&(n=t),n},q=function(e){if(!e)return null;var t=Object.keys(e);return t&&t.length?e[t[0]]:null},$=function(e,t){return U(e)&&U(t)?function(n){return e+n*(t-e)}:function(){return t}},K=function(e,t,n){return e&&e.length?e.find(function(e){return e&&H()(e,t)===n}):null};function X(e,t){for(var n in e)if({}.hasOwnProperty.call(e,n)&&(!{}.hasOwnProperty.call(t,n)||e[n]!==t[n]))return!1;for(var r in t)if({}.hasOwnProperty.call(t,r)&&!{}.hasOwnProperty.call(e,r))return!1;return!0}function Q(e,t){return!X(e,this.props)||!X(t,this.state)}function Z(e){e.prototype.shouldComponentUpdate=Q}function ee(e){return function(e){if(Array.isArray(e)){for(var t=0,n=new Array(e.length);t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var ne={alignmentBaseline:s.a.string,angle:s.a.number,baselineShift:s.a.string,clip:s.a.string,clipPath:s.a.string,clipRule:s.a.string,color:s.a.string,colorInterpolation:s.a.string,colorInterpolationFilters:s.a.string,colorProfile:s.a.string,colorRendering:s.a.string,cursor:s.a.string,direction:s.a.oneOf(["ltr","rtl","inherit"]),display:s.a.string,dominantBaseline:s.a.string,enableBackground:s.a.string,fill:s.a.string,fillOpacity:s.a.oneOfType([s.a.string,s.a.number]),fillRule:s.a.oneOf(["nonzero","evenodd","inherit"]),filter:s.a.string,floodColor:s.a.string,floodOpacity:s.a.oneOfType([s.a.string,s.a.number]),font:s.a.string,fontFamily:s.a.string,fontSize:s.a.oneOfType([s.a.number,s.a.string]),fontSizeAdjust:s.a.oneOfType([s.a.number,s.a.string]),fontStretch:s.a.oneOf(["normal","wider","narrower","ultra-condensed","extra-condensed","condensed","semi-condensed","semi-expanded","expanded","extra-expanded","ultra-expanded","inherit"]),fontStyle:s.a.oneOf(["normal","italic","oblique","inherit"]),fontVariant:s.a.oneOf(["normal","small-caps","inherit"]),fontWeight:s.a.oneOf(["normal","bold","bolder","lighter",100,200,300,400,500,600,700,800,900,"inherit"]),glyphOrientationHorizontal:s.a.string,glyphOrientationVertical:s.a.string,imageRendering:s.a.oneOf(["auto","optimizeSpeed","optimizeQuality","inherit"]),kerning:s.a.oneOfType([s.a.number,s.a.string]),letterSpacing:s.a.oneOfType([s.a.number,s.a.string]),lightingColor:s.a.string,lineHeight:s.a.oneOfType([s.a.number,s.a.string]),markerEnd:s.a.string,markerMid:s.a.string,markerStart:s.a.string,mask:s.a.string,opacity:s.a.oneOfType([s.a.number,s.a.string]),overflow:s.a.oneOf(["visible","hidden","scroll","auto","inherit"]),pointerEvents:s.a.oneOf(["visiblePainted","visibleFill","visibleStroke","visible","painted","fill","stroke","all","none","inherit"]),shapeRendering:s.a.oneOf(["auto","optimizeSpeed","crispEdges","geometricPrecision","inherit"]),stopColor:s.a.string,stopOpacity:s.a.oneOfType([s.a.number,s.a.string]),stroke:s.a.oneOfType([s.a.number,s.a.string]),strokeDasharray:s.a.string,strokeDashoffset:s.a.oneOfType([s.a.number,s.a.string]),strokeLinecap:s.a.oneOf(["butt","round","square","inherit"]),strokeLinejoin:s.a.oneOf(["miter","round","bevel","inherit"]),strokeMiterlimit:s.a.oneOfType([s.a.number,s.a.string]),strokeOpacity:s.a.oneOfType([s.a.number,s.a.string]),strokeWidth:s.a.oneOfType([s.a.number,s.a.string]),textAnchor:s.a.oneOf(["start","middle","end","inherit"]),textDecoration:s.a.oneOf(["none","underline","overline","line-through","blink","inherit"]),textRendering:s.a.oneOf(["auto","optimizeSpeed","optimizeLegibility","geometricPrecision","inherit"]),unicodeBidi:s.a.oneOf(["normal","embed","bidi-override","inherit"]),visibility:s.a.oneOf(["visible","hidden","collapse","inherit"]),wordSpacing:s.a.oneOfType([s.a.number,s.a.string]),writingMode:s.a.oneOf(["lr-tb","rl-tb","tb-rl","lr","rl","tb","inherit"]),transform:s.a.string,style:s.a.object,width:s.a.number,height:s.a.number,dx:s.a.number,dy:s.a.number,x:s.a.number,y:s.a.number,r:s.a.number,radius:s.a.oneOfType([s.a.number,s.a.array])},re={onClick:s.a.func,onMouseDown:s.a.func,onMouseUp:s.a.func,onMouseOver:s.a.func,onMouseMove:s.a.func,onMouseOut:s.a.func,onMouseEnter:s.a.func,onMouseLeave:s.a.func,onTouchEnd:s.a.func,onTouchMove:s.a.func,onTouchStart:s.a.func,onTouchCancel:s.a.func},ae={click:"onClick",mousedown:"onMouseDown",mouseup:"onMouseUp",mouseover:"onMouseOver",mousemove:"onMouseMove",mouseout:"onMouseOut",mouseenter:"onMouseEnter",mouseleave:"onMouseLeave",touchcancel:"onTouchCancel",touchend:"onTouchEnd",touchmove:"onTouchMove",touchstart:"onTouchStart"},ie=["plainline","line","square","rect","circle","cross","diamond","star","triangle","wye","none"],oe=function(e){return"string"==typeof e?e:e?e.displayName||e.name||"Component":""},se=function(e,t){var n=[],r=[];return r=A()(t)?t.map(function(e){return oe(e)}):[oe(t)],i.a.Children.forEach(e,function(e){var t=e&&e.type&&(e.type.displayName||e.type.name);-1!==r.indexOf(t)&&n.push(e)}),n},ue=function(e,t){var n=se(e,t);return n&&n[0]},le=function(e){if(!e||b()(e))return null;var t=i.a.isValidElement(e)?e.props:e;if(!E()(t))return null;var n=null;for(var r in t)({}).hasOwnProperty.call(t,r)&&ne[r]&&(n||(n={}),n[r]=t[r]);return n},ce=function(e,t){return function(n){return e(t,n),null}},de=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if(!e||b()(e))return null;var r=i.a.isValidElement(e)?e.props:e;if(!E()(r))return null;var a=null;for(var o in r)({}).hasOwnProperty.call(r,o)&&re[o]&&(a||(a={}),a[o]=t||(n?ce(r[o],r):r[o]));return a},fe=function(e,t,n){return function(r){return e(t,n,r),null}},he=function(e,t,n){if(!E()(e))return null;var r=null;for(var a in e)({}).hasOwnProperty.call(e,a)&&re[a]&&b()(e[a])&&(r||(r={}),r[a]=fe(e[a],t,n));return r},pe=function(e){if(!e||!e.props)return!1;var t=e.props,n=t.width,r=t.height;return!(!U(n)||n<=0||!U(r)||r<=0)},me=function(){return!("undefined"!=typeof window&&window.document&&window.document.createElement&&window.setTimeout)},_e=["a","altGlyph","altGlyphDef","altGlyphItem","animate","animateColor","animateMotion","animateTransform","circle","clipPath","color-profile","cursor","defs","desc","ellipse","feBlend","feColormatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","filter","font","font-face","font-face-format","font-face-name","font-face-url","foreignObject","g","glyph","glyphRef","hkern","image","line","lineGradient","marker","mask","metadata","missing-glyph","mpath","path","pattern","polygon","polyline","radialGradient","rect","script","set","stop","style","svg","switch","symbol","text","textPath","title","tref","tspan","use","view","vkern"],ye=function(e,t){if(T()(e)&&T()(t))return!0;if(!T()(e)&&!T()(t)){var n=e.props||{},r=n.children,a=te(n,["children"]),i=t.props||{},o=i.children,s=te(i,["children"]);return r&&o?X(a,s)&&ve(r,o):!r&&!o&&X(a,s)}return!1},ve=function e(t,n){if(t===n)return!0;if(a.Children.count(t)!==a.Children.count(n))return!1;var r=a.Children.count(t);if(0===r)return!0;if(1===r)return ye(A()(t)?t[0]:t,A()(n)?n[0]:n);for(var i=0;i=0}(e))n.push(e);else if(e&&t[oe(e.type)]){var i=oe(e.type),o=t[i],s=o.handler,u=o.once;if(u&&!r[i]||!u){var l=s(e,i,a);A()(l)?n=[n].concat(ee(l)):n.push(l),r[i]=!0}}}),n},be=function(e){var t=e&&e.type;return t&&ae[t]?ae[t]:null};function Me(){return(Me=Object.assign||function(e){for(var t=1;t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var we={width:s.a.number.isRequired,height:s.a.number.isRequired,viewBox:s.a.shape({x:s.a.number,y:s.a.number,width:s.a.number,height:s.a.number}),className:s.a.string,style:s.a.object,children:s.a.oneOfType([s.a.arrayOf(s.a.node),s.a.node])};function xe(e){var t=e.children,n=e.width,r=e.height,a=e.viewBox,o=e.className,s=e.style,u=ke(e,["children","width","height","viewBox","className","style"]),l=a||{width:n,height:r,x:0,y:0},c=S()("recharts-surface",o),d=le(u);return i.a.createElement("svg",Me({},d,{className:c,width:n,height:r,style:s,viewBox:"".concat(l.x," ").concat(l.y," ").concat(l.width," ").concat(l.height),version:"1.1"}),t)}xe.propTypes=we;var Le=xe;function Te(){return(Te=Object.assign||function(e){for(var t=1;t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var Se={className:s.a.string,children:s.a.oneOfType([s.a.arrayOf(s.a.node),s.a.node])};function De(e){var t=e.children,n=e.className,r=Ye(e,["children","className"]),a=S()("recharts-layer",n);return i.a.createElement("g",Te({className:a},r),t)}De.propTypes=Se;var Oe=De,je=n(26),Ee=n.n(je),Pe=n(31),Ae=n.n(Pe);function Ce(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=-1;Ae()(function r(a){n<0&&(n=a),a-n>t?(e(a),n=-1):Ae()(r)})}function He(e){return(He="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})(e)}function Ne(e){return function(e){if(Array.isArray(e))return e}(e)||function(e){if(Symbol.iterator in Object(e)||"[object Arguments]"===Object.prototype.toString.call(e))return Array.from(e)}(e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance")}()}function Ie(){var e=function(){return null},t=!1;return{stop:function(){t=!0},start:function(n){t=!1,function n(r){if(!t){if(Array.isArray(r)){if(!r.length)return;var a=Ne(r),i=a[0],o=a.slice(1);return"number"==typeof i?void Ce(n.bind(null,o),i):(n(i),void Ce(n.bind(null,o)))}"object"===He(r)&&e(r),"function"==typeof r&&r()}}(n)},subscribe:function(t){return e=t,function(){e=function(){return null}}}}}var Re=n(57),We=n.n(Re);function Fe(e){return(Fe="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})(e)}function ze(e,t){if(e===t)return!0;if("object"!==Fe(e)||null===e||"object"!==Fe(t)||null===t)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(var a=hasOwnProperty.bind(t),i=0;i=0&&e<=1});var s,u,l=it(r,i),c=it(a,o),d=(s=r,u=i,function(e){var t=nt(rt(s,u).map(function(e,t){return e*t}).slice(1)).concat([0]);return at(t,e)}),f=function(e){for(var t,n=e>1?1:e,r=n,a=0;a<8;++a){var i=l(r)-n,o=d(r);if(Math.abs(i-n)<1e-4||o<1e-4)return c(r);r=(t=r-i/o)>1?1:t<0?0:t}return c(r)};return f.isStepper=!1,f},st=function(){for(var e=arguments.length,t=new Array(e),n=0;n0&&void 0!==arguments[0]?arguments[0]:{},t=e.stiff,n=void 0===t?100:t,r=e.damping,a=void 0===r?8:r,i=e.dt,o=void 0===i?17:i,s=function(e,t,r){var i=r+(-(e-t)*n-r*a)*o/1e3,s=r*o/1e3+e;return Math.abs(s-t)<1e-4&&Math.abs(i)<1e-4?[t,0]:[s,i]};return s.isStepper=!0,s.dt=o,s}()}return"function"==typeof r?r:null},ut=n(301),lt=n.n(ut);function ct(e){return function(e){if(Array.isArray(e)){for(var t=0,n=new Array(e.length);t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}function kt(e){return function(e){if(Array.isArray(e)){for(var t=0,n=new Array(e.length);t0?n[a-1]:r,f=l||Object.keys(u);if("function"==typeof s||"spring"===s)return kt(e).concat([t.runJSAnimation.bind(t,{from:d.style,to:u,duration:i,easing:s}),i]);var h=tt(f,i,s),p=wt({},d.style,u,{transition:h});return kt(e).concat([p,i,c]).filter(Qe)},[o,Math.max(u,r)])),[e.onAnimationEnd]))}},{key:"runAnimation",value:function(e){this.manager||(this.manager=Ie());var t=e.begin,n=e.duration,r=e.attributeName,a=e.to,i=e.easing,o=e.onAnimationStart,s=e.onAnimationEnd,u=e.steps,l=e.children,c=this.manager;if(this.unSubscribe=c.subscribe(this.handleStyleChange),"function"!=typeof i&&"function"!=typeof l&&"spring"!==i)if(u.length>1)this.runStepAnimation(e);else{var d=r?xt({},r,a):a,f=tt(Object.keys(d),n,i);c.start([o,t,wt({},d,{transition:f}),n,s])}else this.runJSAnimation(e)}},{key:"handleStyleChange",value:function(e){this.changeStyle(e)}},{key:"changeStyle",value:function(e){this.mounted&&this.setState({style:e})}},{key:"render",value:function(){var e=this.props,t=e.children,n=(e.begin,e.duration,e.attributeName,e.easing,e.isActive),r=(e.steps,e.from,e.to,e.canBegin,e.onAnimationEnd,e.shouldReAnimate,e.onAnimationReStart,Mt(e,["children","begin","duration","attributeName","easing","isActive","steps","from","to","canBegin","onAnimationEnd","shouldReAnimate","onAnimationReStart"])),o=a.Children.count(t),s=et(this.state.style);if("function"==typeof t)return t(s);if(!n||0===o)return t;var u=function(e){var t=e.props,n=t.style,i=void 0===n?{}:n,o=t.className;return Object(a.cloneElement)(e,wt({},r,{style:wt({},i,s),className:o}))};return 1===o?u(a.Children.only(t)):i.a.createElement("div",null,a.Children.map(t,function(e){return u(e)}))}}])&&Lt(n.prototype,r),o&&Lt(n,o),t}(),mt.displayName="Animate",mt.propTypes={from:s.a.oneOfType([s.a.object,s.a.string]),to:s.a.oneOfType([s.a.object,s.a.string]),attributeName:s.a.string,duration:s.a.number,begin:s.a.number,easing:s.a.oneOfType([s.a.string,s.a.func]),steps:s.a.arrayOf(s.a.shape({duration:s.a.number.isRequired,style:s.a.object.isRequired,easing:s.a.oneOfType([s.a.oneOf(["ease","ease-in","ease-out","ease-in-out","linear"]),s.a.func]),properties:s.a.arrayOf("string"),onAnimationEnd:s.a.func})),children:s.a.oneOfType([s.a.node,s.a.func]),isActive:s.a.bool,canBegin:s.a.bool,onAnimationEnd:s.a.func,shouldReAnimate:s.a.bool,onAnimationStart:s.a.func,onAnimationReStart:s.a.func},mt.defaultProps={begin:0,duration:1e3,from:"",to:"",attributeName:"",easing:"ease",isActive:!0,canBegin:!0,steps:[],onAnimationEnd:function(){},onAnimationStart:function(){}},pt=_t))||pt,jt=n(75);function Et(e){return(Et="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})(e)}function Pt(){return(Pt=Object.assign||function(e){for(var t=1;t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}function Ct(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ht(e,t){for(var n=0;n0&&void 0!==arguments[0]?arguments[0]:{},t=e.steps,n=e.duration;return t&&t.length?t.reduce(function(e,t){return e+(W()(t.duration)&&t.duration>0?t.duration:0)},0):W()(n)?n:0},Ft=function(e){function t(){var e,n;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);for(var r=arguments.length,a=new Array(r),i=0;i1||Math.abs(r.height-n)>1)&&this.setState({boxWidth:r.width,boxHeight:r.height})}else-1===t&&-1===n||this.setState({boxWidth:-1,boxHeight:-1})}},{key:"render",value:function(){var e,t,n,r=this,a=this.props,o=a.payload,s=a.isAnimationActive,u=a.animationDuration,l=a.animationEasing,c=a.filterNull&&o&&o.length?o.filter(function(e){return!T()(e.value)}):o,d=c&&c.length,f=this.props,h=f.content,p=f.viewBox,m=f.coordinate,_=f.position,y=f.active,v=f.offset,g=un({pointerEvents:"none",visibility:y&&d?"visible":"hidden",position:"absolute",top:0},f.wrapperStyle);if(_&&U(_.x)&&U(_.y))t=_.x,n=_.y;else{var M=this.state,k=M.boxWidth,w=M.boxHeight;k>0&&w>0&&m?(t=_&&U(_.x)?_.x:Math.max(m.x+k+v>p.x+p.width?m.x-k-v:m.x+v,p.x),n=_&&U(_.y)?_.y:Math.max(m.y+w+v>p.y+p.height?m.y-w-v:m.y+v,p.y)):g.visibility="hidden"}g=un({},g,et({transform:this.props.useTranslate3d?"translate3d(".concat(t,"px, ").concat(n,"px, 0)"):"translate(".concat(t,"px, ").concat(n,"px)")})),s&&y&&(g=un({},g,et({transition:"transform ".concat(u,"ms ").concat(l)})));var x=S()(pn,(ln(e={},"".concat(pn,"-right"),U(t)&&m&&U(m.x)&&t>=m.x),ln(e,"".concat(pn,"-left"),U(t)&&m&&U(m.x)&&t=m.y),ln(e,"".concat(pn,"-top"),U(n)&&m&&U(m.y)&&n1e-6)if(Math.abs(c*s-u*l)>1e-6&&a){var f=n-i,h=r-o,p=s*s+u*u,m=f*f+h*h,_=Math.sqrt(p),y=Math.sqrt(d),v=a*Math.tan((vn-Math.acos((p+d-m)/(2*_*y)))/2),g=v/y,b=v/_;Math.abs(g-1)>1e-6&&(this._+="L"+(e+g*l)+","+(t+g*c)),this._+="A"+a+","+a+",0,0,"+ +(c*f>l*h)+","+(this._x1=e+b*s)+","+(this._y1=t+b*u)}else this._+="L"+(this._x1=e)+","+(this._y1=t);else;},arc:function(e,t,n,r,a,i){e=+e,t=+t;var o=(n=+n)*Math.cos(r),s=n*Math.sin(r),u=e+o,l=t+s,c=1^i,d=i?r-a:a-r;if(n<0)throw new Error("negative radius: "+n);null===this._x1?this._+="M"+u+","+l:(Math.abs(this._x1-u)>1e-6||Math.abs(this._y1-l)>1e-6)&&(this._+="L"+u+","+l),n&&(d<0&&(d=d%gn+gn),d>bn?this._+="A"+n+","+n+",0,1,"+c+","+(e-o)+","+(t-s)+"A"+n+","+n+",0,1,"+c+","+(this._x1=u)+","+(this._y1=l):d>1e-6&&(this._+="A"+n+","+n+",0,"+ +(d>=vn)+","+c+","+(this._x1=e+n*Math.cos(a))+","+(this._y1=t+n*Math.sin(a))))},rect:function(e,t,n,r){this._+="M"+(this._x0=this._x1=+e)+","+(this._y0=this._y1=+t)+"h"+ +n+"v"+ +r+"h"+-n+"Z"},toString:function(){return this._}};var wn=kn,xn=function(e){return function(){return e}},Ln=(Math.abs,Math.atan2,Math.cos,Math.max,Math.min,Math.sin,Math.sqrt,1e-12),Tn=Math.PI,Yn=2*Tn;function Sn(e){this._context=e}Sn.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:this._context.lineTo(e,t)}}};var Dn=function(e){return new Sn(e)};function On(e){return e[0]}function jn(e){return e[1]}var En=function(){var e=On,t=jn,n=xn(!0),r=null,a=Dn,i=null;function o(o){var s,u,l,c=o.length,d=!1;for(null==r&&(i=a(l=wn())),s=0;s<=c;++s)!(s=c;--d)s.point(_[d],y[d]);s.lineEnd(),s.areaEnd()}m&&(_[l]=+e(f,l,u),y[l]=+n(f,l,u),s.point(t?+t(f,l,u):_[l],r?+r(f,l,u):y[l]))}if(h)return s=null,h+""||null}function l(){return En().defined(a).curve(o).context(i)}return u.x=function(n){return arguments.length?(e="function"==typeof n?n:xn(+n),t=null,u):e},u.x0=function(t){return arguments.length?(e="function"==typeof t?t:xn(+t),u):e},u.x1=function(e){return arguments.length?(t=null==e?null:"function"==typeof e?e:xn(+e),u):t},u.y=function(e){return arguments.length?(n="function"==typeof e?e:xn(+e),r=null,u):n},u.y0=function(e){return arguments.length?(n="function"==typeof e?e:xn(+e),u):n},u.y1=function(e){return arguments.length?(r=null==e?null:"function"==typeof e?e:xn(+e),u):r},u.lineX0=u.lineY0=function(){return l().x(e).y(n)},u.lineY1=function(){return l().x(e).y(r)},u.lineX1=function(){return l().x(t).y(n)},u.defined=function(e){return arguments.length?(a="function"==typeof e?e:xn(!!e),u):a},u.curve=function(e){return arguments.length?(o=e,null!=i&&(s=o(i)),u):o},u.context=function(e){return arguments.length?(null==e?i=s=null:s=o(i=e),u):i},u};Cn(Dn);function An(e){this._curve=e}function Cn(e){function t(t){return new An(e(t))}return t._curve=e,t}An.prototype={areaStart:function(){this._curve.areaStart()},areaEnd:function(){this._curve.areaEnd()},lineStart:function(){this._curve.lineStart()},lineEnd:function(){this._curve.lineEnd()},point:function(e,t){this._curve.point(t*Math.sin(e),t*-Math.cos(e))}};var Hn=Array.prototype.slice;var Nn={draw:function(e,t){var n=Math.sqrt(t/Tn);e.moveTo(n,0),e.arc(0,0,n,0,Yn)}},In={draw:function(e,t){var n=Math.sqrt(t/5)/2;e.moveTo(-3*n,-n),e.lineTo(-n,-n),e.lineTo(-n,-3*n),e.lineTo(n,-3*n),e.lineTo(n,-n),e.lineTo(3*n,-n),e.lineTo(3*n,n),e.lineTo(n,n),e.lineTo(n,3*n),e.lineTo(-n,3*n),e.lineTo(-n,n),e.lineTo(-3*n,n),e.closePath()}},Rn=Math.sqrt(1/3),Wn=2*Rn,Fn={draw:function(e,t){var n=Math.sqrt(t/Wn),r=n*Rn;e.moveTo(0,-n),e.lineTo(r,0),e.lineTo(0,n),e.lineTo(-r,0),e.closePath()}},zn=Math.sin(Tn/10)/Math.sin(7*Tn/10),Un=Math.sin(Yn/10)*zn,Bn=-Math.cos(Yn/10)*zn,Gn={draw:function(e,t){var n=Math.sqrt(.8908130915292852*t),r=Un*n,a=Bn*n;e.moveTo(0,-n),e.lineTo(r,a);for(var i=1;i<5;++i){var o=Yn*i/5,s=Math.cos(o),u=Math.sin(o);e.lineTo(u*n,-s*n),e.lineTo(s*r-u*a,u*r+s*a)}e.closePath()}},Vn={draw:function(e,t){var n=Math.sqrt(t),r=-n/2;e.rect(r,r,n,n)}},Jn=Math.sqrt(3),qn={draw:function(e,t){var n=-Math.sqrt(t/(3*Jn));e.moveTo(0,2*n),e.lineTo(-Jn*n,-n),e.lineTo(Jn*n,-n),e.closePath()}},$n=Math.sqrt(3)/2,Kn=1/Math.sqrt(12),Xn=3*(Kn/2+1),Qn={draw:function(e,t){var n=Math.sqrt(t/Xn),r=n/2,a=n*Kn,i=r,o=n*Kn+n,s=-i,u=o;e.moveTo(r,a),e.lineTo(i,o),e.lineTo(s,u),e.lineTo(-.5*r-$n*a,$n*r+-.5*a),e.lineTo(-.5*i-$n*o,$n*i+-.5*o),e.lineTo(-.5*s-$n*u,$n*s+-.5*u),e.lineTo(-.5*r+$n*a,-.5*a-$n*r),e.lineTo(-.5*i+$n*o,-.5*o-$n*i),e.lineTo(-.5*s+$n*u,-.5*u-$n*s),e.closePath()}},Zn=function(){};function er(e,t,n){e._context.bezierCurveTo((2*e._x0+e._x1)/3,(2*e._y0+e._y1)/3,(e._x0+2*e._x1)/3,(e._y0+2*e._y1)/3,(e._x0+4*e._x1+t)/6,(e._y0+4*e._y1+n)/6)}function tr(e){this._context=e}tr.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:er(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:er(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function nr(e){this._context=e}nr.prototype={areaStart:Zn,areaEnd:Zn,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x2,this._y2),this._context.closePath();break;case 2:this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break;case 3:this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4)}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x2=e,this._y2=t;break;case 1:this._point=2,this._x3=e,this._y3=t;break;case 2:this._point=3,this._x4=e,this._y4=t,this._context.moveTo((this._x0+4*this._x1+e)/6,(this._y0+4*this._y1+t)/6);break;default:er(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function rr(e){this._context=e}rr.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var n=(this._x0+4*this._x1+e)/6,r=(this._y0+4*this._y1+t)/6;this._line?this._context.lineTo(n,r):this._context.moveTo(n,r);break;case 3:this._point=4;default:er(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function ar(e,t){this._basis=new tr(e),this._beta=t}ar.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var e=this._x,t=this._y,n=e.length-1;if(n>0)for(var r,a=e[0],i=t[0],o=e[n]-a,s=t[n]-i,u=-1;++u<=n;)r=u/n,this._basis.point(this._beta*e[u]+(1-this._beta)*(a+r*o),this._beta*t[u]+(1-this._beta)*(i+r*s));this._x=this._y=null,this._basis.lineEnd()},point:function(e,t){this._x.push(+e),this._y.push(+t)}};(function e(t){function n(e){return 1===t?new tr(e):new ar(e,t)}return n.beta=function(t){return e(+t)},n})(.85);function ir(e,t,n){e._context.bezierCurveTo(e._x1+e._k*(e._x2-e._x0),e._y1+e._k*(e._y2-e._y0),e._x2+e._k*(e._x1-t),e._y2+e._k*(e._y1-n),e._x2,e._y2)}function or(e,t){this._context=e,this._k=(1-t)/6}or.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:ir(this,this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2,this._x1=e,this._y1=t;break;case 2:this._point=3;default:ir(this,e,t)}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};(function e(t){function n(e){return new or(e,t)}return n.tension=function(t){return e(+t)},n})(0);function sr(e,t){this._context=e,this._k=(1-t)/6}sr.prototype={areaStart:Zn,areaEnd:Zn,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x3=e,this._y3=t;break;case 1:this._point=2,this._context.moveTo(this._x4=e,this._y4=t);break;case 2:this._point=3,this._x5=e,this._y5=t;break;default:ir(this,e,t)}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};(function e(t){function n(e){return new sr(e,t)}return n.tension=function(t){return e(+t)},n})(0);function ur(e,t){this._context=e,this._k=(1-t)/6}ur.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:ir(this,e,t)}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};(function e(t){function n(e){return new ur(e,t)}return n.tension=function(t){return e(+t)},n})(0);function lr(e,t,n){var r=e._x1,a=e._y1,i=e._x2,o=e._y2;if(e._l01_a>Ln){var s=2*e._l01_2a+3*e._l01_a*e._l12_a+e._l12_2a,u=3*e._l01_a*(e._l01_a+e._l12_a);r=(r*s-e._x0*e._l12_2a+e._x2*e._l01_2a)/u,a=(a*s-e._y0*e._l12_2a+e._y2*e._l01_2a)/u}if(e._l23_a>Ln){var l=2*e._l23_2a+3*e._l23_a*e._l12_a+e._l12_2a,c=3*e._l23_a*(e._l23_a+e._l12_a);i=(i*l+e._x1*e._l23_2a-t*e._l12_2a)/c,o=(o*l+e._y1*e._l23_2a-n*e._l12_2a)/c}e._context.bezierCurveTo(r,a,i,o,e._x2,e._y2)}function cr(e,t){this._context=e,this._alpha=t}cr.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:this.point(this._x2,this._y2)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){if(e=+e,t=+t,this._point){var n=this._x2-e,r=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3;default:lr(this,e,t)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};(function e(t){function n(e){return t?new cr(e,t):new or(e,0)}return n.alpha=function(t){return e(+t)},n})(.5);function dr(e,t){this._context=e,this._alpha=t}dr.prototype={areaStart:Zn,areaEnd:Zn,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(e,t){if(e=+e,t=+t,this._point){var n=this._x2-e,r=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1,this._x3=e,this._y3=t;break;case 1:this._point=2,this._context.moveTo(this._x4=e,this._y4=t);break;case 2:this._point=3,this._x5=e,this._y5=t;break;default:lr(this,e,t)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};(function e(t){function n(e){return t?new dr(e,t):new sr(e,0)}return n.alpha=function(t){return e(+t)},n})(.5);function fr(e,t){this._context=e,this._alpha=t}fr.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){if(e=+e,t=+t,this._point){var n=this._x2-e,r=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:lr(this,e,t)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};(function e(t){function n(e){return t?new fr(e,t):new ur(e,0)}return n.alpha=function(t){return e(+t)},n})(.5);function hr(e){this._context=e}hr.prototype={areaStart:Zn,areaEnd:Zn,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(e,t){e=+e,t=+t,this._point?this._context.lineTo(e,t):(this._point=1,this._context.moveTo(e,t))}};function pr(e){return e<0?-1:1}function mr(e,t,n){var r=e._x1-e._x0,a=t-e._x1,i=(e._y1-e._y0)/(r||a<0&&-0),o=(n-e._y1)/(a||r<0&&-0),s=(i*a+o*r)/(r+a);return(pr(i)+pr(o))*Math.min(Math.abs(i),Math.abs(o),.5*Math.abs(s))||0}function _r(e,t){var n=e._x1-e._x0;return n?(3*(e._y1-e._y0)/n-t)/2:t}function yr(e,t,n){var r=e._x0,a=e._y0,i=e._x1,o=e._y1,s=(i-r)/3;e._context.bezierCurveTo(r+s,a+s*t,i-s,o-s*n,i,o)}function vr(e){this._context=e}function gr(e){this._context=new br(e)}function br(e){this._context=e}function Mr(e){this._context=e}function kr(e){var t,n,r=e.length-1,a=new Array(r),i=new Array(r),o=new Array(r);for(a[0]=0,i[0]=2,o[0]=e[0]+2*e[1],t=1;t=0;--t)a[t]=(o[t]-a[t+1])/i[t];for(i[r-1]=(e[r]+a[r-1])/2,t=0;t=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:if(this._t<=0)this._context.lineTo(this._x,t),this._context.lineTo(e,t);else{var n=this._x*(1-this._t)+e*this._t;this._context.lineTo(n,this._y),this._context.lineTo(n,t)}}this._x=e,this._y=t}};var xr=function(e,t){if((a=e.length)>1)for(var n,r,a,i=1,o=e[t[0]],s=o.length;i=0;)n[t]=t;return n};function Tr(e,t){return e[t]}var Yr,Sr,Dr;function Or(e){return(Or="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})(e)}function jr(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Er(){return(Er=Object.assign||function(e){for(var t=1;t=0&&n>=0?{width:t,height:n}:null}},{key:"getDefaultPosition",value:function(e){var t,n,r=this.props,a=r.layout,i=r.align,o=r.verticalAlign,s=r.margin,u=r.chartWidth,l=r.chartHeight;e&&(void 0!==e.left&&null!==e.left||void 0!==e.right&&null!==e.right)||(t="center"===i&&"vertical"===a?{left:((u||0)-(this.getBBox()||{width:0}).width)/2}:"right"===i?{right:s&&s.right||0}:{left:s&&s.left||0});e&&(void 0!==e.top&&null!==e.top||void 0!==e.bottom&&null!==e.bottom)||(n="middle"===o?{top:((l||0)-(this.getBBox()||{height:0}).height)/2}:"bottom"===o?{bottom:s&&s.bottom||0}:{top:s&&s.top||0});return na({},t,n)}},{key:"updateBBox",value:function(){var e=this.state,t=e.boxWidth,n=e.boxHeight,r=this.props.onBBoxUpdate;if(this.wrapperNode&&this.wrapperNode.getBoundingClientRect){var a=this.wrapperNode.getBoundingClientRect();(Math.abs(a.width-t)>1||Math.abs(a.height-n)>1)&&this.setState({boxWidth:a.width,boxHeight:a.height},function(){r&&r(a)})}else-1===t&&-1===n||this.setState({boxWidth:-1,boxHeight:-1},function(){r&&r(null)})}},{key:"render",value:function(){var e=this,t=this.props,n=t.content,r=t.width,a=t.height,o=t.wrapperStyle,s=na({position:"absolute",width:r||"auto",height:a||"auto"},this.getDefaultPosition(o),o);return i.a.createElement("div",{className:"recharts-legend-wrapper",style:s,ref:function(t){e.wrapperNode=t}},function(e,t){return i.a.isValidElement(e)?i.a.cloneElement(e,t):b()(e)?e(t):i.a.createElement(ea,t)}(n,this.props))}}])&&aa(n.prototype,r),o&&aa(n,o),t}(),Xr.displayName="Legend",Xr.propTypes={content:s.a.oneOfType([s.a.element,s.a.func]),wrapperStyle:s.a.object,chartWidth:s.a.number,chartHeight:s.a.number,width:s.a.number,height:s.a.number,iconSize:s.a.number,iconType:s.a.oneOf(da),layout:s.a.oneOf(["horizontal","vertical"]),align:s.a.oneOf(["center","left","right"]),verticalAlign:s.a.oneOf(["top","bottom","middle"]),margin:s.a.shape({top:s.a.number,left:s.a.number,bottom:s.a.number,right:s.a.number}),payload:s.a.arrayOf(s.a.shape({value:s.a.any,id:s.a.any,type:s.a.oneOf(ie)})),formatter:s.a.func,onMouseEnter:s.a.func,onMouseLeave:s.a.func,onClick:s.a.func,onBBoxUpdate:s.a.func},Xr.defaultProps={iconSize:14,layout:"horizontal",align:"center",verticalAlign:"bottom"},Kr=Qr))||Kr;function ha(e){return(ha="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})(e)}function pa(){return(pa=Object.assign||function(e){for(var t=1;tt?1:e>=t?0:NaN},Ga=function(e){var t;return 1===e.length&&(t=e,e=function(e,n){return Ba(t(e),n)}),{left:function(t,n,r,a){for(null==r&&(r=0),null==a&&(a=t.length);r>>1;e(t[i],n)<0?r=i+1:a=i}return r},right:function(t,n,r,a){for(null==r&&(r=0),null==a&&(a=t.length);r>>1;e(t[i],n)>0?a=i:r=i+1}return r}}};var Va=Ga(Ba),Ja=Va.right,qa=(Va.left,Ja);var $a=function(e){return null===e?NaN:+e},Ka=Array.prototype,Xa=(Ka.slice,Ka.map,function(e,t,n){e=+e,t=+t,n=(a=arguments.length)<2?(t=e,e=0,1):a<3?1:+n;for(var r=-1,a=0|Math.max(0,Math.ceil((t-e)/n)),i=new Array(a);++r0)return[e];if((r=t0)for(e=Math.ceil(e/o),t=Math.floor(t/o),i=new Array(a=Math.ceil(t-e+1));++s=0?(i>=Qa?10:i>=Za?5:i>=ei?2:1)*Math.pow(10,a):-Math.pow(10,-a)/(i>=Qa?10:i>=Za?5:i>=ei?2:1)}function ri(e,t,n){var r=Math.abs(t-e)/Math.max(0,n),a=Math.pow(10,Math.floor(Math.log(r)/Math.LN10)),i=r/a;return i>=Qa?a*=10:i>=Za?a*=5:i>=ei&&(a*=2),t=1)return+n(e[r-1],r-1,e);var r,a=(r-1)*t,i=Math.floor(a),o=+n(e[i],i,e);return o+(+n(e[i+1],i+1,e)-o)*(a-i)}};function ii(){}function oi(e,t){var n=new ii;if(e instanceof ii)e.each(function(e,t){n.set(t,e)});else if(Array.isArray(e)){var r,a=-1,i=e.length;if(null==t)for(;++a>8&15|t>>4&240,t>>4&15|240&t,(15&t)<<4|15&t,1):(t=Li.exec(e))?Ai(parseInt(t[1],16)):(t=Ti.exec(e))?new Ii(t[1],t[2],t[3],1):(t=Yi.exec(e))?new Ii(255*t[1]/100,255*t[2]/100,255*t[3]/100,1):(t=Si.exec(e))?Ci(t[1],t[2],t[3],t[4]):(t=Di.exec(e))?Ci(255*t[1]/100,255*t[2]/100,255*t[3]/100,t[4]):(t=Oi.exec(e))?Wi(t[1],t[2]/100,t[3]/100,1):(t=ji.exec(e))?Wi(t[1],t[2]/100,t[3]/100,t[4]):Ei.hasOwnProperty(e)?Ai(Ei[e]):"transparent"===e?new Ii(NaN,NaN,NaN,0):null}function Ai(e){return new Ii(e>>16&255,e>>8&255,255&e,1)}function Ci(e,t,n,r){return r<=0&&(e=t=n=NaN),new Ii(e,t,n,r)}function Hi(e){return e instanceof bi||(e=Pi(e)),e?new Ii((e=e.rgb()).r,e.g,e.b,e.opacity):new Ii}function Ni(e,t,n,r){return 1===arguments.length?Hi(e):new Ii(e,t,n,null==r?1:r)}function Ii(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}function Ri(e){return((e=Math.max(0,Math.min(255,Math.round(e)||0)))<16?"0":"")+e.toString(16)}function Wi(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new zi(e,t,n,r)}function Fi(e,t,n,r){return 1===arguments.length?function(e){if(e instanceof zi)return new zi(e.h,e.s,e.l,e.opacity);if(e instanceof bi||(e=Pi(e)),!e)return new zi;if(e instanceof zi)return e;var t=(e=e.rgb()).r/255,n=e.g/255,r=e.b/255,a=Math.min(t,n,r),i=Math.max(t,n,r),o=NaN,s=i-a,u=(i+a)/2;return s?(o=t===i?(n-r)/s+6*(n0&&u<1?0:o,new zi(o,s,u,e.opacity)}(e):new zi(e,t,n,null==r?1:r)}function zi(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}function Ui(e,t,n){return 255*(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)}vi(bi,Pi,{displayable:function(){return this.rgb().displayable()},hex:function(){return this.rgb().hex()},toString:function(){return this.rgb()+""}}),vi(Ii,Ni,gi(bi,{brighter:function(e){return e=null==e?1/.7:Math.pow(1/.7,e),new Ii(this.r*e,this.g*e,this.b*e,this.opacity)},darker:function(e){return e=null==e?.7:Math.pow(.7,e),new Ii(this.r*e,this.g*e,this.b*e,this.opacity)},rgb:function(){return this},displayable:function(){return 0<=this.r&&this.r<=255&&0<=this.g&&this.g<=255&&0<=this.b&&this.b<=255&&0<=this.opacity&&this.opacity<=1},hex:function(){return"#"+Ri(this.r)+Ri(this.g)+Ri(this.b)},toString:function(){var e=this.opacity;return(1===(e=isNaN(e)?1:Math.max(0,Math.min(1,e)))?"rgb(":"rgba(")+Math.max(0,Math.min(255,Math.round(this.r)||0))+", "+Math.max(0,Math.min(255,Math.round(this.g)||0))+", "+Math.max(0,Math.min(255,Math.round(this.b)||0))+(1===e?")":", "+e+")")}})),vi(zi,Fi,gi(bi,{brighter:function(e){return e=null==e?1/.7:Math.pow(1/.7,e),new zi(this.h,this.s,this.l*e,this.opacity)},darker:function(e){return e=null==e?.7:Math.pow(.7,e),new zi(this.h,this.s,this.l*e,this.opacity)},rgb:function(){var e=this.h%360+360*(this.h<0),t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*t,a=2*n-r;return new Ii(Ui(e>=240?e-240:e+120,a,r),Ui(e,a,r),Ui(e<120?e+240:e-120,a,r),this.opacity)},displayable:function(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1}}));var Bi=Math.PI/180,Gi=180/Math.PI,Vi=.96422,Ji=1,qi=.82521,$i=4/29,Ki=6/29,Xi=3*Ki*Ki,Qi=Ki*Ki*Ki;function Zi(e){if(e instanceof to)return new to(e.l,e.a,e.b,e.opacity);if(e instanceof uo){if(isNaN(e.h))return new to(e.l,0,0,e.opacity);var t=e.h*Bi;return new to(e.l,Math.cos(t)*e.c,Math.sin(t)*e.c,e.opacity)}e instanceof Ii||(e=Hi(e));var n,r,a=io(e.r),i=io(e.g),o=io(e.b),s=no((.2225045*a+.7168786*i+.0606169*o)/Ji);return a===i&&i===o?n=r=s:(n=no((.4360747*a+.3850649*i+.1430804*o)/Vi),r=no((.0139322*a+.0971045*i+.7141733*o)/qi)),new to(116*s-16,500*(n-s),200*(s-r),e.opacity)}function eo(e,t,n,r){return 1===arguments.length?Zi(e):new to(e,t,n,null==r?1:r)}function to(e,t,n,r){this.l=+e,this.a=+t,this.b=+n,this.opacity=+r}function no(e){return e>Qi?Math.pow(e,1/3):e/Xi+$i}function ro(e){return e>Ki?e*e*e:Xi*(e-$i)}function ao(e){return 255*(e<=.0031308?12.92*e:1.055*Math.pow(e,1/2.4)-.055)}function io(e){return(e/=255)<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4)}function oo(e){if(e instanceof uo)return new uo(e.h,e.c,e.l,e.opacity);if(e instanceof to||(e=Zi(e)),0===e.a&&0===e.b)return new uo(NaN,0,e.l,e.opacity);var t=Math.atan2(e.b,e.a)*Gi;return new uo(t<0?t+360:t,Math.sqrt(e.a*e.a+e.b*e.b),e.l,e.opacity)}function so(e,t,n,r){return 1===arguments.length?oo(e):new uo(e,t,n,null==r?1:r)}function uo(e,t,n,r){this.h=+e,this.c=+t,this.l=+n,this.opacity=+r}vi(to,eo,gi(bi,{brighter:function(e){return new to(this.l+18*(null==e?1:e),this.a,this.b,this.opacity)},darker:function(e){return new to(this.l-18*(null==e?1:e),this.a,this.b,this.opacity)},rgb:function(){var e=(this.l+16)/116,t=isNaN(this.a)?e:e+this.a/500,n=isNaN(this.b)?e:e-this.b/200;return new Ii(ao(3.1338561*(t=Vi*ro(t))-1.6168667*(e=Ji*ro(e))-.4906146*(n=qi*ro(n))),ao(-.9787684*t+1.9161415*e+.033454*n),ao(.0719453*t-.2289914*e+1.4052427*n),this.opacity)}})),vi(uo,so,gi(bi,{brighter:function(e){return new uo(this.h,this.c,this.l+18*(null==e?1:e),this.opacity)},darker:function(e){return new uo(this.h,this.c,this.l-18*(null==e?1:e),this.opacity)},rgb:function(){return Zi(this).rgb()}}));var lo=-.14861,co=1.78277,fo=-.29227,ho=-.90649,po=1.97294,mo=po*ho,_o=po*co,yo=co*fo-ho*lo;function vo(e,t,n,r){return 1===arguments.length?function(e){if(e instanceof go)return new go(e.h,e.s,e.l,e.opacity);e instanceof Ii||(e=Hi(e));var t=e.r/255,n=e.g/255,r=e.b/255,a=(yo*r+mo*t-_o*n)/(yo+mo-_o),i=r-a,o=(po*(n-a)-fo*i)/ho,s=Math.sqrt(o*o+i*i)/(po*a*(1-a)),u=s?Math.atan2(o,i)*Gi-120:NaN;return new go(u<0?u+360:u,s,a,e.opacity)}(e):new go(e,t,n,null==r?1:r)}function go(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}function bo(e,t,n,r,a){var i=e*e,o=i*e;return((1-3*e+3*i-o)*t+(4-6*i+3*o)*n+(1+3*e+3*i-3*o)*r+o*a)/6}vi(go,vo,gi(bi,{brighter:function(e){return e=null==e?1/.7:Math.pow(1/.7,e),new go(this.h,this.s,this.l*e,this.opacity)},darker:function(e){return e=null==e?.7:Math.pow(.7,e),new go(this.h,this.s,this.l*e,this.opacity)},rgb:function(){var e=isNaN(this.h)?0:(this.h+120)*Bi,t=+this.l,n=isNaN(this.s)?0:this.s*t*(1-t),r=Math.cos(e),a=Math.sin(e);return new Ii(255*(t+n*(lo*r+co*a)),255*(t+n*(fo*r+ho*a)),255*(t+n*(po*r)),this.opacity)}}));var Mo=function(e){return function(){return e}};function ko(e,t){return function(n){return e+n*t}}function wo(e,t){var n=t-e;return n?ko(e,n>180||n<-180?n-360*Math.round(n/360):n):Mo(isNaN(e)?t:e)}function xo(e){return 1==(e=+e)?Lo:function(t,n){return n-t?function(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(r){return Math.pow(e+r*t,n)}}(t,n,e):Mo(isNaN(t)?n:t)}}function Lo(e,t){var n=t-e;return n?ko(e,n):Mo(isNaN(e)?t:e)}var To=function e(t){var n=xo(t);function r(e,t){var r=n((e=Ni(e)).r,(t=Ni(t)).r),a=n(e.g,t.g),i=n(e.b,t.b),o=Lo(e.opacity,t.opacity);return function(t){return e.r=r(t),e.g=a(t),e.b=i(t),e.opacity=o(t),e+""}}return r.gamma=e,r}(1);function Yo(e){return function(t){var n,r,a=t.length,i=new Array(a),o=new Array(a),s=new Array(a);for(n=0;n=1?(n=1,t-1):Math.floor(n*t),a=e[r],i=e[r+1],o=r>0?e[r-1]:2*a-i,s=ri&&(a=t.slice(i,a),s[o]?s[o]+=a:s[++o]=a),(n=n[0])===(r=r[0])?s[o]?s[o]+=r:s[++o]=r:(s[++o]=null,u.push({i:o,x:So(n,r)})),i=Oo.lastIndex;return i180?t+=360:t-e>180&&(e+=360),i.push({i:n.push(a(n)+"rotate(",null,r)-2,x:So(e,t)})):t&&n.push(a(n)+"rotate("+t+r)}(i.rotate,o.rotate,s,u),function(e,t,n,i){e!==t?i.push({i:n.push(a(n)+"skewX(",null,r)-2,x:So(e,t)}):t&&n.push(a(n)+"skewX("+t+r)}(i.skewX,o.skewX,s,u),function(e,t,n,r,i,o){if(e!==n||t!==r){var s=i.push(a(i)+"scale(",null,",",null,")");o.push({i:s-4,x:So(e,n)},{i:s-2,x:So(t,r)})}else 1===n&&1===r||i.push(a(i)+"scale("+n+","+r+")")}(i.scaleX,i.scaleY,o.scaleX,o.scaleY,s,u),i=o=null,function(e){for(var t,n=-1,r=u.length;++n2?$o:qo,r=a=null,c}function c(t){return(r||(r=n(i,o,u?function(e){return function(t,n){var r=e(t=+t,n=+n);return function(e){return e<=t?0:e>=n?1:r(e)}}}(e):e,s)))(+t)}return c.invert=function(e){return(a||(a=n(o,i,Jo,u?function(e){return function(t,n){var r=e(t=+t,n=+n);return function(e){return e<=0?t:e>=1?n:r(e)}}}(t):t)))(+e)},c.domain=function(e){return arguments.length?(i=fi.call(e,Go),l()):i.slice()},c.range=function(e){return arguments.length?(o=hi.call(e),l()):o.slice()},c.rangeRound=function(e){return o=hi.call(e),s=Ho,l()},c.clamp=function(e){return arguments.length?(u=!!e,l()):u},c.interpolate=function(e){return arguments.length?(s=e,l()):s},l()}var Qo=function(e,t){if((n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"))<0)return null;var n,r=e.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+e.slice(n+1)]},Zo=function(e){return(e=Qo(Math.abs(e)))?e[1]:NaN},es=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function ts(e){return new ns(e)}function ns(e){if(!(t=es.exec(e)))throw new Error("invalid format: "+e);var t;this.fill=t[1]||" ",this.align=t[2]||">",this.sign=t[3]||"-",this.symbol=t[4]||"",this.zero=!!t[5],this.width=t[6]&&+t[6],this.comma=!!t[7],this.precision=t[8]&&+t[8].slice(1),this.trim=!!t[9],this.type=t[10]||""}ts.prototype=ns.prototype,ns.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(null==this.width?"":Math.max(1,0|this.width))+(this.comma?",":"")+(null==this.precision?"":"."+Math.max(0,0|this.precision))+(this.trim?"~":"")+this.type};var rs,as,is,os,ss=function(e){e:for(var t,n=e.length,r=1,a=-1;r0){if(!+e[r])break e;a=0}}return a>0?e.slice(0,a)+e.slice(t+1):e},us=function(e,t){var n=Qo(e,t);if(!n)return e+"";var r=n[0],a=n[1];return a<0?"0."+new Array(-a).join("0")+r:r.length>a+1?r.slice(0,a+1)+"."+r.slice(a+1):r+new Array(a-r.length+2).join("0")},ls={"%":function(e,t){return(100*e).toFixed(t)},b:function(e){return Math.round(e).toString(2)},c:function(e){return e+""},d:function(e){return Math.round(e).toString(10)},e:function(e,t){return e.toExponential(t)},f:function(e,t){return e.toFixed(t)},g:function(e,t){return e.toPrecision(t)},o:function(e){return Math.round(e).toString(8)},p:function(e,t){return us(100*e,t)},r:us,s:function(e,t){var n=Qo(e,t);if(!n)return e+"";var r=n[0],a=n[1],i=a-(rs=3*Math.max(-8,Math.min(8,Math.floor(a/3))))+1,o=r.length;return i===o?r:i>o?r+new Array(i-o+1).join("0"):i>0?r.slice(0,i)+"."+r.slice(i):"0."+new Array(1-i).join("0")+Qo(e,Math.max(0,t+i-1))[0]},X:function(e){return Math.round(e).toString(16).toUpperCase()},x:function(e){return Math.round(e).toString(16)}},cs=function(e){return e},ds=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];as=function(e){var t,n,r=e.grouping&&e.thousands?(t=e.grouping,n=e.thousands,function(e,r){for(var a=e.length,i=[],o=0,s=t[0],u=0;a>0&&s>0&&(u+s+1>r&&(s=Math.max(1,r-u)),i.push(e.substring(a-=s,a+s)),!((u+=s+1)>r));)s=t[o=(o+1)%t.length];return i.reverse().join(n)}):cs,a=e.currency,i=e.decimal,o=e.numerals?function(e){return function(t){return t.replace(/[0-9]/g,function(t){return e[+t]})}}(e.numerals):cs,s=e.percent||"%";function u(e){var t=(e=ts(e)).fill,n=e.align,u=e.sign,l=e.symbol,c=e.zero,d=e.width,f=e.comma,h=e.precision,p=e.trim,m=e.type;"n"===m?(f=!0,m="g"):ls[m]||(null==h&&(h=12),p=!0,m="g"),(c||"0"===t&&"="===n)&&(c=!0,t="0",n="=");var _="$"===l?a[0]:"#"===l&&/[boxX]/.test(m)?"0"+m.toLowerCase():"",y="$"===l?a[1]:/[%p]/.test(m)?s:"",v=ls[m],g=/[defgprs%]/.test(m);function b(e){var a,s,l,b=_,M=y;if("c"===m)M=v(e)+M,e="";else{var k=(e=+e)<0;if(e=v(Math.abs(e),h),p&&(e=ss(e)),k&&0==+e&&(k=!1),b=(k?"("===u?u:"-":"-"===u||"("===u?"":u)+b,M=("s"===m?ds[8+rs/3]:"")+M+(k&&"("===u?")":""),g)for(a=-1,s=e.length;++a(l=e.charCodeAt(a))||l>57){M=(46===l?i+e.slice(a+1):e.slice(a))+M,e=e.slice(0,a);break}}f&&!c&&(e=r(e,1/0));var w=b.length+e.length+M.length,x=w>1)+b+e+M+x.slice(w);break;default:e=x+b+e+M}return o(e)}return h=null==h?6:/[gprs]/.test(m)?Math.max(1,Math.min(21,h)):Math.max(0,Math.min(20,h)),b.toString=function(){return e+""},b}return{format:u,formatPrefix:function(e,t){var n=u(((e=ts(e)).type="f",e)),r=3*Math.max(-8,Math.min(8,Math.floor(Zo(t)/3))),a=Math.pow(10,-r),i=ds[8+r/3];return function(e){return n(a*e)+i}}}}({decimal:".",thousands:",",grouping:[3],currency:["$",""]}),is=as.format,os=as.formatPrefix;var fs=function(e,t,n){var r,a=e[0],i=e[e.length-1],o=ri(a,i,null==t?10:t);switch((n=ts(null==n?",f":n)).type){case"s":var s=Math.max(Math.abs(a),Math.abs(i));return null!=n.precision||isNaN(r=function(e,t){return Math.max(0,3*Math.max(-8,Math.min(8,Math.floor(Zo(t)/3)))-Zo(Math.abs(e)))}(o,s))||(n.precision=r),os(n,s);case"":case"e":case"g":case"p":case"r":null!=n.precision||isNaN(r=function(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,Zo(t)-Zo(e))+1}(o,Math.max(Math.abs(a),Math.abs(i))))||(n.precision=r-("e"===n.type));break;case"f":case"%":null!=n.precision||isNaN(r=function(e){return Math.max(0,-Zo(Math.abs(e)))}(o))||(n.precision=r-2*("%"===n.type))}return is(n)};function hs(e){var t=e.domain;return e.ticks=function(e){var n=t();return ti(n[0],n[n.length-1],null==e?10:e)},e.tickFormat=function(e,n){return fs(t(),e,n)},e.nice=function(n){null==n&&(n=10);var r,a=t(),i=0,o=a.length-1,s=a[i],u=a[o];return u0?r=ni(s=Math.floor(s/r)*r,u=Math.ceil(u/r)*r,n):r<0&&(r=ni(s=Math.ceil(s*r)/r,u=Math.floor(u*r)/r,n)),r>0?(a[i]=Math.floor(s/r)*r,a[o]=Math.ceil(u/r)*r,t(a)):r<0&&(a[i]=Math.ceil(s*r)/r,a[o]=Math.floor(u*r)/r,t(a)),e},e}function ps(){var e=Xo(Jo,So);return e.copy=function(){return Ko(e,ps())},hs(e)}function ms(){var e=[0,1];function t(e){return+e}return t.invert=t,t.domain=t.range=function(n){return arguments.length?(e=fi.call(n,Go),t):e.slice()},t.copy=function(){return ms().domain(e)},hs(t)}var _s=function(e,t){var n,r=0,a=(e=e.slice()).length-1,i=e[r],o=e[a];return o0){for(;fu)break;m.push(d)}}else for(;f=1;--c)if(!((d=l*c)u)break;m.push(d)}}else m=ti(f,h,Math.min(h-f,p)).map(a);return i?m.reverse():m},e.tickFormat=function(t,i){if(null==i&&(i=10===n?".0e":","),"function"!=typeof i&&(i=is(i)),t===1/0)return i;null==t&&(t=10);var o=Math.max(1,n*t/e.ticks().length);return function(e){var t=e/a(Math.round(r(e)));return t*n0?n[a-1]:e[0],a=n?[r[n-1],t]:[r[o-1],r[o]]},i.copy=function(){return Ss().domain([e,t]).range(a)},hs(i)}function Ds(){var e=[.5],t=[0,1],n=1;function r(r){if(r<=r)return t[qa(e,r,0,n)]}return r.domain=function(a){return arguments.length?(e=hi.call(a),n=Math.min(e.length,t.length-1),r):e.slice()},r.range=function(a){return arguments.length?(t=hi.call(a),n=Math.min(e.length,t.length-1),r):t.slice()},r.invertExtent=function(n){var r=t.indexOf(n);return[e[r-1],e[r]]},r.copy=function(){return Ds().domain(e).range(t)},r}var Os=new Date,js=new Date;function Es(e,t,n,r){function a(t){return e(t=new Date(+t)),t}return a.floor=a,a.ceil=function(n){return e(n=new Date(n-1)),t(n,1),e(n),n},a.round=function(e){var t=a(e),n=a.ceil(e);return e-t0))return s;do{s.push(o=new Date(+n)),t(n,i),e(n)}while(o=t)for(;e(t),!n(t);)t.setTime(t-1)},function(e,r){if(e>=e)if(r<0)for(;++r<=0;)for(;t(e,-1),!n(e););else for(;--r>=0;)for(;t(e,1),!n(e););})},n&&(a.count=function(t,r){return Os.setTime(+t),js.setTime(+r),e(Os),e(js),Math.floor(n(Os,js))},a.every=function(e){return e=Math.floor(e),isFinite(e)&&e>0?e>1?a.filter(r?function(t){return r(t)%e==0}:function(t){return a.count(0,t)%e==0}):a:null}),a}var Ps=Es(function(){},function(e,t){e.setTime(+e+t)},function(e,t){return t-e});Ps.every=function(e){return e=Math.floor(e),isFinite(e)&&e>0?e>1?Es(function(t){t.setTime(Math.floor(t/e)*e)},function(t,n){t.setTime(+t+n*e)},function(t,n){return(n-t)/e}):Ps:null};var As=Ps,Cs=(Ps.range,6e4),Hs=6048e5,Ns=Es(function(e){e.setTime(e-e.getMilliseconds())},function(e,t){e.setTime(+e+1e3*t)},function(e,t){return(t-e)/1e3},function(e){return e.getUTCSeconds()}),Is=Ns,Rs=(Ns.range,Es(function(e){e.setTime(e-e.getMilliseconds()-1e3*e.getSeconds())},function(e,t){e.setTime(+e+t*Cs)},function(e,t){return(t-e)/Cs},function(e){return e.getMinutes()})),Ws=Rs,Fs=(Rs.range,Es(function(e){e.setTime(e-e.getMilliseconds()-1e3*e.getSeconds()-e.getMinutes()*Cs)},function(e,t){e.setTime(+e+36e5*t)},function(e,t){return(t-e)/36e5},function(e){return e.getHours()})),zs=Fs,Us=(Fs.range,Es(function(e){e.setHours(0,0,0,0)},function(e,t){e.setDate(e.getDate()+t)},function(e,t){return(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*Cs)/864e5},function(e){return e.getDate()-1})),Bs=Us;Us.range;function Gs(e){return Es(function(t){t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)},function(e,t){e.setDate(e.getDate()+7*t)},function(e,t){return(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*Cs)/Hs})}var Vs=Gs(0),Js=Gs(1),qs=Gs(2),$s=Gs(3),Ks=Gs(4),Xs=Gs(5),Qs=Gs(6),Zs=(Vs.range,Js.range,qs.range,$s.range,Ks.range,Xs.range,Qs.range,Es(function(e){e.setDate(1),e.setHours(0,0,0,0)},function(e,t){e.setMonth(e.getMonth()+t)},function(e,t){return t.getMonth()-e.getMonth()+12*(t.getFullYear()-e.getFullYear())},function(e){return e.getMonth()})),eu=Zs,tu=(Zs.range,Es(function(e){e.setMonth(0,1),e.setHours(0,0,0,0)},function(e,t){e.setFullYear(e.getFullYear()+t)},function(e,t){return t.getFullYear()-e.getFullYear()},function(e){return e.getFullYear()}));tu.every=function(e){return isFinite(e=Math.floor(e))&&e>0?Es(function(t){t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)},function(t,n){t.setFullYear(t.getFullYear()+n*e)}):null};var nu=tu,ru=(tu.range,Es(function(e){e.setUTCSeconds(0,0)},function(e,t){e.setTime(+e+t*Cs)},function(e,t){return(t-e)/Cs},function(e){return e.getUTCMinutes()})),au=ru,iu=(ru.range,Es(function(e){e.setUTCMinutes(0,0,0)},function(e,t){e.setTime(+e+36e5*t)},function(e,t){return(t-e)/36e5},function(e){return e.getUTCHours()})),ou=iu,su=(iu.range,Es(function(e){e.setUTCHours(0,0,0,0)},function(e,t){e.setUTCDate(e.getUTCDate()+t)},function(e,t){return(t-e)/864e5},function(e){return e.getUTCDate()-1})),uu=su;su.range;function lu(e){return Es(function(t){t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)},function(e,t){e.setUTCDate(e.getUTCDate()+7*t)},function(e,t){return(t-e)/Hs})}var cu=lu(0),du=lu(1),fu=lu(2),hu=lu(3),pu=lu(4),mu=lu(5),_u=lu(6),yu=(cu.range,du.range,fu.range,hu.range,pu.range,mu.range,_u.range,Es(function(e){e.setUTCDate(1),e.setUTCHours(0,0,0,0)},function(e,t){e.setUTCMonth(e.getUTCMonth()+t)},function(e,t){return t.getUTCMonth()-e.getUTCMonth()+12*(t.getUTCFullYear()-e.getUTCFullYear())},function(e){return e.getUTCMonth()})),vu=yu,gu=(yu.range,Es(function(e){e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},function(e,t){e.setUTCFullYear(e.getUTCFullYear()+t)},function(e,t){return t.getUTCFullYear()-e.getUTCFullYear()},function(e){return e.getUTCFullYear()}));gu.every=function(e){return isFinite(e=Math.floor(e))&&e>0?Es(function(t){t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},function(t,n){t.setUTCFullYear(t.getUTCFullYear()+n*e)}):null};var bu=gu;gu.range;function Mu(e){if(0<=e.y&&e.y<100){var t=new Date(-1,e.m,e.d,e.H,e.M,e.S,e.L);return t.setFullYear(e.y),t}return new Date(e.y,e.m,e.d,e.H,e.M,e.S,e.L)}function ku(e){if(0<=e.y&&e.y<100){var t=new Date(Date.UTC(-1,e.m,e.d,e.H,e.M,e.S,e.L));return t.setUTCFullYear(e.y),t}return new Date(Date.UTC(e.y,e.m,e.d,e.H,e.M,e.S,e.L))}function wu(e){return{y:e,m:0,d:1,H:0,M:0,S:0,L:0}}var xu,Lu,Tu,Yu,Su={"-":"",_:" ",0:"0"},Du=/^\s*\d+/,Ou=/^%/,ju=/[\\^$*+?|[\]().{}]/g;function Eu(e,t,n){var r=e<0?"-":"",a=(r?-e:e)+"",i=a.length;return r+(i68?1900:2e3),n+r[0].length):-1}function Uu(e,t,n){var r=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(t.slice(n,n+6));return r?(e.Z=r[1]?0:-(r[2]+(r[3]||"00")),n+r[0].length):-1}function Bu(e,t,n){var r=Du.exec(t.slice(n,n+2));return r?(e.m=r[0]-1,n+r[0].length):-1}function Gu(e,t,n){var r=Du.exec(t.slice(n,n+2));return r?(e.d=+r[0],n+r[0].length):-1}function Vu(e,t,n){var r=Du.exec(t.slice(n,n+3));return r?(e.m=0,e.d=+r[0],n+r[0].length):-1}function Ju(e,t,n){var r=Du.exec(t.slice(n,n+2));return r?(e.H=+r[0],n+r[0].length):-1}function qu(e,t,n){var r=Du.exec(t.slice(n,n+2));return r?(e.M=+r[0],n+r[0].length):-1}function $u(e,t,n){var r=Du.exec(t.slice(n,n+2));return r?(e.S=+r[0],n+r[0].length):-1}function Ku(e,t,n){var r=Du.exec(t.slice(n,n+3));return r?(e.L=+r[0],n+r[0].length):-1}function Xu(e,t,n){var r=Du.exec(t.slice(n,n+6));return r?(e.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function Qu(e,t,n){var r=Ou.exec(t.slice(n,n+1));return r?n+r[0].length:-1}function Zu(e,t,n){var r=Du.exec(t.slice(n));return r?(e.Q=+r[0],n+r[0].length):-1}function el(e,t,n){var r=Du.exec(t.slice(n));return r?(e.Q=1e3*+r[0],n+r[0].length):-1}function tl(e,t){return Eu(e.getDate(),t,2)}function nl(e,t){return Eu(e.getHours(),t,2)}function rl(e,t){return Eu(e.getHours()%12||12,t,2)}function al(e,t){return Eu(1+Bs.count(nu(e),e),t,3)}function il(e,t){return Eu(e.getMilliseconds(),t,3)}function ol(e,t){return il(e,t)+"000"}function sl(e,t){return Eu(e.getMonth()+1,t,2)}function ul(e,t){return Eu(e.getMinutes(),t,2)}function ll(e,t){return Eu(e.getSeconds(),t,2)}function cl(e){var t=e.getDay();return 0===t?7:t}function dl(e,t){return Eu(Vs.count(nu(e),e),t,2)}function fl(e,t){var n=e.getDay();return e=n>=4||0===n?Ks(e):Ks.ceil(e),Eu(Ks.count(nu(e),e)+(4===nu(e).getDay()),t,2)}function hl(e){return e.getDay()}function pl(e,t){return Eu(Js.count(nu(e),e),t,2)}function ml(e,t){return Eu(e.getFullYear()%100,t,2)}function _l(e,t){return Eu(e.getFullYear()%1e4,t,4)}function yl(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+Eu(t/60|0,"0",2)+Eu(t%60,"0",2)}function vl(e,t){return Eu(e.getUTCDate(),t,2)}function gl(e,t){return Eu(e.getUTCHours(),t,2)}function bl(e,t){return Eu(e.getUTCHours()%12||12,t,2)}function Ml(e,t){return Eu(1+uu.count(bu(e),e),t,3)}function kl(e,t){return Eu(e.getUTCMilliseconds(),t,3)}function wl(e,t){return kl(e,t)+"000"}function xl(e,t){return Eu(e.getUTCMonth()+1,t,2)}function Ll(e,t){return Eu(e.getUTCMinutes(),t,2)}function Tl(e,t){return Eu(e.getUTCSeconds(),t,2)}function Yl(e){var t=e.getUTCDay();return 0===t?7:t}function Sl(e,t){return Eu(cu.count(bu(e),e),t,2)}function Dl(e,t){var n=e.getUTCDay();return e=n>=4||0===n?pu(e):pu.ceil(e),Eu(pu.count(bu(e),e)+(4===bu(e).getUTCDay()),t,2)}function Ol(e){return e.getUTCDay()}function jl(e,t){return Eu(du.count(bu(e),e),t,2)}function El(e,t){return Eu(e.getUTCFullYear()%100,t,2)}function Pl(e,t){return Eu(e.getUTCFullYear()%1e4,t,4)}function Al(){return"+0000"}function Cl(){return"%"}function Hl(e){return+e}function Nl(e){return Math.floor(+e/1e3)}!function(e){xu=function(e){var t=e.dateTime,n=e.date,r=e.time,a=e.periods,i=e.days,o=e.shortDays,s=e.months,u=e.shortMonths,l=Au(a),c=Cu(a),d=Au(i),f=Cu(i),h=Au(o),p=Cu(o),m=Au(s),_=Cu(s),y=Au(u),v=Cu(u),g={a:function(e){return o[e.getDay()]},A:function(e){return i[e.getDay()]},b:function(e){return u[e.getMonth()]},B:function(e){return s[e.getMonth()]},c:null,d:tl,e:tl,f:ol,H:nl,I:rl,j:al,L:il,m:sl,M:ul,p:function(e){return a[+(e.getHours()>=12)]},Q:Hl,s:Nl,S:ll,u:cl,U:dl,V:fl,w:hl,W:pl,x:null,X:null,y:ml,Y:_l,Z:yl,"%":Cl},b={a:function(e){return o[e.getUTCDay()]},A:function(e){return i[e.getUTCDay()]},b:function(e){return u[e.getUTCMonth()]},B:function(e){return s[e.getUTCMonth()]},c:null,d:vl,e:vl,f:wl,H:gl,I:bl,j:Ml,L:kl,m:xl,M:Ll,p:function(e){return a[+(e.getUTCHours()>=12)]},Q:Hl,s:Nl,S:Tl,u:Yl,U:Sl,V:Dl,w:Ol,W:jl,x:null,X:null,y:El,Y:Pl,Z:Al,"%":Cl},M={a:function(e,t,n){var r=h.exec(t.slice(n));return r?(e.w=p[r[0].toLowerCase()],n+r[0].length):-1},A:function(e,t,n){var r=d.exec(t.slice(n));return r?(e.w=f[r[0].toLowerCase()],n+r[0].length):-1},b:function(e,t,n){var r=y.exec(t.slice(n));return r?(e.m=v[r[0].toLowerCase()],n+r[0].length):-1},B:function(e,t,n){var r=m.exec(t.slice(n));return r?(e.m=_[r[0].toLowerCase()],n+r[0].length):-1},c:function(e,n,r){return x(e,t,n,r)},d:Gu,e:Gu,f:Xu,H:Ju,I:Ju,j:Vu,L:Ku,m:Bu,M:qu,p:function(e,t,n){var r=l.exec(t.slice(n));return r?(e.p=c[r[0].toLowerCase()],n+r[0].length):-1},Q:Zu,s:el,S:$u,u:Nu,U:Iu,V:Ru,w:Hu,W:Wu,x:function(e,t,r){return x(e,n,t,r)},X:function(e,t,n){return x(e,r,t,n)},y:zu,Y:Fu,Z:Uu,"%":Qu};function k(e,t){return function(n){var r,a,i,o=[],s=-1,u=0,l=e.length;for(n instanceof Date||(n=new Date(+n));++s53)return null;"w"in i||(i.w=1),"Z"in i?(a=(r=ku(wu(i.y))).getUTCDay(),r=a>4||0===a?du.ceil(r):du(r),r=uu.offset(r,7*(i.V-1)),i.y=r.getUTCFullYear(),i.m=r.getUTCMonth(),i.d=r.getUTCDate()+(i.w+6)%7):(a=(r=t(wu(i.y))).getDay(),r=a>4||0===a?Js.ceil(r):Js(r),r=Bs.offset(r,7*(i.V-1)),i.y=r.getFullYear(),i.m=r.getMonth(),i.d=r.getDate()+(i.w+6)%7)}else("W"in i||"U"in i)&&("w"in i||(i.w="u"in i?i.u%7:"W"in i?1:0),a="Z"in i?ku(wu(i.y)).getUTCDay():t(wu(i.y)).getDay(),i.m=0,i.d="W"in i?(i.w+6)%7+7*i.W-(a+5)%7:i.w+7*i.U-(a+6)%7);return"Z"in i?(i.H+=i.Z/100|0,i.M+=i.Z%100,ku(i)):t(i)}}function x(e,t,n,r){for(var a,i,o=0,s=t.length,u=n.length;o=u)return-1;if(37===(a=t.charCodeAt(o++))){if(a=t.charAt(o++),!(i=M[a in Su?t.charAt(o++):a])||(r=i(e,n,r))<0)return-1}else if(a!=n.charCodeAt(r++))return-1}return r}return g.x=k(n,g),g.X=k(r,g),g.c=k(t,g),b.x=k(n,b),b.X=k(r,b),b.c=k(t,b),{format:function(e){var t=k(e+="",g);return t.toString=function(){return e},t},parse:function(e){var t=w(e+="",Mu);return t.toString=function(){return e},t},utcFormat:function(e){var t=k(e+="",b);return t.toString=function(){return e},t},utcParse:function(e){var t=w(e,ku);return t.toString=function(){return e},t}}}(e),Lu=xu.format,xu.parse,Tu=xu.utcFormat,Yu=xu.utcParse}({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});Date.prototype.toISOString||Tu("%Y-%m-%dT%H:%M:%S.%LZ");+new Date("2000-01-01T00:00:00.000Z")||Yu("%Y-%m-%dT%H:%M:%S.%LZ");var Il=1e3,Rl=60*Il,Wl=60*Rl,Fl=24*Wl,zl=7*Fl,Ul=30*Fl,Bl=365*Fl;function Gl(e){return new Date(e)}function Vl(e){return e instanceof Date?+e:+new Date(+e)}function Jl(e,t,n,r,a,i,o,s,u){var l=Xo(Jo,So),c=l.invert,d=l.domain,f=u(".%L"),h=u(":%S"),p=u("%I:%M"),m=u("%I %p"),_=u("%a %d"),y=u("%b %d"),v=u("%B"),g=u("%Y"),b=[[o,1,Il],[o,5,5*Il],[o,15,15*Il],[o,30,30*Il],[i,1,Rl],[i,5,5*Rl],[i,15,15*Rl],[i,30,30*Rl],[a,1,Wl],[a,3,3*Wl],[a,6,6*Wl],[a,12,12*Wl],[r,1,Fl],[r,2,2*Fl],[n,1,zl],[t,1,Ul],[t,3,3*Ul],[e,1,Bl]];function M(s){return(o(s)=0&&a===+a?"".concat(a,"px"):a),";");var r,a,i},"")},_c=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(null==e||me())return{width:0,height:0};var n="".concat(e),r=mc(t),a="".concat(n,"-").concat(r);if(fc.widthCache[a])return fc.widthCache[a];try{var i=document.getElementById("recharts_measurement_span");i||((i=document.createElement("span")).setAttribute("id","recharts_measurement_span"),document.body.appendChild(i));var o=function(e){for(var t=1;t2e3&&(fc.cacheCount=0,fc.widthCache={}),u}catch(e){return{width:0,height:0}}};function yc(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function vc(e){return(vc="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})(e)}function gc(){return(gc=Object.assign||function(e){for(var t=1;t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}function Mc(e,t){for(var n=0;n=0?1:-1;"insideStart"===o?(r=p+g*u,a=_):"insideEnd"===o?(r=m-g*u,a=!_):"end"===o&&(r=m+g*u,a=_),a=v<=0?a:!a;var b=If(c,d,y,r),M=If(c,d,y,r+359*(a?1:-1)),k="M".concat(b.x,",").concat(b.y,"\n A").concat(y,",").concat(y,",0,1,").concat(a?0:1,",\n ").concat(M.x,",").concat(M.y),w=T()(e.id)?V("recharts-radial-line-"):e.id;return i.a.createElement("text",Dc({},n,{dominantBaseline:"central",className:S()("recharts-radial-bar-label",l)}),i.a.createElement("defs",null,i.a.createElement("path",{id:w,d:k})),i.a.createElement("textPath",{xlinkHref:"#".concat(w)},t))},Hc=function(e){var t=e.viewBox,n=e.offset,r=e.position,a=t.cx,i=t.cy,o=t.innerRadius,s=t.outerRadius,u=(t.startAngle+t.endAngle)/2;if("outside"===r){var l=If(a,i,s+n,u),c=l.x;return{x:c,y:l.y,textAnchor:c>=a?"start":"end",verticalAnchor:"middle"}}if("center"===r)return{x:a,y:i,textAnchor:"middle",verticalAnchor:"middle"};if("centerTop"===r)return{x:a,y:i,textAnchor:"middle",verticalAnchor:"start"};if("centerBottom"===r)return{x:a,y:i,textAnchor:"middle",verticalAnchor:"end"};var d=If(a,i,(o+s)/2,u);return{x:d.x,y:d.y,textAnchor:"middle",verticalAnchor:"middle"}},Nc=function(e){var t=e.viewBox,n=e.offset,r=e.position,a=t.x,i=t.y,o=t.width,s=t.height,u=s>=0?1:-1;return"top"===r?{x:a+o/2,y:i-u*n,textAnchor:"middle",verticalAnchor:u>0?"end":"start"}:"bottom"===r?{x:a+o/2,y:i+s+u*n,textAnchor:"middle",verticalAnchor:"start"}:"left"===r?{x:a-n,y:i+s/2,textAnchor:"end",verticalAnchor:"middle"}:"right"===r?{x:a+o+n,y:i+s/2,textAnchor:"start",verticalAnchor:"middle"}:"insideLeft"===r?{x:a+n,y:i+s/2,textAnchor:"start",verticalAnchor:"middle"}:"insideRight"===r?{x:a+o-n,y:i+s/2,textAnchor:"end",verticalAnchor:"middle"}:"insideTop"===r?{x:a+o/2,y:i+u*n,textAnchor:"middle",verticalAnchor:"start"}:"insideBottom"===r?{x:a+o/2,y:i+s-u*n,textAnchor:"middle",verticalAnchor:"end"}:"insideTopLeft"===r?{x:a+n,y:i+u*n,textAnchor:"start",verticalAnchor:"start"}:"insideTopRight"===r?{x:a+o-n,y:i+u*n,textAnchor:"end",verticalAnchor:"start"}:"insideBottomLeft"===r?{x:a+n,y:i+s-u*n,textAnchor:"start",verticalAnchor:"end"}:"insideBottomRight"===r?{x:a+o-n,y:i+s-u*n,textAnchor:"end",verticalAnchor:"end"}:E()(r)&&(U(r.x)||z(r.x))&&(U(r.y)||z(r.y))?{x:a+J(r.x,o),y:i+J(r.y,s),textAnchor:"end",verticalAnchor:"end"}:{x:a+o/2,y:i+s/2,textAnchor:"middle",verticalAnchor:"middle"}},Ic=function(e){return U(e.cx)};function Rc(e){var t,n=e.viewBox,r=e.position,o=e.value,s=e.children,u=e.content,l=e.className,c=void 0===l?"":l;if(!n||T()(o)&&T()(s)&&!Object(a.isValidElement)(u)&&!b()(u))return null;if(Object(a.isValidElement)(u))return Object(a.cloneElement)(u,e);if(b()(u)){if(t=u(e),Object(a.isValidElement)(t))return t}else t=Ac(e);var d=Ic(n),f=le(e);if(d&&("insideStart"===r||"insideEnd"===r||"end"===r))return Cc(e,t,f);var h=d?Hc(e):Nc(e);return i.a.createElement(Yc,Dc({className:S()("recharts-label",c)},f,h),t)}Rc.displayName="Label",Rc.defaultProps={offset:5},Rc.propTypes=Pc;var Wc=function(e){var t=e.cx,n=e.cy,r=e.angle,a=e.startAngle,i=e.endAngle,o=e.r,s=e.radius,u=e.innerRadius,l=e.outerRadius,c=e.x,d=e.y,f=e.top,h=e.left,p=e.width,m=e.height,_=e.clockWise;if(U(p)&&U(m)){if(U(c)&&U(d))return{x:c,y:d,width:p,height:m};if(U(f)&&U(h))return{x:f,y:h,width:p,height:m}}return U(c)&&U(d)?{x:c,y:d,width:0,height:0}:U(t)&&U(n)?{cx:t,cy:n,startAngle:a||r||0,endAngle:i||r||0,innerRadius:u||0,outerRadius:l||s||o||0,clockWise:_}:e.viewBox?e.viewBox:{}};Rc.parseViewBox=Wc,Rc.renderCallByParent=function(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];if(!e||!e.children&&n&&!e.label)return null;var r=e.children,o=Wc(e),s=se(r,Rc).map(function(e,n){return Object(a.cloneElement)(e,{viewBox:t||o,key:"label-".concat(n)})});return n?[function(e,t){return e?!0===e?i.a.createElement(Rc,{key:"label-implicit",viewBox:t}):B(e)?i.a.createElement(Rc,{key:"label-implicit",viewBox:t,value:e}):Object(a.isValidElement)(e)||b()(e)?i.a.createElement(Rc,{key:"label-implicit",content:e,viewBox:t}):E()(e)?i.a.createElement(Rc,Dc({viewBox:t},e,{key:"label-implicit"})):null:null}(e.label,t||o)].concat(Sc(s)):s};var Fc=Rc,zc=n(104),Uc=n.n(zc);function Bc(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Gc(e,t){for(var n=0;n1&&void 0!==arguments[1]?arguments[1]:{}).bandAware;if(void 0!==e){if(t){var n=this.bandwidth?this.bandwidth()/2:0;return this.scale(e)+n}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}},{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}}]),e}();qc.EPS=1e-4;var $c,Kc,Xc,Qc=function(){function e(t){Bc(this,e),this.scales=Uc()(t,qc.create),Object.assign(this,this.scales)}return Vc(e,null,[{key:"create",value:function(e){return new this(e)}}]),Vc(e,[{key:"apply",value:function(e){var t=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).bandAware,n=this.scales;return Uc()(e,function(e,r){return n[r].apply(e,{bandAware:t})})}},{key:"isInRange",value:function(e){var t=this.scales;return p()(e,function(e,n){return t[n].isInRange(e)})}}]),e}();function Zc(e){return(Zc="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})(e)}function ed(){return(ed=Object.assign||function(e){for(var t=1;t=0?1:-1,u=r>=0?1:0;if(o>0&&a instanceof Array){for(var l=[],c=0;c<4;c++)l[c]=a[c]>o?o:a[c];i="M".concat(e,",").concat(t+s*l[0]),l[0]>0&&(i+="A ".concat(l[0],",").concat(l[0],",0,0,").concat(u,",").concat(e+l[0],",").concat(t)),i+="L ".concat(e+n-l[1],",").concat(t),l[1]>0&&(i+="A ".concat(l[1],",").concat(l[1],",0,0,").concat(u,",\n ").concat(e+n,",").concat(t+s*l[1])),i+="L ".concat(e+n,",").concat(t+r-s*l[2]),l[2]>0&&(i+="A ".concat(l[2],",").concat(l[2],",0,0,").concat(u,",\n ").concat(e+n-l[2],",").concat(t+r)),i+="L ".concat(e+l[3],",").concat(t+r),l[3]>0&&(i+="A ".concat(l[3],",").concat(l[3],",0,0,").concat(u,",\n ").concat(e,",").concat(t+r-s*l[3])),i+="Z"}else if(o>0&&a===+a&&a>0){var d=Math.min(o,a);i="M ".concat(e,",").concat(t+s*d,"\n A ").concat(d,",").concat(d,",0,0,").concat(u,",").concat(e+d,",").concat(t,"\n L ").concat(e+n-d,",").concat(t,"\n A ").concat(d,",").concat(d,",0,0,").concat(u,",").concat(e+n,",").concat(t+s*d,"\n L ").concat(e+n,",").concat(t+r-s*d,"\n A ").concat(d,",").concat(d,",0,0,").concat(u,",").concat(e+n-d,",").concat(t+r,"\n L ").concat(e+d,",").concat(t+r,"\n A ").concat(d,",").concat(d,",0,0,").concat(u,",").concat(e,",").concat(t+r-s*d," Z")}else i="M ".concat(e,",").concat(t," h ").concat(n," v ").concat(r," h ").concat(-n," Z");return i},Nd=Z((xd=wd=function(e){function t(){var e,n;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);for(var r=arguments.length,a=new Array(r),i=0;i0,from:{width:a,height:o,x:n,y:r},to:{width:a,height:o,x:n,y:r},duration:f,animationEasing:d,isActive:m},function(t){var n=t.width,r=t.height,a=t.x,o=t.y;return i.a.createElement(Jt,{canBegin:l>0,from:"0px ".concat(-1===l?1:l,"px"),to:"".concat(l,"px 0px"),attributeName:"strokeDasharray",begin:h,duration:f,isActive:p,easing:d},i.a.createElement("path",Sd({},le(e.props),de(e.props),{className:_,d:Hd(a,o,n,r,s),ref:function(t){e.node=t}})))}):i.a.createElement("path",Sd({},le(this.props),de(this.props),{className:_,d:Hd(n,r,a,o,s)}))}}])&&Dd(n.prototype,r),o&&Dd(n,o),t}(),wd.displayName="Rectangle",wd.propTypes=function(e){for(var t=1;t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}function Xd(e,t){for(var n=0;n=0});if(i&&i.length){var o=i.map(function(e){return e.props.dataKey});return e.reduce(function(e,t){var r=sf(t,n,0),a=A()(r)?[Wa()(r),Ia()(r)]:[r,r],i=o.reduce(function(e,n){var r=sf(t,n,0),i=a[0]-Math.abs(A()(r)?r[0]:r),o=a[1]+Math.abs(A()(r)?r[1]:r);return[Math.min(i,e[0]),Math.max(o,e[1])]},[1/0,-1/0]);return[Math.min(i[0],e[0]),Math.max(i[1],e[1])]},[1/0,-1/0])}return null},ff=function(e,t,n,r){var a=t.map(function(t){var a=t.props.dataKey;return"number"===n&&a&&df(e,t,a)||uf(e,a,n,r)});if("number"===n)return a.reduce(function(e,t){return[Math.min(e[0],t[0]),Math.max(e[1],t[1])]},[1/0,-1/0]);var i={};return a.reduce(function(e,t){for(var n=0,r=t.length;n=0||t.indexOf("AreaChart")>=0)?{scale:yi(),realScaleType:"point"}:"category"===a?{scale:_i(),realScaleType:"band"}:{scale:ps(),realScaleType:"linear"};if(O()(n)){var s="scale".concat(n.slice(0,1).toUpperCase()).concat(n.slice(1));return{scale:(r[s]||yi)(),realScaleType:r[s]?s:"point"}}return b()(n)?{scale:n}:{scale:yi(),realScaleType:"point"}},vf=function(e){var t=e.domain();if(t&&!(t.length<=2)){var n=t.length,r=e.range(),a=Math.min(r[0],r[1])-1e-4,i=Math.max(r[0],r[1])+1e-4,o=e(t[0]),s=e(t[n-1]);(oi||si)&&e.domain([t[0],t[n-1]])}},gf={sign:function(e){var t=e.length;if(!(t<=0))for(var n=0,r=e[0].length;n=0?(e[o][n][0]=a,e[o][n][1]=a+s,a=e[o][n][1]):(e[o][n][0]=i,e[o][n][1]=i+s,i=e[o][n][1])}},expand:function(e,t){if((r=e.length)>0){for(var n,r,a,i=0,o=e[0].length;i0){for(var n,r=0,a=e[t[0]],i=a.length;r0&&(r=(n=e[t[0]]).length)>0){for(var n,r,a,i=0,o=1;o=2){for(var n=v()(t,function(e){return e.coordinate}),r=1/0,a=1,i=n.length;a2&&void 0!==arguments[2]?arguments[2]:{top:0,right:0,bottom:0,left:0};return Math.min(Math.abs(e-(n.left||0)-(n.right||0)),Math.abs(t-(n.top||0)-(n.bottom||0)))/2},Wf=function(e,t){var n,r,a,i,o,s,u=e.x,l=e.y,c=t.cx,d=t.cy,f=(r={x:c,y:d},a=(n={x:u,y:l}).x,i=n.y,o=r.x,s=r.y,Math.sqrt(Math.pow(a-o,2)+Math.pow(i-s,2)));if(f<=0)return{radius:f};var h=(u-c)/f,p=Math.acos(h);return l>d&&(p=2*Math.PI-p),{radius:f,angle:Nf(p),angleInRadian:p}},Ff=function(e,t){var n=t.startAngle,r=t.endAngle,a=Math.floor(n/360),i=Math.floor(r/360);return e+360*Math.min(a,i)},zf=function(e,t){var n=e.x,r=e.y,a=Wf({x:n,y:r},t),i=a.radius,o=a.angle,s=t.innerRadius,u=t.outerRadius;if(iu)return!1;if(0===i)return!0;var l,c=function(e){var t=e.startAngle,n=e.endAngle,r=Math.floor(t/360),a=Math.floor(n/360),i=Math.min(r,a);return{startAngle:t-360*i,endAngle:n-360*i}}(t),d=c.startAngle,f=c.endAngle,h=o;if(d<=f){for(;h>f;)h-=360;for(;h=d&&h<=f}else{for(;h>d;)h-=360;for(;h=f&&h<=d}return l?Of({},t,{radius:i,angle:Ff(h,t)}):null};function Uf(e){return(Uf="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})(e)}function Bf(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Gf(){return(Gf=Object.assign||function(e){for(var t=1;t180),",").concat(+(i>s),",\n ").concat(l.x,",").concat(l.y,"\n ");if(r>0){var d=If(t,n,r,i),f=If(t,n,r,s);c+="L ".concat(f.x,",").concat(f.y,"\n A ").concat(r,",").concat(r,",0,\n ").concat(+(Math.abs(o)>180),",").concat(+(i<=s),",\n ").concat(d.x,",").concat(d.y," Z")}else c+="L ".concat(t,",").concat(n," Z");return c},Qf=Z((Cf=Af=function(e){function t(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),Jf(this,qf(t).apply(this,arguments))}var n,r,o;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}}),t&&$f(e,t)}(t,a["Component"]),n=t,(r=[{key:"render",value:function(){var e=this.props,t=e.cx,n=e.cy,r=e.innerRadius,a=e.outerRadius,o=e.cornerRadius,s=e.startAngle,u=e.endAngle,l=e.className;if(a0&&Math.abs(s-u)<360?function(e){var t=e.cx,n=e.cy,r=e.innerRadius,a=e.outerRadius,i=e.cornerRadius,o=e.startAngle,s=e.endAngle,u=F(s-o),l=Kf({cx:t,cy:n,radius:a,angle:o,sign:u,cornerRadius:i}),c=l.circleTangency,d=l.lineTangency,f=l.theta,h=Kf({cx:t,cy:n,radius:a,angle:s,sign:-u,cornerRadius:i}),p=h.circleTangency,m=h.lineTangency,_=h.theta,y=Math.abs(o-s)-f-_;if(y<0)return Xf({cx:t,cy:n,innerRadius:r,outerRadius:a,startAngle:o,endAngle:s});var v="M ".concat(d.x,",").concat(d.y,"\n A").concat(i,",").concat(i,",0,0,").concat(+(u<0),",").concat(c.x,",").concat(c.y,"\n A").concat(a,",").concat(a,",0,").concat(+(y>180),",").concat(+(u<0),",").concat(p.x,",").concat(p.y,"\n A").concat(i,",").concat(i,",0,0,").concat(+(u<0),",").concat(m.x,",").concat(m.y,"\n ");if(r>0){var g=Kf({cx:t,cy:n,radius:r,angle:o,sign:u,isExternal:!0,cornerRadius:i}),b=g.circleTangency,M=g.lineTangency,k=g.theta,w=Kf({cx:t,cy:n,radius:r,angle:s,sign:-u,isExternal:!0,cornerRadius:i}),x=w.circleTangency,L=w.lineTangency,T=w.theta,Y=Math.abs(o-s)-k-T;if(Y<0)return"".concat(v,"L").concat(t,",").concat(n,"Z");v+="L".concat(L.x,",").concat(L.y,"\n A").concat(i,",").concat(i,",0,0,").concat(+(u<0),",").concat(x.x,",").concat(x.y,"\n A").concat(r,",").concat(r,",0,").concat(+(Y>180),",").concat(+(u>0),",").concat(b.x,",").concat(b.y,"\n A").concat(i,",").concat(i,",0,0,").concat(+(u<0),",").concat(M.x,",").concat(M.y,"Z")}else v+="L".concat(t,",").concat(n,"Z");return v}({cx:t,cy:n,innerRadius:r,outerRadius:a,cornerRadius:Math.min(h,f/2),startAngle:s,endAngle:u}):Xf({cx:t,cy:n,innerRadius:r,outerRadius:a,startAngle:s,endAngle:u}),i.a.createElement("path",Gf({},le(this.props),de(this.props),{className:d,d:c}))}}])&&Vf(n.prototype,r),o&&Vf(n,o),t}(),Af.displayName="Sector",Af.propTypes=function(e){for(var t=1;t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}function ah(e,t){for(var n=0;n=2?F(m[1].coordinate-m[0].coordinate):1;if(1===v?(n="width"===p?c:d,r="width"===p?c+f:d+h):(n="width"===p?c+f:d+h,r="width"===p?c:d),t){var g=a[y-1],M=b()(i)?i(g.value):g.value,k=_c(M)[p]+_,w=v*(g.coordinate+v*k/2-r);m[y-1]=g=th({},g,{tickCoord:w>0?g.coordinate-w*v:g.coordinate}),v*(g.tickCoord-v*k/2-n)>=0&&v*(g.tickCoord+v*k/2-r)<=0&&(r=g.tickCoord-v*(k/2+u),m[y-1]=th({},g,{isShow:!0}))}for(var x=t?y-1:y,L=0;L=0&&v*(T.tickCoord+v*S/2-r)<=0&&(n=T.tickCoord+v*(S/2+u),m[L]=th({},T,{isShow:!0}))}return m.filter(function(e){return e.isShow})}},{key:"getTicksEnd",value:function(e){var t,n,r=e.ticks,a=e.tickFormatter,i=e.viewBox,o=e.orientation,s=e.minTickGap,u=e.unit,l=i.x,c=i.y,d=i.width,f=i.height,h="top"===o||"bottom"===o?"width":"height",p=u?_c(u)[h]:0,m=(r||[]).slice(),_=m.length,y=_>=2?F(m[1].coordinate-m[0].coordinate):1;1===y?(t="width"===h?l:c,n="width"===h?l+d:c+f):(t="width"===h?l+d:c+f,n="width"===h?l:c);for(var v=_-1;v>=0;v--){var g=m[v],M=b()(a)?a(g.value):g.value,k=_c(M)[h]+p;if(v===_-1){var w=y*(g.coordinate+y*k/2-n);m[v]=g=th({},g,{tickCoord:w>0?g.coordinate-w*y:g.coordinate})}else m[v]=g=th({},g,{tickCoord:g.coordinate});y*(g.tickCoord-y*k/2-t)>=0&&y*(g.tickCoord+y*k/2-n)<=0&&(n=g.tickCoord-y*(k/2+s),m[v]=th({},g,{isShow:!0}))}return m.filter(function(e){return e.isShow})}},{key:"renderTickItem",value:function(e,t,n){return i.a.isValidElement(e)?i.a.cloneElement(e,t):b()(e)?e(t):i.a.createElement(Yc,eh({},t,{className:"recharts-cartesian-axis-tick-value"}),n)}}],(r=[{key:"shouldComponentUpdate",value:function(e,t){var n=e.viewBox,r=rh(e,["viewBox"]),a=this.props,i=a.viewBox,o=rh(a,["viewBox"]);return!X(n,i)||!X(r,o)||!X(t,this.state)}},{key:"getTickLineCoord",value:function(e){var t,n,r,a,i,o,s=this.props,u=s.x,l=s.y,c=s.width,d=s.height,f=s.orientation,h=s.tickSize,p=s.mirror,m=s.tickMargin,_=p?-1:1,y=e.tickSize||h,v=U(e.tickCoord)?e.tickCoord:e.coordinate;switch(f){case"top":t=n=e.coordinate,o=(r=(a=l+!p*d)-_*y)-_*m,i=v;break;case"left":r=a=e.coordinate,i=(t=(n=u+!p*c)-_*y)-_*m,o=v;break;case"right":r=a=e.coordinate,i=(t=(n=u+p*c)+_*y)+_*m,o=v;break;default:t=n=e.coordinate,o=(r=(a=l+p*d)+_*y)+_*m,i=v}return{line:{x1:t,y1:r,x2:n,y2:a},tick:{x:i,y:o}}}},{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 e=this.props,t=e.x,n=e.y,r=e.width,a=e.height,o=e.orientation,s=e.axisLine,u=e.mirror,l=th({},le(this.props),{fill:"none"},le(s));if("top"===o||"bottom"===o){var c="top"===o&&!u||"bottom"===o&&u;l=th({},l,{x1:t,y1:n+c*a,x2:t+r,y2:n+c*a})}else{var d="left"===o&&!u||"right"===o&&u;l=th({},l,{x1:t+d*r,y1:n,x2:t+d*r,y2:n+a})}return i.a.createElement("line",eh({className:"recharts-cartesian-axis-line"},l))}},{key:"renderTicks",value:function(e){var n=this,r=this.props,a=r.tickLine,o=r.stroke,s=r.tick,u=r.tickFormatter,l=r.unit,c=t.getTicks(th({},this.props,{ticks:e})),d=this.getTickTextAnchor(),f=this.getTickVerticalAnchor(),h=le(this.props),p=le(s),m=th({},h,{fill:"none"},le(a)),_=c.map(function(e,t){var r=n.getTickLineCoord(e),_=r.line,y=r.tick,v=th({textAnchor:d,verticalAnchor:f},h,{stroke:"none",fill:o},p,y,{index:t,payload:e,visibleTicksCount:c.length});return i.a.createElement(Oe,eh({className:"recharts-cartesian-axis-tick",key:"tick-".concat(t)},he(n.props,e,t)),a&&i.a.createElement("line",eh({className:"recharts-cartesian-axis-tick-line"},m,_)),s&&n.constructor.renderTickItem(s,v,"".concat(b()(u)?u(e.value):e.value).concat(l||"")))});return i.a.createElement("g",{className:"recharts-cartesian-axis-ticks"},_)}},{key:"render",value:function(){var e=this.props,t=e.axisLine,n=e.width,r=e.height,a=e.ticksGenerator,o=e.className;if(e.hide)return null;var s=this.props,u=s.ticks,l=rh(s,["ticks"]),c=u;return b()(a)&&(c=u&&u.length>0?a(this.props):a(l)),n<=0||r<=0||!c||!c.length?null:i.a.createElement(Oe,{className:S()("recharts-cartesian-axis",o)},t&&this.renderAxisLine(),this.renderTicks(c),Fc.renderCallByParent(this.props))}}])&&ah(n.prototype,r),o&&ah(n,o),t}();uh.displayName="CartesianAxis",uh.propTypes=th({},ne,re,{className:s.a.string,x:s.a.number,y:s.a.number,width:s.a.number,height:s.a.number,orientation:s.a.oneOf(["top","bottom","left","right"]),viewBox:s.a.shape({x:s.a.number,y:s.a.number,width:s.a.number,height:s.a.number}),tick:s.a.oneOfType([s.a.bool,s.a.func,s.a.object,s.a.element]),axisLine:s.a.oneOfType([s.a.bool,s.a.object]),tickLine:s.a.oneOfType([s.a.bool,s.a.object]),mirror:s.a.bool,tickMargin:s.a.number.isRequired,minTickGap:s.a.number,ticks:s.a.array,tickSize:s.a.number,stroke:s.a.string,tickFormatter:s.a.func,ticksGenerator:s.a.func,interval:s.a.oneOfType([s.a.number,s.a.oneOf(["preserveStart","preserveEnd","preserveStartEnd"])])}),uh.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 lh=uh;function ch(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var dh,fh,hh,ph=["Webkit","Moz","O","ms"],mh=function(e,t){if(!e)return null;var n=e.replace(/(\w)/,function(e){return e.toUpperCase()}),r=ph.reduce(function(e,r){return function(e){for(var t=1;t0&&n.handleDrag(e.changedTouches[0])},n.handleDragEnd=function(){n.setState({isTravellerMoving:!1,isSlideMoving:!1})},n.handleLeaveWrapper=function(){(n.state.isTravellerMoving||n.state.isSlideMoving)&&(n.leaveTimer=setTimeout(n.handleDragEnd,1e3))},n.handleEnterSlideOrTraveller=function(){n.setState({isTextActive:!0})},n.handleLeaveSlideOrTraveller=function(){n.setState({isTextActive:!1})},n.handleSlideDragStart=function(e){var t=e.changedTouches&&e.changedTouches.length?e.changedTouches[0]:e;n.setState({isTravellerMoving:!1,isSlideMoving:!0,slideMoveStartX:t.pageX})},n.travellerDragStartHandlers={startX:n.handleTravellerDragStart.bind(kh(kh(n)),"startX"),endX:n.handleTravellerDragStart.bind(kh(kh(n)),"endX")},n.state=e.data&&e.data.length?n.updateScale(e):{},n}var n,r,o;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}}),t&&Mh(e,t)}(t,a["Component"]),n=t,o=[{key:"getIndexInRange",value:function(e,t){for(var n=0,r=e.length-1;r-n>1;){var a=Math.floor((n+r)/2);e[a]>t?r=a:n=a}return t>=e[r]?r:n}}],(r=[{key:"componentWillReceiveProps",value:function(e){var t=this,n=this.props,r=n.data,a=n.width,i=n.x,o=n.travellerWidth,s=n.updateId;(e.data!==r||e.updateId!==s)&&e.data&&e.data.length?this.setState(this.updateScale(e)):e.width===a&&e.x===i&&e.travellerWidth===o||(this.scale.range([e.x,e.x+e.width-e.travellerWidth]),this.scaleValues=this.scale.domain().map(function(e){return t.scale(e)}),this.setState({startX:this.scale(e.startIndex),endX:this.scale(e.endIndex)}))}},{key:"componentWillUnmount",value:function(){this.scale=null,this.scaleValues=null,this.leaveTimer&&(clearTimeout(this.leaveTimer),this.leaveTimer=null)}},{key:"getIndex",value:function(e){var t=e.startX,n=e.endX,r=this.props,a=r.gap,i=r.data.length-1,o=Math.min(t,n),s=Math.max(t,n),u=this.constructor.getIndexInRange(this.scaleValues,o),l=this.constructor.getIndexInRange(this.scaleValues,s);return{startIndex:u-u%a,endIndex:l===i?i:l-l%a}}},{key:"getTextOfTick",value:function(e){var t=this.props,n=t.data,r=t.tickFormatter,a=t.dataKey,i=sf(n[e],a,e);return b()(r)?r(i):i}},{key:"handleSlideDrag",value:function(e){var t=this.state,n=t.slideMoveStartX,r=t.startX,a=t.endX,i=this.props,o=i.x,s=i.width,u=i.travellerWidth,l=i.startIndex,c=i.endIndex,d=i.onChange,f=e.pageX-n;f>0?f=Math.min(f,o+s-u-a,o+s-u-r):f<0&&(f=Math.max(f,o-r,o-a));var h=this.getIndex({startX:r+f,endX:a+f});h.startIndex===l&&h.endIndex===c||!d||d(h),this.setState({startX:r+f,endX:a+f,slideMoveStartX:e.pageX})}},{key:"handleTravellerDragStart",value:function(e,t){var n=t.changedTouches&&t.changedTouches.length?t.changedTouches[0]:t;this.setState({isSlideMoving:!1,isTravellerMoving:!0,movingTravellerId:e,brushMoveStartX:n.pageX})}},{key:"handleTravellerMove",value:function(e){var t,n=this.state,r=n.brushMoveStartX,a=n.movingTravellerId,i=n.endX,o=n.startX,s=this.state[a],u=this.props,l=u.x,c=u.width,d=u.travellerWidth,f=u.onChange,h=u.gap,p=u.data,m={startX:this.state.startX,endX:this.state.endX},_=e.pageX-r;_>0?_=Math.min(_,l+c-d-s):_<0&&(_=Math.max(_,l-s)),m[a]=s+_;var y=this.getIndex(m),v=y.startIndex,g=y.endIndex;this.setState((vh(t={},a,s+_),vh(t,"brushMoveStartX",e.pageX),t),function(){var e;f&&(e=p.length-1,("startX"===a&&(i>o?v%h==0:g%h==0)||io?g%h==0:v%h==0)||i>o&&g===e)&&f(y))})}},{key:"updateScale",value:function(e){var t=this,n=e.data,r=e.startIndex,a=e.endIndex,i=e.x,o=e.width,s=e.travellerWidth,u=n.length;return this.scale=yi().domain(k()(0,u)).range([i,i+o-s]),this.scaleValues=this.scale.domain().map(function(e){return t.scale(e)}),{isTextActive:!1,isSlideMoving:!1,isTravellerMoving:!1,startX:this.scale(r),endX:this.scale(a)}}},{key:"renderBackground",value:function(){var e=this.props,t=e.x,n=e.y,r=e.width,a=e.height,o=e.fill,s=e.stroke;return i.a.createElement("rect",{stroke:s,fill:o,x:t,y:n,width:r,height:a})}},{key:"renderPanorama",value:function(){var e=this.props,t=e.x,n=e.y,r=e.width,o=e.height,s=e.data,u=e.children,l=e.padding,c=a.Children.only(u);return c?i.a.cloneElement(c,{x:t,y:n,width:r,height:o,margin:l,compact:!0,data:s}):null}},{key:"renderTraveller",value:function(e,t){var n=this.props,r=n.y,a=n.travellerWidth,o=n.height,s=n.stroke,u=Math.floor(r+o/2)-1,l=Math.max(e,this.props.x);return i.a.createElement(Oe,{className:"recharts-brush-traveller",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.travellerDragStartHandlers[t],onTouchStart:this.travellerDragStartHandlers[t],style:{cursor:"col-resize"}},i.a.createElement("rect",{x:l,y:r,width:a,height:o,fill:s,stroke:"none"}),i.a.createElement("line",{x1:l+1,y1:u,x2:l+a-1,y2:u,fill:"none",stroke:"#fff"}),i.a.createElement("line",{x1:l+1,y1:u+2,x2:l+a-1,y2:u+2,fill:"none",stroke:"#fff"}))}},{key:"renderSlide",value:function(e,t){var n=this.props,r=n.y,a=n.height,o=n.stroke;return i.a.createElement("rect",{className:"recharts-brush-slide",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.handleSlideDragStart,onTouchStart:this.handleSlideDragStart,style:{cursor:"move"},stroke:"none",fill:o,fillOpacity:.2,x:Math.min(e,t),y:r,width:Math.abs(t-e),height:a})}},{key:"renderText",value:function(){var e=this.props,t=e.startIndex,n=e.endIndex,r=e.y,a=e.height,o=e.travellerWidth,s=e.stroke,u=this.state,l=u.startX,c=u.endX,d={pointerEvents:"none",fill:s};return i.a.createElement(Oe,{className:"recharts-brush-texts"},i.a.createElement(Yc,yh({textAnchor:"end",verticalAnchor:"middle",x:Math.min(l,c)-5,y:r+a/2},d),this.getTextOfTick(t)),i.a.createElement(Yc,yh({textAnchor:"start",verticalAnchor:"middle",x:Math.max(l,c)+o+5,y:r+a/2},d),this.getTextOfTick(n)))}},{key:"render",value:function(){var e=this.props,t=e.data,n=e.className,r=e.children,a=e.x,o=e.y,s=e.width,u=e.height,l=this.state,c=l.startX,d=l.endX,f=l.isTextActive,h=l.isSlideMoving,p=l.isTravellerMoving;if(!t||!t.length||!U(a)||!U(o)||!U(s)||!U(u)||s<=0||u<=0)return null;var m=S()("recharts-brush",n),_=1===i.a.Children.count(r),y=mh("userSelect","none");return i.a.createElement(Oe,{className:m,onMouseMove:this.handleDrag,onMouseLeave:this.handleLeaveWrapper,onMouseUp:this.handleDragEnd,onTouchEnd:this.handleDragEnd,onTouchMove:this.handleTouchMove,style:y},this.renderBackground(),_&&this.renderPanorama(),this.renderSlide(c,d),this.renderTraveller(c,"startX"),this.renderTraveller(d,"endX"),(f||h||p)&&this.renderText())}}])&&gh(n.prototype,r),o&&gh(n,o),t}(),fh.displayName="Brush",fh.propTypes={className:s.a.string,fill:s.a.string,stroke:s.a.string,x:s.a.number,y:s.a.number,width:s.a.number,height:s.a.number.isRequired,travellerWidth:s.a.number,gap:s.a.number,padding:s.a.shape({top:s.a.number,right:s.a.number,bottom:s.a.number,left:s.a.number}),dataKey:s.a.oneOfType([s.a.string,s.a.number,s.a.func]),data:s.a.array,startIndex:s.a.number,endIndex:s.a.number,tickFormatter:s.a.func,children:s.a.node,onChange:s.a.func,updateId:s.a.oneOfType([s.a.string,s.a.number])},fh.defaultProps={height:40,travellerWidth:5,gap:1,fill:"#fff",stroke:"#666",padding:{top:1,right:1,bottom:1,left:1}},dh=hh))||dh,xh=n(302),Lh=new(n.n(xh).a);Lh.setMaxListeners&&Lh.setMaxListeners(10);var Th="recharts.syncMouseEvents";function Yh(e){return(Yh="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})(e)}function Sh(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},i=Object.keys(e);for(r=0;r=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}function Dh(){return(Dh=Object.assign||function(e){for(var t=1;t0&&n.handleMouseMove(e.changedTouches[0])},n.handleTouchStart=function(e){null!=e.changedTouches&&e.changedTouches.length>0&&n.handleMouseDown(e.changedTouches[0])},n.handleTouchEnd=function(e){null!=e.changedTouches&&e.changedTouches.length>0&&n.handleMouseUp(e.changedTouches[0])},n.verticalCoordinatesGenerator=function(e){var t=e.xAxis,n=e.width,r=e.height,a=e.offset;return pf(lh.getTicks(jh({},lh.defaultProps,t,{ticks:mf(t,!0),viewBox:{x:0,y:0,width:n,height:r}})),a.left,a.left+a.width)},n.horizontalCoordinatesGenerator=function(e){var t=e.yAxis,n=e.width,r=e.height,a=e.offset;return pf(lh.getTicks(jh({},lh.defaultProps,t,{ticks:mf(t,!0),viewBox:{x:0,y:0,width:n,height:r}})),a.top,a.top+a.height)},n.axesTicksGenerator=function(e){return mf(e,!0)},n.tooltipTicksGenerator=function(e){var t=q(e),n=mf(t,!1,!0);return{tooltipTicks:n,orderedTooltipTicks:v()(n,function(e){return e.coordinate}),tooltipAxis:t,tooltipAxisBandSize:Sf(t)}},n.renderCursor=function(e){var r=n.state,i=r.isTooltipActive,o=r.activeCoordinate,s=r.activePayload,u=r.offset;if(!(e&&e.props.cursor&&i&&o))return null;var l,c=n.props.layout,d=Sa;if("ScatterChart"===t)l=o,d=Ha;else if("BarChart"===t)l=n.getCursorRectangle(),d=Nd;else if("radial"===c){var f=n.getCursorPoints(),h=f.cx,p=f.cy,m=f.radius;l={cx:h,cy:p,startAngle:f.startAngle,endAngle:f.endAngle,innerRadius:m,outerRadius:m},d=Qf}else l={points:n.getCursorPoints()},d=Sa;var _=e.key||"_recharts-cursor",y=jh({stroke:"#ccc",pointerEvents:"none"},u,l,le(e.props.cursor),{payload:s,key:_,className:"recharts-tooltip-cursor"});return Object(a.isValidElement)(e.props.cursor)?Object(a.cloneElement)(e.props.cursor,y):Object(a.createElement)(d,y)},n.renderPolarAxis=function(e,t,r){var i=e.type.axisType,o=n.state["".concat(i,"Map")][e.props["".concat(i,"Id")]];return Object(a.cloneElement)(e,jh({},o,{className:i,key:e.key||"".concat(t,"-").concat(r),ticks:mf(o,!0)}))},n.renderXAxis=function(e,t,r){var a=n.state.xAxisMap[e.props.xAxisId];return n.renderAxis(a,e,t,r)},n.renderYAxis=function(e,t,r){var a=n.state.yAxisMap[e.props.yAxisId];return n.renderAxis(a,e,t,r)},n.renderGrid=function(e){var t=n.state,r=t.xAxisMap,i=t.yAxisMap,o=t.offset,s=n.props,u=s.width,l=s.height,c=q(r),d=_()(i,function(e){return p()(e.domain,Number.isFinite)})||q(i),f=e.props||{};return Object(a.cloneElement)(e,{key:e.key||"grid",x:U(f.x)?f.x:o.left,y:U(f.y)?f.y:o.top,width:U(f.width)?f.width:o.width,height:U(f.height)?f.height:o.height,xAxis:c,yAxis:d,offset:o,chartWidth:u,chartHeight:l,verticalCoordinatesGenerator:f.verticalCoordinatesGenerator||n.verticalCoordinatesGenerator,horizontalCoordinatesGenerator:f.horizontalCoordinatesGenerator||n.horizontalCoordinatesGenerator})},n.renderPolarGrid=function(e){var t=n.state,r=t.radiusAxisMap,i=t.angleAxisMap,o=q(r),s=q(i),u=s.cx,l=s.cy,c=s.innerRadius,d=s.outerRadius;return Object(a.cloneElement)(e,{polarAngles:mf(s,!0).map(function(e){return e.coordinate}),polarRadius:mf(o,!0).map(function(e){return e.coordinate}),cx:u,cy:l,innerRadius:c,outerRadius:d,key:e.key||"polar-grid"})},n.renderBrush=function(e){var t=n.props,r=t.margin,i=t.data,o=n.state,s=o.offset,u=o.dataStartIndex,l=o.dataEndIndex,c=o.updateId;return Object(a.cloneElement)(e,{key:e.key||"_recharts-brush",onChange:_f(n.handleBrushChange,null,e.props.onChange),data:i,x:U(e.props.x)?e.props.x:s.left,y:U(e.props.y)?e.props.y:s.top+s.height+s.brushBottom-(r.bottom||0),width:U(e.props.width)?e.props.width:s.width,startIndex:u,endIndex:l,updateId:"brush-".concat(c)})},n.renderReferenceElement=function(e,t,r){if(!e)return null;var i=Hh(Hh(n)).clipPathId,o=n.state,s=o.xAxisMap,u=o.yAxisMap,l=o.offset,c=e.props,d=c.xAxisId,f=c.yAxisId;return Object(a.cloneElement)(e,{key:e.key||"".concat(t,"-").concat(r),xAxis:s[d],yAxis:u[f],viewBox:{x:l.left,y:l.top,width:l.width,height:l.height},clipPathId:i})},n.renderGraphicChild=function(e,t,r){var i=n.filterFormatItem(e,t,r);if(!i)return null;var o,s,u=Object(a.cloneElement)(e,i.props),l=n.state,c=l.isTooltipActive,d=l.tooltipAxis,f=l.activeTooltipIndex,h=l.activeLabel,p=n.props.children,m=ue(p,yn),_=i.props,y=_.points,v=_.isRange,g=_.baseLine,b=i.item.props,M=b.activeDot;return!b.hide&&c&&m&&M&&f>=0&&(d.dataKey&&!d.allowDuplicatedCategory?(o=K(y,"payload.".concat(d.dataKey),h),s=v&&g&&K(g,"payload.".concat(d.dataKey),h)):(o=y[f],s=v&&g&&g[f]),!T()(o))?[u].concat(Oh(n.renderActivePoints({item:i,activePoint:o,basePoint:s,childIndex:f,isRange:v}))):v?[u,null,null]:[u,null]};var s=n.constructor.createDefaultState(e);return n.state=jh({},s,{updateId:0},n.updateStateOfAxisMapsOffsetAndStackGroups(jh({props:e},s,{updateId:0}))),n.uniqueChartId=T()(e.id)?V("recharts"):e.id,n.clipPathId="".concat(n.uniqueChartId,"-clip"),e.throttleDelay&&(n.triggeredAfterMouseMove=x()(n.triggeredAfterMouseMove,e.throttleDelay)),n}var s,d,f;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}}),t&&Ch(e,t)}(r,a.Component),s=r,f=[{key:"getAxisNameByLayout",value: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"}}},{key:"renderActiveDot",value:function(e,t){var n;return n=Object(a.isValidElement)(e)?Object(a.cloneElement)(e,t):b()(e)?e(t):i.a.createElement(sc,t),i.a.createElement(Oe,{className:"recharts-active-dot",key:t.key},n)}}],(d=[{key:"componentDidMount",value:function(){T()(this.props.syncId)||this.addListener()}},{key:"componentWillReceiveProps",value:function(e){var t=this,n=this.props,r=n.data,a=n.children,i=n.width,o=n.height,s=n.layout,u=n.stackOffset,l=n.margin,c=this.state.updateId;if(e.data===r&&e.width===i&&e.height===o&&e.layout===s&&e.stackOffset===u&&X(e.margin,l)){if(!ve(e.children,a)){var d=T()(e.data)?c+1:c;this.setState(function(n){return jh({updateId:d},t.updateStateOfAxisMapsOffsetAndStackGroups(jh({props:e},n,{updateId:d})))})}}else{var f=this.constructor.createDefaultState(e);this.setState(jh({},f,{updateId:c+1},this.updateStateOfAxisMapsOffsetAndStackGroups(jh({props:e},f,{updateId:c+1}))))}T()(this.props.syncId)&&!T()(e.syncId)&&this.addListener(),!T()(this.props.syncId)&&T()(e.syncId)&&this.removeListener()}},{key:"componentWillUnmount",value:function(){T()(this.props.syncId)||this.removeListener(),"function"==typeof this.triggeredAfterMouseMove.cancel&&this.triggeredAfterMouseMove.cancel()}},{key:"getAxisMap",value:function(e,t){var n=t.axisType,r=void 0===n?"xAxis":n,a=t.AxisComp,i=t.graphicalItems,o=t.stackGroups,s=t.dataStartIndex,u=t.dataEndIndex,l=e.children,c="".concat(r,"Id"),d=se(l,a),f={};return d&&d.length?f=this.getAxisMapByAxes(e,{axes:d,graphicalItems:i,axisType:r,axisIdKey:c,stackGroups:o,dataStartIndex:s,dataEndIndex:u}):i&&i.length&&(f=this.getAxisMapByItems(e,{Axis:a,graphicalItems:i,axisType:r,axisIdKey:c,stackGroups:o,dataStartIndex:s,dataEndIndex:u})),f}},{key:"getAxisMapByAxes",value:function(e,t){var n=this,r=t.axes,a=t.graphicalItems,i=t.axisType,o=t.axisIdKey,s=t.stackGroups,u=t.dataStartIndex,l=t.dataEndIndex,c=e.layout,d=e.children,f=e.stackOffset,h=hf(c,i);return r.reduce(function(t,r){var p=r.props,m=p.type,_=p.dataKey,y=p.allowDataOverflow,v=p.allowDuplicatedCategory,g=p.scale,b=p.ticks,M=r.props[o],w=n.constructor.getDisplayedData(e,{graphicalItems:a.filter(function(e){return e.props[o]===M}),dataStartIndex:u,dataEndIndex:l}),x=w.length;if(!t[M]){var L,Y,S;if(_){if(L=uf(w,_,m),"category"===m&&h){var D=function(e){if(!A()(e))return!1;for(var t=e.length,n={},r=0;r=0?e:Oh(e).concat([t])},[]))}else if("category"===m)L=v?L.filter(function(e){return""!==e&&!T()(e)}):Df(r.props.domain,L,r).reduce(function(e,t){return e.indexOf(t)>=0||""===t||T()(t)?e:Oh(e).concat([t])},[]);else if("number"===m){var O=function(e,t,n,r){var a=t.map(function(t){return df(e,t,n,r)}).filter(function(e){return!T()(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}(w,a.filter(function(e){return e.props[o]===M&&!e.props.hide}),_,i);O&&(L=O)}!h||"number"!==m&&"auto"===g||(S=uf(w,_,"category"))}else L=h?k()(0,x):s&&s[M]&&s[M].hasStack&&"number"===m?"expand"===f?[0,1]:xf(s[M].stackGroups,u,l):ff(w,a.filter(function(e){return e.props[o]===M&&!e.props.hide}),m,!0);return"number"===m&&(L=wf(d,L,M,i,b),r.props.domain&&(L=Yf(r.props.domain,L,y))),jh({},t,Eh({},M,jh({},r.props,{axisType:i,domain:L,categoricalDomain:S,duplicateDomain:Y,originalDomain:r.props.domain,isCategorial:h,layout:c})))}return t},{})}},{key:"getAxisMapByItems",value:function(e,t){var n=t.graphicalItems,r=t.Axis,a=t.axisType,i=t.axisIdKey,o=t.stackGroups,s=t.dataStartIndex,u=t.dataEndIndex,l=e.layout,c=e.children,d=this.constructor.getDisplayedData(e,{graphicalItems:n,dataStartIndex:s,dataEndIndex:u}),f=d.length,h=hf(l,a),p=-1;return n.reduce(function(e,t){var m,_=t.props[i];return e[_]?e:(p++,h?m=k()(0,f):o&&o[_]&&o[_].hasStack?(m=xf(o[_].stackGroups,s,u),m=wf(c,m,_,a)):(m=Yf(r.defaultProps.domain,ff(d,n.filter(function(e){return e.props[i]===_&&!e.props.hide}),"number"),r.defaultProps.allowDataOverflow),m=wf(c,m,_,a)),jh({},e,Eh({},_,jh({axisType:a},r.defaultProps,{hide:!0,orientation:Wh[a]&&Wh[a][p%2],domain:m,originalDomain:r.defaultProps.domain,isCategorial:h,layout:l}))))},{})}},{key:"getActiveCoordinate",value:function(e,t,n){var r=this.props.layout,a=e.find(function(e){return e&&e.index===t});if(a){if("horizontal"===r)return{x:a.coordinate,y:n.y};if("vertical"===r)return{x:n.x,y:a.coordinate};if("centric"===r){var i=a.coordinate,o=n.radius;return jh({},n,If(n.cx,n.cy,o,i),{angle:i,radius:o})}var s=a.coordinate,u=n.angle;return jh({},n,If(n.cx,n.cy,s,u),{angle:u,radius:s})}return Fh}},{key:"getMouseInfo",value:function(e){if(!this.container)return null;var t,n,r,a=function(e,t){return{chartX:Math.round(e.pageX-t.left),chartY:Math.round(e.pageY-t.top)}}(e,(t=this.container,n=t.ownerDocument.documentElement,r={top:0,left:0},void 0!==t.getBoundingClientRect&&(r=t.getBoundingClientRect()),{top:r.top+window.pageYOffset-n.clientTop,left:r.left+window.pageXOffset-n.clientLeft})),i=this.inRange(a.chartX,a.chartY);if(!i)return null;var s=this.state,u=s.xAxisMap,l=s.yAxisMap;if("axis"!==o&&u&&l){var c=q(u).scale,d=q(l).scale;return jh({},a,{xValue:c&&c.invert?c.invert(a.chartX):null,yValue:d&&d.invert?d.invert(a.chartY):null})}var f=this.state,h=f.orderedTooltipTicks,p=f.tooltipAxis,m=f.tooltipTicks,_=function(e,t,n,r){var a=-1,i=t.length;if(i>1){if(r&&"angleAxis"===r.axisType&&Math.abs(Math.abs(r.range[1]-r.range[0])-360)<=1e-6)for(var o=r.range,s=0;s0?n[s-1].coordinate:n[i-1].coordinate,l=n[s].coordinate,c=s>=i-1?n[0].coordinate:n[s+1].coordinate,d=void 0;if(F(l-u)!==F(c-l)){var f=[];if(F(c-l)===F(o[1]-o[0])){d=c;var h=l+o[1]-o[0];f[0]=Math.min(h,(h+u)/2),f[1]=Math.max(h,(h+u)/2)}else{d=u;var p=c+o[1]-o[0];f[0]=Math.min(l,(p+l)/2),f[1]=Math.max(l,(p+l)/2)}var m=[Math.min(l,(d+l)/2),Math.max(l,(d+l)/2)];if(e>m[0]&&e<=m[1]||e>=f[0]&&e<=f[1]){a=n[s].index;break}}else{var _=Math.min(u,c),y=Math.max(u,c);if(e>(_+l)/2&&e<=(y+l)/2){a=n[s].index;break}}}else for(var v=0;v0&&v(t[v].coordinate+t[v-1].coordinate)/2&&e<=(t[v].coordinate+t[v+1].coordinate)/2||v===i-1&&e>(t[v].coordinate+t[v-1].coordinate)/2){a=t[v].index;break}}else a=0;return a}(this.calculateTooltipPos(i),h,m,p);if(_>=0&&m){var y=m[_]&&m[_].value;return jh({},a,{activeTooltipIndex:_,activeLabel:y,activePayload:this.getTooltipContent(_,y),activeCoordinate:this.getActiveCoordinate(h,_,i)})}return null}},{key:"getTooltipContent",value:function(e,t){var n=this.state,r=n.graphicalItems,a=n.tooltipAxis,i=this.constructor.getDisplayedData(this.props,this.state);return e<0||!r||!r.length||e>=i.length?null:r.reduce(function(n,r){if(r.props.hide)return n;var o,s=r.props,u=s.dataKey,l=s.name,c=s.unit,d=s.formatter,f=s.data;return(o=a.dataKey&&!a.allowDuplicatedCategory?K(f||i,a.dataKey,t):i[e])?Oh(n).concat([jh({},le(r),{dataKey:u,unit:c,formatter:d,name:l||u,color:lf(r),value:sf(o,u),payload:o})]):n},[])}},{key:"getFormatItems",value:function(e,t){var n=this,r=t.graphicalItems,i=t.stackGroups,o=t.offset,s=t.updateId,l=t.dataStartIndex,c=t.dataEndIndex,d=e.barSize,f=e.layout,h=e.barGap,p=e.barCategoryGap,m=e.maxBarSize,_=this.constructor.getAxisNameByLayout(f),y=_.numericAxisName,v=_.cateAxisName,g=this.constructor.hasBar(r),b=g&&function(e){var t=e.barSize,n=e.stackGroups,r=void 0===n?{}:n;if(!r)return{};for(var a={},i=Object.keys(r),o=0,s=i.length;o=0});if(m&&m.length){var _=m[0].props.barSize,y=m[0].props[p];a[y]||(a[y]=[]),a[y].push({item:m[0],stackList:m.slice(1),barSize:T()(_)?t:_})}}return a}({barSize:d,stackGroups:i}),M=[];return r.forEach(function(r,d){var _,k,w,x,L=n.constructor.getDisplayedData(e,{dataStartIndex:l,dataEndIndex:c},r),Y=r.props,S=Y.dataKey,D=Y.maxBarSize,O=r.props["".concat(y,"Id")],j=r.props["".concat(v,"Id")],E=u.reduce(function(e,n){var a,i=t["".concat(n.axisType,"Map")],o=r.props["".concat(n.axisType,"Id")],s=i&&i[o];return jh({},e,(Eh(a={},n.axisType,s),Eh(a,"".concat(n.axisType,"Ticks"),mf(s)),a))},{}),P=E[v],A=E["".concat(v,"Ticks")],C=i&&i[O]&&i[O].hasStack&&function(e,t){var n=e.props.stackId;if(B(n)){var r=t[n];if(r&&r.items.length){for(var a=-1,i=0,o=r.items.length;i=0?r.stackedData[a]:null}}return null}(r,i[O].stackGroups),H=Sf(P,A),N=T()(D)?m:D,I=g&&function(e){var t=e.barGap,n=e.barCategoryGap,r=e.bandSize,a=e.sizeList,i=void 0===a?[]:a,o=e.maxBarSize,s=i.length;if(s<1)return null;var u,l=J(t,r,0,!0);if(i[0].barSize===+i[0].barSize){var c=!1,d=r/s,f=i.reduce(function(e,t){return e+t.barSize||0},0);(f+=(s-1)*l)>=r&&(f-=(s-1)*l,l=0),f>=r&&d>0&&(c=!0,f=s*(d*=.9));var h={offset:((r-f)/2>>0)-l,size:0};u=i.reduce(function(e,t){var n=rf(e).concat([{item:t.item,position:{offset:h.offset+h.size+l,size:c?d:t.barSize}}]);return h=n[n.length-1].position,t.stackList&&t.stackList.length&&t.stackList.forEach(function(e){n.push({item:e,position:h})}),n},[])}else{var p=J(n,r,0,!0);r-2*p-(s-1)*l<=0&&(l=0);var m=(r-2*p-(s-1)*l)/s;m>1&&(m>>=0);var _=o===+o?Math.min(m,o):m;u=i.reduce(function(e,t,n){var r=rf(e).concat([{item:t.item,position:{offset:p+(m+l)*n+(m-_)/2,size:_}}]);return t.stackList&&t.stackList.length&&t.stackList.forEach(function(e){r.push({item:e,position:r[r.length-1].position})}),r},[])}return u}({barGap:h,barCategoryGap:p,bandSize:H,sizeList:b[j],maxBarSize:N}),R=r&&r.type&&r.type.getComposedData;R&&M.push({props:jh({},R(jh({},E,{displayedData:L,props:e,dataKey:S,item:r,bandSize:H,barPosition:I,offset:o,stackedData:C,layout:f,dataStartIndex:l,dataEndIndex:c,onItemMouseLeave:_f(n.handleItemMouseLeave,null,r.props.onMouseLeave),onItemMouseEnter:_f(n.handleItemMouseEnter,null,r.props.onMouseEnter)})),(_={key:r.key||"item-".concat(d)},Eh(_,y,E[y]),Eh(_,v,E[v]),Eh(_,"animationId",s),_)),childIndex:(k=r,w=e.children,x=-1,a.Children.forEach(w,function(e,t){e===k&&(x=t)}),x),item:r})}),M}},{key:"getCursorRectangle",value:function(){var e=this.props.layout,t=this.state,n=t.activeCoordinate,r=t.offset,a=t.tooltipAxisBandSize,i=a/2;return{stroke:"none",fill:"#ccc",x:"horizontal"===e?n.x-i:r.left+.5,y:"horizontal"===e?r.top+.5:n.y-i,width:"horizontal"===e?a:r.width-1,height:"horizontal"===e?r.height-1:a}}},{key:"getCursorPoints",value:function(){var e,t,n,r,a=this.props.layout,i=this.state,o=i.activeCoordinate,s=i.offset;if("horizontal"===a)n=e=o.x,t=s.top,r=s.top+s.height;else if("vertical"===a)r=t=o.y,e=s.left,n=s.left+s.width;else if(!T()(o.cx)||!T()(o.cy)){if("centric"!==a){var u=o.cx,l=o.cy,c=o.radius,d=o.startAngle,f=o.endAngle;return{points:[If(u,l,c,d),If(u,l,c,f)],cx:u,cy:l,radius:c,startAngle:d,endAngle:f}}var h=o.cx,p=o.cy,m=o.innerRadius,_=o.outerRadius,y=o.angle,v=If(h,p,m,y),g=If(h,p,_,y);e=v.x,t=v.y,n=g.x,r=g.y}return[{x:e,y:t},{x:n,y:r}]}},{key:"calculateTooltipPos",value:function(e){var t=this.props.layout;return"horizontal"===t?e.x:"vertical"===t?e.y:"centric"===t?e.angle:e.radius}},{key:"inRange",value:function(e,t){var n=this.props.layout;if("horizontal"===n||"vertical"===n){var r=this.state.offset;return e>=r.left&&e<=r.left+r.width&&t>=r.top&&t<=r.top+r.height?{x:e,y:t}:null}var a=this.state,i=a.angleAxisMap,o=a.radiusAxisMap;if(i&&o){var s=q(i);return zf({x:e,y:t},s)}return null}},{key:"parseEventsOfWrapper",value:function(){var e=this.props.children,t=ue(e,yn)&&"axis"===o?{onMouseEnter:this.handleMouseEnter,onMouseMove:this.handleMouseMove,onMouseLeave:this.handleMouseLeave,onTouchMove:this.handleTouchMove,onTouchStart:this.handleTouchStart,onTouchEnd:this.handleTouchEnd}:{};return jh({},de(this.props,this.handleOuterEvent),t)}},{key:"updateStateOfAxisMapsOffsetAndStackGroups",value:function(e){var r=this,a=e.props,i=e.dataStartIndex,o=e.dataEndIndex,s=e.updateId;if(!pe({props:a}))return null;var l=a.children,d=a.layout,f=a.stackOffset,h=a.data,p=a.reverseStackOrder,m=this.constructor.getAxisNameByLayout(d),_=m.numericAxisName,y=m.cateAxisName,v=se(l,n),g=function(e,t,n,r,a,i){if(!e)return null;var o=(i?t.reverse():t).reduce(function(e,t){var a=t.props,i=a.stackId;if(a.hide)return e;var o=t.props[n],s=e[o]||{hasStack:!1,stackGroups:{}};if(B(i)){var u=s.stackGroups[i]||{numericAxisId:n,cateAxisId:r,items:[]};u.items.push(t),s.hasStack=!0,s.stackGroups[i]=u}else s.stackGroups[V("_stackId_")]={numericAxisId:n,cateAxisId:r,items:[t]};return af({},e,of({},o,s))},{});return Object.keys(o).reduce(function(t,i){var s=o[i];return s.hasStack&&(s.stackGroups=Object.keys(s.stackGroups).reduce(function(t,i){var o=s.stackGroups[i];return af({},t,of({},i,{numericAxisId:n,cateAxisId:r,items:o.items,stackedData:bf(e,o.items,a)}))},{})),af({},t,of({},i,s))},{})}(h,v,"".concat(_,"Id"),"".concat(y,"Id"),f,p),b=u.reduce(function(e,t){return jh({},e,Eh({},"".concat(t.axisType,"Map"),r.getAxisMap(a,jh({},t,{graphicalItems:v,stackGroups:t.axisType===_&&g,dataStartIndex:i,dataEndIndex:o}))))},{}),M=this.calculateOffset(jh({},b,{props:a,graphicalItems:v}));Object.keys(b).forEach(function(e){b[e]=c(a,b[e],M,e.replace("Map",""),t)});var k=b["".concat(y,"Map")],w=this.tooltipTicksGenerator(k),x=this.getFormatItems(a,jh({},b,{dataStartIndex:i,dataEndIndex:o,updateId:s,graphicalItems:v,stackGroups:g,offset:M}));return jh({formatedGraphicalItems:x,graphicalItems:v,offset:M,stackGroups:g},w,b)}},{key:"addListener",value:function(){Lh.on(Th,this.handleReceiveSyncEvent),Lh.setMaxListeners&&Lh._maxListeners&&Lh.setMaxListeners(Lh._maxListeners+1)}},{key:"removeListener",value:function(){Lh.removeListener(Th,this.handleReceiveSyncEvent),Lh.setMaxListeners&&Lh._maxListeners&&Lh.setMaxListeners(Lh._maxListeners-1)}},{key:"calculateOffset",value:function(e){var t=e.props,n=e.graphicalItems,r=e.xAxisMap,a=void 0===r?{}:r,i=e.yAxisMap,o=void 0===i?{}:i,s=t.width,u=t.height,l=t.children,c=t.margin||{},d=ue(l,wh),f=ue(l,fa),h=Object.keys(o).reduce(function(e,t){var n=o[t],r=n.orientation;return n.mirror||n.hide?e:jh({},e,Eh({},r,e[r]+n.width))},{left:c.left||0,right:c.right||0}),p=Object.keys(a).reduce(function(e,t){var n=a[t],r=n.orientation;return n.mirror||n.hide?e:jh({},e,Eh({},r,e[r]+n.height))},{top:c.top||0,bottom:c.bottom||0}),m=jh({},p,h),_=m.bottom;return d&&(m.bottom+=d.props.height||wh.defaultProps.height),f&&this.legendInstance&&(m=function(e,t,n,r){var a=n.children,i=n.width,o=n.height,s=n.margin,u=i-(s.left||0)-(s.right||0),l=o-(s.top||0)-(s.bottom||0),c=cf({children:a,items:t,legendWidth:u,legendHeight:l}),d=e;if(c){var f=r||{},h=c.align,p=c.verticalAlign,m=c.layout;("vertical"===m||"horizontal"===m&&"center"===p)&&U(e[h])&&(d=af({},e,of({},h,d[h]+(f.width||0)))),("horizontal"===m||"vertical"===m&&"center"===h)&&U(e[p])&&(d=af({},e,of({},p,d[p]+(f.height||0))))}return d}(m,n,t,this.legendInstance.getBBox())),jh({brushBottom:_},m,{width:s-m.left-m.right,height:u-m.top-m.bottom})}},{key:"triggerSyncEvent",value:function(e){var t=this.props.syncId;T()(t)||Lh.emit(Th,t,this.uniqueChartId,e)}},{key:"filterFormatItem",value:function(e,t,n){for(var r=this.state.formatedGraphicalItems,a=0,i=r.length;a=0})},h.getDisplayedData=function(e,t,n){var r=t.graphicalItems,a=t.dataStartIndex,i=t.dataEndIndex,o=(r||[]).reduce(function(e,t){var n=t.props.data;return n&&n.length?Oh(e).concat(Oh(n)):e},[]);if(o&&o.length>0)return o;if(n&&n.props&&n.props.data&&n.props.data.length>0)return n.props.data;var s=e.data;return s&&s.length&&U(a)&&U(i)?s.slice(a,i+1):[]},h};function Uh(e){return(Uh="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})(e)}function Bh(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Gh(){return(Gh=Object.assign||function(e){for(var t=1;t1e-5?"outer"===t?"start":"end":n<-1e-5?"outer"===t?"end":"start":"middle"}},{key:"renderAxisLine",value:function(){var e=this.props,t=e.cx,n=e.cy,r=e.radius,a=e.axisLine,o=e.axisLineType,s=rp({},le(this.props),{fill:"none"},le(a));if("circle"===o)return i.a.createElement(sc,np({className:"recharts-polar-angle-axis-line"},s,{cx:t,cy:n,r:r}));var u=this.props.ticks.map(function(e){return If(t,n,r,e.coordinate)});return i.a.createElement(ep,np({className:"recharts-polar-angle-axis-line"},s,{points:u}))}},{key:"renderTicks",value:function(){var e=this,t=this.props,n=t.ticks,r=t.tick,a=t.tickLine,o=t.tickFormatter,s=t.stroke,u=le(this.props),l=le(r),c=rp({},u,{fill:"none"},le(a)),d=n.map(function(t,n){var d=e.getTickLineCoord(t),f=rp({textAnchor:e.getTickTextAnchor(t)},u,{stroke:"none",fill:s},l,{index:n,payload:t,x:d.x2,y:d.y2});return i.a.createElement(Oe,np({className:"recharts-polar-angle-axis-tick",key:"tick-".concat(n)},he(e.props,t,n)),a&&i.a.createElement("line",np({className:"recharts-polar-angle-axis-tick-line"},c,d)),r&&e.constructor.renderTickItem(r,f,o?o(t.value):t.value))});return i.a.createElement(Oe,{className:"recharts-polar-angle-axis-ticks"},d)}},{key:"render",value:function(){var e=this.props,t=e.ticks,n=e.radius,r=e.axisLine;return n<=0||!t||!t.length?null:i.a.createElement(Oe,{className:"recharts-polar-angle-axis"},r&&this.renderAxisLine(),this.renderTicks())}}])&&ip(n.prototype,r),o&&ip(n,o),t}(),Xh.displayName="PolarAngleAxis",Xh.axisType="angleAxis",Xh.propTypes=rp({},ne,re,{type:s.a.oneOf(["number","category"]),angleAxisId:s.a.oneOfType([s.a.string,s.a.number]),dataKey:s.a.oneOfType([s.a.number,s.a.string,s.a.func]),cx:s.a.number,cy:s.a.number,radius:s.a.oneOfType([s.a.number,s.a.string]),hide:s.a.bool,scale:s.a.oneOfType([s.a.oneOf(["auto","linear","pow","sqrt","log","identity","time","band","point","ordinal","quantile","quantize","utc","sequential","threshold"]),s.a.func]),axisLine:s.a.oneOfType([s.a.bool,s.a.object]),axisLineType:s.a.oneOf(["polygon","circle"]),tickLine:s.a.oneOfType([s.a.bool,s.a.object]),tick:s.a.oneOfType([s.a.bool,s.a.func,s.a.object,s.a.element]),ticks:s.a.arrayOf(s.a.shape({value:s.a.any,coordinate:s.a.number})),stroke:s.a.string,orientation:s.a.oneOf(["inner","outer"]),tickFormatter:s.a.func,allowDuplicatedCategory:s.a.bool}),Xh.defaultProps={type:"category",angleAxisId:0,scale:"auto",cx:0,cy:0,domain:[0,"auto"],orientation:"outer",axisLine:!0,tickLine:!0,tick:!0,hide:!1,allowDuplicatedCategory:!0},Kh=Qh))||Kh,pp=n(304),mp=n.n(pp),_p=n(305),yp=n.n(_p);function vp(e){return(vp="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})(e)}function gp(){return(gp=Object.assign||function(e){for(var t=1;t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}function wp(e,t){for(var n=0;n=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var Cp={id:s.a.string,data:s.a.arrayOf(s.a.object),valueAccessor:s.a.func,clockWise:s.a.bool,dataKey:s.a.oneOfType([s.a.string,s.a.number,s.a.func])},Hp={valueAccessor:function(e){return A()(e.value)?Dp()(e.value):e.value}};function Np(e){var t=e.data,n=e.valueAccessor,r=e.dataKey,a=e.clockWise,o=e.id,s=Ap(e,["data","valueAccessor","dataKey","clockWise","id"]);return t&&t.length?i.a.createElement(Oe,{className:"recharts-label-list"},t.map(function(e,t){var u=T()(r)?n(e,t):sf(e&&e.payload,r),l=T()(o)?{}:{id:"".concat(o,"-").concat(t)};return i.a.createElement(Fc,jp({},le(e),s,l,{index:t,value:u,viewBox:Fc.parseViewBox(T()(a)?e:Ep({},e,{clockWise:a})),key:"label-".concat(t)}))})):null}Np.propTypes=Cp,Np.displayName="LabelList";Np.renderCallByParent=function(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];if(!e||!e.children&&n&&!e.label)return null;var r=e.children,o=se(r,Np).map(function(e,n){return Object(a.cloneElement)(e,{data:t,key:"labelList-".concat(n)})});return n?[function(e,t){return e?!0===e?i.a.createElement(Np,{key:"labelList-implicit",data:t}):i.a.isValidElement(e)||b()(e)?i.a.createElement(Np,{key:"labelList-implicit",data:t,content:e}):E()(e)?i.a.createElement(Np,jp({data:t},e,{key:"labelList-implicit"})):null:null}(e.label,t)].concat(Op(o)):o},Np.defaultProps=Hp;var Ip=Np;function Rp(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Wp(){return null}Wp.propTypes=function(e){for(var t=1;tt?"start":e0?e.paddingAngle:0;if(n){var s=$(n.endAngle-n.startAngle,e.endAngle-e.startAngle),u=Jp({},e,{startAngle:o+i,endAngle:o+s(r)+i});a.push(u),o=u.endAngle}else{var c=e.endAngle,d=e.startAngle,f=$(0,c-d)(r),h=Jp({},e,{startAngle:o+i,endAngle:o+f+i});a.push(h),o=h.endAngle}}),i.a.createElement(Oe,null,e.renderSectorsStatically(a))})}},{key:"renderSectors",value:function(){var e=this.props,t=e.sectors,n=e.isAnimationActive,r=this.state.prevSectors;return!(n&&t&&t.length)||r&&Ee()(r,t)?this.renderSectorsStatically(t):this.renderSectorsWithAnimation()}},{key:"render",value:function(){var e=this.props,t=e.hide,n=e.sectors,r=e.className,a=e.label,o=e.cx,s=e.cy,u=e.innerRadius,l=e.outerRadius,c=e.isAnimationActive,d=e.prevSectors,f=e.id;if(t||!n||!n.length||!U(o)||!U(s)||!U(u)||!U(l))return null;var h=S()("recharts-pie",r);return i.a.createElement(Oe,{className:h},i.a.createElement("g",{clipPath:"url(#".concat(T()(f)?this.id:f,")")},this.renderSectors()),a&&this.renderLabels(n),Fc.renderCallByParent(this.props,null,!1),(!c||d&&Ee()(d,n))&&Ip.renderCallByParent(this.props,n,!1))}}])&&$p(n.prototype,r),o&&$p(n,o),t}(),zp.displayName="Pie",zp.propTypes=Jp({},ne,re,{className:s.a.string,animationId:s.a.number,cx:s.a.oneOfType([s.a.number,s.a.string]),cy:s.a.oneOfType([s.a.number,s.a.string]),startAngle:s.a.number,endAngle:s.a.number,paddingAngle:s.a.number,innerRadius:s.a.oneOfType([s.a.number,s.a.string]),outerRadius:s.a.oneOfType([s.a.number,s.a.string]),cornerRadius:s.a.oneOfType([s.a.number,s.a.string]),dataKey:s.a.oneOfType([s.a.string,s.a.number,s.a.func]).isRequired,nameKey:s.a.oneOfType([s.a.string,s.a.number,s.a.func]),valueKey:s.a.oneOfType([s.a.string,s.a.number,s.a.func]),data:s.a.arrayOf(s.a.object),blendStroke:s.a.bool,minAngle:s.a.number,legendType:s.a.oneOf(ie),maxRadius:s.a.number,sectors:s.a.arrayOf(s.a.object),hide:s.a.bool,labelLine:s.a.oneOfType([s.a.object,s.a.func,s.a.element,s.a.bool]),label:s.a.oneOfType([s.a.shape({offsetRadius:s.a.number}),s.a.func,s.a.element,s.a.bool]),activeShape:s.a.oneOfType([s.a.object,s.a.func,s.a.element]),activeIndex:s.a.oneOfType([s.a.number,s.a.arrayOf(s.a.number)]),isAnimationActive:s.a.bool,animationBegin:s.a.number,animationDuration:s.a.number,animationEasing:s.a.oneOf(["ease","ease-in","ease-out","ease-in-out","spring","linear"]),id:s.a.string}),zp.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:!me(),animationBegin:400,animationDuration:1500,animationEasing:"ease",nameKey:"name",blendStroke:!1},zp.parseDeltaAngle=function(e){var t=e.startAngle,n=e.endAngle;return F(n-t)*Math.min(Math.abs(n-t),360)},zp.getRealPieData=function(e){var t=e.props,n=t.data,r=t.children,a=le(e.props),i=se(r,Bp);return n&&n.length?n.map(function(e,t){return Jp({payload:e},a,e,i&&i[t]&&i[t].props)}):i&&i.length?i.map(function(e){return Jp({},a,e.props)}):[]},zp.parseCoordinateOfPie=function(e,t){var n=t.top,r=t.left,a=t.width,i=t.height,o=Rf(a,i);return{cx:r+J(e.props.cx,a,a/2),cy:n+J(e.props.cy,i,i/2),innerRadius:J(e.props.innerRadius,o,0),outerRadius:J(e.props.outerRadius,o,.8*o),maxRadius:e.props.maxRadius||Math.sqrt(a*a+i*i)/2}},zp.getComposedData=function(e){var t=e.item,n=e.offset,r=e.onItemMouseLeave,a=e.onItemMouseEnter,i=Zp.getRealPieData(t);if(!i||!i.length)return[];var o=t.props,s=o.cornerRadius,u=o.startAngle,l=o.endAngle,c=o.paddingAngle,d=o.dataKey,f=o.nameKey,h=o.valueKey,p=Math.abs(t.props.minAngle),m=Zp.parseCoordinateOfPie(t,n),_=i.length,y=Zp.parseDeltaAngle({startAngle:u,endAngle:l}),v=Math.abs(y),g=v-_*p-(v>=360?_:_-1)*c,b=d;T()(d)&&T()(h)?b="value":T()(d)&&(b=h);var M,k,w=i.reduce(function(e,t){var n=sf(t,b,0);return e+(U(n)?n:0)},0);w>0&&(M=i.map(function(e,t){var n,r=sf(e,b,0),a=sf(e,f,t),i=(U(r)?r:0)/w,o=(n=t?k.endAngle+F(y)*c:u)+F(y)*(p+i*g),l=(n+o)/2,d=(m.innerRadius+m.outerRadius)/2,h=[{name:a,value:r,payload:e}],_=If(m.cx,m.cy,d,l);return k=Jp({percent:i,cornerRadius:s,name:a,tooltipPayload:h,midAngle:l,middleRadius:d,tooltipPosition:_},e,m,{value:sf(e,b),startAngle:n,endAngle:o,payload:e,paddingAngle:F(y)*c})}));return Jp({},m,{sectors:M,data:i,onMouseLeave:r,onMouseEnter:a})},Fp=Up))||Fp,em=Zp,tm=zh({chartName:"PieChart",GraphicalChild:em,eventType:"item",legendContent:"children",axisComponents:[{axisType:"angleAxis",AxisComp:hp},{axisType:"radiusAxis",AxisComp:Yp}],formatAxisMap:function(e,t,n,r,a){var i=e.width,o=e.height,s=e.startAngle,u=e.endAngle,l=J(e.cx,i,i/2),c=J(e.cy,o,o/2),d=Rf(i,o,n),f=J(e.innerRadius,d,0),h=J(e.outerRadius,d,.8*d);return Object.keys(t).reduce(function(e,n){var i,o=t[n],d=o.domain,p=o.reversed;if(T()(o.range))"angleAxis"===r?i=[s,u]:"radiusAxis"===r&&(i=[f,h]),p&&(i=[i[1],i[0]]);else{var m=Ef(i=o.range,2);s=m[0],u=m[1]}var _=yf(o,a),y=_.realScaleType,v=_.scale;v.domain(d).range(i),vf(v);var g=Mf(v,Of({},o,{realScaleType:y})),b=Of({},o,g,{range:i,radius:h,realScaleType:y,scale:v,cx:l,cy:c,innerRadius:f,outerRadius:h,startAngle:s,endAngle:u});return Of({},e,jf({},n,b))},{})},defaultProps:{layout:"centric",startAngle:0,endAngle:360,cx:"50%",cy:"50%",innerRadius:0,outerRadius:"80%"},propTypes:{layout:s.a.oneOf(["centric"]),startAngle:s.a.number,endAngle:s.a.number,cx:s.a.oneOfType([s.a.number,s.a.string]),cy:s.a.oneOfType([s.a.number,s.a.string]),innerRadius:s.a.oneOfType([s.a.number,s.a.string]),outerRadius:s.a.oneOfType([s.a.number,s.a.string])}}),nm=n(35);function rm(e,t,n,r,a){if(e>=t)return Promise.resolve({patternGraphData:[],calendarGraphData:[]});var i=[],o=function(o){if(!r[o].enabled)return"continue";var s=n.filter(function(e){return e.cal.regex.test(r[o].name)});s.length>0&&i.push(a(o,e,t).then(function(e){return{id:o,events:e,filtered:s}}))};for(var s in r)o(s);return Promise.all(i).then(function(a){var i={},o={},s={},u={};a.forEach(function(e){i[e.id]=e.events,o[e.id]=e.filtered});for(var l=0;lt+2&&(l=5,u="start"),an+2&&(c=10),i.a.createElement("text",{x:r,y:a,dx:l,dy:c,fill:o,textAnchor:u},"".concat(s))}var om=Object(u.withStyles)(am)(function(e){return i.a.createElement(c.a,{item:!0,xs:12,lg:6},i.a.createElement("div",{className:e.classes.patternTableWrapper},i.a.createElement(tm,{width:400,height:250,className:e.classes.pieChart},i.a.createElement(em,{data:e.data,dataKey:"value",cx:200,cy:125,outerRadius:60,fill:nm.a,isAnimationActive:!1,label:im},e.data.map(function(e,t){return i.a.createElement(Bp,{key:t,fill:e.color?e.color:nm.a})})),i.a.createElement(yn,{formatter:function(e){return"".concat(e.toFixed(2)," hr")}}))))});function sm(e){return i.a.createElement(c.a,{container:!0,spacing:0},i.a.createElement(om,{data:e.patternGraphData}),i.a.createElement(c.a,{item:!0,xs:12,lg:6},i.a.createElement("div",{className:e.classes.patternTableWrapper},i.a.createElement(tm,{width:400,height:250,className:e.classes.pieChart},i.a.createElement(em,{data:e.calendarGraphData,dataKey:"value",cx:200,cy:125,innerRadius:40,outerRadius:70,fill:f.a[300],isAnimationActive:!1,label:im},e.calendarGraphData.map(function(e,t){return i.a.createElement(Bp,{key:t,fill:e.color?e.color:f.a[300]})})),i.a.createElement(yn,{formatter:function(e){return"".concat(e.toFixed(2)," hr")}})))))}sm.propTypes={patternGraphData:s.a.array.isRequired,calendarGraphData:s.a.array.isRequired};var um=Object(u.withStyles)(am)(sm)},function(e,t,n){"use strict"; /* object-assign (c) Sindre Sorhus @@ -67,4 +67,4 @@ Object.defineProperty(t,"__esModule",{value:!0});var n=null,r=!1,a=3,i=-1,o=-1,s * @website https://github.com/jsstyles/css-vendor * @license MIT */ -t.prefix=r.default,t.supportedProperty=a.default,t.supportedValue=i.default},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){if(!s)return e;if(null!=u[e])return u[e];(0,i.default)(e)in s.style?u[e]=e:a.default.js+(0,i.default)("-"+e)in s.style?u[e]=a.default.css+e:u[e]=!1;return u[e]};var r=o(n(63)),a=o(n(90)),i=o(n(391));function o(e){return e&&e.__esModule?e:{default:e}}var s=void 0,u={};if(r.default){s=document.createElement("p");var l=window.getComputedStyle(document.documentElement,"");for(var c in l)isNaN(c)||(u[l[c]]=l[c])}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return e.replace(r,a)};var r=/[-\s]+(.)?/g;function a(e,t){return t?t.toUpperCase():""}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){if(!s)return t;if("string"!=typeof t||!isNaN(parseInt(t,10)))return t;var n=e+t;if(null!=o[n])return o[n];try{s.style[e]=t}catch(e){return o[n]=!1,!1}""!==s.style[e]?o[n]=t:("-ms-flex"===(t=a.default.css+t)&&(t="-ms-flexbox"),s.style[e]=t,""!==s.style[e]&&(o[n]=t));o[n]||(o[n]=!1);return s.style[e]="",o[n]};var r=i(n(63)),a=i(n(90));function i(e){return e&&e.__esModule?e:{default:e}}var o={},s=void 0;r.default&&(s=document.createElement("p"))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(){function e(e,t){return e.length-t.length}return{onProcessStyle:function(t,n){if("style"!==n.type)return t;var r={},a=Object.keys(t).sort(e);for(var i in a)r[a[i]]=t[a[i]];return r}}}},function(e,t,n){"use strict";var r=n(395),a=n(3);Object.defineProperty(t,"__esModule",{value:!0}),t.default=t.MuiThemeProviderOld=void 0;var i=a(n(9)),o=a(n(7)),s=a(n(12)),u=a(n(13)),l=a(n(16)),c=a(n(17)),d=a(n(18)),f=a(n(1)),h=a(n(0)),p=(a(n(19)),a(n(396))),m=n(14),_=r(n(91)),y=function(e){function t(e,n){var r;return(0,s.default)(this,t),(r=(0,l.default)(this,(0,c.default)(t).call(this))).broadcast=(0,p.default)(),r.outerTheme=_.default.initial(n),r.broadcast.setState(r.mergeOuterLocalTheme(e.theme)),r}return(0,d.default)(t,e),(0,u.default)(t,[{key:"getChildContext",value:function(){var e,t=this.props,n=t.disableStylesGeneration,r=t.sheetsCache,a=t.sheetsManager,i=this.context.muiThemeProviderOptions||{};return void 0!==n&&(i.disableStylesGeneration=n),void 0!==r&&(i.sheetsCache=r),void 0!==a&&(i.sheetsManager=a),e={},(0,o.default)(e,_.CHANNEL,this.broadcast),(0,o.default)(e,"muiThemeProviderOptions",i),e}},{key:"componentDidMount",value:function(){var e=this;this.unsubscribeId=_.default.subscribe(this.context,function(t){e.outerTheme=t,e.broadcast.setState(e.mergeOuterLocalTheme(e.props.theme))})}},{key:"componentDidUpdate",value:function(e){this.props.theme!==e.theme&&this.broadcast.setState(this.mergeOuterLocalTheme(this.props.theme))}},{key:"componentWillUnmount",value:function(){null!==this.unsubscribeId&&_.default.unsubscribe(this.context,this.unsubscribeId)}},{key:"mergeOuterLocalTheme",value:function(e){return"function"==typeof e?e(this.outerTheme):this.outerTheme?(0,i.default)({},this.outerTheme,e):e}},{key:"render",value:function(){return this.props.children}}]),t}(f.default.Component);t.MuiThemeProviderOld=y,y.childContextTypes=(0,i.default)({},_.default.contextTypes,{muiThemeProviderOptions:h.default.object}),y.contextTypes=(0,i.default)({},_.default.contextTypes,{muiThemeProviderOptions:h.default.object}),m.ponyfillGlobal.__MUI_STYLES__||(m.ponyfillGlobal.__MUI_STYLES__={}),m.ponyfillGlobal.__MUI_STYLES__.MuiThemeProvider||(m.ponyfillGlobal.__MUI_STYLES__.MuiThemeProvider=y);var v=m.ponyfillGlobal.__MUI_STYLES__.MuiThemeProvider;t.default=v},function(e,t){e.exports=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){var r=Object.defineProperty&&Object.getOwnPropertyDescriptor?Object.getOwnPropertyDescriptor(e,n):{};r.get||r.set?Object.defineProperty(t,n,r):t[n]=e[n]}return t.default=e,t}},function(e,t,n){"use strict";n.r(t),t.default=function(e){var t={},n=1,r=e;return{getState:function(){return r},setState:function(e){r=e;for(var n=Object.keys(t),a=0,i=n.length;a=t||n<0||y&&e-m>=d}function M(){var e=a();if(b(e))return k(e);h=setTimeout(M,function(e){var n=t-(e-p);return y?u(n,d-(e-m)):n}(e))}function k(e){return h=void 0,v&&l?g(e):(l=c=void 0,f)}function w(){var e=a(),n=b(e);if(l=arguments,c=this,p=e,n){if(void 0===h)return function(e){return m=e,h=setTimeout(M,t),_?g(e):f}(p);if(y)return h=setTimeout(M,t),g(p)}return void 0===h&&(h=setTimeout(M,t)),f}return t=i(t)||0,r(n)&&(_=!!n.leading,d=(y="maxWait"in n)?s(i(n.maxWait)||0,t):d,v="trailing"in n?!!n.trailing:v),w.cancel=function(){void 0!==h&&clearTimeout(h),m=0,l=p=c=h=void 0},w.flush=function(){return void 0===h?f:k(a())},w}},function(e,t,n){var r=n(23);e.exports=function(){return r.Date.now()}},function(e,t,n){var r=n(53),a=Object.prototype,i=a.hasOwnProperty,o=a.toString,s=r?r.toStringTag:void 0;e.exports=function(e){var t=i.call(e,s),n=e[s];try{e[s]=void 0;var r=!0}catch(e){}var a=o.call(e);return r&&(t?e[s]=n:delete e[s]),a}},function(e,t){var n=Object.prototype.toString;e.exports=function(e){return n.call(e)}},,function(e,t,n){"use strict";var r=n(3);Object.defineProperty(t,"__esModule",{value:!0}),t.default=t.styles=void 0;var a=r(n(7)),i=r(n(10)),o=r(n(9)),s=r(n(1)),u=(r(n(0)),r(n(4))),l=(n(14),r(n(15))),c=n(119),d=(r(n(417)),[0,8,16,24,32,40]),f=["auto",!0,1,2,3,4,5,6,7,8,9,10,11,12];var h=function(e){return(0,o.default)({container:{boxSizing:"border-box",display:"flex",flexWrap:"wrap",width:"100%"},item:{boxSizing:"border-box",margin:"0"},zeroMinWidth:{minWidth:0},"direction-xs-column":{flexDirection:"column"},"direction-xs-column-reverse":{flexDirection:"column-reverse"},"direction-xs-row-reverse":{flexDirection:"row-reverse"},"wrap-xs-nowrap":{flexWrap:"nowrap"},"wrap-xs-wrap-reverse":{flexWrap:"wrap-reverse"},"align-items-xs-center":{alignItems:"center"},"align-items-xs-flex-start":{alignItems:"flex-start"},"align-items-xs-flex-end":{alignItems:"flex-end"},"align-items-xs-baseline":{alignItems:"baseline"},"align-content-xs-center":{alignContent:"center"},"align-content-xs-flex-start":{alignContent:"flex-start"},"align-content-xs-flex-end":{alignContent:"flex-end"},"align-content-xs-space-between":{alignContent:"space-between"},"align-content-xs-space-around":{alignContent:"space-around"},"justify-xs-center":{justifyContent:"center"},"justify-xs-flex-end":{justifyContent:"flex-end"},"justify-xs-space-between":{justifyContent:"space-between"},"justify-xs-space-around":{justifyContent:"space-around"},"justify-xs-space-evenly":{justifyContent:"space-evenly"}},function(e,t){var n={};return d.forEach(function(e,r){0!==r&&(n["spacing-".concat(t,"-").concat(e)]={margin:-e/2,width:"calc(100% + ".concat(e,"px)"),"& > $item":{padding:e/2}})}),n}(0,"xs"),c.keys.reduce(function(t,n){return function(e,t,n){var r={};f.forEach(function(e){var t="grid-".concat(n,"-").concat(e);if(!0!==e)if("auto"!==e){var a="".concat(Math.round(e/12*1e8)/1e6,"%");r[t]={flexBasis:a,flexGrow:0,maxWidth:a}}else r[t]={flexBasis:"auto",flexGrow:0,maxWidth:"none"};else r[t]={flexBasis:0,flexGrow:1,maxWidth:"100%"}}),"xs"===n?(0,o.default)(e,r):e[t.breakpoints.up(n)]=r}(t,e,n),t},{}))};function p(e){var t,n=e.alignContent,r=e.alignItems,l=e.classes,c=e.className,d=e.component,f=e.container,h=e.direction,m=e.item,_=e.justify,y=e.lg,v=e.md,g=e.sm,b=e.spacing,M=e.wrap,k=e.xl,w=e.xs,x=e.zeroMinWidth,L=(0,i.default)(e,["alignContent","alignItems","classes","className","component","container","direction","item","justify","lg","md","sm","spacing","wrap","xl","xs","zeroMinWidth"]),T=(0,u.default)((t={},(0,a.default)(t,l.container,f),(0,a.default)(t,l.item,m),(0,a.default)(t,l.zeroMinWidth,x),(0,a.default)(t,l["spacing-xs-".concat(String(b))],f&&0!==b),(0,a.default)(t,l["direction-xs-".concat(String(h))],h!==p.defaultProps.direction),(0,a.default)(t,l["wrap-xs-".concat(String(M))],M!==p.defaultProps.wrap),(0,a.default)(t,l["align-items-xs-".concat(String(r))],r!==p.defaultProps.alignItems),(0,a.default)(t,l["align-content-xs-".concat(String(n))],n!==p.defaultProps.alignContent),(0,a.default)(t,l["justify-xs-".concat(String(_))],_!==p.defaultProps.justify),(0,a.default)(t,l["grid-xs-".concat(String(w))],!1!==w),(0,a.default)(t,l["grid-sm-".concat(String(g))],!1!==g),(0,a.default)(t,l["grid-md-".concat(String(v))],!1!==v),(0,a.default)(t,l["grid-lg-".concat(String(y))],!1!==y),(0,a.default)(t,l["grid-xl-".concat(String(k))],!1!==k),t),c);return s.default.createElement(d,(0,o.default)({className:T},L))}t.styles=h,p.defaultProps={alignContent:"stretch",alignItems:"stretch",component:"div",container:!1,direction:"row",item:!1,justify:"flex-start",lg:!1,md:!1,sm:!1,spacing:0,wrap:"wrap",xl:!1,xs:!1,zeroMinWidth:!1};var m=(0,l.default)(h,{name:"MuiGrid"})(p);t.default=m},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r=function(e){return function(){return null}};t.default=r},function(e,t){e.exports=function(e,t){for(var n=-1,r=null==e?0:e.length;++n-1}},function(e,t,n){var r=n(67);e.exports=function(e,t){var n=this.__data__,a=r(n,e);return a<0?(++this.size,n.push([e,t])):n[a][1]=t,this}},function(e,t,n){var r=n(66);e.exports=function(){this.__data__=new r,this.size=0}},function(e,t){e.exports=function(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}},function(e,t){e.exports=function(e){return this.__data__.get(e)}},function(e,t){e.exports=function(e){return this.__data__.has(e)}},function(e,t,n){var r=n(66),a=n(98),i=n(99),o=200;e.exports=function(e,t){var n=this.__data__;if(n instanceof r){var s=n.__data__;if(!a||s.length-1?s[u?t[l]:l]:void 0}}},function(e,t,n){var r=n(279),a=n(24),i=n(492),o=Math.max;e.exports=function(e,t,n){var s=null==e?0:e.length;if(!s)return-1;var u=null==n?0:i(n);return u<0&&(u=o(s+u,0)),r(e,a(t,3),u)}},function(e,t,n){var r=n(280);e.exports=function(e){var t=r(e),n=t%1;return t==t?n?t-n:t:0}},function(e,t,n){var r=n(53),a=n(93),i=n(8),o=r?r.isConcatSpreadable:void 0;e.exports=function(e){return i(e)||a(e)||!!(o&&e&&e[o])}},function(e,t,n){var r=n(54),a=n(24),i=n(282),o=n(495),s=n(96),u=n(496),l=n(43);e.exports=function(e,t,n){var c=-1;t=r(t.length?t:[l],s(a));var d=i(e,function(e,n,a){return{criteria:r(t,function(t){return t(e)}),index:++c,value:e}});return o(d,function(e,t){return u(e,t,n)})}},function(e,t){e.exports=function(e,t){var n=e.length;for(e.sort(t);n--;)e[n]=e[n].value;return e}},function(e,t,n){var r=n(497);e.exports=function(e,t,n){for(var a=-1,i=e.criteria,o=t.criteria,s=i.length,u=n.length;++a=u?l:l*("desc"==n[a]?-1:1)}return e.index-t.index}},function(e,t,n){var r=n(41);e.exports=function(e,t){if(e!==t){var n=void 0!==e,a=null===e,i=e==e,o=r(e),s=void 0!==t,u=null===t,l=t==t,c=r(t);if(!u&&!c&&!o&&e>t||o&&s&&l&&!u&&!c||a&&s&&l||!n&&l||!i)return 1;if(!a&&!o&&!c&&e0){if(++t>=n)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}},function(e,t,n){var r=n(505),a=n(71),i=n(280);e.exports=function(e){return function(t,n,o){return o&&"number"!=typeof o&&a(t,n,o)&&(n=o=void 0),t=i(t),void 0===n?(n=t,t=0):n=i(n),o=void 0===o?tr&&(a=r,i=n),[a,i]}function c(e,t,n){if(e.lte(0))return new r.default(0);var a=i.default.getDigitCount(e.toNumber()),o=new r.default(10).pow(a),s=e.div(o),u=1!==a?.05:.1,l=new r.default(Math.ceil(s.div(u).toNumber())).add(n).mul(u).mul(o);return t?l:new r.default(Math.ceil(l))}function d(e,t,n){var o=1,s=new r.default(e);if(!s.isint()&&n){var u=Math.abs(e);u<1?(o=new r.default(10).pow(i.default.getDigitCount(e)-1),s=new r.default(Math.floor(s.div(o).toNumber())).mul(o)):u>1&&(s=new r.default(Math.floor(e)))}else 0===e?s=new r.default(Math.floor((t-1)/2)):n||(s=new r.default(Math.floor(e)));var l=Math.floor((t-1)/2);return(0,a.compose)((0,a.map)(function(e){return s.add(new r.default(e-l).mul(o)).toNumber()}),a.range)(0,t)}var f=(0,a.memoize)(function(e){var t=u(e,2),n=t[0],o=t[1],f=arguments.length>1&&void 0!==arguments[1]?arguments[1]:6,h=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],p=Math.max(f,2),m=u(l([n,o]),2),_=m[0],y=m[1];if(_===-1/0||y===1/0){var v=y===1/0?[_].concat(s((0,a.range)(0,f-1).map(function(){return 1/0}))):s((0,a.range)(0,f-1).map(function(){return-1/0})).concat([y]);return n>o?(0,a.reverse)(v):v}if(_===y)return d(_,f,h);var g=function e(t,n,a,i){var o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:0;if(!Number.isFinite((n-t)/(a-1)))return{step:new r.default(0),tickMin:new r.default(0),tickMax:new r.default(0)};var s,u=c(new r.default(n).sub(t).div(a-1),i,o);s=t<=0&&n>=0?new r.default(0):(s=new r.default(t).add(n).div(2)).sub(new r.default(s).mod(u));var l=Math.ceil(s.sub(t).div(u).toNumber()),d=Math.ceil(new r.default(n).sub(s).div(u).toNumber()),f=l+d+1;return f>a?e(t,n,a,i,o+1):(f0?d+(a-f):d,l=n>0?l:l+(a-f)),{step:u,tickMin:s.sub(new r.default(l).mul(u)),tickMax:s.add(new r.default(d).mul(u))})}(_,y,p,h),b=g.step,M=g.tickMin,k=g.tickMax,w=i.default.rangeStep(M,k.add(new r.default(.1).mul(b)),b);return n>o?(0,a.reverse)(w):w});t.getNiceTickValues=f;var h=(0,a.memoize)(function(e){var t=u(e,2),n=t[0],i=t[1],o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:6,s=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],f=Math.max(o,2),h=u(l([n,i]),2),p=h[0],m=h[1];if(p===-1/0||m===1/0)return[n,i];if(p===m)return d(p,o,s);var _=c(new r.default(m).sub(p).div(f-1),s,0),y=(0,a.compose)((0,a.map)(function(e){return new r.default(p).add(new r.default(e).mul(_)).toNumber()}),a.range)(0,f).filter(function(e){return e>=p&&e<=m});return n>i?(0,a.reverse)(y):y});t.getTickValues=h;var p=(0,a.memoize)(function(e,t){var n=u(e,2),o=n[0],d=n[1],f=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],h=u(l([o,d]),2),p=h[0],m=h[1];if(p===-1/0||m===1/0)return[o,d];if(p===m)return[p];var _=Math.max(t,2),y=c(new r.default(m).sub(p).div(_-1),f,0),v=s(i.default.rangeStep(new r.default(p),new r.default(m).sub(new r.default(.99).mul(y)),y)).concat([m]);return o>d?(0,a.reverse)(v):v});t.getTickValuesFixedDomain=p},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r,a=(r=n(287))&&r.__esModule?r:{default:r},i=n(288);var o={rangeStep:function(e,t,n){for(var r=new a.default(e),i=[];r.lt(t);)i.push(r.toNumber()),r=r.add(n);return i},getDigitCount:function(e){return 0===e?1:Math.floor(new a.default(e).abs().log(10).toNumber())+1},interpolateNumber:(0,i.curry)(function(e,t,n){var r=+e;return r+n*(+t-r)}),uninterpolateNumber:(0,i.curry)(function(e,t,n){var r=t-+e;return(n-e)/(r=r||1/0)}),uninterpolateTruncation:(0,i.curry)(function(e,t,n){var r=t-+e;return r=r||1/0,Math.max(0,Math.min(1,(n-e)/r))})};t.default=o},function(e,t,n){var r=n(64);e.exports=function(e,t){var n;return r(e,function(e,r,a){return!(n=t(e,r,a))}),!!n}},function(e,t,n){var r=n(284);e.exports=function(e,t,n){"__proto__"==t&&r?r(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}},function(e,t){function n(e,t,n){e instanceof RegExp&&(e=r(e,n)),t instanceof RegExp&&(t=r(t,n));var i=a(e,t,n);return i&&{start:i[0],end:i[1],pre:n.slice(0,i[0]),body:n.slice(i[0]+e.length,i[1]),post:n.slice(i[1]+t.length)}}function r(e,t){var n=t.match(e);return n?n[0]:null}function a(e,t,n){var r,a,i,o,s,u=n.indexOf(e),l=n.indexOf(t,u+1),c=u;if(u>=0&&l>0){for(r=[],i=n.length;c>=0&&!s;)c==u?(r.push(c),u=n.indexOf(e,c+1)):1==r.length?s=[r.pop(),l]:((a=r.pop())=0?u:l;r.length&&(s=[i,o])}return s}e.exports=n,n.range=a},function(e,t,n){var r=n(513);function a(e,t,n){var i=e;return function(e,t){var n=[],a="string"==typeof t?new RegExp("\\b("+t+")\\("):t;do{var i=a.exec(e);if(!i)return n;if(void 0===i[1])throw new Error("Missing the first couple of parenthesis to get the function identifier in "+t);var o=i[1],s=i.index,u=r("(",")",e.substring(s));if(!u||u.start!==i[0].length-1)throw new SyntaxError(o+"(): missing closing ')' in the value '"+e+"'");n.push({matches:u,functionIdentifier:o}),e=u.post}while(a.test(e));return n}(e,t).reduce(function(e,r){return e.replace(r.functionIdentifier+"("+r.matches.body+")",function(e,t,n,r,i){return n(a(e,i,n),t,r)}(r.matches.body,r.functionIdentifier,n,i,t))},e)}e.exports=a},function(e,t){function n(e,t,n){e instanceof RegExp&&(e=r(e,n)),t instanceof RegExp&&(t=r(t,n));var i=a(e,t,n);return i&&{start:i[0],end:i[1],pre:n.slice(0,i[0]),body:n.slice(i[0]+e.length,i[1]),post:n.slice(i[1]+t.length)}}function r(e,t){var n=t.match(e);return n?n[0]:null}function a(e,t,n){var r,a,i,o,s,u=n.indexOf(e),l=n.indexOf(t,u+1),c=u;if(u>=0&&l>0){for(r=[],i=n.length;c>=0&&!s;)c==u?(r.push(c),u=n.indexOf(e,c+1)):1==r.length?s=[r.pop(),l]:((a=r.pop())=0?u:l;r.length&&(s=[i,o])}return s}e.exports=n,n.range=a},function(e,t,n){var r=n(515);r.prototype.formulaEval=function(){"use strict";for(var e,t,n,r=[],a=this.value,i=0;i"+t.value+""+a[i].show+""+e.value+"",type:10}):r.push({value:(1!=t.type?"(":"")+t.value+(1!=t.type?")":"")+""+e.value+"",type:1})):2===a[i].type||9===a[i].type?(e=r.pop(),t=r.pop(),r.push({value:(1!=t.type?"(":"")+t.value+(1!=t.type?")":"")+a[i].show+(1!=e.type?"(":"")+e.value+(1!=e.type?")":""),type:a[i].type})):12===a[i].type&&(e=r.pop(),t=r.pop(),n=r.pop(),r.push({value:a[i].show+"("+n.value+","+t.value+","+e.value+")",type:12}));return r[0].value},e.exports=r},function(e,t,n){var r=n(516);r.prototype.postfixEval=function(e){"use strict";(e=e||{}).PI=Math.PI,e.E=Math.E;for(var t,n,a,i=[],o=this.value,s=void 0!==e.n,u=0;u1)throw new r.exception("Uncaught Syntax error");return i[0].value>1e15?"Infinity":parseFloat(i[0].value.toFixed(15))},r.eval=function(e,t,n){return void 0===t?this.lex(e).toPostfix().postfixEval():void 0===n?void 0!==t.length?this.lex(e,t).toPostfix().postfixEval():this.lex(e).toPostfix().postfixEval(t):this.lex(e,t).toPostfix().postfixEval(n)},e.exports=r},function(e,t,n){var r=n(517);r.prototype.toPostfix=function(){"use strict";for(var e,t,n,a,i,o=[],s=[{value:"(",type:4,pre:0}],u=this.value,l=1;ln)s.push(e);else{for(;n>=a&&!c||c&&av.length-2?v.length-1:w.length-i;y>0;y--)for(b=0;b=120&&y.length>=120)?new r(h&&y):void 0}y=e[0];var v=-1,g=p[0];e:for(;++v-1}},function(e,t,n){var r=n(279),a=n(524),i=n(525);e.exports=function(e,t,n){return t==t?i(e,t,n):r(e,a,n)}},function(e,t){e.exports=function(e){return e!=e}},function(e,t){e.exports=function(e,t,n){for(var r=n-1,a=e.length;++r=0||(a[n]=e[n]);return a}(e,["children","in"]),o=r.default.Children.toArray(t),s=o[0],u=o[1];return delete a.onEnter,delete a.onEntering,delete a.onEntered,delete a.onExit,delete a.onExiting,delete a.onExited,r.default.createElement(i.default,a,n?r.default.cloneElement(s,{key:"first",onEnter:this.handleEnter,onEntering:this.handleEntering,onEntered:this.handleEntered}):r.default.cloneElement(u,{key:"second",onEnter:this.handleExit,onEntering:this.handleExiting,onEntered:this.handleExited}))},o}(r.default.Component);s.propTypes={};var u=s;t.default=u,e.exports=t.default},function(e,t,n){"use strict";t.__esModule=!0,t.getChildMapping=a,t.mergeChildMappings=i,t.getInitialChildMapping=function(e,t){return a(e.children,function(n){return(0,r.cloneElement)(n,{onExited:t.bind(null,n),in:!0,appear:o(n,"appear",e),enter:o(n,"enter",e),exit:o(n,"exit",e)})})},t.getNextChildMapping=function(e,t,n){var s=a(e.children),u=i(t,s);return Object.keys(u).forEach(function(a){var i=u[a];if((0,r.isValidElement)(i)){var l=a in t,c=a in s,d=t[a],f=(0,r.isValidElement)(d)&&!d.props.in;!c||l&&!f?c||!l||f?c&&l&&(0,r.isValidElement)(d)&&(u[a]=(0,r.cloneElement)(i,{onExited:n.bind(null,i),in:d.props.in,exit:o(i,"exit",e),enter:o(i,"enter",e)})):u[a]=(0,r.cloneElement)(i,{in:!1}):u[a]=(0,r.cloneElement)(i,{onExited:n.bind(null,i),in:!0,exit:o(i,"exit",e),enter:o(i,"enter",e)})}}),u};var r=n(1);function a(e,t){var n=Object.create(null);return e&&r.Children.map(e,function(e){return e}).forEach(function(e){n[e.key]=function(e){return t&&(0,r.isValidElement)(e)?t(e):e}(e)}),n}function i(e,t){function n(n){return n in t?t[n]:e[n]}e=e||{},t=t||{};var r,a=Object.create(null),i=[];for(var o in e)o in t?i.length&&(a[o]=i,i=[]):i.push(o);var s={};for(var u in t){if(a[u])for(r=0;r1;const m=(e,t,n)=>{const r=e[f].get(t);if(r){const t=r.value;if(_(e,t)){if(v(e,r),!e[s])return}else n&&(e[h]&&(r.value.now=Date.now()),e[d].unshiftNode(r));return t.value}},_=(e,t)=>{if(!t||!t.maxAge&&!e[u])return!1;const n=Date.now()-t.now;return t.maxAge?n>t.maxAge:e[u]&&n>e[u]},y=e=>{if(e[i]>e[a])for(let t=e[d].tail;e[i]>e[a]&&null!==t;){const n=t.prev;v(e,t),t=n}},v=(e,t)=>{if(t){const n=t.value;e[l]&&e[l](n.key,n.value),e[i]-=n.length,e[f].delete(n.key),e[d].removeNode(t)}};class g{constructor(e,t,n,r,a){this.key=e,this.value=t,this.length=n,this.now=r,this.maxAge=a||0}}const b=(e,t,n,r)=>{let a=n.value;_(e,a)&&(v(e,n),e[s]||(a=void 0)),a&&t.call(r,a.value,a.key,e)};e.exports=class{constructor(e){if("number"==typeof e&&(e={max:e}),e||(e={}),e.max&&("number"!=typeof e.max||e.max<0))throw new TypeError("max must be a non-negative number");this[a]=e.max||1/0;const t=e.length||p;if(this[o]="function"!=typeof t?p:t,this[s]=e.stale||!1,e.maxAge&&"number"!=typeof e.maxAge)throw new TypeError("maxAge must be a number");this[u]=e.maxAge||0,this[l]=e.dispose,this[c]=e.noDisposeOnSet||!1,this[h]=e.updateAgeOnGet||!1,this.reset()}set max(e){if("number"!=typeof e||e<0)throw new TypeError("max must be a non-negative number");this[a]=e||1/0,y(this)}get max(){return this[a]}set allowStale(e){this[s]=!!e}get allowStale(){return this[s]}set maxAge(e){if("number"!=typeof e)throw new TypeError("maxAge must be a non-negative number");this[u]=e,y(this)}get maxAge(){return this[u]}set lengthCalculator(e){"function"!=typeof e&&(e=p),e!==this[o]&&(this[o]=e,this[i]=0,this[d].forEach(e=>{e.length=this[o](e.value,e.key),this[i]+=e.length})),y(this)}get lengthCalculator(){return this[o]}get length(){return this[i]}get itemCount(){return this[d].length}rforEach(e,t){t=t||this;for(let n=this[d].tail;null!==n;){const r=n.prev;b(this,e,n,t),n=r}}forEach(e,t){t=t||this;for(let n=this[d].head;null!==n;){const r=n.next;b(this,e,n,t),n=r}}keys(){return this[d].toArray().map(e=>e.key)}values(){return this[d].toArray().map(e=>e.value)}reset(){this[l]&&this[d]&&this[d].length&&this[d].forEach(e=>this[l](e.key,e.value)),this[f]=new Map,this[d]=new r,this[i]=0}dump(){return this[d].map(e=>!_(this,e)&&{k:e.key,v:e.value,e:e.now+(e.maxAge||0)}).toArray().filter(e=>e)}dumpLru(){return this[d]}set(e,t,n){if((n=n||this[u])&&"number"!=typeof n)throw new TypeError("maxAge must be a number");const r=n?Date.now():0,s=this[o](t,e);if(this[f].has(e)){if(s>this[a])return v(this,this[f].get(e)),!1;const o=this[f].get(e).value;return this[l]&&(this[c]||this[l](e,o.value)),o.now=r,o.maxAge=n,o.value=t,this[i]+=s-o.length,o.length=s,this.get(e),y(this),!0}const h=new g(e,t,s,r,n);return h.length>this[a]?(this[l]&&this[l](e,t),!1):(this[i]+=h.length,this[d].unshift(h),this[f].set(e,this[d].head),y(this),!0)}has(e){if(!this[f].has(e))return!1;const t=this[f].get(e).value;return!_(this,t)}get(e){return m(this,e,!0)}peek(e){return m(this,e,!1)}pop(){const e=this[d].tail;return e?(v(this,e),e.value):null}del(e){v(this,this[f].get(e))}load(e){this.reset();const t=Date.now();for(let n=e.length-1;n>=0;n--){const r=e[n],a=r.e||0;if(0===a)this.set(r.k,r.v);else{const e=a-t;e>0&&this.set(r.k,r.v,e)}}}prune(){this[f].forEach((e,t)=>m(this,t,!1))}}},function(e,t){function n(e,t,n,r,a,i,o){try{var s=e[i](o),u=s.value}catch(e){return void n(e)}s.done?t(u):Promise.resolve(u).then(r,a)}e.exports=function(e){return function(){var t=this,r=arguments;return new Promise(function(a,i){var o=e.apply(t,r);function s(e){n(o,a,i,s,u,"next",e)}function u(e){n(o,a,i,s,u,"throw",e)}s(void 0)})}}},,,,,,,,,,,,,,,,,,,,,,,,,,,,,,function(e,t){e.exports=function(e){if(Array.isArray(e))return e}},function(e,t){e.exports=function(e,t){var n=[],r=!0,a=!1,i=void 0;try{for(var o,s=e[Symbol.iterator]();!(r=(o=s.next()).done)&&(n.push(o.value),!t||n.length!==t);r=!0);}catch(e){a=!0,i=e}finally{try{r||null==s.return||s.return()}finally{if(a)throw i}}return n}},function(e,t){e.exports=function(){throw new TypeError("Invalid attempt to destructure non-iterable instance")}},function(e,t,n){"use strict";function r(e){var t=this;if(t instanceof r||(t=new r),t.tail=null,t.head=null,t.length=0,e&&"function"==typeof e.forEach)e.forEach(function(e){t.push(e)});else if(arguments.length>0)for(var n=0,a=arguments.length;n1)n=t;else{if(!this.head)throw new TypeError("Reduce of empty list with no initial value");r=this.head.next,n=this.head.value}for(var a=0;null!==r;a++)n=e(n,r.value,a),r=r.next;return n},r.prototype.reduceReverse=function(e,t){var n,r=this.tail;if(arguments.length>1)n=t;else{if(!this.tail)throw new TypeError("Reduce of empty list with no initial value");r=this.tail.prev,n=this.tail.value}for(var a=this.length-1;null!==r;a--)n=e(n,r.value,a),r=r.prev;return n},r.prototype.toArray=function(){for(var e=new Array(this.length),t=0,n=this.head;null!==n;t++)e[t]=n.value,n=n.next;return e},r.prototype.toArrayReverse=function(){for(var e=new Array(this.length),t=0,n=this.tail;null!==n;t++)e[t]=n.value,n=n.prev;return e},r.prototype.slice=function(e,t){(t=t||this.length)<0&&(t+=this.length),(e=e||0)<0&&(e+=this.length);var n=new r;if(tthis.length&&(t=this.length);for(var a=0,i=this.head;null!==i&&athis.length&&(t=this.length);for(var a=this.length,i=this.tail;null!==i&&a>t;a--)i=i.prev;for(;null!==i&&a>e;a--,i=i.prev)n.push(i.value);return n},r.prototype.reverse=function(){for(var e=this.head,t=this.tail,n=e;null!==n;n=n.prev){var r=n.prev;n.prev=n.next,n.next=r}return this.head=t,this.tail=e,this};try{n(578)(r)}catch(e){}},function(e,t,n){"use strict";e.exports=function(e){e.prototype[Symbol.iterator]=function*(){for(let e=this.head;e;e=e.next)yield e.value}}},,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,function(e,t,n){var r=function(){return this||"object"==typeof self&&self}()||Function("return this")(),a=r.regeneratorRuntime&&Object.getOwnPropertyNames(r).indexOf("regeneratorRuntime")>=0,i=a&&r.regeneratorRuntime;if(r.regeneratorRuntime=void 0,e.exports=n(613),a)r.regeneratorRuntime=i;else try{delete r.regeneratorRuntime}catch(e){r.regeneratorRuntime=void 0}},function(e,t){!function(t){"use strict";var n,r=Object.prototype,a=r.hasOwnProperty,i="function"==typeof Symbol?Symbol:{},o=i.iterator||"@@iterator",s=i.asyncIterator||"@@asyncIterator",u=i.toStringTag||"@@toStringTag",l="object"==typeof e,c=t.regeneratorRuntime;if(c)l&&(e.exports=c);else{(c=t.regeneratorRuntime=l?e.exports:{}).wrap=b;var d="suspendedStart",f="suspendedYield",h="executing",p="completed",m={},_={};_[o]=function(){return this};var y=Object.getPrototypeOf,v=y&&y(y(j([])));v&&v!==r&&a.call(v,o)&&(_=v);var g=x.prototype=k.prototype=Object.create(_);w.prototype=g.constructor=x,x.constructor=w,x[u]=w.displayName="GeneratorFunction",c.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===w||"GeneratorFunction"===(t.displayName||t.name))},c.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,x):(e.__proto__=x,u in e||(e[u]="GeneratorFunction")),e.prototype=Object.create(g),e},c.awrap=function(e){return{__await:e}},L(T.prototype),T.prototype[s]=function(){return this},c.AsyncIterator=T,c.async=function(e,t,n,r){var a=new T(b(e,t,n,r));return c.isGeneratorFunction(t)?a:a.next().then(function(e){return e.done?e.value:a.next()})},L(g),g[u]="Generator",g[o]=function(){return this},g.toString=function(){return"[object Generator]"},c.keys=function(e){var t=[];for(var n in e)t.push(n);return t.reverse(),function n(){for(;t.length;){var r=t.pop();if(r in e)return n.value=r,n.done=!1,n}return n.done=!0,n}},c.values=j,O.prototype={constructor:O,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=n,this.done=!1,this.delegate=null,this.method="next",this.arg=n,this.tryEntries.forEach(D),!e)for(var t in this)"t"===t.charAt(0)&&a.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=n)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var t=this;function r(r,a){return s.type="throw",s.arg=e,t.next=r,a&&(t.method="next",t.arg=n),!!a}for(var i=this.tryEntries.length-1;i>=0;--i){var o=this.tryEntries[i],s=o.completion;if("root"===o.tryLoc)return r("end");if(o.tryLoc<=this.prev){var u=a.call(o,"catchLoc"),l=a.call(o,"finallyLoc");if(u&&l){if(this.prev=0;--n){var r=this.tryEntries[n];if(r.tryLoc<=this.prev&&a.call(r,"finallyLoc")&&this.prev=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),D(n),m}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var a=r.arg;D(n)}return a}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,r){return this.delegate={iterator:j(e),resultName:t,nextLoc:r},"next"===this.method&&(this.arg=n),m}}}function b(e,t,n,r){var a=t&&t.prototype instanceof k?t:k,i=Object.create(a.prototype),o=new O(r||[]);return i._invoke=function(e,t,n){var r=d;return function(a,i){if(r===h)throw new Error("Generator is already running");if(r===p){if("throw"===a)throw i;return E()}for(n.method=a,n.arg=i;;){var o=n.delegate;if(o){var s=Y(o,n);if(s){if(s===m)continue;return s}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(r===d)throw r=p,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r=h;var u=M(e,t,n);if("normal"===u.type){if(r=n.done?p:f,u.arg===m)continue;return{value:u.arg,done:n.done}}"throw"===u.type&&(r=p,n.method="throw",n.arg=u.arg)}}}(e,n,o),i}function M(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}function k(){}function w(){}function x(){}function L(e){["next","throw","return"].forEach(function(t){e[t]=function(e){return this._invoke(t,e)}})}function T(e){var t;this._invoke=function(n,r){function i(){return new Promise(function(t,i){!function t(n,r,i,o){var s=M(e[n],e,r);if("throw"!==s.type){var u=s.arg,l=u.value;return l&&"object"==typeof l&&a.call(l,"__await")?Promise.resolve(l.__await).then(function(e){t("next",e,i,o)},function(e){t("throw",e,i,o)}):Promise.resolve(l).then(function(e){u.value=e,i(u)},function(e){return t("throw",e,i,o)})}o(s.arg)}(n,r,t,i)})}return t=t?t.then(i,i):i()}}function Y(e,t){var r=e.iterator[t.method];if(r===n){if(t.delegate=null,"throw"===t.method){if(e.iterator.return&&(t.method="return",t.arg=n,Y(e,t),"throw"===t.method))return m;t.method="throw",t.arg=new TypeError("The iterator does not provide a 'throw' method")}return m}var a=M(r,e.iterator,t.arg);if("throw"===a.type)return t.method="throw",t.arg=a.arg,t.delegate=null,m;var i=a.arg;return i?i.done?(t[e.resultName]=i.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=n),t.delegate=null,m):i:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,m)}function S(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function D(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function O(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(S,this),this.reset(!0)}function j(e){if(e){var t=e[o];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var r=-1,i=function t(){for(;++r=t||n<0||y&&e-m>=d}function M(){var e=a();if(b(e))return k(e);h=setTimeout(M,function(e){var n=t-(e-p);return y?u(n,d-(e-m)):n}(e))}function k(e){return h=void 0,v&&l?g(e):(l=c=void 0,f)}function w(){var e=a(),n=b(e);if(l=arguments,c=this,p=e,n){if(void 0===h)return function(e){return m=e,h=setTimeout(M,t),_?g(e):f}(p);if(y)return h=setTimeout(M,t),g(p)}return void 0===h&&(h=setTimeout(M,t)),f}return t=i(t)||0,r(n)&&(_=!!n.leading,d=(y="maxWait"in n)?s(i(n.maxWait)||0,t):d,v="trailing"in n?!!n.trailing:v),w.cancel=function(){void 0!==h&&clearTimeout(h),m=0,l=p=c=h=void 0},w.flush=function(){return void 0===h?f:k(a())},w}},function(e,t,n){var r=n(23);e.exports=function(){return r.Date.now()}},function(e,t,n){var r=n(53),a=Object.prototype,i=a.hasOwnProperty,o=a.toString,s=r?r.toStringTag:void 0;e.exports=function(e){var t=i.call(e,s),n=e[s];try{e[s]=void 0;var r=!0}catch(e){}var a=o.call(e);return r&&(t?e[s]=n:delete e[s]),a}},function(e,t){var n=Object.prototype.toString;e.exports=function(e){return n.call(e)}},,function(e,t,n){"use strict";var r=n(3);Object.defineProperty(t,"__esModule",{value:!0}),t.default=t.styles=void 0;var a=r(n(7)),i=r(n(10)),o=r(n(9)),s=r(n(1)),u=(r(n(0)),r(n(4))),l=(n(14),r(n(15))),c=n(119),d=(r(n(417)),[0,8,16,24,32,40]),f=["auto",!0,1,2,3,4,5,6,7,8,9,10,11,12];var h=function(e){return(0,o.default)({container:{boxSizing:"border-box",display:"flex",flexWrap:"wrap",width:"100%"},item:{boxSizing:"border-box",margin:"0"},zeroMinWidth:{minWidth:0},"direction-xs-column":{flexDirection:"column"},"direction-xs-column-reverse":{flexDirection:"column-reverse"},"direction-xs-row-reverse":{flexDirection:"row-reverse"},"wrap-xs-nowrap":{flexWrap:"nowrap"},"wrap-xs-wrap-reverse":{flexWrap:"wrap-reverse"},"align-items-xs-center":{alignItems:"center"},"align-items-xs-flex-start":{alignItems:"flex-start"},"align-items-xs-flex-end":{alignItems:"flex-end"},"align-items-xs-baseline":{alignItems:"baseline"},"align-content-xs-center":{alignContent:"center"},"align-content-xs-flex-start":{alignContent:"flex-start"},"align-content-xs-flex-end":{alignContent:"flex-end"},"align-content-xs-space-between":{alignContent:"space-between"},"align-content-xs-space-around":{alignContent:"space-around"},"justify-xs-center":{justifyContent:"center"},"justify-xs-flex-end":{justifyContent:"flex-end"},"justify-xs-space-between":{justifyContent:"space-between"},"justify-xs-space-around":{justifyContent:"space-around"},"justify-xs-space-evenly":{justifyContent:"space-evenly"}},function(e,t){var n={};return d.forEach(function(e,r){0!==r&&(n["spacing-".concat(t,"-").concat(e)]={margin:-e/2,width:"calc(100% + ".concat(e,"px)"),"& > $item":{padding:e/2}})}),n}(0,"xs"),c.keys.reduce(function(t,n){return function(e,t,n){var r={};f.forEach(function(e){var t="grid-".concat(n,"-").concat(e);if(!0!==e)if("auto"!==e){var a="".concat(Math.round(e/12*1e8)/1e6,"%");r[t]={flexBasis:a,flexGrow:0,maxWidth:a}}else r[t]={flexBasis:"auto",flexGrow:0,maxWidth:"none"};else r[t]={flexBasis:0,flexGrow:1,maxWidth:"100%"}}),"xs"===n?(0,o.default)(e,r):e[t.breakpoints.up(n)]=r}(t,e,n),t},{}))};function p(e){var t,n=e.alignContent,r=e.alignItems,l=e.classes,c=e.className,d=e.component,f=e.container,h=e.direction,m=e.item,_=e.justify,y=e.lg,v=e.md,g=e.sm,b=e.spacing,M=e.wrap,k=e.xl,w=e.xs,x=e.zeroMinWidth,L=(0,i.default)(e,["alignContent","alignItems","classes","className","component","container","direction","item","justify","lg","md","sm","spacing","wrap","xl","xs","zeroMinWidth"]),T=(0,u.default)((t={},(0,a.default)(t,l.container,f),(0,a.default)(t,l.item,m),(0,a.default)(t,l.zeroMinWidth,x),(0,a.default)(t,l["spacing-xs-".concat(String(b))],f&&0!==b),(0,a.default)(t,l["direction-xs-".concat(String(h))],h!==p.defaultProps.direction),(0,a.default)(t,l["wrap-xs-".concat(String(M))],M!==p.defaultProps.wrap),(0,a.default)(t,l["align-items-xs-".concat(String(r))],r!==p.defaultProps.alignItems),(0,a.default)(t,l["align-content-xs-".concat(String(n))],n!==p.defaultProps.alignContent),(0,a.default)(t,l["justify-xs-".concat(String(_))],_!==p.defaultProps.justify),(0,a.default)(t,l["grid-xs-".concat(String(w))],!1!==w),(0,a.default)(t,l["grid-sm-".concat(String(g))],!1!==g),(0,a.default)(t,l["grid-md-".concat(String(v))],!1!==v),(0,a.default)(t,l["grid-lg-".concat(String(y))],!1!==y),(0,a.default)(t,l["grid-xl-".concat(String(k))],!1!==k),t),c);return s.default.createElement(d,(0,o.default)({className:T},L))}t.styles=h,p.defaultProps={alignContent:"stretch",alignItems:"stretch",component:"div",container:!1,direction:"row",item:!1,justify:"flex-start",lg:!1,md:!1,sm:!1,spacing:0,wrap:"wrap",xl:!1,xs:!1,zeroMinWidth:!1};var m=(0,l.default)(h,{name:"MuiGrid"})(p);t.default=m},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r=function(e){return function(){return null}};t.default=r},function(e,t){e.exports=function(e,t){for(var n=-1,r=null==e?0:e.length;++n-1}},function(e,t,n){var r=n(67);e.exports=function(e,t){var n=this.__data__,a=r(n,e);return a<0?(++this.size,n.push([e,t])):n[a][1]=t,this}},function(e,t,n){var r=n(66);e.exports=function(){this.__data__=new r,this.size=0}},function(e,t){e.exports=function(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}},function(e,t){e.exports=function(e){return this.__data__.get(e)}},function(e,t){e.exports=function(e){return this.__data__.has(e)}},function(e,t,n){var r=n(66),a=n(98),i=n(99),o=200;e.exports=function(e,t){var n=this.__data__;if(n instanceof r){var s=n.__data__;if(!a||s.length-1?s[u?t[l]:l]:void 0}}},function(e,t,n){var r=n(279),a=n(24),i=n(492),o=Math.max;e.exports=function(e,t,n){var s=null==e?0:e.length;if(!s)return-1;var u=null==n?0:i(n);return u<0&&(u=o(s+u,0)),r(e,a(t,3),u)}},function(e,t,n){var r=n(280);e.exports=function(e){var t=r(e),n=t%1;return t==t?n?t-n:t:0}},function(e,t,n){var r=n(53),a=n(93),i=n(8),o=r?r.isConcatSpreadable:void 0;e.exports=function(e){return i(e)||a(e)||!!(o&&e&&e[o])}},function(e,t,n){var r=n(54),a=n(24),i=n(282),o=n(495),s=n(96),u=n(496),l=n(43);e.exports=function(e,t,n){var c=-1;t=r(t.length?t:[l],s(a));var d=i(e,function(e,n,a){return{criteria:r(t,function(t){return t(e)}),index:++c,value:e}});return o(d,function(e,t){return u(e,t,n)})}},function(e,t){e.exports=function(e,t){var n=e.length;for(e.sort(t);n--;)e[n]=e[n].value;return e}},function(e,t,n){var r=n(497);e.exports=function(e,t,n){for(var a=-1,i=e.criteria,o=t.criteria,s=i.length,u=n.length;++a=u?l:l*("desc"==n[a]?-1:1)}return e.index-t.index}},function(e,t,n){var r=n(41);e.exports=function(e,t){if(e!==t){var n=void 0!==e,a=null===e,i=e==e,o=r(e),s=void 0!==t,u=null===t,l=t==t,c=r(t);if(!u&&!c&&!o&&e>t||o&&s&&l&&!u&&!c||a&&s&&l||!n&&l||!i)return 1;if(!a&&!o&&!c&&e0){if(++t>=n)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}},function(e,t,n){var r=n(505),a=n(71),i=n(280);e.exports=function(e){return function(t,n,o){return o&&"number"!=typeof o&&a(t,n,o)&&(n=o=void 0),t=i(t),void 0===n?(n=t,t=0):n=i(n),o=void 0===o?tr&&(a=r,i=n),[a,i]}function c(e,t,n){if(e.lte(0))return new r.default(0);var a=i.default.getDigitCount(e.toNumber()),o=new r.default(10).pow(a),s=e.div(o),u=1!==a?.05:.1,l=new r.default(Math.ceil(s.div(u).toNumber())).add(n).mul(u).mul(o);return t?l:new r.default(Math.ceil(l))}function d(e,t,n){var o=1,s=new r.default(e);if(!s.isint()&&n){var u=Math.abs(e);u<1?(o=new r.default(10).pow(i.default.getDigitCount(e)-1),s=new r.default(Math.floor(s.div(o).toNumber())).mul(o)):u>1&&(s=new r.default(Math.floor(e)))}else 0===e?s=new r.default(Math.floor((t-1)/2)):n||(s=new r.default(Math.floor(e)));var l=Math.floor((t-1)/2);return(0,a.compose)((0,a.map)(function(e){return s.add(new r.default(e-l).mul(o)).toNumber()}),a.range)(0,t)}var f=(0,a.memoize)(function(e){var t=u(e,2),n=t[0],o=t[1],f=arguments.length>1&&void 0!==arguments[1]?arguments[1]:6,h=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],p=Math.max(f,2),m=u(l([n,o]),2),_=m[0],y=m[1];if(_===-1/0||y===1/0){var v=y===1/0?[_].concat(s((0,a.range)(0,f-1).map(function(){return 1/0}))):s((0,a.range)(0,f-1).map(function(){return-1/0})).concat([y]);return n>o?(0,a.reverse)(v):v}if(_===y)return d(_,f,h);var g=function e(t,n,a,i){var o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:0;if(!Number.isFinite((n-t)/(a-1)))return{step:new r.default(0),tickMin:new r.default(0),tickMax:new r.default(0)};var s,u=c(new r.default(n).sub(t).div(a-1),i,o);s=t<=0&&n>=0?new r.default(0):(s=new r.default(t).add(n).div(2)).sub(new r.default(s).mod(u));var l=Math.ceil(s.sub(t).div(u).toNumber()),d=Math.ceil(new r.default(n).sub(s).div(u).toNumber()),f=l+d+1;return f>a?e(t,n,a,i,o+1):(f0?d+(a-f):d,l=n>0?l:l+(a-f)),{step:u,tickMin:s.sub(new r.default(l).mul(u)),tickMax:s.add(new r.default(d).mul(u))})}(_,y,p,h),b=g.step,M=g.tickMin,k=g.tickMax,w=i.default.rangeStep(M,k.add(new r.default(.1).mul(b)),b);return n>o?(0,a.reverse)(w):w});t.getNiceTickValues=f;var h=(0,a.memoize)(function(e){var t=u(e,2),n=t[0],i=t[1],o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:6,s=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],f=Math.max(o,2),h=u(l([n,i]),2),p=h[0],m=h[1];if(p===-1/0||m===1/0)return[n,i];if(p===m)return d(p,o,s);var _=c(new r.default(m).sub(p).div(f-1),s,0),y=(0,a.compose)((0,a.map)(function(e){return new r.default(p).add(new r.default(e).mul(_)).toNumber()}),a.range)(0,f).filter(function(e){return e>=p&&e<=m});return n>i?(0,a.reverse)(y):y});t.getTickValues=h;var p=(0,a.memoize)(function(e,t){var n=u(e,2),o=n[0],d=n[1],f=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],h=u(l([o,d]),2),p=h[0],m=h[1];if(p===-1/0||m===1/0)return[o,d];if(p===m)return[p];var _=Math.max(t,2),y=c(new r.default(m).sub(p).div(_-1),f,0),v=s(i.default.rangeStep(new r.default(p),new r.default(m).sub(new r.default(.99).mul(y)),y)).concat([m]);return o>d?(0,a.reverse)(v):v});t.getTickValuesFixedDomain=p},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r,a=(r=n(287))&&r.__esModule?r:{default:r},i=n(288);var o={rangeStep:function(e,t,n){for(var r=new a.default(e),i=[];r.lt(t);)i.push(r.toNumber()),r=r.add(n);return i},getDigitCount:function(e){return 0===e?1:Math.floor(new a.default(e).abs().log(10).toNumber())+1},interpolateNumber:(0,i.curry)(function(e,t,n){var r=+e;return r+n*(+t-r)}),uninterpolateNumber:(0,i.curry)(function(e,t,n){var r=t-+e;return(n-e)/(r=r||1/0)}),uninterpolateTruncation:(0,i.curry)(function(e,t,n){var r=t-+e;return r=r||1/0,Math.max(0,Math.min(1,(n-e)/r))})};t.default=o},function(e,t,n){var r=n(64);e.exports=function(e,t){var n;return r(e,function(e,r,a){return!(n=t(e,r,a))}),!!n}},function(e,t,n){var r=n(284);e.exports=function(e,t,n){"__proto__"==t&&r?r(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}},function(e,t){function n(e,t,n){e instanceof RegExp&&(e=r(e,n)),t instanceof RegExp&&(t=r(t,n));var i=a(e,t,n);return i&&{start:i[0],end:i[1],pre:n.slice(0,i[0]),body:n.slice(i[0]+e.length,i[1]),post:n.slice(i[1]+t.length)}}function r(e,t){var n=t.match(e);return n?n[0]:null}function a(e,t,n){var r,a,i,o,s,u=n.indexOf(e),l=n.indexOf(t,u+1),c=u;if(u>=0&&l>0){for(r=[],i=n.length;c>=0&&!s;)c==u?(r.push(c),u=n.indexOf(e,c+1)):1==r.length?s=[r.pop(),l]:((a=r.pop())=0?u:l;r.length&&(s=[i,o])}return s}e.exports=n,n.range=a},function(e,t,n){var r=n(513);function a(e,t,n){var i=e;return function(e,t){var n=[],a="string"==typeof t?new RegExp("\\b("+t+")\\("):t;do{var i=a.exec(e);if(!i)return n;if(void 0===i[1])throw new Error("Missing the first couple of parenthesis to get the function identifier in "+t);var o=i[1],s=i.index,u=r("(",")",e.substring(s));if(!u||u.start!==i[0].length-1)throw new SyntaxError(o+"(): missing closing ')' in the value '"+e+"'");n.push({matches:u,functionIdentifier:o}),e=u.post}while(a.test(e));return n}(e,t).reduce(function(e,r){return e.replace(r.functionIdentifier+"("+r.matches.body+")",function(e,t,n,r,i){return n(a(e,i,n),t,r)}(r.matches.body,r.functionIdentifier,n,i,t))},e)}e.exports=a},function(e,t){function n(e,t,n){e instanceof RegExp&&(e=r(e,n)),t instanceof RegExp&&(t=r(t,n));var i=a(e,t,n);return i&&{start:i[0],end:i[1],pre:n.slice(0,i[0]),body:n.slice(i[0]+e.length,i[1]),post:n.slice(i[1]+t.length)}}function r(e,t){var n=t.match(e);return n?n[0]:null}function a(e,t,n){var r,a,i,o,s,u=n.indexOf(e),l=n.indexOf(t,u+1),c=u;if(u>=0&&l>0){for(r=[],i=n.length;c>=0&&!s;)c==u?(r.push(c),u=n.indexOf(e,c+1)):1==r.length?s=[r.pop(),l]:((a=r.pop())=0?u:l;r.length&&(s=[i,o])}return s}e.exports=n,n.range=a},function(e,t,n){var r=n(515);r.prototype.formulaEval=function(){"use strict";for(var e,t,n,r=[],a=this.value,i=0;i"+t.value+""+a[i].show+""+e.value+"",type:10}):r.push({value:(1!=t.type?"(":"")+t.value+(1!=t.type?")":"")+""+e.value+"",type:1})):2===a[i].type||9===a[i].type?(e=r.pop(),t=r.pop(),r.push({value:(1!=t.type?"(":"")+t.value+(1!=t.type?")":"")+a[i].show+(1!=e.type?"(":"")+e.value+(1!=e.type?")":""),type:a[i].type})):12===a[i].type&&(e=r.pop(),t=r.pop(),n=r.pop(),r.push({value:a[i].show+"("+n.value+","+t.value+","+e.value+")",type:12}));return r[0].value},e.exports=r},function(e,t,n){var r=n(516);r.prototype.postfixEval=function(e){"use strict";(e=e||{}).PI=Math.PI,e.E=Math.E;for(var t,n,a,i=[],o=this.value,s=void 0!==e.n,u=0;u1)throw new r.exception("Uncaught Syntax error");return i[0].value>1e15?"Infinity":parseFloat(i[0].value.toFixed(15))},r.eval=function(e,t,n){return void 0===t?this.lex(e).toPostfix().postfixEval():void 0===n?void 0!==t.length?this.lex(e,t).toPostfix().postfixEval():this.lex(e).toPostfix().postfixEval(t):this.lex(e,t).toPostfix().postfixEval(n)},e.exports=r},function(e,t,n){var r=n(517);r.prototype.toPostfix=function(){"use strict";for(var e,t,n,a,i,o=[],s=[{value:"(",type:4,pre:0}],u=this.value,l=1;ln)s.push(e);else{for(;n>=a&&!c||c&&av.length-2?v.length-1:w.length-i;y>0;y--)for(b=0;b=120&&y.length>=120)?new r(h&&y):void 0}y=e[0];var v=-1,g=p[0];e:for(;++v-1}},function(e,t,n){var r=n(279),a=n(524),i=n(525);e.exports=function(e,t,n){return t==t?i(e,t,n):r(e,a,n)}},function(e,t){e.exports=function(e){return e!=e}},function(e,t){e.exports=function(e,t,n){for(var r=n-1,a=e.length;++r=0||(a[n]=e[n]);return a}(e,["children","in"]),o=r.default.Children.toArray(t),s=o[0],u=o[1];return delete a.onEnter,delete a.onEntering,delete a.onEntered,delete a.onExit,delete a.onExiting,delete a.onExited,r.default.createElement(i.default,a,n?r.default.cloneElement(s,{key:"first",onEnter:this.handleEnter,onEntering:this.handleEntering,onEntered:this.handleEntered}):r.default.cloneElement(u,{key:"second",onEnter:this.handleExit,onEntering:this.handleExiting,onEntered:this.handleExited}))},o}(r.default.Component);s.propTypes={};var u=s;t.default=u,e.exports=t.default},function(e,t,n){"use strict";t.__esModule=!0,t.getChildMapping=a,t.mergeChildMappings=i,t.getInitialChildMapping=function(e,t){return a(e.children,function(n){return(0,r.cloneElement)(n,{onExited:t.bind(null,n),in:!0,appear:o(n,"appear",e),enter:o(n,"enter",e),exit:o(n,"exit",e)})})},t.getNextChildMapping=function(e,t,n){var s=a(e.children),u=i(t,s);return Object.keys(u).forEach(function(a){var i=u[a];if((0,r.isValidElement)(i)){var l=a in t,c=a in s,d=t[a],f=(0,r.isValidElement)(d)&&!d.props.in;!c||l&&!f?c||!l||f?c&&l&&(0,r.isValidElement)(d)&&(u[a]=(0,r.cloneElement)(i,{onExited:n.bind(null,i),in:d.props.in,exit:o(i,"exit",e),enter:o(i,"enter",e)})):u[a]=(0,r.cloneElement)(i,{in:!1}):u[a]=(0,r.cloneElement)(i,{onExited:n.bind(null,i),in:!0,exit:o(i,"exit",e),enter:o(i,"enter",e)})}}),u};var r=n(1);function a(e,t){var n=Object.create(null);return e&&r.Children.map(e,function(e){return e}).forEach(function(e){n[e.key]=function(e){return t&&(0,r.isValidElement)(e)?t(e):e}(e)}),n}function i(e,t){function n(n){return n in t?t[n]:e[n]}e=e||{},t=t||{};var r,a=Object.create(null),i=[];for(var o in e)o in t?i.length&&(a[o]=i,i=[]):i.push(o);var s={};for(var u in t){if(a[u])for(r=0;r1;const m=(e,t,n)=>{const r=e[f].get(t);if(r){const t=r.value;if(_(e,t)){if(v(e,r),!e[s])return}else n&&(e[h]&&(r.value.now=Date.now()),e[d].unshiftNode(r));return t.value}},_=(e,t)=>{if(!t||!t.maxAge&&!e[u])return!1;const n=Date.now()-t.now;return t.maxAge?n>t.maxAge:e[u]&&n>e[u]},y=e=>{if(e[i]>e[a])for(let t=e[d].tail;e[i]>e[a]&&null!==t;){const n=t.prev;v(e,t),t=n}},v=(e,t)=>{if(t){const n=t.value;e[l]&&e[l](n.key,n.value),e[i]-=n.length,e[f].delete(n.key),e[d].removeNode(t)}};class g{constructor(e,t,n,r,a){this.key=e,this.value=t,this.length=n,this.now=r,this.maxAge=a||0}}const b=(e,t,n,r)=>{let a=n.value;_(e,a)&&(v(e,n),e[s]||(a=void 0)),a&&t.call(r,a.value,a.key,e)};e.exports=class{constructor(e){if("number"==typeof e&&(e={max:e}),e||(e={}),e.max&&("number"!=typeof e.max||e.max<0))throw new TypeError("max must be a non-negative number");this[a]=e.max||1/0;const t=e.length||p;if(this[o]="function"!=typeof t?p:t,this[s]=e.stale||!1,e.maxAge&&"number"!=typeof e.maxAge)throw new TypeError("maxAge must be a number");this[u]=e.maxAge||0,this[l]=e.dispose,this[c]=e.noDisposeOnSet||!1,this[h]=e.updateAgeOnGet||!1,this.reset()}set max(e){if("number"!=typeof e||e<0)throw new TypeError("max must be a non-negative number");this[a]=e||1/0,y(this)}get max(){return this[a]}set allowStale(e){this[s]=!!e}get allowStale(){return this[s]}set maxAge(e){if("number"!=typeof e)throw new TypeError("maxAge must be a non-negative number");this[u]=e,y(this)}get maxAge(){return this[u]}set lengthCalculator(e){"function"!=typeof e&&(e=p),e!==this[o]&&(this[o]=e,this[i]=0,this[d].forEach(e=>{e.length=this[o](e.value,e.key),this[i]+=e.length})),y(this)}get lengthCalculator(){return this[o]}get length(){return this[i]}get itemCount(){return this[d].length}rforEach(e,t){t=t||this;for(let n=this[d].tail;null!==n;){const r=n.prev;b(this,e,n,t),n=r}}forEach(e,t){t=t||this;for(let n=this[d].head;null!==n;){const r=n.next;b(this,e,n,t),n=r}}keys(){return this[d].toArray().map(e=>e.key)}values(){return this[d].toArray().map(e=>e.value)}reset(){this[l]&&this[d]&&this[d].length&&this[d].forEach(e=>this[l](e.key,e.value)),this[f]=new Map,this[d]=new r,this[i]=0}dump(){return this[d].map(e=>!_(this,e)&&{k:e.key,v:e.value,e:e.now+(e.maxAge||0)}).toArray().filter(e=>e)}dumpLru(){return this[d]}set(e,t,n){if((n=n||this[u])&&"number"!=typeof n)throw new TypeError("maxAge must be a number");const r=n?Date.now():0,s=this[o](t,e);if(this[f].has(e)){if(s>this[a])return v(this,this[f].get(e)),!1;const o=this[f].get(e).value;return this[l]&&(this[c]||this[l](e,o.value)),o.now=r,o.maxAge=n,o.value=t,this[i]+=s-o.length,o.length=s,this.get(e),y(this),!0}const h=new g(e,t,s,r,n);return h.length>this[a]?(this[l]&&this[l](e,t),!1):(this[i]+=h.length,this[d].unshift(h),this[f].set(e,this[d].head),y(this),!0)}has(e){if(!this[f].has(e))return!1;const t=this[f].get(e).value;return!_(this,t)}get(e){return m(this,e,!0)}peek(e){return m(this,e,!1)}pop(){const e=this[d].tail;return e?(v(this,e),e.value):null}del(e){v(this,this[f].get(e))}load(e){this.reset();const t=Date.now();for(let n=e.length-1;n>=0;n--){const r=e[n],a=r.e||0;if(0===a)this.set(r.k,r.v);else{const e=a-t;e>0&&this.set(r.k,r.v,e)}}}prune(){this[f].forEach((e,t)=>m(this,t,!1))}}},function(e,t){function n(e,t,n,r,a,i,o){try{var s=e[i](o),u=s.value}catch(e){return void n(e)}s.done?t(u):Promise.resolve(u).then(r,a)}e.exports=function(e){return function(){var t=this,r=arguments;return new Promise(function(a,i){var o=e.apply(t,r);function s(e){n(o,a,i,s,u,"next",e)}function u(e){n(o,a,i,s,u,"throw",e)}s(void 0)})}}},,,,,,,,,,,,,,,,,,,,,,,,,,,,,,function(e,t){e.exports=function(e){if(Array.isArray(e))return e}},function(e,t){e.exports=function(e,t){var n=[],r=!0,a=!1,i=void 0;try{for(var o,s=e[Symbol.iterator]();!(r=(o=s.next()).done)&&(n.push(o.value),!t||n.length!==t);r=!0);}catch(e){a=!0,i=e}finally{try{r||null==s.return||s.return()}finally{if(a)throw i}}return n}},function(e,t){e.exports=function(){throw new TypeError("Invalid attempt to destructure non-iterable instance")}},function(e,t,n){"use strict";function r(e){var t=this;if(t instanceof r||(t=new r),t.tail=null,t.head=null,t.length=0,e&&"function"==typeof e.forEach)e.forEach(function(e){t.push(e)});else if(arguments.length>0)for(var n=0,a=arguments.length;n1)n=t;else{if(!this.head)throw new TypeError("Reduce of empty list with no initial value");r=this.head.next,n=this.head.value}for(var a=0;null!==r;a++)n=e(n,r.value,a),r=r.next;return n},r.prototype.reduceReverse=function(e,t){var n,r=this.tail;if(arguments.length>1)n=t;else{if(!this.tail)throw new TypeError("Reduce of empty list with no initial value");r=this.tail.prev,n=this.tail.value}for(var a=this.length-1;null!==r;a--)n=e(n,r.value,a),r=r.prev;return n},r.prototype.toArray=function(){for(var e=new Array(this.length),t=0,n=this.head;null!==n;t++)e[t]=n.value,n=n.next;return e},r.prototype.toArrayReverse=function(){for(var e=new Array(this.length),t=0,n=this.tail;null!==n;t++)e[t]=n.value,n=n.prev;return e},r.prototype.slice=function(e,t){(t=t||this.length)<0&&(t+=this.length),(e=e||0)<0&&(e+=this.length);var n=new r;if(tthis.length&&(t=this.length);for(var a=0,i=this.head;null!==i&&athis.length&&(t=this.length);for(var a=this.length,i=this.tail;null!==i&&a>t;a--)i=i.prev;for(;null!==i&&a>e;a--,i=i.prev)n.push(i.value);return n},r.prototype.reverse=function(){for(var e=this.head,t=this.tail,n=e;null!==n;n=n.prev){var r=n.prev;n.prev=n.next,n.next=r}return this.head=t,this.tail=e,this};try{n(578)(r)}catch(e){}},function(e,t,n){"use strict";e.exports=function(e){e.prototype[Symbol.iterator]=function*(){for(let e=this.head;e;e=e.next)yield e.value}}},,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,function(e,t,n){var r=function(){return this||"object"==typeof self&&self}()||Function("return this")(),a=r.regeneratorRuntime&&Object.getOwnPropertyNames(r).indexOf("regeneratorRuntime")>=0,i=a&&r.regeneratorRuntime;if(r.regeneratorRuntime=void 0,e.exports=n(613),a)r.regeneratorRuntime=i;else try{delete r.regeneratorRuntime}catch(e){r.regeneratorRuntime=void 0}},function(e,t){!function(t){"use strict";var n,r=Object.prototype,a=r.hasOwnProperty,i="function"==typeof Symbol?Symbol:{},o=i.iterator||"@@iterator",s=i.asyncIterator||"@@asyncIterator",u=i.toStringTag||"@@toStringTag",l="object"==typeof e,c=t.regeneratorRuntime;if(c)l&&(e.exports=c);else{(c=t.regeneratorRuntime=l?e.exports:{}).wrap=b;var d="suspendedStart",f="suspendedYield",h="executing",p="completed",m={},_={};_[o]=function(){return this};var y=Object.getPrototypeOf,v=y&&y(y(j([])));v&&v!==r&&a.call(v,o)&&(_=v);var g=x.prototype=k.prototype=Object.create(_);w.prototype=g.constructor=x,x.constructor=w,x[u]=w.displayName="GeneratorFunction",c.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===w||"GeneratorFunction"===(t.displayName||t.name))},c.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,x):(e.__proto__=x,u in e||(e[u]="GeneratorFunction")),e.prototype=Object.create(g),e},c.awrap=function(e){return{__await:e}},L(T.prototype),T.prototype[s]=function(){return this},c.AsyncIterator=T,c.async=function(e,t,n,r){var a=new T(b(e,t,n,r));return c.isGeneratorFunction(t)?a:a.next().then(function(e){return e.done?e.value:a.next()})},L(g),g[u]="Generator",g[o]=function(){return this},g.toString=function(){return"[object Generator]"},c.keys=function(e){var t=[];for(var n in e)t.push(n);return t.reverse(),function n(){for(;t.length;){var r=t.pop();if(r in e)return n.value=r,n.done=!1,n}return n.done=!0,n}},c.values=j,O.prototype={constructor:O,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=n,this.done=!1,this.delegate=null,this.method="next",this.arg=n,this.tryEntries.forEach(D),!e)for(var t in this)"t"===t.charAt(0)&&a.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=n)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var t=this;function r(r,a){return s.type="throw",s.arg=e,t.next=r,a&&(t.method="next",t.arg=n),!!a}for(var i=this.tryEntries.length-1;i>=0;--i){var o=this.tryEntries[i],s=o.completion;if("root"===o.tryLoc)return r("end");if(o.tryLoc<=this.prev){var u=a.call(o,"catchLoc"),l=a.call(o,"finallyLoc");if(u&&l){if(this.prev=0;--n){var r=this.tryEntries[n];if(r.tryLoc<=this.prev&&a.call(r,"finallyLoc")&&this.prev=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),D(n),m}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var a=r.arg;D(n)}return a}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,r){return this.delegate={iterator:j(e),resultName:t,nextLoc:r},"next"===this.method&&(this.arg=n),m}}}function b(e,t,n,r){var a=t&&t.prototype instanceof k?t:k,i=Object.create(a.prototype),o=new O(r||[]);return i._invoke=function(e,t,n){var r=d;return function(a,i){if(r===h)throw new Error("Generator is already running");if(r===p){if("throw"===a)throw i;return E()}for(n.method=a,n.arg=i;;){var o=n.delegate;if(o){var s=Y(o,n);if(s){if(s===m)continue;return s}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(r===d)throw r=p,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r=h;var u=M(e,t,n);if("normal"===u.type){if(r=n.done?p:f,u.arg===m)continue;return{value:u.arg,done:n.done}}"throw"===u.type&&(r=p,n.method="throw",n.arg=u.arg)}}}(e,n,o),i}function M(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}function k(){}function w(){}function x(){}function L(e){["next","throw","return"].forEach(function(t){e[t]=function(e){return this._invoke(t,e)}})}function T(e){var t;this._invoke=function(n,r){function i(){return new Promise(function(t,i){!function t(n,r,i,o){var s=M(e[n],e,r);if("throw"!==s.type){var u=s.arg,l=u.value;return l&&"object"==typeof l&&a.call(l,"__await")?Promise.resolve(l.__await).then(function(e){t("next",e,i,o)},function(e){t("throw",e,i,o)}):Promise.resolve(l).then(function(e){u.value=e,i(u)},function(e){return t("throw",e,i,o)})}o(s.arg)}(n,r,t,i)})}return t=t?t.then(i,i):i()}}function Y(e,t){var r=e.iterator[t.method];if(r===n){if(t.delegate=null,"throw"===t.method){if(e.iterator.return&&(t.method="return",t.arg=n,Y(e,t),"throw"===t.method))return m;t.method="throw",t.arg=new TypeError("The iterator does not provide a 'throw' method")}return m}var a=M(r,e.iterator,t.arg);if("throw"===a.type)return t.method="throw",t.arg=a.arg,t.delegate=null,m;var i=a.arg;return i?i.done?(t[e.resultName]=i.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=n),t.delegate=null,m):i:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,m)}function S(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function D(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function O(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(S,this),this.reset(!0)}function j(e){if(e){var t=e[o];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var r=-1,i=function t(){for(;++r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}},function(e,t){e.exports=function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}},function(e,t){e.exports=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}},function(e,t){function n(e,t){for(var n=0;n1&&void 0!==arguments[1]?arguments[1]:{};return function(n){var r,m=t.withTheme,y=void 0!==m&&m,b=t.flip,k=void 0===b?null:b,w=t.name,j=(0,d.default)(t,["withTheme","flip","name"]),C=(0,x.default)(e),Y=C.themingEnabled||"string"==typeof w||y;O+=1,C.options.index=O;var R=function(e){function t(e,n){var r;(0,i.default)(this,t),(r=(0,u.default)(this,(0,l.default)(t).call(this,e,n))).jss=n[v.default.jss]||D,r.sheetsManager=P,r.unsubscribeId=null;var a=n.muiThemeProviderOptions;return a&&(a.sheetsManager&&(r.sheetsManager=a.sheetsManager),r.sheetsCache=a.sheetsCache,r.disableStylesGeneration=a.disableStylesGeneration),r.stylesCreatorSaved=C,r.sheetOptions=(0,o.default)({generateClassName:T},n[v.default.sheetOptions]),r.theme=Y?M.default.initial(n)||E:L,r.attach(r.theme),r.cacheClasses={value:null,lastProp:null,lastJSS:{}},r}return(0,c.default)(t,e),(0,s.default)(t,[{key:"componentDidMount",value:function(){var e=this;Y&&(this.unsubscribeId=M.default.subscribe(this.context,function(t){var n=e.theme;e.theme=t,e.attach(e.theme),e.setState({},function(){e.detach(n)})}))}},{key:"componentDidUpdate",value:function(){this.stylesCreatorSaved}},{key:"componentWillUnmount",value:function(){this.detach(this.theme),null!==this.unsubscribeId&&M.default.unsubscribe(this.context,this.unsubscribeId)}},{key:"getClasses",value:function(){if(this.disableStylesGeneration)return this.props.classes||{};var e=!1,t=A.default.get(this.sheetsManager,this.stylesCreatorSaved,this.theme);return t.sheet.classes!==this.cacheClasses.lastJSS&&(this.cacheClasses.lastJSS=t.sheet.classes,e=!0),this.props.classes!==this.cacheClasses.lastProp&&(this.cacheClasses.lastProp=this.props.classes,e=!0),e&&(this.cacheClasses.value=(0,g.default)({baseClasses:this.cacheClasses.lastJSS,newClasses:this.props.classes,Component:n})),this.cacheClasses.value}},{key:"attach",value:function(e){if(!this.disableStylesGeneration){var t=this.stylesCreatorSaved,n=A.default.get(this.sheetsManager,t,e);if(n||(n={refs:0,sheet:null},A.default.set(this.sheetsManager,t,e,n)),0===n.refs){var r;this.sheetsCache&&(r=A.default.get(this.sheetsCache,t,e)),r||((r=this.createSheet(e)).attach(),this.sheetsCache&&A.default.set(this.sheetsCache,t,e,r)),n.sheet=r;var a=this.context[v.default.sheetsRegistry];a&&a.add(r)}n.refs+=1}}},{key:"createSheet",value:function(e){var t=this.stylesCreatorSaved.create(e,w),r=w;return this.jss.createStyleSheet(t,(0,o.default)({meta:r,classNamePrefix:r,flip:"boolean"==typeof k?k:"rtl"===e.direction,link:!1},this.sheetOptions,this.stylesCreatorSaved.options,{name:w||n.displayName},j))}},{key:"detach",value:function(e){if(!this.disableStylesGeneration){var t=A.default.get(this.sheetsManager,this.stylesCreatorSaved,e);if(t.refs-=1,0===t.refs){A.default.delete(this.sheetsManager,this.stylesCreatorSaved,e),this.jss.removeStyleSheet(t.sheet);var n=this.context[v.default.sheetsRegistry];n&&n.remove(t.sheet)}}}},{key:"render",value:function(){var e=this.props,t=(e.classes,e.innerRef),r=(0,d.default)(e,["classes","innerRef"]),a=(0,S.default)({theme:this.theme,name:w,props:r});return y&&!a.theme&&(a.theme=this.theme),f.default.createElement(n,(0,o.default)({},a,{classes:this.getClasses(),ref:t}))}}]),t}(f.default.Component);return R.contextTypes=(0,o.default)((r={muiThemeProviderOptions:p.default.object},(0,a.default)(r,v.default.jss,p.default.object),(0,a.default)(r,v.default.sheetOptions,p.default.object),(0,a.default)(r,v.default.sheetsRegistry,p.default.object),r),Y?M.default.contextTypes:{}),(0,h.default)(R,n),R}});t.default=function(e,t){return m.ponyfillGlobal.__MUI_STYLES__.withStyles(e,(0,o.default)({defaultTheme:E},t))}},function(e,t,n){var r=n(55),a=n(11);e.exports=function(e,t){return!t||"object"!==r(t)&&"function"!=typeof t?a(e):t}},function(e,t){function n(t){return e.exports=n=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},n(t)}e.exports=n},function(e,t,n){var r=n(343);e.exports=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}}),t&&r(e,t)}},function(e,t,n){"use strict";var r=function(){};e.exports=r},function(e,t){e.exports=function(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}},function(e,t,n){"use strict";var r=n(3);Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"createGenerateClassName",{enumerable:!0,get:function(){return a.default}}),Object.defineProperty(t,"createMuiTheme",{enumerable:!0,get:function(){return o.default}}),Object.defineProperty(t,"jssPreset",{enumerable:!0,get:function(){return i.default}}),Object.defineProperty(t,"MuiThemeProvider",{enumerable:!0,get:function(){return s.default}}),Object.defineProperty(t,"createStyles",{enumerable:!0,get:function(){return u.default}}),Object.defineProperty(t,"withStyles",{enumerable:!0,get:function(){return l.default}}),Object.defineProperty(t,"withTheme",{enumerable:!0,get:function(){return c.default}});var a=r(n(118)),o=r(n(87)),i=r(n(126)),s=r(n(394)),u=r(n(397)),l=r(n(15)),c=r(n(113))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.MODIFIER_KEY_NAMES=t.DEFAULT_VERTICAL_SPACING=t.FANG_HEIGHT_PX=t.FANG_WIDTH_PX=t.WEEKDAYS=t.BLOCKED_MODIFIER=t.DAY_SIZE=t.OPEN_UP=t.OPEN_DOWN=t.ANCHOR_RIGHT=t.ANCHOR_LEFT=t.INFO_POSITION_AFTER=t.INFO_POSITION_BEFORE=t.INFO_POSITION_BOTTOM=t.INFO_POSITION_TOP=t.ICON_AFTER_POSITION=t.ICON_BEFORE_POSITION=t.VERTICAL_SCROLLABLE=t.VERTICAL_ORIENTATION=t.HORIZONTAL_ORIENTATION=t.END_DATE=t.START_DATE=t.ISO_MONTH_FORMAT=t.ISO_FORMAT=t.DISPLAY_FORMAT=void 0;t.DISPLAY_FORMAT="L";t.ISO_FORMAT="YYYY-MM-DD";t.ISO_MONTH_FORMAT="YYYY-MM";t.START_DATE="startDate";t.END_DATE="endDate";t.HORIZONTAL_ORIENTATION="horizontal";t.VERTICAL_ORIENTATION="vertical";t.VERTICAL_SCROLLABLE="verticalScrollable";t.ICON_BEFORE_POSITION="before";t.ICON_AFTER_POSITION="after";t.INFO_POSITION_TOP="top";t.INFO_POSITION_BOTTOM="bottom";t.INFO_POSITION_BEFORE="before";t.INFO_POSITION_AFTER="after";t.ANCHOR_LEFT="left";t.ANCHOR_RIGHT="right";t.OPEN_DOWN="down";t.OPEN_UP="up";t.DAY_SIZE=39;t.BLOCKED_MODIFIER="blocked";t.WEEKDAYS=[0,1,2,3,4,5,6];t.FANG_WIDTH_PX=20;t.FANG_HEIGHT_PX=10;t.DEFAULT_VERTICAL_SPACING=22;var r=new Set(["Shift","Control","Alt","Meta"]);t.MODIFIER_KEY_NAMES=r},function(e,t,n){var r=n(261),a="object"==typeof self&&self&&self.Object===Object&&self,o=r||a||Function("return this")();e.exports=o},function(e,t,n){var r=n(432),a=n(478),o=n(43),i=n(8),s=n(487);e.exports=function(e){return"function"==typeof e?e:null==e?o:"object"==typeof e?i(e)?a(e[0],e[1]):r(e):s(e)}},function(e,t,n){"use strict";!function e(){if("undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE)try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(e){console.error(e)}}(),e.exports=n(340)},function(e,t,n){var r=n(100);e.exports=function(e,t){return r(e,t)}},function(e,t,n){"use strict";n.d(t,"c",function(){return v}),n.d(t,"a",function(){return g}),n.d(t,"b",function(){return A});var r=n(12),a=n.n(r),o=n(13),i=n.n(o),s=n(7),u=n.n(s),l="updatePatterns",c="getPatterns",d="updateCalendars",f="getCalendars",p="getCalEvents",h="updateConfig",m="getConfig",y="getGraphData",v=Object.freeze({updatePatterns:Symbol(l),getPatterns:Symbol(c),updateCalendars:Symbol(d),getCalendars:Symbol(f),getCalEvents:Symbol(p),updateConfig:Symbol(h),getConfig:Symbol(m),getGraphData:Symbol(y)});function b(e){switch(e){case v.updatePatterns:return l;case v.getPatterns:return c;case v.updateCalendars:return d;case v.getCalendars:return f;case v.getCalEvents:return p;case v.updateConfig:return h;case v.getConfig:return m;case v.getGraphData:return y;default:console.error("unreachable")}}var g=function(){function e(t,n,r){a()(this,e),this.id=t,this.type=n,this.data=r}return i()(e,[{key:"genResp",value:function(t){return new e(this.id,this.type,t)}},{key:"deflate",value:function(){return{id:this.id,type:b(this.type),data:this.data}}}]),e}();u()(g,"inflate",function(e){return new g(e.id,function(e){switch(e){case l:return v.updatePatterns;case c:return v.getPatterns;case d:return v.updateCalendars;case f:return v.getCalendars;case p:return v.getCalEvents;case h:return v.updateConfig;case m:return v.getConfig;case y:return v.getGraphData;default:console.error("unreachable")}}(e.type),e.data)});var A=function e(t){var n=this;a()(this,e),u()(this,"sendMsg",function(e){var t,r,a=e.type,o=e.data,i=n.requestCallback,s=new Promise(function(e){t=e});return r=i.ids.length>0?i.ids.pop():i.maxId++,i.inFlight[r]=t,n.port.postMessage(new g(r,a,o).deflate()),s});var r=chrome.runtime.connect({name:t});r.onMessage.addListener(function(e){console.log(e);var t=(e.type,n.requestCallback),r=t.inFlight[e.id];console.assert(void 0!==r),t.ids.push(e.id),r(e)}),this.port=r,this.requestCallback={inFlight:{},ids:[],maxId:0}}},function(e,t){e.exports=function(e){return null!=e&&"object"==typeof e}},function(e,t,n){var r=n(30),a=n(8),o=n(28),i="[object String]";e.exports=function(e){return"string"==typeof e||!a(e)&&o(e)&&r(e)==i}},function(e,t,n){var r=n(53),a=n(413),o=n(414),i="[object Null]",s="[object Undefined]",u=r?r.toStringTag:void 0;e.exports=function(e){return null==e?void 0===e?s:i:u&&u in Object(e)?a(e):o(e)}},function(e,t,n){(function(t){for(var r=n(519),a="undefined"==typeof window?t:window,o=["moz","webkit"],i="AnimationFrame",s=a["request"+i],u=a["cancel"+i]||a["cancelRequest"+i],l=0;!s&&l-1?e[n]:void 0},t.createChainedFunction=function(){for(var e=arguments.length,t=new Array(e),n=0;n1&&void 0!==arguments[1]&&arguments[1];if(!Array.isArray(e))return e;var n="";if(Array.isArray(e[0]))for(var a=0;a0&&void 0!==arguments[0]?arguments[0]:"unnamed",t=arguments[1],n=arguments[2],i=n.jss,s=(0,o.default)(t),u=i.plugins.onCreateRule(e,s,n);if(u)return u;"@"===e[0]&&(0,r.default)(!1,"[JSS] Unknown at-rule %s",e);return new a.default(e,s,n)};var r=i(n(39)),a=i(n(40)),o=i(n(365));function i(e){return e&&e.__esModule?e:{default:e}}},function(e,t,n){"use strict";n.r(t),n.d(t,"isBrowser",function(){return a});var r="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},a="object"===("undefined"==typeof window?"undefined":r(window))&&"object"===("undefined"==typeof document?"undefined":r(document))&&9===document.nodeType;t.default=a},function(e,t,n){var r=n(263),a=n(431)(r);e.exports=a},function(e,t,n){var r=n(422),a=n(428),o=n(42);e.exports=function(e){return o(e)?r(e):a(e)}},function(e,t,n){var r=n(434),a=n(435),o=n(436),i=n(437),s=n(438);function u(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t1&&i(e,t[0],t[1])?t=[]:n>2&&i(t[0],t[1],t[2])&&(t=[t[0]]),a(e,r(t,1),[])});e.exports=s},function(e,t,n){"use strict";var r=s(n(530)),a=s(n(534)),o=s(n(107)),i=s(n(80));function s(e){return e&&e.__esModule?e:{default:e}}e.exports={Transition:i.default,TransitionGroup:o.default,ReplaceTransition:a.default,CSSTransition:r.default}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r={50:"#fff3e0",100:"#ffe0b2",200:"#ffcc80",300:"#ffb74d",400:"#ffa726",500:"#ff9800",600:"#fb8c00",700:"#f57c00",800:"#ef6c00",900:"#e65100",A100:"#ffd180",A200:"#ffab40",A400:"#ff9100",A700:"#ff6d00"};t.default=r},function(e,t,n){var r,a=n(511),o=n(512),i=n(514),s=100,u=/(\+|\-|\*|\\|[^a-z]|)(\s*)(\()/g;e.exports=function(e,t){function n(e,o,l){if(r++>s)throw r=0,new Error("Call stack overflow for "+l);if(""===e)throw new Error(o+"(): '"+l+"' must contain a non-whitespace string");var c=function(e){var t=[],n=[],r=/[\.0-9]([%a-z]+)/gi,a=r.exec(e);for(;a;)a&&a[1]&&(-1===n.indexOf(a[1].toLowerCase())&&(t.push(a[1]),n.push(a[1].toLowerCase())),a=r.exec(e));return t}(e=function(e,t){e=e.replace(/((?:\-[a-z]+\-)?calc)/g,"");var r,o="",i=e;for(;r=u.exec(i);){r[0].index>0&&(o+=i.substring(0,r[0].index));var s=a("(",")",i.substring([0].index));if(""===s.body)throw new Error("'"+e+"' must contain a non-whitespace string");var l=n(s.body,"",t);o+=s.pre+l,i=s.post}return o+i}(e,l));if(c.length>1||e.indexOf("var(")>-1)return o+"("+e+")";var d=c[0]||"";"%"===d&&(e=e.replace(/\b[0-9\.]+%/g,function(e){return.01*parseFloat(e.slice(0,-1))}));var f,p=e.replace(new RegExp(d,"gi"),"");try{f=i.eval(p)}catch(t){return o+"("+e+")"}return"%"===d&&(f*=100),(o.length||"%"===d)&&(f=Math.round(f*t)/t),f+=d}return r=0,t=Math.pow(10,void 0===t?5:t),e=e.replace(/\n+/g," "),o(e,/((?:\-[a-z]+\-)?calc)\(/,n)}},function(e,t,n){"use strict";var r=n(548);e.exports=function(e,t,n){return!r(e.props,t)||!r(e.state,n)}},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.withStylesPropTypes=t.css=void 0;var r=Object.assign||function(e){for(var t=1;t1&&void 0!==arguments[1]?arguments[1]:{},n=t.stylesPropName,i=void 0===n?"styles":n,c=t.themePropName,f=void 0===c?"theme":c,h=t.cssPropName,b=void 0===h?"css":h,g=t.flushBefore,A=void 0!==g&&g,k=t.pureComponent,M=void 0!==k&&k,w=void 0,x=void 0,S=void 0,D=void 0,T=function(e){if(e){if(!o.default.PureComponent)throw new ReferenceError("withStyles() pureComponent option requires React 15.3.0 or later");return o.default.PureComponent}return o.default.Component}(M);function O(e){return e===l.DIRECTIONS.LTR?d.default.resolveLTR:d.default.resolveRTL}function P(t,n){var r=function(e){return e===l.DIRECTIONS.LTR?S:D}(t),a=t===l.DIRECTIONS.LTR?w:x,o=d.default.get();if(a&&r===o)return a;var i=t===l.DIRECTIONS.RTL;return i?(x=e?d.default.createRTL(e):m,D=o,a=x):(w=e?d.default.createLTR(e):m,S=o,a=w),a}function L(e,t){return{resolveMethod:O(e),styleDef:P(e,t)}}return function(){return function(e){var t=e.displayName||e.name||"Component",n=function(n){function s(e,n){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,s);var r=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(s.__proto__||Object.getPrototypeOf(s)).call(this,e,n)),a=r.context[l.CHANNEL]?r.context[l.CHANNEL].getState():v;return r.state=L(a,t),r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(s,n),a(s,[{key:"componentDidMount",value:function(){return function(){var e=this;this.context[l.CHANNEL]&&(this.channelUnsubscribe=this.context[l.CHANNEL].subscribe(function(n){e.setState(L(n,t))}))}}()},{key:"componentWillUnmount",value:function(){return function(){this.channelUnsubscribe&&this.channelUnsubscribe()}}()},{key:"render",value:function(){return function(){var t;A&&d.default.flush();var n=this.state,a=n.resolveMethod,s=n.styleDef;return o.default.createElement(e,r({},this.props,(p(t={},f,d.default.get()),p(t,i,s()),p(t,b,a),t)))}}()}]),s}(T);n.WrappedComponent=e,n.displayName="withStyles("+String(t)+")",n.contextTypes=y,e.propTypes&&(n.propTypes=(0,u.default)({},e.propTypes),delete n.propTypes[i],delete n.propTypes[f],delete n.propTypes[b]);e.defaultProps&&(n.defaultProps=(0,u.default)({},e.defaultProps));return(0,s.default)(n,e)}}()};var o=f(n(1)),i=f(n(0)),s=f(n(774)),u=f(n(775)),l=n(776),c=f(n(777)),d=f(n(638));function f(e){return e&&e.__esModule?e:{default:e}}function p(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}t.css=d.default.resolveLTR,t.withStylesPropTypes={styles:i.default.object.isRequired,theme:i.default.object.isRequired,css:i.default.func.isRequired};var h={},m=function(){return h};var y=p({},l.CHANNEL,c.default),v=l.DIRECTIONS.LTR},function(e,t,n){"use strict";t.__esModule=!0,t.default=t.EXITING=t.ENTERED=t.ENTERING=t.EXITED=t.UNMOUNTED=void 0;var r=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){var r=Object.defineProperty&&Object.getOwnPropertyDescriptor?Object.getOwnPropertyDescriptor(e,n):{};r.get||r.set?Object.defineProperty(t,n,r):t[n]=e[n]}return t.default=e,t}(n(0)),a=s(n(1)),o=s(n(25)),i=n(289);n(290);function s(e){return e&&e.__esModule?e:{default:e}}var u="unmounted";t.UNMOUNTED=u;var l="exited";t.EXITED=l;var c="entering";t.ENTERING=c;var d="entered";t.ENTERED=d;t.EXITING="exiting";var f=function(e){var t,n;function r(t,n){var r;r=e.call(this,t,n)||this;var a,o=n.transitionGroup,i=o&&!o.isMounting?t.enter:t.appear;return r.appearStatus=null,t.in?i?(a=l,r.appearStatus=c):a=d:a=t.unmountOnExit||t.mountOnEnter?u:l,r.state={status:a},r.nextCallback=null,r}n=e,(t=r).prototype=Object.create(n.prototype),t.prototype.constructor=t,t.__proto__=n;var i=r.prototype;return i.getChildContext=function(){return{transitionGroup:null}},r.getDerivedStateFromProps=function(e,t){return e.in&&t.status===u?{status:l}:null},i.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},i.componentDidUpdate=function(e){var t=null;if(e!==this.props){var n=this.state.status;this.props.in?n!==c&&n!==d&&(t=c):n!==c&&n!==d||(t="exiting")}this.updateStatus(!1,t)},i.componentWillUnmount=function(){this.cancelNextCallback()},i.getTimeouts=function(){var e,t,n,r=this.props.timeout;return e=t=n=r,null!=r&&"number"!=typeof r&&(e=r.exit,t=r.enter,n=r.appear),{exit:e,enter:t,appear:n}},i.updateStatus=function(e,t){if(void 0===e&&(e=!1),null!==t){this.cancelNextCallback();var n=o.default.findDOMNode(this);t===c?this.performEnter(n,e):this.performExit(n)}else this.props.unmountOnExit&&this.state.status===l&&this.setState({status:u})},i.performEnter=function(e,t){var n=this,r=this.props.enter,a=this.context.transitionGroup?this.context.transitionGroup.isMounting:t,o=this.getTimeouts();t||r?(this.props.onEnter(e,a),this.safeSetState({status:c},function(){n.props.onEntering(e,a),n.onTransitionEnd(e,o.enter,function(){n.safeSetState({status:d},function(){n.props.onEntered(e,a)})})})):this.safeSetState({status:d},function(){n.props.onEntered(e)})},i.performExit=function(e){var t=this,n=this.props.exit,r=this.getTimeouts();n?(this.props.onExit(e),this.safeSetState({status:"exiting"},function(){t.props.onExiting(e),t.onTransitionEnd(e,r.exit,function(){t.safeSetState({status:l},function(){t.props.onExited(e)})})})):this.safeSetState({status:l},function(){t.props.onExited(e)})},i.cancelNextCallback=function(){null!==this.nextCallback&&(this.nextCallback.cancel(),this.nextCallback=null)},i.safeSetState=function(e,t){t=this.setNextCallback(t),this.setState(e,t)},i.setNextCallback=function(e){var t=this,n=!0;return this.nextCallback=function(r){n&&(n=!1,t.nextCallback=null,e(r))},this.nextCallback.cancel=function(){n=!1},this.nextCallback},i.onTransitionEnd=function(e,t,n){this.setNextCallback(n),e?(this.props.addEndListener&&this.props.addEndListener(e,this.nextCallback),null!=t&&setTimeout(this.nextCallback,t)):setTimeout(this.nextCallback,0)},i.render=function(){var e=this.state.status;if(e===u)return null;var t=this.props,n=t.children,r=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r=0||(a[n]=e[n]);return a}(t,["children"]);if(delete r.in,delete r.mountOnEnter,delete r.unmountOnExit,delete r.appear,delete r.enter,delete r.exit,delete r.timeout,delete r.addEndListener,delete r.onEnter,delete r.onEntering,delete r.onEntered,delete r.onExit,delete r.onExiting,delete r.onExited,"function"==typeof n)return n(e,r);var o=a.default.Children.only(n);return a.default.cloneElement(o,r)},r}(a.default.Component);function p(){}f.contextTypes={transitionGroup:r.object},f.childContextTypes={transitionGroup:function(){}},f.propTypes={},f.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:p,onEntering:p,onEntered:p,onExit:p,onExiting:p,onExited:p},f.UNMOUNTED=0,f.EXITED=1,f.ENTERING=2,f.ENTERED=3,f.EXITING=4;var h=(0,i.polyfill)(f);t.default=h},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r={50:"#e0f7fa",100:"#b2ebf2",200:"#80deea",300:"#4dd0e1",400:"#26c6da",500:"#00bcd4",600:"#00acc1",700:"#0097a7",800:"#00838f",900:"#006064",A100:"#84ffff",A200:"#18ffff",A400:"#00e5ff",A700:"#00b8d4"};t.default=r},function(e,t,n){"use strict";e.exports=function(e,t,n,r,a,o,i,s){if(!e){var u;if(void 0===t)u=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var l=[n,r,a,o,i,s],c=0;(u=new Error(t.replace(/%s/g,function(){return l[c++]}))).name="Invariant Violation"}throw u.framesToPop=1,u}}},function(e,t,n){"use strict";n.d(t,"e",function(){return b}),n.d(t,"b",function(){return g}),n.d(t,"f",function(){return A}),n.d(t,"g",function(){return k}),n.d(t,"c",function(){return M}),n.d(t,"d",function(){return w}),n.d(t,"a",function(){return S});var r=n(12),a=n.n(r),o=n(13),i=n.n(o),s=n(49),u=n.n(s),l=n(105),c=n.n(l),d=n(543),f=n.n(d),p="https://www.googleapis.com/calendar/v3",h=Object.freeze({invalidSyncToken:Symbol("invalidSyncToken"),notLoggedIn:Symbol("notLoggedIn"),notLoggedOut:Symbol("notLoggedOut"),otherError:Symbol("otherError")});function m(e){return Object.entries(e).filter(function(e){var t=c()(e,2);t[0];return t[1]}).map(function(e){var t=c()(e,2),n=t[0],r=t[1];return"".concat(encodeURIComponent(n),"=").concat(encodeURIComponent(r))}).join("&")}var y=null;function v(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];return new Promise(function(t){return chrome.identity.getAuthToken({interactive:e},function(e){return t([e,!chrome.runtime.lastError])})}).then(function(e){var t=c()(e,2),n=t[0];if(t[1])return n;throw h.notLoggedIn})}function b(){return null===y?v(!1).then(function(){return y=!0}).catch(function(){return y=!1}).then(function(){return y}):Promise.resolve(y)}function g(){return b().then(function(e){if(e)return v(!1);throw h.notLoggedIn})}function A(){return b().then(function(e){if(e)throw h.notLoggedOut;return v(!0).then(function(){return y=!0})})}function k(){return g().then(function(e){return fetch("https://accounts.google.com/o/oauth2/revoke?".concat(m({token:e})),{method:"GET",async:!0}).then(function(t){return function(e){return new Promise(function(t){return chrome.identity.removeCachedAuthToken({token:e},function(){return t()})})}(e)})}).then(function(){return y=!1})}function M(e){return fetch("".concat(p,"/users/me/calendarList?").concat(m({access_token:e})),{method:"GET",async:!0}).then(function(e){return e.json()}).then(function(e){return e.items})}function w(e){return fetch("".concat(p,"/colors?").concat(m({access_token:e})),{method:"GET",async:!0}).then(function(e){return e.json()})}function x(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null,o=arguments.length>5&&void 0!==arguments[5]?arguments[5]:100,i=[];return function n(s,l){return fetch("".concat(p,"/calendars/").concat(e,"/events?").concat(m({access_token:t,pageToken:s,syncToken:l,timeMin:r,timeMax:a,maxResults:o})),{method:"GET",async:!0}).then(function(e){if(200===e.status)return e.json();throw 410===e.status?h.invalidSyncToken:h.otherError}).then(function(e){return i.push.apply(i,u()(e.items)),e.nextPageToken?n(e.nextPageToken,""):{nextSyncToken:e.nextSyncToken,results:i}})}("",n)}var S=function(){function e(t,n){var r=this,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{maxCachedItems:100,nDaysPerSlot:10,largeQuery:10};a()(this,e),this.calId=t,this.name=n,this.syncToken="",this.cache=new f.a({max:o.maxCachedItems,dispose:function(e,t){return r.onRemoveSlot(e,t)}}),this.eventMeta={},this.options=o,this.divider=864e5*this.options.nDaysPerSlot}return i()(e,[{key:"dateToCacheKey",value:function(e){return Math.floor(e/this.divider)}},{key:"dateRangeToCacheKeys",value:function(e){return{start:this.dateToCacheKey(e.start),end:this.dateToCacheKey(new Date(e.end.getTime()-1))}}},{key:"getSlot",value:function(e){if(this.cache.has(e))return this.cache.get(e);var t={};return this.cache.set(e,t),t}},{key:"onRemoveSlot",value:function(e,t){for(var n in t){console.assert(this.eventMeta[n]);var r=this.eventMeta[n].keys;r.delete(e),0===r.size&&delete this.eventMeta[n]}}},{key:"slotStartDate",value:function(e){return new Date(e*this.divider)}},{key:"slotEndDate",value:function(e){return new Date((e+1)*this.divider)}},{key:"addEvent",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];this.eventMeta.hasOwnProperty(e.id)&&this.removeEvent(e);for(var n=this.dateRangeToCacheKeys(e),r=n.start,a=n.end,o=this.cache.length,i=new Set,s=r;s<=a;s++)i.add(s),this.cache.has(s)||o++;if(this.eventMeta[e.id]={keys:i,summary:e.summary},t||!(o>this.options.maxCachedItems))if(r===a)this.getSlot(r)[e.id]={start:e.start,end:e.end,id:e.id};else{this.getSlot(r)[e.id]={start:e.start,end:this.slotEndDate(r),id:e.id},this.getSlot(a)[e.id]={start:this.slotStartDate(a),end:e.end,id:e.id};for(var u=r+1;u=n||r[o].end<=t||a.push({id:o,start:r[o].startn?n:r[o].end,summary:this.eventMeta[o].summary});return a}},{key:"getCachedEvents",value:function(e){for(var t=this.dateRangeToCacheKeys(e),n=t.start,r=t.end,a=this.getSlotEvents(n,e.start,e.end),o=n+1;on&&a.push.apply(a,u()(this.getSlotEvents(r,e.start,e.end))),a}},{key:"sync",value:function(){var e=this;return this.token.then(function(t){return x(e.calId,t,e.syncToken).then(function(n){var r=n.results.map(function(n){return n.start?Promise.resolve(n):function(e,t,n){return fetch("".concat(p,"/calendars/").concat(e,"/events/").concat(t,"?").concat(m({access_token:n})),{method:"GET",async:!0}).then(function(e){return e.json()})}(e.calId,n.id,t)});return Promise.all(r).then(function(t){t.forEach(function(t){t.start=new Date(t.start.dateTime),t.end=new Date(t.end.dateTime),"confirmed"===t.status?e.addEvent(t):"cancelled"===t.status&&e.removeEvent(t)}),e.syncToken=n.nextSyncToken})})}).catch(function(t){if(t!==h.invalidSyncToken)throw t;e.syncToken="",e.sync()})}},{key:"getEvents",value:function(e,t){for(var n=this,r=this.dateRangeToCacheKeys({start:e,end:t}),a={},o=r.start;o<=r.end;o++)this.cache.has(o)||(a.hasOwnProperty("start")||(a.start=o),a.end=o);return console.log("start: ".concat(e," end: ").concat(t)),a.hasOwnProperty("start")?(console.assert(a.start<=a.end),a.end-a.start+1>this.options.largeQuery?(console.log("encounter large query, use direct fetch"),this.token.then(function(r){return x(n.calId,r,null,e.toISOString(),t.toISOString()).then(function(n){var r=[];return n.results.forEach(function(e){console.assert(e.start),e.start=new Date(e.start.dateTime),e.end=new Date(e.end.dateTime),r.push(e)}),r.filter(function(n){return!(n.start>=t||n.end<=e)}).map(function(n){return{id:n.id,start:n.startt?t:n.end,summary:n.summary}})})})):(console.log("fetching short event list"),this.token.then(function(e){return x(n.calId,e,null,n.slotStartDate(a.start).toISOString(),n.slotEndDate(a.end).toISOString()).then(function(e){e.results.forEach(function(e){"confirmed"===e.status&&(console.assert(e.start),e.start=new Date(e.start.dateTime),e.end=new Date(e.end.dateTime),n.addEvent(e,!0))}),""===n.syncToken&&(n.syncToken=e.nextSyncToken)})}).then(function(){return n.sync()}).then(function(){return n.getCachedEvents({start:e,end:t})}))):(console.log("cache hit"),this.sync().then(function(){return n.getCachedEvents({start:e,end:t})}))}},{key:"token",get:function(){return g()}}]),e}()},function(e,t,n){"use strict";var r=n(3);Object.defineProperty(t,"__esModule",{value:!0}),t.convertHexToRGB=o,t.rgbToHex=function(e){if(0===e.indexOf("#"))return e;var t=i(e).values;return t=t.map(function(e){return 1===(t=e.toString(16)).length?"0".concat(t):t;var t}),"#".concat(t.join(""))},t.decomposeColor=i,t.recomposeColor=s,t.getContrastRatio=function(e,t){var n=u(e),r=u(t);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)},t.getLuminance=u,t.emphasize=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:.15;return u(e)>.5?l(e,t):c(e,t)},t.fade=function(e,t){if(!e)return e;e=i(e),t=a(t),("rgb"===e.type||"hsl"===e.type)&&(e.type+="a");return e.values[3]=t,s(e)},t.darken=l,t.lighten=c;r(n(19));function a(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;return en?n:e}function o(e){e=e.substr(1);var t=new RegExp(".{1,".concat(e.length/3,"}"),"g"),n=e.match(t);return n&&1===n[0].length&&(n=n.map(function(e){return e+e})),n?"rgb(".concat(n.map(function(e){return parseInt(e,16)}).join(", "),")"):""}function i(e){if("#"===e.charAt(0))return i(o(e));var t=e.indexOf("("),n=e.substring(0,t),r=e.substring(t+1,e.length-1).split(",");return{type:n,values:r=r.map(function(e){return parseFloat(e)})}}function s(e){var t=e.type,n=e.values;return-1!==t.indexOf("rgb")&&(n=n.map(function(e,t){return t<3?parseInt(e,10):e})),-1!==t.indexOf("hsl")&&(n[1]="".concat(n[1],"%"),n[2]="".concat(n[2],"%")),"".concat(e.type,"(").concat(n.join(", "),")")}function u(e){var t=i(e);if(-1!==t.type.indexOf("rgb")){var n=t.values.map(function(e){return(e/=255)<=.03928?e/12.92:Math.pow((e+.055)/1.055,2.4)});return Number((.2126*n[0]+.7152*n[1]+.0722*n[2]).toFixed(3))}return t.values[2]/100}function l(e,t){if(!e)return e;if(e=i(e),t=a(t),-1!==e.type.indexOf("hsl"))e.values[2]*=1-t;else if(-1!==e.type.indexOf("rgb"))for(var n=0;n<3;n+=1)e.values[n]*=1-t;return s(e)}function c(e,t){if(!e)return e;if(e=i(e),t=a(t),-1!==e.type.indexOf("hsl"))e.values[2]+=(100-e.values[2])*t;else if(-1!==e.type.indexOf("rgb"))for(var n=0;n<3;n+=1)e.values[n]+=(255-e.values[n])*t;return s(e)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r=function(e){return e&&e.ownerDocument||document};t.default=r},function(e,t,n){"use strict";var r=n(3);Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"default",{enumerable:!0,get:function(){return a.default}});var a=r(n(610))},function(e,t,n){"use strict";var r=n(3);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;r(n(7));var a=r(n(9)),o=r(n(10)),i=r(n(60)),s=r(n(347)),u=(r(n(19)),r(n(119))),l=r(n(349)),c=r(n(350)),d=r(n(356)),f=r(n(358)),p=r(n(359)),h=r(n(360)),m=r(n(111)),y=r(n(361));var v=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.breakpoints,n=void 0===t?{}:t,r=e.mixins,v=void 0===r?{}:r,b=e.palette,g=void 0===b?{}:b,A=e.shadows,k=e.spacing,M=void 0===k?{}:k,w=e.typography,x=void 0===w?{}:w,S=(0,o.default)(e,["breakpoints","mixins","palette","shadows","spacing","typography"]),D=(0,c.default)(g),T=(0,u.default)(n),O=(0,a.default)({},h.default,M);return(0,a.default)({breakpoints:T,direction:"ltr",mixins:(0,l.default)(T,O,v),overrides:{},palette:D,props:{},shadows:A||f.default,typography:(0,d.default)(D,x)},(0,i.default)({shape:p.default,spacing:O,transitions:m.default,zIndex:y.default},S,{isMergeableObject:s.default}))};t.default=v},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r="";if(!t)return r;var a=n.indent,s=void 0===a?0:a,u=t.fallbacks;if(s++,u)if(Array.isArray(u))for(var l=0;l-1&&e%1==0&&e-1&&e%1==0&&e<=n}},function(e,t){e.exports=function(e){return function(t){return e(t)}}},function(e,t){e.exports=function(e,t){return e===t||e!=e&&t!=t}},function(e,t,n){var r=n(34)(n(23),"Map");e.exports=r},function(e,t,n){var r=n(448),a=n(455),o=n(457),i=n(458),s=n(459);function u(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t=0||(a[n]=e[n]);return a}(e,["component","childFactory"]),o=c(this.state.children).map(n);return delete r.appear,delete r.enter,delete r.exit,null===t?o:a.default.createElement(t,r,o)},r}(a.default.Component);d.childContextTypes={transitionGroup:r.default.object.isRequired},d.propTypes={},d.defaultProps={component:"div",childFactory:function(e){return e}};var f=(0,o.polyfill)(d);t.default=f,e.exports=t.default},function(e,t,n){var r=n(411),a=n(20),o="Expected a function";e.exports=function(e,t,n){var i=!0,s=!0;if("function"!=typeof e)throw new TypeError(o);return a(n)&&(i="leading"in n?!!n.leading:i,s="trailing"in n?!!n.trailing:s),r(e,t,{leading:i,maxWait:t,trailing:s})}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r={50:"#fbe9e7",100:"#ffccbc",200:"#ffab91",300:"#ff8a65",400:"#ff7043",500:"#ff5722",600:"#f4511e",700:"#e64a19",800:"#d84315",900:"#bf360c",A100:"#ff9e80",A200:"#ff6e40",A400:"#ff3d00",A700:"#dd2c00"};t.default=r},function(e,t,n){"use strict";var r=n(3);Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"default",{enumerable:!0,get:function(){return a.default}});var a=r(n(902))},function(e,t,n){"use strict";var r=n(3);Object.defineProperty(t,"__esModule",{value:!0}),t.default=t.isNumber=t.isString=t.formatMs=t.duration=t.easing=void 0;var a=r(n(10)),o=(r(n(19)),{easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",easeIn:"cubic-bezier(0.4, 0, 1, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"});t.easing=o;var i={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};t.duration=i;var s=function(e){return"".concat(Math.round(e),"ms")};t.formatMs=s;t.isString=function(e){return"string"==typeof e};t.isNumber=function(e){return!isNaN(parseFloat(e))};var u={easing:o,duration:i,create:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:["all"],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.duration,r=void 0===n?i.standard:n,u=t.easing,l=void 0===u?o.easeInOut:u,c=t.delay,d=void 0===c?0:c;(0,a.default)(t,["duration","easing","delay"]);return(Array.isArray(e)?e:[e]).map(function(e){return"".concat(e," ").concat("string"==typeof r?r:s(r)," ").concat(l," ").concat("string"==typeof d?d:s(d))}).join(",")},getAutoHeightDuration:function(e){if(!e)return 0;var t=e/36;return Math.round(10*(4+15*Math.pow(t,.25)+t/5))}};t.default=u},function(e,t,n){"use strict";var r=n(121),a={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},o={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},i={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},s={};function u(e){return r.isMemo(e)?i:s[e.$$typeof]||a}s[r.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0};var l=Object.defineProperty,c=Object.getOwnPropertyNames,d=Object.getOwnPropertySymbols,f=Object.getOwnPropertyDescriptor,p=Object.getPrototypeOf,h=Object.prototype;e.exports=function e(t,n,r){if("string"!=typeof n){if(h){var a=p(n);a&&a!==h&&e(t,a,r)}var i=c(n);d&&(i=i.concat(d(n)));for(var s=u(t),m=u(n),y=0;y0?1:-1},W=function(e){return L()(e)&&e.indexOf("%")===e.length-1},z=function(e){return F()(e)&&!I()(e)},V=function(e){return z(e)||L()(e)},U=0,K=function(e){var t=++U;return"".concat(e||"").concat(t)},G=function(e,t){var n,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,a=arguments.length>3&&void 0!==arguments[3]&&arguments[3];if(!z(e)&&!L()(e))return r;if(W(e)){var o=e.indexOf("%");n=t*parseFloat(e.slice(0,o))/100}else n=+e;return I()(n)&&(n=r),a&&n>t&&(n=t),n},q=function(e){if(!e)return null;var t=Object.keys(e);return t&&t.length?e[t[0]]:null},Z=function(e,t){return z(e)&&z(t)?function(n){return e+n*(t-e)}:function(){return t}},Q=function(e,t,n){return e&&e.length?e.find(function(e){return e&&N()(e,t)===n}):null};function X(e,t){for(var n in e)if({}.hasOwnProperty.call(e,n)&&(!{}.hasOwnProperty.call(t,n)||e[n]!==t[n]))return!1;for(var r in t)if({}.hasOwnProperty.call(t,r)&&!{}.hasOwnProperty.call(e,r))return!1;return!0}function J(e,t){return!X(e,this.props)||!X(t,this.state)}function $(e){e.prototype.shouldComponentUpdate=J}function ee(e){return function(e){if(Array.isArray(e)){for(var t=0,n=new Array(e.length);t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var ne={alignmentBaseline:s.a.string,angle:s.a.number,baselineShift:s.a.string,clip:s.a.string,clipPath:s.a.string,clipRule:s.a.string,color:s.a.string,colorInterpolation:s.a.string,colorInterpolationFilters:s.a.string,colorProfile:s.a.string,colorRendering:s.a.string,cursor:s.a.string,direction:s.a.oneOf(["ltr","rtl","inherit"]),display:s.a.string,dominantBaseline:s.a.string,enableBackground:s.a.string,fill:s.a.string,fillOpacity:s.a.oneOfType([s.a.string,s.a.number]),fillRule:s.a.oneOf(["nonzero","evenodd","inherit"]),filter:s.a.string,floodColor:s.a.string,floodOpacity:s.a.oneOfType([s.a.string,s.a.number]),font:s.a.string,fontFamily:s.a.string,fontSize:s.a.oneOfType([s.a.number,s.a.string]),fontSizeAdjust:s.a.oneOfType([s.a.number,s.a.string]),fontStretch:s.a.oneOf(["normal","wider","narrower","ultra-condensed","extra-condensed","condensed","semi-condensed","semi-expanded","expanded","extra-expanded","ultra-expanded","inherit"]),fontStyle:s.a.oneOf(["normal","italic","oblique","inherit"]),fontVariant:s.a.oneOf(["normal","small-caps","inherit"]),fontWeight:s.a.oneOf(["normal","bold","bolder","lighter",100,200,300,400,500,600,700,800,900,"inherit"]),glyphOrientationHorizontal:s.a.string,glyphOrientationVertical:s.a.string,imageRendering:s.a.oneOf(["auto","optimizeSpeed","optimizeQuality","inherit"]),kerning:s.a.oneOfType([s.a.number,s.a.string]),letterSpacing:s.a.oneOfType([s.a.number,s.a.string]),lightingColor:s.a.string,lineHeight:s.a.oneOfType([s.a.number,s.a.string]),markerEnd:s.a.string,markerMid:s.a.string,markerStart:s.a.string,mask:s.a.string,opacity:s.a.oneOfType([s.a.number,s.a.string]),overflow:s.a.oneOf(["visible","hidden","scroll","auto","inherit"]),pointerEvents:s.a.oneOf(["visiblePainted","visibleFill","visibleStroke","visible","painted","fill","stroke","all","none","inherit"]),shapeRendering:s.a.oneOf(["auto","optimizeSpeed","crispEdges","geometricPrecision","inherit"]),stopColor:s.a.string,stopOpacity:s.a.oneOfType([s.a.number,s.a.string]),stroke:s.a.oneOfType([s.a.number,s.a.string]),strokeDasharray:s.a.string,strokeDashoffset:s.a.oneOfType([s.a.number,s.a.string]),strokeLinecap:s.a.oneOf(["butt","round","square","inherit"]),strokeLinejoin:s.a.oneOf(["miter","round","bevel","inherit"]),strokeMiterlimit:s.a.oneOfType([s.a.number,s.a.string]),strokeOpacity:s.a.oneOfType([s.a.number,s.a.string]),strokeWidth:s.a.oneOfType([s.a.number,s.a.string]),textAnchor:s.a.oneOf(["start","middle","end","inherit"]),textDecoration:s.a.oneOf(["none","underline","overline","line-through","blink","inherit"]),textRendering:s.a.oneOf(["auto","optimizeSpeed","optimizeLegibility","geometricPrecision","inherit"]),unicodeBidi:s.a.oneOf(["normal","embed","bidi-override","inherit"]),visibility:s.a.oneOf(["visible","hidden","collapse","inherit"]),wordSpacing:s.a.oneOfType([s.a.number,s.a.string]),writingMode:s.a.oneOf(["lr-tb","rl-tb","tb-rl","lr","rl","tb","inherit"]),transform:s.a.string,style:s.a.object,width:s.a.number,height:s.a.number,dx:s.a.number,dy:s.a.number,x:s.a.number,y:s.a.number,r:s.a.number,radius:s.a.oneOfType([s.a.number,s.a.array])},re={onClick:s.a.func,onMouseDown:s.a.func,onMouseUp:s.a.func,onMouseOver:s.a.func,onMouseMove:s.a.func,onMouseOut:s.a.func,onMouseEnter:s.a.func,onMouseLeave:s.a.func,onTouchEnd:s.a.func,onTouchMove:s.a.func,onTouchStart:s.a.func,onTouchCancel:s.a.func},ae={click:"onClick",mousedown:"onMouseDown",mouseup:"onMouseUp",mouseover:"onMouseOver",mousemove:"onMouseMove",mouseout:"onMouseOut",mouseenter:"onMouseEnter",mouseleave:"onMouseLeave",touchcancel:"onTouchCancel",touchend:"onTouchEnd",touchmove:"onTouchMove",touchstart:"onTouchStart"},oe=["plainline","line","square","rect","circle","cross","diamond","star","triangle","wye","none"],ie=function(e){return"string"==typeof e?e:e?e.displayName||e.name||"Component":""},se=function(e,t){var n=[],r=[];return r=Y()(t)?t.map(function(e){return ie(e)}):[ie(t)],o.a.Children.forEach(e,function(e){var t=e&&e.type&&(e.type.displayName||e.type.name);-1!==r.indexOf(t)&&n.push(e)}),n},ue=function(e,t){var n=se(e,t);return n&&n[0]},le=function(e){if(!e||A()(e))return null;var t=o.a.isValidElement(e)?e.props:e;if(!j()(t))return null;var n=null;for(var r in t)({}).hasOwnProperty.call(t,r)&&ne[r]&&(n||(n={}),n[r]=t[r]);return n},ce=function(e,t){return function(n){return e(t,n),null}},de=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if(!e||A()(e))return null;var r=o.a.isValidElement(e)?e.props:e;if(!j()(r))return null;var a=null;for(var i in r)({}).hasOwnProperty.call(r,i)&&re[i]&&(a||(a={}),a[i]=t||(n?ce(r[i],r):r[i]));return a},fe=function(e,t,n){return function(r){return e(t,n,r),null}},pe=function(e,t,n){if(!j()(e))return null;var r=null;for(var a in e)({}).hasOwnProperty.call(e,a)&&re[a]&&A()(e[a])&&(r||(r={}),r[a]=fe(e[a],t,n));return r},he=function(e){if(!e||!e.props)return!1;var t=e.props,n=t.width,r=t.height;return!(!z(n)||n<=0||!z(r)||r<=0)},me=function(){return!("undefined"!=typeof window&&window.document&&window.document.createElement&&window.setTimeout)},ye=["a","altGlyph","altGlyphDef","altGlyphItem","animate","animateColor","animateMotion","animateTransform","circle","clipPath","color-profile","cursor","defs","desc","ellipse","feBlend","feColormatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","filter","font","font-face","font-face-format","font-face-name","font-face-url","foreignObject","g","glyph","glyphRef","hkern","image","line","lineGradient","marker","mask","metadata","missing-glyph","mpath","path","pattern","polygon","polyline","radialGradient","rect","script","set","stop","style","svg","switch","symbol","text","textPath","title","tref","tspan","use","view","vkern"],ve=function(e,t){if(D()(e)&&D()(t))return!0;if(!D()(e)&&!D()(t)){var n=e.props||{},r=n.children,a=te(n,["children"]),o=t.props||{},i=o.children,s=te(o,["children"]);return r&&i?X(a,s)&&be(r,i):!r&&!i&&X(a,s)}return!1},be=function e(t,n){if(t===n)return!0;if(a.Children.count(t)!==a.Children.count(n))return!1;var r=a.Children.count(t);if(0===r)return!0;if(1===r)return ve(Y()(t)?t[0]:t,Y()(n)?n[0]:n);for(var o=0;o=0}(e))n.push(e);else if(e&&t[ie(e.type)]){var o=ie(e.type),i=t[o],s=i.handler,u=i.once;if(u&&!r[o]||!u){var l=s(e,o,a);Y()(l)?n=[n].concat(ee(l)):n.push(l),r[o]=!0}}}),n},Ae=function(e){var t=e&&e.type;return t&&ae[t]?ae[t]:null};function ke(){return(ke=Object.assign||function(e){for(var t=1;t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var we={width:s.a.number.isRequired,height:s.a.number.isRequired,viewBox:s.a.shape({x:s.a.number,y:s.a.number,width:s.a.number,height:s.a.number}),className:s.a.string,style:s.a.object,children:s.a.oneOfType([s.a.arrayOf(s.a.node),s.a.node])};function xe(e){var t=e.children,n=e.width,r=e.height,a=e.viewBox,i=e.className,s=e.style,u=Me(e,["children","width","height","viewBox","className","style"]),l=a||{width:n,height:r,x:0,y:0},c=O()("recharts-surface",i),d=le(u);return o.a.createElement("svg",ke({},d,{className:c,width:n,height:r,style:s,viewBox:"".concat(l.x," ").concat(l.y," ").concat(l.width," ").concat(l.height),version:"1.1"}),t)}xe.propTypes=we;var Se=xe;function De(){return(De=Object.assign||function(e){for(var t=1;t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var Oe={className:s.a.string,children:s.a.oneOfType([s.a.arrayOf(s.a.node),s.a.node])};function Pe(e){var t=e.children,n=e.className,r=Te(e,["children","className"]),a=O()("recharts-layer",n);return o.a.createElement("g",De({className:a},r),t)}Pe.propTypes=Oe;var Le=Pe,Ee=n(26),je=n.n(Ee),Ce=n(31),Ye=n.n(Ce);function Re(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=-1;Ye()(function r(a){n<0&&(n=a),a-n>t?(e(a),n=-1):Ye()(r)})}function Ne(e){return(Ne="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})(e)}function _e(e){return function(e){if(Array.isArray(e))return e}(e)||function(e){if(Symbol.iterator in Object(e)||"[object Arguments]"===Object.prototype.toString.call(e))return Array.from(e)}(e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance")}()}function Ie(){var e=function(){return null},t=!1;return{stop:function(){t=!0},start:function(n){t=!1,function n(r){if(!t){if(Array.isArray(r)){if(!r.length)return;var a=_e(r),o=a[0],i=a.slice(1);return"number"==typeof o?void Re(n.bind(null,i),o):(n(o),void Re(n.bind(null,i)))}"object"===Ne(r)&&e(r),"function"==typeof r&&r()}}(n)},subscribe:function(t){return e=t,function(){e=function(){return null}}}}}var He=n(57),Fe=n.n(He);function Be(e){return(Be="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})(e)}function We(e,t){if(e===t)return!0;if("object"!==Be(e)||null===e||"object"!==Be(t)||null===t)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(var a=hasOwnProperty.bind(t),o=0;o=0&&e<=1});var s,u,l=ot(r,o),c=ot(a,i),d=(s=r,u=o,function(e){var t=nt(rt(s,u).map(function(e,t){return e*t}).slice(1)).concat([0]);return at(t,e)}),f=function(e){for(var t,n=e>1?1:e,r=n,a=0;a<8;++a){var o=l(r)-n,i=d(r);if(Math.abs(o-n)<1e-4||i<1e-4)return c(r);r=(t=r-o/i)>1?1:t<0?0:t}return c(r)};return f.isStepper=!1,f},st=function(){for(var e=arguments.length,t=new Array(e),n=0;n0&&void 0!==arguments[0]?arguments[0]:{},t=e.stiff,n=void 0===t?100:t,r=e.damping,a=void 0===r?8:r,o=e.dt,i=void 0===o?17:o,s=function(e,t,r){var o=r+(-(e-t)*n-r*a)*i/1e3,s=r*i/1e3+e;return Math.abs(s-t)<1e-4&&Math.abs(o)<1e-4?[t,0]:[s,o]};return s.isStepper=!0,s.dt=i,s}()}return"function"==typeof r?r:null},ut=n(301),lt=n.n(ut);function ct(e){return function(e){if(Array.isArray(e)){for(var t=0,n=new Array(e.length);t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}function Mt(e){return function(e){if(Array.isArray(e)){for(var t=0,n=new Array(e.length);t0?n[a-1]:r,f=l||Object.keys(u);if("function"==typeof s||"spring"===s)return Mt(e).concat([t.runJSAnimation.bind(t,{from:d.style,to:u,duration:o,easing:s}),o]);var p=tt(f,o,s),h=wt({},d.style,u,{transition:p});return Mt(e).concat([h,o,c]).filter(Je)},[i,Math.max(u,r)])),[e.onAnimationEnd]))}},{key:"runAnimation",value:function(e){this.manager||(this.manager=Ie());var t=e.begin,n=e.duration,r=e.attributeName,a=e.to,o=e.easing,i=e.onAnimationStart,s=e.onAnimationEnd,u=e.steps,l=e.children,c=this.manager;if(this.unSubscribe=c.subscribe(this.handleStyleChange),"function"!=typeof o&&"function"!=typeof l&&"spring"!==o)if(u.length>1)this.runStepAnimation(e);else{var d=r?xt({},r,a):a,f=tt(Object.keys(d),n,o);c.start([i,t,wt({},d,{transition:f}),n,s])}else this.runJSAnimation(e)}},{key:"handleStyleChange",value:function(e){this.changeStyle(e)}},{key:"changeStyle",value:function(e){this.mounted&&this.setState({style:e})}},{key:"render",value:function(){var e=this.props,t=e.children,n=(e.begin,e.duration,e.attributeName,e.easing,e.isActive),r=(e.steps,e.from,e.to,e.canBegin,e.onAnimationEnd,e.shouldReAnimate,e.onAnimationReStart,kt(e,["children","begin","duration","attributeName","easing","isActive","steps","from","to","canBegin","onAnimationEnd","shouldReAnimate","onAnimationReStart"])),i=a.Children.count(t),s=et(this.state.style);if("function"==typeof t)return t(s);if(!n||0===i)return t;var u=function(e){var t=e.props,n=t.style,o=void 0===n?{}:n,i=t.className;return Object(a.cloneElement)(e,wt({},r,{style:wt({},o,s),className:i}))};return 1===i?u(a.Children.only(t)):o.a.createElement("div",null,a.Children.map(t,function(e){return u(e)}))}}])&&St(n.prototype,r),i&&St(n,i),t}(),mt.displayName="Animate",mt.propTypes={from:s.a.oneOfType([s.a.object,s.a.string]),to:s.a.oneOfType([s.a.object,s.a.string]),attributeName:s.a.string,duration:s.a.number,begin:s.a.number,easing:s.a.oneOfType([s.a.string,s.a.func]),steps:s.a.arrayOf(s.a.shape({duration:s.a.number.isRequired,style:s.a.object.isRequired,easing:s.a.oneOfType([s.a.oneOf(["ease","ease-in","ease-out","ease-in-out","linear"]),s.a.func]),properties:s.a.arrayOf("string"),onAnimationEnd:s.a.func})),children:s.a.oneOfType([s.a.node,s.a.func]),isActive:s.a.bool,canBegin:s.a.bool,onAnimationEnd:s.a.func,shouldReAnimate:s.a.bool,onAnimationStart:s.a.func,onAnimationReStart:s.a.func},mt.defaultProps={begin:0,duration:1e3,from:"",to:"",attributeName:"",easing:"ease",isActive:!0,canBegin:!0,steps:[],onAnimationEnd:function(){},onAnimationStart:function(){}},ht=yt))||ht,Et=n(75);function jt(e){return(jt="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})(e)}function Ct(){return(Ct=Object.assign||function(e){for(var t=1;t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}function Rt(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Nt(e,t){for(var n=0;n0&&void 0!==arguments[0]?arguments[0]:{},t=e.steps,n=e.duration;return t&&t.length?t.reduce(function(e,t){return e+(F()(t.duration)&&t.duration>0?t.duration:0)},0):F()(n)?n:0},Bt=function(e){function t(){var e,n;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);for(var r=arguments.length,a=new Array(r),o=0;o1||Math.abs(r.height-n)>1)&&this.setState({boxWidth:r.width,boxHeight:r.height})}else-1===t&&-1===n||this.setState({boxWidth:-1,boxHeight:-1})}},{key:"render",value:function(){var e,t,n,r=this,a=this.props,i=a.payload,s=a.isAnimationActive,u=a.animationDuration,l=a.animationEasing,c=a.filterNull&&i&&i.length?i.filter(function(e){return!D()(e.value)}):i,d=c&&c.length,f=this.props,p=f.content,h=f.viewBox,m=f.coordinate,y=f.position,v=f.active,b=f.offset,g=un({pointerEvents:"none",visibility:v&&d?"visible":"hidden",position:"absolute",top:0},f.wrapperStyle);if(y&&z(y.x)&&z(y.y))t=y.x,n=y.y;else{var k=this.state,M=k.boxWidth,w=k.boxHeight;M>0&&w>0&&m?(t=y&&z(y.x)?y.x:Math.max(m.x+M+b>h.x+h.width?m.x-M-b:m.x+b,h.x),n=y&&z(y.y)?y.y:Math.max(m.y+w+b>h.y+h.height?m.y-w-b:m.y+b,h.y)):g.visibility="hidden"}g=un({},g,et({transform:this.props.useTranslate3d?"translate3d(".concat(t,"px, ").concat(n,"px, 0)"):"translate(".concat(t,"px, ").concat(n,"px)")})),s&&v&&(g=un({},g,et({transition:"transform ".concat(u,"ms ").concat(l)})));var x=O()(hn,(ln(e={},"".concat(hn,"-right"),z(t)&&m&&z(m.x)&&t>=m.x),ln(e,"".concat(hn,"-left"),z(t)&&m&&z(m.x)&&t=m.y),ln(e,"".concat(hn,"-top"),z(n)&&m&&z(m.y)&&n1e-6)if(Math.abs(c*s-u*l)>1e-6&&a){var f=n-o,p=r-i,h=s*s+u*u,m=f*f+p*p,y=Math.sqrt(h),v=Math.sqrt(d),b=a*Math.tan((bn-Math.acos((h+d-m)/(2*y*v)))/2),g=b/v,A=b/y;Math.abs(g-1)>1e-6&&(this._+="L"+(e+g*l)+","+(t+g*c)),this._+="A"+a+","+a+",0,0,"+ +(c*f>l*p)+","+(this._x1=e+A*s)+","+(this._y1=t+A*u)}else this._+="L"+(this._x1=e)+","+(this._y1=t);else;},arc:function(e,t,n,r,a,o){e=+e,t=+t;var i=(n=+n)*Math.cos(r),s=n*Math.sin(r),u=e+i,l=t+s,c=1^o,d=o?r-a:a-r;if(n<0)throw new Error("negative radius: "+n);null===this._x1?this._+="M"+u+","+l:(Math.abs(this._x1-u)>1e-6||Math.abs(this._y1-l)>1e-6)&&(this._+="L"+u+","+l),n&&(d<0&&(d=d%gn+gn),d>An?this._+="A"+n+","+n+",0,1,"+c+","+(e-i)+","+(t-s)+"A"+n+","+n+",0,1,"+c+","+(this._x1=u)+","+(this._y1=l):d>1e-6&&(this._+="A"+n+","+n+",0,"+ +(d>=bn)+","+c+","+(this._x1=e+n*Math.cos(a))+","+(this._y1=t+n*Math.sin(a))))},rect:function(e,t,n,r){this._+="M"+(this._x0=this._x1=+e)+","+(this._y0=this._y1=+t)+"h"+ +n+"v"+ +r+"h"+-n+"Z"},toString:function(){return this._}};var wn=Mn,xn=function(e){return function(){return e}},Sn=(Math.abs,Math.atan2,Math.cos,Math.max,Math.min,Math.sin,Math.sqrt,1e-12),Dn=Math.PI,Tn=2*Dn;function On(e){this._context=e}On.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:this._context.lineTo(e,t)}}};var Pn=function(e){return new On(e)};function Ln(e){return e[0]}function En(e){return e[1]}var jn=function(){var e=Ln,t=En,n=xn(!0),r=null,a=Pn,o=null;function i(i){var s,u,l,c=i.length,d=!1;for(null==r&&(o=a(l=wn())),s=0;s<=c;++s)!(s=c;--d)s.point(y[d],v[d]);s.lineEnd(),s.areaEnd()}m&&(y[l]=+e(f,l,u),v[l]=+n(f,l,u),s.point(t?+t(f,l,u):y[l],r?+r(f,l,u):v[l]))}if(p)return s=null,p+""||null}function l(){return jn().defined(a).curve(i).context(o)}return u.x=function(n){return arguments.length?(e="function"==typeof n?n:xn(+n),t=null,u):e},u.x0=function(t){return arguments.length?(e="function"==typeof t?t:xn(+t),u):e},u.x1=function(e){return arguments.length?(t=null==e?null:"function"==typeof e?e:xn(+e),u):t},u.y=function(e){return arguments.length?(n="function"==typeof e?e:xn(+e),r=null,u):n},u.y0=function(e){return arguments.length?(n="function"==typeof e?e:xn(+e),u):n},u.y1=function(e){return arguments.length?(r=null==e?null:"function"==typeof e?e:xn(+e),u):r},u.lineX0=u.lineY0=function(){return l().x(e).y(n)},u.lineY1=function(){return l().x(e).y(r)},u.lineX1=function(){return l().x(t).y(n)},u.defined=function(e){return arguments.length?(a="function"==typeof e?e:xn(!!e),u):a},u.curve=function(e){return arguments.length?(i=e,null!=o&&(s=i(o)),u):i},u.context=function(e){return arguments.length?(null==e?o=s=null:s=i(o=e),u):o},u};Rn(Pn);function Yn(e){this._curve=e}function Rn(e){function t(t){return new Yn(e(t))}return t._curve=e,t}Yn.prototype={areaStart:function(){this._curve.areaStart()},areaEnd:function(){this._curve.areaEnd()},lineStart:function(){this._curve.lineStart()},lineEnd:function(){this._curve.lineEnd()},point:function(e,t){this._curve.point(t*Math.sin(e),t*-Math.cos(e))}};var Nn=Array.prototype.slice;var _n={draw:function(e,t){var n=Math.sqrt(t/Dn);e.moveTo(n,0),e.arc(0,0,n,0,Tn)}},In={draw:function(e,t){var n=Math.sqrt(t/5)/2;e.moveTo(-3*n,-n),e.lineTo(-n,-n),e.lineTo(-n,-3*n),e.lineTo(n,-3*n),e.lineTo(n,-n),e.lineTo(3*n,-n),e.lineTo(3*n,n),e.lineTo(n,n),e.lineTo(n,3*n),e.lineTo(-n,3*n),e.lineTo(-n,n),e.lineTo(-3*n,n),e.closePath()}},Hn=Math.sqrt(1/3),Fn=2*Hn,Bn={draw:function(e,t){var n=Math.sqrt(t/Fn),r=n*Hn;e.moveTo(0,-n),e.lineTo(r,0),e.lineTo(0,n),e.lineTo(-r,0),e.closePath()}},Wn=Math.sin(Dn/10)/Math.sin(7*Dn/10),zn=Math.sin(Tn/10)*Wn,Vn=-Math.cos(Tn/10)*Wn,Un={draw:function(e,t){var n=Math.sqrt(.8908130915292852*t),r=zn*n,a=Vn*n;e.moveTo(0,-n),e.lineTo(r,a);for(var o=1;o<5;++o){var i=Tn*o/5,s=Math.cos(i),u=Math.sin(i);e.lineTo(u*n,-s*n),e.lineTo(s*r-u*a,u*r+s*a)}e.closePath()}},Kn={draw:function(e,t){var n=Math.sqrt(t),r=-n/2;e.rect(r,r,n,n)}},Gn=Math.sqrt(3),qn={draw:function(e,t){var n=-Math.sqrt(t/(3*Gn));e.moveTo(0,2*n),e.lineTo(-Gn*n,-n),e.lineTo(Gn*n,-n),e.closePath()}},Zn=Math.sqrt(3)/2,Qn=1/Math.sqrt(12),Xn=3*(Qn/2+1),Jn={draw:function(e,t){var n=Math.sqrt(t/Xn),r=n/2,a=n*Qn,o=r,i=n*Qn+n,s=-o,u=i;e.moveTo(r,a),e.lineTo(o,i),e.lineTo(s,u),e.lineTo(-.5*r-Zn*a,Zn*r+-.5*a),e.lineTo(-.5*o-Zn*i,Zn*o+-.5*i),e.lineTo(-.5*s-Zn*u,Zn*s+-.5*u),e.lineTo(-.5*r+Zn*a,-.5*a-Zn*r),e.lineTo(-.5*o+Zn*i,-.5*i-Zn*o),e.lineTo(-.5*s+Zn*u,-.5*u-Zn*s),e.closePath()}},$n=function(){};function er(e,t,n){e._context.bezierCurveTo((2*e._x0+e._x1)/3,(2*e._y0+e._y1)/3,(e._x0+2*e._x1)/3,(e._y0+2*e._y1)/3,(e._x0+4*e._x1+t)/6,(e._y0+4*e._y1+n)/6)}function tr(e){this._context=e}tr.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:er(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:er(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function nr(e){this._context=e}nr.prototype={areaStart:$n,areaEnd:$n,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x2,this._y2),this._context.closePath();break;case 2:this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break;case 3:this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4)}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x2=e,this._y2=t;break;case 1:this._point=2,this._x3=e,this._y3=t;break;case 2:this._point=3,this._x4=e,this._y4=t,this._context.moveTo((this._x0+4*this._x1+e)/6,(this._y0+4*this._y1+t)/6);break;default:er(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function rr(e){this._context=e}rr.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var n=(this._x0+4*this._x1+e)/6,r=(this._y0+4*this._y1+t)/6;this._line?this._context.lineTo(n,r):this._context.moveTo(n,r);break;case 3:this._point=4;default:er(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function ar(e,t){this._basis=new tr(e),this._beta=t}ar.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var e=this._x,t=this._y,n=e.length-1;if(n>0)for(var r,a=e[0],o=t[0],i=e[n]-a,s=t[n]-o,u=-1;++u<=n;)r=u/n,this._basis.point(this._beta*e[u]+(1-this._beta)*(a+r*i),this._beta*t[u]+(1-this._beta)*(o+r*s));this._x=this._y=null,this._basis.lineEnd()},point:function(e,t){this._x.push(+e),this._y.push(+t)}};(function e(t){function n(e){return 1===t?new tr(e):new ar(e,t)}return n.beta=function(t){return e(+t)},n})(.85);function or(e,t,n){e._context.bezierCurveTo(e._x1+e._k*(e._x2-e._x0),e._y1+e._k*(e._y2-e._y0),e._x2+e._k*(e._x1-t),e._y2+e._k*(e._y1-n),e._x2,e._y2)}function ir(e,t){this._context=e,this._k=(1-t)/6}ir.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:or(this,this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2,this._x1=e,this._y1=t;break;case 2:this._point=3;default:or(this,e,t)}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};(function e(t){function n(e){return new ir(e,t)}return n.tension=function(t){return e(+t)},n})(0);function sr(e,t){this._context=e,this._k=(1-t)/6}sr.prototype={areaStart:$n,areaEnd:$n,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x3=e,this._y3=t;break;case 1:this._point=2,this._context.moveTo(this._x4=e,this._y4=t);break;case 2:this._point=3,this._x5=e,this._y5=t;break;default:or(this,e,t)}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};(function e(t){function n(e){return new sr(e,t)}return n.tension=function(t){return e(+t)},n})(0);function ur(e,t){this._context=e,this._k=(1-t)/6}ur.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:or(this,e,t)}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};(function e(t){function n(e){return new ur(e,t)}return n.tension=function(t){return e(+t)},n})(0);function lr(e,t,n){var r=e._x1,a=e._y1,o=e._x2,i=e._y2;if(e._l01_a>Sn){var s=2*e._l01_2a+3*e._l01_a*e._l12_a+e._l12_2a,u=3*e._l01_a*(e._l01_a+e._l12_a);r=(r*s-e._x0*e._l12_2a+e._x2*e._l01_2a)/u,a=(a*s-e._y0*e._l12_2a+e._y2*e._l01_2a)/u}if(e._l23_a>Sn){var l=2*e._l23_2a+3*e._l23_a*e._l12_a+e._l12_2a,c=3*e._l23_a*(e._l23_a+e._l12_a);o=(o*l+e._x1*e._l23_2a-t*e._l12_2a)/c,i=(i*l+e._y1*e._l23_2a-n*e._l12_2a)/c}e._context.bezierCurveTo(r,a,o,i,e._x2,e._y2)}function cr(e,t){this._context=e,this._alpha=t}cr.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:this.point(this._x2,this._y2)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){if(e=+e,t=+t,this._point){var n=this._x2-e,r=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3;default:lr(this,e,t)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};(function e(t){function n(e){return t?new cr(e,t):new ir(e,0)}return n.alpha=function(t){return e(+t)},n})(.5);function dr(e,t){this._context=e,this._alpha=t}dr.prototype={areaStart:$n,areaEnd:$n,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(e,t){if(e=+e,t=+t,this._point){var n=this._x2-e,r=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1,this._x3=e,this._y3=t;break;case 1:this._point=2,this._context.moveTo(this._x4=e,this._y4=t);break;case 2:this._point=3,this._x5=e,this._y5=t;break;default:lr(this,e,t)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};(function e(t){function n(e){return t?new dr(e,t):new sr(e,0)}return n.alpha=function(t){return e(+t)},n})(.5);function fr(e,t){this._context=e,this._alpha=t}fr.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){if(e=+e,t=+t,this._point){var n=this._x2-e,r=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:lr(this,e,t)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};(function e(t){function n(e){return t?new fr(e,t):new ur(e,0)}return n.alpha=function(t){return e(+t)},n})(.5);function pr(e){this._context=e}pr.prototype={areaStart:$n,areaEnd:$n,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(e,t){e=+e,t=+t,this._point?this._context.lineTo(e,t):(this._point=1,this._context.moveTo(e,t))}};function hr(e){return e<0?-1:1}function mr(e,t,n){var r=e._x1-e._x0,a=t-e._x1,o=(e._y1-e._y0)/(r||a<0&&-0),i=(n-e._y1)/(a||r<0&&-0),s=(o*a+i*r)/(r+a);return(hr(o)+hr(i))*Math.min(Math.abs(o),Math.abs(i),.5*Math.abs(s))||0}function yr(e,t){var n=e._x1-e._x0;return n?(3*(e._y1-e._y0)/n-t)/2:t}function vr(e,t,n){var r=e._x0,a=e._y0,o=e._x1,i=e._y1,s=(o-r)/3;e._context.bezierCurveTo(r+s,a+s*t,o-s,i-s*n,o,i)}function br(e){this._context=e}function gr(e){this._context=new Ar(e)}function Ar(e){this._context=e}function kr(e){this._context=e}function Mr(e){var t,n,r=e.length-1,a=new Array(r),o=new Array(r),i=new Array(r);for(a[0]=0,o[0]=2,i[0]=e[0]+2*e[1],t=1;t=0;--t)a[t]=(i[t]-a[t+1])/o[t];for(o[r-1]=(e[r]+a[r-1])/2,t=0;t=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:if(this._t<=0)this._context.lineTo(this._x,t),this._context.lineTo(e,t);else{var n=this._x*(1-this._t)+e*this._t;this._context.lineTo(n,this._y),this._context.lineTo(n,t)}}this._x=e,this._y=t}};var xr=function(e,t){if((a=e.length)>1)for(var n,r,a,o=1,i=e[t[0]],s=i.length;o=0;)n[t]=t;return n};function Dr(e,t){return e[t]}var Tr,Or,Pr;function Lr(e){return(Lr="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})(e)}function Er(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function jr(){return(jr=Object.assign||function(e){for(var t=1;t=0&&n>=0?{width:t,height:n}:null}},{key:"getDefaultPosition",value:function(e){var t,n,r=this.props,a=r.layout,o=r.align,i=r.verticalAlign,s=r.margin,u=r.chartWidth,l=r.chartHeight;e&&(void 0!==e.left&&null!==e.left||void 0!==e.right&&null!==e.right)||(t="center"===o&&"vertical"===a?{left:((u||0)-(this.getBBox()||{width:0}).width)/2}:"right"===o?{right:s&&s.right||0}:{left:s&&s.left||0});e&&(void 0!==e.top&&null!==e.top||void 0!==e.bottom&&null!==e.bottom)||(n="middle"===i?{top:((l||0)-(this.getBBox()||{height:0}).height)/2}:"bottom"===i?{bottom:s&&s.bottom||0}:{top:s&&s.top||0});return na({},t,n)}},{key:"updateBBox",value:function(){var e=this.state,t=e.boxWidth,n=e.boxHeight,r=this.props.onBBoxUpdate;if(this.wrapperNode&&this.wrapperNode.getBoundingClientRect){var a=this.wrapperNode.getBoundingClientRect();(Math.abs(a.width-t)>1||Math.abs(a.height-n)>1)&&this.setState({boxWidth:a.width,boxHeight:a.height},function(){r&&r(a)})}else-1===t&&-1===n||this.setState({boxWidth:-1,boxHeight:-1},function(){r&&r(null)})}},{key:"render",value:function(){var e=this,t=this.props,n=t.content,r=t.width,a=t.height,i=t.wrapperStyle,s=na({position:"absolute",width:r||"auto",height:a||"auto"},this.getDefaultPosition(i),i);return o.a.createElement("div",{className:"recharts-legend-wrapper",style:s,ref:function(t){e.wrapperNode=t}},function(e,t){return o.a.isValidElement(e)?o.a.cloneElement(e,t):A()(e)?e(t):o.a.createElement(ea,t)}(n,this.props))}}])&&aa(n.prototype,r),i&&aa(n,i),t}(),Xr.displayName="Legend",Xr.propTypes={content:s.a.oneOfType([s.a.element,s.a.func]),wrapperStyle:s.a.object,chartWidth:s.a.number,chartHeight:s.a.number,width:s.a.number,height:s.a.number,iconSize:s.a.number,iconType:s.a.oneOf(da),layout:s.a.oneOf(["horizontal","vertical"]),align:s.a.oneOf(["center","left","right"]),verticalAlign:s.a.oneOf(["top","bottom","middle"]),margin:s.a.shape({top:s.a.number,left:s.a.number,bottom:s.a.number,right:s.a.number}),payload:s.a.arrayOf(s.a.shape({value:s.a.any,id:s.a.any,type:s.a.oneOf(oe)})),formatter:s.a.func,onMouseEnter:s.a.func,onMouseLeave:s.a.func,onClick:s.a.func,onBBoxUpdate:s.a.func},Xr.defaultProps={iconSize:14,layout:"horizontal",align:"center",verticalAlign:"bottom"},Qr=Jr))||Qr;function pa(e){return(pa="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})(e)}function ha(){return(ha=Object.assign||function(e){for(var t=1;tt?1:e>=t?0:NaN},Ua=function(e){var t;return 1===e.length&&(t=e,e=function(e,n){return Va(t(e),n)}),{left:function(t,n,r,a){for(null==r&&(r=0),null==a&&(a=t.length);r>>1;e(t[o],n)<0?r=o+1:a=o}return r},right:function(t,n,r,a){for(null==r&&(r=0),null==a&&(a=t.length);r>>1;e(t[o],n)>0?a=o:r=o+1}return r}}};var Ka=Ua(Va),Ga=Ka.right,qa=(Ka.left,Ga);var Za=function(e){return null===e?NaN:+e},Qa=Array.prototype,Xa=(Qa.slice,Qa.map,function(e,t,n){e=+e,t=+t,n=(a=arguments.length)<2?(t=e,e=0,1):a<3?1:+n;for(var r=-1,a=0|Math.max(0,Math.ceil((t-e)/n)),o=new Array(a);++r0)return[e];if((r=t0)for(e=Math.ceil(e/i),t=Math.floor(t/i),o=new Array(a=Math.ceil(t-e+1));++s=0?(o>=Ja?10:o>=$a?5:o>=eo?2:1)*Math.pow(10,a):-Math.pow(10,-a)/(o>=Ja?10:o>=$a?5:o>=eo?2:1)}function ro(e,t,n){var r=Math.abs(t-e)/Math.max(0,n),a=Math.pow(10,Math.floor(Math.log(r)/Math.LN10)),o=r/a;return o>=Ja?a*=10:o>=$a?a*=5:o>=eo&&(a*=2),t=1)return+n(e[r-1],r-1,e);var r,a=(r-1)*t,o=Math.floor(a),i=+n(e[o],o,e);return i+(+n(e[o+1],o+1,e)-i)*(a-o)}};function oo(){}function io(e,t){var n=new oo;if(e instanceof oo)e.each(function(e,t){n.set(t,e)});else if(Array.isArray(e)){var r,a=-1,o=e.length;if(null==t)for(;++a>8&15|t>>4&240,t>>4&15|240&t,(15&t)<<4|15&t,1):(t=Do.exec(e))?Ro(parseInt(t[1],16)):(t=To.exec(e))?new Ho(t[1],t[2],t[3],1):(t=Oo.exec(e))?new Ho(255*t[1]/100,255*t[2]/100,255*t[3]/100,1):(t=Po.exec(e))?No(t[1],t[2],t[3],t[4]):(t=Lo.exec(e))?No(255*t[1]/100,255*t[2]/100,255*t[3]/100,t[4]):(t=Eo.exec(e))?Bo(t[1],t[2]/100,t[3]/100,1):(t=jo.exec(e))?Bo(t[1],t[2]/100,t[3]/100,t[4]):Co.hasOwnProperty(e)?Ro(Co[e]):"transparent"===e?new Ho(NaN,NaN,NaN,0):null}function Ro(e){return new Ho(e>>16&255,e>>8&255,255&e,1)}function No(e,t,n,r){return r<=0&&(e=t=n=NaN),new Ho(e,t,n,r)}function _o(e){return e instanceof ko||(e=Yo(e)),e?new Ho((e=e.rgb()).r,e.g,e.b,e.opacity):new Ho}function Io(e,t,n,r){return 1===arguments.length?_o(e):new Ho(e,t,n,null==r?1:r)}function Ho(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}function Fo(e){return((e=Math.max(0,Math.min(255,Math.round(e)||0)))<16?"0":"")+e.toString(16)}function Bo(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new zo(e,t,n,r)}function Wo(e,t,n,r){return 1===arguments.length?function(e){if(e instanceof zo)return new zo(e.h,e.s,e.l,e.opacity);if(e instanceof ko||(e=Yo(e)),!e)return new zo;if(e instanceof zo)return e;var t=(e=e.rgb()).r/255,n=e.g/255,r=e.b/255,a=Math.min(t,n,r),o=Math.max(t,n,r),i=NaN,s=o-a,u=(o+a)/2;return s?(i=t===o?(n-r)/s+6*(n0&&u<1?0:i,new zo(i,s,u,e.opacity)}(e):new zo(e,t,n,null==r?1:r)}function zo(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}function Vo(e,t,n){return 255*(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)}go(ko,Yo,{displayable:function(){return this.rgb().displayable()},hex:function(){return this.rgb().hex()},toString:function(){return this.rgb()+""}}),go(Ho,Io,Ao(ko,{brighter:function(e){return e=null==e?1/.7:Math.pow(1/.7,e),new Ho(this.r*e,this.g*e,this.b*e,this.opacity)},darker:function(e){return e=null==e?.7:Math.pow(.7,e),new Ho(this.r*e,this.g*e,this.b*e,this.opacity)},rgb:function(){return this},displayable:function(){return 0<=this.r&&this.r<=255&&0<=this.g&&this.g<=255&&0<=this.b&&this.b<=255&&0<=this.opacity&&this.opacity<=1},hex:function(){return"#"+Fo(this.r)+Fo(this.g)+Fo(this.b)},toString:function(){var e=this.opacity;return(1===(e=isNaN(e)?1:Math.max(0,Math.min(1,e)))?"rgb(":"rgba(")+Math.max(0,Math.min(255,Math.round(this.r)||0))+", "+Math.max(0,Math.min(255,Math.round(this.g)||0))+", "+Math.max(0,Math.min(255,Math.round(this.b)||0))+(1===e?")":", "+e+")")}})),go(zo,Wo,Ao(ko,{brighter:function(e){return e=null==e?1/.7:Math.pow(1/.7,e),new zo(this.h,this.s,this.l*e,this.opacity)},darker:function(e){return e=null==e?.7:Math.pow(.7,e),new zo(this.h,this.s,this.l*e,this.opacity)},rgb:function(){var e=this.h%360+360*(this.h<0),t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*t,a=2*n-r;return new Ho(Vo(e>=240?e-240:e+120,a,r),Vo(e,a,r),Vo(e<120?e+240:e-120,a,r),this.opacity)},displayable:function(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1}}));var Uo=Math.PI/180,Ko=180/Math.PI,Go=.96422,qo=1,Zo=.82521,Qo=4/29,Xo=6/29,Jo=3*Xo*Xo,$o=Xo*Xo*Xo;function ei(e){if(e instanceof ni)return new ni(e.l,e.a,e.b,e.opacity);if(e instanceof li){if(isNaN(e.h))return new ni(e.l,0,0,e.opacity);var t=e.h*Uo;return new ni(e.l,Math.cos(t)*e.c,Math.sin(t)*e.c,e.opacity)}e instanceof Ho||(e=_o(e));var n,r,a=ii(e.r),o=ii(e.g),i=ii(e.b),s=ri((.2225045*a+.7168786*o+.0606169*i)/qo);return a===o&&o===i?n=r=s:(n=ri((.4360747*a+.3850649*o+.1430804*i)/Go),r=ri((.0139322*a+.0971045*o+.7141733*i)/Zo)),new ni(116*s-16,500*(n-s),200*(s-r),e.opacity)}function ti(e,t,n,r){return 1===arguments.length?ei(e):new ni(e,t,n,null==r?1:r)}function ni(e,t,n,r){this.l=+e,this.a=+t,this.b=+n,this.opacity=+r}function ri(e){return e>$o?Math.pow(e,1/3):e/Jo+Qo}function ai(e){return e>Xo?e*e*e:Jo*(e-Qo)}function oi(e){return 255*(e<=.0031308?12.92*e:1.055*Math.pow(e,1/2.4)-.055)}function ii(e){return(e/=255)<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4)}function si(e){if(e instanceof li)return new li(e.h,e.c,e.l,e.opacity);if(e instanceof ni||(e=ei(e)),0===e.a&&0===e.b)return new li(NaN,0,e.l,e.opacity);var t=Math.atan2(e.b,e.a)*Ko;return new li(t<0?t+360:t,Math.sqrt(e.a*e.a+e.b*e.b),e.l,e.opacity)}function ui(e,t,n,r){return 1===arguments.length?si(e):new li(e,t,n,null==r?1:r)}function li(e,t,n,r){this.h=+e,this.c=+t,this.l=+n,this.opacity=+r}go(ni,ti,Ao(ko,{brighter:function(e){return new ni(this.l+18*(null==e?1:e),this.a,this.b,this.opacity)},darker:function(e){return new ni(this.l-18*(null==e?1:e),this.a,this.b,this.opacity)},rgb:function(){var e=(this.l+16)/116,t=isNaN(this.a)?e:e+this.a/500,n=isNaN(this.b)?e:e-this.b/200;return new Ho(oi(3.1338561*(t=Go*ai(t))-1.6168667*(e=qo*ai(e))-.4906146*(n=Zo*ai(n))),oi(-.9787684*t+1.9161415*e+.033454*n),oi(.0719453*t-.2289914*e+1.4052427*n),this.opacity)}})),go(li,ui,Ao(ko,{brighter:function(e){return new li(this.h,this.c,this.l+18*(null==e?1:e),this.opacity)},darker:function(e){return new li(this.h,this.c,this.l-18*(null==e?1:e),this.opacity)},rgb:function(){return ei(this).rgb()}}));var ci=-.14861,di=1.78277,fi=-.29227,pi=-.90649,hi=1.97294,mi=hi*pi,yi=hi*di,vi=di*fi-pi*ci;function bi(e,t,n,r){return 1===arguments.length?function(e){if(e instanceof gi)return new gi(e.h,e.s,e.l,e.opacity);e instanceof Ho||(e=_o(e));var t=e.r/255,n=e.g/255,r=e.b/255,a=(vi*r+mi*t-yi*n)/(vi+mi-yi),o=r-a,i=(hi*(n-a)-fi*o)/pi,s=Math.sqrt(i*i+o*o)/(hi*a*(1-a)),u=s?Math.atan2(i,o)*Ko-120:NaN;return new gi(u<0?u+360:u,s,a,e.opacity)}(e):new gi(e,t,n,null==r?1:r)}function gi(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}function Ai(e,t,n,r,a){var o=e*e,i=o*e;return((1-3*e+3*o-i)*t+(4-6*o+3*i)*n+(1+3*e+3*o-3*i)*r+i*a)/6}go(gi,bi,Ao(ko,{brighter:function(e){return e=null==e?1/.7:Math.pow(1/.7,e),new gi(this.h,this.s,this.l*e,this.opacity)},darker:function(e){return e=null==e?.7:Math.pow(.7,e),new gi(this.h,this.s,this.l*e,this.opacity)},rgb:function(){var e=isNaN(this.h)?0:(this.h+120)*Uo,t=+this.l,n=isNaN(this.s)?0:this.s*t*(1-t),r=Math.cos(e),a=Math.sin(e);return new Ho(255*(t+n*(ci*r+di*a)),255*(t+n*(fi*r+pi*a)),255*(t+n*(hi*r)),this.opacity)}}));var ki=function(e){return function(){return e}};function Mi(e,t){return function(n){return e+n*t}}function wi(e,t){var n=t-e;return n?Mi(e,n>180||n<-180?n-360*Math.round(n/360):n):ki(isNaN(e)?t:e)}function xi(e){return 1==(e=+e)?Si:function(t,n){return n-t?function(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(r){return Math.pow(e+r*t,n)}}(t,n,e):ki(isNaN(t)?n:t)}}function Si(e,t){var n=t-e;return n?Mi(e,n):ki(isNaN(e)?t:e)}var Di=function e(t){var n=xi(t);function r(e,t){var r=n((e=Io(e)).r,(t=Io(t)).r),a=n(e.g,t.g),o=n(e.b,t.b),i=Si(e.opacity,t.opacity);return function(t){return e.r=r(t),e.g=a(t),e.b=o(t),e.opacity=i(t),e+""}}return r.gamma=e,r}(1);function Ti(e){return function(t){var n,r,a=t.length,o=new Array(a),i=new Array(a),s=new Array(a);for(n=0;n=1?(n=1,t-1):Math.floor(n*t),a=e[r],o=e[r+1],i=r>0?e[r-1]:2*a-o,s=ro&&(a=t.slice(o,a),s[i]?s[i]+=a:s[++i]=a),(n=n[0])===(r=r[0])?s[i]?s[i]+=r:s[++i]=r:(s[++i]=null,u.push({i:i,x:Oi(n,r)})),o=Li.lastIndex;return o180?t+=360:t-e>180&&(e+=360),o.push({i:n.push(a(n)+"rotate(",null,r)-2,x:Oi(e,t)})):t&&n.push(a(n)+"rotate("+t+r)}(o.rotate,i.rotate,s,u),function(e,t,n,o){e!==t?o.push({i:n.push(a(n)+"skewX(",null,r)-2,x:Oi(e,t)}):t&&n.push(a(n)+"skewX("+t+r)}(o.skewX,i.skewX,s,u),function(e,t,n,r,o,i){if(e!==n||t!==r){var s=o.push(a(o)+"scale(",null,",",null,")");i.push({i:s-4,x:Oi(e,n)},{i:s-2,x:Oi(t,r)})}else 1===n&&1===r||o.push(a(o)+"scale("+n+","+r+")")}(o.scaleX,o.scaleY,i.scaleX,i.scaleY,s,u),o=i=null,function(e){for(var t,n=-1,r=u.length;++n2?Zi:qi,r=a=null,c}function c(t){return(r||(r=n(o,i,u?function(e){return function(t,n){var r=e(t=+t,n=+n);return function(e){return e<=t?0:e>=n?1:r(e)}}}(e):e,s)))(+t)}return c.invert=function(e){return(a||(a=n(i,o,Gi,u?function(e){return function(t,n){var r=e(t=+t,n=+n);return function(e){return e<=0?t:e>=1?n:r(e)}}}(t):t)))(+e)},c.domain=function(e){return arguments.length?(o=po.call(e,Ui),l()):o.slice()},c.range=function(e){return arguments.length?(i=ho.call(e),l()):i.slice()},c.rangeRound=function(e){return i=ho.call(e),s=Ni,l()},c.clamp=function(e){return arguments.length?(u=!!e,l()):u},c.interpolate=function(e){return arguments.length?(s=e,l()):s},l()}var Ji=function(e,t){if((n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"))<0)return null;var n,r=e.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+e.slice(n+1)]},$i=function(e){return(e=Ji(Math.abs(e)))?e[1]:NaN},es=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function ts(e){return new ns(e)}function ns(e){if(!(t=es.exec(e)))throw new Error("invalid format: "+e);var t;this.fill=t[1]||" ",this.align=t[2]||">",this.sign=t[3]||"-",this.symbol=t[4]||"",this.zero=!!t[5],this.width=t[6]&&+t[6],this.comma=!!t[7],this.precision=t[8]&&+t[8].slice(1),this.trim=!!t[9],this.type=t[10]||""}ts.prototype=ns.prototype,ns.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(null==this.width?"":Math.max(1,0|this.width))+(this.comma?",":"")+(null==this.precision?"":"."+Math.max(0,0|this.precision))+(this.trim?"~":"")+this.type};var rs,as,os,is,ss=function(e){e:for(var t,n=e.length,r=1,a=-1;r0){if(!+e[r])break e;a=0}}return a>0?e.slice(0,a)+e.slice(t+1):e},us=function(e,t){var n=Ji(e,t);if(!n)return e+"";var r=n[0],a=n[1];return a<0?"0."+new Array(-a).join("0")+r:r.length>a+1?r.slice(0,a+1)+"."+r.slice(a+1):r+new Array(a-r.length+2).join("0")},ls={"%":function(e,t){return(100*e).toFixed(t)},b:function(e){return Math.round(e).toString(2)},c:function(e){return e+""},d:function(e){return Math.round(e).toString(10)},e:function(e,t){return e.toExponential(t)},f:function(e,t){return e.toFixed(t)},g:function(e,t){return e.toPrecision(t)},o:function(e){return Math.round(e).toString(8)},p:function(e,t){return us(100*e,t)},r:us,s:function(e,t){var n=Ji(e,t);if(!n)return e+"";var r=n[0],a=n[1],o=a-(rs=3*Math.max(-8,Math.min(8,Math.floor(a/3))))+1,i=r.length;return o===i?r:o>i?r+new Array(o-i+1).join("0"):o>0?r.slice(0,o)+"."+r.slice(o):"0."+new Array(1-o).join("0")+Ji(e,Math.max(0,t+o-1))[0]},X:function(e){return Math.round(e).toString(16).toUpperCase()},x:function(e){return Math.round(e).toString(16)}},cs=function(e){return e},ds=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];as=function(e){var t,n,r=e.grouping&&e.thousands?(t=e.grouping,n=e.thousands,function(e,r){for(var a=e.length,o=[],i=0,s=t[0],u=0;a>0&&s>0&&(u+s+1>r&&(s=Math.max(1,r-u)),o.push(e.substring(a-=s,a+s)),!((u+=s+1)>r));)s=t[i=(i+1)%t.length];return o.reverse().join(n)}):cs,a=e.currency,o=e.decimal,i=e.numerals?function(e){return function(t){return t.replace(/[0-9]/g,function(t){return e[+t]})}}(e.numerals):cs,s=e.percent||"%";function u(e){var t=(e=ts(e)).fill,n=e.align,u=e.sign,l=e.symbol,c=e.zero,d=e.width,f=e.comma,p=e.precision,h=e.trim,m=e.type;"n"===m?(f=!0,m="g"):ls[m]||(null==p&&(p=12),h=!0,m="g"),(c||"0"===t&&"="===n)&&(c=!0,t="0",n="=");var y="$"===l?a[0]:"#"===l&&/[boxX]/.test(m)?"0"+m.toLowerCase():"",v="$"===l?a[1]:/[%p]/.test(m)?s:"",b=ls[m],g=/[defgprs%]/.test(m);function A(e){var a,s,l,A=y,k=v;if("c"===m)k=b(e)+k,e="";else{var M=(e=+e)<0;if(e=b(Math.abs(e),p),h&&(e=ss(e)),M&&0==+e&&(M=!1),A=(M?"("===u?u:"-":"-"===u||"("===u?"":u)+A,k=("s"===m?ds[8+rs/3]:"")+k+(M&&"("===u?")":""),g)for(a=-1,s=e.length;++a(l=e.charCodeAt(a))||l>57){k=(46===l?o+e.slice(a+1):e.slice(a))+k,e=e.slice(0,a);break}}f&&!c&&(e=r(e,1/0));var w=A.length+e.length+k.length,x=w>1)+A+e+k+x.slice(w);break;default:e=x+A+e+k}return i(e)}return p=null==p?6:/[gprs]/.test(m)?Math.max(1,Math.min(21,p)):Math.max(0,Math.min(20,p)),A.toString=function(){return e+""},A}return{format:u,formatPrefix:function(e,t){var n=u(((e=ts(e)).type="f",e)),r=3*Math.max(-8,Math.min(8,Math.floor($i(t)/3))),a=Math.pow(10,-r),o=ds[8+r/3];return function(e){return n(a*e)+o}}}}({decimal:".",thousands:",",grouping:[3],currency:["$",""]}),os=as.format,is=as.formatPrefix;var fs=function(e,t,n){var r,a=e[0],o=e[e.length-1],i=ro(a,o,null==t?10:t);switch((n=ts(null==n?",f":n)).type){case"s":var s=Math.max(Math.abs(a),Math.abs(o));return null!=n.precision||isNaN(r=function(e,t){return Math.max(0,3*Math.max(-8,Math.min(8,Math.floor($i(t)/3)))-$i(Math.abs(e)))}(i,s))||(n.precision=r),is(n,s);case"":case"e":case"g":case"p":case"r":null!=n.precision||isNaN(r=function(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,$i(t)-$i(e))+1}(i,Math.max(Math.abs(a),Math.abs(o))))||(n.precision=r-("e"===n.type));break;case"f":case"%":null!=n.precision||isNaN(r=function(e){return Math.max(0,-$i(Math.abs(e)))}(i))||(n.precision=r-2*("%"===n.type))}return os(n)};function ps(e){var t=e.domain;return e.ticks=function(e){var n=t();return to(n[0],n[n.length-1],null==e?10:e)},e.tickFormat=function(e,n){return fs(t(),e,n)},e.nice=function(n){null==n&&(n=10);var r,a=t(),o=0,i=a.length-1,s=a[o],u=a[i];return u0?r=no(s=Math.floor(s/r)*r,u=Math.ceil(u/r)*r,n):r<0&&(r=no(s=Math.ceil(s*r)/r,u=Math.floor(u*r)/r,n)),r>0?(a[o]=Math.floor(s/r)*r,a[i]=Math.ceil(u/r)*r,t(a)):r<0&&(a[o]=Math.ceil(s*r)/r,a[i]=Math.floor(u*r)/r,t(a)),e},e}function hs(){var e=Xi(Gi,Oi);return e.copy=function(){return Qi(e,hs())},ps(e)}function ms(){var e=[0,1];function t(e){return+e}return t.invert=t,t.domain=t.range=function(n){return arguments.length?(e=po.call(n,Ui),t):e.slice()},t.copy=function(){return ms().domain(e)},ps(t)}var ys=function(e,t){var n,r=0,a=(e=e.slice()).length-1,o=e[r],i=e[a];return i0){for(;fu)break;m.push(d)}}else for(;f=1;--c)if(!((d=l*c)u)break;m.push(d)}}else m=to(f,p,Math.min(p-f,h)).map(a);return o?m.reverse():m},e.tickFormat=function(t,o){if(null==o&&(o=10===n?".0e":","),"function"!=typeof o&&(o=os(o)),t===1/0)return o;null==t&&(t=10);var i=Math.max(1,n*t/e.ticks().length);return function(e){var t=e/a(Math.round(r(e)));return t*n0?n[a-1]:e[0],a=n?[r[n-1],t]:[r[i-1],r[i]]},o.copy=function(){return Os().domain([e,t]).range(a)},ps(o)}function Ps(){var e=[.5],t=[0,1],n=1;function r(r){if(r<=r)return t[qa(e,r,0,n)]}return r.domain=function(a){return arguments.length?(e=ho.call(a),n=Math.min(e.length,t.length-1),r):e.slice()},r.range=function(a){return arguments.length?(t=ho.call(a),n=Math.min(e.length,t.length-1),r):t.slice()},r.invertExtent=function(n){var r=t.indexOf(n);return[e[r-1],e[r]]},r.copy=function(){return Ps().domain(e).range(t)},r}var Ls=new Date,Es=new Date;function js(e,t,n,r){function a(t){return e(t=new Date(+t)),t}return a.floor=a,a.ceil=function(n){return e(n=new Date(n-1)),t(n,1),e(n),n},a.round=function(e){var t=a(e),n=a.ceil(e);return e-t0))return s;do{s.push(i=new Date(+n)),t(n,o),e(n)}while(i=t)for(;e(t),!n(t);)t.setTime(t-1)},function(e,r){if(e>=e)if(r<0)for(;++r<=0;)for(;t(e,-1),!n(e););else for(;--r>=0;)for(;t(e,1),!n(e););})},n&&(a.count=function(t,r){return Ls.setTime(+t),Es.setTime(+r),e(Ls),e(Es),Math.floor(n(Ls,Es))},a.every=function(e){return e=Math.floor(e),isFinite(e)&&e>0?e>1?a.filter(r?function(t){return r(t)%e==0}:function(t){return a.count(0,t)%e==0}):a:null}),a}var Cs=js(function(){},function(e,t){e.setTime(+e+t)},function(e,t){return t-e});Cs.every=function(e){return e=Math.floor(e),isFinite(e)&&e>0?e>1?js(function(t){t.setTime(Math.floor(t/e)*e)},function(t,n){t.setTime(+t+n*e)},function(t,n){return(n-t)/e}):Cs:null};var Ys=Cs,Rs=(Cs.range,6e4),Ns=6048e5,_s=js(function(e){e.setTime(e-e.getMilliseconds())},function(e,t){e.setTime(+e+1e3*t)},function(e,t){return(t-e)/1e3},function(e){return e.getUTCSeconds()}),Is=_s,Hs=(_s.range,js(function(e){e.setTime(e-e.getMilliseconds()-1e3*e.getSeconds())},function(e,t){e.setTime(+e+t*Rs)},function(e,t){return(t-e)/Rs},function(e){return e.getMinutes()})),Fs=Hs,Bs=(Hs.range,js(function(e){e.setTime(e-e.getMilliseconds()-1e3*e.getSeconds()-e.getMinutes()*Rs)},function(e,t){e.setTime(+e+36e5*t)},function(e,t){return(t-e)/36e5},function(e){return e.getHours()})),Ws=Bs,zs=(Bs.range,js(function(e){e.setHours(0,0,0,0)},function(e,t){e.setDate(e.getDate()+t)},function(e,t){return(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*Rs)/864e5},function(e){return e.getDate()-1})),Vs=zs;zs.range;function Us(e){return js(function(t){t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)},function(e,t){e.setDate(e.getDate()+7*t)},function(e,t){return(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*Rs)/Ns})}var Ks=Us(0),Gs=Us(1),qs=Us(2),Zs=Us(3),Qs=Us(4),Xs=Us(5),Js=Us(6),$s=(Ks.range,Gs.range,qs.range,Zs.range,Qs.range,Xs.range,Js.range,js(function(e){e.setDate(1),e.setHours(0,0,0,0)},function(e,t){e.setMonth(e.getMonth()+t)},function(e,t){return t.getMonth()-e.getMonth()+12*(t.getFullYear()-e.getFullYear())},function(e){return e.getMonth()})),eu=$s,tu=($s.range,js(function(e){e.setMonth(0,1),e.setHours(0,0,0,0)},function(e,t){e.setFullYear(e.getFullYear()+t)},function(e,t){return t.getFullYear()-e.getFullYear()},function(e){return e.getFullYear()}));tu.every=function(e){return isFinite(e=Math.floor(e))&&e>0?js(function(t){t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)},function(t,n){t.setFullYear(t.getFullYear()+n*e)}):null};var nu=tu,ru=(tu.range,js(function(e){e.setUTCSeconds(0,0)},function(e,t){e.setTime(+e+t*Rs)},function(e,t){return(t-e)/Rs},function(e){return e.getUTCMinutes()})),au=ru,ou=(ru.range,js(function(e){e.setUTCMinutes(0,0,0)},function(e,t){e.setTime(+e+36e5*t)},function(e,t){return(t-e)/36e5},function(e){return e.getUTCHours()})),iu=ou,su=(ou.range,js(function(e){e.setUTCHours(0,0,0,0)},function(e,t){e.setUTCDate(e.getUTCDate()+t)},function(e,t){return(t-e)/864e5},function(e){return e.getUTCDate()-1})),uu=su;su.range;function lu(e){return js(function(t){t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)},function(e,t){e.setUTCDate(e.getUTCDate()+7*t)},function(e,t){return(t-e)/Ns})}var cu=lu(0),du=lu(1),fu=lu(2),pu=lu(3),hu=lu(4),mu=lu(5),yu=lu(6),vu=(cu.range,du.range,fu.range,pu.range,hu.range,mu.range,yu.range,js(function(e){e.setUTCDate(1),e.setUTCHours(0,0,0,0)},function(e,t){e.setUTCMonth(e.getUTCMonth()+t)},function(e,t){return t.getUTCMonth()-e.getUTCMonth()+12*(t.getUTCFullYear()-e.getUTCFullYear())},function(e){return e.getUTCMonth()})),bu=vu,gu=(vu.range,js(function(e){e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},function(e,t){e.setUTCFullYear(e.getUTCFullYear()+t)},function(e,t){return t.getUTCFullYear()-e.getUTCFullYear()},function(e){return e.getUTCFullYear()}));gu.every=function(e){return isFinite(e=Math.floor(e))&&e>0?js(function(t){t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},function(t,n){t.setUTCFullYear(t.getUTCFullYear()+n*e)}):null};var Au=gu;gu.range;function ku(e){if(0<=e.y&&e.y<100){var t=new Date(-1,e.m,e.d,e.H,e.M,e.S,e.L);return t.setFullYear(e.y),t}return new Date(e.y,e.m,e.d,e.H,e.M,e.S,e.L)}function Mu(e){if(0<=e.y&&e.y<100){var t=new Date(Date.UTC(-1,e.m,e.d,e.H,e.M,e.S,e.L));return t.setUTCFullYear(e.y),t}return new Date(Date.UTC(e.y,e.m,e.d,e.H,e.M,e.S,e.L))}function wu(e){return{y:e,m:0,d:1,H:0,M:0,S:0,L:0}}var xu,Su,Du,Tu,Ou={"-":"",_:" ",0:"0"},Pu=/^\s*\d+/,Lu=/^%/,Eu=/[\\^$*+?|[\]().{}]/g;function ju(e,t,n){var r=e<0?"-":"",a=(r?-e:e)+"",o=a.length;return r+(o68?1900:2e3),n+r[0].length):-1}function zu(e,t,n){var r=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(t.slice(n,n+6));return r?(e.Z=r[1]?0:-(r[2]+(r[3]||"00")),n+r[0].length):-1}function Vu(e,t,n){var r=Pu.exec(t.slice(n,n+2));return r?(e.m=r[0]-1,n+r[0].length):-1}function Uu(e,t,n){var r=Pu.exec(t.slice(n,n+2));return r?(e.d=+r[0],n+r[0].length):-1}function Ku(e,t,n){var r=Pu.exec(t.slice(n,n+3));return r?(e.m=0,e.d=+r[0],n+r[0].length):-1}function Gu(e,t,n){var r=Pu.exec(t.slice(n,n+2));return r?(e.H=+r[0],n+r[0].length):-1}function qu(e,t,n){var r=Pu.exec(t.slice(n,n+2));return r?(e.M=+r[0],n+r[0].length):-1}function Zu(e,t,n){var r=Pu.exec(t.slice(n,n+2));return r?(e.S=+r[0],n+r[0].length):-1}function Qu(e,t,n){var r=Pu.exec(t.slice(n,n+3));return r?(e.L=+r[0],n+r[0].length):-1}function Xu(e,t,n){var r=Pu.exec(t.slice(n,n+6));return r?(e.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function Ju(e,t,n){var r=Lu.exec(t.slice(n,n+1));return r?n+r[0].length:-1}function $u(e,t,n){var r=Pu.exec(t.slice(n));return r?(e.Q=+r[0],n+r[0].length):-1}function el(e,t,n){var r=Pu.exec(t.slice(n));return r?(e.Q=1e3*+r[0],n+r[0].length):-1}function tl(e,t){return ju(e.getDate(),t,2)}function nl(e,t){return ju(e.getHours(),t,2)}function rl(e,t){return ju(e.getHours()%12||12,t,2)}function al(e,t){return ju(1+Vs.count(nu(e),e),t,3)}function ol(e,t){return ju(e.getMilliseconds(),t,3)}function il(e,t){return ol(e,t)+"000"}function sl(e,t){return ju(e.getMonth()+1,t,2)}function ul(e,t){return ju(e.getMinutes(),t,2)}function ll(e,t){return ju(e.getSeconds(),t,2)}function cl(e){var t=e.getDay();return 0===t?7:t}function dl(e,t){return ju(Ks.count(nu(e),e),t,2)}function fl(e,t){var n=e.getDay();return e=n>=4||0===n?Qs(e):Qs.ceil(e),ju(Qs.count(nu(e),e)+(4===nu(e).getDay()),t,2)}function pl(e){return e.getDay()}function hl(e,t){return ju(Gs.count(nu(e),e),t,2)}function ml(e,t){return ju(e.getFullYear()%100,t,2)}function yl(e,t){return ju(e.getFullYear()%1e4,t,4)}function vl(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+ju(t/60|0,"0",2)+ju(t%60,"0",2)}function bl(e,t){return ju(e.getUTCDate(),t,2)}function gl(e,t){return ju(e.getUTCHours(),t,2)}function Al(e,t){return ju(e.getUTCHours()%12||12,t,2)}function kl(e,t){return ju(1+uu.count(Au(e),e),t,3)}function Ml(e,t){return ju(e.getUTCMilliseconds(),t,3)}function wl(e,t){return Ml(e,t)+"000"}function xl(e,t){return ju(e.getUTCMonth()+1,t,2)}function Sl(e,t){return ju(e.getUTCMinutes(),t,2)}function Dl(e,t){return ju(e.getUTCSeconds(),t,2)}function Tl(e){var t=e.getUTCDay();return 0===t?7:t}function Ol(e,t){return ju(cu.count(Au(e),e),t,2)}function Pl(e,t){var n=e.getUTCDay();return e=n>=4||0===n?hu(e):hu.ceil(e),ju(hu.count(Au(e),e)+(4===Au(e).getUTCDay()),t,2)}function Ll(e){return e.getUTCDay()}function El(e,t){return ju(du.count(Au(e),e),t,2)}function jl(e,t){return ju(e.getUTCFullYear()%100,t,2)}function Cl(e,t){return ju(e.getUTCFullYear()%1e4,t,4)}function Yl(){return"+0000"}function Rl(){return"%"}function Nl(e){return+e}function _l(e){return Math.floor(+e/1e3)}!function(e){xu=function(e){var t=e.dateTime,n=e.date,r=e.time,a=e.periods,o=e.days,i=e.shortDays,s=e.months,u=e.shortMonths,l=Yu(a),c=Ru(a),d=Yu(o),f=Ru(o),p=Yu(i),h=Ru(i),m=Yu(s),y=Ru(s),v=Yu(u),b=Ru(u),g={a:function(e){return i[e.getDay()]},A:function(e){return o[e.getDay()]},b:function(e){return u[e.getMonth()]},B:function(e){return s[e.getMonth()]},c:null,d:tl,e:tl,f:il,H:nl,I:rl,j:al,L:ol,m:sl,M:ul,p:function(e){return a[+(e.getHours()>=12)]},Q:Nl,s:_l,S:ll,u:cl,U:dl,V:fl,w:pl,W:hl,x:null,X:null,y:ml,Y:yl,Z:vl,"%":Rl},A={a:function(e){return i[e.getUTCDay()]},A:function(e){return o[e.getUTCDay()]},b:function(e){return u[e.getUTCMonth()]},B:function(e){return s[e.getUTCMonth()]},c:null,d:bl,e:bl,f:wl,H:gl,I:Al,j:kl,L:Ml,m:xl,M:Sl,p:function(e){return a[+(e.getUTCHours()>=12)]},Q:Nl,s:_l,S:Dl,u:Tl,U:Ol,V:Pl,w:Ll,W:El,x:null,X:null,y:jl,Y:Cl,Z:Yl,"%":Rl},k={a:function(e,t,n){var r=p.exec(t.slice(n));return r?(e.w=h[r[0].toLowerCase()],n+r[0].length):-1},A:function(e,t,n){var r=d.exec(t.slice(n));return r?(e.w=f[r[0].toLowerCase()],n+r[0].length):-1},b:function(e,t,n){var r=v.exec(t.slice(n));return r?(e.m=b[r[0].toLowerCase()],n+r[0].length):-1},B:function(e,t,n){var r=m.exec(t.slice(n));return r?(e.m=y[r[0].toLowerCase()],n+r[0].length):-1},c:function(e,n,r){return x(e,t,n,r)},d:Uu,e:Uu,f:Xu,H:Gu,I:Gu,j:Ku,L:Qu,m:Vu,M:qu,p:function(e,t,n){var r=l.exec(t.slice(n));return r?(e.p=c[r[0].toLowerCase()],n+r[0].length):-1},Q:$u,s:el,S:Zu,u:_u,U:Iu,V:Hu,w:Nu,W:Fu,x:function(e,t,r){return x(e,n,t,r)},X:function(e,t,n){return x(e,r,t,n)},y:Wu,Y:Bu,Z:zu,"%":Ju};function M(e,t){return function(n){var r,a,o,i=[],s=-1,u=0,l=e.length;for(n instanceof Date||(n=new Date(+n));++s53)return null;"w"in o||(o.w=1),"Z"in o?(a=(r=Mu(wu(o.y))).getUTCDay(),r=a>4||0===a?du.ceil(r):du(r),r=uu.offset(r,7*(o.V-1)),o.y=r.getUTCFullYear(),o.m=r.getUTCMonth(),o.d=r.getUTCDate()+(o.w+6)%7):(a=(r=t(wu(o.y))).getDay(),r=a>4||0===a?Gs.ceil(r):Gs(r),r=Vs.offset(r,7*(o.V-1)),o.y=r.getFullYear(),o.m=r.getMonth(),o.d=r.getDate()+(o.w+6)%7)}else("W"in o||"U"in o)&&("w"in o||(o.w="u"in o?o.u%7:"W"in o?1:0),a="Z"in o?Mu(wu(o.y)).getUTCDay():t(wu(o.y)).getDay(),o.m=0,o.d="W"in o?(o.w+6)%7+7*o.W-(a+5)%7:o.w+7*o.U-(a+6)%7);return"Z"in o?(o.H+=o.Z/100|0,o.M+=o.Z%100,Mu(o)):t(o)}}function x(e,t,n,r){for(var a,o,i=0,s=t.length,u=n.length;i=u)return-1;if(37===(a=t.charCodeAt(i++))){if(a=t.charAt(i++),!(o=k[a in Ou?t.charAt(i++):a])||(r=o(e,n,r))<0)return-1}else if(a!=n.charCodeAt(r++))return-1}return r}return g.x=M(n,g),g.X=M(r,g),g.c=M(t,g),A.x=M(n,A),A.X=M(r,A),A.c=M(t,A),{format:function(e){var t=M(e+="",g);return t.toString=function(){return e},t},parse:function(e){var t=w(e+="",ku);return t.toString=function(){return e},t},utcFormat:function(e){var t=M(e+="",A);return t.toString=function(){return e},t},utcParse:function(e){var t=w(e,Mu);return t.toString=function(){return e},t}}}(e),Su=xu.format,xu.parse,Du=xu.utcFormat,Tu=xu.utcParse}({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});Date.prototype.toISOString||Du("%Y-%m-%dT%H:%M:%S.%LZ");+new Date("2000-01-01T00:00:00.000Z")||Tu("%Y-%m-%dT%H:%M:%S.%LZ");var Il=1e3,Hl=60*Il,Fl=60*Hl,Bl=24*Fl,Wl=7*Bl,zl=30*Bl,Vl=365*Bl;function Ul(e){return new Date(e)}function Kl(e){return e instanceof Date?+e:+new Date(+e)}function Gl(e,t,n,r,a,o,i,s,u){var l=Xi(Gi,Oi),c=l.invert,d=l.domain,f=u(".%L"),p=u(":%S"),h=u("%I:%M"),m=u("%I %p"),y=u("%a %d"),v=u("%b %d"),b=u("%B"),g=u("%Y"),A=[[i,1,Il],[i,5,5*Il],[i,15,15*Il],[i,30,30*Il],[o,1,Hl],[o,5,5*Hl],[o,15,15*Hl],[o,30,30*Hl],[a,1,Fl],[a,3,3*Fl],[a,6,6*Fl],[a,12,12*Fl],[r,1,Bl],[r,2,2*Bl],[n,1,Wl],[t,1,zl],[t,3,3*zl],[e,1,Vl]];function k(s){return(i(s)=0&&a===+a?"".concat(a,"px"):a),";");var r,a,o},"")},yc=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(null==e||me())return{width:0,height:0};var n="".concat(e),r=mc(t),a="".concat(n,"-").concat(r);if(fc.widthCache[a])return fc.widthCache[a];try{var o=document.getElementById("recharts_measurement_span");o||((o=document.createElement("span")).setAttribute("id","recharts_measurement_span"),document.body.appendChild(o));var i=function(e){for(var t=1;t2e3&&(fc.cacheCount=0,fc.widthCache={}),u}catch(e){return{width:0,height:0}}};function vc(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function bc(e){return(bc="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})(e)}function gc(){return(gc=Object.assign||function(e){for(var t=1;t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}function kc(e,t){for(var n=0;n=0?1:-1;"insideStart"===i?(r=h+g*u,a=y):"insideEnd"===i?(r=m-g*u,a=!y):"end"===i&&(r=m+g*u,a=y),a=b<=0?a:!a;var A=If(c,d,v,r),k=If(c,d,v,r+359*(a?1:-1)),M="M".concat(A.x,",").concat(A.y,"\n A").concat(v,",").concat(v,",0,1,").concat(a?0:1,",\n ").concat(k.x,",").concat(k.y),w=D()(e.id)?K("recharts-radial-line-"):e.id;return o.a.createElement("text",Pc({},n,{dominantBaseline:"central",className:O()("recharts-radial-bar-label",l)}),o.a.createElement("defs",null,o.a.createElement("path",{id:w,d:M})),o.a.createElement("textPath",{xlinkHref:"#".concat(w)},t))},Nc=function(e){var t=e.viewBox,n=e.offset,r=e.position,a=t.cx,o=t.cy,i=t.innerRadius,s=t.outerRadius,u=(t.startAngle+t.endAngle)/2;if("outside"===r){var l=If(a,o,s+n,u),c=l.x;return{x:c,y:l.y,textAnchor:c>=a?"start":"end",verticalAnchor:"middle"}}if("center"===r)return{x:a,y:o,textAnchor:"middle",verticalAnchor:"middle"};if("centerTop"===r)return{x:a,y:o,textAnchor:"middle",verticalAnchor:"start"};if("centerBottom"===r)return{x:a,y:o,textAnchor:"middle",verticalAnchor:"end"};var d=If(a,o,(i+s)/2,u);return{x:d.x,y:d.y,textAnchor:"middle",verticalAnchor:"middle"}},_c=function(e){var t=e.viewBox,n=e.offset,r=e.position,a=t.x,o=t.y,i=t.width,s=t.height,u=s>=0?1:-1;return"top"===r?{x:a+i/2,y:o-u*n,textAnchor:"middle",verticalAnchor:u>0?"end":"start"}:"bottom"===r?{x:a+i/2,y:o+s+u*n,textAnchor:"middle",verticalAnchor:"start"}:"left"===r?{x:a-n,y:o+s/2,textAnchor:"end",verticalAnchor:"middle"}:"right"===r?{x:a+i+n,y:o+s/2,textAnchor:"start",verticalAnchor:"middle"}:"insideLeft"===r?{x:a+n,y:o+s/2,textAnchor:"start",verticalAnchor:"middle"}:"insideRight"===r?{x:a+i-n,y:o+s/2,textAnchor:"end",verticalAnchor:"middle"}:"insideTop"===r?{x:a+i/2,y:o+u*n,textAnchor:"middle",verticalAnchor:"start"}:"insideBottom"===r?{x:a+i/2,y:o+s-u*n,textAnchor:"middle",verticalAnchor:"end"}:"insideTopLeft"===r?{x:a+n,y:o+u*n,textAnchor:"start",verticalAnchor:"start"}:"insideTopRight"===r?{x:a+i-n,y:o+u*n,textAnchor:"end",verticalAnchor:"start"}:"insideBottomLeft"===r?{x:a+n,y:o+s-u*n,textAnchor:"start",verticalAnchor:"end"}:"insideBottomRight"===r?{x:a+i-n,y:o+s-u*n,textAnchor:"end",verticalAnchor:"end"}:j()(r)&&(z(r.x)||W(r.x))&&(z(r.y)||W(r.y))?{x:a+G(r.x,i),y:o+G(r.y,s),textAnchor:"end",verticalAnchor:"end"}:{x:a+i/2,y:o+s/2,textAnchor:"middle",verticalAnchor:"middle"}},Ic=function(e){return z(e.cx)};function Hc(e){var t,n=e.viewBox,r=e.position,i=e.value,s=e.children,u=e.content,l=e.className,c=void 0===l?"":l;if(!n||D()(i)&&D()(s)&&!Object(a.isValidElement)(u)&&!A()(u))return null;if(Object(a.isValidElement)(u))return Object(a.cloneElement)(u,e);if(A()(u)){if(t=u(e),Object(a.isValidElement)(t))return t}else t=Yc(e);var d=Ic(n),f=le(e);if(d&&("insideStart"===r||"insideEnd"===r||"end"===r))return Rc(e,t,f);var p=d?Nc(e):_c(e);return o.a.createElement(Tc,Pc({className:O()("recharts-label",c)},f,p),t)}Hc.displayName="Label",Hc.defaultProps={offset:5},Hc.propTypes=Cc;var Fc=function(e){var t=e.cx,n=e.cy,r=e.angle,a=e.startAngle,o=e.endAngle,i=e.r,s=e.radius,u=e.innerRadius,l=e.outerRadius,c=e.x,d=e.y,f=e.top,p=e.left,h=e.width,m=e.height,y=e.clockWise;if(z(h)&&z(m)){if(z(c)&&z(d))return{x:c,y:d,width:h,height:m};if(z(f)&&z(p))return{x:f,y:p,width:h,height:m}}return z(c)&&z(d)?{x:c,y:d,width:0,height:0}:z(t)&&z(n)?{cx:t,cy:n,startAngle:a||r||0,endAngle:o||r||0,innerRadius:u||0,outerRadius:l||s||i||0,clockWise:y}:e.viewBox?e.viewBox:{}};Hc.parseViewBox=Fc,Hc.renderCallByParent=function(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];if(!e||!e.children&&n&&!e.label)return null;var r=e.children,i=Fc(e),s=se(r,Hc).map(function(e,n){return Object(a.cloneElement)(e,{viewBox:t||i,key:"label-".concat(n)})});return n?[function(e,t){return e?!0===e?o.a.createElement(Hc,{key:"label-implicit",viewBox:t}):V(e)?o.a.createElement(Hc,{key:"label-implicit",viewBox:t,value:e}):Object(a.isValidElement)(e)||A()(e)?o.a.createElement(Hc,{key:"label-implicit",content:e,viewBox:t}):j()(e)?o.a.createElement(Hc,Pc({viewBox:t},e,{key:"label-implicit"})):null:null}(e.label,t||i)].concat(Oc(s)):s};var Bc=Hc,Wc=n(104),zc=n.n(Wc);function Vc(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Uc(e,t){for(var n=0;n1&&void 0!==arguments[1]?arguments[1]:{}).bandAware;if(void 0!==e){if(t){var n=this.bandwidth?this.bandwidth()/2:0;return this.scale(e)+n}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}},{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}}]),e}();qc.EPS=1e-4;var Zc,Qc,Xc,Jc=function(){function e(t){Vc(this,e),this.scales=zc()(t,qc.create),Object.assign(this,this.scales)}return Kc(e,null,[{key:"create",value:function(e){return new this(e)}}]),Kc(e,[{key:"apply",value:function(e){var t=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).bandAware,n=this.scales;return zc()(e,function(e,r){return n[r].apply(e,{bandAware:t})})}},{key:"isInRange",value:function(e){var t=this.scales;return h()(e,function(e,n){return t[n].isInRange(e)})}}]),e}();function $c(e){return($c="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})(e)}function ed(){return(ed=Object.assign||function(e){for(var t=1;t=0?1:-1,u=r>=0?1:0;if(i>0&&a instanceof Array){for(var l=[],c=0;c<4;c++)l[c]=a[c]>i?i:a[c];o="M".concat(e,",").concat(t+s*l[0]),l[0]>0&&(o+="A ".concat(l[0],",").concat(l[0],",0,0,").concat(u,",").concat(e+l[0],",").concat(t)),o+="L ".concat(e+n-l[1],",").concat(t),l[1]>0&&(o+="A ".concat(l[1],",").concat(l[1],",0,0,").concat(u,",\n ").concat(e+n,",").concat(t+s*l[1])),o+="L ".concat(e+n,",").concat(t+r-s*l[2]),l[2]>0&&(o+="A ".concat(l[2],",").concat(l[2],",0,0,").concat(u,",\n ").concat(e+n-l[2],",").concat(t+r)),o+="L ".concat(e+l[3],",").concat(t+r),l[3]>0&&(o+="A ".concat(l[3],",").concat(l[3],",0,0,").concat(u,",\n ").concat(e,",").concat(t+r-s*l[3])),o+="Z"}else if(i>0&&a===+a&&a>0){var d=Math.min(i,a);o="M ".concat(e,",").concat(t+s*d,"\n A ").concat(d,",").concat(d,",0,0,").concat(u,",").concat(e+d,",").concat(t,"\n L ").concat(e+n-d,",").concat(t,"\n A ").concat(d,",").concat(d,",0,0,").concat(u,",").concat(e+n,",").concat(t+s*d,"\n L ").concat(e+n,",").concat(t+r-s*d,"\n A ").concat(d,",").concat(d,",0,0,").concat(u,",").concat(e+n-d,",").concat(t+r,"\n L ").concat(e+d,",").concat(t+r,"\n A ").concat(d,",").concat(d,",0,0,").concat(u,",").concat(e,",").concat(t+r-s*d," Z")}else o="M ".concat(e,",").concat(t," h ").concat(n," v ").concat(r," h ").concat(-n," Z");return o},_d=$((xd=wd=function(e){function t(){var e,n;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);for(var r=arguments.length,a=new Array(r),o=0;o0,from:{width:a,height:i,x:n,y:r},to:{width:a,height:i,x:n,y:r},duration:f,animationEasing:d,isActive:m},function(t){var n=t.width,r=t.height,a=t.x,i=t.y;return o.a.createElement(Gt,{canBegin:l>0,from:"0px ".concat(-1===l?1:l,"px"),to:"".concat(l,"px 0px"),attributeName:"strokeDasharray",begin:p,duration:f,isActive:h,easing:d},o.a.createElement("path",Od({},le(e.props),de(e.props),{className:y,d:Nd(a,i,n,r,s),ref:function(t){e.node=t}})))}):o.a.createElement("path",Od({},le(this.props),de(this.props),{className:y,d:Nd(n,r,a,i,s)}))}}])&&Pd(n.prototype,r),i&&Pd(n,i),t}(),wd.displayName="Rectangle",wd.propTypes=function(e){for(var t=1;t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}function Xd(e,t){for(var n=0;n=0});if(o&&o.length){var i=o.map(function(e){return e.props.dataKey});return e.reduce(function(e,t){var r=sf(t,n,0),a=Y()(r)?[Fa()(r),Ia()(r)]:[r,r],o=i.reduce(function(e,n){var r=sf(t,n,0),o=a[0]-Math.abs(Y()(r)?r[0]:r),i=a[1]+Math.abs(Y()(r)?r[1]:r);return[Math.min(o,e[0]),Math.max(i,e[1])]},[1/0,-1/0]);return[Math.min(o[0],e[0]),Math.max(o[1],e[1])]},[1/0,-1/0])}return null},ff=function(e,t,n,r){var a=t.map(function(t){var a=t.props.dataKey;return"number"===n&&a&&df(e,t,a)||uf(e,a,n,r)});if("number"===n)return a.reduce(function(e,t){return[Math.min(e[0],t[0]),Math.max(e[1],t[1])]},[1/0,-1/0]);var o={};return a.reduce(function(e,t){for(var n=0,r=t.length;n=0||t.indexOf("AreaChart")>=0)?{scale:bo(),realScaleType:"point"}:"category"===a?{scale:vo(),realScaleType:"band"}:{scale:hs(),realScaleType:"linear"};if(L()(n)){var s="scale".concat(n.slice(0,1).toUpperCase()).concat(n.slice(1));return{scale:(r[s]||bo)(),realScaleType:r[s]?s:"point"}}return A()(n)?{scale:n}:{scale:bo(),realScaleType:"point"}},bf=function(e){var t=e.domain();if(t&&!(t.length<=2)){var n=t.length,r=e.range(),a=Math.min(r[0],r[1])-1e-4,o=Math.max(r[0],r[1])+1e-4,i=e(t[0]),s=e(t[n-1]);(io||so)&&e.domain([t[0],t[n-1]])}},gf={sign:function(e){var t=e.length;if(!(t<=0))for(var n=0,r=e[0].length;n=0?(e[i][n][0]=a,e[i][n][1]=a+s,a=e[i][n][1]):(e[i][n][0]=o,e[i][n][1]=o+s,o=e[i][n][1])}},expand:function(e,t){if((r=e.length)>0){for(var n,r,a,o=0,i=e[0].length;o0){for(var n,r=0,a=e[t[0]],o=a.length;r0&&(r=(n=e[t[0]]).length)>0){for(var n,r,a,o=0,i=1;i=2){for(var n=b()(t,function(e){return e.coordinate}),r=1/0,a=1,o=n.length;a2&&void 0!==arguments[2]?arguments[2]:{top:0,right:0,bottom:0,left:0};return Math.min(Math.abs(e-(n.left||0)-(n.right||0)),Math.abs(t-(n.top||0)-(n.bottom||0)))/2},Ff=function(e,t){var n,r,a,o,i,s,u=e.x,l=e.y,c=t.cx,d=t.cy,f=(r={x:c,y:d},a=(n={x:u,y:l}).x,o=n.y,i=r.x,s=r.y,Math.sqrt(Math.pow(a-i,2)+Math.pow(o-s,2)));if(f<=0)return{radius:f};var p=(u-c)/f,h=Math.acos(p);return l>d&&(h=2*Math.PI-h),{radius:f,angle:_f(h),angleInRadian:h}},Bf=function(e,t){var n=t.startAngle,r=t.endAngle,a=Math.floor(n/360),o=Math.floor(r/360);return e+360*Math.min(a,o)},Wf=function(e,t){var n=e.x,r=e.y,a=Ff({x:n,y:r},t),o=a.radius,i=a.angle,s=t.innerRadius,u=t.outerRadius;if(ou)return!1;if(0===o)return!0;var l,c=function(e){var t=e.startAngle,n=e.endAngle,r=Math.floor(t/360),a=Math.floor(n/360),o=Math.min(r,a);return{startAngle:t-360*o,endAngle:n-360*o}}(t),d=c.startAngle,f=c.endAngle,p=i;if(d<=f){for(;p>f;)p-=360;for(;p=d&&p<=f}else{for(;p>d;)p-=360;for(;p=f&&p<=d}return l?Lf({},t,{radius:o,angle:Bf(p,t)}):null};function zf(e){return(zf="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})(e)}function Vf(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Uf(){return(Uf=Object.assign||function(e){for(var t=1;t180),",").concat(+(o>s),",\n ").concat(l.x,",").concat(l.y,"\n ");if(r>0){var d=If(t,n,r,o),f=If(t,n,r,s);c+="L ".concat(f.x,",").concat(f.y,"\n A ").concat(r,",").concat(r,",0,\n ").concat(+(Math.abs(i)>180),",").concat(+(o<=s),",\n ").concat(d.x,",").concat(d.y," Z")}else c+="L ".concat(t,",").concat(n," Z");return c},Jf=$((Rf=Yf=function(e){function t(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),Gf(this,qf(t).apply(this,arguments))}var n,r,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}}),t&&Zf(e,t)}(t,a["Component"]),n=t,(r=[{key:"render",value:function(){var e=this.props,t=e.cx,n=e.cy,r=e.innerRadius,a=e.outerRadius,i=e.cornerRadius,s=e.startAngle,u=e.endAngle,l=e.className;if(a0&&Math.abs(s-u)<360?function(e){var t=e.cx,n=e.cy,r=e.innerRadius,a=e.outerRadius,o=e.cornerRadius,i=e.startAngle,s=e.endAngle,u=B(s-i),l=Qf({cx:t,cy:n,radius:a,angle:i,sign:u,cornerRadius:o}),c=l.circleTangency,d=l.lineTangency,f=l.theta,p=Qf({cx:t,cy:n,radius:a,angle:s,sign:-u,cornerRadius:o}),h=p.circleTangency,m=p.lineTangency,y=p.theta,v=Math.abs(i-s)-f-y;if(v<0)return Xf({cx:t,cy:n,innerRadius:r,outerRadius:a,startAngle:i,endAngle:s});var b="M ".concat(d.x,",").concat(d.y,"\n A").concat(o,",").concat(o,",0,0,").concat(+(u<0),",").concat(c.x,",").concat(c.y,"\n A").concat(a,",").concat(a,",0,").concat(+(v>180),",").concat(+(u<0),",").concat(h.x,",").concat(h.y,"\n A").concat(o,",").concat(o,",0,0,").concat(+(u<0),",").concat(m.x,",").concat(m.y,"\n ");if(r>0){var g=Qf({cx:t,cy:n,radius:r,angle:i,sign:u,isExternal:!0,cornerRadius:o}),A=g.circleTangency,k=g.lineTangency,M=g.theta,w=Qf({cx:t,cy:n,radius:r,angle:s,sign:-u,isExternal:!0,cornerRadius:o}),x=w.circleTangency,S=w.lineTangency,D=w.theta,T=Math.abs(i-s)-M-D;if(T<0)return"".concat(b,"L").concat(t,",").concat(n,"Z");b+="L".concat(S.x,",").concat(S.y,"\n A").concat(o,",").concat(o,",0,0,").concat(+(u<0),",").concat(x.x,",").concat(x.y,"\n A").concat(r,",").concat(r,",0,").concat(+(T>180),",").concat(+(u>0),",").concat(A.x,",").concat(A.y,"\n A").concat(o,",").concat(o,",0,0,").concat(+(u<0),",").concat(k.x,",").concat(k.y,"Z")}else b+="L".concat(t,",").concat(n,"Z");return b}({cx:t,cy:n,innerRadius:r,outerRadius:a,cornerRadius:Math.min(p,f/2),startAngle:s,endAngle:u}):Xf({cx:t,cy:n,innerRadius:r,outerRadius:a,startAngle:s,endAngle:u}),o.a.createElement("path",Uf({},le(this.props),de(this.props),{className:d,d:c}))}}])&&Kf(n.prototype,r),i&&Kf(n,i),t}(),Yf.displayName="Sector",Yf.propTypes=function(e){for(var t=1;t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}function ap(e,t){for(var n=0;n=2?B(m[1].coordinate-m[0].coordinate):1;if(1===b?(n="width"===h?c:d,r="width"===h?c+f:d+p):(n="width"===h?c+f:d+p,r="width"===h?c:d),t){var g=a[v-1],k=A()(o)?o(g.value):g.value,M=yc(k)[h]+y,w=b*(g.coordinate+b*M/2-r);m[v-1]=g=tp({},g,{tickCoord:w>0?g.coordinate-w*b:g.coordinate}),b*(g.tickCoord-b*M/2-n)>=0&&b*(g.tickCoord+b*M/2-r)<=0&&(r=g.tickCoord-b*(M/2+u),m[v-1]=tp({},g,{isShow:!0}))}for(var x=t?v-1:v,S=0;S=0&&b*(D.tickCoord+b*O/2-r)<=0&&(n=D.tickCoord+b*(O/2+u),m[S]=tp({},D,{isShow:!0}))}return m.filter(function(e){return e.isShow})}},{key:"getTicksEnd",value:function(e){var t,n,r=e.ticks,a=e.tickFormatter,o=e.viewBox,i=e.orientation,s=e.minTickGap,u=e.unit,l=o.x,c=o.y,d=o.width,f=o.height,p="top"===i||"bottom"===i?"width":"height",h=u?yc(u)[p]:0,m=(r||[]).slice(),y=m.length,v=y>=2?B(m[1].coordinate-m[0].coordinate):1;1===v?(t="width"===p?l:c,n="width"===p?l+d:c+f):(t="width"===p?l+d:c+f,n="width"===p?l:c);for(var b=y-1;b>=0;b--){var g=m[b],k=A()(a)?a(g.value):g.value,M=yc(k)[p]+h;if(b===y-1){var w=v*(g.coordinate+v*M/2-n);m[b]=g=tp({},g,{tickCoord:w>0?g.coordinate-w*v:g.coordinate})}else m[b]=g=tp({},g,{tickCoord:g.coordinate});v*(g.tickCoord-v*M/2-t)>=0&&v*(g.tickCoord+v*M/2-n)<=0&&(n=g.tickCoord-v*(M/2+s),m[b]=tp({},g,{isShow:!0}))}return m.filter(function(e){return e.isShow})}},{key:"renderTickItem",value:function(e,t,n){return o.a.isValidElement(e)?o.a.cloneElement(e,t):A()(e)?e(t):o.a.createElement(Tc,ep({},t,{className:"recharts-cartesian-axis-tick-value"}),n)}}],(r=[{key:"shouldComponentUpdate",value:function(e,t){var n=e.viewBox,r=rp(e,["viewBox"]),a=this.props,o=a.viewBox,i=rp(a,["viewBox"]);return!X(n,o)||!X(r,i)||!X(t,this.state)}},{key:"getTickLineCoord",value:function(e){var t,n,r,a,o,i,s=this.props,u=s.x,l=s.y,c=s.width,d=s.height,f=s.orientation,p=s.tickSize,h=s.mirror,m=s.tickMargin,y=h?-1:1,v=e.tickSize||p,b=z(e.tickCoord)?e.tickCoord:e.coordinate;switch(f){case"top":t=n=e.coordinate,i=(r=(a=l+!h*d)-y*v)-y*m,o=b;break;case"left":r=a=e.coordinate,o=(t=(n=u+!h*c)-y*v)-y*m,i=b;break;case"right":r=a=e.coordinate,o=(t=(n=u+h*c)+y*v)+y*m,i=b;break;default:t=n=e.coordinate,i=(r=(a=l+h*d)+y*v)+y*m,o=b}return{line:{x1:t,y1:r,x2:n,y2:a},tick:{x:o,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 e=this.props,t=e.x,n=e.y,r=e.width,a=e.height,i=e.orientation,s=e.axisLine,u=e.mirror,l=tp({},le(this.props),{fill:"none"},le(s));if("top"===i||"bottom"===i){var c="top"===i&&!u||"bottom"===i&&u;l=tp({},l,{x1:t,y1:n+c*a,x2:t+r,y2:n+c*a})}else{var d="left"===i&&!u||"right"===i&&u;l=tp({},l,{x1:t+d*r,y1:n,x2:t+d*r,y2:n+a})}return o.a.createElement("line",ep({className:"recharts-cartesian-axis-line"},l))}},{key:"renderTicks",value:function(e){var n=this,r=this.props,a=r.tickLine,i=r.stroke,s=r.tick,u=r.tickFormatter,l=r.unit,c=t.getTicks(tp({},this.props,{ticks:e})),d=this.getTickTextAnchor(),f=this.getTickVerticalAnchor(),p=le(this.props),h=le(s),m=tp({},p,{fill:"none"},le(a)),y=c.map(function(e,t){var r=n.getTickLineCoord(e),y=r.line,v=r.tick,b=tp({textAnchor:d,verticalAnchor:f},p,{stroke:"none",fill:i},h,v,{index:t,payload:e,visibleTicksCount:c.length});return o.a.createElement(Le,ep({className:"recharts-cartesian-axis-tick",key:"tick-".concat(t)},pe(n.props,e,t)),a&&o.a.createElement("line",ep({className:"recharts-cartesian-axis-tick-line"},m,y)),s&&n.constructor.renderTickItem(s,b,"".concat(A()(u)?u(e.value):e.value).concat(l||"")))});return o.a.createElement("g",{className:"recharts-cartesian-axis-ticks"},y)}},{key:"render",value:function(){var e=this.props,t=e.axisLine,n=e.width,r=e.height,a=e.ticksGenerator,i=e.className;if(e.hide)return null;var s=this.props,u=s.ticks,l=rp(s,["ticks"]),c=u;return A()(a)&&(c=u&&u.length>0?a(this.props):a(l)),n<=0||r<=0||!c||!c.length?null:o.a.createElement(Le,{className:O()("recharts-cartesian-axis",i)},t&&this.renderAxisLine(),this.renderTicks(c),Bc.renderCallByParent(this.props))}}])&&ap(n.prototype,r),i&&ap(n,i),t}();up.displayName="CartesianAxis",up.propTypes=tp({},ne,re,{className:s.a.string,x:s.a.number,y:s.a.number,width:s.a.number,height:s.a.number,orientation:s.a.oneOf(["top","bottom","left","right"]),viewBox:s.a.shape({x:s.a.number,y:s.a.number,width:s.a.number,height:s.a.number}),tick:s.a.oneOfType([s.a.bool,s.a.func,s.a.object,s.a.element]),axisLine:s.a.oneOfType([s.a.bool,s.a.object]),tickLine:s.a.oneOfType([s.a.bool,s.a.object]),mirror:s.a.bool,tickMargin:s.a.number.isRequired,minTickGap:s.a.number,ticks:s.a.array,tickSize:s.a.number,stroke:s.a.string,tickFormatter:s.a.func,ticksGenerator:s.a.func,interval:s.a.oneOfType([s.a.number,s.a.oneOf(["preserveStart","preserveEnd","preserveStartEnd"])])}),up.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 lp=up;function cp(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var dp,fp,pp,hp=["Webkit","Moz","O","ms"],mp=function(e,t){if(!e)return null;var n=e.replace(/(\w)/,function(e){return e.toUpperCase()}),r=hp.reduce(function(e,r){return function(e){for(var t=1;t0&&n.handleDrag(e.changedTouches[0])},n.handleDragEnd=function(){n.setState({isTravellerMoving:!1,isSlideMoving:!1})},n.handleLeaveWrapper=function(){(n.state.isTravellerMoving||n.state.isSlideMoving)&&(n.leaveTimer=setTimeout(n.handleDragEnd,1e3))},n.handleEnterSlideOrTraveller=function(){n.setState({isTextActive:!0})},n.handleLeaveSlideOrTraveller=function(){n.setState({isTextActive:!1})},n.handleSlideDragStart=function(e){var t=e.changedTouches&&e.changedTouches.length?e.changedTouches[0]:e;n.setState({isTravellerMoving:!1,isSlideMoving:!0,slideMoveStartX:t.pageX})},n.travellerDragStartHandlers={startX:n.handleTravellerDragStart.bind(Mp(Mp(n)),"startX"),endX:n.handleTravellerDragStart.bind(Mp(Mp(n)),"endX")},n.state=e.data&&e.data.length?n.updateScale(e):{},n}var n,r,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}}),t&&kp(e,t)}(t,a["Component"]),n=t,i=[{key:"getIndexInRange",value:function(e,t){for(var n=0,r=e.length-1;r-n>1;){var a=Math.floor((n+r)/2);e[a]>t?r=a:n=a}return t>=e[r]?r:n}}],(r=[{key:"componentWillReceiveProps",value:function(e){var t=this,n=this.props,r=n.data,a=n.width,o=n.x,i=n.travellerWidth,s=n.updateId;(e.data!==r||e.updateId!==s)&&e.data&&e.data.length?this.setState(this.updateScale(e)):e.width===a&&e.x===o&&e.travellerWidth===i||(this.scale.range([e.x,e.x+e.width-e.travellerWidth]),this.scaleValues=this.scale.domain().map(function(e){return t.scale(e)}),this.setState({startX:this.scale(e.startIndex),endX:this.scale(e.endIndex)}))}},{key:"componentWillUnmount",value:function(){this.scale=null,this.scaleValues=null,this.leaveTimer&&(clearTimeout(this.leaveTimer),this.leaveTimer=null)}},{key:"getIndex",value:function(e){var t=e.startX,n=e.endX,r=this.props,a=r.gap,o=r.data.length-1,i=Math.min(t,n),s=Math.max(t,n),u=this.constructor.getIndexInRange(this.scaleValues,i),l=this.constructor.getIndexInRange(this.scaleValues,s);return{startIndex:u-u%a,endIndex:l===o?o:l-l%a}}},{key:"getTextOfTick",value:function(e){var t=this.props,n=t.data,r=t.tickFormatter,a=t.dataKey,o=sf(n[e],a,e);return A()(r)?r(o):o}},{key:"handleSlideDrag",value:function(e){var t=this.state,n=t.slideMoveStartX,r=t.startX,a=t.endX,o=this.props,i=o.x,s=o.width,u=o.travellerWidth,l=o.startIndex,c=o.endIndex,d=o.onChange,f=e.pageX-n;f>0?f=Math.min(f,i+s-u-a,i+s-u-r):f<0&&(f=Math.max(f,i-r,i-a));var p=this.getIndex({startX:r+f,endX:a+f});p.startIndex===l&&p.endIndex===c||!d||d(p),this.setState({startX:r+f,endX:a+f,slideMoveStartX:e.pageX})}},{key:"handleTravellerDragStart",value:function(e,t){var n=t.changedTouches&&t.changedTouches.length?t.changedTouches[0]:t;this.setState({isSlideMoving:!1,isTravellerMoving:!0,movingTravellerId:e,brushMoveStartX:n.pageX})}},{key:"handleTravellerMove",value:function(e){var t,n=this.state,r=n.brushMoveStartX,a=n.movingTravellerId,o=n.endX,i=n.startX,s=this.state[a],u=this.props,l=u.x,c=u.width,d=u.travellerWidth,f=u.onChange,p=u.gap,h=u.data,m={startX:this.state.startX,endX:this.state.endX},y=e.pageX-r;y>0?y=Math.min(y,l+c-d-s):y<0&&(y=Math.max(y,l-s)),m[a]=s+y;var v=this.getIndex(m),b=v.startIndex,g=v.endIndex;this.setState((bp(t={},a,s+y),bp(t,"brushMoveStartX",e.pageX),t),function(){var e;f&&(e=h.length-1,("startX"===a&&(o>i?b%p==0:g%p==0)||oi?g%p==0:b%p==0)||o>i&&g===e)&&f(v))})}},{key:"updateScale",value:function(e){var t=this,n=e.data,r=e.startIndex,a=e.endIndex,o=e.x,i=e.width,s=e.travellerWidth,u=n.length;return this.scale=bo().domain(M()(0,u)).range([o,o+i-s]),this.scaleValues=this.scale.domain().map(function(e){return t.scale(e)}),{isTextActive:!1,isSlideMoving:!1,isTravellerMoving:!1,startX:this.scale(r),endX:this.scale(a)}}},{key:"renderBackground",value:function(){var e=this.props,t=e.x,n=e.y,r=e.width,a=e.height,i=e.fill,s=e.stroke;return o.a.createElement("rect",{stroke:s,fill:i,x:t,y:n,width:r,height:a})}},{key:"renderPanorama",value:function(){var e=this.props,t=e.x,n=e.y,r=e.width,i=e.height,s=e.data,u=e.children,l=e.padding,c=a.Children.only(u);return c?o.a.cloneElement(c,{x:t,y:n,width:r,height:i,margin:l,compact:!0,data:s}):null}},{key:"renderTraveller",value:function(e,t){var n=this.props,r=n.y,a=n.travellerWidth,i=n.height,s=n.stroke,u=Math.floor(r+i/2)-1,l=Math.max(e,this.props.x);return o.a.createElement(Le,{className:"recharts-brush-traveller",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.travellerDragStartHandlers[t],onTouchStart:this.travellerDragStartHandlers[t],style:{cursor:"col-resize"}},o.a.createElement("rect",{x:l,y:r,width:a,height:i,fill:s,stroke:"none"}),o.a.createElement("line",{x1:l+1,y1:u,x2:l+a-1,y2:u,fill:"none",stroke:"#fff"}),o.a.createElement("line",{x1:l+1,y1:u+2,x2:l+a-1,y2:u+2,fill:"none",stroke:"#fff"}))}},{key:"renderSlide",value:function(e,t){var n=this.props,r=n.y,a=n.height,i=n.stroke;return o.a.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:Math.min(e,t),y:r,width:Math.abs(t-e),height:a})}},{key:"renderText",value:function(){var e=this.props,t=e.startIndex,n=e.endIndex,r=e.y,a=e.height,i=e.travellerWidth,s=e.stroke,u=this.state,l=u.startX,c=u.endX,d={pointerEvents:"none",fill:s};return o.a.createElement(Le,{className:"recharts-brush-texts"},o.a.createElement(Tc,vp({textAnchor:"end",verticalAnchor:"middle",x:Math.min(l,c)-5,y:r+a/2},d),this.getTextOfTick(t)),o.a.createElement(Tc,vp({textAnchor:"start",verticalAnchor:"middle",x:Math.max(l,c)+i+5,y:r+a/2},d),this.getTextOfTick(n)))}},{key:"render",value:function(){var e=this.props,t=e.data,n=e.className,r=e.children,a=e.x,i=e.y,s=e.width,u=e.height,l=this.state,c=l.startX,d=l.endX,f=l.isTextActive,p=l.isSlideMoving,h=l.isTravellerMoving;if(!t||!t.length||!z(a)||!z(i)||!z(s)||!z(u)||s<=0||u<=0)return null;var m=O()("recharts-brush",n),y=1===o.a.Children.count(r),v=mp("userSelect","none");return o.a.createElement(Le,{className:m,onMouseMove:this.handleDrag,onMouseLeave:this.handleLeaveWrapper,onMouseUp:this.handleDragEnd,onTouchEnd:this.handleDragEnd,onTouchMove:this.handleTouchMove,style:v},this.renderBackground(),y&&this.renderPanorama(),this.renderSlide(c,d),this.renderTraveller(c,"startX"),this.renderTraveller(d,"endX"),(f||p||h)&&this.renderText())}}])&&gp(n.prototype,r),i&&gp(n,i),t}(),fp.displayName="Brush",fp.propTypes={className:s.a.string,fill:s.a.string,stroke:s.a.string,x:s.a.number,y:s.a.number,width:s.a.number,height:s.a.number.isRequired,travellerWidth:s.a.number,gap:s.a.number,padding:s.a.shape({top:s.a.number,right:s.a.number,bottom:s.a.number,left:s.a.number}),dataKey:s.a.oneOfType([s.a.string,s.a.number,s.a.func]),data:s.a.array,startIndex:s.a.number,endIndex:s.a.number,tickFormatter:s.a.func,children:s.a.node,onChange:s.a.func,updateId:s.a.oneOfType([s.a.string,s.a.number])},fp.defaultProps={height:40,travellerWidth:5,gap:1,fill:"#fff",stroke:"#666",padding:{top:1,right:1,bottom:1,left:1}},dp=pp))||dp,xp=n(302),Sp=new(n.n(xp).a);Sp.setMaxListeners&&Sp.setMaxListeners(10);var Dp="recharts.syncMouseEvents";function Tp(e){return(Tp="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})(e)}function Op(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}function Pp(){return(Pp=Object.assign||function(e){for(var t=1;t0&&n.handleMouseMove(e.changedTouches[0])},n.handleTouchStart=function(e){null!=e.changedTouches&&e.changedTouches.length>0&&n.handleMouseDown(e.changedTouches[0])},n.handleTouchEnd=function(e){null!=e.changedTouches&&e.changedTouches.length>0&&n.handleMouseUp(e.changedTouches[0])},n.verticalCoordinatesGenerator=function(e){var t=e.xAxis,n=e.width,r=e.height,a=e.offset;return hf(lp.getTicks(Ep({},lp.defaultProps,t,{ticks:mf(t,!0),viewBox:{x:0,y:0,width:n,height:r}})),a.left,a.left+a.width)},n.horizontalCoordinatesGenerator=function(e){var t=e.yAxis,n=e.width,r=e.height,a=e.offset;return hf(lp.getTicks(Ep({},lp.defaultProps,t,{ticks:mf(t,!0),viewBox:{x:0,y:0,width:n,height:r}})),a.top,a.top+a.height)},n.axesTicksGenerator=function(e){return mf(e,!0)},n.tooltipTicksGenerator=function(e){var t=q(e),n=mf(t,!1,!0);return{tooltipTicks:n,orderedTooltipTicks:b()(n,function(e){return e.coordinate}),tooltipAxis:t,tooltipAxisBandSize:Of(t)}},n.renderCursor=function(e){var r=n.state,o=r.isTooltipActive,i=r.activeCoordinate,s=r.activePayload,u=r.offset;if(!(e&&e.props.cursor&&o&&i))return null;var l,c=n.props.layout,d=Oa;if("ScatterChart"===t)l=i,d=Na;else if("BarChart"===t)l=n.getCursorRectangle(),d=_d;else if("radial"===c){var f=n.getCursorPoints(),p=f.cx,h=f.cy,m=f.radius;l={cx:p,cy:h,startAngle:f.startAngle,endAngle:f.endAngle,innerRadius:m,outerRadius:m},d=Jf}else l={points:n.getCursorPoints()},d=Oa;var y=e.key||"_recharts-cursor",v=Ep({stroke:"#ccc",pointerEvents:"none"},u,l,le(e.props.cursor),{payload:s,key:y,className:"recharts-tooltip-cursor"});return Object(a.isValidElement)(e.props.cursor)?Object(a.cloneElement)(e.props.cursor,v):Object(a.createElement)(d,v)},n.renderPolarAxis=function(e,t,r){var o=e.type.axisType,i=n.state["".concat(o,"Map")][e.props["".concat(o,"Id")]];return Object(a.cloneElement)(e,Ep({},i,{className:o,key:e.key||"".concat(t,"-").concat(r),ticks:mf(i,!0)}))},n.renderXAxis=function(e,t,r){var a=n.state.xAxisMap[e.props.xAxisId];return n.renderAxis(a,e,t,r)},n.renderYAxis=function(e,t,r){var a=n.state.yAxisMap[e.props.yAxisId];return n.renderAxis(a,e,t,r)},n.renderGrid=function(e){var t=n.state,r=t.xAxisMap,o=t.yAxisMap,i=t.offset,s=n.props,u=s.width,l=s.height,c=q(r),d=y()(o,function(e){return h()(e.domain,Number.isFinite)})||q(o),f=e.props||{};return Object(a.cloneElement)(e,{key:e.key||"grid",x:z(f.x)?f.x:i.left,y:z(f.y)?f.y:i.top,width:z(f.width)?f.width:i.width,height:z(f.height)?f.height:i.height,xAxis:c,yAxis:d,offset:i,chartWidth:u,chartHeight:l,verticalCoordinatesGenerator:f.verticalCoordinatesGenerator||n.verticalCoordinatesGenerator,horizontalCoordinatesGenerator:f.horizontalCoordinatesGenerator||n.horizontalCoordinatesGenerator})},n.renderPolarGrid=function(e){var t=n.state,r=t.radiusAxisMap,o=t.angleAxisMap,i=q(r),s=q(o),u=s.cx,l=s.cy,c=s.innerRadius,d=s.outerRadius;return Object(a.cloneElement)(e,{polarAngles:mf(s,!0).map(function(e){return e.coordinate}),polarRadius:mf(i,!0).map(function(e){return e.coordinate}),cx:u,cy:l,innerRadius:c,outerRadius:d,key:e.key||"polar-grid"})},n.renderBrush=function(e){var t=n.props,r=t.margin,o=t.data,i=n.state,s=i.offset,u=i.dataStartIndex,l=i.dataEndIndex,c=i.updateId;return Object(a.cloneElement)(e,{key:e.key||"_recharts-brush",onChange:yf(n.handleBrushChange,null,e.props.onChange),data:o,x:z(e.props.x)?e.props.x:s.left,y:z(e.props.y)?e.props.y:s.top+s.height+s.brushBottom-(r.bottom||0),width:z(e.props.width)?e.props.width:s.width,startIndex:u,endIndex:l,updateId:"brush-".concat(c)})},n.renderReferenceElement=function(e,t,r){if(!e)return null;var o=Np(Np(n)).clipPathId,i=n.state,s=i.xAxisMap,u=i.yAxisMap,l=i.offset,c=e.props,d=c.xAxisId,f=c.yAxisId;return Object(a.cloneElement)(e,{key:e.key||"".concat(t,"-").concat(r),xAxis:s[d],yAxis:u[f],viewBox:{x:l.left,y:l.top,width:l.width,height:l.height},clipPathId:o})},n.renderGraphicChild=function(e,t,r){var o=n.filterFormatItem(e,t,r);if(!o)return null;var i,s,u=Object(a.cloneElement)(e,o.props),l=n.state,c=l.isTooltipActive,d=l.tooltipAxis,f=l.activeTooltipIndex,p=l.activeLabel,h=n.props.children,m=ue(h,vn),y=o.props,v=y.points,b=y.isRange,g=y.baseLine,A=o.item.props,k=A.activeDot;return!A.hide&&c&&m&&k&&f>=0&&(d.dataKey&&!d.allowDuplicatedCategory?(i=Q(v,"payload.".concat(d.dataKey),p),s=b&&g&&Q(g,"payload.".concat(d.dataKey),p)):(i=v[f],s=b&&g&&g[f]),!D()(i))?[u].concat(Lp(n.renderActivePoints({item:o,activePoint:i,basePoint:s,childIndex:f,isRange:b}))):b?[u,null,null]:[u,null]};var s=n.constructor.createDefaultState(e);return n.state=Ep({},s,{updateId:0},n.updateStateOfAxisMapsOffsetAndStackGroups(Ep({props:e},s,{updateId:0}))),n.uniqueChartId=D()(e.id)?K("recharts"):e.id,n.clipPathId="".concat(n.uniqueChartId,"-clip"),e.throttleDelay&&(n.triggeredAfterMouseMove=x()(n.triggeredAfterMouseMove,e.throttleDelay)),n}var s,d,f;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}}),t&&Rp(e,t)}(r,a.Component),s=r,f=[{key:"getAxisNameByLayout",value: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"}}},{key:"renderActiveDot",value:function(e,t){var n;return n=Object(a.isValidElement)(e)?Object(a.cloneElement)(e,t):A()(e)?e(t):o.a.createElement(sc,t),o.a.createElement(Le,{className:"recharts-active-dot",key:t.key},n)}}],(d=[{key:"componentDidMount",value:function(){D()(this.props.syncId)||this.addListener()}},{key:"componentWillReceiveProps",value:function(e){var t=this,n=this.props,r=n.data,a=n.children,o=n.width,i=n.height,s=n.layout,u=n.stackOffset,l=n.margin,c=this.state.updateId;if(e.data===r&&e.width===o&&e.height===i&&e.layout===s&&e.stackOffset===u&&X(e.margin,l)){if(!be(e.children,a)){var d=D()(e.data)?c+1:c;this.setState(function(n){return Ep({updateId:d},t.updateStateOfAxisMapsOffsetAndStackGroups(Ep({props:e},n,{updateId:d})))})}}else{var f=this.constructor.createDefaultState(e);this.setState(Ep({},f,{updateId:c+1},this.updateStateOfAxisMapsOffsetAndStackGroups(Ep({props:e},f,{updateId:c+1}))))}D()(this.props.syncId)&&!D()(e.syncId)&&this.addListener(),!D()(this.props.syncId)&&D()(e.syncId)&&this.removeListener()}},{key:"componentWillUnmount",value:function(){D()(this.props.syncId)||this.removeListener(),"function"==typeof this.triggeredAfterMouseMove.cancel&&this.triggeredAfterMouseMove.cancel()}},{key:"getAxisMap",value:function(e,t){var n=t.axisType,r=void 0===n?"xAxis":n,a=t.AxisComp,o=t.graphicalItems,i=t.stackGroups,s=t.dataStartIndex,u=t.dataEndIndex,l=e.children,c="".concat(r,"Id"),d=se(l,a),f={};return d&&d.length?f=this.getAxisMapByAxes(e,{axes:d,graphicalItems:o,axisType:r,axisIdKey:c,stackGroups:i,dataStartIndex:s,dataEndIndex:u}):o&&o.length&&(f=this.getAxisMapByItems(e,{Axis:a,graphicalItems:o,axisType:r,axisIdKey:c,stackGroups:i,dataStartIndex:s,dataEndIndex:u})),f}},{key:"getAxisMapByAxes",value:function(e,t){var n=this,r=t.axes,a=t.graphicalItems,o=t.axisType,i=t.axisIdKey,s=t.stackGroups,u=t.dataStartIndex,l=t.dataEndIndex,c=e.layout,d=e.children,f=e.stackOffset,p=pf(c,o);return r.reduce(function(t,r){var h=r.props,m=h.type,y=h.dataKey,v=h.allowDataOverflow,b=h.allowDuplicatedCategory,g=h.scale,A=h.ticks,k=r.props[i],w=n.constructor.getDisplayedData(e,{graphicalItems:a.filter(function(e){return e.props[i]===k}),dataStartIndex:u,dataEndIndex:l}),x=w.length;if(!t[k]){var S,T,O;if(y){if(S=uf(w,y,m),"category"===m&&p){var P=function(e){if(!Y()(e))return!1;for(var t=e.length,n={},r=0;r=0?e:Lp(e).concat([t])},[]))}else if("category"===m)S=b?S.filter(function(e){return""!==e&&!D()(e)}):Pf(r.props.domain,S,r).reduce(function(e,t){return e.indexOf(t)>=0||""===t||D()(t)?e:Lp(e).concat([t])},[]);else if("number"===m){var L=function(e,t,n,r){var a=t.map(function(t){return df(e,t,n,r)}).filter(function(e){return!D()(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}(w,a.filter(function(e){return e.props[i]===k&&!e.props.hide}),y,o);L&&(S=L)}!p||"number"!==m&&"auto"===g||(O=uf(w,y,"category"))}else S=p?M()(0,x):s&&s[k]&&s[k].hasStack&&"number"===m?"expand"===f?[0,1]:xf(s[k].stackGroups,u,l):ff(w,a.filter(function(e){return e.props[i]===k&&!e.props.hide}),m,!0);return"number"===m&&(S=wf(d,S,k,o,A),r.props.domain&&(S=Tf(r.props.domain,S,v))),Ep({},t,jp({},k,Ep({},r.props,{axisType:o,domain:S,categoricalDomain:O,duplicateDomain:T,originalDomain:r.props.domain,isCategorial:p,layout:c})))}return t},{})}},{key:"getAxisMapByItems",value:function(e,t){var n=t.graphicalItems,r=t.Axis,a=t.axisType,o=t.axisIdKey,i=t.stackGroups,s=t.dataStartIndex,u=t.dataEndIndex,l=e.layout,c=e.children,d=this.constructor.getDisplayedData(e,{graphicalItems:n,dataStartIndex:s,dataEndIndex:u}),f=d.length,p=pf(l,a),h=-1;return n.reduce(function(e,t){var m,y=t.props[o];return e[y]?e:(h++,p?m=M()(0,f):i&&i[y]&&i[y].hasStack?(m=xf(i[y].stackGroups,s,u),m=wf(c,m,y,a)):(m=Tf(r.defaultProps.domain,ff(d,n.filter(function(e){return e.props[o]===y&&!e.props.hide}),"number"),r.defaultProps.allowDataOverflow),m=wf(c,m,y,a)),Ep({},e,jp({},y,Ep({axisType:a},r.defaultProps,{hide:!0,orientation:Fp[a]&&Fp[a][h%2],domain:m,originalDomain:r.defaultProps.domain,isCategorial:p,layout:l}))))},{})}},{key:"getActiveCoordinate",value:function(e,t,n){var r=this.props.layout,a=e.find(function(e){return e&&e.index===t});if(a){if("horizontal"===r)return{x:a.coordinate,y:n.y};if("vertical"===r)return{x:n.x,y:a.coordinate};if("centric"===r){var o=a.coordinate,i=n.radius;return Ep({},n,If(n.cx,n.cy,i,o),{angle:o,radius:i})}var s=a.coordinate,u=n.angle;return Ep({},n,If(n.cx,n.cy,s,u),{angle:u,radius:s})}return Bp}},{key:"getMouseInfo",value:function(e){if(!this.container)return null;var t,n,r,a=function(e,t){return{chartX:Math.round(e.pageX-t.left),chartY:Math.round(e.pageY-t.top)}}(e,(t=this.container,n=t.ownerDocument.documentElement,r={top:0,left:0},void 0!==t.getBoundingClientRect&&(r=t.getBoundingClientRect()),{top:r.top+window.pageYOffset-n.clientTop,left:r.left+window.pageXOffset-n.clientLeft})),o=this.inRange(a.chartX,a.chartY);if(!o)return null;var s=this.state,u=s.xAxisMap,l=s.yAxisMap;if("axis"!==i&&u&&l){var c=q(u).scale,d=q(l).scale;return Ep({},a,{xValue:c&&c.invert?c.invert(a.chartX):null,yValue:d&&d.invert?d.invert(a.chartY):null})}var f=this.state,p=f.orderedTooltipTicks,h=f.tooltipAxis,m=f.tooltipTicks,y=function(e,t,n,r){var a=-1,o=t.length;if(o>1){if(r&&"angleAxis"===r.axisType&&Math.abs(Math.abs(r.range[1]-r.range[0])-360)<=1e-6)for(var i=r.range,s=0;s0?n[s-1].coordinate:n[o-1].coordinate,l=n[s].coordinate,c=s>=o-1?n[0].coordinate:n[s+1].coordinate,d=void 0;if(B(l-u)!==B(c-l)){var f=[];if(B(c-l)===B(i[1]-i[0])){d=c;var p=l+i[1]-i[0];f[0]=Math.min(p,(p+u)/2),f[1]=Math.max(p,(p+u)/2)}else{d=u;var h=c+i[1]-i[0];f[0]=Math.min(l,(h+l)/2),f[1]=Math.max(l,(h+l)/2)}var m=[Math.min(l,(d+l)/2),Math.max(l,(d+l)/2)];if(e>m[0]&&e<=m[1]||e>=f[0]&&e<=f[1]){a=n[s].index;break}}else{var y=Math.min(u,c),v=Math.max(u,c);if(e>(y+l)/2&&e<=(v+l)/2){a=n[s].index;break}}}else for(var b=0;b0&&b(t[b].coordinate+t[b-1].coordinate)/2&&e<=(t[b].coordinate+t[b+1].coordinate)/2||b===o-1&&e>(t[b].coordinate+t[b-1].coordinate)/2){a=t[b].index;break}}else a=0;return a}(this.calculateTooltipPos(o),p,m,h);if(y>=0&&m){var v=m[y]&&m[y].value;return Ep({},a,{activeTooltipIndex:y,activeLabel:v,activePayload:this.getTooltipContent(y,v),activeCoordinate:this.getActiveCoordinate(p,y,o)})}return null}},{key:"getTooltipContent",value:function(e,t){var n=this.state,r=n.graphicalItems,a=n.tooltipAxis,o=this.constructor.getDisplayedData(this.props,this.state);return e<0||!r||!r.length||e>=o.length?null:r.reduce(function(n,r){if(r.props.hide)return n;var i,s=r.props,u=s.dataKey,l=s.name,c=s.unit,d=s.formatter,f=s.data;return(i=a.dataKey&&!a.allowDuplicatedCategory?Q(f||o,a.dataKey,t):o[e])?Lp(n).concat([Ep({},le(r),{dataKey:u,unit:c,formatter:d,name:l||u,color:lf(r),value:sf(i,u),payload:i})]):n},[])}},{key:"getFormatItems",value:function(e,t){var n=this,r=t.graphicalItems,o=t.stackGroups,i=t.offset,s=t.updateId,l=t.dataStartIndex,c=t.dataEndIndex,d=e.barSize,f=e.layout,p=e.barGap,h=e.barCategoryGap,m=e.maxBarSize,y=this.constructor.getAxisNameByLayout(f),v=y.numericAxisName,b=y.cateAxisName,g=this.constructor.hasBar(r),A=g&&function(e){var t=e.barSize,n=e.stackGroups,r=void 0===n?{}:n;if(!r)return{};for(var a={},o=Object.keys(r),i=0,s=o.length;i=0});if(m&&m.length){var y=m[0].props.barSize,v=m[0].props[h];a[v]||(a[v]=[]),a[v].push({item:m[0],stackList:m.slice(1),barSize:D()(y)?t:y})}}return a}({barSize:d,stackGroups:o}),k=[];return r.forEach(function(r,d){var y,M,w,x,S=n.constructor.getDisplayedData(e,{dataStartIndex:l,dataEndIndex:c},r),T=r.props,O=T.dataKey,P=T.maxBarSize,L=r.props["".concat(v,"Id")],E=r.props["".concat(b,"Id")],j=u.reduce(function(e,n){var a,o=t["".concat(n.axisType,"Map")],i=r.props["".concat(n.axisType,"Id")],s=o&&o[i];return Ep({},e,(jp(a={},n.axisType,s),jp(a,"".concat(n.axisType,"Ticks"),mf(s)),a))},{}),C=j[b],Y=j["".concat(b,"Ticks")],R=o&&o[L]&&o[L].hasStack&&function(e,t){var n=e.props.stackId;if(V(n)){var r=t[n];if(r&&r.items.length){for(var a=-1,o=0,i=r.items.length;o=0?r.stackedData[a]:null}}return null}(r,o[L].stackGroups),N=Of(C,Y),_=D()(P)?m:P,I=g&&function(e){var t=e.barGap,n=e.barCategoryGap,r=e.bandSize,a=e.sizeList,o=void 0===a?[]:a,i=e.maxBarSize,s=o.length;if(s<1)return null;var u,l=G(t,r,0,!0);if(o[0].barSize===+o[0].barSize){var c=!1,d=r/s,f=o.reduce(function(e,t){return e+t.barSize||0},0);(f+=(s-1)*l)>=r&&(f-=(s-1)*l,l=0),f>=r&&d>0&&(c=!0,f=s*(d*=.9));var p={offset:((r-f)/2>>0)-l,size:0};u=o.reduce(function(e,t){var n=rf(e).concat([{item:t.item,position:{offset:p.offset+p.size+l,size:c?d:t.barSize}}]);return p=n[n.length-1].position,t.stackList&&t.stackList.length&&t.stackList.forEach(function(e){n.push({item:e,position:p})}),n},[])}else{var h=G(n,r,0,!0);r-2*h-(s-1)*l<=0&&(l=0);var m=(r-2*h-(s-1)*l)/s;m>1&&(m>>=0);var y=i===+i?Math.min(m,i):m;u=o.reduce(function(e,t,n){var r=rf(e).concat([{item:t.item,position:{offset:h+(m+l)*n+(m-y)/2,size:y}}]);return t.stackList&&t.stackList.length&&t.stackList.forEach(function(e){r.push({item:e,position:r[r.length-1].position})}),r},[])}return u}({barGap:p,barCategoryGap:h,bandSize:N,sizeList:A[E],maxBarSize:_}),H=r&&r.type&&r.type.getComposedData;H&&k.push({props:Ep({},H(Ep({},j,{displayedData:S,props:e,dataKey:O,item:r,bandSize:N,barPosition:I,offset:i,stackedData:R,layout:f,dataStartIndex:l,dataEndIndex:c,onItemMouseLeave:yf(n.handleItemMouseLeave,null,r.props.onMouseLeave),onItemMouseEnter:yf(n.handleItemMouseEnter,null,r.props.onMouseEnter)})),(y={key:r.key||"item-".concat(d)},jp(y,v,j[v]),jp(y,b,j[b]),jp(y,"animationId",s),y)),childIndex:(M=r,w=e.children,x=-1,a.Children.forEach(w,function(e,t){e===M&&(x=t)}),x),item:r})}),k}},{key:"getCursorRectangle",value:function(){var e=this.props.layout,t=this.state,n=t.activeCoordinate,r=t.offset,a=t.tooltipAxisBandSize,o=a/2;return{stroke:"none",fill:"#ccc",x:"horizontal"===e?n.x-o:r.left+.5,y:"horizontal"===e?r.top+.5:n.y-o,width:"horizontal"===e?a:r.width-1,height:"horizontal"===e?r.height-1:a}}},{key:"getCursorPoints",value:function(){var e,t,n,r,a=this.props.layout,o=this.state,i=o.activeCoordinate,s=o.offset;if("horizontal"===a)n=e=i.x,t=s.top,r=s.top+s.height;else if("vertical"===a)r=t=i.y,e=s.left,n=s.left+s.width;else if(!D()(i.cx)||!D()(i.cy)){if("centric"!==a){var u=i.cx,l=i.cy,c=i.radius,d=i.startAngle,f=i.endAngle;return{points:[If(u,l,c,d),If(u,l,c,f)],cx:u,cy:l,radius:c,startAngle:d,endAngle:f}}var p=i.cx,h=i.cy,m=i.innerRadius,y=i.outerRadius,v=i.angle,b=If(p,h,m,v),g=If(p,h,y,v);e=b.x,t=b.y,n=g.x,r=g.y}return[{x:e,y:t},{x:n,y:r}]}},{key:"calculateTooltipPos",value:function(e){var t=this.props.layout;return"horizontal"===t?e.x:"vertical"===t?e.y:"centric"===t?e.angle:e.radius}},{key:"inRange",value:function(e,t){var n=this.props.layout;if("horizontal"===n||"vertical"===n){var r=this.state.offset;return e>=r.left&&e<=r.left+r.width&&t>=r.top&&t<=r.top+r.height?{x:e,y:t}:null}var a=this.state,o=a.angleAxisMap,i=a.radiusAxisMap;if(o&&i){var s=q(o);return Wf({x:e,y:t},s)}return null}},{key:"parseEventsOfWrapper",value:function(){var e=this.props.children,t=ue(e,vn)&&"axis"===i?{onMouseEnter:this.handleMouseEnter,onMouseMove:this.handleMouseMove,onMouseLeave:this.handleMouseLeave,onTouchMove:this.handleTouchMove,onTouchStart:this.handleTouchStart,onTouchEnd:this.handleTouchEnd}:{};return Ep({},de(this.props,this.handleOuterEvent),t)}},{key:"updateStateOfAxisMapsOffsetAndStackGroups",value:function(e){var r=this,a=e.props,o=e.dataStartIndex,i=e.dataEndIndex,s=e.updateId;if(!he({props:a}))return null;var l=a.children,d=a.layout,f=a.stackOffset,p=a.data,h=a.reverseStackOrder,m=this.constructor.getAxisNameByLayout(d),y=m.numericAxisName,v=m.cateAxisName,b=se(l,n),g=function(e,t,n,r,a,o){if(!e)return null;var i=(o?t.reverse():t).reduce(function(e,t){var a=t.props,o=a.stackId;if(a.hide)return e;var i=t.props[n],s=e[i]||{hasStack:!1,stackGroups:{}};if(V(o)){var u=s.stackGroups[o]||{numericAxisId:n,cateAxisId:r,items:[]};u.items.push(t),s.hasStack=!0,s.stackGroups[o]=u}else s.stackGroups[K("_stackId_")]={numericAxisId:n,cateAxisId:r,items:[t]};return af({},e,of({},i,s))},{});return Object.keys(i).reduce(function(t,o){var s=i[o];return s.hasStack&&(s.stackGroups=Object.keys(s.stackGroups).reduce(function(t,o){var i=s.stackGroups[o];return af({},t,of({},o,{numericAxisId:n,cateAxisId:r,items:i.items,stackedData:Af(e,i.items,a)}))},{})),af({},t,of({},o,s))},{})}(p,b,"".concat(y,"Id"),"".concat(v,"Id"),f,h),A=u.reduce(function(e,t){return Ep({},e,jp({},"".concat(t.axisType,"Map"),r.getAxisMap(a,Ep({},t,{graphicalItems:b,stackGroups:t.axisType===y&&g,dataStartIndex:o,dataEndIndex:i}))))},{}),k=this.calculateOffset(Ep({},A,{props:a,graphicalItems:b}));Object.keys(A).forEach(function(e){A[e]=c(a,A[e],k,e.replace("Map",""),t)});var M=A["".concat(v,"Map")],w=this.tooltipTicksGenerator(M),x=this.getFormatItems(a,Ep({},A,{dataStartIndex:o,dataEndIndex:i,updateId:s,graphicalItems:b,stackGroups:g,offset:k}));return Ep({formatedGraphicalItems:x,graphicalItems:b,offset:k,stackGroups:g},w,A)}},{key:"addListener",value:function(){Sp.on(Dp,this.handleReceiveSyncEvent),Sp.setMaxListeners&&Sp._maxListeners&&Sp.setMaxListeners(Sp._maxListeners+1)}},{key:"removeListener",value:function(){Sp.removeListener(Dp,this.handleReceiveSyncEvent),Sp.setMaxListeners&&Sp._maxListeners&&Sp.setMaxListeners(Sp._maxListeners-1)}},{key:"calculateOffset",value:function(e){var t=e.props,n=e.graphicalItems,r=e.xAxisMap,a=void 0===r?{}:r,o=e.yAxisMap,i=void 0===o?{}:o,s=t.width,u=t.height,l=t.children,c=t.margin||{},d=ue(l,wp),f=ue(l,fa),p=Object.keys(i).reduce(function(e,t){var n=i[t],r=n.orientation;return n.mirror||n.hide?e:Ep({},e,jp({},r,e[r]+n.width))},{left:c.left||0,right:c.right||0}),h=Object.keys(a).reduce(function(e,t){var n=a[t],r=n.orientation;return n.mirror||n.hide?e:Ep({},e,jp({},r,e[r]+n.height))},{top:c.top||0,bottom:c.bottom||0}),m=Ep({},h,p),y=m.bottom;return d&&(m.bottom+=d.props.height||wp.defaultProps.height),f&&this.legendInstance&&(m=function(e,t,n,r){var a=n.children,o=n.width,i=n.height,s=n.margin,u=o-(s.left||0)-(s.right||0),l=i-(s.top||0)-(s.bottom||0),c=cf({children:a,items:t,legendWidth:u,legendHeight:l}),d=e;if(c){var f=r||{},p=c.align,h=c.verticalAlign,m=c.layout;("vertical"===m||"horizontal"===m&&"center"===h)&&z(e[p])&&(d=af({},e,of({},p,d[p]+(f.width||0)))),("horizontal"===m||"vertical"===m&&"center"===p)&&z(e[h])&&(d=af({},e,of({},h,d[h]+(f.height||0))))}return d}(m,n,t,this.legendInstance.getBBox())),Ep({brushBottom:y},m,{width:s-m.left-m.right,height:u-m.top-m.bottom})}},{key:"triggerSyncEvent",value:function(e){var t=this.props.syncId;D()(t)||Sp.emit(Dp,t,this.uniqueChartId,e)}},{key:"filterFormatItem",value:function(e,t,n){for(var r=this.state.formatedGraphicalItems,a=0,o=r.length;a=0})},p.getDisplayedData=function(e,t,n){var r=t.graphicalItems,a=t.dataStartIndex,o=t.dataEndIndex,i=(r||[]).reduce(function(e,t){var n=t.props.data;return n&&n.length?Lp(e).concat(Lp(n)):e},[]);if(i&&i.length>0)return i;if(n&&n.props&&n.props.data&&n.props.data.length>0)return n.props.data;var s=e.data;return s&&s.length&&z(a)&&z(o)?s.slice(a,o+1):[]},p};function zp(e){return(zp="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})(e)}function Vp(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Up(){return(Up=Object.assign||function(e){for(var t=1;t1e-5?"outer"===t?"start":"end":n<-1e-5?"outer"===t?"end":"start":"middle"}},{key:"renderAxisLine",value:function(){var e=this.props,t=e.cx,n=e.cy,r=e.radius,a=e.axisLine,i=e.axisLineType,s=rh({},le(this.props),{fill:"none"},le(a));if("circle"===i)return o.a.createElement(sc,nh({className:"recharts-polar-angle-axis-line"},s,{cx:t,cy:n,r:r}));var u=this.props.ticks.map(function(e){return If(t,n,r,e.coordinate)});return o.a.createElement(eh,nh({className:"recharts-polar-angle-axis-line"},s,{points:u}))}},{key:"renderTicks",value:function(){var e=this,t=this.props,n=t.ticks,r=t.tick,a=t.tickLine,i=t.tickFormatter,s=t.stroke,u=le(this.props),l=le(r),c=rh({},u,{fill:"none"},le(a)),d=n.map(function(t,n){var d=e.getTickLineCoord(t),f=rh({textAnchor:e.getTickTextAnchor(t)},u,{stroke:"none",fill:s},l,{index:n,payload:t,x:d.x2,y:d.y2});return o.a.createElement(Le,nh({className:"recharts-polar-angle-axis-tick",key:"tick-".concat(n)},pe(e.props,t,n)),a&&o.a.createElement("line",nh({className:"recharts-polar-angle-axis-tick-line"},c,d)),r&&e.constructor.renderTickItem(r,f,i?i(t.value):t.value))});return o.a.createElement(Le,{className:"recharts-polar-angle-axis-ticks"},d)}},{key:"render",value:function(){var e=this.props,t=e.ticks,n=e.radius,r=e.axisLine;return n<=0||!t||!t.length?null:o.a.createElement(Le,{className:"recharts-polar-angle-axis"},r&&this.renderAxisLine(),this.renderTicks())}}])&&oh(n.prototype,r),i&&oh(n,i),t}(),Xp.displayName="PolarAngleAxis",Xp.axisType="angleAxis",Xp.propTypes=rh({},ne,re,{type:s.a.oneOf(["number","category"]),angleAxisId:s.a.oneOfType([s.a.string,s.a.number]),dataKey:s.a.oneOfType([s.a.number,s.a.string,s.a.func]),cx:s.a.number,cy:s.a.number,radius:s.a.oneOfType([s.a.number,s.a.string]),hide:s.a.bool,scale:s.a.oneOfType([s.a.oneOf(["auto","linear","pow","sqrt","log","identity","time","band","point","ordinal","quantile","quantize","utc","sequential","threshold"]),s.a.func]),axisLine:s.a.oneOfType([s.a.bool,s.a.object]),axisLineType:s.a.oneOf(["polygon","circle"]),tickLine:s.a.oneOfType([s.a.bool,s.a.object]),tick:s.a.oneOfType([s.a.bool,s.a.func,s.a.object,s.a.element]),ticks:s.a.arrayOf(s.a.shape({value:s.a.any,coordinate:s.a.number})),stroke:s.a.string,orientation:s.a.oneOf(["inner","outer"]),tickFormatter:s.a.func,allowDuplicatedCategory:s.a.bool}),Xp.defaultProps={type:"category",angleAxisId:0,scale:"auto",cx:0,cy:0,domain:[0,"auto"],orientation:"outer",axisLine:!0,tickLine:!0,tick:!0,hide:!1,allowDuplicatedCategory:!0},Qp=Jp))||Qp,hh=n(304),mh=n.n(hh),yh=n(305),vh=n.n(yh);function bh(e){return(bh="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})(e)}function gh(){return(gh=Object.assign||function(e){for(var t=1;t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}function wh(e,t){for(var n=0;n=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var Rh={id:s.a.string,data:s.a.arrayOf(s.a.object),valueAccessor:s.a.func,clockWise:s.a.bool,dataKey:s.a.oneOfType([s.a.string,s.a.number,s.a.func])},Nh={valueAccessor:function(e){return Y()(e.value)?Ph()(e.value):e.value}};function _h(e){var t=e.data,n=e.valueAccessor,r=e.dataKey,a=e.clockWise,i=e.id,s=Yh(e,["data","valueAccessor","dataKey","clockWise","id"]);return t&&t.length?o.a.createElement(Le,{className:"recharts-label-list"},t.map(function(e,t){var u=D()(r)?n(e,t):sf(e&&e.payload,r),l=D()(i)?{}:{id:"".concat(i,"-").concat(t)};return o.a.createElement(Bc,Eh({},le(e),s,l,{index:t,value:u,viewBox:Bc.parseViewBox(D()(a)?e:jh({},e,{clockWise:a})),key:"label-".concat(t)}))})):null}_h.propTypes=Rh,_h.displayName="LabelList";_h.renderCallByParent=function(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];if(!e||!e.children&&n&&!e.label)return null;var r=e.children,i=se(r,_h).map(function(e,n){return Object(a.cloneElement)(e,{data:t,key:"labelList-".concat(n)})});return n?[function(e,t){return e?!0===e?o.a.createElement(_h,{key:"labelList-implicit",data:t}):o.a.isValidElement(e)||A()(e)?o.a.createElement(_h,{key:"labelList-implicit",data:t,content:e}):j()(e)?o.a.createElement(_h,Eh({data:t},e,{key:"labelList-implicit"})):null:null}(e.label,t)].concat(Lh(i)):i},_h.defaultProps=Nh;var Ih=_h;function Hh(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Fh(){return null}Fh.propTypes=function(e){for(var t=1;tt?"start":e0?e.paddingAngle:0;if(n){var s=Z(n.endAngle-n.startAngle,e.endAngle-e.startAngle),u=Gh({},e,{startAngle:i+o,endAngle:i+s(r)+o});a.push(u),i=u.endAngle}else{var c=e.endAngle,d=e.startAngle,f=Z(0,c-d)(r),p=Gh({},e,{startAngle:i+o,endAngle:i+f+o});a.push(p),i=p.endAngle}}),o.a.createElement(Le,null,e.renderSectorsStatically(a))})}},{key:"renderSectors",value:function(){var e=this.props,t=e.sectors,n=e.isAnimationActive,r=this.state.prevSectors;return!(n&&t&&t.length)||r&&je()(r,t)?this.renderSectorsStatically(t):this.renderSectorsWithAnimation()}},{key:"render",value:function(){var e=this.props,t=e.hide,n=e.sectors,r=e.className,a=e.label,i=e.cx,s=e.cy,u=e.innerRadius,l=e.outerRadius,c=e.isAnimationActive,d=e.prevSectors,f=e.id;if(t||!n||!n.length||!z(i)||!z(s)||!z(u)||!z(l))return null;var p=O()("recharts-pie",r);return o.a.createElement(Le,{className:p},o.a.createElement("g",{clipPath:"url(#".concat(D()(f)?this.id:f,")")},this.renderSectors()),a&&this.renderLabels(n),Bc.renderCallByParent(this.props,null,!1),(!c||d&&je()(d,n))&&Ih.renderCallByParent(this.props,n,!1))}}])&&Zh(n.prototype,r),i&&Zh(n,i),t}(),Wh.displayName="Pie",Wh.propTypes=Gh({},ne,re,{className:s.a.string,animationId:s.a.number,cx:s.a.oneOfType([s.a.number,s.a.string]),cy:s.a.oneOfType([s.a.number,s.a.string]),startAngle:s.a.number,endAngle:s.a.number,paddingAngle:s.a.number,innerRadius:s.a.oneOfType([s.a.number,s.a.string]),outerRadius:s.a.oneOfType([s.a.number,s.a.string]),cornerRadius:s.a.oneOfType([s.a.number,s.a.string]),dataKey:s.a.oneOfType([s.a.string,s.a.number,s.a.func]).isRequired,nameKey:s.a.oneOfType([s.a.string,s.a.number,s.a.func]),valueKey:s.a.oneOfType([s.a.string,s.a.number,s.a.func]),data:s.a.arrayOf(s.a.object),blendStroke:s.a.bool,minAngle:s.a.number,legendType:s.a.oneOf(oe),maxRadius:s.a.number,sectors:s.a.arrayOf(s.a.object),hide:s.a.bool,labelLine:s.a.oneOfType([s.a.object,s.a.func,s.a.element,s.a.bool]),label:s.a.oneOfType([s.a.shape({offsetRadius:s.a.number}),s.a.func,s.a.element,s.a.bool]),activeShape:s.a.oneOfType([s.a.object,s.a.func,s.a.element]),activeIndex:s.a.oneOfType([s.a.number,s.a.arrayOf(s.a.number)]),isAnimationActive:s.a.bool,animationBegin:s.a.number,animationDuration:s.a.number,animationEasing:s.a.oneOf(["ease","ease-in","ease-out","ease-in-out","spring","linear"]),id:s.a.string}),Wh.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:!me(),animationBegin:400,animationDuration:1500,animationEasing:"ease",nameKey:"name",blendStroke:!1},Wh.parseDeltaAngle=function(e){var t=e.startAngle,n=e.endAngle;return B(n-t)*Math.min(Math.abs(n-t),360)},Wh.getRealPieData=function(e){var t=e.props,n=t.data,r=t.children,a=le(e.props),o=se(r,Vh);return n&&n.length?n.map(function(e,t){return Gh({payload:e},a,e,o&&o[t]&&o[t].props)}):o&&o.length?o.map(function(e){return Gh({},a,e.props)}):[]},Wh.parseCoordinateOfPie=function(e,t){var n=t.top,r=t.left,a=t.width,o=t.height,i=Hf(a,o);return{cx:r+G(e.props.cx,a,a/2),cy:n+G(e.props.cy,o,o/2),innerRadius:G(e.props.innerRadius,i,0),outerRadius:G(e.props.outerRadius,i,.8*i),maxRadius:e.props.maxRadius||Math.sqrt(a*a+o*o)/2}},Wh.getComposedData=function(e){var t=e.item,n=e.offset,r=e.onItemMouseLeave,a=e.onItemMouseEnter,o=$h.getRealPieData(t);if(!o||!o.length)return[];var i=t.props,s=i.cornerRadius,u=i.startAngle,l=i.endAngle,c=i.paddingAngle,d=i.dataKey,f=i.nameKey,p=i.valueKey,h=Math.abs(t.props.minAngle),m=$h.parseCoordinateOfPie(t,n),y=o.length,v=$h.parseDeltaAngle({startAngle:u,endAngle:l}),b=Math.abs(v),g=b-y*h-(b>=360?y:y-1)*c,A=d;D()(d)&&D()(p)?A="value":D()(d)&&(A=p);var k,M,w=o.reduce(function(e,t){var n=sf(t,A,0);return e+(z(n)?n:0)},0);w>0&&(k=o.map(function(e,t){var n,r=sf(e,A,0),a=sf(e,f,t),o=(z(r)?r:0)/w,i=(n=t?M.endAngle+B(v)*c:u)+B(v)*(h+o*g),l=(n+i)/2,d=(m.innerRadius+m.outerRadius)/2,p=[{name:a,value:r,payload:e}],y=If(m.cx,m.cy,d,l);return M=Gh({percent:o,cornerRadius:s,name:a,tooltipPayload:p,midAngle:l,middleRadius:d,tooltipPosition:y},e,m,{value:sf(e,A),startAngle:n,endAngle:i,payload:e,paddingAngle:B(v)*c})}));return Gh({},m,{sectors:k,data:o,onMouseLeave:r,onMouseEnter:a})},Bh=zh))||Bh,em=$h,tm=Wp({chartName:"PieChart",GraphicalChild:em,eventType:"item",legendContent:"children",axisComponents:[{axisType:"angleAxis",AxisComp:ph},{axisType:"radiusAxis",AxisComp:Th}],formatAxisMap:function(e,t,n,r,a){var o=e.width,i=e.height,s=e.startAngle,u=e.endAngle,l=G(e.cx,o,o/2),c=G(e.cy,i,i/2),d=Hf(o,i,n),f=G(e.innerRadius,d,0),p=G(e.outerRadius,d,.8*d);return Object.keys(t).reduce(function(e,n){var o,i=t[n],d=i.domain,h=i.reversed;if(D()(i.range))"angleAxis"===r?o=[s,u]:"radiusAxis"===r&&(o=[f,p]),h&&(o=[o[1],o[0]]);else{var m=jf(o=i.range,2);s=m[0],u=m[1]}var y=vf(i,a),v=y.realScaleType,b=y.scale;b.domain(d).range(o),bf(b);var g=kf(b,Lf({},i,{realScaleType:v})),A=Lf({},i,g,{range:o,radius:p,realScaleType:v,scale:b,cx:l,cy:c,innerRadius:f,outerRadius:p,startAngle:s,endAngle:u});return Lf({},e,Ef({},n,A))},{})},defaultProps:{layout:"centric",startAngle:0,endAngle:360,cx:"50%",cy:"50%",innerRadius:0,outerRadius:"80%"},propTypes:{layout:s.a.oneOf(["centric"]),startAngle:s.a.number,endAngle:s.a.number,cx:s.a.oneOfType([s.a.number,s.a.string]),cy:s.a.oneOfType([s.a.number,s.a.string]),innerRadius:s.a.oneOfType([s.a.number,s.a.string]),outerRadius:s.a.oneOfType([s.a.number,s.a.string])}}),nm=n(35);function rm(e,t,n,r,a){if(e>=t)return Promise.resolve({patternGraphData:[],calendarGraphData:[]});var o=[],i=function(i){if(!r[i].enabled)return"continue";var s=n.filter(function(e){return e.cal.regex.test(r[i].name)});s.length>0&&o.push(a(i,e,t).then(function(e){return{id:i,events:e,filtered:s}}))};for(var s in r)i(s);return Promise.all(o).then(function(a){var o={},i={},s={},u={};a.forEach(function(e){o[e.id]=e.events,i[e.id]=e.filtered});for(var l=0;lt+2&&(l=5,u="start"),an+2&&(c=10),o.a.createElement("text",{x:r,y:a,dx:l,dy:c,fill:i,textAnchor:u},"".concat(s))}var im=Object(u.withStyles)(am)(function(e){return o.a.createElement(c.a,{item:!0,xs:12,lg:6},o.a.createElement("div",{className:e.classes.patternTableWrapper},o.a.createElement(tm,{width:400,height:250,className:e.classes.pieChart},o.a.createElement(em,{data:e.data,dataKey:"value",cx:200,cy:125,outerRadius:60,fill:nm.a,isAnimationActive:!1,label:om},e.data.map(function(e,t){return o.a.createElement(Vh,{key:t,fill:e.color?e.color:nm.a})})),o.a.createElement(vn,{formatter:function(e){return"".concat(e.toFixed(2)," hr")}}))))});function sm(e){return o.a.createElement(c.a,{container:!0,spacing:0},o.a.createElement(im,{data:e.patternGraphData}),o.a.createElement(c.a,{item:!0,xs:12,lg:6},o.a.createElement("div",{className:e.classes.patternTableWrapper},o.a.createElement(tm,{width:400,height:250,className:e.classes.pieChart},o.a.createElement(em,{data:e.calendarGraphData,dataKey:"value",cx:200,cy:125,innerRadius:40,outerRadius:70,fill:f.a[300],isAnimationActive:!1,label:om},e.calendarGraphData.map(function(e,t){return o.a.createElement(Vh,{key:t,fill:e.color?e.color:f.a[300]})})),o.a.createElement(vn,{formatter:function(e){return"".concat(e.toFixed(2)," hr")}})))))}sm.propTypes={patternGraphData:s.a.array.isRequired,calendarGraphData:s.a.array.isRequired};var um=Object(u.withStyles)(am)(sm)},function(e,t,n){"use strict"; +!function(){"use strict";var n={}.hasOwnProperty;function a(){for(var e=[],t=0;t=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}},function(e,t){e.exports=function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}},function(e,t){e.exports=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}},function(e,t){function n(e,t){for(var n=0;n1&&void 0!==arguments[1]?arguments[1]:{};return function(n){var r,m=t.withTheme,y=void 0!==m&&m,b=t.flip,k=void 0===b?null:b,w=t.name,j=(0,d.default)(t,["withTheme","flip","name"]),C=(0,x.default)(e),Y=C.themingEnabled||"string"==typeof w||y;O+=1,C.options.index=O;var R=function(e){function t(e,n){var r;(0,i.default)(this,t),(r=(0,u.default)(this,(0,l.default)(t).call(this,e,n))).jss=n[v.default.jss]||D,r.sheetsManager=P,r.unsubscribeId=null;var a=n.muiThemeProviderOptions;return a&&(a.sheetsManager&&(r.sheetsManager=a.sheetsManager),r.sheetsCache=a.sheetsCache,r.disableStylesGeneration=a.disableStylesGeneration),r.stylesCreatorSaved=C,r.sheetOptions=(0,o.default)({generateClassName:T},n[v.default.sheetOptions]),r.theme=Y?M.default.initial(n)||E:L,r.attach(r.theme),r.cacheClasses={value:null,lastProp:null,lastJSS:{}},r}return(0,c.default)(t,e),(0,s.default)(t,[{key:"componentDidMount",value:function(){var e=this;Y&&(this.unsubscribeId=M.default.subscribe(this.context,function(t){var n=e.theme;e.theme=t,e.attach(e.theme),e.setState({},function(){e.detach(n)})}))}},{key:"componentDidUpdate",value:function(){this.stylesCreatorSaved}},{key:"componentWillUnmount",value:function(){this.detach(this.theme),null!==this.unsubscribeId&&M.default.unsubscribe(this.context,this.unsubscribeId)}},{key:"getClasses",value:function(){if(this.disableStylesGeneration)return this.props.classes||{};var e=!1,t=A.default.get(this.sheetsManager,this.stylesCreatorSaved,this.theme);return t.sheet.classes!==this.cacheClasses.lastJSS&&(this.cacheClasses.lastJSS=t.sheet.classes,e=!0),this.props.classes!==this.cacheClasses.lastProp&&(this.cacheClasses.lastProp=this.props.classes,e=!0),e&&(this.cacheClasses.value=(0,g.default)({baseClasses:this.cacheClasses.lastJSS,newClasses:this.props.classes,Component:n})),this.cacheClasses.value}},{key:"attach",value:function(e){if(!this.disableStylesGeneration){var t=this.stylesCreatorSaved,n=A.default.get(this.sheetsManager,t,e);if(n||(n={refs:0,sheet:null},A.default.set(this.sheetsManager,t,e,n)),0===n.refs){var r;this.sheetsCache&&(r=A.default.get(this.sheetsCache,t,e)),r||((r=this.createSheet(e)).attach(),this.sheetsCache&&A.default.set(this.sheetsCache,t,e,r)),n.sheet=r;var a=this.context[v.default.sheetsRegistry];a&&a.add(r)}n.refs+=1}}},{key:"createSheet",value:function(e){var t=this.stylesCreatorSaved.create(e,w),r=w;return this.jss.createStyleSheet(t,(0,o.default)({meta:r,classNamePrefix:r,flip:"boolean"==typeof k?k:"rtl"===e.direction,link:!1},this.sheetOptions,this.stylesCreatorSaved.options,{name:w||n.displayName},j))}},{key:"detach",value:function(e){if(!this.disableStylesGeneration){var t=A.default.get(this.sheetsManager,this.stylesCreatorSaved,e);if(t.refs-=1,0===t.refs){A.default.delete(this.sheetsManager,this.stylesCreatorSaved,e),this.jss.removeStyleSheet(t.sheet);var n=this.context[v.default.sheetsRegistry];n&&n.remove(t.sheet)}}}},{key:"render",value:function(){var e=this.props,t=(e.classes,e.innerRef),r=(0,d.default)(e,["classes","innerRef"]),a=(0,S.default)({theme:this.theme,name:w,props:r});return y&&!a.theme&&(a.theme=this.theme),f.default.createElement(n,(0,o.default)({},a,{classes:this.getClasses(),ref:t}))}}]),t}(f.default.Component);return R.contextTypes=(0,o.default)((r={muiThemeProviderOptions:p.default.object},(0,a.default)(r,v.default.jss,p.default.object),(0,a.default)(r,v.default.sheetOptions,p.default.object),(0,a.default)(r,v.default.sheetsRegistry,p.default.object),r),Y?M.default.contextTypes:{}),(0,h.default)(R,n),R}});t.default=function(e,t){return m.ponyfillGlobal.__MUI_STYLES__.withStyles(e,(0,o.default)({defaultTheme:E},t))}},function(e,t,n){var r=n(55),a=n(11);e.exports=function(e,t){return!t||"object"!==r(t)&&"function"!=typeof t?a(e):t}},function(e,t){function n(t){return e.exports=n=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},n(t)}e.exports=n},function(e,t,n){var r=n(343);e.exports=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}}),t&&r(e,t)}},function(e,t,n){"use strict";var r=function(){};e.exports=r},function(e,t){e.exports=function(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}},function(e,t,n){"use strict";var r=n(3);Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"createGenerateClassName",{enumerable:!0,get:function(){return a.default}}),Object.defineProperty(t,"createMuiTheme",{enumerable:!0,get:function(){return o.default}}),Object.defineProperty(t,"jssPreset",{enumerable:!0,get:function(){return i.default}}),Object.defineProperty(t,"MuiThemeProvider",{enumerable:!0,get:function(){return s.default}}),Object.defineProperty(t,"createStyles",{enumerable:!0,get:function(){return u.default}}),Object.defineProperty(t,"withStyles",{enumerable:!0,get:function(){return l.default}}),Object.defineProperty(t,"withTheme",{enumerable:!0,get:function(){return c.default}});var a=r(n(118)),o=r(n(87)),i=r(n(126)),s=r(n(394)),u=r(n(397)),l=r(n(15)),c=r(n(113))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.MODIFIER_KEY_NAMES=t.DEFAULT_VERTICAL_SPACING=t.FANG_HEIGHT_PX=t.FANG_WIDTH_PX=t.WEEKDAYS=t.BLOCKED_MODIFIER=t.DAY_SIZE=t.OPEN_UP=t.OPEN_DOWN=t.ANCHOR_RIGHT=t.ANCHOR_LEFT=t.INFO_POSITION_AFTER=t.INFO_POSITION_BEFORE=t.INFO_POSITION_BOTTOM=t.INFO_POSITION_TOP=t.ICON_AFTER_POSITION=t.ICON_BEFORE_POSITION=t.VERTICAL_SCROLLABLE=t.VERTICAL_ORIENTATION=t.HORIZONTAL_ORIENTATION=t.END_DATE=t.START_DATE=t.ISO_MONTH_FORMAT=t.ISO_FORMAT=t.DISPLAY_FORMAT=void 0;t.DISPLAY_FORMAT="L";t.ISO_FORMAT="YYYY-MM-DD";t.ISO_MONTH_FORMAT="YYYY-MM";t.START_DATE="startDate";t.END_DATE="endDate";t.HORIZONTAL_ORIENTATION="horizontal";t.VERTICAL_ORIENTATION="vertical";t.VERTICAL_SCROLLABLE="verticalScrollable";t.ICON_BEFORE_POSITION="before";t.ICON_AFTER_POSITION="after";t.INFO_POSITION_TOP="top";t.INFO_POSITION_BOTTOM="bottom";t.INFO_POSITION_BEFORE="before";t.INFO_POSITION_AFTER="after";t.ANCHOR_LEFT="left";t.ANCHOR_RIGHT="right";t.OPEN_DOWN="down";t.OPEN_UP="up";t.DAY_SIZE=39;t.BLOCKED_MODIFIER="blocked";t.WEEKDAYS=[0,1,2,3,4,5,6];t.FANG_WIDTH_PX=20;t.FANG_HEIGHT_PX=10;t.DEFAULT_VERTICAL_SPACING=22;var r=new Set(["Shift","Control","Alt","Meta"]);t.MODIFIER_KEY_NAMES=r},function(e,t,n){var r=n(261),a="object"==typeof self&&self&&self.Object===Object&&self,o=r||a||Function("return this")();e.exports=o},function(e,t,n){var r=n(432),a=n(478),o=n(43),i=n(8),s=n(487);e.exports=function(e){return"function"==typeof e?e:null==e?o:"object"==typeof e?i(e)?a(e[0],e[1]):r(e):s(e)}},function(e,t,n){"use strict";!function e(){if("undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE)try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(e){console.error(e)}}(),e.exports=n(340)},function(e,t,n){var r=n(100);e.exports=function(e,t){return r(e,t)}},function(e,t,n){"use strict";n.d(t,"c",function(){return v}),n.d(t,"a",function(){return g}),n.d(t,"b",function(){return A});var r=n(12),a=n.n(r),o=n(13),i=n.n(o),s=n(7),u=n.n(s),l="updatePatterns",c="getPatterns",d="updateCalendars",f="getCalendars",p="getCalEvents",h="updateConfig",m="getConfig",y="getGraphData",v=Object.freeze({updatePatterns:Symbol(l),getPatterns:Symbol(c),updateCalendars:Symbol(d),getCalendars:Symbol(f),getCalEvents:Symbol(p),updateConfig:Symbol(h),getConfig:Symbol(m),getGraphData:Symbol(y)});function b(e){switch(e){case v.updatePatterns:return l;case v.getPatterns:return c;case v.updateCalendars:return d;case v.getCalendars:return f;case v.getCalEvents:return p;case v.updateConfig:return h;case v.getConfig:return m;case v.getGraphData:return y;default:console.error("unreachable")}}var g=function(){function e(t,n,r){a()(this,e),this.id=t,this.type=n,this.data=r}return i()(e,[{key:"genResp",value:function(t){return new e(this.id,this.type,t)}},{key:"deflate",value:function(){return{id:this.id,type:b(this.type),data:this.data}}}]),e}();u()(g,"inflate",function(e){return new g(e.id,function(e){switch(e){case l:return v.updatePatterns;case c:return v.getPatterns;case d:return v.updateCalendars;case f:return v.getCalendars;case p:return v.getCalEvents;case h:return v.updateConfig;case m:return v.getConfig;case y:return v.getGraphData;default:console.error("unreachable")}}(e.type),e.data)});var A=function e(t){var n=this;a()(this,e),u()(this,"sendMsg",function(e){var t,r,a=e.type,o=e.data,i=n.requestCallback,s=new Promise(function(e){t=e});return r=i.ids.length>0?i.ids.pop():i.maxId++,i.inFlight[r]=t,n.port.postMessage(new g(r,a,o).deflate()),s});var r=chrome.runtime.connect({name:t});r.onMessage.addListener(function(e){console.log(e);var t=(e.type,n.requestCallback),r=t.inFlight[e.id];console.assert(void 0!==r),t.ids.push(e.id),r(e)}),this.port=r,this.requestCallback={inFlight:{},ids:[],maxId:0}}},function(e,t){e.exports=function(e){return null!=e&&"object"==typeof e}},function(e,t,n){var r=n(30),a=n(8),o=n(28),i="[object String]";e.exports=function(e){return"string"==typeof e||!a(e)&&o(e)&&r(e)==i}},function(e,t,n){var r=n(53),a=n(413),o=n(414),i="[object Null]",s="[object Undefined]",u=r?r.toStringTag:void 0;e.exports=function(e){return null==e?void 0===e?s:i:u&&u in Object(e)?a(e):o(e)}},function(e,t,n){(function(t){for(var r=n(519),a="undefined"==typeof window?t:window,o=["moz","webkit"],i="AnimationFrame",s=a["request"+i],u=a["cancel"+i]||a["cancelRequest"+i],l=0;!s&&l-1?e[n]:void 0},t.createChainedFunction=function(){for(var e=arguments.length,t=new Array(e),n=0;n1&&void 0!==arguments[1]&&arguments[1];if(!Array.isArray(e))return e;var n="";if(Array.isArray(e[0]))for(var a=0;a0&&void 0!==arguments[0]?arguments[0]:"unnamed",t=arguments[1],n=arguments[2],i=n.jss,s=(0,o.default)(t),u=i.plugins.onCreateRule(e,s,n);if(u)return u;"@"===e[0]&&(0,r.default)(!1,"[JSS] Unknown at-rule %s",e);return new a.default(e,s,n)};var r=i(n(39)),a=i(n(40)),o=i(n(365));function i(e){return e&&e.__esModule?e:{default:e}}},function(e,t,n){"use strict";n.r(t),n.d(t,"isBrowser",function(){return a});var r="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},a="object"===("undefined"==typeof window?"undefined":r(window))&&"object"===("undefined"==typeof document?"undefined":r(document))&&9===document.nodeType;t.default=a},function(e,t,n){var r=n(263),a=n(431)(r);e.exports=a},function(e,t,n){var r=n(422),a=n(428),o=n(42);e.exports=function(e){return o(e)?r(e):a(e)}},function(e,t,n){var r=n(434),a=n(435),o=n(436),i=n(437),s=n(438);function u(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t1&&i(e,t[0],t[1])?t=[]:n>2&&i(t[0],t[1],t[2])&&(t=[t[0]]),a(e,r(t,1),[])});e.exports=s},function(e,t,n){"use strict";var r=s(n(530)),a=s(n(534)),o=s(n(107)),i=s(n(80));function s(e){return e&&e.__esModule?e:{default:e}}e.exports={Transition:i.default,TransitionGroup:o.default,ReplaceTransition:a.default,CSSTransition:r.default}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r={50:"#fff3e0",100:"#ffe0b2",200:"#ffcc80",300:"#ffb74d",400:"#ffa726",500:"#ff9800",600:"#fb8c00",700:"#f57c00",800:"#ef6c00",900:"#e65100",A100:"#ffd180",A200:"#ffab40",A400:"#ff9100",A700:"#ff6d00"};t.default=r},function(e,t,n){var r,a=n(511),o=n(512),i=n(514),s=100,u=/(\+|\-|\*|\\|[^a-z]|)(\s*)(\()/g;e.exports=function(e,t){function n(e,o,l){if(r++>s)throw r=0,new Error("Call stack overflow for "+l);if(""===e)throw new Error(o+"(): '"+l+"' must contain a non-whitespace string");var c=function(e){var t=[],n=[],r=/[\.0-9]([%a-z]+)/gi,a=r.exec(e);for(;a;)a&&a[1]&&(-1===n.indexOf(a[1].toLowerCase())&&(t.push(a[1]),n.push(a[1].toLowerCase())),a=r.exec(e));return t}(e=function(e,t){e=e.replace(/((?:\-[a-z]+\-)?calc)/g,"");var r,o="",i=e;for(;r=u.exec(i);){r[0].index>0&&(o+=i.substring(0,r[0].index));var s=a("(",")",i.substring([0].index));if(""===s.body)throw new Error("'"+e+"' must contain a non-whitespace string");var l=n(s.body,"",t);o+=s.pre+l,i=s.post}return o+i}(e,l));if(c.length>1||e.indexOf("var(")>-1)return o+"("+e+")";var d=c[0]||"";"%"===d&&(e=e.replace(/\b[0-9\.]+%/g,function(e){return.01*parseFloat(e.slice(0,-1))}));var f,p=e.replace(new RegExp(d,"gi"),"");try{f=i.eval(p)}catch(t){return o+"("+e+")"}return"%"===d&&(f*=100),(o.length||"%"===d)&&(f=Math.round(f*t)/t),f+=d}return r=0,t=Math.pow(10,void 0===t?5:t),e=e.replace(/\n+/g," "),o(e,/((?:\-[a-z]+\-)?calc)\(/,n)}},function(e,t,n){"use strict";var r=n(548);e.exports=function(e,t,n){return!r(e.props,t)||!r(e.state,n)}},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.withStylesPropTypes=t.css=void 0;var r=Object.assign||function(e){for(var t=1;t1&&void 0!==arguments[1]?arguments[1]:{},n=t.stylesPropName,i=void 0===n?"styles":n,c=t.themePropName,f=void 0===c?"theme":c,h=t.cssPropName,b=void 0===h?"css":h,g=t.flushBefore,A=void 0!==g&&g,k=t.pureComponent,M=void 0!==k&&k,w=void 0,x=void 0,S=void 0,D=void 0,T=function(e){if(e){if(!o.default.PureComponent)throw new ReferenceError("withStyles() pureComponent option requires React 15.3.0 or later");return o.default.PureComponent}return o.default.Component}(M);function O(e){return e===l.DIRECTIONS.LTR?d.default.resolveLTR:d.default.resolveRTL}function P(t,n){var r=function(e){return e===l.DIRECTIONS.LTR?S:D}(t),a=t===l.DIRECTIONS.LTR?w:x,o=d.default.get();if(a&&r===o)return a;var i=t===l.DIRECTIONS.RTL;return i?(x=e?d.default.createRTL(e):m,D=o,a=x):(w=e?d.default.createLTR(e):m,S=o,a=w),a}function L(e,t){return{resolveMethod:O(e),styleDef:P(e,t)}}return function(){return function(e){var t=e.displayName||e.name||"Component",n=function(n){function s(e,n){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,s);var r=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(s.__proto__||Object.getPrototypeOf(s)).call(this,e,n)),a=r.context[l.CHANNEL]?r.context[l.CHANNEL].getState():v;return r.state=L(a,t),r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(s,n),a(s,[{key:"componentDidMount",value:function(){return function(){var e=this;this.context[l.CHANNEL]&&(this.channelUnsubscribe=this.context[l.CHANNEL].subscribe(function(n){e.setState(L(n,t))}))}}()},{key:"componentWillUnmount",value:function(){return function(){this.channelUnsubscribe&&this.channelUnsubscribe()}}()},{key:"render",value:function(){return function(){var t;A&&d.default.flush();var n=this.state,a=n.resolveMethod,s=n.styleDef;return o.default.createElement(e,r({},this.props,(p(t={},f,d.default.get()),p(t,i,s()),p(t,b,a),t)))}}()}]),s}(T);n.WrappedComponent=e,n.displayName="withStyles("+String(t)+")",n.contextTypes=y,e.propTypes&&(n.propTypes=(0,u.default)({},e.propTypes),delete n.propTypes[i],delete n.propTypes[f],delete n.propTypes[b]);e.defaultProps&&(n.defaultProps=(0,u.default)({},e.defaultProps));return(0,s.default)(n,e)}}()};var o=f(n(1)),i=f(n(0)),s=f(n(774)),u=f(n(775)),l=n(776),c=f(n(777)),d=f(n(638));function f(e){return e&&e.__esModule?e:{default:e}}function p(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}t.css=d.default.resolveLTR,t.withStylesPropTypes={styles:i.default.object.isRequired,theme:i.default.object.isRequired,css:i.default.func.isRequired};var h={},m=function(){return h};var y=p({},l.CHANNEL,c.default),v=l.DIRECTIONS.LTR},function(e,t,n){"use strict";t.__esModule=!0,t.default=t.EXITING=t.ENTERED=t.ENTERING=t.EXITED=t.UNMOUNTED=void 0;var r=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){var r=Object.defineProperty&&Object.getOwnPropertyDescriptor?Object.getOwnPropertyDescriptor(e,n):{};r.get||r.set?Object.defineProperty(t,n,r):t[n]=e[n]}return t.default=e,t}(n(0)),a=s(n(1)),o=s(n(25)),i=n(289);n(290);function s(e){return e&&e.__esModule?e:{default:e}}var u="unmounted";t.UNMOUNTED=u;var l="exited";t.EXITED=l;var c="entering";t.ENTERING=c;var d="entered";t.ENTERED=d;t.EXITING="exiting";var f=function(e){var t,n;function r(t,n){var r;r=e.call(this,t,n)||this;var a,o=n.transitionGroup,i=o&&!o.isMounting?t.enter:t.appear;return r.appearStatus=null,t.in?i?(a=l,r.appearStatus=c):a=d:a=t.unmountOnExit||t.mountOnEnter?u:l,r.state={status:a},r.nextCallback=null,r}n=e,(t=r).prototype=Object.create(n.prototype),t.prototype.constructor=t,t.__proto__=n;var i=r.prototype;return i.getChildContext=function(){return{transitionGroup:null}},r.getDerivedStateFromProps=function(e,t){return e.in&&t.status===u?{status:l}:null},i.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},i.componentDidUpdate=function(e){var t=null;if(e!==this.props){var n=this.state.status;this.props.in?n!==c&&n!==d&&(t=c):n!==c&&n!==d||(t="exiting")}this.updateStatus(!1,t)},i.componentWillUnmount=function(){this.cancelNextCallback()},i.getTimeouts=function(){var e,t,n,r=this.props.timeout;return e=t=n=r,null!=r&&"number"!=typeof r&&(e=r.exit,t=r.enter,n=r.appear),{exit:e,enter:t,appear:n}},i.updateStatus=function(e,t){if(void 0===e&&(e=!1),null!==t){this.cancelNextCallback();var n=o.default.findDOMNode(this);t===c?this.performEnter(n,e):this.performExit(n)}else this.props.unmountOnExit&&this.state.status===l&&this.setState({status:u})},i.performEnter=function(e,t){var n=this,r=this.props.enter,a=this.context.transitionGroup?this.context.transitionGroup.isMounting:t,o=this.getTimeouts();t||r?(this.props.onEnter(e,a),this.safeSetState({status:c},function(){n.props.onEntering(e,a),n.onTransitionEnd(e,o.enter,function(){n.safeSetState({status:d},function(){n.props.onEntered(e,a)})})})):this.safeSetState({status:d},function(){n.props.onEntered(e)})},i.performExit=function(e){var t=this,n=this.props.exit,r=this.getTimeouts();n?(this.props.onExit(e),this.safeSetState({status:"exiting"},function(){t.props.onExiting(e),t.onTransitionEnd(e,r.exit,function(){t.safeSetState({status:l},function(){t.props.onExited(e)})})})):this.safeSetState({status:l},function(){t.props.onExited(e)})},i.cancelNextCallback=function(){null!==this.nextCallback&&(this.nextCallback.cancel(),this.nextCallback=null)},i.safeSetState=function(e,t){t=this.setNextCallback(t),this.setState(e,t)},i.setNextCallback=function(e){var t=this,n=!0;return this.nextCallback=function(r){n&&(n=!1,t.nextCallback=null,e(r))},this.nextCallback.cancel=function(){n=!1},this.nextCallback},i.onTransitionEnd=function(e,t,n){this.setNextCallback(n),e?(this.props.addEndListener&&this.props.addEndListener(e,this.nextCallback),null!=t&&setTimeout(this.nextCallback,t)):setTimeout(this.nextCallback,0)},i.render=function(){var e=this.state.status;if(e===u)return null;var t=this.props,n=t.children,r=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r=0||(a[n]=e[n]);return a}(t,["children"]);if(delete r.in,delete r.mountOnEnter,delete r.unmountOnExit,delete r.appear,delete r.enter,delete r.exit,delete r.timeout,delete r.addEndListener,delete r.onEnter,delete r.onEntering,delete r.onEntered,delete r.onExit,delete r.onExiting,delete r.onExited,"function"==typeof n)return n(e,r);var o=a.default.Children.only(n);return a.default.cloneElement(o,r)},r}(a.default.Component);function p(){}f.contextTypes={transitionGroup:r.object},f.childContextTypes={transitionGroup:function(){}},f.propTypes={},f.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:p,onEntering:p,onEntered:p,onExit:p,onExiting:p,onExited:p},f.UNMOUNTED=0,f.EXITED=1,f.ENTERING=2,f.ENTERED=3,f.EXITING=4;var h=(0,i.polyfill)(f);t.default=h},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r={50:"#e0f7fa",100:"#b2ebf2",200:"#80deea",300:"#4dd0e1",400:"#26c6da",500:"#00bcd4",600:"#00acc1",700:"#0097a7",800:"#00838f",900:"#006064",A100:"#84ffff",A200:"#18ffff",A400:"#00e5ff",A700:"#00b8d4"};t.default=r},function(e,t,n){"use strict";e.exports=function(e,t,n,r,a,o,i,s){if(!e){var u;if(void 0===t)u=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var l=[n,r,a,o,i,s],c=0;(u=new Error(t.replace(/%s/g,function(){return l[c++]}))).name="Invariant Violation"}throw u.framesToPop=1,u}}},function(e,t,n){"use strict";n.d(t,"e",function(){return b}),n.d(t,"b",function(){return g}),n.d(t,"f",function(){return A}),n.d(t,"g",function(){return k}),n.d(t,"c",function(){return M}),n.d(t,"d",function(){return w}),n.d(t,"a",function(){return S});var r=n(12),a=n.n(r),o=n(13),i=n.n(o),s=n(49),u=n.n(s),l=n(105),c=n.n(l),d=n(543),f=n.n(d),p="https://www.googleapis.com/calendar/v3",h=Object.freeze({invalidSyncToken:Symbol("invalidSyncToken"),notLoggedIn:Symbol("notLoggedIn"),notLoggedOut:Symbol("notLoggedOut"),otherError:Symbol("otherError")});function m(e){return Object.entries(e).filter(function(e){var t=c()(e,2);t[0];return t[1]}).map(function(e){var t=c()(e,2),n=t[0],r=t[1];return"".concat(encodeURIComponent(n),"=").concat(encodeURIComponent(r))}).join("&")}var y=null;function v(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];return new Promise(function(t){return chrome.identity.getAuthToken({interactive:e},function(e){return t([e,!chrome.runtime.lastError])})}).then(function(e){var t=c()(e,2),n=t[0];if(t[1])return n;throw h.notLoggedIn})}function b(){return null===y?v(!1).then(function(){return y=!0}).catch(function(){return y=!1}).then(function(){return y}):Promise.resolve(y)}function g(){return b().then(function(e){if(e)return v(!1);throw h.notLoggedIn})}function A(){return b().then(function(e){if(e)throw h.notLoggedOut;return v(!0).then(function(){return y=!0})})}function k(){return g().then(function(e){return fetch("https://accounts.google.com/o/oauth2/revoke?".concat(m({token:e})),{method:"GET",async:!0}).then(function(t){return function(e){return new Promise(function(t){return chrome.identity.removeCachedAuthToken({token:e},function(){return t()})})}(e)})}).then(function(){return y=!1})}function M(e){return fetch("".concat(p,"/users/me/calendarList?").concat(m({access_token:e})),{method:"GET",async:!0}).then(function(e){return e.json()}).then(function(e){return e.items})}function w(e){return fetch("".concat(p,"/colors?").concat(m({access_token:e})),{method:"GET",async:!0}).then(function(e){return e.json()})}function x(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null,o=arguments.length>5&&void 0!==arguments[5]?arguments[5]:100,i=[];return function n(s,l){return fetch("".concat(p,"/calendars/").concat(e,"/events?").concat(m({access_token:t,pageToken:s,syncToken:l,timeMin:r,timeMax:a,maxResults:o})),{method:"GET",async:!0}).then(function(e){if(200===e.status)return e.json();throw 410===e.status?h.invalidSyncToken:h.otherError}).then(function(e){return i.push.apply(i,u()(e.items)),e.nextPageToken?n(e.nextPageToken,""):{nextSyncToken:e.nextSyncToken,results:i}})}("",n)}var S=function(){function e(t,n){var r=this,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{maxCachedItems:100,nDaysPerSlot:10,largeQuery:10};a()(this,e),this.calId=t,this.name=n,this.syncToken="",this.cache=new f.a({max:o.maxCachedItems,dispose:function(e,t){return r.onRemoveSlot(e,t)}}),this.eventMeta={},this.options=o,this.divider=864e5*this.options.nDaysPerSlot}return i()(e,[{key:"dateToCacheKey",value:function(e){return Math.floor(e/this.divider)}},{key:"dateRangeToCacheKeys",value:function(e){return{start:this.dateToCacheKey(e.start),end:this.dateToCacheKey(new Date(e.end.getTime()-1))}}},{key:"getSlot",value:function(e){if(this.cache.has(e))return this.cache.get(e);var t={};return this.cache.set(e,t),t}},{key:"onRemoveSlot",value:function(e,t){for(var n in t){console.assert(this.eventMeta[n]);var r=this.eventMeta[n].keys;r.delete(e),0===r.size&&delete this.eventMeta[n]}}},{key:"slotStartDate",value:function(e){return new Date(e*this.divider)}},{key:"slotEndDate",value:function(e){return new Date((e+1)*this.divider)}},{key:"addEvent",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];this.eventMeta.hasOwnProperty(e.id)&&this.removeEvent(e);for(var n=this.dateRangeToCacheKeys(e),r=n.start,a=n.end,o=this.cache.length,i=new Set,s=r;s<=a;s++)i.add(s),this.cache.has(s)||o++;if(this.eventMeta[e.id]={keys:i,summary:e.summary},t||!(o>this.options.maxCachedItems))if(r===a)this.getSlot(r)[e.id]={start:e.start,end:e.end,id:e.id};else{this.getSlot(r)[e.id]={start:e.start,end:this.slotEndDate(r),id:e.id},this.getSlot(a)[e.id]={start:this.slotStartDate(a),end:e.end,id:e.id};for(var u=r+1;u=n||r[o].end<=t||a.push({id:o,start:r[o].startn?n:r[o].end,summary:this.eventMeta[o].summary});return a}},{key:"getCachedEvents",value:function(e){for(var t=this.dateRangeToCacheKeys(e),n=t.start,r=t.end,a=this.getSlotEvents(n,e.start,e.end),o=n+1;on&&a.push.apply(a,u()(this.getSlotEvents(r,e.start,e.end))),a}},{key:"sync",value:function(){var e=this;return this.token.then(function(t){return x(e.calId,t,e.syncToken).then(function(n){var r=n.results.map(function(n){return n.start?Promise.resolve(n):function(e,t,n){return fetch("".concat(p,"/calendars/").concat(e,"/events/").concat(t,"?").concat(m({access_token:n})),{method:"GET",async:!0}).then(function(e){return e.json()})}(e.calId,n.id,t)});return Promise.all(r).then(function(t){t.forEach(function(t){t.start=new Date(t.start.dateTime),t.end=new Date(t.end.dateTime),"confirmed"===t.status?e.addEvent(t):"cancelled"===t.status&&e.removeEvent(t)}),e.syncToken=n.nextSyncToken})})}).catch(function(t){if(t!==h.invalidSyncToken)throw t;e.syncToken="",e.sync()})}},{key:"getEvents",value:function(e,t){for(var n=this,r=this.dateRangeToCacheKeys({start:e,end:t}),a={},o=r.start;o<=r.end;o++)this.cache.has(o)||(a.hasOwnProperty("start")||(a.start=o),a.end=o);return a.hasOwnProperty("start")?(console.assert(a.start<=a.end),a.end-a.start+1>this.options.largeQuery?(console.log("encounter large query, use direct fetch"),this.token.then(function(r){return x(n.calId,r,null,e.toISOString(),t.toISOString()).then(function(n){var r=[];return n.results.forEach(function(e){console.assert(e.start),e.start=new Date(e.start.dateTime),e.end=new Date(e.end.dateTime),r.push(e)}),r.filter(function(n){return!(n.start>=t||n.end<=e)}).map(function(n){return{id:n.id,start:n.startt?t:n.end,summary:n.summary}})})})):(console.log("fetching short event list"),this.token.then(function(e){return x(n.calId,e,null,n.slotStartDate(a.start).toISOString(),n.slotEndDate(a.end).toISOString()).then(function(e){e.results.forEach(function(e){"confirmed"===e.status&&(console.assert(e.start),e.start=new Date(e.start.dateTime),e.end=new Date(e.end.dateTime),n.addEvent(e,!0))}),""===n.syncToken&&(n.syncToken=e.nextSyncToken)})}).then(function(){return n.sync()}).then(function(){return n.getCachedEvents({start:e,end:t})}))):(console.log("cache hit"),this.sync().then(function(){return n.getCachedEvents({start:e,end:t})}))}},{key:"token",get:function(){return g()}}]),e}()},function(e,t,n){"use strict";var r=n(3);Object.defineProperty(t,"__esModule",{value:!0}),t.convertHexToRGB=o,t.rgbToHex=function(e){if(0===e.indexOf("#"))return e;var t=i(e).values;return t=t.map(function(e){return 1===(t=e.toString(16)).length?"0".concat(t):t;var t}),"#".concat(t.join(""))},t.decomposeColor=i,t.recomposeColor=s,t.getContrastRatio=function(e,t){var n=u(e),r=u(t);return(Math.max(n,r)+.05)/(Math.min(n,r)+.05)},t.getLuminance=u,t.emphasize=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:.15;return u(e)>.5?l(e,t):c(e,t)},t.fade=function(e,t){if(!e)return e;e=i(e),t=a(t),("rgb"===e.type||"hsl"===e.type)&&(e.type+="a");return e.values[3]=t,s(e)},t.darken=l,t.lighten=c;r(n(19));function a(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;return en?n:e}function o(e){e=e.substr(1);var t=new RegExp(".{1,".concat(e.length/3,"}"),"g"),n=e.match(t);return n&&1===n[0].length&&(n=n.map(function(e){return e+e})),n?"rgb(".concat(n.map(function(e){return parseInt(e,16)}).join(", "),")"):""}function i(e){if("#"===e.charAt(0))return i(o(e));var t=e.indexOf("("),n=e.substring(0,t),r=e.substring(t+1,e.length-1).split(",");return{type:n,values:r=r.map(function(e){return parseFloat(e)})}}function s(e){var t=e.type,n=e.values;return-1!==t.indexOf("rgb")&&(n=n.map(function(e,t){return t<3?parseInt(e,10):e})),-1!==t.indexOf("hsl")&&(n[1]="".concat(n[1],"%"),n[2]="".concat(n[2],"%")),"".concat(e.type,"(").concat(n.join(", "),")")}function u(e){var t=i(e);if(-1!==t.type.indexOf("rgb")){var n=t.values.map(function(e){return(e/=255)<=.03928?e/12.92:Math.pow((e+.055)/1.055,2.4)});return Number((.2126*n[0]+.7152*n[1]+.0722*n[2]).toFixed(3))}return t.values[2]/100}function l(e,t){if(!e)return e;if(e=i(e),t=a(t),-1!==e.type.indexOf("hsl"))e.values[2]*=1-t;else if(-1!==e.type.indexOf("rgb"))for(var n=0;n<3;n+=1)e.values[n]*=1-t;return s(e)}function c(e,t){if(!e)return e;if(e=i(e),t=a(t),-1!==e.type.indexOf("hsl"))e.values[2]+=(100-e.values[2])*t;else if(-1!==e.type.indexOf("rgb"))for(var n=0;n<3;n+=1)e.values[n]+=(255-e.values[n])*t;return s(e)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r=function(e){return e&&e.ownerDocument||document};t.default=r},function(e,t,n){"use strict";var r=n(3);Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"default",{enumerable:!0,get:function(){return a.default}});var a=r(n(610))},function(e,t,n){"use strict";var r=n(3);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;r(n(7));var a=r(n(9)),o=r(n(10)),i=r(n(60)),s=r(n(347)),u=(r(n(19)),r(n(119))),l=r(n(349)),c=r(n(350)),d=r(n(356)),f=r(n(358)),p=r(n(359)),h=r(n(360)),m=r(n(111)),y=r(n(361));var v=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.breakpoints,n=void 0===t?{}:t,r=e.mixins,v=void 0===r?{}:r,b=e.palette,g=void 0===b?{}:b,A=e.shadows,k=e.spacing,M=void 0===k?{}:k,w=e.typography,x=void 0===w?{}:w,S=(0,o.default)(e,["breakpoints","mixins","palette","shadows","spacing","typography"]),D=(0,c.default)(g),T=(0,u.default)(n),O=(0,a.default)({},h.default,M);return(0,a.default)({breakpoints:T,direction:"ltr",mixins:(0,l.default)(T,O,v),overrides:{},palette:D,props:{},shadows:A||f.default,typography:(0,d.default)(D,x)},(0,i.default)({shape:p.default,spacing:O,transitions:m.default,zIndex:y.default},S,{isMergeableObject:s.default}))};t.default=v},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r="";if(!t)return r;var a=n.indent,s=void 0===a?0:a,u=t.fallbacks;if(s++,u)if(Array.isArray(u))for(var l=0;l-1&&e%1==0&&e-1&&e%1==0&&e<=n}},function(e,t){e.exports=function(e){return function(t){return e(t)}}},function(e,t){e.exports=function(e,t){return e===t||e!=e&&t!=t}},function(e,t,n){var r=n(34)(n(23),"Map");e.exports=r},function(e,t,n){var r=n(448),a=n(455),o=n(457),i=n(458),s=n(459);function u(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t=0||(a[n]=e[n]);return a}(e,["component","childFactory"]),o=c(this.state.children).map(n);return delete r.appear,delete r.enter,delete r.exit,null===t?o:a.default.createElement(t,r,o)},r}(a.default.Component);d.childContextTypes={transitionGroup:r.default.object.isRequired},d.propTypes={},d.defaultProps={component:"div",childFactory:function(e){return e}};var f=(0,o.polyfill)(d);t.default=f,e.exports=t.default},function(e,t,n){var r=n(411),a=n(20),o="Expected a function";e.exports=function(e,t,n){var i=!0,s=!0;if("function"!=typeof e)throw new TypeError(o);return a(n)&&(i="leading"in n?!!n.leading:i,s="trailing"in n?!!n.trailing:s),r(e,t,{leading:i,maxWait:t,trailing:s})}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r={50:"#fbe9e7",100:"#ffccbc",200:"#ffab91",300:"#ff8a65",400:"#ff7043",500:"#ff5722",600:"#f4511e",700:"#e64a19",800:"#d84315",900:"#bf360c",A100:"#ff9e80",A200:"#ff6e40",A400:"#ff3d00",A700:"#dd2c00"};t.default=r},function(e,t,n){"use strict";var r=n(3);Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"default",{enumerable:!0,get:function(){return a.default}});var a=r(n(902))},function(e,t,n){"use strict";var r=n(3);Object.defineProperty(t,"__esModule",{value:!0}),t.default=t.isNumber=t.isString=t.formatMs=t.duration=t.easing=void 0;var a=r(n(10)),o=(r(n(19)),{easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",easeIn:"cubic-bezier(0.4, 0, 1, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"});t.easing=o;var i={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};t.duration=i;var s=function(e){return"".concat(Math.round(e),"ms")};t.formatMs=s;t.isString=function(e){return"string"==typeof e};t.isNumber=function(e){return!isNaN(parseFloat(e))};var u={easing:o,duration:i,create:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:["all"],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.duration,r=void 0===n?i.standard:n,u=t.easing,l=void 0===u?o.easeInOut:u,c=t.delay,d=void 0===c?0:c;(0,a.default)(t,["duration","easing","delay"]);return(Array.isArray(e)?e:[e]).map(function(e){return"".concat(e," ").concat("string"==typeof r?r:s(r)," ").concat(l," ").concat("string"==typeof d?d:s(d))}).join(",")},getAutoHeightDuration:function(e){if(!e)return 0;var t=e/36;return Math.round(10*(4+15*Math.pow(t,.25)+t/5))}};t.default=u},function(e,t,n){"use strict";var r=n(121),a={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},o={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},i={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},s={};function u(e){return r.isMemo(e)?i:s[e.$$typeof]||a}s[r.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0};var l=Object.defineProperty,c=Object.getOwnPropertyNames,d=Object.getOwnPropertySymbols,f=Object.getOwnPropertyDescriptor,p=Object.getPrototypeOf,h=Object.prototype;e.exports=function e(t,n,r){if("string"!=typeof n){if(h){var a=p(n);a&&a!==h&&e(t,a,r)}var i=c(n);d&&(i=i.concat(d(n)));for(var s=u(t),m=u(n),y=0;y0?1:-1},W=function(e){return L()(e)&&e.indexOf("%")===e.length-1},z=function(e){return F()(e)&&!I()(e)},V=function(e){return z(e)||L()(e)},U=0,K=function(e){var t=++U;return"".concat(e||"").concat(t)},G=function(e,t){var n,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,a=arguments.length>3&&void 0!==arguments[3]&&arguments[3];if(!z(e)&&!L()(e))return r;if(W(e)){var o=e.indexOf("%");n=t*parseFloat(e.slice(0,o))/100}else n=+e;return I()(n)&&(n=r),a&&n>t&&(n=t),n},q=function(e){if(!e)return null;var t=Object.keys(e);return t&&t.length?e[t[0]]:null},Z=function(e,t){return z(e)&&z(t)?function(n){return e+n*(t-e)}:function(){return t}},Q=function(e,t,n){return e&&e.length?e.find(function(e){return e&&N()(e,t)===n}):null};function X(e,t){for(var n in e)if({}.hasOwnProperty.call(e,n)&&(!{}.hasOwnProperty.call(t,n)||e[n]!==t[n]))return!1;for(var r in t)if({}.hasOwnProperty.call(t,r)&&!{}.hasOwnProperty.call(e,r))return!1;return!0}function J(e,t){return!X(e,this.props)||!X(t,this.state)}function $(e){e.prototype.shouldComponentUpdate=J}function ee(e){return function(e){if(Array.isArray(e)){for(var t=0,n=new Array(e.length);t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var ne={alignmentBaseline:s.a.string,angle:s.a.number,baselineShift:s.a.string,clip:s.a.string,clipPath:s.a.string,clipRule:s.a.string,color:s.a.string,colorInterpolation:s.a.string,colorInterpolationFilters:s.a.string,colorProfile:s.a.string,colorRendering:s.a.string,cursor:s.a.string,direction:s.a.oneOf(["ltr","rtl","inherit"]),display:s.a.string,dominantBaseline:s.a.string,enableBackground:s.a.string,fill:s.a.string,fillOpacity:s.a.oneOfType([s.a.string,s.a.number]),fillRule:s.a.oneOf(["nonzero","evenodd","inherit"]),filter:s.a.string,floodColor:s.a.string,floodOpacity:s.a.oneOfType([s.a.string,s.a.number]),font:s.a.string,fontFamily:s.a.string,fontSize:s.a.oneOfType([s.a.number,s.a.string]),fontSizeAdjust:s.a.oneOfType([s.a.number,s.a.string]),fontStretch:s.a.oneOf(["normal","wider","narrower","ultra-condensed","extra-condensed","condensed","semi-condensed","semi-expanded","expanded","extra-expanded","ultra-expanded","inherit"]),fontStyle:s.a.oneOf(["normal","italic","oblique","inherit"]),fontVariant:s.a.oneOf(["normal","small-caps","inherit"]),fontWeight:s.a.oneOf(["normal","bold","bolder","lighter",100,200,300,400,500,600,700,800,900,"inherit"]),glyphOrientationHorizontal:s.a.string,glyphOrientationVertical:s.a.string,imageRendering:s.a.oneOf(["auto","optimizeSpeed","optimizeQuality","inherit"]),kerning:s.a.oneOfType([s.a.number,s.a.string]),letterSpacing:s.a.oneOfType([s.a.number,s.a.string]),lightingColor:s.a.string,lineHeight:s.a.oneOfType([s.a.number,s.a.string]),markerEnd:s.a.string,markerMid:s.a.string,markerStart:s.a.string,mask:s.a.string,opacity:s.a.oneOfType([s.a.number,s.a.string]),overflow:s.a.oneOf(["visible","hidden","scroll","auto","inherit"]),pointerEvents:s.a.oneOf(["visiblePainted","visibleFill","visibleStroke","visible","painted","fill","stroke","all","none","inherit"]),shapeRendering:s.a.oneOf(["auto","optimizeSpeed","crispEdges","geometricPrecision","inherit"]),stopColor:s.a.string,stopOpacity:s.a.oneOfType([s.a.number,s.a.string]),stroke:s.a.oneOfType([s.a.number,s.a.string]),strokeDasharray:s.a.string,strokeDashoffset:s.a.oneOfType([s.a.number,s.a.string]),strokeLinecap:s.a.oneOf(["butt","round","square","inherit"]),strokeLinejoin:s.a.oneOf(["miter","round","bevel","inherit"]),strokeMiterlimit:s.a.oneOfType([s.a.number,s.a.string]),strokeOpacity:s.a.oneOfType([s.a.number,s.a.string]),strokeWidth:s.a.oneOfType([s.a.number,s.a.string]),textAnchor:s.a.oneOf(["start","middle","end","inherit"]),textDecoration:s.a.oneOf(["none","underline","overline","line-through","blink","inherit"]),textRendering:s.a.oneOf(["auto","optimizeSpeed","optimizeLegibility","geometricPrecision","inherit"]),unicodeBidi:s.a.oneOf(["normal","embed","bidi-override","inherit"]),visibility:s.a.oneOf(["visible","hidden","collapse","inherit"]),wordSpacing:s.a.oneOfType([s.a.number,s.a.string]),writingMode:s.a.oneOf(["lr-tb","rl-tb","tb-rl","lr","rl","tb","inherit"]),transform:s.a.string,style:s.a.object,width:s.a.number,height:s.a.number,dx:s.a.number,dy:s.a.number,x:s.a.number,y:s.a.number,r:s.a.number,radius:s.a.oneOfType([s.a.number,s.a.array])},re={onClick:s.a.func,onMouseDown:s.a.func,onMouseUp:s.a.func,onMouseOver:s.a.func,onMouseMove:s.a.func,onMouseOut:s.a.func,onMouseEnter:s.a.func,onMouseLeave:s.a.func,onTouchEnd:s.a.func,onTouchMove:s.a.func,onTouchStart:s.a.func,onTouchCancel:s.a.func},ae={click:"onClick",mousedown:"onMouseDown",mouseup:"onMouseUp",mouseover:"onMouseOver",mousemove:"onMouseMove",mouseout:"onMouseOut",mouseenter:"onMouseEnter",mouseleave:"onMouseLeave",touchcancel:"onTouchCancel",touchend:"onTouchEnd",touchmove:"onTouchMove",touchstart:"onTouchStart"},oe=["plainline","line","square","rect","circle","cross","diamond","star","triangle","wye","none"],ie=function(e){return"string"==typeof e?e:e?e.displayName||e.name||"Component":""},se=function(e,t){var n=[],r=[];return r=Y()(t)?t.map(function(e){return ie(e)}):[ie(t)],o.a.Children.forEach(e,function(e){var t=e&&e.type&&(e.type.displayName||e.type.name);-1!==r.indexOf(t)&&n.push(e)}),n},ue=function(e,t){var n=se(e,t);return n&&n[0]},le=function(e){if(!e||A()(e))return null;var t=o.a.isValidElement(e)?e.props:e;if(!j()(t))return null;var n=null;for(var r in t)({}).hasOwnProperty.call(t,r)&&ne[r]&&(n||(n={}),n[r]=t[r]);return n},ce=function(e,t){return function(n){return e(t,n),null}},de=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if(!e||A()(e))return null;var r=o.a.isValidElement(e)?e.props:e;if(!j()(r))return null;var a=null;for(var i in r)({}).hasOwnProperty.call(r,i)&&re[i]&&(a||(a={}),a[i]=t||(n?ce(r[i],r):r[i]));return a},fe=function(e,t,n){return function(r){return e(t,n,r),null}},pe=function(e,t,n){if(!j()(e))return null;var r=null;for(var a in e)({}).hasOwnProperty.call(e,a)&&re[a]&&A()(e[a])&&(r||(r={}),r[a]=fe(e[a],t,n));return r},he=function(e){if(!e||!e.props)return!1;var t=e.props,n=t.width,r=t.height;return!(!z(n)||n<=0||!z(r)||r<=0)},me=function(){return!("undefined"!=typeof window&&window.document&&window.document.createElement&&window.setTimeout)},ye=["a","altGlyph","altGlyphDef","altGlyphItem","animate","animateColor","animateMotion","animateTransform","circle","clipPath","color-profile","cursor","defs","desc","ellipse","feBlend","feColormatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","filter","font","font-face","font-face-format","font-face-name","font-face-url","foreignObject","g","glyph","glyphRef","hkern","image","line","lineGradient","marker","mask","metadata","missing-glyph","mpath","path","pattern","polygon","polyline","radialGradient","rect","script","set","stop","style","svg","switch","symbol","text","textPath","title","tref","tspan","use","view","vkern"],ve=function(e,t){if(D()(e)&&D()(t))return!0;if(!D()(e)&&!D()(t)){var n=e.props||{},r=n.children,a=te(n,["children"]),o=t.props||{},i=o.children,s=te(o,["children"]);return r&&i?X(a,s)&&be(r,i):!r&&!i&&X(a,s)}return!1},be=function e(t,n){if(t===n)return!0;if(a.Children.count(t)!==a.Children.count(n))return!1;var r=a.Children.count(t);if(0===r)return!0;if(1===r)return ve(Y()(t)?t[0]:t,Y()(n)?n[0]:n);for(var o=0;o=0}(e))n.push(e);else if(e&&t[ie(e.type)]){var o=ie(e.type),i=t[o],s=i.handler,u=i.once;if(u&&!r[o]||!u){var l=s(e,o,a);Y()(l)?n=[n].concat(ee(l)):n.push(l),r[o]=!0}}}),n},Ae=function(e){var t=e&&e.type;return t&&ae[t]?ae[t]:null};function ke(){return(ke=Object.assign||function(e){for(var t=1;t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var we={width:s.a.number.isRequired,height:s.a.number.isRequired,viewBox:s.a.shape({x:s.a.number,y:s.a.number,width:s.a.number,height:s.a.number}),className:s.a.string,style:s.a.object,children:s.a.oneOfType([s.a.arrayOf(s.a.node),s.a.node])};function xe(e){var t=e.children,n=e.width,r=e.height,a=e.viewBox,i=e.className,s=e.style,u=Me(e,["children","width","height","viewBox","className","style"]),l=a||{width:n,height:r,x:0,y:0},c=O()("recharts-surface",i),d=le(u);return o.a.createElement("svg",ke({},d,{className:c,width:n,height:r,style:s,viewBox:"".concat(l.x," ").concat(l.y," ").concat(l.width," ").concat(l.height),version:"1.1"}),t)}xe.propTypes=we;var Se=xe;function De(){return(De=Object.assign||function(e){for(var t=1;t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var Oe={className:s.a.string,children:s.a.oneOfType([s.a.arrayOf(s.a.node),s.a.node])};function Pe(e){var t=e.children,n=e.className,r=Te(e,["children","className"]),a=O()("recharts-layer",n);return o.a.createElement("g",De({className:a},r),t)}Pe.propTypes=Oe;var Le=Pe,Ee=n(26),je=n.n(Ee),Ce=n(31),Ye=n.n(Ce);function Re(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=-1;Ye()(function r(a){n<0&&(n=a),a-n>t?(e(a),n=-1):Ye()(r)})}function Ne(e){return(Ne="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})(e)}function _e(e){return function(e){if(Array.isArray(e))return e}(e)||function(e){if(Symbol.iterator in Object(e)||"[object Arguments]"===Object.prototype.toString.call(e))return Array.from(e)}(e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance")}()}function Ie(){var e=function(){return null},t=!1;return{stop:function(){t=!0},start:function(n){t=!1,function n(r){if(!t){if(Array.isArray(r)){if(!r.length)return;var a=_e(r),o=a[0],i=a.slice(1);return"number"==typeof o?void Re(n.bind(null,i),o):(n(o),void Re(n.bind(null,i)))}"object"===Ne(r)&&e(r),"function"==typeof r&&r()}}(n)},subscribe:function(t){return e=t,function(){e=function(){return null}}}}}var He=n(57),Fe=n.n(He);function Be(e){return(Be="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})(e)}function We(e,t){if(e===t)return!0;if("object"!==Be(e)||null===e||"object"!==Be(t)||null===t)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(var a=hasOwnProperty.bind(t),o=0;o=0&&e<=1});var s,u,l=ot(r,o),c=ot(a,i),d=(s=r,u=o,function(e){var t=nt(rt(s,u).map(function(e,t){return e*t}).slice(1)).concat([0]);return at(t,e)}),f=function(e){for(var t,n=e>1?1:e,r=n,a=0;a<8;++a){var o=l(r)-n,i=d(r);if(Math.abs(o-n)<1e-4||i<1e-4)return c(r);r=(t=r-o/i)>1?1:t<0?0:t}return c(r)};return f.isStepper=!1,f},st=function(){for(var e=arguments.length,t=new Array(e),n=0;n0&&void 0!==arguments[0]?arguments[0]:{},t=e.stiff,n=void 0===t?100:t,r=e.damping,a=void 0===r?8:r,o=e.dt,i=void 0===o?17:o,s=function(e,t,r){var o=r+(-(e-t)*n-r*a)*i/1e3,s=r*i/1e3+e;return Math.abs(s-t)<1e-4&&Math.abs(o)<1e-4?[t,0]:[s,o]};return s.isStepper=!0,s.dt=i,s}()}return"function"==typeof r?r:null},ut=n(301),lt=n.n(ut);function ct(e){return function(e){if(Array.isArray(e)){for(var t=0,n=new Array(e.length);t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}function Mt(e){return function(e){if(Array.isArray(e)){for(var t=0,n=new Array(e.length);t0?n[a-1]:r,f=l||Object.keys(u);if("function"==typeof s||"spring"===s)return Mt(e).concat([t.runJSAnimation.bind(t,{from:d.style,to:u,duration:o,easing:s}),o]);var p=tt(f,o,s),h=wt({},d.style,u,{transition:p});return Mt(e).concat([h,o,c]).filter(Je)},[i,Math.max(u,r)])),[e.onAnimationEnd]))}},{key:"runAnimation",value:function(e){this.manager||(this.manager=Ie());var t=e.begin,n=e.duration,r=e.attributeName,a=e.to,o=e.easing,i=e.onAnimationStart,s=e.onAnimationEnd,u=e.steps,l=e.children,c=this.manager;if(this.unSubscribe=c.subscribe(this.handleStyleChange),"function"!=typeof o&&"function"!=typeof l&&"spring"!==o)if(u.length>1)this.runStepAnimation(e);else{var d=r?xt({},r,a):a,f=tt(Object.keys(d),n,o);c.start([i,t,wt({},d,{transition:f}),n,s])}else this.runJSAnimation(e)}},{key:"handleStyleChange",value:function(e){this.changeStyle(e)}},{key:"changeStyle",value:function(e){this.mounted&&this.setState({style:e})}},{key:"render",value:function(){var e=this.props,t=e.children,n=(e.begin,e.duration,e.attributeName,e.easing,e.isActive),r=(e.steps,e.from,e.to,e.canBegin,e.onAnimationEnd,e.shouldReAnimate,e.onAnimationReStart,kt(e,["children","begin","duration","attributeName","easing","isActive","steps","from","to","canBegin","onAnimationEnd","shouldReAnimate","onAnimationReStart"])),i=a.Children.count(t),s=et(this.state.style);if("function"==typeof t)return t(s);if(!n||0===i)return t;var u=function(e){var t=e.props,n=t.style,o=void 0===n?{}:n,i=t.className;return Object(a.cloneElement)(e,wt({},r,{style:wt({},o,s),className:i}))};return 1===i?u(a.Children.only(t)):o.a.createElement("div",null,a.Children.map(t,function(e){return u(e)}))}}])&&St(n.prototype,r),i&&St(n,i),t}(),mt.displayName="Animate",mt.propTypes={from:s.a.oneOfType([s.a.object,s.a.string]),to:s.a.oneOfType([s.a.object,s.a.string]),attributeName:s.a.string,duration:s.a.number,begin:s.a.number,easing:s.a.oneOfType([s.a.string,s.a.func]),steps:s.a.arrayOf(s.a.shape({duration:s.a.number.isRequired,style:s.a.object.isRequired,easing:s.a.oneOfType([s.a.oneOf(["ease","ease-in","ease-out","ease-in-out","linear"]),s.a.func]),properties:s.a.arrayOf("string"),onAnimationEnd:s.a.func})),children:s.a.oneOfType([s.a.node,s.a.func]),isActive:s.a.bool,canBegin:s.a.bool,onAnimationEnd:s.a.func,shouldReAnimate:s.a.bool,onAnimationStart:s.a.func,onAnimationReStart:s.a.func},mt.defaultProps={begin:0,duration:1e3,from:"",to:"",attributeName:"",easing:"ease",isActive:!0,canBegin:!0,steps:[],onAnimationEnd:function(){},onAnimationStart:function(){}},ht=yt))||ht,Et=n(75);function jt(e){return(jt="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})(e)}function Ct(){return(Ct=Object.assign||function(e){for(var t=1;t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}function Rt(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Nt(e,t){for(var n=0;n0&&void 0!==arguments[0]?arguments[0]:{},t=e.steps,n=e.duration;return t&&t.length?t.reduce(function(e,t){return e+(F()(t.duration)&&t.duration>0?t.duration:0)},0):F()(n)?n:0},Bt=function(e){function t(){var e,n;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);for(var r=arguments.length,a=new Array(r),o=0;o1||Math.abs(r.height-n)>1)&&this.setState({boxWidth:r.width,boxHeight:r.height})}else-1===t&&-1===n||this.setState({boxWidth:-1,boxHeight:-1})}},{key:"render",value:function(){var e,t,n,r=this,a=this.props,i=a.payload,s=a.isAnimationActive,u=a.animationDuration,l=a.animationEasing,c=a.filterNull&&i&&i.length?i.filter(function(e){return!D()(e.value)}):i,d=c&&c.length,f=this.props,p=f.content,h=f.viewBox,m=f.coordinate,y=f.position,v=f.active,b=f.offset,g=un({pointerEvents:"none",visibility:v&&d?"visible":"hidden",position:"absolute",top:0},f.wrapperStyle);if(y&&z(y.x)&&z(y.y))t=y.x,n=y.y;else{var k=this.state,M=k.boxWidth,w=k.boxHeight;M>0&&w>0&&m?(t=y&&z(y.x)?y.x:Math.max(m.x+M+b>h.x+h.width?m.x-M-b:m.x+b,h.x),n=y&&z(y.y)?y.y:Math.max(m.y+w+b>h.y+h.height?m.y-w-b:m.y+b,h.y)):g.visibility="hidden"}g=un({},g,et({transform:this.props.useTranslate3d?"translate3d(".concat(t,"px, ").concat(n,"px, 0)"):"translate(".concat(t,"px, ").concat(n,"px)")})),s&&v&&(g=un({},g,et({transition:"transform ".concat(u,"ms ").concat(l)})));var x=O()(hn,(ln(e={},"".concat(hn,"-right"),z(t)&&m&&z(m.x)&&t>=m.x),ln(e,"".concat(hn,"-left"),z(t)&&m&&z(m.x)&&t=m.y),ln(e,"".concat(hn,"-top"),z(n)&&m&&z(m.y)&&n1e-6)if(Math.abs(c*s-u*l)>1e-6&&a){var f=n-o,p=r-i,h=s*s+u*u,m=f*f+p*p,y=Math.sqrt(h),v=Math.sqrt(d),b=a*Math.tan((bn-Math.acos((h+d-m)/(2*y*v)))/2),g=b/v,A=b/y;Math.abs(g-1)>1e-6&&(this._+="L"+(e+g*l)+","+(t+g*c)),this._+="A"+a+","+a+",0,0,"+ +(c*f>l*p)+","+(this._x1=e+A*s)+","+(this._y1=t+A*u)}else this._+="L"+(this._x1=e)+","+(this._y1=t);else;},arc:function(e,t,n,r,a,o){e=+e,t=+t;var i=(n=+n)*Math.cos(r),s=n*Math.sin(r),u=e+i,l=t+s,c=1^o,d=o?r-a:a-r;if(n<0)throw new Error("negative radius: "+n);null===this._x1?this._+="M"+u+","+l:(Math.abs(this._x1-u)>1e-6||Math.abs(this._y1-l)>1e-6)&&(this._+="L"+u+","+l),n&&(d<0&&(d=d%gn+gn),d>An?this._+="A"+n+","+n+",0,1,"+c+","+(e-i)+","+(t-s)+"A"+n+","+n+",0,1,"+c+","+(this._x1=u)+","+(this._y1=l):d>1e-6&&(this._+="A"+n+","+n+",0,"+ +(d>=bn)+","+c+","+(this._x1=e+n*Math.cos(a))+","+(this._y1=t+n*Math.sin(a))))},rect:function(e,t,n,r){this._+="M"+(this._x0=this._x1=+e)+","+(this._y0=this._y1=+t)+"h"+ +n+"v"+ +r+"h"+-n+"Z"},toString:function(){return this._}};var wn=Mn,xn=function(e){return function(){return e}},Sn=(Math.abs,Math.atan2,Math.cos,Math.max,Math.min,Math.sin,Math.sqrt,1e-12),Dn=Math.PI,Tn=2*Dn;function On(e){this._context=e}On.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:this._context.lineTo(e,t)}}};var Pn=function(e){return new On(e)};function Ln(e){return e[0]}function En(e){return e[1]}var jn=function(){var e=Ln,t=En,n=xn(!0),r=null,a=Pn,o=null;function i(i){var s,u,l,c=i.length,d=!1;for(null==r&&(o=a(l=wn())),s=0;s<=c;++s)!(s=c;--d)s.point(y[d],v[d]);s.lineEnd(),s.areaEnd()}m&&(y[l]=+e(f,l,u),v[l]=+n(f,l,u),s.point(t?+t(f,l,u):y[l],r?+r(f,l,u):v[l]))}if(p)return s=null,p+""||null}function l(){return jn().defined(a).curve(i).context(o)}return u.x=function(n){return arguments.length?(e="function"==typeof n?n:xn(+n),t=null,u):e},u.x0=function(t){return arguments.length?(e="function"==typeof t?t:xn(+t),u):e},u.x1=function(e){return arguments.length?(t=null==e?null:"function"==typeof e?e:xn(+e),u):t},u.y=function(e){return arguments.length?(n="function"==typeof e?e:xn(+e),r=null,u):n},u.y0=function(e){return arguments.length?(n="function"==typeof e?e:xn(+e),u):n},u.y1=function(e){return arguments.length?(r=null==e?null:"function"==typeof e?e:xn(+e),u):r},u.lineX0=u.lineY0=function(){return l().x(e).y(n)},u.lineY1=function(){return l().x(e).y(r)},u.lineX1=function(){return l().x(t).y(n)},u.defined=function(e){return arguments.length?(a="function"==typeof e?e:xn(!!e),u):a},u.curve=function(e){return arguments.length?(i=e,null!=o&&(s=i(o)),u):i},u.context=function(e){return arguments.length?(null==e?o=s=null:s=i(o=e),u):o},u};Rn(Pn);function Yn(e){this._curve=e}function Rn(e){function t(t){return new Yn(e(t))}return t._curve=e,t}Yn.prototype={areaStart:function(){this._curve.areaStart()},areaEnd:function(){this._curve.areaEnd()},lineStart:function(){this._curve.lineStart()},lineEnd:function(){this._curve.lineEnd()},point:function(e,t){this._curve.point(t*Math.sin(e),t*-Math.cos(e))}};var Nn=Array.prototype.slice;var _n={draw:function(e,t){var n=Math.sqrt(t/Dn);e.moveTo(n,0),e.arc(0,0,n,0,Tn)}},In={draw:function(e,t){var n=Math.sqrt(t/5)/2;e.moveTo(-3*n,-n),e.lineTo(-n,-n),e.lineTo(-n,-3*n),e.lineTo(n,-3*n),e.lineTo(n,-n),e.lineTo(3*n,-n),e.lineTo(3*n,n),e.lineTo(n,n),e.lineTo(n,3*n),e.lineTo(-n,3*n),e.lineTo(-n,n),e.lineTo(-3*n,n),e.closePath()}},Hn=Math.sqrt(1/3),Fn=2*Hn,Bn={draw:function(e,t){var n=Math.sqrt(t/Fn),r=n*Hn;e.moveTo(0,-n),e.lineTo(r,0),e.lineTo(0,n),e.lineTo(-r,0),e.closePath()}},Wn=Math.sin(Dn/10)/Math.sin(7*Dn/10),zn=Math.sin(Tn/10)*Wn,Vn=-Math.cos(Tn/10)*Wn,Un={draw:function(e,t){var n=Math.sqrt(.8908130915292852*t),r=zn*n,a=Vn*n;e.moveTo(0,-n),e.lineTo(r,a);for(var o=1;o<5;++o){var i=Tn*o/5,s=Math.cos(i),u=Math.sin(i);e.lineTo(u*n,-s*n),e.lineTo(s*r-u*a,u*r+s*a)}e.closePath()}},Kn={draw:function(e,t){var n=Math.sqrt(t),r=-n/2;e.rect(r,r,n,n)}},Gn=Math.sqrt(3),qn={draw:function(e,t){var n=-Math.sqrt(t/(3*Gn));e.moveTo(0,2*n),e.lineTo(-Gn*n,-n),e.lineTo(Gn*n,-n),e.closePath()}},Zn=Math.sqrt(3)/2,Qn=1/Math.sqrt(12),Xn=3*(Qn/2+1),Jn={draw:function(e,t){var n=Math.sqrt(t/Xn),r=n/2,a=n*Qn,o=r,i=n*Qn+n,s=-o,u=i;e.moveTo(r,a),e.lineTo(o,i),e.lineTo(s,u),e.lineTo(-.5*r-Zn*a,Zn*r+-.5*a),e.lineTo(-.5*o-Zn*i,Zn*o+-.5*i),e.lineTo(-.5*s-Zn*u,Zn*s+-.5*u),e.lineTo(-.5*r+Zn*a,-.5*a-Zn*r),e.lineTo(-.5*o+Zn*i,-.5*i-Zn*o),e.lineTo(-.5*s+Zn*u,-.5*u-Zn*s),e.closePath()}},$n=function(){};function er(e,t,n){e._context.bezierCurveTo((2*e._x0+e._x1)/3,(2*e._y0+e._y1)/3,(e._x0+2*e._x1)/3,(e._y0+2*e._y1)/3,(e._x0+4*e._x1+t)/6,(e._y0+4*e._y1+n)/6)}function tr(e){this._context=e}tr.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:er(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:er(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function nr(e){this._context=e}nr.prototype={areaStart:$n,areaEnd:$n,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x2,this._y2),this._context.closePath();break;case 2:this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break;case 3:this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4)}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x2=e,this._y2=t;break;case 1:this._point=2,this._x3=e,this._y3=t;break;case 2:this._point=3,this._x4=e,this._y4=t,this._context.moveTo((this._x0+4*this._x1+e)/6,(this._y0+4*this._y1+t)/6);break;default:er(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function rr(e){this._context=e}rr.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var n=(this._x0+4*this._x1+e)/6,r=(this._y0+4*this._y1+t)/6;this._line?this._context.lineTo(n,r):this._context.moveTo(n,r);break;case 3:this._point=4;default:er(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function ar(e,t){this._basis=new tr(e),this._beta=t}ar.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var e=this._x,t=this._y,n=e.length-1;if(n>0)for(var r,a=e[0],o=t[0],i=e[n]-a,s=t[n]-o,u=-1;++u<=n;)r=u/n,this._basis.point(this._beta*e[u]+(1-this._beta)*(a+r*i),this._beta*t[u]+(1-this._beta)*(o+r*s));this._x=this._y=null,this._basis.lineEnd()},point:function(e,t){this._x.push(+e),this._y.push(+t)}};(function e(t){function n(e){return 1===t?new tr(e):new ar(e,t)}return n.beta=function(t){return e(+t)},n})(.85);function or(e,t,n){e._context.bezierCurveTo(e._x1+e._k*(e._x2-e._x0),e._y1+e._k*(e._y2-e._y0),e._x2+e._k*(e._x1-t),e._y2+e._k*(e._y1-n),e._x2,e._y2)}function ir(e,t){this._context=e,this._k=(1-t)/6}ir.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:or(this,this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2,this._x1=e,this._y1=t;break;case 2:this._point=3;default:or(this,e,t)}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};(function e(t){function n(e){return new ir(e,t)}return n.tension=function(t){return e(+t)},n})(0);function sr(e,t){this._context=e,this._k=(1-t)/6}sr.prototype={areaStart:$n,areaEnd:$n,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x3=e,this._y3=t;break;case 1:this._point=2,this._context.moveTo(this._x4=e,this._y4=t);break;case 2:this._point=3,this._x5=e,this._y5=t;break;default:or(this,e,t)}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};(function e(t){function n(e){return new sr(e,t)}return n.tension=function(t){return e(+t)},n})(0);function ur(e,t){this._context=e,this._k=(1-t)/6}ur.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:or(this,e,t)}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};(function e(t){function n(e){return new ur(e,t)}return n.tension=function(t){return e(+t)},n})(0);function lr(e,t,n){var r=e._x1,a=e._y1,o=e._x2,i=e._y2;if(e._l01_a>Sn){var s=2*e._l01_2a+3*e._l01_a*e._l12_a+e._l12_2a,u=3*e._l01_a*(e._l01_a+e._l12_a);r=(r*s-e._x0*e._l12_2a+e._x2*e._l01_2a)/u,a=(a*s-e._y0*e._l12_2a+e._y2*e._l01_2a)/u}if(e._l23_a>Sn){var l=2*e._l23_2a+3*e._l23_a*e._l12_a+e._l12_2a,c=3*e._l23_a*(e._l23_a+e._l12_a);o=(o*l+e._x1*e._l23_2a-t*e._l12_2a)/c,i=(i*l+e._y1*e._l23_2a-n*e._l12_2a)/c}e._context.bezierCurveTo(r,a,o,i,e._x2,e._y2)}function cr(e,t){this._context=e,this._alpha=t}cr.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:this.point(this._x2,this._y2)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){if(e=+e,t=+t,this._point){var n=this._x2-e,r=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3;default:lr(this,e,t)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};(function e(t){function n(e){return t?new cr(e,t):new ir(e,0)}return n.alpha=function(t){return e(+t)},n})(.5);function dr(e,t){this._context=e,this._alpha=t}dr.prototype={areaStart:$n,areaEnd:$n,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(e,t){if(e=+e,t=+t,this._point){var n=this._x2-e,r=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1,this._x3=e,this._y3=t;break;case 1:this._point=2,this._context.moveTo(this._x4=e,this._y4=t);break;case 2:this._point=3,this._x5=e,this._y5=t;break;default:lr(this,e,t)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};(function e(t){function n(e){return t?new dr(e,t):new sr(e,0)}return n.alpha=function(t){return e(+t)},n})(.5);function fr(e,t){this._context=e,this._alpha=t}fr.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){if(e=+e,t=+t,this._point){var n=this._x2-e,r=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:lr(this,e,t)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};(function e(t){function n(e){return t?new fr(e,t):new ur(e,0)}return n.alpha=function(t){return e(+t)},n})(.5);function pr(e){this._context=e}pr.prototype={areaStart:$n,areaEnd:$n,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(e,t){e=+e,t=+t,this._point?this._context.lineTo(e,t):(this._point=1,this._context.moveTo(e,t))}};function hr(e){return e<0?-1:1}function mr(e,t,n){var r=e._x1-e._x0,a=t-e._x1,o=(e._y1-e._y0)/(r||a<0&&-0),i=(n-e._y1)/(a||r<0&&-0),s=(o*a+i*r)/(r+a);return(hr(o)+hr(i))*Math.min(Math.abs(o),Math.abs(i),.5*Math.abs(s))||0}function yr(e,t){var n=e._x1-e._x0;return n?(3*(e._y1-e._y0)/n-t)/2:t}function vr(e,t,n){var r=e._x0,a=e._y0,o=e._x1,i=e._y1,s=(o-r)/3;e._context.bezierCurveTo(r+s,a+s*t,o-s,i-s*n,o,i)}function br(e){this._context=e}function gr(e){this._context=new Ar(e)}function Ar(e){this._context=e}function kr(e){this._context=e}function Mr(e){var t,n,r=e.length-1,a=new Array(r),o=new Array(r),i=new Array(r);for(a[0]=0,o[0]=2,i[0]=e[0]+2*e[1],t=1;t=0;--t)a[t]=(i[t]-a[t+1])/o[t];for(o[r-1]=(e[r]+a[r-1])/2,t=0;t=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:if(this._t<=0)this._context.lineTo(this._x,t),this._context.lineTo(e,t);else{var n=this._x*(1-this._t)+e*this._t;this._context.lineTo(n,this._y),this._context.lineTo(n,t)}}this._x=e,this._y=t}};var xr=function(e,t){if((a=e.length)>1)for(var n,r,a,o=1,i=e[t[0]],s=i.length;o=0;)n[t]=t;return n};function Dr(e,t){return e[t]}var Tr,Or,Pr;function Lr(e){return(Lr="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})(e)}function Er(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function jr(){return(jr=Object.assign||function(e){for(var t=1;t=0&&n>=0?{width:t,height:n}:null}},{key:"getDefaultPosition",value:function(e){var t,n,r=this.props,a=r.layout,o=r.align,i=r.verticalAlign,s=r.margin,u=r.chartWidth,l=r.chartHeight;e&&(void 0!==e.left&&null!==e.left||void 0!==e.right&&null!==e.right)||(t="center"===o&&"vertical"===a?{left:((u||0)-(this.getBBox()||{width:0}).width)/2}:"right"===o?{right:s&&s.right||0}:{left:s&&s.left||0});e&&(void 0!==e.top&&null!==e.top||void 0!==e.bottom&&null!==e.bottom)||(n="middle"===i?{top:((l||0)-(this.getBBox()||{height:0}).height)/2}:"bottom"===i?{bottom:s&&s.bottom||0}:{top:s&&s.top||0});return na({},t,n)}},{key:"updateBBox",value:function(){var e=this.state,t=e.boxWidth,n=e.boxHeight,r=this.props.onBBoxUpdate;if(this.wrapperNode&&this.wrapperNode.getBoundingClientRect){var a=this.wrapperNode.getBoundingClientRect();(Math.abs(a.width-t)>1||Math.abs(a.height-n)>1)&&this.setState({boxWidth:a.width,boxHeight:a.height},function(){r&&r(a)})}else-1===t&&-1===n||this.setState({boxWidth:-1,boxHeight:-1},function(){r&&r(null)})}},{key:"render",value:function(){var e=this,t=this.props,n=t.content,r=t.width,a=t.height,i=t.wrapperStyle,s=na({position:"absolute",width:r||"auto",height:a||"auto"},this.getDefaultPosition(i),i);return o.a.createElement("div",{className:"recharts-legend-wrapper",style:s,ref:function(t){e.wrapperNode=t}},function(e,t){return o.a.isValidElement(e)?o.a.cloneElement(e,t):A()(e)?e(t):o.a.createElement(ea,t)}(n,this.props))}}])&&aa(n.prototype,r),i&&aa(n,i),t}(),Xr.displayName="Legend",Xr.propTypes={content:s.a.oneOfType([s.a.element,s.a.func]),wrapperStyle:s.a.object,chartWidth:s.a.number,chartHeight:s.a.number,width:s.a.number,height:s.a.number,iconSize:s.a.number,iconType:s.a.oneOf(da),layout:s.a.oneOf(["horizontal","vertical"]),align:s.a.oneOf(["center","left","right"]),verticalAlign:s.a.oneOf(["top","bottom","middle"]),margin:s.a.shape({top:s.a.number,left:s.a.number,bottom:s.a.number,right:s.a.number}),payload:s.a.arrayOf(s.a.shape({value:s.a.any,id:s.a.any,type:s.a.oneOf(oe)})),formatter:s.a.func,onMouseEnter:s.a.func,onMouseLeave:s.a.func,onClick:s.a.func,onBBoxUpdate:s.a.func},Xr.defaultProps={iconSize:14,layout:"horizontal",align:"center",verticalAlign:"bottom"},Qr=Jr))||Qr;function pa(e){return(pa="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})(e)}function ha(){return(ha=Object.assign||function(e){for(var t=1;tt?1:e>=t?0:NaN},Ua=function(e){var t;return 1===e.length&&(t=e,e=function(e,n){return Va(t(e),n)}),{left:function(t,n,r,a){for(null==r&&(r=0),null==a&&(a=t.length);r>>1;e(t[o],n)<0?r=o+1:a=o}return r},right:function(t,n,r,a){for(null==r&&(r=0),null==a&&(a=t.length);r>>1;e(t[o],n)>0?a=o:r=o+1}return r}}};var Ka=Ua(Va),Ga=Ka.right,qa=(Ka.left,Ga);var Za=function(e){return null===e?NaN:+e},Qa=Array.prototype,Xa=(Qa.slice,Qa.map,function(e,t,n){e=+e,t=+t,n=(a=arguments.length)<2?(t=e,e=0,1):a<3?1:+n;for(var r=-1,a=0|Math.max(0,Math.ceil((t-e)/n)),o=new Array(a);++r0)return[e];if((r=t0)for(e=Math.ceil(e/i),t=Math.floor(t/i),o=new Array(a=Math.ceil(t-e+1));++s=0?(o>=Ja?10:o>=$a?5:o>=eo?2:1)*Math.pow(10,a):-Math.pow(10,-a)/(o>=Ja?10:o>=$a?5:o>=eo?2:1)}function ro(e,t,n){var r=Math.abs(t-e)/Math.max(0,n),a=Math.pow(10,Math.floor(Math.log(r)/Math.LN10)),o=r/a;return o>=Ja?a*=10:o>=$a?a*=5:o>=eo&&(a*=2),t=1)return+n(e[r-1],r-1,e);var r,a=(r-1)*t,o=Math.floor(a),i=+n(e[o],o,e);return i+(+n(e[o+1],o+1,e)-i)*(a-o)}};function oo(){}function io(e,t){var n=new oo;if(e instanceof oo)e.each(function(e,t){n.set(t,e)});else if(Array.isArray(e)){var r,a=-1,o=e.length;if(null==t)for(;++a>8&15|t>>4&240,t>>4&15|240&t,(15&t)<<4|15&t,1):(t=Do.exec(e))?Ro(parseInt(t[1],16)):(t=To.exec(e))?new Ho(t[1],t[2],t[3],1):(t=Oo.exec(e))?new Ho(255*t[1]/100,255*t[2]/100,255*t[3]/100,1):(t=Po.exec(e))?No(t[1],t[2],t[3],t[4]):(t=Lo.exec(e))?No(255*t[1]/100,255*t[2]/100,255*t[3]/100,t[4]):(t=Eo.exec(e))?Bo(t[1],t[2]/100,t[3]/100,1):(t=jo.exec(e))?Bo(t[1],t[2]/100,t[3]/100,t[4]):Co.hasOwnProperty(e)?Ro(Co[e]):"transparent"===e?new Ho(NaN,NaN,NaN,0):null}function Ro(e){return new Ho(e>>16&255,e>>8&255,255&e,1)}function No(e,t,n,r){return r<=0&&(e=t=n=NaN),new Ho(e,t,n,r)}function _o(e){return e instanceof ko||(e=Yo(e)),e?new Ho((e=e.rgb()).r,e.g,e.b,e.opacity):new Ho}function Io(e,t,n,r){return 1===arguments.length?_o(e):new Ho(e,t,n,null==r?1:r)}function Ho(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}function Fo(e){return((e=Math.max(0,Math.min(255,Math.round(e)||0)))<16?"0":"")+e.toString(16)}function Bo(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new zo(e,t,n,r)}function Wo(e,t,n,r){return 1===arguments.length?function(e){if(e instanceof zo)return new zo(e.h,e.s,e.l,e.opacity);if(e instanceof ko||(e=Yo(e)),!e)return new zo;if(e instanceof zo)return e;var t=(e=e.rgb()).r/255,n=e.g/255,r=e.b/255,a=Math.min(t,n,r),o=Math.max(t,n,r),i=NaN,s=o-a,u=(o+a)/2;return s?(i=t===o?(n-r)/s+6*(n0&&u<1?0:i,new zo(i,s,u,e.opacity)}(e):new zo(e,t,n,null==r?1:r)}function zo(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}function Vo(e,t,n){return 255*(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)}go(ko,Yo,{displayable:function(){return this.rgb().displayable()},hex:function(){return this.rgb().hex()},toString:function(){return this.rgb()+""}}),go(Ho,Io,Ao(ko,{brighter:function(e){return e=null==e?1/.7:Math.pow(1/.7,e),new Ho(this.r*e,this.g*e,this.b*e,this.opacity)},darker:function(e){return e=null==e?.7:Math.pow(.7,e),new Ho(this.r*e,this.g*e,this.b*e,this.opacity)},rgb:function(){return this},displayable:function(){return 0<=this.r&&this.r<=255&&0<=this.g&&this.g<=255&&0<=this.b&&this.b<=255&&0<=this.opacity&&this.opacity<=1},hex:function(){return"#"+Fo(this.r)+Fo(this.g)+Fo(this.b)},toString:function(){var e=this.opacity;return(1===(e=isNaN(e)?1:Math.max(0,Math.min(1,e)))?"rgb(":"rgba(")+Math.max(0,Math.min(255,Math.round(this.r)||0))+", "+Math.max(0,Math.min(255,Math.round(this.g)||0))+", "+Math.max(0,Math.min(255,Math.round(this.b)||0))+(1===e?")":", "+e+")")}})),go(zo,Wo,Ao(ko,{brighter:function(e){return e=null==e?1/.7:Math.pow(1/.7,e),new zo(this.h,this.s,this.l*e,this.opacity)},darker:function(e){return e=null==e?.7:Math.pow(.7,e),new zo(this.h,this.s,this.l*e,this.opacity)},rgb:function(){var e=this.h%360+360*(this.h<0),t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*t,a=2*n-r;return new Ho(Vo(e>=240?e-240:e+120,a,r),Vo(e,a,r),Vo(e<120?e+240:e-120,a,r),this.opacity)},displayable:function(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1}}));var Uo=Math.PI/180,Ko=180/Math.PI,Go=.96422,qo=1,Zo=.82521,Qo=4/29,Xo=6/29,Jo=3*Xo*Xo,$o=Xo*Xo*Xo;function ei(e){if(e instanceof ni)return new ni(e.l,e.a,e.b,e.opacity);if(e instanceof li){if(isNaN(e.h))return new ni(e.l,0,0,e.opacity);var t=e.h*Uo;return new ni(e.l,Math.cos(t)*e.c,Math.sin(t)*e.c,e.opacity)}e instanceof Ho||(e=_o(e));var n,r,a=ii(e.r),o=ii(e.g),i=ii(e.b),s=ri((.2225045*a+.7168786*o+.0606169*i)/qo);return a===o&&o===i?n=r=s:(n=ri((.4360747*a+.3850649*o+.1430804*i)/Go),r=ri((.0139322*a+.0971045*o+.7141733*i)/Zo)),new ni(116*s-16,500*(n-s),200*(s-r),e.opacity)}function ti(e,t,n,r){return 1===arguments.length?ei(e):new ni(e,t,n,null==r?1:r)}function ni(e,t,n,r){this.l=+e,this.a=+t,this.b=+n,this.opacity=+r}function ri(e){return e>$o?Math.pow(e,1/3):e/Jo+Qo}function ai(e){return e>Xo?e*e*e:Jo*(e-Qo)}function oi(e){return 255*(e<=.0031308?12.92*e:1.055*Math.pow(e,1/2.4)-.055)}function ii(e){return(e/=255)<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4)}function si(e){if(e instanceof li)return new li(e.h,e.c,e.l,e.opacity);if(e instanceof ni||(e=ei(e)),0===e.a&&0===e.b)return new li(NaN,0,e.l,e.opacity);var t=Math.atan2(e.b,e.a)*Ko;return new li(t<0?t+360:t,Math.sqrt(e.a*e.a+e.b*e.b),e.l,e.opacity)}function ui(e,t,n,r){return 1===arguments.length?si(e):new li(e,t,n,null==r?1:r)}function li(e,t,n,r){this.h=+e,this.c=+t,this.l=+n,this.opacity=+r}go(ni,ti,Ao(ko,{brighter:function(e){return new ni(this.l+18*(null==e?1:e),this.a,this.b,this.opacity)},darker:function(e){return new ni(this.l-18*(null==e?1:e),this.a,this.b,this.opacity)},rgb:function(){var e=(this.l+16)/116,t=isNaN(this.a)?e:e+this.a/500,n=isNaN(this.b)?e:e-this.b/200;return new Ho(oi(3.1338561*(t=Go*ai(t))-1.6168667*(e=qo*ai(e))-.4906146*(n=Zo*ai(n))),oi(-.9787684*t+1.9161415*e+.033454*n),oi(.0719453*t-.2289914*e+1.4052427*n),this.opacity)}})),go(li,ui,Ao(ko,{brighter:function(e){return new li(this.h,this.c,this.l+18*(null==e?1:e),this.opacity)},darker:function(e){return new li(this.h,this.c,this.l-18*(null==e?1:e),this.opacity)},rgb:function(){return ei(this).rgb()}}));var ci=-.14861,di=1.78277,fi=-.29227,pi=-.90649,hi=1.97294,mi=hi*pi,yi=hi*di,vi=di*fi-pi*ci;function bi(e,t,n,r){return 1===arguments.length?function(e){if(e instanceof gi)return new gi(e.h,e.s,e.l,e.opacity);e instanceof Ho||(e=_o(e));var t=e.r/255,n=e.g/255,r=e.b/255,a=(vi*r+mi*t-yi*n)/(vi+mi-yi),o=r-a,i=(hi*(n-a)-fi*o)/pi,s=Math.sqrt(i*i+o*o)/(hi*a*(1-a)),u=s?Math.atan2(i,o)*Ko-120:NaN;return new gi(u<0?u+360:u,s,a,e.opacity)}(e):new gi(e,t,n,null==r?1:r)}function gi(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}function Ai(e,t,n,r,a){var o=e*e,i=o*e;return((1-3*e+3*o-i)*t+(4-6*o+3*i)*n+(1+3*e+3*o-3*i)*r+i*a)/6}go(gi,bi,Ao(ko,{brighter:function(e){return e=null==e?1/.7:Math.pow(1/.7,e),new gi(this.h,this.s,this.l*e,this.opacity)},darker:function(e){return e=null==e?.7:Math.pow(.7,e),new gi(this.h,this.s,this.l*e,this.opacity)},rgb:function(){var e=isNaN(this.h)?0:(this.h+120)*Uo,t=+this.l,n=isNaN(this.s)?0:this.s*t*(1-t),r=Math.cos(e),a=Math.sin(e);return new Ho(255*(t+n*(ci*r+di*a)),255*(t+n*(fi*r+pi*a)),255*(t+n*(hi*r)),this.opacity)}}));var ki=function(e){return function(){return e}};function Mi(e,t){return function(n){return e+n*t}}function wi(e,t){var n=t-e;return n?Mi(e,n>180||n<-180?n-360*Math.round(n/360):n):ki(isNaN(e)?t:e)}function xi(e){return 1==(e=+e)?Si:function(t,n){return n-t?function(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(r){return Math.pow(e+r*t,n)}}(t,n,e):ki(isNaN(t)?n:t)}}function Si(e,t){var n=t-e;return n?Mi(e,n):ki(isNaN(e)?t:e)}var Di=function e(t){var n=xi(t);function r(e,t){var r=n((e=Io(e)).r,(t=Io(t)).r),a=n(e.g,t.g),o=n(e.b,t.b),i=Si(e.opacity,t.opacity);return function(t){return e.r=r(t),e.g=a(t),e.b=o(t),e.opacity=i(t),e+""}}return r.gamma=e,r}(1);function Ti(e){return function(t){var n,r,a=t.length,o=new Array(a),i=new Array(a),s=new Array(a);for(n=0;n=1?(n=1,t-1):Math.floor(n*t),a=e[r],o=e[r+1],i=r>0?e[r-1]:2*a-o,s=ro&&(a=t.slice(o,a),s[i]?s[i]+=a:s[++i]=a),(n=n[0])===(r=r[0])?s[i]?s[i]+=r:s[++i]=r:(s[++i]=null,u.push({i:i,x:Oi(n,r)})),o=Li.lastIndex;return o180?t+=360:t-e>180&&(e+=360),o.push({i:n.push(a(n)+"rotate(",null,r)-2,x:Oi(e,t)})):t&&n.push(a(n)+"rotate("+t+r)}(o.rotate,i.rotate,s,u),function(e,t,n,o){e!==t?o.push({i:n.push(a(n)+"skewX(",null,r)-2,x:Oi(e,t)}):t&&n.push(a(n)+"skewX("+t+r)}(o.skewX,i.skewX,s,u),function(e,t,n,r,o,i){if(e!==n||t!==r){var s=o.push(a(o)+"scale(",null,",",null,")");i.push({i:s-4,x:Oi(e,n)},{i:s-2,x:Oi(t,r)})}else 1===n&&1===r||o.push(a(o)+"scale("+n+","+r+")")}(o.scaleX,o.scaleY,i.scaleX,i.scaleY,s,u),o=i=null,function(e){for(var t,n=-1,r=u.length;++n2?Zi:qi,r=a=null,c}function c(t){return(r||(r=n(o,i,u?function(e){return function(t,n){var r=e(t=+t,n=+n);return function(e){return e<=t?0:e>=n?1:r(e)}}}(e):e,s)))(+t)}return c.invert=function(e){return(a||(a=n(i,o,Gi,u?function(e){return function(t,n){var r=e(t=+t,n=+n);return function(e){return e<=0?t:e>=1?n:r(e)}}}(t):t)))(+e)},c.domain=function(e){return arguments.length?(o=po.call(e,Ui),l()):o.slice()},c.range=function(e){return arguments.length?(i=ho.call(e),l()):i.slice()},c.rangeRound=function(e){return i=ho.call(e),s=Ni,l()},c.clamp=function(e){return arguments.length?(u=!!e,l()):u},c.interpolate=function(e){return arguments.length?(s=e,l()):s},l()}var Ji=function(e,t){if((n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"))<0)return null;var n,r=e.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+e.slice(n+1)]},$i=function(e){return(e=Ji(Math.abs(e)))?e[1]:NaN},es=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function ts(e){return new ns(e)}function ns(e){if(!(t=es.exec(e)))throw new Error("invalid format: "+e);var t;this.fill=t[1]||" ",this.align=t[2]||">",this.sign=t[3]||"-",this.symbol=t[4]||"",this.zero=!!t[5],this.width=t[6]&&+t[6],this.comma=!!t[7],this.precision=t[8]&&+t[8].slice(1),this.trim=!!t[9],this.type=t[10]||""}ts.prototype=ns.prototype,ns.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(null==this.width?"":Math.max(1,0|this.width))+(this.comma?",":"")+(null==this.precision?"":"."+Math.max(0,0|this.precision))+(this.trim?"~":"")+this.type};var rs,as,os,is,ss=function(e){e:for(var t,n=e.length,r=1,a=-1;r0){if(!+e[r])break e;a=0}}return a>0?e.slice(0,a)+e.slice(t+1):e},us=function(e,t){var n=Ji(e,t);if(!n)return e+"";var r=n[0],a=n[1];return a<0?"0."+new Array(-a).join("0")+r:r.length>a+1?r.slice(0,a+1)+"."+r.slice(a+1):r+new Array(a-r.length+2).join("0")},ls={"%":function(e,t){return(100*e).toFixed(t)},b:function(e){return Math.round(e).toString(2)},c:function(e){return e+""},d:function(e){return Math.round(e).toString(10)},e:function(e,t){return e.toExponential(t)},f:function(e,t){return e.toFixed(t)},g:function(e,t){return e.toPrecision(t)},o:function(e){return Math.round(e).toString(8)},p:function(e,t){return us(100*e,t)},r:us,s:function(e,t){var n=Ji(e,t);if(!n)return e+"";var r=n[0],a=n[1],o=a-(rs=3*Math.max(-8,Math.min(8,Math.floor(a/3))))+1,i=r.length;return o===i?r:o>i?r+new Array(o-i+1).join("0"):o>0?r.slice(0,o)+"."+r.slice(o):"0."+new Array(1-o).join("0")+Ji(e,Math.max(0,t+o-1))[0]},X:function(e){return Math.round(e).toString(16).toUpperCase()},x:function(e){return Math.round(e).toString(16)}},cs=function(e){return e},ds=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];as=function(e){var t,n,r=e.grouping&&e.thousands?(t=e.grouping,n=e.thousands,function(e,r){for(var a=e.length,o=[],i=0,s=t[0],u=0;a>0&&s>0&&(u+s+1>r&&(s=Math.max(1,r-u)),o.push(e.substring(a-=s,a+s)),!((u+=s+1)>r));)s=t[i=(i+1)%t.length];return o.reverse().join(n)}):cs,a=e.currency,o=e.decimal,i=e.numerals?function(e){return function(t){return t.replace(/[0-9]/g,function(t){return e[+t]})}}(e.numerals):cs,s=e.percent||"%";function u(e){var t=(e=ts(e)).fill,n=e.align,u=e.sign,l=e.symbol,c=e.zero,d=e.width,f=e.comma,p=e.precision,h=e.trim,m=e.type;"n"===m?(f=!0,m="g"):ls[m]||(null==p&&(p=12),h=!0,m="g"),(c||"0"===t&&"="===n)&&(c=!0,t="0",n="=");var y="$"===l?a[0]:"#"===l&&/[boxX]/.test(m)?"0"+m.toLowerCase():"",v="$"===l?a[1]:/[%p]/.test(m)?s:"",b=ls[m],g=/[defgprs%]/.test(m);function A(e){var a,s,l,A=y,k=v;if("c"===m)k=b(e)+k,e="";else{var M=(e=+e)<0;if(e=b(Math.abs(e),p),h&&(e=ss(e)),M&&0==+e&&(M=!1),A=(M?"("===u?u:"-":"-"===u||"("===u?"":u)+A,k=("s"===m?ds[8+rs/3]:"")+k+(M&&"("===u?")":""),g)for(a=-1,s=e.length;++a(l=e.charCodeAt(a))||l>57){k=(46===l?o+e.slice(a+1):e.slice(a))+k,e=e.slice(0,a);break}}f&&!c&&(e=r(e,1/0));var w=A.length+e.length+k.length,x=w>1)+A+e+k+x.slice(w);break;default:e=x+A+e+k}return i(e)}return p=null==p?6:/[gprs]/.test(m)?Math.max(1,Math.min(21,p)):Math.max(0,Math.min(20,p)),A.toString=function(){return e+""},A}return{format:u,formatPrefix:function(e,t){var n=u(((e=ts(e)).type="f",e)),r=3*Math.max(-8,Math.min(8,Math.floor($i(t)/3))),a=Math.pow(10,-r),o=ds[8+r/3];return function(e){return n(a*e)+o}}}}({decimal:".",thousands:",",grouping:[3],currency:["$",""]}),os=as.format,is=as.formatPrefix;var fs=function(e,t,n){var r,a=e[0],o=e[e.length-1],i=ro(a,o,null==t?10:t);switch((n=ts(null==n?",f":n)).type){case"s":var s=Math.max(Math.abs(a),Math.abs(o));return null!=n.precision||isNaN(r=function(e,t){return Math.max(0,3*Math.max(-8,Math.min(8,Math.floor($i(t)/3)))-$i(Math.abs(e)))}(i,s))||(n.precision=r),is(n,s);case"":case"e":case"g":case"p":case"r":null!=n.precision||isNaN(r=function(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,$i(t)-$i(e))+1}(i,Math.max(Math.abs(a),Math.abs(o))))||(n.precision=r-("e"===n.type));break;case"f":case"%":null!=n.precision||isNaN(r=function(e){return Math.max(0,-$i(Math.abs(e)))}(i))||(n.precision=r-2*("%"===n.type))}return os(n)};function ps(e){var t=e.domain;return e.ticks=function(e){var n=t();return to(n[0],n[n.length-1],null==e?10:e)},e.tickFormat=function(e,n){return fs(t(),e,n)},e.nice=function(n){null==n&&(n=10);var r,a=t(),o=0,i=a.length-1,s=a[o],u=a[i];return u0?r=no(s=Math.floor(s/r)*r,u=Math.ceil(u/r)*r,n):r<0&&(r=no(s=Math.ceil(s*r)/r,u=Math.floor(u*r)/r,n)),r>0?(a[o]=Math.floor(s/r)*r,a[i]=Math.ceil(u/r)*r,t(a)):r<0&&(a[o]=Math.ceil(s*r)/r,a[i]=Math.floor(u*r)/r,t(a)),e},e}function hs(){var e=Xi(Gi,Oi);return e.copy=function(){return Qi(e,hs())},ps(e)}function ms(){var e=[0,1];function t(e){return+e}return t.invert=t,t.domain=t.range=function(n){return arguments.length?(e=po.call(n,Ui),t):e.slice()},t.copy=function(){return ms().domain(e)},ps(t)}var ys=function(e,t){var n,r=0,a=(e=e.slice()).length-1,o=e[r],i=e[a];return i0){for(;fu)break;m.push(d)}}else for(;f=1;--c)if(!((d=l*c)u)break;m.push(d)}}else m=to(f,p,Math.min(p-f,h)).map(a);return o?m.reverse():m},e.tickFormat=function(t,o){if(null==o&&(o=10===n?".0e":","),"function"!=typeof o&&(o=os(o)),t===1/0)return o;null==t&&(t=10);var i=Math.max(1,n*t/e.ticks().length);return function(e){var t=e/a(Math.round(r(e)));return t*n0?n[a-1]:e[0],a=n?[r[n-1],t]:[r[i-1],r[i]]},o.copy=function(){return Os().domain([e,t]).range(a)},ps(o)}function Ps(){var e=[.5],t=[0,1],n=1;function r(r){if(r<=r)return t[qa(e,r,0,n)]}return r.domain=function(a){return arguments.length?(e=ho.call(a),n=Math.min(e.length,t.length-1),r):e.slice()},r.range=function(a){return arguments.length?(t=ho.call(a),n=Math.min(e.length,t.length-1),r):t.slice()},r.invertExtent=function(n){var r=t.indexOf(n);return[e[r-1],e[r]]},r.copy=function(){return Ps().domain(e).range(t)},r}var Ls=new Date,Es=new Date;function js(e,t,n,r){function a(t){return e(t=new Date(+t)),t}return a.floor=a,a.ceil=function(n){return e(n=new Date(n-1)),t(n,1),e(n),n},a.round=function(e){var t=a(e),n=a.ceil(e);return e-t0))return s;do{s.push(i=new Date(+n)),t(n,o),e(n)}while(i=t)for(;e(t),!n(t);)t.setTime(t-1)},function(e,r){if(e>=e)if(r<0)for(;++r<=0;)for(;t(e,-1),!n(e););else for(;--r>=0;)for(;t(e,1),!n(e););})},n&&(a.count=function(t,r){return Ls.setTime(+t),Es.setTime(+r),e(Ls),e(Es),Math.floor(n(Ls,Es))},a.every=function(e){return e=Math.floor(e),isFinite(e)&&e>0?e>1?a.filter(r?function(t){return r(t)%e==0}:function(t){return a.count(0,t)%e==0}):a:null}),a}var Cs=js(function(){},function(e,t){e.setTime(+e+t)},function(e,t){return t-e});Cs.every=function(e){return e=Math.floor(e),isFinite(e)&&e>0?e>1?js(function(t){t.setTime(Math.floor(t/e)*e)},function(t,n){t.setTime(+t+n*e)},function(t,n){return(n-t)/e}):Cs:null};var Ys=Cs,Rs=(Cs.range,6e4),Ns=6048e5,_s=js(function(e){e.setTime(e-e.getMilliseconds())},function(e,t){e.setTime(+e+1e3*t)},function(e,t){return(t-e)/1e3},function(e){return e.getUTCSeconds()}),Is=_s,Hs=(_s.range,js(function(e){e.setTime(e-e.getMilliseconds()-1e3*e.getSeconds())},function(e,t){e.setTime(+e+t*Rs)},function(e,t){return(t-e)/Rs},function(e){return e.getMinutes()})),Fs=Hs,Bs=(Hs.range,js(function(e){e.setTime(e-e.getMilliseconds()-1e3*e.getSeconds()-e.getMinutes()*Rs)},function(e,t){e.setTime(+e+36e5*t)},function(e,t){return(t-e)/36e5},function(e){return e.getHours()})),Ws=Bs,zs=(Bs.range,js(function(e){e.setHours(0,0,0,0)},function(e,t){e.setDate(e.getDate()+t)},function(e,t){return(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*Rs)/864e5},function(e){return e.getDate()-1})),Vs=zs;zs.range;function Us(e){return js(function(t){t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)},function(e,t){e.setDate(e.getDate()+7*t)},function(e,t){return(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*Rs)/Ns})}var Ks=Us(0),Gs=Us(1),qs=Us(2),Zs=Us(3),Qs=Us(4),Xs=Us(5),Js=Us(6),$s=(Ks.range,Gs.range,qs.range,Zs.range,Qs.range,Xs.range,Js.range,js(function(e){e.setDate(1),e.setHours(0,0,0,0)},function(e,t){e.setMonth(e.getMonth()+t)},function(e,t){return t.getMonth()-e.getMonth()+12*(t.getFullYear()-e.getFullYear())},function(e){return e.getMonth()})),eu=$s,tu=($s.range,js(function(e){e.setMonth(0,1),e.setHours(0,0,0,0)},function(e,t){e.setFullYear(e.getFullYear()+t)},function(e,t){return t.getFullYear()-e.getFullYear()},function(e){return e.getFullYear()}));tu.every=function(e){return isFinite(e=Math.floor(e))&&e>0?js(function(t){t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)},function(t,n){t.setFullYear(t.getFullYear()+n*e)}):null};var nu=tu,ru=(tu.range,js(function(e){e.setUTCSeconds(0,0)},function(e,t){e.setTime(+e+t*Rs)},function(e,t){return(t-e)/Rs},function(e){return e.getUTCMinutes()})),au=ru,ou=(ru.range,js(function(e){e.setUTCMinutes(0,0,0)},function(e,t){e.setTime(+e+36e5*t)},function(e,t){return(t-e)/36e5},function(e){return e.getUTCHours()})),iu=ou,su=(ou.range,js(function(e){e.setUTCHours(0,0,0,0)},function(e,t){e.setUTCDate(e.getUTCDate()+t)},function(e,t){return(t-e)/864e5},function(e){return e.getUTCDate()-1})),uu=su;su.range;function lu(e){return js(function(t){t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)},function(e,t){e.setUTCDate(e.getUTCDate()+7*t)},function(e,t){return(t-e)/Ns})}var cu=lu(0),du=lu(1),fu=lu(2),pu=lu(3),hu=lu(4),mu=lu(5),yu=lu(6),vu=(cu.range,du.range,fu.range,pu.range,hu.range,mu.range,yu.range,js(function(e){e.setUTCDate(1),e.setUTCHours(0,0,0,0)},function(e,t){e.setUTCMonth(e.getUTCMonth()+t)},function(e,t){return t.getUTCMonth()-e.getUTCMonth()+12*(t.getUTCFullYear()-e.getUTCFullYear())},function(e){return e.getUTCMonth()})),bu=vu,gu=(vu.range,js(function(e){e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},function(e,t){e.setUTCFullYear(e.getUTCFullYear()+t)},function(e,t){return t.getUTCFullYear()-e.getUTCFullYear()},function(e){return e.getUTCFullYear()}));gu.every=function(e){return isFinite(e=Math.floor(e))&&e>0?js(function(t){t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},function(t,n){t.setUTCFullYear(t.getUTCFullYear()+n*e)}):null};var Au=gu;gu.range;function ku(e){if(0<=e.y&&e.y<100){var t=new Date(-1,e.m,e.d,e.H,e.M,e.S,e.L);return t.setFullYear(e.y),t}return new Date(e.y,e.m,e.d,e.H,e.M,e.S,e.L)}function Mu(e){if(0<=e.y&&e.y<100){var t=new Date(Date.UTC(-1,e.m,e.d,e.H,e.M,e.S,e.L));return t.setUTCFullYear(e.y),t}return new Date(Date.UTC(e.y,e.m,e.d,e.H,e.M,e.S,e.L))}function wu(e){return{y:e,m:0,d:1,H:0,M:0,S:0,L:0}}var xu,Su,Du,Tu,Ou={"-":"",_:" ",0:"0"},Pu=/^\s*\d+/,Lu=/^%/,Eu=/[\\^$*+?|[\]().{}]/g;function ju(e,t,n){var r=e<0?"-":"",a=(r?-e:e)+"",o=a.length;return r+(o68?1900:2e3),n+r[0].length):-1}function zu(e,t,n){var r=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(t.slice(n,n+6));return r?(e.Z=r[1]?0:-(r[2]+(r[3]||"00")),n+r[0].length):-1}function Vu(e,t,n){var r=Pu.exec(t.slice(n,n+2));return r?(e.m=r[0]-1,n+r[0].length):-1}function Uu(e,t,n){var r=Pu.exec(t.slice(n,n+2));return r?(e.d=+r[0],n+r[0].length):-1}function Ku(e,t,n){var r=Pu.exec(t.slice(n,n+3));return r?(e.m=0,e.d=+r[0],n+r[0].length):-1}function Gu(e,t,n){var r=Pu.exec(t.slice(n,n+2));return r?(e.H=+r[0],n+r[0].length):-1}function qu(e,t,n){var r=Pu.exec(t.slice(n,n+2));return r?(e.M=+r[0],n+r[0].length):-1}function Zu(e,t,n){var r=Pu.exec(t.slice(n,n+2));return r?(e.S=+r[0],n+r[0].length):-1}function Qu(e,t,n){var r=Pu.exec(t.slice(n,n+3));return r?(e.L=+r[0],n+r[0].length):-1}function Xu(e,t,n){var r=Pu.exec(t.slice(n,n+6));return r?(e.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function Ju(e,t,n){var r=Lu.exec(t.slice(n,n+1));return r?n+r[0].length:-1}function $u(e,t,n){var r=Pu.exec(t.slice(n));return r?(e.Q=+r[0],n+r[0].length):-1}function el(e,t,n){var r=Pu.exec(t.slice(n));return r?(e.Q=1e3*+r[0],n+r[0].length):-1}function tl(e,t){return ju(e.getDate(),t,2)}function nl(e,t){return ju(e.getHours(),t,2)}function rl(e,t){return ju(e.getHours()%12||12,t,2)}function al(e,t){return ju(1+Vs.count(nu(e),e),t,3)}function ol(e,t){return ju(e.getMilliseconds(),t,3)}function il(e,t){return ol(e,t)+"000"}function sl(e,t){return ju(e.getMonth()+1,t,2)}function ul(e,t){return ju(e.getMinutes(),t,2)}function ll(e,t){return ju(e.getSeconds(),t,2)}function cl(e){var t=e.getDay();return 0===t?7:t}function dl(e,t){return ju(Ks.count(nu(e),e),t,2)}function fl(e,t){var n=e.getDay();return e=n>=4||0===n?Qs(e):Qs.ceil(e),ju(Qs.count(nu(e),e)+(4===nu(e).getDay()),t,2)}function pl(e){return e.getDay()}function hl(e,t){return ju(Gs.count(nu(e),e),t,2)}function ml(e,t){return ju(e.getFullYear()%100,t,2)}function yl(e,t){return ju(e.getFullYear()%1e4,t,4)}function vl(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+ju(t/60|0,"0",2)+ju(t%60,"0",2)}function bl(e,t){return ju(e.getUTCDate(),t,2)}function gl(e,t){return ju(e.getUTCHours(),t,2)}function Al(e,t){return ju(e.getUTCHours()%12||12,t,2)}function kl(e,t){return ju(1+uu.count(Au(e),e),t,3)}function Ml(e,t){return ju(e.getUTCMilliseconds(),t,3)}function wl(e,t){return Ml(e,t)+"000"}function xl(e,t){return ju(e.getUTCMonth()+1,t,2)}function Sl(e,t){return ju(e.getUTCMinutes(),t,2)}function Dl(e,t){return ju(e.getUTCSeconds(),t,2)}function Tl(e){var t=e.getUTCDay();return 0===t?7:t}function Ol(e,t){return ju(cu.count(Au(e),e),t,2)}function Pl(e,t){var n=e.getUTCDay();return e=n>=4||0===n?hu(e):hu.ceil(e),ju(hu.count(Au(e),e)+(4===Au(e).getUTCDay()),t,2)}function Ll(e){return e.getUTCDay()}function El(e,t){return ju(du.count(Au(e),e),t,2)}function jl(e,t){return ju(e.getUTCFullYear()%100,t,2)}function Cl(e,t){return ju(e.getUTCFullYear()%1e4,t,4)}function Yl(){return"+0000"}function Rl(){return"%"}function Nl(e){return+e}function _l(e){return Math.floor(+e/1e3)}!function(e){xu=function(e){var t=e.dateTime,n=e.date,r=e.time,a=e.periods,o=e.days,i=e.shortDays,s=e.months,u=e.shortMonths,l=Yu(a),c=Ru(a),d=Yu(o),f=Ru(o),p=Yu(i),h=Ru(i),m=Yu(s),y=Ru(s),v=Yu(u),b=Ru(u),g={a:function(e){return i[e.getDay()]},A:function(e){return o[e.getDay()]},b:function(e){return u[e.getMonth()]},B:function(e){return s[e.getMonth()]},c:null,d:tl,e:tl,f:il,H:nl,I:rl,j:al,L:ol,m:sl,M:ul,p:function(e){return a[+(e.getHours()>=12)]},Q:Nl,s:_l,S:ll,u:cl,U:dl,V:fl,w:pl,W:hl,x:null,X:null,y:ml,Y:yl,Z:vl,"%":Rl},A={a:function(e){return i[e.getUTCDay()]},A:function(e){return o[e.getUTCDay()]},b:function(e){return u[e.getUTCMonth()]},B:function(e){return s[e.getUTCMonth()]},c:null,d:bl,e:bl,f:wl,H:gl,I:Al,j:kl,L:Ml,m:xl,M:Sl,p:function(e){return a[+(e.getUTCHours()>=12)]},Q:Nl,s:_l,S:Dl,u:Tl,U:Ol,V:Pl,w:Ll,W:El,x:null,X:null,y:jl,Y:Cl,Z:Yl,"%":Rl},k={a:function(e,t,n){var r=p.exec(t.slice(n));return r?(e.w=h[r[0].toLowerCase()],n+r[0].length):-1},A:function(e,t,n){var r=d.exec(t.slice(n));return r?(e.w=f[r[0].toLowerCase()],n+r[0].length):-1},b:function(e,t,n){var r=v.exec(t.slice(n));return r?(e.m=b[r[0].toLowerCase()],n+r[0].length):-1},B:function(e,t,n){var r=m.exec(t.slice(n));return r?(e.m=y[r[0].toLowerCase()],n+r[0].length):-1},c:function(e,n,r){return x(e,t,n,r)},d:Uu,e:Uu,f:Xu,H:Gu,I:Gu,j:Ku,L:Qu,m:Vu,M:qu,p:function(e,t,n){var r=l.exec(t.slice(n));return r?(e.p=c[r[0].toLowerCase()],n+r[0].length):-1},Q:$u,s:el,S:Zu,u:_u,U:Iu,V:Hu,w:Nu,W:Fu,x:function(e,t,r){return x(e,n,t,r)},X:function(e,t,n){return x(e,r,t,n)},y:Wu,Y:Bu,Z:zu,"%":Ju};function M(e,t){return function(n){var r,a,o,i=[],s=-1,u=0,l=e.length;for(n instanceof Date||(n=new Date(+n));++s53)return null;"w"in o||(o.w=1),"Z"in o?(a=(r=Mu(wu(o.y))).getUTCDay(),r=a>4||0===a?du.ceil(r):du(r),r=uu.offset(r,7*(o.V-1)),o.y=r.getUTCFullYear(),o.m=r.getUTCMonth(),o.d=r.getUTCDate()+(o.w+6)%7):(a=(r=t(wu(o.y))).getDay(),r=a>4||0===a?Gs.ceil(r):Gs(r),r=Vs.offset(r,7*(o.V-1)),o.y=r.getFullYear(),o.m=r.getMonth(),o.d=r.getDate()+(o.w+6)%7)}else("W"in o||"U"in o)&&("w"in o||(o.w="u"in o?o.u%7:"W"in o?1:0),a="Z"in o?Mu(wu(o.y)).getUTCDay():t(wu(o.y)).getDay(),o.m=0,o.d="W"in o?(o.w+6)%7+7*o.W-(a+5)%7:o.w+7*o.U-(a+6)%7);return"Z"in o?(o.H+=o.Z/100|0,o.M+=o.Z%100,Mu(o)):t(o)}}function x(e,t,n,r){for(var a,o,i=0,s=t.length,u=n.length;i=u)return-1;if(37===(a=t.charCodeAt(i++))){if(a=t.charAt(i++),!(o=k[a in Ou?t.charAt(i++):a])||(r=o(e,n,r))<0)return-1}else if(a!=n.charCodeAt(r++))return-1}return r}return g.x=M(n,g),g.X=M(r,g),g.c=M(t,g),A.x=M(n,A),A.X=M(r,A),A.c=M(t,A),{format:function(e){var t=M(e+="",g);return t.toString=function(){return e},t},parse:function(e){var t=w(e+="",ku);return t.toString=function(){return e},t},utcFormat:function(e){var t=M(e+="",A);return t.toString=function(){return e},t},utcParse:function(e){var t=w(e,Mu);return t.toString=function(){return e},t}}}(e),Su=xu.format,xu.parse,Du=xu.utcFormat,Tu=xu.utcParse}({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});Date.prototype.toISOString||Du("%Y-%m-%dT%H:%M:%S.%LZ");+new Date("2000-01-01T00:00:00.000Z")||Tu("%Y-%m-%dT%H:%M:%S.%LZ");var Il=1e3,Hl=60*Il,Fl=60*Hl,Bl=24*Fl,Wl=7*Bl,zl=30*Bl,Vl=365*Bl;function Ul(e){return new Date(e)}function Kl(e){return e instanceof Date?+e:+new Date(+e)}function Gl(e,t,n,r,a,o,i,s,u){var l=Xi(Gi,Oi),c=l.invert,d=l.domain,f=u(".%L"),p=u(":%S"),h=u("%I:%M"),m=u("%I %p"),y=u("%a %d"),v=u("%b %d"),b=u("%B"),g=u("%Y"),A=[[i,1,Il],[i,5,5*Il],[i,15,15*Il],[i,30,30*Il],[o,1,Hl],[o,5,5*Hl],[o,15,15*Hl],[o,30,30*Hl],[a,1,Fl],[a,3,3*Fl],[a,6,6*Fl],[a,12,12*Fl],[r,1,Bl],[r,2,2*Bl],[n,1,Wl],[t,1,zl],[t,3,3*zl],[e,1,Vl]];function k(s){return(i(s)=0&&a===+a?"".concat(a,"px"):a),";");var r,a,o},"")},yc=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(null==e||me())return{width:0,height:0};var n="".concat(e),r=mc(t),a="".concat(n,"-").concat(r);if(fc.widthCache[a])return fc.widthCache[a];try{var o=document.getElementById("recharts_measurement_span");o||((o=document.createElement("span")).setAttribute("id","recharts_measurement_span"),document.body.appendChild(o));var i=function(e){for(var t=1;t2e3&&(fc.cacheCount=0,fc.widthCache={}),u}catch(e){return{width:0,height:0}}};function vc(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function bc(e){return(bc="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})(e)}function gc(){return(gc=Object.assign||function(e){for(var t=1;t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}function kc(e,t){for(var n=0;n=0?1:-1;"insideStart"===i?(r=h+g*u,a=y):"insideEnd"===i?(r=m-g*u,a=!y):"end"===i&&(r=m+g*u,a=y),a=b<=0?a:!a;var A=If(c,d,v,r),k=If(c,d,v,r+359*(a?1:-1)),M="M".concat(A.x,",").concat(A.y,"\n A").concat(v,",").concat(v,",0,1,").concat(a?0:1,",\n ").concat(k.x,",").concat(k.y),w=D()(e.id)?K("recharts-radial-line-"):e.id;return o.a.createElement("text",Pc({},n,{dominantBaseline:"central",className:O()("recharts-radial-bar-label",l)}),o.a.createElement("defs",null,o.a.createElement("path",{id:w,d:M})),o.a.createElement("textPath",{xlinkHref:"#".concat(w)},t))},Nc=function(e){var t=e.viewBox,n=e.offset,r=e.position,a=t.cx,o=t.cy,i=t.innerRadius,s=t.outerRadius,u=(t.startAngle+t.endAngle)/2;if("outside"===r){var l=If(a,o,s+n,u),c=l.x;return{x:c,y:l.y,textAnchor:c>=a?"start":"end",verticalAnchor:"middle"}}if("center"===r)return{x:a,y:o,textAnchor:"middle",verticalAnchor:"middle"};if("centerTop"===r)return{x:a,y:o,textAnchor:"middle",verticalAnchor:"start"};if("centerBottom"===r)return{x:a,y:o,textAnchor:"middle",verticalAnchor:"end"};var d=If(a,o,(i+s)/2,u);return{x:d.x,y:d.y,textAnchor:"middle",verticalAnchor:"middle"}},_c=function(e){var t=e.viewBox,n=e.offset,r=e.position,a=t.x,o=t.y,i=t.width,s=t.height,u=s>=0?1:-1;return"top"===r?{x:a+i/2,y:o-u*n,textAnchor:"middle",verticalAnchor:u>0?"end":"start"}:"bottom"===r?{x:a+i/2,y:o+s+u*n,textAnchor:"middle",verticalAnchor:"start"}:"left"===r?{x:a-n,y:o+s/2,textAnchor:"end",verticalAnchor:"middle"}:"right"===r?{x:a+i+n,y:o+s/2,textAnchor:"start",verticalAnchor:"middle"}:"insideLeft"===r?{x:a+n,y:o+s/2,textAnchor:"start",verticalAnchor:"middle"}:"insideRight"===r?{x:a+i-n,y:o+s/2,textAnchor:"end",verticalAnchor:"middle"}:"insideTop"===r?{x:a+i/2,y:o+u*n,textAnchor:"middle",verticalAnchor:"start"}:"insideBottom"===r?{x:a+i/2,y:o+s-u*n,textAnchor:"middle",verticalAnchor:"end"}:"insideTopLeft"===r?{x:a+n,y:o+u*n,textAnchor:"start",verticalAnchor:"start"}:"insideTopRight"===r?{x:a+i-n,y:o+u*n,textAnchor:"end",verticalAnchor:"start"}:"insideBottomLeft"===r?{x:a+n,y:o+s-u*n,textAnchor:"start",verticalAnchor:"end"}:"insideBottomRight"===r?{x:a+i-n,y:o+s-u*n,textAnchor:"end",verticalAnchor:"end"}:j()(r)&&(z(r.x)||W(r.x))&&(z(r.y)||W(r.y))?{x:a+G(r.x,i),y:o+G(r.y,s),textAnchor:"end",verticalAnchor:"end"}:{x:a+i/2,y:o+s/2,textAnchor:"middle",verticalAnchor:"middle"}},Ic=function(e){return z(e.cx)};function Hc(e){var t,n=e.viewBox,r=e.position,i=e.value,s=e.children,u=e.content,l=e.className,c=void 0===l?"":l;if(!n||D()(i)&&D()(s)&&!Object(a.isValidElement)(u)&&!A()(u))return null;if(Object(a.isValidElement)(u))return Object(a.cloneElement)(u,e);if(A()(u)){if(t=u(e),Object(a.isValidElement)(t))return t}else t=Yc(e);var d=Ic(n),f=le(e);if(d&&("insideStart"===r||"insideEnd"===r||"end"===r))return Rc(e,t,f);var p=d?Nc(e):_c(e);return o.a.createElement(Tc,Pc({className:O()("recharts-label",c)},f,p),t)}Hc.displayName="Label",Hc.defaultProps={offset:5},Hc.propTypes=Cc;var Fc=function(e){var t=e.cx,n=e.cy,r=e.angle,a=e.startAngle,o=e.endAngle,i=e.r,s=e.radius,u=e.innerRadius,l=e.outerRadius,c=e.x,d=e.y,f=e.top,p=e.left,h=e.width,m=e.height,y=e.clockWise;if(z(h)&&z(m)){if(z(c)&&z(d))return{x:c,y:d,width:h,height:m};if(z(f)&&z(p))return{x:f,y:p,width:h,height:m}}return z(c)&&z(d)?{x:c,y:d,width:0,height:0}:z(t)&&z(n)?{cx:t,cy:n,startAngle:a||r||0,endAngle:o||r||0,innerRadius:u||0,outerRadius:l||s||i||0,clockWise:y}:e.viewBox?e.viewBox:{}};Hc.parseViewBox=Fc,Hc.renderCallByParent=function(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];if(!e||!e.children&&n&&!e.label)return null;var r=e.children,i=Fc(e),s=se(r,Hc).map(function(e,n){return Object(a.cloneElement)(e,{viewBox:t||i,key:"label-".concat(n)})});return n?[function(e,t){return e?!0===e?o.a.createElement(Hc,{key:"label-implicit",viewBox:t}):V(e)?o.a.createElement(Hc,{key:"label-implicit",viewBox:t,value:e}):Object(a.isValidElement)(e)||A()(e)?o.a.createElement(Hc,{key:"label-implicit",content:e,viewBox:t}):j()(e)?o.a.createElement(Hc,Pc({viewBox:t},e,{key:"label-implicit"})):null:null}(e.label,t||i)].concat(Oc(s)):s};var Bc=Hc,Wc=n(104),zc=n.n(Wc);function Vc(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Uc(e,t){for(var n=0;n1&&void 0!==arguments[1]?arguments[1]:{}).bandAware;if(void 0!==e){if(t){var n=this.bandwidth?this.bandwidth()/2:0;return this.scale(e)+n}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}},{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}}]),e}();qc.EPS=1e-4;var Zc,Qc,Xc,Jc=function(){function e(t){Vc(this,e),this.scales=zc()(t,qc.create),Object.assign(this,this.scales)}return Kc(e,null,[{key:"create",value:function(e){return new this(e)}}]),Kc(e,[{key:"apply",value:function(e){var t=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).bandAware,n=this.scales;return zc()(e,function(e,r){return n[r].apply(e,{bandAware:t})})}},{key:"isInRange",value:function(e){var t=this.scales;return h()(e,function(e,n){return t[n].isInRange(e)})}}]),e}();function $c(e){return($c="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})(e)}function ed(){return(ed=Object.assign||function(e){for(var t=1;t=0?1:-1,u=r>=0?1:0;if(i>0&&a instanceof Array){for(var l=[],c=0;c<4;c++)l[c]=a[c]>i?i:a[c];o="M".concat(e,",").concat(t+s*l[0]),l[0]>0&&(o+="A ".concat(l[0],",").concat(l[0],",0,0,").concat(u,",").concat(e+l[0],",").concat(t)),o+="L ".concat(e+n-l[1],",").concat(t),l[1]>0&&(o+="A ".concat(l[1],",").concat(l[1],",0,0,").concat(u,",\n ").concat(e+n,",").concat(t+s*l[1])),o+="L ".concat(e+n,",").concat(t+r-s*l[2]),l[2]>0&&(o+="A ".concat(l[2],",").concat(l[2],",0,0,").concat(u,",\n ").concat(e+n-l[2],",").concat(t+r)),o+="L ".concat(e+l[3],",").concat(t+r),l[3]>0&&(o+="A ".concat(l[3],",").concat(l[3],",0,0,").concat(u,",\n ").concat(e,",").concat(t+r-s*l[3])),o+="Z"}else if(i>0&&a===+a&&a>0){var d=Math.min(i,a);o="M ".concat(e,",").concat(t+s*d,"\n A ").concat(d,",").concat(d,",0,0,").concat(u,",").concat(e+d,",").concat(t,"\n L ").concat(e+n-d,",").concat(t,"\n A ").concat(d,",").concat(d,",0,0,").concat(u,",").concat(e+n,",").concat(t+s*d,"\n L ").concat(e+n,",").concat(t+r-s*d,"\n A ").concat(d,",").concat(d,",0,0,").concat(u,",").concat(e+n-d,",").concat(t+r,"\n L ").concat(e+d,",").concat(t+r,"\n A ").concat(d,",").concat(d,",0,0,").concat(u,",").concat(e,",").concat(t+r-s*d," Z")}else o="M ".concat(e,",").concat(t," h ").concat(n," v ").concat(r," h ").concat(-n," Z");return o},_d=$((xd=wd=function(e){function t(){var e,n;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);for(var r=arguments.length,a=new Array(r),o=0;o0,from:{width:a,height:i,x:n,y:r},to:{width:a,height:i,x:n,y:r},duration:f,animationEasing:d,isActive:m},function(t){var n=t.width,r=t.height,a=t.x,i=t.y;return o.a.createElement(Gt,{canBegin:l>0,from:"0px ".concat(-1===l?1:l,"px"),to:"".concat(l,"px 0px"),attributeName:"strokeDasharray",begin:p,duration:f,isActive:h,easing:d},o.a.createElement("path",Od({},le(e.props),de(e.props),{className:y,d:Nd(a,i,n,r,s),ref:function(t){e.node=t}})))}):o.a.createElement("path",Od({},le(this.props),de(this.props),{className:y,d:Nd(n,r,a,i,s)}))}}])&&Pd(n.prototype,r),i&&Pd(n,i),t}(),wd.displayName="Rectangle",wd.propTypes=function(e){for(var t=1;t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}function Xd(e,t){for(var n=0;n=0});if(o&&o.length){var i=o.map(function(e){return e.props.dataKey});return e.reduce(function(e,t){var r=sf(t,n,0),a=Y()(r)?[Fa()(r),Ia()(r)]:[r,r],o=i.reduce(function(e,n){var r=sf(t,n,0),o=a[0]-Math.abs(Y()(r)?r[0]:r),i=a[1]+Math.abs(Y()(r)?r[1]:r);return[Math.min(o,e[0]),Math.max(i,e[1])]},[1/0,-1/0]);return[Math.min(o[0],e[0]),Math.max(o[1],e[1])]},[1/0,-1/0])}return null},ff=function(e,t,n,r){var a=t.map(function(t){var a=t.props.dataKey;return"number"===n&&a&&df(e,t,a)||uf(e,a,n,r)});if("number"===n)return a.reduce(function(e,t){return[Math.min(e[0],t[0]),Math.max(e[1],t[1])]},[1/0,-1/0]);var o={};return a.reduce(function(e,t){for(var n=0,r=t.length;n=0||t.indexOf("AreaChart")>=0)?{scale:bo(),realScaleType:"point"}:"category"===a?{scale:vo(),realScaleType:"band"}:{scale:hs(),realScaleType:"linear"};if(L()(n)){var s="scale".concat(n.slice(0,1).toUpperCase()).concat(n.slice(1));return{scale:(r[s]||bo)(),realScaleType:r[s]?s:"point"}}return A()(n)?{scale:n}:{scale:bo(),realScaleType:"point"}},bf=function(e){var t=e.domain();if(t&&!(t.length<=2)){var n=t.length,r=e.range(),a=Math.min(r[0],r[1])-1e-4,o=Math.max(r[0],r[1])+1e-4,i=e(t[0]),s=e(t[n-1]);(io||so)&&e.domain([t[0],t[n-1]])}},gf={sign:function(e){var t=e.length;if(!(t<=0))for(var n=0,r=e[0].length;n=0?(e[i][n][0]=a,e[i][n][1]=a+s,a=e[i][n][1]):(e[i][n][0]=o,e[i][n][1]=o+s,o=e[i][n][1])}},expand:function(e,t){if((r=e.length)>0){for(var n,r,a,o=0,i=e[0].length;o0){for(var n,r=0,a=e[t[0]],o=a.length;r0&&(r=(n=e[t[0]]).length)>0){for(var n,r,a,o=0,i=1;i=2){for(var n=b()(t,function(e){return e.coordinate}),r=1/0,a=1,o=n.length;a2&&void 0!==arguments[2]?arguments[2]:{top:0,right:0,bottom:0,left:0};return Math.min(Math.abs(e-(n.left||0)-(n.right||0)),Math.abs(t-(n.top||0)-(n.bottom||0)))/2},Ff=function(e,t){var n,r,a,o,i,s,u=e.x,l=e.y,c=t.cx,d=t.cy,f=(r={x:c,y:d},a=(n={x:u,y:l}).x,o=n.y,i=r.x,s=r.y,Math.sqrt(Math.pow(a-i,2)+Math.pow(o-s,2)));if(f<=0)return{radius:f};var p=(u-c)/f,h=Math.acos(p);return l>d&&(h=2*Math.PI-h),{radius:f,angle:_f(h),angleInRadian:h}},Bf=function(e,t){var n=t.startAngle,r=t.endAngle,a=Math.floor(n/360),o=Math.floor(r/360);return e+360*Math.min(a,o)},Wf=function(e,t){var n=e.x,r=e.y,a=Ff({x:n,y:r},t),o=a.radius,i=a.angle,s=t.innerRadius,u=t.outerRadius;if(ou)return!1;if(0===o)return!0;var l,c=function(e){var t=e.startAngle,n=e.endAngle,r=Math.floor(t/360),a=Math.floor(n/360),o=Math.min(r,a);return{startAngle:t-360*o,endAngle:n-360*o}}(t),d=c.startAngle,f=c.endAngle,p=i;if(d<=f){for(;p>f;)p-=360;for(;p=d&&p<=f}else{for(;p>d;)p-=360;for(;p=f&&p<=d}return l?Lf({},t,{radius:o,angle:Bf(p,t)}):null};function zf(e){return(zf="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})(e)}function Vf(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Uf(){return(Uf=Object.assign||function(e){for(var t=1;t180),",").concat(+(o>s),",\n ").concat(l.x,",").concat(l.y,"\n ");if(r>0){var d=If(t,n,r,o),f=If(t,n,r,s);c+="L ".concat(f.x,",").concat(f.y,"\n A ").concat(r,",").concat(r,",0,\n ").concat(+(Math.abs(i)>180),",").concat(+(o<=s),",\n ").concat(d.x,",").concat(d.y," Z")}else c+="L ".concat(t,",").concat(n," Z");return c},Jf=$((Rf=Yf=function(e){function t(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),Gf(this,qf(t).apply(this,arguments))}var n,r,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}}),t&&Zf(e,t)}(t,a["Component"]),n=t,(r=[{key:"render",value:function(){var e=this.props,t=e.cx,n=e.cy,r=e.innerRadius,a=e.outerRadius,i=e.cornerRadius,s=e.startAngle,u=e.endAngle,l=e.className;if(a0&&Math.abs(s-u)<360?function(e){var t=e.cx,n=e.cy,r=e.innerRadius,a=e.outerRadius,o=e.cornerRadius,i=e.startAngle,s=e.endAngle,u=B(s-i),l=Qf({cx:t,cy:n,radius:a,angle:i,sign:u,cornerRadius:o}),c=l.circleTangency,d=l.lineTangency,f=l.theta,p=Qf({cx:t,cy:n,radius:a,angle:s,sign:-u,cornerRadius:o}),h=p.circleTangency,m=p.lineTangency,y=p.theta,v=Math.abs(i-s)-f-y;if(v<0)return Xf({cx:t,cy:n,innerRadius:r,outerRadius:a,startAngle:i,endAngle:s});var b="M ".concat(d.x,",").concat(d.y,"\n A").concat(o,",").concat(o,",0,0,").concat(+(u<0),",").concat(c.x,",").concat(c.y,"\n A").concat(a,",").concat(a,",0,").concat(+(v>180),",").concat(+(u<0),",").concat(h.x,",").concat(h.y,"\n A").concat(o,",").concat(o,",0,0,").concat(+(u<0),",").concat(m.x,",").concat(m.y,"\n ");if(r>0){var g=Qf({cx:t,cy:n,radius:r,angle:i,sign:u,isExternal:!0,cornerRadius:o}),A=g.circleTangency,k=g.lineTangency,M=g.theta,w=Qf({cx:t,cy:n,radius:r,angle:s,sign:-u,isExternal:!0,cornerRadius:o}),x=w.circleTangency,S=w.lineTangency,D=w.theta,T=Math.abs(i-s)-M-D;if(T<0)return"".concat(b,"L").concat(t,",").concat(n,"Z");b+="L".concat(S.x,",").concat(S.y,"\n A").concat(o,",").concat(o,",0,0,").concat(+(u<0),",").concat(x.x,",").concat(x.y,"\n A").concat(r,",").concat(r,",0,").concat(+(T>180),",").concat(+(u>0),",").concat(A.x,",").concat(A.y,"\n A").concat(o,",").concat(o,",0,0,").concat(+(u<0),",").concat(k.x,",").concat(k.y,"Z")}else b+="L".concat(t,",").concat(n,"Z");return b}({cx:t,cy:n,innerRadius:r,outerRadius:a,cornerRadius:Math.min(p,f/2),startAngle:s,endAngle:u}):Xf({cx:t,cy:n,innerRadius:r,outerRadius:a,startAngle:s,endAngle:u}),o.a.createElement("path",Uf({},le(this.props),de(this.props),{className:d,d:c}))}}])&&Kf(n.prototype,r),i&&Kf(n,i),t}(),Yf.displayName="Sector",Yf.propTypes=function(e){for(var t=1;t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}function ap(e,t){for(var n=0;n=2?B(m[1].coordinate-m[0].coordinate):1;if(1===b?(n="width"===h?c:d,r="width"===h?c+f:d+p):(n="width"===h?c+f:d+p,r="width"===h?c:d),t){var g=a[v-1],k=A()(o)?o(g.value):g.value,M=yc(k)[h]+y,w=b*(g.coordinate+b*M/2-r);m[v-1]=g=tp({},g,{tickCoord:w>0?g.coordinate-w*b:g.coordinate}),b*(g.tickCoord-b*M/2-n)>=0&&b*(g.tickCoord+b*M/2-r)<=0&&(r=g.tickCoord-b*(M/2+u),m[v-1]=tp({},g,{isShow:!0}))}for(var x=t?v-1:v,S=0;S=0&&b*(D.tickCoord+b*O/2-r)<=0&&(n=D.tickCoord+b*(O/2+u),m[S]=tp({},D,{isShow:!0}))}return m.filter(function(e){return e.isShow})}},{key:"getTicksEnd",value:function(e){var t,n,r=e.ticks,a=e.tickFormatter,o=e.viewBox,i=e.orientation,s=e.minTickGap,u=e.unit,l=o.x,c=o.y,d=o.width,f=o.height,p="top"===i||"bottom"===i?"width":"height",h=u?yc(u)[p]:0,m=(r||[]).slice(),y=m.length,v=y>=2?B(m[1].coordinate-m[0].coordinate):1;1===v?(t="width"===p?l:c,n="width"===p?l+d:c+f):(t="width"===p?l+d:c+f,n="width"===p?l:c);for(var b=y-1;b>=0;b--){var g=m[b],k=A()(a)?a(g.value):g.value,M=yc(k)[p]+h;if(b===y-1){var w=v*(g.coordinate+v*M/2-n);m[b]=g=tp({},g,{tickCoord:w>0?g.coordinate-w*v:g.coordinate})}else m[b]=g=tp({},g,{tickCoord:g.coordinate});v*(g.tickCoord-v*M/2-t)>=0&&v*(g.tickCoord+v*M/2-n)<=0&&(n=g.tickCoord-v*(M/2+s),m[b]=tp({},g,{isShow:!0}))}return m.filter(function(e){return e.isShow})}},{key:"renderTickItem",value:function(e,t,n){return o.a.isValidElement(e)?o.a.cloneElement(e,t):A()(e)?e(t):o.a.createElement(Tc,ep({},t,{className:"recharts-cartesian-axis-tick-value"}),n)}}],(r=[{key:"shouldComponentUpdate",value:function(e,t){var n=e.viewBox,r=rp(e,["viewBox"]),a=this.props,o=a.viewBox,i=rp(a,["viewBox"]);return!X(n,o)||!X(r,i)||!X(t,this.state)}},{key:"getTickLineCoord",value:function(e){var t,n,r,a,o,i,s=this.props,u=s.x,l=s.y,c=s.width,d=s.height,f=s.orientation,p=s.tickSize,h=s.mirror,m=s.tickMargin,y=h?-1:1,v=e.tickSize||p,b=z(e.tickCoord)?e.tickCoord:e.coordinate;switch(f){case"top":t=n=e.coordinate,i=(r=(a=l+!h*d)-y*v)-y*m,o=b;break;case"left":r=a=e.coordinate,o=(t=(n=u+!h*c)-y*v)-y*m,i=b;break;case"right":r=a=e.coordinate,o=(t=(n=u+h*c)+y*v)+y*m,i=b;break;default:t=n=e.coordinate,i=(r=(a=l+h*d)+y*v)+y*m,o=b}return{line:{x1:t,y1:r,x2:n,y2:a},tick:{x:o,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 e=this.props,t=e.x,n=e.y,r=e.width,a=e.height,i=e.orientation,s=e.axisLine,u=e.mirror,l=tp({},le(this.props),{fill:"none"},le(s));if("top"===i||"bottom"===i){var c="top"===i&&!u||"bottom"===i&&u;l=tp({},l,{x1:t,y1:n+c*a,x2:t+r,y2:n+c*a})}else{var d="left"===i&&!u||"right"===i&&u;l=tp({},l,{x1:t+d*r,y1:n,x2:t+d*r,y2:n+a})}return o.a.createElement("line",ep({className:"recharts-cartesian-axis-line"},l))}},{key:"renderTicks",value:function(e){var n=this,r=this.props,a=r.tickLine,i=r.stroke,s=r.tick,u=r.tickFormatter,l=r.unit,c=t.getTicks(tp({},this.props,{ticks:e})),d=this.getTickTextAnchor(),f=this.getTickVerticalAnchor(),p=le(this.props),h=le(s),m=tp({},p,{fill:"none"},le(a)),y=c.map(function(e,t){var r=n.getTickLineCoord(e),y=r.line,v=r.tick,b=tp({textAnchor:d,verticalAnchor:f},p,{stroke:"none",fill:i},h,v,{index:t,payload:e,visibleTicksCount:c.length});return o.a.createElement(Le,ep({className:"recharts-cartesian-axis-tick",key:"tick-".concat(t)},pe(n.props,e,t)),a&&o.a.createElement("line",ep({className:"recharts-cartesian-axis-tick-line"},m,y)),s&&n.constructor.renderTickItem(s,b,"".concat(A()(u)?u(e.value):e.value).concat(l||"")))});return o.a.createElement("g",{className:"recharts-cartesian-axis-ticks"},y)}},{key:"render",value:function(){var e=this.props,t=e.axisLine,n=e.width,r=e.height,a=e.ticksGenerator,i=e.className;if(e.hide)return null;var s=this.props,u=s.ticks,l=rp(s,["ticks"]),c=u;return A()(a)&&(c=u&&u.length>0?a(this.props):a(l)),n<=0||r<=0||!c||!c.length?null:o.a.createElement(Le,{className:O()("recharts-cartesian-axis",i)},t&&this.renderAxisLine(),this.renderTicks(c),Bc.renderCallByParent(this.props))}}])&&ap(n.prototype,r),i&&ap(n,i),t}();up.displayName="CartesianAxis",up.propTypes=tp({},ne,re,{className:s.a.string,x:s.a.number,y:s.a.number,width:s.a.number,height:s.a.number,orientation:s.a.oneOf(["top","bottom","left","right"]),viewBox:s.a.shape({x:s.a.number,y:s.a.number,width:s.a.number,height:s.a.number}),tick:s.a.oneOfType([s.a.bool,s.a.func,s.a.object,s.a.element]),axisLine:s.a.oneOfType([s.a.bool,s.a.object]),tickLine:s.a.oneOfType([s.a.bool,s.a.object]),mirror:s.a.bool,tickMargin:s.a.number.isRequired,minTickGap:s.a.number,ticks:s.a.array,tickSize:s.a.number,stroke:s.a.string,tickFormatter:s.a.func,ticksGenerator:s.a.func,interval:s.a.oneOfType([s.a.number,s.a.oneOf(["preserveStart","preserveEnd","preserveStartEnd"])])}),up.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 lp=up;function cp(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var dp,fp,pp,hp=["Webkit","Moz","O","ms"],mp=function(e,t){if(!e)return null;var n=e.replace(/(\w)/,function(e){return e.toUpperCase()}),r=hp.reduce(function(e,r){return function(e){for(var t=1;t0&&n.handleDrag(e.changedTouches[0])},n.handleDragEnd=function(){n.setState({isTravellerMoving:!1,isSlideMoving:!1})},n.handleLeaveWrapper=function(){(n.state.isTravellerMoving||n.state.isSlideMoving)&&(n.leaveTimer=setTimeout(n.handleDragEnd,1e3))},n.handleEnterSlideOrTraveller=function(){n.setState({isTextActive:!0})},n.handleLeaveSlideOrTraveller=function(){n.setState({isTextActive:!1})},n.handleSlideDragStart=function(e){var t=e.changedTouches&&e.changedTouches.length?e.changedTouches[0]:e;n.setState({isTravellerMoving:!1,isSlideMoving:!0,slideMoveStartX:t.pageX})},n.travellerDragStartHandlers={startX:n.handleTravellerDragStart.bind(Mp(Mp(n)),"startX"),endX:n.handleTravellerDragStart.bind(Mp(Mp(n)),"endX")},n.state=e.data&&e.data.length?n.updateScale(e):{},n}var n,r,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}}),t&&kp(e,t)}(t,a["Component"]),n=t,i=[{key:"getIndexInRange",value:function(e,t){for(var n=0,r=e.length-1;r-n>1;){var a=Math.floor((n+r)/2);e[a]>t?r=a:n=a}return t>=e[r]?r:n}}],(r=[{key:"componentWillReceiveProps",value:function(e){var t=this,n=this.props,r=n.data,a=n.width,o=n.x,i=n.travellerWidth,s=n.updateId;(e.data!==r||e.updateId!==s)&&e.data&&e.data.length?this.setState(this.updateScale(e)):e.width===a&&e.x===o&&e.travellerWidth===i||(this.scale.range([e.x,e.x+e.width-e.travellerWidth]),this.scaleValues=this.scale.domain().map(function(e){return t.scale(e)}),this.setState({startX:this.scale(e.startIndex),endX:this.scale(e.endIndex)}))}},{key:"componentWillUnmount",value:function(){this.scale=null,this.scaleValues=null,this.leaveTimer&&(clearTimeout(this.leaveTimer),this.leaveTimer=null)}},{key:"getIndex",value:function(e){var t=e.startX,n=e.endX,r=this.props,a=r.gap,o=r.data.length-1,i=Math.min(t,n),s=Math.max(t,n),u=this.constructor.getIndexInRange(this.scaleValues,i),l=this.constructor.getIndexInRange(this.scaleValues,s);return{startIndex:u-u%a,endIndex:l===o?o:l-l%a}}},{key:"getTextOfTick",value:function(e){var t=this.props,n=t.data,r=t.tickFormatter,a=t.dataKey,o=sf(n[e],a,e);return A()(r)?r(o):o}},{key:"handleSlideDrag",value:function(e){var t=this.state,n=t.slideMoveStartX,r=t.startX,a=t.endX,o=this.props,i=o.x,s=o.width,u=o.travellerWidth,l=o.startIndex,c=o.endIndex,d=o.onChange,f=e.pageX-n;f>0?f=Math.min(f,i+s-u-a,i+s-u-r):f<0&&(f=Math.max(f,i-r,i-a));var p=this.getIndex({startX:r+f,endX:a+f});p.startIndex===l&&p.endIndex===c||!d||d(p),this.setState({startX:r+f,endX:a+f,slideMoveStartX:e.pageX})}},{key:"handleTravellerDragStart",value:function(e,t){var n=t.changedTouches&&t.changedTouches.length?t.changedTouches[0]:t;this.setState({isSlideMoving:!1,isTravellerMoving:!0,movingTravellerId:e,brushMoveStartX:n.pageX})}},{key:"handleTravellerMove",value:function(e){var t,n=this.state,r=n.brushMoveStartX,a=n.movingTravellerId,o=n.endX,i=n.startX,s=this.state[a],u=this.props,l=u.x,c=u.width,d=u.travellerWidth,f=u.onChange,p=u.gap,h=u.data,m={startX:this.state.startX,endX:this.state.endX},y=e.pageX-r;y>0?y=Math.min(y,l+c-d-s):y<0&&(y=Math.max(y,l-s)),m[a]=s+y;var v=this.getIndex(m),b=v.startIndex,g=v.endIndex;this.setState((bp(t={},a,s+y),bp(t,"brushMoveStartX",e.pageX),t),function(){var e;f&&(e=h.length-1,("startX"===a&&(o>i?b%p==0:g%p==0)||oi?g%p==0:b%p==0)||o>i&&g===e)&&f(v))})}},{key:"updateScale",value:function(e){var t=this,n=e.data,r=e.startIndex,a=e.endIndex,o=e.x,i=e.width,s=e.travellerWidth,u=n.length;return this.scale=bo().domain(M()(0,u)).range([o,o+i-s]),this.scaleValues=this.scale.domain().map(function(e){return t.scale(e)}),{isTextActive:!1,isSlideMoving:!1,isTravellerMoving:!1,startX:this.scale(r),endX:this.scale(a)}}},{key:"renderBackground",value:function(){var e=this.props,t=e.x,n=e.y,r=e.width,a=e.height,i=e.fill,s=e.stroke;return o.a.createElement("rect",{stroke:s,fill:i,x:t,y:n,width:r,height:a})}},{key:"renderPanorama",value:function(){var e=this.props,t=e.x,n=e.y,r=e.width,i=e.height,s=e.data,u=e.children,l=e.padding,c=a.Children.only(u);return c?o.a.cloneElement(c,{x:t,y:n,width:r,height:i,margin:l,compact:!0,data:s}):null}},{key:"renderTraveller",value:function(e,t){var n=this.props,r=n.y,a=n.travellerWidth,i=n.height,s=n.stroke,u=Math.floor(r+i/2)-1,l=Math.max(e,this.props.x);return o.a.createElement(Le,{className:"recharts-brush-traveller",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.travellerDragStartHandlers[t],onTouchStart:this.travellerDragStartHandlers[t],style:{cursor:"col-resize"}},o.a.createElement("rect",{x:l,y:r,width:a,height:i,fill:s,stroke:"none"}),o.a.createElement("line",{x1:l+1,y1:u,x2:l+a-1,y2:u,fill:"none",stroke:"#fff"}),o.a.createElement("line",{x1:l+1,y1:u+2,x2:l+a-1,y2:u+2,fill:"none",stroke:"#fff"}))}},{key:"renderSlide",value:function(e,t){var n=this.props,r=n.y,a=n.height,i=n.stroke;return o.a.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:Math.min(e,t),y:r,width:Math.abs(t-e),height:a})}},{key:"renderText",value:function(){var e=this.props,t=e.startIndex,n=e.endIndex,r=e.y,a=e.height,i=e.travellerWidth,s=e.stroke,u=this.state,l=u.startX,c=u.endX,d={pointerEvents:"none",fill:s};return o.a.createElement(Le,{className:"recharts-brush-texts"},o.a.createElement(Tc,vp({textAnchor:"end",verticalAnchor:"middle",x:Math.min(l,c)-5,y:r+a/2},d),this.getTextOfTick(t)),o.a.createElement(Tc,vp({textAnchor:"start",verticalAnchor:"middle",x:Math.max(l,c)+i+5,y:r+a/2},d),this.getTextOfTick(n)))}},{key:"render",value:function(){var e=this.props,t=e.data,n=e.className,r=e.children,a=e.x,i=e.y,s=e.width,u=e.height,l=this.state,c=l.startX,d=l.endX,f=l.isTextActive,p=l.isSlideMoving,h=l.isTravellerMoving;if(!t||!t.length||!z(a)||!z(i)||!z(s)||!z(u)||s<=0||u<=0)return null;var m=O()("recharts-brush",n),y=1===o.a.Children.count(r),v=mp("userSelect","none");return o.a.createElement(Le,{className:m,onMouseMove:this.handleDrag,onMouseLeave:this.handleLeaveWrapper,onMouseUp:this.handleDragEnd,onTouchEnd:this.handleDragEnd,onTouchMove:this.handleTouchMove,style:v},this.renderBackground(),y&&this.renderPanorama(),this.renderSlide(c,d),this.renderTraveller(c,"startX"),this.renderTraveller(d,"endX"),(f||p||h)&&this.renderText())}}])&&gp(n.prototype,r),i&&gp(n,i),t}(),fp.displayName="Brush",fp.propTypes={className:s.a.string,fill:s.a.string,stroke:s.a.string,x:s.a.number,y:s.a.number,width:s.a.number,height:s.a.number.isRequired,travellerWidth:s.a.number,gap:s.a.number,padding:s.a.shape({top:s.a.number,right:s.a.number,bottom:s.a.number,left:s.a.number}),dataKey:s.a.oneOfType([s.a.string,s.a.number,s.a.func]),data:s.a.array,startIndex:s.a.number,endIndex:s.a.number,tickFormatter:s.a.func,children:s.a.node,onChange:s.a.func,updateId:s.a.oneOfType([s.a.string,s.a.number])},fp.defaultProps={height:40,travellerWidth:5,gap:1,fill:"#fff",stroke:"#666",padding:{top:1,right:1,bottom:1,left:1}},dp=pp))||dp,xp=n(302),Sp=new(n.n(xp).a);Sp.setMaxListeners&&Sp.setMaxListeners(10);var Dp="recharts.syncMouseEvents";function Tp(e){return(Tp="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})(e)}function Op(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},o=Object.keys(e);for(r=0;r=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}function Pp(){return(Pp=Object.assign||function(e){for(var t=1;t0&&n.handleMouseMove(e.changedTouches[0])},n.handleTouchStart=function(e){null!=e.changedTouches&&e.changedTouches.length>0&&n.handleMouseDown(e.changedTouches[0])},n.handleTouchEnd=function(e){null!=e.changedTouches&&e.changedTouches.length>0&&n.handleMouseUp(e.changedTouches[0])},n.verticalCoordinatesGenerator=function(e){var t=e.xAxis,n=e.width,r=e.height,a=e.offset;return hf(lp.getTicks(Ep({},lp.defaultProps,t,{ticks:mf(t,!0),viewBox:{x:0,y:0,width:n,height:r}})),a.left,a.left+a.width)},n.horizontalCoordinatesGenerator=function(e){var t=e.yAxis,n=e.width,r=e.height,a=e.offset;return hf(lp.getTicks(Ep({},lp.defaultProps,t,{ticks:mf(t,!0),viewBox:{x:0,y:0,width:n,height:r}})),a.top,a.top+a.height)},n.axesTicksGenerator=function(e){return mf(e,!0)},n.tooltipTicksGenerator=function(e){var t=q(e),n=mf(t,!1,!0);return{tooltipTicks:n,orderedTooltipTicks:b()(n,function(e){return e.coordinate}),tooltipAxis:t,tooltipAxisBandSize:Of(t)}},n.renderCursor=function(e){var r=n.state,o=r.isTooltipActive,i=r.activeCoordinate,s=r.activePayload,u=r.offset;if(!(e&&e.props.cursor&&o&&i))return null;var l,c=n.props.layout,d=Oa;if("ScatterChart"===t)l=i,d=Na;else if("BarChart"===t)l=n.getCursorRectangle(),d=_d;else if("radial"===c){var f=n.getCursorPoints(),p=f.cx,h=f.cy,m=f.radius;l={cx:p,cy:h,startAngle:f.startAngle,endAngle:f.endAngle,innerRadius:m,outerRadius:m},d=Jf}else l={points:n.getCursorPoints()},d=Oa;var y=e.key||"_recharts-cursor",v=Ep({stroke:"#ccc",pointerEvents:"none"},u,l,le(e.props.cursor),{payload:s,key:y,className:"recharts-tooltip-cursor"});return Object(a.isValidElement)(e.props.cursor)?Object(a.cloneElement)(e.props.cursor,v):Object(a.createElement)(d,v)},n.renderPolarAxis=function(e,t,r){var o=e.type.axisType,i=n.state["".concat(o,"Map")][e.props["".concat(o,"Id")]];return Object(a.cloneElement)(e,Ep({},i,{className:o,key:e.key||"".concat(t,"-").concat(r),ticks:mf(i,!0)}))},n.renderXAxis=function(e,t,r){var a=n.state.xAxisMap[e.props.xAxisId];return n.renderAxis(a,e,t,r)},n.renderYAxis=function(e,t,r){var a=n.state.yAxisMap[e.props.yAxisId];return n.renderAxis(a,e,t,r)},n.renderGrid=function(e){var t=n.state,r=t.xAxisMap,o=t.yAxisMap,i=t.offset,s=n.props,u=s.width,l=s.height,c=q(r),d=y()(o,function(e){return h()(e.domain,Number.isFinite)})||q(o),f=e.props||{};return Object(a.cloneElement)(e,{key:e.key||"grid",x:z(f.x)?f.x:i.left,y:z(f.y)?f.y:i.top,width:z(f.width)?f.width:i.width,height:z(f.height)?f.height:i.height,xAxis:c,yAxis:d,offset:i,chartWidth:u,chartHeight:l,verticalCoordinatesGenerator:f.verticalCoordinatesGenerator||n.verticalCoordinatesGenerator,horizontalCoordinatesGenerator:f.horizontalCoordinatesGenerator||n.horizontalCoordinatesGenerator})},n.renderPolarGrid=function(e){var t=n.state,r=t.radiusAxisMap,o=t.angleAxisMap,i=q(r),s=q(o),u=s.cx,l=s.cy,c=s.innerRadius,d=s.outerRadius;return Object(a.cloneElement)(e,{polarAngles:mf(s,!0).map(function(e){return e.coordinate}),polarRadius:mf(i,!0).map(function(e){return e.coordinate}),cx:u,cy:l,innerRadius:c,outerRadius:d,key:e.key||"polar-grid"})},n.renderBrush=function(e){var t=n.props,r=t.margin,o=t.data,i=n.state,s=i.offset,u=i.dataStartIndex,l=i.dataEndIndex,c=i.updateId;return Object(a.cloneElement)(e,{key:e.key||"_recharts-brush",onChange:yf(n.handleBrushChange,null,e.props.onChange),data:o,x:z(e.props.x)?e.props.x:s.left,y:z(e.props.y)?e.props.y:s.top+s.height+s.brushBottom-(r.bottom||0),width:z(e.props.width)?e.props.width:s.width,startIndex:u,endIndex:l,updateId:"brush-".concat(c)})},n.renderReferenceElement=function(e,t,r){if(!e)return null;var o=Np(Np(n)).clipPathId,i=n.state,s=i.xAxisMap,u=i.yAxisMap,l=i.offset,c=e.props,d=c.xAxisId,f=c.yAxisId;return Object(a.cloneElement)(e,{key:e.key||"".concat(t,"-").concat(r),xAxis:s[d],yAxis:u[f],viewBox:{x:l.left,y:l.top,width:l.width,height:l.height},clipPathId:o})},n.renderGraphicChild=function(e,t,r){var o=n.filterFormatItem(e,t,r);if(!o)return null;var i,s,u=Object(a.cloneElement)(e,o.props),l=n.state,c=l.isTooltipActive,d=l.tooltipAxis,f=l.activeTooltipIndex,p=l.activeLabel,h=n.props.children,m=ue(h,vn),y=o.props,v=y.points,b=y.isRange,g=y.baseLine,A=o.item.props,k=A.activeDot;return!A.hide&&c&&m&&k&&f>=0&&(d.dataKey&&!d.allowDuplicatedCategory?(i=Q(v,"payload.".concat(d.dataKey),p),s=b&&g&&Q(g,"payload.".concat(d.dataKey),p)):(i=v[f],s=b&&g&&g[f]),!D()(i))?[u].concat(Lp(n.renderActivePoints({item:o,activePoint:i,basePoint:s,childIndex:f,isRange:b}))):b?[u,null,null]:[u,null]};var s=n.constructor.createDefaultState(e);return n.state=Ep({},s,{updateId:0},n.updateStateOfAxisMapsOffsetAndStackGroups(Ep({props:e},s,{updateId:0}))),n.uniqueChartId=D()(e.id)?K("recharts"):e.id,n.clipPathId="".concat(n.uniqueChartId,"-clip"),e.throttleDelay&&(n.triggeredAfterMouseMove=x()(n.triggeredAfterMouseMove,e.throttleDelay)),n}var s,d,f;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}}),t&&Rp(e,t)}(r,a.Component),s=r,f=[{key:"getAxisNameByLayout",value: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"}}},{key:"renderActiveDot",value:function(e,t){var n;return n=Object(a.isValidElement)(e)?Object(a.cloneElement)(e,t):A()(e)?e(t):o.a.createElement(sc,t),o.a.createElement(Le,{className:"recharts-active-dot",key:t.key},n)}}],(d=[{key:"componentDidMount",value:function(){D()(this.props.syncId)||this.addListener()}},{key:"componentWillReceiveProps",value:function(e){var t=this,n=this.props,r=n.data,a=n.children,o=n.width,i=n.height,s=n.layout,u=n.stackOffset,l=n.margin,c=this.state.updateId;if(e.data===r&&e.width===o&&e.height===i&&e.layout===s&&e.stackOffset===u&&X(e.margin,l)){if(!be(e.children,a)){var d=D()(e.data)?c+1:c;this.setState(function(n){return Ep({updateId:d},t.updateStateOfAxisMapsOffsetAndStackGroups(Ep({props:e},n,{updateId:d})))})}}else{var f=this.constructor.createDefaultState(e);this.setState(Ep({},f,{updateId:c+1},this.updateStateOfAxisMapsOffsetAndStackGroups(Ep({props:e},f,{updateId:c+1}))))}D()(this.props.syncId)&&!D()(e.syncId)&&this.addListener(),!D()(this.props.syncId)&&D()(e.syncId)&&this.removeListener()}},{key:"componentWillUnmount",value:function(){D()(this.props.syncId)||this.removeListener(),"function"==typeof this.triggeredAfterMouseMove.cancel&&this.triggeredAfterMouseMove.cancel()}},{key:"getAxisMap",value:function(e,t){var n=t.axisType,r=void 0===n?"xAxis":n,a=t.AxisComp,o=t.graphicalItems,i=t.stackGroups,s=t.dataStartIndex,u=t.dataEndIndex,l=e.children,c="".concat(r,"Id"),d=se(l,a),f={};return d&&d.length?f=this.getAxisMapByAxes(e,{axes:d,graphicalItems:o,axisType:r,axisIdKey:c,stackGroups:i,dataStartIndex:s,dataEndIndex:u}):o&&o.length&&(f=this.getAxisMapByItems(e,{Axis:a,graphicalItems:o,axisType:r,axisIdKey:c,stackGroups:i,dataStartIndex:s,dataEndIndex:u})),f}},{key:"getAxisMapByAxes",value:function(e,t){var n=this,r=t.axes,a=t.graphicalItems,o=t.axisType,i=t.axisIdKey,s=t.stackGroups,u=t.dataStartIndex,l=t.dataEndIndex,c=e.layout,d=e.children,f=e.stackOffset,p=pf(c,o);return r.reduce(function(t,r){var h=r.props,m=h.type,y=h.dataKey,v=h.allowDataOverflow,b=h.allowDuplicatedCategory,g=h.scale,A=h.ticks,k=r.props[i],w=n.constructor.getDisplayedData(e,{graphicalItems:a.filter(function(e){return e.props[i]===k}),dataStartIndex:u,dataEndIndex:l}),x=w.length;if(!t[k]){var S,T,O;if(y){if(S=uf(w,y,m),"category"===m&&p){var P=function(e){if(!Y()(e))return!1;for(var t=e.length,n={},r=0;r=0?e:Lp(e).concat([t])},[]))}else if("category"===m)S=b?S.filter(function(e){return""!==e&&!D()(e)}):Pf(r.props.domain,S,r).reduce(function(e,t){return e.indexOf(t)>=0||""===t||D()(t)?e:Lp(e).concat([t])},[]);else if("number"===m){var L=function(e,t,n,r){var a=t.map(function(t){return df(e,t,n,r)}).filter(function(e){return!D()(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}(w,a.filter(function(e){return e.props[i]===k&&!e.props.hide}),y,o);L&&(S=L)}!p||"number"!==m&&"auto"===g||(O=uf(w,y,"category"))}else S=p?M()(0,x):s&&s[k]&&s[k].hasStack&&"number"===m?"expand"===f?[0,1]:xf(s[k].stackGroups,u,l):ff(w,a.filter(function(e){return e.props[i]===k&&!e.props.hide}),m,!0);return"number"===m&&(S=wf(d,S,k,o,A),r.props.domain&&(S=Tf(r.props.domain,S,v))),Ep({},t,jp({},k,Ep({},r.props,{axisType:o,domain:S,categoricalDomain:O,duplicateDomain:T,originalDomain:r.props.domain,isCategorial:p,layout:c})))}return t},{})}},{key:"getAxisMapByItems",value:function(e,t){var n=t.graphicalItems,r=t.Axis,a=t.axisType,o=t.axisIdKey,i=t.stackGroups,s=t.dataStartIndex,u=t.dataEndIndex,l=e.layout,c=e.children,d=this.constructor.getDisplayedData(e,{graphicalItems:n,dataStartIndex:s,dataEndIndex:u}),f=d.length,p=pf(l,a),h=-1;return n.reduce(function(e,t){var m,y=t.props[o];return e[y]?e:(h++,p?m=M()(0,f):i&&i[y]&&i[y].hasStack?(m=xf(i[y].stackGroups,s,u),m=wf(c,m,y,a)):(m=Tf(r.defaultProps.domain,ff(d,n.filter(function(e){return e.props[o]===y&&!e.props.hide}),"number"),r.defaultProps.allowDataOverflow),m=wf(c,m,y,a)),Ep({},e,jp({},y,Ep({axisType:a},r.defaultProps,{hide:!0,orientation:Fp[a]&&Fp[a][h%2],domain:m,originalDomain:r.defaultProps.domain,isCategorial:p,layout:l}))))},{})}},{key:"getActiveCoordinate",value:function(e,t,n){var r=this.props.layout,a=e.find(function(e){return e&&e.index===t});if(a){if("horizontal"===r)return{x:a.coordinate,y:n.y};if("vertical"===r)return{x:n.x,y:a.coordinate};if("centric"===r){var o=a.coordinate,i=n.radius;return Ep({},n,If(n.cx,n.cy,i,o),{angle:o,radius:i})}var s=a.coordinate,u=n.angle;return Ep({},n,If(n.cx,n.cy,s,u),{angle:u,radius:s})}return Bp}},{key:"getMouseInfo",value:function(e){if(!this.container)return null;var t,n,r,a=function(e,t){return{chartX:Math.round(e.pageX-t.left),chartY:Math.round(e.pageY-t.top)}}(e,(t=this.container,n=t.ownerDocument.documentElement,r={top:0,left:0},void 0!==t.getBoundingClientRect&&(r=t.getBoundingClientRect()),{top:r.top+window.pageYOffset-n.clientTop,left:r.left+window.pageXOffset-n.clientLeft})),o=this.inRange(a.chartX,a.chartY);if(!o)return null;var s=this.state,u=s.xAxisMap,l=s.yAxisMap;if("axis"!==i&&u&&l){var c=q(u).scale,d=q(l).scale;return Ep({},a,{xValue:c&&c.invert?c.invert(a.chartX):null,yValue:d&&d.invert?d.invert(a.chartY):null})}var f=this.state,p=f.orderedTooltipTicks,h=f.tooltipAxis,m=f.tooltipTicks,y=function(e,t,n,r){var a=-1,o=t.length;if(o>1){if(r&&"angleAxis"===r.axisType&&Math.abs(Math.abs(r.range[1]-r.range[0])-360)<=1e-6)for(var i=r.range,s=0;s0?n[s-1].coordinate:n[o-1].coordinate,l=n[s].coordinate,c=s>=o-1?n[0].coordinate:n[s+1].coordinate,d=void 0;if(B(l-u)!==B(c-l)){var f=[];if(B(c-l)===B(i[1]-i[0])){d=c;var p=l+i[1]-i[0];f[0]=Math.min(p,(p+u)/2),f[1]=Math.max(p,(p+u)/2)}else{d=u;var h=c+i[1]-i[0];f[0]=Math.min(l,(h+l)/2),f[1]=Math.max(l,(h+l)/2)}var m=[Math.min(l,(d+l)/2),Math.max(l,(d+l)/2)];if(e>m[0]&&e<=m[1]||e>=f[0]&&e<=f[1]){a=n[s].index;break}}else{var y=Math.min(u,c),v=Math.max(u,c);if(e>(y+l)/2&&e<=(v+l)/2){a=n[s].index;break}}}else for(var b=0;b0&&b(t[b].coordinate+t[b-1].coordinate)/2&&e<=(t[b].coordinate+t[b+1].coordinate)/2||b===o-1&&e>(t[b].coordinate+t[b-1].coordinate)/2){a=t[b].index;break}}else a=0;return a}(this.calculateTooltipPos(o),p,m,h);if(y>=0&&m){var v=m[y]&&m[y].value;return Ep({},a,{activeTooltipIndex:y,activeLabel:v,activePayload:this.getTooltipContent(y,v),activeCoordinate:this.getActiveCoordinate(p,y,o)})}return null}},{key:"getTooltipContent",value:function(e,t){var n=this.state,r=n.graphicalItems,a=n.tooltipAxis,o=this.constructor.getDisplayedData(this.props,this.state);return e<0||!r||!r.length||e>=o.length?null:r.reduce(function(n,r){if(r.props.hide)return n;var i,s=r.props,u=s.dataKey,l=s.name,c=s.unit,d=s.formatter,f=s.data;return(i=a.dataKey&&!a.allowDuplicatedCategory?Q(f||o,a.dataKey,t):o[e])?Lp(n).concat([Ep({},le(r),{dataKey:u,unit:c,formatter:d,name:l||u,color:lf(r),value:sf(i,u),payload:i})]):n},[])}},{key:"getFormatItems",value:function(e,t){var n=this,r=t.graphicalItems,o=t.stackGroups,i=t.offset,s=t.updateId,l=t.dataStartIndex,c=t.dataEndIndex,d=e.barSize,f=e.layout,p=e.barGap,h=e.barCategoryGap,m=e.maxBarSize,y=this.constructor.getAxisNameByLayout(f),v=y.numericAxisName,b=y.cateAxisName,g=this.constructor.hasBar(r),A=g&&function(e){var t=e.barSize,n=e.stackGroups,r=void 0===n?{}:n;if(!r)return{};for(var a={},o=Object.keys(r),i=0,s=o.length;i=0});if(m&&m.length){var y=m[0].props.barSize,v=m[0].props[h];a[v]||(a[v]=[]),a[v].push({item:m[0],stackList:m.slice(1),barSize:D()(y)?t:y})}}return a}({barSize:d,stackGroups:o}),k=[];return r.forEach(function(r,d){var y,M,w,x,S=n.constructor.getDisplayedData(e,{dataStartIndex:l,dataEndIndex:c},r),T=r.props,O=T.dataKey,P=T.maxBarSize,L=r.props["".concat(v,"Id")],E=r.props["".concat(b,"Id")],j=u.reduce(function(e,n){var a,o=t["".concat(n.axisType,"Map")],i=r.props["".concat(n.axisType,"Id")],s=o&&o[i];return Ep({},e,(jp(a={},n.axisType,s),jp(a,"".concat(n.axisType,"Ticks"),mf(s)),a))},{}),C=j[b],Y=j["".concat(b,"Ticks")],R=o&&o[L]&&o[L].hasStack&&function(e,t){var n=e.props.stackId;if(V(n)){var r=t[n];if(r&&r.items.length){for(var a=-1,o=0,i=r.items.length;o=0?r.stackedData[a]:null}}return null}(r,o[L].stackGroups),N=Of(C,Y),_=D()(P)?m:P,I=g&&function(e){var t=e.barGap,n=e.barCategoryGap,r=e.bandSize,a=e.sizeList,o=void 0===a?[]:a,i=e.maxBarSize,s=o.length;if(s<1)return null;var u,l=G(t,r,0,!0);if(o[0].barSize===+o[0].barSize){var c=!1,d=r/s,f=o.reduce(function(e,t){return e+t.barSize||0},0);(f+=(s-1)*l)>=r&&(f-=(s-1)*l,l=0),f>=r&&d>0&&(c=!0,f=s*(d*=.9));var p={offset:((r-f)/2>>0)-l,size:0};u=o.reduce(function(e,t){var n=rf(e).concat([{item:t.item,position:{offset:p.offset+p.size+l,size:c?d:t.barSize}}]);return p=n[n.length-1].position,t.stackList&&t.stackList.length&&t.stackList.forEach(function(e){n.push({item:e,position:p})}),n},[])}else{var h=G(n,r,0,!0);r-2*h-(s-1)*l<=0&&(l=0);var m=(r-2*h-(s-1)*l)/s;m>1&&(m>>=0);var y=i===+i?Math.min(m,i):m;u=o.reduce(function(e,t,n){var r=rf(e).concat([{item:t.item,position:{offset:h+(m+l)*n+(m-y)/2,size:y}}]);return t.stackList&&t.stackList.length&&t.stackList.forEach(function(e){r.push({item:e,position:r[r.length-1].position})}),r},[])}return u}({barGap:p,barCategoryGap:h,bandSize:N,sizeList:A[E],maxBarSize:_}),H=r&&r.type&&r.type.getComposedData;H&&k.push({props:Ep({},H(Ep({},j,{displayedData:S,props:e,dataKey:O,item:r,bandSize:N,barPosition:I,offset:i,stackedData:R,layout:f,dataStartIndex:l,dataEndIndex:c,onItemMouseLeave:yf(n.handleItemMouseLeave,null,r.props.onMouseLeave),onItemMouseEnter:yf(n.handleItemMouseEnter,null,r.props.onMouseEnter)})),(y={key:r.key||"item-".concat(d)},jp(y,v,j[v]),jp(y,b,j[b]),jp(y,"animationId",s),y)),childIndex:(M=r,w=e.children,x=-1,a.Children.forEach(w,function(e,t){e===M&&(x=t)}),x),item:r})}),k}},{key:"getCursorRectangle",value:function(){var e=this.props.layout,t=this.state,n=t.activeCoordinate,r=t.offset,a=t.tooltipAxisBandSize,o=a/2;return{stroke:"none",fill:"#ccc",x:"horizontal"===e?n.x-o:r.left+.5,y:"horizontal"===e?r.top+.5:n.y-o,width:"horizontal"===e?a:r.width-1,height:"horizontal"===e?r.height-1:a}}},{key:"getCursorPoints",value:function(){var e,t,n,r,a=this.props.layout,o=this.state,i=o.activeCoordinate,s=o.offset;if("horizontal"===a)n=e=i.x,t=s.top,r=s.top+s.height;else if("vertical"===a)r=t=i.y,e=s.left,n=s.left+s.width;else if(!D()(i.cx)||!D()(i.cy)){if("centric"!==a){var u=i.cx,l=i.cy,c=i.radius,d=i.startAngle,f=i.endAngle;return{points:[If(u,l,c,d),If(u,l,c,f)],cx:u,cy:l,radius:c,startAngle:d,endAngle:f}}var p=i.cx,h=i.cy,m=i.innerRadius,y=i.outerRadius,v=i.angle,b=If(p,h,m,v),g=If(p,h,y,v);e=b.x,t=b.y,n=g.x,r=g.y}return[{x:e,y:t},{x:n,y:r}]}},{key:"calculateTooltipPos",value:function(e){var t=this.props.layout;return"horizontal"===t?e.x:"vertical"===t?e.y:"centric"===t?e.angle:e.radius}},{key:"inRange",value:function(e,t){var n=this.props.layout;if("horizontal"===n||"vertical"===n){var r=this.state.offset;return e>=r.left&&e<=r.left+r.width&&t>=r.top&&t<=r.top+r.height?{x:e,y:t}:null}var a=this.state,o=a.angleAxisMap,i=a.radiusAxisMap;if(o&&i){var s=q(o);return Wf({x:e,y:t},s)}return null}},{key:"parseEventsOfWrapper",value:function(){var e=this.props.children,t=ue(e,vn)&&"axis"===i?{onMouseEnter:this.handleMouseEnter,onMouseMove:this.handleMouseMove,onMouseLeave:this.handleMouseLeave,onTouchMove:this.handleTouchMove,onTouchStart:this.handleTouchStart,onTouchEnd:this.handleTouchEnd}:{};return Ep({},de(this.props,this.handleOuterEvent),t)}},{key:"updateStateOfAxisMapsOffsetAndStackGroups",value:function(e){var r=this,a=e.props,o=e.dataStartIndex,i=e.dataEndIndex,s=e.updateId;if(!he({props:a}))return null;var l=a.children,d=a.layout,f=a.stackOffset,p=a.data,h=a.reverseStackOrder,m=this.constructor.getAxisNameByLayout(d),y=m.numericAxisName,v=m.cateAxisName,b=se(l,n),g=function(e,t,n,r,a,o){if(!e)return null;var i=(o?t.reverse():t).reduce(function(e,t){var a=t.props,o=a.stackId;if(a.hide)return e;var i=t.props[n],s=e[i]||{hasStack:!1,stackGroups:{}};if(V(o)){var u=s.stackGroups[o]||{numericAxisId:n,cateAxisId:r,items:[]};u.items.push(t),s.hasStack=!0,s.stackGroups[o]=u}else s.stackGroups[K("_stackId_")]={numericAxisId:n,cateAxisId:r,items:[t]};return af({},e,of({},i,s))},{});return Object.keys(i).reduce(function(t,o){var s=i[o];return s.hasStack&&(s.stackGroups=Object.keys(s.stackGroups).reduce(function(t,o){var i=s.stackGroups[o];return af({},t,of({},o,{numericAxisId:n,cateAxisId:r,items:i.items,stackedData:Af(e,i.items,a)}))},{})),af({},t,of({},o,s))},{})}(p,b,"".concat(y,"Id"),"".concat(v,"Id"),f,h),A=u.reduce(function(e,t){return Ep({},e,jp({},"".concat(t.axisType,"Map"),r.getAxisMap(a,Ep({},t,{graphicalItems:b,stackGroups:t.axisType===y&&g,dataStartIndex:o,dataEndIndex:i}))))},{}),k=this.calculateOffset(Ep({},A,{props:a,graphicalItems:b}));Object.keys(A).forEach(function(e){A[e]=c(a,A[e],k,e.replace("Map",""),t)});var M=A["".concat(v,"Map")],w=this.tooltipTicksGenerator(M),x=this.getFormatItems(a,Ep({},A,{dataStartIndex:o,dataEndIndex:i,updateId:s,graphicalItems:b,stackGroups:g,offset:k}));return Ep({formatedGraphicalItems:x,graphicalItems:b,offset:k,stackGroups:g},w,A)}},{key:"addListener",value:function(){Sp.on(Dp,this.handleReceiveSyncEvent),Sp.setMaxListeners&&Sp._maxListeners&&Sp.setMaxListeners(Sp._maxListeners+1)}},{key:"removeListener",value:function(){Sp.removeListener(Dp,this.handleReceiveSyncEvent),Sp.setMaxListeners&&Sp._maxListeners&&Sp.setMaxListeners(Sp._maxListeners-1)}},{key:"calculateOffset",value:function(e){var t=e.props,n=e.graphicalItems,r=e.xAxisMap,a=void 0===r?{}:r,o=e.yAxisMap,i=void 0===o?{}:o,s=t.width,u=t.height,l=t.children,c=t.margin||{},d=ue(l,wp),f=ue(l,fa),p=Object.keys(i).reduce(function(e,t){var n=i[t],r=n.orientation;return n.mirror||n.hide?e:Ep({},e,jp({},r,e[r]+n.width))},{left:c.left||0,right:c.right||0}),h=Object.keys(a).reduce(function(e,t){var n=a[t],r=n.orientation;return n.mirror||n.hide?e:Ep({},e,jp({},r,e[r]+n.height))},{top:c.top||0,bottom:c.bottom||0}),m=Ep({},h,p),y=m.bottom;return d&&(m.bottom+=d.props.height||wp.defaultProps.height),f&&this.legendInstance&&(m=function(e,t,n,r){var a=n.children,o=n.width,i=n.height,s=n.margin,u=o-(s.left||0)-(s.right||0),l=i-(s.top||0)-(s.bottom||0),c=cf({children:a,items:t,legendWidth:u,legendHeight:l}),d=e;if(c){var f=r||{},p=c.align,h=c.verticalAlign,m=c.layout;("vertical"===m||"horizontal"===m&&"center"===h)&&z(e[p])&&(d=af({},e,of({},p,d[p]+(f.width||0)))),("horizontal"===m||"vertical"===m&&"center"===p)&&z(e[h])&&(d=af({},e,of({},h,d[h]+(f.height||0))))}return d}(m,n,t,this.legendInstance.getBBox())),Ep({brushBottom:y},m,{width:s-m.left-m.right,height:u-m.top-m.bottom})}},{key:"triggerSyncEvent",value:function(e){var t=this.props.syncId;D()(t)||Sp.emit(Dp,t,this.uniqueChartId,e)}},{key:"filterFormatItem",value:function(e,t,n){for(var r=this.state.formatedGraphicalItems,a=0,o=r.length;a=0})},p.getDisplayedData=function(e,t,n){var r=t.graphicalItems,a=t.dataStartIndex,o=t.dataEndIndex,i=(r||[]).reduce(function(e,t){var n=t.props.data;return n&&n.length?Lp(e).concat(Lp(n)):e},[]);if(i&&i.length>0)return i;if(n&&n.props&&n.props.data&&n.props.data.length>0)return n.props.data;var s=e.data;return s&&s.length&&z(a)&&z(o)?s.slice(a,o+1):[]},p};function zp(e){return(zp="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})(e)}function Vp(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Up(){return(Up=Object.assign||function(e){for(var t=1;t1e-5?"outer"===t?"start":"end":n<-1e-5?"outer"===t?"end":"start":"middle"}},{key:"renderAxisLine",value:function(){var e=this.props,t=e.cx,n=e.cy,r=e.radius,a=e.axisLine,i=e.axisLineType,s=rh({},le(this.props),{fill:"none"},le(a));if("circle"===i)return o.a.createElement(sc,nh({className:"recharts-polar-angle-axis-line"},s,{cx:t,cy:n,r:r}));var u=this.props.ticks.map(function(e){return If(t,n,r,e.coordinate)});return o.a.createElement(eh,nh({className:"recharts-polar-angle-axis-line"},s,{points:u}))}},{key:"renderTicks",value:function(){var e=this,t=this.props,n=t.ticks,r=t.tick,a=t.tickLine,i=t.tickFormatter,s=t.stroke,u=le(this.props),l=le(r),c=rh({},u,{fill:"none"},le(a)),d=n.map(function(t,n){var d=e.getTickLineCoord(t),f=rh({textAnchor:e.getTickTextAnchor(t)},u,{stroke:"none",fill:s},l,{index:n,payload:t,x:d.x2,y:d.y2});return o.a.createElement(Le,nh({className:"recharts-polar-angle-axis-tick",key:"tick-".concat(n)},pe(e.props,t,n)),a&&o.a.createElement("line",nh({className:"recharts-polar-angle-axis-tick-line"},c,d)),r&&e.constructor.renderTickItem(r,f,i?i(t.value):t.value))});return o.a.createElement(Le,{className:"recharts-polar-angle-axis-ticks"},d)}},{key:"render",value:function(){var e=this.props,t=e.ticks,n=e.radius,r=e.axisLine;return n<=0||!t||!t.length?null:o.a.createElement(Le,{className:"recharts-polar-angle-axis"},r&&this.renderAxisLine(),this.renderTicks())}}])&&oh(n.prototype,r),i&&oh(n,i),t}(),Xp.displayName="PolarAngleAxis",Xp.axisType="angleAxis",Xp.propTypes=rh({},ne,re,{type:s.a.oneOf(["number","category"]),angleAxisId:s.a.oneOfType([s.a.string,s.a.number]),dataKey:s.a.oneOfType([s.a.number,s.a.string,s.a.func]),cx:s.a.number,cy:s.a.number,radius:s.a.oneOfType([s.a.number,s.a.string]),hide:s.a.bool,scale:s.a.oneOfType([s.a.oneOf(["auto","linear","pow","sqrt","log","identity","time","band","point","ordinal","quantile","quantize","utc","sequential","threshold"]),s.a.func]),axisLine:s.a.oneOfType([s.a.bool,s.a.object]),axisLineType:s.a.oneOf(["polygon","circle"]),tickLine:s.a.oneOfType([s.a.bool,s.a.object]),tick:s.a.oneOfType([s.a.bool,s.a.func,s.a.object,s.a.element]),ticks:s.a.arrayOf(s.a.shape({value:s.a.any,coordinate:s.a.number})),stroke:s.a.string,orientation:s.a.oneOf(["inner","outer"]),tickFormatter:s.a.func,allowDuplicatedCategory:s.a.bool}),Xp.defaultProps={type:"category",angleAxisId:0,scale:"auto",cx:0,cy:0,domain:[0,"auto"],orientation:"outer",axisLine:!0,tickLine:!0,tick:!0,hide:!1,allowDuplicatedCategory:!0},Qp=Jp))||Qp,hh=n(304),mh=n.n(hh),yh=n(305),vh=n.n(yh);function bh(e){return(bh="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})(e)}function gh(){return(gh=Object.assign||function(e){for(var t=1;t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}function wh(e,t){for(var n=0;n=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var Rh={id:s.a.string,data:s.a.arrayOf(s.a.object),valueAccessor:s.a.func,clockWise:s.a.bool,dataKey:s.a.oneOfType([s.a.string,s.a.number,s.a.func])},Nh={valueAccessor:function(e){return Y()(e.value)?Ph()(e.value):e.value}};function _h(e){var t=e.data,n=e.valueAccessor,r=e.dataKey,a=e.clockWise,i=e.id,s=Yh(e,["data","valueAccessor","dataKey","clockWise","id"]);return t&&t.length?o.a.createElement(Le,{className:"recharts-label-list"},t.map(function(e,t){var u=D()(r)?n(e,t):sf(e&&e.payload,r),l=D()(i)?{}:{id:"".concat(i,"-").concat(t)};return o.a.createElement(Bc,Eh({},le(e),s,l,{index:t,value:u,viewBox:Bc.parseViewBox(D()(a)?e:jh({},e,{clockWise:a})),key:"label-".concat(t)}))})):null}_h.propTypes=Rh,_h.displayName="LabelList";_h.renderCallByParent=function(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];if(!e||!e.children&&n&&!e.label)return null;var r=e.children,i=se(r,_h).map(function(e,n){return Object(a.cloneElement)(e,{data:t,key:"labelList-".concat(n)})});return n?[function(e,t){return e?!0===e?o.a.createElement(_h,{key:"labelList-implicit",data:t}):o.a.isValidElement(e)||A()(e)?o.a.createElement(_h,{key:"labelList-implicit",data:t,content:e}):j()(e)?o.a.createElement(_h,Eh({data:t},e,{key:"labelList-implicit"})):null:null}(e.label,t)].concat(Lh(i)):i},_h.defaultProps=Nh;var Ih=_h;function Hh(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Fh(){return null}Fh.propTypes=function(e){for(var t=1;tt?"start":e0?e.paddingAngle:0;if(n){var s=Z(n.endAngle-n.startAngle,e.endAngle-e.startAngle),u=Gh({},e,{startAngle:i+o,endAngle:i+s(r)+o});a.push(u),i=u.endAngle}else{var c=e.endAngle,d=e.startAngle,f=Z(0,c-d)(r),p=Gh({},e,{startAngle:i+o,endAngle:i+f+o});a.push(p),i=p.endAngle}}),o.a.createElement(Le,null,e.renderSectorsStatically(a))})}},{key:"renderSectors",value:function(){var e=this.props,t=e.sectors,n=e.isAnimationActive,r=this.state.prevSectors;return!(n&&t&&t.length)||r&&je()(r,t)?this.renderSectorsStatically(t):this.renderSectorsWithAnimation()}},{key:"render",value:function(){var e=this.props,t=e.hide,n=e.sectors,r=e.className,a=e.label,i=e.cx,s=e.cy,u=e.innerRadius,l=e.outerRadius,c=e.isAnimationActive,d=e.prevSectors,f=e.id;if(t||!n||!n.length||!z(i)||!z(s)||!z(u)||!z(l))return null;var p=O()("recharts-pie",r);return o.a.createElement(Le,{className:p},o.a.createElement("g",{clipPath:"url(#".concat(D()(f)?this.id:f,")")},this.renderSectors()),a&&this.renderLabels(n),Bc.renderCallByParent(this.props,null,!1),(!c||d&&je()(d,n))&&Ih.renderCallByParent(this.props,n,!1))}}])&&Zh(n.prototype,r),i&&Zh(n,i),t}(),Wh.displayName="Pie",Wh.propTypes=Gh({},ne,re,{className:s.a.string,animationId:s.a.number,cx:s.a.oneOfType([s.a.number,s.a.string]),cy:s.a.oneOfType([s.a.number,s.a.string]),startAngle:s.a.number,endAngle:s.a.number,paddingAngle:s.a.number,innerRadius:s.a.oneOfType([s.a.number,s.a.string]),outerRadius:s.a.oneOfType([s.a.number,s.a.string]),cornerRadius:s.a.oneOfType([s.a.number,s.a.string]),dataKey:s.a.oneOfType([s.a.string,s.a.number,s.a.func]).isRequired,nameKey:s.a.oneOfType([s.a.string,s.a.number,s.a.func]),valueKey:s.a.oneOfType([s.a.string,s.a.number,s.a.func]),data:s.a.arrayOf(s.a.object),blendStroke:s.a.bool,minAngle:s.a.number,legendType:s.a.oneOf(oe),maxRadius:s.a.number,sectors:s.a.arrayOf(s.a.object),hide:s.a.bool,labelLine:s.a.oneOfType([s.a.object,s.a.func,s.a.element,s.a.bool]),label:s.a.oneOfType([s.a.shape({offsetRadius:s.a.number}),s.a.func,s.a.element,s.a.bool]),activeShape:s.a.oneOfType([s.a.object,s.a.func,s.a.element]),activeIndex:s.a.oneOfType([s.a.number,s.a.arrayOf(s.a.number)]),isAnimationActive:s.a.bool,animationBegin:s.a.number,animationDuration:s.a.number,animationEasing:s.a.oneOf(["ease","ease-in","ease-out","ease-in-out","spring","linear"]),id:s.a.string}),Wh.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:!me(),animationBegin:400,animationDuration:1500,animationEasing:"ease",nameKey:"name",blendStroke:!1},Wh.parseDeltaAngle=function(e){var t=e.startAngle,n=e.endAngle;return B(n-t)*Math.min(Math.abs(n-t),360)},Wh.getRealPieData=function(e){var t=e.props,n=t.data,r=t.children,a=le(e.props),o=se(r,Vh);return n&&n.length?n.map(function(e,t){return Gh({payload:e},a,e,o&&o[t]&&o[t].props)}):o&&o.length?o.map(function(e){return Gh({},a,e.props)}):[]},Wh.parseCoordinateOfPie=function(e,t){var n=t.top,r=t.left,a=t.width,o=t.height,i=Hf(a,o);return{cx:r+G(e.props.cx,a,a/2),cy:n+G(e.props.cy,o,o/2),innerRadius:G(e.props.innerRadius,i,0),outerRadius:G(e.props.outerRadius,i,.8*i),maxRadius:e.props.maxRadius||Math.sqrt(a*a+o*o)/2}},Wh.getComposedData=function(e){var t=e.item,n=e.offset,r=e.onItemMouseLeave,a=e.onItemMouseEnter,o=$h.getRealPieData(t);if(!o||!o.length)return[];var i=t.props,s=i.cornerRadius,u=i.startAngle,l=i.endAngle,c=i.paddingAngle,d=i.dataKey,f=i.nameKey,p=i.valueKey,h=Math.abs(t.props.minAngle),m=$h.parseCoordinateOfPie(t,n),y=o.length,v=$h.parseDeltaAngle({startAngle:u,endAngle:l}),b=Math.abs(v),g=b-y*h-(b>=360?y:y-1)*c,A=d;D()(d)&&D()(p)?A="value":D()(d)&&(A=p);var k,M,w=o.reduce(function(e,t){var n=sf(t,A,0);return e+(z(n)?n:0)},0);w>0&&(k=o.map(function(e,t){var n,r=sf(e,A,0),a=sf(e,f,t),o=(z(r)?r:0)/w,i=(n=t?M.endAngle+B(v)*c:u)+B(v)*(h+o*g),l=(n+i)/2,d=(m.innerRadius+m.outerRadius)/2,p=[{name:a,value:r,payload:e}],y=If(m.cx,m.cy,d,l);return M=Gh({percent:o,cornerRadius:s,name:a,tooltipPayload:p,midAngle:l,middleRadius:d,tooltipPosition:y},e,m,{value:sf(e,A),startAngle:n,endAngle:i,payload:e,paddingAngle:B(v)*c})}));return Gh({},m,{sectors:k,data:o,onMouseLeave:r,onMouseEnter:a})},Bh=zh))||Bh,em=$h,tm=Wp({chartName:"PieChart",GraphicalChild:em,eventType:"item",legendContent:"children",axisComponents:[{axisType:"angleAxis",AxisComp:ph},{axisType:"radiusAxis",AxisComp:Th}],formatAxisMap:function(e,t,n,r,a){var o=e.width,i=e.height,s=e.startAngle,u=e.endAngle,l=G(e.cx,o,o/2),c=G(e.cy,i,i/2),d=Hf(o,i,n),f=G(e.innerRadius,d,0),p=G(e.outerRadius,d,.8*d);return Object.keys(t).reduce(function(e,n){var o,i=t[n],d=i.domain,h=i.reversed;if(D()(i.range))"angleAxis"===r?o=[s,u]:"radiusAxis"===r&&(o=[f,p]),h&&(o=[o[1],o[0]]);else{var m=jf(o=i.range,2);s=m[0],u=m[1]}var y=vf(i,a),v=y.realScaleType,b=y.scale;b.domain(d).range(o),bf(b);var g=kf(b,Lf({},i,{realScaleType:v})),A=Lf({},i,g,{range:o,radius:p,realScaleType:v,scale:b,cx:l,cy:c,innerRadius:f,outerRadius:p,startAngle:s,endAngle:u});return Lf({},e,Ef({},n,A))},{})},defaultProps:{layout:"centric",startAngle:0,endAngle:360,cx:"50%",cy:"50%",innerRadius:0,outerRadius:"80%"},propTypes:{layout:s.a.oneOf(["centric"]),startAngle:s.a.number,endAngle:s.a.number,cx:s.a.oneOfType([s.a.number,s.a.string]),cy:s.a.oneOfType([s.a.number,s.a.string]),innerRadius:s.a.oneOfType([s.a.number,s.a.string]),outerRadius:s.a.oneOfType([s.a.number,s.a.string])}}),nm=n(35);function rm(e,t,n,r,a){if(e>=t)return Promise.resolve({patternGraphData:[],calendarGraphData:[]});var o=[],i=function(i){if(!r[i].enabled)return"continue";var s=n.filter(function(e){return e.cal.regex.test(r[i].name)});s.length>0&&o.push(a(i,e,t).then(function(e){return{id:i,events:e,filtered:s}}))};for(var s in r)i(s);return Promise.all(o).then(function(a){var o={},i={},s={},u={};a.forEach(function(e){o[e.id]=e.events,i[e.id]=e.filtered});for(var l=0;lt+2&&(l=5,u="start"),an+2&&(c=10),o.a.createElement("text",{x:r,y:a,dx:l,dy:c,fill:i,textAnchor:u},"".concat(s))}var im=Object(u.withStyles)(am)(function(e){return o.a.createElement(c.a,{item:!0,xs:12,lg:6},o.a.createElement("div",{className:e.classes.patternTableWrapper},o.a.createElement(tm,{width:400,height:250,className:e.classes.pieChart},o.a.createElement(em,{data:e.data,dataKey:"value",cx:200,cy:125,outerRadius:60,fill:nm.a,isAnimationActive:!1,label:om},e.data.map(function(e,t){return o.a.createElement(Vh,{key:t,fill:e.color?e.color:nm.a})})),o.a.createElement(vn,{formatter:function(e){return"".concat(e.toFixed(2)," hr")}}))))});function sm(e){return o.a.createElement(c.a,{container:!0,spacing:0},o.a.createElement(im,{data:e.patternGraphData}),o.a.createElement(c.a,{item:!0,xs:12,lg:6},o.a.createElement("div",{className:e.classes.patternTableWrapper},o.a.createElement(tm,{width:400,height:250,className:e.classes.pieChart},o.a.createElement(em,{data:e.calendarGraphData,dataKey:"value",cx:200,cy:125,innerRadius:40,outerRadius:70,fill:f.a[300],isAnimationActive:!1,label:om},e.calendarGraphData.map(function(e,t){return o.a.createElement(Vh,{key:t,fill:e.color?e.color:f.a[300]})})),o.a.createElement(vn,{formatter:function(e){return"".concat(e.toFixed(2)," hr")}})))))}sm.propTypes={patternGraphData:s.a.array.isRequired,calendarGraphData:s.a.array.isRequired};var um=Object(u.withStyles)(am)(sm)},function(e,t,n){"use strict"; /* object-assign (c) Sindre Sorhus @@ -67,4 +67,4 @@ Object.defineProperty(t,"__esModule",{value:!0});var n=null,r=!1,a=3,o=-1,i=-1,s * @website https://github.com/jsstyles/css-vendor * @license MIT */ -t.prefix=r.default,t.supportedProperty=a.default,t.supportedValue=o.default},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){if(!s)return e;if(null!=u[e])return u[e];(0,o.default)(e)in s.style?u[e]=e:a.default.js+(0,o.default)("-"+e)in s.style?u[e]=a.default.css+e:u[e]=!1;return u[e]};var r=i(n(63)),a=i(n(90)),o=i(n(391));function i(e){return e&&e.__esModule?e:{default:e}}var s=void 0,u={};if(r.default){s=document.createElement("p");var l=window.getComputedStyle(document.documentElement,"");for(var c in l)isNaN(c)||(u[l[c]]=l[c])}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return e.replace(r,a)};var r=/[-\s]+(.)?/g;function a(e,t){return t?t.toUpperCase():""}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){if(!s)return t;if("string"!=typeof t||!isNaN(parseInt(t,10)))return t;var n=e+t;if(null!=i[n])return i[n];try{s.style[e]=t}catch(e){return i[n]=!1,!1}""!==s.style[e]?i[n]=t:("-ms-flex"===(t=a.default.css+t)&&(t="-ms-flexbox"),s.style[e]=t,""!==s.style[e]&&(i[n]=t));i[n]||(i[n]=!1);return s.style[e]="",i[n]};var r=o(n(63)),a=o(n(90));function o(e){return e&&e.__esModule?e:{default:e}}var i={},s=void 0;r.default&&(s=document.createElement("p"))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(){function e(e,t){return e.length-t.length}return{onProcessStyle:function(t,n){if("style"!==n.type)return t;var r={},a=Object.keys(t).sort(e);for(var o in a)r[a[o]]=t[a[o]];return r}}}},function(e,t,n){"use strict";var r=n(395),a=n(3);Object.defineProperty(t,"__esModule",{value:!0}),t.default=t.MuiThemeProviderOld=void 0;var o=a(n(9)),i=a(n(7)),s=a(n(12)),u=a(n(13)),l=a(n(16)),c=a(n(17)),d=a(n(18)),f=a(n(1)),p=a(n(0)),h=(a(n(19)),a(n(396))),m=n(14),y=r(n(91)),v=function(e){function t(e,n){var r;return(0,s.default)(this,t),(r=(0,l.default)(this,(0,c.default)(t).call(this))).broadcast=(0,h.default)(),r.outerTheme=y.default.initial(n),r.broadcast.setState(r.mergeOuterLocalTheme(e.theme)),r}return(0,d.default)(t,e),(0,u.default)(t,[{key:"getChildContext",value:function(){var e,t=this.props,n=t.disableStylesGeneration,r=t.sheetsCache,a=t.sheetsManager,o=this.context.muiThemeProviderOptions||{};return void 0!==n&&(o.disableStylesGeneration=n),void 0!==r&&(o.sheetsCache=r),void 0!==a&&(o.sheetsManager=a),e={},(0,i.default)(e,y.CHANNEL,this.broadcast),(0,i.default)(e,"muiThemeProviderOptions",o),e}},{key:"componentDidMount",value:function(){var e=this;this.unsubscribeId=y.default.subscribe(this.context,function(t){e.outerTheme=t,e.broadcast.setState(e.mergeOuterLocalTheme(e.props.theme))})}},{key:"componentDidUpdate",value:function(e){this.props.theme!==e.theme&&this.broadcast.setState(this.mergeOuterLocalTheme(this.props.theme))}},{key:"componentWillUnmount",value:function(){null!==this.unsubscribeId&&y.default.unsubscribe(this.context,this.unsubscribeId)}},{key:"mergeOuterLocalTheme",value:function(e){return"function"==typeof e?e(this.outerTheme):this.outerTheme?(0,o.default)({},this.outerTheme,e):e}},{key:"render",value:function(){return this.props.children}}]),t}(f.default.Component);t.MuiThemeProviderOld=v,v.childContextTypes=(0,o.default)({},y.default.contextTypes,{muiThemeProviderOptions:p.default.object}),v.contextTypes=(0,o.default)({},y.default.contextTypes,{muiThemeProviderOptions:p.default.object}),m.ponyfillGlobal.__MUI_STYLES__||(m.ponyfillGlobal.__MUI_STYLES__={}),m.ponyfillGlobal.__MUI_STYLES__.MuiThemeProvider||(m.ponyfillGlobal.__MUI_STYLES__.MuiThemeProvider=v);var b=m.ponyfillGlobal.__MUI_STYLES__.MuiThemeProvider;t.default=b},function(e,t){e.exports=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){var r=Object.defineProperty&&Object.getOwnPropertyDescriptor?Object.getOwnPropertyDescriptor(e,n):{};r.get||r.set?Object.defineProperty(t,n,r):t[n]=e[n]}return t.default=e,t}},function(e,t,n){"use strict";n.r(t),t.default=function(e){var t={},n=1,r=e;return{getState:function(){return r},setState:function(e){r=e;for(var n=Object.keys(t),a=0,o=n.length;a2?arguments[2]:{},o=r(t);a&&(o=i.call(o,Object.getOwnPropertySymbols(t)));for(var s=0;s=t||n<0||v&&e-m>=d}function k(){var e=a();if(A(e))return M(e);p=setTimeout(k,function(e){var n=t-(e-h);return v?u(n,d-(e-m)):n}(e))}function M(e){return p=void 0,b&&l?g(e):(l=c=void 0,f)}function w(){var e=a(),n=A(e);if(l=arguments,c=this,h=e,n){if(void 0===p)return function(e){return m=e,p=setTimeout(k,t),y?g(e):f}(h);if(v)return p=setTimeout(k,t),g(h)}return void 0===p&&(p=setTimeout(k,t)),f}return t=o(t)||0,r(n)&&(y=!!n.leading,d=(v="maxWait"in n)?s(o(n.maxWait)||0,t):d,b="trailing"in n?!!n.trailing:b),w.cancel=function(){void 0!==p&&clearTimeout(p),m=0,l=h=c=p=void 0},w.flush=function(){return void 0===p?f:M(a())},w}},function(e,t,n){var r=n(23);e.exports=function(){return r.Date.now()}},function(e,t,n){var r=n(53),a=Object.prototype,o=a.hasOwnProperty,i=a.toString,s=r?r.toStringTag:void 0;e.exports=function(e){var t=o.call(e,s),n=e[s];try{e[s]=void 0;var r=!0}catch(e){}var a=i.call(e);return r&&(t?e[s]=n:delete e[s]),a}},function(e,t){var n=Object.prototype.toString;e.exports=function(e){return n.call(e)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r,a=(r=n(1))&&r.__esModule?r:{default:r};var o=function(){return function(e){return a.default.createElement("svg",e,a.default.createElement("path",{fillRule:"evenodd",d:"M11.53.47a.75.75 0 0 0-1.061 0l-4.47 4.47L1.529.47A.75.75 0 1 0 .468 1.531l4.47 4.47-4.47 4.47a.75.75 0 1 0 1.061 1.061l4.47-4.47 4.47 4.47a.75.75 0 1 0 1.061-1.061l-4.47-4.47 4.47-4.47a.75.75 0 0 0 0-1.061z"}))}}();o.defaultProps={focusable:"false",viewBox:"0 0 12 12"};var i=o;t.default=i},function(e,t,n){"use strict";var r=n(3);Object.defineProperty(t,"__esModule",{value:!0}),t.default=t.styles=void 0;var a=r(n(7)),o=r(n(10)),i=r(n(9)),s=r(n(1)),u=(r(n(0)),r(n(4))),l=(n(14),r(n(15))),c=n(119),d=(r(n(417)),[0,8,16,24,32,40]),f=["auto",!0,1,2,3,4,5,6,7,8,9,10,11,12];var p=function(e){return(0,i.default)({container:{boxSizing:"border-box",display:"flex",flexWrap:"wrap",width:"100%"},item:{boxSizing:"border-box",margin:"0"},zeroMinWidth:{minWidth:0},"direction-xs-column":{flexDirection:"column"},"direction-xs-column-reverse":{flexDirection:"column-reverse"},"direction-xs-row-reverse":{flexDirection:"row-reverse"},"wrap-xs-nowrap":{flexWrap:"nowrap"},"wrap-xs-wrap-reverse":{flexWrap:"wrap-reverse"},"align-items-xs-center":{alignItems:"center"},"align-items-xs-flex-start":{alignItems:"flex-start"},"align-items-xs-flex-end":{alignItems:"flex-end"},"align-items-xs-baseline":{alignItems:"baseline"},"align-content-xs-center":{alignContent:"center"},"align-content-xs-flex-start":{alignContent:"flex-start"},"align-content-xs-flex-end":{alignContent:"flex-end"},"align-content-xs-space-between":{alignContent:"space-between"},"align-content-xs-space-around":{alignContent:"space-around"},"justify-xs-center":{justifyContent:"center"},"justify-xs-flex-end":{justifyContent:"flex-end"},"justify-xs-space-between":{justifyContent:"space-between"},"justify-xs-space-around":{justifyContent:"space-around"},"justify-xs-space-evenly":{justifyContent:"space-evenly"}},function(e,t){var n={};return d.forEach(function(e,r){0!==r&&(n["spacing-".concat(t,"-").concat(e)]={margin:-e/2,width:"calc(100% + ".concat(e,"px)"),"& > $item":{padding:e/2}})}),n}(0,"xs"),c.keys.reduce(function(t,n){return function(e,t,n){var r={};f.forEach(function(e){var t="grid-".concat(n,"-").concat(e);if(!0!==e)if("auto"!==e){var a="".concat(Math.round(e/12*1e8)/1e6,"%");r[t]={flexBasis:a,flexGrow:0,maxWidth:a}}else r[t]={flexBasis:"auto",flexGrow:0,maxWidth:"none"};else r[t]={flexBasis:0,flexGrow:1,maxWidth:"100%"}}),"xs"===n?(0,i.default)(e,r):e[t.breakpoints.up(n)]=r}(t,e,n),t},{}))};function h(e){var t,n=e.alignContent,r=e.alignItems,l=e.classes,c=e.className,d=e.component,f=e.container,p=e.direction,m=e.item,y=e.justify,v=e.lg,b=e.md,g=e.sm,A=e.spacing,k=e.wrap,M=e.xl,w=e.xs,x=e.zeroMinWidth,S=(0,o.default)(e,["alignContent","alignItems","classes","className","component","container","direction","item","justify","lg","md","sm","spacing","wrap","xl","xs","zeroMinWidth"]),D=(0,u.default)((t={},(0,a.default)(t,l.container,f),(0,a.default)(t,l.item,m),(0,a.default)(t,l.zeroMinWidth,x),(0,a.default)(t,l["spacing-xs-".concat(String(A))],f&&0!==A),(0,a.default)(t,l["direction-xs-".concat(String(p))],p!==h.defaultProps.direction),(0,a.default)(t,l["wrap-xs-".concat(String(k))],k!==h.defaultProps.wrap),(0,a.default)(t,l["align-items-xs-".concat(String(r))],r!==h.defaultProps.alignItems),(0,a.default)(t,l["align-content-xs-".concat(String(n))],n!==h.defaultProps.alignContent),(0,a.default)(t,l["justify-xs-".concat(String(y))],y!==h.defaultProps.justify),(0,a.default)(t,l["grid-xs-".concat(String(w))],!1!==w),(0,a.default)(t,l["grid-sm-".concat(String(g))],!1!==g),(0,a.default)(t,l["grid-md-".concat(String(b))],!1!==b),(0,a.default)(t,l["grid-lg-".concat(String(v))],!1!==v),(0,a.default)(t,l["grid-xl-".concat(String(M))],!1!==M),t),c);return s.default.createElement(d,(0,i.default)({className:D},S))}t.styles=p,h.defaultProps={alignContent:"stretch",alignItems:"stretch",component:"div",container:!1,direction:"row",item:!1,justify:"flex-start",lg:!1,md:!1,sm:!1,spacing:0,wrap:"wrap",xl:!1,xs:!1,zeroMinWidth:!1};var m=(0,l.default)(p,{name:"MuiGrid"})(h);t.default=m},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r=function(e){return function(){return null}};t.default=r},function(e,t){e.exports=function(e,t){for(var n=-1,r=null==e?0:e.length;++n-1}},function(e,t,n){var r=n(67);e.exports=function(e,t){var n=this.__data__,a=r(n,e);return a<0?(++this.size,n.push([e,t])):n[a][1]=t,this}},function(e,t,n){var r=n(66);e.exports=function(){this.__data__=new r,this.size=0}},function(e,t){e.exports=function(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}},function(e,t){e.exports=function(e){return this.__data__.get(e)}},function(e,t){e.exports=function(e){return this.__data__.has(e)}},function(e,t,n){var r=n(66),a=n(98),o=n(99),i=200;e.exports=function(e,t){var n=this.__data__;if(n instanceof r){var s=n.__data__;if(!a||s.length-1?s[u?t[l]:l]:void 0}}},function(e,t,n){var r=n(279),a=n(24),o=n(492),i=Math.max;e.exports=function(e,t,n){var s=null==e?0:e.length;if(!s)return-1;var u=null==n?0:o(n);return u<0&&(u=i(s+u,0)),r(e,a(t,3),u)}},function(e,t,n){var r=n(280);e.exports=function(e){var t=r(e),n=t%1;return t==t?n?t-n:t:0}},function(e,t,n){var r=n(53),a=n(93),o=n(8),i=r?r.isConcatSpreadable:void 0;e.exports=function(e){return o(e)||a(e)||!!(i&&e&&e[i])}},function(e,t,n){var r=n(54),a=n(24),o=n(282),i=n(495),s=n(96),u=n(496),l=n(43);e.exports=function(e,t,n){var c=-1;t=r(t.length?t:[l],s(a));var d=o(e,function(e,n,a){return{criteria:r(t,function(t){return t(e)}),index:++c,value:e}});return i(d,function(e,t){return u(e,t,n)})}},function(e,t){e.exports=function(e,t){var n=e.length;for(e.sort(t);n--;)e[n]=e[n].value;return e}},function(e,t,n){var r=n(497);e.exports=function(e,t,n){for(var a=-1,o=e.criteria,i=t.criteria,s=o.length,u=n.length;++a=u?l:l*("desc"==n[a]?-1:1)}return e.index-t.index}},function(e,t,n){var r=n(41);e.exports=function(e,t){if(e!==t){var n=void 0!==e,a=null===e,o=e==e,i=r(e),s=void 0!==t,u=null===t,l=t==t,c=r(t);if(!u&&!c&&!i&&e>t||i&&s&&l&&!u&&!c||a&&s&&l||!n&&l||!o)return 1;if(!a&&!i&&!c&&e0){if(++t>=n)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}},function(e,t,n){var r=n(505),a=n(71),o=n(280);e.exports=function(e){return function(t,n,i){return i&&"number"!=typeof i&&a(t,n,i)&&(n=i=void 0),t=o(t),void 0===n?(n=t,t=0):n=o(n),i=void 0===i?tr&&(a=r,o=n),[a,o]}function c(e,t,n){if(e.lte(0))return new r.default(0);var a=o.default.getDigitCount(e.toNumber()),i=new r.default(10).pow(a),s=e.div(i),u=1!==a?.05:.1,l=new r.default(Math.ceil(s.div(u).toNumber())).add(n).mul(u).mul(i);return t?l:new r.default(Math.ceil(l))}function d(e,t,n){var i=1,s=new r.default(e);if(!s.isint()&&n){var u=Math.abs(e);u<1?(i=new r.default(10).pow(o.default.getDigitCount(e)-1),s=new r.default(Math.floor(s.div(i).toNumber())).mul(i)):u>1&&(s=new r.default(Math.floor(e)))}else 0===e?s=new r.default(Math.floor((t-1)/2)):n||(s=new r.default(Math.floor(e)));var l=Math.floor((t-1)/2);return(0,a.compose)((0,a.map)(function(e){return s.add(new r.default(e-l).mul(i)).toNumber()}),a.range)(0,t)}var f=(0,a.memoize)(function(e){var t=u(e,2),n=t[0],i=t[1],f=arguments.length>1&&void 0!==arguments[1]?arguments[1]:6,p=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],h=Math.max(f,2),m=u(l([n,i]),2),y=m[0],v=m[1];if(y===-1/0||v===1/0){var b=v===1/0?[y].concat(s((0,a.range)(0,f-1).map(function(){return 1/0}))):s((0,a.range)(0,f-1).map(function(){return-1/0})).concat([v]);return n>i?(0,a.reverse)(b):b}if(y===v)return d(y,f,p);var g=function e(t,n,a,o){var i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:0;if(!Number.isFinite((n-t)/(a-1)))return{step:new r.default(0),tickMin:new r.default(0),tickMax:new r.default(0)};var s,u=c(new r.default(n).sub(t).div(a-1),o,i);s=t<=0&&n>=0?new r.default(0):(s=new r.default(t).add(n).div(2)).sub(new r.default(s).mod(u));var l=Math.ceil(s.sub(t).div(u).toNumber()),d=Math.ceil(new r.default(n).sub(s).div(u).toNumber()),f=l+d+1;return f>a?e(t,n,a,o,i+1):(f0?d+(a-f):d,l=n>0?l:l+(a-f)),{step:u,tickMin:s.sub(new r.default(l).mul(u)),tickMax:s.add(new r.default(d).mul(u))})}(y,v,h,p),A=g.step,k=g.tickMin,M=g.tickMax,w=o.default.rangeStep(k,M.add(new r.default(.1).mul(A)),A);return n>i?(0,a.reverse)(w):w});t.getNiceTickValues=f;var p=(0,a.memoize)(function(e){var t=u(e,2),n=t[0],o=t[1],i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:6,s=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],f=Math.max(i,2),p=u(l([n,o]),2),h=p[0],m=p[1];if(h===-1/0||m===1/0)return[n,o];if(h===m)return d(h,i,s);var y=c(new r.default(m).sub(h).div(f-1),s,0),v=(0,a.compose)((0,a.map)(function(e){return new r.default(h).add(new r.default(e).mul(y)).toNumber()}),a.range)(0,f).filter(function(e){return e>=h&&e<=m});return n>o?(0,a.reverse)(v):v});t.getTickValues=p;var h=(0,a.memoize)(function(e,t){var n=u(e,2),i=n[0],d=n[1],f=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],p=u(l([i,d]),2),h=p[0],m=p[1];if(h===-1/0||m===1/0)return[i,d];if(h===m)return[h];var y=Math.max(t,2),v=c(new r.default(m).sub(h).div(y-1),f,0),b=s(o.default.rangeStep(new r.default(h),new r.default(m).sub(new r.default(.99).mul(v)),v)).concat([m]);return i>d?(0,a.reverse)(b):b});t.getTickValuesFixedDomain=h},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r,a=(r=n(287))&&r.__esModule?r:{default:r},o=n(288);var i={rangeStep:function(e,t,n){for(var r=new a.default(e),o=[];r.lt(t);)o.push(r.toNumber()),r=r.add(n);return o},getDigitCount:function(e){return 0===e?1:Math.floor(new a.default(e).abs().log(10).toNumber())+1},interpolateNumber:(0,o.curry)(function(e,t,n){var r=+e;return r+n*(+t-r)}),uninterpolateNumber:(0,o.curry)(function(e,t,n){var r=t-+e;return(n-e)/(r=r||1/0)}),uninterpolateTruncation:(0,o.curry)(function(e,t,n){var r=t-+e;return r=r||1/0,Math.max(0,Math.min(1,(n-e)/r))})};t.default=i},function(e,t,n){var r=n(64);e.exports=function(e,t){var n;return r(e,function(e,r,a){return!(n=t(e,r,a))}),!!n}},function(e,t,n){var r=n(284);e.exports=function(e,t,n){"__proto__"==t&&r?r(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}},function(e,t){function n(e,t,n){e instanceof RegExp&&(e=r(e,n)),t instanceof RegExp&&(t=r(t,n));var o=a(e,t,n);return o&&{start:o[0],end:o[1],pre:n.slice(0,o[0]),body:n.slice(o[0]+e.length,o[1]),post:n.slice(o[1]+t.length)}}function r(e,t){var n=t.match(e);return n?n[0]:null}function a(e,t,n){var r,a,o,i,s,u=n.indexOf(e),l=n.indexOf(t,u+1),c=u;if(u>=0&&l>0){for(r=[],o=n.length;c>=0&&!s;)c==u?(r.push(c),u=n.indexOf(e,c+1)):1==r.length?s=[r.pop(),l]:((a=r.pop())=0?u:l;r.length&&(s=[o,i])}return s}e.exports=n,n.range=a},function(e,t,n){var r=n(513);function a(e,t,n){var o=e;return function(e,t){var n=[],a="string"==typeof t?new RegExp("\\b("+t+")\\("):t;do{var o=a.exec(e);if(!o)return n;if(void 0===o[1])throw new Error("Missing the first couple of parenthesis to get the function identifier in "+t);var i=o[1],s=o.index,u=r("(",")",e.substring(s));if(!u||u.start!==o[0].length-1)throw new SyntaxError(i+"(): missing closing ')' in the value '"+e+"'");n.push({matches:u,functionIdentifier:i}),e=u.post}while(a.test(e));return n}(e,t).reduce(function(e,r){return e.replace(r.functionIdentifier+"("+r.matches.body+")",function(e,t,n,r,o){return n(a(e,o,n),t,r)}(r.matches.body,r.functionIdentifier,n,o,t))},e)}e.exports=a},function(e,t){function n(e,t,n){e instanceof RegExp&&(e=r(e,n)),t instanceof RegExp&&(t=r(t,n));var o=a(e,t,n);return o&&{start:o[0],end:o[1],pre:n.slice(0,o[0]),body:n.slice(o[0]+e.length,o[1]),post:n.slice(o[1]+t.length)}}function r(e,t){var n=t.match(e);return n?n[0]:null}function a(e,t,n){var r,a,o,i,s,u=n.indexOf(e),l=n.indexOf(t,u+1),c=u;if(u>=0&&l>0){for(r=[],o=n.length;c>=0&&!s;)c==u?(r.push(c),u=n.indexOf(e,c+1)):1==r.length?s=[r.pop(),l]:((a=r.pop())=0?u:l;r.length&&(s=[o,i])}return s}e.exports=n,n.range=a},function(e,t,n){var r=n(515);r.prototype.formulaEval=function(){"use strict";for(var e,t,n,r=[],a=this.value,o=0;o"+t.value+""+a[o].show+""+e.value+"",type:10}):r.push({value:(1!=t.type?"(":"")+t.value+(1!=t.type?")":"")+""+e.value+"",type:1})):2===a[o].type||9===a[o].type?(e=r.pop(),t=r.pop(),r.push({value:(1!=t.type?"(":"")+t.value+(1!=t.type?")":"")+a[o].show+(1!=e.type?"(":"")+e.value+(1!=e.type?")":""),type:a[o].type})):12===a[o].type&&(e=r.pop(),t=r.pop(),n=r.pop(),r.push({value:a[o].show+"("+n.value+","+t.value+","+e.value+")",type:12}));return r[0].value},e.exports=r},function(e,t,n){var r=n(516);r.prototype.postfixEval=function(e){"use strict";(e=e||{}).PI=Math.PI,e.E=Math.E;for(var t,n,a,o=[],i=this.value,s=void 0!==e.n,u=0;u1)throw new r.exception("Uncaught Syntax error");return o[0].value>1e15?"Infinity":parseFloat(o[0].value.toFixed(15))},r.eval=function(e,t,n){return void 0===t?this.lex(e).toPostfix().postfixEval():void 0===n?void 0!==t.length?this.lex(e,t).toPostfix().postfixEval():this.lex(e).toPostfix().postfixEval(t):this.lex(e,t).toPostfix().postfixEval(n)},e.exports=r},function(e,t,n){var r=n(517);r.prototype.toPostfix=function(){"use strict";for(var e,t,n,a,o,i=[],s=[{value:"(",type:4,pre:0}],u=this.value,l=1;ln)s.push(e);else{for(;n>=a&&!c||c&&ab.length-2?b.length-1:w.length-i;y>0;y--)for(A=0;A=120&&v.length>=120)?new r(p&&v):void 0}v=e[0];var b=-1,g=h[0];e:for(;++b-1}},function(e,t,n){var r=n(279),a=n(524),o=n(525);e.exports=function(e,t,n){return t==t?o(e,t,n):r(e,a,n)}},function(e,t){e.exports=function(e){return e!=e}},function(e,t){e.exports=function(e,t,n){for(var r=n-1,a=e.length;++r=0||(a[n]=e[n]);return a}(e,["children","in"]),i=r.default.Children.toArray(t),s=i[0],u=i[1];return delete a.onEnter,delete a.onEntering,delete a.onEntered,delete a.onExit,delete a.onExiting,delete a.onExited,r.default.createElement(o.default,a,n?r.default.cloneElement(s,{key:"first",onEnter:this.handleEnter,onEntering:this.handleEntering,onEntered:this.handleEntered}):r.default.cloneElement(u,{key:"second",onEnter:this.handleExit,onEntering:this.handleExiting,onEntered:this.handleExited}))},i}(r.default.Component);s.propTypes={};var u=s;t.default=u,e.exports=t.default},function(e,t,n){"use strict";t.__esModule=!0,t.getChildMapping=a,t.mergeChildMappings=o,t.getInitialChildMapping=function(e,t){return a(e.children,function(n){return(0,r.cloneElement)(n,{onExited:t.bind(null,n),in:!0,appear:i(n,"appear",e),enter:i(n,"enter",e),exit:i(n,"exit",e)})})},t.getNextChildMapping=function(e,t,n){var s=a(e.children),u=o(t,s);return Object.keys(u).forEach(function(a){var o=u[a];if((0,r.isValidElement)(o)){var l=a in t,c=a in s,d=t[a],f=(0,r.isValidElement)(d)&&!d.props.in;!c||l&&!f?c||!l||f?c&&l&&(0,r.isValidElement)(d)&&(u[a]=(0,r.cloneElement)(o,{onExited:n.bind(null,o),in:d.props.in,exit:i(o,"exit",e),enter:i(o,"enter",e)})):u[a]=(0,r.cloneElement)(o,{in:!1}):u[a]=(0,r.cloneElement)(o,{onExited:n.bind(null,o),in:!0,exit:i(o,"exit",e),enter:i(o,"enter",e)})}}),u};var r=n(1);function a(e,t){var n=Object.create(null);return e&&r.Children.map(e,function(e){return e}).forEach(function(e){n[e.key]=function(e){return t&&(0,r.isValidElement)(e)?t(e):e}(e)}),n}function o(e,t){function n(n){return n in t?t[n]:e[n]}e=e||{},t=t||{};var r,a=Object.create(null),o=[];for(var i in e)i in t?o.length&&(a[i]=o,o=[]):o.push(i);var s={};for(var u in t){if(a[u])for(r=0;r=0?r=setTimeout(u,t-l):(r=null,n||(s=e.apply(o,a),o=a=null))}null==t&&(t=100);var l=function(){o=this,a=arguments,i=Date.now();var l=n&&!r;return r||(r=setTimeout(u,t)),l&&(s=e.apply(o,a),o=a=null),s};return l.clear=function(){r&&(clearTimeout(r),r=null)},l.flush=function(){r&&(s=e.apply(o,a),o=a=null,clearTimeout(r),r=null)},l}n.debounce=n,e.exports=n},function(e,t,n){"use strict";var r=n(3);Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"default",{enumerable:!0,get:function(){return a.default}});var a=r(n(882))},function(e,t,n){"use strict";var r=n(3);t.__esModule=!0,t.default=void 0;var a=r(n(604)),o=function(e){return(0,a.default)("displayName",e)};t.default=o},function(e,t,n){"use strict";var r=n(3);t.__esModule=!0,t.default=void 0;var a=r(n(605)),o=function(e,t){return t+"("+(0,a.default)(e)+")"};t.default=o},function(e,t,n){"use strict";var r=n(1),a=n.n(r);t.a=function(e){return a.a.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 98.905998 93.557997",version:"1.1",style:e.style},a.a.createElement("g",{id:"g13",transform:"translate(-153.533,-203.047)"},a.a.createElement("g",{id:"g29"},a.a.createElement("g",{id:"g27"},a.a.createElement("polygon",{id:"polygon7",points:"252.439,241.924 234.556,288.703 185.103,296.605 153.533,257.728 171.416,210.949 220.869,203.047 ",style:{fill:"#ff8000"}}),a.a.createElement("g",{id:"g11",transform:"translate(167.24355,224.20734)"},a.a.createElement("text",{id:"text9",style:{fontStyle:"normal",fontVariant:"normal",fontWeight:"normal",fontStretch:"normal",fontSize:75,fontFamily:"TypoPRO Fantasque Sans Mono",fill:"#ffeade"},transform:"translate(0.586,49.072)"},"Cr"))))))}},function(e,t,n){"use strict";const r=n(577),a=Symbol("max"),o=Symbol("length"),i=Symbol("lengthCalculator"),s=Symbol("allowStale"),u=Symbol("maxAge"),l=Symbol("dispose"),c=Symbol("noDisposeOnSet"),d=Symbol("lruList"),f=Symbol("cache"),p=Symbol("updateAgeOnGet"),h=()=>1;const m=(e,t,n)=>{const r=e[f].get(t);if(r){const t=r.value;if(y(e,t)){if(b(e,r),!e[s])return}else n&&(e[p]&&(r.value.now=Date.now()),e[d].unshiftNode(r));return t.value}},y=(e,t)=>{if(!t||!t.maxAge&&!e[u])return!1;const n=Date.now()-t.now;return t.maxAge?n>t.maxAge:e[u]&&n>e[u]},v=e=>{if(e[o]>e[a])for(let t=e[d].tail;e[o]>e[a]&&null!==t;){const n=t.prev;b(e,t),t=n}},b=(e,t)=>{if(t){const n=t.value;e[l]&&e[l](n.key,n.value),e[o]-=n.length,e[f].delete(n.key),e[d].removeNode(t)}};class g{constructor(e,t,n,r,a){this.key=e,this.value=t,this.length=n,this.now=r,this.maxAge=a||0}}const A=(e,t,n,r)=>{let a=n.value;y(e,a)&&(b(e,n),e[s]||(a=void 0)),a&&t.call(r,a.value,a.key,e)};e.exports=class{constructor(e){if("number"==typeof e&&(e={max:e}),e||(e={}),e.max&&("number"!=typeof e.max||e.max<0))throw new TypeError("max must be a non-negative number");this[a]=e.max||1/0;const t=e.length||h;if(this[i]="function"!=typeof t?h:t,this[s]=e.stale||!1,e.maxAge&&"number"!=typeof e.maxAge)throw new TypeError("maxAge must be a number");this[u]=e.maxAge||0,this[l]=e.dispose,this[c]=e.noDisposeOnSet||!1,this[p]=e.updateAgeOnGet||!1,this.reset()}set max(e){if("number"!=typeof e||e<0)throw new TypeError("max must be a non-negative number");this[a]=e||1/0,v(this)}get max(){return this[a]}set allowStale(e){this[s]=!!e}get allowStale(){return this[s]}set maxAge(e){if("number"!=typeof e)throw new TypeError("maxAge must be a non-negative number");this[u]=e,v(this)}get maxAge(){return this[u]}set lengthCalculator(e){"function"!=typeof e&&(e=h),e!==this[i]&&(this[i]=e,this[o]=0,this[d].forEach(e=>{e.length=this[i](e.value,e.key),this[o]+=e.length})),v(this)}get lengthCalculator(){return this[i]}get length(){return this[o]}get itemCount(){return this[d].length}rforEach(e,t){t=t||this;for(let n=this[d].tail;null!==n;){const r=n.prev;A(this,e,n,t),n=r}}forEach(e,t){t=t||this;for(let n=this[d].head;null!==n;){const r=n.next;A(this,e,n,t),n=r}}keys(){return this[d].toArray().map(e=>e.key)}values(){return this[d].toArray().map(e=>e.value)}reset(){this[l]&&this[d]&&this[d].length&&this[d].forEach(e=>this[l](e.key,e.value)),this[f]=new Map,this[d]=new r,this[o]=0}dump(){return this[d].map(e=>!y(this,e)&&{k:e.key,v:e.value,e:e.now+(e.maxAge||0)}).toArray().filter(e=>e)}dumpLru(){return this[d]}set(e,t,n){if((n=n||this[u])&&"number"!=typeof n)throw new TypeError("maxAge must be a number");const r=n?Date.now():0,s=this[i](t,e);if(this[f].has(e)){if(s>this[a])return b(this,this[f].get(e)),!1;const i=this[f].get(e).value;return this[l]&&(this[c]||this[l](e,i.value)),i.now=r,i.maxAge=n,i.value=t,this[o]+=s-i.length,i.length=s,this.get(e),v(this),!0}const p=new g(e,t,s,r,n);return p.length>this[a]?(this[l]&&this[l](e,t),!1):(this[o]+=p.length,this[d].unshift(p),this[f].set(e,this[d].head),v(this),!0)}has(e){if(!this[f].has(e))return!1;const t=this[f].get(e).value;return!y(this,t)}get(e){return m(this,e,!0)}peek(e){return m(this,e,!1)}pop(){const e=this[d].tail;return e?(b(this,e),e.value):null}del(e){b(this,this[f].get(e))}load(e){this.reset();const t=Date.now();for(let n=e.length-1;n>=0;n--){const r=e[n],a=r.e||0;if(0===a)this.set(r.k,r.v);else{const e=a-t;e>0&&this.set(r.k,r.v,e)}}}prune(){this[f].forEach((e,t)=>m(this,t,!1))}}},function(e,t){function n(e,t,n,r,a,o,i){try{var s=e[o](i),u=s.value}catch(e){return void n(e)}s.done?t(u):Promise.resolve(u).then(r,a)}e.exports=function(e){return function(){var t=this,r=arguments;return new Promise(function(a,o){var i=e.apply(t,r);function s(e){n(i,a,o,s,u,"next",e)}function u(e){n(i,a,o,s,u,"throw",e)}s(void 0)})}}},function(e,t,n){"use strict";var r=n(3);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var a=r(n(1)),o=(0,r(n(293)).default)(a.default.createElement(a.default.Fragment,null,a.default.createElement("path",{d:"M17.65 6.35C16.2 4.9 14.21 4 12 4c-4.42 0-7.99 3.58-7.99 8s3.57 8 7.99 8c3.73 0 6.84-2.55 7.73-6h-2.08c-.82 2.33-3.04 4-5.65 4-3.31 0-6-2.69-6-6s2.69-6 6-6c1.66 0 3.14.69 4.22 1.78L13 11h7V4l-2.35 2.35z"}),a.default.createElement("path",{fill:"none",d:"M0 0h24v24H0z"})),"Refresh");t.default=o},function(e,t,n){"use strict";(function(e){n.d(t,"a",function(){return r});Boolean("localhost"===window.location.hostname||"[::1]"===window.location.hostname||window.location.hostname.match(/^127(?:\.(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)){3}$/));function r(){"serviceWorker"in navigator&&navigator.serviceWorker.ready.then(function(e){e.unregister()})}}).call(this,n(310))},function(e,t,n){"use strict";var r=Object.getOwnPropertyDescriptor?function(){return Object.getOwnPropertyDescriptor(arguments,"callee").get}():function(){throw new TypeError},a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator,o=Object.getPrototypeOf||function(e){return e.__proto__},i=void 0,s="undefined"==typeof Uint8Array?void 0:o(Uint8Array),u={"$ %Array%":Array,"$ %ArrayBuffer%":"undefined"==typeof ArrayBuffer?void 0:ArrayBuffer,"$ %ArrayBufferPrototype%":"undefined"==typeof ArrayBuffer?void 0:ArrayBuffer.prototype,"$ %ArrayIteratorPrototype%":a?o([][Symbol.iterator]()):void 0,"$ %ArrayPrototype%":Array.prototype,"$ %ArrayProto_entries%":Array.prototype.entries,"$ %ArrayProto_forEach%":Array.prototype.forEach,"$ %ArrayProto_keys%":Array.prototype.keys,"$ %ArrayProto_values%":Array.prototype.values,"$ %AsyncFromSyncIteratorPrototype%":void 0,"$ %AsyncFunction%":void 0,"$ %AsyncFunctionPrototype%":void 0,"$ %AsyncGenerator%":void 0,"$ %AsyncGeneratorFunction%":void 0,"$ %AsyncGeneratorPrototype%":void 0,"$ %AsyncIteratorPrototype%":i&&a&&Symbol.asyncIterator?i[Symbol.asyncIterator]():void 0,"$ %Atomics%":"undefined"==typeof Atomics?void 0:Atomics,"$ %Boolean%":Boolean,"$ %BooleanPrototype%":Boolean.prototype,"$ %DataView%":"undefined"==typeof DataView?void 0:DataView,"$ %DataViewPrototype%":"undefined"==typeof DataView?void 0:DataView.prototype,"$ %Date%":Date,"$ %DatePrototype%":Date.prototype,"$ %decodeURI%":decodeURI,"$ %decodeURIComponent%":decodeURIComponent,"$ %encodeURI%":encodeURI,"$ %encodeURIComponent%":encodeURIComponent,"$ %Error%":Error,"$ %ErrorPrototype%":Error.prototype,"$ %eval%":eval,"$ %EvalError%":EvalError,"$ %EvalErrorPrototype%":EvalError.prototype,"$ %Float32Array%":"undefined"==typeof Float32Array?void 0:Float32Array,"$ %Float32ArrayPrototype%":"undefined"==typeof Float32Array?void 0:Float32Array.prototype,"$ %Float64Array%":"undefined"==typeof Float64Array?void 0:Float64Array,"$ %Float64ArrayPrototype%":"undefined"==typeof Float64Array?void 0:Float64Array.prototype,"$ %Function%":Function,"$ %FunctionPrototype%":Function.prototype,"$ %Generator%":void 0,"$ %GeneratorFunction%":void 0,"$ %GeneratorPrototype%":void 0,"$ %Int8Array%":"undefined"==typeof Int8Array?void 0:Int8Array,"$ %Int8ArrayPrototype%":"undefined"==typeof Int8Array?void 0:Int8Array.prototype,"$ %Int16Array%":"undefined"==typeof Int16Array?void 0:Int16Array,"$ %Int16ArrayPrototype%":"undefined"==typeof Int16Array?void 0:Int8Array.prototype,"$ %Int32Array%":"undefined"==typeof Int32Array?void 0:Int32Array,"$ %Int32ArrayPrototype%":"undefined"==typeof Int32Array?void 0:Int32Array.prototype,"$ %isFinite%":isFinite,"$ %isNaN%":isNaN,"$ %IteratorPrototype%":a?o(o([][Symbol.iterator]())):void 0,"$ %JSON%":JSON,"$ %JSONParse%":JSON.parse,"$ %Map%":"undefined"==typeof Map?void 0:Map,"$ %MapIteratorPrototype%":"undefined"!=typeof Map&&a?o((new Map)[Symbol.iterator]()):void 0,"$ %MapPrototype%":"undefined"==typeof Map?void 0:Map.prototype,"$ %Math%":Math,"$ %Number%":Number,"$ %NumberPrototype%":Number.prototype,"$ %Object%":Object,"$ %ObjectPrototype%":Object.prototype,"$ %ObjProto_toString%":Object.prototype.toString,"$ %ObjProto_valueOf%":Object.prototype.valueOf,"$ %parseFloat%":parseFloat,"$ %parseInt%":parseInt,"$ %Promise%":"undefined"==typeof Promise?void 0:Promise,"$ %PromisePrototype%":"undefined"==typeof Promise?void 0:Promise.prototype,"$ %PromiseProto_then%":"undefined"==typeof Promise?void 0:Promise.prototype.then,"$ %Promise_all%":"undefined"==typeof Promise?void 0:Promise.all,"$ %Promise_reject%":"undefined"==typeof Promise?void 0:Promise.reject,"$ %Promise_resolve%":"undefined"==typeof Promise?void 0:Promise.resolve,"$ %Proxy%":"undefined"==typeof Proxy?void 0:Proxy,"$ %RangeError%":RangeError,"$ %RangeErrorPrototype%":RangeError.prototype,"$ %ReferenceError%":ReferenceError,"$ %ReferenceErrorPrototype%":ReferenceError.prototype,"$ %Reflect%":"undefined"==typeof Reflect?void 0:Reflect,"$ %RegExp%":RegExp,"$ %RegExpPrototype%":RegExp.prototype,"$ %Set%":"undefined"==typeof Set?void 0:Set,"$ %SetIteratorPrototype%":"undefined"!=typeof Set&&a?o((new Set)[Symbol.iterator]()):void 0,"$ %SetPrototype%":"undefined"==typeof Set?void 0:Set.prototype,"$ %SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?void 0:SharedArrayBuffer,"$ %SharedArrayBufferPrototype%":"undefined"==typeof SharedArrayBuffer?void 0:SharedArrayBuffer.prototype,"$ %String%":String,"$ %StringIteratorPrototype%":a?o(""[Symbol.iterator]()):void 0,"$ %StringPrototype%":String.prototype,"$ %Symbol%":a?Symbol:void 0,"$ %SymbolPrototype%":a?Symbol.prototype:void 0,"$ %SyntaxError%":SyntaxError,"$ %SyntaxErrorPrototype%":SyntaxError.prototype,"$ %ThrowTypeError%":r,"$ %TypedArray%":s,"$ %TypedArrayPrototype%":s?s.prototype:void 0,"$ %TypeError%":TypeError,"$ %TypeErrorPrototype%":TypeError.prototype,"$ %Uint8Array%":"undefined"==typeof Uint8Array?void 0:Uint8Array,"$ %Uint8ArrayPrototype%":"undefined"==typeof Uint8Array?void 0:Uint8Array.prototype,"$ %Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?void 0:Uint8ClampedArray,"$ %Uint8ClampedArrayPrototype%":"undefined"==typeof Uint8ClampedArray?void 0:Uint8ClampedArray.prototype,"$ %Uint16Array%":"undefined"==typeof Uint16Array?void 0:Uint16Array,"$ %Uint16ArrayPrototype%":"undefined"==typeof Uint16Array?void 0:Uint16Array.prototype,"$ %Uint32Array%":"undefined"==typeof Uint32Array?void 0:Uint32Array,"$ %Uint32ArrayPrototype%":"undefined"==typeof Uint32Array?void 0:Uint32Array.prototype,"$ %URIError%":URIError,"$ %URIErrorPrototype%":URIError.prototype,"$ %WeakMap%":"undefined"==typeof WeakMap?void 0:WeakMap,"$ %WeakMapPrototype%":"undefined"==typeof WeakMap?void 0:WeakMap.prototype,"$ %WeakSet%":"undefined"==typeof WeakSet?void 0:WeakSet,"$ %WeakSetPrototype%":"undefined"==typeof WeakSet?void 0:WeakSet.prototype};e.exports=function(e,t){if(arguments.length>1&&"boolean"!=typeof t)throw new TypeError('"allowMissing" argument must be a boolean');var n="$ "+e;if(!(n in u))throw new SyntaxError("intrinsic "+e+" does not exist!");if(void 0===u[n]&&!t)throw new TypeError("intrinsic "+e+" exists, but is not available. Please file an issue!");return u[n]}},function(e,t,n){"use strict";var r=Object.prototype.hasOwnProperty;function a(e,t){return e===t?0!==e||0!==t||1/e==1/t:e!=e&&t!=t}e.exports=function(e,t){if(a(e,t))return!0;if("object"!=typeof e||null===e||"object"!=typeof t||null===t)return!1;var n=Object.keys(e),o=Object.keys(t);if(n.length!==o.length)return!1;for(var i=0;i2?n-2:0),i=2;i0)for(var n=0,a=arguments.length;n1)n=t;else{if(!this.head)throw new TypeError("Reduce of empty list with no initial value");r=this.head.next,n=this.head.value}for(var a=0;null!==r;a++)n=e(n,r.value,a),r=r.next;return n},r.prototype.reduceReverse=function(e,t){var n,r=this.tail;if(arguments.length>1)n=t;else{if(!this.tail)throw new TypeError("Reduce of empty list with no initial value");r=this.tail.prev,n=this.tail.value}for(var a=this.length-1;null!==r;a--)n=e(n,r.value,a),r=r.prev;return n},r.prototype.toArray=function(){for(var e=new Array(this.length),t=0,n=this.head;null!==n;t++)e[t]=n.value,n=n.next;return e},r.prototype.toArrayReverse=function(){for(var e=new Array(this.length),t=0,n=this.tail;null!==n;t++)e[t]=n.value,n=n.prev;return e},r.prototype.slice=function(e,t){(t=t||this.length)<0&&(t+=this.length),(e=e||0)<0&&(e+=this.length);var n=new r;if(tthis.length&&(t=this.length);for(var a=0,o=this.head;null!==o&&athis.length&&(t=this.length);for(var a=this.length,o=this.tail;null!==o&&a>t;a--)o=o.prev;for(;null!==o&&a>e;a--,o=o.prev)n.push(o.value);return n},r.prototype.reverse=function(){for(var e=this.head,t=this.tail,n=e;null!==n;n=n.prev){var r=n.prev;n.prev=n.next,n.next=r}return this.head=t,this.tail=e,this};try{n(578)(r)}catch(e){}},function(e,t,n){"use strict";e.exports=function(e){e.prototype[Symbol.iterator]=function*(){for(let e=this.head;e;e=e.next)yield e.value}}},function(e,t,n){var r=n(333);e.exports=function(e,t){if(!r(e))return e;var n,a;if(t&&"function"==typeof(n=e.toString)&&!r(a=n.call(e)))return a;if("function"==typeof(n=e.valueOf)&&!r(a=n.call(e)))return a;if(!t&&"function"==typeof(n=e.toString)&&!r(a=n.call(e)))return a;throw TypeError("Can't convert object to primitive value")}},function(e,t){e.exports=function(e){if(null==e)throw TypeError("Can't call method on "+e);return e}},function(e,t){var n=Math.ceil,r=Math.floor;e.exports=function(e){return isNaN(e=+e)?0:(e>0?r:n)(e)}},function(e,t,n){var r=n(583)("keys"),a=n(556);e.exports=function(e){return r[e]||(r[e]=a(e))}},function(e,t,n){var r=n(102),a=n(291),o=a["__core-js_shared__"]||(a["__core-js_shared__"]={});(e.exports=function(e,t){return o[e]||(o[e]=void 0!==t?t:{})})("versions",[]).push({version:r.version,mode:n(555)?"pure":"global",copyright:"© 2019 Denis Pushkarev (zloirock.ru)"})},function(e,t){e.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},function(e,t){t.f=Object.getOwnPropertySymbols},function(e,t){e.exports={}},function(e,t,n){var r=n(536),a=n(827),o=n(584),i=n(582)("IE_PROTO"),s=function(){},u=function(){var e,t=n(669)("iframe"),r=o.length;for(t.style.display="none",n(828).appendChild(t),t.src="javascript:",(e=t.contentWindow.document).open(),e.write("