release 4.3.0
diff --git a/public/en/404.html b/public/en/404.html
index ee0e840..b2290ab 100644
--- a/public/en/404.html
+++ b/public/en/404.html
@@ -1,4 +1,4 @@
-<!DOCTYPE html><html lang="zh-CN"><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width, initial-scale=1" user-scalable="no"><meta name="description" content="ECharts, a powerful, interactive charting and visualization library for browser"><link rel="shortcut icon" href="images/favicon.png"><link rel="stylesheet" type="text/css" href="https://cdn.jsdelivr.net/npm/bootstrap@3.3.7/dist/css/bootstrap.min.css"><!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries--><!--[if lt IE 9]><script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script><script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script><![endif]--><link rel="stylesheet" type="text/css" href="./css/main.css?_v_=1567711848565"><script>window.EC_WWW_LANG = 'zh';
+<!DOCTYPE html><html lang="zh-CN"><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width, initial-scale=1" user-scalable="no"><meta name="description" content="ECharts, a powerful, interactive charting and visualization library for browser"><link rel="shortcut icon" href="images/favicon.png"><link rel="stylesheet" type="text/css" href="https://cdn.jsdelivr.net/npm/bootstrap@3.3.7/dist/css/bootstrap.min.css"><!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries--><!--[if lt IE 9]><script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script><script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script><![endif]--><link rel="stylesheet" type="text/css" href="./css/main.css?_v_=1568642955357"><script>window.EC_WWW_LANG = 'zh';
 </script><script type="text/javascript" src="./vendors/pace/pace.min.js"></script><script id="font-hack" type="text/javascript">if (/windows/i.test(navigator.userAgent)) {
     var el = document.createElement('style');
     el.innerHTML = ''
diff --git a/public/en/api.html b/public/en/api.html
index e338296..e091843 100644
--- a/public/en/api.html
+++ b/public/en/api.html
@@ -1,4 +1,4 @@
-<!DOCTYPE html><html lang="en-US"><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width, initial-scale=1" user-scalable="no"><meta name="description" content="ECharts, a powerful, interactive charting and visualization library for browser"><link rel="shortcut icon" href="images/favicon.png"><link rel="stylesheet" type="text/css" href="https://cdn.jsdelivr.net/npm/bootstrap@3.3.7/dist/css/bootstrap.min.css"><!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries--><!--[if lt IE 9]><script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script><script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script><![endif]--><link rel="stylesheet" type="text/css" href="./css/main.css?_v_=1567711848565"><script>window.EC_WWW_LANG = 'en';
+<!DOCTYPE html><html lang="en-US"><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width, initial-scale=1" user-scalable="no"><meta name="description" content="ECharts, a powerful, interactive charting and visualization library for browser"><link rel="shortcut icon" href="images/favicon.png"><link rel="stylesheet" type="text/css" href="https://cdn.jsdelivr.net/npm/bootstrap@3.3.7/dist/css/bootstrap.min.css"><!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries--><!--[if lt IE 9]><script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script><script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script><![endif]--><link rel="stylesheet" type="text/css" href="./css/main.css?_v_=1568642955357"><script>window.EC_WWW_LANG = 'en';
 </script><script type="text/javascript" src="./vendors/pace/pace.min.js"></script><script id="font-hack" type="text/javascript">if (/windows/i.test(navigator.userAgent)) {
     var el = document.createElement('style');
     el.innerHTML = ''
@@ -6,7 +6,7 @@
         + '@font-face {font-family:"noto-light";src:local("Microsoft Yahei");}';
     document.head.insertBefore(el, document.getElementById('font-hack'));
 }
-</script><title>ECharts Documentation</title><link rel="stylesheet" type="text/css" href="css/ecOption.css?_v_=1567711848565"><link rel="stylesheet" type="text/css" href="vendors/prettify/prettify.css"><link rel="stylesheet" type="text/css" href="vendors/perfect-scrollbar/0.6.8/css/perfect-scrollbar.min.css"><link rel="stylesheet" type="text/css" href="vendors/jquery-autocomplete/jquery.auto-complete.css"><link rel="stylesheet" type="text/css" href="vendors/twentytwenty/twentytwenty.css"><script src="js/log.js"></script><script src="vendors/prettify/prettify.js"></script><script src="vendors/prettify/lang-css.js"></script><script src="vendors/esl.js"></script><script type="text/javascript" src="https://cdn.jsdelivr.net/npm/jquery@2.2.4/dist/jquery.min.js"></script></head><!--[if lte IE 8]><body class="lower-ie"><div id="lowie-main"><img src="./images/forie.png" alt="ie tip"></div></body><![endif]-->
+</script><title>ECharts Documentation</title><link rel="stylesheet" type="text/css" href="css/ecOption.css?_v_=1568642955357"><link rel="stylesheet" type="text/css" href="vendors/prettify/prettify.css"><link rel="stylesheet" type="text/css" href="vendors/perfect-scrollbar/0.6.8/css/perfect-scrollbar.min.css"><link rel="stylesheet" type="text/css" href="vendors/jquery-autocomplete/jquery.auto-complete.css"><link rel="stylesheet" type="text/css" href="vendors/twentytwenty/twentytwenty.css"><script src="js/log.js"></script><script src="vendors/prettify/prettify.js"></script><script src="vendors/prettify/lang-css.js"></script><script src="vendors/esl.js"></script><script type="text/javascript" src="https://cdn.jsdelivr.net/npm/jquery@2.2.4/dist/jquery.min.js"></script></head><!--[if lte IE 8]><body class="lower-ie"><div id="lowie-main"><img src="./images/forie.png" alt="ie tip"></div></body><![endif]-->
 <!--[if (gt IE 8)|!(IE)]><body class="undefined"></body><![endif]--><div id="apache-banner"><div class="txt"><p>Apache ECharts is an effort undergoing incubation at The Apache Software Foundation (ASF), sponsored by the Apache Incubator.</p><p>We are working on redirecting this Website to <a href="https://echarts.apache.org" target="_blank">https://echarts.apache.org</a>. You may visit our new official Website now.</p></div><a href="https://echarts.apache.org" target="_blank" onclick="logApache()" class="btn"><div>Visit Official Website</div></a><a href="javascript:;" onclick="closeApacheBanner(true)" class="close-btn">x</a></div><div id="main"><nav class="navbar navbar-default navbar-fixed-top"><div class="container-fluid"><div class="navbar-header"><button type="button" data-toggle="collapse" data-target="#navbar-collapse" aria-expanded="false" class="navbar-toggle collapsed"><span class="sr-only">Toggle navigation</span><span class="icon-bar"></span><span class="icon-bar"></span><span class="icon-bar"></span></button><a href="https://echarts.apache.org/en/index.html" class="navbar-brand"><img src="https://echarts.apache.org/en/images/logo.png" alt="echarts logo" class="navbar-logo"></a></div><div id="navbar-collapse" class="collapse navbar-collapse"><ul class="nav navbar-nav navbar-left"><li id="nav-index"><a href="https://echarts.apache.org/en/index.html">Home</a></li><li id="nav-doc" class="dropdown"><a href="#" data-toggle="dropdown" class="dropdown-toggle">Documents<b class="caret"></b></a><ul class="dropdown-menu"><li><a href="https://echarts.apache.org/en/feature.html">Features</a></li><li><a href="https://echarts.apache.org/en/tutorial.html">Tutorials</a></li><li><a href="https://echarts.apache.org/en/api.html">API</a></li><li><a href="https://echarts.apache.org/en/cheat-sheet.html">Cheat Sheet<span class="new">NEW</span></a></li><li><a href="https://echarts.apache.org/en/option.html">Chart Configuration</a></li><li><a href="https://echarts.apache.org/en/option-gl.html">GL Configuration (Chinese)</a></li><li><a href="https://echarts.apache.org/en/changelog.html">Changelog</a></li></ul></li><li id="nav-download" class="dropdown"><a href="#" data-toggle="dropdown" class="dropdown-toggle">Download<b class="caret"></b></a><ul class="dropdown-menu"><li><a href="https://echarts.apache.org/en/download.html">Download</a></li><li><a href="https://echarts.apache.org/en/download-theme.html">Download Themes</a></li><li><a href="https://echarts.apache.org/en/download-extension.html">Download Extensions</a></li></ul></li><li id="nav-examples"><a href="#" data-toggle="dropdown" class="dropdown-toggle">Examples<b class="caret"></b></a><ul class="dropdown-menu"><li><a href="https://echarts.apache.org/examples/en/">ECharts Examples</a></li><li><a href="https://echarts.apache.org/examples/en/index.html#chart-type-globe">GL Examples</a></li></ul></li><li id="nav-contribute"><a href="#" data-toggle="dropdown" class="dropdown-toggle">Contribute<b class="caret"></b></a><ul class="dropdown-menu"><li><a href="https://github.com/apache/incubator-echarts" target="_blank">Source Code (GitHub)</a></li><li><a href="https://github.com/apache/incubator-echarts/issues" target="_blank">Issue Tracking</a></li><li><a href="https://echarts.apache.org/en/coding-standard.html">Code Standard</a></li></ul></li><li id="nav-about"><a href="#" data-toggle="dropdown" class="dropdown-toggle">About<b class="caret"></b></a><ul class="dropdown-menu"><li><a href="https://echarts.apache.org/en/committers.html">Committers</a></li><li><a href="https://www.apache.org/licenses/">License</a></li><li><a href="https://echarts.apache.org/en/maillist.html">Mailing List</a></li><li><a href="https://echarts.apache.org/en/dependencies.html">Dependencies</a></li><li><a href="https://echarts.apache.org/en/faq.html">FAQ</a></li></ul></li></ul><ul class="nav navbar-nav navbar-right"><li id="nav-github"><a href="https://github.com/ecomfe/echarts" target="_blank"><img src="https://echarts.apache.org/en/images/github.png" width="18"></a></li><li id="nav-homeen"><a href="javascript:;" onclick="changeLang('zh')">中文</a></li></ul></div></div></nav><div class="ecdoc-apidoc"></div></div><script type="text/javascript" src="https://cdn.jsdelivr.net/npm/bootstrap@3.3.7/dist/js/bootstrap.min.js"></script><script type="text/javascript" src="./js/common.js"></script><script src="vendors/twentytwenty/jquery.event.move.js"></script><script src="vendors/twentytwenty/jquery.twentytwenty.js"></script><script type="text/javascript">window.globalArgsExtra = {
     pageName: 'api',
     initHash: 'echarts',
@@ -28,7 +28,7 @@
 var vendorPath = '../vendors';
 
 define('globalArgs', extend({
-    version: '1567711848565',
+    version: '1568642955357',
     basePath: './',
     // Schema url is added by each doc page
     schemaUrl: '',
@@ -55,7 +55,7 @@
         hasher: vendorPath + '/hasher/1.2.0/hasher.min',
         perfectScrollbar: vendorPath + '/perfect-scrollbar/0.6.8/js/perfect-scrollbar'
     },
-    urlArgs: '_v_=1567711848565'
+    urlArgs: '_v_=1568642955357'
 });
 
 require(['docTool/main'], function (main) {
diff --git a/public/en/builder.html b/public/en/builder.html
index 96b603b..4fe69c1 100644
--- a/public/en/builder.html
+++ b/public/en/builder.html
@@ -1,4 +1,4 @@
-<!DOCTYPE html><html lang="en-US"><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width, initial-scale=1" user-scalable="no"><meta name="description" content="ECharts, a powerful, interactive charting and visualization library for browser"><link rel="shortcut icon" href="images/favicon.png"><link rel="stylesheet" type="text/css" href="https://cdn.jsdelivr.net/npm/bootstrap@3.3.7/dist/css/bootstrap.min.css"><!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries--><!--[if lt IE 9]><script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script><script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script><![endif]--><link rel="stylesheet" type="text/css" href="./css/main.css?_v_=1567711848565"><script>window.EC_WWW_LANG = 'en';
+<!DOCTYPE html><html lang="en-US"><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width, initial-scale=1" user-scalable="no"><meta name="description" content="ECharts, a powerful, interactive charting and visualization library for browser"><link rel="shortcut icon" href="images/favicon.png"><link rel="stylesheet" type="text/css" href="https://cdn.jsdelivr.net/npm/bootstrap@3.3.7/dist/css/bootstrap.min.css"><!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries--><!--[if lt IE 9]><script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script><script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script><![endif]--><link rel="stylesheet" type="text/css" href="./css/main.css?_v_=1568642955357"><script>window.EC_WWW_LANG = 'en';
 </script><script type="text/javascript" src="./vendors/pace/pace.min.js"></script><script id="font-hack" type="text/javascript">if (/windows/i.test(navigator.userAgent)) {
     var el = document.createElement('style');
     el.innerHTML = ''
diff --git a/public/en/builder/src/echarts/chart/chord/chordCircularLayout.js b/public/en/builder/src/echarts/chart/chord/chordCircularLayout.js
index b781393..0e8b8d3 100644
--- a/public/en/builder/src/echarts/chart/chord/chordCircularLayout.js
+++ b/public/en/builder/src/echarts/chart/chord/chordCircularLayout.js
@@ -16,12 +16,6 @@
 * specific language governing permissions and limitations
 * under the License.
 */
-
-/**
- * Chord layout
- * @module echarts/chart/chord/chordCircularLayout
- * @author pissang(http://github.com/pissang)
- */
 import * as zrUtil from 'zrender/src/core/util';
 import { parsePercent } from '../../util/number';
 /**
diff --git a/public/en/builder/src/echarts/chart/heatmap/HeatmapLayer.js b/public/en/builder/src/echarts/chart/heatmap/HeatmapLayer.js
index 3fe50db..8b1bb81 100644
--- a/public/en/builder/src/echarts/chart/heatmap/HeatmapLayer.js
+++ b/public/en/builder/src/echarts/chart/heatmap/HeatmapLayer.js
@@ -18,14 +18,6 @@
 */
 
 /* global Uint8ClampedArray */
-
-/**
- * @file defines echarts Heatmap Chart
- * @author Ovilia (me@zhangwenli.com)
- * Inspired by https://github.com/mourner/simpleheat
- *
- * @module
- */
 import * as zrUtil from 'zrender/src/core/util';
 var GRADIENT_LEVELS = 256;
 /**
diff --git a/public/en/builder/src/echarts/chart/sankey/SankeySeries.js b/public/en/builder/src/echarts/chart/sankey/SankeySeries.js
index 890c80c..c85eb1a 100644
--- a/public/en/builder/src/echarts/chart/sankey/SankeySeries.js
+++ b/public/en/builder/src/echarts/chart/sankey/SankeySeries.js
@@ -16,11 +16,6 @@
 * specific language governing permissions and limitations
 * under the License.
 */
-
-/**
- * @file Get initial data and define sankey view's series model
- * @author Deqing Li(annong035@gmail.com)
- */
 import SeriesModel from '../../model/Series';
 import createGraphFromNodeEdge from '../helper/createGraphFromNodeEdge';
 import { encodeHTML } from '../../util/format';
diff --git a/public/en/builder/src/echarts/chart/sankey/SankeyView.js b/public/en/builder/src/echarts/chart/sankey/SankeyView.js
index a782499..c789196 100644
--- a/public/en/builder/src/echarts/chart/sankey/SankeyView.js
+++ b/public/en/builder/src/echarts/chart/sankey/SankeyView.js
@@ -16,11 +16,6 @@
 * specific language governing permissions and limitations
 * under the License.
 */
-
-/**
- * @file  The file used to draw sankey diagram.
- * @author  Deqing Li(annong035@gmail.com)
- */
 import * as graphic from '../../util/graphic';
 import * as echarts from '../../echarts';
 import * as zrUtil from 'zrender/src/core/util';
diff --git a/public/en/builder/src/echarts/chart/sankey/sankeyAction.js b/public/en/builder/src/echarts/chart/sankey/sankeyAction.js
index ac171cf..ae540f8 100644
--- a/public/en/builder/src/echarts/chart/sankey/sankeyAction.js
+++ b/public/en/builder/src/echarts/chart/sankey/sankeyAction.js
@@ -16,11 +16,6 @@
 * specific language governing permissions and limitations
 * under the License.
 */
-
-/**
- * @file The interactive action of sankey view
- * @author Deqing Li(annong035@gmail.com)
- */
 import * as echarts from '../../echarts';
 import '../helper/focusNodeAdjacencyAction';
 echarts.registerAction({
diff --git a/public/en/builder/src/echarts/chart/sankey/sankeyLayout.js b/public/en/builder/src/echarts/chart/sankey/sankeyLayout.js
index a8bbde9..84e7bca 100644
--- a/public/en/builder/src/echarts/chart/sankey/sankeyLayout.js
+++ b/public/en/builder/src/echarts/chart/sankey/sankeyLayout.js
@@ -16,11 +16,6 @@
 * specific language governing permissions and limitations
 * under the License.
 */
-
-/**
- * @file The layout algorithm of sankey diagram.
- * @author Deqing Li(annong035@gmail.com)
- */
 import * as layout from '../../util/layout';
 import * as zrUtil from 'zrender/src/core/util';
 import { groupData } from '../../util/model';
diff --git a/public/en/builder/src/echarts/chart/sankey/sankeyVisual.js b/public/en/builder/src/echarts/chart/sankey/sankeyVisual.js
index 8bb4ccf..45cfb8f 100644
--- a/public/en/builder/src/echarts/chart/sankey/sankeyVisual.js
+++ b/public/en/builder/src/echarts/chart/sankey/sankeyVisual.js
@@ -16,11 +16,6 @@
 * specific language governing permissions and limitations
 * under the License.
 */
-
-/**
- * @file Visual encoding for sankey view
- * @author  Deqing Li(annong035@gmail.com)
- */
 import VisualMapping from '../../visual/VisualMapping';
 import * as zrUtil from 'zrender/src/core/util';
 export default function (ecModel, payload) {
diff --git a/public/en/builder/src/echarts/chart/themeRiver/ThemeRiverSeries.js b/public/en/builder/src/echarts/chart/themeRiver/ThemeRiverSeries.js
index 2dd16a5..35a8b7c 100644
--- a/public/en/builder/src/echarts/chart/themeRiver/ThemeRiverSeries.js
+++ b/public/en/builder/src/echarts/chart/themeRiver/ThemeRiverSeries.js
@@ -16,11 +16,6 @@
 * specific language governing permissions and limitations
 * under the License.
 */
-
-/**
- * @file  Define the themeRiver view's series model
- * @author Deqing Li(annong035@gmail.com)
- */
 import SeriesModel from '../../model/Series';
 import createDimensions from '../../data/helper/createDimensions';
 import { getDimensionTypeByAxis } from '../../data/helper/dimensionHelper';
diff --git a/public/en/builder/src/echarts/chart/themeRiver/ThemeRiverView.js b/public/en/builder/src/echarts/chart/themeRiver/ThemeRiverView.js
index a496959..7b84e29 100644
--- a/public/en/builder/src/echarts/chart/themeRiver/ThemeRiverView.js
+++ b/public/en/builder/src/echarts/chart/themeRiver/ThemeRiverView.js
@@ -16,11 +16,6 @@
 * specific language governing permissions and limitations
 * under the License.
 */
-
-/**
- * @file  The file used to draw themeRiver view
- * @author  Deqing Li(annong035@gmail.com)
- */
 import * as echarts from '../../echarts';
 import { Polygon } from '../line/poly';
 import * as graphic from '../../util/graphic';
diff --git a/public/en/builder/src/echarts/chart/themeRiver/themeRiverLayout.js b/public/en/builder/src/echarts/chart/themeRiver/themeRiverLayout.js
index f60e0db..79fb47c 100644
--- a/public/en/builder/src/echarts/chart/themeRiver/themeRiverLayout.js
+++ b/public/en/builder/src/echarts/chart/themeRiver/themeRiverLayout.js
@@ -16,11 +16,6 @@
 * specific language governing permissions and limitations
 * under the License.
 */
-
-/**
- * @file  Using layout algorithm transform the raw data to layout information.
- * @author Deqing Li(annong035@gmail.com)
- */
 import * as zrUtil from 'zrender/src/core/util';
 import * as numberUtil from '../../util/number';
 export default function (ecModel, api) {
diff --git a/public/en/builder/src/echarts/chart/themeRiver/themeRiverVisual.js b/public/en/builder/src/echarts/chart/themeRiver/themeRiverVisual.js
index a78b591..e9ce012 100644
--- a/public/en/builder/src/echarts/chart/themeRiver/themeRiverVisual.js
+++ b/public/en/builder/src/echarts/chart/themeRiver/themeRiverVisual.js
@@ -16,11 +16,6 @@
 * specific language governing permissions and limitations
 * under the License.
 */
-
-/**
- * @file Visual encoding for themeRiver view
- * @author Deqing Li(annong035@gmail.com)
- */
 import { createHashMap } from 'zrender/src/core/util';
 export default function (ecModel) {
   ecModel.eachSeriesByType('themeRiver', function (seriesModel) {
diff --git a/public/en/builder/src/echarts/chart/tree/TreeSeries.js b/public/en/builder/src/echarts/chart/tree/TreeSeries.js
index d8e79a5..0f28625 100644
--- a/public/en/builder/src/echarts/chart/tree/TreeSeries.js
+++ b/public/en/builder/src/echarts/chart/tree/TreeSeries.js
@@ -16,11 +16,6 @@
 * specific language governing permissions and limitations
 * under the License.
 */
-
-/**
- * @file Create data struct and define tree view's series model
- * @author Deqing Li(annong035@gmail.com)
- */
 import SeriesModel from '../../model/Series';
 import Tree from '../../data/Tree';
 import { encodeHTML } from '../../util/format';
diff --git a/public/en/builder/src/echarts/chart/tree/TreeView.js b/public/en/builder/src/echarts/chart/tree/TreeView.js
index 8501ada..3f99cfe 100644
--- a/public/en/builder/src/echarts/chart/tree/TreeView.js
+++ b/public/en/builder/src/echarts/chart/tree/TreeView.js
@@ -16,11 +16,6 @@
 * specific language governing permissions and limitations
 * under the License.
 */
-
-/**
- * @file This file used to draw tree view.
- * @author Deqing Li(annong035@gmail.com)
- */
 import * as zrUtil from 'zrender/src/core/util';
 import * as graphic from '../../util/graphic';
 import SymbolClz from '../helper/Symbol';
diff --git a/public/en/builder/src/echarts/chart/tree/treeAction.js b/public/en/builder/src/echarts/chart/tree/treeAction.js
index d928444..15992ec 100644
--- a/public/en/builder/src/echarts/chart/tree/treeAction.js
+++ b/public/en/builder/src/echarts/chart/tree/treeAction.js
@@ -16,11 +16,6 @@
 * specific language governing permissions and limitations
 * under the License.
 */
-
-/**
- * @file Register the actions of the tree
- * @author Deqing Li(annong035@gmail.com)
- */
 import * as echarts from '../../echarts';
 import { updateCenterAndZoom } from '../../action/roamHelper';
 echarts.registerAction({
diff --git a/public/en/builder/src/echarts/component/brush/selector.js b/public/en/builder/src/echarts/component/brush/selector.js
index bf57d60..3179b51 100644
--- a/public/en/builder/src/echarts/component/brush/selector.js
+++ b/public/en/builder/src/echarts/component/brush/selector.js
@@ -17,7 +17,8 @@
 * under the License.
 */
 import * as polygonContain from 'zrender/src/contain/polygon';
-import BoundingRect from 'zrender/src/core/BoundingRect'; // Key of the first level is brushType: `line`, `rect`, `polygon`.
+import BoundingRect from 'zrender/src/core/BoundingRect';
+import { linePolygonIntersect } from '../../util/graphic'; // Key of the first level is brushType: `line`, `rect`, `polygon`.
 // Key of the second level is chart element type: `point`, `rect`.
 // See moudule:echarts/component/helper/BrushController
 // function param:
@@ -55,7 +56,7 @@
       var height = itemLayout.height;
       var p = points[0];
 
-      if (polygonContain.contain(points, x, y) || polygonContain.contain(points, x + width, y) || polygonContain.contain(points, x, y + height) || polygonContain.contain(points, x + width, y + height) || BoundingRect.create(itemLayout).contain(p[0], p[1]) || lineIntersectPolygon(x, y, x + width, y, points) || lineIntersectPolygon(x, y, x, y + height, points) || lineIntersectPolygon(x + width, y, x + width, y + height, points) || lineIntersectPolygon(x, y + height, x + width, y + height, points)) {
+      if (polygonContain.contain(points, x, y) || polygonContain.contain(points, x + width, y) || polygonContain.contain(points, x, y + height) || polygonContain.contain(points, x + width, y + height) || BoundingRect.create(itemLayout).contain(p[0], p[1]) || linePolygonIntersect(x, y, x + width, y, points) || linePolygonIntersect(x, y, x, y + height, points) || linePolygonIntersect(x + width, y, x + width, y + height, points) || linePolygonIntersect(x, y + height, x + width, y + height, points)) {
         return true;
       }
     }
@@ -88,49 +89,4 @@
   return range[0] <= p && p <= range[1];
 }
 
-function lineIntersectPolygon(lx, ly, l2x, l2y, points) {
-  for (var i = 0, p2 = points[points.length - 1]; i < points.length; i++) {
-    var p = points[i];
-
-    if (lineIntersect(lx, ly, l2x, l2y, p[0], p[1], p2[0], p2[1])) {
-      return true;
-    }
-
-    p2 = p;
-  }
-} // Code from <http://blog.csdn.net/rickliuxiao/article/details/6259322> with some fix.
-// See <https://en.wikipedia.org/wiki/Line%E2%80%93line_intersection>
-
-
-function lineIntersect(a1x, a1y, a2x, a2y, b1x, b1y, b2x, b2y) {
-  var delta = determinant(a2x - a1x, b1x - b2x, a2y - a1y, b1y - b2y);
-
-  if (nearZero(delta)) {
-    // parallel
-    return false;
-  }
-
-  var namenda = determinant(b1x - a1x, b1x - b2x, b1y - a1y, b1y - b2y) / delta;
-
-  if (namenda < 0 || namenda > 1) {
-    return false;
-  }
-
-  var miu = determinant(a2x - a1x, b1x - a1x, a2y - a1y, b1y - a1y) / delta;
-
-  if (miu < 0 || miu > 1) {
-    return false;
-  }
-
-  return true;
-}
-
-function nearZero(val) {
-  return val <= 1e-6 && val >= -1e-6;
-}
-
-function determinant(v1, v2, v3, v4) {
-  return v1 * v4 - v2 * v3;
-}
-
 export default selector;
\ No newline at end of file
diff --git a/public/en/builder/src/echarts/component/calendar.js b/public/en/builder/src/echarts/component/calendar.js
index a578ee6..6905de2 100644
--- a/public/en/builder/src/echarts/component/calendar.js
+++ b/public/en/builder/src/echarts/component/calendar.js
@@ -16,11 +16,6 @@
 * specific language governing permissions and limitations
 * under the License.
 */
-
-/**
- * @file calendar.js
- * @author dxh
- */
 import '../coord/calendar/Calendar';
 import '../coord/calendar/CalendarModel';
 import './calendar/CalendarView';
\ No newline at end of file
diff --git a/public/en/builder/src/echarts/component/toolbox/feature/DataView.js b/public/en/builder/src/echarts/component/toolbox/feature/DataView.js
index 752d851..7e4923a 100644
--- a/public/en/builder/src/echarts/component/toolbox/feature/DataView.js
+++ b/public/en/builder/src/echarts/component/toolbox/feature/DataView.js
@@ -398,22 +398,7 @@
   refreshButton.style.cssText = buttonStyle;
   closeButton.style.cssText = buttonStyle;
   !model.get('readOnly') && buttonContainer.appendChild(refreshButton);
-  buttonContainer.appendChild(closeButton); // http://stackoverflow.com/questions/6637341/use-tab-to-indent-in-textarea
-
-  eventTool.addEventListener(textarea, 'keydown', function (e) {
-    if ((e.keyCode || e.which) === 9) {
-      // get caret position/selection
-      var val = this.value;
-      var start = this.selectionStart;
-      var end = this.selectionEnd; // set textarea value to: text before caret + tab + text after caret
-
-      this.value = val.substring(0, start) + ITEM_SPLITER + val.substring(end); // put caret at right position again
-
-      this.selectionStart = this.selectionEnd = start + 1; // prevent the focus lose
-
-      eventTool.stop(e);
-    }
-  });
+  buttonContainer.appendChild(closeButton);
   root.appendChild(header);
   root.appendChild(viewMain);
   root.appendChild(buttonContainer);
diff --git a/public/en/builder/src/echarts/component/tooltip/TooltipContent.js b/public/en/builder/src/echarts/component/tooltip/TooltipContent.js
index 6758935..20e0ee4 100644
--- a/public/en/builder/src/echarts/component/tooltip/TooltipContent.js
+++ b/public/en/builder/src/echarts/component/tooltip/TooltipContent.js
@@ -195,7 +195,9 @@
   show: function (tooltipModel) {
     clearTimeout(this._hideTimeout);
     var el = this.el;
-    el.style.cssText = gCssText + assembleCssText(tooltipModel) // http://stackoverflow.com/questions/21125587/css3-transition-not-working-in-chrome-anymore
+    el.style.cssText = gCssText + assembleCssText(tooltipModel) // Because of the reason described in:
+    // http://stackoverflow.com/questions/21125587/css3-transition-not-working-in-chrome-anymore
+    // we should set initial value to `left` and `top`.
     + ';left:' + this._x + 'px;top:' + this._y + 'px;' + (tooltipModel.get('extraCssText') || '');
     el.style.display = el.innerHTML ? 'block' : 'none'; // If mouse occsionally move over the tooltip, a mouseout event will be
     // triggered by canvas, and cuase some unexpectable result like dragging
diff --git a/public/en/builder/src/echarts/data/Graph.js b/public/en/builder/src/echarts/data/Graph.js
index 4ca05ca..87ef723 100644
--- a/public/en/builder/src/echarts/data/Graph.js
+++ b/public/en/builder/src/echarts/data/Graph.js
@@ -16,13 +16,6 @@
 * specific language governing permissions and limitations
 * under the License.
 */
-
-/**
- * Graph data structure
- *
- * @module echarts/data/Graph
- * @author Yi Shen(https://www.github.com/pissang)
- */
 import { __DEV__ } from '../config';
 import * as zrUtil from 'zrender/src/core/util';
 import { enableClassCheck } from '../util/clazz'; // id may be function name of Object, add a prefix to avoid this problem.
diff --git a/public/en/builder/src/echarts/helper.js b/public/en/builder/src/echarts/helper.js
index 654117c..bccbf12 100644
--- a/public/en/builder/src/echarts/helper.js
+++ b/public/en/builder/src/echarts/helper.js
@@ -52,7 +52,6 @@
 };
 /**
  * Create a symbol element with given symbol configuration: shape, x, y, width, height, color
- * @see http://echarts.baidu.com/option.html#series-scatter.symbol
  * @param {string} symbolDesc
  * @param {number} x
  * @param {number} y
diff --git a/public/en/builder/src/echarts/util/KDTree.js b/public/en/builder/src/echarts/util/KDTree.js
index a29e746..9667fcc 100644
--- a/public/en/builder/src/echarts/util/KDTree.js
+++ b/public/en/builder/src/echarts/util/KDTree.js
@@ -16,13 +16,6 @@
 * specific language governing permissions and limitations
 * under the License.
 */
-
-/**
- * K-Dimension Tree
- *
- * @module echarts/data/KDTree
- * @author Yi Shen(https://github.com/pissang)
- */
 import quickSelect from './quickSelect';
 
 function Node(axis, data) {
diff --git a/public/en/builder/src/echarts/util/graphic.js b/public/en/builder/src/echarts/util/graphic.js
index 83a7b4b..002f5b4 100644
--- a/public/en/builder/src/echarts/util/graphic.js
+++ b/public/en/builder/src/echarts/util/graphic.js
@@ -1227,4 +1227,92 @@
     return iconStr.indexOf('image://') === 0 ? (style.image = iconStr.slice(8), zrUtil.defaults(style, rect), new ZImage(opt)) : makePath(iconStr.replace('path://', ''), opt, rect, 'center');
   }
 }
+/**
+ * Return `true` if the given line (line `a`) and the given polygon
+ * are intersect.
+ * Note that we do not count colinear as intersect here because no
+ * requirement for that. We could do that if required in future.
+ *
+ * @param {number} a1x
+ * @param {number} a1y
+ * @param {number} a2x
+ * @param {number} a2y
+ * @param {Array.<Array.<number>>} points Points of the polygon.
+ * @return {boolean}
+ */
+
+export function linePolygonIntersect(a1x, a1y, a2x, a2y, points) {
+  for (var i = 0, p2 = points[points.length - 1]; i < points.length; i++) {
+    var p = points[i];
+
+    if (lineLineIntersect(a1x, a1y, a2x, a2y, p[0], p[1], p2[0], p2[1])) {
+      return true;
+    }
+
+    p2 = p;
+  }
+}
+/**
+ * Return `true` if the given two lines (line `a` and line `b`)
+ * are intersect.
+ * Note that we do not count colinear as intersect here because no
+ * requirement for that. We could do that if required in future.
+ *
+ * @param {number} a1x
+ * @param {number} a1y
+ * @param {number} a2x
+ * @param {number} a2y
+ * @param {number} b1x
+ * @param {number} b1y
+ * @param {number} b2x
+ * @param {number} b2y
+ * @return {boolean}
+ */
+
+export function lineLineIntersect(a1x, a1y, a2x, a2y, b1x, b1y, b2x, b2y) {
+  // let `vec_m` to be `vec_a2 - vec_a1` and `vec_n` to be `vec_b2 - vec_b1`.
+  var mx = a2x - a1x;
+  var my = a2y - a1y;
+  var nx = b2x - b1x;
+  var ny = b2y - b1y; // `vec_m` and `vec_n` are parallel iff
+  //     exising `k` such that `vec_m = k · vec_n`, equivalent to `vec_m X vec_n = 0`.
+
+  var nmCrossProduct = crossProduct2d(nx, ny, mx, my);
+
+  if (nearZero(nmCrossProduct)) {
+    return false;
+  } // `vec_m` and `vec_n` are intersect iff
+  //     existing `p` and `q` in [0, 1] such that `vec_a1 + p * vec_m = vec_b1 + q * vec_n`,
+  //     such that `q = ((vec_a1 - vec_b1) X vec_m) / (vec_n X vec_m)`
+  //           and `p = ((vec_a1 - vec_b1) X vec_n) / (vec_n X vec_m)`.
+
+
+  var b1a1x = a1x - b1x;
+  var b1a1y = a1y - b1y;
+  var q = crossProduct2d(b1a1x, b1a1y, mx, my) / nmCrossProduct;
+
+  if (q < 0 || q > 1) {
+    return false;
+  }
+
+  var p = crossProduct2d(b1a1x, b1a1y, nx, ny) / nmCrossProduct;
+
+  if (p < 0 || p > 1) {
+    return false;
+  }
+
+  return true;
+}
+/**
+ * Cross product of 2-dimension vector.
+ */
+
+function crossProduct2d(x1, y1, x2, y2) {
+  return x1 * y2 - x2 * y1;
+}
+
+function nearZero(val) {
+  return val <= 1e-6 && val >= -1e-6;
+}
+
 export { Group, ZImage as Image, Text, Circle, Sector, Ring, Polygon, Polyline, Rect, Line, BezierCurve, Arc, IncrementalDisplayable, CompoundPath, LinearGradient, RadialGradient, BoundingRect };
\ No newline at end of file
diff --git a/public/en/builder/src/echarts/util/quickSelect.js b/public/en/builder/src/echarts/util/quickSelect.js
index 8d7f9d8..3bbf1ee 100644
--- a/public/en/builder/src/echarts/util/quickSelect.js
+++ b/public/en/builder/src/echarts/util/quickSelect.js
@@ -21,9 +21,6 @@
  * Quick select n-th element in an array.
  *
  * Note: it will change the elements placement in array.
- *
- * @module echarts/core/quickSelect
- * @author Yi Shen(https://github.com/pissang)
  */
 function defaultCompareFunc(a, b) {
   return a - b;
diff --git a/public/en/changelog.html b/public/en/changelog.html
index f006913..4f4df9b 100644
--- a/public/en/changelog.html
+++ b/public/en/changelog.html
@@ -1,4 +1,4 @@
-<!DOCTYPE html><html lang="en-US"><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width, initial-scale=1" user-scalable="no"><meta name="description" content="ECharts, a powerful, interactive charting and visualization library for browser"><link rel="shortcut icon" href="images/favicon.png"><link rel="stylesheet" type="text/css" href="https://cdn.jsdelivr.net/npm/bootstrap@3.3.7/dist/css/bootstrap.min.css"><!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries--><!--[if lt IE 9]><script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script><script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script><![endif]--><link rel="stylesheet" type="text/css" href="./css/main.css?_v_=1567711848565"><script>window.EC_WWW_LANG = 'en';
+<!DOCTYPE html><html lang="en-US"><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width, initial-scale=1" user-scalable="no"><meta name="description" content="ECharts, a powerful, interactive charting and visualization library for browser"><link rel="shortcut icon" href="images/favicon.png"><link rel="stylesheet" type="text/css" href="https://cdn.jsdelivr.net/npm/bootstrap@3.3.7/dist/css/bootstrap.min.css"><!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries--><!--[if lt IE 9]><script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script><script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script><![endif]--><link rel="stylesheet" type="text/css" href="./css/main.css?_v_=1568642955357"><script>window.EC_WWW_LANG = 'en';
 </script><script type="text/javascript" src="./vendors/pace/pace.min.js"></script><script id="font-hack" type="text/javascript">if (/windows/i.test(navigator.userAgent)) {
     var el = document.createElement('style');
     el.innerHTML = ''
diff --git a/public/en/cheat-sheet.html b/public/en/cheat-sheet.html
index 681d3b4..47a9cda 100644
--- a/public/en/cheat-sheet.html
+++ b/public/en/cheat-sheet.html
@@ -1,4 +1,4 @@
-<!DOCTYPE html><html lang="en-US"><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width, initial-scale=1" user-scalable="no"><meta name="description" content="ECharts, a powerful, interactive charting and visualization library for browser"><link rel="shortcut icon" href="images/favicon.png"><link rel="stylesheet" type="text/css" href="https://cdn.jsdelivr.net/npm/bootstrap@3.3.7/dist/css/bootstrap.min.css"><!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries--><!--[if lt IE 9]><script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script><script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script><![endif]--><link rel="stylesheet" type="text/css" href="./css/main.css?_v_=1567711848565"><script>window.EC_WWW_LANG = 'en';
+<!DOCTYPE html><html lang="en-US"><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width, initial-scale=1" user-scalable="no"><meta name="description" content="ECharts, a powerful, interactive charting and visualization library for browser"><link rel="shortcut icon" href="images/favicon.png"><link rel="stylesheet" type="text/css" href="https://cdn.jsdelivr.net/npm/bootstrap@3.3.7/dist/css/bootstrap.min.css"><!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries--><!--[if lt IE 9]><script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script><script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script><![endif]--><link rel="stylesheet" type="text/css" href="./css/main.css?_v_=1568642955357"><script>window.EC_WWW_LANG = 'en';
 </script><script type="text/javascript" src="./vendors/pace/pace.min.js"></script><script id="font-hack" type="text/javascript">if (/windows/i.test(navigator.userAgent)) {
     var el = document.createElement('style');
     el.innerHTML = ''
diff --git a/public/en/coding-standard.html b/public/en/coding-standard.html
index cd9b62e..2a4e49d 100644
--- a/public/en/coding-standard.html
+++ b/public/en/coding-standard.html
@@ -1,4 +1,4 @@
-<!DOCTYPE html><html lang="en-US"><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width, initial-scale=1" user-scalable="no"><meta name="description" content="ECharts, a powerful, interactive charting and visualization library for browser"><link rel="shortcut icon" href="images/favicon.png"><link rel="stylesheet" type="text/css" href="https://cdn.jsdelivr.net/npm/bootstrap@3.3.7/dist/css/bootstrap.min.css"><!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries--><!--[if lt IE 9]><script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script><script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script><![endif]--><link rel="stylesheet" type="text/css" href="./css/main.css?_v_=1567711848565"><script>window.EC_WWW_LANG = 'en';
+<!DOCTYPE html><html lang="en-US"><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width, initial-scale=1" user-scalable="no"><meta name="description" content="ECharts, a powerful, interactive charting and visualization library for browser"><link rel="shortcut icon" href="images/favicon.png"><link rel="stylesheet" type="text/css" href="https://cdn.jsdelivr.net/npm/bootstrap@3.3.7/dist/css/bootstrap.min.css"><!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries--><!--[if lt IE 9]><script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script><script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script><![endif]--><link rel="stylesheet" type="text/css" href="./css/main.css?_v_=1568642955357"><script>window.EC_WWW_LANG = 'en';
 </script><script type="text/javascript" src="./vendors/pace/pace.min.js"></script><script id="font-hack" type="text/javascript">if (/windows/i.test(navigator.userAgent)) {
     var el = document.createElement('style');
     el.innerHTML = ''
diff --git a/public/en/committers.html b/public/en/committers.html
index 1965d35..8285386 100644
--- a/public/en/committers.html
+++ b/public/en/committers.html
@@ -1,4 +1,4 @@
-<!DOCTYPE html><html lang="en-US"><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width, initial-scale=1" user-scalable="no"><meta name="description" content="ECharts, a powerful, interactive charting and visualization library for browser"><link rel="shortcut icon" href="images/favicon.png"><link rel="stylesheet" type="text/css" href="https://cdn.jsdelivr.net/npm/bootstrap@3.3.7/dist/css/bootstrap.min.css"><!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries--><!--[if lt IE 9]><script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script><script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script><![endif]--><link rel="stylesheet" type="text/css" href="./css/main.css?_v_=1567711848565"><script>window.EC_WWW_LANG = 'en';
+<!DOCTYPE html><html lang="en-US"><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width, initial-scale=1" user-scalable="no"><meta name="description" content="ECharts, a powerful, interactive charting and visualization library for browser"><link rel="shortcut icon" href="images/favicon.png"><link rel="stylesheet" type="text/css" href="https://cdn.jsdelivr.net/npm/bootstrap@3.3.7/dist/css/bootstrap.min.css"><!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries--><!--[if lt IE 9]><script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script><script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script><![endif]--><link rel="stylesheet" type="text/css" href="./css/main.css?_v_=1568642955357"><script>window.EC_WWW_LANG = 'en';
 </script><script type="text/javascript" src="./vendors/pace/pace.min.js"></script><script id="font-hack" type="text/javascript">if (/windows/i.test(navigator.userAgent)) {
     var el = document.createElement('style');
     el.innerHTML = ''
diff --git a/public/en/dependencies.html b/public/en/dependencies.html
index 078919b..59821b0 100644
--- a/public/en/dependencies.html
+++ b/public/en/dependencies.html
@@ -1,4 +1,4 @@
-<!DOCTYPE html><html lang="en-US"><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width, initial-scale=1" user-scalable="no"><meta name="description" content="ECharts, a powerful, interactive charting and visualization library for browser"><link rel="shortcut icon" href="images/favicon.png"><link rel="stylesheet" type="text/css" href="https://cdn.jsdelivr.net/npm/bootstrap@3.3.7/dist/css/bootstrap.min.css"><!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries--><!--[if lt IE 9]><script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script><script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script><![endif]--><link rel="stylesheet" type="text/css" href="./css/main.css?_v_=1567711848565"><script>window.EC_WWW_LANG = 'en';
+<!DOCTYPE html><html lang="en-US"><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width, initial-scale=1" user-scalable="no"><meta name="description" content="ECharts, a powerful, interactive charting and visualization library for browser"><link rel="shortcut icon" href="images/favicon.png"><link rel="stylesheet" type="text/css" href="https://cdn.jsdelivr.net/npm/bootstrap@3.3.7/dist/css/bootstrap.min.css"><!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media queries--><!--[if lt IE 9]><script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script><script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script><![endif]--><link rel="stylesheet" type="text/css" href="./css/main.css?_v_=1568642955357"><script>window.EC_WWW_LANG = 'en';
 </script><script type="text/javascript" src="./vendors/pace/pace.min.js"></script><script id="font-hack" type="text/javascript">if (/windows/i.test(navigator.userAgent)) {
     var el = document.createElement('style');
     el.innerHTML = ''
diff --git a/public/en/dist/echarts-en.common.js b/public/en/dist/echarts-en.common.js
index 9605e93..0250538 100644
--- a/public/en/dist/echarts-en.common.js
+++ b/public/en/dist/echarts-en.common.js
@@ -17966,6 +17966,88 @@
     }
 }
 
+/**
+ * Return `true` if the given line (line `a`) and the given polygon
+ * are intersect.
+ * Note that we do not count colinear as intersect here because no
+ * requirement for that. We could do that if required in future.
+ *
+ * @param {number} a1x
+ * @param {number} a1y
+ * @param {number} a2x
+ * @param {number} a2y
+ * @param {Array.<Array.<number>>} points Points of the polygon.
+ * @return {boolean}
+ */
+function linePolygonIntersect(a1x, a1y, a2x, a2y, points) {
+    for (var i = 0, p2 = points[points.length - 1]; i < points.length; i++) {
+        var p = points[i];
+        if (lineLineIntersect(a1x, a1y, a2x, a2y, p[0], p[1], p2[0], p2[1])) {
+            return true;
+        }
+        p2 = p;
+    }
+}
+
+/**
+ * Return `true` if the given two lines (line `a` and line `b`)
+ * are intersect.
+ * Note that we do not count colinear as intersect here because no
+ * requirement for that. We could do that if required in future.
+ *
+ * @param {number} a1x
+ * @param {number} a1y
+ * @param {number} a2x
+ * @param {number} a2y
+ * @param {number} b1x
+ * @param {number} b1y
+ * @param {number} b2x
+ * @param {number} b2y
+ * @return {boolean}
+ */
+function lineLineIntersect(a1x, a1y, a2x, a2y, b1x, b1y, b2x, b2y) {
+    // let `vec_m` to be `vec_a2 - vec_a1` and `vec_n` to be `vec_b2 - vec_b1`.
+    var mx = a2x - a1x;
+    var my = a2y - a1y;
+    var nx = b2x - b1x;
+    var ny = b2y - b1y;
+
+    // `vec_m` and `vec_n` are parallel iff
+    //     exising `k` such that `vec_m = k · vec_n`, equivalent to `vec_m X vec_n = 0`.
+    var nmCrossProduct = crossProduct2d(nx, ny, mx, my);
+    if (nearZero(nmCrossProduct)) {
+        return false;
+    }
+
+    // `vec_m` and `vec_n` are intersect iff
+    //     existing `p` and `q` in [0, 1] such that `vec_a1 + p * vec_m = vec_b1 + q * vec_n`,
+    //     such that `q = ((vec_a1 - vec_b1) X vec_m) / (vec_n X vec_m)`
+    //           and `p = ((vec_a1 - vec_b1) X vec_n) / (vec_n X vec_m)`.
+    var b1a1x = a1x - b1x;
+    var b1a1y = a1y - b1y;
+    var q = crossProduct2d(b1a1x, b1a1y, mx, my) / nmCrossProduct;
+    if (q < 0 || q > 1) {
+        return false;
+    }
+    var p = crossProduct2d(b1a1x, b1a1y, nx, ny) / nmCrossProduct;
+    if (p < 0 || p > 1) {
+        return false;
+    }
+
+    return true;
+}
+
+/**
+ * Cross product of 2-dimension vector.
+ */
+function crossProduct2d(x1, y1, x2, y2) {
+    return x1 * y2 - x2 * y1;
+}
+
+function nearZero(val) {
+    return val <= (1e-6) && val >= -(1e-6);
+}
+
 
 
 
@@ -18000,6 +18082,8 @@
 	clipPointsByRect: clipPointsByRect,
 	clipRectByRect: clipRectByRect,
 	createIcon: createIcon,
+	linePolygonIntersect: linePolygonIntersect,
+	lineLineIntersect: lineLineIntersect,
 	Group: Group,
 	Image: ZImage,
 	Text: Text,
@@ -46682,7 +46766,9 @@
         var el = this.el;
 
         el.style.cssText = gCssText + assembleCssText(tooltipModel)
+            // Because of the reason described in:
             // http://stackoverflow.com/questions/21125587/css3-transition-not-working-in-chrome-anymore
+            // we should set initial value to `left` and `top`.
             + ';left:' + this._x + 'px;top:' + this._y + 'px;'
             + (tooltipModel.get('extraCssText') || '');
 
@@ -56230,25 +56316,6 @@
     !model.get('readOnly') && buttonContainer.appendChild(refreshButton);
     buttonContainer.appendChild(closeButton);
 
-    // http://stackoverflow.com/questions/6637341/use-tab-to-indent-in-textarea
-    addEventListener(textarea, 'keydown', function (e) {
-        if ((e.keyCode || e.which) === 9) {
-            // get caret position/selection
-            var val = this.value;
-            var start = this.selectionStart;
-            var end = this.selectionEnd;
-
-            // set textarea value to: text before caret + tab + text after caret
-            this.value = val.substring(0, start) + ITEM_SPLITER + val.substring(end);
-
-            // put caret at right position again
-            this.selectionStart = this.selectionEnd = start + 1;
-
-            // prevent the focus lose
-            stop(e);
-        }
-    });
-
     root.appendChild(header);
     root.appendChild(viewMain);
     root.appendChild(buttonContainer);
diff --git a/public/en/dist/echarts-en.common.min.js b/public/en/dist/echarts-en.common.min.js
index ca98c0a..ea1b3e1 100644
--- a/public/en/dist/echarts-en.common.min.js
+++ b/public/en/dist/echarts-en.common.min.js
@@ -19,4 +19,4 @@
 */
 
 
-!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports):"function"==typeof define&&define.amd?define(["exports"],e):e(t.echarts={})}(this,function(t){"use strict";var e=2311,i=function(){return e++},v="object"==typeof wx&&"function"==typeof wx.getSystemInfoSync?{browser:{},os:{},node:!1,wxa:!0,canvasSupported:!0,svgSupported:!1,touchEventsSupported:!0,domSupported:!1}:"undefined"==typeof document&&"undefined"!=typeof self?{browser:{},os:{},node:!1,worker:!0,canvasSupported:!0,domSupported:!1}:"undefined"==typeof navigator?{browser:{},os:{},node:!0,worker:!1,canvasSupported:!0,svgSupported:!0,domSupported:!1}:function(t){var e={},n=t.match(/Firefox\/([\d.]+)/),i=t.match(/MSIE\s([\d.]+)/)||t.match(/Trident\/.+?rv:(([\d.]+))/),r=t.match(/Edge\/([\d.]+)/),a=/micromessenger/i.test(t);n&&(e.firefox=!0,e.version=n[1]);i&&(e.ie=!0,e.version=i[1]);r&&(e.edge=!0,e.version=r[1]);a&&(e.weChat=!0);return{browser:e,os:{},node:!1,canvasSupported:!!document.createElement("canvas").getContext,svgSupported:"undefined"!=typeof SVGRect,touchEventsSupported:"ontouchstart"in window&&!e.ie&&!e.edge,pointerEventsSupported:"onpointerdown"in window&&(e.edge||e.ie&&11<=e.version),domSupported:"undefined"!=typeof document}}(navigator.userAgent);var s={"[object Function]":1,"[object RegExp]":1,"[object Date]":1,"[object Error]":1,"[object CanvasGradient]":1,"[object CanvasPattern]":1,"[object Image]":1,"[object Canvas]":1},l={"[object Int8Array]":1,"[object Uint8Array]":1,"[object Uint8ClampedArray]":1,"[object Int16Array]":1,"[object Uint16Array]":1,"[object Int32Array]":1,"[object Uint32Array]":1,"[object Float32Array]":1,"[object Float64Array]":1},h=Object.prototype.toString,n=Array.prototype,o=n.forEach,u=n.filter,r=n.slice,c=n.map,d=n.reduce,a={};function f(t,e){"createCanvas"===t&&(y=null),a[t]=e}function b(t){if(null==t||"object"!=typeof t)return t;var e=t,n=h.call(t);if("[object Array]"===n){if(!$(t)){e=[];for(var i=0,r=t.length;i<r;i++)e[i]=b(t[i])}}else if(l[n]){if(!$(t)){var a=t.constructor;if(t.constructor.from)e=a.from(t);else{e=new a(t.length);for(i=0,r=t.length;i<r;i++)e[i]=b(t[i])}}}else if(!s[n]&&!$(t)&&!F(t))for(var o in e={},t)t.hasOwnProperty(o)&&(e[o]=b(t[o]));return e}function m(t,e,n){if(!N(e)||!N(t))return n?b(e):t;for(var i in e)if(e.hasOwnProperty(i)){var r=t[i],a=e[i];!N(a)||!N(r)||O(a)||O(r)||F(a)||F(r)||R(a)||R(r)||$(a)||$(r)?!n&&i in t||(t[i]=b(e[i])):m(r,a,n)}return t}function p(t,e){for(var n=t[0],i=1,r=t.length;i<r;i++)n=m(n,t[i],e);return n}function I(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);return t}function T(t,e,n){for(var i in e)e.hasOwnProperty(i)&&(n?null!=e[i]:null==t[i])&&(t[i]=e[i]);return t}function g(){return a.createCanvas()}var y;function _(){return y=y||g().getContext("2d")}function x(t,e){if(t){if(t.indexOf)return t.indexOf(e);for(var n=0,i=t.length;n<i;n++)if(t[n]===e)return n}return-1}function w(t,e){var n=t.prototype;function i(){}for(var r in i.prototype=e.prototype,t.prototype=new i,n)t.prototype[r]=n[r];(t.prototype.constructor=t).superClass=e}function S(t,e,n){T(t="prototype"in t?t.prototype:t,e="prototype"in e?e.prototype:e,n)}function L(t){if(t)return"string"!=typeof t&&"number"==typeof t.length}function A(t,e,n){if(t&&e)if(t.forEach&&t.forEach===o)t.forEach(e,n);else if(t.length===+t.length)for(var i=0,r=t.length;i<r;i++)e.call(n,t[i],i,t);else for(var a in t)t.hasOwnProperty(a)&&e.call(n,t[a],a,t)}function D(t,e,n){if(t&&e){if(t.map&&t.map===c)return t.map(e,n);for(var i=[],r=0,a=t.length;r<a;r++)i.push(e.call(n,t[r],r,t));return i}}function M(t,e,n,i){if(t&&e){if(t.reduce&&t.reduce===d)return t.reduce(e,n,i);for(var r=0,a=t.length;r<a;r++)n=e.call(i,n,t[r],r,t);return n}}function C(t,e,n){if(t&&e){if(t.filter&&t.filter===u)return t.filter(e,n);for(var i=[],r=0,a=t.length;r<a;r++)e.call(n,t[r],r,t)&&i.push(t[r]);return i}}function k(t,e){var n=r.call(arguments,2);return function(){return t.apply(e,n.concat(r.call(arguments)))}}function P(t){var e=r.call(arguments,1);return function(){return t.apply(this,e.concat(r.call(arguments)))}}function O(t){return"[object Array]"===h.call(t)}function z(t){return"function"==typeof t}function E(t){return"[object String]"===h.call(t)}function N(t){var e=typeof t;return"function"==e||!!t&&"object"==e}function R(t){return!!s[h.call(t)]}function B(t){return!!l[h.call(t)]}function F(t){return"object"==typeof t&&"number"==typeof t.nodeType&&"object"==typeof t.ownerDocument}function V(t){return t!=t}function H(t){for(var e=0,n=arguments.length;e<n;e++)if(null!=arguments[e])return arguments[e]}function W(t,e){return null!=t?t:e}function G(t,e,n){return null!=t?t:null!=e?e:n}function Z(){return Function.call.apply(r,arguments)}function U(t){if("number"==typeof t)return[t,t,t,t];var e=t.length;return 2===e?[t[0],t[1],t[0],t[1]]:3===e?[t[0],t[1],t[2],t[1]]:t}function X(t,e){if(!t)throw new Error(e)}function Y(t){return null==t?null:"function"==typeof t.trim?t.trim():t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")}a.createCanvas=function(){return document.createElement("canvas")};var j="__ec_primitive__";function q(t){t[j]=!0}function $(t){return t[j]}function K(t){var n=O(t);this.data={};var i=this;function e(t,e){n?i.set(t,e):i.set(e,t)}t instanceof K?t.each(e):t&&A(t,e)}function Q(t){return new K(t)}function J(){}K.prototype={constructor:K,get:function(t){return this.data.hasOwnProperty(t)?this.data[t]:null},set:function(t,e){return this.data[t]=e},each:function(t,e){for(var n in void 0!==e&&(t=k(t,e)),this.data)this.data.hasOwnProperty(n)&&t(this.data[n],n)},removeKey:function(t){delete this.data[t]}};var tt=(Object.freeze||Object)({$override:f,clone:b,merge:m,mergeAll:p,extend:I,defaults:T,createCanvas:g,getContext:_,indexOf:x,inherits:w,mixin:S,isArrayLike:L,each:A,map:D,reduce:M,filter:C,find:function(t,e,n){if(t&&e)for(var i=0,r=t.length;i<r;i++)if(e.call(n,t[i],i,t))return t[i]},bind:k,curry:P,isArray:O,isFunction:z,isString:E,isObject:N,isBuiltInObject:R,isTypedArray:B,isDom:F,eqNaN:V,retrieve:H,retrieve2:W,retrieve3:G,slice:Z,normalizeCssArray:U,assert:X,trim:Y,setAsPrimitive:q,isPrimitive:$,createHashMap:Q,concatArray:function(t,e){for(var n=new t.constructor(t.length+e.length),i=0;i<t.length;i++)n[i]=t[i];var r=t.length;for(i=0;i<e.length;i++)n[i+r]=e[i];return n},noop:J}),et="undefined"==typeof Float32Array?Array:Float32Array;function nt(t,e){var n=new et(2);return null==t&&(t=0),null==e&&(e=0),n[0]=t,n[1]=e,n}function it(t,e){return t[0]=e[0],t[1]=e[1],t}function rt(t){var e=new et(2);return e[0]=t[0],e[1]=t[1],e}function at(t,e,n){return t[0]=e[0]+n[0],t[1]=e[1]+n[1],t}function ot(t,e,n,i){return t[0]=e[0]+n[0]*i,t[1]=e[1]+n[1]*i,t}function st(t,e,n){return t[0]=e[0]-n[0],t[1]=e[1]-n[1],t}function lt(t){return Math.sqrt(ut(t))}var ht=lt;function ut(t){return t[0]*t[0]+t[1]*t[1]}var ct=ut;function dt(t,e,n){return t[0]=e[0]*n,t[1]=e[1]*n,t}function ft(t,e){var n=lt(e);return 0===n?(t[0]=0,t[1]=0):(t[0]=e[0]/n,t[1]=e[1]/n),t}function pt(t,e){return Math.sqrt((t[0]-e[0])*(t[0]-e[0])+(t[1]-e[1])*(t[1]-e[1]))}var gt=pt;function mt(t,e){return(t[0]-e[0])*(t[0]-e[0])+(t[1]-e[1])*(t[1]-e[1])}var vt=mt;function yt(t,e,n){var i=e[0],r=e[1];return t[0]=n[0]*i+n[2]*r+n[4],t[1]=n[1]*i+n[3]*r+n[5],t}function _t(t,e,n){return t[0]=Math.min(e[0],n[0]),t[1]=Math.min(e[1],n[1]),t}function xt(t,e,n){return t[0]=Math.max(e[0],n[0]),t[1]=Math.max(e[1],n[1]),t}var wt=(Object.freeze||Object)({create:nt,copy:it,clone:rt,set:function(t,e,n){return t[0]=e,t[1]=n,t},add:at,scaleAndAdd:ot,sub:st,len:lt,length:ht,lenSquare:ut,lengthSquare:ct,mul:function(t,e,n){return t[0]=e[0]*n[0],t[1]=e[1]*n[1],t},div:function(t,e,n){return t[0]=e[0]/n[0],t[1]=e[1]/n[1],t},dot:function(t,e){return t[0]*e[0]+t[1]*e[1]},scale:dt,normalize:ft,distance:pt,dist:gt,distanceSquare:mt,distSquare:vt,negate:function(t,e){return t[0]=-e[0],t[1]=-e[1],t},lerp:function(t,e,n,i){return t[0]=e[0]+i*(n[0]-e[0]),t[1]=e[1]+i*(n[1]-e[1]),t},applyTransform:yt,min:_t,max:xt});function bt(){this.on("mousedown",this._dragStart,this),this.on("mousemove",this._drag,this),this.on("mouseup",this._dragEnd,this),this.on("globalout",this._dragEnd,this)}function St(t,e){return{target:t,topTarget:e&&e.topTarget}}bt.prototype={constructor:bt,_dragStart:function(t){var e=t.target;e&&e.draggable&&((this._draggingTarget=e).dragging=!0,this._x=t.offsetX,this._y=t.offsetY,this.dispatchToElement(St(e,t),"dragstart",t.event))},_drag:function(t){var e=this._draggingTarget;if(e){var n=t.offsetX,i=t.offsetY,r=n-this._x,a=i-this._y;this._x=n,this._y=i,e.drift(r,a,t),this.dispatchToElement(St(e,t),"drag",t.event);var o=this.findHover(n,i,e).target,s=this._dropTarget;e!==(this._dropTarget=o)&&(s&&o!==s&&this.dispatchToElement(St(s,t),"dragleave",t.event),o&&o!==s&&this.dispatchToElement(St(o,t),"dragenter",t.event))}},_dragEnd:function(t){var e=this._draggingTarget;e&&(e.dragging=!1),this.dispatchToElement(St(e,t),"dragend",t.event),this._dropTarget&&this.dispatchToElement(St(this._dropTarget,t),"drop",t.event),this._draggingTarget=null,this._dropTarget=null}};var Mt=Array.prototype.slice,It=function(t){this._$handlers={},this._$eventProcessor=t};function Ct(t,e,n,i,r,a){var o=t._$handlers;if("function"==typeof n&&(r=i,i=n,n=null),!i||!e)return t;n=function(t,e){var n=t._$eventProcessor;return null!=e&&n&&n.normalizeQuery&&(e=n.normalizeQuery(e)),e}(t,n),o[e]||(o[e]=[]);for(var s=0;s<o[e].length;s++)if(o[e][s].h===i)return t;var l={h:i,one:a,query:n,ctx:r||t,callAtLast:i.zrEventfulCallAtLast},h=o[e].length-1,u=o[e][h];return u&&u.callAtLast?o[e].splice(h,0,l):o[e].push(l),t}It.prototype={constructor:It,one:function(t,e,n,i){return Ct(this,t,e,n,i,!0)},on:function(t,e,n,i){return Ct(this,t,e,n,i,!1)},isSilent:function(t){var e=this._$handlers;return!e[t]||!e[t].length},off:function(t,e){var n=this._$handlers;if(!t)return this._$handlers={},this;if(e){if(n[t]){for(var i=[],r=0,a=n[t].length;r<a;r++)n[t][r].h!==e&&i.push(n[t][r]);n[t]=i}n[t]&&0===n[t].length&&delete n[t]}else delete n[t];return this},trigger:function(t){var e=this._$handlers[t],n=this._$eventProcessor;if(e){var i=arguments,r=i.length;3<r&&(i=Mt.call(i,1));for(var a=e.length,o=0;o<a;){var s=e[o];if(n&&n.filter&&null!=s.query&&!n.filter(t,s.query))o++;else{switch(r){case 1:s.h.call(s.ctx);break;case 2:s.h.call(s.ctx,i[1]);break;case 3:s.h.call(s.ctx,i[1],i[2]);break;default:s.h.apply(s.ctx,i)}s.one?(e.splice(o,1),a--):o++}}}return n&&n.afterTrigger&&n.afterTrigger(t),this},triggerWithContext:function(t){var e=this._$handlers[t],n=this._$eventProcessor;if(e){var i=arguments,r=i.length;4<r&&(i=Mt.call(i,1,i.length-1));for(var a=i[i.length-1],o=e.length,s=0;s<o;){var l=e[s];if(n&&n.filter&&null!=l.query&&!n.filter(t,l.query))s++;else{switch(r){case 1:l.h.call(a);break;case 2:l.h.call(a,i[1]);break;case 3:l.h.call(a,i[1],i[2]);break;default:l.h.apply(a,i)}l.one?(e.splice(s,1),o--):s++}}}return n&&n.afterTrigger&&n.afterTrigger(t),this}};var Tt=Math.log(2);function At(t,e,n,i,r,a){var o=i+"-"+r,s=t.length;if(a.hasOwnProperty(o))return a[o];if(1===e){var l=Math.round(Math.log((1<<s)-1&~r)/Tt);return t[n][l]}for(var h=i|1<<n,u=n+1;i&1<<u;)u++;for(var c=0,d=0,f=0;d<s;d++){var p=1<<d;p&r||(c+=(f%2?-1:1)*t[n][d]*At(t,e-1,u,h,r|p,a),f++)}return a[o]=c}var Dt="undefined"!=typeof window&&!!window.addEventListener,kt=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,Pt="___zrEVENTSAVED",Lt=[];function Ot(t,e,n,i){return n=n||{},i||!v.canvasSupported?zt(t,e,n):v.browser.firefox&&null!=e.layerX&&e.layerX!==e.offsetX?(n.zrX=e.layerX,n.zrY=e.layerY):null!=e.offsetX?(n.zrX=e.offsetX,n.zrY=e.offsetY):zt(t,e,n),n}function zt(t,e,n){if(t.getBoundingClientRect&&v.domSupported){var i=e.clientX,r=e.clientY;if("CANVAS"===t.nodeName.toUpperCase()){var a=t.getBoundingClientRect();return n.zrX=i-a.left,void(n.zrY=r-a.top)}var o=t[Pt]||(t[Pt]={}),s=function(t,e){for(var n=e.transformer,i=e.srcCoords,r=!0,a=[],o=[],s=0;s<4;s++){var l=t[s].getBoundingClientRect(),h=2*s,u=l.left,c=l.top;a.push(u,c),r&=i&&u===i[h]&&c===i[1+h],o.push(t[s].offsetLeft,t[s].offsetTop)}return r?n:(e.srcCoords=a,e.transformer=function(t,e){var n=[[t[0],t[1],1,0,0,0,-e[0]*t[0],-e[0]*t[1]],[0,0,0,t[0],t[1],1,-e[1]*t[0],-e[1]*t[1]],[t[2],t[3],1,0,0,0,-e[2]*t[2],-e[2]*t[3]],[0,0,0,t[2],t[3],1,-e[3]*t[2],-e[3]*t[3]],[t[4],t[5],1,0,0,0,-e[4]*t[4],-e[4]*t[5]],[0,0,0,t[4],t[5],1,-e[5]*t[4],-e[5]*t[5]],[t[6],t[7],1,0,0,0,-e[6]*t[6],-e[6]*t[7]],[0,0,0,t[6],t[7],1,-e[7]*t[6],-e[7]*t[7]]],i={},r=At(n,8,0,0,0,i);if(0!==r){for(var a=[],o=0;o<8;o++)for(var s=0;s<8;s++)null==a[s]&&(a[s]=0),a[s]+=((o+s)%2?-1:1)*At(n,7,0===o?1:0,1<<o,1<<s,i)/r*e[o];return function(t,e,n){var i=e*a[6]+n*a[7]+1;t[0]=(e*a[0]+n*a[1]+a[2])/i,t[1]=(e*a[3]+n*a[4]+a[5])/i}}}(a,o))}(function(t,e){var n=e.markers;if(n)return n;n=e.markers=[];for(var i=["left","right"],r=["top","bottom"],a=0;a<4;a++){var o=document.createElement("div"),s=o.style,l=a%2,h=(a>>1)%2;s.cssText=["position:absolute","visibility: hidden","padding: 0","margin: 0","border-width: 0","width:0","height:0",i[l]+":0",r[h]+":0",i[1-l]+":auto",r[1-h]+":auto",""].join("!important;"),t.appendChild(o),n.push(o)}return n}(t,o),o);if(s)return s(Lt,i,r),n.zrX=Lt[0],void(n.zrY=Lt[1])}n.zrX=n.zrY=0}function Et(t,e,n){if(null!=(e=e||window.event).zrX)return e;var i=e.type;if(i&&0<=i.indexOf("touch")){var r="touchend"!==i?e.targetTouches[0]:e.changedTouches[0];r&&Ot(t,r,e,n)}else Ot(t,e,e,n),e.zrDelta=e.wheelDelta?e.wheelDelta/120:-(e.detail||0)/3;var a=e.button;return null==e.which&&void 0!==a&&kt.test(e.type)&&(e.which=1&a?1:2&a?3:4&a?2:0),e}function Nt(t,e,n){Dt?t.addEventListener(e,n):t.attachEvent("on"+e,n)}var Rt=Dt?function(t){t.preventDefault(),t.stopPropagation(),t.cancelBubble=!0}:function(t){t.returnValue=!1,t.cancelBubble=!0};function Bt(t){return 2===t.which||3===t.which}function Ft(){this._track=[]}function Vt(t){var e=t[1][0]-t[0][0],n=t[1][1]-t[0][1];return Math.sqrt(e*e+n*n)}Ft.prototype={constructor:Ft,recognize:function(t,e,n){return this._doTrack(t,e,n),this._recognize(t)},clear:function(){return this._track.length=0,this},_doTrack:function(t,e,n){var i=t.touches;if(i){for(var r={points:[],touches:[],target:e,event:t},a=0,o=i.length;a<o;a++){var s=i[a],l=Ot(n,s,{});r.points.push([l.zrX,l.zrY]),r.touches.push(s)}this._track.push(r)}},_recognize:function(t){for(var e in Ht)if(Ht.hasOwnProperty(e)){var n=Ht[e](this._track,t);if(n)return n}}};var Ht={pinch:function(t,e){var n=t.length;if(n){var i=(t[n-1]||{}).points,r=(t[n-2]||{}).points||i;if(r&&1<r.length&&i&&1<i.length){var a=Vt(i)/Vt(r);isFinite(a)||(a=1),e.pinchScale=a;var o=function(t){return[(t[0][0]+t[1][0])/2,(t[0][1]+t[1][1])/2]}(i);return e.pinchX=o[0],e.pinchY=o[1],{type:"pinch",target:t[0].target,event:e}}}}},Wt="silent";function Gt(t){Rt(this.event)}function Zt(){}Zt.prototype.dispose=function(){};function Ut(t,e,n,i){It.call(this),this.storage=t,this.painter=e,this.painterRoot=i,n=n||new Zt,this.proxy=null,this._hovered={},this._lastTouchMoment,this._lastX,this._lastY,this._gestureMgr,bt.call(this),this.setHandlerProxy(n)}var Xt=["click","dblclick","mousewheel","mouseout","mouseup","mousedown","mousemove","contextmenu"];function Yt(t,e,n){if(t[t.rectHover?"rectContain":"contain"](e,n)){for(var i,r=t;r;){if(r.clipPath&&!r.clipPath.contain(e,n))return!1;r.silent&&(i=!0),r=r.parent}return!i||Wt}return!1}Ut.prototype={constructor:Ut,setHandlerProxy:function(e){this.proxy&&this.proxy.dispose(),e&&(A(Xt,function(t){e.on&&e.on(t,this[t],this)},this),e.handler=this),this.proxy=e},mousemove:function(t){var e=t.zrX,n=t.zrY,i=this._hovered,r=i.target;r&&!r.__zr&&(r=(i=this.findHover(i.x,i.y)).target);var a=this._hovered=this.findHover(e,n),o=a.target,s=this.proxy;s.setCursor&&s.setCursor(o?o.cursor:"default"),r&&o!==r&&this.dispatchToElement(i,"mouseout",t),this.dispatchToElement(a,"mousemove",t),o&&o!==r&&this.dispatchToElement(a,"mouseover",t)},mouseout:function(t){this.dispatchToElement(this._hovered,"mouseout",t);for(var e,n=t.toElement||t.relatedTarget;(n=n&&n.parentNode)&&9!==n.nodeType&&!(e=n===this.painterRoot););e||this.trigger("globalout",{event:t})},resize:function(t){this._hovered={}},dispatch:function(t,e){var n=this[t];n&&n.call(this,e)},dispose:function(){this.proxy.dispose(),this.storage=this.proxy=this.painter=null},setCursorStyle:function(t){var e=this.proxy;e.setCursor&&e.setCursor(t)},dispatchToElement:function(t,e,n){var i=(t=t||{}).target;if(!i||!i.silent){for(var r="on"+e,a=function(t,e,n){return{type:t,event:n,target:e.target,topTarget:e.topTarget,cancelBubble:!1,offsetX:n.zrX,offsetY:n.zrY,gestureEvent:n.gestureEvent,pinchX:n.pinchX,pinchY:n.pinchY,pinchScale:n.pinchScale,wheelDelta:n.zrDelta,zrByTouch:n.zrByTouch,which:n.which,stop:Gt}}(e,t,n);i&&(i[r]&&(a.cancelBubble=i[r].call(i,a)),i.trigger(e,a),i=i.parent,!a.cancelBubble););a.cancelBubble||(this.trigger(e,a),this.painter&&this.painter.eachOtherLayer(function(t){"function"==typeof t[r]&&t[r].call(t,a),t.trigger&&t.trigger(e,a)}))}},findHover:function(t,e,n){for(var i=this.storage.getDisplayList(),r={x:t,y:e},a=i.length-1;0<=a;a--){var o;if(i[a]!==n&&!i[a].ignore&&(o=Yt(i[a],t,e))&&(r.topTarget||(r.topTarget=i[a]),o!==Wt)){r.target=i[a];break}}return r},processGesture:function(t,e){this._gestureMgr||(this._gestureMgr=new Ft);var n=this._gestureMgr;"start"===e&&n.clear();var i=n.recognize(t,this.findHover(t.zrX,t.zrY,null).target,this.proxy.dom);if("end"===e&&n.clear(),i){var r=i.type;t.gestureEvent=r,this.dispatchToElement({target:i.target},r,i.event)}}},A(["click","mousedown","mouseup","mousewheel","dblclick","contextmenu"],function(i){Ut.prototype[i]=function(t){var e=this.findHover(t.zrX,t.zrY),n=e.target;if("mousedown"===i)this._downEl=n,this._downPoint=[t.zrX,t.zrY],this._upEl=n;else if("mouseup"===i)this._upEl=n;else if("click"===i){if(this._downEl!==this._upEl||!this._downPoint||4<gt(this._downPoint,[t.zrX,t.zrY]))return;this._downPoint=null}this.dispatchToElement(e,i,t)}}),S(Ut,It),S(Ut,bt);var jt="undefined"==typeof Float32Array?Array:Float32Array;function qt(){var t=new jt(6);return $t(t),t}function $t(t){return t[0]=1,t[1]=0,t[2]=0,t[3]=1,t[4]=0,t[5]=0,t}function Kt(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}function Qt(t,e,n){var i=e[0]*n[0]+e[2]*n[1],r=e[1]*n[0]+e[3]*n[1],a=e[0]*n[2]+e[2]*n[3],o=e[1]*n[2]+e[3]*n[3],s=e[0]*n[4]+e[2]*n[5]+e[4],l=e[1]*n[4]+e[3]*n[5]+e[5];return t[0]=i,t[1]=r,t[2]=a,t[3]=o,t[4]=s,t[5]=l,t}function Jt(t,e,n){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[4]=e[4]+n[0],t[5]=e[5]+n[1],t}function te(t,e,n){var i=e[0],r=e[2],a=e[4],o=e[1],s=e[3],l=e[5],h=Math.sin(n),u=Math.cos(n);return t[0]=i*u+o*h,t[1]=-i*h+o*u,t[2]=r*u+s*h,t[3]=-r*h+u*s,t[4]=u*a+h*l,t[5]=u*l-h*a,t}function ee(t,e,n){var i=n[0],r=n[1];return t[0]=e[0]*i,t[1]=e[1]*r,t[2]=e[2]*i,t[3]=e[3]*r,t[4]=e[4]*i,t[5]=e[5]*r,t}function ne(t,e){var n=e[0],i=e[2],r=e[4],a=e[1],o=e[3],s=e[5],l=n*o-a*i;return l?(l=1/l,t[0]=o*l,t[1]=-a*l,t[2]=-i*l,t[3]=n*l,t[4]=(i*s-o*r)*l,t[5]=(a*r-n*s)*l,t):null}var ie=(Object.freeze||Object)({create:qt,identity:$t,copy:Kt,mul:Qt,translate:Jt,rotate:te,scale:ee,invert:ne,clone:function(t){var e=qt();return Kt(e,t),e}}),re=$t;function ae(t){return 5e-5<t||t<-5e-5}var oe=function(t){(t=t||{}).position||(this.position=[0,0]),null==t.rotation&&(this.rotation=0),t.scale||(this.scale=[1,1]),this.origin=this.origin||null},se=oe.prototype;se.transform=null,se.needLocalTransform=function(){return ae(this.rotation)||ae(this.position[0])||ae(this.position[1])||ae(this.scale[0]-1)||ae(this.scale[1]-1)};var le=[];se.updateTransform=function(){var t=this.parent,e=t&&t.transform,n=this.needLocalTransform(),i=this.transform;if(n||e){i=i||qt(),n?this.getLocalTransform(i):re(i),e&&(n?Qt(i,t.transform,i):Kt(i,t.transform)),this.transform=i;var r=this.globalScaleRatio;if(null!=r&&1!==r){this.getGlobalScale(le);var a=le[0]<0?-1:1,o=le[1]<0?-1:1,s=((le[0]-a)*r+a)/le[0]||0,l=((le[1]-o)*r+o)/le[1]||0;i[0]*=s,i[1]*=s,i[2]*=l,i[3]*=l}this.invTransform=this.invTransform||qt(),ne(this.invTransform,i)}else i&&re(i)},se.getLocalTransform=function(t){return oe.getLocalTransform(this,t)},se.setTransform=function(t){var e=this.transform,n=t.dpr||1;e?t.setTransform(n*e[0],n*e[1],n*e[2],n*e[3],n*e[4],n*e[5]):t.setTransform(n,0,0,n,0,0)},se.restoreTransform=function(t){var e=t.dpr||1;t.setTransform(e,0,0,e,0,0)};var he=[],ue=qt();se.setLocalTransform=function(t){if(t){var e=t[0]*t[0]+t[1]*t[1],n=t[2]*t[2]+t[3]*t[3],i=this.position,r=this.scale;ae(e-1)&&(e=Math.sqrt(e)),ae(n-1)&&(n=Math.sqrt(n)),t[0]<0&&(e=-e),t[3]<0&&(n=-n),i[0]=t[4],i[1]=t[5],r[0]=e,r[1]=n,this.rotation=Math.atan2(-t[1]/n,t[0]/e)}},se.decomposeTransform=function(){if(this.transform){var t=this.parent,e=this.transform;t&&t.transform&&(Qt(he,t.invTransform,e),e=he);var n=this.origin;n&&(n[0]||n[1])&&(ue[4]=n[0],ue[5]=n[1],Qt(he,e,ue),he[4]-=n[0],he[5]-=n[1],e=he),this.setLocalTransform(e)}},se.getGlobalScale=function(t){var e=this.transform;return t=t||[],e?(t[0]=Math.sqrt(e[0]*e[0]+e[1]*e[1]),t[1]=Math.sqrt(e[2]*e[2]+e[3]*e[3]),e[0]<0&&(t[0]=-t[0]),e[3]<0&&(t[1]=-t[1])):(t[0]=1,t[1]=1),t},se.transformCoordToLocal=function(t,e){var n=[t,e],i=this.invTransform;return i&&yt(n,n,i),n},se.transformCoordToGlobal=function(t,e){var n=[t,e],i=this.transform;return i&&yt(n,n,i),n},oe.getLocalTransform=function(t,e){re(e=e||[]);var n=t.origin,i=t.scale||[1,1],r=t.rotation||0,a=t.position||[0,0];return n&&(e[4]-=n[0],e[5]-=n[1]),ee(e,e,i),r&&te(e,e,r),n&&(e[4]+=n[0],e[5]+=n[1]),e[4]+=a[0],e[5]+=a[1],e};var ce={linear:function(t){return t},quadraticIn:function(t){return t*t},quadraticOut:function(t){return t*(2-t)},quadraticInOut:function(t){return(t*=2)<1?.5*t*t:-.5*(--t*(t-2)-1)},cubicIn:function(t){return t*t*t},cubicOut:function(t){return--t*t*t+1},cubicInOut:function(t){return(t*=2)<1?.5*t*t*t:.5*((t-=2)*t*t+2)},quarticIn:function(t){return t*t*t*t},quarticOut:function(t){return 1- --t*t*t*t},quarticInOut:function(t){return(t*=2)<1?.5*t*t*t*t:-.5*((t-=2)*t*t*t-2)},quinticIn:function(t){return t*t*t*t*t},quinticOut:function(t){return--t*t*t*t*t+1},quinticInOut:function(t){return(t*=2)<1?.5*t*t*t*t*t:.5*((t-=2)*t*t*t*t+2)},sinusoidalIn:function(t){return 1-Math.cos(t*Math.PI/2)},sinusoidalOut:function(t){return Math.sin(t*Math.PI/2)},sinusoidalInOut:function(t){return.5*(1-Math.cos(Math.PI*t))},exponentialIn:function(t){return 0===t?0:Math.pow(1024,t-1)},exponentialOut:function(t){return 1===t?1:1-Math.pow(2,-10*t)},exponentialInOut:function(t){return 0===t?0:1===t?1:(t*=2)<1?.5*Math.pow(1024,t-1):.5*(2-Math.pow(2,-10*(t-1)))},circularIn:function(t){return 1-Math.sqrt(1-t*t)},circularOut:function(t){return Math.sqrt(1- --t*t)},circularInOut:function(t){return(t*=2)<1?-.5*(Math.sqrt(1-t*t)-1):.5*(Math.sqrt(1-(t-=2)*t)+1)},elasticIn:function(t){var e,n=.1;return 0===t?0:1===t?1:(e=!n||n<1?(n=1,.1):.4*Math.asin(1/n)/(2*Math.PI),-n*Math.pow(2,10*(t-=1))*Math.sin((t-e)*(2*Math.PI)/.4))},elasticOut:function(t){var e,n=.1;return 0===t?0:1===t?1:(e=!n||n<1?(n=1,.1):.4*Math.asin(1/n)/(2*Math.PI),n*Math.pow(2,-10*t)*Math.sin((t-e)*(2*Math.PI)/.4)+1)},elasticInOut:function(t){var e,n=.1;return 0===t?0:1===t?1:(e=!n||n<1?(n=1,.1):.4*Math.asin(1/n)/(2*Math.PI),(t*=2)<1?n*Math.pow(2,10*(t-=1))*Math.sin((t-e)*(2*Math.PI)/.4)*-.5:n*Math.pow(2,-10*(t-=1))*Math.sin((t-e)*(2*Math.PI)/.4)*.5+1)},backIn:function(t){return t*t*(2.70158*t-1.70158)},backOut:function(t){return--t*t*(2.70158*t+1.70158)+1},backInOut:function(t){var e=2.5949095;return(t*=2)<1?t*t*((1+e)*t-e)*.5:.5*((t-=2)*t*((1+e)*t+e)+2)},bounceIn:function(t){return 1-ce.bounceOut(1-t)},bounceOut:function(t){return t<1/2.75?7.5625*t*t:t<2/2.75?7.5625*(t-=1.5/2.75)*t+.75:t<2.5/2.75?7.5625*(t-=2.25/2.75)*t+.9375:7.5625*(t-=2.625/2.75)*t+.984375},bounceInOut:function(t){return t<.5?.5*ce.bounceIn(2*t):.5*ce.bounceOut(2*t-1)+.5}};function de(t){this._target=t.target,this._life=t.life||1e3,this._delay=t.delay||0,this._initialized=!1,this.loop=null!=t.loop&&t.loop,this.gap=t.gap||0,this.easing=t.easing||"Linear",this.onframe=t.onframe,this.ondestroy=t.ondestroy,this.onrestart=t.onrestart,this._pausedTime=0,this._paused=!1}de.prototype={constructor:de,step:function(t,e){if(this._initialized||(this._startTime=t+this._delay,this._initialized=!0),this._paused)this._pausedTime+=e;else{var n=(t-this._startTime-this._pausedTime)/this._life;if(!(n<0)){n=Math.min(n,1);var i=this.easing,r="string"==typeof i?ce[i]:i,a="function"==typeof r?r(n):n;return this.fire("frame",a),1===n?this.loop?(this.restart(t),"restart"):(this._needsRemove=!0,"destroy"):null}}},restart:function(t){var e=(t-this._startTime-this._pausedTime)%this._life;this._startTime=t-e+this.gap,this._pausedTime=0,this._needsRemove=!1},fire:function(t,e){this[t="on"+t]&&this[t](this._target,e)},pause:function(){this._paused=!0},resume:function(){this._paused=!1}};function fe(){this.head=null,this.tail=null,this._len=0}var pe=fe.prototype;pe.insert=function(t){var e=new me(t);return this.insertEntry(e),e},pe.insertEntry=function(t){this.head?((this.tail.next=t).prev=this.tail,t.next=null,this.tail=t):this.head=this.tail=t,this._len++},pe.remove=function(t){var e=t.prev,n=t.next;e?e.next=n:this.head=n,n?n.prev=e:this.tail=e,t.next=t.prev=null,this._len--},pe.len=function(){return this._len},pe.clear=function(){this.head=this.tail=null,this._len=0};function ge(t){this._list=new fe,this._map={},this._maxSize=t||10,this._lastRemovedEntry=null}var me=function(t){this.value=t,this.next,this.prev},ve=ge.prototype;ve.put=function(t,e){var n=this._list,i=this._map,r=null;if(null==i[t]){var a=n.len(),o=this._lastRemovedEntry;if(a>=this._maxSize&&0<a){var s=n.head;n.remove(s),delete i[s.key],r=s.value,this._lastRemovedEntry=s}o?o.value=e:o=new me(e),o.key=t,n.insertEntry(o),i[t]=o}return r},ve.get=function(t){var e=this._map[t],n=this._list;if(null!=e)return e!==n.tail&&(n.remove(e),n.insertEntry(e)),e.value},ve.clear=function(){this._list.clear(),this._map={}};var ye={transparent:[0,0,0,0],aliceblue:[240,248,255,1],antiquewhite:[250,235,215,1],aqua:[0,255,255,1],aquamarine:[127,255,212,1],azure:[240,255,255,1],beige:[245,245,220,1],bisque:[255,228,196,1],black:[0,0,0,1],blanchedalmond:[255,235,205,1],blue:[0,0,255,1],blueviolet:[138,43,226,1],brown:[165,42,42,1],burlywood:[222,184,135,1],cadetblue:[95,158,160,1],chartreuse:[127,255,0,1],chocolate:[210,105,30,1],coral:[255,127,80,1],cornflowerblue:[100,149,237,1],cornsilk:[255,248,220,1],crimson:[220,20,60,1],cyan:[0,255,255,1],darkblue:[0,0,139,1],darkcyan:[0,139,139,1],darkgoldenrod:[184,134,11,1],darkgray:[169,169,169,1],darkgreen:[0,100,0,1],darkgrey:[169,169,169,1],darkkhaki:[189,183,107,1],darkmagenta:[139,0,139,1],darkolivegreen:[85,107,47,1],darkorange:[255,140,0,1],darkorchid:[153,50,204,1],darkred:[139,0,0,1],darksalmon:[233,150,122,1],darkseagreen:[143,188,143,1],darkslateblue:[72,61,139,1],darkslategray:[47,79,79,1],darkslategrey:[47,79,79,1],darkturquoise:[0,206,209,1],darkviolet:[148,0,211,1],deeppink:[255,20,147,1],deepskyblue:[0,191,255,1],dimgray:[105,105,105,1],dimgrey:[105,105,105,1],dodgerblue:[30,144,255,1],firebrick:[178,34,34,1],floralwhite:[255,250,240,1],forestgreen:[34,139,34,1],fuchsia:[255,0,255,1],gainsboro:[220,220,220,1],ghostwhite:[248,248,255,1],gold:[255,215,0,1],goldenrod:[218,165,32,1],gray:[128,128,128,1],green:[0,128,0,1],greenyellow:[173,255,47,1],grey:[128,128,128,1],honeydew:[240,255,240,1],hotpink:[255,105,180,1],indianred:[205,92,92,1],indigo:[75,0,130,1],ivory:[255,255,240,1],khaki:[240,230,140,1],lavender:[230,230,250,1],lavenderblush:[255,240,245,1],lawngreen:[124,252,0,1],lemonchiffon:[255,250,205,1],lightblue:[173,216,230,1],lightcoral:[240,128,128,1],lightcyan:[224,255,255,1],lightgoldenrodyellow:[250,250,210,1],lightgray:[211,211,211,1],lightgreen:[144,238,144,1],lightgrey:[211,211,211,1],lightpink:[255,182,193,1],lightsalmon:[255,160,122,1],lightseagreen:[32,178,170,1],lightskyblue:[135,206,250,1],lightslategray:[119,136,153,1],lightslategrey:[119,136,153,1],lightsteelblue:[176,196,222,1],lightyellow:[255,255,224,1],lime:[0,255,0,1],limegreen:[50,205,50,1],linen:[250,240,230,1],magenta:[255,0,255,1],maroon:[128,0,0,1],mediumaquamarine:[102,205,170,1],mediumblue:[0,0,205,1],mediumorchid:[186,85,211,1],mediumpurple:[147,112,219,1],mediumseagreen:[60,179,113,1],mediumslateblue:[123,104,238,1],mediumspringgreen:[0,250,154,1],mediumturquoise:[72,209,204,1],mediumvioletred:[199,21,133,1],midnightblue:[25,25,112,1],mintcream:[245,255,250,1],mistyrose:[255,228,225,1],moccasin:[255,228,181,1],navajowhite:[255,222,173,1],navy:[0,0,128,1],oldlace:[253,245,230,1],olive:[128,128,0,1],olivedrab:[107,142,35,1],orange:[255,165,0,1],orangered:[255,69,0,1],orchid:[218,112,214,1],palegoldenrod:[238,232,170,1],palegreen:[152,251,152,1],paleturquoise:[175,238,238,1],palevioletred:[219,112,147,1],papayawhip:[255,239,213,1],peachpuff:[255,218,185,1],peru:[205,133,63,1],pink:[255,192,203,1],plum:[221,160,221,1],powderblue:[176,224,230,1],purple:[128,0,128,1],red:[255,0,0,1],rosybrown:[188,143,143,1],royalblue:[65,105,225,1],saddlebrown:[139,69,19,1],salmon:[250,128,114,1],sandybrown:[244,164,96,1],seagreen:[46,139,87,1],seashell:[255,245,238,1],sienna:[160,82,45,1],silver:[192,192,192,1],skyblue:[135,206,235,1],slateblue:[106,90,205,1],slategray:[112,128,144,1],slategrey:[112,128,144,1],snow:[255,250,250,1],springgreen:[0,255,127,1],steelblue:[70,130,180,1],tan:[210,180,140,1],teal:[0,128,128,1],thistle:[216,191,216,1],tomato:[255,99,71,1],turquoise:[64,224,208,1],violet:[238,130,238,1],wheat:[245,222,179,1],white:[255,255,255,1],whitesmoke:[245,245,245,1],yellow:[255,255,0,1],yellowgreen:[154,205,50,1]};function _e(t){return(t=Math.round(t))<0?0:255<t?255:t}function xe(t){return t<0?0:1<t?1:t}function we(t){return t.length&&"%"===t.charAt(t.length-1)?_e(parseFloat(t)/100*255):_e(parseInt(t,10))}function be(t){return t.length&&"%"===t.charAt(t.length-1)?xe(parseFloat(t)/100):xe(parseFloat(t))}function Se(t,e,n){return n<0?n+=1:1<n&&(n-=1),6*n<1?t+(e-t)*n*6:2*n<1?e:3*n<2?t+(e-t)*(2/3-n)*6:t}function Me(t,e,n){return t+(e-t)*n}function Ie(t,e,n,i,r){return t[0]=e,t[1]=n,t[2]=i,t[3]=r,t}function Ce(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t}var Te=new ge(20),Ae=null;function De(t,e){Ae&&Ce(Ae,e),Ae=Te.put(t,Ae||e.slice())}function ke(t,e){if(t){e=e||[];var n=Te.get(t);if(n)return Ce(e,n);var i,r=(t+="").replace(/ /g,"").toLowerCase();if(r in ye)return Ce(e,ye[r]),De(t,e),e;if("#"===r.charAt(0))return 4===r.length?0<=(i=parseInt(r.substr(1),16))&&i<=4095?(Ie(e,(3840&i)>>4|(3840&i)>>8,240&i|(240&i)>>4,15&i|(15&i)<<4,1),De(t,e),e):void Ie(e,0,0,0,1):7===r.length?0<=(i=parseInt(r.substr(1),16))&&i<=16777215?(Ie(e,(16711680&i)>>16,(65280&i)>>8,255&i,1),De(t,e),e):void Ie(e,0,0,0,1):void 0;var a=r.indexOf("("),o=r.indexOf(")");if(-1!==a&&o+1===r.length){var s=r.substr(0,a),l=r.substr(a+1,o-(a+1)).split(","),h=1;switch(s){case"rgba":if(4!==l.length)return void Ie(e,0,0,0,1);h=be(l.pop());case"rgb":return 3!==l.length?void Ie(e,0,0,0,1):(Ie(e,we(l[0]),we(l[1]),we(l[2]),h),De(t,e),e);case"hsla":return 4!==l.length?void Ie(e,0,0,0,1):(l[3]=be(l[3]),Pe(l,e),De(t,e),e);case"hsl":return 3!==l.length?void Ie(e,0,0,0,1):(Pe(l,e),De(t,e),e);default:return}}Ie(e,0,0,0,1)}}function Pe(t,e){var n=(parseFloat(t[0])%360+360)%360/360,i=be(t[1]),r=be(t[2]),a=r<=.5?r*(i+1):r+i-r*i,o=2*r-a;return Ie(e=e||[],_e(255*Se(o,a,n+1/3)),_e(255*Se(o,a,n)),_e(255*Se(o,a,n-1/3)),1),4===t.length&&(e[3]=t[3]),e}function Le(t,e){var n=ke(t);if(n){for(var i=0;i<3;i++)n[i]=e<0?n[i]*(1-e)|0:(255-n[i])*e+n[i]|0,255<n[i]?n[i]=255:t[i]<0&&(n[i]=0);return Fe(n,4===n.length?"rgba":"rgb")}}function Oe(t){var e=ke(t);if(e)return((1<<24)+(e[0]<<16)+(e[1]<<8)+ +e[2]).toString(16).slice(1)}function ze(t,e,n){if(e&&e.length&&0<=t&&t<=1){n=n||[];var i=t*(e.length-1),r=Math.floor(i),a=Math.ceil(i),o=e[r],s=e[a],l=i-r;return n[0]=_e(Me(o[0],s[0],l)),n[1]=_e(Me(o[1],s[1],l)),n[2]=_e(Me(o[2],s[2],l)),n[3]=xe(Me(o[3],s[3],l)),n}}var Ee=ze;function Ne(t,e,n){if(e&&e.length&&0<=t&&t<=1){var i=t*(e.length-1),r=Math.floor(i),a=Math.ceil(i),o=ke(e[r]),s=ke(e[a]),l=i-r,h=Fe([_e(Me(o[0],s[0],l)),_e(Me(o[1],s[1],l)),_e(Me(o[2],s[2],l)),xe(Me(o[3],s[3],l))],"rgba");return n?{color:h,leftIndex:r,rightIndex:a,value:i}:h}}var Re=Ne;function Be(t,e){if((t=ke(t))&&null!=e)return t[3]=xe(e),Fe(t,"rgba")}function Fe(t,e){if(t&&t.length){var n=t[0]+","+t[1]+","+t[2];return"rgba"!==e&&"hsva"!==e&&"hsla"!==e||(n+=","+t[3]),e+"("+n+")"}}var Ve=(Object.freeze||Object)({parse:ke,lift:Le,toHex:Oe,fastLerp:ze,fastMapToColor:Ee,lerp:Ne,mapToColor:Re,modifyHSL:function(t,e,n,i){if(t=ke(t))return t=function(t){if(t){var e,n,i=t[0]/255,r=t[1]/255,a=t[2]/255,o=Math.min(i,r,a),s=Math.max(i,r,a),l=s-o,h=(s+o)/2;if(0==l)n=e=0;else{n=h<.5?l/(s+o):l/(2-s-o);var u=((s-i)/6+l/2)/l,c=((s-r)/6+l/2)/l,d=((s-a)/6+l/2)/l;i===s?e=d-c:r===s?e=1/3+u-d:a===s&&(e=2/3+c-u),e<0&&(e+=1),1<e&&(e-=1)}var f=[360*e,n,h];return null!=t[3]&&f.push(t[3]),f}}(t),null!=e&&(t[0]=function(t){return(t=Math.round(t))<0?0:360<t?360:t}(e)),null!=n&&(t[1]=be(n)),null!=i&&(t[2]=be(i)),Fe(Pe(t),"rgba")},modifyAlpha:Be,stringify:Fe}),He=Array.prototype.slice;function We(t,e){return t[e]}function Ge(t,e,n){t[e]=n}function Ze(t,e,n){return(e-t)*n+t}function Ue(t,e,n){return.5<n?e:t}function Xe(t,e,n,i,r){var a=t.length;if(1===r)for(var o=0;o<a;o++)i[o]=Ze(t[o],e[o],n);else{var s=a&&t[0].length;for(o=0;o<a;o++)for(var l=0;l<s;l++)i[o][l]=Ze(t[o][l],e[o][l],n)}}function Ye(t,e,n){var i=t.length,r=e.length;if(i!==r)if(r<i)t.length=r;else for(var a=i;a<r;a++)t.push(1===n?e[a]:He.call(e[a]));var o=t[0]&&t[0].length;for(a=0;a<t.length;a++)if(1===n)isNaN(t[a])&&(t[a]=e[a]);else for(var s=0;s<o;s++)isNaN(t[a][s])&&(t[a][s]=e[a][s])}function je(t,e,n){if(t===e)return!0;var i=t.length;if(i!==e.length)return!1;if(1===n){for(var r=0;r<i;r++)if(t[r]!==e[r])return!1}else{var a=t[0].length;for(r=0;r<i;r++)for(var o=0;o<a;o++)if(t[r][o]!==e[r][o])return!1}return!0}function qe(t,e,n,i,r,a,o,s,l){var h=t.length;if(1===l)for(var u=0;u<h;u++)s[u]=$e(t[u],e[u],n[u],i[u],r,a,o);else{var c=t[0].length;for(u=0;u<h;u++)for(var d=0;d<c;d++)s[u][d]=$e(t[u][d],e[u][d],n[u][d],i[u][d],r,a,o)}}function $e(t,e,n,i,r,a,o){var s=.5*(n-t),l=.5*(i-e);return(2*(e-n)+s+l)*o+(-3*(e-n)-2*s-l)*a+s*r+e}function Ke(t){if(L(t)){var e=t.length;if(L(t[0])){for(var n=[],i=0;i<e;i++)n.push(He.call(t[i]));return n}return He.call(t)}return t}function Qe(t){return t[0]=Math.floor(t[0]),t[1]=Math.floor(t[1]),t[2]=Math.floor(t[2]),"rgba("+t.join(",")+")"}function Je(t,e,n,i,a,r){var o=t._getter,s=t._setter,l="spline"===e,h=i.length;if(h){var u,c=L(i[0].value),d=!1,f=!1,p=c?function(t){var e=t[t.length-1].value;return L(e&&e[0])?2:1}(i):0;i.sort(function(t,e){return t.time-e.time}),u=i[h-1].time;for(var g=[],m=[],v=i[0].value,y=!0,_=0;_<h;_++){g.push(i[_].time/u);var x=i[_].value;if(c&&je(x,v,p)||!c&&x===v||(y=!1),"string"==typeof(v=x)){var w=ke(x);w?(x=w,d=!0):f=!0}m.push(x)}if(r||!y){var b=m[h-1];for(_=0;_<h-1;_++)c?Ye(m[_],b,p):!isNaN(m[_])||isNaN(b)||f||d||(m[_]=b);c&&Ye(o(t._target,a),b,p);var S,M,I,C,T,A=0,D=0;if(d)var k=[0,0,0,0];var P=new de({target:t._target,life:u,loop:t._loop,delay:t._delay,onframe:function(t,e){var n;if(e<0)n=0;else if(e<D){for(n=Math.min(A+1,h-1);0<=n&&!(g[n]<=e);n--);n=Math.min(n,h-2)}else{for(n=A;n<h&&!(g[n]>e);n++);n=Math.min(n-1,h-2)}D=e;var i=g[(A=n)+1]-g[n];if(0!=i)if(S=(e-g[n])/i,l)if(I=m[n],M=m[0===n?n:n-1],C=m[h-2<n?h-1:n+1],T=m[h-3<n?h-1:n+2],c)qe(M,I,C,T,S,S*S,S*S*S,o(t,a),p);else{if(d)r=qe(M,I,C,T,S,S*S,S*S*S,k,1),r=Qe(k);else{if(f)return Ue(I,C,S);r=$e(M,I,C,T,S,S*S,S*S*S)}s(t,a,r)}else if(c)Xe(m[n],m[n+1],S,o(t,a),p);else{var r;if(d)Xe(m[n],m[n+1],S,k,1),r=Qe(k);else{if(f)return Ue(m[n],m[n+1],S);r=Ze(m[n],m[n+1],S)}s(t,a,r)}},ondestroy:n});return e&&"spline"!==e&&(P.easing=e),P}}}function tn(t,e,n,i){this._tracks={},this._target=t,this._loop=e||!1,this._getter=n||We,this._setter=i||Ge,this._clipCount=0,this._delay=0,this._doneList=[],this._onframeList=[],this._clipList=[]}tn.prototype={when:function(t,e){var n=this._tracks;for(var i in e)if(e.hasOwnProperty(i)){if(!n[i]){n[i]=[];var r=this._getter(this._target,i);if(null==r)continue;0!==t&&n[i].push({time:0,value:Ke(r)})}n[i].push({time:t,value:e[i]})}return this},during:function(t){return this._onframeList.push(t),this},pause:function(){for(var t=0;t<this._clipList.length;t++)this._clipList[t].pause();this._paused=!0},resume:function(){for(var t=0;t<this._clipList.length;t++)this._clipList[t].resume();this._paused=!1},isPaused:function(){return!!this._paused},_doneCallback:function(){this._tracks={},this._clipList.length=0;for(var t=this._doneList,e=t.length,n=0;n<e;n++)t[n].call(this)},start:function(t,e){function n(){--a||r._doneCallback()}var i,r=this,a=0;for(var o in this._tracks)if(this._tracks.hasOwnProperty(o)){var s=Je(this,t,n,this._tracks[o],o,e);s&&(this._clipList.push(s),a++,this.animation&&this.animation.addClip(s),i=s)}if(i){var l=i.onframe;i.onframe=function(t,e){l(t,e);for(var n=0;n<r._onframeList.length;n++)r._onframeList[n](t,e)}}return a||this._doneCallback(),this},stop:function(t){for(var e=this._clipList,n=this.animation,i=0;i<e.length;i++){var r=e[i];t&&r.onframe(this._target,1),n&&n.removeClip(r)}e.length=0},delay:function(t){return this._delay=t,this},done:function(t){return t&&this._doneList.push(t),this},getClips:function(){return this._clipList}};var en=1;"undefined"!=typeof window&&(en=Math.max(window.devicePixelRatio||1,1));var nn=en,rn=function(){};function an(){this.animators=[]}var on=rn;function sn(t,e,n,i,r,a,o,s){E(i)?(a=r,r=i,i=0):z(r)?(a=r,r="linear",i=0):z(i)?(a=i,i=0):n=z(n)?(a=n,500):n||500,t.stopAnimation(),function t(e,n,i,r,a,o,s){var l={};var h=0;for(var u in r)r.hasOwnProperty(u)&&(null!=i[u]?N(r[u])&&!L(r[u])?t(e,n?n+"."+u:u,i[u],r[u],a,o,s):(s?(l[u]=i[u],ln(e,n,u,r[u])):l[u]=r[u],h++):null==r[u]||s||ln(e,n,u,r[u]));0<h&&e.animate(n,!1).when(null==a?500:a,l).delay(o||0)}(t,"",t,e,n,i,s);var l=t.animators.slice(),h=l.length;function u(){--h||a&&a()}h||a&&a();for(var c=0;c<l.length;c++)l[c].done(u).start(r,o)}function ln(t,e,n,i){if(e){var r={};r[e]={},r[e][n]=i,t.attr(r)}else t.attr(n,i)}an.prototype={constructor:an,animate:function(t,e){var n,i=!1,r=this,a=this.__zr;if(t){var o=t.split("."),s=r;i="shape"===o[0];for(var l=0,h=o.length;l<h;l++)s=s&&s[o[l]];s&&(n=s)}else n=r;if(n){var u=r.animators,c=new tn(n,e);return c.during(function(t){r.dirty(i)}).done(function(){u.splice(x(u,c),1)}),u.push(c),a&&a.animation.addAnimator(c),c}on('Property "'+t+'" is not existed in element '+r.id)},stopAnimation:function(t){for(var e=this.animators,n=e.length,i=0;i<n;i++)e[i].stop(t);return e.length=0,this},animateTo:function(t,e,n,i,r,a){sn(this,t,e,n,i,r,a)},animateFrom:function(t,e,n,i,r,a){sn(this,t,e,n,i,r,a,!0)}};var hn=function(t){oe.call(this,t),It.call(this,t),an.call(this,t),this.id=t.id||i()};hn.prototype={type:"element",name:"",__zr:null,ignore:!1,clipPath:null,isGroup:!1,drift:function(t,e){switch(this.draggable){case"horizontal":e=0;break;case"vertical":t=0}var n=this.transform;(n=n||(this.transform=[1,0,0,1,0,0]))[4]+=t,n[5]+=e,this.decomposeTransform(),this.dirty(!1)},beforeUpdate:function(){},afterUpdate:function(){},update:function(){this.updateTransform()},traverse:function(t,e){},attrKV:function(t,e){if("position"===t||"scale"===t||"origin"===t){if(e){var n=this[t];(n=n||(this[t]=[]))[0]=e[0],n[1]=e[1]}}else this[t]=e},hide:function(){this.ignore=!0,this.__zr&&this.__zr.refresh()},show:function(){this.ignore=!1,this.__zr&&this.__zr.refresh()},attr:function(t,e){if("string"==typeof t)this.attrKV(t,e);else if(N(t))for(var n in t)t.hasOwnProperty(n)&&this.attrKV(n,t[n]);return this.dirty(!1),this},setClipPath:function(t){var e=this.__zr;e&&t.addSelfToZr(e),this.clipPath&&this.clipPath!==t&&this.removeClipPath(),(this.clipPath=t).__zr=e,(t.__clipTarget=this).dirty(!1)},removeClipPath:function(){var t=this.clipPath;t&&(t.__zr&&t.removeSelfFromZr(t.__zr),t.__zr=null,t.__clipTarget=null,this.clipPath=null,this.dirty(!1))},addSelfToZr:function(t){this.__zr=t;var e=this.animators;if(e)for(var n=0;n<e.length;n++)t.animation.addAnimator(e[n]);this.clipPath&&this.clipPath.addSelfToZr(t)},removeSelfFromZr:function(t){this.__zr=null;var e=this.animators;if(e)for(var n=0;n<e.length;n++)t.animation.removeAnimator(e[n]);this.clipPath&&this.clipPath.removeSelfFromZr(t)}},S(hn,an),S(hn,oe),S(hn,It);var un,cn,dn,fn,pn=yt,gn=Math.min,mn=Math.max;function vn(t,e,n,i){n<0&&(t+=n,n=-n),i<0&&(e+=i,i=-i),this.x=t,this.y=e,this.width=n,this.height=i}vn.prototype={constructor:vn,union:function(t){var e=gn(t.x,this.x),n=gn(t.y,this.y);this.width=mn(t.x+t.width,this.x+this.width)-e,this.height=mn(t.y+t.height,this.y+this.height)-n,this.x=e,this.y=n},applyTransform:(un=[],cn=[],dn=[],fn=[],function(t){if(t){un[0]=dn[0]=this.x,un[1]=fn[1]=this.y,cn[0]=fn[0]=this.x+this.width,cn[1]=dn[1]=this.y+this.height,pn(un,un,t),pn(cn,cn,t),pn(dn,dn,t),pn(fn,fn,t),this.x=gn(un[0],cn[0],dn[0],fn[0]),this.y=gn(un[1],cn[1],dn[1],fn[1]);var e=mn(un[0],cn[0],dn[0],fn[0]),n=mn(un[1],cn[1],dn[1],fn[1]);this.width=e-this.x,this.height=n-this.y}}),calculateTransform:function(t){var e=t.width/this.width,n=t.height/this.height,i=qt();return Jt(i,i,[-this.x,-this.y]),ee(i,i,[e,n]),Jt(i,i,[t.x,t.y]),i},intersect:function(t){if(!t)return!1;t instanceof vn||(t=vn.create(t));var e=this,n=e.x,i=e.x+e.width,r=e.y,a=e.y+e.height,o=t.x,s=t.x+t.width,l=t.y,h=t.y+t.height;return!(i<o||s<n||a<l||h<r)},contain:function(t,e){var n=this;return t>=n.x&&t<=n.x+n.width&&e>=n.y&&e<=n.y+n.height},clone:function(){return new vn(this.x,this.y,this.width,this.height)},copy:function(t){this.x=t.x,this.y=t.y,this.width=t.width,this.height=t.height},plain:function(){return{x:this.x,y:this.y,width:this.width,height:this.height}}},vn.create=function(t){return new vn(t.x,t.y,t.width,t.height)};var yn=function(t){for(var e in t=t||{},hn.call(this,t),t)t.hasOwnProperty(e)&&(this[e]=t[e]);this._children=[],this.__storage=null,this.__dirty=!0};yn.prototype={constructor:yn,isGroup:!0,type:"group",silent:!1,children:function(){return this._children.slice()},childAt:function(t){return this._children[t]},childOfName:function(t){for(var e=this._children,n=0;n<e.length;n++)if(e[n].name===t)return e[n]},childCount:function(){return this._children.length},add:function(t){return t&&t!==this&&t.parent!==this&&(this._children.push(t),this._doAdd(t)),this},addBefore:function(t,e){if(t&&t!==this&&t.parent!==this&&e&&e.parent===this){var n=this._children,i=n.indexOf(e);0<=i&&(n.splice(i,0,t),this._doAdd(t))}return this},_doAdd:function(t){t.parent&&t.parent.remove(t);var e=(t.parent=this).__storage,n=this.__zr;e&&e!==t.__storage&&(e.addToStorage(t),t instanceof yn&&t.addChildrenToStorage(e)),n&&n.refresh()},remove:function(t){var e=this.__zr,n=this.__storage,i=this._children,r=x(i,t);return r<0||(i.splice(r,1),t.parent=null,n&&(n.delFromStorage(t),t instanceof yn&&t.delChildrenFromStorage(n)),e&&e.refresh()),this},removeAll:function(){var t,e,n=this._children,i=this.__storage;for(e=0;e<n.length;e++)t=n[e],i&&(i.delFromStorage(t),t instanceof yn&&t.delChildrenFromStorage(i)),t.parent=null;return n.length=0,this},eachChild:function(t,e){for(var n=this._children,i=0;i<n.length;i++){var r=n[i];t.call(e,r,i)}return this},traverse:function(t,e){for(var n=0;n<this._children.length;n++){var i=this._children[n];t.call(e,i),"group"===i.type&&i.traverse(t,e)}return this},addChildrenToStorage:function(t){for(var e=0;e<this._children.length;e++){var n=this._children[e];t.addToStorage(n),n instanceof yn&&n.addChildrenToStorage(t)}},delChildrenFromStorage:function(t){for(var e=0;e<this._children.length;e++){var n=this._children[e];t.delFromStorage(n),n instanceof yn&&n.delChildrenFromStorage(t)}},dirty:function(){return this.__dirty=!0,this.__zr&&this.__zr.refresh(),this},getBoundingRect:function(t){for(var e=null,n=new vn(0,0,0,0),i=t||this._children,r=[],a=0;a<i.length;a++){var o=i[a];if(!o.ignore&&!o.invisible){var s=o.getBoundingRect(),l=o.getLocalTransform(r);l?(n.copy(s),n.applyTransform(l),(e=e||n.clone()).union(n)):(e=e||s.clone()).union(s)}}return e||n}},w(yn,hn);var _n=32,xn=7;function wn(t,e,n,i){var r=e+1;if(r===n)return 1;if(i(t[r++],t[e])<0){for(;r<n&&i(t[r],t[r-1])<0;)r++;!function(t,e,n){n--;for(;e<n;){var i=t[e];t[e++]=t[n],t[n--]=i}}(t,e,r)}else for(;r<n&&0<=i(t[r],t[r-1]);)r++;return r-e}function bn(t,e,n,i,r){for(i===e&&i++;i<n;i++){for(var a,o=t[i],s=e,l=i;s<l;)r(o,t[a=s+l>>>1])<0?l=a:s=1+a;var h=i-s;switch(h){case 3:t[s+3]=t[s+2];case 2:t[s+2]=t[s+1];case 1:t[s+1]=t[s];break;default:for(;0<h;)t[s+h]=t[s+h-1],h--}t[s]=o}}function Sn(t,e,n,i,r,a){var o=0,s=0,l=1;if(0<a(t,e[n+r])){for(s=i-r;l<s&&0<a(t,e[n+r+l]);)(l=1+((o=l)<<1))<=0&&(l=s);s<l&&(l=s),o+=r,l+=r}else{for(s=r+1;l<s&&a(t,e[n+r-l])<=0;)(l=1+((o=l)<<1))<=0&&(l=s);s<l&&(l=s);var h=o;o=r-l,l=r-h}for(o++;o<l;){var u=o+(l-o>>>1);0<a(t,e[n+u])?o=u+1:l=u}return l}function Mn(t,e,n,i,r,a){var o=0,s=0,l=1;if(a(t,e[n+r])<0){for(s=r+1;l<s&&a(t,e[n+r-l])<0;)(l=1+((o=l)<<1))<=0&&(l=s);s<l&&(l=s);var h=o;o=r-l,l=r-h}else{for(s=i-r;l<s&&0<=a(t,e[n+r+l]);)(l=1+((o=l)<<1))<=0&&(l=s);s<l&&(l=s),o+=r,l+=r}for(o++;o<l;){var u=o+(l-o>>>1);a(t,e[n+u])<0?l=u:o=u+1}return l}function In(p,g){var o,s,m=xn,l=0,v=[];function e(t){var e=o[t],n=s[t],i=o[t+1],r=s[t+1];s[t]=n+r,t===l-3&&(o[t+1]=o[t+2],s[t+1]=s[t+2]),l--;var a=Mn(p[i],p,e,n,0,g);e+=a,0!==(n-=a)&&0!==(r=Sn(p[e+n-1],p,i,r,r-1,g))&&(n<=r?function(t,e,n,i){var r=0;for(r=0;r<e;r++)v[r]=p[t+r];var a=0,o=n,s=t;if(p[s++]=p[o++],0==--i){for(r=0;r<e;r++)p[s+r]=v[a+r];return}if(1===e){for(r=0;r<i;r++)p[s+r]=p[o+r];return p[s+i]=v[a]}var l,h,u,c=m;for(;;){h=l=0,u=!1;do{if(g(p[o],v[a])<0){if(p[s++]=p[o++],h++,(l=0)==--i){u=!0;break}}else if(p[s++]=v[a++],l++,h=0,1==--e){u=!0;break}}while((l|h)<c);if(u)break;do{if(0!==(l=Mn(p[o],v,a,e,0,g))){for(r=0;r<l;r++)p[s+r]=v[a+r];if(s+=l,a+=l,(e-=l)<=1){u=!0;break}}if(p[s++]=p[o++],0==--i){u=!0;break}if(0!==(h=Sn(v[a],p,o,i,0,g))){for(r=0;r<h;r++)p[s+r]=p[o+r];if(s+=h,o+=h,0===(i-=h)){u=!0;break}}if(p[s++]=v[a++],1==--e){u=!0;break}c--}while(xn<=l||xn<=h);if(u)break;c<0&&(c=0),c+=2}if((m=c)<1&&(m=1),1===e){for(r=0;r<i;r++)p[s+r]=p[o+r];p[s+i]=v[a]}else{if(0===e)throw new Error;for(r=0;r<e;r++)p[s+r]=v[a+r]}}(e,n,i,r):function(t,e,n,i){var r=0;for(r=0;r<i;r++)v[r]=p[n+r];var a=t+e-1,o=i-1,s=n+i-1,l=0,h=0;if(p[s--]=p[a--],0==--e){for(l=s-(i-1),r=0;r<i;r++)p[l+r]=v[r];return}if(1===i){for(h=(s-=e)+1,l=(a-=e)+1,r=e-1;0<=r;r--)p[h+r]=p[l+r];return p[s]=v[o]}var u=m;for(;;){var c=0,d=0,f=!1;do{if(g(v[o],p[a])<0){if(p[s--]=p[a--],c++,(d=0)==--e){f=!0;break}}else if(p[s--]=v[o--],d++,c=0,1==--i){f=!0;break}}while((c|d)<u);if(f)break;do{if(0!==(c=e-Mn(v[o],p,t,e,e-1,g))){for(e-=c,h=(s-=c)+1,l=(a-=c)+1,r=c-1;0<=r;r--)p[h+r]=p[l+r];if(0===e){f=!0;break}}if(p[s--]=v[o--],1==--i){f=!0;break}if(0!==(d=i-Sn(p[a],v,0,i,i-1,g))){for(i-=d,h=(s-=d)+1,l=(o-=d)+1,r=0;r<d;r++)p[h+r]=v[l+r];if(i<=1){f=!0;break}}if(p[s--]=p[a--],0==--e){f=!0;break}u--}while(xn<=c||xn<=d);if(f)break;u<0&&(u=0),u+=2}(m=u)<1&&(m=1);if(1===i){for(h=(s-=e)+1,l=(a-=e)+1,r=e-1;0<=r;r--)p[h+r]=p[l+r];p[s]=v[o]}else{if(0===i)throw new Error;for(l=s-(i-1),r=0;r<i;r++)p[l+r]=v[r]}}(e,n,i,r))}o=[],s=[],this.mergeRuns=function(){for(;1<l;){var t=l-2;if(1<=t&&s[t-1]<=s[t]+s[t+1]||2<=t&&s[t-2]<=s[t]+s[t-1])s[t-1]<s[t+1]&&t--;else if(s[t]>s[t+1])break;e(t)}},this.forceMergeRuns=function(){for(;1<l;){var t=l-2;0<t&&s[t-1]<s[t+1]&&t--,e(t)}},this.pushRun=function(t,e){o[l]=t,s[l]=e,l+=1}}function Cn(t,e,n,i){n=n||0;var r=(i=i||t.length)-n;if(!(r<2)){var a=0;if(r<_n)bn(t,n,i,n+(a=wn(t,n,i,e)),e);else{var o=new In(t,e),s=function(t){for(var e=0;_n<=t;)e|=1&t,t>>=1;return t+e}(r);do{if((a=wn(t,n,i,e))<s){var l=r;s<l&&(l=s),bn(t,n,n+l,n+a,e),a=l}o.pushRun(n,a),o.mergeRuns(),r-=a,n+=a}while(0!==r);o.forceMergeRuns()}}}function Tn(t,e){return t.zlevel===e.zlevel?t.z===e.z?t.z2-e.z2:t.z-e.z:t.zlevel-e.zlevel}function An(){this._roots=[],this._displayList=[],this._displayListLen=0}An.prototype={constructor:An,traverse:function(t,e){for(var n=0;n<this._roots.length;n++)this._roots[n].traverse(t,e)},getDisplayList:function(t,e){return e=e||!1,t&&this.updateDisplayList(e),this._displayList},updateDisplayList:function(t){this._displayListLen=0;for(var e=this._roots,n=this._displayList,i=0,r=e.length;i<r;i++)this._updateAndAddDisplayable(e[i],null,t);n.length=this._displayListLen,v.canvasSupported&&Cn(n,Tn)},_updateAndAddDisplayable:function(t,e,n){if(!t.ignore||n){t.beforeUpdate(),t.__dirty&&t.update(),t.afterUpdate();var i=t.clipPath;if(i){e=e?e.slice():[];for(var r=i,a=t;r;)r.parent=a,r.updateTransform(),e.push(r),r=(a=r).clipPath}if(t.isGroup){for(var o=t._children,s=0;s<o.length;s++){var l=o[s];t.__dirty&&(l.__dirty=!0),this._updateAndAddDisplayable(l,e,n)}t.__dirty=!1}else t.__clipPaths=e,this._displayList[this._displayListLen++]=t}},addRoot:function(t){t.__storage!==this&&(t instanceof yn&&t.addChildrenToStorage(this),this.addToStorage(t),this._roots.push(t))},delRoot:function(t){if(null==t){for(var e=0;e<this._roots.length;e++){var n=this._roots[e];n instanceof yn&&n.delChildrenFromStorage(this)}return this._roots=[],this._displayList=[],void(this._displayListLen=0)}if(t instanceof Array){e=0;for(var i=t.length;e<i;e++)this.delRoot(t[e])}else{var r=x(this._roots,t);0<=r&&(this.delFromStorage(t),this._roots.splice(r,1),t instanceof yn&&t.delChildrenFromStorage(this))}},addToStorage:function(t){return t&&(t.__storage=this,t.dirty(!1)),this},delFromStorage:function(t){return t&&(t.__storage=null),this},dispose:function(){this._renderList=this._roots=null},displayableSortFunc:Tn};var Dn={shadowBlur:1,shadowOffsetX:1,shadowOffsetY:1,textShadowBlur:1,textShadowOffsetX:1,textShadowOffsetY:1,textBoxShadowBlur:1,textBoxShadowOffsetX:1,textBoxShadowOffsetY:1},kn=function(t,e,n){return Dn.hasOwnProperty(e)?n*t.dpr:n},Pn={NONE:0,STYLE_BIND:1,PLAIN_TEXT:2},Ln=9,On=[["shadowBlur",0],["shadowOffsetX",0],["shadowOffsetY",0],["shadowColor","#000"],["lineCap","butt"],["lineJoin","miter"],["miterLimit",10]],zn=function(t){this.extendFrom(t,!1)};function En(t,e,n){var i=null==e.x?0:e.x,r=null==e.x2?1:e.x2,a=null==e.y?0:e.y,o=null==e.y2?0:e.y2;return e.global||(i=i*n.width+n.x,r=r*n.width+n.x,a=a*n.height+n.y,o=o*n.height+n.y),i=isNaN(i)?0:i,r=isNaN(r)?1:r,a=isNaN(a)?0:a,o=isNaN(o)?0:o,t.createLinearGradient(i,a,r,o)}function Nn(t,e,n){var i=n.width,r=n.height,a=Math.min(i,r),o=null==e.x?.5:e.x,s=null==e.y?.5:e.y,l=null==e.r?.5:e.r;return e.global||(o=o*i+n.x,s=s*r+n.y,l*=a),t.createRadialGradient(o,s,0,o,s,l)}zn.prototype={constructor:zn,fill:"#000",stroke:null,opacity:1,fillOpacity:null,strokeOpacity:null,lineDash:null,lineDashOffset:0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,lineWidth:1,strokeNoScale:!1,text:null,font:null,textFont:null,fontStyle:null,fontWeight:null,fontSize:null,fontFamily:null,textTag:null,textFill:"#000",textStroke:null,textWidth:null,textHeight:null,textStrokeWidth:0,textLineHeight:null,textPosition:"inside",textRect:null,textOffset:null,textAlign:null,textVerticalAlign:null,textDistance:5,textShadowColor:"transparent",textShadowBlur:0,textShadowOffsetX:0,textShadowOffsetY:0,textBoxShadowColor:"transparent",textBoxShadowBlur:0,textBoxShadowOffsetX:0,textBoxShadowOffsetY:0,transformText:!1,textRotation:0,textOrigin:null,textBackgroundColor:null,textBorderColor:null,textBorderWidth:0,textBorderRadius:0,textPadding:null,rich:null,truncate:null,blend:null,bind:function(t,e,n){var i=this,r=n&&n.style,a=!r||t.__attrCachedBy!==Pn.STYLE_BIND;t.__attrCachedBy=Pn.STYLE_BIND;for(var o=0;o<On.length;o++){var s=On[o],l=s[0];!a&&i[l]===r[l]||(t[l]=kn(t,l,i[l]||s[1]))}if(!a&&i.fill===r.fill||(t.fillStyle=i.fill),!a&&i.stroke===r.stroke||(t.strokeStyle=i.stroke),!a&&i.opacity===r.opacity||(t.globalAlpha=null==i.opacity?1:i.opacity),!a&&i.blend===r.blend||(t.globalCompositeOperation=i.blend||"source-over"),this.hasStroke()){var h=i.lineWidth;t.lineWidth=h/(this.strokeNoScale&&e&&e.getLineScale?e.getLineScale():1)}},hasFill:function(){var t=this.fill;return null!=t&&"none"!==t},hasStroke:function(){var t=this.stroke;return null!=t&&"none"!==t&&0<this.lineWidth},extendFrom:function(t,e){if(t)for(var n in t)!t.hasOwnProperty(n)||!0!==e&&(!1===e?this.hasOwnProperty(n):null==t[n])||(this[n]=t[n])},set:function(t,e){"string"==typeof t?this[t]=e:this.extendFrom(t,!0)},clone:function(){var t=new this.constructor;return t.extendFrom(this,!0),t},getGradient:function(t,e,n){for(var i=("radial"===e.type?Nn:En)(t,e,n),r=e.colorStops,a=0;a<r.length;a++)i.addColorStop(r[a].offset,r[a].color);return i}};for(var Rn=zn.prototype,Bn=0;Bn<On.length;Bn++){var Fn=On[Bn];Fn[0]in Rn||(Rn[Fn[0]]=Fn[1])}zn.getGradient=Rn.getGradient;function Vn(t,e){this.image=t,this.repeat=e,this.type="pattern"}function Hn(){return!1}function Wn(t,e,n){var i=g(),r=e.getWidth(),a=e.getHeight(),o=i.style;return o&&(o.position="absolute",o.left=0,o.top=0,o.width=r+"px",o.height=a+"px",i.setAttribute("data-zr-dom-id",t)),i.width=r*n,i.height=a*n,i}function Gn(t,e,n){var i;n=n||nn,"string"==typeof t?i=Wn(t,e,n):N(t)&&(t=(i=t).id),this.id=t;var r=(this.dom=i).style;r&&(i.onselectstart=Hn,r["-webkit-user-select"]="none",r["user-select"]="none",r["-webkit-touch-callout"]="none",r["-webkit-tap-highlight-color"]="rgba(0,0,0,0)",r.padding=0,r.margin=0,r["border-width"]=0),this.domBack=null,this.ctxBack=null,this.painter=e,this.config=null,this.clearColor=0,this.motionBlur=!1,this.lastFrameAlpha=.7,this.dpr=n}Gn.prototype={constructor:Gn,__dirty:!0,__used:!(Vn.prototype.getCanvasPattern=function(t){return t.createPattern(this.image,this.repeat||"repeat")}),__drawIndex:0,__startIndex:0,__endIndex:0,incremental:!1,getElementCount:function(){return this.__endIndex-this.__startIndex},initContext:function(){this.ctx=this.dom.getContext("2d"),this.ctx.dpr=this.dpr},createBackBuffer:function(){var t=this.dpr;this.domBack=Wn("back-"+this.id,this.painter,t),this.ctxBack=this.domBack.getContext("2d"),1!==t&&this.ctxBack.scale(t,t)},resize:function(t,e){var n=this.dpr,i=this.dom,r=i.style,a=this.domBack;r&&(r.width=t+"px",r.height=e+"px"),i.width=t*n,i.height=e*n,a&&(a.width=t*n,a.height=e*n,1!==n&&this.ctxBack.scale(n,n))},clear:function(t,e){var n,i=this.dom,r=this.ctx,a=i.width,o=i.height,s=(e=e||this.clearColor,this.motionBlur&&!t),l=this.lastFrameAlpha,h=this.dpr;s&&(this.domBack||this.createBackBuffer(),this.ctxBack.globalCompositeOperation="copy",this.ctxBack.drawImage(i,0,0,a/h,o/h)),r.clearRect(0,0,a,o),e&&"transparent"!==e&&(e.colorStops?(n=e.__canvasGradient||zn.getGradient(r,e,{x:0,y:0,width:a,height:o}),e.__canvasGradient=n):e.image&&(n=Vn.prototype.getCanvasPattern.call(e,r)),r.save(),r.fillStyle=n||e,r.fillRect(0,0,a,o),r.restore());if(s){var u=this.domBack;r.save(),r.globalAlpha=l,r.drawImage(u,0,0,a,o),r.restore()}}};var Zn="undefined"!=typeof window&&(window.requestAnimationFrame&&window.requestAnimationFrame.bind(window)||window.msRequestAnimationFrame&&window.msRequestAnimationFrame.bind(window)||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame)||function(t){setTimeout(t,16)},Un=new ge(50);function Xn(t){if("string"!=typeof t)return t;var e=Un.get(t);return e&&e.image}function Yn(t,e,n,i,r){if(t){if("string"!=typeof t)return t;if(e&&e.__zrImageSrc===t||!n)return e;var a=Un.get(t),o={hostEl:n,cb:i,cbPayload:r};return a?qn(e=a.image)||a.pending.push(o):((e=new Image).onload=e.onerror=jn,Un.put(t,e.__cachedImgObj={image:e,pending:[o]}),e.src=e.__zrImageSrc=t),e}return e}function jn(){var t=this.__cachedImgObj;this.onload=this.onerror=this.__cachedImgObj=null;for(var e=0;e<t.pending.length;e++){var n=t.pending[e],i=n.cb;i&&i(this,n.cbPayload),n.hostEl.dirty()}t.pending.length=0}function qn(t){return t&&t.width&&t.height}var $n={},Kn=0,Qn=5e3,Jn=/\{([a-zA-Z0-9_]+)\|([^}]*)\}/g,ti="12px sans-serif",ei={};function ni(t,e){var n=t+":"+(e=e||ti);if($n[n])return $n[n];for(var i,r,a=(t+"").split("\n"),o=0,s=0,l=a.length;s<l;s++)o=Math.max((i=a[s],r=e,ei.measureText(i,r)).width,o);return Qn<Kn&&(Kn=0,$n={}),Kn++,$n[n]=o}function ii(t,e,n,i,r,a,o,s){return o?function(t,e,n,i,r,a,o,s){var l=fi(t,{rich:o,truncate:s,font:e,textAlign:n,textPadding:r,textLineHeight:a}),h=l.outerWidth,u=l.outerHeight,c=ri(0,h,n),d=ai(0,u,i);return new vn(c,d,h,u)}(t,e,n,i,r,a,o,s):function(t,e,n,i,r,a,o){var s=di(t,e,r,a,o),l=ni(t,e);r&&(l+=r[1]+r[3]);var h=s.outerHeight,u=ri(0,l,n),c=ai(0,h,i),d=new vn(u,c,l,h);return d.lineHeight=s.lineHeight,d}(t,e,n,i,r,a,s)}function ri(t,e,n){return"right"===n?t-=e:"center"===n&&(t-=e/2),t}function ai(t,e,n){return"middle"===n?t-=e/2:"bottom"===n&&(t-=e),t}function oi(t,e,n){var i=e.textPosition,r=e.textDistance,a=n.x,o=n.y,s=n.height,l=n.width,h=s/2,u="left",c="top";switch(i){case"left":a-=r,o+=h,u="right",c="middle";break;case"right":a+=r+l,o+=h,c="middle";break;case"top":a+=l/2,o-=r,u="center",c="bottom";break;case"bottom":a+=l/2,o+=s+r,u="center";break;case"inside":a+=l/2,o+=h,u="center",c="middle";break;case"insideLeft":a+=r,o+=h,c="middle";break;case"insideRight":a+=l-r,o+=h,u="right",c="middle";break;case"insideTop":a+=l/2,o+=r,u="center";break;case"insideBottom":a+=l/2,o+=s-r,u="center",c="bottom";break;case"insideTopLeft":a+=r,o+=r;break;case"insideTopRight":a+=l-r,o+=r,u="right";break;case"insideBottomLeft":a+=r,o+=s-r,c="bottom";break;case"insideBottomRight":a+=l-r,o+=s-r,u="right",c="bottom"}return(t=t||{}).x=a,t.y=o,t.textAlign=u,t.textVerticalAlign=c,t}function si(t,e,n,i,r){if(!e)return"";var a=(t+"").split("\n");r=li(e,n,i,r);for(var o=0,s=a.length;o<s;o++)a[o]=hi(a[o],r);return a.join("\n")}function li(t,e,n,i){(i=I({},i)).font=e;n=W(n,"...");i.maxIterations=W(i.maxIterations,2);var r=i.minChar=W(i.minChar,0);i.cnCharWidth=ni("国",e);var a=i.ascCharWidth=ni("a",e);i.placeholder=W(i.placeholder,"");for(var o=t=Math.max(0,t-1),s=0;s<r&&a<=o;s++)o-=a;var l=ni(n,e);return o<l&&(n="",l=0),o=t-l,i.ellipsis=n,i.ellipsisWidth=l,i.contentWidth=o,i.containerWidth=t,i}function hi(t,e){var n=e.containerWidth,i=e.font,r=e.contentWidth;if(!n)return"";var a=ni(t,i);if(a<=n)return t;for(var o=0;;o++){if(a<=r||o>=e.maxIterations){t+=e.ellipsis;break}var s=0===o?ui(t,r,e.ascCharWidth,e.cnCharWidth):0<a?Math.floor(t.length*r/a):0;a=ni(t=t.substr(0,s),i)}return""===t&&(t=e.placeholder),t}function ui(t,e,n,i){for(var r=0,a=0,o=t.length;a<o&&r<e;a++){var s=t.charCodeAt(a);r+=0<=s&&s<=127?n:i}return a}function ci(t){return ni("国",t)}function di(t,e,n,i,r){null!=t&&(t+="");var a=W(i,ci(e)),o=t?t.split("\n"):[],s=o.length*a,l=s;if(n&&(l+=n[0]+n[2]),t&&r){var h=r.outerHeight,u=r.outerWidth;if(null!=h&&h<l)t="",o=[];else if(null!=u)for(var c=li(u-(n?n[1]+n[3]:0),e,r.ellipsis,{minChar:r.minChar,placeholder:r.placeholder}),d=0,f=o.length;d<f;d++)o[d]=hi(o[d],c)}return{lines:o,height:s,outerHeight:l,lineHeight:a}}function fi(t,e){var n={lines:[],width:0,height:0};if(null!=t&&(t+=""),!t)return n;for(var i,r=Jn.lastIndex=0;null!=(i=Jn.exec(t));){var a=i.index;r<a&&pi(n,t.substring(r,a)),pi(n,i[2],i[1]),r=Jn.lastIndex}r<t.length&&pi(n,t.substring(r,t.length));var o=n.lines,s=0,l=0,h=[],u=e.textPadding,c=e.truncate,d=c&&c.outerWidth,f=c&&c.outerHeight;u&&(null!=d&&(d-=u[1]+u[3]),null!=f&&(f-=u[0]+u[2]));for(var p=0;p<o.length;p++){for(var g=o[p],m=0,v=0,y=0;y<g.tokens.length;y++){var _=(D=g.tokens[y]).styleName&&e.rich[D.styleName]||{},x=D.textPadding=_.textPadding,w=D.font=_.font||e.font,b=D.textHeight=W(_.textHeight,ci(w));if(x&&(b+=x[0]+x[2]),D.height=b,D.lineHeight=G(_.textLineHeight,e.textLineHeight,b),D.textAlign=_&&_.textAlign||e.textAlign,D.textVerticalAlign=_&&_.textVerticalAlign||"middle",null!=f&&s+D.lineHeight>f)return{lines:[],width:0,height:0};D.textWidth=ni(D.text,w);var S=_.textWidth,M=null==S||"auto"===S;if("string"==typeof S&&"%"===S.charAt(S.length-1))D.percentWidth=S,h.push(D),S=0;else{if(M){S=D.textWidth;var I=_.textBackgroundColor,C=I&&I.image;C&&qn(C=Xn(C))&&(S=Math.max(S,C.width*b/C.height))}var T=x?x[1]+x[3]:0;S+=T;var A=null!=d?d-v:null;null!=A&&A<S&&(!M||A<T?(D.text="",D.textWidth=S=0):(D.text=si(D.text,A-T,w,c.ellipsis,{minChar:c.minChar}),D.textWidth=ni(D.text,w),S=D.textWidth+T))}v+=D.width=S,_&&(m=Math.max(m,D.lineHeight))}g.width=v,s+=g.lineHeight=m,l=Math.max(l,v)}n.outerWidth=n.width=W(e.textWidth,l),n.outerHeight=n.height=W(e.textHeight,s),u&&(n.outerWidth+=u[1]+u[3],n.outerHeight+=u[0]+u[2]);for(p=0;p<h.length;p++){var D,k=(D=h[p]).percentWidth;D.width=parseInt(k,10)/100*l}return n}function pi(t,e,n){for(var i=""===e,r=e.split("\n"),a=t.lines,o=0;o<r.length;o++){var s=r[o],l={styleName:n,text:s,isLineHolder:!s&&!i};if(o)a.push({tokens:[l]});else{var h=(a[a.length-1]||(a[0]={tokens:[]})).tokens,u=h.length;1===u&&h[0].isLineHolder?h[0]=l:!s&&u&&!i||h.push(l)}}}function gi(t){var e=(t.fontSize||t.fontFamily)&&[t.fontStyle,t.fontWeight,(t.fontSize||12)+"px",t.fontFamily||"sans-serif"].join(" ");return e&&Y(e)||t.textFont||t.font}function mi(t,e){var n,i,r,a,o,s=e.x,l=e.y,h=e.width,u=e.height,c=e.r;h<0&&(s+=h,h=-h),u<0&&(l+=u,u=-u),"number"==typeof c?n=i=r=a=c:c instanceof Array?1===c.length?n=i=r=a=c[0]:2===c.length?(n=r=c[0],i=a=c[1]):3===c.length?(n=c[0],i=a=c[1],r=c[2]):(n=c[0],i=c[1],r=c[2],a=c[3]):n=i=r=a=0,h<n+i&&(n*=h/(o=n+i),i*=h/o),h<r+a&&(r*=h/(o=r+a),a*=h/o),u<i+r&&(i*=u/(o=i+r),r*=u/o),u<n+a&&(n*=u/(o=n+a),a*=u/o),t.moveTo(s+n,l),t.lineTo(s+h-i,l),0!==i&&t.arc(s+h-i,l+i,i,-Math.PI/2,0),t.lineTo(s+h,l+u-r),0!==r&&t.arc(s+h-r,l+u-r,r,0,Math.PI/2),t.lineTo(s+a,l+u),0!==a&&t.arc(s+a,l+u-a,a,Math.PI/2,Math.PI),t.lineTo(s,l+n),0!==n&&t.arc(s+n,l+n,n,Math.PI,1.5*Math.PI)}ei.measureText=function(t,e){var n=_();return n.font=e||ti,n.measureText(t)};var vi=ti,yi={left:1,right:1,center:1},_i={top:1,bottom:1,middle:1},xi=[["textShadowBlur","shadowBlur",0],["textShadowOffsetX","shadowOffsetX",0],["textShadowOffsetY","shadowOffsetY",0],["textShadowColor","shadowColor","transparent"]],wi={},bi={};function Si(t){return Mi(t),A(t.rich,Mi),t}function Mi(t){if(t){t.font=gi(t);var e=t.textAlign;"middle"===e&&(e="center"),t.textAlign=null==e||yi[e]?e:"left";var n=t.textVerticalAlign||t.textBaseline;"center"===n&&(n="middle"),t.textVerticalAlign=null==n||_i[n]?n:"top",t.textPadding&&(t.textPadding=U(t.textPadding))}}function Ii(t,e,n,i,r,a){i.rich?function(t,e,n,i,r,a){a!==Ln&&(e.__attrCachedBy=Pn.NONE);var o=t.__textCotentBlock;o&&!t.__dirtyText||(o=t.__textCotentBlock=fi(n,i));!function(t,e,n,i,r){var a=n.width,o=n.outerWidth,s=n.outerHeight,l=i.textPadding,h=Pi(bi,t,i,r),u=h.baseX,c=h.baseY,d=h.textAlign,f=h.textVerticalAlign;Ci(e,i,r,u,c);var p=ri(u,o,d),g=ai(c,s,f),m=p,v=g;l&&(m+=l[3],v+=l[0]);var y=m+a;Ai(i)&&Di(t,e,i,p,g,o,s);for(var _=0;_<n.lines.length;_++){for(var x,w=n.lines[_],b=w.tokens,S=b.length,M=w.lineHeight,I=w.width,C=0,T=m,A=y,D=S-1;C<S&&(!(x=b[C]).textAlign||"left"===x.textAlign);)Ti(t,e,x,i,M,v,T,"left"),I-=x.width,T+=x.width,C++;for(;0<=D&&"right"===(x=b[D]).textAlign;)Ti(t,e,x,i,M,v,A,"right"),I-=x.width,A-=x.width,D--;for(T+=(a-(T-m)-(y-A)-I)/2;C<=D;)x=b[C],Ti(t,e,x,i,M,v,T+x.width/2,"center"),T+=x.width,C++;v+=M}}(t,e,o,i,r)}(t,e,n,i,r,a):function(t,e,n,i,r,a){var o,s=Ai(i),l=!1,h=e.__attrCachedBy===Pn.PLAIN_TEXT;a!==Ln?(a&&(o=a.style,l=!s&&h&&o),e.__attrCachedBy=s?Pn.NONE:Pn.PLAIN_TEXT):h&&(e.__attrCachedBy=Pn.NONE);var u=i.font||vi;l&&u===(o.font||vi)||(e.font=u);var c=t.__computedFont;t.__styleFont!==u&&(t.__styleFont=u,c=t.__computedFont=e.font);var d=i.textPadding,f=i.textLineHeight,p=t.__textCotentBlock;p&&!t.__dirtyText||(p=t.__textCotentBlock=di(n,c,d,f,i.truncate));var g=p.outerHeight,m=p.lines,v=p.lineHeight,y=Pi(bi,t,i,r),_=y.baseX,x=y.baseY,w=y.textAlign||"left",b=y.textVerticalAlign;Ci(e,i,r,_,x);var S=ai(x,g,b),M=_,I=S;if(s||d){var C=ni(n,c);d&&(C+=d[1]+d[3]);var T=ri(_,C,w);s&&Di(t,e,i,T,S,C,g),d&&(M=Ni(_,w,d),I+=d[0])}e.textAlign=w,e.textBaseline="middle",e.globalAlpha=i.opacity||1;for(var A=0;A<xi.length;A++){var D=xi[A],k=D[0],P=D[1],L=i[k];l&&L===o[k]||(e[P]=kn(e,P,L||D[2]))}I+=v/2;var O=i.textStrokeWidth,z=l?o.textStrokeWidth:null,E=!l||O!==z,N=!l||E||i.textStroke!==o.textStroke,R=Oi(i.textStroke,O),B=zi(i.textFill);R&&(E&&(e.lineWidth=O),N&&(e.strokeStyle=R));B&&(l&&i.textFill===o.textFill||(e.fillStyle=B));if(1===m.length)R&&e.strokeText(m[0],M,I),B&&e.fillText(m[0],M,I);else for(A=0;A<m.length;A++)R&&e.strokeText(m[A],M,I),B&&e.fillText(m[A],M,I),I+=v}(t,e,n,i,r,a)}function Ci(t,e,n,i,r){if(n&&e.textRotation){var a=e.textOrigin;"center"===a?(i=n.width/2+n.x,r=n.height/2+n.y):a&&(i=a[0]+n.x,r=a[1]+n.y),t.translate(i,r),t.rotate(-e.textRotation),t.translate(-i,-r)}}function Ti(t,e,n,i,r,a,o,s){var l=i.rich[n.styleName]||{};l.text=n.text;var h=n.textVerticalAlign,u=a+r/2;"top"===h?u=a+n.height/2:"bottom"===h&&(u=a+r-n.height/2),!n.isLineHolder&&Ai(l)&&Di(t,e,l,"right"===s?o-n.width:"center"===s?o-n.width/2:o,u-n.height/2,n.width,n.height);var c=n.textPadding;c&&(o=Ni(o,s,c),u-=n.height/2-c[2]-n.textHeight/2),Li(e,"shadowBlur",G(l.textShadowBlur,i.textShadowBlur,0)),Li(e,"shadowColor",l.textShadowColor||i.textShadowColor||"transparent"),Li(e,"shadowOffsetX",G(l.textShadowOffsetX,i.textShadowOffsetX,0)),Li(e,"shadowOffsetY",G(l.textShadowOffsetY,i.textShadowOffsetY,0)),Li(e,"textAlign",s),Li(e,"textBaseline","middle"),Li(e,"font",n.font||vi);var d=Oi(l.textStroke||i.textStroke,p),f=zi(l.textFill||i.textFill),p=W(l.textStrokeWidth,i.textStrokeWidth);d&&(Li(e,"lineWidth",p),Li(e,"strokeStyle",d),e.strokeText(n.text,o,u)),f&&(Li(e,"fillStyle",f),e.fillText(n.text,o,u))}function Ai(t){return!!(t.textBackgroundColor||t.textBorderWidth&&t.textBorderColor)}function Di(t,e,n,i,r,a,o){var s=n.textBackgroundColor,l=n.textBorderWidth,h=n.textBorderColor,u=E(s);if(Li(e,"shadowBlur",n.textBoxShadowBlur||0),Li(e,"shadowColor",n.textBoxShadowColor||"transparent"),Li(e,"shadowOffsetX",n.textBoxShadowOffsetX||0),Li(e,"shadowOffsetY",n.textBoxShadowOffsetY||0),u||l&&h){e.beginPath();var c=n.textBorderRadius;c?mi(e,{x:i,y:r,width:a,height:o,r:c}):e.rect(i,r,a,o),e.closePath()}if(u)if(Li(e,"fillStyle",s),null!=n.fillOpacity){var d=e.globalAlpha;e.globalAlpha=n.fillOpacity*n.opacity,e.fill(),e.globalAlpha=d}else e.fill();else if(N(s)){var f=s.image;(f=Yn(f,null,t,ki,s))&&qn(f)&&e.drawImage(f,i,r,a,o)}if(l&&h)if(Li(e,"lineWidth",l),Li(e,"strokeStyle",h),null!=n.strokeOpacity){d=e.globalAlpha;e.globalAlpha=n.strokeOpacity*n.opacity,e.stroke(),e.globalAlpha=d}else e.stroke()}function ki(t,e){e.image=t}function Pi(t,e,n,i){var r=n.x||0,a=n.y||0,o=n.textAlign,s=n.textVerticalAlign;if(i){var l=n.textPosition;if(l instanceof Array)r=i.x+Ei(l[0],i.width),a=i.y+Ei(l[1],i.height);else{var h=e&&e.calculateTextPosition?e.calculateTextPosition(wi,n,i):oi(wi,n,i);r=h.x,a=h.y,o=o||h.textAlign,s=s||h.textVerticalAlign}var u=n.textOffset;u&&(r+=u[0],a+=u[1])}return(t=t||{}).baseX=r,t.baseY=a,t.textAlign=o,t.textVerticalAlign=s,t}function Li(t,e,n){return t[e]=kn(t,e,n),t[e]}function Oi(t,e){return null==t||e<=0||"transparent"===t||"none"===t?null:t.image||t.colorStops?"#000":t}function zi(t){return null==t||"none"===t?null:t.image||t.colorStops?"#000":t}function Ei(t,e){return"string"==typeof t?0<=t.lastIndexOf("%")?parseFloat(t)/100*e:parseFloat(t):t}function Ni(t,e,n){return"right"===e?t-n[1]:"center"===e?t+n[3]/2-n[1]/2:t+n[3]}function Ri(t,e){return null!=t&&(t||e.textBackgroundColor||e.textBorderWidth&&e.textBorderColor||e.textPadding)}function Bi(){}var Fi=new vn;function Vi(t){for(var e in t=t||{},hn.call(this,t),t)t.hasOwnProperty(e)&&"style"!==e&&(this[e]=t[e]);this.style=new zn(t.style,this),this._rect=null,this.__clipPaths=null}function Hi(t){Vi.call(this,t)}Vi.prototype={constructor:Vi,type:"displayable",__dirty:!0,invisible:!(Bi.prototype={constructor:Bi,drawRectText:function(t,e){var n=this.style;e=n.textRect||e,this.__dirty&&Si(n);var i=n.text;if(null!=i&&(i+=""),Ri(i,n)){t.save();var r=this.transform;n.transformText?this.setTransform(t):r&&(Fi.copy(e),Fi.applyTransform(r),e=Fi),Ii(this,t,i,n,e,Ln),t.restore()}}}),z:0,z2:0,zlevel:0,draggable:!1,dragging:!1,silent:!1,culling:!1,cursor:"pointer",rectHover:!1,progressive:!1,incremental:!1,globalScaleRatio:1,beforeBrush:function(t){},afterBrush:function(t){},brush:function(t,e){},getBoundingRect:function(){},contain:function(t,e){return this.rectContain(t,e)},traverse:function(t,e){t.call(e,this)},rectContain:function(t,e){var n=this.transformCoordToLocal(t,e);return this.getBoundingRect().contain(n[0],n[1])},dirty:function(){this.__dirty=this.__dirtyText=!0,this._rect=null,this.__zr&&this.__zr.refresh()},animateStyle:function(t){return this.animate("style",t)},attrKV:function(t,e){"style"!==t?hn.prototype.attrKV.call(this,t,e):this.style.set(e)},setStyle:function(t,e){return this.style.set(t,e),this.dirty(!1),this},useStyle:function(t){return this.style=new zn(t,this),this.dirty(!1),this},calculateTextPosition:null},w(Vi,hn),S(Vi,Bi),Hi.prototype={constructor:Hi,type:"image",brush:function(t,e){var n=this.style,i=n.image;n.bind(t,this,e);var r=this._image=Yn(i,this._image,this,this.onload);if(r&&qn(r)){var a=n.x||0,o=n.y||0,s=n.width,l=n.height,h=r.width/r.height;if(null==s&&null!=l?s=l*h:null==l&&null!=s?l=s/h:null==s&&null==l&&(s=r.width,l=r.height),this.setTransform(t),n.sWidth&&n.sHeight){var u=n.sx||0,c=n.sy||0;t.drawImage(r,u,c,n.sWidth,n.sHeight,a,o,s,l)}else if(n.sx&&n.sy){var d=s-(u=n.sx),f=l-(c=n.sy);t.drawImage(r,u,c,d,f,a,o,s,l)}else t.drawImage(r,a,o,s,l);null!=n.text&&(this.restoreTransform(t),this.drawRectText(t,this.getBoundingRect()))}},getBoundingRect:function(){var t=this.style;return this._rect||(this._rect=new vn(t.x||0,t.y||0,t.width||0,t.height||0)),this._rect}},w(Hi,Vi);var Wi=314159;function Gi(t){return parseInt(t,10)}var Zi=new vn(0,0,0,0),Ui=new vn(0,0,0,0);function Xi(t,e,n){this.type="canvas";var i=!t.nodeName||"CANVAS"===t.nodeName.toUpperCase();this._opts=n=I({},n||{}),this.dpr=n.devicePixelRatio||nn,this._singleCanvas=i;var r=(this.root=t).style;r&&(r["-webkit-tap-highlight-color"]="transparent",r["-webkit-user-select"]=r["user-select"]=r["-webkit-touch-callout"]="none",t.innerHTML=""),this.storage=e;var a=this._zlevelList=[],o=this._layers={};if(this._layerConfig={},this._needsManuallyCompositing=!1,i){var s=t.width,l=t.height;null!=n.width&&(s=n.width),null!=n.height&&(l=n.height),this.dpr=n.devicePixelRatio||1,t.width=s*this.dpr,t.height=l*this.dpr,this._width=s,this._height=l;var h=new Gn(t,this,this.dpr);h.__builtin__=!0,h.initContext(),(o[Wi]=h).zlevel=Wi,a.push(Wi),this._domRoot=t}else{this._width=this._getSize(0),this._height=this._getSize(1);var u=this._domRoot=function(t,e){var n=document.createElement("div");return n.style.cssText=["position:relative","overflow:hidden","width:"+t+"px","height:"+e+"px","padding:0","margin:0","border-width:0"].join(";")+";",n}(this._width,this._height);t.appendChild(u)}this._hoverlayer=null,this._hoverElements=[]}Xi.prototype={constructor:Xi,getType:function(){return"canvas"},isSingleCanvas:function(){return this._singleCanvas},getViewportRoot:function(){return this._domRoot},getViewportRootOffset:function(){var t=this.getViewportRoot();if(t)return{offsetLeft:t.offsetLeft||0,offsetTop:t.offsetTop||0}},refresh:function(t){var e=this.storage.getDisplayList(!0),n=this._zlevelList;this._redrawId=Math.random(),this._paintList(e,t,this._redrawId);for(var i=0;i<n.length;i++){var r=n[i],a=this._layers[r];if(!a.__builtin__&&a.refresh){var o=0===i?this._backgroundColor:null;a.refresh(o)}}return this.refreshHover(),this},addHover:function(t,e){if(!t.__hoverMir){var n=new t.constructor({style:t.style,shape:t.shape,z:t.z,z2:t.z2,silent:t.silent});return(n.__from=t).__hoverMir=n,e&&n.setStyle(e),this._hoverElements.push(n),n}},removeHover:function(t){var e=t.__hoverMir,n=this._hoverElements,i=x(n,e);0<=i&&n.splice(i,1),t.__hoverMir=null},clearHover:function(t){for(var e=this._hoverElements,n=0;n<e.length;n++){var i=e[n].__from;i&&(i.__hoverMir=null)}e.length=0},refreshHover:function(){var t=this._hoverElements,e=t.length,n=this._hoverlayer;if(n&&n.clear(),e){Cn(t,this.storage.displayableSortFunc);var i={};(n=n||(this._hoverlayer=this.getLayer(1e5))).ctx.save();for(var r=0;r<e;){var a=t[r],o=a.__from;o&&o.__zr?(r++,o.invisible||(a.transform=o.transform,a.invTransform=o.invTransform,a.__clipPaths=o.__clipPaths,this._doPaintEl(a,n,!0,i))):(t.splice(r,1),o.__hoverMir=null,e--)}n.ctx.restore()}},getHoverLayer:function(){return this.getLayer(1e5)},_paintList:function(t,e,n){if(this._redrawId===n){e=e||!1,this._updateLayerStatus(t);var i=this._doPaintList(t,e);if(this._needsManuallyCompositing&&this._compositeManually(),!i){var r=this;Zn(function(){r._paintList(t,e,n)})}}},_compositeManually:function(){var e=this.getLayer(Wi).ctx,n=this._domRoot.width,i=this._domRoot.height;e.clearRect(0,0,n,i),this.eachBuiltinLayer(function(t){t.virtual&&e.drawImage(t.dom,0,0,n,i)})},_doPaintList:function(t,e){for(var n=[],i=0;i<this._zlevelList.length;i++){var r=this._zlevelList[i];(s=this._layers[r]).__builtin__&&s!==this._hoverlayer&&(s.__dirty||e)&&n.push(s)}for(var a=!0,o=0;o<n.length;o++){var s,l=(s=n[o]).ctx,h={};l.save();var u=e?s.__startIndex:s.__drawIndex,c=!e&&s.incremental&&Date.now,d=c&&Date.now(),f=s.zlevel===this._zlevelList[0]?this._backgroundColor:null;if(s.__startIndex===s.__endIndex)s.clear(!1,f);else if(u===s.__startIndex){var p=t[u];p.incremental&&p.notClear&&!e||s.clear(!1,f)}-1===u&&(console.error("For some unknown reason. drawIndex is -1"),u=s.__startIndex);for(var g=u;g<s.__endIndex;g++){var m=t[g];if(this._doPaintEl(m,s,e,h),m.__dirty=m.__dirtyText=!1,c)if(15<Date.now()-d)break}s.__drawIndex=g,s.__drawIndex<s.__endIndex&&(a=!1),h.prevElClipPaths&&l.restore(),l.restore()}return v.wxa&&A(this._layers,function(t){t&&t.ctx&&t.ctx.draw&&t.ctx.draw()}),a},_doPaintEl:function(t,e,n,i){var r=e.ctx,a=t.transform;if((e.__dirty||n)&&!t.invisible&&0!==t.style.opacity&&(!a||a[0]||a[3])&&(!t.culling||!function(t,e,n){return Zi.copy(t.getBoundingRect()),t.transform&&Zi.applyTransform(t.transform),Ui.width=e,Ui.height=n,!Zi.intersect(Ui)}(t,this._width,this._height))){var o=t.__clipPaths,s=i.prevElClipPaths;s&&!function(t,e){if(t===e)return!1;if(!t||!e||t.length!==e.length)return!0;for(var n=0;n<t.length;n++)if(t[n]!==e[n])return!0;return!1}(o,s)||(s&&(r.restore(),i.prevElClipPaths=null,i.prevEl=null),o&&(r.save(),function(t,e){for(var n=0;n<t.length;n++){var i=t[n];i.setTransform(e),e.beginPath(),i.buildPath(e,i.shape),e.clip(),i.restoreTransform(e)}}(o,r),i.prevElClipPaths=o)),t.beforeBrush&&t.beforeBrush(r),t.brush(r,i.prevEl||null),(i.prevEl=t).afterBrush&&t.afterBrush(r)}},getLayer:function(t,e){this._singleCanvas&&!this._needsManuallyCompositing&&(t=Wi);var n=this._layers[t];return n||((n=new Gn("zr_"+t,this,this.dpr)).zlevel=t,n.__builtin__=!0,this._layerConfig[t]&&m(n,this._layerConfig[t],!0),e&&(n.virtual=e),this.insertLayer(t,n),n.initContext()),n},insertLayer:function(t,e){var n=this._layers,i=this._zlevelList,r=i.length,a=null,o=-1,s=this._domRoot;if(n[t])on("ZLevel "+t+" has been used already");else if(function(t){return!!t&&(!!t.__builtin__||"function"==typeof t.resize&&"function"==typeof t.refresh)}(e)){if(0<r&&t>i[0]){for(o=0;o<r-1&&!(i[o]<t&&i[o+1]>t);o++);a=n[i[o]]}if(i.splice(o+1,0,t),!(n[t]=e).virtual)if(a){var l=a.dom;l.nextSibling?s.insertBefore(e.dom,l.nextSibling):s.appendChild(e.dom)}else s.firstChild?s.insertBefore(e.dom,s.firstChild):s.appendChild(e.dom)}else on("Layer of zlevel "+t+" is not valid")},eachLayer:function(t,e){var n,i,r=this._zlevelList;for(i=0;i<r.length;i++)n=r[i],t.call(e,this._layers[n],n)},eachBuiltinLayer:function(t,e){var n,i,r,a=this._zlevelList;for(r=0;r<a.length;r++)i=a[r],(n=this._layers[i]).__builtin__&&t.call(e,n,i)},eachOtherLayer:function(t,e){var n,i,r,a=this._zlevelList;for(r=0;r<a.length;r++)i=a[r],(n=this._layers[i]).__builtin__||t.call(e,n,i)},getLayers:function(){return this._layers},_updateLayerStatus:function(t){function e(t){i&&(i.__endIndex!==t&&(i.__dirty=!0),i.__endIndex=t)}if(this.eachBuiltinLayer(function(t,e){t.__dirty=t.__used=!1}),this._singleCanvas)for(var n=1;n<t.length;n++){if((a=t[n]).zlevel!==t[n-1].zlevel||a.incremental){this._needsManuallyCompositing=!0;break}}var i=null,r=0;for(n=0;n<t.length;n++){var a,o,s=(a=t[n]).zlevel;a.incremental?((o=this.getLayer(s+.001,this._needsManuallyCompositing)).incremental=!0,r=1):o=this.getLayer(s+(0<r?.01:0),this._needsManuallyCompositing),o.__builtin__||on("ZLevel "+s+" has been used by unkown layer "+o.id),o!==i&&(o.__used=!0,o.__startIndex!==n&&(o.__dirty=!0),o.__startIndex=n,o.incremental?o.__drawIndex=-1:o.__drawIndex=n,e(n),i=o),a.__dirty&&(o.__dirty=!0,o.incremental&&o.__drawIndex<0&&(o.__drawIndex=n))}e(n),this.eachBuiltinLayer(function(t,e){!t.__used&&0<t.getElementCount()&&(t.__dirty=!0,t.__startIndex=t.__endIndex=t.__drawIndex=0),t.__dirty&&t.__drawIndex<0&&(t.__drawIndex=t.__startIndex)})},clear:function(){return this.eachBuiltinLayer(this._clearLayer),this},_clearLayer:function(t){t.clear()},setBackgroundColor:function(t){this._backgroundColor=t},configLayer:function(t,e){if(e){var n=this._layerConfig;n[t]?m(n[t],e,!0):n[t]=e;for(var i=0;i<this._zlevelList.length;i++){var r=this._zlevelList[i];if(r===t||r===t+.01)m(this._layers[r],n[t],!0)}}},delLayer:function(t){var e=this._layers,n=this._zlevelList,i=e[t];i&&(i.dom.parentNode.removeChild(i.dom),delete e[t],n.splice(x(n,t),1))},resize:function(e,n){if(this._domRoot.style){var t=this._domRoot;t.style.display="none";var i=this._opts;if(null!=e&&(i.width=e),null!=n&&(i.height=n),e=this._getSize(0),n=this._getSize(1),t.style.display="",this._width!==e||n!==this._height){for(var r in t.style.width=e+"px",t.style.height=n+"px",this._layers)this._layers.hasOwnProperty(r)&&this._layers[r].resize(e,n);A(this._progressiveLayers,function(t){t.resize(e,n)}),this.refresh(!0)}this._width=e,this._height=n}else{if(null==e||null==n)return;this._width=e,this._height=n,this.getLayer(Wi).resize(e,n)}return this},clearLayer:function(t){var e=this._layers[t];e&&e.clear()},dispose:function(){this.root.innerHTML="",this.root=this.storage=this._domRoot=this._layers=null},getRenderedCanvas:function(t){if(t=t||{},this._singleCanvas&&!this._compositeManually)return this._layers[Wi].dom;var e=new Gn("image",this,t.pixelRatio||this.dpr);if(e.initContext(),e.clear(!1,t.backgroundColor||this._backgroundColor),t.pixelRatio<=this.dpr){this.refresh();var n=e.dom.width,i=e.dom.height,r=e.ctx;this.eachLayer(function(t){t.__builtin__?r.drawImage(t.dom,0,0,n,i):t.renderToCanvas&&(e.ctx.save(),t.renderToCanvas(e.ctx),e.ctx.restore())})}else for(var a={},o=this.storage.getDisplayList(!0),s=0;s<o.length;s++){var l=o[s];this._doPaintEl(l,e,!0,a)}return e.dom},getWidth:function(){return this._width},getHeight:function(){return this._height},_getSize:function(t){var e=this._opts,n=["width","height"][t],i=["clientWidth","clientHeight"][t],r=["paddingLeft","paddingTop"][t],a=["paddingRight","paddingBottom"][t];if(null!=e[n]&&"auto"!==e[n])return parseFloat(e[n]);var o=this.root,s=document.defaultView.getComputedStyle(o);return(o[i]||Gi(s[n])||Gi(o.style[n]))-(Gi(s[r])||0)-(Gi(s[a])||0)|0},pathToImage:function(t,e){e=e||this.dpr;var n=document.createElement("canvas"),i=n.getContext("2d"),r=t.getBoundingRect(),a=t.style,o=a.shadowBlur*e,s=a.shadowOffsetX*e,l=a.shadowOffsetY*e,h=a.hasStroke()?a.lineWidth:0,u=Math.max(h/2,o-s),c=Math.max(h/2,s+o),d=Math.max(h/2,o-l),f=Math.max(h/2,l+o),p=r.width+u+c,g=r.height+d+f;n.width=p*e,n.height=g*e,i.scale(e,e),i.clearRect(0,0,p,g),i.dpr=e;var m={position:t.position,rotation:t.rotation,scale:t.scale};t.position=[u-r.x,d-r.y],t.rotation=0,t.scale=[1,1],t.updateTransform(),t&&t.brush(i);var v=new Hi({style:{x:0,y:0,image:n}});return null!=m.position&&(v.position=t.position=m.position),null!=m.rotation&&(v.rotation=t.rotation=m.rotation),null!=m.scale&&(v.scale=t.scale=m.scale),v}};function Yi(t){t=t||{},this.stage=t.stage||{},this.onframe=t.onframe||function(){},this._clips=[],this._running=!1,this._time,this._pausedTime,this._pauseStart,this._paused=!1,It.call(this)}Yi.prototype={constructor:Yi,addClip:function(t){this._clips.push(t)},addAnimator:function(t){t.animation=this;for(var e=t.getClips(),n=0;n<e.length;n++)this.addClip(e[n])},removeClip:function(t){var e=x(this._clips,t);0<=e&&this._clips.splice(e,1)},removeAnimator:function(t){for(var e=t.getClips(),n=0;n<e.length;n++)this.removeClip(e[n]);t.animation=null},_update:function(){for(var t=(new Date).getTime()-this._pausedTime,e=t-this._time,n=this._clips,i=n.length,r=[],a=[],o=0;o<i;o++){var s=n[o],l=s.step(t,e);l&&(r.push(l),a.push(s))}for(o=0;o<i;)n[o]._needsRemove?(n[o]=n[i-1],n.pop(),i--):o++;i=r.length;for(o=0;o<i;o++)a[o].fire(r[o]);this._time=t,this.onframe(e),this.trigger("frame",e),this.stage.update&&this.stage.update()},_startLoop:function(){var e=this;this._running=!0,Zn(function t(){e._running&&(Zn(t),e._paused||e._update())})},start:function(){this._time=(new Date).getTime(),this._pausedTime=0,this._startLoop()},stop:function(){this._running=!1},pause:function(){this._paused||(this._pauseStart=(new Date).getTime(),this._paused=!0)},resume:function(){this._paused&&(this._pausedTime+=(new Date).getTime()-this._pauseStart,this._paused=!1)},clear:function(){this._clips=[]},isFinished:function(){return!this._clips.length},animate:function(t,e){var n=new tn(t,(e=e||{}).loop,e.getter,e.setter);return this.addAnimator(n),n}},S(Yi,It);var ji=["click","dblclick","mousewheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],qi=["touchstart","touchend","touchmove"],$i={pointerdown:1,pointerup:1,pointermove:1,pointerout:1},Ki=D(ji,function(t){var e=t.replace("mouse","pointer");return $i[e]?e:t});function Qi(t){return"mousewheel"===t&&v.browser.firefox?"DOMMouseScroll":t}function Ji(t){t._touching=!0,clearTimeout(t._touchTimer),t._touchTimer=setTimeout(function(){t._touching=!1},700)}var tr={mousemove:function(t){t=Et(this.dom,t),this.trigger("mousemove",t)},mouseout:function(t){var e=(t=Et(this.dom,t)).toElement||t.relatedTarget;if(e!==this.dom)for(;e&&9!==e.nodeType;){if(e===this.dom)return;e=e.parentNode}this.trigger("mouseout",t)},touchstart:function(t){(t=Et(this.dom,t)).zrByTouch=!0,this._lastTouchMoment=new Date,this.handler.processGesture(this,t,"start"),tr.mousemove.call(this,t),tr.mousedown.call(this,t),Ji(this)},touchmove:function(t){(t=Et(this.dom,t)).zrByTouch=!0,this.handler.processGesture(this,t,"change"),tr.mousemove.call(this,t),Ji(this)},touchend:function(t){(t=Et(this.dom,t)).zrByTouch=!0,this.handler.processGesture(this,t,"end"),tr.mouseup.call(this,t),+new Date-this._lastTouchMoment<300&&tr.click.call(this,t),Ji(this)},pointerdown:function(t){tr.mousedown.call(this,t)},pointermove:function(t){er(t)||tr.mousemove.call(this,t)},pointerup:function(t){tr.mouseup.call(this,t)},pointerout:function(t){er(t)||tr.mouseout.call(this,t)}};function er(t){var e=t.pointerType;return"pen"===e||"touch"===e}function nr(n){function t(t,e){A(t,function(t){Nt(n,Qi(t),e._handlers[t])},e)}It.call(this),this.dom=n,this._touching=!1,this._touchTimer,this._handlers={},function(e){A(qi,function(t){e._handlers[t]=k(tr[t],e)}),A(Ki,function(t){e._handlers[t]=k(tr[t],e)}),A(ji,function(t){e._handlers[t]=function(t,e){return function(){if(!e._touching)return t.apply(e,arguments)}}(tr[t],e)})}(this),v.pointerEventsSupported?t(Ki,this):(v.touchEventsSupported&&t(qi,this),t(ji,this))}A(["click","mousedown","mouseup","mousewheel","dblclick","contextmenu"],function(e){tr[e]=function(t){t=Et(this.dom,t),this.trigger(e,t)}});var ir=nr.prototype;ir.dispose=function(){for(var t,e,n,i=ji.concat(qi),r=0;r<i.length;r++){var a=i[r];t=this.dom,e=Qi(a),n=this._handlers[a],Dt?t.removeEventListener(e,n):t.detachEvent("on"+e,n)}},ir.setCursor=function(t){this.dom.style&&(this.dom.style.cursor=t||"default")},S(nr,It);var rr=!v.canvasSupported,ar={canvas:Xi},or={};function sr(t,e){var n=new hr(i(),t,e);return or[n.id]=n}function lr(t,e){ar[t]=e}var hr=function(t,e,n){n=n||{},this.dom=e,this.id=t;var i=this,r=new An,a=n.renderer;if(rr){if(!ar.vml)throw new Error("You need to require 'zrender/vml/vml' to support IE8");a="vml"}else a&&ar[a]||(a="canvas");var o=new ar[a](e,r,n,t);this.storage=r,this.painter=o;var s=v.node||v.worker?null:new nr(o.getViewportRoot());this.handler=new Ut(r,o,s,o.root),this.animation=new Yi({stage:{update:k(this.flush,this)}}),this.animation.start(),this._needsRefresh;var l=r.delFromStorage,h=r.addToStorage;r.delFromStorage=function(t){l.call(r,t),t&&t.removeSelfFromZr(i)},r.addToStorage=function(t){h.call(r,t),t.addSelfToZr(i)}};hr.prototype={constructor:hr,getId:function(){return this.id},add:function(t){this.storage.addRoot(t),this._needsRefresh=!0},remove:function(t){this.storage.delRoot(t),this._needsRefresh=!0},configLayer:function(t,e){this.painter.configLayer&&this.painter.configLayer(t,e),this._needsRefresh=!0},setBackgroundColor:function(t){this.painter.setBackgroundColor&&this.painter.setBackgroundColor(t),this._needsRefresh=!0},refreshImmediately:function(){this._needsRefresh=this._needsRefreshHover=!1,this.painter.refresh(),this._needsRefresh=this._needsRefreshHover=!1},refresh:function(){this._needsRefresh=!0},flush:function(){var t;this._needsRefresh&&(t=!0,this.refreshImmediately()),this._needsRefreshHover&&(t=!0,this.refreshHoverImmediately()),t&&this.trigger("rendered")},addHover:function(t,e){if(this.painter.addHover){var n=this.painter.addHover(t,e);return this.refreshHover(),n}},removeHover:function(t){this.painter.removeHover&&(this.painter.removeHover(t),this.refreshHover())},clearHover:function(){this.painter.clearHover&&(this.painter.clearHover(),this.refreshHover())},refreshHover:function(){this._needsRefreshHover=!0},refreshHoverImmediately:function(){this._needsRefreshHover=!1,this.painter.refreshHover&&this.painter.refreshHover()},resize:function(t){t=t||{},this.painter.resize(t.width,t.height),this.handler.resize()},clearAnimation:function(){this.animation.clear()},getWidth:function(){return this.painter.getWidth()},getHeight:function(){return this.painter.getHeight()},pathToImage:function(t,e){return this.painter.pathToImage(t,e)},setCursorStyle:function(t){this.handler.setCursorStyle(t)},findHover:function(t,e){return this.handler.findHover(t,e)},on:function(t,e,n){this.handler.on(t,e,n)},off:function(t,e){this.handler.off(t,e)},trigger:function(t,e){this.handler.trigger(t,e)},clear:function(){this.storage.delRoot(),this.painter.clear()},dispose:function(){this.animation.stop(),this.clear(),this.storage.dispose(),this.painter.dispose(),this.handler.dispose(),this.animation=this.storage=this.painter=this.handler=null,function(t){delete or[t]}(this.id)}};var ur=(Object.freeze||Object)({version:"4.1.0",init:sr,dispose:function(t){if(t)t.dispose();else{for(var e in or)or.hasOwnProperty(e)&&or[e].dispose();or={}}return this},getInstance:function(t){return or[t]},registerPainter:lr}),cr=A,dr=N,fr=O,pr="series\0";function gr(t){return t instanceof Array?t:null==t?[]:[t]}function mr(t,e,n){if(t){t[e]=t[e]||{},t.emphasis=t.emphasis||{},t.emphasis[e]=t.emphasis[e]||{};for(var i=0,r=n.length;i<r;i++){var a=n[i];!t.emphasis[e].hasOwnProperty(a)&&t[e].hasOwnProperty(a)&&(t.emphasis[e][a]=t[e][a])}}}var vr=["fontStyle","fontWeight","fontSize","fontFamily","rich","tag","color","textBorderColor","textBorderWidth","width","height","lineHeight","align","verticalAlign","baseline","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY","textShadowColor","textShadowBlur","textShadowOffsetX","textShadowOffsetY","backgroundColor","borderColor","borderWidth","borderRadius","padding"];function yr(t){return!dr(t)||fr(t)||t instanceof Date?t:t.value}function _r(t,r){r=(r||[]).slice();var a=D(t||[],function(t,e){return{exist:t}});return cr(r,function(t,e){if(dr(t)){for(var n=0;n<a.length;n++)if(!a[n].option&&null!=t.id&&a[n].exist.id===t.id+"")return a[n].option=t,void(r[e]=null);for(n=0;n<a.length;n++){var i=a[n].exist;if(!(a[n].option||null!=i.id&&null!=t.id||null==t.name||br(t)||br(i)||i.name!==t.name+""))return a[n].option=t,void(r[e]=null)}}}),cr(r,function(t,e){if(dr(t)){for(var n=0;n<a.length;n++){var i=a[n].exist;if(!a[n].option&&!br(i)&&null==t.id){a[n].option=t;break}}n>=a.length&&a.push({option:t})}}),a}function xr(t){var o=Q();cr(t,function(t,e){var n=t.exist;n&&o.set(n.id,t)}),cr(t,function(t,e){var n=t.option;X(!n||null==n.id||!o.get(n.id)||o.get(n.id)===t,"id duplicates: "+(n&&n.id)),n&&null!=n.id&&o.set(n.id,t),t.keyInfo||(t.keyInfo={})}),cr(t,function(t,e){var n=t.exist,i=t.option,r=t.keyInfo;if(dr(i)){if(r.name=null!=i.name?i.name+"":n?n.name:pr+e,n)r.id=n.id;else if(null!=i.id)r.id=i.id+"";else for(var a=0;r.id="\0"+r.name+"\0"+a++,o.get(r.id););o.set(r.id,t)}})}function wr(t){var e=t.name;return!(!e||!e.indexOf(pr))}function br(t){return dr(t)&&t.id&&0===(t.id+"").indexOf("\0_ec_\0")}function Sr(e,t){return null!=t.dataIndexInside?t.dataIndexInside:null!=t.dataIndex?O(t.dataIndex)?D(t.dataIndex,function(t){return e.indexOfRawIndex(t)}):e.indexOfRawIndex(t.dataIndex):null!=t.name?O(t.name)?D(t.name,function(t){return e.indexOfName(t)}):e.indexOfName(t.name):void 0}function Mr(){var e="__\0ec_inner_"+Ir+++"_"+Math.random().toFixed(5);return function(t){return t[e]||(t[e]={})}}var Ir=0;function Cr(s,l,h){if(E(l)){var t={};t[l+"Index"]=0,l=t}var e=h&&h.defaultMainType;!e||Tr(l,e+"Index")||Tr(l,e+"Id")||Tr(l,e+"Name")||(l[e+"Index"]=0);var u={};return cr(l,function(t,e){t=l[e];if("dataIndex"!==e&&"dataIndexInside"!==e){var n=e.match(/^(\w+)(Index|Id|Name)$/)||[],i=n[1],r=(n[2]||"").toLowerCase();if(!(!i||!r||null==t||"index"===r&&"none"===t||h&&h.includeMainTypes&&x(h.includeMainTypes,i)<0)){var a={mainType:i};"index"===r&&"all"===t||(a[r]=t);var o=s.queryComponents(a);u[i+"Models"]=o,u[i+"Model"]=o[0]}}else u[e]=t}),u}function Tr(t,e){return t&&t.hasOwnProperty(e)}function Ar(t,e,n){t.setAttribute?t.setAttribute(e,n):t[e]=n}function Dr(t){return"auto"===t?v.domSupported?"html":"richText":t||"html"}var kr=".",Pr="___EC__COMPONENT__CONTAINER___";function Lr(t){var e={main:"",sub:""};return t&&(t=t.split(kr),e.main=t[0]||"",e.sub=t[1]||""),e}function Or(t){(t.$constructor=t).extend=function(t){function e(){t.$constructor?t.$constructor.apply(this,arguments):n.apply(this,arguments)}var n=this;return I(e.prototype,t),e.extend=this.extend,e.superCall=Nr,e.superApply=Rr,w(e,this),e.superClass=n,e}}var zr=0;function Er(t){var e=["__\0is_clz",zr++,Math.random().toFixed(3)].join("_");t.prototype[e]=!0,t.isInstance=function(t){return!(!t||!t[e])}}function Nr(t,e){var n=Z(arguments,2);return this.superClass.prototype[e].apply(t,n)}function Rr(t,e,n){return this.superClass.prototype[e].apply(t,n)}function Br(n,t){t=t||{};var r={};if(n.registerClass=function(t,e){if(e)if(function(t){X(/^[a-zA-Z0-9_]+([.][a-zA-Z0-9_]+)?$/.test(t),'componentType "'+t+'" illegal')}(e),(e=Lr(e)).sub){if(e.sub!==Pr){(function(t){var e=r[t.main];e&&e[Pr]||((e=r[t.main]={})[Pr]=!0);return e})(e)[e.sub]=t}}else r[e.main]=t;return t},n.getClass=function(t,e,n){var i=r[t];if(i&&i[Pr]&&(i=e?i[e]:null),n&&!i)throw new Error(e?"Component "+t+"."+(e||"")+" not exists. Load it first.":t+".type should be specified.");return i},n.getClassesByMainType=function(t){t=Lr(t);var n=[],e=r[t.main];return e&&e[Pr]?A(e,function(t,e){e!==Pr&&n.push(t)}):n.push(e),n},n.hasClass=function(t){return t=Lr(t),!!r[t.main]},n.getAllClassMainTypes=function(){var n=[];return A(r,function(t,e){n.push(e)}),n},n.hasSubTypes=function(t){t=Lr(t);var e=r[t.main];return e&&e[Pr]},n.parseClassType=Lr,t.registerWhenExtend){var i=n.extend;i&&(n.extend=function(t){var e=i.call(this,t);return n.registerClass(e,t.type)})}return n}function Fr(s){for(var t=0;t<s.length;t++)s[t][1]||(s[t][1]=s[t][0]);return function(t,e,n){for(var i={},r=0;r<s.length;r++){var a=s[r][1];if(!(e&&0<=x(e,a)||n&&x(n,a)<0)){var o=t.getShallow(a);null!=o&&(i[s[r][0]]=o)}}return i}}var Vr=Fr([["lineWidth","width"],["stroke","color"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"]]),Hr={getLineStyle:function(t){var e=Vr(this,t);return e.lineDash=this.getLineDash(e.lineWidth),e},getLineDash:function(t){null==t&&(t=1);var e=this.get("type"),n=Math.max(t,2),i=4*t;return"solid"!==e&&null!=e&&("dashed"===e?[i,i]:[n,n])}},Wr=Fr([["fill","color"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["opacity"],["shadowColor"]]),Gr={getAreaStyle:function(t,e){return Wr(this,t,e)}},Zr=Math.pow,Ur=Math.sqrt,Xr=1e-8,Yr=1e-4,jr=Ur(3),qr=1/3,$r=nt(),Kr=nt(),Qr=nt();function Jr(t){return-Xr<t&&t<Xr}function ta(t){return Xr<t||t<-Xr}function ea(t,e,n,i,r){var a=1-r;return a*a*(a*t+3*r*e)+r*r*(r*i+3*a*n)}function na(t,e,n,i,r){var a=1-r;return 3*(((e-t)*a+2*(n-e)*r)*a+(i-n)*r*r)}function ia(t,e,n,i,r){var a=6*n-12*e+6*t,o=9*e+3*i-3*t-9*n,s=3*e-3*t,l=0;if(Jr(o)){if(ta(a))0<=(u=-s/a)&&u<=1&&(r[l++]=u)}else{var h=a*a-4*o*s;if(Jr(h))r[0]=-a/(2*o);else if(0<h){var u,c=Ur(h),d=(-a-c)/(2*o);0<=(u=(-a+c)/(2*o))&&u<=1&&(r[l++]=u),0<=d&&d<=1&&(r[l++]=d)}}return l}function ra(t,e,n,i,r,a){var o=(e-t)*r+t,s=(n-e)*r+e,l=(i-n)*r+n,h=(s-o)*r+o,u=(l-s)*r+s,c=(u-h)*r+h;a[0]=t,a[1]=o,a[2]=h,a[3]=c,a[4]=c,a[5]=u,a[6]=l,a[7]=i}function aa(t,e,n,i){var r=1-i;return r*(r*t+2*i*e)+i*i*n}function oa(t,e,n,i){return 2*((1-i)*(e-t)+i*(n-e))}function sa(t,e,n){var i=t+n-2*e;return 0==i?.5:(t-e)/i}function la(t,e,n,i,r){var a=(e-t)*i+t,o=(n-e)*i+e,s=(o-a)*i+a;r[0]=t,r[1]=a,r[2]=s,r[3]=s,r[4]=o,r[5]=n}var ha=Math.min,ua=Math.max,ca=Math.sin,da=Math.cos,fa=2*Math.PI,pa=nt(),ga=nt(),ma=nt();function va(t,e,n){if(0!==t.length){var i,r=t[0],a=r[0],o=r[0],s=r[1],l=r[1];for(i=1;i<t.length;i++)r=t[i],a=ha(a,r[0]),o=ua(o,r[0]),s=ha(s,r[1]),l=ua(l,r[1]);e[0]=a,e[1]=s,n[0]=o,n[1]=l}}function ya(t,e,n,i,r,a){r[0]=ha(t,n),r[1]=ha(e,i),a[0]=ua(t,n),a[1]=ua(e,i)}var _a=[],xa=[];function wa(t,e,n,i,r,a,o,s,l,h){var u,c=ia,d=ea,f=c(t,n,r,o,_a);for(l[0]=1/0,l[1]=1/0,h[0]=-1/0,h[1]=-1/0,u=0;u<f;u++){var p=d(t,n,r,o,_a[u]);l[0]=ha(p,l[0]),h[0]=ua(p,h[0])}for(f=c(e,i,a,s,xa),u=0;u<f;u++){var g=d(e,i,a,s,xa[u]);l[1]=ha(g,l[1]),h[1]=ua(g,h[1])}l[0]=ha(t,l[0]),h[0]=ua(t,h[0]),l[0]=ha(o,l[0]),h[0]=ua(o,h[0]),l[1]=ha(e,l[1]),h[1]=ua(e,h[1]),l[1]=ha(s,l[1]),h[1]=ua(s,h[1])}function ba(t,e,n,i,r,a,o,s,l){var h=_t,u=xt,c=Math.abs(r-a);if(c%fa<1e-4&&1e-4<c)return s[0]=t-n,s[1]=e-i,l[0]=t+n,void(l[1]=e+i);if(pa[0]=da(r)*n+t,pa[1]=ca(r)*i+e,ga[0]=da(a)*n+t,ga[1]=ca(a)*i+e,h(s,pa,ga),u(l,pa,ga),(r%=fa)<0&&(r+=fa),(a%=fa)<0&&(a+=fa),a<r&&!o?a+=fa:r<a&&o&&(r+=fa),o){var d=a;a=r,r=d}for(var f=0;f<a;f+=Math.PI/2)r<f&&(ma[0]=da(f)*n+t,ma[1]=ca(f)*i+e,h(s,ma,s),u(l,ma,l))}var Sa={M:1,L:2,C:3,Q:4,A:5,Z:6,R:7},Ma=[],Ia=[],Ca=[],Ta=[],Aa=Math.min,Da=Math.max,ka=Math.cos,Pa=Math.sin,La=Math.sqrt,Oa=Math.abs,za="undefined"!=typeof Float32Array,Ea=function(t){this._saveData=!t,this._saveData&&(this.data=[]),this._ctx=null};function Na(t,e,n,i,r,a,o){if(0===r)return!1;var s=r,l=0;if(e+s<o&&i+s<o||o<e-s&&o<i-s||t+s<a&&n+s<a||a<t-s&&a<n-s)return!1;if(t===n)return Math.abs(a-t)<=s/2;var h=(l=(e-i)/(t-n))*a-o+(t*i-n*e)/(t-n);return h*h/(l*l+1)<=s/2*s/2}function Ra(t,e,n,i,r,a,o,s,l,h,u){if(0===l)return!1;var c=l;return!(e+c<u&&i+c<u&&a+c<u&&s+c<u||u<e-c&&u<i-c&&u<a-c&&u<s-c||t+c<h&&n+c<h&&r+c<h&&o+c<h||h<t-c&&h<n-c&&h<r-c&&h<o-c)&&function(t,e,n,i,r,a,o,s,l,h,u){var c,d,f,p,g,m=.005,v=1/0;$r[0]=l,$r[1]=h;for(var y=0;y<1;y+=.05)Kr[0]=ea(t,n,r,o,y),Kr[1]=ea(e,i,a,s,y),(p=vt($r,Kr))<v&&(c=y,v=p);v=1/0;for(var _=0;_<32&&!(m<Yr);_++)d=c-m,f=c+m,Kr[0]=ea(t,n,r,o,d),Kr[1]=ea(e,i,a,s,d),p=vt(Kr,$r),0<=d&&p<v?(c=d,v=p):(Qr[0]=ea(t,n,r,o,f),Qr[1]=ea(e,i,a,s,f),g=vt(Qr,$r),f<=1&&g<v?(c=f,v=g):m*=.5);return u&&(u[0]=ea(t,n,r,o,c),u[1]=ea(e,i,a,s,c)),Ur(v)}(t,e,n,i,r,a,o,s,h,u,null)<=c/2}function Ba(t,e,n,i,r,a,o,s,l){if(0===o)return!1;var h=o;return!(e+h<l&&i+h<l&&a+h<l||l<e-h&&l<i-h&&l<a-h||t+h<s&&n+h<s&&r+h<s||s<t-h&&s<n-h&&s<r-h)&&function(t,e,n,i,r,a,o,s,l){var h,u=.005,c=1/0;$r[0]=o,$r[1]=s;for(var d=0;d<1;d+=.05){Kr[0]=aa(t,n,r,d),Kr[1]=aa(e,i,a,d),(m=vt($r,Kr))<c&&(h=d,c=m)}c=1/0;for(var f=0;f<32&&!(u<Yr);f++){var p=h-u,g=h+u;Kr[0]=aa(t,n,r,p),Kr[1]=aa(e,i,a,p);var m=vt(Kr,$r);if(0<=p&&m<c)h=p,c=m;else{Qr[0]=aa(t,n,r,g),Qr[1]=aa(e,i,a,g);var v=vt(Qr,$r);g<=1&&v<c?(h=g,c=v):u*=.5}}return l&&(l[0]=aa(t,n,r,h),l[1]=aa(e,i,a,h)),Ur(c)}(t,e,n,i,r,a,s,l,null)<=h/2}Ea.prototype={constructor:Ea,_xi:0,_yi:0,_x0:0,_y0:0,_ux:0,_uy:0,_len:0,_lineDash:null,_dashOffset:0,_dashIdx:0,_dashSum:0,setScale:function(t,e,n){n=n||0,this._ux=Oa(n/nn/t)||0,this._uy=Oa(n/nn/e)||0},getContext:function(){return this._ctx},beginPath:function(t){return(this._ctx=t)&&t.beginPath(),t&&(this.dpr=t.dpr),this._saveData&&(this._len=0),this._lineDash&&(this._lineDash=null,this._dashOffset=0),this},moveTo:function(t,e){return this.addData(Sa.M,t,e),this._ctx&&this._ctx.moveTo(t,e),this._x0=t,this._y0=e,this._xi=t,this._yi=e,this},lineTo:function(t,e){var n=Oa(t-this._xi)>this._ux||Oa(e-this._yi)>this._uy||this._len<5;return this.addData(Sa.L,t,e),this._ctx&&n&&(this._needsDash()?this._dashedLineTo(t,e):this._ctx.lineTo(t,e)),n&&(this._xi=t,this._yi=e),this},bezierCurveTo:function(t,e,n,i,r,a){return this.addData(Sa.C,t,e,n,i,r,a),this._ctx&&(this._needsDash()?this._dashedBezierTo(t,e,n,i,r,a):this._ctx.bezierCurveTo(t,e,n,i,r,a)),this._xi=r,this._yi=a,this},quadraticCurveTo:function(t,e,n,i){return this.addData(Sa.Q,t,e,n,i),this._ctx&&(this._needsDash()?this._dashedQuadraticTo(t,e,n,i):this._ctx.quadraticCurveTo(t,e,n,i)),this._xi=n,this._yi=i,this},arc:function(t,e,n,i,r,a){return this.addData(Sa.A,t,e,n,n,i,r-i,0,a?0:1),this._ctx&&this._ctx.arc(t,e,n,i,r,a),this._xi=ka(r)*n+t,this._yi=Pa(r)*n+e,this},arcTo:function(t,e,n,i,r){return this._ctx&&this._ctx.arcTo(t,e,n,i,r),this},rect:function(t,e,n,i){return this._ctx&&this._ctx.rect(t,e,n,i),this.addData(Sa.R,t,e,n,i),this},closePath:function(){this.addData(Sa.Z);var t=this._ctx,e=this._x0,n=this._y0;return t&&(this._needsDash()&&this._dashedLineTo(e,n),t.closePath()),this._xi=e,this._yi=n,this},fill:function(t){t&&t.fill(),this.toStatic()},stroke:function(t){t&&t.stroke(),this.toStatic()},setLineDash:function(t){if(t instanceof Array){this._lineDash=t;for(var e=this._dashIdx=0,n=0;n<t.length;n++)e+=t[n];this._dashSum=e}return this},setLineDashOffset:function(t){return this._dashOffset=t,this},len:function(){return this._len},setData:function(t){var e=t.length;this.data&&this.data.length===e||!za||(this.data=new Float32Array(e));for(var n=0;n<e;n++)this.data[n]=t[n];this._len=e},appendPath:function(t){t instanceof Array||(t=[t]);for(var e=t.length,n=0,i=this._len,r=0;r<e;r++)n+=t[r].len();za&&this.data instanceof Float32Array&&(this.data=new Float32Array(i+n));for(r=0;r<e;r++)for(var a=t[r].data,o=0;o<a.length;o++)this.data[i++]=a[o];this._len=i},addData:function(t){if(this._saveData){var e=this.data;this._len+arguments.length>e.length&&(this._expandData(),e=this.data);for(var n=0;n<arguments.length;n++)e[this._len++]=arguments[n];this._prevCmd=t}},_expandData:function(){if(!(this.data instanceof Array)){for(var t=[],e=0;e<this._len;e++)t[e]=this.data[e];this.data=t}},_needsDash:function(){return this._lineDash},_dashedLineTo:function(t,e){var n,i,r=this._dashSum,a=this._dashOffset,o=this._lineDash,s=this._ctx,l=this._xi,h=this._yi,u=t-l,c=e-h,d=La(u*u+c*c),f=l,p=h,g=o.length;for(a<0&&(a=r+a),f-=(a%=r)*(u/=d),p-=a*(c/=d);0<u&&f<=t||u<0&&t<=f||0===u&&(0<c&&p<=e||c<0&&e<=p);)f+=u*(n=o[i=this._dashIdx]),p+=c*n,this._dashIdx=(i+1)%g,0<u&&f<l||u<0&&l<f||0<c&&p<h||c<0&&h<p||s[i%2?"moveTo":"lineTo"](0<=u?Aa(f,t):Da(f,t),0<=c?Aa(p,e):Da(p,e));u=f-t,c=p-e,this._dashOffset=-La(u*u+c*c)},_dashedBezierTo:function(t,e,n,i,r,a){var o,s,l,h,u,c=this._dashSum,d=this._dashOffset,f=this._lineDash,p=this._ctx,g=this._xi,m=this._yi,v=ea,y=0,_=this._dashIdx,x=f.length,w=0;for(d<0&&(d=c+d),d%=c,o=0;o<1;o+=.1)s=v(g,t,n,r,o+.1)-v(g,t,n,r,o),l=v(m,e,i,a,o+.1)-v(m,e,i,a,o),y+=La(s*s+l*l);for(;_<x&&!(d<(w+=f[_]));_++);for(o=(w-d)/y;o<=1;)h=v(g,t,n,r,o),u=v(m,e,i,a,o),_%2?p.moveTo(h,u):p.lineTo(h,u),o+=f[_]/y,_=(_+1)%x;_%2!=0&&p.lineTo(r,a),s=r-h,l=a-u,this._dashOffset=-La(s*s+l*l)},_dashedQuadraticTo:function(t,e,n,i){var r=n,a=i;n=(n+2*t)/3,i=(i+2*e)/3,t=(this._xi+2*t)/3,e=(this._yi+2*e)/3,this._dashedBezierTo(t,e,n,i,r,a)},toStatic:function(){var t=this.data;t instanceof Array&&(t.length=this._len,za&&(this.data=new Float32Array(t)))},getBoundingRect:function(){Ma[0]=Ma[1]=Ca[0]=Ca[1]=Number.MAX_VALUE,Ia[0]=Ia[1]=Ta[0]=Ta[1]=-Number.MAX_VALUE;for(var t,e,n,i,r,a,o,s,l,h,u,c,d,f,p=this.data,g=0,m=0,v=0,y=0,_=0;_<p.length;){var x=p[_++];switch(1===_&&(v=g=p[_],y=m=p[_+1]),x){case Sa.M:g=v=p[_++],m=y=p[_++],Ca[0]=v,Ca[1]=y,Ta[0]=v,Ta[1]=y;break;case Sa.L:ya(g,m,p[_],p[_+1],Ca,Ta),g=p[_++],m=p[_++];break;case Sa.C:wa(g,m,p[_++],p[_++],p[_++],p[_++],p[_],p[_+1],Ca,Ta),g=p[_++],m=p[_++];break;case Sa.Q:t=g,e=m,n=p[_++],i=p[_++],r=p[_],a=p[_+1],o=Ca,s=Ta,h=l=void 0,h=aa,u=ua(ha((l=sa)(t,n,r),1),0),c=ua(ha(l(e,i,a),1),0),d=h(t,n,r,u),f=h(e,i,a,c),o[0]=ha(t,r,d),o[1]=ha(e,a,f),s[0]=ua(t,r,d),s[1]=ua(e,a,f),g=p[_++],m=p[_++];break;case Sa.A:var w=p[_++],b=p[_++],S=p[_++],M=p[_++],I=p[_++],C=p[_++]+I;_+=1;var T=1-p[_++];1===_&&(v=ka(I)*S+w,y=Pa(I)*M+b),ba(w,b,S,M,I,C,T,Ca,Ta),g=ka(C)*S+w,m=Pa(C)*M+b;break;case Sa.R:ya(v=g=p[_++],y=m=p[_++],v+p[_++],y+p[_++],Ca,Ta);break;case Sa.Z:g=v,m=y}_t(Ma,Ma,Ca),xt(Ia,Ia,Ta)}return 0===_&&(Ma[0]=Ma[1]=Ia[0]=Ia[1]=0),new vn(Ma[0],Ma[1],Ia[0]-Ma[0],Ia[1]-Ma[1])},rebuildPath:function(t){for(var e,n,i,r,a,o,s=this.data,l=this._ux,h=this._uy,u=this._len,c=0;c<u;){var d=s[c++];switch(1===c&&(e=i=s[c],n=r=s[c+1]),d){case Sa.M:e=i=s[c++],n=r=s[c++],t.moveTo(i,r);break;case Sa.L:a=s[c++],o=s[c++],(Oa(a-i)>l||Oa(o-r)>h||c===u-1)&&(t.lineTo(a,o),i=a,r=o);break;case Sa.C:t.bezierCurveTo(s[c++],s[c++],s[c++],s[c++],s[c++],s[c++]),i=s[c-2],r=s[c-1];break;case Sa.Q:t.quadraticCurveTo(s[c++],s[c++],s[c++],s[c++]),i=s[c-2],r=s[c-1];break;case Sa.A:var f=s[c++],p=s[c++],g=s[c++],m=s[c++],v=s[c++],y=s[c++],_=s[c++],x=s[c++],w=m<g?g:m,b=m<g?1:g/m,S=m<g?m/g:1,M=v+y;.001<Math.abs(g-m)?(t.translate(f,p),t.rotate(_),t.scale(b,S),t.arc(0,0,w,v,M,1-x),t.scale(1/b,1/S),t.rotate(-_),t.translate(-f,-p)):t.arc(f,p,w,v,M,1-x),1===c&&(e=ka(v)*g+f,n=Pa(v)*m+p),i=ka(M)*g+f,r=Pa(M)*m+p;break;case Sa.R:e=i=s[c],n=r=s[c+1],t.rect(s[c++],s[c++],s[c++],s[c++]);break;case Sa.Z:t.closePath(),i=e,r=n}}}},Ea.CMD=Sa;var Fa=2*Math.PI;function Va(t){return(t%=Fa)<0&&(t+=Fa),t}var Ha=2*Math.PI;function Wa(t,e,n,i,r,a,o,s,l){if(0===o)return!1;var h=o;s-=t,l-=e;var u=Math.sqrt(s*s+l*l);if(n<u-h||u+h<n)return!1;if(Math.abs(i-r)%Ha<1e-4)return!0;if(a){var c=i;i=Va(r),r=Va(c)}else i=Va(i),r=Va(r);r<i&&(r+=Ha);var d=Math.atan2(l,s);return d<0&&(d+=Ha),i<=d&&d<=r||i<=d+Ha&&d+Ha<=r}function Ga(t,e,n,i,r,a){if(e<a&&i<a||a<e&&a<i)return 0;if(i===e)return 0;var o=i<e?1:-1,s=(a-e)/(i-e);1!=s&&0!=s||(o=i<e?.5:-.5);var l=s*(n-t)+t;return l===r?1/0:r<l?o:0}var Za=Ea.CMD,Ua=2*Math.PI,Xa=1e-4;var Ya=[-1,-1,-1],ja=[-1,-1];function qa(t,e,n,i,r,a,o,s,l,h){if(e<h&&i<h&&a<h&&s<h||h<e&&h<i&&h<a&&h<s)return 0;var u,c=function(t,e,n,i,r,a){var o=i+3*(e-n)-t,s=3*(n-2*e+t),l=3*(e-t),h=t-r,u=s*s-3*o*l,c=s*l-9*o*h,d=l*l-3*s*h,f=0;if(Jr(u)&&Jr(c)){if(Jr(s))a[0]=0;else 0<=(M=-l/s)&&M<=1&&(a[f++]=M)}else{var p=c*c-4*u*d;if(Jr(p)){var g=c/u,m=-g/2;0<=(M=-s/o+g)&&M<=1&&(a[f++]=M),0<=m&&m<=1&&(a[f++]=m)}else if(0<p){var v=Ur(p),y=u*s+1.5*o*(-c+v),_=u*s+1.5*o*(-c-v);0<=(M=(-s-((y=y<0?-Zr(-y,qr):Zr(y,qr))+(_=_<0?-Zr(-_,qr):Zr(_,qr))))/(3*o))&&M<=1&&(a[f++]=M)}else{var x=(2*u*s-3*o*c)/(2*Ur(u*u*u)),w=Math.acos(x)/3,b=Ur(u),S=Math.cos(w),M=(-s-2*b*S)/(3*o),I=(m=(-s+b*(S+jr*Math.sin(w)))/(3*o),(-s+b*(S-jr*Math.sin(w)))/(3*o));0<=M&&M<=1&&(a[f++]=M),0<=m&&m<=1&&(a[f++]=m),0<=I&&I<=1&&(a[f++]=I)}}return f}(e,i,a,s,h,Ya);if(0===c)return 0;for(var d,f,p=0,g=-1,m=0;m<c;m++){var v=Ya[m],y=0===v||1===v?.5:1;ea(t,n,r,o,v)<l||(g<0&&(g=ia(e,i,a,s,ja),ja[1]<ja[0]&&1<g&&(void 0,u=ja[0],ja[0]=ja[1],ja[1]=u),d=ea(e,i,a,s,ja[0]),1<g&&(f=ea(e,i,a,s,ja[1]))),2===g?v<ja[0]?p+=d<e?y:-y:v<ja[1]?p+=f<d?y:-y:p+=s<f?y:-y:v<ja[0]?p+=d<e?y:-y:p+=s<d?y:-y)}return p}function $a(t,e,n,i,r,a,o,s){if(e<s&&i<s&&a<s||s<e&&s<i&&s<a)return 0;var l=function(t,e,n,i,r){var a=t-2*e+n,o=2*(e-t),s=t-i,l=0;if(Jr(a)){if(ta(o))0<=(u=-s/o)&&u<=1&&(r[l++]=u)}else{var h=o*o-4*a*s;if(Jr(h))0<=(u=-o/(2*a))&&u<=1&&(r[l++]=u);else if(0<h){var u,c=Ur(h),d=(-o-c)/(2*a);0<=(u=(-o+c)/(2*a))&&u<=1&&(r[l++]=u),0<=d&&d<=1&&(r[l++]=d)}}return l}(e,i,a,s,Ya);if(0===l)return 0;var h=sa(e,i,a);if(0<=h&&h<=1){for(var u=0,c=aa(e,i,a,h),d=0;d<l;d++){var f=0===Ya[d]||1===Ya[d]?.5:1;aa(t,n,r,Ya[d])<o||(Ya[d]<h?u+=c<e?f:-f:u+=a<c?f:-f)}return u}f=0===Ya[0]||1===Ya[0]?.5:1;return aa(t,n,r,Ya[0])<o?0:a<e?f:-f}function Ka(t,e,n,i,r,a,o,s){if(n<(s-=e)||s<-n)return 0;var l=Math.sqrt(n*n-s*s);Ya[0]=-l,Ya[1]=l;var h=Math.abs(i-r);if(h<1e-4)return 0;if(h%Ua<1e-4){r=Ua;var u=a?1:-1;return o>=Ya[i=0]+t&&o<=Ya[1]+t?u:0}if(a){l=i;i=Va(r),r=Va(l)}else i=Va(i),r=Va(r);r<i&&(r+=Ua);for(var c=0,d=0;d<2;d++){var f=Ya[d];if(o<f+t){var p=Math.atan2(s,f);u=a?1:-1;p<0&&(p=Ua+p),(i<=p&&p<=r||i<=p+Ua&&p+Ua<=r)&&(p>Math.PI/2&&p<1.5*Math.PI&&(u=-u),c+=u)}}return c}function Qa(t,e,n,i,r){for(var a=0,o=0,s=0,l=0,h=0,u=0;u<t.length;){var c=t[u++];switch(c===Za.M&&1<u&&(n||(a+=Ga(o,s,l,h,i,r))),1===u&&(l=o=t[u],h=s=t[u+1]),c){case Za.M:o=l=t[u++],s=h=t[u++];break;case Za.L:if(n){if(Na(o,s,t[u],t[u+1],e,i,r))return!0}else a+=Ga(o,s,t[u],t[u+1],i,r)||0;o=t[u++],s=t[u++];break;case Za.C:if(n){if(Ra(o,s,t[u++],t[u++],t[u++],t[u++],t[u],t[u+1],e,i,r))return!0}else a+=qa(o,s,t[u++],t[u++],t[u++],t[u++],t[u],t[u+1],i,r)||0;o=t[u++],s=t[u++];break;case Za.Q:if(n){if(Ba(o,s,t[u++],t[u++],t[u],t[u+1],e,i,r))return!0}else a+=$a(o,s,t[u++],t[u++],t[u],t[u+1],i,r)||0;o=t[u++],s=t[u++];break;case Za.A:var d=t[u++],f=t[u++],p=t[u++],g=t[u++],m=t[u++],v=t[u++];u+=1;var y=1-t[u++],_=Math.cos(m)*p+d,x=Math.sin(m)*g+f;1<u?a+=Ga(o,s,_,x,i,r):(l=_,h=x);var w=(i-d)*g/p+d;if(n){if(Wa(d,f,g,m,m+v,y,e,w,r))return!0}else a+=Ka(d,f,g,m,m+v,y,w,r);o=Math.cos(m+v)*p+d,s=Math.sin(m+v)*g+f;break;case Za.R:l=o=t[u++],h=s=t[u++];_=l+t[u++],x=h+t[u++];if(n){if(Na(l,h,_,h,e,i,r)||Na(_,h,_,x,e,i,r)||Na(_,x,l,x,e,i,r)||Na(l,x,l,h,e,i,r))return!0}else a+=Ga(_,h,_,x,i,r),a+=Ga(l,x,l,h,i,r);break;case Za.Z:if(n){if(Na(o,s,l,h,e,i,r))return!0}else a+=Ga(o,s,l,h,i,r);o=l,s=h}}return n||function(t,e){return Math.abs(t-e)<Xa}(s,h)||(a+=Ga(o,s,l,h,i,r)||0),0!==a}var Ja=Vn.prototype.getCanvasPattern,to=Math.abs,eo=new Ea(!0);function no(t){Vi.call(this,t),this.path=null}no.prototype={constructor:no,type:"path",__dirtyPath:!0,strokeContainThreshold:5,segmentIgnoreThreshold:0,subPixelOptimize:!1,brush:function(t,e){var n,i=this.style,r=this.path||eo,a=i.hasStroke(),o=i.hasFill(),s=i.fill,l=i.stroke,h=o&&!!s.colorStops,u=a&&!!l.colorStops,c=o&&!!s.image,d=a&&!!l.image;i.bind(t,this,e),this.setTransform(t),this.__dirty&&(h&&(n=n||this.getBoundingRect(),this._fillGradient=i.getGradient(t,s,n)),u&&(n=n||this.getBoundingRect(),this._strokeGradient=i.getGradient(t,l,n)));h?t.fillStyle=this._fillGradient:c&&(t.fillStyle=Ja.call(s,t)),u?t.strokeStyle=this._strokeGradient:d&&(t.strokeStyle=Ja.call(l,t));var f=i.lineDash,p=i.lineDashOffset,g=!!t.setLineDash,m=this.getGlobalScale();if(r.setScale(m[0],m[1],this.segmentIgnoreThreshold),this.__dirtyPath||f&&!g&&a?(r.beginPath(t),f&&!g&&(r.setLineDash(f),r.setLineDashOffset(p)),this.buildPath(r,this.shape,!1),this.path&&(this.__dirtyPath=!1)):(t.beginPath(),this.path.rebuildPath(t)),o)if(null!=i.fillOpacity){var v=t.globalAlpha;t.globalAlpha=i.fillOpacity*i.opacity,r.fill(t),t.globalAlpha=v}else r.fill(t);if(f&&g&&(t.setLineDash(f),t.lineDashOffset=p),a)if(null!=i.strokeOpacity){v=t.globalAlpha;t.globalAlpha=i.strokeOpacity*i.opacity,r.stroke(t),t.globalAlpha=v}else r.stroke(t);f&&g&&t.setLineDash([]),null!=i.text&&(this.restoreTransform(t),this.drawRectText(t,this.getBoundingRect()))},buildPath:function(t,e,n){},createPathProxy:function(){this.path=new Ea},getBoundingRect:function(){var t=this._rect,e=this.style,n=!t;if(n){var i=this.path;i=i||(this.path=new Ea),this.__dirtyPath&&(i.beginPath(),this.buildPath(i,this.shape,!1)),t=i.getBoundingRect()}if(this._rect=t,e.hasStroke()){var r=this._rectWithStroke||(this._rectWithStroke=t.clone());if(this.__dirty||n){r.copy(t);var a=e.lineWidth,o=e.strokeNoScale?this.getLineScale():1;e.hasFill()||(a=Math.max(a,this.strokeContainThreshold||4)),1e-10<o&&(r.width+=a/o,r.height+=a/o,r.x-=a/o/2,r.y-=a/o/2)}return r}return t},contain:function(t,e){var n=this.transformCoordToLocal(t,e),i=this.getBoundingRect(),r=this.style;if(t=n[0],e=n[1],i.contain(t,e)){var a=this.path.data;if(r.hasStroke()){var o=r.lineWidth,s=r.strokeNoScale?this.getLineScale():1;if(1e-10<s&&(r.hasFill()||(o=Math.max(o,this.strokeContainThreshold)),function(t,e,n,i){return Qa(t,e,!0,n,i)}(a,o/s,t,e)))return!0}if(r.hasFill())return function(t,e,n){return Qa(t,0,!1,e,n)}(a,t,e)}return!1},dirty:function(t){null==t&&(t=!0),t&&(this.__dirtyPath=t,this._rect=null),this.__dirty=this.__dirtyText=!0,this.__zr&&this.__zr.refresh(),this.__clipTarget&&this.__clipTarget.dirty()},animateShape:function(t){return this.animate("shape",t)},attrKV:function(t,e){"shape"===t?(this.setShape(e),this.__dirtyPath=!0,this._rect=null):Vi.prototype.attrKV.call(this,t,e)},setShape:function(t,e){var n=this.shape;if(n){if(N(t))for(var i in t)t.hasOwnProperty(i)&&(n[i]=t[i]);else n[t]=e;this.dirty(!0)}return this},getLineScale:function(){var t=this.transform;return t&&1e-10<to(t[0]-1)&&1e-10<to(t[3]-1)?Math.sqrt(to(t[0]*t[3]-t[2]*t[1])):1}},no.extend=function(r){function t(t){no.call(this,t),r.style&&this.style.extendFrom(r.style,!1);var e=r.shape;if(e){this.shape=this.shape||{};var n=this.shape;for(var i in e)!n.hasOwnProperty(i)&&e.hasOwnProperty(i)&&(n[i]=e[i])}r.init&&r.init.call(this,t)}for(var e in w(t,no),r)"style"!==e&&"shape"!==e&&(t.prototype[e]=r[e]);return t},w(no,Vi);function io(t){return Math.sqrt(t[0]*t[0]+t[1]*t[1])}var ro=Ea.CMD,ao=[[],[],[]],oo=Math.sqrt,so=Math.atan2,lo=function(t,e){var n,i,r,a,o,s=t.data,l=ro.M,h=ro.C,u=ro.L,c=ro.R,d=ro.A,f=ro.Q;for(a=r=0;r<s.length;){switch(n=s[r++],a=r,i=0,n){case l:case u:i=1;break;case h:i=3;break;case f:i=2;break;case d:var p=e[4],g=e[5],m=oo(e[0]*e[0]+e[1]*e[1]),v=oo(e[2]*e[2]+e[3]*e[3]),y=so(-e[1]/v,e[0]/m);s[r]*=m,s[r++]+=p,s[r]*=v,s[r++]+=g,s[r++]*=m,s[r++]*=v,s[r++]+=y,s[r++]+=y,a=r+=2;break;case c:_[0]=s[r++],_[1]=s[r++],yt(_,_,e),s[a++]=_[0],s[a++]=_[1],_[0]+=s[r++],_[1]+=s[r++],yt(_,_,e),s[a++]=_[0],s[a++]=_[1]}for(o=0;o<i;o++){var _;(_=ao[o])[0]=s[r++],_[1]=s[r++],yt(_,_,e),s[a++]=_[0],s[a++]=_[1]}}},ho=Math.sqrt,uo=Math.sin,co=Math.cos,fo=Math.PI,po=function(t,e){return(t[0]*e[0]+t[1]*e[1])/(io(t)*io(e))},go=function(t,e){return(t[0]*e[1]<t[1]*e[0]?-1:1)*Math.acos(po(t,e))};function mo(t,e,n,i,r,a,o,s,l,h,u){var c=l*(fo/180),d=co(c)*(t-n)/2+uo(c)*(e-i)/2,f=-1*uo(c)*(t-n)/2+co(c)*(e-i)/2,p=d*d/(o*o)+f*f/(s*s);1<p&&(o*=ho(p),s*=ho(p));var g=(r===a?-1:1)*ho((o*o*(s*s)-o*o*(f*f)-s*s*(d*d))/(o*o*(f*f)+s*s*(d*d)))||0,m=g*o*f/s,v=g*-s*d/o,y=(t+n)/2+co(c)*m-uo(c)*v,_=(e+i)/2+uo(c)*m+co(c)*v,x=go([1,0],[(d-m)/o,(f-v)/s]),w=[(d-m)/o,(f-v)/s],b=[(-1*d-m)/o,(-1*f-v)/s],S=go(w,b);po(w,b)<=-1&&(S=fo),1<=po(w,b)&&(S=0),0===a&&0<S&&(S-=2*fo),1===a&&S<0&&(S+=2*fo),u.addData(h,y,_,o,s,x,S,c,a)}var vo=/([mlvhzcqtsa])([^mlvhzcqtsa]*)/gi,yo=/-?([0-9]*\.)?[0-9]+([eE]-?[0-9]+)?/g;function _o(t,e){var n=function(t){if(!t)return new Ea;for(var e,n=0,i=0,r=n,a=i,o=new Ea,s=Ea.CMD,l=t.match(vo),h=0;h<l.length;h++){for(var u,c=l[h],d=c.charAt(0),f=c.match(yo)||[],p=f.length,g=0;g<p;g++)f[g]=parseFloat(f[g]);for(var m=0;m<p;){var v,y,_,x,w,b,S,M=n,I=i;switch(d){case"l":n+=f[m++],i+=f[m++],u=s.L,o.addData(u,n,i);break;case"L":n=f[m++],i=f[m++],u=s.L,o.addData(u,n,i);break;case"m":n+=f[m++],i+=f[m++],u=s.M,o.addData(u,n,i),r=n,a=i,d="l";break;case"M":n=f[m++],i=f[m++],u=s.M,o.addData(u,n,i),r=n,a=i,d="L";break;case"h":n+=f[m++],u=s.L,o.addData(u,n,i);break;case"H":n=f[m++],u=s.L,o.addData(u,n,i);break;case"v":i+=f[m++],u=s.L,o.addData(u,n,i);break;case"V":i=f[m++],u=s.L,o.addData(u,n,i);break;case"C":u=s.C,o.addData(u,f[m++],f[m++],f[m++],f[m++],f[m++],f[m++]),n=f[m-2],i=f[m-1];break;case"c":u=s.C,o.addData(u,f[m++]+n,f[m++]+i,f[m++]+n,f[m++]+i,f[m++]+n,f[m++]+i),n+=f[m-2],i+=f[m-1];break;case"S":v=n,y=i;var C=o.len(),T=o.data;e===s.C&&(v+=n-T[C-4],y+=i-T[C-3]),u=s.C,M=f[m++],I=f[m++],n=f[m++],i=f[m++],o.addData(u,v,y,M,I,n,i);break;case"s":v=n,y=i;C=o.len(),T=o.data;e===s.C&&(v+=n-T[C-4],y+=i-T[C-3]),u=s.C,M=n+f[m++],I=i+f[m++],n+=f[m++],i+=f[m++],o.addData(u,v,y,M,I,n,i);break;case"Q":M=f[m++],I=f[m++],n=f[m++],i=f[m++],u=s.Q,o.addData(u,M,I,n,i);break;case"q":M=f[m++]+n,I=f[m++]+i,n+=f[m++],i+=f[m++],u=s.Q,o.addData(u,M,I,n,i);break;case"T":v=n,y=i;C=o.len(),T=o.data;e===s.Q&&(v+=n-T[C-4],y+=i-T[C-3]),n=f[m++],i=f[m++],u=s.Q,o.addData(u,v,y,n,i);break;case"t":v=n,y=i;C=o.len(),T=o.data;e===s.Q&&(v+=n-T[C-4],y+=i-T[C-3]),n+=f[m++],i+=f[m++],u=s.Q,o.addData(u,v,y,n,i);break;case"A":_=f[m++],x=f[m++],w=f[m++],b=f[m++],S=f[m++],mo(M=n,I=i,n=f[m++],i=f[m++],b,S,_,x,w,u=s.A,o);break;case"a":_=f[m++],x=f[m++],w=f[m++],b=f[m++],S=f[m++],mo(M=n,I=i,n+=f[m++],i+=f[m++],b,S,_,x,w,u=s.A,o)}}"z"!==d&&"Z"!==d||(u=s.Z,o.addData(u),n=r,i=a),e=u}return o.toStatic(),o}(t);return(e=e||{}).buildPath=function(t){if(t.setData){t.setData(n.data),(e=t.getContext())&&t.rebuildPath(e)}else{var e=t;n.rebuildPath(e)}},e.applyTransform=function(t){lo(n,t),this.dirty(!0)},e}function xo(t,e){return new no(_o(t,e))}var wo=function(t){Vi.call(this,t)};wo.prototype={constructor:wo,type:"text",brush:function(t,e){var n=this.style;this.__dirty&&Si(n),n.fill=n.stroke=n.shadowBlur=n.shadowColor=n.shadowOffsetX=n.shadowOffsetY=null;var i=n.text;null!=i&&(i+=""),Ri(i,n)?(this.setTransform(t),Ii(this,t,i,n,null,e),this.restoreTransform(t)):t.__attrCachedBy=Pn.NONE},getBoundingRect:function(){var t=this.style;if(this.__dirty&&Si(t),!this._rect){var e=t.text;null!=e?e+="":e="";var n=ii(t.text+"",t.font,t.textAlign,t.textVerticalAlign,t.textPadding,t.textLineHeight,t.rich);if(n.x+=t.x||0,n.y+=t.y||0,Oi(t.textStroke,t.textStrokeWidth)){var i=t.textStrokeWidth;n.x-=i/2,n.y-=i/2,n.width+=i,n.height+=i}this._rect=n}return this._rect}},w(wo,Vi);function bo(l){return v.browser.ie&&11<=v.browser.version?function(){var t,e=this.__clipPaths,n=this.style;if(e)for(var i=0;i<e.length;i++){var r=e[i],a=r&&r.shape,o=r&&r.type;if(a&&("sector"===o&&a.startAngle===a.endAngle||"rect"===o&&(!a.width||!a.height))){for(var s=0;s<Mo.length;s++)Mo[s][2]=n[Mo[s][0]],n[Mo[s][0]]=Mo[s][1];t=!0;break}}if(l.apply(this,arguments),t)for(s=0;s<Mo.length;s++)n[Mo[s][0]]=Mo[s][2]}:l}var So=no.extend({type:"circle",shape:{cx:0,cy:0,r:0},buildPath:function(t,e,n){n&&t.moveTo(e.cx+e.r,e.cy),t.arc(e.cx,e.cy,e.r,0,2*Math.PI,!0)}}),Mo=[["shadowBlur",0],["shadowColor","#000"],["shadowOffsetX",0],["shadowOffsetY",0]],Io=no.extend({type:"sector",shape:{cx:0,cy:0,r0:0,r:0,startAngle:0,endAngle:2*Math.PI,clockwise:!0},brush:bo(no.prototype.brush),buildPath:function(t,e){var n=e.cx,i=e.cy,r=Math.max(e.r0||0,0),a=Math.max(e.r,0),o=e.startAngle,s=e.endAngle,l=e.clockwise,h=Math.cos(o),u=Math.sin(o);t.moveTo(h*r+n,u*r+i),t.lineTo(h*a+n,u*a+i),t.arc(n,i,a,o,s,!l),t.lineTo(Math.cos(s)*r+n,Math.sin(s)*r+i),0!==r&&t.arc(n,i,r,s,o,l),t.closePath()}}),Co=no.extend({type:"ring",shape:{cx:0,cy:0,r:0,r0:0},buildPath:function(t,e){var n=e.cx,i=e.cy,r=2*Math.PI;t.moveTo(n+e.r,i),t.arc(n,i,e.r,0,r,!1),t.moveTo(n+e.r0,i),t.arc(n,i,e.r0,0,r,!0)}});function To(t,e,n,i,r,a,o){var s=.5*(n-t),l=.5*(i-e);return(2*(e-n)+s+l)*o+(-3*(e-n)-2*s-l)*a+s*r+e}function Ao(t,e,n){var i=e.points,r=e.smooth;if(i&&2<=i.length){if(r&&"spline"!==r){var a=function(t,e,n,i){var r,a,o,s,l=[],h=[],u=[],c=[];if(i){o=[1/0,1/0],s=[-1/0,-1/0];for(var d=0,f=t.length;d<f;d++)_t(o,o,t[d]),xt(s,s,t[d]);_t(o,o,i[0]),xt(s,s,i[1])}for(d=0,f=t.length;d<f;d++){var p=t[d];if(n)r=t[d?d-1:f-1],a=t[(d+1)%f];else{if(0===d||d===f-1){l.push(rt(t[d]));continue}r=t[d-1],a=t[d+1]}st(h,a,r),dt(h,h,e);var g=pt(p,r),m=pt(p,a),v=g+m;0!==v&&(g/=v,m/=v),dt(u,h,-g),dt(c,h,m);var y=at([],p,u),_=at([],p,c);i&&(xt(y,y,o),_t(y,y,s),xt(_,_,o),_t(_,_,s)),l.push(y),l.push(_)}return n&&l.push(l.shift()),l}(i,r,n,e.smoothConstraint);t.moveTo(i[0][0],i[0][1]);for(var o=i.length,s=0;s<(n?o:o-1);s++){var l=a[2*s],h=a[2*s+1],u=i[(s+1)%o];t.bezierCurveTo(l[0],l[1],h[0],h[1],u[0],u[1])}}else{"spline"===r&&(i=function(t,e){for(var n=t.length,i=[],r=0,a=1;a<n;a++)r+=pt(t[a-1],t[a]);var o=r/2;o=o<n?n:o;for(a=0;a<o;a++){var s,l,h,u=a/(o-1)*(e?n:n-1),c=Math.floor(u),d=u-c,f=t[c%n];h=e?(s=t[(c-1+n)%n],l=t[(c+1)%n],t[(c+2)%n]):(s=t[0===c?c:c-1],l=t[n-2<c?n-1:c+1],t[n-3<c?n-1:c+2]);var p=d*d,g=d*p;i.push([To(s[0],f[0],l[0],h[0],d,p,g),To(s[1],f[1],l[1],h[1],d,p,g)])}return i}(i,n)),t.moveTo(i[0][0],i[0][1]);s=1;for(var c=i.length;s<c;s++)t.lineTo(i[s][0],i[s][1])}n&&t.closePath()}}var Do=no.extend({type:"polygon",shape:{points:null,smooth:!1,smoothConstraint:null},buildPath:function(t,e){Ao(t,e,!0)}}),ko=no.extend({type:"polyline",shape:{points:null,smooth:!1,smoothConstraint:null},style:{stroke:"#000",fill:null},buildPath:function(t,e){Ao(t,e,!1)}}),Po=Math.round;function Lo(t,e,n){var i=n&&n.lineWidth;if(e&&i){var r=e.x1,a=e.x2,o=e.y1,s=e.y2;Po(2*r)===Po(2*a)?t.x1=t.x2=zo(r,i,!0):(t.x1=r,t.x2=a),Po(2*o)===Po(2*s)?t.y1=t.y2=zo(o,i,!0):(t.y1=o,t.y2=s)}}function Oo(t,e,n){var i=n&&n.lineWidth;if(e&&i){var r=e.x,a=e.y,o=e.width,s=e.height;t.x=zo(r,i,!0),t.y=zo(a,i,!0),t.width=Math.max(zo(r+o,i,!1)-t.x,0===o?0:1),t.height=Math.max(zo(a+s,i,!1)-t.y,0===s?0:1)}}function zo(t,e,n){var i=Po(2*t);return(i+Po(e))%2==0?i/2:(i+(n?1:-1))/2}var Eo={},No=no.extend({type:"rect",shape:{r:0,x:0,y:0,width:0,height:0},buildPath:function(t,e){var n,i,r,a;this.subPixelOptimize?(Oo(Eo,e,this.style),n=Eo.x,i=Eo.y,r=Eo.width,a=Eo.height,Eo.r=e.r,e=Eo):(n=e.x,i=e.y,r=e.width,a=e.height),e.r?mi(t,e):t.rect(n,i,r,a),t.closePath()}}),Ro={},Bo=no.extend({type:"line",shape:{x1:0,y1:0,x2:0,y2:0,percent:1},style:{stroke:"#000",fill:null},buildPath:function(t,e){var n,i,r,a;a=this.subPixelOptimize?(Lo(Ro,e,this.style),n=Ro.x1,i=Ro.y1,r=Ro.x2,Ro.y2):(n=e.x1,i=e.y1,r=e.x2,e.y2);var o=e.percent;0!==o&&(t.moveTo(n,i),o<1&&(r=n*(1-o)+r*o,a=i*(1-o)+a*o),t.lineTo(r,a))},pointAt:function(t){var e=this.shape;return[e.x1*(1-t)+e.x2*t,e.y1*(1-t)+e.y2*t]}}),Fo=[];function Vo(t,e,n){var i=t.cpx2,r=t.cpy2;return null===i||null===r?[(n?na:ea)(t.x1,t.cpx1,t.cpx2,t.x2,e),(n?na:ea)(t.y1,t.cpy1,t.cpy2,t.y2,e)]:[(n?oa:aa)(t.x1,t.cpx1,t.x2,e),(n?oa:aa)(t.y1,t.cpy1,t.y2,e)]}function Ho(t){this.colorStops=t||[]}var Wo=no.extend({type:"bezier-curve",shape:{x1:0,y1:0,x2:0,y2:0,cpx1:0,cpy1:0,percent:1},style:{stroke:"#000",fill:null},buildPath:function(t,e){var n=e.x1,i=e.y1,r=e.x2,a=e.y2,o=e.cpx1,s=e.cpy1,l=e.cpx2,h=e.cpy2,u=e.percent;0!==u&&(t.moveTo(n,i),null==l||null==h?(u<1&&(la(n,o,r,u,Fo),o=Fo[1],r=Fo[2],la(i,s,a,u,Fo),s=Fo[1],a=Fo[2]),t.quadraticCurveTo(o,s,r,a)):(u<1&&(ra(n,o,l,r,u,Fo),o=Fo[1],l=Fo[2],r=Fo[3],ra(i,s,h,a,u,Fo),s=Fo[1],h=Fo[2],a=Fo[3]),t.bezierCurveTo(o,s,l,h,r,a)))},pointAt:function(t){return Vo(this.shape,t,!1)},tangentAt:function(t){var e=Vo(this.shape,t,!0);return ft(e,e)}}),Go=no.extend({type:"arc",shape:{cx:0,cy:0,r:0,startAngle:0,endAngle:2*Math.PI,clockwise:!0},style:{stroke:"#000",fill:null},buildPath:function(t,e){var n=e.cx,i=e.cy,r=Math.max(e.r,0),a=e.startAngle,o=e.endAngle,s=e.clockwise,l=Math.cos(a),h=Math.sin(a);t.moveTo(l*r+n,h*r+i),t.arc(n,i,r,a,o,!s)}}),Zo=no.extend({type:"compound",shape:{paths:null},_updatePathDirty:function(){for(var t=this.__dirtyPath,e=this.shape.paths,n=0;n<e.length;n++)t=t||e[n].__dirtyPath;this.__dirtyPath=t,this.__dirty=this.__dirty||t},beforeBrush:function(){this._updatePathDirty();for(var t=this.shape.paths||[],e=this.getGlobalScale(),n=0;n<t.length;n++)t[n].path||t[n].createPathProxy(),t[n].path.setScale(e[0],e[1],t[n].segmentIgnoreThreshold)},buildPath:function(t,e){for(var n=e.paths||[],i=0;i<n.length;i++)n[i].buildPath(t,n[i].shape,!0)},afterBrush:function(){for(var t=this.shape.paths||[],e=0;e<t.length;e++)t[e].__dirtyPath=!1},getBoundingRect:function(){return this._updatePathDirty(),no.prototype.getBoundingRect.call(this)}});Ho.prototype={constructor:Ho,addColorStop:function(t,e){this.colorStops.push({offset:t,color:e})}};function Uo(t,e,n,i,r,a){this.x=null==t?0:t,this.y=null==e?0:e,this.x2=null==n?1:n,this.y2=null==i?0:i,this.type="linear",this.global=a||!1,Ho.call(this,r)}Uo.prototype={constructor:Uo},w(Uo,Ho);function Xo(t,e,n,i,r){this.x=null==t?.5:t,this.y=null==e?.5:e,this.r=null==n?.5:n,this.type="radial",this.global=r||!1,Ho.call(this,i)}function Yo(t){Vi.call(this,t),this._displayables=[],this._temporaryDisplayables=[],this._cursor=0,this.notClear=!0}Xo.prototype={constructor:Xo},w(Xo,Ho),Yo.prototype.incremental=!0,Yo.prototype.clearDisplaybles=function(){this._displayables=[],this._temporaryDisplayables=[],this._cursor=0,this.dirty(),this.notClear=!1},Yo.prototype.addDisplayable=function(t,e){e?this._temporaryDisplayables.push(t):this._displayables.push(t),this.dirty()},Yo.prototype.addDisplayables=function(t,e){e=e||!1;for(var n=0;n<t.length;n++)this.addDisplayable(t[n],e)},Yo.prototype.eachPendingDisplayable=function(t){for(var e=this._cursor;e<this._displayables.length;e++)t&&t(this._displayables[e]);for(e=0;e<this._temporaryDisplayables.length;e++)t&&t(this._temporaryDisplayables[e])},Yo.prototype.update=function(){this.updateTransform();for(var t=this._cursor;t<this._displayables.length;t++){(e=this._displayables[t]).parent=this,e.update(),e.parent=null}for(t=0;t<this._temporaryDisplayables.length;t++){var e;(e=this._temporaryDisplayables[t]).parent=this,e.update(),e.parent=null}},Yo.prototype.brush=function(t,e){for(var n=this._cursor;n<this._displayables.length;n++){(i=this._displayables[n]).beforeBrush&&i.beforeBrush(t),i.brush(t,n===this._cursor?null:this._displayables[n-1]),i.afterBrush&&i.afterBrush(t)}this._cursor=n;for(n=0;n<this._temporaryDisplayables.length;n++){var i;(i=this._temporaryDisplayables[n]).beforeBrush&&i.beforeBrush(t),i.brush(t,0===n?null:this._temporaryDisplayables[n-1]),i.afterBrush&&i.afterBrush(t)}this._temporaryDisplayables=[],this.notClear=!0};var jo=[];Yo.prototype.getBoundingRect=function(){if(!this._rect){for(var t=new vn(1/0,1/0,-1/0,-1/0),e=0;e<this._displayables.length;e++){var n=this._displayables[e],i=n.getBoundingRect().clone();n.needLocalTransform()&&i.applyTransform(n.getLocalTransform(jo)),t.union(i)}this._rect=t}return this._rect},Yo.prototype.contain=function(t,e){var n=this.transformCoordToLocal(t,e);if(this.getBoundingRect().contain(n[0],n[1]))for(var i=0;i<this._displayables.length;i++){if(this._displayables[i].contain(t,e))return!0}return!1},w(Yo,Vi);var qo=Math.max,$o=Math.min,Ko={},Qo=1,Jo="emphasis",ts="normal",es=1,ns={};function is(t){return no.extend(t)}function rs(t,e,n,i){var r=xo(t,e);return n&&("center"===i&&(n=os(n,r.getBoundingRect())),ls(r,n)),r}function as(t,n,i){var r=new Hi({style:{image:t,x:n.x,y:n.y,width:n.width,height:n.height},onload:function(t){if("center"===i){var e={width:t.width,height:t.height};r.setStyle(os(n,e))}}});return r}function os(t,e){var n,i=e.width/e.height,r=t.height*i;return n=r<=t.width?t.height:(r=t.width)/i,{x:t.x+t.width/2-r/2,y:t.y+t.height/2-n/2,width:r,height:n}}function ss(t,e){for(var n=[],i=t.length,r=0;r<i;r++){var a=t[r];a.path||a.createPathProxy(),a.__dirtyPath&&a.buildPath(a.path,a.shape,!0),n.push(a.path)}var o=new no(e);return o.createPathProxy(),o.buildPath=function(t){t.appendPath(n);var e=t.getContext();e&&t.rebuildPath(e)},o}function ls(t,e){if(t.applyTransform){var n=t.getBoundingRect().calculateTransform(e);t.applyTransform(n)}}var hs=zo;function us(t){return null!=t&&"none"!==t}var cs=Q(),ds=0;function fs(t){var e=t.__hoverStl;if(e&&!t.__highlighted){var n=t.useHoverLayer;t.__highlighted=n?"layer":"plain";var i=t.__zr;if(!(t.isGroup||!i&&n)){var r=t,a=t.style;n&&(a=(r=i.addHover(t)).style),Os(a),n||function(t){if(t.__hoverStlDirty){t.__hoverStlDirty=!1;var e=t.__hoverStl;if(e){var n=t.__cachedNormalStl={};t.__cachedNormalZ2=t.z2;var i=t.style;for(var r in e)null!=e[r]&&(n[r]=i[r]);n.fill=i.fill,n.stroke=i.stroke}else t.__cachedNormalStl=t.__cachedNormalZ2=null}}(r),a.extendFrom(e),ps(a,e,"fill"),ps(a,e,"stroke"),Ls(a),n||(t.dirty(!1),t.z2+=Qo)}}}function ps(t,e,n){!us(e[n])&&us(t[n])&&(t[n]=function(t){if("string"!=typeof t)return t;var e=cs.get(t);return e||(e=Le(t,-.1),ds<1e4&&(cs.set(t,e),ds++)),e}(t[n]))}function gs(t){var e=t.__highlighted;if(e&&(t.__highlighted=!1,!t.isGroup))if("layer"===e)t.__zr&&t.__zr.removeHover(t);else{var n=t.style,i=t.__cachedNormalStl;i&&(Os(n),t.setStyle(i),Ls(n));var r=t.__cachedNormalZ2;null!=r&&t.z2-r===Qo&&(t.z2=r)}}function ms(t,e,n){var i,r=ts,a=ts;t.__highlighted&&(r=Jo,i=!0),e(t,n),t.__highlighted&&(a=Jo,i=!0),t.isGroup&&t.traverse(function(t){t.isGroup||e(t,n)}),i&&t.__highDownOnUpdate&&t.__highDownOnUpdate(r,a)}function vs(t,e){e=t.__hoverStl=!1!==e&&(t.hoverStyle||e||{}),t.__hoverStlDirty=!0,t.__highlighted&&(t.__cachedNormalStl=null,gs(t),fs(t))}function ys(t){bs(this,t)||this.__highByOuter||ms(this,fs)}function _s(t){bs(this,t)||this.__highByOuter||ms(this,gs)}function xs(t){this.__highByOuter|=1<<(t||0),ms(this,fs)}function ws(t){(this.__highByOuter&=~(1<<(t||0)))||ms(this,gs)}function bs(t,e){return t.__highDownSilentOnTouch&&e.zrByTouch}function Ss(t,e){Ms(t,!0),ms(t,vs,e)}function Ms(t,e){var n=!1===e;if(t.__highDownSilentOnTouch=t.highDownSilentOnTouch,t.__highDownOnUpdate=t.highDownOnUpdate,!n||t.__highDownDispatcher){var i=n?"off":"on";t[i]("mouseover",ys)[i]("mouseout",_s),t[i]("emphasis",xs)[i]("normal",ws),t.__highByOuter=t.__highByOuter||0,t.__highDownDispatcher=!n}}function Is(t){return!(!t||!t.__highDownDispatcher)}function Cs(t){var e=ns[t];return null==e&&es<=32&&(e=ns[t]=es++),e}function Ts(t,e,n,i,r,a,o){var s,l=(r=r||Ko).labelFetcher,h=r.labelDataIndex,u=r.labelDimIndex,c=n.getShallow("show"),d=i.getShallow("show");(c||d)&&(l&&(s=l.getFormattedLabel(h,"normal",null,u)),null==s&&(s=z(r.defaultText)?r.defaultText(h,r):r.defaultText));var f=c?s:null,p=d?W(l?l.getFormattedLabel(h,"emphasis",null,u):null,s):null;null==f&&null==p||(As(t,n,a,r),As(e,i,o,r,!0)),t.text=f,e.text=p}function As(t,e,n,i,r){return Ds(t,e,i,r),n&&I(t,n),t}function Ds(t,e,n,i){if((n=n||Ko).isRectText){var r=e.getShallow("position")||(i?null:"inside");"outside"===r&&(r="top"),t.textPosition=r,t.textOffset=e.getShallow("offset");var a=e.getShallow("rotate");null!=a&&(a*=Math.PI/180),t.textRotation=a,t.textDistance=W(e.getShallow("distance"),i?null:5)}var o,s=e.ecModel,l=s&&s.option.textStyle,h=function(t){var e;for(;t&&t!==t.ecModel;){var n=(t.option||Ko).rich;if(n)for(var i in e=e||{},n)n.hasOwnProperty(i)&&(e[i]=1);t=t.parentModel}return e}(e);if(h)for(var u in o={},h)if(h.hasOwnProperty(u)){var c=e.getModel(["rich",u]);ks(o[u]={},c,l,n,i)}return t.rich=o,ks(t,e,l,n,i,!0),n.forceRich&&!n.textStyle&&(n.textStyle={}),t}function ks(t,e,n,i,r,a){n=!r&&n||Ko,t.textFill=Ps(e.getShallow("color"),i)||n.color,t.textStroke=Ps(e.getShallow("textBorderColor"),i)||n.textBorderColor,t.textStrokeWidth=W(e.getShallow("textBorderWidth"),n.textBorderWidth),r||(a&&(t.insideRollbackOpt=i,Ls(t)),null==t.textFill&&(t.textFill=i.autoColor)),t.fontStyle=e.getShallow("fontStyle")||n.fontStyle,t.fontWeight=e.getShallow("fontWeight")||n.fontWeight,t.fontSize=e.getShallow("fontSize")||n.fontSize,t.fontFamily=e.getShallow("fontFamily")||n.fontFamily,t.textAlign=e.getShallow("align"),t.textVerticalAlign=e.getShallow("verticalAlign")||e.getShallow("baseline"),t.textLineHeight=e.getShallow("lineHeight"),t.textWidth=e.getShallow("width"),t.textHeight=e.getShallow("height"),t.textTag=e.getShallow("tag"),a&&i.disableBox||(t.textBackgroundColor=Ps(e.getShallow("backgroundColor"),i),t.textPadding=e.getShallow("padding"),t.textBorderColor=Ps(e.getShallow("borderColor"),i),t.textBorderWidth=e.getShallow("borderWidth"),t.textBorderRadius=e.getShallow("borderRadius"),t.textBoxShadowColor=e.getShallow("shadowColor"),t.textBoxShadowBlur=e.getShallow("shadowBlur"),t.textBoxShadowOffsetX=e.getShallow("shadowOffsetX"),t.textBoxShadowOffsetY=e.getShallow("shadowOffsetY")),t.textShadowColor=e.getShallow("textShadowColor")||n.textShadowColor,t.textShadowBlur=e.getShallow("textShadowBlur")||n.textShadowBlur,t.textShadowOffsetX=e.getShallow("textShadowOffsetX")||n.textShadowOffsetX,t.textShadowOffsetY=e.getShallow("textShadowOffsetY")||n.textShadowOffsetY}function Ps(t,e){return"auto"!==t?t:e&&e.autoColor?e.autoColor:null}function Ls(t){var e,n=t.textPosition,i=t.insideRollbackOpt;if(i&&null==t.textFill){var r=i.autoColor,a=i.isRectText,o=i.useInsideStyle,s=!1!==o&&(!0===o||a&&n&&"string"==typeof n&&0<=n.indexOf("inside")),l=!s&&null!=r;(s||l)&&(e={textFill:t.textFill,textStroke:t.textStroke,textStrokeWidth:t.textStrokeWidth}),s&&(t.textFill="#fff",null==t.textStroke&&(t.textStroke=r,null==t.textStrokeWidth&&(t.textStrokeWidth=2))),l&&(t.textFill=r)}t.insideRollback=e}function Os(t){var e=t.insideRollback;e&&(t.textFill=e.textFill,t.textStroke=e.textStroke,t.textStrokeWidth=e.textStrokeWidth,t.insideRollback=null)}function zs(t,e){var n=e||e.getModel("textStyle");return Y([t.fontStyle||n&&n.getShallow("fontStyle")||"",t.fontWeight||n&&n.getShallow("fontWeight")||"",(t.fontSize||n&&n.getShallow("fontSize")||12)+"px",t.fontFamily||n&&n.getShallow("fontFamily")||"sans-serif"].join(" "))}function Es(t,e,n,i,r,a){if("function"==typeof r&&(a=r,r=null),i&&i.isAnimationEnabled()){var o=t?"Update":"",s=i.getShallow("animationDuration"+o),l=i.getShallow("animationEasing"+o),h=i.getShallow("animationDelay"+o);"function"==typeof h&&(h=h(r,i.getAnimationDelayParams?i.getAnimationDelayParams(e,r):null)),"function"==typeof s&&(s=s(r)),0<s?e.animateTo(n,s,h||0,l,a,!!a):(e.stopAnimation(),e.attr(n),a&&a())}else e.stopAnimation(),e.attr(n),a&&a()}function Ns(t,e,n,i,r){Es(!0,t,e,n,i,r)}function Rs(t,e,n,i,r){Es(!1,t,e,n,i,r)}function Bs(t,e){for(var n=$t([]);t&&t!==e;)Qt(n,t.getLocalTransform(),n),t=t.parent;return n}function Fs(t,e,n){return e&&!L(e)&&(e=oe.getLocalTransform(e)),n&&(e=ne([],e)),yt([],t,e)}function Vs(t,e,n){var i=0===e[4]||0===e[5]||0===e[0]?1:Math.abs(2*e[4]/e[0]),r=0===e[4]||0===e[5]||0===e[2]?1:Math.abs(2*e[4]/e[2]),a=["left"===t?-i:"right"===t?i:0,"top"===t?-r:"bottom"===t?r:0];return a=Fs(a,e,n),Math.abs(a[0])>Math.abs(a[1])?0<a[0]?"right":"left":0<a[1]?"bottom":"top"}function Hs(t,e,i,n){if(t&&e){var r,a=(r={},t.traverse(function(t){!t.isGroup&&t.anid&&(r[t.anid]=t)}),r);e.traverse(function(t){if(!t.isGroup&&t.anid){var e=a[t.anid];if(e){var n=o(t);t.attr(o(e)),Ns(t,n,i,t.dataIndex)}}})}function o(t){var e={position:rt(t.position),rotation:t.rotation};return t.shape&&(e.shape=I({},t.shape)),e}}function Ws(t,i){return D(t,function(t){var e=t[0];e=qo(e,i.x),e=$o(e,i.x+i.width);var n=t[1];return n=qo(n,i.y),[e,n=$o(n,i.y+i.height)]})}function Gs(t,e,n){var i=(e=I({rectHover:!0},e)).style={strokeNoScale:!0};if(n=n||{x:-1,y:-1,width:2,height:2},t)return 0===t.indexOf("image://")?(i.image=t.slice(8),T(i,n),new Hi(e)):rs(t.replace("path://",""),e,n,"center")}var Zs=(Object.freeze||Object)({Z2_EMPHASIS_LIFT:Qo,CACHED_LABEL_STYLE_PROPERTIES:{color:"textFill",textBorderColor:"textStroke",textBorderWidth:"textStrokeWidth"},extendShape:is,extendPath:function(t,e){return function(t,e){return no.extend(_o(t,e))}(t,e)},makePath:rs,makeImage:as,mergePath:ss,resizePath:ls,subPixelOptimizeLine:function(t){return Lo(t.shape,t.shape,t.style),t},subPixelOptimizeRect:function(t){return Oo(t.shape,t.shape,t.style),t},subPixelOptimize:hs,setElementHoverStyle:vs,setHoverStyle:Ss,setAsHighDownDispatcher:Ms,isHighDownDispatcher:Is,getHighlightDigit:Cs,setLabelStyle:Ts,modifyLabelStyle:function(t,e,n){var i=t.style;e&&(Os(i),t.setStyle(e),Ls(i)),i=t.__hoverStl,n&&i&&(Os(i),I(i,n),Ls(i))},setTextStyle:As,setText:function(t,e,n){var i,r={isRectText:!0};!1===n?i=!0:r.autoColor=n,Ds(t,e,r,i)},getFont:zs,updateProps:Ns,initProps:Rs,getTransform:Bs,applyTransform:Fs,transformDirection:Vs,groupTransition:Hs,clipPointsByRect:Ws,clipRectByRect:function(t,e){var n=qo(t.x,e.x),i=$o(t.x+t.width,e.x+e.width),r=qo(t.y,e.y),a=$o(t.y+t.height,e.y+e.height);if(n<=i&&r<=a)return{x:n,y:r,width:i-n,height:a-r}},createIcon:Gs,Group:yn,Image:Hi,Text:wo,Circle:So,Sector:Io,Ring:Co,Polygon:Do,Polyline:ko,Rect:No,Line:Bo,BezierCurve:Wo,Arc:Go,IncrementalDisplayable:Yo,CompoundPath:Zo,LinearGradient:Uo,RadialGradient:Xo,BoundingRect:vn}),Us=["textStyle","color"],Xs={getTextColor:function(t){var e=this.ecModel;return this.getShallow("color")||(!t&&e?e.get(Us):null)},getFont:function(){return zs({fontStyle:this.getShallow("fontStyle"),fontWeight:this.getShallow("fontWeight"),fontSize:this.getShallow("fontSize"),fontFamily:this.getShallow("fontFamily")},this.ecModel)},getTextRect:function(t){return ii(t,this.getFont(),this.getShallow("align"),this.getShallow("verticalAlign")||this.getShallow("baseline"),this.getShallow("padding"),this.getShallow("lineHeight"),this.getShallow("rich"),this.getShallow("truncateText"))}},Ys=Fr([["fill","color"],["stroke","borderColor"],["lineWidth","borderWidth"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"],["textPosition"],["textAlign"]]),js={getItemStyle:function(t,e){var n=Ys(this,t,e),i=this.getBorderLineDash();return i&&(n.lineDash=i),n},getBorderLineDash:function(){var t=this.get("borderType");return"solid"===t||null==t?null:"dashed"===t?[5,5]:[1,1]}},qs=S,$s=Mr();function Ks(t,e,n){this.parentModel=e,this.ecModel=n,this.option=t}function Qs(t,e,n){for(var i=0;i<e.length&&(!e[i]||null!=(t=t&&"object"==typeof t?t[e[i]]:null));i++);return null==t&&n&&(t=n.get(e)),t}function Js(t,e){var n=$s(t).getParent;return n?n.call(t,e):t.parentModel}Ks.prototype={constructor:Ks,init:null,mergeOption:function(t){m(this.option,t,!0)},get:function(t,e){return null==t?this.option:Qs(this.option,this.parsePath(t),!e&&Js(this,t))},getShallow:function(t,e){var n=this.option,i=null==n?n:n[t],r=!e&&Js(this,t);return null==i&&r&&(i=r.getShallow(t)),i},getModel:function(t,e){var n;return new Ks(null==t?this.option:Qs(this.option,t=this.parsePath(t)),e=e||(n=Js(this,t))&&n.getModel(t),this.ecModel)},isEmpty:function(){return null==this.option},restoreData:function(){},clone:function(){return new this.constructor(b(this.option))},setReadOnly:function(t){},parsePath:function(t){return"string"==typeof t&&(t=t.split(".")),t},customizeGetParent:function(t){$s(this).getParent=t},isAnimationEnabled:function(){if(!v.node){if(null!=this.option.animation)return!!this.option.animation;if(this.parentModel)return this.parentModel.isAnimationEnabled()}}},Or(Ks),Er(Ks),qs(Ks,Hr),qs(Ks,Gr),qs(Ks,Xs),qs(Ks,js);var tl=0;function el(t){return[t||"",tl++,Math.random().toFixed(5)].join("_")}var nl=1e-4;function il(t,e,n,i){var r=e[1]-e[0],a=n[1]-n[0];if(0==r)return 0==a?n[0]:(n[0]+n[1])/2;if(i)if(0<r){if(t<=e[0])return n[0];if(t>=e[1])return n[1]}else{if(t>=e[0])return n[0];if(t<=e[1])return n[1]}else{if(t===e[0])return n[0];if(t===e[1])return n[1]}return(t-e[0])/r*a+n[0]}function rl(t,e){switch(t){case"center":case"middle":t="50%";break;case"left":case"top":t="0%";break;case"right":case"bottom":t="100%"}return"string"==typeof t?function(t){return t.replace(/^\s+/,"").replace(/\s+$/,"")}(t).match(/%$/)?parseFloat(t)/100*e:parseFloat(t):null==t?NaN:+t}function al(t,e,n){return null==e&&(e=10),e=Math.min(Math.max(0,e),20),t=(+t).toFixed(e),n?t:+t}function ol(t){return t.sort(function(t,e){return t-e}),t}function sl(t){if(t=+t,isNaN(t))return 0;for(var e=1,n=0;Math.round(t*e)/e!==t;)e*=10,n++;return n}function ll(t){var e=t.toString(),n=e.indexOf("e");if(0<n){var i=+e.slice(n+1);return i<0?-i:0}var r=e.indexOf(".");return r<0?0:e.length-1-r}function hl(t,e){var n=Math.log,i=Math.LN10,r=Math.floor(n(t[1]-t[0])/i),a=Math.round(n(Math.abs(e[1]-e[0]))/i),o=Math.min(Math.max(-r+a,0),20);return isFinite(o)?o:20}function ul(t,e,n){if(!t[e])return 0;var i=M(t,function(t,e){return t+(isNaN(e)?0:e)},0);if(0===i)return 0;for(var r=Math.pow(10,n),a=D(t,function(t){return(isNaN(t)?0:t)/i*r*100}),o=100*r,s=D(a,function(t){return Math.floor(t)}),l=M(s,function(t,e){return t+e},0),h=D(a,function(t,e){return t-s[e]});l<o;){for(var u=Number.NEGATIVE_INFINITY,c=null,d=0,f=h.length;d<f;++d)h[d]>u&&(u=h[d],c=d);++s[c],h[c]=0,++l}return s[e]/r}function cl(t){var e=2*Math.PI;return(t%e+e)%e}function dl(t){return-nl<t&&t<nl}var fl=/^(?:(\d{4})(?:[-\/](\d{1,2})(?:[-\/](\d{1,2})(?:[T ](\d{1,2})(?::(\d\d)(?::(\d\d)(?:[.,](\d+))?)?)?(Z|[\+\-]\d\d:?\d\d)?)?)?)?)?$/;function pl(t){if(t instanceof Date)return t;if("string"!=typeof t)return null==t?new Date(NaN):new Date(Math.round(t));var e=fl.exec(t);if(!e)return new Date(NaN);if(e[8]){var n=+e[4]||0;return"Z"!==e[8].toUpperCase()&&(n-=e[8].slice(0,3)),new Date(Date.UTC(+e[1],+(e[2]||1)-1,+e[3]||1,n,+(e[5]||0),+e[6]||0,+e[7]||0))}return new Date(+e[1],+(e[2]||1)-1,+e[3]||1,+e[4]||0,+(e[5]||0),+e[6]||0,+e[7]||0)}function gl(t){return Math.pow(10,ml(t))}function ml(t){return Math.floor(Math.log(t)/Math.LN10)}function vl(t,e){var n=ml(t),i=Math.pow(10,n),r=t/i;return t=(e?r<1.5?1:r<2.5?2:r<4?3:r<7?5:10:r<1?1:r<2?2:r<3?3:r<5?5:10)*i,-20<=n?+t.toFixed(n<0?-n:0):t}var yl=(Object.freeze||Object)({linearMap:il,parsePercent:rl,round:al,asc:ol,getPrecision:sl,getPrecisionSafe:ll,getPixelPrecision:hl,getPercentWithPrecision:ul,MAX_SAFE_INTEGER:9007199254740991,remRadian:cl,isRadianAroundZero:dl,parseDate:pl,quantity:gl,nice:vl,quantile:function(t,e){var n=(t.length-1)*e+1,i=Math.floor(n),r=+t[i-1],a=n-i;return a?r+a*(t[i]-r):r},reformIntervals:function(t){t.sort(function(t,e){return function t(e,n,i){return e.interval[i]<n.interval[i]||e.interval[i]===n.interval[i]&&(e.close[i]-n.close[i]==(i?-1:1)||!i&&t(e,n,1))}(t,e,0)?-1:1});for(var e=-1/0,n=1,i=0;i<t.length;){for(var r=t[i].interval,a=t[i].close,o=0;o<2;o++)r[o]<=e&&(r[o]=e,a[o]=o?1:1-n),e=r[o],n=a[o];r[0]===r[1]&&a[0]*a[1]!=1?t.splice(i,1):i++}return t},isNumeric:function(t){return 0<=t-parseFloat(t)}});function _l(t){return isNaN(t)?"-":(t=(t+"").split("."))[0].replace(/(\d{1,3})(?=(?:\d{3})+(?!\d))/g,"$1,")+(1<t.length?"."+t[1]:"")}function xl(t,e){return t=(t||"").toLowerCase().replace(/-(.)/g,function(t,e){return e.toUpperCase()}),e&&t&&(t=t.charAt(0).toUpperCase()+t.slice(1)),t}var wl=U,bl=/([&<>"'])/g,Sl={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"};function Ml(t){return null==t?"":(t+"").replace(bl,function(t,e){return Sl[e]})}function Il(t,e){return"{"+t+(null==e?"":e)+"}"}var Cl=["a","b","c","d","e","f","g"];function Tl(t,e,n){O(e)||(e=[e]);var i=e.length;if(!i)return"";for(var r=e[0].$vars||[],a=0;a<r.length;a++){var o=Cl[a];t=t.replace(Il(o),Il(o,0))}for(var s=0;s<i;s++)for(var l=0;l<r.length;l++){var h=e[s][r[l]];t=t.replace(Il(Cl[l],s),n?Ml(h):h)}return t}function Al(t,e){var n=(t=E(t)?{color:t,extraCssText:e}:t||{}).color,i=t.type,r=(e=t.extraCssText,t.renderMode||"html"),a=t.markerId||"X";return n?"html"===r?"subItem"===i?'<span style="display:inline-block;vertical-align:middle;margin-right:8px;margin-left:3px;border-radius:4px;width:4px;height:4px;background-color:'+Ml(n)+";"+(e||"")+'"></span>':'<span style="display:inline-block;margin-right:5px;border-radius:10px;width:10px;height:10px;background-color:'+Ml(n)+";"+(e||"")+'"></span>':{renderMode:r,content:"{marker"+a+"|}  ",style:{color:n}}:""}function Dl(t,e){return"0000".substr(0,e-(t+="").length)+t}function kl(t,e,n){"week"!==t&&"month"!==t&&"quarter"!==t&&"half-year"!==t&&"year"!==t||(t="MM-dd\nyyyy");var i=pl(e),r=n?"UTC":"",a=i["get"+r+"FullYear"](),o=i["get"+r+"Month"]()+1,s=i["get"+r+"Date"](),l=i["get"+r+"Hours"](),h=i["get"+r+"Minutes"](),u=i["get"+r+"Seconds"](),c=i["get"+r+"Milliseconds"]();return t=t.replace("MM",Dl(o,2)).replace("M",o).replace("yyyy",a).replace("yy",a%100).replace("dd",Dl(s,2)).replace("d",s).replace("hh",Dl(l,2)).replace("h",l).replace("mm",Dl(h,2)).replace("m",h).replace("ss",Dl(u,2)).replace("s",u).replace("SSS",Dl(c,3))}function Pl(t){return t?t.charAt(0).toUpperCase()+t.substr(1):t}var Ll=si;var Ol=(Object.freeze||Object)({addCommas:_l,toCamelCase:xl,normalizeCssArray:wl,encodeHTML:Ml,formatTpl:Tl,formatTplSimple:function(n,t,i){return A(t,function(t,e){n=n.replace("{"+e+"}",i?Ml(t):t)}),n},getTooltipMarker:Al,formatTime:kl,capitalFirst:Pl,truncateText:Ll,getTextBoundingRect:function(t){return ii(t.text,t.font,t.textAlign,t.textVerticalAlign,t.textPadding,t.textLineHeight,t.rich,t.truncate)},getTextRect:function(t,e,n,i,r,a,o,s){return ii(t,e,n,i,r,s,a,o)}}),zl=A,El=["left","right","top","bottom","width","height"],Nl=[["width","left","right"],["height","top","bottom"]];function Rl(u,c,d,f,p){var g=0,m=0;null==f&&(f=1/0),null==p&&(p=1/0);var v=0;c.eachChild(function(t,e){var n,i,r=t.position,a=t.getBoundingRect(),o=c.childAt(e+1),s=o&&o.getBoundingRect();if("horizontal"===u){var l=a.width+(s?-s.x+a.x:0);v=f<(n=g+l)||t.newline?(g=0,n=l,m+=v+d,a.height):Math.max(v,a.height)}else{var h=a.height+(s?-s.y+a.y:0);v=p<(i=m+h)||t.newline?(g+=v+d,m=0,i=h,a.width):Math.max(v,a.width)}t.newline||(r[0]=g,r[1]=m,"horizontal"===u?g=n+d:m=i+d)})}var Bl=Rl;P(Rl,"vertical"),P(Rl,"horizontal");function Fl(t,e,n){n=wl(n||0);var i=e.width,r=e.height,a=rl(t.left,i),o=rl(t.top,r),s=rl(t.right,i),l=rl(t.bottom,r),h=rl(t.width,i),u=rl(t.height,r),c=n[2]+n[0],d=n[1]+n[3],f=t.aspect;switch(isNaN(h)&&(h=i-s-d-a),isNaN(u)&&(u=r-l-c-o),null!=f&&(isNaN(h)&&isNaN(u)&&(i/r<f?h=.8*i:u=.8*r),isNaN(h)&&(h=f*u),isNaN(u)&&(u=h/f)),isNaN(a)&&(a=i-s-h-d),isNaN(o)&&(o=r-l-u-c),t.left||t.right){case"center":a=i/2-h/2-n[3];break;case"right":a=i-h-d}switch(t.top||t.bottom){case"middle":case"center":o=r/2-u/2-n[0];break;case"bottom":o=r-u-c}a=a||0,o=o||0,isNaN(h)&&(h=i-d-a-(s||0)),isNaN(u)&&(u=r-c-o-(l||0));var p=new vn(a+n[3],o+n[0],h,u);return p.margin=n,p}function Vl(t,e,n,i,r){var a=!r||!r.hv||r.hv[0],o=!r||!r.hv||r.hv[1],s=r&&r.boundingMode||"all";if(a||o){var l;if("raw"===s)l="group"===t.type?new vn(0,0,+e.width||0,+e.height||0):t.getBoundingRect();else if(l=t.getBoundingRect(),t.needLocalTransform()){var h=t.getLocalTransform();(l=l.clone()).applyTransform(h)}e=Fl(T({width:l.width,height:l.height},e),n,i);var u=t.position,c=a?e.x-l.x:0,d=o?e.y-l.y:0;t.attr("position","raw"===s?[c,d]:[u[0]+c,u[1]+d])}}function Hl(l,h,t){N(t)||(t={});var u=t.ignoreSize;O(u)||(u=[u,u]);var e=i(Nl[0],0),n=i(Nl[1],1);function i(t,e){var n={},i=0,r={},a=0;if(zl(t,function(t){r[t]=l[t]}),zl(t,function(t){c(h,t)&&(n[t]=r[t]=h[t]),d(n,t)&&i++,d(r,t)&&a++}),u[e])return d(h,t[1])?r[t[2]]=null:d(h,t[2])&&(r[t[1]]=null),r;if(2!==a&&i){if(2<=i)return n;for(var o=0;o<t.length;o++){var s=t[o];if(!c(n,s)&&c(l,s)){n[s]=l[s];break}}return n}return r}function c(t,e){return t.hasOwnProperty(e)}function d(t,e){return null!=t[e]&&"auto"!==t[e]}function r(t,e,n){zl(t,function(t){e[t]=n[t]})}r(Nl[0],l,e),r(Nl[1],l,n)}function Wl(t){return Gl({},t)}function Gl(e,n){return n&&e&&zl(El,function(t){n.hasOwnProperty(t)&&(e[t]=n[t])}),e}var Zl,Ul,Xl,Yl=Mr(),jl=Ks.extend({type:"component",id:"",name:"",mainType:"",subType:"",componentIndex:0,defaultOption:null,ecModel:null,dependentModels:[],uid:null,layoutMode:null,$constructor:function(t,e,n,i){Ks.call(this,t,e,n,i),this.uid=el("ec_cpt_model")},init:function(t,e,n,i){this.mergeDefaultAndTheme(t,n)},mergeDefaultAndTheme:function(t,e){var n=this.layoutMode,i=n?Wl(t):{};m(t,e.getTheme().get(this.mainType)),m(t,this.getDefaultOption()),n&&Hl(t,i,n)},mergeOption:function(t,e){m(this.option,t,!0);var n=this.layoutMode;n&&Hl(this.option,t,n)},optionUpdated:function(t,e){},getDefaultOption:function(){var t=Yl(this);if(!t.defaultOption){for(var e=[],n=this.constructor;n;){var i=n.prototype.defaultOption;i&&e.push(i),n=n.superClass}for(var r={},a=e.length-1;0<=a;a--)r=m(r,e[a],!0);t.defaultOption=r}return t.defaultOption},getReferringComponents:function(t){return this.ecModel.queryComponents({mainType:t,index:this.get(t+"Index",!0),id:this.get(t+"Id",!0)})}});function ql(t,e){return t[e]||(t[e]={predecessor:[],successor:[]}),t[e]}Br(jl,{registerWhenExtend:!0}),Ul={},(Zl=jl).registerSubTypeDefaulter=function(t,e){t=Lr(t),Ul[t.main]=e},Zl.determineSubType=function(t,e){var n=e.type;if(!n){var i=Lr(t).main;Zl.hasSubTypes(t)&&Ul[i]&&(n=Ul[i](e))}return n},Xl=function(t){var e=[];A(jl.getClassesByMainType(t),function(t){e=e.concat(t.prototype.dependencies||[])}),e=D(e,function(t){return Lr(t).main}),"dataset"!==t&&x(e,"dataset")<=0&&e.unshift("dataset");return e},jl.topologicalTravel=function(t,e,n,i){if(t.length){var r=function(e){var r={},a=[];return A(e,function(n){var i=ql(r,n),t=function(t,e){var n=[];return A(t,function(t){0<=x(e,t)&&n.push(t)}),n}(i.originalDeps=Xl(n),e);i.entryCount=t.length,0===i.entryCount&&a.push(n),A(t,function(t){x(i.predecessor,t)<0&&i.predecessor.push(t);var e=ql(r,t);x(e.successor,t)<0&&e.successor.push(n)})}),{graph:r,noEntryList:a}}(e),a=r.graph,o=r.noEntryList,s={};for(A(t,function(t){s[t]=!0});o.length;){var l=o.pop(),h=a[l],u=!!s[l];u&&(n.call(i,l,h.originalDeps.slice()),delete s[l]),A(h.successor,u?d:c)}A(s,function(){throw new Error("Circle dependency may exists")})}function c(t){a[t].entryCount--,0===a[t].entryCount&&o.push(t)}function d(t){s[t]=!0,c(t)}},S(jl,{getBoxLayoutParams:function(){return{left:this.get("left"),top:this.get("top"),right:this.get("right"),bottom:this.get("bottom"),width:this.get("width"),height:this.get("height")}}});var $l="";"undefined"!=typeof navigator&&($l=navigator.platform||"");var Kl={color:["#c23531","#2f4554","#61a0a8","#d48265","#91c7ae","#749f83","#ca8622","#bda29a","#6e7074","#546570","#c4ccd3"],gradientColor:["#f6efa6","#d88273","#bf444c"],textStyle:{fontFamily:$l.match(/^Win/)?"Microsoft YaHei":"sans-serif",fontSize:12,fontStyle:"normal",fontWeight:"normal"},blendMode:null,animation:"auto",animationDuration:1e3,animationDurationUpdate:300,animationEasing:"exponentialOut",animationEasingUpdate:"cubicOut",animationThreshold:2e3,progressiveThreshold:3e3,progressive:400,hoverLayerThreshold:3e3,useUTC:!1},Ql=Mr();var Jl={clearColorPalette:function(){Ql(this).colorIdx=0,Ql(this).colorNameMap={}},getColorFromPalette:function(t,e,n){var i=Ql(e=e||this),r=i.colorIdx||0,a=i.colorNameMap=i.colorNameMap||{};if(a.hasOwnProperty(t))return a[t];var o=gr(this.get("color",!0)),s=this.get("colorLayer",!0),l=null!=n&&s?function(t,e){for(var n=t.length,i=0;i<n;i++)if(t[i].length>e)return t[i];return t[n-1]}(s,n):o;if((l=l||o)&&l.length){var h=l[r];return t&&(a[t]=h),i.colorIdx=(r+1)%l.length,h}}};function th(t){var e=t.get("coordinateSystem"),n={coordSysName:e,coordSysDims:[],axisMap:Q(),categoryAxisMap:Q()},i=eh[e];if(i)return i(t,n,n.axisMap,n.categoryAxisMap),n}var eh={cartesian2d:function(t,e,n,i){var r=t.getReferringComponents("xAxis")[0],a=t.getReferringComponents("yAxis")[0];e.coordSysDims=["x","y"],n.set("x",r),n.set("y",a),nh(r)&&(i.set("x",r),e.firstCategoryDimIndex=0),nh(a)&&(i.set("y",a),e.firstCategoryDimIndex=1)},singleAxis:function(t,e,n,i){var r=t.getReferringComponents("singleAxis")[0];e.coordSysDims=["single"],n.set("single",r),nh(r)&&(i.set("single",r),e.firstCategoryDimIndex=0)},polar:function(t,e,n,i){var r=t.getReferringComponents("polar")[0],a=r.findAxisModel("radiusAxis"),o=r.findAxisModel("angleAxis");e.coordSysDims=["radius","angle"],n.set("radius",a),n.set("angle",o),nh(a)&&(i.set("radius",a),e.firstCategoryDimIndex=0),nh(o)&&(i.set("angle",o),e.firstCategoryDimIndex=1)},geo:function(t,e,n,i){e.coordSysDims=["lng","lat"]},parallel:function(t,r,a,o){var s=t.ecModel,e=s.getComponent("parallel",t.get("parallelIndex")),l=r.coordSysDims=e.dimensions.slice();A(e.parallelAxisIndex,function(t,e){var n=s.getComponent("parallelAxis",t),i=l[e];a.set(i,n),nh(n)&&null==r.firstCategoryDimIndex&&(o.set(i,n),r.firstCategoryDimIndex=e)})}};function nh(t){return"category"===t.get("type")}var ih="original",rh="arrayRows",ah="objectRows",oh="keyedColumns",sh="unknown",lh="typedArray",hh="column",uh="row";function ch(t){this.fromDataset=t.fromDataset,this.data=t.data||(t.sourceFormat===oh?{}:[]),this.sourceFormat=t.sourceFormat||sh,this.seriesLayoutBy=t.seriesLayoutBy||hh,this.dimensionsDefine=t.dimensionsDefine,this.encodeDefine=t.encodeDefine&&Q(t.encodeDefine),this.startIndex=t.startIndex||0,this.dimensionsDetectCount=t.dimensionsDetectCount}ch.seriesDataToSource=function(t){return new ch({data:t,sourceFormat:B(t)?lh:ih,fromDataset:!1})},Er(ch);var dh=Mr();function fh(t){var e=t.option,n=e.data,i=B(n)?lh:ih,r=!1,a=e.seriesLayoutBy,o=e.sourceHeader,s=e.dimensions,l=function(t){var e=t.option;if(!e.data)return t.ecModel.getComponent("dataset",e.datasetIndex||0)}(t);if(l){var h=l.option;n=h.source,i=dh(l).sourceFormat,r=!0,a=a||h.seriesLayoutBy,null==o&&(o=h.sourceHeader),s=s||h.dimensions}var u=function(t,e,n,i,r){if(!t)return{dimensionsDefine:ph(r)};var a,o,s,l;if(e===rh)"auto"===i||null==i?gh(function(t){null!=t&&"-"!==t&&(E(t)?null==o&&(o=1):o=0)},n,t,10):o=i?1:0,r||1!==o||(r=[],gh(function(t,e){r[e]=null!=t?t:""},n,t)),a=r?r.length:n===uh?t.length:t[0]?t[0].length:null;else if(e===ah)r||(r=function(t){var e,n=0;for(;n<t.length&&!(e=t[n++]););if(e){var i=[];return A(e,function(t,e){i.push(e)}),i}}(t),s=!0);else if(e===oh)r||(r=[],s=!0,A(t,function(t,e){r.push(e)}));else if(e===ih){var h=yr(t[0]);a=O(h)&&h.length||1}s&&A(r,function(t,e){"name"===(N(t)?t.name:t)&&(l=e)});return{startIndex:o,dimensionsDefine:ph(r),dimensionsDetectCount:a,potentialNameDimIndex:l}}(n,i,a,o,s),c=e.encode;!c&&l&&(c=function(t,e,n,i,r,a){var o=th(t),s={},l=[],h=[],u=t.subType,c=Q(["pie","map","funnel"]),d=Q(["line","bar","pictorialBar","scatter","effectScatter","candlestick","boxplot"]);if(o&&null!=d.get(u)){var f=t.ecModel,p=dh(f).datasetMap,g=e.uid+"_"+r,m=p.get(g)||p.set(g,{categoryWayDim:1,valueWayDim:0});A(o.coordSysDims,function(t){if(null==o.firstCategoryDimIndex){var e=m.valueWayDim++;s[t]=e,h.push(e)}else if(o.categoryAxisMap.get(t))s[t]=0,l.push(0);else{e=m.categoryWayDim++;s[t]=e,h.push(e)}})}else if(null!=c.get(u)){for(var v,y=0;y<5&&null==v;y++)mh(n,i,r,a.dimensionsDefine,a.startIndex,y)||(v=y);if(null!=v){s.value=v;var _=a.potentialNameDimIndex||Math.max(v-1,0);h.push(_),l.push(_)}}return l.length&&(s.itemName=l),h.length&&(s.seriesName=h),s}(t,l,n,i,a,u)),dh(t).source=new ch({data:n,fromDataset:r,seriesLayoutBy:a,sourceFormat:i,dimensionsDefine:u.dimensionsDefine,startIndex:u.startIndex,dimensionsDetectCount:u.dimensionsDetectCount,encodeDefine:c})}function ph(t){if(t){var i=Q();return D(t,function(t,e){if(null==(t=I({},N(t)?t:{name:t})).name)return t;t.name+="",null==t.displayName&&(t.displayName=t.name);var n=i.get(t.name);return n?t.name+="-"+n.count++:i.set(t.name,{count:1}),t})}}function gh(t,e,n,i){if(null==i&&(i=1/0),e===uh)for(var r=0;r<n.length&&r<i;r++)t(n[r]?n[r][0]:null,r);else{var a=n[0]||[];for(r=0;r<a.length&&r<i;r++)t(a[r],r)}}function mh(t,e,n,i,r,a){var o,s;if(B(t))return!1;if(i&&(s=N(s=i[a])?s.name:s),e===rh)if(n===uh){for(var l=t[a],h=0;h<(l||[]).length&&h<5;h++)if(null!=(o=f(l[r+h])))return o}else for(h=0;h<t.length&&h<5;h++){var u=t[r+h];if(u&&null!=(o=f(u[a])))return o}else if(e===ah){if(!s)return;for(h=0;h<t.length&&h<5;h++){if((c=t[h])&&null!=(o=f(c[s])))return o}}else if(e===oh){if(!s)return;if(!(l=t[s])||B(l))return!1;for(h=0;h<l.length&&h<5;h++)if(null!=(o=f(l[h])))return o}else if(e===ih)for(h=0;h<t.length&&h<5;h++){var c,d=yr(c=t[h]);if(!O(d))return!1;if(null!=(o=f(d[a])))return o}function f(t){return(null==t||!isFinite(t)||""===t)&&(!(!E(t)||"-"===t)||void 0)}return!1}var vh="\0_ec_inner",yh=Ks.extend({init:function(t,e,n,i){n=n||{},this.option=null,this._theme=new Ks(n),this._optionManager=i},setOption:function(t,e){X(!(vh in t),"please use chart.getOption()"),this._optionManager.setOption(t,e),this.resetOption(null)},resetOption:function(t){var e=!1,n=this._optionManager;if(!t||"recreate"===t){var i=n.mountOption("recreate"===t);this.option&&"recreate"!==t?(this.restoreData(),this.mergeOption(i)):function(t){t=t,this.option={},this.option[vh]=1,this._componentsMap=Q({series:[]}),this._seriesIndices,this._seriesIndicesMap,function(n,t){var i=n.color&&!n.colorLayer;A(t,function(t,e){"colorLayer"===e&&i||jl.hasClass(e)||("object"==typeof t?n[e]=n[e]?m(n[e],t,!1):b(t):null==n[e]&&(n[e]=t))})}(t,this._theme.option),m(t,Kl,!1),this.mergeOption(t)}.call(this,i),e=!0}if("timeline"!==t&&"media"!==t||this.restoreData(),!t||"recreate"===t||"timeline"===t){var r=n.getTimelineOption(this);r&&(this.mergeOption(r),e=!0)}if(!t||"recreate"===t||"media"===t){var a=n.getMediaOption(this,this._api);a.length&&A(a,function(t){this.mergeOption(t,e=!0)},this)}return e},mergeOption:function(i){var l=this.option,h=this._componentsMap,n=[];!function(t){dh(t).datasetMap=Q()}(this),A(i,function(t,e){null!=t&&(jl.hasClass(e)?e&&n.push(e):l[e]=null==l[e]?b(t):m(l[e],t,!0))}),jl.topologicalTravel(n,jl.getAllClassMainTypes(),function(o,t){var e=gr(i[o]),n=_r(h.get(o),e);xr(n),A(n,function(t,e){var n=t.option;N(n)&&(t.keyInfo.mainType=o,t.keyInfo.subType=function(t,e,n){return e.type?e.type:n?n.subType:jl.determineSubType(t,e)}(o,n,t.exist))});var s=function(e,t){O(t)||(t=t?[t]:[]);var n={};return A(t,function(t){n[t]=(e.get(t)||[]).slice()}),n}(h,t);l[o]=[],h.set(o,[]),A(n,function(t,e){var n=t.exist,i=t.option;if(X(N(i)||n,"Empty component definition"),i){var r=jl.getClass(o,t.keyInfo.subType,!0);if(n&&n instanceof r)n.name=t.keyInfo.name,n.mergeOption(i,this),n.optionUpdated(i,!1);else{var a=I({dependentModels:s,componentIndex:e},t.keyInfo);I(n=new r(i,this,this,a),a),n.init(i,this,this,a),n.optionUpdated(null,!0)}}else n.mergeOption({},this),n.optionUpdated({},!1);h.get(o)[e]=n,l[o][e]=n.option},this),"series"===o&&_h(this,h.get("series"))},this),this._seriesIndicesMap=Q(this._seriesIndices=this._seriesIndices||[])},getOption:function(){var i=b(this.option);return A(i,function(t,e){if(jl.hasClass(e)){for(var n=(t=gr(t)).length-1;0<=n;n--)br(t[n])&&t.splice(n,1);i[e]=t}}),delete i[vh],i},getTheme:function(){return this._theme},getComponent:function(t,e){var n=this._componentsMap.get(t);if(n)return n[e||0]},queryComponents:function(t){var e=t.mainType;if(!e)return[];var n,i=t.index,r=t.id,a=t.name,o=this._componentsMap.get(e);if(!o||!o.length)return[];if(null!=i)O(i)||(i=[i]),n=C(D(i,function(t){return o[t]}),function(t){return!!t});else if(null!=r){var s=O(r);n=C(o,function(t){return s&&0<=x(r,t.id)||!s&&t.id===r})}else if(null!=a){var l=O(a);n=C(o,function(t){return l&&0<=x(a,t.name)||!l&&t.name===a})}else n=o.slice();return xh(n,t)},findComponents:function(t){var e,n,i,r,a,o=t.query,s=t.mainType,l=(n=s+"Index",i=s+"Id",r=s+"Name",!(e=o)||null==e[n]&&null==e[i]&&null==e[r]?null:{mainType:s,index:e[n],id:e[i],name:e[r]}),h=l?this.queryComponents(l):this._componentsMap.get(s);return a=xh(h,t),t.filter?C(a,t.filter):a},eachComponent:function(t,i,r){var e=this._componentsMap;if("function"==typeof t)r=i,i=t,e.each(function(t,n){A(t,function(t,e){i.call(r,n,t,e)})});else if(E(t))A(e.get(t),i,r);else if(N(t)){A(this.findComponents(t),i,r)}},getSeriesByName:function(e){return C(this._componentsMap.get("series"),function(t){return t.name===e})},getSeriesByIndex:function(t){return this._componentsMap.get("series")[t]},getSeriesByType:function(e){return C(this._componentsMap.get("series"),function(t){return t.subType===e})},getSeries:function(){return this._componentsMap.get("series").slice()},getSeriesCount:function(){return this._componentsMap.get("series").length},eachSeries:function(n,i){A(this._seriesIndices,function(t){var e=this._componentsMap.get("series")[t];n.call(i,e,t)},this)},eachRawSeries:function(t,e){A(this._componentsMap.get("series"),t,e)},eachSeriesByType:function(n,i,r){A(this._seriesIndices,function(t){var e=this._componentsMap.get("series")[t];e.subType===n&&i.call(r,e,t)},this)},eachRawSeriesByType:function(t,e,n){return A(this.getSeriesByType(t),e,n)},isSeriesFiltered:function(t){return null==this._seriesIndicesMap.get(t.componentIndex)},getCurrentSeriesIndices:function(){return(this._seriesIndices||[]).slice()},filterSeries:function(t,e){var n=C(this._componentsMap.get("series"),t,e);_h(this,n)},restoreData:function(n){var i=this._componentsMap;_h(this,i.get("series"));var r=[];i.each(function(t,e){r.push(e)}),jl.topologicalTravel(r,jl.getAllClassMainTypes(),function(e,t){A(i.get(e),function(t){"series"===e&&function(t,e){if(e){var n=e.seiresIndex,i=e.seriesId,r=e.seriesName;return null!=n&&t.componentIndex!==n||null!=i&&t.id!==i||null!=r&&t.name!==r}}(t,n)||t.restoreData()})})}});function _h(t,e){t._seriesIndicesMap=Q(t._seriesIndices=D(e,function(t){return t.componentIndex})||[])}function xh(t,e){return e.hasOwnProperty("subType")?C(t,function(t){return t.subType===e.subType}):t}S(yh,Jl);var wh=["getDom","getZr","getWidth","getHeight","getDevicePixelRatio","dispatchAction","isDisposed","on","off","getDataURL","getConnectedDataURL","getModel","getOption","getViewOfComponentModel","getViewOfSeriesModel"];function bh(e){A(wh,function(t){this[t]=k(e[t],e)},this)}var Sh={};function Mh(){this._coordinateSystems=[]}Mh.prototype={constructor:Mh,create:function(i,r){var a=[];A(Sh,function(t,e){var n=t.create(i,r);a=a.concat(n||[])}),this._coordinateSystems=a},update:function(e,n){A(this._coordinateSystems,function(t){t.update&&t.update(e,n)})},getCoordinateSystems:function(){return this._coordinateSystems.slice()}},Mh.register=function(t,e){Sh[t]=e},Mh.get=function(t){return Sh[t]};var Ih=A,Ch=b,Th=D,Ah=m,Dh=/^(min|max)?(.+)$/;function kh(t){this._api=t,this._timelineOptions=[],this._mediaList=[],this._mediaDefault,this._currentMediaIndices=[],this._optionBackup,this._newBaseOption}function Ph(t,e,n){var a={width:e,height:n,aspectratio:e/n},o=!0;return A(t,function(t,e){var n=e.match(Dh);if(n&&n[1]&&n[2]){var i=n[1],r=n[2].toLowerCase();!function(t,e,n){return"min"===n?e<=t:"max"===n?t<=e:t===e}(a[r],t,i)&&(o=!1)}}),o}kh.prototype={constructor:kh,setOption:function(t,e){t&&A(gr(t.series),function(t){t&&t.data&&B(t.data)&&q(t.data)}),t=Ch(t);var n=this._optionBackup,i=function(t,n,i){var e,r,a=[],o=[],s=t.timeline;t.baseOption&&(r=t.baseOption);(s||t.options)&&(r=r||{},a=(t.options||[]).slice());if(t.media){r=r||{};var l=t.media;Ih(l,function(t){t&&t.option&&(t.query?o.push(t):e=e||t)})}r=r||t;r.timeline||(r.timeline=s);return Ih([r].concat(a).concat(D(o,function(t){return t.option})),function(e){Ih(n,function(t){t(e,i)})}),{baseOption:r,timelineOptions:a,mediaDefault:e,mediaList:o}}.call(this,t,e,!n);this._newBaseOption=i.baseOption,n?(function(r,t){Ih(t=t||{},function(t,e){if(null!=t){var n=r[e];if(jl.hasClass(e)){t=gr(t);var i=_r(n=gr(n),t);r[e]=Th(i,function(t){return t.option&&t.exist?Ah(t.exist,t.option,!0):t.exist||t.option})}else r[e]=Ah(n,t,!0)}})}(n.baseOption,i.baseOption),i.timelineOptions.length&&(n.timelineOptions=i.timelineOptions),i.mediaList.length&&(n.mediaList=i.mediaList),i.mediaDefault&&(n.mediaDefault=i.mediaDefault)):this._optionBackup=i},mountOption:function(t){var e=this._optionBackup;return this._timelineOptions=Th(e.timelineOptions,Ch),this._mediaList=Th(e.mediaList,Ch),this._mediaDefault=Ch(e.mediaDefault),this._currentMediaIndices=[],Ch(t?e.baseOption:this._newBaseOption)},getTimelineOption:function(t){var e,n=this._timelineOptions;if(n.length){var i=t.getComponent("timeline");i&&(e=Ch(n[i.getCurrentIndex()],!0))}return e},getMediaOption:function(t){var e=this._api.getWidth(),n=this._api.getHeight(),i=this._mediaList,r=this._mediaDefault,a=[],o=[];if(!i.length&&!r)return o;for(var s=0,l=i.length;s<l;s++)Ph(i[s].query,e,n)&&a.push(s);return!a.length&&r&&(a=[-1]),a.length&&!function(t,e){return t.join(",")===e.join(",")}(a,this._currentMediaIndices)&&(o=Th(a,function(t){return Ch(-1===t?r.option:i[t].option)})),this._currentMediaIndices=a,o}};var Lh=A,Oh=N,zh=["areaStyle","lineStyle","nodeStyle","linkStyle","chordStyle","label","labelLine"];function Eh(t){var e=t&&t.itemStyle;if(e)for(var n=0,i=zh.length;n<i;n++){var r=zh[n],a=e.normal,o=e.emphasis;a&&a[r]&&(t[r]=t[r]||{},t[r].normal?m(t[r].normal,a[r]):t[r].normal=a[r],a[r]=null),o&&o[r]&&(t[r]=t[r]||{},t[r].emphasis?m(t[r].emphasis,o[r]):t[r].emphasis=o[r],o[r]=null)}}function Nh(t,e,n){if(t&&t[e]&&(t[e].normal||t[e].emphasis)){var i=t[e].normal,r=t[e].emphasis;i&&(n?(t[e].normal=t[e].emphasis=null,T(t[e],i)):t[e]=i),r&&(t.emphasis=t.emphasis||{},t.emphasis[e]=r)}}function Rh(t){Nh(t,"itemStyle"),Nh(t,"lineStyle"),Nh(t,"areaStyle"),Nh(t,"label"),Nh(t,"labelLine"),Nh(t,"upperLabel"),Nh(t,"edgeLabel")}function Bh(t,e){var n=Oh(t)&&t[e],i=Oh(n)&&n.textStyle;if(i)for(var r=0,a=vr.length;r<a;r++){e=vr[r];i.hasOwnProperty(e)&&(n[e]=i[e])}}function Fh(t){t&&(Rh(t),Bh(t,"label"),t.emphasis&&Bh(t.emphasis,"label"))}function Vh(t){return O(t)?t:t?[t]:[]}function Hh(t){return(O(t)?t[0]:t)||{}}function Wh(e,t){Lh(Vh(e.series),function(t){Oh(t)&&function(t){if(Oh(t)){Eh(t),Rh(t),Bh(t,"label"),Bh(t,"upperLabel"),Bh(t,"edgeLabel"),t.emphasis&&(Bh(t.emphasis,"label"),Bh(t.emphasis,"upperLabel"),Bh(t.emphasis,"edgeLabel")),(n=t.markPoint)&&(Eh(n),Fh(n)),(i=t.markLine)&&(Eh(i),Fh(i));var e=t.markArea;e&&Fh(e);var n,i,r=t.data;if("graph"===t.type){r=r||t.nodes;var a=t.links||t.edges;if(a&&!B(a))for(var o=0;o<a.length;o++)Fh(a[o]);A(t.categories,function(t){Rh(t)})}if(r&&!B(r))for(o=0;o<r.length;o++)Fh(r[o]);if((n=t.markPoint)&&n.data){var s=n.data;for(o=0;o<s.length;o++)Fh(s[o])}if((i=t.markLine)&&i.data){var l=i.data;for(o=0;o<l.length;o++)O(l[o])?(Fh(l[o][0]),Fh(l[o][1])):Fh(l[o])}"gauge"===t.type?(Bh(t,"axisLabel"),Bh(t,"title"),Bh(t,"detail")):"treemap"===t.type?(Nh(t.breadcrumb,"itemStyle"),A(t.levels,function(t){Rh(t)})):"tree"===t.type&&Rh(t.leaves)}}(t)});var n=["xAxis","yAxis","radiusAxis","angleAxis","singleAxis","parallelAxis","radar"];t&&n.push("valueAxis","categoryAxis","logAxis","timeAxis"),Lh(n,function(t){Lh(Vh(e[t]),function(t){t&&(Bh(t,"axisLabel"),Bh(t.axisPointer,"label"))})}),Lh(Vh(e.parallel),function(t){var e=t&&t.parallelAxisDefault;Bh(e,"axisLabel"),Bh(e&&e.axisPointer,"label")}),Lh(Vh(e.calendar),function(t){Nh(t,"itemStyle"),Bh(t,"dayLabel"),Bh(t,"monthLabel"),Bh(t,"yearLabel")}),Lh(Vh(e.radar),function(t){Bh(t,"name")}),Lh(Vh(e.geo),function(t){Oh(t)&&(Fh(t),Lh(Vh(t.regions),function(t){Fh(t)}))}),Lh(Vh(e.timeline),function(t){Fh(t),Nh(t,"label"),Nh(t,"itemStyle"),Nh(t,"controlStyle",!0);var e=t.data;O(e)&&A(e,function(t){N(t)&&(Nh(t,"label"),Nh(t,"itemStyle"))})}),Lh(Vh(e.toolbox),function(t){Nh(t,"iconStyle"),Lh(t.feature,function(t){Nh(t,"iconStyle")})}),Bh(Hh(e.axisPointer),"label"),Bh(Hh(e.tooltip).axisPointer,"label")}function Gh(e){A(Zh,function(t){t[0]in e&&!(t[1]in e)&&(e[t[1]]=e[t[0]])})}var Zh=[["x","left"],["y","top"],["x2","right"],["y2","bottom"]],Uh=["grid","geo","parallel","legend","toolbox","title","visualMap","dataZoom","timeline"],Xh=function(n,t){Wh(n,t),n.series=gr(n.series),A(n.series,function(t){if(N(t)){var e=t.type;if("pie"!==e&&"gauge"!==e||null!=t.clockWise&&(t.clockwise=t.clockWise),"gauge"===e){var n=function(t,e){e=e.split(",");for(var n=t,i=0;i<e.length&&null!=(n=n&&n[e[i]]);i++);return n}(t,"pointer.color");null!=n&&function(t,e,n,i){e=e.split(",");for(var r,a=t,o=0;o<e.length-1;o++)null==a[r=e[o]]&&(a[r]={}),a=a[r];!i&&null!=a[e[o]]||(a[e[o]]=n)}(t,"itemStyle.color",n)}Gh(t)}}),n.dataRange&&(n.visualMap=n.dataRange),A(Uh,function(t){var e=n[t];e&&(O(e)||(e=[e]),A(e,function(t){Gh(t)}))})};function Yh(m){A(m,function(u,c){var d=[],f=[NaN,NaN],t=[u.stackResultDimension,u.stackedOverDimension],p=u.data,g=u.isStackedByIndex,e=p.map(t,function(t,e,n){var i,r,a=p.get(u.stackedDimension,n);if(isNaN(a))return f;g?r=p.getRawIndex(n):i=p.get(u.stackedByDimension,n);for(var o=NaN,s=c-1;0<=s;s--){var l=m[s];if(g||(r=l.data.rawIndexOf(l.stackedByDimension,i)),0<=r){var h=l.data.getByRawIndex(l.stackResultDimension,r);if(0<=a&&0<h||a<=0&&h<0){a+=h,o=h;break}}}return d[0]=a,d[1]=o,d});p.hostModel.setData(e),u.data=e})}function jh(t,e){ch.isInstance(t)||(t=ch.seriesDataToSource(t)),this._source=t;var n=this._data=t.data,i=t.sourceFormat;i===lh&&(this._offset=0,this._dimSize=e,this._data=n),I(this,$h[i===rh?i+"_"+t.seriesLayoutBy:i])}var qh=jh.prototype;qh.pure=!1;var $h={arrayRows_column:{pure:qh.persistent=!0,count:function(){return Math.max(0,this._data.length-this._source.startIndex)},getItem:function(t){return this._data[t+this._source.startIndex]},appendData:Jh},arrayRows_row:{pure:!0,count:function(){var t=this._data[0];return t?Math.max(0,t.length-this._source.startIndex):0},getItem:function(t){t+=this._source.startIndex;for(var e=[],n=this._data,i=0;i<n.length;i++){var r=n[i];e.push(r?r[t]:null)}return e},appendData:function(){throw new Error('Do not support appendData when set seriesLayoutBy: "row".')}},objectRows:{pure:!0,count:Kh,getItem:Qh,appendData:Jh},keyedColumns:{pure:!0,count:function(){var t=this._source.dimensionsDefine[0].name,e=this._data[t];return e?e.length:0},getItem:function(t){for(var e=[],n=this._source.dimensionsDefine,i=0;i<n.length;i++){var r=this._data[n[i].name];e.push(r?r[t]:null)}return e},appendData:function(t){var r=this._data;A(t,function(t,e){for(var n=r[e]||(r[e]=[]),i=0;i<(t||[]).length;i++)n.push(t[i])})}},original:{count:Kh,getItem:Qh,appendData:Jh},typedArray:{persistent:!(qh.getSource=function(){return this._source}),pure:!0,count:function(){return this._data?this._data.length/this._dimSize:0},getItem:function(t,e){t-=this._offset,e=e||[];for(var n=this._dimSize*t,i=0;i<this._dimSize;i++)e[i]=this._data[n+i];return e},appendData:function(t){this._data=t},clean:function(){this._offset+=this.count(),this._data=null}}};function Kh(){return this._data.length}function Qh(t){return this._data[t]}function Jh(t){for(var e=0;e<t.length;e++)this._data.push(t[e])}var tu={arrayRows:eu,objectRows:function(t,e,n,i){return null!=n?t[i]:t},keyedColumns:eu,original:function(t,e,n,i){var r=yr(t);return null!=n&&r instanceof Array?r[n]:r},typedArray:eu};function eu(t,e,n,i){return null!=n?t[n]:t}var nu={arrayRows:iu,objectRows:function(t,e,n,i){return ru(t[e],this._dimensionInfos[e])},keyedColumns:iu,original:function(t,e,n,i){var r=t&&(null==t.value?t:t.value);return!this._rawData.pure&&function(t){return dr(t)&&!(t instanceof Array)}(t)&&(this.hasItemOption=!0),ru(r instanceof Array?r[i]:r,this._dimensionInfos[e])},typedArray:function(t,e,n,i){return t[i]}};function iu(t,e,n,i){return ru(t[i],this._dimensionInfos[e])}function ru(t,e){var n=e&&e.type;if("ordinal"!==n)return"time"===n&&"number"!=typeof t&&null!=t&&"-"!==t&&(t=+pl(t)),null==t||""===t?NaN:+t;var i=e&&e.ordinalMeta;return i?i.parseAndCollect(t):t}function au(t,e,n){if(t){var i=t.getRawDataItem(e);if(null!=i){var r,a,o=t.getProvider().getSource().sourceFormat,s=t.getDimensionInfo(n);return s&&(r=s.name,a=s.index),tu[o](i,e,a,r)}}}function ou(t,e,n){if(t){var i=t.getProvider().getSource().sourceFormat;if(i===ih||i===ah){var r=t.getRawDataItem(e);return i!==ih||N(r)||(r=null),r?r[n]:void 0}}}var su=/\{@(.+?)\}/g,lu={getDataParams:function(t,e){var n=this.getData(e),i=this.getRawValue(t,e),r=n.getRawIndex(t),a=n.getName(t),o=n.getRawDataItem(t),s=n.getItemVisual(t,"color"),l=this.ecModel.getComponent("tooltip"),h=Dr(l&&l.get("renderMode")),u=this.mainType,c="series"===u,d=n.userOutput;return{componentType:u,componentSubType:this.subType,componentIndex:this.componentIndex,seriesType:c?this.subType:null,seriesIndex:this.seriesIndex,seriesId:c?this.id:null,seriesName:c?this.name:null,name:a,dataIndex:r,data:o,dataType:e,value:i,color:s,dimensionNames:d?d.dimensionNames:null,encode:d?d.encode:null,marker:Al({color:s,renderMode:h}),$vars:["seriesName","name","value"]}},getFormattedLabel:function(i,t,e,n,r){t=t||"normal";var a=this.getData(e),o=a.getItemModel(i),s=this.getDataParams(i,e);null!=n&&s.value instanceof Array&&(s.value=s.value[n]);var l=o.get("normal"===t?[r||"label","formatter"]:[t,r||"label","formatter"]);return"function"==typeof l?(s.status=t,s.dimensionIndex=n,l(s)):"string"==typeof l?Tl(l,s).replace(su,function(t,e){var n=e.length;return"["===e.charAt(0)&&"]"===e.charAt(n-1)&&(e=+e.slice(1,n-1)),au(a,i,e)}):void 0},getRawValue:function(t,e){return au(this.getData(e),t)},formatTooltip:function(){}};function hu(t){return new uu(t)}function uu(t){t=t||{},this._reset=t.reset,this._plan=t.plan,this._count=t.count,this._onDirty=t.onDirty,this._dirty=!0,this.context}var cu=uu.prototype;cu.perform=function(t){var e,n=this._upstream,i=t&&t.skip;if(this._dirty&&n){var r=this.context;r.data=r.outputData=n.context.outputData}this.__pipeline&&(this.__pipeline.currentTask=this),this._plan&&!i&&(e=this._plan(this.context));var a,o=u(this._modBy),s=this._modDataCount||0,l=u(t&&t.modBy),h=t&&t.modDataCount||0;function u(t){return 1<=t||(t=1),t}o===l&&s===h||(e="reset"),!this._dirty&&"reset"!==e||(this._dirty=!1,a=function(t,e){var n,i;t._dueIndex=t._outputDueEnd=t._dueEnd=0,t._settedOutputEnd=null,!e&&t._reset&&((n=t._reset(t.context))&&n.progress&&(i=n.forceFirstProgress,n=n.progress),O(n)&&!n.length&&(n=null));t._progress=n,t._modBy=t._modDataCount=null;var r=t._downstream;return r&&r.dirty(),i}(this,i)),this._modBy=l,this._modDataCount=h;var c=t&&t.step;if(this._dueEnd=n?n._outputDueEnd:this._count?this._count(this.context):1/0,this._progress){var d=this._dueIndex,f=Math.min(null!=c?this._dueIndex+c:1/0,this._dueEnd);if(!i&&(a||d<f)){var p=this._progress;if(O(p))for(var g=0;g<p.length;g++)wu(this,p[g],d,f,l,h);else wu(this,p,d,f,l,h)}this._dueIndex=f;var m=null!=this._settedOutputEnd?this._settedOutputEnd:f;this._outputDueEnd=m}else this._dueIndex=this._outputDueEnd=null!=this._settedOutputEnd?this._settedOutputEnd:this._dueEnd;return this.unfinished()};var du,fu,pu,gu,mu,vu,yu=vu={reset:function(t,e,n,i){fu=t,du=e,pu=n,gu=i,mu=Math.ceil(gu/pu),vu.next=1<pu&&0<gu?xu:_u}};function _u(){return fu<du?fu++:null}function xu(){var t=fu%mu*pu+Math.ceil(fu/mu),e=du<=fu?null:t<gu?t:fu;return fu++,e}function wu(t,e,n,i,r,a){yu.reset(n,i,r,a),t._callingProgress=e,t._callingProgress({start:n,end:i,count:i-n,next:yu.next},t.context)}cu.dirty=function(){this._dirty=!0,this._onDirty&&this._onDirty(this.context)},cu.unfinished=function(){return this._progress&&this._dueIndex<this._dueEnd},cu.pipe=function(t){this._downstream===t&&!this._dirty||((this._downstream=t)._upstream=this,t.dirty())},cu.dispose=function(){this._disposed||(this._upstream&&(this._upstream._downstream=null),this._downstream&&(this._downstream._upstream=null),this._dirty=!1,this._disposed=!0)},cu.getUpstream=function(){return this._upstream},cu.getDownstream=function(){return this._downstream},cu.setOutputEnd=function(t){this._outputDueEnd=this._settedOutputEnd=t};var bu=Mr(),Su=jl.extend({type:"series.__base__",seriesIndex:0,coordinateSystem:null,defaultOption:null,legendDataProvider:null,visualColorAccessPath:"itemStyle.color",layoutMode:null,init:function(t,e,n,i){this.seriesIndex=this.componentIndex,this.dataTask=hu({count:Iu,reset:Cu}),this.dataTask.context={model:this},this.mergeDefaultAndTheme(t,n),fh(this);var r=this.getInitialData(t,n);Au(r,this),this.dataTask.context.data=r,bu(this).dataBeforeProcessed=r,Mu(this)},mergeDefaultAndTheme:function(t,e){var n=this.layoutMode,i=n?Wl(t):{},r=this.subType;jl.hasClass(r)&&(r+="Series"),m(t,e.getTheme().get(this.subType)),m(t,this.getDefaultOption()),mr(t,"label",["show"]),this.fillDataTextStyle(t.data),n&&Hl(t,i,n)},mergeOption:function(t,e){t=m(this.option,t,!0),this.fillDataTextStyle(t.data);var n=this.layoutMode;n&&Hl(this.option,t,n),fh(this);var i=this.getInitialData(t,e);Au(i,this),this.dataTask.dirty(),this.dataTask.context.data=i,bu(this).dataBeforeProcessed=i,Mu(this)},fillDataTextStyle:function(t){if(t&&!B(t))for(var e=["show"],n=0;n<t.length;n++)t[n]&&t[n].label&&mr(t[n],"label",e)},getInitialData:function(){},appendData:function(t){this.getRawData().appendData(t.data)},getData:function(t){var e=ku(this);if(e){var n=e.context.data;return null==t?n:n.getLinkedData(t)}return bu(this).data},setData:function(t){var e=ku(this);if(e){var n=e.context;n.data!==t&&e.modifyOutputEnd&&e.setOutputEnd(t.count()),n.outputData=t,e!==this.dataTask&&(n.data=t)}bu(this).data=t},getSource:function(){return function(t){return dh(t).source}(this)},getRawData:function(){return bu(this).dataBeforeProcessed},getBaseAxis:function(){var t=this.coordinateSystem;return t&&t.getBaseAxis&&t.getBaseAxis()},formatTooltip:function(r,u,t,c){var d=this,e="html"===(c=c||"html")?"<br/>":"\n",f="richText"===c,p={},g=0;function n(t){return{renderMode:c,content:Ml(_l(t)),style:p}}var m=this.getData(),a=m.mapDimension("defaultedTooltip",!0),i=a.length,o=this.getRawValue(r),s=O(o),v=m.getItemVisual(r,"color");N(v)&&v.colorStops&&(v=(v.colorStops[0]||{}).color),v=v||"transparent";var l=(1<i||s&&!i?function(t){var l=M(t,function(t,e,n){var i=m.getDimensionInfo(n);return t|(i&&!1!==i.tooltip&&null!=i.displayName)},0),h=[];function e(t,e){var n=m.getDimensionInfo(e);if(n&&!1!==n.otherDims.tooltip){var i=n.type,r="sub"+d.seriesIndex+"at"+g,a=Al({color:v,type:"subItem",renderMode:c,markerId:r}),o="string"==typeof a?a:a.content,s=(l?o+Ml(n.displayName||"-")+": ":"")+Ml("ordinal"===i?t+"":"time"===i?u?"":kl("yyyy/MM/dd hh:mm:ss",t):_l(t));s&&h.push(s),f&&(p[r]=v,++g)}}a.length?A(a,function(t){e(au(m,r,t),t)}):A(t,e);var n=l?f?"\n":"<br/>":"",i=n+h.join(n||", ");return{renderMode:c,content:i,style:p}}(o):n(i?au(m,r,a[0]):s?o[0]:o)).content,h=d.seriesIndex+"at"+g,y=Al({color:v,type:"item",renderMode:c,markerId:h});p[h]=v,++g;var _=m.getName(r),x=this.name;wr(this)||(x=""),x=x?Ml(x)+(u?": ":e):"";var w="string"==typeof y?y:y.content;return{html:u?w+x+l:x+w+(_?Ml(_)+": "+l:l),markers:p}},isAnimationEnabled:function(){if(v.node)return!1;var t=this.getShallow("animation");return t&&this.getData().count()>this.getShallow("animationThreshold")&&(t=!1),t},restoreData:function(){this.dataTask.dirty()},getColorFromPalette:function(t,e,n){var i=this.ecModel,r=Jl.getColorFromPalette.call(this,t,e,n);return r=r||i.getColorFromPalette(t,e,n)},coordDimToDataDim:function(t){return this.getRawData().mapDimension(t,!0)},getProgressive:function(){return this.get("progressive")},getProgressiveThreshold:function(){return this.get("progressiveThreshold")},getAxisTooltipData:null,getTooltipPosition:null,pipeTask:null,preventIncremental:null,pipelineContext:null});function Mu(t){var e=t.name;wr(t)||(t.name=function(t){var n=t.getRawData(),e=n.mapDimension("seriesName",!0),i=[];return A(e,function(t){var e=n.getDimensionInfo(t);e.displayName&&i.push(e.displayName)}),i.join(" ")}(t)||e)}function Iu(t){return t.model.getRawData().count()}function Cu(t){var e=t.model;return e.setData(e.getRawData().cloneShallow()),Tu}function Tu(t,e){t.end>e.outputData.count()&&e.model.getRawData().cloneShallow(e.outputData)}function Au(e,n){A(e.CHANGABLE_METHODS,function(t){e.wrapMethod(t,P(Du,n))})}function Du(t){var e=ku(t);e&&e.setOutputEnd(this.count())}function ku(t){var e=(t.ecModel||{}).scheduler,n=e&&e.getPipeline(t.uid);if(n){var i=n.currentTask;if(i){var r=i.agentStubMap;r&&(i=r.get(t.uid))}return i}}S(Su,lu),S(Su,Jl);var Pu=function(){this.group=new yn,this.uid=el("viewComponent")};Pu.prototype={constructor:Pu,init:function(t,e){},render:function(t,e,n,i){},dispose:function(){},filterForExposedEvent:null};var Lu=Pu.prototype;Lu.updateView=Lu.updateLayout=Lu.updateVisual=function(t,e,n,i){},Or(Pu),Br(Pu,{registerWhenExtend:!0});function Ou(){var s=Mr();return function(t){var e=s(t),n=t.pipelineContext,i=e.large,r=e.progressiveRender,a=e.large=n.large,o=e.progressiveRender=n.progressiveRender;return!!(i^a||r^o)&&"reset"}}var zu=Mr(),Eu=Ou();function Nu(){this.group=new yn,this.uid=el("viewChart"),this.renderTask=hu({plan:Vu,reset:Hu}),this.renderTask.context={view:this}}var Ru=Nu.prototype={type:"chart",init:function(t,e){},render:function(t,e,n,i){},highlight:function(t,e,n,i){Fu(t.getData(),i,"emphasis")},downplay:function(t,e,n,i){Fu(t.getData(),i,"normal")},remove:function(t,e){this.group.removeAll()},dispose:function(){},incrementalPrepareRender:null,incrementalRender:null,updateTransform:null,filterForExposedEvent:null};function Bu(t,e,n){if(t&&(t.trigger(e,n),t.isGroup&&!Is(t)))for(var i=0,r=t.childCount();i<r;i++)Bu(t.childAt(i),e,n)}function Fu(e,t,n){var i=Sr(e,t),r=t&&null!=t.highlightKey?Cs(t.highlightKey):null;null!=i?A(gr(i),function(t){Bu(e.getItemGraphicEl(t),n,r)}):e.eachItemGraphicEl(function(t){Bu(t,n,r)})}function Vu(t){return Eu(t.model)}function Hu(t){var e=t.model,n=t.ecModel,i=t.api,r=t.payload,a=e.pipelineContext.progressiveRender,o=t.view,s=r&&zu(r).updateMethod,l=a?"incrementalPrepareRender":s&&o[s]?s:"render";return"render"!==l&&o[l](e,n,i,r),Wu[l]}Ru.updateView=Ru.updateLayout=Ru.updateVisual=function(t,e,n,i){this.render(t,e,n,i)},Or(Nu),Br(Nu,{registerWhenExtend:!0}),Nu.markUpdateMethod=function(t,e){zu(t).updateMethod=e};var Wu={incrementalPrepareRender:{progress:function(t,e){e.view.incrementalRender(t,e.model,e.ecModel,e.api,e.payload)}},render:{forceFirstProgress:!0,progress:function(t,e){e.view.render(e.model,e.ecModel,e.api,e.payload)}}},Gu="\0__throttleOriginMethod",Zu="\0__throttleRate",Uu="\0__throttleType";function Xu(t,n,i){var r,a,o,s,l,h=0,u=0,c=null;function d(){u=(new Date).getTime(),c=null,t.apply(o,s||[])}n=n||0;function e(){r=(new Date).getTime(),o=this,s=arguments;var t=l||n,e=l||i;l=null,a=r-(e?h:u)-t,clearTimeout(c),e?c=setTimeout(d,t):0<=a?d():c=setTimeout(d,-a),h=r}return e.clear=function(){c&&(clearTimeout(c),c=null)},e.debounceNextCall=function(t){l=t},e}function Yu(t,e,n,i){var r=t[e];if(r){var a=r[Gu]||r,o=r[Uu];if(r[Zu]!==n||o!==i){if(null==n||!i)return t[e]=a;(r=t[e]=Xu(a,n,"debounce"===i))[Gu]=a,r[Uu]=i,r[Zu]=n}return r}}function ju(t,e){var n=t[e];n&&n[Gu]&&(t[e]=n[Gu])}var qu={createOnAllSeries:!0,performRawSeries:!0,reset:function(e,t){var n=e.getData(),i=(e.visualColorAccessPath||"itemStyle.color").split("."),r=e.get(i)||e.getColorFromPalette(e.name,null,t.getSeriesCount());if(n.setVisual("color",r),!t.isSeriesFiltered(e)){"function"!=typeof r||r instanceof Ho||n.each(function(t){n.setItemVisual(t,"color",r(e.getDataParams(t)))});return{dataEach:n.hasItemOption?function(t,e){var n=t.getItemModel(e).get(i,!0);null!=n&&t.setItemVisual(e,"color",n)}:null}}}},$u={toolbox:{brush:{title:{rect:"Box Select",polygon:"Lasso Select",lineX:"Horizontally Select",lineY:"Vertically Select",keep:"Keep Selections",clear:"Clear Selections"}},dataView:{title:"Data View",lang:["Data View","Close","Refresh"]},dataZoom:{title:{zoom:"Zoom",back:"Zoom Reset"}},magicType:{title:{line:"Switch to Line Chart",bar:"Switch to Bar Chart",stack:"Stack",tiled:"Tile"}},restore:{title:"Restore"},saveAsImage:{title:"Save as Image",lang:["Right Click to Save Image"]}},aria:{general:{withTitle:'This is a chart about "{title}"',withoutTitle:"This is a chart"},series:{single:{prefix:"",withName:" with type {seriesType} named {seriesName}.",withoutName:" with type {seriesType}."},multiple:{prefix:". It consists of {seriesCount} series count.",withName:" The {seriesId} series is a {seriesType} representing {seriesName}.",withoutName:" The {seriesId} series is a {seriesType}.",separator:{middle:"",end:""}}},data:{allData:"The data is as follows: ",partialData:"The first {displayCnt} items are: ",withName:"the data for {name} is {value}",withoutName:"{value}",separator:{middle:",",end:"."}}}},Ku=function(t,e){var a=e.getModel("aria");if(a.get("show"))if(a.get("description"))t.setAttribute("aria-label",a.get("description"));else{var u=0;e.eachSeries(function(t,e){++u},this);var n,c=a.get("data.maxCount")||10,i=a.get("series.maxCount")||10,d=Math.min(u,i);if(!(u<1)){var r=function(){var t=e.getModel("title").option;t&&t.length&&(t=t[0]);return t&&t.text}();n=r?p(g("general.withTitle"),{title:r}):g("general.withoutTitle");var f=[];n+=p(g(1<u?"series.multiple.prefix":"series.single.prefix"),{seriesCount:u}),e.eachSeries(function(t,e){if(e<d){var n,i=t.get("name"),r="series."+(1<u?"multiple":"single")+".";n=p(n=g(i?r+"withName":r+"withoutName"),{seriesId:t.seriesIndex,seriesName:t.get("name"),seriesType:function(t){return $u.series.typeNames[t]||"自定义图"}(t.subType)});var a=t.getData();(window.data=a).count()>c?n+=p(g("data.partialData"),{displayCnt:c}):n+=g("data.allData");for(var o=[],s=0;s<a.count();s++)if(s<c){var l=a.getName(s),h=au(a,s);o.push(p(g(l?"data.withName":"data.withoutName"),{name:l,value:h}))}n+=o.join(g("data.separator.middle"))+g("data.separator.end"),f.push(n)}}),n+=f.join(g("series.multiple.separator.middle"))+g("series.multiple.separator.end"),t.setAttribute("aria-label",n)}}function p(t,e){if("string"!=typeof t)return t;var n=t;return A(e,function(t,e){n=n.replace(new RegExp("\\{\\s*"+e+"\\s*\\}","g"),t)}),n}function g(t){var e=a.get(t);if(null!=e)return e;for(var n=t.split("."),i=$u.aria,r=0;r<n.length;++r)i=i[n[r]];return i}},Qu=Math.PI;function Ju(t,e,n,i){this.ecInstance=t,this.api=e,this.unfinished;n=this._dataProcessorHandlers=n.slice(),i=this._visualHandlers=i.slice();this._allHandlers=n.concat(i),this._stageTaskMap=Q()}var tc=Ju.prototype;function ec(l,t,h,u,c){var d;function f(t,e){return t.setDirty&&(!t.dirtyMap||t.dirtyMap.get(e.__pipeline.id))}c=c||{},A(t,function(i,t){if(!c.visualType||c.visualType===i.visualType){var e=l._stageTaskMap.get(i.uid),n=e.seriesTaskMap,r=e.overallTask;if(r){var a,o=r.agentStubMap;o.each(function(t){f(c,t)&&(t.dirty(),a=!0)}),a&&r.dirty(),nc(r,u);var s=l.getPerformArgs(r,c.block);o.each(function(t){t.perform(s)}),d|=r.perform(s)}else n&&n.each(function(t,e){f(c,t)&&t.dirty();var n=l.getPerformArgs(t,c.block);n.skip=!i.performRawSeries&&h.isSeriesFiltered(t.context.model),nc(t,u),d|=t.perform(n)})}}),l.unfinished|=d}tc.restoreData=function(t,e){t.restoreData(e),this._stageTaskMap.each(function(t){var e=t.overallTask;e&&e.dirty()})},tc.getPerformArgs=function(t,e){if(t.__pipeline){var n=this._pipelineMap.get(t.__pipeline.id),i=n.context,r=!e&&n.progressiveEnabled&&(!i||i.progressiveRender)&&t.__idxInPipeline>n.blockIndex?n.step:null,a=i&&i.modDataCount;return{step:r,modBy:null!=a?Math.ceil(a/r):null,modDataCount:a}}},tc.getPipeline=function(t){return this._pipelineMap.get(t)},tc.updateStreamModes=function(t,e){var n=this._pipelineMap.get(t.uid),i=t.getData().count(),r=n.progressiveEnabled&&e.incrementalPrepareRender&&i>=n.threshold,a=t.get("large")&&i>=t.get("largeThreshold"),o="mod"===t.get("progressiveChunkMode")?i:null;t.pipelineContext=n.context={progressiveRender:r,modDataCount:o,large:a}},tc.restorePipelines=function(t){var i=this,r=i._pipelineMap=Q();t.eachSeries(function(t){var e=t.getProgressive(),n=t.uid;r.set(n,{id:n,head:null,tail:null,threshold:t.getProgressiveThreshold(),progressiveEnabled:e&&!(t.preventIncremental&&t.preventIncremental()),blockIndex:-1,step:Math.round(e||700),count:0}),dc(i,t,t.dataTask)})},tc.prepareStageTasks=function(){var n=this._stageTaskMap,i=this.ecInstance.getModel(),r=this.api;A(this._allHandlers,function(t){var e=n.get(t.uid)||n.set(t.uid,[]);t.reset&&function(i,r,t,a,o){var s=t.seriesTaskMap||(t.seriesTaskMap=Q()),e=r.seriesType,n=r.getTargetSeries;r.createOnAllSeries?a.eachRawSeries(l):e?a.eachRawSeriesByType(e,l):n&&n(a,o).each(l);function l(t){var e=t.uid,n=s.get(e)||s.set(e,hu({plan:sc,reset:lc,count:cc}));n.context={model:t,ecModel:a,api:o,useClearVisual:r.isVisual&&!r.isLayout,plan:r.plan,reset:r.reset,scheduler:i},dc(i,t,n)}var h=i._pipelineMap;s.each(function(t,e){h.get(e)||(t.dispose(),s.removeKey(e))})}(this,t,e,i,r),t.overallReset&&function(i,t,e,n,r){var a=e.overallTask=e.overallTask||hu({reset:ic});a.context={ecModel:n,api:r,overallReset:t.overallReset,scheduler:i};var o=a.agentStubMap=a.agentStubMap||Q(),s=t.seriesType,l=t.getTargetSeries,h=!0,u=t.modifyOutputEnd;s?n.eachRawSeriesByType(s,c):l?l(n,r).each(c):(h=!1,A(n.getSeries(),c));function c(t){var e=t.uid,n=o.get(e);n||(n=o.set(e,hu({reset:rc,onDirty:oc})),a.dirty()),n.context={model:t,overallProgress:h,modifyOutputEnd:u},n.agent=a,n.__block=h,dc(i,t,n)}var d=i._pipelineMap;o.each(function(t,e){d.get(e)||(t.dispose(),a.dirty(),o.removeKey(e))})}(this,t,e,i,r)},this)},tc.prepareView=function(t,e,n,i){var r=t.renderTask,a=r.context;a.model=e,a.ecModel=n,a.api=i,r.__block=!t.incrementalPrepareRender,dc(this,e,r)},tc.performDataProcessorTasks=function(t,e){ec(this,this._dataProcessorHandlers,t,e,{block:!0})},tc.performVisualTasks=function(t,e,n){ec(this,this._visualHandlers,t,e,n)},tc.performSeriesTasks=function(t){var e;t.eachSeries(function(t){e|=t.dataTask.perform()}),this.unfinished|=e},tc.plan=function(){this._pipelineMap.each(function(t){var e=t.tail;do{if(e.__block){t.blockIndex=e.__idxInPipeline;break}e=e.getUpstream()}while(e)})};var nc=tc.updatePayload=function(t,e){"remain"!==e&&(t.context.payload=e)};function ic(t){t.overallReset(t.ecModel,t.api,t.payload)}function rc(t,e){return t.overallProgress&&ac}function ac(){this.agent.dirty(),this.getDownstream().dirty()}function oc(){this.agent&&this.agent.dirty()}function sc(t){return t.plan&&t.plan(t.model,t.ecModel,t.api,t.payload)}function lc(t){t.useClearVisual&&t.data.clearAllVisual();var e=t.resetDefines=gr(t.reset(t.model,t.ecModel,t.api,t.payload));return 1<e.length?D(e,function(t,e){return uc(e)}):hc}var hc=uc(0);function uc(a){return function(t,e){var n=e.data,i=e.resetDefines[a];if(i&&i.dataEach)for(var r=t.start;r<t.end;r++)i.dataEach(n,r);else i&&i.progress&&i.progress(t,n)}}function cc(t){return t.data.count()}function dc(t,e,n){var i=e.uid,r=t._pipelineMap.get(i);r.head||(r.head=n),r.tail&&r.tail.pipe(n),(r.tail=n).__idxInPipeline=r.count++,n.__pipeline=r}Ju.wrapStageHandler=function(t,e){return z(t)&&(t={overallReset:t,seriesType:function(t){fc=null;try{t(pc,gc)}catch(t){}return fc}(t)}),t.uid=el("stageHandler"),e&&(t.visualType=e),t};var fc,pc={},gc={};function mc(t,e){for(var n in e.prototype)t[n]=J}mc(pc,yh),mc(gc,bh),pc.eachSeriesByType=pc.eachRawSeriesByType=function(t){fc=t},pc.eachComponent=function(t){"series"===t.mainType&&t.subType&&(fc=t.subType)};function vc(){return{axisLine:{lineStyle:{color:xc}},axisTick:{lineStyle:{color:xc}},axisLabel:{textStyle:{color:xc}},splitLine:{lineStyle:{type:"dashed",color:"#aaa"}},splitArea:{areaStyle:{color:xc}}}}var yc=["#37A2DA","#32C5E9","#67E0E3","#9FE6B8","#FFDB5C","#ff9f7f","#fb7293","#E062AE","#E690D1","#e7bcf3","#9d96f5","#8378EA","#96BFFF"],_c={color:yc,colorLayer:[["#37A2DA","#ffd85c","#fd7b5f"],["#37A2DA","#67E0E3","#FFDB5C","#ff9f7f","#E062AE","#9d96f5"],["#37A2DA","#32C5E9","#9FE6B8","#FFDB5C","#ff9f7f","#fb7293","#e7bcf3","#8378EA","#96BFFF"],yc]},xc="#eee",wc=["#dd6b66","#759aa0","#e69d87","#8dc1a9","#ea7e53","#eedd78","#73a373","#73b9bc","#7289ab","#91ca8c","#f49f42"],bc={color:wc,backgroundColor:"#333",tooltip:{axisPointer:{lineStyle:{color:xc},crossStyle:{color:xc}}},legend:{textStyle:{color:xc}},textStyle:{color:xc},title:{textStyle:{color:xc}},toolbox:{iconStyle:{normal:{borderColor:xc}}},dataZoom:{textStyle:{color:xc}},visualMap:{textStyle:{color:xc}},timeline:{lineStyle:{color:xc},itemStyle:{normal:{color:wc[1]}},label:{normal:{textStyle:{color:xc}}},controlStyle:{normal:{color:xc,borderColor:xc}}},timeAxis:vc(),logAxis:vc(),valueAxis:vc(),categoryAxis:vc(),line:{symbol:"circle"},graph:{color:wc},gauge:{title:{textStyle:{color:xc}}},candlestick:{itemStyle:{normal:{color:"#FD1050",color0:"#0CF49B",borderColor:"#FD1050",borderColor0:"#0CF49B"}}}};bc.categoryAxis.splitLine.show=!1,jl.extend({type:"dataset",defaultOption:{seriesLayoutBy:hh,sourceHeader:null,dimensions:null,source:null},optionUpdated:function(){!function(t){var e=t.option.source,n=sh;if(B(e))n=lh;else if(O(e)){0===e.length&&(n=rh);for(var i=0,r=e.length;i<r;i++){var a=e[i];if(null!=a){if(O(a)){n=rh;break}if(N(a)){n=ah;break}}}}else if(N(e)){for(var o in e)if(e.hasOwnProperty(o)&&L(e[o])){n=oh;break}}else if(null!=e)throw new Error("Invalid data");dh(t).sourceFormat=n}(this)}}),Pu.extend({type:"dataset"});var Sc=no.extend({type:"ellipse",shape:{cx:0,cy:0,rx:0,ry:0},buildPath:function(t,e){var n=e.cx,i=e.cy,r=e.rx,a=e.ry,o=.5522848*r,s=.5522848*a;t.moveTo(n-r,i),t.bezierCurveTo(n-r,i-s,n-o,i-a,n,i-a),t.bezierCurveTo(n+o,i-a,n+r,i-s,n+r,i),t.bezierCurveTo(n+r,i+s,n+o,i+a,n,i+a),t.bezierCurveTo(n-o,i+a,n-r,i+s,n-r,i),t.closePath()}}),Mc=/[\s,]+/;function Ic(t){E(t)&&(t=(new DOMParser).parseFromString(t,"text/xml"));for(9===t.nodeType&&(t=t.firstChild);"svg"!==t.nodeName.toLowerCase()||1!==t.nodeType;)t=t.nextSibling;return t}var Cc={g:function(t,e){var n=new yn;return Ac(e,n),Pc(t,n,this._defs),n},rect:function(t,e){var n=new No;return Ac(e,n),Pc(t,n,this._defs),n.setShape({x:parseFloat(t.getAttribute("x")||0),y:parseFloat(t.getAttribute("y")||0),width:parseFloat(t.getAttribute("width")||0),height:parseFloat(t.getAttribute("height")||0)}),n},circle:function(t,e){var n=new So;return Ac(e,n),Pc(t,n,this._defs),n.setShape({cx:parseFloat(t.getAttribute("cx")||0),cy:parseFloat(t.getAttribute("cy")||0),r:parseFloat(t.getAttribute("r")||0)}),n},line:function(t,e){var n=new Bo;return Ac(e,n),Pc(t,n,this._defs),n.setShape({x1:parseFloat(t.getAttribute("x1")||0),y1:parseFloat(t.getAttribute("y1")||0),x2:parseFloat(t.getAttribute("x2")||0),y2:parseFloat(t.getAttribute("y2")||0)}),n},ellipse:function(t,e){var n=new Sc;return Ac(e,n),Pc(t,n,this._defs),n.setShape({cx:parseFloat(t.getAttribute("cx")||0),cy:parseFloat(t.getAttribute("cy")||0),rx:parseFloat(t.getAttribute("rx")||0),ry:parseFloat(t.getAttribute("ry")||0)}),n},polygon:function(t,e){var n=t.getAttribute("points");n=n&&Dc(n);var i=new Do({shape:{points:n||[]}});return Ac(e,i),Pc(t,i,this._defs),i},polyline:function(t,e){var n=new no;Ac(e,n),Pc(t,n,this._defs);var i=t.getAttribute("points");return i=i&&Dc(i),new ko({shape:{points:i||[]}})},image:function(t,e){var n=new Hi;return Ac(e,n),Pc(t,n,this._defs),n.setStyle({image:t.getAttribute("xlink:href"),x:t.getAttribute("x"),y:t.getAttribute("y"),width:t.getAttribute("width"),height:t.getAttribute("height")}),n},text:function(t,e){var n=t.getAttribute("x")||0,i=t.getAttribute("y")||0,r=t.getAttribute("dx")||0,a=t.getAttribute("dy")||0;this._textX=parseFloat(n)+parseFloat(r),this._textY=parseFloat(i)+parseFloat(a);var o=new yn;return Ac(e,o),Pc(t,o,this._defs),o},tspan:function(t,e){var n=t.getAttribute("x"),i=t.getAttribute("y");null!=n&&(this._textX=parseFloat(n)),null!=i&&(this._textY=parseFloat(i));var r=t.getAttribute("dx")||0,a=t.getAttribute("dy")||0,o=new yn;return Ac(e,o),Pc(t,o,this._defs),this._textX+=r,this._textY+=a,o},path:function(t,e){var n=xo(t.getAttribute("d")||"");return Ac(e,n),Pc(t,n,this._defs),n}},Tc={lineargradient:function(t){var e=parseInt(t.getAttribute("x1")||0,10),n=parseInt(t.getAttribute("y1")||0,10),i=parseInt(t.getAttribute("x2")||10,10),r=parseInt(t.getAttribute("y2")||0,10),a=new Uo(e,n,i,r);return function(t,e){var n=t.firstChild;for(;n;){if(1===n.nodeType){var i=n.getAttribute("offset");i=0<i.indexOf("%")?parseInt(i,10)/100:i?parseFloat(i):0;var r=n.getAttribute("stop-color")||"#000000";e.addColorStop(i,r)}n=n.nextSibling}}(t,a),a},radialgradient:function(t){}};function Ac(t,e){t&&t.__inheritedStyle&&(e.__inheritedStyle||(e.__inheritedStyle={}),T(e.__inheritedStyle,t.__inheritedStyle))}function Dc(t){for(var e=Y(t).split(Mc),n=[],i=0;i<e.length;i+=2){var r=parseFloat(e[i]),a=parseFloat(e[i+1]);n.push([r,a])}return n}var kc={fill:"fill",stroke:"stroke","stroke-width":"lineWidth",opacity:"opacity","fill-opacity":"fillOpacity","stroke-opacity":"strokeOpacity","stroke-dasharray":"lineDash","stroke-dashoffset":"lineDashOffset","stroke-linecap":"lineCap","stroke-linejoin":"lineJoin","stroke-miterlimit":"miterLimit","font-family":"fontFamily","font-size":"fontSize","font-style":"fontStyle","font-weight":"fontWeight","text-align":"textAlign","alignment-baseline":"textBaseline"};function Pc(t,e,n,i){var r=e.__inheritedStyle||{},a="text"===e.type;if(1===t.nodeType&&(function(t,e){var n=t.getAttribute("transform");if(n){n=n.replace(/,/g," ");var i=null,r=[];n.replace(zc,function(t,e,n){r.push(e,n)});for(var a=r.length-1;0<a;a-=2){var o=r[a],s=r[a-1];switch(i=i||qt(),s){case"translate":o=Y(o).split(Mc),Jt(i,i,[parseFloat(o[0]),parseFloat(o[1]||0)]);break;case"scale":o=Y(o).split(Mc),ee(i,i,[parseFloat(o[0]),parseFloat(o[1]||o[0])]);break;case"rotate":o=Y(o).split(Mc),te(i,i,parseFloat(o[0]));break;case"skew":o=Y(o).split(Mc),console.warn("Skew transform is not supported yet");break;case"matrix":o=Y(o).split(Mc);i[0]=parseFloat(o[0]),i[1]=parseFloat(o[1]),i[2]=parseFloat(o[2]),i[3]=parseFloat(o[3]),i[4]=parseFloat(o[4]),i[5]=parseFloat(o[5])}}e.setLocalTransform(i)}}(t,e),I(r,function(t){var e=t.getAttribute("style"),n={};if(!e)return n;var i,r={};Ec.lastIndex=0;for(;null!=(i=Ec.exec(e));)r[i[1]]=i[2];for(var a in kc)kc.hasOwnProperty(a)&&null!=r[a]&&(n[kc[a]]=r[a]);return n}(t)),!i))for(var o in kc)if(kc.hasOwnProperty(o)){var s=t.getAttribute(o);null!=s&&(r[kc[o]]=s)}var l=a?"textFill":"fill",h=a?"textStroke":"stroke";e.style=e.style||new zn;var u=e.style;null!=r.fill&&u.set(l,Oc(r.fill,n)),null!=r.stroke&&u.set(h,Oc(r.stroke,n)),A(["lineWidth","opacity","fillOpacity","strokeOpacity","miterLimit","fontSize"],function(t){var e="lineWidth"===t&&a?"textStrokeWidth":t;null!=r[t]&&u.set(e,parseFloat(r[t]))}),r.textBaseline&&"auto"!==r.textBaseline||(r.textBaseline="alphabetic"),"alphabetic"===r.textBaseline&&(r.textBaseline="bottom"),"start"===r.textAlign&&(r.textAlign="left"),"end"===r.textAlign&&(r.textAlign="right"),A(["lineDashOffset","lineCap","lineJoin","fontWeight","fontFamily","fontStyle","textAlign","textBaseline"],function(t){null!=r[t]&&u.set(t,r[t])}),r.lineDash&&(e.style.lineDash=Y(r.lineDash).split(Mc)),u[h]&&"none"!==u[h]&&(e[h]=!0),e.__inheritedStyle=r}var Lc=/url\(\s*#(.*?)\)/;function Oc(t,e){var n=e&&t&&t.match(Lc);return n?e[Y(n[1])]:t}var zc=/(translate|scale|rotate|skewX|skewY|matrix)\(([\-\s0-9\.e,]*)\)/g;var Ec=/([^\s:;]+)\s*:\s*([^:;]+)/g;var Nc=Q(),Rc=function(t,e,n){var i;return A(i=O(e)?e:e.svg?[{type:"svg",source:e.svg,specialAreas:e.specialAreas}]:(e.geoJson&&!e.features&&(n=e.specialAreas,e=e.geoJson),[{type:"geoJSON",source:e,specialAreas:n}]),function(t){var e=t.type;"geoJson"===e&&(e=t.type="geoJSON"),(0,Fc[e])(t)}),Nc.set(t,i)},Bc=function(t){return Nc.get(t)},Fc={geoJSON:function(t){var e=t.source;t.geoJSON=E(e)?"undefined"!=typeof JSON&&JSON.parse?JSON.parse(e):new Function("return ("+e+");")():e},svg:function(t){t.svgXML=Ic(t.source)}},Vc=X,Hc=A,Wc=z,Gc=N,Zc=jl.parseClassType,Uc={PROCESSOR:{FILTER:1e3,STATISTIC:5e3},VISUAL:{LAYOUT:1e3,PROGRESSIVE_LAYOUT:1100,GLOBAL:2e3,CHART:3e3,POST_CHART_LAYOUT:3500,COMPONENT:4e3,BRUSH:5e3}},Xc="__flagInMainProcess",Yc="__optionUpdated",jc=/^[a-zA-Z0-9_]+$/;function qc(i){return function(t,e,n){t=t&&t.toLowerCase(),It.prototype[i].call(this,t,e,n)}}function $c(){It.call(this)}function Kc(t,e,n){n=n||{},"string"==typeof e&&(e=wd[e]),this.id,this.group,this._dom=t;var i=this._zr=sr(t,{renderer:n.renderer||"canvas",devicePixelRatio:n.devicePixelRatio,width:n.width,height:n.height});this._throttledZrFlush=Xu(k(i.flush,i),17),(e=b(e))&&Xh(e,!0),this._theme=e,this._chartsViews=[],this._chartsMap={},this._componentsViews=[],this._componentsMap={},this._coordSysMgr=new Mh;var r=this._api=function(n){var t=n._coordSysMgr;return I(new bh(n),{getCoordinateSystems:k(t.getCoordinateSystems,t),getComponentByElement:function(t){for(;t;){var e=t.__ecComponentInfo;if(null!=e)return n._model.getComponent(e.mainType,e.index);t=t.parent}}})}(this);function a(t,e){return t.__prio-e.__prio}Cn(xd,a),Cn(vd,a),this._scheduler=new Ju(this,r,vd,xd),It.call(this,this._ecEventProcessor=new pd),this._messageCenter=new $c,this._initEvents(),this.resize=k(this.resize,this),this._pendingActions=[],i.animation.on("frame",this._onframe,this),function(t,e){t.on("rendered",function(){e.trigger("rendered"),!t.animation.isFinished()||e[Yc]||e._scheduler.unfinished||e._pendingActions.length||e.trigger("finished")})}(i,this),q(this)}$c.prototype.on=qc("on"),$c.prototype.off=qc("off"),$c.prototype.one=qc("one"),S($c,It);var Qc=Kc.prototype;function Jc(t,e,n){var i,r=this._model,a=this._coordSysMgr.getCoordinateSystems();e=Cr(r,e);for(var o=0;o<a.length;o++){var s=a[o];if(s[t]&&null!=(i=s[t](r,e,n)))return i}}Qc._onframe=function(){if(!this._disposed){var t=this._scheduler;if(this[Yc]){var e=this[Yc].silent;this[Xc]=!0,ed(this),td.update.call(this),this[Xc]=!1,this[Yc]=!1,ad.call(this,e),od.call(this,e)}else if(t.unfinished){var n=1,i=this._model,r=this._api;t.unfinished=!1;do{var a=+new Date;t.performSeriesTasks(i),t.performDataProcessorTasks(i),id(this,i),t.performVisualTasks(i),ud(this,this._model,r,"remain"),n-=+new Date-a}while(0<n&&t.unfinished);t.unfinished||this._zr.flush()}}},Qc.getDom=function(){return this._dom},Qc.getZr=function(){return this._zr},Qc.setOption=function(t,e,n){var i;if(Gc(e)&&(n=e.lazyUpdate,i=e.silent,e=e.notMerge),this[Xc]=!0,!this._model||e){var r=new kh(this._api),a=this._theme,o=this._model=new yh;o.scheduler=this._scheduler,o.init(null,null,a,r)}this._model.setOption(t,yd),n?(this[Yc]={silent:i},this[Xc]=!1):(ed(this),td.update.call(this),this._zr.flush(),this[Yc]=!1,this[Xc]=!1,ad.call(this,i),od.call(this,i))},Qc.setTheme=function(){console.error("ECharts#setTheme() is DEPRECATED in ECharts 3.0")},Qc.getModel=function(){return this._model},Qc.getOption=function(){return this._model&&this._model.getOption()},Qc.getWidth=function(){return this._zr.getWidth()},Qc.getHeight=function(){return this._zr.getHeight()},Qc.getDevicePixelRatio=function(){return this._zr.painter.dpr||window.devicePixelRatio||1},Qc.getRenderedCanvas=function(t){if(v.canvasSupported)return(t=t||{}).pixelRatio=t.pixelRatio||1,t.backgroundColor=t.backgroundColor||this._model.get("backgroundColor"),this._zr.painter.getRenderedCanvas(t)},Qc.getSvgDataUrl=function(){if(v.svgSupported){var t=this._zr;return A(t.storage.getDisplayList(),function(t){t.stopAnimation(!0)}),t.painter.pathToDataUrl()}},Qc.getDataURL=function(t){var e=(t=t||{}).excludeComponents,n=this._model,i=[],r=this;Hc(e,function(t){n.eachComponent({mainType:t},function(t){var e=r._componentsMap[t.__viewId];e.group.ignore||(i.push(e),e.group.ignore=!0)})});var a="svg"===this._zr.painter.getType()?this.getSvgDataUrl():this.getRenderedCanvas(t).toDataURL("image/"+(t&&t.type||"png"));return Hc(i,function(t){t.group.ignore=!1}),a},Qc.getConnectedDataURL=function(r){if(v.canvasSupported){var a=this.group,o=Math.min,s=Math.max;if(Md[a]){var l=1/0,h=1/0,u=-1/0,c=-1/0,d=[],n=r&&r.pixelRatio||1;A(Sd,function(t,e){if(t.group===a){var n=t.getRenderedCanvas(b(r)),i=t.getDom().getBoundingClientRect();l=o(i.left,l),h=o(i.top,h),u=s(i.right,u),c=s(i.bottom,c),d.push({dom:n,left:i.left,top:i.top})}});var t=(u*=n)-(l*=n),e=(c*=n)-(h*=n),i=g();i.width=t,i.height=e;var f=sr(i);return r.connectedBackgroundColor&&f.add(new No({shape:{x:0,y:0,width:t,height:e},style:{fill:r.connectedBackgroundColor}})),Hc(d,function(t){var e=new Hi({style:{x:t.left*n-l,y:t.top*n-h,image:t.dom}});f.add(e)}),f.refreshImmediately(),i.toDataURL("image/"+(r&&r.type||"png"))}return this.getDataURL(r)}},Qc.convertToPixel=P(Jc,"convertToPixel"),Qc.convertFromPixel=P(Jc,"convertFromPixel"),Qc.containPixel=function(t,r){var a;return A(t=Cr(this._model,t),function(t,i){0<=i.indexOf("Models")&&A(t,function(t){var e=t.coordinateSystem;if(e&&e.containPoint)a|=!!e.containPoint(r);else if("seriesModels"===i){var n=this._chartsMap[t.__viewId];n&&n.containPoint&&(a|=n.containPoint(r,t))}},this)},this),!!a},Qc.getVisual=function(t,e){var n=(t=Cr(this._model,t,{defaultMainType:"series"})).seriesModel.getData(),i=t.hasOwnProperty("dataIndexInside")?t.dataIndexInside:t.hasOwnProperty("dataIndex")?n.indexOfRawIndex(t.dataIndex):null;return null!=i?n.getItemVisual(i,e):n.getVisual(e)},Qc.getViewOfComponentModel=function(t){return this._componentsMap[t.__viewId]},Qc.getViewOfSeriesModel=function(t){return this._chartsMap[t.__viewId]};var td={prepareAndUpdate:function(t){ed(this),td.update.call(this,t)},update:function(t){var e=this._model,n=this._api,i=this._zr,r=this._coordSysMgr,a=this._scheduler;if(e){a.restoreData(e,t),a.performSeriesTasks(e),r.create(e,n),a.performDataProcessorTasks(e,t),id(this,e),r.update(e,n),ld(e),a.performVisualTasks(e,t),hd(this,e,n,t);var o=e.get("backgroundColor")||"transparent";if(v.canvasSupported)i.setBackgroundColor(o);else{var s=ke(o);o=Fe(s,"rgb"),0===s[3]&&(o="transparent")}cd(e,n)}},updateTransform:function(r){var a=this._model,o=this,s=this._api;if(a){var l=[];a.eachComponent(function(t,e){var n=o.getViewOfComponentModel(e);if(n&&n.__alive)if(n.updateTransform){var i=n.updateTransform(e,a,s,r);i&&i.update&&l.push(n)}else l.push(n)});var i=Q();a.eachSeries(function(t){var e=o._chartsMap[t.__viewId];if(e.updateTransform){var n=e.updateTransform(t,a,s,r);n&&n.update&&i.set(t.uid,1)}else i.set(t.uid,1)}),ld(a),this._scheduler.performVisualTasks(a,r,{setDirty:!0,dirtyMap:i}),ud(o,a,s,r,i),cd(a,this._api)}},updateView:function(t){var e=this._model;e&&(Nu.markUpdateMethod(t,"updateView"),ld(e),this._scheduler.performVisualTasks(e,t,{setDirty:!0}),hd(this,this._model,this._api,t),cd(e,this._api))},updateVisual:function(t){td.update.call(this,t)},updateLayout:function(t){td.update.call(this,t)}};function ed(t){var e=t._model,n=t._scheduler;n.restorePipelines(e),n.prepareStageTasks(),sd(t,"component",e,n),sd(t,"chart",e,n),n.plan()}function nd(e,n,i,r,t){var a=e._model;if(r){var o={};o[r+"Id"]=i[r+"Id"],o[r+"Index"]=i[r+"Index"],o[r+"Name"]=i[r+"Name"];var s={mainType:r,query:o};t&&(s.subType=t);var l=i.excludeSeriesId;null!=l&&(l=Q(gr(l))),a&&a.eachComponent(s,function(t){l&&null!=l.get(t.id)||h(e["series"===r?"_chartsMap":"_componentsMap"][t.__viewId])},e)}else Hc(e._componentsViews.concat(e._chartsViews),h);function h(t){t&&t.__alive&&t[n]&&t[n](t.__model,a,e._api,i)}}function id(t,e){var n=t._chartsMap,i=t._scheduler;e.eachSeries(function(t){i.updateStreamModes(t,n[t.__viewId])})}function rd(e,t){var n=e.type,i=e.escapeConnect,r=gd[n],a=r.actionInfo,o=(a.update||"update").split(":"),s=o.pop();o=null!=o[0]&&Zc(o[0]),this[Xc]=!0;var l=[e],h=!1;e.batch&&(h=!0,l=D(e.batch,function(t){return(t=T(I({},t),e)).batch=null,t}));var u,c=[],d="highlight"===n||"downplay"===n;Hc(l,function(t){(u=(u=r.action(t,this._model,this._api))||I({},t)).type=a.event||u.type,c.push(u),d?nd(this,s,t,"series"):o&&nd(this,s,t,o.main,o.sub)},this),"none"===s||d||o||(this[Yc]?(ed(this),td.update.call(this,e),this[Yc]=!1):td[s].call(this,e)),u=h?{type:a.event||n,escapeConnect:i,batch:c}:c[0],this[Xc]=!1,t||this._messageCenter.trigger(u.type,u)}function ad(t){for(var e=this._pendingActions;e.length;){var n=e.shift();rd.call(this,n,t)}}function od(t){t||this.trigger("updated")}function sd(t,e,r,a){for(var o="component"===e,s=o?t._componentsViews:t._chartsViews,l=o?t._componentsMap:t._chartsMap,h=t._zr,u=t._api,n=0;n<s.length;n++)s[n].__alive=!1;function i(t){var e="_ec_"+t.id+"_"+t.type,n=l[e];if(!n){var i=Zc(t.type);(n=new(o?Pu.getClass(i.main,i.sub):Nu.getClass(i.sub))).init(r,u),l[e]=n,s.push(n),h.add(n.group)}t.__viewId=n.__id=e,n.__alive=!0,n.__model=t,n.group.__ecComponentInfo={mainType:t.mainType,index:t.componentIndex},o||a.prepareView(n,t,r,u)}o?r.eachComponent(function(t,e){"series"!==t&&i(e)}):r.eachSeries(i);for(n=0;n<s.length;){var c=s[n];c.__alive?n++:(o||c.renderTask.dispose(),h.remove(c.group),c.dispose(r,u),s.splice(n,1),delete l[c.__id],c.__id=c.group.__ecComponentInfo=null)}}function ld(t){t.clearColorPalette(),t.eachSeries(function(t){t.clearColorPalette()})}function hd(t,e,n,i){!function(t,n,i,r,e){Hc(e||t._componentsViews,function(t){var e=t.__model;t.render(e,n,i,r),fd(e,t)})}(t,e,n,i),Hc(t._chartsViews,function(t){t.__alive=!1}),ud(t,e,n,i),Hc(t._chartsViews,function(t){t.__alive||t.remove(e,n)})}function ud(i,t,e,r,a){var o,s=i._scheduler;t.eachSeries(function(t){var e=i._chartsMap[t.__viewId];e.__alive=!0;var n=e.renderTask;s.updatePayload(n,r),a&&a.get(t.uid)&&n.dirty(),o|=n.perform(s.getPerformArgs(n)),e.group.silent=!!t.get("silent"),fd(t,e),function(t,e){var n=t.get("blendMode")||null;e.group.traverse(function(t){t.isGroup||t.style.blend!==n&&t.setStyle("blend",n),t.eachPendingDisplayable&&t.eachPendingDisplayable(function(t){t.setStyle("blend",n)})})}(t,e)}),s.unfinished|=o,function(n,t){var e=n._zr.storage,i=0;e.traverse(function(t){i++}),i>t.get("hoverLayerThreshold")&&!v.node&&t.eachSeries(function(t){if(!t.preventUsingHoverLayer){var e=n._chartsMap[t.__viewId];e.__alive&&e.group.traverse(function(t){t.useHoverLayer=!0})}})}(i,t),Ku(i._zr.dom,t)}function cd(e,n){Hc(_d,function(t){t(e,n)})}Qc.resize=function(t){this._zr.resize(t);var e=this._model;if(this._loadingFX&&this._loadingFX.resize(),e){var n=e.resetOption("media"),i=t&&t.silent;this[Xc]=!0,n&&ed(this),td.update.call(this),this[Xc]=!1,ad.call(this,i),od.call(this,i)}},Qc.showLoading=function(t,e){if(Gc(t)&&(e=t,t=""),t=t||"default",this.hideLoading(),bd[t]){var n=bd[t](this._api,e),i=this._zr;this._loadingFX=n,i.add(n)}},Qc.hideLoading=function(){this._loadingFX&&this._zr.remove(this._loadingFX),this._loadingFX=null},Qc.makeActionFromEvent=function(t){var e=I({},t);return e.type=md[t.type],e},Qc.dispatchAction=function(t,e){Gc(e)||(e={silent:!!e}),gd[t.type]&&this._model&&(this[Xc]?this._pendingActions.push(t):(rd.call(this,t,e.silent),e.flush?this._zr.flush(!0):!1!==e.flush&&v.browser.weChat&&this._throttledZrFlush(),ad.call(this,e.silent),od.call(this,e.silent)))},Qc.appendData=function(t){var e=t.seriesIndex;this.getModel().getSeriesByIndex(e).appendData(t),this._scheduler.unfinished=!0},Qc.on=qc("on"),Qc.off=qc("off"),Qc.one=qc("one");var dd=["click","dblclick","mouseover","mouseout","mousemove","mousedown","mouseup","globalout","contextmenu"];function fd(t,e){var n=t.get("z"),i=t.get("zlevel");e.group.traverse(function(t){"group"!==t.type&&(null!=n&&(t.z=n),null!=i&&(t.zlevel=i))})}function pd(){this.eventInfo}Qc._initEvents=function(){Hc(dd,function(h){function t(t){var e,n=this.getModel(),i=t.target;if("globalout"===h)e={};else if(i&&null!=i.dataIndex){var r=i.dataModel||n.getSeriesByIndex(i.seriesIndex);e=r&&r.getDataParams(i.dataIndex,i.dataType,i)||{}}else i&&i.eventData&&(e=I({},i.eventData));if(e){var a=e.componentType,o=e.componentIndex;"markLine"!==a&&"markPoint"!==a&&"markArea"!==a||(a="series",o=e.seriesIndex);var s=a&&null!=o&&n.getComponent(a,o),l=s&&this["series"===s.mainType?"_chartsMap":"_componentsMap"][s.__viewId];e.event=t,e.type=h,this._ecEventProcessor.eventInfo={targetEl:i,packedEvent:e,model:s,view:l},this.trigger(h,e)}}t.zrEventfulCallAtLast=!0,this._zr.on(h,t,this)},this),Hc(md,function(t,e){this._messageCenter.on(e,function(t){this.trigger(e,t)},this)},this)},Qc.isDisposed=function(){return this._disposed},Qc.clear=function(){this.setOption({series:[]},!0)},Qc.dispose=function(){if(!this._disposed){this._disposed=!0,Ar(this.getDom(),Td,"");var e=this._api,n=this._model;Hc(this._componentsViews,function(t){t.dispose(n,e)}),Hc(this._chartsViews,function(t){t.dispose(n,e)}),this._zr.dispose(),delete Sd[this.id]}},S(Kc,It),pd.prototype={constructor:pd,normalizeQuery:function(t){var s={},l={},h={};if(E(t)){var e=Zc(t);s.mainType=e.main||null,s.subType=e.sub||null}else{var u=["Index","Name","Id"],c={name:1,dataIndex:1,dataType:1};A(t,function(t,e){for(var n=!1,i=0;i<u.length;i++){var r=u[i],a=e.lastIndexOf(r);if(0<a&&a===e.length-r.length){var o=e.slice(0,a);"data"!==o&&(s.mainType=o,s[r.toLowerCase()]=t,n=!0)}}c.hasOwnProperty(e)&&(l[e]=t,n=!0),n||(h[e]=t)})}return{cptQuery:s,dataQuery:l,otherQuery:h}},filter:function(t,e,n){var i=this.eventInfo;if(!i)return!0;var r=i.targetEl,a=i.packedEvent,o=i.model,s=i.view;if(!o||!s)return!0;var l=e.cptQuery,h=e.dataQuery;return u(l,o,"mainType")&&u(l,o,"subType")&&u(l,o,"index","componentIndex")&&u(l,o,"name")&&u(l,o,"id")&&u(h,a,"name")&&u(h,a,"dataIndex")&&u(h,a,"dataType")&&(!s.filterForExposedEvent||s.filterForExposedEvent(t,e.otherQuery,r,a));function u(t,e,n,i){return null==t[n]||e[i||n]===t[n]}},afterTrigger:function(){this.eventInfo=null}};var gd={},md={},vd=[],yd=[],_d=[],xd=[],wd={},bd={},Sd={},Md={},Id=new Date-0,Cd=new Date-0,Td="_echarts_instance_";function Ad(t){Md[t]=!1}var Dd=Ad;function kd(t){return Sd[function(t,e){return t.getAttribute?t.getAttribute(e):t[e]}(t,Td)]}function Pd(t,e){wd[t]=e}function Ld(t){yd.push(t)}function Od(t,e){Rd(vd,t,e,1e3)}function zd(t,e,n){"function"==typeof e&&(n=e,e="");var i=Gc(t)?t.type:[t,t={event:e}][0];t.event=(t.event||i).toLowerCase(),e=t.event,Vc(jc.test(i)&&jc.test(e)),gd[i]||(gd[i]={action:n,actionInfo:t}),md[e]=i}function Ed(t,e){Rd(xd,t,e,1e3,"layout")}function Nd(t,e){Rd(xd,t,e,3e3,"visual")}function Rd(t,e,n,i,r){(Wc(e)||Gc(e))&&(n=e,e=i);var a=Ju.wrapStageHandler(n,r);return a.__prio=e,a.__raw=n,t.push(a),a}function Bd(t,e){bd[t]=e}function Fd(t){return jl.extend(t)}function Vd(t){return Pu.extend(t)}function Hd(t){return Su.extend(t)}function Wd(t){return Nu.extend(t)}Nd(2e3,qu),Ld(Xh),Od(5e3,function(t){var a=Q();t.eachSeries(function(t){var e=t.get("stack");if(e){var n=a.get(e)||a.set(e,[]),i=t.getData(),r={stackResultDimension:i.getCalculationInfo("stackResultDimension"),stackedOverDimension:i.getCalculationInfo("stackedOverDimension"),stackedDimension:i.getCalculationInfo("stackedDimension"),stackedByDimension:i.getCalculationInfo("stackedByDimension"),isStackedByIndex:i.getCalculationInfo("isStackedByIndex"),data:i,seriesModel:t};if(!r.stackedDimension||!r.isStackedByIndex&&!r.stackedByDimension)return;n.length&&i.setCalculationInfo("stackedOnSeries",n[n.length-1].seriesModel),n.push(r)}}),a.each(Yh)}),Bd("default",function(i,t){T(t=t||{},{text:"loading",color:"#c23531",textColor:"#000",maskColor:"rgba(255, 255, 255, 0.8)",zlevel:0});var r=new No({style:{fill:t.maskColor},zlevel:t.zlevel,z:1e4}),a=new Go({shape:{startAngle:-Qu/2,endAngle:-Qu/2+.1,r:10},style:{stroke:t.color,lineCap:"round",lineWidth:5},zlevel:t.zlevel,z:10001}),o=new No({style:{fill:"none",text:t.text,textPosition:"right",textDistance:10,textFill:t.textColor},zlevel:t.zlevel,z:10001});a.animateShape(!0).when(1e3,{endAngle:3*Qu/2}).start("circularInOut"),a.animateShape(!0).when(1e3,{startAngle:3*Qu/2}).delay(300).start("circularInOut");var e=new yn;return e.add(a),e.add(o),e.add(r),e.resize=function(){var t=i.getWidth()/2,e=i.getHeight()/2;a.setShape({cx:t,cy:e});var n=a.shape.r;o.setShape({x:t-n,y:e-n,width:2*n,height:2*n}),r.setShape({x:0,y:0,width:i.getWidth(),height:i.getHeight()})},e.resize(),e}),zd({type:"highlight",event:"highlight",update:"highlight"},J),zd({type:"downplay",event:"downplay",update:"downplay"},J),Pd("light",_c),Pd("dark",bc);function Gd(t){return t}function Zd(t,e,n,i,r){this._old=t,this._new=e,this._oldKeyGetter=n||Gd,this._newKeyGetter=i||Gd,this.context=r}function Ud(t,e,n,i,r){for(var a=0;a<t.length;a++){var o="_ec_"+r[i](t[a],a),s=e[o];null==s?(n.push(o),e[o]=a):(s.length||(e[o]=s=[s]),s.push(a))}}Zd.prototype={constructor:Zd,add:function(t){return this._add=t,this},update:function(t){return this._update=t,this},remove:function(t){return this._remove=t,this},execute:function(){var t=this._old,e=this._new,n={},i=[],r=[];for(Ud(t,{},i,"_oldKeyGetter",this),Ud(e,n,r,"_newKeyGetter",this),a=0;a<t.length;a++){if(null!=(s=n[o=i[a]]))(h=s.length)?(1===h&&(n[o]=null),s=s.unshift()):n[o]=null,this._update&&this._update(s,a);else this._remove&&this._remove(a)}for(var a=0;a<r.length;a++){var o=r[a];if(n.hasOwnProperty(o)){var s;if(null==(s=n[o]))continue;if(s.length)for(var l=0,h=s.length;l<h;l++)this._add&&this._add(s[l]);else this._add&&this._add(s)}}}};var Xd=Q(["tooltip","label","itemName","itemId","seriesName"]);function Yd(t,e){return t.hasOwnProperty(e)||(t[e]=[]),t[e]}var jd=N,qd="undefined",$d={float:typeof Float64Array==qd?Array:Float64Array,int:typeof Int32Array==qd?Array:Int32Array,ordinal:Array,number:Array,time:Array},Kd=typeof Uint32Array==qd?Array:Uint32Array,Qd=typeof Int32Array==qd?Array:Int32Array,Jd=typeof Uint16Array==qd?Array:Uint16Array;function tf(t){return 65535<t._rawCount?Kd:Jd}var ef=["hasItemOption","_nameList","_idList","_invertedIndicesMap","_rawData","_chunkSize","_chunkCount","_dimValueGetter","_count","_rawCount","_nameDimIdx","_idDimIdx"],nf=["_extent","_approximateExtent","_rawExtent"];function rf(e,n){A(ef.concat(n.__wrappedMethods||[]),function(t){n.hasOwnProperty(t)&&(e[t]=n[t])}),e.__wrappedMethods=n.__wrappedMethods,A(nf,function(t){e[t]=b(n[t])}),e._calculationInfo=I(n._calculationInfo)}var af=function(t,e){t=t||["x","y"];for(var n={},i=[],r={},a=0;a<t.length;a++){var o=t[a];E(o)&&(o={name:o});var s=o.name;o.type=o.type||"float",o.coordDim||(o.coordDim=s,o.coordDimIndex=0),o.otherDims=o.otherDims||{},i.push(s),(n[s]=o).index=a,o.createInvertedIndices&&(r[s]=[])}this.dimensions=i,this._dimensionInfos=n,this.hostModel=e,this.dataType,this._indices=null,this._count=0,this._rawCount=0,this._storage={},this._nameList=[],this._idList=[],this._optionModels=[],this._visual={},this._layout={},this._itemVisuals=[],this.hasItemVisual={},this._itemLayouts=[],this._graphicEls=[],this._chunkSize=1e5,this._chunkCount=0,this._rawData,this._rawExtent={},this._extent={},this._approximateExtent={},this._dimensionsSummary=function(i){var t={},a=t.encode={},o=Q(),s=[],l=[],h=t.userOutput={dimensionNames:i.dimensions.slice(),encode:{}};A(i.dimensions,function(t){var r=i.getDimensionInfo(t),e=r.coordDim;if(e){var n=r.coordDimIndex;Yd(a,e)[n]=t,r.isExtraCoord||(o.set(e,1),function(t){return!("ordinal"===t||"time"===t)}(r.type)&&(s[0]=t),Yd(h.encode,e)[n]=r.index),r.defaultTooltip&&l.push(t)}Xd.each(function(t,e){var n=Yd(a,e),i=r.otherDims[e];null!=i&&!1!==i&&(n[i]=r.name)})});var r=[],u={};o.each(function(t,e){var n=a[e];u[e]=n[0],r=r.concat(n)}),t.dataDimsOnCoord=r,t.encodeFirstDimNotExtra=u;var e=a.label;e&&e.length&&(s=e.slice());var n=a.tooltip;return n&&n.length?l=n.slice():l.length||(l=s.slice()),a.defaultedLabel=s,a.defaultedTooltip=l,t}(this),this._invertedIndicesMap=r,this._calculationInfo={},this.userOutput=this._dimensionsSummary.userOutput},of=af.prototype;function sf(t,e,n,i,r){var a=$d[e.type],o=i-1,s=e.name,l=t[s][o];if(l&&l.length<n){for(var h=new a(Math.min(r-o*n,n)),u=0;u<l.length;u++)h[u]=l[u];t[s][o]=h}for(var c=i*n;c<r;c+=n)t[s].push(new a(Math.min(r-c,n)))}function lf(r){var a=r._invertedIndicesMap;A(a,function(t,e){var n=r._dimensionInfos[e].ordinalMeta;if(n){t=a[e]=new Qd(n.categories.length);for(var i=0;i<t.length;i++)t[i]=-1;for(i=0;i<r._count;i++)t[r.get(e,i)]=i}})}function hf(t,e,n){var i;if(null!=e){var r=t._chunkSize,a=Math.floor(n/r),o=n%r,s=t.dimensions[e],l=t._storage[s][a];if(l){i=l[o];var h=t._dimensionInfos[s].ordinalMeta;h&&h.categories.length&&(i=h.categories[i])}}return i}function uf(t){return t}function cf(t){return t<this._count&&0<=t?this._indices[t]:-1}function df(t,e){var n=t._idList[e];return null==n&&(n=hf(t,t._idDimIdx,e)),null==n&&(n="e\0\0"+e),n}function ff(t){return O(t)||(t=[t]),t}function pf(t,e){var n=t.dimensions,i=new af(D(n,t.getDimensionInfo,t),t.hostModel);rf(i,t);for(var r=i._storage={},a=t._storage,o=0;o<n.length;o++){var s=n[o];a[s]&&(0<=x(e,s)?(r[s]=gf(a[s]),i._rawExtent[s]=mf(),i._extent[s]=null):r[s]=a[s])}return i}function gf(t){for(var e,n,i=new Array(t.length),r=0;r<t.length;r++)i[r]=(e=t[r],n=void 0,(n=e.constructor)===Array?e.slice():new n(e));return i}function mf(){return[1/0,-1/0]}of.type="list",of.hasItemOption=!0,of.getDimension=function(t){return"number"!=typeof t&&(isNaN(t)||this._dimensionInfos.hasOwnProperty(t))||(t=this.dimensions[t]),t},of.getDimensionInfo=function(t){return this._dimensionInfos[this.getDimension(t)]},of.getDimensionsOnCoord=function(){return this._dimensionsSummary.dataDimsOnCoord.slice()},of.mapDimension=function(t,e){var n=this._dimensionsSummary;if(null==e)return n.encodeFirstDimNotExtra[t];var i=n.encode[t];return!0===e?(i||[]).slice():i&&i[e]},of.initData=function(t,e,n){(ch.isInstance(t)||L(t))&&(t=new jh(t,this.dimensions.length)),this._rawData=t,this._storage={},this._indices=null,this._nameList=e||[],this._idList=[],this._nameRepeatCount={},n||(this.hasItemOption=!1),this.defaultDimValueGetter=nu[this._rawData.getSource().sourceFormat],this._dimValueGetter=n=n||this.defaultDimValueGetter,this._dimValueGetterArrayRows=nu.arrayRows,this._rawExtent={},this._initDataFromProvider(0,t.count()),t.pure&&(this.hasItemOption=!1)},of.getProvider=function(){return this._rawData},of.appendData=function(t){var e=this._rawData,n=this.count();e.appendData(t);var i=e.count();e.persistent||(i+=n),this._initDataFromProvider(n,i)},of.appendValues=function(t,e){for(var n=this._chunkSize,i=this._storage,r=this.dimensions,a=r.length,o=this._rawExtent,s=this.count(),l=s+Math.max(t.length,e?e.length:0),h=this._chunkCount,u=0;u<a;u++){o[v=r[u]]||(o[v]=mf()),i[v]||(i[v]=[]),sf(i,this._dimensionInfos[v],n,h,l),this._chunkCount=i[v].length}for(var c=new Array(a),d=s;d<l;d++){for(var f=d-s,p=Math.floor(d/n),g=d%n,m=0;m<a;m++){var v=r[m],y=this._dimValueGetterArrayRows(t[f]||c,v,f,m);i[v][p][g]=y;var _=o[v];y<_[0]&&(_[0]=y),y>_[1]&&(_[1]=y)}e&&(this._nameList[d]=e[f])}this._rawCount=this._count=l,this._extent={},lf(this)},of._initDataFromProvider=function(t,e){if(!(e<=t)){for(var n,i=this._chunkSize,r=this._rawData,a=this._storage,o=this.dimensions,s=o.length,l=this._dimensionInfos,h=this._nameList,u=this._idList,c=this._rawExtent,d=this._nameRepeatCount={},f=this._chunkCount,p=0;p<s;p++){c[w=o[p]]||(c[w]=mf());var g=l[w];0===g.otherDims.itemName&&(n=this._nameDimIdx=p),0===g.otherDims.itemId&&(this._idDimIdx=p),a[w]||(a[w]=[]),sf(a,g,i,f,e),this._chunkCount=a[w].length}for(var m=new Array(s),v=t;v<e;v++){m=r.getItem(v,m);for(var y=Math.floor(v/i),_=v%i,x=0;x<s;x++){var w,b=a[w=o[x]][y],S=this._dimValueGetter(m,w,v,x);b[_]=S;var M=c[w];S<M[0]&&(M[0]=S),S>M[1]&&(M[1]=S)}if(!r.pure){var I=h[v];if(m&&null==I)if(null!=m.name)h[v]=I=m.name;else if(null!=n){var C=o[n],T=a[C][y];if(T){I=T[_];var A=l[C].ordinalMeta;A&&A.categories.length&&(I=A.categories[I])}}var D=null==m?null:m.id;null==D&&null!=I&&(d[I]=d[I]||0,0<d[D=I]&&(D+="__ec__"+d[I]),d[I]++),null!=D&&(u[v]=D)}}!r.persistent&&r.clean&&r.clean(),this._rawCount=this._count=e,this._extent={},lf(this)}},of.count=function(){return this._count},of.getIndices=function(){var t=this._indices;if(t){var e=t.constructor,n=this._count;if(e===Array){r=new e(n);for(var i=0;i<n;i++)r[i]=t[i]}else r=new e(t.buffer,0,n)}else{var r=new(e=tf(this))(this.count());for(i=0;i<r.length;i++)r[i]=i}return r},of.get=function(t,e){if(!(0<=e&&e<this._count))return NaN;var n=this._storage;if(!n[t])return NaN;e=this.getRawIndex(e);var i=Math.floor(e/this._chunkSize),r=e%this._chunkSize;return n[t][i][r]},of.getByRawIndex=function(t,e){if(!(0<=e&&e<this._rawCount))return NaN;var n=this._storage[t];if(!n)return NaN;var i=Math.floor(e/this._chunkSize),r=e%this._chunkSize;return n[i][r]},of._getFast=function(t,e){var n=Math.floor(e/this._chunkSize),i=e%this._chunkSize;return this._storage[t][n][i]},of.getValues=function(t,e){var n=[];O(t)||(e=t,t=this.dimensions);for(var i=0,r=t.length;i<r;i++)n.push(this.get(t[i],e));return n},of.hasValue=function(t){for(var e=this._dimensionsSummary.dataDimsOnCoord,n=0,i=e.length;n<i;n++)if(isNaN(this.get(e[n],t)))return!1;return!0},of.getDataExtent=function(t){t=this.getDimension(t);var e=this._storage[t],n=mf();if(!e)return n;var i,r=this.count();if(!this._indices)return this._rawExtent[t].slice();if(i=this._extent[t])return i.slice();for(var a=(i=n)[0],o=i[1],s=0;s<r;s++){var l=this._getFast(t,this.getRawIndex(s));l<a&&(a=l),o<l&&(o=l)}return i=[a,o],this._extent[t]=i},of.getApproximateExtent=function(t){return t=this.getDimension(t),this._approximateExtent[t]||this.getDataExtent(t)},of.setApproximateExtent=function(t,e){e=this.getDimension(e),this._approximateExtent[e]=t.slice()},of.getCalculationInfo=function(t){return this._calculationInfo[t]},of.setCalculationInfo=function(t,e){jd(t)?I(this._calculationInfo,t):this._calculationInfo[t]=e},of.getSum=function(t){var e=0;if(this._storage[t])for(var n=0,i=this.count();n<i;n++){var r=this.get(t,n);isNaN(r)||(e+=r)}return e},of.getMedian=function(t){var n=[];this.each(t,function(t,e){isNaN(t)||n.push(t)});var e=[].concat(n).sort(function(t,e){return t-e}),i=this.count();return 0===i?0:i%2==1?e[(i-1)/2]:(e[i/2]+e[i/2-1])/2},of.rawIndexOf=function(t,e){var n=(t&&this._invertedIndicesMap[t])[e];return null==n||isNaN(n)?-1:n},of.indexOfName=function(t){for(var e=0,n=this.count();e<n;e++)if(this.getName(e)===t)return e;return-1},of.indexOfRawIndex=function(t){if(!this._indices)return t;if(t>=this._rawCount||t<0)return-1;var e=this._indices,n=e[t];if(null!=n&&n<this._count&&n===t)return t;for(var i=0,r=this._count-1;i<=r;){var a=(i+r)/2|0;if(e[a]<t)i=1+a;else{if(!(e[a]>t))return a;r=a-1}}return-1},of.indicesOfNearest=function(t,e,n){var i=[];if(!this._storage[t])return i;null==n&&(n=1/0);for(var r=Number.MAX_VALUE,a=-1,o=0,s=this.count();o<s;o++){var l=e-this.get(t,o),h=Math.abs(l);l<=n&&h<=r&&((h<r||0<=l&&a<0)&&(r=h,a=l,i.length=0),i.push(o))}return i},of.getRawIndex=uf,of.getRawDataItem=function(t){if(this._rawData.persistent)return this._rawData.getItem(this.getRawIndex(t));for(var e=[],n=0;n<this.dimensions.length;n++){var i=this.dimensions[n];e.push(this.get(i,t))}return e},of.getName=function(t){var e=this.getRawIndex(t);return this._nameList[e]||hf(this,this._nameDimIdx,e)||""},of.getId=function(t){return df(this,this.getRawIndex(t))},of.each=function(t,e,n,i){if(this._count){"function"==typeof t&&(i=n,n=e,e=t,t=[]),n=n||i||this;for(var r=(t=D(ff(t),this.getDimension,this)).length,a=0;a<this.count();a++)switch(r){case 0:e.call(n,a);break;case 1:e.call(n,this.get(t[0],a),a);break;case 2:e.call(n,this.get(t[0],a),this.get(t[1],a),a);break;default:for(var o=0,s=[];o<r;o++)s[o]=this.get(t[o],a);s[o]=a,e.apply(n,s)}}},of.filterSelf=function(t,e,n,i){if(this._count){"function"==typeof t&&(i=n,n=e,e=t,t=[]),n=n||i||this,t=D(ff(t),this.getDimension,this);for(var r=this.count(),a=new(tf(this))(r),o=[],s=t.length,l=0,h=t[0],u=0;u<r;u++){var c,d=this.getRawIndex(u);if(0===s)c=e.call(n,u);else if(1===s){var f=this._getFast(h,d);c=e.call(n,f,u)}else{for(var p=0;p<s;p++)o[p]=this._getFast(h,d);o[p]=u,c=e.apply(n,o)}c&&(a[l++]=d)}return l<r&&(this._indices=a),this._count=l,this._extent={},this.getRawIndex=this._indices?cf:uf,this}},of.selectRange=function(t){if(this._count){var e=[];for(var n in t)t.hasOwnProperty(n)&&e.push(n);var i=e.length;if(i){var r=this.count(),a=new(tf(this))(r),o=0,s=e[0],l=t[s][0],h=t[s][1],u=!1;if(!this._indices){var c=0;if(1===i){for(var d=this._storage[e[0]],f=0;f<this._chunkCount;f++)for(var p=d[f],g=Math.min(this._count-f*this._chunkSize,this._chunkSize),m=0;m<g;m++){(l<=(w=p[m])&&w<=h||isNaN(w))&&(a[o++]=c),c++}u=!0}else if(2===i){d=this._storage[s];var v=this._storage[e[1]],y=t[e[1]][0],_=t[e[1]][1];for(f=0;f<this._chunkCount;f++){p=d[f];var x=v[f];for(g=Math.min(this._count-f*this._chunkSize,this._chunkSize),m=0;m<g;m++){var w=p[m],b=x[m];(l<=w&&w<=h||isNaN(w))&&(y<=b&&b<=_||isNaN(b))&&(a[o++]=c),c++}}u=!0}}if(!u)if(1===i)for(m=0;m<r;m++){var S=this.getRawIndex(m);(l<=(w=this._getFast(s,S))&&w<=h||isNaN(w))&&(a[o++]=S)}else for(m=0;m<r;m++){var M=!0;for(S=this.getRawIndex(m),f=0;f<i;f++){var I=e[f];((w=this._getFast(n,S))<t[I][0]||w>t[I][1])&&(M=!1)}M&&(a[o++]=this.getRawIndex(m))}return o<r&&(this._indices=a),this._count=o,this._extent={},this.getRawIndex=this._indices?cf:uf,this}}},of.mapArray=function(t,e,n,i){"function"==typeof t&&(i=n,n=e,e=t,t=[]),n=n||i||this;var r=[];return this.each(t,function(){r.push(e&&e.apply(this,arguments))},n),r},of.map=function(t,e,n,i){n=n||i||this;var r=pf(this,t=D(ff(t),this.getDimension,this));r._indices=this._indices,r.getRawIndex=r._indices?cf:uf;for(var a=r._storage,o=[],s=this._chunkSize,l=t.length,h=this.count(),u=[],c=r._rawExtent,d=0;d<h;d++){for(var f=0;f<l;f++)u[f]=this.get(t[f],d);u[l]=d;var p=e&&e.apply(n,u);if(null!=p){"object"!=typeof p&&(o[0]=p,p=o);for(var g=this.getRawIndex(d),m=Math.floor(g/s),v=g%s,y=0;y<p.length;y++){var _=t[y],x=p[y],w=c[_],b=a[_];b&&(b[m][v]=x),x<w[0]&&(w[0]=x),x>w[1]&&(w[1]=x)}}}return r},of.downSample=function(t,e,n,i){for(var r=pf(this,[t]),a=r._storage,o=[],s=Math.floor(1/e),l=a[t],h=this.count(),u=this._chunkSize,c=r._rawExtent[t],d=new(tf(this))(h),f=0,p=0;p<h;p+=s){h-p<s&&(s=h-p,o.length=s);for(var g=0;g<s;g++){var m=this.getRawIndex(p+g),v=Math.floor(m/u),y=m%u;o[g]=l[v][y]}var _=n(o),x=this.getRawIndex(Math.min(p+i(o,_)||0,h-1)),w=x%u;(l[Math.floor(x/u)][w]=_)<c[0]&&(c[0]=_),_>c[1]&&(c[1]=_),d[f++]=x}return r._count=f,r._indices=d,r.getRawIndex=cf,r},of.getItemModel=function(t){var e=this.hostModel;return new Ks(this.getRawDataItem(t),e,e&&e.ecModel)},of.diff=function(e){var n=this;return new Zd(e?e.getIndices():[],this.getIndices(),function(t){return df(e,t)},function(t){return df(n,t)})},of.getVisual=function(t){var e=this._visual;return e&&e[t]},of.setVisual=function(t,e){if(jd(t))for(var n in t)t.hasOwnProperty(n)&&this.setVisual(n,t[n]);else this._visual=this._visual||{},this._visual[t]=e},of.setLayout=function(t,e){if(jd(t))for(var n in t)t.hasOwnProperty(n)&&this.setLayout(n,t[n]);else this._layout[t]=e},of.getLayout=function(t){return this._layout[t]},of.getItemLayout=function(t){return this._itemLayouts[t]},of.setItemLayout=function(t,e,n){this._itemLayouts[t]=n?I(this._itemLayouts[t]||{},e):e},of.clearItemLayouts=function(){this._itemLayouts.length=0},of.getItemVisual=function(t,e,n){var i=this._itemVisuals[t],r=i&&i[e];return null!=r||n?r:this.getVisual(e)},of.setItemVisual=function(t,e,n){var i=this._itemVisuals[t]||{},r=this.hasItemVisual;if(this._itemVisuals[t]=i,jd(e))for(var a in e)e.hasOwnProperty(a)&&(i[a]=e[a],r[a]=!0);else i[e]=n,r[e]=!0},of.clearAllVisual=function(){this._visual={},this._itemVisuals=[],this.hasItemVisual={}};function vf(t){t.seriesIndex=this.seriesIndex,t.dataIndex=this.dataIndex,t.dataType=this.dataType}function yf(t,e,n){ch.isInstance(e)||(e=ch.seriesDataToSource(e)),n=n||{},t=(t||[]).slice();for(var i=(n.dimsDef||[]).slice(),l=Q(n.encodeDef),r=Q(),a=Q(),h=[],o=function(t,e,n,i){var r=Math.max(t.dimensionsDetectCount||1,e.length,n.length,i||0);return A(e,function(t){var e=t.dimsDef;e&&(r=Math.max(r,e.length))}),r}(e,t,i,n.dimCount),s=0;s<o;s++){var u=i[s]=I({},N(i[s])?i[s]:{name:i[s]}),c=u.name,d=h[s]={otherDims:{}};null!=c&&null==r.get(c)&&(d.name=d.displayName=c,r.set(c,s)),null!=u.type&&(d.type=u.type),null!=u.displayName&&(d.displayName=u.displayName)}l.each(function(t,n){if(1===(t=gr(t).slice()).length&&!E(t[0])&&t[0]<0)l.set(n,!1);else{var i=l.set(n,[]);A(t,function(t,e){E(t)&&(t=r.get(t)),null!=t&&t<o&&(i[e]=t,p(h[t],n,e))})}});var f=0;function p(t,e,n){null!=Xd.get(e)?t.otherDims[e]=n:(t.coordDim=e,t.coordDimIndex=n,a.set(e,!0))}A(t,function(r,t){var a,o,s;if(E(r))a=r,r={};else{a=r.name;var e=r.ordinalMeta;r.ordinalMeta=null,(r=b(r)).ordinalMeta=e,o=r.dimsDef,s=r.otherDims,r.name=r.coordDim=r.coordDimIndex=r.dimsDef=r.otherDims=null}if(!1!==(n=l.get(a))){var n;if(!(n=gr(n)).length)for(var i=0;i<(o&&o.length||1);i++){for(;f<h.length&&null!=h[f].coordDim;)f++;f<h.length&&n.push(f++)}A(n,function(t,e){var n=h[t];if(p(T(n,r),a,e),null==n.name&&o){var i=o[e];N(i)||(i={name:i}),n.name=n.displayName=i.name,n.defaultTooltip=i.defaultTooltip}s&&T(n.otherDims,s)})}});var g=n.generateCoord,m=n.generateCoordCount,v=null!=m;m=g?m||1:0;for(var y,_,x=g||"value",w=0;w<o;w++){null==(d=h[w]=h[w]||{}).coordDim&&(d.coordDim=_f(x,a,v),d.coordDimIndex=0,(!g||m<=0)&&(d.isExtraCoord=!0),m--),null==d.name&&(d.name=_f(d.coordDim,r)),null==d.type&&(y=e,_=w,d.name,mh(y.data,y.sourceFormat,y.seriesLayoutBy,y.dimensionsDefine,y.startIndex,_))&&(d.type="ordinal")}return h}function _f(t,e,n){if(n||null!=e.get(t)){for(var i=0;null!=e.get(t+i);)i++;t+=i}return e.set(t,!0),t}of.setItemGraphicEl=function(t,e){var n=this.hostModel;e&&(e.dataIndex=t,e.dataType=this.dataType,e.seriesIndex=n&&n.seriesIndex,"group"===e.type&&e.traverse(vf,e)),this._graphicEls[t]=e},of.getItemGraphicEl=function(t){return this._graphicEls[t]},of.eachItemGraphicEl=function(n,i){A(this._graphicEls,function(t,e){t&&n&&n.call(i,t,e)})},of.cloneShallow=function(t){if(!t){var e=D(this.dimensions,this.getDimensionInfo,this);t=new af(e,this.hostModel)}if(t._storage=this._storage,rf(t,this),this._indices){var n=this._indices.constructor;t._indices=new n(this._indices)}else t._indices=null;return t.getRawIndex=t._indices?cf:uf,t},of.wrapMethod=function(t,e){var n=this[t];"function"==typeof n&&(this.__wrappedMethods=this.__wrappedMethods||[],this.__wrappedMethods.push(t),this[t]=function(){var t=n.apply(this,arguments);return e.apply(this,[t].concat(Z(arguments)))})},of.TRANSFERABLE_METHODS=["cloneShallow","downSample","map"],of.CHANGABLE_METHODS=["filterSelf","selectRange"];var xf=function(t,e){return yf((e=e||{}).coordDimensions||[],t,{dimsDef:e.dimensionsDefine||t.dimensionsDefine,encodeDef:e.encodeDefine||t.encodeDefine,dimCount:e.dimensionsCount,generateCoord:e.generateCoord,generateCoordCount:e.generateCoordCount})};function wf(t,n,e){var i,r,a,o,s=(e=e||{}).byIndex,l=e.stackedCoordDimension,h=!(!t||!t.get("stack"));if(A(n,function(t,e){E(t)&&(n[e]=t={name:t}),h&&!t.isExtraCoord&&(s||i||!t.ordinalMeta||(i=t),r||"ordinal"===t.type||"time"===t.type||l&&l!==t.coordDim||(r=t))}),!r||s||i||(s=!0),r){a="__\0ecstackresult",o="__\0ecstackedover",i&&(i.createInvertedIndices=!0);var u=r.coordDim,c=r.type,d=0;A(n,function(t){t.coordDim===u&&d++}),n.push({name:a,coordDim:u,coordDimIndex:d,type:c,isExtraCoord:!0,isCalculationCoord:!0}),d++,n.push({name:o,coordDim:o,coordDimIndex:d,type:c,isExtraCoord:!0,isCalculationCoord:!0})}return{stackedDimension:r&&r.name,stackedByDimension:i&&i.name,isStackedByIndex:s,stackedOverDimension:o,stackResultDimension:a}}function bf(t,e){return!!e&&e===t.getCalculationInfo("stackedDimension")}function Sf(t,e){return bf(t,e)?t.getCalculationInfo("stackResultDimension"):e}function Mf(t,e,n){n=n||{},ch.isInstance(t)||(t=ch.seriesDataToSource(t));var i,r=e.get("coordinateSystem"),a=Mh.get(r),o=th(e);o&&(i=D(o.coordSysDims,function(t){var e={name:t},n=o.axisMap.get(t);if(n){var i=n.get("type");e.type=function(t){return"category"===t?"ordinal":"time"===t?"time":"float"}(i)}return e})),i=i||(a&&(a.getDimensionsInfo?a.getDimensionsInfo():a.dimensions.slice())||["x","y"]);var s,l,h=xf(t,{coordDimensions:i,generateCoord:n.generateCoord});o&&A(h,function(t,e){var n=t.coordDim,i=o.categoryAxisMap.get(n);i&&(null==s&&(s=e),t.ordinalMeta=i.getOrdinalMeta()),null!=t.otherDims.itemName&&(l=!0)}),l||null==s||(h[s].otherDims.itemName=0);var u=wf(e,h),c=new af(h,e);c.setCalculationInfo(u);var d=null!=s&&function(t){if(t.sourceFormat===ih){var e=function(t){var e=0;for(;e<t.length&&null==t[e];)e++;return t[e]}(t.data||[]);return null!=e&&!O(yr(e))}}(t)?function(t,e,n,i){return i===s?n:this.defaultDimValueGetter(t,e,n,i)}:null;return c.hasItemOption=!1,c.initData(t,null,d),c}function If(t){this._setting=t||{},this._extent=[1/0,-1/0],this._interval=0,this.init&&this.init.apply(this,arguments)}function Cf(t){this.categories=t.categories||[],this._needCollect=t.needCollect,this._deduplication=t.deduplication,this._map}If.prototype.parse=function(t){return t},If.prototype.getSetting=function(t){return this._setting[t]},If.prototype.contain=function(t){var e=this._extent;return t>=e[0]&&t<=e[1]},If.prototype.normalize=function(t){var e=this._extent;return e[1]===e[0]?.5:(t-e[0])/(e[1]-e[0])},If.prototype.scale=function(t){var e=this._extent;return t*(e[1]-e[0])+e[0]},If.prototype.unionExtent=function(t){var e=this._extent;t[0]<e[0]&&(e[0]=t[0]),t[1]>e[1]&&(e[1]=t[1])},If.prototype.unionExtentFromData=function(t,e){this.unionExtent(t.getApproximateExtent(e))},If.prototype.getExtent=function(){return this._extent.slice()},If.prototype.setExtent=function(t,e){var n=this._extent;isNaN(t)||(n[0]=t),isNaN(e)||(n[1]=e)},If.prototype.isBlank=function(){return this._isBlank},If.prototype.setBlank=function(t){this._isBlank=t},If.prototype.getLabel=null,Or(If),Br(If,{registerWhenExtend:!0}),Cf.createByAxisModel=function(t){var e=t.option,n=e.data,i=n&&D(n,Df);return new Cf({categories:i,needCollect:!i,deduplication:!1!==e.dedplication})};var Tf=Cf.prototype;function Af(t){return t._map||(t._map=Q(t.categories))}function Df(t){return N(t)&&null!=t.value?t.value:t+""}Tf.getOrdinal=function(t){return Af(this).get(t)},Tf.parseAndCollect=function(t){var e,n=this._needCollect;if("string"!=typeof t&&!n)return t;if(n&&!this._deduplication)return e=this.categories.length,this.categories[e]=t,e;var i=Af(this);return null==(e=i.get(t))&&(n?(e=this.categories.length,this.categories[e]=t,i.set(t,e)):e=NaN),e};var kf=If.prototype,Pf=If.extend({type:"ordinal",init:function(t,e){t&&!O(t)||(t=new Cf({categories:t})),this._ordinalMeta=t,this._extent=e||[0,t.categories.length-1]},parse:function(t){return"string"==typeof t?this._ordinalMeta.getOrdinal(t):Math.round(t)},contain:function(t){return t=this.parse(t),kf.contain.call(this,t)&&null!=this._ordinalMeta.categories[t]},normalize:function(t){return kf.normalize.call(this,this.parse(t))},scale:function(t){return Math.round(kf.scale.call(this,t))},getTicks:function(){for(var t=[],e=this._extent,n=e[0];n<=e[1];)t.push(n),n++;return t},getLabel:function(t){if(!this.isBlank())return this._ordinalMeta.categories[t]},count:function(){return this._extent[1]-this._extent[0]+1},unionExtentFromData:function(t,e){this.unionExtent(t.getApproximateExtent(e))},getOrdinalMeta:function(){return this._ordinalMeta},niceTicks:J,niceExtent:J});Pf.create=function(){return new Pf};var Lf=al;function Of(t){return ll(t)+2}function zf(t,e,n){t[e]=Math.max(Math.min(t[e],n[1]),n[0])}function Ef(t,e){isFinite(t[0])||(t[0]=e[0]),isFinite(t[1])||(t[1]=e[1]),zf(t,0,e),zf(t,1,e),t[0]>t[1]&&(t[0]=t[1])}var Nf=al,Rf=If.extend({type:"interval",_interval:0,_intervalPrecision:2,setExtent:function(t,e){var n=this._extent;isNaN(t)||(n[0]=parseFloat(t)),isNaN(e)||(n[1]=parseFloat(e))},unionExtent:function(t){var e=this._extent;t[0]<e[0]&&(e[0]=t[0]),t[1]>e[1]&&(e[1]=t[1]),Rf.prototype.setExtent.call(this,e[0],e[1])},getInterval:function(){return this._interval},setInterval:function(t){this._interval=t,this._niceExtent=this._extent.slice(),this._intervalPrecision=Of(t)},getTicks:function(){return function(t,e,n,i){var r=[];if(!t)return r;e[0]<n[0]&&r.push(e[0]);for(var a=n[0];a<=n[1]&&(r.push(a),(a=Lf(a+t,i))!==r[r.length-1]);)if(1e4<r.length)return[];return e[1]>(r.length?r[r.length-1]:n[1])&&r.push(e[1]),r}(this._interval,this._extent,this._niceExtent,this._intervalPrecision)},getLabel:function(t,e){if(null==t)return"";var n=e&&e.precision;return null==n?n=ll(t)||0:"auto"===n&&(n=this._intervalPrecision),_l(t=Nf(t,n,!0))},niceTicks:function(t,e,n){t=t||5;var i=this._extent,r=i[1]-i[0];if(isFinite(r)){r<0&&(r=-r,i.reverse());var a=function(t,e,n,i){var r={},a=t[1]-t[0],o=r.interval=vl(a/e,!0);null!=n&&o<n&&(o=r.interval=n),null!=i&&i<o&&(o=r.interval=i);var s=r.intervalPrecision=Of(o);return Ef(r.niceTickExtent=[Lf(Math.ceil(t[0]/o)*o,s),Lf(Math.floor(t[1]/o)*o,s)],t),r}(i,t,e,n);this._intervalPrecision=a.intervalPrecision,this._interval=a.interval,this._niceExtent=a.niceTickExtent}},niceExtent:function(t){var e=this._extent;if(e[0]===e[1])if(0!==e[0]){var n=e[0];t.fixMax||(e[1]+=n/2),e[0]-=n/2}else e[1]=1;var i=e[1]-e[0];isFinite(i)||(e[0]=0,e[1]=1),this.niceTicks(t.splitNumber,t.minInterval,t.maxInterval);var r=this._interval;t.fixMin||(e[0]=Nf(Math.floor(e[0]/r)*r)),t.fixMax||(e[1]=Nf(Math.ceil(e[1]/r)*r))}});Rf.create=function(){return new Rf};var Bf="__ec_stack_",Ff="undefined"!=typeof Float32Array?Float32Array:Array;function Vf(t){return t.get("stack")||Bf+t.seriesIndex}function Hf(t){return t.dim+t.index}function Wf(t,e){var n=[];return e.eachSeriesByType(t,function(t){Xf(t)&&!Yf(t)&&n.push(t)}),n}function Gf(t){var h=[];return A(t,function(t){var e=t.getData(),n=t.coordinateSystem.getBaseAxis(),i=n.getExtent(),r="category"===n.type?n.getBandWidth():Math.abs(i[1]-i[0])/e.count(),a=rl(t.get("barWidth"),r),o=rl(t.get("barMaxWidth"),r),s=t.get("barGap"),l=t.get("barCategoryGap");h.push({bandWidth:r,barWidth:a,barMaxWidth:o,barGap:s,barCategoryGap:l,axisKey:Hf(n),stackId:Vf(t)})}),function(t){var c={};A(t,function(t,e){var n=t.axisKey,i=t.bandWidth,r=c[n]||{bandWidth:i,remainedWidth:i,autoWidthCount:0,categoryGap:"20%",gap:"30%",stacks:{}},a=r.stacks;c[n]=r;var o=t.stackId;a[o]||r.autoWidthCount++,a[o]=a[o]||{width:0,maxWidth:0};var s=t.barWidth;s&&!a[o].width&&(a[o].width=s,s=Math.min(r.remainedWidth,s),r.remainedWidth-=s);var l=t.barMaxWidth;l&&(a[o].maxWidth=l);var h=t.barGap;null!=h&&(r.gap=h);var u=t.barCategoryGap;null!=u&&(r.categoryGap=u)});var d={};return A(c,function(t,n){d[n]={};var e=t.stacks,i=t.bandWidth,r=rl(t.categoryGap,i),a=rl(t.gap,1),o=t.remainedWidth,s=t.autoWidthCount,l=(o-r)/(s+(s-1)*a);l=Math.max(l,0),A(e,function(t,e){var n=t.maxWidth;n&&n<l&&(n=Math.min(n,o),t.width&&(n=Math.min(n,t.width)),o-=n,t.width=n,s--)}),l=(o-r)/(s+(s-1)*a),l=Math.max(l,0);var h,u=0;A(e,function(t,e){t.width||(t.width=l),u+=(h=t).width*(1+a)}),h&&(u-=h.width*a);var c=-u/2;A(e,function(t,e){d[n][e]=d[n][e]||{offset:c,width:t.width},c+=t.width*(1+a)})}),d}(h)}function Zf(t,e,n){if(t&&e){var i=t[Hf(e)];return null!=i&&null!=n&&(i=i[Vf(n)]),i}}var Uf={seriesType:"bar",plan:Ou(),reset:function(t){if(Xf(t)&&Yf(t)){var e=t.getData(),u=t.coordinateSystem,c=u.getBaseAxis(),d=u.getOtherAxis(c),f=e.mapDimension(d.dim),p=e.mapDimension(c.dim),g=d.isHorizontal(),m=g?0:1,v=Zf(Gf([t]),c,t).width;return.5<v||(v=.5),{progress:function(t,e){var n,i=t.count,r=new Ff(2*i),a=new Ff(i),o=[],s=[],l=0,h=0;for(;null!=(n=t.next());)s[m]=e.get(f,n),s[1-m]=e.get(p,n),o=u.dataToPoint(s,null,o),r[l++]=o[0],r[l++]=o[1],a[h++]=n;e.setLayout({largePoints:r,largeDataIndices:a,barWidth:v,valueAxisStart:jf(c,d,!1),valueAxisHorizontal:g})}}}}};function Xf(t){return t.coordinateSystem&&"cartesian2d"===t.coordinateSystem.type}function Yf(t){return t.pipelineContext&&t.pipelineContext.large}function jf(t,e){var n,i,r=e.getGlobalExtent();i=r[0]>r[1]?(n=r[1],r[0]):(n=r[0],r[1]);var a=e.toGlobalCoord(e.dataToCoord(0));return a<n&&(a=n),i<a&&(a=i),a}var qf=Rf.prototype,$f=Math.ceil,Kf=Math.floor,Qf=36e5,Jf=864e5,tp=Rf.extend({type:"time",getLabel:function(t){var e=this._stepLvl,n=new Date(t);return kl(e[0],n,this.getSetting("useUTC"))},niceExtent:function(t){var e=this._extent;if(e[0]===e[1]&&(e[0]-=Jf,e[1]+=Jf),e[1]===-1/0&&e[0]===1/0){var n=new Date;e[1]=+new Date(n.getFullYear(),n.getMonth(),n.getDate()),e[0]=e[1]-Jf}this.niceTicks(t.splitNumber,t.minInterval,t.maxInterval);var i=this._interval;t.fixMin||(e[0]=al(Kf(e[0]/i)*i)),t.fixMax||(e[1]=al($f(e[1]/i)*i))},niceTicks:function(t,e,n){t=t||10;var i=this._extent,r=i[1]-i[0],a=r/t;null!=e&&a<e&&(a=e),null!=n&&n<a&&(a=n);var o=ep.length,s=function(t,e,n,i){for(;n<i;){var r=n+i>>>1;t[r][1]<e?n=1+r:i=r}return n}(ep,a,0,o),l=ep[Math.min(s,o-1)],h=l[1];"year"===l[0]&&(h*=vl(r/h/t,!0));var u=this.getSetting("useUTC")?0:60*new Date(+i[0]||+i[1]).getTimezoneOffset()*1e3,c=[Math.round($f((i[0]-u)/h)*h+u),Math.round(Kf((i[1]-u)/h)*h+u)];Ef(c,i),this._stepLvl=l,this._interval=h,this._niceExtent=c},parse:function(t){return+pl(t)}});A(["contain","normalize"],function(e){tp.prototype[e]=function(t){return qf[e].call(this,this.parse(t))}});var ep=[["hh:mm:ss",1e3],["hh:mm:ss",5e3],["hh:mm:ss",1e4],["hh:mm:ss",15e3],["hh:mm:ss",3e4],["hh:mm\nMM-dd",6e4],["hh:mm\nMM-dd",3e5],["hh:mm\nMM-dd",6e5],["hh:mm\nMM-dd",9e5],["hh:mm\nMM-dd",18e5],["hh:mm\nMM-dd",Qf],["hh:mm\nMM-dd",72e5],["hh:mm\nMM-dd",6*Qf],["hh:mm\nMM-dd",432e5],["MM-dd\nyyyy",Jf],["MM-dd\nyyyy",2*Jf],["MM-dd\nyyyy",3*Jf],["MM-dd\nyyyy",4*Jf],["MM-dd\nyyyy",5*Jf],["MM-dd\nyyyy",6*Jf],["week",7*Jf],["MM-dd\nyyyy",864e6],["week",14*Jf],["week",21*Jf],["month",31*Jf],["week",42*Jf],["month",62*Jf],["week",70*Jf],["quarter",95*Jf],["month",31*Jf*4],["month",13392e6],["half-year",16416e6],["month",31*Jf*8],["month",26784e6],["year",380*Jf]];tp.create=function(t){return new tp({useUTC:t.ecModel.get("useUTC")})};var np=If.prototype,ip=Rf.prototype,rp=ll,ap=al,op=Math.floor,sp=Math.ceil,lp=Math.pow,hp=Math.log,up=If.extend({type:"log",base:10,$constructor:function(){If.apply(this,arguments),this._originalScale=new Rf},getTicks:function(){var n=this._originalScale,i=this._extent,r=n.getExtent();return D(ip.getTicks.call(this),function(t){var e=al(lp(this.base,t));return e=t===i[0]&&n.__fixMin?cp(e,r[0]):e,e=t===i[1]&&n.__fixMax?cp(e,r[1]):e},this)},getLabel:ip.getLabel,scale:function(t){return t=np.scale.call(this,t),lp(this.base,t)},setExtent:function(t,e){var n=this.base;t=hp(t)/hp(n),e=hp(e)/hp(n),ip.setExtent.call(this,t,e)},getExtent:function(){var t=this.base,e=np.getExtent.call(this);e[0]=lp(t,e[0]),e[1]=lp(t,e[1]);var n=this._originalScale,i=n.getExtent();return n.__fixMin&&(e[0]=cp(e[0],i[0])),n.__fixMax&&(e[1]=cp(e[1],i[1])),e},unionExtent:function(t){this._originalScale.unionExtent(t);var e=this.base;t[0]=hp(t[0])/hp(e),t[1]=hp(t[1])/hp(e),np.unionExtent.call(this,t)},unionExtentFromData:function(t,e){this.unionExtent(t.getApproximateExtent(e))},niceTicks:function(t){t=t||10;var e=this._extent,n=e[1]-e[0];if(!(n==1/0||n<=0)){var i=gl(n);for(t/n*i<=.5&&(i*=10);!isNaN(i)&&Math.abs(i)<1&&0<Math.abs(i);)i*=10;var r=[al(sp(e[0]/i)*i),al(op(e[1]/i)*i)];this._interval=i,this._niceExtent=r}},niceExtent:function(t){ip.niceExtent.call(this,t);var e=this._originalScale;e.__fixMin=t.fixMin,e.__fixMax=t.fixMax}});function cp(t,e){return ap(t,rp(e))}function dp(t,e){var n,i,r,a=t.type,o=e.getMin(),s=e.getMax(),l=null!=o,h=null!=s,u=t.getExtent();"ordinal"===a?n=e.getCategories().length:(O(i=e.get("boundaryGap"))||(i=[i||0,i||0]),"boolean"==typeof i[0]&&(i=[0,0]),i[0]=rl(i[0],1),i[1]=rl(i[1],1),r=u[1]-u[0]||Math.abs(u[0])),null==o&&(o="ordinal"===a?n?0:NaN:u[0]-i[0]*r),null==s&&(s="ordinal"===a?n?n-1:NaN:u[1]+i[1]*r),"dataMin"===o?o=u[0]:"function"==typeof o&&(o=o({min:u[0],max:u[1]})),"dataMax"===s?s=u[1]:"function"==typeof s&&(s=s({min:u[0],max:u[1]})),null!=o&&isFinite(o)||(o=NaN),null!=s&&isFinite(s)||(s=NaN),t.setBlank(V(o)||V(s)||"ordinal"===a&&!t.getOrdinalMeta().categories.length),e.getNeedCrossZero()&&(0<o&&0<s&&!l&&(o=0),o<0&&s<0&&!h&&(s=0));var c=e.ecModel;if(c&&"time"===a){var d,f=Wf("bar",c);if(A(f,function(t){d|=t.getBaseAxis()===e.axis}),d){var p=Gf(f),g=function(t,e,n,i){var r=n.axis.getExtent(),a=r[1]-r[0],o=Zf(i,n.axis);if(void 0===o)return{min:t,max:e};var s=1/0;A(o,function(t){s=Math.min(t.offset,s)});var l=-1/0;A(o,function(t){l=Math.max(t.offset+t.width,l)}),s=Math.abs(s),l=Math.abs(l);var h=s+l,u=e-t,c=u/(1-(s+l)/a)-u;return{min:t-=s/h*c,max:e+=l/h*c}}(o,s,e,p);o=g.min,s=g.max}}return[o,s]}function fp(t,e){var n=dp(t,e),i=null!=e.getMin(),r=null!=e.getMax(),a=e.get("splitNumber");"log"===t.type&&(t.base=e.get("logBase"));var o=t.type;t.setExtent(n[0],n[1]),t.niceExtent({splitNumber:a,fixMin:i,fixMax:r,minInterval:"interval"===o||"time"===o?e.get("minInterval"):null,maxInterval:"interval"===o||"time"===o?e.get("maxInterval"):null});var s=e.get("interval");null!=s&&t.setInterval&&t.setInterval(s)}function pp(t,e){if(e=e||t.get("type"))switch(e){case"category":return new Pf(t.getOrdinalMeta?t.getOrdinalMeta():t.getCategories(),[1/0,-1/0]);case"value":return new Rf;default:return(If.getClass(e)||Rf).create(t)}}function gp(n){var e,i=n.getLabelModel().get("formatter"),r="category"===n.type?n.scale.getExtent()[0]:null;return"string"==typeof i?(e=i,i=function(t){return t=n.scale.getLabel(t),e.replace("{value}",null!=t?t:"")}):"function"==typeof i?function(t,e){return null!=r&&(e=t-r),i(mp(n,t),e)}:function(t){return n.scale.getLabel(t)}}function mp(t,e){return"category"===t.type?t.scale.getLabel(e):e}function vp(t){var e=t.get("interval");return null==e?"auto":e}function yp(t){return"category"===t.type&&0===vp(t.getLabelModel())}A(["contain","normalize"],function(e){up.prototype[e]=function(t){return t=hp(t)/hp(this.base),np[e].call(this,t)}}),up.create=function(){return new up};var _p={getMin:function(t){var e=this.option,n=t||null==e.rangeStart?e.min:e.rangeStart;return this.axis&&null!=n&&"dataMin"!==n&&"function"!=typeof n&&!V(n)&&(n=this.axis.scale.parse(n)),n},getMax:function(t){var e=this.option,n=t||null==e.rangeEnd?e.max:e.rangeEnd;return this.axis&&null!=n&&"dataMax"!==n&&"function"!=typeof n&&!V(n)&&(n=this.axis.scale.parse(n)),n},getNeedCrossZero:function(){var t=this.option;return null==t.rangeStart&&null==t.rangeEnd&&!t.scale},getCoordSysModel:J,setRange:function(t,e){this.option.rangeStart=t,this.option.rangeEnd=e},resetRange:function(){this.option.rangeStart=this.option.rangeEnd=null}},xp=is({type:"triangle",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(t,e){var n=e.cx,i=e.cy,r=e.width/2,a=e.height/2;t.moveTo(n,i-a),t.lineTo(n+r,i+a),t.lineTo(n-r,i+a),t.closePath()}}),wp=is({type:"diamond",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(t,e){var n=e.cx,i=e.cy,r=e.width/2,a=e.height/2;t.moveTo(n,i-a),t.lineTo(n+r,i),t.lineTo(n,i+a),t.lineTo(n-r,i),t.closePath()}}),bp=is({type:"pin",shape:{x:0,y:0,width:0,height:0},buildPath:function(t,e){var n=e.x,i=e.y,r=e.width/5*3,a=Math.max(r,e.height),o=r/2,s=o*o/(a-o),l=i-a+o+s,h=Math.asin(s/o),u=Math.cos(h)*o,c=Math.sin(h),d=Math.cos(h),f=.6*o,p=.7*o;t.moveTo(n-u,l+s),t.arc(n,l,o,Math.PI-h,2*Math.PI+h),t.bezierCurveTo(n+u-c*f,l+s+d*f,n,i-p,n,i),t.bezierCurveTo(n,i-p,n-u+c*f,l+s+d*f,n-u,l+s),t.closePath()}}),Sp=is({type:"arrow",shape:{x:0,y:0,width:0,height:0},buildPath:function(t,e){var n=e.height,i=e.width,r=e.x,a=e.y,o=i/3*2;t.moveTo(r,a),t.lineTo(r+o,a+n),t.lineTo(r,a+n/4*3),t.lineTo(r-o,a+n),t.lineTo(r,a),t.closePath()}}),Mp={line:function(t,e,n,i,r){r.x1=t,r.y1=e+i/2,r.x2=t+n,r.y2=e+i/2},rect:function(t,e,n,i,r){r.x=t,r.y=e,r.width=n,r.height=i},roundRect:function(t,e,n,i,r){r.x=t,r.y=e,r.width=n,r.height=i,r.r=Math.min(n,i)/4},square:function(t,e,n,i,r){var a=Math.min(n,i);r.x=t,r.y=e,r.width=a,r.height=a},circle:function(t,e,n,i,r){r.cx=t+n/2,r.cy=e+i/2,r.r=Math.min(n,i)/2},diamond:function(t,e,n,i,r){r.cx=t+n/2,r.cy=e+i/2,r.width=n,r.height=i},pin:function(t,e,n,i,r){r.x=t+n/2,r.y=e+i/2,r.width=n,r.height=i},arrow:function(t,e,n,i,r){r.x=t+n/2,r.y=e+i/2,r.width=n,r.height=i},triangle:function(t,e,n,i,r){r.cx=t+n/2,r.cy=e+i/2,r.width=n,r.height=i}},Ip={};A({line:Bo,rect:No,roundRect:No,square:No,circle:So,diamond:wp,pin:bp,arrow:Sp,triangle:xp},function(t,e){Ip[e]=new t});var Cp=is({type:"symbol",shape:{symbolType:"",x:0,y:0,width:0,height:0},calculateTextPosition:function(t,e,n){var i=oi(t,e,n),r=this.shape;return r&&"pin"===r.symbolType&&"inside"===e.textPosition&&(i.y=n.y+.4*n.height),i},buildPath:function(t,e,n){var i=e.symbolType;if("none"!==i){var r=Ip[i];r=r||Ip[i="rect"],Mp[i](e.x,e.y,e.width,e.height,r.shape),r.buildPath(t,r.shape,n)}}});function Tp(t,e){if("image"!==this.type){var n=this.style,i=this.shape;i&&"line"===i.symbolType?n.stroke=t:this.__isEmptyBrush?(n.stroke=t,n.fill=e||"#fff"):(n.fill&&(n.fill=t),n.stroke&&(n.stroke=t)),this.dirty(!1)}}function Ap(t,e,n,i,r,a,o){var s,l=0===t.indexOf("empty");return l&&(t=t.substr(5,1).toLowerCase()+t.substr(6)),(s=0===t.indexOf("image://")?as(t.slice(8),new vn(e,n,i,r),o?"center":"cover"):0===t.indexOf("path://")?rs(t.slice(7),{},new vn(e,n,i,r),o?"center":"cover"):new Cp({shape:{symbolType:t,x:e,y:n,width:i,height:r}})).__isEmptyBrush=l,s.setColor=Tp,s.setColor(a),s}var Dp={isDimensionStacked:bf,enableDataStack:wf,getStackedDimension:Sf};var kp=(Object.freeze||Object)({createList:function(t){return Mf(t.getSource(),t)},getLayoutRect:Fl,dataStack:Dp,createScale:function(t,e){var n=e;Ks.isInstance(e)||S(n=new Ks(e),_p);var i=pp(n);return i.setExtent(t[0],t[1]),fp(i,n),i},mixinAxisModelCommonMethods:function(t){S(t,_p)},completeDimensions:yf,createDimensions:xf,createSymbol:Ap}),Pp=1e-8;function Lp(t,e){return Math.abs(t-e)<Pp}function Op(t,e,n){var i=0,r=t[0];if(!r)return!1;for(var a=1;a<t.length;a++){var o=t[a];i+=Ga(r[0],r[1],o[0],o[1],e,n),r=o}var s=t[0];return Lp(r[0],s[0])&&Lp(r[1],s[1])||(i+=Ga(r[0],r[1],s[0],s[1],e,n)),0!==i}function zp(t,e,n){if(this.name=t,this.geometries=e,n)n=[n[0],n[1]];else{var i=this.getBoundingRect();n=[i.x+i.width/2,i.y+i.height/2]}this.center=n}function Ep(t,e,n){for(var i=[],r=e[0],a=e[1],o=0;o<t.length;o+=2){var s=t.charCodeAt(o)-64,l=t.charCodeAt(o+1)-64;s=s>>1^-(1&s),l=l>>1^-(1&l),r=s+=r,a=l+=a,i.push([s/n,l/n])}return i}zp.prototype={constructor:zp,properties:null,getBoundingRect:function(){var t=this._rect;if(t)return t;for(var e=Number.MAX_VALUE,n=[e,e],i=[-e,-e],r=[],a=[],o=this.geometries,s=0;s<o.length;s++){if("polygon"===o[s].type)va(o[s].exterior,r,a),_t(n,n,r),xt(i,i,a)}return 0===s&&(n[0]=n[1]=i[0]=i[1]=0),this._rect=new vn(n[0],n[1],i[0]-n[0],i[1]-n[1])},contain:function(t){var e=this.getBoundingRect(),n=this.geometries;if(!e.contain(t[0],t[1]))return!1;t:for(var i=0,r=n.length;i<r;i++)if("polygon"===n[i].type){var a=n[i].exterior,o=n[i].interiors;if(Op(a,t[0],t[1])){for(var s=0;s<(o?o.length:0);s++)if(Op(o[s]))continue t;return!0}}return!1},transformTo:function(t,e,n,i){var r=this.getBoundingRect(),a=r.width/r.height;n?i=i||n/a:n=a*i;for(var o=new vn(t,e,n,i),s=r.calculateTransform(o),l=this.geometries,h=0;h<l.length;h++)if("polygon"===l[h].type){for(var u=l[h].exterior,c=l[h].interiors,d=0;d<u.length;d++)yt(u[d],u[d],s);for(var f=0;f<(c?c.length:0);f++)for(d=0;d<c[f].length;d++)yt(c[f][d],c[f][d],s)}(r=this._rect).copy(o),this.center=[r.x+r.width/2,r.y+r.height/2]},cloneShallow:function(t){null==t&&(t=this.name);var e=new zp(t,this.geometries,this.center);return e._rect=this._rect,e.transformTo=null,e}};function Np(t){return function(t){if(!t.UTF8Encoding)return;var e=t.UTF8Scale;null==e&&(e=1024);for(var n=t.features,i=0;i<n.length;i++)for(var r=n[i].geometry,a=r.coordinates,o=r.encodeOffsets,s=0;s<a.length;s++){var l=a[s];if("Polygon"===r.type)a[s]=Ep(l,o[s],e);else if("MultiPolygon"===r.type)for(var h=0;h<l.length;h++){var u=l[h];l[h]=Ep(u,o[s][h],e)}}t.UTF8Encoding=!1}(t),D(C(t.features,function(t){return t.geometry&&t.properties&&0<t.geometry.coordinates.length}),function(t){var e=t.properties,n=t.geometry,i=n.coordinates,r=[];"Polygon"===n.type&&r.push({type:"polygon",exterior:i[0],interiors:i.slice(1)}),"MultiPolygon"===n.type&&A(i,function(t){t[0]&&r.push({type:"polygon",exterior:t[0],interiors:t.slice(1)})});var a=new zp(e.name,r,e.cp);return a.properties=e,a})}var Rp=Mr();function Bp(t){return"category"===t.type?function(t){var e=t.getLabelModel(),n=Vp(t,e);return!e.get("show")||t.scale.isBlank()?{labels:[],labelCategoryInterval:n.labelCategoryInterval}:n}(t):function(n){var t=n.scale.getTicks(),i=gp(n);return{labels:D(t,function(t,e){return{formattedLabel:i(t,e),rawLabel:n.scale.getLabel(t),tickValue:t}})}}(t)}function Fp(t,e){return"category"===t.type?function(t,e){var n,i,r=Hp(t,"ticks"),a=vp(e),o=Wp(r,a);if(o)return o;e.get("show")&&!t.scale.isBlank()||(n=[]);if(z(a))n=Up(t,a,!0);else if("auto"===a){var s=Vp(t,t.getLabelModel());i=s.labelCategoryInterval,n=D(s.labels,function(t){return t.tickValue})}else n=Zp(t,i=a,!0);return Gp(r,a,{ticks:n,tickCategoryInterval:i})}(t,e):{ticks:t.scale.getTicks()}}function Vp(t,e){var n,i=Hp(t,"labels"),r=vp(e),a=Wp(i,r);return a||Gp(i,r,{labels:z(r)?Up(t,r):Zp(t,n="auto"===r?function(t){var e=Rp(t).autoInterval;return null!=e?e:Rp(t).autoInterval=t.calculateCategoryInterval()}(t):r),labelCategoryInterval:n})}function Hp(t,e){return Rp(t)[e]||(Rp(t)[e]=[])}function Wp(t,e){for(var n=0;n<t.length;n++)if(t[n].key===e)return t[n].value}function Gp(t,e,n){return t.push({key:e,value:n}),n}function Zp(t,e,n){var i=gp(t),r=t.scale,a=r.getExtent(),o=t.getLabelModel(),s=[],l=Math.max((e||0)+1,1),h=a[0],u=r.count();0!==h&&1<l&&2<u/l&&(h=Math.round(Math.ceil(h/l)*l));var c=yp(t),d=o.get("showMinLabel")||c,f=o.get("showMaxLabel")||c;d&&h!==a[0]&&g(a[0]);for(var p=h;p<=a[1];p+=l)g(p);function g(t){s.push(n?t:{formattedLabel:i(t),rawLabel:r.getLabel(t),tickValue:t})}return f&&p-l!==a[1]&&g(a[1]),s}function Up(t,n,i){var r=t.scale,a=gp(t),o=[];return A(r.getTicks(),function(t){var e=r.getLabel(t);n(t,e)&&o.push(i?t:{formattedLabel:a(t),rawLabel:e,tickValue:t})}),o}function Xp(t,e,n){this.dim=t,this.scale=e,this._extent=n||[0,0],this.inverse=!1,this.onBand=!1}var Yp=[0,1];function jp(t,e){var n=(t[1]-t[0])/e/2;t[0]+=n,t[1]-=n}Xp.prototype={constructor:Xp,contain:function(t){var e=this._extent,n=Math.min(e[0],e[1]),i=Math.max(e[0],e[1]);return n<=t&&t<=i},containData:function(t){return this.contain(this.dataToCoord(t))},getExtent:function(){return this._extent.slice()},getPixelPrecision:function(t){return hl(t||this.scale.getExtent(),this._extent)},setExtent:function(t,e){var n=this._extent;n[0]=t,n[1]=e},dataToCoord:function(t,e){var n=this._extent,i=this.scale;return t=i.normalize(t),this.onBand&&"ordinal"===i.type&&jp(n=n.slice(),i.count()),il(t,Yp,n,e)},coordToData:function(t,e){var n=this._extent,i=this.scale;this.onBand&&"ordinal"===i.type&&jp(n=n.slice(),i.count());var r=il(t,n,Yp,e);return this.scale.scale(r)},pointToData:function(t,e){},getTicksCoords:function(t){var e=(t=t||{}).tickModel||this.getTickModel(),n=Fp(this,e),i=D(n.ticks,function(t){return{coord:this.dataToCoord(t),tickValue:t}},this),r=e.get("alignWithLabel");return function(t,e,n,i,r){var a=e.length;if(!t.onBand||i||!a)return;var o,s=t.getExtent();if(1===a)e[0].coord=s[0],o=e[1]={coord:s[0]};else{var l=e[1].coord-e[0].coord;A(e,function(t){t.coord-=l/2;var e=e||0;0<e%2&&(t.coord-=l/(2*(e+1)))}),o={coord:e[a-1].coord+l},e.push(o)}var h=s[0]>s[1];u(e[0].coord,s[0])&&(r?e[0].coord=s[0]:e.shift());r&&u(s[0],e[0].coord)&&e.unshift({coord:s[0]});u(s[1],o.coord)&&(r?o.coord=s[1]:e.pop());r&&u(o.coord,s[1])&&e.push({coord:s[1]});function u(t,e){return h?e<t:t<e}}(this,i,n.tickCategoryInterval,r,t.clamp),i},getViewLabels:function(){return Bp(this).labels},getLabelModel:function(){return this.model.getModel("axisLabel")},getTickModel:function(){return this.model.getModel("axisTick")},getBandWidth:function(){var t=this._extent,e=this.scale.getExtent(),n=e[1]-e[0]+(this.onBand?1:0);0===n&&(n=1);var i=Math.abs(t[1]-t[0]);return Math.abs(i)/n},isHorizontal:null,getRotate:null,calculateCategoryInterval:function(){return function(t){var e=function(t){var e=t.getLabelModel();return{axisRotate:t.getRotate?t.getRotate():t.isHorizontal&&!t.isHorizontal()?90:0,labelRotate:e.get("rotate")||0,font:e.getFont()}}(t),n=gp(t),i=(e.axisRotate-e.labelRotate)/180*Math.PI,r=t.scale,a=r.getExtent(),o=r.count();if(a[1]-a[0]<1)return 0;var s=1;40<o&&(s=Math.max(1,Math.floor(o/40)));for(var l=a[0],h=t.dataToCoord(l+1)-t.dataToCoord(l),u=Math.abs(h*Math.cos(i)),c=Math.abs(h*Math.sin(i)),d=0,f=0;l<=a[1];l+=s){var p,g,m=ii(n(l),e.font,"center","top");p=1.3*m.width,g=1.3*m.height,d=Math.max(d,p,7),f=Math.max(f,g,7)}var v=d/u,y=f/c;isNaN(v)&&(v=1/0),isNaN(y)&&(y=1/0);var _=Math.max(0,Math.floor(Math.min(v,y))),x=Rp(t.model),w=x.lastAutoInterval,b=x.lastTickCount;return null!=w&&null!=b&&Math.abs(w-_)<=1&&Math.abs(b-o)<=1&&_<w?_=w:(x.lastTickCount=o,x.lastAutoInterval=_),_}(this)}};var qp=Np,$p={};A(["map","each","filter","indexOf","inherits","reduce","filter","bind","curry","isArray","isString","isObject","isFunction","extend","defaults","clone","merge"],function(t){$p[t]=tt[t]});var Kp={};function Qp(t,e){var n=t.mapDimension("defaultedLabel",!0),i=n.length;if(1===i)return au(t,e,n[0]);if(i){for(var r=[],a=0;a<n.length;a++){var o=au(t,e,n[a]);r.push(o)}return r.join(" ")}}function Jp(t,e,n){yn.call(this),this.updateData(t,e,n)}A(["extendShape","extendPath","makePath","makeImage","mergePath","resizePath","createIcon","setHoverStyle","setLabelStyle","setTextStyle","setText","getFont","updateProps","initProps","getTransform","clipPointsByRect","clipRectByRect","Group","Image","Text","Circle","Sector","Ring","Polygon","Polyline","Rect","Line","BezierCurve","Arc","IncrementalDisplayable","CompoundPath","LinearGradient","RadialGradient","BoundingRect"],function(t){Kp[t]=Zs[t]}),Su.extend({type:"series.line",dependencies:["grid","polar"],getInitialData:function(t,e){return Mf(this.getSource(),this)},defaultOption:{zlevel:0,z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,hoverAnimation:!0,clipOverflow:!0,label:{position:"top"},lineStyle:{width:2,type:"solid"},step:!1,smooth:!1,smoothMonotone:null,symbol:"emptyCircle",symbolSize:4,symbolRotate:null,showSymbol:!0,showAllSymbol:"auto",connectNulls:!1,sampling:"none",animationEasing:"linear",progressive:0,hoverLayerThreshold:1/0}});var tg=Jp.prototype,eg=Jp.getSymbolSize=function(t,e){var n=t.getItemVisual(e,"symbolSize");return n instanceof Array?n.slice():[+n,+n]};function ng(t){return[t[0]/2,t[1]/2]}function ig(t,e){this.parent.drift(t,e)}tg._createSymbol=function(t,e,n,i,r){this.removeAll();var a=Ap(t,-1,-1,2,2,e.getItemVisual(n,"color"),r);a.attr({z2:100,culling:!0,scale:ng(i)}),a.drift=ig,this._symbolType=t,this.add(a)},tg.stopSymbolAnimation=function(t){this.childAt(0).stopAnimation(t)},tg.getSymbolPath=function(){return this.childAt(0)},tg.getScale=function(){return this.childAt(0).scale},tg.highlight=function(){this.childAt(0).trigger("emphasis")},tg.downplay=function(){this.childAt(0).trigger("normal")},tg.setZ=function(t,e){var n=this.childAt(0);n.zlevel=t,n.z=e},tg.setDraggable=function(t){var e=this.childAt(0);e.draggable=t,e.cursor=t?"move":e.cursor},tg.updateData=function(t,e,n){this.silent=!1;var i=t.getItemVisual(e,"symbol")||"circle",r=t.hostModel,a=eg(t,e),o=i!==this._symbolType;if(o){var s=t.getItemVisual(e,"symbolKeepAspect");this._createSymbol(i,t,e,a,s)}else{(l=this.childAt(0)).silent=!1,Ns(l,{scale:ng(a)},r,e)}if(this._updateCommon(t,e,a,n),o){var l=this.childAt(0),h=n&&n.fadeIn,u={scale:l.scale.slice()};h&&(u.style={opacity:l.style.opacity}),l.scale=[0,0],h&&(l.style.opacity=0),Rs(l,u,r,e)}this._seriesModel=r};var rg=["itemStyle"],ag=["emphasis","itemStyle"],og=["label"],sg=["emphasis","label"];function lg(t,e){if(!this.incremental&&!this.useHoverLayer)if("emphasis"===e){var n=this.__symbolOriginalScale,i=n[1]/n[0],r={scale:[Math.max(1.1*n[0],n[0]+3),Math.max(1.1*n[1],n[1]+3*i)]};this.animateTo(r,400,"elasticOut")}else"normal"===e&&this.animateTo({scale:this.__symbolOriginalScale},400,"elasticOut")}function hg(t){this.group=new yn,this._symbolCtor=t||Jp}tg._updateCommon=function(n,t,e,i){var r=this.childAt(0),a=n.hostModel,o=n.getItemVisual(t,"color");"image"!==r.type&&r.useStyle({strokeNoScale:!0});var s=i&&i.itemStyle,l=i&&i.hoverItemStyle,h=i&&i.symbolRotate,u=i&&i.symbolOffset,c=i&&i.labelModel,d=i&&i.hoverLabelModel,f=i&&i.hoverAnimation,p=i&&i.cursorStyle;if(!i||n.hasItemOption){var g=i&&i.itemModel?i.itemModel:n.getItemModel(t);s=g.getModel(rg).getItemStyle(["color"]),l=g.getModel(ag).getItemStyle(),h=g.getShallow("symbolRotate"),u=g.getShallow("symbolOffset"),c=g.getModel(og),d=g.getModel(sg),f=g.getShallow("hoverAnimation"),p=g.getShallow("cursor")}else l=I({},l);var m=r.style;r.attr("rotation",(h||0)*Math.PI/180||0),u&&r.attr("position",[rl(u[0],e[0]),rl(u[1],e[1])]),p&&r.attr("cursor",p),r.setColor(o,i&&i.symbolInnerColor),r.setStyle(s);var v=n.getItemVisual(t,"opacity");null!=v&&(m.opacity=v);var y=n.getItemVisual(t,"liftZ"),_=r.__z2Origin;null!=y?null==_&&(r.__z2Origin=r.z2,r.z2+=y):null!=_&&(r.z2=_,r.__z2Origin=null);var x=i&&i.useNameLabel;Ts(m,l,c,d,{labelFetcher:a,labelDataIndex:t,defaultText:function(t,e){return x?n.getName(t):Qp(n,t)},isRectText:!0,autoColor:o}),r.__symbolOriginalScale=ng(e),r.hoverStyle=l,r.highDownOnUpdate=f&&a.isAnimationEnabled()?lg:null,Ss(r)},tg.fadeOut=function(t,e){var n=this.childAt(0);this.silent=n.silent=!0,e&&e.keepLabel||(n.style.text=null),Ns(n,{style:{opacity:0},scale:[0,0]},this._seriesModel,this.dataIndex,t)},w(Jp,yn);var ug=hg.prototype;function cg(t,e,n,i){return e&&!isNaN(e[0])&&!isNaN(e[1])&&!(i.isIgnore&&i.isIgnore(n))&&!(i.clipShape&&!i.clipShape.contain(e[0],e[1]))&&"none"!==t.getItemVisual(n,"symbol")}function dg(t){return null==t||N(t)||(t={isIgnore:t}),t||{}}function fg(t){var e=t.hostModel;return{itemStyle:e.getModel("itemStyle").getItemStyle(["color"]),hoverItemStyle:e.getModel("emphasis.itemStyle").getItemStyle(),symbolRotate:e.get("symbolRotate"),symbolOffset:e.get("symbolOffset"),hoverAnimation:e.get("hoverAnimation"),labelModel:e.getModel("label"),hoverLabelModel:e.getModel("emphasis.label"),cursorStyle:e.get("cursor")}}function pg(t,e,n){var i,r=t.getBaseAxis(),a=t.getOtherAxis(r),o=function(t,e){var n=0,i=t.scale.getExtent();"start"===e?n=i[0]:"end"===e?n=i[1]:0<i[0]?n=i[0]:i[1]<0&&(n=i[1]);return n}(a,n),s=r.dim,l=a.dim,h=e.mapDimension(l),u=e.mapDimension(s),c="x"===l||"radius"===l?1:0,d=D(t.dimensions,function(t){return e.mapDimension(t)}),f=e.getCalculationInfo("stackResultDimension");return(i|=bf(e,d[0]))&&(d[0]=f),(i|=bf(e,d[1]))&&(d[1]=f),{dataDimsForPoint:d,valueStart:o,valueAxisDim:l,baseAxisDim:s,stacked:!!i,valueDim:h,baseDim:u,baseDataOffset:c,stackedOverDimension:e.getCalculationInfo("stackedOverDimension")}}function gg(t,e,n,i){var r=NaN;t.stacked&&(r=n.get(n.getCalculationInfo("stackedOverDimension"),i)),isNaN(r)&&(r=t.valueStart);var a=t.baseDataOffset,o=[];return o[a]=n.get(t.baseDim,i),o[1-a]=r,e.dataToPoint(o)}ug.updateData=function(r,a){a=dg(a);var o=this.group,s=r.hostModel,l=this._data,h=this._symbolCtor,u=fg(r);l||o.removeAll(),r.diff(l).add(function(t){var e=r.getItemLayout(t);if(cg(r,e,t,a)){var n=new h(r,t,u);n.attr("position",e),r.setItemGraphicEl(t,n),o.add(n)}}).update(function(t,e){var n=l.getItemGraphicEl(e),i=r.getItemLayout(t);cg(r,i,t,a)?(n?(n.updateData(r,t,u),Ns(n,{position:i},s)):(n=new h(r,t)).attr("position",i),o.add(n),r.setItemGraphicEl(t,n)):o.remove(n)}).remove(function(t){var e=l.getItemGraphicEl(t);e&&e.fadeOut(function(){o.remove(e)})}).execute(),this._data=r},ug.isPersistent=function(){return!0},ug.updateLayout=function(){var i=this._data;i&&i.eachItemGraphicEl(function(t,e){var n=i.getItemLayout(e);t.attr("position",n)})},ug.incrementalPrepareUpdate=function(t){this._seriesScope=fg(t),this._data=null,this.group.removeAll()},ug.incrementalUpdate=function(t,e,n){function i(t){t.isGroup||(t.incremental=t.useHoverLayer=!0)}n=dg(n);for(var r=t.start;r<t.end;r++){var a=e.getItemLayout(r);if(cg(e,a,r,n)){var o=new this._symbolCtor(e,r,this._seriesScope);o.traverse(i),o.attr("position",a),this.group.add(o),e.setItemGraphicEl(r,o)}}},ug.remove=function(t){var e=this.group,n=this._data;n&&t?n.eachItemGraphicEl(function(t){t.fadeOut(function(){e.remove(t)})}):e.removeAll()};var mg=_t,vg=xt,yg=ot,_g=it,xg=[],wg=[],bg=[];function Sg(t){return isNaN(t[0])||isNaN(t[1])}function Mg(t,e,n,i,r,a,o,s,l,h){return"none"!==h&&h?function(t,e,n,i,r,a,o,s,l,h,u){for(var c=0,d=n,f=0;f<i;f++){var p=e[d];if(r<=d||d<0)break;if(Sg(p)){if(u){d+=a;continue}break}if(d===n)t[0<a?"moveTo":"lineTo"](p[0],p[1]);else if(0<l){var g=e[c],m="y"===h?1:0,v=(p[m]-g[m])*l;_g(wg,g),wg[m]=g[m]+v,_g(bg,p),bg[m]=p[m]-v,t.bezierCurveTo(wg[0],wg[1],bg[0],bg[1],p[0],p[1])}else t.lineTo(p[0],p[1]);c=d,d+=a}return f}.apply(this,arguments):function(t,e,n,i,r,a,o,s,l,h,u){for(var c=0,d=n,f=0;f<i;f++){var p=e[d];if(r<=d||d<0)break;if(Sg(p)){if(u){d+=a;continue}break}if(d===n)t[0<a?"moveTo":"lineTo"](p[0],p[1]),_g(wg,p);else if(0<l){var g=d+a,m=e[g];if(u)for(;m&&Sg(e[g]);)m=e[g+=a];var v=.5,y=e[c];if(!(m=e[g])||Sg(m))_g(bg,p);else{var _,x;if(Sg(m)&&!u&&(m=p),st(xg,m,y),"x"===h||"y"===h){var w="x"===h?0:1;_=Math.abs(p[w]-y[w]),x=Math.abs(p[w]-m[w])}else _=gt(p,y),x=gt(p,m);yg(bg,p,xg,-l*(1-(v=x/(x+_))))}mg(wg,wg,s),vg(wg,wg,o),mg(bg,bg,s),vg(bg,bg,o),t.bezierCurveTo(wg[0],wg[1],bg[0],bg[1],p[0],p[1]),yg(wg,p,xg,l*v)}else t.lineTo(p[0],p[1]);c=d,d+=a}return f}.apply(this,arguments)}function Ig(t,e){var n=[1/0,1/0],i=[-1/0,-1/0];if(e)for(var r=0;r<t.length;r++){var a=t[r];a[0]<n[0]&&(n[0]=a[0]),a[1]<n[1]&&(n[1]=a[1]),a[0]>i[0]&&(i[0]=a[0]),a[1]>i[1]&&(i[1]=a[1])}return{min:e?n:i,max:e?i:n}}var Cg=no.extend({type:"ec-polyline",shape:{points:[],smooth:0,smoothConstraint:!0,smoothMonotone:null,connectNulls:!1},style:{fill:null,stroke:"#000"},brush:bo(no.prototype.brush),buildPath:function(t,e){var n=e.points,i=0,r=n.length,a=Ig(n,e.smoothConstraint);if(e.connectNulls){for(;0<r&&Sg(n[r-1]);r--);for(;i<r&&Sg(n[i]);i++);}for(;i<r;)i+=Mg(t,n,i,r,r,1,a.min,a.max,e.smooth,e.smoothMonotone,e.connectNulls)+1}}),Tg=no.extend({type:"ec-polygon",shape:{points:[],stackedOnPoints:[],smooth:0,stackedOnSmooth:0,smoothConstraint:!0,smoothMonotone:null,connectNulls:!1},brush:bo(no.prototype.brush),buildPath:function(t,e){var n=e.points,i=e.stackedOnPoints,r=0,a=n.length,o=e.smoothMonotone,s=Ig(n,e.smoothConstraint),l=Ig(i,e.smoothConstraint);if(e.connectNulls){for(;0<a&&Sg(n[a-1]);a--);for(;r<a&&Sg(n[r]);r++);}for(;r<a;){var h=Mg(t,n,r,a,a,1,s.min,s.max,e.smooth,o,e.connectNulls);Mg(t,i,r+h-1,h,a,-1,l.min,l.max,e.stackedOnSmooth,o,e.connectNulls),r+=h+1,t.closePath()}}});function Ag(t,e){if(t.length===e.length){for(var n=0;n<t.length;n++){var i=t[n],r=e[n];if(i[0]!==r[0]||i[1]!==r[1])return}return!0}}function Dg(t){return"number"==typeof t?t:t?.5:0}function kg(t){var e=t.getGlobalExtent();if(t.onBand){var n=t.getBandWidth()/2-1,i=e[1]>e[0]?1:-1;e[0]+=i*n,e[1]-=i*n}return e}function Pg(t,e,n,i){return"polar"===t.type?function(t,e,n,i){var r=t.getAngleAxis(),a=t.getRadiusAxis().getExtent().slice();a[0]>a[1]&&a.reverse();var o=r.getExtent(),s=Math.PI/180;n&&(a[0]-=.5,a[1]+=.5);var l=new Io({shape:{cx:al(t.cx,1),cy:al(t.cy,1),r0:al(a[0],1),r:al(a[1],1),startAngle:-o[0]*s,endAngle:-o[1]*s,clockwise:r.inverse}});return e&&(l.shape.endAngle=-o[0]*s,Rs(l,{shape:{endAngle:-o[1]*s}},i)),l}(t,e,n,i):function(t,e,n,i){var r=kg(t.getAxis("x")),a=kg(t.getAxis("y")),o=t.getBaseAxis().isHorizontal(),s=Math.min(r[0],r[1]),l=Math.min(a[0],a[1]),h=Math.max(r[0],r[1])-s,u=Math.max(a[0],a[1])-l;if(n)s-=.5,h+=.5,l-=.5,u+=.5;else{var c=i.get("lineStyle.width")||2,d=i.get("clipOverflow")?c/2:Math.max(h,u);o?(l-=d,u+=2*d):(s-=d,h+=2*d)}var f=new No({shape:{x:s,y:l,width:h,height:u}});return e&&(f.shape[o?"width":"height"]=0,Rs(f,{shape:{width:h,height:u}},i)),f}(t,e,n,i)}function Lg(t,e,n){for(var i=e.getBaseAxis(),r="x"===i.dim||"radius"===i.dim?0:1,a=[],o=0;o<t.length-1;o++){var s=t[o+1],l=t[o];a.push(l);var h=[];switch(n){case"end":h[r]=s[r],h[1-r]=l[1-r],a.push(h);break;case"middle":var u=(l[r]+s[r])/2,c=[];h[r]=c[r]=u,h[1-r]=l[1-r],c[1-r]=s[1-r],a.push(h),a.push(c);break;default:h[r]=l[r],h[1-r]=s[1-r],a.push(h)}}return t[o]&&a.push(t[o]),a}function Og(t,e,n){var i=t.get("showAllSymbol"),r="auto"===i;if(!i||r){var a=n.getAxesByScale("ordinal")[0];if(a&&(!r||!function(t,e){var n=t.getExtent(),i=Math.abs(n[1]-n[0])/t.scale.count();isNaN(i)&&(i=0);for(var r=e.count(),a=Math.max(1,Math.round(r/5)),o=0;o<r;o+=a)if(1.5*Jp.getSymbolSize(e,o)[t.isHorizontal()?1:0]>i)return!1;return!0}(a,e))){var o=e.mapDimension(a.dim),s={};return A(a.getViewLabels(),function(t){s[t.tickValue]=1}),function(t){return!s.hasOwnProperty(e.get(o,t))}}}}Nu.extend({type:"line",init:function(){var t=new yn,e=new hg;this.group.add(e.group),this._symbolDraw=e,this._lineGroup=t},render:function(t,e,n){var i=t.coordinateSystem,r=this.group,a=t.getData(),o=t.getModel("lineStyle"),s=t.getModel("areaStyle"),l=a.mapArray(a.getItemLayout),h="polar"===i.type,u=this._coordSys,c=this._symbolDraw,d=this._polyline,f=this._polygon,p=this._lineGroup,g=t.get("animation"),m=!s.isEmpty(),v=s.get("origin"),y=function(t,e,n){if(!n.valueDim)return[];for(var i=[],r=0,a=e.count();r<a;r++)i.push(gg(n,t,e,r));return i}(i,a,pg(i,a,v)),_=t.get("showSymbol"),x=_&&!h&&Og(t,a,i),w=this._data;w&&w.eachItemGraphicEl(function(t,e){t.__temp&&(r.remove(t),w.setItemGraphicEl(e,null))}),_||c.remove(),r.add(p);var b=!h&&t.get("step");d&&u.type===i.type&&b===this._step?(m&&!f?f=this._newPolygon(l,y,i,g):f&&!m&&(p.remove(f),f=this._polygon=null),p.setClipPath(Pg(i,!1,!1,t)),_&&c.updateData(a,{isIgnore:x,clipShape:Pg(i,!1,!0,t)}),a.eachItemGraphicEl(function(t){t.stopAnimation(!0)}),Ag(this._stackedOnPoints,y)&&Ag(this._points,l)||(g?this._updateAnimation(a,y,i,n,b,v):(b&&(l=Lg(l,i,b),y=Lg(y,i,b)),d.setShape({points:l}),f&&f.setShape({points:l,stackedOnPoints:y})))):(_&&c.updateData(a,{isIgnore:x,clipShape:Pg(i,!1,!0,t)}),b&&(l=Lg(l,i,b),y=Lg(y,i,b)),d=this._newPolyline(l,i,g),m&&(f=this._newPolygon(l,y,i,g)),p.setClipPath(Pg(i,!0,!1,t)));var S=function(t,e){var n=t.getVisual("visualMeta");if(n&&n.length&&t.count()&&"cartesian2d"===e.type){for(var i,r,a=n.length-1;0<=a;a--){var o=n[a].dimension,s=t.dimensions[o],l=t.getDimensionInfo(s);if("x"===(i=l&&l.coordDim)||"y"===i){r=n[a];break}}if(r){var h=e.getAxis(i),u=D(r.stops,function(t){return{coord:h.toGlobalCoord(h.dataToCoord(t.value)),color:t.color}}),c=u.length,d=r.outerColors.slice();c&&u[0].coord>u[c-1].coord&&(u.reverse(),d.reverse());var f=u[0].coord-10,p=u[c-1].coord+10,g=p-f;if(g<.001)return"transparent";A(u,function(t){t.offset=(t.coord-f)/g}),u.push({offset:c?u[c-1].offset:.5,color:d[1]||"transparent"}),u.unshift({offset:c?u[0].offset:.5,color:d[0]||"transparent"});var m=new Uo(0,0,0,0,u,!0);return m[i]=f,m[i+"2"]=p,m}}}(a,i)||a.getVisual("color");d.useStyle(T(o.getLineStyle(),{fill:"none",stroke:S,lineJoin:"bevel"}));var M=t.get("smooth");if(M=Dg(t.get("smooth")),d.setShape({smooth:M,smoothMonotone:t.get("smoothMonotone"),connectNulls:t.get("connectNulls")}),f){var I=a.getCalculationInfo("stackedOnSeries"),C=0;f.useStyle(T(s.getAreaStyle(),{fill:S,opacity:.7,lineJoin:"bevel"})),I&&(C=Dg(I.get("smooth"))),f.setShape({smooth:M,stackedOnSmooth:C,smoothMonotone:t.get("smoothMonotone"),connectNulls:t.get("connectNulls")})}this._data=a,this._coordSys=i,this._stackedOnPoints=y,this._points=l,this._step=b,this._valueOrigin=v},dispose:function(){},highlight:function(t,e,n,i){var r=t.getData(),a=Sr(r,i);if(!(a instanceof Array)&&null!=a&&0<=a){var o=r.getItemGraphicEl(a);if(!o){var s=r.getItemLayout(a);if(!s)return;(o=new Jp(r,a)).position=s,o.setZ(t.get("zlevel"),t.get("z")),o.ignore=isNaN(s[0])||isNaN(s[1]),o.__temp=!0,r.setItemGraphicEl(a,o),o.stopSymbolAnimation(!0),this.group.add(o)}o.highlight()}else Nu.prototype.highlight.call(this,t,e,n,i)},downplay:function(t,e,n,i){var r=t.getData(),a=Sr(r,i);if(null!=a&&0<=a){var o=r.getItemGraphicEl(a);o&&(o.__temp?(r.setItemGraphicEl(a,null),this.group.remove(o)):o.downplay())}else Nu.prototype.downplay.call(this,t,e,n,i)},_newPolyline:function(t){var e=this._polyline;return e&&this._lineGroup.remove(e),e=new Cg({shape:{points:t},silent:!0,z2:10}),this._lineGroup.add(e),this._polyline=e},_newPolygon:function(t,e){var n=this._polygon;return n&&this._lineGroup.remove(n),n=new Tg({shape:{points:t,stackedOnPoints:e},silent:!0}),this._lineGroup.add(n),this._polygon=n},_updateAnimation:function(t,e,n,i,r,a){var o=this._polyline,s=this._polygon,l=t.hostModel,h=function(t,e,n,i,r,a,o,s){for(var l=function(t,e){var n=[];return e.diff(t).add(function(t){n.push({cmd:"+",idx:t})}).update(function(t,e){n.push({cmd:"=",idx:e,idx1:t})}).remove(function(t){n.push({cmd:"-",idx:t})}).execute(),n}(t,e),h=[],u=[],c=[],d=[],f=[],p=[],g=[],m=pg(r,e,o),v=pg(a,t,s),y=0;y<l.length;y++){var _=l[y],x=!0;switch(_.cmd){case"=":var w=t.getItemLayout(_.idx),b=e.getItemLayout(_.idx1);(isNaN(w[0])||isNaN(w[1]))&&(w=b.slice()),h.push(w),u.push(b),c.push(n[_.idx]),d.push(i[_.idx1]),g.push(e.getRawIndex(_.idx1));break;case"+":var S=_.idx;h.push(r.dataToPoint([e.get(m.dataDimsForPoint[0],S),e.get(m.dataDimsForPoint[1],S)])),u.push(e.getItemLayout(S).slice()),c.push(gg(m,r,e,S)),d.push(i[S]),g.push(e.getRawIndex(S));break;case"-":S=_.idx;var M=t.getRawIndex(S);M!==S?(h.push(t.getItemLayout(S)),u.push(a.dataToPoint([t.get(v.dataDimsForPoint[0],S),t.get(v.dataDimsForPoint[1],S)])),c.push(n[S]),d.push(gg(v,a,t,S)),g.push(M)):x=!1}x&&(f.push(_),p.push(p.length))}p.sort(function(t,e){return g[t]-g[e]});var I=[],C=[],T=[],A=[],D=[];for(y=0;y<p.length;y++){S=p[y];I[y]=h[S],C[y]=u[S],T[y]=c[S],A[y]=d[S],D[y]=f[S]}return{current:I,next:C,stackedOnCurrent:T,stackedOnNext:A,status:D}}(this._data,t,this._stackedOnPoints,e,this._coordSys,n,this._valueOrigin,a),u=h.current,c=h.stackedOnCurrent,d=h.next,f=h.stackedOnNext;r&&(u=Lg(h.current,n,r),c=Lg(h.stackedOnCurrent,n,r),d=Lg(h.next,n,r),f=Lg(h.stackedOnNext,n,r)),o.shape.__points=h.current,o.shape.points=u,Ns(o,{shape:{points:d}},l),s&&(s.setShape({points:u,stackedOnPoints:c}),Ns(s,{shape:{points:d,stackedOnPoints:f}},l));for(var p=[],g=h.status,m=0;m<g.length;m++){if("="===g[m].cmd){var v=t.getItemGraphicEl(g[m].idx1);v&&p.push({el:v,ptIdx:m})}}o.animators&&o.animators.length&&o.animators[0].during(function(){for(var t=0;t<p.length;t++){p[t].el.attr("position",o.shape.__points[p[t].ptIdx])}})},remove:function(t){var n=this.group,i=this._data;this._lineGroup.removeAll(),this._symbolDraw.remove(!0),i&&i.eachItemGraphicEl(function(t,e){t.__temp&&(n.remove(t),i.setItemGraphicEl(e,null))}),this._polyline=this._polygon=this._coordSys=this._points=this._stackedOnPoints=this._data=null}});function zg(t,o,s){return{seriesType:t,performRawSeries:!0,reset:function(l,t,e){var n=l.getData(),h=l.get("symbol"),u=l.get("symbolSize"),i=l.get("symbolKeepAspect"),c=z(h),d=z(u),f=c||d,r=!c&&h?h:o,a=d?null:u;if(n.setVisual({legendSymbol:s||r,symbol:r,symbolSize:a,symbolKeepAspect:i}),!t.isSeriesFiltered(l))return{dataEach:n.hasItemOption||f?function(t,e){if(f){var n=l.getRawValue(e),i=l.getDataParams(e);c&&t.setItemVisual(e,"symbol",h(n,i)),d&&t.setItemVisual(e,"symbolSize",u(n,i))}if(t.hasItemOption){var r=t.getItemModel(e),a=r.getShallow("symbol",!0),o=r.getShallow("symbolSize",!0),s=r.getShallow("symbolKeepAspect",!0);null!=a&&t.setItemVisual(e,"symbol",a),null!=o&&t.setItemVisual(e,"symbolSize",o),null!=s&&t.setItemVisual(e,"symbolKeepAspect",s)}}:null}}}}function Eg(t){return{seriesType:t,plan:Ou(),reset:function(t){var e=t.getData(),c=t.coordinateSystem,d=t.pipelineContext.large;if(c){var f=D(c.dimensions,function(t){return e.mapDimension(t)}).slice(0,2),p=f.length,n=e.getCalculationInfo("stackResultDimension");return bf(e,f[0])&&(f[0]=n),bf(e,f[1])&&(f[1]=n),p&&{progress:function(t,e){for(var n=t.end-t.start,i=d&&new Float32Array(n*p),r=t.start,a=0,o=[],s=[];r<t.end;r++){var l;if(1===p){var h=e.get(f[0],r);l=!isNaN(h)&&c.dataToPoint(h,null,s)}else{h=o[0]=e.get(f[0],r);var u=o[1]=e.get(f[1],r);l=!isNaN(h)&&!isNaN(u)&&c.dataToPoint(o,null,s)}d?(i[a++]=l?l[0]:NaN,i[a++]=l?l[1]:NaN):e.setItemLayout(r,l&&l.slice()||[NaN,NaN])}d&&e.setLayout("symbolPoints",i)}}}}}}function Ng(t,e){return Math.round(t.length/2)}var Rg={average:function(t){for(var e=0,n=0,i=0;i<t.length;i++)isNaN(t[i])||(e+=t[i],n++);return 0===n?NaN:e/n},sum:function(t){for(var e=0,n=0;n<t.length;n++)e+=t[n]||0;return e},max:function(t){for(var e=-1/0,n=0;n<t.length;n++)t[n]>e&&(e=t[n]);return isFinite(e)?e:NaN},min:function(t){for(var e=1/0,n=0;n<t.length;n++)t[n]<e&&(e=t[n]);return isFinite(e)?e:NaN},nearest:function(t){return t[0]}};function Bg(t){return this._axes[t]}function Fg(t){this._axes={},this._dimList=[],this.name=t||""}function Vg(t){Fg.call(this,t)}Fg.prototype={constructor:Fg,type:"cartesian",getAxis:function(t){return this._axes[t]},getAxes:function(){return D(this._dimList,Bg,this)},getAxesByScale:function(e){return e=e.toLowerCase(),C(this.getAxes(),function(t){return t.scale.type===e})},addAxis:function(t){var e=t.dim;this._axes[e]=t,this._dimList.push(e)},dataToCoord:function(t){return this._dataCoordConvert(t,"dataToCoord")},coordToData:function(t){return this._dataCoordConvert(t,"coordToData")},_dataCoordConvert:function(t,e){for(var n=this._dimList,i=t instanceof Array?[]:{},r=0;r<n.length;r++){var a=n[r],o=this._axes[a];i[a]=o[e](t[a])}return i}},Vg.prototype={constructor:Vg,type:"cartesian2d",dimensions:["x","y"],getBaseAxis:function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAxis("x")},containPoint:function(t){var e=this.getAxis("x"),n=this.getAxis("y");return e.contain(e.toLocalCoord(t[0]))&&n.contain(n.toLocalCoord(t[1]))},containData:function(t){return this.getAxis("x").containData(t[0])&&this.getAxis("y").containData(t[1])},dataToPoint:function(t,e,n){var i=this.getAxis("x"),r=this.getAxis("y");return(n=n||[])[0]=i.toGlobalCoord(i.dataToCoord(t[0])),n[1]=r.toGlobalCoord(r.dataToCoord(t[1])),n},clampData:function(t,e){var n=this.getAxis("x").scale,i=this.getAxis("y").scale,r=n.getExtent(),a=i.getExtent(),o=n.parse(t[0]),s=i.parse(t[1]);return(e=e||[])[0]=Math.min(Math.max(Math.min(r[0],r[1]),o),Math.max(r[0],r[1])),e[1]=Math.min(Math.max(Math.min(a[0],a[1]),s),Math.max(a[0],a[1])),e},pointToData:function(t,e){var n=this.getAxis("x"),i=this.getAxis("y");return(e=e||[])[0]=n.coordToData(n.toLocalCoord(t[0])),e[1]=i.coordToData(i.toLocalCoord(t[1])),e},getOtherAxis:function(t){return this.getAxis("x"===t.dim?"y":"x")}},w(Vg,Fg);function Hg(t,e,n,i,r){Xp.call(this,t,e,n),this.type=i||"value",this.position=r||"bottom"}Hg.prototype={constructor:Hg,index:0,getAxesOnZeroOf:null,model:null,isHorizontal:function(){var t=this.position;return"top"===t||"bottom"===t},getGlobalExtent:function(t){var e=this.getExtent();return e[0]=this.toGlobalCoord(e[0]),e[1]=this.toGlobalCoord(e[1]),t&&e[0]>e[1]&&e.reverse(),e},getOtherAxis:function(){this.grid.getOtherAxis()},pointToData:function(t,e){return this.coordToData(this.toLocalCoord(t["x"===this.dim?0:1]),e)},toLocalCoord:null,toGlobalCoord:null},w(Hg,Xp);var Wg={show:!0,zlevel:0,z:0,inverse:!1,name:"",nameLocation:"end",nameRotate:null,nameTruncate:{maxWidth:null,ellipsis:"...",placeholder:"."},nameTextStyle:{},nameGap:15,silent:!1,triggerEvent:!1,tooltip:{show:!1},axisPointer:{},axisLine:{show:!0,onZero:!0,onZeroAxisIndex:null,lineStyle:{color:"#333",width:1,type:"solid"},symbol:["none","none"],symbolSize:[10,15]},axisTick:{show:!0,inside:!1,length:5,lineStyle:{width:1}},axisLabel:{show:!0,inside:!1,rotate:0,showMinLabel:null,showMaxLabel:null,margin:8,fontSize:12},splitLine:{show:!0,lineStyle:{color:["#ccc"],width:1,type:"solid"}},splitArea:{show:!1,areaStyle:{color:["rgba(250,250,250,0.3)","rgba(200,200,200,0.3)"]}}},Gg={};Gg.categoryAxis=m({boundaryGap:!0,deduplication:null,splitLine:{show:!1},axisTick:{alignWithLabel:!1,interval:"auto"},axisLabel:{interval:"auto"}},Wg),Gg.valueAxis=m({boundaryGap:[0,0],splitNumber:5},Wg),Gg.timeAxis=T({scale:!0,min:"dataMin",max:"dataMax"},Gg.valueAxis),Gg.logAxis=T({scale:!0,logBase:10},Gg.valueAxis);function Zg(a,t,o,e){A(Ug,function(r){t.extend({type:a+"Axis."+r,mergeDefaultAndTheme:function(t,e){var n=this.layoutMode,i=n?Wl(t):{};m(t,e.getTheme().get(r+"Axis")),m(t,this.getDefaultOption()),t.type=o(a,t),n&&Hl(t,i,n)},optionUpdated:function(){"category"===this.option.type&&(this.__ordinalMeta=Cf.createByAxisModel(this))},getCategories:function(t){var e=this.option;if("category"===e.type)return t?e.data:this.__ordinalMeta.categories},getOrdinalMeta:function(){return this.__ordinalMeta},defaultOption:p([{},Gg[r+"Axis"],e],!0)})}),jl.registerSubTypeDefaulter(a+"Axis",P(o,a))}var Ug=["value","category","time","log"],Xg=jl.extend({type:"cartesian2dAxis",axis:null,init:function(){Xg.superApply(this,"init",arguments),this.resetRange()},mergeOption:function(){Xg.superApply(this,"mergeOption",arguments),this.resetRange()},restoreData:function(){Xg.superApply(this,"restoreData",arguments),this.resetRange()},getCoordSysModel:function(){return this.ecModel.queryComponents({mainType:"grid",index:this.option.gridIndex,id:this.option.gridId})[0]}});function Yg(t,e){return e.type||(e.data?"category":"value")}m(Xg.prototype,_p);var jg={offset:0};function qg(t,e){return t.getCoordSysModel()===e}function $g(t,e,n){this._coordsMap={},this._coordsList=[],this._axesMap={},this._axesList=[],this._initCartesian(t,e,n),this.model=t}Zg("x",Xg,Yg,jg),Zg("y",Xg,Yg,jg),jl.extend({type:"grid",dependencies:["xAxis","yAxis"],layoutMode:"box",coordinateSystem:null,defaultOption:{show:!1,zlevel:0,z:0,left:"10%",top:60,right:"10%",bottom:60,containLabel:!1,backgroundColor:"rgba(0,0,0,0)",borderWidth:1,borderColor:"#ccc"}});var Kg=$g.prototype;function Qg(t,e,n,i){n.getAxesOnZeroOf=function(){return r?[r]:[]};var r,a=t[e],o=n.model,s=o.get("axisLine.onZero"),l=o.get("axisLine.onZeroAxisIndex");if(s){if(null!=l)Jg(a[l])&&(r=a[l]);else for(var h in a)if(a.hasOwnProperty(h)&&Jg(a[h])&&!i[u(a[h])]){r=a[h];break}r&&(i[u(r)]=!0)}function u(t){return t.dim+"_"+t.index}}function Jg(t){return t&&"category"!==t.type&&"time"!==t.type&&function(t){var e=t.scale.getExtent(),n=e[0],i=e[1];return!(0<n&&0<i||n<0&&i<0)}(t)}Kg.type="grid",Kg.axisPointerEnabled=!0,Kg.getRect=function(){return this._rect},Kg.update=function(t,e){var n=this._axesMap;this._updateScale(t,this.model),A(n.x,function(t){fp(t.scale,t.model)}),A(n.y,function(t){fp(t.scale,t.model)});var i={};A(n.x,function(t){Qg(n,"y",t,i)}),A(n.y,function(t){Qg(n,"x",t,i)}),this.resize(this.model,e)},Kg.resize=function(t,e,n){var r=Fl(t.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()});this._rect=r;var i=this._axesList;function a(){A(i,function(t){var e=t.isHorizontal(),n=e?[0,r.width]:[0,r.height],i=t.inverse?1:0;t.setExtent(n[i],n[1-i]),function(t,e){var n=t.getExtent(),i=n[0]+n[1];t.toGlobalCoord="x"===t.dim?function(t){return t+e}:function(t){return i-t+e},t.toLocalCoord="x"===t.dim?function(t){return t-e}:function(t){return i-t+e}}(t,e?r.x:r.y)})}a(),!n&&t.get("containLabel")&&(A(i,function(t){if(!t.model.get("axisLabel.inside")){var e=function(t){var e=t.model,n=t.scale;if(e.get("axisLabel.show")&&!n.isBlank()){var i,r,a="category"===t.type,o=n.getExtent();r=a?n.count():(i=n.getTicks()).length;var s,l,h,u,c,d,f,p,g,m=t.getLabelModel(),v=gp(t),y=1;40<r&&(y=Math.ceil(r/40));for(var _=0;_<r;_+=y){var x=v(i?i[_]:o[0]+_),w=m.getTextRect(x),b=(l=w,h=m.get("rotate")||0,void 0,u=h*Math.PI/180,c=l.plain(),d=c.width,f=c.height,p=d*Math.cos(u)+f*Math.sin(u),g=d*Math.sin(u)+f*Math.cos(u),new vn(c.x,c.y,p,g));s?s.union(b):s=b}return s}}(t);if(e){var n=t.isHorizontal()?"height":"width",i=t.model.get("axisLabel.margin");r[n]-=e[n]+i,"top"===t.position?r.y+=e.height+i:"left"===t.position&&(r.x+=e.width+i)}}}),a())},Kg.getAxis=function(t,e){var n=this._axesMap[t];if(null!=n){if(null==e)for(var i in n)if(n.hasOwnProperty(i))return n[i];return n[e]}},Kg.getAxes=function(){return this._axesList.slice()},Kg.getCartesian=function(t,e){if(null!=t&&null!=e){var n="x"+t+"y"+e;return this._coordsMap[n]}N(t)&&(e=t.yAxisIndex,t=t.xAxisIndex);for(var i=0,r=this._coordsList;i<r.length;i++)if(r[i].getAxis("x").index===t||r[i].getAxis("y").index===e)return r[i]},Kg.getCartesians=function(){return this._coordsList.slice()},Kg.convertToPixel=function(t,e,n){var i=this._findConvertTarget(t,e);return i.cartesian?i.cartesian.dataToPoint(n):i.axis?i.axis.toGlobalCoord(i.axis.dataToCoord(n)):null},Kg.convertFromPixel=function(t,e,n){var i=this._findConvertTarget(t,e);return i.cartesian?i.cartesian.pointToData(n):i.axis?i.axis.coordToData(i.axis.toLocalCoord(n)):null},Kg._findConvertTarget=function(t,e){var n,i,r=e.seriesModel,a=e.xAxisModel||r&&r.getReferringComponents("xAxis")[0],o=e.yAxisModel||r&&r.getReferringComponents("yAxis")[0],s=e.gridModel,l=this._coordsList;if(r)x(l,n=r.coordinateSystem)<0&&(n=null);else if(a&&o)n=this.getCartesian(a.componentIndex,o.componentIndex);else if(a)i=this.getAxis("x",a.componentIndex);else if(o)i=this.getAxis("y",o.componentIndex);else if(s){s.coordinateSystem===this&&(n=this._coordsList[0])}return{cartesian:n,axis:i}},Kg.containPoint=function(t){var e=this._coordsList[0];if(e)return e.containPoint(t)},Kg._initCartesian=function(o,t,e){var s={left:!1,right:!1,top:!1,bottom:!1},l={x:{},y:{}},h={x:0,y:0};if(t.eachComponent("xAxis",n("x"),this),t.eachComponent("yAxis",n("y"),this),!h.x||!h.y)return this._axesMap={},void(this._axesList=[]);function n(a){return function(t,e){if(qg(t,o)){var n=t.get("position");"x"===a?"top"!==n&&"bottom"!==n&&(n=s.bottom?"top":"bottom"):"left"!==n&&"right"!==n&&(n=s.left?"right":"left"),s[n]=!0;var i=new Hg(a,pp(t),[0,0],t.get("type"),n),r="category"===i.type;i.onBand=r&&t.get("boundaryGap"),i.inverse=t.get("inverse"),(t.axis=i).model=t,i.grid=this,i.index=e,this._axesList.push(i),l[a][e]=i,h[a]++}}}A((this._axesMap=l).x,function(r,a){A(l.y,function(t,e){var n="x"+a+"y"+e,i=new Vg(n);i.grid=this,i.model=o,this._coordsMap[n]=i,this._coordsList.push(i),i.addAxis(r),i.addAxis(t)},this)},this)},Kg._updateScale=function(l,h){function u(e,n){A(e.mapDimension(n.dim,!0),function(t){n.scale.unionExtentFromData(e,Sf(e,t))})}A(this._axesList,function(t){t.scale.setExtent(1/0,-1/0)}),l.eachSeries(function(t){if(nm(t)){var e=em(t,l),n=e[0],i=e[1];if(!qg(n,h)||!qg(i,h))return;var r=this.getCartesian(n.componentIndex,i.componentIndex),a=t.getData(),o=r.getAxis("x"),s=r.getAxis("y");"list"===a.type&&(u(a,o,t),u(a,s,t))}},this)},Kg.getTooltipAxes=function(i){var r=[],a=[];return A(this.getCartesians(),function(t){var e=null!=i&&"auto"!==i?t.getAxis(i):t.getBaseAxis(),n=t.getOtherAxis(e);x(r,e)<0&&r.push(e),x(a,n)<0&&a.push(n)}),{baseAxes:r,otherAxes:a}};var tm=["xAxis","yAxis"];function em(e){return D(tm,function(t){return e.getReferringComponents(t)[0]})}function nm(t){return"cartesian2d"===t.get("coordinateSystem")}$g.create=function(i,r){var a=[];return i.eachComponent("grid",function(t,e){var n=new $g(t,i,r);n.name="grid_"+e,n.resize(t,r,!0),t.coordinateSystem=n,a.push(n)}),i.eachSeries(function(t){if(nm(t)){var e=em(t),n=e[0],i=e[1],r=n.getCoordSysModel().coordinateSystem;t.coordinateSystem=r.getCartesian(n.componentIndex,i.componentIndex)}}),a},$g.dimensions=$g.prototype.dimensions=Vg.prototype.dimensions,Mh.register("cartesian2d",$g);function im(t,e){this.opt=e,this.axisModel=t,T(e,{labelOffset:0,nameDirection:1,tickDirection:1,labelDirection:1,silent:!0}),this.group=new yn;var n=new yn({position:e.position.slice(),rotation:e.rotation});n.updateTransform(),this._transform=n.transform,this._dumbGroup=n}var rm=Math.PI;im.prototype={constructor:im,hasBuilder:function(t){return!!am[t]},add:function(t){am[t].call(this)},getGroup:function(){return this.group}};var am={axisLine:function(){var a=this.opt,t=this.axisModel;if(t.get("axisLine.show")){var e=this.axisModel.axis.getExtent(),n=this._transform,o=[e[0],0],i=[e[1],0];n&&(yt(o,o,n),yt(i,i,n));var s=I({lineCap:"round"},t.getModel("axisLine.lineStyle").getLineStyle());this.group.add(new Bo({anid:"line",subPixelOptimize:!0,shape:{x1:o[0],y1:o[1],x2:i[0],y2:i[1]},style:s,strokeContainThreshold:a.strokeContainThreshold||5,silent:!0,z2:1}));var l=t.get("axisLine.symbol"),r=t.get("axisLine.symbolSize"),h=t.get("axisLine.symbolOffset")||0;if("number"==typeof h&&(h=[h,h]),null!=l){"string"==typeof l&&(l=[l,l]),"string"!=typeof r&&"number"!=typeof r||(r=[r,r]);var u=r[0],c=r[1];A([{rotate:a.rotation+Math.PI/2,offset:h[0],r:0},{rotate:a.rotation-Math.PI/2,offset:h[1],r:Math.sqrt((o[0]-i[0])*(o[0]-i[0])+(o[1]-i[1])*(o[1]-i[1]))}],function(t,e){if("none"!==l[e]&&null!=l[e]){var n=Ap(l[e],-u/2,-c/2,u,c,s.stroke,!0),i=t.r+t.offset,r=[o[0]+i*Math.cos(a.rotation),o[1]-i*Math.sin(a.rotation)];n.attr({rotation:t.rotate,position:r,silent:!0,z2:11}),this.group.add(n)}},this)}}},axisTickLabel:function(){var t=this.axisModel,e=this.opt,n=function(t,e,n){var i=e.axis;if(!e.get("axisTick.show")||i.scale.isBlank())return;for(var r=e.getModel("axisTick"),a=r.getModel("lineStyle"),o=r.get("length"),s=i.getTicksCoords(),l=[],h=[],u=t._transform,c=[],d=0;d<s.length;d++){var f=s[d].coord;l[0]=f,l[1]=0,h[0]=f,h[1]=n.tickDirection*o,u&&(yt(l,l,u),yt(h,h,u));var p=new Bo({anid:"tick_"+s[d].tickValue,subPixelOptimize:!0,shape:{x1:l[0],y1:l[1],x2:h[0],y2:h[1]},style:T(a.getLineStyle(),{stroke:e.get("axisLine.lineStyle.color")}),z2:2,silent:!0});t.group.add(p),c.push(p)}return c}(this,t,e);!function(t,e,n){if(yp(t.axis))return;var i=t.get("axisLabel.showMinLabel"),r=t.get("axisLabel.showMaxLabel");n=n||[];var a=(e=e||[])[0],o=e[1],s=e[e.length-1],l=e[e.length-2],h=n[0],u=n[1],c=n[n.length-1],d=n[n.length-2];!1===i?(hm(a),hm(h)):um(a,o)&&(i?(hm(o),hm(u)):(hm(a),hm(h)));!1===r?(hm(s),hm(c)):um(l,s)&&(r?(hm(l),hm(d)):(hm(s),hm(c)))}(t,function(h,u,c){var d=u.axis;if(!H(c.axisLabelShow,u.get("axisLabel.show"))||d.scale.isBlank())return;var f=u.getModel("axisLabel"),p=f.get("margin"),t=d.getViewLabels(),e=(H(c.labelRotate,f.get("rotate"))||0)*rm/180,g=sm(c.rotation,e,c.labelDirection),m=u.getCategories&&u.getCategories(!0),v=[],y=lm(u),_=u.get("triggerEvent");return A(t,function(t,e){var n=t.tickValue,i=t.formattedLabel,r=t.rawLabel,a=f;m&&m[n]&&m[n].textStyle&&(a=new Ks(m[n].textStyle,f,u.ecModel));var o=a.getTextColor()||u.get("axisLine.lineStyle.color"),s=[d.dataToCoord(n),c.labelOffset+c.labelDirection*p],l=new wo({anid:"label_"+n,position:s,rotation:g.rotation,silent:y,z2:10});As(l.style,a,{text:i,textAlign:a.getShallow("align",!0)||g.textAlign,textVerticalAlign:a.getShallow("verticalAlign",!0)||a.getShallow("baseline",!0)||g.textVerticalAlign,textFill:"function"==typeof o?o("category"===d.type?r:"value"===d.type?n+"":n,e):o}),_&&(l.eventData=om(u),l.eventData.targetType="axisLabel",l.eventData.value=r),h._dumbGroup.add(l),l.updateTransform(),v.push(l),h.group.add(l),l.decomposeTransform()}),v}(this,t,e),n)},axisName:function(){var t=this.opt,e=this.axisModel,n=H(t.axisName,e.get("name"));if(n){var i,r,a=e.get("nameLocation"),o=t.nameDirection,s=e.getModel("nameTextStyle"),l=e.get("nameGap")||0,h=this.axisModel.axis.getExtent(),u=h[0]>h[1]?-1:1,c=["start"===a?h[0]-u*l:"end"===a?h[1]+u*l:(h[0]+h[1])/2,cm(a)?t.labelOffset+o*l:0],d=e.get("nameRotate");null!=d&&(d=d*rm/180),cm(a)?i=sm(t.rotation,null!=d?d:t.rotation,o):(i=function(t,e,n,i){var r,a,o=cl(n-t.rotation),s=i[0]>i[1],l="start"===e&&!s||"start"!==e&&s;r=dl(o-rm/2)?(a=l?"bottom":"top","center"):dl(o-1.5*rm)?(a=l?"top":"bottom","center"):(a="middle",o<1.5*rm&&rm/2<o?l?"left":"right":l?"right":"left");return{rotation:o,textAlign:r,textVerticalAlign:a}}(t,a,d||0,h),null!=(r=t.axisNameAvailableWidth)&&(r=Math.abs(r/Math.sin(i.rotation)),isFinite(r)||(r=null)));var f=s.getFont(),p=e.get("nameTruncate",!0)||{},g=p.ellipsis,m=H(t.nameTruncateMaxWidth,p.maxWidth,r),v=null!=g&&null!=m?Ll(n,m,f,g,{minChar:2,placeholder:p.placeholder}):n,y=e.get("tooltip",!0),_=e.mainType,x={componentType:_,name:n,$vars:["name"]};x[_+"Index"]=e.componentIndex;var w=new wo({anid:"name",__fullText:n,__truncatedText:v,position:c,rotation:i.rotation,silent:lm(e),z2:1,tooltip:y&&y.show?I({content:n,formatter:function(){return n},formatterParams:x},y):null});As(w.style,s,{text:v,textFont:f,textFill:s.getTextColor()||e.get("axisLine.lineStyle.color"),textAlign:s.get("align")||i.textAlign,textVerticalAlign:s.get("verticalAlign")||i.textVerticalAlign}),e.get("triggerEvent")&&(w.eventData=om(e),w.eventData.targetType="axisName",w.eventData.name=n),this._dumbGroup.add(w),w.updateTransform(),this.group.add(w),w.decomposeTransform()}}},om=im.makeAxisEventDataBase=function(t){var e={componentType:t.mainType,componentIndex:t.componentIndex};return e[t.mainType+"Index"]=t.componentIndex,e},sm=im.innerTextLayout=function(t,e,n){var i,r=cl(e-t);return{rotation:r,textAlign:dl(r)?(i=0<n?"top":"bottom","center"):dl(r-rm)?(i=0<n?"bottom":"top","center"):(i="middle",0<r&&r<rm?0<n?"right":"left":0<n?"left":"right"),textVerticalAlign:i}};var lm=im.isLabelSilent=function(t){var e=t.get("tooltip");return t.get("silent")||!(t.get("triggerEvent")||e&&e.show)};function hm(t){t&&(t.ignore=!0)}function um(t,e){var n=t&&t.getBoundingRect().clone(),i=e&&e.getBoundingRect().clone();if(n&&i){var r=$t([]);return te(r,r,-t.rotation),n.applyTransform(Qt([],r,t.getLocalTransform())),i.applyTransform(Qt([],r,e.getLocalTransform())),n.intersect(i)}}function cm(t){return"middle"===t||"center"===t}var dm=A,fm=P;function pm(t,e){var n={axesInfo:{},seriesInvolved:!1,coordSysAxesInfo:{},coordSysMap:{}};return function(p,g,t){var a=g.getComponent("tooltip"),m=g.getComponent("axisPointer"),v=m.get("link",!0)||[],y=[];dm(t.getCoordinateSystems(),function(c){if(c.axisPointerEnabled){var t=ym(c.model),d=p.coordSysAxesInfo[t]={},f=(p.coordSysMap[t]=c).model.getModel("tooltip",a);if(dm(c.getAxes(),fm(r,!1,null)),c.getTooltipAxes&&a&&f.get("show")){var e="axis"===f.get("trigger"),n="cross"===f.get("axisPointer.type"),i=c.getTooltipAxes(f.get("axisPointer.axis"));(e||n)&&dm(i.baseAxes,fm(r,!n||"cross",e)),n&&dm(i.otherAxes,fm(r,"cross",!1))}}function r(t,e,n){var i=n.model.getModel("axisPointer",m),r=i.get("show");if(r&&("auto"!==r||t||vm(i))){null==e&&(e=i.get("triggerTooltip"));var a=(i=t?function(t,e,n,i,r,a){var o=e.getModel("axisPointer"),s={};dm(["type","snap","lineStyle","shadowStyle","label","animation","animationDurationUpdate","animationEasingUpdate","z"],function(t){s[t]=b(o.get(t))}),s.snap="category"!==t.type&&!!a,"cross"===o.get("type")&&(s.type="line");var l=s.label||(s.label={});if(null==l.show&&(l.show=!1),"cross"===r){var h=o.get("label.show");if(l.show=null==h||h,!a){var u=s.lineStyle=o.get("crossStyle");u&&T(l,u.textStyle)}}return t.model.getModel("axisPointer",new Ks(s,n,i))}(n,f,m,g,t,e):i).get("snap"),o=ym(n.model),s=e||a||"category"===n.type,l=p.axesInfo[o]={key:o,axis:n,coordSys:c,axisPointerModel:i,triggerTooltip:e,involveSeries:s,snap:a,useHandle:vm(i),seriesModels:[]};d[o]=l,p.seriesInvolved|=s;var h=function(t,e){for(var n=e.model,i=e.dim,r=0;r<t.length;r++){var a=t[r]||{};if(gm(a[i+"AxisId"],n.id)||gm(a[i+"AxisIndex"],n.componentIndex)||gm(a[i+"AxisName"],n.name))return r}}(v,n);if(null!=h){var u=y[h]||(y[h]={axesInfo:{}});u.axesInfo[o]=l,u.mapper=v[h].mapper,l.linkGroup=u}}}})}(n,t,e),n.seriesInvolved&&function(r,t){t.eachSeries(function(n){var i=n.coordinateSystem,t=n.get("tooltip.trigger",!0),e=n.get("tooltip.show",!0);i&&"none"!==t&&!1!==t&&"item"!==t&&!1!==e&&!1!==n.get("axisPointer.show",!0)&&dm(r.coordSysAxesInfo[ym(i.model)],function(t){var e=t.axis;i.getAxis(e.dim)===e&&(t.seriesModels.push(n),null==t.seriesDataCount&&(t.seriesDataCount=0),t.seriesDataCount+=n.getData().count())})},this)}(n,t),n}function gm(t,e){return"all"===t||O(t)&&0<=x(t,e)||t===e}function mm(t){var e=(t.ecModel.getComponent("axisPointer")||{}).coordSysAxesInfo;return e&&e.axesInfo[ym(t)]}function vm(t){return!!t.get("handle.show")}function ym(t){return t.type+"||"+t.id}var _m=Vd({type:"axis",_axisPointer:null,axisPointerClass:null,render:function(t,e,n,i){this.axisPointerClass&&function(t){var e=mm(t);if(e){var n=e.axisPointerModel,i=e.axis.scale,r=n.option,a=n.get("status"),o=n.get("value");null!=o&&(o=i.parse(o));var s=vm(n);null==a&&(r.status=s?"show":"hide");var l=i.getExtent().slice();l[0]>l[1]&&l.reverse(),(null==o||o>l[1])&&(o=l[1]),o<l[0]&&(o=l[0]),r.value=o,s&&(r.status=e.axis.scale.isBlank()?"hide":"show")}}(t),_m.superApply(this,"render",arguments),xm(this,t,e,n,i,!0)},updateAxisPointer:function(t,e,n,i,r){xm(this,t,e,n,i,!1)},remove:function(t,e){var n=this._axisPointer;n&&n.remove(e),_m.superApply(this,"remove",arguments)},dispose:function(t,e){wm(this,e),_m.superApply(this,"dispose",arguments)}});function xm(t,e,n,i,r,a){var o=_m.getAxisPointerClass(t.axisPointerClass);if(o){var s=function(t){var e=mm(t);return e&&e.axisPointerModel}(e);s?(t._axisPointer||(t._axisPointer=new o)).render(e,s,i,a):wm(t,i)}}function wm(t,e,n){var i=t._axisPointer;i&&i.dispose(e,n),t._axisPointer=null}var bm=[];function Sm(t,e,n){n=n||{};var i=t.coordinateSystem,r=e.axis,a={},o=r.getAxesOnZeroOf()[0],s=r.position,l=o?"onZero":s,h=r.dim,u=i.getRect(),c=[u.x,u.x+u.width,u.y,u.y+u.height],d={left:0,right:1,top:0,bottom:1,onZero:2},f=e.get("offset")||0,p="x"===h?[c[2]-f,c[3]+f]:[c[0]-f,c[1]+f];if(o){var g=o.toGlobalCoord(o.dataToCoord(0));p[d.onZero]=Math.max(Math.min(g,p[1]),p[0])}a.position=["y"===h?p[d[l]]:c[0],"x"===h?p[d[l]]:c[3]],a.rotation=Math.PI/2*("x"===h?0:1);a.labelDirection=a.tickDirection=a.nameDirection={top:-1,bottom:1,left:-1,right:1}[s],a.labelOffset=o?p[d[s]]-p[d.onZero]:0,e.get("axisTick.inside")&&(a.tickDirection=-a.tickDirection),H(n.labelInside,e.get("axisLabel.inside"))&&(a.labelDirection=-a.labelDirection);var m=e.get("axisLabel.rotate");return a.labelRotate="top"===l?-m:m,a.z2=1,a}_m.registerAxisPointerClass=function(t,e){bm[t]=e},_m.getAxisPointerClass=function(t){return t&&bm[t]};var Mm=["axisLine","axisTickLabel","axisName"],Im=["splitArea","splitLine"],Cm=_m.extend({type:"cartesianAxis",axisPointerClass:"CartesianAxisPointer",render:function(e,t,n,i){this.group.removeAll();var r=this._axisGroup;if(this._axisGroup=new yn,this.group.add(this._axisGroup),e.get("show")){var a=e.getCoordSysModel(),o=Sm(a,e),s=new im(e,o);A(Mm,s.add,s),this._axisGroup.add(s.getGroup()),A(Im,function(t){e.get(t+".show")&&this["_"+t](e,a)},this),Hs(r,this._axisGroup,e),Cm.superCall(this,"render",e,t,n,i)}},remove:function(){this._splitAreaColors=null},_splitLine:function(t,e){var n=t.axis;if(!n.scale.isBlank()){var i=t.getModel("splitLine"),r=i.getModel("lineStyle"),a=r.get("color");a=O(a)?a:[a];for(var o=e.coordinateSystem.getRect(),s=n.isHorizontal(),l=0,h=n.getTicksCoords({tickModel:i}),u=[],c=[],d=r.getLineStyle(),f=0;f<h.length;f++){var p=n.toGlobalCoord(h[f].coord);s?(u[0]=p,u[1]=o.y,c[0]=p,c[1]=o.y+o.height):(u[0]=o.x,u[1]=p,c[0]=o.x+o.width,c[1]=p);var g=l++%a.length,m=h[f].tickValue;this._axisGroup.add(new Bo({anid:null!=m?"line_"+h[f].tickValue:null,subPixelOptimize:!0,shape:{x1:u[0],y1:u[1],x2:c[0],y2:c[1]},style:T({stroke:a[g]},d),silent:!0}))}}},_splitArea:function(t,e){var n=t.axis;if(!n.scale.isBlank()){var i=t.getModel("splitArea"),r=i.getModel("areaStyle"),a=r.get("color"),o=e.coordinateSystem.getRect(),s=n.getTicksCoords({tickModel:i,clamp:!0});if(s.length){var l=a.length,h=this._splitAreaColors,u=Q(),c=0;if(h)for(var d=0;d<s.length;d++){var f=h.get(s[d].tickValue);if(null!=f){c=(f+(l-1)*d)%l;break}}var p=n.toGlobalCoord(s[0].coord),g=r.getAreaStyle();a=O(a)?a:[a];for(d=1;d<s.length;d++){var m,v,y,_,x=n.toGlobalCoord(s[d].coord);p=n.isHorizontal()?(m=p,v=o.y,y=x-m,_=o.height,m+y):(m=o.x,v=p,y=o.width,v+(_=x-v));var w=s[d-1].tickValue;null!=w&&u.set(w,c),this._axisGroup.add(new No({anid:null!=w?"area_"+w:null,shape:{x:m,y:v,width:y,height:_},style:T({fill:a[c]},g),silent:!0})),c=(c+1)%l}this._splitAreaColors=u}}}});function Tm(t,e){"outside"===t.textPosition&&(t.textPosition=e)}Cm.extend({type:"xAxis"}),Cm.extend({type:"yAxis"}),Vd({type:"grid",render:function(t,e){this.group.removeAll(),t.get("show")&&this.group.add(new No({shape:t.coordinateSystem.getRect(),style:T({fill:t.get("backgroundColor")},t.getItemStyle()),silent:!0,z2:-1}))}}),Ld(function(t){t.xAxis&&t.yAxis&&!t.grid&&(t.grid={})}),Nd(zg("line","circle","line")),Ed(Eg("line")),Od(Uc.PROCESSOR.STATISTIC,{seriesType:"line",modifyOutputEnd:!0,reset:function(t,e,n){var i=t.getData(),r=t.get("sampling"),a=t.coordinateSystem;if("cartesian2d"===a.type&&r){var o,s=a.getBaseAxis(),l=a.getOtherAxis(s),h=s.getExtent(),u=h[1]-h[0],c=Math.round(i.count()/u);1<c&&("string"==typeof r?o=Rg[r]:"function"==typeof r&&(o=r),o&&t.setData(i.downSample(i.mapDimension(l.dim),1/c,o,Ng)))}}}),Su.extend({type:"series.__base_bar__",getInitialData:function(t,e){return Mf(this.getSource(),this)},getMarkerPosition:function(t){var e=this.coordinateSystem;if(e){var n=e.dataToPoint(e.clampData(t)),i=this.getData(),r=i.getLayout("offset"),a=i.getLayout("size");return n[e.getBaseAxis().isHorizontal()?0:1]+=r+a/2,n}return[NaN,NaN]},defaultOption:{zlevel:0,z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,barMinHeight:0,barMinAngle:0,large:!1,largeThreshold:400,progressive:3e3,progressiveChunkMode:"mod",itemStyle:{},emphasis:{}}}).extend({type:"series.bar",dependencies:["grid","polar"],brushSelector:"rect",getProgressive:function(){return!!this.get("large")&&this.get("progressive")},getProgressiveThreshold:function(){var t=this.get("progressiveThreshold"),e=this.get("largeThreshold");return t<e&&(t=e),t}});var Am=Fr([["fill","color"],["stroke","borderColor"],["lineWidth","borderWidth"],["stroke","barBorderColor"],["lineWidth","barBorderWidth"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"]]),Dm=["itemStyle","barBorderWidth"],km=[0,0];I(Ks.prototype,{getBarItemStyle:function(t){var e=Am(this,t);if(this.getBorderLineDash){var n=this.getBorderLineDash();n&&(e.lineDash=n)}return e}}),Wd({type:"bar",render:function(t,e,n){this._updateDrawMode(t);var i=t.get("coordinateSystem");return"cartesian2d"!==i&&"polar"!==i||(this._isLargeDraw?this._renderLarge(t,e,n):this._renderNormal(t,e,n)),this.group},incrementalPrepareRender:function(t,e,n){this._clear(),this._updateDrawMode(t)},incrementalRender:function(t,e,n,i){this._incrementalRenderLarge(t,e)},_updateDrawMode:function(t){var e=t.pipelineContext.large;(null==this._isLargeDraw||e^this._isLargeDraw)&&(this._isLargeDraw=e,this._clear())},_renderNormal:function(a,t,e){var o,s=this.group,l=a.getData(),h=this._data,u=a.coordinateSystem,n=u.getBaseAxis();"cartesian2d"===u.type?o=n.isHorizontal():"polar"===u.type&&(o="angle"===n.dim);var c=a.isAnimationEnabled()?a:null;l.diff(h).add(function(t){if(l.hasValue(t)){var e=l.getItemModel(t),n=zm[u.type](l,t,e),i=Pm[u.type](l,t,e,n,o,c);l.setItemGraphicEl(t,i),s.add(i),Em(i,l,t,e,n,a,o,"polar"===u.type)}}).update(function(t,e){var n=h.getItemGraphicEl(e);if(l.hasValue(t)){var i=l.getItemModel(t),r=zm[u.type](l,t,i);n?Ns(n,{shape:r},c,t):n=Pm[u.type](l,t,i,r,o,c,!0),l.setItemGraphicEl(t,n),s.add(n),Em(n,l,t,i,r,a,o,"polar"===u.type)}else s.remove(n)}).remove(function(t){var e=h.getItemGraphicEl(t);"cartesian2d"===u.type?e&&Lm(t,c,e):e&&Om(t,c,e)}).execute(),this._data=l},_renderLarge:function(t,e,n){this._clear(),Rm(t,this.group)},_incrementalRenderLarge:function(t,e){Rm(e,this.group,!0)},dispose:J,remove:function(t){this._clear(t)},_clear:function(e){var t=this.group,n=this._data;e&&e.get("animation")&&n&&!this._isLargeDraw?n.eachItemGraphicEl(function(t){"sector"===t.type?Om(t.dataIndex,e,t):Lm(t.dataIndex,e,t)}):t.removeAll(),this._data=null}});var Pm={cartesian2d:function(t,e,n,i,r,a,o){var s=new No({shape:I({},i)});if(a){var l=r?"height":"width",h={};s.shape[l]=0,h[l]=i[l],Zs[o?"updateProps":"initProps"](s,{shape:h},a,e)}return s},polar:function(t,e,n,i,r,a,o){var s=i.startAngle<i.endAngle,l=new Io({shape:T({clockwise:s},i)});if(a){var h=r?"r":"endAngle",u={};l.shape[h]=r?0:i.startAngle,u[h]=i[h],Zs[o?"updateProps":"initProps"](l,{shape:u},a,e)}return l}};function Lm(t,e,n){n.style.text=null,Ns(n,{shape:{width:0}},e,t,function(){n.parent&&n.parent.remove(n)})}function Om(t,e,n){n.style.text=null,Ns(n,{shape:{r:n.shape.r0}},e,t,function(){n.parent&&n.parent.remove(n)})}var zm={cartesian2d:function(t,e,n){var i=t.getItemLayout(e),r=function(t,e){var n=t.get(Dm)||0;return Math.min(n,Math.abs(e.width),Math.abs(e.height))}(n,i),a=0<i.width?1:-1,o=0<i.height?1:-1;return{x:i.x+a*r/2,y:i.y+o*r/2,width:i.width-a*r,height:i.height-o*r}},polar:function(t,e,n){var i=t.getItemLayout(e);return{cx:i.cx,cy:i.cy,r0:i.r0,r:i.r,startAngle:i.startAngle,endAngle:i.endAngle}}};function Em(t,e,n,i,r,a,o,s){var l=e.getItemVisual(n,"color"),h=e.getItemVisual(n,"opacity"),u=i.getModel("itemStyle"),c=i.getModel("emphasis.itemStyle").getBarItemStyle();s||t.setShape("r",u.get("barBorderRadius")||0),t.useStyle(T({fill:l,opacity:h},u.getBarItemStyle()));var d=i.getShallow("cursor");d&&t.attr("cursor",d);o?r.height:r.width;s||function(t,e,n,i,r,a){Ts(t,e,n.getModel("label"),n.getModel("emphasis.label"),{labelFetcher:r,labelDataIndex:a,defaultText:Qp(r.getData(),a),isRectText:!0,autoColor:i}),Tm(t),Tm(e)}(t.style,c,i,l,a,n),Ss(t,c)}var Nm=no.extend({type:"largeBar",shape:{points:[]},buildPath:function(t,e){for(var n=e.points,i=this.__startPoint,r=this.__baseDimIdx,a=0;a<n.length;a+=2)i[r]=n[a+r],t.moveTo(i[0],i[1]),t.lineTo(n[a],n[a+1])}});function Rm(t,e,n){var i=t.getData(),r=[],a=i.getLayout("valueAxisHorizontal")?1:0;r[1-a]=i.getLayout("valueAxisStart");var o=new Nm({shape:{points:i.getLayout("largePoints")},incremental:!!n,__startPoint:r,__baseDimIdx:a,__largeDataIndices:i.getLayout("largeDataIndices"),__barWidth:i.getLayout("barWidth")});e.add(o),function(t,e,n){var i=n.getVisual("borderColor")||n.getVisual("color"),r=e.getModel("itemStyle").getItemStyle(["color","borderColor"]);t.useStyle(r),t.style.fill=null,t.style.stroke=i,t.style.lineWidth=n.getLayout("barWidth")}(o,t,i),o.seriesIndex=t.seriesIndex,t.get("silent")||(o.on("mousedown",Bm),o.on("mousemove",Bm))}var Bm=Xu(function(t){var e=function(t,e,n){var i=t.__baseDimIdx,r=1-i,a=t.shape.points,o=t.__largeDataIndices,s=Math.abs(t.__barWidth/2),l=t.__startPoint[r];km[0]=e,km[1]=n;for(var h=km[i],u=km[1-i],c=h-s,d=h+s,f=0,p=a.length/2;f<p;f++){var g=2*f,m=a[g+i],v=a[g+r];if(c<=m&&m<=d&&(l<=v?l<=u&&u<=v:v<=u&&u<=l))return o[f]}return-1}(this,t.offsetX,t.offsetY);this.dataIndex=0<=e?e:null},30,!1);Ed(Uc.VISUAL.LAYOUT,P(function(t,e){var n=Wf(t,e),C=Gf(n),T={};A(n,function(t){var e=t.getData(),n=t.coordinateSystem,i=n.getBaseAxis(),r=Vf(t),a=C[Hf(i)][r],o=a.offset,s=a.width,l=n.getOtherAxis(i),h=t.get("barMinHeight")||0;T[r]=T[r]||[],e.setLayout({offset:o,size:s});for(var u=e.mapDimension(l.dim),c=e.mapDimension(i.dim),d=bf(e,u),f=l.isHorizontal(),p=jf(i,l,d),g=0,m=e.count();g<m;g++){var v=e.get(u,g),y=e.get(c,g);if(!isNaN(v)&&!isNaN(y)){var _,x,w,b,S,M=0<=v?"p":"n",I=p;if(d&&(T[r][y]||(T[r][y]={p:p,n:p}),I=T[r][y][M]),f)_=I,x=(S=n.dataToPoint([v,y]))[1]+o,w=S[0]-p,b=s,Math.abs(w)<h&&(w=(w<0?-1:1)*h),d&&(T[r][y][M]+=w);else _=(S=n.dataToPoint([y,v]))[0]+o,x=I,w=s,b=S[1]-p,Math.abs(b)<h&&(b=(b<=0?-1:1)*h),d&&(T[r][y][M]+=b);e.setItemLayout(g,{x:_,y:x,width:w,height:b})}}},this)},"bar")),Ed(Uc.VISUAL.PROGRESSIVE_LAYOUT,Uf),Nd({seriesType:"bar",reset:function(t){t.getData().setVisual("legendSymbol","roundRect")}});var Fm={updateSelectedMap:function(t){this._targetList=O(t)?t.slice():[],this._selectTargetMap=M(t||[],function(t,e){return t.set(e.name,e),t},Q())},select:function(t,e){var n=null!=e?this._targetList[e]:this._selectTargetMap.get(t);"single"===this.get("selectedMode")&&this._selectTargetMap.each(function(t){t.selected=!1}),n&&(n.selected=!0)},unSelect:function(t,e){var n=null!=e?this._targetList[e]:this._selectTargetMap.get(t);n&&(n.selected=!1)},toggleSelected:function(t,e){var n=null!=e?this._targetList[e]:this._selectTargetMap.get(t);if(null!=n)return this[n.selected?"unSelect":"select"](t,e),n.selected},isSelected:function(t,e){var n=null!=e?this._targetList[e]:this._selectTargetMap.get(t);return n&&n.selected}},Vm=Hd({type:"series.pie",init:function(t){Vm.superApply(this,"init",arguments),this.legendDataProvider=function(){return this.getRawData()},this.updateSelectedMap(this._createSelectableList()),this._defaultLabelLine(t)},mergeOption:function(t){Vm.superCall(this,"mergeOption",t),this.updateSelectedMap(this._createSelectableList())},getInitialData:function(t,e){return function(t,e,n){e=O(e)&&{coordDimensions:e}||I({},e);var i=t.getSource(),r=xf(i,e),a=new af(r,t);return a.initData(i,n),a}(this,["value"])},_createSelectableList:function(){for(var t=this.getRawData(),e=t.mapDimension("value"),n=[],i=0,r=t.count();i<r;i++)n.push({name:t.getName(i),value:t.get(e,i),selected:ou(t,i,"selected")});return n},getDataParams:function(t){var e=this.getData(),n=Vm.superCall(this,"getDataParams",t),i=[];return e.each(e.mapDimension("value"),function(t){i.push(t)}),n.percent=ul(i,t,e.hostModel.get("percentPrecision")),n.$vars.push("percent"),n},_defaultLabelLine:function(t){mr(t,"labelLine",["show"]);var e=t.labelLine,n=t.emphasis.labelLine;e.show=e.show&&t.label.show,n.show=n.show&&t.emphasis.label.show},defaultOption:{zlevel:0,z:2,legendHoverLink:!0,hoverAnimation:!0,center:["50%","50%"],radius:[0,"75%"],clockwise:!0,startAngle:90,minAngle:0,minShowLabelAngle:0,selectedOffset:10,hoverOffset:10,avoidLabelOverlap:!0,percentPrecision:2,stillShowZeroSum:!0,label:{rotate:!1,show:!0,position:"outer"},labelLine:{show:!0,length:15,length2:15,smooth:!1,lineStyle:{width:1,type:"solid"}},itemStyle:{borderWidth:1},animationType:"expansion",animationEasing:"cubicOut"}});function Hm(t,e,n,i){var r=e.getData(),a=this.dataIndex,o=r.getName(a),s=e.get("selectedOffset");i.dispatchAction({type:"pieToggleSelect",from:t,name:o,seriesId:e.id}),r.each(function(t){Wm(r.getItemGraphicEl(t),r.getItemLayout(t),e.isSelected(r.getName(t)),s,n)})}function Wm(t,e,n,i,r){var a=(e.startAngle+e.endAngle)/2,o=n?i:0,s=[Math.cos(a)*o,Math.sin(a)*o];r?t.animate().when(200,{position:s}).start("bounceOut"):t.attr("position",s)}function Gm(t,e){yn.call(this);var n=new Io({z2:2}),i=new ko,r=new wo;this.add(n),this.add(i),this.add(r),this.updateData(t,e,!0)}S(Vm,Fm);var Zm=Gm.prototype;Zm.updateData=function(t,e,n){var i=this.childAt(0),r=this.childAt(1),a=this.childAt(2),o=t.hostModel,s=t.getItemModel(e),l=t.getItemLayout(e),h=I({},l);(h.label=null,n)?(i.setShape(h),"scale"===o.getShallow("animationType")?(i.shape.r=l.r0,Rs(i,{shape:{r:l.r}},o,e)):(i.shape.endAngle=l.startAngle,Ns(i,{shape:{endAngle:l.endAngle}},o,e))):Ns(i,{shape:h},o,e);var u=t.getItemVisual(e,"color");i.useStyle(T({lineJoin:"bevel",fill:u},s.getModel("itemStyle").getItemStyle())),i.hoverStyle=s.getModel("emphasis.itemStyle").getItemStyle();var c=s.getShallow("cursor");c&&i.attr("cursor",c),Wm(this,t.getItemLayout(e),o.isSelected(null,e),o.get("selectedOffset"),o.get("animation")),this._updateLabel(t,e),this.highDownOnUpdate=s.get("hoverAnimation")&&o.isAnimationEnabled()?function(t,e){"emphasis"===e?(r.ignore=r.hoverIgnore,a.ignore=a.hoverIgnore,i.stopAnimation(!0),i.animateTo({shape:{r:l.r+o.get("hoverOffset")}},300,"elasticOut")):(r.ignore=r.normalIgnore,a.ignore=a.normalIgnore,i.stopAnimation(!0),i.animateTo({shape:{r:l.r}},300,"elasticOut"))}:null,Ss(this)},Zm._updateLabel=function(t,e){var n=this.childAt(1),i=this.childAt(2),r=t.hostModel,a=t.getItemModel(e),o=t.getItemLayout(e).label,s=t.getItemVisual(e,"color");if(!o||isNaN(o.x)||isNaN(o.y))i.ignore=i.normalIgnore=i.hoverIgnore=n.ignore=n.normalIgnore=n.hoverIgnore=!0;else{Ns(n,{shape:{points:o.linePoints||[[o.x,o.y],[o.x,o.y],[o.x,o.y]]}},r,e),Ns(i,{style:{x:o.x,y:o.y}},r,e),i.attr({rotation:o.rotation,origin:[o.x,o.y],z2:10});var l=a.getModel("label"),h=a.getModel("emphasis.label"),u=a.getModel("labelLine"),c=a.getModel("emphasis.labelLine");s=t.getItemVisual(e,"color");Ts(i.style,i.hoverStyle={},l,h,{labelFetcher:t.hostModel,labelDataIndex:e,defaultText:t.getName(e),autoColor:s,useInsideStyle:!!o.inside},{textAlign:o.textAlign,textVerticalAlign:o.verticalAlign,opacity:t.getItemVisual(e,"opacity")}),i.ignore=i.normalIgnore=!l.get("show"),i.hoverIgnore=!h.get("show"),n.ignore=n.normalIgnore=!u.get("show"),n.hoverIgnore=!c.get("show"),n.setStyle({stroke:s,opacity:t.getItemVisual(e,"opacity")}),n.setStyle(u.getModel("lineStyle").getLineStyle()),n.hoverStyle=c.getModel("lineStyle").getLineStyle();var d=u.get("smooth");d&&!0===d&&(d=.4),n.setShape({smooth:d})}},w(Gm,yn);Nu.extend({type:"pie",init:function(){var t=new yn;this._sectorGroup=t},render:function(t,e,n,i){if(!i||i.from!==this.uid){var r=t.getData(),a=this._data,o=this.group,s=e.get("animation"),l=!a,h=t.get("animationType"),u=P(Hm,this.uid,t,s,n),c=t.get("selectedMode");if(r.diff(a).add(function(t){var e=new Gm(r,t);l&&"scale"!==h&&e.eachChild(function(t){t.stopAnimation(!0)}),c&&e.on("click",u),r.setItemGraphicEl(t,e),o.add(e)}).update(function(t,e){var n=a.getItemGraphicEl(e);n.updateData(r,t),n.off("click"),c&&n.on("click",u),o.add(n),r.setItemGraphicEl(t,n)}).remove(function(t){var e=a.getItemGraphicEl(t);o.remove(e)}).execute(),s&&l&&0<r.count()&&"scale"!==h){for(var d=r.getItemLayout(0),f=1;isNaN(d.startAngle)&&f<r.count();++f)d=r.getItemLayout(f);var p=Math.max(n.getWidth(),n.getHeight())/2,g=k(o.removeClipPath,o);o.setClipPath(this._createClipPath(d.cx,d.cy,p,d.startAngle,d.clockwise,g,t))}else o.removeClipPath();this._data=r}},dispose:function(){},_createClipPath:function(t,e,n,i,r,a,o){var s=new Io({shape:{cx:t,cy:e,r0:0,r:n,startAngle:i,endAngle:i,clockwise:r}});return Rs(s,{shape:{endAngle:i+(r?1:-1)*Math.PI*2}},o,a),s},containPoint:function(t,e){var n=e.getData().getItemLayout(0);if(n){var i=t[0]-n.cx,r=t[1]-n.cy,a=Math.sqrt(i*i+r*r);return a<=n.r&&a>=n.r0}}});var Um=Math.PI/180;function Xm(r,t,e,n,i,a,o){function s(t,e,n){for(var i=t;i<e;i++)if(r[i].y+=n,t<i&&i+1<e&&r[i+1].y>r[i].y+r[i].height)return void l(i,n/2);l(e-1,n/2)}function l(t,e){for(var n=t;0<=n&&(r[n].y-=e,!(0<n&&r[n].y>r[n-1].y+r[n-1].height));n--);}function h(t,e,n,i,r,a){for(var o=e?Number.MAX_VALUE:0,s=0,l=t.length;s<l;s++){var h=Math.abs(t[s].y-i),u=t[s].len,c=t[s].len2,d=h<r+u?Math.sqrt((r+u+c)*(r+u+c)-h*h):Math.abs(t[s].x-n);e&&o<=d&&(d=o-10),!e&&d<=o&&(d=o+10),t[s].x=n+d*a,o=d}}r.sort(function(t,e){return t.y-e.y});for(var u,c=0,d=r.length,f=[],p=[],g=0;g<d;g++)(u=r[g].y-c)<0&&s(g,d,-u),c=r[g].y+r[g].height;o-c<0&&l(d-1,c-o);for(g=0;g<d;g++)r[g].y>=e?p.push(r[g]):f.push(r[g]);h(f,!1,t,e,n,i),h(p,!0,t,e,n,i)}function Ym(t){return"center"===t.position}function jm(I,C,t,e,n){var T,A,D=I.getData(),k=[],P=!1,L=(I.get("minShowLabelAngle")||0)*Um;D.each(function(t){var e=D.getItemLayout(t),n=D.getItemModel(t),i=n.getModel("label"),r=i.get("position")||n.get("emphasis.label.position"),a=n.getModel("labelLine"),o=a.get("length"),s=a.get("length2");if(!(e.angle<L)){var l,h,u,c,d=(e.startAngle+e.endAngle)/2,f=Math.cos(d),p=Math.sin(d);T=e.cx,A=e.cy;var g="inside"===r||"inner"===r;if("center"===r)l=e.cx,h=e.cy,c="center";else{var m=(g?(e.r+e.r0)/2*f:e.r*f)+T,v=(g?(e.r+e.r0)/2*p:e.r*p)+A;if(l=m+3*f,h=v+3*p,!g){var y=m+f*(o+C-e.r),_=v+p*(o+C-e.r),x=y+(f<0?-1:1)*s;l=x+(f<0?-5:5),u=[[m,v],[y,_],[x,h=_]]}c=g?"center":0<f?"left":"right"}var w,b=i.getFont(),S=i.get("rotate");w="number"==typeof S?S*(Math.PI/180):S?f<0?-d+Math.PI:-d:0;var M=ii(I.getFormattedLabel(t,"normal")||D.getName(t),b,c,"top");P=!!w,e.label={x:l,y:h,position:r,height:M.height,len:o,len2:s,linePoints:u,textAlign:c,verticalAlign:"middle",rotation:w,inside:g},g||k.push(e.label)}}),!P&&I.get("avoidLabelOverlap")&&function(t,e,n,i,r,a){for(var o=[],s=[],l=0;l<t.length;l++)Ym(t[l])||(t[l].x<e?o.push(t[l]):s.push(t[l]));for(Xm(s,e,n,i,1,0,a),Xm(o,e,n,i,-1,0,a),l=0;l<t.length;l++)if(!Ym(t[l])){var h=t[l].linePoints;if(h){var u=h[1][0]-h[2][0];t[l].x<e?h[2][0]=t[l].x+3:h[2][0]=t[l].x-3,h[1][1]=h[2][1]=t[l].y,h[1][0]=h[2][0]+u}}}(k,T,A,C,0,e)}var qm,$m,Km=2*Math.PI,Qm=Math.PI/180;qm="pie",A([{type:"pieToggleSelect",event:"pieselectchanged",method:"toggleSelected"},{type:"pieSelect",event:"pieselected",method:"select"},{type:"pieUnSelect",event:"pieunselected",method:"unSelect"}],function(a){a.update="updateView",zd(a,function(t,e){var r={};return e.eachComponent({mainType:"series",subType:qm,query:t},function(n){n[a.method]&&n[a.method](t.name,t.dataIndex);var i=n.getData();i.each(function(t){var e=i.getName(t);r[e]=n.isSelected(e)||!1})}),{name:t.name,selected:r,seriesId:t.seriesId}})}),Nd(($m="pie",{getTargetSeries:function(t){var e={},n=Q();return t.eachSeriesByType($m,function(t){t.__paletteScope=e,n.set(t.uid,t)}),n},reset:function(r,t){var a=r.getRawData(),o={},s=r.getData();s.each(function(t){var e=s.getRawIndex(t);o[e]=t}),a.each(function(t){var e=o[t],n=null!=e&&s.getItemVisual(e,"color",!0);if(n)a.setItemVisual(t,"color",n);else{var i=a.getItemModel(t).get("itemStyle.color")||r.getColorFromPalette(a.getName(t)||t+"",r.__paletteScope,a.count());a.setItemVisual(t,"color",i),null!=e&&s.setItemVisual(e,"color",i)}})}})),Ed(P(function(t,e,C,n){e.eachSeriesByType(t,function(t){var r=t.getData(),e=r.mapDimension("value"),n=t.get("center"),i=t.get("radius");O(i)||(i=[0,i]),O(n)||(n=[n,n]);var a=C.getWidth(),o=C.getHeight(),s=Math.min(a,o),l=rl(n[0],a),h=rl(n[1],o),u=rl(i[0],s/2),c=rl(i[1],s/2),d=-t.get("startAngle")*Qm,f=t.get("minAngle")*Qm,p=0;r.each(e,function(t){isNaN(t)||p++});var g=r.getSum(e),m=Math.PI/(g||p)*2,v=t.get("clockwise"),y=t.get("roseType"),_=t.get("stillShowZeroSum"),x=r.getDataExtent(e);x[0]=0;var w=Km,b=0,S=d,M=v?1:-1;if(r.each(e,function(t,e){var n;if(isNaN(t))r.setItemLayout(e,{angle:NaN,startAngle:NaN,endAngle:NaN,clockwise:v,cx:l,cy:h,r0:u,r:y?NaN:c});else{(n="area"!==y?0===g&&_?m:t*m:Km/p)<f?w-=n=f:b+=t;var i=S+M*n;r.setItemLayout(e,{angle:n,startAngle:S,endAngle:i,clockwise:v,cx:l,cy:h,r0:u,r:y?il(t,x,[u,c]):c}),S=i}}),w<Km&&p)if(w<=.001){var I=Km/p;r.each(e,function(t,e){if(!isNaN(t)){var n=r.getItemLayout(e);n.angle=I,n.startAngle=d+M*e*I,n.endAngle=d+M*(e+1)*I}})}else m=w/b,S=d,r.each(e,function(t,e){if(!isNaN(t)){var n=r.getItemLayout(e),i=n.angle===f?f:t*m;n.startAngle=S,n.endAngle=S+M*i,S+=M*i}});jm(t,c,0,o)})},"pie")),Od({seriesType:"pie",reset:function(t,e){var i=e.findComponents({mainType:"legend"});if(i&&i.length){var r=t.getData();r.filterSelf(function(t){for(var e=r.getName(t),n=0;n<i.length;n++)if(!i[n].isSelected(e))return!1;return!0})}}}),Su.extend({type:"series.scatter",dependencies:["grid","polar","geo","singleAxis","calendar"],getInitialData:function(t,e){return Mf(this.getSource(),this)},brushSelector:"point",getProgressive:function(){var t=this.option.progressive;return null==t?this.option.large?5e3:this.get("progressive"):t},getProgressiveThreshold:function(){var t=this.option.progressiveThreshold;return null==t?this.option.large?1e4:this.get("progressiveThreshold"):t},defaultOption:{coordinateSystem:"cartesian2d",zlevel:0,z:2,legendHoverLink:!0,hoverAnimation:!0,symbolSize:10,large:!1,largeThreshold:2e3,itemStyle:{opacity:.8}}});var Jm=is({shape:{points:null},symbolProxy:null,buildPath:function(t,e){var n=e.points,i=e.size,r=this.symbolProxy,a=r.shape;if(!((t.getContext?t.getContext():t)&&i[0]<4))for(var o=0;o<n.length;){var s=n[o++],l=n[o++];isNaN(s)||isNaN(l)||(a.x=s-i[0]/2,a.y=l-i[1]/2,a.width=i[0],a.height=i[1],r.buildPath(t,a,!0))}},afterBrush:function(t){var e=this.shape,n=e.points,i=e.size;if(i[0]<4){this.setTransform(t);for(var r=0;r<n.length;){var a=n[r++],o=n[r++];isNaN(a)||isNaN(o)||t.fillRect(a-i[0]/2,o-i[1]/2,i[0],i[1])}this.restoreTransform(t)}},findDataIndex:function(t,e){for(var n=this.shape,i=n.points,r=n.size,a=Math.max(r[0],4),o=Math.max(r[1],4),s=i.length/2-1;0<=s;s--){var l=2*s,h=i[l]-a/2,u=i[1+l]-o/2;if(h<=t&&u<=e&&t<=h+a&&e<=u+o)return s}return-1}});function tv(){this.group=new yn}var ev=tv.prototype;ev.isPersistent=function(){return!this._incremental},ev.updateData=function(t){this.group.removeAll();var e=new Jm({rectHover:!0,cursor:"default"});e.setShape({points:t.getLayout("symbolPoints")}),this._setCommon(e,t),this.group.add(e),this._incremental=null},ev.updateLayout=function(t){if(!this._incremental){var i=t.getLayout("symbolPoints");this.group.eachChild(function(t){if(null!=t.startIndex){var e=2*(t.endIndex-t.startIndex),n=4*t.startIndex*2;i=new Float32Array(i.buffer,n,e)}t.setShape("points",i)})}},ev.incrementalPrepareUpdate=function(t){this.group.removeAll(),this._clearIncremental(),2e6<t.count()?(this._incremental||(this._incremental=new Yo({silent:!0})),this.group.add(this._incremental)):this._incremental=null},ev.incrementalUpdate=function(t,e){var n;this._incremental?(n=new Jm,this._incremental.addDisplayable(n,!0)):((n=new Jm({rectHover:!0,cursor:"default",startIndex:t.start,endIndex:t.end})).incremental=!0,this.group.add(n)),n.setShape({points:e.getLayout("symbolPoints")}),this._setCommon(n,e,!!this._incremental)},ev._setCommon=function(n,t,e){var i=t.hostModel,r=t.getVisual("symbolSize");n.setShape("size",r instanceof Array?r:[r,r]),n.symbolProxy=Ap(t.getVisual("symbol"),0,0,0,0),n.setColor=n.symbolProxy.setColor;var a=n.shape.size[0]<4;n.useStyle(i.getModel("itemStyle").getItemStyle(a?["color","shadowBlur","shadowColor"]:["color"]));var o=t.getVisual("color");o&&n.setColor(o),e||(n.seriesIndex=i.seriesIndex,n.on("mousemove",function(t){n.dataIndex=null;var e=n.findDataIndex(t.offsetX,t.offsetY);0<=e&&(n.dataIndex=e+(n.startIndex||0))}))},ev.remove=function(){this._clearIncremental(),this._incremental=null,this.group.removeAll()},ev._clearIncremental=function(){var t=this._incremental;t&&t.clearDisplaybles()},Wd({type:"scatter",render:function(t,e,n){var i=t.getData();this._updateSymbolDraw(i,t).updateData(i),this._finished=!0},incrementalPrepareRender:function(t,e,n){var i=t.getData();this._updateSymbolDraw(i,t).incrementalPrepareUpdate(i),this._finished=!1},incrementalRender:function(t,e,n){this._symbolDraw.incrementalUpdate(t,e.getData()),this._finished=t.end===e.getData().count()},updateTransform:function(t,e,n){var i=t.getData();if(this.group.dirty(),!this._finished||1e4<i.count()||!this._symbolDraw.isPersistent())return{update:!0};var r=Eg().reset(t);r.progress&&r.progress({start:0,end:i.count()},i),this._symbolDraw.updateLayout(i)},_updateSymbolDraw:function(t,e){var n=this._symbolDraw,i=e.pipelineContext.large;return n&&i===this._isLargeDraw||(n&&n.remove(),n=this._symbolDraw=i?new tv:new hg,this._isLargeDraw=i,this.group.removeAll()),this.group.add(n.group),n},remove:function(t,e){this._symbolDraw&&this._symbolDraw.remove(!0),this._symbolDraw=null},dispose:function(){}}),Nd(zg("scatter","circle")),Ed(Eg("scatter")),Ld(function(t){var e=t.graphic;O(e)?e[0]&&e[0].elements?t.graphic=[t.graphic[0]]:t.graphic=[{elements:e}]:e&&!e.elements&&(t.graphic=[{elements:[e]}])});var nv=Fd({type:"graphic",defaultOption:{elements:[],parentId:null},_elOptionsToUpdate:null,mergeOption:function(t){var e=this.option.elements;this.option.elements=null,nv.superApply(this,"mergeOption",arguments),this.option.elements=e},optionUpdated:function(t,e){var n=this.option,i=(e?n:t).elements,r=n.elements=e?[]:n.elements,a=[];this._flatten(i,a);var o=_r(r,a);xr(o);var s=this._elOptionsToUpdate=[];A(o,function(t,e){var n=t.option;n&&(s.push(n),function(t,e){var n=t.exist;if(e.id=t.keyInfo.id,!e.type&&n&&(e.type=n.type),null==e.parentId){var i=e.parentOption;i?e.parentId=i.id:n&&(e.parentId=n.parentId)}e.parentOption=null}(t,n),function(t,e,n){var i=I({},n),r=t[e],a=n.$action||"merge";"merge"===a?r?(m(r,i,!0),Hl(r,i,{ignoreSize:!0}),Gl(n,r)):t[e]=i:"replace"===a?t[e]=i:"remove"===a&&r&&(t[e]=null)}(r,e,n),function(t,e){if(!t)return;t.hv=e.hv=[av(e,["left","right"]),av(e,["top","bottom"])],"group"===t.type&&(null==t.width&&(t.width=e.width=0),null==t.height&&(t.height=e.height=0))}(r[e],n))},this);for(var l=r.length-1;0<=l;l--)null==r[l]?r.splice(l,1):delete r[l].$action},_flatten:function(t,n,i){A(t,function(t){if(t){i&&(t.parentOption=i),n.push(t);var e=t.children;"group"===t.type&&e&&this._flatten(e,n,t),delete t.children}},this)},useElOptionsToUpdate:function(){var t=this._elOptionsToUpdate;return this._elOptionsToUpdate=null,t}});function iv(t,e,n,i){var r=n.type,a=new(Zs[r.charAt(0).toUpperCase()+r.slice(1)])(n);e.add(a),i.set(t,a),a.__ecGraphicId=t}function rv(t,e){var n=t&&t.parent;n&&("group"===t.type&&t.traverse(function(t){rv(t,e)}),e.removeKey(t.__ecGraphicId),n.remove(t))}function av(e,t){var n;return A(t,function(t){null!=e[t]&&"auto"!==e[t]&&(n=!0)}),n}Vd({type:"graphic",init:function(t,e){this._elMap=Q(),this._lastGraphicModel},render:function(t,e,n){t!==this._lastGraphicModel&&this._clear(),this._lastGraphicModel=t,this._updateElements(t),this._relocate(t,n)},_updateElements:function(h){var t=h.useElOptionsToUpdate();if(t){var u=this._elMap,c=this.group;A(t,function(t){var e=t.$action,n=t.id,i=u.get(n),r=t.parentId,a=null!=r?u.get(r):c,o=t.style;"text"===t.type&&o&&(t.hv&&t.hv[1]&&(o.textVerticalAlign=o.textBaseline=null),!o.hasOwnProperty("textFill")&&o.fill&&(o.textFill=o.fill),!o.hasOwnProperty("textStroke")&&o.stroke&&(o.textStroke=o.stroke));var s=function(e){return e=I({},e),A(["id","parentId","$action","hv","bounding"].concat(El),function(t){delete e[t]}),e}(t);e&&"merge"!==e?"replace"===e?(rv(i,u),iv(n,a,s,u)):"remove"===e&&rv(i,u):i?i.attr(s):iv(n,a,s,u);var l=u.get(n);l&&(l.__ecGraphicWidth=t.width,l.__ecGraphicHeight=t.height,function(t,e){var n=t.eventData;t.silent||t.ignore||n||(n=t.eventData={componentType:"graphic",componentIndex:e.componentIndex,name:t.name});n&&(n.info=t.info)}(l,h))})}},_relocate:function(t,e){for(var n=t.option.elements,i=this.group,r=this._elMap,a=n.length-1;0<=a;a--){var o=n[a],s=r.get(o.id);if(s){var l=s.parent;Vl(s,o,l===i?{width:e.getWidth(),height:e.getHeight()}:{width:l.__ecGraphicWidth||0,height:l.__ecGraphicHeight||0},null,{hv:o.hv,boundingMode:o.bounding})}}},_clear:function(){var e=this._elMap;e.each(function(t){rv(t,e)}),this._elMap=Q()},dispose:function(){this._clear()}});function ov(t,e){var n,i=[],r=t.seriesIndex;if(null==r||!(n=e.getSeriesByIndex(r)))return{point:[]};var a=n.getData(),o=Sr(a,t);if(null==o||o<0||O(o))return{point:[]};var s=a.getItemGraphicEl(o),l=n.coordinateSystem;if(n.getTooltipPosition)i=n.getTooltipPosition(o)||[];else if(l&&l.dataToPoint)i=l.dataToPoint(a.getValues(D(l.dimensions,function(t){return a.mapDimension(t)}),o,!0))||[];else if(s){var h=s.getBoundingRect().clone();h.applyTransform(s.transform),i=[h.x+h.width/2,h.y+h.height/2]}return{point:i,el:s}}var sv=A,lv=P,hv=Mr();function uv(t,e,n,i,r){var a=t.axis;if(!a.scale.isBlank()&&a.containData(e))if(t.involveSeries){var o=function(l,t){var h=t.axis,u=h.dim,c=l,d=[],f=Number.MAX_VALUE,p=-1;return sv(t.seriesModels,function(e,t){var n,i,r=e.getData().mapDimension(u,!0);if(e.getAxisTooltipData){var a=e.getAxisTooltipData(r,l,h);i=a.dataIndices,n=a.nestestValue}else{if(!(i=e.getData().indicesOfNearest(r[0],l,"category"===h.type?.5:null)).length)return;n=e.getData().get(r[0],i[0])}if(null!=n&&isFinite(n)){var o=l-n,s=Math.abs(o);s<=f&&((s<f||0<=o&&p<0)&&(f=s,p=o,c=n,d.length=0),sv(i,function(t){d.push({seriesIndex:e.seriesIndex,dataIndexInside:t,dataIndex:e.getData().getRawIndex(t)})}))}}),{payloadBatch:d,snapToValue:c}}(e,t),s=o.payloadBatch,l=o.snapToValue;s[0]&&null==r.seriesIndex&&I(r,s[0]),!i&&t.snap&&a.containData(l)&&null!=l&&(e=l),n.showPointer(t,e,s,r),n.showTooltip(t,o,l)}else n.showPointer(t,e)}function cv(t,e,n,i){t[e.key]={value:n,payloadBatch:i}}function dv(t,e,n,i){var r=n.payloadBatch,a=e.axis,o=a.model,s=e.axisPointerModel;if(e.triggerTooltip&&r.length){var l=e.coordSys.model,h=ym(l),u=t.map[h];u||(u=t.map[h]={coordSysId:l.id,coordSysIndex:l.componentIndex,coordSysType:l.type,coordSysMainType:l.mainType,dataByAxis:[]},t.list.push(u)),u.dataByAxis.push({axisDim:a.dim,axisIndex:o.componentIndex,axisType:o.type,axisId:o.id,value:i,valueLabelOpt:{precision:s.get("label.precision"),formatter:s.get("label.formatter")},seriesDataIndices:r.slice()})}}function fv(t){var e=t.axis.model,n={},i=n.axisDim=t.axis.dim;return n.axisIndex=n[i+"AxisIndex"]=e.componentIndex,n.axisName=n[i+"AxisName"]=e.name,n.axisId=n[i+"AxisId"]=e.id,n}function pv(t){return!t||null==t[0]||isNaN(t[0])||null==t[1]||isNaN(t[1])}Fd({type:"axisPointer",coordSysAxesInfo:null,defaultOption:{show:"auto",triggerOn:null,zlevel:0,z:50,type:"line",snap:!1,triggerTooltip:!0,value:null,status:null,link:[],animation:null,animationDurationUpdate:200,lineStyle:{color:"#aaa",width:1,type:"solid"},shadowStyle:{color:"rgba(150,150,150,0.3)"},label:{show:!0,formatter:null,precision:"auto",margin:3,color:"#fff",padding:[5,7,5,7],backgroundColor:"auto",borderColor:null,borderWidth:0,shadowBlur:3,shadowColor:"#aaa"},handle:{show:!1,icon:"M10.7,11.9v-1.3H9.3v1.3c-4.9,0.3-8.8,4.4-8.8,9.4c0,5,3.9,9.1,8.8,9.4h1.3c4.9-0.3,8.8-4.4,8.8-9.4C19.5,16.3,15.6,12.2,10.7,11.9z M13.3,24.4H6.7v-1.2h6.6z M13.3,22H6.7v-1.2h6.6z M13.3,19.6H6.7v-1.2h6.6z",size:45,margin:50,color:"#333",shadowBlur:3,shadowColor:"#aaa",shadowOffsetX:0,shadowOffsetY:2,throttle:40}}});var gv=Mr(),mv=A;function vv(t,e,n){if(!v.node){var i=e.getZr();gv(i).records||(gv(i).records={}),function(r,a){if(gv(r).initialized)return;function t(t,i){r.on(t,function(e){var n=function(n){var i={showTip:[],hideTip:[]},r=function(t){var e=i[t.type];e?e.push(t):(t.dispatchAction=r,n.dispatchAction(t))};return{dispatchAction:r,pendings:i}}(a);mv(gv(r).records,function(t){t&&i(t,e,n.dispatchAction)}),function(t,e){var n,i=t.showTip.length,r=t.hideTip.length;i?n=t.showTip[i-1]:r&&(n=t.hideTip[r-1]);n&&(n.dispatchAction=null,e.dispatchAction(n))}(n.pendings,a)})}gv(r).initialized=!0,t("click",P(_v,"click")),t("mousemove",P(_v,"mousemove")),t("globalout",yv)}(i,e),(gv(i).records[t]||(gv(i).records[t]={})).handler=n}}function yv(t,e,n){t.handler("leave",null,n)}function _v(t,e,n,i){e.handler(t,n,i)}function xv(t,e){if(!v.node){var n=e.getZr();(gv(n).records||{})[t]&&(gv(n).records[t]=null)}}var wv=Vd({type:"axisPointer",render:function(t,e,n){var i=e.getComponent("tooltip"),r=t.get("triggerOn")||i&&i.get("triggerOn")||"mousemove|click";vv("axisPointer",n,function(t,e,n){"none"!==r&&("leave"===t||0<=r.indexOf(t))&&n({type:"updateAxisPointer",currTrigger:t,x:e&&e.offsetX,y:e&&e.offsetY})})},remove:function(t,e){xv(e.getZr(),"axisPointer"),wv.superApply(this._model,"remove",arguments)},dispose:function(t,e){xv("axisPointer",e),wv.superApply(this._model,"dispose",arguments)}}),bv=Mr(),Sv=b,Mv=k;function Iv(){}function Cv(t,e,n,i){!function n(i,t){{if(N(i)&&N(t)){var r=!0;return A(t,function(t,e){r=r&&n(i[e],t)}),!!r}return i===t}}(bv(n).lastProp,i)&&(bv(n).lastProp=i,e?Ns(n,i,t):(n.stopAnimation(),n.attr(i)))}function Tv(t,e){t[e.get("label.show")?"show":"hide"]()}function Av(t){return{position:t.position.slice(),rotation:t.rotation||0}}function Dv(t,e,n){var i=e.get("z"),r=e.get("zlevel");t&&t.traverse(function(t){"group"!==t.type&&(null!=i&&(t.z=i),null!=r&&(t.zlevel=r),t.silent=n)})}function kv(t,e,n,i,r){var a=Pv(n.get("value"),e.axis,e.ecModel,n.get("seriesDataIndices"),{precision:n.get("label.precision"),formatter:n.get("label.formatter")}),o=n.getModel("label"),s=wl(o.get("padding")||0),l=o.getFont(),h=ii(a,l),u=r.position,c=h.width+s[1]+s[3],d=h.height+s[0]+s[2],f=r.align;"right"===f&&(u[0]-=c),"center"===f&&(u[0]-=c/2);var p=r.verticalAlign;"bottom"===p&&(u[1]-=d),"middle"===p&&(u[1]-=d/2),function(t,e,n,i){var r=i.getWidth(),a=i.getHeight();t[0]=Math.min(t[0]+e,r)-e,t[1]=Math.min(t[1]+n,a)-n,t[0]=Math.max(t[0],0),t[1]=Math.max(t[1],0)}(u,c,d,i);var g=o.get("backgroundColor");g&&"auto"!==g||(g=e.get("axisLine.lineStyle.color")),t.label={shape:{x:0,y:0,width:c,height:d,r:o.get("borderRadius")},position:u.slice(),style:{text:a,textFont:l,textFill:o.getTextColor(),textPosition:"inside",textPadding:s,fill:g,stroke:o.get("borderColor")||"transparent",lineWidth:o.get("borderWidth")||0,shadowBlur:o.get("shadowBlur"),shadowColor:o.get("shadowColor"),shadowOffsetX:o.get("shadowOffsetX"),shadowOffsetY:o.get("shadowOffsetY")},z2:10}}function Pv(t,e,r,n,i){t=e.scale.parse(t);var a=e.scale.getLabel(t,{precision:i.precision}),o=i.formatter;if(o){var s={value:mp(e,t),axisDimension:e.dim,axisIndex:e.index,seriesData:[]};A(n,function(t){var e=r.getSeriesByIndex(t.seriesIndex),n=t.dataIndexInside,i=e&&e.getDataParams(n);i&&s.seriesData.push(i)}),E(o)?a=o.replace("{value}",a):z(o)&&(a=o(s))}return a}function Lv(t,e,n){var i=qt();return te(i,i,n.rotation),Jt(i,i,n.position),Fs([t.dataToCoord(e),(n.labelOffset||0)+(n.labelDirection||1)*(n.labelMargin||0)],i)}Or((Iv.prototype={_group:null,_lastGraphicKey:null,_handle:null,_dragging:!1,_lastValue:null,_lastStatus:null,_payloadInfo:null,animationThreshold:15,render:function(t,e,n,i){var r=e.get("value"),a=e.get("status");if(this._axisModel=t,this._axisPointerModel=e,this._api=n,i||this._lastValue!==r||this._lastStatus!==a){this._lastValue=r,this._lastStatus=a;var o=this._group,s=this._handle;if(!a||"hide"===a)return o&&o.hide(),void(s&&s.hide());o&&o.show(),s&&s.show();var l={};this.makeElOption(l,r,t,e,n);var h=l.graphicKey;h!==this._lastGraphicKey&&this.clear(n),this._lastGraphicKey=h;var u=this._moveAnimation=this.determineAnimation(t,e);if(o){var c=P(Cv,e,u);this.updatePointerEl(o,l,c,e),this.updateLabelEl(o,l,c,e)}else o=this._group=new yn,this.createPointerEl(o,l,t,e),this.createLabelEl(o,l,t,e),n.getZr().add(o);Dv(o,e,!0),this._renderHandle(r)}},remove:function(t){this.clear(t)},dispose:function(t){this.clear(t)},determineAnimation:function(t,e){var n=e.get("animation"),i=t.axis,r="category"===i.type,a=e.get("snap");if(!a&&!r)return!1;if("auto"!==n&&null!=n)return!0===n;var o=this.animationThreshold;if(r&&i.getBandWidth()>o)return!0;if(a){var s=mm(t).seriesDataCount,l=i.getExtent();return Math.abs(l[0]-l[1])/s>o}return!1},makeElOption:function(t,e,n,i,r){},createPointerEl:function(t,e,n,i){var r=e.pointer;if(r){var a=bv(t).pointerEl=new Zs[r.type](Sv(e.pointer));t.add(a)}},createLabelEl:function(t,e,n,i){if(e.label){var r=bv(t).labelEl=new No(Sv(e.label));t.add(r),Tv(r,i)}},updatePointerEl:function(t,e,n){var i=bv(t).pointerEl;i&&e.pointer&&(i.setStyle(e.pointer.style),n(i,{shape:e.pointer.shape}))},updateLabelEl:function(t,e,n,i){var r=bv(t).labelEl;r&&(r.setStyle(e.label.style),n(r,{shape:e.label.shape,position:e.label.position}),Tv(r,i))},_renderHandle:function(t){if(!this._dragging&&this.updateHandleTransform){var e,n=this._axisPointerModel,i=this._api.getZr(),r=this._handle,a=n.getModel("handle"),o=n.get("status");if(!a.get("show")||!o||"hide"===o)return r&&i.remove(r),void(this._handle=null);this._handle||(e=!0,r=this._handle=Gs(a.get("icon"),{cursor:"move",draggable:!0,onmousemove:function(t){Rt(t.event)},onmousedown:Mv(this._onHandleDragMove,this,0,0),drift:Mv(this._onHandleDragMove,this),ondragend:Mv(this._onHandleDragEnd,this)}),i.add(r)),Dv(r,n,!1);r.setStyle(a.getItemStyle(null,["color","borderColor","borderWidth","opacity","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"]));var s=a.get("size");O(s)||(s=[s,s]),r.attr("scale",[s[0]/2,s[1]/2]),Yu(this,"_doDispatchAxisPointer",a.get("throttle")||0,"fixRate"),this._moveHandleToValue(t,e)}},_moveHandleToValue:function(t,e){Cv(this._axisPointerModel,!e&&this._moveAnimation,this._handle,Av(this.getHandleTransform(t,this._axisModel,this._axisPointerModel)))},_onHandleDragMove:function(t,e){var n=this._handle;if(n){this._dragging=!0;var i=this.updateHandleTransform(Av(n),[t,e],this._axisModel,this._axisPointerModel);this._payloadInfo=i,n.stopAnimation(),n.attr(Av(i)),bv(n).lastProp=null,this._doDispatchAxisPointer()}},_doDispatchAxisPointer:function(){if(this._handle){var t=this._payloadInfo,e=this._axisModel;this._api.dispatchAction({type:"updateAxisPointer",x:t.cursorPoint[0],y:t.cursorPoint[1],tooltipOption:t.tooltipOption,axesInfo:[{axisDim:e.axis.dim,axisIndex:e.componentIndex}]})}},_onHandleDragEnd:function(t){if(this._dragging=!1,this._handle){var e=this._axisPointerModel.get("value");this._moveHandleToValue(e),this._api.dispatchAction({type:"hideTip"})}},getHandleTransform:null,updateHandleTransform:null,clear:function(t){this._lastValue=null,this._lastStatus=null;var e=t.getZr(),n=this._group,i=this._handle;e&&n&&(this._lastGraphicKey=null,n&&e.remove(n),i&&e.remove(i),this._group=null,this._handle=null,this._payloadInfo=null)},doClear:function(){},buildLabel:function(t,e,n){return{x:t[n=n||0],y:t[1-n],width:e[n],height:e[1-n]}}}).constructor=Iv);var Ov=Iv.extend({makeElOption:function(t,e,n,i,r){var a=n.axis,o=a.grid,s=i.get("type"),l=zv(o,a).getOtherAxis(a).getGlobalExtent(),h=a.toGlobalCoord(a.dataToCoord(e,!0));if(s&&"none"!==s){var u=function(t){var e,n=t.get("type"),i=t.getModel(n+"Style");return"line"===n?(e=i.getLineStyle()).fill=null:"shadow"===n&&((e=i.getAreaStyle()).stroke=null),e}(i),c=Ev[s](a,h,l);c.style=u,t.graphicKey=c.type,t.pointer=c}!function(t,e,n,i,r,a){var o=im.innerTextLayout(n.rotation,0,n.labelDirection);n.labelMargin=r.get("label.margin"),kv(e,i,r,a,{position:Lv(i.axis,t,n),align:o.textAlign,verticalAlign:o.textVerticalAlign})}(e,t,Sm(o.model,n),n,i,r)},getHandleTransform:function(t,e,n){var i=Sm(e.axis.grid.model,e,{labelInside:!1});return i.labelMargin=n.get("handle.margin"),{position:Lv(e.axis,t,i),rotation:i.rotation+(i.labelDirection<0?Math.PI:0)}},updateHandleTransform:function(t,e,n,i){var r=n.axis,a=r.grid,o=r.getGlobalExtent(!0),s=zv(a,r).getOtherAxis(r).getGlobalExtent(),l="x"===r.dim?0:1,h=t.position;h[l]+=e[l],h[l]=Math.min(o[1],h[l]),h[l]=Math.max(o[0],h[l]);var u=(s[1]+s[0])/2,c=[u,u];c[l]=h[l];return{position:h,rotation:t.rotation,cursorPoint:c,tooltipOption:[{verticalAlign:"middle"},{align:"center"}][l]}}});function zv(t,e){var n={};return n[e.dim+"AxisIndex"]=e.index,t.getCartesian(n)}var Ev={line:function(t,e,n){return{type:"Line",subPixelOptimize:!0,shape:function(t,e,n){return{x1:t[n=n||0],y1:t[1-n],x2:e[n],y2:e[1-n]}}([e,n[0]],[e,n[1]],Nv(t))}},shadow:function(t,e,n){var i=Math.max(1,t.getBandWidth()),r=n[1]-n[0];return{type:"Rect",shape:function(t,e,n){return{x:t[n=n||0],y:t[1-n],width:e[n],height:e[1-n]}}([e-i/2,n[0]],[i,r],Nv(t))}}};function Nv(t){return"x"===t.dim?0:1}_m.registerAxisPointerClass("CartesianAxisPointer",Ov),Ld(function(t){if(t){t.axisPointer&&0!==t.axisPointer.length||(t.axisPointer={});var e=t.axisPointer.link;e&&!O(e)&&(t.axisPointer.link=[e])}}),Od(Uc.PROCESSOR.STATISTIC,function(t,e){t.getComponent("axisPointer").coordSysAxesInfo=pm(t,e)}),zd({type:"updateAxisPointer",event:"updateAxisPointer",update:":updateAxisPointer"},function(t,e,n){var i=t.currTrigger,o=[t.x,t.y],r=t,a=t.dispatchAction||k(n.dispatchAction,n),s=e.getComponent("axisPointer").coordSysAxesInfo;if(s){pv(o)&&(o=ov({seriesIndex:r.seriesIndex,dataIndex:r.dataIndex},e).point);var l=pv(o),h=r.axesInfo,u=s.axesInfo,c="leave"===i||pv(o),d={},f={},p={list:[],map:{}},g={showPointer:lv(cv,f),showTooltip:lv(dv,p)};sv(s.coordSysMap,function(t,e){var a=l||t.containPoint(o);sv(s.coordSysAxesInfo[e],function(t,e){var n=t.axis,i=function(t,e){for(var n=0;n<(t||[]).length;n++){var i=t[n];if(e.axis.dim===i.axisDim&&e.axis.model.componentIndex===i.axisIndex)return i}}(h,t);if(!c&&a&&(!h||i)){var r=i&&i.value;null!=r||l||(r=n.pointToData(o)),null!=r&&uv(t,r,g,!1,d)}})});var m={};return sv(u,function(r,t){var a=r.linkGroup;a&&!f[t]&&sv(a.axesInfo,function(t,e){var n=f[e];if(t!==r&&n){var i=n.value;a.mapper&&(i=r.axis.scale.parse(a.mapper(i,fv(t),fv(r)))),m[r.key]=i}})}),sv(m,function(t,e){uv(u[e],t,g,!0,d)}),function(r,t,e){var a=e.axesInfo=[];sv(t,function(t,e){var n=t.axisPointerModel.option,i=r[e];i?(t.useHandle||(n.status="show"),n.value=i.value,n.seriesDataIndices=(i.payloadBatch||[]).slice()):t.useHandle||(n.status="hide"),"show"===n.status&&a.push({axisDim:t.axis.dim,axisIndex:t.axis.model.componentIndex,value:n.value})})}(f,u,d),function(t,e,n,i){if(pv(e)||!t.list.length)return i({type:"hideTip"});var r=((t.list[0].dataByAxis[0]||{}).seriesDataIndices||[])[0]||{};i({type:"showTip",escapeConnect:!0,x:e[0],y:e[1],tooltipOption:n.tooltipOption,position:n.position,dataIndexInside:r.dataIndexInside,dataIndex:r.dataIndex,seriesIndex:r.seriesIndex,dataByCoordSys:t.list})}(p,o,t,a),function(t,e,n){var i=n.getZr(),r="axisPointerLastHighlights",a=hv(i)[r]||{},o=hv(i)[r]={};sv(t,function(t,e){var n=t.axisPointerModel.option;"show"===n.status&&sv(n.seriesDataIndices,function(t){var e=t.seriesIndex+" | "+t.dataIndex;o[e]=t})});var s=[],l=[];A(a,function(t,e){o[e]||l.push(t)}),A(o,function(t,e){a[e]||s.push(t)}),l.length&&n.dispatchAction({type:"downplay",escapeConnect:!0,batch:l}),s.length&&n.dispatchAction({type:"highlight",escapeConnect:!0,batch:s})}(u,0,n),d}}),Fd({type:"tooltip",dependencies:["axisPointer"],defaultOption:{zlevel:0,z:60,show:!0,showContent:!0,trigger:"item",triggerOn:"mousemove|click",alwaysShowContent:!1,displayMode:"single",renderMode:"auto",confine:!1,showDelay:0,hideDelay:100,transitionDuration:.4,enterable:!1,backgroundColor:"rgba(50,50,50,0.7)",borderColor:"#333",borderRadius:4,borderWidth:0,padding:5,extraCssText:"",axisPointer:{type:"line",axis:"auto",animation:"auto",animationDurationUpdate:200,animationEasingUpdate:"exponentialOut",crossStyle:{color:"#999",width:1,type:"dashed",textStyle:{}}},textStyle:{color:"#fff",fontSize:14}}});var Rv=A,Bv=xl,Fv=["","-webkit-","-moz-","-o-"];function Vv(r){var a=[],t=r.get("transitionDuration"),e=r.get("backgroundColor"),n=r.getModel("textStyle"),i=r.get("padding");return t&&a.push(function(t){var e="cubic-bezier(0.23, 1, 0.32, 1)",n="left "+t+"s "+e+",top "+t+"s "+e;return D(Fv,function(t){return t+"transition:"+n}).join(";")}(t)),e&&(v.canvasSupported?a.push("background-Color:"+e):(a.push("background-Color:#"+Oe(e)),a.push("filter:alpha(opacity=70)"))),Rv(["width","color","radius"],function(t){var e="border-"+t,n=Bv(e),i=r.get(n);null!=i&&a.push(e+":"+i+("color"===t?"":"px"))}),a.push(function(n){var i=[],t=n.get("fontSize"),e=n.getTextColor();return e&&i.push("color:"+e),i.push("font:"+n.getFont()),t&&i.push("line-height:"+Math.round(3*t/2)+"px"),Rv(["decoration","align"],function(t){var e=n.get(t);e&&i.push("text-"+t+":"+e)}),i.join(";")}(n)),null!=i&&a.push("padding:"+wl(i).join("px ")+"px"),a.join(";")+";"}function Hv(n,t){if(v.wxa)return null;var e=document.createElement("div"),i=this._zr=t.getZr();this.el=e,this._x=t.getWidth()/2,this._y=t.getHeight()/2,n.appendChild(e),this._container=n,this._show=!1,this._hideTimeout;var r=this;e.onmouseenter=function(){r._enterable&&(clearTimeout(r._hideTimeout),r._show=!0),r._inContent=!0},e.onmousemove=function(t){if(t=t||window.event,!r._enterable){var e=i.handler;Et(n,t,!0),e.dispatch("mousemove",t)}},e.onmouseleave=function(){r._enterable&&r._show&&r.hideLater(r._hideDelay),r._inContent=!1}}function Wv(t){this._zr=t.getZr(),this._show=!1,this._hideTimeout}Hv.prototype={constructor:Hv,_enterable:!0,update:function(){var t=this._container,e=t.currentStyle||document.defaultView.getComputedStyle(t),n=t.style;"absolute"!==n.position&&"absolute"!==e.position&&(n.position="relative")},show:function(t){clearTimeout(this._hideTimeout);var e=this.el;e.style.cssText="position:absolute;display:block;border-style:solid;white-space:nowrap;z-index:9999999;"+Vv(t)+";left:"+this._x+"px;top:"+this._y+"px;"+(t.get("extraCssText")||""),e.style.display=e.innerHTML?"block":"none",e.style.pointerEvents=this._enterable?"auto":"none",this._show=!0},setContent:function(t){this.el.innerHTML=null==t?"":t},setEnterable:function(t){this._enterable=t},getSize:function(){var t=this.el;return[t.clientWidth,t.clientHeight]},moveTo:function(t,e){var n,i=this._zr;i&&i.painter&&(n=i.painter.getViewportRootOffset())&&(t+=n.offsetLeft,e+=n.offsetTop);var r=this.el.style;r.left=t+"px",r.top=e+"px",this._x=t,this._y=e},hide:function(){this.el.style.display="none",this._show=!1},hideLater:function(t){!this._show||this._inContent&&this._enterable||(t?(this._hideDelay=t,this._show=!1,this._hideTimeout=setTimeout(k(this.hide,this),t)):this.hide())},isShow:function(){return this._show},getOuterSize:function(){var t=this.el.clientWidth,e=this.el.clientHeight;if(document.defaultView&&document.defaultView.getComputedStyle){var n=document.defaultView.getComputedStyle(this.el);n&&(t+=parseInt(n.borderLeftWidth,10)+parseInt(n.borderRightWidth,10),e+=parseInt(n.borderTopWidth,10)+parseInt(n.borderBottomWidth,10))}return{width:t,height:e}}},Wv.prototype={constructor:Wv,_enterable:!0,update:function(){},show:function(t){this._hideTimeout&&clearTimeout(this._hideTimeout),this.el.attr("show",!0),this._show=!0},setContent:function(t,e,n){this.el&&this._zr.remove(this.el);for(var i={},r=t,a="{marker",o=r.indexOf(a);0<=o;){var s=r.indexOf("|}"),l=r.substr(o+a.length,s-o-a.length);-1<l.indexOf("sub")?i["marker"+l]={textWidth:4,textHeight:4,textBorderRadius:2,textBackgroundColor:e[l],textOffset:[3,0]}:i["marker"+l]={textWidth:10,textHeight:10,textBorderRadius:5,textBackgroundColor:e[l]},o=(r=r.substr(s+1)).indexOf("{marker")}this.el=new wo({style:{rich:i,text:t,textLineHeight:20,textBackgroundColor:n.get("backgroundColor"),textBorderRadius:n.get("borderRadius"),textFill:n.get("textStyle.color"),textPadding:n.get("padding")},z:n.get("z")}),this._zr.add(this.el);var h=this;this.el.on("mouseover",function(){h._enterable&&(clearTimeout(h._hideTimeout),h._show=!0),h._inContent=!0}),this.el.on("mouseout",function(){h._enterable&&h._show&&h.hideLater(h._hideDelay),h._inContent=!1})},setEnterable:function(t){this._enterable=t},getSize:function(){var t=this.el.getBoundingRect();return[t.width,t.height]},moveTo:function(t,e){this.el&&this.el.attr("position",[t,e])},hide:function(){this.el&&this.el.hide(),this._show=!1},hideLater:function(t){!this._show||this._inContent&&this._enterable||(t?(this._hideDelay=t,this._show=!1,this._hideTimeout=setTimeout(k(this.hide,this),t)):this.hide())},isShow:function(){return this._show},getOuterSize:function(){var t=this.getSize();return{width:t[0],height:t[1]}}};var Gv=k,Zv=A,Uv=rl,Xv=new No({shape:{x:-1,y:-1,width:2,height:2}});function Yv(t){for(var e=t.pop();t.length;){var n=t.pop();n&&(Ks.isInstance(n)&&(n=n.get("tooltip",!0)),"string"==typeof n&&(n={formatter:n}),e=new Ks(n,e,e.ecModel))}return e}function jv(t,e){return t.dispatchAction||k(e.dispatchAction,e)}function qv(t){return"center"===t||"middle"===t}Vd({type:"tooltip",init:function(t,e){if(!v.node){var n,i=t.getComponent("tooltip").get("renderMode");this._renderMode=Dr(i),"html"===this._renderMode?(n=new Hv(e.getDom(),e),this._newLine="<br/>"):(n=new Wv(e),this._newLine="\n"),this._tooltipContent=n}},render:function(t,e,n){if(!v.node){this.group.removeAll(),this._tooltipModel=t,this._ecModel=e,this._api=n,this._lastDataByCoordSys=null,this._alwaysShowContent=t.get("alwaysShowContent");var i=this._tooltipContent;i.update(),i.setEnterable(t.get("enterable")),this._initGlobalListener(),this._keepShow()}},_initGlobalListener:function(){var i=this._tooltipModel.get("triggerOn");vv("itemTooltip",this._api,Gv(function(t,e,n){"none"!==i&&(0<=i.indexOf(t)?this._tryShow(e,n):"leave"===t&&this._hide(n))},this))},_keepShow:function(){var t=this._tooltipModel,e=this._ecModel,n=this._api;if(null!=this._lastX&&null!=this._lastY&&"none"!==t.get("triggerOn")){var i=this;clearTimeout(this._refreshUpdateTimeout),this._refreshUpdateTimeout=setTimeout(function(){n.isDisposed()||i.manuallyShowTip(t,e,n,{x:i._lastX,y:i._lastY})})}},manuallyShowTip:function(t,e,n,i){if(i.from!==this.uid&&!v.node){var r=jv(i,n);this._ticket="";var a=i.dataByCoordSys;if(i.tooltip&&null!=i.x&&null!=i.y){var o=Xv;o.position=[i.x,i.y],o.update(),o.tooltip=i.tooltip,this._tryShow({offsetX:i.x,offsetY:i.y,target:o},r)}else if(a)this._tryShow({offsetX:i.x,offsetY:i.y,position:i.position,event:{},dataByCoordSys:i.dataByCoordSys,tooltipOption:i.tooltipOption},r);else if(null!=i.seriesIndex){if(this._manuallyAxisShowTip(t,e,n,i))return;var s=ov(i,e),l=s.point[0],h=s.point[1];null!=l&&null!=h&&this._tryShow({offsetX:l,offsetY:h,position:i.position,target:s.el,event:{}},r)}else null!=i.x&&null!=i.y&&(n.dispatchAction({type:"updateAxisPointer",x:i.x,y:i.y}),this._tryShow({offsetX:i.x,offsetY:i.y,position:i.position,target:n.getZr().findHover(i.x,i.y).target,event:{}},r))}},manuallyHideTip:function(t,e,n,i){var r=this._tooltipContent;!this._alwaysShowContent&&this._tooltipModel&&r.hideLater(this._tooltipModel.get("hideDelay")),this._lastX=this._lastY=null,i.from!==this.uid&&this._hide(jv(i,n))},_manuallyAxisShowTip:function(t,e,n,i){var r=i.seriesIndex,a=i.dataIndex,o=e.getComponent("axisPointer").coordSysAxesInfo;if(null!=r&&null!=a&&null!=o){var s=e.getSeriesByIndex(r);if(s)if("axis"===(t=Yv([s.getData().getItemModel(a),s,(s.coordinateSystem||{}).model,t])).get("trigger"))return n.dispatchAction({type:"updateAxisPointer",seriesIndex:r,dataIndex:a,position:i.position}),!0}},_tryShow:function(t,e){var n=t.target;if(this._tooltipModel){this._lastX=t.offsetX,this._lastY=t.offsetY;var i=t.dataByCoordSys;i&&i.length?this._showAxisTooltip(i,t):n&&null!=n.dataIndex?(this._lastDataByCoordSys=null,this._showSeriesItemTooltip(t,n,e)):n&&n.tooltip?(this._lastDataByCoordSys=null,this._showComponentItemTooltip(t,n,e)):(this._lastDataByCoordSys=null,this._hide(e))}},_showOrMove:function(t,e){var n=t.get("showDelay");e=k(e,this),clearTimeout(this._showTimout),0<n?this._showTimout=setTimeout(e,n):e()},_showAxisTooltip:function(t,e){var d=this._ecModel,n=this._tooltipModel,i=[e.offsetX,e.offsetY],r=[],f=[],a=Yv([e.tooltipOption,n]),p=this._renderMode,o=this._newLine,g={};Zv(t,function(t){Zv(t.dataByAxis,function(s){var l=d.getComponent(s.axisDim+"Axis",s.axisIndex),h=s.value,u=[];if(l&&null!=h){var c=Pv(h,l.axis,d,s.seriesDataIndices,s.valueLabelOpt);A(s.seriesDataIndices,function(t){var e=d.getSeriesByIndex(t.seriesIndex),n=t.dataIndexInside,i=e&&e.getDataParams(n);if(i.axisDim=s.axisDim,i.axisIndex=s.axisIndex,i.axisType=s.axisType,i.axisId=s.axisId,i.axisValue=mp(l.axis,h),i.axisValueLabel=c,i){f.push(i);var r,a=e.formatTooltip(n,!0,null,p);if(N(a)){r=a.html;var o=a.markers;m(g,o)}else r=a;u.push(r)}});var t=c;"html"!==p?r.push(u.join(o)):r.push((t?Ml(t)+o:"")+u.join(o))}})},this),r.reverse(),r=r.join(this._newLine+this._newLine);var s=e.position;this._showOrMove(a,function(){this._updateContentNotChangedOnAxis(t)?this._updatePosition(a,s,i[0],i[1],this._tooltipContent,f):this._showTooltipContent(a,r,f,Math.random(),i[0],i[1],s,void 0,g)})},_showSeriesItemTooltip:function(t,e,n){var i=this._ecModel,r=e.seriesIndex,a=i.getSeriesByIndex(r),o=e.dataModel||a,s=e.dataIndex,l=e.dataType,h=o.getData(),u=Yv([h.getItemModel(s),o,a&&(a.coordinateSystem||{}).model,this._tooltipModel]),c=u.get("trigger");if(null==c||"item"===c){var d,f,p=o.getDataParams(s,l),g=o.formatTooltip(s,!1,l,this._renderMode);f=N(g)?(d=g.html,g.markers):(d=g,null);var m="item_"+o.name+"_"+s;this._showOrMove(u,function(){this._showTooltipContent(u,d,p,m,t.offsetX,t.offsetY,t.position,t.target,f)}),n({type:"showTip",dataIndexInside:s,dataIndex:h.getRawIndex(s),seriesIndex:r,from:this.uid})}},_showComponentItemTooltip:function(t,e,n){var i=e.tooltip;if("string"==typeof i){i={content:i,formatter:i}}var r=new Ks(i,this._tooltipModel,this._ecModel),a=r.get("content"),o=Math.random();this._showOrMove(r,function(){this._showTooltipContent(r,a,r.get("formatterParams")||{},o,t.offsetX,t.offsetY,t.position,e)}),n({type:"showTip",from:this.uid})},_showTooltipContent:function(n,t,i,e,r,a,o,s,l){if(this._ticket="",n.get("showContent")&&n.get("show")){var h=this._tooltipContent,u=n.get("formatter");o=o||n.get("position");var c=t;if(u&&"string"==typeof u)c=Tl(u,i,!0);else if("function"==typeof u){var d=Gv(function(t,e){t===this._ticket&&(h.setContent(e,l,n),this._updatePosition(n,o,r,a,h,i,s))},this);this._ticket=e,c=u(i,e,d)}h.setContent(c,l,n),h.show(n),this._updatePosition(n,o,r,a,h,i,s)}},_updatePosition:function(t,e,n,i,r,a,o){var s=this._api.getWidth(),l=this._api.getHeight();e=e||t.get("position");var h=r.getSize(),u=t.get("align"),c=t.get("verticalAlign"),d=o&&o.getBoundingRect().clone();if(o&&d.applyTransform(o.transform),"function"==typeof e&&(e=e([n,i],a,r.el,d,{viewSize:[s,l],contentSize:h.slice()})),O(e))n=Uv(e[0],s),i=Uv(e[1],l);else if(N(e)){e.width=h[0],e.height=h[1];var f=Fl(e,{width:s,height:l});n=f.x,i=f.y,c=u=null}else if("string"==typeof e&&o){n=(p=function(t,e,n){var i=n[0],r=n[1],a=0,o=0,s=e.width,l=e.height;switch(t){case"inside":a=e.x+s/2-i/2,o=e.y+l/2-r/2;break;case"top":a=e.x+s/2-i/2,o=e.y-r-5;break;case"bottom":a=e.x+s/2-i/2,o=e.y+l+5;break;case"left":a=e.x-i-5,o=e.y+l/2-r/2;break;case"right":a=e.x+s+5,o=e.y+l/2-r/2}return[a,o]}(e,d,h))[0],i=p[1]}else{var p;n=(p=function(t,e,n,i,r,a,o){var s=n.getOuterSize(),l=s.width,h=s.height;null!=a&&(i<t+l+a?t-=l+a:t+=a);null!=o&&(r<e+h+o?e-=h+o:e+=o);return[t,e]}(n,i,r,s,l,u?null:20,c?null:20))[0],i=p[1]}u&&(n-=qv(u)?h[0]/2:"right"===u?h[0]:0),c&&(i-=qv(c)?h[1]/2:"bottom"===c?h[1]:0),t.get("confine")&&(n=(p=function(t,e,n,i,r){var a=n.getOuterSize(),o=a.width,s=a.height;return t=Math.min(t+o,i)-o,e=Math.min(e+s,r)-s,t=Math.max(t,0),e=Math.max(e,0),[t,e]}(n,i,r,s,l))[0],i=p[1]);r.moveTo(n,i)},_updateContentNotChangedOnAxis:function(i){var t=this._lastDataByCoordSys,o=!!t&&t.length===i.length;return o&&Zv(t,function(t,e){var n=t.dataByAxis||{},a=(i[e]||{}).dataByAxis||[];(o&=n.length===a.length)&&Zv(n,function(t,e){var n=a[e]||{},i=t.seriesDataIndices||[],r=n.seriesDataIndices||[];(o&=t.value===n.value&&t.axisType===n.axisType&&t.axisId===n.axisId&&i.length===r.length)&&Zv(i,function(t,e){var n=r[e];o&=t.seriesIndex===n.seriesIndex&&t.dataIndex===n.dataIndex})})}),this._lastDataByCoordSys=i,!!o},_hide:function(t){this._lastDataByCoordSys=null,t({type:"hideTip",from:this.uid})},dispose:function(t,e){v.node||(this._tooltipContent.hide(),xv("itemTooltip",e))}}),zd({type:"showTip",event:"showTip",update:"tooltip:manuallyShowTip"},function(){}),zd({type:"hideTip",event:"hideTip",update:"tooltip:manuallyHideTip"},function(){});var $v=Fd({type:"legend.plain",dependencies:["series"],layoutMode:{type:"box",ignoreSize:!0},init:function(t,e,n){this.mergeDefaultAndTheme(t,n),t.selected=t.selected||{}},mergeOption:function(t){$v.superCall(this,"mergeOption",t)},optionUpdated:function(){this._updateData(this.ecModel);var t=this._data;if(t[0]&&"single"===this.get("selectedMode")){for(var e=!1,n=0;n<t.length;n++){var i=t[n].get("name");if(this.isSelected(i)){this.select(i),e=!0;break}}e||this.select(t[0].get("name"))}},_updateData:function(a){var o=[],s=[];a.eachRawSeries(function(t){var e,n=t.name;if(s.push(n),t.legendDataProvider){var i=t.legendDataProvider(),r=i.mapArray(i.getName);a.isSeriesFiltered(t)||(s=s.concat(r)),r.length?o=o.concat(r):e=!0}else e=!0;e&&wr(t)&&o.push(t.name)}),this._availableNames=s;var t=D(this.get("data")||o,function(t){return"string"!=typeof t&&"number"!=typeof t||(t={name:t}),new Ks(t,this,this.ecModel)},this);this._data=t},getData:function(){return this._data},select:function(t){var e=this.option.selected;"single"===this.get("selectedMode")&&A(this._data,function(t){e[t.get("name")]=!1});e[t]=!0},unSelect:function(t){"single"!==this.get("selectedMode")&&(this.option.selected[t]=!1)},toggleSelected:function(t){var e=this.option.selected;e.hasOwnProperty(t)||(e[t]=!0),this[e[t]?"unSelect":"select"](t)},isSelected:function(t){var e=this.option.selected;return!(e.hasOwnProperty(t)&&!e[t])&&0<=x(this._availableNames,t)},defaultOption:{zlevel:0,z:4,show:!0,orient:"horizontal",left:"center",top:0,align:"auto",backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderRadius:0,borderWidth:0,padding:5,itemGap:10,itemWidth:25,itemHeight:14,inactiveColor:"#ccc",textStyle:{color:"#333"},selectedMode:!0,tooltip:{show:!1}}});function Kv(t,e,n){var r,a={},o="toggleSelected"===t;return n.eachComponent("legend",function(i){o&&null!=r?i[r?"select":"unSelect"](e.name):(i[t](e.name),r=i.isSelected(e.name)),A(i.getData(),function(t){var e=t.get("name");if("\n"!==e&&""!==e){var n=i.isSelected(e);a.hasOwnProperty(e)?a[e]=a[e]&&n:a[e]=n}})}),{name:e.name,selected:a}}function Qv(t,e){var n=wl(e.get("padding")),i=e.getItemStyle(["color","opacity"]);return i.fill=e.get("backgroundColor"),t=new No({shape:{x:t.x-n[3],y:t.y-n[0],width:t.width+n[1]+n[3],height:t.height+n[0]+n[2],r:e.get("borderRadius")},style:i,silent:!0,z2:-1})}zd("legendToggleSelect","legendselectchanged",P(Kv,"toggleSelected")),zd("legendSelect","legendselected",P(Kv,"select")),zd("legendUnSelect","legendunselected",P(Kv,"unSelect"));var Jv=P,ty=A,ey=yn,ny=Vd({type:"legend.plain",newlineDisabled:!1,init:function(){this.group.add(this._contentGroup=new ey),this._backgroundEl,this._isFirstRender=!0},getContentGroup:function(){return this._contentGroup},render:function(t,e,n){var i=this._isFirstRender;if(this._isFirstRender=!1,this.resetInner(),t.get("show",!0)){var r=t.get("align");r&&"auto"!==r||(r="right"===t.get("left")&&"vertical"===t.get("orient")?"right":"left"),this.renderInner(r,t,e,n);var a=t.getBoxLayoutParams(),o={width:n.getWidth(),height:n.getHeight()},s=t.get("padding"),l=Fl(a,o,s),h=this.layoutInner(t,r,l,i),u=Fl(T({width:h.width,height:h.height},a),o,s);this.group.attr("position",[u.x-h.x,u.y-h.y]),this.group.add(this._backgroundEl=Qv(h,t))}},resetInner:function(){this.getContentGroup().removeAll(),this._backgroundEl&&this.group.remove(this._backgroundEl)},renderInner:function(l,h,u,c){var d=this.getContentGroup(),f=Q(),p=h.get("selectedMode"),g=[];u.eachRawSeries(function(t){t.get("legendHoverLink")||g.push(t.id)}),ty(h.getData(),function(r,a){var o=r.get("name");if(this.newlineDisabled||""!==o&&"\n"!==o){var t=u.getSeriesByName(o)[0];if(!f.get(o))if(t){var e=t.getData(),n=e.getVisual("color");"function"==typeof n&&(n=n(t.getDataParams(0)));var i=e.getVisual("legendSymbol")||"roundRect",s=e.getVisual("symbol");this._createItem(o,a,r,h,i,s,l,n,p).on("click",Jv(iy,o,c)).on("mouseover",Jv(ry,t.name,null,c,g)).on("mouseout",Jv(ay,t.name,null,c,g)),f.set(o,!0)}else u.eachRawSeries(function(t){if(!f.get(o)&&t.legendDataProvider){var e=t.legendDataProvider(),n=e.indexOfName(o);if(n<0)return;var i=e.getItemVisual(n,"color");this._createItem(o,a,r,h,"roundRect",null,l,i,p).on("click",Jv(iy,o,c)).on("mouseover",Jv(ry,null,o,c,g)).on("mouseout",Jv(ay,null,o,c,g)),f.set(o,!0)}},this)}else d.add(new ey({newline:!0}))},this)},_createItem:function(t,e,n,i,r,a,o,s,l){var h=i.get("itemWidth"),u=i.get("itemHeight"),c=i.get("inactiveColor"),d=i.get("symbolKeepAspect"),f=i.isSelected(t),p=new ey,g=n.getModel("textStyle"),m=n.get("icon"),v=n.getModel("tooltip"),y=v.parentModel;if(r=m||r,p.add(Ap(r,0,0,h,u,f?s:c,null==d||d)),!m&&a&&(a!==r||"none"===a)){var _=.8*u;"none"===a&&(a="circle"),p.add(Ap(a,(h-_)/2,(u-_)/2,_,_,f?s:c,null==d||d))}var x="left"===o?h+5:-5,w=o,b=i.get("formatter"),S=t;"string"==typeof b&&b?S=b.replace("{name}",null!=t?t:""):"function"==typeof b&&(S=b(t)),p.add(new wo({style:As({},g,{text:S,x:x,y:u/2,textFill:f?g.getTextColor():c,textAlign:w,textVerticalAlign:"middle"})}));var M=new No({shape:p.getBoundingRect(),invisible:!0,tooltip:v.get("show")?I({content:t,formatter:y.get("formatter",!0)||function(){return t},formatterParams:{componentType:"legend",legendIndex:i.componentIndex,name:t,$vars:["name"]}},v.option):null});return p.add(M),p.eachChild(function(t){t.silent=!0}),M.silent=!l,this.getContentGroup().add(p),Ss(p),p.__legendDataIndex=e,p},layoutInner:function(t,e,n){var i=this.getContentGroup();Bl(t.get("orient"),i,t.get("itemGap"),n.width,n.height);var r=i.getBoundingRect();return i.attr("position",[-r.x,-r.y]),this.group.getBoundingRect()},remove:function(){this.getContentGroup().removeAll(),this._isFirstRender=!0}});function iy(t,e){e.dispatchAction({type:"legendToggleSelect",name:t})}function ry(t,e,n,i){var r=n.getZr().storage.getDisplayList()[0];r&&r.useHoverLayer||n.dispatchAction({type:"highlight",seriesName:t,name:e,excludeSeriesId:i})}function ay(t,e,n,i){var r=n.getZr().storage.getDisplayList()[0];r&&r.useHoverLayer||n.dispatchAction({type:"downplay",seriesName:t,name:e,excludeSeriesId:i})}Od(function(t){var n=t.findComponents({mainType:"legend"});n&&n.length&&t.filterSeries(function(t){for(var e=0;e<n.length;e++)if(!n[e].isSelected(t.name))return!1;return!0})}),jl.registerSubTypeDefaulter("legend",function(){return"plain"});var oy=$v.extend({type:"legend.scroll",setScrollDataIndex:function(t){this.option.scrollDataIndex=t},defaultOption:{scrollDataIndex:0,pageButtonItemGap:5,pageButtonGap:null,pageButtonPosition:"end",pageFormatter:"{current}/{total}",pageIcons:{horizontal:["M0,0L12,-10L12,10z","M0,0L-12,-10L-12,10z"],vertical:["M0,0L20,0L10,-20z","M0,0L20,0L10,20z"]},pageIconColor:"#2f4554",pageIconInactiveColor:"#aaa",pageIconSize:15,pageTextStyle:{color:"#333"},animationDurationUpdate:800},init:function(t,e,n,i){var r=Wl(t);oy.superCall(this,"init",t,e,n,i),sy(this,t,r)},mergeOption:function(t,e){oy.superCall(this,"mergeOption",t,e),sy(this,this.option,t)},getOrient:function(){return"vertical"===this.get("orient")?{index:1,name:"vertical"}:{index:0,name:"horizontal"}}});function sy(t,e,n){var i=[1,1];i[t.getOrient().index]=0,Hl(e,n,{type:"box",ignoreSize:i})}var ly=yn,hy=["width","height"],uy=["x","y"],cy=ny.extend({type:"legend.scroll",newlineDisabled:!0,init:function(){cy.superCall(this,"init"),this._currentIndex=0,this.group.add(this._containerGroup=new ly),this._containerGroup.add(this.getContentGroup()),this.group.add(this._controllerGroup=new ly),this._showController},resetInner:function(){cy.superCall(this,"resetInner"),this._controllerGroup.removeAll(),this._containerGroup.removeClipPath(),this._containerGroup.__rectSize=null},renderInner:function(t,r,e,a){var o=this;cy.superCall(this,"renderInner",t,r,e,a);var s=this._controllerGroup,l=r.get("pageIconSize",!0);O(l)||(l=[l,l]),i("pagePrev",0);var n=r.getModel("pageTextStyle");function i(t,e){var n=t+"DataIndex",i=Gs(r.get("pageIcons",!0)[r.getOrient().name][e],{onclick:k(o._pageGo,o,n,r,a)},{x:-l[0]/2,y:-l[1]/2,width:l[0],height:l[1]});i.name=t,s.add(i)}s.add(new wo({name:"pageText",style:{textFill:n.getTextColor(),font:n.getFont(),textVerticalAlign:"middle",textAlign:"center"},silent:!0})),i("pageNext",1)},layoutInner:function(t,e,n,i){var r=this.getContentGroup(),a=this._containerGroup,o=this._controllerGroup,s=t.getOrient().index,l=hy[s],h=hy[1-s],u=uy[1-s];Bl(t.get("orient"),r,t.get("itemGap"),s?n.width:null,s?null:n.height),Bl("horizontal",o,t.get("pageButtonItemGap",!0));var c=r.getBoundingRect(),d=o.getBoundingRect(),f=this._showController=c[l]>n[l],p=[-c.x,-c.y];i||(p[s]=r.position[s]);var g=[0,0],m=[-d.x,-d.y],v=W(t.get("pageButtonGap",!0),t.get("itemGap",!0));f&&("end"===t.get("pageButtonPosition",!0)?m[s]+=n[l]-d[l]:g[s]+=d[l]+v);m[1-s]+=c[h]/2-d[h]/2,r.attr("position",p),a.attr("position",g),o.attr("position",m);var y=this.group.getBoundingRect();if((y={x:0,y:0})[l]=f?n[l]:c[l],y[h]=Math.max(c[h],d[h]),y[u]=Math.min(0,d[u]+m[1-s]),a.__rectSize=n[l],f){var _={x:0,y:0};_[l]=Math.max(n[l]-d[l]-v,0),_[h]=y[h],a.setClipPath(new No({shape:_})),a.__rectSize=_[l]}else o.eachChild(function(t){t.attr({invisible:!0,silent:!0})});var x=this._getPageInfo(t);return null!=x.pageIndex&&Ns(r,{position:x.contentPosition},f&&t),this._updatePageInfoView(t,x),y},_pageGo:function(t,e,n){var i=this._getPageInfo(e)[t];null!=i&&n.dispatchAction({type:"legendScroll",scrollDataIndex:i,legendId:e.id})},_updatePageInfoView:function(i,r){var a=this._controllerGroup;A(["pagePrev","pageNext"],function(t){var e=null!=r[t+"DataIndex"],n=a.childOfName(t);n&&(n.setStyle("fill",e?i.get("pageIconColor",!0):i.get("pageIconInactiveColor",!0)),n.cursor=e?"pointer":"default")});var t=a.childOfName("pageText"),e=i.get("pageFormatter"),n=r.pageIndex,o=null!=n?n+1:0,s=r.pageCount;t&&e&&t.setStyle("text",E(e)?e.replace("{current}",o).replace("{total}",s):e({current:o,total:s}))},_getPageInfo:function(t){var e=t.get("scrollDataIndex",!0),n=this.getContentGroup(),i=this._containerGroup.__rectSize,r=t.getOrient().index,a=hy[r],o=uy[r],s=this._findTargetItemIndex(e),l=n.children(),h=l[s],u=l.length,c=u?1:0,d={contentPosition:n.position.slice(),pageCount:c,pageIndex:c-1,pagePrevDataIndex:null,pageNextDataIndex:null};if(!h)return d;var f=y(h);d.contentPosition[r]=-f.s;for(var p=s+1,g=f,m=f,v=null;p<=u;++p)(!(v=y(l[p]))&&m.e>g.s+i||v&&!_(v,g.s))&&(g=m.i>g.i?m:v)&&(null==d.pageNextDataIndex&&(d.pageNextDataIndex=g.i),++d.pageCount),m=v;for(p=s-1,g=f,m=f,v=null;-1<=p;--p)(v=y(l[p]))&&_(m,v.s)||!(g.i<m.i)||(m=g,null==d.pagePrevDataIndex&&(d.pagePrevDataIndex=g.i),++d.pageCount,++d.pageIndex),g=v;return d;function y(t){if(t){var e=t.getBoundingRect(),n=e[o]+t.position[r];return{s:n,e:n+e[a],i:t.__legendDataIndex}}}function _(t,e){return t.e>=e&&t.s<=e+i}},_findTargetItemIndex:function(i){var r,a,t=this.getContentGroup();return this._showController&&t.eachChild(function(t,e){var n=t.__legendDataIndex;null==a&&null!=n&&(a=e),n===i&&(r=e)}),null!=r?r:a}});zd("legendScroll","legendscroll",function(t,e){var n=t.scrollDataIndex;null!=n&&e.eachComponent({mainType:"legend",subType:"scroll",query:t},function(t){t.setScrollDataIndex(n)})}),Fd({type:"title",layoutMode:{type:"box",ignoreSize:!0},defaultOption:{zlevel:0,z:6,show:!0,text:"",target:"blank",subtext:"",subtarget:"blank",left:0,top:0,backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderWidth:0,padding:5,itemGap:10,textStyle:{fontSize:18,fontWeight:"bolder",color:"#333"},subtextStyle:{color:"#aaa"}}}),Vd({type:"title",render:function(t,e,n){if(this.group.removeAll(),t.get("show")){var i=this.group,r=t.getModel("textStyle"),a=t.getModel("subtextStyle"),o=t.get("textAlign"),s=W(t.get("textBaseline"),t.get("textVerticalAlign")),l=new wo({style:As({},r,{text:t.get("text"),textFill:r.getTextColor()},{disableBox:!0}),z2:10}),h=l.getBoundingRect(),u=t.get("subtext"),c=new wo({style:As({},a,{text:u,textFill:a.getTextColor(),y:h.height+t.get("itemGap"),textVerticalAlign:"top"},{disableBox:!0}),z2:10}),d=t.get("link"),f=t.get("sublink"),p=t.get("triggerEvent",!0);l.silent=!d&&!p,c.silent=!f&&!p,d&&l.on("click",function(){window.open(d,"_"+t.get("target"))}),f&&c.on("click",function(){window.open(f,"_"+t.get("subtarget"))}),l.eventData=c.eventData=p?{componentType:"title",componentIndex:t.componentIndex}:null,i.add(l),u&&i.add(c);var g=i.getBoundingRect(),m=t.getBoxLayoutParams();m.width=g.width,m.height=g.height;var v=Fl(m,{width:n.getWidth(),height:n.getHeight()},t.get("padding"));o||("middle"===(o=t.get("left")||t.get("right"))&&(o="center"),"right"===o?v.x+=v.width:"center"===o&&(v.x+=v.width/2)),s||("center"===(s=t.get("top")||t.get("bottom"))&&(s="middle"),"bottom"===s?v.y+=v.height:"middle"===s&&(v.y+=v.height/2),s=s||"top"),i.attr("position",[v.x,v.y]);var y={textAlign:o,textVerticalAlign:s};l.setStyle(y),c.setStyle(y),g=i.getBoundingRect();var _=v.margin,x=t.getItemStyle(["color","opacity"]);x.fill=t.get("backgroundColor");var w=new No({shape:{x:g.x-_[3],y:g.y-_[0],width:g.width+_[1]+_[3],height:g.height+_[0]+_[2],r:t.get("borderRadius")},style:x,subPixelOptimize:!0,silent:!0});i.add(w)}}});var dy=_l,fy=Ml;function py(t){mr(t,"label",["show"])}var gy=Fd({type:"marker",dependencies:["series","grid","polar","geo"],init:function(t,e,n,i){this.mergeDefaultAndTheme(t,n),this.mergeOption(t,n,i.createdBySelf,!0)},isAnimationEnabled:function(){if(v.node)return!1;var t=this.__hostSeries;return this.getShallow("animation")&&t&&t.isAnimationEnabled()},mergeOption:function(t,i,e,r){var a=this.constructor,o=this.mainType+"Model";e||i.eachSeries(function(t){var e=t.get(this.mainType,!0),n=t[o];e&&e.data?(n?n.mergeOption(e,i,!0):(r&&py(e),A(e.data,function(t){t instanceof Array?(py(t[0]),py(t[1])):py(t)}),I(n=new a(e,this,i),{mainType:this.mainType,seriesIndex:t.seriesIndex,name:t.name,createdBySelf:!0}),n.__hostSeries=t),t[o]=n):t[o]=null},this)},formatTooltip:function(t){var e=this.getData(),n=this.getRawValue(t),i=O(n)?D(n,dy).join(", "):dy(n),r=e.getName(t),a=fy(this.name);return null==n&&!r||(a+="<br />"),r&&(a+=fy(r),null!=n&&(a+=" : ")),null!=n&&(a+=fy(i)),a},getData:function(){return this._data},setData:function(t){this._data=t}});S(gy,lu),gy.extend({type:"markPoint",defaultOption:{zlevel:0,z:5,symbol:"pin",symbolSize:50,tooltip:{trigger:"item"},label:{show:!0,position:"inside"},itemStyle:{borderWidth:2},emphasis:{label:{show:!0}}}});var my=x;function vy(t,e,n,i,r,a){var o=[],s=bf(e,i)?e.getCalculationInfo("stackResultDimension"):i,l=My(e,s,t),h=e.indicesOfNearest(s,l)[0];o[r]=e.get(n,h),o[a]=e.get(i,h);var u=sl(e.get(i,h));return 0<=(u=Math.min(u,20))&&(o[a]=+o[a].toFixed(u)),o}var yy=P,_y={min:yy(vy,"min"),max:yy(vy,"max"),average:yy(vy,"average")};function xy(t,e){var n=t.getData(),i=t.coordinateSystem;if(e&&!function(t){return!isNaN(parseFloat(t.x))&&!isNaN(parseFloat(t.y))}(e)&&!O(e.coord)&&i){var r=i.dimensions,a=wy(e,n,i,t);if((e=b(e)).type&&_y[e.type]&&a.baseAxis&&a.valueAxis){var o=my(r,a.baseAxis.dim),s=my(r,a.valueAxis.dim);e.coord=_y[e.type](n,a.baseDataDim,a.valueDataDim,o,s),e.value=e.coord[s]}else{for(var l=[null!=e.xAxis?e.xAxis:e.radiusAxis,null!=e.yAxis?e.yAxis:e.angleAxis],h=0;h<2;h++)_y[l[h]]&&(l[h]=My(n,n.mapDimension(r[h]),l[h]));e.coord=l}}return e}function wy(t,e,n,i){var r={};return null!=t.valueIndex||null!=t.valueDim?(r.valueDataDim=null!=t.valueIndex?e.getDimension(t.valueIndex):t.valueDim,r.valueAxis=n.getAxis(function(t,e){var n=t.getData(),i=n.dimensions;e=n.getDimension(e);for(var r=0;r<i.length;r++){var a=n.getDimensionInfo(i[r]);if(a.name===e)return a.coordDim}}(i,r.valueDataDim)),r.baseAxis=n.getOtherAxis(r.valueAxis),r.baseDataDim=e.mapDimension(r.baseAxis.dim)):(r.baseAxis=i.getBaseAxis(),r.valueAxis=n.getOtherAxis(r.baseAxis),r.baseDataDim=e.mapDimension(r.baseAxis.dim),r.valueDataDim=e.mapDimension(r.valueAxis.dim)),r}function by(t,e){return!(t&&t.containData&&e.coord&&!function(t){return!(isNaN(parseFloat(t.x))&&isNaN(parseFloat(t.y)))}(e))||t.containData(e.coord)}function Sy(t,e,n,i){return i<2?t.coord&&t.coord[i]:t.value}function My(t,e,n){if("average"!==n)return"median"===n?t.getMedian(e):t.getDataExtent(e,!0)["max"===n?1:0];var i=0,r=0;return t.each(e,function(t,e){isNaN(t)||(i+=t,r++)}),i/r}var Iy=Vd({type:"marker",init:function(){this.markerGroupMap=Q()},render:function(t,n,i){var e=this.markerGroupMap;e.each(function(t){t.__keep=!1});var r=this.type+"Model";n.eachSeries(function(t){var e=t[r];e&&this.renderSeries(t,e,n,i)},this),e.each(function(t){t.__keep||this.group.remove(t.group)},this)},renderSeries:function(){}});function Cy(s,l,h){var u=l.coordinateSystem;s.each(function(t){var e,n=s.getItemModel(t),i=rl(n.get("x"),h.getWidth()),r=rl(n.get("y"),h.getHeight());if(isNaN(i)||isNaN(r)){if(l.getMarkerPosition)e=l.getMarkerPosition(s.getValues(s.dimensions,t));else if(u){var a=s.get(u.dimensions[0],t),o=s.get(u.dimensions[1],t);e=u.dataToPoint([a,o])}}else e=[i,r];isNaN(i)||(e[0]=i),isNaN(r)||(e[1]=r),s.setItemLayout(t,e)})}Iy.extend({type:"markPoint",updateTransform:function(t,e,n){e.eachSeries(function(t){var e=t.markPointModel;e&&(Cy(e.getData(),t,n),this.markerGroupMap.get(t.id).updateLayout(e))},this)},renderSeries:function(t,l,e,n){var i=t.coordinateSystem,r=t.id,h=t.getData(),a=this.markerGroupMap,o=a.get(r)||a.set(r,new hg),u=function(t,e,n){var i;i=t?D(t&&t.dimensions,function(t){return T({name:t},e.getData().getDimensionInfo(e.getData().mapDimension(t))||{})}):[{name:"value",type:"float"}];var r=new af(i,n),a=D(n.get("data"),P(xy,e));t&&(a=C(a,P(by,t)));return r.initData(a,null,t?Sy:function(t){return t.value}),r}(i,t,l);l.setData(u),Cy(l.getData(),t,n),u.each(function(t){var e=u.getItemModel(t),n=e.getShallow("symbol"),i=e.getShallow("symbolSize"),r=z(n),a=z(i);if(r||a){var o=l.getRawValue(t),s=l.getDataParams(t);r&&(n=n(o,s)),a&&(i=i(o,s))}u.setItemVisual(t,{symbol:n,symbolSize:i,color:e.get("itemStyle.color")||h.getVisual("color")})}),o.updateData(u),this.group.add(o.group),u.eachItemGraphicEl(function(t){t.traverse(function(t){t.dataModel=l})}),o.__keep=!0,o.group.silent=l.get("silent")||t.get("silent")}}),Ld(function(t){t.markPoint=t.markPoint||{}}),gy.extend({type:"markLine",defaultOption:{zlevel:0,z:5,symbol:["circle","arrow"],symbolSize:[8,16],precision:2,tooltip:{trigger:"item"},label:{show:!0,position:"end"},lineStyle:{type:"dashed"},emphasis:{label:{show:!0},lineStyle:{width:3}},animationEasing:"linear"}});var Ty=Bo.prototype,Ay=Wo.prototype;function Dy(t){return isNaN(+t.cpx1)||isNaN(+t.cpy1)}var ky=is({type:"ec-line",style:{stroke:"#000",fill:null},shape:{x1:0,y1:0,x2:0,y2:0,percent:1,cpx1:null,cpy1:null},buildPath:function(t,e){this[Dy(e)?"_buildPathLine":"_buildPathCurve"](t,e)},_buildPathLine:Ty.buildPath,_buildPathCurve:Ay.buildPath,pointAt:function(t){return this[Dy(this.shape)?"_pointAtLine":"_pointAtCurve"](t)},_pointAtLine:Ty.pointAt,_pointAtCurve:Ay.pointAt,tangentAt:function(t){var e=this.shape,n=Dy(e)?[e.x2-e.x1,e.y2-e.y1]:this._tangentAtCurve(t);return ft(n,n)},_tangentAtCurve:Ay.tangentAt}),Py=["fromSymbol","toSymbol"];function Ly(t){return"_"+t+"Type"}function Oy(t,e,n){var i=e.getItemVisual(n,"color"),r=e.getItemVisual(n,t),a=e.getItemVisual(n,t+"Size");if(r&&"none"!==r){O(a)||(a=[a,a]);var o=Ap(r,-a[0]/2,-a[1]/2,a[0],a[1],i);return o.name=t,o}}function zy(t,e){t.x1=e[0][0],t.y1=e[0][1],t.x2=e[1][0],t.y2=e[1][1],t.percent=1;var n=e[2];n?(t.cpx1=n[0],t.cpy1=n[1]):(t.cpx1=NaN,t.cpy1=NaN)}function Ey(t,e,n){yn.call(this),this._createLine(t,e,n)}var Ny=Ey.prototype;function Ry(t){this._ctor=t||Ey,this.group=new yn}Ny.beforeUpdate=function(){var t=this.childOfName("fromSymbol"),e=this.childOfName("toSymbol"),n=this.childOfName("label");if(t||e||!n.ignore){for(var i=1,r=this.parent;r;)r.scale&&(i/=r.scale[0]),r=r.parent;var a=this.childOfName("line");if(this.__dirty||a.__dirty){var o=a.shape.percent,s=a.pointAt(0),l=a.pointAt(o),h=st([],l,s);if(ft(h,h),t){t.attr("position",s);var u=a.tangentAt(0);t.attr("rotation",Math.PI/2-Math.atan2(u[1],u[0])),t.attr("scale",[i*o,i*o])}if(e){e.attr("position",l);u=a.tangentAt(1);e.attr("rotation",-Math.PI/2-Math.atan2(u[1],u[0])),e.attr("scale",[i*o,i*o])}if(!n.ignore){var c,d,f;n.attr("position",l);var p=5*i;if("end"===n.__position)c=[h[0]*p+l[0],h[1]*p+l[1]],d=.8<h[0]?"left":h[0]<-.8?"right":"center",f=.8<h[1]?"top":h[1]<-.8?"bottom":"middle";else if("middle"===n.__position){var g=o/2,m=[(u=a.tangentAt(g))[1],-u[0]],v=a.pointAt(g);0<m[1]&&(m[0]=-m[0],m[1]=-m[1]),c=[v[0]+m[0]*p,v[1]+m[1]*p],d="center",f="bottom";var y=-Math.atan2(u[1],u[0]);l[0]<s[0]&&(y=Math.PI+y),n.attr("rotation",y)}else c=[-h[0]*p+s[0],-h[1]*p+s[1]],d=.8<h[0]?"right":h[0]<-.8?"left":"center",f=.8<h[1]?"bottom":h[1]<-.8?"top":"middle";n.attr({style:{textVerticalAlign:n.__verticalAlign||f,textAlign:n.__textAlign||d},position:c,scale:[i,i]})}}}},Ny._createLine=function(n,i,t){var e=n.hostModel,r=function(t){var e=new ky({name:"line",subPixelOptimize:!0});return zy(e.shape,t),e}(n.getItemLayout(i));r.shape.percent=0,Rs(r,{shape:{percent:1}},e,i),this.add(r);var a=new wo({name:"label",lineLabelOriginalOpacity:1});this.add(a),A(Py,function(t){var e=Oy(t,n,i);this.add(e),this[Ly(t)]=n.getItemVisual(i,t)},this),this._updateCommonStl(n,i,t)},Ny.updateData=function(r,a,t){var e=r.hostModel,n=this.childOfName("line"),i=r.getItemLayout(a),o={shape:{}};zy(o.shape,i),Ns(n,o,e,a),A(Py,function(t){var e=r.getItemVisual(a,t),n=Ly(t);if(this[n]!==e){this.remove(this.childOfName(t));var i=Oy(t,r,a);this.add(i)}this[n]=e},this),this._updateCommonStl(r,a,t)},Ny._updateCommonStl=function(t,e,n){var i=t.hostModel,r=this.childOfName("line"),a=n&&n.lineStyle,o=n&&n.hoverLineStyle,s=n&&n.labelModel,l=n&&n.hoverLabelModel;if(!n||t.hasItemOption){var h=t.getItemModel(e);a=h.getModel("lineStyle").getLineStyle(),o=h.getModel("emphasis.lineStyle").getLineStyle(),s=h.getModel("label"),l=h.getModel("emphasis.label")}var u=t.getItemVisual(e,"color"),c=G(t.getItemVisual(e,"opacity"),a.opacity,1);r.useStyle(T({strokeNoScale:!0,fill:"none",stroke:u,opacity:c},a)),r.hoverStyle=o,A(Py,function(t){var e=this.childOfName(t);e&&(e.setColor(u),e.setStyle({opacity:c}))},this);var d,f,p=s.getShallow("show"),g=l.getShallow("show"),m=this.childOfName("label");if((p||g)&&(d=u||"#000",null==(f=i.getFormattedLabel(e,"normal",t.dataType)))){var v=i.getRawValue(e);f=null==v?t.getName(e):isFinite(v)?al(v):v}var y=p?f:null,_=g?W(i.getFormattedLabel(e,"emphasis",t.dataType),f):null,x=m.style;null==y&&null==_||(As(m.style,s,{text:y},{autoColor:d}),m.__textAlign=x.textAlign,m.__verticalAlign=x.textVerticalAlign,m.__position=s.get("position")||"middle"),m.hoverStyle=null!=_?{text:_,textFill:l.getTextColor(!0),fontStyle:l.getShallow("fontStyle"),fontWeight:l.getShallow("fontWeight"),fontSize:l.getShallow("fontSize"),fontFamily:l.getShallow("fontFamily")}:{text:null},m.ignore=!p&&!g,Ss(this)},Ny.highlight=function(){this.trigger("emphasis")},Ny.downplay=function(){this.trigger("normal")},Ny.updateLayout=function(t,e){this.setLinePoints(t.getItemLayout(e))},Ny.setLinePoints=function(t){var e=this.childOfName("line");zy(e.shape,t),e.dirty()},w(Ey,yn);var By=Ry.prototype;function Fy(t){var e=t.hostModel;return{lineStyle:e.getModel("lineStyle").getLineStyle(),hoverLineStyle:e.getModel("emphasis.lineStyle").getLineStyle(),labelModel:e.getModel("label"),hoverLabelModel:e.getModel("emphasis.label")}}function Vy(t){return isNaN(t[0])||isNaN(t[1])}function Hy(t){return!Vy(t[0])&&!Vy(t[1])}By.isPersistent=function(){return!0},By.updateData=function(n){var i=this,e=i.group,r=i._lineData;i._lineData=n,r||e.removeAll();var a=Fy(n);n.diff(r).add(function(t){!function(t,e,n,i){if(!Hy(e.getItemLayout(n)))return;var r=new t._ctor(e,n,i);e.setItemGraphicEl(n,r),t.group.add(r)}(i,n,t,a)}).update(function(t,e){!function(t,e,n,i,r,a){var o=e.getItemGraphicEl(i);if(!Hy(n.getItemLayout(r)))return t.group.remove(o);o?o.updateData(n,r,a):o=new t._ctor(n,r,a);n.setItemGraphicEl(r,o),t.group.add(o)}(i,r,n,e,t,a)}).remove(function(t){e.remove(r.getItemGraphicEl(t))}).execute()},By.updateLayout=function(){var n=this._lineData;n&&n.eachItemGraphicEl(function(t,e){t.updateLayout(n,e)},this)},By.incrementalPrepareUpdate=function(t){this._seriesScope=Fy(t),this._lineData=null,this.group.removeAll()},By.incrementalUpdate=function(t,e){function n(t){t.isGroup||(t.incremental=t.useHoverLayer=!0)}for(var i=t.start;i<t.end;i++){if(Hy(e.getItemLayout(i))){var r=new this._ctor(e,i,this._seriesScope);r.traverse(n),this.group.add(r),e.setItemGraphicEl(i,r)}}},By.remove=function(){this._clearIncremental(),this._incremental=null,this.group.removeAll()},By._clearIncremental=function(){var t=this._incremental;t&&t.clearDisplaybles()};function Wy(t,e,n,i){var r=t.getData(),a=i.type;if(!O(i)&&("min"===a||"max"===a||"average"===a||"median"===a||null!=i.xAxis||null!=i.yAxis)){var o,s;if(null!=i.yAxis||null!=i.xAxis)o=e.getAxis(null!=i.yAxis?"y":"x"),s=H(i.yAxis,i.xAxis);else{var l=wy(i,r,e,t);o=l.valueAxis,s=My(r,Sf(r,l.valueDataDim),a)}var h="x"===o.dim?0:1,u=1-h,c=b(i),d={};c.type=null,c.coord=[],d.coord=[],c.coord[u]=-1/0,d.coord[u]=1/0;var f=n.get("precision");0<=f&&"number"==typeof s&&(s=+s.toFixed(Math.min(f,20))),c.coord[h]=d.coord[h]=s,i=[c,d,{type:a,valueIndex:i.valueIndex,value:s}]}return(i=[xy(t,i[0]),xy(t,i[1]),I({},i[2])])[2].type=i[2].type||"",m(i[2],i[0]),m(i[2],i[1]),i}function Gy(t){return!isNaN(t)&&!isFinite(t)}function Zy(t,e,n,i){var r=1-t,a=i.dimensions[t];return Gy(e[r])&&Gy(n[r])&&e[t]===n[t]&&i.getAxis(a).containData(e[t])}function Uy(t,e){if("cartesian2d"===t.type){var n=e[0].coord,i=e[1].coord;if(n&&i&&(Zy(1,n,i,t)||Zy(0,n,i,t)))return!0}return by(t,e[0])&&by(t,e[1])}function Xy(t,e,n,i,r){var a,o=i.coordinateSystem,s=t.getItemModel(e),l=rl(s.get("x"),r.getWidth()),h=rl(s.get("y"),r.getHeight());if(isNaN(l)||isNaN(h)){if(i.getMarkerPosition)a=i.getMarkerPosition(t.getValues(t.dimensions,e));else{var u=o.dimensions,c=t.get(u[0],e),d=t.get(u[1],e);a=o.dataToPoint([c,d])}if("cartesian2d"===o.type){var f=o.getAxis("x"),p=o.getAxis("y");u=o.dimensions;Gy(t.get(u[0],e))?a[0]=f.toGlobalCoord(f.getExtent()[n?0:1]):Gy(t.get(u[1],e))&&(a[1]=p.toGlobalCoord(p.getExtent()[n?0:1]))}isNaN(l)||(a[0]=l),isNaN(h)||(a[1]=h)}else a=[l,h];t.setItemLayout(e,a)}Iy.extend({type:"markLine",updateTransform:function(t,e,a){e.eachSeries(function(e){var t=e.markLineModel;if(t){var n=t.getData(),i=t.__from,r=t.__to;i.each(function(t){Xy(i,t,!0,e,a),Xy(r,t,!1,e,a)}),n.each(function(t){n.setItemLayout(t,[i.getItemLayout(t),r.getItemLayout(t)])}),this.markerGroupMap.get(e.id).updateLayout()}},this)},renderSeries:function(r,n,t,a){var e=r.coordinateSystem,i=r.id,o=r.getData(),s=this.markerGroupMap,l=s.get(i)||s.set(i,new Ry);this.group.add(l.group);var h=function(t,e,n){var i;i=t?D(t&&t.dimensions,function(t){return T({name:t},e.getData().getDimensionInfo(e.getData().mapDimension(t))||{})}):[{name:"value",type:"float"}];var r=new af(i,n),a=new af(i,n),o=new af([],n),s=D(n.get("data"),P(Wy,e,t,n));t&&(s=C(s,P(Uy,t)));var l=t?Sy:function(t){return t.value};return r.initData(D(s,function(t){return t[0]}),null,l),a.initData(D(s,function(t){return t[1]}),null,l),o.initData(D(s,function(t){return t[2]})),o.hasItemOption=!0,{from:r,to:a,line:o}}(e,r,n),u=h.from,c=h.to,d=h.line;n.__from=u,n.__to=c,n.setData(d);var f=n.get("symbol"),p=n.get("symbolSize");function g(t,e,n){var i=t.getItemModel(e);Xy(t,e,n,r,a),t.setItemVisual(e,{symbolSize:i.get("symbolSize")||p[n?0:1],symbol:i.get("symbol",!0)||f[n?0:1],color:i.get("itemStyle.color")||o.getVisual("color")})}O(f)||(f=[f,f]),"number"==typeof p&&(p=[p,p]),h.from.each(function(t){g(u,t,!0),g(c,t,!1)}),d.each(function(t){var e=d.getItemModel(t).get("lineStyle.color");d.setItemVisual(t,{color:e||u.getItemVisual(t,"color")}),d.setItemLayout(t,[u.getItemLayout(t),c.getItemLayout(t)]),d.setItemVisual(t,{fromSymbolSize:u.getItemVisual(t,"symbolSize"),fromSymbol:u.getItemVisual(t,"symbol"),toSymbolSize:c.getItemVisual(t,"symbolSize"),toSymbol:c.getItemVisual(t,"symbol")})}),l.updateData(d),h.line.eachItemGraphicEl(function(t,e){t.traverse(function(t){t.dataModel=n})}),l.__keep=!0,l.group.silent=n.get("silent")||r.get("silent")}}),Ld(function(t){t.markLine=t.markLine||{}}),gy.extend({type:"markArea",defaultOption:{zlevel:0,z:1,tooltip:{trigger:"item"},animation:!1,label:{show:!0,position:"top"},itemStyle:{borderWidth:0},emphasis:{label:{show:!0,position:"top"}}}});function Yy(t,e,n,i){var r=xy(t,i[0]),a=xy(t,i[1]),o=H,s=r.coord,l=a.coord;s[0]=o(s[0],-1/0),s[1]=o(s[1],-1/0),l[0]=o(l[0],1/0),l[1]=o(l[1],1/0);var h=p([{},r,a]);return h.coord=[r.coord,a.coord],h.x0=r.x,h.y0=r.y,h.x1=a.x,h.y1=a.y,h}function jy(t){return!isNaN(t)&&!isFinite(t)}function qy(t,e,n){var i=1-t;return jy(e[i])&&jy(n[i])}function $y(t,e){var n=e.coord[0],i=e.coord[1];return!("cartesian2d"!==t.type||!n||!i||!qy(1,n,i)&&!qy(0,n,i))||(by(t,{coord:n,x:e.x0,y:e.y0})||by(t,{coord:i,x:e.x1,y:e.y1}))}function Ky(t,e,n,i,r){var a,o=i.coordinateSystem,s=t.getItemModel(e),l=rl(s.get(n[0]),r.getWidth()),h=rl(s.get(n[1]),r.getHeight());if(isNaN(l)||isNaN(h)){if(i.getMarkerPosition)a=i.getMarkerPosition(t.getValues(n,e));else{var u=[f=t.get(n[0],e),p=t.get(n[1],e)];o.clampData&&o.clampData(u,u),a=o.dataToPoint(u,!0)}if("cartesian2d"===o.type){var c=o.getAxis("x"),d=o.getAxis("y"),f=t.get(n[0],e),p=t.get(n[1],e);jy(f)?a[0]=c.toGlobalCoord(c.getExtent()["x0"===n[0]?0:1]):jy(p)&&(a[1]=d.toGlobalCoord(d.getExtent()["y0"===n[1]?0:1]))}isNaN(l)||(a[0]=l),isNaN(h)||(a[1]=h)}else a=[l,h];return a}var Qy=[["x0","y0"],["x1","y0"],["x1","y1"],["x0","y1"]];Iy.extend({type:"markArea",updateTransform:function(t,e,r){e.eachSeries(function(n){var t=n.markAreaModel;if(t){var i=t.getData();i.each(function(e){var t=D(Qy,function(t){return Ky(i,e,t,n,r)});i.setItemLayout(e,t),i.getItemGraphicEl(e).setShape("points",t)})}},this)},renderSeries:function(n,o,t,i){var e=n.coordinateSystem,r=n.id,a=n.getData(),s=this.markerGroupMap,l=s.get(r)||s.set(r,{group:new yn});this.group.add(l.group),l.__keep=!0;var h=function(t,n,e){var i,r;r=t?(i=D(t&&t.dimensions,function(t){var e=n.getData();return T({name:t},e.getDimensionInfo(e.mapDimension(t))||{})}),new af(D(["x0","y0","x1","y1"],function(t,e){return{name:t,type:i[e%2].type}}),e)):new af(i=[{name:"value",type:"float"}],e);var a=D(e.get("data"),P(Yy,n,t,e));t&&(a=C(a,P($y,t)));var o=t?function(t,e,n,i){return t.coord[Math.floor(i/2)][i%2]}:function(t){return t.value};return r.initData(a,null,o),r.hasItemOption=!0,r}(e,n,o);o.setData(h),h.each(function(e){h.setItemLayout(e,D(Qy,function(t){return Ky(h,e,t,n,i)})),h.setItemVisual(e,{color:a.getVisual("color")})}),h.diff(l.__data).add(function(t){var e=new Do({shape:{points:h.getItemLayout(t)}});h.setItemGraphicEl(t,e),l.group.add(e)}).update(function(t,e){var n=l.__data.getItemGraphicEl(e);Ns(n,{shape:{points:h.getItemLayout(t)}},o,t),l.group.add(n),h.setItemGraphicEl(t,n)}).remove(function(t){var e=l.__data.getItemGraphicEl(t);l.group.remove(e)}).execute(),h.eachItemGraphicEl(function(t,e){var n=h.getItemModel(e),i=n.getModel("label"),r=n.getModel("emphasis.label"),a=h.getItemVisual(e,"color");t.useStyle(T(n.getModel("itemStyle").getItemStyle(),{fill:Be(a,.4),stroke:a})),t.hoverStyle=n.getModel("emphasis.itemStyle").getItemStyle(),Ts(t.style,t.hoverStyle,i,r,{labelFetcher:o,labelDataIndex:e,defaultText:h.getName(e)||"",isRectText:!0,autoColor:a}),Ss(t,{}),t.dataModel=o}),l.__data=h,l.group.silent=o.get("silent")||n.get("silent")}}),Ld(function(t){t.markArea=t.markArea||{}}),jl.registerSubTypeDefaulter("dataZoom",function(){return"slider"});var Jy=["cartesian2d","polar","singleAxis"];var t_,e_,n_,i_,r_=(e_=["axisIndex","axis","index","id"],n_=D(t_=(t_=["x","y","z","radius","angle","single"]).slice(),Pl),i_=D(e_=(e_||[]).slice(),Pl),function(r,a){A(t_,function(t,e){for(var n={name:t,capital:n_[e]},i=0;i<e_.length;i++)n[e_[i]]=t+i_[i];r.call(a,n)})});function a_(r,a,o){return function(t){var e,n={nodes:[],records:{}};if(a(function(t){n.records[t.name]={}}),!t)return n;for(s(t,n);e=!1,r(i),e;);function i(t){!function(t,e){return 0<=x(e.nodes,t)}(t,n)&&function(t,n){var i=!1;return a(function(e){A(o(t,e)||[],function(t){n.records[e.name][t]&&(i=!0)})}),i}(t,n)&&(s(t,n),e=!0)}return n};function s(t,n){n.nodes.push(t),a(function(e){A(o(t,e)||[],function(t){n.records[e.name][t]=!0})})}}function o_(t,e,n,i,r,a){t=t||0;var o=n[1]-n[0];if(null!=r&&(r=l_(r,[0,o])),null!=a&&(a=Math.max(a,null!=r?r:0)),"all"===i){var s=Math.abs(e[1]-e[0]);r=a=l_(s=l_(s,[0,o]),[r,a]),i=0}e[0]=l_(e[0],n),e[1]=l_(e[1],n);var l=s_(e,i);e[i]+=t;var h=r||0,u=n.slice();l.sign<0?u[0]+=h:u[1]-=h,e[i]=l_(e[i],u);var c=s_(e,i);return null!=r&&(c.sign!==l.sign||c.span<r)&&(e[1-i]=e[i]+l.sign*r),c=s_(e,i),null!=a&&c.span>a&&(e[1-i]=e[i]+c.sign*a),e}function s_(t,e){var n=t[e]-t[1-e];return{span:Math.abs(n),sign:0<n?-1:n<0?1:e?-1:1}}function l_(t,e){return Math.min(null!=e[1]?e[1]:1/0,Math.max(null!=e[0]?e[0]:-1/0,t))}function h_(t,e,n,i){this._dimName=t,this._axisIndex=e,this._valueWindow,this._percentWindow,this._dataExtent,this._minMaxSpan,this.ecModel=i,this._dataZoomModel=n}var u_=A,c_=ol;function d_(t,e){var n=t.getAxisModel(),i=t._percentWindow,r=t._valueWindow;if(i){var a=hl(r,[0,500]);a=Math.min(a,20);var o=e||0===i[0]&&100===i[1];n.setRange(o?null:+r[0].toFixed(a),o?null:+r[1].toFixed(a))}}h_.prototype={constructor:h_,hostedBy:function(t){return this._dataZoomModel===t},getDataValueWindow:function(){return this._valueWindow.slice()},getDataPercentWindow:function(){return this._percentWindow.slice()},getTargetSeriesModels:function(){var i=[],r=this.ecModel;return r.eachSeries(function(t){if(function(t){return 0<=x(Jy,t)}(t.get("coordinateSystem"))){var e=this._dimName,n=r.queryComponents({mainType:e+"Axis",index:t.get(e+"AxisIndex"),id:t.get(e+"AxisId")})[0];this._axisIndex===(n&&n.componentIndex)&&i.push(t)}},this),i},getAxisModel:function(){return this.ecModel.getComponent(this._dimName+"Axis",this._axisIndex)},getOtherAxisModel:function(){var t,e,n,i=this._dimName,r=this.ecModel,a=this.getAxisModel();return t="x"===i||"y"===i?(e="gridIndex","x"===i?"y":"x"):(e="polarIndex","angle"===i?"radius":"angle"),r.eachComponent(t+"Axis",function(t){(t.get(e)||0)===(a.get(e)||0)&&(n=t)}),n},getMinMaxSpan:function(){return b(this._minMaxSpan)},calculateDataWindow:function(r){var a,o=this._dataExtent,s=this.getAxisModel().axis.scale,l=this._dataZoomModel.getRangePropMode(),h=[0,100],u=[],c=[];u_(["start","end"],function(t,e){var n=r[t],i=r[t+"Value"];"percent"===l[e]?(null==n&&(n=h[e]),i=s.parse(il(n,h,o))):(a=!0,n=il(i=null==i?o[e]:s.parse(i),o,h)),c[e]=i,u[e]=n}),c_(c),c_(u);var d=this._minMaxSpan;function t(t,e,n,i,r){var a=r?"Span":"ValueSpan";o_(0,t,n,"all",d["min"+a],d["max"+a]);for(var o=0;o<2;o++)e[o]=il(t[o],n,i,!0),r&&(e[o]=s.parse(e[o]))}return a?t(c,u,o,h,!1):t(u,c,h,o,!0),{valueWindow:c,percentWindow:u}},reset:function(t){if(t===this._dataZoomModel){var e=this.getTargetSeriesModels();this._dataExtent=function(t,e,n){var i=[1/0,-1/0];u_(n,function(t){var n=t.getData();n&&u_(n.mapDimension(e,!0),function(t){var e=n.getApproximateExtent(t);e[0]<i[0]&&(i[0]=e[0]),e[1]>i[1]&&(i[1]=e[1])})}),i[1]<i[0]&&(i=[NaN,NaN]);return function(t,e){var n=t.getAxisModel(),i=n.getMin(!0),r="category"===n.get("type"),a=r&&n.getCategories().length;null!=i&&"dataMin"!==i&&"function"!=typeof i?e[0]=i:r&&(e[0]=0<a?0:NaN);var o=n.getMax(!0);null!=o&&"dataMax"!==o&&"function"!=typeof o?e[1]=o:r&&(e[1]=0<a?a-1:NaN);n.get("scale",!0)||(0<e[0]&&(e[0]=0),e[1]<0&&(e[1]=0))}(t,i),i}(this,this._dimName,e),function(i){var r=i._minMaxSpan={},a=i._dataZoomModel,o=i._dataExtent;u_(["min","max"],function(t){var e=a.get(t+"Span"),n=a.get(t+"ValueSpan");null!=n&&(n=i.getAxisModel().axis.scale.parse(n)),null!=n?e=il(o[0]+n,o,[0,100],!0):null!=e&&(n=il(e,[0,100],o,!0)-o[0]),r[t+"Span"]=e,r[t+"ValueSpan"]=n})}(this);var n=this.calculateDataWindow(t.option);this._valueWindow=n.valueWindow,this._percentWindow=n.percentWindow,d_(this)}},restore:function(t){t===this._dataZoomModel&&(this._valueWindow=this._percentWindow=null,d_(this,!0))},filterData:function(t,e){if(t===this._dataZoomModel){var i=this._dimName,n=this.getTargetSeriesModels(),r=t.get("filterMode"),c=this._valueWindow;"none"!==r&&u_(n,function(n){var h=n.getData(),u=h.mapDimension(i,!0);u.length&&("weakFilter"===r?h.filterSelf(function(t){for(var e,n,i,r=0;r<u.length;r++){var a=h.get(u[r],t),o=!isNaN(a),s=a<c[0],l=a>c[1];if(o&&!s&&!l)return!0;o&&(i=!0),s&&(e=!0),l&&(n=!0)}return i&&e&&n}):u_(u,function(t){if("empty"===r)n.setData(h=h.map(t,function(t){return function(t){return t>=c[0]&&t<=c[1]}(t)?t:NaN}));else{var e={};e[t]=c,h.selectRange(e)}}),u_(u,function(t){h.setApproximateExtent(c,t)}))})}}};var f_=A,p_=r_,g_=Fd({type:"dataZoom",dependencies:["xAxis","yAxis","zAxis","radiusAxis","angleAxis","singleAxis","series"],defaultOption:{zlevel:0,z:4,orient:null,xAxisIndex:null,yAxisIndex:null,filterMode:"filter",throttle:null,start:0,end:100,startValue:null,endValue:null,minSpan:null,maxSpan:null,minValueSpan:null,maxValueSpan:null,rangeMode:null},init:function(t,e,n){this._dataIntervalByAxis={},this._dataInfo={},this._axisProxies={},this.textStyleModel,this._autoThrottle=!0,this._rangePropMode=["percent","percent"];var i=m_(t);this.mergeDefaultAndTheme(t,n),this.doInit(i)},mergeOption:function(t){var e=m_(t);m(this.option,t,!0),this.doInit(e)},doInit:function(t){var n=this.option;v.canvasSupported||(n.realtime=!1),this._setDefaultThrottle(t),v_(this,t),f_([["start","startValue"],["end","endValue"]],function(t,e){"value"===this._rangePropMode[e]&&(n[t[0]]=null)},this),this.textStyleModel=this.getModel("textStyle"),this._resetTarget(),this._giveAxisProxies()},_giveAxisProxies:function(){var o=this._axisProxies;this.eachTargetAxis(function(t,e,n,i){var r=this.dependentModels[t.axis][e],a=r.__dzAxisProxy||(r.__dzAxisProxy=new h_(t.name,e,this,i));o[t.name+"_"+e]=a},this)},_resetTarget:function(){var n=this.option,t=this._judgeAutoMode();p_(function(t){var e=t.axisIndex;n[e]=gr(n[e])},this),"axisIndex"===t?this._autoSetAxisIndex():"orient"===t&&this._autoSetOrient()},_judgeAutoMode:function(){var e=this.option,n=!1;p_(function(t){null!=e[t.axisIndex]&&(n=!0)},this);var t=e.orient;return null==t&&n?"orient":n?void 0:(null==t&&(e.orient="horizontal"),"axisIndex")},_autoSetAxisIndex:function(){var a=!0,e=this.get("orient",!0),o=this.option,t=this.dependentModels;if(a){var n="vertical"===e?"y":"x";t[n+"Axis"].length?(o[n+"AxisIndex"]=[0],a=!1):f_(t.singleAxis,function(t){a&&t.get("orient",!0)===e&&(o.singleAxisIndex=[t.componentIndex],a=!1)})}a&&p_(function(t){if(a){var e=[],n=this.dependentModels[t.axis];if(n.length&&!e.length)for(var i=0,r=n.length;i<r;i++)"category"===n[i].get("type")&&e.push(i);(o[t.axisIndex]=e).length&&(a=!1)}},this),a&&this.ecModel.eachSeries(function(r){this._isSeriesHasAllAxesTypeOf(r,"value")&&p_(function(t){var e=o[t.axisIndex],n=r.get(t.axisIndex),i=r.get(t.axisId);x(e,n=r.ecModel.queryComponents({mainType:t.axis,index:n,id:i})[0].componentIndex)<0&&e.push(n)})},this)},_autoSetOrient:function(){var e;this.eachTargetAxis(function(t){e=e||t.name},this),this.option.orient="y"===e?"vertical":"horizontal"},_isSeriesHasAllAxesTypeOf:function(i,r){var a=!0;return p_(function(t){var e=i.get(t.axisIndex),n=this.dependentModels[t.axis][e];n&&n.get("type")===r||(a=!1)},this),a},_setDefaultThrottle:function(t){if(t.hasOwnProperty("throttle")&&(this._autoThrottle=!1),this._autoThrottle){var e=this.ecModel.option;this.option.throttle=e.animation&&0<e.animationDurationUpdate?100:20}},getFirstTargetAxisModel:function(){var n;return p_(function(t){if(null==n){var e=this.get(t.axisIndex);e.length&&(n=this.dependentModels[t.axis][e[0]])}},this),n},eachTargetAxis:function(n,i){var r=this.ecModel;p_(function(e){f_(this.get(e.axisIndex),function(t){n.call(i,e,t,this,r)},this)},this)},getAxisProxy:function(t,e){return this._axisProxies[t+"_"+e]},getAxisModel:function(t,e){var n=this.getAxisProxy(t,e);return n&&n.getAxisModel()},setRawRange:function(e,t){var n=this.option;f_([["start","startValue"],["end","endValue"]],function(t){null==e[t[0]]&&null==e[t[1]]||(n[t[0]]=e[t[0]],n[t[1]]=e[t[1]])},this),t||v_(this,e)},getPercentRange:function(){var t=this.findRepresentativeAxisProxy();if(t)return t.getDataPercentWindow()},getValueRange:function(t,e){if(null!=t||null!=e)return this.getAxisProxy(t,e).getDataValueWindow();var n=this.findRepresentativeAxisProxy();return n?n.getDataValueWindow():void 0},findRepresentativeAxisProxy:function(t){if(t)return t.__dzAxisProxy;var e=this._axisProxies;for(var n in e)if(e.hasOwnProperty(n)&&e[n].hostedBy(this))return e[n];for(var n in e)if(e.hasOwnProperty(n)&&!e[n].hostedBy(this))return e[n]},getRangePropMode:function(){return this._rangePropMode.slice()}});function m_(e){var n={};return f_(["start","end","startValue","endValue","throttle"],function(t){e.hasOwnProperty(t)&&(n[t]=e[t])}),n}function v_(t,r){var a=t._rangePropMode,o=t.get("rangeMode");f_([["start","startValue"],["end","endValue"]],function(t,e){var n=null!=r[t[0]],i=null!=r[t[1]];n&&!i?a[e]="percent":!n&&i?a[e]="value":o?a[e]=o[e]:n&&(a[e]="percent")})}var y_=Pu.extend({type:"dataZoom",render:function(t,e,n,i){this.dataZoomModel=t,this.ecModel=e,this.api=n},getTargetCoordInfo:function(){var t=this.dataZoomModel,r=this.ecModel,a={};return t.eachTargetAxis(function(t,e){var n=r.getComponent(t.axis,e);if(n){var i=n.getCoordSysModel();i&&function(t,e,n,i){for(var r,a=0;a<n.length;a++)if(n[a].model===t){r=n[a];break}r||n.push(r={model:t,axisModels:[],coordIndex:i});r.axisModels.push(e)}(i,n,a[i.mainType]||(a[i.mainType]=[]),i.componentIndex)}},this),a}}),__=(g_.extend({type:"dataZoom.slider",layoutMode:"box",defaultOption:{show:!0,right:"ph",top:"ph",width:"ph",height:"ph",left:null,bottom:null,backgroundColor:"rgba(47,69,84,0)",dataBackground:{lineStyle:{color:"#2f4554",width:.5,opacity:.3},areaStyle:{color:"rgba(47,69,84,0.3)",opacity:.3}},borderColor:"#ddd",fillerColor:"rgba(167,183,204,0.4)",handleIcon:"M8.2,13.6V3.9H6.3v9.7H3.1v14.9h3.3v9.7h1.8v-9.7h3.3V13.6H8.2z M9.7,24.4H4.8v-1.4h4.9V24.4z M9.7,19.1H4.8v-1.4h4.9V19.1z",handleSize:"100%",handleStyle:{color:"#a7b7cc"},labelPrecision:null,labelFormatter:null,showDetail:!0,showDataShadow:"auto",realtime:!0,zoomLock:!1,textStyle:{color:"#333"}}}),No),x_=il,w_=ol,b_=k,S_=A,M_="horizontal",I_="vertical",C_=["line","bar","candlestick","scatter"],T_=y_.extend({type:"dataZoom.slider",init:function(t,e){this._displayables={},this._orient,this._range,this._handleEnds,this._size,this._handleWidth,this._handleHeight,this._location,this._dragging,this._dataShadowInfo,this.api=e},render:function(t,e,n,i){T_.superApply(this,"render",arguments),Yu(this,"_dispatchZoomAction",this.dataZoomModel.get("throttle"),"fixRate"),this._orient=t.get("orient"),!1!==this.dataZoomModel.get("show")?(i&&"dataZoom"===i.type&&i.from===this.uid||this._buildView(),this._updateView()):this.group.removeAll()},remove:function(){T_.superApply(this,"remove",arguments),ju(this,"_dispatchZoomAction")},dispose:function(){T_.superApply(this,"dispose",arguments),ju(this,"_dispatchZoomAction")},_buildView:function(){var t=this.group;t.removeAll(),this._resetLocation(),this._resetInterval();var e=this._displayables.barGroup=new yn;this._renderBackground(),this._renderHandle(),this._renderDataShadow(),t.add(e),this._positionGroup()},_resetLocation:function(){var t=this.dataZoomModel,e=this.api,n=this._findCoordRect(),i={width:e.getWidth(),height:e.getHeight()},r=this._orient===M_?{right:i.width-n.x-n.width,top:i.height-30-7,width:n.width,height:30}:{right:7,top:n.y,width:30,height:n.height},a=Wl(t.option);A(["right","top","width","height"],function(t){"ph"===a[t]&&(a[t]=r[t])});var o=Fl(a,i,t.padding);this._location={x:o.x,y:o.y},this._size=[o.width,o.height],this._orient===I_&&this._size.reverse()},_positionGroup:function(){var t=this.group,e=this._location,n=this._orient,i=this.dataZoomModel.getFirstTargetAxisModel(),r=i&&i.get("inverse"),a=this._displayables.barGroup,o=(this._dataShadowInfo||{}).otherAxisInverse;a.attr(n!==M_||r?n===M_&&r?{scale:o?[-1,1]:[-1,-1]}:n!==I_||r?{scale:o?[-1,-1]:[-1,1],rotation:Math.PI/2}:{scale:o?[1,-1]:[1,1],rotation:Math.PI/2}:{scale:o?[1,1]:[1,-1]});var s=t.getBoundingRect([a]);t.attr("position",[e.x-s.x,e.y-s.y])},_getViewExtent:function(){return[0,this._size[0]]},_renderBackground:function(){var t=this.dataZoomModel,e=this._size,n=this._displayables.barGroup;n.add(new __({silent:!0,shape:{x:0,y:0,width:e[0],height:e[1]},style:{fill:t.get("backgroundColor")},z2:-40})),n.add(new __({shape:{x:0,y:0,width:e[0],height:e[1]},style:{fill:"transparent"},z2:0,onclick:k(this._onClickPanelClick,this)}))},_renderDataShadow:function(){var t=this._dataShadowInfo=this._prepareDataShadowInfo();if(t){var e=this._size,n=t.series,i=n.getRawData(),r=n.getShadowDim?n.getShadowDim():t.otherDim;if(null!=r){var a=i.getDataExtent(r),o=.3*(a[1]-a[0]);a=[a[0]-o,a[1]+o];var s,l=[0,e[1]],h=[0,e[0]],u=[[e[0],0],[0,0]],c=[],d=h[1]/(i.count()-1),f=0,p=Math.round(i.count()/e[0]);i.each([r],function(t,e){if(0<p&&e%p)f+=d;else{var n=null==t||isNaN(t)||""===t,i=n?0:x_(t,a,l,!0);n&&!s&&e?(u.push([u[u.length-1][0],0]),c.push([c[c.length-1][0],0])):!n&&s&&(u.push([f,0]),c.push([f,0])),u.push([f,i]),c.push([f,i]),f+=d,s=n}});var g=this.dataZoomModel;this._displayables.barGroup.add(new Do({shape:{points:u},style:T({fill:g.get("dataBackgroundColor")},g.getModel("dataBackground.areaStyle").getAreaStyle()),silent:!0,z2:-20})),this._displayables.barGroup.add(new ko({shape:{points:c},style:g.getModel("dataBackground.lineStyle").getLineStyle(),silent:!0,z2:-19}))}}},_prepareDataShadowInfo:function(){var t=this.dataZoomModel,s=t.get("showDataShadow");if(!1!==s){var l,h=this.ecModel;return t.eachTargetAxis(function(a,o){A(t.getAxisProxy(a.name,o).getTargetSeriesModels(),function(t){if(!(l||!0!==s&&x(C_,t.get("type"))<0)){var e,n=h.getComponent(a.axis,o).axis,i=function(t){return{x:"y",y:"x",radius:"angle",angle:"radius"}[t]}(a.name),r=t.coordinateSystem;null!=i&&r.getOtherAxis&&(e=r.getOtherAxis(n).inverse),i=t.getData().mapDimension(i),l={thisAxis:n,series:t,thisDim:a.name,otherDim:i,otherAxisInverse:e}}},this)},this),l}},_renderHandle:function(){var t=this._displayables,a=t.handles=[],o=t.handleLabels=[],s=this._displayables.barGroup,e=this._size,l=this.dataZoomModel;s.add(t.filler=new __({draggable:!0,cursor:A_(this._orient),drift:b_(this._onDragMove,this,"all"),onmousemove:function(t){Rt(t.event)},ondragstart:b_(this._showDataInfo,this,!0),ondragend:b_(this._onDragEnd,this),onmouseover:b_(this._showDataInfo,this,!0),onmouseout:b_(this._showDataInfo,this,!1),style:{fill:l.get("fillerColor"),textPosition:"inside"}})),s.add(new __({silent:!0,subPixelOptimize:!0,shape:{x:0,y:0,width:e[0],height:e[1]},style:{stroke:l.get("dataBackgroundColor")||l.get("borderColor"),lineWidth:1,fill:"rgba(0,0,0,0)"}})),S_([0,1],function(t){var e=Gs(l.get("handleIcon"),{cursor:A_(this._orient),draggable:!0,drift:b_(this._onDragMove,this,t),onmousemove:function(t){Rt(t.event)},ondragend:b_(this._onDragEnd,this),onmouseover:b_(this._showDataInfo,this,!0),onmouseout:b_(this._showDataInfo,this,!1)},{x:-1,y:0,width:2,height:2}),n=e.getBoundingRect();this._handleHeight=rl(l.get("handleSize"),this._size[1]),this._handleWidth=n.width/n.height*this._handleHeight,e.setStyle(l.getModel("handleStyle").getItemStyle());var i=l.get("handleColor");null!=i&&(e.style.fill=i),s.add(a[t]=e);var r=l.textStyleModel;this.group.add(o[t]=new wo({silent:!0,invisible:!0,style:{x:0,y:0,text:"",textVerticalAlign:"middle",textAlign:"center",textFill:r.getTextColor(),textFont:r.getFont()},z2:10}))},this)},_resetInterval:function(){var t=this._range=this.dataZoomModel.getPercentRange(),e=this._getViewExtent();this._handleEnds=[x_(t[0],[0,100],e,!0),x_(t[1],[0,100],e,!0)]},_updateInterval:function(t,e){var n=this.dataZoomModel,i=this._handleEnds,r=this._getViewExtent(),a=n.findRepresentativeAxisProxy().getMinMaxSpan(),o=[0,100];o_(e,i,r,n.get("zoomLock")?"all":t,null!=a.minSpan?x_(a.minSpan,o,r,!0):null,null!=a.maxSpan?x_(a.maxSpan,o,r,!0):null);var s=this._range,l=this._range=w_([x_(i[0],r,o,!0),x_(i[1],r,o,!0)]);return!s||s[0]!==l[0]||s[1]!==l[1]},_updateView:function(t){var i=this._displayables,r=this._handleEnds,e=w_(r.slice()),a=this._size;S_([0,1],function(t){var e=i.handles[t],n=this._handleHeight;e.attr({scale:[n/2,n/2],position:[r[t],a[1]/2-n/2]})},this),i.filler.setShape({x:e[0],y:0,width:e[1]-e[0],height:a[1]}),this._updateDataInfo(t)},_updateDataInfo:function(t){var e=this.dataZoomModel,a=this._displayables,o=a.handleLabels,s=this._orient,l=["",""];if(e.get("showDetail")){var n=e.findRepresentativeAxisProxy();if(n){var i=n.getAxisModel().axis,r=this._range,h=t?n.calculateDataWindow({start:r[0],end:r[1]}).valueWindow:n.getDataValueWindow();l=[this._formatLabel(h[0],i),this._formatLabel(h[1],i)]}}var u=w_(this._handleEnds.slice());function c(t){var e=Bs(a.handles[t].parent,this.group),n=Vs(0===t?"right":"left",e),i=this._handleWidth/2+5,r=Fs([u[t]+(0===t?-i:i),this._size[1]/2],e);o[t].setStyle({x:r[0],y:r[1],textVerticalAlign:s===M_?"middle":n,textAlign:s===M_?n:"center",text:l[t]})}c.call(this,0),c.call(this,1)},_formatLabel:function(t,e){var n=this.dataZoomModel,i=n.get("labelFormatter"),r=n.get("labelPrecision");null!=r&&"auto"!==r||(r=e.getPixelPrecision());var a=null==t||isNaN(t)?"":"category"===e.type||"time"===e.type?e.scale.getLabel(Math.round(t)):t.toFixed(Math.min(r,20));return z(i)?i(t,a):E(i)?i.replace("{value}",a):a},_showDataInfo:function(t){t=this._dragging||t;var e=this._displayables.handleLabels;e[0].attr("invisible",!t),e[1].attr("invisible",!t)},_onDragMove:function(t,e,n){this._dragging=!0;var i=Fs([e,n],this._displayables.barGroup.getLocalTransform(),!0),r=this._updateInterval(t,i[0]),a=this.dataZoomModel.get("realtime");this._updateView(!a),r&&a&&this._dispatchZoomAction()},_onDragEnd:function(){this._dragging=!1,this._showDataInfo(!1),this.dataZoomModel.get("realtime")||this._dispatchZoomAction()},_onClickPanelClick:function(t){var e=this._size,n=this._displayables.barGroup.transformCoordToLocal(t.offsetX,t.offsetY);if(!(n[0]<0||n[0]>e[0]||n[1]<0||n[1]>e[1])){var i=this._handleEnds,r=(i[0]+i[1])/2,a=this._updateInterval("all",n[0]-r);this._updateView(),a&&this._dispatchZoomAction()}},_dispatchZoomAction:function(){var t=this._range;this.api.dispatchAction({type:"dataZoom",from:this.uid,dataZoomId:this.dataZoomModel.id,start:t[0],end:t[1]})},_findCoordRect:function(){var n;if(S_(this.getTargetCoordInfo(),function(t){if(!n&&t.length){var e=t[0].model.coordinateSystem;n=e.getRect&&e.getRect()}}),!n){var t=this.api.getWidth(),e=this.api.getHeight();n={x:.2*t,y:.2*e,width:.6*t,height:.6*e}}return n}});function A_(t){return"vertical"===t?"ns-resize":"ew-resize"}Od({getTargetSeries:function(t){var i=Q();return t.eachComponent("dataZoom",function(t){t.eachTargetAxis(function(t,e,n){A(n.getAxisProxy(t.name,e).getTargetSeriesModels(),function(t){i.set(t.uid,t)})})}),i},modifyOutputEnd:!0,overallReset:function(t,i){t.eachComponent("dataZoom",function(t){t.eachTargetAxis(function(t,e,n){n.getAxisProxy(t.name,e).reset(n,i)}),t.eachTargetAxis(function(t,e,n){n.getAxisProxy(t.name,e).filterData(n,i)})}),t.eachComponent("dataZoom",function(t){var e=t.findRepresentativeAxisProxy(),n=e.getDataPercentWindow(),i=e.getDataValueWindow();t.setRawRange({start:n[0],end:n[1],startValue:i[0],endValue:i[1]},!0)})}}),zd("dataZoom",function(n,t){var i=a_(k(t.eachComponent,t,"dataZoom"),r_,function(t,e){return t.get(e.axisIndex)}),r=[];t.eachComponent({mainType:"dataZoom",query:n},function(t,e){r.push.apply(r,i(t).nodes)}),A(r,function(t,e){t.setRawRange({start:n.start,end:n.end,startValue:n.startValue,endValue:n.endValue})})}),g_.extend({type:"dataZoom.inside",defaultOption:{disabled:!1,zoomLock:!1,zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0}});var D_="\0_ec_interaction_mutex";function k_(t,e){return!!P_(t)[e]}function P_(t){return t[D_]||(t[D_]={})}function L_(n){this.pointerChecker,this._zr=n,this._opt={};var t=k,i=t(O_,this),r=t(z_,this),a=t(E_,this),o=t(N_,this),s=t(R_,this);It.call(this),this.setPointerChecker=function(t){this.pointerChecker=t},this.enable=function(t,e){this.disable(),this._opt=T(b(e)||{},{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0}),null==t&&(t=!0),!0!==t&&"move"!==t&&"pan"!==t||(n.on("mousedown",i),n.on("mousemove",r),n.on("mouseup",a)),!0!==t&&"scale"!==t&&"zoom"!==t||(n.on("mousewheel",o),n.on("pinch",s))},this.disable=function(){n.off("mousedown",i),n.off("mousemove",r),n.off("mouseup",a),n.off("mousewheel",o),n.off("pinch",s)},this.dispose=this.disable,this.isDragging=function(){return this._dragging},this.isPinching=function(){return this._pinching}}function O_(t){if(!(Bt(t)||t.target&&t.target.draggable)){var e=t.offsetX,n=t.offsetY;this.pointerChecker&&this.pointerChecker(t,e,n)&&(this._x=e,this._y=n,this._dragging=!0)}}function z_(t){if(this._dragging&&V_("moveOnMouseMove",t,this._opt)&&"pinch"!==t.gestureEvent&&!k_(this._zr,"globalPan")){var e=t.offsetX,n=t.offsetY,i=this._x,r=this._y,a=e-i,o=n-r;this._x=e,this._y=n,this._opt.preventDefaultMouseMove&&Rt(t.event),F_(this,"pan","moveOnMouseMove",t,{dx:a,dy:o,oldX:i,oldY:r,newX:e,newY:n})}}function E_(t){Bt(t)||(this._dragging=!1)}function N_(t){var e=V_("zoomOnMouseWheel",t,this._opt),n=V_("moveOnMouseWheel",t,this._opt),i=t.wheelDelta,r=Math.abs(i),a=t.offsetX,o=t.offsetY;if(0!==i&&(e||n)){if(e){var s=3<r?1.4:1<r?1.2:1.1;B_(this,"zoom","zoomOnMouseWheel",t,{scale:0<i?s:1/s,originX:a,originY:o})}if(n){var l=Math.abs(i);B_(this,"scrollMove","moveOnMouseWheel",t,{scrollDelta:(0<i?1:-1)*(3<l?.4:1<l?.15:.05),originX:a,originY:o})}}}function R_(t){k_(this._zr,"globalPan")||B_(this,"zoom",null,t,{scale:1<t.pinchScale?1.1:1/1.1,originX:t.pinchX,originY:t.pinchY})}function B_(t,e,n,i,r){t.pointerChecker&&t.pointerChecker(i,r.originX,r.originY)&&(Rt(i.event),F_(t,e,n,i,r))}function F_(t,e,n,i,r){r.isAvailableBehavior=k(V_,null,n,i),t.trigger(e,r)}function V_(t,e,n){var i=n[t];return!t||i&&(!E(i)||e.event[i+"Key"])}zd({type:"takeGlobalCursor",event:"globalCursorTaken",update:"update"},function(){}),S(L_,It);var H_="\0_ec_dataZoom_roams";function W_(t,i){var e=Z_(t),r=i.dataZoomId,a=i.coordId;A(e,function(t,e){var n=t.dataZoomInfos;n[r]&&x(i.allCoordIds,a)<0&&(delete n[r],t.count--)}),U_(e);var n=e[a];n||((n=e[a]={coordId:a,dataZoomInfos:{},count:0}).controller=function(t,o){var e=new L_(t.getZr());return A(["pan","zoom","scrollMove"],function(a){e.on(a,function(i){var r=[];A(o.dataZoomInfos,function(t){if(i.isAvailableBehavior(t.dataZoomModel.option)){var e=(t.getRange||{})[a],n=e&&e(o.controller,i);!t.dataZoomModel.get("disabled",!0)&&n&&r.push({dataZoomId:t.dataZoomId,start:n[0],end:n[1]})}}),r.length&&o.dispatchAction(r)})}),e}(t,n),n.dispatchAction=P(X_,t)),n.dataZoomInfos[r]||n.count++,n.dataZoomInfos[r]=i;var o=function(t){var i,r={type_true:2,type_move:1,type_false:0,type_undefined:-1},a=!0;return A(t,function(t){var e=t.dataZoomModel,n=!e.get("disabled",!0)&&(!e.get("zoomLock",!0)||"move");r["type_"+i]<r["type_"+n]&&(i=n),a&=e.get("preventDefaultMouseMove",!0)}),{controlType:i,opt:{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!0,preventDefaultMouseMove:!!a}}}(n.dataZoomInfos);n.controller.enable(o.controlType,o.opt),n.controller.setPointerChecker(i.containsPoint),Yu(n,"dispatchAction",i.dataZoomModel.get("throttle",!0),"fixRate")}function G_(t){return t.type+"\0_"+t.id}function Z_(t){var e=t.getZr();return e[H_]||(e[H_]={})}function U_(n){A(n,function(t,e){t.count||(t.controller.dispose(),delete n[e])})}function X_(t,e){t.dispatchAction({type:"dataZoom",batch:e})}var Y_=k,j_=y_.extend({type:"dataZoom.inside",init:function(t,e){this._range},render:function(o,t,s,e){j_.superApply(this,"render",arguments),this._range=o.getPercentRange(),A(this.getTargetCoordInfo(),function(t,r){var a=D(t,function(t){return G_(t.model)});A(t,function(e){var i=e.model,n={};A(["pan","zoom","scrollMove"],function(t){n[t]=Y_(q_[t],this,e,r)},this),W_(s,{coordId:G_(i),allCoordIds:a,containsPoint:function(t,e,n){return i.coordinateSystem.containPoint([e,n])},dataZoomId:o.id,dataZoomModel:o,getRange:n})},this)},this)},dispose:function(){!function(t,n){var e=Z_(t);A(e,function(t){t.controller.dispose();var e=t.dataZoomInfos;e[n]&&(delete e[n],t.count--)}),U_(e)}(this.api,this.dataZoomModel.id),j_.superApply(this,"dispose",arguments),this._range=null}}),q_={zoom:function(t,e,n,i){var r=this._range,a=r.slice(),o=t.axisModels[0];if(o){var s=K_[e](null,[i.originX,i.originY],o,n,t),l=(0<s.signal?s.pixelStart+s.pixelLength-s.pixel:s.pixel-s.pixelStart)/s.pixelLength*(a[1]-a[0])+a[0],h=Math.max(1/i.scale,0);a[0]=(a[0]-l)*h+l,a[1]=(a[1]-l)*h+l;var u=this.dataZoomModel.findRepresentativeAxisProxy().getMinMaxSpan();return o_(0,a,[0,100],0,u.minSpan,u.maxSpan),this._range=a,r[0]!==a[0]||r[1]!==a[1]?a:void 0}},pan:$_(function(t,e,n,i,r,a){var o=K_[i]([a.oldX,a.oldY],[a.newX,a.newY],e,r,n);return o.signal*(t[1]-t[0])*o.pixel/o.pixelLength}),scrollMove:$_(function(t,e,n,i,r,a){return K_[i]([0,0],[a.scrollDelta,a.scrollDelta],e,r,n).signal*(t[1]-t[0])*a.scrollDelta})};function $_(l){return function(t,e,n,i){var r=this._range,a=r.slice(),o=t.axisModels[0];if(o){var s=l(a,o,t,e,n,i);return o_(s,a,[0,100],"all"),this._range=a,r[0]!==a[0]||r[1]!==a[1]?a:void 0}}}var K_={grid:function(t,e,n,i,r){var a=n.axis,o={},s=r.model.coordinateSystem.getRect();return t=t||[0,0],"x"===a.dim?(o.pixel=e[0]-t[0],o.pixelLength=s.width,o.pixelStart=s.x,o.signal=a.inverse?1:-1):(o.pixel=e[1]-t[1],o.pixelLength=s.height,o.pixelStart=s.y,o.signal=a.inverse?-1:1),o},polar:function(t,e,n,i,r){var a=n.axis,o={},s=r.model.coordinateSystem,l=s.getRadiusAxis().getExtent(),h=s.getAngleAxis().getExtent();return t=t?s.pointToCoord(t):[0,0],e=s.pointToCoord(e),"radiusAxis"===n.mainType?(o.pixel=e[0]-t[0],o.pixelLength=l[1]-l[0],o.pixelStart=l[0],o.signal=a.inverse?1:-1):(o.pixel=e[1]-t[1],o.pixelLength=h[1]-h[0],o.pixelStart=h[0],o.signal=a.inverse?-1:1),o},singleAxis:function(t,e,n,i,r){var a=n.axis,o=r.model.coordinateSystem.getRect(),s={};return t=t||[0,0],"horizontal"===a.orient?(s.pixel=e[0]-t[0],s.pixelLength=o.width,s.pixelStart=o.x,s.signal=a.inverse?1:-1):(s.pixel=e[1]-t[1],s.pixelLength=o.height,s.pixelStart=o.y,s.signal=a.inverse?-1:1),s}},Q_={};function J_(t,e){Q_[t]=e}function tx(t){return Q_[t]}var ex=Fd({type:"toolbox",layoutMode:{type:"box",ignoreSize:!0},optionUpdated:function(){ex.superApply(this,"optionUpdated",arguments),A(this.option.feature,function(t,e){var n=tx(e);n&&m(t,n.defaultOption)})},defaultOption:{show:!0,z:6,zlevel:0,orient:"horizontal",left:"right",top:"top",backgroundColor:"transparent",borderColor:"#ccc",borderRadius:0,borderWidth:0,padding:5,itemSize:15,itemGap:8,showTitle:!0,iconStyle:{borderColor:"#666",color:"none"},emphasis:{iconStyle:{borderColor:"#3E98C5"}},tooltip:{show:!1}}});Vd({type:"toolbox",render:function(u,c,d,s){var f=this.group;if(f.removeAll(),u.get("show")){var p=+u.get("itemSize"),l=u.get("feature")||{},h=this._features||(this._features={}),g=[];A(l,function(t,e){g.push(e)}),new Zd(this._featureNames||[],g).add(t).update(t).remove(P(t,null)).execute(),this._featureNames=g,function(t,e,n){var i=e.getBoxLayoutParams(),r=e.get("padding"),a={width:n.getWidth(),height:n.getHeight()},o=Fl(i,a,r);Bl(e.get("orient"),t,e.get("itemGap"),o.width,o.height),Vl(t,i,a,r)}(f,u,d),f.add(Qv(f.getBoundingRect(),u)),f.eachChild(function(t){var e=t.__title,n=t.hoverStyle;if(n&&e){var i=ii(e,gi(n)),r=t.position[0]+f.position[0],a=!1;t.position[1]+f.position[1]+p+i.height>d.getHeight()&&(n.textPosition="top",a=!0);var o=a?-5-i.height:p+8;r+i.width/2>d.getWidth()?(n.textPosition=["100%",o],n.textAlign="right"):r-i.width/2<0&&(n.textPosition=[0,o],n.textAlign="left")}})}function t(t,e){var n,i=g[t],r=g[e],a=new Ks(l[i],u,u.ecModel);if(i&&!r){if(function(t){return 0===t.indexOf("my")}(i))n={model:a,onclick:a.option.onclick,featureName:i};else{var o=tx(i);if(!o)return;n=new o(a,c,d)}h[i]=n}else{if(!(n=h[r]))return;n.model=a,n.ecModel=c,n.api=d}i||!r?a.get("show")&&!n.unusable?(function(r,a,t){var o=r.getModel("iconStyle"),s=r.getModel("emphasis.iconStyle"),e=a.getIcons?a.getIcons():r.get("icon"),l=r.get("title")||{};if("string"==typeof e){var n=e,i=l;l={},(e={})[t]=n,l[t]=i}var h=r.iconPaths={};A(e,function(t,e){var n=Gs(t,{},{x:-p/2,y:-p/2,width:p,height:p});n.setStyle(o.getItemStyle()),n.hoverStyle=s.getItemStyle();var i=u.getModel("tooltip");i&&i.get("show")&&n.attr("tooltip",I({content:l[e],formatter:i.get("formatter",!0)||function(){return l[e]},formatterParams:{componentType:"toolbox",name:e,title:l[e],$vars:["name","title"]},position:i.get("position",!0)||"bottom"},i.option)),Ss(n),u.get("showTitle")&&(n.__title=l[e],n.on("mouseover",function(){var t=s.getItemStyle();n.setStyle({text:l[e],textPosition:s.get("textPosition")||"bottom",textFill:s.get("textFill")||t.fill||t.stroke||"#000",textAlign:s.get("textAlign")||"center",textBackgroundColor:s.get("textBackgroundColor"),textBorderRadius:s.get("textBorderRadius"),textPadding:s.get("textPadding")})}).on("mouseout",function(){n.setStyle({textFill:null,textBackgroundColor:null})})),n.trigger(r.get("iconStatus."+e)||"normal"),f.add(n),n.on("click",k(a.onclick,a,c,d,e)),h[e]=n})}(a,n,i),a.setIconStatus=function(t,e){var n=this.option,i=this.iconPaths;n.iconStatus=n.iconStatus||{},n.iconStatus[t]=e,i[t]&&i[t].trigger(e)},n.render&&n.render(a,c,d,s)):n.remove&&n.remove(c,d):n.dispose&&n.dispose(c,d)}},updateView:function(t,e,n,i){A(this._features,function(t){t.updateView&&t.updateView(t.model,e,n,i)})},remove:function(e,n){A(this._features,function(t){t.remove&&t.remove(e,n)}),this.group.removeAll()},dispose:function(e,n){A(this._features,function(t){t.dispose&&t.dispose(e,n)})}});var nx=$u.toolbox.saveAsImage;function ix(t){this.model=t}ix.defaultOption={show:!0,icon:"M4.7,22.9L29.3,45.5L54.7,23.4M4.6,43.6L4.6,58L53.8,58L53.8,43.6M29.2,45.1L29.2,0",title:nx.title,type:"png",connectedBackgroundColor:"#fff",name:"",excludeComponents:["toolbox"],pixelRatio:1,lang:nx.lang.slice()},ix.prototype.unusable=!v.canvasSupported,ix.prototype.onclick=function(t,e){var n=this.model,i=n.get("name")||t.get("title.0.text")||"echarts",r=n.get("type",!0)||"png",a=e.getConnectedDataURL({type:r,backgroundColor:n.get("backgroundColor",!0)||t.get("backgroundColor")||"#fff",connectedBackgroundColor:n.get("connectedBackgroundColor"),excludeComponents:n.get("excludeComponents"),pixelRatio:n.get("pixelRatio")});if("function"!=typeof MouseEvent||v.browser.ie||v.browser.edge)if(window.navigator.msSaveOrOpenBlob){for(var o=atob(a.split(",")[1]),s=o.length,l=new Uint8Array(s);s--;)l[s]=o.charCodeAt(s);var h=new Blob([l]);window.navigator.msSaveOrOpenBlob(h,i+"."+r)}else{var u=n.get("lang"),c='<body style="margin:0;"><img src="'+a+'" style="max-width:100%;" title="'+(u&&u[0]||"")+'" /></body>';window.open().document.write(c)}else{var d=document.createElement("a");d.download=i+"."+r,d.target="_blank",d.href=a;var f=new MouseEvent("click",{view:window,bubbles:!0,cancelable:!1});d.dispatchEvent(f)}},J_("saveAsImage",ix);var rx=$u.toolbox.magicType;function ax(t){this.model=t}ax.defaultOption={show:!0,type:[],icon:{line:"M4.1,28.9h7.1l9.3-22l7.4,38l9.7-19.7l3,12.8h14.9M4.1,58h51.4",bar:"M6.7,22.9h10V48h-10V22.9zM24.9,13h10v35h-10V13zM43.2,2h10v46h-10V2zM3.1,58h53.7",stack:"M8.2,38.4l-8.4,4.1l30.6,15.3L60,42.5l-8.1-4.1l-21.5,11L8.2,38.4z M51.9,30l-8.1,4.2l-13.4,6.9l-13.9-6.9L8.2,30l-8.4,4.2l8.4,4.2l22.2,11l21.5-11l8.1-4.2L51.9,30z M51.9,21.7l-8.1,4.2L35.7,30l-5.3,2.8L24.9,30l-8.4-4.1l-8.3-4.2l-8.4,4.2L8.2,30l8.3,4.2l13.9,6.9l13.4-6.9l8.1-4.2l8.1-4.1L51.9,21.7zM30.4,2.2L-0.2,17.5l8.4,4.1l8.3,4.2l8.4,4.2l5.5,2.7l5.3-2.7l8.1-4.2l8.1-4.2l8.1-4.1L30.4,2.2z",tiled:"M2.3,2.2h22.8V25H2.3V2.2z M35,2.2h22.8V25H35V2.2zM2.3,35h22.8v22.8H2.3V35z M35,35h22.8v22.8H35V35z"},title:b(rx.title),option:{},seriesIndex:{}};var ox=ax.prototype;ox.getIcons=function(){var t=this.model,e=t.get("icon"),n={};return A(t.get("type"),function(t){e[t]&&(n[t]=e[t])}),n};var sx={line:function(t,e,n,i){if("bar"===t)return m({id:e,type:"line",data:n.get("data"),stack:n.get("stack"),markPoint:n.get("markPoint"),markLine:n.get("markLine")},i.get("option.line")||{},!0)},bar:function(t,e,n,i){if("line"===t)return m({id:e,type:"bar",data:n.get("data"),stack:n.get("stack"),markPoint:n.get("markPoint"),markLine:n.get("markLine")},i.get("option.bar")||{},!0)},stack:function(t,e,n,i){if("line"===t||"bar"===t)return m({id:e,stack:"__ec_magicType_stack__"},i.get("option.stack")||{},!0)},tiled:function(t,e,n,i){if("line"===t||"bar"===t)return m({id:e,stack:""},i.get("option.tiled")||{},!0)}},lx=[["line","bar"],["stack","tiled"]];ox.onclick=function(h,t,u){var c=this.model,e=c.get("seriesIndex."+u);if(sx[u]){var d={series:[]};A(lx,function(t){0<=x(t,u)&&A(t,function(t){c.setIconStatus(t,"normal")})}),c.setIconStatus(u,"emphasis"),h.eachComponent({mainType:"series",query:null==e?null:{seriesIndex:e}},function(t){var e=t.subType,n=t.id,i=sx[u](e,n,t,c);i&&(T(i,t.option),d.series.push(i));var r=t.coordinateSystem;if(r&&"cartesian2d"===r.type&&("line"===u||"bar"===u)){var a=r.getAxesByScale("ordinal")[0];if(a){var o=a.dim+"Axis",s=h.queryComponents({mainType:o,index:t.get(name+"Index"),id:t.get(name+"Id")})[0].componentIndex;d[o]=d[o]||[];for(var l=0;l<=s;l++)d[o][s]=d[o][s]||{};d[o][s].boundaryGap="bar"===u}}}),t.dispatchAction({type:"changeMagicType",currentType:u,newOption:d})}},zd({type:"changeMagicType",event:"magicTypeChanged",update:"prepareAndUpdate"},function(t,e){e.mergeOption(t.newOption)}),J_("magicType",ax);var hx=$u.toolbox.dataView,ux=new Array(60).join("-"),cx="\t";function dx(t){var e=function(t){var r={},a=[],o=[];return t.eachRawSeries(function(t){var e=t.coordinateSystem;if(!e||"cartesian2d"!==e.type&&"polar"!==e.type)a.push(t);else{var n=e.getBaseAxis();if("category"===n.type){var i=n.dim+"_"+n.index;r[i]||(r[i]={categoryAxis:n,valueAxis:e.getOtherAxis(n),series:[]},o.push({axisDim:n.dim,axisIndex:n.index})),r[i].series.push(t)}else a.push(t)}}),{seriesGroupByCategoryAxis:r,other:a,meta:o}}(t);return{value:C([function(t){var u=[];return A(t,function(t,e){var n=t.categoryAxis,i=t.valueAxis.dim,r=[" "].concat(D(t.series,function(t){return t.name})),a=[n.model.getCategories()];A(t.series,function(t){a.push(t.getRawData().mapArray(i,function(t){return t}))});for(var o=[r.join(cx)],s=0;s<a[0].length;s++){for(var l=[],h=0;h<a.length;h++)l.push(a[h][s]);o.push(l.join(cx))}u.push(o.join("\n"))}),u.join("\n\n"+ux+"\n\n")}(e.seriesGroupByCategoryAxis),function(t){return D(t,function(t){var r=t.getRawData(),a=[t.name],o=[];return r.each(r.dimensions,function(){for(var t=arguments.length,e=arguments[t-1],n=r.getName(e),i=0;i<t-1;i++)o[i]=arguments[i];a.push((n?n+cx:"")+o.join(cx))}),a.join("\n")}).join("\n\n"+ux+"\n\n")}(e.other)],function(t){return t.replace(/[\n\t\s]/g,"")}).join("\n\n"+ux+"\n\n"),meta:e.meta}}function fx(t){return t.replace(/^\s\s*/,"").replace(/\s\s*$/,"")}var px=new RegExp("["+cx+"]+","g");function gx(t,a){var e=t.split(new RegExp("\n*"+ux+"\n*","g")),o={series:[]};return A(e,function(t,e){if(function(t){if(0<=t.slice(0,t.indexOf("\n")).indexOf(cx))return!0}(t)){var n=function(t){for(var e=t.split(/\n+/g),n=[],i=D(fx(e.shift()).split(px),function(t){return{name:t,data:[]}}),r=0;r<e.length;r++){var a=fx(e[r]).split(px);n.push(a.shift());for(var o=0;o<a.length;o++)i[o]&&(i[o].data[r]=a[o])}return{series:i,categories:n}}(t),i=a[e],r=i.axisDim+"Axis";i&&(o[r]=o[r]||[],o[r][i.axisIndex]={data:n.categories},o.series=o.series.concat(n.series))}else{n=function(t){for(var e=t.split(/\n+/g),n=fx(e.shift()),i=[],r=0;r<e.length;r++){var a,o=fx(e[r]).split(px),s="",l=!1;a=isNaN(o[0])?(l=!0,s=o[0],o=o.slice(1),i[r]={name:s,value:[]},i[r].value):i[r]=[];for(var h=0;h<o.length;h++)a.push(+o[h]);1===a.length&&(l?i[r].value=a[0]:i[r]=a[0])}return{name:n,data:i}}(t);o.series.push(n)}}),o}function mx(t){this._dom=null,this.model=t}mx.defaultOption={show:!0,readOnly:!1,optionToContent:null,contentToOption:null,icon:"M17.5,17.3H33 M17.5,17.3H33 M45.4,29.5h-28 M11.5,2v56H51V14.8L38.4,2H11.5z M38.4,2.2v12.7H51 M45.4,41.7h-28",title:b(hx.title),lang:b(hx.lang),backgroundColor:"#fff",textColor:"#000",textareaColor:"#fff",textareaBorderColor:"#333",buttonColor:"#c23531",buttonTextColor:"#fff"},mx.prototype.onclick=function(t,e){var n=e.getDom(),i=this.model;this._dom&&n.removeChild(this._dom);var r=document.createElement("div");r.style.cssText="position:absolute;left:5px;top:5px;bottom:5px;right:5px;",r.style.backgroundColor=i.get("backgroundColor")||"#fff";var a=document.createElement("h4"),o=i.get("lang")||[];a.innerHTML=o[0]||i.get("title"),a.style.cssText="margin: 10px 20px;",a.style.color=i.get("textColor");var s=document.createElement("div"),l=document.createElement("textarea");s.style.cssText="display:block;width:100%;overflow:auto;";var h=i.get("optionToContent"),u=i.get("contentToOption"),c=dx(t);if("function"==typeof h){var d=h(e.getOption());"string"==typeof d?s.innerHTML=d:F(d)&&s.appendChild(d)}else s.appendChild(l),l.readOnly=i.get("readOnly"),l.style.cssText="width:100%;height:100%;font-family:monospace;font-size:14px;line-height:1.6rem;",l.style.color=i.get("textColor"),l.style.borderColor=i.get("textareaBorderColor"),l.style.backgroundColor=i.get("textareaColor"),l.value=c.value;var f=c.meta,p=document.createElement("div");p.style.cssText="position:absolute;bottom:0;left:0;right:0;";var g="float:right;margin-right:20px;border:none;cursor:pointer;padding:2px 5px;font-size:12px;border-radius:3px",m=document.createElement("div"),v=document.createElement("div");g+=";background-color:"+i.get("buttonColor"),g+=";color:"+i.get("buttonTextColor");var y=this;function _(){n.removeChild(r),y._dom=null}Nt(m,"click",_),Nt(v,"click",function(){var t;try{t="function"==typeof u?u(s,e.getOption()):gx(l.value,f)}catch(t){throw _(),new Error("Data view format error "+t)}t&&e.dispatchAction({type:"changeDataView",newOption:t}),_()}),m.innerHTML=o[1],v.innerHTML=o[2],v.style.cssText=g,m.style.cssText=g,i.get("readOnly")||p.appendChild(v),p.appendChild(m),Nt(l,"keydown",function(t){if(9===(t.keyCode||t.which)){var e=this.value,n=this.selectionStart,i=this.selectionEnd;this.value=e.substring(0,n)+cx+e.substring(i),this.selectionStart=this.selectionEnd=n+1,Rt(t)}}),r.appendChild(a),r.appendChild(s),r.appendChild(p),s.style.height=n.clientHeight-80+"px",n.appendChild(r),this._dom=r},mx.prototype.remove=function(t,e){this._dom&&e.getDom().removeChild(this._dom)},mx.prototype.dispose=function(t,e){this.remove(t,e)},J_("dataView",mx),zd({type:"changeDataView",event:"dataViewChanged",update:"prepareAndUpdate"},function(t,i){var r=[];A(t.newOption.series,function(t){var e=i.getSeriesByName(t.name)[0];if(e){var n=e.get("data");r.push({name:t.name,data:function(t,i){return D(t,function(t,e){var n=i&&i[e];return N(n)&&!O(n)?(N(t)&&!O(t)&&(t=t.value),T({value:t},n)):t})}(t.data,n)})}else r.push(I({type:"scatter"},t))}),i.mergeOption(T({series:r},t.newOption))});var vx=P,yx=A,_x=D,xx=Math.min,bx=Math.max,Sx=Math.pow,Mx=1e4,Ix=6,Cx=6,Tx="globalPan",Ax={w:[0,0],e:[0,1],n:[1,0],s:[1,1]},Dx={w:"ew",e:"ew",n:"ns",s:"ns",ne:"nesw",sw:"nesw",nw:"nwse",se:"nwse"},kx={brushStyle:{lineWidth:2,stroke:"rgba(0,0,0,0.3)",fill:"rgba(0,0,0,0.1)"},transformable:!0,brushMode:"single",removeOnClick:!1},Px=0;function Lx(t){It.call(this),this._zr=t,this.group=new yn,this._brushType,this._brushOption,this._panels,this._track=[],this._dragging,this._covers=[],this._creatingCover,this._creatingPanel,this._enableGlobalPan,this._uid="brushController_"+Px++,this._handlers={},yx(rw,function(t,e){this._handlers[e]=k(t,this)},this)}function Ox(t,e){var n=ow[e.brushType].createCover(t,e);return n.__brushOption=e,Nx(n,e),t.group.add(n),n}function zx(t,e){var n=Bx(e);return n.endCreating&&(n.endCreating(t,e),Nx(e,e.__brushOption)),e}function Ex(t,e){var n=e.__brushOption;Bx(e).updateCoverShape(t,e,n.range,n)}function Nx(t,e){var n=e.z;null==n&&(n=Mx),t.traverse(function(t){t.z=n,t.z2=n})}function Rx(t,e){Bx(e).updateCommon(t,e),Ex(t,e)}function Bx(t){return ow[t.__brushOption.brushType]}function Fx(t,e,n){var i,r=t._panels;if(!r)return!0;var a=t._transform;return yx(r,function(t){t.isTargetByCursor(e,n,a)&&(i=t)}),i}function Vx(t,e){var n=t._panels;if(!n)return!0;var i=e.__brushOption.panelId;return null==i||n[i]}function Hx(e){var t=e._covers,n=t.length;return yx(t,function(t){e.group.remove(t)},e),t.length=0,!!n}function Wx(t,e){var n=_x(t._covers,function(t){var e=t.__brushOption,n=b(e.range);return{brushType:e.brushType,panelId:e.panelId,range:n}});t.trigger("brush",n,{isEnd:!!e.isEnd,removeOnClick:!!e.removeOnClick})}function Gx(t){var e=t.length-1;return e<0&&(e=0),[t[0],t[e]]}function Zx(e,n,t,i){var r=new yn;return r.add(new No({name:"main",style:jx(t),silent:!0,draggable:!0,cursor:"move",drift:vx(e,n,r,"nswe"),ondragend:vx(Wx,n,{isEnd:!0})})),yx(i,function(t){r.add(new No({name:t,style:{opacity:0},draggable:!0,silent:!0,invisible:!0,drift:vx(e,n,r,t),ondragend:vx(Wx,n,{isEnd:!0})}))}),r}function Ux(t,e,n,i){var r=i.brushStyle.lineWidth||0,a=bx(r,Cx),o=n[0][0],s=n[1][0],l=o-r/2,h=s-r/2,u=n[0][1],c=n[1][1],d=u-a+r/2,f=c-a+r/2,p=u-o,g=c-s,m=p+r,v=g+r;Yx(t,e,"main",o,s,p,g),i.transformable&&(Yx(t,e,"w",l,h,a,v),Yx(t,e,"e",d,h,a,v),Yx(t,e,"n",l,h,m,a),Yx(t,e,"s",l,f,m,a),Yx(t,e,"nw",l,h,a,a),Yx(t,e,"ne",d,h,a,a),Yx(t,e,"sw",l,f,a,a),Yx(t,e,"se",d,f,a,a))}function Xx(i,r){var t=r.__brushOption,a=t.transformable,e=r.childAt(0);e.useStyle(jx(t)),e.attr({silent:!a,cursor:a?"move":"default"}),yx(["w","e","n","s","se","sw","ne","nw"],function(t){var e=r.childOfName(t),n=function t(e,n){{if(1<n.length){n=n.split("");var i=[t(e,n[0]),t(e,n[1])];return"e"!==i[0]&&"w"!==i[0]||i.reverse(),i.join("")}var r={w:"left",e:"right",n:"top",s:"bottom"},a={left:"w",right:"e",top:"n",bottom:"s"},i=Vs(r[n],Bs(e.group));return a[i]}}(i,t);e&&e.attr({silent:!a,invisible:!a,cursor:a?Dx[n]+"-resize":null})})}function Yx(t,e,n,i,r,a,o){var s=e.childOfName(n);s&&s.setShape(function(t){var e=xx(t[0][0],t[1][0]),n=xx(t[0][1],t[1][1]),i=bx(t[0][0],t[1][0]),r=bx(t[0][1],t[1][1]);return{x:e,y:n,width:i-e,height:r-n}}(Jx(t,e,[[i,r],[i+a,r+o]])))}function jx(t){return T({strokeNoScale:!0},t.brushStyle)}function qx(t,e,n,i){var r=[xx(t,n),xx(e,i)],a=[bx(t,n),bx(e,i)];return[[r[0],a[0]],[r[1],a[1]]]}function $x(t,e,n,i,r,a,o,s){var l=i.__brushOption,h=t(l.range),u=Qx(n,a,o);yx(r.split(""),function(t){var e=Ax[t];h[e[0]][e[1]]+=u[e[0]]}),l.range=e(qx(h[0][0],h[1][0],h[0][1],h[1][1])),Rx(n,i),Wx(n,{isEnd:!1})}function Kx(t,e,n,i,r){var a=e.__brushOption.range,o=Qx(t,n,i);yx(a,function(t){t[0]+=o[0],t[1]+=o[1]}),Rx(t,e),Wx(t,{isEnd:!1})}function Qx(t,e,n){var i=t.group,r=i.transformCoordToLocal(e,n),a=i.transformCoordToLocal(0,0);return[r[0]-a[0],r[1]-a[1]]}function Jx(t,e,n){var i=Vx(t,e);return i&&!0!==i?i.clipPath(n,t._transform):b(n)}function tw(t){var e=t.event;e.preventDefault&&e.preventDefault()}function ew(t,e,n){return t.childOfName("main").contain(e,n)}function nw(t,e,n,i){var r,a=t._creatingCover,o=t._creatingPanel,s=t._brushOption;if(t._track.push(n.slice()),function(t){var e=t._track;if(!e.length)return!1;var n=e[e.length-1],i=e[0],r=n[0]-i[0],a=n[1]-i[1],o=Sx(r*r+a*a,.5);return Ix<o}(t)||a){if(o&&!a){"single"===s.brushMode&&Hx(t);var l=b(s);l.brushType=iw(l.brushType,o),l.panelId=!0===o?null:o.panelId,a=t._creatingCover=Ox(t,l),t._covers.push(a)}if(a){var h=ow[iw(t._brushType,o)];a.__brushOption.range=h.getCreatingRange(Jx(t,a,t._track)),i&&(zx(t,a),h.updateCommon(t,a)),Ex(t,a),r={isEnd:i}}}else i&&"single"===s.brushMode&&s.removeOnClick&&Fx(t,e,n)&&Hx(t)&&(r={isEnd:i,removeOnClick:!0});return r}function iw(t,e){return"auto"===t?e.defaultBrushType:t}Lx.prototype={constructor:Lx,enableBrush:function(t){return this._brushType&&function(t){var n=t._zr;(function(t,e,n){var i=P_(t);i[e]===n&&(i[e]=null)})(n,Tx,t._uid),yx(t._handlers,function(t,e){n.off(e,t)}),t._brushType=t._brushOption=null}(this),t.brushType&&function(t,e){var n=t._zr;t._enableGlobalPan||function(t,e,n){P_(t)[e]=n}(n,Tx,t._uid);yx(t._handlers,function(t,e){n.on(e,t)}),t._brushType=e.brushType,t._brushOption=m(b(kx),e,!0)}(this,t),this},setPanels:function(t){if(t&&t.length){var e=this._panels={};A(t,function(t){e[t.panelId]=b(t)})}else this._panels=null;return this},mount:function(t){t=t||{},this._enableGlobalPan=t.enableGlobalPan;var e=this.group;return this._zr.add(e),e.attr({position:t.position||[0,0],rotation:t.rotation||0,scale:t.scale||[1,1]}),this._transform=e.getLocalTransform(),this},eachCover:function(t,e){yx(this._covers,t,e)},updateCovers:function(r){r=D(r,function(t){return m(b(kx),t,!0)});var n="\0-brush-index-",a=this._covers,o=this._covers=[],s=this,l=this._creatingCover;return new Zd(a,r,function(t,e){return i(t.__brushOption,e)},i).add(t).update(t).remove(function(t){a[t]!==l&&s.group.remove(a[t])}).execute(),this;function i(t,e){return(null!=t.id?t.id:n+e)+"-"+t.brushType}function t(t,e){var n=r[t];if(null!=e&&a[e]===l)o[t]=a[e];else{var i=o[t]=null!=e?(a[e].__brushOption=n,a[e]):zx(s,Ox(s,n));Rx(s,i)}}},unmount:function(){return this.enableBrush(!1),Hx(this),this._zr.remove(this.group),this},dispose:function(){this.unmount(),this.off()}},S(Lx,It);var rw={mousedown:function(t){if(this._dragging)aw.call(this,t);else if(!t.target||!t.target.draggable){tw(t);var e=this.group.transformCoordToLocal(t.offsetX,t.offsetY);this._creatingCover=null,(this._creatingPanel=Fx(this,t,e))&&(this._dragging=!0,this._track=[e.slice()])}},mousemove:function(t){var e=this.group.transformCoordToLocal(t.offsetX,t.offsetY);if(function(t,e,n){if(t._brushType){var i=t._zr,r=t._covers,a=Fx(t,e,n);if(!t._dragging)for(var o=0;o<r.length;o++){var s=r[o].__brushOption;if(a&&(!0===a||s.panelId===a.panelId)&&ow[s.brushType].contain(r[o],n[0],n[1]))return}a&&i.setCursorStyle("crosshair")}}(this,t,e),this._dragging){tw(t);var n=nw(this,t,e,!1);n&&Wx(this,n)}},mouseup:aw};function aw(t){if(this._dragging){tw(t);var e=this.group.transformCoordToLocal(t.offsetX,t.offsetY),n=nw(this,t,e,!0);this._dragging=!1,this._track=[],this._creatingCover=null,n&&Wx(this,n)}}var ow={lineX:sw(0),lineY:sw(1),rect:{createCover:function(t,e){return Zx(vx($x,function(t){return t},function(t){return t}),t,e,["w","e","n","s","se","sw","ne","nw"])},getCreatingRange:function(t){var e=Gx(t);return qx(e[1][0],e[1][1],e[0][0],e[0][1])},updateCoverShape:function(t,e,n,i){Ux(t,e,n,i)},updateCommon:Xx,contain:ew},polygon:{createCover:function(t,e){var n=new yn;return n.add(new ko({name:"main",style:jx(e),silent:!0})),n},getCreatingRange:function(t){return t},endCreating:function(t,e){e.remove(e.childAt(0)),e.add(new Do({name:"main",draggable:!0,drift:vx(Kx,t,e),ondragend:vx(Wx,t,{isEnd:!0})}))},updateCoverShape:function(t,e,n,i){e.childAt(0).setShape({points:Jx(t,e,n)})},updateCommon:Xx,contain:ew}};function sw(l){return{createCover:function(t,e){return Zx(vx($x,function(t){var e=[t,[0,100]];return l&&e.reverse(),e},function(t){return t[l]}),t,e,[["w","e"],["n","s"]][l])},getCreatingRange:function(t){var e=Gx(t);return[xx(e[0][l],e[1][l]),bx(e[0][l],e[1][l])]},updateCoverShape:function(t,e,n,i){var r,a=Vx(t,e);if(!0!==a&&a.getLinearBrushOtherExtent)r=a.getLinearBrushOtherExtent(l,t._transform);else{var o=t._zr;r=[0,[o.getWidth(),o.getHeight()][1-l]]}var s=[n,r];l&&s.reverse(),Ux(t,e,s,i)},updateCommon:Xx,contain:ew}}var lw={axisPointer:1,tooltip:1,brush:1};function hw(i,r,a){return i=uw(i),function(t,e,n){return i.contain(e[0],e[1])&&!function(t,e,n){var i=e.getComponentByElement(t.topTarget),r=i&&i.coordinateSystem;return i&&i!==n&&!lw[i.mainType]&&r&&r.model!==n}(t,r,a)}}function uw(t){return vn.create(t)}var cw=A,dw=x,fw=P,pw=["dataToPoint","pointToData"],gw=["grid","xAxis","yAxis","geo","graph","polar","radiusAxis","angleAxis","bmap"];function mw(t,e,n){var i=this._targetInfoList=[],r={},a=_w(e,t);cw(xw,function(t,e){n&&n.include&&!(0<=dw(n.include,e))||t(a,i,r)})}var vw=mw.prototype;function yw(t){return t[0]>t[1]&&t.reverse(),t}function _w(t,e){return Cr(t,e,{includeMainTypes:gw})}vw.setOutputRanges=function(t,e){this.matchOutputRanges(t,e,function(t,e,n){if((t.coordRanges||(t.coordRanges=[])).push(e),!t.coordRange){t.coordRange=e;var i=Sw[t.brushType](0,n,e);t.__rangeOffset={offset:Iw[t.brushType](i.values,t.range,[1,1]),xyMinMax:i.xyMinMax}}})},vw.matchOutputRanges=function(t,i,r){cw(t,function(n){var t=this.findTargetInfo(n,i);t&&!0!==t&&A(t.coordSyses,function(t){var e=Sw[n.brushType](1,t,n.range);r(n,e.values,t,i)})},this)},vw.setInputRanges=function(t,r){cw(t,function(t){var e=this.findTargetInfo(t,r);if(t.range=t.range||[],e&&!0!==e){t.panelId=e.panelId;var n=Sw[t.brushType](0,e.coordSys,t.coordRange),i=t.__rangeOffset;t.range=i?Iw[t.brushType](n.values,i.offset,function(t,e){var n=Tw(t),i=Tw(e),r=[n[0]/i[0],n[1]/i[1]];return isNaN(r[0])&&(r[0]=1),isNaN(r[1])&&(r[1]=1),r}(n.xyMinMax,i.xyMinMax)):n.values}},this)},vw.makePanelOpts=function(n,i){return D(this._targetInfoList,function(t){var e=t.getPanelRect();return{panelId:t.panelId,defaultBrushType:i&&i(t),clipPath:function(n){return n=uw(n),function(t,e){return Ws(t,n)}}(e),isTargetByCursor:hw(e,n,t.coordSysModel),getLinearBrushOtherExtent:function(r,a){return r=uw(r),function(t){var e=null!=a?a:t,n=e?r.width:r.height,i=e?r.x:r.y;return[i,i+(n||0)]}}(e)}})},vw.controlSeries=function(t,e,n){var i=this.findTargetInfo(t,n);return!0===i||i&&0<=dw(i.coordSyses,e.coordinateSystem)},vw.findTargetInfo=function(t,e){for(var n=this._targetInfoList,i=_w(e,t),r=0;r<n.length;r++){var a=n[r],o=t.panelId;if(o){if(a.panelId===o)return a}else for(r=0;r<ww.length;r++)if(ww[r](i,a))return a}return!0};var xw={grid:function(t,i){var r=t.xAxisModels,a=t.yAxisModels,e=t.gridModels,n=Q(),o={},s={};(r||a||e)&&(cw(r,function(t){var e=t.axis.grid.model;n.set(e.id,e),o[e.id]=!0}),cw(a,function(t){var e=t.axis.grid.model;n.set(e.id,e),s[e.id]=!0}),cw(e,function(t){n.set(t.id,t),o[t.id]=!0,s[t.id]=!0}),n.each(function(t){var e=t.coordinateSystem,n=[];cw(e.getCartesians(),function(t,e){(0<=dw(r,t.getAxis("x").model)||0<=dw(a,t.getAxis("y").model))&&n.push(t)}),i.push({panelId:"grid--"+t.id,gridModel:t,coordSysModel:t,coordSys:n[0],coordSyses:n,getPanelRect:bw.grid,xAxisDeclared:o[t.id],yAxisDeclared:s[t.id]})}))},geo:function(t,n){cw(t.geoModels,function(t){var e=t.coordinateSystem;n.push({panelId:"geo--"+t.id,geoModel:t,coordSysModel:t,coordSys:e,coordSyses:[e],getPanelRect:bw.geo})})}},ww=[function(t,e){var n=t.xAxisModel,i=t.yAxisModel,r=t.gridModel;return!r&&n&&(r=n.axis.grid.model),!r&&i&&(r=i.axis.grid.model),r&&r===e.gridModel},function(t,e){var n=t.geoModel;return n&&n===e.geoModel}],bw={grid:function(){return this.coordSys.grid.getRect().clone()},geo:function(){var t=this.coordSys,e=t.getBoundingRect().clone();return e.applyTransform(Bs(t)),e}},Sw={lineX:fw(Mw,0),lineY:fw(Mw,1),rect:function(t,e,n){var i=e[pw[t]]([n[0][0],n[1][0]]),r=e[pw[t]]([n[0][1],n[1][1]]),a=[yw([i[0],r[0]]),yw([i[1],r[1]])];return{values:a,xyMinMax:a}},polygon:function(n,i,t){var r=[[1/0,-1/0],[1/0,-1/0]];return{values:D(t,function(t){var e=i[pw[n]](t);return r[0][0]=Math.min(r[0][0],e[0]),r[1][0]=Math.min(r[1][0],e[1]),r[0][1]=Math.max(r[0][1],e[0]),r[1][1]=Math.max(r[1][1],e[1]),e}),xyMinMax:r}}};function Mw(t,e,n,i){var r=n.getAxis(["x","y"][t]),a=yw(D([0,1],function(t){return e?r.coordToData(r.toLocalCoord(i[t])):r.toGlobalCoord(r.dataToCoord(i[t]))})),o=[];return o[t]=a,o[1-t]=[NaN,NaN],{values:a,xyMinMax:o}}var Iw={lineX:fw(Cw,0),lineY:fw(Cw,1),rect:function(t,e,n){return[[t[0][0]-n[0]*e[0][0],t[0][1]-n[0]*e[0][1]],[t[1][0]-n[1]*e[1][0],t[1][1]-n[1]*e[1][1]]]},polygon:function(t,n,i){return D(t,function(t,e){return[t[0]-i[0]*n[e][0],t[1]-i[1]*n[e][1]]})}};function Cw(t,e,n,i){return[e[0]-i[t]*n[0],e[1]-i[t]*n[1]]}function Tw(t){return t?[t[0][1]-t[0][0],t[1][1]-t[1][0]]:[NaN,NaN]}var Aw=A,Dw="\0_ec_hist_store";function kw(t){var e=t[Dw];return e=e||(t[Dw]=[{}])}g_.extend({type:"dataZoom.select"}),y_.extend({type:"dataZoom.select"});var Pw=$u.toolbox.dataZoom,Lw=A;function Ow(t,e,n){(this._brushController=new Lx(n.getZr())).on("brush",k(this._onBrush,this)).mount(),this._isZoomActive}Ow.defaultOption={show:!0,icon:{zoom:"M0,13.5h26.9 M13.5,26.9V0 M32.1,13.5H58V58H13.5 V32.1",back:"M22,1.4L9.9,13.5l12.3,12.3 M10.3,13.5H54.9v44.6 H10.3v-26"},title:b(Pw.title)};var zw=Ow.prototype;zw.render=function(t,e,n,i){this.model=t,this.ecModel=e,this.api=n,function(t,e,n,i,r){var a=n._isZoomActive;i&&"takeGlobalCursor"===i.type&&(a="dataZoomSelect"===i.key&&i.dataZoomSelectActive);n._isZoomActive=a,t.setIconStatus("zoom",a?"emphasis":"normal");var o=new mw(Nw(t.option),e,{include:["grid"]});n._brushController.setPanels(o.makePanelOpts(r,function(t){return t.xAxisDeclared&&!t.yAxisDeclared?"lineX":!t.xAxisDeclared&&t.yAxisDeclared?"lineY":"rect"})).enableBrush(!!a&&{brushType:"auto",brushStyle:{lineWidth:0,fill:"rgba(0,0,0,0.2)"}})}(t,e,this,i,n),function(t,e){t.setIconStatus("back",1<function(t){return kw(t).length}(e)?"emphasis":"normal")}(t,e)},zw.onclick=function(t,e,n){Ew[n].call(this)},zw.remove=function(t,e){this._brushController.unmount()},zw.dispose=function(t,e){this._brushController.dispose()};var Ew={zoom:function(){var t=!this._isZoomActive;this.api.dispatchAction({type:"takeGlobalCursor",key:"dataZoomSelect",dataZoomSelectActive:t})},back:function(){this._dispatchZoomAction(function(t){var i=kw(t),e=i[i.length-1];1<i.length&&i.pop();var r={};return Aw(e,function(t,e){for(var n=i.length-1;0<=n;n--){if(t=i[n][e]){r[e]=t;break}}}),r}(this.ecModel))}};function Nw(e){var n={};return A(["xAxisIndex","yAxisIndex"],function(t){n[t]=e[t],null==n[t]&&(n[t]="all"),!1!==n[t]&&"none"!==n[t]||(n[t]=[])}),n}zw._onBrush=function(t,e){if(e.isEnd&&t.length){var s={},l=this.ecModel;this._brushController.updateCovers([]),new mw(Nw(this.model.option),l,{include:["grid"]}).matchOutputRanges(t,l,function(t,e,n){if("cartesian2d"===n.type){var i=t.brushType;"rect"===i?(r("x",n,e[0]),r("y",n,e[1])):r({lineX:"x",lineY:"y"}[i],n,e)}}),function(a,t){var o=kw(a);Aw(t,function(t,e){for(var n=o.length-1;0<=n;n--){if(o[n][e])break}if(n<0){var i=a.queryComponents({mainType:"dataZoom",subType:"select",id:e})[0];if(i){var r=i.getPercentRange();o[0][e]={dataZoomId:e,start:r[0],end:r[1]}}}}),o.push(t)}(l,s),this._dispatchZoomAction(s)}function r(t,e,n){var i=e.getAxis(t),r=i.model,a=function(e,n,t){var i;return t.eachComponent({mainType:"dataZoom",subType:"select"},function(t){t.getAxisModel(e,n.componentIndex)&&(i=t)}),i}(t,r,l),o=a.findRepresentativeAxisProxy(r).getMinMaxSpan();null==o.minValueSpan&&null==o.maxValueSpan||(n=o_(0,n.slice(),i.scale.getExtent(),0,o.minValueSpan,o.maxValueSpan)),a&&(s[a.id]={dataZoomId:a.id,startValue:n[0],endValue:n[1]})}},zw._dispatchZoomAction=function(t){var n=[];Lw(t,function(t,e){n.push(b(t))}),n.length&&this.api.dispatchAction({type:"dataZoom",from:this.uid,batch:n})},J_("dataZoom",Ow),Ld(function(o){if(o){var s=o.dataZoom||(o.dataZoom=[]);O(s)||(o.dataZoom=s=[s]);var t=o.toolbox;if(t&&(O(t)&&(t=t[0]),t&&t.feature)){var e=t.feature.dataZoom;n("xAxis",e),n("yAxis",e)}}function n(i,t){if(t){var r=i+"Index",a=t[r];null==a||"all"===a||O(a)||(a=!1===a||"none"===a?[]:[a]),function(t,e){var n=o[t];O(n)||(n=n?[n]:[]);Lw(n,e)}(i,function(t,e){if(null==a||"all"===a||-1!==x(a,e)){var n={type:"select",$fromToolbox:!0,id:"\0_ec_\0toolbox-dataZoom_"+i+e};n[r]=e,s.push(n)}})}}});var Rw=$u.toolbox.restore;function Bw(t){this.model=t}Bw.defaultOption={show:!0,icon:"M3.8,33.4 M47,18.9h9.8V8.7 M56.3,20.1 C52.1,9,40.5,0.6,26.8,2.1C12.6,3.7,1.6,16.2,2.1,30.6 M13,41.1H3.1v10.2 M3.7,39.9c4.2,11.1,15.8,19.5,29.5,18 c14.2-1.6,25.2-14.1,24.7-28.5",title:Rw.title},Bw.prototype.onclick=function(t,e,n){!function(t){t[Dw]=null}(t),e.dispatchAction({type:"restore",from:this.uid})},J_("restore",Bw),zd({type:"restore",event:"restore",update:"prepareAndUpdate"},function(t,e){e.resetOption("recreate")});var Fw,Vw="urn:schemas-microsoft-com:vml",Hw="undefined"==typeof window?null:window,Ww=!1,Gw=Hw&&Hw.document;function Zw(t){return Fw(t)}if(Gw&&!v.canvasSupported)try{Gw.namespaces.zrvml||Gw.namespaces.add("zrvml",Vw),Fw=function(t){return Gw.createElement("<zrvml:"+t+' class="zrvml">')}}catch(t){Fw=function(t){return Gw.createElement("<"+t+' xmlns="'+Vw+'" class="zrvml">')}}var Uw,Xw=Ea.CMD,Yw=Math.round,jw=Math.sqrt,qw=Math.abs,$w=Math.cos,Kw=Math.sin,Qw=Math.max;if(!v.canvasSupported){var Jw=",",tb="progid:DXImageTransform.Microsoft",eb=21600,nb=eb/2,ib=function(t){t.style.cssText="position:absolute;left:0;top:0;width:1px;height:1px;",t.coordsize=eb+","+eb,t.coordorigin="0,0"},rb=function(t,e,n){return"rgb("+[t,e,n].join(",")+")"},ab=function(t,e){e&&t&&e.parentNode!==t&&t.appendChild(e)},ob=function(t,e){e&&t&&e.parentNode===t&&t.removeChild(e)},sb=function(t,e,n){return 1e5*(parseFloat(t)||0)+1e3*(parseFloat(e)||0)+n},lb=function(t,e){return"string"==typeof t?0<=t.lastIndexOf("%")?parseFloat(t)/100*e:parseFloat(t):t},hb=function(t,e,n){var i=ke(e);n=+n,isNaN(n)&&(n=1),i&&(t.color=rb(i[0],i[1],i[2]),t.opacity=n*i[3])},ub=function(t,e,n,i){var r="fill"===e,a=t.getElementsByTagName(e)[0];null!=n[e]&&"none"!==n[e]&&(r||!r&&n.lineWidth)?(t[r?"filled":"stroked"]="true",n[e]instanceof Ho&&ob(t,a),a=a||Zw(e),r?function(t,e,n){var i,r,a=e.fill;if(null!=a)if(a instanceof Ho){var o,s=0,l=[0,0],h=0,u=1,c=n.getBoundingRect(),d=c.width,f=c.height;if("linear"===a.type){o="gradient";var p=n.transform,g=[a.x*d,a.y*f],m=[a.x2*d,a.y2*f];p&&(yt(g,g,p),yt(m,m,p));var v=m[0]-g[0],y=m[1]-g[1];(s=180*Math.atan2(v,y)/Math.PI)<0&&(s+=360),s<1e-6&&(s=0)}else{o="gradientradial";g=[a.x*d,a.y*f],p=n.transform;var _=n.scale,x=d,w=f;l=[(g[0]-c.x)/x,(g[1]-c.y)/w],p&&yt(g,g,p),x/=_[0]*eb,w/=_[1]*eb;var b=Qw(x,w);h=0/b,u=2*a.r/b-h}var S=a.colorStops.slice();S.sort(function(t,e){return t.offset-e.offset});for(var M=S.length,I=[],C=[],T=0;T<M;T++){var A=S[T],D=(i=A.color,void 0,r=ke(i),[rb(r[0],r[1],r[2]),r[3]]);C.push(A.offset*u+h+" "+D[0]),0!==T&&T!==M-1||I.push(D)}if(2<=M){var k=I[0][0],P=I[1][0],L=I[0][1]*e.opacity,O=I[1][1]*e.opacity;t.type=o,t.method="none",t.focus="100%",t.angle=s,t.color=k,t.color2=P,t.colors=C.join(","),t.opacity=O,t.opacity2=L}"radial"===o&&(t.focusposition=l.join(","))}else hb(t,a,e.opacity)}(a,n,i):function(t,e){e.lineDash&&(t.dashstyle=e.lineDash.join(" ")),null==e.stroke||e.stroke instanceof Ho||hb(t,e.stroke,e.opacity)}(a,n),ab(t,a)):(t[r?"filled":"stroked"]="false",ob(t,a))},cb=[[],[],[]];no.prototype.brushVML=function(t){var e=this.style,n=this._vmlEl;n||(n=Zw("shape"),ib(n),this._vmlEl=n),ub(n,"fill",e,this),ub(n,"stroke",e,this);var i=this.transform,r=null!=i,a=n.getElementsByTagName("stroke")[0];if(a){var o=e.lineWidth;if(r&&!e.strokeNoScale){var s=i[0]*i[3]-i[1]*i[2];o*=jw(qw(s))}a.weight=o+"px"}var l=this.path||(this.path=new Ea);this.__dirtyPath&&(l.beginPath(),l.subPixelOptimize=!1,this.buildPath(l,this.shape),l.toStatic(),this.__dirtyPath=!1),n.path=function(t,e){var n,i,r,a,o,s,l=Xw.M,h=Xw.C,u=Xw.L,c=Xw.A,d=Xw.Q,f=[],p=t.data,g=t.len();for(a=0;a<g;){switch(i="",n=0,r=p[a++]){case l:i=" m ",n=1,o=p[a++],s=p[a++],cb[0][0]=o,cb[0][1]=s;break;case u:i=" l ",n=1,o=p[a++],s=p[a++],cb[0][0]=o,cb[0][1]=s;break;case d:case h:i=" c ",n=3;var m,v,y=p[a++],_=p[a++],x=p[a++],w=p[a++];r===d?(x=((m=x)+2*y)/3,w=((v=w)+2*_)/3,y=(o+2*y)/3,_=(s+2*_)/3):(m=p[a++],v=p[a++]),cb[0][0]=y,cb[0][1]=_,cb[1][0]=x,cb[1][1]=w,o=cb[2][0]=m,s=cb[2][1]=v;break;case c:var b=0,S=0,M=1,I=1,C=0;e&&(b=e[4],S=e[5],M=jw(e[0]*e[0]+e[1]*e[1]),I=jw(e[2]*e[2]+e[3]*e[3]),C=Math.atan2(-e[1]/I,e[0]/M));var T=p[a++],A=p[a++],D=p[a++],k=p[a++],P=p[a++]+C,L=p[a++]+P+C;a++;var O=p[a++],z=T+$w(P)*D,E=A+Kw(P)*k,N=(y=T+$w(L)*D,_=A+Kw(L)*k,O?" wa ":" at ");Math.abs(z-y)<1e-4&&(.01<Math.abs(L-P)?O&&(z+=.0125):Math.abs(E-A)<1e-4?O&&z<T||!O&&T<z?_-=.0125:_+=.0125:O&&E<A||!O&&A<E?y+=.0125:y-=.0125),f.push(N,Yw(((T-D)*M+b)*eb-nb),Jw,Yw(((A-k)*I+S)*eb-nb),Jw,Yw(((T+D)*M+b)*eb-nb),Jw,Yw(((A+k)*I+S)*eb-nb),Jw,Yw((z*M+b)*eb-nb),Jw,Yw((E*I+S)*eb-nb),Jw,Yw((y*M+b)*eb-nb),Jw,Yw((_*I+S)*eb-nb)),o=y,s=_;break;case Xw.R:var R=cb[0],B=cb[1];R[0]=p[a++],R[1]=p[a++],B[0]=R[0]+p[a++],B[1]=R[1]+p[a++],e&&(yt(R,R,e),yt(B,B,e)),R[0]=Yw(R[0]*eb-nb),B[0]=Yw(B[0]*eb-nb),R[1]=Yw(R[1]*eb-nb),B[1]=Yw(B[1]*eb-nb),f.push(" m ",R[0],Jw,R[1]," l ",B[0],Jw,R[1]," l ",B[0],Jw,B[1]," l ",R[0],Jw,B[1]);break;case Xw.Z:f.push(" x ")}if(0<n){f.push(i);for(var F=0;F<n;F++){var V=cb[F];e&&yt(V,V,e),f.push(Yw(V[0]*eb-nb),Jw,Yw(V[1]*eb-nb),F<n-1?Jw:"")}}}return f.join("")}(l,this.transform),n.style.zIndex=sb(this.zlevel,this.z,this.z2),ab(t,n),null!=e.text?this.drawRectText(t,this.getBoundingRect()):this.removeRectText(t)},no.prototype.onRemove=function(t){ob(t,this._vmlEl),this.removeRectText(t)},no.prototype.onAdd=function(t){ab(t,this._vmlEl),this.appendRectText(t)};Hi.prototype.brushVML=function(t){var e,n,i=this.style,r=i.image;if(function(t){return"object"==typeof t&&t.tagName&&"IMG"===t.tagName.toUpperCase()}(r)){var a=r.src;if(a===this._imageSrc)e=this._imageWidth,n=this._imageHeight;else{var o=r.runtimeStyle,s=o.width,l=o.height;o.width="auto",o.height="auto",e=r.width,n=r.height,o.width=s,o.height=l,this._imageSrc=a,this._imageWidth=e,this._imageHeight=n}r=a}else r===this._imageSrc&&(e=this._imageWidth,n=this._imageHeight);if(r){var h=i.x||0,u=i.y||0,c=i.width,d=i.height,f=i.sWidth,p=i.sHeight,g=i.sx||0,m=i.sy||0,v=f&&p,y=this._vmlEl;y||(y=Gw.createElement("div"),ib(y),this._vmlEl=y);var _,x=y.style,w=!1,b=1,S=1;if(this.transform&&(_=this.transform,b=jw(_[0]*_[0]+_[1]*_[1]),S=jw(_[2]*_[2]+_[3]*_[3]),w=_[1]||_[2]),w){var M=[h,u],I=[h+c,u],C=[h,u+d],T=[h+c,u+d];yt(M,M,_),yt(I,I,_),yt(C,C,_),yt(T,T,_);var A=Qw(M[0],I[0],C[0],T[0]),D=Qw(M[1],I[1],C[1],T[1]),k=[];k.push("M11=",_[0]/b,Jw,"M12=",_[2]/S,Jw,"M21=",_[1]/b,Jw,"M22=",_[3]/S,Jw,"Dx=",Yw(h*b+_[4]),Jw,"Dy=",Yw(u*S+_[5])),x.padding="0 "+Yw(A)+"px "+Yw(D)+"px 0",x.filter=tb+".Matrix("+k.join("")+", SizingMethod=clip)"}else _&&(h=h*b+_[4],u=u*S+_[5]),x.filter="",x.left=Yw(h)+"px",x.top=Yw(u)+"px";var P=this._imageEl,L=this._cropEl;P||(P=Gw.createElement("div"),this._imageEl=P);var O=P.style;if(v){if(e&&n)O.width=Yw(b*e*c/f)+"px",O.height=Yw(S*n*d/p)+"px";else{var z=new Image,E=this;z.onload=function(){z.onload=null,e=z.width,n=z.height,O.width=Yw(b*e*c/f)+"px",O.height=Yw(S*n*d/p)+"px",E._imageWidth=e,E._imageHeight=n,E._imageSrc=r},z.src=r}L||((L=Gw.createElement("div")).style.overflow="hidden",this._cropEl=L);var N=L.style;N.width=Yw((c+g*c/f)*b),N.height=Yw((d+m*d/p)*S),N.filter=tb+".Matrix(Dx="+-g*c/f*b+",Dy="+-m*d/p*S+")",L.parentNode||y.appendChild(L),P.parentNode!==L&&L.appendChild(P)}else O.width=Yw(b*c)+"px",O.height=Yw(S*d)+"px",y.appendChild(P),L&&L.parentNode&&(y.removeChild(L),this._cropEl=null);var R="",B=i.opacity;B<1&&(R+=".Alpha(opacity="+Yw(100*B)+") "),R+=tb+".AlphaImageLoader(src="+r+", SizingMethod=scale)",O.filter=R,y.style.zIndex=sb(this.zlevel,this.z,this.z2),ab(t,y),null!=i.text&&this.drawRectText(t,this.getBoundingRect())}},Hi.prototype.onRemove=function(t){ob(t,this._vmlEl),this._vmlEl=null,this._cropEl=null,this._imageEl=null,this.removeRectText(t)},Hi.prototype.onAdd=function(t){ab(t,this._vmlEl),this.appendRectText(t)};var db,fb="normal",pb={},gb=0,mb=document.createElement("div");Uw=function(t,e){var n=Gw;db||((db=n.createElement("div")).style.cssText="position:absolute;top:-20000px;left:0;padding:0;margin:0;border:none;white-space:pre;",Gw.body.appendChild(db));try{db.style.font=e}catch(t){}return db.innerHTML="",db.appendChild(n.createTextNode(t)),{width:db.offsetWidth}},ei["measureText"]=Uw;for(var vb=new vn,yb=function(t,e,n,i){var r=this.style;this.__dirty&&Si(r);var a=r.text;if(null!=a&&(a+=""),a){if(r.rich){var o=fi(a,r);a=[];for(var s=0;s<o.lines.length;s++){for(var l=o.lines[s].tokens,h=[],u=0;u<l.length;u++)h.push(l[u].text);a.push(h.join(""))}a=a.join("\n")}var c,d,f=r.textAlign,p=r.textVerticalAlign,g=function(t){var e=pb[t];if(!e){100<gb&&(gb=0,pb={});var n,i=mb.style;try{i.font=t,n=i.fontFamily.split(",")[0]}catch(t){}e={style:i.fontStyle||fb,variant:i.fontVariant||fb,weight:i.fontWeight||fb,size:0|parseFloat(i.fontSize||12),family:n||"Microsoft YaHei"},pb[t]=e,gb++}return e}(r.font),m=g.style+" "+g.variant+" "+g.weight+" "+g.size+'px "'+g.family+'"';n=n||ii(a,m,f,p,r.textPadding,r.textLineHeight);var v=this.transform;if(v&&!i&&(vb.copy(e),vb.applyTransform(v),e=vb),i)c=e.x,d=e.y;else{var y=r.textPosition;if(y instanceof Array)c=e.x+lb(y[0],e.width),d=e.y+lb(y[1],e.height),f=f||"left";else{var _=this.calculateTextPosition?this.calculateTextPosition({},r,e):oi({},r,e);c=_.x,d=_.y,f=f||_.textAlign,p=p||_.textVerticalAlign}}c=ri(c,n.width,f),d=ai(d,n.height,p),d+=n.height/2;var x,w,b,S=Zw,M=this._textVmlEl;M?w=(x=(b=M.firstChild).nextSibling).nextSibling:(M=S("line"),x=S("path"),w=S("textpath"),b=S("skew"),w.style["v-text-align"]="left",ib(M),x.textpathok=!0,w.on=!0,M.from="0 0",M.to="1000 0.05",ab(M,b),ab(M,x),ab(M,w),this._textVmlEl=M);var I=[c,d],C=M.style;v&&i?(yt(I,I,v),b.on=!0,b.matrix=v[0].toFixed(3)+Jw+v[2].toFixed(3)+Jw+v[1].toFixed(3)+Jw+v[3].toFixed(3)+",0,0",b.offset=(Yw(I[0])||0)+","+(Yw(I[1])||0),b.origin="0 0",C.left="0px",C.top="0px"):(b.on=!1,C.left=Yw(c)+"px",C.top=Yw(d)+"px"),w.string=function(t){return String(t).replace(/&/g,"&amp;").replace(/"/g,"&quot;")}(a);try{w.style.font=m}catch(t){}ub(M,"fill",{fill:r.textFill,opacity:r.opacity},this),ub(M,"stroke",{stroke:r.textStroke,opacity:r.opacity,lineDash:r.lineDash||null},this),M.style.zIndex=sb(this.zlevel,this.z,this.z2),ab(t,M)}},_b=function(t){ob(t,this._textVmlEl),this._textVmlEl=null},xb=function(t){ab(t,this._textVmlEl)},wb=[Bi,Vi,Hi,no,wo],bb=0;bb<wb.length;bb++){var Sb=wb[bb].prototype;Sb.drawRectText=yb,Sb.removeRectText=_b,Sb.appendRectText=xb}wo.prototype.brushVML=function(t){var e=this.style;null!=e.text?this.drawRectText(t,{x:e.x||0,y:e.y||0,width:0,height:0},this.getBoundingRect(),!0):this.removeRectText(t)},wo.prototype.onRemove=function(t){this.removeRectText(t)},wo.prototype.onAdd=function(t){this.appendRectText(t)}}function Mb(t){return parseInt(t,10)}function Ib(t,e){!function(){if(!Ww&&Gw){Ww=!0;var t=Gw.styleSheets;t.length<31?Gw.createStyleSheet().addRule(".zrvml","behavior:url(#default#VML)"):t[0].addRule(".zrvml","behavior:url(#default#VML)")}}(),this.root=t,this.storage=e;var n=document.createElement("div"),i=document.createElement("div");n.style.cssText="display:inline-block;overflow:hidden;position:relative;width:300px;height:150px;",i.style.cssText="position:absolute;left:0;top:0;",t.appendChild(n),this._vmlRoot=i,this._vmlViewport=n,this.resize();var r=e.delFromStorage,a=e.addToStorage;e.delFromStorage=function(t){r.call(e,t),t&&t.onRemove&&t.onRemove(i)},e.addToStorage=function(t){t.onAdd&&t.onAdd(i),a.call(e,t)},this._firstPaint=!0}Ib.prototype={constructor:Ib,getType:function(){return"vml"},getViewportRoot:function(){return this._vmlViewport},getViewportRootOffset:function(){var t=this.getViewportRoot();if(t)return{offsetLeft:t.offsetLeft||0,offsetTop:t.offsetTop||0}},refresh:function(){var t=this.storage.getDisplayList(!0,!0);this._paintList(t)},_paintList:function(t){for(var e=this._vmlRoot,n=0;n<t.length;n++){var i=t[n];i.invisible||i.ignore?(i.__alreadyNotVisible||i.onRemove(e),i.__alreadyNotVisible=!0):(i.__alreadyNotVisible&&i.onAdd(e),i.__alreadyNotVisible=!1,i.__dirty&&(i.beforeBrush&&i.beforeBrush(),(i.brushVML||i.brush).call(i,e),i.afterBrush&&i.afterBrush())),i.__dirty=!1}this._firstPaint&&(this._vmlViewport.appendChild(e),this._firstPaint=!1)},resize:function(t,e){t=null==t?this._getWidth():t,e=null==e?this._getHeight():e;if(this._width!==t||this._height!==e){this._width=t,this._height=e;var n=this._vmlViewport.style;n.width=t+"px",n.height=e+"px"}},dispose:function(){this.root.innerHTML="",this._vmlRoot=this._vmlViewport=this.storage=null},getWidth:function(){return this._width},getHeight:function(){return this._height},clear:function(){this._vmlViewport&&this.root.removeChild(this._vmlViewport)},_getWidth:function(){var t=this.root,e=t.currentStyle;return(t.clientWidth||Mb(e.width))-Mb(e.paddingLeft)-Mb(e.paddingRight)|0},_getHeight:function(){var t=this.root,e=t.currentStyle;return(t.clientHeight||Mb(e.height))-Mb(e.paddingTop)-Mb(e.paddingBottom)|0}},A(["getLayer","insertLayer","eachLayer","eachBuiltinLayer","eachOtherLayer","getLayers","modLayer","delLayer","clearLayer","toDataURL","pathToImage"],function(t){Ib.prototype[t]=function(t){return function(){on('In IE8.0 VML mode painter not support method "'+t+'"')}}(t)}),lr("vml",Ib);function Cb(t){return document.createElementNS("http://www.w3.org/2000/svg",t)}var Tb=Ea.CMD,Ab=Array.prototype.join,Db="none",kb=Math.round,Pb=Math.sin,Lb=Math.cos,Ob=Math.PI,zb=2*Math.PI,Eb=180/Ob,Nb=1e-4;function Rb(t){return kb(1e4*t)/1e4}function Bb(t){return t<Nb&&-Nb<t}function Fb(t,e){e&&Vb(t,"transform","matrix("+Ab.call(e,",")+")")}function Vb(t,e,n){n&&("linear"===n.type||"radial"===n.type)||t.setAttribute(e,n)}function Hb(t,e,n,i){if(function(t,e){var n=e?t.textFill:t.fill;return null!=n&&n!==Db}(e,n)){var r=n?e.textFill:e.fill;Vb(t,"fill",r="transparent"===r?Db:r),Vb(t,"fill-opacity",null!=e.fillOpacity?e.fillOpacity*e.opacity:e.opacity)}else Vb(t,"fill",Db);if(function(t,e){var n=e?t.textStroke:t.stroke;return null!=n&&n!==Db}(e,n)){var a=n?e.textStroke:e.stroke;Vb(t,"stroke",a="transparent"===a?Db:a),Vb(t,"stroke-width",(n?e.textStrokeWidth:e.lineWidth)/(!n&&e.strokeNoScale?i.getLineScale():1)),Vb(t,"paint-order",n?"stroke":"fill"),Vb(t,"stroke-opacity",null!=e.strokeOpacity?e.strokeOpacity:e.opacity),e.lineDash?(Vb(t,"stroke-dasharray",e.lineDash.join(",")),Vb(t,"stroke-dashoffset",kb(e.lineDashOffset||0))):Vb(t,"stroke-dasharray",""),e.lineCap&&Vb(t,"stroke-linecap",e.lineCap),e.lineJoin&&Vb(t,"stroke-linejoin",e.lineJoin),e.miterLimit&&Vb(t,"stroke-miterlimit",e.miterLimit)}else Vb(t,"stroke",Db)}var Wb={};Wb.brush=function(t){var e=t.style,n=t.__svgEl;n||(n=Cb("path"),t.__svgEl=n),t.path||t.createPathProxy();var i=t.path;if(t.__dirtyPath){i.beginPath(),i.subPixelOptimize=!1,t.buildPath(i,t.shape),t.__dirtyPath=!1;var r=function(t){for(var e=[],n=t.data,i=t.len(),r=0;r<i;){var a="",o=0;switch(n[r++]){case Tb.M:a="M",o=2;break;case Tb.L:a="L",o=2;break;case Tb.Q:a="Q",o=4;break;case Tb.C:a="C",o=6;break;case Tb.A:var s=n[r++],l=n[r++],h=n[r++],u=n[r++],c=n[r++],d=n[r++],f=n[r++],p=n[r++],g=Math.abs(d),m=Bb(g-zb)&&!Bb(g),v=!1;v=zb<=g||!Bb(g)&&(-Ob<d&&d<0||Ob<d)==!!p;var y=Rb(s+h*Lb(c)),_=Rb(l+u*Pb(c));m&&(d=p?zb-1e-4:1e-4-zb,v=!0,9===r&&e.push("M",y,_));var x=Rb(s+h*Lb(c+d)),w=Rb(l+u*Pb(c+d));e.push("A",Rb(h),Rb(u),kb(f*Eb),+v,+p,x,w);break;case Tb.Z:a="Z";break;case Tb.R:x=Rb(n[r++]),w=Rb(n[r++]);var b=Rb(n[r++]),S=Rb(n[r++]);e.push("M",x,w,"L",x+b,w,"L",x+b,w+S,"L",x,w+S,"L",x,w)}a&&e.push(a);for(var M=0;M<o;M++)e.push(Rb(n[r++]))}return e.join(" ")}(i);r.indexOf("NaN")<0&&Vb(n,"d",r)}Hb(n,e,!1,t),Fb(n,t.transform),null!=e.text&&Yb(t,t.getBoundingRect())};var Gb={brush:function(t){var e=t.style,n=e.image;n instanceof HTMLImageElement&&(n=n.src);if(n){var i=e.x||0,r=e.y||0,a=e.width,o=e.height,s=t.__svgEl;s||(s=Cb("image"),t.__svgEl=s),n!==t.__imageSrc&&(function(t,e,n){t.setAttributeNS("http://www.w3.org/1999/xlink",e,n)}(s,"href",n),t.__imageSrc=n),Vb(s,"width",a),Vb(s,"height",o),Vb(s,"x",i),Vb(s,"y",r),Fb(s,t.transform),null!=e.text&&Yb(t,t.getBoundingRect())}}},Zb={},Ub=new vn,Xb={},Yb=function(t,e,n){var i=t.style;t.__dirty&&Si(i);var r=i.text;if(null!=r){r+="";var a,o,s=t.__textSvgEl;s||(s=Cb("text"),t.__textSvgEl=s);var l=i.textPosition,h=i.textAlign||"left";"number"==typeof i.fontSize&&(i.fontSize+="px");var u=i.font||[i.fontStyle||"",i.fontWeight||"",i.fontSize||"",i.fontFamily||""].join(" ")||ti,c=i.textVerticalAlign,d=(n=ii(r,u,h,c,i.textPadding,i.textLineHeight)).lineHeight;if(l instanceof Array)a=e.x+l[0],o=e.y+l[1];else{var f=t.calculateTextPosition?t.calculateTextPosition(Xb,i,e):oi(Xb,i,e);a=f.x,o=f.y,c=f.textVerticalAlign,h=f.textAlign}jb(s,c),u&&(s.style.font=u);var p=i.textPadding;if(Vb(s,"x",a),Vb(s,"y",o),Hb(s,i,!0,t),t instanceof wo||t.style.transformText)Fb(s,t.transform);else{if(t.transform)Ub.copy(e),Ub.applyTransform(t.transform),e=Ub;else{var g=t.transformCoordToGlobal(e.x,e.y);e.x=g[0],e.y=g[1],t.transform=$t(qt())}var m=i.textOrigin;"center"===m?(a=n.width/2+a,o=n.height/2+o):m&&(a=m[0]+a,o=m[1]+o);var v=-i.textRotation||0,y=qt();te(y,y,v),Jt(y,y,g=[t.transform[4],t.transform[5]]),Fb(s,y)}var _=r.split("\n"),x=_.length,w=h;"left"===w?(w="start",p&&(a+=p[3])):"right"===w?(w="end",p&&(a-=p[1])):"center"===w&&(w="middle",p&&(a+=(p[3]-p[1])/2));var b=0;if("bottom"===c?(b=-n.height+d,p&&(b-=p[2])):"middle"===c?(b=(-n.height+d)/2,p&&(o+=(p[0]-p[2])/2)):p&&(b+=p[0]),t.__text!==r||t.__textFont!==u){var S=t.__tspanList||[];t.__tspanList=S;for(var M=0;M<x;M++){(C=S[M])?C.innerHTML="":(C=S[M]=Cb("tspan"),s.appendChild(C),jb(C,c),Vb(C,"text-anchor",w)),Vb(C,"x",a),Vb(C,"y",o+M*d+b),C.appendChild(document.createTextNode(_[M]))}for(;M<S.length;M++)s.removeChild(S[M]);S.length=x,t.__text=r,t.__textFont=u}else if(t.__tspanList.length){var I=t.__tspanList.length;for(M=0;M<I;++M){var C;(C=t.__tspanList[M])&&(Vb(C,"x",a),Vb(C,"y",o+M*d+b))}}}};function jb(t,e){switch(e){case"middle":Vb(t,"dominant-baseline","middle"),Vb(t,"alignment-baseline","middle");break;case"bottom":Vb(t,"dominant-baseline","ideographic"),Vb(t,"alignment-baseline","ideographic");break;default:Vb(t,"dominant-baseline","hanging"),Vb(t,"alignment-baseline","hanging")}}function qb(){}function $b(t,e){for(var n=0,i=e.length,r=0,a=0;n<i;n++){var o=e[n];if(o.removed){for(s=[],l=a;l<a+o.count;l++)s.push(l);o.indices=s,a+=o.count}else{for(var s=[],l=r;l<r+o.count;l++)s.push(l);o.indices=s,r+=o.count,o.added||(a+=o.count)}}return e}Zb.drawRectText=Yb,Zb.brush=function(t){var e=t.style;null!=e.text&&(e.textPosition=[0,0],Yb(t,{x:e.x||0,y:e.y||0,width:0,height:0},t.getBoundingRect()))},qb.prototype={diff:function(l,h,t){t=t||function(t,e){return t===e},this.equals=t;var u=this;l=l.slice();var c=(h=h.slice()).length,d=l.length,f=1,e=c+d,p=[{newPos:-1,components:[]}],n=this.extractCommon(p[0],h,l,0);if(p[0].newPos+1>=c&&d<=n+1){for(var i=[],r=0;r<h.length;r++)i.push(r);return[{indices:i,count:h.length}]}function a(){for(var t=-1*f;t<=f;t+=2){var e,n=p[t-1],i=p[t+1],r=(i?i.newPos:0)-t;n&&(p[t-1]=void 0);var a=n&&n.newPos+1<c,o=i&&0<=r&&r<d;if(a||o){if(!a||o&&n.newPos<i.newPos?(e={newPos:(s=i).newPos,components:s.components.slice(0)},u.pushComponent(e.components,void 0,!0)):((e=n).newPos++,u.pushComponent(e.components,!0,void 0)),r=u.extractCommon(e,h,l,t),e.newPos+1>=c&&d<=r+1)return $b(u,e.components,h,l);p[t]=e}else p[t]=void 0}var s;f++}for(;f<=e;){var o=a();if(o)return o}},pushComponent:function(t,e,n){var i=t[t.length-1];i&&i.added===e&&i.removed===n?t[t.length-1]={count:i.count+1,added:e,removed:n}:t.push({count:1,added:e,removed:n})},extractCommon:function(t,e,n,i){for(var r=e.length,a=n.length,o=t.newPos,s=o-i,l=0;o+1<r&&s+1<a&&this.equals(e[o+1],n[s+1]);)o++,s++,l++;return l&&t.components.push({count:l}),t.newPos=o,s},tokenize:function(t){return t.slice()},join:function(t){return t.slice()}};var Kb=new qb;function Qb(t,e,n,i,r){this._zrId=t,this._svgRoot=e,this._tagNames="string"==typeof n?[n]:n,this._markLabel=i,this._domName=r||"_dom",this.nextId=0}function Jb(t,e){Qb.call(this,t,e,["linearGradient","radialGradient"],"__gradient_in_use__")}function tS(t,e){Qb.call(this,t,e,"clipPath","__clippath_in_use__")}function eS(t,e){Qb.call(this,t,e,["filter"],"__filter_in_use__","_shadowDom")}function nS(t){return t&&(t.shadowBlur||t.shadowOffsetX||t.shadowOffsetY||t.textShadowBlur||t.textShadowOffsetX||t.textShadowOffsetY)}function iS(t){return parseInt(t,10)}function rS(t,e){return e&&t&&e.parentNode!==t}function aS(t,e,n){if(rS(t,e)&&n){var i=n.nextSibling;i?t.insertBefore(e,i):t.appendChild(e)}}function oS(t,e){if(rS(t,e)){var n=t.firstChild;n?t.insertBefore(e,n):t.appendChild(e)}}function sS(t,e){e&&t&&e.parentNode===t&&t.removeChild(e)}function lS(t){return t.__textSvgEl}function hS(t){return t.__svgEl}Qb.prototype.createElement=Cb,Qb.prototype.getDefs=function(t){var e=this._svgRoot,i=this._svgRoot.getElementsByTagName("defs");return 0===i.length?t?((i=e.insertBefore(this.createElement("defs"),e.firstChild)).contains||(i.contains=function(t){var e=i.children;if(!e)return!1;for(var n=e.length-1;0<=n;--n)if(e[n]===t)return!0;return!1}),i):null:i[0]},Qb.prototype.update=function(t,e){if(t){var n=this.getDefs(!1);if(t[this._domName]&&n.contains(t[this._domName]))"function"==typeof e&&e(t);else{var i=this.add(t);i&&(t[this._domName]=i)}}},Qb.prototype.addDom=function(t){this.getDefs(!0).appendChild(t)},Qb.prototype.removeDom=function(t){var e=this.getDefs(!1);e&&t[this._domName]&&(e.removeChild(t[this._domName]),t[this._domName]=null)},Qb.prototype.getDoms=function(){var n=this.getDefs(!1);if(!n)return[];var i=[];return A(this._tagNames,function(t){var e=n.getElementsByTagName(t);i=i.concat([].slice.call(e))}),i},Qb.prototype.markAllUnused=function(){var t=this.getDoms(),e=this;A(t,function(t){t[e._markLabel]="0"})},Qb.prototype.markUsed=function(t){t&&(t[this._markLabel]="1")},Qb.prototype.removeUnused=function(){var e=this.getDefs(!1);if(e){var t=this.getDoms(),n=this;A(t,function(t){"1"!==t[n._markLabel]&&e.removeChild(t)})}},Qb.prototype.getSvgProxy=function(t){return t instanceof no?Wb:t instanceof Hi?Gb:t instanceof wo?Zb:Wb},Qb.prototype.getTextSvgElement=function(t){return t.__textSvgEl},Qb.prototype.getSvgElement=function(t){return t.__svgEl},w(Jb,Qb),Jb.prototype.addWithoutUpdate=function(a,o){if(o&&o.style){var s=this;A(["fill","stroke"],function(t){if(o.style[t]&&("linear"===o.style[t].type||"radial"===o.style[t].type)){var e,n=o.style[t],i=s.getDefs(!0);n._dom?(e=n._dom,i.contains(n._dom)||s.addDom(e)):e=s.add(n),s.markUsed(o);var r=e.getAttribute("id");a.setAttribute(t,"url(#"+r+")")}})}},Jb.prototype.add=function(t){var e;if("linear"===t.type)e=this.createElement("linearGradient");else{if("radial"!==t.type)return on("Illegal gradient type."),null;e=this.createElement("radialGradient")}return t.id=t.id||this.nextId++,e.setAttribute("id","zr"+this._zrId+"-gradient-"+t.id),this.updateDom(t,e),this.addDom(e),e},Jb.prototype.update=function(n){var i=this;Qb.prototype.update.call(this,n,function(){var t=n.type,e=n._dom.tagName;"linear"===t&&"linearGradient"===e||"radial"===t&&"radialGradient"===e?i.updateDom(n,n._dom):(i.removeDom(n),i.add(n))})},Jb.prototype.updateDom=function(t,e){if("linear"===t.type)e.setAttribute("x1",t.x),e.setAttribute("y1",t.y),e.setAttribute("x2",t.x2),e.setAttribute("y2",t.y2);else{if("radial"!==t.type)return void on("Illegal gradient type.");e.setAttribute("cx",t.x),e.setAttribute("cy",t.y),e.setAttribute("r",t.r)}t.global?e.setAttribute("gradientUnits","userSpaceOnUse"):e.setAttribute("gradientUnits","objectBoundingBox"),e.innerHTML="";for(var n=t.colorStops,i=0,r=n.length;i<r;++i){var a=this.createElement("stop");a.setAttribute("offset",100*n[i].offset+"%");var o=n[i].color;if(o.indexOf(!1)){var s=ke(o)[3],l=Oe(o);a.setAttribute("stop-color","#"+l),a.setAttribute("stop-opacity",s)}else a.setAttribute("stop-color",n[i].color);e.appendChild(a)}t._dom=e},Jb.prototype.markUsed=function(t){if(t.style){var e=t.style.fill;e&&e._dom&&Qb.prototype.markUsed.call(this,e._dom),(e=t.style.stroke)&&e._dom&&Qb.prototype.markUsed.call(this,e._dom)}},w(tS,Qb),tS.prototype.update=function(t){var e=this.getSvgElement(t);e&&this.updateDom(e,t.__clipPaths,!1);var n=this.getTextSvgElement(t);n&&this.updateDom(n,t.__clipPaths,!0),this.markUsed(t)},tS.prototype.updateDom=function(t,e,n){if(e&&0<e.length){var i,r,a=this.getDefs(!0),o=e[0],s=n?"_textDom":"_dom";o[s]?(r=o[s].getAttribute("id"),i=o[s],a.contains(i)||a.appendChild(i)):(r="zr"+this._zrId+"-clip-"+this.nextId,++this.nextId,(i=this.createElement("clipPath")).setAttribute("id",r),a.appendChild(i),o[s]=i);var l=this.getSvgProxy(o);if(o.transform&&o.parent.invTransform&&!n){var h=Array.prototype.slice.call(o.transform);Qt(o.transform,o.parent.invTransform,o.transform),l.brush(o),o.transform=h}else l.brush(o);var u=this.getSvgElement(o);i.innerHTML="",i.appendChild(u.cloneNode()),t.setAttribute("clip-path","url(#"+r+")"),1<e.length&&this.updateDom(i,e.slice(1),n)}else t&&t.setAttribute("clip-path","none")},tS.prototype.markUsed=function(t){var e=this;t.__clipPaths&&A(t.__clipPaths,function(t){t._dom&&Qb.prototype.markUsed.call(e,t._dom),t._textDom&&Qb.prototype.markUsed.call(e,t._textDom)})},w(eS,Qb),eS.prototype.addWithoutUpdate=function(t,e){if(e&&nS(e.style)){var n,i=e.style;if(i._shadowDom)n=i._shadowDom,this.getDefs(!0).contains(i._shadowDom)||this.addDom(n);else n=this.add(e);this.markUsed(e);var r=n.getAttribute("id");t.style.filter="url(#"+r+")"}},eS.prototype.add=function(t){var e=this.createElement("filter"),n=t.style;return n._shadowDomId=n._shadowDomId||this.nextId++,e.setAttribute("id","zr"+this._zrId+"-shadow-"+n._shadowDomId),this.updateDom(t,e),this.addDom(e),e},eS.prototype.update=function(t,e){var n=e.style;if(nS(n)){var i=this;Qb.prototype.update.call(this,e,function(t){i.updateDom(e,t._shadowDom)})}else this.remove(t,n)},eS.prototype.remove=function(t,e){null!=e._shadowDomId&&(this.removeDom(e),t.style.filter="")},eS.prototype.updateDom=function(t,e){var n=e.getElementsByTagName("feDropShadow");n=0===n.length?this.createElement("feDropShadow"):n[0];var i,r,a,o,s=t.style,l=t.scale&&t.scale[0]||1,h=t.scale&&t.scale[1]||1;if(s.shadowBlur||s.shadowOffsetX||s.shadowOffsetY)i=s.shadowOffsetX||0,r=s.shadowOffsetY||0,a=s.shadowBlur,o=s.shadowColor;else{if(!s.textShadowBlur)return void this.removeDom(e,s);i=s.textShadowOffsetX||0,r=s.textShadowOffsetY||0,a=s.textShadowBlur,o=s.textShadowColor}n.setAttribute("dx",i/l),n.setAttribute("dy",r/h),n.setAttribute("flood-color",o);var u=a/2/l+" "+a/2/h;n.setAttribute("stdDeviation",u),e.setAttribute("x","-100%"),e.setAttribute("y","-100%"),e.setAttribute("width",Math.ceil(a/2*200)+"%"),e.setAttribute("height",Math.ceil(a/2*200)+"%"),e.appendChild(n),s._shadowDom=e},eS.prototype.markUsed=function(t){var e=t.style;e&&e._shadowDom&&Qb.prototype.markUsed.call(this,e._shadowDom)};function uS(t,e,n,i){this.root=t,this.storage=e,this._opts=n=I({},n||{});var r=Cb("svg");r.setAttribute("xmlns","http://www.w3.org/2000/svg"),r.setAttribute("version","1.1"),r.setAttribute("baseProfile","full"),r.style.cssText="user-select:none;position:absolute;left:0;top:0;",this.gradientManager=new Jb(i,r),this.clipPathManager=new tS(i,r),this.shadowManager=new eS(i,r);var a=document.createElement("div");a.style.cssText="overflow:hidden;position:relative",this._svgRoot=r,this._viewport=a,t.appendChild(a),a.appendChild(r),this.resize(n.width,n.height),this._visibleList=[]}uS.prototype={constructor:uS,getType:function(){return"svg"},getViewportRoot:function(){return this._viewport},getViewportRootOffset:function(){var t=this.getViewportRoot();if(t)return{offsetLeft:t.offsetLeft||0,offsetTop:t.offsetTop||0}},refresh:function(){var t=this.storage.getDisplayList(!0);this._paintList(t)},setBackgroundColor:function(t){this._viewport.style.background=t},_paintList:function(t){this.gradientManager.markAllUnused(),this.clipPathManager.markAllUnused(),this.shadowManager.markAllUnused();var e,n,i=this._svgRoot,r=this._visibleList,a=t.length,o=[];for(e=0;e<a;e++){var s=t[e],l=(n=s)instanceof no?Wb:n instanceof Hi?Gb:n instanceof wo?Zb:Wb,h=hS(s)||lS(s);s.invisible||(s.__dirty&&(l&&l.brush(s),this.clipPathManager.update(s),s.style&&(this.gradientManager.update(s.style.fill),this.gradientManager.update(s.style.stroke),this.shadowManager.update(h,s)),s.__dirty=!1),o.push(s))}var u,c=function(t,e,n){return Kb.diff(t,e,n)}(r,o);for(e=0;e<c.length;e++){if((p=c[e]).removed)for(var d=0;d<p.count;d++){h=hS(s=r[p.indices[d]]);var f=lS(s);sS(i,h),sS(i,f)}}for(e=0;e<c.length;e++){var p;if((p=c[e]).added)for(d=0;d<p.count;d++){h=hS(s=o[p.indices[d]]),f=lS(s);u?aS(i,h,u):oS(i,h),h?aS(i,f,h):u?aS(i,f,u):oS(i,f),aS(i,f,h),u=f||h||u,this.gradientManager.addWithoutUpdate(h,s),this.shadowManager.addWithoutUpdate(u,s),this.clipPathManager.markUsed(s)}else if(!p.removed)for(d=0;d<p.count;d++){u=h=lS(s=o[p.indices[d]])||hS(s)||u,this.gradientManager.markUsed(s),this.gradientManager.addWithoutUpdate(h,s),this.shadowManager.markUsed(s),this.shadowManager.addWithoutUpdate(h,s),this.clipPathManager.markUsed(s)}}this.gradientManager.removeUnused(),this.clipPathManager.removeUnused(),this.shadowManager.removeUnused(),this._visibleList=o},_getDefs:function(t){var i,e=this._svgRoot;return 0!==(i=this._svgRoot.getElementsByTagName("defs")).length?i[0]:t?((i=e.insertBefore(Cb("defs"),e.firstChild)).contains||(i.contains=function(t){var e=i.children;if(!e)return!1;for(var n=e.length-1;0<=n;--n)if(e[n]===t)return!0;return!1}),i):null},resize:function(t,e){var n=this._viewport;n.style.display="none";var i=this._opts;if(null!=t&&(i.width=t),null!=e&&(i.height=e),t=this._getSize(0),e=this._getSize(1),n.style.display="",this._width!==t||this._height!==e){this._width=t,this._height=e;var r=n.style;r.width=t+"px",r.height=e+"px";var a=this._svgRoot;a.setAttribute("width",t),a.setAttribute("height",e)}},getWidth:function(){return this._width},getHeight:function(){return this._height},_getSize:function(t){var e=this._opts,n=["width","height"][t],i=["clientWidth","clientHeight"][t],r=["paddingLeft","paddingTop"][t],a=["paddingRight","paddingBottom"][t];if(null!=e[n]&&"auto"!==e[n])return parseFloat(e[n]);var o=this.root,s=document.defaultView.getComputedStyle(o);return(o[i]||iS(s[n])||iS(o.style[n]))-(iS(s[r])||0)-(iS(s[a])||0)|0},dispose:function(){this.root.innerHTML="",this._svgRoot=this._viewport=this.storage=null},clear:function(){this._viewport&&this.root.removeChild(this._viewport)},pathToDataUrl:function(){return this.refresh(),"data:image/svg+xml;charset=UTF-8,"+this._svgRoot.outerHTML}},A(["getLayer","insertLayer","eachLayer","eachBuiltinLayer","eachOtherLayer","getLayers","modLayer","delLayer","clearLayer","toDataURL","pathToImage"],function(t){uS.prototype[t]=function(t){return function(){on('In SVG mode painter not support method "'+t+'"')}}(t)}),lr("svg",uS),t.version="4.3.0",t.dependencies={zrender:"4.1.0"},t.PRIORITY=Uc,t.init=function(t,e,n){var i=kd(t);if(i)return i;var r=new Kc(t,e,n);return r.id="ec_"+Id++,Sd[r.id]=r,Ar(t,Td,r.id),function(i){var r="__connectUpdateStatus";function a(t,e){for(var n=0;n<t.length;n++){t[n][r]=e}}Hc(md,function(t,e){i._messageCenter.on(e,function(t){if(Md[i.group]&&0!==i[r]){if(t&&t.escapeConnect)return;var e=i.makeActionFromEvent(t),n=[];Hc(Sd,function(t){t!==i&&t.group===i.group&&n.push(t)}),a(n,0),Hc(n,function(t){1!==t[r]&&t.dispatchAction(e)}),a(n,2)}})})}(r),r},t.connect=function(e){if(O(e)){var t=e;e=null,Hc(t,function(t){null!=t.group&&(e=t.group)}),e=e||"g_"+Cd++,Hc(t,function(t){t.group=e})}return Md[e]=!0,e},t.disConnect=Ad,t.disconnect=Dd,t.dispose=function(t){"string"==typeof t?t=Sd[t]:t instanceof Kc||(t=kd(t)),t instanceof Kc&&!t.isDisposed()&&t.dispose()},t.getInstanceByDom=kd,t.getInstanceById=function(t){return Sd[t]},t.registerTheme=Pd,t.registerPreprocessor=Ld,t.registerProcessor=Od,t.registerPostUpdate=function(t){_d.push(t)},t.registerAction=zd,t.registerCoordinateSystem=function(t,e){Mh.register(t,e)},t.getCoordinateSystemDimensions=function(t){var e=Mh.get(t);if(e)return e.getDimensionsInfo?e.getDimensionsInfo():e.dimensions.slice()},t.registerLayout=Ed,t.registerVisual=Nd,t.registerLoading=Bd,t.extendComponentModel=Fd,t.extendComponentView=Vd,t.extendSeriesModel=Hd,t.extendChartView=Wd,t.setCanvasCreator=function(t){f("createCanvas",t)},t.registerMap=function(t,e,n){Rc(t,e,n)},t.getMap=function(t){var e=Bc(t);return e&&e[0]&&{geoJson:e[0].geoJSON,specialAreas:e[0].specialAreas}},t.dataTool={},t.zrender=ur,t.number=yl,t.format=Ol,t.throttle=Xu,t.helper=kp,t.matrix=ie,t.vector=wt,t.color=Ve,t.parseGeoJSON=Np,t.parseGeoJson=qp,t.util=$p,t.graphic=Kp,t.List=af,t.Model=Ks,t.Axis=Xp,t.env=v});
+!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports):"function"==typeof define&&define.amd?define(["exports"],e):e(t.echarts={})}(this,function(t){"use strict";var e=2311,i=function(){return e++},v="object"==typeof wx&&"function"==typeof wx.getSystemInfoSync?{browser:{},os:{},node:!1,wxa:!0,canvasSupported:!0,svgSupported:!1,touchEventsSupported:!0,domSupported:!1}:"undefined"==typeof document&&"undefined"!=typeof self?{browser:{},os:{},node:!1,worker:!0,canvasSupported:!0,domSupported:!1}:"undefined"==typeof navigator?{browser:{},os:{},node:!0,worker:!1,canvasSupported:!0,svgSupported:!0,domSupported:!1}:function(t){var e={},n=t.match(/Firefox\/([\d.]+)/),i=t.match(/MSIE\s([\d.]+)/)||t.match(/Trident\/.+?rv:(([\d.]+))/),r=t.match(/Edge\/([\d.]+)/),a=/micromessenger/i.test(t);n&&(e.firefox=!0,e.version=n[1]);i&&(e.ie=!0,e.version=i[1]);r&&(e.edge=!0,e.version=r[1]);a&&(e.weChat=!0);return{browser:e,os:{},node:!1,canvasSupported:!!document.createElement("canvas").getContext,svgSupported:"undefined"!=typeof SVGRect,touchEventsSupported:"ontouchstart"in window&&!e.ie&&!e.edge,pointerEventsSupported:"onpointerdown"in window&&(e.edge||e.ie&&11<=e.version),domSupported:"undefined"!=typeof document}}(navigator.userAgent);var s={"[object Function]":1,"[object RegExp]":1,"[object Date]":1,"[object Error]":1,"[object CanvasGradient]":1,"[object CanvasPattern]":1,"[object Image]":1,"[object Canvas]":1},l={"[object Int8Array]":1,"[object Uint8Array]":1,"[object Uint8ClampedArray]":1,"[object Int16Array]":1,"[object Uint16Array]":1,"[object Int32Array]":1,"[object Uint32Array]":1,"[object Float32Array]":1,"[object Float64Array]":1},h=Object.prototype.toString,n=Array.prototype,o=n.forEach,u=n.filter,r=n.slice,c=n.map,d=n.reduce,a={};function f(t,e){"createCanvas"===t&&(y=null),a[t]=e}function b(t){if(null==t||"object"!=typeof t)return t;var e=t,n=h.call(t);if("[object Array]"===n){if(!$(t)){e=[];for(var i=0,r=t.length;i<r;i++)e[i]=b(t[i])}}else if(l[n]){if(!$(t)){var a=t.constructor;if(t.constructor.from)e=a.from(t);else{e=new a(t.length);for(i=0,r=t.length;i<r;i++)e[i]=b(t[i])}}}else if(!s[n]&&!$(t)&&!F(t))for(var o in e={},t)t.hasOwnProperty(o)&&(e[o]=b(t[o]));return e}function m(t,e,n){if(!N(e)||!N(t))return n?b(e):t;for(var i in e)if(e.hasOwnProperty(i)){var r=t[i],a=e[i];!N(a)||!N(r)||O(a)||O(r)||F(a)||F(r)||R(a)||R(r)||$(a)||$(r)?!n&&i in t||(t[i]=b(e[i])):m(r,a,n)}return t}function p(t,e){for(var n=t[0],i=1,r=t.length;i<r;i++)n=m(n,t[i],e);return n}function I(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);return t}function T(t,e,n){for(var i in e)e.hasOwnProperty(i)&&(n?null!=e[i]:null==t[i])&&(t[i]=e[i]);return t}function g(){return a.createCanvas()}var y;function _(){return y=y||g().getContext("2d")}function x(t,e){if(t){if(t.indexOf)return t.indexOf(e);for(var n=0,i=t.length;n<i;n++)if(t[n]===e)return n}return-1}function w(t,e){var n=t.prototype;function i(){}for(var r in i.prototype=e.prototype,t.prototype=new i,n)t.prototype[r]=n[r];(t.prototype.constructor=t).superClass=e}function S(t,e,n){T(t="prototype"in t?t.prototype:t,e="prototype"in e?e.prototype:e,n)}function L(t){if(t)return"string"!=typeof t&&"number"==typeof t.length}function A(t,e,n){if(t&&e)if(t.forEach&&t.forEach===o)t.forEach(e,n);else if(t.length===+t.length)for(var i=0,r=t.length;i<r;i++)e.call(n,t[i],i,t);else for(var a in t)t.hasOwnProperty(a)&&e.call(n,t[a],a,t)}function D(t,e,n){if(t&&e){if(t.map&&t.map===c)return t.map(e,n);for(var i=[],r=0,a=t.length;r<a;r++)i.push(e.call(n,t[r],r,t));return i}}function M(t,e,n,i){if(t&&e){if(t.reduce&&t.reduce===d)return t.reduce(e,n,i);for(var r=0,a=t.length;r<a;r++)n=e.call(i,n,t[r],r,t);return n}}function C(t,e,n){if(t&&e){if(t.filter&&t.filter===u)return t.filter(e,n);for(var i=[],r=0,a=t.length;r<a;r++)e.call(n,t[r],r,t)&&i.push(t[r]);return i}}function k(t,e){var n=r.call(arguments,2);return function(){return t.apply(e,n.concat(r.call(arguments)))}}function P(t){var e=r.call(arguments,1);return function(){return t.apply(this,e.concat(r.call(arguments)))}}function O(t){return"[object Array]"===h.call(t)}function z(t){return"function"==typeof t}function E(t){return"[object String]"===h.call(t)}function N(t){var e=typeof t;return"function"==e||!!t&&"object"==e}function R(t){return!!s[h.call(t)]}function B(t){return!!l[h.call(t)]}function F(t){return"object"==typeof t&&"number"==typeof t.nodeType&&"object"==typeof t.ownerDocument}function V(t){return t!=t}function H(t){for(var e=0,n=arguments.length;e<n;e++)if(null!=arguments[e])return arguments[e]}function W(t,e){return null!=t?t:e}function G(t,e,n){return null!=t?t:null!=e?e:n}function Z(){return Function.call.apply(r,arguments)}function U(t){if("number"==typeof t)return[t,t,t,t];var e=t.length;return 2===e?[t[0],t[1],t[0],t[1]]:3===e?[t[0],t[1],t[2],t[1]]:t}function X(t,e){if(!t)throw new Error(e)}function Y(t){return null==t?null:"function"==typeof t.trim?t.trim():t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")}a.createCanvas=function(){return document.createElement("canvas")};var j="__ec_primitive__";function q(t){t[j]=!0}function $(t){return t[j]}function K(t){var n=O(t);this.data={};var i=this;function e(t,e){n?i.set(t,e):i.set(e,t)}t instanceof K?t.each(e):t&&A(t,e)}function Q(t){return new K(t)}function J(){}K.prototype={constructor:K,get:function(t){return this.data.hasOwnProperty(t)?this.data[t]:null},set:function(t,e){return this.data[t]=e},each:function(t,e){for(var n in void 0!==e&&(t=k(t,e)),this.data)this.data.hasOwnProperty(n)&&t(this.data[n],n)},removeKey:function(t){delete this.data[t]}};var tt=(Object.freeze||Object)({$override:f,clone:b,merge:m,mergeAll:p,extend:I,defaults:T,createCanvas:g,getContext:_,indexOf:x,inherits:w,mixin:S,isArrayLike:L,each:A,map:D,reduce:M,filter:C,find:function(t,e,n){if(t&&e)for(var i=0,r=t.length;i<r;i++)if(e.call(n,t[i],i,t))return t[i]},bind:k,curry:P,isArray:O,isFunction:z,isString:E,isObject:N,isBuiltInObject:R,isTypedArray:B,isDom:F,eqNaN:V,retrieve:H,retrieve2:W,retrieve3:G,slice:Z,normalizeCssArray:U,assert:X,trim:Y,setAsPrimitive:q,isPrimitive:$,createHashMap:Q,concatArray:function(t,e){for(var n=new t.constructor(t.length+e.length),i=0;i<t.length;i++)n[i]=t[i];var r=t.length;for(i=0;i<e.length;i++)n[i+r]=e[i];return n},noop:J}),et="undefined"==typeof Float32Array?Array:Float32Array;function nt(t,e){var n=new et(2);return null==t&&(t=0),null==e&&(e=0),n[0]=t,n[1]=e,n}function it(t,e){return t[0]=e[0],t[1]=e[1],t}function rt(t){var e=new et(2);return e[0]=t[0],e[1]=t[1],e}function at(t,e,n){return t[0]=e[0]+n[0],t[1]=e[1]+n[1],t}function ot(t,e,n,i){return t[0]=e[0]+n[0]*i,t[1]=e[1]+n[1]*i,t}function st(t,e,n){return t[0]=e[0]-n[0],t[1]=e[1]-n[1],t}function lt(t){return Math.sqrt(ut(t))}var ht=lt;function ut(t){return t[0]*t[0]+t[1]*t[1]}var ct=ut;function dt(t,e,n){return t[0]=e[0]*n,t[1]=e[1]*n,t}function ft(t,e){var n=lt(e);return 0===n?(t[0]=0,t[1]=0):(t[0]=e[0]/n,t[1]=e[1]/n),t}function pt(t,e){return Math.sqrt((t[0]-e[0])*(t[0]-e[0])+(t[1]-e[1])*(t[1]-e[1]))}var gt=pt;function mt(t,e){return(t[0]-e[0])*(t[0]-e[0])+(t[1]-e[1])*(t[1]-e[1])}var vt=mt;function yt(t,e,n){var i=e[0],r=e[1];return t[0]=n[0]*i+n[2]*r+n[4],t[1]=n[1]*i+n[3]*r+n[5],t}function _t(t,e,n){return t[0]=Math.min(e[0],n[0]),t[1]=Math.min(e[1],n[1]),t}function xt(t,e,n){return t[0]=Math.max(e[0],n[0]),t[1]=Math.max(e[1],n[1]),t}var wt=(Object.freeze||Object)({create:nt,copy:it,clone:rt,set:function(t,e,n){return t[0]=e,t[1]=n,t},add:at,scaleAndAdd:ot,sub:st,len:lt,length:ht,lenSquare:ut,lengthSquare:ct,mul:function(t,e,n){return t[0]=e[0]*n[0],t[1]=e[1]*n[1],t},div:function(t,e,n){return t[0]=e[0]/n[0],t[1]=e[1]/n[1],t},dot:function(t,e){return t[0]*e[0]+t[1]*e[1]},scale:dt,normalize:ft,distance:pt,dist:gt,distanceSquare:mt,distSquare:vt,negate:function(t,e){return t[0]=-e[0],t[1]=-e[1],t},lerp:function(t,e,n,i){return t[0]=e[0]+i*(n[0]-e[0]),t[1]=e[1]+i*(n[1]-e[1]),t},applyTransform:yt,min:_t,max:xt});function bt(){this.on("mousedown",this._dragStart,this),this.on("mousemove",this._drag,this),this.on("mouseup",this._dragEnd,this),this.on("globalout",this._dragEnd,this)}function St(t,e){return{target:t,topTarget:e&&e.topTarget}}bt.prototype={constructor:bt,_dragStart:function(t){var e=t.target;e&&e.draggable&&((this._draggingTarget=e).dragging=!0,this._x=t.offsetX,this._y=t.offsetY,this.dispatchToElement(St(e,t),"dragstart",t.event))},_drag:function(t){var e=this._draggingTarget;if(e){var n=t.offsetX,i=t.offsetY,r=n-this._x,a=i-this._y;this._x=n,this._y=i,e.drift(r,a,t),this.dispatchToElement(St(e,t),"drag",t.event);var o=this.findHover(n,i,e).target,s=this._dropTarget;e!==(this._dropTarget=o)&&(s&&o!==s&&this.dispatchToElement(St(s,t),"dragleave",t.event),o&&o!==s&&this.dispatchToElement(St(o,t),"dragenter",t.event))}},_dragEnd:function(t){var e=this._draggingTarget;e&&(e.dragging=!1),this.dispatchToElement(St(e,t),"dragend",t.event),this._dropTarget&&this.dispatchToElement(St(this._dropTarget,t),"drop",t.event),this._draggingTarget=null,this._dropTarget=null}};var Mt=Array.prototype.slice,It=function(t){this._$handlers={},this._$eventProcessor=t};function Ct(t,e,n,i,r,a){var o=t._$handlers;if("function"==typeof n&&(r=i,i=n,n=null),!i||!e)return t;n=function(t,e){var n=t._$eventProcessor;return null!=e&&n&&n.normalizeQuery&&(e=n.normalizeQuery(e)),e}(t,n),o[e]||(o[e]=[]);for(var s=0;s<o[e].length;s++)if(o[e][s].h===i)return t;var l={h:i,one:a,query:n,ctx:r||t,callAtLast:i.zrEventfulCallAtLast},h=o[e].length-1,u=o[e][h];return u&&u.callAtLast?o[e].splice(h,0,l):o[e].push(l),t}It.prototype={constructor:It,one:function(t,e,n,i){return Ct(this,t,e,n,i,!0)},on:function(t,e,n,i){return Ct(this,t,e,n,i,!1)},isSilent:function(t){var e=this._$handlers;return!e[t]||!e[t].length},off:function(t,e){var n=this._$handlers;if(!t)return this._$handlers={},this;if(e){if(n[t]){for(var i=[],r=0,a=n[t].length;r<a;r++)n[t][r].h!==e&&i.push(n[t][r]);n[t]=i}n[t]&&0===n[t].length&&delete n[t]}else delete n[t];return this},trigger:function(t){var e=this._$handlers[t],n=this._$eventProcessor;if(e){var i=arguments,r=i.length;3<r&&(i=Mt.call(i,1));for(var a=e.length,o=0;o<a;){var s=e[o];if(n&&n.filter&&null!=s.query&&!n.filter(t,s.query))o++;else{switch(r){case 1:s.h.call(s.ctx);break;case 2:s.h.call(s.ctx,i[1]);break;case 3:s.h.call(s.ctx,i[1],i[2]);break;default:s.h.apply(s.ctx,i)}s.one?(e.splice(o,1),a--):o++}}}return n&&n.afterTrigger&&n.afterTrigger(t),this},triggerWithContext:function(t){var e=this._$handlers[t],n=this._$eventProcessor;if(e){var i=arguments,r=i.length;4<r&&(i=Mt.call(i,1,i.length-1));for(var a=i[i.length-1],o=e.length,s=0;s<o;){var l=e[s];if(n&&n.filter&&null!=l.query&&!n.filter(t,l.query))s++;else{switch(r){case 1:l.h.call(a);break;case 2:l.h.call(a,i[1]);break;case 3:l.h.call(a,i[1],i[2]);break;default:l.h.apply(a,i)}l.one?(e.splice(s,1),o--):s++}}}return n&&n.afterTrigger&&n.afterTrigger(t),this}};var Tt=Math.log(2);function At(t,e,n,i,r,a){var o=i+"-"+r,s=t.length;if(a.hasOwnProperty(o))return a[o];if(1===e){var l=Math.round(Math.log((1<<s)-1&~r)/Tt);return t[n][l]}for(var h=i|1<<n,u=n+1;i&1<<u;)u++;for(var c=0,d=0,f=0;d<s;d++){var p=1<<d;p&r||(c+=(f%2?-1:1)*t[n][d]*At(t,e-1,u,h,r|p,a),f++)}return a[o]=c}var Dt="undefined"!=typeof window&&!!window.addEventListener,kt=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,Pt="___zrEVENTSAVED",Lt=[];function Ot(t,e,n,i){return n=n||{},i||!v.canvasSupported?zt(t,e,n):v.browser.firefox&&null!=e.layerX&&e.layerX!==e.offsetX?(n.zrX=e.layerX,n.zrY=e.layerY):null!=e.offsetX?(n.zrX=e.offsetX,n.zrY=e.offsetY):zt(t,e,n),n}function zt(t,e,n){if(t.getBoundingClientRect&&v.domSupported){var i=e.clientX,r=e.clientY;if("CANVAS"===t.nodeName.toUpperCase()){var a=t.getBoundingClientRect();return n.zrX=i-a.left,void(n.zrY=r-a.top)}var o=t[Pt]||(t[Pt]={}),s=function(t,e){for(var n=e.transformer,i=e.srcCoords,r=!0,a=[],o=[],s=0;s<4;s++){var l=t[s].getBoundingClientRect(),h=2*s,u=l.left,c=l.top;a.push(u,c),r&=i&&u===i[h]&&c===i[1+h],o.push(t[s].offsetLeft,t[s].offsetTop)}return r?n:(e.srcCoords=a,e.transformer=function(t,e){var n=[[t[0],t[1],1,0,0,0,-e[0]*t[0],-e[0]*t[1]],[0,0,0,t[0],t[1],1,-e[1]*t[0],-e[1]*t[1]],[t[2],t[3],1,0,0,0,-e[2]*t[2],-e[2]*t[3]],[0,0,0,t[2],t[3],1,-e[3]*t[2],-e[3]*t[3]],[t[4],t[5],1,0,0,0,-e[4]*t[4],-e[4]*t[5]],[0,0,0,t[4],t[5],1,-e[5]*t[4],-e[5]*t[5]],[t[6],t[7],1,0,0,0,-e[6]*t[6],-e[6]*t[7]],[0,0,0,t[6],t[7],1,-e[7]*t[6],-e[7]*t[7]]],i={},r=At(n,8,0,0,0,i);if(0!==r){for(var a=[],o=0;o<8;o++)for(var s=0;s<8;s++)null==a[s]&&(a[s]=0),a[s]+=((o+s)%2?-1:1)*At(n,7,0===o?1:0,1<<o,1<<s,i)/r*e[o];return function(t,e,n){var i=e*a[6]+n*a[7]+1;t[0]=(e*a[0]+n*a[1]+a[2])/i,t[1]=(e*a[3]+n*a[4]+a[5])/i}}}(a,o))}(function(t,e){var n=e.markers;if(n)return n;n=e.markers=[];for(var i=["left","right"],r=["top","bottom"],a=0;a<4;a++){var o=document.createElement("div"),s=o.style,l=a%2,h=(a>>1)%2;s.cssText=["position:absolute","visibility: hidden","padding: 0","margin: 0","border-width: 0","width:0","height:0",i[l]+":0",r[h]+":0",i[1-l]+":auto",r[1-h]+":auto",""].join("!important;"),t.appendChild(o),n.push(o)}return n}(t,o),o);if(s)return s(Lt,i,r),n.zrX=Lt[0],void(n.zrY=Lt[1])}n.zrX=n.zrY=0}function Et(t,e,n){if(null!=(e=e||window.event).zrX)return e;var i=e.type;if(i&&0<=i.indexOf("touch")){var r="touchend"!==i?e.targetTouches[0]:e.changedTouches[0];r&&Ot(t,r,e,n)}else Ot(t,e,e,n),e.zrDelta=e.wheelDelta?e.wheelDelta/120:-(e.detail||0)/3;var a=e.button;return null==e.which&&void 0!==a&&kt.test(e.type)&&(e.which=1&a?1:2&a?3:4&a?2:0),e}function Nt(t,e,n){Dt?t.addEventListener(e,n):t.attachEvent("on"+e,n)}var Rt=Dt?function(t){t.preventDefault(),t.stopPropagation(),t.cancelBubble=!0}:function(t){t.returnValue=!1,t.cancelBubble=!0};function Bt(t){return 2===t.which||3===t.which}function Ft(){this._track=[]}function Vt(t){var e=t[1][0]-t[0][0],n=t[1][1]-t[0][1];return Math.sqrt(e*e+n*n)}Ft.prototype={constructor:Ft,recognize:function(t,e,n){return this._doTrack(t,e,n),this._recognize(t)},clear:function(){return this._track.length=0,this},_doTrack:function(t,e,n){var i=t.touches;if(i){for(var r={points:[],touches:[],target:e,event:t},a=0,o=i.length;a<o;a++){var s=i[a],l=Ot(n,s,{});r.points.push([l.zrX,l.zrY]),r.touches.push(s)}this._track.push(r)}},_recognize:function(t){for(var e in Ht)if(Ht.hasOwnProperty(e)){var n=Ht[e](this._track,t);if(n)return n}}};var Ht={pinch:function(t,e){var n=t.length;if(n){var i=(t[n-1]||{}).points,r=(t[n-2]||{}).points||i;if(r&&1<r.length&&i&&1<i.length){var a=Vt(i)/Vt(r);isFinite(a)||(a=1),e.pinchScale=a;var o=function(t){return[(t[0][0]+t[1][0])/2,(t[0][1]+t[1][1])/2]}(i);return e.pinchX=o[0],e.pinchY=o[1],{type:"pinch",target:t[0].target,event:e}}}}},Wt="silent";function Gt(t){Rt(this.event)}function Zt(){}Zt.prototype.dispose=function(){};function Ut(t,e,n,i){It.call(this),this.storage=t,this.painter=e,this.painterRoot=i,n=n||new Zt,this.proxy=null,this._hovered={},this._lastTouchMoment,this._lastX,this._lastY,this._gestureMgr,bt.call(this),this.setHandlerProxy(n)}var Xt=["click","dblclick","mousewheel","mouseout","mouseup","mousedown","mousemove","contextmenu"];function Yt(t,e,n){if(t[t.rectHover?"rectContain":"contain"](e,n)){for(var i,r=t;r;){if(r.clipPath&&!r.clipPath.contain(e,n))return!1;r.silent&&(i=!0),r=r.parent}return!i||Wt}return!1}Ut.prototype={constructor:Ut,setHandlerProxy:function(e){this.proxy&&this.proxy.dispose(),e&&(A(Xt,function(t){e.on&&e.on(t,this[t],this)},this),e.handler=this),this.proxy=e},mousemove:function(t){var e=t.zrX,n=t.zrY,i=this._hovered,r=i.target;r&&!r.__zr&&(r=(i=this.findHover(i.x,i.y)).target);var a=this._hovered=this.findHover(e,n),o=a.target,s=this.proxy;s.setCursor&&s.setCursor(o?o.cursor:"default"),r&&o!==r&&this.dispatchToElement(i,"mouseout",t),this.dispatchToElement(a,"mousemove",t),o&&o!==r&&this.dispatchToElement(a,"mouseover",t)},mouseout:function(t){this.dispatchToElement(this._hovered,"mouseout",t);for(var e,n=t.toElement||t.relatedTarget;(n=n&&n.parentNode)&&9!==n.nodeType&&!(e=n===this.painterRoot););e||this.trigger("globalout",{event:t})},resize:function(t){this._hovered={}},dispatch:function(t,e){var n=this[t];n&&n.call(this,e)},dispose:function(){this.proxy.dispose(),this.storage=this.proxy=this.painter=null},setCursorStyle:function(t){var e=this.proxy;e.setCursor&&e.setCursor(t)},dispatchToElement:function(t,e,n){var i=(t=t||{}).target;if(!i||!i.silent){for(var r="on"+e,a=function(t,e,n){return{type:t,event:n,target:e.target,topTarget:e.topTarget,cancelBubble:!1,offsetX:n.zrX,offsetY:n.zrY,gestureEvent:n.gestureEvent,pinchX:n.pinchX,pinchY:n.pinchY,pinchScale:n.pinchScale,wheelDelta:n.zrDelta,zrByTouch:n.zrByTouch,which:n.which,stop:Gt}}(e,t,n);i&&(i[r]&&(a.cancelBubble=i[r].call(i,a)),i.trigger(e,a),i=i.parent,!a.cancelBubble););a.cancelBubble||(this.trigger(e,a),this.painter&&this.painter.eachOtherLayer(function(t){"function"==typeof t[r]&&t[r].call(t,a),t.trigger&&t.trigger(e,a)}))}},findHover:function(t,e,n){for(var i=this.storage.getDisplayList(),r={x:t,y:e},a=i.length-1;0<=a;a--){var o;if(i[a]!==n&&!i[a].ignore&&(o=Yt(i[a],t,e))&&(r.topTarget||(r.topTarget=i[a]),o!==Wt)){r.target=i[a];break}}return r},processGesture:function(t,e){this._gestureMgr||(this._gestureMgr=new Ft);var n=this._gestureMgr;"start"===e&&n.clear();var i=n.recognize(t,this.findHover(t.zrX,t.zrY,null).target,this.proxy.dom);if("end"===e&&n.clear(),i){var r=i.type;t.gestureEvent=r,this.dispatchToElement({target:i.target},r,i.event)}}},A(["click","mousedown","mouseup","mousewheel","dblclick","contextmenu"],function(i){Ut.prototype[i]=function(t){var e=this.findHover(t.zrX,t.zrY),n=e.target;if("mousedown"===i)this._downEl=n,this._downPoint=[t.zrX,t.zrY],this._upEl=n;else if("mouseup"===i)this._upEl=n;else if("click"===i){if(this._downEl!==this._upEl||!this._downPoint||4<gt(this._downPoint,[t.zrX,t.zrY]))return;this._downPoint=null}this.dispatchToElement(e,i,t)}}),S(Ut,It),S(Ut,bt);var jt="undefined"==typeof Float32Array?Array:Float32Array;function qt(){var t=new jt(6);return $t(t),t}function $t(t){return t[0]=1,t[1]=0,t[2]=0,t[3]=1,t[4]=0,t[5]=0,t}function Kt(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}function Qt(t,e,n){var i=e[0]*n[0]+e[2]*n[1],r=e[1]*n[0]+e[3]*n[1],a=e[0]*n[2]+e[2]*n[3],o=e[1]*n[2]+e[3]*n[3],s=e[0]*n[4]+e[2]*n[5]+e[4],l=e[1]*n[4]+e[3]*n[5]+e[5];return t[0]=i,t[1]=r,t[2]=a,t[3]=o,t[4]=s,t[5]=l,t}function Jt(t,e,n){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[4]=e[4]+n[0],t[5]=e[5]+n[1],t}function te(t,e,n){var i=e[0],r=e[2],a=e[4],o=e[1],s=e[3],l=e[5],h=Math.sin(n),u=Math.cos(n);return t[0]=i*u+o*h,t[1]=-i*h+o*u,t[2]=r*u+s*h,t[3]=-r*h+u*s,t[4]=u*a+h*l,t[5]=u*l-h*a,t}function ee(t,e,n){var i=n[0],r=n[1];return t[0]=e[0]*i,t[1]=e[1]*r,t[2]=e[2]*i,t[3]=e[3]*r,t[4]=e[4]*i,t[5]=e[5]*r,t}function ne(t,e){var n=e[0],i=e[2],r=e[4],a=e[1],o=e[3],s=e[5],l=n*o-a*i;return l?(l=1/l,t[0]=o*l,t[1]=-a*l,t[2]=-i*l,t[3]=n*l,t[4]=(i*s-o*r)*l,t[5]=(a*r-n*s)*l,t):null}var ie=(Object.freeze||Object)({create:qt,identity:$t,copy:Kt,mul:Qt,translate:Jt,rotate:te,scale:ee,invert:ne,clone:function(t){var e=qt();return Kt(e,t),e}}),re=$t;function ae(t){return 5e-5<t||t<-5e-5}var oe=function(t){(t=t||{}).position||(this.position=[0,0]),null==t.rotation&&(this.rotation=0),t.scale||(this.scale=[1,1]),this.origin=this.origin||null},se=oe.prototype;se.transform=null,se.needLocalTransform=function(){return ae(this.rotation)||ae(this.position[0])||ae(this.position[1])||ae(this.scale[0]-1)||ae(this.scale[1]-1)};var le=[];se.updateTransform=function(){var t=this.parent,e=t&&t.transform,n=this.needLocalTransform(),i=this.transform;if(n||e){i=i||qt(),n?this.getLocalTransform(i):re(i),e&&(n?Qt(i,t.transform,i):Kt(i,t.transform)),this.transform=i;var r=this.globalScaleRatio;if(null!=r&&1!==r){this.getGlobalScale(le);var a=le[0]<0?-1:1,o=le[1]<0?-1:1,s=((le[0]-a)*r+a)/le[0]||0,l=((le[1]-o)*r+o)/le[1]||0;i[0]*=s,i[1]*=s,i[2]*=l,i[3]*=l}this.invTransform=this.invTransform||qt(),ne(this.invTransform,i)}else i&&re(i)},se.getLocalTransform=function(t){return oe.getLocalTransform(this,t)},se.setTransform=function(t){var e=this.transform,n=t.dpr||1;e?t.setTransform(n*e[0],n*e[1],n*e[2],n*e[3],n*e[4],n*e[5]):t.setTransform(n,0,0,n,0,0)},se.restoreTransform=function(t){var e=t.dpr||1;t.setTransform(e,0,0,e,0,0)};var he=[],ue=qt();se.setLocalTransform=function(t){if(t){var e=t[0]*t[0]+t[1]*t[1],n=t[2]*t[2]+t[3]*t[3],i=this.position,r=this.scale;ae(e-1)&&(e=Math.sqrt(e)),ae(n-1)&&(n=Math.sqrt(n)),t[0]<0&&(e=-e),t[3]<0&&(n=-n),i[0]=t[4],i[1]=t[5],r[0]=e,r[1]=n,this.rotation=Math.atan2(-t[1]/n,t[0]/e)}},se.decomposeTransform=function(){if(this.transform){var t=this.parent,e=this.transform;t&&t.transform&&(Qt(he,t.invTransform,e),e=he);var n=this.origin;n&&(n[0]||n[1])&&(ue[4]=n[0],ue[5]=n[1],Qt(he,e,ue),he[4]-=n[0],he[5]-=n[1],e=he),this.setLocalTransform(e)}},se.getGlobalScale=function(t){var e=this.transform;return t=t||[],e?(t[0]=Math.sqrt(e[0]*e[0]+e[1]*e[1]),t[1]=Math.sqrt(e[2]*e[2]+e[3]*e[3]),e[0]<0&&(t[0]=-t[0]),e[3]<0&&(t[1]=-t[1])):(t[0]=1,t[1]=1),t},se.transformCoordToLocal=function(t,e){var n=[t,e],i=this.invTransform;return i&&yt(n,n,i),n},se.transformCoordToGlobal=function(t,e){var n=[t,e],i=this.transform;return i&&yt(n,n,i),n},oe.getLocalTransform=function(t,e){re(e=e||[]);var n=t.origin,i=t.scale||[1,1],r=t.rotation||0,a=t.position||[0,0];return n&&(e[4]-=n[0],e[5]-=n[1]),ee(e,e,i),r&&te(e,e,r),n&&(e[4]+=n[0],e[5]+=n[1]),e[4]+=a[0],e[5]+=a[1],e};var ce={linear:function(t){return t},quadraticIn:function(t){return t*t},quadraticOut:function(t){return t*(2-t)},quadraticInOut:function(t){return(t*=2)<1?.5*t*t:-.5*(--t*(t-2)-1)},cubicIn:function(t){return t*t*t},cubicOut:function(t){return--t*t*t+1},cubicInOut:function(t){return(t*=2)<1?.5*t*t*t:.5*((t-=2)*t*t+2)},quarticIn:function(t){return t*t*t*t},quarticOut:function(t){return 1- --t*t*t*t},quarticInOut:function(t){return(t*=2)<1?.5*t*t*t*t:-.5*((t-=2)*t*t*t-2)},quinticIn:function(t){return t*t*t*t*t},quinticOut:function(t){return--t*t*t*t*t+1},quinticInOut:function(t){return(t*=2)<1?.5*t*t*t*t*t:.5*((t-=2)*t*t*t*t+2)},sinusoidalIn:function(t){return 1-Math.cos(t*Math.PI/2)},sinusoidalOut:function(t){return Math.sin(t*Math.PI/2)},sinusoidalInOut:function(t){return.5*(1-Math.cos(Math.PI*t))},exponentialIn:function(t){return 0===t?0:Math.pow(1024,t-1)},exponentialOut:function(t){return 1===t?1:1-Math.pow(2,-10*t)},exponentialInOut:function(t){return 0===t?0:1===t?1:(t*=2)<1?.5*Math.pow(1024,t-1):.5*(2-Math.pow(2,-10*(t-1)))},circularIn:function(t){return 1-Math.sqrt(1-t*t)},circularOut:function(t){return Math.sqrt(1- --t*t)},circularInOut:function(t){return(t*=2)<1?-.5*(Math.sqrt(1-t*t)-1):.5*(Math.sqrt(1-(t-=2)*t)+1)},elasticIn:function(t){var e,n=.1;return 0===t?0:1===t?1:(e=!n||n<1?(n=1,.1):.4*Math.asin(1/n)/(2*Math.PI),-n*Math.pow(2,10*(t-=1))*Math.sin((t-e)*(2*Math.PI)/.4))},elasticOut:function(t){var e,n=.1;return 0===t?0:1===t?1:(e=!n||n<1?(n=1,.1):.4*Math.asin(1/n)/(2*Math.PI),n*Math.pow(2,-10*t)*Math.sin((t-e)*(2*Math.PI)/.4)+1)},elasticInOut:function(t){var e,n=.1;return 0===t?0:1===t?1:(e=!n||n<1?(n=1,.1):.4*Math.asin(1/n)/(2*Math.PI),(t*=2)<1?n*Math.pow(2,10*(t-=1))*Math.sin((t-e)*(2*Math.PI)/.4)*-.5:n*Math.pow(2,-10*(t-=1))*Math.sin((t-e)*(2*Math.PI)/.4)*.5+1)},backIn:function(t){return t*t*(2.70158*t-1.70158)},backOut:function(t){return--t*t*(2.70158*t+1.70158)+1},backInOut:function(t){var e=2.5949095;return(t*=2)<1?t*t*((1+e)*t-e)*.5:.5*((t-=2)*t*((1+e)*t+e)+2)},bounceIn:function(t){return 1-ce.bounceOut(1-t)},bounceOut:function(t){return t<1/2.75?7.5625*t*t:t<2/2.75?7.5625*(t-=1.5/2.75)*t+.75:t<2.5/2.75?7.5625*(t-=2.25/2.75)*t+.9375:7.5625*(t-=2.625/2.75)*t+.984375},bounceInOut:function(t){return t<.5?.5*ce.bounceIn(2*t):.5*ce.bounceOut(2*t-1)+.5}};function de(t){this._target=t.target,this._life=t.life||1e3,this._delay=t.delay||0,this._initialized=!1,this.loop=null!=t.loop&&t.loop,this.gap=t.gap||0,this.easing=t.easing||"Linear",this.onframe=t.onframe,this.ondestroy=t.ondestroy,this.onrestart=t.onrestart,this._pausedTime=0,this._paused=!1}de.prototype={constructor:de,step:function(t,e){if(this._initialized||(this._startTime=t+this._delay,this._initialized=!0),this._paused)this._pausedTime+=e;else{var n=(t-this._startTime-this._pausedTime)/this._life;if(!(n<0)){n=Math.min(n,1);var i=this.easing,r="string"==typeof i?ce[i]:i,a="function"==typeof r?r(n):n;return this.fire("frame",a),1===n?this.loop?(this.restart(t),"restart"):(this._needsRemove=!0,"destroy"):null}}},restart:function(t){var e=(t-this._startTime-this._pausedTime)%this._life;this._startTime=t-e+this.gap,this._pausedTime=0,this._needsRemove=!1},fire:function(t,e){this[t="on"+t]&&this[t](this._target,e)},pause:function(){this._paused=!0},resume:function(){this._paused=!1}};function fe(){this.head=null,this.tail=null,this._len=0}var pe=fe.prototype;pe.insert=function(t){var e=new me(t);return this.insertEntry(e),e},pe.insertEntry=function(t){this.head?((this.tail.next=t).prev=this.tail,t.next=null,this.tail=t):this.head=this.tail=t,this._len++},pe.remove=function(t){var e=t.prev,n=t.next;e?e.next=n:this.head=n,n?n.prev=e:this.tail=e,t.next=t.prev=null,this._len--},pe.len=function(){return this._len},pe.clear=function(){this.head=this.tail=null,this._len=0};function ge(t){this._list=new fe,this._map={},this._maxSize=t||10,this._lastRemovedEntry=null}var me=function(t){this.value=t,this.next,this.prev},ve=ge.prototype;ve.put=function(t,e){var n=this._list,i=this._map,r=null;if(null==i[t]){var a=n.len(),o=this._lastRemovedEntry;if(a>=this._maxSize&&0<a){var s=n.head;n.remove(s),delete i[s.key],r=s.value,this._lastRemovedEntry=s}o?o.value=e:o=new me(e),o.key=t,n.insertEntry(o),i[t]=o}return r},ve.get=function(t){var e=this._map[t],n=this._list;if(null!=e)return e!==n.tail&&(n.remove(e),n.insertEntry(e)),e.value},ve.clear=function(){this._list.clear(),this._map={}};var ye={transparent:[0,0,0,0],aliceblue:[240,248,255,1],antiquewhite:[250,235,215,1],aqua:[0,255,255,1],aquamarine:[127,255,212,1],azure:[240,255,255,1],beige:[245,245,220,1],bisque:[255,228,196,1],black:[0,0,0,1],blanchedalmond:[255,235,205,1],blue:[0,0,255,1],blueviolet:[138,43,226,1],brown:[165,42,42,1],burlywood:[222,184,135,1],cadetblue:[95,158,160,1],chartreuse:[127,255,0,1],chocolate:[210,105,30,1],coral:[255,127,80,1],cornflowerblue:[100,149,237,1],cornsilk:[255,248,220,1],crimson:[220,20,60,1],cyan:[0,255,255,1],darkblue:[0,0,139,1],darkcyan:[0,139,139,1],darkgoldenrod:[184,134,11,1],darkgray:[169,169,169,1],darkgreen:[0,100,0,1],darkgrey:[169,169,169,1],darkkhaki:[189,183,107,1],darkmagenta:[139,0,139,1],darkolivegreen:[85,107,47,1],darkorange:[255,140,0,1],darkorchid:[153,50,204,1],darkred:[139,0,0,1],darksalmon:[233,150,122,1],darkseagreen:[143,188,143,1],darkslateblue:[72,61,139,1],darkslategray:[47,79,79,1],darkslategrey:[47,79,79,1],darkturquoise:[0,206,209,1],darkviolet:[148,0,211,1],deeppink:[255,20,147,1],deepskyblue:[0,191,255,1],dimgray:[105,105,105,1],dimgrey:[105,105,105,1],dodgerblue:[30,144,255,1],firebrick:[178,34,34,1],floralwhite:[255,250,240,1],forestgreen:[34,139,34,1],fuchsia:[255,0,255,1],gainsboro:[220,220,220,1],ghostwhite:[248,248,255,1],gold:[255,215,0,1],goldenrod:[218,165,32,1],gray:[128,128,128,1],green:[0,128,0,1],greenyellow:[173,255,47,1],grey:[128,128,128,1],honeydew:[240,255,240,1],hotpink:[255,105,180,1],indianred:[205,92,92,1],indigo:[75,0,130,1],ivory:[255,255,240,1],khaki:[240,230,140,1],lavender:[230,230,250,1],lavenderblush:[255,240,245,1],lawngreen:[124,252,0,1],lemonchiffon:[255,250,205,1],lightblue:[173,216,230,1],lightcoral:[240,128,128,1],lightcyan:[224,255,255,1],lightgoldenrodyellow:[250,250,210,1],lightgray:[211,211,211,1],lightgreen:[144,238,144,1],lightgrey:[211,211,211,1],lightpink:[255,182,193,1],lightsalmon:[255,160,122,1],lightseagreen:[32,178,170,1],lightskyblue:[135,206,250,1],lightslategray:[119,136,153,1],lightslategrey:[119,136,153,1],lightsteelblue:[176,196,222,1],lightyellow:[255,255,224,1],lime:[0,255,0,1],limegreen:[50,205,50,1],linen:[250,240,230,1],magenta:[255,0,255,1],maroon:[128,0,0,1],mediumaquamarine:[102,205,170,1],mediumblue:[0,0,205,1],mediumorchid:[186,85,211,1],mediumpurple:[147,112,219,1],mediumseagreen:[60,179,113,1],mediumslateblue:[123,104,238,1],mediumspringgreen:[0,250,154,1],mediumturquoise:[72,209,204,1],mediumvioletred:[199,21,133,1],midnightblue:[25,25,112,1],mintcream:[245,255,250,1],mistyrose:[255,228,225,1],moccasin:[255,228,181,1],navajowhite:[255,222,173,1],navy:[0,0,128,1],oldlace:[253,245,230,1],olive:[128,128,0,1],olivedrab:[107,142,35,1],orange:[255,165,0,1],orangered:[255,69,0,1],orchid:[218,112,214,1],palegoldenrod:[238,232,170,1],palegreen:[152,251,152,1],paleturquoise:[175,238,238,1],palevioletred:[219,112,147,1],papayawhip:[255,239,213,1],peachpuff:[255,218,185,1],peru:[205,133,63,1],pink:[255,192,203,1],plum:[221,160,221,1],powderblue:[176,224,230,1],purple:[128,0,128,1],red:[255,0,0,1],rosybrown:[188,143,143,1],royalblue:[65,105,225,1],saddlebrown:[139,69,19,1],salmon:[250,128,114,1],sandybrown:[244,164,96,1],seagreen:[46,139,87,1],seashell:[255,245,238,1],sienna:[160,82,45,1],silver:[192,192,192,1],skyblue:[135,206,235,1],slateblue:[106,90,205,1],slategray:[112,128,144,1],slategrey:[112,128,144,1],snow:[255,250,250,1],springgreen:[0,255,127,1],steelblue:[70,130,180,1],tan:[210,180,140,1],teal:[0,128,128,1],thistle:[216,191,216,1],tomato:[255,99,71,1],turquoise:[64,224,208,1],violet:[238,130,238,1],wheat:[245,222,179,1],white:[255,255,255,1],whitesmoke:[245,245,245,1],yellow:[255,255,0,1],yellowgreen:[154,205,50,1]};function _e(t){return(t=Math.round(t))<0?0:255<t?255:t}function xe(t){return t<0?0:1<t?1:t}function we(t){return t.length&&"%"===t.charAt(t.length-1)?_e(parseFloat(t)/100*255):_e(parseInt(t,10))}function be(t){return t.length&&"%"===t.charAt(t.length-1)?xe(parseFloat(t)/100):xe(parseFloat(t))}function Se(t,e,n){return n<0?n+=1:1<n&&(n-=1),6*n<1?t+(e-t)*n*6:2*n<1?e:3*n<2?t+(e-t)*(2/3-n)*6:t}function Me(t,e,n){return t+(e-t)*n}function Ie(t,e,n,i,r){return t[0]=e,t[1]=n,t[2]=i,t[3]=r,t}function Ce(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t}var Te=new ge(20),Ae=null;function De(t,e){Ae&&Ce(Ae,e),Ae=Te.put(t,Ae||e.slice())}function ke(t,e){if(t){e=e||[];var n=Te.get(t);if(n)return Ce(e,n);var i,r=(t+="").replace(/ /g,"").toLowerCase();if(r in ye)return Ce(e,ye[r]),De(t,e),e;if("#"===r.charAt(0))return 4===r.length?0<=(i=parseInt(r.substr(1),16))&&i<=4095?(Ie(e,(3840&i)>>4|(3840&i)>>8,240&i|(240&i)>>4,15&i|(15&i)<<4,1),De(t,e),e):void Ie(e,0,0,0,1):7===r.length?0<=(i=parseInt(r.substr(1),16))&&i<=16777215?(Ie(e,(16711680&i)>>16,(65280&i)>>8,255&i,1),De(t,e),e):void Ie(e,0,0,0,1):void 0;var a=r.indexOf("("),o=r.indexOf(")");if(-1!==a&&o+1===r.length){var s=r.substr(0,a),l=r.substr(a+1,o-(a+1)).split(","),h=1;switch(s){case"rgba":if(4!==l.length)return void Ie(e,0,0,0,1);h=be(l.pop());case"rgb":return 3!==l.length?void Ie(e,0,0,0,1):(Ie(e,we(l[0]),we(l[1]),we(l[2]),h),De(t,e),e);case"hsla":return 4!==l.length?void Ie(e,0,0,0,1):(l[3]=be(l[3]),Pe(l,e),De(t,e),e);case"hsl":return 3!==l.length?void Ie(e,0,0,0,1):(Pe(l,e),De(t,e),e);default:return}}Ie(e,0,0,0,1)}}function Pe(t,e){var n=(parseFloat(t[0])%360+360)%360/360,i=be(t[1]),r=be(t[2]),a=r<=.5?r*(i+1):r+i-r*i,o=2*r-a;return Ie(e=e||[],_e(255*Se(o,a,n+1/3)),_e(255*Se(o,a,n)),_e(255*Se(o,a,n-1/3)),1),4===t.length&&(e[3]=t[3]),e}function Le(t,e){var n=ke(t);if(n){for(var i=0;i<3;i++)n[i]=e<0?n[i]*(1-e)|0:(255-n[i])*e+n[i]|0,255<n[i]?n[i]=255:t[i]<0&&(n[i]=0);return Fe(n,4===n.length?"rgba":"rgb")}}function Oe(t){var e=ke(t);if(e)return((1<<24)+(e[0]<<16)+(e[1]<<8)+ +e[2]).toString(16).slice(1)}function ze(t,e,n){if(e&&e.length&&0<=t&&t<=1){n=n||[];var i=t*(e.length-1),r=Math.floor(i),a=Math.ceil(i),o=e[r],s=e[a],l=i-r;return n[0]=_e(Me(o[0],s[0],l)),n[1]=_e(Me(o[1],s[1],l)),n[2]=_e(Me(o[2],s[2],l)),n[3]=xe(Me(o[3],s[3],l)),n}}var Ee=ze;function Ne(t,e,n){if(e&&e.length&&0<=t&&t<=1){var i=t*(e.length-1),r=Math.floor(i),a=Math.ceil(i),o=ke(e[r]),s=ke(e[a]),l=i-r,h=Fe([_e(Me(o[0],s[0],l)),_e(Me(o[1],s[1],l)),_e(Me(o[2],s[2],l)),xe(Me(o[3],s[3],l))],"rgba");return n?{color:h,leftIndex:r,rightIndex:a,value:i}:h}}var Re=Ne;function Be(t,e){if((t=ke(t))&&null!=e)return t[3]=xe(e),Fe(t,"rgba")}function Fe(t,e){if(t&&t.length){var n=t[0]+","+t[1]+","+t[2];return"rgba"!==e&&"hsva"!==e&&"hsla"!==e||(n+=","+t[3]),e+"("+n+")"}}var Ve=(Object.freeze||Object)({parse:ke,lift:Le,toHex:Oe,fastLerp:ze,fastMapToColor:Ee,lerp:Ne,mapToColor:Re,modifyHSL:function(t,e,n,i){if(t=ke(t))return t=function(t){if(t){var e,n,i=t[0]/255,r=t[1]/255,a=t[2]/255,o=Math.min(i,r,a),s=Math.max(i,r,a),l=s-o,h=(s+o)/2;if(0==l)n=e=0;else{n=h<.5?l/(s+o):l/(2-s-o);var u=((s-i)/6+l/2)/l,c=((s-r)/6+l/2)/l,d=((s-a)/6+l/2)/l;i===s?e=d-c:r===s?e=1/3+u-d:a===s&&(e=2/3+c-u),e<0&&(e+=1),1<e&&(e-=1)}var f=[360*e,n,h];return null!=t[3]&&f.push(t[3]),f}}(t),null!=e&&(t[0]=function(t){return(t=Math.round(t))<0?0:360<t?360:t}(e)),null!=n&&(t[1]=be(n)),null!=i&&(t[2]=be(i)),Fe(Pe(t),"rgba")},modifyAlpha:Be,stringify:Fe}),He=Array.prototype.slice;function We(t,e){return t[e]}function Ge(t,e,n){t[e]=n}function Ze(t,e,n){return(e-t)*n+t}function Ue(t,e,n){return.5<n?e:t}function Xe(t,e,n,i,r){var a=t.length;if(1===r)for(var o=0;o<a;o++)i[o]=Ze(t[o],e[o],n);else{var s=a&&t[0].length;for(o=0;o<a;o++)for(var l=0;l<s;l++)i[o][l]=Ze(t[o][l],e[o][l],n)}}function Ye(t,e,n){var i=t.length,r=e.length;if(i!==r)if(r<i)t.length=r;else for(var a=i;a<r;a++)t.push(1===n?e[a]:He.call(e[a]));var o=t[0]&&t[0].length;for(a=0;a<t.length;a++)if(1===n)isNaN(t[a])&&(t[a]=e[a]);else for(var s=0;s<o;s++)isNaN(t[a][s])&&(t[a][s]=e[a][s])}function je(t,e,n){if(t===e)return!0;var i=t.length;if(i!==e.length)return!1;if(1===n){for(var r=0;r<i;r++)if(t[r]!==e[r])return!1}else{var a=t[0].length;for(r=0;r<i;r++)for(var o=0;o<a;o++)if(t[r][o]!==e[r][o])return!1}return!0}function qe(t,e,n,i,r,a,o,s,l){var h=t.length;if(1===l)for(var u=0;u<h;u++)s[u]=$e(t[u],e[u],n[u],i[u],r,a,o);else{var c=t[0].length;for(u=0;u<h;u++)for(var d=0;d<c;d++)s[u][d]=$e(t[u][d],e[u][d],n[u][d],i[u][d],r,a,o)}}function $e(t,e,n,i,r,a,o){var s=.5*(n-t),l=.5*(i-e);return(2*(e-n)+s+l)*o+(-3*(e-n)-2*s-l)*a+s*r+e}function Ke(t){if(L(t)){var e=t.length;if(L(t[0])){for(var n=[],i=0;i<e;i++)n.push(He.call(t[i]));return n}return He.call(t)}return t}function Qe(t){return t[0]=Math.floor(t[0]),t[1]=Math.floor(t[1]),t[2]=Math.floor(t[2]),"rgba("+t.join(",")+")"}function Je(t,e,n,i,a,r){var o=t._getter,s=t._setter,l="spline"===e,h=i.length;if(h){var u,c=L(i[0].value),d=!1,f=!1,p=c?function(t){var e=t[t.length-1].value;return L(e&&e[0])?2:1}(i):0;i.sort(function(t,e){return t.time-e.time}),u=i[h-1].time;for(var g=[],m=[],v=i[0].value,y=!0,_=0;_<h;_++){g.push(i[_].time/u);var x=i[_].value;if(c&&je(x,v,p)||!c&&x===v||(y=!1),"string"==typeof(v=x)){var w=ke(x);w?(x=w,d=!0):f=!0}m.push(x)}if(r||!y){var b=m[h-1];for(_=0;_<h-1;_++)c?Ye(m[_],b,p):!isNaN(m[_])||isNaN(b)||f||d||(m[_]=b);c&&Ye(o(t._target,a),b,p);var S,M,I,C,T,A=0,D=0;if(d)var k=[0,0,0,0];var P=new de({target:t._target,life:u,loop:t._loop,delay:t._delay,onframe:function(t,e){var n;if(e<0)n=0;else if(e<D){for(n=Math.min(A+1,h-1);0<=n&&!(g[n]<=e);n--);n=Math.min(n,h-2)}else{for(n=A;n<h&&!(g[n]>e);n++);n=Math.min(n-1,h-2)}D=e;var i=g[(A=n)+1]-g[n];if(0!=i)if(S=(e-g[n])/i,l)if(I=m[n],M=m[0===n?n:n-1],C=m[h-2<n?h-1:n+1],T=m[h-3<n?h-1:n+2],c)qe(M,I,C,T,S,S*S,S*S*S,o(t,a),p);else{if(d)r=qe(M,I,C,T,S,S*S,S*S*S,k,1),r=Qe(k);else{if(f)return Ue(I,C,S);r=$e(M,I,C,T,S,S*S,S*S*S)}s(t,a,r)}else if(c)Xe(m[n],m[n+1],S,o(t,a),p);else{var r;if(d)Xe(m[n],m[n+1],S,k,1),r=Qe(k);else{if(f)return Ue(m[n],m[n+1],S);r=Ze(m[n],m[n+1],S)}s(t,a,r)}},ondestroy:n});return e&&"spline"!==e&&(P.easing=e),P}}}function tn(t,e,n,i){this._tracks={},this._target=t,this._loop=e||!1,this._getter=n||We,this._setter=i||Ge,this._clipCount=0,this._delay=0,this._doneList=[],this._onframeList=[],this._clipList=[]}tn.prototype={when:function(t,e){var n=this._tracks;for(var i in e)if(e.hasOwnProperty(i)){if(!n[i]){n[i]=[];var r=this._getter(this._target,i);if(null==r)continue;0!==t&&n[i].push({time:0,value:Ke(r)})}n[i].push({time:t,value:e[i]})}return this},during:function(t){return this._onframeList.push(t),this},pause:function(){for(var t=0;t<this._clipList.length;t++)this._clipList[t].pause();this._paused=!0},resume:function(){for(var t=0;t<this._clipList.length;t++)this._clipList[t].resume();this._paused=!1},isPaused:function(){return!!this._paused},_doneCallback:function(){this._tracks={},this._clipList.length=0;for(var t=this._doneList,e=t.length,n=0;n<e;n++)t[n].call(this)},start:function(t,e){function n(){--a||r._doneCallback()}var i,r=this,a=0;for(var o in this._tracks)if(this._tracks.hasOwnProperty(o)){var s=Je(this,t,n,this._tracks[o],o,e);s&&(this._clipList.push(s),a++,this.animation&&this.animation.addClip(s),i=s)}if(i){var l=i.onframe;i.onframe=function(t,e){l(t,e);for(var n=0;n<r._onframeList.length;n++)r._onframeList[n](t,e)}}return a||this._doneCallback(),this},stop:function(t){for(var e=this._clipList,n=this.animation,i=0;i<e.length;i++){var r=e[i];t&&r.onframe(this._target,1),n&&n.removeClip(r)}e.length=0},delay:function(t){return this._delay=t,this},done:function(t){return t&&this._doneList.push(t),this},getClips:function(){return this._clipList}};var en=1;"undefined"!=typeof window&&(en=Math.max(window.devicePixelRatio||1,1));var nn=en,rn=function(){};function an(){this.animators=[]}var on=rn;function sn(t,e,n,i,r,a,o,s){E(i)?(a=r,r=i,i=0):z(r)?(a=r,r="linear",i=0):z(i)?(a=i,i=0):n=z(n)?(a=n,500):n||500,t.stopAnimation(),function t(e,n,i,r,a,o,s){var l={};var h=0;for(var u in r)r.hasOwnProperty(u)&&(null!=i[u]?N(r[u])&&!L(r[u])?t(e,n?n+"."+u:u,i[u],r[u],a,o,s):(s?(l[u]=i[u],ln(e,n,u,r[u])):l[u]=r[u],h++):null==r[u]||s||ln(e,n,u,r[u]));0<h&&e.animate(n,!1).when(null==a?500:a,l).delay(o||0)}(t,"",t,e,n,i,s);var l=t.animators.slice(),h=l.length;function u(){--h||a&&a()}h||a&&a();for(var c=0;c<l.length;c++)l[c].done(u).start(r,o)}function ln(t,e,n,i){if(e){var r={};r[e]={},r[e][n]=i,t.attr(r)}else t.attr(n,i)}an.prototype={constructor:an,animate:function(t,e){var n,i=!1,r=this,a=this.__zr;if(t){var o=t.split("."),s=r;i="shape"===o[0];for(var l=0,h=o.length;l<h;l++)s=s&&s[o[l]];s&&(n=s)}else n=r;if(n){var u=r.animators,c=new tn(n,e);return c.during(function(t){r.dirty(i)}).done(function(){u.splice(x(u,c),1)}),u.push(c),a&&a.animation.addAnimator(c),c}on('Property "'+t+'" is not existed in element '+r.id)},stopAnimation:function(t){for(var e=this.animators,n=e.length,i=0;i<n;i++)e[i].stop(t);return e.length=0,this},animateTo:function(t,e,n,i,r,a){sn(this,t,e,n,i,r,a)},animateFrom:function(t,e,n,i,r,a){sn(this,t,e,n,i,r,a,!0)}};var hn=function(t){oe.call(this,t),It.call(this,t),an.call(this,t),this.id=t.id||i()};hn.prototype={type:"element",name:"",__zr:null,ignore:!1,clipPath:null,isGroup:!1,drift:function(t,e){switch(this.draggable){case"horizontal":e=0;break;case"vertical":t=0}var n=this.transform;(n=n||(this.transform=[1,0,0,1,0,0]))[4]+=t,n[5]+=e,this.decomposeTransform(),this.dirty(!1)},beforeUpdate:function(){},afterUpdate:function(){},update:function(){this.updateTransform()},traverse:function(t,e){},attrKV:function(t,e){if("position"===t||"scale"===t||"origin"===t){if(e){var n=this[t];(n=n||(this[t]=[]))[0]=e[0],n[1]=e[1]}}else this[t]=e},hide:function(){this.ignore=!0,this.__zr&&this.__zr.refresh()},show:function(){this.ignore=!1,this.__zr&&this.__zr.refresh()},attr:function(t,e){if("string"==typeof t)this.attrKV(t,e);else if(N(t))for(var n in t)t.hasOwnProperty(n)&&this.attrKV(n,t[n]);return this.dirty(!1),this},setClipPath:function(t){var e=this.__zr;e&&t.addSelfToZr(e),this.clipPath&&this.clipPath!==t&&this.removeClipPath(),(this.clipPath=t).__zr=e,(t.__clipTarget=this).dirty(!1)},removeClipPath:function(){var t=this.clipPath;t&&(t.__zr&&t.removeSelfFromZr(t.__zr),t.__zr=null,t.__clipTarget=null,this.clipPath=null,this.dirty(!1))},addSelfToZr:function(t){this.__zr=t;var e=this.animators;if(e)for(var n=0;n<e.length;n++)t.animation.addAnimator(e[n]);this.clipPath&&this.clipPath.addSelfToZr(t)},removeSelfFromZr:function(t){this.__zr=null;var e=this.animators;if(e)for(var n=0;n<e.length;n++)t.animation.removeAnimator(e[n]);this.clipPath&&this.clipPath.removeSelfFromZr(t)}},S(hn,an),S(hn,oe),S(hn,It);var un,cn,dn,fn,pn=yt,gn=Math.min,mn=Math.max;function vn(t,e,n,i){n<0&&(t+=n,n=-n),i<0&&(e+=i,i=-i),this.x=t,this.y=e,this.width=n,this.height=i}vn.prototype={constructor:vn,union:function(t){var e=gn(t.x,this.x),n=gn(t.y,this.y);this.width=mn(t.x+t.width,this.x+this.width)-e,this.height=mn(t.y+t.height,this.y+this.height)-n,this.x=e,this.y=n},applyTransform:(un=[],cn=[],dn=[],fn=[],function(t){if(t){un[0]=dn[0]=this.x,un[1]=fn[1]=this.y,cn[0]=fn[0]=this.x+this.width,cn[1]=dn[1]=this.y+this.height,pn(un,un,t),pn(cn,cn,t),pn(dn,dn,t),pn(fn,fn,t),this.x=gn(un[0],cn[0],dn[0],fn[0]),this.y=gn(un[1],cn[1],dn[1],fn[1]);var e=mn(un[0],cn[0],dn[0],fn[0]),n=mn(un[1],cn[1],dn[1],fn[1]);this.width=e-this.x,this.height=n-this.y}}),calculateTransform:function(t){var e=t.width/this.width,n=t.height/this.height,i=qt();return Jt(i,i,[-this.x,-this.y]),ee(i,i,[e,n]),Jt(i,i,[t.x,t.y]),i},intersect:function(t){if(!t)return!1;t instanceof vn||(t=vn.create(t));var e=this,n=e.x,i=e.x+e.width,r=e.y,a=e.y+e.height,o=t.x,s=t.x+t.width,l=t.y,h=t.y+t.height;return!(i<o||s<n||a<l||h<r)},contain:function(t,e){var n=this;return t>=n.x&&t<=n.x+n.width&&e>=n.y&&e<=n.y+n.height},clone:function(){return new vn(this.x,this.y,this.width,this.height)},copy:function(t){this.x=t.x,this.y=t.y,this.width=t.width,this.height=t.height},plain:function(){return{x:this.x,y:this.y,width:this.width,height:this.height}}},vn.create=function(t){return new vn(t.x,t.y,t.width,t.height)};var yn=function(t){for(var e in t=t||{},hn.call(this,t),t)t.hasOwnProperty(e)&&(this[e]=t[e]);this._children=[],this.__storage=null,this.__dirty=!0};yn.prototype={constructor:yn,isGroup:!0,type:"group",silent:!1,children:function(){return this._children.slice()},childAt:function(t){return this._children[t]},childOfName:function(t){for(var e=this._children,n=0;n<e.length;n++)if(e[n].name===t)return e[n]},childCount:function(){return this._children.length},add:function(t){return t&&t!==this&&t.parent!==this&&(this._children.push(t),this._doAdd(t)),this},addBefore:function(t,e){if(t&&t!==this&&t.parent!==this&&e&&e.parent===this){var n=this._children,i=n.indexOf(e);0<=i&&(n.splice(i,0,t),this._doAdd(t))}return this},_doAdd:function(t){t.parent&&t.parent.remove(t);var e=(t.parent=this).__storage,n=this.__zr;e&&e!==t.__storage&&(e.addToStorage(t),t instanceof yn&&t.addChildrenToStorage(e)),n&&n.refresh()},remove:function(t){var e=this.__zr,n=this.__storage,i=this._children,r=x(i,t);return r<0||(i.splice(r,1),t.parent=null,n&&(n.delFromStorage(t),t instanceof yn&&t.delChildrenFromStorage(n)),e&&e.refresh()),this},removeAll:function(){var t,e,n=this._children,i=this.__storage;for(e=0;e<n.length;e++)t=n[e],i&&(i.delFromStorage(t),t instanceof yn&&t.delChildrenFromStorage(i)),t.parent=null;return n.length=0,this},eachChild:function(t,e){for(var n=this._children,i=0;i<n.length;i++){var r=n[i];t.call(e,r,i)}return this},traverse:function(t,e){for(var n=0;n<this._children.length;n++){var i=this._children[n];t.call(e,i),"group"===i.type&&i.traverse(t,e)}return this},addChildrenToStorage:function(t){for(var e=0;e<this._children.length;e++){var n=this._children[e];t.addToStorage(n),n instanceof yn&&n.addChildrenToStorage(t)}},delChildrenFromStorage:function(t){for(var e=0;e<this._children.length;e++){var n=this._children[e];t.delFromStorage(n),n instanceof yn&&n.delChildrenFromStorage(t)}},dirty:function(){return this.__dirty=!0,this.__zr&&this.__zr.refresh(),this},getBoundingRect:function(t){for(var e=null,n=new vn(0,0,0,0),i=t||this._children,r=[],a=0;a<i.length;a++){var o=i[a];if(!o.ignore&&!o.invisible){var s=o.getBoundingRect(),l=o.getLocalTransform(r);l?(n.copy(s),n.applyTransform(l),(e=e||n.clone()).union(n)):(e=e||s.clone()).union(s)}}return e||n}},w(yn,hn);var _n=32,xn=7;function wn(t,e,n,i){var r=e+1;if(r===n)return 1;if(i(t[r++],t[e])<0){for(;r<n&&i(t[r],t[r-1])<0;)r++;!function(t,e,n){n--;for(;e<n;){var i=t[e];t[e++]=t[n],t[n--]=i}}(t,e,r)}else for(;r<n&&0<=i(t[r],t[r-1]);)r++;return r-e}function bn(t,e,n,i,r){for(i===e&&i++;i<n;i++){for(var a,o=t[i],s=e,l=i;s<l;)r(o,t[a=s+l>>>1])<0?l=a:s=1+a;var h=i-s;switch(h){case 3:t[s+3]=t[s+2];case 2:t[s+2]=t[s+1];case 1:t[s+1]=t[s];break;default:for(;0<h;)t[s+h]=t[s+h-1],h--}t[s]=o}}function Sn(t,e,n,i,r,a){var o=0,s=0,l=1;if(0<a(t,e[n+r])){for(s=i-r;l<s&&0<a(t,e[n+r+l]);)(l=1+((o=l)<<1))<=0&&(l=s);s<l&&(l=s),o+=r,l+=r}else{for(s=r+1;l<s&&a(t,e[n+r-l])<=0;)(l=1+((o=l)<<1))<=0&&(l=s);s<l&&(l=s);var h=o;o=r-l,l=r-h}for(o++;o<l;){var u=o+(l-o>>>1);0<a(t,e[n+u])?o=u+1:l=u}return l}function Mn(t,e,n,i,r,a){var o=0,s=0,l=1;if(a(t,e[n+r])<0){for(s=r+1;l<s&&a(t,e[n+r-l])<0;)(l=1+((o=l)<<1))<=0&&(l=s);s<l&&(l=s);var h=o;o=r-l,l=r-h}else{for(s=i-r;l<s&&0<=a(t,e[n+r+l]);)(l=1+((o=l)<<1))<=0&&(l=s);s<l&&(l=s),o+=r,l+=r}for(o++;o<l;){var u=o+(l-o>>>1);a(t,e[n+u])<0?l=u:o=u+1}return l}function In(p,g){var o,s,m=xn,l=0,v=[];function e(t){var e=o[t],n=s[t],i=o[t+1],r=s[t+1];s[t]=n+r,t===l-3&&(o[t+1]=o[t+2],s[t+1]=s[t+2]),l--;var a=Mn(p[i],p,e,n,0,g);e+=a,0!==(n-=a)&&0!==(r=Sn(p[e+n-1],p,i,r,r-1,g))&&(n<=r?function(t,e,n,i){var r=0;for(r=0;r<e;r++)v[r]=p[t+r];var a=0,o=n,s=t;if(p[s++]=p[o++],0==--i){for(r=0;r<e;r++)p[s+r]=v[a+r];return}if(1===e){for(r=0;r<i;r++)p[s+r]=p[o+r];return p[s+i]=v[a]}var l,h,u,c=m;for(;;){h=l=0,u=!1;do{if(g(p[o],v[a])<0){if(p[s++]=p[o++],h++,(l=0)==--i){u=!0;break}}else if(p[s++]=v[a++],l++,h=0,1==--e){u=!0;break}}while((l|h)<c);if(u)break;do{if(0!==(l=Mn(p[o],v,a,e,0,g))){for(r=0;r<l;r++)p[s+r]=v[a+r];if(s+=l,a+=l,(e-=l)<=1){u=!0;break}}if(p[s++]=p[o++],0==--i){u=!0;break}if(0!==(h=Sn(v[a],p,o,i,0,g))){for(r=0;r<h;r++)p[s+r]=p[o+r];if(s+=h,o+=h,0===(i-=h)){u=!0;break}}if(p[s++]=v[a++],1==--e){u=!0;break}c--}while(xn<=l||xn<=h);if(u)break;c<0&&(c=0),c+=2}if((m=c)<1&&(m=1),1===e){for(r=0;r<i;r++)p[s+r]=p[o+r];p[s+i]=v[a]}else{if(0===e)throw new Error;for(r=0;r<e;r++)p[s+r]=v[a+r]}}(e,n,i,r):function(t,e,n,i){var r=0;for(r=0;r<i;r++)v[r]=p[n+r];var a=t+e-1,o=i-1,s=n+i-1,l=0,h=0;if(p[s--]=p[a--],0==--e){for(l=s-(i-1),r=0;r<i;r++)p[l+r]=v[r];return}if(1===i){for(h=(s-=e)+1,l=(a-=e)+1,r=e-1;0<=r;r--)p[h+r]=p[l+r];return p[s]=v[o]}var u=m;for(;;){var c=0,d=0,f=!1;do{if(g(v[o],p[a])<0){if(p[s--]=p[a--],c++,(d=0)==--e){f=!0;break}}else if(p[s--]=v[o--],d++,c=0,1==--i){f=!0;break}}while((c|d)<u);if(f)break;do{if(0!==(c=e-Mn(v[o],p,t,e,e-1,g))){for(e-=c,h=(s-=c)+1,l=(a-=c)+1,r=c-1;0<=r;r--)p[h+r]=p[l+r];if(0===e){f=!0;break}}if(p[s--]=v[o--],1==--i){f=!0;break}if(0!==(d=i-Sn(p[a],v,0,i,i-1,g))){for(i-=d,h=(s-=d)+1,l=(o-=d)+1,r=0;r<d;r++)p[h+r]=v[l+r];if(i<=1){f=!0;break}}if(p[s--]=p[a--],0==--e){f=!0;break}u--}while(xn<=c||xn<=d);if(f)break;u<0&&(u=0),u+=2}(m=u)<1&&(m=1);if(1===i){for(h=(s-=e)+1,l=(a-=e)+1,r=e-1;0<=r;r--)p[h+r]=p[l+r];p[s]=v[o]}else{if(0===i)throw new Error;for(l=s-(i-1),r=0;r<i;r++)p[l+r]=v[r]}}(e,n,i,r))}o=[],s=[],this.mergeRuns=function(){for(;1<l;){var t=l-2;if(1<=t&&s[t-1]<=s[t]+s[t+1]||2<=t&&s[t-2]<=s[t]+s[t-1])s[t-1]<s[t+1]&&t--;else if(s[t]>s[t+1])break;e(t)}},this.forceMergeRuns=function(){for(;1<l;){var t=l-2;0<t&&s[t-1]<s[t+1]&&t--,e(t)}},this.pushRun=function(t,e){o[l]=t,s[l]=e,l+=1}}function Cn(t,e,n,i){n=n||0;var r=(i=i||t.length)-n;if(!(r<2)){var a=0;if(r<_n)bn(t,n,i,n+(a=wn(t,n,i,e)),e);else{var o=new In(t,e),s=function(t){for(var e=0;_n<=t;)e|=1&t,t>>=1;return t+e}(r);do{if((a=wn(t,n,i,e))<s){var l=r;s<l&&(l=s),bn(t,n,n+l,n+a,e),a=l}o.pushRun(n,a),o.mergeRuns(),r-=a,n+=a}while(0!==r);o.forceMergeRuns()}}}function Tn(t,e){return t.zlevel===e.zlevel?t.z===e.z?t.z2-e.z2:t.z-e.z:t.zlevel-e.zlevel}function An(){this._roots=[],this._displayList=[],this._displayListLen=0}An.prototype={constructor:An,traverse:function(t,e){for(var n=0;n<this._roots.length;n++)this._roots[n].traverse(t,e)},getDisplayList:function(t,e){return e=e||!1,t&&this.updateDisplayList(e),this._displayList},updateDisplayList:function(t){this._displayListLen=0;for(var e=this._roots,n=this._displayList,i=0,r=e.length;i<r;i++)this._updateAndAddDisplayable(e[i],null,t);n.length=this._displayListLen,v.canvasSupported&&Cn(n,Tn)},_updateAndAddDisplayable:function(t,e,n){if(!t.ignore||n){t.beforeUpdate(),t.__dirty&&t.update(),t.afterUpdate();var i=t.clipPath;if(i){e=e?e.slice():[];for(var r=i,a=t;r;)r.parent=a,r.updateTransform(),e.push(r),r=(a=r).clipPath}if(t.isGroup){for(var o=t._children,s=0;s<o.length;s++){var l=o[s];t.__dirty&&(l.__dirty=!0),this._updateAndAddDisplayable(l,e,n)}t.__dirty=!1}else t.__clipPaths=e,this._displayList[this._displayListLen++]=t}},addRoot:function(t){t.__storage!==this&&(t instanceof yn&&t.addChildrenToStorage(this),this.addToStorage(t),this._roots.push(t))},delRoot:function(t){if(null==t){for(var e=0;e<this._roots.length;e++){var n=this._roots[e];n instanceof yn&&n.delChildrenFromStorage(this)}return this._roots=[],this._displayList=[],void(this._displayListLen=0)}if(t instanceof Array){e=0;for(var i=t.length;e<i;e++)this.delRoot(t[e])}else{var r=x(this._roots,t);0<=r&&(this.delFromStorage(t),this._roots.splice(r,1),t instanceof yn&&t.delChildrenFromStorage(this))}},addToStorage:function(t){return t&&(t.__storage=this,t.dirty(!1)),this},delFromStorage:function(t){return t&&(t.__storage=null),this},dispose:function(){this._renderList=this._roots=null},displayableSortFunc:Tn};var Dn={shadowBlur:1,shadowOffsetX:1,shadowOffsetY:1,textShadowBlur:1,textShadowOffsetX:1,textShadowOffsetY:1,textBoxShadowBlur:1,textBoxShadowOffsetX:1,textBoxShadowOffsetY:1},kn=function(t,e,n){return Dn.hasOwnProperty(e)?n*t.dpr:n},Pn={NONE:0,STYLE_BIND:1,PLAIN_TEXT:2},Ln=9,On=[["shadowBlur",0],["shadowOffsetX",0],["shadowOffsetY",0],["shadowColor","#000"],["lineCap","butt"],["lineJoin","miter"],["miterLimit",10]],zn=function(t){this.extendFrom(t,!1)};function En(t,e,n){var i=null==e.x?0:e.x,r=null==e.x2?1:e.x2,a=null==e.y?0:e.y,o=null==e.y2?0:e.y2;return e.global||(i=i*n.width+n.x,r=r*n.width+n.x,a=a*n.height+n.y,o=o*n.height+n.y),i=isNaN(i)?0:i,r=isNaN(r)?1:r,a=isNaN(a)?0:a,o=isNaN(o)?0:o,t.createLinearGradient(i,a,r,o)}function Nn(t,e,n){var i=n.width,r=n.height,a=Math.min(i,r),o=null==e.x?.5:e.x,s=null==e.y?.5:e.y,l=null==e.r?.5:e.r;return e.global||(o=o*i+n.x,s=s*r+n.y,l*=a),t.createRadialGradient(o,s,0,o,s,l)}zn.prototype={constructor:zn,fill:"#000",stroke:null,opacity:1,fillOpacity:null,strokeOpacity:null,lineDash:null,lineDashOffset:0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,lineWidth:1,strokeNoScale:!1,text:null,font:null,textFont:null,fontStyle:null,fontWeight:null,fontSize:null,fontFamily:null,textTag:null,textFill:"#000",textStroke:null,textWidth:null,textHeight:null,textStrokeWidth:0,textLineHeight:null,textPosition:"inside",textRect:null,textOffset:null,textAlign:null,textVerticalAlign:null,textDistance:5,textShadowColor:"transparent",textShadowBlur:0,textShadowOffsetX:0,textShadowOffsetY:0,textBoxShadowColor:"transparent",textBoxShadowBlur:0,textBoxShadowOffsetX:0,textBoxShadowOffsetY:0,transformText:!1,textRotation:0,textOrigin:null,textBackgroundColor:null,textBorderColor:null,textBorderWidth:0,textBorderRadius:0,textPadding:null,rich:null,truncate:null,blend:null,bind:function(t,e,n){var i=this,r=n&&n.style,a=!r||t.__attrCachedBy!==Pn.STYLE_BIND;t.__attrCachedBy=Pn.STYLE_BIND;for(var o=0;o<On.length;o++){var s=On[o],l=s[0];!a&&i[l]===r[l]||(t[l]=kn(t,l,i[l]||s[1]))}if(!a&&i.fill===r.fill||(t.fillStyle=i.fill),!a&&i.stroke===r.stroke||(t.strokeStyle=i.stroke),!a&&i.opacity===r.opacity||(t.globalAlpha=null==i.opacity?1:i.opacity),!a&&i.blend===r.blend||(t.globalCompositeOperation=i.blend||"source-over"),this.hasStroke()){var h=i.lineWidth;t.lineWidth=h/(this.strokeNoScale&&e&&e.getLineScale?e.getLineScale():1)}},hasFill:function(){var t=this.fill;return null!=t&&"none"!==t},hasStroke:function(){var t=this.stroke;return null!=t&&"none"!==t&&0<this.lineWidth},extendFrom:function(t,e){if(t)for(var n in t)!t.hasOwnProperty(n)||!0!==e&&(!1===e?this.hasOwnProperty(n):null==t[n])||(this[n]=t[n])},set:function(t,e){"string"==typeof t?this[t]=e:this.extendFrom(t,!0)},clone:function(){var t=new this.constructor;return t.extendFrom(this,!0),t},getGradient:function(t,e,n){for(var i=("radial"===e.type?Nn:En)(t,e,n),r=e.colorStops,a=0;a<r.length;a++)i.addColorStop(r[a].offset,r[a].color);return i}};for(var Rn=zn.prototype,Bn=0;Bn<On.length;Bn++){var Fn=On[Bn];Fn[0]in Rn||(Rn[Fn[0]]=Fn[1])}zn.getGradient=Rn.getGradient;function Vn(t,e){this.image=t,this.repeat=e,this.type="pattern"}function Hn(){return!1}function Wn(t,e,n){var i=g(),r=e.getWidth(),a=e.getHeight(),o=i.style;return o&&(o.position="absolute",o.left=0,o.top=0,o.width=r+"px",o.height=a+"px",i.setAttribute("data-zr-dom-id",t)),i.width=r*n,i.height=a*n,i}function Gn(t,e,n){var i;n=n||nn,"string"==typeof t?i=Wn(t,e,n):N(t)&&(t=(i=t).id),this.id=t;var r=(this.dom=i).style;r&&(i.onselectstart=Hn,r["-webkit-user-select"]="none",r["user-select"]="none",r["-webkit-touch-callout"]="none",r["-webkit-tap-highlight-color"]="rgba(0,0,0,0)",r.padding=0,r.margin=0,r["border-width"]=0),this.domBack=null,this.ctxBack=null,this.painter=e,this.config=null,this.clearColor=0,this.motionBlur=!1,this.lastFrameAlpha=.7,this.dpr=n}Gn.prototype={constructor:Gn,__dirty:!0,__used:!(Vn.prototype.getCanvasPattern=function(t){return t.createPattern(this.image,this.repeat||"repeat")}),__drawIndex:0,__startIndex:0,__endIndex:0,incremental:!1,getElementCount:function(){return this.__endIndex-this.__startIndex},initContext:function(){this.ctx=this.dom.getContext("2d"),this.ctx.dpr=this.dpr},createBackBuffer:function(){var t=this.dpr;this.domBack=Wn("back-"+this.id,this.painter,t),this.ctxBack=this.domBack.getContext("2d"),1!==t&&this.ctxBack.scale(t,t)},resize:function(t,e){var n=this.dpr,i=this.dom,r=i.style,a=this.domBack;r&&(r.width=t+"px",r.height=e+"px"),i.width=t*n,i.height=e*n,a&&(a.width=t*n,a.height=e*n,1!==n&&this.ctxBack.scale(n,n))},clear:function(t,e){var n,i=this.dom,r=this.ctx,a=i.width,o=i.height,s=(e=e||this.clearColor,this.motionBlur&&!t),l=this.lastFrameAlpha,h=this.dpr;s&&(this.domBack||this.createBackBuffer(),this.ctxBack.globalCompositeOperation="copy",this.ctxBack.drawImage(i,0,0,a/h,o/h)),r.clearRect(0,0,a,o),e&&"transparent"!==e&&(e.colorStops?(n=e.__canvasGradient||zn.getGradient(r,e,{x:0,y:0,width:a,height:o}),e.__canvasGradient=n):e.image&&(n=Vn.prototype.getCanvasPattern.call(e,r)),r.save(),r.fillStyle=n||e,r.fillRect(0,0,a,o),r.restore());if(s){var u=this.domBack;r.save(),r.globalAlpha=l,r.drawImage(u,0,0,a,o),r.restore()}}};var Zn="undefined"!=typeof window&&(window.requestAnimationFrame&&window.requestAnimationFrame.bind(window)||window.msRequestAnimationFrame&&window.msRequestAnimationFrame.bind(window)||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame)||function(t){setTimeout(t,16)},Un=new ge(50);function Xn(t){if("string"!=typeof t)return t;var e=Un.get(t);return e&&e.image}function Yn(t,e,n,i,r){if(t){if("string"!=typeof t)return t;if(e&&e.__zrImageSrc===t||!n)return e;var a=Un.get(t),o={hostEl:n,cb:i,cbPayload:r};return a?qn(e=a.image)||a.pending.push(o):((e=new Image).onload=e.onerror=jn,Un.put(t,e.__cachedImgObj={image:e,pending:[o]}),e.src=e.__zrImageSrc=t),e}return e}function jn(){var t=this.__cachedImgObj;this.onload=this.onerror=this.__cachedImgObj=null;for(var e=0;e<t.pending.length;e++){var n=t.pending[e],i=n.cb;i&&i(this,n.cbPayload),n.hostEl.dirty()}t.pending.length=0}function qn(t){return t&&t.width&&t.height}var $n={},Kn=0,Qn=5e3,Jn=/\{([a-zA-Z0-9_]+)\|([^}]*)\}/g,ti="12px sans-serif",ei={};function ni(t,e){var n=t+":"+(e=e||ti);if($n[n])return $n[n];for(var i,r,a=(t+"").split("\n"),o=0,s=0,l=a.length;s<l;s++)o=Math.max((i=a[s],r=e,ei.measureText(i,r)).width,o);return Qn<Kn&&(Kn=0,$n={}),Kn++,$n[n]=o}function ii(t,e,n,i,r,a,o,s){return o?function(t,e,n,i,r,a,o,s){var l=fi(t,{rich:o,truncate:s,font:e,textAlign:n,textPadding:r,textLineHeight:a}),h=l.outerWidth,u=l.outerHeight,c=ri(0,h,n),d=ai(0,u,i);return new vn(c,d,h,u)}(t,e,n,i,r,a,o,s):function(t,e,n,i,r,a,o){var s=di(t,e,r,a,o),l=ni(t,e);r&&(l+=r[1]+r[3]);var h=s.outerHeight,u=ri(0,l,n),c=ai(0,h,i),d=new vn(u,c,l,h);return d.lineHeight=s.lineHeight,d}(t,e,n,i,r,a,s)}function ri(t,e,n){return"right"===n?t-=e:"center"===n&&(t-=e/2),t}function ai(t,e,n){return"middle"===n?t-=e/2:"bottom"===n&&(t-=e),t}function oi(t,e,n){var i=e.textPosition,r=e.textDistance,a=n.x,o=n.y,s=n.height,l=n.width,h=s/2,u="left",c="top";switch(i){case"left":a-=r,o+=h,u="right",c="middle";break;case"right":a+=r+l,o+=h,c="middle";break;case"top":a+=l/2,o-=r,u="center",c="bottom";break;case"bottom":a+=l/2,o+=s+r,u="center";break;case"inside":a+=l/2,o+=h,u="center",c="middle";break;case"insideLeft":a+=r,o+=h,c="middle";break;case"insideRight":a+=l-r,o+=h,u="right",c="middle";break;case"insideTop":a+=l/2,o+=r,u="center";break;case"insideBottom":a+=l/2,o+=s-r,u="center",c="bottom";break;case"insideTopLeft":a+=r,o+=r;break;case"insideTopRight":a+=l-r,o+=r,u="right";break;case"insideBottomLeft":a+=r,o+=s-r,c="bottom";break;case"insideBottomRight":a+=l-r,o+=s-r,u="right",c="bottom"}return(t=t||{}).x=a,t.y=o,t.textAlign=u,t.textVerticalAlign=c,t}function si(t,e,n,i,r){if(!e)return"";var a=(t+"").split("\n");r=li(e,n,i,r);for(var o=0,s=a.length;o<s;o++)a[o]=hi(a[o],r);return a.join("\n")}function li(t,e,n,i){(i=I({},i)).font=e;n=W(n,"...");i.maxIterations=W(i.maxIterations,2);var r=i.minChar=W(i.minChar,0);i.cnCharWidth=ni("国",e);var a=i.ascCharWidth=ni("a",e);i.placeholder=W(i.placeholder,"");for(var o=t=Math.max(0,t-1),s=0;s<r&&a<=o;s++)o-=a;var l=ni(n,e);return o<l&&(n="",l=0),o=t-l,i.ellipsis=n,i.ellipsisWidth=l,i.contentWidth=o,i.containerWidth=t,i}function hi(t,e){var n=e.containerWidth,i=e.font,r=e.contentWidth;if(!n)return"";var a=ni(t,i);if(a<=n)return t;for(var o=0;;o++){if(a<=r||o>=e.maxIterations){t+=e.ellipsis;break}var s=0===o?ui(t,r,e.ascCharWidth,e.cnCharWidth):0<a?Math.floor(t.length*r/a):0;a=ni(t=t.substr(0,s),i)}return""===t&&(t=e.placeholder),t}function ui(t,e,n,i){for(var r=0,a=0,o=t.length;a<o&&r<e;a++){var s=t.charCodeAt(a);r+=0<=s&&s<=127?n:i}return a}function ci(t){return ni("国",t)}function di(t,e,n,i,r){null!=t&&(t+="");var a=W(i,ci(e)),o=t?t.split("\n"):[],s=o.length*a,l=s;if(n&&(l+=n[0]+n[2]),t&&r){var h=r.outerHeight,u=r.outerWidth;if(null!=h&&h<l)t="",o=[];else if(null!=u)for(var c=li(u-(n?n[1]+n[3]:0),e,r.ellipsis,{minChar:r.minChar,placeholder:r.placeholder}),d=0,f=o.length;d<f;d++)o[d]=hi(o[d],c)}return{lines:o,height:s,outerHeight:l,lineHeight:a}}function fi(t,e){var n={lines:[],width:0,height:0};if(null!=t&&(t+=""),!t)return n;for(var i,r=Jn.lastIndex=0;null!=(i=Jn.exec(t));){var a=i.index;r<a&&pi(n,t.substring(r,a)),pi(n,i[2],i[1]),r=Jn.lastIndex}r<t.length&&pi(n,t.substring(r,t.length));var o=n.lines,s=0,l=0,h=[],u=e.textPadding,c=e.truncate,d=c&&c.outerWidth,f=c&&c.outerHeight;u&&(null!=d&&(d-=u[1]+u[3]),null!=f&&(f-=u[0]+u[2]));for(var p=0;p<o.length;p++){for(var g=o[p],m=0,v=0,y=0;y<g.tokens.length;y++){var _=(D=g.tokens[y]).styleName&&e.rich[D.styleName]||{},x=D.textPadding=_.textPadding,w=D.font=_.font||e.font,b=D.textHeight=W(_.textHeight,ci(w));if(x&&(b+=x[0]+x[2]),D.height=b,D.lineHeight=G(_.textLineHeight,e.textLineHeight,b),D.textAlign=_&&_.textAlign||e.textAlign,D.textVerticalAlign=_&&_.textVerticalAlign||"middle",null!=f&&s+D.lineHeight>f)return{lines:[],width:0,height:0};D.textWidth=ni(D.text,w);var S=_.textWidth,M=null==S||"auto"===S;if("string"==typeof S&&"%"===S.charAt(S.length-1))D.percentWidth=S,h.push(D),S=0;else{if(M){S=D.textWidth;var I=_.textBackgroundColor,C=I&&I.image;C&&qn(C=Xn(C))&&(S=Math.max(S,C.width*b/C.height))}var T=x?x[1]+x[3]:0;S+=T;var A=null!=d?d-v:null;null!=A&&A<S&&(!M||A<T?(D.text="",D.textWidth=S=0):(D.text=si(D.text,A-T,w,c.ellipsis,{minChar:c.minChar}),D.textWidth=ni(D.text,w),S=D.textWidth+T))}v+=D.width=S,_&&(m=Math.max(m,D.lineHeight))}g.width=v,s+=g.lineHeight=m,l=Math.max(l,v)}n.outerWidth=n.width=W(e.textWidth,l),n.outerHeight=n.height=W(e.textHeight,s),u&&(n.outerWidth+=u[1]+u[3],n.outerHeight+=u[0]+u[2]);for(p=0;p<h.length;p++){var D,k=(D=h[p]).percentWidth;D.width=parseInt(k,10)/100*l}return n}function pi(t,e,n){for(var i=""===e,r=e.split("\n"),a=t.lines,o=0;o<r.length;o++){var s=r[o],l={styleName:n,text:s,isLineHolder:!s&&!i};if(o)a.push({tokens:[l]});else{var h=(a[a.length-1]||(a[0]={tokens:[]})).tokens,u=h.length;1===u&&h[0].isLineHolder?h[0]=l:!s&&u&&!i||h.push(l)}}}function gi(t){var e=(t.fontSize||t.fontFamily)&&[t.fontStyle,t.fontWeight,(t.fontSize||12)+"px",t.fontFamily||"sans-serif"].join(" ");return e&&Y(e)||t.textFont||t.font}function mi(t,e){var n,i,r,a,o,s=e.x,l=e.y,h=e.width,u=e.height,c=e.r;h<0&&(s+=h,h=-h),u<0&&(l+=u,u=-u),"number"==typeof c?n=i=r=a=c:c instanceof Array?1===c.length?n=i=r=a=c[0]:2===c.length?(n=r=c[0],i=a=c[1]):3===c.length?(n=c[0],i=a=c[1],r=c[2]):(n=c[0],i=c[1],r=c[2],a=c[3]):n=i=r=a=0,h<n+i&&(n*=h/(o=n+i),i*=h/o),h<r+a&&(r*=h/(o=r+a),a*=h/o),u<i+r&&(i*=u/(o=i+r),r*=u/o),u<n+a&&(n*=u/(o=n+a),a*=u/o),t.moveTo(s+n,l),t.lineTo(s+h-i,l),0!==i&&t.arc(s+h-i,l+i,i,-Math.PI/2,0),t.lineTo(s+h,l+u-r),0!==r&&t.arc(s+h-r,l+u-r,r,0,Math.PI/2),t.lineTo(s+a,l+u),0!==a&&t.arc(s+a,l+u-a,a,Math.PI/2,Math.PI),t.lineTo(s,l+n),0!==n&&t.arc(s+n,l+n,n,Math.PI,1.5*Math.PI)}ei.measureText=function(t,e){var n=_();return n.font=e||ti,n.measureText(t)};var vi=ti,yi={left:1,right:1,center:1},_i={top:1,bottom:1,middle:1},xi=[["textShadowBlur","shadowBlur",0],["textShadowOffsetX","shadowOffsetX",0],["textShadowOffsetY","shadowOffsetY",0],["textShadowColor","shadowColor","transparent"]],wi={},bi={};function Si(t){return Mi(t),A(t.rich,Mi),t}function Mi(t){if(t){t.font=gi(t);var e=t.textAlign;"middle"===e&&(e="center"),t.textAlign=null==e||yi[e]?e:"left";var n=t.textVerticalAlign||t.textBaseline;"center"===n&&(n="middle"),t.textVerticalAlign=null==n||_i[n]?n:"top",t.textPadding&&(t.textPadding=U(t.textPadding))}}function Ii(t,e,n,i,r,a){i.rich?function(t,e,n,i,r,a){a!==Ln&&(e.__attrCachedBy=Pn.NONE);var o=t.__textCotentBlock;o&&!t.__dirtyText||(o=t.__textCotentBlock=fi(n,i));!function(t,e,n,i,r){var a=n.width,o=n.outerWidth,s=n.outerHeight,l=i.textPadding,h=Pi(bi,t,i,r),u=h.baseX,c=h.baseY,d=h.textAlign,f=h.textVerticalAlign;Ci(e,i,r,u,c);var p=ri(u,o,d),g=ai(c,s,f),m=p,v=g;l&&(m+=l[3],v+=l[0]);var y=m+a;Ai(i)&&Di(t,e,i,p,g,o,s);for(var _=0;_<n.lines.length;_++){for(var x,w=n.lines[_],b=w.tokens,S=b.length,M=w.lineHeight,I=w.width,C=0,T=m,A=y,D=S-1;C<S&&(!(x=b[C]).textAlign||"left"===x.textAlign);)Ti(t,e,x,i,M,v,T,"left"),I-=x.width,T+=x.width,C++;for(;0<=D&&"right"===(x=b[D]).textAlign;)Ti(t,e,x,i,M,v,A,"right"),I-=x.width,A-=x.width,D--;for(T+=(a-(T-m)-(y-A)-I)/2;C<=D;)x=b[C],Ti(t,e,x,i,M,v,T+x.width/2,"center"),T+=x.width,C++;v+=M}}(t,e,o,i,r)}(t,e,n,i,r,a):function(t,e,n,i,r,a){var o,s=Ai(i),l=!1,h=e.__attrCachedBy===Pn.PLAIN_TEXT;a!==Ln?(a&&(o=a.style,l=!s&&h&&o),e.__attrCachedBy=s?Pn.NONE:Pn.PLAIN_TEXT):h&&(e.__attrCachedBy=Pn.NONE);var u=i.font||vi;l&&u===(o.font||vi)||(e.font=u);var c=t.__computedFont;t.__styleFont!==u&&(t.__styleFont=u,c=t.__computedFont=e.font);var d=i.textPadding,f=i.textLineHeight,p=t.__textCotentBlock;p&&!t.__dirtyText||(p=t.__textCotentBlock=di(n,c,d,f,i.truncate));var g=p.outerHeight,m=p.lines,v=p.lineHeight,y=Pi(bi,t,i,r),_=y.baseX,x=y.baseY,w=y.textAlign||"left",b=y.textVerticalAlign;Ci(e,i,r,_,x);var S=ai(x,g,b),M=_,I=S;if(s||d){var C=ni(n,c);d&&(C+=d[1]+d[3]);var T=ri(_,C,w);s&&Di(t,e,i,T,S,C,g),d&&(M=Ni(_,w,d),I+=d[0])}e.textAlign=w,e.textBaseline="middle",e.globalAlpha=i.opacity||1;for(var A=0;A<xi.length;A++){var D=xi[A],k=D[0],P=D[1],L=i[k];l&&L===o[k]||(e[P]=kn(e,P,L||D[2]))}I+=v/2;var O=i.textStrokeWidth,z=l?o.textStrokeWidth:null,E=!l||O!==z,N=!l||E||i.textStroke!==o.textStroke,R=Oi(i.textStroke,O),B=zi(i.textFill);R&&(E&&(e.lineWidth=O),N&&(e.strokeStyle=R));B&&(l&&i.textFill===o.textFill||(e.fillStyle=B));if(1===m.length)R&&e.strokeText(m[0],M,I),B&&e.fillText(m[0],M,I);else for(A=0;A<m.length;A++)R&&e.strokeText(m[A],M,I),B&&e.fillText(m[A],M,I),I+=v}(t,e,n,i,r,a)}function Ci(t,e,n,i,r){if(n&&e.textRotation){var a=e.textOrigin;"center"===a?(i=n.width/2+n.x,r=n.height/2+n.y):a&&(i=a[0]+n.x,r=a[1]+n.y),t.translate(i,r),t.rotate(-e.textRotation),t.translate(-i,-r)}}function Ti(t,e,n,i,r,a,o,s){var l=i.rich[n.styleName]||{};l.text=n.text;var h=n.textVerticalAlign,u=a+r/2;"top"===h?u=a+n.height/2:"bottom"===h&&(u=a+r-n.height/2),!n.isLineHolder&&Ai(l)&&Di(t,e,l,"right"===s?o-n.width:"center"===s?o-n.width/2:o,u-n.height/2,n.width,n.height);var c=n.textPadding;c&&(o=Ni(o,s,c),u-=n.height/2-c[2]-n.textHeight/2),Li(e,"shadowBlur",G(l.textShadowBlur,i.textShadowBlur,0)),Li(e,"shadowColor",l.textShadowColor||i.textShadowColor||"transparent"),Li(e,"shadowOffsetX",G(l.textShadowOffsetX,i.textShadowOffsetX,0)),Li(e,"shadowOffsetY",G(l.textShadowOffsetY,i.textShadowOffsetY,0)),Li(e,"textAlign",s),Li(e,"textBaseline","middle"),Li(e,"font",n.font||vi);var d=Oi(l.textStroke||i.textStroke,p),f=zi(l.textFill||i.textFill),p=W(l.textStrokeWidth,i.textStrokeWidth);d&&(Li(e,"lineWidth",p),Li(e,"strokeStyle",d),e.strokeText(n.text,o,u)),f&&(Li(e,"fillStyle",f),e.fillText(n.text,o,u))}function Ai(t){return!!(t.textBackgroundColor||t.textBorderWidth&&t.textBorderColor)}function Di(t,e,n,i,r,a,o){var s=n.textBackgroundColor,l=n.textBorderWidth,h=n.textBorderColor,u=E(s);if(Li(e,"shadowBlur",n.textBoxShadowBlur||0),Li(e,"shadowColor",n.textBoxShadowColor||"transparent"),Li(e,"shadowOffsetX",n.textBoxShadowOffsetX||0),Li(e,"shadowOffsetY",n.textBoxShadowOffsetY||0),u||l&&h){e.beginPath();var c=n.textBorderRadius;c?mi(e,{x:i,y:r,width:a,height:o,r:c}):e.rect(i,r,a,o),e.closePath()}if(u)if(Li(e,"fillStyle",s),null!=n.fillOpacity){var d=e.globalAlpha;e.globalAlpha=n.fillOpacity*n.opacity,e.fill(),e.globalAlpha=d}else e.fill();else if(N(s)){var f=s.image;(f=Yn(f,null,t,ki,s))&&qn(f)&&e.drawImage(f,i,r,a,o)}if(l&&h)if(Li(e,"lineWidth",l),Li(e,"strokeStyle",h),null!=n.strokeOpacity){d=e.globalAlpha;e.globalAlpha=n.strokeOpacity*n.opacity,e.stroke(),e.globalAlpha=d}else e.stroke()}function ki(t,e){e.image=t}function Pi(t,e,n,i){var r=n.x||0,a=n.y||0,o=n.textAlign,s=n.textVerticalAlign;if(i){var l=n.textPosition;if(l instanceof Array)r=i.x+Ei(l[0],i.width),a=i.y+Ei(l[1],i.height);else{var h=e&&e.calculateTextPosition?e.calculateTextPosition(wi,n,i):oi(wi,n,i);r=h.x,a=h.y,o=o||h.textAlign,s=s||h.textVerticalAlign}var u=n.textOffset;u&&(r+=u[0],a+=u[1])}return(t=t||{}).baseX=r,t.baseY=a,t.textAlign=o,t.textVerticalAlign=s,t}function Li(t,e,n){return t[e]=kn(t,e,n),t[e]}function Oi(t,e){return null==t||e<=0||"transparent"===t||"none"===t?null:t.image||t.colorStops?"#000":t}function zi(t){return null==t||"none"===t?null:t.image||t.colorStops?"#000":t}function Ei(t,e){return"string"==typeof t?0<=t.lastIndexOf("%")?parseFloat(t)/100*e:parseFloat(t):t}function Ni(t,e,n){return"right"===e?t-n[1]:"center"===e?t+n[3]/2-n[1]/2:t+n[3]}function Ri(t,e){return null!=t&&(t||e.textBackgroundColor||e.textBorderWidth&&e.textBorderColor||e.textPadding)}function Bi(){}var Fi=new vn;function Vi(t){for(var e in t=t||{},hn.call(this,t),t)t.hasOwnProperty(e)&&"style"!==e&&(this[e]=t[e]);this.style=new zn(t.style,this),this._rect=null,this.__clipPaths=null}function Hi(t){Vi.call(this,t)}Vi.prototype={constructor:Vi,type:"displayable",__dirty:!0,invisible:!(Bi.prototype={constructor:Bi,drawRectText:function(t,e){var n=this.style;e=n.textRect||e,this.__dirty&&Si(n);var i=n.text;if(null!=i&&(i+=""),Ri(i,n)){t.save();var r=this.transform;n.transformText?this.setTransform(t):r&&(Fi.copy(e),Fi.applyTransform(r),e=Fi),Ii(this,t,i,n,e,Ln),t.restore()}}}),z:0,z2:0,zlevel:0,draggable:!1,dragging:!1,silent:!1,culling:!1,cursor:"pointer",rectHover:!1,progressive:!1,incremental:!1,globalScaleRatio:1,beforeBrush:function(t){},afterBrush:function(t){},brush:function(t,e){},getBoundingRect:function(){},contain:function(t,e){return this.rectContain(t,e)},traverse:function(t,e){t.call(e,this)},rectContain:function(t,e){var n=this.transformCoordToLocal(t,e);return this.getBoundingRect().contain(n[0],n[1])},dirty:function(){this.__dirty=this.__dirtyText=!0,this._rect=null,this.__zr&&this.__zr.refresh()},animateStyle:function(t){return this.animate("style",t)},attrKV:function(t,e){"style"!==t?hn.prototype.attrKV.call(this,t,e):this.style.set(e)},setStyle:function(t,e){return this.style.set(t,e),this.dirty(!1),this},useStyle:function(t){return this.style=new zn(t,this),this.dirty(!1),this},calculateTextPosition:null},w(Vi,hn),S(Vi,Bi),Hi.prototype={constructor:Hi,type:"image",brush:function(t,e){var n=this.style,i=n.image;n.bind(t,this,e);var r=this._image=Yn(i,this._image,this,this.onload);if(r&&qn(r)){var a=n.x||0,o=n.y||0,s=n.width,l=n.height,h=r.width/r.height;if(null==s&&null!=l?s=l*h:null==l&&null!=s?l=s/h:null==s&&null==l&&(s=r.width,l=r.height),this.setTransform(t),n.sWidth&&n.sHeight){var u=n.sx||0,c=n.sy||0;t.drawImage(r,u,c,n.sWidth,n.sHeight,a,o,s,l)}else if(n.sx&&n.sy){var d=s-(u=n.sx),f=l-(c=n.sy);t.drawImage(r,u,c,d,f,a,o,s,l)}else t.drawImage(r,a,o,s,l);null!=n.text&&(this.restoreTransform(t),this.drawRectText(t,this.getBoundingRect()))}},getBoundingRect:function(){var t=this.style;return this._rect||(this._rect=new vn(t.x||0,t.y||0,t.width||0,t.height||0)),this._rect}},w(Hi,Vi);var Wi=314159;function Gi(t){return parseInt(t,10)}var Zi=new vn(0,0,0,0),Ui=new vn(0,0,0,0);function Xi(t,e,n){this.type="canvas";var i=!t.nodeName||"CANVAS"===t.nodeName.toUpperCase();this._opts=n=I({},n||{}),this.dpr=n.devicePixelRatio||nn,this._singleCanvas=i;var r=(this.root=t).style;r&&(r["-webkit-tap-highlight-color"]="transparent",r["-webkit-user-select"]=r["user-select"]=r["-webkit-touch-callout"]="none",t.innerHTML=""),this.storage=e;var a=this._zlevelList=[],o=this._layers={};if(this._layerConfig={},this._needsManuallyCompositing=!1,i){var s=t.width,l=t.height;null!=n.width&&(s=n.width),null!=n.height&&(l=n.height),this.dpr=n.devicePixelRatio||1,t.width=s*this.dpr,t.height=l*this.dpr,this._width=s,this._height=l;var h=new Gn(t,this,this.dpr);h.__builtin__=!0,h.initContext(),(o[Wi]=h).zlevel=Wi,a.push(Wi),this._domRoot=t}else{this._width=this._getSize(0),this._height=this._getSize(1);var u=this._domRoot=function(t,e){var n=document.createElement("div");return n.style.cssText=["position:relative","overflow:hidden","width:"+t+"px","height:"+e+"px","padding:0","margin:0","border-width:0"].join(";")+";",n}(this._width,this._height);t.appendChild(u)}this._hoverlayer=null,this._hoverElements=[]}Xi.prototype={constructor:Xi,getType:function(){return"canvas"},isSingleCanvas:function(){return this._singleCanvas},getViewportRoot:function(){return this._domRoot},getViewportRootOffset:function(){var t=this.getViewportRoot();if(t)return{offsetLeft:t.offsetLeft||0,offsetTop:t.offsetTop||0}},refresh:function(t){var e=this.storage.getDisplayList(!0),n=this._zlevelList;this._redrawId=Math.random(),this._paintList(e,t,this._redrawId);for(var i=0;i<n.length;i++){var r=n[i],a=this._layers[r];if(!a.__builtin__&&a.refresh){var o=0===i?this._backgroundColor:null;a.refresh(o)}}return this.refreshHover(),this},addHover:function(t,e){if(!t.__hoverMir){var n=new t.constructor({style:t.style,shape:t.shape,z:t.z,z2:t.z2,silent:t.silent});return(n.__from=t).__hoverMir=n,e&&n.setStyle(e),this._hoverElements.push(n),n}},removeHover:function(t){var e=t.__hoverMir,n=this._hoverElements,i=x(n,e);0<=i&&n.splice(i,1),t.__hoverMir=null},clearHover:function(t){for(var e=this._hoverElements,n=0;n<e.length;n++){var i=e[n].__from;i&&(i.__hoverMir=null)}e.length=0},refreshHover:function(){var t=this._hoverElements,e=t.length,n=this._hoverlayer;if(n&&n.clear(),e){Cn(t,this.storage.displayableSortFunc);var i={};(n=n||(this._hoverlayer=this.getLayer(1e5))).ctx.save();for(var r=0;r<e;){var a=t[r],o=a.__from;o&&o.__zr?(r++,o.invisible||(a.transform=o.transform,a.invTransform=o.invTransform,a.__clipPaths=o.__clipPaths,this._doPaintEl(a,n,!0,i))):(t.splice(r,1),o.__hoverMir=null,e--)}n.ctx.restore()}},getHoverLayer:function(){return this.getLayer(1e5)},_paintList:function(t,e,n){if(this._redrawId===n){e=e||!1,this._updateLayerStatus(t);var i=this._doPaintList(t,e);if(this._needsManuallyCompositing&&this._compositeManually(),!i){var r=this;Zn(function(){r._paintList(t,e,n)})}}},_compositeManually:function(){var e=this.getLayer(Wi).ctx,n=this._domRoot.width,i=this._domRoot.height;e.clearRect(0,0,n,i),this.eachBuiltinLayer(function(t){t.virtual&&e.drawImage(t.dom,0,0,n,i)})},_doPaintList:function(t,e){for(var n=[],i=0;i<this._zlevelList.length;i++){var r=this._zlevelList[i];(s=this._layers[r]).__builtin__&&s!==this._hoverlayer&&(s.__dirty||e)&&n.push(s)}for(var a=!0,o=0;o<n.length;o++){var s,l=(s=n[o]).ctx,h={};l.save();var u=e?s.__startIndex:s.__drawIndex,c=!e&&s.incremental&&Date.now,d=c&&Date.now(),f=s.zlevel===this._zlevelList[0]?this._backgroundColor:null;if(s.__startIndex===s.__endIndex)s.clear(!1,f);else if(u===s.__startIndex){var p=t[u];p.incremental&&p.notClear&&!e||s.clear(!1,f)}-1===u&&(console.error("For some unknown reason. drawIndex is -1"),u=s.__startIndex);for(var g=u;g<s.__endIndex;g++){var m=t[g];if(this._doPaintEl(m,s,e,h),m.__dirty=m.__dirtyText=!1,c)if(15<Date.now()-d)break}s.__drawIndex=g,s.__drawIndex<s.__endIndex&&(a=!1),h.prevElClipPaths&&l.restore(),l.restore()}return v.wxa&&A(this._layers,function(t){t&&t.ctx&&t.ctx.draw&&t.ctx.draw()}),a},_doPaintEl:function(t,e,n,i){var r=e.ctx,a=t.transform;if((e.__dirty||n)&&!t.invisible&&0!==t.style.opacity&&(!a||a[0]||a[3])&&(!t.culling||!function(t,e,n){return Zi.copy(t.getBoundingRect()),t.transform&&Zi.applyTransform(t.transform),Ui.width=e,Ui.height=n,!Zi.intersect(Ui)}(t,this._width,this._height))){var o=t.__clipPaths,s=i.prevElClipPaths;s&&!function(t,e){if(t===e)return!1;if(!t||!e||t.length!==e.length)return!0;for(var n=0;n<t.length;n++)if(t[n]!==e[n])return!0;return!1}(o,s)||(s&&(r.restore(),i.prevElClipPaths=null,i.prevEl=null),o&&(r.save(),function(t,e){for(var n=0;n<t.length;n++){var i=t[n];i.setTransform(e),e.beginPath(),i.buildPath(e,i.shape),e.clip(),i.restoreTransform(e)}}(o,r),i.prevElClipPaths=o)),t.beforeBrush&&t.beforeBrush(r),t.brush(r,i.prevEl||null),(i.prevEl=t).afterBrush&&t.afterBrush(r)}},getLayer:function(t,e){this._singleCanvas&&!this._needsManuallyCompositing&&(t=Wi);var n=this._layers[t];return n||((n=new Gn("zr_"+t,this,this.dpr)).zlevel=t,n.__builtin__=!0,this._layerConfig[t]&&m(n,this._layerConfig[t],!0),e&&(n.virtual=e),this.insertLayer(t,n),n.initContext()),n},insertLayer:function(t,e){var n=this._layers,i=this._zlevelList,r=i.length,a=null,o=-1,s=this._domRoot;if(n[t])on("ZLevel "+t+" has been used already");else if(function(t){return!!t&&(!!t.__builtin__||"function"==typeof t.resize&&"function"==typeof t.refresh)}(e)){if(0<r&&t>i[0]){for(o=0;o<r-1&&!(i[o]<t&&i[o+1]>t);o++);a=n[i[o]]}if(i.splice(o+1,0,t),!(n[t]=e).virtual)if(a){var l=a.dom;l.nextSibling?s.insertBefore(e.dom,l.nextSibling):s.appendChild(e.dom)}else s.firstChild?s.insertBefore(e.dom,s.firstChild):s.appendChild(e.dom)}else on("Layer of zlevel "+t+" is not valid")},eachLayer:function(t,e){var n,i,r=this._zlevelList;for(i=0;i<r.length;i++)n=r[i],t.call(e,this._layers[n],n)},eachBuiltinLayer:function(t,e){var n,i,r,a=this._zlevelList;for(r=0;r<a.length;r++)i=a[r],(n=this._layers[i]).__builtin__&&t.call(e,n,i)},eachOtherLayer:function(t,e){var n,i,r,a=this._zlevelList;for(r=0;r<a.length;r++)i=a[r],(n=this._layers[i]).__builtin__||t.call(e,n,i)},getLayers:function(){return this._layers},_updateLayerStatus:function(t){function e(t){i&&(i.__endIndex!==t&&(i.__dirty=!0),i.__endIndex=t)}if(this.eachBuiltinLayer(function(t,e){t.__dirty=t.__used=!1}),this._singleCanvas)for(var n=1;n<t.length;n++){if((a=t[n]).zlevel!==t[n-1].zlevel||a.incremental){this._needsManuallyCompositing=!0;break}}var i=null,r=0;for(n=0;n<t.length;n++){var a,o,s=(a=t[n]).zlevel;a.incremental?((o=this.getLayer(s+.001,this._needsManuallyCompositing)).incremental=!0,r=1):o=this.getLayer(s+(0<r?.01:0),this._needsManuallyCompositing),o.__builtin__||on("ZLevel "+s+" has been used by unkown layer "+o.id),o!==i&&(o.__used=!0,o.__startIndex!==n&&(o.__dirty=!0),o.__startIndex=n,o.incremental?o.__drawIndex=-1:o.__drawIndex=n,e(n),i=o),a.__dirty&&(o.__dirty=!0,o.incremental&&o.__drawIndex<0&&(o.__drawIndex=n))}e(n),this.eachBuiltinLayer(function(t,e){!t.__used&&0<t.getElementCount()&&(t.__dirty=!0,t.__startIndex=t.__endIndex=t.__drawIndex=0),t.__dirty&&t.__drawIndex<0&&(t.__drawIndex=t.__startIndex)})},clear:function(){return this.eachBuiltinLayer(this._clearLayer),this},_clearLayer:function(t){t.clear()},setBackgroundColor:function(t){this._backgroundColor=t},configLayer:function(t,e){if(e){var n=this._layerConfig;n[t]?m(n[t],e,!0):n[t]=e;for(var i=0;i<this._zlevelList.length;i++){var r=this._zlevelList[i];if(r===t||r===t+.01)m(this._layers[r],n[t],!0)}}},delLayer:function(t){var e=this._layers,n=this._zlevelList,i=e[t];i&&(i.dom.parentNode.removeChild(i.dom),delete e[t],n.splice(x(n,t),1))},resize:function(e,n){if(this._domRoot.style){var t=this._domRoot;t.style.display="none";var i=this._opts;if(null!=e&&(i.width=e),null!=n&&(i.height=n),e=this._getSize(0),n=this._getSize(1),t.style.display="",this._width!==e||n!==this._height){for(var r in t.style.width=e+"px",t.style.height=n+"px",this._layers)this._layers.hasOwnProperty(r)&&this._layers[r].resize(e,n);A(this._progressiveLayers,function(t){t.resize(e,n)}),this.refresh(!0)}this._width=e,this._height=n}else{if(null==e||null==n)return;this._width=e,this._height=n,this.getLayer(Wi).resize(e,n)}return this},clearLayer:function(t){var e=this._layers[t];e&&e.clear()},dispose:function(){this.root.innerHTML="",this.root=this.storage=this._domRoot=this._layers=null},getRenderedCanvas:function(t){if(t=t||{},this._singleCanvas&&!this._compositeManually)return this._layers[Wi].dom;var e=new Gn("image",this,t.pixelRatio||this.dpr);if(e.initContext(),e.clear(!1,t.backgroundColor||this._backgroundColor),t.pixelRatio<=this.dpr){this.refresh();var n=e.dom.width,i=e.dom.height,r=e.ctx;this.eachLayer(function(t){t.__builtin__?r.drawImage(t.dom,0,0,n,i):t.renderToCanvas&&(e.ctx.save(),t.renderToCanvas(e.ctx),e.ctx.restore())})}else for(var a={},o=this.storage.getDisplayList(!0),s=0;s<o.length;s++){var l=o[s];this._doPaintEl(l,e,!0,a)}return e.dom},getWidth:function(){return this._width},getHeight:function(){return this._height},_getSize:function(t){var e=this._opts,n=["width","height"][t],i=["clientWidth","clientHeight"][t],r=["paddingLeft","paddingTop"][t],a=["paddingRight","paddingBottom"][t];if(null!=e[n]&&"auto"!==e[n])return parseFloat(e[n]);var o=this.root,s=document.defaultView.getComputedStyle(o);return(o[i]||Gi(s[n])||Gi(o.style[n]))-(Gi(s[r])||0)-(Gi(s[a])||0)|0},pathToImage:function(t,e){e=e||this.dpr;var n=document.createElement("canvas"),i=n.getContext("2d"),r=t.getBoundingRect(),a=t.style,o=a.shadowBlur*e,s=a.shadowOffsetX*e,l=a.shadowOffsetY*e,h=a.hasStroke()?a.lineWidth:0,u=Math.max(h/2,o-s),c=Math.max(h/2,s+o),d=Math.max(h/2,o-l),f=Math.max(h/2,l+o),p=r.width+u+c,g=r.height+d+f;n.width=p*e,n.height=g*e,i.scale(e,e),i.clearRect(0,0,p,g),i.dpr=e;var m={position:t.position,rotation:t.rotation,scale:t.scale};t.position=[u-r.x,d-r.y],t.rotation=0,t.scale=[1,1],t.updateTransform(),t&&t.brush(i);var v=new Hi({style:{x:0,y:0,image:n}});return null!=m.position&&(v.position=t.position=m.position),null!=m.rotation&&(v.rotation=t.rotation=m.rotation),null!=m.scale&&(v.scale=t.scale=m.scale),v}};function Yi(t){t=t||{},this.stage=t.stage||{},this.onframe=t.onframe||function(){},this._clips=[],this._running=!1,this._time,this._pausedTime,this._pauseStart,this._paused=!1,It.call(this)}Yi.prototype={constructor:Yi,addClip:function(t){this._clips.push(t)},addAnimator:function(t){t.animation=this;for(var e=t.getClips(),n=0;n<e.length;n++)this.addClip(e[n])},removeClip:function(t){var e=x(this._clips,t);0<=e&&this._clips.splice(e,1)},removeAnimator:function(t){for(var e=t.getClips(),n=0;n<e.length;n++)this.removeClip(e[n]);t.animation=null},_update:function(){for(var t=(new Date).getTime()-this._pausedTime,e=t-this._time,n=this._clips,i=n.length,r=[],a=[],o=0;o<i;o++){var s=n[o],l=s.step(t,e);l&&(r.push(l),a.push(s))}for(o=0;o<i;)n[o]._needsRemove?(n[o]=n[i-1],n.pop(),i--):o++;i=r.length;for(o=0;o<i;o++)a[o].fire(r[o]);this._time=t,this.onframe(e),this.trigger("frame",e),this.stage.update&&this.stage.update()},_startLoop:function(){var e=this;this._running=!0,Zn(function t(){e._running&&(Zn(t),e._paused||e._update())})},start:function(){this._time=(new Date).getTime(),this._pausedTime=0,this._startLoop()},stop:function(){this._running=!1},pause:function(){this._paused||(this._pauseStart=(new Date).getTime(),this._paused=!0)},resume:function(){this._paused&&(this._pausedTime+=(new Date).getTime()-this._pauseStart,this._paused=!1)},clear:function(){this._clips=[]},isFinished:function(){return!this._clips.length},animate:function(t,e){var n=new tn(t,(e=e||{}).loop,e.getter,e.setter);return this.addAnimator(n),n}},S(Yi,It);var ji=["click","dblclick","mousewheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],qi=["touchstart","touchend","touchmove"],$i={pointerdown:1,pointerup:1,pointermove:1,pointerout:1},Ki=D(ji,function(t){var e=t.replace("mouse","pointer");return $i[e]?e:t});function Qi(t){return"mousewheel"===t&&v.browser.firefox?"DOMMouseScroll":t}function Ji(t){t._touching=!0,clearTimeout(t._touchTimer),t._touchTimer=setTimeout(function(){t._touching=!1},700)}var tr={mousemove:function(t){t=Et(this.dom,t),this.trigger("mousemove",t)},mouseout:function(t){var e=(t=Et(this.dom,t)).toElement||t.relatedTarget;if(e!==this.dom)for(;e&&9!==e.nodeType;){if(e===this.dom)return;e=e.parentNode}this.trigger("mouseout",t)},touchstart:function(t){(t=Et(this.dom,t)).zrByTouch=!0,this._lastTouchMoment=new Date,this.handler.processGesture(this,t,"start"),tr.mousemove.call(this,t),tr.mousedown.call(this,t),Ji(this)},touchmove:function(t){(t=Et(this.dom,t)).zrByTouch=!0,this.handler.processGesture(this,t,"change"),tr.mousemove.call(this,t),Ji(this)},touchend:function(t){(t=Et(this.dom,t)).zrByTouch=!0,this.handler.processGesture(this,t,"end"),tr.mouseup.call(this,t),+new Date-this._lastTouchMoment<300&&tr.click.call(this,t),Ji(this)},pointerdown:function(t){tr.mousedown.call(this,t)},pointermove:function(t){er(t)||tr.mousemove.call(this,t)},pointerup:function(t){tr.mouseup.call(this,t)},pointerout:function(t){er(t)||tr.mouseout.call(this,t)}};function er(t){var e=t.pointerType;return"pen"===e||"touch"===e}function nr(n){function t(t,e){A(t,function(t){Nt(n,Qi(t),e._handlers[t])},e)}It.call(this),this.dom=n,this._touching=!1,this._touchTimer,this._handlers={},function(e){A(qi,function(t){e._handlers[t]=k(tr[t],e)}),A(Ki,function(t){e._handlers[t]=k(tr[t],e)}),A(ji,function(t){e._handlers[t]=function(t,e){return function(){if(!e._touching)return t.apply(e,arguments)}}(tr[t],e)})}(this),v.pointerEventsSupported?t(Ki,this):(v.touchEventsSupported&&t(qi,this),t(ji,this))}A(["click","mousedown","mouseup","mousewheel","dblclick","contextmenu"],function(e){tr[e]=function(t){t=Et(this.dom,t),this.trigger(e,t)}});var ir=nr.prototype;ir.dispose=function(){for(var t,e,n,i=ji.concat(qi),r=0;r<i.length;r++){var a=i[r];t=this.dom,e=Qi(a),n=this._handlers[a],Dt?t.removeEventListener(e,n):t.detachEvent("on"+e,n)}},ir.setCursor=function(t){this.dom.style&&(this.dom.style.cursor=t||"default")},S(nr,It);var rr=!v.canvasSupported,ar={canvas:Xi},or={};function sr(t,e){var n=new hr(i(),t,e);return or[n.id]=n}function lr(t,e){ar[t]=e}var hr=function(t,e,n){n=n||{},this.dom=e,this.id=t;var i=this,r=new An,a=n.renderer;if(rr){if(!ar.vml)throw new Error("You need to require 'zrender/vml/vml' to support IE8");a="vml"}else a&&ar[a]||(a="canvas");var o=new ar[a](e,r,n,t);this.storage=r,this.painter=o;var s=v.node||v.worker?null:new nr(o.getViewportRoot());this.handler=new Ut(r,o,s,o.root),this.animation=new Yi({stage:{update:k(this.flush,this)}}),this.animation.start(),this._needsRefresh;var l=r.delFromStorage,h=r.addToStorage;r.delFromStorage=function(t){l.call(r,t),t&&t.removeSelfFromZr(i)},r.addToStorage=function(t){h.call(r,t),t.addSelfToZr(i)}};hr.prototype={constructor:hr,getId:function(){return this.id},add:function(t){this.storage.addRoot(t),this._needsRefresh=!0},remove:function(t){this.storage.delRoot(t),this._needsRefresh=!0},configLayer:function(t,e){this.painter.configLayer&&this.painter.configLayer(t,e),this._needsRefresh=!0},setBackgroundColor:function(t){this.painter.setBackgroundColor&&this.painter.setBackgroundColor(t),this._needsRefresh=!0},refreshImmediately:function(){this._needsRefresh=this._needsRefreshHover=!1,this.painter.refresh(),this._needsRefresh=this._needsRefreshHover=!1},refresh:function(){this._needsRefresh=!0},flush:function(){var t;this._needsRefresh&&(t=!0,this.refreshImmediately()),this._needsRefreshHover&&(t=!0,this.refreshHoverImmediately()),t&&this.trigger("rendered")},addHover:function(t,e){if(this.painter.addHover){var n=this.painter.addHover(t,e);return this.refreshHover(),n}},removeHover:function(t){this.painter.removeHover&&(this.painter.removeHover(t),this.refreshHover())},clearHover:function(){this.painter.clearHover&&(this.painter.clearHover(),this.refreshHover())},refreshHover:function(){this._needsRefreshHover=!0},refreshHoverImmediately:function(){this._needsRefreshHover=!1,this.painter.refreshHover&&this.painter.refreshHover()},resize:function(t){t=t||{},this.painter.resize(t.width,t.height),this.handler.resize()},clearAnimation:function(){this.animation.clear()},getWidth:function(){return this.painter.getWidth()},getHeight:function(){return this.painter.getHeight()},pathToImage:function(t,e){return this.painter.pathToImage(t,e)},setCursorStyle:function(t){this.handler.setCursorStyle(t)},findHover:function(t,e){return this.handler.findHover(t,e)},on:function(t,e,n){this.handler.on(t,e,n)},off:function(t,e){this.handler.off(t,e)},trigger:function(t,e){this.handler.trigger(t,e)},clear:function(){this.storage.delRoot(),this.painter.clear()},dispose:function(){this.animation.stop(),this.clear(),this.storage.dispose(),this.painter.dispose(),this.handler.dispose(),this.animation=this.storage=this.painter=this.handler=null,function(t){delete or[t]}(this.id)}};var ur=(Object.freeze||Object)({version:"4.1.0",init:sr,dispose:function(t){if(t)t.dispose();else{for(var e in or)or.hasOwnProperty(e)&&or[e].dispose();or={}}return this},getInstance:function(t){return or[t]},registerPainter:lr}),cr=A,dr=N,fr=O,pr="series\0";function gr(t){return t instanceof Array?t:null==t?[]:[t]}function mr(t,e,n){if(t){t[e]=t[e]||{},t.emphasis=t.emphasis||{},t.emphasis[e]=t.emphasis[e]||{};for(var i=0,r=n.length;i<r;i++){var a=n[i];!t.emphasis[e].hasOwnProperty(a)&&t[e].hasOwnProperty(a)&&(t.emphasis[e][a]=t[e][a])}}}var vr=["fontStyle","fontWeight","fontSize","fontFamily","rich","tag","color","textBorderColor","textBorderWidth","width","height","lineHeight","align","verticalAlign","baseline","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY","textShadowColor","textShadowBlur","textShadowOffsetX","textShadowOffsetY","backgroundColor","borderColor","borderWidth","borderRadius","padding"];function yr(t){return!dr(t)||fr(t)||t instanceof Date?t:t.value}function _r(t,r){r=(r||[]).slice();var a=D(t||[],function(t,e){return{exist:t}});return cr(r,function(t,e){if(dr(t)){for(var n=0;n<a.length;n++)if(!a[n].option&&null!=t.id&&a[n].exist.id===t.id+"")return a[n].option=t,void(r[e]=null);for(n=0;n<a.length;n++){var i=a[n].exist;if(!(a[n].option||null!=i.id&&null!=t.id||null==t.name||br(t)||br(i)||i.name!==t.name+""))return a[n].option=t,void(r[e]=null)}}}),cr(r,function(t,e){if(dr(t)){for(var n=0;n<a.length;n++){var i=a[n].exist;if(!a[n].option&&!br(i)&&null==t.id){a[n].option=t;break}}n>=a.length&&a.push({option:t})}}),a}function xr(t){var o=Q();cr(t,function(t,e){var n=t.exist;n&&o.set(n.id,t)}),cr(t,function(t,e){var n=t.option;X(!n||null==n.id||!o.get(n.id)||o.get(n.id)===t,"id duplicates: "+(n&&n.id)),n&&null!=n.id&&o.set(n.id,t),t.keyInfo||(t.keyInfo={})}),cr(t,function(t,e){var n=t.exist,i=t.option,r=t.keyInfo;if(dr(i)){if(r.name=null!=i.name?i.name+"":n?n.name:pr+e,n)r.id=n.id;else if(null!=i.id)r.id=i.id+"";else for(var a=0;r.id="\0"+r.name+"\0"+a++,o.get(r.id););o.set(r.id,t)}})}function wr(t){var e=t.name;return!(!e||!e.indexOf(pr))}function br(t){return dr(t)&&t.id&&0===(t.id+"").indexOf("\0_ec_\0")}function Sr(e,t){return null!=t.dataIndexInside?t.dataIndexInside:null!=t.dataIndex?O(t.dataIndex)?D(t.dataIndex,function(t){return e.indexOfRawIndex(t)}):e.indexOfRawIndex(t.dataIndex):null!=t.name?O(t.name)?D(t.name,function(t){return e.indexOfName(t)}):e.indexOfName(t.name):void 0}function Mr(){var e="__\0ec_inner_"+Ir+++"_"+Math.random().toFixed(5);return function(t){return t[e]||(t[e]={})}}var Ir=0;function Cr(s,l,h){if(E(l)){var t={};t[l+"Index"]=0,l=t}var e=h&&h.defaultMainType;!e||Tr(l,e+"Index")||Tr(l,e+"Id")||Tr(l,e+"Name")||(l[e+"Index"]=0);var u={};return cr(l,function(t,e){t=l[e];if("dataIndex"!==e&&"dataIndexInside"!==e){var n=e.match(/^(\w+)(Index|Id|Name)$/)||[],i=n[1],r=(n[2]||"").toLowerCase();if(!(!i||!r||null==t||"index"===r&&"none"===t||h&&h.includeMainTypes&&x(h.includeMainTypes,i)<0)){var a={mainType:i};"index"===r&&"all"===t||(a[r]=t);var o=s.queryComponents(a);u[i+"Models"]=o,u[i+"Model"]=o[0]}}else u[e]=t}),u}function Tr(t,e){return t&&t.hasOwnProperty(e)}function Ar(t,e,n){t.setAttribute?t.setAttribute(e,n):t[e]=n}function Dr(t){return"auto"===t?v.domSupported?"html":"richText":t||"html"}var kr=".",Pr="___EC__COMPONENT__CONTAINER___";function Lr(t){var e={main:"",sub:""};return t&&(t=t.split(kr),e.main=t[0]||"",e.sub=t[1]||""),e}function Or(t){(t.$constructor=t).extend=function(t){function e(){t.$constructor?t.$constructor.apply(this,arguments):n.apply(this,arguments)}var n=this;return I(e.prototype,t),e.extend=this.extend,e.superCall=Nr,e.superApply=Rr,w(e,this),e.superClass=n,e}}var zr=0;function Er(t){var e=["__\0is_clz",zr++,Math.random().toFixed(3)].join("_");t.prototype[e]=!0,t.isInstance=function(t){return!(!t||!t[e])}}function Nr(t,e){var n=Z(arguments,2);return this.superClass.prototype[e].apply(t,n)}function Rr(t,e,n){return this.superClass.prototype[e].apply(t,n)}function Br(n,t){t=t||{};var r={};if(n.registerClass=function(t,e){if(e)if(function(t){X(/^[a-zA-Z0-9_]+([.][a-zA-Z0-9_]+)?$/.test(t),'componentType "'+t+'" illegal')}(e),(e=Lr(e)).sub){if(e.sub!==Pr){(function(t){var e=r[t.main];e&&e[Pr]||((e=r[t.main]={})[Pr]=!0);return e})(e)[e.sub]=t}}else r[e.main]=t;return t},n.getClass=function(t,e,n){var i=r[t];if(i&&i[Pr]&&(i=e?i[e]:null),n&&!i)throw new Error(e?"Component "+t+"."+(e||"")+" not exists. Load it first.":t+".type should be specified.");return i},n.getClassesByMainType=function(t){t=Lr(t);var n=[],e=r[t.main];return e&&e[Pr]?A(e,function(t,e){e!==Pr&&n.push(t)}):n.push(e),n},n.hasClass=function(t){return t=Lr(t),!!r[t.main]},n.getAllClassMainTypes=function(){var n=[];return A(r,function(t,e){n.push(e)}),n},n.hasSubTypes=function(t){t=Lr(t);var e=r[t.main];return e&&e[Pr]},n.parseClassType=Lr,t.registerWhenExtend){var i=n.extend;i&&(n.extend=function(t){var e=i.call(this,t);return n.registerClass(e,t.type)})}return n}function Fr(s){for(var t=0;t<s.length;t++)s[t][1]||(s[t][1]=s[t][0]);return function(t,e,n){for(var i={},r=0;r<s.length;r++){var a=s[r][1];if(!(e&&0<=x(e,a)||n&&x(n,a)<0)){var o=t.getShallow(a);null!=o&&(i[s[r][0]]=o)}}return i}}var Vr=Fr([["lineWidth","width"],["stroke","color"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"]]),Hr={getLineStyle:function(t){var e=Vr(this,t);return e.lineDash=this.getLineDash(e.lineWidth),e},getLineDash:function(t){null==t&&(t=1);var e=this.get("type"),n=Math.max(t,2),i=4*t;return"solid"!==e&&null!=e&&("dashed"===e?[i,i]:[n,n])}},Wr=Fr([["fill","color"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["opacity"],["shadowColor"]]),Gr={getAreaStyle:function(t,e){return Wr(this,t,e)}},Zr=Math.pow,Ur=Math.sqrt,Xr=1e-8,Yr=1e-4,jr=Ur(3),qr=1/3,$r=nt(),Kr=nt(),Qr=nt();function Jr(t){return-Xr<t&&t<Xr}function ta(t){return Xr<t||t<-Xr}function ea(t,e,n,i,r){var a=1-r;return a*a*(a*t+3*r*e)+r*r*(r*i+3*a*n)}function na(t,e,n,i,r){var a=1-r;return 3*(((e-t)*a+2*(n-e)*r)*a+(i-n)*r*r)}function ia(t,e,n,i,r){var a=6*n-12*e+6*t,o=9*e+3*i-3*t-9*n,s=3*e-3*t,l=0;if(Jr(o)){if(ta(a))0<=(u=-s/a)&&u<=1&&(r[l++]=u)}else{var h=a*a-4*o*s;if(Jr(h))r[0]=-a/(2*o);else if(0<h){var u,c=Ur(h),d=(-a-c)/(2*o);0<=(u=(-a+c)/(2*o))&&u<=1&&(r[l++]=u),0<=d&&d<=1&&(r[l++]=d)}}return l}function ra(t,e,n,i,r,a){var o=(e-t)*r+t,s=(n-e)*r+e,l=(i-n)*r+n,h=(s-o)*r+o,u=(l-s)*r+s,c=(u-h)*r+h;a[0]=t,a[1]=o,a[2]=h,a[3]=c,a[4]=c,a[5]=u,a[6]=l,a[7]=i}function aa(t,e,n,i){var r=1-i;return r*(r*t+2*i*e)+i*i*n}function oa(t,e,n,i){return 2*((1-i)*(e-t)+i*(n-e))}function sa(t,e,n){var i=t+n-2*e;return 0==i?.5:(t-e)/i}function la(t,e,n,i,r){var a=(e-t)*i+t,o=(n-e)*i+e,s=(o-a)*i+a;r[0]=t,r[1]=a,r[2]=s,r[3]=s,r[4]=o,r[5]=n}var ha=Math.min,ua=Math.max,ca=Math.sin,da=Math.cos,fa=2*Math.PI,pa=nt(),ga=nt(),ma=nt();function va(t,e,n){if(0!==t.length){var i,r=t[0],a=r[0],o=r[0],s=r[1],l=r[1];for(i=1;i<t.length;i++)r=t[i],a=ha(a,r[0]),o=ua(o,r[0]),s=ha(s,r[1]),l=ua(l,r[1]);e[0]=a,e[1]=s,n[0]=o,n[1]=l}}function ya(t,e,n,i,r,a){r[0]=ha(t,n),r[1]=ha(e,i),a[0]=ua(t,n),a[1]=ua(e,i)}var _a=[],xa=[];function wa(t,e,n,i,r,a,o,s,l,h){var u,c=ia,d=ea,f=c(t,n,r,o,_a);for(l[0]=1/0,l[1]=1/0,h[0]=-1/0,h[1]=-1/0,u=0;u<f;u++){var p=d(t,n,r,o,_a[u]);l[0]=ha(p,l[0]),h[0]=ua(p,h[0])}for(f=c(e,i,a,s,xa),u=0;u<f;u++){var g=d(e,i,a,s,xa[u]);l[1]=ha(g,l[1]),h[1]=ua(g,h[1])}l[0]=ha(t,l[0]),h[0]=ua(t,h[0]),l[0]=ha(o,l[0]),h[0]=ua(o,h[0]),l[1]=ha(e,l[1]),h[1]=ua(e,h[1]),l[1]=ha(s,l[1]),h[1]=ua(s,h[1])}function ba(t,e,n,i,r,a,o,s,l){var h=_t,u=xt,c=Math.abs(r-a);if(c%fa<1e-4&&1e-4<c)return s[0]=t-n,s[1]=e-i,l[0]=t+n,void(l[1]=e+i);if(pa[0]=da(r)*n+t,pa[1]=ca(r)*i+e,ga[0]=da(a)*n+t,ga[1]=ca(a)*i+e,h(s,pa,ga),u(l,pa,ga),(r%=fa)<0&&(r+=fa),(a%=fa)<0&&(a+=fa),a<r&&!o?a+=fa:r<a&&o&&(r+=fa),o){var d=a;a=r,r=d}for(var f=0;f<a;f+=Math.PI/2)r<f&&(ma[0]=da(f)*n+t,ma[1]=ca(f)*i+e,h(s,ma,s),u(l,ma,l))}var Sa={M:1,L:2,C:3,Q:4,A:5,Z:6,R:7},Ma=[],Ia=[],Ca=[],Ta=[],Aa=Math.min,Da=Math.max,ka=Math.cos,Pa=Math.sin,La=Math.sqrt,Oa=Math.abs,za="undefined"!=typeof Float32Array,Ea=function(t){this._saveData=!t,this._saveData&&(this.data=[]),this._ctx=null};function Na(t,e,n,i,r,a,o){if(0===r)return!1;var s=r,l=0;if(e+s<o&&i+s<o||o<e-s&&o<i-s||t+s<a&&n+s<a||a<t-s&&a<n-s)return!1;if(t===n)return Math.abs(a-t)<=s/2;var h=(l=(e-i)/(t-n))*a-o+(t*i-n*e)/(t-n);return h*h/(l*l+1)<=s/2*s/2}function Ra(t,e,n,i,r,a,o,s,l,h,u){if(0===l)return!1;var c=l;return!(e+c<u&&i+c<u&&a+c<u&&s+c<u||u<e-c&&u<i-c&&u<a-c&&u<s-c||t+c<h&&n+c<h&&r+c<h&&o+c<h||h<t-c&&h<n-c&&h<r-c&&h<o-c)&&function(t,e,n,i,r,a,o,s,l,h,u){var c,d,f,p,g,m=.005,v=1/0;$r[0]=l,$r[1]=h;for(var y=0;y<1;y+=.05)Kr[0]=ea(t,n,r,o,y),Kr[1]=ea(e,i,a,s,y),(p=vt($r,Kr))<v&&(c=y,v=p);v=1/0;for(var _=0;_<32&&!(m<Yr);_++)d=c-m,f=c+m,Kr[0]=ea(t,n,r,o,d),Kr[1]=ea(e,i,a,s,d),p=vt(Kr,$r),0<=d&&p<v?(c=d,v=p):(Qr[0]=ea(t,n,r,o,f),Qr[1]=ea(e,i,a,s,f),g=vt(Qr,$r),f<=1&&g<v?(c=f,v=g):m*=.5);return u&&(u[0]=ea(t,n,r,o,c),u[1]=ea(e,i,a,s,c)),Ur(v)}(t,e,n,i,r,a,o,s,h,u,null)<=c/2}function Ba(t,e,n,i,r,a,o,s,l){if(0===o)return!1;var h=o;return!(e+h<l&&i+h<l&&a+h<l||l<e-h&&l<i-h&&l<a-h||t+h<s&&n+h<s&&r+h<s||s<t-h&&s<n-h&&s<r-h)&&function(t,e,n,i,r,a,o,s,l){var h,u=.005,c=1/0;$r[0]=o,$r[1]=s;for(var d=0;d<1;d+=.05){Kr[0]=aa(t,n,r,d),Kr[1]=aa(e,i,a,d),(m=vt($r,Kr))<c&&(h=d,c=m)}c=1/0;for(var f=0;f<32&&!(u<Yr);f++){var p=h-u,g=h+u;Kr[0]=aa(t,n,r,p),Kr[1]=aa(e,i,a,p);var m=vt(Kr,$r);if(0<=p&&m<c)h=p,c=m;else{Qr[0]=aa(t,n,r,g),Qr[1]=aa(e,i,a,g);var v=vt(Qr,$r);g<=1&&v<c?(h=g,c=v):u*=.5}}return l&&(l[0]=aa(t,n,r,h),l[1]=aa(e,i,a,h)),Ur(c)}(t,e,n,i,r,a,s,l,null)<=h/2}Ea.prototype={constructor:Ea,_xi:0,_yi:0,_x0:0,_y0:0,_ux:0,_uy:0,_len:0,_lineDash:null,_dashOffset:0,_dashIdx:0,_dashSum:0,setScale:function(t,e,n){n=n||0,this._ux=Oa(n/nn/t)||0,this._uy=Oa(n/nn/e)||0},getContext:function(){return this._ctx},beginPath:function(t){return(this._ctx=t)&&t.beginPath(),t&&(this.dpr=t.dpr),this._saveData&&(this._len=0),this._lineDash&&(this._lineDash=null,this._dashOffset=0),this},moveTo:function(t,e){return this.addData(Sa.M,t,e),this._ctx&&this._ctx.moveTo(t,e),this._x0=t,this._y0=e,this._xi=t,this._yi=e,this},lineTo:function(t,e){var n=Oa(t-this._xi)>this._ux||Oa(e-this._yi)>this._uy||this._len<5;return this.addData(Sa.L,t,e),this._ctx&&n&&(this._needsDash()?this._dashedLineTo(t,e):this._ctx.lineTo(t,e)),n&&(this._xi=t,this._yi=e),this},bezierCurveTo:function(t,e,n,i,r,a){return this.addData(Sa.C,t,e,n,i,r,a),this._ctx&&(this._needsDash()?this._dashedBezierTo(t,e,n,i,r,a):this._ctx.bezierCurveTo(t,e,n,i,r,a)),this._xi=r,this._yi=a,this},quadraticCurveTo:function(t,e,n,i){return this.addData(Sa.Q,t,e,n,i),this._ctx&&(this._needsDash()?this._dashedQuadraticTo(t,e,n,i):this._ctx.quadraticCurveTo(t,e,n,i)),this._xi=n,this._yi=i,this},arc:function(t,e,n,i,r,a){return this.addData(Sa.A,t,e,n,n,i,r-i,0,a?0:1),this._ctx&&this._ctx.arc(t,e,n,i,r,a),this._xi=ka(r)*n+t,this._yi=Pa(r)*n+e,this},arcTo:function(t,e,n,i,r){return this._ctx&&this._ctx.arcTo(t,e,n,i,r),this},rect:function(t,e,n,i){return this._ctx&&this._ctx.rect(t,e,n,i),this.addData(Sa.R,t,e,n,i),this},closePath:function(){this.addData(Sa.Z);var t=this._ctx,e=this._x0,n=this._y0;return t&&(this._needsDash()&&this._dashedLineTo(e,n),t.closePath()),this._xi=e,this._yi=n,this},fill:function(t){t&&t.fill(),this.toStatic()},stroke:function(t){t&&t.stroke(),this.toStatic()},setLineDash:function(t){if(t instanceof Array){this._lineDash=t;for(var e=this._dashIdx=0,n=0;n<t.length;n++)e+=t[n];this._dashSum=e}return this},setLineDashOffset:function(t){return this._dashOffset=t,this},len:function(){return this._len},setData:function(t){var e=t.length;this.data&&this.data.length===e||!za||(this.data=new Float32Array(e));for(var n=0;n<e;n++)this.data[n]=t[n];this._len=e},appendPath:function(t){t instanceof Array||(t=[t]);for(var e=t.length,n=0,i=this._len,r=0;r<e;r++)n+=t[r].len();za&&this.data instanceof Float32Array&&(this.data=new Float32Array(i+n));for(r=0;r<e;r++)for(var a=t[r].data,o=0;o<a.length;o++)this.data[i++]=a[o];this._len=i},addData:function(t){if(this._saveData){var e=this.data;this._len+arguments.length>e.length&&(this._expandData(),e=this.data);for(var n=0;n<arguments.length;n++)e[this._len++]=arguments[n];this._prevCmd=t}},_expandData:function(){if(!(this.data instanceof Array)){for(var t=[],e=0;e<this._len;e++)t[e]=this.data[e];this.data=t}},_needsDash:function(){return this._lineDash},_dashedLineTo:function(t,e){var n,i,r=this._dashSum,a=this._dashOffset,o=this._lineDash,s=this._ctx,l=this._xi,h=this._yi,u=t-l,c=e-h,d=La(u*u+c*c),f=l,p=h,g=o.length;for(a<0&&(a=r+a),f-=(a%=r)*(u/=d),p-=a*(c/=d);0<u&&f<=t||u<0&&t<=f||0===u&&(0<c&&p<=e||c<0&&e<=p);)f+=u*(n=o[i=this._dashIdx]),p+=c*n,this._dashIdx=(i+1)%g,0<u&&f<l||u<0&&l<f||0<c&&p<h||c<0&&h<p||s[i%2?"moveTo":"lineTo"](0<=u?Aa(f,t):Da(f,t),0<=c?Aa(p,e):Da(p,e));u=f-t,c=p-e,this._dashOffset=-La(u*u+c*c)},_dashedBezierTo:function(t,e,n,i,r,a){var o,s,l,h,u,c=this._dashSum,d=this._dashOffset,f=this._lineDash,p=this._ctx,g=this._xi,m=this._yi,v=ea,y=0,_=this._dashIdx,x=f.length,w=0;for(d<0&&(d=c+d),d%=c,o=0;o<1;o+=.1)s=v(g,t,n,r,o+.1)-v(g,t,n,r,o),l=v(m,e,i,a,o+.1)-v(m,e,i,a,o),y+=La(s*s+l*l);for(;_<x&&!(d<(w+=f[_]));_++);for(o=(w-d)/y;o<=1;)h=v(g,t,n,r,o),u=v(m,e,i,a,o),_%2?p.moveTo(h,u):p.lineTo(h,u),o+=f[_]/y,_=(_+1)%x;_%2!=0&&p.lineTo(r,a),s=r-h,l=a-u,this._dashOffset=-La(s*s+l*l)},_dashedQuadraticTo:function(t,e,n,i){var r=n,a=i;n=(n+2*t)/3,i=(i+2*e)/3,t=(this._xi+2*t)/3,e=(this._yi+2*e)/3,this._dashedBezierTo(t,e,n,i,r,a)},toStatic:function(){var t=this.data;t instanceof Array&&(t.length=this._len,za&&(this.data=new Float32Array(t)))},getBoundingRect:function(){Ma[0]=Ma[1]=Ca[0]=Ca[1]=Number.MAX_VALUE,Ia[0]=Ia[1]=Ta[0]=Ta[1]=-Number.MAX_VALUE;for(var t,e,n,i,r,a,o,s,l,h,u,c,d,f,p=this.data,g=0,m=0,v=0,y=0,_=0;_<p.length;){var x=p[_++];switch(1===_&&(v=g=p[_],y=m=p[_+1]),x){case Sa.M:g=v=p[_++],m=y=p[_++],Ca[0]=v,Ca[1]=y,Ta[0]=v,Ta[1]=y;break;case Sa.L:ya(g,m,p[_],p[_+1],Ca,Ta),g=p[_++],m=p[_++];break;case Sa.C:wa(g,m,p[_++],p[_++],p[_++],p[_++],p[_],p[_+1],Ca,Ta),g=p[_++],m=p[_++];break;case Sa.Q:t=g,e=m,n=p[_++],i=p[_++],r=p[_],a=p[_+1],o=Ca,s=Ta,h=l=void 0,h=aa,u=ua(ha((l=sa)(t,n,r),1),0),c=ua(ha(l(e,i,a),1),0),d=h(t,n,r,u),f=h(e,i,a,c),o[0]=ha(t,r,d),o[1]=ha(e,a,f),s[0]=ua(t,r,d),s[1]=ua(e,a,f),g=p[_++],m=p[_++];break;case Sa.A:var w=p[_++],b=p[_++],S=p[_++],M=p[_++],I=p[_++],C=p[_++]+I;_+=1;var T=1-p[_++];1===_&&(v=ka(I)*S+w,y=Pa(I)*M+b),ba(w,b,S,M,I,C,T,Ca,Ta),g=ka(C)*S+w,m=Pa(C)*M+b;break;case Sa.R:ya(v=g=p[_++],y=m=p[_++],v+p[_++],y+p[_++],Ca,Ta);break;case Sa.Z:g=v,m=y}_t(Ma,Ma,Ca),xt(Ia,Ia,Ta)}return 0===_&&(Ma[0]=Ma[1]=Ia[0]=Ia[1]=0),new vn(Ma[0],Ma[1],Ia[0]-Ma[0],Ia[1]-Ma[1])},rebuildPath:function(t){for(var e,n,i,r,a,o,s=this.data,l=this._ux,h=this._uy,u=this._len,c=0;c<u;){var d=s[c++];switch(1===c&&(e=i=s[c],n=r=s[c+1]),d){case Sa.M:e=i=s[c++],n=r=s[c++],t.moveTo(i,r);break;case Sa.L:a=s[c++],o=s[c++],(Oa(a-i)>l||Oa(o-r)>h||c===u-1)&&(t.lineTo(a,o),i=a,r=o);break;case Sa.C:t.bezierCurveTo(s[c++],s[c++],s[c++],s[c++],s[c++],s[c++]),i=s[c-2],r=s[c-1];break;case Sa.Q:t.quadraticCurveTo(s[c++],s[c++],s[c++],s[c++]),i=s[c-2],r=s[c-1];break;case Sa.A:var f=s[c++],p=s[c++],g=s[c++],m=s[c++],v=s[c++],y=s[c++],_=s[c++],x=s[c++],w=m<g?g:m,b=m<g?1:g/m,S=m<g?m/g:1,M=v+y;.001<Math.abs(g-m)?(t.translate(f,p),t.rotate(_),t.scale(b,S),t.arc(0,0,w,v,M,1-x),t.scale(1/b,1/S),t.rotate(-_),t.translate(-f,-p)):t.arc(f,p,w,v,M,1-x),1===c&&(e=ka(v)*g+f,n=Pa(v)*m+p),i=ka(M)*g+f,r=Pa(M)*m+p;break;case Sa.R:e=i=s[c],n=r=s[c+1],t.rect(s[c++],s[c++],s[c++],s[c++]);break;case Sa.Z:t.closePath(),i=e,r=n}}}},Ea.CMD=Sa;var Fa=2*Math.PI;function Va(t){return(t%=Fa)<0&&(t+=Fa),t}var Ha=2*Math.PI;function Wa(t,e,n,i,r,a,o,s,l){if(0===o)return!1;var h=o;s-=t,l-=e;var u=Math.sqrt(s*s+l*l);if(n<u-h||u+h<n)return!1;if(Math.abs(i-r)%Ha<1e-4)return!0;if(a){var c=i;i=Va(r),r=Va(c)}else i=Va(i),r=Va(r);r<i&&(r+=Ha);var d=Math.atan2(l,s);return d<0&&(d+=Ha),i<=d&&d<=r||i<=d+Ha&&d+Ha<=r}function Ga(t,e,n,i,r,a){if(e<a&&i<a||a<e&&a<i)return 0;if(i===e)return 0;var o=i<e?1:-1,s=(a-e)/(i-e);1!=s&&0!=s||(o=i<e?.5:-.5);var l=s*(n-t)+t;return l===r?1/0:r<l?o:0}var Za=Ea.CMD,Ua=2*Math.PI,Xa=1e-4;var Ya=[-1,-1,-1],ja=[-1,-1];function qa(t,e,n,i,r,a,o,s,l,h){if(e<h&&i<h&&a<h&&s<h||h<e&&h<i&&h<a&&h<s)return 0;var u,c=function(t,e,n,i,r,a){var o=i+3*(e-n)-t,s=3*(n-2*e+t),l=3*(e-t),h=t-r,u=s*s-3*o*l,c=s*l-9*o*h,d=l*l-3*s*h,f=0;if(Jr(u)&&Jr(c)){if(Jr(s))a[0]=0;else 0<=(M=-l/s)&&M<=1&&(a[f++]=M)}else{var p=c*c-4*u*d;if(Jr(p)){var g=c/u,m=-g/2;0<=(M=-s/o+g)&&M<=1&&(a[f++]=M),0<=m&&m<=1&&(a[f++]=m)}else if(0<p){var v=Ur(p),y=u*s+1.5*o*(-c+v),_=u*s+1.5*o*(-c-v);0<=(M=(-s-((y=y<0?-Zr(-y,qr):Zr(y,qr))+(_=_<0?-Zr(-_,qr):Zr(_,qr))))/(3*o))&&M<=1&&(a[f++]=M)}else{var x=(2*u*s-3*o*c)/(2*Ur(u*u*u)),w=Math.acos(x)/3,b=Ur(u),S=Math.cos(w),M=(-s-2*b*S)/(3*o),I=(m=(-s+b*(S+jr*Math.sin(w)))/(3*o),(-s+b*(S-jr*Math.sin(w)))/(3*o));0<=M&&M<=1&&(a[f++]=M),0<=m&&m<=1&&(a[f++]=m),0<=I&&I<=1&&(a[f++]=I)}}return f}(e,i,a,s,h,Ya);if(0===c)return 0;for(var d,f,p=0,g=-1,m=0;m<c;m++){var v=Ya[m],y=0===v||1===v?.5:1;ea(t,n,r,o,v)<l||(g<0&&(g=ia(e,i,a,s,ja),ja[1]<ja[0]&&1<g&&(void 0,u=ja[0],ja[0]=ja[1],ja[1]=u),d=ea(e,i,a,s,ja[0]),1<g&&(f=ea(e,i,a,s,ja[1]))),2===g?v<ja[0]?p+=d<e?y:-y:v<ja[1]?p+=f<d?y:-y:p+=s<f?y:-y:v<ja[0]?p+=d<e?y:-y:p+=s<d?y:-y)}return p}function $a(t,e,n,i,r,a,o,s){if(e<s&&i<s&&a<s||s<e&&s<i&&s<a)return 0;var l=function(t,e,n,i,r){var a=t-2*e+n,o=2*(e-t),s=t-i,l=0;if(Jr(a)){if(ta(o))0<=(u=-s/o)&&u<=1&&(r[l++]=u)}else{var h=o*o-4*a*s;if(Jr(h))0<=(u=-o/(2*a))&&u<=1&&(r[l++]=u);else if(0<h){var u,c=Ur(h),d=(-o-c)/(2*a);0<=(u=(-o+c)/(2*a))&&u<=1&&(r[l++]=u),0<=d&&d<=1&&(r[l++]=d)}}return l}(e,i,a,s,Ya);if(0===l)return 0;var h=sa(e,i,a);if(0<=h&&h<=1){for(var u=0,c=aa(e,i,a,h),d=0;d<l;d++){var f=0===Ya[d]||1===Ya[d]?.5:1;aa(t,n,r,Ya[d])<o||(Ya[d]<h?u+=c<e?f:-f:u+=a<c?f:-f)}return u}f=0===Ya[0]||1===Ya[0]?.5:1;return aa(t,n,r,Ya[0])<o?0:a<e?f:-f}function Ka(t,e,n,i,r,a,o,s){if(n<(s-=e)||s<-n)return 0;var l=Math.sqrt(n*n-s*s);Ya[0]=-l,Ya[1]=l;var h=Math.abs(i-r);if(h<1e-4)return 0;if(h%Ua<1e-4){r=Ua;var u=a?1:-1;return o>=Ya[i=0]+t&&o<=Ya[1]+t?u:0}if(a){l=i;i=Va(r),r=Va(l)}else i=Va(i),r=Va(r);r<i&&(r+=Ua);for(var c=0,d=0;d<2;d++){var f=Ya[d];if(o<f+t){var p=Math.atan2(s,f);u=a?1:-1;p<0&&(p=Ua+p),(i<=p&&p<=r||i<=p+Ua&&p+Ua<=r)&&(p>Math.PI/2&&p<1.5*Math.PI&&(u=-u),c+=u)}}return c}function Qa(t,e,n,i,r){for(var a=0,o=0,s=0,l=0,h=0,u=0;u<t.length;){var c=t[u++];switch(c===Za.M&&1<u&&(n||(a+=Ga(o,s,l,h,i,r))),1===u&&(l=o=t[u],h=s=t[u+1]),c){case Za.M:o=l=t[u++],s=h=t[u++];break;case Za.L:if(n){if(Na(o,s,t[u],t[u+1],e,i,r))return!0}else a+=Ga(o,s,t[u],t[u+1],i,r)||0;o=t[u++],s=t[u++];break;case Za.C:if(n){if(Ra(o,s,t[u++],t[u++],t[u++],t[u++],t[u],t[u+1],e,i,r))return!0}else a+=qa(o,s,t[u++],t[u++],t[u++],t[u++],t[u],t[u+1],i,r)||0;o=t[u++],s=t[u++];break;case Za.Q:if(n){if(Ba(o,s,t[u++],t[u++],t[u],t[u+1],e,i,r))return!0}else a+=$a(o,s,t[u++],t[u++],t[u],t[u+1],i,r)||0;o=t[u++],s=t[u++];break;case Za.A:var d=t[u++],f=t[u++],p=t[u++],g=t[u++],m=t[u++],v=t[u++];u+=1;var y=1-t[u++],_=Math.cos(m)*p+d,x=Math.sin(m)*g+f;1<u?a+=Ga(o,s,_,x,i,r):(l=_,h=x);var w=(i-d)*g/p+d;if(n){if(Wa(d,f,g,m,m+v,y,e,w,r))return!0}else a+=Ka(d,f,g,m,m+v,y,w,r);o=Math.cos(m+v)*p+d,s=Math.sin(m+v)*g+f;break;case Za.R:l=o=t[u++],h=s=t[u++];_=l+t[u++],x=h+t[u++];if(n){if(Na(l,h,_,h,e,i,r)||Na(_,h,_,x,e,i,r)||Na(_,x,l,x,e,i,r)||Na(l,x,l,h,e,i,r))return!0}else a+=Ga(_,h,_,x,i,r),a+=Ga(l,x,l,h,i,r);break;case Za.Z:if(n){if(Na(o,s,l,h,e,i,r))return!0}else a+=Ga(o,s,l,h,i,r);o=l,s=h}}return n||function(t,e){return Math.abs(t-e)<Xa}(s,h)||(a+=Ga(o,s,l,h,i,r)||0),0!==a}var Ja=Vn.prototype.getCanvasPattern,to=Math.abs,eo=new Ea(!0);function no(t){Vi.call(this,t),this.path=null}no.prototype={constructor:no,type:"path",__dirtyPath:!0,strokeContainThreshold:5,segmentIgnoreThreshold:0,subPixelOptimize:!1,brush:function(t,e){var n,i=this.style,r=this.path||eo,a=i.hasStroke(),o=i.hasFill(),s=i.fill,l=i.stroke,h=o&&!!s.colorStops,u=a&&!!l.colorStops,c=o&&!!s.image,d=a&&!!l.image;i.bind(t,this,e),this.setTransform(t),this.__dirty&&(h&&(n=n||this.getBoundingRect(),this._fillGradient=i.getGradient(t,s,n)),u&&(n=n||this.getBoundingRect(),this._strokeGradient=i.getGradient(t,l,n)));h?t.fillStyle=this._fillGradient:c&&(t.fillStyle=Ja.call(s,t)),u?t.strokeStyle=this._strokeGradient:d&&(t.strokeStyle=Ja.call(l,t));var f=i.lineDash,p=i.lineDashOffset,g=!!t.setLineDash,m=this.getGlobalScale();if(r.setScale(m[0],m[1],this.segmentIgnoreThreshold),this.__dirtyPath||f&&!g&&a?(r.beginPath(t),f&&!g&&(r.setLineDash(f),r.setLineDashOffset(p)),this.buildPath(r,this.shape,!1),this.path&&(this.__dirtyPath=!1)):(t.beginPath(),this.path.rebuildPath(t)),o)if(null!=i.fillOpacity){var v=t.globalAlpha;t.globalAlpha=i.fillOpacity*i.opacity,r.fill(t),t.globalAlpha=v}else r.fill(t);if(f&&g&&(t.setLineDash(f),t.lineDashOffset=p),a)if(null!=i.strokeOpacity){v=t.globalAlpha;t.globalAlpha=i.strokeOpacity*i.opacity,r.stroke(t),t.globalAlpha=v}else r.stroke(t);f&&g&&t.setLineDash([]),null!=i.text&&(this.restoreTransform(t),this.drawRectText(t,this.getBoundingRect()))},buildPath:function(t,e,n){},createPathProxy:function(){this.path=new Ea},getBoundingRect:function(){var t=this._rect,e=this.style,n=!t;if(n){var i=this.path;i=i||(this.path=new Ea),this.__dirtyPath&&(i.beginPath(),this.buildPath(i,this.shape,!1)),t=i.getBoundingRect()}if(this._rect=t,e.hasStroke()){var r=this._rectWithStroke||(this._rectWithStroke=t.clone());if(this.__dirty||n){r.copy(t);var a=e.lineWidth,o=e.strokeNoScale?this.getLineScale():1;e.hasFill()||(a=Math.max(a,this.strokeContainThreshold||4)),1e-10<o&&(r.width+=a/o,r.height+=a/o,r.x-=a/o/2,r.y-=a/o/2)}return r}return t},contain:function(t,e){var n=this.transformCoordToLocal(t,e),i=this.getBoundingRect(),r=this.style;if(t=n[0],e=n[1],i.contain(t,e)){var a=this.path.data;if(r.hasStroke()){var o=r.lineWidth,s=r.strokeNoScale?this.getLineScale():1;if(1e-10<s&&(r.hasFill()||(o=Math.max(o,this.strokeContainThreshold)),function(t,e,n,i){return Qa(t,e,!0,n,i)}(a,o/s,t,e)))return!0}if(r.hasFill())return function(t,e,n){return Qa(t,0,!1,e,n)}(a,t,e)}return!1},dirty:function(t){null==t&&(t=!0),t&&(this.__dirtyPath=t,this._rect=null),this.__dirty=this.__dirtyText=!0,this.__zr&&this.__zr.refresh(),this.__clipTarget&&this.__clipTarget.dirty()},animateShape:function(t){return this.animate("shape",t)},attrKV:function(t,e){"shape"===t?(this.setShape(e),this.__dirtyPath=!0,this._rect=null):Vi.prototype.attrKV.call(this,t,e)},setShape:function(t,e){var n=this.shape;if(n){if(N(t))for(var i in t)t.hasOwnProperty(i)&&(n[i]=t[i]);else n[t]=e;this.dirty(!0)}return this},getLineScale:function(){var t=this.transform;return t&&1e-10<to(t[0]-1)&&1e-10<to(t[3]-1)?Math.sqrt(to(t[0]*t[3]-t[2]*t[1])):1}},no.extend=function(r){function t(t){no.call(this,t),r.style&&this.style.extendFrom(r.style,!1);var e=r.shape;if(e){this.shape=this.shape||{};var n=this.shape;for(var i in e)!n.hasOwnProperty(i)&&e.hasOwnProperty(i)&&(n[i]=e[i])}r.init&&r.init.call(this,t)}for(var e in w(t,no),r)"style"!==e&&"shape"!==e&&(t.prototype[e]=r[e]);return t},w(no,Vi);function io(t){return Math.sqrt(t[0]*t[0]+t[1]*t[1])}var ro=Ea.CMD,ao=[[],[],[]],oo=Math.sqrt,so=Math.atan2,lo=function(t,e){var n,i,r,a,o,s=t.data,l=ro.M,h=ro.C,u=ro.L,c=ro.R,d=ro.A,f=ro.Q;for(a=r=0;r<s.length;){switch(n=s[r++],a=r,i=0,n){case l:case u:i=1;break;case h:i=3;break;case f:i=2;break;case d:var p=e[4],g=e[5],m=oo(e[0]*e[0]+e[1]*e[1]),v=oo(e[2]*e[2]+e[3]*e[3]),y=so(-e[1]/v,e[0]/m);s[r]*=m,s[r++]+=p,s[r]*=v,s[r++]+=g,s[r++]*=m,s[r++]*=v,s[r++]+=y,s[r++]+=y,a=r+=2;break;case c:_[0]=s[r++],_[1]=s[r++],yt(_,_,e),s[a++]=_[0],s[a++]=_[1],_[0]+=s[r++],_[1]+=s[r++],yt(_,_,e),s[a++]=_[0],s[a++]=_[1]}for(o=0;o<i;o++){var _;(_=ao[o])[0]=s[r++],_[1]=s[r++],yt(_,_,e),s[a++]=_[0],s[a++]=_[1]}}},ho=Math.sqrt,uo=Math.sin,co=Math.cos,fo=Math.PI,po=function(t,e){return(t[0]*e[0]+t[1]*e[1])/(io(t)*io(e))},go=function(t,e){return(t[0]*e[1]<t[1]*e[0]?-1:1)*Math.acos(po(t,e))};function mo(t,e,n,i,r,a,o,s,l,h,u){var c=l*(fo/180),d=co(c)*(t-n)/2+uo(c)*(e-i)/2,f=-1*uo(c)*(t-n)/2+co(c)*(e-i)/2,p=d*d/(o*o)+f*f/(s*s);1<p&&(o*=ho(p),s*=ho(p));var g=(r===a?-1:1)*ho((o*o*(s*s)-o*o*(f*f)-s*s*(d*d))/(o*o*(f*f)+s*s*(d*d)))||0,m=g*o*f/s,v=g*-s*d/o,y=(t+n)/2+co(c)*m-uo(c)*v,_=(e+i)/2+uo(c)*m+co(c)*v,x=go([1,0],[(d-m)/o,(f-v)/s]),w=[(d-m)/o,(f-v)/s],b=[(-1*d-m)/o,(-1*f-v)/s],S=go(w,b);po(w,b)<=-1&&(S=fo),1<=po(w,b)&&(S=0),0===a&&0<S&&(S-=2*fo),1===a&&S<0&&(S+=2*fo),u.addData(h,y,_,o,s,x,S,c,a)}var vo=/([mlvhzcqtsa])([^mlvhzcqtsa]*)/gi,yo=/-?([0-9]*\.)?[0-9]+([eE]-?[0-9]+)?/g;function _o(t,e){var n=function(t){if(!t)return new Ea;for(var e,n=0,i=0,r=n,a=i,o=new Ea,s=Ea.CMD,l=t.match(vo),h=0;h<l.length;h++){for(var u,c=l[h],d=c.charAt(0),f=c.match(yo)||[],p=f.length,g=0;g<p;g++)f[g]=parseFloat(f[g]);for(var m=0;m<p;){var v,y,_,x,w,b,S,M=n,I=i;switch(d){case"l":n+=f[m++],i+=f[m++],u=s.L,o.addData(u,n,i);break;case"L":n=f[m++],i=f[m++],u=s.L,o.addData(u,n,i);break;case"m":n+=f[m++],i+=f[m++],u=s.M,o.addData(u,n,i),r=n,a=i,d="l";break;case"M":n=f[m++],i=f[m++],u=s.M,o.addData(u,n,i),r=n,a=i,d="L";break;case"h":n+=f[m++],u=s.L,o.addData(u,n,i);break;case"H":n=f[m++],u=s.L,o.addData(u,n,i);break;case"v":i+=f[m++],u=s.L,o.addData(u,n,i);break;case"V":i=f[m++],u=s.L,o.addData(u,n,i);break;case"C":u=s.C,o.addData(u,f[m++],f[m++],f[m++],f[m++],f[m++],f[m++]),n=f[m-2],i=f[m-1];break;case"c":u=s.C,o.addData(u,f[m++]+n,f[m++]+i,f[m++]+n,f[m++]+i,f[m++]+n,f[m++]+i),n+=f[m-2],i+=f[m-1];break;case"S":v=n,y=i;var C=o.len(),T=o.data;e===s.C&&(v+=n-T[C-4],y+=i-T[C-3]),u=s.C,M=f[m++],I=f[m++],n=f[m++],i=f[m++],o.addData(u,v,y,M,I,n,i);break;case"s":v=n,y=i;C=o.len(),T=o.data;e===s.C&&(v+=n-T[C-4],y+=i-T[C-3]),u=s.C,M=n+f[m++],I=i+f[m++],n+=f[m++],i+=f[m++],o.addData(u,v,y,M,I,n,i);break;case"Q":M=f[m++],I=f[m++],n=f[m++],i=f[m++],u=s.Q,o.addData(u,M,I,n,i);break;case"q":M=f[m++]+n,I=f[m++]+i,n+=f[m++],i+=f[m++],u=s.Q,o.addData(u,M,I,n,i);break;case"T":v=n,y=i;C=o.len(),T=o.data;e===s.Q&&(v+=n-T[C-4],y+=i-T[C-3]),n=f[m++],i=f[m++],u=s.Q,o.addData(u,v,y,n,i);break;case"t":v=n,y=i;C=o.len(),T=o.data;e===s.Q&&(v+=n-T[C-4],y+=i-T[C-3]),n+=f[m++],i+=f[m++],u=s.Q,o.addData(u,v,y,n,i);break;case"A":_=f[m++],x=f[m++],w=f[m++],b=f[m++],S=f[m++],mo(M=n,I=i,n=f[m++],i=f[m++],b,S,_,x,w,u=s.A,o);break;case"a":_=f[m++],x=f[m++],w=f[m++],b=f[m++],S=f[m++],mo(M=n,I=i,n+=f[m++],i+=f[m++],b,S,_,x,w,u=s.A,o)}}"z"!==d&&"Z"!==d||(u=s.Z,o.addData(u),n=r,i=a),e=u}return o.toStatic(),o}(t);return(e=e||{}).buildPath=function(t){if(t.setData){t.setData(n.data),(e=t.getContext())&&t.rebuildPath(e)}else{var e=t;n.rebuildPath(e)}},e.applyTransform=function(t){lo(n,t),this.dirty(!0)},e}function xo(t,e){return new no(_o(t,e))}var wo=function(t){Vi.call(this,t)};wo.prototype={constructor:wo,type:"text",brush:function(t,e){var n=this.style;this.__dirty&&Si(n),n.fill=n.stroke=n.shadowBlur=n.shadowColor=n.shadowOffsetX=n.shadowOffsetY=null;var i=n.text;null!=i&&(i+=""),Ri(i,n)?(this.setTransform(t),Ii(this,t,i,n,null,e),this.restoreTransform(t)):t.__attrCachedBy=Pn.NONE},getBoundingRect:function(){var t=this.style;if(this.__dirty&&Si(t),!this._rect){var e=t.text;null!=e?e+="":e="";var n=ii(t.text+"",t.font,t.textAlign,t.textVerticalAlign,t.textPadding,t.textLineHeight,t.rich);if(n.x+=t.x||0,n.y+=t.y||0,Oi(t.textStroke,t.textStrokeWidth)){var i=t.textStrokeWidth;n.x-=i/2,n.y-=i/2,n.width+=i,n.height+=i}this._rect=n}return this._rect}},w(wo,Vi);function bo(l){return v.browser.ie&&11<=v.browser.version?function(){var t,e=this.__clipPaths,n=this.style;if(e)for(var i=0;i<e.length;i++){var r=e[i],a=r&&r.shape,o=r&&r.type;if(a&&("sector"===o&&a.startAngle===a.endAngle||"rect"===o&&(!a.width||!a.height))){for(var s=0;s<Mo.length;s++)Mo[s][2]=n[Mo[s][0]],n[Mo[s][0]]=Mo[s][1];t=!0;break}}if(l.apply(this,arguments),t)for(s=0;s<Mo.length;s++)n[Mo[s][0]]=Mo[s][2]}:l}var So=no.extend({type:"circle",shape:{cx:0,cy:0,r:0},buildPath:function(t,e,n){n&&t.moveTo(e.cx+e.r,e.cy),t.arc(e.cx,e.cy,e.r,0,2*Math.PI,!0)}}),Mo=[["shadowBlur",0],["shadowColor","#000"],["shadowOffsetX",0],["shadowOffsetY",0]],Io=no.extend({type:"sector",shape:{cx:0,cy:0,r0:0,r:0,startAngle:0,endAngle:2*Math.PI,clockwise:!0},brush:bo(no.prototype.brush),buildPath:function(t,e){var n=e.cx,i=e.cy,r=Math.max(e.r0||0,0),a=Math.max(e.r,0),o=e.startAngle,s=e.endAngle,l=e.clockwise,h=Math.cos(o),u=Math.sin(o);t.moveTo(h*r+n,u*r+i),t.lineTo(h*a+n,u*a+i),t.arc(n,i,a,o,s,!l),t.lineTo(Math.cos(s)*r+n,Math.sin(s)*r+i),0!==r&&t.arc(n,i,r,s,o,l),t.closePath()}}),Co=no.extend({type:"ring",shape:{cx:0,cy:0,r:0,r0:0},buildPath:function(t,e){var n=e.cx,i=e.cy,r=2*Math.PI;t.moveTo(n+e.r,i),t.arc(n,i,e.r,0,r,!1),t.moveTo(n+e.r0,i),t.arc(n,i,e.r0,0,r,!0)}});function To(t,e,n,i,r,a,o){var s=.5*(n-t),l=.5*(i-e);return(2*(e-n)+s+l)*o+(-3*(e-n)-2*s-l)*a+s*r+e}function Ao(t,e,n){var i=e.points,r=e.smooth;if(i&&2<=i.length){if(r&&"spline"!==r){var a=function(t,e,n,i){var r,a,o,s,l=[],h=[],u=[],c=[];if(i){o=[1/0,1/0],s=[-1/0,-1/0];for(var d=0,f=t.length;d<f;d++)_t(o,o,t[d]),xt(s,s,t[d]);_t(o,o,i[0]),xt(s,s,i[1])}for(d=0,f=t.length;d<f;d++){var p=t[d];if(n)r=t[d?d-1:f-1],a=t[(d+1)%f];else{if(0===d||d===f-1){l.push(rt(t[d]));continue}r=t[d-1],a=t[d+1]}st(h,a,r),dt(h,h,e);var g=pt(p,r),m=pt(p,a),v=g+m;0!==v&&(g/=v,m/=v),dt(u,h,-g),dt(c,h,m);var y=at([],p,u),_=at([],p,c);i&&(xt(y,y,o),_t(y,y,s),xt(_,_,o),_t(_,_,s)),l.push(y),l.push(_)}return n&&l.push(l.shift()),l}(i,r,n,e.smoothConstraint);t.moveTo(i[0][0],i[0][1]);for(var o=i.length,s=0;s<(n?o:o-1);s++){var l=a[2*s],h=a[2*s+1],u=i[(s+1)%o];t.bezierCurveTo(l[0],l[1],h[0],h[1],u[0],u[1])}}else{"spline"===r&&(i=function(t,e){for(var n=t.length,i=[],r=0,a=1;a<n;a++)r+=pt(t[a-1],t[a]);var o=r/2;o=o<n?n:o;for(a=0;a<o;a++){var s,l,h,u=a/(o-1)*(e?n:n-1),c=Math.floor(u),d=u-c,f=t[c%n];h=e?(s=t[(c-1+n)%n],l=t[(c+1)%n],t[(c+2)%n]):(s=t[0===c?c:c-1],l=t[n-2<c?n-1:c+1],t[n-3<c?n-1:c+2]);var p=d*d,g=d*p;i.push([To(s[0],f[0],l[0],h[0],d,p,g),To(s[1],f[1],l[1],h[1],d,p,g)])}return i}(i,n)),t.moveTo(i[0][0],i[0][1]);s=1;for(var c=i.length;s<c;s++)t.lineTo(i[s][0],i[s][1])}n&&t.closePath()}}var Do=no.extend({type:"polygon",shape:{points:null,smooth:!1,smoothConstraint:null},buildPath:function(t,e){Ao(t,e,!0)}}),ko=no.extend({type:"polyline",shape:{points:null,smooth:!1,smoothConstraint:null},style:{stroke:"#000",fill:null},buildPath:function(t,e){Ao(t,e,!1)}}),Po=Math.round;function Lo(t,e,n){var i=n&&n.lineWidth;if(e&&i){var r=e.x1,a=e.x2,o=e.y1,s=e.y2;Po(2*r)===Po(2*a)?t.x1=t.x2=zo(r,i,!0):(t.x1=r,t.x2=a),Po(2*o)===Po(2*s)?t.y1=t.y2=zo(o,i,!0):(t.y1=o,t.y2=s)}}function Oo(t,e,n){var i=n&&n.lineWidth;if(e&&i){var r=e.x,a=e.y,o=e.width,s=e.height;t.x=zo(r,i,!0),t.y=zo(a,i,!0),t.width=Math.max(zo(r+o,i,!1)-t.x,0===o?0:1),t.height=Math.max(zo(a+s,i,!1)-t.y,0===s?0:1)}}function zo(t,e,n){var i=Po(2*t);return(i+Po(e))%2==0?i/2:(i+(n?1:-1))/2}var Eo={},No=no.extend({type:"rect",shape:{r:0,x:0,y:0,width:0,height:0},buildPath:function(t,e){var n,i,r,a;this.subPixelOptimize?(Oo(Eo,e,this.style),n=Eo.x,i=Eo.y,r=Eo.width,a=Eo.height,Eo.r=e.r,e=Eo):(n=e.x,i=e.y,r=e.width,a=e.height),e.r?mi(t,e):t.rect(n,i,r,a),t.closePath()}}),Ro={},Bo=no.extend({type:"line",shape:{x1:0,y1:0,x2:0,y2:0,percent:1},style:{stroke:"#000",fill:null},buildPath:function(t,e){var n,i,r,a;a=this.subPixelOptimize?(Lo(Ro,e,this.style),n=Ro.x1,i=Ro.y1,r=Ro.x2,Ro.y2):(n=e.x1,i=e.y1,r=e.x2,e.y2);var o=e.percent;0!==o&&(t.moveTo(n,i),o<1&&(r=n*(1-o)+r*o,a=i*(1-o)+a*o),t.lineTo(r,a))},pointAt:function(t){var e=this.shape;return[e.x1*(1-t)+e.x2*t,e.y1*(1-t)+e.y2*t]}}),Fo=[];function Vo(t,e,n){var i=t.cpx2,r=t.cpy2;return null===i||null===r?[(n?na:ea)(t.x1,t.cpx1,t.cpx2,t.x2,e),(n?na:ea)(t.y1,t.cpy1,t.cpy2,t.y2,e)]:[(n?oa:aa)(t.x1,t.cpx1,t.x2,e),(n?oa:aa)(t.y1,t.cpy1,t.y2,e)]}function Ho(t){this.colorStops=t||[]}var Wo=no.extend({type:"bezier-curve",shape:{x1:0,y1:0,x2:0,y2:0,cpx1:0,cpy1:0,percent:1},style:{stroke:"#000",fill:null},buildPath:function(t,e){var n=e.x1,i=e.y1,r=e.x2,a=e.y2,o=e.cpx1,s=e.cpy1,l=e.cpx2,h=e.cpy2,u=e.percent;0!==u&&(t.moveTo(n,i),null==l||null==h?(u<1&&(la(n,o,r,u,Fo),o=Fo[1],r=Fo[2],la(i,s,a,u,Fo),s=Fo[1],a=Fo[2]),t.quadraticCurveTo(o,s,r,a)):(u<1&&(ra(n,o,l,r,u,Fo),o=Fo[1],l=Fo[2],r=Fo[3],ra(i,s,h,a,u,Fo),s=Fo[1],h=Fo[2],a=Fo[3]),t.bezierCurveTo(o,s,l,h,r,a)))},pointAt:function(t){return Vo(this.shape,t,!1)},tangentAt:function(t){var e=Vo(this.shape,t,!0);return ft(e,e)}}),Go=no.extend({type:"arc",shape:{cx:0,cy:0,r:0,startAngle:0,endAngle:2*Math.PI,clockwise:!0},style:{stroke:"#000",fill:null},buildPath:function(t,e){var n=e.cx,i=e.cy,r=Math.max(e.r,0),a=e.startAngle,o=e.endAngle,s=e.clockwise,l=Math.cos(a),h=Math.sin(a);t.moveTo(l*r+n,h*r+i),t.arc(n,i,r,a,o,!s)}}),Zo=no.extend({type:"compound",shape:{paths:null},_updatePathDirty:function(){for(var t=this.__dirtyPath,e=this.shape.paths,n=0;n<e.length;n++)t=t||e[n].__dirtyPath;this.__dirtyPath=t,this.__dirty=this.__dirty||t},beforeBrush:function(){this._updatePathDirty();for(var t=this.shape.paths||[],e=this.getGlobalScale(),n=0;n<t.length;n++)t[n].path||t[n].createPathProxy(),t[n].path.setScale(e[0],e[1],t[n].segmentIgnoreThreshold)},buildPath:function(t,e){for(var n=e.paths||[],i=0;i<n.length;i++)n[i].buildPath(t,n[i].shape,!0)},afterBrush:function(){for(var t=this.shape.paths||[],e=0;e<t.length;e++)t[e].__dirtyPath=!1},getBoundingRect:function(){return this._updatePathDirty(),no.prototype.getBoundingRect.call(this)}});Ho.prototype={constructor:Ho,addColorStop:function(t,e){this.colorStops.push({offset:t,color:e})}};function Uo(t,e,n,i,r,a){this.x=null==t?0:t,this.y=null==e?0:e,this.x2=null==n?1:n,this.y2=null==i?0:i,this.type="linear",this.global=a||!1,Ho.call(this,r)}Uo.prototype={constructor:Uo},w(Uo,Ho);function Xo(t,e,n,i,r){this.x=null==t?.5:t,this.y=null==e?.5:e,this.r=null==n?.5:n,this.type="radial",this.global=r||!1,Ho.call(this,i)}function Yo(t){Vi.call(this,t),this._displayables=[],this._temporaryDisplayables=[],this._cursor=0,this.notClear=!0}Xo.prototype={constructor:Xo},w(Xo,Ho),Yo.prototype.incremental=!0,Yo.prototype.clearDisplaybles=function(){this._displayables=[],this._temporaryDisplayables=[],this._cursor=0,this.dirty(),this.notClear=!1},Yo.prototype.addDisplayable=function(t,e){e?this._temporaryDisplayables.push(t):this._displayables.push(t),this.dirty()},Yo.prototype.addDisplayables=function(t,e){e=e||!1;for(var n=0;n<t.length;n++)this.addDisplayable(t[n],e)},Yo.prototype.eachPendingDisplayable=function(t){for(var e=this._cursor;e<this._displayables.length;e++)t&&t(this._displayables[e]);for(e=0;e<this._temporaryDisplayables.length;e++)t&&t(this._temporaryDisplayables[e])},Yo.prototype.update=function(){this.updateTransform();for(var t=this._cursor;t<this._displayables.length;t++){(e=this._displayables[t]).parent=this,e.update(),e.parent=null}for(t=0;t<this._temporaryDisplayables.length;t++){var e;(e=this._temporaryDisplayables[t]).parent=this,e.update(),e.parent=null}},Yo.prototype.brush=function(t,e){for(var n=this._cursor;n<this._displayables.length;n++){(i=this._displayables[n]).beforeBrush&&i.beforeBrush(t),i.brush(t,n===this._cursor?null:this._displayables[n-1]),i.afterBrush&&i.afterBrush(t)}this._cursor=n;for(n=0;n<this._temporaryDisplayables.length;n++){var i;(i=this._temporaryDisplayables[n]).beforeBrush&&i.beforeBrush(t),i.brush(t,0===n?null:this._temporaryDisplayables[n-1]),i.afterBrush&&i.afterBrush(t)}this._temporaryDisplayables=[],this.notClear=!0};var jo=[];Yo.prototype.getBoundingRect=function(){if(!this._rect){for(var t=new vn(1/0,1/0,-1/0,-1/0),e=0;e<this._displayables.length;e++){var n=this._displayables[e],i=n.getBoundingRect().clone();n.needLocalTransform()&&i.applyTransform(n.getLocalTransform(jo)),t.union(i)}this._rect=t}return this._rect},Yo.prototype.contain=function(t,e){var n=this.transformCoordToLocal(t,e);if(this.getBoundingRect().contain(n[0],n[1]))for(var i=0;i<this._displayables.length;i++){if(this._displayables[i].contain(t,e))return!0}return!1},w(Yo,Vi);var qo=Math.max,$o=Math.min,Ko={},Qo=1,Jo="emphasis",ts="normal",es=1,ns={};function is(t){return no.extend(t)}function rs(t,e,n,i){var r=xo(t,e);return n&&("center"===i&&(n=os(n,r.getBoundingRect())),ls(r,n)),r}function as(t,n,i){var r=new Hi({style:{image:t,x:n.x,y:n.y,width:n.width,height:n.height},onload:function(t){if("center"===i){var e={width:t.width,height:t.height};r.setStyle(os(n,e))}}});return r}function os(t,e){var n,i=e.width/e.height,r=t.height*i;return n=r<=t.width?t.height:(r=t.width)/i,{x:t.x+t.width/2-r/2,y:t.y+t.height/2-n/2,width:r,height:n}}function ss(t,e){for(var n=[],i=t.length,r=0;r<i;r++){var a=t[r];a.path||a.createPathProxy(),a.__dirtyPath&&a.buildPath(a.path,a.shape,!0),n.push(a.path)}var o=new no(e);return o.createPathProxy(),o.buildPath=function(t){t.appendPath(n);var e=t.getContext();e&&t.rebuildPath(e)},o}function ls(t,e){if(t.applyTransform){var n=t.getBoundingRect().calculateTransform(e);t.applyTransform(n)}}var hs=zo;function us(t){return null!=t&&"none"!==t}var cs=Q(),ds=0;function fs(t){var e=t.__hoverStl;if(e&&!t.__highlighted){var n=t.useHoverLayer;t.__highlighted=n?"layer":"plain";var i=t.__zr;if(!(t.isGroup||!i&&n)){var r=t,a=t.style;n&&(a=(r=i.addHover(t)).style),Os(a),n||function(t){if(t.__hoverStlDirty){t.__hoverStlDirty=!1;var e=t.__hoverStl;if(e){var n=t.__cachedNormalStl={};t.__cachedNormalZ2=t.z2;var i=t.style;for(var r in e)null!=e[r]&&(n[r]=i[r]);n.fill=i.fill,n.stroke=i.stroke}else t.__cachedNormalStl=t.__cachedNormalZ2=null}}(r),a.extendFrom(e),ps(a,e,"fill"),ps(a,e,"stroke"),Ls(a),n||(t.dirty(!1),t.z2+=Qo)}}}function ps(t,e,n){!us(e[n])&&us(t[n])&&(t[n]=function(t){if("string"!=typeof t)return t;var e=cs.get(t);return e||(e=Le(t,-.1),ds<1e4&&(cs.set(t,e),ds++)),e}(t[n]))}function gs(t){var e=t.__highlighted;if(e&&(t.__highlighted=!1,!t.isGroup))if("layer"===e)t.__zr&&t.__zr.removeHover(t);else{var n=t.style,i=t.__cachedNormalStl;i&&(Os(n),t.setStyle(i),Ls(n));var r=t.__cachedNormalZ2;null!=r&&t.z2-r===Qo&&(t.z2=r)}}function ms(t,e,n){var i,r=ts,a=ts;t.__highlighted&&(r=Jo,i=!0),e(t,n),t.__highlighted&&(a=Jo,i=!0),t.isGroup&&t.traverse(function(t){t.isGroup||e(t,n)}),i&&t.__highDownOnUpdate&&t.__highDownOnUpdate(r,a)}function vs(t,e){e=t.__hoverStl=!1!==e&&(t.hoverStyle||e||{}),t.__hoverStlDirty=!0,t.__highlighted&&(t.__cachedNormalStl=null,gs(t),fs(t))}function ys(t){bs(this,t)||this.__highByOuter||ms(this,fs)}function _s(t){bs(this,t)||this.__highByOuter||ms(this,gs)}function xs(t){this.__highByOuter|=1<<(t||0),ms(this,fs)}function ws(t){(this.__highByOuter&=~(1<<(t||0)))||ms(this,gs)}function bs(t,e){return t.__highDownSilentOnTouch&&e.zrByTouch}function Ss(t,e){Ms(t,!0),ms(t,vs,e)}function Ms(t,e){var n=!1===e;if(t.__highDownSilentOnTouch=t.highDownSilentOnTouch,t.__highDownOnUpdate=t.highDownOnUpdate,!n||t.__highDownDispatcher){var i=n?"off":"on";t[i]("mouseover",ys)[i]("mouseout",_s),t[i]("emphasis",xs)[i]("normal",ws),t.__highByOuter=t.__highByOuter||0,t.__highDownDispatcher=!n}}function Is(t){return!(!t||!t.__highDownDispatcher)}function Cs(t){var e=ns[t];return null==e&&es<=32&&(e=ns[t]=es++),e}function Ts(t,e,n,i,r,a,o){var s,l=(r=r||Ko).labelFetcher,h=r.labelDataIndex,u=r.labelDimIndex,c=n.getShallow("show"),d=i.getShallow("show");(c||d)&&(l&&(s=l.getFormattedLabel(h,"normal",null,u)),null==s&&(s=z(r.defaultText)?r.defaultText(h,r):r.defaultText));var f=c?s:null,p=d?W(l?l.getFormattedLabel(h,"emphasis",null,u):null,s):null;null==f&&null==p||(As(t,n,a,r),As(e,i,o,r,!0)),t.text=f,e.text=p}function As(t,e,n,i,r){return Ds(t,e,i,r),n&&I(t,n),t}function Ds(t,e,n,i){if((n=n||Ko).isRectText){var r=e.getShallow("position")||(i?null:"inside");"outside"===r&&(r="top"),t.textPosition=r,t.textOffset=e.getShallow("offset");var a=e.getShallow("rotate");null!=a&&(a*=Math.PI/180),t.textRotation=a,t.textDistance=W(e.getShallow("distance"),i?null:5)}var o,s=e.ecModel,l=s&&s.option.textStyle,h=function(t){var e;for(;t&&t!==t.ecModel;){var n=(t.option||Ko).rich;if(n)for(var i in e=e||{},n)n.hasOwnProperty(i)&&(e[i]=1);t=t.parentModel}return e}(e);if(h)for(var u in o={},h)if(h.hasOwnProperty(u)){var c=e.getModel(["rich",u]);ks(o[u]={},c,l,n,i)}return t.rich=o,ks(t,e,l,n,i,!0),n.forceRich&&!n.textStyle&&(n.textStyle={}),t}function ks(t,e,n,i,r,a){n=!r&&n||Ko,t.textFill=Ps(e.getShallow("color"),i)||n.color,t.textStroke=Ps(e.getShallow("textBorderColor"),i)||n.textBorderColor,t.textStrokeWidth=W(e.getShallow("textBorderWidth"),n.textBorderWidth),r||(a&&(t.insideRollbackOpt=i,Ls(t)),null==t.textFill&&(t.textFill=i.autoColor)),t.fontStyle=e.getShallow("fontStyle")||n.fontStyle,t.fontWeight=e.getShallow("fontWeight")||n.fontWeight,t.fontSize=e.getShallow("fontSize")||n.fontSize,t.fontFamily=e.getShallow("fontFamily")||n.fontFamily,t.textAlign=e.getShallow("align"),t.textVerticalAlign=e.getShallow("verticalAlign")||e.getShallow("baseline"),t.textLineHeight=e.getShallow("lineHeight"),t.textWidth=e.getShallow("width"),t.textHeight=e.getShallow("height"),t.textTag=e.getShallow("tag"),a&&i.disableBox||(t.textBackgroundColor=Ps(e.getShallow("backgroundColor"),i),t.textPadding=e.getShallow("padding"),t.textBorderColor=Ps(e.getShallow("borderColor"),i),t.textBorderWidth=e.getShallow("borderWidth"),t.textBorderRadius=e.getShallow("borderRadius"),t.textBoxShadowColor=e.getShallow("shadowColor"),t.textBoxShadowBlur=e.getShallow("shadowBlur"),t.textBoxShadowOffsetX=e.getShallow("shadowOffsetX"),t.textBoxShadowOffsetY=e.getShallow("shadowOffsetY")),t.textShadowColor=e.getShallow("textShadowColor")||n.textShadowColor,t.textShadowBlur=e.getShallow("textShadowBlur")||n.textShadowBlur,t.textShadowOffsetX=e.getShallow("textShadowOffsetX")||n.textShadowOffsetX,t.textShadowOffsetY=e.getShallow("textShadowOffsetY")||n.textShadowOffsetY}function Ps(t,e){return"auto"!==t?t:e&&e.autoColor?e.autoColor:null}function Ls(t){var e,n=t.textPosition,i=t.insideRollbackOpt;if(i&&null==t.textFill){var r=i.autoColor,a=i.isRectText,o=i.useInsideStyle,s=!1!==o&&(!0===o||a&&n&&"string"==typeof n&&0<=n.indexOf("inside")),l=!s&&null!=r;(s||l)&&(e={textFill:t.textFill,textStroke:t.textStroke,textStrokeWidth:t.textStrokeWidth}),s&&(t.textFill="#fff",null==t.textStroke&&(t.textStroke=r,null==t.textStrokeWidth&&(t.textStrokeWidth=2))),l&&(t.textFill=r)}t.insideRollback=e}function Os(t){var e=t.insideRollback;e&&(t.textFill=e.textFill,t.textStroke=e.textStroke,t.textStrokeWidth=e.textStrokeWidth,t.insideRollback=null)}function zs(t,e){var n=e||e.getModel("textStyle");return Y([t.fontStyle||n&&n.getShallow("fontStyle")||"",t.fontWeight||n&&n.getShallow("fontWeight")||"",(t.fontSize||n&&n.getShallow("fontSize")||12)+"px",t.fontFamily||n&&n.getShallow("fontFamily")||"sans-serif"].join(" "))}function Es(t,e,n,i,r,a){if("function"==typeof r&&(a=r,r=null),i&&i.isAnimationEnabled()){var o=t?"Update":"",s=i.getShallow("animationDuration"+o),l=i.getShallow("animationEasing"+o),h=i.getShallow("animationDelay"+o);"function"==typeof h&&(h=h(r,i.getAnimationDelayParams?i.getAnimationDelayParams(e,r):null)),"function"==typeof s&&(s=s(r)),0<s?e.animateTo(n,s,h||0,l,a,!!a):(e.stopAnimation(),e.attr(n),a&&a())}else e.stopAnimation(),e.attr(n),a&&a()}function Ns(t,e,n,i,r){Es(!0,t,e,n,i,r)}function Rs(t,e,n,i,r){Es(!1,t,e,n,i,r)}function Bs(t,e){for(var n=$t([]);t&&t!==e;)Qt(n,t.getLocalTransform(),n),t=t.parent;return n}function Fs(t,e,n){return e&&!L(e)&&(e=oe.getLocalTransform(e)),n&&(e=ne([],e)),yt([],t,e)}function Vs(t,e,n){var i=0===e[4]||0===e[5]||0===e[0]?1:Math.abs(2*e[4]/e[0]),r=0===e[4]||0===e[5]||0===e[2]?1:Math.abs(2*e[4]/e[2]),a=["left"===t?-i:"right"===t?i:0,"top"===t?-r:"bottom"===t?r:0];return a=Fs(a,e,n),Math.abs(a[0])>Math.abs(a[1])?0<a[0]?"right":"left":0<a[1]?"bottom":"top"}function Hs(t,e,i,n){if(t&&e){var r,a=(r={},t.traverse(function(t){!t.isGroup&&t.anid&&(r[t.anid]=t)}),r);e.traverse(function(t){if(!t.isGroup&&t.anid){var e=a[t.anid];if(e){var n=o(t);t.attr(o(e)),Ns(t,n,i,t.dataIndex)}}})}function o(t){var e={position:rt(t.position),rotation:t.rotation};return t.shape&&(e.shape=I({},t.shape)),e}}function Ws(t,i){return D(t,function(t){var e=t[0];e=qo(e,i.x),e=$o(e,i.x+i.width);var n=t[1];return n=qo(n,i.y),[e,n=$o(n,i.y+i.height)]})}function Gs(t,e,n){var i=(e=I({rectHover:!0},e)).style={strokeNoScale:!0};if(n=n||{x:-1,y:-1,width:2,height:2},t)return 0===t.indexOf("image://")?(i.image=t.slice(8),T(i,n),new Hi(e)):rs(t.replace("path://",""),e,n,"center")}function Zs(t,e,n,i,r,a,o,s){var l=n-t,h=i-e,u=o-r,c=s-a,d=Us(u,c,l,h);if(function(t){return t<=1e-6&&-1e-6<=t}(d))return!1;var f=t-r,p=e-a,g=Us(f,p,l,h)/d;if(g<0||1<g)return!1;var m=Us(f,p,u,c)/d;return!(m<0||1<m)}function Us(t,e,n,i){return t*i-n*e}var Xs=(Object.freeze||Object)({Z2_EMPHASIS_LIFT:Qo,CACHED_LABEL_STYLE_PROPERTIES:{color:"textFill",textBorderColor:"textStroke",textBorderWidth:"textStrokeWidth"},extendShape:is,extendPath:function(t,e){return function(t,e){return no.extend(_o(t,e))}(t,e)},makePath:rs,makeImage:as,mergePath:ss,resizePath:ls,subPixelOptimizeLine:function(t){return Lo(t.shape,t.shape,t.style),t},subPixelOptimizeRect:function(t){return Oo(t.shape,t.shape,t.style),t},subPixelOptimize:hs,setElementHoverStyle:vs,setHoverStyle:Ss,setAsHighDownDispatcher:Ms,isHighDownDispatcher:Is,getHighlightDigit:Cs,setLabelStyle:Ts,modifyLabelStyle:function(t,e,n){var i=t.style;e&&(Os(i),t.setStyle(e),Ls(i)),i=t.__hoverStl,n&&i&&(Os(i),I(i,n),Ls(i))},setTextStyle:As,setText:function(t,e,n){var i,r={isRectText:!0};!1===n?i=!0:r.autoColor=n,Ds(t,e,r,i)},getFont:zs,updateProps:Ns,initProps:Rs,getTransform:Bs,applyTransform:Fs,transformDirection:Vs,groupTransition:Hs,clipPointsByRect:Ws,clipRectByRect:function(t,e){var n=qo(t.x,e.x),i=$o(t.x+t.width,e.x+e.width),r=qo(t.y,e.y),a=$o(t.y+t.height,e.y+e.height);if(n<=i&&r<=a)return{x:n,y:r,width:i-n,height:a-r}},createIcon:Gs,linePolygonIntersect:function(t,e,n,i,r){for(var a=0,o=r[r.length-1];a<r.length;a++){var s=r[a];if(Zs(t,e,n,i,s[0],s[1],o[0],o[1]))return!0;o=s}},lineLineIntersect:Zs,Group:yn,Image:Hi,Text:wo,Circle:So,Sector:Io,Ring:Co,Polygon:Do,Polyline:ko,Rect:No,Line:Bo,BezierCurve:Wo,Arc:Go,IncrementalDisplayable:Yo,CompoundPath:Zo,LinearGradient:Uo,RadialGradient:Xo,BoundingRect:vn}),Ys=["textStyle","color"],js={getTextColor:function(t){var e=this.ecModel;return this.getShallow("color")||(!t&&e?e.get(Ys):null)},getFont:function(){return zs({fontStyle:this.getShallow("fontStyle"),fontWeight:this.getShallow("fontWeight"),fontSize:this.getShallow("fontSize"),fontFamily:this.getShallow("fontFamily")},this.ecModel)},getTextRect:function(t){return ii(t,this.getFont(),this.getShallow("align"),this.getShallow("verticalAlign")||this.getShallow("baseline"),this.getShallow("padding"),this.getShallow("lineHeight"),this.getShallow("rich"),this.getShallow("truncateText"))}},qs=Fr([["fill","color"],["stroke","borderColor"],["lineWidth","borderWidth"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"],["textPosition"],["textAlign"]]),$s={getItemStyle:function(t,e){var n=qs(this,t,e),i=this.getBorderLineDash();return i&&(n.lineDash=i),n},getBorderLineDash:function(){var t=this.get("borderType");return"solid"===t||null==t?null:"dashed"===t?[5,5]:[1,1]}},Ks=S,Qs=Mr();function Js(t,e,n){this.parentModel=e,this.ecModel=n,this.option=t}function tl(t,e,n){for(var i=0;i<e.length&&(!e[i]||null!=(t=t&&"object"==typeof t?t[e[i]]:null));i++);return null==t&&n&&(t=n.get(e)),t}function el(t,e){var n=Qs(t).getParent;return n?n.call(t,e):t.parentModel}Js.prototype={constructor:Js,init:null,mergeOption:function(t){m(this.option,t,!0)},get:function(t,e){return null==t?this.option:tl(this.option,this.parsePath(t),!e&&el(this,t))},getShallow:function(t,e){var n=this.option,i=null==n?n:n[t],r=!e&&el(this,t);return null==i&&r&&(i=r.getShallow(t)),i},getModel:function(t,e){var n;return new Js(null==t?this.option:tl(this.option,t=this.parsePath(t)),e=e||(n=el(this,t))&&n.getModel(t),this.ecModel)},isEmpty:function(){return null==this.option},restoreData:function(){},clone:function(){return new this.constructor(b(this.option))},setReadOnly:function(t){},parsePath:function(t){return"string"==typeof t&&(t=t.split(".")),t},customizeGetParent:function(t){Qs(this).getParent=t},isAnimationEnabled:function(){if(!v.node){if(null!=this.option.animation)return!!this.option.animation;if(this.parentModel)return this.parentModel.isAnimationEnabled()}}},Or(Js),Er(Js),Ks(Js,Hr),Ks(Js,Gr),Ks(Js,js),Ks(Js,$s);var nl=0;function il(t){return[t||"",nl++,Math.random().toFixed(5)].join("_")}var rl=1e-4;function al(t,e,n,i){var r=e[1]-e[0],a=n[1]-n[0];if(0==r)return 0==a?n[0]:(n[0]+n[1])/2;if(i)if(0<r){if(t<=e[0])return n[0];if(t>=e[1])return n[1]}else{if(t>=e[0])return n[0];if(t<=e[1])return n[1]}else{if(t===e[0])return n[0];if(t===e[1])return n[1]}return(t-e[0])/r*a+n[0]}function ol(t,e){switch(t){case"center":case"middle":t="50%";break;case"left":case"top":t="0%";break;case"right":case"bottom":t="100%"}return"string"==typeof t?function(t){return t.replace(/^\s+/,"").replace(/\s+$/,"")}(t).match(/%$/)?parseFloat(t)/100*e:parseFloat(t):null==t?NaN:+t}function sl(t,e,n){return null==e&&(e=10),e=Math.min(Math.max(0,e),20),t=(+t).toFixed(e),n?t:+t}function ll(t){return t.sort(function(t,e){return t-e}),t}function hl(t){if(t=+t,isNaN(t))return 0;for(var e=1,n=0;Math.round(t*e)/e!==t;)e*=10,n++;return n}function ul(t){var e=t.toString(),n=e.indexOf("e");if(0<n){var i=+e.slice(n+1);return i<0?-i:0}var r=e.indexOf(".");return r<0?0:e.length-1-r}function cl(t,e){var n=Math.log,i=Math.LN10,r=Math.floor(n(t[1]-t[0])/i),a=Math.round(n(Math.abs(e[1]-e[0]))/i),o=Math.min(Math.max(-r+a,0),20);return isFinite(o)?o:20}function dl(t,e,n){if(!t[e])return 0;var i=M(t,function(t,e){return t+(isNaN(e)?0:e)},0);if(0===i)return 0;for(var r=Math.pow(10,n),a=D(t,function(t){return(isNaN(t)?0:t)/i*r*100}),o=100*r,s=D(a,function(t){return Math.floor(t)}),l=M(s,function(t,e){return t+e},0),h=D(a,function(t,e){return t-s[e]});l<o;){for(var u=Number.NEGATIVE_INFINITY,c=null,d=0,f=h.length;d<f;++d)h[d]>u&&(u=h[d],c=d);++s[c],h[c]=0,++l}return s[e]/r}function fl(t){var e=2*Math.PI;return(t%e+e)%e}function pl(t){return-rl<t&&t<rl}var gl=/^(?:(\d{4})(?:[-\/](\d{1,2})(?:[-\/](\d{1,2})(?:[T ](\d{1,2})(?::(\d\d)(?::(\d\d)(?:[.,](\d+))?)?)?(Z|[\+\-]\d\d:?\d\d)?)?)?)?)?$/;function ml(t){if(t instanceof Date)return t;if("string"!=typeof t)return null==t?new Date(NaN):new Date(Math.round(t));var e=gl.exec(t);if(!e)return new Date(NaN);if(e[8]){var n=+e[4]||0;return"Z"!==e[8].toUpperCase()&&(n-=e[8].slice(0,3)),new Date(Date.UTC(+e[1],+(e[2]||1)-1,+e[3]||1,n,+(e[5]||0),+e[6]||0,+e[7]||0))}return new Date(+e[1],+(e[2]||1)-1,+e[3]||1,+e[4]||0,+(e[5]||0),+e[6]||0,+e[7]||0)}function vl(t){return Math.pow(10,yl(t))}function yl(t){return Math.floor(Math.log(t)/Math.LN10)}function _l(t,e){var n=yl(t),i=Math.pow(10,n),r=t/i;return t=(e?r<1.5?1:r<2.5?2:r<4?3:r<7?5:10:r<1?1:r<2?2:r<3?3:r<5?5:10)*i,-20<=n?+t.toFixed(n<0?-n:0):t}var xl=(Object.freeze||Object)({linearMap:al,parsePercent:ol,round:sl,asc:ll,getPrecision:hl,getPrecisionSafe:ul,getPixelPrecision:cl,getPercentWithPrecision:dl,MAX_SAFE_INTEGER:9007199254740991,remRadian:fl,isRadianAroundZero:pl,parseDate:ml,quantity:vl,nice:_l,quantile:function(t,e){var n=(t.length-1)*e+1,i=Math.floor(n),r=+t[i-1],a=n-i;return a?r+a*(t[i]-r):r},reformIntervals:function(t){t.sort(function(t,e){return function t(e,n,i){return e.interval[i]<n.interval[i]||e.interval[i]===n.interval[i]&&(e.close[i]-n.close[i]==(i?-1:1)||!i&&t(e,n,1))}(t,e,0)?-1:1});for(var e=-1/0,n=1,i=0;i<t.length;){for(var r=t[i].interval,a=t[i].close,o=0;o<2;o++)r[o]<=e&&(r[o]=e,a[o]=o?1:1-n),e=r[o],n=a[o];r[0]===r[1]&&a[0]*a[1]!=1?t.splice(i,1):i++}return t},isNumeric:function(t){return 0<=t-parseFloat(t)}});function wl(t){return isNaN(t)?"-":(t=(t+"").split("."))[0].replace(/(\d{1,3})(?=(?:\d{3})+(?!\d))/g,"$1,")+(1<t.length?"."+t[1]:"")}function bl(t,e){return t=(t||"").toLowerCase().replace(/-(.)/g,function(t,e){return e.toUpperCase()}),e&&t&&(t=t.charAt(0).toUpperCase()+t.slice(1)),t}var Sl=U,Ml=/([&<>"'])/g,Il={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"};function Cl(t){return null==t?"":(t+"").replace(Ml,function(t,e){return Il[e]})}function Tl(t,e){return"{"+t+(null==e?"":e)+"}"}var Al=["a","b","c","d","e","f","g"];function Dl(t,e,n){O(e)||(e=[e]);var i=e.length;if(!i)return"";for(var r=e[0].$vars||[],a=0;a<r.length;a++){var o=Al[a];t=t.replace(Tl(o),Tl(o,0))}for(var s=0;s<i;s++)for(var l=0;l<r.length;l++){var h=e[s][r[l]];t=t.replace(Tl(Al[l],s),n?Cl(h):h)}return t}function kl(t,e){var n=(t=E(t)?{color:t,extraCssText:e}:t||{}).color,i=t.type,r=(e=t.extraCssText,t.renderMode||"html"),a=t.markerId||"X";return n?"html"===r?"subItem"===i?'<span style="display:inline-block;vertical-align:middle;margin-right:8px;margin-left:3px;border-radius:4px;width:4px;height:4px;background-color:'+Cl(n)+";"+(e||"")+'"></span>':'<span style="display:inline-block;margin-right:5px;border-radius:10px;width:10px;height:10px;background-color:'+Cl(n)+";"+(e||"")+'"></span>':{renderMode:r,content:"{marker"+a+"|}  ",style:{color:n}}:""}function Pl(t,e){return"0000".substr(0,e-(t+="").length)+t}function Ll(t,e,n){"week"!==t&&"month"!==t&&"quarter"!==t&&"half-year"!==t&&"year"!==t||(t="MM-dd\nyyyy");var i=ml(e),r=n?"UTC":"",a=i["get"+r+"FullYear"](),o=i["get"+r+"Month"]()+1,s=i["get"+r+"Date"](),l=i["get"+r+"Hours"](),h=i["get"+r+"Minutes"](),u=i["get"+r+"Seconds"](),c=i["get"+r+"Milliseconds"]();return t=t.replace("MM",Pl(o,2)).replace("M",o).replace("yyyy",a).replace("yy",a%100).replace("dd",Pl(s,2)).replace("d",s).replace("hh",Pl(l,2)).replace("h",l).replace("mm",Pl(h,2)).replace("m",h).replace("ss",Pl(u,2)).replace("s",u).replace("SSS",Pl(c,3))}function Ol(t){return t?t.charAt(0).toUpperCase()+t.substr(1):t}var zl=si;var El=(Object.freeze||Object)({addCommas:wl,toCamelCase:bl,normalizeCssArray:Sl,encodeHTML:Cl,formatTpl:Dl,formatTplSimple:function(n,t,i){return A(t,function(t,e){n=n.replace("{"+e+"}",i?Cl(t):t)}),n},getTooltipMarker:kl,formatTime:Ll,capitalFirst:Ol,truncateText:zl,getTextBoundingRect:function(t){return ii(t.text,t.font,t.textAlign,t.textVerticalAlign,t.textPadding,t.textLineHeight,t.rich,t.truncate)},getTextRect:function(t,e,n,i,r,a,o,s){return ii(t,e,n,i,r,s,a,o)}}),Nl=A,Rl=["left","right","top","bottom","width","height"],Bl=[["width","left","right"],["height","top","bottom"]];function Fl(u,c,d,f,p){var g=0,m=0;null==f&&(f=1/0),null==p&&(p=1/0);var v=0;c.eachChild(function(t,e){var n,i,r=t.position,a=t.getBoundingRect(),o=c.childAt(e+1),s=o&&o.getBoundingRect();if("horizontal"===u){var l=a.width+(s?-s.x+a.x:0);v=f<(n=g+l)||t.newline?(g=0,n=l,m+=v+d,a.height):Math.max(v,a.height)}else{var h=a.height+(s?-s.y+a.y:0);v=p<(i=m+h)||t.newline?(g+=v+d,m=0,i=h,a.width):Math.max(v,a.width)}t.newline||(r[0]=g,r[1]=m,"horizontal"===u?g=n+d:m=i+d)})}var Vl=Fl;P(Fl,"vertical"),P(Fl,"horizontal");function Hl(t,e,n){n=Sl(n||0);var i=e.width,r=e.height,a=ol(t.left,i),o=ol(t.top,r),s=ol(t.right,i),l=ol(t.bottom,r),h=ol(t.width,i),u=ol(t.height,r),c=n[2]+n[0],d=n[1]+n[3],f=t.aspect;switch(isNaN(h)&&(h=i-s-d-a),isNaN(u)&&(u=r-l-c-o),null!=f&&(isNaN(h)&&isNaN(u)&&(i/r<f?h=.8*i:u=.8*r),isNaN(h)&&(h=f*u),isNaN(u)&&(u=h/f)),isNaN(a)&&(a=i-s-h-d),isNaN(o)&&(o=r-l-u-c),t.left||t.right){case"center":a=i/2-h/2-n[3];break;case"right":a=i-h-d}switch(t.top||t.bottom){case"middle":case"center":o=r/2-u/2-n[0];break;case"bottom":o=r-u-c}a=a||0,o=o||0,isNaN(h)&&(h=i-d-a-(s||0)),isNaN(u)&&(u=r-c-o-(l||0));var p=new vn(a+n[3],o+n[0],h,u);return p.margin=n,p}function Wl(t,e,n,i,r){var a=!r||!r.hv||r.hv[0],o=!r||!r.hv||r.hv[1],s=r&&r.boundingMode||"all";if(a||o){var l;if("raw"===s)l="group"===t.type?new vn(0,0,+e.width||0,+e.height||0):t.getBoundingRect();else if(l=t.getBoundingRect(),t.needLocalTransform()){var h=t.getLocalTransform();(l=l.clone()).applyTransform(h)}e=Hl(T({width:l.width,height:l.height},e),n,i);var u=t.position,c=a?e.x-l.x:0,d=o?e.y-l.y:0;t.attr("position","raw"===s?[c,d]:[u[0]+c,u[1]+d])}}function Gl(l,h,t){N(t)||(t={});var u=t.ignoreSize;O(u)||(u=[u,u]);var e=i(Bl[0],0),n=i(Bl[1],1);function i(t,e){var n={},i=0,r={},a=0;if(Nl(t,function(t){r[t]=l[t]}),Nl(t,function(t){c(h,t)&&(n[t]=r[t]=h[t]),d(n,t)&&i++,d(r,t)&&a++}),u[e])return d(h,t[1])?r[t[2]]=null:d(h,t[2])&&(r[t[1]]=null),r;if(2!==a&&i){if(2<=i)return n;for(var o=0;o<t.length;o++){var s=t[o];if(!c(n,s)&&c(l,s)){n[s]=l[s];break}}return n}return r}function c(t,e){return t.hasOwnProperty(e)}function d(t,e){return null!=t[e]&&"auto"!==t[e]}function r(t,e,n){Nl(t,function(t){e[t]=n[t]})}r(Bl[0],l,e),r(Bl[1],l,n)}function Zl(t){return Ul({},t)}function Ul(e,n){return n&&e&&Nl(Rl,function(t){n.hasOwnProperty(t)&&(e[t]=n[t])}),e}var Xl,Yl,jl,ql=Mr(),$l=Js.extend({type:"component",id:"",name:"",mainType:"",subType:"",componentIndex:0,defaultOption:null,ecModel:null,dependentModels:[],uid:null,layoutMode:null,$constructor:function(t,e,n,i){Js.call(this,t,e,n,i),this.uid=il("ec_cpt_model")},init:function(t,e,n,i){this.mergeDefaultAndTheme(t,n)},mergeDefaultAndTheme:function(t,e){var n=this.layoutMode,i=n?Zl(t):{};m(t,e.getTheme().get(this.mainType)),m(t,this.getDefaultOption()),n&&Gl(t,i,n)},mergeOption:function(t,e){m(this.option,t,!0);var n=this.layoutMode;n&&Gl(this.option,t,n)},optionUpdated:function(t,e){},getDefaultOption:function(){var t=ql(this);if(!t.defaultOption){for(var e=[],n=this.constructor;n;){var i=n.prototype.defaultOption;i&&e.push(i),n=n.superClass}for(var r={},a=e.length-1;0<=a;a--)r=m(r,e[a],!0);t.defaultOption=r}return t.defaultOption},getReferringComponents:function(t){return this.ecModel.queryComponents({mainType:t,index:this.get(t+"Index",!0),id:this.get(t+"Id",!0)})}});function Kl(t,e){return t[e]||(t[e]={predecessor:[],successor:[]}),t[e]}Br($l,{registerWhenExtend:!0}),Yl={},(Xl=$l).registerSubTypeDefaulter=function(t,e){t=Lr(t),Yl[t.main]=e},Xl.determineSubType=function(t,e){var n=e.type;if(!n){var i=Lr(t).main;Xl.hasSubTypes(t)&&Yl[i]&&(n=Yl[i](e))}return n},jl=function(t){var e=[];A($l.getClassesByMainType(t),function(t){e=e.concat(t.prototype.dependencies||[])}),e=D(e,function(t){return Lr(t).main}),"dataset"!==t&&x(e,"dataset")<=0&&e.unshift("dataset");return e},$l.topologicalTravel=function(t,e,n,i){if(t.length){var r=function(e){var r={},a=[];return A(e,function(n){var i=Kl(r,n),t=function(t,e){var n=[];return A(t,function(t){0<=x(e,t)&&n.push(t)}),n}(i.originalDeps=jl(n),e);i.entryCount=t.length,0===i.entryCount&&a.push(n),A(t,function(t){x(i.predecessor,t)<0&&i.predecessor.push(t);var e=Kl(r,t);x(e.successor,t)<0&&e.successor.push(n)})}),{graph:r,noEntryList:a}}(e),a=r.graph,o=r.noEntryList,s={};for(A(t,function(t){s[t]=!0});o.length;){var l=o.pop(),h=a[l],u=!!s[l];u&&(n.call(i,l,h.originalDeps.slice()),delete s[l]),A(h.successor,u?d:c)}A(s,function(){throw new Error("Circle dependency may exists")})}function c(t){a[t].entryCount--,0===a[t].entryCount&&o.push(t)}function d(t){s[t]=!0,c(t)}},S($l,{getBoxLayoutParams:function(){return{left:this.get("left"),top:this.get("top"),right:this.get("right"),bottom:this.get("bottom"),width:this.get("width"),height:this.get("height")}}});var Ql="";"undefined"!=typeof navigator&&(Ql=navigator.platform||"");var Jl={color:["#c23531","#2f4554","#61a0a8","#d48265","#91c7ae","#749f83","#ca8622","#bda29a","#6e7074","#546570","#c4ccd3"],gradientColor:["#f6efa6","#d88273","#bf444c"],textStyle:{fontFamily:Ql.match(/^Win/)?"Microsoft YaHei":"sans-serif",fontSize:12,fontStyle:"normal",fontWeight:"normal"},blendMode:null,animation:"auto",animationDuration:1e3,animationDurationUpdate:300,animationEasing:"exponentialOut",animationEasingUpdate:"cubicOut",animationThreshold:2e3,progressiveThreshold:3e3,progressive:400,hoverLayerThreshold:3e3,useUTC:!1},th=Mr();var eh={clearColorPalette:function(){th(this).colorIdx=0,th(this).colorNameMap={}},getColorFromPalette:function(t,e,n){var i=th(e=e||this),r=i.colorIdx||0,a=i.colorNameMap=i.colorNameMap||{};if(a.hasOwnProperty(t))return a[t];var o=gr(this.get("color",!0)),s=this.get("colorLayer",!0),l=null!=n&&s?function(t,e){for(var n=t.length,i=0;i<n;i++)if(t[i].length>e)return t[i];return t[n-1]}(s,n):o;if((l=l||o)&&l.length){var h=l[r];return t&&(a[t]=h),i.colorIdx=(r+1)%l.length,h}}};function nh(t){var e=t.get("coordinateSystem"),n={coordSysName:e,coordSysDims:[],axisMap:Q(),categoryAxisMap:Q()},i=ih[e];if(i)return i(t,n,n.axisMap,n.categoryAxisMap),n}var ih={cartesian2d:function(t,e,n,i){var r=t.getReferringComponents("xAxis")[0],a=t.getReferringComponents("yAxis")[0];e.coordSysDims=["x","y"],n.set("x",r),n.set("y",a),rh(r)&&(i.set("x",r),e.firstCategoryDimIndex=0),rh(a)&&(i.set("y",a),e.firstCategoryDimIndex=1)},singleAxis:function(t,e,n,i){var r=t.getReferringComponents("singleAxis")[0];e.coordSysDims=["single"],n.set("single",r),rh(r)&&(i.set("single",r),e.firstCategoryDimIndex=0)},polar:function(t,e,n,i){var r=t.getReferringComponents("polar")[0],a=r.findAxisModel("radiusAxis"),o=r.findAxisModel("angleAxis");e.coordSysDims=["radius","angle"],n.set("radius",a),n.set("angle",o),rh(a)&&(i.set("radius",a),e.firstCategoryDimIndex=0),rh(o)&&(i.set("angle",o),e.firstCategoryDimIndex=1)},geo:function(t,e,n,i){e.coordSysDims=["lng","lat"]},parallel:function(t,r,a,o){var s=t.ecModel,e=s.getComponent("parallel",t.get("parallelIndex")),l=r.coordSysDims=e.dimensions.slice();A(e.parallelAxisIndex,function(t,e){var n=s.getComponent("parallelAxis",t),i=l[e];a.set(i,n),rh(n)&&null==r.firstCategoryDimIndex&&(o.set(i,n),r.firstCategoryDimIndex=e)})}};function rh(t){return"category"===t.get("type")}var ah="original",oh="arrayRows",sh="objectRows",lh="keyedColumns",hh="unknown",uh="typedArray",ch="column",dh="row";function fh(t){this.fromDataset=t.fromDataset,this.data=t.data||(t.sourceFormat===lh?{}:[]),this.sourceFormat=t.sourceFormat||hh,this.seriesLayoutBy=t.seriesLayoutBy||ch,this.dimensionsDefine=t.dimensionsDefine,this.encodeDefine=t.encodeDefine&&Q(t.encodeDefine),this.startIndex=t.startIndex||0,this.dimensionsDetectCount=t.dimensionsDetectCount}fh.seriesDataToSource=function(t){return new fh({data:t,sourceFormat:B(t)?uh:ah,fromDataset:!1})},Er(fh);var ph=Mr();function gh(t){var e=t.option,n=e.data,i=B(n)?uh:ah,r=!1,a=e.seriesLayoutBy,o=e.sourceHeader,s=e.dimensions,l=function(t){var e=t.option;if(!e.data)return t.ecModel.getComponent("dataset",e.datasetIndex||0)}(t);if(l){var h=l.option;n=h.source,i=ph(l).sourceFormat,r=!0,a=a||h.seriesLayoutBy,null==o&&(o=h.sourceHeader),s=s||h.dimensions}var u=function(t,e,n,i,r){if(!t)return{dimensionsDefine:mh(r)};var a,o,s,l;if(e===oh)"auto"===i||null==i?vh(function(t){null!=t&&"-"!==t&&(E(t)?null==o&&(o=1):o=0)},n,t,10):o=i?1:0,r||1!==o||(r=[],vh(function(t,e){r[e]=null!=t?t:""},n,t)),a=r?r.length:n===dh?t.length:t[0]?t[0].length:null;else if(e===sh)r||(r=function(t){var e,n=0;for(;n<t.length&&!(e=t[n++]););if(e){var i=[];return A(e,function(t,e){i.push(e)}),i}}(t),s=!0);else if(e===lh)r||(r=[],s=!0,A(t,function(t,e){r.push(e)}));else if(e===ah){var h=yr(t[0]);a=O(h)&&h.length||1}s&&A(r,function(t,e){"name"===(N(t)?t.name:t)&&(l=e)});return{startIndex:o,dimensionsDefine:mh(r),dimensionsDetectCount:a,potentialNameDimIndex:l}}(n,i,a,o,s),c=e.encode;!c&&l&&(c=function(t,e,n,i,r,a){var o=nh(t),s={},l=[],h=[],u=t.subType,c=Q(["pie","map","funnel"]),d=Q(["line","bar","pictorialBar","scatter","effectScatter","candlestick","boxplot"]);if(o&&null!=d.get(u)){var f=t.ecModel,p=ph(f).datasetMap,g=e.uid+"_"+r,m=p.get(g)||p.set(g,{categoryWayDim:1,valueWayDim:0});A(o.coordSysDims,function(t){if(null==o.firstCategoryDimIndex){var e=m.valueWayDim++;s[t]=e,h.push(e)}else if(o.categoryAxisMap.get(t))s[t]=0,l.push(0);else{e=m.categoryWayDim++;s[t]=e,h.push(e)}})}else if(null!=c.get(u)){for(var v,y=0;y<5&&null==v;y++)yh(n,i,r,a.dimensionsDefine,a.startIndex,y)||(v=y);if(null!=v){s.value=v;var _=a.potentialNameDimIndex||Math.max(v-1,0);h.push(_),l.push(_)}}return l.length&&(s.itemName=l),h.length&&(s.seriesName=h),s}(t,l,n,i,a,u)),ph(t).source=new fh({data:n,fromDataset:r,seriesLayoutBy:a,sourceFormat:i,dimensionsDefine:u.dimensionsDefine,startIndex:u.startIndex,dimensionsDetectCount:u.dimensionsDetectCount,encodeDefine:c})}function mh(t){if(t){var i=Q();return D(t,function(t,e){if(null==(t=I({},N(t)?t:{name:t})).name)return t;t.name+="",null==t.displayName&&(t.displayName=t.name);var n=i.get(t.name);return n?t.name+="-"+n.count++:i.set(t.name,{count:1}),t})}}function vh(t,e,n,i){if(null==i&&(i=1/0),e===dh)for(var r=0;r<n.length&&r<i;r++)t(n[r]?n[r][0]:null,r);else{var a=n[0]||[];for(r=0;r<a.length&&r<i;r++)t(a[r],r)}}function yh(t,e,n,i,r,a){var o,s;if(B(t))return!1;if(i&&(s=N(s=i[a])?s.name:s),e===oh)if(n===dh){for(var l=t[a],h=0;h<(l||[]).length&&h<5;h++)if(null!=(o=f(l[r+h])))return o}else for(h=0;h<t.length&&h<5;h++){var u=t[r+h];if(u&&null!=(o=f(u[a])))return o}else if(e===sh){if(!s)return;for(h=0;h<t.length&&h<5;h++){if((c=t[h])&&null!=(o=f(c[s])))return o}}else if(e===lh){if(!s)return;if(!(l=t[s])||B(l))return!1;for(h=0;h<l.length&&h<5;h++)if(null!=(o=f(l[h])))return o}else if(e===ah)for(h=0;h<t.length&&h<5;h++){var c,d=yr(c=t[h]);if(!O(d))return!1;if(null!=(o=f(d[a])))return o}function f(t){return(null==t||!isFinite(t)||""===t)&&(!(!E(t)||"-"===t)||void 0)}return!1}var _h="\0_ec_inner",xh=Js.extend({init:function(t,e,n,i){n=n||{},this.option=null,this._theme=new Js(n),this._optionManager=i},setOption:function(t,e){X(!(_h in t),"please use chart.getOption()"),this._optionManager.setOption(t,e),this.resetOption(null)},resetOption:function(t){var e=!1,n=this._optionManager;if(!t||"recreate"===t){var i=n.mountOption("recreate"===t);this.option&&"recreate"!==t?(this.restoreData(),this.mergeOption(i)):function(t){t=t,this.option={},this.option[_h]=1,this._componentsMap=Q({series:[]}),this._seriesIndices,this._seriesIndicesMap,function(n,t){var i=n.color&&!n.colorLayer;A(t,function(t,e){"colorLayer"===e&&i||$l.hasClass(e)||("object"==typeof t?n[e]=n[e]?m(n[e],t,!1):b(t):null==n[e]&&(n[e]=t))})}(t,this._theme.option),m(t,Jl,!1),this.mergeOption(t)}.call(this,i),e=!0}if("timeline"!==t&&"media"!==t||this.restoreData(),!t||"recreate"===t||"timeline"===t){var r=n.getTimelineOption(this);r&&(this.mergeOption(r),e=!0)}if(!t||"recreate"===t||"media"===t){var a=n.getMediaOption(this,this._api);a.length&&A(a,function(t){this.mergeOption(t,e=!0)},this)}return e},mergeOption:function(i){var l=this.option,h=this._componentsMap,n=[];!function(t){ph(t).datasetMap=Q()}(this),A(i,function(t,e){null!=t&&($l.hasClass(e)?e&&n.push(e):l[e]=null==l[e]?b(t):m(l[e],t,!0))}),$l.topologicalTravel(n,$l.getAllClassMainTypes(),function(o,t){var e=gr(i[o]),n=_r(h.get(o),e);xr(n),A(n,function(t,e){var n=t.option;N(n)&&(t.keyInfo.mainType=o,t.keyInfo.subType=function(t,e,n){return e.type?e.type:n?n.subType:$l.determineSubType(t,e)}(o,n,t.exist))});var s=function(e,t){O(t)||(t=t?[t]:[]);var n={};return A(t,function(t){n[t]=(e.get(t)||[]).slice()}),n}(h,t);l[o]=[],h.set(o,[]),A(n,function(t,e){var n=t.exist,i=t.option;if(X(N(i)||n,"Empty component definition"),i){var r=$l.getClass(o,t.keyInfo.subType,!0);if(n&&n instanceof r)n.name=t.keyInfo.name,n.mergeOption(i,this),n.optionUpdated(i,!1);else{var a=I({dependentModels:s,componentIndex:e},t.keyInfo);I(n=new r(i,this,this,a),a),n.init(i,this,this,a),n.optionUpdated(null,!0)}}else n.mergeOption({},this),n.optionUpdated({},!1);h.get(o)[e]=n,l[o][e]=n.option},this),"series"===o&&wh(this,h.get("series"))},this),this._seriesIndicesMap=Q(this._seriesIndices=this._seriesIndices||[])},getOption:function(){var i=b(this.option);return A(i,function(t,e){if($l.hasClass(e)){for(var n=(t=gr(t)).length-1;0<=n;n--)br(t[n])&&t.splice(n,1);i[e]=t}}),delete i[_h],i},getTheme:function(){return this._theme},getComponent:function(t,e){var n=this._componentsMap.get(t);if(n)return n[e||0]},queryComponents:function(t){var e=t.mainType;if(!e)return[];var n,i=t.index,r=t.id,a=t.name,o=this._componentsMap.get(e);if(!o||!o.length)return[];if(null!=i)O(i)||(i=[i]),n=C(D(i,function(t){return o[t]}),function(t){return!!t});else if(null!=r){var s=O(r);n=C(o,function(t){return s&&0<=x(r,t.id)||!s&&t.id===r})}else if(null!=a){var l=O(a);n=C(o,function(t){return l&&0<=x(a,t.name)||!l&&t.name===a})}else n=o.slice();return bh(n,t)},findComponents:function(t){var e,n,i,r,a,o=t.query,s=t.mainType,l=(n=s+"Index",i=s+"Id",r=s+"Name",!(e=o)||null==e[n]&&null==e[i]&&null==e[r]?null:{mainType:s,index:e[n],id:e[i],name:e[r]}),h=l?this.queryComponents(l):this._componentsMap.get(s);return a=bh(h,t),t.filter?C(a,t.filter):a},eachComponent:function(t,i,r){var e=this._componentsMap;if("function"==typeof t)r=i,i=t,e.each(function(t,n){A(t,function(t,e){i.call(r,n,t,e)})});else if(E(t))A(e.get(t),i,r);else if(N(t)){A(this.findComponents(t),i,r)}},getSeriesByName:function(e){return C(this._componentsMap.get("series"),function(t){return t.name===e})},getSeriesByIndex:function(t){return this._componentsMap.get("series")[t]},getSeriesByType:function(e){return C(this._componentsMap.get("series"),function(t){return t.subType===e})},getSeries:function(){return this._componentsMap.get("series").slice()},getSeriesCount:function(){return this._componentsMap.get("series").length},eachSeries:function(n,i){A(this._seriesIndices,function(t){var e=this._componentsMap.get("series")[t];n.call(i,e,t)},this)},eachRawSeries:function(t,e){A(this._componentsMap.get("series"),t,e)},eachSeriesByType:function(n,i,r){A(this._seriesIndices,function(t){var e=this._componentsMap.get("series")[t];e.subType===n&&i.call(r,e,t)},this)},eachRawSeriesByType:function(t,e,n){return A(this.getSeriesByType(t),e,n)},isSeriesFiltered:function(t){return null==this._seriesIndicesMap.get(t.componentIndex)},getCurrentSeriesIndices:function(){return(this._seriesIndices||[]).slice()},filterSeries:function(t,e){var n=C(this._componentsMap.get("series"),t,e);wh(this,n)},restoreData:function(n){var i=this._componentsMap;wh(this,i.get("series"));var r=[];i.each(function(t,e){r.push(e)}),$l.topologicalTravel(r,$l.getAllClassMainTypes(),function(e,t){A(i.get(e),function(t){"series"===e&&function(t,e){if(e){var n=e.seiresIndex,i=e.seriesId,r=e.seriesName;return null!=n&&t.componentIndex!==n||null!=i&&t.id!==i||null!=r&&t.name!==r}}(t,n)||t.restoreData()})})}});function wh(t,e){t._seriesIndicesMap=Q(t._seriesIndices=D(e,function(t){return t.componentIndex})||[])}function bh(t,e){return e.hasOwnProperty("subType")?C(t,function(t){return t.subType===e.subType}):t}S(xh,eh);var Sh=["getDom","getZr","getWidth","getHeight","getDevicePixelRatio","dispatchAction","isDisposed","on","off","getDataURL","getConnectedDataURL","getModel","getOption","getViewOfComponentModel","getViewOfSeriesModel"];function Mh(e){A(Sh,function(t){this[t]=k(e[t],e)},this)}var Ih={};function Ch(){this._coordinateSystems=[]}Ch.prototype={constructor:Ch,create:function(i,r){var a=[];A(Ih,function(t,e){var n=t.create(i,r);a=a.concat(n||[])}),this._coordinateSystems=a},update:function(e,n){A(this._coordinateSystems,function(t){t.update&&t.update(e,n)})},getCoordinateSystems:function(){return this._coordinateSystems.slice()}},Ch.register=function(t,e){Ih[t]=e},Ch.get=function(t){return Ih[t]};var Th=A,Ah=b,Dh=D,kh=m,Ph=/^(min|max)?(.+)$/;function Lh(t){this._api=t,this._timelineOptions=[],this._mediaList=[],this._mediaDefault,this._currentMediaIndices=[],this._optionBackup,this._newBaseOption}function Oh(t,e,n){var a={width:e,height:n,aspectratio:e/n},o=!0;return A(t,function(t,e){var n=e.match(Ph);if(n&&n[1]&&n[2]){var i=n[1],r=n[2].toLowerCase();!function(t,e,n){return"min"===n?e<=t:"max"===n?t<=e:t===e}(a[r],t,i)&&(o=!1)}}),o}Lh.prototype={constructor:Lh,setOption:function(t,e){t&&A(gr(t.series),function(t){t&&t.data&&B(t.data)&&q(t.data)}),t=Ah(t);var n=this._optionBackup,i=function(t,n,i){var e,r,a=[],o=[],s=t.timeline;t.baseOption&&(r=t.baseOption);(s||t.options)&&(r=r||{},a=(t.options||[]).slice());if(t.media){r=r||{};var l=t.media;Th(l,function(t){t&&t.option&&(t.query?o.push(t):e=e||t)})}r=r||t;r.timeline||(r.timeline=s);return Th([r].concat(a).concat(D(o,function(t){return t.option})),function(e){Th(n,function(t){t(e,i)})}),{baseOption:r,timelineOptions:a,mediaDefault:e,mediaList:o}}.call(this,t,e,!n);this._newBaseOption=i.baseOption,n?(function(r,t){Th(t=t||{},function(t,e){if(null!=t){var n=r[e];if($l.hasClass(e)){t=gr(t);var i=_r(n=gr(n),t);r[e]=Dh(i,function(t){return t.option&&t.exist?kh(t.exist,t.option,!0):t.exist||t.option})}else r[e]=kh(n,t,!0)}})}(n.baseOption,i.baseOption),i.timelineOptions.length&&(n.timelineOptions=i.timelineOptions),i.mediaList.length&&(n.mediaList=i.mediaList),i.mediaDefault&&(n.mediaDefault=i.mediaDefault)):this._optionBackup=i},mountOption:function(t){var e=this._optionBackup;return this._timelineOptions=Dh(e.timelineOptions,Ah),this._mediaList=Dh(e.mediaList,Ah),this._mediaDefault=Ah(e.mediaDefault),this._currentMediaIndices=[],Ah(t?e.baseOption:this._newBaseOption)},getTimelineOption:function(t){var e,n=this._timelineOptions;if(n.length){var i=t.getComponent("timeline");i&&(e=Ah(n[i.getCurrentIndex()],!0))}return e},getMediaOption:function(t){var e=this._api.getWidth(),n=this._api.getHeight(),i=this._mediaList,r=this._mediaDefault,a=[],o=[];if(!i.length&&!r)return o;for(var s=0,l=i.length;s<l;s++)Oh(i[s].query,e,n)&&a.push(s);return!a.length&&r&&(a=[-1]),a.length&&!function(t,e){return t.join(",")===e.join(",")}(a,this._currentMediaIndices)&&(o=Dh(a,function(t){return Ah(-1===t?r.option:i[t].option)})),this._currentMediaIndices=a,o}};var zh=A,Eh=N,Nh=["areaStyle","lineStyle","nodeStyle","linkStyle","chordStyle","label","labelLine"];function Rh(t){var e=t&&t.itemStyle;if(e)for(var n=0,i=Nh.length;n<i;n++){var r=Nh[n],a=e.normal,o=e.emphasis;a&&a[r]&&(t[r]=t[r]||{},t[r].normal?m(t[r].normal,a[r]):t[r].normal=a[r],a[r]=null),o&&o[r]&&(t[r]=t[r]||{},t[r].emphasis?m(t[r].emphasis,o[r]):t[r].emphasis=o[r],o[r]=null)}}function Bh(t,e,n){if(t&&t[e]&&(t[e].normal||t[e].emphasis)){var i=t[e].normal,r=t[e].emphasis;i&&(n?(t[e].normal=t[e].emphasis=null,T(t[e],i)):t[e]=i),r&&(t.emphasis=t.emphasis||{},t.emphasis[e]=r)}}function Fh(t){Bh(t,"itemStyle"),Bh(t,"lineStyle"),Bh(t,"areaStyle"),Bh(t,"label"),Bh(t,"labelLine"),Bh(t,"upperLabel"),Bh(t,"edgeLabel")}function Vh(t,e){var n=Eh(t)&&t[e],i=Eh(n)&&n.textStyle;if(i)for(var r=0,a=vr.length;r<a;r++){e=vr[r];i.hasOwnProperty(e)&&(n[e]=i[e])}}function Hh(t){t&&(Fh(t),Vh(t,"label"),t.emphasis&&Vh(t.emphasis,"label"))}function Wh(t){return O(t)?t:t?[t]:[]}function Gh(t){return(O(t)?t[0]:t)||{}}function Zh(e,t){zh(Wh(e.series),function(t){Eh(t)&&function(t){if(Eh(t)){Rh(t),Fh(t),Vh(t,"label"),Vh(t,"upperLabel"),Vh(t,"edgeLabel"),t.emphasis&&(Vh(t.emphasis,"label"),Vh(t.emphasis,"upperLabel"),Vh(t.emphasis,"edgeLabel")),(n=t.markPoint)&&(Rh(n),Hh(n)),(i=t.markLine)&&(Rh(i),Hh(i));var e=t.markArea;e&&Hh(e);var n,i,r=t.data;if("graph"===t.type){r=r||t.nodes;var a=t.links||t.edges;if(a&&!B(a))for(var o=0;o<a.length;o++)Hh(a[o]);A(t.categories,function(t){Fh(t)})}if(r&&!B(r))for(o=0;o<r.length;o++)Hh(r[o]);if((n=t.markPoint)&&n.data){var s=n.data;for(o=0;o<s.length;o++)Hh(s[o])}if((i=t.markLine)&&i.data){var l=i.data;for(o=0;o<l.length;o++)O(l[o])?(Hh(l[o][0]),Hh(l[o][1])):Hh(l[o])}"gauge"===t.type?(Vh(t,"axisLabel"),Vh(t,"title"),Vh(t,"detail")):"treemap"===t.type?(Bh(t.breadcrumb,"itemStyle"),A(t.levels,function(t){Fh(t)})):"tree"===t.type&&Fh(t.leaves)}}(t)});var n=["xAxis","yAxis","radiusAxis","angleAxis","singleAxis","parallelAxis","radar"];t&&n.push("valueAxis","categoryAxis","logAxis","timeAxis"),zh(n,function(t){zh(Wh(e[t]),function(t){t&&(Vh(t,"axisLabel"),Vh(t.axisPointer,"label"))})}),zh(Wh(e.parallel),function(t){var e=t&&t.parallelAxisDefault;Vh(e,"axisLabel"),Vh(e&&e.axisPointer,"label")}),zh(Wh(e.calendar),function(t){Bh(t,"itemStyle"),Vh(t,"dayLabel"),Vh(t,"monthLabel"),Vh(t,"yearLabel")}),zh(Wh(e.radar),function(t){Vh(t,"name")}),zh(Wh(e.geo),function(t){Eh(t)&&(Hh(t),zh(Wh(t.regions),function(t){Hh(t)}))}),zh(Wh(e.timeline),function(t){Hh(t),Bh(t,"label"),Bh(t,"itemStyle"),Bh(t,"controlStyle",!0);var e=t.data;O(e)&&A(e,function(t){N(t)&&(Bh(t,"label"),Bh(t,"itemStyle"))})}),zh(Wh(e.toolbox),function(t){Bh(t,"iconStyle"),zh(t.feature,function(t){Bh(t,"iconStyle")})}),Vh(Gh(e.axisPointer),"label"),Vh(Gh(e.tooltip).axisPointer,"label")}function Uh(e){A(Xh,function(t){t[0]in e&&!(t[1]in e)&&(e[t[1]]=e[t[0]])})}var Xh=[["x","left"],["y","top"],["x2","right"],["y2","bottom"]],Yh=["grid","geo","parallel","legend","toolbox","title","visualMap","dataZoom","timeline"],jh=function(n,t){Zh(n,t),n.series=gr(n.series),A(n.series,function(t){if(N(t)){var e=t.type;if("pie"!==e&&"gauge"!==e||null!=t.clockWise&&(t.clockwise=t.clockWise),"gauge"===e){var n=function(t,e){e=e.split(",");for(var n=t,i=0;i<e.length&&null!=(n=n&&n[e[i]]);i++);return n}(t,"pointer.color");null!=n&&function(t,e,n,i){e=e.split(",");for(var r,a=t,o=0;o<e.length-1;o++)null==a[r=e[o]]&&(a[r]={}),a=a[r];!i&&null!=a[e[o]]||(a[e[o]]=n)}(t,"itemStyle.color",n)}Uh(t)}}),n.dataRange&&(n.visualMap=n.dataRange),A(Yh,function(t){var e=n[t];e&&(O(e)||(e=[e]),A(e,function(t){Uh(t)}))})};function qh(m){A(m,function(u,c){var d=[],f=[NaN,NaN],t=[u.stackResultDimension,u.stackedOverDimension],p=u.data,g=u.isStackedByIndex,e=p.map(t,function(t,e,n){var i,r,a=p.get(u.stackedDimension,n);if(isNaN(a))return f;g?r=p.getRawIndex(n):i=p.get(u.stackedByDimension,n);for(var o=NaN,s=c-1;0<=s;s--){var l=m[s];if(g||(r=l.data.rawIndexOf(l.stackedByDimension,i)),0<=r){var h=l.data.getByRawIndex(l.stackResultDimension,r);if(0<=a&&0<h||a<=0&&h<0){a+=h,o=h;break}}}return d[0]=a,d[1]=o,d});p.hostModel.setData(e),u.data=e})}function $h(t,e){fh.isInstance(t)||(t=fh.seriesDataToSource(t)),this._source=t;var n=this._data=t.data,i=t.sourceFormat;i===uh&&(this._offset=0,this._dimSize=e,this._data=n),I(this,Qh[i===oh?i+"_"+t.seriesLayoutBy:i])}var Kh=$h.prototype;Kh.pure=!1;var Qh={arrayRows_column:{pure:Kh.persistent=!0,count:function(){return Math.max(0,this._data.length-this._source.startIndex)},getItem:function(t){return this._data[t+this._source.startIndex]},appendData:eu},arrayRows_row:{pure:!0,count:function(){var t=this._data[0];return t?Math.max(0,t.length-this._source.startIndex):0},getItem:function(t){t+=this._source.startIndex;for(var e=[],n=this._data,i=0;i<n.length;i++){var r=n[i];e.push(r?r[t]:null)}return e},appendData:function(){throw new Error('Do not support appendData when set seriesLayoutBy: "row".')}},objectRows:{pure:!0,count:Jh,getItem:tu,appendData:eu},keyedColumns:{pure:!0,count:function(){var t=this._source.dimensionsDefine[0].name,e=this._data[t];return e?e.length:0},getItem:function(t){for(var e=[],n=this._source.dimensionsDefine,i=0;i<n.length;i++){var r=this._data[n[i].name];e.push(r?r[t]:null)}return e},appendData:function(t){var r=this._data;A(t,function(t,e){for(var n=r[e]||(r[e]=[]),i=0;i<(t||[]).length;i++)n.push(t[i])})}},original:{count:Jh,getItem:tu,appendData:eu},typedArray:{persistent:!(Kh.getSource=function(){return this._source}),pure:!0,count:function(){return this._data?this._data.length/this._dimSize:0},getItem:function(t,e){t-=this._offset,e=e||[];for(var n=this._dimSize*t,i=0;i<this._dimSize;i++)e[i]=this._data[n+i];return e},appendData:function(t){this._data=t},clean:function(){this._offset+=this.count(),this._data=null}}};function Jh(){return this._data.length}function tu(t){return this._data[t]}function eu(t){for(var e=0;e<t.length;e++)this._data.push(t[e])}var nu={arrayRows:iu,objectRows:function(t,e,n,i){return null!=n?t[i]:t},keyedColumns:iu,original:function(t,e,n,i){var r=yr(t);return null!=n&&r instanceof Array?r[n]:r},typedArray:iu};function iu(t,e,n,i){return null!=n?t[n]:t}var ru={arrayRows:au,objectRows:function(t,e,n,i){return ou(t[e],this._dimensionInfos[e])},keyedColumns:au,original:function(t,e,n,i){var r=t&&(null==t.value?t:t.value);return!this._rawData.pure&&function(t){return dr(t)&&!(t instanceof Array)}(t)&&(this.hasItemOption=!0),ou(r instanceof Array?r[i]:r,this._dimensionInfos[e])},typedArray:function(t,e,n,i){return t[i]}};function au(t,e,n,i){return ou(t[i],this._dimensionInfos[e])}function ou(t,e){var n=e&&e.type;if("ordinal"!==n)return"time"===n&&"number"!=typeof t&&null!=t&&"-"!==t&&(t=+ml(t)),null==t||""===t?NaN:+t;var i=e&&e.ordinalMeta;return i?i.parseAndCollect(t):t}function su(t,e,n){if(t){var i=t.getRawDataItem(e);if(null!=i){var r,a,o=t.getProvider().getSource().sourceFormat,s=t.getDimensionInfo(n);return s&&(r=s.name,a=s.index),nu[o](i,e,a,r)}}}function lu(t,e,n){if(t){var i=t.getProvider().getSource().sourceFormat;if(i===ah||i===sh){var r=t.getRawDataItem(e);return i!==ah||N(r)||(r=null),r?r[n]:void 0}}}var hu=/\{@(.+?)\}/g,uu={getDataParams:function(t,e){var n=this.getData(e),i=this.getRawValue(t,e),r=n.getRawIndex(t),a=n.getName(t),o=n.getRawDataItem(t),s=n.getItemVisual(t,"color"),l=this.ecModel.getComponent("tooltip"),h=Dr(l&&l.get("renderMode")),u=this.mainType,c="series"===u,d=n.userOutput;return{componentType:u,componentSubType:this.subType,componentIndex:this.componentIndex,seriesType:c?this.subType:null,seriesIndex:this.seriesIndex,seriesId:c?this.id:null,seriesName:c?this.name:null,name:a,dataIndex:r,data:o,dataType:e,value:i,color:s,dimensionNames:d?d.dimensionNames:null,encode:d?d.encode:null,marker:kl({color:s,renderMode:h}),$vars:["seriesName","name","value"]}},getFormattedLabel:function(i,t,e,n,r){t=t||"normal";var a=this.getData(e),o=a.getItemModel(i),s=this.getDataParams(i,e);null!=n&&s.value instanceof Array&&(s.value=s.value[n]);var l=o.get("normal"===t?[r||"label","formatter"]:[t,r||"label","formatter"]);return"function"==typeof l?(s.status=t,s.dimensionIndex=n,l(s)):"string"==typeof l?Dl(l,s).replace(hu,function(t,e){var n=e.length;return"["===e.charAt(0)&&"]"===e.charAt(n-1)&&(e=+e.slice(1,n-1)),su(a,i,e)}):void 0},getRawValue:function(t,e){return su(this.getData(e),t)},formatTooltip:function(){}};function cu(t){return new du(t)}function du(t){t=t||{},this._reset=t.reset,this._plan=t.plan,this._count=t.count,this._onDirty=t.onDirty,this._dirty=!0,this.context}var fu=du.prototype;fu.perform=function(t){var e,n=this._upstream,i=t&&t.skip;if(this._dirty&&n){var r=this.context;r.data=r.outputData=n.context.outputData}this.__pipeline&&(this.__pipeline.currentTask=this),this._plan&&!i&&(e=this._plan(this.context));var a,o=u(this._modBy),s=this._modDataCount||0,l=u(t&&t.modBy),h=t&&t.modDataCount||0;function u(t){return 1<=t||(t=1),t}o===l&&s===h||(e="reset"),!this._dirty&&"reset"!==e||(this._dirty=!1,a=function(t,e){var n,i;t._dueIndex=t._outputDueEnd=t._dueEnd=0,t._settedOutputEnd=null,!e&&t._reset&&((n=t._reset(t.context))&&n.progress&&(i=n.forceFirstProgress,n=n.progress),O(n)&&!n.length&&(n=null));t._progress=n,t._modBy=t._modDataCount=null;var r=t._downstream;return r&&r.dirty(),i}(this,i)),this._modBy=l,this._modDataCount=h;var c=t&&t.step;if(this._dueEnd=n?n._outputDueEnd:this._count?this._count(this.context):1/0,this._progress){var d=this._dueIndex,f=Math.min(null!=c?this._dueIndex+c:1/0,this._dueEnd);if(!i&&(a||d<f)){var p=this._progress;if(O(p))for(var g=0;g<p.length;g++)Su(this,p[g],d,f,l,h);else Su(this,p,d,f,l,h)}this._dueIndex=f;var m=null!=this._settedOutputEnd?this._settedOutputEnd:f;this._outputDueEnd=m}else this._dueIndex=this._outputDueEnd=null!=this._settedOutputEnd?this._settedOutputEnd:this._dueEnd;return this.unfinished()};var pu,gu,mu,vu,yu,_u,xu=_u={reset:function(t,e,n,i){gu=t,pu=e,mu=n,vu=i,yu=Math.ceil(vu/mu),_u.next=1<mu&&0<vu?bu:wu}};function wu(){return gu<pu?gu++:null}function bu(){var t=gu%yu*mu+Math.ceil(gu/yu),e=pu<=gu?null:t<vu?t:gu;return gu++,e}function Su(t,e,n,i,r,a){xu.reset(n,i,r,a),t._callingProgress=e,t._callingProgress({start:n,end:i,count:i-n,next:xu.next},t.context)}fu.dirty=function(){this._dirty=!0,this._onDirty&&this._onDirty(this.context)},fu.unfinished=function(){return this._progress&&this._dueIndex<this._dueEnd},fu.pipe=function(t){this._downstream===t&&!this._dirty||((this._downstream=t)._upstream=this,t.dirty())},fu.dispose=function(){this._disposed||(this._upstream&&(this._upstream._downstream=null),this._downstream&&(this._downstream._upstream=null),this._dirty=!1,this._disposed=!0)},fu.getUpstream=function(){return this._upstream},fu.getDownstream=function(){return this._downstream},fu.setOutputEnd=function(t){this._outputDueEnd=this._settedOutputEnd=t};var Mu=Mr(),Iu=$l.extend({type:"series.__base__",seriesIndex:0,coordinateSystem:null,defaultOption:null,legendDataProvider:null,visualColorAccessPath:"itemStyle.color",layoutMode:null,init:function(t,e,n,i){this.seriesIndex=this.componentIndex,this.dataTask=cu({count:Tu,reset:Au}),this.dataTask.context={model:this},this.mergeDefaultAndTheme(t,n),gh(this);var r=this.getInitialData(t,n);ku(r,this),this.dataTask.context.data=r,Mu(this).dataBeforeProcessed=r,Cu(this)},mergeDefaultAndTheme:function(t,e){var n=this.layoutMode,i=n?Zl(t):{},r=this.subType;$l.hasClass(r)&&(r+="Series"),m(t,e.getTheme().get(this.subType)),m(t,this.getDefaultOption()),mr(t,"label",["show"]),this.fillDataTextStyle(t.data),n&&Gl(t,i,n)},mergeOption:function(t,e){t=m(this.option,t,!0),this.fillDataTextStyle(t.data);var n=this.layoutMode;n&&Gl(this.option,t,n),gh(this);var i=this.getInitialData(t,e);ku(i,this),this.dataTask.dirty(),this.dataTask.context.data=i,Mu(this).dataBeforeProcessed=i,Cu(this)},fillDataTextStyle:function(t){if(t&&!B(t))for(var e=["show"],n=0;n<t.length;n++)t[n]&&t[n].label&&mr(t[n],"label",e)},getInitialData:function(){},appendData:function(t){this.getRawData().appendData(t.data)},getData:function(t){var e=Lu(this);if(e){var n=e.context.data;return null==t?n:n.getLinkedData(t)}return Mu(this).data},setData:function(t){var e=Lu(this);if(e){var n=e.context;n.data!==t&&e.modifyOutputEnd&&e.setOutputEnd(t.count()),n.outputData=t,e!==this.dataTask&&(n.data=t)}Mu(this).data=t},getSource:function(){return function(t){return ph(t).source}(this)},getRawData:function(){return Mu(this).dataBeforeProcessed},getBaseAxis:function(){var t=this.coordinateSystem;return t&&t.getBaseAxis&&t.getBaseAxis()},formatTooltip:function(r,u,t,c){var d=this,e="html"===(c=c||"html")?"<br/>":"\n",f="richText"===c,p={},g=0;function n(t){return{renderMode:c,content:Cl(wl(t)),style:p}}var m=this.getData(),a=m.mapDimension("defaultedTooltip",!0),i=a.length,o=this.getRawValue(r),s=O(o),v=m.getItemVisual(r,"color");N(v)&&v.colorStops&&(v=(v.colorStops[0]||{}).color),v=v||"transparent";var l=(1<i||s&&!i?function(t){var l=M(t,function(t,e,n){var i=m.getDimensionInfo(n);return t|(i&&!1!==i.tooltip&&null!=i.displayName)},0),h=[];function e(t,e){var n=m.getDimensionInfo(e);if(n&&!1!==n.otherDims.tooltip){var i=n.type,r="sub"+d.seriesIndex+"at"+g,a=kl({color:v,type:"subItem",renderMode:c,markerId:r}),o="string"==typeof a?a:a.content,s=(l?o+Cl(n.displayName||"-")+": ":"")+Cl("ordinal"===i?t+"":"time"===i?u?"":Ll("yyyy/MM/dd hh:mm:ss",t):wl(t));s&&h.push(s),f&&(p[r]=v,++g)}}a.length?A(a,function(t){e(su(m,r,t),t)}):A(t,e);var n=l?f?"\n":"<br/>":"",i=n+h.join(n||", ");return{renderMode:c,content:i,style:p}}(o):n(i?su(m,r,a[0]):s?o[0]:o)).content,h=d.seriesIndex+"at"+g,y=kl({color:v,type:"item",renderMode:c,markerId:h});p[h]=v,++g;var _=m.getName(r),x=this.name;wr(this)||(x=""),x=x?Cl(x)+(u?": ":e):"";var w="string"==typeof y?y:y.content;return{html:u?w+x+l:x+w+(_?Cl(_)+": "+l:l),markers:p}},isAnimationEnabled:function(){if(v.node)return!1;var t=this.getShallow("animation");return t&&this.getData().count()>this.getShallow("animationThreshold")&&(t=!1),t},restoreData:function(){this.dataTask.dirty()},getColorFromPalette:function(t,e,n){var i=this.ecModel,r=eh.getColorFromPalette.call(this,t,e,n);return r=r||i.getColorFromPalette(t,e,n)},coordDimToDataDim:function(t){return this.getRawData().mapDimension(t,!0)},getProgressive:function(){return this.get("progressive")},getProgressiveThreshold:function(){return this.get("progressiveThreshold")},getAxisTooltipData:null,getTooltipPosition:null,pipeTask:null,preventIncremental:null,pipelineContext:null});function Cu(t){var e=t.name;wr(t)||(t.name=function(t){var n=t.getRawData(),e=n.mapDimension("seriesName",!0),i=[];return A(e,function(t){var e=n.getDimensionInfo(t);e.displayName&&i.push(e.displayName)}),i.join(" ")}(t)||e)}function Tu(t){return t.model.getRawData().count()}function Au(t){var e=t.model;return e.setData(e.getRawData().cloneShallow()),Du}function Du(t,e){t.end>e.outputData.count()&&e.model.getRawData().cloneShallow(e.outputData)}function ku(e,n){A(e.CHANGABLE_METHODS,function(t){e.wrapMethod(t,P(Pu,n))})}function Pu(t){var e=Lu(t);e&&e.setOutputEnd(this.count())}function Lu(t){var e=(t.ecModel||{}).scheduler,n=e&&e.getPipeline(t.uid);if(n){var i=n.currentTask;if(i){var r=i.agentStubMap;r&&(i=r.get(t.uid))}return i}}S(Iu,uu),S(Iu,eh);var Ou=function(){this.group=new yn,this.uid=il("viewComponent")};Ou.prototype={constructor:Ou,init:function(t,e){},render:function(t,e,n,i){},dispose:function(){},filterForExposedEvent:null};var zu=Ou.prototype;zu.updateView=zu.updateLayout=zu.updateVisual=function(t,e,n,i){},Or(Ou),Br(Ou,{registerWhenExtend:!0});function Eu(){var s=Mr();return function(t){var e=s(t),n=t.pipelineContext,i=e.large,r=e.progressiveRender,a=e.large=n.large,o=e.progressiveRender=n.progressiveRender;return!!(i^a||r^o)&&"reset"}}var Nu=Mr(),Ru=Eu();function Bu(){this.group=new yn,this.uid=il("viewChart"),this.renderTask=cu({plan:Wu,reset:Gu}),this.renderTask.context={view:this}}var Fu=Bu.prototype={type:"chart",init:function(t,e){},render:function(t,e,n,i){},highlight:function(t,e,n,i){Hu(t.getData(),i,"emphasis")},downplay:function(t,e,n,i){Hu(t.getData(),i,"normal")},remove:function(t,e){this.group.removeAll()},dispose:function(){},incrementalPrepareRender:null,incrementalRender:null,updateTransform:null,filterForExposedEvent:null};function Vu(t,e,n){if(t&&(t.trigger(e,n),t.isGroup&&!Is(t)))for(var i=0,r=t.childCount();i<r;i++)Vu(t.childAt(i),e,n)}function Hu(e,t,n){var i=Sr(e,t),r=t&&null!=t.highlightKey?Cs(t.highlightKey):null;null!=i?A(gr(i),function(t){Vu(e.getItemGraphicEl(t),n,r)}):e.eachItemGraphicEl(function(t){Vu(t,n,r)})}function Wu(t){return Ru(t.model)}function Gu(t){var e=t.model,n=t.ecModel,i=t.api,r=t.payload,a=e.pipelineContext.progressiveRender,o=t.view,s=r&&Nu(r).updateMethod,l=a?"incrementalPrepareRender":s&&o[s]?s:"render";return"render"!==l&&o[l](e,n,i,r),Zu[l]}Fu.updateView=Fu.updateLayout=Fu.updateVisual=function(t,e,n,i){this.render(t,e,n,i)},Or(Bu),Br(Bu,{registerWhenExtend:!0}),Bu.markUpdateMethod=function(t,e){Nu(t).updateMethod=e};var Zu={incrementalPrepareRender:{progress:function(t,e){e.view.incrementalRender(t,e.model,e.ecModel,e.api,e.payload)}},render:{forceFirstProgress:!0,progress:function(t,e){e.view.render(e.model,e.ecModel,e.api,e.payload)}}},Uu="\0__throttleOriginMethod",Xu="\0__throttleRate",Yu="\0__throttleType";function ju(t,n,i){var r,a,o,s,l,h=0,u=0,c=null;function d(){u=(new Date).getTime(),c=null,t.apply(o,s||[])}n=n||0;function e(){r=(new Date).getTime(),o=this,s=arguments;var t=l||n,e=l||i;l=null,a=r-(e?h:u)-t,clearTimeout(c),e?c=setTimeout(d,t):0<=a?d():c=setTimeout(d,-a),h=r}return e.clear=function(){c&&(clearTimeout(c),c=null)},e.debounceNextCall=function(t){l=t},e}function qu(t,e,n,i){var r=t[e];if(r){var a=r[Uu]||r,o=r[Yu];if(r[Xu]!==n||o!==i){if(null==n||!i)return t[e]=a;(r=t[e]=ju(a,n,"debounce"===i))[Uu]=a,r[Yu]=i,r[Xu]=n}return r}}function $u(t,e){var n=t[e];n&&n[Uu]&&(t[e]=n[Uu])}var Ku={createOnAllSeries:!0,performRawSeries:!0,reset:function(e,t){var n=e.getData(),i=(e.visualColorAccessPath||"itemStyle.color").split("."),r=e.get(i)||e.getColorFromPalette(e.name,null,t.getSeriesCount());if(n.setVisual("color",r),!t.isSeriesFiltered(e)){"function"!=typeof r||r instanceof Ho||n.each(function(t){n.setItemVisual(t,"color",r(e.getDataParams(t)))});return{dataEach:n.hasItemOption?function(t,e){var n=t.getItemModel(e).get(i,!0);null!=n&&t.setItemVisual(e,"color",n)}:null}}}},Qu={toolbox:{brush:{title:{rect:"Box Select",polygon:"Lasso Select",lineX:"Horizontally Select",lineY:"Vertically Select",keep:"Keep Selections",clear:"Clear Selections"}},dataView:{title:"Data View",lang:["Data View","Close","Refresh"]},dataZoom:{title:{zoom:"Zoom",back:"Zoom Reset"}},magicType:{title:{line:"Switch to Line Chart",bar:"Switch to Bar Chart",stack:"Stack",tiled:"Tile"}},restore:{title:"Restore"},saveAsImage:{title:"Save as Image",lang:["Right Click to Save Image"]}},aria:{general:{withTitle:'This is a chart about "{title}"',withoutTitle:"This is a chart"},series:{single:{prefix:"",withName:" with type {seriesType} named {seriesName}.",withoutName:" with type {seriesType}."},multiple:{prefix:". It consists of {seriesCount} series count.",withName:" The {seriesId} series is a {seriesType} representing {seriesName}.",withoutName:" The {seriesId} series is a {seriesType}.",separator:{middle:"",end:""}}},data:{allData:"The data is as follows: ",partialData:"The first {displayCnt} items are: ",withName:"the data for {name} is {value}",withoutName:"{value}",separator:{middle:",",end:"."}}}},Ju=function(t,e){var a=e.getModel("aria");if(a.get("show"))if(a.get("description"))t.setAttribute("aria-label",a.get("description"));else{var u=0;e.eachSeries(function(t,e){++u},this);var n,c=a.get("data.maxCount")||10,i=a.get("series.maxCount")||10,d=Math.min(u,i);if(!(u<1)){var r=function(){var t=e.getModel("title").option;t&&t.length&&(t=t[0]);return t&&t.text}();n=r?p(g("general.withTitle"),{title:r}):g("general.withoutTitle");var f=[];n+=p(g(1<u?"series.multiple.prefix":"series.single.prefix"),{seriesCount:u}),e.eachSeries(function(t,e){if(e<d){var n,i=t.get("name"),r="series."+(1<u?"multiple":"single")+".";n=p(n=g(i?r+"withName":r+"withoutName"),{seriesId:t.seriesIndex,seriesName:t.get("name"),seriesType:function(t){return Qu.series.typeNames[t]||"自定义图"}(t.subType)});var a=t.getData();(window.data=a).count()>c?n+=p(g("data.partialData"),{displayCnt:c}):n+=g("data.allData");for(var o=[],s=0;s<a.count();s++)if(s<c){var l=a.getName(s),h=su(a,s);o.push(p(g(l?"data.withName":"data.withoutName"),{name:l,value:h}))}n+=o.join(g("data.separator.middle"))+g("data.separator.end"),f.push(n)}}),n+=f.join(g("series.multiple.separator.middle"))+g("series.multiple.separator.end"),t.setAttribute("aria-label",n)}}function p(t,e){if("string"!=typeof t)return t;var n=t;return A(e,function(t,e){n=n.replace(new RegExp("\\{\\s*"+e+"\\s*\\}","g"),t)}),n}function g(t){var e=a.get(t);if(null!=e)return e;for(var n=t.split("."),i=Qu.aria,r=0;r<n.length;++r)i=i[n[r]];return i}},tc=Math.PI;function ec(t,e,n,i){this.ecInstance=t,this.api=e,this.unfinished;n=this._dataProcessorHandlers=n.slice(),i=this._visualHandlers=i.slice();this._allHandlers=n.concat(i),this._stageTaskMap=Q()}var nc=ec.prototype;function ic(l,t,h,u,c){var d;function f(t,e){return t.setDirty&&(!t.dirtyMap||t.dirtyMap.get(e.__pipeline.id))}c=c||{},A(t,function(i,t){if(!c.visualType||c.visualType===i.visualType){var e=l._stageTaskMap.get(i.uid),n=e.seriesTaskMap,r=e.overallTask;if(r){var a,o=r.agentStubMap;o.each(function(t){f(c,t)&&(t.dirty(),a=!0)}),a&&r.dirty(),rc(r,u);var s=l.getPerformArgs(r,c.block);o.each(function(t){t.perform(s)}),d|=r.perform(s)}else n&&n.each(function(t,e){f(c,t)&&t.dirty();var n=l.getPerformArgs(t,c.block);n.skip=!i.performRawSeries&&h.isSeriesFiltered(t.context.model),rc(t,u),d|=t.perform(n)})}}),l.unfinished|=d}nc.restoreData=function(t,e){t.restoreData(e),this._stageTaskMap.each(function(t){var e=t.overallTask;e&&e.dirty()})},nc.getPerformArgs=function(t,e){if(t.__pipeline){var n=this._pipelineMap.get(t.__pipeline.id),i=n.context,r=!e&&n.progressiveEnabled&&(!i||i.progressiveRender)&&t.__idxInPipeline>n.blockIndex?n.step:null,a=i&&i.modDataCount;return{step:r,modBy:null!=a?Math.ceil(a/r):null,modDataCount:a}}},nc.getPipeline=function(t){return this._pipelineMap.get(t)},nc.updateStreamModes=function(t,e){var n=this._pipelineMap.get(t.uid),i=t.getData().count(),r=n.progressiveEnabled&&e.incrementalPrepareRender&&i>=n.threshold,a=t.get("large")&&i>=t.get("largeThreshold"),o="mod"===t.get("progressiveChunkMode")?i:null;t.pipelineContext=n.context={progressiveRender:r,modDataCount:o,large:a}},nc.restorePipelines=function(t){var i=this,r=i._pipelineMap=Q();t.eachSeries(function(t){var e=t.getProgressive(),n=t.uid;r.set(n,{id:n,head:null,tail:null,threshold:t.getProgressiveThreshold(),progressiveEnabled:e&&!(t.preventIncremental&&t.preventIncremental()),blockIndex:-1,step:Math.round(e||700),count:0}),pc(i,t,t.dataTask)})},nc.prepareStageTasks=function(){var n=this._stageTaskMap,i=this.ecInstance.getModel(),r=this.api;A(this._allHandlers,function(t){var e=n.get(t.uid)||n.set(t.uid,[]);t.reset&&function(i,r,t,a,o){var s=t.seriesTaskMap||(t.seriesTaskMap=Q()),e=r.seriesType,n=r.getTargetSeries;r.createOnAllSeries?a.eachRawSeries(l):e?a.eachRawSeriesByType(e,l):n&&n(a,o).each(l);function l(t){var e=t.uid,n=s.get(e)||s.set(e,cu({plan:hc,reset:uc,count:fc}));n.context={model:t,ecModel:a,api:o,useClearVisual:r.isVisual&&!r.isLayout,plan:r.plan,reset:r.reset,scheduler:i},pc(i,t,n)}var h=i._pipelineMap;s.each(function(t,e){h.get(e)||(t.dispose(),s.removeKey(e))})}(this,t,e,i,r),t.overallReset&&function(i,t,e,n,r){var a=e.overallTask=e.overallTask||cu({reset:ac});a.context={ecModel:n,api:r,overallReset:t.overallReset,scheduler:i};var o=a.agentStubMap=a.agentStubMap||Q(),s=t.seriesType,l=t.getTargetSeries,h=!0,u=t.modifyOutputEnd;s?n.eachRawSeriesByType(s,c):l?l(n,r).each(c):(h=!1,A(n.getSeries(),c));function c(t){var e=t.uid,n=o.get(e);n||(n=o.set(e,cu({reset:oc,onDirty:lc})),a.dirty()),n.context={model:t,overallProgress:h,modifyOutputEnd:u},n.agent=a,n.__block=h,pc(i,t,n)}var d=i._pipelineMap;o.each(function(t,e){d.get(e)||(t.dispose(),a.dirty(),o.removeKey(e))})}(this,t,e,i,r)},this)},nc.prepareView=function(t,e,n,i){var r=t.renderTask,a=r.context;a.model=e,a.ecModel=n,a.api=i,r.__block=!t.incrementalPrepareRender,pc(this,e,r)},nc.performDataProcessorTasks=function(t,e){ic(this,this._dataProcessorHandlers,t,e,{block:!0})},nc.performVisualTasks=function(t,e,n){ic(this,this._visualHandlers,t,e,n)},nc.performSeriesTasks=function(t){var e;t.eachSeries(function(t){e|=t.dataTask.perform()}),this.unfinished|=e},nc.plan=function(){this._pipelineMap.each(function(t){var e=t.tail;do{if(e.__block){t.blockIndex=e.__idxInPipeline;break}e=e.getUpstream()}while(e)})};var rc=nc.updatePayload=function(t,e){"remain"!==e&&(t.context.payload=e)};function ac(t){t.overallReset(t.ecModel,t.api,t.payload)}function oc(t,e){return t.overallProgress&&sc}function sc(){this.agent.dirty(),this.getDownstream().dirty()}function lc(){this.agent&&this.agent.dirty()}function hc(t){return t.plan&&t.plan(t.model,t.ecModel,t.api,t.payload)}function uc(t){t.useClearVisual&&t.data.clearAllVisual();var e=t.resetDefines=gr(t.reset(t.model,t.ecModel,t.api,t.payload));return 1<e.length?D(e,function(t,e){return dc(e)}):cc}var cc=dc(0);function dc(a){return function(t,e){var n=e.data,i=e.resetDefines[a];if(i&&i.dataEach)for(var r=t.start;r<t.end;r++)i.dataEach(n,r);else i&&i.progress&&i.progress(t,n)}}function fc(t){return t.data.count()}function pc(t,e,n){var i=e.uid,r=t._pipelineMap.get(i);r.head||(r.head=n),r.tail&&r.tail.pipe(n),(r.tail=n).__idxInPipeline=r.count++,n.__pipeline=r}ec.wrapStageHandler=function(t,e){return z(t)&&(t={overallReset:t,seriesType:function(t){gc=null;try{t(mc,vc)}catch(t){}return gc}(t)}),t.uid=il("stageHandler"),e&&(t.visualType=e),t};var gc,mc={},vc={};function yc(t,e){for(var n in e.prototype)t[n]=J}yc(mc,xh),yc(vc,Mh),mc.eachSeriesByType=mc.eachRawSeriesByType=function(t){gc=t},mc.eachComponent=function(t){"series"===t.mainType&&t.subType&&(gc=t.subType)};function _c(){return{axisLine:{lineStyle:{color:bc}},axisTick:{lineStyle:{color:bc}},axisLabel:{textStyle:{color:bc}},splitLine:{lineStyle:{type:"dashed",color:"#aaa"}},splitArea:{areaStyle:{color:bc}}}}var xc=["#37A2DA","#32C5E9","#67E0E3","#9FE6B8","#FFDB5C","#ff9f7f","#fb7293","#E062AE","#E690D1","#e7bcf3","#9d96f5","#8378EA","#96BFFF"],wc={color:xc,colorLayer:[["#37A2DA","#ffd85c","#fd7b5f"],["#37A2DA","#67E0E3","#FFDB5C","#ff9f7f","#E062AE","#9d96f5"],["#37A2DA","#32C5E9","#9FE6B8","#FFDB5C","#ff9f7f","#fb7293","#e7bcf3","#8378EA","#96BFFF"],xc]},bc="#eee",Sc=["#dd6b66","#759aa0","#e69d87","#8dc1a9","#ea7e53","#eedd78","#73a373","#73b9bc","#7289ab","#91ca8c","#f49f42"],Mc={color:Sc,backgroundColor:"#333",tooltip:{axisPointer:{lineStyle:{color:bc},crossStyle:{color:bc}}},legend:{textStyle:{color:bc}},textStyle:{color:bc},title:{textStyle:{color:bc}},toolbox:{iconStyle:{normal:{borderColor:bc}}},dataZoom:{textStyle:{color:bc}},visualMap:{textStyle:{color:bc}},timeline:{lineStyle:{color:bc},itemStyle:{normal:{color:Sc[1]}},label:{normal:{textStyle:{color:bc}}},controlStyle:{normal:{color:bc,borderColor:bc}}},timeAxis:_c(),logAxis:_c(),valueAxis:_c(),categoryAxis:_c(),line:{symbol:"circle"},graph:{color:Sc},gauge:{title:{textStyle:{color:bc}}},candlestick:{itemStyle:{normal:{color:"#FD1050",color0:"#0CF49B",borderColor:"#FD1050",borderColor0:"#0CF49B"}}}};Mc.categoryAxis.splitLine.show=!1,$l.extend({type:"dataset",defaultOption:{seriesLayoutBy:ch,sourceHeader:null,dimensions:null,source:null},optionUpdated:function(){!function(t){var e=t.option.source,n=hh;if(B(e))n=uh;else if(O(e)){0===e.length&&(n=oh);for(var i=0,r=e.length;i<r;i++){var a=e[i];if(null!=a){if(O(a)){n=oh;break}if(N(a)){n=sh;break}}}}else if(N(e)){for(var o in e)if(e.hasOwnProperty(o)&&L(e[o])){n=lh;break}}else if(null!=e)throw new Error("Invalid data");ph(t).sourceFormat=n}(this)}}),Ou.extend({type:"dataset"});var Ic=no.extend({type:"ellipse",shape:{cx:0,cy:0,rx:0,ry:0},buildPath:function(t,e){var n=e.cx,i=e.cy,r=e.rx,a=e.ry,o=.5522848*r,s=.5522848*a;t.moveTo(n-r,i),t.bezierCurveTo(n-r,i-s,n-o,i-a,n,i-a),t.bezierCurveTo(n+o,i-a,n+r,i-s,n+r,i),t.bezierCurveTo(n+r,i+s,n+o,i+a,n,i+a),t.bezierCurveTo(n-o,i+a,n-r,i+s,n-r,i),t.closePath()}}),Cc=/[\s,]+/;function Tc(t){E(t)&&(t=(new DOMParser).parseFromString(t,"text/xml"));for(9===t.nodeType&&(t=t.firstChild);"svg"!==t.nodeName.toLowerCase()||1!==t.nodeType;)t=t.nextSibling;return t}var Ac={g:function(t,e){var n=new yn;return kc(e,n),Oc(t,n,this._defs),n},rect:function(t,e){var n=new No;return kc(e,n),Oc(t,n,this._defs),n.setShape({x:parseFloat(t.getAttribute("x")||0),y:parseFloat(t.getAttribute("y")||0),width:parseFloat(t.getAttribute("width")||0),height:parseFloat(t.getAttribute("height")||0)}),n},circle:function(t,e){var n=new So;return kc(e,n),Oc(t,n,this._defs),n.setShape({cx:parseFloat(t.getAttribute("cx")||0),cy:parseFloat(t.getAttribute("cy")||0),r:parseFloat(t.getAttribute("r")||0)}),n},line:function(t,e){var n=new Bo;return kc(e,n),Oc(t,n,this._defs),n.setShape({x1:parseFloat(t.getAttribute("x1")||0),y1:parseFloat(t.getAttribute("y1")||0),x2:parseFloat(t.getAttribute("x2")||0),y2:parseFloat(t.getAttribute("y2")||0)}),n},ellipse:function(t,e){var n=new Ic;return kc(e,n),Oc(t,n,this._defs),n.setShape({cx:parseFloat(t.getAttribute("cx")||0),cy:parseFloat(t.getAttribute("cy")||0),rx:parseFloat(t.getAttribute("rx")||0),ry:parseFloat(t.getAttribute("ry")||0)}),n},polygon:function(t,e){var n=t.getAttribute("points");n=n&&Pc(n);var i=new Do({shape:{points:n||[]}});return kc(e,i),Oc(t,i,this._defs),i},polyline:function(t,e){var n=new no;kc(e,n),Oc(t,n,this._defs);var i=t.getAttribute("points");return i=i&&Pc(i),new ko({shape:{points:i||[]}})},image:function(t,e){var n=new Hi;return kc(e,n),Oc(t,n,this._defs),n.setStyle({image:t.getAttribute("xlink:href"),x:t.getAttribute("x"),y:t.getAttribute("y"),width:t.getAttribute("width"),height:t.getAttribute("height")}),n},text:function(t,e){var n=t.getAttribute("x")||0,i=t.getAttribute("y")||0,r=t.getAttribute("dx")||0,a=t.getAttribute("dy")||0;this._textX=parseFloat(n)+parseFloat(r),this._textY=parseFloat(i)+parseFloat(a);var o=new yn;return kc(e,o),Oc(t,o,this._defs),o},tspan:function(t,e){var n=t.getAttribute("x"),i=t.getAttribute("y");null!=n&&(this._textX=parseFloat(n)),null!=i&&(this._textY=parseFloat(i));var r=t.getAttribute("dx")||0,a=t.getAttribute("dy")||0,o=new yn;return kc(e,o),Oc(t,o,this._defs),this._textX+=r,this._textY+=a,o},path:function(t,e){var n=xo(t.getAttribute("d")||"");return kc(e,n),Oc(t,n,this._defs),n}},Dc={lineargradient:function(t){var e=parseInt(t.getAttribute("x1")||0,10),n=parseInt(t.getAttribute("y1")||0,10),i=parseInt(t.getAttribute("x2")||10,10),r=parseInt(t.getAttribute("y2")||0,10),a=new Uo(e,n,i,r);return function(t,e){var n=t.firstChild;for(;n;){if(1===n.nodeType){var i=n.getAttribute("offset");i=0<i.indexOf("%")?parseInt(i,10)/100:i?parseFloat(i):0;var r=n.getAttribute("stop-color")||"#000000";e.addColorStop(i,r)}n=n.nextSibling}}(t,a),a},radialgradient:function(t){}};function kc(t,e){t&&t.__inheritedStyle&&(e.__inheritedStyle||(e.__inheritedStyle={}),T(e.__inheritedStyle,t.__inheritedStyle))}function Pc(t){for(var e=Y(t).split(Cc),n=[],i=0;i<e.length;i+=2){var r=parseFloat(e[i]),a=parseFloat(e[i+1]);n.push([r,a])}return n}var Lc={fill:"fill",stroke:"stroke","stroke-width":"lineWidth",opacity:"opacity","fill-opacity":"fillOpacity","stroke-opacity":"strokeOpacity","stroke-dasharray":"lineDash","stroke-dashoffset":"lineDashOffset","stroke-linecap":"lineCap","stroke-linejoin":"lineJoin","stroke-miterlimit":"miterLimit","font-family":"fontFamily","font-size":"fontSize","font-style":"fontStyle","font-weight":"fontWeight","text-align":"textAlign","alignment-baseline":"textBaseline"};function Oc(t,e,n,i){var r=e.__inheritedStyle||{},a="text"===e.type;if(1===t.nodeType&&(function(t,e){var n=t.getAttribute("transform");if(n){n=n.replace(/,/g," ");var i=null,r=[];n.replace(Nc,function(t,e,n){r.push(e,n)});for(var a=r.length-1;0<a;a-=2){var o=r[a],s=r[a-1];switch(i=i||qt(),s){case"translate":o=Y(o).split(Cc),Jt(i,i,[parseFloat(o[0]),parseFloat(o[1]||0)]);break;case"scale":o=Y(o).split(Cc),ee(i,i,[parseFloat(o[0]),parseFloat(o[1]||o[0])]);break;case"rotate":o=Y(o).split(Cc),te(i,i,parseFloat(o[0]));break;case"skew":o=Y(o).split(Cc),console.warn("Skew transform is not supported yet");break;case"matrix":o=Y(o).split(Cc);i[0]=parseFloat(o[0]),i[1]=parseFloat(o[1]),i[2]=parseFloat(o[2]),i[3]=parseFloat(o[3]),i[4]=parseFloat(o[4]),i[5]=parseFloat(o[5])}}e.setLocalTransform(i)}}(t,e),I(r,function(t){var e=t.getAttribute("style"),n={};if(!e)return n;var i,r={};Rc.lastIndex=0;for(;null!=(i=Rc.exec(e));)r[i[1]]=i[2];for(var a in Lc)Lc.hasOwnProperty(a)&&null!=r[a]&&(n[Lc[a]]=r[a]);return n}(t)),!i))for(var o in Lc)if(Lc.hasOwnProperty(o)){var s=t.getAttribute(o);null!=s&&(r[Lc[o]]=s)}var l=a?"textFill":"fill",h=a?"textStroke":"stroke";e.style=e.style||new zn;var u=e.style;null!=r.fill&&u.set(l,Ec(r.fill,n)),null!=r.stroke&&u.set(h,Ec(r.stroke,n)),A(["lineWidth","opacity","fillOpacity","strokeOpacity","miterLimit","fontSize"],function(t){var e="lineWidth"===t&&a?"textStrokeWidth":t;null!=r[t]&&u.set(e,parseFloat(r[t]))}),r.textBaseline&&"auto"!==r.textBaseline||(r.textBaseline="alphabetic"),"alphabetic"===r.textBaseline&&(r.textBaseline="bottom"),"start"===r.textAlign&&(r.textAlign="left"),"end"===r.textAlign&&(r.textAlign="right"),A(["lineDashOffset","lineCap","lineJoin","fontWeight","fontFamily","fontStyle","textAlign","textBaseline"],function(t){null!=r[t]&&u.set(t,r[t])}),r.lineDash&&(e.style.lineDash=Y(r.lineDash).split(Cc)),u[h]&&"none"!==u[h]&&(e[h]=!0),e.__inheritedStyle=r}var zc=/url\(\s*#(.*?)\)/;function Ec(t,e){var n=e&&t&&t.match(zc);return n?e[Y(n[1])]:t}var Nc=/(translate|scale|rotate|skewX|skewY|matrix)\(([\-\s0-9\.e,]*)\)/g;var Rc=/([^\s:;]+)\s*:\s*([^:;]+)/g;var Bc=Q(),Fc=function(t,e,n){var i;return A(i=O(e)?e:e.svg?[{type:"svg",source:e.svg,specialAreas:e.specialAreas}]:(e.geoJson&&!e.features&&(n=e.specialAreas,e=e.geoJson),[{type:"geoJSON",source:e,specialAreas:n}]),function(t){var e=t.type;"geoJson"===e&&(e=t.type="geoJSON"),(0,Hc[e])(t)}),Bc.set(t,i)},Vc=function(t){return Bc.get(t)},Hc={geoJSON:function(t){var e=t.source;t.geoJSON=E(e)?"undefined"!=typeof JSON&&JSON.parse?JSON.parse(e):new Function("return ("+e+");")():e},svg:function(t){t.svgXML=Tc(t.source)}},Wc=X,Gc=A,Zc=z,Uc=N,Xc=$l.parseClassType,Yc={PROCESSOR:{FILTER:1e3,STATISTIC:5e3},VISUAL:{LAYOUT:1e3,PROGRESSIVE_LAYOUT:1100,GLOBAL:2e3,CHART:3e3,POST_CHART_LAYOUT:3500,COMPONENT:4e3,BRUSH:5e3}},jc="__flagInMainProcess",qc="__optionUpdated",$c=/^[a-zA-Z0-9_]+$/;function Kc(i){return function(t,e,n){t=t&&t.toLowerCase(),It.prototype[i].call(this,t,e,n)}}function Qc(){It.call(this)}function Jc(t,e,n){n=n||{},"string"==typeof e&&(e=Sd[e]),this.id,this.group,this._dom=t;var i=this._zr=sr(t,{renderer:n.renderer||"canvas",devicePixelRatio:n.devicePixelRatio,width:n.width,height:n.height});this._throttledZrFlush=ju(k(i.flush,i),17),(e=b(e))&&jh(e,!0),this._theme=e,this._chartsViews=[],this._chartsMap={},this._componentsViews=[],this._componentsMap={},this._coordSysMgr=new Ch;var r=this._api=function(n){var t=n._coordSysMgr;return I(new Mh(n),{getCoordinateSystems:k(t.getCoordinateSystems,t),getComponentByElement:function(t){for(;t;){var e=t.__ecComponentInfo;if(null!=e)return n._model.getComponent(e.mainType,e.index);t=t.parent}}})}(this);function a(t,e){return t.__prio-e.__prio}Cn(bd,a),Cn(_d,a),this._scheduler=new ec(this,r,_d,bd),It.call(this,this._ecEventProcessor=new md),this._messageCenter=new Qc,this._initEvents(),this.resize=k(this.resize,this),this._pendingActions=[],i.animation.on("frame",this._onframe,this),function(t,e){t.on("rendered",function(){e.trigger("rendered"),!t.animation.isFinished()||e[qc]||e._scheduler.unfinished||e._pendingActions.length||e.trigger("finished")})}(i,this),q(this)}Qc.prototype.on=Kc("on"),Qc.prototype.off=Kc("off"),Qc.prototype.one=Kc("one"),S(Qc,It);var td=Jc.prototype;function ed(t,e,n){var i,r=this._model,a=this._coordSysMgr.getCoordinateSystems();e=Cr(r,e);for(var o=0;o<a.length;o++){var s=a[o];if(s[t]&&null!=(i=s[t](r,e,n)))return i}}td._onframe=function(){if(!this._disposed){var t=this._scheduler;if(this[qc]){var e=this[qc].silent;this[jc]=!0,id(this),nd.update.call(this),this[jc]=!1,this[qc]=!1,sd.call(this,e),ld.call(this,e)}else if(t.unfinished){var n=1,i=this._model,r=this._api;t.unfinished=!1;do{var a=+new Date;t.performSeriesTasks(i),t.performDataProcessorTasks(i),ad(this,i),t.performVisualTasks(i),dd(this,this._model,r,"remain"),n-=+new Date-a}while(0<n&&t.unfinished);t.unfinished||this._zr.flush()}}},td.getDom=function(){return this._dom},td.getZr=function(){return this._zr},td.setOption=function(t,e,n){var i;if(Uc(e)&&(n=e.lazyUpdate,i=e.silent,e=e.notMerge),this[jc]=!0,!this._model||e){var r=new Lh(this._api),a=this._theme,o=this._model=new xh;o.scheduler=this._scheduler,o.init(null,null,a,r)}this._model.setOption(t,xd),n?(this[qc]={silent:i},this[jc]=!1):(id(this),nd.update.call(this),this._zr.flush(),this[qc]=!1,this[jc]=!1,sd.call(this,i),ld.call(this,i))},td.setTheme=function(){console.error("ECharts#setTheme() is DEPRECATED in ECharts 3.0")},td.getModel=function(){return this._model},td.getOption=function(){return this._model&&this._model.getOption()},td.getWidth=function(){return this._zr.getWidth()},td.getHeight=function(){return this._zr.getHeight()},td.getDevicePixelRatio=function(){return this._zr.painter.dpr||window.devicePixelRatio||1},td.getRenderedCanvas=function(t){if(v.canvasSupported)return(t=t||{}).pixelRatio=t.pixelRatio||1,t.backgroundColor=t.backgroundColor||this._model.get("backgroundColor"),this._zr.painter.getRenderedCanvas(t)},td.getSvgDataUrl=function(){if(v.svgSupported){var t=this._zr;return A(t.storage.getDisplayList(),function(t){t.stopAnimation(!0)}),t.painter.pathToDataUrl()}},td.getDataURL=function(t){var e=(t=t||{}).excludeComponents,n=this._model,i=[],r=this;Gc(e,function(t){n.eachComponent({mainType:t},function(t){var e=r._componentsMap[t.__viewId];e.group.ignore||(i.push(e),e.group.ignore=!0)})});var a="svg"===this._zr.painter.getType()?this.getSvgDataUrl():this.getRenderedCanvas(t).toDataURL("image/"+(t&&t.type||"png"));return Gc(i,function(t){t.group.ignore=!1}),a},td.getConnectedDataURL=function(r){if(v.canvasSupported){var a=this.group,o=Math.min,s=Math.max;if(Cd[a]){var l=1/0,h=1/0,u=-1/0,c=-1/0,d=[],n=r&&r.pixelRatio||1;A(Id,function(t,e){if(t.group===a){var n=t.getRenderedCanvas(b(r)),i=t.getDom().getBoundingClientRect();l=o(i.left,l),h=o(i.top,h),u=s(i.right,u),c=s(i.bottom,c),d.push({dom:n,left:i.left,top:i.top})}});var t=(u*=n)-(l*=n),e=(c*=n)-(h*=n),i=g();i.width=t,i.height=e;var f=sr(i);return r.connectedBackgroundColor&&f.add(new No({shape:{x:0,y:0,width:t,height:e},style:{fill:r.connectedBackgroundColor}})),Gc(d,function(t){var e=new Hi({style:{x:t.left*n-l,y:t.top*n-h,image:t.dom}});f.add(e)}),f.refreshImmediately(),i.toDataURL("image/"+(r&&r.type||"png"))}return this.getDataURL(r)}},td.convertToPixel=P(ed,"convertToPixel"),td.convertFromPixel=P(ed,"convertFromPixel"),td.containPixel=function(t,r){var a;return A(t=Cr(this._model,t),function(t,i){0<=i.indexOf("Models")&&A(t,function(t){var e=t.coordinateSystem;if(e&&e.containPoint)a|=!!e.containPoint(r);else if("seriesModels"===i){var n=this._chartsMap[t.__viewId];n&&n.containPoint&&(a|=n.containPoint(r,t))}},this)},this),!!a},td.getVisual=function(t,e){var n=(t=Cr(this._model,t,{defaultMainType:"series"})).seriesModel.getData(),i=t.hasOwnProperty("dataIndexInside")?t.dataIndexInside:t.hasOwnProperty("dataIndex")?n.indexOfRawIndex(t.dataIndex):null;return null!=i?n.getItemVisual(i,e):n.getVisual(e)},td.getViewOfComponentModel=function(t){return this._componentsMap[t.__viewId]},td.getViewOfSeriesModel=function(t){return this._chartsMap[t.__viewId]};var nd={prepareAndUpdate:function(t){id(this),nd.update.call(this,t)},update:function(t){var e=this._model,n=this._api,i=this._zr,r=this._coordSysMgr,a=this._scheduler;if(e){a.restoreData(e,t),a.performSeriesTasks(e),r.create(e,n),a.performDataProcessorTasks(e,t),ad(this,e),r.update(e,n),ud(e),a.performVisualTasks(e,t),cd(this,e,n,t);var o=e.get("backgroundColor")||"transparent";if(v.canvasSupported)i.setBackgroundColor(o);else{var s=ke(o);o=Fe(s,"rgb"),0===s[3]&&(o="transparent")}fd(e,n)}},updateTransform:function(r){var a=this._model,o=this,s=this._api;if(a){var l=[];a.eachComponent(function(t,e){var n=o.getViewOfComponentModel(e);if(n&&n.__alive)if(n.updateTransform){var i=n.updateTransform(e,a,s,r);i&&i.update&&l.push(n)}else l.push(n)});var i=Q();a.eachSeries(function(t){var e=o._chartsMap[t.__viewId];if(e.updateTransform){var n=e.updateTransform(t,a,s,r);n&&n.update&&i.set(t.uid,1)}else i.set(t.uid,1)}),ud(a),this._scheduler.performVisualTasks(a,r,{setDirty:!0,dirtyMap:i}),dd(o,a,s,r,i),fd(a,this._api)}},updateView:function(t){var e=this._model;e&&(Bu.markUpdateMethod(t,"updateView"),ud(e),this._scheduler.performVisualTasks(e,t,{setDirty:!0}),cd(this,this._model,this._api,t),fd(e,this._api))},updateVisual:function(t){nd.update.call(this,t)},updateLayout:function(t){nd.update.call(this,t)}};function id(t){var e=t._model,n=t._scheduler;n.restorePipelines(e),n.prepareStageTasks(),hd(t,"component",e,n),hd(t,"chart",e,n),n.plan()}function rd(e,n,i,r,t){var a=e._model;if(r){var o={};o[r+"Id"]=i[r+"Id"],o[r+"Index"]=i[r+"Index"],o[r+"Name"]=i[r+"Name"];var s={mainType:r,query:o};t&&(s.subType=t);var l=i.excludeSeriesId;null!=l&&(l=Q(gr(l))),a&&a.eachComponent(s,function(t){l&&null!=l.get(t.id)||h(e["series"===r?"_chartsMap":"_componentsMap"][t.__viewId])},e)}else Gc(e._componentsViews.concat(e._chartsViews),h);function h(t){t&&t.__alive&&t[n]&&t[n](t.__model,a,e._api,i)}}function ad(t,e){var n=t._chartsMap,i=t._scheduler;e.eachSeries(function(t){i.updateStreamModes(t,n[t.__viewId])})}function od(e,t){var n=e.type,i=e.escapeConnect,r=vd[n],a=r.actionInfo,o=(a.update||"update").split(":"),s=o.pop();o=null!=o[0]&&Xc(o[0]),this[jc]=!0;var l=[e],h=!1;e.batch&&(h=!0,l=D(e.batch,function(t){return(t=T(I({},t),e)).batch=null,t}));var u,c=[],d="highlight"===n||"downplay"===n;Gc(l,function(t){(u=(u=r.action(t,this._model,this._api))||I({},t)).type=a.event||u.type,c.push(u),d?rd(this,s,t,"series"):o&&rd(this,s,t,o.main,o.sub)},this),"none"===s||d||o||(this[qc]?(id(this),nd.update.call(this,e),this[qc]=!1):nd[s].call(this,e)),u=h?{type:a.event||n,escapeConnect:i,batch:c}:c[0],this[jc]=!1,t||this._messageCenter.trigger(u.type,u)}function sd(t){for(var e=this._pendingActions;e.length;){var n=e.shift();od.call(this,n,t)}}function ld(t){t||this.trigger("updated")}function hd(t,e,r,a){for(var o="component"===e,s=o?t._componentsViews:t._chartsViews,l=o?t._componentsMap:t._chartsMap,h=t._zr,u=t._api,n=0;n<s.length;n++)s[n].__alive=!1;function i(t){var e="_ec_"+t.id+"_"+t.type,n=l[e];if(!n){var i=Xc(t.type);(n=new(o?Ou.getClass(i.main,i.sub):Bu.getClass(i.sub))).init(r,u),l[e]=n,s.push(n),h.add(n.group)}t.__viewId=n.__id=e,n.__alive=!0,n.__model=t,n.group.__ecComponentInfo={mainType:t.mainType,index:t.componentIndex},o||a.prepareView(n,t,r,u)}o?r.eachComponent(function(t,e){"series"!==t&&i(e)}):r.eachSeries(i);for(n=0;n<s.length;){var c=s[n];c.__alive?n++:(o||c.renderTask.dispose(),h.remove(c.group),c.dispose(r,u),s.splice(n,1),delete l[c.__id],c.__id=c.group.__ecComponentInfo=null)}}function ud(t){t.clearColorPalette(),t.eachSeries(function(t){t.clearColorPalette()})}function cd(t,e,n,i){!function(t,n,i,r,e){Gc(e||t._componentsViews,function(t){var e=t.__model;t.render(e,n,i,r),gd(e,t)})}(t,e,n,i),Gc(t._chartsViews,function(t){t.__alive=!1}),dd(t,e,n,i),Gc(t._chartsViews,function(t){t.__alive||t.remove(e,n)})}function dd(i,t,e,r,a){var o,s=i._scheduler;t.eachSeries(function(t){var e=i._chartsMap[t.__viewId];e.__alive=!0;var n=e.renderTask;s.updatePayload(n,r),a&&a.get(t.uid)&&n.dirty(),o|=n.perform(s.getPerformArgs(n)),e.group.silent=!!t.get("silent"),gd(t,e),function(t,e){var n=t.get("blendMode")||null;e.group.traverse(function(t){t.isGroup||t.style.blend!==n&&t.setStyle("blend",n),t.eachPendingDisplayable&&t.eachPendingDisplayable(function(t){t.setStyle("blend",n)})})}(t,e)}),s.unfinished|=o,function(n,t){var e=n._zr.storage,i=0;e.traverse(function(t){i++}),i>t.get("hoverLayerThreshold")&&!v.node&&t.eachSeries(function(t){if(!t.preventUsingHoverLayer){var e=n._chartsMap[t.__viewId];e.__alive&&e.group.traverse(function(t){t.useHoverLayer=!0})}})}(i,t),Ju(i._zr.dom,t)}function fd(e,n){Gc(wd,function(t){t(e,n)})}td.resize=function(t){this._zr.resize(t);var e=this._model;if(this._loadingFX&&this._loadingFX.resize(),e){var n=e.resetOption("media"),i=t&&t.silent;this[jc]=!0,n&&id(this),nd.update.call(this),this[jc]=!1,sd.call(this,i),ld.call(this,i)}},td.showLoading=function(t,e){if(Uc(t)&&(e=t,t=""),t=t||"default",this.hideLoading(),Md[t]){var n=Md[t](this._api,e),i=this._zr;this._loadingFX=n,i.add(n)}},td.hideLoading=function(){this._loadingFX&&this._zr.remove(this._loadingFX),this._loadingFX=null},td.makeActionFromEvent=function(t){var e=I({},t);return e.type=yd[t.type],e},td.dispatchAction=function(t,e){Uc(e)||(e={silent:!!e}),vd[t.type]&&this._model&&(this[jc]?this._pendingActions.push(t):(od.call(this,t,e.silent),e.flush?this._zr.flush(!0):!1!==e.flush&&v.browser.weChat&&this._throttledZrFlush(),sd.call(this,e.silent),ld.call(this,e.silent)))},td.appendData=function(t){var e=t.seriesIndex;this.getModel().getSeriesByIndex(e).appendData(t),this._scheduler.unfinished=!0},td.on=Kc("on"),td.off=Kc("off"),td.one=Kc("one");var pd=["click","dblclick","mouseover","mouseout","mousemove","mousedown","mouseup","globalout","contextmenu"];function gd(t,e){var n=t.get("z"),i=t.get("zlevel");e.group.traverse(function(t){"group"!==t.type&&(null!=n&&(t.z=n),null!=i&&(t.zlevel=i))})}function md(){this.eventInfo}td._initEvents=function(){Gc(pd,function(h){function t(t){var e,n=this.getModel(),i=t.target;if("globalout"===h)e={};else if(i&&null!=i.dataIndex){var r=i.dataModel||n.getSeriesByIndex(i.seriesIndex);e=r&&r.getDataParams(i.dataIndex,i.dataType,i)||{}}else i&&i.eventData&&(e=I({},i.eventData));if(e){var a=e.componentType,o=e.componentIndex;"markLine"!==a&&"markPoint"!==a&&"markArea"!==a||(a="series",o=e.seriesIndex);var s=a&&null!=o&&n.getComponent(a,o),l=s&&this["series"===s.mainType?"_chartsMap":"_componentsMap"][s.__viewId];e.event=t,e.type=h,this._ecEventProcessor.eventInfo={targetEl:i,packedEvent:e,model:s,view:l},this.trigger(h,e)}}t.zrEventfulCallAtLast=!0,this._zr.on(h,t,this)},this),Gc(yd,function(t,e){this._messageCenter.on(e,function(t){this.trigger(e,t)},this)},this)},td.isDisposed=function(){return this._disposed},td.clear=function(){this.setOption({series:[]},!0)},td.dispose=function(){if(!this._disposed){this._disposed=!0,Ar(this.getDom(),Dd,"");var e=this._api,n=this._model;Gc(this._componentsViews,function(t){t.dispose(n,e)}),Gc(this._chartsViews,function(t){t.dispose(n,e)}),this._zr.dispose(),delete Id[this.id]}},S(Jc,It),md.prototype={constructor:md,normalizeQuery:function(t){var s={},l={},h={};if(E(t)){var e=Xc(t);s.mainType=e.main||null,s.subType=e.sub||null}else{var u=["Index","Name","Id"],c={name:1,dataIndex:1,dataType:1};A(t,function(t,e){for(var n=!1,i=0;i<u.length;i++){var r=u[i],a=e.lastIndexOf(r);if(0<a&&a===e.length-r.length){var o=e.slice(0,a);"data"!==o&&(s.mainType=o,s[r.toLowerCase()]=t,n=!0)}}c.hasOwnProperty(e)&&(l[e]=t,n=!0),n||(h[e]=t)})}return{cptQuery:s,dataQuery:l,otherQuery:h}},filter:function(t,e,n){var i=this.eventInfo;if(!i)return!0;var r=i.targetEl,a=i.packedEvent,o=i.model,s=i.view;if(!o||!s)return!0;var l=e.cptQuery,h=e.dataQuery;return u(l,o,"mainType")&&u(l,o,"subType")&&u(l,o,"index","componentIndex")&&u(l,o,"name")&&u(l,o,"id")&&u(h,a,"name")&&u(h,a,"dataIndex")&&u(h,a,"dataType")&&(!s.filterForExposedEvent||s.filterForExposedEvent(t,e.otherQuery,r,a));function u(t,e,n,i){return null==t[n]||e[i||n]===t[n]}},afterTrigger:function(){this.eventInfo=null}};var vd={},yd={},_d=[],xd=[],wd=[],bd=[],Sd={},Md={},Id={},Cd={},Td=new Date-0,Ad=new Date-0,Dd="_echarts_instance_";function kd(t){Cd[t]=!1}var Pd=kd;function Ld(t){return Id[function(t,e){return t.getAttribute?t.getAttribute(e):t[e]}(t,Dd)]}function Od(t,e){Sd[t]=e}function zd(t){xd.push(t)}function Ed(t,e){Fd(_d,t,e,1e3)}function Nd(t,e,n){"function"==typeof e&&(n=e,e="");var i=Uc(t)?t.type:[t,t={event:e}][0];t.event=(t.event||i).toLowerCase(),e=t.event,Wc($c.test(i)&&$c.test(e)),vd[i]||(vd[i]={action:n,actionInfo:t}),yd[e]=i}function Rd(t,e){Fd(bd,t,e,1e3,"layout")}function Bd(t,e){Fd(bd,t,e,3e3,"visual")}function Fd(t,e,n,i,r){(Zc(e)||Uc(e))&&(n=e,e=i);var a=ec.wrapStageHandler(n,r);return a.__prio=e,a.__raw=n,t.push(a),a}function Vd(t,e){Md[t]=e}function Hd(t){return $l.extend(t)}function Wd(t){return Ou.extend(t)}function Gd(t){return Iu.extend(t)}function Zd(t){return Bu.extend(t)}Bd(2e3,Ku),zd(jh),Ed(5e3,function(t){var a=Q();t.eachSeries(function(t){var e=t.get("stack");if(e){var n=a.get(e)||a.set(e,[]),i=t.getData(),r={stackResultDimension:i.getCalculationInfo("stackResultDimension"),stackedOverDimension:i.getCalculationInfo("stackedOverDimension"),stackedDimension:i.getCalculationInfo("stackedDimension"),stackedByDimension:i.getCalculationInfo("stackedByDimension"),isStackedByIndex:i.getCalculationInfo("isStackedByIndex"),data:i,seriesModel:t};if(!r.stackedDimension||!r.isStackedByIndex&&!r.stackedByDimension)return;n.length&&i.setCalculationInfo("stackedOnSeries",n[n.length-1].seriesModel),n.push(r)}}),a.each(qh)}),Vd("default",function(i,t){T(t=t||{},{text:"loading",color:"#c23531",textColor:"#000",maskColor:"rgba(255, 255, 255, 0.8)",zlevel:0});var r=new No({style:{fill:t.maskColor},zlevel:t.zlevel,z:1e4}),a=new Go({shape:{startAngle:-tc/2,endAngle:-tc/2+.1,r:10},style:{stroke:t.color,lineCap:"round",lineWidth:5},zlevel:t.zlevel,z:10001}),o=new No({style:{fill:"none",text:t.text,textPosition:"right",textDistance:10,textFill:t.textColor},zlevel:t.zlevel,z:10001});a.animateShape(!0).when(1e3,{endAngle:3*tc/2}).start("circularInOut"),a.animateShape(!0).when(1e3,{startAngle:3*tc/2}).delay(300).start("circularInOut");var e=new yn;return e.add(a),e.add(o),e.add(r),e.resize=function(){var t=i.getWidth()/2,e=i.getHeight()/2;a.setShape({cx:t,cy:e});var n=a.shape.r;o.setShape({x:t-n,y:e-n,width:2*n,height:2*n}),r.setShape({x:0,y:0,width:i.getWidth(),height:i.getHeight()})},e.resize(),e}),Nd({type:"highlight",event:"highlight",update:"highlight"},J),Nd({type:"downplay",event:"downplay",update:"downplay"},J),Od("light",wc),Od("dark",Mc);function Ud(t){return t}function Xd(t,e,n,i,r){this._old=t,this._new=e,this._oldKeyGetter=n||Ud,this._newKeyGetter=i||Ud,this.context=r}function Yd(t,e,n,i,r){for(var a=0;a<t.length;a++){var o="_ec_"+r[i](t[a],a),s=e[o];null==s?(n.push(o),e[o]=a):(s.length||(e[o]=s=[s]),s.push(a))}}Xd.prototype={constructor:Xd,add:function(t){return this._add=t,this},update:function(t){return this._update=t,this},remove:function(t){return this._remove=t,this},execute:function(){var t=this._old,e=this._new,n={},i=[],r=[];for(Yd(t,{},i,"_oldKeyGetter",this),Yd(e,n,r,"_newKeyGetter",this),a=0;a<t.length;a++){if(null!=(s=n[o=i[a]]))(h=s.length)?(1===h&&(n[o]=null),s=s.unshift()):n[o]=null,this._update&&this._update(s,a);else this._remove&&this._remove(a)}for(var a=0;a<r.length;a++){var o=r[a];if(n.hasOwnProperty(o)){var s;if(null==(s=n[o]))continue;if(s.length)for(var l=0,h=s.length;l<h;l++)this._add&&this._add(s[l]);else this._add&&this._add(s)}}}};var jd=Q(["tooltip","label","itemName","itemId","seriesName"]);function qd(t,e){return t.hasOwnProperty(e)||(t[e]=[]),t[e]}var $d=N,Kd="undefined",Qd={float:typeof Float64Array==Kd?Array:Float64Array,int:typeof Int32Array==Kd?Array:Int32Array,ordinal:Array,number:Array,time:Array},Jd=typeof Uint32Array==Kd?Array:Uint32Array,tf=typeof Int32Array==Kd?Array:Int32Array,ef=typeof Uint16Array==Kd?Array:Uint16Array;function nf(t){return 65535<t._rawCount?Jd:ef}var rf=["hasItemOption","_nameList","_idList","_invertedIndicesMap","_rawData","_chunkSize","_chunkCount","_dimValueGetter","_count","_rawCount","_nameDimIdx","_idDimIdx"],af=["_extent","_approximateExtent","_rawExtent"];function of(e,n){A(rf.concat(n.__wrappedMethods||[]),function(t){n.hasOwnProperty(t)&&(e[t]=n[t])}),e.__wrappedMethods=n.__wrappedMethods,A(af,function(t){e[t]=b(n[t])}),e._calculationInfo=I(n._calculationInfo)}var sf=function(t,e){t=t||["x","y"];for(var n={},i=[],r={},a=0;a<t.length;a++){var o=t[a];E(o)&&(o={name:o});var s=o.name;o.type=o.type||"float",o.coordDim||(o.coordDim=s,o.coordDimIndex=0),o.otherDims=o.otherDims||{},i.push(s),(n[s]=o).index=a,o.createInvertedIndices&&(r[s]=[])}this.dimensions=i,this._dimensionInfos=n,this.hostModel=e,this.dataType,this._indices=null,this._count=0,this._rawCount=0,this._storage={},this._nameList=[],this._idList=[],this._optionModels=[],this._visual={},this._layout={},this._itemVisuals=[],this.hasItemVisual={},this._itemLayouts=[],this._graphicEls=[],this._chunkSize=1e5,this._chunkCount=0,this._rawData,this._rawExtent={},this._extent={},this._approximateExtent={},this._dimensionsSummary=function(i){var t={},a=t.encode={},o=Q(),s=[],l=[],h=t.userOutput={dimensionNames:i.dimensions.slice(),encode:{}};A(i.dimensions,function(t){var r=i.getDimensionInfo(t),e=r.coordDim;if(e){var n=r.coordDimIndex;qd(a,e)[n]=t,r.isExtraCoord||(o.set(e,1),function(t){return!("ordinal"===t||"time"===t)}(r.type)&&(s[0]=t),qd(h.encode,e)[n]=r.index),r.defaultTooltip&&l.push(t)}jd.each(function(t,e){var n=qd(a,e),i=r.otherDims[e];null!=i&&!1!==i&&(n[i]=r.name)})});var r=[],u={};o.each(function(t,e){var n=a[e];u[e]=n[0],r=r.concat(n)}),t.dataDimsOnCoord=r,t.encodeFirstDimNotExtra=u;var e=a.label;e&&e.length&&(s=e.slice());var n=a.tooltip;return n&&n.length?l=n.slice():l.length||(l=s.slice()),a.defaultedLabel=s,a.defaultedTooltip=l,t}(this),this._invertedIndicesMap=r,this._calculationInfo={},this.userOutput=this._dimensionsSummary.userOutput},lf=sf.prototype;function hf(t,e,n,i,r){var a=Qd[e.type],o=i-1,s=e.name,l=t[s][o];if(l&&l.length<n){for(var h=new a(Math.min(r-o*n,n)),u=0;u<l.length;u++)h[u]=l[u];t[s][o]=h}for(var c=i*n;c<r;c+=n)t[s].push(new a(Math.min(r-c,n)))}function uf(r){var a=r._invertedIndicesMap;A(a,function(t,e){var n=r._dimensionInfos[e].ordinalMeta;if(n){t=a[e]=new tf(n.categories.length);for(var i=0;i<t.length;i++)t[i]=-1;for(i=0;i<r._count;i++)t[r.get(e,i)]=i}})}function cf(t,e,n){var i;if(null!=e){var r=t._chunkSize,a=Math.floor(n/r),o=n%r,s=t.dimensions[e],l=t._storage[s][a];if(l){i=l[o];var h=t._dimensionInfos[s].ordinalMeta;h&&h.categories.length&&(i=h.categories[i])}}return i}function df(t){return t}function ff(t){return t<this._count&&0<=t?this._indices[t]:-1}function pf(t,e){var n=t._idList[e];return null==n&&(n=cf(t,t._idDimIdx,e)),null==n&&(n="e\0\0"+e),n}function gf(t){return O(t)||(t=[t]),t}function mf(t,e){var n=t.dimensions,i=new sf(D(n,t.getDimensionInfo,t),t.hostModel);of(i,t);for(var r=i._storage={},a=t._storage,o=0;o<n.length;o++){var s=n[o];a[s]&&(0<=x(e,s)?(r[s]=vf(a[s]),i._rawExtent[s]=yf(),i._extent[s]=null):r[s]=a[s])}return i}function vf(t){for(var e,n,i=new Array(t.length),r=0;r<t.length;r++)i[r]=(e=t[r],n=void 0,(n=e.constructor)===Array?e.slice():new n(e));return i}function yf(){return[1/0,-1/0]}lf.type="list",lf.hasItemOption=!0,lf.getDimension=function(t){return"number"!=typeof t&&(isNaN(t)||this._dimensionInfos.hasOwnProperty(t))||(t=this.dimensions[t]),t},lf.getDimensionInfo=function(t){return this._dimensionInfos[this.getDimension(t)]},lf.getDimensionsOnCoord=function(){return this._dimensionsSummary.dataDimsOnCoord.slice()},lf.mapDimension=function(t,e){var n=this._dimensionsSummary;if(null==e)return n.encodeFirstDimNotExtra[t];var i=n.encode[t];return!0===e?(i||[]).slice():i&&i[e]},lf.initData=function(t,e,n){(fh.isInstance(t)||L(t))&&(t=new $h(t,this.dimensions.length)),this._rawData=t,this._storage={},this._indices=null,this._nameList=e||[],this._idList=[],this._nameRepeatCount={},n||(this.hasItemOption=!1),this.defaultDimValueGetter=ru[this._rawData.getSource().sourceFormat],this._dimValueGetter=n=n||this.defaultDimValueGetter,this._dimValueGetterArrayRows=ru.arrayRows,this._rawExtent={},this._initDataFromProvider(0,t.count()),t.pure&&(this.hasItemOption=!1)},lf.getProvider=function(){return this._rawData},lf.appendData=function(t){var e=this._rawData,n=this.count();e.appendData(t);var i=e.count();e.persistent||(i+=n),this._initDataFromProvider(n,i)},lf.appendValues=function(t,e){for(var n=this._chunkSize,i=this._storage,r=this.dimensions,a=r.length,o=this._rawExtent,s=this.count(),l=s+Math.max(t.length,e?e.length:0),h=this._chunkCount,u=0;u<a;u++){o[v=r[u]]||(o[v]=yf()),i[v]||(i[v]=[]),hf(i,this._dimensionInfos[v],n,h,l),this._chunkCount=i[v].length}for(var c=new Array(a),d=s;d<l;d++){for(var f=d-s,p=Math.floor(d/n),g=d%n,m=0;m<a;m++){var v=r[m],y=this._dimValueGetterArrayRows(t[f]||c,v,f,m);i[v][p][g]=y;var _=o[v];y<_[0]&&(_[0]=y),y>_[1]&&(_[1]=y)}e&&(this._nameList[d]=e[f])}this._rawCount=this._count=l,this._extent={},uf(this)},lf._initDataFromProvider=function(t,e){if(!(e<=t)){for(var n,i=this._chunkSize,r=this._rawData,a=this._storage,o=this.dimensions,s=o.length,l=this._dimensionInfos,h=this._nameList,u=this._idList,c=this._rawExtent,d=this._nameRepeatCount={},f=this._chunkCount,p=0;p<s;p++){c[w=o[p]]||(c[w]=yf());var g=l[w];0===g.otherDims.itemName&&(n=this._nameDimIdx=p),0===g.otherDims.itemId&&(this._idDimIdx=p),a[w]||(a[w]=[]),hf(a,g,i,f,e),this._chunkCount=a[w].length}for(var m=new Array(s),v=t;v<e;v++){m=r.getItem(v,m);for(var y=Math.floor(v/i),_=v%i,x=0;x<s;x++){var w,b=a[w=o[x]][y],S=this._dimValueGetter(m,w,v,x);b[_]=S;var M=c[w];S<M[0]&&(M[0]=S),S>M[1]&&(M[1]=S)}if(!r.pure){var I=h[v];if(m&&null==I)if(null!=m.name)h[v]=I=m.name;else if(null!=n){var C=o[n],T=a[C][y];if(T){I=T[_];var A=l[C].ordinalMeta;A&&A.categories.length&&(I=A.categories[I])}}var D=null==m?null:m.id;null==D&&null!=I&&(d[I]=d[I]||0,0<d[D=I]&&(D+="__ec__"+d[I]),d[I]++),null!=D&&(u[v]=D)}}!r.persistent&&r.clean&&r.clean(),this._rawCount=this._count=e,this._extent={},uf(this)}},lf.count=function(){return this._count},lf.getIndices=function(){var t=this._indices;if(t){var e=t.constructor,n=this._count;if(e===Array){r=new e(n);for(var i=0;i<n;i++)r[i]=t[i]}else r=new e(t.buffer,0,n)}else{var r=new(e=nf(this))(this.count());for(i=0;i<r.length;i++)r[i]=i}return r},lf.get=function(t,e){if(!(0<=e&&e<this._count))return NaN;var n=this._storage;if(!n[t])return NaN;e=this.getRawIndex(e);var i=Math.floor(e/this._chunkSize),r=e%this._chunkSize;return n[t][i][r]},lf.getByRawIndex=function(t,e){if(!(0<=e&&e<this._rawCount))return NaN;var n=this._storage[t];if(!n)return NaN;var i=Math.floor(e/this._chunkSize),r=e%this._chunkSize;return n[i][r]},lf._getFast=function(t,e){var n=Math.floor(e/this._chunkSize),i=e%this._chunkSize;return this._storage[t][n][i]},lf.getValues=function(t,e){var n=[];O(t)||(e=t,t=this.dimensions);for(var i=0,r=t.length;i<r;i++)n.push(this.get(t[i],e));return n},lf.hasValue=function(t){for(var e=this._dimensionsSummary.dataDimsOnCoord,n=0,i=e.length;n<i;n++)if(isNaN(this.get(e[n],t)))return!1;return!0},lf.getDataExtent=function(t){t=this.getDimension(t);var e=this._storage[t],n=yf();if(!e)return n;var i,r=this.count();if(!this._indices)return this._rawExtent[t].slice();if(i=this._extent[t])return i.slice();for(var a=(i=n)[0],o=i[1],s=0;s<r;s++){var l=this._getFast(t,this.getRawIndex(s));l<a&&(a=l),o<l&&(o=l)}return i=[a,o],this._extent[t]=i},lf.getApproximateExtent=function(t){return t=this.getDimension(t),this._approximateExtent[t]||this.getDataExtent(t)},lf.setApproximateExtent=function(t,e){e=this.getDimension(e),this._approximateExtent[e]=t.slice()},lf.getCalculationInfo=function(t){return this._calculationInfo[t]},lf.setCalculationInfo=function(t,e){$d(t)?I(this._calculationInfo,t):this._calculationInfo[t]=e},lf.getSum=function(t){var e=0;if(this._storage[t])for(var n=0,i=this.count();n<i;n++){var r=this.get(t,n);isNaN(r)||(e+=r)}return e},lf.getMedian=function(t){var n=[];this.each(t,function(t,e){isNaN(t)||n.push(t)});var e=[].concat(n).sort(function(t,e){return t-e}),i=this.count();return 0===i?0:i%2==1?e[(i-1)/2]:(e[i/2]+e[i/2-1])/2},lf.rawIndexOf=function(t,e){var n=(t&&this._invertedIndicesMap[t])[e];return null==n||isNaN(n)?-1:n},lf.indexOfName=function(t){for(var e=0,n=this.count();e<n;e++)if(this.getName(e)===t)return e;return-1},lf.indexOfRawIndex=function(t){if(!this._indices)return t;if(t>=this._rawCount||t<0)return-1;var e=this._indices,n=e[t];if(null!=n&&n<this._count&&n===t)return t;for(var i=0,r=this._count-1;i<=r;){var a=(i+r)/2|0;if(e[a]<t)i=1+a;else{if(!(e[a]>t))return a;r=a-1}}return-1},lf.indicesOfNearest=function(t,e,n){var i=[];if(!this._storage[t])return i;null==n&&(n=1/0);for(var r=Number.MAX_VALUE,a=-1,o=0,s=this.count();o<s;o++){var l=e-this.get(t,o),h=Math.abs(l);l<=n&&h<=r&&((h<r||0<=l&&a<0)&&(r=h,a=l,i.length=0),i.push(o))}return i},lf.getRawIndex=df,lf.getRawDataItem=function(t){if(this._rawData.persistent)return this._rawData.getItem(this.getRawIndex(t));for(var e=[],n=0;n<this.dimensions.length;n++){var i=this.dimensions[n];e.push(this.get(i,t))}return e},lf.getName=function(t){var e=this.getRawIndex(t);return this._nameList[e]||cf(this,this._nameDimIdx,e)||""},lf.getId=function(t){return pf(this,this.getRawIndex(t))},lf.each=function(t,e,n,i){if(this._count){"function"==typeof t&&(i=n,n=e,e=t,t=[]),n=n||i||this;for(var r=(t=D(gf(t),this.getDimension,this)).length,a=0;a<this.count();a++)switch(r){case 0:e.call(n,a);break;case 1:e.call(n,this.get(t[0],a),a);break;case 2:e.call(n,this.get(t[0],a),this.get(t[1],a),a);break;default:for(var o=0,s=[];o<r;o++)s[o]=this.get(t[o],a);s[o]=a,e.apply(n,s)}}},lf.filterSelf=function(t,e,n,i){if(this._count){"function"==typeof t&&(i=n,n=e,e=t,t=[]),n=n||i||this,t=D(gf(t),this.getDimension,this);for(var r=this.count(),a=new(nf(this))(r),o=[],s=t.length,l=0,h=t[0],u=0;u<r;u++){var c,d=this.getRawIndex(u);if(0===s)c=e.call(n,u);else if(1===s){var f=this._getFast(h,d);c=e.call(n,f,u)}else{for(var p=0;p<s;p++)o[p]=this._getFast(h,d);o[p]=u,c=e.apply(n,o)}c&&(a[l++]=d)}return l<r&&(this._indices=a),this._count=l,this._extent={},this.getRawIndex=this._indices?ff:df,this}},lf.selectRange=function(t){if(this._count){var e=[];for(var n in t)t.hasOwnProperty(n)&&e.push(n);var i=e.length;if(i){var r=this.count(),a=new(nf(this))(r),o=0,s=e[0],l=t[s][0],h=t[s][1],u=!1;if(!this._indices){var c=0;if(1===i){for(var d=this._storage[e[0]],f=0;f<this._chunkCount;f++)for(var p=d[f],g=Math.min(this._count-f*this._chunkSize,this._chunkSize),m=0;m<g;m++){(l<=(w=p[m])&&w<=h||isNaN(w))&&(a[o++]=c),c++}u=!0}else if(2===i){d=this._storage[s];var v=this._storage[e[1]],y=t[e[1]][0],_=t[e[1]][1];for(f=0;f<this._chunkCount;f++){p=d[f];var x=v[f];for(g=Math.min(this._count-f*this._chunkSize,this._chunkSize),m=0;m<g;m++){var w=p[m],b=x[m];(l<=w&&w<=h||isNaN(w))&&(y<=b&&b<=_||isNaN(b))&&(a[o++]=c),c++}}u=!0}}if(!u)if(1===i)for(m=0;m<r;m++){var S=this.getRawIndex(m);(l<=(w=this._getFast(s,S))&&w<=h||isNaN(w))&&(a[o++]=S)}else for(m=0;m<r;m++){var M=!0;for(S=this.getRawIndex(m),f=0;f<i;f++){var I=e[f];((w=this._getFast(n,S))<t[I][0]||w>t[I][1])&&(M=!1)}M&&(a[o++]=this.getRawIndex(m))}return o<r&&(this._indices=a),this._count=o,this._extent={},this.getRawIndex=this._indices?ff:df,this}}},lf.mapArray=function(t,e,n,i){"function"==typeof t&&(i=n,n=e,e=t,t=[]),n=n||i||this;var r=[];return this.each(t,function(){r.push(e&&e.apply(this,arguments))},n),r},lf.map=function(t,e,n,i){n=n||i||this;var r=mf(this,t=D(gf(t),this.getDimension,this));r._indices=this._indices,r.getRawIndex=r._indices?ff:df;for(var a=r._storage,o=[],s=this._chunkSize,l=t.length,h=this.count(),u=[],c=r._rawExtent,d=0;d<h;d++){for(var f=0;f<l;f++)u[f]=this.get(t[f],d);u[l]=d;var p=e&&e.apply(n,u);if(null!=p){"object"!=typeof p&&(o[0]=p,p=o);for(var g=this.getRawIndex(d),m=Math.floor(g/s),v=g%s,y=0;y<p.length;y++){var _=t[y],x=p[y],w=c[_],b=a[_];b&&(b[m][v]=x),x<w[0]&&(w[0]=x),x>w[1]&&(w[1]=x)}}}return r},lf.downSample=function(t,e,n,i){for(var r=mf(this,[t]),a=r._storage,o=[],s=Math.floor(1/e),l=a[t],h=this.count(),u=this._chunkSize,c=r._rawExtent[t],d=new(nf(this))(h),f=0,p=0;p<h;p+=s){h-p<s&&(s=h-p,o.length=s);for(var g=0;g<s;g++){var m=this.getRawIndex(p+g),v=Math.floor(m/u),y=m%u;o[g]=l[v][y]}var _=n(o),x=this.getRawIndex(Math.min(p+i(o,_)||0,h-1)),w=x%u;(l[Math.floor(x/u)][w]=_)<c[0]&&(c[0]=_),_>c[1]&&(c[1]=_),d[f++]=x}return r._count=f,r._indices=d,r.getRawIndex=ff,r},lf.getItemModel=function(t){var e=this.hostModel;return new Js(this.getRawDataItem(t),e,e&&e.ecModel)},lf.diff=function(e){var n=this;return new Xd(e?e.getIndices():[],this.getIndices(),function(t){return pf(e,t)},function(t){return pf(n,t)})},lf.getVisual=function(t){var e=this._visual;return e&&e[t]},lf.setVisual=function(t,e){if($d(t))for(var n in t)t.hasOwnProperty(n)&&this.setVisual(n,t[n]);else this._visual=this._visual||{},this._visual[t]=e},lf.setLayout=function(t,e){if($d(t))for(var n in t)t.hasOwnProperty(n)&&this.setLayout(n,t[n]);else this._layout[t]=e},lf.getLayout=function(t){return this._layout[t]},lf.getItemLayout=function(t){return this._itemLayouts[t]},lf.setItemLayout=function(t,e,n){this._itemLayouts[t]=n?I(this._itemLayouts[t]||{},e):e},lf.clearItemLayouts=function(){this._itemLayouts.length=0},lf.getItemVisual=function(t,e,n){var i=this._itemVisuals[t],r=i&&i[e];return null!=r||n?r:this.getVisual(e)},lf.setItemVisual=function(t,e,n){var i=this._itemVisuals[t]||{},r=this.hasItemVisual;if(this._itemVisuals[t]=i,$d(e))for(var a in e)e.hasOwnProperty(a)&&(i[a]=e[a],r[a]=!0);else i[e]=n,r[e]=!0},lf.clearAllVisual=function(){this._visual={},this._itemVisuals=[],this.hasItemVisual={}};function _f(t){t.seriesIndex=this.seriesIndex,t.dataIndex=this.dataIndex,t.dataType=this.dataType}function xf(t,e,n){fh.isInstance(e)||(e=fh.seriesDataToSource(e)),n=n||{},t=(t||[]).slice();for(var i=(n.dimsDef||[]).slice(),l=Q(n.encodeDef),r=Q(),a=Q(),h=[],o=function(t,e,n,i){var r=Math.max(t.dimensionsDetectCount||1,e.length,n.length,i||0);return A(e,function(t){var e=t.dimsDef;e&&(r=Math.max(r,e.length))}),r}(e,t,i,n.dimCount),s=0;s<o;s++){var u=i[s]=I({},N(i[s])?i[s]:{name:i[s]}),c=u.name,d=h[s]={otherDims:{}};null!=c&&null==r.get(c)&&(d.name=d.displayName=c,r.set(c,s)),null!=u.type&&(d.type=u.type),null!=u.displayName&&(d.displayName=u.displayName)}l.each(function(t,n){if(1===(t=gr(t).slice()).length&&!E(t[0])&&t[0]<0)l.set(n,!1);else{var i=l.set(n,[]);A(t,function(t,e){E(t)&&(t=r.get(t)),null!=t&&t<o&&(i[e]=t,p(h[t],n,e))})}});var f=0;function p(t,e,n){null!=jd.get(e)?t.otherDims[e]=n:(t.coordDim=e,t.coordDimIndex=n,a.set(e,!0))}A(t,function(r,t){var a,o,s;if(E(r))a=r,r={};else{a=r.name;var e=r.ordinalMeta;r.ordinalMeta=null,(r=b(r)).ordinalMeta=e,o=r.dimsDef,s=r.otherDims,r.name=r.coordDim=r.coordDimIndex=r.dimsDef=r.otherDims=null}if(!1!==(n=l.get(a))){var n;if(!(n=gr(n)).length)for(var i=0;i<(o&&o.length||1);i++){for(;f<h.length&&null!=h[f].coordDim;)f++;f<h.length&&n.push(f++)}A(n,function(t,e){var n=h[t];if(p(T(n,r),a,e),null==n.name&&o){var i=o[e];N(i)||(i={name:i}),n.name=n.displayName=i.name,n.defaultTooltip=i.defaultTooltip}s&&T(n.otherDims,s)})}});var g=n.generateCoord,m=n.generateCoordCount,v=null!=m;m=g?m||1:0;for(var y,_,x=g||"value",w=0;w<o;w++){null==(d=h[w]=h[w]||{}).coordDim&&(d.coordDim=wf(x,a,v),d.coordDimIndex=0,(!g||m<=0)&&(d.isExtraCoord=!0),m--),null==d.name&&(d.name=wf(d.coordDim,r)),null==d.type&&(y=e,_=w,d.name,yh(y.data,y.sourceFormat,y.seriesLayoutBy,y.dimensionsDefine,y.startIndex,_))&&(d.type="ordinal")}return h}function wf(t,e,n){if(n||null!=e.get(t)){for(var i=0;null!=e.get(t+i);)i++;t+=i}return e.set(t,!0),t}lf.setItemGraphicEl=function(t,e){var n=this.hostModel;e&&(e.dataIndex=t,e.dataType=this.dataType,e.seriesIndex=n&&n.seriesIndex,"group"===e.type&&e.traverse(_f,e)),this._graphicEls[t]=e},lf.getItemGraphicEl=function(t){return this._graphicEls[t]},lf.eachItemGraphicEl=function(n,i){A(this._graphicEls,function(t,e){t&&n&&n.call(i,t,e)})},lf.cloneShallow=function(t){if(!t){var e=D(this.dimensions,this.getDimensionInfo,this);t=new sf(e,this.hostModel)}if(t._storage=this._storage,of(t,this),this._indices){var n=this._indices.constructor;t._indices=new n(this._indices)}else t._indices=null;return t.getRawIndex=t._indices?ff:df,t},lf.wrapMethod=function(t,e){var n=this[t];"function"==typeof n&&(this.__wrappedMethods=this.__wrappedMethods||[],this.__wrappedMethods.push(t),this[t]=function(){var t=n.apply(this,arguments);return e.apply(this,[t].concat(Z(arguments)))})},lf.TRANSFERABLE_METHODS=["cloneShallow","downSample","map"],lf.CHANGABLE_METHODS=["filterSelf","selectRange"];var bf=function(t,e){return xf((e=e||{}).coordDimensions||[],t,{dimsDef:e.dimensionsDefine||t.dimensionsDefine,encodeDef:e.encodeDefine||t.encodeDefine,dimCount:e.dimensionsCount,generateCoord:e.generateCoord,generateCoordCount:e.generateCoordCount})};function Sf(t,n,e){var i,r,a,o,s=(e=e||{}).byIndex,l=e.stackedCoordDimension,h=!(!t||!t.get("stack"));if(A(n,function(t,e){E(t)&&(n[e]=t={name:t}),h&&!t.isExtraCoord&&(s||i||!t.ordinalMeta||(i=t),r||"ordinal"===t.type||"time"===t.type||l&&l!==t.coordDim||(r=t))}),!r||s||i||(s=!0),r){a="__\0ecstackresult",o="__\0ecstackedover",i&&(i.createInvertedIndices=!0);var u=r.coordDim,c=r.type,d=0;A(n,function(t){t.coordDim===u&&d++}),n.push({name:a,coordDim:u,coordDimIndex:d,type:c,isExtraCoord:!0,isCalculationCoord:!0}),d++,n.push({name:o,coordDim:o,coordDimIndex:d,type:c,isExtraCoord:!0,isCalculationCoord:!0})}return{stackedDimension:r&&r.name,stackedByDimension:i&&i.name,isStackedByIndex:s,stackedOverDimension:o,stackResultDimension:a}}function Mf(t,e){return!!e&&e===t.getCalculationInfo("stackedDimension")}function If(t,e){return Mf(t,e)?t.getCalculationInfo("stackResultDimension"):e}function Cf(t,e,n){n=n||{},fh.isInstance(t)||(t=fh.seriesDataToSource(t));var i,r=e.get("coordinateSystem"),a=Ch.get(r),o=nh(e);o&&(i=D(o.coordSysDims,function(t){var e={name:t},n=o.axisMap.get(t);if(n){var i=n.get("type");e.type=function(t){return"category"===t?"ordinal":"time"===t?"time":"float"}(i)}return e})),i=i||(a&&(a.getDimensionsInfo?a.getDimensionsInfo():a.dimensions.slice())||["x","y"]);var s,l,h=bf(t,{coordDimensions:i,generateCoord:n.generateCoord});o&&A(h,function(t,e){var n=t.coordDim,i=o.categoryAxisMap.get(n);i&&(null==s&&(s=e),t.ordinalMeta=i.getOrdinalMeta()),null!=t.otherDims.itemName&&(l=!0)}),l||null==s||(h[s].otherDims.itemName=0);var u=Sf(e,h),c=new sf(h,e);c.setCalculationInfo(u);var d=null!=s&&function(t){if(t.sourceFormat===ah){var e=function(t){var e=0;for(;e<t.length&&null==t[e];)e++;return t[e]}(t.data||[]);return null!=e&&!O(yr(e))}}(t)?function(t,e,n,i){return i===s?n:this.defaultDimValueGetter(t,e,n,i)}:null;return c.hasItemOption=!1,c.initData(t,null,d),c}function Tf(t){this._setting=t||{},this._extent=[1/0,-1/0],this._interval=0,this.init&&this.init.apply(this,arguments)}function Af(t){this.categories=t.categories||[],this._needCollect=t.needCollect,this._deduplication=t.deduplication,this._map}Tf.prototype.parse=function(t){return t},Tf.prototype.getSetting=function(t){return this._setting[t]},Tf.prototype.contain=function(t){var e=this._extent;return t>=e[0]&&t<=e[1]},Tf.prototype.normalize=function(t){var e=this._extent;return e[1]===e[0]?.5:(t-e[0])/(e[1]-e[0])},Tf.prototype.scale=function(t){var e=this._extent;return t*(e[1]-e[0])+e[0]},Tf.prototype.unionExtent=function(t){var e=this._extent;t[0]<e[0]&&(e[0]=t[0]),t[1]>e[1]&&(e[1]=t[1])},Tf.prototype.unionExtentFromData=function(t,e){this.unionExtent(t.getApproximateExtent(e))},Tf.prototype.getExtent=function(){return this._extent.slice()},Tf.prototype.setExtent=function(t,e){var n=this._extent;isNaN(t)||(n[0]=t),isNaN(e)||(n[1]=e)},Tf.prototype.isBlank=function(){return this._isBlank},Tf.prototype.setBlank=function(t){this._isBlank=t},Tf.prototype.getLabel=null,Or(Tf),Br(Tf,{registerWhenExtend:!0}),Af.createByAxisModel=function(t){var e=t.option,n=e.data,i=n&&D(n,Pf);return new Af({categories:i,needCollect:!i,deduplication:!1!==e.dedplication})};var Df=Af.prototype;function kf(t){return t._map||(t._map=Q(t.categories))}function Pf(t){return N(t)&&null!=t.value?t.value:t+""}Df.getOrdinal=function(t){return kf(this).get(t)},Df.parseAndCollect=function(t){var e,n=this._needCollect;if("string"!=typeof t&&!n)return t;if(n&&!this._deduplication)return e=this.categories.length,this.categories[e]=t,e;var i=kf(this);return null==(e=i.get(t))&&(n?(e=this.categories.length,this.categories[e]=t,i.set(t,e)):e=NaN),e};var Lf=Tf.prototype,Of=Tf.extend({type:"ordinal",init:function(t,e){t&&!O(t)||(t=new Af({categories:t})),this._ordinalMeta=t,this._extent=e||[0,t.categories.length-1]},parse:function(t){return"string"==typeof t?this._ordinalMeta.getOrdinal(t):Math.round(t)},contain:function(t){return t=this.parse(t),Lf.contain.call(this,t)&&null!=this._ordinalMeta.categories[t]},normalize:function(t){return Lf.normalize.call(this,this.parse(t))},scale:function(t){return Math.round(Lf.scale.call(this,t))},getTicks:function(){for(var t=[],e=this._extent,n=e[0];n<=e[1];)t.push(n),n++;return t},getLabel:function(t){if(!this.isBlank())return this._ordinalMeta.categories[t]},count:function(){return this._extent[1]-this._extent[0]+1},unionExtentFromData:function(t,e){this.unionExtent(t.getApproximateExtent(e))},getOrdinalMeta:function(){return this._ordinalMeta},niceTicks:J,niceExtent:J});Of.create=function(){return new Of};var zf=sl;function Ef(t){return ul(t)+2}function Nf(t,e,n){t[e]=Math.max(Math.min(t[e],n[1]),n[0])}function Rf(t,e){isFinite(t[0])||(t[0]=e[0]),isFinite(t[1])||(t[1]=e[1]),Nf(t,0,e),Nf(t,1,e),t[0]>t[1]&&(t[0]=t[1])}var Bf=sl,Ff=Tf.extend({type:"interval",_interval:0,_intervalPrecision:2,setExtent:function(t,e){var n=this._extent;isNaN(t)||(n[0]=parseFloat(t)),isNaN(e)||(n[1]=parseFloat(e))},unionExtent:function(t){var e=this._extent;t[0]<e[0]&&(e[0]=t[0]),t[1]>e[1]&&(e[1]=t[1]),Ff.prototype.setExtent.call(this,e[0],e[1])},getInterval:function(){return this._interval},setInterval:function(t){this._interval=t,this._niceExtent=this._extent.slice(),this._intervalPrecision=Ef(t)},getTicks:function(){return function(t,e,n,i){var r=[];if(!t)return r;e[0]<n[0]&&r.push(e[0]);for(var a=n[0];a<=n[1]&&(r.push(a),(a=zf(a+t,i))!==r[r.length-1]);)if(1e4<r.length)return[];return e[1]>(r.length?r[r.length-1]:n[1])&&r.push(e[1]),r}(this._interval,this._extent,this._niceExtent,this._intervalPrecision)},getLabel:function(t,e){if(null==t)return"";var n=e&&e.precision;return null==n?n=ul(t)||0:"auto"===n&&(n=this._intervalPrecision),wl(t=Bf(t,n,!0))},niceTicks:function(t,e,n){t=t||5;var i=this._extent,r=i[1]-i[0];if(isFinite(r)){r<0&&(r=-r,i.reverse());var a=function(t,e,n,i){var r={},a=t[1]-t[0],o=r.interval=_l(a/e,!0);null!=n&&o<n&&(o=r.interval=n),null!=i&&i<o&&(o=r.interval=i);var s=r.intervalPrecision=Ef(o);return Rf(r.niceTickExtent=[zf(Math.ceil(t[0]/o)*o,s),zf(Math.floor(t[1]/o)*o,s)],t),r}(i,t,e,n);this._intervalPrecision=a.intervalPrecision,this._interval=a.interval,this._niceExtent=a.niceTickExtent}},niceExtent:function(t){var e=this._extent;if(e[0]===e[1])if(0!==e[0]){var n=e[0];t.fixMax||(e[1]+=n/2),e[0]-=n/2}else e[1]=1;var i=e[1]-e[0];isFinite(i)||(e[0]=0,e[1]=1),this.niceTicks(t.splitNumber,t.minInterval,t.maxInterval);var r=this._interval;t.fixMin||(e[0]=Bf(Math.floor(e[0]/r)*r)),t.fixMax||(e[1]=Bf(Math.ceil(e[1]/r)*r))}});Ff.create=function(){return new Ff};var Vf="__ec_stack_",Hf="undefined"!=typeof Float32Array?Float32Array:Array;function Wf(t){return t.get("stack")||Vf+t.seriesIndex}function Gf(t){return t.dim+t.index}function Zf(t,e){var n=[];return e.eachSeriesByType(t,function(t){jf(t)&&!qf(t)&&n.push(t)}),n}function Uf(t){var h=[];return A(t,function(t){var e=t.getData(),n=t.coordinateSystem.getBaseAxis(),i=n.getExtent(),r="category"===n.type?n.getBandWidth():Math.abs(i[1]-i[0])/e.count(),a=ol(t.get("barWidth"),r),o=ol(t.get("barMaxWidth"),r),s=t.get("barGap"),l=t.get("barCategoryGap");h.push({bandWidth:r,barWidth:a,barMaxWidth:o,barGap:s,barCategoryGap:l,axisKey:Gf(n),stackId:Wf(t)})}),function(t){var c={};A(t,function(t,e){var n=t.axisKey,i=t.bandWidth,r=c[n]||{bandWidth:i,remainedWidth:i,autoWidthCount:0,categoryGap:"20%",gap:"30%",stacks:{}},a=r.stacks;c[n]=r;var o=t.stackId;a[o]||r.autoWidthCount++,a[o]=a[o]||{width:0,maxWidth:0};var s=t.barWidth;s&&!a[o].width&&(a[o].width=s,s=Math.min(r.remainedWidth,s),r.remainedWidth-=s);var l=t.barMaxWidth;l&&(a[o].maxWidth=l);var h=t.barGap;null!=h&&(r.gap=h);var u=t.barCategoryGap;null!=u&&(r.categoryGap=u)});var d={};return A(c,function(t,n){d[n]={};var e=t.stacks,i=t.bandWidth,r=ol(t.categoryGap,i),a=ol(t.gap,1),o=t.remainedWidth,s=t.autoWidthCount,l=(o-r)/(s+(s-1)*a);l=Math.max(l,0),A(e,function(t,e){var n=t.maxWidth;n&&n<l&&(n=Math.min(n,o),t.width&&(n=Math.min(n,t.width)),o-=n,t.width=n,s--)}),l=(o-r)/(s+(s-1)*a),l=Math.max(l,0);var h,u=0;A(e,function(t,e){t.width||(t.width=l),u+=(h=t).width*(1+a)}),h&&(u-=h.width*a);var c=-u/2;A(e,function(t,e){d[n][e]=d[n][e]||{offset:c,width:t.width},c+=t.width*(1+a)})}),d}(h)}function Xf(t,e,n){if(t&&e){var i=t[Gf(e)];return null!=i&&null!=n&&(i=i[Wf(n)]),i}}var Yf={seriesType:"bar",plan:Eu(),reset:function(t){if(jf(t)&&qf(t)){var e=t.getData(),u=t.coordinateSystem,c=u.getBaseAxis(),d=u.getOtherAxis(c),f=e.mapDimension(d.dim),p=e.mapDimension(c.dim),g=d.isHorizontal(),m=g?0:1,v=Xf(Uf([t]),c,t).width;return.5<v||(v=.5),{progress:function(t,e){var n,i=t.count,r=new Hf(2*i),a=new Hf(i),o=[],s=[],l=0,h=0;for(;null!=(n=t.next());)s[m]=e.get(f,n),s[1-m]=e.get(p,n),o=u.dataToPoint(s,null,o),r[l++]=o[0],r[l++]=o[1],a[h++]=n;e.setLayout({largePoints:r,largeDataIndices:a,barWidth:v,valueAxisStart:$f(c,d,!1),valueAxisHorizontal:g})}}}}};function jf(t){return t.coordinateSystem&&"cartesian2d"===t.coordinateSystem.type}function qf(t){return t.pipelineContext&&t.pipelineContext.large}function $f(t,e){var n,i,r=e.getGlobalExtent();i=r[0]>r[1]?(n=r[1],r[0]):(n=r[0],r[1]);var a=e.toGlobalCoord(e.dataToCoord(0));return a<n&&(a=n),i<a&&(a=i),a}var Kf=Ff.prototype,Qf=Math.ceil,Jf=Math.floor,tp=36e5,ep=864e5,np=Ff.extend({type:"time",getLabel:function(t){var e=this._stepLvl,n=new Date(t);return Ll(e[0],n,this.getSetting("useUTC"))},niceExtent:function(t){var e=this._extent;if(e[0]===e[1]&&(e[0]-=ep,e[1]+=ep),e[1]===-1/0&&e[0]===1/0){var n=new Date;e[1]=+new Date(n.getFullYear(),n.getMonth(),n.getDate()),e[0]=e[1]-ep}this.niceTicks(t.splitNumber,t.minInterval,t.maxInterval);var i=this._interval;t.fixMin||(e[0]=sl(Jf(e[0]/i)*i)),t.fixMax||(e[1]=sl(Qf(e[1]/i)*i))},niceTicks:function(t,e,n){t=t||10;var i=this._extent,r=i[1]-i[0],a=r/t;null!=e&&a<e&&(a=e),null!=n&&n<a&&(a=n);var o=ip.length,s=function(t,e,n,i){for(;n<i;){var r=n+i>>>1;t[r][1]<e?n=1+r:i=r}return n}(ip,a,0,o),l=ip[Math.min(s,o-1)],h=l[1];"year"===l[0]&&(h*=_l(r/h/t,!0));var u=this.getSetting("useUTC")?0:60*new Date(+i[0]||+i[1]).getTimezoneOffset()*1e3,c=[Math.round(Qf((i[0]-u)/h)*h+u),Math.round(Jf((i[1]-u)/h)*h+u)];Rf(c,i),this._stepLvl=l,this._interval=h,this._niceExtent=c},parse:function(t){return+ml(t)}});A(["contain","normalize"],function(e){np.prototype[e]=function(t){return Kf[e].call(this,this.parse(t))}});var ip=[["hh:mm:ss",1e3],["hh:mm:ss",5e3],["hh:mm:ss",1e4],["hh:mm:ss",15e3],["hh:mm:ss",3e4],["hh:mm\nMM-dd",6e4],["hh:mm\nMM-dd",3e5],["hh:mm\nMM-dd",6e5],["hh:mm\nMM-dd",9e5],["hh:mm\nMM-dd",18e5],["hh:mm\nMM-dd",tp],["hh:mm\nMM-dd",72e5],["hh:mm\nMM-dd",6*tp],["hh:mm\nMM-dd",432e5],["MM-dd\nyyyy",ep],["MM-dd\nyyyy",2*ep],["MM-dd\nyyyy",3*ep],["MM-dd\nyyyy",4*ep],["MM-dd\nyyyy",5*ep],["MM-dd\nyyyy",6*ep],["week",7*ep],["MM-dd\nyyyy",864e6],["week",14*ep],["week",21*ep],["month",31*ep],["week",42*ep],["month",62*ep],["week",70*ep],["quarter",95*ep],["month",31*ep*4],["month",13392e6],["half-year",16416e6],["month",31*ep*8],["month",26784e6],["year",380*ep]];np.create=function(t){return new np({useUTC:t.ecModel.get("useUTC")})};var rp=Tf.prototype,ap=Ff.prototype,op=ul,sp=sl,lp=Math.floor,hp=Math.ceil,up=Math.pow,cp=Math.log,dp=Tf.extend({type:"log",base:10,$constructor:function(){Tf.apply(this,arguments),this._originalScale=new Ff},getTicks:function(){var n=this._originalScale,i=this._extent,r=n.getExtent();return D(ap.getTicks.call(this),function(t){var e=sl(up(this.base,t));return e=t===i[0]&&n.__fixMin?fp(e,r[0]):e,e=t===i[1]&&n.__fixMax?fp(e,r[1]):e},this)},getLabel:ap.getLabel,scale:function(t){return t=rp.scale.call(this,t),up(this.base,t)},setExtent:function(t,e){var n=this.base;t=cp(t)/cp(n),e=cp(e)/cp(n),ap.setExtent.call(this,t,e)},getExtent:function(){var t=this.base,e=rp.getExtent.call(this);e[0]=up(t,e[0]),e[1]=up(t,e[1]);var n=this._originalScale,i=n.getExtent();return n.__fixMin&&(e[0]=fp(e[0],i[0])),n.__fixMax&&(e[1]=fp(e[1],i[1])),e},unionExtent:function(t){this._originalScale.unionExtent(t);var e=this.base;t[0]=cp(t[0])/cp(e),t[1]=cp(t[1])/cp(e),rp.unionExtent.call(this,t)},unionExtentFromData:function(t,e){this.unionExtent(t.getApproximateExtent(e))},niceTicks:function(t){t=t||10;var e=this._extent,n=e[1]-e[0];if(!(n==1/0||n<=0)){var i=vl(n);for(t/n*i<=.5&&(i*=10);!isNaN(i)&&Math.abs(i)<1&&0<Math.abs(i);)i*=10;var r=[sl(hp(e[0]/i)*i),sl(lp(e[1]/i)*i)];this._interval=i,this._niceExtent=r}},niceExtent:function(t){ap.niceExtent.call(this,t);var e=this._originalScale;e.__fixMin=t.fixMin,e.__fixMax=t.fixMax}});function fp(t,e){return sp(t,op(e))}function pp(t,e){var n,i,r,a=t.type,o=e.getMin(),s=e.getMax(),l=null!=o,h=null!=s,u=t.getExtent();"ordinal"===a?n=e.getCategories().length:(O(i=e.get("boundaryGap"))||(i=[i||0,i||0]),"boolean"==typeof i[0]&&(i=[0,0]),i[0]=ol(i[0],1),i[1]=ol(i[1],1),r=u[1]-u[0]||Math.abs(u[0])),null==o&&(o="ordinal"===a?n?0:NaN:u[0]-i[0]*r),null==s&&(s="ordinal"===a?n?n-1:NaN:u[1]+i[1]*r),"dataMin"===o?o=u[0]:"function"==typeof o&&(o=o({min:u[0],max:u[1]})),"dataMax"===s?s=u[1]:"function"==typeof s&&(s=s({min:u[0],max:u[1]})),null!=o&&isFinite(o)||(o=NaN),null!=s&&isFinite(s)||(s=NaN),t.setBlank(V(o)||V(s)||"ordinal"===a&&!t.getOrdinalMeta().categories.length),e.getNeedCrossZero()&&(0<o&&0<s&&!l&&(o=0),o<0&&s<0&&!h&&(s=0));var c=e.ecModel;if(c&&"time"===a){var d,f=Zf("bar",c);if(A(f,function(t){d|=t.getBaseAxis()===e.axis}),d){var p=Uf(f),g=function(t,e,n,i){var r=n.axis.getExtent(),a=r[1]-r[0],o=Xf(i,n.axis);if(void 0===o)return{min:t,max:e};var s=1/0;A(o,function(t){s=Math.min(t.offset,s)});var l=-1/0;A(o,function(t){l=Math.max(t.offset+t.width,l)}),s=Math.abs(s),l=Math.abs(l);var h=s+l,u=e-t,c=u/(1-(s+l)/a)-u;return{min:t-=s/h*c,max:e+=l/h*c}}(o,s,e,p);o=g.min,s=g.max}}return[o,s]}function gp(t,e){var n=pp(t,e),i=null!=e.getMin(),r=null!=e.getMax(),a=e.get("splitNumber");"log"===t.type&&(t.base=e.get("logBase"));var o=t.type;t.setExtent(n[0],n[1]),t.niceExtent({splitNumber:a,fixMin:i,fixMax:r,minInterval:"interval"===o||"time"===o?e.get("minInterval"):null,maxInterval:"interval"===o||"time"===o?e.get("maxInterval"):null});var s=e.get("interval");null!=s&&t.setInterval&&t.setInterval(s)}function mp(t,e){if(e=e||t.get("type"))switch(e){case"category":return new Of(t.getOrdinalMeta?t.getOrdinalMeta():t.getCategories(),[1/0,-1/0]);case"value":return new Ff;default:return(Tf.getClass(e)||Ff).create(t)}}function vp(n){var e,i=n.getLabelModel().get("formatter"),r="category"===n.type?n.scale.getExtent()[0]:null;return"string"==typeof i?(e=i,i=function(t){return t=n.scale.getLabel(t),e.replace("{value}",null!=t?t:"")}):"function"==typeof i?function(t,e){return null!=r&&(e=t-r),i(yp(n,t),e)}:function(t){return n.scale.getLabel(t)}}function yp(t,e){return"category"===t.type?t.scale.getLabel(e):e}function _p(t){var e=t.get("interval");return null==e?"auto":e}function xp(t){return"category"===t.type&&0===_p(t.getLabelModel())}A(["contain","normalize"],function(e){dp.prototype[e]=function(t){return t=cp(t)/cp(this.base),rp[e].call(this,t)}}),dp.create=function(){return new dp};var wp={getMin:function(t){var e=this.option,n=t||null==e.rangeStart?e.min:e.rangeStart;return this.axis&&null!=n&&"dataMin"!==n&&"function"!=typeof n&&!V(n)&&(n=this.axis.scale.parse(n)),n},getMax:function(t){var e=this.option,n=t||null==e.rangeEnd?e.max:e.rangeEnd;return this.axis&&null!=n&&"dataMax"!==n&&"function"!=typeof n&&!V(n)&&(n=this.axis.scale.parse(n)),n},getNeedCrossZero:function(){var t=this.option;return null==t.rangeStart&&null==t.rangeEnd&&!t.scale},getCoordSysModel:J,setRange:function(t,e){this.option.rangeStart=t,this.option.rangeEnd=e},resetRange:function(){this.option.rangeStart=this.option.rangeEnd=null}},bp=is({type:"triangle",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(t,e){var n=e.cx,i=e.cy,r=e.width/2,a=e.height/2;t.moveTo(n,i-a),t.lineTo(n+r,i+a),t.lineTo(n-r,i+a),t.closePath()}}),Sp=is({type:"diamond",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(t,e){var n=e.cx,i=e.cy,r=e.width/2,a=e.height/2;t.moveTo(n,i-a),t.lineTo(n+r,i),t.lineTo(n,i+a),t.lineTo(n-r,i),t.closePath()}}),Mp=is({type:"pin",shape:{x:0,y:0,width:0,height:0},buildPath:function(t,e){var n=e.x,i=e.y,r=e.width/5*3,a=Math.max(r,e.height),o=r/2,s=o*o/(a-o),l=i-a+o+s,h=Math.asin(s/o),u=Math.cos(h)*o,c=Math.sin(h),d=Math.cos(h),f=.6*o,p=.7*o;t.moveTo(n-u,l+s),t.arc(n,l,o,Math.PI-h,2*Math.PI+h),t.bezierCurveTo(n+u-c*f,l+s+d*f,n,i-p,n,i),t.bezierCurveTo(n,i-p,n-u+c*f,l+s+d*f,n-u,l+s),t.closePath()}}),Ip=is({type:"arrow",shape:{x:0,y:0,width:0,height:0},buildPath:function(t,e){var n=e.height,i=e.width,r=e.x,a=e.y,o=i/3*2;t.moveTo(r,a),t.lineTo(r+o,a+n),t.lineTo(r,a+n/4*3),t.lineTo(r-o,a+n),t.lineTo(r,a),t.closePath()}}),Cp={line:function(t,e,n,i,r){r.x1=t,r.y1=e+i/2,r.x2=t+n,r.y2=e+i/2},rect:function(t,e,n,i,r){r.x=t,r.y=e,r.width=n,r.height=i},roundRect:function(t,e,n,i,r){r.x=t,r.y=e,r.width=n,r.height=i,r.r=Math.min(n,i)/4},square:function(t,e,n,i,r){var a=Math.min(n,i);r.x=t,r.y=e,r.width=a,r.height=a},circle:function(t,e,n,i,r){r.cx=t+n/2,r.cy=e+i/2,r.r=Math.min(n,i)/2},diamond:function(t,e,n,i,r){r.cx=t+n/2,r.cy=e+i/2,r.width=n,r.height=i},pin:function(t,e,n,i,r){r.x=t+n/2,r.y=e+i/2,r.width=n,r.height=i},arrow:function(t,e,n,i,r){r.x=t+n/2,r.y=e+i/2,r.width=n,r.height=i},triangle:function(t,e,n,i,r){r.cx=t+n/2,r.cy=e+i/2,r.width=n,r.height=i}},Tp={};A({line:Bo,rect:No,roundRect:No,square:No,circle:So,diamond:Sp,pin:Mp,arrow:Ip,triangle:bp},function(t,e){Tp[e]=new t});var Ap=is({type:"symbol",shape:{symbolType:"",x:0,y:0,width:0,height:0},calculateTextPosition:function(t,e,n){var i=oi(t,e,n),r=this.shape;return r&&"pin"===r.symbolType&&"inside"===e.textPosition&&(i.y=n.y+.4*n.height),i},buildPath:function(t,e,n){var i=e.symbolType;if("none"!==i){var r=Tp[i];r=r||Tp[i="rect"],Cp[i](e.x,e.y,e.width,e.height,r.shape),r.buildPath(t,r.shape,n)}}});function Dp(t,e){if("image"!==this.type){var n=this.style,i=this.shape;i&&"line"===i.symbolType?n.stroke=t:this.__isEmptyBrush?(n.stroke=t,n.fill=e||"#fff"):(n.fill&&(n.fill=t),n.stroke&&(n.stroke=t)),this.dirty(!1)}}function kp(t,e,n,i,r,a,o){var s,l=0===t.indexOf("empty");return l&&(t=t.substr(5,1).toLowerCase()+t.substr(6)),(s=0===t.indexOf("image://")?as(t.slice(8),new vn(e,n,i,r),o?"center":"cover"):0===t.indexOf("path://")?rs(t.slice(7),{},new vn(e,n,i,r),o?"center":"cover"):new Ap({shape:{symbolType:t,x:e,y:n,width:i,height:r}})).__isEmptyBrush=l,s.setColor=Dp,s.setColor(a),s}var Pp={isDimensionStacked:Mf,enableDataStack:Sf,getStackedDimension:If};var Lp=(Object.freeze||Object)({createList:function(t){return Cf(t.getSource(),t)},getLayoutRect:Hl,dataStack:Pp,createScale:function(t,e){var n=e;Js.isInstance(e)||S(n=new Js(e),wp);var i=mp(n);return i.setExtent(t[0],t[1]),gp(i,n),i},mixinAxisModelCommonMethods:function(t){S(t,wp)},completeDimensions:xf,createDimensions:bf,createSymbol:kp}),Op=1e-8;function zp(t,e){return Math.abs(t-e)<Op}function Ep(t,e,n){var i=0,r=t[0];if(!r)return!1;for(var a=1;a<t.length;a++){var o=t[a];i+=Ga(r[0],r[1],o[0],o[1],e,n),r=o}var s=t[0];return zp(r[0],s[0])&&zp(r[1],s[1])||(i+=Ga(r[0],r[1],s[0],s[1],e,n)),0!==i}function Np(t,e,n){if(this.name=t,this.geometries=e,n)n=[n[0],n[1]];else{var i=this.getBoundingRect();n=[i.x+i.width/2,i.y+i.height/2]}this.center=n}function Rp(t,e,n){for(var i=[],r=e[0],a=e[1],o=0;o<t.length;o+=2){var s=t.charCodeAt(o)-64,l=t.charCodeAt(o+1)-64;s=s>>1^-(1&s),l=l>>1^-(1&l),r=s+=r,a=l+=a,i.push([s/n,l/n])}return i}Np.prototype={constructor:Np,properties:null,getBoundingRect:function(){var t=this._rect;if(t)return t;for(var e=Number.MAX_VALUE,n=[e,e],i=[-e,-e],r=[],a=[],o=this.geometries,s=0;s<o.length;s++){if("polygon"===o[s].type)va(o[s].exterior,r,a),_t(n,n,r),xt(i,i,a)}return 0===s&&(n[0]=n[1]=i[0]=i[1]=0),this._rect=new vn(n[0],n[1],i[0]-n[0],i[1]-n[1])},contain:function(t){var e=this.getBoundingRect(),n=this.geometries;if(!e.contain(t[0],t[1]))return!1;t:for(var i=0,r=n.length;i<r;i++)if("polygon"===n[i].type){var a=n[i].exterior,o=n[i].interiors;if(Ep(a,t[0],t[1])){for(var s=0;s<(o?o.length:0);s++)if(Ep(o[s]))continue t;return!0}}return!1},transformTo:function(t,e,n,i){var r=this.getBoundingRect(),a=r.width/r.height;n?i=i||n/a:n=a*i;for(var o=new vn(t,e,n,i),s=r.calculateTransform(o),l=this.geometries,h=0;h<l.length;h++)if("polygon"===l[h].type){for(var u=l[h].exterior,c=l[h].interiors,d=0;d<u.length;d++)yt(u[d],u[d],s);for(var f=0;f<(c?c.length:0);f++)for(d=0;d<c[f].length;d++)yt(c[f][d],c[f][d],s)}(r=this._rect).copy(o),this.center=[r.x+r.width/2,r.y+r.height/2]},cloneShallow:function(t){null==t&&(t=this.name);var e=new Np(t,this.geometries,this.center);return e._rect=this._rect,e.transformTo=null,e}};function Bp(t){return function(t){if(!t.UTF8Encoding)return;var e=t.UTF8Scale;null==e&&(e=1024);for(var n=t.features,i=0;i<n.length;i++)for(var r=n[i].geometry,a=r.coordinates,o=r.encodeOffsets,s=0;s<a.length;s++){var l=a[s];if("Polygon"===r.type)a[s]=Rp(l,o[s],e);else if("MultiPolygon"===r.type)for(var h=0;h<l.length;h++){var u=l[h];l[h]=Rp(u,o[s][h],e)}}t.UTF8Encoding=!1}(t),D(C(t.features,function(t){return t.geometry&&t.properties&&0<t.geometry.coordinates.length}),function(t){var e=t.properties,n=t.geometry,i=n.coordinates,r=[];"Polygon"===n.type&&r.push({type:"polygon",exterior:i[0],interiors:i.slice(1)}),"MultiPolygon"===n.type&&A(i,function(t){t[0]&&r.push({type:"polygon",exterior:t[0],interiors:t.slice(1)})});var a=new Np(e.name,r,e.cp);return a.properties=e,a})}var Fp=Mr();function Vp(t){return"category"===t.type?function(t){var e=t.getLabelModel(),n=Wp(t,e);return!e.get("show")||t.scale.isBlank()?{labels:[],labelCategoryInterval:n.labelCategoryInterval}:n}(t):function(n){var t=n.scale.getTicks(),i=vp(n);return{labels:D(t,function(t,e){return{formattedLabel:i(t,e),rawLabel:n.scale.getLabel(t),tickValue:t}})}}(t)}function Hp(t,e){return"category"===t.type?function(t,e){var n,i,r=Gp(t,"ticks"),a=_p(e),o=Zp(r,a);if(o)return o;e.get("show")&&!t.scale.isBlank()||(n=[]);if(z(a))n=Yp(t,a,!0);else if("auto"===a){var s=Wp(t,t.getLabelModel());i=s.labelCategoryInterval,n=D(s.labels,function(t){return t.tickValue})}else n=Xp(t,i=a,!0);return Up(r,a,{ticks:n,tickCategoryInterval:i})}(t,e):{ticks:t.scale.getTicks()}}function Wp(t,e){var n,i=Gp(t,"labels"),r=_p(e),a=Zp(i,r);return a||Up(i,r,{labels:z(r)?Yp(t,r):Xp(t,n="auto"===r?function(t){var e=Fp(t).autoInterval;return null!=e?e:Fp(t).autoInterval=t.calculateCategoryInterval()}(t):r),labelCategoryInterval:n})}function Gp(t,e){return Fp(t)[e]||(Fp(t)[e]=[])}function Zp(t,e){for(var n=0;n<t.length;n++)if(t[n].key===e)return t[n].value}function Up(t,e,n){return t.push({key:e,value:n}),n}function Xp(t,e,n){var i=vp(t),r=t.scale,a=r.getExtent(),o=t.getLabelModel(),s=[],l=Math.max((e||0)+1,1),h=a[0],u=r.count();0!==h&&1<l&&2<u/l&&(h=Math.round(Math.ceil(h/l)*l));var c=xp(t),d=o.get("showMinLabel")||c,f=o.get("showMaxLabel")||c;d&&h!==a[0]&&g(a[0]);for(var p=h;p<=a[1];p+=l)g(p);function g(t){s.push(n?t:{formattedLabel:i(t),rawLabel:r.getLabel(t),tickValue:t})}return f&&p-l!==a[1]&&g(a[1]),s}function Yp(t,n,i){var r=t.scale,a=vp(t),o=[];return A(r.getTicks(),function(t){var e=r.getLabel(t);n(t,e)&&o.push(i?t:{formattedLabel:a(t),rawLabel:e,tickValue:t})}),o}function jp(t,e,n){this.dim=t,this.scale=e,this._extent=n||[0,0],this.inverse=!1,this.onBand=!1}var qp=[0,1];function $p(t,e){var n=(t[1]-t[0])/e/2;t[0]+=n,t[1]-=n}jp.prototype={constructor:jp,contain:function(t){var e=this._extent,n=Math.min(e[0],e[1]),i=Math.max(e[0],e[1]);return n<=t&&t<=i},containData:function(t){return this.contain(this.dataToCoord(t))},getExtent:function(){return this._extent.slice()},getPixelPrecision:function(t){return cl(t||this.scale.getExtent(),this._extent)},setExtent:function(t,e){var n=this._extent;n[0]=t,n[1]=e},dataToCoord:function(t,e){var n=this._extent,i=this.scale;return t=i.normalize(t),this.onBand&&"ordinal"===i.type&&$p(n=n.slice(),i.count()),al(t,qp,n,e)},coordToData:function(t,e){var n=this._extent,i=this.scale;this.onBand&&"ordinal"===i.type&&$p(n=n.slice(),i.count());var r=al(t,n,qp,e);return this.scale.scale(r)},pointToData:function(t,e){},getTicksCoords:function(t){var e=(t=t||{}).tickModel||this.getTickModel(),n=Hp(this,e),i=D(n.ticks,function(t){return{coord:this.dataToCoord(t),tickValue:t}},this),r=e.get("alignWithLabel");return function(t,e,n,i,r){var a=e.length;if(!t.onBand||i||!a)return;var o,s=t.getExtent();if(1===a)e[0].coord=s[0],o=e[1]={coord:s[0]};else{var l=e[1].coord-e[0].coord;A(e,function(t){t.coord-=l/2;var e=e||0;0<e%2&&(t.coord-=l/(2*(e+1)))}),o={coord:e[a-1].coord+l},e.push(o)}var h=s[0]>s[1];u(e[0].coord,s[0])&&(r?e[0].coord=s[0]:e.shift());r&&u(s[0],e[0].coord)&&e.unshift({coord:s[0]});u(s[1],o.coord)&&(r?o.coord=s[1]:e.pop());r&&u(o.coord,s[1])&&e.push({coord:s[1]});function u(t,e){return h?e<t:t<e}}(this,i,n.tickCategoryInterval,r,t.clamp),i},getViewLabels:function(){return Vp(this).labels},getLabelModel:function(){return this.model.getModel("axisLabel")},getTickModel:function(){return this.model.getModel("axisTick")},getBandWidth:function(){var t=this._extent,e=this.scale.getExtent(),n=e[1]-e[0]+(this.onBand?1:0);0===n&&(n=1);var i=Math.abs(t[1]-t[0]);return Math.abs(i)/n},isHorizontal:null,getRotate:null,calculateCategoryInterval:function(){return function(t){var e=function(t){var e=t.getLabelModel();return{axisRotate:t.getRotate?t.getRotate():t.isHorizontal&&!t.isHorizontal()?90:0,labelRotate:e.get("rotate")||0,font:e.getFont()}}(t),n=vp(t),i=(e.axisRotate-e.labelRotate)/180*Math.PI,r=t.scale,a=r.getExtent(),o=r.count();if(a[1]-a[0]<1)return 0;var s=1;40<o&&(s=Math.max(1,Math.floor(o/40)));for(var l=a[0],h=t.dataToCoord(l+1)-t.dataToCoord(l),u=Math.abs(h*Math.cos(i)),c=Math.abs(h*Math.sin(i)),d=0,f=0;l<=a[1];l+=s){var p,g,m=ii(n(l),e.font,"center","top");p=1.3*m.width,g=1.3*m.height,d=Math.max(d,p,7),f=Math.max(f,g,7)}var v=d/u,y=f/c;isNaN(v)&&(v=1/0),isNaN(y)&&(y=1/0);var _=Math.max(0,Math.floor(Math.min(v,y))),x=Fp(t.model),w=x.lastAutoInterval,b=x.lastTickCount;return null!=w&&null!=b&&Math.abs(w-_)<=1&&Math.abs(b-o)<=1&&_<w?_=w:(x.lastTickCount=o,x.lastAutoInterval=_),_}(this)}};var Kp=Bp,Qp={};A(["map","each","filter","indexOf","inherits","reduce","filter","bind","curry","isArray","isString","isObject","isFunction","extend","defaults","clone","merge"],function(t){Qp[t]=tt[t]});var Jp={};function tg(t,e){var n=t.mapDimension("defaultedLabel",!0),i=n.length;if(1===i)return su(t,e,n[0]);if(i){for(var r=[],a=0;a<n.length;a++){var o=su(t,e,n[a]);r.push(o)}return r.join(" ")}}function eg(t,e,n){yn.call(this),this.updateData(t,e,n)}A(["extendShape","extendPath","makePath","makeImage","mergePath","resizePath","createIcon","setHoverStyle","setLabelStyle","setTextStyle","setText","getFont","updateProps","initProps","getTransform","clipPointsByRect","clipRectByRect","Group","Image","Text","Circle","Sector","Ring","Polygon","Polyline","Rect","Line","BezierCurve","Arc","IncrementalDisplayable","CompoundPath","LinearGradient","RadialGradient","BoundingRect"],function(t){Jp[t]=Xs[t]}),Iu.extend({type:"series.line",dependencies:["grid","polar"],getInitialData:function(t,e){return Cf(this.getSource(),this)},defaultOption:{zlevel:0,z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,hoverAnimation:!0,clipOverflow:!0,label:{position:"top"},lineStyle:{width:2,type:"solid"},step:!1,smooth:!1,smoothMonotone:null,symbol:"emptyCircle",symbolSize:4,symbolRotate:null,showSymbol:!0,showAllSymbol:"auto",connectNulls:!1,sampling:"none",animationEasing:"linear",progressive:0,hoverLayerThreshold:1/0}});var ng=eg.prototype,ig=eg.getSymbolSize=function(t,e){var n=t.getItemVisual(e,"symbolSize");return n instanceof Array?n.slice():[+n,+n]};function rg(t){return[t[0]/2,t[1]/2]}function ag(t,e){this.parent.drift(t,e)}ng._createSymbol=function(t,e,n,i,r){this.removeAll();var a=kp(t,-1,-1,2,2,e.getItemVisual(n,"color"),r);a.attr({z2:100,culling:!0,scale:rg(i)}),a.drift=ag,this._symbolType=t,this.add(a)},ng.stopSymbolAnimation=function(t){this.childAt(0).stopAnimation(t)},ng.getSymbolPath=function(){return this.childAt(0)},ng.getScale=function(){return this.childAt(0).scale},ng.highlight=function(){this.childAt(0).trigger("emphasis")},ng.downplay=function(){this.childAt(0).trigger("normal")},ng.setZ=function(t,e){var n=this.childAt(0);n.zlevel=t,n.z=e},ng.setDraggable=function(t){var e=this.childAt(0);e.draggable=t,e.cursor=t?"move":e.cursor},ng.updateData=function(t,e,n){this.silent=!1;var i=t.getItemVisual(e,"symbol")||"circle",r=t.hostModel,a=ig(t,e),o=i!==this._symbolType;if(o){var s=t.getItemVisual(e,"symbolKeepAspect");this._createSymbol(i,t,e,a,s)}else{(l=this.childAt(0)).silent=!1,Ns(l,{scale:rg(a)},r,e)}if(this._updateCommon(t,e,a,n),o){var l=this.childAt(0),h=n&&n.fadeIn,u={scale:l.scale.slice()};h&&(u.style={opacity:l.style.opacity}),l.scale=[0,0],h&&(l.style.opacity=0),Rs(l,u,r,e)}this._seriesModel=r};var og=["itemStyle"],sg=["emphasis","itemStyle"],lg=["label"],hg=["emphasis","label"];function ug(t,e){if(!this.incremental&&!this.useHoverLayer)if("emphasis"===e){var n=this.__symbolOriginalScale,i=n[1]/n[0],r={scale:[Math.max(1.1*n[0],n[0]+3),Math.max(1.1*n[1],n[1]+3*i)]};this.animateTo(r,400,"elasticOut")}else"normal"===e&&this.animateTo({scale:this.__symbolOriginalScale},400,"elasticOut")}function cg(t){this.group=new yn,this._symbolCtor=t||eg}ng._updateCommon=function(n,t,e,i){var r=this.childAt(0),a=n.hostModel,o=n.getItemVisual(t,"color");"image"!==r.type&&r.useStyle({strokeNoScale:!0});var s=i&&i.itemStyle,l=i&&i.hoverItemStyle,h=i&&i.symbolRotate,u=i&&i.symbolOffset,c=i&&i.labelModel,d=i&&i.hoverLabelModel,f=i&&i.hoverAnimation,p=i&&i.cursorStyle;if(!i||n.hasItemOption){var g=i&&i.itemModel?i.itemModel:n.getItemModel(t);s=g.getModel(og).getItemStyle(["color"]),l=g.getModel(sg).getItemStyle(),h=g.getShallow("symbolRotate"),u=g.getShallow("symbolOffset"),c=g.getModel(lg),d=g.getModel(hg),f=g.getShallow("hoverAnimation"),p=g.getShallow("cursor")}else l=I({},l);var m=r.style;r.attr("rotation",(h||0)*Math.PI/180||0),u&&r.attr("position",[ol(u[0],e[0]),ol(u[1],e[1])]),p&&r.attr("cursor",p),r.setColor(o,i&&i.symbolInnerColor),r.setStyle(s);var v=n.getItemVisual(t,"opacity");null!=v&&(m.opacity=v);var y=n.getItemVisual(t,"liftZ"),_=r.__z2Origin;null!=y?null==_&&(r.__z2Origin=r.z2,r.z2+=y):null!=_&&(r.z2=_,r.__z2Origin=null);var x=i&&i.useNameLabel;Ts(m,l,c,d,{labelFetcher:a,labelDataIndex:t,defaultText:function(t,e){return x?n.getName(t):tg(n,t)},isRectText:!0,autoColor:o}),r.__symbolOriginalScale=rg(e),r.hoverStyle=l,r.highDownOnUpdate=f&&a.isAnimationEnabled()?ug:null,Ss(r)},ng.fadeOut=function(t,e){var n=this.childAt(0);this.silent=n.silent=!0,e&&e.keepLabel||(n.style.text=null),Ns(n,{style:{opacity:0},scale:[0,0]},this._seriesModel,this.dataIndex,t)},w(eg,yn);var dg=cg.prototype;function fg(t,e,n,i){return e&&!isNaN(e[0])&&!isNaN(e[1])&&!(i.isIgnore&&i.isIgnore(n))&&!(i.clipShape&&!i.clipShape.contain(e[0],e[1]))&&"none"!==t.getItemVisual(n,"symbol")}function pg(t){return null==t||N(t)||(t={isIgnore:t}),t||{}}function gg(t){var e=t.hostModel;return{itemStyle:e.getModel("itemStyle").getItemStyle(["color"]),hoverItemStyle:e.getModel("emphasis.itemStyle").getItemStyle(),symbolRotate:e.get("symbolRotate"),symbolOffset:e.get("symbolOffset"),hoverAnimation:e.get("hoverAnimation"),labelModel:e.getModel("label"),hoverLabelModel:e.getModel("emphasis.label"),cursorStyle:e.get("cursor")}}function mg(t,e,n){var i,r=t.getBaseAxis(),a=t.getOtherAxis(r),o=function(t,e){var n=0,i=t.scale.getExtent();"start"===e?n=i[0]:"end"===e?n=i[1]:0<i[0]?n=i[0]:i[1]<0&&(n=i[1]);return n}(a,n),s=r.dim,l=a.dim,h=e.mapDimension(l),u=e.mapDimension(s),c="x"===l||"radius"===l?1:0,d=D(t.dimensions,function(t){return e.mapDimension(t)}),f=e.getCalculationInfo("stackResultDimension");return(i|=Mf(e,d[0]))&&(d[0]=f),(i|=Mf(e,d[1]))&&(d[1]=f),{dataDimsForPoint:d,valueStart:o,valueAxisDim:l,baseAxisDim:s,stacked:!!i,valueDim:h,baseDim:u,baseDataOffset:c,stackedOverDimension:e.getCalculationInfo("stackedOverDimension")}}function vg(t,e,n,i){var r=NaN;t.stacked&&(r=n.get(n.getCalculationInfo("stackedOverDimension"),i)),isNaN(r)&&(r=t.valueStart);var a=t.baseDataOffset,o=[];return o[a]=n.get(t.baseDim,i),o[1-a]=r,e.dataToPoint(o)}dg.updateData=function(r,a){a=pg(a);var o=this.group,s=r.hostModel,l=this._data,h=this._symbolCtor,u=gg(r);l||o.removeAll(),r.diff(l).add(function(t){var e=r.getItemLayout(t);if(fg(r,e,t,a)){var n=new h(r,t,u);n.attr("position",e),r.setItemGraphicEl(t,n),o.add(n)}}).update(function(t,e){var n=l.getItemGraphicEl(e),i=r.getItemLayout(t);fg(r,i,t,a)?(n?(n.updateData(r,t,u),Ns(n,{position:i},s)):(n=new h(r,t)).attr("position",i),o.add(n),r.setItemGraphicEl(t,n)):o.remove(n)}).remove(function(t){var e=l.getItemGraphicEl(t);e&&e.fadeOut(function(){o.remove(e)})}).execute(),this._data=r},dg.isPersistent=function(){return!0},dg.updateLayout=function(){var i=this._data;i&&i.eachItemGraphicEl(function(t,e){var n=i.getItemLayout(e);t.attr("position",n)})},dg.incrementalPrepareUpdate=function(t){this._seriesScope=gg(t),this._data=null,this.group.removeAll()},dg.incrementalUpdate=function(t,e,n){function i(t){t.isGroup||(t.incremental=t.useHoverLayer=!0)}n=pg(n);for(var r=t.start;r<t.end;r++){var a=e.getItemLayout(r);if(fg(e,a,r,n)){var o=new this._symbolCtor(e,r,this._seriesScope);o.traverse(i),o.attr("position",a),this.group.add(o),e.setItemGraphicEl(r,o)}}},dg.remove=function(t){var e=this.group,n=this._data;n&&t?n.eachItemGraphicEl(function(t){t.fadeOut(function(){e.remove(t)})}):e.removeAll()};var yg=_t,_g=xt,xg=ot,wg=it,bg=[],Sg=[],Mg=[];function Ig(t){return isNaN(t[0])||isNaN(t[1])}function Cg(t,e,n,i,r,a,o,s,l,h){return"none"!==h&&h?function(t,e,n,i,r,a,o,s,l,h,u){for(var c=0,d=n,f=0;f<i;f++){var p=e[d];if(r<=d||d<0)break;if(Ig(p)){if(u){d+=a;continue}break}if(d===n)t[0<a?"moveTo":"lineTo"](p[0],p[1]);else if(0<l){var g=e[c],m="y"===h?1:0,v=(p[m]-g[m])*l;wg(Sg,g),Sg[m]=g[m]+v,wg(Mg,p),Mg[m]=p[m]-v,t.bezierCurveTo(Sg[0],Sg[1],Mg[0],Mg[1],p[0],p[1])}else t.lineTo(p[0],p[1]);c=d,d+=a}return f}.apply(this,arguments):function(t,e,n,i,r,a,o,s,l,h,u){for(var c=0,d=n,f=0;f<i;f++){var p=e[d];if(r<=d||d<0)break;if(Ig(p)){if(u){d+=a;continue}break}if(d===n)t[0<a?"moveTo":"lineTo"](p[0],p[1]),wg(Sg,p);else if(0<l){var g=d+a,m=e[g];if(u)for(;m&&Ig(e[g]);)m=e[g+=a];var v=.5,y=e[c];if(!(m=e[g])||Ig(m))wg(Mg,p);else{var _,x;if(Ig(m)&&!u&&(m=p),st(bg,m,y),"x"===h||"y"===h){var w="x"===h?0:1;_=Math.abs(p[w]-y[w]),x=Math.abs(p[w]-m[w])}else _=gt(p,y),x=gt(p,m);xg(Mg,p,bg,-l*(1-(v=x/(x+_))))}yg(Sg,Sg,s),_g(Sg,Sg,o),yg(Mg,Mg,s),_g(Mg,Mg,o),t.bezierCurveTo(Sg[0],Sg[1],Mg[0],Mg[1],p[0],p[1]),xg(Sg,p,bg,l*v)}else t.lineTo(p[0],p[1]);c=d,d+=a}return f}.apply(this,arguments)}function Tg(t,e){var n=[1/0,1/0],i=[-1/0,-1/0];if(e)for(var r=0;r<t.length;r++){var a=t[r];a[0]<n[0]&&(n[0]=a[0]),a[1]<n[1]&&(n[1]=a[1]),a[0]>i[0]&&(i[0]=a[0]),a[1]>i[1]&&(i[1]=a[1])}return{min:e?n:i,max:e?i:n}}var Ag=no.extend({type:"ec-polyline",shape:{points:[],smooth:0,smoothConstraint:!0,smoothMonotone:null,connectNulls:!1},style:{fill:null,stroke:"#000"},brush:bo(no.prototype.brush),buildPath:function(t,e){var n=e.points,i=0,r=n.length,a=Tg(n,e.smoothConstraint);if(e.connectNulls){for(;0<r&&Ig(n[r-1]);r--);for(;i<r&&Ig(n[i]);i++);}for(;i<r;)i+=Cg(t,n,i,r,r,1,a.min,a.max,e.smooth,e.smoothMonotone,e.connectNulls)+1}}),Dg=no.extend({type:"ec-polygon",shape:{points:[],stackedOnPoints:[],smooth:0,stackedOnSmooth:0,smoothConstraint:!0,smoothMonotone:null,connectNulls:!1},brush:bo(no.prototype.brush),buildPath:function(t,e){var n=e.points,i=e.stackedOnPoints,r=0,a=n.length,o=e.smoothMonotone,s=Tg(n,e.smoothConstraint),l=Tg(i,e.smoothConstraint);if(e.connectNulls){for(;0<a&&Ig(n[a-1]);a--);for(;r<a&&Ig(n[r]);r++);}for(;r<a;){var h=Cg(t,n,r,a,a,1,s.min,s.max,e.smooth,o,e.connectNulls);Cg(t,i,r+h-1,h,a,-1,l.min,l.max,e.stackedOnSmooth,o,e.connectNulls),r+=h+1,t.closePath()}}});function kg(t,e){if(t.length===e.length){for(var n=0;n<t.length;n++){var i=t[n],r=e[n];if(i[0]!==r[0]||i[1]!==r[1])return}return!0}}function Pg(t){return"number"==typeof t?t:t?.5:0}function Lg(t){var e=t.getGlobalExtent();if(t.onBand){var n=t.getBandWidth()/2-1,i=e[1]>e[0]?1:-1;e[0]+=i*n,e[1]-=i*n}return e}function Og(t,e,n,i){return"polar"===t.type?function(t,e,n,i){var r=t.getAngleAxis(),a=t.getRadiusAxis().getExtent().slice();a[0]>a[1]&&a.reverse();var o=r.getExtent(),s=Math.PI/180;n&&(a[0]-=.5,a[1]+=.5);var l=new Io({shape:{cx:sl(t.cx,1),cy:sl(t.cy,1),r0:sl(a[0],1),r:sl(a[1],1),startAngle:-o[0]*s,endAngle:-o[1]*s,clockwise:r.inverse}});return e&&(l.shape.endAngle=-o[0]*s,Rs(l,{shape:{endAngle:-o[1]*s}},i)),l}(t,e,n,i):function(t,e,n,i){var r=Lg(t.getAxis("x")),a=Lg(t.getAxis("y")),o=t.getBaseAxis().isHorizontal(),s=Math.min(r[0],r[1]),l=Math.min(a[0],a[1]),h=Math.max(r[0],r[1])-s,u=Math.max(a[0],a[1])-l;if(n)s-=.5,h+=.5,l-=.5,u+=.5;else{var c=i.get("lineStyle.width")||2,d=i.get("clipOverflow")?c/2:Math.max(h,u);o?(l-=d,u+=2*d):(s-=d,h+=2*d)}var f=new No({shape:{x:s,y:l,width:h,height:u}});return e&&(f.shape[o?"width":"height"]=0,Rs(f,{shape:{width:h,height:u}},i)),f}(t,e,n,i)}function zg(t,e,n){for(var i=e.getBaseAxis(),r="x"===i.dim||"radius"===i.dim?0:1,a=[],o=0;o<t.length-1;o++){var s=t[o+1],l=t[o];a.push(l);var h=[];switch(n){case"end":h[r]=s[r],h[1-r]=l[1-r],a.push(h);break;case"middle":var u=(l[r]+s[r])/2,c=[];h[r]=c[r]=u,h[1-r]=l[1-r],c[1-r]=s[1-r],a.push(h),a.push(c);break;default:h[r]=l[r],h[1-r]=s[1-r],a.push(h)}}return t[o]&&a.push(t[o]),a}function Eg(t,e,n){var i=t.get("showAllSymbol"),r="auto"===i;if(!i||r){var a=n.getAxesByScale("ordinal")[0];if(a&&(!r||!function(t,e){var n=t.getExtent(),i=Math.abs(n[1]-n[0])/t.scale.count();isNaN(i)&&(i=0);for(var r=e.count(),a=Math.max(1,Math.round(r/5)),o=0;o<r;o+=a)if(1.5*eg.getSymbolSize(e,o)[t.isHorizontal()?1:0]>i)return!1;return!0}(a,e))){var o=e.mapDimension(a.dim),s={};return A(a.getViewLabels(),function(t){s[t.tickValue]=1}),function(t){return!s.hasOwnProperty(e.get(o,t))}}}}Bu.extend({type:"line",init:function(){var t=new yn,e=new cg;this.group.add(e.group),this._symbolDraw=e,this._lineGroup=t},render:function(t,e,n){var i=t.coordinateSystem,r=this.group,a=t.getData(),o=t.getModel("lineStyle"),s=t.getModel("areaStyle"),l=a.mapArray(a.getItemLayout),h="polar"===i.type,u=this._coordSys,c=this._symbolDraw,d=this._polyline,f=this._polygon,p=this._lineGroup,g=t.get("animation"),m=!s.isEmpty(),v=s.get("origin"),y=function(t,e,n){if(!n.valueDim)return[];for(var i=[],r=0,a=e.count();r<a;r++)i.push(vg(n,t,e,r));return i}(i,a,mg(i,a,v)),_=t.get("showSymbol"),x=_&&!h&&Eg(t,a,i),w=this._data;w&&w.eachItemGraphicEl(function(t,e){t.__temp&&(r.remove(t),w.setItemGraphicEl(e,null))}),_||c.remove(),r.add(p);var b=!h&&t.get("step");d&&u.type===i.type&&b===this._step?(m&&!f?f=this._newPolygon(l,y,i,g):f&&!m&&(p.remove(f),f=this._polygon=null),p.setClipPath(Og(i,!1,!1,t)),_&&c.updateData(a,{isIgnore:x,clipShape:Og(i,!1,!0,t)}),a.eachItemGraphicEl(function(t){t.stopAnimation(!0)}),kg(this._stackedOnPoints,y)&&kg(this._points,l)||(g?this._updateAnimation(a,y,i,n,b,v):(b&&(l=zg(l,i,b),y=zg(y,i,b)),d.setShape({points:l}),f&&f.setShape({points:l,stackedOnPoints:y})))):(_&&c.updateData(a,{isIgnore:x,clipShape:Og(i,!1,!0,t)}),b&&(l=zg(l,i,b),y=zg(y,i,b)),d=this._newPolyline(l,i,g),m&&(f=this._newPolygon(l,y,i,g)),p.setClipPath(Og(i,!0,!1,t)));var S=function(t,e){var n=t.getVisual("visualMeta");if(n&&n.length&&t.count()&&"cartesian2d"===e.type){for(var i,r,a=n.length-1;0<=a;a--){var o=n[a].dimension,s=t.dimensions[o],l=t.getDimensionInfo(s);if("x"===(i=l&&l.coordDim)||"y"===i){r=n[a];break}}if(r){var h=e.getAxis(i),u=D(r.stops,function(t){return{coord:h.toGlobalCoord(h.dataToCoord(t.value)),color:t.color}}),c=u.length,d=r.outerColors.slice();c&&u[0].coord>u[c-1].coord&&(u.reverse(),d.reverse());var f=u[0].coord-10,p=u[c-1].coord+10,g=p-f;if(g<.001)return"transparent";A(u,function(t){t.offset=(t.coord-f)/g}),u.push({offset:c?u[c-1].offset:.5,color:d[1]||"transparent"}),u.unshift({offset:c?u[0].offset:.5,color:d[0]||"transparent"});var m=new Uo(0,0,0,0,u,!0);return m[i]=f,m[i+"2"]=p,m}}}(a,i)||a.getVisual("color");d.useStyle(T(o.getLineStyle(),{fill:"none",stroke:S,lineJoin:"bevel"}));var M=t.get("smooth");if(M=Pg(t.get("smooth")),d.setShape({smooth:M,smoothMonotone:t.get("smoothMonotone"),connectNulls:t.get("connectNulls")}),f){var I=a.getCalculationInfo("stackedOnSeries"),C=0;f.useStyle(T(s.getAreaStyle(),{fill:S,opacity:.7,lineJoin:"bevel"})),I&&(C=Pg(I.get("smooth"))),f.setShape({smooth:M,stackedOnSmooth:C,smoothMonotone:t.get("smoothMonotone"),connectNulls:t.get("connectNulls")})}this._data=a,this._coordSys=i,this._stackedOnPoints=y,this._points=l,this._step=b,this._valueOrigin=v},dispose:function(){},highlight:function(t,e,n,i){var r=t.getData(),a=Sr(r,i);if(!(a instanceof Array)&&null!=a&&0<=a){var o=r.getItemGraphicEl(a);if(!o){var s=r.getItemLayout(a);if(!s)return;(o=new eg(r,a)).position=s,o.setZ(t.get("zlevel"),t.get("z")),o.ignore=isNaN(s[0])||isNaN(s[1]),o.__temp=!0,r.setItemGraphicEl(a,o),o.stopSymbolAnimation(!0),this.group.add(o)}o.highlight()}else Bu.prototype.highlight.call(this,t,e,n,i)},downplay:function(t,e,n,i){var r=t.getData(),a=Sr(r,i);if(null!=a&&0<=a){var o=r.getItemGraphicEl(a);o&&(o.__temp?(r.setItemGraphicEl(a,null),this.group.remove(o)):o.downplay())}else Bu.prototype.downplay.call(this,t,e,n,i)},_newPolyline:function(t){var e=this._polyline;return e&&this._lineGroup.remove(e),e=new Ag({shape:{points:t},silent:!0,z2:10}),this._lineGroup.add(e),this._polyline=e},_newPolygon:function(t,e){var n=this._polygon;return n&&this._lineGroup.remove(n),n=new Dg({shape:{points:t,stackedOnPoints:e},silent:!0}),this._lineGroup.add(n),this._polygon=n},_updateAnimation:function(t,e,n,i,r,a){var o=this._polyline,s=this._polygon,l=t.hostModel,h=function(t,e,n,i,r,a,o,s){for(var l=function(t,e){var n=[];return e.diff(t).add(function(t){n.push({cmd:"+",idx:t})}).update(function(t,e){n.push({cmd:"=",idx:e,idx1:t})}).remove(function(t){n.push({cmd:"-",idx:t})}).execute(),n}(t,e),h=[],u=[],c=[],d=[],f=[],p=[],g=[],m=mg(r,e,o),v=mg(a,t,s),y=0;y<l.length;y++){var _=l[y],x=!0;switch(_.cmd){case"=":var w=t.getItemLayout(_.idx),b=e.getItemLayout(_.idx1);(isNaN(w[0])||isNaN(w[1]))&&(w=b.slice()),h.push(w),u.push(b),c.push(n[_.idx]),d.push(i[_.idx1]),g.push(e.getRawIndex(_.idx1));break;case"+":var S=_.idx;h.push(r.dataToPoint([e.get(m.dataDimsForPoint[0],S),e.get(m.dataDimsForPoint[1],S)])),u.push(e.getItemLayout(S).slice()),c.push(vg(m,r,e,S)),d.push(i[S]),g.push(e.getRawIndex(S));break;case"-":S=_.idx;var M=t.getRawIndex(S);M!==S?(h.push(t.getItemLayout(S)),u.push(a.dataToPoint([t.get(v.dataDimsForPoint[0],S),t.get(v.dataDimsForPoint[1],S)])),c.push(n[S]),d.push(vg(v,a,t,S)),g.push(M)):x=!1}x&&(f.push(_),p.push(p.length))}p.sort(function(t,e){return g[t]-g[e]});var I=[],C=[],T=[],A=[],D=[];for(y=0;y<p.length;y++){S=p[y];I[y]=h[S],C[y]=u[S],T[y]=c[S],A[y]=d[S],D[y]=f[S]}return{current:I,next:C,stackedOnCurrent:T,stackedOnNext:A,status:D}}(this._data,t,this._stackedOnPoints,e,this._coordSys,n,this._valueOrigin,a),u=h.current,c=h.stackedOnCurrent,d=h.next,f=h.stackedOnNext;r&&(u=zg(h.current,n,r),c=zg(h.stackedOnCurrent,n,r),d=zg(h.next,n,r),f=zg(h.stackedOnNext,n,r)),o.shape.__points=h.current,o.shape.points=u,Ns(o,{shape:{points:d}},l),s&&(s.setShape({points:u,stackedOnPoints:c}),Ns(s,{shape:{points:d,stackedOnPoints:f}},l));for(var p=[],g=h.status,m=0;m<g.length;m++){if("="===g[m].cmd){var v=t.getItemGraphicEl(g[m].idx1);v&&p.push({el:v,ptIdx:m})}}o.animators&&o.animators.length&&o.animators[0].during(function(){for(var t=0;t<p.length;t++){p[t].el.attr("position",o.shape.__points[p[t].ptIdx])}})},remove:function(t){var n=this.group,i=this._data;this._lineGroup.removeAll(),this._symbolDraw.remove(!0),i&&i.eachItemGraphicEl(function(t,e){t.__temp&&(n.remove(t),i.setItemGraphicEl(e,null))}),this._polyline=this._polygon=this._coordSys=this._points=this._stackedOnPoints=this._data=null}});function Ng(t,o,s){return{seriesType:t,performRawSeries:!0,reset:function(l,t,e){var n=l.getData(),h=l.get("symbol"),u=l.get("symbolSize"),i=l.get("symbolKeepAspect"),c=z(h),d=z(u),f=c||d,r=!c&&h?h:o,a=d?null:u;if(n.setVisual({legendSymbol:s||r,symbol:r,symbolSize:a,symbolKeepAspect:i}),!t.isSeriesFiltered(l))return{dataEach:n.hasItemOption||f?function(t,e){if(f){var n=l.getRawValue(e),i=l.getDataParams(e);c&&t.setItemVisual(e,"symbol",h(n,i)),d&&t.setItemVisual(e,"symbolSize",u(n,i))}if(t.hasItemOption){var r=t.getItemModel(e),a=r.getShallow("symbol",!0),o=r.getShallow("symbolSize",!0),s=r.getShallow("symbolKeepAspect",!0);null!=a&&t.setItemVisual(e,"symbol",a),null!=o&&t.setItemVisual(e,"symbolSize",o),null!=s&&t.setItemVisual(e,"symbolKeepAspect",s)}}:null}}}}function Rg(t){return{seriesType:t,plan:Eu(),reset:function(t){var e=t.getData(),c=t.coordinateSystem,d=t.pipelineContext.large;if(c){var f=D(c.dimensions,function(t){return e.mapDimension(t)}).slice(0,2),p=f.length,n=e.getCalculationInfo("stackResultDimension");return Mf(e,f[0])&&(f[0]=n),Mf(e,f[1])&&(f[1]=n),p&&{progress:function(t,e){for(var n=t.end-t.start,i=d&&new Float32Array(n*p),r=t.start,a=0,o=[],s=[];r<t.end;r++){var l;if(1===p){var h=e.get(f[0],r);l=!isNaN(h)&&c.dataToPoint(h,null,s)}else{h=o[0]=e.get(f[0],r);var u=o[1]=e.get(f[1],r);l=!isNaN(h)&&!isNaN(u)&&c.dataToPoint(o,null,s)}d?(i[a++]=l?l[0]:NaN,i[a++]=l?l[1]:NaN):e.setItemLayout(r,l&&l.slice()||[NaN,NaN])}d&&e.setLayout("symbolPoints",i)}}}}}}function Bg(t,e){return Math.round(t.length/2)}var Fg={average:function(t){for(var e=0,n=0,i=0;i<t.length;i++)isNaN(t[i])||(e+=t[i],n++);return 0===n?NaN:e/n},sum:function(t){for(var e=0,n=0;n<t.length;n++)e+=t[n]||0;return e},max:function(t){for(var e=-1/0,n=0;n<t.length;n++)t[n]>e&&(e=t[n]);return isFinite(e)?e:NaN},min:function(t){for(var e=1/0,n=0;n<t.length;n++)t[n]<e&&(e=t[n]);return isFinite(e)?e:NaN},nearest:function(t){return t[0]}};function Vg(t){return this._axes[t]}function Hg(t){this._axes={},this._dimList=[],this.name=t||""}function Wg(t){Hg.call(this,t)}Hg.prototype={constructor:Hg,type:"cartesian",getAxis:function(t){return this._axes[t]},getAxes:function(){return D(this._dimList,Vg,this)},getAxesByScale:function(e){return e=e.toLowerCase(),C(this.getAxes(),function(t){return t.scale.type===e})},addAxis:function(t){var e=t.dim;this._axes[e]=t,this._dimList.push(e)},dataToCoord:function(t){return this._dataCoordConvert(t,"dataToCoord")},coordToData:function(t){return this._dataCoordConvert(t,"coordToData")},_dataCoordConvert:function(t,e){for(var n=this._dimList,i=t instanceof Array?[]:{},r=0;r<n.length;r++){var a=n[r],o=this._axes[a];i[a]=o[e](t[a])}return i}},Wg.prototype={constructor:Wg,type:"cartesian2d",dimensions:["x","y"],getBaseAxis:function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAxis("x")},containPoint:function(t){var e=this.getAxis("x"),n=this.getAxis("y");return e.contain(e.toLocalCoord(t[0]))&&n.contain(n.toLocalCoord(t[1]))},containData:function(t){return this.getAxis("x").containData(t[0])&&this.getAxis("y").containData(t[1])},dataToPoint:function(t,e,n){var i=this.getAxis("x"),r=this.getAxis("y");return(n=n||[])[0]=i.toGlobalCoord(i.dataToCoord(t[0])),n[1]=r.toGlobalCoord(r.dataToCoord(t[1])),n},clampData:function(t,e){var n=this.getAxis("x").scale,i=this.getAxis("y").scale,r=n.getExtent(),a=i.getExtent(),o=n.parse(t[0]),s=i.parse(t[1]);return(e=e||[])[0]=Math.min(Math.max(Math.min(r[0],r[1]),o),Math.max(r[0],r[1])),e[1]=Math.min(Math.max(Math.min(a[0],a[1]),s),Math.max(a[0],a[1])),e},pointToData:function(t,e){var n=this.getAxis("x"),i=this.getAxis("y");return(e=e||[])[0]=n.coordToData(n.toLocalCoord(t[0])),e[1]=i.coordToData(i.toLocalCoord(t[1])),e},getOtherAxis:function(t){return this.getAxis("x"===t.dim?"y":"x")}},w(Wg,Hg);function Gg(t,e,n,i,r){jp.call(this,t,e,n),this.type=i||"value",this.position=r||"bottom"}Gg.prototype={constructor:Gg,index:0,getAxesOnZeroOf:null,model:null,isHorizontal:function(){var t=this.position;return"top"===t||"bottom"===t},getGlobalExtent:function(t){var e=this.getExtent();return e[0]=this.toGlobalCoord(e[0]),e[1]=this.toGlobalCoord(e[1]),t&&e[0]>e[1]&&e.reverse(),e},getOtherAxis:function(){this.grid.getOtherAxis()},pointToData:function(t,e){return this.coordToData(this.toLocalCoord(t["x"===this.dim?0:1]),e)},toLocalCoord:null,toGlobalCoord:null},w(Gg,jp);var Zg={show:!0,zlevel:0,z:0,inverse:!1,name:"",nameLocation:"end",nameRotate:null,nameTruncate:{maxWidth:null,ellipsis:"...",placeholder:"."},nameTextStyle:{},nameGap:15,silent:!1,triggerEvent:!1,tooltip:{show:!1},axisPointer:{},axisLine:{show:!0,onZero:!0,onZeroAxisIndex:null,lineStyle:{color:"#333",width:1,type:"solid"},symbol:["none","none"],symbolSize:[10,15]},axisTick:{show:!0,inside:!1,length:5,lineStyle:{width:1}},axisLabel:{show:!0,inside:!1,rotate:0,showMinLabel:null,showMaxLabel:null,margin:8,fontSize:12},splitLine:{show:!0,lineStyle:{color:["#ccc"],width:1,type:"solid"}},splitArea:{show:!1,areaStyle:{color:["rgba(250,250,250,0.3)","rgba(200,200,200,0.3)"]}}},Ug={};Ug.categoryAxis=m({boundaryGap:!0,deduplication:null,splitLine:{show:!1},axisTick:{alignWithLabel:!1,interval:"auto"},axisLabel:{interval:"auto"}},Zg),Ug.valueAxis=m({boundaryGap:[0,0],splitNumber:5},Zg),Ug.timeAxis=T({scale:!0,min:"dataMin",max:"dataMax"},Ug.valueAxis),Ug.logAxis=T({scale:!0,logBase:10},Ug.valueAxis);function Xg(a,t,o,e){A(Yg,function(r){t.extend({type:a+"Axis."+r,mergeDefaultAndTheme:function(t,e){var n=this.layoutMode,i=n?Zl(t):{};m(t,e.getTheme().get(r+"Axis")),m(t,this.getDefaultOption()),t.type=o(a,t),n&&Gl(t,i,n)},optionUpdated:function(){"category"===this.option.type&&(this.__ordinalMeta=Af.createByAxisModel(this))},getCategories:function(t){var e=this.option;if("category"===e.type)return t?e.data:this.__ordinalMeta.categories},getOrdinalMeta:function(){return this.__ordinalMeta},defaultOption:p([{},Ug[r+"Axis"],e],!0)})}),$l.registerSubTypeDefaulter(a+"Axis",P(o,a))}var Yg=["value","category","time","log"],jg=$l.extend({type:"cartesian2dAxis",axis:null,init:function(){jg.superApply(this,"init",arguments),this.resetRange()},mergeOption:function(){jg.superApply(this,"mergeOption",arguments),this.resetRange()},restoreData:function(){jg.superApply(this,"restoreData",arguments),this.resetRange()},getCoordSysModel:function(){return this.ecModel.queryComponents({mainType:"grid",index:this.option.gridIndex,id:this.option.gridId})[0]}});function qg(t,e){return e.type||(e.data?"category":"value")}m(jg.prototype,wp);var $g={offset:0};function Kg(t,e){return t.getCoordSysModel()===e}function Qg(t,e,n){this._coordsMap={},this._coordsList=[],this._axesMap={},this._axesList=[],this._initCartesian(t,e,n),this.model=t}Xg("x",jg,qg,$g),Xg("y",jg,qg,$g),$l.extend({type:"grid",dependencies:["xAxis","yAxis"],layoutMode:"box",coordinateSystem:null,defaultOption:{show:!1,zlevel:0,z:0,left:"10%",top:60,right:"10%",bottom:60,containLabel:!1,backgroundColor:"rgba(0,0,0,0)",borderWidth:1,borderColor:"#ccc"}});var Jg=Qg.prototype;function tm(t,e,n,i){n.getAxesOnZeroOf=function(){return r?[r]:[]};var r,a=t[e],o=n.model,s=o.get("axisLine.onZero"),l=o.get("axisLine.onZeroAxisIndex");if(s){if(null!=l)em(a[l])&&(r=a[l]);else for(var h in a)if(a.hasOwnProperty(h)&&em(a[h])&&!i[u(a[h])]){r=a[h];break}r&&(i[u(r)]=!0)}function u(t){return t.dim+"_"+t.index}}function em(t){return t&&"category"!==t.type&&"time"!==t.type&&function(t){var e=t.scale.getExtent(),n=e[0],i=e[1];return!(0<n&&0<i||n<0&&i<0)}(t)}Jg.type="grid",Jg.axisPointerEnabled=!0,Jg.getRect=function(){return this._rect},Jg.update=function(t,e){var n=this._axesMap;this._updateScale(t,this.model),A(n.x,function(t){gp(t.scale,t.model)}),A(n.y,function(t){gp(t.scale,t.model)});var i={};A(n.x,function(t){tm(n,"y",t,i)}),A(n.y,function(t){tm(n,"x",t,i)}),this.resize(this.model,e)},Jg.resize=function(t,e,n){var r=Hl(t.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()});this._rect=r;var i=this._axesList;function a(){A(i,function(t){var e=t.isHorizontal(),n=e?[0,r.width]:[0,r.height],i=t.inverse?1:0;t.setExtent(n[i],n[1-i]),function(t,e){var n=t.getExtent(),i=n[0]+n[1];t.toGlobalCoord="x"===t.dim?function(t){return t+e}:function(t){return i-t+e},t.toLocalCoord="x"===t.dim?function(t){return t-e}:function(t){return i-t+e}}(t,e?r.x:r.y)})}a(),!n&&t.get("containLabel")&&(A(i,function(t){if(!t.model.get("axisLabel.inside")){var e=function(t){var e=t.model,n=t.scale;if(e.get("axisLabel.show")&&!n.isBlank()){var i,r,a="category"===t.type,o=n.getExtent();r=a?n.count():(i=n.getTicks()).length;var s,l,h,u,c,d,f,p,g,m=t.getLabelModel(),v=vp(t),y=1;40<r&&(y=Math.ceil(r/40));for(var _=0;_<r;_+=y){var x=v(i?i[_]:o[0]+_),w=m.getTextRect(x),b=(l=w,h=m.get("rotate")||0,void 0,u=h*Math.PI/180,c=l.plain(),d=c.width,f=c.height,p=d*Math.cos(u)+f*Math.sin(u),g=d*Math.sin(u)+f*Math.cos(u),new vn(c.x,c.y,p,g));s?s.union(b):s=b}return s}}(t);if(e){var n=t.isHorizontal()?"height":"width",i=t.model.get("axisLabel.margin");r[n]-=e[n]+i,"top"===t.position?r.y+=e.height+i:"left"===t.position&&(r.x+=e.width+i)}}}),a())},Jg.getAxis=function(t,e){var n=this._axesMap[t];if(null!=n){if(null==e)for(var i in n)if(n.hasOwnProperty(i))return n[i];return n[e]}},Jg.getAxes=function(){return this._axesList.slice()},Jg.getCartesian=function(t,e){if(null!=t&&null!=e){var n="x"+t+"y"+e;return this._coordsMap[n]}N(t)&&(e=t.yAxisIndex,t=t.xAxisIndex);for(var i=0,r=this._coordsList;i<r.length;i++)if(r[i].getAxis("x").index===t||r[i].getAxis("y").index===e)return r[i]},Jg.getCartesians=function(){return this._coordsList.slice()},Jg.convertToPixel=function(t,e,n){var i=this._findConvertTarget(t,e);return i.cartesian?i.cartesian.dataToPoint(n):i.axis?i.axis.toGlobalCoord(i.axis.dataToCoord(n)):null},Jg.convertFromPixel=function(t,e,n){var i=this._findConvertTarget(t,e);return i.cartesian?i.cartesian.pointToData(n):i.axis?i.axis.coordToData(i.axis.toLocalCoord(n)):null},Jg._findConvertTarget=function(t,e){var n,i,r=e.seriesModel,a=e.xAxisModel||r&&r.getReferringComponents("xAxis")[0],o=e.yAxisModel||r&&r.getReferringComponents("yAxis")[0],s=e.gridModel,l=this._coordsList;if(r)x(l,n=r.coordinateSystem)<0&&(n=null);else if(a&&o)n=this.getCartesian(a.componentIndex,o.componentIndex);else if(a)i=this.getAxis("x",a.componentIndex);else if(o)i=this.getAxis("y",o.componentIndex);else if(s){s.coordinateSystem===this&&(n=this._coordsList[0])}return{cartesian:n,axis:i}},Jg.containPoint=function(t){var e=this._coordsList[0];if(e)return e.containPoint(t)},Jg._initCartesian=function(o,t,e){var s={left:!1,right:!1,top:!1,bottom:!1},l={x:{},y:{}},h={x:0,y:0};if(t.eachComponent("xAxis",n("x"),this),t.eachComponent("yAxis",n("y"),this),!h.x||!h.y)return this._axesMap={},void(this._axesList=[]);function n(a){return function(t,e){if(Kg(t,o)){var n=t.get("position");"x"===a?"top"!==n&&"bottom"!==n&&(n=s.bottom?"top":"bottom"):"left"!==n&&"right"!==n&&(n=s.left?"right":"left"),s[n]=!0;var i=new Gg(a,mp(t),[0,0],t.get("type"),n),r="category"===i.type;i.onBand=r&&t.get("boundaryGap"),i.inverse=t.get("inverse"),(t.axis=i).model=t,i.grid=this,i.index=e,this._axesList.push(i),l[a][e]=i,h[a]++}}}A((this._axesMap=l).x,function(r,a){A(l.y,function(t,e){var n="x"+a+"y"+e,i=new Wg(n);i.grid=this,i.model=o,this._coordsMap[n]=i,this._coordsList.push(i),i.addAxis(r),i.addAxis(t)},this)},this)},Jg._updateScale=function(l,h){function u(e,n){A(e.mapDimension(n.dim,!0),function(t){n.scale.unionExtentFromData(e,If(e,t))})}A(this._axesList,function(t){t.scale.setExtent(1/0,-1/0)}),l.eachSeries(function(t){if(rm(t)){var e=im(t,l),n=e[0],i=e[1];if(!Kg(n,h)||!Kg(i,h))return;var r=this.getCartesian(n.componentIndex,i.componentIndex),a=t.getData(),o=r.getAxis("x"),s=r.getAxis("y");"list"===a.type&&(u(a,o,t),u(a,s,t))}},this)},Jg.getTooltipAxes=function(i){var r=[],a=[];return A(this.getCartesians(),function(t){var e=null!=i&&"auto"!==i?t.getAxis(i):t.getBaseAxis(),n=t.getOtherAxis(e);x(r,e)<0&&r.push(e),x(a,n)<0&&a.push(n)}),{baseAxes:r,otherAxes:a}};var nm=["xAxis","yAxis"];function im(e){return D(nm,function(t){return e.getReferringComponents(t)[0]})}function rm(t){return"cartesian2d"===t.get("coordinateSystem")}Qg.create=function(i,r){var a=[];return i.eachComponent("grid",function(t,e){var n=new Qg(t,i,r);n.name="grid_"+e,n.resize(t,r,!0),t.coordinateSystem=n,a.push(n)}),i.eachSeries(function(t){if(rm(t)){var e=im(t),n=e[0],i=e[1],r=n.getCoordSysModel().coordinateSystem;t.coordinateSystem=r.getCartesian(n.componentIndex,i.componentIndex)}}),a},Qg.dimensions=Qg.prototype.dimensions=Wg.prototype.dimensions,Ch.register("cartesian2d",Qg);function am(t,e){this.opt=e,this.axisModel=t,T(e,{labelOffset:0,nameDirection:1,tickDirection:1,labelDirection:1,silent:!0}),this.group=new yn;var n=new yn({position:e.position.slice(),rotation:e.rotation});n.updateTransform(),this._transform=n.transform,this._dumbGroup=n}var om=Math.PI;am.prototype={constructor:am,hasBuilder:function(t){return!!sm[t]},add:function(t){sm[t].call(this)},getGroup:function(){return this.group}};var sm={axisLine:function(){var a=this.opt,t=this.axisModel;if(t.get("axisLine.show")){var e=this.axisModel.axis.getExtent(),n=this._transform,o=[e[0],0],i=[e[1],0];n&&(yt(o,o,n),yt(i,i,n));var s=I({lineCap:"round"},t.getModel("axisLine.lineStyle").getLineStyle());this.group.add(new Bo({anid:"line",subPixelOptimize:!0,shape:{x1:o[0],y1:o[1],x2:i[0],y2:i[1]},style:s,strokeContainThreshold:a.strokeContainThreshold||5,silent:!0,z2:1}));var l=t.get("axisLine.symbol"),r=t.get("axisLine.symbolSize"),h=t.get("axisLine.symbolOffset")||0;if("number"==typeof h&&(h=[h,h]),null!=l){"string"==typeof l&&(l=[l,l]),"string"!=typeof r&&"number"!=typeof r||(r=[r,r]);var u=r[0],c=r[1];A([{rotate:a.rotation+Math.PI/2,offset:h[0],r:0},{rotate:a.rotation-Math.PI/2,offset:h[1],r:Math.sqrt((o[0]-i[0])*(o[0]-i[0])+(o[1]-i[1])*(o[1]-i[1]))}],function(t,e){if("none"!==l[e]&&null!=l[e]){var n=kp(l[e],-u/2,-c/2,u,c,s.stroke,!0),i=t.r+t.offset,r=[o[0]+i*Math.cos(a.rotation),o[1]-i*Math.sin(a.rotation)];n.attr({rotation:t.rotate,position:r,silent:!0,z2:11}),this.group.add(n)}},this)}}},axisTickLabel:function(){var t=this.axisModel,e=this.opt,n=function(t,e,n){var i=e.axis;if(!e.get("axisTick.show")||i.scale.isBlank())return;for(var r=e.getModel("axisTick"),a=r.getModel("lineStyle"),o=r.get("length"),s=i.getTicksCoords(),l=[],h=[],u=t._transform,c=[],d=0;d<s.length;d++){var f=s[d].coord;l[0]=f,l[1]=0,h[0]=f,h[1]=n.tickDirection*o,u&&(yt(l,l,u),yt(h,h,u));var p=new Bo({anid:"tick_"+s[d].tickValue,subPixelOptimize:!0,shape:{x1:l[0],y1:l[1],x2:h[0],y2:h[1]},style:T(a.getLineStyle(),{stroke:e.get("axisLine.lineStyle.color")}),z2:2,silent:!0});t.group.add(p),c.push(p)}return c}(this,t,e);!function(t,e,n){if(xp(t.axis))return;var i=t.get("axisLabel.showMinLabel"),r=t.get("axisLabel.showMaxLabel");n=n||[];var a=(e=e||[])[0],o=e[1],s=e[e.length-1],l=e[e.length-2],h=n[0],u=n[1],c=n[n.length-1],d=n[n.length-2];!1===i?(cm(a),cm(h)):dm(a,o)&&(i?(cm(o),cm(u)):(cm(a),cm(h)));!1===r?(cm(s),cm(c)):dm(l,s)&&(r?(cm(l),cm(d)):(cm(s),cm(c)))}(t,function(h,u,c){var d=u.axis;if(!H(c.axisLabelShow,u.get("axisLabel.show"))||d.scale.isBlank())return;var f=u.getModel("axisLabel"),p=f.get("margin"),t=d.getViewLabels(),e=(H(c.labelRotate,f.get("rotate"))||0)*om/180,g=hm(c.rotation,e,c.labelDirection),m=u.getCategories&&u.getCategories(!0),v=[],y=um(u),_=u.get("triggerEvent");return A(t,function(t,e){var n=t.tickValue,i=t.formattedLabel,r=t.rawLabel,a=f;m&&m[n]&&m[n].textStyle&&(a=new Js(m[n].textStyle,f,u.ecModel));var o=a.getTextColor()||u.get("axisLine.lineStyle.color"),s=[d.dataToCoord(n),c.labelOffset+c.labelDirection*p],l=new wo({anid:"label_"+n,position:s,rotation:g.rotation,silent:y,z2:10});As(l.style,a,{text:i,textAlign:a.getShallow("align",!0)||g.textAlign,textVerticalAlign:a.getShallow("verticalAlign",!0)||a.getShallow("baseline",!0)||g.textVerticalAlign,textFill:"function"==typeof o?o("category"===d.type?r:"value"===d.type?n+"":n,e):o}),_&&(l.eventData=lm(u),l.eventData.targetType="axisLabel",l.eventData.value=r),h._dumbGroup.add(l),l.updateTransform(),v.push(l),h.group.add(l),l.decomposeTransform()}),v}(this,t,e),n)},axisName:function(){var t=this.opt,e=this.axisModel,n=H(t.axisName,e.get("name"));if(n){var i,r,a=e.get("nameLocation"),o=t.nameDirection,s=e.getModel("nameTextStyle"),l=e.get("nameGap")||0,h=this.axisModel.axis.getExtent(),u=h[0]>h[1]?-1:1,c=["start"===a?h[0]-u*l:"end"===a?h[1]+u*l:(h[0]+h[1])/2,fm(a)?t.labelOffset+o*l:0],d=e.get("nameRotate");null!=d&&(d=d*om/180),fm(a)?i=hm(t.rotation,null!=d?d:t.rotation,o):(i=function(t,e,n,i){var r,a,o=fl(n-t.rotation),s=i[0]>i[1],l="start"===e&&!s||"start"!==e&&s;r=pl(o-om/2)?(a=l?"bottom":"top","center"):pl(o-1.5*om)?(a=l?"top":"bottom","center"):(a="middle",o<1.5*om&&om/2<o?l?"left":"right":l?"right":"left");return{rotation:o,textAlign:r,textVerticalAlign:a}}(t,a,d||0,h),null!=(r=t.axisNameAvailableWidth)&&(r=Math.abs(r/Math.sin(i.rotation)),isFinite(r)||(r=null)));var f=s.getFont(),p=e.get("nameTruncate",!0)||{},g=p.ellipsis,m=H(t.nameTruncateMaxWidth,p.maxWidth,r),v=null!=g&&null!=m?zl(n,m,f,g,{minChar:2,placeholder:p.placeholder}):n,y=e.get("tooltip",!0),_=e.mainType,x={componentType:_,name:n,$vars:["name"]};x[_+"Index"]=e.componentIndex;var w=new wo({anid:"name",__fullText:n,__truncatedText:v,position:c,rotation:i.rotation,silent:um(e),z2:1,tooltip:y&&y.show?I({content:n,formatter:function(){return n},formatterParams:x},y):null});As(w.style,s,{text:v,textFont:f,textFill:s.getTextColor()||e.get("axisLine.lineStyle.color"),textAlign:s.get("align")||i.textAlign,textVerticalAlign:s.get("verticalAlign")||i.textVerticalAlign}),e.get("triggerEvent")&&(w.eventData=lm(e),w.eventData.targetType="axisName",w.eventData.name=n),this._dumbGroup.add(w),w.updateTransform(),this.group.add(w),w.decomposeTransform()}}},lm=am.makeAxisEventDataBase=function(t){var e={componentType:t.mainType,componentIndex:t.componentIndex};return e[t.mainType+"Index"]=t.componentIndex,e},hm=am.innerTextLayout=function(t,e,n){var i,r=fl(e-t);return{rotation:r,textAlign:pl(r)?(i=0<n?"top":"bottom","center"):pl(r-om)?(i=0<n?"bottom":"top","center"):(i="middle",0<r&&r<om?0<n?"right":"left":0<n?"left":"right"),textVerticalAlign:i}};var um=am.isLabelSilent=function(t){var e=t.get("tooltip");return t.get("silent")||!(t.get("triggerEvent")||e&&e.show)};function cm(t){t&&(t.ignore=!0)}function dm(t,e){var n=t&&t.getBoundingRect().clone(),i=e&&e.getBoundingRect().clone();if(n&&i){var r=$t([]);return te(r,r,-t.rotation),n.applyTransform(Qt([],r,t.getLocalTransform())),i.applyTransform(Qt([],r,e.getLocalTransform())),n.intersect(i)}}function fm(t){return"middle"===t||"center"===t}var pm=A,gm=P;function mm(t,e){var n={axesInfo:{},seriesInvolved:!1,coordSysAxesInfo:{},coordSysMap:{}};return function(p,g,t){var a=g.getComponent("tooltip"),m=g.getComponent("axisPointer"),v=m.get("link",!0)||[],y=[];pm(t.getCoordinateSystems(),function(c){if(c.axisPointerEnabled){var t=xm(c.model),d=p.coordSysAxesInfo[t]={},f=(p.coordSysMap[t]=c).model.getModel("tooltip",a);if(pm(c.getAxes(),gm(r,!1,null)),c.getTooltipAxes&&a&&f.get("show")){var e="axis"===f.get("trigger"),n="cross"===f.get("axisPointer.type"),i=c.getTooltipAxes(f.get("axisPointer.axis"));(e||n)&&pm(i.baseAxes,gm(r,!n||"cross",e)),n&&pm(i.otherAxes,gm(r,"cross",!1))}}function r(t,e,n){var i=n.model.getModel("axisPointer",m),r=i.get("show");if(r&&("auto"!==r||t||_m(i))){null==e&&(e=i.get("triggerTooltip"));var a=(i=t?function(t,e,n,i,r,a){var o=e.getModel("axisPointer"),s={};pm(["type","snap","lineStyle","shadowStyle","label","animation","animationDurationUpdate","animationEasingUpdate","z"],function(t){s[t]=b(o.get(t))}),s.snap="category"!==t.type&&!!a,"cross"===o.get("type")&&(s.type="line");var l=s.label||(s.label={});if(null==l.show&&(l.show=!1),"cross"===r){var h=o.get("label.show");if(l.show=null==h||h,!a){var u=s.lineStyle=o.get("crossStyle");u&&T(l,u.textStyle)}}return t.model.getModel("axisPointer",new Js(s,n,i))}(n,f,m,g,t,e):i).get("snap"),o=xm(n.model),s=e||a||"category"===n.type,l=p.axesInfo[o]={key:o,axis:n,coordSys:c,axisPointerModel:i,triggerTooltip:e,involveSeries:s,snap:a,useHandle:_m(i),seriesModels:[]};d[o]=l,p.seriesInvolved|=s;var h=function(t,e){for(var n=e.model,i=e.dim,r=0;r<t.length;r++){var a=t[r]||{};if(vm(a[i+"AxisId"],n.id)||vm(a[i+"AxisIndex"],n.componentIndex)||vm(a[i+"AxisName"],n.name))return r}}(v,n);if(null!=h){var u=y[h]||(y[h]={axesInfo:{}});u.axesInfo[o]=l,u.mapper=v[h].mapper,l.linkGroup=u}}}})}(n,t,e),n.seriesInvolved&&function(r,t){t.eachSeries(function(n){var i=n.coordinateSystem,t=n.get("tooltip.trigger",!0),e=n.get("tooltip.show",!0);i&&"none"!==t&&!1!==t&&"item"!==t&&!1!==e&&!1!==n.get("axisPointer.show",!0)&&pm(r.coordSysAxesInfo[xm(i.model)],function(t){var e=t.axis;i.getAxis(e.dim)===e&&(t.seriesModels.push(n),null==t.seriesDataCount&&(t.seriesDataCount=0),t.seriesDataCount+=n.getData().count())})},this)}(n,t),n}function vm(t,e){return"all"===t||O(t)&&0<=x(t,e)||t===e}function ym(t){var e=(t.ecModel.getComponent("axisPointer")||{}).coordSysAxesInfo;return e&&e.axesInfo[xm(t)]}function _m(t){return!!t.get("handle.show")}function xm(t){return t.type+"||"+t.id}var wm=Wd({type:"axis",_axisPointer:null,axisPointerClass:null,render:function(t,e,n,i){this.axisPointerClass&&function(t){var e=ym(t);if(e){var n=e.axisPointerModel,i=e.axis.scale,r=n.option,a=n.get("status"),o=n.get("value");null!=o&&(o=i.parse(o));var s=_m(n);null==a&&(r.status=s?"show":"hide");var l=i.getExtent().slice();l[0]>l[1]&&l.reverse(),(null==o||o>l[1])&&(o=l[1]),o<l[0]&&(o=l[0]),r.value=o,s&&(r.status=e.axis.scale.isBlank()?"hide":"show")}}(t),wm.superApply(this,"render",arguments),bm(this,t,e,n,i,!0)},updateAxisPointer:function(t,e,n,i,r){bm(this,t,e,n,i,!1)},remove:function(t,e){var n=this._axisPointer;n&&n.remove(e),wm.superApply(this,"remove",arguments)},dispose:function(t,e){Sm(this,e),wm.superApply(this,"dispose",arguments)}});function bm(t,e,n,i,r,a){var o=wm.getAxisPointerClass(t.axisPointerClass);if(o){var s=function(t){var e=ym(t);return e&&e.axisPointerModel}(e);s?(t._axisPointer||(t._axisPointer=new o)).render(e,s,i,a):Sm(t,i)}}function Sm(t,e,n){var i=t._axisPointer;i&&i.dispose(e,n),t._axisPointer=null}var Mm=[];function Im(t,e,n){n=n||{};var i=t.coordinateSystem,r=e.axis,a={},o=r.getAxesOnZeroOf()[0],s=r.position,l=o?"onZero":s,h=r.dim,u=i.getRect(),c=[u.x,u.x+u.width,u.y,u.y+u.height],d={left:0,right:1,top:0,bottom:1,onZero:2},f=e.get("offset")||0,p="x"===h?[c[2]-f,c[3]+f]:[c[0]-f,c[1]+f];if(o){var g=o.toGlobalCoord(o.dataToCoord(0));p[d.onZero]=Math.max(Math.min(g,p[1]),p[0])}a.position=["y"===h?p[d[l]]:c[0],"x"===h?p[d[l]]:c[3]],a.rotation=Math.PI/2*("x"===h?0:1);a.labelDirection=a.tickDirection=a.nameDirection={top:-1,bottom:1,left:-1,right:1}[s],a.labelOffset=o?p[d[s]]-p[d.onZero]:0,e.get("axisTick.inside")&&(a.tickDirection=-a.tickDirection),H(n.labelInside,e.get("axisLabel.inside"))&&(a.labelDirection=-a.labelDirection);var m=e.get("axisLabel.rotate");return a.labelRotate="top"===l?-m:m,a.z2=1,a}wm.registerAxisPointerClass=function(t,e){Mm[t]=e},wm.getAxisPointerClass=function(t){return t&&Mm[t]};var Cm=["axisLine","axisTickLabel","axisName"],Tm=["splitArea","splitLine"],Am=wm.extend({type:"cartesianAxis",axisPointerClass:"CartesianAxisPointer",render:function(e,t,n,i){this.group.removeAll();var r=this._axisGroup;if(this._axisGroup=new yn,this.group.add(this._axisGroup),e.get("show")){var a=e.getCoordSysModel(),o=Im(a,e),s=new am(e,o);A(Cm,s.add,s),this._axisGroup.add(s.getGroup()),A(Tm,function(t){e.get(t+".show")&&this["_"+t](e,a)},this),Hs(r,this._axisGroup,e),Am.superCall(this,"render",e,t,n,i)}},remove:function(){this._splitAreaColors=null},_splitLine:function(t,e){var n=t.axis;if(!n.scale.isBlank()){var i=t.getModel("splitLine"),r=i.getModel("lineStyle"),a=r.get("color");a=O(a)?a:[a];for(var o=e.coordinateSystem.getRect(),s=n.isHorizontal(),l=0,h=n.getTicksCoords({tickModel:i}),u=[],c=[],d=r.getLineStyle(),f=0;f<h.length;f++){var p=n.toGlobalCoord(h[f].coord);s?(u[0]=p,u[1]=o.y,c[0]=p,c[1]=o.y+o.height):(u[0]=o.x,u[1]=p,c[0]=o.x+o.width,c[1]=p);var g=l++%a.length,m=h[f].tickValue;this._axisGroup.add(new Bo({anid:null!=m?"line_"+h[f].tickValue:null,subPixelOptimize:!0,shape:{x1:u[0],y1:u[1],x2:c[0],y2:c[1]},style:T({stroke:a[g]},d),silent:!0}))}}},_splitArea:function(t,e){var n=t.axis;if(!n.scale.isBlank()){var i=t.getModel("splitArea"),r=i.getModel("areaStyle"),a=r.get("color"),o=e.coordinateSystem.getRect(),s=n.getTicksCoords({tickModel:i,clamp:!0});if(s.length){var l=a.length,h=this._splitAreaColors,u=Q(),c=0;if(h)for(var d=0;d<s.length;d++){var f=h.get(s[d].tickValue);if(null!=f){c=(f+(l-1)*d)%l;break}}var p=n.toGlobalCoord(s[0].coord),g=r.getAreaStyle();a=O(a)?a:[a];for(d=1;d<s.length;d++){var m,v,y,_,x=n.toGlobalCoord(s[d].coord);p=n.isHorizontal()?(m=p,v=o.y,y=x-m,_=o.height,m+y):(m=o.x,v=p,y=o.width,v+(_=x-v));var w=s[d-1].tickValue;null!=w&&u.set(w,c),this._axisGroup.add(new No({anid:null!=w?"area_"+w:null,shape:{x:m,y:v,width:y,height:_},style:T({fill:a[c]},g),silent:!0})),c=(c+1)%l}this._splitAreaColors=u}}}});function Dm(t,e){"outside"===t.textPosition&&(t.textPosition=e)}Am.extend({type:"xAxis"}),Am.extend({type:"yAxis"}),Wd({type:"grid",render:function(t,e){this.group.removeAll(),t.get("show")&&this.group.add(new No({shape:t.coordinateSystem.getRect(),style:T({fill:t.get("backgroundColor")},t.getItemStyle()),silent:!0,z2:-1}))}}),zd(function(t){t.xAxis&&t.yAxis&&!t.grid&&(t.grid={})}),Bd(Ng("line","circle","line")),Rd(Rg("line")),Ed(Yc.PROCESSOR.STATISTIC,{seriesType:"line",modifyOutputEnd:!0,reset:function(t,e,n){var i=t.getData(),r=t.get("sampling"),a=t.coordinateSystem;if("cartesian2d"===a.type&&r){var o,s=a.getBaseAxis(),l=a.getOtherAxis(s),h=s.getExtent(),u=h[1]-h[0],c=Math.round(i.count()/u);1<c&&("string"==typeof r?o=Fg[r]:"function"==typeof r&&(o=r),o&&t.setData(i.downSample(i.mapDimension(l.dim),1/c,o,Bg)))}}}),Iu.extend({type:"series.__base_bar__",getInitialData:function(t,e){return Cf(this.getSource(),this)},getMarkerPosition:function(t){var e=this.coordinateSystem;if(e){var n=e.dataToPoint(e.clampData(t)),i=this.getData(),r=i.getLayout("offset"),a=i.getLayout("size");return n[e.getBaseAxis().isHorizontal()?0:1]+=r+a/2,n}return[NaN,NaN]},defaultOption:{zlevel:0,z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,barMinHeight:0,barMinAngle:0,large:!1,largeThreshold:400,progressive:3e3,progressiveChunkMode:"mod",itemStyle:{},emphasis:{}}}).extend({type:"series.bar",dependencies:["grid","polar"],brushSelector:"rect",getProgressive:function(){return!!this.get("large")&&this.get("progressive")},getProgressiveThreshold:function(){var t=this.get("progressiveThreshold"),e=this.get("largeThreshold");return t<e&&(t=e),t}});var km=Fr([["fill","color"],["stroke","borderColor"],["lineWidth","borderWidth"],["stroke","barBorderColor"],["lineWidth","barBorderWidth"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"]]),Pm=["itemStyle","barBorderWidth"],Lm=[0,0];I(Js.prototype,{getBarItemStyle:function(t){var e=km(this,t);if(this.getBorderLineDash){var n=this.getBorderLineDash();n&&(e.lineDash=n)}return e}}),Zd({type:"bar",render:function(t,e,n){this._updateDrawMode(t);var i=t.get("coordinateSystem");return"cartesian2d"!==i&&"polar"!==i||(this._isLargeDraw?this._renderLarge(t,e,n):this._renderNormal(t,e,n)),this.group},incrementalPrepareRender:function(t,e,n){this._clear(),this._updateDrawMode(t)},incrementalRender:function(t,e,n,i){this._incrementalRenderLarge(t,e)},_updateDrawMode:function(t){var e=t.pipelineContext.large;(null==this._isLargeDraw||e^this._isLargeDraw)&&(this._isLargeDraw=e,this._clear())},_renderNormal:function(a,t,e){var o,s=this.group,l=a.getData(),h=this._data,u=a.coordinateSystem,n=u.getBaseAxis();"cartesian2d"===u.type?o=n.isHorizontal():"polar"===u.type&&(o="angle"===n.dim);var c=a.isAnimationEnabled()?a:null;l.diff(h).add(function(t){if(l.hasValue(t)){var e=l.getItemModel(t),n=Nm[u.type](l,t,e),i=Om[u.type](l,t,e,n,o,c);l.setItemGraphicEl(t,i),s.add(i),Rm(i,l,t,e,n,a,o,"polar"===u.type)}}).update(function(t,e){var n=h.getItemGraphicEl(e);if(l.hasValue(t)){var i=l.getItemModel(t),r=Nm[u.type](l,t,i);n?Ns(n,{shape:r},c,t):n=Om[u.type](l,t,i,r,o,c,!0),l.setItemGraphicEl(t,n),s.add(n),Rm(n,l,t,i,r,a,o,"polar"===u.type)}else s.remove(n)}).remove(function(t){var e=h.getItemGraphicEl(t);"cartesian2d"===u.type?e&&zm(t,c,e):e&&Em(t,c,e)}).execute(),this._data=l},_renderLarge:function(t,e,n){this._clear(),Fm(t,this.group)},_incrementalRenderLarge:function(t,e){Fm(e,this.group,!0)},dispose:J,remove:function(t){this._clear(t)},_clear:function(e){var t=this.group,n=this._data;e&&e.get("animation")&&n&&!this._isLargeDraw?n.eachItemGraphicEl(function(t){"sector"===t.type?Em(t.dataIndex,e,t):zm(t.dataIndex,e,t)}):t.removeAll(),this._data=null}});var Om={cartesian2d:function(t,e,n,i,r,a,o){var s=new No({shape:I({},i)});if(a){var l=r?"height":"width",h={};s.shape[l]=0,h[l]=i[l],Xs[o?"updateProps":"initProps"](s,{shape:h},a,e)}return s},polar:function(t,e,n,i,r,a,o){var s=i.startAngle<i.endAngle,l=new Io({shape:T({clockwise:s},i)});if(a){var h=r?"r":"endAngle",u={};l.shape[h]=r?0:i.startAngle,u[h]=i[h],Xs[o?"updateProps":"initProps"](l,{shape:u},a,e)}return l}};function zm(t,e,n){n.style.text=null,Ns(n,{shape:{width:0}},e,t,function(){n.parent&&n.parent.remove(n)})}function Em(t,e,n){n.style.text=null,Ns(n,{shape:{r:n.shape.r0}},e,t,function(){n.parent&&n.parent.remove(n)})}var Nm={cartesian2d:function(t,e,n){var i=t.getItemLayout(e),r=function(t,e){var n=t.get(Pm)||0;return Math.min(n,Math.abs(e.width),Math.abs(e.height))}(n,i),a=0<i.width?1:-1,o=0<i.height?1:-1;return{x:i.x+a*r/2,y:i.y+o*r/2,width:i.width-a*r,height:i.height-o*r}},polar:function(t,e,n){var i=t.getItemLayout(e);return{cx:i.cx,cy:i.cy,r0:i.r0,r:i.r,startAngle:i.startAngle,endAngle:i.endAngle}}};function Rm(t,e,n,i,r,a,o,s){var l=e.getItemVisual(n,"color"),h=e.getItemVisual(n,"opacity"),u=i.getModel("itemStyle"),c=i.getModel("emphasis.itemStyle").getBarItemStyle();s||t.setShape("r",u.get("barBorderRadius")||0),t.useStyle(T({fill:l,opacity:h},u.getBarItemStyle()));var d=i.getShallow("cursor");d&&t.attr("cursor",d);o?r.height:r.width;s||function(t,e,n,i,r,a){Ts(t,e,n.getModel("label"),n.getModel("emphasis.label"),{labelFetcher:r,labelDataIndex:a,defaultText:tg(r.getData(),a),isRectText:!0,autoColor:i}),Dm(t),Dm(e)}(t.style,c,i,l,a,n),Ss(t,c)}var Bm=no.extend({type:"largeBar",shape:{points:[]},buildPath:function(t,e){for(var n=e.points,i=this.__startPoint,r=this.__baseDimIdx,a=0;a<n.length;a+=2)i[r]=n[a+r],t.moveTo(i[0],i[1]),t.lineTo(n[a],n[a+1])}});function Fm(t,e,n){var i=t.getData(),r=[],a=i.getLayout("valueAxisHorizontal")?1:0;r[1-a]=i.getLayout("valueAxisStart");var o=new Bm({shape:{points:i.getLayout("largePoints")},incremental:!!n,__startPoint:r,__baseDimIdx:a,__largeDataIndices:i.getLayout("largeDataIndices"),__barWidth:i.getLayout("barWidth")});e.add(o),function(t,e,n){var i=n.getVisual("borderColor")||n.getVisual("color"),r=e.getModel("itemStyle").getItemStyle(["color","borderColor"]);t.useStyle(r),t.style.fill=null,t.style.stroke=i,t.style.lineWidth=n.getLayout("barWidth")}(o,t,i),o.seriesIndex=t.seriesIndex,t.get("silent")||(o.on("mousedown",Vm),o.on("mousemove",Vm))}var Vm=ju(function(t){var e=function(t,e,n){var i=t.__baseDimIdx,r=1-i,a=t.shape.points,o=t.__largeDataIndices,s=Math.abs(t.__barWidth/2),l=t.__startPoint[r];Lm[0]=e,Lm[1]=n;for(var h=Lm[i],u=Lm[1-i],c=h-s,d=h+s,f=0,p=a.length/2;f<p;f++){var g=2*f,m=a[g+i],v=a[g+r];if(c<=m&&m<=d&&(l<=v?l<=u&&u<=v:v<=u&&u<=l))return o[f]}return-1}(this,t.offsetX,t.offsetY);this.dataIndex=0<=e?e:null},30,!1);Rd(Yc.VISUAL.LAYOUT,P(function(t,e){var n=Zf(t,e),C=Uf(n),T={};A(n,function(t){var e=t.getData(),n=t.coordinateSystem,i=n.getBaseAxis(),r=Wf(t),a=C[Gf(i)][r],o=a.offset,s=a.width,l=n.getOtherAxis(i),h=t.get("barMinHeight")||0;T[r]=T[r]||[],e.setLayout({offset:o,size:s});for(var u=e.mapDimension(l.dim),c=e.mapDimension(i.dim),d=Mf(e,u),f=l.isHorizontal(),p=$f(i,l,d),g=0,m=e.count();g<m;g++){var v=e.get(u,g),y=e.get(c,g);if(!isNaN(v)&&!isNaN(y)){var _,x,w,b,S,M=0<=v?"p":"n",I=p;if(d&&(T[r][y]||(T[r][y]={p:p,n:p}),I=T[r][y][M]),f)_=I,x=(S=n.dataToPoint([v,y]))[1]+o,w=S[0]-p,b=s,Math.abs(w)<h&&(w=(w<0?-1:1)*h),d&&(T[r][y][M]+=w);else _=(S=n.dataToPoint([y,v]))[0]+o,x=I,w=s,b=S[1]-p,Math.abs(b)<h&&(b=(b<=0?-1:1)*h),d&&(T[r][y][M]+=b);e.setItemLayout(g,{x:_,y:x,width:w,height:b})}}},this)},"bar")),Rd(Yc.VISUAL.PROGRESSIVE_LAYOUT,Yf),Bd({seriesType:"bar",reset:function(t){t.getData().setVisual("legendSymbol","roundRect")}});var Hm={updateSelectedMap:function(t){this._targetList=O(t)?t.slice():[],this._selectTargetMap=M(t||[],function(t,e){return t.set(e.name,e),t},Q())},select:function(t,e){var n=null!=e?this._targetList[e]:this._selectTargetMap.get(t);"single"===this.get("selectedMode")&&this._selectTargetMap.each(function(t){t.selected=!1}),n&&(n.selected=!0)},unSelect:function(t,e){var n=null!=e?this._targetList[e]:this._selectTargetMap.get(t);n&&(n.selected=!1)},toggleSelected:function(t,e){var n=null!=e?this._targetList[e]:this._selectTargetMap.get(t);if(null!=n)return this[n.selected?"unSelect":"select"](t,e),n.selected},isSelected:function(t,e){var n=null!=e?this._targetList[e]:this._selectTargetMap.get(t);return n&&n.selected}},Wm=Gd({type:"series.pie",init:function(t){Wm.superApply(this,"init",arguments),this.legendDataProvider=function(){return this.getRawData()},this.updateSelectedMap(this._createSelectableList()),this._defaultLabelLine(t)},mergeOption:function(t){Wm.superCall(this,"mergeOption",t),this.updateSelectedMap(this._createSelectableList())},getInitialData:function(t,e){return function(t,e,n){e=O(e)&&{coordDimensions:e}||I({},e);var i=t.getSource(),r=bf(i,e),a=new sf(r,t);return a.initData(i,n),a}(this,["value"])},_createSelectableList:function(){for(var t=this.getRawData(),e=t.mapDimension("value"),n=[],i=0,r=t.count();i<r;i++)n.push({name:t.getName(i),value:t.get(e,i),selected:lu(t,i,"selected")});return n},getDataParams:function(t){var e=this.getData(),n=Wm.superCall(this,"getDataParams",t),i=[];return e.each(e.mapDimension("value"),function(t){i.push(t)}),n.percent=dl(i,t,e.hostModel.get("percentPrecision")),n.$vars.push("percent"),n},_defaultLabelLine:function(t){mr(t,"labelLine",["show"]);var e=t.labelLine,n=t.emphasis.labelLine;e.show=e.show&&t.label.show,n.show=n.show&&t.emphasis.label.show},defaultOption:{zlevel:0,z:2,legendHoverLink:!0,hoverAnimation:!0,center:["50%","50%"],radius:[0,"75%"],clockwise:!0,startAngle:90,minAngle:0,minShowLabelAngle:0,selectedOffset:10,hoverOffset:10,avoidLabelOverlap:!0,percentPrecision:2,stillShowZeroSum:!0,label:{rotate:!1,show:!0,position:"outer"},labelLine:{show:!0,length:15,length2:15,smooth:!1,lineStyle:{width:1,type:"solid"}},itemStyle:{borderWidth:1},animationType:"expansion",animationEasing:"cubicOut"}});function Gm(t,e,n,i){var r=e.getData(),a=this.dataIndex,o=r.getName(a),s=e.get("selectedOffset");i.dispatchAction({type:"pieToggleSelect",from:t,name:o,seriesId:e.id}),r.each(function(t){Zm(r.getItemGraphicEl(t),r.getItemLayout(t),e.isSelected(r.getName(t)),s,n)})}function Zm(t,e,n,i,r){var a=(e.startAngle+e.endAngle)/2,o=n?i:0,s=[Math.cos(a)*o,Math.sin(a)*o];r?t.animate().when(200,{position:s}).start("bounceOut"):t.attr("position",s)}function Um(t,e){yn.call(this);var n=new Io({z2:2}),i=new ko,r=new wo;this.add(n),this.add(i),this.add(r),this.updateData(t,e,!0)}S(Wm,Hm);var Xm=Um.prototype;Xm.updateData=function(t,e,n){var i=this.childAt(0),r=this.childAt(1),a=this.childAt(2),o=t.hostModel,s=t.getItemModel(e),l=t.getItemLayout(e),h=I({},l);(h.label=null,n)?(i.setShape(h),"scale"===o.getShallow("animationType")?(i.shape.r=l.r0,Rs(i,{shape:{r:l.r}},o,e)):(i.shape.endAngle=l.startAngle,Ns(i,{shape:{endAngle:l.endAngle}},o,e))):Ns(i,{shape:h},o,e);var u=t.getItemVisual(e,"color");i.useStyle(T({lineJoin:"bevel",fill:u},s.getModel("itemStyle").getItemStyle())),i.hoverStyle=s.getModel("emphasis.itemStyle").getItemStyle();var c=s.getShallow("cursor");c&&i.attr("cursor",c),Zm(this,t.getItemLayout(e),o.isSelected(null,e),o.get("selectedOffset"),o.get("animation")),this._updateLabel(t,e),this.highDownOnUpdate=s.get("hoverAnimation")&&o.isAnimationEnabled()?function(t,e){"emphasis"===e?(r.ignore=r.hoverIgnore,a.ignore=a.hoverIgnore,i.stopAnimation(!0),i.animateTo({shape:{r:l.r+o.get("hoverOffset")}},300,"elasticOut")):(r.ignore=r.normalIgnore,a.ignore=a.normalIgnore,i.stopAnimation(!0),i.animateTo({shape:{r:l.r}},300,"elasticOut"))}:null,Ss(this)},Xm._updateLabel=function(t,e){var n=this.childAt(1),i=this.childAt(2),r=t.hostModel,a=t.getItemModel(e),o=t.getItemLayout(e).label,s=t.getItemVisual(e,"color");if(!o||isNaN(o.x)||isNaN(o.y))i.ignore=i.normalIgnore=i.hoverIgnore=n.ignore=n.normalIgnore=n.hoverIgnore=!0;else{Ns(n,{shape:{points:o.linePoints||[[o.x,o.y],[o.x,o.y],[o.x,o.y]]}},r,e),Ns(i,{style:{x:o.x,y:o.y}},r,e),i.attr({rotation:o.rotation,origin:[o.x,o.y],z2:10});var l=a.getModel("label"),h=a.getModel("emphasis.label"),u=a.getModel("labelLine"),c=a.getModel("emphasis.labelLine");s=t.getItemVisual(e,"color");Ts(i.style,i.hoverStyle={},l,h,{labelFetcher:t.hostModel,labelDataIndex:e,defaultText:t.getName(e),autoColor:s,useInsideStyle:!!o.inside},{textAlign:o.textAlign,textVerticalAlign:o.verticalAlign,opacity:t.getItemVisual(e,"opacity")}),i.ignore=i.normalIgnore=!l.get("show"),i.hoverIgnore=!h.get("show"),n.ignore=n.normalIgnore=!u.get("show"),n.hoverIgnore=!c.get("show"),n.setStyle({stroke:s,opacity:t.getItemVisual(e,"opacity")}),n.setStyle(u.getModel("lineStyle").getLineStyle()),n.hoverStyle=c.getModel("lineStyle").getLineStyle();var d=u.get("smooth");d&&!0===d&&(d=.4),n.setShape({smooth:d})}},w(Um,yn);Bu.extend({type:"pie",init:function(){var t=new yn;this._sectorGroup=t},render:function(t,e,n,i){if(!i||i.from!==this.uid){var r=t.getData(),a=this._data,o=this.group,s=e.get("animation"),l=!a,h=t.get("animationType"),u=P(Gm,this.uid,t,s,n),c=t.get("selectedMode");if(r.diff(a).add(function(t){var e=new Um(r,t);l&&"scale"!==h&&e.eachChild(function(t){t.stopAnimation(!0)}),c&&e.on("click",u),r.setItemGraphicEl(t,e),o.add(e)}).update(function(t,e){var n=a.getItemGraphicEl(e);n.updateData(r,t),n.off("click"),c&&n.on("click",u),o.add(n),r.setItemGraphicEl(t,n)}).remove(function(t){var e=a.getItemGraphicEl(t);o.remove(e)}).execute(),s&&l&&0<r.count()&&"scale"!==h){for(var d=r.getItemLayout(0),f=1;isNaN(d.startAngle)&&f<r.count();++f)d=r.getItemLayout(f);var p=Math.max(n.getWidth(),n.getHeight())/2,g=k(o.removeClipPath,o);o.setClipPath(this._createClipPath(d.cx,d.cy,p,d.startAngle,d.clockwise,g,t))}else o.removeClipPath();this._data=r}},dispose:function(){},_createClipPath:function(t,e,n,i,r,a,o){var s=new Io({shape:{cx:t,cy:e,r0:0,r:n,startAngle:i,endAngle:i,clockwise:r}});return Rs(s,{shape:{endAngle:i+(r?1:-1)*Math.PI*2}},o,a),s},containPoint:function(t,e){var n=e.getData().getItemLayout(0);if(n){var i=t[0]-n.cx,r=t[1]-n.cy,a=Math.sqrt(i*i+r*r);return a<=n.r&&a>=n.r0}}});var Ym=Math.PI/180;function jm(r,t,e,n,i,a,o){function s(t,e,n){for(var i=t;i<e;i++)if(r[i].y+=n,t<i&&i+1<e&&r[i+1].y>r[i].y+r[i].height)return void l(i,n/2);l(e-1,n/2)}function l(t,e){for(var n=t;0<=n&&(r[n].y-=e,!(0<n&&r[n].y>r[n-1].y+r[n-1].height));n--);}function h(t,e,n,i,r,a){for(var o=e?Number.MAX_VALUE:0,s=0,l=t.length;s<l;s++){var h=Math.abs(t[s].y-i),u=t[s].len,c=t[s].len2,d=h<r+u?Math.sqrt((r+u+c)*(r+u+c)-h*h):Math.abs(t[s].x-n);e&&o<=d&&(d=o-10),!e&&d<=o&&(d=o+10),t[s].x=n+d*a,o=d}}r.sort(function(t,e){return t.y-e.y});for(var u,c=0,d=r.length,f=[],p=[],g=0;g<d;g++)(u=r[g].y-c)<0&&s(g,d,-u),c=r[g].y+r[g].height;o-c<0&&l(d-1,c-o);for(g=0;g<d;g++)r[g].y>=e?p.push(r[g]):f.push(r[g]);h(f,!1,t,e,n,i),h(p,!0,t,e,n,i)}function qm(t){return"center"===t.position}function $m(I,C,t,e,n){var T,A,D=I.getData(),k=[],P=!1,L=(I.get("minShowLabelAngle")||0)*Ym;D.each(function(t){var e=D.getItemLayout(t),n=D.getItemModel(t),i=n.getModel("label"),r=i.get("position")||n.get("emphasis.label.position"),a=n.getModel("labelLine"),o=a.get("length"),s=a.get("length2");if(!(e.angle<L)){var l,h,u,c,d=(e.startAngle+e.endAngle)/2,f=Math.cos(d),p=Math.sin(d);T=e.cx,A=e.cy;var g="inside"===r||"inner"===r;if("center"===r)l=e.cx,h=e.cy,c="center";else{var m=(g?(e.r+e.r0)/2*f:e.r*f)+T,v=(g?(e.r+e.r0)/2*p:e.r*p)+A;if(l=m+3*f,h=v+3*p,!g){var y=m+f*(o+C-e.r),_=v+p*(o+C-e.r),x=y+(f<0?-1:1)*s;l=x+(f<0?-5:5),u=[[m,v],[y,_],[x,h=_]]}c=g?"center":0<f?"left":"right"}var w,b=i.getFont(),S=i.get("rotate");w="number"==typeof S?S*(Math.PI/180):S?f<0?-d+Math.PI:-d:0;var M=ii(I.getFormattedLabel(t,"normal")||D.getName(t),b,c,"top");P=!!w,e.label={x:l,y:h,position:r,height:M.height,len:o,len2:s,linePoints:u,textAlign:c,verticalAlign:"middle",rotation:w,inside:g},g||k.push(e.label)}}),!P&&I.get("avoidLabelOverlap")&&function(t,e,n,i,r,a){for(var o=[],s=[],l=0;l<t.length;l++)qm(t[l])||(t[l].x<e?o.push(t[l]):s.push(t[l]));for(jm(s,e,n,i,1,0,a),jm(o,e,n,i,-1,0,a),l=0;l<t.length;l++)if(!qm(t[l])){var h=t[l].linePoints;if(h){var u=h[1][0]-h[2][0];t[l].x<e?h[2][0]=t[l].x+3:h[2][0]=t[l].x-3,h[1][1]=h[2][1]=t[l].y,h[1][0]=h[2][0]+u}}}(k,T,A,C,0,e)}var Km,Qm,Jm=2*Math.PI,tv=Math.PI/180;Km="pie",A([{type:"pieToggleSelect",event:"pieselectchanged",method:"toggleSelected"},{type:"pieSelect",event:"pieselected",method:"select"},{type:"pieUnSelect",event:"pieunselected",method:"unSelect"}],function(a){a.update="updateView",Nd(a,function(t,e){var r={};return e.eachComponent({mainType:"series",subType:Km,query:t},function(n){n[a.method]&&n[a.method](t.name,t.dataIndex);var i=n.getData();i.each(function(t){var e=i.getName(t);r[e]=n.isSelected(e)||!1})}),{name:t.name,selected:r,seriesId:t.seriesId}})}),Bd((Qm="pie",{getTargetSeries:function(t){var e={},n=Q();return t.eachSeriesByType(Qm,function(t){t.__paletteScope=e,n.set(t.uid,t)}),n},reset:function(r,t){var a=r.getRawData(),o={},s=r.getData();s.each(function(t){var e=s.getRawIndex(t);o[e]=t}),a.each(function(t){var e=o[t],n=null!=e&&s.getItemVisual(e,"color",!0);if(n)a.setItemVisual(t,"color",n);else{var i=a.getItemModel(t).get("itemStyle.color")||r.getColorFromPalette(a.getName(t)||t+"",r.__paletteScope,a.count());a.setItemVisual(t,"color",i),null!=e&&s.setItemVisual(e,"color",i)}})}})),Rd(P(function(t,e,C,n){e.eachSeriesByType(t,function(t){var r=t.getData(),e=r.mapDimension("value"),n=t.get("center"),i=t.get("radius");O(i)||(i=[0,i]),O(n)||(n=[n,n]);var a=C.getWidth(),o=C.getHeight(),s=Math.min(a,o),l=ol(n[0],a),h=ol(n[1],o),u=ol(i[0],s/2),c=ol(i[1],s/2),d=-t.get("startAngle")*tv,f=t.get("minAngle")*tv,p=0;r.each(e,function(t){isNaN(t)||p++});var g=r.getSum(e),m=Math.PI/(g||p)*2,v=t.get("clockwise"),y=t.get("roseType"),_=t.get("stillShowZeroSum"),x=r.getDataExtent(e);x[0]=0;var w=Jm,b=0,S=d,M=v?1:-1;if(r.each(e,function(t,e){var n;if(isNaN(t))r.setItemLayout(e,{angle:NaN,startAngle:NaN,endAngle:NaN,clockwise:v,cx:l,cy:h,r0:u,r:y?NaN:c});else{(n="area"!==y?0===g&&_?m:t*m:Jm/p)<f?w-=n=f:b+=t;var i=S+M*n;r.setItemLayout(e,{angle:n,startAngle:S,endAngle:i,clockwise:v,cx:l,cy:h,r0:u,r:y?al(t,x,[u,c]):c}),S=i}}),w<Jm&&p)if(w<=.001){var I=Jm/p;r.each(e,function(t,e){if(!isNaN(t)){var n=r.getItemLayout(e);n.angle=I,n.startAngle=d+M*e*I,n.endAngle=d+M*(e+1)*I}})}else m=w/b,S=d,r.each(e,function(t,e){if(!isNaN(t)){var n=r.getItemLayout(e),i=n.angle===f?f:t*m;n.startAngle=S,n.endAngle=S+M*i,S+=M*i}});$m(t,c,0,o)})},"pie")),Ed({seriesType:"pie",reset:function(t,e){var i=e.findComponents({mainType:"legend"});if(i&&i.length){var r=t.getData();r.filterSelf(function(t){for(var e=r.getName(t),n=0;n<i.length;n++)if(!i[n].isSelected(e))return!1;return!0})}}}),Iu.extend({type:"series.scatter",dependencies:["grid","polar","geo","singleAxis","calendar"],getInitialData:function(t,e){return Cf(this.getSource(),this)},brushSelector:"point",getProgressive:function(){var t=this.option.progressive;return null==t?this.option.large?5e3:this.get("progressive"):t},getProgressiveThreshold:function(){var t=this.option.progressiveThreshold;return null==t?this.option.large?1e4:this.get("progressiveThreshold"):t},defaultOption:{coordinateSystem:"cartesian2d",zlevel:0,z:2,legendHoverLink:!0,hoverAnimation:!0,symbolSize:10,large:!1,largeThreshold:2e3,itemStyle:{opacity:.8}}});var ev=is({shape:{points:null},symbolProxy:null,buildPath:function(t,e){var n=e.points,i=e.size,r=this.symbolProxy,a=r.shape;if(!((t.getContext?t.getContext():t)&&i[0]<4))for(var o=0;o<n.length;){var s=n[o++],l=n[o++];isNaN(s)||isNaN(l)||(a.x=s-i[0]/2,a.y=l-i[1]/2,a.width=i[0],a.height=i[1],r.buildPath(t,a,!0))}},afterBrush:function(t){var e=this.shape,n=e.points,i=e.size;if(i[0]<4){this.setTransform(t);for(var r=0;r<n.length;){var a=n[r++],o=n[r++];isNaN(a)||isNaN(o)||t.fillRect(a-i[0]/2,o-i[1]/2,i[0],i[1])}this.restoreTransform(t)}},findDataIndex:function(t,e){for(var n=this.shape,i=n.points,r=n.size,a=Math.max(r[0],4),o=Math.max(r[1],4),s=i.length/2-1;0<=s;s--){var l=2*s,h=i[l]-a/2,u=i[1+l]-o/2;if(h<=t&&u<=e&&t<=h+a&&e<=u+o)return s}return-1}});function nv(){this.group=new yn}var iv=nv.prototype;iv.isPersistent=function(){return!this._incremental},iv.updateData=function(t){this.group.removeAll();var e=new ev({rectHover:!0,cursor:"default"});e.setShape({points:t.getLayout("symbolPoints")}),this._setCommon(e,t),this.group.add(e),this._incremental=null},iv.updateLayout=function(t){if(!this._incremental){var i=t.getLayout("symbolPoints");this.group.eachChild(function(t){if(null!=t.startIndex){var e=2*(t.endIndex-t.startIndex),n=4*t.startIndex*2;i=new Float32Array(i.buffer,n,e)}t.setShape("points",i)})}},iv.incrementalPrepareUpdate=function(t){this.group.removeAll(),this._clearIncremental(),2e6<t.count()?(this._incremental||(this._incremental=new Yo({silent:!0})),this.group.add(this._incremental)):this._incremental=null},iv.incrementalUpdate=function(t,e){var n;this._incremental?(n=new ev,this._incremental.addDisplayable(n,!0)):((n=new ev({rectHover:!0,cursor:"default",startIndex:t.start,endIndex:t.end})).incremental=!0,this.group.add(n)),n.setShape({points:e.getLayout("symbolPoints")}),this._setCommon(n,e,!!this._incremental)},iv._setCommon=function(n,t,e){var i=t.hostModel,r=t.getVisual("symbolSize");n.setShape("size",r instanceof Array?r:[r,r]),n.symbolProxy=kp(t.getVisual("symbol"),0,0,0,0),n.setColor=n.symbolProxy.setColor;var a=n.shape.size[0]<4;n.useStyle(i.getModel("itemStyle").getItemStyle(a?["color","shadowBlur","shadowColor"]:["color"]));var o=t.getVisual("color");o&&n.setColor(o),e||(n.seriesIndex=i.seriesIndex,n.on("mousemove",function(t){n.dataIndex=null;var e=n.findDataIndex(t.offsetX,t.offsetY);0<=e&&(n.dataIndex=e+(n.startIndex||0))}))},iv.remove=function(){this._clearIncremental(),this._incremental=null,this.group.removeAll()},iv._clearIncremental=function(){var t=this._incremental;t&&t.clearDisplaybles()},Zd({type:"scatter",render:function(t,e,n){var i=t.getData();this._updateSymbolDraw(i,t).updateData(i),this._finished=!0},incrementalPrepareRender:function(t,e,n){var i=t.getData();this._updateSymbolDraw(i,t).incrementalPrepareUpdate(i),this._finished=!1},incrementalRender:function(t,e,n){this._symbolDraw.incrementalUpdate(t,e.getData()),this._finished=t.end===e.getData().count()},updateTransform:function(t,e,n){var i=t.getData();if(this.group.dirty(),!this._finished||1e4<i.count()||!this._symbolDraw.isPersistent())return{update:!0};var r=Rg().reset(t);r.progress&&r.progress({start:0,end:i.count()},i),this._symbolDraw.updateLayout(i)},_updateSymbolDraw:function(t,e){var n=this._symbolDraw,i=e.pipelineContext.large;return n&&i===this._isLargeDraw||(n&&n.remove(),n=this._symbolDraw=i?new nv:new cg,this._isLargeDraw=i,this.group.removeAll()),this.group.add(n.group),n},remove:function(t,e){this._symbolDraw&&this._symbolDraw.remove(!0),this._symbolDraw=null},dispose:function(){}}),Bd(Ng("scatter","circle")),Rd(Rg("scatter")),zd(function(t){var e=t.graphic;O(e)?e[0]&&e[0].elements?t.graphic=[t.graphic[0]]:t.graphic=[{elements:e}]:e&&!e.elements&&(t.graphic=[{elements:[e]}])});var rv=Hd({type:"graphic",defaultOption:{elements:[],parentId:null},_elOptionsToUpdate:null,mergeOption:function(t){var e=this.option.elements;this.option.elements=null,rv.superApply(this,"mergeOption",arguments),this.option.elements=e},optionUpdated:function(t,e){var n=this.option,i=(e?n:t).elements,r=n.elements=e?[]:n.elements,a=[];this._flatten(i,a);var o=_r(r,a);xr(o);var s=this._elOptionsToUpdate=[];A(o,function(t,e){var n=t.option;n&&(s.push(n),function(t,e){var n=t.exist;if(e.id=t.keyInfo.id,!e.type&&n&&(e.type=n.type),null==e.parentId){var i=e.parentOption;i?e.parentId=i.id:n&&(e.parentId=n.parentId)}e.parentOption=null}(t,n),function(t,e,n){var i=I({},n),r=t[e],a=n.$action||"merge";"merge"===a?r?(m(r,i,!0),Gl(r,i,{ignoreSize:!0}),Ul(n,r)):t[e]=i:"replace"===a?t[e]=i:"remove"===a&&r&&(t[e]=null)}(r,e,n),function(t,e){if(!t)return;t.hv=e.hv=[sv(e,["left","right"]),sv(e,["top","bottom"])],"group"===t.type&&(null==t.width&&(t.width=e.width=0),null==t.height&&(t.height=e.height=0))}(r[e],n))},this);for(var l=r.length-1;0<=l;l--)null==r[l]?r.splice(l,1):delete r[l].$action},_flatten:function(t,n,i){A(t,function(t){if(t){i&&(t.parentOption=i),n.push(t);var e=t.children;"group"===t.type&&e&&this._flatten(e,n,t),delete t.children}},this)},useElOptionsToUpdate:function(){var t=this._elOptionsToUpdate;return this._elOptionsToUpdate=null,t}});function av(t,e,n,i){var r=n.type,a=new(Xs[r.charAt(0).toUpperCase()+r.slice(1)])(n);e.add(a),i.set(t,a),a.__ecGraphicId=t}function ov(t,e){var n=t&&t.parent;n&&("group"===t.type&&t.traverse(function(t){ov(t,e)}),e.removeKey(t.__ecGraphicId),n.remove(t))}function sv(e,t){var n;return A(t,function(t){null!=e[t]&&"auto"!==e[t]&&(n=!0)}),n}Wd({type:"graphic",init:function(t,e){this._elMap=Q(),this._lastGraphicModel},render:function(t,e,n){t!==this._lastGraphicModel&&this._clear(),this._lastGraphicModel=t,this._updateElements(t),this._relocate(t,n)},_updateElements:function(h){var t=h.useElOptionsToUpdate();if(t){var u=this._elMap,c=this.group;A(t,function(t){var e=t.$action,n=t.id,i=u.get(n),r=t.parentId,a=null!=r?u.get(r):c,o=t.style;"text"===t.type&&o&&(t.hv&&t.hv[1]&&(o.textVerticalAlign=o.textBaseline=null),!o.hasOwnProperty("textFill")&&o.fill&&(o.textFill=o.fill),!o.hasOwnProperty("textStroke")&&o.stroke&&(o.textStroke=o.stroke));var s=function(e){return e=I({},e),A(["id","parentId","$action","hv","bounding"].concat(Rl),function(t){delete e[t]}),e}(t);e&&"merge"!==e?"replace"===e?(ov(i,u),av(n,a,s,u)):"remove"===e&&ov(i,u):i?i.attr(s):av(n,a,s,u);var l=u.get(n);l&&(l.__ecGraphicWidth=t.width,l.__ecGraphicHeight=t.height,function(t,e){var n=t.eventData;t.silent||t.ignore||n||(n=t.eventData={componentType:"graphic",componentIndex:e.componentIndex,name:t.name});n&&(n.info=t.info)}(l,h))})}},_relocate:function(t,e){for(var n=t.option.elements,i=this.group,r=this._elMap,a=n.length-1;0<=a;a--){var o=n[a],s=r.get(o.id);if(s){var l=s.parent;Wl(s,o,l===i?{width:e.getWidth(),height:e.getHeight()}:{width:l.__ecGraphicWidth||0,height:l.__ecGraphicHeight||0},null,{hv:o.hv,boundingMode:o.bounding})}}},_clear:function(){var e=this._elMap;e.each(function(t){ov(t,e)}),this._elMap=Q()},dispose:function(){this._clear()}});function lv(t,e){var n,i=[],r=t.seriesIndex;if(null==r||!(n=e.getSeriesByIndex(r)))return{point:[]};var a=n.getData(),o=Sr(a,t);if(null==o||o<0||O(o))return{point:[]};var s=a.getItemGraphicEl(o),l=n.coordinateSystem;if(n.getTooltipPosition)i=n.getTooltipPosition(o)||[];else if(l&&l.dataToPoint)i=l.dataToPoint(a.getValues(D(l.dimensions,function(t){return a.mapDimension(t)}),o,!0))||[];else if(s){var h=s.getBoundingRect().clone();h.applyTransform(s.transform),i=[h.x+h.width/2,h.y+h.height/2]}return{point:i,el:s}}var hv=A,uv=P,cv=Mr();function dv(t,e,n,i,r){var a=t.axis;if(!a.scale.isBlank()&&a.containData(e))if(t.involveSeries){var o=function(l,t){var h=t.axis,u=h.dim,c=l,d=[],f=Number.MAX_VALUE,p=-1;return hv(t.seriesModels,function(e,t){var n,i,r=e.getData().mapDimension(u,!0);if(e.getAxisTooltipData){var a=e.getAxisTooltipData(r,l,h);i=a.dataIndices,n=a.nestestValue}else{if(!(i=e.getData().indicesOfNearest(r[0],l,"category"===h.type?.5:null)).length)return;n=e.getData().get(r[0],i[0])}if(null!=n&&isFinite(n)){var o=l-n,s=Math.abs(o);s<=f&&((s<f||0<=o&&p<0)&&(f=s,p=o,c=n,d.length=0),hv(i,function(t){d.push({seriesIndex:e.seriesIndex,dataIndexInside:t,dataIndex:e.getData().getRawIndex(t)})}))}}),{payloadBatch:d,snapToValue:c}}(e,t),s=o.payloadBatch,l=o.snapToValue;s[0]&&null==r.seriesIndex&&I(r,s[0]),!i&&t.snap&&a.containData(l)&&null!=l&&(e=l),n.showPointer(t,e,s,r),n.showTooltip(t,o,l)}else n.showPointer(t,e)}function fv(t,e,n,i){t[e.key]={value:n,payloadBatch:i}}function pv(t,e,n,i){var r=n.payloadBatch,a=e.axis,o=a.model,s=e.axisPointerModel;if(e.triggerTooltip&&r.length){var l=e.coordSys.model,h=xm(l),u=t.map[h];u||(u=t.map[h]={coordSysId:l.id,coordSysIndex:l.componentIndex,coordSysType:l.type,coordSysMainType:l.mainType,dataByAxis:[]},t.list.push(u)),u.dataByAxis.push({axisDim:a.dim,axisIndex:o.componentIndex,axisType:o.type,axisId:o.id,value:i,valueLabelOpt:{precision:s.get("label.precision"),formatter:s.get("label.formatter")},seriesDataIndices:r.slice()})}}function gv(t){var e=t.axis.model,n={},i=n.axisDim=t.axis.dim;return n.axisIndex=n[i+"AxisIndex"]=e.componentIndex,n.axisName=n[i+"AxisName"]=e.name,n.axisId=n[i+"AxisId"]=e.id,n}function mv(t){return!t||null==t[0]||isNaN(t[0])||null==t[1]||isNaN(t[1])}Hd({type:"axisPointer",coordSysAxesInfo:null,defaultOption:{show:"auto",triggerOn:null,zlevel:0,z:50,type:"line",snap:!1,triggerTooltip:!0,value:null,status:null,link:[],animation:null,animationDurationUpdate:200,lineStyle:{color:"#aaa",width:1,type:"solid"},shadowStyle:{color:"rgba(150,150,150,0.3)"},label:{show:!0,formatter:null,precision:"auto",margin:3,color:"#fff",padding:[5,7,5,7],backgroundColor:"auto",borderColor:null,borderWidth:0,shadowBlur:3,shadowColor:"#aaa"},handle:{show:!1,icon:"M10.7,11.9v-1.3H9.3v1.3c-4.9,0.3-8.8,4.4-8.8,9.4c0,5,3.9,9.1,8.8,9.4h1.3c4.9-0.3,8.8-4.4,8.8-9.4C19.5,16.3,15.6,12.2,10.7,11.9z M13.3,24.4H6.7v-1.2h6.6z M13.3,22H6.7v-1.2h6.6z M13.3,19.6H6.7v-1.2h6.6z",size:45,margin:50,color:"#333",shadowBlur:3,shadowColor:"#aaa",shadowOffsetX:0,shadowOffsetY:2,throttle:40}}});var vv=Mr(),yv=A;function _v(t,e,n){if(!v.node){var i=e.getZr();vv(i).records||(vv(i).records={}),function(r,a){if(vv(r).initialized)return;function t(t,i){r.on(t,function(e){var n=function(n){var i={showTip:[],hideTip:[]},r=function(t){var e=i[t.type];e?e.push(t):(t.dispatchAction=r,n.dispatchAction(t))};return{dispatchAction:r,pendings:i}}(a);yv(vv(r).records,function(t){t&&i(t,e,n.dispatchAction)}),function(t,e){var n,i=t.showTip.length,r=t.hideTip.length;i?n=t.showTip[i-1]:r&&(n=t.hideTip[r-1]);n&&(n.dispatchAction=null,e.dispatchAction(n))}(n.pendings,a)})}vv(r).initialized=!0,t("click",P(wv,"click")),t("mousemove",P(wv,"mousemove")),t("globalout",xv)}(i,e),(vv(i).records[t]||(vv(i).records[t]={})).handler=n}}function xv(t,e,n){t.handler("leave",null,n)}function wv(t,e,n,i){e.handler(t,n,i)}function bv(t,e){if(!v.node){var n=e.getZr();(vv(n).records||{})[t]&&(vv(n).records[t]=null)}}var Sv=Wd({type:"axisPointer",render:function(t,e,n){var i=e.getComponent("tooltip"),r=t.get("triggerOn")||i&&i.get("triggerOn")||"mousemove|click";_v("axisPointer",n,function(t,e,n){"none"!==r&&("leave"===t||0<=r.indexOf(t))&&n({type:"updateAxisPointer",currTrigger:t,x:e&&e.offsetX,y:e&&e.offsetY})})},remove:function(t,e){bv(e.getZr(),"axisPointer"),Sv.superApply(this._model,"remove",arguments)},dispose:function(t,e){bv("axisPointer",e),Sv.superApply(this._model,"dispose",arguments)}}),Mv=Mr(),Iv=b,Cv=k;function Tv(){}function Av(t,e,n,i){!function n(i,t){{if(N(i)&&N(t)){var r=!0;return A(t,function(t,e){r=r&&n(i[e],t)}),!!r}return i===t}}(Mv(n).lastProp,i)&&(Mv(n).lastProp=i,e?Ns(n,i,t):(n.stopAnimation(),n.attr(i)))}function Dv(t,e){t[e.get("label.show")?"show":"hide"]()}function kv(t){return{position:t.position.slice(),rotation:t.rotation||0}}function Pv(t,e,n){var i=e.get("z"),r=e.get("zlevel");t&&t.traverse(function(t){"group"!==t.type&&(null!=i&&(t.z=i),null!=r&&(t.zlevel=r),t.silent=n)})}function Lv(t,e,n,i,r){var a=Ov(n.get("value"),e.axis,e.ecModel,n.get("seriesDataIndices"),{precision:n.get("label.precision"),formatter:n.get("label.formatter")}),o=n.getModel("label"),s=Sl(o.get("padding")||0),l=o.getFont(),h=ii(a,l),u=r.position,c=h.width+s[1]+s[3],d=h.height+s[0]+s[2],f=r.align;"right"===f&&(u[0]-=c),"center"===f&&(u[0]-=c/2);var p=r.verticalAlign;"bottom"===p&&(u[1]-=d),"middle"===p&&(u[1]-=d/2),function(t,e,n,i){var r=i.getWidth(),a=i.getHeight();t[0]=Math.min(t[0]+e,r)-e,t[1]=Math.min(t[1]+n,a)-n,t[0]=Math.max(t[0],0),t[1]=Math.max(t[1],0)}(u,c,d,i);var g=o.get("backgroundColor");g&&"auto"!==g||(g=e.get("axisLine.lineStyle.color")),t.label={shape:{x:0,y:0,width:c,height:d,r:o.get("borderRadius")},position:u.slice(),style:{text:a,textFont:l,textFill:o.getTextColor(),textPosition:"inside",textPadding:s,fill:g,stroke:o.get("borderColor")||"transparent",lineWidth:o.get("borderWidth")||0,shadowBlur:o.get("shadowBlur"),shadowColor:o.get("shadowColor"),shadowOffsetX:o.get("shadowOffsetX"),shadowOffsetY:o.get("shadowOffsetY")},z2:10}}function Ov(t,e,r,n,i){t=e.scale.parse(t);var a=e.scale.getLabel(t,{precision:i.precision}),o=i.formatter;if(o){var s={value:yp(e,t),axisDimension:e.dim,axisIndex:e.index,seriesData:[]};A(n,function(t){var e=r.getSeriesByIndex(t.seriesIndex),n=t.dataIndexInside,i=e&&e.getDataParams(n);i&&s.seriesData.push(i)}),E(o)?a=o.replace("{value}",a):z(o)&&(a=o(s))}return a}function zv(t,e,n){var i=qt();return te(i,i,n.rotation),Jt(i,i,n.position),Fs([t.dataToCoord(e),(n.labelOffset||0)+(n.labelDirection||1)*(n.labelMargin||0)],i)}Or((Tv.prototype={_group:null,_lastGraphicKey:null,_handle:null,_dragging:!1,_lastValue:null,_lastStatus:null,_payloadInfo:null,animationThreshold:15,render:function(t,e,n,i){var r=e.get("value"),a=e.get("status");if(this._axisModel=t,this._axisPointerModel=e,this._api=n,i||this._lastValue!==r||this._lastStatus!==a){this._lastValue=r,this._lastStatus=a;var o=this._group,s=this._handle;if(!a||"hide"===a)return o&&o.hide(),void(s&&s.hide());o&&o.show(),s&&s.show();var l={};this.makeElOption(l,r,t,e,n);var h=l.graphicKey;h!==this._lastGraphicKey&&this.clear(n),this._lastGraphicKey=h;var u=this._moveAnimation=this.determineAnimation(t,e);if(o){var c=P(Av,e,u);this.updatePointerEl(o,l,c,e),this.updateLabelEl(o,l,c,e)}else o=this._group=new yn,this.createPointerEl(o,l,t,e),this.createLabelEl(o,l,t,e),n.getZr().add(o);Pv(o,e,!0),this._renderHandle(r)}},remove:function(t){this.clear(t)},dispose:function(t){this.clear(t)},determineAnimation:function(t,e){var n=e.get("animation"),i=t.axis,r="category"===i.type,a=e.get("snap");if(!a&&!r)return!1;if("auto"!==n&&null!=n)return!0===n;var o=this.animationThreshold;if(r&&i.getBandWidth()>o)return!0;if(a){var s=ym(t).seriesDataCount,l=i.getExtent();return Math.abs(l[0]-l[1])/s>o}return!1},makeElOption:function(t,e,n,i,r){},createPointerEl:function(t,e,n,i){var r=e.pointer;if(r){var a=Mv(t).pointerEl=new Xs[r.type](Iv(e.pointer));t.add(a)}},createLabelEl:function(t,e,n,i){if(e.label){var r=Mv(t).labelEl=new No(Iv(e.label));t.add(r),Dv(r,i)}},updatePointerEl:function(t,e,n){var i=Mv(t).pointerEl;i&&e.pointer&&(i.setStyle(e.pointer.style),n(i,{shape:e.pointer.shape}))},updateLabelEl:function(t,e,n,i){var r=Mv(t).labelEl;r&&(r.setStyle(e.label.style),n(r,{shape:e.label.shape,position:e.label.position}),Dv(r,i))},_renderHandle:function(t){if(!this._dragging&&this.updateHandleTransform){var e,n=this._axisPointerModel,i=this._api.getZr(),r=this._handle,a=n.getModel("handle"),o=n.get("status");if(!a.get("show")||!o||"hide"===o)return r&&i.remove(r),void(this._handle=null);this._handle||(e=!0,r=this._handle=Gs(a.get("icon"),{cursor:"move",draggable:!0,onmousemove:function(t){Rt(t.event)},onmousedown:Cv(this._onHandleDragMove,this,0,0),drift:Cv(this._onHandleDragMove,this),ondragend:Cv(this._onHandleDragEnd,this)}),i.add(r)),Pv(r,n,!1);r.setStyle(a.getItemStyle(null,["color","borderColor","borderWidth","opacity","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"]));var s=a.get("size");O(s)||(s=[s,s]),r.attr("scale",[s[0]/2,s[1]/2]),qu(this,"_doDispatchAxisPointer",a.get("throttle")||0,"fixRate"),this._moveHandleToValue(t,e)}},_moveHandleToValue:function(t,e){Av(this._axisPointerModel,!e&&this._moveAnimation,this._handle,kv(this.getHandleTransform(t,this._axisModel,this._axisPointerModel)))},_onHandleDragMove:function(t,e){var n=this._handle;if(n){this._dragging=!0;var i=this.updateHandleTransform(kv(n),[t,e],this._axisModel,this._axisPointerModel);this._payloadInfo=i,n.stopAnimation(),n.attr(kv(i)),Mv(n).lastProp=null,this._doDispatchAxisPointer()}},_doDispatchAxisPointer:function(){if(this._handle){var t=this._payloadInfo,e=this._axisModel;this._api.dispatchAction({type:"updateAxisPointer",x:t.cursorPoint[0],y:t.cursorPoint[1],tooltipOption:t.tooltipOption,axesInfo:[{axisDim:e.axis.dim,axisIndex:e.componentIndex}]})}},_onHandleDragEnd:function(t){if(this._dragging=!1,this._handle){var e=this._axisPointerModel.get("value");this._moveHandleToValue(e),this._api.dispatchAction({type:"hideTip"})}},getHandleTransform:null,updateHandleTransform:null,clear:function(t){this._lastValue=null,this._lastStatus=null;var e=t.getZr(),n=this._group,i=this._handle;e&&n&&(this._lastGraphicKey=null,n&&e.remove(n),i&&e.remove(i),this._group=null,this._handle=null,this._payloadInfo=null)},doClear:function(){},buildLabel:function(t,e,n){return{x:t[n=n||0],y:t[1-n],width:e[n],height:e[1-n]}}}).constructor=Tv);var Ev=Tv.extend({makeElOption:function(t,e,n,i,r){var a=n.axis,o=a.grid,s=i.get("type"),l=Nv(o,a).getOtherAxis(a).getGlobalExtent(),h=a.toGlobalCoord(a.dataToCoord(e,!0));if(s&&"none"!==s){var u=function(t){var e,n=t.get("type"),i=t.getModel(n+"Style");return"line"===n?(e=i.getLineStyle()).fill=null:"shadow"===n&&((e=i.getAreaStyle()).stroke=null),e}(i),c=Rv[s](a,h,l);c.style=u,t.graphicKey=c.type,t.pointer=c}!function(t,e,n,i,r,a){var o=am.innerTextLayout(n.rotation,0,n.labelDirection);n.labelMargin=r.get("label.margin"),Lv(e,i,r,a,{position:zv(i.axis,t,n),align:o.textAlign,verticalAlign:o.textVerticalAlign})}(e,t,Im(o.model,n),n,i,r)},getHandleTransform:function(t,e,n){var i=Im(e.axis.grid.model,e,{labelInside:!1});return i.labelMargin=n.get("handle.margin"),{position:zv(e.axis,t,i),rotation:i.rotation+(i.labelDirection<0?Math.PI:0)}},updateHandleTransform:function(t,e,n,i){var r=n.axis,a=r.grid,o=r.getGlobalExtent(!0),s=Nv(a,r).getOtherAxis(r).getGlobalExtent(),l="x"===r.dim?0:1,h=t.position;h[l]+=e[l],h[l]=Math.min(o[1],h[l]),h[l]=Math.max(o[0],h[l]);var u=(s[1]+s[0])/2,c=[u,u];c[l]=h[l];return{position:h,rotation:t.rotation,cursorPoint:c,tooltipOption:[{verticalAlign:"middle"},{align:"center"}][l]}}});function Nv(t,e){var n={};return n[e.dim+"AxisIndex"]=e.index,t.getCartesian(n)}var Rv={line:function(t,e,n){return{type:"Line",subPixelOptimize:!0,shape:function(t,e,n){return{x1:t[n=n||0],y1:t[1-n],x2:e[n],y2:e[1-n]}}([e,n[0]],[e,n[1]],Bv(t))}},shadow:function(t,e,n){var i=Math.max(1,t.getBandWidth()),r=n[1]-n[0];return{type:"Rect",shape:function(t,e,n){return{x:t[n=n||0],y:t[1-n],width:e[n],height:e[1-n]}}([e-i/2,n[0]],[i,r],Bv(t))}}};function Bv(t){return"x"===t.dim?0:1}wm.registerAxisPointerClass("CartesianAxisPointer",Ev),zd(function(t){if(t){t.axisPointer&&0!==t.axisPointer.length||(t.axisPointer={});var e=t.axisPointer.link;e&&!O(e)&&(t.axisPointer.link=[e])}}),Ed(Yc.PROCESSOR.STATISTIC,function(t,e){t.getComponent("axisPointer").coordSysAxesInfo=mm(t,e)}),Nd({type:"updateAxisPointer",event:"updateAxisPointer",update:":updateAxisPointer"},function(t,e,n){var i=t.currTrigger,o=[t.x,t.y],r=t,a=t.dispatchAction||k(n.dispatchAction,n),s=e.getComponent("axisPointer").coordSysAxesInfo;if(s){mv(o)&&(o=lv({seriesIndex:r.seriesIndex,dataIndex:r.dataIndex},e).point);var l=mv(o),h=r.axesInfo,u=s.axesInfo,c="leave"===i||mv(o),d={},f={},p={list:[],map:{}},g={showPointer:uv(fv,f),showTooltip:uv(pv,p)};hv(s.coordSysMap,function(t,e){var a=l||t.containPoint(o);hv(s.coordSysAxesInfo[e],function(t,e){var n=t.axis,i=function(t,e){for(var n=0;n<(t||[]).length;n++){var i=t[n];if(e.axis.dim===i.axisDim&&e.axis.model.componentIndex===i.axisIndex)return i}}(h,t);if(!c&&a&&(!h||i)){var r=i&&i.value;null!=r||l||(r=n.pointToData(o)),null!=r&&dv(t,r,g,!1,d)}})});var m={};return hv(u,function(r,t){var a=r.linkGroup;a&&!f[t]&&hv(a.axesInfo,function(t,e){var n=f[e];if(t!==r&&n){var i=n.value;a.mapper&&(i=r.axis.scale.parse(a.mapper(i,gv(t),gv(r)))),m[r.key]=i}})}),hv(m,function(t,e){dv(u[e],t,g,!0,d)}),function(r,t,e){var a=e.axesInfo=[];hv(t,function(t,e){var n=t.axisPointerModel.option,i=r[e];i?(t.useHandle||(n.status="show"),n.value=i.value,n.seriesDataIndices=(i.payloadBatch||[]).slice()):t.useHandle||(n.status="hide"),"show"===n.status&&a.push({axisDim:t.axis.dim,axisIndex:t.axis.model.componentIndex,value:n.value})})}(f,u,d),function(t,e,n,i){if(mv(e)||!t.list.length)return i({type:"hideTip"});var r=((t.list[0].dataByAxis[0]||{}).seriesDataIndices||[])[0]||{};i({type:"showTip",escapeConnect:!0,x:e[0],y:e[1],tooltipOption:n.tooltipOption,position:n.position,dataIndexInside:r.dataIndexInside,dataIndex:r.dataIndex,seriesIndex:r.seriesIndex,dataByCoordSys:t.list})}(p,o,t,a),function(t,e,n){var i=n.getZr(),r="axisPointerLastHighlights",a=cv(i)[r]||{},o=cv(i)[r]={};hv(t,function(t,e){var n=t.axisPointerModel.option;"show"===n.status&&hv(n.seriesDataIndices,function(t){var e=t.seriesIndex+" | "+t.dataIndex;o[e]=t})});var s=[],l=[];A(a,function(t,e){o[e]||l.push(t)}),A(o,function(t,e){a[e]||s.push(t)}),l.length&&n.dispatchAction({type:"downplay",escapeConnect:!0,batch:l}),s.length&&n.dispatchAction({type:"highlight",escapeConnect:!0,batch:s})}(u,0,n),d}}),Hd({type:"tooltip",dependencies:["axisPointer"],defaultOption:{zlevel:0,z:60,show:!0,showContent:!0,trigger:"item",triggerOn:"mousemove|click",alwaysShowContent:!1,displayMode:"single",renderMode:"auto",confine:!1,showDelay:0,hideDelay:100,transitionDuration:.4,enterable:!1,backgroundColor:"rgba(50,50,50,0.7)",borderColor:"#333",borderRadius:4,borderWidth:0,padding:5,extraCssText:"",axisPointer:{type:"line",axis:"auto",animation:"auto",animationDurationUpdate:200,animationEasingUpdate:"exponentialOut",crossStyle:{color:"#999",width:1,type:"dashed",textStyle:{}}},textStyle:{color:"#fff",fontSize:14}}});var Fv=A,Vv=bl,Hv=["","-webkit-","-moz-","-o-"];function Wv(r){var a=[],t=r.get("transitionDuration"),e=r.get("backgroundColor"),n=r.getModel("textStyle"),i=r.get("padding");return t&&a.push(function(t){var e="cubic-bezier(0.23, 1, 0.32, 1)",n="left "+t+"s "+e+",top "+t+"s "+e;return D(Hv,function(t){return t+"transition:"+n}).join(";")}(t)),e&&(v.canvasSupported?a.push("background-Color:"+e):(a.push("background-Color:#"+Oe(e)),a.push("filter:alpha(opacity=70)"))),Fv(["width","color","radius"],function(t){var e="border-"+t,n=Vv(e),i=r.get(n);null!=i&&a.push(e+":"+i+("color"===t?"":"px"))}),a.push(function(n){var i=[],t=n.get("fontSize"),e=n.getTextColor();return e&&i.push("color:"+e),i.push("font:"+n.getFont()),t&&i.push("line-height:"+Math.round(3*t/2)+"px"),Fv(["decoration","align"],function(t){var e=n.get(t);e&&i.push("text-"+t+":"+e)}),i.join(";")}(n)),null!=i&&a.push("padding:"+Sl(i).join("px ")+"px"),a.join(";")+";"}function Gv(n,t){if(v.wxa)return null;var e=document.createElement("div"),i=this._zr=t.getZr();this.el=e,this._x=t.getWidth()/2,this._y=t.getHeight()/2,n.appendChild(e),this._container=n,this._show=!1,this._hideTimeout;var r=this;e.onmouseenter=function(){r._enterable&&(clearTimeout(r._hideTimeout),r._show=!0),r._inContent=!0},e.onmousemove=function(t){if(t=t||window.event,!r._enterable){var e=i.handler;Et(n,t,!0),e.dispatch("mousemove",t)}},e.onmouseleave=function(){r._enterable&&r._show&&r.hideLater(r._hideDelay),r._inContent=!1}}function Zv(t){this._zr=t.getZr(),this._show=!1,this._hideTimeout}Gv.prototype={constructor:Gv,_enterable:!0,update:function(){var t=this._container,e=t.currentStyle||document.defaultView.getComputedStyle(t),n=t.style;"absolute"!==n.position&&"absolute"!==e.position&&(n.position="relative")},show:function(t){clearTimeout(this._hideTimeout);var e=this.el;e.style.cssText="position:absolute;display:block;border-style:solid;white-space:nowrap;z-index:9999999;"+Wv(t)+";left:"+this._x+"px;top:"+this._y+"px;"+(t.get("extraCssText")||""),e.style.display=e.innerHTML?"block":"none",e.style.pointerEvents=this._enterable?"auto":"none",this._show=!0},setContent:function(t){this.el.innerHTML=null==t?"":t},setEnterable:function(t){this._enterable=t},getSize:function(){var t=this.el;return[t.clientWidth,t.clientHeight]},moveTo:function(t,e){var n,i=this._zr;i&&i.painter&&(n=i.painter.getViewportRootOffset())&&(t+=n.offsetLeft,e+=n.offsetTop);var r=this.el.style;r.left=t+"px",r.top=e+"px",this._x=t,this._y=e},hide:function(){this.el.style.display="none",this._show=!1},hideLater:function(t){!this._show||this._inContent&&this._enterable||(t?(this._hideDelay=t,this._show=!1,this._hideTimeout=setTimeout(k(this.hide,this),t)):this.hide())},isShow:function(){return this._show},getOuterSize:function(){var t=this.el.clientWidth,e=this.el.clientHeight;if(document.defaultView&&document.defaultView.getComputedStyle){var n=document.defaultView.getComputedStyle(this.el);n&&(t+=parseInt(n.borderLeftWidth,10)+parseInt(n.borderRightWidth,10),e+=parseInt(n.borderTopWidth,10)+parseInt(n.borderBottomWidth,10))}return{width:t,height:e}}},Zv.prototype={constructor:Zv,_enterable:!0,update:function(){},show:function(t){this._hideTimeout&&clearTimeout(this._hideTimeout),this.el.attr("show",!0),this._show=!0},setContent:function(t,e,n){this.el&&this._zr.remove(this.el);for(var i={},r=t,a="{marker",o=r.indexOf(a);0<=o;){var s=r.indexOf("|}"),l=r.substr(o+a.length,s-o-a.length);-1<l.indexOf("sub")?i["marker"+l]={textWidth:4,textHeight:4,textBorderRadius:2,textBackgroundColor:e[l],textOffset:[3,0]}:i["marker"+l]={textWidth:10,textHeight:10,textBorderRadius:5,textBackgroundColor:e[l]},o=(r=r.substr(s+1)).indexOf("{marker")}this.el=new wo({style:{rich:i,text:t,textLineHeight:20,textBackgroundColor:n.get("backgroundColor"),textBorderRadius:n.get("borderRadius"),textFill:n.get("textStyle.color"),textPadding:n.get("padding")},z:n.get("z")}),this._zr.add(this.el);var h=this;this.el.on("mouseover",function(){h._enterable&&(clearTimeout(h._hideTimeout),h._show=!0),h._inContent=!0}),this.el.on("mouseout",function(){h._enterable&&h._show&&h.hideLater(h._hideDelay),h._inContent=!1})},setEnterable:function(t){this._enterable=t},getSize:function(){var t=this.el.getBoundingRect();return[t.width,t.height]},moveTo:function(t,e){this.el&&this.el.attr("position",[t,e])},hide:function(){this.el&&this.el.hide(),this._show=!1},hideLater:function(t){!this._show||this._inContent&&this._enterable||(t?(this._hideDelay=t,this._show=!1,this._hideTimeout=setTimeout(k(this.hide,this),t)):this.hide())},isShow:function(){return this._show},getOuterSize:function(){var t=this.getSize();return{width:t[0],height:t[1]}}};var Uv=k,Xv=A,Yv=ol,jv=new No({shape:{x:-1,y:-1,width:2,height:2}});function qv(t){for(var e=t.pop();t.length;){var n=t.pop();n&&(Js.isInstance(n)&&(n=n.get("tooltip",!0)),"string"==typeof n&&(n={formatter:n}),e=new Js(n,e,e.ecModel))}return e}function $v(t,e){return t.dispatchAction||k(e.dispatchAction,e)}function Kv(t){return"center"===t||"middle"===t}Wd({type:"tooltip",init:function(t,e){if(!v.node){var n,i=t.getComponent("tooltip").get("renderMode");this._renderMode=Dr(i),"html"===this._renderMode?(n=new Gv(e.getDom(),e),this._newLine="<br/>"):(n=new Zv(e),this._newLine="\n"),this._tooltipContent=n}},render:function(t,e,n){if(!v.node){this.group.removeAll(),this._tooltipModel=t,this._ecModel=e,this._api=n,this._lastDataByCoordSys=null,this._alwaysShowContent=t.get("alwaysShowContent");var i=this._tooltipContent;i.update(),i.setEnterable(t.get("enterable")),this._initGlobalListener(),this._keepShow()}},_initGlobalListener:function(){var i=this._tooltipModel.get("triggerOn");_v("itemTooltip",this._api,Uv(function(t,e,n){"none"!==i&&(0<=i.indexOf(t)?this._tryShow(e,n):"leave"===t&&this._hide(n))},this))},_keepShow:function(){var t=this._tooltipModel,e=this._ecModel,n=this._api;if(null!=this._lastX&&null!=this._lastY&&"none"!==t.get("triggerOn")){var i=this;clearTimeout(this._refreshUpdateTimeout),this._refreshUpdateTimeout=setTimeout(function(){n.isDisposed()||i.manuallyShowTip(t,e,n,{x:i._lastX,y:i._lastY})})}},manuallyShowTip:function(t,e,n,i){if(i.from!==this.uid&&!v.node){var r=$v(i,n);this._ticket="";var a=i.dataByCoordSys;if(i.tooltip&&null!=i.x&&null!=i.y){var o=jv;o.position=[i.x,i.y],o.update(),o.tooltip=i.tooltip,this._tryShow({offsetX:i.x,offsetY:i.y,target:o},r)}else if(a)this._tryShow({offsetX:i.x,offsetY:i.y,position:i.position,event:{},dataByCoordSys:i.dataByCoordSys,tooltipOption:i.tooltipOption},r);else if(null!=i.seriesIndex){if(this._manuallyAxisShowTip(t,e,n,i))return;var s=lv(i,e),l=s.point[0],h=s.point[1];null!=l&&null!=h&&this._tryShow({offsetX:l,offsetY:h,position:i.position,target:s.el,event:{}},r)}else null!=i.x&&null!=i.y&&(n.dispatchAction({type:"updateAxisPointer",x:i.x,y:i.y}),this._tryShow({offsetX:i.x,offsetY:i.y,position:i.position,target:n.getZr().findHover(i.x,i.y).target,event:{}},r))}},manuallyHideTip:function(t,e,n,i){var r=this._tooltipContent;!this._alwaysShowContent&&this._tooltipModel&&r.hideLater(this._tooltipModel.get("hideDelay")),this._lastX=this._lastY=null,i.from!==this.uid&&this._hide($v(i,n))},_manuallyAxisShowTip:function(t,e,n,i){var r=i.seriesIndex,a=i.dataIndex,o=e.getComponent("axisPointer").coordSysAxesInfo;if(null!=r&&null!=a&&null!=o){var s=e.getSeriesByIndex(r);if(s)if("axis"===(t=qv([s.getData().getItemModel(a),s,(s.coordinateSystem||{}).model,t])).get("trigger"))return n.dispatchAction({type:"updateAxisPointer",seriesIndex:r,dataIndex:a,position:i.position}),!0}},_tryShow:function(t,e){var n=t.target;if(this._tooltipModel){this._lastX=t.offsetX,this._lastY=t.offsetY;var i=t.dataByCoordSys;i&&i.length?this._showAxisTooltip(i,t):n&&null!=n.dataIndex?(this._lastDataByCoordSys=null,this._showSeriesItemTooltip(t,n,e)):n&&n.tooltip?(this._lastDataByCoordSys=null,this._showComponentItemTooltip(t,n,e)):(this._lastDataByCoordSys=null,this._hide(e))}},_showOrMove:function(t,e){var n=t.get("showDelay");e=k(e,this),clearTimeout(this._showTimout),0<n?this._showTimout=setTimeout(e,n):e()},_showAxisTooltip:function(t,e){var d=this._ecModel,n=this._tooltipModel,i=[e.offsetX,e.offsetY],r=[],f=[],a=qv([e.tooltipOption,n]),p=this._renderMode,o=this._newLine,g={};Xv(t,function(t){Xv(t.dataByAxis,function(s){var l=d.getComponent(s.axisDim+"Axis",s.axisIndex),h=s.value,u=[];if(l&&null!=h){var c=Ov(h,l.axis,d,s.seriesDataIndices,s.valueLabelOpt);A(s.seriesDataIndices,function(t){var e=d.getSeriesByIndex(t.seriesIndex),n=t.dataIndexInside,i=e&&e.getDataParams(n);if(i.axisDim=s.axisDim,i.axisIndex=s.axisIndex,i.axisType=s.axisType,i.axisId=s.axisId,i.axisValue=yp(l.axis,h),i.axisValueLabel=c,i){f.push(i);var r,a=e.formatTooltip(n,!0,null,p);if(N(a)){r=a.html;var o=a.markers;m(g,o)}else r=a;u.push(r)}});var t=c;"html"!==p?r.push(u.join(o)):r.push((t?Cl(t)+o:"")+u.join(o))}})},this),r.reverse(),r=r.join(this._newLine+this._newLine);var s=e.position;this._showOrMove(a,function(){this._updateContentNotChangedOnAxis(t)?this._updatePosition(a,s,i[0],i[1],this._tooltipContent,f):this._showTooltipContent(a,r,f,Math.random(),i[0],i[1],s,void 0,g)})},_showSeriesItemTooltip:function(t,e,n){var i=this._ecModel,r=e.seriesIndex,a=i.getSeriesByIndex(r),o=e.dataModel||a,s=e.dataIndex,l=e.dataType,h=o.getData(),u=qv([h.getItemModel(s),o,a&&(a.coordinateSystem||{}).model,this._tooltipModel]),c=u.get("trigger");if(null==c||"item"===c){var d,f,p=o.getDataParams(s,l),g=o.formatTooltip(s,!1,l,this._renderMode);f=N(g)?(d=g.html,g.markers):(d=g,null);var m="item_"+o.name+"_"+s;this._showOrMove(u,function(){this._showTooltipContent(u,d,p,m,t.offsetX,t.offsetY,t.position,t.target,f)}),n({type:"showTip",dataIndexInside:s,dataIndex:h.getRawIndex(s),seriesIndex:r,from:this.uid})}},_showComponentItemTooltip:function(t,e,n){var i=e.tooltip;if("string"==typeof i){i={content:i,formatter:i}}var r=new Js(i,this._tooltipModel,this._ecModel),a=r.get("content"),o=Math.random();this._showOrMove(r,function(){this._showTooltipContent(r,a,r.get("formatterParams")||{},o,t.offsetX,t.offsetY,t.position,e)}),n({type:"showTip",from:this.uid})},_showTooltipContent:function(n,t,i,e,r,a,o,s,l){if(this._ticket="",n.get("showContent")&&n.get("show")){var h=this._tooltipContent,u=n.get("formatter");o=o||n.get("position");var c=t;if(u&&"string"==typeof u)c=Dl(u,i,!0);else if("function"==typeof u){var d=Uv(function(t,e){t===this._ticket&&(h.setContent(e,l,n),this._updatePosition(n,o,r,a,h,i,s))},this);this._ticket=e,c=u(i,e,d)}h.setContent(c,l,n),h.show(n),this._updatePosition(n,o,r,a,h,i,s)}},_updatePosition:function(t,e,n,i,r,a,o){var s=this._api.getWidth(),l=this._api.getHeight();e=e||t.get("position");var h=r.getSize(),u=t.get("align"),c=t.get("verticalAlign"),d=o&&o.getBoundingRect().clone();if(o&&d.applyTransform(o.transform),"function"==typeof e&&(e=e([n,i],a,r.el,d,{viewSize:[s,l],contentSize:h.slice()})),O(e))n=Yv(e[0],s),i=Yv(e[1],l);else if(N(e)){e.width=h[0],e.height=h[1];var f=Hl(e,{width:s,height:l});n=f.x,i=f.y,c=u=null}else if("string"==typeof e&&o){n=(p=function(t,e,n){var i=n[0],r=n[1],a=0,o=0,s=e.width,l=e.height;switch(t){case"inside":a=e.x+s/2-i/2,o=e.y+l/2-r/2;break;case"top":a=e.x+s/2-i/2,o=e.y-r-5;break;case"bottom":a=e.x+s/2-i/2,o=e.y+l+5;break;case"left":a=e.x-i-5,o=e.y+l/2-r/2;break;case"right":a=e.x+s+5,o=e.y+l/2-r/2}return[a,o]}(e,d,h))[0],i=p[1]}else{var p;n=(p=function(t,e,n,i,r,a,o){var s=n.getOuterSize(),l=s.width,h=s.height;null!=a&&(i<t+l+a?t-=l+a:t+=a);null!=o&&(r<e+h+o?e-=h+o:e+=o);return[t,e]}(n,i,r,s,l,u?null:20,c?null:20))[0],i=p[1]}u&&(n-=Kv(u)?h[0]/2:"right"===u?h[0]:0),c&&(i-=Kv(c)?h[1]/2:"bottom"===c?h[1]:0),t.get("confine")&&(n=(p=function(t,e,n,i,r){var a=n.getOuterSize(),o=a.width,s=a.height;return t=Math.min(t+o,i)-o,e=Math.min(e+s,r)-s,t=Math.max(t,0),e=Math.max(e,0),[t,e]}(n,i,r,s,l))[0],i=p[1]);r.moveTo(n,i)},_updateContentNotChangedOnAxis:function(i){var t=this._lastDataByCoordSys,o=!!t&&t.length===i.length;return o&&Xv(t,function(t,e){var n=t.dataByAxis||{},a=(i[e]||{}).dataByAxis||[];(o&=n.length===a.length)&&Xv(n,function(t,e){var n=a[e]||{},i=t.seriesDataIndices||[],r=n.seriesDataIndices||[];(o&=t.value===n.value&&t.axisType===n.axisType&&t.axisId===n.axisId&&i.length===r.length)&&Xv(i,function(t,e){var n=r[e];o&=t.seriesIndex===n.seriesIndex&&t.dataIndex===n.dataIndex})})}),this._lastDataByCoordSys=i,!!o},_hide:function(t){this._lastDataByCoordSys=null,t({type:"hideTip",from:this.uid})},dispose:function(t,e){v.node||(this._tooltipContent.hide(),bv("itemTooltip",e))}}),Nd({type:"showTip",event:"showTip",update:"tooltip:manuallyShowTip"},function(){}),Nd({type:"hideTip",event:"hideTip",update:"tooltip:manuallyHideTip"},function(){});var Qv=Hd({type:"legend.plain",dependencies:["series"],layoutMode:{type:"box",ignoreSize:!0},init:function(t,e,n){this.mergeDefaultAndTheme(t,n),t.selected=t.selected||{}},mergeOption:function(t){Qv.superCall(this,"mergeOption",t)},optionUpdated:function(){this._updateData(this.ecModel);var t=this._data;if(t[0]&&"single"===this.get("selectedMode")){for(var e=!1,n=0;n<t.length;n++){var i=t[n].get("name");if(this.isSelected(i)){this.select(i),e=!0;break}}e||this.select(t[0].get("name"))}},_updateData:function(a){var o=[],s=[];a.eachRawSeries(function(t){var e,n=t.name;if(s.push(n),t.legendDataProvider){var i=t.legendDataProvider(),r=i.mapArray(i.getName);a.isSeriesFiltered(t)||(s=s.concat(r)),r.length?o=o.concat(r):e=!0}else e=!0;e&&wr(t)&&o.push(t.name)}),this._availableNames=s;var t=D(this.get("data")||o,function(t){return"string"!=typeof t&&"number"!=typeof t||(t={name:t}),new Js(t,this,this.ecModel)},this);this._data=t},getData:function(){return this._data},select:function(t){var e=this.option.selected;"single"===this.get("selectedMode")&&A(this._data,function(t){e[t.get("name")]=!1});e[t]=!0},unSelect:function(t){"single"!==this.get("selectedMode")&&(this.option.selected[t]=!1)},toggleSelected:function(t){var e=this.option.selected;e.hasOwnProperty(t)||(e[t]=!0),this[e[t]?"unSelect":"select"](t)},isSelected:function(t){var e=this.option.selected;return!(e.hasOwnProperty(t)&&!e[t])&&0<=x(this._availableNames,t)},defaultOption:{zlevel:0,z:4,show:!0,orient:"horizontal",left:"center",top:0,align:"auto",backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderRadius:0,borderWidth:0,padding:5,itemGap:10,itemWidth:25,itemHeight:14,inactiveColor:"#ccc",textStyle:{color:"#333"},selectedMode:!0,tooltip:{show:!1}}});function Jv(t,e,n){var r,a={},o="toggleSelected"===t;return n.eachComponent("legend",function(i){o&&null!=r?i[r?"select":"unSelect"](e.name):(i[t](e.name),r=i.isSelected(e.name)),A(i.getData(),function(t){var e=t.get("name");if("\n"!==e&&""!==e){var n=i.isSelected(e);a.hasOwnProperty(e)?a[e]=a[e]&&n:a[e]=n}})}),{name:e.name,selected:a}}function ty(t,e){var n=Sl(e.get("padding")),i=e.getItemStyle(["color","opacity"]);return i.fill=e.get("backgroundColor"),t=new No({shape:{x:t.x-n[3],y:t.y-n[0],width:t.width+n[1]+n[3],height:t.height+n[0]+n[2],r:e.get("borderRadius")},style:i,silent:!0,z2:-1})}Nd("legendToggleSelect","legendselectchanged",P(Jv,"toggleSelected")),Nd("legendSelect","legendselected",P(Jv,"select")),Nd("legendUnSelect","legendunselected",P(Jv,"unSelect"));var ey=P,ny=A,iy=yn,ry=Wd({type:"legend.plain",newlineDisabled:!1,init:function(){this.group.add(this._contentGroup=new iy),this._backgroundEl,this._isFirstRender=!0},getContentGroup:function(){return this._contentGroup},render:function(t,e,n){var i=this._isFirstRender;if(this._isFirstRender=!1,this.resetInner(),t.get("show",!0)){var r=t.get("align");r&&"auto"!==r||(r="right"===t.get("left")&&"vertical"===t.get("orient")?"right":"left"),this.renderInner(r,t,e,n);var a=t.getBoxLayoutParams(),o={width:n.getWidth(),height:n.getHeight()},s=t.get("padding"),l=Hl(a,o,s),h=this.layoutInner(t,r,l,i),u=Hl(T({width:h.width,height:h.height},a),o,s);this.group.attr("position",[u.x-h.x,u.y-h.y]),this.group.add(this._backgroundEl=ty(h,t))}},resetInner:function(){this.getContentGroup().removeAll(),this._backgroundEl&&this.group.remove(this._backgroundEl)},renderInner:function(l,h,u,c){var d=this.getContentGroup(),f=Q(),p=h.get("selectedMode"),g=[];u.eachRawSeries(function(t){t.get("legendHoverLink")||g.push(t.id)}),ny(h.getData(),function(r,a){var o=r.get("name");if(this.newlineDisabled||""!==o&&"\n"!==o){var t=u.getSeriesByName(o)[0];if(!f.get(o))if(t){var e=t.getData(),n=e.getVisual("color");"function"==typeof n&&(n=n(t.getDataParams(0)));var i=e.getVisual("legendSymbol")||"roundRect",s=e.getVisual("symbol");this._createItem(o,a,r,h,i,s,l,n,p).on("click",ey(ay,o,c)).on("mouseover",ey(oy,t.name,null,c,g)).on("mouseout",ey(sy,t.name,null,c,g)),f.set(o,!0)}else u.eachRawSeries(function(t){if(!f.get(o)&&t.legendDataProvider){var e=t.legendDataProvider(),n=e.indexOfName(o);if(n<0)return;var i=e.getItemVisual(n,"color");this._createItem(o,a,r,h,"roundRect",null,l,i,p).on("click",ey(ay,o,c)).on("mouseover",ey(oy,null,o,c,g)).on("mouseout",ey(sy,null,o,c,g)),f.set(o,!0)}},this)}else d.add(new iy({newline:!0}))},this)},_createItem:function(t,e,n,i,r,a,o,s,l){var h=i.get("itemWidth"),u=i.get("itemHeight"),c=i.get("inactiveColor"),d=i.get("symbolKeepAspect"),f=i.isSelected(t),p=new iy,g=n.getModel("textStyle"),m=n.get("icon"),v=n.getModel("tooltip"),y=v.parentModel;if(r=m||r,p.add(kp(r,0,0,h,u,f?s:c,null==d||d)),!m&&a&&(a!==r||"none"===a)){var _=.8*u;"none"===a&&(a="circle"),p.add(kp(a,(h-_)/2,(u-_)/2,_,_,f?s:c,null==d||d))}var x="left"===o?h+5:-5,w=o,b=i.get("formatter"),S=t;"string"==typeof b&&b?S=b.replace("{name}",null!=t?t:""):"function"==typeof b&&(S=b(t)),p.add(new wo({style:As({},g,{text:S,x:x,y:u/2,textFill:f?g.getTextColor():c,textAlign:w,textVerticalAlign:"middle"})}));var M=new No({shape:p.getBoundingRect(),invisible:!0,tooltip:v.get("show")?I({content:t,formatter:y.get("formatter",!0)||function(){return t},formatterParams:{componentType:"legend",legendIndex:i.componentIndex,name:t,$vars:["name"]}},v.option):null});return p.add(M),p.eachChild(function(t){t.silent=!0}),M.silent=!l,this.getContentGroup().add(p),Ss(p),p.__legendDataIndex=e,p},layoutInner:function(t,e,n){var i=this.getContentGroup();Vl(t.get("orient"),i,t.get("itemGap"),n.width,n.height);var r=i.getBoundingRect();return i.attr("position",[-r.x,-r.y]),this.group.getBoundingRect()},remove:function(){this.getContentGroup().removeAll(),this._isFirstRender=!0}});function ay(t,e){e.dispatchAction({type:"legendToggleSelect",name:t})}function oy(t,e,n,i){var r=n.getZr().storage.getDisplayList()[0];r&&r.useHoverLayer||n.dispatchAction({type:"highlight",seriesName:t,name:e,excludeSeriesId:i})}function sy(t,e,n,i){var r=n.getZr().storage.getDisplayList()[0];r&&r.useHoverLayer||n.dispatchAction({type:"downplay",seriesName:t,name:e,excludeSeriesId:i})}Ed(function(t){var n=t.findComponents({mainType:"legend"});n&&n.length&&t.filterSeries(function(t){for(var e=0;e<n.length;e++)if(!n[e].isSelected(t.name))return!1;return!0})}),$l.registerSubTypeDefaulter("legend",function(){return"plain"});var ly=Qv.extend({type:"legend.scroll",setScrollDataIndex:function(t){this.option.scrollDataIndex=t},defaultOption:{scrollDataIndex:0,pageButtonItemGap:5,pageButtonGap:null,pageButtonPosition:"end",pageFormatter:"{current}/{total}",pageIcons:{horizontal:["M0,0L12,-10L12,10z","M0,0L-12,-10L-12,10z"],vertical:["M0,0L20,0L10,-20z","M0,0L20,0L10,20z"]},pageIconColor:"#2f4554",pageIconInactiveColor:"#aaa",pageIconSize:15,pageTextStyle:{color:"#333"},animationDurationUpdate:800},init:function(t,e,n,i){var r=Zl(t);ly.superCall(this,"init",t,e,n,i),hy(this,t,r)},mergeOption:function(t,e){ly.superCall(this,"mergeOption",t,e),hy(this,this.option,t)},getOrient:function(){return"vertical"===this.get("orient")?{index:1,name:"vertical"}:{index:0,name:"horizontal"}}});function hy(t,e,n){var i=[1,1];i[t.getOrient().index]=0,Gl(e,n,{type:"box",ignoreSize:i})}var uy=yn,cy=["width","height"],dy=["x","y"],fy=ry.extend({type:"legend.scroll",newlineDisabled:!0,init:function(){fy.superCall(this,"init"),this._currentIndex=0,this.group.add(this._containerGroup=new uy),this._containerGroup.add(this.getContentGroup()),this.group.add(this._controllerGroup=new uy),this._showController},resetInner:function(){fy.superCall(this,"resetInner"),this._controllerGroup.removeAll(),this._containerGroup.removeClipPath(),this._containerGroup.__rectSize=null},renderInner:function(t,r,e,a){var o=this;fy.superCall(this,"renderInner",t,r,e,a);var s=this._controllerGroup,l=r.get("pageIconSize",!0);O(l)||(l=[l,l]),i("pagePrev",0);var n=r.getModel("pageTextStyle");function i(t,e){var n=t+"DataIndex",i=Gs(r.get("pageIcons",!0)[r.getOrient().name][e],{onclick:k(o._pageGo,o,n,r,a)},{x:-l[0]/2,y:-l[1]/2,width:l[0],height:l[1]});i.name=t,s.add(i)}s.add(new wo({name:"pageText",style:{textFill:n.getTextColor(),font:n.getFont(),textVerticalAlign:"middle",textAlign:"center"},silent:!0})),i("pageNext",1)},layoutInner:function(t,e,n,i){var r=this.getContentGroup(),a=this._containerGroup,o=this._controllerGroup,s=t.getOrient().index,l=cy[s],h=cy[1-s],u=dy[1-s];Vl(t.get("orient"),r,t.get("itemGap"),s?n.width:null,s?null:n.height),Vl("horizontal",o,t.get("pageButtonItemGap",!0));var c=r.getBoundingRect(),d=o.getBoundingRect(),f=this._showController=c[l]>n[l],p=[-c.x,-c.y];i||(p[s]=r.position[s]);var g=[0,0],m=[-d.x,-d.y],v=W(t.get("pageButtonGap",!0),t.get("itemGap",!0));f&&("end"===t.get("pageButtonPosition",!0)?m[s]+=n[l]-d[l]:g[s]+=d[l]+v);m[1-s]+=c[h]/2-d[h]/2,r.attr("position",p),a.attr("position",g),o.attr("position",m);var y=this.group.getBoundingRect();if((y={x:0,y:0})[l]=f?n[l]:c[l],y[h]=Math.max(c[h],d[h]),y[u]=Math.min(0,d[u]+m[1-s]),a.__rectSize=n[l],f){var _={x:0,y:0};_[l]=Math.max(n[l]-d[l]-v,0),_[h]=y[h],a.setClipPath(new No({shape:_})),a.__rectSize=_[l]}else o.eachChild(function(t){t.attr({invisible:!0,silent:!0})});var x=this._getPageInfo(t);return null!=x.pageIndex&&Ns(r,{position:x.contentPosition},f&&t),this._updatePageInfoView(t,x),y},_pageGo:function(t,e,n){var i=this._getPageInfo(e)[t];null!=i&&n.dispatchAction({type:"legendScroll",scrollDataIndex:i,legendId:e.id})},_updatePageInfoView:function(i,r){var a=this._controllerGroup;A(["pagePrev","pageNext"],function(t){var e=null!=r[t+"DataIndex"],n=a.childOfName(t);n&&(n.setStyle("fill",e?i.get("pageIconColor",!0):i.get("pageIconInactiveColor",!0)),n.cursor=e?"pointer":"default")});var t=a.childOfName("pageText"),e=i.get("pageFormatter"),n=r.pageIndex,o=null!=n?n+1:0,s=r.pageCount;t&&e&&t.setStyle("text",E(e)?e.replace("{current}",o).replace("{total}",s):e({current:o,total:s}))},_getPageInfo:function(t){var e=t.get("scrollDataIndex",!0),n=this.getContentGroup(),i=this._containerGroup.__rectSize,r=t.getOrient().index,a=cy[r],o=dy[r],s=this._findTargetItemIndex(e),l=n.children(),h=l[s],u=l.length,c=u?1:0,d={contentPosition:n.position.slice(),pageCount:c,pageIndex:c-1,pagePrevDataIndex:null,pageNextDataIndex:null};if(!h)return d;var f=y(h);d.contentPosition[r]=-f.s;for(var p=s+1,g=f,m=f,v=null;p<=u;++p)(!(v=y(l[p]))&&m.e>g.s+i||v&&!_(v,g.s))&&(g=m.i>g.i?m:v)&&(null==d.pageNextDataIndex&&(d.pageNextDataIndex=g.i),++d.pageCount),m=v;for(p=s-1,g=f,m=f,v=null;-1<=p;--p)(v=y(l[p]))&&_(m,v.s)||!(g.i<m.i)||(m=g,null==d.pagePrevDataIndex&&(d.pagePrevDataIndex=g.i),++d.pageCount,++d.pageIndex),g=v;return d;function y(t){if(t){var e=t.getBoundingRect(),n=e[o]+t.position[r];return{s:n,e:n+e[a],i:t.__legendDataIndex}}}function _(t,e){return t.e>=e&&t.s<=e+i}},_findTargetItemIndex:function(i){var r,a,t=this.getContentGroup();return this._showController&&t.eachChild(function(t,e){var n=t.__legendDataIndex;null==a&&null!=n&&(a=e),n===i&&(r=e)}),null!=r?r:a}});Nd("legendScroll","legendscroll",function(t,e){var n=t.scrollDataIndex;null!=n&&e.eachComponent({mainType:"legend",subType:"scroll",query:t},function(t){t.setScrollDataIndex(n)})}),Hd({type:"title",layoutMode:{type:"box",ignoreSize:!0},defaultOption:{zlevel:0,z:6,show:!0,text:"",target:"blank",subtext:"",subtarget:"blank",left:0,top:0,backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderWidth:0,padding:5,itemGap:10,textStyle:{fontSize:18,fontWeight:"bolder",color:"#333"},subtextStyle:{color:"#aaa"}}}),Wd({type:"title",render:function(t,e,n){if(this.group.removeAll(),t.get("show")){var i=this.group,r=t.getModel("textStyle"),a=t.getModel("subtextStyle"),o=t.get("textAlign"),s=W(t.get("textBaseline"),t.get("textVerticalAlign")),l=new wo({style:As({},r,{text:t.get("text"),textFill:r.getTextColor()},{disableBox:!0}),z2:10}),h=l.getBoundingRect(),u=t.get("subtext"),c=new wo({style:As({},a,{text:u,textFill:a.getTextColor(),y:h.height+t.get("itemGap"),textVerticalAlign:"top"},{disableBox:!0}),z2:10}),d=t.get("link"),f=t.get("sublink"),p=t.get("triggerEvent",!0);l.silent=!d&&!p,c.silent=!f&&!p,d&&l.on("click",function(){window.open(d,"_"+t.get("target"))}),f&&c.on("click",function(){window.open(f,"_"+t.get("subtarget"))}),l.eventData=c.eventData=p?{componentType:"title",componentIndex:t.componentIndex}:null,i.add(l),u&&i.add(c);var g=i.getBoundingRect(),m=t.getBoxLayoutParams();m.width=g.width,m.height=g.height;var v=Hl(m,{width:n.getWidth(),height:n.getHeight()},t.get("padding"));o||("middle"===(o=t.get("left")||t.get("right"))&&(o="center"),"right"===o?v.x+=v.width:"center"===o&&(v.x+=v.width/2)),s||("center"===(s=t.get("top")||t.get("bottom"))&&(s="middle"),"bottom"===s?v.y+=v.height:"middle"===s&&(v.y+=v.height/2),s=s||"top"),i.attr("position",[v.x,v.y]);var y={textAlign:o,textVerticalAlign:s};l.setStyle(y),c.setStyle(y),g=i.getBoundingRect();var _=v.margin,x=t.getItemStyle(["color","opacity"]);x.fill=t.get("backgroundColor");var w=new No({shape:{x:g.x-_[3],y:g.y-_[0],width:g.width+_[1]+_[3],height:g.height+_[0]+_[2],r:t.get("borderRadius")},style:x,subPixelOptimize:!0,silent:!0});i.add(w)}}});var py=wl,gy=Cl;function my(t){mr(t,"label",["show"])}var vy=Hd({type:"marker",dependencies:["series","grid","polar","geo"],init:function(t,e,n,i){this.mergeDefaultAndTheme(t,n),this.mergeOption(t,n,i.createdBySelf,!0)},isAnimationEnabled:function(){if(v.node)return!1;var t=this.__hostSeries;return this.getShallow("animation")&&t&&t.isAnimationEnable