Skip to content

Instantly share code, notes, and snippets.

@kagawagao
Created May 23, 2018 09:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kagawagao/71e8529f13603e22ac7f73bfca8ca6a2 to your computer and use it in GitHub Desktop.
Save kagawagao/71e8529f13603e22ac7f73bfca8ca6a2 to your computer and use it in GitHub Desktop.
error-parsed-chunk
(window.webpackJsonp=window.webpackJsonp||[]).push([[5],Array(549).concat([function(t,e,n){var r=n(552).CommonUtil,i=5;function o(t,e){for(var n in e)e.hasOwnProperty(n)&&"constructor"!==n&&void 0!==e[n]&&(t[n]=e[n])}var a=r.assign({cloneDeep:n(618),filter:n(891),flatten:n(672),groupBy:n(724),indexOf:n(880),isDate:n(878),isEmpty:n(82),isEqualWith:n(876),isFinite:n(875),isNaN:n(874),isNull:n(873),isPlainObject:n(70),lowerFirst:n(872),map:n(723),maxBy:n(871),minBy:n(869),pick:n(607),reduce:n(864),replace:n(862),round:n(861),union:n(859),uniq:n(720),upperCase:n(858),snapEqual:function(t,e){return Math.abs(t-e)<.001},fixedBase:function(t,e){var n=e.toString(),r=n.indexOf(".");if(-1===r)return Math.round(t);var i=n.substr(r+1).length;return i>20&&(i=20),parseFloat(t.toFixed(i))},mix:function(t,e,n,r){return e&&o(t,e),n&&o(t,n),r&&o(t,r),t},inArray:function(t,e){return t.indexOf(e)>=0},wrapBehavior:function(t,e){if(t["_wrap_"+e])return t["_wrap_"+e];var n=function(n){t[e](n)};return t["_wrap_"+e]=n,n},getWrapBehavior:function(t,e){return t["_wrap_"+e]},toAllPadding:function(t){var e=0,n=0,r=0,i=0;return a.isNumber(t)||a.isString(t)?e=n=r=i=t:a.isArray(t)?(e=t[0],r=a.isNil(t[1])?t[0]:t[1],i=a.isNil(t[2])?t[0]:t[2],n=a.isNil(t[3])?r:t[3]):a.isObject(t)&&(e=t.top||0,r=t.right||0,i=t.bottom||0,n=t.left||0),[e,r,i,n]},substitute:function(t,e){return t&&e?t.replace(/\\?\{([^{}]+)\}/g,function(t,n){return"\\"===t.charAt(0)?t.slice(1):void 0===e[n]?"":e[n]}):t}},r);function s(t,e,n){for(var r in n=n||0,e)if(e.hasOwnProperty(r)){var o=e[r];null!==o&&a.isPlainObject(o)?(a.isPlainObject(t[r])||(t[r]={}),n<i?s(t[r],e[r],n+1):t[r]=e[r]):a.isArray(o)?(t[r]=[],t[r]=t[r].concat(o)):void 0!==o&&(t[r]=e[r])}}a.deepMix=function(){for(var t=a.toArray(arguments),e=t[0],n=1;n<t.length;n++){s(e,t[n])}return e},a.Array={merge:function(t){for(var e=[],n=0;n<t.length;n++)e=e.concat(t[n]);return e},values:function(t,e){for(var n=[],r={},i=0;i<t.length;i++){var o=t[i][e];a.isNil(o)||(a.isArray(o)||(o=[o]),a.each(o,function(t){r[t]||(n.push(t),r[t]=!0)}))}return n},getRange:function(t){if(!(t=a.filter(t,function(t){return!isNaN(t)})).length)return{min:0,max:0};if(a.isArray(t[0])){for(var e=[],n=0;n<t.length;n++)e=e.concat(t[n]);t=e}var r=Math.max.apply(null,t);return{min:Math.min.apply(null,t),max:r}},firstValue:function(t,e){for(var n=null,r=0;r<t.length;r++){var i=t[r][e];if(!a.isNil(i)){n=a.isArray(i)?i[0]:i;break}}return n},group:function(t,e){if(!e)return[t];var n=a.Array.groupToMap(t,e),r=[];for(var i in n)r.push(n[i]);return r},groupToMap:function(t,e){if(!e)return{0:t};if(!a.isFunction(e)){var n=a.isArray(e)?e:e.replace(/\s+/g,"").split("*");e=function(t){for(var e="_",r=0,i=n.length;r<i;r++)e+=t[n[r]]&&t[n[r]].toString();return e}}return a.groupBy(t,e)},remove:r.remove},t.exports=a},,function(t,e,n){var r=n(549),i=n(841),o={version:"____G2_VERSION____",trackable:!0,animate:!0,snapArray:[0,1,2,4,5,10],snapCountArray:[0,1,1.2,1.5,1.6,2,2.2,2.4,2.5,3,4,5,6,7.5,8,10],widthRatio:{column:.5,rose:.9999999,multiplePie:1/1.3},showSinglePoint:!1,connectNulls:!1,scales:{}};function a(t){var e={};e=r.isObject(t)?t:-1!==r.indexOf(Object.keys(i),t)?i[t]:i.default,r.deepMix(o,e)}a("default"),o.setTheme=a,t.exports=o},function(t,e,n){t.exports={Canvas:n(967),Group:n(691),Shape:n(556),Rect:n(619),Circle:n(688),Ellipse:n(687),Path:n(686),Text:n(684),Line:n(683),Image:n(682),Polygon:n(681),Polyline:n(680),Arc:n(679),Fan:n(678),Cubic:n(677),Quadratic:n(676),Marker:n(675),PathUtil:n(623),PathSegment:n(685),MatrixUtil:n(558),CommonUtil:n(585),DomUtil:n(693),Event:n(692),version:"____G_VERSION____"}},function(t,e,n){var r=n(585),i=n(693),o={};r.merge(o,r,i,{mixin:function(t,e){var n=t.CFG?"CFG":"ATTRS";if(t&&e){t._mixins=e,t[n]=t[n]||{};var r={};o.each(e,function(e){o.augment(t,e);var i=e[n];i&&o.merge(r,i)}),t[n]=o.merge(r,t[n])}}}),t.exports=o},,function(t,e,n){var r=n(601),i=n(575),o=n(703),a=n(254),s=n(164),u=n(565),l=Object.prototype.hasOwnProperty,c=o(function(t,e){if(s(e)||a(e))i(e,u(e),t);else for(var n in e)l.call(e,n)&&r(t,n,e[n])});t.exports=c},function(t,e,n){var r=n(553),i=n(690),o=n(557),a=function t(e){t.superclass.constructor.call(this,e)};a.ATTRS={},r.extend(a,i),r.augment(a,{isShape:!0,createPath:function(){},drawInner:function(t){var e=this.__attrs;this.createPath(t);var n=t.globalAlpha;if(this.hasFill()){var i=e.fillOpacity;r.isNil(i)||1===i?t.fill():(t.globalAlpha=i,t.fill(),t.globalAlpha=n)}if(this.hasStroke()&&this.__attrs.lineWidth>0){var o=e.strokeOpacity;r.isNil(o)||1===o||(t.globalAlpha=o),t.stroke()}},isPointInPath:function(){return!1},isHitBox:function(){return!0},isHit:function(t,e){var n=[t,e,1];if(this.invert(n),this.isHitBox()){var r=this.getBBox();if(r&&!o.box(r.minX,r.maxX,r.minY,r.maxY,n[0],n[1]))return!1}var i=this.__attrs.clip;return i?!!i.inside(t,e)&&this.isPointInPath(n[0],n[1]):this.isPointInPath(n[0],n[1])},calculateBox:function(){return null},getHitLineWidth:function(){var t=this.__attrs,e=t.lineAppendWidth||0;return(t.lineWidth||0)+e},clearTotalMatrix:function(){this.__cfg.totalMatrix=null,this.__cfg.region=null},clearBBox:function(){this.__cfg.box=null,this.__cfg.region=null},getBBox:function(){var t=this.__cfg.box;return t||((t=this.calculateBox())&&(t.x=t.minX,t.y=t.minY,t.width=t.maxX-t.minX,t.height=t.maxY-t.minY),this.__cfg.box=t),t}}),t.exports=a},function(t,e,n){var r=n(622),i=n(621),o=n(597),a=n(620);t.exports={line:function(t,e,n,i,o,a,s){var u=r.box(t,e,n,i,o);if(!this.box(u.minX,u.maxX,u.minY,u.maxY,a,s))return!1;var l=r.pointDistance(t,e,n,i,a,s);return!isNaN(l)&&l<=o/2},polyline:function(t,e,n,r){var i=t.length-1;if(i<1)return!1;for(var o=0;o<i;o++){var a=t[o][0],s=t[o][1],u=t[o+1][0],l=t[o+1][1];if(this.line(a,s,u,l,e,n,r))return!0}return!1},cubicline:function(t,e,n,r,i,a,s,u,l,c,h){return o.pointDistance(t,e,n,r,i,a,s,u,c,h)<=l/2},quadraticline:function(t,e,n,r,o,a,s,u,l){return i.pointDistance(t,e,n,r,o,a,u,l)<=s/2},arcline:function(t,e,n,r,i,o,s,u,l){return a.pointDistance(t,e,n,r,i,o,u,l)<=s/2},rect:function(t,e,n,r,i,o){return t<=i&&i<=t+n&&e<=o&&o<=e+r},circle:function(t,e,n,r,i){return Math.pow(r-t,2)+Math.pow(i-e,2)<=Math.pow(n,2)},box:function(t,e,n,r,i,o){return t<=i&&i<=e&&n<=o&&o<=r}}},function(t,e,n){var r=n(585),i=n(898),o=n(897),a=n(896);a.angle=function(t,e){var n=a.dot(t,e)/(a.length(t)*a.length(e));return Math.acos(r.clamp(n,-1,1))},a.direction=function(t,e){return t[0]*e[1]-e[0]*t[1]},a.angleTo=function(t,e,n){var r=a.angle(t,e),i=a.direction(t,e)>=0;return n?i?2*Math.PI-r:r:i?r:2*Math.PI-r},a.vertical=function(t,e,n){return n?(t[0]=e[1],t[1]=-1*e[0]):(t[0]=-1*e[1],t[1]=e[0]),t},i.translate=function(t,e,n){var r=new Array(9);return i.fromTranslation(r,n),i.multiply(t,r,e)},i.rotate=function(t,e,n){var r=new Array(9);return i.fromRotation(r,n),i.multiply(t,r,e)},i.scale=function(t,e,n){var r=new Array(9);return i.fromScaling(r,n),i.multiply(t,r,e)},t.exports={mat3:i,vec2:a,vec3:o,transform:function(t,e){return t=r.clone(t),r.each(e,function(e){switch(e[0]){case"t":i.translate(t,t,[e[1],e[2]]);break;case"s":i.scale(t,t,[e[1],e[2]]);break;case"r":i.rotate(t,t,e[1]);break;case"m":i.multiply(t,t,e[1]);break;default:return!1}}),t}}},,,function(t,e,n){var r=n(549),i=n(568),o=n(552).PathUtil,a={},s={_coord:null,draw:function(t,e){return this.drawShape?this.drawShape(t,e):null},setCoord:function(t){this._coord=t},parsePath:function(t,e){var n=this._coord;return t=o.parsePathString(t),t=n.isPolar&&!1!==e?i.convertPolarPath(n,t):i.convertNormalPath(n,t)},parsePoint:function(t){return this._coord.convertPoint(t)},parsePoints:function(t){var e=this._coord,n=[];return r.each(t,function(t){n.push(e.convertPoint(t))}),n}},u={defaultShapeType:null,setCoord:function(t){this._coord=t},getShape:function(t){r.isArray(t)&&(t=t[0]);var e=this[t]||this[this.defaultShapeType];return e._coord=this._coord,e},getShapePoints:function(t,e){var n=this.getShape(t);return(n.getPoints||n.getShapePoints||this.getDefaultPoints)(e)},getDefaultPoints:function(){return[]},getMarkerCfg:function(t,e){var n=this.getShape(t);if(!n.getMarkerCfg){var r=this.defaultShapeType;n=this.getShape(r)}return n.getMarkerCfg(e)},getSelectedCfg:function(){return{}},drawShape:function(t,e,n){var r=this.getShape(t).draw(e,n);return r&&(r.setSilent("origin",e.origin),r._id=e.yIndex?e._id+e.yIndex:e._id,r.name=this.name),r}};a.registerFactory=function(t,e){var n=r.upperFirst(t),i=r.assign({},u,e);return a[n]=i,i.name=t,i},a.registerShape=function(t,e,n){var i=r.upperFirst(t),o=a[i],u=r.assign({},s,n);return o[e]=u,u},a.getShapeFactory=function(t){return t=t||"point",this[r.upperFirst(t)]},t.exports=a},function(t,e,n){var r=n(617),i=n(666),o=n(549),a=n(551),s=n(839),u=n(834),l=n(561),c=n(830),h=n(829),f=n(828),p=["color","shape","size"];function d(t){return o.isArray(t)?t:o.isString(t)?t.split("*"):[t]}function g(t){return(o.isString(t)||o.isPlainObject(t))&&(t=[t]),o.each(t,function(e,n){o.isObject(e)||(t[n]={type:e})}),t}var v=function(t){function e(n){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);var r=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.call(this,n));return o.assign(r,c,h,f),r.get("container")&&r._initContainer(),r._initOptions(),r}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){return{_id:null,type:"base",coord:null,attrs:{},view:null,data:[],scales:{},container:null,labelContainer:null,shapeContainer:null,attrOptions:{},styleOptions:null,selectedOptions:null,activedOptions:null,hasDefaultAdjust:!1,adjusts:null,shapeType:null,generatePoints:!1,sortable:!1,labelCfg:null,shareTooltip:!0,tooltipCfg:null,animate:!0,animateCfg:null,visible:!0}},e.prototype._initOptions=function(){var t=this.get("adjusts");t&&(t=g(t),this.set("adjusts",t))},e.prototype._createScale=function(t,e){var n=this.get("scales"),r=n[t];return r||(r=this.get("view").createScale(t,e),n[t]=r),r},e.prototype._setAttrOptions=function(t,e){this.get("attrOptions")[t]=e},e.prototype._createAttrOption=function(t,e,n,r){var i={};i.field=e,n?o.isFunction(n)?i.callback=n:i.values=n:"color"!==t&&(i.values=r),this._setAttrOptions(t,i)},e.prototype.position=function(t){return this._setAttrOptions("position",{field:t}),this},e.prototype.color=function(t,e){return this._createAttrOption("color",t,e,a.colors),this},e.prototype.size=function(t,e){return this._createAttrOption("size",t,e,a.sizes),this},e.prototype.shape=function(t,e){var n=this.get("type"),r=a.shapes[n]||[];return this._createAttrOption("shape",t,e,r),this},e.prototype.opacity=function(t,e){return this._createAttrOption("opacity",t,e,a.opacities),this},e.prototype.style=function(t,e){var n=this.get("styleOptions");n||(n={},this.set("styleOptions",n)),o.isObject(t)&&(e=t,t=null);var r=void 0;return t&&(r=d(t)),n.fields=r,n.style=e,this},e.prototype.label=function(t,e,n){var r=this.get("labelCfg");r||(r={},this.set("labelCfg",r));var i=void 0;return t&&(i=d(t)),r.fields=i,o.isFunction(e)?(n||(n={}),n.content=e):o.isObject(e)&&(n=e),r.cfg=n,this},e.prototype.tooltip=function(t,e){var n=this.get("tooltipCfg");if(n||(n={}),!1===t)this.set("tooltipCfg",!1);else{var r=void 0;t&&(r=d(t)),n.fields=r,n.cfg=e}return this.set("tooltipCfg",n),this},e.prototype.animate=function(t){return this.set("animateCfg",t),this},e.prototype.active=function(t,e){return!1===t?this.set("allowActive",!1):o.isObject(t)?(this.set("allowActive",!0),this.set("activedOptions",t)):(this.set("allowActive",!0),this.set("activedOptions",e)),this},e.prototype.adjust=function(t){return this.get("hasDefaultAdjust")||(t&&(t=g(t)),this.set("adjusts",t)),this},e.prototype.select=function(t,e){return!1===t?this.set("allowSelect",!1):o.isObject(t)?(this.set("allowSelect",!0),this.set("selectedOptions",t)):(this.set("allowSelect",!0),this.set("selectedOptions",e)),this},e.prototype.hasAdjust=function(t){var e=this.get("adjusts");if(!t)return!1;var n=!1;return o.each(e,function(e){if(e.type===t)return n=!0,!1}),n},e.prototype.hasStack=function(){var t=this.get("isStacked");return o.isNil(t)&&(t=this.hasAdjust("stack"),this.set("isStacked",t)),t},e.prototype.isInCircle=function(){var t=this.get("coord");return t&&t.isPolar},e.prototype._initContainer=function(){var t=this.get("shapeContainer");if(!t){var e=this.get("container"),n=this.get("view"),r=n&&n.get("_id");t=e.addGroup({viewId:r,visible:this.get("visible")}),this.set("shapeContainer",t)}},e.prototype.init=function(){var t=this;if(t._initContainer(),t._initAttrs(),t.get("tooltipCfg")&&t.get("tooltipCfg").fields){var e=t.get("tooltipCfg").fields;o.each(e,function(e){t._createScale(e)})}var n=t._processData();t.get("adjusts")&&t._adjust(n),t.set("dataArray",n)},e.prototype._initAttrs=function(){var t=this.get("attrs"),e=this.get("attrOptions"),n=this.get("coord"),r=!1;for(var s in e)if(e.hasOwnProperty(s)){var u=e[s],l=o.upperFirst(s),c=d(u.field);"position"===s&&(u.coord=n,1===c.length&&"theta"===n.type&&(c.unshift("1"),r=!0));for(var h=[],f=0;f<c.length;f++){var p=c[f],g=this._createScale(p);"color"===s&&o.isNil(u.values)&&(g.values.length<=8?u.values=r?a.colors_pie:a.colors:g.values.length<=16?u.values=r?a.colors_pie_16:a.colors_16:u.values=a.colors_24,o.isNil(u.values)&&(u.values=a.colors)),h.push(g)}if("theta"===n.type&&"position"===s&&h.length>1){var v=h[1];v.change({nice:!1,min:0,max:Math.max.apply(null,v.values)})}u.scales=h;var y=new i[l](u);t[s]=y}},e.prototype._processData=function(){for(var t=this.get("data"),e=[],n=this._groupData(t),r=0;r<n.length;r++){var i=n[r],o=this._saveOrigin(i);this._numberic(o),e.push(o)}return e},e.prototype._groupData=function(t){var e=this._getGroupScales().map(function(t){return t.field});return o.Array.group(t,e)},e.prototype._saveOrigin=function(t){for(var e=[],n=0;n<t.length;n++){var r=t[n],i={};for(var o in r)i[o]=r[o];i._origin=r,e.push(i)}return e},e.prototype._numberic=function(t){for(var e=this.getAttr("position").scales,n=0;n<t.length;n++)for(var r=t[n],i=0;i<Math.min(2,e.length);i++){var o=e[i];if(o.isCategory){var a=o.field;r[a]=o.translate(r[a])}}},e.prototype._getGroupScales=function(){var t=this.get("groupScales");if(!t){t=[];var e=this.get("attrs");o.each(e,function(e){if(-1!==p.indexOf(e.type)){var n=e.scales;o.each(n,function(e){e.isCategory&&-1===o.indexOf(t,e)&&t.push(e)})}}),this.set("groupScales",t)}return t},e.prototype._updateStackRange=function(t,e,n){for(var r=o.Array.merge(n),i=e.min,a=e.max,s=0;s<r.length;s++){var u=r[s],l=Math.min.apply(null,u[t]),c=Math.max.apply(null,u[t]);l<i&&(i=l),c>a&&(a=c)}(i<e.min||a>e.max)&&e.change({min:i,max:a})},e.prototype._adjust=function(t){var e=this,n=e.get("adjusts"),r=e.getYScale(),i=e.getXScale(),a=i.field,u=r?r.field:null;o.each(n,function(n){var l=o.mix({xField:a,yField:u},n),c=o.upperFirst(n.type);if("Dodge"===c){var h=[];if(i.isCategory||i.isIdentity)h.push("x");else{if(r)throw new Error("dodge is not support linear attribute, please use category attribute!");h.push("y")}l.adjustNames=h}else if("Stack"===c){var f=e.get("coord");if(!r){l.height=f.getHeight();var p=e.getDefaultValue("size")||3;l.size=p}!f.isTransposed&&o.isNil(l.reverseOrder)&&(l.reverseOrder=!0)}new s[c](l).processAdjust(t),"Stack"===c&&r&&e._updateStackRange(u,r,t)})},e.prototype.setCoord=function(t){this.set("coord",t);var e=this.getAttr("position");this.get("shapeContainer").setMatrix(t.matrix),e&&(e.coord=t)},e.prototype.paint=function(){var t=this.get("dataArray"),e=[],n=this.getShapeFactory();n.setCoord(this.get("coord"));var r=this.get("shapeContainer");this._beforeMapping(t);for(var i=0;i<t.length;i++){var a=t[i],s=i;a=this._mapping(a),e.push(a),this.draw(a,r,n,s)}this.get("labelCfg")&&this._addLabels(o.union.apply(null,e)),this.get("sortable")?this.set("dataArray",e):this._sort(e)},e.prototype._sort=function(t){var e=this.getXScale(),n=e.field;o.each(t,function(t){t.sort(function(t,r){return e.translate(t._origin[n])-e.translate(r._origin[n])})}),this.set("dataArray",t)},e.prototype._beforeMapping=function(t){var e=this;if(e.get("sortable")){var n=e.getXScale(),r=n.field;o.each(t,function(t){t.sort(function(t,e){return n.translate(t[r])-n.translate(e[r])})})}e.get("generatePoints")&&(o.each(t,function(t){e._generatePoints(t)}),o.each(t,function(e,n){var r=t[n+1];r&&(e[0].nextPoints=r[0].points)}))},e.prototype._addLabels=function(t){var e=this,n=e.get("type"),r=e.get("coord"),i=u.getLabelsClass(r.type,n),a=e.get("container"),s=o.map(e.get("labelCfg").fields,function(t){return e._createScale(t)}),l=a.addGroup(i,{_id:this.get("_id"),labelCfg:o.mix({scales:s},e.get("labelCfg")),coord:r,geom:e,geomType:n,visible:e.get("visible")});l.showLabels(t),e.set("labelContainer",l)},e.prototype.getShapeFactory=function(){var t=this.get("shapeFactory");if(!t){var e=this.get("shapeType");t=l.getShapeFactory(e),this.set("shapeFactory",t)}return t},e.prototype._generatePoints=function(t){for(var e=this.getShapeFactory(),n=this.getAttr("shape"),r=0;r<t.length;r++){var i=t[r],o=this.createShapePointsCfg(i),a=n?this._getAttrValues(n,i):null,s=e.getShapePoints(a,o);i.points=s}},e.prototype.createShapePointsCfg=function(t){var e=this.getXScale(),n=this.getYScale();return{x:this._normalizeValues(t[e.field],e),y:n?this._normalizeValues(t[n.field],n):t.y?t.y:.1,y0:n?n.scale(this.getYMinValue()):void 0}},e.prototype.getYMinValue=function(){var t=this.getYScale().min;return t>=0?t:0},e.prototype._normalizeValues=function(t,e){var n=[];if(o.isArray(t))for(var r=0;r<t.length;r++){var i=t[r];n.push(e.scale(i))}else n=e.scale(t);return n},e.prototype._mapping=function(t){for(var e=this.get("attrs"),n=[],r=0;r<t.length;r++){var i=t[r],a={};for(var s in a._origin=i._origin,a.points=i.points,a.nextPoints=i.nextPoints,e)if(e.hasOwnProperty(s)){var u=e[s],l=u.names,c=this._getAttrValues(u,i);if(l.length>1)for(var h=0;h<c.length;h++){var f=c[h];a[l[h]]=o.isArray(f)&&1===f.length?f[0]:f}else a[l[0]]=1===c.length?c[0]:c}n.push(a)}return n},e.prototype._getAttrValues=function(t,e){for(var n=t.scales,r=[],i=0;i<n.length;i++){var o=n[i],a=o.field;"identity"===o.type?r.push(o.value):r.push(e[a])}return t.mapping.apply(t,r)},e.prototype.getAttrValue=function(t,e){var n=this.getAttr(t),r=null;n&&(r=this._getAttrValues(n,e)[0]);return r},e.prototype.getDefaultValue=function(t){var e=this.get(t),n=this.getAttr(t);if(n){var r=n.getScale(t);"identity"===r.type&&(e=r.value)}return e},e.prototype.draw=function(t,e,n,r){for(var i=0;i<t.length;i++){var o=t[i];this.drawPoint(o,e,n,r+i)}},e.prototype.getCallbackCfg=function(t,e,n){if(!t)return e;var r={},i=t.map(function(t){return n[t]});return o.each(e,function(t,e){o.isFunction(t)?r[e]=t.apply(null,i):r[e]=t}),r},e.prototype._getShapeId=function(t){var e=this.get("_id"),n=this.get("keyFields");if(n&&n.length>0)o.each(n,function(n){e+="-"+t[n]});else{var r=this.get("type"),i=this.getXScale(),a=this.getYScale(),s=i.field||"x",u=a.field||"y",l=t[u],c=void 0;c=i.isIdentity?i.value:t[s],e+="interval"===r||"schema"===r?"-"+c:"line"===r||"area"===r||"path"===r?"-"+r:"-"+c+"-"+l;var h=this._getGroupScales();o.isEmpty(h)||o.each(h,function(n){var r=n.field;"identity"!==n.type&&(e+="-"+t[r])})}return e},e.prototype.getDrawCfg=function(t){var e={origin:t,x:t.x,y:t.y,color:t.color,size:t.size,shape:t.shape,isInCircle:this.isInCircle(),opacity:t.opacity},n=this.get("styleOptions");return n&&n.style&&(e.style=this.getCallbackCfg(n.fields,n.style,t._origin)),this.get("generatePoints")&&(e.points=t.points,e.nextPoints=t.nextPoints),this.get("animate")&&(e._id=this._getShapeId(t._origin)),e},e.prototype.appendShapeInfo=function(t,e){t&&(t.setSilent("index",e),t.setSilent("coord",this.get("coord")),this.get("animate")&&this.get("animateCfg")&&t.setSilent("animateCfg",this.get("animateCfg")))},e.prototype.drawPoint=function(t,e,n,r){var i=t.shape,o=this.getDrawCfg(t),a=n.drawShape(i,o,e);this.appendShapeInfo(a,r)},e.prototype.getAttr=function(t){return this.get("attrs")[t]},e.prototype.getXScale=function(){return this.getAttr("position").scales[0]},e.prototype.getYScale=function(){return this.getAttr("position").scales[1]},e.prototype.getShapes=function(){var t=[],e=this.get("shapeContainer").get("children");return o.each(e,function(e){e.get("origin")&&t.push(e)}),t},e.prototype.getAttrsForLegend=function(){var t=this.get("attrs"),e=[];return o.each(t,function(t){-1!==p.indexOf(t.type)&&e.push(t)}),e},e.prototype.getFieldsForLegend=function(){var t=[],e=this.get("attrOptions");return o.each(p,function(n){var r=e[n];r&&r.field&&o.isString(r.field)&&(t=t.concat(r.field.split("*")))}),o.uniq(t)},e.prototype.changeVisible=function(t,e){var n=this.get("shapeContainer");n.set("visible",t);var r=this.get("labelContainer");(r&&r.set("visible",t),e)||n.get("canvas").draw()},e.prototype.reset=function(){this.set("attrOptions",{}),this.clearInner()},e.prototype.clearInner=function(){this.clearActivedShapes(),this.clearSelected();var t=this.get("shapeContainer");t&&t.clear();var e=this.get("labelContainer");e&&e.remove(),this.set("attrs",{}),this.set("groupScales",null),this.set("labelContainer",null),this.set("xDistance",null),this.set("isStacked",null)},e.prototype.clear=function(){this.clearInner(),this.set("scales",{})},e.prototype.destroy=function(){this.clear();var e=this.get("shapeContainer");e&&e.remove(),this.offEvents(),t.prototype.destroy.call(this)},e.prototype.bindEvents=function(){this.get("view")&&(this._bindActiveAction(),this._bindSelectedAction())},e.prototype.offEvents=function(){this.get("view")&&(this._offActiveAction(),this._offSelectedAction())},e}(r);t.exports=v},function(t,e,n){"use strict";n.r(e);var r="http://www.w3.org/1999/xhtml",i={svg:"http://www.w3.org/2000/svg",xhtml:r,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"},o=function(t){var e=t+="",n=e.indexOf(":");return n>=0&&"xmlns"!==(e=t.slice(0,n))&&(t=t.slice(n+1)),i.hasOwnProperty(e)?{space:i[e],local:t}:t};var a=function(t){var e=o(t);return(e.local?function(t){return function(){return this.ownerDocument.createElementNS(t.space,t.local)}}:function(t){return function(){var e=this.ownerDocument,n=this.namespaceURI;return n===r&&e.documentElement.namespaceURI===r?e.createElement(t):e.createElementNS(n,t)}})(e)};function s(){}var u=function(t){return null==t?s:function(){return this.querySelector(t)}};function l(){return[]}var c=function(t){return null==t?l:function(){return this.querySelectorAll(t)}},h=function(t){return function(){return this.matches(t)}};if("undefined"!=typeof document){var f=document.documentElement;if(!f.matches){var p=f.webkitMatchesSelector||f.msMatchesSelector||f.mozMatchesSelector||f.oMatchesSelector;h=function(t){return function(){return p.call(this,t)}}}}var d=h,g=function(t){return new Array(t.length)};function v(t,e){this.ownerDocument=t.ownerDocument,this.namespaceURI=t.namespaceURI,this._next=null,this._parent=t,this.__data__=e}v.prototype={constructor:v,appendChild:function(t){return this._parent.insertBefore(t,this._next)},insertBefore:function(t,e){return this._parent.insertBefore(t,e)},querySelector:function(t){return this._parent.querySelector(t)},querySelectorAll:function(t){return this._parent.querySelectorAll(t)}};var y="$";function m(t,e,n,r,i,o){for(var a,s=0,u=e.length,l=o.length;s<l;++s)(a=e[s])?(a.__data__=o[s],r[s]=a):n[s]=new v(t,o[s]);for(;s<u;++s)(a=e[s])&&(i[s]=a)}function x(t,e,n,r,i,o,a){var s,u,l,c={},h=e.length,f=o.length,p=new Array(h);for(s=0;s<h;++s)(u=e[s])&&(p[s]=l=y+a.call(u,u.__data__,s,e),l in c?i[s]=u:c[l]=u);for(s=0;s<f;++s)(u=c[l=y+a.call(t,o[s],s,o)])?(r[s]=u,u.__data__=o[s],c[l]=null):n[s]=new v(t,o[s]);for(s=0;s<h;++s)(u=e[s])&&c[p[s]]===u&&(i[s]=u)}function b(t,e){return t<e?-1:t>e?1:t>=e?0:NaN}var _=function(t){return t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView};function w(t,e){return t.style.getPropertyValue(e)||_(t).getComputedStyle(t,null).getPropertyValue(e)}function S(t){return t.trim().split(/^|\s+/)}function M(t){return t.classList||new C(t)}function C(t){this._node=t,this._names=S(t.getAttribute("class")||"")}function P(t,e){for(var n=M(t),r=-1,i=e.length;++r<i;)n.add(e[r])}function A(t,e){for(var n=M(t),r=-1,i=e.length;++r<i;)n.remove(e[r])}C.prototype={add:function(t){this._names.indexOf(t)<0&&(this._names.push(t),this._node.setAttribute("class",this._names.join(" ")))},remove:function(t){var e=this._names.indexOf(t);e>=0&&(this._names.splice(e,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(t){return this._names.indexOf(t)>=0}};function I(){this.textContent=""}function O(){this.innerHTML=""}function E(){this.nextSibling&&this.parentNode.appendChild(this)}function T(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function k(){return null}function j(){var t=this.parentNode;t&&t.removeChild(this)}function L(){return this.parentNode.insertBefore(this.cloneNode(!1),this.nextSibling)}function D(){return this.parentNode.insertBefore(this.cloneNode(!0),this.nextSibling)}var F={},R=null;"undefined"!=typeof document&&("onmouseenter"in document.documentElement||(F={mouseenter:"mouseover",mouseleave:"mouseout"}));function B(t,e,n){return t=N(t,e,n),function(e){var n=e.relatedTarget;n&&(n===this||8&n.compareDocumentPosition(this))||t.call(this,e)}}function N(t,e,n){return function(r){var i=R;R=r;try{t.call(this,this.__data__,e,n)}finally{R=i}}}function z(t){return function(){var e=this.__on;if(e){for(var n,r=0,i=-1,o=e.length;r<o;++r)n=e[r],t.type&&n.type!==t.type||n.name!==t.name?e[++i]=n:this.removeEventListener(n.type,n.listener,n.capture);++i?e.length=i:delete this.__on}}}function V(t,e,n){var r=F.hasOwnProperty(t.type)?B:N;return function(i,o,a){var s,u=this.__on,l=r(e,o,a);if(u)for(var c=0,h=u.length;c<h;++c)if((s=u[c]).type===t.type&&s.name===t.name)return this.removeEventListener(s.type,s.listener,s.capture),this.addEventListener(s.type,s.listener=l,s.capture=n),void(s.value=e);this.addEventListener(t.type,l,n),s={type:t.type,name:t.name,value:e,listener:l,capture:n},u?u.push(s):this.__on=[s]}}function G(t,e,n,r){var i=R;t.sourceEvent=R,R=t;try{return e.apply(n,r)}finally{R=i}}function Y(t,e,n){var r=_(t),i=r.CustomEvent;"function"==typeof i?i=new i(e,n):(i=r.document.createEvent("Event"),n?(i.initEvent(e,n.bubbles,n.cancelable),i.detail=n.detail):i.initEvent(e,!1,!1)),t.dispatchEvent(i)}var W=[null];function X(t,e){this._groups=t,this._parents=e}function q(){return new X([[document.documentElement]],W)}X.prototype=q.prototype={constructor:X,select:function(t){"function"!=typeof t&&(t=u(t));for(var e=this._groups,n=e.length,r=new Array(n),i=0;i<n;++i)for(var o,a,s=e[i],l=s.length,c=r[i]=new Array(l),h=0;h<l;++h)(o=s[h])&&(a=t.call(o,o.__data__,h,s))&&("__data__"in o&&(a.__data__=o.__data__),c[h]=a);return new X(r,this._parents)},selectAll:function(t){"function"!=typeof t&&(t=c(t));for(var e=this._groups,n=e.length,r=[],i=[],o=0;o<n;++o)for(var a,s=e[o],u=s.length,l=0;l<u;++l)(a=s[l])&&(r.push(t.call(a,a.__data__,l,s)),i.push(a));return new X(r,i)},filter:function(t){"function"!=typeof t&&(t=d(t));for(var e=this._groups,n=e.length,r=new Array(n),i=0;i<n;++i)for(var o,a=e[i],s=a.length,u=r[i]=[],l=0;l<s;++l)(o=a[l])&&t.call(o,o.__data__,l,a)&&u.push(o);return new X(r,this._parents)},data:function(t,e){if(!t)return d=new Array(this.size()),c=-1,this.each(function(t){d[++c]=t}),d;var n,r=e?x:m,i=this._parents,o=this._groups;"function"!=typeof t&&(n=t,t=function(){return n});for(var a=o.length,s=new Array(a),u=new Array(a),l=new Array(a),c=0;c<a;++c){var h=i[c],f=o[c],p=f.length,d=t.call(h,h&&h.__data__,c,i),g=d.length,v=u[c]=new Array(g),y=s[c]=new Array(g);r(h,f,v,y,l[c]=new Array(p),d,e);for(var b,_,w=0,S=0;w<g;++w)if(b=v[w]){for(w>=S&&(S=w+1);!(_=y[S])&&++S<g;);b._next=_||null}}return(s=new X(s,i))._enter=u,s._exit=l,s},enter:function(){return new X(this._enter||this._groups.map(g),this._parents)},exit:function(){return new X(this._exit||this._groups.map(g),this._parents)},merge:function(t){for(var e=this._groups,n=t._groups,r=e.length,i=n.length,o=Math.min(r,i),a=new Array(r),s=0;s<o;++s)for(var u,l=e[s],c=n[s],h=l.length,f=a[s]=new Array(h),p=0;p<h;++p)(u=l[p]||c[p])&&(f[p]=u);for(;s<r;++s)a[s]=e[s];return new X(a,this._parents)},order:function(){for(var t=this._groups,e=-1,n=t.length;++e<n;)for(var r,i=t[e],o=i.length-1,a=i[o];--o>=0;)(r=i[o])&&(a&&a!==r.nextSibling&&a.parentNode.insertBefore(r,a),a=r);return this},sort:function(t){function e(e,n){return e&&n?t(e.__data__,n.__data__):!e-!n}t||(t=b);for(var n=this._groups,r=n.length,i=new Array(r),o=0;o<r;++o){for(var a,s=n[o],u=s.length,l=i[o]=new Array(u),c=0;c<u;++c)(a=s[c])&&(l[c]=a);l.sort(e)}return new X(i,this._parents).order()},call:function(){var t=arguments[0];return arguments[0]=this,t.apply(null,arguments),this},nodes:function(){var t=new Array(this.size()),e=-1;return this.each(function(){t[++e]=this}),t},node:function(){for(var t=this._groups,e=0,n=t.length;e<n;++e)for(var r=t[e],i=0,o=r.length;i<o;++i){var a=r[i];if(a)return a}return null},size:function(){var t=0;return this.each(function(){++t}),t},empty:function(){return!this.node()},each:function(t){for(var e=this._groups,n=0,r=e.length;n<r;++n)for(var i,o=e[n],a=0,s=o.length;a<s;++a)(i=o[a])&&t.call(i,i.__data__,a,o);return this},attr:function(t,e){var n=o(t);if(arguments.length<2){var r=this.node();return n.local?r.getAttributeNS(n.space,n.local):r.getAttribute(n)}return this.each((null==e?n.local?function(t){return function(){this.removeAttributeNS(t.space,t.local)}}:function(t){return function(){this.removeAttribute(t)}}:"function"==typeof e?n.local?function(t,e){return function(){var n=e.apply(this,arguments);null==n?this.removeAttributeNS(t.space,t.local):this.setAttributeNS(t.space,t.local,n)}}:function(t,e){return function(){var n=e.apply(this,arguments);null==n?this.removeAttribute(t):this.setAttribute(t,n)}}:n.local?function(t,e){return function(){this.setAttributeNS(t.space,t.local,e)}}:function(t,e){return function(){this.setAttribute(t,e)}})(n,e))},style:function(t,e,n){return arguments.length>1?this.each((null==e?function(t){return function(){this.style.removeProperty(t)}}:"function"==typeof e?function(t,e,n){return function(){var r=e.apply(this,arguments);null==r?this.style.removeProperty(t):this.style.setProperty(t,r,n)}}:function(t,e,n){return function(){this.style.setProperty(t,e,n)}})(t,e,null==n?"":n)):w(this.node(),t)},property:function(t,e){return arguments.length>1?this.each((null==e?function(t){return function(){delete this[t]}}:"function"==typeof e?function(t,e){return function(){var n=e.apply(this,arguments);null==n?delete this[t]:this[t]=n}}:function(t,e){return function(){this[t]=e}})(t,e)):this.node()[t]},classed:function(t,e){var n=S(t+"");if(arguments.length<2){for(var r=M(this.node()),i=-1,o=n.length;++i<o;)if(!r.contains(n[i]))return!1;return!0}return this.each(("function"==typeof e?function(t,e){return function(){(e.apply(this,arguments)?P:A)(this,t)}}:e?function(t){return function(){P(this,t)}}:function(t){return function(){A(this,t)}})(n,e))},text:function(t){return arguments.length?this.each(null==t?I:("function"==typeof t?function(t){return function(){var e=t.apply(this,arguments);this.textContent=null==e?"":e}}:function(t){return function(){this.textContent=t}})(t)):this.node().textContent},html:function(t){return arguments.length?this.each(null==t?O:("function"==typeof t?function(t){return function(){var e=t.apply(this,arguments);this.innerHTML=null==e?"":e}}:function(t){return function(){this.innerHTML=t}})(t)):this.node().innerHTML},raise:function(){return this.each(E)},lower:function(){return this.each(T)},append:function(t){var e="function"==typeof t?t:a(t);return this.select(function(){return this.appendChild(e.apply(this,arguments))})},insert:function(t,e){var n="function"==typeof t?t:a(t),r=null==e?k:"function"==typeof e?e:u(e);return this.select(function(){return this.insertBefore(n.apply(this,arguments),r.apply(this,arguments)||null)})},remove:function(){return this.each(j)},clone:function(t){return this.select(t?D:L)},datum:function(t){return arguments.length?this.property("__data__",t):this.node().__data__},on:function(t,e,n){var r,i,o=function(t){return t.trim().split(/^|\s+/).map(function(t){var e="",n=t.indexOf(".");return n>=0&&(e=t.slice(n+1),t=t.slice(0,n)),{type:t,name:e}})}(t+""),a=o.length;if(!(arguments.length<2)){for(s=e?V:z,null==n&&(n=!1),r=0;r<a;++r)this.each(s(o[r],e,n));return this}var s=this.node().__on;if(s)for(var u,l=0,c=s.length;l<c;++l)for(r=0,u=s[l];r<a;++r)if((i=o[r]).type===u.type&&i.name===u.name)return u.value},dispatch:function(t,e){return this.each(("function"==typeof e?function(t,e){return function(){return Y(this,t,e.apply(this,arguments))}}:function(t,e){return function(){return Y(this,t,e)}})(t,e))}};var H=q,U=function(t){return"string"==typeof t?new X([[document.querySelector(t)]],[document.documentElement]):new X([[t]],W)},Z=function(t){return U(a(t).call(document.documentElement))},Q=0;function $(){return new J}function J(){this._="@"+(++Q).toString(36)}J.prototype=$.prototype={constructor:J,get:function(t){for(var e=this._;!(e in t);)if(!(t=t.parentNode))return;return t[e]},set:function(t,e){return t[this._]=e},remove:function(t){return this._ in t&&delete t[this._]},toString:function(){return this._}};var K=function(){for(var t,e=R;t=e.sourceEvent;)e=t;return e},tt=function(t,e){var n=t.ownerSVGElement||t;if(n.createSVGPoint){var r=n.createSVGPoint();return r.x=e.clientX,r.y=e.clientY,[(r=r.matrixTransform(t.getScreenCTM().inverse())).x,r.y]}var i=t.getBoundingClientRect();return[e.clientX-i.left-t.clientLeft,e.clientY-i.top-t.clientTop]},et=function(t){var e=K();return e.changedTouches&&(e=e.changedTouches[0]),tt(t,e)},nt=function(t){return"string"==typeof t?new X([document.querySelectorAll(t)],[document.documentElement]):new X([null==t?[]:t],W)},rt=function(t,e,n){arguments.length<3&&(n=e,e=K().changedTouches);for(var r,i=0,o=e?e.length:0;i<o;++i)if((r=e[i]).identifier===n)return tt(t,r);return null},it=function(t,e){null==e&&(e=K().touches);for(var n=0,r=e?e.length:0,i=new Array(r);n<r;++n)i[n]=tt(t,e[n]);return i};n.d(e,"create",function(){return Z}),n.d(e,"creator",function(){return a}),n.d(e,"local",function(){return $}),n.d(e,"matcher",function(){return d}),n.d(e,"mouse",function(){return et}),n.d(e,"namespace",function(){return o}),n.d(e,"namespaces",function(){return i}),n.d(e,"clientPoint",function(){return tt}),n.d(e,"select",function(){return U}),n.d(e,"selectAll",function(){return nt}),n.d(e,"selection",function(){return H}),n.d(e,"selector",function(){return u}),n.d(e,"selectorAll",function(){return c}),n.d(e,"style",function(){return w}),n.d(e,"touch",function(){return rt}),n.d(e,"touches",function(){return it}),n.d(e,"window",function(){return _}),n.d(e,"event",function(){return R}),n.d(e,"customEvent",function(){return G})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),i=n(1),o=s(i),a=s(n(0));function s(t){return t&&t.__esModule?t:{default:t}}function u(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function l(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function c(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}var h=function(t){function e(t,n){u(this,e);var r=l(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t));return r.getParentInfo=function(){return{id:r.id,name:r.name}},r.name=n,r}return c(e,i.Component),r(e,[{key:"getChildContext",value:function(){return{addElement:this.context.addElement,updateElement:this.context.updateElement,deleteElement:this.context.deleteElement,createId:this.context.createId,getParentInfo:this.getParentInfo,getViewId:this.context.getViewId}}},{key:"componentWillMount",value:function(){var t=this.context;this.id=t.createId(),t.addElement(this.name,this.id,this.props,t.getParentInfo(),t.getViewId())}},{key:"componentWillReceiveProps",value:function(t){this.context.updateElement(this.name,this.id,t,this.context.getParentInfo(),this.context.getViewId())}},{key:"componentWillUnmount",value:function(){this.context.deleteElement(this.name,this.id)}},{key:"render",value:function(){var t=this.props.children;return t?t.length&&(t=o.default.createElement("div",null,t)):t=null,t}}]),e}();h.contextTypes={addElement:a.default.func,updateElement:a.default.func,deleteElement:a.default.func,createId:a.default.func,getParentInfo:a.default.func,getViewId:a.default.func},h.childContextTypes={addElement:a.default.func,updateElement:a.default.func,deleteElement:a.default.func,createId:a.default.func,getParentInfo:a.default.func,getViewId:a.default.func},h.generateBaseTypedComponent=function(t){var e=function(e){function n(e){return u(this,n),l(this,(n.__proto__||Object.getPrototypeOf(n)).call(this,e,t))}return c(n,h),r(n,[{key:"getChildContext",value:function(){return{addElement:this.context.addElement,updateElement:this.context.updateElement,deleteElement:this.context.deleteElement,createId:this.context.createId,getParentInfo:this.getParentInfo,getViewId:this.context.getViewId}}}]),n}();return e.contextTypes={addElement:a.default.func,updateElement:a.default.func,deleteElement:a.default.func,createId:a.default.func,getParentInfo:a.default.func,getViewId:a.default.func},e.childContextTypes={addElement:a.default.func,updateElement:a.default.func,deleteElement:a.default.func,createId:a.default.func,getParentInfo:a.default.func,getViewId:a.default.func},e},e.default=h},,,function(t,e,n){"use strict";var r=function(t,e,n){t.prototype=e.prototype=n,n.constructor=t};function i(t,e){var n=Object.create(t.prototype);for(var r in e)n[r]=e[r];return n}function o(){}var a="\\s*([+-]?\\d+)\\s*",s="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)\\s*",u="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)%\\s*",l=/^#([0-9a-f]{3})$/,c=/^#([0-9a-f]{6})$/,h=new RegExp("^rgb\\("+[a,a,a]+"\\)$"),f=new RegExp("^rgb\\("+[u,u,u]+"\\)$"),p=new RegExp("^rgba\\("+[a,a,a,s]+"\\)$"),d=new RegExp("^rgba\\("+[u,u,u,s]+"\\)$"),g=new RegExp("^hsl\\("+[s,u,u]+"\\)$"),v=new RegExp("^hsla\\("+[s,u,u,s]+"\\)$"),y={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 m(t){var e;return t=(t+"").trim().toLowerCase(),(e=l.exec(t))?new S((e=parseInt(e[1],16))>>8&15|e>>4&240,e>>4&15|240&e,(15&e)<<4|15&e,1):(e=c.exec(t))?x(parseInt(e[1],16)):(e=h.exec(t))?new S(e[1],e[2],e[3],1):(e=f.exec(t))?new S(255*e[1]/100,255*e[2]/100,255*e[3]/100,1):(e=p.exec(t))?b(e[1],e[2],e[3],e[4]):(e=d.exec(t))?b(255*e[1]/100,255*e[2]/100,255*e[3]/100,e[4]):(e=g.exec(t))?C(e[1],e[2]/100,e[3]/100,1):(e=v.exec(t))?C(e[1],e[2]/100,e[3]/100,e[4]):y.hasOwnProperty(t)?x(y[t]):"transparent"===t?new S(NaN,NaN,NaN,0):null}function x(t){return new S(t>>16&255,t>>8&255,255&t,1)}function b(t,e,n,r){return r<=0&&(t=e=n=NaN),new S(t,e,n,r)}function _(t){return t instanceof o||(t=m(t)),t?new S((t=t.rgb()).r,t.g,t.b,t.opacity):new S}function w(t,e,n,r){return 1===arguments.length?_(t):new S(t,e,n,null==r?1:r)}function S(t,e,n,r){this.r=+t,this.g=+e,this.b=+n,this.opacity=+r}function M(t){return((t=Math.max(0,Math.min(255,Math.round(t)||0)))<16?"0":"")+t.toString(16)}function C(t,e,n,r){return r<=0?t=e=n=NaN:n<=0||n>=1?t=e=NaN:e<=0&&(t=NaN),new A(t,e,n,r)}function P(t,e,n,r){return 1===arguments.length?function(t){if(t instanceof A)return new A(t.h,t.s,t.l,t.opacity);if(t instanceof o||(t=m(t)),!t)return new A;if(t instanceof A)return t;var e=(t=t.rgb()).r/255,n=t.g/255,r=t.b/255,i=Math.min(e,n,r),a=Math.max(e,n,r),s=NaN,u=a-i,l=(a+i)/2;return u?(s=e===a?(n-r)/u+6*(n<r):n===a?(r-e)/u+2:(e-n)/u+4,u/=l<.5?a+i:2-a-i,s*=60):u=l>0&&l<1?0:s,new A(s,u,l,t.opacity)}(t):new A(t,e,n,null==r?1:r)}function A(t,e,n,r){this.h=+t,this.s=+e,this.l=+n,this.opacity=+r}function I(t,e,n){return 255*(t<60?e+(n-e)*t/60:t<180?n:t<240?e+(n-e)*(240-t)/60:e)}r(o,m,{displayable:function(){return this.rgb().displayable()},hex:function(){return this.rgb().hex()},toString:function(){return this.rgb()+""}}),r(S,w,i(o,{brighter:function(t){return t=null==t?1/.7:Math.pow(1/.7,t),new S(this.r*t,this.g*t,this.b*t,this.opacity)},darker:function(t){return t=null==t?.7:Math.pow(.7,t),new S(this.r*t,this.g*t,this.b*t,this.opacity)},rgb:function(){return this},displayable:function(){return 0<=this.r&&this.r<=255&&0<=this.g&&this.g<=255&&0<=this.b&&this.b<=255&&0<=this.opacity&&this.opacity<=1},hex:function(){return"#"+M(this.r)+M(this.g)+M(this.b)},toString:function(){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+")")}})),r(A,P,i(o,{brighter:function(t){return t=null==t?1/.7:Math.pow(1/.7,t),new A(this.h,this.s,this.l*t,this.opacity)},darker:function(t){return t=null==t?.7:Math.pow(.7,t),new A(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,r=n+(n<.5?n:1-n)*e,i=2*n-r;return new S(I(t>=240?t-240:t+120,i,r),I(t,i,r),I(t<120?t+240:t-120,i,r),this.opacity)},displayable:function(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1}}));var O=Math.PI/180,E=180/Math.PI,T=.96422,k=1,j=.82521,L=4/29,D=6/29,F=3*D*D,R=D*D*D;function B(t){if(t instanceof V)return new V(t.l,t.a,t.b,t.opacity);if(t instanceof Z){if(isNaN(t.h))return new V(t.l,0,0,t.opacity);var e=t.h*O;return new V(t.l,Math.cos(e)*t.c,Math.sin(e)*t.c,t.opacity)}t instanceof S||(t=_(t));var n,r,i=X(t.r),o=X(t.g),a=X(t.b),s=G((.2225045*i+.7168786*o+.0606169*a)/k);return i===o&&o===a?n=r=s:(n=G((.4360747*i+.3850649*o+.1430804*a)/T),r=G((.0139322*i+.0971045*o+.7141733*a)/j)),new V(116*s-16,500*(n-s),200*(s-r),t.opacity)}function N(t,e){return new V(t,0,0,null==e?1:e)}function z(t,e,n,r){return 1===arguments.length?B(t):new V(t,e,n,null==r?1:r)}function V(t,e,n,r){this.l=+t,this.a=+e,this.b=+n,this.opacity=+r}function G(t){return t>R?Math.pow(t,1/3):t/F+L}function Y(t){return t>D?t*t*t:F*(t-L)}function W(t){return 255*(t<=.0031308?12.92*t:1.055*Math.pow(t,1/2.4)-.055)}function X(t){return(t/=255)<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)}function q(t){if(t instanceof Z)return new Z(t.h,t.c,t.l,t.opacity);if(t instanceof V||(t=B(t)),0===t.a&&0===t.b)return new Z(NaN,0,t.l,t.opacity);var e=Math.atan2(t.b,t.a)*E;return new Z(e<0?e+360:e,Math.sqrt(t.a*t.a+t.b*t.b),t.l,t.opacity)}function H(t,e,n,r){return 1===arguments.length?q(t):new Z(n,e,t,null==r?1:r)}function U(t,e,n,r){return 1===arguments.length?q(t):new Z(t,e,n,null==r?1:r)}function Z(t,e,n,r){this.h=+t,this.c=+e,this.l=+n,this.opacity=+r}r(V,z,i(o,{brighter:function(t){return new V(this.l+18*(null==t?1:t),this.a,this.b,this.opacity)},darker:function(t){return new V(this.l-18*(null==t?1:t),this.a,this.b,this.opacity)},rgb:function(){var t=(this.l+16)/116,e=isNaN(this.a)?t:t+this.a/500,n=isNaN(this.b)?t:t-this.b/200;return new S(W(3.1338561*(e=T*Y(e))-1.6168667*(t=k*Y(t))-.4906146*(n=j*Y(n))),W(-.9787684*e+1.9161415*t+.033454*n),W(.0719453*e-.2289914*t+1.4052427*n),this.opacity)}})),r(Z,U,i(o,{brighter:function(t){return new Z(this.h,this.c,this.l+18*(null==t?1:t),this.opacity)},darker:function(t){return new Z(this.h,this.c,this.l-18*(null==t?1:t),this.opacity)},rgb:function(){return B(this).rgb()}}));var Q=-.14861,$=1.78277,J=-.29227,K=-.90649,tt=1.97294,et=tt*K,nt=tt*$,rt=$*J-K*Q;function it(t,e,n,r){return 1===arguments.length?function(t){if(t instanceof ot)return new ot(t.h,t.s,t.l,t.opacity);t instanceof S||(t=_(t));var e=t.r/255,n=t.g/255,r=t.b/255,i=(rt*r+et*e-nt*n)/(rt+et-nt),o=r-i,a=(tt*(n-i)-J*o)/K,s=Math.sqrt(a*a+o*o)/(tt*i*(1-i)),u=s?Math.atan2(a,o)*E-120:NaN;return new ot(u<0?u+360:u,s,i,t.opacity)}(t):new ot(t,e,n,null==r?1:r)}function ot(t,e,n,r){this.h=+t,this.s=+e,this.l=+n,this.opacity=+r}r(ot,it,i(o,{brighter:function(t){return t=null==t?1/.7:Math.pow(1/.7,t),new ot(this.h,this.s,this.l*t,this.opacity)},darker:function(t){return t=null==t?.7:Math.pow(.7,t),new ot(this.h,this.s,this.l*t,this.opacity)},rgb:function(){var t=isNaN(this.h)?0:(this.h+120)*O,e=+this.l,n=isNaN(this.s)?0:this.s*e*(1-e),r=Math.cos(t),i=Math.sin(t);return new S(255*(e+n*(Q*r+$*i)),255*(e+n*(J*r+K*i)),255*(e+n*(tt*r)),this.opacity)}})),n.d(e,"a",function(){return m}),n.d(e,"f",function(){return w}),n.d(e,"d",function(){return P}),n.d(e,"e",function(){return z}),n.d(e,"c",function(){return U}),n.d(e,!1,function(){return H}),n.d(e,!1,function(){return N}),n.d(e,"b",function(){return it})},function(t,e,n){var r=n(549),i=n(832);function o(t,e){var n=t.getCenter();return Math.sqrt(Math.pow(e.x-n.x,2)+Math.pow(e.y-n.y,2))}function a(t,e){for(var n=t.length,r=[t[0]],i=1;i<n;i+=2){var o=e.convertPoint({x:t[i],y:t[i+1]});r.push(o.x,o.y)}return r}var s={getLinePath:function(t,e){return function(t,e){if(!t.length)return[];for(var n=[],r=0,i=t.length;r<i;r++){var o=t[r];0===r?n.push(["M",o.x,o.y]):n.push(["L",o.x,o.y])}return e&&n.push(["Z"]),n}(t,e)},getSplinePath:function(t,e,n){var o=[],a=t[0],u=null;if(t.length<=2)return s.getLinePath(t,e);r.each(t,function(t){u&&u.x===t.x&&u.y===t.y||(o.push(t.x),o.push(t.y),u=t)}),n=n||[[0,0],[1,1]];var l=i.catmullRom2bezier(o,e,n);return l.unshift(["M",a.x,a.y]),l},getPointRadius:function(t,e){return o(t,e)},getPointAngle:function(t,e){var n=t.getCenter();return Math.atan2(e.y-n.y,e.x-n.x)},convertNormalPath:function(t,e){var n=[];return r.each(e,function(e){switch(e[0].toLowerCase()){case"m":case"l":case"c":n.push(a(e,t));break;case"z":default:n.push(e)}}),n},convertPolarPath:function(t,e){var n=[],i=void 0,s=void 0,u=void 0;return r.each(e,function(r,l){switch(r[0].toLowerCase()){case"m":case"c":case"q":n.push(a(r,t));break;case"l":i=e[l-1],s=r,u=t.isTransposed,(u?i[i.length-2]===s[1]:i[i.length-1]===s[2])?n=n.concat(function(t,e,n){var r=n.isTransposed,i=n.startAngle,a=n.endAngle,s={x:t[1],y:t[2]},u={x:e[1],y:e[2]},l=[],c=r?"y":"x",h=Math.abs(u[c]-s[c])*(a-i),f=u[c]>=s[c]?1:0,p=h>Math.PI?1:0,d=n.convertPoint(u),g=o(n,d);if(g>=.5)if(h===2*Math.PI){var v={x:(u.x+s.x)/2,y:(u.y+s.y)/2},y=n.convertPoint(v);l.push(["A",g,g,0,p,f,y.x,y.y]),l.push(["A",g,g,0,p,f,d.x,d.y])}else l.push(["A",g,g,0,p,f,d.x,d.y]);return l}(i,s,t)):n.push(a(r,t));break;case"z":default:n.push(r)}}),function(t){r.each(t,function(e,n){if("a"===e[0].toLowerCase()){var r=t[n-1],i=t[n+1];i&&"a"===i[0].toLowerCase()?r&&"l"===r[0].toLowerCase()&&(r[0]="M"):r&&"a"===r[0].toLowerCase()&&i&&"l"===i[0].toLowerCase()&&(i[0]="M")}})}(n),n}};t.exports=s},,,,function(t,e,n){var r=n(549),i=["min","max","median"];function o(t){var e=void 0;return r.each(t,function(t){if(t)return e=t,!1}),e}var a=function(){function t(e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t);var n=this.getDefaultCfg();e=r.deepMix({},n,e),r.mix(this,e)}return t.prototype.getDefaultCfg=function(){return{zIndex:1,xScales:null,yScales:null,el:null}},t.prototype._getNormalizedValue=function(t,e){var n=void 0;if(-1!==r.indexOf(i,t)){var o=void 0;"median"===t?(o=e.isCategory?(e.values.length-1)/2:(e.min+e.max)/2,n=e.scale(o)):(o=e.isCategory?"min"===t?0:e.values.length-1:e[t],n=e.scale(o))}else n=e.scale(t);return n},t.prototype.parsePoint=function(t,e){var n=this.xScales,i=this.yScales;r.isFunction(e)&&(e=e(n,i));var a=void 0,s=void 0;if(r.isArray(e)&&r.isString(e[0])&&-1!==e[0].indexOf("%"))return this.parsePercentPoint(t,e);if(r.isArray(e))a=this._getNormalizedValue(e[0],o(n)),s=this._getNormalizedValue(e[1],o(i));else for(var u in e){var l=e[u];n[u]&&(a=this._getNormalizedValue(l,n[u])),i[u]&&(s=this._getNormalizedValue(l,i[u]))}return r.isNil(a)||r.isNil(s)?void 0:t.convert({x:a,y:s})},t.prototype.parsePercentPoint=function(t,e){var n=parseFloat(e[0])/100,r=parseFloat(e[1])/100,i=t.start,o=t.end,a=Math.min(i.x,o.x),s=Math.min(i.y,o.y);return{x:t.width*n+a,y:t.height*r+s}},t.prototype.setVisible=function(t){var e=this.el;e&&(e.set?e.set("visible",t):e.style.display=t?"":"none")},t.prototype.render=function(){},t.prototype.remove=function(){var t=this.el;t&&t.remove()},t}();t.exports=a},function(t,e,n){var r=n(549);function i(t,e){return r.isString(e)?e:t.invert(t.scale(e))}var o=function(){function t(e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.type="base",this.name=null,this.method=null,this.values=[],this.scales=[],this.linear=null,r.mix(this,e)}return t.prototype.get=function(t){return this[t]},t.prototype.set=function(t,e){this[t]=e},t.prototype._getAttrValue=function(t,e){var n=this.values;if(t.isCategory&&!this.linear)return n[t.translate(e)%n.length];var r=t.scale(e);return this.getLinearValue(r)},t.prototype.getLinearValue=function(t){var e=this.values,n=e.length-1,r=Math.floor(n*t),i=n*t-r,o=e[r];return o+((r===n?o:e[r+1])-o)*i},t.prototype.callback=function(t){var e=this.scales[0];return"identity"===e.type?e.value:this._getAttrValue(e,t)},t.prototype.getNames=function(){for(var t=this.scales,e=this.names,n=Math.min(t.length,e.length),r=[],i=0;i<n;i++)r.push(e[i]);return r},t.prototype.getFields=function(){var t=this.scales,e=[];return r.each(t,function(t){e.push(t.field)}),e},t.prototype.getScale=function(t){return this.scales[this.names.indexOf(t)]},t.prototype.mapping=function(){for(var t=this.scales,e=this.callback,n=arguments.length,i=Array(n),o=0;o<n;o++)i[o]=arguments[o];var a=i;if(e){for(var s=0;s<i.length;s++)i[s]=this._toOriginParam(i[s],t[s]);a=e.apply(this,i)}return r.isArray(a)||(a=[a]),a},t.prototype._toOriginParam=function(t,e){var n=t;if(!e.isLinear)if(r.isArray(t)){n=[];for(var o=0;o<t.length;o++)n.push(i(e,t[o]))}else n=i(e,t);return n},t}();t.exports=o},function(t,e){var n=Math.PI,r=Math.sin,i=Math.cos,o=Math.atan2,a=10,s=n/3;function u(t,e,u,l,c,h){var f=void 0,p=void 0,d=void 0,g=void 0,v=void 0,y=void 0,m=void 0;if(!e.fill){var x=e.arrowLength||a,b=e.arrowAngle?e.arrowAngle*n/180:s;m=o(h-l,c-u),m-=n,v=e.lineWidth*i(m),y=e.lineWidth*r(m),f=c+x*i(m+b/2),p=h+x*r(m+b/2),d=c+x*i(m-b/2),g=h+x*r(m-b/2),t.moveTo(f-v,p-y),t.lineTo(c-v,h-y),t.lineTo(d-v,g-y),t.moveTo(c-v,h-y),t.lineTo(c+v,h+y),t.moveTo(c,h)}}t.exports={addStartArrow:function(t,e,n,r,i,o){e.startArrow&&u(t,e,n,r,i,o)},addEndArrow:function(t,e,n,r,i,o){e.endArrow&&u(t,e,n,r,i,o)}}},function(t,e,n){var r=n(601),i=n(600);t.exports=function(t,e,n,o){var a=!n;n||(n={});for(var s=-1,u=e.length;++s<u;){var l=e[s],c=o?o(n[l],t[l],l,n,t):void 0;void 0===c&&(c=t[l]),a?i(n,l,c):r(n,l,c)}return n}},,,,,,function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r="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},i=n(626);function o(t,e){return t===e?0!==t||0!==e||1/t==1/e:t!=t&&e!=e}function a(t){return i.Util.isArray(t)?t.length:i.Util.isObject(t)?Object.keys(t).length:0}e.default=i.Util.mix({},i.Util,{shallowEqual:function(t,e){if(o(t,e))return!0;if("object"!==(void 0===t?"undefined":r(t))||null===t||"object"!==(void 0===e?"undefined":r(e))||null===e)return!1;if(i.Util.isArray(t)!==i.Util.isArray(e))return!1;if(a(t)!==a(e))return!1;var n=!0;return i.Util.each(t,function(t,r){return!!o(t,e[r])||(n=!1)}),n},without:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n={};return i.Util.each(t,function(t,r){-1===i.Util.indexOf(e,r)&&(n[r]=t)}),n},length:a})},function(t,e,n){var r=n(549),i=function(){function t(e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t);var n=this.getDefaultCfg();r.assign(this,n,e)}return t.prototype.getDefaultCfg=function(){return{xField:null,yField:null,adjustNames:["x","y"],groupFields:null}},t.prototype.isAdjust=function(t){return this.adjustNames.indexOf(t)>=0},t.prototype.processAdjust=function(t){var e=r.Array.merge(t);this.adjDataArray=t,this.mergeData=e,this.adjustData(t,e),this.adjFrames=null,this.mergeData=null},t.prototype._getDimValues=function(t){var e={},n=[];if(this.xField&&this.isAdjust("x")&&n.push(this.xField),this.yField&&this.isAdjust("y")&&n.push(this.yField),r.each(n,function(n){var i=r.Array.values(t,n);i.sort(function(t,e){return t-e}),e[n]=i}),!this.yField&&this.isAdjust("y")){var i=[0,1];e.y=i}return e},t.prototype.adjustData=function(t,e){var n=this,i=n._getDimValues(e);r.each(t,function(e,o){r.each(i,function(r,i){n.adjustDim(i,r,e,t.length,o)})})},t.prototype.adjustDim=function(){},t.prototype.getAdjustRange=function(t,e,n){var r=n.indexOf(e),i=n.length,o=void 0,a=void 0;return!this.yField&&this.isAdjust("y")?(o=0,a=1):i>1?(o=0===r?n[0]:n[r-1],a=r===i-1?n[i-1]:n[r+1],0!==r?o+=(e-o)/2:o-=(a-e)/2,r!==i-1?a-=(a-e)/2:a+=(e-n[i-2])/2):(o=0===e?0:e-.5,a=0===e?1:e+.5),{pre:o,next:a}},t.prototype.groupData=function(t,e){var n={};return r.each(t,function(t){var r=t[e];void 0===r&&(r=t[e]=0),n[r]||(n[r]=[]),n[r].push(t)}),n},t}();t.exports=i},function(t,e,n){var r=n(909),i=n(908)(r);t.exports=i},,function(t,e,n){var r=Math.PI/180,i=180/Math.PI;t.exports={isFunction:n(157),isObject:n(156),isBoolean:n(966),isNil:n(714),isString:n(102),isArray:n(80),isNumber:n(611),isEmpty:n(82),uniqueId:n(731),clone:n(730),assign:n(555),merge:n(728),upperFirst:n(918),remove:n(913),each:n(727),isEqual:n(907),toArray:n(903),extend:function(t,e,n,r){this.isFunction(e)||(n=e,e=t,t=function(){});var i=Object.create?function(t,e){return Object.create(t,{constructor:{value:e}})}:function(t,e){function n(){}n.prototype=t;var r=new n;return r.constructor=e,r},o=i(e.prototype,t);return t.prototype=this.merge(o,t.prototype),t.superclass=i(e.prototype,e),this.merge(o,n),this.merge(t,r),t},augment:function(t){for(var e=this.toArray(arguments),n=1;n<e.length;n++){var r=e[n];this.isFunction(r)&&(r=r.prototype),this.merge(t.prototype,r)}},isNumberEqual:function(t,e){return Math.abs(t-e)<1e-5},toRadian:function(t){return r*t},toDegree:function(t){return i*t},mod:function(t,e){return(t%e+e)%e},clamp:function(t,e,n){return t<e?e:t>n?n:t}}},,function(t,e,n){var r=n(946),i=n(944),o=n(254);t.exports=function(t){return o(t)?r(t,!0):i(t)}},,function(t,e,n){"use strict";n.r(e);var r=n(567);function i(t,e,n,r,i){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)*r+a*i)/6}var o=function(t){var e=t.length-1;return function(n){var r=n<=0?n=0:n>=1?(n=1,e-1):Math.floor(n*e),o=t[r],a=t[r+1],s=r>0?t[r-1]:2*o-a,u=r<e-1?t[r+2]:2*a-o;return i((n-r/e)*e,s,o,a,u)}},a=function(t){var e=t.length;return function(n){var r=Math.floor(((n%=1)<0?++n:n)*e),o=t[(r+e-1)%e],a=t[r%e],s=t[(r+1)%e],u=t[(r+2)%e];return i((n-r/e)*e,o,a,s,u)}},s=function(t){return function(){return t}};function u(t,e){return function(n){return t+n*e}}function l(t,e){var n=e-t;return n?u(t,n>180||n<-180?n-360*Math.round(n/360):n):s(isNaN(t)?e:t)}function c(t){return 1==(t=+t)?h: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(r){return Math.pow(t+r*e,n)}}(e,n,t):s(isNaN(e)?n:e)}}function h(t,e){var n=e-t;return n?u(t,n):s(isNaN(t)?e:t)}var f=function t(e){var n=c(e);function i(t,e){var i=n((t=Object(r.f)(t)).r,(e=Object(r.f)(e)).r),o=n(t.g,e.g),a=n(t.b,e.b),s=h(t.opacity,e.opacity);return function(e){return t.r=i(e),t.g=o(e),t.b=a(e),t.opacity=s(e),t+""}}return i.gamma=t,i}(1);function p(t){return function(e){var n,i,o=e.length,a=new Array(o),s=new Array(o),u=new Array(o);for(n=0;n<o;++n)i=Object(r.f)(e[n]),a[n]=i.r||0,s[n]=i.g||0,u[n]=i.b||0;return a=t(a),s=t(s),u=t(u),i.opacity=1,function(t){return i.r=a(t),i.g=s(t),i.b=u(t),i+""}}}var d=p(o),g=p(a),v=function(t,e){var n,r=e?e.length:0,i=t?Math.min(r,t.length):0,o=new Array(i),a=new Array(r);for(n=0;n<i;++n)o[n]=A(t[n],e[n]);for(;n<r;++n)a[n]=e[n];return function(t){for(n=0;n<i;++n)a[n]=o[n](t);return a}},y=function(t,e){var n=new Date;return e-=t=+t,function(r){return n.setTime(t+e*r),n}},m=function(t,e){return e-=t=+t,function(n){return t+e*n}},x=function(t,e){var n,r={},i={};for(n in null!==t&&"object"==typeof t||(t={}),null!==e&&"object"==typeof e||(e={}),e)n in t?r[n]=A(t[n],e[n]):i[n]=e[n];return function(t){for(n in r)i[n]=r[n](t);return i}},b=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,_=new RegExp(b.source,"g");var w,S,M,C,P=function(t,e){var n,r,i,o=b.lastIndex=_.lastIndex=0,a=-1,s=[],u=[];for(t+="",e+="";(n=b.exec(t))&&(r=_.exec(e));)(i=r.index)>o&&(i=e.slice(o,i),s[a]?s[a]+=i:s[++a]=i),(n=n[0])===(r=r[0])?s[a]?s[a]+=r:s[++a]=r:(s[++a]=null,u.push({i:a,x:m(n,r)})),o=_.lastIndex;return o<e.length&&(i=e.slice(o),s[a]?s[a]+=i:s[++a]=i),s.length<2?u[0]?function(t){return function(e){return t(e)+""}}(u[0].x):function(t){return function(){return t}}(e):(e=u.length,function(t){for(var n,r=0;r<e;++r)s[(n=u[r]).i]=n.x(t);return s.join("")})},A=function(t,e){var n,i=typeof e;return null==e||"boolean"===i?s(e):("number"===i?m:"string"===i?(n=Object(r.a)(e))?(e=n,f):P:e instanceof r.a?f:e instanceof Date?y:Array.isArray(e)?v:"function"!=typeof e.valueOf&&"function"!=typeof e.toString||isNaN(e)?x:m)(t,e)},I=function(t,e){return e-=t=+t,function(n){return Math.round(t+e*n)}},O=180/Math.PI,E={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1},T=function(t,e,n,r,i,o){var a,s,u;return(a=Math.sqrt(t*t+e*e))&&(t/=a,e/=a),(u=t*n+e*r)&&(n-=t*u,r-=e*u),(s=Math.sqrt(n*n+r*r))&&(n/=s,r/=s,u/=s),t*r<e*n&&(t=-t,e=-e,u=-u,a=-a),{translateX:i,translateY:o,rotate:Math.atan2(e,t)*O,skewX:Math.atan(u)*O,scaleX:a,scaleY:s}};function k(t,e,n,r){function i(t){return t.length?t.pop()+" ":""}return function(o,a){var s=[],u=[];return o=t(o),a=t(a),function(t,r,i,o,a,s){if(t!==i||r!==o){var u=a.push("translate(",null,e,null,n);s.push({i:u-4,x:m(t,i)},{i:u-2,x:m(r,o)})}else(i||o)&&a.push("translate("+i+e+o+n)}(o.translateX,o.translateY,a.translateX,a.translateY,s,u),function(t,e,n,o){t!==e?(t-e>180?e+=360:e-t>180&&(t+=360),o.push({i:n.push(i(n)+"rotate(",null,r)-2,x:m(t,e)})):e&&n.push(i(n)+"rotate("+e+r)}(o.rotate,a.rotate,s,u),function(t,e,n,o){t!==e?o.push({i:n.push(i(n)+"skewX(",null,r)-2,x:m(t,e)}):e&&n.push(i(n)+"skewX("+e+r)}(o.skewX,a.skewX,s,u),function(t,e,n,r,o,a){if(t!==n||e!==r){var s=o.push(i(o)+"scale(",null,",",null,")");a.push({i:s-4,x:m(t,n)},{i:s-2,x:m(e,r)})}else 1===n&&1===r||o.push(i(o)+"scale("+n+","+r+")")}(o.scaleX,o.scaleY,a.scaleX,a.scaleY,s,u),o=a=null,function(t){for(var e,n=-1,r=u.length;++n<r;)s[(e=u[n]).i]=e.x(t);return s.join("")}}}var j=k(function(t){return"none"===t?E:(w||(w=document.createElement("DIV"),S=document.documentElement,M=document.defaultView),w.style.transform=t,t=M.getComputedStyle(S.appendChild(w),null).getPropertyValue("transform"),S.removeChild(w),t=t.slice(7,-1).split(","),T(+t[0],+t[1],+t[2],+t[3],+t[4],+t[5]))},"px, ","px)","deg)"),L=k(function(t){return null==t?E:(C||(C=document.createElementNS("http://www.w3.org/2000/svg","g")),C.setAttribute("transform",t),(t=C.transform.baseVal.consolidate())?(t=t.matrix,T(t.a,t.b,t.c,t.d,t.e,t.f)):E)},", ",")",")"),D=Math.SQRT2;function F(t){return((t=Math.exp(t))+1/t)/2}var R=function(t,e){var n,r,i=t[0],o=t[1],a=t[2],s=e[0],u=e[1],l=e[2],c=s-i,h=u-o,f=c*c+h*h;if(f<1e-12)r=Math.log(l/a)/D,n=function(t){return[i+t*c,o+t*h,a*Math.exp(D*t*r)]};else{var p=Math.sqrt(f),d=(l*l-a*a+4*f)/(2*a*2*p),g=(l*l-a*a-4*f)/(2*l*2*p),v=Math.log(Math.sqrt(d*d+1)-d),y=Math.log(Math.sqrt(g*g+1)-g);r=(y-v)/D,n=function(t){var e,n=t*r,s=F(v),u=a/(2*p)*(s*(e=D*n+v,((e=Math.exp(2*e))-1)/(e+1))-function(t){return((t=Math.exp(t))-1/t)/2}(v));return[i+u*c,o+u*h,a*s/F(D*n+v)]}}return n.duration=1e3*r,n};function B(t){return function(e,n){var i=t((e=Object(r.d)(e)).h,(n=Object(r.d)(n)).h),o=h(e.s,n.s),a=h(e.l,n.l),s=h(e.opacity,n.opacity);return function(t){return e.h=i(t),e.s=o(t),e.l=a(t),e.opacity=s(t),e+""}}}var N=B(l),z=B(h);function V(t,e){var n=h((t=Object(r.e)(t)).l,(e=Object(r.e)(e)).l),i=h(t.a,e.a),o=h(t.b,e.b),a=h(t.opacity,e.opacity);return function(e){return t.l=n(e),t.a=i(e),t.b=o(e),t.opacity=a(e),t+""}}function G(t){return function(e,n){var i=t((e=Object(r.c)(e)).h,(n=Object(r.c)(n)).h),o=h(e.c,n.c),a=h(e.l,n.l),s=h(e.opacity,n.opacity);return function(t){return e.h=i(t),e.c=o(t),e.l=a(t),e.opacity=s(t),e+""}}}var Y=G(l),W=G(h);function X(t){return function e(n){function i(e,i){var o=t((e=Object(r.b)(e)).h,(i=Object(r.b)(i)).h),a=h(e.s,i.s),s=h(e.l,i.l),u=h(e.opacity,i.opacity);return function(t){return e.h=o(t),e.s=a(t),e.l=s(Math.pow(t,n)),e.opacity=u(t),e+""}}return n=+n,i.gamma=e,i}(1)}var q=X(l),H=X(h),U=function(t,e){for(var n=new Array(e),r=0;r<e;++r)n[r]=t(r/(e-1));return n};n.d(e,"interpolate",function(){return A}),n.d(e,"interpolateArray",function(){return v}),n.d(e,"interpolateBasis",function(){return o}),n.d(e,"interpolateBasisClosed",function(){return a}),n.d(e,"interpolateDate",function(){return y}),n.d(e,"interpolateNumber",function(){return m}),n.d(e,"interpolateObject",function(){return x}),n.d(e,"interpolateRound",function(){return I}),n.d(e,"interpolateString",function(){return P}),n.d(e,"interpolateTransformCss",function(){return j}),n.d(e,"interpolateTransformSvg",function(){return L}),n.d(e,"interpolateZoom",function(){return R}),n.d(e,"interpolateRgb",function(){return f}),n.d(e,"interpolateRgbBasis",function(){return d}),n.d(e,"interpolateRgbBasisClosed",function(){return g}),n.d(e,"interpolateHsl",function(){return N}),n.d(e,"interpolateHslLong",function(){return z}),n.d(e,"interpolateLab",function(){return V}),n.d(e,"interpolateHcl",function(){return Y}),n.d(e,"interpolateHclLong",function(){return W}),n.d(e,"interpolateCubehelix",function(){return q}),n.d(e,"interpolateCubehelixLong",function(){return H}),n.d(e,"quantize",function(){return U})},function(t,e,n){var r=n(551),i=n(549),o=i.assign,a=i.isNil,s=i.isArray,u=i.cloneDeep;function l(t,e){if(t["_wrap_"+e])return t["_wrap_"+e];var n=function(n){t[e](n)};return t["_wrap_"+e]=n,n}function c(t,e){return t["_wrap_"+e]}var h=function(){function t(e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t);var n=this.getDefaultCfg();o(this,n,e),this.init()}return t.prototype.getDefaultCfg=function(){return{chart:null,group:null,showTitle:!0,autoSetAxis:!0,padding:10,eachView:null,fields:[],colTitle:{offsetY:-15,style:{fontSize:14,textAlign:"center",fill:"#666",fontFamily:r.fontFamily}},rowTitle:{offsetX:15,style:{fontSize:14,textAlign:"center",rotate:90,fill:"#666",fontFamily:r.fontFamily}}}},t.prototype.init=function(){if(!this.chart)throw new Error("Facets Error: please specify the chart!");this._bindEvent(),this.initContainer(),this.chart.get("data")&&this.initViews()},t.prototype.initContainer=function(){var t=this.chart.get("frontPlot").addGroup();this.group=t},t.prototype.initViews=function(){for(var t=this.chart,e=t.get("data"),n=this.eachView,r=this.generateFacets(e),i=0;i<r.length;i++){var o=r[i],a=o.region,s=t.view({start:a.start,end:a.end,padding:this.padding});s.source(o.data),this.beforeProcessView(s,o),n&&n(s,o),this.afterProcessView(s,o),o.view=s}this.facets=r},t.prototype.beforeProcessView=function(){},t.prototype.afterProcessView=function(t,e){this.autoSetAxis&&this.processAxis(t,e)},t.prototype.processAxis=function(t,e){var n=t.get("options"),r=t.get("geoms");if((!n.coord.type||"rect"===n.coord.type)&&r.length){var i=r[0].get("attrOptions").position.field,o=s(i)?i:i.split("*").map(function(t){return t.trim()}),u=o[0],l=o[1];a(n.axes)&&(n.axes={});var c=n.axes;!1!==c&&(u&&!1!==c[u]&&(c[u]=c[u]||{},this.setXAxis(u,c,e)),l&&!1!==c[l]&&(c[l]=c[l]||{},this.setYAxis(l,c,e)))}},t.prototype.setXAxis=function(){},t.prototype.setYAxis=function(){},t.prototype.renderTitle=function(t,e){this.drawColTitle(t,e)},t.prototype.getScaleText=function(t,e,n){var r=void 0;if(t){var i=n.get("scales")[t];i||(i=n.createScale(t)),r=i.getText(e)}else r=e;return r},t.prototype.drawColTitle=function(t,e){var n=this.getScaleText(e.colField,e.colValue,t),r=o({position:["50%","0%"],content:n},this.colTitle);t.guide().text(r)},t.prototype.drawRowTitle=function(t,e){var n=this.getScaleText(e.rowField,e.rowValue,t),r=o({position:["100%","50%"],content:n},u(this.rowTitle));t.guide().text(r)},t.prototype.getFilter=function(t){return function(e){var n=!0;return t.forEach(function(t){var r=t.field,i=t.value,o=!0;!a(i)&&r&&(o=e[r]===i),n=n&&o}),n}},t.prototype.getFieldValues=function(t,e){for(var n=[],r={},i=0;i<e.length;i++){var o=e[i][t];a(o)||r[o]||(n.push(o),r[o]=!0)}return n},t.prototype.getRegion=function(t,e,n,r){var i=1/e,o=1/t,a={x:i*n,y:o*r};return{start:a,end:{x:a.x+i,y:a.y+o}}},t.prototype.generateFacets=function(){return[]},t.prototype._bindEvent=function(){var t=this.chart;t.on("afterchangedata",l(this,"onDataChange")),t.on("beforeclear",l(this,"onClear")),t.on("beforedestroy",l(this,"destroy")),t.on("beforepaint",l(this,"onPaint")),t.on("setdata",l(this,"onDataChange"))},t.prototype._clearEvent=function(){var t=this.chart;t&&(t.off("afterchangedata",c(this,"onDataChange")),t.off("beforeclear",c(this,"onClear")),t.off("beforedestroy",c(this,"destroy")),t.off("beforepaint",c(this,"onPaint")),t.off("setdata",c(this,"onDataChange")))},t.prototype._clearFacets=function(){var t=this.facets,e=this.chart;if(t)for(var n=0;n<t.length;n++){var r=t[n];e.removeView(r.view)}this.facets=null},t.prototype.onClear=function(){this.onRemove()},t.prototype.onPaint=function(){if(this.showTitle)for(var t=this.facets,e=0;e<t.length;e++){var n=t[e],r=n.view;this.renderTitle(r,n)}},t.prototype.onDataChange=function(){this._clearFacets(),this.initViews()},t.prototype.onRemove=function(){this._clearFacets(),this._clearEvent(),this.group&&this.group.remove(),this.chart=null,this.facets=null,this.group=null},t.prototype.destroy=function(){this.onRemove(),this.destroyed=!0},t}();t.exports=h},function(t,e,n){var r=n(549),i=n(663).LabelsRenderer,o=n(552).Group,a=n(811),s=n(551),u=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){return{_id:null,zIndex:4,ticks:null,line:null,tickLine:null,subTickCount:0,subTickLine:null,grid:null,label:{textStyle:{},autoRotate:!0,formatter:null},title:{autoRotate:!0,textStyle:{}},autoPaint:!0}},e.prototype._beforeRenderUI=function(){var t=this.get("title"),e=this.get("label"),n=this.get("grid");t&&this.setSilent("title",r.deepMix({autoRotate:!0,textStyle:{fontSize:12,fill:"#ccc",textBaseline:"middle",fontFamily:s.fontFamily,textAlign:"center"},offset:48},t)),e&&this.setSilent("label",r.deepMix({autoRotate:!0,textStyle:{fontSize:12,fill:"#ccc",textBaseline:"middle",fontFamily:s.fontFamily},offset:10},e)),n&&this.setSilent("grid",r.deepMix({lineStyle:{lineWidth:1,stroke:"#C0D0E0"}},n))},e.prototype._renderUI=function(){this.get("label")&&this.renderLabels(),this.get("autoPaint")&&this.paint(),r.isNil(this.get("title"))||this.renderTitle(),this.sort()},e.prototype._parseTicks=function(t){for(var e=(t=t||[]).length,n=0;n<e;n++){var i=t[n];r.isObject(i)||(t[n]=this.parseTick(i,n,e))}return this.set("ticks",t),t},e.prototype._addTickItem=function(t,e,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"",i=this.get("tickItems"),o=this.get("subTickItems"),a=this.getTickEnd(e,n,t),s={x1:e.x,y1:e.y,x2:a.x,y2:a.y};i||(i=[]),o||(o=[]),"sub"===r?o.push(s):i.push(s),this.set("tickItems",i),this.set("subTickItems",o)},e.prototype._renderLine=function(){var t=this.get("line"),e=void 0;if(t){e=this.getLinePath(),t=r.mix({path:e},t);var n=this.addShape("path",{attrs:t});n.name="axis-line",this.get("appendInfo")&&n.setSilent("appendInfo",this.get("appendInfo")),this.set("lineShape",n)}},e.prototype._processTicks=function(){var t=this,e=t.get("label"),n=t.get("subTickCount"),i=t.get("tickLine"),o=t.get("ticks");if(o=t._parseTicks(o),r.each(o,function(n,r){var o=t.getTickPoint(n.value,r);i&&t._addTickItem(r,o,i.length),e&&t.addLabel(n,o,r)}),n){var a=t.get("subTickLine");r.each(o,function(e,r){if(r>0){var s=e.value-o[r-1].value;s/=t.get("subTickCount")+1;for(var u=1;u<=n;u++){var l={text:"",value:r?o[r-1].value+u*s:u*s},c=t.getTickPoint(l.value),h=void 0;h=a&&a.length?a.length:parseInt(.6*i.length,10),t._addTickItem(u-1,c,h,"sub")}}})}},e.prototype._addTickLine=function(t,e){var n=r.mix({},e),i=[];r.each(t,function(t){i.push(["M",t.x1,t.y1]),i.push(["L",t.x2,t.y2])}),delete n.length,n.path=i;var o=this.addShape("path",{attrs:n});o.name="axis-ticks",o._id=this.get("_id")+"-ticks",o.set("coord",this.get("coord")),this.get("appendInfo")&&o.setSilent("appendInfo",this.get("appendInfo"))},e.prototype._renderTicks=function(){var t=this.get("tickItems"),e=this.get("subTickItems");if(!r.isEmpty(t)){var n=this.get("tickLine");this._addTickLine(t,n)}if(!r.isEmpty(e)){var i=this.get("subTickLine")||this.get("tickLine");this._addTickLine(e,i)}},e.prototype._renderGrid=function(){var t=this.get("grid");t&&(t.coord=this.get("coord"),t.appendInfo=this.get("appendInfo"),this.set("gridGroup",this.addGroup(a,t)))},e.prototype.paint=function(){this._renderLine(),this._processTicks(),this._renderTicks(),this._renderGrid();var t=this.get("label");t&&t.autoRotate&&this.autoRotateLabels()},e.prototype.parseTick=function(t,e,n){return{text:t,value:e/(n-1)}},e.prototype.getTextAnchor=function(t){return Math.abs(t[1]/t[0])>=1?"center":t[0]>0?"start":"end"},e.prototype.getMaxLabelWidth=function(t){var e=t.get("children"),n=0;return r.each(e,function(t){var e=t.getBBox().width;n<e&&(n=e)}),n},e.prototype.remove=function(){t.prototype.remove.call(this);var e=this.get("gridGroup");e&&e.remove(),this.removeLabels()},e.prototype.autoRotateLabels=function(){},e.prototype.renderTitle=function(){},e.prototype.getLinePath=function(){},e.prototype.getTickPoint=function(){},e.prototype.getTickEnd=function(){},e.prototype.getSideVector=function(){},e}(o);r.assign(u.prototype,i,{addLabel:function(t,e,n){var i=this.get("labelsGroup"),o={},a=void 0;if(i){var s=this.get("_labelOffset");r.isNil(this.get("label").offset)||(s=this.get("label").offset);var u=this.getSideVector(s,e,n);e={x:e.x+u[0],y:e.y+u[1]},o.text=t.text,o.x=e.x,o.y=e.y,o.textAlign=this.getTextAnchor(u),(a=i.addLabel(o))&&(a.name="axis-label",a._id=this.get("_id")+"-"+t.tickValue,a.set("coord",this.get("coord")),this.get("appendInfo")&&a.setSilent("appendInfo",this.get("appendInfo")))}return a}}),t.exports=u},function(t,e,n){var r=n(549),i=n(552).MatrixUtil,o=i.mat3,a=i.vec3,s=function(){function t(e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t);var n=this.getDefaultCfg();r.mix(this,n,e),this.init()}return t.prototype.getDefaultCfg=function(){return{isTransposed:!1,matrix:[1,0,0,0,1,0,0,0,1]}},t.prototype.init=function(){var t=this.start,e=this.end,n={x:(t.x+e.x)/2,y:(t.y+e.y)/2};this.center=n,this.width=Math.abs(e.x-t.x),this.height=Math.abs(e.y-t.y)},t.prototype._swapDim=function(t){var e=this[t];if(e){var n=e.start;e.start=e.end,e.end=n}},t.prototype.getCenter=function(){return this.center},t.prototype.getWidth=function(){return this.width},t.prototype.getHeight=function(){return this.height},t.prototype.convertDim=function(t,e){var n=this[e],r=n.start;return r+t*(n.end-r)},t.prototype.invertDim=function(t,e){var n=this[e],r=n.start;return(t-r)/(n.end-r)},t.prototype.convertPoint=function(t){return t},t.prototype.invertPoint=function(t){return t},t.prototype.applyMatrix=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,r=this.matrix,i=[t,e,n];return a.transformMat3(i,i,r),i},t.prototype.invertMatrix=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,r=this.matrix,i=o.invert([],r),s=[t,e,n];return a.transformMat3(s,s,i),s},t.prototype.convert=function(t){var e=this.convertPoint(t),n=e.x,r=e.y,i=this.applyMatrix(n,r,1);return{x:i[0],y:i[1]}},t.prototype.invert=function(t){var e=this.invertMatrix(t.x,t.y,1);return this.invertPoint({x:e[0],y:e[1]})},t.prototype.rotate=function(t){var e=this.matrix,n=this.center;return o.translate(e,e,[-n.x,-n.y]),o.rotate(e,e,t),o.translate(e,e,[n.x,n.y]),this},t.prototype.reflect=function(t){switch(t){case"x":this._swapDim("x");break;case"y":this._swapDim("y");break;default:this._swapDim("y")}return this},t.prototype.scale=function(t,e){var n=this.matrix,r=this.center;return o.translate(n,n,[-r.x,-r.y]),o.scale(n,n,[t,e]),o.translate(n,n,[r.x,r.y]),this},t.prototype.translate=function(t,e){var n=this.matrix;return o.translate(n,n,[t,e]),this},t.prototype.transpose=function(){return this.isTransposed=!this.isTransposed,this},t}();t.exports=s},function(t,e,n){var r=n(594),i=n(549),o=n(826),a=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return i.mix({},e,{type:"linear",isLinear:!0,min:null,minLimit:null,max:null,maxLimit:null,nice:!1,tickCount:null,tickInterval:null,snapArray:null})},e.prototype.init=function(){if(this.ticks){var t=this.ticks,e=this.translate(t[0]),n=this.translate(t[t.length-1]);(i.isNil(this.min)||this.min>e)&&(this.min=e),(i.isNil(this.max)||this.max<n)&&(this.max=n)}else this.min=this.translate(this.min),this.max=this.translate(this.max),this.initTicks()},e.prototype.calculateTicks=function(){var t=this.min,e=this.max,n=this.tickCount,r=this.tickInterval;if(e<t)throw new Error("max: "+e+" should not be less than min: "+t);return o({min:t,max:e,minLimit:this.minLimit,maxLimit:this.maxLimit,minCount:n,maxCount:n,interval:r,snapArray:this.snapArray}).ticks},e.prototype.initTicks=function(){var t=this,e=t.calculateTicks();if(t.nice)t.ticks=e,t.min=e[0],t.max=e[e.length-1];else{var n=[];i.each(e,function(e){e>=t.min&&e<=t.max&&n.push(e)}),n.length||(n.push(t.min),n.push(t.max)),t.ticks=n}},e.prototype.scale=function(t){if(null===t||void 0===t)return NaN;var e=this.max,n=this.min;if(e===n)return 0;var r=(t-n)/(e-n),i=this.rangeMin();return i+r*(this.rangeMax()-i)},e.prototype.invert=function(t){var e=(t-this.rangeMin())/(this.rangeMax()-this.rangeMin());return this.min+e*(this.max-this.min)},e}(r);t.exports=a},function(t,e,n){var r=n(549),i=function(){function t(e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t);var n=this.getDefaultCfg();r.mix(this,n,e),this.init()}return t.prototype.getDefaultCfg=function(){return{type:"base",formatter:null,range:[0,1],ticks:null,values:[]}},t.prototype.init=function(){},t.prototype.getTicks=function(){var t=this,e=t.ticks,n=[];return r.each(e,function(e){var i=void 0;i=r.isObject(e)?e:{text:t.getText(e),tickValue:e,value:t.scale(e)},n.push(i)}),n},t.prototype.getText=function(t){var e=this.formatter;return t=e?e(t):t,!r.isNil(t)&&t.toString||(t=""),t.toString()},t.prototype.rangeMin=function(){return this.range[0]},t.prototype.rangeMax=function(){var t=this.range;return t[t.length-1]},t.prototype.invert=function(t){return t},t.prototype.translate=function(t){return t},t.prototype.scale=function(t){return t},t.prototype.clone=function(){var t=this,e=t.constructor,n={};return r.each(t,function(e,r){n[r]=t[r]}),new e(n)},t.prototype.change=function(t){return this.ticks=null,r.mix(this,t),this.init(),this},t}();t.exports=i},,,function(t,e,n){var r=n(553),i=n(558).vec2;function o(t,e,n,r,i){var o=1-i;return o*o*(o*r+3*i*n)+i*i*(i*t+3*o*e)}function a(t,e,n,r,a,s,u,l,c,h,f){var p=void 0,d=.005,g=1/0,v=void 0,y=void 0,m=void 0,x=void 0,b=void 0,_=void 0,w=void 0,S=[c,h];for(v=0;v<1;v+=.05)y=[o(t,n,a,u,v),o(e,r,s,l,v)],(m=i.squaredDistance(S,y))<g&&(p=v,g=m);g=1/0;for(var M=0;M<32&&!(d<1e-4);M++)w=p+d,y=[o(t,n,a,u,_=p-d),o(e,r,s,l,_)],m=i.squaredDistance(S,y),_>=0&&m<g?(p=_,g=m):(b=[o(t,n,a,u,w),o(e,r,s,l,w)],x=i.squaredDistance(S,b),w<=1&&x<g?(p=w,g=x):d*=.5);return f&&(f.x=o(t,n,a,u,p),f.y=o(e,r,s,l,p)),Math.sqrt(g)}function s(t,e,n,r,i){return t*(t*(-3*e+9*n-9*r+3*i)+6*e-12*n+6*r)-3*e+3*n}t.exports={at:o,derivativeAt:function(t,e,n,r,i){var o=1-i;return 3*(((e-t)*o+2*(n-e)*i)*o+(r-n)*i*i)},projectPoint:function(t,e,n,r,i,o,s,u,l,c){var h={};return a(t,e,n,r,i,o,s,u,l,c,h),h},pointDistance:a,extrema:function(t,e,n,i){var o=3*t-9*e+9*n-3*i,a=6*e-12*n+6*i,s=3*n-3*i,u=[],l=void 0,c=void 0,h=void 0;if(r.isNumberEqual(o,0))r.isNumberEqual(a,0)||(l=-s/a)>=0&&l<=1&&u.push(l);else{var f=a*a-4*o*s;r.isNumberEqual(f,0)?u.push(-a/(2*o)):f>0&&(c=(-a-(h=Math.sqrt(f)))/(2*o),(l=(-a+h)/(2*o))>=0&&l<=1&&u.push(l),c>=0&&c<=1&&u.push(c))}return u},len:function(t,e,n,i,o,a,u,l,c){r.isNil(c)&&(c=1);for(var h=(c=c>1?1:c<0?0:c)/2,f=[-.1252,.1252,-.3678,.3678,-.5873,.5873,-.7699,.7699,-.9041,.9041,-.9816,.9816],p=[.2491,.2491,.2335,.2335,.2032,.2032,.1601,.1601,.1069,.1069,.0472,.0472],d=0,g=0;g<12;g++){var v=h*f[g]+h,y=s(v,t,n,o,u),m=s(v,e,i,a,l),x=y*y+m*m;d+=p[g]*Math.sqrt(x)}return h*d}}},function(t,e,n){var r=n(609),i=n(702),o=n(701);t.exports=function(t,e){return o(i(t,e,r),t+"")}},function(t,e){t.exports=function(t,e){var n=-1,r=t.length;for(e||(e=Array(r));++n<r;)e[n]=t[n];return e}},,,,,,,,function(t,e,n){var r=n(867),i=n(865)(function(t,e){return null==t?{}:r(t,e)});t.exports=i},function(t,e,n){var r=n(706),i=n(884);t.exports=function t(e,n,o,a,s){var u=-1,l=e.length;for(o||(o=i),s||(s=[]);++u<l;){var c=e[u];n>0&&o(c)?n>1?t(c,n-1,o,a,s):r(s,c):a||(s[s.length]=c)}return s}},,,function(t,e,n){var r=n(50),i=n(49),o="[object Number]";t.exports=function(t){return"number"==typeof t||i(t)&&r(t)==o}},function(t,e,n){"use strict";n.r(e);var r,i,o=0,a=0,s=0,u=1e3,l=0,c=0,h=0,f="object"==typeof performance&&performance.now?performance:Date,p="object"==typeof window&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(t){setTimeout(t,17)};function d(){return c||(p(g),c=f.now()+h)}function g(){c=0}function v(){this._call=this._time=this._next=null}function y(t,e,n){var r=new v;return r.restart(t,e,n),r}function m(){d(),++o;for(var t,e=r;e;)(t=c-e._time)>=0&&e._call.call(null,t),e=e._next;--o}function x(){c=(l=f.now())+h,o=a=0;try{m()}finally{o=0,function(){var t,e,n=r,o=1/0;for(;n;)n._call?(o>n._time&&(o=n._time),t=n,n=n._next):(e=n._next,n._next=null,n=t?t._next=e:r=e);i=t,_(o)}(),c=0}}function b(){var t=f.now(),e=t-l;e>u&&(h-=e,l=t)}function _(t){o||(a&&(a=clearTimeout(a)),t-c>24?(t<1/0&&(a=setTimeout(x,t-f.now()-h)),s&&(s=clearInterval(s))):(s||(l=f.now(),s=setInterval(b,u)),o=1,p(x)))}v.prototype=y.prototype={constructor:v,restart:function(t,e,n){if("function"!=typeof t)throw new TypeError("callback is not a function");n=(null==n?d():+n)+(null==e?0:+e),this._next||i===this||(i?i._next=this:r=this,i=this),this._call=t,this._time=n,_()},stop:function(){this._call&&(this._call=null,this._time=1/0,_())}};var w=function(t,e,n){var r=new v;return e=null==e?0:+e,r.restart(function(n){r.stop(),t(n+e)},e,n),r},S=function(t,e,n){var r=new v,i=e;return null==e?(r.restart(t,e,n),r):(e=+e,n=null==n?d():+n,r.restart(function o(a){a+=i,r.restart(o,i+=e,n),t(a)},e,n),r)};n.d(e,"now",function(){return d}),n.d(e,"timer",function(){return y}),n.d(e,"timerFlush",function(){return m}),n.d(e,"timeout",function(){return w}),n.d(e,"interval",function(){return S})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.Prop=e.Util=void 0;var r=o(n(581)),i=o(n(757));function o(t){return t&&t.__esModule?t:{default:t}}e.Util=r.default,e.Prop=i.default},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r={Chart:"deleteChart",Coord:"deleteCoord",Geom:"deleteGeom",Axis:"deleteAxis",Tooltip:"deleteTooltip",Legend:"deleteLegend",Label:"deleteLabel",View:"deleteView",Guide:"deleteGuide",GuideLine:"deleteTypedGuide",GuideImage:"deleteTypedGuide",GuideText:"deleteTypedGuide",GuideRegion:"deleteTypedGuide",GuideHtml:"deleteTypedGuide",GuideArc:"deleteTypedGuide",Facet:"deleteFacet"},i={merge:function(t,e,n,r){this.mergeDelete(t,e,n),this.mergeUpdate(t,r)},mergeDelete:function(t,e,n){var i=this;Object.keys(e).forEach(function(e){var o=r[n[e].name],a=t;n[e].viewId&&(a=t.views[n[e].viewId]),i[o]&&i[o](a,e,n[e].parentInfo.id)})},deleteAxis:function(t,e){t&&delete t.axises[e]},deleteTooltip:function(t){t&&delete t.tooltip},deleteCoord:function(t){t&&delete t.coord},deleteLegend:function(t,e){t&&delete t.legends[e]},deleteGuide:function(t){t&&delete t.guide},deleteGeom:function(t,e){t&&t.geoms&&delete t.geoms[e]},deleteLabel:function(t,e,n){t&&t.geoms&&t.geoms[n]&&delete t.geoms[n].label},deleteFacet:function(t){t&&delete t.facet},deleteTypedGuide:function(t,e){t&&t.guide&&delete t.guide.elements[e]},deleteView:function(t,e){t&&delete t.views[e]},mergeUpdate:function(t,e){this.mergeChart(t,e),this.mergeAxises(t,e),this.mergeCoord(t,e),this.mergeGeoms(t.geoms,e),this.mergeLegends(t.legends,e),this.mergeTooltip(t,e),this.mergeViews(t.views,e)},mergeChart:function(t,e){t.chart&&t.chart.updateProps&&(t.chart.props=t.chart.updateProps),e&&delete t.chart.g2Instance},mergeAxises:function(t,e){var n=t.axises;if(null!=!n)for(var r in n)n[r]&&n[r].updateProps&&(n[r].props=n[r].updateProps),e&&delete n[r].g2Instance},mergeTooltip:function(t,e){t.tooltip&&(e&&delete t.tooltip.g2Instance,t.tooltip.updateProps&&(t.tooltip.props=t.tooltip.updateProps))},mergeCoord:function(t,e){t.coord&&(e&&delete t.coord.g2Instance,t.coord.updateProps&&(t.coord.props=t.coord.updateProps))},mergeLegends:function(t,e){if(t)for(var n in t)if(t[n]){var r=t[n];e&&delete r.g2Instance,r.updateProps&&(r.props=r.updateProps)}},mergeGeoms:function(t,e){if(null!=t)for(var n in t)t[n]&&(e&&(delete t[n].g2Instance,t[n].label&&t[n].label.g2Instance&&delete t[n].label.g2Instance),t[n].updateProps&&(t[n].props=t[n].updateProps))},mergeGuide:function(t,e){if(null!=t){var n=t.elements;for(var r in n)n[r]&&(e&&delete n[r].g2Instance,n[r].updateProps&&(n[r].props=n[r].updateProps))}},mergeView:function(t,e){t&&(e&&t.g2Instance&&delete t.g2Instance,t.updateProps&&(t.props=t.updateProps),this.mergeCoord(t,e),this.mergeAxises(t,e),this.mergeGeoms(t.geoms,e),this.mergeGuide(t.guide,e))},mergeViews:function(t,e){if(null!=t)for(var n in t)t[n]&&this.mergeView(t[n],e)}};e.default=i},function(t,e,n){var r=n(549),i={splitPoints:function(t){var e=[],n=t.x,i=t.y;return i=r.isArray(i)?i:[i],r.each(i,function(t,i){var o={x:r.isArray(n)?n[i]:n,y:t};e.push(o)}),e}};t.exports=i},function(t,e,n){var r=n(549),i=/rgb\((\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*\)/;function o(t,e,n,r){return t[r]+(e[r]-t[r])*n}function a(t){return"#"+s(t[0])+s(t[1])+s(t[2])}function s(t){return 1===(t=(t=Math.round(t)).toString(16)).length&&(t="0"+t),t}function u(t){var e=[];return e.push(parseInt(t.substr(1,2),16)),e.push(parseInt(t.substr(3,2),16)),e.push(parseInt(t.substr(5,2),16)),e}var l={},c=null,h={toRGB:function(t){if("#"===t[0]&&7===t.length)return t;var e;c||((e=document.createElement("i")).title="Web Colour Picker",e.style.display="none",document.body.appendChild(e),c=e);var n=void 0;if(l[t])n=l[t];else{c.style.color=t,n=document.defaultView.getComputedStyle(c,"").getPropertyValue("color");var r=i.exec(n);r.shift(),n=a(r),l[t]=n}return n},rgb2arr:u,gradient:function(t){var e=[];return r.isString(t)&&(t=t.split("-")),r.each(t,function(t){-1===t.indexOf("#")&&(t=h.toRGB(t)),e.push(u(t))}),function(t){return function(t,e){!r.isNaN(e)&&r.isNumber(e)||(e=0);var n=t.length-1,i=Math.floor(n*e),s=n*e-i,u=t[i],l=i===n?u:t[i+1];return a([o(u,l,s,0),o(u,l,s,1),o(u,l,s,2)])}(e,t)}}};t.exports=h},function(t,e,n){var r=n(847),i=n(549),o=function(t){function e(n){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);var r=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.call(this)),o={visible:!0},a=r.getDefaultCfg();return r._attrs=o,i.assign(o,a,n),r}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){return{}},e.prototype.get=function(t){return this._attrs[t]},e.prototype.set=function(t,e){this._attrs[t]=e},e.prototype.show=function(){this.get("visible")||(this.set("visible",!0),this.changeVisible(!0))},e.prototype.hide=function(){this.get("visible")&&(this.set("visible",!1),this.changeVisible(!1))},e.prototype.changeVisible=function(){},e.prototype.destroy=function(){this._attrs={},this.removeAllListeners(),this.destroyed=!0},e}(r);t.exports=o},function(t,e,n){var r=n(713),i=1,o=4;t.exports=function(t){return r(t,i|o)}},function(t,e,n){var r=n(553),i=n(556),o=n(557),a=function t(e){t.superclass.constructor.call(this,e)};a.ATTRS={x:0,y:0,width:0,height:0,radius:0,lineWidth:1},r.extend(a,i),r.augment(a,{canFill:!0,canStroke:!0,type:"rect",getDefaultAttrs:function(){return{lineWidth:1,radius:0}},calculateBox:function(){var t=this.__attrs,e=t.x,n=t.y,r=t.width,i=t.height,o=this.getHitLineWidth()/2;return{minX:e-o,minY:n-o,maxX:e+r+o,maxY:n+i+o}},isPointInPath:function(t,e){var n=this.hasFill(),r=this.hasStroke();return n&&r?this.__isPointInFill(t,e)||this.__isPointInStroke(t,e):n?this.__isPointInFill(t,e):!!r&&this.__isPointInStroke(t,e)},__isPointInFill:function(t,e){var n=this.get("context");return!!n&&(this.createPath(),n.isPointInPath(t,e))},__isPointInStroke:function(t,e){var n=this.__attrs,r=n.x,i=n.y,a=n.width,s=n.height,u=n.radius,l=this.getHitLineWidth();if(0===u){var c=l/2;return o.line(r-c,i,r+a+c,i,l,t,e)||o.line(r+a,i-c,r+a,i+s+c,l,t,e)||o.line(r+a+c,i+s,r-c,i+s,l,t,e)||o.line(r,i+s+c,r,i-c,l,t,e)}return o.line(r+u,i,r+a-u,i,l,t,e)||o.line(r+a,i+u,r+a,i+s-u,l,t,e)||o.line(r+a-u,i+s,r+u,i+s,l,t,e)||o.line(r,i+s-u,r,i+u,l,t,e)||o.arcline(r+a-u,i+u,u,1.5*Math.PI,2*Math.PI,!1,l,t,e)||o.arcline(r+a-u,i+s-u,u,0,.5*Math.PI,!1,l,t,e)||o.arcline(r+u,i+s-u,u,.5*Math.PI,Math.PI,!1,l,t,e)||o.arcline(r+u,i+u,u,Math.PI,1.5*Math.PI,!1,l,t,e)},createPath:function(t){var e=this.__attrs,n=e.x,r=e.y,i=e.width,o=e.height,a=e.radius;(t=t||this.get("context")).beginPath(),0===a?t.rect(n,r,i,o):(t.moveTo(n+a,r),t.lineTo(n+i-a,r),t.arc(n+i-a,r+a,a,-Math.PI/2,0,!1),t.lineTo(n+i,r+o-a),t.arc(n+i-a,r+o-a,a,0,Math.PI/2,!1),t.lineTo(n+a,r+o),t.arc(n+a,r+o-a,a,Math.PI/2,Math.PI,!1),t.lineTo(n,r+a),t.arc(n+a,r+a,a,Math.PI,3*Math.PI/2,!1),t.closePath())}}),t.exports=a},function(t,e,n){var r=n(553),i=n(558).vec2;function o(t,e,n,r){return{x:Math.cos(r)*n+t,y:Math.sin(r)*n+e}}function a(t,e,n,r){var i=void 0,o=void 0;return r?t<e?(i=e-t,o=2*Math.PI-n+t):t>n&&(i=2*Math.PI-t+e,o=t-n):(i=t-e,o=n-t),i>o?n:e}function s(t,e,n,i){var o=0;return n-e>=2*Math.PI&&(o=2*Math.PI),e=r.mod(e,2*Math.PI),n=r.mod(n,2*Math.PI)+o,t=r.mod(t,2*Math.PI),i?e>=n?t>n&&t<e?t:a(t,n,e,!0):t<e||t>n?t:a(t,e,n):e<=n?e<t&&t<n?t:a(t,e,n,!0):t>e||t<n?t:a(t,n,e)}function u(t,e,n,r,o,a,u,l,c){var h=[u,l],f=[t,e],p=i.subtract([],h,f),d=i.angleTo([1,0],p);d=s(d,r,o,a);var g=[n*Math.cos(d)+t,n*Math.sin(d)+e];return c&&(c.x=g[0],c.y=g[1]),i.distance(g,h)}t.exports={nearAngle:s,projectPoint:function(t,e,n,r,i,o,a,s){var l={};return u(t,e,n,r,i,o,a,s,l),l},pointDistance:u,box:function(t,e,n,i,a,u){var l=Math.PI/2,c=Math.PI,h=3*Math.PI/2,f=[],p=s(0,i,a,u);0===p&&f.push(o(t,e,n,0)),(p=s(l,i,a,u))===l&&f.push(o(t,e,n,l)),(p=s(c,i,a,u))===c&&f.push(o(t,e,n,c)),(p=s(h,i,a,u))===h&&f.push(o(t,e,n,h)),f.push(o(t,e,n,i)),f.push(o(t,e,n,a));var d=1/0,g=-1/0,v=1/0,y=-1/0;return r.each(f,function(t){d>t.x&&(d=t.x),g<t.x&&(g=t.x),v>t.y&&(v=t.y),y<t.y&&(y=t.y)}),{minX:d,minY:v,maxX:g,maxY:y}}}},function(t,e,n){var r=n(553),i=n(558).vec2;function o(t,e,n,r){var i=1-r;return i*(i*t+2*r*e)+r*r*n}function a(t,e,n,r,a,s,u,l,c){var h=void 0,f=.005,p=1/0,d=void 0,g=void 0,v=void 0,y=void 0,m=void 0,x=void 0,b=[u,l];for(y=0;y<1;y+=.05)g=[o(t,n,a,y),o(e,r,s,y)],(d=i.squaredDistance(b,g))<p&&(h=y,p=d);for(p=1/0,x=0;x<32&&!(f<1e-4);x++){var _=h-f,w=h+f;g=[o(t,n,a,_),o(e,r,s,_)],d=i.squaredDistance(b,g),_>=0&&d<p?(h=_,p=d):(v=[o(t,n,a,w),o(e,r,s,w)],m=i.squaredDistance(b,v),w<=1&&m<p?(h=w,p=m):f*=.5)}return c&&(c.x=o(t,n,a,h),c.y=o(e,r,s,h)),Math.sqrt(p)}t.exports={at:o,projectPoint:function(t,e,n,r,i,o,s,u){var l={};return a(t,e,n,r,i,o,s,u,l),l},pointDistance:a,extrema:function(t,e,n){var i=t+n-2*e;if(r.isNumberEqual(i,0))return[.5];var o=(t-e)/i;return o<=1&&o>=0?[o]:[]}}},function(t,e,n){var r=n(558).vec2;t.exports={at:function(t,e,n){return(e-t)*n+t},pointDistance:function(t,e,n,i,o,a){var s=[n-t,i-e];if(r.exactEquals(s,[0,0]))return NaN;var u=[-s[1],s[0]];r.normalize(u,u);var l=[o-t,a-e];return Math.abs(r.dot(l,u))},box:function(t,e,n,r,i){var o=i/2,a=Math.min(t,n),s=Math.max(t,n);return{minX:a-o,minY:Math.min(e,r)-o,maxX:s+o,maxY:Math.max(e,r)+o}},len:function(t,e,n,r){return Math.sqrt((n-t)*(n-t)+(r-e)*(r-e))}}},function(t,e,n){var r="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},i=n(585),o="\t\n\v\f\r   ᠎              \u2028\u2029",a=new RegExp("([a-z])["+o+",]*((-?\\d*\\.?\\d*(?:e[\\-+]?\\d+)?["+o+"]*,?["+o+"]*)+)","ig"),s=new RegExp("(-?\\d*\\.?\\d*(?:e[\\-+]?\\d+)?)["+o+"]*,?["+o+"]*","ig"),u=function(t){if(!t)return null;if((void 0===t?"undefined":r(t))===r([]))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(a,function(t,r,i){var o=[],a=r.toLowerCase();if(i.replace(s,function(t,e){e&&o.push(+e)}),"m"===a&&o.length>2&&(n.push([r].concat(o.splice(0,2))),a="l",r="m"===r?"l":"L"),"o"===a&&1===o.length&&n.push([r,o[0]]),"r"===a)n.push([r].concat(o));else for(;o.length>=e[a]&&(n.push([r].concat(o.splice(0,e[a]))),e[a]););}),n},l=function(t,e){for(var n=[],r=0,i=t.length;i-2*!e>r;r+=2){var o=[{x:+t[r-2],y:+t[r-1]},{x:+t[r],y:+t[r+1]},{x:+t[r+2],y:+t[r+3]},{x:+t[r+4],y:+t[r+5]}];e?r?i-4===r?o[3]={x:+t[0],y:+t[1]}:i-2===r&&(o[2]={x:+t[0],y:+t[1]},o[3]={x:+t[2],y:+t[3]}):o[0]={x:+t[i-2],y:+t[i-1]}:i-4===r?o[3]=o[2]:r||(o[0]={x:+t[r],y:+t[r+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},c=function(t,e,n,r,i){var o=[];if(null===i&&null===r&&(r=n),t=+t,e=+e,n=+n,r=+r,null!==i){var a=Math.PI/180,s=t+n*Math.cos(-r*a),u=t+n*Math.cos(-i*a);o=[["M",s,e+n*Math.sin(-r*a)],["A",n,n,0,+(i-r>180),0,u,e+n*Math.sin(-i*a)]]}else o=[["M",t,e],["m",0,-r],["a",n,r,0,1,1,0,2*r],["a",n,r,0,1,1,0,-2*r],["z"]];return o},h=function(t){if(!(t=u(t))||!t.length)return[["M",0,0]];var e=[],n=0,r=0,i=0,o=0,a=0,s=void 0,h=void 0;"M"===t[0][0]&&(i=n=+t[0][1],o=r=+t[0][2],a++,e[0]=["M",n,r]);for(var f,p,d=3===t.length&&"M"===t[0][0]&&"R"===t[1][0].toUpperCase()&&"Z"===t[2][0].toUpperCase(),g=a,v=t.length;g<v;g++){if(e.push(f=[]),(s=(p=t[g])[0])!==s.toUpperCase())switch(f[0]=s.toUpperCase(),f[0]){case"A":f[1]=p[1],f[2]=p[2],f[3]=p[3],f[4]=p[4],f[5]=p[5],f[6]=+p[6]+n,f[7]=+p[7]+r;break;case"V":f[1]=+p[1]+r;break;case"H":f[1]=+p[1]+n;break;case"R":for(var y=2,m=(h=[n,r].concat(p.slice(1))).length;y<m;y++)h[y]=+h[y]+n,h[++y]=+h[y]+r;e.pop(),e=e.concat(l(h,d));break;case"O":e.pop(),(h=c(n,r,p[1],p[2])).push(h[0]),e=e.concat(h);break;case"U":e.pop(),e=e.concat(c(n,r,p[1],p[2],p[3])),f=["U"].concat(e[e.length-1].slice(-2));break;case"M":i=+p[1]+n,o=+p[2]+r;break;default:for(var x=1,b=p.length;x<b;x++)f[x]=+p[x]+(x%2?n:r)}else if("R"===s)h=[n,r].concat(p.slice(1)),e.pop(),e=e.concat(l(h,d)),f=["R"].concat(p.slice(-2));else if("O"===s)e.pop(),(h=c(n,r,p[1],p[2])).push(h[0]),e=e.concat(h);else if("U"===s)e.pop(),e=e.concat(c(n,r,p[1],p[2],p[3])),f=["U"].concat(e[e.length-1].slice(-2));else for(var _=0,w=p.length;_<w;_++)f[_]=p[_];if("O"!==(s=s.toUpperCase()))switch(f[0]){case"Z":n=+i,r=+o;break;case"H":n=f[1];break;case"V":r=f[1];break;case"M":i=f[f.length-2],o=f[f.length-1];break;default:n=f[f.length-2],r=f[f.length-1]}}return e},f=function(t,e,n,r){return[t,e,n,r,n,r]},p=function(t,e,n,r,i,o){return[1/3*t+2/3*n,1/3*e+2/3*r,1/3*i+2/3*n,1/3*o+2/3*r,i,o]},d=function(t,e){var n=h(t),r=e&&h(e),i={x:0,y:0,bx:0,by:0,X:0,Y:0,qx:null,qy:null},o={x:0,y:0,bx:0,by:0,X:0,Y:0,qx:null,qy:null},a=[],s=[],u="",l="",c=void 0,d=function(t,e,n){var r=void 0,i=void 0;if(!t)return["C",e.x,e.y,e.x,e.y,e.x,e.y];switch(!(t[0]in{T:1,Q:1})&&(e.qx=e.qy=null),t[0]){case"M":e.X=t[1],e.Y=t[2];break;case"A":t=["C"].concat(function t(e,n,r,i,o,a,s,u,l,c){r===i&&(r+=1);var h=120*Math.PI/180,f=Math.PI/180*(+o||0),p=[],d=void 0,g=void 0,v=void 0,y=void 0,m=void 0,x=function(t,e,n){return{x:t*Math.cos(n)-e*Math.sin(n),y:t*Math.sin(n)+e*Math.cos(n)}};if(c)g=c[0],v=c[1],y=c[2],m=c[3];else{e=(d=x(e,n,-f)).x,n=d.y,u=(d=x(u,l,-f)).x,l=d.y,e===u&&n===l&&(u+=1,l+=1);var b=(e-u)/2,_=(n-l)/2,w=b*b/(r*r)+_*_/(i*i);w>1&&(r*=w=Math.sqrt(w),i*=w);var S=r*r,M=i*i,C=(a===s?-1:1)*Math.sqrt(Math.abs((S*M-S*_*_-M*b*b)/(S*_*_+M*b*b)));y=C*r*_/i+(e+u)/2,m=C*-i*b/r+(n+l)/2,g=Math.asin(((n-m)/i).toFixed(9)),v=Math.asin(((l-m)/i).toFixed(9)),g=e<y?Math.PI-g:g,v=u<y?Math.PI-v:v,g<0&&(g=2*Math.PI+g),v<0&&(v=2*Math.PI+v),s&&g>v&&(g-=2*Math.PI),!s&&v>g&&(v-=2*Math.PI)}var P=v-g;if(Math.abs(P)>h){var A=v,I=u,O=l;v=g+h*(s&&v>g?1:-1),p=t(u=y+r*Math.cos(v),l=m+i*Math.sin(v),r,i,o,0,s,I,O,[v,A,y,m])}P=v-g;var E=Math.cos(g),T=Math.sin(g),k=Math.cos(v),j=Math.sin(v),L=Math.tan(P/4),D=4/3*r*L,F=4/3*i*L,R=[e,n],B=[e+D*T,n-F*E],N=[u+D*j,l-F*k],z=[u,l];if(B[0]=2*R[0]-B[0],B[1]=2*R[1]-B[1],c)return[B,N,z].concat(p);for(var V=[],G=0,Y=(p=[B,N,z].concat(p).join().split(",")).length;G<Y;G++)V[G]=G%2?x(p[G-1],p[G],f).y:x(p[G],p[G+1],f).x;return V}.apply(0,[e.x,e.y].concat(t.slice(1))));break;case"S":"C"===n||"S"===n?(r=2*e.x-e.bx,i=2*e.y-e.by):(r=e.x,i=e.y),t=["C",r,i].concat(t.slice(1));break;case"T":"Q"===n||"T"===n?(e.qx=2*e.x-e.qx,e.qy=2*e.y-e.qy):(e.qx=e.x,e.qy=e.y),t=["C"].concat(p(e.x,e.y,e.qx,e.qy,t[1],t[2]));break;case"Q":e.qx=t[1],e.qy=t[2],t=["C"].concat(p(e.x,e.y,t[1],t[2],t[3],t[4]));break;case"L":t=["C"].concat(f(e.x,e.y,t[1],t[2]));break;case"H":t=["C"].concat(f(e.x,e.y,t[1],e.y));break;case"V":t=["C"].concat(f(e.x,e.y,e.x,t[1]));break;case"Z":t=["C"].concat(f(e.x,e.y,e.X,e.Y))}return t},g=function(t,e){if(t[e].length>7){t[e].shift();for(var i=t[e];i.length;)a[e]="A",r&&(s[e]="A"),t.splice(e++,0,["C"].concat(i.splice(0,6)));t.splice(e,1),c=Math.max(n.length,r&&r.length||0)}},v=function(t,e,i,o,a){t&&e&&"M"===t[a][0]&&"M"!==e[a][0]&&(e.splice(a,0,["M",o.x,o.y]),i.bx=0,i.by=0,i.x=t[a][1],i.y=t[a][2],c=Math.max(n.length,r&&r.length||0))};c=Math.max(n.length,r&&r.length||0);for(var y=0;y<c;y++){n[y]&&(u=n[y][0]),"C"!==u&&(a[y]=u,y&&(l=a[y-1])),n[y]=d(n[y],i,l),"A"!==a[y]&&"C"===u&&(a[y]="C"),g(n,y),r&&(r[y]&&(u=r[y][0]),"C"!==u&&(s[y]=u,y&&(l=s[y-1])),r[y]=d(r[y],o,l),"A"!==s[y]&&"C"===u&&(s[y]="C"),g(r,y)),v(n,r,i,o,y),v(r,n,o,i,y);var m=n[y],x=r&&r[y],b=m.length,_=r&&x.length;i.x=m[b-2],i.y=m[b-1],i.bx=parseFloat(m[b-4])||i.x,i.by=parseFloat(m[b-3])||i.y,o.bx=r&&(parseFloat(x[_-4])||o.x),o.by=r&&(parseFloat(x[_-3])||o.y),o.x=r&&x[_-2],o.y=r&&x[_-1]}return r?[n,r]:n},g=/,?([a-z]),?/gi,v=function(t){return t.join(",").replace(g,"$1")},y=function(t,e,n,r,i){return t*(t*(-3*e+9*n-9*r+3*i)+6*e-12*n+6*r)-3*e+3*n},m=function(t,e,n,r,i,o,a,s,u){null===u&&(u=1);for(var l=(u=u>1?1:u<0?0:u)/2,c=[-.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*c[p]+l,g=y(d,t,n,i,a),v=y(d,e,r,o,s),m=g*g+v*v;f+=h[p]*Math.sqrt(m)}return l*f},x=function(t,e,n,r,i,o,a,s){if(!(Math.max(t,n)<Math.min(i,a)||Math.min(t,n)>Math.max(i,a)||Math.max(e,r)<Math.min(o,s)||Math.min(e,r)>Math.max(o,s))){var u=(t-n)*(o-s)-(e-r)*(i-a);if(u){var l=((t*r-e*n)*(i-a)-(t-n)*(i*s-o*a))/u,c=((t*r-e*n)*(o-s)-(e-r)*(i*s-o*a))/u,h=+l.toFixed(2),f=+c.toFixed(2);if(!(h<+Math.min(t,n).toFixed(2)||h>+Math.max(t,n).toFixed(2)||h<+Math.min(i,a).toFixed(2)||h>+Math.max(i,a).toFixed(2)||f<+Math.min(e,r).toFixed(2)||f>+Math.max(e,r).toFixed(2)||f<+Math.min(o,s).toFixed(2)||f>+Math.max(o,s).toFixed(2)))return{x:l,y:c}}}},b=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,r,i){if(i)return[["M",+t+ +i,e],["l",n-2*i,0],["a",i,i,0,0,1,i,i],["l",0,r-2*i],["a",i,i,0,0,1,-i,i],["l",2*i-n,0],["a",i,i,0,0,1,-i,-i],["l",0,2*i-r],["a",i,i,0,0,1,i,-i],["z"]];var o=[["M",t,e],["l",n,0],["l",0,r],["l",-n,0],["z"]];return o.parsePathArray=v,o},w=function(t,e,n,r){return null===t&&(t=e=n=r=0),null===e&&(e=t.y,n=t.width,r=t.height,t=t.x),{x:t,y:e,width:n,w:n,height:r,h:r,x2:t+n,y2:e+r,cx:t+n/2,cy:e+r/2,r1:Math.min(n,r)/2,r2:Math.max(n,r)/2,r0:Math.sqrt(n*n+r*r)/2,path:_(t,e,n,r),vb:[t,e,n,r].join(" ")}},S=function(t,e,n,r,o,a,s,u){i.isArray(t)||(t=[t,e,n,r,o,a,s,u]);var l=function(t,e,n,r,i,o,a,s){for(var u=[],l=[[],[]],c=void 0,h=void 0,f=void 0,p=void 0,d=0;d<2;++d)if(0===d?(h=6*t-12*n+6*i,c=-3*t+9*n-9*i+3*a,f=3*n-3*t):(h=6*e-12*r+6*o,c=-3*e+9*r-9*o+3*s,f=3*r-3*e),Math.abs(c)<1e-12){if(Math.abs(h)<1e-12)continue;(p=-f/h)>0&&p<1&&u.push(p)}else{var g=h*h-4*f*c,v=Math.sqrt(g);if(!(g<0)){var y=(-h+v)/(2*c);y>0&&y<1&&u.push(y);var m=(-h-v)/(2*c);m>0&&m<1&&u.push(m)}}for(var x=u.length,b=x,_=void 0;x--;)_=1-(p=u[x]),l[0][x]=_*_*_*t+3*_*_*p*n+3*_*p*p*i+p*p*p*a,l[1][x]=_*_*_*e+3*_*_*p*r+3*_*p*p*o+p*p*p*s;return l[0][b]=t,l[1][b]=e,l[0][b+1]=a,l[1][b+1]=s,l[0].length=l[1].length=b+2,{min:{x:Math.min.apply(0,l[0]),y:Math.min.apply(0,l[1])},max:{x:Math.max.apply(0,l[0]),y:Math.max.apply(0,l[1])}}}.apply(null,t);return w(l.min.x,l.min.y,l.max.x-l.min.x,l.max.y-l.min.y)},M=function(t,e,n,r,i,o,a,s,u){var l=1-u,c=Math.pow(l,3),h=Math.pow(l,2),f=u*u,p=f*u,d=t+2*u*(n-t)+f*(i-2*n+t),g=e+2*u*(r-e)+f*(o-2*r+e),v=n+2*u*(i-n)+f*(a-2*i+n),y=r+2*u*(o-r)+f*(s-2*o+r);return{x:c*t+3*h*u*n+3*l*u*u*i+p*a,y:c*e+3*h*u*r+3*l*u*u*o+p*s,m:{x:d,y:g},n:{x:v,y:y},start:{x:l*t+u*n,y:l*e+u*r},end:{x:l*i+u*a,y:l*o+u*s},alpha:90-180*Math.atan2(d-v,g-y)/Math.PI}},C=function(t,e,n){if(!function(t,e){return t=w(t),e=w(e),b(e,t.x,t.y)||b(e,t.x2,t.y)||b(e,t.x,t.y2)||b(e,t.x2,t.y2)||b(t,e.x,e.y)||b(t,e.x2,e.y)||b(t,e.x,e.y2)||b(t,e.x2,e.y2)||(t.x<e.x2&&t.x>e.x||e.x<t.x2&&e.x>t.x)&&(t.y<e.y2&&t.y>e.y||e.y<t.y2&&e.y>t.y)}(S(t),S(e)))return n?0:[];for(var r=~~(m.apply(0,t)/8),i=~~(m.apply(0,e)/8),o=[],a=[],s={},u=n?0:[],l=0;l<r+1;l++){var c=M.apply(0,t.concat(l/r));o.push({x:c.x,y:c.y,t:l/r})}for(var h=0;h<i+1;h++){var f=M.apply(0,e.concat(h/i));a.push({x:f.x,y:f.y,t:h/i})}for(var p=0;p<r;p++)for(var d=0;d<i;d++){var g=o[p],v=o[p+1],y=a[d],_=a[d+1],C=Math.abs(v.x-g.x)<.001?"y":"x",P=Math.abs(_.x-y.x)<.001?"y":"x",A=x(g.x,g.y,v.x,v.y,y.x,y.y,_.x,_.y);if(A){if(s[A.x.toFixed(4)]===A.y.toFixed(4))continue;s[A.x.toFixed(4)]=A.y.toFixed(4);var I=g.t+Math.abs((A[C]-g[C])/(v[C]-g[C]))*(v.t-g.t),O=y.t+Math.abs((A[P]-y[P])/(_[P]-y[P]))*(_.t-y.t);I>=0&&I<=1&&O>=0&&O<=1&&(n?u++:u.push({x:A.x,y:A.y,t1:I,t2:O}))}}return u};t.exports={parsePathString:u,parsePathArray:v,pathTocurve:d,pathToAbsolute:h,catmullRomToBezier:l,rectPath:_,intersection:function(t,e){return function(t,e,n){t=d(t),e=d(e);for(var r=void 0,i=void 0,o=void 0,a=void 0,s=void 0,u=void 0,l=void 0,c=void 0,h=void 0,f=void 0,p=n?0:[],g=0,v=t.length;g<v;g++){var y=t[g];if("M"===y[0])r=s=y[1],i=u=y[2];else{"C"===y[0]?(r=(h=[r,i].concat(y.slice(1)))[6],i=h[7]):(h=[r,i,r,i,s,u,s,u],r=s,i=u);for(var m=0,x=e.length;m<x;m++){var b=e[m];if("M"===b[0])o=l=b[1],a=c=b[2];else{"C"===b[0]?(o=(f=[o,a].concat(b.slice(1)))[6],a=f[7]):(f=[o,a,o,a,l,c,l,c],o=l,a=c);var _=C(h,f,n);if(n)p+=_;else{for(var w=0,S=_.length;w<S;w++)_[w].segment1=g,_[w].segment2=m,_[w].bez1=h,_[w].bez2=f;p=p.concat(_)}}}}}return p}(t,e)}}},function(t,e){var n={EPSILON:1e-6};n.ARRAY_TYPE="undefined"!=typeof Float32Array?Float32Array:Array,n.RANDOM=Math.random,n.ENABLE_SIMD=!1,n.SIMD_AVAILABLE=n.ARRAY_TYPE===Float32Array&&"SIMD"in this,n.USE_SIMD=n.ENABLE_SIMD&&n.SIMD_AVAILABLE,n.setMatrixArrayType=function(t){n.ARRAY_TYPE=t};var r=Math.PI/180;n.toRadian=function(t){return t*r},n.equals=function(t,e){return Math.abs(t-e)<=n.EPSILON*Math.max(1,Math.abs(t),Math.abs(e))},t.exports=n},function(t,e,n){var r=n(933);t.exports=function(t){var e=new t.constructor(t.byteLength);return new r(e).set(new r(t)),e}},function(t,e,n){var r=n(968);n(787),n(785),n(783),n(782),n(780),n(649),n(778),n(776),n(774),n(772),n(769),t.exports=r},,,,function(t,e,n){var r=n(879);t.exports=function(t){var e=r(t),n=e%1;return e==e?n?e-n:e:0}},,function(t,e,n){var r=n(901),i=n(565);t.exports=function(t){return null==t?[]:r(t,i(t))}},,function(t,e,n){var r=n(254),i=n(49);t.exports=function(t){return i(t)&&r(t)}},function(t,e,n){var r=n(921)();t.exports=r},,,function(t,e,n){"use strict";function r(t){return+t}function i(t){return t*t}function o(t){return t*(2-t)}function a(t){return((t*=2)<=1?t*t:--t*(2-t)+1)/2}function s(t){return t*t*t}function u(t){return--t*t*t+1}function l(t){return((t*=2)<=1?t*t*t:(t-=2)*t*t+2)/2}n.r(e);var c=function t(e){function n(t){return Math.pow(t,e)}return e=+e,n.exponent=t,n}(3),h=function t(e){function n(t){return 1-Math.pow(1-t,e)}return e=+e,n.exponent=t,n}(3),f=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),p=Math.PI,d=p/2;function g(t){return 1-Math.cos(t*d)}function v(t){return Math.sin(t*d)}function y(t){return(1-Math.cos(p*t))/2}function m(t){return Math.pow(2,10*t-10)}function x(t){return 1-Math.pow(2,-10*t)}function b(t){return((t*=2)<=1?Math.pow(2,10*t-10):2-Math.pow(2,10-10*t))/2}function _(t){return 1-Math.sqrt(1-t*t)}function w(t){return Math.sqrt(1- --t*t)}function S(t){return((t*=2)<=1?1-Math.sqrt(1-t*t):Math.sqrt(1-(t-=2)*t)+1)/2}var M=4/11,C=6/11,P=8/11,A=.75,I=9/11,O=10/11,E=.9375,T=21/22,k=63/64,j=1/M/M;function L(t){return 1-D(1-t)}function D(t){return(t=+t)<M?j*t*t:t<P?j*(t-=C)*t+A:t<O?j*(t-=I)*t+E:j*(t-=T)*t+k}function F(t){return((t*=2)<=1?1-D(1-t):D(t-1)+1)/2}var R=function t(e){function n(t){return t*t*((e+1)*t-e)}return e=+e,n.overshoot=t,n}(1.70158),B=function t(e){function n(t){return--t*t*((e+1)*t+e)+1}return e=+e,n.overshoot=t,n}(1.70158),N=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),z=2*Math.PI,V=function t(e,n){var r=Math.asin(1/(e=Math.max(1,e)))*(n/=z);function i(t){return e*Math.pow(2,10*--t)*Math.sin((r-t)/n)}return i.amplitude=function(e){return t(e,n*z)},i.period=function(n){return t(e,n)},i}(1,.3),G=function t(e,n){var r=Math.asin(1/(e=Math.max(1,e)))*(n/=z);function i(t){return 1-e*Math.pow(2,-10*(t=+t))*Math.sin((t+r)/n)}return i.amplitude=function(e){return t(e,n*z)},i.period=function(n){return t(e,n)},i}(1,.3),Y=function t(e,n){var r=Math.asin(1/(e=Math.max(1,e)))*(n/=z);function i(t){return((t=2*t-1)<0?e*Math.pow(2,10*t)*Math.sin((r-t)/n):2-e*Math.pow(2,-10*t)*Math.sin((r+t)/n))/2}return i.amplitude=function(e){return t(e,n*z)},i.period=function(n){return t(e,n)},i}(1,.3);n.d(e,"easeLinear",function(){return r}),n.d(e,"easeQuad",function(){return a}),n.d(e,"easeQuadIn",function(){return i}),n.d(e,"easeQuadOut",function(){return o}),n.d(e,"easeQuadInOut",function(){return a}),n.d(e,"easeCubic",function(){return l}),n.d(e,"easeCubicIn",function(){return s}),n.d(e,"easeCubicOut",function(){return u}),n.d(e,"easeCubicInOut",function(){return l}),n.d(e,"easePoly",function(){return f}),n.d(e,"easePolyIn",function(){return c}),n.d(e,"easePolyOut",function(){return h}),n.d(e,"easePolyInOut",function(){return f}),n.d(e,"easeSin",function(){return y}),n.d(e,"easeSinIn",function(){return g}),n.d(e,"easeSinOut",function(){return v}),n.d(e,"easeSinInOut",function(){return y}),n.d(e,"easeExp",function(){return b}),n.d(e,"easeExpIn",function(){return m}),n.d(e,"easeExpOut",function(){return x}),n.d(e,"easeExpInOut",function(){return b}),n.d(e,"easeCircle",function(){return S}),n.d(e,"easeCircleIn",function(){return _}),n.d(e,"easeCircleOut",function(){return w}),n.d(e,"easeCircleInOut",function(){return S}),n.d(e,"easeBounce",function(){return D}),n.d(e,"easeBounceIn",function(){return L}),n.d(e,"easeBounceOut",function(){return D}),n.d(e,"easeBounceInOut",function(){return F}),n.d(e,"easeBack",function(){return N}),n.d(e,"easeBackIn",function(){return R}),n.d(e,"easeBackOut",function(){return B}),n.d(e,"easeBackInOut",function(){return N}),n.d(e,"easeElastic",function(){return G}),n.d(e,"easeElasticIn",function(){return V}),n.d(e,"easeElasticOut",function(){return G}),n.d(e,"easeElasticInOut",function(){return Y})},,,,,,function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=o(n(0)),i=o(n(581));function o(t){return t&&t.__esModule?t:{default:t}}for(var a=["mouseenter","mousemove","mouseleave","click","dblclick","mousedown","mouseup","touchstart","touchmove","touchend"],s=["Mouseenter","Mousemove","Mouseleave","Click","Dblclick","Mousedown","Mouseup","Touchstart","Touchmove","Touchend"],u=["point","area","line","path","interval","schema","polygon","edge","axis-title","axis-label","axis-ticks","axis-line","axis-grid","legend-title","legend-item","legend-marker","legend-text","guide-text","guide-region","guide-line","guide-image","label"],l=["onPoint","onArea","onLine","onPath","onInterval","onSchema","onPolygon","onEdge","onAxisTitle","onAxisLabel","onAxisTicks","onAxisLine","onAxisGrid","onLegendTitle","onLegendItem","onLegendMarker","onLegendText","onGuideText","onGuideRegion","onGuideLine","onGuideImage","onLabel"],c=[],h=0;h<u.length;h+=1)for(var f=0;f<a.length;f+=1)c.push({prop:""+l[h]+s[f],event:u[h]+":"+a[f]});var p=[{prop:"onPlotMove",event:"plotmove"},{prop:"onPlotEnter",event:"plotenter"},{prop:"onPlotLeave",event:"plotleave"},{prop:"onPlotClick",event:"plotclick"},{prop:"onPlotDblClick",event:"plotdblclick"},{prop:"onItemSelected",event:"itemselected"},{prop:"onItemUnselected",event:"itemunselected"},{prop:"onItemSelectedChange",event:"itemselectedchange"},{prop:"onTooltipChange",event:"tooltip:change"},{prop:"onTooltipShow",event:"tooltip:show"},{prop:"onTooltipHide",event:"tooltip:hide"}].concat(c);function d(){return[{prop:"onMouseEnter",event:"mouseenter"},{prop:"onMouseMove",event:"mousemove"},{prop:"onMouseLeave",event:"mouseleave"},{prop:"onClick",event:"click"},{prop:"onDblClick",event:"dblclick"},{prop:"onMouseDown",event:"mousedown"},{prop:"onMouseUp",event:"mouseup"},{prop:"onTouchStart",event:"touchstart"},{prop:"onTouchMove",event:"touchmove"},{prop:"onTouchEnd",event:"touchend"}]}var g=[{prop:"onMouseEnter",event:"mouseenter"},{prop:"onMouseMove",event:"mousemove"},{prop:"onMouseLeave",event:"mouseleave"},{prop:"onClick",event:"click"},{prop:"onDblClick",event:"dblclick"},{prop:"onMouseDown",event:"mousedown"},{prop:"onMouseUp",event:"mouseup"},{prop:"onTouchStart",event:"touchstart"},{prop:"onTouchMove",event:"touchmove"},{prop:"onTouchEnd",event:"touchend"}],v={onMouseEnter:r.default.object,onMouseMove:r.default.object,onMouseLeave:r.default.object,onClick:r.default.oneOfType([r.default.object,r.default.func]),onDblClick:r.default.object,onMouseDown:r.default.object,onMouseUp:r.default.object,onTouchStart:r.default.object,onTouchMove:r.default.object,onTouchEnd:r.default.object},y={onMouseEnter:r.default.func,onMouseMove:r.default.func,onMouseLeave:r.default.func,onClick:r.default.func,onDblClick:r.default.func,onMouseDown:r.default.func,onMouseUp:r.default.func,onTouchStart:r.default.func,onTouchMove:r.default.func,onTouchEnd:r.default.func};function m(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments[2];i.default.each(e,function(e){var r=e.prop,o=e.event,a=n[r];if(i.default.isFunction(a))t.on(o,a);else if(i.default.isObject(a))for(var s in a)void 0!==a[s]&&t.on(s+":"+o,a[s])})}function x(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments[2],r=arguments[3];i.default.each(e,function(e){var o=e.prop,a=e.event,s=n[o],u=r[o],l=void 0;if(!i.default.shallowEqual(s,u))if(i.default.isFunction(s)&&i.default.isFunction(u))t.off(a,s),t.on(a,u);else if(i.default.isObject(s)&&i.default.isObject(u)){for(l in s)Object.prototype.hasOwnProperty.call(s,l)&&t.off(l+":"+a,s[l]);for(l in u)Object.prototype.hasOwnProperty.call(u,l)&&t.on(l+":"+a,u[l])}})}function b(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments[2];i.default.each(e,function(e){var r=e.prop,o=e.event,a=n[r];if(i.default.isFunction(a))t.off(o,a);else if(i.default.isObject(a))for(var s in a)Object.prototype.hasOwnProperty.call(a,s)&&t.off(s+":"+o,a[s])})}e.default={baseEventObjectTypes:v,baseEventFuncTypes:y,genBaseEvents:d,genItemBaseEvents:function(t){var e=[{prop:"onMouseEnter",event:"mouseenter"},{prop:"onMouseMove",event:"mousemove"},{prop:"onMouseLeave",event:"mouseleave"},{prop:"onClick",event:"click"},{prop:"onDblClick",event:"dblclick"},{prop:"onMouseDown",event:"mousedown"},{prop:"onMouseUp",event:"mouseup"},{prop:"onTouchStart",event:"touchstart"},{prop:"onTouchMove",event:"touchmove"},{prop:"onTouchEnd",event:"touchend"}];return i.default.map(e,function(e){var n=e.event;return e.event=t+":"+n,e}),e},bindEvents:m,bindBaseEvents:function(t,e){m(t,g,e)},updateEvents:x,updateBaseEvents:function(t,e,n){x(t,g,e,n)},unbindEvents:b,unbindBaseEvents:function(t,e){b(t,g,e)},chartEvents:p}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},i=l(n(626)),o=n(613),a=l(n(646)),s=l(n(644)),u=l(n(614));function l(t){return t&&t.__esModule?t:{default:t}}function c(t){if(Array.isArray(t)){for(var e=0,n=Array(t.length);e<t.length;e++)n[e]=t[e];return n}return Array.from(t)}function h(t,e){var n={};for(var r in t)e.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(t,r)&&(n[r]=t[r]);return n}var f=a.default.COORD_FUNC_PROPS,p=a.default.GEOM_FUNC_PROPS;e.default={createChart:function(t){var e=t.chart,n=new i.default.Chart(e.props);return e.g2Instance=n,n},executeChartConfig:function(t,e){var n=e.chart.props;t.coord("rect",{}),t.source(n.data,n.scale),(e.facet||n.axis)&&e.facet&&!1!==n.axis||t.axis(!1),t.legend(!1),t.tooltip(!1),n.filter&&n.filter.forEach(function(e){t.filter(e[0],e[1])}),s.default.bindEvents(t,s.default.chartEvents,n),s.default.bindBaseEvents(t,n)},coord:function(t,e){var n=e.coord;if(n&&!n.g2Instance){var r=n.props,i=r.type,a=h(r,["type"]),s=t.coord(i||"rect",o.Util.without(a,f));o.Prop.init(f,a,function(t,e){s[e].apply(s,c(t))}),n.g2Instance=s}},createLabel:function(t,e){if(e&&!e.g2Instance){var n=e.props,r=n.content,i=h(n,["content"]);r&&(o.Util.isArray(r)?e.g2Instance=t.label(r[0],r[1],i):e.g2Instance=t.label(r,i))}},createGeom:function(t,e){if(e.g2Instance)e.label&&this.createLabel(e.g2Instance,e.label);else{var n=e.props,r=t[n.type||"interval"]();n.adjust&&r.adjust(n.adjust),o.Prop.init(p,n,function(t,e){r[e].apply(r,c(t))}),e.g2Instance=r,this.createLabel(r,e.label)}},geoms:function(t,e){var n=e.geoms;if(n)for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&this.createGeom(t,n[r])},legends:function(t,e){var n=e.legends;for(var r in n)if(n[r]){var i=n[r];if(i.g2Instance)return;var o=i.props,a=o.name,s=o.visible,u=h(o,["name","visible"]),l=s;Object.prototype.hasOwnProperty.call(i.props,"visible")||(l=!0);var f=l?u:l;i.g2Instance=t.legend.apply(t,c(a?[a,f]:[f]))}},tooltip:function(t,e){var n=e.tooltip;n&&!n.g2Instance&&(n.g2Instance=t.tooltip(r({},n.props)))},createAxis:function(t,e){if(!e.g2Instance){var n=e.props,r=n.name,i=n.visible,o=h(n,["name","visible"]);i||!Object.prototype.hasOwnProperty.call(e.props,"visible")?e.g2Instance=t.axis(r,o):e.g2Instance=t.axis(r,!1)}},axises:function(t,e){var n=e.axises;for(var r in n)n[r]&&this.createAxis(t,n[r])},views:function(t,e){var n=e.views;for(var r in n)n[r]&&this.createView(t,n[r])},createView:function(t,e){if("Facet"!==e.parentInfo.name){if(e.g2Instance)return e.filter&&e.filter.forEach(function(t){e.g2Instance.filter(t[0],t[1])}),this.coord(e.g2Instance,e),this.axises(e.g2Instance,e),this.geoms(e.g2Instance,e),void this.guide(e.g2Instance,e.guide);var n=e.props,i=n.scale,o=n.data,a=n.instance,s=n.axis,u=n.filter,l=(n.geoms,h(n,["scale","data","instance","axis","filter","geoms"])),c=void 0;c=a||t.view(r({},l)),o&&c.source(o,i),i&&c.scale(i),u&&u.forEach(function(t){c.filter(t[0],t[1])}),!0===s||a||c.axis(!1),e.g2Instance=c,this.coord(c,e),this.axises(c,e),this.geoms(c,e),this.guide(c,e.guide)}},facetView:function(t,e){var n=e.props,r=n.scale,i=n.data,o=n.axis;n.geoms,h(n,["scale","data","axis","geoms"]);i&&t.source(i,r),r&&t.scale(r),!1===o&&t.axis(!1),this.coord(t,e),this.axises(t,e),this.geoms(t,e),this.guide(t,e.guide),u.default.mergeView(e,!0)},guide:function(t,e){if(e){var n=e.elements;for(var r in n)if(n[r]){var i=n[r];if(!i.g2Instance){var o=i.props,a=(o.type,h(o,["type"]));i.g2Instance=t.guide()[i.type](a)}}}},facet:function(t,e){var n=this,r=e.facet;if(r&&!r.g2Instance){var i=r.props,o=i.children,a=i.type,s=h(i,["children","type"]);if(o){var l=e.views,c=null;for(var f in l)if(l[f]&&"Facet"===l[f].parentInfo.name&&l[f].parentInfo.id===r.id){c=l[f];break}c&&(u.default.mergeView(c,!0),s.eachView=function(t){n.facetView(t,c)},t.facet(a,s))}else t.facet(a,s)}},synchronizeG2Add:function(t,e){this.coord(t,e),this.axises(t,e),this.legends(t,e),this.tooltip(t,e),this.geoms(t,e),this.facet(t,e),this.views(t,e),this.guide(t,e.guide)},synchronizeG2Views:function(t,e){var n=e.views;for(var r in n)n[r]&&this.synchronizeG2View(n[r].g2Instance,n[r])},synchronizeG2View:function(t,e){t.clear(),this.clearViewG2Instance(e);var n=e.props,r=n.scale,i=n.data,o=n.instance,a=n.axis;n.geoms,h(n,["scale","data","instance","axis","geoms"]);i&&t.source(i,r),r&&t.scale(r),!0===a||o||t.axis(!1),this.coord(t,e),this.axises(t,e),this.geoms(t,e),this.guide(t,e.guide)},clearViewG2Instance:function(t){t.coord&&delete t.coord.g2Instance,t.axises&&Object.keys(t.axises).forEach(function(e){delete t.axises[e].g2Instance}),t.geoms&&Object.keys(t.geoms).forEach(function(e){delete t.geoms[e].g2Instance,t.geoms[e].label&&delete t.geoms[e].label.g2Instance}),t.guide&&t.guide.elements&&Object.keys(t.guide.elements).forEach(function(e){delete t.guide.elements[e].g2Instance})}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={COORD_FUNC_PROPS:["rotate","scale","reflect","transpose"],GEOM_FUNC_PROPS:["position","color","size","shape","opacity","tooltip","style","animate","active","select"]}},function(t,e,n){var r=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return e.type="list",e.cols=null,e},e.prototype.generateFacets=function(t){var e=this,n=e.fields[0];if(!n)throw"Please specify for the field for facet!";var r=e.getFieldValues(n,t),i=r.length,o=e.cols||i,a=parseInt((i+o-1)/o),s=[];return r.forEach(function(u,l){var c=parseInt(l/o),h=l%o,f=[{field:n,value:u,values:r}],p=e.getFilter(f),d=t.filter(p),g={type:e.type,count:i,colValue:u,colField:n,rowField:null,rowValue:u,colIndex:h,rowIndex:c,cols:o,rows:a,data:d,region:e.getRegion(a,o,h,c)};s.push(g)}),s},e.prototype.setXAxis=function(t,e,n){n.rowIndex!==n.rows-1&&n.cols*n.rowIndex+n.colIndex+1+n.cols<=n.count&&(e[t].label=null,e[t].title=null)},e.prototype.setYAxis=function(t,e,n){0!==n.colIndex&&(e[t].title=null,e[t].label=null)},e}(n(590));t.exports=r},function(t,e,n){var r=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return e.type="rect",e},e.prototype.generateFacets=function(t){var e=this,n=e.fields,r=[],i=1,o=1,a=n[0],s=n[1],u=[""],l=[""];return a&&(u=e.getFieldValues(a,t),o=u.length),s&&(l=e.getFieldValues(s,t),i=l.length),u.forEach(function(n,c){l.forEach(function(h,f){var p=[{field:a,value:n,values:u},{field:s,value:h,values:l}],d=e.getFilter(p),g=t.filter(d),v={type:e.type,colValue:n,rowValue:h,colField:a,rowField:s,colIndex:c,rowIndex:f,cols:o,rows:i,data:g,region:e.getRegion(i,o,c,f)};r.push(v)})}),r},e.prototype.setXAxis=function(t,e,n){n.rowIndex!==n.rows-1?(e[t].title=null,e[t].label=null):n.colIndex!==parseInt((n.cols-1)/2)&&(e[t].title=null)},e.prototype.setYAxis=function(t,e,n){0!==n.colIndex?(e[t].title=null,e[t].label=null):n.rowIndex!==parseInt((n.rows-1)/2)&&(e[t].title=null)},e.prototype.renderTitle=function(t,e){0===e.rowIndex&&this.drawColTitle(t,e),e.colIndex===e.cols-1&&this.drawRowTitle(t,e)},e}(n(590));t.exports=r},function(t,e,n){var r=n(562),i=n(651),o=n(549),a=function(t){function e(n){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);var r=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.call(this,n));return o.assign(r,i),r}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return e.type="path",e.shapeType="line",e},e.prototype.getDrawCfg=function(e){var n=t.prototype.getDrawCfg.call(this,e);return n.isStack=this.hasStack(),n},e.prototype.draw=function(t,e,n,r){var i=this,a=this.splitData(t),s=this.getDrawCfg(t[0]);s.origin=t,o.each(a,function(t,a){if(!o.isEmpty(t)){s.splitedIndex=a,s.points=t;var u=n.drawShape(s.shape,s,e);i.appendShapeInfo(u,r+a)}})},e}(r);r.Path=a,t.exports=a},function(t,e,n){var r=n(551),i=n(549);var o={getDefalutSize:function(){var t=this.get("defaultSize");if(!t){var e=this.get("coord"),n=this.getXScale(),o=n.values,a=this.get("dataArray"),s=void 0;if(n.isLinear&&o.length>1){o.sort();var u=function(t,e){var n=t.length;i.isString(t[0])&&(t=t.map(function(t){return e.translate(t)}));for(var r=t[1]-t[0],o=2;o<n;o++){var a=t[o]-t[o-1];r>a&&(r=a)}return r}(o,n);s=(n.max-n.min)/u,o.length>s&&(s=o.length)}else s=o.length;var l=n.range,c=1/s,h=1;if(this.isInCircle()?h=e.isTransposed&&s>1?r.widthRatio.multiplePie:r.widthRatio.rose:(n.isLinear&&(c*=l[1]-l[0]),h=r.widthRatio.column),c*=h,this.hasAdjust("dodge"))c/=this._getDodgeCount(a);t=c,this.set("defaultSize",t)}return t},_getDodgeCount:function(t){var e=this.get("adjusts"),n=void 0,r=t.length;if(i.each(e,function(t){"dodge"===t.type&&(n=t.dodgeBy)}),n){var o=i.Array.merge(t);r=i.Array.values(o,n).length}return r},getDimWidth:function(t){var e=this.get("coord"),n=e.convertPoint({x:0,y:0}),r=e.convertPoint({x:"x"===t?1:0,y:"x"===t?0:1}),i=0;return n&&r&&(i=Math.sqrt(Math.pow(r.x-n.x,2)+Math.pow(r.y-n.y,2))),i},_getWidth:function(){var t=this.get("coord");return this.isInCircle()&&!t.isTransposed?(t.endAngle-t.startAngle)*t.radius:this.getDimWidth("x")},_toNormalizedSize:function(t){return t/this._getWidth()},_toCoordSize:function(t){return this._getWidth()*t},getNormalizedSize:function(t){var e=this.getAttrValue("size",t);return e=i.isNil(e)?this.getDefalutSize():this._toNormalizedSize(e)},getSize:function(t){var e=this.getAttrValue("size",t);if(i.isNil(e)){var n=this.getDefalutSize();e=this._toCoordSize(n)}return e}};t.exports=o},function(t,e,n){var r=n(549),i=n(551);t.exports={splitData:function(t){if(!t.length)return[];var e=[],n=[],o=this.getYScale().field,a=void 0;return r.each(t,function(t){a=t._origin?t._origin[o]:t[o],i.connectNulls?r.isNil(a)||n.push(t):r.isArray(a)&&r.isNil(a[0])||r.isNil(a)?n.length&&(e.push(n),n=[]):n.push(t)}),n.length&&e.push(n),e}}},function(t,e,n){var r=n(549),i=n(551),o=n(653),a=n(552),s=a.Event,u=a.Group,l=n(795),c=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return r.mix({},e,{type:"continuous-legend",items:null,layout:"vertical",width:156,height:20,titleGap:22,textStyle:{fill:"#333",textAlign:"center",textBaseline:"middle",fontFamily:i.fontFamily},slidable:!0,inRange:{fill:"#4E7CCC"},_range:[0,100],middleAttr:{fill:"#fff",fillOpacity:0},outRangeStyle:{fill:"#D9D9D9"},numberFormatter:null,labelOffset:10})},e.prototype._calStartPoint=function(){var t={x:0,y:this.get("titleGap")-12},e=this.get("titleShape");if(e){var n=e.getBBox();t.y+=n.height}return t},e.prototype._beforeRenderUI=function(){var e=this.get("items");r.isArray(e)&&!r.isEmpty(e)&&(t.prototype._beforeRenderUI.call(this),this.set("firstItem",e[0]),this.set("lastItem",e[e.length-1]))},e.prototype._formatItemValue=function(t){var e=this.get("numberFormatter");e&&(t=e(t));var n=this.get("itemFormatter");return n&&(t=n.call(this,t)),t},e.prototype._renderUI=function(){t.prototype._renderUI.call(this),this.get("slidable")?this._renderSlider():this._renderBackground()},e.prototype._renderSlider=function(){var t=new u,e=new u,n=new u,r=this._calStartPoint(),i=this.addGroup(l,{minHandleElement:t,maxHandleElement:e,backgroundElement:n,middleAttr:this.get("middleAttr"),layout:this.get("layout"),range:this.get("_range"),width:this.get("width"),height:this.get("height")});i.translate(r.x,r.y),this.set("slider",i),this._renderSliderShape().attr("clip",i.get("middleHandleElement")),this._renderTrigger()},e.prototype._addBackground=function(t,e,n){return t.addShape(e,{attrs:r.mix({},n,this.get("outRangeStyle"))}),t.addShape(e,{attrs:n})},e.prototype._renderTrigger=function(){var t=this.get("firstItem"),e=this.get("lastItem"),n=this.get("layout"),i=this.get("textStyle"),o=this.get("inRange"),a=void 0,s=void 0;"color-legend"===this.get("type")?(a={fill:t.attrValue},s={fill:e.attrValue}):(a=r.mix({},o),s=r.mix({},o));var u=r.mix({text:this._formatItemValue(t.value)+""},i),l=r.mix({text:this._formatItemValue(e.value)+""},i);"vertical"===n?(this._addVerticalTrigger("min",a,u),this._addVerticalTrigger("max",s,l)):(this._addHorizontalTrigger("min",a,u),this._addHorizontalTrigger("max",s,l))},e.prototype._addVerticalTrigger=function(t,e,n){var i=this.get("slider").get(t+"HandleElement"),o=this.get("width"),a=i.addShape("polygon",{attrs:r.mix({points:[[o/2+12,0],[o/2+1,0],[o/2+12,"min"===t?12:-12]]},e)}),s=i.addShape("text",{attrs:r.mix(n,{x:o+8,y:"max"===t?-4:4,textAlign:"start",lineHeight:1,textBaseline:"middle"})}),u="vertical"===this.get("layout")?"ns-resize":"ew-resize";a.attr("cursor",u),s.attr("cursor",u),this.set(t+"ButtonElement",a),this.set(t+"TextElement",s)},e.prototype._addHorizontalTrigger=function(t,e,n){var i=this.get("slider").get(t+"HandleElement"),o=i.addShape("polygon",{attrs:r.mix({points:[[0,0],[0,12],["min"===t?-12:12,12]]},e)}),a=i.addShape("text",{attrs:r.mix(n,{x:"min"===t?-16:16,y:6,textAlign:"min"===t?"end":"start",textBaseline:"middle"})}),s="vertical"===this.get("layout")?"ns-resize":"ew-resize";o.attr("cursor",s),a.attr("cursor",s),this.set(t+"ButtonElement",o),this.set(t+"TextElement",a)},e.prototype._bindUI=function(){var t=this;t.get("slidable")&&t.get("slider").on("sliderchange",function(e){var n=e.range,r=1*t.get("firstItem").value,i=1*t.get("lastItem").value,o=r+n[0]/100*(i-r),a=r+n[1]/100*(i-r);t._updateElement(o,a);var u=new s("itemfilter",e,!0,!0);u.range=[o,a],t.emit("itemfilter",u)})},e.prototype._updateElement=function(t,e){var n=this.get("minTextElement"),r=this.get("maxTextElement");if(e>1&&(t=parseInt(t,10),e=parseInt(e,10)),n.attr("text",this._formatItemValue(t)+""),r.attr("text",this._formatItemValue(e)+""),"color-legend"===this.get("type")&&this.get("attr")){var i=this.get("attr"),o=this.get("minButtonElement"),a=this.get("maxButtonElement");o.attr("fill",i.mapping(t).join("")),a.attr("fill",i.mapping(e).join(""))}},e}(o);t.exports=c},function(t,e,n){var r=n(549),i=n(551),o=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){return{title:{fill:"#333",textBaseline:"middle"},itemFormatter:null,useHtml:!1,inPlot:!1,hoverable:!0}},e.prototype._beforeRenderUI=function(){var t=this.addGroup();t.set("viewId",this.get("viewId")),this.set("itemsGroup",t)},e.prototype._renderUI=function(){this._renderTitle()},e.prototype._renderTitle=function(){var t=this.get("title");if(t&&t.text){var e=this.addShape("text",{attrs:r.mix({x:0,y:0,fill:"#333",textBaseline:"middle",fontFamily:i.fontFamily},t)});e.name="legend-title",this.get("appendInfo")&&e.setSilent("appendInfo",this.get("appendInfo")),this.set("titleShape",e)}},e.prototype.getCheckedCount=function(){var t=this.get("itemsGroup").get("children");return r.filter(t,function(t){return t.get("checked")}).length},e.prototype.setItems=function(t){this.set("items",t),this.clearItems(),this._renderUI()},e.prototype.addItem=function(t){this.get("items").push(t),this.clearItems(),this._renderUI()},e.prototype.clearItems=function(){this.get("itemsGroup").clear()},e.prototype.getWidth=function(){return this.getBBox().width},e.prototype.getHeight=function(){return this.getBBox().height},e}(n(552).Group);t.exports=o},function(t,e,n){var r=n(549);t.exports={toTimeStamp:function(t){return r.isString(t)&&(t=t.indexOf("T")>0?new Date(t).getTime():new Date(t.replace(/-/gi,"/")).getTime()),r.isDate(t)&&(t=t.getTime()),t}}},function(t,e,n){var r;!function(i){"use strict";var o={},a=/d{1,4}|M{1,4}|YY(?:YY)?|S{1,3}|Do|ZZ|([HhMsDm])\1?|[aA]|"[^"]*"|'[^']*'/g,s=/\d\d?/,u=/[0-9]*['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+|[\u0600-\u06FF\/]+(\s*?[\u0600-\u06FF]+){1,2}/i,l=/\[([^]*?)\]/gm,c=function(){};function h(t,e){for(var n=[],r=0,i=t.length;r<i;r++)n.push(t[r].substr(0,e));return n}function f(t){return function(e,n,r){var i=r[t].indexOf(n.charAt(0).toUpperCase()+n.substr(1).toLowerCase());~i&&(e.month=i)}}function p(t,e){for(t=String(t),e=e||2;t.length<e;)t="0"+t;return t}var d=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],g=["January","February","March","April","May","June","July","August","September","October","November","December"],v=h(g,3),y=h(d,3);o.i18n={dayNamesShort:y,dayNames:d,monthNamesShort:v,monthNames:g,amPm:["am","pm"],DoFn:function(t){return t+["th","st","nd","rd"][t%10>3?0:(t-t%10!=10)*t%10]}};var m={D:function(t){return t.getDate()},DD:function(t){return p(t.getDate())},Do:function(t,e){return e.DoFn(t.getDate())},d:function(t){return t.getDay()},dd:function(t){return p(t.getDay())},ddd:function(t,e){return e.dayNamesShort[t.getDay()]},dddd:function(t,e){return e.dayNames[t.getDay()]},M:function(t){return t.getMonth()+1},MM:function(t){return p(t.getMonth()+1)},MMM:function(t,e){return e.monthNamesShort[t.getMonth()]},MMMM:function(t,e){return e.monthNames[t.getMonth()]},YY:function(t){return String(t.getFullYear()).substr(2)},YYYY:function(t){return p(t.getFullYear(),4)},h:function(t){return t.getHours()%12||12},hh:function(t){return p(t.getHours()%12||12)},H:function(t){return t.getHours()},HH:function(t){return p(t.getHours())},m:function(t){return t.getMinutes()},mm:function(t){return p(t.getMinutes())},s:function(t){return t.getSeconds()},ss:function(t){return p(t.getSeconds())},S:function(t){return Math.round(t.getMilliseconds()/100)},SS:function(t){return p(Math.round(t.getMilliseconds()/10),2)},SSS:function(t){return p(t.getMilliseconds(),3)},a:function(t,e){return t.getHours()<12?e.amPm[0]:e.amPm[1]},A:function(t,e){return t.getHours()<12?e.amPm[0].toUpperCase():e.amPm[1].toUpperCase()},ZZ:function(t){var e=t.getTimezoneOffset();return(e>0?"-":"+")+p(100*Math.floor(Math.abs(e)/60)+Math.abs(e)%60,4)}},x={D:[s,function(t,e){t.day=e}],Do:[new RegExp(s.source+u.source),function(t,e){t.day=parseInt(e,10)}],M:[s,function(t,e){t.month=e-1}],YY:[s,function(t,e){var n=+(""+(new Date).getFullYear()).substr(0,2);t.year=""+(e>68?n-1:n)+e}],h:[s,function(t,e){t.hour=e}],m:[s,function(t,e){t.minute=e}],s:[s,function(t,e){t.second=e}],YYYY:[/\d{4}/,function(t,e){t.year=e}],S:[/\d/,function(t,e){t.millisecond=100*e}],SS:[/\d{2}/,function(t,e){t.millisecond=10*e}],SSS:[/\d{3}/,function(t,e){t.millisecond=e}],d:[s,c],ddd:[u,c],MMM:[u,f("monthNamesShort")],MMMM:[u,f("monthNames")],a:[u,function(t,e,n){var r=e.toLowerCase();r===n.amPm[0]?t.isPm=!1:r===n.amPm[1]&&(t.isPm=!0)}],ZZ:[/([\+\-]\d\d:?\d\d|Z)/,function(t,e){"Z"===e&&(e="+00:00");var n,r=(e+"").match(/([\+\-]|\d\d)/gi);r&&(n=60*r[1]+parseInt(r[2],10),t.timezoneOffset="+"===r[0]?n:-n)}]};x.dd=x.d,x.dddd=x.ddd,x.DD=x.D,x.mm=x.m,x.hh=x.H=x.HH=x.h,x.MM=x.M,x.ss=x.s,x.A=x.a,o.masks={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",shortTime:"HH:mm",mediumTime:"HH:mm:ss",longTime:"HH:mm:ss.SSS"},o.format=function(t,e,n){var r=n||o.i18n;if("number"==typeof t&&(t=new Date(t)),"[object Date]"!==Object.prototype.toString.call(t)||isNaN(t.getTime()))throw new Error("Invalid Date in fecha.format");var i=[];return(e=(e=(e=o.masks[e]||e||o.masks.default).replace(l,function(t,e){return i.push(e),"??"})).replace(a,function(e){return e in m?m[e](t,r):e.slice(1,e.length-1)})).replace(/\?\?/g,function(){return i.shift()})},o.parse=function(t,e,n){var r=n||o.i18n;if("string"!=typeof e)throw new Error("Invalid format in fecha.parse");if(e=o.masks[e]||e,t.length>1e3)return!1;var i=!0,s={};if(e.replace(a,function(e){if(x[e]){var n=x[e],o=t.search(n[0]);~o?t.replace(n[0],function(e){return n[1](s,e,r),t=t.substr(o+e.length),e}):i=!1}return x[e]?"":e.slice(1,e.length-1)}),!i)return!1;var u,l=new Date;return!0===s.isPm&&null!=s.hour&&12!=+s.hour?s.hour=+s.hour+12:!1===s.isPm&&12==+s.hour&&(s.hour=0),null!=s.timezoneOffset?(s.minute=+(s.minute||0)-+s.timezoneOffset,u=new Date(Date.UTC(s.year||l.getFullYear(),s.month||0,s.day||1,s.hour||0,s.minute||0,s.second||0,s.millisecond||0))):u=new Date(s.year||l.getFullYear(),s.month||0,s.day||1,s.hour||0,s.minute||0,s.second||0,s.millisecond||0),u},void 0!==t&&t.exports?t.exports=o:void 0===(r=function(){return o}.call(e,n,e,t))||(t.exports=r)}()},function(t,e,n){var r=n(549);t.exports=function(t){var e,n,i={},o=[],a=t.maxCount||8,s=(e=t.data,n=[],r.each(e,function(t){r.isArray(t)?n=n.concat(t):n.push(t)}),n),u=s.length,l=function(t,e){var n=void 0;for(n=e;n>0&&t%n!=0;n--);if(1===n)for(n=e;n>0&&(t-1)%n!=0;n--);return n}(u-1,a-1)+1;2===l?l=a:l<a-4&&(l=a-4);var c=parseInt(u/(l-1),10),h=s.map(function(t,e){return e%c==0?s.slice(e,e+c):null}).filter(function(t){return t});o.push(s[0]);for(var f=1;f<h.length&&f*c<u-c;f++)o.push(h[f][0]);var p=s[u-1];return-1===o.indexOf(p)&&o.push(p),i.categories=s,i.ticks=o,i}},function(t,e,n){var r=n(594),i=n(549),o=n(656),a=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return i.mix({},e,{type:"cat",tickCount:null,isCategory:!0})},e.prototype.init=function(){var t=this.values,e=this.tickCount;if(i.each(t,function(e,n){t[n]=e.toString()}),!this.ticks){var n=t;if(e)n=o({maxCount:e,data:t}).ticks;this.ticks=n}},e.prototype.getText=function(e){return-1===this.values.indexOf(e)&&i.isNumber(e)&&(e=this.values[Math.round(e)]),t.prototype.getText.call(this,e)},e.prototype.translate=function(t){var e=this.values.indexOf(t);return-1===e&&i.isNumber(t)?e=t:-1===e&&(e=NaN),e},e.prototype.scale=function(t){var e=this.rangeMin(),n=this.rangeMax();return(i.isString(t)||-1!==this.values.indexOf(t))&&(t=this.translate(t)),e+(this.values.length>1?t/(this.values.length-1):t)*(n-e)},e.prototype.invert=function(t){if(i.isString(t))return t;var e=this.rangeMin(),n=this.rangeMax();t<e&&(t=e),t>n&&(t=n);var r=(t-e)/(n-e),o=Math.round(r*(this.values.length-1))%this.values.length;return o=o||0,this.values[o]},e}(r);t.exports=a},function(t,e){var n=12;function r(t,e){var n=t.length;if(0===n)return NaN;var r=t[0];if(e<t[0])return NaN;if(e>=t[n-1])return t[n-1];for(var i=1;i<t.length&&!(e<t[i]);i++)r=t[i];return r}function i(t,e){var n=t.length;if(0===n)return NaN;var r=void 0;if(e>t[n-1])return NaN;if(e<t[0])return t[0];for(var i=1;i<t.length;i++)if(e<=t[i]){r=t[i];break}return r}var o={snapFactorTo:function(t,e,r){if(isNaN(t))return NaN;var i=1;if(0!==t){t<0&&(i=-1);var a=function(t){var e=1;if(t===1/0||t===-1/0)throw new Error("Not support Infinity!");if(t<1){for(var r=0;t<1;)e/=10,t*=10,r++;e.toString().length>n&&(e=parseFloat(e.toFixed(r)))}else for(;t>10;)e*=10,t/=10;return e}(t*=i);i*=a,t/=a}var s=(t="floor"===r?o.snapFloor(e,t):"ceil"===r?o.snapCeiling(e,t):o.snapTo(e,t))*i;Math.abs(i)<1&&s.toString().length>n&&(s=t/parseInt(1/i)*(i>0?1:-1));return s},snapMultiple:function(t,e,n){return("ceil"===n?Math.ceil(t/e):"floor"===n?Math.floor(t/e):Math.round(t/e))*e},snapTo:function(t,e){var n=r(t,e),o=i(t,e);if(isNaN(n)||isNaN(o)){if(t[0]>=e)return t[0];var a=t[t.length-1];if(a<=e)return a}return Math.abs(e-n)<Math.abs(o-e)?n:o},snapFloor:function(t,e){return r(t,e)},snapCeiling:function(t,e){return i(t,e)}};t.exports=o},function(t,e,n){var r=n(549),i=n(594);i.Linear=n(593),i.Identity=n(825),i.Cat=n(657),i.Time=n(824),i.TimeCat=n(822),i.Log=n(821),i.Pow=n(820);var o=function(t){if(i.hasOwnProperty(t)){var e=r.lowerFirst(t);i[e]=function(e){return new i[t](e)}}};for(var a in i)o(a);var s=["cat","timeCat"];i.isCategory=function(t){return s.indexOf(t)>=0},t.exports=i},function(t,e,n){t.exports={Scale:n(827),Coord:n(819),Axis:n(814),Guide:n(807),Legend:n(799),Tooltip:n(793),Event:n(791)}},function(t,e,n){var r=n(664),i=n(568),o=n(549),a=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getPointRauis=function(t,e){return i.getPointRadius(t,e)},e.prototype.getCirclePoint=function(t,e,n){var r=this.get("coord"),i=r.getCenter(),o=this._isEmitLabels(),a=this.getPointRauis(r,n);r.isTransposed&&a>e&&!o?t+=2*Math.asin(e/(2*a)):a+=e;return{x:i.x+a*Math.cos(t),y:i.y+a*Math.sin(t),angle:t,r:a}},e.prototype.getArcPoint=function(t,e){var n=void 0;return e=e||0,n=o.isArray(t.x)||o.isArray(t.y)?{x:o.isArray(t.x)?t.x[e]:t.x,y:o.isArray(t.y)?t.y[e]:t.y}:t,this.transLabelPoint(n),n},e.prototype.getPointAngle=function(t){var e=this.get("coord");return i.getPointAngle(e,t)},e.prototype.getMiddlePoint=function(t){var e=this.get("coord"),n=t.length,r={x:0,y:0};return o.each(t,function(t){r.x+=t.x,r.y+=t.y}),r.x/=n,r.y/=n,r=e.convert(r)},e.prototype._isToMiddle=function(t){return t.x.length>2},e.prototype.getLabelPoint=function(t,e,n){var r=t[n],i=1,o=void 0;this._isToMiddle(e)?o=this.getMiddlePoint(e.points):(1===t.length&&0===n?n=1:0===n&&(i=-1),o=this.getArcPoint(e,n));var a=this.getDefaultOffset();a*=i;var s=this.getPointAngle(o),u=this.getCirclePoint(s,a,o);return u.text=r,u.angle=s,u.color=e.color,u.rotate=this.getLabelRotate(s,a,e),u},e.prototype._isEmitLabels=function(){return this.get("label").labelEmit},e.prototype.getLabelRotate=function(t){var e=void 0;return e=180*t/Math.PI,e+=90,this._isEmitLabels()&&(e-=90),e&&(e>90?e-=180:e<-90&&(e+=180)),e/180*Math.PI},e.prototype.getLabelAlign=function(t){var e=this.get("coord"),n=void 0;if(this._isEmitLabels())n=t.angle<=Math.PI/2&&t.angle>-Math.PI/2?"left":"right";else if(e.isTransposed){var r=e.getCenter(),i=this.getDefaultOffset();n=Math.abs(t.x-r.x)<1?"center":t.angle>Math.PI||t.angle<=0?i>0?"left":"right":i>0?"right":"left"}else n="center";return n},e}(r);t.exports=a},function(t,e,n){var r=n(549),i=n(552),o=i.DomUtil,a=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){return{zIndex:6,items:null,textStyle:null,formatter:null,htmlTemplate:null,_containerTpl:'<div class="g-labels" style="position:absolute;top:0;left:0;"></div>',_itemTpl:'<div class="g-label" style="position:absolute;">{text}</div>'}},e.prototype._renderUI=function(){this._drawLabels()},e.prototype._drawLabels=function(){var t=this,e=t.get("items");r.each(e,function(e,n){t._addLabel(e,n)})},e.prototype._addLabel=function(t,e){var n=this._getLabelCfg(t,e);return this._createText(n)},e.prototype._getLabelCfg=function(t,e){var n=this.get("textStyle")||{},i=this.get("formatter"),o=this.get("htmlTemplate");if(!r.isObject(t)){var a=t;(t={}).text=a}return r.isFunction(n)&&(n=n(t.text,t,e)),i&&(t.text=i(t.text,t,e)),r.isFunction(o)&&(t.text=o(t.text,t,e)),r.isNil(t.text)&&(t.text=""),t.text=t.text+"",r.mix({},t,n,{x:t.x||0,y:t.y||0})},e.prototype._createText=function(t){var e=this.get("htmlTemplate"),n=this.get("customDiv"),r=void 0;if(!e){var i=t.point;return delete t.point,(r=this.addShape("text",{attrs:t})).setSilent("origin",i),r.name="label",this.get("appendInfo")&&r.setSilent("appendInfo",this.get("appendInfo")),r}if(!n){var a=this.get("_containerTpl"),s=this.get("canvas").get("el").parentNode;n=o.createDom(a),s.style.position="relative",s.appendChild(n),this.set("customDiv",n)}var u=this._createDom(t);n.appendChild(u),this._setCustomPosition(t,u)},e.prototype._setCustomPosition=function(t,e){var n=t.textAlign||"left",r=t.y,i=t.x,a=o.getOuterWidth(e);r-=o.getOuterHeight(e)/2,"center"===n?i-=a/2:"right"===n&&(i-=a),e.style.top=parseInt(r,10)+"px",e.style.left=parseInt(i,10)+"px"},e.prototype._createDom=function(t){var e=this.get("_itemTpl"),n=this.get("htmlTemplate");r.isString(n)&&(t.text=r.substitute(n,{text:t.text}));var i=r.substitute(e,{text:t.text});return o.createDom(i)},e.prototype.getLabels=function(){var t=this.get("customDiv");return t?r.toArray(t.childNodes):this.get("children")},e.prototype.addLabel=function(t){var e=this.get("items"),n=e.length;return e.push(t),this._addLabel(t,n)},e.prototype.changeLabel=function(t,e){if(t){var n=this.get("htmlTemplate"),i=r.indexOf(this.getLabels(),t),o=this._getLabelCfg(e,i);if(n){var a=this._createDom(o);t.innerHTML=a.innerHTML,this._setCustomPosition(o,t)}else if(t._id=e._id,t.attr("text",o.text),t.attr("x")!==o.x||t.attr("y")!==o.y){var s=t.get("attrs").rotate;s?(t.rotateAtStart(-s),t.attr(o),t.rotateAtStart(s)):t.attr(o)}}},e.prototype.clear=function(){var e=this.get("customDiv");e&&(e.innerHTML=""),t.prototype.clear.call(this)},e.prototype.setItems=function(t){this.clear(),this.set("items",t),this._drawLabels()},e.prototype.remove=function(){var e=this.get("customDiv");e&&e.parentNode.removeChild(e),t.prototype.remove.call(this)},e}(i.Group);t.exports=a},function(t,e,n){var r=n(662);r.LabelsRenderer=n(833),t.exports=r},function(t,e,n){var r=n(552).Group,i=n(663),o=n(551),a=n(549),s=["line","point","path"];var u=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){return{label:o.label,labelCfg:null,coord:null,geomType:null,zIndex:6}},e.prototype._renderUI=function(){t.prototype._renderUI.call(this),this.initLabelsCfg(),this.renderLabels()},e.prototype._getLabelValue=function(t){var e=t._origin,n=this.get("labelCfg"),r=n.scales,i=n.cfg&&n.cfg.content,o=void 0;if(i){var s=[];a.each(r,function(t){s.push(e[t.field])}),o=i.apply(null,s)}else{var u=r[0];if(o=e[u.field],a.isArray(o)){var l=[];a.each(o,function(t){l.push(u.getText(t))}),o=l}else o=u.getText(o)}return o},e.prototype.initLabelsCfg=function(){var t=this.getDefaultLabelCfg(),e=this.get("labelCfg");a.deepMix(t,e.cfg),this.set("label",t)},e.prototype.getDefaultLabelCfg=function(){var t=this.get("labelCfg").cfg,e=this.get("geomType");return"polygon"===e||t&&t.offset<0&&-1===a.indexOf(s,e)?a.deepMix({},this.get("label"),o.innerLabels):a.deepMix({},o.label,this.get("label"))},e.prototype.getLabelsItems=function(t){var e=this,n=[],r=e.get("label"),i=e.get("geom"),o=void 0;return a.each(t,function(t){o=t._origin;var s=e._getLabelValue(t);a.isArray(s)||(s=[s]);var u=s.length;a.each(s,function(l,c){var h=e.getLabelPoint(s,t,c);if(h&&!a.isNil(h.text)&&""!==h.text){h=a.mix({},o,h);var f=void 0;f=r&&r.label&&r.label.textAlign?r.label.textAlign:e.getLabelAlign(h,c,u),h.textAlign=f,i&&(h._id=i._getShapeId(o)+"-glabel-"+c+"-"+h.text),h.coord=e.get("coord"),n.push(h)}})}),n},e.prototype.adjustItems=function(t){return t},e.prototype.drawLines=function(t,e){var n=this;n.getDefaultOffset()>0&&a.each(t,function(t){n.lineToLabel(t,e)})},e.prototype.lineToLabel=function(t,e){var n=this.get("coord"),r=t.x-t._offset.x,i=t.y-t._offset.y,o=(r+t.x)/2,s=(i+t.y)/2,u=this.get("lineGroup");u||(u=this.addGroup({elCls:"x-line-group"}),this.set("lineGroup",u));var l=u.addShape("path",{attrs:a.mix({path:["M"+r,i+" Q"+o,s+" "+t.x,t.y].join(","),fill:null,stroke:t.color},e)});l.name="labelLine",l._id=t._id&&t._id.replace("glabel","glabelline"),l.set("coord",n)},e.prototype.getLabelPoint=function(t,e,n){var r=this.get("coord");function i(e,n){var r,i;return a.isArray(e)&&(1===t.length?e.length<=2?e=e[e.length-1]:(r=e,i=0,a.each(r,function(t){i+=t}),e=i/r.length):e=e[n]),e}var o={x:i(e.x,n),y:i(e.y,n),text:t[n]};if(e&&e.nextPoints&&("funnel"===e.shape||"pyramid"===e.shape)){var s=-1/0;e.nextPoints.forEach(function(t){(t=r.convert(t)).x>s&&(s=t.x)}),o.x=(o.x+s)/2}"pyramid"===e.shape&&!e.nextPoints&&e.points&&e.points.forEach(function(t){t=r.convert(t),(a.isArray(t.x)&&-1===e.x.indexOf(t.x)||a.isNumber(t.x)&&e.x!==t.x)&&(o.x=(o.x+t.x)/2)});var u=this.getLabelOffset(o,n,t.length);return this.transLabelPoint(o),o.x+=u.x,o.y+=u.y,o.color=e.color,o._offset=u,o},e.prototype.transLabelPoint=function(t){var e=this.get("coord").applyMatrix(t.x,t.y,1);t.x=e[0],t.y=e[1]},e.prototype.getOffsetVector=function(){var t=this.get("label").offset||0,e=this.get("coord");return e.isTransposed?e.applyMatrix(t,0):e.applyMatrix(0,t)},e.prototype.getDefaultOffset=function(){var t=this.get("coord"),e=this.getOffsetVector();return t.isTransposed?e[0]:e[1]},e.prototype.getLabelOffset=function(t,e,n){var r=this.getDefaultOffset(),i=this.get("coord").isTransposed,o=i?"x":"y",a=i?1:-1,s={x:0,y:0};return s[o]=e>0||1===n?r*a:r*a*-1,s},e.prototype.getLabelAlign=function(t,e,n){var r="center";if(this.get("coord").isTransposed){var i=this.getDefaultOffset();r=i<0?"right":0===i?"center":"left",n>1&&0===e&&("right"===r?r="left":"left"===r&&(r="right"))}return r},e.prototype.showLabels=function(t){var e=this.getLabelsItems(t),n=this.get("label");e=this.adjustItems(e),this.resetLabels(e),n.labelLine&&this.drawLines(e,n.labelLine)},e.prototype.destroy=function(){this.removeLabels(),t.prototype.destroy.call(this)},e}(r);a.assign(u.prototype,i.LabelsRenderer),t.exports=u},function(t,e){var n,r,i='"-apple-system", BlinkMacSystemFont, "Segoe UI", Roboto,"Helvetica Neue", Helvetica, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei",SimSun, "sans-serif"',o={defaultColor:"#1890FF",plotCfg:{padding:[20,20,95,80]},fontFamily:i,defaultLegendPosition:"bottom",colors:["#1890FF","#2FC25B","#FACC14","#223273","#8543E0","#13C2C2","#3436C7","#F04864"],colors_16:["#1890FF","#41D9C7","#2FC25B","#FACC14","#E6965C","#223273","#7564CC","#8543E0","#5C8EE6","#13C2C2","#5CA3E6","#3436C7","#B381E6","#F04864","#D598D9"],colors_24:["#1890FF","#66B5FF","#41D9C7","#2FC25B","#6EDB8F","#9AE65C","#FACC14","#E6965C","#57AD71","#223273","#738AE6","#7564CC","#8543E0","#A877ED","#5C8EE6","#13C2C2","#70E0E0","#5CA3E6","#3436C7","#8082FF","#DD81E6","#F04864","#FA7D92","#D598D9"],colors_pie:["#1890FF","#13C2C2","#2FC25B","#FACC14","#F04864","#8543E0","#3436C7","#223273"],colors_pie_16:["#1890FF","#73C9E6","#13C2C2","#6CD9B3","#2FC25B","#9DD96C","#FACC14","#E6965C","#F04864","#D66BCA","#8543E0","#8E77ED","#3436C7","#737EE6","#223273","#7EA2E6"],shapes:{point:["hollowCircle","hollowSquare","hollowDiamond","hollowBowtie","hollowTriangle","hollowHexagon","cross","tick","plus","hyphen","line"],line:["line","dash","dot"],area:["area"]},sizes:[1,10],opacities:[.1,.9],axis:{top:{position:"top",title:null,label:{offset:14,textStyle:{fill:"#545454",fontSize:12,lineHeight:20,textBaseline:"middle",fontFamily:i},autoRotate:!0},line:{lineWidth:1,stroke:"#BFBFBF"},tickLine:{lineWidth:1,stroke:"#BFBFBF",length:4}},bottom:{position:"bottom",title:null,label:{offset:22,autoRotate:!0,textStyle:{fill:"#545454",fontSize:12,lineHeight:20,textBaseline:"middle",fontFamily:i}},line:{lineWidth:1,stroke:"#BFBFBF"},tickLine:{lineWidth:1,stroke:"#BFBFBF",length:4}},left:{position:"left",title:null,label:{offset:12,autoRotate:!0,textStyle:{fill:"#545454",fontSize:12,lineHeight:20,textBaseline:"middle",fontFamily:i}},line:null,tickLine:null,grid:{zIndex:-1,lineStyle:{stroke:"#E9E9E9",lineWidth:1,lineDash:[3,3]},hideFirstLine:!0}},right:{position:"right",title:null,label:{offset:12,autoRotate:!0,textStyle:{fill:"#545454",fontSize:12,lineHeight:20,textBaseline:"middle",fontFamily:i}},line:null,tickLine:null,grid:{lineStyle:{stroke:"#E9E9E9",lineWidth:1,lineDash:[3,3]},hideFirstLine:!0}},circle:{zIndex:1,title:null,label:{offset:12,textStyle:{fill:"#545454",fontSize:12,lineHeight:20,fontFamily:i}},line:{lineWidth:1,stroke:"#BFBFBF"},tickLine:{lineWidth:1,stroke:"#BFBFBF",length:4},grid:{lineStyle:{stroke:"#E9E9E9",lineWidth:1,lineDash:[3,3]},hideFirstLine:!0}},radius:{zIndex:0,label:{offset:12,textStyle:{fill:"#545454",fontSize:12,textBaseline:"middle",lineHeight:20,fontFamily:i}},line:{lineWidth:1,stroke:"#BFBFBF"},tickLine:{lineWidth:1,stroke:"#BFBFBF",length:4},grid:{lineStyle:{stroke:"#E9E9E9",lineWidth:1,lineDash:[3,3]},type:"circle"}},helix:{grid:null,label:null,title:null,line:{lineWidth:1,stroke:"#BFBFBF"},tickLine:{lineWidth:1,length:4,stroke:"#BFBFBF"}}},label:{offset:20,textStyle:{fill:"#545454",fontSize:12,textBaseline:"middle",fontFamily:i}},treemapLabels:{offset:10,textStyle:{fill:"#fff",fontSize:12,textBaseline:"top",fontStyle:"bold",fontFamily:i}},innerLabels:{textStyle:{fill:"#fff",fontSize:12,textBaseline:"middle",fontFamily:i}},thetaLabels:{labelLine:{lineWidth:1},labelHeight:14,offset:30},legend:{right:{position:"right",layout:"vertical",itemMarginBottom:8,width:16,height:156,title:null,textStyle:{fill:"#8C8C8C",fontSize:12,textAlign:"start",textBaseline:"middle",lineHeight:20,fontFamily:i},unCheckColor:"#bfbfbf"},left:{position:"left",layout:"vertical",itemMarginBottom:8,width:16,height:156,title:null,textStyle:{fill:"#8C8C8C",fontSize:12,textAlign:"start",textBaseline:"middle",lineHeight:20,fontFamily:i},unCheckColor:"#bfbfbf"},top:{position:"top",offset:6,layout:"horizontal",title:null,itemGap:10,width:156,height:16,textStyle:{fill:"#8C8C8C",fontSize:12,textAlign:"start",textBaseline:"middle",lineHeight:20,fontFamily:i},unCheckColor:"#bfbfbf"},bottom:{position:"bottom",offset:58,layout:"horizontal",title:null,itemGap:24,width:156,height:16,textStyle:{fill:"#8C8C8C",fontSize:12,textAlign:"start",textBaseline:"middle",lineHeight:20,fontFamily:i},unCheckColor:"#bfbfbf"},html:(n={},n["g2-legend"]={height:"auto",width:"auto",position:"absolute",overflow:"auto",fontSize:"12px",fontFamily:i,lineHeight:"20px",color:"#8C8C8C"},n["g2-legend-title"]={marginBottom:"4px"},n["g2-legend-list"]={listStyleType:"none",margin:0,padding:0},n["g2-legend-list-item"]={cursor:"pointer",marginBottom:"5px",marginRight:"24px"},n["g2-legend-marker"]={width:"9px",height:"9px",borderRadius:"50%",display:"inline-block",marginRight:"8px",verticalAlign:"middle"},n),gradient:{textStyle:{fill:"#8C8C8C",fontSize:12,textAlign:"center",textBaseline:"middle",lineHeight:20,fontFamily:i},lineStyle:{lineWidth:1,stroke:"#fff"},unCheckColor:"#bfbfbf"},margin:[0,20,24,5],legendMargin:24},tooltip:(r={crosshairs:!1,offset:15},r["g2-tooltip"]={position:"absolute",visibility:"hidden",whiteSpace:"nowrap",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(0, 0, 0, 0.65)",borderRadius:"4px",color:"rgb(255, 255, 255)",fontSize:"12px",fontFamily:i,lineHeight:"20px",padding:"10px 10px 6px 10px"},r["g2-tooltip-title"]={marginBottom:"4px"},r["g2-tooltip-list"]={margin:0,listStyleType:"none",padding:0},r["g2-tooltip-list-item"]={marginBottom:"4px"},r["g2-tooltip-marker"]={width:"7px",height:"7px",borderRadius:"50%",border:"1px solid #fff",display:"inline-block",marginRight:"8px"},r),tooltipMarker:{symbol:function(t,e,n,r,i){var o=i.get("color");r.fillStyle=o,r.lineWidth=1,r.strokeStyle="#fff",r.beginPath(),r.arc(t,e,n,0,2*Math.PI,!1),r.fill(),r.stroke(),r.save(),r.beginPath(),r.fillStyle="#fff",r.strokeStyle=o,r.globalAlpha=.2,r.lineWidth=3,r.arc(t,e,6,0,2*Math.PI,!1),r.stroke(),r.restore()},radius:4},tooltipCrosshairsRect:{type:"rect",style:{fill:"#CCD6EC",opacity:.3}},tooltipCrosshairsLine:{style:{stroke:"rgba(0, 0, 0, 0.25)",lineWidth:1}},shape:{point:{lineWidth:1,fill:"#1890FF",radius:4},hollowPoint:{fill:"#fff",lineWidth:1,stroke:"#1890FF",radius:3},interval:{lineWidth:0,fill:"#1890FF",fillOpacity:.85},hollowInterval:{fill:"#fff",stroke:"#1890FF",fillOpacity:0,lineWidth:2},area:{lineWidth:0,fill:"#1890FF",fillOpacity:.3},polygon:{lineWidth:0,fill:"#1890FF",fillOpacity:1},hollowPolygon:{fill:"#fff",stroke:"#1890FF",fillOpacity:0,lineWidth:2},hollowArea:{fill:"#fff",stroke:"#1890FF",fillOpacity:0,lineWidth:2},line:{stroke:"#1890FF",lineWidth:2,fill:null},edge:{stroke:"#1890FF",lineWidth:1,fill:null},schema:{stroke:"#1890FF",lineWidth:1,fill:null}},guide:{line:{lineStyle:{stroke:"#1890FF",lineDash:[0,2,2],lineWidth:1},text:{position:"end",autoRotate:!0,style:{fill:"#545454",fontSize:12,textAlign:"center",fontFamily:i}}},text:{style:{fill:"#545454",fontSize:12,textBaseline:"middle",textAlign:"start",fontFamily:i}},region:{style:{lineWidth:0,fill:"#000",fillOpacity:.04}},html:{alignX:"middle",alignY:"middle"}},pixelRatio:null};t.exports=o},function(t,e,n){var r=n(573);r.Color=n(846),r.Size=n(845),r.Opacity=n(844),r.Shape=n(843),r.Position=n(842),t.exports=r},function(t,e,n){var r=n(549),i=n(848),o=n(552),a=o.Canvas,s=o.DomUtil,u=n(789),l=n(660),c=n(551);function h(t,e){return r.isEqualWith(t,e,function(t,e){return t===e})}var f=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return r.mix(e,{id:null,forceFit:!1,container:null,wrapperEl:null,canvas:null,width:500,height:500,pixelRatio:null,padding:c.plotCfg.padding,backPlot:null,frontPlot:null,plotBackground:null,background:null,autoPaddingAppend:5,views:[]})},e.prototype.init=function(){this._initCanvas(),this._initPlot(),this._initEvents(),t.prototype.init.call(this);var e=new l.Tooltip({chart:this,options:{}});this.set("tooltipController",e);var n=new l.Legend({chart:this});this.set("legendController",n),this.set("_id","chart"),this.emit("afterinit")},e.prototype._isAutoPadding=function(){var t=this.get("padding");return r.isArray(t)?-1!==t.indexOf("auto"):"auto"===t},e.prototype._getAutoPadding=function(){for(var t,e,n=this.get("padding"),i=this.get("frontPlot").getBBox(),o=this.get("backPlot").getBBox(),a=(t=i,e=o,{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)}),s=[0-a.minY,a.maxX-this.get("width"),a.maxY-this.get("height"),0-a.minX],u=r.toAllPadding(n),l=0;l<u.length;l++)if("auto"===u[l]){var c=Math.max(0,s[l]);u[l]=c+this.get("autoPaddingAppend")}return u},e.prototype._initCanvas=function(){var t=this.get("container"),e=this.get("id");!t&&e&&(t=e,this.set("container",e));var n=this.get("width"),i=this.get("height");if(r.isString(t)){if(!(t=document.getElementById(t)))throw new Error("Please specify the container for the chart!");this.set("container",t)}var o=s.createDom('<div style="position:relative;"></div>');t.appendChild(o),this.set("wrapperEl",o),this.get("forceFit")&&(n=s.getWidth(t,n),this.set("width",n));var u=new a({containerDOM:o,width:n,height:i,pixelRatio:this.get("pixelRatio")});this.set("canvas",u)},e.prototype._initPlot=function(){this._initPlotBack();var t=this.get("canvas"),e=t.addGroup({zIndex:1}),n=t.addGroup({zIndex:2}),r=t.addGroup({zIndex:3});this.set("backPlot",e),this.set("middlePlot",n),this.set("frontPlot",r)},e.prototype._initPlotBack=function(){var t=this.get("canvas").addGroup(u,{padding:this.get("padding"),plotBackground:r.mix({},c.plotBackground,this.get("plotBackground")),background:r.mix({},c.background,this.get("background"))});this.set("plot",t),this.set("plotRange",t.get("plotRange"))},e.prototype._initEvents=function(){this.get("forceFit")&&window.addEventListener("resize",r.wrapBehavior(this,"_initForceFitEvent"))},e.prototype._initForceFitEvent=function(){var t=setTimeout(r.wrapBehavior(this,"forceFit"),200);clearTimeout(this.get("resizeTimer")),this.set("resizeTimer",t)},e.prototype._renderLegends=function(){var t=this.get("options").legends;if(r.isNil(t)||!1!==t){var e=this.get("legendController");if(e.options=t||{},e.plotRange=this.get("plotRange"),t&&t.custom)e.addCustomLegend();else{var n=this.getAllGeoms(),i=[];r.each(n,function(t){var n=t.get("view"),o=t.getAttrsForLegend();r.each(o,function(o){var a=o.type,s=o.getScale(a);if(s.field&&"identity"!==s.type&&!function(t,e){var n=!1;return r.each(t,function(t){var r=[].concat(t.values),i=[].concat(e.values);t.type!==e.type||t.field!==e.field||r.sort().toString()!==i.sort().toString()||(n=!0)}),n}(i,s)){i.push(s);var u=n.getFilteredValues(s.field);e.addLegend(s,o,t,u)}})})}e.alignLegends()}},e.prototype._renderTooltips=function(){var t=this.get("options");if(r.isNil(t.tooltip)||!1!==t.tooltip){var e=this.get("tooltipController");e.options=t.tooltip||{},e.renderTooltip()}},e.prototype.getAllGeoms=function(){var t=[];t=t.concat(this.get("geoms"));var e=this.get("views");return r.each(e,function(e){t=t.concat(e.get("geoms"))}),t},e.prototype.forceFit=function(){if(this&&!this.destroyed){var t=this.get("container"),e=this.get("width"),n=s.getWidth(t,e);if(0!==n&&n!==e){var r=this.get("height");this.changeSize(n,r)}return this}},e.prototype.resetPlot=function(){var t=this.get("plot"),e=this.get("padding");h(e,t.get("padding"))||(t.set("padding",e),t.repaint())},e.prototype.changeSize=function(t,e){this.get("canvas").changeSize(t,e);var n=this.get("plot");return this.set("width",t),this.set("height",e),n.repaint(),this.set("keepPadding",!0),this.repaint(),this.set("keepPadding",!1),this.emit("afterchangesize"),this},e.prototype.changeWidth=function(t){return this.changeSize(t,this.get("height"))},e.prototype.changeHeight=function(t){return this.changeSize(this.get("width"),t)},e.prototype.view=function(t){(t=t||{}).parent=this,t.backPlot=this.get("backPlot"),t.middlePlot=this.get("middlePlot"),t.frontPlot=this.get("frontPlot"),t.canvas=this.get("canvas"),r.isNil(t.animate)&&(t.animate=this.get("animate")),t.options=r.mix({},this._getSharedOptions(),t.options);var e=new i(t);return e.set("_id","view"+this.get("views").length),this.get("views").push(e),this.emit("addview",{view:e}),e},e.prototype.removeView=function(t){var e=this.get("views");r.Array.remove(e,t),t.destroy()},e.prototype._getSharedOptions=function(){var t=this.get("options"),e={};return r.each(["scales","coord","axes"],function(n){e[n]=r.cloneDeep(t[n])}),e},e.prototype.getViewRegion=function(){var t=this.get("plotRange");return{start:t.bl,end:t.tr}},e.prototype.legend=function(t,e){var n=this.get("options");n.legends||(n.legends={});var i={};return!1===t?n.legends=!1:r.isObject(t)?i=t:r.isString(t)?i[t]=e:i=e,r.mix(n.legends,i),this},e.prototype.tooltip=function(t,e){var n=this.get("options");return n.tooltip||(n.tooltip={}),!1===t?n.tooltip=!1:r.isObject(t)?r.mix(n.tooltip,t):r.mix(n.tooltip,e),this},e.prototype.clear=function(){this.emit("beforeclear");for(var e=this.get("views");e.length>0;){e.shift().destroy()}t.prototype.clear.call(this);var n=this.get("canvas");return this.resetPlot(),n.draw(),this.emit("afterclear"),this},e.prototype.clearInner=function(){var e=this.get("views");r.each(e,function(t){t.clearInner()});var n=this.get("tooltipController");if(n&&n.clear(),!this.get("keepLegend")){var i=this.get("legendController");i&&i.clear()}t.prototype.clearInner.call(this)},e.prototype.drawComponents=function(){t.prototype.drawComponents.call(this),this.get("keepLegend")||this._renderLegends()},e.prototype.render=function(){if(!this.get("keepPadding")&&this._isAutoPadding()){this.beforeRender(),this.drawComponents();var e=this._getAutoPadding(),n=this.get("plot");h(n.get("padding"),e)||(n.set("padding",e),n.repaint())}t.prototype.render.call(this),this._renderTooltips()},e.prototype.repaint=function(){this.get("keepPadding")||this.resetPlot(),t.prototype.repaint.call(this)},e.prototype.changeVisible=function(t){var e=this.get("wrapperEl"),n=t?"":"none";e.style.display=n},e.prototype.toDataURL=function(){return this.get("canvas").get("el").toDataURL("image/png")},e.prototype.downloadImage=function(t){var e=this.toDataURL(),n=document.createElement("a");n.addEventListener("click",function(){n.download=(t||"chart")+".png",n.href=e.replace("image/png","image/octet-stream")});var r=document.createEvent("MouseEvents");return r.initEvent("click",!1,!1),n.dispatchEvent(r),e},e.prototype.showTooltip=function(t){var e=this.getViewsByPoint(t);e.length&&this.get("tooltipController").showTooltip(t,e);return this},e.prototype.hideTooltip=function(){return this.get("tooltipController").hideTooltip(),this},e.prototype.getTooltipItems=function(t){var e=this.getViewsByPoint(t),n=[];return r.each(e,function(e){var i=e.get("geoms");r.each(i,function(e){var i=e.get("dataArray"),o=[];r.each(i,function(n){var r=e.findPoint(t,n);if(r){var i=e.getTipItems(r);o=o.concat(i)}}),n=n.concat(o)})}),n},e.prototype.destroy=function(){this.emit("beforedestroy"),clearTimeout(this.get("resizeTimer"));var e=this.get("canvas"),n=this.get("wrapperEl");n.parentNode.removeChild(n),t.prototype.destroy.call(this),e.destroy(),window.removeEventListener("resize",r.getWrapBehavior(this,"_initForceFitEvent")),this.emit("afterdestroy")},e}(i);t.exports=f},,function(t,e){t.exports=function(t,e,n,r){var i=-1,o=null==t?0:t.length;for(r&&o&&(n=t[++i]);++i<o;)n=e(n,t[i],i,t);return n}},function(t,e,n){var r=n(577);t.exports=function(t,e,n){for(var i=-1,o=t.length;++i<o;){var a=t[i],s=e(a);if(null!=s&&(void 0===u?s==s&&!r(s):n(s,u)))var u=s,l=a}return l}},function(t,e,n){var r=n(156),i=n(577),o=NaN,a=/^\s+|\s+$/g,s=/^[-+]0x[0-9a-f]+$/i,u=/^0b[01]+$/i,l=/^0o[0-7]+$/i,c=parseInt;t.exports=function(t){if("number"==typeof t)return t;if(i(t))return o;if(r(t)){var e="function"==typeof t.valueOf?t.valueOf():t;t=r(e)?e+"":e}if("string"!=typeof t)return 0===t?t:+t;t=t.replace(a,"");var n=u.test(t);return n||l.test(t)?c(t.slice(2),n?2:8):s.test(t)?o:+t}},function(t,e,n){var r=n(608);t.exports=function(t){return null!=t&&t.length?r(t,1):[]}},,function(t,e,n){var r=n(549),i=n(849),o={appear:{duration:450,easing:"easeQuadOut"},update:{duration:450,easing:"easeQuadInOut"},enter:{duration:400,easing:"easeQuadInOut",delay:100},leave:{duration:350,easing:"easeQuadIn"}},a={line:{appear:function(){return i.appear.clipIn},enter:function(){return i.enter.clipIn},leave:function(){return i.leave.lineWidthOut}},path:{appear:function(){return i.appear.clipIn},enter:function(){return i.enter.clipIn},leave:function(){return i.leave.lineWidthOut}},area:{appear:function(){return i.appear.clipIn},enter:function(){return i.enter.fadeIn},leave:function(){return i.leave.fadeOut},cfg:{appear:{duration:500,easing:"easeQuadOut"},update:{duration:450,easing:"easeQuadInOut"},enter:{duration:600,delay:150,easing:"easeQuadInOut"},leave:{easing:"easeQuadOut",duration:350}}},polygon:{appear:function(){return i.appear.zoomIn},enter:function(){return i.enter.zoomIn},leave:function(){return i.leave.zoomOut}},edge:{appear:function(){return i.appear.pathIn},enter:function(){return i.enter.pathIn},leave:function(){return i.leave.pathOut}},interval:{appear:function(t){var e=void 0;return t.isPolar?(e=i.appear.zoomIn,(t.isTransposed||"theta"===t.type)&&(e=i.appear.fanIn)):e=t.isRect?t.isTransposed?i.appear.scaleInX:i.appear.scaleInY:i.appear.zoomIn,e},enter:function(t){return t.isRect||t.isTransposed||"theta"===t.type?i.enter.fadeIn:i.enter.zoomIn},leave:function(){return i.leave.fadeOut},update:function(t){if("theta"===t.type)return i.update.fanIn}},point:{appear:function(){return i.appear.zoomIn},enter:function(){return i.enter.zoomIn},leave:function(){return i.leave.zoomOut}},schema:{appear:function(){return i.appear.clipIn},enter:function(){return i.enter.clipIn},leave:function(){return i.leave.lineWidthOut}},contour:null,heatmap:null,label:{appear:function(){return i.appear.fadeIn},enter:function(){return i.enter.fadeIn},leave:function(){return i.leave.fadeOut},cfg:{appear:{duration:900}}},"axis-label":{enter:function(){return i.appear.fadeIn},leave:function(){return i.leave.fadeOut},update:function(t){if(t.isPolar)return i.appear.fadeIn}},"axis-ticks":{enter:function(){return i.appear.fadeIn},leave:function(){return i.leave.fadeOut},update:function(t){if(t.isPolar)return i.appear.fadeIn}},"axis-grid":{enter:function(){return i.appear.fadeIn},leave:function(){return i.leave.fadeOut},update:function(t){if(t.isPolar)return i.appear.fadeIn}},"axis-grid-rect":{enter:function(){return i.appear.fadeIn},leave:function(){return i.leave.fadeOut},update:function(){return i.leave.fadeIn}},labelLine:{appear:function(){return i.appear.pathIn},enter:function(){return i.enter.pathIn},leave:function(){return i.leave.pathOut}}};a.Action=i,a.defaultCfg=o,a.getAnimation=function(t,e,n){var i=this[t];if(i){var o=i[n];if(r.isFunction(o))return o(e)}return!1},a.getAnimateCfg=function(t,e){var n=o[e];return this[t]&&this[t].cfg&&this[t].cfg[e]?r.deepMix({},n,this[t].cfg[e]):n},a.registerAnimation=function(t,e,n){this.Action[t]||(this.Action[t]={}),this.Action[t][e]=n},t.exports=a},function(t,e,n){var r=n(553),i=n(556),o=n(557),a=function t(e){t.superclass.constructor.call(this,e)};a.Symbols={circle:function(t,e,n,r){r.arc(t,e,n,0,2*Math.PI,!1)},square:function(t,e,n,r){r.moveTo(t-n,e-n),r.lineTo(t+n,e-n),r.lineTo(t+n,e+n),r.lineTo(t-n,e+n),r.closePath()},diamond:function(t,e,n,r){r.moveTo(t-n,e),r.lineTo(t,e-n),r.lineTo(t+n,e),r.lineTo(t,e+n),r.closePath()},triangle:function(t,e,n,r){var i=n*Math.sin(1/3*Math.PI);r.moveTo(t-n,e+i),r.lineTo(t,e-i),r.lineTo(t+n,e+i),r.closePath()},"triangle-down":function(t,e,n,r){var i=n*Math.sin(1/3*Math.PI);r.moveTo(t-n,e-i),r.lineTo(t+n,e-i),r.lineTo(t,e+i),r.closePath()}},a.ATTRS={path:null,lineWidth:1},r.extend(a,i),r.augment(a,{type:"marker",canFill:!0,canStroke:!0,getDefaultAttrs:function(){return{x:0,y:0,lineWidth:1}},calculateBox:function(){var t=this.__attrs,e=t.x,n=t.y,r=t.radius,i=this.getHitLineWidth()/2+r;return{minX:e-i,minY:n-i,maxX:e+i,maxY:n+i}},isPointInPath:function(t,e){var n=this.__attrs,r=n.x,i=n.y,a=n.radius,s=this.getHitLineWidth();return o.circle(r,i,a+s/2,t,e)},createPath:function(t){var e=this.__attrs,n=e.x,i=e.y,o=e.radius,s=e.symbol||"circle",u=void 0;u=r.isFunction(s)?s:a.Symbols[s],t.beginPath(),u(n,i,o,t,this)}}),t.exports=a},function(t,e,n){var r=n(553),i=n(556),o=n(557),a=n(574),s=n(621),u=function t(e){t.superclass.constructor.call(this,e)};u.ATTRS={p1:null,p2:null,p3:null,lineWidth:1,startArrow:!1,endArrow:!1},r.extend(u,i),r.augment(u,{canStroke:!0,type:"quadratic",getDefaultAttrs:function(){return{lineWidth:1,startArrow:!1,endArrow:!1}},calculateBox:function(){var t=this.__attrs,e=t.p1,n=t.p2,i=t.p3,o=this.getHitLineWidth(),a=void 0,u=void 0;if(r.isNil(e)||r.isNil(n)||r.isNil(i))return null;var l=o/2,c=s.extrema(e[0],n[0],i[0]);for(a=0,u=c.length;a<u;a++)c[a]=s.at(e[0],n[0],i[0],c[a]);c.push(e[0],i[0]);var h=s.extrema(e[1],n[1],i[1]);for(a=0,u=h.length;a<u;a++)h[a]=s.at(e[1],n[1],i[1],h[a]);return h.push(e[1],i[1]),{minX:Math.min.apply(Math,c)-l,maxX:Math.max.apply(Math,c)+l,minY:Math.min.apply(Math,h)-l,maxY:Math.max.apply(Math,h)+l}},isPointInPath:function(t,e){var n=this.__attrs,r=n.p1,i=n.p2,a=n.p3,s=this.getHitLineWidth();return o.quadraticline(r[0],r[1],i[0],i[1],a[0],a[1],s,t,e)},createPath:function(t){var e=this.__attrs,n=e.p1,i=e.p2,o=e.p3;r.isNil(n)||r.isNil(i)||r.isNil(o)||((t=t||this.get("context")).beginPath(),a.addStartArrow(t,e,i[0],i[1],n[0],n[1]),t.moveTo(n[0],n[1]),t.quadraticCurveTo(i[0],i[1],o[0],o[1]),a.addEndArrow(t,e,i[0],i[1],o[0],o[1]))},getPoint:function(t){var e=this.__attrs;return{x:s.at(e.p1[0],e.p2[0],e.p3[0],t),y:s.at(e.p1[1],e.p2[1],e.p3[1],t)}}}),t.exports=u},function(t,e,n){var r=n(553),i=n(556),o=n(557),a=n(574),s=n(597),u=function t(e){t.superclass.constructor.call(this,e)};u.ATTRS={p1:null,p2:null,p3:null,p4:null,lineWidth:1,startArrow:!1,endArrow:!1},r.extend(u,i),r.augment(u,{canStroke:!0,type:"cubic",getDefaultAttrs:function(){return{lineWidth:1,startArrow:!1,endArrow:!1}},calculateBox:function(){var t=this.__attrs,e=t.p1,n=t.p2,i=t.p3,o=t.p4,a=this.getHitLineWidth(),u=void 0,l=void 0;if(r.isNil(e)||r.isNil(n)||r.isNil(i)||r.isNil(o))return null;var c=a/2,h=s.extrema(e[0],n[0],i[0],o[0]);for(u=0,l=h.length;u<l;u++)h[u]=s.at(e[0],n[0],i[0],o[0],h[u]);var f=s.extrema(e[1],n[1],i[1],o[1]);for(u=0,l=f.length;u<l;u++)f[u]=s.at(e[1],n[1],i[1],o[1],f[u]);return h.push(e[0],o[0]),f.push(e[1],o[1]),{minX:Math.min.apply(Math,h)-c,maxX:Math.max.apply(Math,h)+c,minY:Math.min.apply(Math,f)-c,maxY:Math.max.apply(Math,f)+c}},isPointInPath:function(t,e){var n=this.__attrs,r=n.p1,i=n.p2,a=n.p3,s=n.p4,u=this.getHitLineWidth();return o.cubicline(r[0],r[1],i[0],i[1],a[0],a[1],s[0],s[1],u,t,e)},createPath:function(t){var e=this.__attrs,n=e.p1,i=e.p2,o=e.p3,s=e.p4;t=t||self.get("context"),r.isNil(n)||r.isNil(i)||r.isNil(o)||r.isNil(s)||(t.beginPath(),a.addStartArrow(t,e,i[0],i[1],n[0],n[1]),t.moveTo(n[0],n[1]),t.bezierCurveTo(i[0],i[1],o[0],o[1],s[0],s[1]),a.addEndArrow(t,e,o[0],o[1],s[0],s[1]))},getPoint:function(t){var e=this.__attrs;return{x:s.at(e.p4[0],e.p3[0],e.p2[0],e.p1[0],t),y:s.at(e.p4[1],e.p3[1],e.p2[1],e.p1[1],t)}}}),t.exports=u},function(t,e,n){var r=n(553),i=n(556),o=n(557),a=n(620),s=n(558).vec2,u=function t(e){t.superclass.constructor.call(this,e)};u.ATTRS={x:0,y:0,rs:0,re:0,startAngle:0,endAngle:0,clockwise:!1,lineWidth:1},r.extend(u,i),r.augment(u,{canFill:!0,canStroke:!0,type:"fan",getDefaultAttrs:function(){return{clockwise:!1,lineWidth:1,rs:0,re:0}},calculateBox:function(){var t=this.__attrs,e=t.x,n=t.y,r=t.rs,i=t.re,o=t.startAngle,s=t.endAngle,u=t.clockwise,l=this.getHitLineWidth(),c=a.box(e,n,r,o,s,u),h=a.box(e,n,i,o,s,u),f=l/2;return{minX:Math.min(c.minX,h.minX)-f,minY:Math.min(c.minY,h.minY)-f,maxX:Math.max(c.maxX,h.maxX)+f,maxY:Math.max(c.maxY,h.maxY)+f}},isPointInPath:function(t,e){var n=this.hasFill(),r=this.hasStroke();return n&&r?this.__isPointInFill(t,e)||this.__isPointInStroke(t,e):n?this.__isPointInFill(t,e):!!r&&this.__isPointInStroke(t,e)},__isPointInFill:function(t,e){var n=this.__attrs,i=n.x,o=n.y,u=n.rs,l=n.re,c=n.startAngle,h=n.endAngle,f=n.clockwise,p=[t-i,e-o],d=s.angleTo([1,0],p),g=a.nearAngle(d,c,h,f);if(r.isNumberEqual(d,g)){var v=s.squaredLength(p);if(u*u<=v&&v<=l*l)return!0}return!1},__isPointInStroke:function(t,e){var n=this.__attrs,r=n.x,i=n.y,a=n.rs,s=n.re,u=n.startAngle,l=n.endAngle,c=n.clockwise,h=this.getHitLineWidth(),f={x:Math.cos(u)*a+r,y:Math.sin(u)*a+i},p={x:Math.cos(u)*s+r,y:Math.sin(u)*s+i},d={x:Math.cos(l)*a+r,y:Math.sin(l)*a+i},g={x:Math.cos(l)*s+r,y:Math.sin(l)*s+i};return!!o.line(f.x,f.y,p.x,p.y,h,t,e)||(!!o.line(d.x,d.y,g.x,g.y,h,t,e)||(!!o.arcline(r,i,a,u,l,c,h,t,e)||!!o.arcline(r,i,s,u,l,c,h,t,e)))},createPath:function(t){var e=this.__attrs,n=e.x,r=e.y,i=e.rs,o=e.re,a=e.startAngle,s=e.endAngle,u=e.clockwise,l={x:Math.cos(a)*i+n,y:Math.sin(a)*i+r},c={x:Math.cos(a)*o+n,y:Math.sin(a)*o+r},h={x:Math.cos(s)*i+n,y:Math.sin(s)*i+r};(t=t||self.get("context")).beginPath(),t.moveTo(l.x,l.y),t.lineTo(c.x,c.y),t.arc(n,r,o,a,s,u),t.lineTo(h.x,h.y),t.arc(n,r,i,s,a,!u),t.closePath()}}),t.exports=u},function(t,e,n){var r=n(553),i=n(556),o=n(557),a=n(620),s=n(574);function u(t,e,n){return t+e*Math.cos(n)}function l(t,e,n){return t+e*Math.sin(n)}var c=function t(e){t.superclass.constructor.call(this,e)};c.ATTRS={x:0,y:0,r:0,startAngle:0,endAngle:0,clockwise:!1,lineWidth:1,startArrow:!1,endArrow:!1},r.extend(c,i),r.augment(c,{canStroke:!0,type:"arc",getDefaultAttrs:function(){return{x:0,y:0,r:0,startAngle:0,endAngle:0,clockwise:!1,lineWidth:1,startArrow:!1,endArrow:!1}},calculateBox:function(){var t=this.__attrs,e=t.x,n=t.y,r=t.r,i=t.startAngle,o=t.endAngle,s=t.clockwise,u=this.getHitLineWidth()/2,l=a.box(e,n,r,i,o,s);return l.minX-=u,l.minY-=u,l.maxX+=u,l.maxY+=u,l},isPointInPath:function(t,e){var n=this.__attrs,r=n.x,i=n.y,a=n.r,s=n.startAngle,u=n.endAngle,l=n.clockwise,c=this.getHitLineWidth();return!!this.hasStroke()&&o.arcline(r,i,a,s,u,l,c,t,e)},createPath:function(t){var e=this.__attrs,n=e.x,r=e.y,i=e.r,o=e.startAngle,a=e.endAngle,c=e.clockwise,h=void 0,f=void 0,p=void 0,d=void 0,g=void 0;(t=t||self.get("context")).beginPath(),e.startArrow&&(h=Math.PI/180,c&&(h*=-1),f=u(n,i,o+h),p=l(r,i,o+h),d=u(n,i,o),g=l(r,i,o),s.addStartArrow(t,e,f,p,d,g)),t.arc(n,r,i,o,a,c),e.endArrow&&(h=Math.PI/180,c&&(h*=-1),f=u(n,i,a+h),p=l(r,i,a+h),d=u(n,i,a),g=l(r,i,a),s.addEndArrow(t,e,d,g,f,p))}}),t.exports=c},function(t,e,n){var r=n(553),i=n(556),o=n(557),a=n(574),s=n(622),u=function t(e){t.superclass.constructor.call(this,e)};u.ATTRS={points:null,lineWidth:1,startArrow:!1,endArrow:!1,tCache:null},r.extend(u,i),r.augment(u,{canStroke:!0,type:"polyline",tCache:null,getDefaultAttrs:function(){return{lineWidth:1,startArrow:!1,endArrow:!1}},calculateBox:function(){var t=this.__attrs,e=this.getHitLineWidth(),n=t.points;if(!n||0===n.length)return null;var i=1/0,o=1/0,a=-1/0,s=-1/0;r.each(n,function(t){var e=t[0],n=t[1];e<i&&(i=e),e>a&&(a=e),n<o&&(o=n),n>s&&(s=n)});var u=e/2;return{minX:i-u,minY:o-u,maxX:a+u,maxY:s+u}},__setTcache:function(){var t=this.__attrs.points,e=0,n=0,i=[],o=void 0,a=void 0;t&&0!==t.length&&(r.each(t,function(n,r){t[r+1]&&(e+=s.len(n[0],n[1],t[r+1][0],t[r+1][1]))}),e<=0||(r.each(t,function(r,u){t[u+1]&&((o=[])[0]=n/e,a=s.len(r[0],r[1],t[u+1][0],t[u+1][1]),n+=a,o[1]=n/e,i.push(o))}),this.tCache=i))},isPointInPath:function(t,e){var n=this.__attrs;if(this.hasStroke()){var r=n.points;if(r.length<2)return!1;var i=n.lineWidth;return o.polyline(r,i,t,e)}return!1},createPath:function(t){var e,n=this.__attrs,r=n.points,i=void 0;if(!(r.length<2)){for((t=t||this.get("context")).beginPath(),a.addStartArrow(t,n,r[1][0],r[1][1],r[0][0],r[0][1]),t.moveTo(r[0][0],r[0][1]),i=1,e=r.length-1;i<e;i++)t.lineTo(r[i][0],r[i][1]);t.lineTo(r[e][0],r[e][1]),a.addEndArrow(t,n,r[e-1][0],r[e-1][1],r[e][0],r[e][1])}},getPoint:function(t){var e=this.__attrs.points,n=this.tCache,i=void 0,o=void 0;return n||(this.__setTcache(),n=this.tCache),r.each(n,function(e,n){t>=e[0]&&t<=e[1]&&(i=(t-e[0])/(e[1]-e[0]),o=n)}),{x:s.at(e[o][0],e[o+1][0],i),y:s.at(e[o][1],e[o+1][1],i)}}}),t.exports=u},function(t,e,n){var r=n(553),i=n(556),o=n(557),a=function t(e){t.superclass.constructor.call(this,e)};a.ATTRS={points:null,lineWidth:1},r.extend(a,i),r.augment(a,{canFill:!0,canStroke:!0,type:"polygon",getDefaultAttrs:function(){return{lineWidth:1}},calculateBox:function(){var t=this.__attrs.points,e=this.getHitLineWidth();if(!t||0===t.length)return null;var n=1/0,i=1/0,o=-1/0,a=-1/0;r.each(t,function(t){var e=t[0],r=t[1];e<n&&(n=e),e>o&&(o=e),r<i&&(i=r),r>a&&(a=r)});var s=e/2;return{minX:n-s,minY:i-s,maxX:o+s,maxY:a+s}},isPointInPath:function(t,e){var n=this.hasFill(),r=this.hasStroke();return n&&r?this.__isPointInFill(t,e)||this.__isPointInStroke(t,e):n?this.__isPointInFill(t,e):!!r&&this.__isPointInStroke(t,e)},__isPointInFill:function(t,e){var n=this.get("context");return this.createPath(),n.isPointInPath(t,e)},__isPointInStroke:function(t,e){var n=this.__attrs.points;if(n.length<2)return!1;var r=this.getHitLineWidth(),i=n.slice(0);return n.length>=3&&i.push(n[0]),o.polyline(i,r,t,e)},createPath:function(t){var e=this.__attrs.points;e.length<2||((t=t||this.get("context")).beginPath(),r.each(e,function(e,n){0===n?t.moveTo(e[0],e[1]):t.lineTo(e[0],e[1])}),t.closePath())}}),t.exports=a},function(t,e,n){var r=n(553),i=n(556),o=n(557),a=function t(e){t.superclass.constructor.call(this,e)};a.ATTRS={x:0,y:0,img:void 0,width:0,height:0,sx:null,sy:null,swidth:null,sheight:null},r.extend(a,i),r.augment(a,{type:"image",__afterSetAttrImg:function(t){this.__setAttrImg(t)},__afterSetAttrAll:function(t){t.img&&this.__setAttrImg(t.img)},isHitBox:function(){return!1},calculateBox:function(){var t=this.__attrs,e=t.x,n=t.y;return{minX:e,minY:n,maxX:e+t.width,maxY:n+t.height}},isPointInPath:function(t,e){var n=this.__attrs;if(this.get("toDraw")||!n.img)return!1;var r=n.x,i=n.y,a=n.width,s=n.height;return o.rect(r,i,a,s,t,e)},__setLoading:function(t){var e=this.get("canvas");return!1===t&&!0===this.get("toDraw")&&(this.__cfg.loading=!1,e.draw()),t},__setAttrImg:function(t){var e=this,n=e.__attrs;if(!r.isString(t))return t instanceof Image?(n.width||e.attr("width",t.width),n.height||e.attr("height",t.height),t):t instanceof HTMLElement&&r.isString(t.nodeName)&&"CANVAS"===t.nodeName.toUpperCase()?(n.width||e.attr("width",Number(t.getAttribute("width"))),n.height||e.attr("height",Number(t.getAttribute("height"))),t):t instanceof ImageData?(n.width||e.attr("width",t.width),n.height||e.attr("height",t.height),t):null;var i=new Image;i.onload=function(){if(e.get("destroyed"))return!1;e.attr("imgSrc",t),e.attr("img",i);var n=e.get("callback");n&&n.call(e),e.set("loading",!1)},i.src=t,e.set("loading",!0)},drawInner:function(t){this.get("loading")?this.set("toDraw",!0):this.__drawImage(t)},__drawImage:function(t){var e=this.__attrs,n=e.x,i=e.y,o=e.img,a=e.width,s=e.height,u=e.sx,l=e.sy,c=e.swidth,h=e.sheight;if(this.set("toDraw",!1),o instanceof Image||o instanceof HTMLElement&&r.isString(o.nodeName)&&"CANVAS"===o.nodeName.toUpperCase()){if(r.isNil(u)||r.isNil(l)||r.isNil(c)||r.isNil(h))return void t.drawImage(o,n,i,a,s);if(!(r.isNil(u)||r.isNil(l)||r.isNil(c)||r.isNil(h)))return void t.drawImage(o,u,l,c,h,n,i,a,s)}else if(o instanceof ImageData)return void t.putImageData(o,n,i,u||0,l||0,c||a,h||s)}}),t.exports=a},function(t,e,n){var r=n(553),i=n(556),o=n(557),a=n(574),s=n(622),u=function t(e){t.superclass.constructor.call(this,e)};u.ATTRS={x1:0,y1:0,x2:0,y2:0,lineWidth:1,startArrow:!1,endArrow:!1},r.extend(u,i),r.augment(u,{canStroke:!0,type:"line",getDefaultAttrs:function(){return{lineWidth:1,startArrow:!1,endArrow:!1}},calculateBox:function(){var t=this.__attrs,e=t.x1,n=t.y1,r=t.x2,i=t.y2,o=this.getHitLineWidth();return s.box(e,n,r,i,o)},isPointInPath:function(t,e){var n=this.__attrs,r=n.x1,i=n.y1,a=n.x2,s=n.y2,u=this.getHitLineWidth();return!!this.hasStroke()&&o.line(r,i,a,s,u,t,e)},createPath:function(t){var e=this.__attrs,n=e.x1,r=e.y1,i=e.x2,o=e.y2;(t=t||self.get("context")).beginPath(),a.addStartArrow(t,e,n,r,i,o),t.moveTo(n,r),t.lineTo(i,o),a.addEndArrow(t,e,i,o,n,r)},getPoint:function(t){var e=this.__attrs;return{x:s.at(e.x1,e.x2,t),y:s.at(e.y1,e.y2,t)}}}),t.exports=u},function(t,e,n){var r=n(553),i=n(556),o=n(557),a=function t(e){t.superclass.constructor.call(this,e)};a.ATTRS={x:0,y:0,text:null,fontSize:12,fontFamily:"sans-serif",fontStyle:"normal",fontWeight:"normal",fontVariant:"normal",textAlign:"start",textBaseline:"bottom",lineHeight:null,textArr:null},r.extend(a,i),r.augment(a,{canFill:!0,canStroke:!0,type:"text",getDefaultAttrs:function(){return{lineWidth:1,lineCount:1,fontSize:12,fontFamily:"sans-serif",fontStyle:"normal",fontWeight:"normal",fontVariant:"normal",textAlign:"start",textBaseline:"bottom"}},initTransform:function(){this.attr("matrix",[1,0,0,0,1,0,0,0,1]);var t=this.__attrs.fontSize;t&&+t<12&&this.transform([["t",-1*this.__attrs.x,-1*this.__attrs.y],["s",+t/12,+t/12],["t",this.__attrs.x,this.__attrs.y]])},__assembleFont:function(){var t=this.__attrs,e=t.fontSize,n=t.fontFamily,r=t.fontWeight,i=t.fontStyle,o=t.fontVariant;t.font=[i,o,r,e+"px",n].join(" ")},__afterSetAttrFontSize:function(){this.__assembleFont()},__afterSetAttrFontFamily:function(){this.__assembleFont()},__afterSetAttrFontWeight:function(){this.__assembleFont()},__afterSetAttrFontStyle:function(){this.__assembleFont()},__afterSetAttrFontVariant:function(){this.__assembleFont()},__afterSetAttrFont:function(){},__afterSetAttrText:function(){var t=this.__attrs,e=t.text,n=void 0;if(r.isString(e)&&-1!==e.indexOf("\n")){var i=(n=e.split("\n")).length;t.lineCount=i,t.textArr=n}},__getTextHeight:function(){var t=this.__attrs,e=t.lineCount,n=1*t.fontSize;return e>1?n*e+this.__getSpaceingY()*(e-1):n},__afterSetAttrAll:function(t){("fontSize"in t||"fontWeight"in t||"fontStyle"in t||"fontVariant"in t||"fontFamily"in t)&&this.__assembleFont(),"text"in t&&this.__afterSetAttrText(t.text)},isHitBox:function(){return!1},calculateBox:function(){var t=this.__attrs,e=t.x,n=t.y,r=this.measureText();if(!r)return{minX:e,minY:n,maxX:e,maxY:n};var i=this.__getTextHeight(),o=t.textAlign,a=t.textBaseline,s=this.getHitLineWidth(),u={x:e,y:n-i};o&&("end"===o||"right"===o?u.x-=r:"center"===o&&(u.x-=r/2)),a&&("top"===a?u.y+=i:"middle"===a&&(u.y+=i/2)),this.set("startPoint",u);var l=s/2;return{minX:u.x-l,minY:u.y-l,maxX:u.x+r+l,maxY:u.y+i+l}},__getSpaceingY:function(){var t=this.__attrs,e=t.lineHeight,n=1*t.fontSize;return e?e-n:.14*n},isPointInPath:function(t,e){var n=this.getBBox();if(this.hasFill()||this.hasStroke())return o.box(n.minX,n.maxX,n.minY,n.maxY,t,e)},drawInner:function(t){var e=this.__attrs,n=e.text;if(n){var i=e.textArr,o=1*e.fontSize,a=this.__getSpaceingY(),s=e.x,u=e.y,l=e.textBaseline,c=void 0;if(i){var h=this.getBBox();c=h.maxY-h.minY}var f=void 0;if(t.beginPath(),this.hasFill()){var p=e.fillOpacity;r.isNil(p)||1===p||(t.globalAlpha=p),i?r.each(i,function(e,n){f=u+n*(a+o)-c+o,"middle"===l&&(f+=c-o-(c-o)/2),"top"===l&&(f+=c-o),t.fillText(e,s,f)}):t.fillText(n,s,u)}this.hasStroke()&&(i?r.each(i,function(e,n){f=u+n*(a+o)-c+o,"middle"===l&&(f+=c-o-(c-o)/2),"top"===l&&(f+=c-o),t.strokeText(e,s,f)}):t.strokeText(n,s,u))}},measureText:function(){var t=this.__attrs,e=t.text,n=t.font,i=t.textArr,o=void 0,a=0;if(!r.isNil(e)){var s=document.createElement("canvas").getContext("2d");return s.save(),s.font=n,i?r.each(i,function(t){o=s.measureText(t).width,a<o&&(a=o),s.restore()}):(a=s.measureText(e).width,s.restore()),a}}}),t.exports=a},function(t,e,n){var r=n(553),i=n(557),o=n(597),a=n(621),s=n(892),u=n(558).vec3,l=n(558).mat3,c=["m","l","c","a","q","h","v","t","s","z"];function h(t,e,n){return{x:n.x+t,y:n.y+e}}function f(t,e){return{x:e.x+(e.x-t.x),y:e.y+(e.y-t.y)}}function p(t){return Math.sqrt(t[0]*t[0]+t[1]*t[1])}function d(t,e){return(t[0]*e[0]+t[1]*e[1])/(p(t)*p(e))}function g(t,e){return(t[0]*e[1]<t[1]*e[0]?-1:1)*Math.acos(d(t,e))}var v=function(t,e,n){this.preSegment=e,this.isLast=n,this.init(t,e)};r.augment(v,{init:function(t,e){var n=t[0];e=e||{endPoint:{x:0,y:0}};var i=c.indexOf(n)>=0,o=i?n.toUpperCase():n,a=t,s=void 0,u=void 0,l=void 0,p=void 0,v=e.endPoint,y=a[1],m=a[2];switch(o){default:break;case"M":p=i?h(y,m,v):{x:y,y:m},this.command="M",this.params=[v,p],this.subStart=p,this.endPoint=p;break;case"L":p=i?h(y,m,v):{x:y,y:m},this.command="L",this.params=[v,p],this.subStart=e.subStart,this.endPoint=p,this.endTangent=function(){return[p.x-v.x,p.y-v.y]},this.startTangent=function(){return[v.x-p.x,v.y-p.y]};break;case"H":p=i?h(y,0,v):{x:y,y:v.y},this.command="L",this.params=[v,p],this.subStart=e.subStart,this.endPoint=p,this.endTangent=function(){return[p.x-v.x,p.y-v.y]},this.startTangent=function(){return[v.x-p.x,v.y-p.y]};break;case"V":p=i?h(0,y,v):{x:v.x,y:y},this.command="L",this.params=[v,p],this.subStart=e.subStart,this.endPoint=p,this.endTangent=function(){return[p.x-v.x,p.y-v.y]},this.startTangent=function(){return[v.x-p.x,v.y-p.y]};break;case"Q":i?(s=h(y,m,v),u=h(a[3],a[4],v)):(s={x:y,y:m},u={x:a[3],y:a[4]}),this.command="Q",this.params=[v,s,u],this.subStart=e.subStart,this.endPoint=u,this.endTangent=function(){return[u.x-s.x,u.y-s.y]},this.startTangent=function(){return[v.x-s.x,v.y-s.y]};break;case"T":u=i?h(y,m,v):{x:y,y:m},"Q"===e.command?(s=f(e.params[1],v),this.command="Q",this.params=[v,s,u],this.subStart=e.subStart,this.endPoint=u,this.endTangent=function(){return[u.x-s.x,u.y-s.y]},this.startTangent=function(){return[v.x-s.x,v.y-s.y]}):(this.command="TL",this.params=[v,u],this.subStart=e.subStart,this.endPoint=u,this.endTangent=function(){return[u.x-v.x,u.y-v.y]},this.startTangent=function(){return[v.x-u.x,v.y-u.y]});break;case"C":i?(s=h(y,m,v),u=h(a[3],a[4],v),l=h(a[5],a[6],v)):(s={x:y,y:m},u={x:a[3],y:a[4]},l={x:a[5],y:a[6]}),this.command="C",this.params=[v,s,u,l],this.subStart=e.subStart,this.endPoint=l,this.endTangent=function(){return[l.x-u.x,l.y-u.y]},this.startTangent=function(){return[v.x-s.x,v.y-s.y]};break;case"S":i?(u=h(y,m,v),l=h(a[3],a[4],v)):(u={x:y,y:m},l={x:a[3],y:a[4]}),"C"===e.command?(s=f(e.params[2],v),this.command="C",this.params=[v,s,u,l],this.subStart=e.subStart,this.endPoint=l,this.endTangent=function(){return[l.x-u.x,l.y-u.y]},this.startTangent=function(){return[v.x-s.x,v.y-s.y]}):(this.command="SQ",this.params=[v,u,l],this.subStart=e.subStart,this.endPoint=l,this.endTangent=function(){return[l.x-u.x,l.y-u.y]},this.startTangent=function(){return[v.x-u.x,v.y-u.y]});break;case"A":var x=y,b=m,_=a[3],w=a[4],S=a[5];p=i?h(a[6],a[7],v):{x:a[6],y:a[7]},this.command="A",this.params=function(t,e,n,i,o,a,s){var u=r.mod(r.toRadian(s),2*Math.PI),l=t.x,c=t.y,h=e.x,f=e.y,p=Math.cos(u)*(l-h)/2+Math.sin(u)*(c-f)/2,v=-1*Math.sin(u)*(l-h)/2+Math.cos(u)*(c-f)/2,y=p*p/(o*o)+v*v/(a*a);y>1&&(o*=Math.sqrt(y),a*=Math.sqrt(y));var m=Math.sqrt((o*o*(a*a)-o*o*(v*v)-a*a*(p*p))/(o*o*(v*v)+a*a*(p*p)));n===i&&(m*=-1),isNaN(m)&&(m=0);var x=m*o*v/a,b=m*-a*p/o,_=(l+h)/2+Math.cos(u)*x-Math.sin(u)*b,w=(c+f)/2+Math.sin(u)*x+Math.cos(u)*b,S=g([1,0],[(p-x)/o,(v-b)/a]),M=[(p-x)/o,(v-b)/a],C=[(-1*p-x)/o,(-1*v-b)/a],P=g(M,C);return d(M,C)<=-1&&(P=Math.PI),d(M,C)>=1&&(P=0),0===i&&P>0&&(P-=2*Math.PI),1===i&&P<0&&(P+=2*Math.PI),[t,_,w,o,a,S,P,u,i]}(v,p,w,S,x,b,_),this.subStart=e.subStart,this.endPoint=p;break;case"Z":this.command="Z",this.params=[v,e.subStart],this.subStart=e.subStart,this.endPoint=e.subStart}},isInside:function(t,e,n){var r=this.command,o=this.params,a=this.box;if(a&&!i.box(a.minX,a.maxX,a.minY,a.maxY,t,e))return!1;switch(r){default:break;case"M":return!1;case"TL":case"L":case"Z":return i.line(o[0].x,o[0].y,o[1].x,o[1].y,n,t,e);case"SQ":case"Q":return i.quadraticline(o[0].x,o[0].y,o[1].x,o[1].y,o[2].x,o[2].y,n,t,e);case"C":return i.cubicline(o[0].x,o[0].y,o[1].x,o[1].y,o[2].x,o[2].y,o[3].x,o[3].y,n,t,e);case"A":var s=o,c=s[1],h=s[2],f=s[3],p=s[4],d=s[5],g=s[6],v=s[7],y=s[8],m=f>p?f:p,x=f>p?1:f/p,b=f>p?p/f:1;s=[t,e,1];var _=[1,0,0,0,1,0,0,0,1];return l.translate(_,_,[-c,-h]),l.rotate(_,_,-v),l.scale(_,_,[1/x,1/b]),u.transformMat3(s,s,_),i.arcline(0,0,m,d,d+g,1-y,n,s[0],s[1])}return!1},draw:function(t){var e=this.command,n=this.params,r=void 0,i=void 0,o=void 0;switch(e){default:break;case"M":t.moveTo(n[1].x,n[1].y);break;case"TL":case"L":t.lineTo(n[1].x,n[1].y);break;case"SQ":case"Q":r=n[1],i=n[2],t.quadraticCurveTo(r.x,r.y,i.x,i.y);break;case"C":r=n[1],i=n[2],o=n[3],t.bezierCurveTo(r.x,r.y,i.x,i.y,o.x,o.y);break;case"A":var a=n,s=a[1],u=a[2],l=a[3],c=a[4],h=a[5],f=a[6],p=a[7],d=a[8],g=l>c?l:c,v=l>c?1:l/c,y=l>c?c/l:1;t.translate(s,u),t.rotate(p),t.scale(v,y),t.arc(0,0,g,h,h+f,1-d),t.scale(1/v,1/y),t.rotate(-p),t.translate(-s,-u);break;case"Z":t.closePath()}},getBBox:function(t){var e=t/2,n=this.params,r=void 0,i=void 0,u=void 0,l=void 0;switch(this.command){default:case"M":case"Z":break;case"TL":case"L":this.box={minX:Math.min(n[0].x,n[1].x)-e,maxX:Math.max(n[0].x,n[1].x)+e,minY:Math.min(n[0].y,n[1].y)-e,maxY:Math.max(n[0].y,n[1].y)+e};break;case"SQ":case"Q":for(u=0,l=(i=a.extrema(n[0].x,n[1].x,n[2].x)).length;u<l;u++)i[u]=a.at(n[0].x,n[1].x,n[2].x,i[u]);for(i.push(n[0].x,n[2].x),u=0,l=(r=a.extrema(n[0].y,n[1].y,n[2].y)).length;u<l;u++)r[u]=a.at(n[0].y,n[1].y,n[2].y,r);r.push(n[0].y,n[2].y),this.box={minX:Math.min.apply(Math,i)-e,maxX:Math.max.apply(Math,i)+e,minY:Math.min.apply(Math,r)-e,maxY:Math.max.apply(Math,r)+e};break;case"C":for(u=0,l=(i=o.extrema(n[0].x,n[1].x,n[2].x,n[3].x)).length;u<l;u++)i[u]=o.at(n[0].x,n[1].x,n[2].x,n[3].x,i[u]);for(u=0,l=(r=o.extrema(n[0].y,n[1].y,n[2].y,n[3].y)).length;u<l;u++)r[u]=o.at(n[0].y,n[1].y,n[2].y,n[3].y,r[u]);i.push(n[0].x,n[3].x),r.push(n[0].y,n[3].y),this.box={minX:Math.min.apply(Math,i)-e,maxX:Math.max.apply(Math,i)+e,minY:Math.min.apply(Math,r)-e,maxY:Math.max.apply(Math,r)+e};break;case"A":var c=n,h=c[1],f=c[2],p=c[3],d=c[4],g=c[5],v=c[6],y=c[7],m=c[8],x=g,b=g+v,_=s.xExtrema(y,p,d),w=1/0,S=-1/0,M=[x,b];for(u=2*-Math.PI;u<=2*Math.PI;u+=Math.PI){var C=_+u;1===m?x<C&&C<b&&M.push(C):b<C&&C<x&&M.push(C)}for(u=0,l=M.length;u<l;u++){var P=s.xAt(y,p,d,h,M[u]);P<w&&(w=P),P>S&&(S=P)}var A=s.yExtrema(y,p,d),I=1/0,O=-1/0,E=[x,b];for(u=2*-Math.PI;u<=2*Math.PI;u+=Math.PI){var T=A+u;1===m?x<T&&T<b&&E.push(T):b<T&&T<x&&E.push(T)}for(u=0,l=E.length;u<l;u++){var k=s.yAt(y,p,d,f,E[u]);k<I&&(I=k),k>O&&(O=k)}this.box={minX:w-e,maxX:S+e,minY:I-e,maxY:O+e}}}}),t.exports=v},function(t,e,n){var r=n(553),i=n(556),o=n(685),a=n(689),s=n(574),u=n(623),l=n(597),c=function t(e){t.superclass.constructor.call(this,e)};c.ATTRS={path:null,lineWidth:1,curve:null,tCache:null,startArrow:!1,endArrow:!1},r.extend(c,i),r.augment(c,{canFill:!0,canStroke:!0,type:"path",getDefaultAttrs:function(){return{lineWidth:1,startArrow:!1,endArrow:!1}},__afterSetAttrPath:function(t){if(r.isNil(t))return this.setSilent("segments",null),void this.setSilent("box",void 0);var e=a.parsePath(t),n=void 0,i=[];if(r.isArray(e)&&0!==e.length&&("M"===e[0][0]||"m"===e[0][0])){for(var s=e.length,u=0;u<e.length;u++){var l=e[u];n=new o(l,n,u===s-1),i.push(n)}this.setSilent("segments",i),this.set("tCache",null),this.setSilent("box",null)}},__afterSetAttrAll:function(t){t.path&&this.__afterSetAttrPath(t.path)},calculateBox:function(){var t=this.get("segments");if(!t)return null;var e=this.getHitLineWidth(),n=1/0,i=-1/0,o=1/0,a=-1/0;return r.each(t,function(t){t.getBBox(e);var r=t.box;r&&(r.minX<n&&(n=r.minX),r.maxX>i&&(i=r.maxX),r.minY<o&&(o=r.minY),r.maxY>a&&(a=r.maxY))}),{minX:n,minY:o,maxX:i,maxY:a}},isPointInPath:function(t,e){var n=this.hasFill(),r=this.hasStroke();return n&&r?this.__isPointInFill(t,e)||this.__isPointInStroke(t,e):n?this.__isPointInFill(t,e):!!r&&this.__isPointInStroke(t,e)},__isPointInFill:function(t,e){var n=this.get("context");if(n)return this.createPath(),n.isPointInPath(t,e)},__isPointInStroke:function(t,e){var n=this.get("segments");if(!r.isEmpty(n))for(var i=this.getHitLineWidth(),o=0,a=n.length;o<a;o++)if(n[o].isInside(t,e,i))return!0;return!1},__setTcache:function(){var t=0,e=0,n=[],i=void 0,o=void 0,a=void 0,s=void 0,u=this.curve;u&&(r.each(u,function(e,n){a=u[n+1],s=e.length,a&&(t+=l.len(e[s-2],e[s-1],a[1],a[2],a[3],a[4],a[5],a[6]))}),r.each(u,function(r,c){a=u[c+1],s=r.length,a&&((i=[])[0]=e/t,o=l.len(r[s-2],r[s-1],a[1],a[2],a[3],a[4],a[5],a[6]),e+=o,i[1]=e/t,n.push(i))}),this.tCache=n)},__calculateCurve:function(){var t=this.__attrs.path;this.curve=u.pathTocurve(t)},getPoint:function(t){var e=this.tCache,n=void 0,i=void 0;e||(this.__calculateCurve(),this.__setTcache(),e=this.tCache);var o=this.curve;if(!e)return o?{x:o[0][1],y:o[0][2]}:null;r.each(e,function(e,r){t>=e[0]&&t<=e[1]&&(n=(t-e[0])/(e[1]-e[0]),i=r)});var a=o[i];if(r.isNil(a)||r.isNil(i))return null;var s=a.length,u=o[i+1];return{x:l.at(a[s-2],u[1],u[3],u[5],1-n),y:l.at(a[s-1],u[2],u[4],u[6],1-n)}},createPath:function(t){var e=this.__attrs,n=this.get("segments");if(r.isArray(n)){(t=t||this.get("context")).beginPath();var i=e.path,o=void 0,a=void 0,u=!1;("z"===i[i.length-1]||"Z"===i[i.length-1]||e.fill)&&(u=!0);var l=n.length;l>1&&!u&&(o=n[0].endPoint,a=n[1].endPoint,s.addStartArrow(t,e,a.x,a.y,o.x,o.y));for(var c=0,h=l;c<h;c++)n[c].draw(t);l>1&&!u&&(o=n[l-2].endPoint,a=n[l-1].endPoint,s.addEndArrow(t,e,o.x,o.y,a.x,a.y))}}}),t.exports=c},function(t,e,n){var r=n(553),i=n(556),o=n(557),a=n(558).mat3,s=n(558).vec3,u=function t(e){t.superclass.constructor.call(this,e)};u.ATTRS={x:0,y:0,rx:1,ry:1,lineWidth:1},r.extend(u,i),r.augment(u,{canFill:!0,canStroke:!0,type:"ellipse",getDefaultAttrs:function(){return{lineWidth:1}},calculateBox:function(){var t=this.__attrs,e=t.x,n=t.y,r=t.rx,i=t.ry,o=this.getHitLineWidth(),a=r+o/2,s=i+o/2;return{minX:e-a,minY:n-s,maxX:e+a,maxY:n+s}},isPointInPath:function(t,e){var n=this.hasFill(),r=this.hasStroke();return n&&r?this.__isPointInFill(t,e)||this.__isPointInStroke(t,e):n?this.__isPointInFill(t,e):!!r&&this.__isPointInStroke(t,e)},__isPointInFill:function(t,e){var n=this.__attrs,r=n.x,i=n.y,u=n.rx,l=n.ry,c=u>l?u:l,h=u>l?1:u/l,f=u>l?l/u:1,p=[t,e,1],d=[1,0,0,0,1,0,0,0,1];a.scale(d,d,[h,f]),a.translate(d,d,[r,i]);var g=a.invert([],d);return s.transformMat3(p,p,g),o.circle(0,0,c,p[0],p[1])},__isPointInStroke:function(t,e){var n=this.__attrs,r=n.x,i=n.y,u=n.rx,l=n.ry,c=this.getHitLineWidth(),h=u>l?u:l,f=u>l?1:u/l,p=u>l?l/u:1,d=[t,e,1],g=[1,0,0,0,1,0,0,0,1];a.scale(g,g,[f,p]),a.translate(g,g,[r,i]);var v=a.invert([],g);return s.transformMat3(d,d,v),o.arcline(0,0,h,0,2*Math.PI,!1,c,d[0],d[1])},createPath:function(t){var e=this.__attrs,n=e.x,r=e.y,i=e.rx,o=e.ry;t=t||self.get("context");var s=i>o?i:o,u=i>o?1:i/o,l=i>o?o/i:1,c=[1,0,0,0,1,0,0,0,1];a.scale(c,c,[u,l]),a.translate(c,c,[n,r]),t.beginPath(),t.save(),t.transform(c[0],c[1],c[3],c[4],c[6],c[7]),t.arc(0,0,s,0,2*Math.PI),t.restore(),t.closePath()}}),t.exports=u},function(t,e,n){var r=n(553),i=n(556),o=n(557),a=function t(e){t.superclass.constructor.call(this,e)};a.ATTRS={x:0,y:0,r:0,lineWidth:1},r.extend(a,i),r.augment(a,{canFill:!0,canStroke:!0,type:"circle",getDefaultAttrs:function(){return{lineWidth:1}},calculateBox:function(){var t=this.__attrs,e=t.x,n=t.y,r=t.r,i=this.getHitLineWidth()/2+r;return{minX:e-i,minY:n-i,maxX:e+i,maxY:n+i}},isPointInPath:function(t,e){var n=this.hasFill(),r=this.hasStroke();return n&&r?this.__isPointInFill(t,e)||this.__isPointInStroke(t,e):n?this.__isPointInFill(t,e):!!r&&this.__isPointInStroke(t,e)},__isPointInFill:function(t,e){var n=this.__attrs,r=n.x,i=n.y,a=n.r;return o.circle(r,i,a,t,e)},__isPointInStroke:function(t,e){var n=this.__attrs,r=n.x,i=n.y,a=n.r,s=this.getHitLineWidth();return o.arcline(r,i,a,0,2*Math.PI,!1,s,t,e)},createPath:function(t){var e=this.__attrs,n=e.x,r=e.y,i=e.r;(t=t||self.get("context")).beginPath(),t.arc(n,r,i,0,2*Math.PI,!1)}}),t.exports=a},function(t,e,n){var r=n(553),i=/[MLHVQTCSAZ]([^MLHVQTCSAZ]*)/gi,o=/[^\s\,]+/gi,a=/^l\s*\(\s*([\d.]+)\s*\)\s*(.*)/i,s=/^r\s*\(\s*([\d.]+)\s*,\s*([\d.]+)\s*,\s*([\d.]+)\s*\)\s*(.*)/i,u=/^p\s*\(\s*([axyn])\s*\)\s*(.*)/i,l=/[\d.]+:(#[^\s]+|[^\)]+\))/gi,c={};function h(t,e){var n=t.match(l);r.each(n,function(t){t=t.split(":"),e.addColorStop(t[0],t[1])})}t.exports={parsePath:function(t){return t=t||[],r.isArray(t)?t:r.isString(t)?(t=t.match(i),r.each(t,function(e,n){if((e=e.match(o))[0].length>1){var i=e[0].charAt(0);e.splice(1,0,e[0].substr(1)),e[0]=i}r.each(e,function(t,n){isNaN(t)||(e[n]=+t)}),t[n]=e}),t):void 0},parseStyle:function(t,e){if(r.isString(t)){if("("===t[1]||"("===t[2]){if("l"===t[0])return function(t,e){var n=a.exec(t),i=r.mod(r.toRadian(parseFloat(n[1])),2*Math.PI),o=n[2],s=e.getBBox(),u=void 0,l=void 0;i>=0&&i<.5*Math.PI?(u={x:s.minX,y:s.minY},l={x:s.maxX,y:s.maxY}):.5*Math.PI<=i&&i<Math.PI?(u={x:s.maxX,y:s.minY},l={x:s.minX,y:s.maxY}):Math.PI<=i&&i<1.5*Math.PI?(u={x:s.maxX,y:s.maxY},l={x:s.minX,y:s.minY}):(u={x:s.minX,y:s.maxY},l={x:s.maxX,y:s.minY});var c=Math.tan(i),f=c*c,p=(l.x-u.x+c*(l.y-u.y))/(f+1)+u.x,d=c*(l.x-u.x+c*(l.y-u.y))/(f+1)+u.y,g=e.get("context").createLinearGradient(u.x,u.y,p,d);return h(o,g),g}(t,e);if("r"===t[0])return function(t,e){var n=s.exec(t),r=parseFloat(n[1]),i=parseFloat(n[2]),o=parseFloat(n[3]),a=n[4],u=e.getBBox(),l=e.get("context"),c=u.maxX-u.minX,f=u.maxY-u.minY,p=Math.sqrt(c*c+f*f)/2,d=l.createRadialGradient(u.minX+c*r,u.minY+f*i,o*p,u.minX+c/2,u.minY+f/2,p);return h(a,d),d}(t,e);if("p"===t[0])return function(t,e){if(e.get("patternSource")&&e.get("patternSource")===t)return e.get("pattern");var n=void 0,r=void 0,i=u.exec(t),o=i[1],a=i[2];function s(){var i=e.get("context");n=i.createPattern(r,o),e.setSilent("pattern",n),e.setSilent("patternSource",t)}switch(o){case"a":o="repeat";break;case"x":o="repeat-x";break;case"y":o="repeat-y";break;case"n":o="no-repeat";break;default:o="no-repeat"}return r=new Image,a.match(/^data:/i)||(r.crossOrigin="Anonymous"),r.src=a,r.complete?s():(r.onload=s,r.src=r.src),n}(t,e)}return t}},numberToColor:function(t){var e=c[t];if(!e){for(var n=t.toString(16),r=n.length;r<6;r++)n="0"+n;e="#"+n,c[t]=e}return e}}},function(t,e,n){var r=n(553),i=n(900),o=n(899),a=n(895),s=n(689),u=n(894),l=["fillStyle","font","globalAlpha","lineCap","lineWidth","lineJoin","miterLimit","shadowBlur","shadowColor","shadowOffsetX","shadowOffsetY","strokeStyle","textAlign","textBaseline","lineDash","lineDashOffset"],c=function(t){this.__cfg={zIndex:0,capture:!0,visible:!0,destroyed:!1},r.assign(this.__cfg,this.getDefaultCfg(),t),this.initAttrs(this.__cfg.attrs),this.initTransform(),this.init()};c.CFG={id:null,zIndex:0,canvas:null,parent:null,capture:!0,context:null,visible:!0,destroyed:!1},r.augment(c,i,o,u,a,{init:function(){this.setSilent("animable",!0),this.setSilent("animating",!1);var t=this.__attrs;t&&t.rotate&&this.rotateAtStart(t.rotate)},getParent:function(){return this.get("parent")},getDefaultCfg:function(){return{}},set:function(t,e){var n="__set"+r.upperFirst(t);return this[n]&&(e=this[n](e)),this.__cfg[t]=e,this},setSilent:function(t,e){this.__cfg[t]=e},get:function(t){return this.__cfg[t]},draw:function(t){this.get("destroyed")||this.get("visible")&&(this.setContext(t),this.drawInner(t),this.restoreContext(t))},setContext:function(t){var e=this.__attrs.clip;t.save(),e&&(e.resetTransform(t),e.createPath(t),t.clip()),this.resetContext(t),this.resetTransform(t)},restoreContext:function(t){t.restore()},resetContext:function(t){var e=this.__attrs;if(!this.isGroup)for(var n in e)if(l.indexOf(n)>-1){var i=e[n];"fillStyle"===n&&(i=s.parseStyle(i,this)),"strokeStyle"===n&&(i=s.parseStyle(i,this)),"lineDash"===n&&t.setLineDash?r.isArray(i)?t.setLineDash(i):r.isString(i)&&t.setLineDash(i.split(" ")):t[n]=i}},drawInner:function(){},show:function(){return this.set("visible",!0),this},hide:function(){return this.set("visible",!1),this},remove:function(t){if(void 0===t&&(t=!0),this.get("parent")){var e=this.get("parent").get("children");r.remove(e,this)}return t&&this.destroy(),this},destroy:function(){if(!this.get("destroyed")){if(this.get("animating")){var t=this.get("animateTimer");t&&t.stop()}this.__cfg={},this.__attrs=null,this.removeEvent(),this.set("destroyed",!0)}},__setZIndex:function(t){return this.__cfg.zIndex=t,r.isNil(this.get("parent"))||this.get("parent").sort(),t},__setAttrs:function(t){return this.attr(t),t},setZIndex:function(t){return this.__cfg.zIndex=t,t},clone:function(){return r.clone(this)},getBBox:function(){return{minX:0,maxX:0,minY:0,maxY:0}}}),t.exports=c},function(t,e,n){var r=n(553),i=n(690),o=n(893),a={},s="_INDEX";function u(t,e,n){for(var r=void 0,i=t.length-1;i>=0;i--){var o=t[i];if(o.__cfg.visible&&o.__cfg.capture&&(o.isGroup?r=o.getShape(e,n):o.isHit(e,n)&&(r=o)),r)break}return r}var l=function t(e){t.superclass.constructor.call(this,e),this.set("children",[]),this._beforeRenderUI(),this._renderUI(),this._bindUI()};r.extend(l,i),r.augment(l,{isGroup:!0,canFill:!0,canStroke:!0,getDefaultCfg:function(){return function t(e){if(!e.__cfg&&e!==l){var n=e.superclass.constructor;n&&!n.__cfg&&t(n),e.__cfg={},r.merge(e.__cfg,n.__cfg),r.merge(e.__cfg,e.CFG)}}(this.constructor),r.merge({},this.constructor.__cfg)},_beforeRenderUI:function(){},_renderUI:function(){},_bindUI:function(){},addShape:function(t,e){var n=this.get("canvas");e=e||{};var i=a[t];if(i||(i=r.upperFirst(t),a[t]=i),e.attrs){var s=e.attrs;if("text"===t){var u=n.get("fontFamily");u&&(s.fontFamily=s.fontFamily?s.fontFamily:u)}}e.canvas=n,e.type=t;var l=new o[i](e);return this.add(l),l},addGroup:function(t,e){var n=this.get("canvas"),i=void 0;if(e=r.merge({},e),r.isFunction(t))e?(e.canvas=n,e.parent=this,i=new t(e)):i=new t({canvas:n,parent:this}),this.add(i);else if(r.isObject(t))t.canvas=n,i=new l(t),this.add(i);else{if(void 0!==t)return!1;i=new l,this.add(i)}return i},renderBack:function(t,e){var n=this.get("backShape"),i=this.getBBox();return r.merge(e,{x:i.minX-t[3],y:i.minY-t[0],width:i.width+t[1]+t[3],height:i.height+t[0]+t[2]}),n?n.attr(e):n=this.addShape("rect",{zIndex:-1,attrs:e}),this.set("backShape",n),this.sort(),n},removeChild:function(t,e){if(arguments.length>=2)this.contain(t)&&t.remove(e);else{if(1===arguments.length){if(!r.isBoolean(t))return this.contain(t)&&t.remove(!0),this;e=t}0===arguments.length&&(e=!0),l.superclass.remove.call(this,e)}return this},add:function(t){var e=this,n=e.get("children");if(r.isArray(t))r.each(t,function(t){var n=t.get("parent");n&&n.removeChild(t,!1),e.__setEvn(t)}),n.push.apply(n,t);else{var i=t,o=i.get("parent");o&&o.removeChild(i,!1),e.__setEvn(i),n.push(i)}return e},contain:function(t){return this.get("children").indexOf(t)>-1},getChildByIndex:function(t){return this.get("children")[t]},getFirst:function(){return this.getChildByIndex(0)},getLast:function(){var t=this.get("children").length-1;return this.getChildByIndex(t)},__setEvn:function(t){t.__cfg.parent=this,t.__cfg.context=this.__cfg.context,t.__cfg.canvas=this.__cfg.canvas;var e=t.__attrs.clip;e&&(e.setSilent("parent",this),e.setSilent("context",this.get("context")));var n=t.__cfg.children;n&&r.each(n,function(e){t.__setEvn(e)})},getBBox:function(){var t=1/0,e=-1/0,n=1/0,i=-1/0,o=this.get("children");r.each(o,function(r){if(r.get("visible")){var o=r.getBBox();if(!o)return!0;var a=[o.minX,o.minY,1],s=[o.minX,o.maxY,1],u=[o.maxX,o.minY,1],l=[o.maxX,o.maxY,1];r.apply(a),r.apply(s),r.apply(u),r.apply(l);var c=Math.min(a[0],s[0],u[0],l[0]),h=Math.max(a[0],s[0],u[0],l[0]),f=Math.min(a[1],s[1],u[1],l[1]),p=Math.max(a[1],s[1],u[1],l[1]);c<t&&(t=c),h>e&&(e=h),f<n&&(n=f),p>i&&(i=p)}});var a={minX:t,minY:n,maxX:e,maxY:i};return a.x=a.minX,a.y=a.minY,a.width=a.maxX-a.minX,a.height=a.maxY-a.minY,a},drawInner:function(t){for(var e=this.get("children"),n=0;n<e.length;n++){e[n].draw(t)}return this},getCount:function(){return this.get("children").length},sort:function(){var t,e=this.get("children");return r.each(e,function(t,e){return t[s]=e,t}),e.sort((t=function(t,e){return t.get("zIndex")-e.get("zIndex")},function(e,n){var r=t(e,n);return 0===r?e[s]-n[s]:r})),this},find:function(t){return this.findBy(function(e){return e.get("id")===t})},findBy:function(t){var e=this.get("children"),n=null;return r.each(e,function(e){if(t(e)?n=e:e.findBy&&(n=e.findBy(t)),n)return!1}),n},findAllBy:function(t){var e=this.get("children"),n=[],i=[];return r.each(e,function(e){t(e)&&n.push(e),e.findAllBy&&(i=e.findAllBy(t),n=n.concat(i))}),n},getShape:function(t,e){var n=this.__attrs.clip,r=this.__cfg.children,i=void 0;return n?n.inside(t,e)&&(i=u(r,t,e)):i=u(r,t,e),i},clearTotalMatrix:function(){if(this.get("totalMatrix")){this.setSilent("totalMatrix",null);for(var t=this.__cfg.children,e=0;e<t.length;e++){t[e].clearTotalMatrix()}}},clear:function(){for(var t=this.get("children");0!==t.length;)t[t.length-1].remove();return this},destroy:function(){this.get("destroyed")||(this.clear(),l.superclass.destroy.call(this))}}),t.exports=l},function(t,e,n){var r=n(553),i=function(t,e,n,r){this.type=t,this.target=null,this.currentTarget=null,this.bubbles=n,this.cancelable=r,this.timeStamp=(new Date).getTime(),this.defaultPrevented=!1,this.propagationStopped=!1,this.removed=!1,this.event=e};r.augment(i,{preventDefault:function(){this.defaultPrevented=this.cancelable&&!0},stopPropagation:function(){this.propagationStopped=!0},remove:function(){this.remove=!0},clone:function(){return r.clone(this)},toString:function(){return"[Event (type="+this.type+")]"}}),t.exports=i},function(t,e,n){var r=n(585),i=document.createElement("table"),o=document.createElement("tr"),a=/^\s*<(\w+|!)[^>]*>/,s={tr:document.createElement("tbody"),tbody:i,thead:i,tfoot:i,td:o,th:o,"*":document.createElement("div")};t.exports={getBoundingClientRect:function(t,e){if(t&&t.getBoundingClientRect){var n=t.getBoundingClientRect(),r=document.documentElement.clientTop,i=document.documentElement.clientLeft;return{top:n.top-r,bottom:n.bottom-r,left:n.left-i,right:n.right-i}}return e||null},getStyle:function(t,e,n){try{return window.getComputedStyle?window.getComputedStyle(t,null)[e]:t.currentStyle[e]}catch(t){return r.isNil(n)?null:n}},modifyCSS:function(t,e){if(t)for(var n in e)e.hasOwnProperty(n)&&(t.style[n]=e[n]);return t},createDom:function(t){var e=a.test(t)&&RegExp.$1;e in s||(e="*");var n=s[e];t=t.replace(/(^\s*)|(\s*$)/g,""),n.innerHTML=""+t;var r=n.childNodes[0];return n.removeChild(r),r},getRatio:function(){return window.devicePixelRatio?window.devicePixelRatio:2},getWidth:function(t,e){var n=this.getStyle(t,"width",e);return"auto"===n&&(n=t.offsetWidth),parseFloat(n)},getHeight:function(t,e){var n=this.getStyle(t,"height",e);return"auto"===n&&(n=t.offsetHeight),parseFloat(n)},getOuterHeight:function(t,e){var n=this.getHeight(t,e),r=parseFloat(this.getStyle(t,"borderTopWidth"))||0,i=parseFloat(this.getStyle(t,"paddingTop"))||0,o=parseFloat(this.getStyle(t,"paddingBottom"))||0;return n+r+(parseFloat(this.getStyle(t,"borderBottomWidth"))||0)+i+o},getOuterWidth:function(t,e){var n=this.getWidth(t,e),r=parseFloat(this.getStyle(t,"borderLeftWidth"))||0,i=parseFloat(this.getStyle(t,"paddingLeft"))||0,o=parseFloat(this.getStyle(t,"paddingRight"))||0;return n+r+(parseFloat(this.getStyle(t,"borderRightWidth"))||0)+i+o},addEventListener:function(t,e,n){if(t){if(t.addEventListener)return t.addEventListener(e,n,!1),{remove:function(){t.removeEventListener(e,n,!1)}};if(t.attachEvent)return t.attachEvent("on"+e,n),{remove:function(){t.detachEvent("on"+e,n)}}}},requestAnimationFrame:function(t){return(window.requestAnimationFrame||window.webkitRequestAnimationFrame||function(t){return setTimeout(t,16)})(t)}}},,,function(t,e,n){var r=n(915),i=n(697),o=n(914);t.exports=function(t){return i(t)?o(t):r(t)}},function(t,e){var n=RegExp("[\\u200d\\ud800-\\udfff\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff\\ufe0e\\ufe0f]");t.exports=function(t){return n.test(t)}},function(t,e,n){var r=n(917),i=n(697),o=n(696),a=n(569);t.exports=function(t){return function(e){e=a(e);var n=i(e)?o(e):void 0,s=n?n[0]:e.charAt(0),u=n?r(n,1).join(""):e.slice(1);return s[t]()+u}}},function(t,e){t.exports=function(t,e){return"__proto__"==e?void 0:t[e]}},function(t,e,n){var r=n(600),i=n(588);t.exports=function(t,e,n){(void 0===n||i(t[e],n))&&(void 0!==n||e in t)||r(t,e,n)}},function(t,e,n){var r=n(925),i=n(923)(r);t.exports=i},function(t,e,n){var r=n(926),i=Math.max;t.exports=function(t,e,n){return e=i(void 0===e?t.length-1:e,0),function(){for(var o=arguments,a=-1,s=i(o.length-e,0),u=Array(s);++a<s;)u[a]=o[e+a];a=-1;for(var l=Array(e+1);++a<e;)l[a]=o[a];return l[e]=n(u),r(t,this,l)}}},function(t,e,n){var r=n(598),i=n(729);t.exports=function(t){return r(function(e,n){var r=-1,o=n.length,a=o>1?n[o-1]:void 0,s=o>2?n[2]:void 0;for(a=t.length>3&&"function"==typeof a?(o--,a):void 0,s&&i(n[0],n[1],s)&&(a=o<3?void 0:a,o=1),e=Object(e);++r<o;){var u=n[r];u&&t(e,u,r,a)}return e})}},function(t,e,n){var r=n(929),i=n(260),o=n(164);t.exports=function(t){return"function"!=typeof t.constructor||o(t)?{}:r(i(t))}},function(t,e,n){var r=n(625);t.exports=function(t,e){var n=e?r(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.length)}},,function(t,e,n){var r=n(706),i=n(260),o=n(708),a=n(940),s=Object.getOwnPropertySymbols?function(t){for(var e=[];t;)r(e,o(t)),t=i(t);return e}:a;t.exports=s},,function(t,e,n){(function(t){var r=n(33),i="object"==typeof e&&e&&!e.nodeType&&e,o=i&&"object"==typeof t&&t&&!t.nodeType&&t,a=o&&o.exports===i?r.Buffer:void 0,s=a?a.allocUnsafe:void 0;t.exports=function(t,e){if(e)return t.slice();var n=t.length,r=s?s(n):new t.constructor(n);return t.copy(r),r}}).call(this,n(81)(t))},,function(t,e){t.exports=function(t,e){for(var n=-1,r=null==t?0:t.length;++n<r&&!1!==e(t[n],n,t););return t}},,function(t,e,n){var r=n(637),i=n(711),o=n(601),a=n(947),s=n(945),u=n(709),l=n(599),c=n(942),h=n(939),f=n(938),p=n(936),d=n(163),g=n(935),v=n(934),y=n(704),m=n(80),x=n(258),b=n(171),_=n(156),w=n(928),S=n(565),M=1,C=2,P=4,A="[object Arguments]",I="[object Function]",O="[object GeneratorFunction]",E="[object Object]",T={};T[A]=T["[object Array]"]=T["[object ArrayBuffer]"]=T["[object DataView]"]=T["[object Boolean]"]=T["[object Date]"]=T["[object Float32Array]"]=T["[object Float64Array]"]=T["[object Int8Array]"]=T["[object Int16Array]"]=T["[object Int32Array]"]=T["[object Map]"]=T["[object Number]"]=T[E]=T["[object RegExp]"]=T["[object Set]"]=T["[object String]"]=T["[object Symbol]"]=T["[object Uint8Array]"]=T["[object Uint8ClampedArray]"]=T["[object Uint16Array]"]=T["[object Uint32Array]"]=!0,T["[object Error]"]=T[I]=T["[object WeakMap]"]=!1,t.exports=function t(e,n,k,j,L,D){var F,R=n&M,B=n&C,N=n&P;if(k&&(F=L?k(e,j,L,D):k(e)),void 0!==F)return F;if(!_(e))return e;var z=m(e);if(z){if(F=g(e),!R)return l(e,F)}else{var V=d(e),G=V==I||V==O;if(x(e))return u(e,R);if(V==E||V==A||G&&!L){if(F=B||G?{}:y(e),!R)return B?h(e,s(F,e)):c(e,a(F,e))}else{if(!T[V])return L?e:{};F=v(e,V,R)}}D||(D=new r);var Y=D.get(e);if(Y)return Y;if(D.set(e,F),w(e))return e.forEach(function(r){F.add(t(r,n,k,r,e,D))}),F;if(b(e))return e.forEach(function(r,i){F.set(i,t(r,n,k,i,e,D))}),F;var W=N?B?p:f:B?keysIn:S,X=z?void 0:W(e);return i(X||e,function(r,i){X&&(r=e[i=r]),o(F,i,t(r,n,k,i,e,D))}),F}},function(t,e){t.exports=function(t){return null==t}},,,,,,function(t,e,n){var r=n(668);t.exports=function(t){return t&&t.length?r(t):[]}},,function(t,e,n){var r=n(583),i=n(254);t.exports=function(t,e){var n=-1,o=i(t)?Array(t.length):[];return r(t,function(t,r,i){o[++n]=e(t,r,i)}),o}},function(t,e,n){var r=n(584),i=n(566),o=n(722),a=n(80);t.exports=function(t,e){return(a(t)?r:o)(t,i(e,3))}},function(t,e,n){var r=n(600),i=n(883),o=Object.prototype.hasOwnProperty,a=i(function(t,e,n){o.call(t,n)?t[n].push(e):r(t,n,[e])});t.exports=a},,function(t,e,n){var r=n(609);t.exports=function(t){return"function"==typeof t?t:r}},function(t,e,n){var r=n(711),i=n(583),o=n(726),a=n(80);t.exports=function(t,e){return(a(t)?r:i)(t,o(e))}},function(t,e,n){var r=n(922),i=n(703)(function(t,e,n){r(t,e,n)});t.exports=i},function(t,e,n){var r=n(588),i=n(254),o=n(610),a=n(156);t.exports=function(t,e,n){if(!a(n))return!1;var s=typeof e;return!!("number"==s?i(n)&&o(e,n.length):"string"==s&&e in n)&&r(n[e],t)}},function(t,e,n){var r=n(713),i=4;t.exports=function(t){return r(t,i)}},function(t,e,n){var r=n(569),i=0;t.exports=function(t){var e=++i;return r(t)+e}},function(t,e,n){"use strict";var r=n(626),i=u(r),o=u(n(581)),a=u(n(764)),s=function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e.default=t,e}(n(763));function u(t){return t&&t.__esModule?t:{default:t}}var l=o.default.mix(s,{G2:i.default,Util:o.default,Shape:r.Shape,Animate:r.Animate,PathUtil:r.PathUtil,track:function(){var t=arguments.length>0&&void 0!==arguments[0]&&arguments[0];i.default.track(t)},setTheme:function(t){var e=t;"string"==typeof t&&a.default[t]&&(e=a.default[t]),i.default.Global.setTheme(e)}});e.default=l,t.exports=e.default},function(t,e,n){"use strict";n.r(e);var r=n(563),i={value:function(){}};function o(){for(var t,e=0,n=arguments.length,r={};e<n;++e){if(!(t=arguments[e]+"")||t in r)throw new Error("illegal type: "+t);r[t]=[]}return new a(r)}function a(t){this._=t}function s(t,e){for(var n,r=0,i=t.length;r<i;++r)if((n=t[r]).name===e)return n.value}function u(t,e,n){for(var r=0,o=t.length;r<o;++r)if(t[r].name===e){t[r]=i,t=t.slice(0,r).concat(t.slice(r+1));break}return null!=n&&t.push({name:e,value:n}),t}a.prototype=o.prototype={constructor:a,on:function(t,e){var n,r,i=this._,o=(r=i,(t+"").trim().split(/^|\s+/).map(function(t){var e="",n=t.indexOf(".");if(n>=0&&(e=t.slice(n+1),t=t.slice(0,n)),t&&!r.hasOwnProperty(t))throw new Error("unknown type: "+t);return{type:t,name:e}})),a=-1,l=o.length;if(!(arguments.length<2)){if(null!=e&&"function"!=typeof e)throw new Error("invalid callback: "+e);for(;++a<l;)if(n=(t=o[a]).type)i[n]=u(i[n],t.name,e);else if(null==e)for(n in i)i[n]=u(i[n],t.name,null);return this}for(;++a<l;)if((n=(t=o[a]).type)&&(n=s(i[n],t.name)))return n},copy:function(){var t={},e=this._;for(var n in e)t[n]=e[n].slice();return new a(t)},call:function(t,e){if((n=arguments.length-2)>0)for(var n,r,i=new Array(n),o=0;o<n;++o)i[o]=arguments[o+2];if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(o=0,n=(r=this._[t]).length;o<n;++o)r[o].value.apply(e,i)},apply:function(t,e,n){if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(var r=this._[t],i=0,o=r.length;i<o;++i)r[i].value.apply(e,n)}};var l=o,c=n(612),h=l("start","end","interrupt"),f=[],p=0,d=1,g=2,v=3,y=4,m=5,x=6,b=function(t,e,n,r,i,o){var a=t.__transition;if(a){if(n in a)return}else t.__transition={};!function(t,e,n){var r,i=t.__transition;function o(u){var l,h,f,p;if(n.state!==d)return s();for(l in i)if((p=i[l]).name===n.name){if(p.state===v)return Object(c.timeout)(o);p.state===y?(p.state=x,p.timer.stop(),p.on.call("interrupt",t,t.__data__,p.index,p.group),delete i[l]):+l<e&&(p.state=x,p.timer.stop(),delete i[l])}if(Object(c.timeout)(function(){n.state===v&&(n.state=y,n.timer.restart(a,n.delay,n.time),a(u))}),n.state=g,n.on.call("start",t,t.__data__,n.index,n.group),n.state===g){for(n.state=v,r=new Array(f=n.tween.length),l=0,h=-1;l<f;++l)(p=n.tween[l].value.call(t,t.__data__,n.index,n.group))&&(r[++h]=p);r.length=h+1}}function a(e){for(var i=e<n.duration?n.ease.call(null,e/n.duration):(n.timer.restart(s),n.state=m,1),o=-1,a=r.length;++o<a;)r[o].call(null,i);n.state===m&&(n.on.call("end",t,t.__data__,n.index,n.group),s())}function s(){for(var r in n.state=x,n.timer.stop(),delete i[e],i)return;delete t.__transition}i[e]=n,n.timer=Object(c.timer)(function(t){n.state=d,n.timer.restart(o,n.delay,n.time),n.delay<=t&&o(t-n.delay)},0,n.time)}(t,n,{name:e,index:r,group:i,on:h,tween:f,time:o.time,delay:o.delay,duration:o.duration,ease:o.ease,timer:null,state:p})};function _(t,e){var n=S(t,e);if(n.state>p)throw new Error("too late; already scheduled");return n}function w(t,e){var n=S(t,e);if(n.state>g)throw new Error("too late; already started");return n}function S(t,e){var n=t.__transition;if(!n||!(n=n[e]))throw new Error("transition not found");return n}var M=function(t,e){var n,r,i,o=t.__transition,a=!0;if(o){for(i in e=null==e?null:e+"",o)(n=o[i]).name===e?(r=n.state>g&&n.state<m,n.state=x,n.timer.stop(),r&&n.on.call("interrupt",t,t.__data__,n.index,n.group),delete o[i]):a=!1;a&&delete t.__transition}},C=n(589);function P(t,e,n){var r=t._id;return t.each(function(){var t=w(this,r);(t.value||(t.value={}))[e]=n.apply(this,arguments)}),function(t){return S(t,r).value[e]}}var A=n(567),I=function(t,e){var n;return("number"==typeof e?C.interpolateNumber:e instanceof A.a?C.interpolateRgb:(n=Object(A.a)(e))?(e=n,C.interpolateRgb):C.interpolateString)(t,e)};var O=r.selection.prototype.constructor;var E=0;function T(t,e,n,r){this._groups=t,this._parents=e,this._name=n,this._id=r}function k(t){return Object(r.selection)().transition(t)}function j(){return++E}var L=r.selection.prototype;T.prototype=k.prototype={constructor:T,select:function(t){var e=this._name,n=this._id;"function"!=typeof t&&(t=Object(r.selector)(t));for(var i=this._groups,o=i.length,a=new Array(o),s=0;s<o;++s)for(var u,l,c=i[s],h=c.length,f=a[s]=new Array(h),p=0;p<h;++p)(u=c[p])&&(l=t.call(u,u.__data__,p,c))&&("__data__"in u&&(l.__data__=u.__data__),f[p]=l,b(f[p],e,n,p,f,S(u,n)));return new T(a,this._parents,e,n)},selectAll:function(t){var e=this._name,n=this._id;"function"!=typeof t&&(t=Object(r.selectorAll)(t));for(var i=this._groups,o=i.length,a=[],s=[],u=0;u<o;++u)for(var l,c=i[u],h=c.length,f=0;f<h;++f)if(l=c[f]){for(var p,d=t.call(l,l.__data__,f,c),g=S(l,n),v=0,y=d.length;v<y;++v)(p=d[v])&&b(p,e,n,v,d,g);a.push(d),s.push(l)}return new T(a,s,e,n)},filter:function(t){"function"!=typeof t&&(t=Object(r.matcher)(t));for(var e=this._groups,n=e.length,i=new Array(n),o=0;o<n;++o)for(var a,s=e[o],u=s.length,l=i[o]=[],c=0;c<u;++c)(a=s[c])&&t.call(a,a.__data__,c,s)&&l.push(a);return new T(i,this._parents,this._name,this._id)},merge:function(t){if(t._id!==this._id)throw new Error;for(var e=this._groups,n=t._groups,r=e.length,i=n.length,o=Math.min(r,i),a=new Array(r),s=0;s<o;++s)for(var u,l=e[s],c=n[s],h=l.length,f=a[s]=new Array(h),p=0;p<h;++p)(u=l[p]||c[p])&&(f[p]=u);for(;s<r;++s)a[s]=e[s];return new T(a,this._parents,this._name,this._id)},selection:function(){return new O(this._groups,this._parents)},transition:function(){for(var t=this._name,e=this._id,n=j(),r=this._groups,i=r.length,o=0;o<i;++o)for(var a,s=r[o],u=s.length,l=0;l<u;++l)if(a=s[l]){var c=S(a,e);b(a,t,n,l,s,{time:c.time+c.delay+c.duration,delay:0,duration:c.duration,ease:c.ease})}return new T(r,this._parents,t,n)},call:L.call,nodes:L.nodes,node:L.node,size:L.size,empty:L.empty,each:L.each,on:function(t,e){var n=this._id;return arguments.length<2?S(this.node(),n).on.on(t):this.each(function(t,e,n){var r,i,o=function(t){return(t+"").trim().split(/^|\s+/).every(function(t){var e=t.indexOf(".");return e>=0&&(t=t.slice(0,e)),!t||"start"===t})}(e)?_:w;return function(){var a=o(this,t),s=a.on;s!==r&&(i=(r=s).copy()).on(e,n),a.on=i}}(n,t,e))},attr:function(t,e){var n=Object(r.namespace)(t),i="transform"===n?C.interpolateTransformSvg:I;return this.attrTween(t,"function"==typeof e?(n.local?function(t,e,n){var r,i,o;return function(){var a,s=n(this);if(null!=s)return(a=this.getAttributeNS(t.space,t.local))===s?null:a===r&&s===i?o:o=e(r=a,i=s);this.removeAttributeNS(t.space,t.local)}}:function(t,e,n){var r,i,o;return function(){var a,s=n(this);if(null!=s)return(a=this.getAttribute(t))===s?null:a===r&&s===i?o:o=e(r=a,i=s);this.removeAttribute(t)}})(n,i,P(this,"attr."+t,e)):null==e?(n.local?function(t){return function(){this.removeAttributeNS(t.space,t.local)}}:function(t){return function(){this.removeAttribute(t)}})(n):(n.local?function(t,e,n){var r,i;return function(){var o=this.getAttributeNS(t.space,t.local);return o===n?null:o===r?i:i=e(r=o,n)}}:function(t,e,n){var r,i;return function(){var o=this.getAttribute(t);return o===n?null:o===r?i:i=e(r=o,n)}})(n,i,e+""))},attrTween:function(t,e){var n="attr."+t;if(arguments.length<2)return(n=this.tween(n))&&n._value;if(null==e)return this.tween(n,null);if("function"!=typeof e)throw new Error;var i=Object(r.namespace)(t);return this.tween(n,(i.local?function(t,e){function n(){var n=this,r=e.apply(n,arguments);return r&&function(e){n.setAttributeNS(t.space,t.local,r(e))}}return n._value=e,n}:function(t,e){function n(){var n=this,r=e.apply(n,arguments);return r&&function(e){n.setAttribute(t,r(e))}}return n._value=e,n})(i,e))},style:function(t,e,n){var i="transform"==(t+="")?C.interpolateTransformCss:I;return null==e?this.styleTween(t,function(t,e){var n,i,o;return function(){var a=Object(r.style)(this,t),s=(this.style.removeProperty(t),Object(r.style)(this,t));return a===s?null:a===n&&s===i?o:o=e(n=a,i=s)}}(t,i)).on("end.style."+t,function(t){return function(){this.style.removeProperty(t)}}(t)):this.styleTween(t,"function"==typeof e?function(t,e,n){var i,o,a;return function(){var s=Object(r.style)(this,t),u=n(this);return null==u&&(this.style.removeProperty(t),u=Object(r.style)(this,t)),s===u?null:s===i&&u===o?a:a=e(i=s,o=u)}}(t,i,P(this,"style."+t,e)):function(t,e,n){var i,o;return function(){var a=Object(r.style)(this,t);return a===n?null:a===i?o:o=e(i=a,n)}}(t,i,e+""),n)},styleTween:function(t,e,n){var r="style."+(t+="");if(arguments.length<2)return(r=this.tween(r))&&r._value;if(null==e)return this.tween(r,null);if("function"!=typeof e)throw new Error;return this.tween(r,function(t,e,n){function r(){var r=this,i=e.apply(r,arguments);return i&&function(e){r.style.setProperty(t,i(e),n)}}return r._value=e,r}(t,e,null==n?"":n))},text:function(t){return this.tween("text","function"==typeof t?function(t){return function(){var e=t(this);this.textContent=null==e?"":e}}(P(this,"text",t)):function(t){return function(){this.textContent=t}}(null==t?"":t+""))},remove:function(){return this.on("end.remove",(t=this._id,function(){var e=this.parentNode;for(var n in this.__transition)if(+n!==t)return;e&&e.removeChild(this)}));var t},tween:function(t,e){var n=this._id;if(t+="",arguments.length<2){for(var r,i=S(this.node(),n).tween,o=0,a=i.length;o<a;++o)if((r=i[o]).name===t)return r.value;return null}return this.each((null==e?function(t,e){var n,r;return function(){var i=w(this,t),o=i.tween;if(o!==n)for(var a=0,s=(r=n=o).length;a<s;++a)if(r[a].name===e){(r=r.slice()).splice(a,1);break}i.tween=r}}:function(t,e,n){var r,i;if("function"!=typeof n)throw new Error;return function(){var o=w(this,t),a=o.tween;if(a!==r){i=(r=a).slice();for(var s={name:e,value:n},u=0,l=i.length;u<l;++u)if(i[u].name===e){i[u]=s;break}u===l&&i.push(s)}o.tween=i}})(n,t,e))},delay:function(t){var e=this._id;return arguments.length?this.each(("function"==typeof t?function(t,e){return function(){_(this,t).delay=+e.apply(this,arguments)}}:function(t,e){return e=+e,function(){_(this,t).delay=e}})(e,t)):S(this.node(),e).delay},duration:function(t){var e=this._id;return arguments.length?this.each(("function"==typeof t?function(t,e){return function(){w(this,t).duration=+e.apply(this,arguments)}}:function(t,e){return e=+e,function(){w(this,t).duration=e}})(e,t)):S(this.node(),e).duration},ease:function(t){var e=this._id;return arguments.length?this.each(function(t,e){if("function"!=typeof e)throw new Error;return function(){w(this,t).ease=e}}(e,t)):S(this.node(),e).ease}};var D={time:null,delay:0,duration:250,ease:n(638).easeCubicInOut};function F(t,e){for(var n;!(n=t.__transition)||!(n=n[e]);)if(!(t=t.parentNode))return D.time=Object(c.now)(),D;return n}r.selection.prototype.interrupt=function(t){return this.each(function(){M(this,t)})},r.selection.prototype.transition=function(t){var e,n;t instanceof T?(e=t._id,t=t._name):(e=j(),(n=D).time=Object(c.now)(),t=null==t?null:t+"");for(var r=this._groups,i=r.length,o=0;o<i;++o)for(var a,s=r[o],u=s.length,l=0;l<u;++l)(a=s[l])&&b(a,t,e,l,s,n||F(a,e));return new T(r,this._parents,t,e)};var R=[null],B=function(t,e){var n,r,i=t.__transition;if(i)for(r in e=null==e?null:e+"",i)if((n=i[r]).state>d&&n.name===e)return new T([[t]],R,e,+r);return null};n.d(e,"transition",function(){return k}),n.d(e,"active",function(){return B}),n.d(e,"interrupt",function(){return M})},,,,,,,,,,,,,function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r,i=n(564),o=(r=i)&&r.__esModule?r:{default:r};e.default=o.default.generateBaseTypedComponent("Facet")},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),i=s(n(11)),o=s(n(564)),a=s(n(0));function s(t){return t&&t.__esModule?t:{default:t}}var u=function(t){function e(t){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,"Label"))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,o.default),r(e,[{key:"componentWillMount",value:function(){var t=this.context.getParentInfo();(0,i.default)("Geom"===t.name,"`<Label />` must be wrapped in `<Geom />`"),this.id=this.context.createId(),this.context.addElement(this.name,this.id,this.props,this.context.getParentInfo(),this.context.getViewId())}}]),e}();u.contextTypes={addElement:a.default.func,updateElement:a.default.func,deleteElement:a.default.func,createId:a.default.func,getParentInfo:a.default.func,getViewId:a.default.func},u.childContextTypes={addElement:a.default.func,updateElement:a.default.func,deleteElement:a.default.func,createId:a.default.func,getParentInfo:a.default.func,getViewId:a.default.func},e.default=u},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r,i=n(564),o=(r=i)&&r.__esModule?r:{default:r};var a=o.default.generateBaseTypedComponent("Guide");a.Line=o.default.generateBaseTypedComponent("GuideLine"),a.Image=o.default.generateBaseTypedComponent("GuideImage"),a.Text=o.default.generateBaseTypedComponent("GuideText"),a.Region=o.default.generateBaseTypedComponent("GuideRegion"),a.Html=o.default.generateBaseTypedComponent("GuideHtml"),a.Arc=o.default.generateBaseTypedComponent("GuideArc"),e.default=a},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),i=a(n(564)),o=a(n(0));function a(t){return t&&t.__esModule?t:{default:t}}var s=function(t){function e(t){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);var n=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,"View"));return n.getViewId=function(){return n.id},n}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,i.default),r(e,[{key:"getChildContext",value:function(){return{addElement:this.context.addElement,updateElement:this.context.updateElement,deleteElement:this.context.deleteElement,createId:this.context.createId,getParentInfo:this.getParentInfo,getViewId:this.getViewId}}}]),e}();s.contextTypes={addElement:o.default.func,updateElement:o.default.func,deleteElement:o.default.func,createId:o.default.func,getParentInfo:o.default.func,getViewId:o.default.func},s.childContextTypes={addElement:o.default.func,updateElement:o.default.func,deleteElement:o.default.func,createId:o.default.func,getParentInfo:o.default.func,getViewId:o.default.func},e.default=s},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r,i=n(564),o=(r=i)&&r.__esModule?r:{default:r};e.default=o.default.generateBaseTypedComponent("Geom")},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r,i=n(564),o=(r=i)&&r.__esModule?r:{default:r};e.default=o.default.generateBaseTypedComponent("Tooltip")},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=o(n(564)),i=o(n(0));function o(t){return t&&t.__esModule?t:{default:t}}var a=function(t){function e(t){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t,"Legend"))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,r.default),e}();a.contextTypes={addElement:i.default.func,updateElement:i.default.func,deleteElement:i.default.func,createId:i.default.func,getParentInfo:i.default.func,getViewId:i.default.func},a.childContextTypes={addElement:i.default.func,updateElement:i.default.func,deleteElement:i.default.func,createId:i.default.func,getParentInfo:i.default.func,getViewId:i.default.func},a.defaultProps={visible:!0},e.default=a},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r,i=n(564),o=(r=i)&&r.__esModule?r:{default:r};e.default=o.default.generateBaseTypedComponent("Axis")},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r,i=n(564),o=(r=i)&&r.__esModule?r:{default:r};e.default=o.default.generateBaseTypedComponent("Coord")},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),i=a(n(1)),o=a(n(0));function a(t){return t&&t.__esModule?t:{default:t}}(0,a(n(9)).default)(i.default.PureComponent,"`React.PureComponent` needs React >=15.3.0");var s=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,(e.__proto__||Object.getPrototypeOf(e)).apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,i.default.PureComponent||i.default.Component),r(e,[{key:"render",value:function(){var t=this.props,e=t.width,n=t.height,r=t.placeholder;return i.default.createElement("div",{style:{width:e,height:n}},r)}}]),e}();s.propTypes={width:o.default.oneOfType([o.default.string,o.default.number]),height:o.default.oneOfType([o.default.string,o.default.number]),placeholder:o.default.node},s.defaultProps={width:"100%",placeholder:i.default.createElement("div",{style:{position:"relative",top:"48%",textAlign:"center"}},"暂无数据")},e.default=s},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r={Chart:"deleteChart",Coord:"deleteCoord",Geom:"deleteGeom",Axis:"deleteAxis",Tooltip:"deleteTooltip",Legend:"deleteLegend",Label:"deleteLabel",View:"deleteView",Guide:"deleteGuide",GuideLine:"deleteTypedGuide",GuideImage:"deleteTypedGuide",GuideText:"deleteTypedGuide",GuideRegion:"deleteTypedGuide",GuideHtml:"deleteTypedGuide",GuideArc:"deleteTypedGuide",Facet:"deleteFacet"},i={Geom:!0,Label:!0,Facet:!0},o={deleteAxis:function(t,e,n){var r=e.axises[n].props;t.axis(r.name,!1)},deleteTooltip:function(t){t.tooltip(!1)},deleteCoord:function(t){t.coord("rect",{})},deleteLegend:function(t,e,n){var r=e.legends[n].props;t.legend.apply(t,function(t){if(Array.isArray(t)){for(var e=0,n=Array(t.length);e<t.length;e++)n[e]=t[e];return n}return Array.from(t)}(r.name?[r.name,!1]:[!1]))},deleteGuide:function(t){t.guide().clear()},deleteView:function(t,e,n){e.views[n].g2Instance&&(t.removeView(e.views[n].g2Instance),delete e.views[n].g2Instance)},deleteViewElement:function(t,e,n,o){var a=this;Object.keys(n).forEach(function(t){var n=o[t],s=n.viewId;s&&(i[n.name]?e.views[s].needReExecute=!0:e.views[s].g2Instance&&a[r[n.name]]&&a[r[n.name]](e.views[s].g2Instance,e.views[s],n.id))})},needReExecute:function(t,e){for(var n in t)if(i[e[n].name]&&!e[n].viewId)return!0;return!1},synchronizeG2Delete:function(t,e,n,i){var o=this;Object.keys(n).forEach(function(n){var a=r[i[n].name];o[a]&&!i[n].viewId&&o[a](t,e,n)}),this.deleteViewElement(t,e,n,i)}};e.default=o},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r,i=n(581),o=(r=i)&&r.__esModule?r:{default:r};e.default={init:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=arguments[1],n=arguments[2];o.default.each(t,function(t){var r=e[t];void 0!==r&&(o.default.isArray(r)||(r=[r]),n(r,t))})},update:function(t,e,n,r){var i=void 0,a=void 0;o.default.each(t,function(t){i=e[t],a=n[t],o.default.shallowEqual(a,i)||(o.default.isArray(a)||(a=[a]),r(a,t))})}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},i=c(n(9)),o=n(613),a=c(n(646)),s=c(n(645)),u=c(n(614)),l=c(n(644));function c(t){return t&&t.__esModule?t:{default:t}}function h(t){if(Array.isArray(t)){for(var e=0,n=Array(t.length);e<t.length;e++)n[e]=t[e];return n}return Array.from(t)}function f(t,e){var n={};for(var r in t)e.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(t,r)&&(n[r]=t[r]);return n}var p=a.default.COORD_FUNC_PROPS,d=a.default.GEOM_FUNC_PROPS,g={needRebuildChart:function(t){if(null==t.chart.props||null==t.chart.updateProps)return!1;var e=t.chart.props,n=t.chart.updateProps;return!(o.Util.shallowEqual(e.padding,n.padding)&&o.Util.shallowEqual(e.background,n.background)&&o.Util.shallowEqual(e.plotBackground,n.plotBackground)&&o.Util.shallowEqual(e.pixelRatio,n.pixelRatio))},needReExecute:function(t){var e=t.geoms;if(null==e)return!1;for(var n in e)if(e[n].props&&e[n].updateProps&&(e[n].props.type!==e[n].updateProps.type||e[n].props.color&&!e[n].updateProps.color||e[n].props.size&&!e[n].updateProps.size||e[n].props.shape&&!e[n].updateProps.shape))return!0;return!1},synchronizeG2Update:function(t,e){this.updateChart(t,e.chart),this.updateAxises(t,e.axises),this.updateTooltip(t,e),this.updateCoord(t,e),this.updateLegends(t,e.legends),this.updateGeoms(t,e.geoms),this.updateGuide(t,e.guide),this.updateFacet(t,e),this.updateViews(t,e)},updateChart:function(t,e){if(e){var n=e.props,r=e.updateProps,i=n.width,a=n.height,s=n.animate,u=n.data,c=n.scale,h=r.width,f=r.height,p=r.animate,d=r.data,g=r.scale;u!==d&&t.changeData(d),o.Util.shallowEqual(c,g)||(o.Util.isArray(g)?t.scale(g[0],g[1]):t.scale(g)),s!==p&&t.animate(p),i!==h&&a!==f?t.changeSize(h,f):i!==h?t.changeWidth(h):a!==f&&t.changeHeight(f),l.default.updateEvents(t,l.default.chartEvents,e.props,r),l.default.updateBaseEvents(t,e.updateProps,r)}},updateAxis:function(t,e){var n=e.props,r=n.name,a=n.visible,s=f(n,["name","visible"]),u=e.updateProps,l=u.name,c=u.visible,h=f(u,["name","visible"]);(0,i.default)(r===l,"`name` propertry should not be changed in `<Axis />`"),a===c||c?o.Util.shallowEqual(s,h)||t.axis(r,h):t.axis(r,!1)},updateAxises:function(t,e){if(e)for(var n in e)e[n]&&e[n].props&&e[n].updateProps&&this.updateAxis(t,e[n])},updateTooltip:function(t,e){if(e.tooltip){var n=e.tooltip.props,i=e.tooltip.updateProps;null==n&&null==i||o.Util.shallowEqual(n,i)||t.tooltip(r({},i))}},updateCoord:function(t,e){var n=e.coord;if(n){var r=n.props,i=n.updateProps;if(null!=r&&null!=i){var a=o.Util.without(i,p.concat(["type"]));if(!o.Util.shallowEqual(r,i)){var s=t.coord(i.type,a);n.g2Instance=s,o.Prop.init(p,i,function(t,e){s[e].apply(s,h(t))})}}}},updateLegend:function(t,e){var n=e.props,r=e.updateProps;if(r&&!o.Util.shallowEqual(n,r)){var i=r.name,a=r.visible,s=f(r,["name","visible"]),u=a?s:a;t.legend.apply(t,h(i?[i,u]:[u]))}},updateLegends:function(t,e){if(null!=e)for(var n in e)e[n]&&this.updateLegend(t,e[n])},updateLabel:function(t,e,n){if(null!=e&&null!=n){var r=e.content,i=f(e,["content"]),a=n.content,s=f(n,["content"]);o.Util.shallowEqual(i,s)&&o.Util.shallowEqual(r,a)||(o.Util.isArray(a)?t.label(a[0],a[1],s):t.label(a,s))}},updateGeom:function(t,e){var n=e.props,r=e.updateProps;if(n&&r&&n.type===r.type){var i=e.g2Instance;if(o.Util.shallowEqual(n,r))e.label&&this.updateLabel(i,e.label.props,e.label.updateProps);else{var a=n.adjust,s=f(n,["adjust"]),u=r.adjust,l=f(r,["adjust"]);(a||u)&&i.adjust(u),o.Prop.update(d,s,l,function(t,e){i[e].apply(i,h(t))}),e.label&&this.updateLabel(i,e.label.props,e.label.updateProps)}}},updateGeoms:function(t,e){if(null==e)return!1;for(var n in e)e[n]&&this.updateGeom(t,e[n]);return!1},isTypedGuideChanged:function(t){return!o.Util.shallowEqual(t.props,t.updateProps)},updateGuide:function(t,e){if(e&&e.elements){var n=e.elements,r=!1;for(var i in n)if(n[i]&&(n[i].updateProps||this.isTypedGuideChanged(n[i]))){r=!0;break}r&&(u.default.mergeGuide(e,!0),t.guide().clear(),s.default.guide(t,e))}},updateView:function(t,e){if(e&&e.props&&e.updateProps&&"Facet"!==e.parentInfo.name){var n=e.g2Instance,r=e.props,i=e.updateProps,a=r.scale,s=r.data,u=r.animate,l=r.axis,c=r.filter,h=i.scale,f=i.animate,p=i.data,d=i.axis,g=i.filter;u!==f&&n.animate(f),s!==p&&n.changeData(p),o.Util.shallowEqual(a,h)||n.scale(h),o.Util.shallowEqual(c,g)||g.forEach(function(t){n.filter(t[0],t[1])}),l!==d&&n.axis(d),this.updateCoord(n,e),this.updateAxises(n,e.axises),this.updateGeoms(n,e.geoms),this.updateGuide(n,e.guide)}},updateViews:function(t,e){var n=e.views;if(n)for(var r in n){var i=n[r];i&&(i.needReExecute||this.needReExecute(i))?(s.default.synchronizeG2View(i.g2Instance,i),n[r].needReExecute=!1):this.updateView(t,i)}},updateFacet:function(t,e){var n=e.facet;if(n){var r=n.props,i=n.updateProps;if(null!=r&&null!=i){var a=r.type,u=f(r,["type"]),l=i.type,c=f(i,["type"]);a===l&&o.Util.shallowEqual(u,c)||(n.props=i,s.default.facet(t,e))}}}};e.default=g},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r={Chart:"addChart",Coord:"addCoord",Geom:"addGeom",Axis:"addAxis",Tooltip:"addTooltip",Legend:"addLegend",Label:"addLabel",View:"addView",Guide:"addGuide",GuideLine:"addGuideLine",GuideImage:"addGuideImage",GuideText:"addGuideText",GuideRegion:"addGuideRegion",GuideHtml:"addGuideHtml",GuideArc:"addGuideArc",Facet:"addFacet"},i={addElement:function(t,e,n){this[r[t]](e,n,n.id,n.viewId,n.parentInfo)},getConfigContainer:function(t,e){return e&&(t.views||(t.views={}),(t=t.views[e])||((t={}).views[e]=t)),t},addUniqueElement:function(t,e,n,r,i){var o=this.getConfigContainer(t,i);return o[e],o[e]=n,r},addChart:function(t,e,n){return this.addUniqueElement(t,"chart",e,n,null)},addView:function(t,e,n){return t.views||(t.views={}),t.views[n]=e,n},addAxis:function(t,e,n,r){var i=this.getConfigContainer(t,r);return i.axises||(i.axises={}),i.axises[n]=e,n},addCoord:function(t,e,n,r){return this.addUniqueElement(t,"coord",e,n,r)},addGeom:function(t,e,n,r,i){var o=this.getConfigContainer(t,r);return o.geoms||(o.geoms={}),o.geoms[n]?i?o.geoms[n].label=e.label:(o.geoms[n].label||console.log("geom label error"),e.label=o.geoms[n].label,o.geoms[n]=e):o.geoms[n]=e,n},addLabel:function(t,e,n,r,i){var o=this.getConfigContainer(t,r);return o.geoms||(o.geoms={}),this.addGeom(t,{label:e},i.id,r,!0),n},addTooltip:function(t,e,n,r){return this.addUniqueElement(t,"tooltip",e,n,r)},addFacet:function(t,e,n,r){return this.addUniqueElement(t,"facet",e,n,r)},addLegend:function(t,e,n,r){var i=this.getConfigContainer(t,r);return i.legends||(i.legends={}),i.legends[n]=e,n},addGuide:function(t,e,n,r){return this.addUniqueElement(t,"guide",e,n,r)},addTypedGuide:function(t,e,n,r,i,o){var a=this.getConfigContainer(t,i),s=a.guide;return s||(this.addUniqueElement("guide",{},o.id,i),s=a.guide),s.elements||(s.elements={}),n.type=e,s.elements[r]=n,r},addGuideLine:function(t,e,n,r,i){this.addTypedGuide(t,"line",e,n,r,i)},addGuideImage:function(t,e,n,r,i){this.addTypedGuide(t,"image",e,n,r,i)},addGuideText:function(t,e,n,r,i){this.addTypedGuide(t,"text",e,n,r,i)},addGuideRegion:function(t,e,n,r,i){this.addTypedGuide(t,"region",e,n,r,i)},addGuideHtml:function(t,e,n,r,i){this.addTypedGuide(t,"html",e,n,r,i)},addGuideArc:function(t,e,n,r,i){this.addTypedGuide(t,"arc",e,n,r,i)}};e.default=i},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},i=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),o=h(n(759)),a=h(n(614)),s=h(n(758)),u=h(n(756)),l=h(n(645)),c=n(613);function h(t){return t&&t.__esModule?t:{default:t}}function f(t,e){var n={};for(var r in t)e.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(t,r)&&(n[r]=t[r]);return n}var p=function(){function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.config={},this.elementInfos={},this.added=!1,this.initedG2=!1,this.updated=!1,this.deleted=!1,this.deleteInfos={}}return i(t,[{key:"calUpdateFlag",value:function(t,e){var n=this.elementInfos[e].props,r=(n.children,f(n,["children"])),i=this.elementInfos[e].updateProps,o=(i.children,f(i,["children"]));if("Chart"===t){var a=r.data,s=f(r,["data"]),u=o.data,l=f(o,["data"]);a===u&&c.Util.isEqual(s,l)||(this.updated=!0)}else c.Util.isEqual(r,o)||(this.updated=!0)}},{key:"addElement",value:function(t,e,n,i,a){!this.chart&&this.initedG2||(this.added=!0,this.elementInfos[e]={id:e,viewId:a,parentInfo:i,name:t,props:r({},n)},i&&!this.elementInfos[i.id]&&(this.elementInfos[i.id]={id:i.id,name:i.name}),o.default.addElement(t,this.config,this.elementInfos[e]))}},{key:"updateElement",value:function(t,e,n){this.elementInfos[e].updateProps=r({},n),this.calUpdateFlag(t,e)}},{key:"deleteElement",value:function(t,e){this.chart&&(this.deleteInfos[e]=e,this.deleted=!0)}},{key:"createG2Instance",value:function(){var t=this.config,e=l.default.createChart(t,this.elementInfos);return l.default.executeChartConfig(e,t,this.elementInfos),l.default.synchronizeG2Add(e,t,this.elementInfos),e.render(),this.chart=e,this.initedG2=!0,this.resetStates(),e}},{key:"destory",value:function(){this.chart.destroy(),this.chart=null}},{key:"resetStates",value:function(){var t=this.elementInfos;for(var e in t)t[e].updateProps&&delete t[e].updateProps,this.deleteInfos[e]&&delete t[e];this.added=!1,this.updated=!1,this.deleteInfos={}}},{key:"reExecuteChart",value:function(){return this.chart.clear(),a.default.merge(this.config,this.deleteInfos,this.elementInfos,!0),l.default.executeChartConfig(this.chart,this.config,this.elementInfos),l.default.synchronizeG2Add(this.chart,this.config,this.elementInfos),this.chart.repaint(),this.resetStates(),this.chart}},{key:"batchedUpdate",value:function(){return null==this.chart?null:s.default.needRebuildChart(this.config)?(a.default.merge(this.config,this.deleteInfos,this.elementInfos,!0),this.chart.destroy(),this.chart="destroy",this.createG2Instance()):u.default.needReExecute(this.deleteInfos,this.elementInfos)||s.default.needReExecute(this.config)?(this.reExecuteChart(),this.chart):(this.deleted&&(u.default.synchronizeG2Delete(this.chart,this.config,this.deleteInfos,this.elementInfos),a.default.mergeDelete(this.config,this.deleteInfos,this.elementInfos)),this.added&&l.default.synchronizeG2Add(this.chart,this.config),this.updated&&s.default.synchronizeG2Update(this.chart,this.config),(this.added||this.deleted||this.updated)&&this.chart.repaint(),a.default.mergeUpdate(this.config,!1),this.resetStates(),this.chart)}}]),t}();e.default=p},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},i=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),o=n(1),a=l(o),s=l(n(0)),u=l(n(760));function l(t){return t&&t.__esModule?t:{default:t}}var c=function(t){function e(t){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);var n=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t));return h.call(n),n.name="Chart",n.gId=0,n.id=n.createId(),n.g2Processor=new u.default,n}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,o.Component),i(e,[{key:"getChildContext",value:function(){return{addElement:this.addElement,updateElement:this.updateElement,deleteElement:this.deleteElement,createId:this.createId,getParentInfo:this.getParentInfo,getViewId:this.getViewId}}},{key:"componentDidMount",value:function(){this.addElement(this.name,this.id,r({},this.props,{container:this.containerWrap})),this.chart=this.g2Processor.createG2Instance(),this.notifyG2Instance()}},{key:"componentDidUpdate",value:function(){this.updateElement(this.name,this.id,r({},this.props,{container:this.containerWrap}));var t=this.g2Processor.batchedUpdate();this.chart!==t&&(this.chart=t,this.notifyG2Instance())}},{key:"componentWillUnmount",value:function(){this.g2Processor.destory(),this.chart=null,this.containerWrap=null}},{key:"getG2Instance",value:function(){return this.chart}},{key:"notifyG2Instance",value:function(){this.props.onGetG2Instance&&this.props.onGetG2Instance(this.chart)}},{key:"render",value:function(){return a.default.createElement("div",{ref:this.refHandle},this.props.children)}}]),e}();c.propTypes={data:s.default.oneOfType([s.default.arrayOf(s.default.object),s.default.object]),scale:s.default.oneOfType([s.default.object,s.default.array]),animate:s.default.bool,width:s.default.number,height:s.default.number.isRequired,onGetG2Instance:s.default.func},c.childContextTypes={addElement:s.default.func,updateElement:s.default.func,deleteElement:s.default.func,createId:s.default.func,getParentInfo:s.default.func,getViewId:s.default.func};var h=function(){var t=this;this.getViewId=function(){},this.getParentInfo=function(){return{id:t.id,name:t.name}},this.createId=function(){return t.gId+=1,t.gId},this.addElement=function(e,n,r,i,o){return t.g2Processor.addElement(e,n,r,i,o)},this.updateElement=function(e,n,r,i,o){t.g2Processor.updateElement(e,n,r,i,o)},this.deleteElement=function(e,n,r){t.g2Processor.deleteElement(e,n,r)},this.refHandle=function(e){t.containerWrap||(t.containerWrap=e)}};e.default=c},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},i=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),o=u(n(1)),a=(u(n(581)),u(n(761))),s=u(n(755));u(n(0));function u(t){return t&&t.__esModule?t:{default:t}}function l(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function c(t){var e=!0;return null==t&&(e=!1),!!e}var h=function(t){function e(){var t,n,r;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);for(var i=arguments.length,a=Array(i),s=0;s<i;s++)a[s]=arguments[s];return n=r=l(this,(t=e.__proto__||Object.getPrototypeOf(e)).call.apply(t,[this].concat(a))),r._refCallback=function(t){t&&(r.chart=t.getG2Instance())},r.hasViewSource=function(){var t=!1;return o.default.Children.map(r.props.children,function(e){!t&&"function"==typeof e.type&&"View"===e.type.name&&e.props.data&&c(e.props.data)&&(t=!0)}),t},l(r,n)}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,o.default.PureComponent||o.default.Component),i(e,[{key:"getG2Instance",value:function(){return this.chart}},{key:"render",value:function(){var t=this.props,e=t.data,n=t.width,i=t.height,u=t.placeholder,l=t.className,h=t.style;return o.default.createElement("div",{className:l,style:h},c(e)||this.hasViewSource()||!u?o.default.createElement(a.default,r({ref:this._refCallback},this.props)):o.default.createElement(s.default,{width:n,height:i,placeholder:!0===u?void 0:u}))}}]),e}();e.default=h},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.Facet=e.Label=e.Guide=e.View=e.Geom=e.Tooltip=e.Legend=e.Axis=e.Coord=e.Chart=void 0;var r=p(n(762)),i=p(n(754)),o=p(n(753)),a=p(n(752)),s=p(n(751)),u=p(n(750)),l=p(n(749)),c=p(n(748)),h=p(n(747)),f=p(n(746));function p(t){return t&&t.__esModule?t:{default:t}}e.Chart=r.default,e.Coord=i.default,e.Axis=o.default,e.Legend=a.default,e.Tooltip=s.default,e.Geom=u.default,e.View=l.default,e.Guide=c.default,e.Label=h.default,e.Facet=f.default},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default={}},function(t,e,n){var r=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return e.type="matrix",e.showTitle=!1,e},e.prototype.generateFacets=function(t){for(var e=this.fields,n=e.length,r=n,i=[],o=0;o<r;o++)for(var a=e[o],s=0;s<n;s++){var u=e[s],l={type:this.type,colValue:a,rowValue:u,colField:a,rowField:u,colIndex:o,rowIndex:s,cols:r,rows:n,data:t,region:this.getRegion(n,r,o,s)};i.push(l)}return i},e.prototype.setXAxis=function(t,e,n){n.rowIndex!==n.rows-1&&(e[t].title=null,e[t].label=null)},e.prototype.setYAxis=function(t,e,n){0!==n.colIndex&&(e[t].title=null,e[t].label=null)},e}(n(648));t.exports=r},function(t,e,n){var r=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return e.type="mirror",this.transpose=!1,e},e.prototype.init=function(){this.transpose?(this.cols=2,this.rows=1):(this.cols=1,this.rows=2),t.prototype.init.call(this)},e.prototype.beforeProcessView=function(t,e){this.transpose?e.colIndex%2==0?t.coord().transpose().scale(-1,1):t.coord().transpose():e.rowIndex%2!=0&&t.coord().scale(1,-1)},e.prototype.renderTitle=function(t,e){this.transpose?this.drawColTitle(t,e):this.drawRowTitle(t,e)},e.prototype.setXAxis=function(t,e,n){1!==n.colIndex&&1!==n.rowIndex||(e[t].label=null,e[t].title=null)},e.prototype.setYAxis=function(){},e}(n(647));t.exports=r},function(t,e,n){var r=n(590),i=n(549).assign,o=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return e.type="tree",e.line={lineWidth:1,stroke:"#ddd"},e.lineSmooth=!1,e},e.prototype.generateFacets=function(t){if(!this.fields.length)throw"Please specify for the fields for facet!";var e=[],n=this.getRootFacet(t);return e.push(n),n.children=this.getChildFacets(t,1,e),this.setRegion(e),e},e.prototype.getRootFacet=function(t){return{type:this.type,rows:this.getRows(),rowIndex:0,colIndex:0,colValue:this.rootTitle,data:t}},e.prototype.getRows=function(){return this.fields.length+1},e.prototype.getChildFacets=function(t,e,n){var r=this,i=r.fields;if(!(i.length<e)){var o=[],a=i[e-1],s=r.getFieldValues(a,t);return s.forEach(function(i,u){var l=[{field:a,value:i,values:s}],c=r.getFilter(l),h=t.filter(c);if(h.length){var f={type:r.type,colValue:i,colField:a,colIndex:u,rows:r.getRows(),rowIndex:e,data:h,children:r.getChildFacets(h,e+1,n)};o.push(f),n.push(f)}}),o}},e.prototype.setRegion=function(t){var e=this;e.forceColIndex(t),t.forEach(function(t){t.region=e.getRegion(t.rows,t.cols,t.colIndex,t.rowIndex)})},e.prototype.forceColIndex=function(t){var e=this,n=[],r=0;t.forEach(function(t){e.isLeaf(t)&&(n.push(t),t.colIndex=r,r++)}),n.forEach(function(t){t.cols=n.length});for(var i=e.fields.length-1;i>=0;i--)for(var o=e.getFacetsByLevel(t,i),a=0;a<o.length;a++){var s=o[a];e.isLeaf(s)||(s.originColIndex=s.colIndex,s.colIndex=e.getRegionIndex(s.children),s.cols=n.length)}},e.prototype.getFacetsByLevel=function(t,e){var n=[];return t.forEach(function(t){t.rowIndex===e&&n.push(t)}),n},e.prototype.getRegion=function(t,e,n,r){var i=1/e,o=1/t,a={x:i*n,y:o*r};return{start:a,end:{x:a.x+i,y:a.y+2*o/3}}},e.prototype.getRegionIndex=function(t){var e=t[0];return(t[t.length-1].colIndex-e.colIndex)/2+e.colIndex},e.prototype.isLeaf=function(t){return!t.children||!t.children.length},e.prototype.setXAxis=function(t,e,n){n.rowIndex!==n.rows-1&&(e[t].label=null,e[t].title=null)},e.prototype.setYAxis=function(t,e,n){0!==n.originColIndex&&0!==n.colIndex&&(e[t].title=null,e[t].label=null)},e.prototype.onPaint=function(){t.prototype.onPaint.call(this),this.group.clear(),this.facets&&this.line&&this.drawLines(this.facets,this.group)},e.prototype.drawLines=function(t,e){var n=this,r=e.addGroup();t.forEach(function(t){if(!n.isLeaf(t)){var e=t.children;n._addFacetLines(t,e,r)}})},e.prototype._addFacetLines=function(t,e,n){var r=this,i=t.view.getViewRegion(),o={x:i.start.x+(i.end.x-i.start.x)/2,y:i.start.y};e.forEach(function(t){var e=t.view.getViewRegion(),i={x:e.start.x+(e.end.x-e.start.x)/2,y:e.end.y},a={x:o.x,y:o.y+(i.y-o.y)/2},s={x:i.x,y:a.y};r._drawLine([o,a,s,i],n)})},e.prototype._getPath=function(t){var e=[];return this.lineSmooth?(e.push(["M",t[0].x,t[0].y]),e.push(["C",t[1].x,t[1].y,t[2].x,t[2].y,t[3].x,t[3].y])):t.forEach(function(t,n){0===n?e.push(["M",t.x,t.y]):e.push(["L",t.x,t.y])}),e},e.prototype._drawLine=function(t,e){var n=this._getPath(t),r=this.line;e.addShape("path",{attrs:i({path:n},r)})},e}(r);t.exports=o},function(t,e,n){function r(t,e,n){return{x:t.x+e*Math.cos(n),y:t.y+e*Math.sin(n)}}var i=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return e.type="circle",e},e.prototype.getRegion=function(t,e){var n=2*Math.PI/t,i=-1*Math.PI/2+n*e,o=.5/(1+1/Math.sin(n/2)),a=r({x:.5,y:.5},.5-o,i),s=5*Math.PI/4,u=1*Math.PI/4;return{start:r(a,o,s),end:r(a,o,u)}},e.prototype.generateFacets=function(t){var e=this,n=e.fields[0];if(!n)throw"Please specify for the field for facet!";var r=e.getFieldValues(n,t),i=r.length,o=[];return r.forEach(function(a,s){var u=[{field:n,value:a,values:r}],l=e.getFilter(u),c=t.filter(l),h={type:e.type,colValue:a,colField:n,colIndex:s,cols:i,rows:1,rowIndex:0,data:c,region:e.getRegion(i,s)};o.push(h)}),o},e}(n(590));t.exports=i},function(t,e,n){var r=n(549),i=n(667),o={};o.Rect=n(648),o.List=n(647),o.Circle=n(768),o.Tree=n(767),o.Mirror=n(766),o.Matrix=n(765),i.prototype.facet=function(t,e){var n=o[r.upperFirst(t)];if(!n)throw new Error("Not support such type of facets as: "+t);var i=this.get("facets");i&&i.destroy(),e.chart=this;var a=new n(e);this.set("facets",a)},t.exports=o},function(t,e,n){var r=n(549),i=n(561),o=n(551),a=n(552).PathUtil;function s(t){var e=o.shape.venn;return r.mix({},e,{stroke:t.color,fill:t.color,fillOpacity:t.opacity},t.style)}var u=i.registerFactory("venn",{defaultShapeType:"venn",getDefaultPoints:function(t){var e=[];return r.each(t.x,function(n,r){var i=t.y[r];e.push({x:n,y:i})}),e},getActiveCfg:function(t,e){var n=e.lineWidth||1;return"hollow"===t?{lineWidth:n+1}:{fillOpacity:(e.fillOpacity||e.opacity||1)-.08}},getSelectedCfg:function(t,e){return e&&e.style?e.style:this.getActiveCfg(t,e)}});i.registerShape("venn","venn",{draw:function(t,e){var n=t.origin._origin.path,i=s(t),o=a.parsePathString(n);return e.addShape("path",{attrs:r.mix(i,{path:o})})},getMarkerCfg:function(t){return r.mix({symbol:"circle",radius:4},s(t))}}),i.registerShape("venn","hollow",{draw:function(t,e){var n=t.origin._origin.path,i=function(t){var e=o.shape.hollowVenn;return r.mix({},e,{stroke:t.color,strokeOpacity:t.opacity},t.style)}(t),s=a.parsePathString(n);return e.addShape("path",{attrs:r.mix(i,{path:s})})},getMarkerCfg:function(t){return r.mix({symbol:"circle",radius:4},s(t))}}),t.exports=u},function(t,e,n){!function(t,e,n){"use strict";var r=1e-10;function i(t,e){var n,i=function(t){for(var e=[],n=0;n<t.length;++n)for(var r=n+1;r<t.length;++r)for(var i=u(t[n],t[r]),o=0;o<i.length;++o){var a=i[o];a.parentIndex=[n,r],e.push(a)}return e}(t),s=i.filter(function(e){return function(t,e){for(var n=0;n<e.length;++n)if(a(t,e[n])>e[n].radius+r)return!1;return!0}(e,t)}),c=0,h=0,f=[];if(s.length>1){var p=l(s);for(n=0;n<s.length;++n){var d=s[n];d.angle=Math.atan2(d.x-p.x,d.y-p.y)}s.sort(function(t,e){return e.angle-t.angle});var g=s[s.length-1];for(n=0;n<s.length;++n){var v=s[n];h+=(g.x+v.x)*(v.y-g.y);for(var y={x:(v.x+g.x)/2,y:(v.y+g.y)/2},m=null,x=0;x<v.parentIndex.length;++x)if(g.parentIndex.indexOf(v.parentIndex[x])>-1){var b=t[v.parentIndex[x]],_=Math.atan2(v.x-b.x,v.y-b.y),w=Math.atan2(g.x-b.x,g.y-b.y),S=w-_;S<0&&(S+=2*Math.PI);var M=w-S/2,C=a(y,{x:b.x+b.radius*Math.sin(M),y:b.y+b.radius*Math.cos(M)});C>2*b.radius&&(C=2*b.radius),(null===m||m.width>C)&&(m={circle:b,width:C,p1:v,p2:g})}null!==m&&(f.push(m),c+=o(m.circle.radius,m.width),g=v)}}else{var P=t[0];for(n=1;n<t.length;++n)t[n].radius<P.radius&&(P=t[n]);var A=!1;for(n=0;n<t.length;++n)if(a(t[n],P)>Math.abs(P.radius-t[n].radius)){A=!0;break}A?c=h=0:(c=P.radius*P.radius*Math.PI,f.push({circle:P,p1:{x:P.x,y:P.y+P.radius},p2:{x:P.x-r,y:P.y+P.radius},width:2*P.radius}))}return h/=2,e&&(e.area=c+h,e.arcArea=c,e.polygonArea=h,e.arcs=f,e.innerPoints=s,e.intersectionPoints=i),c+h}function o(t,e){return t*t*Math.acos(1-e/t)-(t-e)*Math.sqrt(e*(2*t-e))}function a(t,e){return Math.sqrt((t.x-e.x)*(t.x-e.x)+(t.y-e.y)*(t.y-e.y))}function s(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 r=t-(n*n-e*e+t*t)/(2*n),i=e-(n*n-t*t+e*e)/(2*n);return o(t,r)+o(e,i)}function u(t,e){var n=a(t,e),r=t.radius,i=e.radius;if(n>=r+i||n<=Math.abs(r-i))return[];var o=(r*r-i*i+n*n)/(2*n),s=Math.sqrt(r*r-o*o),u=t.x+o*(e.x-t.x)/n,l=t.y+o*(e.y-t.y)/n,c=-(e.y-t.y)*(s/n),h=-(e.x-t.x)*(s/n);return[{x:u+c,y:l-h},{x:u-c,y:l+h}]}function l(t){for(var e={x:0,y:0},n=0;n<t.length;++n)e.x+=t[n].x,e.y+=t[n].y;return e.x/=t.length,e.y/=t.length,e}function c(t){for(var e=new Array(t),n=0;n<t;++n)e[n]=0;return e}function h(t,e){return c(t).map(function(){return c(e)})}function f(t,e){for(var n=0,r=0;r<t.length;++r)n+=t[r]*e[r];return n}function p(t){return Math.sqrt(f(t,t))}function d(t,e,n){for(var r=0;r<e.length;++r)t[r]=e[r]*n}function g(t,e,n,r,i){for(var o=0;o<t.length;++o)t[o]=e*n[o]+r*i[o]}function v(t,e,n){var r,i=(n=n||{}).maxIterations||200*e.length,o=n.nonZeroDelta||1.05,a=n.zeroDelta||.001,s=n.minErrorDelta||1e-6,u=n.minErrorDelta||1e-5,l=void 0!==n.rho?n.rho:1,c=void 0!==n.chi?n.chi:2,h=void 0!==n.psi?n.psi:-.5,f=void 0!==n.sigma?n.sigma:.5,p=e.length,d=new Array(p+1);d[0]=e,d[0].fx=t(e),d[0].id=0;for(var v=0;v<p;++v){var y=e.slice();y[v]=y[v]?y[v]*o:a,d[v+1]=y,d[v+1].fx=t(y),d[v+1].id=v+1}function m(t){for(var e=0;e<t.length;e++)d[p][e]=t[e];d[p].fx=t.fx}for(var x=function(t,e){return t.fx-e.fx},b=e.slice(),_=e.slice(),w=e.slice(),S=e.slice(),M=0;M<i;++M){if(d.sort(x),n.history){var C=d.map(function(t){var e=t.slice();return e.fx=t.fx,e.id=t.id,e});C.sort(function(t,e){return t.id-e.id}),n.history.push({x:d[0].slice(),fx:d[0].fx,simplex:C})}for(r=0,v=0;v<p;++v)r=Math.max(r,Math.abs(d[0][v]-d[1][v]));if(Math.abs(d[0].fx-d[p].fx)<s&&r<u)break;for(v=0;v<p;++v){b[v]=0;for(var P=0;P<p;++P)b[v]+=d[P][v];b[v]/=p}var A=d[p];if(g(_,1+l,b,-l,A),_.fx=t(_),_.fx<d[0].fx)g(S,1+c,b,-c,A),S.fx=t(S),S.fx<_.fx?m(S):m(_);else if(_.fx>=d[p-1].fx){var I=!1;if(_.fx>A.fx?(g(w,1+h,b,-h,A),w.fx=t(w),w.fx<A.fx?m(w):I=!0):(g(w,1-h*l,b,h*l,A),w.fx=t(w),w.fx<_.fx?m(w):I=!0),I){if(f>=1)break;for(v=1;v<d.length;++v)g(d[v],1-f,d[0],f,d[v]),d[v].fx=t(d[v])}}else m(_)}return d.sort(x),{fx:d[0].fx,x:d[0]}}function y(t,e,n,r,i,o,a){var s=n.fx,u=f(n.fxprime,e),l=s,c=s,h=u,p=0;function d(c,p,d){for(var v=0;v<16;++v)if(i=(c+p)/2,g(r.x,1,n.x,i,e),l=r.fx=t(r.x,r.fxprime),h=f(r.fxprime,e),l>s+o*i*u||l>=d)p=i;else{if(Math.abs(h)<=-a*u)return i;h*(p-c)>=0&&(p=c),c=i,d=l}return 0}i=i||1,o=o||1e-6,a=a||.1;for(var v=0;v<10;++v){if(g(r.x,1,n.x,i,e),l=r.fx=t(r.x,r.fxprime),h=f(r.fxprime,e),l>s+o*i*u||v&&l>=c)return d(p,i,c);if(Math.abs(h)<=-a*u)return i;if(h>=0)return d(i,p,l);c=l,p=i,i*=2}return i}function m(t,e,n){var r,i,o,a={x:e.slice(),fx:0,fxprime:e.slice()},s={x:e.slice(),fx:0,fxprime:e.slice()},u=e.slice(),l=1;o=(n=n||{}).maxIterations||20*e.length,a.fx=t(a.x,a.fxprime),d(r=a.fxprime.slice(),a.fxprime,-1);for(var c=0;c<o;++c){if(l=y(t,r,a,s,l),n.history&&n.history.push({x:a.x.slice(),fx:a.fx,fxprime:a.fxprime.slice(),alpha:l}),l){g(u,1,s.fxprime,-1,a.fxprime);var h=f(a.fxprime,a.fxprime),v=Math.max(0,f(u,s.fxprime)/h);g(r,v,r,-1,s.fxprime),i=a,a=s,s=i}else d(r,a.fxprime,-1);if(p(a.fxprime)<=1e-5)break}return n.history&&n.history.push({x:a.x.slice(),fx:a.fx,fxprime:a.fxprime.slice(),alpha:l}),a}function x(t,e){(e=e||{}).maxIterations=e.maxIterations||500;var n=e.initialLayout||w,r=e.lossFunction||M;t=function(t){t=t.slice();var e,n,r,i,o=[],a={};for(e=0;e<t.length;++e){var s=t[e];1==s.sets.length?o.push(s.sets[0]):2==s.sets.length&&(r=s.sets[0],i=s.sets[1],a[[r,i]]=!0,a[[i,r]]=!0)}for(o.sort(function(t,e){return t>e}),e=0;e<o.length;++e)for(r=o[e],n=e+1;n<o.length;++n)i=o[n],[r,i]in a||t.push({sets:[r,i],size:0});return t}(t);var i,o=n(t,e),a=[],s=[];for(i in o)o.hasOwnProperty(i)&&(a.push(o[i].x),a.push(o[i].y),s.push(i));for(var u=v(function(e){for(var n={},i=0;i<s.length;++i){var a=s[i];n[a]={x:e[2*i],y:e[2*i+1],radius:o[a].radius}}return r(n,t)},a,e),l=u.x,c=0;c<s.length;++c)i=s[c],o[i].x=l[2*c],o[i].y=l[2*c+1];return o}var b=1e-10;function _(t,e,n){return Math.min(t,e)*Math.min(t,e)*Math.PI<=n+b?Math.abs(t-e):function(t,e,n,r){var i=(r=r||{}).maxIterations||100,o=r.tolerance||1e-10,a=t(e),s=t(n),u=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<i;++l){var c=e+(u/=2),h=t(c);if(h*a>=0&&(e=c),Math.abs(u)<o||0===h)return c}return e+u}(function(r){return s(t,e,r)-n},0,t+e)}function w(t,e){var n=S(t,e),r=e.lossFunction||M;if(t.length>=8){var i=function(t,e){var n,r=(e=e||{}).restarts||10,i=[],o={};for(n=0;n<t.length;++n){var a=t[n];1==a.sets.length&&(o[a.sets[0]]=i.length,i.push(a))}var s=function(t,e,n){var r=h(e.length,e.length),i=h(e.length,e.length);return t.filter(function(t){return 2==t.sets.length}).map(function(t){var o=n[t.sets[0]],a=n[t.sets[1]],s=_(Math.sqrt(e[o].size/Math.PI),Math.sqrt(e[a].size/Math.PI),t.size);r[o][a]=r[a][o]=s;var u=0;t.size+1e-10>=Math.min(e[o].size,e[a].size)?u=1:t.size<=1e-10&&(u=-1),i[o][a]=i[a][o]=u}),{distances:r,constraints:i}}(t,i,o),u=s.distances,l=s.constraints,f=p(u.map(p))/u.length;u=u.map(function(t){return t.map(function(t){return t/f})});var g,v,y=function(t,e){return function(t,e,n,r){var i,o=0;for(i=0;i<e.length;++i)e[i]=0;for(i=0;i<n.length;++i)for(var a=t[2*i],s=t[2*i+1],u=i+1;u<n.length;++u){var l=t[2*u],c=t[2*u+1],h=n[i][u],f=r[i][u],p=(l-a)*(l-a)+(c-s)*(c-s),d=Math.sqrt(p),g=p-h*h;f>0&&d<=h||f<0&&d>=h||(o+=2*g*g,e[2*i]+=4*g*(a-l),e[2*i+1]+=4*g*(s-c),e[2*u]+=4*g*(l-a),e[2*u+1]+=4*g*(c-s))}return o}(t,e,u,l)};for(n=0;n<r;++n){var x=c(2*u.length).map(Math.random);v=m(y,x,e),(!g||v.fx<g.fx)&&(g=v)}var b=g.x,w={};for(n=0;n<i.length;++n){var S=i[n];w[S.sets[0]]={x:b[2*n]*f,y:b[2*n+1]*f,radius:Math.sqrt(S.size/Math.PI)}}if(e.history)for(n=0;n<e.history.length;++n)d(e.history[n].x,f);return w}(t,e),o=r(i,t),a=r(n,t);o+1e-8<a&&(n=i)}return n}function S(t,e){for(var n,r=e&&e.lossFunction?e.lossFunction:M,i={},o={},a=0;a<t.length;++a){var s=t[a];1==s.sets.length&&(n=s.sets[0],i[n]={x:1e10,y:1e10,rowid:i.length,size:s.size,radius:Math.sqrt(s.size/Math.PI)},o[n]=[])}for(t=t.filter(function(t){return 2==t.sets.length}),a=0;a<t.length;++a){var l=t[a],c=l.hasOwnProperty("weight")?l.weight:1,h=l.sets[0],f=l.sets[1];l.size+b>=Math.min(i[h].size,i[f].size)&&(c=0),o[h].push({set:f,size:l.size,weight:c}),o[f].push({set:h,size:l.size,weight:c})}var p=[];for(n in o)if(o.hasOwnProperty(n)){var d=0;for(a=0;a<o[n].length;++a)d+=o[n][a].size*o[n][a].weight;p.push({set:n,size:d})}function g(t,e){return e.size-t.size}p.sort(g);var v={};function y(t){return t.set in v}function m(t,e){i[e].x=t.x,i[e].y=t.y,v[e]=!0}for(m({x:0,y:0},p[0].set),a=1;a<p.length;++a){var x=p[a].set,w=o[x].filter(y);if(n=i[x],w.sort(g),0===w.length)throw"ERROR: missing pairwise overlap information";for(var S=[],C=0;C<w.length;++C){var P=i[w[C].set],A=_(n.radius,P.radius,w[C].size);S.push({x:P.x+A,y:P.y}),S.push({x:P.x-A,y:P.y}),S.push({y:P.y+A,x:P.x}),S.push({y:P.y-A,x:P.x});for(var I=C+1;I<w.length;++I)for(var O=i[w[I].set],E=_(n.radius,O.radius,w[I].size),T=u({x:P.x,y:P.y,radius:A},{x:O.x,y:O.y,radius:E}),k=0;k<T.length;++k)S.push(T[k])}var j=1e50,L=S[0];for(C=0;C<S.length;++C){i[x].x=S[C].x,i[x].y=S[C].y;var D=r(i,t);D<j&&(j=D,L=S[C])}m(L,x)}return i}function M(t,e){for(var n=0,r=0;r<e.length;++r){var o,u=e[r];if(1!=u.sets.length){if(2==u.sets.length){var l=t[u.sets[0]],c=t[u.sets[1]];o=s(l.radius,c.radius,a(l,c))}else o=i(u.sets.map(function(e){return t[e]}));var h=u.hasOwnProperty("weight")?u.weight:1;n+=h*(o-u.size)*(o-u.size)}}return n}function C(t,e,n){var r;if(null===n?t.sort(function(t,e){return e.radius-t.radius}):t.sort(n),t.length>0){var i=t[0].x,o=t[0].y;for(r=0;r<t.length;++r)t[r].x-=i,t[r].y-=o}if(2==t.length){var s=a(t[0],t[1]);s<Math.abs(t[1].radius-t[0].radius)&&(t[1].x=t[0].x+t[0].radius-t[1].radius-1e-10,t[1].y=t[0].y)}if(t.length>1){var u,l,c=Math.atan2(t[1].x,t[1].y)-e,h=Math.cos(c),f=Math.sin(c);for(r=0;r<t.length;++r)u=t[r].x,l=t[r].y,t[r].x=h*u-f*l,t[r].y=f*u+h*l}if(t.length>2){for(var p=Math.atan2(t[2].x,t[2].y)-e;p<0;)p+=2*Math.PI;for(;p>2*Math.PI;)p-=2*Math.PI;if(p>Math.PI){var d=t[1].y/(1e-10+t[1].x);for(r=0;r<t.length;++r){var g=(t[r].x+d*t[r].y)/(1+d*d);t[r].x=2*g-t[r].x,t[r].y=2*g*d-t[r].y}}}}function P(t){function e(t){return t.parent!==t&&(t.parent=e(t.parent)),t.parent}t.map(function(t){t.parent=t});for(var n=0;n<t.length;++n)for(var r=n+1;r<t.length;++r){var i=t[n].radius+t[r].radius;a(t[n],t[r])+1e-10<i&&(o=t[r],s=t[n],u=void 0,u=e(o),l=e(s),u.parent=l)}var o,s,u,l,c,h={};for(n=0;n<t.length;++n)(c=e(t[n]).parent.setid)in h||(h[c]=[]),h[c].push(t[n]);t.map(function(t){delete t.parent});var f=[];for(c in h)h.hasOwnProperty(c)&&f.push(h[c]);return f}function A(t){var e=function(e){var n=Math.max.apply(null,t.map(function(t){return t[e]+t.radius})),r=Math.min.apply(null,t.map(function(t){return t[e]-t.radius}));return{max:n,min:r}};return{xRange:e("x"),yRange:e("y")}}function I(t,e,n){null===e&&(e=Math.PI/2);var r,i,o=[];for(i in t)if(t.hasOwnProperty(i)){var a=t[i];o.push({x:a.x,y:a.y,radius:a.radius,setid:i})}var s=P(o);for(r=0;r<s.length;++r){C(s[r],e,n);var u=A(s[r]);s[r].size=(u.xRange.max-u.xRange.min)*(u.yRange.max-u.yRange.min),s[r].bounds=u}s.sort(function(t,e){return e.size-t.size});var l=(o=s[0]).bounds,c=(l.xRange.max-l.xRange.min)/50;function h(t,e,n){if(t){var r,i,a,s=t.bounds;e?r=l.xRange.max-s.xRange.min+c:(r=l.xRange.max-s.xRange.max,(a=(s.xRange.max-s.xRange.min)/2-(l.xRange.max-l.xRange.min)/2)<0&&(r+=a)),n?i=l.yRange.max-s.yRange.min+c:(i=l.yRange.max-s.yRange.max,(a=(s.yRange.max-s.yRange.min)/2-(l.yRange.max-l.yRange.min)/2)<0&&(i+=a));for(var u=0;u<t.length;++u)t[u].x+=r,t[u].y+=i,o.push(t[u])}}for(var f=1;f<s.length;)h(s[f],!0,!1),h(s[f+1],!1,!0),h(s[f+2],!0,!0),f+=3,l=A(o);var p={};for(r=0;r<o.length;++r)p[o[r].setid]=o[r];return p}function O(t,e,n,r){var i=[],o=[];for(var a in t)t.hasOwnProperty(a)&&(o.push(a),i.push(t[a]));e-=2*r,n-=2*r;var s=A(i),u=s.xRange,l=s.yRange;if(u.max==u.min||l.max==l.min)return console.log("not scaling solution: zero size detected"),t;for(var c=e/(u.max-u.min),h=n/(l.max-l.min),f=Math.min(h,c),p=(e-(u.max-u.min)*f)/2,d=(n-(l.max-l.min)*f)/2,g={},v=0;v<i.length;++v){var y=i[v];g[o[v]]={radius:f*y.radius,x:r+p+(y.x-u.min)*f,y:r+d+(y.y-l.min)*f}}return g}function E(t,n){return function(){for(var r,i=e.select(this),o=i.datum(),a=t[o.sets[0]].radius||50,s=n(o)||"",u=s.split(/\s+/).reverse(),l=(s.length+u.length)/3,c=u.pop(),h=[c],f=0,p=i.text(null).append("tspan").text(c);c=u.pop();)h.push(c),r=h.join(" "),p.text(r),r.length>l&&p.node().getComputedTextLength()>a&&(h.pop(),p.text(h.join(" ")),h=[c],p=i.append("tspan").text(c),f++);var d=.35-1.1*f/2,g=i.attr("x"),v=i.attr("y");i.selectAll("tspan").attr("x",g).attr("y",v).attr("dy",function(t,e){return d+1.1*e+"em"})}}function T(t,e,n){var r,i,o=e[0].radius-a(e[0],t);for(r=1;r<e.length;++r)(i=e[r].radius-a(e[r],t))<=o&&(o=i);for(r=0;r<n.length;++r)(i=a(n[r],t)-n[r].radius)<=o&&(o=i);return o}function k(t,e){var n,r=[];for(n=0;n<t.length;++n){var o=t[n];r.push({x:o.x,y:o.y}),r.push({x:o.x+o.radius/2,y:o.y}),r.push({x:o.x-o.radius/2,y:o.y}),r.push({x:o.x,y:o.y+o.radius/2}),r.push({x:o.x,y:o.y-o.radius/2})}var s=r[0],u=T(r[0],t,e);for(n=1;n<r.length;++n){var c=T(r[n],t,e);c>=u&&(s=r[n],u=c)}var h=v(function(n){return-1*T({x:n[0],y:n[1]},t,e)},[s.x,s.y],{maxIterations:500,minErrorDelta:1e-10}).x,f={x:h[0],y:h[1]},p=!0;for(n=0;n<t.length;++n)if(a(f,t[n])>t[n].radius){p=!1;break}for(n=0;n<e.length;++n)if(a(f,e[n])<e[n].radius){p=!1;break}if(!p)if(1==t.length)f={x:t[0].x,y:t[0].y};else{var d={};i(t,d),f=0===d.arcs.length?{x:0,y:-1e3,disjoint:!0}:1==d.arcs.length?{x:d.arcs[0].circle.x,y:d.arcs[0].circle.y}:e.length?k(t,[]):l(d.arcs.map(function(t){return t.p1}))}return f}function j(t){var e={},n=[];for(var r in t)n.push(r),e[r]=[];for(var i=0;i<n.length;i++)for(var o=t[n[i]],s=i+1;s<n.length;++s){var u=t[n[s]],l=a(o,u);l+u.radius<=o.radius+1e-10?e[n[s]].push(n[i]):l+o.radius<=u.radius+1e-10&&e[n[i]].push(n[s])}return e}function L(t,e){for(var n={},r=j(t),i=0;i<e.length;++i){for(var o=e[i].sets,a={},s={},u=0;u<o.length;++u){a[o[u]]=!0;for(var l=r[o[u]],c=0;c<l.length;++c)s[l[c]]=!0}var h=[],f=[];for(var p in t)p in a?h.push(t[p]):p in s||f.push(t[p]);var d=k(h,f);n[o]=d,d.disjoint&&e[i].size>0&&console.log("WARNING: area "+o+" not represented on screen")}return n}function D(t,e,n){var r=[];return r.push("\nM",t,e),r.push("\nm",-n,0),r.push("\na",n,n,0,1,0,2*n,0),r.push("\na",n,n,0,1,0,2*-n,0),r.join(" ")}function F(t){var e=t.split(" ");return{x:parseFloat(e[1]),y:parseFloat(e[2]),radius:-parseFloat(e[4])}}function R(t){var e={};i(t,e);var n=e.arcs;if(0===n.length)return"M 0 0";if(1==n.length){var r=n[0].circle;return D(r.x,r.y,r.radius)}for(var o=["\nM",n[0].p2.x,n[0].p2.y],a=0;a<n.length;++a){var s=n[a],u=s.circle.radius,l=s.width>u;o.push("\nA",u,u,0,l?1:0,1,s.p1.x,s.p1.y)}return o.join(" ")}t.intersectionArea=i,t.circleCircleIntersection=u,t.circleOverlap=s,t.circleArea=o,t.distance=a,t.venn=x,t.greedyLayout=S,t.scaleSolution=O,t.normalizeSolution=I,t.bestInitialLayout=w,t.lossFunction=M,t.disjointCluster=P,t.distanceFromIntersectArea=_,t.VennDiagram=function(){var t=600,n=350,r=15,i=1e3,o=Math.PI/2,a=!0,s=!0,u=!0,l=null,c=null,h={},f=["#1f77b4","#ff7f0e","#2ca02c","#d62728","#9467bd","#8c564b","#e377c2","#7f7f7f","#bcbd22","#17becf"],p=0,d=function(t){if(t in h)return h[t];var e=h[t]=f[p];return(p+=1)>=f.length&&(p=0),e},g=x,v=M;function y(h){var f=h.datum(),p={};f.forEach(function(t){0==t.size&&1==t.sets.length&&(p[t.sets[0]]=1)});var y={},m={};if((f=f.filter(function(t){return!t.sets.some(function(t){return t in p})})).length>0){var x=g(f,{lossFunction:v});a&&(x=I(x,o,c)),y=O(x,t,n,r),m=L(y,f)}var b={};function _(t){return t.sets in b?b[t.sets]:1==t.sets.length?""+t.sets[0]:void 0}f.forEach(function(t){t.label&&(b[t.sets]=t.label)}),h.selectAll("svg").data([y]).enter().append("svg");var w=h.select("svg").attr("width",t).attr("height",n),S={},M=!1;w.selectAll(".venn-area path").each(function(t){var n=e.select(this).attr("d");1==t.sets.length&&n&&(M=!0,S[t.sets[0]]=F(n))});var C=function(e){return function(r){var i=e.sets.map(function(e){var i=S[e],o=y[e];return i||(i={x:t/2,y:n/2,radius:1}),o||(o={x:t/2,y:n/2,radius:1}),{x:i.x*(1-r)+o.x*r,y:i.y*(1-r)+o.y*r,radius:i.radius*(1-r)+o.radius*r}});return R(i)}},P=w.selectAll(".venn-area").data(f,function(t){return t.sets}),A=P.enter().append("g").attr("class",function(t){return"venn-area venn-"+(1==t.sets.length?"circle":"intersection")}).attr("data-venn-sets",function(t){return t.sets.join("_")}),T=A.append("path"),k=A.append("text").attr("class","label").text(function(t){return _(t)}).attr("text-anchor","middle").attr("dy",".35em").attr("x",t/2).attr("y",n/2);u&&(T.style("fill-opacity","0").filter(function(t){return 1==t.sets.length}).style("fill",function(t){return d(t.sets)}).style("fill-opacity",".25"),k.style("fill",function(t){return 1==t.sets.length?d(t.sets):"#444"}));var j=h;M?(j=h.transition("venn").duration(i)).selectAll("path").attrTween("d",C):j.selectAll("path").attr("d",function(t){return R(t.sets.map(function(t){return y[t]}))});var D=j.selectAll("text").filter(function(t){return t.sets in m}).text(function(t){return _(t)}).attr("x",function(t){return Math.floor(m[t.sets].x)}).attr("y",function(t){return Math.floor(m[t.sets].y)});s&&(M?"on"in D?D.on("end",E(y,_)):D.each("end",E(y,_)):D.each(E(y,_)));var B=P.exit().transition("venn").duration(i).remove();B.selectAll("path").attrTween("d",C);var N=B.selectAll("text").attr("x",t/2).attr("y",n/2);return null!==l&&(k.style("font-size","0px"),D.style("font-size",l),N.style("font-size","0px")),{circles:y,textCentres:m,nodes:P,enter:A,update:j,exit:B}}return y.wrap=function(t){return arguments.length?(s=t,y):s},y.width=function(e){return arguments.length?(t=e,y):t},y.height=function(t){return arguments.length?(n=t,y):n},y.padding=function(t){return arguments.length?(r=t,y):r},y.colours=function(t){return arguments.length?(d=t,y):d},y.fontSize=function(t){return arguments.length?(l=t,y):l},y.duration=function(t){return arguments.length?(i=t,y):i},y.layoutFunction=function(t){return arguments.length?(g=t,y):g},y.normalize=function(t){return arguments.length?(a=t,y):a},y.styled=function(t){return arguments.length?(u=t,y):u},y.orientation=function(t){return arguments.length?(o=t,y):o},y.orientationOrder=function(t){return arguments.length?(c=t,y):c},y.lossFunction=function(t){return arguments.length?(v=t,y):v},y},t.wrapText=E,t.computeTextCentres=L,t.computeTextCentre=k,t.sortAreas=function(t,e){for(var n=j(t.selectAll("svg").datum()),r={},i=0;i<e.sets.length;++i){var o=e.sets[i];for(var a in n)for(var s=n[a],u=0;u<s.length;++u)if(s[u]==o){r[a]=!0;break}}function l(t){for(var e=0;e<t.length;++e)if(!(t[e]in r))return!1;return!0}t.selectAll("g").sort(function(t,n){return t.sets.length!=n.sets.length?t.sets.length-n.sets.length:t==e?l(n.sets)?-1:1:n==e?l(t.sets)?1:-1:n.size-t.size})},t.circlePath=D,t.circleFromPath=F,t.intersectionAreaPath=R,Object.defineProperty(t,"__esModule",{value:!0})}(e,n(563),n(733))},function(t,e,n){var r=n(562),i=n(666),o=n(551),a=n(549),s=n(771),u=s.venn,l=s.scaleSolution,c=s.circlePath,h=s.intersectionAreaPath,f=s.computeTextCentres;function p(t){return a.isArray(t)?t:a.isString(t)?t.split("*"):[t]}n(770);var d=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return e.type="venn",e.shapeType="venn",e.generatePoints=!0,e},e.prototype._initAttrs=function(){var t=this.get("view"),e=this.get("attrs"),n=this.get("attrOptions"),r=this.get("labelCfg"),s=this.get("data"),d=n.size?n.size.field:"size",g=r?r.fields[0]:"sets";this.set("labelCfg",null),s.forEach(function(t){t.sets=t[g],t.size=t[d]});var v=u(s),y=this.get("coord"),m=[Math.min(y.x.end,y.x.start),Math.max(y.x.end,y.x.start)],x=[Math.min(y.y.end,y.y.start),Math.max(y.y.end,y.y.start)],b=m[1]-m[0],_=x[1]-x[0],w=this.get("styleOptions"),S=w&&a.isObject(w.style)?w.style.padding:0;a.isFinite(S)||(S=0);var M=l(v,b,_,S),C=f(M,s);for(var P in s.forEach(function(t){var e=t.sets,n=e.join(",");if(t.id=n,1===e.length){var r=M[n];t.path=c(r.x,r.y,r.radius),a.assign(t,r)}else{var i=e.map(function(t){return M[t]}),o=h(i);/[zZ]$/.test(o)||(o+="Z"),t.path=o;var s=C[n]||{x:0,y:0};a.assign(t,s)}}),t.set("data",s),this.set("data",s),this.set("dataArray",s),this.position("x*y"),n)if(n.hasOwnProperty(P)){var A=n[P],I=a.upperFirst(P),O=p(A.field);"position"===P&&(A.coord=y);for(var E=[],T=0;T<O.length;T++){var k=O[T],j=this._createScale(k,s);"color"===P&&a.isNil(A.values)&&(j.values.length<=8?A.values=o.colors:j.values.length<=16?A.values=o.colors_16:A.values=o.colors_24,a.isNil(A.values)&&(A.values=o.colors)),E.push(j)}"position"===P&&(E[0].change({nice:!1,min:m[0],max:m[1]}),E[1].change({nice:!1,min:x[0],max:x[1]})),A.scales=E;var L=new i[I](A);e[P]=L}},e.prototype.paint=function(){t.prototype.paint.call(this);var e=this,n=e.get("dataArray"),r=e.get("shapeContainer");n.forEach(function(t){var n=e.getDrawCfg(t[0]),i=n.origin._origin;r.addShape("text",{attrs:a.mix({},{x:i.x,y:i.y,text:i.label||"",fontSize:18,fill:"hollow"===n.shape?n.color:"#666",textAlign:"center",textBaseline:"middle"},n.style?n.style.textStyle:{})})})},e}(r);r.Venn=d,t.exports=d},function(t,e,n){var r=n(549),i=n(561),o=n(551);function a(t){r.isArray(t)||(t=[t]);var e=t[0],n=t[t.length-1],i=t.length>1?t[1]:e;return{min:e,max:n,min1:i,max1:t.length>3?t[3]:n,median:t.length>2?t[2]:i}}function s(t,e,n){var i,o,s=[],u=void 0,l=void 0;return r.isArray(e)?u=[[t-n/2,(l=a(e)).max],[t+n/2,l.max],[t,l.max],[t,l.max1],[t-n/2,l.min1],[t-n/2,l.max1],[t+n/2,l.max1],[t+n/2,l.min1],[t,l.min1],[t,l.min],[t-n/2,l.min],[t+n/2,l.min],[t-n/2,l.median],[t+n/2,l.median]]:(e=e||.5,u=[[(l=a(t)).min,e-n/2],[l.min,e+n/2],[l.min,e],[l.min1,e],[l.min1,e-n/2],[l.min1,e+n/2],[l.max1,e+n/2],[l.max1,e-n/2],[l.max1,e],[l.max,e],[l.max,e-n/2],[l.max,e+n/2],[l.median,e-n/2],[l.median,e+n/2]]),i=u,o=s,r.each(i,function(t){o.push({x:t[0],y:t[1]})}),s}function u(t,e,n){var i=function(t){r.isArray(t)||(t=[t]);var e=t.sort(function(t,e){return t<e?1:-1}),n=e.length;if(n<4)for(var i=e[n-1],o=0;o<4-n;o++)e.push(i);return e}(e);return[{x:t,y:i[0]},{x:t,y:i[1]},{x:t-n/2,y:i[2]},{x:t-n/2,y:i[1]},{x:t+n/2,y:i[1]},{x:t+n/2,y:i[2]},{x:t,y:i[2]},{x:t,y:i[3]}]}var l=i.registerFactory("schema",{defaultShapeType:"",getActiveCfg:function(t,e){if("box"===t)return{lineWidth:(e.lineWidth||1)+1};var n=e.fillOpacity||e.opacity||1;return{fillOpacity:n-.15,strokeOpacity:n-.15}},getSelectedCfg:function(t,e){return e&&e.style?e.style:this.getActiveCfg(t,e)}});i.registerShape("schema","box",{getPoints:function(t){return s(t.x,t.y,t.size)},draw:function(t,e){var n,i=function(t){var e=o.shape.schema;return r.mix({},e,{stroke:t.color,strokeOpacity:t.opacity},t.style)}(t),a=[["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],["L",n[6].x,n[6].y],["L",n[7].x,n[7].y],["L",n[4].x,n[4].y],["Z"],["M",n[8].x,n[8].y],["L",n[9].x,n[9].y],["M",n[10].x,n[10].y],["L",n[11].x,n[11].y],["M",n[12].x,n[12].y],["L",n[13].x,n[13].y]];return a=this.parsePath(a),e.addShape("path",{attrs:r.mix(i,{path:a})})},getMarkerCfg:function(t){return{symbol:function(t,e,n,r){var i=s(t,[e-6,e-3,e,e+3,e+6],n);r.moveTo(i[0].x+1,i[0].y),r.lineTo(i[1].x-1,i[1].y),r.moveTo(i[2].x,i[2].y),r.lineTo(i[3].x,i[3].y),r.moveTo(i[4].x,i[4].y),r.lineTo(i[5].x,i[5].y),r.lineTo(i[6].x,i[6].y),r.lineTo(i[7].x,i[7].y),r.lineTo(i[4].x,i[4].y),r.closePath(),r.moveTo(i[8].x,i[8].y),r.lineTo(i[9].x,i[9].y),r.moveTo(i[10].x+1,i[10].y),r.lineTo(i[11].x-1,i[11].y),r.moveTo(i[12].x,i[12].y),r.lineTo(i[13].x,i[13].y)},radius:6,lineWidth:1,stroke:t.color}}}),i.registerShape("schema","candle",{getPoints:function(t){return u(t.x,t.y,t.size)},draw:function(t,e){var n,i=function(t){var e=o.shape.schema;return r.mix({},e,{fill:t.color,stroke:t.color,fillOpacity:t.opacity},t.style)}(t),a=[["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],["L",n[4].x,n[4].y],["L",n[5].x,n[5].y],["Z"],["M",n[6].x,n[6].y],["L",n[7].x,n[7].y]];return a=this.parsePath(a),e.addShape("path",{attrs:r.mix(i,{path:a})})},getMarkerCfg:function(t){return{symbol:function(t,e,n,r){var i=u(t,e=[e+7.5,e+3,e-3,e-7.5],n);r.moveTo(i[0].x,i[0].y),r.lineTo(i[1].x,i[1].y),r.moveTo(i[2].x,i[2].y),r.lineTo(i[3].x,i[3].y),r.lineTo(i[4].x,i[4].y),r.lineTo(i[5].x,i[5].y),r.closePath(),r.moveTo(i[6].x,i[6].y),r.lineTo(i[7].x,i[7].y)},lineWidth:1,stroke:t.color,fill:t.color,radius:6}}}),t.exports=l},function(t,e,n){function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function o(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}var a=n(562),s=n(549),u=n(650);n(773);var l=function(t){function e(n){r(this,e);var o=i(this,t.call(this,n));return s.assign(o,u),o}return o(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return e.type="schema",e.shapeType="schema",e.generatePoints=!0,e},e.prototype.createShapePointsCfg=function(e){var n=t.prototype.createShapePointsCfg.call(this,e);return n.size=this.getNormalizedSize(e),n},e}(a),c=function(t){function e(){return r(this,e),i(this,t.apply(this,arguments))}return o(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return e.hasDefaultAdjust=!0,e.adjusts=[{type:"dodge"}],e},e}(l);l.Dodge=c,a.Schema=l,a.SchemaDodge=c,t.exports=l},function(t,e,n){var r=n(549),i=n(561),o=n(551);function a(t){var e=o.shape.polygon;return r.mix({},e,{stroke:t.color,fill:t.color,fillOpacity:t.opacity},t.style)}function s(t){for(var e=t[0],n=1,i=[["M",e.x,e.y]];n<t.length;){var o=t[n];o.x===t[n-1].x&&o.y===t[n-1].y||(i.push(["L",o.x,o.y]),o.x===e.x&&o.y===e.y&&n<t.length-1&&(e=t[n+1],i.push(["Z"]),i.push(["M",e.x,e.y]),n++)),n++}return r.isEqual(i[i.length-1],e)||i.push(["L",e.x,e.y]),i.push(["Z"]),i}var u=i.registerFactory("polygon",{defaultShapeType:"polygon",getDefaultPoints:function(t){var e=[];return r.each(t.x,function(n,r){var i=t.y[r];e.push({x:n,y:i})}),e},getActiveCfg:function(t,e){var n=e.lineWidth||1;return"hollow"===t?{lineWidth:n+1}:{fillOpacity:(e.fillOpacity||e.opacity||1)-.08}},getSelectedCfg:function(t,e){return e&&e.style?e.style:this.getActiveCfg(t,e)}});i.registerShape("polygon","polygon",{draw:function(t,e){if(!r.isEmpty(t.points)){var n=a(t),i=s(t.points);return i=this.parsePath(i),e.addShape("path",{attrs:r.mix(n,{path:i})})}},getMarkerCfg:function(t){return r.mix({symbol:"square",radius:4},a(t))}}),i.registerShape("polygon","hollow",{draw:function(t,e){if(!r.isEmpty(t.points)){var n=function(t){var e=o.shape.hollowPolygon;return r.mix({},e,{stroke:t.color,strokeOpacity:t.opacity},t.style)}(t),i=s(t.points);return i=this.parsePath(i),e.addShape("path",{attrs:r.mix(n,{path:i})})}},getMarkerCfg:function(t){return r.mix({symbol:"square",radius:4},a(t))}}),t.exports=u},function(t,e,n){var r=n(562),i=n(549);n(775);var o=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return e.type="polygon",e.shapeType="polygon",e.generatePoints=!0,e},e.prototype.createShapePointsCfg=function(e){var n=t.prototype.createShapePointsCfg.call(this,e),r=n.x,o=n.y,a=void 0;if(!i.isArray(r)||!i.isArray(o)){var s=this.getXScale(),u=this.getYScale(),l=.5/(s.values?s.values.length:s.ticks.length),c=.5/(u.values?u.values.length:u.ticks.length);s.isCategory&&u.isCategory?(r=[r-l,r-l,r+l,r+l],o=[o-c,o+c,o+c,o-c]):i.isArray(r)?(r=[(a=r)[0],a[0],a[1],a[1]],o=[o-c/2,o+c/2,o+c/2,o-c/2]):i.isArray(o)&&(o=[(a=o)[0],a[1],a[1],a[0]],r=[r-l/2,r-l/2,r+l/2,r+l/2]),n.x=r,n.y=o}return n},e}(r);r.Polygon=o,t.exports=o},function(t,e,n){var r=n(549),i=n(615),o=n(551),a=n(561),s=n(552),u=s.Marker,l=s.PathUtil,c=["cross","tick","plus","hyphen","line","pointerLine","pointerArrow"],h=Math.sqrt(3);function f(t){var e=o.shape.point;return r.mix({},e,{fill:t.color,fillOpacity:t.opacity,radius:t.size},t.style)}function p(t){var e=o.shape.hollowPoint;return r.mix({},e,{stroke:t.color,strokeOpacity:t.opacity,radius:t.size},t.style)}r.mix(u.Symbols,{hexagon:function(t,e,n,r){var i=n/2*h;r.moveTo(t,e-n),r.lineTo(t+i,e-n/2),r.lineTo(t+i,e+n/2),r.lineTo(t,e+n),r.lineTo(t-i,e+n/2),r.lineTo(t-i,e-n/2),r.closePath()},bowtie:function(t,e,n,r){var i=n-1.5;r.moveTo(t-n,e-i),r.lineTo(t+n,e+i),r.lineTo(t+n,e-i),r.lineTo(t-n,e+i),r.closePath()},cross:function(t,e,n,r){r.moveTo(t-n,e-n),r.lineTo(t+n,e+n),r.moveTo(t+n,e-n),r.lineTo(t-n,e+n)},tick:function(t,e,n,r){r.moveTo(t-n/2,e-n),r.lineTo(t+n/2,e-n),r.moveTo(t,e-n),r.lineTo(t,e+n),r.moveTo(t-n/2,e+n),r.lineTo(t+n/2,e+n)},plus:function(t,e,n,r){r.moveTo(t-n,e),r.lineTo(t+n,e),r.moveTo(t,e-n),r.lineTo(t,e+n)},hyphen:function(t,e,n,r){r.moveTo(t-n,e),r.lineTo(t+n,e)},line:function(t,e,n,r){r.moveTo(t,e-n),r.lineTo(t,e+n)}});var d=a.registerFactory("point",{defaultShapeType:"hollowCircle",getActiveCfg:function(t,e){var n=e.radius,i=void 0;return{radius:n+1,shadowBlur:n,shadowColor:i=t&&(0===t.indexOf("hollow")||-1!==r.indexOf(c,t))||!t?e.stroke||e.strokeStyle:e.fill||e.fillStyle,stroke:i,strokeOpacity:1,lineWidth:1}},getDefaultPoints:function(t){return i.splitPoints(t)}});a.registerShape("point","rect",{draw:function(t,e){var n=f(t),i=function(t){var e=t.points[0].x,n=t.points[0].y,r=t.size[0],i=t.size[1];return[["M",e-.5*r,n-.5*i],["L",e+.5*r,n-.5*i],["L",e+.5*r,n+.5*i],["L",e-.5*r,n+.5*i],["z"]]}(t);return i=this.parsePath(i),e.addShape("path",{attrs:r.mix(n,{path:i})})},getMarkerCfg:function(t){var e=f(t);return e.symbol="rect",e.radius=4.5,e}}),r.each(["circle","square","bowtie","diamond","hexagon","triangle","triangle-down"],function(t){a.registerShape("point",t,{draw:function(e,n){var i=f(e);return n.addShape("Marker",{attrs:r.mix(i,{symbol:t,x:e.x,y:e.y})})},getMarkerCfg:function(e){var n=f(e);return n.symbol=t,n.radius=4.5,n}}),a.registerShape("point","hollow"+r.upperFirst(t),{draw:function(e,n){var i=p(e);return n.addShape("Marker",{attrs:r.mix(i,{symbol:t,x:e.x,y:e.y})})},getMarkerCfg:function(e){var n=p(e);return n.symbol=t,n.radius=4.5,n}})}),r.each(c,function(t){a.registerShape("point",t,{draw:function(e,n){var i=p(e);return n.addShape("Marker",{attrs:r.mix(i,{symbol:t,x:e.x,y:e.y})})},getMarkerCfg:function(e){var n=p(e);return n.symbol=t,n.radius=4.5,n}})}),a.registerShape("point","image",{draw:function(t,e){return t.points=this.parsePoints(t.points),e.addShape("image",{attrs:{x:t.points[0].x-t.size/2,y:t.points[0].y-t.size,width:t.size,height:t.size,img:t.shape[1]}})}});var g={};a.registerShape("point","path",{draw:function(t,e){var n=r.mix({},p(t),f(t)),i=t.shape[1],o=t.size||10,a=void 0;if(g[i])a=g[i];else{var s=l.parsePathString(i),u=r.flatten(s).filter(function(t){return r.isNumber(t)});g[i]=a={range:Math.max.apply(null,u)-Math.min.apply(null,u),segments:s}}var c=o/a.range,h=[];n.rotate&&(h.push(["r",n.rotate/180*Math.PI]),delete n.rotate);var d=e.addShape("path",{attrs:r.mix(n,{path:a.segments})});return h.push(["s",c,c],["t",t.x,t.y]),d.transform(h),d}}),t.exports=d},function(t,e,n){function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function o(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}var a=n(562),s=n(549);n(777);var u=function(t){function e(){return r(this,e),i(this,t.apply(this,arguments))}return o(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return e.type="point",e.shapeType="point",e.generatePoints=!0,e},e.prototype.drawPoint=function(t,e,n,r){var i=this,o=t.shape,a=i.getDrawCfg(t),u=void 0;if(s.isArray(t.y)){var l=i.hasStack();s.each(t.y,function(t,s){a.y=t,a.yIndex=s,l&&0===s||(u=n.drawShape(o,a,e),i.appendShapeInfo(u,r+s))})}else s.isNil(t.y)||(u=n.drawShape(o,a,e),i.appendShapeInfo(u,r))},e}(a),l=function(t){function e(){return r(this,e),i(this,t.apply(this,arguments))}return o(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return e.hasDefaultAdjust=!0,e.adjusts=[{type:"jitter"}],e},e}(u),c=function(t){function e(){return r(this,e),i(this,t.apply(this,arguments))}return o(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return e.hasDefaultAdjust=!0,e.adjusts=[{type:"stack"}],e},e}(u);u.Jitter=l,u.Stack=c,a.Point=u,a.PointJitter=l,a.PointStack=c,t.exports=u},function(t,e,n){var r=n(549),i=n(568),o=n(615),a=n(561),s=n(551),u=[1,1],l=[5.5,1];function c(t){var e=s.shape.line;return r.mix({},e,{stroke:t.color,lineWidth:t.size,strokeOpacity:t.opacity,opacity:t.opacity},t.style)}function h(t){var e=s.shape.line;return r.mix({},e,{stroke:t.color,lineWidth:2,strokeOpacity:t.opacity,opacity:t.opacity,radius:6},t.style)}function f(t,e,n,r){var o=void 0;if(e){var a=r.constraint;n&&t.length&&t.push({x:t[0].x,y:t[0].y}),o=i.getSplinePath(t,!1,a)}else o=i.getLinePath(t,!1),n&&o.push(["Z"]);return o}function p(t,e){var n=t.points,i=t.isInCircle,a=n[0];return r.isArray(a.y)?function(t,e,n,r){for(var i=[],a=r.isStack,s=[],u=0;u<t.length;u++){var l=t[u],c=o.splitPoints(l);s.push(c[0]),i.push(c[1])}var h=f(i,e,n,r),p=f(s,e,n,r);return a?h:h.concat(p)}(n,e,i,t):f(n,e,i,t)}function d(t,e){return function(t){var e=[];return r.each(t,function(t,n){var r=0===n?["M",t.x,t.y]:["L",t.x,t.y];e.push(r)}),e}(function(t,e){var n=[];return r.each(t,function(r,i){var o=t[i+1];n.push(r),o&&(n=n.concat(e(r,o)))}),n}(t.points,e))}function g(t,e,n,r){r.moveTo(t-n,e),r.lineTo(t+n,e)}function v(t,e,n,r){r.moveTo(t-n,e),r.arcTo(t-n/2,e-n/2,t,e,n/2),r.lineTo(t,e),r.arcTo(t+n/2,e+n/2,t+n,e-n/2,n/2)}function y(t,e){return r.mix({symbol:e?v:g},h(t))}function m(t,e){return r.mix({symbol:e},h(t))}var x=a.registerFactory("line",{defaultShapeType:"line",getActiveCfg:function(t,e){return{lineWidth:(e.lineWidth||0)+1}},getDefaultPoints:function(t){return o.splitPoints(t)},drawShape:function(t,e,n){var i=this.getShape(t),o=void 0;return(o=1===e.points.length&&s.showSinglePoint?function(t,e,n){var i=e.points[0];return n.addShape("circle",{attrs:r.mix({x:i.x,y:i.y,r:2,fill:e.color},e.style)})}(0,e,n):i.draw(e,n))&&(o.set("origin",e.origin),o._id=e.splitedIndex?e._id+e.splitedIndex:e._id,o.name=this.name),o}});a.registerShape("line","line",{draw:function(t,e){var n=c(t),i=p(t,!1);return e.addShape("path",{attrs:r.mix(n,{path:i})})},getMarkerCfg:function(t){return y(t)}}),a.registerShape("line","dot",{draw:function(t,e){var n=c(t),i=p(t,!1);return e.addShape("path",{attrs:r.mix(n,{path:i,lineDash:u})})},getMarkerCfg:function(t){var e=y(t,!1);return e.lineDash=u,e}}),a.registerShape("line","dash",{draw:function(t,e){var n=c(t),i=p(t,!1);return e.addShape("path",{attrs:r.mix({path:i,lineDash:l},n)})},getMarkerCfg:function(t){var e=y(t,!1);return e.lineDash=e.lineDash||l,e}}),a.registerShape("line","smooth",{draw:function(t,e){var n=c(t),i=this._coord;t.constraint=[[i.start.x,i.end.y],[i.end.x,i.start.y]];var o=p(t,!0);return e.addShape("path",{attrs:r.mix(n,{path:o})})},getMarkerCfg:function(t){return y(t,!0)}}),a.registerShape("line","hv",{draw:function(t,e){var n=c(t),i=d(t,function(t,e){var n=[];return n.push({x:e.x,y:t.y}),n});return e.addShape("path",{attrs:r.mix(n,{path:i})})},getMarkerCfg:function(t){return m(t,function(t,e,n,r){r.moveTo(t-n-1,e-2.5),r.lineTo(t,e-2.5),r.lineTo(t,e+2.5),r.lineTo(t+n+1,e+2.5)})}}),a.registerShape("line","vh",{draw:function(t,e){var n=c(t),i=d(t,function(t,e){var n=[];return n.push({x:t.x,y:e.y}),n});return e.addShape("path",{attrs:r.mix(n,{path:i})})},getMarkerCfg:function(t){return m(t,function(t,e,n,r){r.moveTo(t-n-1,e+2.5),r.lineTo(t,e+2.5),r.lineTo(t,e-2.5),r.lineTo(t+n+1,e-2.5)})}}),a.registerShape("line","hvh",{draw:function(t,e){var n=c(t),i=d(t,function(t,e){var n=[],r=(e.x-t.x)/2+t.x;return n.push({x:r,y:t.y}),n.push({x:r,y:e.y}),n});return e.addShape("path",{attrs:r.mix(n,{path:i})})},getMarkerCfg:function(t){return m(t,function(t,e,n,r){r.moveTo(t-(n+1),e+2.5),r.lineTo(t-n/2,e+2.5),r.lineTo(t-n/2,e-2.5),r.lineTo(t+n/2,e-2.5),r.lineTo(t+n/2,e+2.5),r.lineTo(t+n+1,e+2.5)})}}),a.registerShape("line","vhv",{draw:function(t,e){var n=c(t),i=d(t,function(t,e){var n=[],r=(e.y-t.y)/2+t.y;return n.push({x:t.x,y:r}),n.push({x:e.x,y:r}),n});return e.addShape("path",{attrs:r.mix(n,{path:i})})},getMarkerCfg:function(t){return m(t,function(t,e,n,r){r.moveTo(t-5,e+2.5),r.lineTo(t-5,e),r.lineTo(t,e),r.lineTo(t,e-3),r.lineTo(t,e+3),r.lineTo(t+6.5,e+3)})}}),x.spline=x.smooth,t.exports=x},function(t,e,n){function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function o(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}var a=n(562),s=n(649);n(779);var u=function(t){function e(){return r(this,e),i(this,t.apply(this,arguments))}return o(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return e.type="line",e.sortable=!0,e},e}(s),l=function(t){function e(){return r(this,e),i(this,t.apply(this,arguments))}return o(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return e.hasDefaultAdjust=!0,e.adjusts=[{type:"stack"}],e},e}(u);u.Stack=l,a.Line=u,a.LineStack=l,t.exports=u},function(t,e,n){var r=n(549),i=n(561),o=n(568),a=n(552).PathUtil,s=n(551);function u(t,e){var n=t.x,i=t.y,o=t.y0,a=t.size,s=o,u=i;r.isArray(i)&&(u=i[1],s=i[0]);var l=void 0,c=void 0;r.isArray(n)?(l=n[0],c=n[1]):(l=n-a/2,c=n+a/2);var h=[];return h.push({x:l,y:s},{x:l,y:u}),e?h.push({x:c,y:(u+s)/2}):h.push({x:c,y:u},{x:c,y:s}),h}function l(t){for(var e=[],n=0;n<t.length;n++){var r=t[n];if(r){var i=0===n?"M":"L";e.push([i,r.x,r.y])}}var o=t[0];return e.push(["L",o.x,o.y]),e.push(["z"]),e}function c(t){var e=s.shape.interval;return r.mix({},e,{fill:t.color,stroke:t.color,fillOpacity:t.opacity},t.style)}function h(t){var e=s.shape.hollowInterval;return r.mix({},e,{stroke:t.color,strokeOpacity:t.opacity},t.style)}function f(t,e){var n=[],i=t.points,o=t.nextPoints;return r.isNil(o)?e?n.push(["M",i[0].x,i[0].y],["L",i[1].x,i[1].y],["L",i[2].x,i[2].y],["L",i[3].x,i[3].y],["Z"]):n.push(["M",i[0].x,i[0].y],["L",i[1].x,i[1].y],["L",i[2].x,i[2].y],["L",i[2].x,i[2].y],["Z"]):n.push(["M",i[0].x,i[0].y],["L",i[1].x,i[1].y],["L",o[1].x,o[1].y],["L",o[0].x,o[0].y],["Z"]),n}function p(t,e){var n=e.geom.get("coord"),i=e.point,a=void 0;if(n&&"theta"===n.type){var s=function(t,e){var n=e.getRadius(),i=void 0,a=void 0,s=n*e.innerRadius,u=void 0,l=void 0;return!r.isArray(t.x)&&r.isArray(t.y)&&(t.x=[t.x,t.x]),r.isArray(t.x)?(u={x:t.x[0],y:t.y[0]},l={x:t.x[1],y:t.y[1]},i=o.getPointAngle(e,u),(a=o.getPointAngle(e,l))<=i&&(a+=2*Math.PI)):(l=t,i=e.startAngle,a=o.getPointAngle(e,l)),{r:n,ir:s,startAngle:i,endAngle:a}}(i,n),u=(s.endAngle-s.startAngle)/2+s.startAngle;a={transform:[["t",7.5*Math.cos(u),7.5*Math.sin(u)]]}}return r.mix({},a)}var d=i.registerFactory("interval",{defaultShapeType:"rect",getActiveCfg:function(t,e){return!t||r.inArray(["rect","funnel","pyramid"],t)?{fillOpacity:(e.fillOpacity||e.opacity||1)-.15}:{lineWidth:(e.lineWidth||0)+1}},getDefaultPoints:function(t){return u(t)},getSelectedCfg:function(t,e){return p(0,e)}});function g(t,e,n,r){return 0===e?[[t+.5*n/Math.PI/2,r/2],[t+.5*n/Math.PI,r],[t+n/4,r]]:1===e?[[t+.5*n/Math.PI/2*(Math.PI-2),r],[t+.5*n/Math.PI/2*(Math.PI-1),r/2],[t+n/4,0]]:2===e?[[t+.5*n/Math.PI/2,-r/2],[t+.5*n/Math.PI,-r],[t+n/4,-r]]:[[t+.5*n/Math.PI/2*(Math.PI-2),-r],[t+.5*n/Math.PI/2*(Math.PI-1),-r/2],[t+n/4,0]]}function v(t,e,n,r,i,o,a){for(var s=2*Math.ceil(2*t/n*4),u=[];r<2*-Math.PI;)r+=2*Math.PI;for(;r>0;)r-=2*Math.PI;var l=o-t+(r=r/Math.PI/2*n)-2*t;u.push(["M",l,e]);for(var c=0,h=0;h<s;++h){var f=g(h*n/4,h%4,n,i);u.push(["C",f[0][0]+l,-f[0][1]+e,f[1][0]+l,-f[1][1]+e,f[2][0]+l,-f[2][1]+e]),h===s-1&&(c=f[2][0])}return u.push(["L",c+l,a+t]),u.push(["L",l,a+t]),u.push(["L",l,e]),u}function y(t,e,n,r,i,o,a,s){for(var u=a.getBBox(),l=u.maxX-u.minX,c=u.maxY-u.minY,h=0;h<r;h++){o.addShape("path",{attrs:{path:v(s,u.minY+c*n,l/4,0,l/64,t,e),fill:i[h],clip:a}}).animate({transform:[["t",l/2,0]],repeat:!0},5e3-300*h)}}i.registerShape("interval","rect",{draw:function(t,e){var n=c(t),i=l(t.points);return i=this.parsePath(i),e.addShape("path",{attrs:r.mix(n,{path:i})})},getMarkerCfg:function(t){var e=c(t),n=t.isInCircle;return r.mix({symbol:n?"circle":"square",radius:n?4.5:4},e)}}),i.registerShape("interval","hollowRect",{draw:function(t,e){var n=h(t),i=l(t.points);return i=this.parsePath(i),e.addShape("path",{attrs:r.mix(n,{path:i})})},getMarkerCfg:function(t){var e=h(t),n=t.isInCircle;return r.mix({symbol:n?"circle":"square",radius:n?4.5:4},e)}}),i.registerShape("interval","line",{getPoints:function(t){return n=(e=t).x,i=e.y,o=e.y0,a=[],r.isArray(i)?r.each(i,function(t,e){a.push({x:r.isArray(n)?n[e]:n,y:t})}):a.push({x:n,y:i},{x:n,y:o}),a;var e,n,i,o,a},draw:function(t,e){var n=h(t);n.lineWidth=t.size||1;var i=l(t.points);return i=this.parsePath(i),e.addShape("path",{attrs:r.mix(n,{path:i})})},getMarkerCfg:function(t){var e=h(t);return r.mix({symbol:"line",radius:5},e)}}),i.registerShape("interval","tick",{getPoints:function(t){return n=(e=t).x,i=r.isArray(e.y)?e.y[1]:e.y,o=r.isArray(e.y)?e.y[0]:e.y0,a=e.size,(s=[]).push({x:n-a/2,y:i},{x:n+a/2,y:i},{x:n,y:i},{x:n,y:o},{x:n-a/2,y:o},{x:n+a/2,y:o}),s;var e,n,i,o,a,s},draw:function(t,e){var n=h(t),i=function(t){var e=[];return e.push(["M",t[0].x,t[0].y],["L",t[1].x,t[1].y],["M",t[2].x,t[2].y],["L",t[3].x,t[3].y],["M",t[4].x,t[4].y],["L",t[5].x,t[5].y]),e}(t.points);return i=this.parsePath(i),e.addShape("path",{attrs:r.mix(n,{path:i})})},getMarkerCfg:function(t){var e=h(t);return r.mix({symbol:"tick",radius:5},e)}}),i.registerShape("interval","funnel",{getPoints:function(t){return t.size=2*t.size,u(t)},draw:function(t,e){var n=c(t),i=f(t,!0);return i=this.parsePath(i),e.addShape("path",{attrs:r.mix(n,{path:i})})},getMarkerCfg:function(t){var e=c(t);return r.mix({symbol:"square",radius:4},e)}}),i.registerShape("interval","pyramid",{getPoints:function(t){return t.size=2*t.size,u(t,!0)},draw:function(t,e){var n=c(t),i=f(t,!1);return i=this.parsePath(i),e.addShape("path",{attrs:r.mix(n,{path:i})})},getMarkerCfg:function(t){var e=c(t);return r.mix({symbol:"square",radius:4},e)}}),i.registerShape("interval","liquid-fill-gauge",{draw:function(t,e){var n=0,i=1/0;r.each(t.points,function(t){t.x<i&&(i=t.x),n+=t.x});var o=n/t.points.length,a=this.parsePoint({x:o,y:.5}),s=this.parsePoint({x:i,y:.5}),u=a.x-s.x,l=Math.min(u,s.y),f=c(t),p=e.addShape("circle",{attrs:{x:a.x,y:a.y,r:l}});return y(a.x,a.y,t.y/(2*a.y),1,[f.fill],e,p,4*l),e.addShape("circle",{attrs:r.mix(h(t),{x:a.x,y:a.y,r:l+l/8})})}});var m={};i.registerShape("interval","liquid-fill-path",{draw:function(t,e){var n=r.mix({},c(t)),i=t.shape[1],o=0,s=1/0;r.each(t.points,function(t){t.x<s&&(s=t.x),o+=t.x});var u=o/t.points.length,l=this.parsePoint({x:u,y:.5}),f=this.parsePoint({x:s,y:.5}),p=l.x-f.x,d=Math.min(p,f.y),g=void 0;if(m[i])g=m[i];else{var v=a.parsePathString(i);m[i]=g={segments:v}}var x=[];n.rotate&&(x.push(["r",n.rotate/180*Math.PI]),delete n.rotate);var b=e.addShape("path",{attrs:r.mix(n,{fillOpacity:0,path:g.segments})}),_=r.cloneDeep(b.getBBox()),w=_.maxX-_.minX,S=_.maxY-_.minY,M=2*d/Math.max(w,S);b.transform(x.concat([["s",M,M]]));var C=M*w/2,P=M*S/2;b.transform([["t",l.x-C,l.y-P]]),y(l.x,l.y,t.y/(2*l.y),1,[n.fill],e,b,4*f.y);var A=e.addShape("path",{attrs:r.mix(h(t),{path:g.segments})});return A.transform(x.concat([["s",M,M],["t",l.x-C,l.y-P]])),A}}),i.registerShape("interval","top-line",{draw:function(t,e){var n=c(t),i=t.style||{},o=[["M",t.points[1].x,t.points[1].y],["L",t.points[2].x,t.points[2].y]],a={stroke:i.stroke||"white",lineWidth:i.lineWidth||1,path:this.parsePath(o)},s=l(t.points);s=this.parsePath(s),delete n.stroke;var u=e.addShape("path",{attrs:r.mix(n,{zIndex:0,path:s})});return e.addShape("path",{zIndex:1,attrs:a}),u},getMarkerCfg:function(t){var e=c(t),n=t.isInCircle;return r.mix({symbol:n?"circle":"square",radius:n?4.5:4},e)}}),t.exports=d},function(t,e,n){function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function o(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}var a=n(562),s=n(549),u=n(650);n(781);var l=function(t){function e(n){r(this,e);var o=i(this,t.call(this,n));return s.assign(o,u),o}return o(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return e.type="interval",e.shapeType="interval",e.generatePoints=!0,e},e.prototype.createShapePointsCfg=function(e){var n=t.prototype.createShapePointsCfg.call(this,e);return n.size=this.getNormalizedSize(e),n},e.prototype.clearInner=function(){t.prototype.clearInner.call(this),this.set("defaultSize",null)},e}(a),c=function(t){function e(){return r(this,e),i(this,t.apply(this,arguments))}return o(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return e.hasDefaultAdjust=!0,e.adjusts=[{type:"stack"}],e},e}(l),h=function(t){function e(){return r(this,e),i(this,t.apply(this,arguments))}return o(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return e.hasDefaultAdjust=!0,e.adjusts=[{type:"dodge"}],e},e}(l),f=function(t){function e(){return r(this,e),i(this,t.apply(this,arguments))}return o(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return e.hasDefaultAdjust=!0,e.adjusts=[{type:"symmetric"}],e},e}(l);l.Stack=c,l.Dodge=h,l.Symmetric=f,a.Interval=l,a.IntervalStack=c,a.IntervalDodge=h,a.IntervalSymmetric=f,t.exports=l},function(t,e,n){var r=n(562),i=n(616),o=n(549),a={},s=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return e.type="heatmap",e},e.prototype._prepareRange=function(){var t=this.get("mappedData"),e=this.getAttr("color").field,n=1/0,r=-1/0;t.forEach(function(t){var i=t._origin[e];i>r&&(r=i),i<n&&(n=i)}),n===r&&(n=r-1);var i=[n,r];this.set("valueRange",i)},e.prototype._prepareSize=function(){var t=this.getDefaultValue("size");o.isNumber(t)||(t=this._getDefaultSize());var e=this.get("styleOptions"),n=e&&o.isObject(e.style)?e.style.blur:null;o.isFinite(n)||(n=t/2),this.set("heatmapSize",{blur:n,radius:t})},e.prototype._getDefaultSize=function(){var t=this.getAttr("position"),e=this.get("coord");return Math.min(e.width/(4*t.scales[0].ticks.length),e.height/(4*t.scales[1].ticks.length))},e.prototype._colorize=function(t){for(var e=this.getAttr("color"),n=t.data,r=3;r<n.length;r+=4){var o=n[r];if(o){var s=void 0;a[o]?s=a[o]:(s=i.rgb2arr(e.gradient(o/256)),a[o]=s),n[r-3]=s[0],n[r-2]=s[1],n[r-1]=s[2],n[r]=o}}},e.prototype._prepareGreyScaleBlurredCircle=function(t,e){var n=this.get("grayScaleBlurredCanvas");n||(n=document.createElement("canvas"),this.set("grayScaleBlurredCanvas",n));var r=t+e,i=n.getContext("2d");n.width=n.height=2*r,i.clearRect(0,0,n.width,n.height),i.shadowOffsetX=i.shadowOffsetY=2*r,i.shadowBlur=e,i.shadowColor="black",i.beginPath(),i.arc(-r,-r,t,0,2*Math.PI,!0),i.closePath(),i.fill()},e.prototype._drawGrayScaleBlurredCircle=function(t,e,n,r,i){var o=this.get("grayScaleBlurredCanvas");i.globalAlpha=r,i.drawImage(o,t-n,e-n)},e.prototype._getShadowCanvasCtx=function(){var t=this.get("shadowCanvas");t||(t=document.createElement("canvas"),this.set("shadowCanvas",t));var e=this.get("coord"),n=e.width,r=e.height;return t.width=n,t.height=r,t.getContext("2d")},e.prototype._clearShadowCanvasCtx=function(){var t=this._getShadowCanvasCtx();t.clearRect(0,0,t.canvas.width,t.canvas.height)},e.prototype._getImageShape=function(){var t=this.get("imageShape");return t||(t=this.get("container").addShape("Image",{}),this.set("imageShape",t),t)},e.prototype.drawWithRange=function(t){var e=this.get("coord"),n=e.start,r=e.end,i=e.width,o=e.height,a=this.getAttr("color").field,s=this.get("heatmapSize");this._clearShadowCanvasCtx();var u=this._getShadowCanvasCtx(),l=this.get("mappedData");t&&(l=l.filter(function(e){return e._origin[a]<=t[1]&&e._origin[a]>=t[0]}));for(var c=this._getScale(a),h=0;h<l.length;h++){var f=l[h],p=this.getDrawCfg(f),d=c.scale(f._origin[a]);this._drawGrayScaleBlurredCircle(p.x,p.y,s.radius+s.blur,d,u)}var g=u.getImageData(n.x,r.y,i,o);this._clearShadowCanvasCtx(),this._colorize(g),u.putImageData(g,0,0);var v=this._getImageShape();v.attr("x",n.x),v.attr("y",r.y),v.attr("width",i),v.attr("height",o),v.attr("img",u.canvas)},e.prototype.draw=function(t){this.set("mappedData",t),this._prepareRange(),this._prepareSize();var e=this.get("heatmapSize");this._prepareGreyScaleBlurredCircle(e.radius,e.blur);var n=this.get("valueRange");this.drawWithRange(n)},e}(r);r.Heatmap=s,t.exports=s},function(t,e,n){var r=n(549),i=n(561),o=n(615),a=n(551),s=n(568),u=1/3;function l(t){var e=a.shape.edge;return r.mix({},e,{stroke:t.color,lineWidth:t.size,strokeOpacity:t.opacity,opacity:t.opacity},t.style)}var c=i.registerFactory("edge",{defaultShapeType:"line",getDefaultPoints:function(t){return o.splitPoints(t)},getActiveCfg:function(t,e){return{lineWidth:(e.lineWidth||0)+1}}});function h(t,e){var n=[];n.push({x:t.x,y:.5*t.y+1*e.y/2}),n.push({y:.5*t.y+1*e.y/2,x:e.x}),n.push(e);var i=["C"];return r.each(n,function(t){i.push(t.x,t.y)}),i}function f(t,e){var n=[];n.push({x:e.x,y:e.y}),n.push(t);var i=["Q"];return r.each(n,function(t){i.push(t.x,t.y)}),i}i.registerShape("edge","line",{draw:function(t,e){var n=this.parsePoints(t.points),i=l(t),o=s.getLinePath(n);return e.addShape("path",{attrs:r.mix(i,{path:o})})},getMarkerCfg:function(t){return r.mix({symbol:"circle",radius:4.5},l(t))}}),i.registerShape("edge","vhv",{draw:function(t,e){var n=t.points,i=l(t),o=function(t,e){var n=[];n.push({y:t.y*(1-u)+e.y*u,x:t.x}),n.push({y:t.y*(1-u)+e.y*u,x:e.x}),n.push(e);var i=[["M",t.x,t.y]];return r.each(n,function(t){i.push(["L",t.x,t.y])}),i}(n[0],n[1]);return o=this.parsePath(o),e.addShape("path",{attrs:r.mix(i,{path:o})})},getMarkerCfg:function(t){return r.mix({symbol:"circle",radius:4.5},l(t))}}),i.registerShape("edge","smooth",{draw:function(t,e){var n=t.points,i=l(t),o=function(t,e){var n=h(t,e),r=[["M",t.x,t.y]];return r.push(n),r}(n[0],n[1]);return o=this.parsePath(o),e.addShape("path",{attrs:r.mix(i,{path:o})})},getMarkerCfg:function(t){return r.mix({symbol:"circle",radius:4.5},l(t))}}),i.registerShape("edge","arc",{draw:function(t,e){var n=t.points,i=n.length>2?"weight":"normal",o=l(t),a=void 0,s=void 0;if(t.isInCircle){var u={x:0,y:1};"normal"===i?s=function(t,e,n){var r=f(e,n),i=[["M",t.x,t.y]];return i.push(r),i}(n[0],n[1],u):(o.fill=o.stroke,s=function(t,e){var n=f(t[1],e),r=f(t[3],e),i=[["M",t[0].x,t[0].y]];return i.push(r),i.push(["L",t[3].x,t[3].y]),i.push(["L",t[2].x,t[2].y]),i.push(n),i.push(["L",t[1].x,t[1].y]),i.push(["L",t[0].x,t[0].y]),i.push(["Z"]),i}(n,u)),s=this.parsePath(s),a=e.addShape("path",{attrs:r.mix(o,{path:s})})}else if("normal"===i)n=this.parsePoints(n),a=e.addShape("arc",{attrs:r.mix(o,{x:(n[1].x+n[0].x)/2,y:n[0].y,r:Math.abs(n[1].x-n[0].x)/2,startAngle:Math.PI,endAngle:2*Math.PI})});else{s=[["M",n[0].x,n[0].y],["L",n[1].x,n[1].y]];var c=h(n[1],n[3]),p=h(n[2],n[0]);s.push(c),s.push(["L",n[3].x,n[3].y]),s.push(["L",n[2].x,n[2].y]),s.push(p),s.push(["Z"]),s=this.parsePath(s),o.fill=o.stroke,a=e.addShape("path",{attrs:r.mix(o,{path:s})})}return a},getMarkerCfg:function(t){return r.mix({symbol:"circle",radius:4.5},l(t))}}),t.exports=c},function(t,e,n){var r=n(562);n(784);var i=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return e.type="edge",e.shapeType="edge",e.generatePoints=!0,e},e}(r);r.Edge=i,t.exports=i},function(t,e,n){var r=n(549),i=n(561),o=n(568),a=n(551);function s(t){var e=a.shape.hollowArea;return r.mix({},e,{stroke:t.color,lineWidth:t.size,strokeOpacity:t.opacity},t.style)}function u(t){var e=a.shape.area;return r.mix({},e,{fill:t.color,stroke:t.color,lineWidth:t.size,fillOpacity:t.opacity},t.style)}function l(t,e,n){var i=[],a=[],s=[],u=[],l=t.isInCircle;return r.each(t.points,function(t){s.push(t[1]),u.push(t[0])}),u=u.reverse(),a.push(s,u),r.each(a,function(r,a){var s=[],u=(r=n.parsePoints(r))[0];l&&r.push({x:u.x,y:u.y}),s=e?o.getSplinePath(r,!1,t.constraint):o.getLinePath(r,!1),a>0&&(s[0][0]="L"),i=i.concat(s)}),i.push(["Z"]),i}function c(t){return{symbol:function(t,e,n,r){r.save(),r.lineWidth=2,r.strokeStyle=r.fillStyle,r.moveTo(t-5.5,e-4),r.lineTo(t+5.5,e-4),r.stroke(),r.restore(),r.moveTo(t-5.5,e-4),r.lineTo(t+5.5,e-4),r.lineTo(t+5.5,e+4),r.lineTo(t-5.5,e+4),r.closePath()},radius:5,fill:t.color,fillOpacity:.3}}var h=i.registerFactory("area",{defaultShapeType:"area",getDefaultPoints:function(t){var e=[],n=t.x,i=t.y,o=t.y0;return i=r.isArray(i)?i:[o,i],r.each(i,function(t){e.push({x:n,y:t})}),e},getActiveCfg:function(t,e){return function(t,e){if("line"===t||"smoothLine"===t)return{lineWidth:(e.lineWidth||0)+1};var n=e.fillOpacity||e.opacity||1;return{fillOpacity:n-.15,strokeOpacity:n-.15}}(t,e)},drawShape:function(t,e,n){var i=this.getShape(t),o=void 0;return(o=1===e.points.length&&a.showSinglePoint?function(t,e,n){var i=t._coord.convertPoint(e.points[0][1]);return n.addShape("circle",{attrs:r.mix({x:i.x,y:i.y,r:2,fill:e.color},e.style)})}(this,e,n):i.draw(e,n))&&(o.set("origin",e.origin),o._id=e.splitedIndex?e._id+e.splitedIndex:e._id,o.name=this.name),o},getSelectedCfg:function(t,e){return e&&e.style?e.style:this.getActiveCfg(t,e)}});i.registerShape("area","area",{draw:function(t,e){var n=u(t),i=l(t,!1,this);return e.addShape("path",{attrs:r.mix(n,{path:i})})},getMarkerCfg:function(t){return c(t)}}),i.registerShape("area","smooth",{draw:function(t,e){var n=u(t),i=this._coord;t.constraint=[[i.start.x,i.end.y],[i.end.x,i.start.y]];var o=l(t,!0,this);return e.addShape("path",{attrs:r.mix(n,{path:o})})},getMarkerCfg:function(t){return c(t)}}),i.registerShape("area","line",{draw:function(t,e){var n=s(t),i=l(t,!1,this);return e.addShape("path",{attrs:r.mix(n,{path:i})})},getMarkerCfg:function(t){return c(t)}}),i.registerShape("area","smoothLine",{draw:function(t,e){var n=s(t),i=l(t,!0,this);return e.addShape("path",{attrs:r.mix(n,{path:i})})},getMarkerCfg:function(t){return c(t)}}),h.spline=h.smooth,t.exports=h},function(t,e,n){function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function i(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function o(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}var a=n(562),s=n(651),u=n(549);n(786);var l=function(t){function e(n){r(this,e);var o=i(this,t.call(this,n));return u.assign(o,s),o}return o(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return e.type="area",e.shapeType="area",e.generatePoints=!0,e.sortable=!0,e},e.prototype.draw=function(t,e,n,r){var i=this,o=this.getDrawCfg(t[0]),a=this.splitData(t);o.origin=t,u.each(a,function(t,a){o.splitedIndex=a;var s=t.map(function(t){return t.points});o.points=s;var u=n.drawShape(o.shape,o,e);i.appendShapeInfo(u,r+a)})},e}(a),c=function(t){function e(){return r(this,e),i(this,t.apply(this,arguments))}return o(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return e.hasDefaultAdjust=!0,e.adjusts=[{type:"stack"}],e},e}(l);l.Stack=c,a.Area=l,a.AreaStack=c,t.exports=l},function(t,e,n){var r=n(551);setTimeout(function(){if(r.trackable){var t=new Image,e={pg:document.URL,r:(new Date).getTime(),g2:!0,version:r.version,page_type:"syslog"},n=encodeURIComponent(JSON.stringify([e]));t.src="https://kcart.alipay.com/web/bi.do?BIProfile=merge&d="+n}},3e3)},function(t,e,n){var r=n(549),i=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){return{type:"plotBack",padding:null,background:null,plotRange:null,plotBackground:null}},e.prototype._beforeRenderUI=function(){this._calculateRange()},e.prototype._renderUI=function(){this._renderBackground(),this._renderPlotBackground()},e.prototype._renderBackground=function(){var t=this.get("background");if(t){var e=this.get("canvas"),n={x:0,y:0,width:this.get("width")||e.get("width"),height:this.get("height")||e.get("height")},i=this.get("backgroundShape");i?i.attr(n):(i=this.addShape("rect",{attrs:r.mix(n,t)}),this.set("backgroundShape",i))}},e.prototype._renderPlotBackground=function(){var t=this.get("plotBackground");if(t){var e=this.get("plotRange"),n=e.br.x-e.bl.x,i=e.br.y-e.tr.y,o=e.tl,a={x:o.x,y:o.y,width:n,height:i},s=this.get("plotBackShape");s?s.attr(a):(t.image?(a.img=t.image,s=this.addShape("image",{attrs:a})):(r.mix(a,t),s=this.addShape("rect",{attrs:a})),this.set("plotBackShape",s))}},e.prototype._convert=function(t,e){if(r.isString(t))if("auto"===t)t=0;else if(-1!==t.indexOf("%")){var n=this.get("canvas"),i=this.get("width")||n.get("width"),o=this.get("height")||n.get("height");t=parseInt(t,10)/100,t=e?t*i:t*o}return t},e.prototype._calculateRange=function(){var t=this.get("plotRange");r.isNil(t)&&(t={});var e=this.get("padding"),n=this.get("canvas"),i=this.get("width")||n.get("width"),o=this.get("height")||n.get("height"),a=r.toAllPadding(e),s=this._convert(a[0],!1),u=this._convert(a[1],!0),l=this._convert(a[2],!1),c=this._convert(a[3],!0),h=Math.min(c,i-u),f=Math.max(c,i-u),p=Math.min(o-l,s),d=Math.max(o-l,s);t.tl={x:h,y:p},t.tr={x:f,y:p},t.bl={x:h,y:d},t.br={x:f,y:d},t.cc={x:(f+h)/2,y:(d+p)/2},this.set("plotRange",t)},e.prototype.repaint=function(){return this._calculateRange(),this._renderBackground(),this._renderPlotBackground(),this},e}(n(552).Group);t.exports=i},function(t,e,n){var r=n(549),i=n(674),o=n(552).MatrixUtil.mat3;function a(t,e){var n=[];if(!1===t.get("animate"))return[];var i=t.get("children");return r.each(i,function(t){if(t.isGroup)n=n.concat(a(t,e));else if(t.isShape&&t._id){var r=t._id;(r=r.split("-")[0])===e&&n.push(t)}}),n}function s(t,e,n,r){return r?i.Action[n][r]:i.getAnimation(t,e,n)}function u(t,e,n){var o=i.getAnimateCfg(t,e);return n&&n[e]?r.deepMix({},o,n[e]):o}function l(t,e,n,i){var a=void 0,l=void 0,c=!1;if(i){var h=[],f=[];r.each(e,function(e){var n=t[e._id];n?(e.setSilent("cacheShape",n),h.push(e),delete t[e._id]):f.push(e)}),r.each(t,function(t){var e=t.name,i=t.coord,h=t._id,f=t.attrs,p=t.index,d=t.type;if(l=u(e,"leave",t.animateCfg),a=s(e,i,"leave",l.animation),r.isFunction(a)){var g=n.addShape(d,{attrs:f,index:p});if(g._id=h,g.name=e,i&&"label"!==e){var v=g.getMatrix(),y=o.multiply([],v,i.matrix);g.setMatrix(y)}c=!0,a(g,l,i)}}),r.each(h,function(t){var e=t.name,n=t.get("coord"),i=t.get("cacheShape").attrs;if(!r.isEqual(i,t.__attrs)){if(l=u(e,"update",t.get("animateCfg")),a=s(e,n,"update",l.animation),r.isFunction(a))a(t,l,n);else{var o=r.cloneDeep(t.__attrs);t.attr(i),t.animate(o,l.duration,l.easing,function(){t.setSilent("cacheShape",null)})}c=!0}}),r.each(f,function(t){var e=t.name,n=t.get("coord");l=u(e,"enter",t.get("animateCfg")),a=s(e,n,"enter",l.animation),r.isFunction(a)&&(a(t,l,n),c=!0)})}else r.each(e,function(t){var e=t.name,n=t.get("coord");l=u(e,"appear",t.get("animateCfg")),a=s(e,n,"appear",l.animation),r.isFunction(a)&&(a(t,l,n),c=!0)});return c}t.exports={execAnimation:function(t,e){var n=t.get("middlePlot"),i=t.get("backPlot"),o=t.get("_id"),s=t.get("canvas"),u=s.get(o+"caches")||[];0===u.length&&(e=!1);var c=a(n,o),h=a(i,o),f=c.concat(h);s.setSilent(o+"caches",function(t){var e={};return r.each(t,function(t){if(t._id&&!t.isClip){var n=t._id;e[n]={_id:n,type:t.get("type"),attrs:r.cloneDeep(t.__attrs),name:t.name,index:t.get("index"),animateCfg:t.get("animateCfg"),coord:t.get("coord")}}}),e}(f));l(u,e?f:c,s,e)||s.draw()}}},function(t,e,n){var r=n(549);function i(t,e){if(r.isNil(t)||r.isNil(e))return!1;var n=t.get("origin"),i=e.get("origin");return r.isNil(n)&&r.isNil(i)?r.isEqual(t,e):r.isEqual(n,i)}function o(t){t.shape&&t.shape.get("origin")&&(t.data=t.shape.get("origin"))}var a=function(){function t(e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.view=null,this.canvas=null,r.assign(this,e),this._init()}return t.prototype._init=function(){this.pixelRatio=this.canvas.get("pixelRatio")},t.prototype._getShapeEventObj=function(t){return{x:t.x/this.pixelRatio,y:t.y/this.pixelRatio,target:t.target,toElement:t.event.toElement||t.event.relatedTarget}},t.prototype._getShape=function(t,e){return this.view.get("canvas").getShape(t,e)},t.prototype._getPointInfo=function(t){var e=this.view,n={x:t.x/this.pixelRatio,y:t.y/this.pixelRatio},r=e.getViewsByPoint(n);return n.views=r,n},t.prototype._getEventObj=function(t,e,n){return{x:e.x,y:e.y,target:t.target,toElement:t.event.toElement||t.event.relatedTarget,views:n}},t.prototype.bindEvents=function(){var t=this.canvas;t.on("mousedown",r.wrapBehavior(this,"onDown")),t.on("mousemove",r.wrapBehavior(this,"onMove")),t.on("mouseleave",r.wrapBehavior(this,"onOut")),t.on("mouseup",r.wrapBehavior(this,"onUp")),t.on("click",r.wrapBehavior(this,"onClick")),t.on("dblclick",r.wrapBehavior(this,"onClick")),t.on("touchstart",r.wrapBehavior(this,"onTouchstart")),t.on("touchmove",r.wrapBehavior(this,"onTouchmove")),t.on("touchend",r.wrapBehavior(this,"onTouchend"))},t.prototype._triggerShapeEvent=function(t,e,n){if(t&&t.name&&!t.get("destroyed")){var r=this.view;if(r.isShapeInView(t)){var i=t.name+":"+e;n.view=r,n.appendInfo=t.get("appendInfo"),r.emit(i,n);var o=r.get("parent");o&&o.emit(i,n)}}},t.prototype.onDown=function(t){var e=this.view,n=this._getShapeEventObj(t);n.shape=this.currentShape,o(n),e.emit("mousedown",n),this._triggerShapeEvent(this.currentShape,"mousedown",n)},t.prototype.onMove=function(t){var e=this.view,n=this.currentShape;n&&n.get("destroyed")&&(n=null,this.currentShape=null);var r=this._getShape(t.x,t.y),a=this._getShapeEventObj(t);if(a.shape=r,o(a),e.emit("mousemove",a),this._triggerShapeEvent(r,"mousemove",a),n&&!i(n,r)){var s=this._getShapeEventObj(t);s.shape=n,s.toShape=r,o(s),this._triggerShapeEvent(n,"mouseleave",s)}if(r&&!i(n,r)){var u=this._getShapeEventObj(t);u.shape=r,u.fromShape=n,o(u),this._triggerShapeEvent(r,"mouseenter",u)}this.currentShape=r;var l=this._getPointInfo(t);0===(this.curViews||[]).length&&l.views.length&&e.emit("plotenter",this._getEventObj(t,l,l.views)),l.views.length&&((a=this._getEventObj(t,l,l.views)).shape=r,o(a),e.emit("plotmove",a)),this.curViews=l.views},t.prototype.onOut=function(t){var e=this.view,n=this._getPointInfo(t),r=this.curViews||[],i=this._getEventObj(t,n,r);0!==n.views.length||i.toElement&&"CANVAS"===i.toElement.tagName||e.emit("plotleave",i)},t.prototype.onUp=function(t){var e=this.view,n=this._getShapeEventObj(t);n.shape=this.currentShape,e.emit("mouseup",n),this._triggerShapeEvent(this.currentShape,"mouseup",n)},t.prototype.onClick=function(t){var e=this.view,n=this._getShape(t.x,t.y),i=this._getShapeEventObj(t);i.shape=n,o(i),e.emit("click",i),this._triggerShapeEvent(n,t.type,i),this.currentShape=n;var a=this._getPointInfo(t),s=a.views;if(!r.isEmpty(s)){var u=this._getEventObj(t,a,s);if(this.currentShape){var l=this.currentShape;u.shape=l,o(u)}e.emit("plotclick",u),"dblclick"===t.type&&(e.emit("plotdblclick",u),e.emit("dblclick",i))}},t.prototype.onTouchstart=function(t){var e=this.view,n=this._getShape(t.x,t.y),r=this._getShapeEventObj(t);r.shape=n,o(r),e.emit("touchstart",r),this._triggerShapeEvent(n,"touchstart",r),this.currentShape=n},t.prototype.onTouchmove=function(t){var e=this.view,n=this._getShape(t.x,t.y),r=this._getShapeEventObj(t);r.shape=n,o(r),e.emit("touchmove",r),this._triggerShapeEvent(n,"touchmove",r),this.currentShape=n},t.prototype.onTouchend=function(t){var e=this.view,n=this._getShapeEventObj(t);n.shape=this.currentShape,o(n),e.emit("touchend",n),this._triggerShapeEvent(this.currentShape,"touchend",n)},t.prototype.clearEvents=function(){var t=this.canvas;t.off("mousemove",r.getWrapBehavior(this,"onMove")),t.off("mouseleave",r.getWrapBehavior(this,"onOut")),t.off("mousedown",r.getWrapBehavior(this,"onDown")),t.off("mouseup",r.getWrapBehavior(this,"onUp")),t.off("click",r.getWrapBehavior(this,"onClick")),t.off("dblclick",r.getWrapBehavior(this,"onClick")),t.off("touchstart",r.getWrapBehavior(this,"onTouchstart")),t.off("touchmove",r.getWrapBehavior(this,"onTouchmove")),t.off("touchend",r.getWrapBehavior(this,"onTouchend"))},t}();t.exports=a},function(t,e,n){var r=n(549),i=n(617),o=n(551),a=n(552).DomUtil;function s(t,e){return t.getElementsByClassName(e)[0]}var u=function(t){function e(n){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);var r=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.call(this,n));return r._init(),r.get("items")&&r._renderTooltip(),r._renderCrosshairs(),r}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){return{x:0,y:0,items:null,showTitle:!0,crosshairs:null,plotRange:null,offset:10,timeStamp:0,containerTpl:'<div class="g2-tooltip"><div class="g2-tooltip-title"></div><ul class="g2-tooltip-list"></ul></div>',itemTpl:'<li data-index={index}><span style="background-color:{color};" class=g2-tooltip-marker></span>{name}: {value}</li>',inPlot:!0,follow:!0,enterable:!1}},e.prototype._initTooltipWrapper=function(){var t=this.get("containerTpl"),e=this.get("canvas").get("el").parentNode,n=void 0;if(/^\#/.test(t)){var r=t.replace("#","");n=document.getElementById(r)}else n=a.createDom(t),a.modifyCSS(n,this.get("g2-tooltip")),e.appendChild(n),e.style.position="relative";this.set("container",n)},e.prototype._init=function(){var t=this.get("crosshairs"),e=this.get("frontPlot"),n=this.get("backPlot"),i=void 0;t&&("rect"===t.type?(this.set("crosshairs",r.deepMix({},o.tooltipCrosshairsRect,t)),i=n.addGroup({zIndex:0})):(this.set("crosshairs",r.deepMix({},o.tooltipCrosshairsLine,t)),i=e.addGroup())),this.set("crosshairsGroup",i),this._initTooltipWrapper()},e.prototype._clearDom=function(){var t=this.get("container"),e=s(t,"g2-tooltip-title"),n=s(t,"g2-tooltip-list");e&&(e.innerHTML=""),n&&(n.innerHTML="")},e.prototype._addItem=function(t,e){var n=this.get("itemTpl"),i=r.substitute(n,r.mix({index:e},t)),o=a.createDom(i);a.modifyCSS(o,this.get("g2-tooltip-list-item"));var u=s(o,"g2-tooltip-marker");return u&&a.modifyCSS(u,this.get("g2-tooltip-marker")),o},e.prototype._renderTooltip=function(){var t=this,e=t.get("showTitle"),n=t.get("titleContent"),i=t.get("container"),o=s(i,"g2-tooltip-title"),u=s(i,"g2-tooltip-list"),l=t.get("items");t._clearDom(),o&&e&&(a.modifyCSS(o,t.get("g2-tooltip-title")),o.innerHTML=n),u&&(a.modifyCSS(u,t.get("g2-tooltip-list")),r.each(l,function(e,n){u.appendChild(t._addItem(e,n))}))},e.prototype._clearCrosshairsGroup=function(){var t=this.get("crosshairsGroup");this.set("crossLineShapeX",null),this.set("crossLineShapeY",null),this.set("crosshairsRectShape",null),t.clear()},e.prototype._renderCrosshairs=function(){var t=this.get("crosshairs"),e=this.get("canvas"),n=this.get("plotRange"),r=this.get("isTransposed");if(t)switch(this._clearCrosshairsGroup(),t.type){case"x":this._renderHorizontalLine(e,n);break;case"y":this._renderVerticalLine(e,n);break;case"cross":this._renderHorizontalLine(e,n),this._renderVerticalLine(e,n);break;case"rect":this._renderBackground(e,n);break;default:r?this._renderHorizontalLine(e,n):this._renderVerticalLine(e,n)}},e.prototype._addCrossLineShape=function(t,e){var n=this.get("crosshairsGroup").addShape("line",{attrs:t});return n.hide(),this.set("crossLineShape"+e,n),n},e.prototype._renderVerticalLine=function(t,e){var n=this.get("crosshairs").style,i=r.mix({x1:0,y1:e?e.bl.y:t.get("height"),x2:0,y2:e?e.tl.y:0},n);this._addCrossLineShape(i,"Y")},e.prototype._renderHorizontalLine=function(t,e){var n=this.get("crosshairs").style,i=r.mix({x1:e?e.bl.x:t.get("width"),y1:0,x2:e?e.br.x:0,y2:0},n);this._addCrossLineShape(i,"X")},e.prototype._renderBackground=function(t,e){var n=this.get("crosshairs").style,i=this.get("crosshairsGroup"),o=r.mix({x:e?e.tl.x:0,y:e?e.tl.y:t.get("height"),width:e?e.br.x-e.bl.x:t.get("width"),height:e?Math.abs(e.tl.y-e.bl.y):t.get("height")},n),a=i.addShape("rect",{attrs:o});return a.hide(),this.set("crosshairsRectShape",a),a},e.prototype.isContentChange=function(t,e){var n=this.get("titleContent"),i=this.get("items"),o=!(t===n&&i.length===e.length);return o||r.each(e,function(t,e){var n=i[e];if(o=t.value!==n.value||t.color!==n.color||t.name!==n.name||t.title!==n.title)return!1}),o},e.prototype.setContent=function(t,e){var n=+new Date;return this.set("items",e),this.set("titleContent",t),this.set("timeStamp",n),this._renderTooltip(),this},e.prototype.setMarkers=function(t,e){var n=this.get("markerGroup"),i=this.get("frontPlot");n?n.clear():(n=i.addGroup({zIndex:1,capture:!1}),this.set("markerGroup",n)),r.each(t,function(t){n.addShape("marker",{color:t.color,attrs:r.mix({},e,{x:t.x,y:t.y})})}),this.set("markerItems",t)},e.prototype.clearMarkers=function(){var t=this.get("markerGroup");t&&t.clear()},e.prototype.setPosition=function(t,e,n){var i=this.get("container"),o=this.get("crossLineShapeX"),s=this.get("crossLineShapeY"),u=this.get("crosshairsRectShape"),l=t,c=e,h=this.get("canvas").get("el"),f=a.getWidth(h),p=a.getHeight(h),d=this.get("offset"),g=void 0;(this.get("position")?(g=function(t,e,n,r,i){var o=r.clientWidth,a=r.clientHeight,s=0,u=0,l=20;if(i){var c=i.getBBox();s=c.width,u=c.height,t=c.x,e=c.y,l=5}switch(n){case"inside":t=t+s/2-o/2,e=e+u/2-a/2;break;case"top":t=t+s/2-o/2,e=e-a-l;break;case"left":t=t-o-l,e=e+u/2-a/2;break;case"right":t=t+s+l,e=e+u/2-a/2;break;case"bottom":default:t=t+s/2-o/2,e=e+u+l}return[t,e]}(t,e,this.get("position"),i,n),t=g[0],e=g[1]):this.get("position")||(g=function(t,e,n,r,i){var o=n.clientWidth,a=n.clientHeight;return t+o+20>r?t=(t-=o+20)<0?0:t:t+=20,e+a+20>i?(e-=a+20,e=t<0?0:e):e+=20,[t,e]}(t,e,i,f,p),t=g[0],e=g[1]),this.get("inPlot"))&&(g=function(t,e,n,r){var i=n.clientWidth,o=n.clientHeight;return t+i>r.tr.x&&(t-=i+40),t<r.tl.x&&(t=r.tl.x),e+o>r.bl.y&&(e-=o+40),e<r.tl.y&&(e=r.tl.y),[t,e]}(t,e,i,this.get("plotRange")),t=g[0],e=g[1]);if(this.get("x")!==t||this.get("y")!==e){var v=this.get("markerItems");if(r.isEmpty(v)||(l=v[0].x,c=v[0].y),s&&s.move(l,0),o&&o.move(0,c),u){var y=this.get("isTransposed"),m=this.get("items"),x=m[0],b=m[m.length-1],_=y?"y":"x",w=y?"height":"width",S=x[_];if(m.length>1&&x[_]>b[_]&&(S=b[_]),this.get("crosshairs").width)u.attr(_,S-this.get("crosshairs").width/2),u.attr(w,this.get("crosshairs").width);else if(r.isArray(x.point[_])&&!x.size){var M=x.point[_][1]-x.point[_][0];u.attr(_,x.point[_][0]),u.attr(w,M)}else d=3*x.size/4,u.attr(_,S-d),1===m.length?u.attr(w,3*x.size/2):u.attr(w,Math.abs(b[_]-x[_])+2*d)}var C=this.get("follow");i.style.left=C?t+"px":0,i.style.top=C?e+"px":0}},e.prototype.show=function(){var e=this.get("crossLineShapeX"),n=this.get("crossLineShapeY"),r=this.get("crosshairsRectShape"),i=this.get("markerGroup"),o=this.get("container"),a=this.get("canvas");e&&e.show(),n&&n.show(),r&&r.show(),i&&i.show(),t.prototype.show.call(this),o.style.visibility="visible",a.draw()},e.prototype.hide=function(){var e=this.get("container"),n=this.get("crossLineShapeX"),r=this.get("crossLineShapeY"),i=this.get("crosshairsRectShape"),o=this.get("markerGroup"),a=this.get("canvas");e.style.visibility="hidden",n&&n.hide(),r&&r.hide(),i&&i.hide(),o&&o.hide(),t.prototype.hide.call(this),a.draw()},e.prototype.destroy=function(){var e=this.get("crossLineShapeX"),n=this.get("crossLineShapeY"),r=this.get("markerGroup"),i=this.get("crosshairsRectShape"),o=this.get("container"),a=this.get("containerTpl");o&&!/^\#/.test(a)&&o.parentNode.removeChild(o),e&&e.remove(),n&&n.remove(),r&&r.remove(),i&&i.remove(),t.prototype.destroy.call(this)},e}(i);t.exports=u},function(t,e,n){var r=n(549),i=n(551),o=n(792),a=n(552).MatrixUtil.vec2,s=["line","area","path","areaStack"],u=["line","area"];function l(t,e){if(!t)return!1;return!!t.className&&-1!==(r.isNil(t.className.baseVal)?t.className:t.className.baseVal).indexOf(e)}function c(t){var e=[];return r.each(t,function(t){var n=function(t,e){var n=-1;return r.each(t,function(t,r){if(t.title===e.title&&t.name===e.name&&t.value===e.value&&t.color===e.color)return n=r,!1}),n}(e,t);-1===n?e.push(t):e[n]=t}),e}var h=function(){function t(e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),r.assign(this,e),this.timeStamp=0}return t.prototype._normalizeEvent=function(t){var e=this.chart,n=this._getCanvas(),r=n.getPointByClient(t.clientX,t.clientY),i=n.get("pixelRatio");r.x=r.x/i,r.y=r.y/i;var o=e.getViewsByPoint(r);return r.views=o,r},t.prototype._getCanvas=function(){return this.chart.get("canvas")},t.prototype._getTriggerEvent=function(){var t=this.options.triggerOn,e=void 0;return t&&"mousemove"!==t?"click"===t?e="plotclick":"none"===t&&(e=null):e="plotmove",e},t.prototype._getDefaultTooltipCfg=function(){var t=this.options,e=r.mix({},i.tooltip),n=this.chart.getAllGeoms().filter(function(t){return t.get("visible")}),o=[];r.each(n,function(t){var e=t.get("type"),n=t.get("adjusts"),i=!1;n&&r.each(n,function(t){if("symmetric"===t.type||"Symmetric"===t.type)return i=!0,!1}),-1!==r.indexOf(o,e)||i||o.push(e)});var a=void 0;return n.length&&n[0].get("coord")&&"cartesian"===n[0].get("coord").type&&1===o.length&&("interval"===o[0]&&!1!==t.shared?a={zIndex:0,crosshairs:i.tooltipCrosshairsRect}:r.indexOf(u,o[0])>-1&&(a={crosshairs:i.tooltipCrosshairsLine})),r.mix(e,a,{isTransposed:!(!n.length||!n[0].get("coord"))&&n[0].get("coord").isTransposed})},t.prototype._bindEvent=function(){var t=this.chart,e=this._getTriggerEvent();e&&(t.on(e,r.wrapBehavior(this,"onMouseMove")),t.on("plotleave",r.wrapBehavior(this,"onMouseOut")))},t.prototype._offEvent=function(){var t=this.chart,e=this._getTriggerEvent();e&&(t.off(e,r.getWrapBehavior(this,"onMouseMove")),t.off("plotleave",r.getWrapBehavior(this,"onMouseOut")))},t.prototype._setTooltip=function(t,e,n,o){var a=this.tooltip,s=this.prePoint;if(!s||s.x!==t.x||s.y!==t.y){e=c(e),this.prePoint=t;var u=this.chart,l=r.isArray(t.x)?t.x[t.x.length-1]:t.x,h=r.isArray(t.y)?t.y[t.y.length-1]:t.y;a.get("visible")||u.emit("tooltip:show",{x:l,y:h,tooltip:a});var f=e[0],p=f.title||f.name;a.isContentChange(p,e)&&(u.emit("tooltip:change",{tooltip:a,x:l,y:h,items:e}),p=e[0].title||e[0].name,a.setContent(p,e),r.isEmpty(n)?a.clearMarkers():!0===this.options.hideMarkers?a.set("markerItems",n):a.setMarkers(n,i.tooltipMarker)),a.setPosition(l,h,o),a.show()}},t.prototype.hideTooltip=function(){var t=this.tooltip,e=this.chart,n=this._getCanvas();this.prePoint=null,t.hide(),e.emit("tooltip:hide",{tooltip:t}),n.draw()},t.prototype.onMouseMove=function(t){if(!r.isEmpty(t.views)){var e=this.timeStamp,n=+new Date,i={x:t.x,y:t.y};if(n-e>16){var o=void 0;t.shape&&r.inArray(["point","interval","polygon","schema"],t.shape.name)&&(o=t.shape),this.showTooltip(i,t.views,o),this.timeStamp=n}}},t.prototype.onMouseOut=function(t){var e=this.tooltip,n=this._getCanvas();e.get("visible")&&(t&&t.target!==n||t&&t.toElement&&(l(t.toElement,"g2-tooltip")||function(t,e){for(var n=t.parentNode,r=!1;n&&n!==document.body;){if(l(n,e)){r=!0;break}n=n.parentNode}return r}(t.toElement,"g2-tooltip"))||this.hideTooltip())},t.prototype.renderTooltip=function(){var t=this;if(!t.tooltip){var e=t.chart,n=t._getCanvas(),i=t._getDefaultTooltipCfg(),a=t.options;(a=r.deepMix({plotRange:e.get("plotRange"),capture:!1,canvas:n,frontPlot:e.get("frontPlot"),backPlot:e.get("backPlot")},i,a)).crosshairs&&"rect"===a.crosshairs.type&&(a.zIndex=0),a.visible=!1,!1===a.shared&&r.isNil(a.position)&&(a.position="top");var s=new o(a);t.tooltip=s;var u=t._getTriggerEvent();if(!s.get("enterable")&&"plotmove"===u){var l=s.get("container");l&&(l.onmousemove=function(n){var r=t._normalizeEvent(n);e.emit(u,r)})}t._bindEvent()}},t.prototype.showTooltip=function(t,e,n){if(!r.isEmpty(e)&&t){this.tooltip||this.renderTooltip();var i=this.options,o=[],u=[];if(r.each(e,function(e){if(!e.get("tooltipEnable"))return!0;var n=e.get("geoms"),a=e.get("coord");r.each(n,function(e){var n=e.get("type");if(e.get("visible")&&!1!==e.get("tooltipCfg")){var l=e.get("dataArray");if(e.isShareTooltip()||!1===i.shared&&r.inArray(["area","line","path"],n))r.each(l,function(l){var c=e.findPoint(t,l);if(c){var h=e.getTipItems(c,i.title);-1!==r.indexOf(s,n)&&r.each(h,function(t){var e=t.point;if(e&&e.x&&e.y){var n=r.isArray(e.x)?e.x[e.x.length-1]:e.x,i=r.isArray(e.y)?e.y[e.y.length-1]:e.y;e=a.applyMatrix(n,i,1),t.x=e[0],t.y=e[1],t.showMarker=!0,o.push(t)}}),u=u.concat(h)}});else{var c=e.get("shapeContainer"),h=c.get("canvas").get("pixelRatio"),f=c.getShape(t.x*h,t.y*h);f&&f.get("visible")&&f.get("origin")&&(u=e.getTipItems(f.get("origin"),i.title))}}}),r.each(u,function(t){var e=t.point,n=r.isArray(e.x)?e.x[e.x.length-1]:e.x,i=r.isArray(e.y)?e.y[e.y.length-1]:e.y;e=a.applyMatrix(n,i,1),t.x=e[0],t.y=e[1]})}),u.length){var l=u[0];if(!u.every(function(t){return t.title===l.title})){var c=l,h=1/0;u.forEach(function(e){var n=a.distance([t.x,t.y],[e.x,e.y]);n<h&&(h=n,c=e)}),u=u.filter(function(t){return t.title===c.title}),o=o.filter(function(t){return t.title===c.title})}if(!1===i.shared&&u.length>1){var f=u[0],p=Math.abs(t.y-f.y);r.each(u,function(e){Math.abs(t.y-e.y)<=p&&(f=e,p=Math.abs(t.y-e.y))}),f&&f.x&&f.y&&(o=[f]),u=[f]}this._setTooltip(t,u,o,n)}else this.hideTooltip()}},t.prototype.clear=function(){var t=this.tooltip;t&&t.destroy(),this.tooltip=null,this.prePoint=null,this._offEvent()},t}();t.exports=h},function(t,e,n){var r=n(549),i=n(551),o=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return r.mix({},e,{type:"size-legend",width:100,height:200,_circleStyle:{stroke:"#4E7CCC",fill:"#fff",fillOpacity:0},textStyle:{fill:"#333",textAlign:"start",textBaseline:"middle",fontFamily:i.fontFamily}})},e.prototype._renderSliderShape=function(){var t=this.get("slider").get("backgroundElement"),e=this.get("width"),n=this.get("height"),i=this.get("inRange"),o="vertical"===this.get("layout")?[[0,0],[e,0],[e,n]]:[[0,n],[e,0],[e,n]];return this._addBackground(t,"Polygon",r.mix({points:o},i))},e.prototype._addCircle=function(t,e,n,i,o){var a=this.addGroup(),s=this.get("_circleStyle"),u=this.get("textStyle"),l=this.get("titleShape"),c=this.get("titleGap");l&&(c+=l.getBBox().height),a.addShape("circle",{attrs:r.mix({x:t,y:e+c,r:0===n?1:n},s)}),a.addShape("text",{attrs:r.mix({x:o+5,y:e+c,text:0===i?"0":i},u)})},e.prototype._renderBackground=function(){var t=1*this.get("firstItem").attrValue,e=1*this.get("lastItem").attrValue,n=(t+e)/2;this._addCircle(e,e,e,n,2*e),this._addCircle(e,2*e+8+n,n,(t+n)/2,2*e),this._addCircle(e,2*(e+8+n)+t,t,t,2*e)},e}(n(652));t.exports=o},function(t,e,n){var r=n(549),i=n(552),o=i.Group,a=i.DomUtil,s=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){return{range:null,middleAttr:null,backgroundElement:null,minHandleElement:null,maxHandleElement:null,middleHandleElement:null,currentTarget:null,layout:"vertical",width:null,height:null,pageX:null,pageY:null}},e.prototype._beforeRenderUI=function(){var t=this.get("layout"),e=this.get("backgroundElement"),n=this.get("minHandleElement"),r=this.get("maxHandleElement"),i=this.addShape("rect",{attrs:this.get("middleAttr")}),o="vertical"===t?"ns-resize":"ew-resize";this.add([e,n,r]),this.set("middleHandleElement",i),e.set("zIndex",0),i.set("zIndex",1),n.set("zIndex",2),r.set("zIndex",2),i.attr("cursor",o),n.attr("cursor",o),r.attr("cursor",o),this.sort()},e.prototype._renderUI=function(){"horizontal"===this.get("layout")?this._renderHorizontal():this._renderVertical()},e.prototype._transform=function(t){var e=this.get("range"),n=e[0]/100,r=e[1]/100,i=this.get("width"),o=this.get("height"),a=this.get("minHandleElement"),s=this.get("maxHandleElement"),u=this.get("middleHandleElement");a.initTransform(),s.initTransform(),"horizontal"===t?(u.attr({x:i*n,y:0,width:(r-n)*i,height:o}),a.translate(n*i,o),s.translate(r*i,o)):(u.attr({x:0,y:o*(1-r),width:i,height:(r-n)*o}),a.translate(i/2,(1-n)*o),s.translate(i/2,(1-r)*o))},e.prototype._renderHorizontal=function(){this._transform("horizontal")},e.prototype._renderVertical=function(){this._transform("vertical")},e.prototype._bindUI=function(){this.on("mousedown",r.wrapBehavior(this,"_onMouseDown"))},e.prototype._isElement=function(t,e){var n=this.get(e);return t===n||!!n.isGroup&&n.get("children").indexOf(t)>-1},e.prototype._getRange=function(t,e){var n=t+e;return n=(n=n>100?100:n)<0?0:n},e.prototype._updateStatus=function(t,e){var n="x"===t?this.get("width"):this.get("height");t=r.upperFirst(t);var i=this.get("range"),o=this.get("page"+t),a=this.get("currentTarget"),s=this.get("rangeStash"),u="vertical"===this.get("layout")?-1:1,l=e["page"+t],c=(l-o)/n*100*u,h=void 0;i[1]<=i[0]?(this._isElement(a,"minHandleElement")||this._isElement(a,"maxHandleElement"))&&(i[0]=this._getRange(c,i[0]),i[1]=this._getRange(c,i[0])):(this._isElement(a,"minHandleElement")&&(i[0]=this._getRange(c,i[0])),this._isElement(a,"maxHandleElement")&&(i[1]=this._getRange(c,i[1]))),this._isElement(a,"middleHandleElement")&&(h=s[1]-s[0],i[0]=this._getRange(c,i[0]),i[1]=i[0]+h,i[1]>100&&(i[1]=100,i[0]=i[1]-h)),this.emit("sliderchange",{range:i}),this.set("page"+t,l),this._renderUI(),this.get("canvas").draw()},e.prototype._onMouseDown=function(t){var e=t.currentTarget,n=t.event,r=this.get("range");n.stopPropagation(),n.preventDefault(),this.set("pageX",n.pageX),this.set("pageY",n.pageY),this.set("currentTarget",e),this.set("rangeStash",[r[0],r[1]]),this._bindCanvasEvents()},e.prototype._bindCanvasEvents=function(){var t=this.get("canvas").get("containerDOM");this.onMouseMoveListener=a.addEventListener(t,"mousemove",r.wrapBehavior(this,"_onCanvasMouseMove")),this.onMouseUpListener=a.addEventListener(t,"mouseup",r.wrapBehavior(this,"_onCanvasMouseUp"))},e.prototype._onCanvasMouseMove=function(t){"horizontal"===this.get("layout")?this._updateStatus("x",t):this._updateStatus("y",t)},e.prototype._onCanvasMouseUp=function(){this._removeDocumentEvents()},e.prototype._removeDocumentEvents=function(){this.onMouseMoveListener.remove(),this.onMouseUpListener.remove()},e}(o);t.exports=s},function(t,e,n){var r=n(549),i=n(652),o=n(616),a=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return r.mix({},e,{type:"color-legend",layout:"vertical",labelOffset:15,lineStyle:{lineWidth:1,stroke:"#fff"}})},e.prototype._renderSliderShape=function(){var t=this.get("slider").get("backgroundElement"),e=this.get("width"),n=this.get("height"),i=this.get("layout"),a=this.get("items"),s="",u=void 0;return"vertical"===i?(s+="l (90) ",r.each(a,function(t){u=o.toRGB(t.attrValue),s+=1-t.scaleValue+":"+u+" "})):(s+="l (0) ",r.each(a,function(t){u=o.toRGB(t.attrValue),s+=t.scaleValue+":"+u+" "})),this._addBackground(t,"Rect",{x:0,y:0,width:e,height:n,fill:s,strokeOpacity:0})},e.prototype._renderBackground=function(){var t=this,e=this.get("titleShape"),n=this.get("titleGap");n=e?e.getBBox().height+n:n;var i=this.get("width"),a=this.get("height"),s=this.get("layout"),u=this.get("items"),l="",c=void 0,h=[],f=this.addGroup();"vertical"===s?(l+="l (90) ",r.each(u,function(e,n){0!==n&&n!==u.length-1&&(h.push(["M",0,a-e.scaleValue*a]),h.push(["L",i,a-e.scaleValue*a])),c=o.toRGB(e.attrValue),l+=1-e.scaleValue+":"+c+" ",f.addShape("text",{attrs:r.mix({},{x:i+t.get("labelOffset")/2,y:a-e.scaleValue*a,text:t._formatItemValue(e.value)+""},t.get("textStyle"),{textAlign:"start"})})})):(l+="l (0) ",r.each(u,function(e,n){0!==n&&n!==u.length-1&&(h.push(["M",e.scaleValue*i,0]),h.push(["L",e.scaleValue*i,a])),c=o.toRGB(e.attrValue),l+=e.scaleValue+":"+c+" ",f.addShape("text",{attrs:r.mix({},{x:e.scaleValue*i,y:a+t.get("labelOffset"),text:t._formatItemValue(e.value)+""},t.get("textStyle"))})})),f.addShape("rect",{attrs:{x:0,y:0,width:i,height:a,fill:l,strokeOpacity:0}}),f.addShape("path",{attrs:r.mix({path:h},this.get("lineStyle"))}),f.move(0,n)},e}(i);t.exports=a},function(t,e,n){var r=n(549),i=n(653),o=n(552),a=o.DomUtil,s=o.Event,u=o.Group,l=n(551),c="g2-legend",h="g2-legend-list",f="g2-legend-list-item",p="g2-legend-marker";function d(t,e){return t.getElementsByClassName(e)[0]}function g(t,e){var n=t.className;return(n=n.split(" ")).indexOf(e)>-1?t:t.parentNode?t.parentNode.className===c?t.parentNode:g(t.parentNode,e):null}function v(t,e){var n=null,i=e instanceof u?e.get("value"):e;return r.each(t,function(t){if(t.value===i)return n=t,!1}),n}function y(t,e){return t.findBy(function(t){return t.name===e})}var m=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return r.mix({},e,{type:"category-legend",items:null,itemGap:5,titleGap:15,itemMarginBottom:8,itemsGroup:null,layout:"horizontal",allowAllCanceled:!1,backPadding:[0,0,0,0],checkable:!0,unCheckColor:"#ccc",background:{fill:"#fff",fillOpacity:0},itemWidth:null,textStyle:{fill:"#333",fontSize:12,textAlign:"start",textBaseline:"middle",fontFamily:l.fontFamily},_wordSpaceing:8,useHtml:!1,autoPosition:!0,container:null,containerTpl:'<div class="'+c+'"><h4 class="g2-legend-title"></h4><ul class="'+h+'"></ul></div>',_defaultItemTpl:'<li class="'+f+' item-{index} {checked}" data-color="{originColor}" data-value="{originValue}"><i class="'+p+'" style="background-color:{color};"></i><span class="g2-legend-text">{value}</span></li>',itemTpl:null,clickable:!0,selectedMode:"multiple",reversed:!1,autoWrap:!0})},e.prototype._beforeRenderUI=function(){t.prototype._beforeRenderUI.call(this)},e.prototype._renderUI=function(){this.get("useHtml")?this._renderHTML():(t.prototype._renderUI.call(this),this._renderItems(),this.get("autoWrap")&&this._adjustItems(),this._renderBack())},e.prototype._bindUI=function(){this.get("hoverable")&&(this.on("mousemove",r.wrapBehavior(this,"_onMousemove")),this.on("mouseleave",r.wrapBehavior(this,"_onMouseleave"))),this.get("clickable")&&this.on("click",r.wrapBehavior(this,"_onClick"))},e.prototype._getLegendItem=function(t){var e=t.get("parent");return e&&"legendGroup"===e.name?e:null},e.prototype._onMousemove=function(t){var e=this._getLegendItem(t.currentTarget);if(e&&e.get("checked")){var n=this.get("items"),r=new s("itemhover",t,!0,!0);r.item=v(n,e),r.checked=e.get("checked"),this.emit("itemhover",r)}else e||this.emit("itemunhover",t)},e.prototype._onMouseleave=function(t){this.emit("itemunhover",t)},e.prototype._onClick=function(t){var e=this._getLegendItem(t.currentTarget),n=this.get("items");if(e&&!e.get("destroyed")){var i=e.get("checked");if(!this.get("allowAllCanceled")&&i&&1===this.getCheckedCount())return;var o=this.get("selectedMode"),a=v(n,e),u=new s("itemclick",t,!0,!0);u.item=a,u.currentTarget=e,u.checked="single"===o||!i;var l=this.get("unCheckColor"),c=this.get("textStyle").fill,h=void 0,f=void 0,p=void 0;if("single"===o){var d=this.get("itemsGroup").get("children");r.each(d,function(t){h=y(t,"legend-marker"),f=y(t,"legend-text"),p=y(t,"legend-item"),t!==e?(h.attr("fill")&&h.attr("fill",l),h.attr("stroke")&&h.attr("stroke",l),f.attr("fill",l),h.setSilent("checked",!1),f.setSilent("checked",!1),p.setSilent("checked",!1),t.setSilent("checked",!1)):(h.attr("fill")&&h.attr("fill",a.marker.fill),h.attr("stroke")&&h.attr("stroke",a.marker.stroke),f.attr("fill",c),h.setSilent("checked",!0),f.setSilent("checked",!0),p.setSilent("checked",!0),t.setSilent("checked",!0))})}else h=y(e,"legend-marker"),f=y(e,"legend-text"),p=y(e,"legend-item"),h.attr("fill")&&h.attr("fill",i?l:a.marker.fill),h.attr("stroke")&&h.attr("stroke",i?l:a.marker.stroke),f.attr("fill",i?l:c),e.setSilent("checked",!i),h.setSilent("checked",!i),f.setSilent("checked",!i),p.setSilent("checked",!i);this.emit("itemclick",u)}},e.prototype._renderHTML=function(){var t=this,e=this,n=e.get("canvas").get("el").parentNode,i=this.get("title"),o=e.get("containerTpl"),s=a.createDom(o),u=d(s,"g2-legend-title"),y=d(s,h),m=e.get("unCheckColor"),x=e.get("selectedMode"),b=l.legend.html,_=e.get("container");if(/^\#/.test(_)){var w=_.replace("#","");(_=document.getElementById(w)).appendChild(s)}else{var S=e.get("position"),M=e.get("canvas"),C={};C="left"===S||"right"===S?{maxHeight:(e.get("maxLength")||M.get("height"))+"px"}:{maxWidth:(e.get("maxLength")||M.get("width"))+"px"},a.modifyCSS(s,r.mix({},b[c],C,e.get(c))),n.appendChild(s)}a.modifyCSS(y,r.mix({},b[h],e.get(h))),u&&(i&&i.text?(u.innerHTML=i.text,a.modifyCSS(u,r.mix({},b["g2-legend-title"],e.get("g2-legend-title")))):s.removeChild(u));var P=e.get("items"),A=e.get("_defaultItemTpl"),I=e.get("itemTpl");I&&I!==A&&(A=I),e.get("reversed")&&P.reverse();var O=e.get("position"),E=r.mix({},b[f],{display:"right"===O||"left"===O?"block":"inline-block"},e.get(f)),T=r.mix({},b[p],e.get(p));if(r.each(P,function(t,n){var i=t.checked,o=e._formatItemValue(t.value),s=t.marker.fill||t.marker.stroke,u=i?s:m,l=void 0;l=r.isFunction(A)?A(o,u,i,n):A;var c=r.substitute(l,{index:n,checked:i?"checked":"unChecked",value:o,color:u,originColor:s,originValue:t.value}),h=a.createDom(c),f=d(h,p);a.modifyCSS(h,E),f&&a.modifyCSS(f,T),i||(h.style.color=m,f&&(f.style.backgroundColor=m)),y.appendChild(h)}),e.get("clickable")){var k=y.childNodes;s.onclick=function(n){var i=n.target,o=i.className;if(!((o=o.split(" ")).indexOf(c)>-1||o.indexOf(h)>-1)){var a=g(i,f),s=d(a,"g2-legend-text"),u=d(a,p),l=v(P,a.getAttribute("data-value"));if(l){var y=a.className,b=a.getAttribute("data-color");if("single"===x)l.checked=!0,r.each(k,function(t){t!==a?(d(t,p).style.backgroundColor=m,t.className=r.replace(t.className,"checked","unChecked"),t.style.color=m,v(P,t.getAttribute("data-value")).checked=!1):(s&&(s.style.color=e.get("textStyle").fill),u&&(u.style.backgroundColor=b),a.className=r.replace(y,"unChecked","checked"))});else{var _=y.includes("checked"),w=0;if(r.each(k,function(t){t.className.includes("checked")&&w++}),!t.get("allowAllCanceled")&&_&&1===w)return;l.checked=!l.checked,_?(u&&(u.style.backgroundColor=m),a.className=r.replace(y,"checked","unChecked"),a.style.color=m):(u&&(u.style.backgroundColor=b),a.className=r.replace(y,"unChecked","checked"),a.style.color=e.get("textStyle").fill)}e.emit("itemclick",{item:l,currentTarget:a,checked:"single"===x||l.checked})}}}}e.get("hoverable")&&(s.onmousemove=function(t){var n=t.target,r=n.className;if(!((r=r.split(" ")).indexOf(c)>-1||r.indexOf(h)>-1)){var i=g(n,f),o=i.className,a=v(P,i.getAttribute("data-value"));a&&o.includes("checked")?e.emit("itemhover",{item:a,currentTarget:i,checked:a.checked}):a||e.emit("itemunhover",t)}},s.onmouseout=function(t){e.emit("itemunhover",t)}),e.set("legendWrapper",s)},e.prototype._renderItems=function(){var t=this,e=t.get("items");t.get("reversed")&&e.reverse(),r.each(e,function(e,n){t._addItem(e,n)})},e.prototype._renderBack=function(){var t=this.get("backPadding"),e=this.get("background");this.renderBack(t,e)},e.prototype._formatItemValue=function(t){var e=this.get("itemFormatter");return e&&(t=e.call(this,t)),t},e.prototype._getNextX=function(){var t=this.get("layout"),e=this.get("itemGap"),n=this.get("itemsGroup"),i=this.get("itemWidth"),o=n.get("children"),a=0;return"horizontal"===t&&r.each(o,function(t){a+=(i||t.getBBox().width)+e}),a},e.prototype._getNextY=function(){var t=this.get("itemMarginBottom"),e=this.get("titleShape")?this.get("titleGap"):0,n=this.get("layout"),i=this.get("itemsGroup"),o=this.get("titleShape"),a=i.get("children"),s=e;return o&&(s+=o.getBBox().height),"vertical"===n&&r.each(a,function(e){s+=e.getBBox().height+t}),s},e.prototype._addItem=function(t){var e=this.get("itemsGroup"),n=this._getNextX(),i=this._getNextY(),o=this.get("unCheckColor"),a=e.addGroup({x:n,y:i,value:t.value,checked:t.checked});a.set("viewId",e.get("viewId"));var s=this.get("textStyle"),u=this.get("_wordSpaceing"),l=0;if(t.marker){var c=r.mix({},t.marker,{x:t.marker.radius+n,y:i});t.checked||(c.fill&&(c.fill=o),c.stroke&&(c.stroke=o));var h=a.addShape("marker",{type:"marker",attrs:c});h.attr("cursor","pointer"),h.name="legend-marker",l+=h.getBBox().width+u}var f=r.mix({},s,{x:l+n,y:i,text:this._formatItemValue(t.value)});t.checked||r.mix(f,{fill:o});var p=a.addShape("text",{attrs:f});p.attr("cursor","pointer"),p.name="legend-text",this.get("appendInfo")&&p.setSilent("appendInfo",this.get("appendInfo"));var d=a.getBBox(),g=this.get("itemWidth"),v=a.addShape("rect",{attrs:{x:n,y:i-d.height/2,fill:"#fff",fillOpacity:0,width:g||d.width,height:d.height}});return v.attr("cursor","pointer"),v.setSilent("origin",t),v.name="legend-item",this.get("appendInfo")&&v.setSilent("appendInfo",this.get("appendInfo")),a.name="legendGroup",a},e.prototype._adjustHorizontal=function(){var t=this.get("itemsGroup"),e=t.get("children"),n=this.get("maxLength"),i=this.get("itemGap"),o=this.get("itemMarginBottom"),a=this.get("titleShape")?this.get("titleGap"):0,s=0,u=0,l=void 0,c=void 0,h=void 0,f=this.get("itemWidth");t.getBBox().width>n&&r.each(e,function(t){h=t.getBBox(),l=f||h.width,c=h.height+o,n-u<l&&(s++,u=0),t.move(u,s*c+a),u+=l+i})},e.prototype._adjustVertical=function(){var t=this.get("itemsGroup"),e=this.get("titleShape"),n=t.get("children"),i=this.get("maxLength"),o=this.get("itemGap"),a=this.get("itemMarginBottom"),s=this.get("titleGap"),u=e?e.getBBox().height+s:0,l=this.get("itemWidth"),c=u,h=void 0,f=void 0,p=void 0,d=0,g=0;t.getBBox().height>i&&r.each(n,function(t){p=t.getBBox(),h=p.width,f=p.height,l?d=l+o:h>d&&(d=h+o),i-c<f?(c=u,g+=d,t.move(g,u)):t.move(g,c),c+=f+a})},e.prototype._adjustItems=function(){"horizontal"===this.get("layout")?this._adjustHorizontal():this._adjustVertical()},e.prototype.getWidth=function(){return this.get("useHtml")?a.getOuterWidth(this.get("legendWrapper")):t.prototype.getWidth.call(this)},e.prototype.getHeight=function(){return this.get("useHtml")?a.getOuterHeight(this.get("legendWrapper")):t.prototype.getHeight.call(this)},e.prototype.move=function(e,n){this.get("useHtml")&&!/^\#/.test(this.get("container"))?a.modifyCSS(this.get("legendWrapper"),{left:e+"px",top:n+"px"}):t.prototype.move.call(this,e,n)},e.prototype.remove=function(){if(this.get("useHtml")){var e=this.get("legendWrapper");e&&e.parentNode&&e.parentNode.removeChild(e)}t.prototype.remove.call(this)},e}(i);t.exports=m},function(t,e,n){t.exports={Category:n(797),Color:n(796),Size:n(794)}},function(t,e,n){var r=n(549),i=n(551),o=n(798),a=n(561),s=window.requestAnimationFrame||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame||window.msRequestAnimationFrame;var u=function(){function t(e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.options={},r.mix(this,e),this.clear();var n=this.chart;this.container=n.get("frontPlot"),this.plotRange=n.get("plotRange")}return t.prototype.clear=function(){var t=this.legends;this.backRange=null,r.each(t,function(t){r.each(t,function(t){t.remove()})}),this.legends={}},t.prototype.getBackRange=function(){var t=this.backRange;if(!t){if((t=this.chart.get("backPlot").getBBox()).minX===1/0){var e=this.plotRange;t={minX:e.tl.x,minY:e.tl.y,maxX:e.br.x,maxY:e.br.y}}this.backRange=t}return t},t.prototype._isFieldInView=function(t,e,n){var i=!1,o=n.get("scales")[t];return o&&o.values&&(i=r.inArray(o.values,e)),i},t.prototype._bindClickEvent=function(t,e,n){var i=this,o=i.chart,a=o.get("views"),s=e.field,u=i.options;t.on("itemclick",function(e){if(u.onClick)u.onClick(e);else{var l=e.item,c=e.checked,h="single"===t.get("selectedMode"),f=l.dataValue;c?(n.push(f),i._isFieldInView(s,f,o)&&o.filter(s,function(t){return h?t===f:r.inArray(n,t)}),r.each(a,function(t){i._isFieldInView(s,f,t)&&t.filter(s,function(t){return h?t===f:r.inArray(n,t)})})):h||(r.Array.remove(n,f),i._isFieldInView(s,f,o)&&o.filter(s,function(t){return r.inArray(n,t)}),r.each(a,function(t){i._isFieldInView(s,f,t)&&t.filter(s,function(t){return r.inArray(n,t)})})),o.set("keepLegend",!0),o.set("keepPadding",!0),o.repaint(),o.set("keepPadding",!1),o.set("keepLegend",!1)}})},t.prototype._filterLabels=function(t,e,n){if(t.get("gLabel"))t.get("gLabel").set("visible",n);else{var i=e.get("labelCfg");if(i&&i.fields&&i.fields.length>0){var o=e.getXScale(),a=e.getYScale(),s=o.field,u=a.field,l=t.get("origin")._origin,c=e.get("labelContainer").get("labelsGroup").get("children");r.each(c,function(e){var r=e.get("origin")||[];r[s]===l[s]&&r[u]===l[u]&&(e.set("visible",n),t.set("gLabel",e))})}}},t.prototype._bindFilterEvent=function(t,e){var n=this,r=this.chart,i=e.field;t.on("itemfilter",function(t){var e=t.range;r.filterShape(function(t,r,o){if(t[i]){var a=t[i]>=e[0]&&t[i]<=e[1];return n._filterLabels(r,o,a),a}return!0});for(var o=r.getAllGeoms()||[],a=function(t){var n=o[t];"heatmap"===n.get("type")&&s(function(){n.drawWithRange(e)})},u=0;u<o.length;u++)a(u)})},t.prototype._getShapeData=function(t){var e=t.get("origin");return r.isArray(e)&&(e=e[0]),e._origin},t.prototype._bindHoverEvent=function(t,e){var n=this,i=n.chart,o=i.getAllGeoms(),a=n.options,s=i.get("canvas");t.on("itemhover",function(t){var i=t.item.value,u=n.pre;if(u){if(u===i)return}else r.each(o,function(o){var u=o.get("shapeContainer"),l=o.getShapes(),c=[];if(e){var h=o.get("scales")[e];r.each(l,function(t){var o=n._getShapeData(t);o&&function(t,e,n){return!r.isNil(n)&&(t=n.translate(t),e=n.translate(e),n.isCategory?t===e:Math.abs(t-e)<=1)}(o[e],i,h)&&c.push(t)})}else o.getYScale().field===i&&(c=l);r.isEmpty(c)||(t.shapes=c,t.geom=o,a.onHover?(a.onHover(t),u.sort(),s.draw()):o.setShapesActived(c))}),n.pre=i}),t.on("itemunhover",function(){n.pre=null,r.each(o,function(t){t.get("activeShapes")&&(t.clearActivedShapes(),s.draw())})})},t.prototype._isFiltered=function(t,e,n){if(!t.isCategory)return!0;var i=!1;return n=t.invert(n),r.each(e,function(e){if(i=i||t.getText(e)===t.getText(n))return!1}),i},t.prototype._alignLegend=function(t,e,n,r){var o=this.container.get("canvas"),a=o.get("width"),s=o.get("height"),u=this.plotRange,l=this.getBackRange(),c=t.get("offsetX")||0,h=t.get("offsetY")||0,f=t.getHeight(),p=t.getWidth(),d=i.legend.margin,g=i.legend.legendMargin,v=0,y=0;if("left"===r||"right"===r)s=u.br.y,v="left"===r?l.minX-p-d[3]:l.maxX+d[1],y=s-f,e&&(y=e.get("y")-f-g);else if(v=(a-n.totalWidth)/2,y="top"===r?l.minY-f-d[0]:l.maxY+d[2],e){var m=e.getWidth();v=e.get("x")+m+g}t.move(v+c,y+h)},t.prototype._getRegion=function(t){var e=0,n=0;return r.each(t,function(t){var r=t.getWidth();e<r&&(e=r),n+=r}),{maxWidth:e,totalWidth:n}},t.prototype._addCategroyLegend=function(t,e,n,s,u){var l=this,c=t.field,h=l.options,f=l.legends;f[u]=f[u]||[];var p=l.container,d=[],g=t.getTicks(),v=!0,y=n.get("shapeType")||"point",m=n.getDefaultValue("shape")||"circle";h[c]&&h[c].marker?(m=h[c].marker,y="point",v=!1):h.marker&&(m=h.marker,y="point",v=!1);var x=l.chart,b=x.get("canvas"),_=l.plotRange,w="right"===u||"left"===u?_.bl.y-_.tr.y:b.get("width");r.each(g,function(e){var o=e.text,u=e.value,c=t.invert(u),h={isInCircle:n.isInCircle()},f=!s||l._isFiltered(t,s,u),p=n.getAttr("color"),g=n.getAttr("shape");if(p)if(p.callback&&p.callback.length>1){var x=Array(p.callback.length-1).fill("");h.color=p.mapping.apply(p,[c].concat(x)).join("")||i.defaultColor}else h.color=p.mapping(c).join("")||i.defaultColor;if(v&&g)if(g.callback&&g.callback.length>1){var b=Array(g.callback.length-1).fill("");m=g.mapping.apply(g,[c].concat(b)).join("")}else m=g.mapping(c).join("");var _=a.getShapeFactory(y).getMarkerCfg(m,h);r.isFunction(m)&&(_.symbol=m),d.push({value:o,dataValue:c,checked:f,marker:_})});var S=r.deepMix({},i.legend[u],h[c]||h,{viewId:x.get("_id"),maxLength:w,items:d});S.title&&r.deepMix(S,{title:{text:t.alias||t.field}});var M=p.addGroup(o.Category,S);return l._bindClickEvent(M,t,s),f[u].push(M),M},t.prototype._addContinuousLegend=function(t,e,n){var a=this.legends;a[n]=a[n]||[];var s=this.container,u=t.field,l=t.getTicks(),c=[],h=void 0,f=void 0,p=void 0;r.each(l,function(n){var r=n.value,i=t.invert(r),o=e.mapping(i).join("");c.push({value:n.tickValue,attrValue:o,scaleValue:r}),0===r&&(f=!0),1===r&&(p=!0)}),f||c.push({value:t.min,attrValue:e.mapping(0).join(""),scaleValue:0}),p||c.push({value:t.max,attrValue:e.mapping(1).join(""),scaleValue:1});var d=this.options,g=i.legend[n];(d&&!1===d.slidable||d[u]&&!1===d[u].slidable)&&(g=r.mix({},g,i.legend.gradient));var v=r.deepMix({},g,d[u]||d,{items:c,attr:e,numberFormatter:t.formatter});return v.title&&r.deepMix(v,{title:{text:t.alias||t.field}}),"color"===e.type?h=s.addGroup(o.Color,v):"size"===e.type&&(h=s.addGroup(o.Size,v)),this._bindFilterEvent(h,t),a[n].push(h),h},t.prototype.addLegend=function(t,e,n,r){var o=this.options,a=t.field,s=o[a];if(!1===s)return null;if(s&&s.custom)this.addCustomLegend(a);else{var u=o.position||i.defaultLegendPosition;s&&s.position&&(u=s.position);var l=void 0;l=t.isLinear?this._addContinuousLegend(t,e,u):this._addCategroyLegend(t,e,n,r,u),this._bindHoverEvent(l,a)}},t.prototype.addCustomLegend=function(t){var e=this.chart,n=this.container,a=this.options;t&&(a=a[t]);var s=a.position||i.defaultLegendPosition,u=this.legends;u[s]=u[s]||[];var l=a.items;if(l){var c=e.getAllGeoms();r.each(l,function(t){var e=function(t,e){var n=void 0;return r.each(t,function(t){t.get("visible")&&t.getYScale().field===e&&(n=t)}),n}(c,t.value);r.isObject(t.marker)?t.marker.radius=t.marker.radius||4.5:t.marker={symbol:t.marker?t.marker:"circle",fill:t.fill,radius:4.5},t.checked=!!r.isNil(t.checked)||t.checked,t.geom=e});var h=e.get("canvas"),f=this.plotRange,p="right"===s||"left"===s?f.bl.y-f.tr.y:h.get("width"),d=r.deepMix({},i.legend[s],a,{maxLength:p,items:l}),g=n.addGroup(o.Category,d);u[s].push(g),g.on("itemclick",function(t){a.onClick&&a.onClick(t)}),this._bindHoverEvent(g)}},t.prototype.alignLegends=function(){var t=this,e=t.legends;return r.each(e,function(e,n){var i=t._getRegion(e);r.each(e,function(r,o){var a=e[o-1];r.get("useHtml")&&!r.get("autoPosition")||t._alignLegend(r,a,i,n)})}),this},t}();t.exports=u},function(t,e,n){var r=n(549),i=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return r.mix({},e,{type:"arc",start:null,end:null,style:{stroke:"#999",lineWidth:1}})},e.prototype.render=function(t,e){var n=this.parsePoint(t,this.start),i=this.parsePoint(t,this.end),o=t.getCenter(),a=Math.sqrt((n.x-o.x)*(n.x-o.x)+(n.y-o.y)*(n.y-o.y)),s=Math.atan2(n.y-o.y,n.x-o.x),u=Math.atan2(i.y-o.y,i.x-o.x),l=e.addShape("arc",{zIndex:this.zIndex,attrs:r.mix({x:o.x,y:o.y,r:a,startAngle:s,endAngle:u},this.style)});l.name="guide-arc",this.appendInfo&&l.setSilent("appendInfo",this.appendInfo),this.el=l},e}(n(572));t.exports=i},function(t,e,n){var r=n(549),i=n(552).DomUtil,o=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return r.mix({},e,{type:"html",zIndex:7,position:null,alignX:"middle",alignY:"middle",offsetX:null,offsetY:null,html:null})},e.prototype.render=function(t,e){var n=this.parsePoint(t,this.position),o=e.get("canvas").get("el").parentNode,a=i.createDom('<div class="g-guide"></div>');o.appendChild(a);var s=this.html;r.isFunction(s)&&(s=s(this.xScales,this.yScales));var u=i.createDom(s);a.appendChild(u),this._setDomPosition(a,u,n),this.el=a},e.prototype._setDomPosition=function(t,e,n){var o=this.alignX,a=this.alignY,s=i.getOuterWidth(e),u=i.getOuterHeight(e),l={x:n.x,y:n.y};"middle"===o&&"top"===a?l.x-=r.round(s/2):"middle"===o&&"bottom"===a?(l.x-=r.round(s/2),l.y-=r.round(u)):"left"===o&&"bottom"===a?l.y-=r.round(u):"left"===o&&"middle"===a?l.y-=r.round(u/2):"left"===o&&"top"===a?(l.x=n.x,l.y=n.y):"right"===o&&"bottom"===a?(l.x-=r.round(s),l.y-=r.round(u)):"right"===o&&"middle"===a?(l.x-=r.round(s),l.y-=r.round(u/2)):"right"===o&&"top"===a?l.x-=r.round(s):(l.x-=r.round(s/2),l.y-=r.round(u/2)),this.offsetX&&(l.x+=this.offsetX),this.offsetY&&(l.y+=this.offsetY),i.modifyCSS(t,{position:"absolute",top:Math.round(l.y)+"px",left:Math.round(l.x)+"px",visibility:"visible",zIndex:this.zIndex})},e.prototype.remove=function(){var t=this.el;t&&t.parentNode.removeChild(t)},e}(n(572));t.exports=o},function(t,e,n){var r=n(549),i=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return r.mix({},e,{type:"region",zIndex:1,start:null,end:null,style:{lineWidth:0,fill:"#CCD7EB",opacity:.4}})},e.prototype.render=function(t,e){var n=this.style,i=this._getPath(t),o=e.addShape("path",{zIndex:this.zIndex,attrs:r.mix({path:i},n)});o.name="guide-region",this.appendInfo&&o.setSilent("appendInfo",this.appendInfo),this.el=o},e.prototype._getPath=function(t){var e=this.parsePoint(t,this.start),n=this.parsePoint(t,this.end),r=[];return r.push(["M",e.x,e.y]),r.push(["L",n.x,e.y]),r.push(["L",n.x,n.y]),r.push(["L",e.x,n.y]),r.push(["z"]),r},e}(n(572));t.exports=i},function(t,e,n){var r=n(549),i=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return r.mix({},e,{type:"image",zIndex:1,start:null,end:null,src:null,offsetX:null,offsetY:null})},e.prototype.render=function(t,e){var n=this.parsePoint(t,this.start),r={x:n.x,y:n.y};if(r.img=this.src,this.end){var i=this.parsePoint(t,this.end);r.width=Math.abs(i.x-n.x),r.height=Math.abs(n.y-i.y)}else this.width&&(r.width=this.width),this.height&&(r.height=this.height);this.offsetX&&(r.x+=this.offsetX),this.offsetY&&(r.y+=this.offsetY);var o=e.addShape("Image",{zIndex:1,attrs:r});o.name="guide-image",this.appendInfo&&o.setSilent("appendInfo",this.appendInfo),this.el=o},e}(n(572));t.exports=i},function(t,e,n){var r=n(549),i=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return r.mix({},e,{type:"text",position:null,content:null,style:{fill:"#999",fontSize:12,fontWeight:500,textAlign:"center"},offsetX:null,offsetY:null})},e.prototype.render=function(t,e){var n=this.position,i=this.parsePoint(t,n),o=r.mix({},this.style);this.offsetX&&(i.x+=this.offsetX),this.offsetY&&(i.y+=this.offsetY),o.rotate&&(o.rotate=o.rotate*Math.PI/180);var a=e.addShape("Text",{zIndex:this.zIndex,attrs:r.mix({text:this.content},o,i)});a.name="guide-text",this.appendInfo&&a.setSilent("appendInfo",this.appendInfo),this.el=a},e}(n(572));t.exports=i},function(t,e,n){var r=n(549),i=n(572),o=n(552).MatrixUtil.vec2,a=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return r.mix({},e,{type:"line",start:null,end:null,lineStyle:{stroke:"#000",lineWidth:1},text:{position:"end",autoRotate:!0,style:{fill:"#999",fontSize:12,fontWeight:500,fontFamily:"sans-serif"},content:null}})},e.prototype.render=function(t,e){var n=this.parsePoint(t,this.start),r=this.parsePoint(t,this.end),i=e.addGroup();this._drawLines(n,r,i),this.text&&this.text.content&&this._drawText(n,r,i),this.el=i},e.prototype._drawLines=function(t,e,n){var i=[["M",t.x,t.y],["L",e.x,e.y]],o=n.addShape("Path",{attrs:r.mix({path:i},this.lineStyle)});o.name="guide-line",this.appendInfo&&o.setSilent("appendInfo",this.appendInfo)},e.prototype._drawText=function(t,e,n){var i=this.text,a=i.position,s=i.style,u=void 0;((u="start"===a?0:"center"===a?.5:r.isString(a)&&-1!==a.indexOf("%")?parseInt(a,10)/100:r.isNumber(a)?a:1)>1||u<0)&&(u=1);var l={x:t.x+(e.x-t.x)*u,y:t.y+(e.y-t.y)*u};if(i.offsetX&&(l.x+=i.offsetX),i.offsetY&&(l.y+=i.offsetY),l.text=i.content,l=r.mix({},l,s),i.autoRotate&&r.isNil(s.rotate)){var c=o.angleTo([e.x-t.x,e.y-t.y],[1,0],1);l.rotate=c}else r.isNil(s.rotate)||(l.rotate=s.rotate*Math.PI/180);var h=n.addShape("Text",{attrs:l});h.name="guide-line-text",this.appendInfo&&h.setSilent("appendInfo",this.appendInfo)},e}(i);t.exports=a},function(t,e,n){t.exports={Line:n(805),Text:n(804),Image:n(803),Region:n(802),Html:n(801),Arc:n(800)}},function(t,e,n){var r=n(549),i=n(806),o=n(551),a=function(){function t(e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.guides=[],this.options=[],this.xScales=null,this.yScales=null,this.container=null,r.mix(this,e)}return t.prototype._creatGuides=function(){var t=this,e=this.options,n=this.xScales,a=this.yScales;return e.forEach(function(e){var s=e.type,u=r.deepMix({xScales:n,yScales:a},o.guide[s],e);s=r.upperFirst(s);var l=new i[s](u);t.guides.push(l)}),t.guides},t.prototype.line=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return this.options.push(r.mix({type:"line"},t)),this},t.prototype.arc=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return this.options.push(r.mix({type:"arc"},t)),this},t.prototype.text=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return this.options.push(r.mix({type:"text"},t)),this},t.prototype.image=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return this.options.push(r.mix({type:"image"},t)),this},t.prototype.region=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return this.options.push(r.mix({type:"region"},t)),this},t.prototype.html=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return this.options.push(r.mix({type:"html"},t)),this},t.prototype.render=function(t){var e=this,n=e._creatGuides(),i=e.backContainer;r.each(n,function(n){n.top&&(i=e.frontContainer),n.render(t,i)})},t.prototype.clear=function(){this.options=[],this.reset()},t.prototype.changeVisible=function(t){var e=this.guides;r.each(e,function(e){e.setVisible(t)})},t.prototype.reset=function(){var t=this.guides;r.each(t,function(t){t.remove()}),this.guides=[]},t}();t.exports=a},function(t,e,n){var r=n(549),i=n(591),o=n(552),a=o.MatrixUtil,s=o.PathUtil,u=a.vec2,l=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return r.mix({},e,{type:"polyline"})},e.prototype.getLinePath=function(){var t=this.get("tickPoints"),e=this.get("start"),n=this.get("end"),i=[];i.push(e.x),i.push(e.y),r.each(t,function(t){i.push(t.x),i.push(t.y)}),i.push(n.x),i.push(n.y);var o=s.catmullRomToBezier(i);return o.unshift(["M",e.x,e.y]),o},e.prototype.getTickPoint=function(t,e){return this.get("tickPoints")[e]},e.prototype.getTickEnd=function(t,e,n){var r=this.get("tickLine"),i=e||r.length,o=this.getSideVector(i,t,n);return{x:t.x+o[0],y:t.y+o[1]}},e.prototype.getSideVector=function(t,e,n){var r=void 0;0===n?r=this.get("start"):r=this.get("tickPoints")[n-1];var i=[e.x-r.x,e.y-r.y],o=u.normalize([],i),a=u.vertical([],o,!1);return u.scale([],a,t)},e}(i);t.exports=l},function(t,e,n){var r=n(549),i=n(591),o=n(552),a=o.MatrixUtil,s=o.PathUtil,u=a.vec2,l=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return r.mix({},e,{type:"helix",line:{lineWidth:1,stroke:"#C0D0E0"},tickLine:{lineWidth:1,stroke:"#C0D0E0",length:5},startAngle:1.25*Math.PI,endAngle:7.25*Math.PI,a:0,center:null,axisStart:null,crp:[]})},e.prototype.getLinePath=function(){var t=this.get("crp"),e=this.get("axisStart"),n=s.catmullRomToBezier(t);return n.unshift(["M",e.x,e.y]),n},e.prototype.getTickPoint=function(t){var e=this.get("startAngle"),n=e+(this.get("endAngle")-e)*t;return this._getHelixPoint(n)},e.prototype._getHelixPoint=function(t){var e=this.get("center"),n=this.get("a")*t+this.get("inner");return{x:e.x+Math.cos(t)*n,y:e.y+Math.sin(t)*n}},e.prototype.getSideVector=function(t,e){var n=this.get("center"),r=[e.x-n.x,e.y-n.y];if(t){var i=u.length(r);u.scale(r,r,t/i)}return r},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.getTickEnd=function(t,e){var n=this.get("tickLine");return e=e||n.length,this.getSidePoint(t,e)},e}(i);t.exports=l},function(t,e,n){var r=n(549),i=n(591),o=n(552).MatrixUtil.vec2,a=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return r.mix({},e,{type:"circle",tickInterval:null,startAngle:-Math.PI/2,endAngle:3*Math.PI/2,line:{lineWidth:1,stroke:"#C0D0E0"},tickLine:{lineWidth:1,stroke:"#C0D0E0",length:5},_labelOffset:5})},e.prototype.parseTick=function(t,e,n){return{text:t,value:e/n}},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.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];if(!r.isNil(t)){var a=o.length(i);o.scale(i,i,t/a)}return i},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.getTickEnd=function(t,e){var n=this.get("tickLine");return e=e||n.length,this.getSidePoint(t,e)},e.prototype.getTextAnchor=function(t){var e=void 0;return r.snapEqual(t[0],0)?e="center":t[0]>0?e="left":t[0]<0&&(e="right"),e},e.prototype.getLinePath=function(){var t=this.get("center"),e=t.x,n=t.y,r=this.get("radius"),i=r,o=this.get("startAngle"),a=this.get("endAngle"),s=this.get("inner"),u=[];if(Math.abs(a-o)===2*Math.PI)u=[["M",e,n],["m",0,-i],["a",r,i,0,1,1,0,2*i],["a",r,i,0,1,1,0,-2*i],["z"]];else{var l=this._getCirclePoint(o),c=this._getCirclePoint(a),h=Math.abs(a-o)>Math.PI?1:0,f=o>a?0:1;if(s){var p=this.getSideVector(s*r,l),d=this.getSideVector(s*r,c),g={x:p[0]+e,y:p[1]+n},v={x:d[0]+e,y:d[1]+n};u=[["M",g.x,g.y],["L",l.x,l.y],["A",r,i,0,h,f,c.x,c.y],["L",v.x,v.y],["A",r*s,i*s,0,h,Math.abs(f-1),g.x,g.y]]}else u=[["M",e,n],["L",l.x,l.y],["A",r,i,0,h,f,c.x,c.y],["L",e,n]]}return u},e.prototype.addLabel=function(e,n,r){var i=this.get("label").offset||this.get("_labelOffset")||.001;n=this.getSidePoint(n,i),t.prototype.addLabel.call(this,e,n,r)},e.prototype.autoRotateLabels=function(){var t=this.get("ticks"),e=this.get("labelsGroup");if(e&&t.length>12){var n=this.get("radius"),i=this.get("startAngle"),o=this.get("endAngle")-i,a=o/(t.length-1),s=Math.sin(a/2)*n*2,u=this.getMaxLabelWidth(e);r.each(e.get("children"),function(e,n){var r=t[n].value*o+i,a=r%(2*Math.PI);u<s?(a<=0&&(r+=Math.PI),a>Math.PI&&(r-=Math.PI),r-=Math.PI/2,e.attr("textAlign","center")):a>Math.PI/2?r-=Math.PI:a<Math.PI/2*-1&&(r+=Math.PI),e.rotateAtStart(r)})}},e}(i);t.exports=a},function(t,e,n){var r=n(552).Group,i=n(549),o=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){return{zIndex:1,type:"line",lineStyle:null,items:null,alternateColor:null,matrix:null,hideFirstLine:!1,hideLastLine:!1}},e.prototype._renderUI=function(){t.prototype._renderUI.call(this),this._drawLines()},e.prototype._drawLines=function(){var t=this.get("lineStyle"),e=this.get("items");e&&e.length&&(this._precessItems(e),this._drawGridLines(e,t))},e.prototype._precessItems=function(t){var e=this,n=void 0;i.each(t,function(t,r){n&&e.get("alternateColor")&&e._drawAlternativeBg(t,n,r),n=t})},e.prototype._drawGridLines=function(t,e){var n=this,r=this.get("type"),o=void 0,a=void 0,s=void 0,u=void 0,l=t.length;"line"===r||"polygon"===r?i.each(t,function(t,c){n.get("hideFirstLine")&&0===c||n.get("hideLastLine")&&c===l-1||(u=t.points,a=[],"line"===r?(a.push(["M",u[0].x,u[0].y]),a.push(["L",u[u.length-1].x,u[u.length-1].y])):i.each(u,function(t,e){0===e?a.push(["M",t.x,t.y]):a.push(["L",t.x,t.y])}),s=i.mix({},e,{path:a}),(o=n.addShape("path",{attrs:s})).name="axis-grid",o._id=t._id,o.set("coord",n.get("coord")),n.get("appendInfo")&&o.setSilent("appendInfo",n.get("appendInfo")))}):i.each(t,function(t,r){n.get("hideFirstLine")&&0===r||n.get("hideLastLine")&&r===l-1||(u=t.points,a=[],i.each(u,function(t,e){var n=t.radius;0===e?a.push(["M",t.x,t.y]):a.push(["A",n,n,0,0,t.flag,t.x,t.y])}),s=i.mix({},e,{path:a}),(o=n.addShape("path",{attrs:s})).name="axis-grid",o._id=t._id,o.set("coord",n.get("coord")),n.get("appendInfo")&&o.setSilent("appendInfo",n.get("appendInfo")))})},e.prototype._drawAlternativeBg=function(t,e,n){var r=this.get("alternateColor"),o=void 0,a=void 0,s=void 0;i.isString(r)?a=r:i.isArray(r)&&(a=r[0],s=r[1]),n%2==0?s&&(o=this._getBackItem(e.points,t.points,s)):a&&(o=this._getBackItem(e.points,t.points,a));var u=this.addShape("Path",{attrs:o});u.name="axis-grid-rect",u._id=t._id&&t._id.replace("grid","grid-rect"),u.set("coord",this.get("coord")),this.get("appendInfo")&&u.setSilent("appendInfo",this.get("appendInfo"))},e.prototype._getBackItem=function(t,e,n){var r=[],o=this.get("type");if("line"===o)r.push(["M",t[0].x,t[0].y]),r.push(["L",t[t.length-1].x,t[t.length-1].y]),r.push(["L",e[e.length-1].x,e[e.length-1].y]),r.push(["L",e[0].x,e[0].y]),r.push(["Z"]);else if("polygon"===o){i.each(t,function(t,e){0===e?r.push(["M",t.x,t.y]):r.push(["L",t.x,t.y])});for(var a=e.length-1;a>=0;a--)r.push(["L",e[a].x,e[a].y]);r.push(["Z"])}else{var s=t[0].flag;i.each(t,function(t,e){var n=t.radius;0===e?r.push(["M",t.x,t.y]):r.push(["A",n,n,0,0,t.flag,t.x,t.y])});for(var u=e.length-1;u>=0;u--){var l=e[u],c=l.radius;u===e.length-1?r.push(["M",l.x,l.y]):r.push(["A",c,c,0,0,1===s?0:1,l.x,l.y])}}return{fill:n,path:r}},e}(r);t.exports=o},function(t,e,n){var r=n(591),i=n(549),o=n(552).MatrixUtil.vec2,a=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return i.mix({},e,{x:null,y:null,line:{lineWidth:1,stroke:"#C0D0E0"},tickLine:{lineWidth:1,stroke:"#C0D0E0",length:5},isVertical:!1,start:null,end:null})},e.prototype._getAvgLabelLength=function(t){var e=t.get("children");return e[1].attr("x")-e[0].attr("x")},e.prototype.getSideVector=function(t){var e=this.get("factor"),n=this.get("isVertical"),r=this.get("start"),i=this.get("end"),a=this.getAxisVector(),s=o.normalize([],a),u=!1;(n&&r.y<i.y||!n&&r.x>i.x)&&(u=!0);var l=o.vertical([],s,u);return o.scale([],l,t*e)},e.prototype.getAxisVector=function(){var t=this.get("start"),e=this.get("end");return[e.x-t.x,e.y-t.y]},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.getTickEnd=function(t,e){var n=this.getSideVector(e);return{x:t.x+n[0],y:t.y+n[1]}},e.prototype.getTickPoint=function(t){var e=this.get("start"),n=this.get("end"),r=n.x-e.x,i=n.y-e.y;return{x:e.x+r*t,y:e.y+i*t}},e.prototype.renderTitle=function(){var t=this.get("title"),e=this.getTickPoint(.5),n=t.offset;if(i.isNil(n)){n=20;var r=this.get("labelsGroup");if(r)n+=this.getMaxLabelWidth(r)+(this.get("label").offset||this.get("_labelOffset"))}var a=t.textStyle,s=i.mix({},a);if(t.text){var u=this.getAxisVector();if(t.autoRotate&&i.isNil(a.rotate)){var l=0;if(!i.snapEqual(u[1],0)){var c=[u[0],u[1]];l=o.angleTo(c,[1,0],!0)}s.rotate=l*(180/Math.PI)}else i.isNil(a.rotate)||(s.rotate=a.rotate/180*Math.PI);var h=this.getSideVector(n),f=void 0,p=t.position;f="start"===p?{x:this.get("start").x+h[0],y:this.get("start").y+h[1]}:"end"===p?{x:this.get("end").x+h[0],y:this.get("end").y+h[1]}:{x:e.x+h[0],y:e.y+h[1]},s.x=f.x,s.y=f.y,s.text=t.text;var d=this.addShape("Text",{zIndex:2,attrs:s});d.name="axis-title",this.get("appendInfo")&&d.setSilent("appendInfo",this.get("appendInfo"))}},e.prototype.autoRotateLabels=function(){var t=this.get("labelsGroup"),e=this.get("title");if(t){var n=this.get("label").offset,r=e?e.offset:48;if(r<0)return;var o=this.getAxisVector(),a=void 0,s=void 0;if(i.snapEqual(o[0],0)&&e&&e.text)(s=this.getMaxLabelWidth(t))>r-n-12&&(a=-1*Math.acos((r-n-12)/s));else if(i.snapEqual(o[1],0)&&t.getCount()>1){var u=Math.abs(this._getAvgLabelLength(t));(s=this.getMaxLabelWidth(t))>u&&(a=Math.asin(1.25*(r-n-12)/s))}if(a){var l=this.get("factor");i.each(t.get("children"),function(t){t.rotateAtStart(a),i.snapEqual(o[1],0)&&(l>0?t.attr("textAlign","left"):t.attr("textAlign","right"))})}}},e}(r);t.exports=a},function(t,e,n){t.exports={Line:n(812),Circle:n(810),Helix:n(809),PolyLine:n(808)}},function(t,e,n){var r=n(549),i=n(813),o=n(552).MatrixUtil.vec2,a=n(551);var s=function(){function t(e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.visible=!0,this.container=null,this.coord=null,this.options=null,this.axes=[],r.mix(this,e)}return t.prototype._isHide=function(t){var e=this.options;return!(!e||!1!==e[t])},t.prototype._getMiddleValue=function(t,e,n,r){if(0===t&&!r)return 0;if(1===t)return 1;var i=e[n+1].value;return r||1!==i?(t+i)/2:1},t.prototype._getLineRange=function(t,e,n,r){var i=void 0,o=void 0,a=void 0,s=e.field,u=this.options,l="";return u[s]&&u[s].position&&(l=u[s].position),"x"===n?(i={x:0,y:"top"===l?1:0},o={x:1,y:"top"===l?1:0},a=!1):(r?(i={x:"left"===l?0:1,y:0},o={x:"left"===l?0:1,y:1}):(i={x:"right"===l?1:0,y:0},o={x:"right"===l?1:0,y:1}),a=!0),{start:i=t.convert(i),end:o=t.convert(o),isVertical:a}},t.prototype._getLineCfg=function(t,e,n,r){var i=this._getLineRange(t,e,n,r),o=i.isVertical,a=i.start,s=i.end,u=t.center;return t.isTransposed&&(o=!o),{isVertical:o,factor:o&&a.x>u.x||!o&&a.y>u.y?1:-1,start:a,end:s}},t.prototype._getCircleCfg=function(t){var e={},n=t.x,r=t.y,i=r.start>r.end,a=void 0;a=t.isTransposed?{x:i?0:1,y:0}:{x:0,y:i?0:1},a=t.convert(a);var s=t.circleCentre,u=[a.x-s.x,a.y-s.y],l=[1,0],c=void 0,h=(c=a.y>s.y?o.angle(u,l):-1*o.angle(u,l))+(n.end-n.start);return e.startAngle=c,e.endAngle=h,e.center=s,e.radius=Math.sqrt(Math.pow(a.x-s.x,2)+Math.pow(a.y-s.y,2)),e.inner=t.innerRadius||0,e},t.prototype._getRadiusCfg=function(t){var e=t.x.start<0?-1:1,n=void 0,r=void 0;return t.isTransposed?(n={x:0,y:0},r={x:1,y:0}):(n={x:0,y:0},r={x:0,y:1}),{factor:e,start:t.convert(n),end:t.convert(r)}},t.prototype._getAxisPosition=function(t,e,n,r){var i="",o=this.options;if(o[r]&&o[r].position)i=o[r].position;else{var a=t.type;t.isRect?"x"===e?i="bottom":"y"===e&&(i=n?"right":"left"):i="helix"===a?"helix":"x"===e?t.isTransposed?"radius":"circle":t.isTransposed?"circle":"radius"}return i},t.prototype._getAxisDefaultCfg=function(t,e,n,i){var o={},s=this.options,u=e.field;return(o=r.deepMix({},a.axis[i],o,s[u])).title&&r.deepMix(o,{title:{text:e.alias||u}}),o.ticks=e.getTicks(),t.isPolar&&!e.isCategory&&"x"===n&&Math.abs(t.endAngle-t.startAngle)===2*Math.PI&&o.ticks.pop(),o.coord=t,o.label&&r.isNil(o.label.autoRotate)&&(o.label.autoRotate=!0),o},t.prototype._getAxisCfg=function(t,e,n,i){var o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:"",a=arguments[5],s=this,u=s._getAxisPosition(t,i,o,e.field),l=s._getAxisDefaultCfg(t,e,i,u);if(!r.isEmpty(l.grid)&&n){var c=[],h=function(t){var e=[];if(t.length>0){var n=(e=t.slice(0))[0],r=e[e.length-1];0!==n.value&&e.unshift({value:0}),1!==r.value&&e.push({value:1})}return e}(n.getTicks());if(h.length){var f=function(t,e,n){var r=[];return t.length<1?r:(t.length>=2&&e&&n&&r.push({text:"",tickValue:"",value:0}),0!==t[0].value&&r.push({text:"",tickValue:"",value:0}),1!==(r=r.concat(t))[r.length-1].value&&r.push({text:"",tickValue:"",value:1}),r)}(l.ticks,e.isLinear,"center"===l.grid.align);r.each(f,function(n,u){var p=[],d=n.value;if("center"===l.grid.align&&(d=s._getMiddleValue(d,f,u,e.isLinear)),!r.isNil(d)){var g=t.x,v=t.y;r.each(h,function(e){var n="x"===i?d:e.value,r="x"===i?e.value:d,o=t.convert({x:n,y:r});if(t.isPolar){var a=t.circleCentre;v.start>v.end&&(r=1-r),o.flag=g.start>g.end?0:1,o.radius=Math.sqrt(Math.pow(o.x-a.x,2)+Math.pow(o.y-a.y,2))}p.push(o)}),c.push({_id:a+"-"+i+o+"-grid-"+n.tickValue,points:p})}})}l.grid.items=c}return l},t.prototype._getHelixCfg=function(t){for(var e={},n=t.a,r=t.startAngle,i=t.endAngle,o=[],a=0;a<=100;a++){var s=t.convert({x:a/100,y:0});o.push(s.x),o.push(s.y)}var u=t.convert({x:0,y:0});return e.a=n,e.startAngle=r,e.endAngle=i,e.crp=o,e.axisStart=u,e.center=t.center,e.inner=t.y.start,e},t.prototype._drawAxis=function(t,e,n,o,a,s,u){var l=this.container,c=void 0,h=void 0;"cartesian"===t.type?(c=i.Line,h=this._getLineCfg(t,e,o,u)):"helix"===t.type&&"x"===o?(c=i.Helix,h=this._getHelixCfg(t)):"x"===o?(c=i.Circle,h=this._getCircleCfg(t)):(c=i.Line,h=this._getRadiusCfg(t));var f=this._getAxisCfg(t,e,n,o,u,a);f=r.mix({},f,h),"y"===o&&s&&"circle"===s.get("type")&&(f.circle=s),f._id=a+"-"+o,r.isNil(u)||(f._id=a+"-"+o+u);var p=l.addGroup(c,f);return this.axes.push(p),p},t.prototype.createAxis=function(t,e,n){var i=this,o=this.coord,a=o.type;if("theta"!==a&&("polar"!==a||!o.isTransposed)){var s=void 0;t&&!i._isHide(t.field)&&(s=i._drawAxis(o,t,e[0],"x",n)),r.isEmpty(e)||"helix"===a||r.each(e,function(e,r){i._isHide(e.field)||i._drawAxis(o,e,t,"y",n,s,r)})}},t.prototype.changeVisible=function(t){var e=this.axes;r.each(e,function(e){e.set("visible",t)})},t.prototype.clear=function(){var t=this.axes;r.each(t,function(t){t.remove()}),this.axes=[]},t}();t.exports=s},function(t,e,n){var r=n(549),i=n(592),o=n(552).MatrixUtil.vec2,a=function(t){function e(n){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);var r=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.call(this,n));return r._init(),r}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return r.mix({},e,{startAngle:1.25*Math.PI,endAngle:7.25*Math.PI,innerRadius:0,type:"helix",isHelix:!0})},e.prototype._init=function(){var t=this.width,e=this.height,n=this.radius,r=this.innerRadius,i=this.startAngle,o=this.endAngle,a=(o-i)/(2*Math.PI)+1,s=Math.min(t,e)/2;n&&n>=0&&n<=1&&(s*=n);var u=Math.floor(s*(1-r)/a),l=u/(2*Math.PI),c={start:i,end:o},h={start:r*s,end:r*s+.99*u};this.a=l,this.d=u,this.x=c,this.y=h},e.prototype.getCenter=function(){return this.center},e.prototype.convertPoint=function(t){var e=this.a,n=this.center,r=void 0,i=void 0;this.isTransposed?(r=t.y,i=t.x):(r=t.x,i=t.y);var o=this.convertDim(r,"x"),a=e*o,s=this.convertDim(i,"y");return{x:n.x+Math.cos(o)*(a+s),y:n.y+Math.sin(o)*(a+s)}},e.prototype.invertPoint=function(t){var e=this.center,n=this.a,i=this.d+this.y.start,a=o.subtract([],[t.x,t.y],[e.x,e.y]),s=o.angleTo(a,[1,0],!0),u=s*n;o.length(a)<u&&(u=o.length(a));var l=n*(s=2*Math.floor((o.length(a)-u)/i)*Math.PI+s),c=o.length(a)-l;c=r.snapEqual(c,0)?0:c;var h=this.invertDim(s,"x"),f=this.invertDim(c,"y");h=r.snapEqual(h,0)?0:h,f=r.snapEqual(f,0)?0:f;var p={};return p.x=this.isTransposed?f:h,p.y=this.isTransposed?h:f,p},e}(i);t.exports=a},function(t,e,n){var r=n(549),i=n(592),o=n(552).MatrixUtil,a=o.mat3,s=o.vec2,u=o.vec3,l=function(t){function e(n){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);var r=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.call(this,n));return r._init(),r}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return r.mix({},e,{startAngle:-Math.PI/2,endAngle:3*Math.PI/2,innerRadius:0,type:"polar",isPolar:!0})},e.prototype._init=function(){var t=this.radius,e=this.innerRadius,n=this.startAngle,r=this.endAngle,i=this.center,o=this.getOneBox(),a=o.maxX-o.minX,s=o.maxY-o.minY,u=Math.abs(o.minX)/a,l=Math.abs(o.minY)/s,c=this.width,h=this.height,f=void 0,p=void 0;h/s>c/a?(f=c/a,p={x:i.x-(.5-u)*c,y:i.y-(.5-l)*f*s}):(f=h/s,p={x:i.x-(.5-u)*f*a,y:i.y-(.5-l)*h}),t?t>0&&t<=1?t*=f:(t<=0||t>f)&&(t=f):t=f;var d={start:n,end:r},g={start:e*t,end:t};this.x=d,this.y=g,this.radius=t,this.circleCentre=p,this.center=p},e.prototype.getCenter=function(){return this.circleCentre},e.prototype.getOneBox=function(){var t=this.startAngle,e=this.endAngle;if(e-t>=2*Math.PI)return{minX:-1,maxX:1,minY:-1,maxY:1};for(var n=[0,Math.cos(t),Math.cos(e)],r=[0,Math.sin(t),Math.sin(e)],i=5*-Math.PI/2;i<3*Math.PI/2;i+=Math.PI/2)t<=i&&i<=e&&(n.push(Math.cos(i)),r.push(Math.sin(i)));return{minX:Math.min.apply(Math,n),maxX:Math.max.apply(Math,n),minY:Math.min.apply(Math,r),maxY:Math.max.apply(Math,r)}},e.prototype.getRadius=function(){return this.radius},e.prototype.convertPoint=function(t){var e=this.getCenter(),n=this.isTransposed?t.y:t.x,r=this.isTransposed?t.x:t.y;return n=this.convertDim(n,"x"),r=this.convertDim(r,"y"),{x:e.x+Math.cos(n)*r,y:e.y+Math.sin(n)*r}},e.prototype.invertPoint=function(t){var e=this.getCenter(),n=[t.x-e.x,t.y-e.y],i=this.x,o=[1,0,0,0,1,0,0,0,1];a.rotate(o,o,i.start);var l=[1,0,0];u.transformMat3(l,l,o),l=[l[0],l[1]];var c=s.angleTo(l,n,i.end<i.start);r.snapEqual(c,2*Math.PI)&&(c=0);var h=s.length(n),f=c/(i.end-i.start);f=i.end-i.start>0?f:-f;var p=this.invertDim(h,"y"),d={};return d.x=this.isTransposed?p:f,d.y=this.isTransposed?f:p,d},e}(i);t.exports=l},function(t,e,n){var r=n(549),i=function(t){function e(n){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);var r=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.call(this,n));return r._init(),r}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return r.mix({},e,{start:{x:0,y:0},end:{x:0,y:0},type:"cartesian",isRect:!0})},e.prototype._init=function(){var t=this.start,e=this.end,n={start:t.x,end:e.x},r={start:t.y,end:e.y};this.x=n,this.y=r},e.prototype.convertPoint=function(t){var e=void 0,n=void 0;return this.isTransposed?(e=t.y,n=t.x):(e=t.x,n=t.y),{x:this.convertDim(e,"x"),y:this.convertDim(n,"y")}},e.prototype.invertPoint=function(t){var e=this.invertDim(t.x,"x"),n=this.invertDim(t.y,"y");return this.isTransposed?{x:n,y:e}:{x:e,y:n}},e}(n(592));t.exports=i},function(t,e,n){var r=n(592);r.Cartesian=n(817),r.Rect=r.Cartesian,r.Polar=n(816),r.Helix=n(815),t.exports=r},function(t,e,n){var r=n(549),i=n(818),o=function(){function t(e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.type="rect",this.actions=[],this.cfg={},r.mix(this,e),this.option=e||{}}return t.prototype.reset=function(t){return this.actions=t.actions||[],this.type=t.type,this.cfg=t.cfg,this.option.actions=this.actions,this.option.type=this.type,this.option.cfg=this.cfg,this},t.prototype._execActions=function(t){var e=this.actions;r.each(e,function(e){var n=e[0];t[n](e[1],e[2])})},t.prototype.hasAction=function(t){var e=this.actions,n=!1;return r.each(e,function(e){if(t===e[0])return n=!0,!1}),n},t.prototype.createCoord=function(t,e){var n=this.type,o=this.cfg,a=void 0,s=void 0,u=r.mix({start:t,end:e},o);return"theta"===n?(a=i.Polar,this.hasAction("transpose")||this.transpose(),(s=new a(u)).type=n):s=new(a=i[r.upperFirst(n)]||i.Rect)(u),this._execActions(s),s},t.prototype.rotate=function(t){return t=t*Math.PI/180,this.actions.push(["rotate",t]),this},t.prototype.reflect=function(t){return this.actions.push(["reflect",t]),this},t.prototype.scale=function(t,e){return this.actions.push(["scale",t,e]),this},t.prototype.transpose=function(){return this.actions.push(["transpose"]),this},t}();t.exports=o},function(t,e,n){var r=n(593),i=n(549);function o(t,e){var n=Math.E;return Math.pow(n,Math.log(e)/t)}var a=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return i.mix({},e,{type:"pow",exponent:2,tickCount:10})},e.prototype.calculateTicks=function(){var t=this.exponent,e=void 0,n=Math.ceil(o(t,this.max));if((e=this.min>=0?Math.floor(o(t,this.min)):0)>n){var r=n;n=e,e=r}for(var i=n-e,a=this.tickCount,s=Math.ceil(i/a),u=[],l=e;l<n+s;l+=s)u.push(Math.pow(l,t));return u},e.prototype._getScalePercent=function(t){var e=this.max,n=this.min;if(e===n)return 0;var r=this.exponent;return(o(r,t)-o(r,n))/(o(r,e)-o(r,n))},e.prototype.scale=function(t){var e=this._getScalePercent(t),n=this.rangeMin();return n+e*(this.rangeMax()-n)},e.prototype.invert=function(t){var e=(t-this.rangeMin())/(this.rangeMax()-this.rangeMin()),n=this.exponent,r=o(n,this.max),i=o(n,this.min),a=e*(r-i)+i;return Math.pow(a,n)},e}(r);t.exports=a},function(t,e,n){var r=n(593),i=n(549);function o(t,e){return 1===t?1:Math.log(e)/Math.log(t)}var a=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return i.mix({},e,{type:"log",base:2,tickCount:10,_minTick:null})},e.prototype.calculateTicks=function(){var t=this.base,e=void 0;if(this.min<0)throw new Error("The minimum value must be greater than zero!");var n=o(t,this.max);if(this.min>0)e=Math.floor(o(t,this.min));else{var r=this.values,a=this.max;i.each(r,function(t){t>0&&t<a&&(a=t)}),a===this.max&&(a=this.max/t),a>1&&(a=1),e=Math.floor(o(t,a)),this._minTick=e,this.positiveMin=a}for(var s=n-e,u=this.tickCount,l=Math.ceil(s/u),c=[],h=e;h<n+l;h+=l)c.push(Math.pow(t,h));return 0===this.min&&c.unshift(0),c},e.prototype._getScalePercent=function(t){var e=this.max,n=this.min;if(e===n)return 0;if(t<=0)return 0;var r=this.base,i=this.positiveMin;i&&(n=1*i/r);return t<i?t/i/(o(r,e)-o(r,n)):(o(r,t)-o(r,n))/(o(r,e)-o(r,n))},e.prototype.scale=function(t){var e=this._getScalePercent(t),n=this.rangeMin();return n+e*(this.rangeMax()-n)},e.prototype.invert=function(t){var e=this.base,n=o(e,this.max),r=this.rangeMin(),i=this.rangeMax()-r,a=void 0,s=this.positiveMin;if(s){if(0===t)return 0;var u=1/(n-(a=o(e,s/e)))*i;if(t<u)return t/u*s}else a=o(e,this.min);var l=(t-r)/i*(n-a)+a;return Math.pow(e,l)},e}(r);t.exports=a},function(t,e,n){var r=n(657),i=n(549),o=n(655),a=n(656),s=n(654),u=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return i.mix({},e,{type:"timeCat",mask:"YYYY-MM-DD",tickCount:7})},e.prototype.init=function(){var t=this,e=this.values;i.each(e,function(n,r){e[r]=t._toTimeStamp(n)}),e.sort(function(t,e){return t-e}),t.ticks||(t.ticks=this.calculateTicks(!1))},e.prototype.calculateTicks=function(t){var e=this,n=e.tickCount,r=void 0;if(n){var s=a({maxCount:n,data:e.values});r=s.ticks}else r=e.values;return t&&i.each(r,function(t,n){r[n]=o.format(t,e.mask)}),r},e.prototype.translate=function(t){t=this._toTimeStamp(t);var e=this.values.indexOf(t);return-1===e&&(e=i.isNumber(t)&&t<this.values.length?t:NaN),e},e.prototype.scale=function(t){var e=this.rangeMin(),n=this.rangeMax(),r=this.translate(t);return e+(1===this.values.length?r:r>-1?r/(this.values.length-1):0)*(n-e)},e.prototype.getText=function(t){var e="",n=this.translate(t);e=n>-1?this.values[n]:t;var r=this.formatter;return e=parseInt(e,10),e=r?r(e):o.format(e,this.mask)},e.prototype.getTicks=function(){var t=this,e=this.ticks,n=[];return i.each(e,function(e){var r=void 0;r=i.isObject(e)?e:{text:i.isString(e)?e:t.getText(e),tickValue:e,value:t.scale(e)},n.push(r)}),n},e.prototype._toTimeStamp=function(t){return s.toTimeStamp(t)},e}(r);t.exports=u},function(t,e,n){var r=n(549),i=n(658),o=[1,2,4,6,8,12],a=36e5,s=864e5;function u(t){return new Date(t).getFullYear()}function l(t){return new Date(t,0,1).getTime()}function c(t){return new Date(t).getMonth()}function h(t,e){return new Date(t,e,1).getTime()}t.exports=function(t){var e=t.minInterval,n=[],f=t.min,p=t.max,d=t.interval,g=void 0;if(p===f&&(p=f+s),r.isNil(d)){var v=s,y=365*v;d=parseInt((p-f)/(t.maxCount||6),10),e&&e>d&&(d=e);var m=d/y,x=u(f);if(m>.51){for(var b=Math.ceil(m),_=u(p),w=x;w<=_+b;w+=b)n.push(l(w));d=null}else if(m>.0834){for(var S=Math.ceil(m/.0834),M=c(f),C=function(t,e){var n=u(t),r=u(e),i=c(t);return 12*(r-n)+(c(e)-i)%12}(f,p),P=0;P<=C+S;P+=S)n.push(h(x,P+M));d=null}else if(d>.5*v){var A=new Date(f),I=A.getFullYear(),O=A.getMonth(f),E=A.getDate(),T=Math.ceil(d/v),k=function(t,e){return Math.ceil((e-t)/s)}(f,p);d=T*v;for(var j=0;j<k+T;j+=T)n.push(new Date(I,O,E+j).getTime())}else if(d>a){var L=new Date(f),D=L.getFullYear(),F=L.getMonth(f),R=L.getDate(),B=L.getHours(),N=i.snapTo(o,Math.ceil(d/a)),z=function(t,e){return Math.ceil((e-t)/a)}(f,p);d=N*a;for(var V=0;V<=z+N;V+=N)n.push(new Date(D,F,R,B+V).getTime())}else if(d>6e4){var G=function(t,e){return Math.ceil((e-t)/6e4)}(f,p),Y=Math.ceil(d/6e4);d=6e4*Y;for(var W=0;W<=G+Y;W+=Y)n.push(f+6e4*W)}else{d<1e3&&(d=1e3),f=1e3*Math.floor(f/1e3);var X=Math.ceil((p-f)/1e3),q=Math.ceil(d/1e3);d=1e3*q;for(var H=0;H<X+q;H+=q)n.push(f+1e3*H)}}if(!n.length){f=1e3*Math.floor(f/1e3),g=((p=1e3*Math.ceil(p/1e3))-f)/d;for(var U=0;U<=g;U++)n.push(r.fixedBase(d*U+f,d))}return{max:p,min:f,interval:d,ticks:n,count:n.length}}},function(t,e,n){var r=n(593),i=n(549),o=n(823),a=n(655),s=n(654),u=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return i.mix({},e,{type:"time",mask:"YYYY-MM-DD"})},e.prototype.init=function(){var e=this,n=e.values;if(n&&n.length){var r=[],o=1/0,a=o,s=0;i.each(n,function(t){var n=e._toTimeStamp(t);if(isNaN(n))throw new TypeError("Invalid Time: "+t);o>n?(a=o,o=n):a>n&&(a=n),s<n&&(s=n),r.push(n)}),n.length>1&&(e.minTickInterval=a-o),(i.isNil(e.min)||e._toTimeStamp(e.min)>o)&&(e.min=o),(i.isNil(e.max)||e._toTimeStamp(e.max)<s)&&(e.max=s)}t.prototype.init.call(this)},e.prototype.calculateTicks=function(){var t=this.min,e=this.max,n=this.tickCount,r=this.tickInterval;return o({min:t,max:e,minCount:n,maxCount:n,interval:r,minInterval:this.minTickInterval}).ticks},e.prototype.getText=function(t){var e=this.formatter;return t=this.translate(t),t=e?e(t):a.format(t,this.mask)},e.prototype.scale=function(e){return i.isString(e)&&(e=this.translate(e)),t.prototype.scale.call(this,e)},e.prototype.translate=function(t){return this._toTimeStamp(t)},e.prototype._toTimeStamp=function(t){return s.toTimeStamp(t)},e}(r);t.exports=u},function(t,e,n){var r=n(594),i=n(549),o=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return i.mix({},e,{isIdentity:!0,type:"identity",value:null})},e.prototype.getText=function(){return this.value.toString()},e.prototype.scale=function(t){return this.value!==t&&i.isNumber(t)?t:this.range[0]},e.prototype.invert=function(){return this.value},e}(r);t.exports=o},function(t,e,n){var r=n(549),i=n(658),o=n(551);t.exports=function(t){var e=t.min,n=t.max,a=t.interval,s=[],u=t.minCount||5,l=t.maxCount||7,c=u===l,h=r.isNil(t.minLimit)?-1/0:t.minLimit,f=r.isNil(t.maxLimit)?1/0:t.maxLimit,p=(u+l)/2,d=p,g=t.snapArray?t.snapArray:c?o.snapCountArray:o.snapArray;if(e===h&&n===f&&c&&(a=(n-e)/(d-1)),r.isNil(e)&&(e=0),r.isNil(n)&&(n=0),n===e&&(0===e?n=1:e>0?e=0:n=0,n-e<5&&!a&&n-e>=1&&(a=1)),r.isNil(a)){var v=(n-e)/(p-1);a=i.snapFactorTo(v,g,"ceil"),l!==u&&((d=parseInt((n-e)/a,10))>l&&(d=l),d<u&&(d=u),a=i.snapFactorTo((n-e)/(d-1),g,"floor"))}if(t.interval||l!==u)n=Math.min(i.snapMultiple(n,a,"ceil"),f),e=Math.max(i.snapMultiple(e,a,"floor"),h),d=Math.round((n-e)/a),e=r.fixedBase(e,a),n=r.fixedBase(n,a);else{p=parseInt(p,10);var y=(n+e)/2,m=i.snapMultiple(y,a,"ceil"),x=Math.floor((p-2)/2),b=m+x*a,_=void 0;_=p%2==0?m-x*a:m-(x+1)*a,b<n&&(b+=a),_>e&&(_-=a),n=r.fixedBase(b,a),e=r.fixedBase(_,a)}n=Math.min(n,f),e=Math.max(e,h),s.push(e);for(var w=1;w<d;w++){var S=r.fixedBase(a*w+e,a);S<n&&s.push(S)}return s[s.length-1]<n&&s.push(n),{min:e,max:n,interval:a,count:d,ticks:s}}},function(t,e,n){var r=n(549),i=n(551),o=n(659),a=/^(?:(?!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]))?$/,s="linear",u="cat",l="time",c=function(){function t(e){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.defs={},r.assign(this,e)}return t.prototype._getDef=function(t){var e=this.defs,n=null;return(i.scales[t]||e[t])&&(n=r.mix({},i.scales[t]),r.each(e[t],function(t,e){r.isNil(t)?delete n[e]:n[e]=t})),n},t.prototype._getDefaultType=function(t,e){var n=s,i=r.Array.firstValue(e,t);return r.isArray(i)&&(i=i[0]),a.test(i)?n=l:r.isString(i)&&(n=u),n},t.prototype._getScaleCfg=function(t,e,n){var i={field:e},a=r.Array.values(n,e);if(i.values=a,!o.isCategory(t)&&"time"!==t){var s=r.Array.getRange(a);i.min=s.min,i.max=s.max,i.nice=!0}return"time"===t&&(i.nice=!1),i},t.prototype.createScale=function(t,e){var n=this._getDef(t),i=void 0;if(!e||!e.length)return i=n&&n.type?o[n.type](n):o.identity({value:t,field:t.toString(),values:[t]});var a=r.Array.firstValue(e,t);if(r.isNumber(t)||r.isNil(a)&&!n)i=o.identity({value:t,field:t.toString(),values:[t]});else{var s=void 0;n&&(s=n.type),s=s||this._getDefaultType(t,e);var u=this._getScaleCfg(s,t,e);n&&r.mix(u,n),i=o[s](u)}return i},t}();t.exports=c},function(t,e,n){var r=n(549);function i(t,e){if(r.isNil(t)||r.isNil(e))return!1;var n=t.get("origin"),i=e.get("origin");return r.isEqual(n,i)}var o={_isAllowSelect:function(){var t=this.get("allowSelect");if(!r.isNil(t))return t;var e=this.get("type"),n=this.get("coord"),i=n&&n.type;return"interval"===e&&"theta"===i},_onClick:function(t){if(this._isAllowSelect()){this.clearActivedShapes();var e=t.shape,n=this.get("shapeContainer");e&&!e.get("animating")&&n.contain(e)&&this.setShapeSelected(e)}},_bindSelectedAction:function(){var t=this.get("view"),e=this.get("type");t.on(e+":click",r.wrapBehavior(this,"_onClick"))},_offSelectedAction:function(){var t=this.get("view"),e=this.get("type");t.off(e+":click",r.getWrapBehavior(this,"_onClick"))},_setShapeStatus:function(t,e){var n=this.get("view"),i=this.get("selectedOptions")||{},o=!1!==i.animate,a=n.get("canvas");t.set("selected",e);var s=t.get("origin");if(e){var u=s.shape||this.getDefaultValue("shape");r.isArray(u)&&(u=u[0]);var l=this.get("shapeFactory"),c=r.mix({geom:this,point:s},i),h=l.getSelectedCfg(u,c);r.mix(h,c.style),t.get("_originAttrs")||(t.get("animating")&&t.stopAnimate(),t.set("_originAttrs",function(t,e){var n={};return r.each(t,function(t,i){"transform"===i&&(i="matrix");var o=e.__attrs[i];r.isArray(o)&&(o=r.cloneDeep(o)),n[i]=o}),n}(h,t))),o?t.animate(h,300):(t.attr(h),a.draw())}else{var f=t.get("_originAttrs");t.set("_originAttrs",null),o?t.animate(f,300):(t.attr(f),a.draw())}},setShapeSelected:function(t){var e=this._getSelectedShapes(),n=this.get("selectedOptions")||{},o=!1!==n.cancelable;if("multiple"===n.mode)-1===r.indexOf(e,t)?(e.push(t),this._setShapeStatus(t,!0)):o&&(r.Array.remove(e,t),this._setShapeStatus(t,!1));else{var a=e[0];o&&(t=i(a,t)?null:t),i(a,t)||(a&&this._setShapeStatus(a,!1),t&&this._setShapeStatus(t,!0))}},clearSelected:function(){var t=this,e=t.get("shapeContainer");if(e&&!e.get("destroyed")){var n=t._getSelectedShapes();r.each(n,function(e){t._setShapeStatus(e,!1),e.set("_originAttrs",null)})}},setSelected:function(t){var e=this,n=e.getShapes();return r.each(n,function(n){var r=n.get("origin");r&&r._origin===t&&e.setShapeSelected(n)}),this},_getSelectedShapes:function(){var t=this.getShapes(),e=[];return r.each(t,function(t){t.get("selected")&&e.push(t)}),this.set("selectedShapes",e),e}};t.exports=o},function(t,e,n){var r=n(549);function i(t,e){if(!t)return!0;if(t.length!==e.length)return!0;var n=!1;return r.each(e,function(e,i){if(!function(t,e){if(r.isNil(t)||r.isNil(e))return!1;var n=t.get("origin"),i=e.get("origin");return r.isEqual(n,i)}(e,t[i]))return n=!0,!1}),n}function o(t,e){var n={};return r.each(t,function(t,i){var o=e.__attrs[i];r.isArray(o)&&(o=r.cloneDeep(o)),n[i]=o}),n}var a={_isAllowActive:function(){var t=this.get("allowActive");if(!r.isNil(t))return t;var e=this.get("view"),n=this.isShareTooltip();return!1===e.get("options").tooltip||!n},_onMouseenter:function(t){var e=t.shape,n=this.get("shapeContainer");e&&n.contain(e)&&this._isAllowActive()&&this.setShapesActived(e)},_onMouseleave:function(){var t=this.get("view").get("canvas");this.get("activeShapes")&&(this.clearActivedShapes(),t.draw())},_bindActiveAction:function(){var t=this.get("view"),e=this.get("type");t.on(e+":mouseenter",r.wrapBehavior(this,"_onMouseenter")),t.on(e+":mouseleave",r.wrapBehavior(this,"_onMouseleave"))},_offActiveAction:function(){var t=this.get("view"),e=this.get("type");t.off(e+":mouseenter",r.getWrapBehavior(this,"_onMouseenter")),t.off(e+":mouseleave",r.getWrapBehavior(this,"_onMouseleave"))},_setActiveShape:function(t){var e=this.get("activedOptions")||{},n=t.get("origin"),i=n.shape||this.getDefaultValue("shape");r.isArray(i)&&(i=i[0]);var a=this.get("shapeFactory"),s=r.mix({},t.__attrs,{origin:n}),u=a.getActiveCfg(i,s);e.style&&r.mix(u,e.style);var l=o(u,t);t.setSilent("_originAttrs",l),e.animate?t.animate(u,300):t.attr(u),t.setZIndex(1)},setShapesActived:function(t){var e=this;r.isArray(t)||(t=[t]);var n=e.get("activeShapes");if(i(n,t)){var o=e.get("view").get("canvas"),a=e.get("shapeContainer"),s=e.get("activedOptions");s&&s.highlight?(r.each(t,function(t){t.get("animating")&&t.stopAnimate()}),e.highlightShapes(t)):(n&&e.clearActivedShapes(),r.each(t,function(t){t.get("animating")&&t.stopAnimate(),t.get("visible")&&!t.get("selected")&&e._setActiveShape(t)})),e.set("activeShapes",t),a.sort(),o.draw()}},clearActivedShapes:function(){var t=this.get("shapeContainer"),e=this.get("activedOptions"),n=e&&e.animate;if(t&&!t.get("destroyed")){var i=this.get("activeShapes");if(r.each(i,function(t){if(!t.get("selected")){var e=t.get("_originAttrs");n?(t.stopAnimate(),t.animate(e,300)):t.attr(e),t.setZIndex(0),t.set("_originAttrs",null)}}),this.get("preHighlightShapes")){var o=t.get("children");r.each(o,function(t){if(!t.get("selected")){var e=t.get("_originAttrs");e&&(n?(t.stopAnimate(),t.animate(e,300)):t.attr(e),t.setZIndex(0),t.set("_originAttrs",null))}})}t.get("children").sort(function(t,e){return t._INDEX-e._INDEX}),this.set("activeShapes",null),this.set("preHighlightShapes",null)}},getGroupShapesByPoint:function(t){var e=[];if(this.get("shapeContainer")){var n=this.getXScale().field,i=this.getShapes(),o=this._getOriginByPoint(t);r.each(i,function(t){var r=t.get("origin");t.get("visible")&&r&&(r._origin[n]===o[n]&&e.push(t))})}return e},getSingleShapeByPoint:function(t){var e=this.get("shapeContainer"),n=e.get("canvas").get("pixelRatio"),r=void 0;if(e&&(r=e.getShape(t.x*n,t.y*n)),r&&r.get("origin"))return r},highlightShapes:function(t,e){r.isArray(t)||(t=[t]);var n=this.get("activeShapes");if(i(n,t)){n&&this.clearActivedShapes();var a=this.getShapes(),s=this.get("activedOptions"),u=s&&s.animate,l=s&&s.style;r.each(a,function(n){var i={};n.stopAnimate(),-1!==r.indexOf(t,n)?(r.mix(i,l,e),n.setZIndex(1)):(r.mix(i,{fillOpacity:.3}),n.setZIndex(0));var a=o(i,n);n.setSilent("_originAttrs",a),u?n.animate(i,300):n.attr(i)}),this.set("preHighlightShapes",t),this.set("activeShapes",t)}}};t.exports=a},function(t,e,n){var r=n(549),i=n(551).defaultColor;function o(t){return t.alias||t.field}var a={_getIntervalSize:function(t){var e=null,n=this.get("type"),i=this.get("coord");if(i.isRect&&("interval"===n||"schema"===n)){e=this.getSize(t._origin);var o=i.isTransposed?"y":"x";if(r.isArray(t[o]))e=e<Math.abs(t[o][1]-t[o][0])?null:e}return e},_snapEqual:function(t,e,n){return t=n.translate(t),e=n.translate(e),n.isCategory?t===e:r.snapEqual(t,e)},_getScaleValueByPoint:function(t){var e=0,n=this.get("coord"),r=this.getXScale(),i=n.invert(t).x;return this.isInCircle()&&i>(1+r.rangeMax())/2&&(i=r.rangeMin()),e=r.invert(i),r.isCategory&&(e=r.translate(e)),e},_getOriginByPoint:function(t){var e=this.getXScale(),n=this.getYScale(),r=e.field,i=n.field,o=this.get("coord").invert(t),a=e.invert(o.x),s=n.invert(o.y),u={};return u[r]=a,u[i]=s,u},_getScale:function(t){var e=this.get("scales"),n=null;return r.each(e,function(e){if(e.field===t)return n=e,!1}),n},_getTipValueScale:function(){var t=this.getAttrsForLegend(),e=void 0;r.each(t,function(t){var n=t.getScale(t.type);if(n.isLinear)return e=n,!1});var n=this.getXScale(),i=this.getYScale();return!e&&i&&"..y"===i.field?n:e||i||n},_getTipTitleScale:function(t){if(t)return this._getScale(t);var e=this.getAttr("position").getFields(),n=void 0;return r.each(e,function(t){if(-1===t.indexOf(".."))return n=t,!1}),this._getScale(n)},_filterValue:function(t,e){var n=this.get("coord"),i=this.getYScale(),o=i.field,a=n.invert(e).y;a=i.invert(a);var s=t[t.length-1];return r.each(t,function(t){var e=t._origin;if(e[o][0]<=a&&e[o][1]>=a)return s=t,!1}),s},getXDistance:function(){var t=this.get("xDistance");if(!t){var e=this.getXScale();if(e.isCategory)t=1;else{var n=e.values,i=e.translate(n[0]),o=i;r.each(n,function(t){(t=e.translate(t))<i&&(i=t),t>o&&(o=t)});var a=n.length;t=(o-i)/(a-1)}this.set("xDistance",t)}return t},findPoint:function(t,e){var n=this,i=n.get("type"),o=n.getXScale(),a=n.getYScale(),s=o.field,u=a.field,l=null;if(r.indexOf(["heatmap"],i)>-1){var c=n.get("coord").invert(t),h=o.invert(c.x),f=a.invert(c.y),p=1/0;return r.each(e,function(t){var e=Math.pow(t._origin[s]-h,2)+Math.pow(t._origin[u]-f,2);e<p&&(p=e,l=t)}),l}var d=e[0],g=e[e.length-1];if(!d)return l;var v=n._getScaleValueByPoint(t),y=d._origin[s],m=d._origin[u],x=g._origin[s],b=a.isLinear&&r.isArray(m);if(r.isArray(y))r.each(e,function(t){var e=t._origin;if(o.translate(e[s][0])<=v&&o.translate(e[s][1])>=v){if(!b)return l=t,!1;r.isArray(l)||(l=[]),l.push(t)}}),r.isArray(l)&&(l=this._filterValue(l,t));else{var _=void 0;if(o.isLinear||"timeCat"===o.type){if((v>o.translate(x)||v<o.translate(y))&&(v>o.max||v<o.min))return null;for(var w=0,S=e.length-1,M=void 0;w<=S;){M=Math.floor((w+S)/2);var C=e[M]._origin[s];if(n._snapEqual(C,v,o))return e[M];o.translate(C)<=o.translate(v)?(w=M+1,g=e[M],_=e[M+1]):(0===S&&(g=e[0]),S=M-1)}}else r.each(e,function(t,i){var a=t._origin;if(n._snapEqual(a[s],v,o)){if(!b)return l=t,!1;r.isArray(l)||(l=[]),l.push(t)}else o.translate(a[s])<=v&&(g=t,_=e[i+1])}),r.isArray(l)&&(l=this._filterValue(l,t));g&&_&&Math.abs(o.translate(g._origin[s])-v)>Math.abs(o.translate(_._origin[s])-v)&&(g=_)}var P=n.getXDistance();return!l&&Math.abs(o.translate(g._origin[s])-v)<=P/2&&(l=g),l},getTipTitle:function(t,e){var n="",r=this._getTipTitleScale(e);if(r){var i=t[r.field];n=r.getText(i)}else if("heatmap"===this.get("type")){var o=this.getXScale(),a=this.getYScale();n="( "+o.getText(t[o.field])+", "+a.getText(t[a.field])+" )"}return n},getTipValue:function(t,e){var n=void 0;if(n=t[e.field],r.isArray(n)){var i=[];r.each(n,function(t){i.push(e.getText(t))}),n=i.join("-")}else n=e.getText(n);return n},getTipName:function(t){var e=void 0,n=void 0,i=this._getGroupScales();if(i.length&&r.each(i,function(t){return n=t,!1}),n){var a=n.field;e=n.getText(t[a])}else{e=o(this._getTipValueScale())}return e},getTipItems:function(t,e){var n=this,a=t._origin,s=n.getTipTitle(a,e),u=n.get("tooltipCfg"),l=[],c=void 0,h=void 0;function f(e,o,a){if(!r.isNil(o)&&""!==o){var u={title:s,point:t,name:e||s,value:o,color:t.color||i,marker:!0};u.size=n._getIntervalSize(t),l.push(r.mix({},u,a))}}if(u){var p=u.fields,d=u.cfg,g=[];if(r.each(p,function(t){g.push(a[t])}),d){r.isFunction(d)&&(d=d.apply(null,g));var v=r.mix({},{point:t,title:s,color:t.color||i,marker:!0},d);v.size=n._getIntervalSize(t),l.push(v)}else r.each(p,function(t){if(!r.isNil(a[t])){var e=n._getScale(t);c=o(e),h=e.getText(a[t]),f(c,h)}})}else{var y=n._getTipValueScale();r.isNil(a[y.field])||(h=n.getTipValue(a,y),f(c=n.getTipName(a),h))}return l},isShareTooltip:function(){var t=this.get("shareTooltip"),e=this.get("type"),n=this.get("view"),i=void 0;if(i=n.get("parent")?n.get("parent").get("options"):n.get("options"),"interval"===e){var o=this.get("coord"),a=o.type;("theta"===a||"polar"===a&&o.isTransposed)&&(t=!1)}else this.getYScale()&&!r.inArray(["contour","point","polygon","edge"],e)||(t=!1);return i.tooltip&&r.isBoolean(i.tooltip.shared)&&(t=i.tooltip.shared),t}};t.exports=a},function(t,e,n){var r=n(549),i=n(661),o=n(568),a=n(551);function s(t,e,n){return{x:t.x+n*Math.cos(e),y:t.y+n*Math.sin(e)}}var u=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){return{label:a.thetaLabels}},e.prototype.getDefaultOffset=function(){return this.get("label").offset||0},e.prototype.adjustItems=function(t){var e=this.getDefaultOffset();return e>0&&(t=this._distribute(t,e)),t},e.prototype._distribute=function(t,e){var n=this.get("coord"),r=n.getRadius(),i=this.get("label").labelHeight,o=n.getCenter(),a=2*(r+e)+2*i,s={start:n.start,end:n.end},u=this.get("geom");if(u){var l=u.get("view");s=l.getViewRegion()}var c=[[],[]];return t.forEach(function(t){"right"===t.textAlign?c[0].push(t):c[1].push(t)}),c.forEach(function(t,e){var n=parseInt(a/i,10);t.length>n&&(t.sort(function(t,e){return e["..percent"]-t["..percent"]}),t.splice(n,t.length-n)),t.sort(function(t,e){return t.y-e.y}),function(t,e,n,r,i){var o=!0,a=n.start,s=n.end,u=Math.min(a.y,s.y),l=Math.abs(a.y-s.y),c=void 0,h=0,f=Number.MIN_VALUE,p=t.map(function(t){return t.y>h&&(h=t.y),t.y<f&&(f=t.y),{size:e,targets:[t.y-u]}});for(f-=u,h-u>l&&(l=h-u);o;)for(p.forEach(function(t){var e=(Math.min.apply(f,t.targets)+Math.max.apply(f,t.targets))/2;t.pos=Math.min(Math.max(f,e-t.size/2),l-t.size)}),o=!1,c=p.length;c--;)if(c>0){var d=p[c-1],g=p[c];d.pos+d.size>g.pos&&(d.size+=g.size,d.targets=d.targets.concat(g.targets),d.pos+d.size>l&&(d.pos=l-d.size),p.splice(c,1),o=!0)}c=0,p.forEach(function(n){var r=u+e/2;n.targets.forEach(function(){t[c].y=n.pos+r,r+=e,c++})}),t.forEach(function(t){var e=t.r*t.r,n=Math.pow(Math.abs(t.y-r.y),2);if(e<n)t.x=r.x;else{var o=Math.sqrt(e-n);t.x=i?r.x+o:r.x-o}})}(t,i,s,o,e)}),c[0].concat(c[1])},e.prototype.lineToLabel=function(t,e){var n=this.get("coord"),i=n.getRadius(),o=this.getDefaultOffset(),a=t.orignAngle||t.angle,u=n.getCenter(),l=s(u,a,i+2.5),c=s(u,a,i+o/2),h=this.get("lineGroup");h||(h=this.addGroup({elCls:"x-line-group"}),this.set("lineGroup",h));var f=h.addShape("path",{attrs:r.mix({path:["M"+l.x,l.y+" Q"+c.x,c.y+" "+t.x,t.y].join(","),fill:null,stroke:t.color},e)});f.name="labelLine",f._id=t._id&&t._id.replace("glabel","glabelline"),f.set("coord",n)},e.prototype.getLabelRotate=function(t,e){var n=void 0;return e<0&&((n=180*t/Math.PI)>90&&(n-=180),n<-90&&(n+=180)),n/180*Math.PI},e.prototype.getLabelAlign=function(t){var e=this.get("coord").getCenter(),n=void 0;return n=t.angle<=Math.PI/2&&t.x>=e.x?"left":"right",this.getDefaultOffset()<=0&&(n="right"===n?"left":"right"),n},e.prototype.getArcPoint=function(t){return t},e.prototype.getPointAngle=function(t){var e=this.get("coord"),n={x:r.isArray(t.x)?t.x[0]:t.x,y:t.y[0]};this.transLabelPoint(n);var i={x:r.isArray(t.x)?t.x[1]:t.x,y:t.y[1]};this.transLabelPoint(i);var a=void 0,s=o.getPointAngle(e,n);if(t.points&&t.points[0].y===t.points[1].y)a=s;else{var u=o.getPointAngle(e,i);s>=u&&(u+=2*Math.PI),a=s+(u-s)/2}return a},e.prototype.getCirclePoint=function(t,e){var n=this.get("coord"),r=n.getCenter(),i=n.getRadius()+e,o=s(r,t,i);return o.angle=t,o.r=i,o},e}(i);t.exports=u},function(t,e,n){var r=n(552).MatrixUtil.vec2;t.exports={catmullRom2bezier:function(t,e,n){for(var i=!!e,o=[],a=0,s=t.length;a<s;a+=2)o.push([t[a],t[a+1]]);for(var u=function(t,e,n,i){var o=[],a=void 0,s=void 0,u=!!i,l=void 0,c=void 0;if(u){l=[1/0,1/0],c=[-1/0,-1/0];for(var h=0,f=t.length;h<f;h++){var p=t[h];l=r.min([],l,p),c=r.max([],c,p)}l=r.min([],l,i[0]),c=r.max([],c,i[1])}for(var d=0,g=t.length;d<g;d++){var v=t[d];if(n)a=t[d?d-1:g-1],s=t[(d+1)%g];else{if(0===d||d===g-1){o.push(v);continue}a=t[d-1],s=t[d+1]}var y=[];y=r.sub(y,s,a),y=r.scale(y,y,e);var m=r.distance(v,a),x=r.distance(v,s),b=m+x;0!==b&&(m/=b,x/=b);var _=r.scale([],y,-m),w=r.scale([],y,x),S=r.add([],v,_),M=r.add([],v,w);u&&(S=r.max([],S,l),S=r.min([],S,c),M=r.max([],M,l),M=r.min([],M,c)),o.push(S),o.push(M)}return n&&o.push(o.shift()),o}(o,.4,i,n),l=o.length,c=[],h=void 0,f=void 0,p=void 0,d=0;d<l-1;d++)h=u[2*d],f=u[2*d+1],p=o[d+1],c.push(["C",h[0],h[1],f[0],f[1],p[0],p[1]]);return i&&(h=u[l],f=u[l+1],p=o[0],c.push(["C",h[0],h[1],f[0],f[1],p[0],p[1]])),c}}},function(t,e,n){var r=n(549),i=n(662);t.exports={renderLabels:function(){var t=this.get("label");if(!r.isNil(t)){r.isNil(t.items)&&(t.items=[]);var e=this.addGroup(i,t);this.set("labelsGroup",e)}},resetLabels:function(t){var e=this,n=e.get("label");if(n){var i=e.get("labelsGroup"),o=i.getLabels(),a=o.length;t=t||n.items,r.each(t,function(t,n){if(n<a){var r=o[n];i.changeLabel(r,t)}else{var s=e.addLabel(t.text,t);s&&(s._id=t._id,s.set("coord",t.coord))}});for(var s=a-1;s>=t.length;s--)o[s].remove()}},addLabel:function(t,e){var n=this.get("labelsGroup"),r={},i=void 0;return n&&(r.text=t,r.x=e.x,r.y=e.y,r.point=e,r.textAlign=e.textAlign,e.rotate&&(r.rotate=e.rotate),i=n.addLabel(r)),i},removeLabels:function(){var t=this.get("labelsGroup");t&&t.remove(),this.set("labelsGroup",null)}}},function(t,e,n){var r=n(664),i=n(661),o=n(831),a={getLabelsClass:function(t){var e=r;return"polar"===t?e=i:"theta"===t&&(e=o),e}};t.exports=a},function(t,e,n){var r=n(549),i=n(582),o=n(551),a=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return r.assign(e,{marginRatio:.5,dodgeRatio:o.widthRatio.column,dodgeBy:null})},e.prototype.processAdjust=function(t){var e=r.Array.merge(t),n=this.dodgeBy,i=t;n&&(i=r.Array.group(e,n)),this.cacheMap={},this.adjDataArray=i,this.mergeData=e,this.adjustData(i,e),this.adjDataArray=null,this.mergeData=null},e.prototype.getDistribution=function(t){var e=this.adjDataArray,n=this.cacheMap,i=n[t];return i||(i={},r.each(e,function(e,n){var o=r.Array.values(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.prototype.adjustDim=function(t,e,n,i,o){var a=this,s=a.getDistribution(t),u=a.groupData(n,t);r.each(u,function(n,i){i=parseFloat(i);var u=void 0;u=1===e.length?{pre:e[0]-1,next:e[0]+1}:a.getAdjustRange(t,i,e),r.each(n,function(e){var n=e[t],r=s[n],i=r.indexOf(o);e[t]=a.getDodgeOffset(u,i,r.length)})})},e.prototype.getDodgeOffset=function(t,e,n){var r=t.pre,i=t.next,o=i-r,a=o*this.dodgeRatio/n,s=this.marginRatio*a;return(r+i)/2+(.5*(o-n*a-(n-1)*s)+((e+1)*a+e*s)-.5*a-.5*o)},e}(i);t.exports=a},function(t,e,n){var r=n(549),i=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return r.assign(e,{cacheMax:null,adjustNames:["y"]})},e.prototype._getMax=function(t){var e=this.mergeData,n=r.maxBy(e,function(e){var n=e[t];return r.isArray(n)?Math.max.apply(null,n):n})[t];return r.isArray(n)?Math.max.apply(null,n):n},e.prototype._getXValuesMax=function(){var t=this.yField,e=this.xField,n={},i=this.mergeData;return r.each(i,function(i){var o=i[e],a=i[t],s=r.isArray(a)?Math.max.apply(null,a):a;n[o]=n[o]||0,n[o]<s&&(n[o]=s)}),n},e.prototype.processAdjust=function(t){var e=r.Array.merge(t);this.mergeData=e,this._processSymmetric(t),this.mergeData=null},e.prototype._processSymmetric=function(t){var e=this.xField,n=this.yField,i=this._getMax(n),o=t[0][0],a=void 0;o&&r.isArray(o[n])&&(a=this._getXValuesMax()),r.each(t,function(t){r.each(t,function(t){var o=t[n],s=void 0;if(r.isArray(o)){var u=t[e],l=a[u];s=(i-l)/2;var c=[];r.each(o,function(t){c.push(s+t)}),t[n]=c}else s=(i-o)/2,t[n]=[s,o+s]})})},e}(n(582));t.exports=i},function(t,e,n){var r=n(549),i=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getAdjustOffset=function(t,e){var n=e-t;return t+.05*n+.9*n*Math.random()},e.prototype._adjustGroup=function(t,e,n,i){var o=this,a=o.getAdjustRange(e,n,i);r.each(t,function(t){t[e]=o.getAdjustOffset(a.pre,a.next)})},e.prototype.adjustDim=function(t,e,n){var i=this,o=i.groupData(n,t);r.each(o,function(n,r){r=parseFloat(r),i._adjustGroup(n,t,r,e)})},e}(n(582));t.exports=i},function(t,e,n){var r=n(549),i=function(t){function e(){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.apply(this,arguments))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return r.assign(e,{height:null,size:10,reverseOrder:!1,adjustNames:["y"]})},e.prototype.processOneDimStack=function(t){var e=this.xField,n=this.yField||"y",r=this.height,i={};this.reverseOrder&&(t=t.slice(0).reverse());for(var o=0;o<t.length;o++)for(var a=t[o],s=0;s<a.length;s++){var u=a[s],l=2*(u.size||this.size)/r,c=u[e];i[c]||(i[c]=l/2),u[n]=i[c],i[c]+=l}},e.prototype.processAdjust=function(t){this.yField?this.processStack(t):this.processOneDimStack(t)},e.prototype.processStack=function(t){var e=this.xField,n=this.yField,i=t.length,o={positive:{},negative:{}};this.reverseOrder&&(t=t.slice(0).reverse());for(var a=0;a<i;a++)for(var s=t[a],u=0;u<s.length;u++){var l=s[u],c=l[e]||0,h=l[n]||0,f=c.toString(),p=(h=r.isArray(h)?h[1]:h)>=0?"positive":"negative";o[p][f]||(o[p][f]=0),l[n]=[o[p][f],h+o[p][f]],o[p][f]+=h}},e}(n(582));t.exports=i},function(t,e,n){var r=n(582);r.Stack=n(838),r.Jitter=n(837),r.Symmetric=n(836),r.Dodge=n(835),t.exports=r},function(t,e,n){var r,i,o=n(549),a=n(665),s=o.deepMix({},a,{background:{fill:"#1F1F1F",radius:2},plotBackground:{fill:"#1F1F1F"},axis:{top:{label:{textStyle:{fill:"#A6A6A6"}},line:{stroke:"#737373"},tickLine:{stroke:"#737373"}},bottom:{label:{textStyle:{fill:"#A6A6A6"}},line:{stroke:"#737373"},tickLine:{stroke:"#737373"}},left:{label:{textStyle:{fill:"#A6A6A6"}},grid:{lineStyle:{stroke:"#404040"}}},right:{label:{textStyle:{fill:"#A6A6A6"}},grid:{lineStyle:{stroke:"#404040"}}},circle:{label:{textStyle:{fill:"#A6A6A6"}},line:{stroke:"#737373"},tickLine:{stroke:"#737373"},grid:{lineStyle:{stroke:"#404040"}}},radius:{label:{textStyle:{fill:"#A6A6A6"}},line:{stroke:"#737373"},tickLine:{stroke:"#737373"},grid:{lineStyle:{stroke:"#404040"}}},helix:{line:{stroke:"#737373"},tickLine:{stroke:"#737373"}}},label:{textStyle:{fill:"#A6A6A6"}},legend:{right:{textStyle:{fill:"#737373"},unCheckColor:"#bfbfbf"},left:{textStyle:{fill:"#737373"},unCheckColor:"#bfbfbf"},top:{textStyle:{fill:"#737373"},unCheckColor:"#bfbfbf"},bottom:{textStyle:{fill:"#737373"},unCheckColor:"#bfbfbf"},html:(r={},r["g2-legend"]={color:"#D9D9D9"},r),gradient:{textStyle:{fill:"#D9D9D9"},lineStyle:{stroke:"#404040"}}},tooltip:(i={},i["g2-tooltip"]={color:"#D9D9D9"},i),tooltipCrosshairsRect:{type:"rect",style:{fill:"#fff",opacity:.1}},tooltipCrosshairsLine:{style:{stroke:"rgba(255, 255, 255, 0.45)"}},guide:{line:{text:{style:{fill:"#A6A6A6"}}},text:{style:{fill:"#A6A6A6"}},region:{style:{lineWidth:0,fill:"#000",fillOpacity:.04}}}});t.exports=s},function(t,e,n){var r={default:n(665),dark:n(840)};t.exports=r},function(t,e,n){var r=n(549),i=function(t){function e(n){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);var r=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.call(this,n));return r.names=["x","y"],r.type="position",r}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.mapping=function(t,e){var n=this.scales,i=this.coord,o=n[0],a=n[1],s=void 0,u=void 0,l=void 0;if(r.isNil(t)||r.isNil(e))return[];if(r.isArray(e)&&r.isArray(t)){s=[],u=[];for(var c=0,h=0;c<t.length&&h<e.length;c++,h++)l=i.convertPoint({x:o.scale(t[c]),y:a.scale(e[h])}),s.push(l.x),u.push(l.y)}else if(r.isArray(e))t=o.scale(t),u=[],r.each(e,function(e){e=a.scale(e),l=i.convertPoint({x:t,y:e}),s&&s!==l.x?(r.isArray(s)||(s=[s]),s.push(l.x)):s=l.x,u.push(l.y)});else if(r.isArray(t))e=a.scale(e),s=[],r.each(t,function(t){t=o.scale(t),l=i.convertPoint({x:t,y:e}),u&&u!==l.y?(r.isArray(u)||(u=[u]),u.push(l.y)):u=l.y,s.push(l.x)});else{t=o.scale(t),e=a.scale(e);var f=i.convertPoint({x:t,y:e});s=f.x,u=f.y}return[s,u]},e}(n(573));t.exports=i},function(t,e,n){var r=function(t){function e(n){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);var r=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.call(this,n));return r.names=["shape"],r.type="shape",r.gradient=null,r}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getLinearValue=function(t){var e=this.values;return e[Math.round((e.length-1)*t)]},e}(n(573));t.exports=r},function(t,e,n){var r=function(t){function e(n){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);var r=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.call(this,n));return r.names=["opacity"],r.type="opacity",r.gradient=null,r}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e}(n(573));t.exports=r},function(t,e,n){var r=function(t){function e(n){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);var r=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.call(this,n));return r.names=["size"],r.type="size",r.gradient=null,r}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e}(n(573));t.exports=r},function(t,e,n){var r=n(616),i=n(573),o=n(549),a=function(t){function e(n){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);var r=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.call(this,n));return r.names=["color"],r.type="color",r.gradient=null,o.isString(r.values)&&(r.linear=!0),r}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getLinearValue=function(t){var e=this.gradient;if(!e){var n=this.values;e=r.gradient(n),this.gradient=e}return e(t)},e}(i);t.exports=a},function(t,e,n){var r;
/*!
* EventEmitter v5.2.4 - git.io/ee
* Unlicense - http://unlicense.org/
* Oliver Caldwell - http://oli.me.uk/
* @preserve
*/!function(e){"use strict";function i(){}var o=i.prototype,a=e.EventEmitter;function s(t,e){for(var n=t.length;n--;)if(t[n].listener===e)return n;return-1}function u(t){return function(){return this[t].apply(this,arguments)}}o.getListeners=function(t){var e,n,r=this._getEvents();if(t instanceof RegExp)for(n in e={},r)r.hasOwnProperty(n)&&t.test(n)&&(e[n]=r[n]);else e=r[t]||(r[t]=[]);return e},o.flattenListeners=function(t){var e,n=[];for(e=0;e<t.length;e+=1)n.push(t[e].listener);return n},o.getListenersAsObject=function(t){var e,n=this.getListeners(t);return n instanceof Array&&((e={})[t]=n),e||n},o.addListener=function(t,e){if(!function t(e){return"function"==typeof e||e instanceof RegExp||!(!e||"object"!=typeof e)&&t(e.listener)}(e))throw new TypeError("listener must be a function");var n,r=this.getListenersAsObject(t),i="object"==typeof e;for(n in r)r.hasOwnProperty(n)&&-1===s(r[n],e)&&r[n].push(i?e:{listener:e,once:!1});return this},o.on=u("addListener"),o.addOnceListener=function(t,e){return this.addListener(t,{listener:e,once:!0})},o.once=u("addOnceListener"),o.defineEvent=function(t){return this.getListeners(t),this},o.defineEvents=function(t){for(var e=0;e<t.length;e+=1)this.defineEvent(t[e]);return this},o.removeListener=function(t,e){var n,r,i=this.getListenersAsObject(t);for(r in i)i.hasOwnProperty(r)&&-1!==(n=s(i[r],e))&&i[r].splice(n,1);return this},o.off=u("removeListener"),o.addListeners=function(t,e){return this.manipulateListeners(!1,t,e)},o.removeListeners=function(t,e){return this.manipulateListeners(!0,t,e)},o.manipulateListeners=function(t,e,n){var r,i,o=t?this.removeListener:this.addListener,a=t?this.removeListeners:this.addListeners;if("object"!=typeof e||e instanceof RegExp)for(r=n.length;r--;)o.call(this,e,n[r]);else for(r in e)e.hasOwnProperty(r)&&(i=e[r])&&("function"==typeof i?o.call(this,r,i):a.call(this,r,i));return this},o.removeEvent=function(t){var e,n=typeof t,r=this._getEvents();if("string"===n)delete r[t];else if(t instanceof RegExp)for(e in r)r.hasOwnProperty(e)&&t.test(e)&&delete r[e];else delete this._events;return this},o.removeAllListeners=u("removeEvent"),o.emitEvent=function(t,e){var n,r,i,o,a=this.getListenersAsObject(t);for(o in a)if(a.hasOwnProperty(o))for(n=a[o].slice(0),i=0;i<n.length;i++)!0===(r=n[i]).once&&this.removeListener(t,r.listener),r.listener.apply(this,e||[])===this._getOnceReturnValue()&&this.removeListener(t,r.listener);return this},o.trigger=u("emitEvent"),o.emit=function(t){var e=Array.prototype.slice.call(arguments,1);return this.emitEvent(t,e)},o.setOnceReturnValue=function(t){return this._onceReturnValue=t,this},o._getOnceReturnValue=function(){return!this.hasOwnProperty("_onceReturnValue")||this._onceReturnValue},o._getEvents=function(){return this._events||(this._events={})},i.noConflict=function(){return e.EventEmitter=a,i},void 0===(r=function(){return i}.call(e,n,e,t))||(t.exports=r)}(this||{})},function(t,e,n){var r=n(617),i=n(562),o=n(549),a=n(660),s=n(551),u=n(790);function l(t,e,n){var r=(t-e)/(n-e);return r>=0&&r<=1}function c(t,e){var n=!1;if(t)if("theta"===t.type){var r=t.start,i=t.end;n=l(e.x,r.x,i.x)&&l(e.y,r.y,i.y)}else{var o=t.invert(e);n=o.x>=0&&o.y>=0&&o.x<=1&&o.y<=1}return n}var h=function(t){function e(n){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);var r=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.call(this,n)),a=r;return o.each(i,function(t,e){var n=o.lowerFirst(e);a[n]=function(e){var n=new t(e);return a.addGeom(n),n}}),r.init(),r}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.getDefaultCfg=function(){return{viewContainer:null,coord:null,start:{x:0,y:0},end:{x:1,y:1},geoms:[],scales:{},options:{},scaleController:null,padding:0,parent:null,tooltipEnable:!0,animate:!0,visible:!0}},e.prototype.init=function(){this._initViewPlot(),this.get("data")&&this._initData(this.get("data")),this._initOptions(),this._initControllers(),this._bindEvents()},e.prototype._initOptions=function(){var t=this,e=o.mix({},t.get("options"));e.scales||(e.scales={}),e.coord||(e.coord={}),!1===e.animate&&this.set("animate",!1),(!1===e.tooltip||o.isNull(e.tooltip))&&this.set("tooltipEnable",!1),e.geoms&&e.geoms.length&&o.each(e.geoms,function(e){t._createGeom(e)});var n=t.get("scaleController");n&&(n.defs=e.scales);var r=t.get("coordController");r&&r.reset(e.coord),this.set("options",e)},e.prototype._createGeom=function(t){var e=t.type,n=void 0;this[e]&&(n=this[e](),o.each(t,function(t,e){if(n[e])if(o.isObject(t)&&t.field)if("label"===t)n[e](t.field,t.callback,t.cfg);else{var r=void 0;o.each(t,function(t,e){"field"!==e&&(r=t)}),n[e](t.field,r)}else n[e](t)}))},e.prototype._initControllers=function(){var t=this.get("options"),e=new a.Scale({defs:t.scales}),n=new a.Coord(t.coord);this.set("scaleController",e),this.set("coordController",n);var r=new a.Axis;this.set("axisController",r);var i=new a.Guide({options:t.guides||[]});this.set("guideController",i)},e.prototype._initViewPlot=function(){this.get("viewContainer")||this.set("viewContainer",this.get("middlePlot"))},e.prototype._initGeoms=function(){for(var t=this.get("geoms"),e=this.get("filteredData"),n=this.get("coord"),r=this.get("_id"),i=0;i<t.length;i++){var o=t[i];o.set("data",e),o.set("coord",n),o.set("_id",r+"-geom"+i),o.set("keyFields",this.get("keyFields")),o.init()}},e.prototype._clearGeoms=function(){for(var t=this.get("geoms"),e=0;e<t.length;e++){t[e].clear()}},e.prototype._removeGeoms=function(){for(var t=this.get("geoms");t.length>0;){t.shift().destroy()}},e.prototype._drawGeoms=function(){for(var t=this.get("geoms"),e=this.get("coord"),n=0;n<t.length;n++){var r=t[n];r.setCoord(e),r.paint()}},e.prototype.isShapeInView=function(t){var e=this.get("_id"),n=t._id;return n?n.split("-")[0]===e:t.get("parent").get("viewId")===e},e.prototype.getViewRegion=function(){var t=this.get("parent"),e=void 0,n=void 0;if(t){var r=t.getViewRegion(),i=this._getViewRegion(r.start,r.end);e=i.start,n=i.end}else e=this.get("start"),n=this.get("end");return{start:e,end:n}},e.prototype._getViewRegion=function(t,e){var n=this.get("start"),r=this.get("end"),i=n.x,a=1-r.y,s=r.x,u=1-n.y,l=this.get("padding"),c=o.toAllPadding(l),h=c[0],f=c[1],p=c[2],d=c[3];return{start:{x:i*(e.x-t.x)+t.x+d,y:a*(e.y-t.y)+t.y-p},end:{x:s*(e.x-t.x)+t.x-f,y:u*(e.y-t.y)+t.y+h}}},e.prototype._createCoord=function(){var t=this.get("coordController"),e=this.getViewRegion(),n=t.createCoord(e.start,e.end);this.set("coord",n)},e.prototype._renderAxes=function(){var t=this.get("options").axes;if(!1!==t){var e=this.get("axisController");e.container=this.get("backPlot"),e.coord=this.get("coord"),e.options=t||{};var n=this.getXScale(),r=this.getYScales(),i=this.get("_id");e.createAxis(n,r,i)}},e.prototype._renderGuides=function(){var t=this.get("guideController");if(!o.isEmpty(t.options)){var e=this.get("coord");t.backContainer=this.get("backPlot"),t.frontContainer=this.get("frontPlot"),t.xScales=this._getScales("x"),t.yScales=this._getScales("y"),t.render(e)}},e.prototype._bindEvents=function(){var t=new a.Event({view:this,canvas:this.get("canvas")});t.bindEvents(),this.set("eventController",t)},e.prototype._clearEvents=function(){var t=this.get("eventController");t&&t.clearEvents()},e.prototype._getScales=function(t){for(var e=this.get("geoms"),n={},r=0;r<e.length;r++){var i=e[r],o="x"===t?i.getXScale():i.getYScale();o&&!n[o.field]&&(n[o.field]=o)}return n},e.prototype._adjustScale=function(){this._setCatScalesRange();for(var t=this.get("geoms"),e=this.get("scaleController").defs,n=0;n<t.length;n++){var r=t[n];if("interval"===r.get("type")){var i=r.getYScale(),o=i.field;e[o]&&e[o].min||!(i.min>0)||"time"===i.type||i.change({min:0})}}},e.prototype._setCatScalesRange=function(){var t=this.get("coord"),e=this.getXScale(),n=this.getYScales(),r=[];e&&r.push(e),r=r.concat(n);var i=t.isPolar&&function(t){var e=t.startAngle,n=t.endAngle;return!(!o.isNil(e)&&!o.isNil(n)&&n-e<2*Math.PI)}(t),a=this.get("scaleController").defs;o.each(r,function(e){if((e.isCategory||e.isIdentity)&&e.values&&(!a[e.field]||!a[e.field].range)){var n=e.values.length,r=void 0;if(1===n)r=[.5,1];else{var o=0;r=i?t.isTransposed?[(o=1/n*s.widthRatio.multiplePie)/2,1-o/2]:[0,1-1/n]:[o=1/n*1/2,1-o]}e.range=r}})},e.prototype.getXScale=function(){var t=this.get("geoms"),e=null;return o.isEmpty(t)||(e=t[0].getXScale()),e},e.prototype.getYScales=function(){for(var t=this.get("geoms"),e=[],n=0;n<t.length;n++){var r=t[n].getYScale();r&&-1===o.indexOf(e,r)&&e.push(r)}return e},e.prototype.getXY=function(t){var e=this.get("coord"),n=this._getScales("x"),r=this._getScales("y"),i=void 0,a=void 0;for(var s in t)n[s]&&(i=n[s].scale(t[s])),r[s]&&(a=r[s].scale(t[s]));return o.isNil(i)||o.isNil(a)?null:e.convert({x:i,y:a})},e.prototype.getSnapRecords=function(t){var e=this.get("geoms"),n=[];return o.each(e,function(e){var r=e.get("dataArray"),i=void 0;o.each(r,function(r){(i=e.findPoint(t,r))&&n.push(i)})}),n},e.prototype.addGeom=function(t){this.get("geoms").push(t),t.set("view",this);var e=this.get("viewContainer");t.set("container",e),t.set("animate",this.get("animate")),t.bindEvents()},e.prototype.removeGeom=function(t){var e=this.get("geoms");o.Array.remove(e,t),t.destroy()},e.prototype.createScale=function(t,e){var n=this.get("scales"),r=this.get("parent"),i=n[t];if(!e){var o=this.get("filteredData"),a=this._getFieldsForLegend();e=o.length&&-1===a.indexOf(t)?o:this.get("data")}var s=this.get("scaleController");if(i){if(i.sync){var u=s.createScale(t,e);this._syncScale(i,u)}}else{if((i=s.createScale(t,e)).sync&&r){var l=r.createScale(t,e);i=this._getSyncScale(l,i)}n[t]=i}return i},e.prototype._getFieldsForLegend=function(){var t=[],e=this.get("geoms");return o.each(e,function(e){var n=e.getFieldsForLegend();t=t.concat(n)}),o.uniq(t)},e.prototype._getSyncScale=function(t,e){return t.type!==e.type?e:(this._syncScale(t,e),t)},e.prototype._syncScale=function(t,e){var n=o.union(t.values,e.values);if(e.isLinear){var r=Math.max(t.max,e.max),i=Math.min(t.min,e.min);t.max===r&&t.min===i||t.change({min:i,max:r,values:n})}n.length!==t.values.length&&t.change({values:n})},e.prototype.getFilteredValues=function(t){var e=this.get("scales")[t].values,n=this._getFilters();return n&&n[t]?e.filter(n[t]):e.slice(0)},e.prototype.filter=function(t,e){var n=this.get("options");n.filters||(n.filters={}),n.filters[t]=e},e.prototype._getFilters=function(){return this.get("options").filters},e.prototype.execFilter=function(t){var e=this._getFilters();return e&&(t=t.filter(function(t){var n=!0;return o.each(e,function(e,r){if(e&&!(n=e(t[r],t)))return!1}),n})),t},e.prototype.axis=function(t,e){var n=this.get("options");!1===t?n.axes=!1:(n.axes||(n.axes={}),n.axes[t]=e);return this},e.prototype.guide=function(){return this.get("guideController")},e.prototype._getKeyFields=function(t){var e=[];o.each(t,function(t,n){t.key&&e.push(n)}),this.set("keyFields",e)},e.prototype.scale=function(t,e){var n=this.get("options").scales;return o.isObject(t)?o.mix(n,t):n[t]=e,this._getKeyFields(n),this},e.prototype.tooltip=function(t){return this.set("tooltipEnable",t),this},e.prototype.animate=function(t){return this.get("options").animate=t,this.set("animate",t),this},e.prototype.changeOptions=function(t){return this.set("options",t),this._initOptions(t),this},e.prototype.getViewsByPoint=function(t){var e=[],n=this.get("views");return c(this.get("coord"),t)&&e.push(this),o.each(n,function(n){n.get("visible")&&c(n.get("coord"),t)&&e.push(n)}),e},e.prototype.eachShape=function(t){var e=this,n=e.get("views"),r=e.get("canvas");o.each(n,function(e){e.eachShape(t)});var i=this.get("geoms");return o.each(i,function(n){var r=n.getShapes();o.each(r,function(r){var i=r.get("origin");if(o.isArray(i)){var a=i.map(function(t){return t._origin});t(a,r,n,e)}else{var s=i._origin;t(s,r,n,e)}})}),r.draw(),this},e.prototype.filterShape=function(t){return this.eachShape(function(e,n,r,i){t(e,n,r,i)?n.set("visible",!0):n.set("visible",!1)}),this},e.prototype.clearInner=function(){this.set("scales",{}),this.get("options").geoms=null,this._clearGeoms(),this.get("guideController")&&this.get("guideController").reset(),this.get("axisController")&&this.get("axisController").clear()},e.prototype.clear=function(){return this.get("options").filters=null,this._removeGeoms(),this.clearInner(),this.get("guideController")&&this.get("guideController").clear(),this.set("isUpdate",!1),this.set("keyFields",[]),this},e.prototype.coord=function(t,e){var n=this.get("coordController");return n.reset({type:t,cfg:e}),n},e.prototype.resetCoord=function(){this._createCoord()},e.prototype.source=function(t,e){return this._initData(t),e&&this.scale(e),this.emit("setdata"),this},e.prototype.changeData=function(t){return this.emit("beforechangedata"),this._initData(t),this.emit("afterchangedata"),this.repaint(),this},e.prototype._initData=function(t){var e=this.get("dataView");e&&(e.off("change",o.getWrapBehavior(this,"_onViewChange")),this.set("dataView",null)),t&&t.isDataView&&(t.on("change",o.wrapBehavior(this,"_onViewChange")),this.set("dataView",t),t=t.rows),this.set("data",t)},e.prototype._onViewChange=function(){this.emit("beforechangedata");var t=this.get("dataView").rows;this.set("data",t),this.emit("afterchangedata"),this.repaint()},e.prototype.beforeRender=function(){var t=this.get("views");o.each(t,function(t){t.beforeRender()}),this.initView()},e.prototype.drawComponents=function(){var t=this.get("views");o.each(t,function(t){t.drawComponents()}),this._renderGuides(),this._renderAxes()},e.prototype.drawCanvas=function(t){if(!t){var e=this.get("views");this.get("backPlot").sort();var n=this.get("canvas");if(this.get("animate")){var r=this.get("isUpdate");o.each(e,function(t){u.execAnimation(t,r)}),u.execAnimation(this,r)}else n.draw()}},e.prototype.render=function(t){return this.clearInner(),this.emit("beforerender"),this.beforeRender(),this.emit("beforepaint"),this.drawComponents(),this.paint(),this.emit("afterpaint"),this.drawCanvas(t),this.emit("afterrender"),this.set("rendered",!0),this},e.prototype.initView=function(){var t=this.get("data")||[],e=this.execFilter(t);this.set("filteredData",e),this._createCoord(),this._initGeoms(),this._adjustScale()},e.prototype.paint=function(){var t=this.get("views");o.each(t,function(t){t.paint()});var e=this.get("data");o.isEmpty(e)||this._drawGeoms(),this.get("visible")||this.changeVisible(!1,!0)},e.prototype.changeVisible=function(t,e){var n=this.get("geoms");(o.each(n,function(e){e.get("visible")&&e.changeVisible(t,!0)}),this.get("axisController")&&this.get("axisController").changeVisible(t),this.get("guideController")&&this.get("guideController").changeVisible(t),e)||this.get("canvas").draw()},e.prototype.repaint=function(){this.set("isUpdate",!0),this.clearInner(),this.render()},e.prototype.destroy=function(){this._clearEvents();var e=this.get("dataView");e&&e.off("change",o.getWrapBehavior(this,"_onViewChange")),this.clear(),t.prototype.destroy.call(this)},e}(r);t.exports=h},function(t,e,n){var r=n(549),i=n(552),o=i.PathUtil;function a(t,e){var n=function(t){if(r.isEmpty(t))return null;var e=t[0].x,n=t[0].x,i=t[0].y,o=t[0].y;return r.each(t,function(t){e=e>t.x?t.x:e,n=n<t.x?t.x:n,i=i>t.y?t.y:i,o=o<t.y?t.y:o}),{minX:e,maxX:n,minY:i,maxY:o,centerX:(e+n)/2,centerY:(i+o)/2}}(t.points||t.get("origin").points),i=void 0,o=void 0,a=e.startAngle,s=e.endAngle-a;return e.isTransposed?(i=n.maxY*s,o=n.minY*s):(i=n.maxX*s,o=n.minX*s),{startAngle:o+=a,endAngle:i+=a}}function s(t,e,n){var i={};return t.delay&&(i.delay=r.isFunction(t.delay)?t.delay(e,n):t.delay),i.easing=r.isFunction(t.easing)?t.easing(e,n):t.easing,i.duration=r.isFunction(t.duration)?t.duration(e,n):t.duration,i.callback=t.callback,i}function u(t,e){var n=t._id,r=t.get("index"),i=t.getBBox(),o=t.get("origin").points,a=(i.minX+i.maxX)/2,u=void 0,l=[a,u=o[0].y-o[1].y<=0?i.maxY:i.minY,1];t.apply(l),t.attr("transform",[["t",-a,-u],["s",1,.01],["t",a,u]]);var c={transform:[["t",-a,-u],["s",1,100],["t",a,u]]},h=s(e,r,n);t.animate(c,h.duration,h.easing,h.callback,h.delay)}function l(t,e){var n=t._id,r=t.get("index"),i=t.getBBox(),o=t.get("origin").points,a=void 0,u=(i.minY+i.maxY)/2,l=[a=o[0].y-o[1].y>0?i.maxX:i.minX,u,1];t.apply(l),t.attr({transform:[["t",-a,-u],["s",.01,1],["t",a,u]]});var c={transform:[["t",-a,-u],["s",100,1],["t",a,u]]},h=s(e,r,n);t.animate(c,h.duration,h.easing,h.callback,h.delay)}function c(t,e,n){var r=t._id,i=t.get("index"),o=void 0,a=void 0;if(n.isPolar&&"point"!==t.name)o=n.getCenter().x,a=n.getCenter().y;else{var u=t.getBBox();o=(u.minX+u.maxX)/2,a=(u.minY+u.maxY)/2}var l=[o,a,1];t.apply(l),t.attr({transform:[["t",-o,-a],["s",.01,.01],["t",o,a]]});var c={transform:[["t",-o,-a],["s",100,100],["t",o,a]]},h=s(e,i,r);t.animate(c,h.duration,h.easing,h.callback,h.delay)}function h(t,e){if("path"===t.get("type")){var n=t._id,r=t.get("index"),i=o.pathToAbsolute(t.attr("path"));t.attr("path",[i[0]]);var a={path:i},u=s(e,r,n);t.animate(a,u.duration,u.easing,u.callback,u.delay)}}function f(t,e,n,r,o){var a=function(t){var e=t.start,n=t.end,r=t.getWidth(),o=t.getHeight(),a=void 0,s=void 0,u=void 0,l=void 0,c=void 0;return t.isPolar?(l=t.getRadius(),u=t.getCenter(),a=t.startAngle,s=t.endAngle,(c=new i.Fan({attrs:{x:u.x,y:u.y,rs:0,re:l+200,startAngle:a,endAngle:a}})).endState={endAngle:s}):(c=new i.Rect({attrs:{x:e.x-200,y:n.y-200,width:t.isTransposed?r+400:0,height:t.isTransposed?0:o+400}}),t.isTransposed?c.endState={height:o+400}:c.endState={width:r+400}),c.isClip=!0,c}(n),u=t.get("canvas"),l=t._id,c=t.get("index"),h=void 0;r?(a.attr("startAngle",r),a.attr("endAngle",r),h={endAngle:o}):h=a.endState,a.set("canvas",u),t.attr("clip",a),t.setSilent("animating",!0);var f=s(e,c,l);a.animate(h,f.duration,f.easing,function(){t&&!t.get("destroyed")&&(t.attr("clip",null),t.setSilent("cacheShape",null),t.setSilent("animating",!1),a.remove())},f.delay)}function p(t,e){var n=t._id,i=t.get("index"),o=r.isNil(t.attr("fillOpacity"))?1:t.attr("fillOpacity"),a=r.isNil(t.attr("strokeOpacity"))?1:t.attr("strokeOpacity");t.attr("fillOpacity",0),t.attr("strokeOpacity",0);var u={fillOpacity:o,strokeOpacity:a},l=s(e,i,n);t.animate(u,l.duration,l.easing,l.callback,l.delay)}function d(t,e,n){var r=a(t,n),i=r.endAngle;f(t,e,n,r.startAngle,i)}t.exports={enter:{clipIn:f,zoomIn:c,pathIn:h,scaleInY:u,scaleInX:l,fanIn:d,fadeIn:p},leave:{lineWidthOut:function(t,e){var n={lineWidth:0,opacity:0},r=t._id,i=s(e,t.get("index"),r);t.animate(n,i.duration,i.easing,function(){t.remove()},i.delay)},zoomOut:function(t,e,n){var r=t._id,i=t.get("index"),o=void 0,a=void 0;if(n.isPolar&&"point"!==t.name)o=n.getCenter().x,a=n.getCenter().y;else{var u=t.getBBox();o=(u.minX+u.maxX)/2,a=(u.minY+u.maxY)/2}var l=[o,a,1];t.apply(l);var c={transform:[["t",-o,-a],["s",.01,.01],["t",o,a]]},h=s(e,i,r);t.animate(c,h.duration,h.easing,function(){t.remove()},h.delay)},pathOut:function(t,e){if("path"===t.get("type")){var n=t._id,r=t.get("index"),i={path:[o.pathToAbsolute(t.attr("path"))[0]]},a=s(e,r,n);t.animate(i,a.duration,a.easing,function(){t.remove()},a.delay)}},fadeOut:function(t,e){var n=t._id,r={fillOpacity:0,strokeOpacity:0},i=s(e,t.get("index"),n);t.animate(r,i.duration,i.easing,function(){t.remove()},i.delay)}},appear:{clipIn:f,zoomIn:c,pathIn:h,scaleInY:u,scaleInX:l,fanIn:d,fadeIn:p},update:{fadeIn:p,fanIn:d}}},function(t,e){var n="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",r="["+n+"]",i="\\d+",o="[\\u2700-\\u27bf]",a="[a-z\\xdf-\\xf6\\xf8-\\xff]",s="[^\\ud800-\\udfff"+n+i+"\\u2700-\\u27bfa-z\\xdf-\\xf6\\xf8-\\xffA-Z\\xc0-\\xd6\\xd8-\\xde]",u="(?:\\ud83c[\\udde6-\\uddff]){2}",l="[\\ud800-\\udbff][\\udc00-\\udfff]",c="[A-Z\\xc0-\\xd6\\xd8-\\xde]",h="(?:"+a+"|"+s+")",f="(?:"+c+"|"+s+")",p="(?:[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]|\\ud83c[\\udffb-\\udfff])?",d="[\\ufe0e\\ufe0f]?"+p+("(?:\\u200d(?:"+["[^\\ud800-\\udfff]",u,l].join("|")+")[\\ufe0e\\ufe0f]?"+p+")*"),g="(?:"+[o,u,l].join("|")+")"+d,v=RegExp([c+"?"+a+"+(?:['’](?:d|ll|m|re|s|t|ve))?(?="+[r,c,"$"].join("|")+")",f+"+(?:['’](?:D|LL|M|RE|S|T|VE))?(?="+[r,c+h,"$"].join("|")+")",c+"?"+h+"+(?:['’](?:d|ll|m|re|s|t|ve))?",c+"+(?:['’](?:D|LL|M|RE|S|T|VE))?","\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",i,g].join("|"),"g");t.exports=function(t){return t.match(v)||[]}},function(t,e){var n=/[a-z][A-Z]|[A-Z]{2,}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;t.exports=function(t){return n.test(t)}},function(t,e){var n=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;t.exports=function(t){return t.match(n)||[]}},function(t,e,n){var r=n(852),i=n(851),o=n(569),a=n(850);t.exports=function(t,e,n){return t=o(t),void 0===(e=n?void 0:e)?i(t)?a(t):r(t):t.match(e)||[]}},function(t,e){t.exports=function(t){return function(e){return null==t?void 0:t[e]}}},function(t,e,n){var r=n(854)({"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","Ç":"C","ç":"c","Ð":"D","ð":"d","È":"E","É":"E","Ê":"E","Ë":"E","è":"e","é":"e","ê":"e","ë":"e","Ì":"I","Í":"I","Î":"I","Ï":"I","ì":"i","í":"i","î":"i","ï":"i","Ñ":"N","ñ":"n","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","Ù":"U","Ú":"U","Û":"U","Ü":"U","ù":"u","ú":"u","û":"u","ü":"u","Ý":"Y","ý":"y","ÿ":"y","Æ":"Ae","æ":"ae","Þ":"Th","þ":"th","ß":"ss","Ā":"A","Ă":"A","Ą":"A","ā":"a","ă":"a","ą":"a","Ć":"C","Ĉ":"C","Ċ":"C","Č":"C","ć":"c","ĉ":"c","ċ":"c","č":"c","Ď":"D","Đ":"D","ď":"d","đ":"d","Ē":"E","Ĕ":"E","Ė":"E","Ę":"E","Ě":"E","ē":"e","ĕ":"e","ė":"e","ę":"e","ě":"e","Ĝ":"G","Ğ":"G","Ġ":"G","Ģ":"G","ĝ":"g","ğ":"g","ġ":"g","ģ":"g","Ĥ":"H","Ħ":"H","ĥ":"h","ħ":"h","Ĩ":"I","Ī":"I","Ĭ":"I","Į":"I","İ":"I","ĩ":"i","ī":"i","ĭ":"i","į":"i","ı":"i","Ĵ":"J","ĵ":"j","Ķ":"K","ķ":"k","ĸ":"k","Ĺ":"L","Ļ":"L","Ľ":"L","Ŀ":"L","Ł":"L","ĺ":"l","ļ":"l","ľ":"l","ŀ":"l","ł":"l","Ń":"N","Ņ":"N","Ň":"N","Ŋ":"N","ń":"n","ņ":"n","ň":"n","ŋ":"n","Ō":"O","Ŏ":"O","Ő":"O","ō":"o","ŏ":"o","ő":"o","Ŕ":"R","Ŗ":"R","Ř":"R","ŕ":"r","ŗ":"r","ř":"r","Ś":"S","Ŝ":"S","Ş":"S","Š":"S","ś":"s","ŝ":"s","ş":"s","š":"s","Ţ":"T","Ť":"T","Ŧ":"T","ţ":"t","ť":"t","ŧ":"t","Ũ":"U","Ū":"U","Ŭ":"U","Ů":"U","Ű":"U","Ų":"U","ũ":"u","ū":"u","ŭ":"u","ů":"u","ű":"u","ų":"u","Ŵ":"W","ŵ":"w","Ŷ":"Y","ŷ":"y","Ÿ":"Y","Ź":"Z","Ż":"Z","Ž":"Z","ź":"z","ż":"z","ž":"z","IJ":"IJ","ij":"ij","Œ":"Oe","œ":"oe","ʼn":"'n","ſ":"s"});t.exports=r},function(t,e,n){var r=n(855),i=n(569),o=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,a=RegExp("[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]","g");t.exports=function(t){return(t=i(t))&&t.replace(o,r).replace(a,"")}},function(t,e,n){var r=n(669),i=n(856),o=n(853),a=RegExp("['’]","g");t.exports=function(t){return function(e){return r(o(i(e).replace(a,"")),t,"")}}},function(t,e,n){var r=n(857)(function(t,e,n){return t+(n?" ":"")+e.toUpperCase()});t.exports=r},function(t,e,n){var r=n(608),i=n(598),o=n(668),a=n(634),s=i(function(t){return o(r(t,1,a,!0))});t.exports=s},function(t,e,n){var r=n(630),i=n(671),o=n(569),a=Math.min;t.exports=function(t){var e=Math[t];return function(t,n){if(t=i(t),n=null==n?0:a(r(n),292)){var s=(o(t)+"e").split("e"),u=e(s[0]+"e"+(+s[1]+n));return+((s=(o(u)+"e").split("e"))[0]+"e"+(+s[1]-n))}return e(t)}}},function(t,e,n){var r=n(860)("round");t.exports=r},function(t,e,n){var r=n(569);t.exports=function(){var t=arguments,e=r(t[0]);return t.length<3?e:e.replace(t[1],t[2])}},function(t,e){t.exports=function(t,e,n,r,i){return i(t,function(t,i,o){n=r?(r=!1,t):e(n,t,i,o)}),n}},function(t,e,n){var r=n(669),i=n(583),o=n(566),a=n(863),s=n(80);t.exports=function(t,e,n){var u=s(t)?r:a,l=arguments.length<3;return u(t,o(e,4),n,l,i)}},function(t,e,n){var r=n(672),i=n(702),o=n(701);t.exports=function(t){return o(i(t,void 0,r),t+"")}},function(t,e,n){var r=n(631),i=n(721),o=n(596);t.exports=function(t,e,n){for(var a=-1,s=e.length,u={};++a<s;){var l=e[a],c=r(t,l);n(c,l)&&i(u,o(l,t),c)}return u}},function(t,e,n){var r=n(866),i=n(886);t.exports=function(t,e){return r(t,e,function(e,n){return i(t,n)})}},function(t,e){t.exports=function(t,e){return t<e}},function(t,e,n){var r=n(670),i=n(566),o=n(868);t.exports=function(t,e){return t&&t.length?r(t,i(e,2),o):void 0}},function(t,e){t.exports=function(t,e){return t>e}},function(t,e,n){var r=n(670),i=n(870),o=n(566);t.exports=function(t,e){return t&&t.length?r(t,o(e,2),i):void 0}},function(t,e,n){var r=n(698)("toLowerCase");t.exports=r},function(t,e){t.exports=function(t){return null===t}},function(t,e,n){var r=n(611);t.exports=function(t){return r(t)&&t!=+t}},function(t,e,n){var r=n(33).isFinite;t.exports=function(t){return"number"==typeof t&&r(t)}},function(t,e,n){var r=n(633);t.exports=function(t,e,n){var i=(n="function"==typeof n?n:void 0)?n(t,e):void 0;return void 0===i?r(t,e,void 0,n):!!i}},function(t,e,n){var r=n(50),i=n(49),o="[object Date]";t.exports=function(t){return i(t)&&r(t)==o}},function(t,e,n){var r=n(877),i=n(162),o=n(166),a=o&&o.isDate,s=a?i(a):r;t.exports=s},function(t,e,n){var r=n(671),i=1/0,o=1.7976931348623157e308;t.exports=function(t){return t?(t=r(t))===i||t===-i?(t<0?-1:1)*o:t==t?t:0:0===t?t:0}},function(t,e,n){var r=n(695),i=n(630),o=Math.max;t.exports=function(t,e,n){var a=null==t?0:t.length;if(!a)return-1;var s=null==n?0:i(n);return s<0&&(s=o(a+s,0)),r(t,e,s)}},function(t,e,n){var r=n(583);t.exports=function(t,e,n,i){return r(t,function(t,r,o){e(i,t,n(t),o)}),i}},function(t,e){t.exports=function(t,e,n,r){for(var i=-1,o=null==t?0:t.length;++i<o;){var a=t[i];e(r,a,n(a),t)}return r}},function(t,e,n){var r=n(882),i=n(881),o=n(566),a=n(80);t.exports=function(t,e){return function(n,s){var u=a(n)?r:i,l=e?e():{};return u(n,t,o(s,2),l)}}},function(t,e,n){var r=n(160),i=n(256),o=n(80),a=r?r.isConcatSpreadable:void 0;t.exports=function(t){return o(t)||i(t)||!!(a&&t&&t[a])}},,,,,,function(t,e,n){var r=n(583);t.exports=function(t,e){var n=[];return r(t,function(t,r,i){e(t,r,i)&&n.push(t)}),n}},function(t,e,n){var r=n(941),i=n(890),o=n(566),a=n(80);t.exports=function(t,e){return(a(t)?r:i)(t,o(e,3))}},function(t,e){t.exports={xAt:function(t,e,n,r,i){return e*Math.cos(t)*Math.cos(i)-n*Math.sin(t)*Math.sin(i)+r},yAt:function(t,e,n,r,i){return e*Math.sin(t)*Math.cos(i)+n*Math.cos(t)*Math.sin(i)+r},xExtrema:function(t,e,n){return Math.atan(-n/e*Math.tan(t))},yExtrema:function(t,e,n){return Math.atan(n/(e*Math.tan(t)))}}},function(t,e,n){var r=n(556);r.Rect=n(619),r.Rect=n(619),r.Circle=n(688),r.Ellipse=n(687),r.Path=n(686),r.Text=n(684),r.Line=n(683),r.Image=n(682),r.Polygon=n(681),r.Polyline=n(680),r.Arc=n(679),r.Fan=n(678),r.Cubic=n(677),r.Quadratic=n(676),r.Marker=n(675),t.exports=r},function(t,e,n){var r;
/*!
* EventEmitter v5.1.0 - git.io/ee
* Unlicense - http://unlicense.org/
* Oliver Caldwell - http://oli.me.uk/
* @preserve
*/!function(e){"use strict";function i(){}var o=i.prototype,a=e.EventEmitter;function s(t,e){for(var n=t.length;n--;)if(t[n].listener===e)return n;return-1}function u(t){return function(){return this[t].apply(this,arguments)}}o.getListeners=function(t){var e,n,r=this._getEvents();if(t instanceof RegExp)for(n in e={},r)r.hasOwnProperty(n)&&t.test(n)&&(e[n]=r[n]);else e=r[t]||(r[t]=[]);return e},o.flattenListeners=function(t){var e,n=[];for(e=0;e<t.length;e+=1)n.push(t[e].listener);return n},o.getListenersAsObject=function(t){var e,n=this.getListeners(t);return n instanceof Array&&((e={})[t]=n),e||n},o.addListener=function(t,e){if(!function t(e){return"function"==typeof e||e instanceof RegExp||!(!e||"object"!=typeof e)&&t(e.listener)}(e))throw new TypeError("listener must be a function");var n,r=this.getListenersAsObject(t),i="object"==typeof e;for(n in r)r.hasOwnProperty(n)&&-1===s(r[n],e)&&r[n].push(i?e:{listener:e,once:!1});return this},o.on=u("addListener"),o.addOnceListener=function(t,e){return this.addListener(t,{listener:e,once:!0})},o.once=u("addOnceListener"),o.defineEvent=function(t){return this.getListeners(t),this},o.defineEvents=function(t){for(var e=0;e<t.length;e+=1)this.defineEvent(t[e]);return this},o.removeListener=function(t,e){var n,r,i=this.getListenersAsObject(t);for(r in i)i.hasOwnProperty(r)&&-1!==(n=s(i[r],e))&&i[r].splice(n,1);return this},o.off=u("removeListener"),o.addListeners=function(t,e){return this.manipulateListeners(!1,t,e)},o.removeListeners=function(t,e){return this.manipulateListeners(!0,t,e)},o.manipulateListeners=function(t,e,n){var r,i,o=t?this.removeListener:this.addListener,a=t?this.removeListeners:this.addListeners;if("object"!=typeof e||e instanceof RegExp)for(r=n.length;r--;)o.call(this,e,n[r]);else for(r in e)e.hasOwnProperty(r)&&(i=e[r])&&("function"==typeof i?o.call(this,r,i):a.call(this,r,i));return this},o.removeEvent=function(t){var e,n=typeof t,r=this._getEvents();if("string"===n)delete r[t];else if(t instanceof RegExp)for(e in r)r.hasOwnProperty(e)&&t.test(e)&&delete r[e];else delete this._events;return this},o.removeAllListeners=u("removeEvent"),o.emitEvent=function(t,e){var n,r,i,o,a=this.getListenersAsObject(t);for(o in a)if(a.hasOwnProperty(o))for(n=a[o].slice(0),i=0;i<n.length;i++)!0===(r=n[i]).once&&this.removeListener(t,r.listener),r.listener.apply(this,e||[])===this._getOnceReturnValue()&&this.removeListener(t,r.listener);return this},o.trigger=u("emitEvent"),o.emit=function(t){var e=Array.prototype.slice.call(arguments,1);return this.emitEvent(t,e)},o.setOnceReturnValue=function(t){return this._onceReturnValue=t,this},o._getOnceReturnValue=function(){return!this.hasOwnProperty("_onceReturnValue")||this._onceReturnValue},o._getEvents=function(){return this._events||(this._events={})},i.noConflict=function(){return e.EventEmitter=a,i},void 0===(r=function(){return i}.call(e,n,e,t))||(t.exports=r)}(this||{})},function(t,e,n){var r=n(558),i=n(623),o=n(553),a=n(638),s=n(612),u=n(589),l=u.interpolate,c=u.interpolateArray,h={delay:"delay"};t.exports={stopAnimate:function(){var t=this.get("canvas");if(!this.get("destroyed")&&this.get("animating")){var e=this.attr("clip");e&&e.get("animating")&&e.stopAnimate();var n=this.get("animateTimer");n&&(n.stop(),this.setSilent("animateTimer",null));var r=this.get("animateCfg");r&&(this.attr(r.toAttrs),r.toM&&this.setMatrix(r.toM),r.callback&&r.callback(),this.setSilent("animateCfg",null)),this.setSilent("animating",!1),t.draw()}},animate:function(t,e,n,u){var f=arguments.length>4&&void 0!==arguments[4]?arguments[4]:0,p=this,d=p.get("canvas"),g=function(t){var e={M:null,attrs:{}};for(var n in t)"transform"===n?e.M=r.transform(p.getMatrix(),t[n]):"matrix"===n?e.M=t[n]:h[n]||(e.attrs[n]=t[n]);return e}(t),v=g.attrs,y=g.M,m=function(t){var e={};for(var n in t)e[n]=p.attr(n);return e}(v),x=o.clone(p.getMatrix()),b=t.repeat,_=p.get("animateTimer");function w(t){var e={};if(!p.get("destroyed")){var n=void 0;for(var r in v)if(!o.isEqual(m[r],v[r]))if("path"===r){var a=i.parsePathString(v[r]),s=i.parsePathString(m[r]);e[r]=[];for(var u=0;u<a.length;u++){for(var h=a[u],f=s[u],g=[],b=0;b<h.length;b++)o.isNumber(h[b])&&f?(n=l(f[b],h[b]),g.push(n(t))):g.push(h[b]);e[r].push(g)}}else n=l(m[r],v[r]),e[r]=n(t);if(y){var _=c(x,y)(t);p.setMatrix(_)}p.attr(e),d.draw()}}_&&_.stop(),o.isNumber(u)&&(f=u,u=null),o.isFunction(n)?(u=n,n="easeLinear"):n=n||"easeLinear",p.setSilent("animating",!0),p.setSilent("animateCfg",{toAttrs:v,toM:y,callback:u}),_=s.timer(function(t){b?function(t){var r=t%e/e;w(r=a[n](r))}(t):function(t){var r=t/e;r<1?w(r=a[n](r)):(w(1),u&&u(),p.setSilent("animating",!1),p.setSilent("animateCfg",null),p.setSilent("animateTimer",null),_.stop())}(t)},f),p.setSilent("animateTimer",_)}}},function(t,e,n){var r,i=n(624),o={};o.create=function(){var t=new i.ARRAY_TYPE(2);return t[0]=0,t[1]=0,t},o.clone=function(t){var e=new i.ARRAY_TYPE(2);return e[0]=t[0],e[1]=t[1],e},o.fromValues=function(t,e){var n=new i.ARRAY_TYPE(2);return n[0]=t,n[1]=e,n},o.copy=function(t,e){return t[0]=e[0],t[1]=e[1],t},o.set=function(t,e,n){return t[0]=e,t[1]=n,t},o.add=function(t,e,n){return t[0]=e[0]+n[0],t[1]=e[1]+n[1],t},o.subtract=function(t,e,n){return t[0]=e[0]-n[0],t[1]=e[1]-n[1],t},o.sub=o.subtract,o.multiply=function(t,e,n){return t[0]=e[0]*n[0],t[1]=e[1]*n[1],t},o.mul=o.multiply,o.divide=function(t,e,n){return t[0]=e[0]/n[0],t[1]=e[1]/n[1],t},o.div=o.divide,o.ceil=function(t,e){return t[0]=Math.ceil(e[0]),t[1]=Math.ceil(e[1]),t},o.floor=function(t,e){return t[0]=Math.floor(e[0]),t[1]=Math.floor(e[1]),t},o.min=function(t,e,n){return t[0]=Math.min(e[0],n[0]),t[1]=Math.min(e[1],n[1]),t},o.max=function(t,e,n){return t[0]=Math.max(e[0],n[0]),t[1]=Math.max(e[1],n[1]),t},o.round=function(t,e){return t[0]=Math.round(e[0]),t[1]=Math.round(e[1]),t},o.scale=function(t,e,n){return t[0]=e[0]*n,t[1]=e[1]*n,t},o.scaleAndAdd=function(t,e,n,r){return t[0]=e[0]+n[0]*r,t[1]=e[1]+n[1]*r,t},o.distance=function(t,e){var n=e[0]-t[0],r=e[1]-t[1];return Math.sqrt(n*n+r*r)},o.dist=o.distance,o.squaredDistance=function(t,e){var n=e[0]-t[0],r=e[1]-t[1];return n*n+r*r},o.sqrDist=o.squaredDistance,o.length=function(t){var e=t[0],n=t[1];return Math.sqrt(e*e+n*n)},o.len=o.length,o.squaredLength=function(t){var e=t[0],n=t[1];return e*e+n*n},o.sqrLen=o.squaredLength,o.negate=function(t,e){return t[0]=-e[0],t[1]=-e[1],t},o.inverse=function(t,e){return t[0]=1/e[0],t[1]=1/e[1],t},o.normalize=function(t,e){var n=e[0],r=e[1],i=n*n+r*r;return i>0&&(i=1/Math.sqrt(i),t[0]=e[0]*i,t[1]=e[1]*i),t},o.dot=function(t,e){return t[0]*e[0]+t[1]*e[1]},o.cross=function(t,e,n){var r=e[0]*n[1]-e[1]*n[0];return t[0]=t[1]=0,t[2]=r,t},o.lerp=function(t,e,n,r){var i=e[0],o=e[1];return t[0]=i+r*(n[0]-i),t[1]=o+r*(n[1]-o),t},o.random=function(t,e){e=e||1;var n=2*i.RANDOM()*Math.PI;return t[0]=Math.cos(n)*e,t[1]=Math.sin(n)*e,t},o.transformMat2=function(t,e,n){var r=e[0],i=e[1];return t[0]=n[0]*r+n[2]*i,t[1]=n[1]*r+n[3]*i,t},o.transformMat2d=function(t,e,n){var r=e[0],i=e[1];return t[0]=n[0]*r+n[2]*i+n[4],t[1]=n[1]*r+n[3]*i+n[5],t},o.transformMat3=function(t,e,n){var r=e[0],i=e[1];return t[0]=n[0]*r+n[3]*i+n[6],t[1]=n[1]*r+n[4]*i+n[7],t},o.transformMat4=function(t,e,n){var r=e[0],i=e[1];return t[0]=n[0]*r+n[4]*i+n[12],t[1]=n[1]*r+n[5]*i+n[13],t},o.forEach=(r=o.create(),function(t,e,n,i,o,a){var s,u;for(e||(e=2),n||(n=0),u=i?Math.min(i*e+n,t.length):t.length,s=n;s<u;s+=e)r[0]=t[s],r[1]=t[s+1],o(r,r,a),t[s]=r[0],t[s+1]=r[1];return t}),o.str=function(t){return"vec2("+t[0]+", "+t[1]+")"},o.exactEquals=function(t,e){return t[0]===e[0]&&t[1]===e[1]},o.equals=function(t,e){var n=t[0],r=t[1],o=e[0],a=e[1];return Math.abs(n-o)<=i.EPSILON*Math.max(1,Math.abs(n),Math.abs(o))&&Math.abs(r-a)<=i.EPSILON*Math.max(1,Math.abs(r),Math.abs(a))},t.exports=o},function(t,e,n){var r,i=n(624),o={};o.create=function(){var t=new i.ARRAY_TYPE(3);return t[0]=0,t[1]=0,t[2]=0,t},o.clone=function(t){var e=new i.ARRAY_TYPE(3);return e[0]=t[0],e[1]=t[1],e[2]=t[2],e},o.fromValues=function(t,e,n){var r=new i.ARRAY_TYPE(3);return r[0]=t,r[1]=e,r[2]=n,r},o.copy=function(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t},o.set=function(t,e,n,r){return t[0]=e,t[1]=n,t[2]=r,t},o.add=function(t,e,n){return t[0]=e[0]+n[0],t[1]=e[1]+n[1],t[2]=e[2]+n[2],t},o.subtract=function(t,e,n){return t[0]=e[0]-n[0],t[1]=e[1]-n[1],t[2]=e[2]-n[2],t},o.sub=o.subtract,o.multiply=function(t,e,n){return t[0]=e[0]*n[0],t[1]=e[1]*n[1],t[2]=e[2]*n[2],t},o.mul=o.multiply,o.divide=function(t,e,n){return t[0]=e[0]/n[0],t[1]=e[1]/n[1],t[2]=e[2]/n[2],t},o.div=o.divide,o.ceil=function(t,e){return t[0]=Math.ceil(e[0]),t[1]=Math.ceil(e[1]),t[2]=Math.ceil(e[2]),t},o.floor=function(t,e){return t[0]=Math.floor(e[0]),t[1]=Math.floor(e[1]),t[2]=Math.floor(e[2]),t},o.min=function(t,e,n){return t[0]=Math.min(e[0],n[0]),t[1]=Math.min(e[1],n[1]),t[2]=Math.min(e[2],n[2]),t},o.max=function(t,e,n){return t[0]=Math.max(e[0],n[0]),t[1]=Math.max(e[1],n[1]),t[2]=Math.max(e[2],n[2]),t},o.round=function(t,e){return t[0]=Math.round(e[0]),t[1]=Math.round(e[1]),t[2]=Math.round(e[2]),t},o.scale=function(t,e,n){return t[0]=e[0]*n,t[1]=e[1]*n,t[2]=e[2]*n,t},o.scaleAndAdd=function(t,e,n,r){return t[0]=e[0]+n[0]*r,t[1]=e[1]+n[1]*r,t[2]=e[2]+n[2]*r,t},o.distance=function(t,e){var n=e[0]-t[0],r=e[1]-t[1],i=e[2]-t[2];return Math.sqrt(n*n+r*r+i*i)},o.dist=o.distance,o.squaredDistance=function(t,e){var n=e[0]-t[0],r=e[1]-t[1],i=e[2]-t[2];return n*n+r*r+i*i},o.sqrDist=o.squaredDistance,o.length=function(t){var e=t[0],n=t[1],r=t[2];return Math.sqrt(e*e+n*n+r*r)},o.len=o.length,o.squaredLength=function(t){var e=t[0],n=t[1],r=t[2];return e*e+n*n+r*r},o.sqrLen=o.squaredLength,o.negate=function(t,e){return t[0]=-e[0],t[1]=-e[1],t[2]=-e[2],t},o.inverse=function(t,e){return t[0]=1/e[0],t[1]=1/e[1],t[2]=1/e[2],t},o.normalize=function(t,e){var n=e[0],r=e[1],i=e[2],o=n*n+r*r+i*i;return o>0&&(o=1/Math.sqrt(o),t[0]=e[0]*o,t[1]=e[1]*o,t[2]=e[2]*o),t},o.dot=function(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]},o.cross=function(t,e,n){var r=e[0],i=e[1],o=e[2],a=n[0],s=n[1],u=n[2];return t[0]=i*u-o*s,t[1]=o*a-r*u,t[2]=r*s-i*a,t},o.lerp=function(t,e,n,r){var i=e[0],o=e[1],a=e[2];return t[0]=i+r*(n[0]-i),t[1]=o+r*(n[1]-o),t[2]=a+r*(n[2]-a),t},o.hermite=function(t,e,n,r,i,o){var a=o*o,s=a*(2*o-3)+1,u=a*(o-2)+o,l=a*(o-1),c=a*(3-2*o);return t[0]=e[0]*s+n[0]*u+r[0]*l+i[0]*c,t[1]=e[1]*s+n[1]*u+r[1]*l+i[1]*c,t[2]=e[2]*s+n[2]*u+r[2]*l+i[2]*c,t},o.bezier=function(t,e,n,r,i,o){var a=1-o,s=a*a,u=o*o,l=s*a,c=3*o*s,h=3*u*a,f=u*o;return t[0]=e[0]*l+n[0]*c+r[0]*h+i[0]*f,t[1]=e[1]*l+n[1]*c+r[1]*h+i[1]*f,t[2]=e[2]*l+n[2]*c+r[2]*h+i[2]*f,t},o.random=function(t,e){e=e||1;var n=2*i.RANDOM()*Math.PI,r=2*i.RANDOM()-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},o.transformMat4=function(t,e,n){var r=e[0],i=e[1],o=e[2],a=n[3]*r+n[7]*i+n[11]*o+n[15];return a=a||1,t[0]=(n[0]*r+n[4]*i+n[8]*o+n[12])/a,t[1]=(n[1]*r+n[5]*i+n[9]*o+n[13])/a,t[2]=(n[2]*r+n[6]*i+n[10]*o+n[14])/a,t},o.transformMat3=function(t,e,n){var r=e[0],i=e[1],o=e[2];return t[0]=r*n[0]+i*n[3]+o*n[6],t[1]=r*n[1]+i*n[4]+o*n[7],t[2]=r*n[2]+i*n[5]+o*n[8],t},o.transformQuat=function(t,e,n){var r=e[0],i=e[1],o=e[2],a=n[0],s=n[1],u=n[2],l=n[3],c=l*r+s*o-u*i,h=l*i+u*r-a*o,f=l*o+a*i-s*r,p=-a*r-s*i-u*o;return t[0]=c*l+p*-a+h*-u-f*-s,t[1]=h*l+p*-s+f*-a-c*-u,t[2]=f*l+p*-u+c*-s-h*-a,t},o.rotateX=function(t,e,n,r){var i=[],o=[];return i[0]=e[0]-n[0],i[1]=e[1]-n[1],i[2]=e[2]-n[2],o[0]=i[0],o[1]=i[1]*Math.cos(r)-i[2]*Math.sin(r),o[2]=i[1]*Math.sin(r)+i[2]*Math.cos(r),t[0]=o[0]+n[0],t[1]=o[1]+n[1],t[2]=o[2]+n[2],t},o.rotateY=function(t,e,n,r){var i=[],o=[];return i[0]=e[0]-n[0],i[1]=e[1]-n[1],i[2]=e[2]-n[2],o[0]=i[2]*Math.sin(r)+i[0]*Math.cos(r),o[1]=i[1],o[2]=i[2]*Math.cos(r)-i[0]*Math.sin(r),t[0]=o[0]+n[0],t[1]=o[1]+n[1],t[2]=o[2]+n[2],t},o.rotateZ=function(t,e,n,r){var i=[],o=[];return i[0]=e[0]-n[0],i[1]=e[1]-n[1],i[2]=e[2]-n[2],o[0]=i[0]*Math.cos(r)-i[1]*Math.sin(r),o[1]=i[0]*Math.sin(r)+i[1]*Math.cos(r),o[2]=i[2],t[0]=o[0]+n[0],t[1]=o[1]+n[1],t[2]=o[2]+n[2],t},o.forEach=(r=o.create(),function(t,e,n,i,o,a){var s,u;for(e||(e=3),n||(n=0),u=i?Math.min(i*e+n,t.length):t.length,s=n;s<u;s+=e)r[0]=t[s],r[1]=t[s+1],r[2]=t[s+2],o(r,r,a),t[s]=r[0],t[s+1]=r[1],t[s+2]=r[2];return t}),o.angle=function(t,e){var n=o.fromValues(t[0],t[1],t[2]),r=o.fromValues(e[0],e[1],e[2]);o.normalize(n,n),o.normalize(r,r);var i=o.dot(n,r);return i>1?0:Math.acos(i)},o.str=function(t){return"vec3("+t[0]+", "+t[1]+", "+t[2]+")"},o.exactEquals=function(t,e){return t[0]===e[0]&&t[1]===e[1]&&t[2]===e[2]},o.equals=function(t,e){var n=t[0],r=t[1],o=t[2],a=e[0],s=e[1],u=e[2];return Math.abs(n-a)<=i.EPSILON*Math.max(1,Math.abs(n),Math.abs(a))&&Math.abs(r-s)<=i.EPSILON*Math.max(1,Math.abs(r),Math.abs(s))&&Math.abs(o-u)<=i.EPSILON*Math.max(1,Math.abs(o),Math.abs(u))},t.exports=o},function(t,e,n){var r=n(624),i={create:function(){var t=new r.ARRAY_TYPE(9);return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=1,t[5]=0,t[6]=0,t[7]=0,t[8]=1,t},fromMat4:function(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[4],t[4]=e[5],t[5]=e[6],t[6]=e[8],t[7]=e[9],t[8]=e[10],t},clone:function(t){var e=new r.ARRAY_TYPE(9);return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e[6]=t[6],e[7]=t[7],e[8]=t[8],e},copy:function(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[4]=e[4],t[5]=e[5],t[6]=e[6],t[7]=e[7],t[8]=e[8],t},fromValues:function(t,e,n,i,o,a,s,u,l){var c=new r.ARRAY_TYPE(9);return c[0]=t,c[1]=e,c[2]=n,c[3]=i,c[4]=o,c[5]=a,c[6]=s,c[7]=u,c[8]=l,c},set:function(t,e,n,r,i,o,a,s,u,l){return t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=o,t[5]=a,t[6]=s,t[7]=u,t[8]=l,t},identity:function(t){return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=1,t[5]=0,t[6]=0,t[7]=0,t[8]=1,t},transpose:function(t,e){if(t===e){var n=e[1],r=e[2],i=e[5];t[1]=e[3],t[2]=e[6],t[3]=n,t[5]=e[7],t[6]=r,t[7]=i}else t[0]=e[0],t[1]=e[3],t[2]=e[6],t[3]=e[1],t[4]=e[4],t[5]=e[7],t[6]=e[2],t[7]=e[5],t[8]=e[8];return t},invert:function(t,e){var n=e[0],r=e[1],i=e[2],o=e[3],a=e[4],s=e[5],u=e[6],l=e[7],c=e[8],h=c*a-s*l,f=-c*o+s*u,p=l*o-a*u,d=n*h+r*f+i*p;return d?(d=1/d,t[0]=h*d,t[1]=(-c*r+i*l)*d,t[2]=(s*r-i*a)*d,t[3]=f*d,t[4]=(c*n-i*u)*d,t[5]=(-s*n+i*o)*d,t[6]=p*d,t[7]=(-l*n+r*u)*d,t[8]=(a*n-r*o)*d,t):null},adjoint:function(t,e){var n=e[0],r=e[1],i=e[2],o=e[3],a=e[4],s=e[5],u=e[6],l=e[7],c=e[8];return t[0]=a*c-s*l,t[1]=i*l-r*c,t[2]=r*s-i*a,t[3]=s*u-o*c,t[4]=n*c-i*u,t[5]=i*o-n*s,t[6]=o*l-a*u,t[7]=r*u-n*l,t[8]=n*a-r*o,t},determinant:function(t){var e=t[0],n=t[1],r=t[2],i=t[3],o=t[4],a=t[5],s=t[6],u=t[7],l=t[8];return e*(l*o-a*u)+n*(-l*i+a*s)+r*(u*i-o*s)},multiply:function(t,e,n){var r=e[0],i=e[1],o=e[2],a=e[3],s=e[4],u=e[5],l=e[6],c=e[7],h=e[8],f=n[0],p=n[1],d=n[2],g=n[3],v=n[4],y=n[5],m=n[6],x=n[7],b=n[8];return t[0]=f*r+p*a+d*l,t[1]=f*i+p*s+d*c,t[2]=f*o+p*u+d*h,t[3]=g*r+v*a+y*l,t[4]=g*i+v*s+y*c,t[5]=g*o+v*u+y*h,t[6]=m*r+x*a+b*l,t[7]=m*i+x*s+b*c,t[8]=m*o+x*u+b*h,t}};i.mul=i.multiply,i.translate=function(t,e,n){var r=e[0],i=e[1],o=e[2],a=e[3],s=e[4],u=e[5],l=e[6],c=e[7],h=e[8],f=n[0],p=n[1];return t[0]=r,t[1]=i,t[2]=o,t[3]=a,t[4]=s,t[5]=u,t[6]=f*r+p*a+l,t[7]=f*i+p*s+c,t[8]=f*o+p*u+h,t},i.rotate=function(t,e,n){var r=e[0],i=e[1],o=e[2],a=e[3],s=e[4],u=e[5],l=e[6],c=e[7],h=e[8],f=Math.sin(n),p=Math.cos(n);return t[0]=p*r+f*a,t[1]=p*i+f*s,t[2]=p*o+f*u,t[3]=p*a-f*r,t[4]=p*s-f*i,t[5]=p*u-f*o,t[6]=l,t[7]=c,t[8]=h,t},i.scale=function(t,e,n){var r=n[0],i=n[1];return t[0]=r*e[0],t[1]=r*e[1],t[2]=r*e[2],t[3]=i*e[3],t[4]=i*e[4],t[5]=i*e[5],t[6]=e[6],t[7]=e[7],t[8]=e[8],t},i.fromTranslation=function(t,e){return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=1,t[5]=0,t[6]=e[0],t[7]=e[1],t[8]=1,t},i.fromRotation=function(t,e){var n=Math.sin(e),r=Math.cos(e);return t[0]=r,t[1]=n,t[2]=0,t[3]=-n,t[4]=r,t[5]=0,t[6]=0,t[7]=0,t[8]=1,t},i.fromScaling=function(t,e){return t[0]=e[0],t[1]=0,t[2]=0,t[3]=0,t[4]=e[1],t[5]=0,t[6]=0,t[7]=0,t[8]=1,t},i.fromMat2d=function(t,e){return t[0]=e[0],t[1]=e[1],t[2]=0,t[3]=e[2],t[4]=e[3],t[5]=0,t[6]=e[4],t[7]=e[5],t[8]=1,t},i.fromQuat=function(t,e){var n=e[0],r=e[1],i=e[2],o=e[3],a=n+n,s=r+r,u=i+i,l=n*a,c=r*a,h=r*s,f=i*a,p=i*s,d=i*u,g=o*a,v=o*s,y=o*u;return t[0]=1-h-d,t[3]=c-y,t[6]=f+v,t[1]=c+y,t[4]=1-l-d,t[7]=p-g,t[2]=f-v,t[5]=p+g,t[8]=1-l-h,t},i.normalFromMat4=function(t,e){var n=e[0],r=e[1],i=e[2],o=e[3],a=e[4],s=e[5],u=e[6],l=e[7],c=e[8],h=e[9],f=e[10],p=e[11],d=e[12],g=e[13],v=e[14],y=e[15],m=n*s-r*a,x=n*u-i*a,b=n*l-o*a,_=r*u-i*s,w=r*l-o*s,S=i*l-o*u,M=c*g-h*d,C=c*v-f*d,P=c*y-p*d,A=h*v-f*g,I=h*y-p*g,O=f*y-p*v,E=m*O-x*I+b*A+_*P-w*C+S*M;return E?(E=1/E,t[0]=(s*O-u*I+l*A)*E,t[1]=(u*P-a*O-l*C)*E,t[2]=(a*I-s*P+l*M)*E,t[3]=(i*I-r*O-o*A)*E,t[4]=(n*O-i*P+o*C)*E,t[5]=(r*P-n*I-o*M)*E,t[6]=(g*S-v*w+y*_)*E,t[7]=(v*b-d*S-y*x)*E,t[8]=(d*w-g*b+y*m)*E,t):null},i.str=function(t){return"mat3("+t[0]+", "+t[1]+", "+t[2]+", "+t[3]+", "+t[4]+", "+t[5]+", "+t[6]+", "+t[7]+", "+t[8]+")"},i.frob=function(t){return Math.sqrt(Math.pow(t[0],2)+Math.pow(t[1],2)+Math.pow(t[2],2)+Math.pow(t[3],2)+Math.pow(t[4],2)+Math.pow(t[5],2)+Math.pow(t[6],2)+Math.pow(t[7],2)+Math.pow(t[8],2))},i.add=function(t,e,n){return t[0]=e[0]+n[0],t[1]=e[1]+n[1],t[2]=e[2]+n[2],t[3]=e[3]+n[3],t[4]=e[4]+n[4],t[5]=e[5]+n[5],t[6]=e[6]+n[6],t[7]=e[7]+n[7],t[8]=e[8]+n[8],t},i.subtract=function(t,e,n){return t[0]=e[0]-n[0],t[1]=e[1]-n[1],t[2]=e[2]-n[2],t[3]=e[3]-n[3],t[4]=e[4]-n[4],t[5]=e[5]-n[5],t[6]=e[6]-n[6],t[7]=e[7]-n[7],t[8]=e[8]-n[8],t},i.sub=i.subtract,i.multiplyScalar=function(t,e,n){return t[0]=e[0]*n,t[1]=e[1]*n,t[2]=e[2]*n,t[3]=e[3]*n,t[4]=e[4]*n,t[5]=e[5]*n,t[6]=e[6]*n,t[7]=e[7]*n,t[8]=e[8]*n,t},i.multiplyScalarAndAdd=function(t,e,n,r){return t[0]=e[0]+n[0]*r,t[1]=e[1]+n[1]*r,t[2]=e[2]+n[2]*r,t[3]=e[3]+n[3]*r,t[4]=e[4]+n[4]*r,t[5]=e[5]+n[5]*r,t[6]=e[6]+n[6]*r,t[7]=e[7]+n[7]*r,t[8]=e[8]+n[8]*r,t},i.exactEquals=function(t,e){return t[0]===e[0]&&t[1]===e[1]&&t[2]===e[2]&&t[3]===e[3]&&t[4]===e[4]&&t[5]===e[5]&&t[6]===e[6]&&t[7]===e[7]&&t[8]===e[8]},i.equals=function(t,e){var n=t[0],i=t[1],o=t[2],a=t[3],s=t[4],u=t[5],l=t[6],c=t[7],h=t[8],f=e[0],p=e[1],d=e[2],g=e[3],v=e[4],y=e[5],m=t[6],x=e[7],b=e[8];return Math.abs(n-f)<=r.EPSILON*Math.max(1,Math.abs(n),Math.abs(f))&&Math.abs(i-p)<=r.EPSILON*Math.max(1,Math.abs(i),Math.abs(p))&&Math.abs(o-d)<=r.EPSILON*Math.max(1,Math.abs(o),Math.abs(d))&&Math.abs(a-g)<=r.EPSILON*Math.max(1,Math.abs(a),Math.abs(g))&&Math.abs(s-v)<=r.EPSILON*Math.max(1,Math.abs(s),Math.abs(v))&&Math.abs(u-y)<=r.EPSILON*Math.max(1,Math.abs(u),Math.abs(y))&&Math.abs(l-m)<=r.EPSILON*Math.max(1,Math.abs(l),Math.abs(m))&&Math.abs(c-x)<=r.EPSILON*Math.max(1,Math.abs(c),Math.abs(x))&&Math.abs(h-b)<=r.EPSILON*Math.max(1,Math.abs(h),Math.abs(b))},t.exports=i},function(t,e,n){var r=n(553),i=n(558).mat3,o=n(558).vec3;function a(t){return 1===t[0]&&0===t[1]&&0===t[3]&&1===t[4]&&0===t[6]&&0===t[7]}function s(t){return 0===t[1]&&0===t[3]&&0===t[6]&&0===t[7]}function u(t,e){a(e)||(s(e)?(t[0]*=e[0],t[4]*=e[4]):i.multiply(t,t,e))}t.exports={initTransform:function(){this.attr("matrix",[1,0,0,0,1,0,0,0,1])},translate:function(t,e){var n=this.attr("matrix");return i.translate(n,n,[t,e]),this.clearTotalMatrix(),this.attr("matrix",n),this},rotate:function(t){var e=this.attr("matrix");return i.rotate(e,e,t),this.clearTotalMatrix(),this.attr("matrix",e),this},scale:function(t,e){var n=this.attr("matrix");return i.scale(n,n,[t,e]),this.clearTotalMatrix(),this.attr("matrix",n),this},rotateAtStart:function(t){var e=this.attr("x"),n=this.attr("y");Math.abs(t)>2*Math.PI&&(t=t/180*Math.PI),this.transform([["t",-e,-n],["r",t],["t",e,n]])},move:function(t,e){var n=this.get("x")||0,r=this.get("y")||0;this.translate(t-n,e-r),this.set("x",t),this.set("y",e)},transform:function(t){var e=this,n=e.attr("matrix");return r.each(t,function(t){switch(t[0]){case"t":e.translate(t[1],t[2]);break;case"s":e.scale(t[1],t[2]);break;case"r":e.rotate(t[1]);break;case"m":e.attr("matrix",i.multiply([],n,t[1])),e.clearTotalMatrix()}}),e},setTransform:function(t){return this.attr("matrix",[1,0,0,0,1,0,0,0,1]),this.transform(t)},getMatrix:function(){return this.attr("matrix")},setMatrix:function(t){return this.attr("matrix",t),this.clearTotalMatrix(),this},apply:function(t,e){var n=void 0;return n=e?this._getMatrixByRoot(e):this.attr("matrix"),o.transformMat3(t,t,n),this},_getMatrixByRoot:function(t){t=t||this;for(var e=this,n=[];e!==t;)n.unshift(e),e=e.get("parent");n.unshift(e);var o=[1,0,0,0,1,0,0,0,1];return r.each(n,function(t){i.multiply(o,t.attr("matrix"),o)}),o},getTotalMatrix:function(){var t=this.__cfg.totalMatrix;if(!t){t=[1,0,0,0,1,0,0,0,1];var e=this.__cfg.parent;if(e)u(t,e.getTotalMatrix());u(t,this.attr("matrix")),this.__cfg.totalMatrix=t}return t},clearTotalMatrix:function(){},invert:function(t){var e=this.getTotalMatrix();if(s(e))t[0]/=e[0],t[1]/=e[4];else{var n=i.invert([],e);n&&o.transformMat3(t,t,n)}return this},resetTransform:function(t){var e=this.attr("matrix");a(e)||t.transform(e[0],e[1],e[3],e[4],e[6],e[7])}}},function(t,e,n){var r=n(553),i=["strokeStyle","fillStyle","globalAlpha"],o=["circle","ellipse","fan","polygon","rect","path"],a={r:"R",opacity:"Opacity",lineWidth:"LineWidth",clip:"Clip",stroke:"Stroke",fill:"Fill",strokeOpacity:"Stroke",fillOpacity:"Fill",x:"X",y:"Y",rx:"Rx",ry:"Ry",re:"Re",rs:"Rs",width:"Width",height:"Height",img:"Img",x1:"X1",x2:"X2",y1:"Y1",y2:"Y2",points:"Points",p1:"P1",p2:"P2",p3:"P3",p4:"P4",text:"Text",radius:"Radius",textAlign:"TextAlign",textBaseline:"TextBaseline",font:"Font",fontSize:"FontSize",fontStyle:"FontStyle",fontVariant:"FontVariant",fontWeight:"FontWeight",fontFamily:"FontFamily",clockwise:"Clockwise",startAngle:"StartAngle",endAngle:"EndAngle",path:"Path"},s={stroke:"strokeStyle",fill:"fillStyle",opacity:"globalAlpha"};t.exports={canFill:!1,canStroke:!1,initAttrs:function(t){return this.__attrs={opacity:1,fillOpacity:1,strokeOpacity:1},this.attr(r.assign(this.getDefaultAttrs(),t)),this},getDefaultAttrs:function(){return{}},attr:function(t,e){if(0===arguments.length)return this.__attrs;if(r.isObject(t)){for(var n in t)if(-1===i.indexOf(n)){var o=t[n];this._setAttr(n,o)}return this.__afterSetAttrAll&&this.__afterSetAttrAll(t),this.clearBBox(),this}if(2===arguments.length){if(!1!==this._setAttr(t,e)){var s="__afterSetAttr"+a[t];this[s]&&this[s](e)}return this.clearBBox(),this}return this._getAttr(t)},clearBBox:function(){this.setSilent("box",null)},__afterSetAttrAll:function(){},_getAttr:function(t){return this.__attrs[t]},_setAttr:function(t,e){if("clip"===t)this.__setAttrClip(e),this.__attrs.clip=e;else if("transform"===t)this.__setAttrTrans(e);else{this.__attrs[t]=e;var n=s[t];n&&(this.__attrs[n]=e)}return this},hasFill:function(){return this.canFill&&this.__attrs.fillStyle},hasStroke:function(){return this.canStroke&&this.__attrs.strokeStyle},__setAttrOpacity:function(t){return this.__attrs.globalAlpha=t,t},__setAttrClip:function(t){var e=this;return t&&o.indexOf(t.type)>-1?(null===t.get("canvas")&&(t=r.clone(t)),t.set("parent",e.get("parent")),t.set("context",e.get("context")),t.inside=function(n,r){var i=[n,r,1];return t.invert(i,e.get("canvas")),t.__isPointInFill(i[0],i[1])},t):null},__setAttrTrans:function(t){return this.transform(t)}}},function(t,e,n){var r=n(584);t.exports=function(t,e){return r(e,function(e){return t[e]})}},function(t,e){t.exports=function(t){for(var e,n=[];!(e=t.next()).done;)n.push(e.value);return n}},function(t,e,n){var r=n(160),i=n(599),o=n(163),a=n(254),s=n(102),u=n(902),l=n(904),c=n(694),h=n(696),f=n(632),p="[object Map]",d="[object Set]",g=r?r.iterator:void 0;t.exports=function(t){if(!t)return[];if(a(t))return s(t)?h(t):i(t);if(g&&t[g])return u(t[g]());var e=o(t);return(e==p?l:e==d?c:f)(t)}},,,,function(t,e,n){var r=n(633);t.exports=function(t,e){return r(t,e)}},function(t,e,n){var r=n(254);t.exports=function(t,e){return function(n,i){if(null==n)return n;if(!r(n))return t(n,i);for(var o=n.length,a=e?o:-1,s=Object(n);(e?a--:++a<o)&&!1!==i(s[a],a,s););return n}}},function(t,e,n){var r=n(635),i=n(565);t.exports=function(t,e){return t&&r(t,e,i)}},function(t,e){t.exports=function(t,e,n,r){for(var i=n-1,o=t.length;++i<o;)if(r(t[i],e))return i;return-1}},function(t,e,n){var r=n(584),i=n(695),o=n(910),a=n(162),s=n(599),u=Array.prototype.splice;t.exports=function(t,e,n,l){var c=l?o:i,h=-1,f=e.length,p=t;for(t===e&&(e=s(e)),n&&(p=r(t,a(n)));++h<f;)for(var d=0,g=e[h],v=n?n(g):g;(d=c(p,v,d,l))>-1;)p!==t&&u.call(p,d,1),u.call(t,d,1);return t}},function(t,e,n){var r=n(911);t.exports=function(t,e){return t&&t.length&&e&&e.length?r(t,e):t}},function(t,e,n){var r=n(598)(n(912));t.exports=r},function(t,e){var n="[\\ud800-\\udfff]",r="[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]",i="\\ud83c[\\udffb-\\udfff]",o="[^\\ud800-\\udfff]",a="(?:\\ud83c[\\udde6-\\uddff]){2}",s="[\\ud800-\\udbff][\\udc00-\\udfff]",u="(?:"+r+"|"+i+")"+"?",l="[\\ufe0e\\ufe0f]?"+u+("(?:\\u200d(?:"+[o,a,s].join("|")+")[\\ufe0e\\ufe0f]?"+u+")*"),c="(?:"+[o+r+"?",r,a,s,n].join("|")+")",h=RegExp(i+"(?="+i+")|"+c+l,"g");t.exports=function(t){return t.match(h)||[]}},function(t,e){t.exports=function(t){return t.split("")}},function(t,e){t.exports=function(t,e,n){var r=-1,i=t.length;e<0&&(e=-e>i?0:i+e),(n=n>i?i:n)<0&&(n+=i),i=e>n?0:n-e>>>0,e>>>=0;for(var o=Array(i);++r<i;)o[r]=t[r+e];return o}},function(t,e,n){var r=n(916);t.exports=function(t,e,n){var i=t.length;return n=void 0===n?i:n,!e&&n>=i?t:r(t,e,n)}},function(t,e,n){var r=n(698)("toUpperCase");t.exports=r},function(t,e,n){var r=n(575),i=n(587);t.exports=function(t){return r(t,i(t))}},function(t,e,n){var r=n(700),i=n(709),o=n(705),a=n(599),s=n(704),u=n(256),l=n(80),c=n(634),h=n(258),f=n(157),p=n(156),d=n(70),g=n(261),v=n(699),y=n(919);t.exports=function(t,e,n,m,x,b,_){var w=v(t,n),S=v(e,n),M=_.get(S);if(M)r(t,n,M);else{var C=b?b(w,S,n+"",t,e,_):void 0,P=void 0===C;if(P){var A=l(S),I=!A&&h(S),O=!A&&!I&&g(S);C=S,A||I||O?l(w)?C=w:c(w)?C=a(w):I?(P=!1,C=i(S,!0)):O?(P=!1,C=o(S,!0)):C=[]:d(S)||u(S)?(C=w,u(w)?C=y(w):(!p(w)||m&&f(w))&&(C=s(S))):P=!1}P&&(_.set(S,C),x(C,S,m,b,_),_.delete(S)),r(t,n,C)}}},function(t,e){t.exports=function(t){return function(e,n,r){for(var i=-1,o=Object(e),a=r(e),s=a.length;s--;){var u=a[t?s:++i];if(!1===n(o[u],u,o))break}return e}}},function(t,e,n){var r=n(637),i=n(700),o=n(635),a=n(920),s=n(156),u=n(587),l=n(699);t.exports=function t(e,n,c,h,f){e!==n&&o(n,function(o,u){if(s(o))f||(f=new r),a(e,n,u,c,t,h,f);else{var p=h?h(l(e,u),o,u+"",e,n,f):void 0;void 0===p&&(p=o),i(e,u,p)}},u)}},function(t,e){var n=800,r=16,i=Date.now;t.exports=function(t){var e=0,o=0;return function(){var a=i(),s=r-(a-o);if(o=a,s>0){if(++e>=n)return arguments[0]}else e=0;return t.apply(void 0,arguments)}}},function(t,e){t.exports=function(t){return function(){return t}}},function(t,e,n){var r=n(924),i=n(710),o=n(609),a=i?function(t,e){return i(t,"toString",{configurable:!0,enumerable:!1,value:r(e),writable:!0})}:o;t.exports=a},function(t,e){t.exports=function(t,e,n){switch(n.length){case 0:return t.call(e);case 1:return t.call(e,n[0]);case 2:return t.call(e,n[0],n[1]);case 3:return t.call(e,n[0],n[1],n[2])}return t.apply(e,n)}},function(t,e,n){var r=n(163),i=n(49),o="[object Set]";t.exports=function(t){return i(t)&&r(t)==o}},function(t,e,n){var r=n(927),i=n(162),o=n(166),a=o&&o.isSet,s=a?i(a):r;t.exports=s},function(t,e,n){var r=n(156),i=Object.create,o=function(){function t(){}return function(e){if(!r(e))return{};if(i)return i(e);t.prototype=e;var n=new t;return t.prototype=void 0,n}}();t.exports=o},function(t,e,n){var r=n(160),i=r?r.prototype:void 0,o=i?i.valueOf:void 0;t.exports=function(t){return o?Object(o.call(t)):{}}},function(t,e){var n=/\w*$/;t.exports=function(t){var e=new t.constructor(t.source,n.exec(t));return e.lastIndex=t.lastIndex,e}},function(t,e,n){var r=n(625);t.exports=function(t,e){var n=e?r(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.byteLength)}},,function(t,e,n){var r=n(625),i=n(932),o=n(931),a=n(930),s=n(705),u="[object Boolean]",l="[object Date]",c="[object Map]",h="[object Number]",f="[object RegExp]",p="[object Set]",d="[object String]",g="[object Symbol]",v="[object ArrayBuffer]",y="[object DataView]",m="[object Float32Array]",x="[object Float64Array]",b="[object Int8Array]",_="[object Int16Array]",w="[object Int32Array]",S="[object Uint8Array]",M="[object Uint8ClampedArray]",C="[object Uint16Array]",P="[object Uint32Array]";t.exports=function(t,e,n){var A=t.constructor;switch(e){case v:return r(t);case u:case l:return new A(+t);case y:return i(t,n);case m:case x:case b:case _:case w:case S:case M:case C:case P:return s(t,n);case c:return new A;case h:case d:return new A(t);case f:return o(t);case p:return new A;case g:return a(t)}}},function(t,e){var n=Object.prototype.hasOwnProperty;t.exports=function(t){var e=t.length,r=new t.constructor(e);return e&&"string"==typeof t[0]&&n.call(t,"index")&&(r.index=t.index,r.input=t.input),r}},function(t,e,n){var r=n(937),i=n(707),o=n(587);t.exports=function(t){return r(t,o,i)}},,,function(t,e,n){var r=n(575),i=n(707);t.exports=function(t,e){return r(t,i(t),e)}},,,function(t,e,n){var r=n(575),i=n(708);t.exports=function(t,e){return r(t,i(t),e)}},function(t,e){t.exports=function(t){var e=[];if(null!=t)for(var n in Object(t))e.push(n);return e}},function(t,e,n){var r=n(156),i=n(164),o=n(943),a=Object.prototype.hasOwnProperty;t.exports=function(t){if(!r(t))return o(t);var e=i(t),n=[];for(var s in t)("constructor"!=s||!e&&a.call(t,s))&&n.push(s);return n}},function(t,e,n){var r=n(575),i=n(587);t.exports=function(t,e){return t&&r(e,i(e),t)}},,function(t,e,n){var r=n(575),i=n(565);t.exports=function(t,e){return t&&r(e,i(e),t)}},,,,,,,,,,,,,,,,,,,function(t,e,n){var r=n(50),i=n(49),o="[object Boolean]";t.exports=function(t){return!0===t||!1===t||i(t)&&r(t)==o}},function(t,e,n){var r=n(553),i=n(692),o=n(691),a=function t(e){t.superclass.constructor.call(this,e)};a.CFG={eventEnable:!0,width:null,height:null,widthCanvas:null,heightCanvas:null,widthStyle:null,heightStyle:null,containerDOM:null,canvasDOM:null,pixelRatio:null},r.extend(a,o),r.augment(a,{init:function(){a.superclass.init.call(this),this._setGlobalParam(),this._setDOM(),this._setInitSize(),this._setCanvas(),this._scale(),this.get("eventEnable")&&this._registEvents()},getEmitter:function(t,e){if(t){if(!r.isEmpty(t._getEvents()))return t;var n=t.get("parent");if(n&&!e.propagationStopped)return this.getEmitter(n,e)}},_getEventObj:function(t,e,n,r){var o=new i(t,e,!0,!0);return o.x=n.x,o.y=n.y,o.clientX=e.clientX,o.clientY=e.clientY,o.currentTarget=r,o.target=r,o},_triggerEvent:function(t,e){var n=this.getPointByClient(e.clientX,e.clientY),r=this.getShape(n.x,n.y),i=void 0;if("mousemove"===t){var o=this._getEventObj("mousemove",e,n,this);this.emit("mousemove",o);var a=this.get("preShape");if(a&&a!==r){var s=this._getEventObj("mouseleave",e,n,a);(i=this.getEmitter(a,e))&&i.emit("mouseleave",s)}if(r){var u=this._getEventObj("mousemove",e,n,r);if((i=this.getEmitter(r,e))&&i.emit("mousemove",u),a!==r){var l=this._getEventObj("mouseenter",e,n,r);i&&i.emit("mouseenter",l,e)}}this.set("preShape",r)}else{var c=this._getEventObj(t,e,n,r||this);(i=this.getEmitter(r,e))&&i!==this&&i.emit(t,c),this.emit(t,c)}var h=this.get("el");r&&!r.get("destroyed")&&(h.style.cursor=r.attr("cursor")||"default")},_registEvents:function(){var t=this,e=t.get("el");e.addEventListener("mouseout",function(e){t._triggerEvent("mouseleave",e)},!1),e.addEventListener("mouseover",function(e){t._triggerEvent("mouseenter",e)},!1),e.addEventListener("mousemove",function(e){t._triggerEvent("mousemove",e)},!1),e.addEventListener("mousedown",function(e){t._triggerEvent("mousedown",e)},!1),e.addEventListener("mouseup",function(e){t._triggerEvent("mouseup",e)},!1),e.addEventListener("click",function(e){t._triggerEvent("click",e)},!1),e.addEventListener("dblclick",function(e){t._triggerEvent("dblclick",e)},!1),e.addEventListener("touchstart",function(e){r.isEmpty(e.touches)||t._triggerEvent("touchstart",e.touches[0])},!1),e.addEventListener("touchmove",function(e){r.isEmpty(e.touches)||t._triggerEvent("touchmove",e.touches[0])},!1),e.addEventListener("touchend",function(e){r.isEmpty(e.changedTouches)||t._triggerEvent("touchend",e.changedTouches[0])},!1)},_scale:function(){var t=this.get("pixelRatio");this.scale(t,t)},_setCanvas:function(){var t=this.get("canvasDOM");this.set("el",t),this.set("context",t.getContext("2d")),this.set("canvas",this)},_setGlobalParam:function(){this.get("pixelRatio")||this.set("pixelRatio",r.getRatio())},_setDOM:function(){this._setContainer(),this._setLayer()},_setContainer:function(){var t=this.get("containerId"),e=this.get("containerDOM");e||(e=document.getElementById(t),this.set("containerDOM",e)),r.modifyCSS(e,{position:"relative"})},_setLayer:function(){var t=this.get("containerDOM"),e=r.uniqueId("canvas_");if(t){var n=r.createDom('<canvas id="'+e+'"></canvas>');t.appendChild(n),this.set("canvasDOM",n)}},_setInitSize:function(){this.changeSize(this.get("width"),this.get("height"))},_reSize:function(){var t=this.get("canvasDOM"),e=this.get("widthCanvas"),n=this.get("heightCanvas"),r=this.get("widthStyle"),i=this.get("heightStyle");t.style.width=r,t.style.height=i,t.setAttribute("width",e),t.setAttribute("height",n)},getWidth:function(){var t=this.get("pixelRatio");return this.get("width")*t},getHeight:function(){var t=this.get("pixelRatio");return this.get("height")*t},changeSize:function(t,e){var n=this.get("pixelRatio"),r=t*n,i=e*n;this.set("widthCanvas",r),this.set("heightCanvas",i),this.set("widthStyle",t+"px"),this.set("heightStyle",e+"px"),this.set("width",t),this.set("height",e),this._reSize()},getPointByClient:function(t,e){var n=this.get("el"),r=n.getBoundingClientRect(),i=r.right-r.left,o=r.bottom-r.top;return{x:(t-r.left)*(n.width/i),y:(e-r.top)*(n.height/o)}},getClientByPoint:function(t,e){var n=this.get("el"),r=n.getBoundingClientRect(),i=r.right-r.left,o=r.bottom-r.top;return{clientX:t/(n.width/i)+r.left,clientY:e/(n.height/o)+r.top}},beforeDraw:function(){var t=this.get("context"),e=this.get("el");t&&t.clearRect(0,0,e.width,e.height)},_beginDraw:function(){this.setSilent("toDraw",!0)},_endDraw:function(){this.setSilent("toDraw",!1)},draw:function(){var t=this;t.get("destroyed")||(t.get("animateHandler")?this._beginDraw():function e(){t.setSilent("animateHandler",r.requestAnimationFrame(function(){t.setSilent("animateHandler",void 0),t.get("toDraw")&&e()})),t.beforeDraw();try{var n=t.get("context");a.superclass.draw.call(t,n)}catch(e){console.warn("error in draw canvas, detail as:"),console.warn(e),t._endDraw()}t._endDraw()}())},destroy:function(){var t=this.get("containerDOM"),e=this.get("canvasDOM");e&&t&&t.removeChild(e),a.superclass.destroy.call(this)}}),t.exports=a},function(t,e,n){var r=n(552),i=n(674),o=n(667),a=n(551),s=n(659),u=n(561),l=n(549),c={version:a.version,Animate:i,Chart:o,Global:a,Scale:s,Shape:u,Util:l,G:r,DomUtil:r.DomUtil,MatrixUtil:r.MatrixUtil,PathUtil:r.PathUtil,track:function(t){a.trackable=t}};n(788),"undefined"!=typeof window&&(window.G2?console.warn("There are multiple versions of G2. Version "+c.version+"'s reference is 'window.G2_3'"):window.G2=c),t.exports=c}])]);
//# sourceMappingURL=5.e2fb06a758ee3befa705.js.map
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment