!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.G2Plot=e():t.G2Plot=e()}(window,(function(){return function(t){var e={};function n(i){if(e[i])return e[i].exports;var r=e[i]={i:i,l:!1,exports:{}};return t[i].call(r.exports,r,r.exports,n),r.l=!0,r.exports}return n.m=t,n.c=e,n.d=function(t,e,i){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:i})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var i=Object.create(null);if(n.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var r in t)n.d(i,r,function(e){return t[e]}.bind(null,r));return i},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=188)}([function(t,e,n){"use strict";n.r(e),n.d(e,"contains",(function(){return r})),n.d(e,"includes",(function(){return r})),n.d(e,"difference",(function(){return a})),n.d(e,"find",(function(){return b})),n.d(e,"findIndex",(function(){return O})),n.d(e,"firstValue",(function(){return _})),n.d(e,"flatten",(function(){return w})),n.d(e,"flattenDeep",(function(){return j})),n.d(e,"getRange",(function(){return A})),n.d(e,"pull",(function(){return P})),n.d(e,"pullAt",(function(){return T})),n.d(e,"reduce",(function(){return L})),n.d(e,"remove",(function(){return k})),n.d(e,"sortBy",(function(){return B})),n.d(e,"union",(function(){return N})),n.d(e,"uniq",(function(){return R})),n.d(e,"valuesOfKey",(function(){return V})),n.d(e,"head",(function(){return z})),n.d(e,"last",(function(){return G})),n.d(e,"startsWith",(function(){return Y})),n.d(e,"endsWith",(function(){return X})),n.d(e,"filter",(function(){return o})),n.d(e,"every",(function(){return W})),n.d(e,"some",(function(){return H})),n.d(e,"group",(function(){return $})),n.d(e,"groupBy",(function(){return q})),n.d(e,"groupToMap",(function(){return Z})),n.d(e,"getWrapBehavior",(function(){return K})),n.d(e,"wrapBehavior",(function(){return Q})),n.d(e,"number2color",(function(){return tt})),n.d(e,"parseRadius",(function(){return et})),n.d(e,"clamp",(function(){return nt})),n.d(e,"fixedBase",(function(){return it})),n.d(e,"isDecimal",(function(){return ot})),n.d(e,"isEven",(function(){return at})),n.d(e,"isInteger",(function(){return st})),n.d(e,"isNegative",(function(){return ct})),n.d(e,"isNumberEqual",(function(){return lt})),n.d(e,"isOdd",(function(){return ut})),n.d(e,"isPositive",(function(){return ht})),n.d(e,"max",(function(){return S})),n.d(e,"maxBy",(function(){return ft})),n.d(e,"min",(function(){return M})),n.d(e,"minBy",(function(){return pt})),n.d(e,"mod",(function(){return dt})),n.d(e,"toDegree",(function(){return yt})),n.d(e,"toInteger",(function(){return vt})),n.d(e,"toRadian",(function(){return xt})),n.d(e,"forIn",(function(){return bt})),n.d(e,"has",(function(){return Ot})),n.d(e,"hasKey",(function(){return _t})),n.d(e,"hasValue",(function(){return jt})),n.d(e,"keys",(function(){return g})),n.d(e,"isMatch",(function(){return y})),n.d(e,"values",(function(){return wt})),n.d(e,"lowerCase",(function(){return Mt})),n.d(e,"lowerFirst",(function(){return At})),n.d(e,"substitute",(function(){return Ct})),n.d(e,"upperCase",(function(){return Et})),n.d(e,"upperFirst",(function(){return It})),n.d(e,"getType",(function(){return Ft})),n.d(e,"isArguments",(function(){return Tt})),n.d(e,"isArray",(function(){return h})),n.d(e,"isArrayLike",(function(){return i})),n.d(e,"isBoolean",(function(){return Lt})),n.d(e,"isDate",(function(){return kt})),n.d(e,"isError",(function(){return Dt})),n.d(e,"isFunction",(function(){return l})),n.d(e,"isFinite",(function(){return Bt})),n.d(e,"isNil",(function(){return u})),n.d(e,"isNull",(function(){return Rt})),n.d(e,"isNumber",(function(){return rt})),n.d(e,"isObject",(function(){return p})),n.d(e,"isObjectLike",(function(){return m})),n.d(e,"isPlainObject",(function(){return x})),n.d(e,"isPrototype",(function(){return Vt})),n.d(e,"isRegExp",(function(){return zt})),n.d(e,"isString",(function(){return D})),n.d(e,"isType",(function(){return c})),n.d(e,"isUndefined",(function(){return Gt})),n.d(e,"isElement",(function(){return Yt})),n.d(e,"requestAnimationFrame",(function(){return Xt})),n.d(e,"clearAnimationFrame",(function(){return Wt})),n.d(e,"augment",(function(){return qt})),n.d(e,"clone",(function(){return $t})),n.d(e,"debounce",(function(){return Kt})),n.d(e,"memoize",(function(){return Qt})),n.d(e,"deepMix",(function(){return te})),n.d(e,"each",(function(){return d})),n.d(e,"extend",(function(){return ee})),n.d(e,"indexOf",(function(){return ne})),n.d(e,"isEmpty",(function(){return re})),n.d(e,"isEqual",(function(){return oe})),n.d(e,"isEqualWith",(function(){return ae})),n.d(e,"map",(function(){return se})),n.d(e,"mapValues",(function(){return le})),n.d(e,"mix",(function(){return Ut})),n.d(e,"assign",(function(){return Ut})),n.d(e,"get",(function(){return ue})),n.d(e,"set",(function(){return he})),n.d(e,"pick",(function(){return pe})),n.d(e,"omit",(function(){return de})),n.d(e,"throttle",(function(){return ge})),n.d(e,"toArray",(function(){return ye})),n.d(e,"toString",(function(){return St})),n.d(e,"uniqueId",(function(){return me})),n.d(e,"noop",(function(){return xe})),n.d(e,"identity",(function(){return be})),n.d(e,"size",(function(){return Oe})),n.d(e,"measureTextWidth",(function(){return je})),n.d(e,"getEllipsisText",(function(){return Se})),n.d(e,"Cache",(function(){return Me}));var i=function(t){return null!==t&&"function"!=typeof t&&isFinite(t.length)},r=function(t,e){return!!i(t)&&t.indexOf(e)>-1},o=function(t,e){if(!i(t))return t;for(var n=[],r=0;r-1;)E.call(t,o,1);return t},F=Array.prototype.splice,T=function(t,e){if(!i(t))return[];for(var n=t?e.length:0,r=n-1;n--;){var o=void 0,a=e[n];n!==r&&a===o||(o=a,F.call(t,a,1))}return t},L=function(t,e,n){if(!h(t)&&!x(t))return t;var i=n;return d(t,(function(t,n){i=e(i,t,n)})),i},k=function(t,e){var n=[];if(!i(t))return n;for(var r=-1,o=[],a=t.length;++re[r])return 1;if(t[r]n?n:t},it=function(t,e){var n=e.toString(),i=n.indexOf(".");if(-1===i)return Math.round(t);var r=n.substr(i+1).length;return r>20&&(r=20),parseFloat(t.toFixed(r))},rt=function(t){return c(t,"Number")},ot=function(t){return rt(t)&&t%1!=0},at=function(t){return rt(t)&&t%2==0},st=Number.isInteger?Number.isInteger:function(t){return rt(t)&&t%1==0},ct=function(t){return rt(t)&&t<0};function lt(t,e,n){return void 0===n&&(n=1e-5),Math.abs(t-e)0},ft=function(t,e){if(h(t)){for(var n,i=-1/0,r=0;ri&&(n=o,i=a)}return n}},pt=function(t,e){if(h(t)){for(var n,i=1/0,r=0;re?(i&&(clearTimeout(i),i=null),s=l,a=t.apply(r,o),i||(r=o=null)):i||!1===n.trailing||(i=setTimeout(c,u)),a};return l.cancel=function(){clearTimeout(i),s=0,i=r=o=null},l},ye=function(t){return i(t)?Array.prototype.slice.call(t):[]},ve={},me=function(t){return ve[t=t||"g"]?ve[t]+=1:ve[t]=1,t+ve[t]},xe=function(){},be=function(t){return t};function Oe(t){return u(t)?0:i(t)?t.length:Object.keys(t).length}var _e,we=n(1),je=Qt((function(t,e){void 0===e&&(e={});var n=e.fontSize,i=e.fontFamily,r=e.fontWeight,o=e.fontStyle,a=e.fontVariant;return _e||(_e=document.createElement("canvas").getContext("2d")),_e.font=[o,a,r,n+"px",i].join(" "),_e.measureText(D(t)?t:"").width}),(function(t,e){return void 0===e&&(e={}),Object(we.__spreadArrays)([t],wt(e)).join("")})),Se=function(t,e,n,i){void 0===i&&(i="...");var r,o,a=je(i,n),s=D(t)?t:St(t),c=e,l=[];if(je(t,n)<=e)return t;for(;r=s.substr(0,16),!((o=je(r,n))+a>c&&o>c);)if(l.push(r),c-=o,!(s=s.substr(16)))return l.join("");for(;r=s.substr(0,1),!((o=je(r,n))+a>c);)if(l.push(r),c-=o,!(s=s.substr(1)))return l.join("");return""+l.join("")+i},Me=function(){function t(){this.map={}}return t.prototype.has=function(t){return void 0!==this.map[t]},t.prototype.get=function(t,e){var n=this.map[t];return void 0===n?e:n},t.prototype.set=function(t,e){this.map[t]=e},t.prototype.clear=function(){this.map={}},t.prototype.delete=function(t){delete this.map[t]},t.prototype.size=function(){return Object.keys(this.map).length},t}()},function(t,e,n){"use strict";function i(t){return(i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)} /*! ***************************************************************************** Copyright (c) Microsoft Corporation. Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted. THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. ***************************************************************************** */n.r(e),n.d(e,"__extends",(function(){return o})),n.d(e,"__assign",(function(){return a})),n.d(e,"__rest",(function(){return s})),n.d(e,"__decorate",(function(){return c})),n.d(e,"__param",(function(){return l})),n.d(e,"__metadata",(function(){return u})),n.d(e,"__awaiter",(function(){return h})),n.d(e,"__generator",(function(){return f})),n.d(e,"__createBinding",(function(){return p})),n.d(e,"__exportStar",(function(){return d})),n.d(e,"__values",(function(){return g})),n.d(e,"__read",(function(){return y})),n.d(e,"__spread",(function(){return v})),n.d(e,"__spreadArrays",(function(){return m})),n.d(e,"__spreadArray",(function(){return x})),n.d(e,"__await",(function(){return b})),n.d(e,"__asyncGenerator",(function(){return O})),n.d(e,"__asyncDelegator",(function(){return _})),n.d(e,"__asyncValues",(function(){return w})),n.d(e,"__makeTemplateObject",(function(){return j})),n.d(e,"__importStar",(function(){return M})),n.d(e,"__importDefault",(function(){return A})),n.d(e,"__classPrivateFieldGet",(function(){return C})),n.d(e,"__classPrivateFieldSet",(function(){return E}));var r=function(t,e){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])})(t,e)};function o(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}r(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var a=function(){return(a=Object.assign||function(t){for(var e,n=1,i=arguments.length;n=0;c--)(o=t[c])&&(s=(a<3?o(s):a>3?o(e,n,s):o(e,n))||s);return a>3&&s&&Object.defineProperty(e,n,s),s}function l(t,e){return function(n,i){e(n,i,t)}}function u(t,e){if("object"===("undefined"==typeof Reflect?"undefined":i(Reflect))&&"function"==typeof Reflect.metadata)return Reflect.metadata(t,e)}function h(t,e,n,i){return new(n||(n=Promise))((function(r,o){function a(t){try{c(i.next(t))}catch(t){o(t)}}function s(t){try{c(i.throw(t))}catch(t){o(t)}}function c(t){var e;t.done?r(t.value):(e=t.value,e instanceof n?e:new n((function(t){t(e)}))).then(a,s)}c((i=i.apply(t,e||[])).next())}))}function f(t,e){var n,i,r,o,a={label:0,sent:function(){if(1&r[0])throw r[1];return r[1]},trys:[],ops:[]};return o={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(o){return function(s){return function(o){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,i&&(r=2&o[0]?i.return:o[0]?i.throw||((r=i.return)&&r.call(i),0):i.next)&&!(r=r.call(i,o[1])).done)return r;switch(i=0,r&&(o=[2&o[0],r.value]),o[0]){case 0:case 1:r=o;break;case 4:return a.label++,{value:o[1],done:!1};case 5:a.label++,i=o[1],o=[0];continue;case 7:o=a.ops.pop(),a.trys.pop();continue;default:if(!(r=a.trys,(r=r.length>0&&r[r.length-1])||6!==o[0]&&2!==o[0])){a=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]=t.length&&(t=void 0),{value:t&&t[i++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")}function y(t,e){var n="function"==typeof Symbol&&t[Symbol.iterator];if(!n)return t;var i,r,o=n.call(t),a=[];try{for(;(void 0===e||e-- >0)&&!(i=o.next()).done;)a.push(i.value)}catch(t){r={error:t}}finally{try{i&&!i.done&&(n=o.return)&&n.call(o)}finally{if(r)throw r.error}}return a}function v(){for(var t=[],e=0;e1||s(t,e)}))})}function s(t,e){try{(n=r[t](e)).value instanceof b?Promise.resolve(n.value.v).then(c,l):u(o[0][2],n)}catch(t){u(o[0][3],t)}var n}function c(t){s("next",t)}function l(t){s("throw",t)}function u(t,e){t(e),o.shift(),o.length&&s(o[0][0],o[0][1])}}function _(t){var e,n;return e={},i("next"),i("throw",(function(t){throw t})),i("return"),e[Symbol.iterator]=function(){return this},e;function i(i,r){e[i]=t[i]?function(e){return(n=!n)?{value:b(t[i](e)),done:"return"===i}:r?r(e):e}:r}}function w(t){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var e,n=t[Symbol.asyncIterator];return n?n.call(t):(t=g(t),e={},i("next"),i("throw"),i("return"),e[Symbol.asyncIterator]=function(){return this},e);function i(n){e[n]=t[n]&&function(e){return new Promise((function(i,r){(function(t,e,n,i){Promise.resolve(i).then((function(e){t({value:e,done:n})}),e)})(i,r,(e=t[n](e)).done,e.value)}))}}}function j(t,e){return Object.defineProperty?Object.defineProperty(t,"raw",{value:e}):t.raw=e,t}var S=Object.create?function(t,e){Object.defineProperty(t,"default",{enumerable:!0,value:e})}:function(t,e){t.default=e};function M(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)"default"!==n&&Object.prototype.hasOwnProperty.call(t,n)&&p(e,t,n);return S(e,t),e}function A(t){return t&&t.__esModule?t:{default:t}}function C(t,e,n,i){if("a"===n&&!i)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof e?t!==e||!i:!e.has(t))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===n?i:"a"===n?i.call(t):i?i.value:e.get(t)}function E(t,e,n,i,r){if("m"===i)throw new TypeError("Private method is not writable");if("a"===i&&!r)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof e?t!==e||!r:!e.has(t))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===i?r.call(t,n):r?r.value=n:e.set(t,n),n}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(1),r=n(197);Object.defineProperty(e,"flow",{enumerable:!0,get:function(){return r.flow}});var o=n(102);Object.defineProperty(e,"pick",{enumerable:!0,get:function(){return o.pick}});var a=n(198);Object.defineProperty(e,"template",{enumerable:!0,get:function(){return a.template}});var s=n(103);Object.defineProperty(e,"log",{enumerable:!0,get:function(){return s.log}}),Object.defineProperty(e,"invariant",{enumerable:!0,get:function(){return s.invariant}}),Object.defineProperty(e,"LEVEL",{enumerable:!0,get:function(){return s.LEVEL}});var c=n(199);Object.defineProperty(e,"getContainerSize",{enumerable:!0,get:function(){return c.getContainerSize}}),i.__exportStar(n(200),e);var l=n(104);Object.defineProperty(e,"findViewById",{enumerable:!0,get:function(){return l.findViewById}}),Object.defineProperty(e,"getViews",{enumerable:!0,get:function(){return l.getViews}}),Object.defineProperty(e,"getSiblingViews",{enumerable:!0,get:function(){return l.getSiblingViews}});var u=n(201);Object.defineProperty(e,"transformLabel",{enumerable:!0,get:function(){return u.transformLabel}});var h=n(202);Object.defineProperty(e,"getSplinePath",{enumerable:!0,get:function(){return h.getSplinePath}});var f=n(105);Object.defineProperty(e,"deepAssign",{enumerable:!0,get:function(){return f.deepAssign}});var p=n(203);Object.defineProperty(e,"kebabCase",{enumerable:!0,get:function(){return p.kebabCase}});var d=n(106);Object.defineProperty(e,"renderStatistic",{enumerable:!0,get:function(){return d.renderStatistic}}),Object.defineProperty(e,"renderGaugeStatistic",{enumerable:!0,get:function(){return d.renderGaugeStatistic}});var g=n(204);Object.defineProperty(e,"measureTextWidth",{enumerable:!0,get:function(){return g.measureTextWidth}});var y=n(77);Object.defineProperty(e,"isBetween",{enumerable:!0,get:function(){return y.isBetween}}),Object.defineProperty(e,"isRealNumber",{enumerable:!0,get:function(){return y.isRealNumber}}),i.__exportStar(n(63),e),i.__exportStar(n(44),e)},function(t,e,n){"use strict";n.r(e),n.d(e,"mat3",(function(){return r.a})),n.d(e,"vec2",(function(){return r.b})),n.d(e,"vec3",(function(){return r.c})),n.d(e,"ext",(function(){return i}));var i={};n.r(i),n.d(i,"leftTranslate",(function(){return o})),n.d(i,"leftRotate",(function(){return a})),n.d(i,"leftScale",(function(){return s})),n.d(i,"transform",(function(){return c})),n.d(i,"direction",(function(){return l})),n.d(i,"angleTo",(function(){return u})),n.d(i,"vertical",(function(){return h}));var r=n(20);function o(t,e,n){var i=[0,0,0,0,0,0,0,0,0];return r.a.fromTranslation(i,n),r.a.multiply(t,i,e)}function a(t,e,n){var i=[0,0,0,0,0,0,0,0,0];return r.a.fromRotation(i,n),r.a.multiply(t,i,e)}function s(t,e,n){var i=[0,0,0,0,0,0,0,0,0];return r.a.fromScaling(i,n),r.a.multiply(t,i,e)}function c(t,e){for(var n,i,c,l=t?[].concat(t):[1,0,0,0,1,0,0,0,1],u=0,h=e.length;u=0;return n?o?2*Math.PI-i:i:o?i:2*Math.PI-i}function h(t,e,n){return n?(t[0]=e[1],t[1]=-1*e[0]):(t[0]=-1*e[1],t[1]=e[0]),t}},function(t,e,n){"use strict";n.d(e,"c",(function(){return r})),n.d(e,"a",(function(){return o})),n.d(e,"h",(function(){return a})),n.d(e,"k",(function(){return s})),n.d(e,"j",(function(){return c})),n.d(e,"b",(function(){return l})),n.d(e,"g",(function(){return u})),n.d(e,"e",(function(){return h})),n.d(e,"i",(function(){return f})),n.d(e,"d",(function(){return p})),n.d(e,"m",(function(){return d})),n.d(e,"l",(function(){return g})),n.d(e,"f",(function(){return y}));var i=n(0);function r(t){var e=0,n=0,r=0,o=0;return Object(i.isNumber)(t)?e=n=r=o=t:Object(i.isArray)(t)&&(e=t[0],r=Object(i.isNil)(t[1])?t[0]:t[1],o=Object(i.isNil)(t[2])?t[0]:t[2],n=Object(i.isNil)(t[3])?r:t[3]),[e,r,o,n]}function o(t){for(var e=t.childNodes,n=e.length-1;n>=0;n--)t.removeChild(e[n])}function a(t,e){return!!t.className.match(new RegExp("(\\s|^)"+e+"(\\s|$)"))}function s(t){var e=t.start,n=t.end,i=Math.min(e.x,n.x),r=Math.min(e.y,n.y),o=Math.max(e.x,n.x),a=Math.max(e.y,n.y);return{x:i,y:r,minX:i,minY:r,maxX:o,maxY:a,width:o-i,height:a-r}}function c(t){var e=t.map((function(t){return t.x})),n=t.map((function(t){return t.y})),i=Math.min.apply(Math,e),r=Math.min.apply(Math,n),o=Math.max.apply(Math,e),a=Math.max.apply(Math,n);return{x:i,y:r,minX:i,minY:r,maxX:o,maxY:a,width:o-i,height:a-r}}function l(t,e,n,i){var r=t+n,o=e+i;return{x:t,y:e,width:n,height:i,minX:t,minY:e,maxX:isNaN(r)?0:r,maxY:isNaN(o)?0:o}}function u(t,e,n){return(1-n)*t+e*n}function h(t,e,n){return{x:t.x+Math.cos(n)*e,y:t.y+Math.sin(n)*e}}var f=function(t,e,n){return void 0===n&&(n=Math.pow(Number.EPSILON,.5)),[t,e].includes(1/0)?Math.abs(t)===Math.abs(e):Math.abs(t-e)0?Object(i.each)(g,(function(t){if(t.get("visible")){if(t.isGroup()&&0===t.get("children").length)return!0;var e=p(t),n=t.applyToMatrix([e.minX,e.minY,1]),i=t.applyToMatrix([e.minX,e.maxY,1]),r=t.applyToMatrix([e.maxX,e.minY,1]),o=t.applyToMatrix([e.maxX,e.maxY,1]),a=Math.min(n[0],i[0],r[0],o[0]),s=Math.max(n[0],i[0],r[0],o[0]),c=Math.min(n[1],i[1],r[1],o[1]),l=Math.max(n[1],i[1],r[1],o[1]);ah&&(h=s),cd&&(d=l)}})):(u=0,h=0,f=0,d=0),e=l(u,f,h-u,d-f)}else e=t.getBBox();return c?(n=e,r=c,o=Math.max(n.minX,r.minX),a=Math.max(n.minY,r.minY),l(o,a,Math.min(n.maxX,r.maxX)-o,Math.min(n.maxY,r.maxY)-a)):e}function d(t,e){if(t.getClip()||e.getClip()){var n=e.getClip();if(n){var i={type:n.get("type"),attrs:n.attr()};t.setClip(i)}else t.setClip(null)}}function g(t){return t+"px"}function y(t,e,n,i){var r,o,a,s,c=i/(r=t,a=(o=e).x-r.x,s=o.y-r.y,Math.sqrt(a*a+s*s)),l=0;return"start"===n?l=0-c:"end"===n&&(l=1+c),{x:u(t.x,e.x,l),y:u(t.y,e.y,l)}}},function(t,e,n){"use strict";e.a={fontFamily:'\n BlinkMacSystemFont, "Segoe UI", Roboto,"Helvetica Neue",\n Helvetica, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei",\n SimSun, "sans-serif"',textColor:"#2C3542",activeTextColor:"#333333",uncheckedColor:"#D8D8D8",lineColor:"#416180",regionColor:"#CCD7EB",verticalAxisRotate:-Math.PI/4,horizontalAxisRotate:Math.PI/4}},function(t,e,n){"use strict";n.d(e,"d",(function(){return r})),n.d(e,"b",(function(){return o})),n.d(e,"e",(function(){return a})),n.d(e,"f",(function(){return s})),n.d(e,"l",(function(){return c})),n.d(e,"j",(function(){return l}));var i=n(0);function r(){return window?window.devicePixelRatio:1}function o(t,e,n,i){var r=t-n,o=e-i;return Math.sqrt(r*r+o*o)}function a(t,e,n,i,r,o){return r>=t&&r<=t+n&&o>=e&&o<=e+i}function s(t,e){return!(e.minX>t.maxX||e.maxXt.maxY||e.maxY=0&&this.radius<=1&&(n*=this.radius),this.d=Math.floor(n*(1-this.innerRadius)/e),this.a=this.d/(2*Math.PI),this.x={start:this.startAngle,end:this.endAngle},this.y={start:this.innerRadius*n,end:this.innerRadius*n+.99*this.d}},e.prototype.convertPoint=function(t){var e,n=t.x,i=t.y;this.isTransposed&&(n=(e=[i,n])[0],i=e[1]);var r=this.convertDim(n,"x"),o=this.a*r,a=this.convertDim(i,"y");return{x:this.center.x+Math.cos(r)*(o+a),y:this.center.y+Math.sin(r)*(o+a)}},e.prototype.invertPoint=function(t){var e,n=this.d+this.y.start,i=N.vec2.subtract([0,0],[t.x,t.y],[this.center.x,this.center.y]),r=N.ext.angleTo(i,[1,0],!0),o=r*this.a;N.vec2.length(i)this.width/i?(e=this.width/i,this.circleCenter={x:this.center.x-(.5-o)*this.width,y:this.center.y-(.5-a)*e*r}):(e=this.height/r,this.circleCenter={x:this.center.x-(.5-o)*e*i,y:this.center.y-(.5-a)*this.height}),this.polarRadius=this.radius,this.radius?this.radius>0&&this.radius<=1?this.polarRadius=e*this.radius:(this.radius<=0||this.radius>e)&&(this.polarRadius=e):this.polarRadius=e,this.x={start:this.startAngle,end:this.endAngle},this.y={start:this.innerRadius*this.polarRadius,end:this.polarRadius}},e.prototype.getRadius=function(){return this.polarRadius},e.prototype.convertPoint=function(t){var e,n=this.getCenter(),i=t.x,r=t.y;return this.isTransposed&&(i=(e=[r,i])[0],r=e[1]),i=this.convertDim(i,"x"),r=this.convertDim(r,"y"),{x:n.x+Math.cos(i)*r,y:n.y+Math.sin(i)*r}},e.prototype.invertPoint=function(t){var e,n=this.getCenter(),i=[t.x-n.x,t.y-n.y],r=this.startAngle,o=this.endAngle;this.isReflect("x")&&(r=(e=[o,r])[0],o=e[1]);var a=[1,0,0,0,1,0,0,0,1];N.ext.leftRotate(a,a,r);var c=[1,0,0];N.vec3.transformMat3(c,c,a);var l=[c[0],c[1]],u=N.ext.angleTo(l,i,o0?f:-f;var p=this.invertDim(h,"y"),d={x:0,y:0};return d.x=this.isTransposed?p:f,d.y=this.isTransposed?f:p,d},e.prototype.getCenter=function(){return this.circleCenter},e.prototype.getOneBox=function(){var t=this.startAngle,e=this.endAngle;if(Math.abs(e-t)>=2*Math.PI)return{minX:-1,maxX:1,minY:-1,maxY:1};for(var n=[0,Math.cos(t),Math.cos(e)],i=[0,Math.sin(t),Math.sin(e)],r=Math.min(t,e);rt.x?t.x:e,n=nt.y?t.y:i,r=r=i&&t<=r}function lt(t,e){return"object"===st(t)&&e.forEach((function(e){delete t[e]})),t}function ut(t,e,n){void 0===e&&(e=[]),void 0===n&&(n=new Map);for(var i=0,r=t;i=this.minX&&t.maxX<=this.maxX&&t.minY>=this.minY&&t.maxY<=this.maxY},t.prototype.clone=function(){return new t(this.x,this.y,this.width,this.height)},t.prototype.add=function(){for(var t=[],e=0;et.minX&&this.minYt.minY},t.prototype.size=function(){return this.width*this.height},t.prototype.isPointIn=function(t){return t.x>=this.minX&&t.x<=this.maxX&&t.y>=this.minY&&t.y<=this.maxY},t}();function ft(t){if(t.isPolar&&!t.isTransposed)return(t.endAngle-t.startAngle)*t.getRadius();var e=t.convert({x:0,y:0}),n=t.convert({x:1,y:0});return Math.sqrt(Math.pow(n.x-e.x,2)+Math.pow(n.y-e.y,2))}function pt(t,e){var n=t.getCenter();return Math.sqrt(Math.pow(e.x-n.x,2)+Math.pow(e.y-n.y,2))}function dt(t,e){var n=!1;if(t)if("theta"===t.type){var i=t.start,r=t.end;n=ct(e.x,i.x,r.x)&&ct(e.y,i.y,r.y)}else{var o=t.invert(e);n=ct(o.x,0,1)&&ct(o.y,0,1)}return n}function gt(t,e){var n=t.getCenter();return Math.atan2(e.y-n.y,e.x-n.x)}function yt(t,e){void 0===e&&(e=0);var n,i=t.start,r=t.end,o=t.getWidth(),a=t.getHeight();if(t.isPolar){var s=t.startAngle,c=t.endAngle,l=t.getCenter(),u=t.getRadius();return{type:"path",startState:{path:it(l.x,l.y,u+e,s,s)},endState:function(t){var n=(c-s)*t+s;return{path:it(l.x,l.y,u+e,s,n)}},attrs:{path:it(l.x,l.y,u+e,s,c)}}}return n=t.isTransposed?{height:a+2*e}:{width:o+2*e},{type:"rect",startState:{x:i.x-e,y:r.y-e,width:t.isTransposed?o+2*e:0,height:t.isTransposed?0:a+2*e},endState:n,attrs:{x:i.x-e,y:r.y-e,width:o+2*e,height:a+2*e}}}var vt=/^(?:(?!0000)[0-9]{4}([-/.]+)(?:(?:0?[1-9]|1[0-2])\1(?:0?[1-9]|1[0-9]|2[0-8])|(?:0?[13-9]|1[0-2])\1(?:29|30)|(?:0?[13578]|1[02])\1(?:31))|(?:[0-9]{2}(?:0[48]|[2468][048]|[13579][26])|(?:0[48]|[2468][048]|[13579][26])00)([-/.]+)0?2\2(?:29))(\s+([01]|([01][0-9]|2[0-3])):([0-9]|[0-5][0-9]):([0-9]|[0-5][0-9]))?$/;function mt(t,e,n,i){return void 0===e&&(e={}),e.type?e.type:"identity"!==t.type&&g.includes(n)&&["interval"].includes(i)||t.isCategory?"cat":t.type}function xt(t,e,n){var i=e||[];if(Object(s.isNumber)(t)||Object(s.isNil)(Object(s.firstValue)(i,t))&&Object(s.isEmpty)(n))return new(Object(k.d)("identity"))({field:t.toString(),values:[t]});var r=Object(s.valuesOfKey)(i,t),o=Object(s.get)(n,"type",function(t){var e="linear";return vt.test(t)?e="timeCat":Object(s.isString)(t)&&(e="cat"),e}(r[0]));return new(Object(k.d)(o))(Object(a.__assign)({field:t,values:r},n))}function bt(t){return t.alias||t.field}function Ot(t,e,n){var i,r=t.values.length;if(1===r)i=[.5,1];else{var o=0;i=function(t){if(t.isPolar){var e=t.startAngle;return t.endAngle-e==2*Math.PI}return!1}(e)?e.isTransposed?[(o=1/r*Object(s.get)(n,"widthRatio.multiplePie",1/1.3))/2,1-o/2]:[0,1-1/r]:[o=1/r/2,1-o]}return i}function _t(t,e){var n={start:{x:0,y:0},end:{x:0,y:0}};t.isRect?n=function(t){var e,n;switch(t){case r.TOP:e={x:0,y:1},n={x:1,y:1};break;case r.RIGHT:e={x:1,y:0},n={x:1,y:1};break;case r.BOTTOM:e={x:0,y:0},n={x:1,y:0};break;case r.LEFT:e={x:0,y:0},n={x:0,y:1};break;default:e=n={x:0,y:0}}return{start:e,end:n}}(e):t.isPolar&&(n=function(t){var e,n;return t.isTransposed?(e={x:0,y:0},n={x:1,y:0}):(e={x:0,y:0},n={x:0,y:1}),{start:e,end:n}}(t));var i=n.start,o=n.end;return{start:t.convert(i),end:t.convert(o)}}function wt(t){var e=t.start,n=t.end;return e.x===n.x}function jt(t,e){var n=t.start,i=t.end;return wt(t)?(n.y-i.y)*(e.x-n.x)>0?1:-1:(i.x-n.x)*(n.y-e.y)>0?-1:1}function St(t,e){var n=Object(s.get)(t,["components","axis"],{});return Object(s.deepMix)({},Object(s.get)(n,["common"],{}),Object(s.deepMix)({},Object(s.get)(n,[e],{})))}function Mt(t,e,n){var i=Object(s.get)(t,["components","axis"],{});return Object(s.deepMix)({},Object(s.get)(i,["common","title"],{}),Object(s.deepMix)({},Object(s.get)(i,[e,"title"],{})),n)}function At(t){var e=t.x,n=t.y,i=t.circleCenter,r=n.start>n.end,o=t.isTransposed?t.convert({x:r?0:1,y:0}):t.convert({x:0,y:r?0:1}),a=[o.x-i.x,o.y-i.y],s=[1,0],c=o.y>i.y?N.vec2.angle(a,s):-1*N.vec2.angle(a,s),l=c+(e.end-e.start);return{center:i,radius:Math.sqrt(Math.pow(o.x-i.x,2)+Math.pow(o.y-i.y,2)),startAngle:c,endAngle:l}}function Ct(t,e){return Object(s.isBoolean)(t)?!1!==t&&{}:Object(s.get)(t,[e])}function Et(t,e){return Object(s.get)(t,"position",e)}function It(t,e){return Object(s.get)(e,["title","text"],bt(t))}var Pt=function(){function t(t,e){this.destroyed=!1,this.facets=[],this.view=t,this.cfg=Object(s.deepMix)({},this.getDefaultCfg(),e)}return t.prototype.init=function(){this.container||(this.container=this.createContainer());var t=this.view.getData();this.facets=this.generateFacets(t)},t.prototype.render=function(){this.renderViews()},t.prototype.update=function(){},t.prototype.clear=function(){this.clearFacetViews()},t.prototype.destroy=function(){this.clear(),this.container&&(this.container.remove(!0),this.container=void 0),this.destroyed=!0,this.view=void 0,this.facets=[]},t.prototype.facetToView=function(t){var e=t.region,n=t.data,i=t.padding,r=void 0===i?this.cfg.padding:i,o=this.view.createView({region:e,padding:r});o.data(n||[]),t.view=o,this.beforeEachView(o,t);var a=this.cfg.eachView;return a&&a(o,t),this.afterEachView(o,t),o},t.prototype.createContainer=function(){return this.view.getLayer(i.FORE).addGroup()},t.prototype.renderViews=function(){this.createFacetViews()},t.prototype.createFacetViews=function(){var t=this;return this.facets.map((function(e){return t.facetToView(e)}))},t.prototype.clearFacetViews=function(){var t=this;Object(s.each)(this.facets,(function(e){e.view&&(t.view.removeView(e.view),e.view=void 0)}))},t.prototype.parseSpacing=function(){var t=this.view.viewBBox,e=t.width,n=t.height;return this.cfg.spacing.map((function(t,i){return Object(s.isNumber)(t)?t/(0===i?e:n):parseFloat(t)/100}))},t.prototype.getFieldValues=function(t,e){var n=[],i={};return Object(s.each)(t,(function(t){var r=t[e];Object(s.isNil)(r)||i[r]||(n.push(r),i[r]=!0)})),n},t.prototype.getRegion=function(t,e,n,i){var r=this.parseSpacing(),o=r[0],a=r[1],s=(1+o)/(0===e?1:e)-o,c=(1+a)/(0===t?1:t)-a,l={x:(s+o)*n,y:(c+a)*i};return{start:l,end:{x:l.x+s,y:l.y+c}}},t.prototype.getDefaultCfg=function(){return{eachView:void 0,showTitle:!0,spacing:[0,0],padding:10,fields:[]}},t.prototype.getDefaultTitleCfg=function(){return{style:{fontSize:14,fill:"#666",fontFamily:this.view.getTheme().fontFamily}}},t.prototype.processAxis=function(t,e){var n=t.getOptions(),i=n.coordinate,r=t.geometries;if("rect"===Object(s.get)(i,"type","rect")&&r.length){Object(s.isNil)(n.axes)&&(n.axes={});var o=n.axes,a=r[0].getXYFields(),c=a[0],l=a[1],u=Ct(o,c),h=Ct(o,l);!1!==u&&(n.axes[c]=this.getXAxisOption(c,o,u,e)),!1!==h&&(n.axes[l]=this.getYAxisOption(l,o,h,e))}},t.prototype.getFacetDataFilter=function(t){return function(e){return Object(s.every)(t,(function(t){var n=t.field,i=t.value;return!(!Object(s.isNil)(i)&&n)||e[n]===i}))}},t}(),Ft={},Tt=function(t){return Ft[Object(s.lowerCase)(t)]},Lt=function(t,e){Ft[Object(s.lowerCase)(t)]=e},kt=function(){function t(t,e){this.context=t,this.cfg=e,t.addAction(this)}return t.prototype.applyCfg=function(t){Object(s.assign)(this,t)},t.prototype.init=function(){this.applyCfg(this.cfg)},t.prototype.destroy=function(){this.context.removeAction(this),this.context=null},t}(),Dt=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(a.__extends)(e,t),e.prototype.execute=function(){this.callback&&this.callback(this.context)},e.prototype.destroy=function(){t.prototype.destroy.call(this),this.callback=null},e}(kt),Bt={};function Rt(t){var e=Bt[t];return Object(s.get)(e,"ActionClass")}function Nt(t,e,n){Bt[t]={ActionClass:e,cfg:n}}function Vt(t,e){var n=new Dt(e);return n.callback=t,n.name="callback",n}function zt(t,e){for(var n=[t[0]],i=1,r=t.length;i=a[l]?1:0,f=u>Math.PI?1:0,p=n.convert(s),d=pt(n,p);if(d>=.5)if(u===2*Math.PI){var g={x:(s.x+a.x)/2,y:(s.y+a.y)/2},y=n.convert(g);c.push(["A",d,d,0,f,h,y.x,y.y]),c.push(["A",d,d,0,f,h,p.x,p.y])}else c.push(["A",d,d,0,f,h,p.x,p.y]);return c}(n,i,t)):o.push(zt(a,t));break;case"a":o.push(Gt(a,t));break;case"z":default:o.push(a)}})),function(t){Object(s.each)(t,(function(e,n){if("a"===e[0].toLowerCase()){var i=t[n-1],r=t[n+1];r&&"a"===r[0].toLowerCase()?i&&"l"===i[0].toLowerCase()&&(i[0]="M"):i&&"a"===i[0].toLowerCase()&&r&&"l"===r[0].toLowerCase()&&(r[0]="M")}}))}(o),o}var Ut=n(28);function qt(t,e){var n=t.event.target.getCanvasBBox();return n.width>=e||n.height>=e?n:null}function Zt(t){var e,n=t.event.target;return n&&(e=n.get("element")),e}function $t(t){var e,n=t.event.target;return n&&(e=n.get("delegateObject")),e}function Kt(t){var e=t.event.gEvent;return!(e&&e.fromShape&&e.toShape&&e.fromShape.get("element")===e.toShape.get("element"))}function Qt(t){return t&&t.component&&t.component.isList()}function Jt(t){return t&&t.component&&t.component.isSlider()}function te(t){var e=t.event.target;return e&&"mask"===e.get("name")}function ee(t,e){var n,i,r,o;if("path"===t.event.target.get("type")){var a=function(t,e){var n=t.event.target,i=n.getCanvasBBox();return i.width>=e||i.height>=e?n.attr("path"):null}(t,e);if(!a)return;return n=t.view,i=a,r=ie(n),o=se(i),r.filter((function(t){var e,n,i=t.shape;if("path"===i.get("type"))e=se(i.attr("path"));else{var r=i.getCanvasBBox();e=[[(n=r).minX,n.minY],[n.maxX,n.minY],[n.maxX,n.maxY],[n.minX,n.maxY]]}return Object(Ut.isPolygonsIntersect)(o,e)}))}var s=qt(t,e);return s?ae(t.view,s):null}function ne(t,e,n){var i=qt(t,n);if(!i)return null;var r=t.view,o=fe(r,e,{x:i.x,y:i.y}),a=fe(r,e,{x:i.maxX,y:i.maxY});return ae(e,{minX:o.x,minY:o.y,maxX:a.x,maxY:a.y})}function ie(t){var e=t.geometries,n=[];return Object(s.each)(e,(function(t){var e=t.elements;n=n.concat(e)})),t.views&&t.views.length&&Object(s.each)(t.views,(function(t){n=n.concat(ie(t))})),n}function re(t,e){var n=t.geometries,i=[];return Object(s.each)(n,(function(t){var n=t.getElementsBy((function(t){return t.hasState(e)}));i=i.concat(n)})),i}function oe(t,e){var n=t.getModel().data;return Object(s.isArray)(n)?n[0][e]:n[e]}function ae(t,e){var n=ie(t),i=[];return Object(s.each)(n,(function(t){var n,r,o=t.shape.getCanvasBBox();n=e,(r=o).minX>n.maxX||r.maxXn.maxY||r.maxY=e.x&&t.y<=e.y&&t.maxY>e.y}function he(t){var e=t.parent,n=null;return e&&(n=e.views.filter((function(e){return e!==t}))),n}function fe(t,e,n){var i=function(t,e){return t.getCoordinate().invert(e)}(t,n);return e.getCoordinate().convert(i)}function pe(t,e,n,i){var r=!1;return Object(s.each)(t,(function(t){if(t[n]===e[n]&&t[i]===e[i])return r=!0,!1})),r}function de(t,e){var n=t.getScaleByField(e);return!n&&t.views&&Object(s.each)(t.views,(function(t){if(n=de(t,e))return!1})),n}var ge=function(){function t(t){this.actions=[],this.event=null,this.cacheMap={},this.view=t}return t.prototype.cache=function(){for(var t=[],e=0;e=0&&e.splice(n,1)},t.prototype.getCurrentPoint=function(){var t=this.event;return t?t.target instanceof HTMLElement?this.view.getCanvas().getPointByClient(t.clientX,t.clientY):{x:t.x,y:t.y}:null},t.prototype.getCurrentShape=function(){return Object(s.get)(this.event,["gEvent","shape"])},t.prototype.isInPlot=function(){var t=this.getCurrentPoint();return!!t&&this.view.isPointInPlot(t)},t.prototype.isInShape=function(t){var e=this.getCurrentShape();return!!e&&e.get("name")===t},t.prototype.isInComponent=function(t){var e=ce(this.view),n=this.getCurrentPoint();return!!n&&!!e.find((function(e){var i=e.getBBox();return t?e.get("name")===t&&ue(i,n):ue(i,n)}))},t.prototype.destroy=function(){Object(s.each)(this.actions.slice(),(function(t){t.destroy()})),this.view=null,this.event=null,this.actions=null,this.cacheMap=null},t}(),ye=function(){function t(t,e){this.view=t,this.cfg=e}return t.prototype.init=function(){this.initEvents()},t.prototype.initEvents=function(){},t.prototype.clearEvents=function(){},t.prototype.destroy=function(){this.clearEvents()},t}();function ve(t,e,n){var i=t.split(":"),r=i[0],o=e.getAction(r)||function(t,e){var n=Bt[t],i=null;return n&&((i=new(0,n.ActionClass)(e,n.cfg)).name=t,i.init()),i}(r,e);if(!o)throw new Error("There is no action named ".concat(r));return{action:o,methodName:i[1],arg:n}}function me(t){var e=t.action,n=t.methodName,i=t.arg;if(!e[n])throw new Error("Action(".concat(e.name,") doesn't have a method called ").concat(n));e[n](i)}var xe="start",be="showEnable",Oe="end",_e="rollback",we="processing",je=function(t){function e(e,n){var i=t.call(this,e,n)||this;return i.callbackCaches={},i.emitCaches={},i.steps=n,i}return Object(a.__extends)(e,t),e.prototype.init=function(){this.initContext(),t.prototype.init.call(this)},e.prototype.destroy=function(){t.prototype.destroy.call(this),this.steps=null,this.context&&(this.context.destroy(),this.context=null),this.callbackCaches=null,this.view=null},e.prototype.initEvents=function(){var t=this;Object(s.each)(this.steps,(function(e,n){Object(s.each)(e,(function(e){var i=t.getActionCallback(n,e);i&&t.bindEvent(e.trigger,i)}))}))},e.prototype.clearEvents=function(){var t=this;Object(s.each)(this.steps,(function(e,n){Object(s.each)(e,(function(e){var i=t.getActionCallback(n,e);i&&t.offEvent(e.trigger,i)}))}))},e.prototype.initContext=function(){var t=this.view,e=new ge(t);this.context=e;var n=this.steps;Object(s.each)(n,(function(t){Object(s.each)(t,(function(t){if(Object(s.isFunction)(t.action))t.actionObject={action:Vt(t.action,e),methodName:"execute"};else if(Object(s.isString)(t.action))t.actionObject=ve(t.action,e,t.arg);else if(Object(s.isArray)(t.action)){var n=t.action,i=Object(s.isArray)(t.arg)?t.arg:[t.arg];t.actionObject=[],Object(s.each)(n,(function(n,r){t.actionObject.push(ve(n,e,i[r]))}))}}))}))},e.prototype.isAllowStep=function(t){var e=this.currentStepName,n=this.steps;if(e===t)return!0;if(t===be)return!0;if(t===we)return e===xe;if(t===xe)return e!==we;if(t===Oe)return e===we||e===xe;if(t===_e){if(n[Oe])return e===Oe;if(e===xe)return!0}return!1},e.prototype.isAllowExecute=function(t,e){if(this.isAllowStep(t)){var n=this.getKey(t,e);return(!e.once||!this.emitCaches[n])&&(!e.isEnable||e.isEnable(this.context))}return!1},e.prototype.enterStep=function(t){this.currentStepName=t,this.emitCaches={}},e.prototype.afterExecute=function(t,e){t!==be&&this.currentStepName!==t&&this.enterStep(t);var n=this.getKey(t,e);this.emitCaches[n]=!0},e.prototype.getKey=function(t,e){return t+e.trigger+e.action},e.prototype.getActionCallback=function(t,e){var n=this,i=this.context,r=this.callbackCaches,o=e.actionObject;if(e.action&&o){var a=this.getKey(t,e);if(!r[a]){var c=function(r){i.event=r,n.isAllowExecute(t,e)?(Object(s.isArray)(o)?Object(s.each)(o,(function(t){i.event=r,me(t)})):(i.event=r,me(o)),n.afterExecute(t,e),e.callback&&(i.event=r,e.callback(i))):i.event=null};e.debounce?r[a]=Object(s.debounce)(c,e.debounce.wait,e.debounce.immediate):e.throttle?r[a]=Object(s.throttle)(c,e.throttle.wait,{leading:e.throttle.leading,trailing:e.throttle.trailing}):r[a]=c}return r[a]}return null},e.prototype.bindEvent=function(t,e){var n=t.split(":");"window"===n[0]?window.addEventListener(n[1],e):"document"===n[0]?document.addEventListener(n[1],e):this.view.on(t,e)},e.prototype.offEvent=function(t,e){var n=t.split(":");"window"===n[0]?window.removeEventListener(n[1],e):"document"===n[0]?document.removeEventListener(n[1],e):this.view.off(t,e)},e}(ye),Se={};function Me(t){return Se[Object(s.lowerCase)(t)]}function Ae(t,e){Se[Object(s.lowerCase)(t)]=e}function Ce(t){var e,n={point:{default:{fill:t.pointFillColor,r:t.pointSize,stroke:t.pointBorderColor,lineWidth:t.pointBorder,fillOpacity:t.pointFillOpacity},active:{stroke:t.pointActiveBorderColor,lineWidth:t.pointActiveBorder},selected:{stroke:t.pointSelectedBorderColor,lineWidth:t.pointSelectedBorder},inactive:{fillOpacity:t.pointInactiveFillOpacity,strokeOpacity:t.pointInactiveBorderOpacity}},hollowPoint:{default:{fill:t.hollowPointFillColor,lineWidth:t.hollowPointBorder,stroke:t.hollowPointBorderColor,strokeOpacity:t.hollowPointBorderOpacity,r:t.hollowPointSize},active:{stroke:t.hollowPointActiveBorderColor,strokeOpacity:t.hollowPointActiveBorderOpacity},selected:{lineWidth:t.hollowPointSelectedBorder,stroke:t.hollowPointSelectedBorderColor,strokeOpacity:t.hollowPointSelectedBorderOpacity},inactive:{strokeOpacity:t.hollowPointInactiveBorderOpacity}},area:{default:{fill:t.areaFillColor,fillOpacity:t.areaFillOpacity,stroke:null},active:{fillOpacity:t.areaActiveFillOpacity},selected:{fillOpacity:t.areaSelectedFillOpacity},inactive:{fillOpacity:t.areaInactiveFillOpacity}},hollowArea:{default:{fill:null,stroke:t.hollowAreaBorderColor,lineWidth:t.hollowAreaBorder,strokeOpacity:t.hollowAreaBorderOpacity},active:{fill:null,lineWidth:t.hollowAreaActiveBorder},selected:{fill:null,lineWidth:t.hollowAreaSelectedBorder},inactive:{strokeOpacity:t.hollowAreaInactiveBorderOpacity}},interval:{default:{fill:t.intervalFillColor,fillOpacity:t.intervalFillOpacity},active:{stroke:t.intervalActiveBorderColor,lineWidth:t.intervalActiveBorder},selected:{stroke:t.intervalSelectedBorderColor,lineWidth:t.intervalSelectedBorder},inactive:{fillOpacity:t.intervalInactiveFillOpacity,strokeOpacity:t.intervalInactiveBorderOpacity}},hollowInterval:{default:{fill:t.hollowIntervalFillColor,stroke:t.hollowIntervalBorderColor,lineWidth:t.hollowIntervalBorder,strokeOpacity:t.hollowIntervalBorderOpacity},active:{stroke:t.hollowIntervalActiveBorderColor,lineWidth:t.hollowIntervalActiveBorder,strokeOpacity:t.hollowIntervalActiveBorderOpacity},selected:{stroke:t.hollowIntervalSelectedBorderColor,lineWidth:t.hollowIntervalSelectedBorder,strokeOpacity:t.hollowIntervalSelectedBorderOpacity},inactive:{stroke:t.hollowIntervalInactiveBorderColor,lineWidth:t.hollowIntervalInactiveBorder,strokeOpacity:t.hollowIntervalInactiveBorderOpacity}},line:{default:{stroke:t.lineBorderColor,lineWidth:t.lineBorder,strokeOpacity:t.lineBorderOpacity,fill:null,lineAppendWidth:10,lineCap:"round",lineJoin:"round"},active:{lineWidth:t.lineActiveBorder},selected:{lineWidth:t.lineSelectedBorder},inactive:{strokeOpacity:t.lineInactiveBorderOpacity}}},i=function(t){return{title:{autoRotate:!0,position:"center",spacing:t.axisTitleSpacing,style:{fill:t.axisTitleTextFillColor,fontSize:t.axisTitleTextFontSize,lineHeight:t.axisTitleTextLineHeight,textBaseline:"middle",fontFamily:t.fontFamily}},label:{autoRotate:!1,autoEllipsis:!1,autoHide:{type:"equidistance",cfg:{minGap:6}},offset:t.axisLabelOffset,style:{fill:t.axisLabelFillColor,fontSize:t.axisLabelFontSize,lineHeight:t.axisLabelLineHeight,fontFamily:t.fontFamily}},line:{style:{lineWidth:t.axisLineBorder,stroke:t.axisLineBorderColor}},grid:{line:{type:"line",style:{stroke:t.axisGridBorderColor,lineWidth:t.axisGridBorder,lineDash:t.axisGridLineDash}},alignTick:!0,animate:!0},tickLine:{style:{lineWidth:t.axisTickLineBorder,stroke:t.axisTickLineBorderColor},alignTick:!0,length:t.axisTickLineLength},subTickLine:null,animate:!0}}(t),r=function(t){return{title:null,marker:{symbol:"circle",spacing:t.legendMarkerSpacing,style:{r:t.legendCircleMarkerSize,fill:t.legendMarkerColor}},itemName:{spacing:5,style:{fill:t.legendItemNameFillColor,fontFamily:t.fontFamily,fontSize:t.legendItemNameFontSize,lineHeight:t.legendItemNameLineHeight,fontWeight:t.legendItemNameFontWeight,textAlign:"start",textBaseline:"middle"}},itemStates:{active:{nameStyle:{opacity:.8}},unchecked:{nameStyle:{fill:"#D8D8D8"},markerStyle:{fill:"#D8D8D8",stroke:"#D8D8D8"}},inactive:{nameStyle:{fill:"#D8D8D8"},markerStyle:{opacity:.2}}},flipPage:!0,pageNavigator:{marker:{style:{size:t.legendPageNavigatorMarkerSize,inactiveFill:t.legendPageNavigatorMarkerInactiveFillColor,inactiveOpacity:t.legendPageNavigatorMarkerInactiveFillOpacity,fill:t.legendPageNavigatorMarkerFillColor,opacity:t.legendPageNavigatorMarkerFillOpacity}},text:{style:{fill:t.legendPageNavigatorTextFillColor,fontSize:t.legendPageNavigatorTextFontSize}}},animate:!1,maxItemWidth:200,itemSpacing:t.legendItemSpacing,itemMarginBottom:t.legendItemMarginBottom,padding:t.legendPadding}}(t);return{background:t.backgroundColor,defaultColor:t.brandColor,subColor:t.subColor,semanticRed:t.paletteSemanticRed,semanticGreen:t.paletteSemanticGreen,padding:"auto",fontFamily:t.fontFamily,columnWidthRatio:.5,maxColumnWidth:null,minColumnWidth:null,roseWidthRatio:.9999999,multiplePieWidthRatio:1/1.3,colors10:t.paletteQualitative10,colors20:t.paletteQualitative20,sequenceColors:t.paletteSequence,shapes:{point:["hollow-circle","hollow-square","hollow-bowtie","hollow-diamond","hollow-hexagon","hollow-triangle","hollow-triangle-down","circle","square","bowtie","diamond","hexagon","triangle","triangle-down","cross","tick","plus","hyphen","line"],line:["line","dash","dot","smooth"],area:["area","smooth","line","smooth-line"],interval:["rect","hollow-rect","line","tick"]},sizes:[1,10],geometries:{interval:{rect:{default:{style:n.interval.default},active:{style:n.interval.active},inactive:{style:n.interval.inactive},selected:{style:function(t){var e=t.geometry.coordinate;if(e.isPolar&&e.isTransposed){var i=ot(t.getModel(),e),r=(i.startAngle+i.endAngle)/2,o=7.5*Math.cos(r),a=7.5*Math.sin(r);return{matrix:N.ext.transform(null,[["t",o,a]])}}return n.interval.selected}}},"hollow-rect":{default:{style:n.hollowInterval.default},active:{style:n.hollowInterval.active},inactive:{style:n.hollowInterval.inactive},selected:{style:n.hollowInterval.selected}},line:{default:{style:n.hollowInterval.default},active:{style:n.hollowInterval.active},inactive:{style:n.hollowInterval.inactive},selected:{style:n.hollowInterval.selected}},tick:{default:{style:n.hollowInterval.default},active:{style:n.hollowInterval.active},inactive:{style:n.hollowInterval.inactive},selected:{style:n.hollowInterval.selected}},funnel:{default:{style:n.interval.default},active:{style:n.interval.active},inactive:{style:n.interval.inactive},selected:{style:n.interval.selected}},pyramid:{default:{style:n.interval.default},active:{style:n.interval.active},inactive:{style:n.interval.inactive},selected:{style:n.interval.selected}}},line:{line:{default:{style:n.line.default},active:{style:n.line.active},inactive:{style:n.line.inactive},selected:{style:n.line.selected}},dot:{default:{style:Object(a.__assign)(Object(a.__assign)({},n.line.default),{lineCap:null,lineDash:[1,1]})},active:{style:Object(a.__assign)(Object(a.__assign)({},n.line.active),{lineCap:null,lineDash:[1,1]})},inactive:{style:Object(a.__assign)(Object(a.__assign)({},n.line.inactive),{lineCap:null,lineDash:[1,1]})},selected:{style:Object(a.__assign)(Object(a.__assign)({},n.line.selected),{lineCap:null,lineDash:[1,1]})}},dash:{default:{style:Object(a.__assign)(Object(a.__assign)({},n.line.default),{lineCap:null,lineDash:[5.5,1]})},active:{style:Object(a.__assign)(Object(a.__assign)({},n.line.active),{lineCap:null,lineDash:[5.5,1]})},inactive:{style:Object(a.__assign)(Object(a.__assign)({},n.line.inactive),{lineCap:null,lineDash:[5.5,1]})},selected:{style:Object(a.__assign)(Object(a.__assign)({},n.line.selected),{lineCap:null,lineDash:[5.5,1]})}},smooth:{default:{style:n.line.default},active:{style:n.line.active},inactive:{style:n.line.inactive},selected:{style:n.line.selected}},hv:{default:{style:n.line.default},active:{style:n.line.active},inactive:{style:n.line.inactive},selected:{style:n.line.selected}},vh:{default:{style:n.line.default},active:{style:n.line.active},inactive:{style:n.line.inactive},selected:{style:n.line.selected}},hvh:{default:{style:n.line.default},active:{style:n.line.active},inactive:{style:n.line.inactive},selected:{style:n.line.selected}},vhv:{default:{style:n.line.default},active:{style:n.line.active},inactive:{style:n.line.inactive},selected:{style:n.line.selected}}},polygon:{polygon:{default:{style:n.interval.default},active:{style:n.interval.active},inactive:{style:n.interval.inactive},selected:{style:n.interval.selected}}},point:{circle:{default:{style:n.point.default},active:{style:n.point.active},inactive:{style:n.point.inactive},selected:{style:n.point.selected}},square:{default:{style:n.point.default},active:{style:n.point.active},inactive:{style:n.point.inactive},selected:{style:n.point.selected}},bowtie:{default:{style:n.point.default},active:{style:n.point.active},inactive:{style:n.point.inactive},selected:{style:n.point.selected}},diamond:{default:{style:n.point.default},active:{style:n.point.active},inactive:{style:n.point.inactive},selected:{style:n.point.selected}},hexagon:{default:{style:n.point.default},active:{style:n.point.active},inactive:{style:n.point.inactive},selected:{style:n.point.selected}},triangle:{default:{style:n.point.default},active:{style:n.point.active},inactive:{style:n.point.inactive},selected:{style:n.point.selected}},"triangle-down":{default:{style:n.point.default},active:{style:n.point.active},inactive:{style:n.point.inactive},selected:{style:n.point.selected}},"hollow-circle":{default:{style:n.hollowPoint.default},active:{style:n.hollowPoint.active},inactive:{style:n.hollowPoint.inactive},selected:{style:n.hollowPoint.selected}},"hollow-square":{default:{style:n.hollowPoint.default},active:{style:n.hollowPoint.active},inactive:{style:n.hollowPoint.inactive},selected:{style:n.hollowPoint.selected}},"hollow-bowtie":{default:{style:n.hollowPoint.default},active:{style:n.hollowPoint.active},inactive:{style:n.hollowPoint.inactive},selected:{style:n.hollowPoint.selected}},"hollow-diamond":{default:{style:n.hollowPoint.default},active:{style:n.hollowPoint.active},inactive:{style:n.hollowPoint.inactive},selected:{style:n.hollowPoint.selected}},"hollow-hexagon":{default:{style:n.hollowPoint.default},active:{style:n.hollowPoint.active},inactive:{style:n.hollowPoint.inactive},selected:{style:n.hollowPoint.selected}},"hollow-triangle":{default:{style:n.hollowPoint.default},active:{style:n.hollowPoint.active},inactive:{style:n.hollowPoint.inactive},selected:{style:n.hollowPoint.selected}},"hollow-triangle-down":{default:{style:n.hollowPoint.default},active:{style:n.hollowPoint.active},inactive:{style:n.hollowPoint.inactive},selected:{style:n.hollowPoint.selected}},cross:{default:{style:n.hollowPoint.default},active:{style:n.hollowPoint.active},inactive:{style:n.hollowPoint.inactive},selected:{style:n.hollowPoint.selected}},tick:{default:{style:n.hollowPoint.default},active:{style:n.hollowPoint.active},inactive:{style:n.hollowPoint.inactive},selected:{style:n.hollowPoint.selected}},plus:{default:{style:n.hollowPoint.default},active:{style:n.hollowPoint.active},inactive:{style:n.hollowPoint.inactive},selected:{style:n.hollowPoint.selected}},hyphen:{default:{style:n.hollowPoint.default},active:{style:n.hollowPoint.active},inactive:{style:n.hollowPoint.inactive},selected:{style:n.hollowPoint.selected}},line:{default:{style:n.hollowPoint.default},active:{style:n.hollowPoint.active},inactive:{style:n.hollowPoint.inactive},selected:{style:n.hollowPoint.selected}}},area:{area:{default:{style:n.area.default},active:{style:n.area.active},inactive:{style:n.area.inactive},selected:{style:n.area.selected}},smooth:{default:{style:n.area.default},active:{style:n.area.active},inactive:{style:n.area.inactive},selected:{style:n.area.selected}},line:{default:{style:n.hollowArea.default},active:{style:n.hollowArea.active},inactive:{style:n.hollowArea.inactive},selected:{style:n.hollowArea.selected}},"smooth-line":{default:{style:n.hollowArea.default},active:{style:n.hollowArea.active},inactive:{style:n.hollowArea.inactive},selected:{style:n.hollowArea.selected}}},schema:{candle:{default:{style:n.hollowInterval.default},active:{style:n.hollowInterval.active},inactive:{style:n.hollowInterval.inactive},selected:{style:n.hollowInterval.selected}},box:{default:{style:n.hollowInterval.default},active:{style:n.hollowInterval.active},inactive:{style:n.hollowInterval.inactive},selected:{style:n.hollowInterval.selected}}},edge:{line:{default:{style:n.line.default},active:{style:n.line.active},inactive:{style:n.line.inactive},selected:{style:n.line.selected}},vhv:{default:{style:n.line.default},active:{style:n.line.active},inactive:{style:n.line.inactive},selected:{style:n.line.selected}},smooth:{default:{style:n.line.default},active:{style:n.line.active},inactive:{style:n.line.inactive},selected:{style:n.line.selected}},arc:{default:{style:n.line.default},active:{style:n.line.active},inactive:{style:n.line.inactive},selected:{style:n.line.selected}}},violin:{violin:{default:{style:n.line.default},active:{style:n.line.active},inactive:{style:n.line.inactive},selected:{style:n.line.selected}},smooth:{default:{style:n.line.default},active:{style:n.line.active},inactive:{style:n.line.inactive},selected:{style:n.line.selected}},hollow:{default:{style:n.hollowArea.default},active:{style:n.hollowArea.active},inactive:{style:n.hollowArea.inactive},selected:{style:n.hollowArea.selected}},"hollow-smooth":{default:{style:n.hollowArea.default},active:{style:n.hollowArea.active},inactive:{style:n.hollowArea.inactive},selected:{style:n.hollowArea.selected}}}},components:{axis:{common:i,top:{position:"top",grid:null,title:null,verticalLimitLength:.5},bottom:{position:"bottom",grid:null,title:null,verticalLimitLength:.5},left:{position:"left",title:null,line:null,tickLine:null,verticalLimitLength:1/3},right:{position:"right",title:null,line:null,tickLine:null,verticalLimitLength:1/3},circle:{title:null,grid:Object(s.deepMix)({},i.grid,{line:{type:"line"}})},radius:{title:null,grid:Object(s.deepMix)({},i.grid,{line:{type:"circle"}})}},legend:{common:r,right:{layout:"vertical",padding:t.legendVerticalPadding},left:{layout:"vertical",padding:t.legendVerticalPadding},top:{layout:"horizontal",padding:t.legendHorizontalPadding},bottom:{layout:"horizontal",padding:t.legendHorizontalPadding},continuous:{title:null,background:null,track:{},rail:{type:"color",size:t.sliderRailHeight,defaultLength:t.sliderRailWidth,style:{fill:t.sliderRailFillColor,stroke:t.sliderRailBorderColor,lineWidth:t.sliderRailBorder}},label:{align:"rail",spacing:4,formatter:null,style:{fill:t.sliderLabelTextFillColor,fontSize:t.sliderLabelTextFontSize,lineHeight:t.sliderLabelTextLineHeight,textBaseline:"middle",fontFamily:t.fontFamily}},handler:{size:t.sliderHandlerWidth,style:{fill:t.sliderHandlerFillColor,stroke:t.sliderHandlerBorderColor}},slidable:!0,padding:r.padding}},tooltip:{showContent:!0,follow:!0,showCrosshairs:!1,showMarkers:!0,shared:!1,enterable:!1,position:"auto",marker:{symbol:"circle",stroke:"#fff",shadowBlur:10,shadowOffsetX:0,shadowOffsetY:0,shadowColor:"rgba(0,0,0,0.09)",lineWidth:2,r:4},crosshairs:{line:{style:{stroke:t.tooltipCrosshairsBorderColor,lineWidth:t.tooltipCrosshairsBorder}},text:null,textBackground:{padding:2,style:{fill:"rgba(0, 0, 0, 0.25)",lineWidth:0,stroke:null}},follow:!1},domStyles:(e={},e["".concat(H.TOOLTIP_CSS_CONST.CONTAINER_CLASS)]={position:"absolute",visibility:"hidden",zIndex:8,transition:"left 0.4s cubic-bezier(0.23, 1, 0.32, 1) 0s, top 0.4s cubic-bezier(0.23, 1, 0.32, 1) 0s",backgroundColor:t.tooltipContainerFillColor,opacity:t.tooltipContainerFillOpacity,boxShadow:t.tooltipContainerShadow,borderRadius:"".concat(t.tooltipContainerBorderRadius,"px"),color:t.tooltipTextFillColor,fontSize:"".concat(t.tooltipTextFontSize,"px"),fontFamily:t.fontFamily,lineHeight:"".concat(t.tooltipTextLineHeight,"px"),padding:"0 12px 0 12px"},e["".concat(H.TOOLTIP_CSS_CONST.TITLE_CLASS)]={marginBottom:"12px",marginTop:"12px"},e["".concat(H.TOOLTIP_CSS_CONST.LIST_CLASS)]={margin:0,listStyleType:"none",padding:0},e["".concat(H.TOOLTIP_CSS_CONST.LIST_ITEM_CLASS)]={listStyleType:"none",padding:0,marginBottom:"12px",marginTop:"12px",marginLeft:0,marginRight:0},e["".concat(H.TOOLTIP_CSS_CONST.MARKER_CLASS)]={width:"8px",height:"8px",borderRadius:"50%",display:"inline-block",marginRight:"8px"},e["".concat(H.TOOLTIP_CSS_CONST.VALUE_CLASS)]={display:"inline-block",float:"right",marginLeft:"30px"},e)},annotation:{arc:{style:{stroke:t.annotationArcBorderColor,lineWidth:t.annotationArcBorder},animate:!0},line:{style:{stroke:t.annotationLineBorderColor,lineDash:t.annotationLineDash,lineWidth:t.annotationLineBorder},text:{position:"start",autoRotate:!0,style:{fill:t.annotationTextFillColor,stroke:t.annotationTextBorderColor,lineWidth:t.annotationTextBorder,fontSize:t.annotationTextFontSize,textAlign:"start",fontFamily:t.fontFamily,textBaseline:"bottom"}},animate:!0},text:{style:{fill:t.annotationTextFillColor,stroke:t.annotationTextBorderColor,lineWidth:t.annotationTextBorder,fontSize:t.annotationTextFontSize,textBaseline:"middle",textAlign:"start",fontFamily:t.fontFamily},animate:!0},region:{top:!1,style:{lineWidth:t.annotationRegionBorder,stroke:t.annotationRegionBorderColor,fill:t.annotationRegionFillColor,fillOpacity:t.annotationRegionFillOpacity},animate:!0},image:{top:!1,animate:!0},dataMarker:{top:!0,point:{style:{r:3,stroke:t.brandColor,lineWidth:2}},line:{style:{stroke:t.annotationLineBorderColor,lineWidth:t.annotationLineBorder},length:t.annotationDataMarkerLineLength},text:{style:{textAlign:"start",fill:t.annotationTextFillColor,stroke:t.annotationTextBorderColor,lineWidth:t.annotationTextBorder,fontSize:t.annotationTextFontSize,fontFamily:t.fontFamily}},direction:"upward",autoAdjust:!0,animate:!0},dataRegion:{style:{region:{fill:t.annotationRegionFillColor,fillOpacity:t.annotationRegionFillOpacity},text:{textAlign:"center",textBaseline:"bottom",fill:t.annotationTextFillColor,stroke:t.annotationTextBorderColor,lineWidth:t.annotationTextBorder,fontSize:t.annotationTextFontSize,fontFamily:t.fontFamily}},animate:!0}},slider:{common:{padding:[8,8,8,8],backgroundStyle:{fill:t.cSliderBackgroundFillColor,opacity:t.cSliderBackgroundFillOpacity},foregroundStyle:{fill:t.cSliderForegroundFillColor,opacity:t.cSliderForegroundFillOpacity},handlerStyle:{width:t.cSliderHandlerWidth,height:t.cSliderHandlerHeight,fill:t.cSliderHandlerFillColor,opacity:t.cSliderHandlerFillOpacity,stroke:t.cSliderHandlerBorderColor,lineWidth:t.cSliderHandlerBorder,radius:t.cSliderHandlerBorderRadius,highLightFill:t.cSliderHandlerHighlightFillColor},textStyle:{fill:t.cSliderTextFillColor,opacity:t.cSliderTextFillOpacity,fontSize:t.cSliderTextFontSize,lineHeight:t.cSliderTextLineHeight,fontWeight:t.cSliderTextFontWeight,stroke:t.cSliderTextBorderColor,lineWidth:t.cSliderTextBorder}}},scrollbar:{common:{padding:[8,8,8,8]},default:{style:{trackColor:t.scrollbarTrackFillColor,thumbColor:t.scrollbarThumbFillColor}},hover:{style:{thumbColor:t.scrollbarThumbHighlightFillColor}}}},labels:{offset:12,style:{fill:t.labelFillColor,fontSize:t.labelFontSize,fontFamily:t.fontFamily,stroke:t.labelBorderColor,lineWidth:t.labelBorder},fillColorDark:t.labelFillColorDark,fillColorLight:t.labelFillColorLight,autoRotate:!0},innerLabels:{style:{fill:t.innerLabelFillColor,fontSize:t.innerLabelFontSize,fontFamily:t.fontFamily,stroke:t.innerLabelBorderColor,lineWidth:t.innerLabelBorder},autoRotate:!0},overflowLabels:{style:{fill:t.overflowLabelFillColor,fontSize:t.overflowLabelFontSize,fontFamily:t.fontFamily,stroke:t.overflowLabelBorderColor,lineWidth:t.overflowLabelBorder}},pieLabels:{labelHeight:14,offset:10,labelLine:{style:{lineWidth:t.labelLineBorder}},autoRotate:!0}}}var Ee="#000",Ie="#595959",Pe="#8C8C8C",Fe="#BFBFBF",Te="#D9D9D9",Le="#F0F0F0",ke="#FFFFFF",De=["#5B8FF9","#5AD8A6","#5D7092","#F6BD16","#6F5EF9","#6DC8EC","#945FB9","#FF9845","#1E9493","#FF99C3"],Be=["#5B8FF9","#CDDDFD","#5AD8A6","#CDF3E4","#5D7092","#CED4DE","#F6BD16","#FCEBB9","#6F5EF9","#D3CEFD","#6DC8EC","#D3EEF9","#945FB9","#DECFEA","#FF9845","#FFE0C7","#1E9493","#BBDEDE","#FF99C3","#FFE0ED"],Re=["#B8E1FF","#9AC5FF","#7DAAFF","#5B8FF9","#3D76DD","#085EC0","#0047A5","#00318A","#001D70"],Ne=function(t){void 0===t&&(t={});var e=t.backgroundColor,n=void 0===e?"transparent":e,i=t.subColor,r=void 0===i?"rgba(0,0,0,0.05)":i,o=t.paletteQualitative10,a=void 0===o?De:o,s=t.paletteQualitative20,c=void 0===s?Be:s,l=t.paletteSemanticRed,u=void 0===l?"#F4664A":l,h=t.paletteSemanticGreen,f=void 0===h?"#30BF78":h,p=t.paletteSemanticYellow,d=void 0===p?"#FAAD14":p,g=t.paletteSequence,y=void 0===g?Re:g,v=t.fontFamily,m=void 0===v?'"Segoe UI", Roboto, "Helvetica Neue", Arial,\n "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol",\n "Noto Color Emoji"':v,x=t.brandColor,b=void 0===x?a[0]:x;return{backgroundColor:n,brandColor:b,subColor:r,paletteQualitative10:a,paletteQualitative20:c,paletteSemanticRed:u,paletteSemanticGreen:f,paletteSemanticYellow:d,paletteSequence:y,fontFamily:m,axisLineBorderColor:Fe,axisLineBorder:1,axisLineDash:null,axisTitleTextFillColor:Ie,axisTitleTextFontSize:12,axisTitleTextLineHeight:12,axisTitleTextFontWeight:"normal",axisTitleSpacing:12,axisTickLineBorderColor:Fe,axisTickLineLength:4,axisTickLineBorder:1,axisSubTickLineBorderColor:Te,axisSubTickLineLength:2,axisSubTickLineBorder:1,axisLabelFillColor:Pe,axisLabelFontSize:12,axisLabelLineHeight:12,axisLabelFontWeight:"normal",axisLabelOffset:8,axisGridBorderColor:Te,axisGridBorder:1,axisGridLineDash:null,legendTitleTextFillColor:Pe,legendTitleTextFontSize:12,legendTitleTextLineHeight:21,legendTitleTextFontWeight:"normal",legendMarkerColor:b,legendMarkerSpacing:8,legendMarkerSize:4,legendCircleMarkerSize:4,legendSquareMarkerSize:4,legendLineMarkerSize:5,legendItemNameFillColor:Ie,legendItemNameFontSize:12,legendItemNameLineHeight:12,legendItemNameFontWeight:"normal",legendItemSpacing:24,legendItemMarginBottom:12,legendPadding:[8,8,8,8],legendHorizontalPadding:[8,0,8,0],legendVerticalPadding:[0,8,0,8],legendPageNavigatorMarkerSize:12,legendPageNavigatorMarkerInactiveFillColor:Ee,legendPageNavigatorMarkerInactiveFillOpacity:.45,legendPageNavigatorMarkerFillColor:Ee,legendPageNavigatorMarkerFillOpacity:1,legendPageNavigatorTextFillColor:Pe,legendPageNavigatorTextFontSize:12,sliderRailFillColor:Te,sliderRailBorder:0,sliderRailBorderColor:null,sliderRailWidth:100,sliderRailHeight:12,sliderLabelTextFillColor:Pe,sliderLabelTextFontSize:12,sliderLabelTextLineHeight:12,sliderLabelTextFontWeight:"normal",sliderHandlerFillColor:Le,sliderHandlerWidth:10,sliderHandlerHeight:14,sliderHandlerBorder:1,sliderHandlerBorderColor:Fe,annotationArcBorderColor:Te,annotationArcBorder:1,annotationLineBorderColor:Fe,annotationLineBorder:1,annotationLineDash:null,annotationTextFillColor:Ie,annotationTextFontSize:12,annotationTextLineHeight:12,annotationTextFontWeight:"normal",annotationTextBorderColor:null,annotationTextBorder:0,annotationRegionFillColor:Ee,annotationRegionFillOpacity:.06,annotationRegionBorder:0,annotationRegionBorderColor:null,annotationDataMarkerLineLength:16,tooltipCrosshairsBorderColor:Fe,tooltipCrosshairsBorder:1,tooltipCrosshairsLineDash:null,tooltipContainerFillColor:"rgb(255, 255, 255)",tooltipContainerFillOpacity:.95,tooltipContainerShadow:"0px 0px 10px #aeaeae",tooltipContainerBorderRadius:3,tooltipTextFillColor:Ie,tooltipTextFontSize:12,tooltipTextLineHeight:12,tooltipTextFontWeight:"bold",labelFillColor:Ie,labelFillColorDark:"#2c3542",labelFillColorLight:"#ffffff",labelFontSize:12,labelLineHeight:12,labelFontWeight:"normal",labelBorderColor:null,labelBorder:0,innerLabelFillColor:ke,innerLabelFontSize:12,innerLabelLineHeight:12,innerLabelFontWeight:"normal",innerLabelBorderColor:null,innerLabelBorder:0,overflowLabelFillColor:Ie,overflowLabelFontSize:12,overflowLabelLineHeight:12,overflowLabelFontWeight:"normal",overflowLabelBorderColor:ke,overflowLabelBorder:1,labelLineBorder:1,labelLineBorderColor:Fe,cSliderRailHieght:16,cSliderBackgroundFillColor:"#416180",cSliderBackgroundFillOpacity:.05,cSliderForegroundFillColor:"#5B8FF9",cSliderForegroundFillOpacity:.15,cSliderHandlerHeight:24,cSliderHandlerWidth:10,cSliderHandlerFillColor:"#F7F7F7",cSliderHandlerFillOpacity:1,cSliderHandlerHighlightFillColor:"#FFF",cSliderHandlerBorderColor:"#BFBFBF",cSliderHandlerBorder:1,cSliderHandlerBorderRadius:2,cSliderTextFillColor:"#000",cSliderTextFillOpacity:.45,cSliderTextFontSize:12,cSliderTextLineHeight:12,cSliderTextFontWeight:"normal",cSliderTextBorderColor:null,cSliderTextBorder:0,scrollbarTrackFillColor:"rgba(0,0,0,0)",scrollbarThumbFillColor:"rgba(0,0,0,0.15)",scrollbarThumbHighlightFillColor:"rgba(0,0,0,0.2)",pointFillColor:b,pointFillOpacity:.95,pointSize:4,pointBorder:1,pointBorderColor:ke,pointBorderOpacity:1,pointActiveBorderColor:Ee,pointSelectedBorder:2,pointSelectedBorderColor:Ee,pointInactiveFillOpacity:.3,pointInactiveBorderOpacity:.3,hollowPointSize:4,hollowPointBorder:1,hollowPointBorderColor:b,hollowPointBorderOpacity:.95,hollowPointFillColor:ke,hollowPointActiveBorder:1,hollowPointActiveBorderColor:Ee,hollowPointActiveBorderOpacity:1,hollowPointSelectedBorder:2,hollowPointSelectedBorderColor:Ee,hollowPointSelectedBorderOpacity:1,hollowPointInactiveBorderOpacity:.3,lineBorder:2,lineBorderColor:b,lineBorderOpacity:1,lineActiveBorder:3,lineSelectedBorder:3,lineInactiveBorderOpacity:.3,areaFillColor:b,areaFillOpacity:.25,areaActiveFillColor:b,areaActiveFillOpacity:.5,areaSelectedFillColor:b,areaSelectedFillOpacity:.5,areaInactiveFillOpacity:.3,hollowAreaBorderColor:b,hollowAreaBorder:2,hollowAreaBorderOpacity:1,hollowAreaActiveBorder:3,hollowAreaActiveBorderColor:Ee,hollowAreaSelectedBorder:3,hollowAreaSelectedBorderColor:Ee,hollowAreaInactiveBorderOpacity:.3,intervalFillColor:b,intervalFillOpacity:.95,intervalActiveBorder:1,intervalActiveBorderColor:Ee,intervalActiveBorderOpacity:1,intervalSelectedBorder:2,intervalSelectedBorderColor:Ee,intervalSelectedBorderOpacity:1,intervalInactiveBorderOpacity:.3,intervalInactiveFillOpacity:.3,hollowIntervalBorder:2,hollowIntervalBorderColor:b,hollowIntervalBorderOpacity:1,hollowIntervalFillColor:ke,hollowIntervalActiveBorder:2,hollowIntervalActiveBorderColor:Ee,hollowIntervalSelectedBorder:3,hollowIntervalSelectedBorderColor:Ee,hollowIntervalSelectedBorderOpacity:1,hollowIntervalInactiveBorderOpacity:.3}};Ne();function Ve(t){var e=t.styleSheet,n=void 0===e?{}:e,i=Object(a.__rest)(t,["styleSheet"]),r=Ne(n);return Object(s.deepMix)({},Ce(r),i)}var ze={default:Ve({})};function Ge(t){return Object(s.get)(ze,Object(s.lowerCase)(t),ze.default)}function Ye(t,e){ze[Object(s.lowerCase)(t)]=Ve(e)}function Xe(t,e,n){var i=n.translate(t),r=n.translate(e);return Object(s.isNumberEqual)(i,r)}function We(t,e,n){var i=n.coordinate,r=n.getYScale(),o=r.field,a=i.invert(e),c=r.invert(a.y);return Object(s.find)(t,(function(t){var e=t._origin;return e[o][0]<=c&&e[o][1]>=c}))||t[t.length-1]}var He=Object(s.memoize)((function(t){if(t.isCategory)return 1;for(var e=t.values,n=e.length,i=t.translate(e[0]),r=i,o=0;or&&(r=s)}return(r-i)/(n-1)}));function Ue(t){for(var e,n=0,i=function(t){var e=Object(s.values)(t.attributes);return Object(s.filter)(e,(function(t){return Object(s.contains)(g,t.type)}))}(t);n(1+o)/2&&(s=a),i.translate(i.invert(s))}(t,n),O=m._origin[a],_=m._origin[c],w=x._origin[a],j=o.isLinear&&Object(s.isArray)(_);if(Object(s.isArray)(O)){for(d=0;d=b){if(!j){l=I;break}Object(s.isArray)(l)||(l=[]),l.push(I)}}Object(s.isArray)(l)&&(l=We(l,t,n))}else{var S=void 0;if(r.isLinear||"timeCat"===r.type){if((b>r.translate(w)||br.max||bMath.abs(r.translate(S._origin[a])-b)&&(x=S)}var P=He(n.getXScale());return!l&&Math.abs(r.translate(x._origin[a])-b)<=P/2&&(l=x),l}function Ze(t,e,n,i){void 0===n&&(n=""),void 0===i&&(i=!1);var r,o=t._origin,c=function(t,e,n){var i=e.getAttribute("position").getFields(),r=e.scales,o=Object(s.isFunction)(n)||!n?i[0]:n,a=r[o],c=a?a.getText(t[o]):t[o]||o;return Object(s.isFunction)(n)?n(c,t):c}(o,e,n),l=e.tooltipOption,u=e.theme.defaultColor,h=[];function f(e,n){if(i||!Object(s.isNil)(n)&&""!==n){var r={title:c,data:o,mappingData:t,name:e,value:n,color:t.color||u,marker:!0};h.push(r)}}if(Object(s.isObject)(l)){var p=l.fields,d=l.callback;if(d){var g=p.map((function(e){return t._origin[e]})),y=d.apply(void 0,g),v=Object(a.__assign)({data:t._origin,mappingData:t,title:c,color:t.color||u,marker:!0},y);h.push(v)}else for(var m=e.scales,x=0,b=p;x');T.appendChild(L);var k=O(T,l,r,o),D=new(v(y).Canvas)(Object(a.__assign)({container:L,pixelRatio:m,localRefresh:_,supportCSSTransform:M},k));return(n=t.call(this,{parent:null,canvas:D,backgroundGroup:D.addGroup({zIndex:d}),middleGroup:D.addGroup({zIndex:p}),foregroundGroup:D.addGroup({zIndex:f}),padding:u,appendPadding:h,visible:j,options:E,limitInPlot:I,theme:P,syncViewPadding:F})||this).onResize=Object(s.debounce)((function(){n.forceFit()}),300),n.ele=T,n.canvas=D,n.width=k.width,n.height=k.height,n.autoFit=l,n.localRefresh=_,n.renderer=y,n.wrapperElement=L,n.updateCanvasStyle(),n.bindAutoFit(),n.initDefaultInteractions(C),n}return Object(a.__extends)(e,t),e.prototype.initDefaultInteractions=function(t){var e=this;Object(s.each)(t,(function(t){e.interaction(t)}))},e.prototype.aria=function(t){!1===t?this.ele.removeAttribute("aria-label"):this.ele.setAttribute("aria-label",t.label)},e.prototype.changeSize=function(t,e){return this.width===t&&this.height===e||(this.emit(c.BEFORE_CHANGE_SIZE),this.width=t,this.height=e,this.canvas.changeSize(t,e),this.render(!0),this.emit(c.AFTER_CHANGE_SIZE)),this},e.prototype.clear=function(){t.prototype.clear.call(this),this.aria(!1)},e.prototype.destroy=function(){var e,n;t.prototype.destroy.call(this),this.unbindAutoFit(),this.canvas.destroy(),e=this.wrapperElement,(n=e.parentNode)&&n.removeChild(e),this.wrapperElement=null},e.prototype.changeVisible=function(e){return t.prototype.changeVisible.call(this,e),this.wrapperElement.style.display=e?"":"none",this},e.prototype.forceFit=function(){if(!this.destroyed){var t=O(this.ele,!0,this.width,this.height),e=t.width,n=t.height;this.changeSize(e,n)}},e.prototype.updateCanvasStyle=function(){Object(x.e)(this.canvas.get("el"),{display:"inline-block",verticalAlign:"middle"})},e.prototype.bindAutoFit=function(){this.autoFit&&window.addEventListener("resize",this.onResize)},e.prototype.unbindAutoFit=function(){this.autoFit&&window.removeEventListener("resize",this.onResize)},e}(fn),dn=function(){function t(t){this.visible=!0,this.components=[],this.view=t}return t.prototype.clear=function(t){Object(s.each)(this.components,(function(t){t.component.destroy()})),this.components=[]},t.prototype.destroy=function(){this.clear()},t.prototype.getComponents=function(){return this.components},t.prototype.changeVisible=function(t){this.visible!==t&&(this.components.forEach((function(e){t?e.component.show():e.component.hide()})),this.visible=t)},t}();var gn=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.isLocked=!1,e}return Object(a.__extends)(e,t),Object.defineProperty(e.prototype,"name",{get:function(){return"tooltip"},enumerable:!1,configurable:!0}),e.prototype.init=function(){},e.prototype.isVisible=function(){return!1!==this.view.getOptions().tooltip},e.prototype.render=function(){},e.prototype.showTooltip=function(t){if(this.point=t,this.isVisible()){var e=this.view,n=this.getTooltipItems(t);if(n.length){var i=this.getTitle(n),r={x:n[0].x,y:n[0].y};e.emit("tooltip:show",rn.fromData(e,"tooltip:show",Object(a.__assign)({items:n,title:i},t)));var o=this.getTooltipCfg(),c=o.follow,l=o.showMarkers,u=o.showCrosshairs,h=o.showContent,f=o.marker,p=this.items,d=this.title;if(Object(s.isEqual)(d,i)&&Object(s.isEqual)(p,n)?(this.tooltip&&c&&(this.tooltip.update(t),this.tooltip.show()),this.tooltipMarkersGroup&&this.tooltipMarkersGroup.show()):(e.emit("tooltip:change",rn.fromData(e,"tooltip:change",Object(a.__assign)({items:n,title:i},t))),(Object(s.isFunction)(h)?h(n):h)&&(this.tooltip||this.renderTooltip(),this.tooltip.update(Object(s.mix)({},o,{items:this.getItemsAfterProcess(n),title:i},c?t:{})),this.tooltip.show()),l&&this.renderTooltipMarkers(n,f)),this.items=n,this.title=i,u){var g=Object(s.get)(o,["crosshairs","follow"],!1);this.renderCrosshairs(g?t:r,o)}}else this.hideTooltip()}},e.prototype.hideTooltip=function(){if(this.getTooltipCfg().follow){var t=this.tooltipMarkersGroup;t&&t.hide();var e=this.xCrosshair,n=this.yCrosshair;e&&e.hide(),n&&n.hide();var i=this.tooltip;i&&i.hide(),this.view.emit("tooltip:hide",rn.fromData(this.view,"tooltip:hide",{})),this.point=null}else this.point=null},e.prototype.lockTooltip=function(){this.isLocked=!0,this.tooltip&&this.tooltip.setCapture(!0)},e.prototype.unlockTooltip=function(){this.isLocked=!1;var t=this.getTooltipCfg();this.tooltip&&this.tooltip.setCapture(t.capture)},e.prototype.isTooltipLocked=function(){return this.isLocked},e.prototype.clear=function(){var t=this.tooltip,e=this.xCrosshair,n=this.yCrosshair,i=this.tooltipMarkersGroup;t&&(t.hide(),t.clear()),e&&e.clear(),n&&n.clear(),i&&i.clear(),(null==t?void 0:t.get("customContent"))&&(this.tooltip.destroy(),this.tooltip=null),this.title=null,this.items=null},e.prototype.destroy=function(){this.tooltip&&this.tooltip.destroy(),this.xCrosshair&&this.xCrosshair.destroy(),this.yCrosshair&&this.yCrosshair.destroy(),this.guideGroup&&this.guideGroup.remove(!0),this.reset()},e.prototype.reset=function(){this.items=null,this.title=null,this.tooltipMarkersGroup=null,this.tooltipCrosshairsGroup=null,this.xCrosshair=null,this.yCrosshair=null,this.tooltip=null,this.guideGroup=null,this.isLocked=!1,this.point=null},e.prototype.changeVisible=function(t){if(this.visible!==t){var e=this.tooltip,n=this.tooltipMarkersGroup,i=this.xCrosshair,r=this.yCrosshair;t?(e&&e.show(),n&&n.show(),i&&i.show(),r&&r.show()):(e&&e.hide(),n&&n.hide(),i&&i.hide(),r&&r.hide()),this.visible=t}},e.prototype.getTooltipItems=function(t){var e=this.findItemsFromView(this.view,t);if(e.length){for(var n=0,i=e=Object(s.flatten)(e);n1){for(var h=e[0],f=Math.abs(t.y-h[0].y),p=0,d=e;p'+i+"":i}})},e.prototype.getTitle=function(t){var e=t[0].title||t[0].name;return this.title=e,e},e.prototype.renderTooltip=function(){var t=this.view.getCanvas(),e={start:{x:0,y:0},end:{x:t.get("width"),y:t.get("height")}},n=this.getTooltipCfg(),i=new J(Object(a.__assign)(Object(a.__assign)({parent:t.get("el").parentNode,region:e},n),{visible:!1,crosshairs:null}));i.init(),this.tooltip=i},e.prototype.renderTooltipMarkers=function(t,e){for(var n=this.getTooltipMarkersGroup(),i=this.view.getRootView(),r=i.limitInPlot,o=0,s=t;o-1)return;i.push(t),"active"!==t&&"selected"!==t||null==a||a.toFront()}else{if(-1===c)return;if(i.splice(c,1),"active"===t||"selected"===t){var l=this.geometry,u=l.sortZIndex,h=l.zIndexReversed?this.geometry.elements.length-this.elementIndex:this.elementIndex;u?a.setZIndex(h):a.set("zIndex",h)}}var f=r.drawShape(s,o,this.getOffscreenGroup());i.length?this.syncShapeStyle(a,f,i,null):this.syncShapeStyle(a,f,["reset"],null),f.remove(!0);var p={state:t,stateStatus:e,element:this,target:this.container};this.container.emit("statechange",p),Object(H.propagationDelegate)(this.shape,"statechange",p)},e.prototype.clearStates=function(){var t=this,e=this.states;Object(s.each)(e,(function(e){t.setState(e,!1)})),this.states=[]},e.prototype.hasState=function(t){return this.states.includes(t)},e.prototype.getStates=function(){return this.states},e.prototype.getData=function(){return this.data},e.prototype.getModel=function(){return this.model},e.prototype.getBBox=function(){var t=this.shape,e=this.labelShape,n={x:0,y:0,minX:0,minY:0,maxX:0,maxY:0,width:0,height:0};return t&&(n=t.getCanvasBBox()),e&&e.forEach((function(t){var e=t.getCanvasBBox();n.x=Math.min(e.x,n.x),n.y=Math.min(e.y,n.y),n.minX=Math.min(e.minX,n.minX),n.minY=Math.min(e.minY,n.minY),n.maxX=Math.max(e.maxX,n.maxX),n.maxY=Math.max(e.maxY,n.maxY)})),n.width=n.maxX-n.minX,n.height=n.maxY-n.minY,n},e.prototype.getStatesStyle=function(){if(!this.statesStyle){var t=this.shapeType,e=this.geometry,n=this.shapeFactory,i=e.stateOption,r=n.defaultShapeType,o=n.theme[t]||n.theme[r];this.statesStyle=Object(s.deepMix)({},o,i)}return this.statesStyle},e.prototype.getStateStyle=function(t,e){var n=this.getStatesStyle(),i=Object(s.get)(n,[t,"style"],{}),r=i[e]||i;return Object(s.isFunction)(r)?r(this):r},e.prototype.getAnimateCfg=function(t){var e=this,n=this.animate;if(n){var i=n[t];return i?Object(a.__assign)(Object(a.__assign)({},i),{callback:function(){var t;Object(s.isFunction)(i.callback)&&i.callback(),null===(t=e.geometry)||void 0===t||t.emit(l.AFTER_DRAW_ANIMATE)}}):i}return null},e.prototype.drawShape=function(t,e){var n;void 0===e&&(e=!1);var i=this.shapeFactory,r=this.container,o=this.shapeType;if(this.shape=i.drawShape(o,t,r),this.shape){this.setShapeInfo(this.shape,t);var c=this.shape.cfg.name;c?Object(s.isString)(c)&&(this.shape.cfg.name=["element",c]):this.shape.cfg.name=["element",this.shapeFactory.geometryType];var u=e?"enter":"appear",h=this.getAnimateCfg(u);h&&(null===(n=this.geometry)||void 0===n||n.emit(l.BEFORE_DRAW_ANIMATE),wn(this.shape,h,{coordinate:i.coordinate,toAttrs:Object(a.__assign)({},this.shape.attr())}))}},e.prototype.getOffscreenGroup=function(){if(!this.offscreenGroup){var t=this.container.getGroupBase();this.offscreenGroup=new t({})}return this.offscreenGroup},e.prototype.setShapeInfo=function(t,e){var n=this;(t.cfg.origin=e,t.cfg.element=this,t.isGroup())&&t.get("children").forEach((function(t){n.setShapeInfo(t,e)}))},e.prototype.syncShapeStyle=function(t,e,n,i,r){var o,a=this;if(void 0===n&&(n=[]),void 0===r&&(r=0),t&&e){var c=t.get("clipShape"),u=e.get("clipShape");if(this.syncShapeStyle(c,u,n,i),t.isGroup())for(var h=t.get("children"),f=e.get("children"),p=0;p=0?e:n<=0?n:0},e.prototype.createAttrOption=function(t,e,n){if(Object(s.isNil)(e)||Object(s.isObject)(e))Object(s.isObject)(e)&&Object(s.isEqual)(Object.keys(e),["values"])?Object(s.set)(this.attributeOption,t,{fields:e.values}):Object(s.set)(this.attributeOption,t,e);else{var i={};Object(s.isNumber)(e)?i.values=[e]:i.fields=Rn(e),n&&(Object(s.isFunction)(n)?i.callback=n:i.values=n),Object(s.set)(this.attributeOption,t,i)}},e.prototype.initAttributes=function(){var t=this,e=this.attributes,n=this.attributeOption,i=this.theme,r=this.shapeType;this.groupScales=[];var o={},c=function(c){if(n.hasOwnProperty(c)){var l=n[c];if(!l)return{value:void 0};var u=Object(a.__assign)({},l),h=u.callback,f=u.values,p=u.fields,d=(void 0===p?[]:p).map((function(e){var n=t.scales[e];!o[e]&&g.includes(c)&&("cat"===mt(n,Object(s.get)(t.scaleDefs,e),c,t.type)&&(t.groupScales.push(n),o[e]=!0));return n}));u.scales=d,"position"!==c&&1===d.length&&"identity"===d[0].type?u.values=d[0].values:h||f||("size"===c?u.values=i.sizes:"shape"===c?u.values=i.shapes[r]||[]:"color"===c&&(d.length?u.values=d[0].values.length<=10?i.colors10:i.colors20:u.values=i.colors10));var y=B(c);e[c]=new y(u)}};for(var l in n){var u=c(l);if("object"===Vn(u))return u.value}},e.prototype.processData=function(t){this.hasSorted=!1;for(var e=this.getAttribute("position").scales.filter((function(t){return t.isCategory})),n=this.groupData(t),i=[],r=0,o=n.length;ro&&(o=u)}var h=this.scaleDefs,f={};rt.max&&!Object(s.get)(h,[i,"max"])&&(f.max=o),t.change(f)},e.prototype.beforeMapping=function(t){var e=t;if(this.sortable&&this.sort(e),this.generatePoints)for(var n=0,i=e.length;n1)for(var h=0;h0}))}var qn=function(){function t(t){this.shapesMap={},this.lastShapesMap={};var e=t.layout,n=t.container;this.layout=e,this.container=n}return t.prototype.render=function(t,e,n){var i=this;void 0===n&&(n=!1),this.shapesMap={};var r=this.container,o=this.createOffscreenGroup();if(t.length){for(var c=0,l=t;c=e.getCount()&&(t.destroyed||e.add(t))}))}(p,f[e],{data:o,origin:c,animateCfg:u,coordinate:l}),i.shapesMap[e]=p}else{r.add(t);var d=Object(s.get)(t.get("animateCfg"),n?"enter":"appear");d&&wn(t,d,{toAttrs:Object(a.__assign)({},t.attr()),coordinate:t.get("coordinate")})}delete h[e]}})),Object(s.each)(h,(function(t){var e=Object(s.get)(t.get("animateCfg"),"leave");e?wn(t,e,{toAttrs:null,coordinate:t.get("coordinate")}):t.remove(!0)})),this.lastShapesMap=f,o.destroy()},t.prototype.clear=function(){this.container.clear(),this.shapesMap={},this.lastShapesMap={}},t.prototype.destroy=function(){this.container.destroy(),this.shapesMap=null,this.lastShapesMap=null},t.prototype.renderLabel=function(t,e){var n,i=t.id,r=t.elementId,o=t.data,c=t.mappingData,l=t.coordinate,u=t.animate,h=t.content,f={id:i,elementId:r,data:o,origin:Object(a.__assign)(Object(a.__assign)({},c),{data:c._origin}),coordinate:l},p=e.addGroup(Object(a.__assign)({name:"label",animateCfg:!1!==this.animate&&null!==u&&!1!==u&&Object(s.deepMix)({},this.animate,u)},f));if(h.isGroup&&h.isGroup()||h.isShape&&h.isShape()){var d=h.getCanvasBBox(),g=d.width,y=d.height,v=Object(s.get)(t,"textAlign","left"),m=t.x;"center"===v?m-=g/2:"right"!==v&&"end"!==v||(m-=g),Yn(h,m,t.y-y/2),n=h,p.add(h)}else{var x=Object(s.get)(t,["style","fill"]);n=p.addShape("text",Object(a.__assign)({attrs:Object(a.__assign)(Object(a.__assign)({x:t.x,y:t.y,textAlign:t.textAlign,textBaseline:Object(s.get)(t,"textBaseline","middle"),text:t.content},t.style),{fill:Object(s.isNull)(x)?t.color:x})},f))}t.rotate&&Xn(n,t.rotate),this.shapesMap[i]=p},t.prototype.doLayout=function(t,e){var n=this;if(this.layout){var i=Object(s.isArray)(this.layout)?this.layout:[this.layout];Object(s.each)(i,(function(i){var r=En(Object(s.get)(i,"type",""));if(r){var o=[],a=[];Object(s.each)(n.shapesMap,(function(t,n){o.push(t),a.push(e[t.get("elementId")])})),r(t,o,a,n.region,i.cfg)}}))}},t.prototype.renderLabelLine=function(t){var e=this;Object(s.each)(t,(function(t){var n=Object(s.get)(t,"coordinate");if(t&&n){var i=n.getCenter(),r=n.getRadius();if(t.labelLine){var o=Object(s.get)(t,"labelLine",{}),c=t.id,l=o.path;if(!l){var u=nt(i.x,i.y,r,t.angle);l=[["M",u.x,u.y],["L",t.x,t.y]]}var h=e.shapesMap[c];h.destroyed||h.addShape("path",{capture:!1,attrs:Object(a.__assign)({path:l,stroke:t.color?t.color:Object(s.get)(t,["style","fill"],"#000"),fill:null},o.style),id:c,origin:t.mappingData,data:t.data,coordinate:t.coordinate})}}}))},t.prototype.renderLabelBackground=function(t){var e=this;Object(s.each)(t,(function(t){var n=Object(s.get)(t,"coordinate"),i=Object(s.get)(t,"background");if(i&&n){var r=t.id,o=e.shapesMap[r];if(!o.destroyed){var c=o.getChildren()[0];if(c){var l=Hn(o,t,i.padding),u=l.rotation,h=Object(a.__rest)(l,["rotation"]),f=o.addShape("rect",{attrs:Object(a.__assign)(Object(a.__assign)({},h),i.style||{}),id:r,origin:t.mappingData,data:t.data,coordinate:t.coordinate});if(f.setZIndex(-1),u){var p=c.getMatrix();f.setMatrix(p)}}}}}))},t.prototype.createOffscreenGroup=function(){return new(this.container.getGroupBase())({})},t.prototype.adjustLabel=function(t){var e=this;Object(s.each)(t,(function(t){if(t){var n=t.id,i=e.shapesMap[n];if(!i.destroyed){var r=i.findAll((function(t){return"path"!==t.get("type")}));Object(s.each)(r,(function(e){e&&(t.offsetX&&e.attr("x",e.attr("x")+t.offsetX),t.offsetY&&e.attr("y",e.attr("y")+t.offsetY))}))}}}))},t}();function Zn(t){var e=0;return Object(s.each)(t,(function(t){e+=t})),e/t.length}var $n=function(){function t(t){this.geometry=t}return t.prototype.getLabelItems=function(t){var e=this,n=[],i=this.getLabelCfgs(t);return Object(s.each)(t,(function(t,r){var o=i[r];if(!o||Object(s.isNil)(t.x)||Object(s.isNil)(t.y))n.push(null);else{var c=Object(s.isArray)(o.content)?o.content:[o.content];o.content=c;var l=c.length;Object(s.each)(c,(function(i,r){if(Object(s.isNil)(i)||""===i)n.push(null);else{var c=Object(a.__assign)(Object(a.__assign)({},o),e.getLabelPoint(o,t,r));c.textAlign||(c.textAlign=e.getLabelAlign(c,r,l)),c.offset<=0&&(c.labelLine=null),n.push(c)}}))}})),n},t.prototype.render=function(t,e){void 0===e&&(e=!1);var n=this.getLabelItems(t),i=this.getLabelsRenderer(),r=this.getGeometryShapes();i.render(n,r,e)},t.prototype.clear=function(){var t=this.labelsRenderer;t&&t.clear()},t.prototype.destroy=function(){var t=this.labelsRenderer;t&&t.destroy(),this.labelsRenderer=null},t.prototype.getCoordinate=function(){return this.geometry.coordinate},t.prototype.getDefaultLabelCfg=function(t,e){var n=this.geometry,i=n.type,r=n.theme;return"polygon"===i||"interval"===i&&"middle"===e||t<0&&!["line","point","path"].includes(i)?Object(s.get)(r,"innerLabels",{}):Object(s.get)(r,"labels",{})},t.prototype.getThemedLabelCfg=function(t){var e=this.geometry,n=this.getDefaultLabelCfg(),i=e.type,r=e.theme;return"polygon"===i||t.offset<0&&!["line","point","path"].includes(i)?Object(s.deepMix)({},n,r.innerLabels,t):Object(s.deepMix)({},n,r.labels,t)},t.prototype.setLabelPosition=function(t,e,n,i){},t.prototype.getLabelOffset=function(t){var e=this.getCoordinate(),n=this.getOffsetVector(t);return e.isTransposed?n[0]:n[1]},t.prototype.getLabelOffsetPoint=function(t,e,n){var i=t.offset,r=this.getCoordinate().isTransposed,o=r?"x":"y",a=r?1:-1,s={x:0,y:0};return s[o]=e>0||1===n?i*a:i*a*-1,s},t.prototype.getLabelPoint=function(t,e,n){var i=this.getCoordinate(),r=t.content.length;function o(e,n,i){void 0===i&&(i=!1);var r=e;return Object(s.isArray)(r)&&(r=1===t.content.length?i?Zn(r):r.length<=2?r[e.length-1]:Zn(r):r[n]),r}var a={content:t.content[n],x:0,y:0,start:{x:0,y:0},color:"#fff"},c=Object(s.isArray)(e.shape)?e.shape[0]:e.shape,l="funnel"===c||"pyramid"===c;if("polygon"===this.geometry.type){var u=function(t,e){if(Object(s.isNumber)(t)&&Object(s.isNumber)(e))return[t,e];if(e=e,tt(t=t)||tt(e))return[et(t),et(e)];for(var n,i,r=-1,o=0,a=0,c=t.length-1,l=0;++r1&&0===e&&("right"===i?i="left":"left"===i&&(i="right"))}return i},t.prototype.getLabelId=function(t){var e=this.geometry,n=e.type,i=e.getXScale(),r=e.getYScale(),o=t._origin,a=e.getElementId(t);return"line"===n||"area"===n?a+=" ".concat(o[i.field]):"path"===n&&(a+=" ".concat(o[i.field],"-").concat(o[r.field])),a},t.prototype.getLabelsRenderer=function(){var t=this.geometry,e=t.labelsContainer,n=t.labelOption,i=t.canvasRegion,r=t.animateOption,o=this.geometry.coordinate,a=this.labelsRenderer;return a||(a=new qn({container:e,layout:Object(s.get)(n,["cfg","layout"],{type:this.defaultLayout})}),this.labelsRenderer=a),a.region=i,a.animate=!!r&&_n("label",o),a},t.prototype.getLabelCfgs=function(t){var e=this,n=this.geometry,i=n.labelOption,r=n.scales,o=n.coordinate,c=i,l=c.fields,u=c.callback,h=c.cfg,f=l.map((function(t){return r[t]})),p=[];return Object(s.each)(t,(function(t,n){var i,r=t._origin,c=e.getLabelText(r,f);if(u){var d=l.map((function(t){return r[t]}));if(i=u.apply(void 0,d),Object(s.isNil)(i))return void p.push(null)}var g=Object(a.__assign)(Object(a.__assign)({id:e.getLabelId(t),elementId:e.geometry.getElementId(t),data:r,mappingData:t,coordinate:o},h),i);Object(s.isFunction)(g.position)&&(g.position=g.position(r,t,n));var y=e.getLabelOffset(g.offset||0),v=e.getDefaultLabelCfg(y,g.position);(g=Object(s.deepMix)({},v,g)).offset=e.getLabelOffset(g.offset||0);var m=g.content;Object(s.isFunction)(m)?g.content=m(r,t,n):Object(s.isUndefined)(m)&&(g.content=c[0]),p.push(g)})),p},t.prototype.getLabelText=function(t,e){var n=[];return Object(s.each)(e,(function(e){var i=t[e.field];i=Object(s.isArray)(i)?i.map((function(t){return e.getText(t)})):e.getText(i),Object(s.isNil)(i)||""===i?n.push(null):n.push(i)})),n},t.prototype.getOffsetVector=function(t){void 0===t&&(t=0);var e=this.getCoordinate(),n=0;return Object(s.isNumber)(t)&&(n=t),e.isTransposed?e.applyMatrix(n,0):e.applyMatrix(0,n)},t.prototype.getGeometryShapes=function(){var t=this.geometry,e={};return Object(s.each)(t.elementsMap,(function(t,n){e[n]=t.shape})),Object(s.each)(t.getOffscreenGroup().getChildren(),(function(n){var i=t.getElementId(n.get("origin").mappingData);e[i]=n})),e},t}();function Kn(t,e,n){if(!t)return n;var i;if(t.callback&&t.callback.length>1){var r=Array(t.callback.length-1).fill("");i=t.mapping.apply(t,Object(a.__spreadArray)([e],r,!1)).join("")}else i=t.mapping(e).join("");return i||n}var Qn={hexagon:function(t,e,n){var i=n/2*Math.sqrt(3);return[["M",t,e-n],["L",t+i,e-n/2],["L",t+i,e+n/2],["L",t,e+n],["L",t-i,e+n/2],["L",t-i,e-n/2],["Z"]]},bowtie:function(t,e,n){var i=n-1.5;return[["M",t-n,e-i],["L",t+n,e+i],["L",t+n,e-i],["L",t-n,e+i],["Z"]]},cross:function(t,e,n){return[["M",t-n,e-n],["L",t+n,e+n],["M",t+n,e-n],["L",t-n,e+n]]},tick:function(t,e,n){return[["M",t-n/2,e-n],["L",t+n/2,e-n],["M",t,e-n],["L",t,e+n],["M",t-n/2,e+n],["L",t+n/2,e+n]]},plus:function(t,e,n){return[["M",t-n,e],["L",t+n,e],["M",t,e-n],["L",t,e+n]]},hyphen:function(t,e,n){return[["M",t-n,e],["L",t+n,e]]},line:function(t,e,n){return[["M",t,e-n],["L",t,e+n]]}},Jn=["line","cross","tick","plus","hyphen"];function ti(t){var e=t.symbol;Object(s.isString)(e)&&Qn[e]&&(t.symbol=Qn[e])}function ei(t){return t.startsWith(r.LEFT)||t.startsWith(r.RIGHT)?"vertical":"horizontal"}function ni(t,e,n,i,r){var o=n.getScale(n.type);if(o.isCategory){var c=o.field,l=e.getAttribute("color"),u=e.getAttribute("shape"),h=t.getTheme().defaultColor,f=e.coordinate.isPolar;return o.getTicks().map((function(n,p){var d,g=n.text,y=n.value,v=g,m=o.invert(y),x=0===t.filterFieldData(c,[(d={},d[c]=m,d)]).length;Object(s.each)(t.views,(function(t){var e;t.filterFieldData(c,[(e={},e[c]=m,e)]).length||(x=!0)}));var b,O,_=Kn(l,m,h),w=Kn(u,m,"point"),j=e.getShapeMarker(w,{color:_,isInPolar:f}),S=r;return Object(s.isFunction)(S)&&(S=S(v,p,Object(a.__assign)({name:v,value:m},Object(s.deepMix)({},i,j)))),function(t,e){var n=t.symbol;if(Object(s.isString)(n)&&-1!==Jn.indexOf(n)){var i=Object(s.get)(t,"style",{}),r=Object(s.get)(i,"lineWidth",1),o=i.stroke||i.fill||e;t.style=Object(s.deepMix)({},t.style,{lineWidth:r,stroke:o,fill:null})}}(j=Object(s.deepMix)({},i,j,lt(Object(a.__assign)({},S),["style"])),_),S&&S.style&&(j.style=(b=j.style,O=S.style,Object(s.isFunction)(O)?O(b):Object(s.deepMix)({},b,O))),ti(j),{id:m,name:v,value:m,marker:j,unchecked:x}}))}return[]}function ii(t,e){var n=Object(s.get)(t,["components","legend"],{});return Object(s.deepMix)({},Object(s.get)(n,["common"],{}),Object(s.deepMix)({},Object(s.get)(n,[e],{})))}function ri(t){return!t&&(null==t||isNaN(t))}function oi(t){if(Object(s.isArray)(t))return ri(t[1].y);var e=t.y;return Object(s.isArray)(e)?ri(e[0]):ri(e)}function ai(t,e,n){if(void 0===e&&(e=!1),void 0===n&&(n=!0),!t.length||1===t.length&&!n)return[];if(e){for(var i=[],r=0,o=t.length;r0&&(l[0][0]="L")),o=o.concat(l)})),o.push(["Z"])}return o}function Li(t,e,n,i,r){for(var o=li(t,e,!e,"lineWidth"),a=t.connectNulls,s=t.isInCircle,c=ai(t.points,a,t.showSinglePoint),l=[],u=0,h=c.length;ui&&(i=r),r=e[0]})));for(var h=this.scales[l],f=0,p=t;fe&&(i=e-(n=n?e/(1+i/n):0)),r+o>e&&(o=e-(r=r?e/(1+o/r):0)),[n||0,i||0,r||0,o||0]}function Gi(t,e,n){var i=[];if(n.isRect){var r=n.isTransposed?{x:n.start.x,y:e[0].y}:{x:e[0].x,y:n.start.y},o=n.isTransposed?{x:n.end.x,y:e[2].y}:{x:e[3].x,y:n.end.y},a=Object(s.get)(t,["background","style","radius"]);if(a){var c=n.isTransposed?Math.abs(e[0].y-e[2].y):e[2].x-e[1].x,l=n.isTransposed?n.getWidth():n.getHeight(),u=zi(a,Math.min(c,l)),h=u[0],f=u[1],p=u[2],d=u[3];i.push(["M",r.x,o.y+h]),0!==h&&i.push(["A",h,h,0,0,1,r.x+h,o.y]),i.push(["L",o.x-f,o.y]),0!==f&&i.push(["A",f,f,0,0,1,o.x,o.y+f]),i.push(["L",o.x,r.y-p]),0!==p&&i.push(["A",p,p,0,0,1,o.x-p,r.y]),i.push(["L",r.x+d,r.y]),0!==d&&i.push(["A",d,d,0,0,1,r.x,r.y-d])}else i.push(["M",r.x,r.y]),i.push(["L",o.x,r.y]),i.push(["L",o.x,o.y]),i.push(["L",r.x,o.y]),i.push(["L",r.x,r.y]);i.push(["z"])}if(n.isPolar){var g=n.getCenter(),y=ot(t,n),v=y.startAngle,m=y.endAngle;if("theta"===n.type||n.isTransposed){var x=function(t){return Math.pow(t,2)};h=Math.sqrt(x(g.x-e[0].x)+x(g.y-e[0].y)),f=Math.sqrt(x(g.x-e[2].x)+x(g.y-e[2].y));i=it(g.x,g.y,h,n.startAngle,n.endAngle,f)}else i=it(g.x,g.y,n.getRadius(),v,m)}return i}function Yi(t,e,n){var i=[];return Object(s.isNil)(e)?n?i.push(["M",t[0].x,t[0].y],["L",t[1].x,t[1].y],["L",(t[2].x+t[3].x)/2,(t[2].y+t[3].y)/2],["Z"]):i.push(["M",t[0].x,t[0].y],["L",t[1].x,t[1].y],["L",t[2].x,t[2].y],["L",t[3].x,t[3].y],["Z"]):i.push(["M",t[0].x,t[0].y],["L",t[1].x,t[1].y],["L",e[1].x,e[1].y],["L",e[0].x,e[0].y],["Z"]),i}function Xi(t,e){return[e,t]}Ln("interval",{defaultShapeType:"rect",getDefaultPoints:function(t){return Ni(t)}});kn("interval","rect",{draw:function(t,e){var n,i=li(t,!1,!0),r=e,o=null==t?void 0:t.background;if(o){r=e.addGroup();var s=ui(t),c=Gi(t,this.parsePoints(t.points),this.coordinate);r.addShape("path",{attrs:Object(a.__assign)(Object(a.__assign)({},s),{path:c}),zIndex:-1,name:"element-background"})}n=i.radius&&this.coordinate.isRect?function(t,e,n){var i,r,o,s,c,l,u,h=Object(a.__spreadArray)([],t,!0),f=h[0],p=h[1],d=h[2],g=h[3],y="number"==typeof n?Array(4).fill(n):n,v=y[0],m=y[1],x=y[2],b=y[3];e.isTransposed&&(p=(i=Xi(p,g))[0],g=i[1],v=(r=[b,v,m,x])[0],m=r[1],x=r[2],b=r[3]),e.isReflect("y")&&(f=(o=Xi(f,p))[0],p=o[1],d=(s=Xi(d,g))[0],g=s[1]),e.isReflect("x")&&(f=(c=Xi(f,g))[0],g=c[1],p=(l=Xi(p,d))[0],d=l[1]);var O=[],_=function(t){return Math.abs(t)};return v=(u=zi([v,m,x,b],Math.min(_(g.x-f.x),_(p.y-f.y))).map((function(t){return _(t)})))[0],m=u[1],x=u[2],b=u[3],f.y1){r.sort();var y=function(t,e){var n=t.length,i=t;Object(s.isString)(i[0])&&(i=t.map((function(t){return e.translate(t)})));for(var r=i[1]-i[0],o=2;oa&&(r=a)}return r}(r,i);a=(i.max-i.min)/y,r.length>a&&(a=r.length)}var v=i.range,m=1/a,x=1;(n.isPolar?x=n.isTransposed&&a>1?d:g:(i.isLinear&&(m*=v[1]-v[0]),x=p),!Object(s.isNil)(l)&&l>=0)?m=(1-(a-1)*(l/c))/a:m*=x;if(t.getAdjust("dodge")){var b=function(t,e){if(e){var n=Object(s.flatten)(t);return Object(s.valuesOfKey)(n,e).length}return t.length}(o,t.getAdjust("dodge").dodgeBy);if(!Object(s.isNil)(u)&&u>=0)m=(m-u/c*(b-1))/b;else!Object(s.isNil)(l)&&l>=0?(m*=x,m/=b):m/=b;m=m>=0?m:0}if(!Object(s.isNil)(h)&&h>=0){var O=h/c;m>O&&(m=O)}if(!Object(s.isNil)(f)&&f>=0){var _=f/c;m<_&&(m=_)}return m}var Hi=function(t){function e(e){var n=t.call(this,e)||this;n.type="interval",n.shapeType="interval",n.generatePoints=!0;var i=e.background;return n.background=i,n}return Object(a.__extends)(e,t),e.prototype.createShapePointsCfg=function(e){var n,i=t.prototype.createShapePointsCfg.call(this,e),r=this.getAttribute("size");r?(n=this.getAttributeValues(r,e)[0],n/=ft(this.coordinate)):(this.defaultSize||(this.defaultSize=Wi(this)),n=this.defaultSize);return i.size=n,i},e.prototype.adjustScale=function(){t.prototype.adjustScale.call(this);var e,n,i=this.getYScale();if("theta"===this.coordinate.type)i.change({nice:!1,min:0,max:(e=i,n=e.values.filter((function(t){return!Object(s.isNil)(t)&&!isNaN(t)})),Math.max.apply(Math,Object(a.__spreadArray)(Object(a.__spreadArray)([],n,!1),[Object(s.isNil)(e.max)?-1/0:e.max],!1)))});else{var r=this.scaleDefs,o=i.field,c=i.min,l=i.max;"time"!==i.type&&(c>0&&!Object(s.get)(r,[o,"min"])&&i.change({min:0}),l<=0&&!Object(s.get)(r,[o,"max"])&&i.change({max:0}))}},e.prototype.getDrawCfg=function(e){var n=t.prototype.getDrawCfg.call(this,e);return n.background=this.background,n},e}(zn),Ui=function(t){function e(e){var n=t.call(this,e)||this;n.type="line";var i=e.sortable,r=void 0!==i&&i;return n.sortable=r,n}return Object(a.__extends)(e,t),e}(Fi),qi=["circle","square","bowtie","diamond","hexagon","triangle","triangle-down"];function Zi(t,e,n,i,r){var o=li(e,r,!r,"r"),s=t.parsePoints(e.points),c=s[0];if(e.isStack)c=s[1];else if(s.length>1){for(var l=n.addGroup(),u=0,h=s;u2?"weight":"normal";if(t.isInCircle){var s={x:0,y:1};return"normal"===o?n=function(t,e,n){var i=er(e,n),r=[["M",t.x,t.y]];return r.push(i),r}(r[0],r[1],s):(i.fill=i.stroke,n=function(t,e){var n=er(t[1],e),i=er(t[3],e),r=[["M",t[0].x,t[0].y]];return r.push(i),r.push(["L",t[3].x,t[3].y]),r.push(["L",t[2].x,t[2].y]),r.push(n),r.push(["L",t[1].x,t[1].y]),r.push(["L",t[0].x,t[0].y]),r.push(["Z"]),r}(r,s)),n=this.parsePath(n),e.addShape("path",{attrs:Object(a.__assign)(Object(a.__assign)({},i),{path:n})})}if("normal"===o)return n=rt(((r=this.parsePoints(r))[1].x+r[0].x)/2,r[0].y,Math.abs(r[1].x-r[0].x)/2,Math.PI,2*Math.PI),e.addShape("path",{attrs:Object(a.__assign)(Object(a.__assign)({},i),{path:n})});var c=tr(r[1],r[3]),l=tr(r[2],r[0]);return n=[["M",r[0].x,r[0].y],["L",r[1].x,r[1].y],c,["L",r[3].x,r[3].y],["L",r[2].x,r[2].y],l,["Z"]],n=this.parsePath(n),i.fill=i.stroke,e.addShape("path",{attrs:Object(a.__assign)(Object(a.__assign)({},i),{path:n})})},getMarker:function(t){return{symbol:"circle",style:{r:4.5,fill:t.color}}}}),kn("edge","smooth",{draw:function(t,e){var n=li(t,!0,!1,"lineWidth"),i=t.points,r=this.parsePath(function(t,e){var n=tr(t,e),i=[["M",t.x,t.y]];return i.push(n),i}(i[0],i[1]));return e.addShape("path",{attrs:Object(a.__assign)(Object(a.__assign)({},n),{path:r})})},getMarker:function(t){return{symbol:"circle",style:{r:4.5,fill:t.color}}}});kn("edge","vhv",{draw:function(t,e){var n=li(t,!0,!1,"lineWidth"),i=t.points,r=this.parsePath(function(t,e){var n=[];n.push({x:t.x,y:t.y*(1-1/3)+e.y*(1/3)}),n.push({x:e.x,y:t.y*(1-1/3)+e.y*(1/3)}),n.push(e);var i=[["M",t.x,t.y]];return Object(s.each)(n,(function(t){i.push(["L",t.x,t.y])})),i}(i[0],i[1]));return e.addShape("path",{attrs:Object(a.__assign)(Object(a.__assign)({},n),{path:r})})},getMarker:function(t){return{symbol:"circle",style:{r:4.5,fill:t.color}}}}),kn("interval","funnel",{getPoints:function(t){return t.size=2*t.size,Ni(t)},draw:function(t,e){var n=li(t,!1,!0),i=this.parsePath(Yi(t.points,t.nextPoints,!1));return e.addShape("path",{attrs:Object(a.__assign)(Object(a.__assign)({},n),{path:i}),name:"interval"})},getMarker:function(t){return{symbol:"square",style:{r:4,fill:t.color}}}}),kn("interval","hollow-rect",{draw:function(t,e){var n=li(t,!0,!1),i=e,r=null==t?void 0:t.background;if(r){i=e.addGroup();var o=ui(t),s=Gi(t,this.parsePoints(t.points),this.coordinate);i.addShape("path",{attrs:Object(a.__assign)(Object(a.__assign)({},o),{path:s}),zIndex:-1,name:"element-background"})}var c=this.parsePath(Vi(t.points)),l=i.addShape("path",{attrs:Object(a.__assign)(Object(a.__assign)({},n),{path:c}),name:"interval"});return r?i:l},getMarker:function(t){var e=t.color;return t.isInPolar?{symbol:"circle",style:{r:4.5,stroke:e,fill:null}}:{symbol:"square",style:{r:4,stroke:e,fill:null}}}}),kn("interval","line",{getPoints:function(t){return n=(e=t).x,i=e.y,r=e.y0,Object(s.isArray)(i)?i.map((function(t,e){return{x:Object(s.isArray)(n)?n[e]:n,y:t}})):[{x:n,y:r},{x:n,y:i}];var e,n,i,r},draw:function(t,e){var n=li(t,!0,!1,"lineWidth"),i=lt(Object(a.__assign)({},n),["fill"]),r=this.parsePath(Vi(t.points,!1));return e.addShape("path",{attrs:Object(a.__assign)(Object(a.__assign)({},i),{path:r}),name:"interval"})},getMarker:function(t){return{symbol:function(t,e,n){return[["M",t,e-n],["L",t,e+n]]},style:{r:5,stroke:t.color}}}}),kn("interval","pyramid",{getPoints:function(t){return t.size=2*t.size,Ni(t)},draw:function(t,e){var n=li(t,!1,!0),i=this.parsePath(Yi(t.points,t.nextPoints,!0));return e.addShape("path",{attrs:Object(a.__assign)(Object(a.__assign)({},n),{path:i}),name:"interval"})},getMarker:function(t){return{symbol:"square",style:{r:4,fill:t.color}}}}),kn("interval","tick",{getPoints:function(t){return function(t){var e,n,i=t.x,r=t.y,o=t.y0,a=t.size;Object(s.isArray)(r)?(e=r[0],n=r[1]):(e=o,n=r);var c=i+a/2,l=i-a/2;return[{x:i,y:e},{x:i,y:n},{x:l,y:e},{x:c,y:e},{x:l,y:n},{x:c,y:n}]}(t)},draw:function(t,e){var n,i=li(t,!0,!1),r=this.parsePath([["M",(n=t.points)[0].x,n[0].y],["L",n[1].x,n[1].y],["M",n[2].x,n[2].y],["L",n[3].x,n[3].y],["M",n[4].x,n[4].y],["L",n[5].x,n[5].y]]);return e.addShape("path",{attrs:Object(a.__assign)(Object(a.__assign)({},i),{path:r}),name:"interval"})},getMarker:function(t){return{symbol:function(t,e,n){return[["M",t-n/2,e-n],["L",t+n/2,e-n],["M",t,e-n],["L",t,e+n],["M",t-n/2,e+n],["L",t+n/2,e+n]]},style:{r:5,stroke:t.color}}}});function nr(t,e){var n=ai(t.points,t.connectNulls,t.showSinglePoint),i=[];return Object(s.each)(n,(function(t){var n=function(t,e){var n=[];return Object(s.each)(t,(function(i,r){var o=t[r+1];if(n.push(i),o){var a=function(t,e,n){var i,r=t.x,o=t.y,a=e.x,s=e.y;switch(n){case"hv":i=[{x:a,y:o}];break;case"vh":i=[{x:r,y:s}];break;case"hvh":var c=(a+r)/2;i=[{x:c,y:o},{x:c,y:s}];break;case"vhv":var l=(o+s)/2;i=[{x:r,y:l},{x:a,y:l}]}return i}(i,o,e);n=n.concat(a)}})),n}(t,e);i=i.concat(function(t){return t.map((function(t,e){return 0===e?["M",t.x,t.y]:["L",t.x,t.y]}))}(n))})),Object(a.__assign)(Object(a.__assign)({},li(t,!0,!1,"lineWidth")),{path:i})}function ir(t){var e=Object(s.isArray)(t)?t:[t],n=e[0],i=e[e.length-1],r=e.length>1?e[1]:n;return{min:n,max:i,min1:r,max1:e.length>3?e[3]:i,median:e.length>2?e[2]:r}}function rr(t,e,n){var i,r=n/2;if(Object(s.isArray)(e)){var o=ir(e),a=o.min,c=o.max,l=o.median,u=o.min1,h=t-r,f=t+r;i=[[h,c],[f,c],[t,c],[t,p=o.max1],[h,u],[h,p],[f,p],[f,u],[t,u],[t,a],[h,a],[f,a],[h,l],[f,l]]}else{e=Object(s.isNil)(e)?.5:e;var p,d=ir(t),g=(a=d.min,c=d.max,l=d.median,e-r),y=e+r;i=[[a,g],[a,y],[a,e],[u=d.min1,e],[u,g],[u,y],[p=d.max1,y],[p,g],[p,e],[c,e],[c,g],[c,y],[l,g],[l,y]]}return i.map((function(t){return{x:t[0],y:t[1]}}))}function or(t){var e=(Object(s.isArray)(t)?t:[t]).sort((function(t,e){return e-t}));return function(t,e,n){if(Object(s.isString)(t))return t.padEnd(e,n);if(Object(s.isArray)(t)){var i=t.length;if(i1){for(var o=e.addGroup(),a=0,s=i;a0?"left":"right");break;case"left":t.x=c,t.y=(r+a)/2,t.textAlign=Object(s.get)(t,"textAlign",d>0?"left":"right");break;case"bottom":u&&(t.x=(o+c)/2),t.y=a,t.textAlign=Object(s.get)(t,"textAlign","center"),t.textBaseline=Object(s.get)(t,"textBaseline",d>0?"bottom":"top");break;case"middle":u&&(t.x=(o+c)/2),t.y=(r+a)/2,t.textAlign=Object(s.get)(t,"textAlign","center"),t.textBaseline=Object(s.get)(t,"textBaseline","middle");break;case"top":u&&(t.x=(o+c)/2),t.y=r,t.textAlign=Object(s.get)(t,"textAlign","center"),t.textBaseline=Object(s.get)(t,"textBaseline",d>0?"bottom":"top")}},e}($n),lr=Math.PI/2,ur=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(a.__extends)(e,t),e.prototype.getLabelOffset=function(t){var e=this.getCoordinate(),n=0;if(Object(s.isNumber)(t))n=t;else if(Object(s.isString)(t)&&-1!==t.indexOf("%")){var i=e.getRadius();e.innerRadius>0&&(i*=1-e.innerRadius),n=.01*parseFloat(t)*i}return n},e.prototype.getLabelItems=function(e){var n=t.prototype.getLabelItems.call(this,e),i=this.geometry.getYScale();return Object(s.map)(n,(function(t){if(t&&i){var e=i.scale(Object(s.get)(t.data,i.field));return Object(a.__assign)(Object(a.__assign)({},t),{percent:e})}return t}))},e.prototype.getLabelAlign=function(t){var e,n=this.getCoordinate();if(t.labelEmit)e=t.angle<=Math.PI/2&&t.angle>=-Math.PI/2?"left":"right";else if(n.isTransposed){var i=n.getCenter(),r=t.offset;e=Math.abs(t.x-i.x)<1?"center":t.angle>Math.PI||t.angle<=0?r>0?"left":"right":r>0?"right":"left"}else e="center";return e},e.prototype.getLabelPoint=function(t,e,n){var i,r=1,o=t.content[n];this.isToMiddle(e)?i=this.getMiddlePoint(e.points):(1===t.content.length&&0===n?n=1:0===n&&(r=-1),i=this.getArcPoint(e,n));var a=t.offset*r,s=this.getPointAngle(i),c=t.labelEmit,l=this.getCirclePoint(s,a,i,c);return 0===l.r?l.content="":(l.content=o,l.angle=s,l.color=e.color),l.rotate=t.autoRotate?this.getLabelRotate(s,a,c):t.rotate,l.start={x:i.x,y:i.y},l},e.prototype.getArcPoint=function(t,e){return void 0===e&&(e=0),Object(s.isArray)(t.x)||Object(s.isArray)(t.y)?{x:Object(s.isArray)(t.x)?t.x[e]:t.x,y:Object(s.isArray)(t.y)?t.y[e]:t.y}:{x:t.x,y:t.y}},e.prototype.getPointAngle=function(t){return gt(this.getCoordinate(),t)},e.prototype.getCirclePoint=function(t,e,n,i){var r=this.getCoordinate(),o=r.getCenter(),s=pt(r,n);if(0===s)return Object(a.__assign)(Object(a.__assign)({},o),{r:s});var c=t;r.isTransposed&&s>e&&!i?c=t+2*Math.asin(e/(2*s)):s+=e;return{x:o.x+s*Math.cos(c),y:o.y+s*Math.sin(c),r:s}},e.prototype.getLabelRotate=function(t,e,n){var i=t+lr;return n&&(i-=lr),i&&(i>lr?i-=Math.PI:i<-lr&&(i+=Math.PI)),i},e.prototype.getMiddlePoint=function(t){var e=this.getCoordinate(),n=t.length,i={x:0,y:0};return Object(s.each)(t,(function(t){i.x+=t.x,i.y+=t.y})),i.x/=n,i.y/=n,i=e.convert(i)},e.prototype.isToMiddle=function(t){return t.x.length>2},e}($n),hr=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.defaultLayout="distribute",e}return Object(a.__extends)(e,t),e.prototype.getDefaultLabelCfg=function(e,n){var i=t.prototype.getDefaultLabelCfg.call(this,e,n);return Object(s.deepMix)({},i,Object(s.get)(this.geometry.theme,"pieLabels",{}))},e.prototype.getLabelOffset=function(e){return t.prototype.getLabelOffset.call(this,e)||0},e.prototype.getLabelRotate=function(t,e,n){var i;return e<0&&((i=t)>Math.PI/2&&(i-=Math.PI),i<-Math.PI/2&&(i+=Math.PI)),i},e.prototype.getLabelAlign=function(t){var e,n=this.getCoordinate().getCenter();return e=t.angle<=Math.PI/2&&t.x>=n.x?"left":"right",t.offset<=0&&(e="right"===e?"left":"right"),e},e.prototype.getArcPoint=function(t){return t},e.prototype.getPointAngle=function(t){var e,n=this.getCoordinate(),i={x:Object(s.isArray)(t.x)?t.x[0]:t.x,y:t.y[0]},r={x:Object(s.isArray)(t.x)?t.x[1]:t.x,y:t.y[1]},o=gt(n,i);if(t.points&&t.points[0].y===t.points[1].y)e=o;else{var a=gt(n,r);o>=a&&(a+=2*Math.PI),e=o+(a-o)/2}return e},e.prototype.getCirclePoint=function(t,e){var n=this.getCoordinate(),i=n.getCenter(),r=n.getRadius()+e;return Object(a.__assign)(Object(a.__assign)({},nt(i.x,i.y,r,t)),{angle:t,r:r})},e}(ur);function fr(t,e,n){var i=t.filter((function(t){return!t.invisible}));i.sort((function(t,e){return t.y-e.y}));var r,o=!0,a=n.minY,s=n.maxY,c=Math.abs(a-s),l=0,u=Number.MIN_VALUE,h=i.map((function(t){return t.y>l&&(l=t.y),t.yc&&(c=l-a);o;)for(h.forEach((function(t){var e=(Math.min.apply(u,t.targets)+Math.max.apply(u,t.targets))/2;t.pos=Math.min(Math.max(u,e-t.size/2),c-t.size),t.pos=Math.max(0,t.pos)})),o=!1,r=h.length;r--;)if(r>0){var f=h[r-1],p=h[r];f.pos+f.size>p.pos&&(f.size+=p.size,f.targets=f.targets.concat(p.targets),f.pos+f.size>c&&(f.pos=c-f.size),h.splice(r,1),o=!0)}r=0,h.forEach((function(t){var n=a+e/2;t.targets.forEach((function(){i[r].y=t.pos+n,n+=e,r++}))}))}var pr=function(){function t(t){void 0===t&&(t={}),this.bitmap={};var e=t.xGap,n=void 0===e?1:e,i=t.yGap,r=void 0===i?8:i;this.xGap=n,this.yGap=r}return t.prototype.hasGap=function(t){for(var e=!0,n=this.bitmap,i=Math.round(t.minX),r=Math.round(t.maxX),o=Math.round(t.minY),a=Math.round(t.maxY),s=i;s<=r;s+=1)if(n[s]){if(s===i||s===r){for(var c=o;c<=a;c++)if(n[s][c]){e=!1;break}}else if(n[s][o]||n[s][a]){e=!1;break}}else n[s]={};return e},t.prototype.fillGap=function(t){for(var e=this.bitmap,n=Math.round(t.minX),i=Math.round(t.maxX),r=Math.round(t.minY),o=Math.round(t.maxY),a=n;a<=i;a+=1)e[a]||(e[a]={});for(a=n;a<=i;a+=this.xGap){for(var s=r;s<=o;s+=this.yGap)e[a][s]=!0;e[a][o]=!0}if(1!==this.yGap)for(a=r;a<=o;a+=1)e[n][a]=!0,e[i][a]=!0;if(1!==this.xGap)for(a=n;a<=i;a+=1)e[a][r]=!0,e[a][o]=!0},t.prototype.destroy=function(){this.bitmap={}},t}();function dr(t,e,n,i){var r=t.getCanvasBBox(),o=r.width,a=r.height,s={x:e,y:n,textAlign:"center"};switch(i){case 0:s.y-=a+1,s.x+=1,s.textAlign="left";break;case 1:s.y-=a+1,s.x-=1,s.textAlign="right";break;case 2:s.y+=a+1,s.x-=1,s.textAlign="right";break;case 3:s.y+=a+1,s.x+=1,s.textAlign="left";break;case 5:s.y-=2*a+2;break;case 6:s.y+=2*a+2;break;case 7:s.x+=o+1,s.textAlign="left";break;case 8:s.x-=o+1,s.textAlign="right"}return t.attr(s),t.getCanvasBBox()}var gr=N.vec2.dot;function yr(t){if(t.length>4)return[];var e=function(t,e){return[e.x-t.x,e.y-t.y]};return[e(t[0],t[1]),e(t[1],t[2])]}function vr(t,e,n){void 0===e&&(e=0),void 0===n&&(n={x:0,y:0});var i=t.x,r=t.y;return{x:(i-n.x)*Math.cos(-e)+(r-n.y)*Math.sin(-e)+n.x,y:(n.x-i)*Math.sin(-e)+(r-n.y)*Math.cos(-e)+n.y}}function mr(t){var e=[{x:t.x,y:t.y},{x:t.x+t.width,y:t.y},{x:t.x+t.width,y:t.y+t.height},{x:t.x,y:t.y+t.height}],n=t.rotation;return n?[vr(e[0],n,e[0]),vr(e[1],n,e[0]),vr(e[2],n,e[0]),vr(e[3],n,e[0])]:e}function xr(t,e){if(t.length>4)return{min:0,max:0};var n=[];return t.forEach((function(t){n.push(gr([t.x,t.y],e))})),{min:Math.min.apply(Math,n),max:Math.max.apply(Math,n)}}function br(t,e){return t.max>e.min&&t.mint.x+t.width+n||e.x+e.widtht.y+t.height+n||e.y+e.height=o.height:a.width>=o.width}(t,e,r)}))}function Ar(t,e,n){return t.some((function(t){return n(t,e)}))}function Cr(t,e){return Ar(t,e,(function(t,e){var n,i,r,o=Wn(t),a=Wn(e);return n=o.getCanvasBBox(),i=a.getCanvasBBox(),void 0===(r=2)&&(r=0),Math.max(0,Math.min(n.x+n.width+r,i.x+i.width+r)-Math.max(n.x-r,i.x-r))*Math.max(0,Math.min(n.y+n.height+r,i.y+i.height+r)-Math.max(n.y-r,i.y-r))>0}))}function Er(t,e,n){return t.some((function(t){return n(t,e)}))}function Ir(t,e){return Er(t,e,(function(t,e){var n,i,r,o=Wn(t),a=Wn(e);return n=o.getCanvasBBox(),i=a.getCanvasBBox(),void 0===(r=2)&&(r=0),Math.max(0,Math.min(n.x+n.width+r,i.x+i.width+r)-Math.max(n.x-r,i.x-r))*Math.max(0,Math.min(n.y+n.height+r,i.y+i.height+r)-Math.max(n.y-r,i.y-r))>0}))}var Pr=Object(s.memoize)((function(t,e){void 0===e&&(e={});var n=e.fontSize,i=e.fontFamily,r=e.fontWeight,o=e.fontStyle,a=e.fontVariant,c=(jr||(jr=document.createElement("canvas").getContext("2d")),jr);return c.font=[o,a,r,"".concat(n,"px"),i].join(" "),c.measureText(Object(s.isString)(t)?t:"").width}),(function(t,e){return void 0===e&&(e={}),Object(a.__spreadArray)([t],Object(s.values)(e),!0).join("")}));function Fr(t,e,n,i,r){var o,a,s=n.start,c=n.end,l=n.getWidth(),u=n.getHeight();"y"===r?(o=s.x+l/2,a=i.ys.x?i.x:s.x,a=s.y+u/2):"xy"===r&&(n.isPolar?(o=n.getCenter().x,a=n.getCenter().y):(o=(s.x+c.x)/2,a=(s.y+c.y)/2));var h=function(t,e,n){var i,r=e[0],o=e[1];return t.applyToMatrix([r,o,1]),"x"===n?(t.setMatrix(N.ext.transform(t.getMatrix(),[["t",-r,-o],["s",.01,1],["t",r,o]])),i=N.ext.transform(t.getMatrix(),[["t",-r,-o],["s",100,1],["t",r,o]])):"y"===n?(t.setMatrix(N.ext.transform(t.getMatrix(),[["t",-r,-o],["s",1,.01],["t",r,o]])),i=N.ext.transform(t.getMatrix(),[["t",-r,-o],["s",1,100],["t",r,o]])):"xy"===n&&(t.setMatrix(N.ext.transform(t.getMatrix(),[["t",-r,-o],["s",.01,.01],["t",r,o]])),i=N.ext.transform(t.getMatrix(),[["t",-r,-o],["s",100,100],["t",r,o]])),i}(t,[o,a],r);t.animate({matrix:h},e)}function Tr(t,e){var n,i=Object(Ii.getArcParams)(t,e),r=i.startAngle,o=i.endAngle;return!Object(s.isNumberEqual)(r,.5*-Math.PI)&&r<.5*-Math.PI&&(r+=2*Math.PI),!Object(s.isNumberEqual)(o,.5*-Math.PI)&&o<.5*-Math.PI&&(o+=2*Math.PI),0===e[5]&&(r=(n=[o,r])[0],o=n[1]),Object(s.isNumberEqual)(r,1.5*Math.PI)&&(r=-.5*Math.PI),Object(s.isNumberEqual)(o,-.5*Math.PI)&&(o=1.5*Math.PI),{startAngle:r,endAngle:o}}function Lr(t){var e;return"M"===t[0]||"L"===t[0]?e=[t[1],t[2]]:"a"!==t[0]&&"A"!==t[0]&&"C"!==t[0]||(e=[t[t.length-2],t[t.length-1]]),e}function kr(t){var e,n,i,r=t.filter((function(t){return"A"===t[0]||"a"===t[0]}));if(0===r.length)return{startAngle:0,endAngle:0,radius:0,innerRadius:0};var o=r[0],a=r.length>1?r[1]:r[0],c=t.indexOf(o),l=t.indexOf(a),u=Lr(t[c-1]),h=Lr(t[l-1]),f=Tr(u,o),p=f.startAngle,d=f.endAngle,g=Tr(h,a),y=g.startAngle,v=g.endAngle;Object(s.isNumberEqual)(p,y)&&Object(s.isNumberEqual)(d,v)?(n=p,i=d):(n=Math.min(p,y),i=Math.max(d,v));var m=o[1],x=r[r.length-1][1];return m=0;r--)for(var o=0,a=this.getFacetsByLevel(t,r);o=n){var r=i.parsePosition([t[c],t[a.field]]);r&&f.push(r)}if(t[c]===h)return!1})),f},e.prototype.parsePercentPosition=function(t){var e=parseFloat(t[0])/100,n=parseFloat(t[1])/100,i=this.view.getCoordinate(),r=i.start,o=i.end,a=Math.min(r.x,o.x),s=Math.min(r.y,o.y);return{x:i.getWidth()*e+a,y:i.getHeight()*n+s}},e.prototype.getCoordinateBBox=function(){var t=this.view.getCoordinate(),e=t.start,n=t.end,i=t.getWidth(),r=t.getHeight(),o={x:Math.min(e.x,n.x),y:Math.min(e.y,n.y)};return{x:o.x,y:o.y,minX:o.x,minY:o.y,maxX:o.x+i,maxY:o.y+r,width:i,height:r}},e.prototype.getAnnotationCfg=function(t,e,n){var i=this,r=this.view.getCoordinate(),o=this.view.getCanvas(),c={};if(Object(s.isNil)(e))return null;var l=e.start,u=e.end,h=e.position,f=this.parsePosition(l),p=this.parsePosition(u),d=this.parsePosition(h);if(!(!["arc","image","line","region","regionFilter"].includes(t)||f&&p))return null;if(["text","dataMarker","html"].includes(t)&&!d)return null;if("arc"===t){var g=e,y=(g.start,g.end,Object(a.__rest)(g,["start","end"])),v=gt(r,f),m=gt(r,p);v>m&&(m=2*Math.PI+m),c=Object(a.__assign)(Object(a.__assign)({},y),{center:r.getCenter(),radius:pt(r,f),startAngle:v,endAngle:m})}else if("image"===t){var x=e;x.start,x.end,y=Object(a.__rest)(x,["start","end"]);c=Object(a.__assign)(Object(a.__assign)({},y),{start:f,end:p,src:e.src})}else if("line"===t){var b=e;b.start,b.end,y=Object(a.__rest)(b,["start","end"]);c=Object(a.__assign)(Object(a.__assign)({},y),{start:f,end:p,text:Object(s.get)(e,"text",null)})}else if("region"===t){var O=e;O.start,O.end,y=Object(a.__rest)(O,["start","end"]);c=Object(a.__assign)(Object(a.__assign)({},y),{start:f,end:p})}else if("text"===t){var _=this.view.getData(),w=e,j=(w.position,w.content),S=(y=Object(a.__rest)(w,["position","content"]),j);Object(s.isFunction)(j)&&(S=j(_)),c=Object(a.__assign)(Object(a.__assign)(Object(a.__assign)({},d),y),{content:S})}else if("dataMarker"===t){var M=e,A=(M.position,M.point),C=M.line,E=M.text,I=M.autoAdjust,P=M.direction;y=Object(a.__rest)(M,["position","point","line","text","autoAdjust","direction"]);c=Object(a.__assign)(Object(a.__assign)(Object(a.__assign)({},y),d),{coordinateBBox:this.getCoordinateBBox(),point:A,line:C,text:E,autoAdjust:I,direction:P})}else if("dataRegion"===t){var F=e,T=F.start,L=F.end,k=F.region,D=(E=F.text,F.lineLength);y=Object(a.__rest)(F,["start","end","region","text","lineLength"]);c=Object(a.__assign)(Object(a.__assign)({},y),{points:this.getRegionPoints(T,L),region:k,text:E,lineLength:D})}else if("regionFilter"===t){var B=e,R=(B.start,B.end,B.apply),N=B.color,V=(y=Object(a.__rest)(B,["start","end","apply","color"]),this.view.geometries),z=[],G=function t(e){e&&(e.isGroup()?e.getChildren().forEach((function(e){return t(e)})):z.push(e))};Object(s.each)(V,(function(t){R?Object(s.contains)(R,t.type)&&Object(s.each)(t.elements,(function(t){G(t.shape)})):Object(s.each)(t.elements,(function(t){G(t.shape)}))})),c=Object(a.__assign)(Object(a.__assign)({},y),{color:N,shapes:z,start:f,end:p})}else if("shape"===t){var Y=e,X=Y.render,W=Object(a.__rest)(Y,["render"]);c=Object(a.__assign)(Object(a.__assign)({},W),{render:function(t){if(Object(s.isFunction)(e.render))return X(t,i.view,{parsePosition:i.parsePosition.bind(i)})}})}else if("html"===t){var H=e,U=H.html;H.position,W=Object(a.__rest)(H,["html","position"]);c=Object(a.__assign)(Object(a.__assign)(Object(a.__assign)({},W),d),{parent:o.get("el").parentNode,html:function(t){return Object(s.isFunction)(U)?U(t,i.view):U}})}var q=Object(s.deepMix)({},n,Object(a.__assign)(Object(a.__assign)({},c),{top:e.top,style:e.style,offsetX:e.offsetX,offsetY:e.offsetY}));return"html"!==t&&(q.container=this.getComponentContainer(q)),q.animate=this.view.getOptions().animate&&q.animate&&Object(s.get)(e,"animate",q.animate),q.animateOption=Object(s.deepMix)({},xn,q.animateOption,e.animateOption),q},e.prototype.isTop=function(t){return Object(s.get)(t,"top",!0)},e.prototype.getComponentContainer=function(t){return this.isTop(t)?this.foregroundContainer:this.backgroundContainer},e.prototype.getAnnotationTheme=function(t){return Object(s.get)(this.view.getTheme(),["components","annotation",t],{})},e.prototype.updateOrCreate=function(t){var e=this.cache.get(this.getCacheKey(t));if(e){var n=t.type,i=this.getAnnotationTheme(n),r=this.getAnnotationCfg(n,t,i);r&<(r,["container"]),e.component.update(Object(a.__assign)(Object(a.__assign)({},r||{}),{visible:!!r})),Object(s.includes)(Ur,t.type)&&e.component.render()}else(e=this.createAnnotation(t))&&(e.component.init(),Object(s.includes)(Ur,t.type)&&e.component.render());return e},e.prototype.syncCache=function(t){var e=this,n=new Map(this.cache);return t.forEach((function(t,e){n.set(e,t)})),n.forEach((function(t,i){Object(s.find)(e.option,(function(t){return i===e.getCacheKey(t)}))||(t.component.destroy(),n.delete(i))})),n},e.prototype.getCacheKey=function(t){return t},e}(dn);function Zr(t,e){var n=Object(s.deepMix)({},Object(s.get)(t,["components","axis","common"]),Object(s.get)(t,["components","axis",e]));return Object(s.get)(n,["grid"],{})}function $r(t,e,n,i){var r=[],o=e.getTicks();return t.isPolar&&o.push({value:1,text:"",tickValue:""}),o.reduce((function(e,o,a){var s=o.value;if(i)r.push({points:[t.convert("y"===n?{x:0,y:s}:{x:s,y:0}),t.convert("y"===n?{x:1,y:s}:{x:s,y:1})]});else if(a){var c=(e.value+s)/2;r.push({points:[t.convert("y"===n?{x:0,y:c}:{x:c,y:0}),t.convert("y"===n?{x:1,y:c}:{x:c,y:1})]})}return o}),o[0]),r}function Kr(t,e,n,i,r){var o=e.values.length,a=[],c=n.getTicks();return c.reduce((function(e,n){var c=e?e.value:n.value,l=n.value,u=(c+l)/2;return"x"===r?a.push({points:[t.convert({x:i?l:u,y:0}),t.convert({x:i?l:u,y:1})]}):a.push({points:Object(s.map)(Array(o+1),(function(e,n){return t.convert({x:n/o,y:i?l:u})}))}),n}),c[0]),a}function Qr(t,e){var n=Object(s.get)(e,"grid");if(null===n)return!1;var i=Object(s.get)(t,"grid");return!(void 0===n&&null===i)}var Jr=["container"],to=Object(a.__assign)(Object(a.__assign)({},xn),{appear:null}),eo=function(t){function e(e){var n=t.call(this,e)||this;return n.cache=new Map,n.gridContainer=n.view.getLayer(i.BG).addGroup(),n.gridForeContainer=n.view.getLayer(i.FORE).addGroup(),n.axisContainer=n.view.getLayer(i.BG).addGroup(),n.axisForeContainer=n.view.getLayer(i.FORE).addGroup(),n}return Object(a.__extends)(e,t),Object.defineProperty(e.prototype,"name",{get:function(){return"axis"},enumerable:!1,configurable:!0}),e.prototype.init=function(){},e.prototype.render=function(){this.update()},e.prototype.layout=function(){var t=this,e=this.view.getCoordinate();Object(s.each)(this.getComponents(),(function(n){var i,r=n.component,a=n.direction,s=n.type,c=n.extra,l=c.dim,u=c.scale,h=c.alignTick;if(s===o.AXIS)e.isPolar?"x"===l?i=e.isTransposed?_t(e,a):At(e):"y"===l&&(i=e.isTransposed?At(e):_t(e,a)):i=_t(e,a);else if(s===o.GRID)if(e.isPolar){i={items:e.isTransposed?"x"===l?Kr(e,t.view.getYScales()[0],u,h,l):$r(e,u,l,h):"x"===l?$r(e,u,l,h):Kr(e,t.view.getXScale(),u,h,l),center:t.view.getCoordinate().getCenter()}}else i={items:$r(e,u,l,h)};r.update(i)}))},e.prototype.update=function(){this.option=this.view.getOptions().axes;var t=new Map;this.updateXAxes(t),this.updateYAxes(t);var e=new Map;this.cache.forEach((function(n,i){t.has(i)?e.set(i,n):n.component.destroy()})),this.cache=e},e.prototype.clear=function(){t.prototype.clear.call(this),this.cache.clear(),this.gridContainer.clear(),this.gridForeContainer.clear(),this.axisContainer.clear(),this.axisForeContainer.clear()},e.prototype.destroy=function(){t.prototype.destroy.call(this),this.gridContainer.remove(!0),this.gridForeContainer.remove(!0),this.axisContainer.remove(!0),this.axisForeContainer.remove(!0)},e.prototype.getComponents=function(){var t=[];return this.cache.forEach((function(e){t.push(e)})),t},e.prototype.updateXAxes=function(t){var e=this.view.getXScale();if(e&&!e.isIdentity){var n=Ct(this.option,e.field);if(!1!==n){var o=Et(n,r.BOTTOM),a=i.BG,c=this.view.getCoordinate(),l=this.getId("axis",e.field),u=this.getId("grid",e.field);if(c.isRect){if(h=this.cache.get(l))lt(p=this.getLineAxisCfg(e,n,o),Jr),h.component.update(p),t.set(l,h);else h=this.createLineAxis(e,n,a,o,"x"),this.cache.set(l,h),t.set(l,h);if(f=this.cache.get(u))lt(p=this.getLineGridCfg(e,n,o,"x"),Jr),f.component.update(p),t.set(u,f);else(f=this.createLineGrid(e,n,a,o,"x"))&&(this.cache.set(u,f),t.set(u,f))}else if(c.isPolar){var h,f;if(h=this.cache.get(l)){lt(p=c.isTransposed?this.getLineAxisCfg(e,n,r.RADIUS):this.getCircleAxisCfg(e,n,o),Jr),h.component.update(p),t.set(l,h)}else{if(c.isTransposed){if(Object(s.isUndefined)(n))return;h=this.createLineAxis(e,n,a,r.RADIUS,"x")}else h=this.createCircleAxis(e,n,a,o,"x");this.cache.set(l,h),t.set(l,h)}if(f=this.cache.get(u)){var p;lt(p=c.isTransposed?this.getCircleGridCfg(e,n,r.RADIUS,"x"):this.getLineGridCfg(e,n,r.CIRCLE,"x"),Jr),f.component.update(p),t.set(u,f)}else{if(c.isTransposed){if(Object(s.isUndefined)(n))return;f=this.createCircleGrid(e,n,a,r.RADIUS,"x")}else f=this.createLineGrid(e,n,a,r.CIRCLE,"x");f&&(this.cache.set(u,f),t.set(u,f))}}}}},e.prototype.updateYAxes=function(t){var e=this,n=this.view.getYScales();Object(s.each)(n,(function(n,o){if(n&&!n.isIdentity){var a=n.field,c=Ct(e.option,a);if(!1!==c){var l=i.BG,u=e.getId("axis",a),h=e.getId("grid",a),f=e.view.getCoordinate();if(f.isRect){var p=Et(c,0===o?r.LEFT:r.RIGHT);if(d=e.cache.get(u))lt(y=e.getLineAxisCfg(n,c,p),Jr),d.component.update(y),t.set(u,d);else d=e.createLineAxis(n,c,l,p,"y"),e.cache.set(u,d),t.set(u,d);if(g=e.cache.get(h))lt(y=e.getLineGridCfg(n,c,p,"y"),Jr),g.component.update(y),t.set(h,g);else(g=e.createLineGrid(n,c,l,p,"y"))&&(e.cache.set(h,g),t.set(h,g))}else if(f.isPolar){var d,g;if(d=e.cache.get(u)){lt(y=f.isTransposed?e.getCircleAxisCfg(n,c,r.CIRCLE):e.getLineAxisCfg(n,c,r.RADIUS),Jr),d.component.update(y),t.set(u,d)}else{if(f.isTransposed){if(Object(s.isUndefined)(c))return;d=e.createCircleAxis(n,c,l,r.CIRCLE,"y")}else d=e.createLineAxis(n,c,l,r.RADIUS,"y");e.cache.set(u,d),t.set(u,d)}if(g=e.cache.get(h)){var y;lt(y=f.isTransposed?e.getLineGridCfg(n,c,r.CIRCLE,"y"):e.getCircleGridCfg(n,c,r.RADIUS,"y"),Jr),g.component.update(y),t.set(h,g)}else{if(f.isTransposed){if(Object(s.isUndefined)(c))return;g=e.createLineGrid(n,c,l,r.CIRCLE,"y")}else g=e.createCircleGrid(n,c,l,r.RADIUS,"y");g&&(e.cache.set(h,g),t.set(h,g))}}}}}))},e.prototype.createLineAxis=function(t,e,n,i,a){var s={component:new U(this.getLineAxisCfg(t,e,i)),layer:n,direction:i===r.RADIUS?r.NONE:i,type:o.AXIS,extra:{dim:a,scale:t}};return s.component.set("field",t.field),s.component.init(),s},e.prototype.createLineGrid=function(t,e,n,i,a){var c=this.getLineGridCfg(t,e,i,a);if(c){var l={component:new Z(c),layer:n,direction:r.NONE,type:o.GRID,extra:{dim:a,scale:t,alignTick:Object(s.get)(c,"alignTick",!0)}};return l.component.init(),l}},e.prototype.createCircleAxis=function(t,e,n,i,r){var a={component:new q(this.getCircleAxisCfg(t,e,i)),layer:n,direction:i,type:o.AXIS,extra:{dim:r,scale:t}};return a.component.set("field",t.field),a.component.init(),a},e.prototype.createCircleGrid=function(t,e,n,i,a){var c=this.getCircleGridCfg(t,e,i,a);if(c){var l={component:new $(c),layer:n,direction:r.NONE,type:o.GRID,extra:{dim:a,scale:t,alignTick:Object(s.get)(c,"alignTick",!0)}};return l.component.init(),l}},e.prototype.getLineAxisCfg=function(t,e,n){var i=Object(s.get)(e,["top"])?this.axisForeContainer:this.axisContainer,r=this.view.getCoordinate(),o=_t(r,n),c=It(t,e),l=St(this.view.getTheme(),n),u=Object(s.get)(e,["title"])?Object(s.deepMix)({title:{style:{text:c}}},{title:Mt(this.view.getTheme(),n,e.title)},e):e,h=Object(s.deepMix)(Object(a.__assign)(Object(a.__assign)({container:i},o),{ticks:t.getTicks().map((function(t){return{id:"".concat(t.tickValue),name:t.text,value:t.value}})),verticalFactor:r.isPolar?-1*jt(o,r.getCenter()):jt(o,r.getCenter()),theme:l}),l,u),f=this.getAnimateCfg(h),p=f.animate,d=f.animateOption;h.animateOption=d,h.animate=p;var g=wt(o),y=Object(s.get)(h,"verticalLimitLength",g?1/3:.5);if(y<=1){var v=this.view.getCanvas().get("width"),m=this.view.getCanvas().get("height");h.verticalLimitLength=y*(g?v:m)}return h},e.prototype.getLineGridCfg=function(t,e,n,i){if(Qr(St(this.view.getTheme(),n),e)){var r=Zr(this.view.getTheme(),n),o=Object(s.deepMix)({container:Object(s.get)(e,["top"])?this.gridForeContainer:this.gridContainer},r,Object(s.get)(e,"grid"),this.getAnimateCfg(e));return o.items=$r(this.view.getCoordinate(),t,i,Object(s.get)(o,"alignTick",!0)),o}},e.prototype.getCircleAxisCfg=function(t,e,n){var i=Object(s.get)(e,["top"])?this.axisForeContainer:this.axisContainer,o=this.view.getCoordinate(),c=t.getTicks().map((function(t){return{id:"".concat(t.tickValue),name:t.text,value:t.value}}));t.isCategory||Math.abs(o.endAngle-o.startAngle)!==2*Math.PI||c.pop();var l=It(t,e),u=St(this.view.getTheme(),r.CIRCLE),h=Object(s.get)(e,["title"])?Object(s.deepMix)({title:{style:{text:l}}},{title:Mt(this.view.getTheme(),n,e.title)},e):e,f=Object(s.deepMix)(Object(a.__assign)(Object(a.__assign)({container:i},At(this.view.getCoordinate())),{ticks:c,verticalFactor:1,theme:u}),u,h),p=this.getAnimateCfg(f),d=p.animate,g=p.animateOption;return f.animate=d,f.animateOption=g,f},e.prototype.getCircleGridCfg=function(t,e,n,i){if(Qr(St(this.view.getTheme(),n),e)){var o=Zr(this.view.getTheme(),r.RADIUS),a=Object(s.deepMix)({container:Object(s.get)(e,["top"])?this.gridForeContainer:this.gridContainer,center:this.view.getCoordinate().getCenter()},o,Object(s.get)(e,"grid"),this.getAnimateCfg(e)),c=Object(s.get)(a,"alignTick",!0),l="x"===i?this.view.getYScales()[0]:this.view.getXScale();return a.items=Kr(this.view.getCoordinate(),l,t,c,i),a}},e.prototype.getId=function(t,e){var n=this.view.getCoordinate();return"".concat(t,"-").concat(e,"-").concat(n.type)},e.prototype.getAnimateCfg=function(t){return{animate:this.view.getOptions().animate&&Object(s.get)(t,"animate"),animateOption:t&&t.animateOption?Object(s.deepMix)({},to,t.animateOption):to}},e}(dn);function no(t,e,n){return n===r.TOP?[t.minX+t.width/2-e.width/2,t.minY]:n===r.BOTTOM?[t.minX+t.width/2-e.width/2,t.maxY-e.height]:n===r.LEFT?[t.minX,t.minY+t.height/2-e.height/2]:n===r.RIGHT?[t.maxX-e.width,t.minY+t.height/2-e.height/2]:n===r.TOP_LEFT||n===r.LEFT_TOP?[t.tl.x,t.tl.y]:n===r.TOP_RIGHT||n===r.RIGHT_TOP?[t.tr.x-e.width,t.tr.y]:n===r.BOTTOM_LEFT||n===r.LEFT_BOTTOM?[t.bl.x,t.bl.y-e.height]:n===r.BOTTOM_RIGHT||n===r.RIGHT_BOTTOM?[t.br.x-e.width,t.br.y-e.height]:[0,0]}function io(t,e){return Object(s.isBoolean)(t)?!1!==t&&{}:Object(s.get)(t,[e],t)}function ro(t){return Object(s.get)(t,"position",r.BOTTOM)}var oo=function(t){function e(e){var n=t.call(this,e)||this;return n.container=n.view.getLayer(i.FORE).addGroup(),n}return Object(a.__extends)(e,t),Object.defineProperty(e.prototype,"name",{get:function(){return"legend"},enumerable:!1,configurable:!0}),e.prototype.init=function(){},e.prototype.render=function(){this.update()},e.prototype.layout=function(){var t=this;this.layoutBBox=this.view.viewBBox,Object(s.each)(this.components,(function(e){var n=e.component,i=e.direction,r=ei(i),o=n.get("maxWidthRatio"),a=n.get("maxHeightRatio"),s=t.getCategoryLegendSizeCfg(r,o,a),c=n.get("maxWidth"),l=n.get("maxHeight");n.update({maxWidth:Math.min(s.maxWidth,c||0),maxHeight:Math.min(s.maxHeight,l||0)});var u=n.get("padding"),h=n.getLayoutBBox(),f=new ht(h.x,h.y,h.width,h.height).expand(u),p=no(t.view.viewBBox,f,i),d=p[0],g=p[1],y=no(t.layoutBBox,f,i),v=y[0],m=y[1],x=0,b=0;i.startsWith("top")||i.startsWith("bottom")?(x=d,b=m):(x=v,b=g),n.setLocation({x:x+u[3],y:b+u[0]}),t.layoutBBox=t.layoutBBox.cut(f,i)}))},e.prototype.update=function(){var t=this;this.option=this.view.getOptions().legends;var e={};if(Object(s.get)(this.option,"custom")){var n="global-custom",r=this.getComponentById(n);if(r){var a=this.getCategoryCfg(void 0,void 0,void 0,this.option,!0);lt(a,["container"]),r.component.update(a),e[n]=!0}else{var c=this.createCustomLegend(void 0,void 0,void 0,this.option);if(c){c.init();var l=i.FORE,u=ro(this.option);this.components.push({id:n,component:c,layer:l,direction:u,type:o.LEGEND,extra:void 0}),e[n]=!0}}}else this.loopLegends((function(n,i,r){var o=t.getId(r.field),a=t.getComponentById(o);if(a){var c=void 0,l=io(t.option,r.field);!1!==l&&(Object(s.get)(l,"custom")?c=t.getCategoryCfg(n,i,r,l,!0):r.isLinear?c=t.getContinuousCfg(n,i,r,l):r.isCategory&&(c=t.getCategoryCfg(n,i,r,l))),c&&(lt(c,["container"]),a.direction=ro(l),a.component.update(c),e[o]=!0)}else{var u=t.createFieldLegend(n,i,r);u&&(u.component.init(),t.components.push(u),e[o]=!0)}}));var h=[];Object(s.each)(this.getComponents(),(function(t){e[t.id]?h.push(t):t.component.destroy()})),this.components=h},e.prototype.clear=function(){t.prototype.clear.call(this),this.container.clear()},e.prototype.destroy=function(){t.prototype.destroy.call(this),this.container.remove(!0)},e.prototype.getGeometries=function(t){var e=this,n=t.geometries;return Object(s.each)(t.views,(function(t){n=n.concat(e.getGeometries(t))})),n},e.prototype.loopLegends=function(t){if(this.view.getRootView()===this.view){var e=this.getGeometries(this.view),n={};Object(s.each)(e,(function(e){var i=e.getGroupAttributes();Object(s.each)(i,(function(i){var r=i.getScale(i.type);r&&"identity"!==r.type&&!n[r.field]&&(t(e,i,r),n[r.field]=!0)}))}))}},e.prototype.createFieldLegend=function(t,e,n){var r,a=io(this.option,n.field),c=i.FORE,l=ro(a);if(!1!==a&&(Object(s.get)(a,"custom")?r=this.createCustomLegend(t,e,n,a):n.isLinear?r=this.createContinuousLegend(t,e,n,a):n.isCategory&&(r=this.createCategoryLegend(t,e,n,a))),r)return r.set("field",n.field),{id:this.getId(n.field),component:r,layer:c,direction:l,type:o.LEGEND,extra:{scale:n}}},e.prototype.createCustomLegend=function(t,e,n,i){var r=this.getCategoryCfg(t,e,n,i,!0);return new K(r)},e.prototype.createContinuousLegend=function(t,e,n,i){var r=this.getContinuousCfg(t,e,n,lt(i,["value"]));return new Q(r)},e.prototype.createCategoryLegend=function(t,e,n,i){var r=this.getCategoryCfg(t,e,n,i);return new K(r)},e.prototype.getContinuousCfg=function(t,e,n,i){var r=n.getTicks(),o=Object(s.find)(r,(function(t){return 0===t.value})),a=Object(s.find)(r,(function(t){return 1===t.value})),c=r.map((function(t){var i=t.value,r=t.tickValue,o=e.mapping(n.invert(i)).join("");return{value:r,attrValue:o,color:o,scaleValue:i}}));o||c.push({value:n.min,attrValue:e.mapping(n.invert(0)).join(""),color:e.mapping(n.invert(0)).join(""),scaleValue:0}),a||c.push({value:n.max,attrValue:e.mapping(n.invert(1)).join(""),color:e.mapping(n.invert(1)).join(""),scaleValue:1}),c.sort((function(t,e){return t.value-e.value}));var l={min:Object(s.head)(c).value,max:Object(s.last)(c).value,colors:[],rail:{type:e.type},track:{}};"size"===e.type&&(l.track={style:{fill:"size"===e.type?this.view.getTheme().defaultColor:void 0}}),"color"===e.type&&(l.colors=c.map((function(t){return t.attrValue})));var u=this.container,h=ei(ro(i)),f=Object(s.get)(i,"title");return f&&(f=Object(s.deepMix)({text:bt(n)},f)),l.container=u,l.layout=h,l.title=f,l.animateOption=xn,this.mergeLegendCfg(l,i,"continuous")},e.prototype.getCategoryCfg=function(t,e,n,i,o){var a=this.container,c=Object(s.get)(i,"position",r.BOTTOM),l=ii(this.view.getTheme(),c),u=Object(s.get)(l,["marker"]),h=Object(s.get)(i,"marker"),f=ei(c),p=Object(s.get)(l,["pageNavigator"]),d=Object(s.get)(i,"pageNavigator"),g=o?function(t,e,n){return n.map((function(n,i){var r=e;Object(s.isFunction)(r)&&(r=r(n.name,i,Object(s.deepMix)({},t,n)));var o=Object(s.isFunction)(n.marker)?n.marker(n.name,i,Object(s.deepMix)({},t,n)):n.marker,a=Object(s.deepMix)({},t,r,o);return ti(a),n.marker=a,n}))}(u,h,i.items):ni(this.view,t,e,u,h),y=Object(s.get)(i,"title");y&&(y=Object(s.deepMix)({text:n?bt(n):""},y));var v=Object(s.get)(i,"maxWidthRatio"),m=Object(s.get)(i,"maxHeightRatio"),x=this.getCategoryLegendSizeCfg(f,v,m);x.container=a,x.layout=f,x.items=g,x.title=y,x.animateOption=xn,x.pageNavigator=Object(s.deepMix)({},p,d);var b=this.mergeLegendCfg(x,i,c);b.reversed&&b.items.reverse();var O=Object(s.get)(b,"maxItemWidth");return O&&O<=1&&(b.maxItemWidth=this.view.viewBBox.width*O),b},e.prototype.mergeLegendCfg=function(t,e,n){var i=n.split("-")[0],r=ii(this.view.getTheme(),i);return Object(s.deepMix)({},r,t,e)},e.prototype.getId=function(t){return"".concat(this.name,"-").concat(t)},e.prototype.getComponentById=function(t){return Object(s.find)(this.components,(function(e){return e.id===t}))},e.prototype.getCategoryLegendSizeCfg=function(t,e,n){void 0===e&&(e=.25),void 0===n&&(n=.25);var i=this.view.viewBBox,r=i.width,o=i.height;return"vertical"===t?{maxWidth:r*e,maxHeight:o}:{maxWidth:r,maxHeight:o*n}},e}(dn),ao=function(t){function e(e){var n=t.call(this,e)||this;return n.onChangeFn=s.noop,n.resetMeasure=function(){n.clear()},n.onValueChange=function(t){var e=t[0],i=t[1];n.start=e,n.end=i,n.changeViewData(e,i)},n.container=n.view.getLayer(i.FORE).addGroup(),n.onChangeFn=Object(s.throttle)(n.onValueChange,20,{leading:!0}),n.width=0,n.view.on(c.BEFORE_CHANGE_DATA,n.resetMeasure),n.view.on(c.BEFORE_CHANGE_SIZE,n.resetMeasure),n}return Object(a.__extends)(e,t),Object.defineProperty(e.prototype,"name",{get:function(){return"slider"},enumerable:!1,configurable:!0}),e.prototype.destroy=function(){t.prototype.destroy.call(this),this.view.off(c.BEFORE_CHANGE_DATA,this.resetMeasure),this.view.off(c.BEFORE_CHANGE_SIZE,this.resetMeasure)},e.prototype.init=function(){},e.prototype.render=function(){this.option=this.view.getOptions().slider;var t=this.getSliderCfg(),e=t.start,n=t.end;Object(s.isNil)(this.start)&&(this.start=e,this.end=n);var i=this.view.getOptions().data;this.option&&!Object(s.isEmpty)(i)?this.slider?this.slider=this.updateSlider():(this.slider=this.createSlider(),this.slider.component.on("sliderchange",this.onChangeFn)):this.slider&&(this.slider.component.destroy(),this.slider=void 0)},e.prototype.layout=function(){var t=this;if(this.option&&!this.width&&(this.measureSlider(),setTimeout((function(){t.view.destroyed||t.changeViewData(t.start,t.end)}),0)),this.slider){var e=this.view.coordinateBBox.width,n=this.slider.component.get("padding"),i=n[0],o=(n[1],n[2],n[3]),s=this.slider.component.getLayoutBBox(),c=new ht(s.x,s.y,Math.min(s.width,e),s.height).expand(n),l=this.getMinMaxText(this.start,this.end),u=l.minText,h=l.maxText,f=no(this.view.viewBBox,c,r.BOTTOM),p=(f[0],f[1]),d=no(this.view.coordinateBBox,c,r.BOTTOM),g=d[0];d[1];this.slider.component.update(Object(a.__assign)(Object(a.__assign)({},this.getSliderCfg()),{x:g+o,y:p+i,width:this.width,start:this.start,end:this.end,minText:u,maxText:h})),this.view.viewBBox=this.view.viewBBox.cut(c,r.BOTTOM)}},e.prototype.update=function(){this.render()},e.prototype.createSlider=function(){var t=this.getSliderCfg(),e=new H.Slider(Object(a.__assign)({container:this.container},t));return e.init(),{component:e,layer:i.FORE,direction:r.BOTTOM,type:o.SLIDER}},e.prototype.updateSlider=function(){var t=this.getSliderCfg();if(this.width){var e=this.getMinMaxText(this.start,this.end),n=e.minText,i=e.maxText;t=Object(a.__assign)(Object(a.__assign)({},t),{width:this.width,start:this.start,end:this.end,minText:n,maxText:i})}return this.slider.component.update(t),this.slider},e.prototype.measureSlider=function(){var t=this.getSliderCfg().width;this.width=t},e.prototype.getSliderCfg=function(){var t={height:16,start:0,end:1,minText:"",maxText:"",x:0,y:0,width:this.view.coordinateBBox.width};if(Object(s.isObject)(this.option)){var e=Object(a.__assign)({data:this.getData()},Object(s.get)(this.option,"trendCfg",{}));t=Object(s.deepMix)({},t,this.getThemeOptions(),this.option),t=Object(a.__assign)(Object(a.__assign)({},t),{trendCfg:e})}return t.start=Object(s.clamp)(Math.min(Object(s.isNil)(t.start)?0:t.start,Object(s.isNil)(t.end)?1:t.end),0,1),t.end=Object(s.clamp)(Math.max(Object(s.isNil)(t.start)?0:t.start,Object(s.isNil)(t.end)?1:t.end),0,1),t},e.prototype.getData=function(){var t=this.view.getOptions().data,e=this.view.getYScales()[0],n=this.view.getGroupScales();if(n.length){var i=n[0],r=i.field,o=i.ticks;return t.reduce((function(t,n){return n[r]===o[0]&&t.push(n[e.field]),t}),[])}return t.map((function(t){return t[e.field]||0}))},e.prototype.getThemeOptions=function(){var t=this.view.getTheme();return Object(s.get)(t,["components","slider","common"],{})},e.prototype.getMinMaxText=function(t,e){var n=this.view.getOptions().data,i=this.view.getXScale(),r=Object(s.valuesOfKey)(n,i.field);i.isLinear&&(r=r.sort());var o=r,a=Object(s.size)(n);if(!i||!a)return{};var c=Object(s.size)(o),l=Math.floor(t*(c-1)),u=Math.floor(e*(c-1)),h=Object(s.get)(o,[l]),f=Object(s.get)(o,[u]),p=this.getSliderCfg().formatter;return p&&(h=p(h,n[l],l),f=p(f,n[u],u)),{minText:h,maxText:f}},e.prototype.changeViewData=function(t,e){var n=this.view.getOptions().data,i=this.view.getXScale(),r=Object(s.size)(n);if(i&&r){var o=Object(s.valuesOfKey)(n,i.field),a=this.view.getXScale().isLinear?o.sort((function(t,e){return Number(t)-Number(e)})):o,c=a,l=Object(s.size)(c),u=Math.floor(t*(l-1)),h=Math.floor(e*(l-1));this.view.filter(i.field,(function(t,e){var n=c.indexOf(t);return!(n>-1)||ct(n,u,h)})),this.view.render(!0)}},e.prototype.getComponents=function(){return this.slider?[this.slider]:[]},e.prototype.clear=function(){this.slider&&(this.slider.component.destroy(),this.slider=void 0),this.width=0,this.start=void 0,this.end=void 0},e}(dn),so=function(t){function e(e){var n=t.call(this,e)||this;return n.onChangeFn=s.noop,n.resetMeasure=function(){n.clear()},n.onValueChange=function(t){var e=t.ratio,i=n.getValidScrollbarCfg().animate;n.ratio=Object(s.clamp)(e,0,1);var r=n.view.getOptions().animate;i||n.view.animate(!1),n.changeViewData(n.getScrollRange(),!0),n.view.animate(r)},n.container=n.view.getLayer(i.FORE).addGroup(),n.onChangeFn=Object(s.throttle)(n.onValueChange,20,{leading:!0}),n.trackLen=0,n.thumbLen=0,n.ratio=0,n.view.on(c.BEFORE_CHANGE_DATA,n.resetMeasure),n.view.on(c.BEFORE_CHANGE_SIZE,n.resetMeasure),n}return Object(a.__extends)(e,t),Object.defineProperty(e.prototype,"name",{get:function(){return"scrollbar"},enumerable:!1,configurable:!0}),e.prototype.destroy=function(){t.prototype.destroy.call(this),this.view.off(c.BEFORE_CHANGE_DATA,this.resetMeasure),this.view.off(c.BEFORE_CHANGE_SIZE,this.resetMeasure)},e.prototype.init=function(){},e.prototype.render=function(){this.option=this.view.getOptions().scrollbar,this.option?this.scrollbar?this.scrollbar=this.updateScrollbar():(this.scrollbar=this.createScrollbar(),this.scrollbar.component.on("scrollchange",this.onChangeFn)):this.scrollbar&&(this.scrollbar.component.destroy(),this.scrollbar=void 0)},e.prototype.layout=function(){var t=this;if(this.option&&!this.trackLen&&(this.measureScrollbar(),setTimeout((function(){t.view.destroyed||t.changeViewData(t.getScrollRange(),!0)}))),this.scrollbar){var e=this.view.coordinateBBox.width,n=this.scrollbar.component.get("padding"),i=this.scrollbar.component.getLayoutBBox(),o=new ht(i.x,i.y,Math.min(i.width,e),i.height).expand(n),s=this.getScrollbarComponentCfg(),c=void 0,l=void 0;if(s.isHorizontal){var u=no(this.view.viewBBox,o,r.BOTTOM),h=(u[0],u[1]),f=no(this.view.coordinateBBox,o,r.BOTTOM),p=f[0];f[1];c=p,l=h}else{var d=no(this.view.viewBBox,o,r.RIGHT),g=(d[0],h=d[1],no(this.view.viewBBox,o,r.RIGHT));p=g[0],g[1];c=p,l=h}c+=n[3],l+=n[0],this.trackLen?this.scrollbar.component.update(Object(a.__assign)(Object(a.__assign)({},s),{x:c,y:l,trackLen:this.trackLen,thumbLen:this.thumbLen,thumbOffset:(this.trackLen-this.thumbLen)*this.ratio})):this.scrollbar.component.update(Object(a.__assign)(Object(a.__assign)({},s),{x:c,y:l})),this.view.viewBBox=this.view.viewBBox.cut(o,s.isHorizontal?r.BOTTOM:r.RIGHT)}},e.prototype.update=function(){this.render()},e.prototype.getComponents=function(){return this.scrollbar?[this.scrollbar]:[]},e.prototype.clear=function(){this.scrollbar&&(this.scrollbar.component.destroy(),this.scrollbar=void 0),this.trackLen=0,this.thumbLen=0,this.ratio=0,this.cnt=0,this.step=0,this.data=void 0,this.xScaleCfg=void 0,this.yScalesCfg=[]},e.prototype.setValue=function(t){this.onValueChange({ratio:t})},e.prototype.getValue=function(){return this.ratio},e.prototype.getThemeOptions=function(){var t=this.view.getTheme();return Object(s.get)(t,["components","scrollbar","common"],{})},e.prototype.getScrollbarTheme=function(t){var e=Object(s.get)(this.view.getTheme(),["components","scrollbar"]),n=t||{},i=n.thumbHighlightColor,r=Object(a.__rest)(n,["thumbHighlightColor"]);return{default:Object(s.deepMix)({},Object(s.get)(e,["default","style"],{}),r),hover:Object(s.deepMix)({},Object(s.get)(e,["hover","style"],{}),{thumbColor:i})}},e.prototype.measureScrollbar=function(){var t=this.view.getXScale(),e=this.view.getYScales().slice();this.data=this.getScrollbarData(),this.step=this.getStep(),this.cnt=this.getCnt();var n=this.getScrollbarComponentCfg(),i=n.trackLen,r=n.thumbLen;this.trackLen=i,this.thumbLen=r,this.xScaleCfg={field:t.field,values:t.values||[]},this.yScalesCfg=e},e.prototype.getScrollRange=function(){var t=Math.floor((this.cnt-this.step)*Object(s.clamp)(this.ratio,0,1));return[t,Math.min(t+this.step-1,this.cnt-1)]},e.prototype.changeViewData=function(t,e){var n=this,i=t[0],r=t[1],o="vertical"!==this.getValidScrollbarCfg().type,a=Object(s.valuesOfKey)(this.data,this.xScaleCfg.field),c=this.view.getXScale().isLinear?a.sort((function(t,e){return Number(t)-Number(e)})):a,l=o?c:c.reverse();this.yScalesCfg.forEach((function(t){n.view.scale(t.field,{formatter:t.formatter,type:t.type,min:t.min,max:t.max,tickMethod:t.tickMethod})})),this.view.filter(this.xScaleCfg.field,(function(t){var e=l.indexOf(t);return!(e>-1)||ct(e,i,r)})),this.view.render(!0)},e.prototype.createScrollbar=function(){var t="vertical"!==this.getValidScrollbarCfg().type,e=new H.Scrollbar(Object(a.__assign)(Object(a.__assign)({container:this.container},this.getScrollbarComponentCfg()),{x:0,y:0}));return e.init(),{component:e,layer:i.FORE,direction:t?r.BOTTOM:r.RIGHT,type:o.SCROLLBAR}},e.prototype.updateScrollbar=function(){var t=this.getScrollbarComponentCfg(),e=this.trackLen?Object(a.__assign)(Object(a.__assign)({},t),{trackLen:this.trackLen,thumbLen:this.thumbLen,thumbOffset:(this.trackLen-this.thumbLen)*this.ratio}):Object(a.__assign)({},t);return this.scrollbar.component.update(e),this.scrollbar},e.prototype.getStep=function(){if(this.step)return this.step;var t=this.view.coordinateBBox,e=this.getValidScrollbarCfg(),n=e.type,i=e.categorySize,r="vertical"!==n;return Math.floor((r?t.width:t.height)/i)},e.prototype.getCnt=function(){if(this.cnt)return this.cnt;var t=this.view.getXScale(),e=this.getScrollbarData(),n=Object(s.valuesOfKey)(e,t.field);return Object(s.size)(n)},e.prototype.getScrollbarComponentCfg=function(){var t=this.view,e=t.coordinateBBox,n=t.viewBBox,i=this.getValidScrollbarCfg(),r=i.type,o=i.padding,c=i.width,l=i.height,u=i.style,h="vertical"!==r,f=o[0],p=o[1],d=o[2],g=o[3],y=h?{x:e.minX+g,y:n.maxY-l-d}:{x:n.maxX-c-p,y:e.minY+f},v=this.getStep(),m=this.getCnt(),x=h?e.width-g-p:e.height-f-d,b=Math.max(x*Object(s.clamp)(v/m,0,1),20);return Object(a.__assign)(Object(a.__assign)({},this.getThemeOptions()),{x:y.x,y:y.y,size:h?l:c,isHorizontal:h,trackLen:x,thumbLen:b,thumbOffset:0,theme:this.getScrollbarTheme(u)})},e.prototype.getValidScrollbarCfg=function(){var t={type:"horizontal",categorySize:32,width:8,height:8,padding:[0,0,0,0],animate:!0,style:{}};return Object(s.isObject)(this.option)&&(t=Object(a.__assign)(Object(a.__assign)({},t),this.option)),Object(s.isObject)(this.option)&&this.option.padding||(t.padding=(t.type,[0,0,0,0])),t},e.prototype.getScrollbarData=function(){var t=this.view.getCoordinate(),e=this.getValidScrollbarCfg(),n=this.view.getOptions().data||[];return t.isReflect("y")&&"vertical"===e.type&&(n=Object(a.__spreadArray)([],n,!0).reverse()),n},e}(dn),co={fill:"#CCD6EC",opacity:.3};function lo(t,e,n){var i=function(t,e,n){for(var i=Qe(t,e,n),r=0,o=t.views;r1){for(var p=i[0],d=Math.abs(e.y-p[0].y),g=0,y=i;gp.maxY&&(p=e)):(e.minXp.maxX&&(p=e)),d.x=Math.min(e.minX,d.minX),d.y=Math.min(e.minY,d.minY),d.width=Math.max(e.maxX,d.maxX)-d.x,d.height=Math.max(e.maxY,d.maxY)-d.y}));var g=e.backgroundGroup,y=e.coordinateBBox,v=void 0;if(h.isRect){var m=e.getXScale(),x=t||{},b=x.appendRatio,O=x.appendWidth;Object(s.isNil)(O)&&(b=Object(s.isNil)(b)?m.isLinear?0:.25:b,O=h.isTransposed?b*p.height:b*f.width);var _=void 0,w=void 0,j=void 0,S=void 0;h.isTransposed?(_=y.minX,w=Math.min(p.minY,f.minY)-O,j=y.width,S=d.height+2*O):(_=Math.min(f.minX,p.minX)-O,w=y.minY,j=d.width+2*O,S=y.height),v=[["M",_,w],["L",_+j,w],["L",_+j,w+S],["L",_,w+S],["Z"]]}else{var M=Object(s.head)(l),A=Object(s.last)(l),C=ot(M.getModel(),h).startAngle,E=ot(A.getModel(),h).endAngle,I=h.getCenter(),P=h.getRadius(),F=h.innerRadius*P;v=it(I.x,I.y,P,C,E,F)}if(this.regionPath)this.regionPath.attr("path",v),this.regionPath.show();else{var T=Object(s.get)(t,"style",co);this.regionPath=g.addShape({type:"path",name:"active-region",capture:!1,attrs:Object(a.__assign)(Object(a.__assign)({},T),{path:v})})}}}},e.prototype.hide=function(){this.regionPath&&this.regionPath.hide(),this.items=null},e.prototype.destroy=function(){this.hide(),this.regionPath&&this.regionPath.remove(!0),t.prototype.destroy.call(this)},e}(kt),ho=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.timeStamp=0,e}return Object(a.__extends)(e,t),e.prototype.show=function(){var t=this.context,e=t.event,n=t.view;if(!n.isTooltipLocked()){var i=this.timeStamp,r=+new Date;if(r-i>Object(s.get)(t.view.getOptions(),"tooltip.showDelay",16)){var o=this.location,a={x:e.x,y:e.y};o&&Object(s.isEqual)(o,a)||this.showTooltip(n,a),this.timeStamp=r,this.location=a}}},e.prototype.hide=function(){var t=this.context.view,e=t.getController("tooltip"),n=this.context.event,i=n.clientX,r=n.clientY;e.isCursorEntered({x:i,y:r})||t.isTooltipLocked()||(this.hideTooltip(t),this.location=null)},e.prototype.showTooltip=function(t,e){t.showTooltip(e)},e.prototype.hideTooltip=function(t){t.hideTooltip()},e}(kt),fo=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(a.__extends)(e,t),e.prototype.showTooltip=function(t,e){var n=he(t);Object(s.each)(n,(function(n){var i=fe(t,n,e);n.showTooltip(i)}))},e.prototype.hideTooltip=function(t){var e=he(t);Object(s.each)(e,(function(t){t.hideTooltip()}))},e}(ho),po=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.timeStamp=0,e}return Object(a.__extends)(e,t),e.prototype.destroy=function(){t.prototype.destroy.call(this),this.tooltip&&this.tooltip.destroy()},e.prototype.show=function(){var t=this.context.event,e=this.timeStamp,n=+new Date;if(n-e>16){var i=this.location,r={x:t.x,y:t.y};i&&Object(s.isEqual)(i,r)||this.showTooltip(r),this.timeStamp=n,this.location=r}},e.prototype.hide=function(){this.hideTooltip(),this.location=null},e.prototype.showTooltip=function(t){var e=this.context.event.target;if(e&&e.get("tip")){this.tooltip||this.renderTooltip();var n=e.get("tip");this.tooltip.update(Object(a.__assign)({title:n},t)),this.tooltip.show()}},e.prototype.hideTooltip=function(){this.tooltip&&this.tooltip.hide()},e.prototype.renderTooltip=function(){var t,e=this.context.view,n=e.canvas,i={start:{x:0,y:0},end:{x:n.get("width"),y:n.get("height")}},r=e.getTheme(),o=Object(s.get)(r,["components","tooltip","domStyles"],{}),c=new J({parent:n.get("el").parentNode,region:i,visible:!1,crosshairs:null,domStyles:Object(a.__assign)({},Object(s.deepMix)({},o,(t={},t[H.TOOLTIP_CSS_CONST.CONTAINER_CLASS]={"max-width":"50%"},t[H.TOOLTIP_CSS_CONST.TITLE_CLASS]={"word-break":"break-all"},t)))});c.init(),c.setCapture(!1),this.tooltip=c},e}(kt),go=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.stateName="",e}return Object(a.__extends)(e,t),e.prototype.hasState=function(t){return t.hasState(this.stateName)},e.prototype.setElementState=function(t,e){t.setState(this.stateName,e)},e.prototype.setState=function(){this.setStateEnable(!0)},e.prototype.clear=function(){var t=this.context.view;this.clearViewState(t)},e.prototype.clearViewState=function(t){var e=this,n=re(t,this.stateName);Object(s.each)(n,(function(t){e.setElementState(t,!1)}))},e}(kt);function yo(t){return Object(s.get)(t.get("delegateObject"),"item")}var vo=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.ignoreListItemStates=["unchecked"],e}return Object(a.__extends)(e,t),e.prototype.isItemIgnore=function(t,e){return!!this.ignoreListItemStates.filter((function(n){return e.hasState(t,n)})).length},e.prototype.setStateByComponent=function(t,e,n){var i=this.context.view,r=t.get("field"),o=ie(i);this.setElementsStateByItem(o,r,e,n)},e.prototype.setStateByElement=function(t,e){this.setElementState(t,e)},e.prototype.isMathItem=function(t,e,n){var i=de(this.context.view,e),r=oe(t,e);return!Object(s.isNil)(r)&&n.name===i.getText(r)},e.prototype.setElementsStateByItem=function(t,e,n,i){var r=this;Object(s.each)(t,(function(t){r.isMathItem(t,e,n)&&t.setState(r.stateName,i)}))},e.prototype.setStateEnable=function(t){var e=Zt(this.context);if(e)Kt(this.context)&&this.setStateByElement(e,t);else{var n=$t(this.context);if(Qt(n)){var i=n.item,r=n.component;if(i&&r&&!this.isItemIgnore(i,r)){var o=this.context.event.gEvent;if(o&&o.fromShape&&o.toShape&&yo(o.fromShape)===yo(o.toShape))return;this.setStateByComponent(r,i,t)}}}},e.prototype.toggle=function(){var t=Zt(this.context);if(t){var e=t.hasState(this.stateName);this.setElementState(t,!e)}},e.prototype.reset=function(){this.setStateEnable(!1)},e}(go),mo=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.stateName="active",e}return Object(a.__extends)(e,t),e.prototype.active=function(){this.setState()},e}(vo),xo=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.cache={},e}return Object(a.__extends)(e,t),e.prototype.getColorScale=function(t,e){var n=e.geometry.getAttribute("color");return n?t.getScaleByField(n.getFields()[0]):null},e.prototype.getLinkPath=function(t,e){var n=this.context.view.getCoordinate().isTransposed,i=t.shape.getCanvasBBox(),r=e.shape.getCanvasBBox();return n?[["M",i.minX,i.minY],["L",r.minX,r.maxY],["L",r.maxX,r.maxY],["L",i.maxX,i.minY],["Z"]]:[["M",i.maxX,i.minY],["L",r.minX,r.minY],["L",r.minX,r.maxY],["L",i.maxX,i.maxY],["Z"]]},e.prototype.addLinkShape=function(t,e,n,i){var r={opacity:.4,fill:e.shape.attr("fill")};t.addShape({type:"path",attrs:Object(a.__assign)(Object(a.__assign)({},Object(s.deepMix)({},r,Object(s.isFunction)(i)?i(r,e):i)),{path:this.getLinkPath(e,n)})})},e.prototype.linkByElement=function(t,e){var n=this,i=this.context.view,r=this.getColorScale(i,t);if(r){var o=oe(t,r.field);if(!this.cache[o]){var a=function(t,e,n){return ie(t).filter((function(t){return oe(t,e)===n}))}(i,r.field,o),c=this.linkGroup.addGroup();this.cache[o]=c;var l=a.length;Object(s.each)(a,(function(t,i){if(i=0}),e)},e}(bo),To=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.stateName="active",e}return Object(a.__extends)(e,t),e.prototype.highlight=function(){this.setState()},e.prototype.setElementState=function(t,e){So(ie(this.context.view),(function(e){return t===e}),e)},e.prototype.clear=function(){jo(this.context.view)},e}(_o),Lo=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.stateName="selected",e}return Object(a.__extends)(e,t),e.prototype.selected=function(){this.setState()},e}(bo),ko=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.stateName="selected",e}return Object(a.__extends)(e,t),e.prototype.selected=function(){this.setState()},e}(vo),Do=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.stateName="selected",e}return Object(a.__extends)(e,t),e.prototype.selected=function(){this.setState()},e}(_o),Bo=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.stateName="",e.ignoreItemStates=[],e}return Object(a.__extends)(e,t),e.prototype.getTriggerListInfo=function(){var t=$t(this.context),e=null;return Qt(t)&&(e={item:t.item,list:t.component}),e},e.prototype.getAllowComponents=function(){var t=this,e=ce(this.context.view),n=[];return Object(s.each)(e,(function(e){e.isList()&&t.allowSetStateByElement(e)&&n.push(e)})),n},e.prototype.hasState=function(t,e){return t.hasState(e,this.stateName)},e.prototype.clearAllComponentsState=function(){var t=this,e=this.getAllowComponents();Object(s.each)(e,(function(e){e.clearItemsState(t.stateName)}))},e.prototype.allowSetStateByElement=function(t){var e=t.get("field");if(!e)return!1;if(this.cfg&&this.cfg.componentNames){var n=t.get("name");if(-1===this.cfg.componentNames.indexOf(n))return!1}var i=de(this.context.view,e);return i&&i.isCategory},e.prototype.allowSetStateByItem=function(t,e){var n=this.ignoreItemStates;return!n.length||0===n.filter((function(n){return e.hasState(t,n)})).length},e.prototype.setStateByElement=function(t,e,n){var i=t.get("field"),r=de(this.context.view,i),o=oe(e,i),a=r.getText(o);this.setItemsState(t,a,n)},e.prototype.setStateEnable=function(t){var e=this,n=Zt(this.context);if(n){var i=this.getAllowComponents();Object(s.each)(i,(function(i){e.setStateByElement(i,n,t)}))}else{var r=$t(this.context);if(Qt(r)){var o=r.item,a=r.component;this.allowSetStateByElement(a)&&this.allowSetStateByItem(o,a)&&this.setItemState(a,o,t)}}},e.prototype.setItemsState=function(t,e,n){var i=this,r=t.getItems();Object(s.each)(r,(function(r){r.name===e&&i.setItemState(t,r,n)}))},e.prototype.setItemState=function(t,e,n){t.setItemState(e,this.stateName,n)},e.prototype.setState=function(){this.setStateEnable(!0)},e.prototype.reset=function(){this.setStateEnable(!1)},e.prototype.toggle=function(){var t=this.getTriggerListInfo();if(t&&t.item){var e=t.list,n=t.item,i=this.hasState(e,n);this.setItemState(e,n,!i)}},e.prototype.clear=function(){var t=this.getTriggerListInfo();t?t.list.clearItemsState(this.stateName):this.clearAllComponentsState()},e}(kt),Ro=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.stateName="active",e}return Object(a.__extends)(e,t),e.prototype.active=function(){this.setState()},e}(Bo);var No=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.stateName="active",e.ignoreItemStates=["unchecked"],e}return Object(a.__extends)(e,t),e.prototype.setItemsState=function(t,e,n){this.setHighlightBy(t,(function(t){return t.name===e}),n)},e.prototype.setItemState=function(t,e,n){t.getItems();this.setHighlightBy(t,(function(t){return t===e}),n)},e.prototype.setHighlightBy=function(t,e,n){var i=t.getItems();if(n)Object(s.each)(i,(function(n){e(n)?(t.hasState(n,"inactive")&&t.setItemState(n,"inactive",!1),t.setItemState(n,"active",!0)):t.hasState(n,"active")||t.setItemState(n,"inactive",!0)}));else{var r=t.getItemsByState("active"),o=!0;Object(s.each)(r,(function(t){if(!e(t))return o=!1,!1})),o?this.clear():Object(s.each)(i,(function(n){e(n)&&(t.hasState(n,"active")&&t.setItemState(n,"active",!1),t.setItemState(n,"inactive",!0))}))}},e.prototype.highlight=function(){this.setState()},e.prototype.clear=function(){var t,e,n=this.getTriggerListInfo();if(n)t=n.list,e=t.getItems(),Object(s.each)(e,(function(e){t.hasState(e,"active")&&t.setItemState(e,"active",!1),t.hasState(e,"inactive")&&t.setItemState(e,"inactive",!1)}));else{var i=this.getAllowComponents();Object(s.each)(i,(function(t){t.clearItemsState("active"),t.clearItemsState("inactive")}))}},e}(Bo),Vo=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.stateName="selected",e}return Object(a.__extends)(e,t),e.prototype.selected=function(){this.setState()},e}(Bo),zo=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.stateName="unchecked",e}return Object(a.__extends)(e,t),e.prototype.unchecked=function(){this.setState()},e}(Bo),Go=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.stateName="checked",e}return Object(a.__extends)(e,t),e.prototype.setItemState=function(t,e,n){this.setCheckedBy(t,(function(t){return t===e}),n)},e.prototype.setCheckedBy=function(t,e,n){var i=t.getItems();n&&Object(s.each)(i,(function(n){e(n)?(t.hasState(n,"unchecked")&&t.setItemState(n,"unchecked",!1),t.setItemState(n,"checked",!0)):t.hasState(n,"checked")||t.setItemState(n,"unchecked",!0)}))},e.prototype.toggle=function(){var t=this.getTriggerListInfo();if(t&&t.item){var e=t.list,n=t.item;!Object(s.some)(e.getItems(),(function(t){return e.hasState(t,"unchecked")}))||e.hasState(n,"unchecked")?this.setItemState(e,n,!0):this.reset()}},e.prototype.checked=function(){this.setState()},e.prototype.reset=function(){var t=this.getAllowComponents();Object(s.each)(t,(function(t){t.clearItemsState("checked"),t.clearItemsState("unchecked")}))},e}(Bo),Yo=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(a.__extends)(e,t),e.prototype.toggle=function(){var t=this.getTriggerListInfo();if(null==t?void 0:t.item){var e=t.list,n=t.item,i=e.getItems(),r=i.filter((function(t){return!e.hasState(t,"unchecked")})),o=i.filter((function(t){return e.hasState(t,"unchecked")})),a=r[0];if(i.length===r.length)for(var s=0,c=i;s16&&"legend-item-radio"===i.get("name")){var r=this.location,o={x:t.x,y:t.y};this.timeStamp=n,this.location=o,r&&Object(s.isEqual)(r,o)||this.showTooltip(o)}},e.prototype.hideTip=function(){this.hideTooltip(),this.location=null},e.prototype.showTooltip=function(t){var e=this.context,n=e.event.target;if(n&&n.get("tip")){this.tooltip||this.renderTooltip();var i=e.view.getCanvas().get("el").getBoundingClientRect(),r=i.x,o=i.y;this.tooltip.update(Object(a.__assign)(Object(a.__assign)({title:n.get("tip")},t),{x:t.x+r,y:t.y+o})),this.tooltip.show()}},e.prototype.hideTooltip=function(){this.tooltip&&this.tooltip.hide()},e.prototype.renderTooltip=function(){var t,e=((t={})[H.TOOLTIP_CSS_CONST.CONTAINER_CLASS]={padding:"6px 8px",transform:"translate(-50%, -80%)",background:"rgba(0,0,0,0.75)",color:"#fff","border-radius":"2px","z-index":100},t[H.TOOLTIP_CSS_CONST.TITLE_CLASS]={"font-size":"12px","line-height":"14px","margin-bottom":0,"word-break":"break-all"},t);document.getElementById(Xo)&&document.body.removeChild(document.getElementById(Xo));var n=new J({parent:document.body,region:null,visible:!1,crosshairs:null,domStyles:e,containerId:Xo});n.init(),n.setCapture(!1),this.tooltip=n},e}(Bo),Ho=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.maskShape=null,e.points=[],e.starting=!1,e.moving=!1,e.preMovePoint=null,e.shapeType="path",e}return Object(a.__extends)(e,t),e.prototype.getCurrentPoint=function(){var t=this.context.event;return{x:t.x,y:t.y}},e.prototype.emitEvent=function(t){var e="mask:".concat(t),n=this.context.view,i=this.context.event;n.emit(e,{target:this.maskShape,shape:this.maskShape,points:this.points,x:i.x,y:i.y})},e.prototype.createMask=function(){var t=this.context.view,e=this.getMaskAttrs();return t.foregroundGroup.addShape({type:this.shapeType,name:"mask",draggable:!0,attrs:Object(a.__assign)({fill:"#C5D4EB",opacity:.3},e)})},e.prototype.getMaskPath=function(){return[]},e.prototype.show=function(){this.maskShape&&(this.maskShape.show(),this.emitEvent("show"))},e.prototype.start=function(t){this.starting=!0,this.moving=!1,this.points=[this.getCurrentPoint()],this.maskShape||(this.maskShape=this.createMask(),this.maskShape.set("capture",!1)),this.updateMask(null==t?void 0:t.maskStyle),this.emitEvent("start")},e.prototype.moveStart=function(){this.moving=!0,this.preMovePoint=this.getCurrentPoint()},e.prototype.move=function(){if(this.moving&&this.maskShape){var t=this.getCurrentPoint(),e=this.preMovePoint,n=t.x-e.x,i=t.y-e.y,r=this.points;Object(s.each)(r,(function(t){t.x+=n,t.y+=i})),this.updateMask(),this.emitEvent("change"),this.preMovePoint=t}},e.prototype.updateMask=function(t){var e=Object(s.deepMix)({},this.getMaskAttrs(),t);this.maskShape.attr(e)},e.prototype.moveEnd=function(){this.moving=!1,this.preMovePoint=null},e.prototype.end=function(){this.starting=!1,this.emitEvent("end"),this.maskShape&&this.maskShape.set("capture",!0)},e.prototype.hide=function(){this.maskShape&&(this.maskShape.hide(),this.emitEvent("hide"))},e.prototype.resize=function(){this.starting&&this.maskShape&&(this.points.push(this.getCurrentPoint()),this.updateMask(),this.emitEvent("change"))},e.prototype.destroy=function(){this.points=[],this.maskShape&&this.maskShape.remove(),this.maskShape=null,this.preMovePoint=null,t.prototype.destroy.call(this)},e}(kt),Uo=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.shapeType="circle",e}return Object(a.__extends)(e,t),e.prototype.getMaskAttrs=function(){var t=this.points,e=Object(s.last)(this.points),n=0,i=0,r=0;if(t.length){var o=t[0];n=le(o,e)/2,i=(e.x+o.x)/2,r=(e.y+o.y)/2}return{x:i,y:r,r:n}},e}(Ho),qo=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.shapeType="rect",e}return Object(a.__extends)(e,t),e.prototype.getRegion=function(){var t=this.points;return{start:Object(s.head)(t),end:Object(s.last)(t)}},e.prototype.getMaskAttrs=function(){var t=this.getRegion(),e=t.start,n=t.end;return{x:Math.min(e.x,n.x),y:Math.min(e.y,n.y),width:Math.abs(n.x-e.x),height:Math.abs(n.y-e.y)}},e}(Ho);function Zo(t){t.x=Object(s.clamp)(t.x,0,1),t.y=Object(s.clamp)(t.y,0,1)}var $o,Ko=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.dim="x",e.inPlot=!0,e}return Object(a.__extends)(e,t),e.prototype.getRegion=function(){var t=null,e=null,n=this.points,i=this.dim,r=this.context.view.getCoordinate(),o=r.invert(Object(s.head)(n)),a=r.invert(Object(s.last)(n));return this.inPlot&&(Zo(o),Zo(a)),"x"===i?(t=r.convert({x:o.x,y:0}),e=r.convert({x:a.x,y:1})):(t=r.convert({x:0,y:o.y}),e=r.convert({x:1,y:a.y})),{start:t,end:e}},e}(qo),Qo=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(a.__extends)(e,t),e.prototype.getMaskPath=function(){var t=this.points,e=[];return t.length&&(Object(s.each)(t,(function(t,n){0===n?e.push(["M",t.x,t.y]):e.push(["L",t.x,t.y])})),e.push(["L",t[0].x,t[0].y])),e},e.prototype.getMaskAttrs=function(){return{path:this.getMaskPath()}},e.prototype.addPoint=function(){this.resize()},e}(Ho),Jo=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(a.__extends)(e,t),e.prototype.getMaskPath=function(){return function(t,e){if(t.length<=2)return Xt(t,!1);var n=t[0],i=[];Object(s.each)(t,(function(t){i.push(t.x),i.push(t.y)}));var r=Yt(i,e,null);return r.unshift(["M",n.x,n.y]),r}(this.points,!0)},e}(Qo),ta=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(a.__extends)(e,t),e.prototype.setCursor=function(t){this.context.view.getCanvas().setCursor(t)},e.prototype.default=function(){this.setCursor("default")},e.prototype.pointer=function(){this.setCursor("pointer")},e.prototype.move=function(){this.setCursor("move")},e.prototype.crosshair=function(){this.setCursor("crosshair")},e.prototype.wait=function(){this.setCursor("wait")},e.prototype.help=function(){this.setCursor("help")},e.prototype.text=function(){this.setCursor("text")},e.prototype.eResize=function(){this.setCursor("e-resize")},e.prototype.wResize=function(){this.setCursor("w-resize")},e.prototype.nResize=function(){this.setCursor("n-resize")},e.prototype.sResize=function(){this.setCursor("s-resize")},e.prototype.neResize=function(){this.setCursor("ne-resize")},e.prototype.nwResize=function(){this.setCursor("nw-resize")},e.prototype.seResize=function(){this.setCursor("se-resize")},e.prototype.swResize=function(){this.setCursor("sw-resize")},e.prototype.nsResize=function(){this.setCursor("ns-resize")},e.prototype.ewResize=function(){this.setCursor("ew-resize")},e}(kt),ea=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(a.__extends)(e,t),e.prototype.filterView=function(t,e,n){var i=this;t.getScaleByField(e)&&t.filter(e,n),t.views&&t.views.length&&Object(s.each)(t.views,(function(t){i.filterView(t,e,n)}))},e.prototype.filter=function(){var t=$t(this.context);if(t){var e=this.context.view,n=t.component,i=n.get("field");if(Qt(t)){if(i){var r=n.getItemsByState("unchecked"),o=de(e,i),a=r.map((function(t){return t.name}));a.length?this.filterView(e,i,(function(t){var e=o.getText(t);return!a.includes(e)})):this.filterView(e,i,null),e.render(!0)}}else if(Jt(t)){var s=n.getValue(),c=s[0],l=s[1];this.filterView(e,i,(function(t){return t>=c&&t<=l})),e.render(!0)}}},e}(kt);function na(t,e,n,i){var r=Math.min(n[e],i[e]),o=Math.max(n[e],i[e]),a=t.range,s=a[0],c=a[1];if(rc&&(o=c),r===c&&o===c)return null;var l=t.invert(r),u=t.invert(o);if(t.isCategory){var h=t.values.indexOf(l),f=t.values.indexOf(u),p=t.values.slice(h,f+1);return function(t){return p.includes(t)}}return function(t){return t>=l&&t<=u}}!function(t){t.FILTER="brush-filter-processing",t.RESET="brush-filter-reset",t.BEFORE_FILTER="brush-filter:beforefilter",t.AFTER_FILTER="brush-filter:afterfilter",t.BEFORE_RESET="brush-filter:beforereset",t.AFTER_RESET="brush-filter:afterreset"}($o||($o={}));var ia=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.dims=["x","y"],e.startPoint=null,e.isStarted=!1,e}return Object(a.__extends)(e,t),e.prototype.hasDim=function(t){return this.dims.includes(t)},e.prototype.start=function(){var t=this.context;this.isStarted=!0,this.startPoint=t.getCurrentPoint()},e.prototype.filter=function(){var t,e;if(te(this.context)){var n=this.context.event.target.getCanvasBBox();t={x:n.x,y:n.y},e={x:n.maxX,y:n.maxY}}else{if(!this.isStarted)return;t=this.startPoint,e=this.context.getCurrentPoint()}if(!(Math.abs(t.x-e.x)<5||Math.abs(t.x-e.y)<5)){var i=this.context,r=i.view,o={view:r,event:i.event,dims:this.dims};r.emit($o.BEFORE_FILTER,rn.fromData(r,$o.BEFORE_FILTER,o));var a=r.getCoordinate(),s=a.invert(e),c=a.invert(t);if(this.hasDim("x")){var l=r.getXScale(),u=na(l,"x",s,c);this.filterView(r,l.field,u)}if(this.hasDim("y")){var h=r.getYScales()[0];u=na(h,"y",s,c);this.filterView(r,h.field,u)}this.reRender(r,{source:$o.FILTER}),r.emit($o.AFTER_FILTER,rn.fromData(r,$o.AFTER_FILTER,o))}},e.prototype.end=function(){this.isStarted=!1},e.prototype.reset=function(){var t=this.context.view;if(t.emit($o.BEFORE_RESET,rn.fromData(t,$o.BEFORE_RESET,{})),this.isStarted=!1,this.hasDim("x")){var e=t.getXScale();this.filterView(t,e.field,null)}if(this.hasDim("y")){var n=t.getYScales()[0];this.filterView(t,n.field,null)}this.reRender(t,{source:$o.RESET}),t.emit($o.AFTER_RESET,rn.fromData(t,$o.AFTER_RESET,{}))},e.prototype.filterView=function(t,e,n){t.filter(e,n)},e.prototype.reRender=function(t,e){t.render(!0,e)},e}(kt),ra=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(a.__extends)(e,t),e.prototype.filterView=function(t,e,n){var i=he(t);Object(s.each)(i,(function(t){t.filter(e,n)}))},e.prototype.reRender=function(t){var e=he(t);Object(s.each)(e,(function(t){t.render(!0)}))},e}(ia),oa=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(a.__extends)(e,t),e.prototype.filter=function(){var t=$t(this.context),e=this.context.view,n=ie(e);if(te(this.context)){var i=ee(this.context,10);i&&Object(s.each)(n,(function(t){i.includes(t)?t.show():t.hide()}))}else if(t){var r=t.component,o=r.get("field");if(Qt(t)){if(o){var a=r.getItemsByState("unchecked"),c=de(e,o),l=a.map((function(t){return t.name}));Object(s.each)(n,(function(t){var e=oe(t,o),n=c.getText(e);l.indexOf(n)>=0?t.hide():t.show()}))}}else if(Jt(t)){var u=r.getValue(),h=u[0],f=u[1];Object(s.each)(n,(function(t){var e=oe(t,o);e>=h&&e<=f?t.show():t.hide()}))}}},e.prototype.clear=function(){var t=ie(this.context.view);Object(s.each)(t,(function(t){t.show()}))},e.prototype.reset=function(){this.clear()},e}(kt),aa=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.byRecord=!1,e}return Object(a.__extends)(e,t),e.prototype.filter=function(){te(this.context)&&(this.byRecord?this.filterByRecord():this.filterByBBox())},e.prototype.filterByRecord=function(){var t=this.context.view,e=ee(this.context,10);if(e){var n=t.getXScale().field,i=t.getYScales()[0].field,r=e.map((function(t){return t.getModel().data})),o=he(t);Object(s.each)(o,(function(t){var e=ie(t);Object(s.each)(e,(function(t){var e=t.getModel().data;pe(r,e,n,i)?t.show():t.hide()}))}))}},e.prototype.filterByBBox=function(){var t=this,e=he(this.context.view);Object(s.each)(e,(function(e){var n=ne(t.context,e,10),i=ie(e);n&&Object(s.each)(i,(function(t){n.includes(t)?t.show():t.hide()}))}))},e.prototype.reset=function(){var t=he(this.context.view);Object(s.each)(t,(function(t){var e=ie(t);Object(s.each)(e,(function(t){t.show()}))}))},e}(kt),sa=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.buttonGroup=null,e.buttonCfg={name:"button",text:"button",textStyle:{x:0,y:0,fontSize:12,fill:"#333333",cursor:"pointer"},padding:[8,10],style:{fill:"#f7f7f7",stroke:"#cccccc",cursor:"pointer"},activeStyle:{fill:"#e6e6e6"}},e}return Object(a.__extends)(e,t),e.prototype.getButtonCfg=function(){return Object(s.deepMix)(this.buttonCfg,this.cfg)},e.prototype.drawButton=function(){var t=this.getButtonCfg(),e=this.context.view.foregroundGroup.addGroup({name:t.name}),n=e.addShape({type:"text",name:"button-text",attrs:Object(a.__assign)({text:t.text},t.textStyle)}).getBBox(),i=Je(t.padding),r=e.addShape({type:"rect",name:"button-rect",attrs:Object(a.__assign)({x:n.x-i[3],y:n.y-i[0],width:n.width+i[1]+i[3],height:n.height+i[0]+i[2]},t.style)});r.toBack(),e.on("mouseenter",(function(){r.attr(t.activeStyle)})),e.on("mouseleave",(function(){r.attr(t.style)})),this.buttonGroup=e},e.prototype.resetPosition=function(){var t=this.context.view.getCoordinate().convert({x:1,y:1}),e=this.buttonGroup,n=e.getBBox(),i=N.ext.transform(null,[["t",t.x-n.width-10,t.y+n.height+5]]);e.setMatrix(i)},e.prototype.show=function(){this.buttonGroup||this.drawButton(),this.resetPosition(),this.buttonGroup.show()},e.prototype.hide=function(){this.buttonGroup&&this.buttonGroup.hide()},e.prototype.destroy=function(){var e=this.buttonGroup;e&&e.remove(),t.prototype.destroy.call(this)},e}(kt),ca=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.starting=!1,e.dragStart=!1,e}return Object(a.__extends)(e,t),e.prototype.start=function(){this.starting=!0,this.startPoint=this.context.getCurrentPoint()},e.prototype.drag=function(){if(this.startPoint){var t=this.context.getCurrentPoint(),e=this.context.view,n=this.context.event;this.dragStart?e.emit("drag",{target:n.target,x:n.x,y:n.y}):le(t,this.startPoint)>4&&(e.emit("dragstart",{target:n.target,x:n.x,y:n.y}),this.dragStart=!0)}},e.prototype.end=function(){if(this.dragStart){var t=this.context.view,e=this.context.event;t.emit("dragend",{target:e.target,x:e.x,y:e.y})}this.starting=!1,this.dragStart=!1},e}(kt),la=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.starting=!1,e.isMoving=!1,e.startPoint=null,e.startMatrix=null,e}return Object(a.__extends)(e,t),e.prototype.start=function(){this.starting=!0,this.startPoint=this.context.getCurrentPoint(),this.startMatrix=this.context.view.middleGroup.getMatrix()},e.prototype.move=function(){if(this.starting){var t=this.startPoint,e=this.context.getCurrentPoint();if(le(t,e)>5&&!this.isMoving&&(this.isMoving=!0),this.isMoving){var n=this.context.view,i=N.ext.transform(this.startMatrix,[["t",e.x-t.x,e.y-t.y]]);n.backgroundGroup.setMatrix(i),n.foregroundGroup.setMatrix(i),n.middleGroup.setMatrix(i)}}},e.prototype.end=function(){this.isMoving&&(this.isMoving=!1),this.startMatrix=null,this.starting=!1,this.startPoint=null},e.prototype.reset=function(){this.starting=!1,this.startPoint=null,this.isMoving=!1;var t=this.context.view;t.backgroundGroup.resetMatrix(),t.foregroundGroup.resetMatrix(),t.middleGroup.resetMatrix(),this.isMoving=!1},e}(kt),ua=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.dims=["x","y"],e.cfgFields=["dims"],e.cacheScaleDefs={},e}return Object(a.__extends)(e,t),e.prototype.hasDim=function(t){return this.dims.includes(t)},e.prototype.getScale=function(t){var e=this.context.view;return"x"===t?e.getXScale():e.getYScales()[0]},e.prototype.resetDim=function(t){var e=this.context.view;if(this.hasDim(t)&&this.cacheScaleDefs[t]){var n=this.getScale(t);e.scale(n.field,this.cacheScaleDefs[t]),this.cacheScaleDefs[t]=null}},e.prototype.reset=function(){this.resetDim("x"),this.resetDim("y"),this.context.view.render(!0)},e}(kt),ha=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.startPoint=null,e.starting=!1,e.startCache={},e}return Object(a.__extends)(e,t),e.prototype.start=function(){var t=this;this.startPoint=this.context.getCurrentPoint(),this.starting=!0;var e=this.dims;Object(s.each)(e,(function(e){var n=t.getScale(e),i=n.min,r=n.max,o=n.values;t.startCache[e]={min:i,max:r,values:o}}))},e.prototype.end=function(){this.startPoint=null,this.starting=!1,this.startCache={}},e.prototype.translate=function(){var t=this;if(this.starting){var e=this.startPoint,n=this.context.view.getCoordinate(),i=this.context.getCurrentPoint(),r=n.invert(e),o=n.invert(i),a=o.x-r.x,c=o.y-r.y,l=this.context.view,u=this.dims;Object(s.each)(u,(function(e){t.translateDim(e,{x:-1*a,y:-1*c})})),l.render(!0)}},e.prototype.translateDim=function(t,e){if(this.hasDim(t)){var n=this.getScale(t);n.isLinear&&this.translateLinear(t,n,e)}},e.prototype.translateLinear=function(t,e,n){var i=this.context.view,r=this.startCache[t],o=r.min,a=r.max,s=a-o,c=n[t]*s;this.cacheScaleDefs[t]||(this.cacheScaleDefs[t]={nice:e.nice,min:o,max:a}),i.scale(e.field,{nice:!1,min:o+c,max:a+c})},e.prototype.reset=function(){t.prototype.reset.call(this),this.startPoint=null,this.starting=!1},e}(ua),fa=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.zoomRatio=.05,e}return Object(a.__extends)(e,t),e.prototype.zoomIn=function(){this.zoom(this.zoomRatio)},e.prototype.zoom=function(t){var e=this,n=this.dims;Object(s.each)(n,(function(n){e.zoomDim(n,t)})),this.context.view.render(!0)},e.prototype.zoomOut=function(){this.zoom(-1*this.zoomRatio)},e.prototype.zoomDim=function(t,e){if(this.hasDim(t)){var n=this.getScale(t);n.isLinear&&this.zoomLinear(t,n,e)}},e.prototype.zoomLinear=function(t,e,n){var i=this.context.view;this.cacheScaleDefs[t]||(this.cacheScaleDefs[t]={nice:e.nice,min:e.min,max:e.max});var r=this.cacheScaleDefs[t],o=r.max-r.min,a=e.min,s=e.max,c=n*o,l=a-c,u=s+c,h=(u-l)/o;u>l&&h<100&&h>.01&&i.scale(e.field,{nice:!1,min:a-c,max:s+c})},e}(ua);var pa=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(a.__extends)(e,t),e.prototype.scroll=function(t){var e=this.context,n=e.view,i=e.event;if(n.getOptions().scrollbar){var r=(null==t?void 0:t.wheelDelta)||1,o=n.getController("scrollbar"),a=n.getXScale(),c=n.getOptions().data,l=Object(s.size)(Object(s.valuesOfKey)(c,a.field)),u=Object(s.size)(a.values),h=o.getValue(),f=Math.floor((l-u)*h)+(function(t){return t.gEvent.originalEvent.deltaY>0}(i)?r:-r),p=r/(l-u)/1e4,d=Object(s.clamp)(f/(l-u)+p,0,1);o.setValue(d)}},e}(kt);function da(t){return t.isInPlot()}function ga(t){return t.gEvent.preventDefault(),t.gEvent.originalEvent.deltaY>0}Ye("dark",Ce(Ei)),m("canvas",Ii),m("svg",Pi),hn("Polygon",Ki),hn("Interval",Hi),hn("Schema",Qi),hn("Path",Fi),hn("Point",$i),hn("Line",Ui),hn("Area",Di),hn("Edge",Bi),hn("Heatmap",Ri),hn("Violin",Ji),Cn("base",$n),Cn("interval",cr),Cn("pie",hr),Cn("polar",ur),In("overlap",(function(t,e,n,i){var r=new pr;Object(s.each)(e,(function(t){for(var e=t.find((function(t){return"text"===t.get("type")})),n=e.attr(),i=n.x,o=n.y,a=!1,s=0;s<=8;s++){var c=dr(e,i,o,s);if(r.hasGap(c)){r.fillGap(c),a=!0;break}}a||t.remove(!0)})),r.destroy()})),In("distribute",(function(t,e,n,i){if(t.length&&e.length){var r=t[0]?t[0].offset:0,o=e[0].get("coordinate"),a=o.getRadius(),c=o.getCenter();if(r>0){var l=2*(a+r)+28,u={start:o.start,end:o.end},h=[[],[]];t.forEach((function(t){t&&("right"===t.textAlign?h[0].push(t):h[1].push(t))})),h.forEach((function(t,n){var i=l/14;t.length>i&&(t.sort((function(t,e){return e["..percent"]-t["..percent"]})),t.splice(i,t.length-i)),t.sort((function(t,e){return t.y-e.y})),function(t,e,n,i,r,o){var a,c=!0,l=i.start,u=i.end,h=Math.min(l.y,u.y),f=Math.abs(l.y-u.y),p=0,d=Number.MIN_VALUE,g=e.map((function(t){return t.y>p&&(p=t.y),t.yf&&(f=p-h);c;)for(g.forEach((function(t){var e=(Math.min.apply(d,t.targets)+Math.max.apply(d,t.targets))/2;t.pos=Math.min(Math.max(d,e-t.size/2),f-t.size)})),c=!1,a=g.length;a--;)if(a>0){var y=g[a-1],v=g[a];y.pos+y.size>v.pos&&(y.size+=v.size,y.targets=y.targets.concat(v.targets),y.pos+y.size>f&&(y.pos=f-y.size),g.splice(a,1),c=!0)}a=0,g.forEach((function(t){var i=h+n/2;t.targets.forEach((function(){e[a].y=t.pos+i,i+=n,a++}))}));for(var m={},x=0,b=t;xr.maxX||i.maxY>r.maxY)&&t.remove(!0)}))})),In("limit-in-canvas",(function(t,e,n,i){Object(s.each)(e,(function(t){var e=i.minX,n=i.minY,r=i.maxX,o=i.maxY,a=t.getCanvasBBox(),s=a.minX,c=a.minY,l=a.maxX,u=a.maxY,h=a.x,f=a.y,p=a.width,d=a.height,g=h,y=f;(sr?g=r-p:l>r&&(g-=l-r),c>o?y=o-d:u>o&&(y-=u-o),g===h&&y===f||Yn(t,g-h,y-f)}))})),In("limit-in-plot",(function(t,e,n,i,r){if(!(e.length<=0)){var o=(null==r?void 0:r.direction)||["top","right","bottom","left"],a=(null==r?void 0:r.action)||"translate",c=(null==r?void 0:r.margin)||0,l=e[0].get("coordinate");if(l){var u=function(t,e){void 0===e&&(e=0);var n=t.start,i=t.end,r=t.getWidth(),o=t.getHeight(),a=Math.min(n.x,i.x),s=Math.min(n.y,i.y);return ht.fromRange(a-e,s-e,a+r+e,s+o+e)}(l,c),h=u.minX,f=u.minY,p=u.maxX,d=u.maxY;Object(s.each)(e,(function(t){var e=t.getCanvasBBox(),n=e.minX,i=e.minY,r=e.maxX,c=e.maxY,l=e.x,u=e.y,g=e.width,y=e.height,v=l,m=u;if(o.indexOf("left")>=0&&(n=0&&(i=0&&(n>p?v=p-g:r>p&&(v-=r-p)),o.indexOf("bottom")>=0&&(i>d?m=d-y:c>d&&(m-=c-d)),v!==l||m!==u){var x=v-l;if("translate"===a)Yn(t,x,m-u);else if("ellipsis"===a){t.findAll((function(t){return"text"===t.get("type")})).forEach((function(t){var e=Object(s.pick)(t.attr(),["fontSize","fontFamily","fontWeight","fontStyle","fontVariant"]),n=t.getCanvasBBox(),i=function(t,e,n){var i,r=Pr("...",n);i=Object(s.isString)(t)?t:Object(s.toString)(t);var o,a,c=e,l=[];if(Pr(t,n)<=e)return t;for(;o=i.substr(0,16),!((a=Pr(o,n))+r>c&&a>c);)if(l.push(o),c-=a,!(i=i.substr(16)))return l.join("");for(;o=i.substr(0,1),!((a=Pr(o,n))+r>c);)if(l.push(o),c-=a,!(i=i.substr(1)))return l.join("");return"".concat(l.join(""),"...")}(t.attr("text"),n.width-Math.abs(x),e);t.attr("text",i)}))}else t.hide()}}))}}})),In("pie-outer",(function(t,e,n,i){var r=Object(s.filter)(t,(function(t){return!Object(s.isNil)(t)})),o=e[0]&&e[0].get("coordinate");if(o){for(var a=o.getCenter(),c=o.getRadius(),l={},u=0,h=e;un&&(t.sort((function(t,e){return e.percent-t.percent})),Object(s.each)(t,(function(t,e){e+1>n&&(l[t.id].set("visible",!1),t.invisible=!0)}))),fr(t,p,b)})),Object(s.each)(g,(function(t,e){Object(s.each)(t,(function(t){var n="right"===e,i=l[t.id].getChildByIndex(0);if(i){var r=c+d,u=t.y-a.y,h=Math.pow(r,2),f=Math.pow(u,2),p=h-f>0?h-f:0,g=Math.sqrt(p),y=Math.abs(Math.cos(t.angle)*r);t.x=n?a.x+Math.max(g,y):a.x-Math.max(g,y)}i&&(i.attr("y",t.y),i.attr("x",t.x)),function(t,e){var n=e.getCenter(),i=e.getRadius();if(t&&t.labelLine){var r=t.angle,o=t.offset,a=nt(n.x,n.y,i,r),c=t.x+Object(s.get)(t,"offsetX",0)*(Math.cos(r)>0?1:-1),l=t.y+Object(s.get)(t,"offsetY",0)*(Math.sin(r)>0?1:-1),u={x:c-4*Math.cos(r),y:l-4*Math.sin(r)},h=t.labelLine.smooth,f=[],p=u.x-n.x,d=u.y-n.y,g=Math.atan(d/p);if(p<0&&(g+=Math.PI),!1===h){Object(s.isObject)(t.labelLine)||(t.labelLine={});var y=0;(r<0&&r>-Math.PI/2||r>1.5*Math.PI)&&u.y>a.y&&(y=1),r>=0&&ra.y&&(y=1),r>=Math.PI/2&&ru.y&&(y=1),(r<-Math.PI/2||r>=Math.PI&&r<1.5*Math.PI)&&a.y>u.y&&(y=1);var v=o/2>4?4:Math.max(o/2-1,0),m=nt(n.x,n.y,i+v,r),x=nt(n.x,n.y,i+o/2,g);f.push("M ".concat(a.x," ").concat(a.y)),f.push("L ".concat(m.x," ").concat(m.y)),f.push("A ".concat(n.x," ").concat(n.y," 0 ").concat(0," ").concat(y," ").concat(x.x," ").concat(x.y)),f.push("L ".concat(u.x," ").concat(u.y))}else{m=nt(n.x,n.y,i+(o/2>4?4:Math.max(o/2-1,0)),r);var b=a.xMath.pow(Math.E,-16)&&f.push.apply(f,["C",u.x+4*b,u.y,2*m.x-a.x,2*m.y-a.y,a.x,a.y]),f.push("L ".concat(a.x," ").concat(a.y))}t.labelLine.path=f.join(" ")}}(t,o)}))}))}}})),In("adjust-color",(function(t,e,n){if(0!==n.length){var i=n[0].get("element").geometry.theme,r=i.labels||{},o=r.fillColorLight,a=r.fillColorDark;n.forEach((function(t,n){var r=e[n].find((function(t){return"text"===t.get("type")})),s=ht.fromObject(t.getBBox()),c=ht.fromObject(r.getCanvasBBox()),l=!s.contains(c),u=function(t){var e=E.default.toRGB(t).toUpperCase();if(Sr[e])return Sr[e];var n=E.default.rgb2arr(e);return(299*n[0]+587*n[1]+114*n[2])/1e3<128}(t.attr("fill"));l?r.attr(i.overflowLabels.style):u?o&&r.attr("fill",o):a&&r.attr("fill",a)}))}})),In("interval-adjust-position",(function(t,e,n){var i;if(0!==n.length){var r=null===(i=n[0])||void 0===i?void 0:i.get("element"),o=null==r?void 0:r.geometry;if(o&&"interval"===o.type)Mr(o,e,n)&&n.forEach((function(t,n){var i=e[n];!function(t,e,n){var i=t.coordinate,r=ht.fromObject(n.getBBox()),o=Wn(e);i.isTransposed?o.attr({x:r.minX+r.width/2,textAlign:"center"}):o.attr({y:r.minY+r.height/2,textBaseline:"middle"})}(o,i,t)}))}})),In("interval-hide-overlap",(function(t,e,n){var i;if(0!==n.length){var r=null===(i=n[0])||void 0===i?void 0:i.get("element"),o=null==r?void 0:r.geometry;if(o&&"interval"===o.type){var a,c=function(t){var e=[],n=Math.max(Math.floor(t.length/500),1);return Object(s.each)(t,(function(t,i){i%n==0?e.push(t):t.set("visible",!1)})),e}(e),l=o.getXYFields()[0],u=[],h=[],f=Object(s.groupBy)(c,(function(t){return t.get("data")[l]})),p=Object(s.uniq)(Object(s.map)(c,(function(t){return t.get("data")[l]})));c.forEach((function(t){t.set("visible",!0)}));var d=function(t){t&&(t.length&&h.push(t.pop()),h.push.apply(h,t))};for(Object(s.size)(p)>0&&(a=p.shift(),d(f[a])),Object(s.size)(p)>0&&(a=p.pop(),d(f[a])),Object(s.each)(p.reverse(),(function(t){d(f[t])}));h.length>0;){var g=h.shift();g.get("visible")&&(Un(g,u)?g.set("visible",!1):u.push(g))}}}})),In("point-adjust-position",(function(t,e,n,i,r){var o,a;if(0!==n.length){var c=null===(o=n[0])||void 0===o?void 0:o.get("element"),l=null==c?void 0:c.geometry;if(l&&"point"===l.type){var u=l.getXYFields(),h=u[0],f=u[1],p=Object(s.groupBy)(e,(function(t){return t.get("data")[h]})),d=[],g=r&&r.offset||(null===(a=t[0])||void 0===a?void 0:a.offset)||12;Object(s.map)(Object(s.keys)(p).reverse(),(function(t){for(var e=function(t,e){var n=t.getXYFields()[1],i=[],r=e.sort((function(t,e){return t.get("data")[n]-t.get("data")[n]}));return r.length>0&&i.push(r.shift()),r.length>0&&i.push(r.pop()),i.push.apply(i,r),i}(l,p[t]);e.length;){var n=e.shift(),i=Wn(n);if(Ar(d,n,(function(t,e){return t.get("data")[h]===e.get("data")[h]&&t.get("data")[f]===e.get("data")[f]})))i.set("visible",!1);else{var r=!1;Cr(d,n)&&(i.attr("y",i.attr("y")+2*g),r=Cr(d,n)),r?i.set("visible",!1):d.push(n)}}}))}}})),In("pie-spider",(function(t,e,n,i){var r=e[0]&&e[0].get("coordinate");if(r){for(var o=r.getCenter(),a=r.getRadius(),c={},l=0,u=e;lo.x||t.x===o.x&&t.y>o.y,n=Object(s.isNil)(t.offsetX)?4:t.offsetX,i=nt(o.x,o.y,a+4,t.angle),r=p+n;t.x=o.x+(e?1:-1)*(a+r),t.y=i.y}}));var d=r.start,g=r.end,y=Object(s.groupBy)(t,(function(t){return t.xv&&(v=Math.min(e,Math.abs(d.y-g.y)))}));var m={minX:d.x,maxX:g.x,minY:o.y-v/2,maxY:o.y+v/2};Object(s.each)(y,(function(t,e){var n=v/f;t.length>n&&(t.sort((function(t,e){return e.percent-t.percent})),Object(s.each)(t,(function(t,e){e>n&&(c[t.id].set("visible",!1),t.invisible=!0)}))),fr(t,f,m)}));var x=m.minY,b=m.maxY;Object(s.each)(y,(function(t,e){var n="right"===e;Object(s.each)(t,(function(t){var e=Object(s.get)(c,t&&[t.id]);if(e)if(t.yb)e.set("visible",!1);else{var i=e.getChildByIndex(0),o=i.getCanvasBBox(),a=n?o.x:o.maxX,l=o.y+o.height/2;Yn(i,t.x-a,t.y-l),t.labelLine&&function(t,e,n){var i,r=e.getCenter(),o=e.getRadius(),a={x:t.x-(n?4:-4),y:t.y},c=nt(r.x,r.y,o+4,t.angle),l={x:a.x,y:a.y},u={x:c.x,y:c.y},h=nt(r.x,r.y,o,t.angle);if(a.y!==c.y){var f=n?4:-4;l.y=a.y,t.angle<0&&t.angle>=-Math.PI/2&&(l.x=Math.max(c.x,a.x-f),a.y0&&t.anglec.y?u.y=l.y:(u.y=c.y,u.x=Math.max(u.x,l.x-f))),t.angle>Math.PI/2&&(l.x=Math.min(c.x,a.x-f),a.y>c.y?u.y=l.y:(u.y=c.y,u.x=Math.min(u.x,l.x-f))),t.angle<-Math.PI/2&&(l.x=Math.min(c.x,a.x-f),a.y0&&i.push(r.shift()),r.length>0&&i.push(r.pop()),i.push.apply(i,r),i}(l,p[t]);e.length;){var n=e.shift(),i=Wn(n);if(Er(d,n,(function(t,e){return t.get("data")[h]===e.get("data")[h]&&t.get("data")[f]===e.get("data")[f]})))i.set("visible",!1);else{var r=!1;Ir(d,n)&&(i.attr("y",i.attr("y")+2*g),r=Ir(d,n)),r?i.set("visible",!1):d.push(n)}}}))}}})),mn("fade-in",(function(t,e,n){var i={fillOpacity:Object(s.isNil)(t.attr("fillOpacity"))?1:t.attr("fillOpacity"),strokeOpacity:Object(s.isNil)(t.attr("strokeOpacity"))?1:t.attr("strokeOpacity"),opacity:Object(s.isNil)(t.attr("opacity"))?1:t.attr("opacity")};t.attr({fillOpacity:0,strokeOpacity:0,opacity:0}),t.animate(i,e)})),mn("fade-out",(function(t,e,n){var i=e.easing,r=e.duration,o=e.delay;t.animate({fillOpacity:0,strokeOpacity:0,opacity:0},r,i,(function(){t.remove(!0)}),o)})),mn("grow-in-x",(function(t,e,n){Fr(t,e,n.coordinate,n.minYPoint,"x")})),mn("grow-in-xy",(function(t,e,n){Fr(t,e,n.coordinate,n.minYPoint,"xy")})),mn("grow-in-y",(function(t,e,n){Fr(t,e,n.coordinate,n.minYPoint,"y")})),mn("scale-in-x",(function(t,e,n){var i=t.getBBox(),r=t.get("origin").mappingData.points,o=r[0].y-r[1].y>0?i.maxX:i.minX,a=(i.minY+i.maxY)/2;t.applyToMatrix([o,a,1]);var s=N.ext.transform(t.getMatrix(),[["t",-o,-a],["s",.01,1],["t",o,a]]);t.setMatrix(s),t.animate({matrix:N.ext.transform(t.getMatrix(),[["t",-o,-a],["s",100,1],["t",o,a]])},e)})),mn("scale-in-y",(function(t,e,n){var i=t.getBBox(),r=t.get("origin").mappingData,o=(i.minX+i.maxX)/2,a=r.points,s=a[0].y-a[1].y<=0?i.maxY:i.minY;t.applyToMatrix([o,s,1]);var c=N.ext.transform(t.getMatrix(),[["t",-o,-s],["s",1,.01],["t",o,s]]);t.setMatrix(c),t.animate({matrix:N.ext.transform(t.getMatrix(),[["t",-o,-s],["s",1,100],["t",o,s]])},e)})),mn("wave-in",(function(t,e,n){var i=yt(n.coordinate,20),r=i.type,o=i.startState,s=i.endState,c=t.setClip({type:r,attrs:o});c.animate(s,Object(a.__assign)(Object(a.__assign)({},e),{callback:function(){t&&!t.get("destroyed")&&t.set("clipShape",null),c.remove(!0)}}))})),mn("zoom-in",(function(t,e,n){Dr(t,e,"zoomIn")})),mn("zoom-out",(function(t,e,n){Dr(t,e,"zoomOut")})),mn("position-update",(function(t,e,n){var i=n.toAttrs,r=i.x,o=i.y;delete i.x,delete i.y,t.attr(i),t.animate({x:r,y:o},e)})),mn("sector-path-update",(function(t,e,n){var i=n.toAttrs,r=n.coordinate,o=i.path||[],c=o.map((function(t){return t[0]}));if(!(o.length<1)){var l=kr(o),u=l.startAngle,h=l.endAngle,f=l.radius,p=l.innerRadius,d=kr(t.attr("path")),g=d.startAngle,y=d.endAngle,v=r.getCenter(),m=u-g,x=h-y;0!==m||0!==x?t.animate((function(t){var e=g+t*m,n=y+t*x;return Object(a.__assign)(Object(a.__assign)({},i),{path:Object(s.isEqual)(c,["M","A","A","Z"])?rt(v.x,v.y,f,e,n):it(v.x,v.y,f,e,n,p)})}),Object(a.__assign)(Object(a.__assign)({},e),{callback:function(){t.attr("path",o)}})):t.attr("path",o)}})),mn("path-in",(function(t,e,n){var i=t.getTotalLength();t.attr("lineDash",[i]),t.animate((function(t){return{lineDashOffset:(1-t)*i}}),e)})),Lt("rect",Yr),Lt("mirror",Gr),Lt("list",Vr),Lt("matrix",zr),Lt("circle",Nr),Lt("tree",Xr),en("axis",eo),en("legend",oo),en("tooltip",gn),en("annotation",qr),en("slider",ao),en("scrollbar",so),Nt("tooltip",ho),Nt("sibling-tooltip",fo),Nt("ellipsis-text",po),Nt("element-active",mo),Nt("element-single-active",wo),Nt("element-range-active",Oo),Nt("element-highlight",Eo),Nt("element-highlight-by-x",Po),Nt("element-highlight-by-color",Io),Nt("element-single-highlight",To),Nt("element-range-highlight",Fo),Nt("element-sibling-highlight",Fo,{effectSiblings:!0,effectByRecord:!0}),Nt("element-selected",ko),Nt("element-single-selected",Do),Nt("element-range-selected",Lo),Nt("element-link-by-color",xo),Nt("active-region",uo),Nt("list-active",Ro),Nt("list-selected",Vo),Nt("list-highlight",No),Nt("list-unchecked",zo),Nt("list-checked",Go),Nt("list-focus",Yo),Nt("list-radio",Wo),Nt("legend-item-highlight",No,{componentNames:["legend"]}),Nt("axis-label-highlight",No,{componentNames:["axis"]}),Nt("rect-mask",qo),Nt("x-rect-mask",Ko,{dim:"x"}),Nt("y-rect-mask",Ko,{dim:"y"}),Nt("circle-mask",Uo),Nt("path-mask",Qo),Nt("smooth-path-mask",Jo),Nt("cursor",ta),Nt("data-filter",ea),Nt("brush",ia),Nt("brush-x",ia,{dims:["x"]}),Nt("brush-y",ia,{dims:["y"]}),Nt("sibling-filter",ra),Nt("sibling-x-filter",ra),Nt("sibling-y-filter",ra),Nt("element-filter",oa),Nt("element-sibling-filter",aa),Nt("element-sibling-filter-record",aa,{byRecord:!0}),Nt("view-drag",ca),Nt("view-move",la),Nt("scale-translate",ha),Nt("scale-zoom",fa),Nt("reset-button",sa,{name:"reset-button",text:"reset"}),Nt("mousewheel-scroll",pa),Ae("tooltip",{start:[{trigger:"plot:mousemove",action:"tooltip:show",throttle:{wait:50,leading:!0,trailing:!1}},{trigger:"plot:touchmove",action:"tooltip:show",throttle:{wait:50,leading:!0,trailing:!1}}],end:[{trigger:"plot:mouseleave",action:"tooltip:hide"},{trigger:"plot:leave",action:"tooltip:hide"},{trigger:"plot:touchend",action:"tooltip:hide"}]}),Ae("ellipsis-text",{start:[{trigger:"legend-item-name:mousemove",action:"ellipsis-text:show",throttle:{wait:50,leading:!0,trailing:!1}},{trigger:"legend-item-name:touchstart",action:"ellipsis-text:show",throttle:{wait:50,leading:!0,trailing:!1}},{trigger:"axis-label:mousemove",action:"ellipsis-text:show",throttle:{wait:50,leading:!0,trailing:!1}},{trigger:"axis-label:touchstart",action:"ellipsis-text:show",throttle:{wait:50,leading:!0,trailing:!1}}],end:[{trigger:"legend-item-name:mouseleave",action:"ellipsis-text:hide"},{trigger:"legend-item-name:touchend",action:"ellipsis-text:hide"},{trigger:"axis-label:mouseleave",action:"ellipsis-text:hide"},{trigger:"axis-label:touchend",action:"ellipsis-text:hide"}]}),Ae("element-active",{start:[{trigger:"element:mouseenter",action:"element-active:active"}],end:[{trigger:"element:mouseleave",action:"element-active:reset"}]}),Ae("element-selected",{start:[{trigger:"element:click",action:"element-selected:toggle"}]}),Ae("element-highlight",{start:[{trigger:"element:mouseenter",action:"element-highlight:highlight"}],end:[{trigger:"element:mouseleave",action:"element-highlight:reset"}]}),Ae("element-highlight-by-x",{start:[{trigger:"element:mouseenter",action:"element-highlight-by-x:highlight"}],end:[{trigger:"element:mouseleave",action:"element-highlight-by-x:reset"}]}),Ae("element-highlight-by-color",{start:[{trigger:"element:mouseenter",action:"element-highlight-by-color:highlight"}],end:[{trigger:"element:mouseleave",action:"element-highlight-by-color:reset"}]}),Ae("legend-active",{start:[{trigger:"legend-item:mouseenter",action:["list-active:active","element-active:active"]}],end:[{trigger:"legend-item:mouseleave",action:["list-active:reset","element-active:reset"]}]}),Ae("legend-highlight",{start:[{trigger:"legend-item:mouseenter",action:["legend-item-highlight:highlight","element-highlight:highlight"]}],end:[{trigger:"legend-item:mouseleave",action:["legend-item-highlight:reset","element-highlight:reset"]}]}),Ae("axis-label-highlight",{start:[{trigger:"axis-label:mouseenter",action:["axis-label-highlight:highlight","element-highlight:highlight"]}],end:[{trigger:"axis-label:mouseleave",action:["axis-label-highlight:reset","element-highlight:reset"]}]}),Ae("element-list-highlight",{start:[{trigger:"element:mouseenter",action:["list-highlight:highlight","element-highlight:highlight"]}],end:[{trigger:"element:mouseleave",action:["list-highlight:reset","element-highlight:reset"]}]}),Ae("element-range-highlight",{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"mask:mouseenter",action:"cursor:move"},{trigger:"plot:mouseleave",action:"cursor:default"},{trigger:"mask:mouseleave",action:"cursor:crosshair"}],start:[{trigger:"plot:mousedown",isEnable:function(t){return!t.isInShape("mask")},action:["rect-mask:start","rect-mask:show"]},{trigger:"mask:dragstart",action:["rect-mask:moveStart"]}],processing:[{trigger:"plot:mousemove",action:["rect-mask:resize"]},{trigger:"mask:drag",action:["rect-mask:move"]},{trigger:"mask:change",action:["element-range-highlight:highlight"]}],end:[{trigger:"plot:mouseup",action:["rect-mask:end"]},{trigger:"mask:dragend",action:["rect-mask:moveEnd"]},{trigger:"document:mouseup",isEnable:function(t){return!t.isInPlot()},action:["element-range-highlight:clear","rect-mask:end","rect-mask:hide"]}],rollback:[{trigger:"dblclick",action:["element-range-highlight:clear","rect-mask:hide"]}]}),Ae("brush",{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"plot:mouseleave",action:"cursor:default"}],start:[{trigger:"mousedown",isEnable:da,action:["brush:start","rect-mask:start","rect-mask:show"]}],processing:[{trigger:"mousemove",isEnable:da,action:["rect-mask:resize"]}],end:[{trigger:"mouseup",isEnable:da,action:["brush:filter","brush:end","rect-mask:end","rect-mask:hide","reset-button:show"]}],rollback:[{trigger:"reset-button:click",action:["brush:reset","reset-button:hide","cursor:crosshair"]}]}),Ae("brush-visible",{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"plot:mouseleave",action:"cursor:default"}],start:[{trigger:"plot:mousedown",action:["rect-mask:start","rect-mask:show"]}],processing:[{trigger:"plot:mousemove",action:["rect-mask:resize"]},{trigger:"mask:change",action:["element-range-highlight:highlight"]}],end:[{trigger:"plot:mouseup",action:["rect-mask:end","rect-mask:hide","element-filter:filter","element-range-highlight:clear"]}],rollback:[{trigger:"dblclick",action:["element-filter:clear"]}]}),Ae("brush-x",{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"plot:mouseleave",action:"cursor:default"}],start:[{trigger:"mousedown",isEnable:da,action:["brush-x:start","x-rect-mask:start","x-rect-mask:show"]}],processing:[{trigger:"mousemove",isEnable:da,action:["x-rect-mask:resize"]}],end:[{trigger:"mouseup",isEnable:da,action:["brush-x:filter","brush-x:end","x-rect-mask:end","x-rect-mask:hide"]}],rollback:[{trigger:"dblclick",action:["brush-x:reset"]}]}),Ae("element-path-highlight",{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"plot:mouseleave",action:"cursor:default"}],start:[{trigger:"mousedown",isEnable:da,action:"path-mask:start"},{trigger:"mousedown",isEnable:da,action:"path-mask:show"}],processing:[{trigger:"mousemove",action:"path-mask:addPoint"}],end:[{trigger:"mouseup",action:"path-mask:end"}],rollback:[{trigger:"dblclick",action:"path-mask:hide"}]}),Ae("element-single-selected",{start:[{trigger:"element:click",action:"element-single-selected:toggle"}]}),Ae("legend-filter",{showEnable:[{trigger:"legend-item:mouseenter",action:["cursor:pointer","list-radio:show"]},{trigger:"legend-item:mouseleave",action:["cursor:default","list-radio:hide"]}],start:[{trigger:"legend-item:click",isEnable:function(t){return!t.isInShape("legend-item-radio")},action:["list-unchecked:toggle","data-filter:filter","list-radio:show"]},{trigger:"legend-item-radio:mouseenter",action:["list-radio:showTip"]},{trigger:"legend-item-radio:mouseleave",action:["list-radio:hideTip"]},{trigger:"legend-item-radio:click",action:["list-focus:toggle","data-filter:filter","list-radio:show"]}]}),Ae("continuous-filter",{start:[{trigger:"legend:valuechanged",action:"data-filter:filter"}]}),Ae("continuous-visible-filter",{start:[{trigger:"legend:valuechanged",action:"element-filter:filter"}]}),Ae("legend-visible-filter",{showEnable:[{trigger:"legend-item:mouseenter",action:"cursor:pointer"},{trigger:"legend-item:mouseleave",action:"cursor:default"}],start:[{trigger:"legend-item:click",action:["list-unchecked:toggle","element-filter:filter"]}]}),Ae("active-region",{start:[{trigger:"plot:mousemove",action:"active-region:show"}],end:[{trigger:"plot:mouseleave",action:"active-region:hide"}]}),Ae("view-zoom",{start:[{trigger:"plot:mousewheel",isEnable:function(t){return ga(t.event)},action:"scale-zoom:zoomOut",throttle:{wait:100,leading:!0,trailing:!1}},{trigger:"plot:mousewheel",isEnable:function(t){return!ga(t.event)},action:"scale-zoom:zoomIn",throttle:{wait:100,leading:!0,trailing:!1}}]}),Ae("sibling-tooltip",{start:[{trigger:"plot:mousemove",action:"sibling-tooltip:show"}],end:[{trigger:"plot:mouseleave",action:"sibling-tooltip:hide"}]}),Ae("plot-mousewheel-scroll",{start:[{trigger:"plot:mousewheel",action:"mousewheel-scroll:scroll"}]})},function(t,e,n){"use strict";n.r(e),n.d(e,"version",(function(){return v}));var i=n(35);n.d(e,"PathUtil",(function(){return i}));var r=n(96);for(var o in r)["default","Event","Base","AbstractCanvas","AbstractGroup","AbstractShape","PathUtil","getBBoxMethod","registerBBox","getTextHeight","assembleFont","isAllowCapture","multiplyVec2","invert","getOffScreenContext","version"].indexOf(o)<0&&function(t){n.d(e,t,(function(){return r[t]}))}(o);var a=n(97);for(var o in a)["default","Event","Base","AbstractCanvas","AbstractGroup","AbstractShape","PathUtil","getBBoxMethod","registerBBox","getTextHeight","assembleFont","isAllowCapture","multiplyVec2","invert","getOffScreenContext","version"].indexOf(o)<0&&function(t){n.d(e,t,(function(){return a[t]}))}(o);var s=n(67);n.d(e,"Event",(function(){return s.a}));var c=n(68);n.d(e,"Base",(function(){return c.a}));var l=n(172);n.d(e,"AbstractCanvas",(function(){return l.a}));var u=n(98);n.d(e,"AbstractGroup",(function(){return u.a}));var h=n(99);n.d(e,"AbstractShape",(function(){return h.a}));var f=n(94);n.d(e,"getBBoxMethod",(function(){return f.a})),n.d(e,"registerBBox",(function(){return f.b}));var p=n(40);n.d(e,"getTextHeight",(function(){return p.b})),n.d(e,"assembleFont",(function(){return p.a}));var d=n(14);n.d(e,"isAllowCapture",(function(){return d.b}));var g=n(29);n.d(e,"multiplyVec2",(function(){return g.c})),n.d(e,"invert",(function(){return g.a}));var y=n(70);n.d(e,"getOffScreenContext",(function(){return y.a}));var v="0.5.9"},function(t,e,n){"use strict";function i(t,e,n){if(t){if("function"==typeof t.addEventListener)return t.addEventListener(e,n,!1),{remove:function(){t.removeEventListener(e,n,!1)}};if("function"==typeof t.attachEvent)return t.attachEvent("on"+e,n),{remove:function(){t.detachEvent("on"+e,n)}}}}var r,o,a,s;function c(t){r||(r=document.createElement("table"),o=document.createElement("tr"),a=/^\s*<(\w+|!)[^>]*>/,s={tr:document.createElement("tbody"),tbody:r,thead:r,tfoot:r,td:o,th:o,"*":document.createElement("div")});var e=a.test(t)&&RegExp.$1;e&&e in s||(e="*");var n=s[e];t="string"==typeof t?t.replace(/(^\s*)|(\s*$)/g,""):t,n.innerHTML=""+t;var i=n.childNodes[0];return i&&n.contains(i)&&n.removeChild(i),i}function l(t,e,n){var i;try{i=window.getComputedStyle?window.getComputedStyle(t,null)[e]:t.style[e]}catch(t){}finally{i=void 0===i?n:i}return i}function u(t,e){var n=function(t,e){var n=l(t,"height",e);return"auto"===n&&(n=t.offsetHeight),parseFloat(n)}(t,e),i=parseFloat(l(t,"borderTopWidth"))||0,r=parseFloat(l(t,"paddingTop"))||0,o=parseFloat(l(t,"paddingBottom"))||0;return n+i+(parseFloat(l(t,"borderBottomWidth"))||0)+r+o+(parseFloat(l(t,"marginTop"))||0)+(parseFloat(l(t,"marginBottom"))||0)}function h(t,e){var n=function(t,e){var n=l(t,"width",e);return"auto"===n&&(n=t.offsetWidth),parseFloat(n)}(t,e),i=parseFloat(l(t,"borderLeftWidth"))||0,r=parseFloat(l(t,"paddingLeft"))||0,o=parseFloat(l(t,"paddingRight"))||0,a=parseFloat(l(t,"borderRightWidth"))||0,s=parseFloat(l(t,"marginRight"))||0;return n+i+a+r+o+(parseFloat(l(t,"marginLeft"))||0)+s}function f(t,e){if(t)for(var n in e)e.hasOwnProperty(n)&&(t.style[n]=e[n]);return t}n.d(e,"a",(function(){return i})),n.d(e,"b",(function(){return c})),n.d(e,"c",(function(){return u})),n.d(e,"d",(function(){return h})),n.d(e,"e",(function(){return f}))},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.limitInPlot=e.annotation=e.scale=e.scrollbar=e.slider=e.state=e.theme=e.animation=e.interaction=e.tooltip=e.legend=void 0;var i=n(1),r=n(0),o=n(37),a=n(2);e.legend=function(t){var e=t.chart,n=t.options,i=n.legend,r=n.colorField,o=n.seriesField;return!1===i?e.legend(!1):(r||o)&&e.legend(r||o,i),t},e.tooltip=function(t){var e=t.chart,n=t.options.tooltip;return void 0!==n&&e.tooltip(n),t},e.interaction=function(t){var e=t.chart,n=t.options.interactions;return r.each(n,(function(t){!1===t.enable?e.removeInteraction(t.type):e.interaction(t.type,t.cfg||{})})),t},e.animation=function(t){var e=t.chart,n=t.options.animation;return"boolean"==typeof n?e.animate(n):e.animate(!0),r.each(e.geometries,(function(t){t.animate(n)})),t},e.theme=function(t){var e=t.chart,n=t.options.theme;return n&&e.theme(n),t},e.state=function(t){var e=t.chart,n=t.options.state;return n&&r.each(e.geometries,(function(t){t.state(n)})),t},e.slider=function(t){var e=t.chart,n=t.options.slider;return e.option("slider",n),t},e.scrollbar=function(t){var e=t.chart,n=t.options.scrollbar;return e.option("scrollbar",n),t},e.scale=function(t,e){return function(n){var i=n.chart,s=n.options,c={};return r.each(t,(function(t,e){c[e]=a.pick(t,o.AXIS_META_CONFIG_KEYS)})),c=a.deepAssign({},e,s.meta,c),i.scale(c),n}},e.annotation=function(t){return function(e){var n=e.chart,o=e.options,a=n.getController("annotation");return r.each(i.__spreadArrays(o.annotations||[],t||[]),(function(t){a.annotation(t)})),e}},e.limitInPlot=function(t){var e=t.chart,n=t.options,i=n.yAxis,o=n.limitInPlot,s=o;return r.isObject(i)&&r.isNil(o)&&(s=!!Object.values(a.pick(i,["min","max","minLimit","maxLimit"])).some((function(t){return!r.isNil(t)}))),e.limitInPlot=s,t};var s=n(45);Object.defineProperty(e,"pattern",{enumerable:!0,get:function(){return s.pattern}})},function(t,e,n){"use strict";var i=n(1),r=n(0),o=n(71),a=n(21),s=n(4),c=n(50),l=["visible","tip","delegateObject"],u=["container","group","shapesMap","isRegister","isUpdating","destroyed"],h=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(i.__extends)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return Object(i.__assign)(Object(i.__assign)({},e),{container:null,shapesMap:{},group:null,capture:!0,isRegister:!1,isUpdating:!1,isInit:!0})},e.prototype.remove=function(){this.clear(),this.get("group").remove()},e.prototype.clear=function(){this.get("group").clear(),this.set("shapesMap",{}),this.clearOffScreenCache(),this.set("isInit",!0)},e.prototype.getChildComponentById=function(t){var e=this.getElementById(t);return e&&e.get("component")},e.prototype.getElementById=function(t){return this.get("shapesMap")[t]},e.prototype.getElementByLocalId=function(t){var e=this.getElementId(t);return this.getElementById(e)},e.prototype.getElementsByName=function(t){var e=[];return Object(r.each)(this.get("shapesMap"),(function(n){n.get("name")===t&&e.push(n)})),e},e.prototype.getContainer=function(){return this.get("container")},e.prototype.updateInner=function(t){this.offScreenRender(),this.get("updateAutoRender")&&this.render()},e.prototype.render=function(){var t=this.get("offScreenGroup");t||(t=this.offScreenRender());var e=this.get("group");this.updateElements(t,e),this.deleteElements(),this.applyOffset(),this.get("eventInitted")||(this.initEvent(),this.set("eventInitted",!0)),this.set("isInit",!1)},e.prototype.show=function(){this.get("group").show(),this.set("visible",!0)},e.prototype.hide=function(){this.get("group").hide(),this.set("visible",!1)},e.prototype.setCapture=function(t){this.get("group").set("capture",t),this.set("capture",t)},e.prototype.destroy=function(){this.removeEvent(),this.remove(),t.prototype.destroy.call(this)},e.prototype.getBBox=function(){return this.get("group").getCanvasBBox()},e.prototype.getLayoutBBox=function(){var t=this.get("group"),e=this.getInnerLayoutBBox(),n=t.getTotalMatrix();return n&&(e=Object(a.a)(n,e)),e},e.prototype.on=function(t,e,n){return this.get("group").on(t,e,n),this},e.prototype.off=function(t,e){var n=this.get("group");return n&&n.off(t,e),this},e.prototype.emit=function(t,e){this.get("group").emit(t,e)},e.prototype.init=function(){t.prototype.init.call(this),this.get("group")||this.initGroup(),this.offScreenRender()},e.prototype.getInnerLayoutBBox=function(){return this.get("offScreenBBox")||this.get("group").getBBox()},e.prototype.delegateEmit=function(t,e){var n=this.get("group");e.target=n,n.emit(t,e),Object(o.a)(n,t,e)},e.prototype.createOffScreenGroup=function(){return new(this.get("group").getGroupBase())({delegateObject:this.getDelegateObject()})},e.prototype.applyOffset=function(){var t=this.get("offsetX"),e=this.get("offsetY");this.moveElementTo(this.get("group"),{x:t,y:e})},e.prototype.initGroup=function(){var t=this.get("container");this.set("group",t.addGroup({id:this.get("id"),name:this.get("name"),capture:this.get("capture"),visible:this.get("visible"),isComponent:!0,component:this,delegateObject:this.getDelegateObject()}))},e.prototype.offScreenRender=function(){this.clearOffScreenCache();var t=this.createOffScreenGroup();return this.renderInner(t),this.set("offScreenGroup",t),this.set("offScreenBBox",Object(s.d)(t)),t},e.prototype.addGroup=function(t,e){this.appendDelegateObject(t,e);var n=t.addGroup(e);return this.get("isRegister")&&this.registerElement(n),n},e.prototype.addShape=function(t,e){this.appendDelegateObject(t,e);var n=t.addShape(e);return this.get("isRegister")&&this.registerElement(n),n},e.prototype.addComponent=function(t,e){var n=e.id,r=e.component,o=Object(i.__rest)(e,["id","component"]),a=new r(Object(i.__assign)(Object(i.__assign)({},o),{id:n,container:t,updateAutoRender:this.get("updateAutoRender")}));return a.init(),a.render(),this.get("isRegister")&&this.registerElement(a.get("group")),a},e.prototype.initEvent=function(){},e.prototype.removeEvent=function(){this.get("group").off()},e.prototype.getElementId=function(t){return this.get("id")+"-"+this.get("name")+"-"+t},e.prototype.registerElement=function(t){var e=t.get("id");this.get("shapesMap")[e]=t},e.prototype.unregisterElement=function(t){var e=t.get("id");delete this.get("shapesMap")[e]},e.prototype.moveElementTo=function(t,e){var n=Object(a.f)(e);t.attr("matrix",n)},e.prototype.addAnimation=function(t,e,n){var i=e.attr("opacity");Object(r.isNil)(i)&&(i=1),e.attr("opacity",0),e.animate({opacity:i},n)},e.prototype.removeAnimation=function(t,e,n){e.animate({opacity:0},n)},e.prototype.updateAnimation=function(t,e,n,i){e.animate(n,i)},e.prototype.updateElements=function(t,e){var n,i=this,o=this.get("animate"),a=this.get("animateOption"),c=t.getChildren().slice(0);Object(r.each)(c,(function(t){var c=t.get("id"),h=i.getElementById(c),f=t.get("name");if(h)if(t.get("isComponent")){var p=t.get("component"),d=h.get("component"),g=Object(r.pick)(p.cfg,Object(r.difference)(Object(r.keys)(p.cfg),u));d.update(g),h.set("update_status","update")}else{var y=i.getReplaceAttrs(h,t);o&&a.update?i.updateAnimation(f,h,y,a.update):h.attr(y),t.isGroup()&&i.updateElements(t,h),Object(r.each)(l,(function(e){h.set(e,t.get(e))})),Object(s.m)(h,t),n=h,h.set("update_status","update")}else{e.add(t);var v=e.getChildren();if(v.splice(v.length-1,1),n){var m=v.indexOf(n);v.splice(m+1,0,t)}else v.unshift(t);if(i.registerElement(t),t.set("update_status","add"),t.get("isComponent"))(p=t.get("component")).set("container",e);else t.isGroup()&&i.registerNewGroup(t);if(n=t,o){var x=i.get("isInit")?a.appear:a.enter;x&&i.addAnimation(f,t,x)}}}))},e.prototype.clearUpdateStatus=function(t){var e=t.getChildren();Object(r.each)(e,(function(t){t.set("update_status",null)}))},e.prototype.clearOffScreenCache=function(){var t=this.get("offScreenGroup");t&&t.destroy(),this.set("offScreenGroup",null),this.set("offScreenBBox",null)},e.prototype.getDelegateObject=function(){var t;return(t={})[this.get("name")]=this,t.component=this,t},e.prototype.appendDelegateObject=function(t,e){var n=t.get("delegateObject");e.delegateObject||(e.delegateObject={}),Object(r.mix)(e.delegateObject,n)},e.prototype.getReplaceAttrs=function(t,e){var n=t.attr(),i=e.attr();return Object(r.each)(n,(function(t,e){void 0===i[e]&&(i[e]=void 0)})),i},e.prototype.registerNewGroup=function(t){var e=this,n=t.getChildren();Object(r.each)(n,(function(t){e.registerElement(t),t.set("update_status","add"),t.isGroup()&&e.registerNewGroup(t)}))},e.prototype.deleteElements=function(){var t=this,e=this.get("shapesMap"),n=[];Object(r.each)(e,(function(t,e){!t.get("update_status")||t.destroyed?n.push([e,t]):t.set("update_status",null)}));var i=this.get("animate"),o=this.get("animateOption");Object(r.each)(n,(function(n){var a=n[0],s=n[1];if(!s.destroyed){var c=s.get("name");if(i&&o.leave){var l=Object(r.mix)({callback:function(){t.removeElement(s)}},o.leave);t.removeAnimation(c,s,l)}else t.removeElement(s)}delete e[a]}))},e.prototype.removeElement=function(t){if(t.get("isGroup")){var e=t.get("component");e&&e.destroy()}t.remove()},e}(c.a);e.a=h},function(t,e,n){"use strict";n.d(e,"j",(function(){return r})),n.d(e,"c",(function(){return o})),n.d(e,"g",(function(){return a})),n.d(e,"b",(function(){return s}));var i=n(0);function r(t,e){var n=t.indexOf(e);-1!==n&&t.splice(n,1)}n.d(e,"e",(function(){return i.isNil})),n.d(e,"d",(function(){return i.isFunction})),n.d(e,"h",(function(){return i.isString})),n.d(e,"f",(function(){return i.isObject})),n.d(e,"i",(function(){return i.mix})),n.d(e,"a",(function(){return i.each})),n.d(e,"k",(function(){return i.upperFirst}));var o="undefined"!=typeof window&&void 0!==window.document;function a(t,e){if(t.isCanvas())return!0;for(var n=e.getParent(),i=!1;n;){if(n===t){i=!0;break}n=n.getParent()}return i}function s(t){return t.cfg.visible&&t.cfg.capture}},function(t,e,n){"use strict";n.d(e,"e",(function(){return m})),n.d(e,"b",(function(){return j})),n.d(e,"a",(function(){return P})),n.d(e,"c",(function(){return f})),n.d(e,"d",(function(){return B})),n.d(e,"f",(function(){return i}));var i={};function r(t){return Math.min.apply(null,t)}function o(t){return Math.max.apply(null,t)}function a(t,e,n,i){var r=t-n,o=e-i;return Math.sqrt(r*r+o*o)}function s(t,e){return Math.abs(t-e)<.001}function c(t,e){var n=r(t),i=r(e);return{x:n,y:i,width:o(t)-n,height:o(e)-i}}function l(t,e,n,i){return{minX:r([t,n]),maxX:o([t,n]),minY:r([e,i]),maxY:o([e,i])}}function u(t){return(t+2*Math.PI)%(2*Math.PI)}n.r(i),n.d(i,"distance",(function(){return a})),n.d(i,"isNumberEqual",(function(){return s})),n.d(i,"getBBoxByArray",(function(){return c})),n.d(i,"getBBoxRange",(function(){return l})),n.d(i,"piMod",(function(){return u}));var h=n(54),f={box:function(t,e,n,i){return c([t,n],[e,i])},length:function(t,e,n,i){return a(t,e,n,i)},pointAt:function(t,e,n,i,r){return{x:(1-r)*t+r*n,y:(1-r)*e+r*i}},pointDistance:function(t,e,n,i,r,o){var s=(n-t)*(r-t)+(i-e)*(o-e);return s<0?a(t,e,r,o):s>(n-t)*(n-t)+(i-e)*(i-e)?a(n,i,r,o):this.pointToLine(t,e,n,i,r,o)},pointToLine:function(t,e,n,i,r,o){var a=[n-t,i-e];if(h.exactEquals(a,[0,0]))return Math.sqrt((r-t)*(r-t)+(o-e)*(o-e));var s=[-a[1],a[0]];h.normalize(s,s);var c=[r-t,o-e];return Math.abs(h.dot(c,s))},tangentAngle:function(t,e,n,i){return Math.atan2(i-e,n-t)}};function p(t,e,n,i,r,o){var s,c=1/0,l=[n,i],u=20;o&&o>200&&(u=o/10);for(var h=1/u,f=h/10,p=0;p<=u;p++){var d=p*h,g=[r.apply(null,t.concat([d])),r.apply(null,e.concat([d]))];(x=a(l[0],l[1],g[0],g[1]))=0&&x=0?[r]:[]}function y(t,e,n,i){return 2*(1-i)*(e-t)+2*i*(n-e)}function v(t,e,n,i,r,o,a){var s=d(t,n,r,a),c=d(e,i,o,a),l=f.pointAt(t,e,n,i,a),u=f.pointAt(n,i,r,o,a);return[[t,e,l.x,l.y,s,c],[s,c,u.x,u.y,r,o]]}var m={box:function(t,e,n,i,r,o){var a=g(t,n,r)[0],s=g(e,i,o)[0],l=[t,r],u=[e,o];return void 0!==a&&l.push(d(t,n,r,a)),void 0!==s&&u.push(d(e,i,o,s)),c(l,u)},length:function(t,e,n,i,r,o){return function t(e,n,i,r,o,s,c){if(0===c)return(a(e,n,i,r)+a(i,r,o,s)+a(e,n,o,s))/2;var l=v(e,n,i,r,o,s,.5),u=l[0],h=l[1];return u.push(c-1),h.push(c-1),t.apply(null,u)+t.apply(null,h)}(t,e,n,i,r,o,3)},nearestPoint:function(t,e,n,i,r,o,a,s){return p([t,n,r],[e,i,o],a,s,d)},pointDistance:function(t,e,n,i,r,o,s,c){var l=this.nearestPoint(t,e,n,i,r,o,s,c);return a(l.x,l.y,s,c)},interpolationAt:d,pointAt:function(t,e,n,i,r,o,a){return{x:d(t,n,r,a),y:d(e,i,o,a)}},divide:function(t,e,n,i,r,o,a){return v(t,e,n,i,r,o,a)},tangentAngle:function(t,e,n,i,r,o,a){var s=y(t,n,r,a),c=y(e,i,o,a);return u(Math.atan2(c,s))}};function x(t,e,n,i,r){var o=1-r;return o*o*o*t+3*e*r*o*o+3*n*r*r*o+i*r*r*r}function b(t,e,n,i,r){var o=1-r;return 3*(o*o*(e-t)+2*o*r*(n-e)+r*r*(i-n))}function O(t,e,n,i){var r,o,a,c=-3*t+9*e-9*n+3*i,l=6*t-12*e+6*n,u=3*e-3*t,h=[];if(s(c,0))s(l,0)||(r=-u/l)>=0&&r<=1&&h.push(r);else{var f=l*l-4*c*u;s(f,0)?h.push(-l/(2*c)):f>0&&(o=(-l-(a=Math.sqrt(f)))/(2*c),(r=(-l+a)/(2*c))>=0&&r<=1&&h.push(r),o>=0&&o<=1&&h.push(o))}return h}function _(t,e,n,i,r,o,a,s,c){var l=x(t,n,r,a,c),u=x(e,i,o,s,c),h=f.pointAt(t,e,n,i,c),p=f.pointAt(n,i,r,o,c),d=f.pointAt(r,o,a,s,c),g=f.pointAt(h.x,h.y,p.x,p.y,c),y=f.pointAt(p.x,p.y,d.x,d.y,c);return[[t,e,h.x,h.y,g.x,g.y,l,u],[l,u,y.x,y.y,d.x,d.y,a,s]]}function w(t,e,n,i,r,o,s,c,l){if(0===l)return function(t,e){for(var n=0,i=t.length,r=0;r0?n:-1*n}var M=function(t,e,n,i,r,o){var a=n,s=i;if(0===a||0===s)return{x:t,y:e};for(var c,l,u=r-t,h=o-e,f=Math.abs(u),p=Math.abs(h),d=a*a,g=s*s,y=Math.PI/4,v=0;v<4;v++){c=a*Math.cos(y),l=s*Math.sin(y);var m=(d-g)*Math.pow(Math.cos(y),3)/a,x=(g-d)*Math.pow(Math.sin(y),3)/s,b=c-m,O=l-x,_=f-m,w=p-x,j=Math.hypot(O,b),M=Math.hypot(w,_);y+=j*Math.asin((b*w-O*_)/(j*M))/Math.sqrt(d+g-c*c-l*l),y=Math.min(Math.PI/2,Math.max(0,y))}return{x:t+S(c,u),y:e+S(l,h)}};function A(t,e,n,i,r,o){return n*Math.cos(r)*Math.cos(o)-i*Math.sin(r)*Math.sin(o)+t}function C(t,e,n,i,r,o){return n*Math.sin(r)*Math.cos(o)+i*Math.cos(r)*Math.sin(o)+e}function E(t,e,n){return{x:t*Math.cos(n),y:e*Math.sin(n)}}function I(t,e,n){var i=Math.cos(n),r=Math.sin(n);return[t*i-e*r,t*r+e*i]}var P={box:function(t,e,n,i,r,o,a){for(var s=function(t,e,n){return Math.atan(-e/t*Math.tan(n))}(n,i,r),c=1/0,l=-1/0,u=[o,a],h=2*-Math.PI;h<=2*Math.PI;h+=Math.PI){var f=s+h;ol&&(l=p)}var d=function(t,e,n){return Math.atan(e/(t*Math.tan(n)))}(n,i,r),g=1/0,y=-1/0,v=[o,a];for(h=2*-Math.PI;h<=2*Math.PI;h+=Math.PI){var m=d+h;oy&&(y=x)}return{x:c,y:g,width:l-c,height:y-g}},length:function(t,e,n,i,r,o,a){},nearestPoint:function(t,e,n,i,r,o,a,s,c){var l=I(s-t,c-e,-r),u=l[0],h=l[1],f=M(0,0,n,i,u,h),p=function(t,e,n,i){return(Math.atan2(i*t,n*e)+2*Math.PI)%(2*Math.PI)}(n,i,f.x,f.y);pa&&(f=E(n,i,a));var d=I(f.x,f.y,r);return{x:d[0]+t,y:d[1]+e}},pointDistance:function(t,e,n,i,r,o,s,c,l){var u=this.nearestPoint(t,e,n,i,c,l);return a(u.x,u.y,c,l)},pointAt:function(t,e,n,i,r,o,a,s){var c=(a-o)*s+o;return{x:A(t,0,n,i,r,c),y:C(0,e,n,i,r,c)}},tangentAngle:function(t,e,n,i,r,o,a,s){var c=(a-o)*s+o,l=function(t,e,n,i,r,o,a,s){return-1*n*Math.cos(r)*Math.sin(s)-i*Math.sin(r)*Math.cos(s)}(0,0,n,i,r,0,0,c),h=function(t,e,n,i,r,o,a,s){return-1*n*Math.sin(r)*Math.sin(s)+i*Math.cos(r)*Math.cos(s)}(0,0,n,i,r,0,0,c);return u(Math.atan2(h,l))}};function F(t){for(var e=0,n=[],i=0;i1||e<0||t.length<2)return null;var n=F(t),i=n.segments,r=n.totalLength;if(0===r)return{x:t[0][0],y:t[0][1]};for(var o=0,a=null,s=0;s=o&&e<=o+h){var p=(e-o)/h;a=f.pointAt(l[0],l[1],u[0],u[1],p);break}o+=h}return a}function k(t,e){if(e>1||e<0||t.length<2)return 0;for(var n=F(t),i=n.segments,r=n.totalLength,o=0,a=0,s=0;s=o&&e<=o+h){a=Math.atan2(u[1]-l[1],u[0]-l[0]);break}o+=h}return a}function D(t,e,n){for(var i=1/0,r=0;re)n.insertBefore(t,r);else if(o_?O:_,C=O>_?1:O/_,E=O>_?_/O:1;e.translate(x,b),e.rotate(S),e.scale(C,E),e.arc(0,0,A,w,j,1-M),e.scale(1/C,1/E),e.rotate(-S),e.translate(-x,-b)}break;case"Z":e.closePath()}if("Z"===d)l=u;else{var I=p.length;l=[p[I-2],p[I-1]]}}}}function y(t,e){var n=t.get("canvas");n&&("remove"===e&&(t._cacheCanvasBBox=t.get("cacheCanvasBBox")),t.get("hasChanged")||(t.set("hasChanged",!0),t.cfg.parent&&t.cfg.parent.get("hasChanged")||(n.refreshElement(t,e,n),n.get("autoDraw")&&n.draw())))}function v(t){if(!t.length)return null;var e=[],n=[],r=[],o=[];return Object(i.each)(t,(function(t){var i=function(t){var e;if(t.destroyed)e=t._cacheCanvasBBox;else{var n=t.get("cacheCanvasBBox"),i=n&&!(!n.width||!n.height),r=t.getCanvasBBox(),o=r&&!(!r.width||!r.height);i&&o?e=Object(a.l)(n,r):i?e=n:o&&(e=r)}return e}(t);i&&(e.push(i.minX),n.push(i.minY),r.push(i.maxX),o.push(i.maxY))})),{minX:Object(i.min)(e),minY:Object(i.min)(n),maxX:Object(i.max)(r),maxY:Object(i.max)(o)}}function m(t,e){return t&&e&&Object(a.f)(t,e)?{minX:Math.max(t.minX,e.minX),minY:Math.max(t.minY,e.minY),maxX:Math.min(t.maxX,e.maxX),maxY:Math.min(t.maxY,e.maxY)}:null}},function(t,e,n){"use strict";n.d(e,"c",(function(){return f})),n.d(e,"b",(function(){return p})),n.d(e,"a",(function(){return d}));var i=n(1),r=n(36);function o(t){return(o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}var a=Math.sin,s=Math.cos,c=Math.atan2,l=Math.PI;function u(t,e,n,i,o,u,h){var f=e.stroke,p=e.lineWidth,d=c(i-u,n-o),g=new r.Path({type:"path",canvas:t.get("canvas"),isArrowShape:!0,attrs:{path:"M"+10*s(l/6)+","+10*a(l/6)+" L0,0 L"+10*s(l/6)+",-"+10*a(l/6),stroke:f,lineWidth:p}});g.translate(o,u),g.rotateAtPoint(o,u,d),t.set(h?"startArrowShape":"endArrowShape",g)}function h(t,e,n,o,l,u,h){var f=e.startArrow,p=e.endArrow,d=e.stroke,g=e.lineWidth,y=h?f:p,v=y.d,m=y.fill,x=y.stroke,b=y.lineWidth,O=Object(i.__rest)(y,["d","fill","stroke","lineWidth"]),_=c(o-u,n-l);v&&(l-=s(_)*v,u-=a(_)*v);var w=new r.Path({type:"path",canvas:t.get("canvas"),isArrowShape:!0,attrs:Object(i.__assign)(Object(i.__assign)({},O),{stroke:x||d,lineWidth:b||g,fill:m})});w.translate(l,u),w.rotateAtPoint(l,u,_),t.set(h?"startArrowShape":"endArrowShape",w)}function f(t,e,n,i,r){var o=c(i-e,n-t);return{dx:s(o)*r,dy:a(o)*r}}function p(t,e,n,i,r,a){"object"===o(e.startArrow)?h(t,e,n,i,r,a,!0):e.startArrow?u(t,e,n,i,r,a,!0):t.set("startArrowShape",null)}function d(t,e,n,i,r,a){"object"===o(e.endArrow)?h(t,e,n,i,r,a,!1):e.endArrow?u(t,e,n,i,r,a,!1):t.set("startArrowShape",null)}},function(t,e,n){"use strict";n.d(e,"b",(function(){return r})),n.d(e,"c",(function(){return o})),n.d(e,"a",(function(){return a}));var i=n(19);function r(t,e){var n=t.cfg.el,i=t.attr(),r={dx:i.shadowOffsetX,dy:i.shadowOffsetY,blur:i.shadowBlur,color:i.shadowColor};if(r.dx||r.dy||r.blur||r.color){var o=e.find("filter",r);o||(o=e.addShadow(r)),n.setAttribute("filter","url(#"+o+")")}else n.removeAttribute("filter")}function o(t){var e=t.attr().matrix;if(e){for(var n=t.cfg.el,i=[],r=0;r<9;r+=3)i.push(e[r]+","+e[r+1]);-1===(i=i.join(",")).indexOf("NaN")?n.setAttribute("transform","matrix("+i+")"):console.warn("invalid matrix:",e)}}function a(t,e){var n=t.getClip(),r=t.get("el");if(n){if(n&&!r.hasAttribute("clip-path")){Object(i.a)(n),n.createPath(e);var o=e.addClip(n);r.setAttribute("clip-path","url(#"+o+")")}}else r.removeAttribute("clip-path")}},function(t,e,n){"use strict";n.d(e,"b",(function(){return r})),n.d(e,"a",(function(){return o})); /*! ***************************************************************************** Copyright (c) Microsoft Corporation. Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted. THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. ***************************************************************************** */ var i=function(t,e){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)};function r(t,e){function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}var o=function(){return(o=Object.assign||function(t){for(var e,n=1,i=arguments.length;n1){var r=t[0].charAt(0);t.splice(1,0,t[0].substr(1)),t[0]=r}Object(i.each)(t,(function(e,n){isNaN(e)||(t[n]=+e)})),e[n]=t})),e):void 0},s=n(20);var c=function(t,e,n){void 0===e&&(e=!1),void 0===n&&(n=[[0,0],[1,1]]);for(var i=!!e,r=[],o=0,a=t.length;o=3&&(3===t.length&&e.push("Q"),e=e.concat(t[1])),2===t.length&&e.push("L"),e=e.concat(t[t.length-1])}))}(t,e,n));else{var r=[].concat(t);"M"===r[0]&&(r[0]="L");for(var o=0;o<=n-1;o++)i.push(r)}return i}function h(t,e){if(1===t.length)return t;var n=t.length-1,i=e.length-1,r=n/i,o=[];if(1===t.length&&"M"===t[0][0]){for(var a=0;a=0;l--)s=a[l].index,"add"===a[l].type?t.splice(s,0,[].concat(t[s])):t.splice(s,1)}if((r=t.length)0)){t[i]=e[i];break}n=g(n,t[i-1],1)}t[i]=["Q"].concat(n.reduce((function(t,e){return t.concat(e)}),[]));break;case"T":t[i]=["T"].concat(n[0]);break;case"C":if(n.length<3){if(!(i>0)){t[i]=e[i];break}n=g(n,t[i-1],2)}t[i]=["C"].concat(n.reduce((function(t,e){return t.concat(e)}),[]));break;case"S":if(n.length<2){if(!(i>0)){t[i]=e[i];break}n=g(n,t[i-1],1)}t[i]=["S"].concat(n.reduce((function(t,e){return t.concat(e)}),[]));break;default:t[i]=e[i]}return t}function v(t,e,n,i,r){return r?[["M",+t+ +r,e],["l",n-2*r,0],["a",r,r,0,0,1,r,r],["l",0,i-2*r],["a",r,r,0,0,1,-r,r],["l",2*r-n,0],["a",r,r,0,0,1,-r,-r],["l",0,2*r-i],["a",r,r,0,0,1,r,-r],["z"]]:[["M",t,e],["l",n,0],["l",0,i],["l",-n,0],["z"]]}var m="\t\n\v\f\r   ᠎              \u2028\u2029",x=new RegExp("([a-z])["+m+",]*((-?\\d*\\.?\\d*(?:e[\\-+]?\\d+)?["+m+"]*,?["+m+"]*)+)","ig"),b=new RegExp("(-?\\d*\\.?\\d*(?:e[\\-+]?\\d+)?)["+m+"]*,?["+m+"]*","ig");function O(t){if(!t)return null;if(Object(i.isArray)(t))return t;var e={a:7,c:6,o:2,h:1,l:2,m:2,r:4,q:4,s:4,t:2,v:1,u:3,z:0},n=[];return String(t).replace(x,(function(t,i,r){var o=[],a=i.toLowerCase();if(r.replace(b,(function(t,e){e&&o.push(+e)})),"m"===a&&o.length>2&&(n.push([i].concat(o.splice(0,2))),a="l",i="m"===i?"l":"L"),"o"===a&&1===o.length&&n.push([i,o[0]]),"r"===a)n.push([i].concat(o));else for(;o.length>=e[a]&&(n.push([i].concat(o.splice(0,e[a]))),e[a]););return""})),n}var _=/[a-z]/;function w(t,e){return[e[0]+(e[0]-t[0]),e[1]+(e[1]-t[1])]}function j(t){var e=O(t);if(!e||!e.length)return[["M",0,0]];for(var n=!1,i=0;i=0){n=!0;break}}if(!n)return e;var o=[],a=0,s=0,c=0,l=0,u=0,h=e[0];"M"!==h[0]&&"m"!==h[0]||(c=a=+h[1],l=s=+h[2],u++,o[0]=["M",a,s]);i=u;for(var f=e.length;i1&&(r=1),r<-1&&(r=-1),(t*i-e*n<0?-1:1)*Math.acos(r)},E=function(t){var e=t.px,n=t.py,i=t.cx,r=t.cy,o=t.rx,a=t.ry,s=t.xAxisRotation,c=void 0===s?0:s,l=t.largeArcFlag,u=void 0===l?0:l,h=t.sweepFlag,f=void 0===h?0:h,p=[];if(0===o||0===a)return[{x1:0,y1:0,x2:0,y2:0,x:i,y:r}];var d=Math.sin(c*S/360),g=Math.cos(c*S/360),y=g*(e-i)/2+d*(n-r)/2,v=-d*(e-i)/2+g*(n-r)/2;if(0===y&&0===v)return[{x1:0,y1:0,x2:0,y2:0,x:i,y:r}];o=Math.abs(o),a=Math.abs(a);var m=Math.pow(y,2)/Math.pow(o,2)+Math.pow(v,2)/Math.pow(a,2);m>1&&(o*=Math.sqrt(m),a*=Math.sqrt(m));var x=function(t,e,n,i,r,o,a,s,c,l,u,h){var f=Math.pow(r,2),p=Math.pow(o,2),d=Math.pow(u,2),g=Math.pow(h,2),y=f*p-f*g-p*d;y<0&&(y=0),y/=f*g+p*d;var v=(y=Math.sqrt(y)*(a===s?-1:1))*r/o*h,m=y*-o/r*u,x=l*v-c*m+(t+n)/2,b=c*v+l*m+(e+i)/2,O=(u-v)/r,_=(h-m)/o,w=(-u-v)/r,j=(-h-m)/o,M=C(1,0,O,_),A=C(O,_,w,j);return 0===s&&A>0&&(A-=S),1===s&&A<0&&(A+=S),[x,b,M,A]}(e,n,i,r,o,a,u,f,d,g,y,v),b=x[0],O=x[1],_=x[2],w=x[3],j=Math.abs(w)/(S/4);Math.abs(1-j)<1e-7&&(j=1);var E=Math.max(Math.ceil(j),1);w/=E;for(var I=0;I7){t[n].shift();for(var i=t[n],r=n;i.length;)e[n]="A",t.splice(r+=1,0,["C"].concat(i.splice(0,6)));t.splice(n,1)}}var D=function(t,e,n,i,r){return t*(t*(-3*e+9*n-9*i+3*r)+6*e-12*n+6*i)-3*e+3*n},B=function(t,e,n,i,r,o,a,s,c){null===c&&(c=1);for(var l=(c=c>1?1:c<0?0:c)/2,u=[-.1252,.1252,-.3678,.3678,-.5873,.5873,-.7699,.7699,-.9041,.9041,-.9816,.9816],h=[.2491,.2491,.2335,.2335,.2032,.2032,.1601,.1601,.1069,.1069,.0472,.0472],f=0,p=0;p<12;p++){var d=l*u[p]+l,g=D(d,t,n,r,a),y=D(d,e,i,o,s),v=g*g+y*y;f+=h[p]*Math.sqrt(v)}return l*f},R=function(t,e,n,i,r,o,a,s){for(var c,l,u,h,f=[],p=[[],[]],d=0;d<2;++d)if(0===d?(l=6*t-12*n+6*r,c=-3*t+9*n-9*r+3*a,u=3*n-3*t):(l=6*e-12*i+6*o,c=-3*e+9*i-9*o+3*s,u=3*i-3*e),Math.abs(c)<1e-12){if(Math.abs(l)<1e-12)continue;(h=-u/l)>0&&h<1&&f.push(h)}else{var g=l*l-4*u*c,y=Math.sqrt(g);if(!(g<0)){var v=(-l+y)/(2*c);v>0&&v<1&&f.push(v);var m=(-l-y)/(2*c);m>0&&m<1&&f.push(m)}}for(var x,b=f.length,O=b;b--;)x=1-(h=f[b]),p[0][b]=x*x*x*t+3*x*x*h*n+3*x*h*h*r+h*h*h*a,p[1][b]=x*x*x*e+3*x*x*h*i+3*x*h*h*o+h*h*h*s;return p[0][O]=t,p[1][O]=e,p[0][O+1]=a,p[1][O+1]=s,p[0].length=p[1].length=O+2,{min:{x:Math.min.apply(0,p[0]),y:Math.min.apply(0,p[1])},max:{x:Math.max.apply(0,p[0]),y:Math.max.apply(0,p[1])}}},N=function(t,e,n,i,r,o,a,s){if(!(Math.max(t,n)Math.max(r,a)||Math.max(e,i)Math.max(o,s))){var c=(t-n)*(o-s)-(e-i)*(r-a);if(c){var l=((t*i-e*n)*(r-a)-(t-n)*(r*s-o*a))/c,u=((t*i-e*n)*(o-s)-(e-i)*(r*s-o*a))/c,h=+l.toFixed(2),f=+u.toFixed(2);if(!(h<+Math.min(t,n).toFixed(2)||h>+Math.max(t,n).toFixed(2)||h<+Math.min(r,a).toFixed(2)||h>+Math.max(r,a).toFixed(2)||f<+Math.min(e,i).toFixed(2)||f>+Math.max(e,i).toFixed(2)||f<+Math.min(o,s).toFixed(2)||f>+Math.max(o,s).toFixed(2)))return{x:l,y:u}}}},V=function(t,e,n){return e>=t.x&&e<=t.x+t.width&&n>=t.y&&n<=t.y+t.height},z=function(t,e,n,i){return null===t&&(t=e=n=i=0),null===e&&(e=t.y,n=t.width,i=t.height,t=t.x),{x:t,y:e,width:n,w:n,height:i,h:i,x2:t+n,y2:e+i,cx:t+n/2,cy:e+i/2,r1:Math.min(n,i)/2,r2:Math.max(n,i)/2,r0:Math.sqrt(n*n+i*i)/2,path:v(t,e,n,i),vb:[t,e,n,i].join(" ")}},G=function(t,e,n,r,o,a,s,c){Object(i.isArray)(t)||(t=[t,e,n,r,o,a,s,c]);var l=R.apply(null,t);return z(l.min.x,l.min.y,l.max.x-l.min.x,l.max.y-l.min.y)},Y=function(t,e,n,i,r,o,a,s,c){var l=1-c,u=Math.pow(l,3),h=Math.pow(l,2),f=c*c,p=f*c,d=t+2*c*(n-t)+f*(r-2*n+t),g=e+2*c*(i-e)+f*(o-2*i+e),y=n+2*c*(r-n)+f*(a-2*r+n),v=i+2*c*(o-i)+f*(s-2*o+i);return{x:u*t+3*h*c*n+3*l*c*c*r+p*a,y:u*e+3*h*c*i+3*l*c*c*o+p*s,m:{x:d,y:g},n:{x:y,y:v},start:{x:l*t+c*n,y:l*e+c*i},end:{x:l*r+c*a,y:l*o+c*s},alpha:90-180*Math.atan2(d-y,g-v)/Math.PI}},X=function(t,e,n){if(!function(t,e){return t=z(t),e=z(e),V(e,t.x,t.y)||V(e,t.x2,t.y)||V(e,t.x,t.y2)||V(e,t.x2,t.y2)||V(t,e.x,e.y)||V(t,e.x2,e.y)||V(t,e.x,e.y2)||V(t,e.x2,e.y2)||(t.xe.x||e.xt.x)&&(t.ye.y||e.yt.y)}(G(t),G(e)))return n?0:[];for(var i=~~(B.apply(0,t)/8),r=~~(B.apply(0,e)/8),o=[],a=[],s={},c=n?0:[],l=0;l=0&&x<=1&&b>=0&&b<=1&&(n?c++:c.push({x:m.x,y:m.y,t1:x,t2:b}))}}return c};function W(t,e){return function(t,e,n){var i,r,o,a,s,c,l,u,h,f;t=L(t),e=L(e);for(var p=n?0:[],d=0,g=t.length;d1&&(n*=Math.sqrt(d),r*=Math.sqrt(d));var g=n*n*(p*p)+r*r*(f*f),y=g?Math.sqrt((n*n*(r*r)-g)/g):1;a===s&&(y*=-1),isNaN(y)&&(y=0);var v=r?y*n*p/r:0,m=n?y*-r*f/n:0,x=(c+u)/2+Math.cos(o)*v-Math.sin(o)*m,b=(l+h)/2+Math.sin(o)*v+Math.cos(o)*m,O=[(f-v)/n,(p-m)/r],_=[(-1*f-v)/n,(-1*p-m)/r],w=$([1,0],O),j=$(O,_);return Z(O,_)<=-1&&(j=Math.PI),Z(O,_)>=1&&(j=0),0===s&&j>0&&(j-=2*Math.PI),1===s&&j<0&&(j+=2*Math.PI),{cx:x,cy:b,rx:K(t,[u,h])?0:n,ry:K(t,[u,h])?0:r,startAngle:w,endAngle:w+j,xRotation:o,arcFlag:a,sweepFlag:s}}function J(t,e){return[e[0]+(e[0]-t[0]),e[1]+(e[1]-t[1])]}function tt(t){for(var e=[],n=null,i=null,r=null,o=0,s=(t=a(t)).length,c=0;c=e&&t<=n};function nt(t,e,n,i){var r=n.x-t.x,o=n.y-t.y,a=e.x-t.x,s=e.y-t.y,c=i.x-n.x,l=i.y-n.y,u=a*l-s*c,h=null;if(u*u>.001*(a*a+s*s)*(c*c+l*l)){var f=(r*l-o*c)/u,p=(r*s-o*a)/u;et(f,0,1)&&et(p,0,1)&&(h={x:t.x+f*a,y:t.y+f*s})}return h}function it(t){return Math.abs(t)<1e-6?0:t<0?-1:1}function rt(t,e,n){return(n[0]-t[0])*(e[1]-t[1])==(e[0]-t[0])*(n[1]-t[1])&&Math.min(t[0],e[0])<=n[0]&&n[0]<=Math.max(t[0],e[0])&&Math.min(t[1],e[1])<=n[1]&&n[1]<=Math.max(t[1],e[1])}function ot(t,e,n){var i=!1,r=t.length;if(r<=2)return!1;for(var o=0;o0!=it(s[1]-n)>0&&it(e-(n-a[1])*(a[0]-s[0])/(a[1]-s[1])-a[0])<0&&(i=!i)}return i}function at(t){for(var e=[],n=t.length,i=0;i1){var a=t[0],s=t[n-1];e.push({from:{x:s[0],y:s[1]},to:{x:a[0],y:a[1]}})}return e}function st(t){var e=t.map((function(t){return t[0]})),n=t.map((function(t){return t[1]}));return{minX:Math.min.apply(null,e),maxX:Math.max.apply(null,e),minY:Math.min.apply(null,n),maxY:Math.max.apply(null,n)}}function ct(t,e){if(t.length<2||e.length<2)return!1;var n,r,o=st(t),a=st(e);if(n=o,(r=a).minX>n.maxX||r.maxXn.maxY||r.maxY0&&t.charCodeAt(e)<128?1:2}function o(t){if(t.length>400)return function(t){for(var e=t.map((function(t){var e=t.attr("text");return Object(i.isNil)(e)?"":""+e})),n=0,r=0,o=0;o=19968&&c<=40869?2:1}a>n&&(n=a,r=o)}return t[r].getBBox().width}(t);var e=0;return Object(i.each)(t,(function(t){var n=t.getBBox().width;e=0?function(t,e,n){void 0===n&&(n="tail");var i=t.length,o="";if("tail"===n){for(var a=0,s=0;a=0},t.prototype.getAdjustRange=function(t,e,n){var i,r,o=this.yField,a=n.indexOf(e),s=n.length;return!o&&this.isAdjust("y")?(i=0,r=1):s>1?(i=n[0===a?0:a-1],r=n[a===s-1?s-1:a+1],0!==a?i+=(e-i)/2:i-=(r-e)/2,a!==s-1?r-=(r-e)/2:r+=(e-n[s-2])/2):(i=0===e?0:e-.5,r=0===e?1:e+.5),{pre:i,next:r}},t.prototype.adjustData=function(t,e){var n=this,r=this.getDimValues(e);i.each(t,(function(t,e){i.each(r,(function(i,r){n.adjustDim(r,i,t,e)}))}))},t.prototype.groupData=function(t,e){return i.each(t,(function(t){void 0===t[e]&&(t[e]=r.a)})),i.groupBy(t,e)},t.prototype.adjustDim=function(t,e,n,i){},t.prototype.getDimValues=function(t){var e=this.xField,n=this.yField,o=i.assign({},this.dimValuesMap),a=[];if(e&&this.isAdjust("x")&&a.push(e),n&&this.isAdjust("y")&&a.push(n),a.forEach((function(e){o&&o[e]||(o[e]=i.valuesOfKey(t,e).sort((function(t,e){return t-e})))})),!n&&this.isAdjust("y")){o.y=[r.a,1]}return o},t}();e.a=o},function(t,e,n){"use strict";n.d(e,"a",(function(){return l})),n.d(e,"b",(function(){return W})),n.d(e,"c",(function(){return s})),n.d(e,"d",(function(){return et}));var i={};n.r(i),n.d(i,"default",(function(){return k})),n.d(i,"assign",(function(){return g})),n.d(i,"format",(function(){return T})),n.d(i,"parse",(function(){return L})),n.d(i,"defaultI18n",(function(){return x})),n.d(i,"setGlobalDateI18n",(function(){return O})),n.d(i,"setGlobalDateMasks",(function(){return F}));var r=n(0),o={};function a(t,e){o[t]=e}var s=function(){function t(t){this.type="base",this.isCategory=!1,this.isLinear=!1,this.isContinuous=!1,this.isIdentity=!1,this.values=[],this.range=[0,1],this.ticks=[],this.__cfg__=t,this.initCfg(),this.init()}return t.prototype.translate=function(t){return t},t.prototype.change=function(t){Object(r.assign)(this.__cfg__,t),this.init()},t.prototype.clone=function(){return this.constructor(this.__cfg__)},t.prototype.getTicks=function(){var t=this;return Object(r.map)(this.ticks,(function(e,n){return Object(r.isObject)(e)?e:{text:t.getText(e,n),tickValue:e,value:t.scale(e)}}))},t.prototype.getText=function(t,e){var n=this.formatter,i=n?n(t,e):t;return Object(r.isNil)(i)||!Object(r.isFunction)(i.toString)?"":i.toString()},t.prototype.getConfig=function(t){return this.__cfg__[t]},t.prototype.init=function(){Object(r.assign)(this,this.__cfg__),this.setDomain(),Object(r.isEmpty)(this.getConfig("ticks"))&&(this.ticks=this.calculateTicks())},t.prototype.initCfg=function(){},t.prototype.setDomain=function(){},t.prototype.calculateTicks=function(){var t=this.tickMethod,e=[];if(Object(r.isString)(t)){var n=o[t];if(!n)throw new Error("There is no method to to calculate ticks!");e=n(this)}else Object(r.isFunction)(t)&&(e=t(this));return e},t.prototype.rangeMin=function(){return this.range[0]},t.prototype.rangeMax=function(){return this.range[1]},t.prototype.calcPercent=function(t,e,n){return Object(r.isNumber)(t)?(t-e)/(n-e):NaN},t.prototype.calcValue=function(t,e,n){return e+t*(n-e)},t}(),c=n(1),l=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="cat",e.isCategory=!0,e}return Object(c.__extends)(e,t),e.prototype.buildIndexMap=function(){if(!this.translateIndexMap){this.translateIndexMap=new Map;for(var t=0;tthis.max?NaN:this.values[i]},e.prototype.getText=function(e){for(var n=[],i=1;i1?t-1:t}this.translateIndexMap&&(this.translateIndexMap=void 0)},e}(s),u=/d{1,4}|M{1,4}|YY(?:YY)?|S{1,3}|Do|ZZ|Z|([HhMsDm])\1?|[aA]|"[^"]*"|'[^']*'/g,h="[^\\s]+",f=/\[([^]*?)\]/gm;function p(t,e){for(var n=[],i=0,r=t.length;i-1?i:null}};function g(t){for(var e=[],n=1;n3?0:(t-t%10!=10?1:0)*t%10]}},b=g({},x),O=function(t){return b=g(b,t)},_=function(t){return t.replace(/[|\\{()[^$+*?.-]/g,"\\$&")},w=function(t,e){for(void 0===e&&(e=2),t=String(t);t.length0?"-":"+")+w(100*Math.floor(Math.abs(e)/60)+Math.abs(e)%60,4)},Z:function(t){var e=t.getTimezoneOffset();return(e>0?"-":"+")+w(Math.floor(Math.abs(e)/60),2)+":"+w(Math.abs(e)%60,2)}},S=function(t){return+t-1},M=[null,"[1-9]\\d?"],A=[null,h],C=["isPm",h,function(t,e){var n=t.toLowerCase();return n===e.amPm[0]?0:n===e.amPm[1]?1:null}],E=["timezoneOffset","[^\\s]*?[\\+\\-]\\d\\d:?\\d\\d|[^\\s]*?Z?",function(t){var e=(t+"").match(/([+-]|\d\d)/gi);if(e){var n=60*+e[1]+parseInt(e[2],10);return"+"===e[0]?n:-n}return 0}],I={D:["day","[1-9]\\d?"],DD:["day","\\d\\d"],Do:["day","[1-9]\\d?"+h,function(t){return parseInt(t,10)}],M:["month","[1-9]\\d?",S],MM:["month","\\d\\d",S],YY:["year","\\d\\d",function(t){var e=+(""+(new Date).getFullYear()).substr(0,2);return+(""+(+t>68?e-1:e)+t)}],h:["hour","[1-9]\\d?",void 0,"isPm"],hh:["hour","\\d\\d",void 0,"isPm"],H:["hour","[1-9]\\d?"],HH:["hour","\\d\\d"],m:["minute","[1-9]\\d?"],mm:["minute","\\d\\d"],s:["second","[1-9]\\d?"],ss:["second","\\d\\d"],YYYY:["year","\\d{4}"],S:["millisecond","\\d",function(t){return 100*+t}],SS:["millisecond","\\d\\d",function(t){return 10*+t}],SSS:["millisecond","\\d{3}"],d:M,dd:M,ddd:A,dddd:A,MMM:["month",h,d("monthNamesShort")],MMMM:["month",h,d("monthNames")],a:C,A:C,ZZ:E,Z:E},P={default:"ddd MMM DD YYYY HH:mm:ss",shortDate:"M/D/YY",mediumDate:"MMM D, YYYY",longDate:"MMMM D, YYYY",fullDate:"dddd, MMMM D, YYYY",isoDate:"YYYY-MM-DD",isoDateTime:"YYYY-MM-DDTHH:mm:ssZ",shortTime:"HH:mm",mediumTime:"HH:mm:ss",longTime:"HH:mm:ss.SSS"},F=function(t){return g(P,t)},T=function(t,e,n){if(void 0===e&&(e=P.default),void 0===n&&(n={}),"number"==typeof t&&(t=new Date(t)),"[object Date]"!==Object.prototype.toString.call(t)||isNaN(t.getTime()))throw new Error("Invalid Date pass to format");var i=[];e=(e=P[e]||e).replace(f,(function(t,e){return i.push(e),"@@@"}));var r=g(g({},b),n);return(e=e.replace(u,(function(e){return j[e](t,r)}))).replace(/@@@/g,(function(){return i.shift()}))};function L(t,e,n){if(void 0===n&&(n={}),"string"!=typeof e)throw new Error("Invalid format in fecha parse");if(e=P[e]||e,t.length>1e3)return null;var i={year:(new Date).getFullYear(),month:0,day:1,hour:0,minute:0,second:0,millisecond:0,isPm:null,timezoneOffset:null},r=[],o=[],a=e.replace(f,(function(t,e){return o.push(_(e)),"@@@"})),s={},c={};a=_(a).replace(u,(function(t){var e=I[t],n=e[0],i=e[1],o=e[3];if(s[n])throw new Error("Invalid format. "+n+" specified twice in format");return s[n]=!0,o&&(c[o]=!0),r.push(e),"("+i+")"})),Object.keys(c).forEach((function(t){if(!s[t])throw new Error("Invalid format. "+t+" is required in specified format")})),a=a.replace(/@@@/g,(function(){return o.shift()}));var l=t.match(new RegExp(a,"i"));if(!l)return null;for(var h=g(g({},b),n),p=1;p0?new Date(t).getTime():new Date(t.replace(/-/gi,"/")).getTime()),Object(r.isDate)(t)&&(t=t.getTime()),t}var R=36e5,N=24*R,V=31*N,z=[["HH:mm:ss",1e3],["HH:mm:ss",1e4],["HH:mm:ss",3e4],["HH:mm",6e4],["HH:mm",6e5],["HH:mm",18e5],["HH",R],["HH",6*R],["HH",12*R],["YYYY-MM-DD",N],["YYYY-MM-DD",4*N],["YYYY-WW",7*N],["YYYY-MM",V],["YYYY-MM",4*V],["YYYY-MM",6*V],["YYYY",380*N]];function G(t,e,n){var i,o=(i=function(t){return t[1]},function(t,e,n,o){for(var a=Object(r.isNil)(n)?0:n,s=Object(r.isNil)(o)?t.length:o;a>>1;i(t[c])>e?s=c:a=c+1}return a})(z,(e-t)/n)-1,a=z[o];return o<0?a=z[0]:o>=z.length&&(a=Object(r.last)(z)),a}var Y=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="timeCat",e}return Object(c.__extends)(e,t),e.prototype.translate=function(t){t=B(t);var e=this.values.indexOf(t);return-1===e&&(e=Object(r.isNumber)(t)&&t-1){var i=this.values[n],r=this.formatter;return i=r?r(i,e):D(i,this.mask)}return t},e.prototype.initCfg=function(){this.tickMethod="time-cat",this.mask="YYYY-MM-DD",this.tickCount=7},e.prototype.setDomain=function(){var e=this.values;Object(r.each)(e,(function(t,n){e[n]=B(t)})),e.sort((function(t,e){return t-e})),t.prototype.setDomain.call(this)},e}(l),X=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.isContinuous=!0,e}return Object(c.__extends)(e,t),e.prototype.scale=function(t){if(Object(r.isNil)(t))return NaN;var e=this.rangeMin(),n=this.rangeMax();return this.max===this.min?e:e+this.getScalePercent(t)*(n-e)},e.prototype.init=function(){t.prototype.init.call(this);var e=this.ticks,n=Object(r.head)(e),i=Object(r.last)(e);nthis.max&&(this.max=i),Object(r.isNil)(this.minLimit)||(this.min=n),Object(r.isNil)(this.maxLimit)||(this.max=i)},e.prototype.setDomain=function(){var t=Object(r.getRange)(this.values),e=t.min,n=t.max;Object(r.isNil)(this.min)&&(this.min=e),Object(r.isNil)(this.max)&&(this.max=n),this.min>this.max&&(this.min=e,this.max=n)},e.prototype.calculateTicks=function(){var e=this,n=t.prototype.calculateTicks.call(this);return this.nice||(n=Object(r.filter)(n,(function(t){return t>=e.min&&t<=e.max}))),n},e.prototype.getScalePercent=function(t){var e=this.max,n=this.min;return(t-n)/(e-n)},e.prototype.getInvertPercent=function(t){return(t-this.rangeMin())/(this.rangeMax()-this.rangeMin())},e}(s),W=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="linear",e.isLinear=!0,e}return Object(c.__extends)(e,t),e.prototype.invert=function(t){var e=this.getInvertPercent(t);return this.min+e*(this.max-this.min)},e.prototype.initCfg=function(){this.tickMethod="wilkinson-extended",this.nice=!1},e}(X);function H(t,e){var n=Math.E;return e>=0?Math.pow(n,Math.log(e)/t):-1*Math.pow(n,Math.log(-e)/t)}function U(t,e){return 1===t?1:Math.log(e)/Math.log(t)}function q(t,e,n){Object(r.isNil)(n)&&(n=Math.max.apply(null,t));var i=n;return Object(r.each)(t,(function(t){t>0&&t1&&(i=1),i}var Z=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="log",e}return Object(c.__extends)(e,t),e.prototype.invert=function(t){var e,n=this.base,i=U(n,this.max),r=this.rangeMin(),o=this.rangeMax()-r,a=this.positiveMin;if(a){if(0===t)return 0;var s=1/(i-(e=U(n,a/n)))*o;if(t=0?1:-1;return Math.pow(o,n)*a},e.prototype.initCfg=function(){this.tickMethod="pow",this.exponent=2,this.tickCount=5,this.nice=!0},e.prototype.getScalePercent=function(t){var e=this.max,n=this.min;if(e===n)return 0;var i=this.exponent;return(H(i,t)-H(i,n))/(H(i,e)-H(i,n))},e}(X),K=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="time",e}return Object(c.__extends)(e,t),e.prototype.getText=function(t,e){var n=this.translate(t),i=this.formatter;return i?i(n,e):D(n,this.mask)},e.prototype.scale=function(e){var n=e;return(Object(r.isString)(n)||Object(r.isDate)(n))&&(n=this.translate(n)),t.prototype.scale.call(this,n)},e.prototype.translate=function(t){return B(t)},e.prototype.initCfg=function(){this.tickMethod="time-pretty",this.mask="YYYY-MM-DD",this.tickCount=7,this.nice=!1},e.prototype.setDomain=function(){var t=this.values,e=this.getConfig("min"),n=this.getConfig("max");if(Object(r.isNil)(e)&&Object(r.isNumber)(e)||(this.min=this.translate(this.min)),Object(r.isNil)(n)&&Object(r.isNumber)(n)||(this.max=this.translate(this.max)),t&&t.length){var i=[],o=1/0,a=o,s=0;Object(r.each)(t,(function(t){var e=B(t);if(isNaN(e))throw new TypeError("Invalid Time: "+t+" in time scale!");o>e?(a=o,o=e):a>e&&(a=e),s1&&(this.minTickInterval=a-o),Object(r.isNil)(e)&&(this.min=o),Object(r.isNil)(n)&&(this.max=s)}},e}(W),Q=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="quantize",e}return Object(c.__extends)(e,t),e.prototype.invert=function(t){var e=this.ticks,n=e.length,i=this.getInvertPercent(t),o=Math.floor(i*(n-1));if(o>=n-1)return Object(r.last)(e);if(o<0)return Object(r.head)(e);var a=e[o],s=o/(n-1);return a+(i-s)/((o+1)/(n-1)-s)*(e[o+1]-a)},e.prototype.initCfg=function(){this.tickMethod="r-pretty",this.tickCount=5,this.nice=!0},e.prototype.calculateTicks=function(){var e=t.prototype.calculateTicks.call(this);return this.nice||(Object(r.last)(e)!==this.max&&e.push(this.max),Object(r.head)(e)!==this.min&&e.unshift(this.min)),e},e.prototype.getScalePercent=function(t){var e=this.ticks;if(tObject(r.last)(e))return 1;var n=0;return Object(r.each)(e,(function(e,i){if(!(t>=e))return!1;n=i})),n/(e.length-1)},e}(X),J=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="quantile",e}return Object(c.__extends)(e,t),e.prototype.initCfg=function(){this.tickMethod="quantile",this.tickCount=5,this.nice=!0},e}(Q),tt={};function et(t){return tt[t]}function nt(t,e){if(et(t))throw new Error("type '"+t+"' existed.");tt[t]=e}var it=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="identity",e.isIdentity=!0,e}return Object(c.__extends)(e,t),e.prototype.calculateTicks=function(){return this.values},e.prototype.scale=function(t){return this.values[0]!==t&&Object(r.isNumber)(t)?t:this.range[0]},e.prototype.invert=function(t){var e=this.range;return te[1]?NaN:this.values[0]},e}(s);function rt(t){return Math.abs(t)<1e-15?t:parseFloat(t.toFixed(15))}var ot=[1,5,2,2.5,4,3],at=100*Number.EPSILON;function st(t,e,n,i,o,a){var s=Object(r.size)(e),c=Object(r.indexOf)(e,t),l=0,u=function(t,e){return(t%e+e)%e}(i,a);return(u=0&&(l=1),1-c/(s-1)-n+l}function ct(t,e,n){var i=Object(r.size)(e);return 1-Object(r.indexOf)(e,t)/(i-1)-n+1}function lt(t,e,n,i,r,o){var a=(t-1)/(o-r),s=(e-1)/(Math.max(o,i)-Math.min(n,r));return 2-Math.max(a/s,s/a)}function ut(t,e){return t>=e?2-(t-1)/(e-1):1}function ht(t,e,n,i){var r=e-t;return 1-.5*(Math.pow(e-i,2)+Math.pow(t-n,2))/Math.pow(.1*r,2)}function ft(t,e,n){var i=e-t;if(n>i){var r=(n-i)/2;return 1-Math.pow(r,2)/Math.pow(.1*i,2)}return 1}function pt(t,e,n,i,o,a){void 0===n&&(n=5),void 0===i&&(i=!0),void 0===o&&(o=ot),void 0===a&&(a=[.25,.2,.5,.05]);var s=n<0?0:Math.round(n);if(Number.isNaN(t)||Number.isNaN(e)||"number"!=typeof t||"number"!=typeof e||!s)return{min:0,max:0,ticks:[]};if(e-t<1e-15||1===s)return{min:t,max:e,ticks:[t]};for(var c={score:-2,lmin:0,lmax:0,lstep:0},l=1;l<1/0;){for(var u=0;uc.score&&(!i||w<=t&&j>=e)&&(c.lmin=w,c.lmax=j,c.lstep=S,c.score=E)}y+=1}p+=1}}l+=1}var I=rt(c.lmax),P=rt(c.lmin),F=rt(c.lstep),T=Math.floor(function(t){return Math.round(1e12*t)/1e12}((I-P)/F))+1,L=new Array(T);L[0]=rt(P);for(u=1;u=a&&t<=s})).map((function(t){return e[t]}))}return e.slice(a,s+1)}var gt=Math.sqrt(50),yt=Math.sqrt(10),vt=Math.sqrt(2),mt=function(){function t(){this._domain=[0,1]}return t.prototype.domain=function(t){return t?(this._domain=Array.from(t,Number),this):this._domain.slice()},t.prototype.nice=function(t){var e,n;void 0===t&&(t=5);var i,r=this._domain.slice(),o=0,a=this._domain.length-1,s=this._domain[o],c=this._domain[a];return c0?i=xt(s=Math.floor(s/i)*i,c=Math.ceil(c/i)*i,t):i<0&&(i=xt(s=Math.ceil(s*i)/i,c=Math.floor(c*i)/i,t)),i>0?(r[o]=Math.floor(s/i)*i,r[a]=Math.ceil(c/i)*i,this.domain(r)):i<0&&(r[o]=Math.ceil(s*i)/i,r[a]=Math.floor(c*i)/i,this.domain(r)),this},t.prototype.ticks=function(t){return void 0===t&&(t=5),function(t,e,n){var i,r,o,a,s=-1;if(n=+n,(t=+t)===(e=+e)&&n>0)return[t];(i=e0)for(t=Math.ceil(t/a),e=Math.floor(e/a),o=new Array(r=Math.ceil(e-t+1));++s=0?(o>=gt?10:o>=yt?5:o>=vt?2:1)*Math.pow(10,r):-Math.pow(10,-r)/(o>=gt?10:o>=yt?5:o>=vt?2:1)}function bt(t,e,n){return("ceil"===n?Math.ceil(t/e):"floor"===n?Math.floor(t/e):Math.round(t/e))*e}function Ot(t,e,n){var i=bt(t,n,"floor"),o=bt(e,n,"ceil");i=Object(r.fixedBase)(i,n),o=Object(r.fixedBase)(o,n);for(var a=[],s=i;s<=o;s+=n){var c=Object(r.fixedBase)(s,n);a.push(c)}return{min:i,max:o,ticks:a}}function _t(t,e,n){var i,o=t.minLimit,a=t.maxLimit,s=t.min,c=t.max,l=t.tickCount,u=void 0===l?5:l,h=Object(r.isNil)(o)?Object(r.isNil)(e)?s:e:o,f=Object(r.isNil)(a)?Object(r.isNil)(n)?c:n:a;if(h>f&&(f=(i=[h,f])[0],h=i[1]),u<=2)return[h,f];for(var p=(f-h)/(u-1),d=[],g=0;g1&&(r*=Math.ceil(a)),i&&r31536e6)for(var c=St(n),l=Math.ceil(o/31536e6),u=s;u<=c+l;u+=l)a.push(Mt(u));else if(o>V){var h=Math.ceil(o/V),f=At(e),p=function(t,e){var n=St(t),i=St(e),r=At(t);return 12*(i-n)+(At(e)-r)%12}(e,n);for(u=0;u<=p+h;u+=h)a.push(Ct(s,u+f))}else if(o>N){var d=(x=new Date(e)).getFullYear(),g=x.getMonth(),y=x.getDate(),v=Math.ceil(o/N),m=function(t,e){return Math.ceil((e-t)/N)}(e,n);for(u=0;uR){d=(x=new Date(e)).getFullYear(),g=x.getMonth(),v=x.getDate();var x,b=x.getHours(),O=Math.ceil(o/R),_=function(t,e){return Math.ceil((e-t)/R)}(e,n);for(u=0;u<=_+O;u+=O)a.push(new Date(d,g,v,b+u).getTime())}else if(o>6e4){var w=function(t,e){return Math.ceil((e-t)/6e4)}(e,n),j=Math.ceil(o/6e4);for(u=0;u<=w+j;u+=j)a.push(e+6e4*u)}else{var S=o;S<1e3&&(S=1e3);var M=1e3*Math.floor(e/1e3),A=Math.ceil((n-e)/1e3),C=Math.ceil(S/1e3);for(u=0;u=512&&console.warn("Notice: current ticks length("+a.length+') >= 512, may cause performance issues, even out of memory. Because of the configure "tickInterval"(in milliseconds, current is '+o+") is too small, increase the value to solve the problem!"),a})),a("log",(function(t){var e,n=t.base,i=t.tickCount,r=t.min,o=t.max,a=t.values,s=U(n,o);if(r>0)e=Math.floor(U(n,r));else{var c=q(a,n,o);e=Math.floor(U(n,c))}for(var l=s-e,u=Math.ceil(l/i),h=[],f=e;f=0?1:-1;return Math.pow(t,e)*n}))})),a("quantile",(function(t){var e=t.tickCount,n=t.values;if(!n||!n.length)return[];for(var i=n.slice().sort((function(t,e){return t-e})),r=[],o=0;o1?1:Number(e),i=t.length-1,r=Math.floor(i*n),o=i*n-r,a=t[r],s=r===i?a:t[r+1];return l([c(a,s,o,0),c(a,s,o,1),c(a,s,o,2)])}(n,t)}},toRGB:Object(i.memoize)(p),toCSSGradient:function(t){if(/^[r,R,L,l]{1}[\s]*\(/.test(t)){var e,n=void 0;if("l"===t[0]){var r=+(c=o.exec(t))[1]+90;n=c[2],e="linear-gradient("+r+"deg, "}else if("r"===t[0]){var c;e="radial-gradient(",n=(c=a.exec(t))[4]}var l=n.match(s);return Object(i.each)(l,(function(t,n){var i=t.split(":");e+=i[1]+" "+100*i[0]+"%",n!==l.length-1&&(e+=", ")})),e+=")"}return t}}},function(t,e,n){"use strict";n.r(e),n.d(e,"catmullRomToBezier",(function(){return c})),n.d(e,"fillPath",(function(){return I})),n.d(e,"fillPathByDiff",(function(){return T})),n.d(e,"formatPath",(function(){return D})),n.d(e,"intersection",(function(){return A})),n.d(e,"parsePathArray",(function(){return y})),n.d(e,"parsePathString",(function(){return s})),n.d(e,"pathToAbsolute",(function(){return u})),n.d(e,"pathToCurve",(function(){return d})),n.d(e,"rectPath",(function(){return _}));var i=n(0),r="\t\n\v\f\r   ᠎              \u2028\u2029",o=new RegExp("([a-z])["+r+",]*((-?\\d*\\.?\\d*(?:e[\\-+]?\\d+)?["+r+"]*,?["+r+"]*)+)","ig"),a=new RegExp("(-?\\d*\\.?\\d*(?:e[\\-+]?\\d+)?)["+r+"]*,?["+r+"]*","ig"),s=function(t){if(!t)return null;if(Object(i.isArray)(t))return t;var e={a:7,c:6,o:2,h:1,l:2,m:2,r:4,q:4,s:4,t:2,v:1,u:3,z:0},n=[];return String(t).replace(o,(function(i,r,o){var s=[],c=r.toLowerCase();if(o.replace(a,(function(t,e){e&&s.push(+e)})),"m"===c&&s.length>2&&(n.push([r].concat(s.splice(0,2))),c="l",r="m"===r?"l":"L"),"o"===c&&1===s.length&&n.push([r,s[0]]),"r"===c)n.push([r].concat(s));else for(;s.length>=e[c]&&(n.push([r].concat(s.splice(0,e[c]))),e[c]););return t})),n},c=function(t,e){for(var n=[],i=0,r=t.length;r-2*!e>i;i+=2){var o=[{x:+t[i-2],y:+t[i-1]},{x:+t[i],y:+t[i+1]},{x:+t[i+2],y:+t[i+3]},{x:+t[i+4],y:+t[i+5]}];e?i?r-4===i?o[3]={x:+t[0],y:+t[1]}:r-2===i&&(o[2]={x:+t[0],y:+t[1]},o[3]={x:+t[2],y:+t[3]}):o[0]={x:+t[r-2],y:+t[r-1]}:r-4===i?o[3]=o[2]:i||(o[0]={x:+t[i],y:+t[i+1]}),n.push(["C",(-o[0].x+6*o[1].x+o[2].x)/6,(-o[0].y+6*o[1].y+o[2].y)/6,(o[1].x+6*o[2].x-o[3].x)/6,(o[1].y+6*o[2].y-o[3].y)/6,o[2].x,o[2].y])}return n},l=function(t,e,n,i,r){var o=[];if(null===r&&null===i&&(i=n),t=+t,e=+e,n=+n,i=+i,null!==r){var a=Math.PI/180,s=t+n*Math.cos(-i*a),c=t+n*Math.cos(-r*a);o=[["M",s,e+n*Math.sin(-i*a)],["A",n,n,0,+(r-i>180),0,c,e+n*Math.sin(-r*a)]]}else o=[["M",t,e],["m",0,-i],["a",n,i,0,1,1,0,2*i],["a",n,i,0,1,1,0,-2*i],["z"]];return o},u=function(t){if(!(t=s(t))||!t.length)return[["M",0,0]];var e,n,i=[],r=0,o=0,a=0,u=0,h=0;"M"===t[0][0]&&(a=r=+t[0][1],u=o=+t[0][2],h++,i[0]=["M",r,o]);for(var f=3===t.length&&"M"===t[0][0]&&"R"===t[1][0].toUpperCase()&&"Z"===t[2][0].toUpperCase(),p=void 0,d=void 0,g=h,y=t.length;g1&&(i*=_=Math.sqrt(_),r*=_);var w=i*i,j=r*r,S=(a===s?-1:1)*Math.sqrt(Math.abs((w*j-w*O*O-j*b*b)/(w*O*O+j*b*b)));d=S*i*O/r+(e+c)/2,g=S*-r*b/i+(n+l)/2,f=Math.asin(((n-g)/r).toFixed(9)),p=Math.asin(((l-g)/r).toFixed(9)),f=ep&&(f-=2*Math.PI),!s&&p>f&&(p-=2*Math.PI)}var M=p-f;if(Math.abs(M)>y){var A=p,C=c,E=l;p=f+y*(s&&p>f?1:-1),m=t(c=d+i*Math.cos(p),l=g+r*Math.sin(p),i,r,o,0,s,C,E,[p,A,d,g])}M=p-f;var I=Math.cos(f),P=Math.sin(f),F=Math.cos(p),T=Math.sin(p),L=Math.tan(M/4),k=4/3*i*L,D=4/3*r*L,B=[e,n],R=[e+k*P,n-D*I],N=[c+k*T,l-D*F],V=[c,l];if(R[0]=2*B[0]-R[0],R[1]=2*B[1]-R[1],u)return[R,N,V].concat(m);for(var z=[],G=0,Y=(m=[R,N,V].concat(m).join().split(",")).length;G7){t[e].shift();for(var o=t[e];o.length;)s[e]="A",r&&(c[e]="A"),t.splice(e++,0,["C"].concat(o.splice(0,6)));t.splice(e,1),n=Math.max(i.length,r&&r.length||0)}},v=function(t,e,o,a,s){t&&e&&"M"===t[s][0]&&"M"!==e[s][0]&&(e.splice(s,0,["M",a.x,a.y]),o.bx=0,o.by=0,o.x=t[s][1],o.y=t[s][2],n=Math.max(i.length,r&&r.length||0))};n=Math.max(i.length,r&&r.length||0);for(var m=0;m1?1:c<0?0:c)/2,u=[-.1252,.1252,-.3678,.3678,-.5873,.5873,-.7699,.7699,-.9041,.9041,-.9816,.9816],h=[.2491,.2491,.2335,.2335,.2032,.2032,.1601,.1601,.1069,.1069,.0472,.0472],f=0,p=0;p<12;p++){var d=l*u[p]+l,g=v(d,t,n,r,a),y=v(d,e,i,o,s),m=g*g+y*y;f+=h[p]*Math.sqrt(m)}return l*f},x=function(t,e,n,i,r,o,a,s){for(var c,l,u,h,f=[],p=[[],[]],d=0;d<2;++d)if(0===d?(l=6*t-12*n+6*r,c=-3*t+9*n-9*r+3*a,u=3*n-3*t):(l=6*e-12*i+6*o,c=-3*e+9*i-9*o+3*s,u=3*i-3*e),Math.abs(c)<1e-12){if(Math.abs(l)<1e-12)continue;(h=-u/l)>0&&h<1&&f.push(h)}else{var g=l*l-4*u*c,y=Math.sqrt(g);if(!(g<0)){var v=(-l+y)/(2*c);v>0&&v<1&&f.push(v);var m=(-l-y)/(2*c);m>0&&m<1&&f.push(m)}}for(var x,b=f.length,O=b;b--;)x=1-(h=f[b]),p[0][b]=x*x*x*t+3*x*x*h*n+3*x*h*h*r+h*h*h*a,p[1][b]=x*x*x*e+3*x*x*h*i+3*x*h*h*o+h*h*h*s;return p[0][O]=t,p[1][O]=e,p[0][O+1]=a,p[1][O+1]=s,p[0].length=p[1].length=O+2,{min:{x:Math.min.apply(0,p[0]),y:Math.min.apply(0,p[1])},max:{x:Math.max.apply(0,p[0]),y:Math.max.apply(0,p[1])}}},b=function(t,e,n,i,r,o,a,s){if(!(Math.max(t,n)Math.max(r,a)||Math.max(e,i)Math.max(o,s))){var c=(t-n)*(o-s)-(e-i)*(r-a);if(c){var l=((t*i-e*n)*(r-a)-(t-n)*(r*s-o*a))/c,u=((t*i-e*n)*(o-s)-(e-i)*(r*s-o*a))/c,h=+l.toFixed(2),f=+u.toFixed(2);if(!(h<+Math.min(t,n).toFixed(2)||h>+Math.max(t,n).toFixed(2)||h<+Math.min(r,a).toFixed(2)||h>+Math.max(r,a).toFixed(2)||f<+Math.min(e,i).toFixed(2)||f>+Math.max(e,i).toFixed(2)||f<+Math.min(o,s).toFixed(2)||f>+Math.max(o,s).toFixed(2)))return{x:l,y:u}}}},O=function(t,e,n){return e>=t.x&&e<=t.x+t.width&&n>=t.y&&n<=t.y+t.height},_=function(t,e,n,i,r){if(r)return[["M",+t+ +r,e],["l",n-2*r,0],["a",r,r,0,0,1,r,r],["l",0,i-2*r],["a",r,r,0,0,1,-r,r],["l",2*r-n,0],["a",r,r,0,0,1,-r,-r],["l",0,2*r-i],["a",r,r,0,0,1,r,-r],["z"]];var o=[["M",t,e],["l",n,0],["l",0,i],["l",-n,0],["z"]];return o.parsePathArray=y,o},w=function(t,e,n,i){return null===t&&(t=e=n=i=0),null===e&&(e=t.y,n=t.width,i=t.height,t=t.x),{x:t,y:e,width:n,w:n,height:i,h:i,x2:t+n,y2:e+i,cx:t+n/2,cy:e+i/2,r1:Math.min(n,i)/2,r2:Math.max(n,i)/2,r0:Math.sqrt(n*n+i*i)/2,path:_(t,e,n,i),vb:[t,e,n,i].join(" ")}},j=function(t,e,n,r,o,a,s,c){Object(i.isArray)(t)||(t=[t,e,n,r,o,a,s,c]);var l=x.apply(null,t);return w(l.min.x,l.min.y,l.max.x-l.min.x,l.max.y-l.min.y)},S=function(t,e,n,i,r,o,a,s,c){var l=1-c,u=Math.pow(l,3),h=Math.pow(l,2),f=c*c,p=f*c,d=t+2*c*(n-t)+f*(r-2*n+t),g=e+2*c*(i-e)+f*(o-2*i+e),y=n+2*c*(r-n)+f*(a-2*r+n),v=i+2*c*(o-i)+f*(s-2*o+i);return{x:u*t+3*h*c*n+3*l*c*c*r+p*a,y:u*e+3*h*c*i+3*l*c*c*o+p*s,m:{x:d,y:g},n:{x:y,y:v},start:{x:l*t+c*n,y:l*e+c*i},end:{x:l*r+c*a,y:l*o+c*s},alpha:90-180*Math.atan2(d-y,g-v)/Math.PI}},M=function(t,e,n){if(!function(t,e){return t=w(t),e=w(e),O(e,t.x,t.y)||O(e,t.x2,t.y)||O(e,t.x,t.y2)||O(e,t.x2,t.y2)||O(t,e.x,e.y)||O(t,e.x2,e.y)||O(t,e.x,e.y2)||O(t,e.x2,e.y2)||(t.xe.x||e.xt.x)&&(t.ye.y||e.yt.y)}(j(t),j(e)))return n?0:[];for(var i=~~(m.apply(0,t)/8),r=~~(m.apply(0,e)/8),o=[],a=[],s={},c=n?0:[],l=0;l=0&&_<=1&&M>=0&&M<=1&&(n?c+=1:c.push({x:x.x,y:x.y,t1:_,t2:M}))}}return c},A=function(t,e){return function(t,e,n){var i,r,o,a,s,c,l,u,h,f;t=d(t),e=d(e);for(var p=n?0:[],g=0,y=t.length;g=3&&(3===t.length&&e.push("Q"),e=e.concat(t[1])),2===t.length&&e.push("L"),e=e.concat(t[t.length-1])}))}(t,e,n));else{var r=[].concat(t);"M"===r[0]&&(r[0]="L");for(var o=0;o<=n-1;o++)i.push(r)}return i},I=function(t,e){if(1===t.length)return t;var n=t.length-1,i=e.length-1,r=n/i,o=[];if(1===t.length&&"M"===t[0][0]){for(var a=0;a=0;c--)a=o[c].index,"add"===o[c].type?t.splice(a,0,[].concat(t[a])):t.splice(a,1)}var h=r-(i=t.length);if(i0)){t[i]=e[i];break}n=L(n,t[i-1],1)}t[i]=["Q"].concat(n.reduce((function(t,e){return t.concat(e)}),[]));break;case"T":t[i]=["T"].concat(n[0]);break;case"C":if(n.length<3){if(!(i>0)){t[i]=e[i];break}n=L(n,t[i-1],2)}t[i]=["C"].concat(n.reduce((function(t,e){return t.concat(e)}),[]));break;case"S":if(n.length<2){if(!(i>0)){t[i]=e[i];break}n=L(n,t[i-1],1)}t[i]=["S"].concat(n.reduce((function(t,e){return t.concat(e)}),[]));break;default:t[i]=e[i]}return t}},function(t,e,n){"use strict";n.r(e),n.d(e,"Base",(function(){return l})),n.d(e,"Circle",(function(){return u})),n.d(e,"Ellipse",(function(){return f})),n.d(e,"Image",(function(){return d})),n.d(e,"Line",(function(){return m})),n.d(e,"Marker",(function(){return _})),n.d(e,"Path",(function(){return T})),n.d(e,"Polygon",(function(){return k})),n.d(e,"Polyline",(function(){return D})),n.d(e,"Rect",(function(){return R})),n.d(e,"Text",(function(){return N}));var i={};n.r(i),n.d(i,"Base",(function(){return l})),n.d(i,"Circle",(function(){return u})),n.d(i,"Ellipse",(function(){return f})),n.d(i,"Image",(function(){return d})),n.d(i,"Line",(function(){return m})),n.d(i,"Marker",(function(){return _})),n.d(i,"Path",(function(){return T})),n.d(i,"Polygon",(function(){return k})),n.d(i,"Polyline",(function(){return D})),n.d(i,"Rect",(function(){return R})),n.d(i,"Text",(function(){return N}));var r=n(1),o=n(10),a=n(6),s=n(23),c=n(51),l=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(r.__extends)(e,t),e.prototype.getDefaultAttrs=function(){var e=t.prototype.getDefaultAttrs.call(this);return Object(r.__assign)(Object(r.__assign)({},e),{lineWidth:1,lineAppendWidth:0,strokeOpacity:1,fillOpacity:1})},e.prototype.getShapeBase=function(){return i},e.prototype.getGroupBase=function(){return c.a},e.prototype.onCanvasChange=function(t){Object(s.h)(this,t)},e.prototype.calculateBBox=function(){var t=this.get("type"),e=this.getHitLineWidth(),n=Object(o.getBBoxMethod)(t)(this),i=e/2,r=n.x-i,a=n.y-i,s=n.x+n.width+i,c=n.y+n.height+i;return{x:r,minX:r,y:a,minY:a,width:n.width+e,height:n.height+e,maxX:s,maxY:c}},e.prototype.isFill=function(){return!!this.attrs.fill||this.isClipShape()},e.prototype.isStroke=function(){return!!this.attrs.stroke},e.prototype._applyClip=function(t,e){e&&(t.save(),Object(s.a)(t,e),e.createPath(t),t.restore(),t.clip(),e._afterDraw())},e.prototype.draw=function(t,e){var n=this.cfg.clipShape;if(e){if(!1===this.cfg.refresh)return void this.set("hasChanged",!1);var i=this.getCanvasBBox();if(!Object(a.f)(e,i))return this.set("hasChanged",!1),void(this.cfg.isInView&&this._afterDraw())}t.save(),Object(s.a)(t,this),this._applyClip(t,n),this.drawPath(t),t.restore(),this._afterDraw()},e.prototype.getCanvasViewBox=function(){var t=this.cfg.canvas;return t?t.getViewRange():null},e.prototype.cacheCanvasBBox=function(){var t=this.getCanvasViewBox();if(t){var e=this.getCanvasBBox(),n=Object(a.f)(e,t);this.set("isInView",n),n?this.set("cacheCanvasBBox",e):this.set("cacheCanvasBBox",null)}},e.prototype._afterDraw=function(){this.cacheCanvasBBox(),this.set("hasChanged",!1),this.set("refresh",null)},e.prototype.skipDraw=function(){this.set("cacheCanvasBBox",null),this.set("isInView",null),this.set("hasChanged",!1)},e.prototype.drawPath=function(t){this.createPath(t),this.strokeAndFill(t),this.afterDrawPath(t)},e.prototype.fill=function(t){t.fill()},e.prototype.stroke=function(t){t.stroke()},e.prototype.strokeAndFill=function(t){var e=this.attrs,n=e.lineWidth,i=e.opacity,r=e.strokeOpacity,o=e.fillOpacity;this.isFill()&&(Object(a.i)(o)||1===o?this.fill(t):(t.globalAlpha=o,this.fill(t),t.globalAlpha=i)),this.isStroke()&&n>0&&(Object(a.i)(r)||1===r||(t.globalAlpha=r),this.stroke(t)),this.afterDrawPath(t)},e.prototype.createPath=function(t){},e.prototype.afterDrawPath=function(t){},e.prototype.isInShape=function(t,e){var n=this.isStroke(),i=this.isFill(),r=this.getHitLineWidth();return this.isInStrokeOrPath(t,e,n,i,r)},e.prototype.isInStrokeOrPath=function(t,e,n,i,r){return!1},e.prototype.getHitLineWidth=function(){if(!this.isStroke())return 0;var t=this.attrs;return t.lineWidth+t.lineAppendWidth},e}(o.AbstractShape),u=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(r.__extends)(e,t),e.prototype.getDefaultAttrs=function(){var e=t.prototype.getDefaultAttrs.call(this);return Object(r.__assign)(Object(r.__assign)({},e),{x:0,y:0,r:0})},e.prototype.isInStrokeOrPath=function(t,e,n,i,r){var o=this.attr(),s=o.x,c=o.y,l=o.r,u=r/2,h=Object(a.b)(s,c,t,e);return i&&n?h<=l+u:i?h<=l:!!n&&(h>=l-u&&h<=l+u)},e.prototype.createPath=function(t){var e=this.attr(),n=e.x,i=e.y,r=e.r;t.beginPath(),t.arc(n,i,r,0,2*Math.PI,!1),t.closePath()},e}(l);function h(t,e,n,i){return t/(n*n)+e/(i*i)}var f=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(r.__extends)(e,t),e.prototype.getDefaultAttrs=function(){var e=t.prototype.getDefaultAttrs.call(this);return Object(r.__assign)(Object(r.__assign)({},e),{x:0,y:0,rx:0,ry:0})},e.prototype.isInStrokeOrPath=function(t,e,n,i,r){var o=this.attr(),a=r/2,s=o.x,c=o.y,l=o.rx,u=o.ry,f=(t-s)*(t-s),p=(e-c)*(e-c);return i&&n?h(f,p,l+a,u+a)<=1:i?h(f,p,l,u)<=1:!!n&&(h(f,p,l-a,u-a)>=1&&h(f,p,l+a,u+a)<=1)},e.prototype.createPath=function(t){var e=this.attr(),n=e.x,i=e.y,r=e.rx,o=e.ry;if(t.beginPath(),t.ellipse)t.ellipse(n,i,r,o,0,0,2*Math.PI,!1);else{var a=r>o?r:o,s=r>o?1:r/o,c=r>o?o/r:1;t.save(),t.translate(n,i),t.scale(s,c),t.arc(0,0,a,0,2*Math.PI),t.restore(),t.closePath()}},e}(l);function p(t){return t instanceof HTMLElement&&Object(a.k)(t.nodeName)&&"CANVAS"===t.nodeName.toUpperCase()}var d=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(r.__extends)(e,t),e.prototype.getDefaultAttrs=function(){var e=t.prototype.getDefaultAttrs.call(this);return Object(r.__assign)(Object(r.__assign)({},e),{x:0,y:0,width:0,height:0})},e.prototype.initAttrs=function(t){this._setImage(t.img)},e.prototype.isStroke=function(){return!1},e.prototype.isOnlyHitBox=function(){return!0},e.prototype._afterLoading=function(){if(!0===this.get("toDraw")){var t=this.get("canvas");t?t.draw():this.createPath(this.get("context"))}},e.prototype._setImage=function(t){var e=this,n=this.attrs;if(Object(a.k)(t)){var i=new Image;i.onload=function(){if(e.destroyed)return!1;e.attr("img",i),e.set("loading",!1),e._afterLoading();var t=e.get("callback");t&&t.call(e)},i.crossOrigin="Anonymous",i.src=t,this.set("loading",!0)}else t instanceof Image?(n.width||(n.width=t.width),n.height||(n.height=t.height)):p(t)&&(n.width||(n.width=Number(t.getAttribute("width"))),n.height||(n.height,Number(t.getAttribute("height"))))},e.prototype.onAttrChange=function(e,n,i){t.prototype.onAttrChange.call(this,e,n,i),"img"===e&&this._setImage(n)},e.prototype.createPath=function(t){if(this.get("loading"))return this.set("toDraw",!0),void this.set("context",t);var e=this.attr(),n=e.x,i=e.y,r=e.width,o=e.height,s=e.sx,c=e.sy,l=e.swidth,u=e.sheight,h=e.img;(h instanceof Image||p(h))&&(Object(a.i)(s)||Object(a.i)(c)||Object(a.i)(l)||Object(a.i)(u)?t.drawImage(h,n,i,r,o):t.drawImage(h,s,c,l,u,n,i,r,o))},e}(l),g=n(15);function y(t,e,n,i,r,o,a){var s=Math.min(t,n),c=Math.max(t,n),l=Math.min(e,i),u=Math.max(e,i),h=r/2;return o>=s-h&&o<=c+h&&a>=l-h&&a<=u+h&&g.c.pointToLine(t,e,n,i,o,a)<=r/2}var v=n(24),m=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(r.__extends)(e,t),e.prototype.getDefaultAttrs=function(){var e=t.prototype.getDefaultAttrs.call(this);return Object(r.__assign)(Object(r.__assign)({},e),{x1:0,y1:0,x2:0,y2:0,startArrow:!1,endArrow:!1})},e.prototype.initAttrs=function(t){this.setArrow()},e.prototype.onAttrChange=function(e,n,i){t.prototype.onAttrChange.call(this,e,n,i),this.setArrow()},e.prototype.setArrow=function(){var t=this.attr(),e=t.x1,n=t.y1,i=t.x2,r=t.y2,o=t.startArrow,a=t.endArrow;o&&v.b(this,t,i,r,e,n),a&&v.a(this,t,e,n,i,r)},e.prototype.isInStrokeOrPath=function(t,e,n,i,r){if(!n||!r)return!1;var o=this.attr();return y(o.x1,o.y1,o.x2,o.y2,r,t,e)},e.prototype.createPath=function(t){var e=this.attr(),n=e.x1,i=e.y1,r=e.x2,o=e.y2,a=e.startArrow,s=e.endArrow,c={dx:0,dy:0},l={dx:0,dy:0};a&&a.d&&(c=v.c(n,i,r,o,e.startArrow.d)),s&&s.d&&(l=v.c(n,i,r,o,e.endArrow.d)),t.beginPath(),t.moveTo(n+c.dx,i+c.dy),t.lineTo(r-l.dx,o-l.dy)},e.prototype.afterDrawPath=function(t){var e=this.get("startArrowShape"),n=this.get("endArrowShape");e&&e.draw(t),n&&n.draw(t)},e.prototype.getTotalLength=function(){var t=this.attr(),e=t.x1,n=t.y1,i=t.x2,r=t.y2;return g.c.length(e,n,i,r)},e.prototype.getPoint=function(t){var e=this.attr(),n=e.x1,i=e.y1,r=e.x2,o=e.y2;return g.c.pointAt(n,i,r,o,t)},e}(l),x=n(0),b=n(28),O={circle:function(t,e,n){return[["M",t-n,e],["A",n,n,0,1,0,t+n,e],["A",n,n,0,1,0,t-n,e]]},square:function(t,e,n){return[["M",t-n,e-n],["L",t+n,e-n],["L",t+n,e+n],["L",t-n,e+n],["Z"]]},diamond:function(t,e,n){return[["M",t-n,e],["L",t,e-n],["L",t+n,e],["L",t,e+n],["Z"]]},triangle:function(t,e,n){var i=n*Math.sin(1/3*Math.PI);return[["M",t-n,e+i],["L",t,e-i],["L",t+n,e+i],["Z"]]},"triangle-down":function(t,e,n){var i=n*Math.sin(1/3*Math.PI);return[["M",t-n,e-i],["L",t+n,e-i],["L",t,e+i],["Z"]]}},_=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(r.__extends)(e,t),e.prototype.initAttrs=function(t){this._resetParamsCache()},e.prototype._resetParamsCache=function(){this.set("paramsCache",{})},e.prototype.onAttrChange=function(e,n,i){t.prototype.onAttrChange.call(this,e,n,i),-1!==["symbol","x","y","r","radius"].indexOf(e)&&this._resetParamsCache()},e.prototype.isOnlyHitBox=function(){return!0},e.prototype._getR=function(t){return Object(x.isNil)(t.r)?t.radius:t.r},e.prototype._getPath=function(){var t,n,i=this.attr(),r=i.x,o=i.y,s=i.symbol||"circle",c=this._getR(i);if(Object(a.h)(s))n=(t=s)(r,o,c),n=Object(b.path2Absolute)(n);else{if(!(t=e.Symbols[s]))return console.warn(s+" marker is not supported."),null;n=t(r,o,c)}return n},e.prototype.createPath=function(t){var e=this._getPath(),n=this.get("paramsCache");Object(s.e)(this,t,{path:e},n)},e.Symbols=O,e}(l);function w(t,e,n){var i=Object(o.getOffScreenContext)();return t.createPath(i),i.isPointInPath(e,n)}function j(t){return Math.abs(t)<1e-6?0:t<0?-1:1}function S(t,e,n){return(n[0]-t[0])*(e[1]-t[1])==(e[0]-t[0])*(n[1]-t[1])&&Math.min(t[0],e[0])<=n[0]&&n[0]<=Math.max(t[0],e[0])&&Math.min(t[1],e[1])<=n[1]&&n[1]<=Math.max(t[1],e[1])}function M(t,e,n){var i=!1,r=t.length;if(r<=2)return!1;for(var o=0;o0!=j(s[1]-n)>0&&j(e-(n-a[1])*(a[0]-s[0])/(a[1]-s[1])-a[0])<0&&(i=!i)}return i}var A=n(3),C=n(69);function E(t,e,n,i,r,o,s,c){var l=(Math.atan2(c-e,s-t)+2*Math.PI)%(2*Math.PI);if(lr)return!1;var u={x:t+n*Math.cos(l),y:e+n*Math.sin(l)};return Object(a.b)(u.x,u.y,s,c)<=o/2}var I=A.ext.transform;var P=Object(r.__assign)({hasArc:function(t){for(var e=!1,n=t.length,i=0;i0&&i.push(r),{polygons:n,polylines:i}},isPointInStroke:function(t,e,n,i,r){for(var o=!1,s=e/2,c=0;cb?x:b,M=I(null,[["t",-v,-m],["r",-w],["s",1/(x>b?1:x/b),1/(x>b?b/x:1)]]);C.transformMat3(j,j,M),o=E(0,0,S,O,_,e,j[0],j[1])}if(o)break}}return o}},o.PathUtil);function F(t,e,n){for(var i=!1,r=0;r=i[0]&&t<=i[1]&&(e=(t-i[0])/(i[1]-i[0]),n=r)}));var o=r[n];if(Object(x.isNil)(o)||Object(x.isNil)(n))return null;var a=o.length,s=r[n+1];return g.b.pointAt(o[a-2],o[a-1],s[1],s[2],s[3],s[4],s[5],s[6],e)},e.prototype._calculateCurve=function(){var t=this.attr().path;this.set("curve",P.pathToCurve(t))},e.prototype._setTcache=function(){var t,e,n,i,r=0,o=0,a=[],s=this.get("curve");s&&(Object(x.each)(s,(function(t,e){n=s[e+1],i=t.length,n&&(r+=g.b.length(t[i-2],t[i-1],n[1],n[2],n[3],n[4],n[5],n[6])||0)})),this.set("totalLength",r),0!==r?(Object(x.each)(s,(function(c,l){n=s[l+1],i=c.length,n&&((t=[])[0]=o/r,e=g.b.length(c[i-2],c[i-1],n[1],n[2],n[3],n[4],n[5],n[6]),o+=e||0,t[1]=o/r,a.push(t))})),this.set("tCache",a)):this.set("tCache",[]))},e.prototype.getStartTangent=function(){var t,e=this.getSegments();if(e.length>1){var n=e[0].currentPoint,i=e[1].currentPoint,r=e[1].startTangent;t=[],r?(t.push([n[0]-r[0],n[1]-r[1]]),t.push([n[0],n[1]])):(t.push([i[0],i[1]]),t.push([n[0],n[1]]))}return t},e.prototype.getEndTangent=function(){var t,e=this.getSegments(),n=e.length;if(n>1){var i=e[n-2].currentPoint,r=e[n-1].currentPoint,o=e[n-1].endTangent;t=[],o?(t.push([r[0]-o[0],r[1]-o[1]]),t.push([r[0],r[1]])):(t.push([i[0],i[1]]),t.push([r[0],r[1]]))}return t},e}(l);function L(t,e,n,i,r){var o=t.length;if(o<2)return!1;for(var a=0;a=i[0]&&t<=i[1]&&(e=(t-i[0])/(i[1]-i[0]),n=r)})),g.c.pointAt(i[n][0],i[n][1],i[n+1][0],i[n+1][1],e)},e.prototype._setTcache=function(){var t=this.attr().points;if(t&&0!==t.length){var e=this.getTotalLength();if(!(e<=0)){var n,i,r=0,o=[];Object(x.each)(t,(function(a,s){t[s+1]&&((n=[])[0]=r/e,i=g.c.length(a[0],a[1],t[s+1][0],t[s+1][1]),r+=i,n[1]=r/e,o.push(n))})),this.set("tCache",o)}}},e.prototype.getStartTangent=function(){var t=this.attr().points,e=[];return e.push([t[1][0],t[1][1]]),e.push([t[0][0],t[0][1]]),e},e.prototype.getEndTangent=function(){var t=this.attr().points,e=t.length-1,n=[];return n.push([t[e-1][0],t[e-1][1]]),n.push([t[e][0],t[e][1]]),n},e}(l),B=n(76);var R=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(r.__extends)(e,t),e.prototype.getDefaultAttrs=function(){var e=t.prototype.getDefaultAttrs.call(this);return Object(r.__assign)(Object(r.__assign)({},e),{x:0,y:0,width:0,height:0,radius:0})},e.prototype.isInStrokeOrPath=function(t,e,n,i,r){var o=this.attr(),s=o.x,c=o.y,l=o.width,u=o.height,h=o.radius;if(h){var f=!1;return n&&(f=function(t,e,n,i,r,o,a,s){return y(t+r,e,t+n-r,e,o,a,s)||y(t+n,e+r,t+n,e+i-r,o,a,s)||y(t+n-r,e+i,t+r,e+i,o,a,s)||y(t,e+i-r,t,e+r,o,a,s)||E(t+n-r,e+r,r,1.5*Math.PI,2*Math.PI,o,a,s)||E(t+n-r,e+i-r,r,0,.5*Math.PI,o,a,s)||E(t+r,e+i-r,r,.5*Math.PI,Math.PI,o,a,s)||E(t+r,e+r,r,Math.PI,1.5*Math.PI,o,a,s)}(s,c,l,u,h,r,t,e)),!f&&i&&(f=w(this,t,e)),f}var p=r/2;return i&&n?Object(a.e)(s-p,c-p,l+p,u+p,t,e):i?Object(a.e)(s,c,l,u,t,e):n?function(t,e,n,i,r,o,s){var c=r/2;return Object(a.e)(t-c,e-c,n,r,o,s)||Object(a.e)(t+n-c,e-c,r,i,o,s)||Object(a.e)(t+c,e+i-c,n,r,o,s)||Object(a.e)(t-c,e+c,r,i,o,s)}(s,c,l,u,r,t,e):void 0},e.prototype.createPath=function(t){var e=this.attr(),n=e.x,i=e.y,r=e.width,o=e.height,a=e.radius;if(t.beginPath(),0===a)t.rect(n,i,r,o);else{var s=Object(B.a)(a),c=s[0],l=s[1],u=s[2],h=s[3];t.moveTo(n+c,i),t.lineTo(n+r-l,i),0!==l&&t.arc(n+r-l,i+l,l,-Math.PI/2,0),t.lineTo(n+r,i+o-u),0!==u&&t.arc(n+r-u,i+o-u,u,0,Math.PI/2),t.lineTo(n+h,i+o),0!==h&&t.arc(n+h,i+o-h,h,Math.PI/2,Math.PI),t.lineTo(n,i+c),0!==c&&t.arc(n+c,i+c,c,Math.PI,1.5*Math.PI),t.closePath()}},e}(l),N=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(r.__extends)(e,t),e.prototype.getDefaultAttrs=function(){var e=t.prototype.getDefaultAttrs.call(this);return Object(r.__assign)(Object(r.__assign)({},e),{x:0,y:0,text:null,fontSize:12,fontFamily:"sans-serif",fontStyle:"normal",fontWeight:"normal",fontVariant:"normal",textAlign:"start",textBaseline:"bottom"})},e.prototype.isOnlyHitBox=function(){return!0},e.prototype.initAttrs=function(t){this._assembleFont(),t.text&&this._setText(t.text)},e.prototype._assembleFont=function(){var t=this.attrs;t.font=Object(o.assembleFont)(t)},e.prototype._setText=function(t){var e=null;Object(a.k)(t)&&-1!==t.indexOf("\n")&&(e=t.split("\n")),this.set("textArr",e)},e.prototype.onAttrChange=function(e,n,i){t.prototype.onAttrChange.call(this,e,n,i),e.startsWith("font")&&this._assembleFont(),"text"===e&&this._setText(n)},e.prototype._getSpaceingY=function(){var t=this.attrs,e=t.lineHeight,n=1*t.fontSize;return e?e-n:.14*n},e.prototype._drawTextArr=function(t,e,n){var i,r=this.attrs,s=r.textBaseline,c=r.x,l=r.y,u=1*r.fontSize,h=this._getSpaceingY(),f=Object(o.getTextHeight)(r.text,r.fontSize,r.lineHeight);Object(a.c)(e,(function(e,r){i=l+r*(h+u)-f+u,"middle"===s&&(i+=f-u-(f-u)/2),"top"===s&&(i+=f-u),Object(a.i)(e)||(n?t.fillText(e,c,i):t.strokeText(e,c,i))}))},e.prototype._drawText=function(t,e){var n=this.attr(),i=n.x,r=n.y,o=this.get("textArr");if(o)this._drawTextArr(t,o,e);else{var s=n.text;Object(a.i)(s)||(e?t.fillText(s,i,r):t.strokeText(s,i,r))}},e.prototype.strokeAndFill=function(t){var e=this.attrs,n=e.lineWidth,i=e.opacity,r=e.strokeOpacity,o=e.fillOpacity;this.isStroke()&&n>0&&(Object(a.i)(r)||1===r||(t.globalAlpha=i),this.stroke(t)),this.isFill()&&(Object(a.i)(o)||1===o?this.fill(t):(t.globalAlpha=o,this.fill(t),t.globalAlpha=i)),this.afterDrawPath(t)},e.prototype.fill=function(t){this._drawText(t,!0)},e.prototype.stroke=function(t){this._drawText(t,!1)},e}(l)},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.AXIS_META_CONFIG_KEYS=void 0,e.AXIS_META_CONFIG_KEYS=["type","alias","tickCount","tickInterval","min","max","nice","minLimit","maxLimit","range","tickMethod","base","exponent","mask","sync"]},function(t,e,n){"use strict";var i=n(1),r=n(11),o=n(0),a=n(4),s=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(i.__extends)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return Object(i.__assign)(Object(i.__assign)({},e),{container:null,containerTpl:"
",updateAutoRender:!0,containerClassName:"",parent:null})},e.prototype.getContainer=function(){return this.get("container")},e.prototype.show=function(){this.get("container").style.display="",this.set("visible",!0)},e.prototype.hide=function(){this.get("container").style.display="none",this.set("visible",!1)},e.prototype.setCapture=function(t){var e=t?"auto":"none";this.getContainer().style.pointerEvents=e,this.set("capture",t)},e.prototype.getBBox=function(){var t=this.getContainer(),e=parseFloat(t.style.left)||0,n=parseFloat(t.style.top)||0;return Object(a.b)(e,n,t.clientWidth,t.clientHeight)},e.prototype.clear=function(){var t=this.get("container");Object(a.a)(t)},e.prototype.destroy=function(){this.removeEvent(),this.removeDom(),t.prototype.destroy.call(this)},e.prototype.init=function(){t.prototype.init.call(this),this.initContainer(),this.initDom(),this.resetStyles(),this.applyStyles(),this.initEvent(),this.initCapture(),this.initVisible()},e.prototype.initCapture=function(){this.setCapture(this.get("capture"))},e.prototype.initVisible=function(){this.get("visible")?this.show():this.hide()},e.prototype.initDom=function(){},e.prototype.initContainer=function(){var t=this.get("container");if(Object(o.isNil)(t)){t=this.createDom();var e=this.get("parent");Object(o.isString)(e)&&(e=document.getElementById(e),this.set("parent",e)),e.appendChild(t),this.get("containerId")&&t.setAttribute("id",this.get("containerId")),this.set("container",t)}else Object(o.isString)(t)&&(t=document.getElementById(t),this.set("container",t));this.get("parent")||this.set("parent",t.parentNode)},e.prototype.resetStyles=function(){var t=this.get("domStyles"),e=this.get("defaultStyles");t=t?Object(o.deepMix)({},e,t):e,this.set("domStyles",t)},e.prototype.applyStyles=function(){var t=this.get("domStyles");if(t){var e=this.getContainer();this.applyChildrenStyles(e,t);var n=this.get("containerClassName");if(n&&Object(a.h)(e,n)){var i=t[n];Object(r.e)(e,i)}}},e.prototype.applyChildrenStyles=function(t,e){Object(o.each)(e,(function(e,n){var i=t.getElementsByClassName(n);Object(o.each)(i,(function(t){Object(r.e)(t,e)}))}))},e.prototype.applyStyle=function(t,e){var n=this.get("domStyles");Object(r.e)(e,n[t])},e.prototype.createDom=function(){var t=this.get("containerTpl");return Object(r.b)(t)},e.prototype.initEvent=function(){},e.prototype.removeDom=function(){var t=this.get("container");t&&t.parentNode&&t.parentNode.removeChild(t)},e.prototype.removeEvent=function(){},e.prototype.updateInner=function(t){Object(o.hasKey)(t,"domStyles")&&(this.resetStyles(),this.applyStyles()),this.resetPosition()},e.prototype.resetPosition=function(){},e}(n(50).a);e.a=s},function(t,e,n){"use strict";n.d(e,"a",(function(){return i})),n.d(e,"d",(function(){return r})),n.d(e,"b",(function(){return o})),n.d(e,"c",(function(){return a}));var i=0,r=.5,o=.5,a=.05},function(t,e,n){"use strict";n.d(e,"b",(function(){return o})),n.d(e,"c",(function(){return a})),n.d(e,"a",(function(){return s}));var i=n(14),r=n(70);function o(t,e,n){var r=1;return Object(i.h)(t)&&(r=t.split("\n").length),r>1?e*r+function(t,e){return e?e-t:.14*t}(e,n)*(r-1):e}function a(t,e){var n=Object(r.a)(),o=0;if(Object(i.e)(t)||""===t)return o;if(n.save(),n.font=e,Object(i.h)(t)&&t.includes("\n")){var a=t.split("\n");Object(i.a)(a,(function(t){var e=n.measureText(t).width;o0&&(n=n.map((function(t,n){return e.forEach((function(i,r){t+=e[r][n]})),t}))),n}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.pattern=void 0;var i=n(1),r=n(9),o=n(0),a=n(111),s=n(2);e.pattern=function(t){var e=this;return function(n){var c,l=n.options,u=n.chart,h=l.pattern;if(!h)return n;return s.deepAssign({},n,{options:(c={},c[t]=function(n){for(var c,f,p,d=[],g=1;g0&&(e?"stroke"in n?this._setColor(t,"stroke",o):"strokeStyle"in n&&this._setColor(t,"stroke",a):this._setColor(t,"stroke",o||a),c&&h.setAttribute(l.b.strokeOpacity,c),u&&h.setAttribute(l.b.lineWidth,u))},e.prototype._setColor=function(t,e,n){var i=this.get("el");if(n)if(n=n.trim(),/^[r,R,L,l]{1}[\s]*\(/.test(n))(r=t.find("gradient",n))||(r=t.addGradient(n)),i.setAttribute(l.b[e],"url(#"+r+")");else if(/^[p,P]{1}[\s]*\(/.test(n)){var r;(r=t.find("pattern",n))||(r=t.addPattern(n)),i.setAttribute(l.b[e],"url(#"+r+")")}else i.setAttribute(l.b[e],n);else i.setAttribute(l.b[e],"none")},e.prototype.shadow=function(t,e){var n=this.attr(),i=e||n,r=i.shadowOffsetX,o=i.shadowOffsetY,s=i.shadowBlur,c=i.shadowColor;(r||o||s||c)&&Object(a.b)(this,t)},e.prototype.transform=function(t){var e=this.attr();(t||e).matrix&&Object(a.c)(this)},e.prototype.isInShape=function(t,e){return this.isPointInPath(t,e)},e.prototype.isPointInPath=function(t,e){var n=this.get("el"),i=this.get("canvas").get("el").getBoundingClientRect(),r=t+i.left,o=e+i.top,a=document.elementFromPoint(r,o);return!(!a||!a.isEqualNode(n))},e.prototype.getHitLineWidth=function(){var t=this.attrs,e=t.lineWidth,n=t.lineAppendWidth;return this.isStroke()?e+n:0},e}(o.AbstractShape),f=n(0),p=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="circle",e.canFill=!0,e.canStroke=!0,e}return Object(r.__extends)(e,t),e.prototype.getDefaultAttrs=function(){var e=t.prototype.getDefaultAttrs.call(this);return Object(r.__assign)(Object(r.__assign)({},e),{x:0,y:0,r:0})},e.prototype.createPath=function(t,e){var n=this.attr(),i=this.get("el");Object(f.each)(e||n,(function(t,e){"x"===e||"y"===e?i.setAttribute("c"+e,t):l.b[e]&&i.setAttribute(l.b[e],t)}))},e}(h),d=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="dom",e.canFill=!1,e.canStroke=!1,e}return Object(r.__extends)(e,t),e.prototype.createPath=function(t,e){var n=this.attr(),i=this.get("el");if(Object(f.each)(e||n,(function(t,e){l.b[e]&&i.setAttribute(l.b[e],t)})),"function"==typeof n.html){var r=n.html.call(this,n);if(r instanceof Element||r instanceof HTMLDocument){for(var o=i.childNodes,a=o.length-1;a>=0;a--)i.removeChild(o[a]);i.appendChild(r)}else i.innerHTML=r}else i.innerHTML=n.html},e}(h),g=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="ellipse",e.canFill=!0,e.canStroke=!0,e}return Object(r.__extends)(e,t),e.prototype.getDefaultAttrs=function(){var e=t.prototype.getDefaultAttrs.call(this);return Object(r.__assign)(Object(r.__assign)({},e),{x:0,y:0,rx:0,ry:0})},e.prototype.createPath=function(t,e){var n=this.attr(),i=this.get("el");Object(f.each)(e||n,(function(t,e){"x"===e||"y"===e?i.setAttribute("c"+e,t):l.b[e]&&i.setAttribute(l.b[e],t)}))},e}(h),y=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="image",e.canFill=!1,e.canStroke=!1,e}return Object(r.__extends)(e,t),e.prototype.getDefaultAttrs=function(){var e=t.prototype.getDefaultAttrs.call(this);return Object(r.__assign)(Object(r.__assign)({},e),{x:0,y:0,width:0,height:0})},e.prototype.createPath=function(t,e){var n=this,i=this.attr(),r=this.get("el");Object(f.each)(e||i,(function(t,e){"img"===e?n._setImage(i.img):l.b[e]&&r.setAttribute(l.b[e],t)}))},e.prototype.setAttr=function(t,e){this.attrs[t]=e,"img"===t&&this._setImage(e)},e.prototype._setImage=function(t){var e=this.attr(),n=this.get("el");if(Object(f.isString)(t))n.setAttribute("href",t);else if(t instanceof window.Image)e.width||(n.setAttribute("width",t.width),this.attr("width",t.width)),e.height||(n.setAttribute("height",t.height),this.attr("height",t.height)),n.setAttribute("href",t.src);else if(t instanceof HTMLElement&&Object(f.isString)(t.nodeName)&&"CANVAS"===t.nodeName.toUpperCase())n.setAttribute("href",t.toDataURL());else if(t instanceof ImageData){var i=document.createElement("canvas");i.setAttribute("width",""+t.width),i.setAttribute("height",""+t.height),i.getContext("2d").putImageData(t,0,0),e.width||(n.setAttribute("width",""+t.width),this.attr("width",t.width)),e.height||(n.setAttribute("height",""+t.height),this.attr("height",t.height)),n.setAttribute("href",i.toDataURL())}},e}(h),v=n(15),m=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="line",e.canFill=!1,e.canStroke=!0,e}return Object(r.__extends)(e,t),e.prototype.getDefaultAttrs=function(){var e=t.prototype.getDefaultAttrs.call(this);return Object(r.__assign)(Object(r.__assign)({},e),{x1:0,y1:0,x2:0,y2:0,startArrow:!1,endArrow:!1})},e.prototype.createPath=function(t,e){var n=this.attr(),i=this.get("el");Object(f.each)(e||n,(function(e,r){if("startArrow"===r||"endArrow"===r)if(e){var o=Object(f.isObject)(e)?t.addArrow(n,l.b[r]):t.getDefaultArrow(n,l.b[r]);i.setAttribute(l.b[r],"url(#"+o+")")}else i.removeAttribute(l.b[r]);else l.b[r]&&i.setAttribute(l.b[r],e)}))},e.prototype.getTotalLength=function(){var t=this.attr(),e=t.x1,n=t.y1,i=t.x2,r=t.y2;return v.c.length(e,n,i,r)},e.prototype.getPoint=function(t){var e=this.attr(),n=e.x1,i=e.y1,r=e.x2,o=e.y2;return v.c.pointAt(n,i,r,o,t)},e}(h),x={circle:function(t,e,n){return[["M",t,e],["m",-n,0],["a",n,n,0,1,0,2*n,0],["a",n,n,0,1,0,2*-n,0]]},square:function(t,e,n){return[["M",t-n,e-n],["L",t+n,e-n],["L",t+n,e+n],["L",t-n,e+n],["Z"]]},diamond:function(t,e,n){return[["M",t-n,e],["L",t,e-n],["L",t+n,e],["L",t,e+n],["Z"]]},triangle:function(t,e,n){var i=n*Math.sin(1/3*Math.PI);return[["M",t-n,e+i],["L",t,e-i],["L",t+n,e+i],["z"]]},triangleDown:function(t,e,n){var i=n*Math.sin(1/3*Math.PI);return[["M",t-n,e-i],["L",t+n,e-i],["L",t,e+i],["Z"]]}},b={get:function(t){return x[t]},register:function(t,e){x[t]=e},remove:function(t){delete x[t]},getAll:function(){return x}},O=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="marker",e.canFill=!0,e.canStroke=!0,e}return Object(r.__extends)(e,t),e.prototype.createPath=function(t){this.get("el").setAttribute("d",this._assembleMarker())},e.prototype._assembleMarker=function(){var t=this._getPath();return Object(f.isArray)(t)?t.map((function(t){return t.join(" ")})).join(""):t},e.prototype._getPath=function(){var t,e=this.attr(),n=e.x,i=e.y,r=e.r||e.radius,o=e.symbol||"circle";return(t=Object(f.isFunction)(o)?o:b.get(o))?t(n,i,r):(console.warn(t+" symbol is not exist."),null)},e.symbolsFactory=b,e}(h),_=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="path",e.canFill=!0,e.canStroke=!0,e}return Object(r.__extends)(e,t),e.prototype.getDefaultAttrs=function(){var e=t.prototype.getDefaultAttrs.call(this);return Object(r.__assign)(Object(r.__assign)({},e),{startArrow:!1,endArrow:!1})},e.prototype.createPath=function(t,e){var n=this,i=this.attr(),r=this.get("el");Object(f.each)(e||i,(function(e,o){if("path"===o&&Object(f.isArray)(e))r.setAttribute("d",n._formatPath(e));else if("startArrow"===o||"endArrow"===o)if(e){var a=Object(f.isObject)(e)?t.addArrow(i,l.b[o]):t.getDefaultArrow(i,l.b[o]);r.setAttribute(l.b[o],"url(#"+a+")")}else r.removeAttribute(l.b[o]);else l.b[o]&&r.setAttribute(l.b[o],e)}))},e.prototype._formatPath=function(t){var e=t.map((function(t){return t.join(" ")})).join("");return~e.indexOf("NaN")?"":e},e.prototype.getTotalLength=function(){var t=this.get("el");return t?t.getTotalLength():null},e.prototype.getPoint=function(t){var e=this.get("el"),n=this.getTotalLength();if(0===n)return null;var i=e?e.getPointAtLength(t*n):null;return i?{x:i.x,y:i.y}:null},e}(h),w=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="polygon",e.canFill=!0,e.canStroke=!0,e}return Object(r.__extends)(e,t),e.prototype.createPath=function(t,e){var n=this.attr(),i=this.get("el");Object(f.each)(e||n,(function(t,e){"points"===e&&Object(f.isArray)(t)&&t.length>=2?i.setAttribute("points",t.map((function(t){return t[0]+","+t[1]})).join(" ")):l.b[e]&&i.setAttribute(l.b[e],t)}))},e}(h),j=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="polyline",e.canFill=!0,e.canStroke=!0,e}return Object(r.__extends)(e,t),e.prototype.getDefaultAttrs=function(){var e=t.prototype.getDefaultAttrs.call(this);return Object(r.__assign)(Object(r.__assign)({},e),{startArrow:!1,endArrow:!1})},e.prototype.onAttrChange=function(e,n,i){t.prototype.onAttrChange.call(this,e,n,i),-1!==["points"].indexOf(e)&&this._resetCache()},e.prototype._resetCache=function(){this.set("totalLength",null),this.set("tCache",null)},e.prototype.createPath=function(t,e){var n=this.attr(),i=this.get("el");Object(f.each)(e||n,(function(t,e){"points"===e&&Object(f.isArray)(t)&&t.length>=2?i.setAttribute("points",t.map((function(t){return t[0]+","+t[1]})).join(" ")):l.b[e]&&i.setAttribute(l.b[e],t)}))},e.prototype.getTotalLength=function(){var t=this.attr().points,e=this.get("totalLength");return Object(f.isNil)(e)?(this.set("totalLength",v.d.length(t)),this.get("totalLength")):e},e.prototype.getPoint=function(t){var e,n,i=this.attr().points,r=this.get("tCache");return r||(this._setTcache(),r=this.get("tCache")),Object(f.each)(r,(function(i,r){t>=i[0]&&t<=i[1]&&(e=(t-i[0])/(i[1]-i[0]),n=r)})),v.c.pointAt(i[n][0],i[n][1],i[n+1][0],i[n+1][1],e)},e.prototype._setTcache=function(){var t=this.attr().points;if(t&&0!==t.length){var e=this.getTotalLength();if(!(e<=0)){var n,i,r=0,o=[];Object(f.each)(t,(function(a,s){t[s+1]&&((n=[])[0]=r/e,i=v.c.length(a[0],a[1],t[s+1][0],t[s+1][1]),r+=i,n[1]=r/e,o.push(n))})),this.set("tCache",o)}}},e.prototype.getStartTangent=function(){var t=this.attr().points,e=[];return e.push([t[1][0],t[1][1]]),e.push([t[0][0],t[0][1]]),e},e.prototype.getEndTangent=function(){var t=this.attr().points,e=t.length-1,n=[];return n.push([t[e-1][0],t[e-1][1]]),n.push([t[e][0],t[e][1]]),n},e}(h);var S=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="rect",e.canFill=!0,e.canStroke=!0,e}return Object(r.__extends)(e,t),e.prototype.getDefaultAttrs=function(){var e=t.prototype.getDefaultAttrs.call(this);return Object(r.__assign)(Object(r.__assign)({},e),{x:0,y:0,width:0,height:0,radius:0})},e.prototype.createPath=function(t,e){var n=this,i=this.attr(),r=this.get("el"),o=!1,a=["x","y","width","height","radius"];Object(f.each)(e||i,(function(t,e){-1===a.indexOf(e)||o?-1===a.indexOf(e)&&l.b[e]&&r.setAttribute(l.b[e],t):(r.setAttribute("d",n._assembleRect(i)),o=!0)}))},e.prototype._assembleRect=function(t){var e=t.x,n=t.y,i=t.width,r=t.height,o=t.radius;if(!o)return"M "+e+","+n+" l "+i+",0 l 0,"+r+" l"+-i+" 0 z";var a=function(t){var e=0,n=0,i=0,r=0;return Object(f.isArray)(t)?1===t.length?e=n=i=r=t[0]:2===t.length?(e=i=t[0],n=r=t[1]):3===t.length?(e=t[0],n=r=t[1],i=t[2]):(e=t[0],n=t[1],i=t[2],r=t[3]):e=n=i=r=t,{r1:e,r2:n,r3:i,r4:r}}(o);return Object(f.isArray)(o)?1===o.length?a.r1=a.r2=a.r3=a.r4=o[0]:2===o.length?(a.r1=a.r3=o[0],a.r2=a.r4=o[1]):3===o.length?(a.r1=o[0],a.r2=a.r4=o[1],a.r3=o[2]):(a.r1=o[0],a.r2=o[1],a.r3=o[2],a.r4=o[3]):a.r1=a.r2=a.r3=a.r4=o,[["M "+(e+a.r1)+","+n],["l "+(i-a.r1-a.r2)+",0"],["a "+a.r2+","+a.r2+",0,0,1,"+a.r2+","+a.r2],["l 0,"+(r-a.r2-a.r3)],["a "+a.r3+","+a.r3+",0,0,1,"+-a.r3+","+a.r3],["l "+(a.r3+a.r4-i)+",0"],["a "+a.r4+","+a.r4+",0,0,1,"+-a.r4+","+-a.r4],["l 0,"+(a.r4+a.r1-r)],["a "+a.r1+","+a.r1+",0,0,1,"+a.r1+","+-a.r1],["z"]].join(" ")},e}(h),M=n(74),A={top:"before-edge",middle:"central",bottom:"after-edge",alphabetic:"baseline",hanging:"hanging"},C={top:"text-before-edge",middle:"central",bottom:"text-after-edge",alphabetic:"alphabetic",hanging:"hanging"},E={left:"left",start:"left",center:"middle",right:"end",end:"end"},I=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="text",e.canFill=!0,e.canStroke=!0,e}return Object(r.__extends)(e,t),e.prototype.getDefaultAttrs=function(){var e=t.prototype.getDefaultAttrs.call(this);return Object(r.__assign)(Object(r.__assign)({},e),{x:0,y:0,text:null,fontSize:12,fontFamily:"sans-serif",fontStyle:"normal",fontWeight:"normal",fontVariant:"normal",textAlign:"start",textBaseline:"bottom"})},e.prototype.createPath=function(t,e){var n=this,i=this.attr(),r=this.get("el");this._setFont(),Object(f.each)(e||i,(function(t,e){"text"===e?n._setText(""+t):"matrix"===e&&t?Object(a.c)(n):l.b[e]&&r.setAttribute(l.b[e],t)})),r.setAttribute("paint-order","stroke"),r.setAttribute("style","stroke-linecap:butt; stroke-linejoin:miter;")},e.prototype._setFont=function(){var t=this.get("el"),e=this.attr(),n=e.textBaseline,i=e.textAlign,r=Object(M.a)();r&&"firefox"===r.name?t.setAttribute("dominant-baseline",C[n]||"alphabetic"):t.setAttribute("alignment-baseline",A[n]||"baseline"),t.setAttribute("text-anchor",E[i]||"left")},e.prototype._setText=function(t){var e=this.get("el"),n=this.attr(),i=n.x,r=n.textBaseline,o=void 0===r?"bottom":r;if(t)if(~t.indexOf("\n")){var a=t.split("\n"),s=a.length-1,c="";Object(f.each)(a,(function(t,e){0===e?"alphabetic"===o?c+=''+t+"":"top"===o?c+=''+t+"":"middle"===o?c+=''+t+"":"bottom"===o?c+=''+t+"":"hanging"===o&&(c+=''+t+""):c+=''+t+""})),e.innerHTML=c}else e.innerHTML=t;else e.innerHTML=""},e}(h)},function(t,e,n){"use strict";n.r(e),n.d(e,"create",(function(){return r})),n.d(e,"clone",(function(){return o})),n.d(e,"fromValues",(function(){return a})),n.d(e,"copy",(function(){return s})),n.d(e,"set",(function(){return c})),n.d(e,"add",(function(){return l})),n.d(e,"subtract",(function(){return u})),n.d(e,"multiply",(function(){return h})),n.d(e,"divide",(function(){return f})),n.d(e,"ceil",(function(){return p})),n.d(e,"floor",(function(){return d})),n.d(e,"min",(function(){return g})),n.d(e,"max",(function(){return y})),n.d(e,"round",(function(){return v})),n.d(e,"scale",(function(){return m})),n.d(e,"scaleAndAdd",(function(){return x})),n.d(e,"distance",(function(){return b})),n.d(e,"squaredDistance",(function(){return O})),n.d(e,"length",(function(){return _})),n.d(e,"squaredLength",(function(){return w})),n.d(e,"negate",(function(){return j})),n.d(e,"inverse",(function(){return S})),n.d(e,"normalize",(function(){return M})),n.d(e,"dot",(function(){return A})),n.d(e,"cross",(function(){return C})),n.d(e,"lerp",(function(){return E})),n.d(e,"random",(function(){return I})),n.d(e,"transformMat2",(function(){return P})),n.d(e,"transformMat2d",(function(){return F})),n.d(e,"transformMat3",(function(){return T})),n.d(e,"transformMat4",(function(){return L})),n.d(e,"rotate",(function(){return k})),n.d(e,"angle",(function(){return D})),n.d(e,"zero",(function(){return B})),n.d(e,"str",(function(){return R})),n.d(e,"exactEquals",(function(){return N})),n.d(e,"equals",(function(){return V})),n.d(e,"len",(function(){return G})),n.d(e,"sub",(function(){return Y})),n.d(e,"mul",(function(){return X})),n.d(e,"div",(function(){return W})),n.d(e,"dist",(function(){return H})),n.d(e,"sqrDist",(function(){return U})),n.d(e,"sqrLen",(function(){return q})),n.d(e,"forEach",(function(){return Z}));var i=n(16);function r(){var t=new i.a(2);return i.a!=Float32Array&&(t[0]=0,t[1]=0),t}function o(t){var e=new i.a(2);return e[0]=t[0],e[1]=t[1],e}function a(t,e){var n=new i.a(2);return n[0]=t,n[1]=e,n}function s(t,e){return t[0]=e[0],t[1]=e[1],t}function c(t,e,n){return t[0]=e,t[1]=n,t}function l(t,e,n){return t[0]=e[0]+n[0],t[1]=e[1]+n[1],t}function u(t,e,n){return t[0]=e[0]-n[0],t[1]=e[1]-n[1],t}function h(t,e,n){return t[0]=e[0]*n[0],t[1]=e[1]*n[1],t}function f(t,e,n){return t[0]=e[0]/n[0],t[1]=e[1]/n[1],t}function p(t,e){return t[0]=Math.ceil(e[0]),t[1]=Math.ceil(e[1]),t}function d(t,e){return t[0]=Math.floor(e[0]),t[1]=Math.floor(e[1]),t}function g(t,e,n){return t[0]=Math.min(e[0],n[0]),t[1]=Math.min(e[1],n[1]),t}function y(t,e,n){return t[0]=Math.max(e[0],n[0]),t[1]=Math.max(e[1],n[1]),t}function v(t,e){return t[0]=Math.round(e[0]),t[1]=Math.round(e[1]),t}function m(t,e,n){return t[0]=e[0]*n,t[1]=e[1]*n,t}function x(t,e,n,i){return t[0]=e[0]+n[0]*i,t[1]=e[1]+n[1]*i,t}function b(t,e){var n=e[0]-t[0],i=e[1]-t[1];return Math.hypot(n,i)}function O(t,e){var n=e[0]-t[0],i=e[1]-t[1];return n*n+i*i}function _(t){var e=t[0],n=t[1];return Math.hypot(e,n)}function w(t){var e=t[0],n=t[1];return e*e+n*n}function j(t,e){return t[0]=-e[0],t[1]=-e[1],t}function S(t,e){return t[0]=1/e[0],t[1]=1/e[1],t}function M(t,e){var n=e[0],i=e[1],r=n*n+i*i;return r>0&&(r=1/Math.sqrt(r)),t[0]=e[0]*r,t[1]=e[1]*r,t}function A(t,e){return t[0]*e[0]+t[1]*e[1]}function C(t,e,n){var i=e[0]*n[1]-e[1]*n[0];return t[0]=t[1]=0,t[2]=i,t}function E(t,e,n,i){var r=e[0],o=e[1];return t[0]=r+i*(n[0]-r),t[1]=o+i*(n[1]-o),t}function I(t,e){e=e||1;var n=2*i.c()*Math.PI;return t[0]=Math.cos(n)*e,t[1]=Math.sin(n)*e,t}function P(t,e,n){var i=e[0],r=e[1];return t[0]=n[0]*i+n[2]*r,t[1]=n[1]*i+n[3]*r,t}function F(t,e,n){var i=e[0],r=e[1];return t[0]=n[0]*i+n[2]*r+n[4],t[1]=n[1]*i+n[3]*r+n[5],t}function T(t,e,n){var i=e[0],r=e[1];return t[0]=n[0]*i+n[3]*r+n[6],t[1]=n[1]*i+n[4]*r+n[7],t}function L(t,e,n){var i=e[0],r=e[1];return t[0]=n[0]*i+n[4]*r+n[12],t[1]=n[1]*i+n[5]*r+n[13],t}function k(t,e,n,i){var r=e[0]-n[0],o=e[1]-n[1],a=Math.sin(i),s=Math.cos(i);return t[0]=r*s-o*a+n[0],t[1]=r*a+o*s+n[1],t}function D(t,e){var n=t[0],i=t[1],r=e[0],o=e[1],a=Math.sqrt(n*n+i*i)*Math.sqrt(r*r+o*o),s=a&&(n*r+i*o)/a;return Math.acos(Math.min(Math.max(s,-1),1))}function B(t){return t[0]=0,t[1]=0,t}function R(t){return"vec2("+t[0]+", "+t[1]+")"}function N(t,e){return t[0]===e[0]&&t[1]===e[1]}function V(t,e){var n=t[0],r=t[1],o=e[0],a=e[1];return Math.abs(n-o)<=i.b*Math.max(1,Math.abs(n),Math.abs(o))&&Math.abs(r-a)<=i.b*Math.max(1,Math.abs(r),Math.abs(a))}var z,G=_,Y=u,X=h,W=f,H=b,U=O,q=w,Z=(z=r(),function(t,e,n,i,r,o){var a,s;for(e||(e=2),n||(n=0),s=i?Math.min(i*e+n,t.length):t.length,a=n;a
',itemTpl:"{value}",domStyles:{"g2-tooltip":{padding:"2px 4px",fontSize:"10px"}},showCrosshairs:!0,crosshairs:{type:"x"}},e.DEFAULT_OPTIONS={appendPadding:2,tooltip:i.__assign({},e.DEFAULT_TOOLTIP_OPTIONS),animation:{}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DEFAULT_OPTIONS=e.PATH_FIELD=e.ID_FIELD=void 0,e.ID_FIELD="id",e.PATH_FIELD="path",e.DEFAULT_OPTIONS={appendPadding:[10,0,20,0],blendMode:"multiply",tooltip:{showTitle:!1,showMarkers:!1,fields:["id","size"],formatter:function(t){return{name:t.id,value:t.size}}},legend:{position:"top-left"},label:{style:{textAlign:"center",fill:"#fff"}},interactions:[{type:"legend-filter",enable:!1}],state:{active:{style:{stroke:"#000"}},selected:{style:{stroke:"#000",lineWidth:2}},inactive:{style:{fillOpacity:.3,strokeOpacity:.3}}},defaultInteractions:["tooltip","venn-legend-active"]}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getAllNodes=e.getField=e.NODE_ANCESTORS_FIELD=e.CHILD_NODE_COUNT=e.NODE_INDEX_FIELD=void 0;var i=n(0);e.NODE_INDEX_FIELD="nodeIndex",e.CHILD_NODE_COUNT="childNodeCount",e.NODE_ANCESTORS_FIELD="nodeAncestor";e.getField=function(t,e){var n=t.field,r=t.fields;if(i.isString(n))return n;if(i.isArray(n))return console.warn("Invalid field: it must be a string!"),n[0];if(console.warn("Invalid field: it must be a string! will try to get fields instead."),i.isString(r))return r;if(i.isArray(r)&&r.length)return r[0];if(e)return e;throw new TypeError("Invalid field: it must be a string!")},e.getAllNodes=function(t){var n,r,o=[];return t&&t.each?t.each((function(t){var a,s;t.parent!==n?(n=t.parent,r=0):r+=1;var c=i.filter(((null===(a=t.ancestors)||void 0===a?void 0:a.call(t))||[]).map((function(t){return o.find((function(e){return e.name===t.name}))||t})),(function(e){var n=e.depth;return n>0&&n1&&(n*=Math.sqrt(y),r*=Math.sqrt(y));var v=n*n*(g*g)+r*r*(d*d),m=v?Math.sqrt((n*n*(r*r)-v)/v):1;c===l&&(m*=-1),isNaN(m)&&(m=0);var x=r?m*n*g/r:0,b=n?m*-r*d/n:0,O=(u+f)/2+Math.cos(s)*x-Math.sin(s)*b,_=(h+p)/2+Math.sin(s)*x+Math.cos(s)*b,w=[(d-x)/n,(g-b)/r],j=[(-1*d-x)/n,(-1*g-b)/r],S=a([1,0],w),M=a(w,j);return o(w,j)<=-1&&(M=Math.PI),o(w,j)>=1&&(M=0),0===l&&M>0&&(M-=2*Math.PI),1===l&&M<0&&(M+=2*Math.PI),{cx:O,cy:_,rx:Object(i.j)(t,[f,p])?0:n,ry:Object(i.j)(t,[f,p])?0:r,startAngle:S,endAngle:S+M,xRotation:s,arcFlag:c,sweepFlag:l}}},function(t,e){},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getLocale=e.registerLocale=void 0;var i=n(0),r=n(2),o=n(107),a={};e.registerLocale=function(t,e){a[t]=e},e.getLocale=function(t){return{get:function(e,n){return r.template(i.get(a[t],e)||i.get(a[o.GLOBAL.locale],e)||i.get(a["en-US"],e)||e,n)}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.processIllegalData=e.transformDataToNodeLinkData=e.adjustYMetaByZero=void 0;var i=n(1),r=n(0),o=n(103),a=n(102);e.adjustYMetaByZero=function(t,e){if(!t)return{};var n=t.filter((function(t){var n=r.get(t,[e]);return r.isNumber(n)&&!isNaN(n)})),i=n.every((function(t){return r.get(t,[e])>=0})),o=n.every((function(t){return r.get(t,[e])<=0}));return i?{min:0}:o?{max:0}:{}},e.transformDataToNodeLinkData=function(t,e,n,r,o){if(void 0===o&&(o=[]),!Array.isArray(t))return{nodes:[],links:[]};var s=[],c={},l=-1;return t.forEach((function(t){var u=t[e],h=t[n],f=t[r],p=a.pick(t,o);c[u]||(c[u]=i.__assign({id:++l,name:u},p)),c[h]||(c[h]=i.__assign({id:++l,name:h},p)),s.push(i.__assign({source:c[u].id,target:c[h].id,value:f},p))})),{nodes:Object.values(c).sort((function(t,e){return t.id-e.id})),links:s}},e.processIllegalData=function(t,e){var n=r.filter(t,(function(t){var n=t[e];return null===n||"number"==typeof n&&!isNaN(n)}));return o.log(o.LEVEL.WARN,n.length===t.length,"illegal data existed in chart data."),n}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.adaptor=e.meta=void 0;var i=n(12),r=n(2),o=n(18),a=n(56),s=n(47),c=n(63);function l(t){var e=t.chart,n=t.options,i=n.data,c=n.color,l=n.areaStyle,u=n.point,h=n.line,f=null==u?void 0:u.state,p=s.getTinyData(i);e.data(p);var d=r.deepAssign({},t,{options:{xField:a.X_FIELD,yField:a.Y_FIELD,area:{color:c,style:l},line:h,point:u}}),g=r.deepAssign({},d,{options:{tooltip:!1}}),y=r.deepAssign({},d,{options:{tooltip:!1,state:f}});return o.area(d),o.line(g),o.point(y),e.axis(!1),e.legend(!1),t}function u(t){var e,n,o=t.options,l=o.xAxis,u=o.yAxis,h=o.data,f=s.getTinyData(h);return r.flow(i.scale(((e={})[a.X_FIELD]=l,e[a.Y_FIELD]=u,e),((n={})[a.X_FIELD]={type:"cat"},n[a.Y_FIELD]=c.adjustYMetaByZero(f,a.Y_FIELD),n)))(t)}e.meta=u,e.adaptor=function(t){return r.flow(i.pattern("areaStyle"),l,u,i.tooltip,i.theme,i.animation,i.annotation())(t)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DrillDownAction=e.HIERARCHY_DATA_TRANSFORM_PARAMS=e.DEFAULT_BREAD_CRUMB_CONFIG=e.BREAD_CRUMB_NAME=e.PADDING_TOP=void 0;var i=n(1),r=n(9),o=n(0),a=n(105);e.PADDING_TOP=5,e.BREAD_CRUMB_NAME="drilldown-bread-crumb",e.DEFAULT_BREAD_CRUMB_CONFIG={position:"top-left",dividerText:"/",textStyle:{fontSize:12,fill:"rgba(0, 0, 0, 0.65)",cursor:"pointer"},activeTextStyle:{fill:"#87B5FF"}},e.HIERARCHY_DATA_TRANSFORM_PARAMS="hierarchy-data-transform-params";var s=function(t){function n(){var n=null!==t&&t.apply(this,arguments)||this;return n.name="drill-down",n.historyCache=[],n.breadCrumbGroup=null,n.breadCrumbCfg=e.DEFAULT_BREAD_CRUMB_CONFIG,n}return i.__extends(n,t),n.prototype.click=function(){var t=o.get(this.context,["event","data","data"]);if(!t)return!1;this.drill(t),this.drawBreadCrumb()},n.prototype.resetPosition=function(){if(this.breadCrumbGroup){var t=this.context.view.getCoordinate(),n=this.breadCrumbGroup,i=n.getBBox(),o=this.getButtonCfg().position,a={x:t.start.x,y:t.end.y-(i.height+2*e.PADDING_TOP)};t.isPolar&&(a={x:0,y:0}),"bottom-left"===o&&(a={x:t.start.x,y:t.start.y});var s=r.Util.transform(null,[["t",a.x+0,a.y+i.height+e.PADDING_TOP]]);n.setMatrix(s)}},n.prototype.back=function(){o.size(this.historyCache)&&this.backTo(this.historyCache.slice(0,-1))},n.prototype.reset=function(){this.historyCache[0]&&this.backTo(this.historyCache.slice(0,1)),this.historyCache=[],this.hideCrumbGroup()},n.prototype.drill=function(t){var n=this.context.view,r=o.get(n,["interactions","drill-down","cfg","transformData"],(function(t){return t})),a=r(i.__assign({data:t.data},t[e.HIERARCHY_DATA_TRANSFORM_PARAMS]));n.changeData(a);for(var s=[],c=t;c;){var l=c.data;s.unshift({id:l.name+"_"+c.height+"_"+c.depth,name:l.name,children:r(i.__assign({data:l},t[e.HIERARCHY_DATA_TRANSFORM_PARAMS]))}),c=c.parent}this.historyCache=(this.historyCache||[]).slice(0,-1).concat(s)},n.prototype.backTo=function(t){if(t&&!(t.length<=0)){var e=this.context.view,n=o.last(t).children;e.changeData(n),t.length>1?(this.historyCache=t,this.drawBreadCrumb()):(this.historyCache=[],this.hideCrumbGroup())}},n.prototype.getButtonCfg=function(){var t=this.context.view,e=o.get(t,["interactions","drill-down","cfg","drillDownConfig"]);return a.deepAssign(this.breadCrumbCfg,null==e?void 0:e.breadCrumb,this.cfg)},n.prototype.drawBreadCrumb=function(){this.drawBreadCrumbGroup(),this.resetPosition(),this.breadCrumbGroup.show()},n.prototype.drawBreadCrumbGroup=function(){var t=this,n=this.getButtonCfg(),r=this.historyCache;this.breadCrumbGroup?this.breadCrumbGroup.clear():this.breadCrumbGroup=this.context.view.foregroundGroup.addGroup({name:e.BREAD_CRUMB_NAME});var a=0;r.forEach((function(s,c){var l=t.breadCrumbGroup.addShape({type:"text",id:s.id,name:e.BREAD_CRUMB_NAME+"_"+s.name+"_text",attrs:i.__assign(i.__assign({text:0!==c||o.isNil(n.rootText)?s.name:n.rootText},n.textStyle),{x:a,y:0})}),u=l.getBBox();if(a+=u.width+4,l.on("click",(function(e){var n,i=e.target.get("id");if(i!==(null===(n=o.last(r))||void 0===n?void 0:n.id)){var a=r.slice(0,r.findIndex((function(t){return t.id===i}))+1);t.backTo(a)}})),l.on("mouseenter",(function(t){var e;t.target.get("id")!==(null===(e=o.last(r))||void 0===e?void 0:e.id)?l.attr(n.activeTextStyle):l.attr({cursor:"default"})})),l.on("mouseleave",(function(){l.attr(n.textStyle)})),c0&&(o=1/Math.sqrt(o)),t[0]=e[0]*o,t[1]=e[1]*o,t[2]=e[2]*o,t}function A(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]}function C(t,e,n){var i=e[0],r=e[1],o=e[2],a=n[0],s=n[1],c=n[2];return t[0]=r*c-o*s,t[1]=o*a-i*c,t[2]=i*s-r*a,t}function E(t,e,n,i){var r=e[0],o=e[1],a=e[2];return t[0]=r+i*(n[0]-r),t[1]=o+i*(n[1]-o),t[2]=a+i*(n[2]-a),t}function I(t,e,n,i,r,o){var a=o*o,s=a*(2*o-3)+1,c=a*(o-2)+o,l=a*(o-1),u=a*(3-2*o);return t[0]=e[0]*s+n[0]*c+i[0]*l+r[0]*u,t[1]=e[1]*s+n[1]*c+i[1]*l+r[1]*u,t[2]=e[2]*s+n[2]*c+i[2]*l+r[2]*u,t}function P(t,e,n,i,r,o){var a=1-o,s=a*a,c=o*o,l=s*a,u=3*o*s,h=3*c*a,f=c*o;return t[0]=e[0]*l+n[0]*u+i[0]*h+r[0]*f,t[1]=e[1]*l+n[1]*u+i[1]*h+r[1]*f,t[2]=e[2]*l+n[2]*u+i[2]*h+r[2]*f,t}function F(t,e){e=e||1;var n=2*i.c()*Math.PI,r=2*i.c()-1,o=Math.sqrt(1-r*r)*e;return t[0]=Math.cos(n)*o,t[1]=Math.sin(n)*o,t[2]=r*e,t}function T(t,e,n){var i=e[0],r=e[1],o=e[2],a=n[3]*i+n[7]*r+n[11]*o+n[15];return a=a||1,t[0]=(n[0]*i+n[4]*r+n[8]*o+n[12])/a,t[1]=(n[1]*i+n[5]*r+n[9]*o+n[13])/a,t[2]=(n[2]*i+n[6]*r+n[10]*o+n[14])/a,t}function L(t,e,n){var i=e[0],r=e[1],o=e[2];return t[0]=i*n[0]+r*n[3]+o*n[6],t[1]=i*n[1]+r*n[4]+o*n[7],t[2]=i*n[2]+r*n[5]+o*n[8],t}function k(t,e,n){var i=n[0],r=n[1],o=n[2],a=n[3],s=e[0],c=e[1],l=e[2],u=r*l-o*c,h=o*s-i*l,f=i*c-r*s,p=r*f-o*h,d=o*u-i*f,g=i*h-r*u,y=2*a;return u*=y,h*=y,f*=y,p*=2,d*=2,g*=2,t[0]=s+u+p,t[1]=c+h+d,t[2]=l+f+g,t}function D(t,e,n,i){var r=[],o=[];return r[0]=e[0]-n[0],r[1]=e[1]-n[1],r[2]=e[2]-n[2],o[0]=r[0],o[1]=r[1]*Math.cos(i)-r[2]*Math.sin(i),o[2]=r[1]*Math.sin(i)+r[2]*Math.cos(i),t[0]=o[0]+n[0],t[1]=o[1]+n[1],t[2]=o[2]+n[2],t}function B(t,e,n,i){var r=[],o=[];return r[0]=e[0]-n[0],r[1]=e[1]-n[1],r[2]=e[2]-n[2],o[0]=r[2]*Math.sin(i)+r[0]*Math.cos(i),o[1]=r[1],o[2]=r[2]*Math.cos(i)-r[0]*Math.sin(i),t[0]=o[0]+n[0],t[1]=o[1]+n[1],t[2]=o[2]+n[2],t}function R(t,e,n,i){var r=[],o=[];return r[0]=e[0]-n[0],r[1]=e[1]-n[1],r[2]=e[2]-n[2],o[0]=r[0]*Math.cos(i)-r[1]*Math.sin(i),o[1]=r[0]*Math.sin(i)+r[1]*Math.cos(i),o[2]=r[2],t[0]=o[0]+n[0],t[1]=o[1]+n[1],t[2]=o[2]+n[2],t}function N(t,e){var n=t[0],i=t[1],r=t[2],o=e[0],a=e[1],s=e[2],c=Math.sqrt(n*n+i*i+r*r)*Math.sqrt(o*o+a*a+s*s),l=c&&A(t,e)/c;return Math.acos(Math.min(Math.max(l,-1),1))}function V(t){return t[0]=0,t[1]=0,t[2]=0,t}function z(t){return"vec3("+t[0]+", "+t[1]+", "+t[2]+")"}function G(t,e){return t[0]===e[0]&&t[1]===e[1]&&t[2]===e[2]}function Y(t,e){var n=t[0],r=t[1],o=t[2],a=e[0],s=e[1],c=e[2];return Math.abs(n-a)<=i.b*Math.max(1,Math.abs(n),Math.abs(a))&&Math.abs(r-s)<=i.b*Math.max(1,Math.abs(r),Math.abs(s))&&Math.abs(o-c)<=i.b*Math.max(1,Math.abs(o),Math.abs(c))}var X,W=h,H=f,U=p,q=O,Z=_,$=a,K=w,Q=(X=r(),function(t,e,n,i,r,o){var a,s;for(e||(e=3),n||(n=0),s=i?Math.min(i*e+n,t.length):t.length,a=n;a0)}));return c.length>0?(Object(a.a)(c,(function(t){var e=t.getBBox();o.push(e.minX,e.maxX),s.push(e.minY,e.maxY)})),t=Object(r.min)(o),e=Object(r.max)(o),n=Object(r.min)(s),i=Object(r.max)(s)):(t=0,e=0,n=0,i=0),{x:t,y:n,minX:t,minY:n,maxX:e,maxY:i,width:e-t,height:i-n}},e.prototype.getCanvasBBox=function(){var t=1/0,e=-1/0,n=1/0,i=-1/0,o=[],s=[],c=this.getChildren().filter((function(t){return t.get("visible")&&(!t.isGroup()||t.isGroup()&&t.getChildren().length>0)}));return c.length>0?(Object(a.a)(c,(function(t){var e=t.getCanvasBBox();o.push(e.minX,e.maxX),s.push(e.minY,e.maxY)})),t=Object(r.min)(o),e=Object(r.max)(o),n=Object(r.min)(s),i=Object(r.max)(s)):(t=0,e=0,n=0,i=0),{x:t,y:n,minX:t,minY:n,maxX:e,maxY:i,width:e-t,height:i-n}},e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return e.children=[],e},e.prototype.onAttrChange=function(e,n,i){if(t.prototype.onAttrChange.call(this,e,n,i),"matrix"===e){var r=this.getTotalMatrix();this._applyChildrenMarix(r)}},e.prototype.applyMatrix=function(e){var n=this.getTotalMatrix();t.prototype.applyMatrix.call(this,e);var i=this.getTotalMatrix();i!==n&&this._applyChildrenMarix(i)},e.prototype._applyChildrenMarix=function(t){var e=this.getChildren();Object(a.a)(e,(function(e){e.applyMatrix(t)}))},e.prototype.addShape=function(){for(var t=[],e=0;e=0;o--){var s=t[o];if(Object(a.b)(s)&&(s.isGroup()?r=s.getShape(e,n,i):s.isHit(e,n)&&(r=s)),r)break}return r},e.prototype.add=function(t){var e=this.getCanvas(),n=this.getChildren(),i=this.get("timeline"),r=t.getParent();r&&function(t,e,n){void 0===n&&(n=!0),n?e.destroy():(e.set("parent",null),e.set("canvas",null)),Object(a.j)(t.getChildren(),e)}(r,t,!1),t.set("parent",this),e&&function t(e,n){if(e.set("canvas",n),e.isGroup()){var i=e.get("children");i.length&&i.forEach((function(e){t(e,n)}))}}(t,e),i&&function t(e,n){if(e.set("timeline",n),e.isGroup()){var i=e.get("children");i.length&&i.forEach((function(e){t(e,n)}))}}(t,i),n.push(t),t.onCanvasChange("add"),this._applyElementMatrix(t)},e.prototype._applyElementMatrix=function(t){var e=this.getTotalMatrix();e&&t.applyMatrix(e)},e.prototype.getChildren=function(){return this.get("children")},e.prototype.sort=function(){var t,e=this.getChildren();Object(a.a)(e,(function(t,e){return t._INDEX=e,t})),e.sort((t=function(t,e){return t.get("zIndex")-e.get("zIndex")},function(e,n){var i=t(e,n);return 0===i?e._INDEX-n._INDEX:i})),this.onCanvasChange("sort")},e.prototype.clear=function(){if(this.set("clearing",!0),!this.destroyed){for(var t=this.getChildren(),e=t.length-1;e>=0;e--)t[e].destroy();this.set("children",[]),this.onCanvasChange("clear"),this.set("clearing",!1)}},e.prototype.destroy=function(){this.get("destroyed")||(this.clear(),t.prototype.destroy.call(this))},e.prototype.getFirst=function(){return this.getChildByIndex(0)},e.prototype.getLast=function(){var t=this.getChildren();return this.getChildByIndex(t.length-1)},e.prototype.getChildByIndex=function(t){return this.getChildren()[t]},e.prototype.getCount=function(){return this.getChildren().length},e.prototype.contain=function(t){return this.getChildren().indexOf(t)>-1},e.prototype.removeChild=function(t,e){void 0===e&&(e=!0),this.contain(t)&&t.remove(e)},e.prototype.findAll=function(t){var e=[],n=this.getChildren();return Object(a.a)(n,(function(n){t(n)&&e.push(n),n.isGroup()&&(e=e.concat(n.findAll(t)))})),e},e.prototype.find=function(t){var e=null,n=this.getChildren();return Object(a.a)(n,(function(n){if(t(n)?e=n:n.isGroup()&&(e=n.find(t)),e)return!1})),e},e.prototype.findById=function(t){return this.find((function(e){return e.get("id")===t}))},e.prototype.findByClassName=function(t){return this.find((function(e){return e.get("className")===t}))},e.prototype.findAllByName=function(t){return this.findAll((function(e){return e.get("name")===t}))},e}(o.a);e.a=c},function(t,e,n){"use strict";var i=n(1),r=n(0),o=n(3),a=n(14),s=n(29),c=n(68),l=o.ext.transform,u=["zIndex","capture","visible","type"],h=["repeat"];function f(t,e){var n={},i=e.attrs;for(var r in t)n[r]=i[r];return n}function p(t,e){var n={},i=e.attr();return Object(r.each)(t,(function(t,e){-1!==h.indexOf(e)||Object(r.isEqual)(i[e],t)||(n[e]=t)})),n}function d(t,e){if(e.onFrame)return t;var n=e.startTime,i=e.delay,o=e.duration,a=Object.prototype.hasOwnProperty;return Object(r.each)(t,(function(t){n+it.delay&&Object(r.each)(e.toAttrs,(function(e,n){a.call(t.toAttrs,n)&&(delete t.toAttrs[n],delete t.fromAttrs[n])}))})),t}var g=function(t){function e(e){var n=t.call(this,e)||this;n.attrs={};var i=n.getDefaultAttrs();return Object(r.mix)(i,e.attrs),n.attrs=i,n.initAttrs(i),n.initAnimate(),n}return Object(i.__extends)(e,t),e.prototype.getDefaultCfg=function(){return{visible:!0,capture:!0,zIndex:0}},e.prototype.getDefaultAttrs=function(){return{matrix:this.getDefaultMatrix(),opacity:1}},e.prototype.onCanvasChange=function(t){},e.prototype.initAttrs=function(t){},e.prototype.initAnimate=function(){this.set("animable",!0),this.set("animating",!1)},e.prototype.isGroup=function(){return!1},e.prototype.getParent=function(){return this.get("parent")},e.prototype.getCanvas=function(){return this.get("canvas")},e.prototype.attr=function(){for(var t,e=[],n=0;n0?i=d(i,_):n.addAnimator(this),i.push(_),this.set("animations",i),this.set("_pause",{isPaused:!1})}},e.prototype.stopAnimate=function(t){var e=this;void 0===t&&(t=!0);var n=this.get("animations");Object(r.each)(n,(function(n){t&&(n.onFrame?e.attr(n.onFrame(1)):e.attr(n.toAttrs)),n.callback&&n.callback()})),this.set("animating",!1),this.set("animations",[])},e.prototype.pauseAnimate=function(){var t=this.get("timeline"),e=this.get("animations"),n=t.getTime();return Object(r.each)(e,(function(t){t._paused=!0,t._pauseTime=n,t.pauseCallback&&t.pauseCallback()})),this.set("_pause",{isPaused:!0,pauseTime:n}),this},e.prototype.resumeAnimate=function(){var t=this.get("timeline").getTime(),e=this.get("animations"),n=this.get("_pause").pauseTime;return Object(r.each)(e,(function(e){e.startTime=e.startTime+(t-n),e._paused=!1,e._pauseTime=null,e.resumeCallback&&e.resumeCallback()})),this.set("_pause",{isPaused:!1}),this.set("animations",e),this},e.prototype.emitDelegation=function(t,e){var n,i=this,o=e.propagationPath;this.getEvents();"mouseenter"===t?n=e.fromShape:"mouseleave"===t&&(n=e.toShape);for(var s=function(t){var s=o[t],l=s.get("name");if(l){if((s.isGroup()||s.isCanvas&&s.isCanvas())&&n&&Object(a.g)(s,n))return"break";Object(r.isArray)(l)?Object(r.each)(l,(function(t){i.emitDelegateEvent(s,t,e)})):c.emitDelegateEvent(s,l,e)}},c=this,l=0;l=0&&s<.5*Math.PI?(i={x:u.minX,y:u.minY},o={x:u.maxX,y:u.maxY}):.5*Math.PI<=s&&s=i&&t<=r}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.adaptor=e.adjust=e.legend=e.axis=e.meta=void 0;var i=n(1),r=n(0),o=n(12),a=n(2),s=n(18),c=n(2),l=n(63);function u(t){var e=t.chart,n=t.options,r=n.data,o=n.color,c=n.lineStyle,l=n.lineShape,u=n.point,h=n.area,f=n.seriesField,p=null==u?void 0:u.state,d=null==h?void 0:h.state;e.data(r);var g=a.deepAssign({},t,{options:{shapeField:f,line:{color:o,style:c,shape:l},point:u&&i.__assign({color:o,shape:"circle"},u),area:h&&i.__assign({color:o},h),label:void 0}}),y=a.deepAssign({},g,{options:{tooltip:!1,state:p}}),v=a.deepAssign({},g,{options:{tooltip:!1,state:d}});return s.line(g),s.point(y),s.area(v),t}function h(t){var e,n,i=t.options,r=i.xAxis,a=i.yAxis,s=i.xField,u=i.yField,h=i.data;return c.flow(o.scale(((e={})[s]=r,e[u]=a,e),((n={})[s]={type:"cat"},n[u]=l.adjustYMetaByZero(h,u),n)))(t)}function f(t){var e=t.chart,n=t.options.reflect;if(n){var i=n;r.isArray(i)||(i=[i]);var o=i.map((function(t){return["reflect",t]}));e.coordinate({type:"rect",actions:o})}return t}function p(t){var e=t.chart,n=t.options,i=n.xAxis,r=n.yAxis,o=n.xField,a=n.yField;return!1===i?e.axis(o,!1):e.axis(o,i),!1===r?e.axis(a,!1):e.axis(a,r),t}function d(t){var e=t.chart,n=t.options,i=n.legend,r=n.seriesField;return i&&r?e.legend(r,i):!1===i&&e.legend(!1),t}function g(t){var e=t.chart,n=t.options,r=n.label,o=n.yField,s=a.findGeometry(e,"line");if(r){var c=r.callback,l=i.__rest(r,["callback"]);s.label({fields:[o],callback:c,cfg:i.__assign({layout:[{type:"limit-in-plot"},{type:"path-adjust-position"},{type:"point-adjust-position"},{type:"limit-in-plot",cfg:{action:"hide"}}]},a.transformLabel(l))})}else s.label(!1);return t}function y(t){var e=t.chart;return t.options.isStack&&r.each(e.geometries,(function(t){t.adjust("stack")})),t}e.meta=h,e.axis=p,e.legend=d,e.adjust=y,e.adaptor=function(t){return c.flow(u,h,y,o.theme,f,p,d,o.tooltip,g,o.slider,o.scrollbar,o.interaction,o.animation,o.annotation(),o.limitInPlot)(t)}},function(t,e,n){"use strict";function i(t){return(i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function r(){return"object"===("undefined"==typeof window?"undefined":i(window))?null===window||void 0===window?void 0:window.devicePixelRatio:2}Object.defineProperty(e,"__esModule",{value:!0}),e.transformMatrix=e.getSymbolsPosition=e.getUnitPatternSize=e.drawBackground=e.initCanvas=e.getPixelRatio=void 0,e.getPixelRatio=r,e.initCanvas=function(t,e){void 0===e&&(e=t);var n=document.createElement("canvas"),i=r();return n.width=t*i,n.height=e*i,n.style.width=t+"px",n.style.height=e+"px",n.getContext("2d").scale(i,i),n},e.drawBackground=function(t,e,n,i){void 0===i&&(i=n);var r=e.backgroundColor,o=e.opacity;t.globalAlpha=o,t.fillStyle=r,t.beginPath(),t.fillRect(0,0,n,i),t.closePath()},e.getUnitPatternSize=function(t,e,n){var i=t+e;return n?2*i:i},e.getSymbolsPosition=function(t,e){return e?[[t*(1/4),t*(1/4)],[t*(3/4),t*(3/4)]]:[[.5*t,.5*t]]},e.transformMatrix=function(t,e){var n=e*Math.PI/180;return{a:Math.cos(n)*(1/t),b:Math.sin(n)*(1/t),c:-Math.sin(n)*(1/t),d:Math.cos(n)*(1/t),e:0,f:0}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DualAxesGeometry=e.AxisType=void 0,function(t){t.Left="Left",t.Right="Right"}(e.AxisType||(e.AxisType={})),function(t){t.Line="line",t.Column="column"}(e.DualAxesGeometry||(e.DualAxesGeometry={}))},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getYAxisWithDefault=e.transformObjectToArray=e.getGeometryOption=e.isColumn=e.isLine=void 0;var i=n(1),r=n(0),o=n(2),a=n(80),s=n(133);function c(t){return r.get(t,"geometry")===a.DualAxesGeometry.Column}e.isLine=function(t){return r.get(t,"geometry")===a.DualAxesGeometry.Line},e.isColumn=c,e.getGeometryOption=function(t,e,n){return c(n)?o.deepAssign({},{geometry:a.DualAxesGeometry.Column,label:n.label&&n.isRange?{content:function(t){var n;return null===(n=t[e])||void 0===n?void 0:n.join("-")}}:void 0},n):i.__assign({geometry:a.DualAxesGeometry.Line},n)},e.transformObjectToArray=function(t,e){var n=t[0],i=t[1];return r.isArray(e)?[e[0],e[1]]:[r.get(e,n),r.get(e,i)]},e.getYAxisWithDefault=function(t,e){return e===a.AxisType.Left?!1!==t&&o.deepAssign({},s.DEFAULT_LEFT_YAXIS_CONFIG,t):e===a.AxisType.Right?!1!==t&&o.deepAssign({},s.DEFAULT_RIGHT_YAXIS_CONFIG,t):t}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.adaptor=e.geometry=void 0;var i=n(0),r=n(2),o=n(12),a=n(18),s=n(144),c=n(83);function l(t){var e=t.chart,n=t.options,o=n.percent,l=n.progressStyle,u=n.color,h=n.barWidthRatio;e.data(c.getProgressData(o));var f=r.deepAssign({},t,{options:{xField:"1",yField:"percent",seriesField:"type",isStack:!0,widthRatio:h,interval:{style:l,color:i.isString(u)?[u,s.DEFAULT_COLOR[1]]:u},args:{zIndexReversed:!0,sortZIndex:!0}}});return a.interval(f),e.tooltip(!1),e.axis(!1),e.legend(!1),t}function u(t){return t.chart.coordinate("rect").transpose(),t}e.geometry=l,e.adaptor=function(t){return r.flow(l,o.scale({}),u,o.animation,o.theme,o.annotation())(t)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getProgressData=void 0;var i=n(0),r=n(77);e.getProgressData=function(t){var e=i.clamp(r.isRealNumber(t)?t:0,0,1);return[{type:"current",percent:e},{type:"target",percent:1-e}]}},function(t,e,n){"use strict";var i;Object.defineProperty(e,"__esModule",{value:!0}),e.DEFAULT_OPTIONS=e.OUTLIERS_VIEW_ID=e.BOX_SYNC_NAME=e.BOX_RANGE_ALIAS=e.BOX_RANGE=void 0;var r=n(7),o=n(2);e.BOX_RANGE="$$range$$",e.BOX_RANGE_ALIAS="low-q1-median-q3-high",e.BOX_SYNC_NAME="$$y_outliers$$",e.OUTLIERS_VIEW_ID="outliers_view",e.DEFAULT_OPTIONS=o.deepAssign({},r.Plot.getDefaultOptions(),{meta:(i={},i[e.BOX_RANGE]={min:0,alias:e.BOX_RANGE_ALIAS},i),interactions:[{type:"active-region"}],tooltip:{showMarkers:!1,shared:!0},boxStyle:{lineWidth:1}})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.placeElementsOrdered=void 0,e.placeElementsOrdered=function(t){t&&t.geometries[0].elements.forEach((function(t){t.shape.toFront()}))}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DEFAULT_OPTIONS=e.DEFAULT_TOOLTIP_OPTIONS=e.TREND_DOWN=e.TREND_UP=e.TREND_FIELD=e.Y_FIELD=void 0;var i=n(7),r=n(2);e.Y_FIELD="$$stock-range$$",e.TREND_FIELD="trend",e.TREND_UP="up",e.TREND_DOWN="down",e.DEFAULT_TOOLTIP_OPTIONS={showMarkers:!1,showCrosshairs:!0,shared:!0,crosshairs:{type:"xy",follow:!0,text:function(t,e,n){var i;if("x"===t){var r=n[0];i=r?r.title:e}else i=e;return{position:"y"===t?"start":"end",content:i,style:{fill:"#dfdfdf"}}},textBackground:{padding:[2,4],style:{fill:"#666"}}}},e.DEFAULT_OPTIONS=r.deepAssign({},i.Plot.getDefaultOptions(),{tooltip:e.DEFAULT_TOOLTIP_OPTIONS,interactions:[{type:"tooltip"}],legend:{position:"top-left"},risingFill:"#ef5350",fallingFill:"#26a69a"})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.conversionTagComponent=e.transformData=void 0;var i=n(1),r=n(0),o=n(48);e.transformData=function(t,e,n){var i=n.yField,a=n.maxSize,s=n.minSize,c=r.get(r.maxBy(e,i),[i]),l=r.isNumber(a)?a:1,u=r.isNumber(s)?s:0;return r.map(t,(function(e,n){var a=(e[i]||0)/c;return e[o.FUNNEL_PERCENT]=a,e[o.FUNNEL_MAPPING_VALUE]=(l-u)*a+u,e[o.FUNNEL_CONVERSATION]=[r.get(t,[n-1,i]),e[i]],e}))},e.conversionTagComponent=function(t){return function(e){var n=e.chart,a=e.options.conversionTag,s=n.getOptions().data;if(a){var c=a.formatter;s.forEach((function(e,l){if(!(l<=0||Number.isNaN(e[o.FUNNEL_MAPPING_VALUE]))){var u=t(e,l,s,{top:!0,text:{content:r.isFunction(c)?c(e,s):c,offsetX:a.offsetX,offsetY:a.offsetY,position:"end",autoRotate:!1,style:i.__assign({textAlign:"start",textBaseline:"middle"},a.style)}});n.annotation().line(u)}}))}return e}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DEFAULT_OPTIONS=e.RAW_FIELDS=e.SUNBURST_PATH_FIELD=e.SUNBURST_Y_FIELD=e.SUNBURST_ANCESTOR_FIELD=void 0;var i=n(7),r=n(2),o=n(58);e.SUNBURST_ANCESTOR_FIELD="ancestor-node",e.SUNBURST_Y_FIELD="value",e.SUNBURST_PATH_FIELD="path",e.RAW_FIELDS=[e.SUNBURST_PATH_FIELD,o.NODE_INDEX_FIELD,o.NODE_ANCESTORS_FIELD,o.CHILD_NODE_COUNT,"name","depth","height"],e.DEFAULT_OPTIONS=r.deepAssign({},i.Plot.getDefaultOptions(),{innerRadius:0,radius:.85,hierarchyConfig:{field:"value"},tooltip:{shared:!0,showMarkers:!1,offset:20,showTitle:!1},legend:!1,sunburstStyle:{lineWidth:.5,stroke:"#FFF"},drilldown:{enabled:!0}})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.isParentNode=void 0;var i=n(9),r=n(0),o=n(65);function a(t){var e=r.get(t,["event","data","data"],{});return r.isArray(e.children)&&e.children.length>0}function s(t){var e=t.view.getCoordinate(),n=e.innerRadius;if(n){var i=t.event,r=i.x,o=i.y,a=e.center,s=a.x,c=a.y,l=e.getRadius()*n;return Math.sqrt(Math.pow(s-r,2)+Math.pow(c-o,2))=0;)e+=n[i].value;else e=1;t.value=e}function c(t,e){var n="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!n){if(Array.isArray(t)||(n=function(t,e){if(!t)return;if("string"==typeof t)return l(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);"Object"===n&&t.constructor&&(n=t.constructor.name);if("Map"===n||"Set"===n)return Array.from(t);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return l(t,e)}(t))||e&&t&&"number"==typeof t.length){n&&(t=n);var i=0,r=function(){};return{s:r,n:function(){return i>=t.length?{done:!0}:{done:!1,value:t[i++]}},e:function(t){throw t},f:r}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,s=!1;return{s:function(){n=n.call(t)},n:function(){var t=n.next();return a=t.done,t},e:function(t){s=!0,o=t},f:function(){try{a||null==n.return||n.return()}finally{if(s)throw o}}}}function l(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,i=new Array(e);n=t.length?{done:!0}:{done:!1,value:t[i++]}},e:function(t){throw t},f:r}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,s=!1;return{s:function(){n=n.call(t)},n:function(){var t=n.next();return a=t.done,t},e:function(t){s=!0,o=t},f:function(){try{a||null==n.return||n.return()}finally{if(s)throw o}}}}function h(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,i=new Array(e);n=0;--o)c.push(i=r[o]=new O(r[o])),i.parent=n,i.depth=n.depth+1;return s.eachBefore(b)}function v(t){return t.children}function m(t){return Array.isArray(t)?t[1]:null}function x(t){void 0!==t.data.value&&(t.value=t.data.value),t.data=t.data.data}function b(t){var e=0;do{t.height=e}while((t=t.parent)&&t.height<++e)}function O(t){this.data=t,this.depth=this.height=0,this.parent=null}function _(t){return(_="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}O.prototype=y.prototype=function(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}({constructor:O,count:function(){return this.eachAfter(s)},each:function(t,e){var n,i=-1,r=c(this);try{for(r.s();!(n=r.n()).done;){var o=n.value;t.call(e,o,++i,this)}}catch(t){r.e(t)}finally{r.f()}return this},eachAfter:function(t,e){for(var n,i,r,o=this,a=[o],s=[],c=-1;o=a.pop();)if(s.push(o),n=o.children)for(i=0,r=n.length;i=0;--i)o.push(n[i]);return this},find:function(t,e){var n,i=-1,r=u(this);try{for(r.s();!(n=r.n()).done;){var o=n.value;if(t.call(e,o,++i,this))return o}}catch(t){r.e(t)}finally{r.f()}},sum:function(t){return this.eachAfter((function(e){for(var n=+t(e.data)||0,i=e.children,r=i&&i.length;--r>=0;)n+=i[r].value;e.value=n}))},sort:function(t){return this.eachBefore((function(e){e.children&&e.children.sort(t)}))},path:function(t){for(var e=this,n=function(t,e){if(t===e)return t;var n=t.ancestors(),i=e.ancestors(),r=null;t=n.pop(),e=i.pop();for(;t===e;)r=t,t=n.pop(),e=i.pop();return r}(e,t),i=[e];e!==n;)e=e.parent,i.push(e);for(var r=i.length;t!==n;)i.splice(r,0,t),t=t.parent;return i},ancestors:function(){for(var t=this,e=[t];t=t.parent;)e.push(t);return e},descendants:function(){return Array.from(this)},leaves:function(){var t=[];return this.eachBefore((function(e){e.children||t.push(e)})),t},links:function(){var t=this,e=[];return t.each((function(n){n!==t&&e.push({source:n.parent,target:n})})),e},copy:function(){return y(this).eachBefore(x)}},Symbol.iterator,g);var w=function(t){for(var e,n,i=0,r=(t=function(t){for(var e,n,i=t.length;i;)n=Math.random()*i--|0,e=t[i],t[i]=t[n],t[n]=e;return t}(Array.from(t))).length,o=[];i0&&n*n>i*i+r*r}function A(t,e){for(var n=0;n(a*=a)?(i=(l+a-r)/(2*l),o=Math.sqrt(Math.max(0,a/l-i*i)),n.x=t.x-i*s-o*c,n.y=t.y-i*c+o*s):(i=(l+r-a)/(2*l),o=Math.sqrt(Math.max(0,r/l-i*i)),n.x=e.x+i*s-o*c,n.y=e.y+i*c+o*s)):(n.x=e.x+n.r,n.y=e.y)}function F(t,e){var n=t.r+e.r-1e-6,i=e.x-t.x,r=e.y-t.y;return n>0&&n*n>i*i+r*r}function T(t){var e=t._,n=t.next._,i=e.r+n.r,r=(e.x*n.r+n.x*e.r)/i,o=(e.y*n.r+n.y*e.r)/i;return r*r+o*o}function L(t){this._=t,this.next=null,this.previous=null}function k(t){if(!(o=(e=t,t="object"===_(e)&&"length"in e?e:Array.from(e)).length))return 0;var e,n,i,r,o,a,s,c,l,u,h,f;if((n=t[0]).x=0,n.y=0,!(o>1))return n.r;if(i=t[1],n.x=-i.r,i.x=n.r,i.y=0,!(o>2))return n.r+i.r;P(i,n,r=t[2]),n=new L(n),i=new L(i),r=new L(r),n.next=r.previous=i,i.next=n.previous=r,r.next=i.previous=n;t:for(c=3;c0)throw new Error("cycle");return o}return n.id=function(e){return arguments.length?(t=R(e),n):t},n.parentId=function(t){return arguments.length?(e=R(t),n):e},n};function tt(t,e){return t.parent===e.parent?1:2}function et(t){var e=t.children;return e?e[0]:t.t}function nt(t){var e=t.children;return e?e[e.length-1]:t.t}function it(t,e,n){var i=n/(e.i-t.i);e.c-=i,e.s+=n,t.c+=i,e.z+=n,e.m+=n}function rt(t,e,n){return t.a.parent===e.parent?t.a:n}function ot(t,e){this._=t,this.parent=null,this.children=null,this.A=null,this.a=this,this.z=0,this.m=0,this.c=0,this.s=0,this.t=null,this.i=e}ot.prototype=Object.create(O.prototype);var at=function(){var t=tt,e=1,n=1,i=null;function r(r){var c=function(t){for(var e,n,i,r,o,a=new ot(t,0),s=[a];e=s.pop();)if(i=e._.children)for(e.children=new Array(o=i.length),r=o-1;r>=0;--r)s.push(n=e.children[r]=new ot(i[r],r)),n.parent=e;return(a.parent=new ot(null,0)).children=[a],a}(r);if(c.eachAfter(o),c.parent.m=-c.z,c.eachBefore(a),i)r.eachBefore(s);else{var l=r,u=r,h=r;r.eachBefore((function(t){t.xu.x&&(u=t),t.depth>h.depth&&(h=t)}));var f=l===u?1:t(l,u)/2,p=f-l.x,d=e/(u.x+f+p),g=n/(h.depth||1);r.eachBefore((function(t){t.x=(t.x+p)*d,t.y=t.depth*g}))}return r}function o(e){var n=e.children,i=e.parent.children,r=e.i?i[e.i-1]:null;if(n){!function(t){for(var e,n=0,i=0,r=t.children,o=r.length;--o>=0;)(e=r[o]).z+=n,e.m+=n,n+=e.s+(i+=e.c)}(e);var o=(n[0].z+n[n.length-1].z)/2;r?(e.z=r.z+t(e._,r._),e.m=e.z-o):e.z=o}else r&&(e.z=r.z+t(e._,r._));e.parent.A=function(e,n,i){if(n){for(var r,o=e,a=e,s=n,c=o.parent.children[0],l=o.m,u=a.m,h=s.m,f=c.m;s=nt(s),o=et(o),s&&o;)c=et(c),(a=nt(a)).a=e,(r=s.z+h-o.z-l+t(s._,o._))>0&&(it(rt(s,e,i),e,r),l+=r,u+=r),h+=s.m,l+=o.m,f+=c.m,u+=a.m;s&&!nt(a)&&(a.t=s,a.m+=h-u),o&&!et(c)&&(c.t=o,c.m+=l-f,i=e)}return i}(e,r,e.parent.A||i[0])}function a(t){t._.x=t.z+t.parent.m,t.m+=t.parent.m}function s(t){t.x*=e,t.y=t.depth*n}return r.separation=function(e){return arguments.length?(t=e,r):t},r.size=function(t){return arguments.length?(i=!1,e=+t[0],n=+t[1],r):i?null:[e,n]},r.nodeSize=function(t){return arguments.length?(i=!0,e=+t[0],n=+t[1],r):i?[e,n]:null},r},st=function(t,e,n,i,r){for(var o,a=t.children,s=-1,c=a.length,l=t.value&&(r-n)/t.value;++sf&&(f=s),y=u*u*g,(p=Math.max(f/y,y/h))>d){u-=s;break}d=p}v.push(a={value:u,dice:c1?e:1)},n}(ct),ht=function(){var t=ut,e=!1,n=1,i=1,r=[0],o=N,a=N,s=N,c=N,l=N;function u(t){return t.x0=t.y0=0,t.x1=n,t.y1=i,t.eachBefore(h),r=[0],e&&t.eachBefore(H),t}function h(e){var n=r[e.depth],i=e.x0+n,u=e.y0+n,h=e.x1-n,f=e.y1-n;h=n-1){var u=s[e];return u.x0=r,u.y0=o,u.x1=a,void(u.y1=c)}var h=l[e],f=i/2+h,p=e+1,d=n-1;for(;p>>1;l[g]c-o){var m=i?(r*v+a*y)/i:a;t(e,p,y,r,o,m,c),t(p,n,v,m,o,a,c)}else{var x=i?(o*v+c*y)/i:c;t(e,p,y,r,o,a,x),t(p,n,v,r,x,a,c)}}(0,c,t.value,e,n,i,r)},pt=function(t,e,n,i,r){(1&t.depth?st:U)(t,e,n,i,r)},dt=function t(e){function n(t,n,i,r,o){if((a=t._squarify)&&a.ratio===e)for(var a,s,c,l,u,h=-1,f=a.length,p=t.value;++h1?e:1)},n}(ct)},function(t,e,n){"use strict";n.d(e,"a",(function(){return o})),n.d(e,"b",(function(){return r}));var i=new Map;function r(t,e){i.set(t,e)}function o(t){return i.get(t)}var a=function(t){var e=t.attr();return{x:e.x,y:e.y,width:e.width,height:e.height}},s=function(t){var e=t.attr(),n=e.x,i=e.y,r=e.r;return{x:n-r,y:i-r,width:2*r,height:2*r}},c=n(15);function l(t,e){return t&&e?{minX:Math.min(t.minX,e.minX),minY:Math.min(t.minY,e.minY),maxX:Math.max(t.maxX,e.maxX),maxY:Math.max(t.maxY,e.maxY)}:t||e}function u(t,e){var n=t.get("startArrowShape"),i=t.get("endArrowShape");return n&&(e=l(e,n.getCanvasBBox())),i&&(e=l(e,i.getCanvasBBox())),e}var h=n(40),f=n(28),p=n(0);function d(t,e){var n=t.prePoint,i=t.currentPoint,r=t.nextPoint,o=Math.pow(i[0]-n[0],2)+Math.pow(i[1]-n[1],2),a=Math.pow(i[0]-r[0],2)+Math.pow(i[1]-r[1],2),s=Math.pow(n[0]-r[0],2)+Math.pow(n[1]-r[1],2),c=Math.acos((o+a-s)/(2*Math.sqrt(o)*Math.sqrt(a)));if(!c||0===Math.sin(c)||Object(p.isNumberEqual)(c,0))return{xExtra:0,yExtra:0};var l=Math.abs(Math.atan2(r[1]-i[1],r[0]-i[0])),u=Math.abs(Math.atan2(r[0]-i[0],r[1]-i[1]));return l=l>Math.PI/2?Math.PI-l:l,u=u>Math.PI/2?Math.PI-u:u,{xExtra:Math.cos(c/2-l)*(e/2*(1/Math.sin(c/2)))-e/2||0,yExtra:Math.cos(u-c/2)*(e/2*(1/Math.sin(c/2)))-e/2||0}}r("rect",a),r("image",a),r("circle",s),r("marker",s),r("polyline",(function(t){for(var e=t.attr().points,n=[],i=[],r=0;r=t&&n.minY<=e&&n.maxY>=e},e.prototype.afterAttrsChange=function(e){t.prototype.afterAttrsChange.call(this,e),this.clearCacheBBox()},e.prototype.getBBox=function(){var t=this.cfg.bbox;return t||(t=this.calculateBBox(),this.set("bbox",t)),t},e.prototype.getCanvasBBox=function(){var t=this.cfg.canvasBBox;return t||(t=this.calculateCanvasBBox(),this.set("canvasBBox",t)),t},e.prototype.applyMatrix=function(e){t.prototype.applyMatrix.call(this,e),this.set("canvasBBox",null)},e.prototype.calculateCanvasBBox=function(){var t=this.getBBox(),e=this.getTotalMatrix(),n=t.minX,i=t.minY,r=t.maxX,a=t.maxY;if(e){var s=Object(o.c)(e,[t.minX,t.minY]),c=Object(o.c)(e,[t.maxX,t.minY]),l=Object(o.c)(e,[t.minX,t.maxY]),u=Object(o.c)(e,[t.maxX,t.maxY]);n=Math.min(s[0],c[0],l[0],u[0]),r=Math.max(s[0],c[0],l[0],u[0]),i=Math.min(s[1],c[1],l[1],u[1]),a=Math.max(s[1],c[1],l[1],u[1])}var h=this.attrs;if(h.shadowColor){var f=h.shadowBlur,p=void 0===f?0:f,d=h.shadowOffsetX,g=void 0===d?0:d,y=h.shadowOffsetY,v=void 0===y?0:y,m=n-p+g,x=r+p+g,b=i-p+v,O=a+p+v;n=Math.min(n,m),r=Math.max(r,x),i=Math.min(i,b),a=Math.max(a,O)}return{x:n,y:i,minX:n,minY:i,maxX:r,maxY:a,width:r-n,height:a-i}},e.prototype.clearCacheBBox=function(){this.set("bbox",null),this.set("canvasBBox",null)},e.prototype.isClipShape=function(){return this.get("isClipShape")},e.prototype.isInShape=function(t,e){return!1},e.prototype.isOnlyHitBox=function(){return!1},e.prototype.isHit=function(t,e){var n=this.get("startArrowShape"),i=this.get("endArrowShape"),r=[t,e,1],o=(r=this.invertFromMatrix(r))[0],a=r[1],s=this._isInBBox(o,a);if(this.isOnlyHitBox())return s;if(s&&!this.isClipped(o,a)){if(this.isInShape(o,a))return!0;if(n&&n.isHit(o,a))return!0;if(i&&i.isHit(o,a))return!0}return!1},e}(r.a);e.a=a},function(t,e){},function(t,e){},function(t,e,n){"use strict";function i(t){return(i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}Object.defineProperty(e,"__esModule",{value:!0}),e.pick=void 0,e.pick=function(t,e){var n={};return null!==t&&"object"===i(t)&&e.forEach((function(e){var i=t[e];void 0!==i&&(n[e]=i)})),n}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.log=e.invariant=e.LEVEL=void 0;var i=n(1);!function(t){t.ERROR="error",t.WARN="warn",t.INFO="log"}(e.LEVEL||(e.LEVEL={}));var r="AntV/G2Plot";function o(t){for(var e=[],n=1;n"},key:(0===c?"top":"bottom")+"-statistic"},o.pick(e,["offsetX","offsetY","rotate","style","formatter"])))}}))},e.renderGaugeStatistic=function(t,e,n){var c=e.statistic;[c.title,c.content].forEach((function(e){if(e){var c=r.isFunction(e.style)?e.style(n):e.style;t.annotation().html(i.__assign({position:["50%","100%"],html:function(t,o){var l=o.getCoordinate(),u=o.views[0].getCoordinate(),h=u.getCenter(),f=u.getRadius(),p=Math.max(Math.sin(u.startAngle),Math.sin(u.endAngle))*f,d=h.y+p-l.y.start-parseFloat(r.get(c,"fontSize",0)),g=l.getRadius()*l.innerRadius*2;s(t,i.__assign({width:g+"px",transform:"translate(-50%, "+d+"px)"},a(c)));var y=o.getData();if(e.customHtml)return e.customHtml(t,o,n,y);var v=e.content;return e.formatter&&(v=e.formatter(n,y)),v?r.isString(v)?v:""+v:"
"}},o.pick(e,["offsetX","offsetY","rotate","style","formatter"])))}}))}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.setGlobal=e.GLOBAL=void 0;var i=n(0);e.GLOBAL={locale:"en-US"},e.setGlobal=function(t){i.each(t,(function(t,n){return e.GLOBAL[n]=t}))}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;e.default=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:60,n=null;return function(){for(var i=this,r=arguments.length,o=new Array(r),a=0;a0?n:e:e<0?e:n;case"outer":return n=12,i.isString(e)&&e.endsWith("%")?.01*parseFloat(e)<0?n:e:e>0?e:n;default:return e}},e.isAllZero=function(t,e){return i.every(r.processIllegalData(t,e),(function(t){return 0===t[e]}))}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.PIE_STATISTIC=void 0;var i=n(9),r=n(248),o=n(249);e.PIE_STATISTIC="pie-statistic",i.registerAction(e.PIE_STATISTIC,o.StatisticAction),i.registerInteraction("pie-statistic-active",{start:[{trigger:"element:mouseenter",action:"pie-statistic:change"}],end:[{trigger:"element:mouseleave",action:"pie-statistic:reset"}]}),i.registerAction("pie-legend",r.PieLegendAction),i.registerInteraction("pie-legend-active",{start:[{trigger:"legend-item:mouseenter",action:"pie-legend:active"}],end:[{trigger:"legend-item:mouseleave",action:"pie-legend:reset"}]})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.transform=void 0;var i=n(1),r=n(9),o=[1,0,0,0,1,0,0,0,1];e.transform=function(t,e){var n=e?i.__spreadArrays(e):i.__spreadArrays(o);return r.Util.transform(n,t)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getSingleKeyValues=e.getFontSizeMapping=e.processImageMask=e.getSize=e.transform=void 0;var i=n(1),r=n(0),o=n(44),a=n(2),s=n(259);function c(t){var e=t.width,n=t.height,i=t.container,r=t.autoFit,s=t.padding,c=t.appendPadding;if(r){var l=a.getContainerSize(i);e=l.width,n=l.height}e=e||400,n=n||400;var u=function(t){var e=o.normalPadding(t.padding),n=o.normalPadding(t.appendPadding),i=e[0]+n[0],r=e[1]+n[1],a=e[2]+n[2],s=e[3]+n[3];return[i,r,a,s]}({padding:s,appendPadding:c}),h=u[0],f=u[1],p=u[2];return[e-(u[3]+f),n-(h+p)]}function l(t,e){if(r.isFunction(t))return t;if(r.isArray(t)){var n=t[0],i=t[1];if(!e)return function(){return(i+n)/2};var o=e[0],a=e[1];return a===o?function(){return(i+n)/2}:function(t){var e=t.value;return(i-n)/(a-o)*(e-o)+n}}return function(){return t}}function u(t,e){return t.map((function(t){return t[e]})).filter((function(t){return"number"==typeof t&&!isNaN(t)}))}function h(t){var e=function(t){var e=t.wordStyle.rotationSteps;e<1&&(a.log(a.LEVEL.WARN,!1,"The rotationSteps option must be greater than or equal to 1."),e=1);return{rotation:t.wordStyle.rotation,rotationSteps:e}}(t),n=e.rotation,i=e.rotationSteps;if(!r.isArray(n))return n;var o=n[0],s=n[1],c=1===i?0:(s-o)/(i-1);return function(){return s===o?s:Math.floor(Math.random()*i)*c}}function f(t){return Math.max.apply(Math,t)}e.transform=function(t){var e=t.options,n=t.chart,o=n,a=o.width,p=o.height,d=o.padding,g=o.appendPadding,y=o.ele,v=e.data,m=e.imageMask,x=e.wordField,b=e.weightField,O=e.colorField,_=e.wordStyle,w=e.timeInterval,j=e.random,S=e.spiral,M=e.autoFit,A=void 0===M||M,C=e.placementStrategy;if(!v||!v.length)return[];var E,I=_.fontFamily,P=_.fontWeight,F=_.padding,T=_.fontSize,L=u(v,b),k=[(E=L,Math.min.apply(Math,E)),f(L)],D=v.map((function(t){return{text:t[x],value:t[b],color:t[O],datum:t}})),B={imageMask:m,font:I,fontSize:l(T,k),fontWeight:P,size:c({width:a,height:p,padding:d,appendPadding:g,autoFit:A,container:y}),padding:F,timeInterval:w,random:j,spiral:S,rotate:h(e)};if(r.isFunction(C)){var R=D.map((function(t,e,r){return i.__assign(i.__assign(i.__assign({},t),{hasText:!!t.text,font:s.functor(B.font)(t,e,r),weight:s.functor(B.fontWeight)(t,e,r),rotate:s.functor(B.rotate)(t,e,r),size:s.functor(B.fontSize)(t,e,r),style:"normal"}),C.call(n,t,e,r))}));return R.push({text:"",value:0,x:0,y:0,opacity:0}),R.push({text:"",value:0,x:B.size[0],y:B.size[1],opacity:0}),R}return s.wordCloud(D,B)},e.getSize=c,e.processImageMask=function(t){return new Promise((function(e,n){if(t instanceof HTMLImageElement)e(t);else{if(r.isString(t)){var i=new Image;return i.crossOrigin="anonymous",i.src=t,i.onload=function(){e(i)},void(i.onerror=function(){a.log(a.LEVEL.ERROR,!1,"image %s load failed !!!",t),n()})}a.log(a.LEVEL.WARN,void 0===t,"The type of imageMask option must be String or HTMLImageElement."),n()}}))},e.getFontSizeMapping=l,e.getSingleKeyValues=u},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DEFAULT_OPTIONS=e.WORD_CLOUD_COLOR_FIELD=void 0;var i=n(7),r=n(2);e.WORD_CLOUD_COLOR_FIELD="color",e.DEFAULT_OPTIONS=r.deepAssign({},i.Plot.getDefaultOptions(),{timeInterval:2e3,legend:!1,tooltip:{showTitle:!1,showMarkers:!1,showCrosshairs:!1,fields:["text","value",e.WORD_CLOUD_COLOR_FIELD],formatter:function(t){return{name:t.text,value:t.value}}},wordStyle:{fontFamily:"Verdana",fontWeight:"normal",padding:1,fontSize:[12,60],rotation:[0,90],rotationSteps:2,rotateRatio:.5}})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.Scatter=void 0;var i=n(1),r=n(9),o=n(7),a=n(2),s=(n(261),n(131)),c=n(264);n(265);var l=function(t){function e(e,n){var o=t.call(this,e,n)||this;return o.type="scatter",o.on(r.VIEW_LIFE_CIRCLE.BEFORE_RENDER,(function(t){var e,n,a=o,c=a.options,l=a.chart;if((null===(e=t.data)||void 0===e?void 0:e.source)===r.BRUSH_FILTER_EVENTS.FILTER){var u=o.chart.filterData(o.chart.getData());s.meta({chart:l,options:i.__assign(i.__assign({},c),{data:u})})}(null===(n=t.data)||void 0===n?void 0:n.source)===r.BRUSH_FILTER_EVENTS.RESET&&s.meta({chart:l,options:c})})),o}return i.__extends(e,t),e.getDefaultOptions=function(){return c.DEFAULT_OPTIONS},e.prototype.changeData=function(t){this.updateOption(s.transformOptions(a.deepAssign({},this.options,{data:t})));var e=this.options,n=this.chart;s.meta({chart:n,options:e}),this.chart.changeData(t)},e.prototype.getSchemaAdaptor=function(){return s.adaptor},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e}(o.Plot);e.Scatter=l},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.adaptor=e.tooltip=e.meta=e.transformOptions=void 0;var i=n(1),r=n(0),o=n(2),a=n(18),s=n(118),c=n(12),l=n(2),u=n(262);function h(t){var e=t.data,n=void 0===e?[]:e,i=t.xField,r=t.yField;if(n.length){for(var a=!0,s=!0,c=n[0],l=void 0,h=1;h1?u/(o-1):l.max),!n&&!o){var f=function(t){return Math.ceil(Math.log(t.length)/Math.LN2)+1}(c);h=u/f}var p={},d=i.groupBy(s,a);i.isEmpty(d)?i.each(s,(function(t){var n=r(t[e],h,o),a=n[0]+"-"+n[1];i.hasKey(p,a)||(p[a]={range:n,count:0}),p[a].count+=1})):Object.keys(d).forEach((function(t){i.each(d[t],(function(n){var s=r(n[e],h,o),c=s[0]+"-"+s[1]+"-"+t;i.hasKey(p,c)||(p[c]={range:s,count:0},p[c][a]=t),p[c].count+=1}))}));var g=[];return i.each(p,(function(t){g.push(t)})),g}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.adaptor=void 0;var i=n(1),r=n(12),o=n(45),a=n(2),s=n(2),c=n(18),l=n(140),u=n(142);function h(t){var e=t.chart,n=t.options,i=n.data,r=n.binField,o=n.binNumber,s=n.binWidth,h=n.color,f=n.stackField,p=n.legend,d=n.columnStyle,g=l.binHistogram(i,r,s,o,f);e.data(g);var y=a.deepAssign({},t,{options:{xField:u.HISTOGRAM_X_FIELD,yField:u.HISTOGRAM_Y_FIELD,seriesField:f,isStack:!0,interval:{color:h,style:d}}});return c.interval(y),p&&f&&e.legend(f,p),t}function f(t){var e,n=t.options,i=n.xAxis,o=n.yAxis;return s.flow(r.scale(((e={})[u.HISTOGRAM_X_FIELD]=i,e[u.HISTOGRAM_Y_FIELD]=o,e)))(t)}function p(t){var e=t.chart,n=t.options,i=n.xAxis,r=n.yAxis;return!1===i?e.axis(u.HISTOGRAM_X_FIELD,!1):e.axis(u.HISTOGRAM_X_FIELD,i),!1===r?e.axis(u.HISTOGRAM_Y_FIELD,!1):e.axis(u.HISTOGRAM_Y_FIELD,r),t}function d(t){var e=t.chart,n=t.options.label,r=a.findGeometry(e,"interval");if(n){var o=n.callback,c=i.__rest(n,["callback"]);r.label({fields:[u.HISTOGRAM_Y_FIELD],callback:o,cfg:s.transformLabel(c)})}else r.label(!1);return t}e.adaptor=function(t){return s.flow(r.theme,o.pattern("columnStyle"),h,f,p,r.state,d,r.tooltip,r.interaction,r.animation)(t)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DEFAULT_OPTIONS=e.HISTOGRAM_Y_FIELD=e.HISTOGRAM_X_FIELD=void 0;var i=n(7),r=n(2);e.HISTOGRAM_X_FIELD="range",e.HISTOGRAM_Y_FIELD="count",e.DEFAULT_OPTIONS=r.deepAssign({},i.Plot.getDefaultOptions(),{columnStyle:{stroke:"#FFFFFF"},tooltip:{shared:!0,showMarkers:!1},interactions:[{type:"active-region"}]})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.Progress=void 0;var i=n(1),r=n(7),o=(n(282),n(82)),a=n(144),s=n(83),c=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="process",e}return i.__extends(e,t),e.getDefaultOptions=function(){return a.DEFAULT_OPTIONS},e.prototype.changeData=function(t){this.updateOption({percent:t}),this.chart.changeData(s.getProgressData(t))},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return o.adaptor},e}(r.Plot);e.Progress=c},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DEFAULT_OPTIONS=e.DEFAULT_COLOR=void 0,e.DEFAULT_COLOR=["#FAAD14","#E8EDF3"],e.DEFAULT_OPTIONS={percent:.2,color:e.DEFAULT_COLOR,animation:{}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.RingProgress=void 0;var i=n(1),r=n(9),o=n(7),a=n(83),s=(n(283),n(146)),c=n(284),l=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="ring-process",e}return i.__extends(e,t),e.getDefaultOptions=function(){return c.DEFAULT_OPTIONS},e.prototype.changeData=function(t){this.chart.emit(r.VIEW_LIFE_CIRCLE.BEFORE_CHANGE_DATA,r.Event.fromData(this.chart,r.VIEW_LIFE_CIRCLE.BEFORE_CHANGE_DATA,null)),this.updateOption({percent:t}),this.chart.data(a.getProgressData(t)),s.statistic({chart:this.chart,options:this.options},!0),this.chart.emit(r.VIEW_LIFE_CIRCLE.AFTER_CHANGE_DATA,r.Event.fromData(this.chart,r.VIEW_LIFE_CIRCLE.AFTER_CHANGE_DATA,null))},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return s.adaptor},e}(o.Plot);e.RingProgress=l},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.adaptor=e.statistic=void 0;var i=n(1),r=n(0),o=n(2),a=n(12),s=n(82);function c(t){var e=t.chart,n=t.options,i=n.innerRadius,r=n.radius;return e.coordinate("theta",{innerRadius:i,radius:r}),t}function l(t,e){var n=t.chart,a=t.options,s=a.innerRadius,c=a.statistic,l=a.percent,u=a.meta;if(n.getController("annotation").clear(!0),s&&c){var h=r.get(u,["percent","formatter"])||function(t){return(100*t).toFixed(2)+"%"},f=c.content;f&&(f=o.deepAssign({},f,{content:r.isNil(f.content)?h(l):f.content})),o.renderStatistic(n,{statistic:i.__assign(i.__assign({},c),{content:f}),plotType:"ring-progress"},{percent:l})}return e&&n.render(!0),t}e.statistic=l,e.adaptor=function(t){return o.flow(s.geometry,a.scale({}),c,l,a.animation,a.theme,a.annotation())(t)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.transformData=void 0;var i=n(0),r=n(84);e.transformData=function(t,e){var n=t;if(Array.isArray(e)){var o=e[0],a=e[1],s=e[2],c=e[3],l=e[4];n=i.map(t,(function(t){return t[r.BOX_RANGE]=[t[o],t[a],t[s],t[c],t[l]],t}))}return n}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.transformViolinData=e.toViolinValue=e.toBoxValue=void 0;var i=n(1),r=n(0),o=i.__importDefault(n(297)),a=n(299);e.toBoxValue=function(t){return{low:r.min(t),high:r.max(t),q1:a.quantile(t,.25),q3:a.quantile(t,.75),median:a.quantile(t,[.5]),minMax:[r.min(t),r.max(t)],quantile:[a.quantile(t,.25),a.quantile(t,.75)]}},e.toViolinValue=function(t,e){var n=o.default.create(t,e);return{violinSize:n.map((function(t){return t.y})),violinY:n.map((function(t){return t.x}))}},e.transformViolinData=function(t){var n=t.xField,o=t.yField,a=t.seriesField,s=t.data,c=t.kde,l={min:c.min,max:c.max,size:c.sampleSize,width:c.width};if(!a){var u=r.groupBy(s,n);return Object.keys(u).map((function(t){var n=u[t].map((function(t){return t[o]}));return i.__assign(i.__assign({x:t},e.toViolinValue(n,l)),e.toBoxValue(n))}))}var h=[],f=r.groupBy(s,a);return Object.keys(f).forEach((function(t){var s=r.groupBy(f[t],n);return Object.keys(s).forEach((function(n){var r,c=s[n].map((function(t){return t[o]}));h.push(i.__assign(i.__assign(((r={x:n})[a]=t,r),e.toViolinValue(c,l)),e.toBoxValue(c)))}))})),h}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DEFAULT_OPTIONS=e.MEDIAN_VIEW_ID=e.QUANTILE_VIEW_ID=e.MIN_MAX_VIEW_ID=e.VIOLIN_VIEW_ID=e.MEDIAN_FIELD=e.QUANTILE_FIELD=e.MIN_MAX_FIELD=e.VIOLIN_SIZE_FIELD=e.VIOLIN_Y_FIELD=e.X_FIELD=void 0;var i=n(7),r=n(2);e.X_FIELD="x",e.VIOLIN_Y_FIELD="violinY",e.VIOLIN_SIZE_FIELD="violinSize",e.MIN_MAX_FIELD="minMax",e.QUANTILE_FIELD="quantile",e.MEDIAN_FIELD="median",e.VIOLIN_VIEW_ID="violin_view",e.MIN_MAX_VIEW_ID="min_max_view",e.QUANTILE_VIEW_ID="quantile_view",e.MEDIAN_VIEW_ID="median_view",e.DEFAULT_OPTIONS=r.deepAssign({},i.Plot.getDefaultOptions(),{syncViewPadding:!0,kde:{type:"triangular",sampleSize:32,width:3},violinStyle:{lineWidth:1,fillOpacity:.3,strokeOpacity:.75},xAxis:{grid:{line:null},tickLine:{alignTick:!1}},yAxis:{grid:{line:{style:{lineWidth:.5,lineDash:[4,4]}}}},legend:{position:"top-left"},tooltip:{showMarkers:!1}})},function(t,e,n){var i,r,o,a;function s(t){return(s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}a=function(t){"use strict";function e(t){for(var e=new Array(t),n=0;nl+s*a*u||h>=g)d=a;else{if(Math.abs(p)<=-c*u)return a;p*(d-f)>=0&&(d=f),f=a,g=h}return 0}a=a||1,s=s||1e-6,c=c||.1;for(var y=0;y<10;++y){if(o(r.x,1,i.x,a,e),h=r.fx=t(r.x,r.fxprime),p=n(r.fxprime,e),h>l+s*a*u||y&&h>=f)return g(d,a,f);if(Math.abs(p)<=-c*u)return a;if(p>=0)return g(a,d,h);f=h,d=a,a*=2}return a}t.bisect=function(t,e,n,i){var r=(i=i||{}).maxIterations||100,o=i.tolerance||1e-10,a=t(e),s=t(n),c=n-e;if(a*s>0)throw"Initial bisect points must have opposite signs";if(0===a)return e;if(0===s)return n;for(var l=0;l=0&&(e=u),Math.abs(c)=g[d-1].fx){var C=!1;if(O.fx>A.fx?(o(_,1+f,b,-f,A),_.fx=t(_),_.fx=1)break;for(y=1;ye[n].radius+1e-10)return!1;return!0}function r(t,e){return t*t*Math.acos(1-e/t)-(t-e)*Math.sqrt(e*(2*t-e))}function o(t,e){return Math.sqrt((t.x-e.x)*(t.x-e.x)+(t.y-e.y)*(t.y-e.y))}function a(t,e){var n=o(t,e),i=t.radius,r=e.radius;if(n>=i+r||n<=Math.abs(i-r))return[];var a=(i*i-r*r+n*n)/(2*n),s=Math.sqrt(i*i-a*a),c=t.x+a*(e.x-t.x)/n,l=t.y+a*(e.y-t.y)/n,u=-(e.y-t.y)*(s/n),h=-(e.x-t.x)*(s/n);return[{x:c+u,y:l-h},{x:c-u,y:l+h}]}function s(t){for(var e={x:0,y:0},n=0;n1){var p=s(l);for(n=0;n-1){var b=t[y.parentIndex[x]],O=Math.atan2(y.x-b.x,y.y-b.y),_=Math.atan2(g.x-b.x,g.y-b.y),w=_-O;w<0&&(w+=2*Math.PI);var j=_-w/2,S=o(v,{x:b.x+b.radius*Math.sin(j),y:b.y+b.radius*Math.cos(j)});S>2*b.radius&&(S=2*b.radius),(null===m||m.width>S)&&(m={circle:b,width:S,p1:y,p2:g})}null!==m&&(f.push(m),u+=r(m.circle.radius,m.width),g=y)}}else{var M=t[0];for(n=1;nMath.abs(M.radius-t[n].radius)){A=!0;break}A?u=h=0:(u=M.radius*M.radius*Math.PI,f.push({circle:M,p1:{x:M.x,y:M.y+M.radius},p2:{x:M.x-1e-10,y:M.y+M.radius},width:2*M.radius}))}return h/=2,e&&(e.area=u+h,e.arcArea=u,e.polygonArea=h,e.arcs=f,e.innerPoints=l,e.intersectionPoints=c),u+h},e.containedInCircles=i,e.circleArea=r,e.distance=o,e.circleOverlap=function(t,e,n){if(n>=t+e)return 0;if(n<=Math.abs(t-e))return Math.PI*Math.min(t,e)*Math.min(t,e);var i=e-(n*n-t*t+e*e)/(2*n);return r(t,t-(n*n-e*e+t*t)/(2*n))+r(e,i)},e.circleCircleIntersection=a,e.getCenter=s},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getStockData=void 0;var i=n(0),r=n(86);e.getStockData=function(t,e){return i.map(t,(function(t){if(i.isArray(e)){var n=e[0],o=e[1],a=e[2],s=e[3];t[r.TREND_FIELD]=t[n]<=t[o]?r.TREND_UP:r.TREND_DOWN,t[r.Y_FIELD]=[t[n],t[o],t[a],t[s]]}return t}))}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.Funnel=e.FUNNEL_CONVERSATION_FIELD=void 0;var i=n(1),r=n(0),o=n(7),a=n(2),s=(n(316),n(154)),c=n(48);Object.defineProperty(e,"FUNNEL_CONVERSATION_FIELD",{enumerable:!0,get:function(){return c.FUNNEL_CONVERSATION}});var l=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="funnel",e}return i.__extends(e,t),e.getDefaultOptions=function(){return c.DEFAULT_OPTIONS},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return s.adaptor},e.prototype.setState=function(t,e,n){void 0===n&&(n=!0);var i=a.getAllElementsRecursively(this.chart);r.each(i,(function(i){e(i.getData())&&i.setState(t,n)}))},e.prototype.getStates=function(){var t=a.getAllElementsRecursively(this.chart),e=[];return r.each(t,(function(t){var n=t.getData(),i=t.getStates();r.each(i,(function(i){e.push({data:n,state:i,geometry:t.geometry,element:t})}))})),e},e.CONVERSATION_FIELD=c.FUNNEL_CONVERSATION,e.PERCENT_FIELD=c.FUNNEL_PERCENT,e.TOTAL_PERCENT_FIELD=c.FUNNEL_TOTAL_PERCENT,e}(o.Plot);e.Funnel=l},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.adaptor=e.meta=void 0;var i=n(0),r=n(12),o=n(62),a=n(2),s=n(117),c=n(155),l=n(317),u=n(318),h=n(319),f=n(48);function p(t){var e,n=t.options,r=n.compareField,c=n.xField,l=n.yField,u=n.locale,h=n.funnelStyle,p=n.data,d=o.getLocale(u),g={label:r?{fields:[c,l,r,f.FUNNEL_PERCENT,f.FUNNEL_CONVERSATION],formatter:function(t){return""+t[l]}}:{fields:[c,l,f.FUNNEL_PERCENT,f.FUNNEL_CONVERSATION],offset:0,position:"middle",formatter:function(t){return t[c]+" "+t[l]}},tooltip:{title:c,formatter:function(t){return{name:t[c],value:t[l]}}},conversionTag:{formatter:function(t){return d.get(["conversionTag","label"])+": "+s.conversionTagFormatter.apply(void 0,t[f.FUNNEL_CONVERSATION])}}};return(r||h)&&(e=function(t){return a.deepAssign({},r&&{lineWidth:1,stroke:"#fff"},i.isFunction(h)?h(t):h)}),a.deepAssign({options:g},t,{options:{funnelStyle:e,data:i.clone(p)}})}function d(t){var e=t.options,n=e.compareField,i=e.dynamicHeight;return e.seriesField?u.facetFunnel(t):n?l.compareFunnel(t):i?h.dynamicHeightFunnel(t):c.basicFunnel(t)}function g(t){var e,n=t.options,i=n.xAxis,o=n.yAxis,s=n.xField,c=n.yField;return a.flow(r.scale(((e={})[s]=i,e[c]=o,e)))(t)}function y(t){return t.chart.axis(!1),t}function v(t){var e=t.chart,n=t.options.legend;return!1===n?e.legend(!1):e.legend(n),t}e.meta=g,e.adaptor=function(t){return a.flow(p,d,g,y,r.tooltip,r.interaction,v,r.animation,r.theme,r.annotation())(t)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.basicFunnel=void 0;var i=n(1),r=n(0),o=n(2),a=n(31),s=n(27),c=n(48),l=n(87);function u(t){var e=t.chart,n=t.options,i=n.data,r=void 0===i?[]:i,o=n.yField,a=n.maxSize,s=n.minSize,c=l.transformData(r,r,{yField:o,maxSize:a,minSize:s});return e.data(c),t}function h(t){var e=t.chart,n=t.options,i=n.xField,l=n.yField,u=n.color,h=n.tooltip,f=n.label,p=n.shape,d=void 0===p?"funnel":p,g=n.funnelStyle,y=n.state,v=a.getTooltipMapping(h,[i,l]),m=v.fields,x=v.formatter;return s.geometry({chart:e,options:{type:"interval",xField:i,yField:c.FUNNEL_MAPPING_VALUE,colorField:i,tooltipFields:r.isArray(m)&&m.concat([c.FUNNEL_PERCENT,c.FUNNEL_CONVERSATION]),mapping:{shape:d,tooltip:x,color:u,style:g},label:f,state:y}}),o.findGeometry(t.chart,"interval").adjust("symmetric"),t}function f(t){var e=t.chart,n=t.options.isTransposed;return e.coordinate({type:"rect",actions:n?[]:[["transpose"],["scale",1,-1]]}),t}function p(t){var e=t.options.maxSize;return l.conversionTagComponent((function(t,n,r,o){var a=e-(e-t[c.FUNNEL_MAPPING_VALUE])/2;return i.__assign(i.__assign({},o),{start:[n-.5,a],end:[n-.5,a+.05]})}))(t),t}e.basicFunnel=function(t){return o.flow(u,h,f,p)(t)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getLiquidData=void 0;e.getLiquidData=function(t){return[{percent:t,type:"liquid"}]}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.addWaterWave=void 0;var i=n(1),r=n(9),o=n(0),a=n(127);function s(t,e,n){return t+(e-t)*n}function c(t,e,n,i){return 0===e?[[t+.5*n/Math.PI/2,i/2],[t+.5*n/Math.PI,i],[t+n/4,i]]:1===e?[[t+.5*n/Math.PI/2*(Math.PI-2),i],[t+.5*n/Math.PI/2*(Math.PI-1),i/2],[t+n/4,0]]:2===e?[[t+.5*n/Math.PI/2,-i/2],[t+.5*n/Math.PI,-i],[t+n/4,-i]]:[[t+.5*n/Math.PI/2*(Math.PI-2),-i],[t+.5*n/Math.PI/2*(Math.PI-1),-i/2],[t+n/4,0]]}function l(t,e,n,i,r,o,a){for(var s=4*Math.ceil(2*t/n*4),l=[],u=i;u<2*-Math.PI;)u+=2*Math.PI;for(;u>0;)u-=2*Math.PI;var h=o-t+(u=u/Math.PI/2*n)-2*t;l.push(["M",h,e]);for(var f=0,p=0;p1?i+"_"+o:""+i})[n]=n?t[n]:String(e),a[i]=r,a))})),s.push(((a={tKey:""+o})[n]=n?t[n]:String(e),a[o]=t[o],a)),c.push(t[r],t[i],t[o])}));var l=Math.min.apply(Math,c.flat(1/0)),u=Math.max.apply(Math,c.flat(1/0));return l=l>0?0:l,"vertical"===a&&s.reverse(),{min:l,max:u,ds:s}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.treemap=e.getTileMethod=void 0;var i=n(1).__importStar(n(93)),r=n(0),o=n(58),a={field:"value",tile:"treemapSquarify",size:[1,1],round:!1,ignoreParentValue:!0,padding:0,paddingInner:0,paddingOuter:0,paddingTop:0,paddingRight:0,paddingBottom:0,paddingLeft:0,as:["x","y"],sort:function(t,e){return e.value-t.value},ratio:.5*(1+Math.sqrt(5))};function s(t,e){return"treemapSquarify"===t?i[t].ratio(e):i[t]}e.getTileMethod=s,e.treemap=function(t,e){var n,c=(e=r.assign({},a,e)).as;if(!r.isArray(c)||2!==c.length)throw new TypeError('Invalid as: it must be an array with 2 strings (e.g. [ "x", "y" ])!');try{n=o.getField(e)}catch(t){console.warn(t)}var l=s(e.tile,e.ratio),u=function(t){return i.treemap().tile(l).size(e.size).round(e.round).padding(e.padding).paddingInner(e.paddingInner).paddingOuter(e.paddingOuter).paddingTop(e.paddingTop).paddingRight(e.paddingRight).paddingBottom(e.paddingBottom).paddingLeft(e.paddingLeft)(i.hierarchy(t).sum((function(t){return e.ignoreParentValue&&t.children?0:t[n]})).sort(e.sort))}(t),h=c[0],f=c[1];return u.each((function(t){t[h]=[t.x0,t.x1,t.x1,t.x0],t[f]=[t.y1,t.y1,t.y0,t.y0],["x0","x1","y0","y1"].forEach((function(e){-1===c.indexOf(e)&&delete t[e]}))})),o.getAllNodes(u)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.Gauge=void 0;var i=n(1),r=n(9),o=n(7),a=(n(336),n(161)),s=n(66),c=n(162);n(337),n(338);var l=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="gauge",e}return i.__extends(e,t),e.getDefaultOptions=function(){return s.DEFAULT_OPTIONS},e.prototype.changeData=function(t){this.chart.emit(r.VIEW_LIFE_CIRCLE.BEFORE_CHANGE_DATA,r.Event.fromData(this.chart,r.VIEW_LIFE_CIRCLE.BEFORE_CHANGE_DATA,null)),this.updateOption({percent:t});var e=this.chart.views.find((function(t){return t.id===s.INDICATEOR_VIEW_ID}));e&&e.data(c.getIndicatorData(t));var n=this.chart.views.find((function(t){return t.id===s.RANGE_VIEW_ID}));n&&n.data(c.getRangeData(t,this.options.range)),a.statistic({chart:this.chart,options:this.options},!0),this.chart.emit(r.VIEW_LIFE_CIRCLE.AFTER_CHANGE_DATA,r.Event.fromData(this.chart,r.VIEW_LIFE_CIRCLE.AFTER_CHANGE_DATA,null))},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return a.adaptor},e}(o.Plot);e.Gauge=l},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.adaptor=e.statistic=void 0;var i=n(1),r=n(0),o=n(12),a=n(18),s=n(37),c=n(2),l=n(66),u=n(162);function h(t){var e=t.chart,n=t.options,i=n.percent,o=n.range,h=n.radius,f=n.innerRadius,p=n.startAngle,d=n.endAngle,g=n.axis,y=n.indicator,v=n.gaugeStyle,m=n.type,x=n.meter,b=o.color,O=o.width;if(y){var _=u.getIndicatorData(i),w=e.createView({id:l.INDICATEOR_VIEW_ID});w.data(_),w.point().position(l.PERCENT+"*1").shape(y.shape||"gauge-indicator").customInfo({defaultColor:e.getTheme().defaultColor,indicator:y}),w.coordinate("polar",{startAngle:p,endAngle:d,radius:f*h}),w.axis(l.PERCENT,g),w.scale(l.PERCENT,c.pick(g,s.AXIS_META_CONFIG_KEYS))}var j=u.getRangeData(i,n.range),S=e.createView({id:l.RANGE_VIEW_ID});S.data(j);var M=r.isString(b)?[b,l.DEFAULT_COLOR]:b;return a.interval({chart:S,options:{xField:"1",yField:l.RANGE_VALUE,seriesField:l.RANGE_TYPE,rawFields:[l.PERCENT],isStack:!0,interval:{color:M,style:v,shape:"meter"===m?"meter-gauge":null},args:{zIndexReversed:!0,sortZIndex:!0},minColumnWidth:O,maxColumnWidth:O}}).ext.geometry.customInfo({meter:x}),S.coordinate("polar",{innerRadius:f,radius:h,startAngle:p,endAngle:d}).transpose(),t}function f(t){var e;return c.flow(o.scale(((e={range:{min:0,max:1,maxLimit:1,minLimit:0}})[l.PERCENT]={},e)))(t)}function p(t,e){var n=t.chart,r=t.options,o=r.statistic,a=r.percent;if(n.getController("annotation").clear(!0),o){var s=o.content,l=void 0;s&&(l=c.deepAssign({},{content:(100*a).toFixed(2)+"%",style:{opacity:.75,fontSize:"30px",lineHeight:1,textAlign:"center",color:"rgba(44,53,66,0.85)"}},s)),c.renderGaugeStatistic(n,{statistic:i.__assign(i.__assign({},o),{content:l})},{percent:a})}return e&&n.render(!0),t}function d(t){var e=t.chart,n=t.options.tooltip;return n?e.tooltip(c.deepAssign({showTitle:!1,showMarkers:!1,containerTpl:'
',domStyles:{"g2-tooltip":{padding:"4px 8px",fontSize:"10px"}},customContent:function(t,e){return(100*r.get(e,[0,"data",l.PERCENT],0)).toFixed(2)+"%"}},n)):e.tooltip(!1),t}function g(t){return t.chart.legend(!1),t}e.statistic=p,e.adaptor=function(t){return c.flow(o.theme,o.animation,h,f,d,p,o.interaction,o.annotation(),g)(t)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getRangeData=e.getIndicatorData=e.processRangeData=void 0;var i=n(0),r=n(66);function o(t,e){return t.map((function(n,i){var o;return(o={})[r.RANGE_VALUE]=n-(t[i-1]||0),o[r.RANGE_TYPE]=""+i,o[r.PERCENT]=e,o})).filter((function(t){return!!t[r.RANGE_VALUE]}))}e.processRangeData=o,e.getIndicatorData=function(t){var e;return[(e={},e[r.PERCENT]=i.clamp(t,0,1),e)]},e.getRangeData=function(t,e){var n=i.get(e,["ticks"],[]);return o(i.size(n)?n:[0,i.clamp(t,0,1),1],t)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.transformData=e.processData=void 0;var i=n(1),r=n(0),o=n(2),a=n(90);function s(t,e,n,a,s){var c,l=[];if(r.reduce(t,(function(t,e){var s;o.log(o.LEVEL.WARN,r.isNumber(e[n]),e[n]+" is not a valid number");var c=r.isUndefined(e[n])?null:e[n];return l.push(i.__assign(i.__assign({},e),((s={})[a]=[t,t+c],s))),t+c}),0),l.length&&s){var u=r.get(l,[[t.length-1],a,[1]]);l.push(((c={})[e]=s.label,c[n]=u,c[a]=[0,u],c))}return l}e.processData=s,e.transformData=function(t,e,n,o){return s(t,e,n,a.Y_FIELD,o).map((function(e,n){var o;return r.isObject(e)?i.__assign(i.__assign({},e),((o={})[a.ABSOLUTE_FIELD]=e[a.Y_FIELD][1],o[a.DIFF_FIELD]=e[a.Y_FIELD][1]-e[a.Y_FIELD][0],o[a.IS_TOTAL]=n===t.length,o)):e}))}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.SERIES_FIELD_KEY=e.SECOND_AXES_VIEW=e.FIRST_AXES_VIEW=void 0,e.FIRST_AXES_VIEW="first-axes-view",e.SECOND_AXES_VIEW="second-axes-view",e.SERIES_FIELD_KEY="series-field-key"},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.syncViewPadding=e.isHorizontal=e.transformData=void 0;var i=n(0);function r(t){return"vertical"!==t}e.transformData=function(t,e,n,r,o){var a=[];e.forEach((function(e){r.forEach((function(i){var r,o=((r={})[t]=i[t],r[n]=e,r[e]=i[e],r);a.push(o)}))}));var s=Object.values(i.groupBy(a,n)),c=s[0],l=void 0===c?[]:c,u=s[1],h=void 0===u?[]:u;return o?[l.reverse(),h.reverse()]:[l,h]},e.isHorizontal=r,e.syncViewPadding=function(t,e,n){var i=e[0],o=e[1],a=i.autoPadding,s=o.autoPadding,c=t.__axisPosition,l=c.layout,u=c.position;if(r(l)&&"top"===u&&(i.autoPadding=n.instance(a.top,0,a.bottom,a.left),o.autoPadding=n.instance(s.top,a.left,s.bottom,0)),r(l)&&"bottom"===u&&(i.autoPadding=n.instance(a.top,a.right/2+5,a.bottom,a.left),o.autoPadding=n.instance(s.top,s.right,s.bottom,a.right/2+5)),!r(l)&&"bottom"===u){var h=a.left>=s.left?a.left:s.left;i.autoPadding=n.instance(a.top,a.right,a.bottom/2+5,h),o.autoPadding=n.instance(a.bottom/2+5,s.right,s.bottom,h)}if(!r(l)&&"top"===u){h=a.left>=s.left?a.left:s.left;i.autoPadding=n.instance(a.top,a.right,0,h),o.autoPadding=n.instance(0,s.right,a.top,h)}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.transformData=e.resetDrillDown=e.enableDrillInteraction=e.enableInteraction=e.findInteraction=void 0;var i=n(1),r=n(0),o=n(65),a=n(159);function s(t,e){if(r.isArray(t))return t.find((function(t){return t.type===e}))}function c(t,e){var n=s(t,e);return n&&!1!==n.enable}e.findInteraction=s,e.enableInteraction=c,e.enableDrillInteraction=function(t){var e=t.interactions,n=t.drilldown;return r.get(n,"enabled")||c(e,"treemap-drill-down")},e.resetDrillDown=function(t){var e=t.interactions["drill-down"];e&&e.context.actions.find((function(t){return"drill-down-action"===t.name})).reset()},e.transformData=function(t){var e=t.data,n=t.colorField,s=t.enableDrillDown,c=t.hierarchyConfig,l=a.treemap(e,i.__assign(i.__assign({},c),{type:"hierarchy.treemap",field:"value",as:["x","y"]})),u=[];return l.forEach((function(t){if(0===t.depth)return null;if(s&&1!==t.depth)return null;if(!s&&t.children)return null;var a=t.ancestors().map((function(t){return{data:t.data,height:t.height,value:t.value}})),l=s&&r.isArray(e.path)?a.concat(e.path.slice(1)):a,h=Object.assign({},t.data,i.__assign({x:t.x,y:t.y,depth:t.depth,value:t.value,path:l},t));if(!t.data[n]&&t.parent){var f=t.ancestors().find((function(t){return t.data[n]}));h[n]=null==f?void 0:f.data[n]}else h[n]=t.data[n];h[o.HIERARCHY_DATA_TRANSFORM_PARAMS]={hierarchyConfig:c,colorField:n,enableDrillDown:s},u.push(h)})),u}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.transformToViewsData=e.getNodePaddingRatio=e.getNodeWidthRatio=void 0;var i=n(1),r=n(2),o=n(63),a=n(359),s=n(363);function c(t,e,n){return r.isRealNumber(t)?t/n:e}function l(t,e,n){return r.isRealNumber(t)?t/n:e}e.getNodeWidthRatio=c,e.getNodePaddingRatio=l,e.transformToViewsData=function(t,e,n){var u,h=t.dataType,f=t.data,p=t.sourceField,d=t.targetField,g=t.weightField,y=t.nodeAlign,v=t.nodeSort,m=t.nodePadding,x=t.nodePaddingRatio,b=t.nodeWidth,O=t.nodeWidthRatio,_=t.nodeDepth,w=t.rawFields,j=void 0===w?[]:w;u=function(t){return"node-link"===t}(h)?f:o.transformDataToNodeLinkData(s.cutoffCircle(f,p,d),p,d,g,j);var S=a.sankeyLayout({nodeAlign:y,nodePadding:l(m,x,n),nodeWidth:c(b,O,e),nodeSort:v,nodeDepth:_},u),M=S.nodes,A=S.links;return{nodes:M.map((function(t){return i.__assign(i.__assign({},r.pick(t,i.__spreadArrays(["x","y","name"],j))),{isNode:!0})})),edges:A.map((function(t){return i.__assign(i.__assign({source:t.source.name,target:t.target.name,name:t.source.name||t.target.name},r.pick(t,i.__spreadArrays(["x","y","value"],j))),{isNode:!1})}))}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.center=e.justify=e.right=e.left=void 0;var i=n(0);function r(t){return t.target.depth}e.left=function(t){return t.depth},e.right=function(t,e){return e-1-t.height},e.justify=function(t,e){return t.sourceLinks.length?t.depth:e-1},e.center=function(t){return t.targetLinks.length?t.depth:t.sourceLinks.length?i.minBy(t.sourceLinks,r)-1:0}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DEFAULT_OPTIONS=e.EDGE_COLOR_FIELD=e.NODE_COLOR_FIELD=e.Y_FIELD=e.X_FIELD=void 0;var i=n(0);e.X_FIELD="x",e.Y_FIELD="y",e.NODE_COLOR_FIELD="name",e.EDGE_COLOR_FIELD="source",e.DEFAULT_OPTIONS={nodeStyle:{opacity:1,fillOpacity:1,lineWidth:1},edgeStyle:{opacity:.5,lineWidth:2},label:{fields:["x","name"],callback:function(t,e){return{labelEmit:!0,style:{fill:"#8c8c8c"},offsetX:(t[0]+t[1])/2>.5?-4:4,content:e}}},tooltip:{showTitle:!1,showMarkers:!1,fields:["source","target","value","isNode"],showContent:function(t){return!i.get(t,[0,"data","isNode"])},formatter:function(t){return{name:t.source+" -> "+t.target,value:t.value}}},interactions:[{type:"element-active"}],weight:!0,nodePaddingRatio:.1,nodeWidthRatio:.05}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DEFAULT_OPTIONS=e.RAW_FIELDS=void 0,e.RAW_FIELDS=["x","y","r","name","value","path","depth"],e.DEFAULT_OPTIONS={colorField:"name",autoFit:!0,pointStyle:{lineWidth:0,stroke:"#fff"},legend:!1,hierarchyConfig:{size:[1,1],padding:0},label:{fields:["name"],layout:{type:"limit-in-shape"}},tooltip:{showMarkers:!1,showTitle:!1},drilldown:{enabled:!1}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.execPlotAdaptor=void 0;var i=n(0),r=n(2),o=n(78),a=n(123),s=n(55),c=n(121),l=n(115),u=n(161),h=n(135),f=n(137),p=n(64),d=n(146),g=n(82),y=n(131),v=n(141),m=n(154),x=n(110),b=n(122),O=n(120),_=n(116),w=n(114),j=n(160),S=n(134),M=n(138),A=n(136),C=n(145),E=n(143),I=n(130),P=n(139),F=n(153),T={line:o.adaptor,pie:a.adaptor,column:s.adaptor,bar:c.adaptor,area:l.adaptor,gauge:u.adaptor,"tiny-line":h.adaptor,"tiny-column":f.adaptor,"tiny-area":p.adaptor,"ring-progress":d.adaptor,progress:g.adaptor,scatter:y.adaptor,histogram:v.adaptor,funnel:m.adaptor},L={line:x.Line,pie:b.Pie,column:_.Column,bar:O.Bar,area:w.Area,gauge:j.Gauge,"tiny-line":S.TinyLine,"tiny-column":A.TinyColumn,"tiny-area":M.TinyArea,"ring-progress":C.RingProgress,progress:E.Progress,scatter:I.Scatter,histogram:P.Histogram,funnel:F.Funnel},k={pie:{label:!1},column:{tooltip:{showMarkers:!1}},bar:{tooltip:{showMarkers:!1}}};e.execPlotAdaptor=function(t,e,n){var o=L[t];o?(0,T[t])({chart:e,options:r.deepAssign({},o.getDefaultOptions(),i.get(k,t,{}),n)}):console.error("could not find "+t+" plot")}},function(t,e,n){"use strict";var i={};n.r(i),n.d(i,"easeLinear",(function(){return A})),n.d(i,"easeQuad",(function(){return I})),n.d(i,"easeQuadIn",(function(){return C})),n.d(i,"easeQuadOut",(function(){return E})),n.d(i,"easeQuadInOut",(function(){return I})),n.d(i,"easeCubic",(function(){return T})),n.d(i,"easeCubicIn",(function(){return P})),n.d(i,"easeCubicOut",(function(){return F})),n.d(i,"easeCubicInOut",(function(){return T})),n.d(i,"easePoly",(function(){return D})),n.d(i,"easePolyIn",(function(){return L})),n.d(i,"easePolyOut",(function(){return k})),n.d(i,"easePolyInOut",(function(){return D})),n.d(i,"easeSin",(function(){return z})),n.d(i,"easeSinIn",(function(){return N})),n.d(i,"easeSinOut",(function(){return V})),n.d(i,"easeSinInOut",(function(){return z})),n.d(i,"easeExp",(function(){return W})),n.d(i,"easeExpIn",(function(){return Y})),n.d(i,"easeExpOut",(function(){return X})),n.d(i,"easeExpInOut",(function(){return W})),n.d(i,"easeCircle",(function(){return q})),n.d(i,"easeCircleIn",(function(){return H})),n.d(i,"easeCircleOut",(function(){return U})),n.d(i,"easeCircleInOut",(function(){return q})),n.d(i,"easeBounce",(function(){return K})),n.d(i,"easeBounceIn",(function(){return $})),n.d(i,"easeBounceOut",(function(){return K})),n.d(i,"easeBounceInOut",(function(){return Q})),n.d(i,"easeBack",(function(){return et})),n.d(i,"easeBackIn",(function(){return J})),n.d(i,"easeBackOut",(function(){return tt})),n.d(i,"easeBackInOut",(function(){return et})),n.d(i,"easeElastic",(function(){return rt})),n.d(i,"easeElasticIn",(function(){return it})),n.d(i,"easeElasticOut",(function(){return rt})),n.d(i,"easeElasticInOut",(function(){return ot}));var r=n(1),o=n(74),a=n(72),s=n(14),c=n(0);function l(t){return(l="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}var u,h,f=0,p=0,d=0,g=0,y=0,v=0,m="object"===("undefined"==typeof performance?"undefined":l(performance))&&performance.now?performance:Date,x="object"===("undefined"==typeof window?"undefined":l(window))&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(t){setTimeout(t,17)};function b(){return y||(x(O),y=m.now()+v)}function O(){y=0}function _(){this._call=this._time=this._next=null}function w(t,e,n){var i=new _;return i.restart(t,e,n),i}function j(){y=(g=m.now())+v,f=p=0;try{!function(){b(),++f;for(var t,e=u;e;)(t=y-e._time)>=0&&e._call.call(null,t),e=e._next;--f}()}finally{f=0,function(){var t,e,n=u,i=1/0;for(;n;)n._call?(i>n._time&&(i=n._time),t=n,n=n._next):(e=n._next,n._next=null,n=t?t._next=e:u=e);h=t,M(i)}(),y=0}}function S(){var t=m.now(),e=t-g;e>1e3&&(v-=e,g=t)}function M(t){f||(p&&(p=clearTimeout(p)),t-y>24?(t<1/0&&(p=setTimeout(j,t-m.now()-v)),d&&(d=clearInterval(d))):(d||(g=m.now(),d=setInterval(S,1e3)),f=1,x(j)))}function A(t){return+t}function C(t){return t*t}function E(t){return t*(2-t)}function I(t){return((t*=2)<=1?t*t:--t*(2-t)+1)/2}function P(t){return t*t*t}function F(t){return--t*t*t+1}function T(t){return((t*=2)<=1?t*t*t:(t-=2)*t*t+2)/2}_.prototype=w.prototype={constructor:_,restart:function(t,e,n){if("function"!=typeof t)throw new TypeError("callback is not a function");n=(null==n?b():+n)+(null==e?0:+e),this._next||h===this||(h?h._next=this:u=this,h=this),this._call=t,this._time=n,M()},stop:function(){this._call&&(this._call=null,this._time=1/0,M())}};var L=function t(e){function n(t){return Math.pow(t,e)}return e=+e,n.exponent=t,n}(3),k=function t(e){function n(t){return 1-Math.pow(1-t,e)}return e=+e,n.exponent=t,n}(3),D=function t(e){function n(t){return((t*=2)<=1?Math.pow(t,e):2-Math.pow(2-t,e))/2}return e=+e,n.exponent=t,n}(3),B=Math.PI,R=B/2;function N(t){return 1==+t?1:1-Math.cos(t*R)}function V(t){return Math.sin(t*R)}function z(t){return(1-Math.cos(B*t))/2}function G(t){return 1.0009775171065494*(Math.pow(2,-10*t)-.0009765625)}function Y(t){return G(1-+t)}function X(t){return 1-G(t)}function W(t){return((t*=2)<=1?G(1-t):2-G(t-1))/2}function H(t){return 1-Math.sqrt(1-t*t)}function U(t){return Math.sqrt(1- --t*t)}function q(t){return((t*=2)<=1?1-Math.sqrt(1-t*t):Math.sqrt(1-(t-=2)*t)+1)/2}var Z=7.5625;function $(t){return 1-K(1-t)}function K(t){return(t=+t)<4/11?Z*t*t:t<8/11?Z*(t-=6/11)*t+3/4:t<10/11?Z*(t-=9/11)*t+15/16:Z*(t-=21/22)*t+63/64}function Q(t){return((t*=2)<=1?1-K(1-t):K(t-1)+1)/2}var J=function t(e){function n(t){return(t=+t)*t*(e*(t-1)+t)}return e=+e,n.overshoot=t,n}(1.70158),tt=function t(e){function n(t){return--t*t*((t+1)*e+t)+1}return e=+e,n.overshoot=t,n}(1.70158),et=function t(e){function n(t){return((t*=2)<1?t*t*((e+1)*t-e):(t-=2)*t*((e+1)*t+e)+2)/2}return e=+e,n.overshoot=t,n}(1.70158),nt=2*Math.PI,it=function t(e,n){var i=Math.asin(1/(e=Math.max(1,e)))*(n/=nt);function r(t){return e*G(- --t)*Math.sin((i-t)/n)}return r.amplitude=function(e){return t(e,n*nt)},r.period=function(n){return t(e,n)},r}(1,.3),rt=function t(e,n){var i=Math.asin(1/(e=Math.max(1,e)))*(n/=nt);function r(t){return 1-e*G(t=+t)*Math.sin((t+i)/n)}return r.amplitude=function(e){return t(e,n*nt)},r.period=function(n){return t(e,n)},r}(1,.3),ot=function t(e,n){var i=Math.asin(1/(e=Math.max(1,e)))*(n/=nt);function r(t){return((t=2*t-1)<0?e*G(-t)*Math.sin((i-t)/n):2-e*G(t)*Math.sin((i+t)/n))/2}return r.amplitude=function(e){return t(e,n*nt)},r.period=function(n){return t(e,n)},r}(1,.3),at=function(t,e,n){t.prototype=e.prototype=n,n.constructor=t};function st(t,e){var n=Object.create(t.prototype);for(var i in e)n[i]=e[i];return n}function ct(){}var lt="\\s*([+-]?\\d+)\\s*",ut="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)\\s*",ht="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)%\\s*",ft=/^#([0-9a-f]{3,8})$/,pt=new RegExp("^rgb\\("+[lt,lt,lt]+"\\)$"),dt=new RegExp("^rgb\\("+[ht,ht,ht]+"\\)$"),gt=new RegExp("^rgba\\("+[lt,lt,lt,ut]+"\\)$"),yt=new RegExp("^rgba\\("+[ht,ht,ht,ut]+"\\)$"),vt=new RegExp("^hsl\\("+[ut,ht,ht]+"\\)$"),mt=new RegExp("^hsla\\("+[ut,ht,ht,ut]+"\\)$"),xt={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};function bt(){return this.rgb().formatHex()}function Ot(){return this.rgb().formatRgb()}function _t(t){var e,n;return t=(t+"").trim().toLowerCase(),(e=ft.exec(t))?(n=e[1].length,e=parseInt(e[1],16),6===n?wt(e):3===n?new At(e>>8&15|e>>4&240,e>>4&15|240&e,(15&e)<<4|15&e,1):8===n?jt(e>>24&255,e>>16&255,e>>8&255,(255&e)/255):4===n?jt(e>>12&15|e>>8&240,e>>8&15|e>>4&240,e>>4&15|240&e,((15&e)<<4|15&e)/255):null):(e=pt.exec(t))?new At(e[1],e[2],e[3],1):(e=dt.exec(t))?new At(255*e[1]/100,255*e[2]/100,255*e[3]/100,1):(e=gt.exec(t))?jt(e[1],e[2],e[3],e[4]):(e=yt.exec(t))?jt(255*e[1]/100,255*e[2]/100,255*e[3]/100,e[4]):(e=vt.exec(t))?Pt(e[1],e[2]/100,e[3]/100,1):(e=mt.exec(t))?Pt(e[1],e[2]/100,e[3]/100,e[4]):xt.hasOwnProperty(t)?wt(xt[t]):"transparent"===t?new At(NaN,NaN,NaN,0):null}function wt(t){return new At(t>>16&255,t>>8&255,255&t,1)}function jt(t,e,n,i){return i<=0&&(t=e=n=NaN),new At(t,e,n,i)}function St(t){return t instanceof ct||(t=_t(t)),t?new At((t=t.rgb()).r,t.g,t.b,t.opacity):new At}function Mt(t,e,n,i){return 1===arguments.length?St(t):new At(t,e,n,null==i?1:i)}function At(t,e,n,i){this.r=+t,this.g=+e,this.b=+n,this.opacity=+i}function Ct(){return"#"+It(this.r)+It(this.g)+It(this.b)}function Et(){var t=this.opacity;return(1===(t=isNaN(t)?1:Math.max(0,Math.min(1,t)))?"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===t?")":", "+t+")")}function It(t){return((t=Math.max(0,Math.min(255,Math.round(t)||0)))<16?"0":"")+t.toString(16)}function Pt(t,e,n,i){return i<=0?t=e=n=NaN:n<=0||n>=1?t=e=NaN:e<=0&&(t=NaN),new Tt(t,e,n,i)}function Ft(t){if(t instanceof Tt)return new Tt(t.h,t.s,t.l,t.opacity);if(t instanceof ct||(t=_t(t)),!t)return new Tt;if(t instanceof Tt)return t;var e=(t=t.rgb()).r/255,n=t.g/255,i=t.b/255,r=Math.min(e,n,i),o=Math.max(e,n,i),a=NaN,s=o-r,c=(o+r)/2;return s?(a=e===o?(n-i)/s+6*(n0&&c<1?0:a,new Tt(a,s,c,t.opacity)}function Tt(t,e,n,i){this.h=+t,this.s=+e,this.l=+n,this.opacity=+i}function Lt(t,e,n){return 255*(t<60?e+(n-e)*t/60:t<180?n:t<240?e+(n-e)*(240-t)/60:e)}function kt(t,e,n,i,r){var o=t*t,a=o*t;return((1-3*t+3*o-a)*e+(4-6*o+3*a)*n+(1+3*t+3*o-3*a)*i+a*r)/6}at(ct,_t,{copy:function(t){return Object.assign(new this.constructor,this,t)},displayable:function(){return this.rgb().displayable()},hex:bt,formatHex:bt,formatHsl:function(){return Ft(this).formatHsl()},formatRgb:Ot,toString:Ot}),at(At,Mt,st(ct,{brighter:function(t){return t=null==t?1/.7:Math.pow(1/.7,t),new At(this.r*t,this.g*t,this.b*t,this.opacity)},darker:function(t){return t=null==t?.7:Math.pow(.7,t),new At(this.r*t,this.g*t,this.b*t,this.opacity)},rgb:function(){return this},displayable:function(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:Ct,formatHex:Ct,formatRgb:Et,toString:Et})),at(Tt,(function(t,e,n,i){return 1===arguments.length?Ft(t):new Tt(t,e,n,null==i?1:i)}),st(ct,{brighter:function(t){return t=null==t?1/.7:Math.pow(1/.7,t),new Tt(this.h,this.s,this.l*t,this.opacity)},darker:function(t){return t=null==t?.7:Math.pow(.7,t),new Tt(this.h,this.s,this.l*t,this.opacity)},rgb:function(){var t=this.h%360+360*(this.h<0),e=isNaN(t)||isNaN(this.s)?0:this.s,n=this.l,i=n+(n<.5?n:1-n)*e,r=2*n-i;return new At(Lt(t>=240?t-240:t+120,r,i),Lt(t,r,i),Lt(t<120?t+240:t-120,r,i),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},formatHsl:function(){var t=this.opacity;return(1===(t=isNaN(t)?1:Math.max(0,Math.min(1,t)))?"hsl(":"hsla(")+(this.h||0)+", "+100*(this.s||0)+"%, "+100*(this.l||0)+"%"+(1===t?")":", "+t+")")}}));var Dt=function(t){return function(){return t}};function Bt(t,e){return function(n){return t+n*e}}function Rt(t){return 1==(t=+t)?Nt:function(e,n){return n-e?function(t,e,n){return t=Math.pow(t,n),e=Math.pow(e,n)-t,n=1/n,function(i){return Math.pow(t+i*e,n)}}(e,n,t):Dt(isNaN(e)?n:e)}}function Nt(t,e){var n=e-t;return n?Bt(t,n):Dt(isNaN(t)?e:t)}var Vt=function t(e){var n=Rt(e);function i(t,e){var i=n((t=Mt(t)).r,(e=Mt(e)).r),r=n(t.g,e.g),o=n(t.b,e.b),a=Nt(t.opacity,e.opacity);return function(e){return t.r=i(e),t.g=r(e),t.b=o(e),t.opacity=a(e),t+""}}return i.gamma=t,i}(1);function zt(t){return function(e){var n,i,r=e.length,o=new Array(r),a=new Array(r),s=new Array(r);for(n=0;n=1?(n=1,e-1):Math.floor(n*e),r=t[i],o=t[i+1],a=i>0?t[i-1]:2*r-o,s=io&&(r=e.slice(o,r),s[a]?s[a]+=r:s[++a]=r),(n=n[0])===(i=i[0])?s[a]?s[a]+=i:s[++a]=i:(s[++a]=null,c.push({i:a,x:Ht(n,i)})),o=$t.lastIndex;return op.length?(f=te.parsePathString(o[h]),p=te.parsePathString(r[h]),p=te.fillPathByDiff(p,f),p=te.formatPath(p,f),e.fromAttrs.path=p,e.toAttrs.path=f):e.pathFormatted||(f=te.parsePathString(o[h]),p=te.parsePathString(r[h]),p=te.formatPath(p,f),e.fromAttrs.path=p,e.toAttrs.path=f,e.pathFormatted=!0),i[h]=[];for(var d=0;d0){for(var o=i.animators.length-1;o>=0;o--)if((t=i.animators[o]).destroyed)i.removeAnimator(o);else{if(!t.isAnimatePaused())for(var a=(e=t.get("animations")).length-1;a>=0;a--)n=e[a],ne(t,n,r)&&(e.splice(a,1),!1,n.callback&&n.callback());0===e.length&&i.removeAnimator(o)}i.canvas.get("autoDraw")||i.canvas.draw()}}))},t.prototype.addAnimator=function(t){this.animators.push(t)},t.prototype.removeAnimator=function(t){this.animators.splice(t,1)},t.prototype.isAnimating=function(){return!!this.animators.length},t.prototype.stop=function(){this.timer&&this.timer.stop()},t.prototype.stopAllAnimations=function(t){void 0===t&&(t=!0),this.animators.forEach((function(e){e.stopAnimate(t)})),this.animators=[],this.canvas.draw()},t.prototype.getTime=function(){return this.current},t}(),re=n(67),oe=["mousedown","mouseup","dblclick","mouseout","mouseover","mousemove","mouseleave","mouseenter","touchstart","touchmove","touchend","dragenter","dragover","dragleave","drop","contextmenu","mousewheel"];function ae(t,e,n){n.name=e,n.target=t,n.currentTarget=t,n.delegateTarget=t,t.emit(e,n)}function se(t,e,n){if(n.bubbles){var i=void 0,r=!1;if("mouseenter"===e?(i=n.fromShape,r=!0):"mouseleave"===e&&(r=!0,i=n.toShape),t.isCanvas()&&r)return;if(i&&Object(s.g)(t,i))return void(n.bubbles=!1);n.name=e,n.currentTarget=t,n.delegateTarget=t,t.emit(e,n)}}var ce=function(){function t(t){var e=this;this.draggingShape=null,this.dragging=!1,this.currentShape=null,this.mousedownShape=null,this.mousedownPoint=null,this._eventCallback=function(t){var n=t.type;e._triggerEvent(n,t)},this._onDocumentMove=function(t){if(e.canvas.get("el")!==t.target&&(e.dragging||e.currentShape)){var n=e._getPointInfo(t);e.dragging&&e._emitEvent("drag",t,n,e.draggingShape)}},this._onDocumentMouseUp=function(t){if(e.canvas.get("el")!==t.target&&e.dragging){var n=e._getPointInfo(t);e.draggingShape&&e._emitEvent("drop",t,n,null),e._emitEvent("dragend",t,n,e.draggingShape),e._afterDrag(e.draggingShape,n,t)}},this.canvas=t.canvas}return t.prototype.init=function(){this._bindEvents()},t.prototype._bindEvents=function(){var t=this,e=this.canvas.get("el");Object(s.a)(oe,(function(n){e.addEventListener(n,t._eventCallback)})),document&&(document.addEventListener("mousemove",this._onDocumentMove),document.addEventListener("mouseup",this._onDocumentMouseUp))},t.prototype._clearEvents=function(){var t=this,e=this.canvas.get("el");Object(s.a)(oe,(function(n){e.removeEventListener(n,t._eventCallback)})),document&&(document.removeEventListener("mousemove",this._onDocumentMove),document.removeEventListener("mouseup",this._onDocumentMouseUp))},t.prototype._getEventObj=function(t,e,n,i,r,o){var a=new re.a(t,e);return a.fromShape=r,a.toShape=o,a.x=n.x,a.y=n.y,a.clientX=n.clientX,a.clientY=n.clientY,a.propagationPath.push(i),a},t.prototype._getShape=function(t,e){return this.canvas.getShape(t.x,t.y,e)},t.prototype._getPointInfo=function(t){var e=this.canvas,n=e.getClientByEvent(t),i=e.getPointByEvent(t);return{x:i.x,y:i.y,clientX:n.x,clientY:n.y}},t.prototype._triggerEvent=function(t,e){var n=this._getPointInfo(e),i=this._getShape(n,e),r=this["_on"+t],o=!1;if(r)r.call(this,n,i,e);else{var a=this.currentShape;"mouseenter"===t||"dragenter"===t||"mouseover"===t?(this._emitEvent(t,e,n,null,null,i),i&&this._emitEvent(t,e,n,i,null,i),"mouseenter"===t&&this.draggingShape&&this._emitEvent("dragenter",e,n,null)):"mouseleave"===t||"dragleave"===t||"mouseout"===t?(o=!0,a&&this._emitEvent(t,e,n,a,a,null),this._emitEvent(t,e,n,null,a,null),"mouseleave"===t&&this.draggingShape&&this._emitEvent("dragleave",e,n,null)):this._emitEvent(t,e,n,i,null,null)}if(o||(this.currentShape=i),i&&!i.get("destroyed")){var s=this.canvas;s.get("el").style.cursor=i.attr("cursor")||s.get("cursor")}},t.prototype._onmousedown=function(t,e,n){0===n.button&&(this.mousedownShape=e,this.mousedownPoint=t,this.mousedownTimeStamp=n.timeStamp),this._emitEvent("mousedown",n,t,e,null,null)},t.prototype._emitMouseoverEvents=function(t,e,n,i){var r=this.canvas.get("el");n!==i&&(n&&(this._emitEvent("mouseout",t,e,n,n,i),this._emitEvent("mouseleave",t,e,n,n,i),i&&!i.get("destroyed")||(r.style.cursor=this.canvas.get("cursor"))),i&&(this._emitEvent("mouseover",t,e,i,n,i),this._emitEvent("mouseenter",t,e,i,n,i)))},t.prototype._emitDragoverEvents=function(t,e,n,i,r){i?(i!==n&&(n&&this._emitEvent("dragleave",t,e,n,n,i),this._emitEvent("dragenter",t,e,i,n,i)),r||this._emitEvent("dragover",t,e,i)):n&&this._emitEvent("dragleave",t,e,n,n,i),r&&this._emitEvent("dragover",t,e,i)},t.prototype._afterDrag=function(t,e,n){t&&(t.set("capture",!0),this.draggingShape=null),this.dragging=!1;var i=this._getShape(e,n);i!==t&&this._emitMouseoverEvents(n,e,t,i),this.currentShape=i},t.prototype._onmouseup=function(t,e,n){if(0===n.button){var i=this.draggingShape;this.dragging?(i&&this._emitEvent("drop",n,t,e),this._emitEvent("dragend",n,t,i),this._afterDrag(i,t,n)):(this._emitEvent("mouseup",n,t,e),e===this.mousedownShape&&this._emitEvent("click",n,t,e),this.mousedownShape=null,this.mousedownPoint=null)}},t.prototype._ondragover=function(t,e,n){n.preventDefault();var i=this.currentShape;this._emitDragoverEvents(n,t,i,e,!0)},t.prototype._onmousemove=function(t,e,n){var i=this.canvas,r=this.currentShape,o=this.draggingShape;if(this.dragging)o&&this._emitDragoverEvents(n,t,r,e,!1),this._emitEvent("drag",n,t,o);else{var a=this.mousedownPoint;if(a){var s=this.mousedownShape,c=n.timeStamp-this.mousedownTimeStamp,l=a.clientX-t.clientX,u=a.clientY-t.clientY;c>120||l*l+u*u>40?s&&s.get("draggable")?((o=this.mousedownShape).set("capture",!1),this.draggingShape=o,this.dragging=!0,this._emitEvent("dragstart",n,t,o),this.mousedownShape=null,this.mousedownPoint=null):!s&&i.get("draggable")?(this.dragging=!0,this._emitEvent("dragstart",n,t,null),this.mousedownShape=null,this.mousedownPoint=null):(this._emitMouseoverEvents(n,t,r,e),this._emitEvent("mousemove",n,t,e)):(this._emitMouseoverEvents(n,t,r,e),this._emitEvent("mousemove",n,t,e))}else this._emitMouseoverEvents(n,t,r,e),this._emitEvent("mousemove",n,t,e)}},t.prototype._emitEvent=function(t,e,n,i,r,o){var a=this._getEventObj(t,e,n,i,r,o);if(i){a.shape=i,ae(i,t,a);for(var s=i.getParent();s;)s.emitDelegation(t,a),a.propagationStopped||se(s,t,a),a.propagationPath.push(s),s=s.getParent()}else{ae(this.canvas,t,a)}},t.prototype.destroy=function(){this._clearEvents(),this.canvas=null,this.currentShape=null,this.draggingShape=null,this.mousedownPoint=null,this.mousedownShape=null,this.mousedownTimeStamp=null},t}(),le=Object(o.a)(),ue=le&&"firefox"===le.name,he=function(t){function e(e){var n=t.call(this,e)||this;return n.initContainer(),n.initDom(),n.initEvents(),n.initTimeline(),n}return Object(r.__extends)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return e.cursor="default",e.supportCSSTransform=!1,e},e.prototype.initContainer=function(){var t=this.get("container");Object(s.h)(t)&&(t=document.getElementById(t),this.set("container",t))},e.prototype.initDom=function(){var t=this.createDom();this.set("el",t),this.get("container").appendChild(t),this.setDOMSize(this.get("width"),this.get("height"))},e.prototype.initEvents=function(){var t=new ce({canvas:this});t.init(),this.set("eventController",t)},e.prototype.initTimeline=function(){var t=new ie(this);this.set("timeline",t)},e.prototype.setDOMSize=function(t,e){var n=this.get("el");s.c&&(n.style.width=t+"px",n.style.height=e+"px")},e.prototype.changeSize=function(t,e){this.setDOMSize(t,e),this.set("width",t),this.set("height",e),this.onCanvasChange("changeSize")},e.prototype.getRenderer=function(){return this.get("renderer")},e.prototype.getCursor=function(){return this.get("cursor")},e.prototype.setCursor=function(t){this.set("cursor",t);var e=this.get("el");s.c&&e&&(e.style.cursor=t)},e.prototype.getPointByEvent=function(t){if(this.get("supportCSSTransform")){if(ue&&!Object(s.e)(t.layerX)&&t.layerX!==t.offsetX)return{x:t.layerX,y:t.layerY};if(!Object(s.e)(t.offsetX))return{x:t.offsetX,y:t.offsetY}}var e=this.getClientByEvent(t),n=e.x,i=e.y;return this.getPointByClient(n,i)},e.prototype.getClientByEvent=function(t){var e=t;return t.touches&&(e="touchend"===t.type?t.changedTouches[0]:t.touches[0]),{x:e.clientX,y:e.clientY}},e.prototype.getPointByClient=function(t,e){var n=this.get("el").getBoundingClientRect();return{x:t-n.left,y:e-n.top}},e.prototype.getClientByPoint=function(t,e){var n=this.get("el").getBoundingClientRect();return{x:t+n.left,y:e+n.top}},e.prototype.draw=function(){},e.prototype.removeDom=function(){var t=this.get("el");t.parentNode.removeChild(t)},e.prototype.clearEvents=function(){this.get("eventController").destroy()},e.prototype.isCanvas=function(){return!0},e.prototype.getParent=function(){return null},e.prototype.destroy=function(){var e=this.get("timeline");this.get("destroyed")||(this.clear(),e&&e.stop(),this.clearEvents(),this.removeDom(),t.prototype.destroy.call(this))},e}(a.a);e.a=he},function(t,e,n){"use strict";n.r(e),n.d(e,"Line",(function(){return h})),n.d(e,"Text",(function(){return f})),n.d(e,"Arc",(function(){return p})),n.d(e,"Region",(function(){return d})),n.d(e,"Image",(function(){return g})),n.d(e,"DataMarker",(function(){return y})),n.d(e,"DataRegion",(function(){return v})),n.d(e,"RegionFilter",(function(){return m})),n.d(e,"Shape",(function(){return x})),n.d(e,"Html",(function(){return O}));var i=n(1),r=n(0),o=n(13),a=n(30),s=n(21),c=n(4);function l(t,e){var n=e.x,o=e.y,l=e.content,u=e.style,h=e.id,f=e.name,p=e.rotate,d=e.maxLength,g=e.autoEllipsis,y=e.isVertical,v=e.ellipsisPosition,m=e.background,x=t.addGroup({id:h+"-group",name:f+"-group",attrs:{x:n,y:o}}),b=x.addShape({type:"text",id:h,name:f,attrs:Object(i.__assign)({x:0,y:0,text:l},u)}),O=Object(c.c)(Object(r.get)(m,"padding",0));if(d&&g){var _=d-(O[1]+O[3]);Object(a.a)(!y,b,_,v)}if(m){var w=Object(r.get)(m,"style",{}),j=b.getCanvasBBox(),S=j.minX,M=j.minY,A=j.width,C=j.height;x.addShape("rect",{id:h+"-bg",name:h+"-bg",attrs:Object(i.__assign)({x:S-O[3],y:M-O[0],width:A+O[1]+O[3],height:C+O[0]+O[2]},w)}).toBack()}Object(s.c)(x,n,o),Object(s.b)(x,p,n,o)}var u=n(5),h=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(i.__extends)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return Object(i.__assign)(Object(i.__assign)({},e),{name:"annotation",type:"line",locationType:"region",start:null,end:null,style:{},text:null,defaultCfg:{style:{fill:u.a.textColor,fontSize:12,textAlign:"center",textBaseline:"bottom",fontFamily:u.a.fontFamily},text:{position:"center",autoRotate:!0,content:null,offsetX:0,offsetY:0,style:{stroke:u.a.lineColor,lineWidth:1}}}})},e.prototype.renderInner=function(t){this.renderLine(t),this.get("text")&&this.renderLabel(t)},e.prototype.renderLine=function(t){var e=this.get("start"),n=this.get("end"),r=this.get("style");this.addShape(t,{type:"line",id:this.getElementId("line"),name:"annotation-line",attrs:Object(i.__assign)({x1:e.x,y1:e.y,x2:n.x,y2:n.y},r)})},e.prototype.getLabelPoint=function(t,e,n){var i;return((i="start"===n?0:"center"===n?.5:Object(r.isString)(n)&&-1!==n.indexOf("%")?parseInt(n,10)/100:Object(r.isNumber)(n)?n:1)>1||i<0)&&(i=1),{x:Object(c.g)(t.x,e.x,i),y:Object(c.g)(t.y,e.y,i)}},e.prototype.renderLabel=function(t){var e=this.get("text"),n=this.get("start"),i=this.get("end"),r=e.position,o=e.content,a=e.style,s=e.offsetX,c=e.offsetY,u=e.autoRotate,h=e.maxLength,f=e.autoEllipsis,p=e.ellipsisPosition,d=e.background,g=e.isVertical,y=void 0!==g&&g,v=this.getLabelPoint(n,i,r),m=v.x+s,x=v.y+c,b={id:this.getElementId("line-text"),name:"annotation-line-text",x:m,y:x,content:o,style:a,maxLength:h,autoEllipsis:f,ellipsisPosition:p,background:d,isVertical:y};if(u){var O=[i.x-n.x,i.y-n.y];b.rotate=Math.atan2(O[1],O[0])}l(t,b)},e}(o.a),f=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(i.__extends)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return Object(i.__assign)(Object(i.__assign)({},e),{name:"annotation",type:"text",locationType:"point",x:0,y:0,content:"",rotate:null,style:{},background:null,maxLength:null,autoEllipsis:!0,isVertical:!1,ellipsisPosition:"tail",defaultCfg:{style:{fill:u.a.textColor,fontSize:12,textAlign:"center",textBaseline:"middle",fontFamily:u.a.fontFamily}}})},e.prototype.setLocation=function(t){this.set("x",t.x),this.set("y",t.y),this.resetLocation()},e.prototype.renderInner=function(t){var e=this.getLocation(),n=e.x,i=e.y,r=this.get("content"),o=this.get("style");l(t,{id:this.getElementId("text"),name:this.get("name")+"-text",x:n,y:i,content:r,style:o,maxLength:this.get("maxLength"),autoEllipsis:this.get("autoEllipsis"),isVertical:this.get("isVertical"),ellipsisPosition:this.get("ellipsisPosition"),background:this.get("background"),rotate:this.get("rotate")})},e.prototype.resetLocation=function(){var t=this.getElementByLocalId("text-group");if(t){var e=this.getLocation(),n=e.x,i=e.y,r=this.get("rotate");Object(s.c)(t,n,i),Object(s.b)(t,r,n,i)}},e}(o.a),p=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(i.__extends)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return Object(i.__assign)(Object(i.__assign)({},e),{name:"annotation",type:"arc",locationType:"circle",center:null,radius:100,startAngle:-Math.PI/2,endAngle:3*Math.PI/2,style:{stroke:"#999",lineWidth:1}})},e.prototype.renderInner=function(t){this.renderArc(t)},e.prototype.getArcPath=function(){var t=this.getLocation(),e=t.center,n=t.radius,i=t.startAngle,r=t.endAngle,o=Object(c.e)(e,n,i),a=Object(c.e)(e,n,r),s=r-i>Math.PI?1:0,l=[["M",o.x,o.y]];if(r-i==2*Math.PI){var u=Object(c.e)(e,n,i+Math.PI);l.push(["A",n,n,0,s,1,u.x,u.y]),l.push(["A",n,n,0,s,1,a.x,a.y])}else l.push(["A",n,n,0,s,1,a.x,a.y]);return l},e.prototype.renderArc=function(t){var e=this.getArcPath(),n=this.get("style");this.addShape(t,{type:"path",id:this.getElementId("arc"),name:"annotation-arc",attrs:Object(i.__assign)({path:e},n)})},e}(o.a),d=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(i.__extends)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return Object(i.__assign)(Object(i.__assign)({},e),{name:"annotation",type:"region",locationType:"region",start:null,end:null,style:{},defaultCfg:{style:{lineWidth:0,fill:u.a.regionColor,opacity:.4}}})},e.prototype.renderInner=function(t){this.renderRegion(t)},e.prototype.renderRegion=function(t){var e=this.get("start"),n=this.get("end"),r=this.get("style"),o=Object(c.k)({start:e,end:n});this.addShape(t,{type:"rect",id:this.getElementId("region"),name:"annotation-region",attrs:Object(i.__assign)({x:o.x,y:o.y,width:o.width,height:o.height},r)})},e}(o.a),g=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(i.__extends)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return Object(i.__assign)(Object(i.__assign)({},e),{name:"annotation",type:"image",locationType:"region",start:null,end:null,src:null,style:{}})},e.prototype.renderInner=function(t){this.renderImage(t)},e.prototype.getImageAttrs=function(){var t=this.get("start"),e=this.get("end"),n=this.get("style"),r=Object(c.k)({start:t,end:e}),o=this.get("src");return Object(i.__assign)({x:r.x,y:r.y,img:o,width:r.width,height:r.height},n)},e.prototype.renderImage=function(t){this.addShape(t,{type:"image",id:this.getElementId("image"),name:"annotation-image",attrs:this.getImageAttrs()})},e}(o.a),y=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(i.__extends)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return Object(i.__assign)(Object(i.__assign)({},e),{name:"annotation",type:"dataMarker",locationType:"point",x:0,y:0,point:{},line:{},text:{},direction:"upward",autoAdjust:!0,coordinateBBox:null,defaultCfg:{point:{display:!0,style:{r:3,fill:"#FFFFFF",stroke:"#1890FF",lineWidth:2}},line:{display:!0,length:20,style:{stroke:u.a.lineColor,lineWidth:1}},text:{content:"",display:!0,style:{fill:u.a.textColor,opacity:.65,fontSize:12,textAlign:"start",fontFamily:u.a.fontFamily}}}})},e.prototype.renderInner=function(t){Object(r.get)(this.get("line"),"display")&&this.renderLine(t),Object(r.get)(this.get("text"),"display")&&this.renderText(t),Object(r.get)(this.get("point"),"display")&&this.renderPoint(t),this.get("autoAdjust")&&this.autoAdjust(t)},e.prototype.applyOffset=function(){this.moveElementTo(this.get("group"),{x:this.get("x")+this.get("offsetX"),y:this.get("y")+this.get("offsetY")})},e.prototype.renderPoint=function(t){var e=this.getShapeAttrs().point;this.addShape(t,{type:"circle",id:this.getElementId("point"),name:"annotation-point",attrs:e})},e.prototype.renderLine=function(t){var e=this.getShapeAttrs().line;this.addShape(t,{type:"path",id:this.getElementId("line"),name:"annotation-line",attrs:e})},e.prototype.renderText=function(t){var e=this.getShapeAttrs().text,n=e.x,r=e.y,o=e.text,a=Object(i.__rest)(e,["x","y","text"]),s=this.get("text"),c=s.background,u=s.maxLength,h=s.autoEllipsis,f=s.isVertival,p=s.ellipsisPosition;l(t,{x:n,y:r,id:this.getElementId("text"),name:"annotation-text",content:o,style:a,background:c,maxLength:u,autoEllipsis:h,isVertival:f,ellipsisPosition:p})},e.prototype.autoAdjust=function(t){var e=this.get("direction"),n=this.get("x"),i=this.get("y"),o=Object(r.get)(this.get("line"),"length",0),a=this.get("coordinateBBox"),c=t.getBBox(),l=c.minX,u=c.maxX,h=c.minY,f=c.maxY,p=t.findById(this.getElementId("text-group")),d=t.findById(this.getElementId("text")),g=t.findById(this.getElementId("line"));if(a){if(p){if(n+l<=a.minX){var y=a.minX-(n+l);Object(s.c)(p,p.attr("x")+y,p.attr("y"))}if(n+u>=a.maxX){y=n+u-a.maxX;Object(s.c)(p,p.attr("x")-y,p.attr("y"))}}if("upward"===e&&i+h<=a.minY||"upward"!==e&&i+f>=a.maxY){var v=void 0,m=void 0;"upward"===e&&i+h<=a.minY?(v="top",m=1):(v="bottom",m=-1),d.attr("textBaseline",v),g&&g.attr("path",[["M",0,0],["L",0,o*m]]),Object(s.c)(p,p.attr("x"),(o+2)*m)}}},e.prototype.getShapeAttrs=function(){var t=Object(r.get)(this.get("line"),"display"),e=Object(r.get)(this.get("point"),"style",{}),n=Object(r.get)(this.get("line"),"style",{}),o=Object(r.get)(this.get("text"),"style",{}),a=this.get("direction"),s=t?Object(r.get)(this.get("line"),"length",0):0,c="upward"===a?-1:1;return{point:Object(i.__assign)({x:0,y:0},e),line:Object(i.__assign)({path:[["M",0,0],["L",0,s*c]]},n),text:Object(i.__assign)({x:0,y:(s+2)*c,text:Object(r.get)(this.get("text"),"content",""),textBaseline:"upward"===a?"bottom":"top"},o)}},e}(o.a),v=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(i.__extends)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return Object(i.__assign)(Object(i.__assign)({},e),{name:"annotation",type:"dataRegion",locationType:"points",points:[],lineLength:0,region:{},text:{},defaultCfg:{region:{style:{lineWidth:0,fill:u.a.regionColor,opacity:.4}},text:{content:"",style:{textAlign:"center",textBaseline:"bottom",fontSize:12,fill:u.a.textColor,fontFamily:u.a.fontFamily}}}})},e.prototype.renderInner=function(t){var e=Object(r.get)(this.get("region"),"style",{}),n=(Object(r.get)(this.get("text"),"style",{}),this.get("lineLength")||0),o=this.get("points");if(o.length){var a=Object(c.j)(o),s=[];s.push(["M",o[0].x,a.minY-n]),o.forEach((function(t){s.push(["L",t.x,t.y])})),s.push(["L",o[o.length-1].x,o[o.length-1].y-n]),this.addShape(t,{type:"path",id:this.getElementId("region"),name:"annotation-region",attrs:Object(i.__assign)({path:s},e)}),l(t,Object(i.__assign)({id:this.getElementId("text"),name:"annotation-text",x:(a.minX+a.maxX)/2,y:a.minY-n},this.get("text")))}},e}(o.a),m=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(i.__extends)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return Object(i.__assign)(Object(i.__assign)({},e),{name:"annotation",type:"regionFilter",locationType:"region",start:null,end:null,color:null,shape:[]})},e.prototype.renderInner=function(t){var e=this,n=this.get("start"),i=this.get("end"),o=this.addGroup(t,{id:this.getElementId("region-filter"),capture:!1});Object(r.each)(this.get("shapes"),(function(t,n){var i=t.get("type"),a=Object(r.clone)(t.attr());e.adjustShapeAttrs(a),e.addShape(o,{id:e.getElementId("shape-"+i+"-"+n),capture:!1,type:i,attrs:a})}));var a=Object(c.k)({start:n,end:i});o.setClip({type:"rect",attrs:{x:a.minX,y:a.minY,width:a.width,height:a.height}})},e.prototype.adjustShapeAttrs=function(t){var e=this.get("color");t.fill&&(t.fill=t.fillStyle=e),t.stroke=t.strokeStyle=e},e}(o.a),x=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(i.__extends)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return Object(i.__assign)(Object(i.__assign)({},e),{name:"annotation",type:"shape",draw:r.noop})},e.prototype.renderInner=function(t){var e=this.get("render");Object(r.isFunction)(e)&&e(t)},e}(o.a),b=n(11),O=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(i.__extends)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return Object(i.__assign)(Object(i.__assign)({},e),{name:"annotation",type:"html",locationType:"point",x:0,y:0,containerTpl:'
',alignX:"left",alignY:"top",html:"",zIndex:7})},e.prototype.render=function(){var t=this.getContainer(),e=this.get("html");Object(c.a)(t);var n=Object(r.isFunction)(e)?e(t):e;if(Object(r.isElement)(n))t.appendChild(n);else if(Object(r.isString)(n)||Object(r.isNumber)(n)){var i=Object(b.b)(""+n);i&&t.appendChild(i)}this.resetPosition()},e.prototype.resetPosition=function(){var t=this.getContainer(),e=this.getLocation(),n=e.x,i=e.y,r=this.get("alignX"),o=this.get("alignY"),a=this.get("offsetX"),s=this.get("offsetY"),c=Object(b.d)(t),l=Object(b.c)(t),u={x:n,y:i};"middle"===r?u.x-=Math.round(c/2):"right"===r&&(u.x-=Math.round(c)),"middle"===o?u.y-=Math.round(l/2):"bottom"===o&&(u.y-=Math.round(l)),a&&(u.x+=a),s&&(u.y+=s),Object(b.e)(t,{position:"absolute",left:u.x+"px",top:u.y+"px",zIndex:this.get("zIndex")})},e}(n(38).a)},function(t,e,n){"use strict";n.r(e),n.d(e,"Line",(function(){return D})),n.d(e,"Circle",(function(){return B})),n.d(e,"Base",(function(){return d}));var i={};n.r(i),n.d(i,"getDefault",(function(){return v})),n.d(i,"ellipsisHead",(function(){return m})),n.d(i,"ellipsisTail",(function(){return x})),n.d(i,"ellipsisMiddle",(function(){return b}));var r={};n.r(r),n.d(r,"getDefault",(function(){return M})),n.d(r,"reserveFirst",(function(){return A})),n.d(r,"reserveLast",(function(){return C})),n.d(r,"reserveBoth",(function(){return E})),n.d(r,"equidistance",(function(){return I})),n.d(r,"equidistanceWithReverseBoth",(function(){return P}));var o={};n.r(o),n.d(o,"getDefault",(function(){return T})),n.d(o,"fixedAngle",(function(){return L})),n.d(o,"unfixedAngle",(function(){return k}));var a={};n.r(a),n.d(a,"autoHide",(function(){return r})),n.d(a,"autoRotate",(function(){return o})),n.d(a,"autoEllipsis",(function(){return i}));var s=n(1),c=n(3),l=n(0),u=n(13),h=n(21),f=n(43),p=n(5),d=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(s.__extends)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return Object(s.__assign)(Object(s.__assign)({},e),{name:"axis",ticks:[],line:{},tickLine:{},subTickLine:null,title:null,label:{},verticalFactor:1,verticalLimitLength:null,overlapOrder:["autoRotate","autoEllipsis","autoHide"],tickStates:{},optimize:{},defaultCfg:{line:{style:{lineWidth:1,stroke:p.a.lineColor}},tickLine:{style:{lineWidth:1,stroke:p.a.lineColor},alignTick:!0,length:5,displayWithLabel:!0},subTickLine:{style:{lineWidth:1,stroke:p.a.lineColor},count:4,length:2},label:{autoRotate:!0,autoHide:!1,autoEllipsis:!1,style:{fontSize:12,fill:p.a.textColor,fontFamily:p.a.fontFamily,fontWeight:"normal"},offset:10,offsetX:0,offsetY:0},title:{autoRotate:!0,spacing:5,position:"center",style:{fontSize:12,fill:p.a.textColor,textBaseline:"middle",fontFamily:p.a.fontFamily,textAlign:"center"}},tickStates:{active:{labelStyle:{fontWeight:500},tickLineStyle:{lineWidth:2}},inactive:{labelStyle:{fill:p.a.uncheckedColor}}},optimize:{enable:!0,threshold:400}},theme:{}})},e.prototype.renderInner=function(t){this.get("line")&&this.drawLine(t),this.drawTicks(t),this.get("title")&&this.drawTitle(t)},e.prototype.isList=function(){return!0},e.prototype.getItems=function(){return this.get("ticks")},e.prototype.setItems=function(t){this.update({ticks:t})},e.prototype.updateItem=function(t,e){Object(l.mix)(t,e),this.clear(),this.render()},e.prototype.clearItems=function(){var t=this.getElementByLocalId("label-group");t&&t.clear()},e.prototype.setItemState=function(t,e,n){t[e]=n,this.updateTickStates(t)},e.prototype.hasState=function(t,e){return!!t[e]},e.prototype.getItemStates=function(t){var e=this.get("tickStates"),n=[];return Object(l.each)(e,(function(e,i){t[i]&&n.push(i)})),n},e.prototype.clearItemsState=function(t){var e=this,n=this.getItemsByState(t);Object(l.each)(n,(function(n){e.setItemState(n,t,!1)}))},e.prototype.getItemsByState=function(t){var e=this,n=this.getItems();return Object(l.filter)(n,(function(n){return e.hasState(n,t)}))},e.prototype.getSidePoint=function(t,e){var n=this.getSideVector(e,t);return{x:t.x+n[0],y:t.y+n[1]}},e.prototype.getTextAnchor=function(t){var e;return Object(l.isNumberEqual)(t[0],0)?e="center":t[0]>0?e="start":t[0]<0&&(e="end"),e},e.prototype.getTextBaseline=function(t){var e;return Object(l.isNumberEqual)(t[1],0)?e="middle":t[1]>0?e="top":t[1]<0&&(e="bottom"),e},e.prototype.processOverlap=function(t){},e.prototype.drawLine=function(t){var e=this.getLinePath(),n=this.get("line");this.addShape(t,{type:"path",id:this.getElementId("line"),name:"axis-line",attrs:Object(l.mix)({path:e},n.style)})},e.prototype.getTickLineItems=function(t){var e=this,n=[],i=this.get("tickLine"),r=i.alignTick,o=i.length,a=1;return t.length>=2&&(a=t[1].value-t[0].value),Object(l.each)(t,(function(t){var i=t.point;r||(i=e.getTickPoint(t.value-a/2));var s=e.getSidePoint(i,o);n.push({startPoint:i,tickValue:t.value,endPoint:s,tickId:t.id,id:"tickline-"+t.id})})),n},e.prototype.getSubTickLineItems=function(t){var e=[],n=this.get("subTickLine"),i=n.count,r=t.length;if(r>=2)for(var o=0;o0){var n=Object(l.size)(e);if(n>t.threshold){var i=Math.ceil(n/t.threshold),r=e.filter((function(t,e){return e%i==0}));this.set("ticks",r),this.set("originalTicks",e)}}},e.prototype.getLabelAttrs=function(t,e,n){var i=this.get("label"),r=i.offset,o=i.offsetX,a=i.offsetY,s=i.rotate,c=i.formatter,u=this.getSidePoint(t.point,r),f=this.getSideVector(r,u),p=c?c(t.name,t,e):t.name,d=i.style;d=Object(l.isFunction)(d)?Object(l.get)(this.get("theme"),["label","style"],{}):d;var g=Object(l.mix)({x:u.x+o,y:u.y+a,text:p,textAlign:this.getTextAnchor(f),textBaseline:this.getTextBaseline(f)},d);return s&&(g.matrix=Object(h.e)(u,s)),g},e.prototype.drawLabels=function(t){var e=this,n=this.get("ticks"),i=this.addGroup(t,{name:"axis-label-group",id:this.getElementId("label-group")});Object(l.each)(n,(function(t,r){e.addShape(i,{type:"text",name:"axis-label",id:e.getElementId("label-"+t.id),attrs:e.getLabelAttrs(t,r,n),delegateObject:{tick:t,item:t,index:r}})})),this.processOverlap(i);var r=i.getChildren(),o=Object(l.get)(this.get("theme"),["label","style"],{}),a=this.get("label"),s=a.style,c=a.formatter;if(Object(l.isFunction)(s)){var u=r.map((function(t){return Object(l.get)(t.get("delegateObject"),"tick")}));Object(l.each)(r,(function(t,e){var n=t.get("delegateObject").tick,i=c?c(n.name,n,e):n.name,r=Object(l.mix)({},o,s(i,e,u));t.attr(r)}))}},e.prototype.getTitleAttrs=function(){var t=this.get("title"),e=t.style,n=t.position,i=t.offset,r=t.spacing,o=void 0===r?0:r,a=t.autoRotate,s=e.fontSize,u=.5;"start"===n?u=0:"end"===n&&(u=1);var f=this.getTickPoint(u),p=this.getSidePoint(f,i||o+s/2),d=Object(l.mix)({x:p.x,y:p.y,text:t.text},e),g=t.rotate,y=g;if(Object(l.isNil)(g)&&a){var v=this.getAxisVector(f);y=c.ext.angleTo(v,[1,0],!0)}if(y){var m=Object(h.e)(p,y);d.matrix=m}return d},e.prototype.drawTitle=function(t){this.addShape(t,{type:"text",id:this.getElementId("title"),name:"axis-title",attrs:this.getTitleAttrs()})},e.prototype.applyTickStates=function(t,e){if(this.getItemStates(t).length){var n=this.get("tickStates"),i=this.getElementId("label-"+t.id),r=e.findById(i);if(r){var o=Object(f.a)(t,"label",n);o&&r.attr(o)}var a=this.getElementId("tickline-"+t.id),s=e.findById(a);if(s){var c=Object(f.a)(t,"tickLine",n);c&&s.attr(c)}}},e.prototype.updateTickStates=function(t){var e=this.getItemStates(t),n=this.get("tickStates"),i=this.get("label"),r=this.getElementByLocalId("label-"+t.id),o=this.get("tickLine"),a=this.getElementByLocalId("tickline-"+t.id);if(e.length){if(r){var s=Object(f.a)(t,"label",n);s&&r.attr(s)}if(a){var c=Object(f.a)(t,"tickLine",n);c&&a.attr(c)}}else r&&r.attr(i.style),a&&a.attr(o.style)},e}(u.a),g=n(30);function y(t,e,n,i){var r=e.getChildren(),o=!1;return Object(l.each)(r,(function(e){var r=Object(g.a)(t,e,n,i);o=o||r})),o}function v(){return x}function m(t,e,n){return y(t,e,n,"head")}function x(t,e,n){return y(t,e,n,"tail")}function b(t,e,n){return y(t,e,n,"middle")}var O=n(4);function _(t){return(function(t){var e=t.attr("matrix");return e&&1!==e[0]}(t)?Object(h.d)(t.attr("matrix")):0)%360}function w(t,e,n,i){var r=!1,o=_(e),a=t?Math.abs(n.attr("y")-e.attr("y")):Math.abs(n.attr("x")-e.attr("x")),s=(t?n.attr("y")>e.attr("y"):n.attr("x")>e.attr("x"))?e.getBBox():n.getBBox();if(t){var c=Math.abs(Math.cos(o));r=Object(O.i)(c,0,Math.PI/180)?s.width+i>a:s.height/c+i>a}else{c=Math.abs(Math.sin(o));r=Object(O.i)(c,0,Math.PI/180)?s.width+i>a:s.height/c+i>a}return r}function j(t,e,n,i){var r=(null==i?void 0:i.minGap)||0,o=e.getChildren().slice().filter((function(t){return t.get("visible")}));if(!o.length)return!1;var a=!1;n&&o.reverse();for(var s=o.length,c=o[0],l=1;l1){f=Math.ceil(f);for(var d=0;d2){var a=r[0],s=r[r.length-1];a.get("visible")||(a.show(),j(t,e,!1,i)&&(o=!0)),s.get("visible")||(s.show(),j(t,e,!0,i)&&(o=!0))}return o}function F(t,e,n,i){var r=e.getChildren();if(!r.length)return!1;if(!t&&r.length<2)return!1;var o=Object(g.b)(r),a=!1;t?a=!!n&&o>n:a=o>Math.abs(r[1].attr("x")-r[0].attr("x"));a&&function(t,e){Object(l.each)(t,(function(t){var n=t.attr("x"),i=t.attr("y"),r=Object(h.e)({x:n,y:i},e);t.attr("matrix",r)}))}(r,i(n,o));return a}function T(){return L}function L(t,e,n,i){return F(t,e,n,(function(){return Object(l.isNumber)(i)?i:t?p.a.verticalAxisRotate:p.a.horizontalAxisRotate}))}function k(t,e,n){return F(t,e,n,(function(e,n){if(!e)return t?p.a.verticalAxisRotate:p.a.horizontalAxisRotate;if(t)return-Math.acos(e/n);var i=0;return(e>n||(i=Math.asin(e/n))>Math.PI/4)&&(i=Math.PI/4),i}))}var D=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(s.__extends)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return Object(s.__assign)(Object(s.__assign)({},e),{type:"line",locationType:"region",start:null,end:null})},e.prototype.getLinePath=function(){var t=this.get("start"),e=this.get("end"),n=[];return n.push(["M",t.x,t.y]),n.push(["L",e.x,e.y]),n},e.prototype.getInnerLayoutBBox=function(){var e=this.get("start"),n=this.get("end"),i=t.prototype.getInnerLayoutBBox.call(this),r=Math.min(e.x,n.x,i.x),o=Math.min(e.y,n.y,i.y),a=Math.max(e.x,n.x,i.maxX),s=Math.max(e.y,n.y,i.maxY);return{x:r,y:o,minX:r,minY:o,maxX:a,maxY:s,width:a-r,height:s-o}},e.prototype.isVertical=function(){var t=this.get("start"),e=this.get("end");return Object(l.isNumberEqual)(t.x,e.x)},e.prototype.isHorizontal=function(){var t=this.get("start"),e=this.get("end");return Object(l.isNumberEqual)(t.y,e.y)},e.prototype.getTickPoint=function(t){var e=this.get("start"),n=this.get("end"),i=n.x-e.x,r=n.y-e.y;return{x:e.x+i*t,y:e.y+r*t}},e.prototype.getSideVector=function(t){var e=this.getAxisVector(),n=c.vec2.normalize([0,0],e),i=this.get("verticalFactor"),r=[n[1],-1*n[0]];return c.vec2.scale([0,0],r,t*i)},e.prototype.getAxisVector=function(){var t=this.get("start"),e=this.get("end");return[e.x-t.x,e.y-t.y]},e.prototype.processOverlap=function(t){var e=this,n=this.isVertical(),i=this.isHorizontal();if(n||i){var r=this.get("label"),o=this.get("title"),a=this.get("verticalLimitLength"),s=r.offset,c=a,u=0,h=0;o&&(u=o.style.fontSize,h=o.spacing),c&&(c=c-s-h-u);var f=this.get("overlapOrder");if(Object(l.each)(f,(function(n){r[n]&&e.canProcessOverlap(n)&&e.autoProcessOverlap(n,r[n],t,c)})),o&&Object(l.isNil)(o.offset)){var p=t.getCanvasBBox(),d=n?p.width:p.height;o.offset=s+d+h+u/2}}},e.prototype.canProcessOverlap=function(t){var e=this.get("label");return"autoRotate"!==t||Object(l.isNil)(e.rotate)},e.prototype.autoProcessOverlap=function(t,e,n,i){var r=this,o=this.isVertical(),s=!1,c=a[t];if(!0===e){this.get("label");s=c.getDefault()(o,n,i)}else if(Object(l.isFunction)(e))s=e(o,n,i);else if(Object(l.isObject)(e)){var u=e;c[u.type]&&(s=c[u.type](o,n,i,u.cfg))}else c[e]&&(s=c[e](o,n,i));if("autoRotate"===t){if(s){var h=n.getChildren(),f=this.get("verticalFactor");Object(l.each)(h,(function(t){if("center"===t.attr("textAlign")){var e=f>0?"end":"start";t.attr("textAlign",e)}}))}}else if("autoHide"===t){var p=n.getChildren().slice(0);Object(l.each)(p,(function(t){t.get("visible")||(r.get("isRegister")&&r.unregisterElement(t),t.remove())}))}},e}(d),B=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(s.__extends)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return Object(s.__assign)(Object(s.__assign)({},e),{type:"circle",locationType:"circle",center:null,radius:null,startAngle:-Math.PI/2,endAngle:3*Math.PI/2})},e.prototype.getLinePath=function(){var t=this.get("center"),e=t.x,n=t.y,i=this.get("radius"),r=i,o=this.get("startAngle"),a=this.get("endAngle"),s=[];if(Math.abs(a-o)===2*Math.PI)s=[["M",e,n-r],["A",i,r,0,1,1,e,n+r],["A",i,r,0,1,1,e,n-r],["Z"]];else{var c=this.getCirclePoint(o),l=this.getCirclePoint(a),u=Math.abs(a-o)>Math.PI?1:0,h=o>a?0:1;s=[["M",e,n],["L",c.x,c.y],["A",i,r,0,u,h,l.x,l.y],["L",e,n]]}return s},e.prototype.getTickPoint=function(t){var e=this.get("startAngle"),n=e+(this.get("endAngle")-e)*t;return this.getCirclePoint(n)},e.prototype.getSideVector=function(t,e){var n=this.get("center"),i=[e.x-n.x,e.y-n.y],r=this.get("verticalFactor"),o=c.vec2.length(i);return c.vec2.scale(i,i,r*t/o),i},e.prototype.getAxisVector=function(t){var e=this.get("center"),n=[t.x-e.x,t.y-e.y];return[n[1],-1*n[0]]},e.prototype.getCirclePoint=function(t,e){var n=this.get("center");return e=e||this.get("radius"),{x:n.x+Math.cos(t)*e,y:n.y+Math.sin(t)*e}},e.prototype.canProcessOverlap=function(t){var e=this.get("label");return"autoRotate"!==t||Object(l.isNil)(e.rotate)},e.prototype.processOverlap=function(t){var e=this,n=this.get("label"),i=this.get("title"),r=this.get("verticalLimitLength"),o=n.offset,a=r,s=0,c=0;i&&(s=i.style.fontSize,c=i.spacing),a&&(a=a-o-c-s);var u=this.get("overlapOrder");if(Object(l.each)(u,(function(i){n[i]&&e.canProcessOverlap(i)&&e.autoProcessOverlap(i,n[i],t,a)})),i&&Object(l.isNil)(i.offset)){var h=t.getCanvasBBox().height;i.offset=o+h+c+s/2}},e.prototype.autoProcessOverlap=function(t,e,n,i){var r=this,o=!1,s=a[t];if(i>0)if(!0===e)o=s.getDefault()(!1,n,i);else if(Object(l.isFunction)(e))o=e(!1,n,i);else if(Object(l.isObject)(e)){var c=e;s[c.type]&&(o=s[c.type](!1,n,i,c.cfg))}else s[e]&&(o=s[e](!1,n,i));if("autoRotate"===t){if(o){var u=n.getChildren(),h=this.get("verticalFactor");Object(l.each)(u,(function(t){if("center"===t.attr("textAlign")){var e=h>0?"end":"start";t.attr("textAlign",e)}}))}}else if("autoHide"===t){var f=n.getChildren().slice(0);Object(l.each)(f,(function(t){t.get("visible")||(r.get("isRegister")&&r.unregisterElement(t),t.remove())}))}},e}(d)},function(t,e,n){"use strict";var i=n(1),r=n(10),o=n(8),a=n(42),s=n(25),c=n(19),l=n(53),u=n(52),h=n(0),f=/^l\s*\(\s*([\d.]+)\s*\)\s*(.*)/i,p=/^r\s*\(\s*([\d.]+)\s*,\s*([\d.]+)\s*,\s*([\d.]+)\s*\)\s*(.*)/i,d=/[\d.]+:(#[^\s]+|[^)]+\))/gi;function g(t){var e=t.match(d);if(!e)return"";var n="";return e.sort((function(t,e){return t=t.split(":"),e=e.split(":"),Number(t[0])-Number(e[0])})),Object(h.each)(e,(function(t){t=t.split(":"),n+=''})),n}var y=function(){function t(t){this.cfg={};var e,n,i,r,o,a,s,l=null,u=Object(h.uniqueId)("gradient_");return"l"===t.toLowerCase()[0]?function(t,e){var n,i,r=f.exec(t),o=Object(h.mod)(Object(h.toRadian)(parseFloat(r[1])),2*Math.PI),a=r[2];o>=0&&o<.5*Math.PI?(n={x:0,y:0},i={x:1,y:1}):.5*Math.PI<=o&&o';e.innerHTML=n},t}(),b=function(){function t(t,e){this.cfg={};var n=Object(c.b)("marker"),i=Object(h.uniqueId)("marker_");n.setAttribute("id",i);var r=Object(c.b)("path");r.setAttribute("stroke",t.stroke||"none"),r.setAttribute("fill",t.fill||"none"),n.appendChild(r),n.setAttribute("overflow","visible"),n.setAttribute("orient","auto-start-reverse"),this.el=n,this.child=r,this.id=i;var o=t["marker-start"===e?"startArrow":"endArrow"];return this.stroke=t.stroke||"#000",!0===o?this._setDefaultPath(e,r):(this.cfg=o,this._setMarker(t.lineWidth,r)),this}return t.prototype.match=function(){return!1},t.prototype._setDefaultPath=function(t,e){var n=this.el;e.setAttribute("d","M0,0 L"+10*Math.cos(Math.PI/6)+",5 L0,10"),n.setAttribute("refX",""+10*Math.cos(Math.PI/6)),n.setAttribute("refY","5")},t.prototype._setMarker=function(t,e){var n=this.el,i=this.cfg.path,r=this.cfg.d;Object(h.isArray)(i)&&(i=i.map((function(t){return t.join(" ")})).join("")),e.setAttribute("d",i),n.appendChild(e),r&&n.setAttribute("refX",""+r/t)},t.prototype.update=function(t){var e=this.child;e.attr?e.attr("fill",t):e.setAttribute("fill",t)},t}(),O=function(){function t(t){this.type="clip",this.cfg={};var e=Object(c.b)("clipPath");this.el=e,this.id=Object(h.uniqueId)("clip_"),e.id=this.id;var n=t.cfg.el;return e.appendChild(n),this.cfg=t,this}return t.prototype.match=function(){return!1},t.prototype.remove=function(){var t=this.el;t.parentNode.removeChild(t)},t}(),_=/^p\s*\(\s*([axyn])\s*\)\s*(.*)/i,w=function(){function t(t){this.cfg={};var e=Object(c.b)("pattern");e.setAttribute("patternUnits","userSpaceOnUse");var n=Object(c.b)("image");e.appendChild(n);var i=Object(h.uniqueId)("pattern_");e.id=i,this.el=e,this.id=i,this.cfg=t;var r=_.exec(t)[2];n.setAttribute("href",r);var o=new Image;function a(){e.setAttribute("width",""+o.width),e.setAttribute("height",""+o.height)}return r.match(/^data:/i)||(o.crossOrigin="Anonymous"),o.src=r,o.complete?a():(o.onload=a,o.src=o.src),this}return t.prototype.match=function(t,e){return this.cfg===e},t}(),j=function(){function t(t){var e=Object(c.b)("defs"),n=Object(h.uniqueId)("defs_");e.id=n,t.appendChild(e),this.children=[],this.defaultArrow={},this.el=e,this.canvas=t}return t.prototype.find=function(t,e){for(var n=this.children,i=null,r=0;rMath.PI?1:0,f=i>r?0:1;a=[["M",l.x,l.y],["A",n,n,0,h,f,u.x,u.y]]}return a},e}(u),p=n(11),d=n(38),g=((i={})["g2-crosshair"]={position:"relative"},i["g2-crosshair-line"]={position:"absolute",backgroundColor:"rgba(0, 0, 0, 0.25)"},i["g2-crosshair-text"]={position:"absolute",color:l.a.textColor,fontFamily:l.a.fontFamily},i),y=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(r.__extends)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return Object(r.__assign)(Object(r.__assign)({},e),{name:"crosshair",type:"html",locationType:"region",start:{x:0,y:0},end:{x:0,y:0},capture:!1,text:null,containerTpl:'
',crosshairTpl:'
',textTpl:'{content}',domStyles:null,containerClassName:"g2-crosshair",defaultStyles:g,defaultCfg:{text:{position:"start",content:null,align:"center",offset:10}}})},e.prototype.render=function(){this.resetText(),this.resetPosition()},e.prototype.initCrossHair=function(){var t=this.getContainer(),e=this.get("crosshairTpl"),n=Object(p.b)(e);t.appendChild(n),this.applyStyle("g2-crosshair-line",n),this.set("crosshairEl",n)},e.prototype.getTextPoint=function(){var t=this.getLocation(),e=t.start,n=t.end,i=this.get("text"),r=i.position,a=i.offset;return Object(o.f)(e,n,r,a)},e.prototype.resetText=function(){var t=this.get("text"),e=this.get("textEl");if(t){var n=t.content;if(!e){var i=this.getContainer(),r=Object(a.substitute)(this.get("textTpl"),t);e=Object(p.b)(r),i.appendChild(e),this.applyStyle("g2-crosshair-text",e),this.set("textEl",e)}e.innerHTML=n}else e&&e.remove()},e.prototype.isVertical=function(t,e){return t.x===e.x},e.prototype.resetPosition=function(){var t=this.get("crosshairEl");t||(this.initCrossHair(),t=this.get("crosshairEl"));var e=this.get("start"),n=this.get("end"),i=Math.min(e.x,n.x),r=Math.min(e.y,n.y);this.isVertical(e,n)?Object(p.e)(t,{width:"1px",height:Object(o.l)(Math.abs(n.y-e.y))}):Object(p.e)(t,{height:"1px",width:Object(o.l)(Math.abs(n.x-e.x))}),Object(p.e)(t,{top:Object(o.l)(r),left:Object(o.l)(i)}),this.alignText()},e.prototype.alignText=function(){var t=this.get("textEl");if(t){var e=this.get("text").align,n=t.clientWidth,i=this.getTextPoint();switch(e){case"center":i.x=i.x-n/2;break;case"right":i.x=i.x-n}Object(p.e)(t,{top:Object(o.l)(i.y),left:Object(o.l)(i.x)})}},e.prototype.updateInner=function(e){Object(a.hasKey)(e,"text")&&this.resetText(),t.prototype.updateInner.call(this,e)},e}(d.a)},function(t,e,n){"use strict";n.d(e,"a",(function(){return O}));var i=n(1),r=n(0),o=n(13),a={opacity:0},s={stroke:"#C5C5C5",strokeOpacity:.85},c={fill:"#CACED4",opacity:.85},l=n(28),u=n(33);function h(t){return function(t){return Object(r.map)(t,(function(t,e){return[0===e?"M":"L",t[0],t[1]]}))}(t)}function f(t,e,n,i){void 0===i&&(i=!0);var o=new u.b({values:t}),a=new u.a({values:Object(r.map)(t,(function(t,e){return e}))}),s=Object(r.map)(t,(function(t,i){return[a.scale(i)*e,n-o.scale(t)*n]}));return i?function(t){if(t.length<=2)return h(t);var e=[];Object(r.each)(t,(function(t){Object(r.isEqual)(t,e.slice(e.length-2))||e.push(t[0],t[1])}));var n=Object(l.catmullRom2Bezier)(e,!1),i=Object(r.head)(t),o=i[0],a=i[1];return n.unshift(["M",o,a]),n}(s):h(s)}function p(t,e,n,r){var o=Object(i.__spreadArrays)(t),a=function(t,e){var n=new u.b({values:t}),i=n.max<0?n.max:Math.max(0,n.min);return e-n.scale(i)*e}(r,n);return o.push(["L",e,a]),o.push(["L",0,a]),o.push(["Z"]),o}var d=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(i.__extends)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return Object(i.__assign)(Object(i.__assign)({},e),{name:"trend",x:0,y:0,width:200,height:16,smooth:!0,isArea:!1,data:[],backgroundStyle:a,lineStyle:s,areaStyle:c})},e.prototype.renderInner=function(t){var e=this.cfg,n=e.width,r=e.height,o=e.data,a=e.smooth,s=e.isArea,c=e.backgroundStyle,l=e.lineStyle,u=e.areaStyle;this.addShape(t,{id:this.getElementId("background"),type:"rect",attrs:Object(i.__assign)({x:0,y:0,width:n,height:r},c)});var h=f(o,n,r,a);if(this.addShape(t,{id:this.getElementId("line"),type:"path",attrs:Object(i.__assign)({path:h},l)}),s){var d=p(h,n,r,o);this.addShape(t,{id:this.getElementId("area"),type:"path",attrs:Object(i.__assign)({path:d},u)})}},e.prototype.applyOffset=function(){var t=this.cfg,e=t.x,n=t.y;this.moveElementTo(this.get("group"),{x:e,y:n})},e}(o.a),g={fill:"#F7F7F7",stroke:"#BFBFBF",radius:2,opacity:1,cursor:"ew-resize",highLightFill:"#FFF"},y=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(i.__extends)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return Object(i.__assign)(Object(i.__assign)({},e),{name:"handler",x:0,y:0,width:10,height:24,style:g})},e.prototype.renderInner=function(t){var e=this.cfg,n=e.width,i=e.height,r=e.style,o=r.fill,a=r.stroke,s=r.radius,c=r.opacity,l=r.cursor;this.addShape(t,{type:"rect",id:this.getElementId("background"),attrs:{x:0,y:0,width:n,height:i,fill:o,stroke:a,radius:s,opacity:c,cursor:l}});var u=1/3*n,h=2/3*n,f=1/4*i,p=3/4*i;this.addShape(t,{id:this.getElementId("line-left"),type:"line",attrs:{x1:u,y1:f,x2:u,y2:p,stroke:a,cursor:l}}),this.addShape(t,{id:this.getElementId("line-right"),type:"line",attrs:{x1:h,y1:f,x2:h,y2:p,stroke:a,cursor:l}})},e.prototype.applyOffset=function(){this.moveElementTo(this.get("group"),{x:this.get("x"),y:this.get("y")})},e.prototype.initEvent=function(){this.bindEvents()},e.prototype.bindEvents=function(){var t=this;this.get("group").on("mouseenter",(function(){var e=t.get("style").highLightFill;t.getElementByLocalId("background").attr("fill",e),t.draw()})),this.get("group").on("mouseleave",(function(){var e=t.get("style").fill;t.getElementByLocalId("background").attr("fill",e),t.draw()}))},e.prototype.draw=function(){var t=this.get("container").get("canvas");t&&t.draw()},e}(o.a),v={fill:"#416180",opacity:.05},m={fill:"#5B8FF9",opacity:.15,cursor:"move"},x={width:10,height:24},b={textBaseline:"middle",fill:"#000",opacity:.45},O=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.onMouseDown=function(t){return function(n){e.currentTarget=t;var i=n.originalEvent;i.stopPropagation(),i.preventDefault(),e.prevX=Object(r.get)(i,"touches.0.pageX",i.pageX),e.prevY=Object(r.get)(i,"touches.0.pageY",i.pageY);var o=e.getContainerDOM();o.addEventListener("mousemove",e.onMouseMove),o.addEventListener("mouseup",e.onMouseUp),o.addEventListener("mouseleave",e.onMouseUp),o.addEventListener("touchmove",e.onMouseMove),o.addEventListener("touchend",e.onMouseUp),o.addEventListener("touchcancel",e.onMouseUp)}},e.onMouseMove=function(t){var n=e.cfg.width,i=[e.get("start"),e.get("end")];t.stopPropagation(),t.preventDefault();var o=Object(r.get)(t,"touches.0.pageX",t.pageX),a=Object(r.get)(t,"touches.0.pageY",t.pageY),s=o-e.prevX,c=e.adjustOffsetRange(s/n);e.updateStartEnd(c),e.updateUI(e.getElementByLocalId("foreground"),e.getElementByLocalId("minText"),e.getElementByLocalId("maxText")),e.prevX=o,e.prevY=a,e.draw(),e.emit("sliderchange",[e.get("start"),e.get("end")].sort()),e.delegateEmit("valuechanged",{originValue:i,value:[e.get("start"),e.get("end")]})},e.onMouseUp=function(){e.currentTarget&&(e.currentTarget=void 0);var t=e.getContainerDOM();t&&(t.removeEventListener("mousemove",e.onMouseMove),t.removeEventListener("mouseup",e.onMouseUp),t.removeEventListener("mouseleave",e.onMouseUp),t.removeEventListener("touchmove",e.onMouseMove),t.removeEventListener("touchend",e.onMouseUp),t.removeEventListener("touchcancel",e.onMouseUp))},e}return Object(i.__extends)(e,t),e.prototype.setRange=function(t,e){this.set("minLimit",t),this.set("maxLimit",e);var n=this.get("start"),i=this.get("end"),o=Object(r.clamp)(n,t,e),a=Object(r.clamp)(i,t,e);this.get("isInit")||n===o&&i===a||this.setValue([o,a])},e.prototype.getRange=function(){return{min:this.get("minLimit")||0,max:this.get("maxLimit")||1}},e.prototype.setValue=function(t){var e=this.getRange();if(Object(r.isArray)(t)&&2===t.length){var n=[this.get("start"),this.get("end")];this.update({start:Object(r.clamp)(t[0],e.min,e.max),end:Object(r.clamp)(t[1],e.min,e.max)}),this.get("updateAutoRender")||this.render(),this.delegateEmit("valuechanged",{originValue:n,value:t})}},e.prototype.getValue=function(){return[this.get("start"),this.get("end")]},e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return Object(i.__assign)(Object(i.__assign)({},e),{name:"slider",x:0,y:0,width:100,height:16,backgroundStyle:{},foregroundStyle:{},handlerStyle:{},textStyle:{},defaultCfg:{backgroundStyle:v,foregroundStyle:m,handlerStyle:x,textStyle:b}})},e.prototype.update=function(e){var n=e.start,o=e.end,a=Object(i.__assign)({},e);Object(r.isNil)(n)||(a.start=Object(r.clamp)(n,0,1)),Object(r.isNil)(o)||(a.end=Object(r.clamp)(o,0,1)),t.prototype.update.call(this,a),this.minHandler=this.getChildComponentById(this.getElementId("minHandler")),this.maxHandler=this.getChildComponentById(this.getElementId("maxHandler")),this.trend=this.getChildComponentById(this.getElementId("trend"))},e.prototype.init=function(){this.set("start",Object(r.clamp)(this.get("start"),0,1)),this.set("end",Object(r.clamp)(this.get("end"),0,1)),t.prototype.init.call(this)},e.prototype.render=function(){t.prototype.render.call(this),this.updateUI(this.getElementByLocalId("foreground"),this.getElementByLocalId("minText"),this.getElementByLocalId("maxText"))},e.prototype.renderInner=function(t){var e=this.cfg,n=(e.start,e.end,e.width),o=e.height,a=e.trendCfg,s=void 0===a?{}:a,c=e.minText,l=e.maxText,u=e.backgroundStyle,h=void 0===u?{}:u,f=e.foregroundStyle,p=void 0===f?{}:f,v=e.textStyle,m=void 0===v?{}:v,x=Object(r.deepMix)({},g,this.cfg.handlerStyle);Object(r.size)(Object(r.get)(s,"data"))&&(this.trend=this.addComponent(t,Object(i.__assign)({component:d,id:this.getElementId("trend"),x:0,y:0,width:n,height:o},s))),this.addShape(t,{id:this.getElementId("background"),type:"rect",attrs:Object(i.__assign)({x:0,y:0,width:n,height:o},h)});this.addShape(t,{id:this.getElementId("minText"),type:"text",attrs:Object(i.__assign)({y:o/2,textAlign:"right",text:c,silent:!1},m)}),this.addShape(t,{id:this.getElementId("maxText"),type:"text",attrs:Object(i.__assign)({y:o/2,textAlign:"left",text:l,silent:!1},m)}),this.addShape(t,{id:this.getElementId("foreground"),name:"foreground",type:"rect",attrs:Object(i.__assign)({y:0,height:o},p)});var b=Object(r.get)(x,"width",10),O=Object(r.get)(x,"height",24);this.minHandler=this.addComponent(t,{component:y,id:this.getElementId("minHandler"),name:"handler-min",x:0,y:(o-O)/2,width:b,height:O,cursor:"ew-resize",style:x}),this.maxHandler=this.addComponent(t,{component:y,id:this.getElementId("maxHandler"),name:"handler-max",x:0,y:(o-O)/2,width:b,height:O,cursor:"ew-resize",style:x})},e.prototype.applyOffset=function(){this.moveElementTo(this.get("group"),{x:this.get("x"),y:this.get("y")})},e.prototype.initEvent=function(){this.bindEvents()},e.prototype.updateUI=function(t,e,n){var i=this.cfg,o=i.start,a=i.end,s=i.width,c=i.minText,l=i.maxText,u=i.handlerStyle,h=i.height,f=o*s,p=a*s;this.trend&&(this.trend.update({width:s,height:h}),this.get("updateAutoRender")||this.trend.render()),t.attr("x",f),t.attr("width",p-f);var d=Object(r.get)(u,"width",10);e.attr("text",c),n.attr("text",l);var g=this._dodgeText([f,p],e,n),y=g[0],v=g[1];this.minHandler&&(this.minHandler.update({x:f-d/2}),this.get("updateAutoRender")||this.minHandler.render()),Object(r.each)(y,(function(t,n){return e.attr(n,t)})),this.maxHandler&&(this.maxHandler.update({x:p-d/2}),this.get("updateAutoRender")||this.maxHandler.render()),Object(r.each)(v,(function(t,e){return n.attr(e,t)}))},e.prototype.bindEvents=function(){var t=this.get("group");t.on("handler-min:mousedown",this.onMouseDown("minHandler")),t.on("handler-min:touchstart",this.onMouseDown("minHandler")),t.on("handler-max:mousedown",this.onMouseDown("maxHandler")),t.on("handler-max:touchstart",this.onMouseDown("maxHandler"));var e=t.findById(this.getElementId("foreground"));e.on("mousedown",this.onMouseDown("foreground")),e.on("touchstart",this.onMouseDown("foreground"))},e.prototype.adjustOffsetRange=function(t){var e=this.cfg,n=e.start,i=e.end;switch(this.currentTarget){case"minHandler":var r=0-n,o=1-n;return Math.min(o,Math.max(r,t));case"maxHandler":r=0-i,o=1-i;return Math.min(o,Math.max(r,t));case"foreground":r=0-n,o=1-i;return Math.min(o,Math.max(r,t))}},e.prototype.updateStartEnd=function(t){var e=this.cfg,n=e.start,i=e.end;switch(this.currentTarget){case"minHandler":n+=t;break;case"maxHandler":i+=t;break;case"foreground":n+=t,i+=t}this.set("start",n),this.set("end",i)},e.prototype._dodgeText=function(t,e,n){var i,o,a=this.cfg,s=a.handlerStyle,c=a.width,l=Object(r.get)(s,"width",10),u=t[0],h=t[1],f=!1;u>h&&(u=(i=[h,u])[0],h=i[1],e=(o=[n,e])[0],n=o[1],f=!0);var p=e.getBBox(),d=n.getBBox(),g=p.width>u-2?{x:u+l/2+2,textAlign:"left"}:{x:u-l/2-2,textAlign:"right"},y=d.width>c-h-2?{x:h-l/2-2,textAlign:"right"}:{x:h+l/2+2,textAlign:"left"};return f?[y,g]:[g,y]},e.prototype.draw=function(){var t=this.get("container"),e=t&&t.get("canvas");e&&e.draw()},e.prototype.getContainerDOM=function(){var t=this.get("container"),e=t&&t.get("canvas");return e&&e.get("container")},e}(o.a)},function(t,e,n){"use strict";n.r(e),n.d(e,"Base",(function(){return s})),n.d(e,"Circle",(function(){return c})),n.d(e,"Line",(function(){return l}));var i=n(1),r=n(0),o=n(13),a=n(5),s=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(i.__extends)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return Object(i.__assign)(Object(i.__assign)({},e),{name:"grid",line:{},alternateColor:null,capture:!1,items:[],closed:!1,defaultCfg:{line:{type:"line",style:{lineWidth:1,stroke:a.a.lineColor}}}})},e.prototype.getLineType=function(){return(this.get("line")||this.get("defaultCfg").line).type},e.prototype.renderInner=function(t){this.drawGrid(t)},e.prototype.getAlternatePath=function(t,e){var n=this.getGridPath(t),i=e.slice(0).reverse(),r=this.getGridPath(i,!0);return this.get("closed")?n=n.concat(r):(r[0][0]="L",(n=n.concat(r)).push(["Z"])),n},e.prototype.getPathStyle=function(){return this.get("line").style},e.prototype.drawGrid=function(t){var e=this,n=this.get("line"),i=this.get("items"),o=this.get("alternateColor"),a=null;Object(r.each)(i,(function(s,c){var l=s.id||c;if(n){var u=e.getPathStyle();u=Object(r.isFunction)(u)?u(s,c,i):u;var h=e.getElementId("line-"+l),f=e.getGridPath(s.points);e.addShape(t,{type:"path",name:"grid-line",id:h,attrs:Object(r.mix)({path:f},u)})}if(o&&c>0){var p=e.getElementId("region-"+l),d=c%2==0;if(Object(r.isString)(o))d&&e.drawAlternateRegion(p,t,a.points,s.points,o);else{var g=d?o[1]:o[0];e.drawAlternateRegion(p,t,a.points,s.points,g)}}a=s}))},e.prototype.drawAlternateRegion=function(t,e,n,i,r){var o=this.getAlternatePath(n,i);this.addShape(e,{type:"path",id:t,name:"grid-region",attrs:{path:o,fill:r}})},e}(o.a);var c=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(i.__extends)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return Object(i.__assign)(Object(i.__assign)({},e),{type:"circle",center:null,closed:!0})},e.prototype.getGridPath=function(t,e){var n,i,o,a,s,c,l=this.getLineType(),u=this.get("closed"),h=[];if(t.length)if("circle"===l){var f=this.get("center"),p=t[0],d=(n=f.x,i=f.y,o=p.x,a=p.y,s=o-n,c=a-i,Math.sqrt(s*s+c*c)),g=e?0:1;u?(h.push(["M",f.x,f.y-d]),h.push(["A",d,d,0,0,g,f.x,f.y+d]),h.push(["A",d,d,0,0,g,f.x,f.y-d]),h.push(["Z"])):Object(r.each)(t,(function(t,e){0===e?h.push(["M",t.x,t.y]):h.push(["A",d,d,0,0,g,t.x,t.y])}))}else Object(r.each)(t,(function(t,e){0===e?h.push(["M",t.x,t.y]):h.push(["L",t.x,t.y])})),u&&h.push(["Z"]);return h},e}(s),l=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(i.__extends)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return Object(i.__assign)(Object(i.__assign)({},e),{type:"line"})},e.prototype.getGridPath=function(t){var e=[];return Object(r.each)(t,(function(t,n){0===n?e.push(["M",t.x,t.y]):e.push(["L",t.x,t.y])})),e},e}(s)},function(t,e,n){"use strict";n.r(e),n.d(e,"Category",(function(){return g})),n.d(e,"Continuous",(function(){return y})),n.d(e,"Base",(function(){return h}));var i=n(1),r=n(0),o=n(30),a=n(21),s=n(43),c=n(5),l=n(13),u=n(4),h=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(i.__extends)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return Object(i.__assign)(Object(i.__assign)({},e),{name:"legend",layout:"horizontal",locationType:"point",x:0,y:0,offsetX:0,offsetY:0,title:null,background:null})},e.prototype.getLayoutBBox=function(){var e=t.prototype.getLayoutBBox.call(this),n=this.get("maxWidth"),i=this.get("maxHeight"),r=e.width,o=e.height;return n&&(r=Math.min(r,n)),i&&(o=Math.min(o,i)),Object(u.b)(e.minX,e.minY,r,o)},e.prototype.setLocation=function(t){this.set("x",t.x),this.set("y",t.y),this.resetLocation()},e.prototype.resetLocation=function(){var t=this.get("x"),e=this.get("y"),n=this.get("offsetX"),i=this.get("offsetY");this.moveElementTo(this.get("group"),{x:t+n,y:e+i})},e.prototype.applyOffset=function(){this.resetLocation()},e.prototype.getDrawPoint=function(){return this.get("currentPoint")},e.prototype.setDrawPoint=function(t){return this.set("currentPoint",t)},e.prototype.renderInner=function(t){this.resetDraw(),this.get("title")&&this.drawTitle(t),this.drawLegendContent(t),this.get("background")&&this.drawBackground(t)},e.prototype.drawBackground=function(t){var e=this.get("background"),n=t.getBBox(),r=Object(u.c)(e.padding),o=Object(i.__assign)({x:0,y:0,width:n.width+r[1]+r[3],height:n.height+r[0]+r[2]},e.style);this.addShape(t,{type:"rect",id:this.getElementId("background"),name:"legend-background",attrs:o}).toBack()},e.prototype.drawTitle=function(t){var e=this.get("currentPoint"),n=this.get("title"),r=n.spacing,o=n.style,a=n.text,s=this.addShape(t,{type:"text",id:this.getElementId("title"),name:"legend-title",attrs:Object(i.__assign)({text:a,x:e.x,y:e.y},o)}).getBBox();this.set("currentPoint",{x:e.x,y:s.maxY+r})},e.prototype.resetDraw=function(){var t=this.get("background"),e={x:0,y:0};if(t){var n=Object(u.c)(t.padding);e.x=n[3],e.y=n[0]}this.set("currentPoint",e)},e}(l.a),f={marker:{style:{inactiveFill:"#000",inactiveOpacity:.45,fill:"#000",opacity:1,size:12}},text:{style:{fill:"#ccc",fontSize:12}}},p={fill:c.a.textColor,fontSize:12,textAlign:"start",textBaseline:"middle",fontFamily:c.a.fontFamily,fontWeight:"normal",lineHeight:12},d={right:90*Math.PI/180,left:270*Math.PI/180,up:0,down:180*Math.PI/180},g=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.currentPageIndex=1,e.totalPagesCnt=1,e.pageWidth=0,e.pageHeight=0,e.startX=0,e.startY=0,e.onNavigationBack=function(){var t=e.getElementByLocalId("item-group");if(e.currentPageIndex>1){e.currentPageIndex-=1,e.updateNavigation();var n=e.getCurrentNavigationMatrix();e.get("animate")?t.animate({matrix:n},100):t.attr({matrix:n})}},e.onNavigationAfter=function(){var t=e.getElementByLocalId("item-group");if(e.currentPageIndexg&&(g=m),"horizontal"===f?(y&&yb&&(b=e.width)})),O=b,b+=h,c&&(b=Math.min(c,b),O=Math.min(c,O)),this.pageWidth=b,this.pageHeight=l-Math.max(y.height,p+_);var S=Math.floor(this.pageHeight/(p+_));Object(r.each)(s,(function(t,e){0!==e&&e%S==0&&(m+=1,v.x+=b,v.y=o),n.moveElementTo(t,v),t.getParent().setClip({type:"rect",attrs:{x:v.x,y:v.y,width:b,height:p}}),v.y+=p+_})),this.totalPagesCnt=m,this.moveElementTo(g,{x:i+O/2-y.width/2-y.minX,y:l-y.height-y.minY})}this.pageHeight&&this.pageWidth&&e.getParent().setClip({type:"rect",attrs:{x:this.startX,y:this.startY,width:this.pageWidth,height:this.pageHeight}}),"horizontal"===a&&this.get("maxRow")?this.totalPagesCnt=Math.ceil(m/this.get("maxRow")):this.totalPagesCnt=m,this.currentPageIndex>this.totalPagesCnt&&(this.currentPageIndex=1),this.updateNavigation(g),e.attr("matrix",this.getCurrentNavigationMatrix())},e.prototype.drawNavigation=function(t,e,n,o){var a={x:0,y:0},s=this.addGroup(t,{id:this.getElementId("navigation-group"),name:"legend-navigation"}),c=Object(r.get)(o.marker,"style",{}),l=c.size,u=void 0===l?12:l,h=Object(i.__rest)(c,["size"]),f=this.drawArrow(s,a,"navigation-arrow-left","horizontal"===e?"up":"left",u,h);f.on("click",this.onNavigationBack);var p=f.getBBox();a.x+=p.width+2;var d=this.addShape(s,{type:"text",id:this.getElementId("navigation-text"),name:"navigation-text",attrs:Object(i.__assign)({x:a.x,y:a.y+u/2,text:n,textBaseline:"middle"},Object(r.get)(o.text,"style"))}).getBBox();return a.x+=d.width+2,this.drawArrow(s,a,"navigation-arrow-right","horizontal"===e?"down":"right",u,h).on("click",this.onNavigationAfter),s},e.prototype.updateNavigation=function(t){var e=Object(r.deepMix)({},f,this.get("pageNavigator")).marker.style,n=e.fill,i=e.opacity,o=e.inactiveFill,a=e.inactiveOpacity,s=this.currentPageIndex+"/"+this.totalPagesCnt,c=t?t.getChildren()[1]:this.getElementByLocalId("navigation-text"),l=t?t.findById(this.getElementId("navigation-arrow-left")):this.getElementByLocalId("navigation-arrow-left"),u=t?t.findById(this.getElementId("navigation-arrow-right")):this.getElementByLocalId("navigation-arrow-right");c.attr("text",s),l.attr("opacity",1===this.currentPageIndex?a:i),l.attr("fill",1===this.currentPageIndex?o:n),l.attr("cursor",1===this.currentPageIndex?"not-allowed":"pointer"),u.attr("opacity",this.currentPageIndex===this.totalPagesCnt?a:i),u.attr("fill",this.currentPageIndex===this.totalPagesCnt?o:n),u.attr("cursor",this.currentPageIndex===this.totalPagesCnt?"not-allowed":"pointer");var h=l.getBBox().maxX+2;c.attr("x",h),h+=c.getBBox().width+2,this.updateArrowPath(u,{x:h,y:0})},e.prototype.drawArrow=function(t,e,n,r,o,s){var c=e.x,l=e.y,u=this.addShape(t,{type:"path",id:this.getElementId(n),name:n,attrs:Object(i.__assign)({size:o,direction:r,path:[["M",c+o/2,l],["L",c,l+o],["L",c+o,l+o],["Z"]],cursor:"pointer"},s)});return u.attr("matrix",Object(a.e)({x:c+o/2,y:l+o/2},d[r])),u},e.prototype.updateArrowPath=function(t,e){var n=e.x,i=e.y,r=t.attr(),o=r.size,s=r.direction,c=Object(a.e)({x:n+o/2,y:i+o/2},d[s]);t.attr("path",[["M",n+o/2,i],["L",n,i+o],["L",n+o,i+o],["Z"]]),t.attr("matrix",c)},e.prototype.getCurrentNavigationMatrix=function(){var t=this.currentPageIndex,e=this.pageWidth,n=this.pageHeight,i="horizontal"===this.get("layout")?{x:0,y:n*(1-t)}:{x:e*(1-t),y:0};return Object(a.f)(i)},e.prototype.applyItemStates=function(t,e){if(this.getItemStates(t).length>0){var n=e.getChildren(),i=this.get("itemStates");Object(r.each)(n,(function(e){var n=e.get("name").split("-")[2],r=Object(s.a)(t,n,i);r&&(e.attr(r),"marker"!==n||e.get("isStroke")&&e.get("isFill")||(e.get("isStroke")&&e.attr("fill",null),e.get("isFill")&&e.attr("stroke",null)))}))}},e.prototype.getLimitItemWidth=function(){var t=this.get("itemWidth"),e=this.get("maxItemWidth");return e?t&&(e=t<=e?t:e):t&&(e=t),e},e}(h),y=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(i.__extends)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return Object(i.__assign)(Object(i.__assign)({},e),{type:"continue",min:0,max:100,value:null,colors:[],track:{},rail:{},label:{},handler:{},slidable:!0,tip:null,step:null,maxWidth:null,maxHeight:null,defaultCfg:{label:{align:"rail",spacing:5,formatter:null,style:{fontSize:12,fill:c.a.textColor,textBaseline:"middle",fontFamily:c.a.fontFamily}},handler:{size:10,style:{fill:"#fff",stroke:"#333"}},track:{},rail:{type:"color",size:20,defaultLength:100,style:{fill:"#DCDEE2"}},title:{spacing:5,style:{fill:c.a.textColor,fontSize:12,textAlign:"start",textBaseline:"top"}}}})},e.prototype.isSlider=function(){return!0},e.prototype.getValue=function(){return this.getCurrentValue()},e.prototype.getRange=function(){return{min:this.get("min"),max:this.get("max")}},e.prototype.setRange=function(t,e){this.update({min:t,max:e})},e.prototype.setValue=function(t){var e=this.getValue();this.set("value",t);var n=this.get("group");this.resetTrackClip(),this.get("slidable")&&this.resetHandlers(n),this.delegateEmit("valuechanged",{originValue:e,value:t})},e.prototype.initEvent=function(){var t=this.get("group");this.bindSliderEvent(t),this.bindRailEvent(t),this.bindTrackEvent(t)},e.prototype.drawLegendContent=function(t){this.drawRail(t),this.drawLabels(t),this.fixedElements(t),this.resetTrack(t),this.resetTrackClip(t),this.get("slidable")&&this.resetHandlers(t)},e.prototype.bindSliderEvent=function(t){this.bindHandlersEvent(t)},e.prototype.bindHandlersEvent=function(t){var e=this;t.on("legend-handler-min:drag",(function(t){var n=e.getValueByCanvasPoint(t.x,t.y),i=e.getCurrentValue()[1];in&&(i=n),e.setValue([i,n])}))},e.prototype.bindRailEvent=function(t){},e.prototype.bindTrackEvent=function(t){var e=this,n=null;t.on("legend-track:dragstart",(function(t){n={x:t.x,y:t.y}})),t.on("legend-track:drag",(function(t){if(n){var i=e.getValueByCanvasPoint(n.x,n.y),r=e.getValueByCanvasPoint(t.x,t.y),o=e.getCurrentValue(),a=o[1]-o[0],s=e.getRange(),c=r-i;c<0?o[0]+c>s.min?e.setValue([o[0]+c,o[1]+c]):e.setValue([s.min,s.min+a]):c>0&&(c>0&&o[1]+co&&(l=o),l0&&this.changeRailLength(i,o,n[o]-u)}},e.prototype.changeRailLength=function(t,e,n){var i,r=t.getBBox();i="height"===e?this.getRailPath(r.x,r.y,r.width,n):this.getRailPath(r.x,r.y,n,r.height),t.attr("path",i)},e.prototype.changeRailPosition=function(t,e,n){var i=t.getBBox(),r=this.getRailPath(e,n,i.width,i.height);t.attr("path",r)},e.prototype.fixedHorizontal=function(t,e,n,i){var r=this.get("label"),o=r.align,a=r.spacing,s=n.getBBox(),c=t.getBBox(),l=e.getBBox(),u=s.height;this.fitRailLength(c,l,s,n),s=n.getBBox(),"rail"===o?(t.attr({x:i.x,y:i.y+u/2}),this.changeRailPosition(n,i.x+c.width+a,i.y),e.attr({x:i.x+c.width+s.width+2*a,y:i.y+u/2})):"top"===o?(t.attr({x:i.x,y:i.y}),e.attr({x:i.x+s.width,y:i.y}),this.changeRailPosition(n,i.x,i.y+c.height+a)):(this.changeRailPosition(n,i.x,i.y),t.attr({x:i.x,y:i.y+s.height+a}),e.attr({x:i.x+s.width,y:i.y+s.height+a}))},e.prototype.fixedVertail=function(t,e,n,i){var r=this.get("label"),o=r.align,a=r.spacing,s=n.getBBox(),c=t.getBBox(),l=e.getBBox();if(this.fitRailLength(c,l,s,n),s=n.getBBox(),"rail"===o)t.attr({x:i.x,y:i.y}),this.changeRailPosition(n,i.x,i.y+c.height+a),e.attr({x:i.x,y:i.y+c.height+s.height+2*a});else if("right"===o)t.attr({x:i.x+s.width+a,y:i.y}),this.changeRailPosition(n,i.x,i.y),e.attr({x:i.x+s.width+a,y:i.y+s.height});else{var u=Math.max(c.width,l.width);t.attr({x:i.x,y:i.y}),this.changeRailPosition(n,i.x+u+a,i.y),e.attr({x:i.x,y:i.y+s.height})}},e}(h)},function(t,e,n){"use strict";n.r(e),n.d(e,"Html",(function(){return p}));var i,r=n(1),o=n(34),a=n(11),s=n(0),c=n(38),l=n(4),u=n(22),h=n(5),f=((i={})[""+u.CONTAINER_CLASS]={position:"absolute",visibility:"visible",zIndex:8,transition:"visibility 0.2s cubic-bezier(0.23, 1, 0.32, 1), left 0.4s cubic-bezier(0.23, 1, 0.32, 1), top 0.4s cubic-bezier(0.23, 1, 0.32, 1)",backgroundColor:"rgba(255, 255, 255, 0.9)",boxShadow:"0px 0px 10px #aeaeae",borderRadius:"3px",color:"rgb(87, 87, 87)",fontSize:"12px",fontFamily:h.a.fontFamily,lineHeight:"20px",padding:"10px 10px 6px 10px"},i[""+u.TITLE_CLASS]={marginBottom:"4px"},i[""+u.LIST_CLASS]={margin:"0px",listStyleType:"none",padding:"0px"},i[""+u.LIST_ITEM_CLASS]={listStyleType:"none",marginBottom:"4px"},i[""+u.MARKER_CLASS]={width:"8px",height:"8px",borderRadius:"50%",display:"inline-block",marginRight:"8px"},i[""+u.VALUE_CLASS]={display:"inline-block",float:"right",marginLeft:"30px"},i[""+u.CROSSHAIR_X]={position:"absolute",width:"1px",backgroundColor:"rgba(0, 0, 0, 0.25)"},i[""+u.CROSSHAIR_Y]={position:"absolute",height:"1px",backgroundColor:"rgba(0, 0, 0, 0.25)"},i);var p=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(r.__extends)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return Object(r.__assign)(Object(r.__assign)({},e),{name:"tooltip",type:"html",x:0,y:0,items:[],customContent:null,containerTpl:'
    ',itemTpl:'
  • \n \n {name}:\n {value}\n
  • ',xCrosshairTpl:'
    ',yCrosshairTpl:'
    ',title:null,showTitle:!0,region:null,crosshairsRegion:null,containerClassName:u.CONTAINER_CLASS,crosshairs:null,offset:10,position:"right",domStyles:null,defaultStyles:f})},e.prototype.render=function(){this.get("customContent")?this.renderCustomContent():(this.resetTitle(),this.renderItems()),this.resetPosition()},e.prototype.clear=function(){this.clearCrosshairs(),this.setTitle(""),this.clearItemDoms()},e.prototype.show=function(){var t=this.getContainer();t&&!this.destroyed&&(this.set("visible",!0),Object(a.e)(t,{visibility:"visible"}),this.setCrossHairsVisible(!0))},e.prototype.hide=function(){var t=this.getContainer();t&&!this.destroyed&&(this.set("visible",!1),Object(a.e)(t,{visibility:"hidden"}),this.setCrossHairsVisible(!1))},e.prototype.getLocation=function(){return{x:this.get("x"),y:this.get("y")}},e.prototype.setLocation=function(t){this.set("x",t.x),this.set("y",t.y),this.resetPosition()},e.prototype.setCrossHairsVisible=function(t){var e=t?"":"none",n=this.get("xCrosshairDom"),i=this.get("yCrosshairDom");n&&Object(a.e)(n,{display:e}),i&&Object(a.e)(i,{display:e})},e.prototype.initContainer=function(){if(t.prototype.initContainer.call(this),this.get("customContent")){this.get("container")&&this.get("container").remove();var e=this.getHtmlContentNode();this.get("parent").appendChild(e),this.set("container",e),this.resetStyles(),this.applyStyles()}},e.prototype.updateInner=function(e){var n,i,r;this.get("customContent")?this.renderCustomContent():(n=e,i=["title","showTitle"],r=!1,Object(s.each)(i,(function(t){if(Object(s.hasKey)(n,t))return r=!0,!1})),r&&this.resetTitle(),Object(s.hasKey)(e,"items")&&this.renderItems()),t.prototype.updateInner.call(this,e)},e.prototype.initDom=function(){this.cacheDoms()},e.prototype.removeDom=function(){t.prototype.removeDom.call(this),this.clearCrosshairs()},e.prototype.resetPosition=function(){var t,e=this.get("x"),n=this.get("y"),i=this.get("offset"),r=this.getOffset(),o=r.offsetX,s=r.offsetY,c=this.get("position"),u=this.get("region"),h=this.getContainer(),f=this.getBBox(),p=f.width,d=f.height;u&&(t=Object(l.k)(u));var g=function(t,e,n,i,r,o,a){var s=function(t,e,n,i,r,o){var a=t,s=e;switch(o){case"left":a=t-i-n,s=e-r/2;break;case"right":a=t+n,s=e-r/2;break;case"top":a=t-i/2,s=e-r-n;break;case"bottom":a=t-i/2,s=e+n;break;default:a=t+n,s=e-r-n}return{x:a,y:s}}(t,e,n,i,r,o);if(a){var c=function(t,e,n,i,r){return{left:tr.x+r.width,top:er.y+r.height}}(s.x,s.y,i,r,a);"auto"===o?(c.right&&(s.x=Math.max(0,t-i-n)),c.top&&(s.y=Math.max(0,e-r-n))):"top"===o||"bottom"===o?(c.left&&(s.x=a.x),c.right&&(s.x=a.x+a.width-i),"top"===o&&c.top&&(s.y=e+n),"bottom"===o&&c.bottom&&(s.y=e-r-n)):(c.top&&(s.y=a.y),c.bottom&&(s.y=a.y+a.height-r),"left"===o&&c.left&&(s.x=t+n),"right"===o&&c.right&&(s.x=t-i-n))}return s}(e,n,i,p,d,c,t);Object(a.e)(h,{left:Object(l.l)(g.x+o),top:Object(l.l)(g.y+s)}),this.resetCrosshairs()},e.prototype.renderCustomContent=function(){var t=this.getHtmlContentNode(),e=this.get("parent"),n=this.get("container");n&&n.parentNode===e?e.replaceChild(t,n):e.appendChild(t),this.set("container",t),this.resetStyles(),this.applyStyles()},e.prototype.getHtmlContentNode=function(){var t,e=this.get("customContent");if(e){var n=e(this.get("title"),this.get("items"));t=Object(s.isElement)(n)?n:Object(a.b)(n)}return t},e.prototype.cacheDoms=function(){var t=this.getContainer(),e=t.getElementsByClassName(u.TITLE_CLASS)[0],n=t.getElementsByClassName(u.LIST_CLASS)[0];this.set("titleDom",e),this.set("listDom",n)},e.prototype.resetTitle=function(){var t=this.get("title");this.get("showTitle")&&t?this.setTitle(t):this.setTitle("")},e.prototype.setTitle=function(t){var e=this.get("titleDom");e&&(e.innerText=t)},e.prototype.resetCrosshairs=function(){var t=this.get("crosshairsRegion"),e=this.get("crosshairs");if(t&&e){var n=Object(l.k)(t),i=this.get("xCrosshairDom"),r=this.get("yCrosshairDom");"x"===e?(this.resetCrosshair("x",n),r&&(r.remove(),this.set("yCrosshairDom",null))):"y"===e?(this.resetCrosshair("y",n),i&&(i.remove(),this.set("xCrosshairDom",null))):(this.resetCrosshair("x",n),this.resetCrosshair("y",n)),this.setCrossHairsVisible(this.get("visible"))}else this.clearCrosshairs()},e.prototype.resetCrosshair=function(t,e){var n=this.checkCrosshair(t),i=this.get(t);"x"===t?Object(a.e)(n,{left:Object(l.l)(i),top:Object(l.l)(e.y),height:Object(l.l)(e.height)}):Object(a.e)(n,{top:Object(l.l)(i),left:Object(l.l)(e.x),width:Object(l.l)(e.width)})},e.prototype.checkCrosshair=function(t){var e=t+"CrosshairDom",n=t+"CrosshairTpl",i="CROSSHAIR_"+t.toUpperCase(),r=u[i],o=this.get(e),s=this.get("parent");return o||(o=Object(a.b)(this.get(n)),this.applyStyle(r,o),s.appendChild(o),this.set(e,o)),o},e.prototype.renderItems=function(){this.clearItemDoms();var t=this.get("items"),e=this.get("itemTpl"),n=this.get("listDom");n&&(Object(s.each)(t,(function(t){var i=o.default.toCSSGradient(t.color),c=Object(r.__assign)(Object(r.__assign)({},t),{color:i}),l=Object(s.substitute)(e,c),u=Object(a.b)(l);n.appendChild(u)})),this.applyChildrenStyles(n,this.get("domStyles")))},e.prototype.clearItemDoms=function(){this.get("listDom")&&Object(l.a)(this.get("listDom"))},e.prototype.clearCrosshairs=function(){var t=this.get("xCrosshairDom"),e=this.get("yCrosshairDom");t&&t.remove(),e&&e.remove(),this.set("xCrosshairDom",null),this.set("yCrosshairDom",null)},e}(c.a)},function(t,e,n){"use strict";var i=n(1),r=n(10);function o(t,e,n){var i=t.getTotalMatrix();if(i){var o=function(t,e){if(e){var n=Object(r.invert)(e);return Object(r.multiplyVec2)(n,t)}return t}([e,n,1],i);return[o[0],o[1]]}return[e,n]}function a(t,e,n){if(t.isCanvas&&t.isCanvas())return!0;if(!Object(r.isAllowCapture)(t)||!1===t.cfg.isInView)return!1;if(t.cfg.clipShape){var i=o(t,e,n),a=i[0],s=i[1];if(t.isClipped(a,s))return!1}var c=t.cfg.cacheCanvasBBox||t.getCanvasBBox();return e>=c.minX&&e<=c.maxX&&n>=c.minY&&n<=c.maxY}var s=n(36),c=n(51),l=n(6),u=n(23),h=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(i.__extends)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return e.renderer="canvas",e.autoDraw=!0,e.localRefresh=!0,e.refreshElements=[],e.clipView=!0,e.quickHit=!1,e},e.prototype.onCanvasChange=function(t){"attr"!==t&&"sort"!==t&&"changeSize"!==t||(this.set("refreshElements",[this]),this.draw())},e.prototype.getShapeBase=function(){return s},e.prototype.getGroupBase=function(){return c.a},e.prototype.getPixelRatio=function(){var t=this.get("pixelRatio")||Object(l.d)();return t>=1?Math.ceil(t):1},e.prototype.getViewRange=function(){return{minX:0,minY:0,maxX:this.cfg.width,maxY:this.cfg.height}},e.prototype.createDom=function(){var t=document.createElement("canvas"),e=t.getContext("2d");return this.set("context",e),t},e.prototype.setDOMSize=function(e,n){t.prototype.setDOMSize.call(this,e,n);var i=this.get("context"),r=this.get("el"),o=this.getPixelRatio();r.width=o*e,r.height=o*n,o>1&&i.scale(o,o)},e.prototype.clear=function(){t.prototype.clear.call(this),this._clearFrame();var e=this.get("context"),n=this.get("el");e.clearRect(0,0,n.width,n.height)},e.prototype.getShape=function(e,n){return this.get("quickHit")?function t(e,n,i){if(!a(e,n,i))return null;for(var r=null,s=e.getChildren(),c=s.length-1;c>=0;c--){var l=s[c];if(l.isGroup())r=t(l,n,i);else if(a(l,n,i)){var u=l,h=o(l,n,i),f=h[0],p=h[1];u.isInShape(f,p)&&(r=l)}if(r)break}return r}(this,e,n):t.prototype.getShape.call(this,e,n,null)},e.prototype._getRefreshRegion=function(){var t,e=this.get("refreshElements"),n=this.getViewRange();e.length&&e[0]===this?t=n:(t=Object(u.f)(e))&&(t.minX=Math.floor(t.minX),t.minY=Math.floor(t.minY),t.maxX=Math.ceil(t.maxX),t.maxY=Math.ceil(t.maxY),t.maxY+=1,this.get("clipView")&&(t=Object(u.g)(t,n)));return t},e.prototype.refreshElement=function(t){this.get("refreshElements").push(t)},e.prototype._clearFrame=function(){var t=this.get("drawFrame");t&&(Object(l.a)(t),this.set("drawFrame",null),this.set("refreshElements",[]))},e.prototype.draw=function(){var t=this.get("drawFrame");this.get("autoDraw")&&t||this._startDraw()},e.prototype._drawAll=function(){var t=this.get("context"),e=this.get("el"),n=this.getChildren();t.clearRect(0,0,e.width,e.height),Object(u.a)(t,this),Object(u.d)(t,n),this.set("refreshElements",[])},e.prototype._drawRegion=function(){var t=this.get("context"),e=this.get("refreshElements"),n=this.getChildren(),i=this._getRefreshRegion();i?(t.clearRect(i.minX,i.minY,i.maxX-i.minX,i.maxY-i.minY),t.save(),t.beginPath(),t.rect(i.minX,i.minY,i.maxX-i.minX,i.maxY-i.minY),t.clip(),Object(u.a)(t,this),Object(u.b)(this,n,i),Object(u.d)(t,n,i),t.restore()):e.length&&Object(u.c)(e),Object(l.c)(e,(function(t){t.get("hasChanged")&&t.set("hasChanged",!1)})),this.set("refreshElements",[])},e.prototype._startDraw=function(){var t=this,e=this.get("drawFrame");e||(e=Object(l.n)((function(){t.get("localRefresh")?t._drawRegion():t._drawAll(),t.set("drawFrame",null)})),this.set("drawFrame",e))},e.prototype.skipDraw=function(){},e.prototype.removeDom=function(){var t=this.get("el");t.width=0,t.height=0,t.parentNode.removeChild(t)},e}(r.AbstractCanvas);e.a=h},function(t,e,n){"use strict";n.d(e,"a",(function(){return c}));var i=n(1),r=n(11),o=n(0),a=n(13),s={default:{trackColor:"rgba(0,0,0,0)",thumbColor:"rgba(0,0,0,0.15)",size:8,lineCap:"round"},hover:{thumbColor:"rgba(0,0,0,0.2)"}},c=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.clearEvents=o.noop,e.onStartEvent=function(t){return function(n){e.isMobile=t,n.originalEvent.preventDefault();var i=t?Object(o.get)(n.originalEvent,"touches.0.clientX"):n.clientX,r=t?Object(o.get)(n.originalEvent,"touches.0.clientY"):n.clientY;e.startPos=e.cfg.isHorizontal?i:r,e.bindLaterEvent()}},e.bindLaterEvent=function(){var t=e.getContainerDOM(),n=[];n=e.isMobile?[Object(r.a)(t,"touchmove",e.onMouseMove),Object(r.a)(t,"touchend",e.onMouseUp),Object(r.a)(t,"touchcancel",e.onMouseUp)]:[Object(r.a)(t,"mousemove",e.onMouseMove),Object(r.a)(t,"mouseup",e.onMouseUp),Object(r.a)(t,"mouseleave",e.onMouseUp)],e.clearEvents=function(){n.forEach((function(t){t.remove()}))}},e.onMouseMove=function(t){var n=e.cfg,i=n.isHorizontal,r=n.thumbOffset;t.preventDefault();var a=e.isMobile?Object(o.get)(t,"touches.0.clientX"):t.clientX,s=e.isMobile?Object(o.get)(t,"touches.0.clientY"):t.clientY,c=i?a:s,l=c-e.startPos;e.startPos=c,e.updateThumbOffset(r+l)},e.onMouseUp=function(t){t.preventDefault(),e.clearEvents()},e.onTrackClick=function(t){var n=e.cfg,i=n.isHorizontal,r=n.x,o=n.y,a=n.thumbLen,s=e.getContainerDOM().getBoundingClientRect(),c=t.clientX,l=t.clientY,u=i?c-s.left-r-a/2:l-s.top-o-a/2,h=e.validateRange(u);e.updateThumbOffset(h)},e.onThumbMouseOver=function(){var t=e.cfg.theme.hover.thumbColor;e.getElementByLocalId("thumb").attr("stroke",t),e.draw()},e.onThumbMouseOut=function(){var t=e.cfg.theme.default.thumbColor;e.getElementByLocalId("thumb").attr("stroke",t),e.draw()},e}return Object(i.__extends)(e,t),e.prototype.setRange=function(t,e){this.set("minLimit",t),this.set("maxLimit",e);var n=this.getValue(),i=Object(o.clamp)(n,t,e);n===i||this.get("isInit")||this.setValue(i)},e.prototype.getRange=function(){return{min:this.get("minLimit")||0,max:this.get("maxLimit")||1}},e.prototype.setValue=function(t){var e=this.getRange(),n=this.getValue();this.update({thumbOffset:(this.get("trackLen")-this.get("thumbLen"))*Object(o.clamp)(t,e.min,e.max)}),this.delegateEmit("valuechange",{originalValue:n,value:this.getValue()})},e.prototype.getValue=function(){return Object(o.clamp)(this.get("thumbOffset")/(this.get("trackLen")-this.get("thumbLen")),0,1)},e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return Object(i.__assign)(Object(i.__assign)({},e),{name:"scrollbar",isHorizontal:!0,minThumbLen:20,thumbOffset:0,theme:s})},e.prototype.renderInner=function(t){this.renderTrackShape(t),this.renderThumbShape(t)},e.prototype.applyOffset=function(){this.moveElementTo(this.get("group"),{x:this.get("x"),y:this.get("y")})},e.prototype.initEvent=function(){this.bindEvents()},e.prototype.renderTrackShape=function(t){var e=this.cfg,n=e.trackLen,i=e.theme,r=void 0===i?{default:{}}:i,a=Object(o.deepMix)({},s,r).default,c=a.lineCap,l=a.trackColor,u=a.size,h=Object(o.get)(this.cfg,"size",u),f=this.get("isHorizontal")?{x1:0+h/2,y1:h/2,x2:n-h/2,y2:h/2,lineWidth:h,stroke:l,lineCap:c}:{x1:h/2,y1:0+h/2,x2:h/2,y2:n-h/2,lineWidth:h,stroke:l,lineCap:c};return this.addShape(t,{id:this.getElementId("track"),name:"track",type:"line",attrs:f})},e.prototype.renderThumbShape=function(t){var e=this.cfg,n=e.thumbOffset,i=e.thumbLen,r=e.theme,a=Object(o.deepMix)({},s,r).default,c=a.size,l=a.lineCap,u=a.thumbColor,h=Object(o.get)(this.cfg,"size",c),f=this.get("isHorizontal")?{x1:n+h/2,y1:h/2,x2:n+i-h/2,y2:h/2,lineWidth:h,stroke:u,lineCap:l,cursor:"default"}:{x1:h/2,y1:n+h/2,x2:h/2,y2:n+i-h/2,lineWidth:h,stroke:u,lineCap:l,cursor:"default"};return this.addShape(t,{id:this.getElementId("thumb"),name:"thumb",type:"line",attrs:f})},e.prototype.bindEvents=function(){var t=this.get("group");t.on("mousedown",this.onStartEvent(!1)),t.on("mouseup",this.onMouseUp),t.on("touchstart",this.onStartEvent(!0)),t.on("touchend",this.onMouseUp),t.findById(this.getElementId("track")).on("click",this.onTrackClick);var e=t.findById(this.getElementId("thumb"));e.on("mouseover",this.onThumbMouseOver),e.on("mouseout",this.onThumbMouseOut)},e.prototype.getContainerDOM=function(){var t=this.get("container"),e=t&&t.get("canvas");return e&&e.get("container")},e.prototype.validateRange=function(t){var e=this.cfg,n=e.thumbLen,i=e.trackLen,r=t;return t+n>i?r=i-n:t+n=0)i=l+this.getIntervalOnlyOffset(n,e);else if(!r.isNil(c)&&r.isNil(s)&&c>=0){i=l+this.getDodgeOnlyOffset(n,e)}else if(!r.isNil(s)&&!r.isNil(c)&&s>=0&&c>=0){i=l+this.getIntervalAndDodgeOffset(n,e)}else{var f=h*o/n,p=a*f;i=(l+u)/2+(.5*(h-n*f-(n-1)*p)+((e+1)*f+e*p)-.5*f-.5*h)}return i},e.prototype.getIntervalOnlyOffset=function(t,e){var n=this,i=n.defaultSize,o=n.intervalPadding,a=n.xDimensionLegenth,s=n.groupNum,c=n.dodgeRatio,l=n.maxColumnWidth,u=n.minColumnWidth,h=n.columnWidthRatio,f=o/a,p=(1-(s-1)*f)/s*c/(t-1),d=((1-f*(s-1))/s-p*(t-1))/t;if(d=r.isNil(h)?d:1/s/t*h,!r.isNil(l)){var g=l/a;d=Math.min(d,g)}if(!r.isNil(u)){var y=u/a;d=Math.max(d,y)}return((.5+e)*(d=i?i/a:d)+e*(p=((1-(s-1)*f)/s-t*d)/(t-1))+.5*f)*s-f/2},e.prototype.getDodgeOnlyOffset=function(t,e){var n=this,i=n.defaultSize,o=n.dodgePadding,a=n.xDimensionLegenth,s=n.groupNum,c=n.marginRatio,l=n.maxColumnWidth,u=n.minColumnWidth,h=n.columnWidthRatio,f=o/a,p=1*c/(s-1),d=((1-p*(s-1))/s-f*(t-1))/t;if(d=h?1/s/t*h:d,!r.isNil(l)){var g=l/a;d=Math.min(d,g)}if(!r.isNil(u)){var y=u/a;d=Math.max(d,y)}return((.5+e)*(d=i?i/a:d)+e*f+.5*(p=(1-(d*t+f*(t-1))*s)/(s-1)))*s-p/2},e.prototype.getIntervalAndDodgeOffset=function(t,e){var n=this.intervalPadding,i=this.dodgePadding,r=this.xDimensionLegenth,o=this.groupNum,a=n/r,s=i/r;return((.5+e)*(((1-a*(o-1))/o-s*(t-1))/t)+e*s+.5*a)*o-a/2},e.prototype.getDistribution=function(t){var e=this.adjustDataArray,n=this.cacheMap,i=n[t];return i||(i={},r.each(e,(function(e,n){var o=r.valuesOfKey(e,t);o.length||o.push(0),r.each(o,(function(t){i[t]||(i[t]=[]),i[t].push(n)}))})),n[t]=i),i},e}(n(32).a);e.a=a},function(t,e,n){"use strict";var i=n(26),r=n(0),o=n(39);var a=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(i.b)(e,t),e.prototype.process=function(t){var e=r.clone(t),n=r.flatten(e);return this.adjustData(e,n),e},e.prototype.adjustDim=function(t,e,n){var i=this,o=this.groupData(n,t);return r.each(o,(function(n,r){return i.adjustGroup(n,t,parseFloat(r),e)}))},e.prototype.getAdjustOffset=function(t){var e,n=t.pre,i=t.next,r=(i-n)*o.c;return(i-r-(e=n+r))*Math.random()+e},e.prototype.adjustGroup=function(t,e,n,i){var o=this,a=this.getAdjustRange(e,n,i);return r.each(t,(function(t){t[e]=o.getAdjustOffset(a)})),t},e}(n(32).a);e.a=a},function(t,e,n){"use strict";var i=n(26),r=n(0),o=n(32),a=r.Cache,s=function(t){function e(e){var n=t.call(this,e)||this,i=e.adjustNames,r=void 0===i?["y"]:i,o=e.height,a=void 0===o?NaN:o,s=e.size,c=void 0===s?10:s,l=e.reverseOrder,u=void 0!==l&&l;return n.adjustNames=r,n.height=a,n.size=c,n.reverseOrder=u,n}return Object(i.b)(e,t),e.prototype.process=function(t){var e=this.yField,n=this.reverseOrder,i=e?this.processStack(t):this.processOneDimStack(t);return n?this.reverse(i):i},e.prototype.reverse=function(t){return t.slice(0).reverse()},e.prototype.processStack=function(t){var e=this.xField,n=this.yField,o=this.reverseOrder?this.reverse(t):t,s=new a,c=new a;return o.map((function(t){return t.map((function(t){var o,a=r.get(t,e,0),l=r.get(t,[n]),u=a.toString();if(l=r.isArray(l)?l[1]:l,!r.isNil(l)){var h=l>=0?s:c;h.has(u)||h.set(u,0);var f=h.get(u),p=l+f;return h.set(u,p),Object(i.a)(Object(i.a)({},t),((o={})[n]=[f,p],o))}return t}))}))},e.prototype.processOneDimStack=function(t){var e=this,n=this.xField,r=this.height,o=this.reverseOrder,s=o?this.reverse(t):t,c=new a;return s.map((function(t){return t.map((function(t){var o,a=e.size,s=t[n],l=2*a/r;c.has(s)||c.set(s,l/2);var u=c.get(s);return c.set(s,u+l),Object(i.a)(Object(i.a)({},t),((o={}).y=u,o))}))}))},e}(o.a);e.a=s},function(t,e,n){"use strict";var i=n(26),r=n(0),o=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return Object(i.b)(e,t),e.prototype.process=function(t){var e=r.flatten(t),n=this.xField,o=this.yField,a=this.getXValuesMaxMap(e),s=Math.max.apply(Math,Object.keys(a).map((function(t){return a[t]})));return r.map(t,(function(t){return r.map(t,(function(t){var e,c,l=t[o],u=t[n];if(r.isArray(l)){var h=(s-a[u])/2;return Object(i.a)(Object(i.a)({},t),((e={})[o]=r.map(l,(function(t){return h+t})),e))}var f=(s-l)/2;return Object(i.a)(Object(i.a)({},t),((c={})[o]=[f,l+f],c))}))}))},e.prototype.getXValuesMaxMap=function(t){var e=this,n=this.xField,i=this.yField,o=r.groupBy(t,(function(t){return t[n]}));return r.mapValues(o,(function(t){return e.getDimMaxValue(t,i)}))},e.prototype.getDimMaxValue=function(t,e){var n=r.map(t,(function(t){return r.get(t,e,[])})),i=r.flatten(n);return Math.max.apply(Math,i)},e}(n(32).a);e.a=o},function(t,e,n){"use strict";n.r(e),n.d(e,"version",(function(){return c}));var i=n(53);n.d(e,"Shape",(function(){return i}));var r=n(10);for(var o in r)["default","Canvas","Group","Shape","version"].indexOf(o)<0&&function(t){n.d(e,t,(function(){return r[t]}))}(o);var a=n(175);n.d(e,"Canvas",(function(){return a.a}));var s=n(52);n.d(e,"Group",(function(){return s.a}));var c="0.5.6"},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.adaptors=e.registerLocale=e.G2=e.version=void 0;var i=n(1);e.version="2.4.12";var r=i.__importStar(n(9));e.G2=r;var o=n(62);Object.defineProperty(e,"registerLocale",{enumerable:!0,get:function(){return o.registerLocale}});var a=n(206),s=n(207);o.registerLocale("en-US",a.EN_US_LOCALE),o.registerLocale("zh-CN",s.ZH_CN_LOCALE);var c=n(107);Object.defineProperty(e,"setGlobal",{enumerable:!0,get:function(){return c.setGlobal}});var l=n(7);Object.defineProperty(e,"Plot",{enumerable:!0,get:function(){return l.Plot}}),i.__exportStar(n(214),e);var u=n(110);Object.defineProperty(e,"Line",{enumerable:!0,get:function(){return u.Line}});var h=n(114);Object.defineProperty(e,"Area",{enumerable:!0,get:function(){return h.Area}});var f=n(116);Object.defineProperty(e,"Column",{enumerable:!0,get:function(){return f.Column}});var p=n(120);Object.defineProperty(e,"Bar",{enumerable:!0,get:function(){return p.Bar}});var d=n(122);Object.defineProperty(e,"Pie",{enumerable:!0,get:function(){return d.Pie}});var g=n(252);Object.defineProperty(e,"Rose",{enumerable:!0,get:function(){return g.Rose}});var y=n(256);Object.defineProperty(e,"WordCloud",{enumerable:!0,get:function(){return y.WordCloud}});var v=n(130);Object.defineProperty(e,"Scatter",{enumerable:!0,get:function(){return v.Scatter}});var m=n(266);Object.defineProperty(e,"Radar",{enumerable:!0,get:function(){return m.Radar}});var x=n(271);Object.defineProperty(e,"DualAxes",{enumerable:!0,get:function(){return x.DualAxes}});var b=n(134);Object.defineProperty(e,"TinyLine",{enumerable:!0,get:function(){return b.TinyLine}});var O=n(136);Object.defineProperty(e,"TinyColumn",{enumerable:!0,get:function(){return O.TinyColumn}});var _=n(138);Object.defineProperty(e,"TinyArea",{enumerable:!0,get:function(){return _.TinyArea}});var w=n(139);Object.defineProperty(e,"Histogram",{enumerable:!0,get:function(){return w.Histogram}});var j=n(143);Object.defineProperty(e,"Progress",{enumerable:!0,get:function(){return j.Progress}});var S=n(145);Object.defineProperty(e,"RingProgress",{enumerable:!0,get:function(){return S.RingProgress}});var M=n(285);Object.defineProperty(e,"Heatmap",{enumerable:!0,get:function(){return M.Heatmap}});var A=n(291);Object.defineProperty(e,"Box",{enumerable:!0,get:function(){return A.Box}});var C=n(294);Object.defineProperty(e,"Violin",{enumerable:!0,get:function(){return C.Violin}});var E=n(300);Object.defineProperty(e,"Venn",{enumerable:!0,get:function(){return E.Venn}});var I=n(313);Object.defineProperty(e,"Stock",{enumerable:!0,get:function(){return I.Stock}});var P=n(153);Object.defineProperty(e,"Funnel",{enumerable:!0,get:function(){return P.Funnel}}),Object.defineProperty(e,"FUNNEL_CONVERSATION_FIELD",{enumerable:!0,get:function(){return P.FUNNEL_CONVERSATION_FIELD}});var F=n(320);Object.defineProperty(e,"Liquid",{enumerable:!0,get:function(){return F.Liquid}}),Object.defineProperty(e,"addWaterWave",{enumerable:!0,get:function(){return F.addWaterWave}});var T=n(324);Object.defineProperty(e,"Bullet",{enumerable:!0,get:function(){return T.Bullet}});var L=n(328);Object.defineProperty(e,"Sunburst",{enumerable:!0,get:function(){return L.Sunburst}});var k=n(160);Object.defineProperty(e,"Gauge",{enumerable:!0,get:function(){return k.Gauge}});var D=n(339);Object.defineProperty(e,"Waterfall",{enumerable:!0,get:function(){return D.Waterfall}});var B=n(343);Object.defineProperty(e,"RadialBar",{enumerable:!0,get:function(){return B.RadialBar}});var R=n(348);Object.defineProperty(e,"BidirectionalBar",{enumerable:!0,get:function(){return R.BidirectionalBar}});var N=n(351);Object.defineProperty(e,"Treemap",{enumerable:!0,get:function(){return N.Treemap}});var V=n(356);Object.defineProperty(e,"Sankey",{enumerable:!0,get:function(){return V.Sankey}});var z=n(367);Object.defineProperty(e,"Chord",{enumerable:!0,get:function(){return z.Chord}});var G=n(371);Object.defineProperty(e,"CirclePacking",{enumerable:!0,get:function(){return G.CirclePacking}});var Y=n(377);Object.defineProperty(e,"P",{enumerable:!0,get:function(){return Y.P}});var X=n(111);Object.defineProperty(e,"getCanvasPattern",{enumerable:!0,get:function(){return X.getCanvasPattern}});var W=n(92);Object.defineProperty(e,"MultiView",{enumerable:!0,get:function(){return W.Mix}});var H=n(92);Object.defineProperty(e,"Mix",{enumerable:!0,get:function(){return H.Mix}});var U=n(383);Object.defineProperty(e,"Facet",{enumerable:!0,get:function(){return U.Facet}});var q=n(2);Object.defineProperty(e,"flow",{enumerable:!0,get:function(){return q.flow}}),Object.defineProperty(e,"measureTextWidth",{enumerable:!0,get:function(){return q.measureTextWidth}});var Z=n(18);Object.defineProperty(e,"line",{enumerable:!0,get:function(){return Z.line}}),Object.defineProperty(e,"interval",{enumerable:!0,get:function(){return Z.interval}}),Object.defineProperty(e,"area",{enumerable:!0,get:function(){return Z.area}}),Object.defineProperty(e,"point",{enumerable:!0,get:function(){return Z.point}}),Object.defineProperty(e,"polygon",{enumerable:!0,get:function(){return Z.polygon}}),Object.defineProperty(e,"schema",{enumerable:!0,get:function(){return Z.schema}});var $=n(12);e.adaptors={scale:$.scale,legend:$.legend,tooltip:$.tooltip,annotation:$.annotation,interaction:$.interaction,theme:$.theme,animation:$.animation};var K=n(388);Object.defineProperty(e,"Lab",{enumerable:!0,get:function(){return K.Lab}})},,,,,,,,function(t,e){var n,i,r=t.exports={};function o(){throw new Error("setTimeout has not been defined")}function a(){throw new Error("clearTimeout has not been defined")}function s(t){if(n===setTimeout)return setTimeout(t,0);if((n===o||!n)&&setTimeout)return n=setTimeout,setTimeout(t,0);try{return n(t,0)}catch(e){try{return n.call(null,t,0)}catch(e){return n.call(this,t,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:o}catch(t){n=o}try{i="function"==typeof clearTimeout?clearTimeout:a}catch(t){i=a}}();var c,l=[],u=!1,h=-1;function f(){u&&c&&(u=!1,c.length?l=c.concat(l):h=-1,l.length&&p())}function p(){if(!u){var t=s(f);u=!0;for(var e=l.length;e;){for(c=l,l=[];++h1)for(var n=1;nO){var w=_/v.length,j=Math.max(1,Math.ceil(O/w)-1),S=v.slice(0,j)+"...";b.attr("text",S)}}}}(t,e,n)}e.conversionTag=function(t,e,n){return void 0===e&&(e=!0),void 0===n&&(n=!1),function(i){var s=i.options,l=i.chart,h=s.conversionTag,f=s.theme;return h&&!n&&(l.theme(a.deepAssign({},r.isObject(f)?f:o.getTheme(f),{columnWidthRatio:1/3})),l.annotation().shape({render:function(n,i){var o=n.addGroup({id:l.id+"-conversion-tag-group",name:"conversion-tag-group"}),a=r.find(l.geometries,(function(t){return"interval"===t.type})),s={view:i,geometry:a,group:o,field:t,horizontal:e,options:c(h,e)},f=a.elements;r.each(f,(function(t,e){e>0&&u(s,f[e-1],t)}))}})),i}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.connectedArea=void 0;var i=n(9),r={hover:"__interval-connected-area-hover__",click:"__interval-connected-area-click__"},o=function(t,e){return"hover"===t?[{trigger:"interval:mouseenter",action:["element-highlight-by-color:highlight","element-link-by-color:link"],arg:[null,{style:e}]}]:[{trigger:"interval:click",action:["element-highlight-by-color:clear","element-highlight-by-color:highlight","element-link-by-color:clear","element-link-by-color:unlink","element-link-by-color:link"],arg:[null,null,null,null,{style:e}]}]};i.registerInteraction(r.hover,{start:o(r.hover),end:[{trigger:"interval:mouseleave",action:["element-highlight-by-color:reset","element-link-by-color:unlink"]}]}),i.registerInteraction(r.click,{start:o(r.click),end:[{trigger:"document:mousedown",action:["element-highlight-by-color:clear","element-link-by-color:clear"]}]}),e.connectedArea=function(t){return void 0===t&&(t=!1),function(e){var n=e.chart,i=e.options.connectedArea,a=function(){n.removeInteraction(r.hover),n.removeInteraction(r.click)};if(!t&&i){var s=i.trigger||"hover";a(),n.interaction(r[s],{start:o(s,i.style)})}else a();return e}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.ButtonAction=e.BUTTON_ACTION_CONFIG=void 0;var i=n(1),r=n(9),o=n(0),a=n(2);e.BUTTON_ACTION_CONFIG={padding:[8,10],text:"reset",textStyle:{default:{x:0,y:0,fontSize:12,fill:"#333333",cursor:"pointer"}},buttonStyle:{default:{fill:"#f7f7f7",stroke:"#cccccc",cursor:"pointer"},active:{fill:"#e6e6e6"}}};var s=function(t){function n(){var n=null!==t&&t.apply(this,arguments)||this;return n.buttonGroup=null,n.buttonCfg=i.__assign({name:"button"},e.BUTTON_ACTION_CONFIG),n}return i.__extends(n,t),n.prototype.getButtonCfg=function(){var t=this.context.view,e=o.get(t,["interactions","filter-action","cfg","buttonConfig"]);return a.deepAssign(this.buttonCfg,e,this.cfg)},n.prototype.drawButton=function(){var t=this.getButtonCfg(),e=this.context.view.foregroundGroup.addGroup({name:t.name}),n=this.drawText(e);this.drawBackground(e,n.getBBox()),this.buttonGroup=e},n.prototype.drawText=function(t){var e,n=this.getButtonCfg();return t.addShape({type:"text",name:"button-text",attrs:i.__assign({text:n.text},null===(e=n.textStyle)||void 0===e?void 0:e.default)})},n.prototype.drawBackground=function(t,e){var n,r=this.getButtonCfg(),o=a.normalPadding(r.padding),s=t.addShape({type:"rect",name:"button-rect",attrs:i.__assign({x:e.x-o[3],y:e.y-o[0],width:e.width+o[1]+o[3],height:e.height+o[0]+o[2]},null===(n=r.buttonStyle)||void 0===n?void 0:n.default)});return s.toBack(),t.on("mouseenter",(function(){var t;s.attr(null===(t=r.buttonStyle)||void 0===t?void 0:t.active)})),t.on("mouseleave",(function(){var t;s.attr(null===(t=r.buttonStyle)||void 0===t?void 0:t.default)})),s},n.prototype.resetPosition=function(){var t=this.context.view.getCoordinate().convert({x:1,y:1}),e=this.buttonGroup,n=e.getBBox(),i=r.Util.transform(null,[["t",t.x-n.width-10,t.y+n.height+5]]);e.setMatrix(i)},n.prototype.show=function(){this.buttonGroup||this.drawButton(),this.resetPosition(),this.buttonGroup.show()},n.prototype.hide=function(){this.buttonGroup&&this.buttonGroup.hide()},n.prototype.destroy=function(){var e=this.buttonGroup;e&&e.remove(),t.prototype.destroy.call(this)},n}(r.Action);e.ButtonAction=s},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DEFAULT_OPTIONS=void 0;var i=n(7),r=n(2);e.DEFAULT_OPTIONS=r.deepAssign({},i.Plot.getDefaultOptions(),{columnWidthRatio:.6,marginRatio:1/32,tooltip:{shared:!0,showMarkers:!1,offset:20},legend:{radio:{}},interactions:[{type:"active-region"}]})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DEFAULT_OPTIONS=void 0;var i=n(7),r=n(2);e.DEFAULT_OPTIONS=r.deepAssign({},i.Plot.getDefaultOptions(),{barWidthRatio:.6,marginRatio:1/32,tooltip:{shared:!0,showMarkers:!1,offset:20},legend:{radio:{}},interactions:[{type:"active-region"}]})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.PieLegendAction=void 0;var i=n(1),r=n(9),o=n(0),a=n(127),s=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return i.__extends(e,t),e.prototype.getActiveElements=function(){var t=r.Util.getDelegationObject(this.context);if(t){var e=this.context.view,n=t.component,i=t.item,o=n.get("field");if(o)return e.geometries[0].elements.filter((function(t){return t.getModel().data[o]===i.value}))}return[]},e.prototype.getActiveElementLabels=function(){var t=this.context.view,e=this.getActiveElements();return t.geometries[0].labelsContainer.getChildren().filter((function(t){return e.find((function(e){return o.isEqual(e.getData(),t.get("data"))}))}))},e.prototype.transfrom=function(t){void 0===t&&(t=7.5);var e=this.getActiveElements(),n=this.getActiveElementLabels();e.forEach((function(e,i){var o=n[i],s=e.geometry.coordinate;if(s.isPolar&&s.isTransposed){var c=r.Util.getAngle(e.getModel(),s),l=(c.startAngle+c.endAngle)/2,u=t,h=u*Math.cos(l),f=u*Math.sin(l);e.shape.setMatrix(a.transform([["t",h,f]])),o.setMatrix(a.transform([["t",h,f]]))}}))},e.prototype.active=function(){this.transfrom()},e.prototype.reset=function(){this.transfrom(0)},e}(r.Action);e.PieLegendAction=s},function(t,e,n){"use strict";function i(t){return(i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}Object.defineProperty(e,"__esModule",{value:!0}),e.StatisticAction=void 0;var r=n(1),o=n(9),a=n(0),s=n(106),c=n(250),l=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return r.__extends(e,t),e.prototype.getAnnotations=function(t){return(t||this.context.view).getController("annotation").option},e.prototype.getInitialAnnotation=function(){return this.initialAnnotation},e.prototype.init=function(){var t=this,e=this.context.view;e.removeInteraction("tooltip"),e.on("afterchangesize",(function(){var n=t.getAnnotations(e);t.initialAnnotation=n}))},e.prototype.change=function(t){var e=this.context,n=e.view,r=e.event;this.initialAnnotation||(this.initialAnnotation=this.getAnnotations());var l=a.get(r,["data","data"]);if(r.type.match("legend-item")){var u=o.Util.getDelegationObject(this.context),h=n.getGroupedFields()[0];if(u&&h){var f=u.item;l=n.getData().find((function(t){return t[h]===f.value}))}}if(l){var p=a.get(t,"annotations",[]),d=a.get(t,"statistic",{});n.getController("annotation").clear(!0),a.each(p,(function(t){"object"===i(t)&&n.annotation()[t.type](t)})),s.renderStatistic(n,{statistic:d,plotType:"pie"},l),n.render(!0)}var g=c.getCurrentElement(this.context);g&&g.shape.toFront()},e.prototype.reset=function(){var t=this.context.view;t.getController("annotation").clear(!0);var e=this.getInitialAnnotation();a.each(e,(function(e){t.annotation()[e.type](e)})),t.render(!0)},e}(o.Action);e.StatisticAction=l},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getCurrentElement=void 0,e.getCurrentElement=function(t){var e,n=t.event.target;return n&&(e=n.get("element")),e}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.Rose=void 0;var i=n(1),r=n(7),o=(n(253),n(254)),a=n(255),s=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="rose",e}return i.__extends(e,t),e.getDefaultOptions=function(){return a.DEFAULT_OPTIONS},e.prototype.changeData=function(t){this.updateOption({data:t}),this.chart.changeData(t)},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return o.adaptor},e}(r.Plot);e.Rose=s},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.adaptor=e.legend=void 0;var i=n(1),r=n(0),o=n(2),a=n(12),s=n(18);function c(t){var e=t.chart,n=t.options,i=n.data,r=n.sectorStyle,a=n.color;return e.data(i),o.flow(s.interval)(o.deepAssign({},t,{options:{marginRatio:1,interval:{style:r,color:a}}})),t}function l(t){var e=t.chart,n=t.options,a=n.label,s=n.xField,c=o.findGeometry(e,"interval");if(!1===a)c.label(!1);else if(r.isObject(a)){var l=a.callback,u=a.fields,h=i.__rest(a,["callback","fields"]),f=h.offset,p=h.layout;(void 0===f||f>=0)&&(p=p?r.isArray(p)?p:[p]:[],h.layout=r.filter(p,(function(t){return"limit-in-shape"!==t.type})),h.layout.length||delete h.layout),c.label({fields:u||[s],callback:l,cfg:o.transformLabel(h)})}else o.log(o.LEVEL.WARN,null===a,"the label option must be an Object."),c.label({fields:[s]});return t}function u(t){var e=t.chart,n=t.options,i=n.legend,r=n.seriesField;return!1===i?e.legend(!1):r&&e.legend(r,i),t}function h(t){var e=t.chart,n=t.options,i=n.radius,r=n.innerRadius,o=n.startAngle,a=n.endAngle;return e.coordinate({type:"polar",cfg:{radius:i,innerRadius:r,startAngle:o,endAngle:a}}),t}function f(t){var e,n=t.options,i=n.xAxis,r=n.yAxis,s=n.xField,c=n.yField;return o.flow(a.scale(((e={})[s]=i,e[c]=r,e)))(t)}function p(t){var e=t.chart,n=t.options,i=n.xAxis,r=n.yAxis,o=n.xField,a=n.yField;return i?e.axis(o,i):e.axis(o,!1),r?e.axis(a,r):e.axis(a,!1),t}e.legend=u,e.adaptor=function(t){o.flow(a.pattern("sectorStyle"),c,f,l,h,p,u,a.tooltip,a.interaction,a.animation,a.theme,a.annotation(),a.state)(t)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DEFAULT_OPTIONS=void 0;var i=n(7),r=n(2);e.DEFAULT_OPTIONS=r.deepAssign({},i.Plot.getDefaultOptions(),{xAxis:!1,yAxis:!1,legend:{position:"right",radio:{}},sectorStyle:{stroke:"#fff",lineWidth:1},label:{layout:{type:"limit-in-shape"}},tooltip:{shared:!0,showMarkers:!1},interactions:[{type:"active-region"}]})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.WordCloud=void 0;var i=n(1),r=n(7),o=(n(257),n(258)),a=n(129),s=n(128);n(260);var c=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="word-cloud",e}return i.__extends(e,t),e.getDefaultOptions=function(){return a.DEFAULT_OPTIONS},e.prototype.changeData=function(t){this.updateOption({data:t}),this.options.imageMask?this.render():this.chart.changeData(s.transform({chart:this.chart,options:this.options}))},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.render=function(){var e=this;return new Promise((function(n){var r=e.options.imageMask;if(!r)return t.prototype.render.call(e),void n();var o=function(r){e.options=i.__assign(i.__assign({},e.options),{imageMask:r||null}),t.prototype.render.call(e),n()};s.processImageMask(r).then(o).catch(o)}))},e.prototype.getSchemaAdaptor=function(){return o.adaptor},e.prototype.triggerResize=function(){var e=this;this.chart.destroyed||(this.execAdaptor(),window.setTimeout((function(){t.prototype.triggerResize.call(e)})))},e}(r.Plot);e.WordCloud=c},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.adaptor=e.legend=void 0;var i=n(1),r=n(0),o=n(12),a=n(2),s=n(18),c=n(128),l=n(129);function u(t){var e=t.chart,n=t.options,o=n.colorField,u=n.color,h=c.transform(t);e.data(h);var f=a.deepAssign({},t,{options:{xField:"x",yField:"y",seriesField:o&&l.WORD_CLOUD_COLOR_FIELD,rawFields:r.isFunction(u)&&i.__spreadArrays(r.get(n,"rawFields",[]),["datum"]),point:{color:u,shape:"word-cloud"}}});return s.point(f).ext.geometry.label(!1),e.coordinate().reflect("y"),e.axis(!1),t}function h(t){return a.flow(o.scale({x:{nice:!1},y:{nice:!1}}))(t)}function f(t){var e=t.chart,n=t.options,i=n.legend,r=n.colorField;return!1===i?e.legend(!1):r&&e.legend(l.WORD_CLOUD_COLOR_FIELD,i),t}e.legend=f,e.adaptor=function(t){a.flow(u,h,o.tooltip,f,o.interaction,o.animation,o.theme,o.state)(t)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.functor=e.transform=e.wordCloud=void 0;var i=n(0),r={font:function(){return"serif"},padding:1,size:[500,500],spiral:"archimedean",timeInterval:3e3};function o(t,e){var n=function(){var t=[256,256],e=c,n=u,i=l,r=h,o=f,a=y,O=Math.random,_=[],w=1/0,j=s,S=l,M=m,A={};function C(e,n,i){for(var r,o,s,c,l,u=n.x,h=n.y,f=Math.sqrt(t[0]*t[0]+t[1]*t[1]),p=a(t),g=O()<.5?1:-1,y=-g;(r=p(y+=g))&&(o=~~r[0],s=~~r[1],!(Math.min(Math.abs(o),Math.abs(s))>=f));)if(n.x=u+o,n.y=h+s,!(n.x+n.x0<0||n.y+n.y0<0||n.x+n.x1>t[0]||n.y+n.y1>t[1]||i&&d(n,e,t[0])||i&&(l=i,!((c=n).x+c.x1>l[0].x&&c.x+c.x0l[0].y&&c.y+c.y0>5,x=t[0]>>5,b=n.x-(m<<4),_=127&b,w=32-_,j=n.y1-n.y0,S=void 0,M=(n.y+n.y0)*x+(b>>5),A=0;A>>_:0);M+=x}return delete n.sprite,!0}return!1}return A.start=function(){var a=t[0],s=t[1],c=function(t){t.width=t.height=1;var e=Math.sqrt(t.getContext("2d").getImageData(0,0,1,1).data.length>>2);t.width=2048/e,t.height=2048/e;var n=t.getContext("2d");return n.fillStyle=n.strokeStyle="red",n.textAlign="center",{context:n,ratio:e}}(M()),l=A.board?A.board:v((t[0]>>5)*t[1]),u=_.length,h=[],f=_.map((function(t,a,s){return t.text=j.call(this,t,a,s),t.font=e.call(this,t,a,s),t.style=S.call(this,t,a,s),t.weight=i.call(this,t,a,s),t.rotate=r.call(this,t,a,s),t.size=~~n.call(this,t,a,s),t.padding=o.call(this,t,a,s),t})).sort((function(t,e){return e.size-t.size})),d=-1,y=A.board?[{x:0,y:0},{x:a,y:s}]:null;return function(){var e=Date.now();for(;Date.now()-e>1,n.y=s*(O()+.5)>>1,p(c,n,f,d),n.hasText&&C(l,n,y)&&(h.push(n),y?A.hasImage||g(y,n):y=[{x:n.x+n.x0,y:n.y+n.y0},{x:n.x+n.x1,y:n.y+n.y1}],n.x-=t[0]>>1,n.y-=t[1]>>1)}A._tags=h,A._bounds=y}(),A},A.createMask=function(e){var n=document.createElement("canvas"),i=t[0],r=t[1];if(i&&r){var o=i>>5,a=v((i>>5)*r);n.width=i,n.height=r;var s=n.getContext("2d");s.drawImage(e,0,0,e.width,e.height,0,0,i,r);for(var c=s.getImageData(0,0,i,r).data,l=0;l>5),f=l*i+u<<2,p=c[f]>=250&&c[f+1]>=250&&c[f+2]>=250?1<<31-u%32:0;a[h]|=p}A.board=a,A.hasImage=!0}},A.timeInterval=function(t){w=null==t?1/0:t},A.words=function(t){_=t},A.size=function(e){t=[+e[0],+e[1]]},A.font=function(t){e=x(t)},A.fontWeight=function(t){i=x(t)},A.rotate=function(t){r=x(t)},A.spiral=function(t){a=b[t]||t},A.fontSize=function(t){n=x(t)},A.padding=function(t){o=x(t)},A.random=function(t){O=x(t)},A}();["font","fontSize","fontWeight","padding","rotate","size","spiral","timeInterval","random"].forEach((function(t){i.isNil(e[t])||n[t](e[t])})),n.words(t),e.imageMask&&n.createMask(e.imageMask);var r=n.start()._tags;r.forEach((function(t){t.x+=e.size[0]/2,t.y+=e.size[1]/2}));var o=e.size,a=o[0],O=o[1];return r.push({text:"",value:0,x:0,y:0,opacity:0}),r.push({text:"",value:0,x:a,y:O,opacity:0}),r}e.wordCloud=function(t,e){return o(t,e=i.assign({},r,e))},e.transform=o;var a=Math.PI/180;function s(t){return t.text}function c(){return"serif"}function l(){return"normal"}function u(t){return t.value}function h(){return 90*~~(2*Math.random())}function f(){return 1}function p(t,e,n,i){if(!e.sprite){var r=t.context,o=t.ratio;r.clearRect(0,0,2048/o,2048/o);var s=0,c=0,l=0,u=n.length;for(--i;++i>5<<5,f=~~Math.max(Math.abs(y+v),Math.abs(y-v))}else h=h+31>>5<<5;if(f>l&&(l=f),s+h>=2048&&(s=0,c+=l,l=0),c+f>=2048)break;r.translate((s+(h>>1))/o,(c+(f>>1))/o),e.rotate&&r.rotate(e.rotate*a),r.fillText(e.text,0,0),e.padding&&(r.lineWidth=2*e.padding,r.strokeText(e.text,0,0)),r.restore(),e.width=h,e.height=f,e.xoff=s,e.yoff=c,e.x1=h>>1,e.y1=f>>1,e.x0=-e.x1,e.y0=-e.y1,e.hasText=!0,s+=h}for(var x=r.getImageData(0,0,2048/o,2048/o).data,b=[];--i>=0;)if((e=n[i]).hasText){for(var O=(h=e.width)>>5,_=(f=e.y1-e.y0,0);_>5),A=x[2048*(c+S)+(s+_)<<2]?1<<31-_%32:0;b[M]|=A,w|=A}w?j=S:(e.y0++,f--,S--,c++)}e.y1=e.y0+j,e.sprite=b.slice(0,(e.y1-e.y0)*O)}}}function d(t,e,n){n>>=5;for(var i,r=t.sprite,o=t.width>>5,a=t.x-(o<<4),s=127&a,c=32-s,l=t.y1-t.y0,u=(t.y+t.y0)*n+(a>>5),h=0;h>>s:0))&e[u+f])return!0;u+=n}return!1}function g(t,e){var n=t[0],i=t[1];e.x+e.x0i.x&&(i.x=e.x+e.x1),e.y+e.y1>i.y&&(i.y=e.y+e.y1)}function y(t){var e=t[0]/t[1];return function(t){return[e*(t*=.1)*Math.cos(t),t*Math.sin(t)]}}function v(t){for(var e=[],n=-1;++n0,f=u>0;function p(t,e){var n=o.get(r,[t]);function i(t){return o.get(n,t)}var a={};return"x"===e?(o.isNumber(l)&&(o.isNumber(i("min"))||(a.min=h?0:2*l),o.isNumber(i("max"))||(a.max=h?2*l:0)),a):(o.isNumber(u)&&(o.isNumber(i("min"))||(a.min=f?0:2*u),o.isNumber(i("max"))||(a.max=f?2*u:0)),a)}return i.__assign(i.__assign({},r),((e={})[a]=i.__assign(i.__assign({},r[a]),p(a,"x")),e[s]=i.__assign(i.__assign({},r[s]),p(s,"y")),e))}},function(t,e,n){"use strict";function i(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var n=[],i=!0,r=!1,o=void 0;try{for(var a,s=t[Symbol.iterator]();!(i=(a=s.next()).done)&&(n.push(a.value),!e||n.length!==e);i=!0);}catch(t){r=!0,o=t}finally{try{i||null==s.return||s.return()}finally{if(r)throw o}}return n}(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance")}()}function r(t,e,n,i){t=t.filter((function(t,i){var r=e(t,i),o=n(t,i);return null!=r&&isFinite(r)&&null!=o&&isFinite(o)})),i&&t.sort((function(t,n){return e(t)-e(n)}));for(var r,o,a,s=t.length,c=new Float64Array(s),l=new Float64Array(s),u=0,h=0,f=0;fr&&(t.splice(o+1,0,f),i=!0)}return i}}function l(t,e,n,i){var r=i-t*t,o=Math.abs(r)<1e-24?0:(n-t*e)/r;return[e-o*t,o]}function u(){var t,e=function(t){return t[0]},n=function(t){return t[1]};function r(r){var s=0,u=0,h=0,f=0,p=0,d=0,g=t?+t[0]:1/0,y=t?+t[1]:-1/0;o(r,e,n,(function(e,n){var i=Math.log(n),r=e*n;++s,u+=(n-u)/s,f+=(r-f)/s,d+=(e*r-d)/s,h+=(n*i-h)/s,p+=(r*i-p)/s,t||(ey&&(y=e))}));var v=i(l(f/u,h/u,p/u,d/u),2),m=v[0],x=v[1];m=Math.exp(m);var b=function(t){return m*Math.exp(x*t)},O=c(g,y,b);return O.a=m,O.b=x,O.predict=b,O.rSquared=a(r,e,n,u,b),O}return r.domain=function(e){return arguments.length?(t=e,r):t},r.x=function(t){return arguments.length?(e=t,r):e},r.y=function(t){return arguments.length?(n=t,r):n},r}function h(){var t,e=function(t){return t[0]},n=function(t){return t[1]};function r(r){var s=0,c=0,u=0,h=0,f=0,p=t?+t[0]:1/0,d=t?+t[1]:-1/0;o(r,e,n,(function(e,n){++s,c+=(e-c)/s,u+=(n-u)/s,h+=(e*n-h)/s,f+=(e*e-f)/s,t||(ed&&(d=e))}));var g=i(l(c,u,h,f),2),y=g[0],v=g[1],m=function(t){return v*t+y},x=[[p,m(p)],[d,m(d)]];return x.a=v,x.b=y,x.predict=m,x.rSquared=a(r,e,n,u,m),x}return r.domain=function(e){return arguments.length?(t=e,r):t},r.x=function(t){return arguments.length?(e=t,r):e},r.y=function(t){return arguments.length?(n=t,r):n},r}function f(t){t.sort((function(t,e){return t-e}));var e=t.length/2;return e%1==0?(t[e-1]+t[e])/2:t[Math.floor(e)]}n.r(e),n.d(e,"regressionExp",(function(){return u})),n.d(e,"regressionLinear",(function(){return h})),n.d(e,"regressionLoess",(function(){return p})),n.d(e,"regressionLog",(function(){return y})),n.d(e,"regressionPoly",(function(){return m})),n.d(e,"regressionPow",(function(){return x})),n.d(e,"regressionQuad",(function(){return v}));function p(){var t=function(t){return t[0]},e=function(t){return t[1]},n=.3;function o(o){for(var a=i(r(o,t,e,!0),4),s=a[0],c=a[1],u=a[2],h=a[3],p=s.length,y=Math.max(2,~~(n*p)),v=new Float64Array(p),m=new Float64Array(p),x=new Float64Array(p).fill(1),b=-1;++b<=2;){for(var O=[0,y-1],_=0;_s[S]-w?j:S,A=0,C=0,E=0,I=0,P=0,F=1/Math.abs(s[M]-w||1),T=j;T<=S;++T){var L=s[T],k=c[T],D=d(Math.abs(w-L)*F)*x[T],B=L*D;A+=D,C+=B,E+=k*D,I+=k*B,P+=L*B}var R=i(l(C/A,E/A,I/A,P/A),2),N=R[0],V=R[1];v[_]=N+V*w,m[_]=Math.abs(c[_]-v[_]),g(s,_+1,O)}if(2===b)break;var z=f(m);if(Math.abs(z)<1e-12)break;for(var G,Y,X=0;X=1?1e-12:(Y=1-G*G)*Y}return function(t,e,n,i){for(var r,o=t.length,a=[],s=0,c=0,l=[];s=t.length))for(;e>r&&t[o]-i<=i-t[r];)n[0]=++r,n[1]=o,++o}function y(){var t,e=function(t){return t[0]},n=function(t){return t[1]},r=Math.E;function s(s){var u=0,h=0,f=0,p=0,d=0,g=t?+t[0]:1/0,y=t?+t[1]:-1/0,v=Math.log(r);o(s,e,n,(function(e,n){var i=Math.log(e)/v;++u,h+=(i-h)/u,f+=(n-f)/u,p+=(i*n-p)/u,d+=(i*i-d)/u,t||(ey&&(y=e))}));var m=i(l(h,f,p,d),2),x=m[0],b=m[1],O=function(t){return b*Math.log(t)/v+x},_=c(g,y,O);return _.a=b,_.b=x,_.predict=O,_.rSquared=a(s,e,n,f,O),_}return s.domain=function(e){return arguments.length?(t=e,s):t},s.x=function(t){return arguments.length?(e=t,s):e},s.y=function(t){return arguments.length?(n=t,s):n},s.base=function(t){return arguments.length?(r=t,s):r},s}function v(){var t,e=function(t){return t[0]},n=function(t){return t[1]};function s(s){var l,u,h,f,p=i(r(s,e,n),4),d=p[0],g=p[1],y=p[2],v=p[3],m=d.length,x=0,b=0,O=0,_=0,w=0;for(l=0;lA&&(A=e))}));var C=O-x*x,E=x*C-b*b,I=(w*x-_*b)/E,P=(_*C-w*b)/E,F=-I*x,T=function(t){return I*(t-=y)*t+P*t+F+v},L=c(M,A,T);return L.a=I,L.b=P-2*I*y,L.c=F-P*y+I*y*y+v,L.predict=T,L.rSquared=a(s,e,n,j,T),L}return s.domain=function(e){return arguments.length?(t=e,s):t},s.x=function(t){return arguments.length?(e=t,s):e},s.y=function(t){return arguments.length?(n=t,s):n},s}function m(){var t,e=function(t){return t[0]},n=function(t){return t[1]},s=3;function l(l){if(1===s){var u=h().x(e).y(n).domain(t)(l);return u.coefficients=[u.b,u.a],delete u.a,delete u.b,u}if(2===s){var f=v().x(e).y(n).domain(t)(l);return f.coefficients=[f.c,f.b,f.a],delete f.a,delete f.b,delete f.c,f}var p,d,g,y,m,x=i(r(l,e,n),4),b=x[0],O=x[1],_=x[2],w=x[3],j=b.length,S=[],M=[],A=s+1,C=0,E=0,I=t?+t[0]:1/0,P=t?+t[1]:-1/0;for(o(l,e,n,(function(e,n){++E,C+=(n-C)/E,t||(eP&&(P=e))})),p=0;pMath.abs(t[e][r])&&(r=n);for(i=e;i=e;i--)t[i][n]-=t[i][e]*t[e][n]/t[e][e]}for(n=a-1;n>=0;--n){for(o=0,i=n+1;i=0;--r)for(a=e[r],s=1,c[r]+=a,o=1;o<=r;++o)s*=(r+1-o)/o,c[r-o]+=a*Math.pow(n,o)*s;return c[0]+=i,c}(A,F,-_,w),L.predict=T,L.rSquared=a(l,e,n,C,T),L}return l.domain=function(e){return arguments.length?(t=e,l):t},l.x=function(t){return arguments.length?(e=t,l):e},l.y=function(t){return arguments.length?(n=t,l):n},l.order=function(t){return arguments.length?(s=t,l):s},l}function x(){var t,e=function(t){return t[0]},n=function(t){return t[1]};function r(r){var s=0,u=0,h=0,f=0,p=0,d=0,g=t?+t[0]:1/0,y=t?+t[1]:-1/0;o(r,e,n,(function(e,n){var i=Math.log(e),r=Math.log(n);++s,u+=(i-u)/s,h+=(r-h)/s,f+=(i*r-f)/s,p+=(i*i-p)/s,d+=(n-d)/s,t||(ey&&(y=e))}));var v=i(l(u,h,f,p),2),m=v[0],x=v[1];m=Math.exp(m);var b=function(t){return m*Math.pow(t,x)},O=c(g,y,b);return O.a=m,O.b=x,O.predict=b,O.rSquared=a(r,e,n,d,b),O}return r.domain=function(e){return arguments.length?(t=e,r):t},r.x=function(t){return arguments.length?(e=t,r):e},r.y=function(t){return arguments.length?(n=t,r):n},r}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DEFAULT_OPTIONS=void 0;var i=n(7),r=n(2);e.DEFAULT_OPTIONS=r.deepAssign({},i.Plot.getDefaultOptions(),{size:4,tooltip:{showTitle:!1,showMarkers:!1,showCrosshairs:!0,crosshairs:{type:"xy"}}})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),n(132)},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.Radar=void 0;var i=n(1),r=n(7),o=n(2),a=(n(267),n(268));n(269);var s=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="radar",e}return i.__extends(e,t),e.prototype.changeData=function(t){this.updateOption({data:t}),this.chart.changeData(t)},e.prototype.getDefaultOptions=function(){return o.deepAssign({},t.prototype.getDefaultOptions.call(this),{xAxis:{label:{offset:15},grid:{line:{type:"line"}}},yAxis:{grid:{line:{type:"circle"}}},legend:{position:"top"},tooltip:{shared:!0,showCrosshairs:!0,showMarkers:!0,crosshairs:{type:"xy",line:{style:{stroke:"#565656",lineDash:[4]}},follow:!0}}})},e.prototype.getSchemaAdaptor=function(){return a.adaptor},e}(r.Plot);e.Radar=s},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.adaptor=void 0;var i=n(1),r=n(12),o=n(18),a=n(2);function s(t){var e=t.chart,n=t.options,r=n.data,s=n.lineStyle,c=n.color,l=n.point,u=n.area;e.data(r);var h=a.deepAssign({},t,{options:{line:{style:s,color:c},point:l?i.__assign({color:c},l):l,area:u?i.__assign({color:c},u):u,label:void 0}}),f=a.deepAssign({},h,{options:{tooltip:!1}}),p=(null==l?void 0:l.state)||n.state,d=a.deepAssign({},h,{options:{tooltip:!1,state:p}});return o.line(h),o.point(d),o.area(f),t}function c(t){var e,n=t.options,i=n.xAxis,o=n.yAxis,s=n.xField,c=n.yField;return a.flow(r.scale(((e={})[s]=i,e[c]=o,e)))(t)}function l(t){var e=t.chart,n=t.options,i=n.radius,r=n.startAngle,o=n.endAngle;return e.coordinate("polar",{radius:i,startAngle:r,endAngle:o}),t}function u(t){var e=t.chart,n=t.options,i=n.xField,r=n.xAxis,o=n.yField,a=n.yAxis;return e.axis(i,r),e.axis(o,a),t}function h(t){var e=t.chart,n=t.options,r=n.label,o=n.yField,s=a.findGeometry(e,"line");if(r){var c=r.callback,l=i.__rest(r,["callback"]);s.label({fields:[o],callback:c,cfg:a.transformLabel(l)})}else s.label(!1);return t}e.adaptor=function(t){return a.flow(s,c,r.theme,l,u,r.legend,r.tooltip,h,r.interaction,r.animation,r.annotation())(t)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(9),r=n(270);i.registerAction("radar-tooltip",r.RadarTooltipAction),i.registerInteraction("radar-tooltip",{start:[{trigger:"plot:mousemove",action:"radar-tooltip:show"}],end:[{trigger:"plot:mouseleave",action:"radar-tooltip:hide"}]})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.RadarTooltipAction=e.RadarTooltipController=void 0;var i=n(1),r=n(9),o=n(0),a=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return i.__extends(e,t),Object.defineProperty(e.prototype,"name",{get:function(){return"radar-tooltip"},enumerable:!1,configurable:!0}),e.prototype.getTooltipItems=function(e){var n=this.getTooltipCfg(),a=n.shared,s=n.title,c=t.prototype.getTooltipItems.call(this,e);if(c.length>0){var l=this.view.geometries[0],u=l.dataArray,h=c[0].name,f=[];return u.forEach((function(t){t.forEach((function(t){var e=r.Util.getTooltipItems(t,l)[0];if(!a&&e&&e.name===h){var n=o.isNil(s)?h:s;f.push(i.__assign(i.__assign({},e),{name:e.title,title:n}))}else if(a&&e){n=o.isNil(s)?e.name||h:s;f.push(i.__assign(i.__assign({},e),{name:e.title,title:n}))}}))})),f}return[]},e}(r.TooltipController);e.RadarTooltipController=a,r.registerComponentController("radar-tooltip",a);var s=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return i.__extends(e,t),e.prototype.init=function(){this.context.view.removeInteraction("tooltip")},e.prototype.show=function(){var t=this.context.event;this.getTooltipController().showTooltip({x:t.x,y:t.y})},e.prototype.hide=function(){this.getTooltipController().hideTooltip()},e.prototype.getTooltipController=function(){return this.context.view.getController("radar-tooltip")},e}(r.Action);e.RadarTooltipAction=s},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DualAxes=void 0;var i=n(1),r=n(7),o=n(2),a=(n(80),n(272)),s=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="dual-axes",e}return i.__extends(e,t),e.prototype.getDefaultOptions=function(){return o.deepAssign({},t.prototype.getDefaultOptions.call(this),{yAxis:[],syncViewPadding:!0})},e.prototype.getSchemaAdaptor=function(){return a.adaptor},e}(r.Plot);e.DualAxes=s},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.adaptor=e.slider=e.legend=e.limitInPlot=e.animation=e.theme=e.annotation=e.interaction=e.tooltip=e.axis=e.meta=e.color=e.transformOptions=void 0;var i=n(1),r=n(0),o=n(12),a=n(46),s=n(2),c=n(104),l=n(81),u=n(273),h=n(274),f=n(275),p=n(80),d=n(133);function g(t){var e,n=t.options,i=n.geometryOptions,o=void 0===i?[]:i,a=n.xField,c=n.yField,u=r.every(o,(function(t){var e=t.geometry;return e===p.DualAxesGeometry.Line||void 0===e}));return s.deepAssign({},{options:{geometryOptions:[],meta:(e={},e[a]={type:"cat",sync:!0,range:u?[0,1]:void 0},e),tooltip:{showMarkers:u,showCrosshairs:u,shared:!0,crosshairs:{type:"x"}},interactions:u?[{type:"legend-visible-filter"}]:[{type:"legend-visible-filter"},{type:"active-region"}],legend:{position:"top-left"}}},t,{options:{yAxis:l.transformObjectToArray(c,n.yAxis),geometryOptions:[l.getGeometryOption(a,c[0],o[0]),l.getGeometryOption(a,c[1],o[1])],annotations:l.transformObjectToArray(c,n.annotations)}})}function y(t){var e,n,i=t.chart,r=t.options.geometryOptions,o={line:0,column:1};return[{type:null===(e=r[0])||void 0===e?void 0:e.geometry,id:d.LEFT_AXES_VIEW},{type:null===(n=r[1])||void 0===n?void 0:n.geometry,id:d.RIGHT_AXES_VIEW}].sort((function(t,e){return-o[t.type]+o[e.type]})).forEach((function(t){return i.createView({id:t.id})})),t}function v(t){var e=t.chart,n=t.options,r=n.xField,o=n.yField,s=n.geometryOptions,u=n.data,f=n.tooltip;return[i.__assign(i.__assign({},s[0]),{id:d.LEFT_AXES_VIEW,data:u[0],yField:o[0]}),i.__assign(i.__assign({},s[1]),{id:d.RIGHT_AXES_VIEW,data:u[1],yField:o[1]})].forEach((function(t){var n=t.id,o=t.data,s=t.yField,u=l.isColumn(t)&&t.isPercent,p=u?a.percent(o,s,r,s):o,d=c.findViewById(e,n).data(p),g=u?i.__assign({formatter:function(e){return{name:e[t.seriesField]||s,value:(100*Number(e[s])).toFixed(2)+"%"}}},f):f;h.drawSingleGeometry({chart:d,options:{xField:r,yField:s,tooltip:g,geometryOption:t}})})),t}function m(t){var e,n=t.chart,i=t.options.geometryOptions,o=(null===(e=n.getTheme())||void 0===e?void 0:e.colors10)||[],a=0;return n.once("beforepaint",(function(){r.each(i,(function(t,e){var i=c.findViewById(n,0===e?d.LEFT_AXES_VIEW:d.RIGHT_AXES_VIEW);if(!t.color){var s=i.getGroupScales(),l=r.get(s,[0,"values","length"],1),u=o.slice(a,a+l).concat(0===e?[]:o);i.geometries.forEach((function(e){t.seriesField?e.color(t.seriesField,u):e.color(u[0])})),a+=l}})),n.render(!0)})),t}function x(t){var e,n,i=t.chart,r=t.options,a=r.xAxis,l=r.yAxis,u=r.xField,h=r.yField;return o.scale(((e={})[u]=a,e[h[0]]=l[0],e))(s.deepAssign({},t,{chart:c.findViewById(i,d.LEFT_AXES_VIEW)})),o.scale(((n={})[u]=a,n[h[1]]=l[1],n))(s.deepAssign({},t,{chart:c.findViewById(i,d.RIGHT_AXES_VIEW)})),t}function b(t){var e=t.chart,n=t.options,i=c.findViewById(e,d.LEFT_AXES_VIEW),r=c.findViewById(e,d.RIGHT_AXES_VIEW),o=n.xField,a=n.yField,s=n.xAxis,u=n.yAxis;return e.axis(o,!1),e.axis(a[0],!1),e.axis(a[1],!1),i.axis(o,s),i.axis(a[0],l.getYAxisWithDefault(u[0],p.AxisType.Left)),r.axis(o,!1),r.axis(a[1],l.getYAxisWithDefault(u[1],p.AxisType.Right)),t}function O(t){var e=t.chart,n=t.options.tooltip,i=c.findViewById(e,d.LEFT_AXES_VIEW),r=c.findViewById(e,d.RIGHT_AXES_VIEW);return e.tooltip(n),i.tooltip({shared:!0}),r.tooltip({shared:!0}),t}function _(t){var e=t.chart;return o.interaction(s.deepAssign({},t,{chart:c.findViewById(e,d.LEFT_AXES_VIEW)})),o.interaction(s.deepAssign({},t,{chart:c.findViewById(e,d.RIGHT_AXES_VIEW)})),t}function w(t){var e=t.chart,n=t.options.annotations,i=r.get(n,[0]),a=r.get(n,[1]);return o.annotation(i)(s.deepAssign({},t,{chart:c.findViewById(e,d.LEFT_AXES_VIEW),options:{annotations:i}})),o.annotation(a)(s.deepAssign({},t,{chart:c.findViewById(e,d.RIGHT_AXES_VIEW),options:{annotations:a}})),t}function j(t){var e=t.chart;return o.theme(s.deepAssign({},t,{chart:c.findViewById(e,d.LEFT_AXES_VIEW)})),o.theme(s.deepAssign({},t,{chart:c.findViewById(e,d.RIGHT_AXES_VIEW)})),o.theme(t),t}function S(t){var e=t.chart;return o.animation(s.deepAssign({},t,{chart:c.findViewById(e,d.LEFT_AXES_VIEW)})),o.animation(s.deepAssign({},t,{chart:c.findViewById(e,d.RIGHT_AXES_VIEW)})),t}function M(t){var e=t.chart,n=t.options.yAxis;return o.limitInPlot(s.deepAssign({},t,{chart:c.findViewById(e,d.LEFT_AXES_VIEW),options:{yAxis:n[0]}})),o.limitInPlot(s.deepAssign({},t,{chart:c.findViewById(e,d.RIGHT_AXES_VIEW),options:{yAxis:n[1]}})),t}function A(t){var e=t.chart,n=t.options,i=n.legend,o=n.geometryOptions,a=n.yField,l=n.data,h=c.findViewById(e,d.LEFT_AXES_VIEW),f=c.findViewById(e,d.RIGHT_AXES_VIEW);if(!1===i)e.legend(!1);else if(r.isObject(i)&&!0===i.custom)e.legend(i);else{var p=r.get(o,[0,"legend"],i),g=r.get(o,[1,"legend"],i);e.once("beforepaint",(function(){var t=l[0].length?u.getViewLegendItems({view:h,geometryOption:o[0],yField:a[0],legend:p}):[],n=l[1].length?u.getViewLegendItems({view:f,geometryOption:o[1],yField:a[1],legend:g}):[];e.legend(s.deepAssign({},i,{custom:!0,items:t.concat(n)}))})),o[0].seriesField&&h.legend(o[0].seriesField,p),o[1].seriesField&&f.legend(o[1].seriesField,g),e.on("legend-item:click",(function(t){var n=r.get(t,"gEvent.delegateObject",{});if(n&&n.item){var i=n.item,o=i.value,s=i.isGeometry,l=i.viewId;if(s){if(r.findIndex(a,(function(t){return t===o}))>-1){var u=r.get(c.findViewById(e,l),"geometries");r.each(u,(function(t){t.changeVisible(!n.item.unchecked)}))}}else{var h=r.get(e.getController("legend"),"option.items",[]);r.each(e.views,(function(t){var n=t.getGroupScales();r.each(n,(function(e){e.values&&e.values.indexOf(o)>-1&&t.filter(e.field,(function(t){return!r.find(h,(function(e){return e.value===t})).unchecked}))})),e.render(!0)}))}}}))}return t}function C(t){var e=t.chart,n=t.options.slider,i=c.findViewById(e,d.LEFT_AXES_VIEW),o=c.findViewById(e,d.RIGHT_AXES_VIEW);return n&&(i.option("slider",n),i.on("slider:valuechanged",(function(t){var e=t.event,n=e.value,i=e.originValue;r.isEqual(n,i)||f.doSliderFilter(o,n)})),e.once("afterpaint",(function(){if(!r.isBoolean(n)){var t=n.start,e=n.end;(t||e)&&f.doSliderFilter(o,[t,e])}}))),t}e.transformOptions=g,e.color=m,e.meta=x,e.axis=b,e.tooltip=O,e.interaction=_,e.annotation=w,e.theme=j,e.animation=S,e.limitInPlot=M,e.legend=A,e.slider=C,e.adaptor=function(t){return s.flow(g,y,j,v,x,b,M,O,_,w,S,m,A,C)(t)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getViewLegendItems=void 0;var i=n(0),r=n(9),o=n(2),a=n(81);e.getViewLegendItems=function(t){var e=t.view,n=t.geometryOption,s=t.yField,c=t.legend,l=i.get(c,"marker"),u=o.findGeometry(e,a.isLine(n)?"line":"interval");if(!n.seriesField){var h=i.get(e,"options.scales."+s+".alias")||s,f=u.getAttribute("color"),p=e.getTheme().defaultColor;return f&&(p=r.Util.getMappingValue(f,h,i.get(f,["values",0],p))),[{value:s,name:h,marker:(i.isFunction(l)?l:!i.isEmpty(l)&&o.deepAssign({},{style:{stroke:p,fill:p}},l))||(a.isLine(n)?{symbol:function(t,e,n){return[["M",t-n,e],["L",t+n,e]]},style:{lineWidth:2,r:6,stroke:p}}:{symbol:"square",style:{fill:p}}),isGeometry:!0,viewId:e.id}]}var d=u.getGroupAttributes();return i.reduce(d,(function(t,n){var i=r.Util.getLegendItems(e,u,n,e.getTheme(),l);return t.concat(i)}),[])}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.drawSingleGeometry=void 0;var i=n(1),r=n(0),o=n(18),a=n(2),s=n(55),c=n(81);e.drawSingleGeometry=function(t){var e=t.options,n=t.chart,l=e.geometryOption,u=l.isStack,h=l.color,f=l.seriesField,p=l.groupField,d=l.isGroup,g=["xField","yField"];if(c.isLine(l)){o.line(a.deepAssign({},t,{options:i.__assign(i.__assign(i.__assign({},a.pick(e,g)),l),{line:{color:l.color,style:l.lineStyle}})})),o.point(a.deepAssign({},t,{options:i.__assign(i.__assign(i.__assign({},a.pick(e,g)),l),{point:l.point&&i.__assign({color:h,shape:"circle"},l.point)})}));var y=[];d&&y.push({type:"dodge",dodgeBy:p||f,customOffset:0}),u&&y.push({type:"stack"}),y.length&&r.each(n.geometries,(function(t){t.adjust(y)}))}return c.isColumn(l)&&s.adaptor(a.deepAssign({},t,{options:i.__assign(i.__assign(i.__assign({},a.pick(e,g)),l),{widthRatio:l.columnWidthRatio,interval:i.__assign(i.__assign({},a.pick(l,["color"])),{style:l.columnStyle})})})),t}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.doSliderFilter=void 0;var i=n(0),r=n(2);e.doSliderFilter=function(t,e){var n=e[0],o=e[1],a=t.getOptions().data,s=t.getXScale(),c=i.size(a);if(s&&c){var l=i.valuesOfKey(a,s.field),u=l,h=i.size(u),f=Math.floor(n*(h-1)),p=Math.floor(o*(h-1));t.filter(s.field,(function(t){var e=u.indexOf(t);return!(e>-1)||r.isBetween(e,f,p)})),t.getRootView().render(!0)}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DEFAULT_OPTIONS=e.DEFAULT_TOOLTIP_OPTIONS=void 0;var i=n(1),r=n(0);e.DEFAULT_TOOLTIP_OPTIONS={showTitle:!1,shared:!0,showMarkers:!1,customContent:function(t,e){return""+r.get(e,[0,"data","y"],0)},containerTpl:'
    ',itemTpl:"{value}",domStyles:{"g2-tooltip":{padding:"2px 4px",fontSize:"10px"}}},e.DEFAULT_OPTIONS={appendPadding:2,tooltip:i.__assign({},e.DEFAULT_TOOLTIP_OPTIONS),animation:{}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DEFAULT_OPTIONS=void 0;var i=n(1),r=n(56);e.DEFAULT_OPTIONS={appendPadding:2,tooltip:i.__assign({},r.DEFAULT_TOOLTIP_OPTIONS),color:"l(90) 0:#E5EDFE 1:#ffffff",areaStyle:{fillOpacity:.6},line:{size:1,color:"#5B8FF9"},animation:{}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DEFAULT_OPTIONS=void 0,e.DEFAULT_OPTIONS={percent:.2,innerRadius:.8,radius:.98,color:["#FAAD14","#E8EDF3"],statistic:{title:!1,content:{style:{fontSize:"14px",fontWeight:300,fill:"#4D4D4D",textAlign:"center",textBaseline:"middle"}}},animation:{}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.Heatmap=void 0;var i=n(1),r=n(7),o=(n(286),n(287)),a=n(288);n(289),n(290);var s=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="heatmap",e}return i.__extends(e,t),e.getDefaultOptions=function(){return a.DEFAULT_OPTIONS},e.prototype.getSchemaAdaptor=function(){return o.adaptor},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e}(r.Plot);e.Heatmap=s},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.adaptor=void 0;var i=n(1),r=n(0),o=n(2),a=n(2),s=n(12),c=n(27),l=n(31);function u(t){var e=t.chart,n=t.options,i=n.data,a=n.type,s=n.xField,u=n.yField,h=n.colorField,f=n.sizeField,p=n.sizeRatio,d=n.shape,g=n.color,y=n.tooltip,v=n.heatmapStyle;e.data(i);var m="polygon";"density"===a&&(m="heatmap");var x=l.getTooltipMapping(y,[s,u,h]),b=x.fields,O=x.formatter,_=1;return(p||0===p)&&(d||f?p<0||p>1?console.warn("sizeRatio is not in effect: It must be a number in [0,1]"):_=p:console.warn("sizeRatio is not in effect: Must define shape or sizeField first")),c.geometry(o.deepAssign({},t,{options:{type:m,colorField:h,tooltipFields:b,shapeField:f||"",label:void 0,mapping:{tooltip:O,shape:d&&(f?function(t){var e=i.map((function(t){return t[f]})),n=Math.min.apply(Math,e),o=Math.max.apply(Math,e);return[d,(r.get(t,f)-n)/(o-n),_]}:function(){return[d,1,_]}),color:g||h&&e.getTheme().sequenceColors.join("-"),style:v}}})),t}function h(t){var e,n=t.options,i=n.xAxis,r=n.yAxis,o=n.xField,c=n.yField;return a.flow(s.scale(((e={})[o]=i,e[c]=r,e)))(t)}function f(t){var e=t.chart,n=t.options,i=n.xAxis,r=n.yAxis,o=n.xField,a=n.yField;return!1===i?e.axis(o,!1):e.axis(o,i),!1===r?e.axis(a,!1):e.axis(a,r),t}function p(t){var e=t.chart,n=t.options,i=n.legend,r=n.colorField,o=n.sizeField,a=n.sizeLegend,s=!1!==i;return r&&e.legend(r,!!s&&i),o&&e.legend(o,void 0===a?i:a),s||a||e.legend(!1),t}function d(t){var e=t.chart,n=t.options,r=n.label,s=n.colorField,c=n.type,l=o.findGeometry(e,"density"===c?"heatmap":"polygon");if(r){if(s){var u=r.callback,h=i.__rest(r,["callback"]);l.label({fields:[s],callback:u,cfg:a.transformLabel(h)})}}else l.label(!1);return t}function g(t){var e=t.chart,n=t.options,i=n.coordinate,r=n.reflect;return i&&e.coordinate({type:i.type||"rect",cfg:i.cfg}),r&&e.coordinate().reflect(r),t}e.adaptor=function(t){return a.flow(s.theme,s.pattern("heatmapStyle"),h,g,u,f,p,s.tooltip,d,s.annotation(),s.interaction,s.animation,s.state)(t)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DEFAULT_OPTIONS=void 0;var i=n(7),r=n(2);e.DEFAULT_OPTIONS=r.deepAssign({},i.Plot.getDefaultOptions(),{type:"polygon",legend:!1,coordinate:{type:"rect"},xAxis:{tickLine:null,line:null,grid:{alignTick:!1,line:{style:{lineWidth:1,lineDash:null,stroke:"#f0f0f0"}}}},yAxis:{grid:{alignTick:!1,line:{style:{lineWidth:1,lineDash:null,stroke:"#f0f0f0"}}}}})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(1);n(9).registerShape("polygon","circle",{draw:function(t,e){var n,r,o=t.x,a=t.y,s=this.parsePoints(t.points),c=Math.abs(s[2].x-s[1].x),l=Math.abs(s[1].y-s[0].y),u=Math.min(c,l)/2,h=Number(t.shape[1]),f=Number(t.shape[2]),p=u*Math.sqrt(f)*Math.sqrt(h),d=(null===(n=t.style)||void 0===n?void 0:n.fill)||t.color||(null===(r=t.defaultStyle)||void 0===r?void 0:r.fill);return e.addShape("circle",{attrs:i.__assign(i.__assign(i.__assign({x:o,y:a,r:p},t.defaultStyle),t.style),{fill:d})})}})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(1);n(9).registerShape("polygon","square",{draw:function(t,e){var n,r,o=t.x,a=t.y,s=this.parsePoints(t.points),c=Math.abs(s[2].x-s[1].x),l=Math.abs(s[1].y-s[0].y),u=Math.min(c,l),h=Number(t.shape[1]),f=Number(t.shape[2]),p=u*Math.sqrt(f)*Math.sqrt(h),d=(null===(n=t.style)||void 0===n?void 0:n.fill)||t.color||(null===(r=t.defaultStyle)||void 0===r?void 0:r.fill);return e.addShape("rect",{attrs:i.__assign(i.__assign(i.__assign({x:o-p/2,y:a-p/2,width:p,height:p},t.defaultStyle),t.style),{fill:d})})}})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.Box=void 0;var i=n(1),r=n(7),o=(n(292),n(293)),a=n(147),s=n(84),c=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="box",e}return i.__extends(e,t),e.getDefaultOptions=function(){return s.DEFAULT_OPTIONS},e.prototype.changeData=function(t){this.updateOption({data:t});var e=this.options.yField,n=this.chart.views.find((function(t){return t.id===s.OUTLIERS_VIEW_ID}));n&&n.data(t),this.chart.changeData(a.transformData(t,e))},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return o.adaptor},e}(r.Plot);e.Box=c},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.adaptor=e.legend=void 0;var i=n(1),r=n(0),o=n(12),a=n(18),s=n(2),c=n(37),l=n(84),u=n(147);function h(t){var e=t.chart,n=t.options,i=n.xField,o=n.yField,c=n.groupField,h=n.color,f=n.tooltip,p=n.boxStyle;e.data(u.transformData(n.data,o));var d=r.isArray(o)?l.BOX_RANGE:o,g=o?r.isArray(o)?o:[o]:[],y=f;!1!==y&&(y=s.deepAssign({},{fields:r.isArray(o)?o:[]},y));var v=a.schema(s.deepAssign({},t,{options:{xField:i,yField:d,seriesField:c,tooltip:y,rawFields:g,label:!1,schema:{shape:"box",color:h,style:p}}})).ext;return c&&v.geometry.adjust("dodge"),t}function f(t){var e=t.chart,n=t.options,r=n.xField,o=n.data,s=n.outliersField,c=n.outliersStyle,u=n.padding,h=n.label;if(!s)return t;var f=e.createView({padding:u,id:l.OUTLIERS_VIEW_ID}),p=o.reduce((function(t,e){return e[s].forEach((function(n){var r;return t.push(i.__assign(i.__assign({},e),((r={})[s]=n,r)))})),t}),[]);return f.data(p),a.point({chart:f,options:{xField:r,yField:s,point:{shape:"circle",style:c},label:h}}),f.axis(!1),t}function p(t){var e,n,i=t.chart,r=t.options,o=r.meta,a=r.xAxis,u=r.yAxis,h=r.xField,f=r.yField,p=r.outliersField,d=Array.isArray(f)?l.BOX_RANGE:f,g={};if(p){var y=l.BOX_SYNC_NAME;(e={})[p]={sync:y,nice:!0},e[d]={sync:y,nice:!0},g=e}var v=s.deepAssign(g,o,((n={})[h]=s.pick(a,c.AXIS_META_CONFIG_KEYS),n[d]=s.pick(u,c.AXIS_META_CONFIG_KEYS),n));return i.scale(v),t}function d(t){var e=t.chart,n=t.options,i=n.xAxis,r=n.yAxis,o=n.xField,a=n.yField,s=Array.isArray(a)?l.BOX_RANGE:a;return!1===i?e.axis(o,!1):e.axis(o,i),!1===r?e.axis(l.BOX_RANGE,!1):e.axis(s,r),t}function g(t){var e=t.chart,n=t.options,i=n.legend,r=n.groupField;return r?i?e.legend(r,i):e.legend(r,{position:"bottom"}):e.legend(!1),t}e.legend=g,e.adaptor=function(t){return s.flow(h,f,p,d,g,o.tooltip,o.interaction,o.animation,o.theme)(t)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.Violin=void 0;var i=n(1),r=n(7),o=(n(295),n(296)),a=n(149),s=n(148),c=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="violin",e}return i.__extends(e,t),e.getDefaultOptions=function(){return a.DEFAULT_OPTIONS},e.prototype.changeData=function(t){this.updateOption({data:t}),this.chart.changeData(s.transformViolinData(this.options))},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return o.adaptor},e}(r.Plot);e.Violin=c},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},function(t,e,n){"use strict";function i(t){return(i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}Object.defineProperty(e,"__esModule",{value:!0}),e.adaptor=e.animation=void 0;var r=n(1),o=n(0),a=n(12),s=n(18),c=n(2),l=n(37),u=n(148),h=n(149),f=["low","high","q1","q3","median"],p=[{type:"dodge",marginRatio:1/32}];function d(t){var e=t.chart,n=t.options;return e.data(u.transformViolinData(n)),t}function g(t){var e=t.chart,n=t.options,i=n.seriesField,o=n.color,a=n.shape,c=void 0===a?"violin":a,l=n.violinStyle,u=n.tooltip,d=n.state,g=e.createView({id:h.VIOLIN_VIEW_ID});return s.violin({chart:g,options:{xField:h.X_FIELD,yField:h.VIOLIN_Y_FIELD,seriesField:i||h.X_FIELD,sizeField:h.VIOLIN_SIZE_FIELD,tooltip:r.__assign({fields:f},u),violin:{style:l,color:o,shape:c},state:d}}),g.geometries[0].adjust(p),t}function y(t){var e=t.chart,n=t.options,o=n.seriesField,a=n.color,c=n.tooltip,l=n.box;if(!1===l)return t;var u=e.createView({id:h.MIN_MAX_VIEW_ID});s.interval({chart:u,options:{xField:h.X_FIELD,yField:h.MIN_MAX_FIELD,seriesField:o||h.X_FIELD,tooltip:r.__assign({fields:f},c),state:"object"===i(l)?l.state:{},interval:{color:a,size:1,style:{lineWidth:0}}}}),u.geometries[0].adjust(p);var d=e.createView({id:h.QUANTILE_VIEW_ID});s.interval({chart:d,options:{xField:h.X_FIELD,yField:h.QUANTILE_FIELD,seriesField:o||h.X_FIELD,tooltip:r.__assign({fields:f},c),state:"object"===i(l)?l.state:{},interval:{color:a,size:8,style:{fillOpacity:1}}}}),d.geometries[0].adjust(p);var g=e.createView({id:h.MEDIAN_VIEW_ID});return s.point({chart:g,options:{xField:h.X_FIELD,yField:h.MEDIAN_FIELD,seriesField:o||h.X_FIELD,tooltip:r.__assign({fields:f},c),state:"object"===i(l)?l.state:{},point:{color:a,size:1,style:{fill:"white",lineWidth:0}}}}),g.geometries[0].adjust(p),d.axis(!1),u.axis(!1),g.axis(!1),g.legend(!1),u.legend(!1),d.legend(!1),t}function v(t){var e,n=t.chart,i=t.options,o=i.meta,a=i.xAxis,s=i.yAxis,u=c.deepAssign({},o,((e={})[h.X_FIELD]=r.__assign(r.__assign({sync:!0},c.pick(a,l.AXIS_META_CONFIG_KEYS)),{type:"cat"}),e[h.VIOLIN_Y_FIELD]=r.__assign({sync:!0},c.pick(s,l.AXIS_META_CONFIG_KEYS)),e[h.MIN_MAX_FIELD]=r.__assign({sync:h.VIOLIN_Y_FIELD},c.pick(s,l.AXIS_META_CONFIG_KEYS)),e[h.QUANTILE_FIELD]=r.__assign({sync:h.VIOLIN_Y_FIELD},c.pick(s,l.AXIS_META_CONFIG_KEYS)),e[h.MEDIAN_FIELD]=r.__assign({sync:h.VIOLIN_Y_FIELD},c.pick(s,l.AXIS_META_CONFIG_KEYS)),e));return n.scale(u),t}function m(t){var e=t.chart,n=t.options,i=n.xAxis,r=n.yAxis,o=c.findViewById(e,h.VIOLIN_VIEW_ID);return!1===i?o.axis(h.X_FIELD,!1):o.axis(h.X_FIELD,i),!1===r?o.axis(h.VIOLIN_Y_FIELD,!1):o.axis(h.VIOLIN_Y_FIELD,r),e.axis(!1),t}function x(t){var e=t.chart,n=t.options,i=n.legend,r=n.seriesField,a=n.shape;if(!1===i)e.legend(!1);else{var s=r||h.X_FIELD,c=o.omit(i,["selected"]);a&&a.startsWith("hollow")||o.get(c,["marker","style","lineWidth"])||o.set(c,["marker","style","lineWidth"],0),e.legend(s,c),o.get(i,"selected")&&o.each(e.views,(function(t){return t.legend(s,i)}))}return t}function b(t){var e=t.chart,n=c.findViewById(e,h.VIOLIN_VIEW_ID);return a.annotation()(r.__assign(r.__assign({},t),{chart:n})),t}function O(t){var e=t.chart,n=t.options.animation;return o.each(e.views,(function(t){"boolean"==typeof n?t.animate(n):t.animate(!0),o.each(t.geometries,(function(t){t.animate(n)}))})),t}e.animation=O,e.adaptor=function(t){return c.flow(a.theme,d,g,y,v,a.tooltip,m,x,a.interaction,b,O)(t)}},function(t,e,n){"use strict";var i=Math.log(2),r=t.exports,o=n(298);function a(t){return 1-Math.abs(t)}t.exports.getUnifiedMinMax=function(t,e){return r.getUnifiedMinMaxMulti([t],e)},t.exports.getUnifiedMinMaxMulti=function(t,e){e=e||{};var n=!1,i=!1,r=o.isNumber(e.width)?e.width:2,a=o.isNumber(e.size)?e.size:50,s=o.isNumber(e.min)?e.min:(n=!0,o.findMinMulti(t)),c=o.isNumber(e.max)?e.max:(i=!0,o.findMaxMulti(t)),l=(c-s)/(a-1);return n&&(s-=2*r*l),i&&(c+=2*r*l),{min:s,max:c}},t.exports.create=function(t,e){if(e=e||{},!t||0===t.length)return[];var n=o.isNumber(e.size)?e.size:50,i=o.isNumber(e.width)?e.width:2,s=r.getUnifiedMinMax(t,{size:n,width:i,min:e.min,max:e.max}),c=s.min,l=s.max-c,u=l/(n-1);if(0===l)return[{x:c,y:1}];for(var h=[],f=0;f=h.length)){var n=Math.max(e-i,0),r=e,a=Math.min(e+i,h.length-1),s=n-(e-i),l=e+i-a,f=p[-i-1+s]||0,v=p[-i-1+l]||0,m=d/(d-f-v);s>0&&(y+=m*(s-1)*g);var x=Math.max(0,e-i+1);o.inside(0,h.length-1,x)&&(h[x].y+=1*m*g),o.inside(0,h.length-1,r+1)&&(h[r+1].y-=2*m*g),o.inside(0,h.length-1,a+1)&&(h[a+1].y+=1*m*g)}}));var v=y,m=0,x=0;return h.forEach((function(t){m+=t.y,v+=m,t.y=v,x+=v})),x>0&&h.forEach((function(t){t.y/=x})),h},t.exports.getExpectedValueFromPdf=function(t){if(t&&0!==t.length){var e=0;return t.forEach((function(t){e+=t.x*t.y})),e}},t.exports.getXWithLeftTailArea=function(t,e){if(t&&0!==t.length){for(var n=0,i=0,r=0;r=e));r++);return t[i].x}},t.exports.getPerplexity=function(t){if(t&&0!==t.length){var e=0;return t.forEach((function(t){var n=Math.log(t.y);isFinite(n)&&(e+=t.y*n)})),e=-e/i,Math.pow(2,e)}}},function(t,e,n){"use strict";var i=t.exports;t.exports.isNumber=function(t){return"number"==typeof t},t.exports.findMin=function(t){if(0===t.length)return 1/0;for(var e=t[0],n=1;n1)throw new Error("quantiles must be between 0 and 1");return 1===e?t[t.length-1]:0===e?t[0]:n%1!=0?t[Math.ceil(n)-1]:t.length%2==0?(t[n-1]+t[n])/2:t[n]}function r(t,e,n){var i=t[e];t[e]=t[n],t[n]=i}function o(t,e,n,i){for(n=n||0,i=i||t.length-1;i>n;){if(i-n>600){var a=i-n+1,s=e-n+1,c=Math.log(a),l=.5*Math.exp(2*c/3),u=.5*Math.sqrt(c*l*(a-l)/a);s-a/2<0&&(u*=-1),o(t,e,Math.max(n,Math.floor(e-s*l/a+u)),Math.min(i,Math.floor(e+(a-s)*l/a+u)))}var h=t[e],f=n,p=i;for(r(t,n,e),t[i]>h&&r(t,n,i);fh;)p--}t[n]===h?r(t,n,p):r(t,++p,i),p<=e&&(n=p+1),e<=p&&(i=p-1)}}function a(t,e,n,i){e%1==0?o(t,e,n,i):(o(t,e=Math.floor(e),n,i),o(t,e+1,e+1,i))}function s(t,e){return t-e}function c(t,e){var n=t*e;return 1===e?t-1:0===e?0:n%1!=0?Math.ceil(n)-1:t%2==0?n-.5:n}Object.defineProperty(e,"__esModule",{value:!0}),e.quantile=e.quickselect=e.swap=e.quantileSorted=void 0,e.quantileSorted=i,e.swap=r,e.quickselect=o,e.quantile=function(t,e){var n=t.slice();if(Array.isArray(e)){!function(t,e){for(var n=[0],i=0;ie?e:t},lighten:function(t,e){return t>e?t:e},dodge:function(t,e){return 255===t||(t=e/255*255/(1-t/255))>255?255:t},burn:function(t,e){return 255===e?255:0===t?0:255*(1-Math.min(1,(1-e/255)/(t/255)))}};function o(t){var e,n=t.replace("/s+/g","");return"string"!=typeof n||n.startsWith("rgba")||n.startsWith("#")?(n.startsWith("rgba")&&(e=n.replace("rgba(","").replace(")","").split(",")),n.startsWith("#")&&(e=i.default.rgb2arr(n).concat([1])),e.map((function(t,e){return 3===e?Number(t):0|t}))):i.default.rgb2arr(i.default.toRGB(n)).concat([1])}e.innerBlend=function(t){if(!r[t])throw new Error("unknown blend mode "+t);return r[t]},e.blend=function(t,n,i){void 0===i&&(i="normal");var r,a=(r=e.innerBlend(i),function(t,e){var n=[];return n[0]=r(t[0],e[0]),n[1]=r(t[1],e[1]),n[2]=r(t[2],e[2]),n})(o(t),o(n)),s=o(t),c=s[0],l=s[1],u=s[2],h=s[3],f=o(n),p=f[0],d=f[1],g=f[2],y=f[3],v=Number((h+y*(1-h)).toFixed(2));return"rgba("+Math.round((h*(1-y)*(c/255)+h*y*(a[0]/255)+(1-h)*y*(p/255))/v*255)+", "+Math.round((h*(1-y)*(l/255)+h*y*(a[1]/255)+(1-h)*y*(d/255))/v*255)+", "+Math.round((h*(1-y)*(u/255)+h*y*(a[2]/255)+(1-h)*y*(g/255))/v*255)+", "+v+")"},e.colorToArr=o},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.scaleSolution=e.normalizeSolution=e.disjointCluster=e.lossFunction=e.greedyLayout=e.constrainedMDSLayout=e.bestInitialLayout=e.getDistanceMatrices=e.distanceFromIntersectArea=e.venn=void 0;var i=n(150),r=n(151);e.venn=function(t,e){(e=e||{}).maxIterations=e.maxIterations||500;var n,r=e.initialLayout||s,o=e.lossFunction||u,a=r(t=function(t){t=t.slice();var e,n,i,r,o=[],a={};for(e=0;ee?1:-1})),e=0;e=Math.min(e[i].size,e[s].size)?l=1:t.size<=1e-10&&(l=-1),a[i][s]=a[s][i]=l})),{distances:r,constraints:a}}function s(t,e){var n=l(t,e),i=e.lossFunction||u;if(t.length>=8){var r=c(t,e);i(r,t)+1e-80&&d<=h||f<0&&d>=h||(o+=2*g*g,e[2*r]+=4*g*(a-l),e[2*r+1]+=4*g*(s-u),e[2*c]+=4*g*(l-a),e[2*c+1]+=4*g*(u-s))}return o}(t,e,u,h)};for(n=0;n=Math.min(a[p].size,a[d].size)&&(f=0),s[p].push({set:d,size:h.size,weight:f}),s[d].push({set:p,size:h.size,weight:f})}var g=[];for(n in s)if(s.hasOwnProperty(n)){var y=0;for(c=0;c0){var o=t[0].x,a=t[0].y;for(i=0;i1){var s=Math.atan2(t[1].x,t[1].y)-e,c=void 0,l=void 0,u=Math.cos(s),h=Math.sin(s);for(i=0;i2){for(var f=Math.atan2(t[2].x,t[2].y)-e;f<0;)f+=2*Math.PI;for(;f>2*Math.PI;)f-=2*Math.PI;if(f>Math.PI){var p=t[1].y/(1e-10+t[1].x);for(i=0;i=u&&(l=s[n],u=h)}var f=i.nelderMead((function(n){return-1*o({x:n[0],y:n[1]},t,e)}),[l.x,l.y],{maxIterations:500,minErrorDelta:1e-10}).x,p={x:f[0],y:f[1]},d=!0;for(n=0;nt[n].radius){d=!1;break}for(n=0;n0&&console.log("WARNING: area "+s+" not represented on screen")}return n},e.circlePath=s,e.circleFromPath=function(t){var e=t.split(" ");return{x:parseFloat(e[1]),y:parseFloat(e[2]),radius:-parseFloat(e[4])}},e.intersectionAreaPath=function(t){var e={};r.intersectionArea(t,e);var n=e.arcs;if(0===n.length)return"M 0 0";if(1==n.length){var i=n[0].circle;return s(i.x,i.y,i.radius)}for(var o=["\nM",n[0].p2.x,n[0].p2.y],a=0;al;o.push("\nA",l,l,0,u?1:0,1,c.p1.x,c.p1.y)}return o.join(" ")}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(1),r=n(9),o=n(28),a=n(2),s=n(57);r.registerShape("schema","venn",{draw:function(t,e){var n=t.data,c=o.parsePathString(n[s.PATH_FIELD]),l=function(t){return a.deepAssign({},t.defaultStyle,{fill:t.color},t.style)}(t),u=e.addGroup({name:"venn-shape"});u.addShape("path",{attrs:i.__assign(i.__assign({},l),{path:c}),name:"venn-path"});var h=t.customInfo,f=h.offsetX,p=h.offsetY,d=r.Util.transform(null,[["t",f,p]]);return u.setMatrix(d),u},getMarker:function(t){var e=t.color;return{symbol:"circle",style:{lineWidth:0,stroke:e,fill:e,r:4}}}})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(1),r=n(9),o=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return i.__extends(e,t),e.prototype.getLabelPoint=function(t,e,n){var i=t.data,r=i.x,o=i.y,a=t.customLabelInfo,s=a.offsetX,c=a.offsetY;return{content:t.content[n],x:r+s,y:o+c}},e}(r.GeometryLabel);r.registerGeometryLabel("venn",o)},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(9),r=n(310),o=n(311),a=n(312);i.registerAction("venn-element-active",r.VennElementActive),i.registerAction("venn-element-highlight",o.VennElementHighlight),i.registerAction("venn-element-selected",a.VennElementSelected),i.registerAction("venn-element-single-selected",a.VennElementSingleSelected),i.registerInteraction("venn-element-active",{start:[{trigger:"element:mouseenter",action:"venn-element-active:active"}],end:[{trigger:"element:mouseleave",action:"venn-element-active:reset"}]}),i.registerInteraction("venn-element-highlight",{start:[{trigger:"element:mouseenter",action:"venn-element-highlight:highlight"}],end:[{trigger:"element:mouseleave",action:"venn-element-highlight:reset"}]}),i.registerInteraction("venn-element-selected",{start:[{trigger:"element:click",action:"venn-element-selected:toggle"}],rollback:[{trigger:"dblclick",action:["venn-element-selected:reset"]}]}),i.registerInteraction("venn-element-single-selected",{start:[{trigger:"element:click",action:"venn-element-single-selected:toggle"}],rollback:[{trigger:"dblclick",action:["venn-element-single-selected:reset"]}]}),i.registerInteraction("venn-legend-active",{start:[{trigger:"legend-item:mouseenter",action:["list-active:active","venn-element-active:active"]}],end:[{trigger:"legend-item:mouseleave",action:["list-active:reset","venn-element-active:reset"]}]}),i.registerInteraction("venn-legend-highlight",{start:[{trigger:"legend-item:mouseenter",action:["legend-item-highlight:highlight","venn-element-highlight:highlight"]}],end:[{trigger:"legend-item:mouseleave",action:["legend-item-highlight:reset","venn-element-highlight:reset"]}]})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.VennElementActive=void 0;var i=n(1),r=n(9),o=n(85),a=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return i.__extends(e,t),e.prototype.syncElementsPos=function(){o.placeElementsOrdered(this.context.view)},e.prototype.active=function(){t.prototype.active.call(this),this.syncElementsPos()},e.prototype.toggle=function(){t.prototype.toggle.call(this),this.syncElementsPos()},e.prototype.reset=function(){t.prototype.reset.call(this),this.syncElementsPos()},e}(r.getActionClass("element-active"));e.VennElementActive=a},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.VennElementHighlight=void 0;var i=n(1),r=n(9),o=n(85),a=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return i.__extends(e,t),e.prototype.syncElementsPos=function(){o.placeElementsOrdered(this.context.view)},e.prototype.highlight=function(){t.prototype.highlight.call(this),this.syncElementsPos()},e.prototype.toggle=function(){t.prototype.toggle.call(this),this.syncElementsPos()},e.prototype.clear=function(){t.prototype.clear.call(this),this.syncElementsPos()},e.prototype.reset=function(){t.prototype.reset.call(this),this.syncElementsPos()},e}(r.getActionClass("element-highlight"));e.VennElementHighlight=a},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.VennElementSingleSelected=e.VennElementSelected=void 0;var i=n(1),r=n(9),o=n(85),a=r.getActionClass("element-selected"),s=r.getActionClass("element-single-selected"),c=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return i.__extends(e,t),e.prototype.syncElementsPos=function(){o.placeElementsOrdered(this.context.view)},e.prototype.selected=function(){t.prototype.selected.call(this),this.syncElementsPos()},e.prototype.toggle=function(){t.prototype.toggle.call(this),this.syncElementsPos()},e.prototype.reset=function(){t.prototype.reset.call(this),this.syncElementsPos()},e}(a);e.VennElementSelected=c;var l=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return i.__extends(e,t),e.prototype.syncElementsPos=function(){o.placeElementsOrdered(this.context.view)},e.prototype.selected=function(){t.prototype.selected.call(this),this.syncElementsPos()},e.prototype.toggle=function(){t.prototype.toggle.call(this),this.syncElementsPos()},e.prototype.reset=function(){t.prototype.reset.call(this),this.syncElementsPos()},e}(s);e.VennElementSingleSelected=l},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.Stock=void 0;var i=n(1),r=n(7),o=(n(314),n(315)),a=n(152),s=n(86),c=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="stock",e}return i.__extends(e,t),e.getDefaultOptions=function(){return s.DEFAULT_OPTIONS},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return o.adaptor},e.prototype.changeData=function(t){this.updateOption({data:t});var e=this.options.yField;this.chart.changeData(a.getStockData(t,e))},e}(r.Plot);e.Stock=c},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.adaptor=e.legend=e.tooltip=e.axis=e.meta=void 0;var i=n(12),r=n(18),o=n(2),a=n(37),s=n(86),c=n(152);function l(t){var e=t.chart,n=t.options,i=n.yField,a=n.data,l=n.risingFill,u=n.fallingFill,h=n.tooltip,f=n.stockStyle;e.data(c.getStockData(a,i));var p=h;return!1!==p&&(p=o.deepAssign({},{fields:i},p)),r.schema(o.deepAssign({},t,{options:{schema:{shape:"candle",color:[l,u],style:f},yField:s.Y_FIELD,seriesField:s.TREND_FIELD,rawFields:i,tooltip:p}})),t}function u(t){var e,n,i=t.chart,r=t.options,c=r.meta,l=r.xAxis,u=r.yAxis,h=r.xField,f=((e={})[h]={type:"timeCat",tickCount:6},e[s.TREND_FIELD]={values:[s.TREND_UP,s.TREND_DOWN]},e),p=o.deepAssign(f,c,((n={})[h]=o.pick(l,a.AXIS_META_CONFIG_KEYS),n[s.Y_FIELD]=o.pick(u,a.AXIS_META_CONFIG_KEYS),n));return i.scale(p),t}function h(t){var e=t.chart,n=t.options,i=n.xAxis,r=n.yAxis,o=n.xField;return!1===i?e.axis(o,!1):e.axis(o,i),!1===r?e.axis(s.Y_FIELD,!1):e.axis(s.Y_FIELD,r),t}function f(t){var e=t.chart,n=t.options.tooltip;return!1!==n?e.tooltip(n):e.tooltip(!1),t}function p(t){var e=t.chart,n=t.options.legend;return n?e.legend(s.TREND_FIELD,n):!1===n&&e.legend(!1),t}e.meta=u,e.axis=h,e.tooltip=f,e.legend=p,e.adaptor=function(t){o.flow(i.theme,l,u,h,f,p,i.interaction,i.animation,i.annotation(),i.slider)(t)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.compareFunnel=void 0;var i=n(0),r=n(2),o=n(31),a=n(27),s=n(48),c=n(87);function l(t){var e,n=t.chart,i=t.options,r=i.data,o=void 0===r?[]:r,a=i.yField;return n.data(o),n.scale(((e={})[a]={sync:!0},e)),t}function u(t){var e=t.chart,n=t.options,l=n.data,u=n.xField,h=n.yField,f=n.color,p=n.compareField,d=n.isTransposed,g=n.tooltip,y=n.maxSize,v=n.minSize,m=n.label,x=n.funnelStyle,b=n.state,O=n.showFacetTitle;return e.facet("mirror",{fields:[p],transpose:!d,padding:d?0:[32,0,0,0],showTitle:O,eachView:function(t,e){var n=d?e.rowIndex:e.columnIndex;d||t.coordinate({type:"rect",actions:[["transpose"],["scale",0===n?-1:1,-1]]});var O=c.transformData(e.data,l,{yField:h,maxSize:y,minSize:v});t.data(O);var _=o.getTooltipMapping(g,[u,h,p]),w=_.fields,j=_.formatter,S=d?{offset:0===n?10:-23,position:0===n?"bottom":"top"}:{offset:10,position:"left",style:{textAlign:0===n?"end":"start"}};a.geometry({chart:t,options:{type:"interval",xField:u,yField:s.FUNNEL_MAPPING_VALUE,colorField:u,tooltipFields:i.isArray(w)&&w.concat([s.FUNNEL_PERCENT,s.FUNNEL_CONVERSATION]),mapping:{shape:"funnel",tooltip:j,color:f,style:x},label:!1!==m&&r.deepAssign({},S,m),state:b}})}}),t}function h(t){var e=t.chart,n=t.options,i=n.conversionTag,o=n.isTransposed;return e.once("beforepaint",(function(){e.views.forEach((function(t,e){c.conversionTagComponent((function(t,n,a,c){var l=0===e?-1:1;return r.deepAssign({},c,{start:[n-.5,t[s.FUNNEL_MAPPING_VALUE]],end:[n-.5,t[s.FUNNEL_MAPPING_VALUE]+.05],text:o?{style:{textAlign:"start"}}:{offsetX:!1!==i?l*i.offsetX:0,style:{textAlign:0===e?"end":"start"}}})}))(r.deepAssign({},{chart:t,options:n}))}))})),t}e.compareFunnel=function(t){return r.flow(l,u,h)(t)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.facetFunnel=void 0;var i=n(2),r=n(155);function o(t){var e,n=t.chart,i=t.options,r=i.data,o=void 0===r?[]:r,a=i.yField;return n.data(o),n.scale(((e={})[a]={sync:!0},e)),t}function a(t){var e=t.chart,n=t.options,o=n.seriesField,a=n.isTransposed,s=n.showFacetTitle;return e.facet("rect",{fields:[o],padding:[a?0:32,10,0,10],showTitle:s,eachView:function(e,n){r.basicFunnel(i.deepAssign({},t,{chart:e,options:{data:n.data}}))}}),t}e.facetFunnel=function(t){return i.flow(o,a)(t)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.dynamicHeightFunnel=void 0;var i=n(1),r=n(0),o=n(2),a=n(48),s=n(27),c=n(31),l=n(87);function u(t){var e=t.chart,n=t.options,i=n.data,o=void 0===i?[]:i,s=n.yField,c=r.reduce(o,(function(t,e){return t+(e[s]||0)}),0),l=r.maxBy(o,s)[s],u=r.map(o,(function(t,e){var n=[],i=[];if(t[a.FUNNEL_TOTAL_PERCENT]=(t[s]||0)/c,e){var u=o[e-1][a.PLOYGON_X],h=o[e-1][a.PLOYGON_Y];n[0]=u[3],i[0]=h[3],n[1]=u[2],i[1]=h[2]}else n[0]=-.5,i[0]=1,n[1]=.5,i[1]=1;return i[2]=i[1]-t[a.FUNNEL_TOTAL_PERCENT],n[2]=(i[2]+1)/4,i[3]=i[2],n[3]=-n[2],t[a.PLOYGON_X]=n,t[a.PLOYGON_Y]=i,t[a.FUNNEL_PERCENT]=(t[s]||0)/l,t[a.FUNNEL_CONVERSATION]=[r.get(o,[e-1,s]),t[s]],t}));return e.data(u),t}function h(t){var e=t.chart,n=t.options,i=n.xField,o=n.yField,l=n.color,u=n.tooltip,h=n.label,f=n.funnelStyle,p=n.state,d=c.getTooltipMapping(u,[i,o]),g=d.fields,y=d.formatter;return s.geometry({chart:e,options:{type:"polygon",xField:a.PLOYGON_X,yField:a.PLOYGON_Y,colorField:i,tooltipFields:r.isArray(g)&&g.concat([a.FUNNEL_PERCENT,a.FUNNEL_CONVERSATION]),label:h,state:p,mapping:{tooltip:y,color:l,style:f}}}),t}function f(t){var e=t.chart,n=t.options.isTransposed;return e.coordinate({type:"rect",actions:n?[["transpose"],["reflect","x"]]:[]}),t}function p(t){return l.conversionTagComponent((function(t,e,n,r){return i.__assign(i.__assign({},r),{start:[t[a.PLOYGON_X][1],t[a.PLOYGON_Y][1]],end:[t[a.PLOYGON_X][1]+.05,t[a.PLOYGON_Y][1]]})}))(t),t}e.dynamicHeightFunnel=function(t){return o.flow(u,h,f,p)(t)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.Liquid=void 0;var i=n(1),r=n(9),o=n(7),a=(n(321),n(322)),s=n(323),c=n(156);n(157);var l=n(157);Object.defineProperty(e,"addWaterWave",{enumerable:!0,get:function(){return l.addWaterWave}});var u=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="liquid",e}return i.__extends(e,t),e.getDefaultOptions=function(){return s.DEFAULT_OPTIONS},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.changeData=function(t){this.chart.emit(r.VIEW_LIFE_CIRCLE.BEFORE_CHANGE_DATA,r.Event.fromData(this.chart,r.VIEW_LIFE_CIRCLE.BEFORE_CHANGE_DATA,null)),this.updateOption({percent:t}),this.chart.data(c.getLiquidData(t)),a.statistic({chart:this.chart,options:this.options},!0),this.chart.emit(r.VIEW_LIFE_CIRCLE.AFTER_CHANGE_DATA,r.Event.fromData(this.chart,r.VIEW_LIFE_CIRCLE.AFTER_CHANGE_DATA,null))},e.prototype.getSchemaAdaptor=function(){return a.adaptor},e}(o.Plot);e.Liquid=u},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.adaptor=e.statistic=void 0;var i=n(1),r=n(0),o=n(12),a=n(2),s=n(18),c=n(156);function l(t){var e=t.chart,n=t.options,i=n.percent,r=n.liquidStyle,o=n.radius,l=n.outline,u=n.wave,h=n.shape,f=n.animation;e.scale({percent:{min:0,max:1}}),e.data(c.getLiquidData(i));var p=n.color||e.getTheme().defaultColor,d=a.deepAssign({},t,{options:{xField:"type",yField:"percent",widthRatio:o,interval:{color:p,style:r,shape:"liquid-fill-gauge"}}}),g=s.interval(d).ext.geometry,y={radius:o,outline:l,wave:u,shape:h,background:e.getTheme().background,animation:f};return g.customInfo(y),e.legend(!1),e.axis(!1),e.tooltip(!1),t}function u(t,e){var n=t.chart,o=t.options,s=o.statistic,c=o.percent,l=o.meta;n.getController("annotation").clear(!0);var u=r.get(l,["percent","formatter"])||function(t){return(100*t).toFixed(2)+"%"},h=s.content;return h&&(h=a.deepAssign({},h,{content:r.isNil(h.content)?u(c):h.content})),a.renderStatistic(n,{statistic:i.__assign(i.__assign({},s),{content:h}),plotType:"liquid"},{percent:c}),e&&n.render(!0),t}e.statistic=u,e.adaptor=function(t){return a.flow(o.theme,o.pattern("liquidStyle"),l,u,o.scale({}),o.animation,o.interaction)(t)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DEFAULT_OPTIONS=void 0,e.DEFAULT_OPTIONS={radius:.9,statistic:{title:!1,content:{style:{opacity:.75,fontSize:"30px",lineHeight:"30px",textAlign:"center"}}},outline:{border:2,distance:0},wave:{count:3,length:192},shape:"circle"}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.Bullet=void 0;var i=n(1),r=n(7),o=(n(325),n(326)),a=n(158),s=n(327),c=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="bullet",e}return i.__extends(e,t),e.getDefaultOptions=function(){return s.DEFAULT_OPTIONS},e.prototype.changeData=function(t){this.updateOption({data:t});var e=a.transformData(this.options),n=e.min,i=e.max,r=e.ds;o.meta({options:this.options,ext:{data:{min:n,max:i}},chart:this.chart}),this.chart.changeData(r)},e.prototype.getSchemaAdaptor=function(){return o.adaptor},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e}(r.Plot);e.Bullet=c},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.adaptor=e.meta=void 0;var i=n(1),r=n(0),o=n(12),a=n(2),s=n(18),c=n(158);function l(t){var e=t.chart,n=t.options,o=n.bulletStyle,l=n.targetField,u=n.rangeField,h=n.measureField,f=n.xField,p=n.color,d=n.layout,g=n.size,y=n.label,v=c.transformData(n),m=v.min,x=v.max,b=v.ds;e.data(b);var O=a.deepAssign({},t,{options:{xField:f,yField:u,seriesField:"rKey",isStack:!0,label:r.get(y,"range"),interval:{color:r.get(p,"range"),style:r.get(o,"range"),size:r.get(g,"range")}}});s.interval(O),e.geometries[0].tooltip(!1);var _=a.deepAssign({},t,{options:{xField:f,yField:h,seriesField:"mKey",isStack:!0,label:r.get(y,"measure"),interval:{color:r.get(p,"measure"),style:r.get(o,"measure"),size:r.get(g,"measure")}}});s.interval(_);var w=a.deepAssign({},t,{options:{xField:f,yField:l,seriesField:"tKey",label:r.get(y,"target"),point:{color:r.get(p,"target"),style:r.get(o,"target"),size:r.isFunction(r.get(g,"target"))?function(t){return r.get(g,"target")(t)/2}:r.get(g,"target")/2,shape:"horizontal"===d?"line":"hyphen"}}});return s.point(w),"horizontal"===d&&e.coordinate().transpose(),i.__assign(i.__assign({},t),{ext:{data:{min:m,max:x}}})}function u(t){var e,n,i=t.options,r=t.ext,s=i.xAxis,c=i.yAxis,l=i.targetField,u=i.rangeField,h=i.measureField,f=i.xField,p=r.data;return a.flow(o.scale(((e={})[f]=s,e[h]=c,e),((n={})[h]={min:null==p?void 0:p.min,max:null==p?void 0:p.max,sync:!0},n[l]={sync:""+h},n[u]={sync:""+h},n)))(t)}function h(t){var e=t.chart,n=t.options,i=n.xAxis,r=n.yAxis,o=n.xField,a=n.measureField,s=n.rangeField,c=n.targetField;return e.axis(""+s,!1),e.axis(""+c,!1),!1===i?e.axis(""+o,!1):e.axis(""+o,i),!1===r?e.axis(""+a,!1):e.axis(""+a,r),t}function f(t){var e=t.chart,n=t.options.legend;return e.removeInteraction("legend-filter"),e.legend(n),e.legend("rKey",!1),e.legend("mKey",!1),e.legend("tKey",!1),t}function p(t){var e=t.chart,n=t.options,o=n.label,s=n.measureField,c=n.targetField,l=n.rangeField,u=e.geometries,h=u[0],f=u[1],p=u[2];return r.get(o,"range")?h.label(""+l,i.__assign({layout:[{type:"limit-in-plot"}]},a.transformLabel(o.range))):h.label(!1),r.get(o,"measure")?f.label(""+s,i.__assign({layout:[{type:"limit-in-plot"}]},a.transformLabel(o.measure))):f.label(!1),r.get(o,"target")?p.label(""+c,i.__assign({layout:[{type:"limit-in-plot"}]},a.transformLabel(o.target))):p.label(!1),t}e.meta=u,e.adaptor=function(t){a.flow(l,u,h,f,o.theme,p,o.tooltip,o.interaction,o.animation)(t)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DEFAULT_OPTIONS=void 0;var i=n(7),r=n(2);e.DEFAULT_OPTIONS=r.deepAssign({},i.Plot.getDefaultOptions(),{layout:"horizontal",size:{range:30,measure:20,target:20},xAxis:{tickLine:!1,line:null},bulletStyle:{range:{fillOpacity:.5}},label:{measure:{position:"right"}},tooltip:{showMarkers:!1}})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.Sunburst=void 0;var i=n(1),r=n(7),o=n(58),a=(n(329),n(330)),s=n(88);n(335);var c=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="sunburst",e}return i.__extends(e,t),e.getDefaultOptions=function(){return s.DEFAULT_OPTIONS},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return a.adaptor},e.SUNBURST_ANCESTOR_FIELD=s.SUNBURST_ANCESTOR_FIELD,e.SUNBURST_PATH_FIELD=s.SUNBURST_PATH_FIELD,e.NODE_ANCESTORS_FIELD=o.NODE_ANCESTORS_FIELD,e}(r.Plot);e.Sunburst=c},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.adaptor=e.tooltip=e.meta=e.axis=void 0;var i=n(1),r=n(0),o=n(18),a=n(12),s=n(2),c=n(44),l=n(88),u=n(331);function h(t){var e,n=t.chart,a=t.options,c=a.color,h=a.colorField,f=void 0===h?l.SUNBURST_ANCESTOR_FIELD:h,p=a.sunburstStyle,d=a.rawFields,g=void 0===d?[]:d,y=u.transformData(a);return n.data(y),p&&(e=function(t){return s.deepAssign({},{fillOpacity:Math.pow(.85,t.depth)},r.isFunction(p)?p(t):p)}),o.polygon(s.deepAssign({},t,{options:{xField:"x",yField:"y",seriesField:f,rawFields:r.uniq(i.__spreadArrays(l.RAW_FIELDS,g)),polygon:{color:c,style:e}}})),t}function f(t){return t.chart.axis(!1),t}function p(t){var e=t.chart,n=t.options.label,r=s.findGeometry(e,"polygon");if(n){var o=n.fields,a=void 0===o?["name"]:o,c=n.callback,l=i.__rest(n,["fields","callback"]);r.label({fields:a,callback:c,cfg:s.transformLabel(l)})}else r.label(!1);return t}function d(t){var e=t.chart,n=t.options,i=n.innerRadius,r=n.radius,o=n.reflect,a=e.coordinate({type:"polar",cfg:{innerRadius:i,radius:r}});return o&&a.reflect(o),t}function g(t){var e,n=t.options,i=n.hierarchyConfig,o=n.meta;return s.flow(a.scale({},((e={})[l.SUNBURST_Y_FIELD]=r.get(o,r.get(i,["field"],"value")),e)))(t)}function y(t){var e=t.chart,n=t.options.tooltip;if(!1===n)e.tooltip(!1);else{var o=n;r.get(n,"fields")||(o=s.deepAssign({},{customItems:function(t){return t.map((function(t){var n=r.get(e.getOptions(),"scales"),o=r.get(n,[l.SUNBURST_PATH_FIELD,"formatter"],(function(t){return t})),a=r.get(n,[l.SUNBURST_Y_FIELD,"formatter"],(function(t){return t}));return i.__assign(i.__assign({},t),{name:o(t.data[l.SUNBURST_PATH_FIELD]),value:a(t.data.value)})}))}},o)),e.tooltip(o)}return t}function v(t){var e=t.drilldown,n=t.interactions,r=void 0===n?[]:n;return(null==e?void 0:e.enabled)?s.deepAssign({},t,{interactions:i.__spreadArrays(r,[{type:"drill-down",cfg:{drillDownConfig:e,transformData:u.transformData}}])}):t}function m(t){var e=t.chart,n=t.options,i=n.drilldown;return a.interaction({chart:e,options:v(n)}),(null==i?void 0:i.enabled)&&(e.appendPadding=c.getAdjustAppendPadding(e.appendPadding,r.get(i,["breadCrumb","position"]))),t}e.axis=f,e.meta=g,e.tooltip=y,e.adaptor=function(t){return s.flow(a.theme,a.pattern("sunburstStyle"),h,f,g,a.legend,d,y,p,m,a.animation,a.annotation())(t)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.transformData=void 0;var i=n(1),r=n(0),o=n(65),a=n(2),s=n(332),c=n(159),l=n(88);e.transformData=function(t){var e=t.data,n=t.colorField,u=t.rawFields,h=t.hierarchyConfig,f=void 0===h?{}:h,p=f.activeDepth,d={partition:s.partition,treemap:c.treemap},g=t.seriesField,y=t.type||"partition",v=d[y](e,i.__assign(i.__assign({field:g||"value"},r.omit(f,["activeDepth"])),{type:"hierarchy."+y,as:["x","y"]})),m=[];return v.forEach((function(t){var e,r,s,c,h,d;if(0===t.depth)return null;if(p>0&&t.depth>p)return null;for(var y=t.data.name,v=i.__assign({},t);v.depth>1;)y=(null===(r=v.parent.data)||void 0===r?void 0:r.name)+" / "+y,v=v.parent;var x=i.__assign(i.__assign(i.__assign({},a.pick(t.data,i.__spreadArrays(u||[],[f.field]))),((e={})[l.SUNBURST_PATH_FIELD]=y,e[l.SUNBURST_ANCESTOR_FIELD]=v.data.name,e)),t);g&&(x[g]=t.data[g]||(null===(c=null===(s=t.parent)||void 0===s?void 0:s.data)||void 0===c?void 0:c[g])),n&&(x[n]=t.data[n]||(null===(d=null===(h=t.parent)||void 0===h?void 0:h.data)||void 0===d?void 0:d[n])),x.ext=f,x[o.HIERARCHY_DATA_TRANSFORM_PARAMS]={hierarchyConfig:f,colorField:n,rawFields:u},m.push(x)})),m}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.partition=void 0;var i=n(1).__importStar(n(93)),r=n(0),o=n(58),a={field:"value",size:[1,1],round:!1,padding:0,sort:function(t,e){return e.value-t.value},as:["x","y"],ignoreParentValue:!0};e.partition=function(t,e){var n,s=(e=r.assign({},a,e)).as;if(!r.isArray(s)||2!==s.length)throw new TypeError('Invalid as: it must be an array with 2 strings (e.g. [ "x", "y" ])!');try{n=o.getField(e)}catch(t){console.warn(t)}var c=function(t){return i.partition().size(e.size).round(e.round).padding(e.padding)(i.hierarchy(t).sum((function(t){return r.size(t.children)?e.ignoreParentValue?0:t[n]-r.reduce(t.children,(function(t,e){return t+e[n]}),0):t[n]})).sort(e.sort))}(t),l=s[0],u=s[1];return c.each((function(t){var e,n;t[l]=[t.x0,t.x1,t.x1,t.x0],t[u]=[t.y1,t.y1,t.y0,t.y0],t.name=t.name||(null===(e=t.data)||void 0===e?void 0:e.name)||(null===(n=t.data)||void 0===n?void 0:n.label),t.data.name=t.name,["x0","x1","y0","y1"].forEach((function(e){-1===s.indexOf(e)&&delete t[e]}))})),o.getAllNodes(c)}},function(t,e,n){(function(t){function e(t){return(e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}var n=function(t){"use strict";var n=Object.prototype,i=n.hasOwnProperty,r="function"==typeof Symbol?Symbol:{},o=r.iterator||"@@iterator",a=r.asyncIterator||"@@asyncIterator",s=r.toStringTag||"@@toStringTag";function c(t,e,n){return Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{c({},"")}catch(t){c=function(t,e,n){return t[e]=n}}function l(t,e,n,i){var r=e&&e.prototype instanceof f?e:f,o=Object.create(r.prototype),a=new j(i||[]);return o._invoke=function(t,e,n){var i="suspendedStart";return function(r,o){if("executing"===i)throw new Error("Generator is already running");if("completed"===i){if("throw"===r)throw o;return M()}for(n.method=r,n.arg=o;;){var a=n.delegate;if(a){var s=O(a,n);if(s){if(s===h)continue;return s}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if("suspendedStart"===i)throw i="completed",n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);i="executing";var c=u(t,e,n);if("normal"===c.type){if(i=n.done?"completed":"suspendedYield",c.arg===h)continue;return{value:c.arg,done:n.done}}"throw"===c.type&&(i="completed",n.method="throw",n.arg=c.arg)}}}(t,n,a),o}function u(t,e,n){try{return{type:"normal",arg:t.call(e,n)}}catch(t){return{type:"throw",arg:t}}}t.wrap=l;var h={};function f(){}function p(){}function d(){}var g={};c(g,o,(function(){return this}));var y=Object.getPrototypeOf,v=y&&y(y(S([])));v&&v!==n&&i.call(v,o)&&(g=v);var m=d.prototype=f.prototype=Object.create(g);function x(t){["next","throw","return"].forEach((function(e){c(t,e,(function(t){return this._invoke(e,t)}))}))}function b(t,n){var r;this._invoke=function(o,a){function s(){return new n((function(r,s){!function r(o,a,s,c){var l=u(t[o],t,a);if("throw"!==l.type){var h=l.arg,f=h.value;return f&&"object"===e(f)&&i.call(f,"__await")?n.resolve(f.__await).then((function(t){r("next",t,s,c)}),(function(t){r("throw",t,s,c)})):n.resolve(f).then((function(t){h.value=t,s(h)}),(function(t){return r("throw",t,s,c)}))}c(l.arg)}(o,a,r,s)}))}return r=r?r.then(s,s):s()}}function O(t,e){var n=t.iterator[e.method];if(void 0===n){if(e.delegate=null,"throw"===e.method){if(t.iterator.return&&(e.method="return",e.arg=void 0,O(t,e),"throw"===e.method))return h;e.method="throw",e.arg=new TypeError("The iterator does not provide a 'throw' method")}return h}var i=u(n,t.iterator,e.arg);if("throw"===i.type)return e.method="throw",e.arg=i.arg,e.delegate=null,h;var r=i.arg;return r?r.done?(e[t.resultName]=r.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=void 0),e.delegate=null,h):r:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,h)}function _(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function w(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function j(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(_,this),this.reset(!0)}function S(t){if(t){var e=t[o];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var n=-1,r=function e(){for(;++n=0;--r){var o=this.tryEntries[r],a=o.completion;if("root"===o.tryLoc)return n("end");if(o.tryLoc<=this.prev){var s=i.call(o,"catchLoc"),c=i.call(o,"finallyLoc");if(s&&c){if(this.prev=0;--n){var r=this.tryEntries[n];if(r.tryLoc<=this.prev&&i.call(r,"finallyLoc")&&this.prev=0;--e){var n=this.tryEntries[e];if(n.finallyLoc===t)return this.complete(n.completion,n.afterLoc),w(n),h}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var n=this.tryEntries[e];if(n.tryLoc===t){var i=n.completion;if("throw"===i.type){var r=i.arg;w(n)}return r}}throw new Error("illegal catch attempt")},delegateYield:function(t,e,n){return this.delegate={iterator:S(t),resultName:e,nextLoc:n},"next"===this.method&&(this.arg=void 0),h}},t}("object"===e(t)?t.exports:{});try{regeneratorRuntime=n}catch(t){"object"===("undefined"==typeof globalThis?"undefined":e(globalThis))?globalThis.regeneratorRuntime=n:Function("r","regeneratorRuntime = r")(n)}}).call(this,n(334)(t))},function(t,e){t.exports=function(t){return t.webpackPolyfill||(t.deprecate=function(){},t.paths=[],t.children||(t.children=[]),Object.defineProperty(t,"loaded",{enumerable:!0,get:function(){return t.l}}),Object.defineProperty(t,"id",{enumerable:!0,get:function(){return t.i}}),t.webpackPolyfill=1),t}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),n(89)},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});n(66)},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(1);n(9).registerShape("point","gauge-indicator",{draw:function(t,e){var n=t.customInfo,r=n.indicator,o=n.defaultColor,a=r,s=a.pointer,c=a.pin,l=e.addGroup(),u=this.parsePoint({x:0,y:0});return s&&l.addShape("line",{name:"pointer",attrs:i.__assign({x1:u.x,y1:u.y,x2:t.x,y2:t.y,stroke:o},s.style)}),c&&l.addShape("circle",{name:"pin",attrs:i.__assign({x:u.x,y:u.y,stroke:o},c.style)}),l}})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(9),r=n(0);i.registerShape("interval","meter-gauge",{draw:function(t,e){var n=t.customInfo.meter,o=void 0===n?{}:n,a=o.steps,s=void 0===a?50:a,c=o.stepRatio,l=void 0===c?.5:c;s=s<1?1:s,l=r.clamp(l,0,1);var u=this.coordinate,h=u.startAngle,f=u.endAngle,p=0;l>0&&l<1&&(p=(f-h)/s/(l/(1-l)+1-1/s));for(var d=p/(1-l)*l,g=e.addGroup(),y=this.coordinate.getCenter(),v=this.coordinate.getRadius(),m=i.Util.getAngle(t,this.coordinate),x=m.startAngle,b=m.endAngle,O=x;O0?g:y},x=c.deepAssign({},t,{options:{xField:o,yField:l.Y_FIELD,seriesField:o,rawFields:[s,l.DIFF_FIELD,l.IS_TOTAL,l.Y_FIELD],widthRatio:p,interval:{style:d,shape:"waterfall",color:m}}});return a.interval(x).ext.geometry.customInfo({leaderLine:f}),t}function p(t){var e,n,i=t.options,a=i.xAxis,s=i.yAxis,u=i.xField,h=i.yField,f=i.meta,p=c.deepAssign({},{alias:h},r.get(f,h));return c.flow(o.scale(((e={})[u]=a,e[h]=s,e[l.Y_FIELD]=s,e),c.deepAssign({},f,((n={})[l.Y_FIELD]=p,n[l.DIFF_FIELD]=p,n[l.ABSOLUTE_FIELD]=p,n))))(t)}function d(t){var e=t.chart,n=t.options,i=n.xAxis,r=n.yAxis,o=n.xField,a=n.yField;return!1===i?e.axis(o,!1):e.axis(o,i),!1===r?(e.axis(a,!1),e.axis(l.Y_FIELD,!1)):(e.axis(a,r),e.axis(l.Y_FIELD,r)),t}function g(t){var e=t.chart,n=t.options,i=n.legend,o=n.total,a=n.risingFill,l=n.fallingFill,u=n.locale,h=s.getLocale(u);if(!1===i)e.legend(!1);else{var f=[{name:h.get(["general","increase"]),value:"increase",marker:{symbol:"square",style:{r:5,fill:a}}},{name:h.get(["general","decrease"]),value:"decrease",marker:{symbol:"square",style:{r:5,fill:l}}}];o&&f.push({name:o.label||"",value:"total",marker:{symbol:"square",style:c.deepAssign({},{r:5},r.get(o,"style"))}}),e.legend(c.deepAssign({},{custom:!0,position:"top",items:f},i)),e.removeInteraction("legend-filter")}return t}function y(t){var e=t.chart,n=t.options,r=n.label,o=n.labelMode,a=n.xField,s=c.findGeometry(e,"interval");if(r){var u=r.callback,h=i.__rest(r,["callback"]);s.label({fields:"absolute"===o?[l.ABSOLUTE_FIELD,a]:[l.DIFF_FIELD,a],callback:u,cfg:c.transformLabel(h)})}else s.label(!1);return t}function v(t){var e=t.chart,n=t.options,r=n.tooltip,o=n.xField,a=n.yField;if(!1!==r){e.tooltip(i.__assign({showCrosshairs:!1,showMarkers:!1,shared:!0,fields:[a]},r));var s=e.geometries[0];(null==r?void 0:r.formatter)?s.tooltip(o+"*"+a,r.formatter):s.tooltip(a)}else e.tooltip(!1);return t}n(342),e.tooltip=v,e.adaptor=function(t){return c.flow(h,o.theme,f,p,d,g,v,y,o.state,o.interaction,o.animation,o.annotation())(t)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(1),r=n(9),o=n(0),a=n(2);r.registerShape("interval","waterfall",{draw:function(t,e){var n=t.customInfo,r=t.points,s=t.nextPoints,c=e.addGroup(),l=this.parsePath(function(t){for(var e=[],n=0;n0?Math.max.apply(Math,i):0,o=Math.abs(t)%360;return o?360*r/o:r},e.getStackedData=function(t,e,n){var r=[];return t.forEach((function(t){var o=r.find((function(n){return n[e]===t[e]}));o?o[n]+=t[n]||null:r.push(i.__assign({},t))})),r}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DEFAULT_OPTIONS=void 0;var i=n(7),r=n(2);e.DEFAULT_OPTIONS=r.deepAssign({},i.Plot.getDefaultOptions(),{interactions:[{type:"element-active"}],legend:!1,tooltip:{showMarkers:!1},xAxis:{grid:null,tickLine:null,line:null},maxAngle:240})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.BidirectionalBar=void 0;var i=n(1),r=n(9),o=n(7),a=n(2),s=(n(349),n(350)),c=n(165),l=n(164),u=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="bidirectional-bar",e}return i.__extends(e,t),e.getDefaultOptions=function(){return a.deepAssign({},t.getDefaultOptions.call(this),{syncViewPadding:c.syncViewPadding})},e.prototype.changeData=function(t){void 0===t&&(t=[]),this.chart.emit(r.VIEW_LIFE_CIRCLE.BEFORE_CHANGE_DATA,r.Event.fromData(this.chart,r.VIEW_LIFE_CIRCLE.BEFORE_CHANGE_DATA,null)),this.updateOption({data:t});var e=this.options,n=e.xField,i=e.yField,o=e.layout,s=c.transformData(n,i,l.SERIES_FIELD_KEY,t,c.isHorizontal(o)),u=s[0],h=s[1],f=a.findViewById(this.chart,l.FIRST_AXES_VIEW),p=a.findViewById(this.chart,l.SECOND_AXES_VIEW);f.data(u),p.data(h),this.chart.render(!0),this.chart.emit(r.VIEW_LIFE_CIRCLE.AFTER_CHANGE_DATA,r.Event.fromData(this.chart,r.VIEW_LIFE_CIRCLE.AFTER_CHANGE_DATA,null))},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return s.adaptor},e.SERIES_FIELD_KEY=l.SERIES_FIELD_KEY,e}(o.Plot);e.BidirectionalBar=u},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.adaptor=e.animation=e.theme=e.limitInPlot=e.interaction=void 0;var i=n(1),r=n(0),o=n(12),a=n(18),s=n(2),c=n(164),l=n(165);function u(t){var e,n,i=t.chart,r=t.options,o=r.data,u=r.xField,h=r.yField,f=r.color,p=r.barStyle,d=r.widthRatio,g=r.legend,y=r.layout,v=l.transformData(u,h,c.SERIES_FIELD_KEY,o,l.isHorizontal(y));g?i.legend(c.SERIES_FIELD_KEY,g):!1===g&&i.legend(!1);var m=v[0],x=v[1];l.isHorizontal(y)?((e=i.createView({region:{start:{x:0,y:0},end:{x:.5,y:1}},id:c.FIRST_AXES_VIEW})).coordinate().transpose().reflect("x"),(n=i.createView({region:{start:{x:.5,y:0},end:{x:1,y:1}},id:c.SECOND_AXES_VIEW})).coordinate().transpose(),e.data(m),n.data(x)):(e=i.createView({region:{start:{x:0,y:0},end:{x:1,y:.5}},id:c.FIRST_AXES_VIEW}),(n=i.createView({region:{start:{x:0,y:.5},end:{x:1,y:1}},id:c.SECOND_AXES_VIEW})).coordinate().reflect("y"),e.data(m),n.data(x));var b=s.deepAssign({},t,{chart:e,options:{widthRatio:d,xField:u,yField:h[0],seriesField:c.SERIES_FIELD_KEY,interval:{color:f,style:p}}});a.interval(b);var O=s.deepAssign({},t,{chart:n,options:{xField:u,yField:h[1],seriesField:c.SERIES_FIELD_KEY,widthRatio:d,interval:{color:f,style:p}}});return a.interval(O),t}function h(t){var e,n,i,a=t.options,l=t.chart,u=a.xAxis,h=a.yAxis,f=a.xField,p=a.yField,d=s.findViewById(l,c.FIRST_AXES_VIEW),g=s.findViewById(l,c.SECOND_AXES_VIEW),y={};return r.keys((null==a?void 0:a.meta)||{}).map((function(t){r.get(null==a?void 0:a.meta,[t,"alias"])&&(y[t]=a.meta[t].alias)})),l.scale(((e={})[c.SERIES_FIELD_KEY]={sync:!0,formatter:function(t){return r.get(y,t,t)}},e)),o.scale(((n={})[f]=u,n[p[0]]=h[p[0]],n))(s.deepAssign({},t,{chart:d})),o.scale(((i={})[f]=u,i[p[1]]=h[p[1]],i))(s.deepAssign({},t,{chart:g})),t}function f(t){var e=t.chart,n=t.options,r=n.xAxis,o=n.yAxis,a=n.xField,u=n.yField,h=n.layout,f=s.findViewById(e,c.FIRST_AXES_VIEW),p=s.findViewById(e,c.SECOND_AXES_VIEW);return"bottom"===(null==r?void 0:r.position)?p.axis(a,i.__assign(i.__assign({},r),{label:{formatter:function(){return""}}})):p.axis(a,!1),!1===r?f.axis(a,!1):f.axis(a,i.__assign({position:l.isHorizontal(h)?"top":"bottom"},r)),!1===o?(f.axis(u[0],!1),p.axis(u[1],!1)):(f.axis(u[0],o[u[0]]),p.axis(u[1],o[u[1]])),e.__axisPosition={position:f.getOptions().axes[a].position,layout:h},t}function p(t){var e=t.chart;return o.interaction(s.deepAssign({},t,{chart:s.findViewById(e,c.FIRST_AXES_VIEW)})),o.interaction(s.deepAssign({},t,{chart:s.findViewById(e,c.SECOND_AXES_VIEW)})),t}function d(t){var e=t.chart,n=t.options,i=n.yField,r=n.yAxis;return o.limitInPlot(s.deepAssign({},t,{chart:s.findViewById(e,c.FIRST_AXES_VIEW),options:{yAxis:r[i[0]]}})),o.limitInPlot(s.deepAssign({},t,{chart:s.findViewById(e,c.SECOND_AXES_VIEW),options:{yAxis:r[i[1]]}})),t}function g(t){var e=t.chart;return o.theme(s.deepAssign({},t,{chart:s.findViewById(e,c.FIRST_AXES_VIEW)})),o.theme(s.deepAssign({},t,{chart:s.findViewById(e,c.SECOND_AXES_VIEW)})),o.theme(t),t}function y(t){var e=t.chart;return o.animation(s.deepAssign({},t,{chart:s.findViewById(e,c.FIRST_AXES_VIEW)})),o.animation(s.deepAssign({},t,{chart:s.findViewById(e,c.SECOND_AXES_VIEW)})),t}function v(t){var e,n,r=this,o=t.chart,a=t.options,u=a.label,h=a.yField,f=a.layout,p=s.findViewById(o,c.FIRST_AXES_VIEW),d=s.findViewById(o,c.SECOND_AXES_VIEW),g=s.findGeometry(p,"interval"),y=s.findGeometry(d,"interval");if(u){var v=u.callback,m=i.__rest(u,["callback"]);m.position||(m.position="middle"),void 0===m.offset&&(m.offset=2);var x=i.__assign({},m);if(l.isHorizontal(f)){var b=(null===(e=x.style)||void 0===e?void 0:e.textAlign)||("middle"===m.position?"center":"left");m.style=s.deepAssign({},m.style,{textAlign:b});x.style=s.deepAssign({},x.style,{textAlign:{left:"right",right:"left",center:"center"}[b]})}else{var O={top:"bottom",bottom:"top",middle:"middle"};"string"==typeof m.position?m.position=O[m.position]:"function"==typeof m.position&&(m.position=function(){for(var t=[],e=0;e "+t.target,value:t.value}}},nodeWidthRatio:.008,nodePaddingRatio:.01,animation:{appear:{animation:"wave-in"},enter:{animation:"wave-in"}}}},e.prototype.changeData=function(t){this.updateOption({data:t});var e=c.transformToViewsData(this.options,this.chart.width,this.chart.height),n=e.nodes,i=e.edges,r=a.findViewById(this.chart,l.NODES_VIEW_ID),o=a.findViewById(this.chart,l.EDGES_VIEW_ID);r.changeData(n),o.changeData(i)},e.prototype.getSchemaAdaptor=function(){return s.adaptor},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e}(o.Plot);e.Sankey=u},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.adaptor=e.nodeDraggable=e.animation=void 0;var i=n(1),r=n(0),o=n(12),a=n(2),s=n(18),c=n(167),l=n(91);function u(t){var e=t.options.rawFields,n=void 0===e?[]:e;return a.deepAssign({},{options:{tooltip:{fields:r.uniq(i.__spreadArrays(["name","source","target","value","isNode"],n))},label:{fields:r.uniq(i.__spreadArrays(["x","name"],n))}}},t)}function h(t){var e=t.chart,n=t.options,i=n.color,r=n.nodeStyle,o=n.edgeStyle,a=n.label,u=n.tooltip,h=n.nodeState,f=n.edgeState;e.legend(!1),e.tooltip(u),e.axis(!1),e.coordinate().reflect("y");var p=c.transformToViewsData(n,e.width,e.height),d=p.nodes,g=p.edges,y=e.createView({id:l.EDGES_VIEW_ID});y.data(g),s.edge({chart:y,options:{xField:l.X_FIELD,yField:l.Y_FIELD,seriesField:l.COLOR_FIELD,edge:{color:i,style:o,shape:"arc"},tooltip:u,state:f}});var v=e.createView({id:l.NODES_VIEW_ID});return v.data(d),s.polygon({chart:v,options:{xField:l.X_FIELD,yField:l.Y_FIELD,seriesField:l.COLOR_FIELD,polygon:{color:i,style:r},label:a,tooltip:u,state:h}}),e.interaction("element-active"),e.scale({x:{sync:!0,nice:!0,min:0,max:1,minLimit:0,maxLimit:1},y:{sync:!0,nice:!0,min:0,max:1,minLimit:0,maxLimit:1},name:{sync:"color",type:"cat"}}),t}function f(t){var e=t.chart,n=t.options.animation;return"boolean"==typeof n?e.animate(n):e.animate(!0),i.__spreadArrays(e.views[0].geometries,e.views[1].geometries).forEach((function(t){t.animate(n)})),t}function p(t){var e=t.chart;return t.options.nodeDraggable?e.interaction("sankey-node-draggable"):e.removeInteraction("sankey-node-draggable"),t}function d(t){var e=t.chart,n=t.options,i=n.interactions,r=void 0===i?[]:i,o=[].concat(r,n.nodeInteractions||[]),s=[].concat(r,n.edgeInteractions||[]),c=a.findViewById(e,l.NODES_VIEW_ID),u=a.findViewById(e,l.EDGES_VIEW_ID);return o.forEach((function(t){!1===(null==t?void 0:t.enable)?c.removeInteraction(t.type):c.interaction(t.type,t.cfg||{})})),s.forEach((function(t){!1===(null==t?void 0:t.enable)?u.removeInteraction(t.type):u.interaction(t.type,t.cfg||{})})),t}e.animation=f,e.nodeDraggable=p,e.adaptor=function(t){return a.flow(u,h,d,p,f,o.theme)(t)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.sankeyLayout=e.getDefaultOptions=e.getNodeAlignFunction=void 0;var i=n(0),r=n(360),o={left:r.left,right:r.right,center:r.center,justify:r.justify},a={nodeId:function(t){return t.index},nodeAlign:"justify",nodeWidth:.008,nodePadding:.03,nodeSort:void 0};function s(t){return(i.isString(t)?o[t]:i.isFunction(t)?t:null)||r.justify}function c(t){return i.assign({},a,t)}e.getNodeAlignFunction=s,e.getDefaultOptions=c,e.sankeyLayout=function(t,e){var n=c(t),i=n.nodeId,o=n.nodeSort,a=n.nodeAlign,l=n.nodeWidth,u=n.nodePadding,h=n.nodeDepth,f=r.sankey().nodeSort(o).nodeWidth(l).nodePadding(u).nodeDepth(h).nodeAlign(s(a)).extent([[0,0],[1,1]]).nodeId(i)(e);return f.nodes.forEach((function(t){var e=t.x0,n=t.x1,i=t.y0,r=t.y1;t.x=[e,n,n,e],t.y=[i,i,r,r]})),f.links.forEach((function(t){var e=t.source,n=t.target,i=e.x1,r=n.x0;t.x=[i,i,r,r];var o=t.width/2;t.y=[t.y0+o,t.y0-o,t.y1+o,t.y1-o]})),f}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.sankey=void 0;var i=n(361);Object.defineProperty(e,"sankey",{enumerable:!0,get:function(){return i.Sankey}});var r=n(168);Object.defineProperty(e,"center",{enumerable:!0,get:function(){return r.center}}),Object.defineProperty(e,"left",{enumerable:!0,get:function(){return r.left}}),Object.defineProperty(e,"right",{enumerable:!0,get:function(){return r.right}}),Object.defineProperty(e,"justify",{enumerable:!0,get:function(){return r.justify}})},function(t,e,n){"use strict";function i(t){return(i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}Object.defineProperty(e,"__esModule",{value:!0}),e.Sankey=void 0;var r=n(168),o=n(362);function a(t,e){return c(t.source,e.source)||t.index-e.index}function s(t,e){return c(t.target,e.target)||t.index-e.index}function c(t,e){return t.y0-e.y0}function l(t){return t.value}function u(t){return t.index}function h(t){return t.nodes}function f(t){return t.links}function p(t,e){var n=t.get(e);if(!n)throw new Error("missing: "+e);return n}function d(t){for(var e=0,n=t.nodes;ei)throw new Error("circular link");r=a,a=new Set}if(e)for(var c=Math.max(o.maxValueBy(n,(function(t){return t.depth}))+1,0),l=void 0,u=0;un)throw new Error("circular link");i=r,r=new Set}}(a),function(e){var i=function(t){for(var e=t.nodes,i=Math.max(o.maxValueBy(e,(function(t){return t.depth}))+1,0),r=(m-y-b)/(i-1),a=new Array(i).fill(0).map((function(){return[]})),s=0,c=e;s0){var m=(h/f-u.y0)*e;u.y0+=m,u.y1+=m,T(u)}}void 0===n&&a.sort(c),a.length&&I(a,i)}}function E(t,e,i){for(var r=t.length-2;r>=0;--r){for(var o=t[r],a=0,s=o;a0){var v=(u/h-l.y0)*e;l.y0+=v,l.y1+=v,T(l)}}void 0===n&&o.sort(c),o.length&&I(o,i)}}function I(e,n){var i=e.length>>1,r=e[i];F(e,r.y0-t,i-1,n),P(e,r.y1+t,i+1,n),F(e,x,e.length-1,n),P(e,v,0,n)}function P(e,n,i,r){for(;i1e-6&&(o.y0+=a,o.y1+=a),n=o.y1+t}}function F(e,n,i,r){for(;i>=0;--i){var o=e[i],a=(o.y1-n)*r;a>1e-6&&(o.y0-=a,o.y1-=a),n=o.y0-t}}function T(t){var e=t.sourceLinks,n=t.targetLinks;if(void 0===g){for(var i=0,r=n;i=1)throw new TypeError("Invalid nodePaddingRatio: it must be in range [0, 1)!");var r=i/(2*n),o=e.nodeWidthRatio;if(o<=0||o>=1)throw new TypeError("Invalid nodeWidthRatio: it must be in range (0, 1)!");var a=0;t.forEach((function(t){a+=t.value})),t.forEach((function(t){t.weight=t.value/a,t.width=t.weight*(1-i),t.height=o})),t.forEach((function(n,i){for(var a=0,s=i-1;s>=0;s--)a+=t[s].width+2*r;var c=n.minX=r+a,l=n.maxX=n.minX+n.width,u=n.minY=e.y-o/2,h=n.maxY=u+o;n.x=[c,l,l,c],n.y=[u,u,h,h]}))}else{var s=1/n;t.forEach((function(t,n){t.x=(n+.5)*s,t.y=e.y}))}return t}(a,n),links:function(t,e,n){if(n.weight){var r={};i.forIn(t,(function(t,e){r[e]=t.value})),e.forEach((function(e){var i=n.source(e),o=n.target(e),a=t[i],s=t[o];if(a&&s){var c=r[i],l=n.sourceWeight(e),u=a.minX+(a.value-c)/a.value*a.width,h=u+l/a.value*a.width;r[i]-=l;var f=r[o],p=n.targetWeight(e),d=s.minX+(s.value-f)/s.value*s.width,g=d+p/s.value*s.width;r[o]-=p;var y=n.y;e.x=[u,h,d,g],e.y=[y,y,y,y],e.source=a,e.target=s}}))}else e.forEach((function(e){var i=t[n.source(e)],r=t[n.target(e)];i&&r&&(e.x=[i.x,r.x],e.y=[i.y,r.y],e.source=i,e.target=r)}));return e}(r,s,n)}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.CirclePacking=void 0;var i=n(1),r=n(7),o=n(372),a=n(170);n(375);n(376);var s=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="circle-packing",e}return i.__extends(e,t),e.getDefaultOptions=function(){return a.DEFAULT_OPTIONS},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return o.adaptor},e.prototype.triggerResize=function(){this.chart.destroyed||(this.chart.forceFit(),this.chart.clear(),this.execAdaptor(),this.chart.render(!0))},e}(r.Plot);e.CirclePacking=s},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.adaptor=e.meta=void 0;var i=n(1),r=n(0),o=n(112),a=n(12),s=n(2),c=n(44),l=n(373),u=n(170);function h(t){var e=t.chart,n=Math.min(e.viewBBox.width,e.viewBBox.height);return s.deepAssign({options:{size:function(t){return t.r*n}}},t)}function f(t){var e=t.options,n=t.chart,i=n.viewBBox,o=e.padding,a=e.appendPadding,s=e.drilldown,u=a;if(null==s?void 0:s.enabled){var h=c.getAdjustAppendPadding(n.appendPadding,r.get(s,["breadCrumb","position"]));u=c.resolveAllPadding([h,a])}var f=l.resolvePaddingForCircle(o,u,i).finalPadding;return n.padding=f,n.appendPadding=0,t}function p(t){var e=t.chart,n=t.options,r=e.padding,a=e.appendPadding,c=n.color,h=n.colorField,f=n.pointStyle,p=n.hierarchyConfig,d=n.sizeField,g=n.rawFields,y=void 0===g?[]:g,v=n.drilldown,m=l.transformData({data:n.data,hierarchyConfig:p,enableDrillDown:null==v?void 0:v.enabled,rawFields:y});e.data(m);var x=e.viewBBox,b=l.resolvePaddingForCircle(r,a,x).finalSize,O=function(t){return t.r*b};return d&&(O=function(t){return t[d]*b}),o.point(s.deepAssign({},t,{options:{xField:"x",yField:"y",seriesField:h,sizeField:d,rawFields:i.__spreadArrays(u.RAW_FIELDS,y),point:{color:c,style:f,shape:"circle",size:O}}})),t}function d(t){return s.flow(a.scale({},{x:{min:0,max:1,minLimit:0,maxLimit:1,nice:!0},y:{min:0,max:1,minLimit:0,maxLimit:1,nice:!0}}))(t)}function g(t){var e=t.chart,n=t.options.tooltip;if(!1===n)e.tooltip(!1);else{var o=n;r.get(n,"fields")||(o=s.deepAssign({},{customItems:function(t){return t.map((function(t){var n=r.get(e.getOptions(),"scales"),o=r.get(n,["name","formatter"],(function(t){return t})),a=r.get(n,["value","formatter"],(function(t){return t}));return i.__assign(i.__assign({},t),{name:o(t.data.name),value:a(t.data.value)})}))}},o)),e.tooltip(o)}return t}function y(t){return t.chart.axis(!1),t}function v(t){var e=t.drilldown,n=t.interactions,r=void 0===n?[]:n;return(null==e?void 0:e.enabled)?s.deepAssign({},t,{interactions:i.__spreadArrays(r,[{type:"drill-down",cfg:{drillDownConfig:e,transformData:l.transformData,enableDrillDown:!0}}])}):t}function m(t){var e=t.chart,n=t.options;return a.interaction({chart:e,options:v(n)}),t}e.meta=d,e.adaptor=function(t){return s.flow(a.pattern("pointStyle"),h,f,a.theme,d,p,y,a.legend,g,m,a.animation,a.annotation())(t)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.resolvePaddingForCircle=e.transformData=void 0;var i=n(1),r=n(374),o=n(2),a=n(65),s=n(44);e.transformData=function(t){var e=t.data,n=t.hierarchyConfig,s=t.rawFields,c=void 0===s?[]:s,l=t.enableDrillDown,u=r.pack(e,i.__assign(i.__assign({},n),{field:"value",as:["x","y","r"]})),h=[];return u.forEach((function(t){for(var e,r=t.data.name,s=i.__assign({},t);s.depth>1;)r=(null===(e=s.parent.data)||void 0===e?void 0:e.name)+" / "+r,s=s.parent;if(l&&t.depth>2)return null;var u=o.deepAssign({},t.data,i.__assign(i.__assign(i.__assign({},o.pick(t.data,c)),{path:r}),t));u.ext=n,u[a.HIERARCHY_DATA_TRANSFORM_PARAMS]={hierarchyConfig:n,rawFields:c,enableDrillDown:l},h.push(u)})),h},e.resolvePaddingForCircle=function(t,e,n){var i=s.resolveAllPadding([t,e]),r=i[0],o=i[1],a=i[2],c=i[3],l=n.width-(c+o),u=n.height-(r+a),h=Math.min(l,u),f=(l-h)/2,p=(u-h)/2;return{finalPadding:[r+p,o+f,a+p,c+f],finalSize:h<0?0:h}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.pack=void 0;var i=n(1).__importStar(n(93)),r=n(0),o=n(58),a={field:"value",as:["x","y","r"],sort:function(t,e){return e.value-t.value}};e.pack=function(t,e){var n,s=(e=r.assign({},a,e)).as;if(!r.isArray(s)||3!==s.length)throw new TypeError('Invalid as: it must be an array with 3 strings (e.g. [ "x", "y", "r" ])!');try{n=o.getField(e)}catch(t){console.warn(t)}var c=function(t){return i.pack().size(e.size).padding(e.padding)(i.hierarchy(t).sum((function(t){return t[n]})).sort(e.sort))}(t),l=s[0],u=s[1],h=s[2];return c.each((function(t){t[l]=t.x,t[u]=t.y,t[h]=t.r})),o.getAllNodes(c)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),n(89)},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.P=void 0;var i=n(1),r=n(2),o=function(t){function e(e,n,i,o){var a=t.call(this,e,r.deepAssign({},o,n))||this;return a.type="g2-plot",a.defaultOptions=o,a.adaptor=i,a}return i.__extends(e,t),e.prototype.getDefaultOptions=function(){return this.defaultOptions},e.prototype.getSchemaAdaptor=function(){return this.adaptor},e}(n(7).Plot);e.P=o},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.adaptor=void 0;var i=n(1),r=n(0),o=n(27),a=n(12),s=n(7),c=n(37),l=n(2),u=n(171);function h(t){var e=t.chart,n=t.options,a=n.views,s=n.legend;return r.each(a,(function(t){var n=t.region,a=t.data,s=t.meta,u=t.axes,h=t.coordinate,f=t.interactions,p=t.annotations,d=t.tooltip,g=t.geometries,y=e.createView({region:n});y.data(a);var v={};u&&r.each(u,(function(t,e){v[e]=l.pick(t,c.AXIS_META_CONFIG_KEYS)})),v=l.deepAssign({},s,v),y.scale(v),u?r.each(u,(function(t,e){y.axis(e,t)})):y.axis(!1),y.coordinate(h),r.each(g,(function(t){var e=o.geometry({chart:y,options:t}).ext,n=t.adjust;n&&e.geometry.adjust(n)})),r.each(f,(function(t){!1===t.enable?y.removeInteraction(t.type):y.interaction(t.type,t.cfg)})),r.each(p,(function(t){y.annotation()[t.type](i.__assign({},t))})),"boolean"==typeof t.animation?y.animate(!1):(y.animate(!0),r.each(y.geometries,(function(e){e.animate(t.animation)}))),d&&(y.interaction("tooltip"),y.tooltip(d))})),s?r.each(s,(function(t,n){e.legend(n,t)})):e.legend(!1),e.tooltip(n.tooltip),t}function f(t){var e=t.chart,n=t.options.plots;return r.each(n,(function(t){var n=t.type,r=t.region,o=t.options,a=void 0===o?{}:o,c=a.tooltip,h=e.createView(i.__assign({region:r},l.pick(a,s.PLOT_CONTAINER_OPTIONS)));c&&h.interaction("tooltip"),u.execPlotAdaptor(n,h,a)})),t}e.adaptor=function(t){return l.flow(a.animation,h,f,a.interaction,a.animation,a.theme,a.tooltip)(t)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),n(381)},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=n(1),r=n(0),o=n(9),a=n(2),s=n(382),c=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return i.__extends(e,t),e.prototype.getAssociationItems=function(t,e){var n,i=this.context.event,o=e||{},c=o.linkField,l=o.dim,u=[];if(null===(n=i.data)||void 0===n?void 0:n.data){var h=i.data.data;r.each(t,(function(t){var e,n,i=c;if("x"===l?i=t.getXScale().field:"y"===l?i=null===(e=t.getYScales().find((function(t){return t.field===i})))||void 0===e?void 0:e.field:i||(i=null===(n=t.getGroupScales()[0])||void 0===n?void 0:n.field),i){var o=r.map(a.getAllElements(t),(function(e){var n=!1,o=!1,a=r.isArray(h)?r.get(h[0],i):r.get(h,i);return s.getElementValue(e,i)===a?n=!0:o=!0,{element:e,view:t,active:n,inactive:o}}));u.push.apply(u,o)}}))}return u},e.prototype.showTooltip=function(t){var e=a.getSiblingViews(this.context.view),n=this.getAssociationItems(e,t);r.each(n,(function(t){if(t.active){var e=t.element.shape.getCanvasBBox();t.view.showTooltip({x:e.minX+e.width/2,y:e.minY+e.height/2})}}))},e.prototype.hideTooltip=function(){var t=a.getSiblingViews(this.context.view);r.each(t,(function(t){t.hideTooltip()}))},e.prototype.active=function(t){var e=a.getViews(this.context.view),n=this.getAssociationItems(e,t);r.each(n,(function(t){var e=t.active,n=t.element;e&&n.setState("active",!0)}))},e.prototype.selected=function(t){var e=a.getViews(this.context.view),n=this.getAssociationItems(e,t);r.each(n,(function(t){var e=t.active,n=t.element;e&&n.setState("selected",!0)}))},e.prototype.highlight=function(t){var e=a.getViews(this.context.view),n=this.getAssociationItems(e,t);r.each(n,(function(t){var e=t.inactive,n=t.element;e&&n.setState("inactive",!0)}))},e.prototype.reset=function(){var t=a.getViews(this.context.view);r.each(t,(function(t){s.clearHighlight(t)}))},e}(o.Action);o.registerAction("association",c),o.registerInteraction("association-active",{start:[{trigger:"element:mouseenter",action:"association:active"}],end:[{trigger:"element:mouseleave",action:"association:reset"}]}),o.registerInteraction("association-selected",{start:[{trigger:"element:mouseenter",action:"association:selected"}],end:[{trigger:"element:mouseleave",action:"association:reset"}]}),o.registerInteraction("association-highlight",{start:[{trigger:"element:mouseenter",action:"association:highlight"}],end:[{trigger:"element:mouseleave",action:"association:reset"}]}),o.registerInteraction("association-tooltip",{start:[{trigger:"element:mousemove",action:"association:showTooltip"}],end:[{trigger:"element:mouseleave",action:"association:hideTooltip"}]})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.clearHighlight=e.getElementValue=void 0;var i=n(0),r=n(2);e.getElementValue=function(t,e){var n=t.getModel().data;return i.isArray(n)?n[0][e]:n[e]},e.clearHighlight=function(t){var e=r.getAllElements(t);i.each(e,(function(t){t.hasState("active")&&t.setState("active",!1),t.hasState("selected")&&t.setState("selected",!1),t.hasState("inactive")&&t.setState("inactive",!1)}))}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.Facet=void 0;var i=n(1),r=n(7),o=n(384),a=n(386),s=(n(387),function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="area",e}return i.__extends(e,t),e.getDefaultOptions=function(){return a.DEFAULT_OPTIONS},e.prototype.getDefaultOptions=function(){return e.getDefaultOptions()},e.prototype.getSchemaAdaptor=function(){return o.adaptor},e}(r.Plot));e.Facet=s},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.adaptor=void 0;var i=n(1),r=n(0),o=n(12),a=n(37),s=n(2),c=n(171),l=n(385);function u(t){var e=t.chart,n=t.options,o=n.type,a=n.data,s=n.fields,u=n.eachView,h=r.omit(n,["type","data","fields","eachView","axes","meta","tooltip","coordinate","theme","legend","interactions","annotations"]);return e.data(a),e.facet(o,i.__assign(i.__assign({},h),{fields:s,eachView:function(t,e){var n=u(t,e);if(n.geometries)l.execViewAdaptor(t,n);else{var i=n,r=i.options;r.tooltip&&t.interaction("tooltip"),c.execPlotAdaptor(i.type,t,r)}}})),t}function h(t){var e=t.chart,n=t.options,o=n.axes,c=n.meta,l=n.tooltip,u=n.coordinate,h=n.theme,f=n.legend,p=n.interactions,d=n.annotations,g={};return o&&r.each(o,(function(t,e){g[e]=s.pick(t,a.AXIS_META_CONFIG_KEYS)})),g=s.deepAssign({},c,g),e.scale(g),e.coordinate(u),o?r.each(o,(function(t,n){e.axis(n,t)})):e.axis(!1),l?(e.interaction("tooltip"),e.tooltip(l)):!1===l&&e.removeInteraction("tooltip"),e.legend(f),h&&e.theme(h),r.each(p,(function(t){!1===t.enable?e.removeInteraction(t.type):e.interaction(t.type,t.cfg)})),r.each(d,(function(t){e.annotation()[t.type](i.__assign({},t))})),t}e.adaptor=function(t){return s.flow(o.theme,u,h)(t)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.execViewAdaptor=void 0;var i=n(1),r=n(0),o=n(27),a=n(37),s=n(2);e.execViewAdaptor=function(t,e){var n=e.data,c=e.coordinate,l=e.interactions,u=e.annotations,h=e.animation,f=e.tooltip,p=e.axes,d=e.meta,g=e.geometries;n&&t.data(n);var y={};p&&r.each(p,(function(t,e){y[e]=s.pick(t,a.AXIS_META_CONFIG_KEYS)})),y=s.deepAssign({},d,y),t.scale(y),c&&t.coordinate(c),!1===p?t.axis(!1):r.each(p,(function(e,n){t.axis(n,e)})),r.each(g,(function(e){var n=o.geometry({chart:t,options:e}).ext,i=e.adjust;i&&n.geometry.adjust(i)})),r.each(l,(function(e){!1===e.enable?t.removeInteraction(e.type):t.interaction(e.type,e.cfg)})),r.each(u,(function(e){t.annotation()[e.type](i.__assign({},e))})),"boolean"==typeof h?t.animate(!1):(t.animate(!0),r.each(t.geometries,(function(t){t.animate(h)}))),f?(t.interaction("tooltip"),t.tooltip(f)):!1===f&&t.removeInteraction("tooltip")}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DEFAULT_OPTIONS=void 0,e.DEFAULT_OPTIONS={title:{style:{fontSize:12,fill:"rgba(0,0,0,0.65)"}},rowTitle:{style:{fontSize:12,fill:"rgba(0,0,0,0.65)"}},columnTitle:{style:{fontSize:12,fill:"rgba(0,0,0,0.65)"}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.Lab=e.notice=e.Stage=void 0;var i,r=n(92);function o(t,e){console.warn(t===i.DEV?"Plot '"+e+"' is in DEV stage, just give us issues.":t===i.BETA?"Plot '"+e+"' is in BETA stage, DO NOT use it in production env.":t===i.STABLE?"Plot '"+e+"' is in STABLE stage, import it by \"import { "+e+" } from '@antv/g2plot'\".":"invalid Stage type.")}!function(t){t.DEV="DEV",t.BETA="BETA",t.STABLE="STABLE"}(i=e.Stage||(e.Stage={})),e.notice=o;var a=function(){function t(){}return Object.defineProperty(t,"MultiView",{get:function(){return o(i.STABLE,"MultiView"),r.Mix},enumerable:!1,configurable:!0}),t}();e.Lab=a}])})); //# sourceMappingURL=g2plot.min.js.map