cancan-microstack 0.0.1__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (440) hide show
  1. cancan_microstack/__init__.py +14 -0
  2. cancan_microstack/__version__.py +10 -0
  3. cancan_microstack/assets/__init__.py +6 -0
  4. cancan_microstack/assets/builds/caddy/Caddyfile +187 -0
  5. cancan_microstack/assets/builds/caddy/DEPLOYMENT.md +303 -0
  6. cancan_microstack/assets/builds/caddy/Dockerfile +46 -0
  7. cancan_microstack/assets/builds/caddy/README.md +343 -0
  8. cancan_microstack/assets/builds/caddy/geoip/README.md +5 -0
  9. cancan_microstack/assets/builds/caddy/start.sh +78 -0
  10. cancan_microstack/assets/builds/caddy/waf/coraza.conf +179 -0
  11. cancan_microstack/assets/builds/service/Dockerfile +59 -0
  12. cancan_microstack/assets/builds/service/README.md +13 -0
  13. cancan_microstack/assets/ddl/create_db.sql +22 -0
  14. cancan_microstack/assets/ddl/infra/execution_log_tbl.sql +46 -0
  15. cancan_microstack/assets/ddl/infra/node_instance_tbl.sql +56 -0
  16. cancan_microstack/assets/ddl/infra/service_action_log_tbl.sql +36 -0
  17. cancan_microstack/assets/ddl/infra/service_config_tbl.sql +26 -0
  18. cancan_microstack/assets/ddl/infra/service_info_tbl.sql +45 -0
  19. cancan_microstack/assets/ddl/infra/service_instance_tbl.sql +54 -0
  20. cancan_microstack/assets/ddl/infra/service_operation_tbl.sql +47 -0
  21. cancan_microstack/assets/ddl/infra/workflow_definition_tbl.sql +60 -0
  22. cancan_microstack/assets/ddl/infra/workflow_definition_version_tbl.sql +35 -0
  23. cancan_microstack/assets/ddl/infra/workflow_engine_alert_tbl.sql +34 -0
  24. cancan_microstack/assets/ddl/infra/workflow_run_tbl.sql +52 -0
  25. cancan_microstack/assets/ddl/ops/admin_user_tbl.sql +34 -0
  26. cancan_microstack/assets/ddl/ops/caddy_access_log_tbl.sql +91 -0
  27. cancan_microstack/assets/ddl/ops/caddy_certificate_tbl.sql +59 -0
  28. cancan_microstack/assets/ddl/ops/caddy_rate_limit_tbl.sql +64 -0
  29. cancan_microstack/assets/ddl/ops/caddy_route_tbl.sql +63 -0
  30. cancan_microstack/assets/ddl/ops/caddy_stats_tbl.sql +77 -0
  31. cancan_microstack/assets/ddl/trigger.sql +21 -0
  32. cancan_microstack/assets/docker/docker-compose.infra.yml +401 -0
  33. cancan_microstack/assets/scripts/README.md +195 -0
  34. cancan_microstack/assets/scripts/docker/build_images.sh +44 -0
  35. cancan_microstack/assets/scripts/docker/force_rebuild_images.sh +38 -0
  36. cancan_microstack/assets/scripts/docker/rebuild_all.sh +34 -0
  37. cancan_microstack/assets/scripts/docker/rebuild_compose.sh +61 -0
  38. cancan_microstack/assets/scripts/docker/restart.sh +35 -0
  39. cancan_microstack/assets/scripts/docker/restart_compose.sh +35 -0
  40. cancan_microstack/assets/scripts/docker/start.sh +78 -0
  41. cancan_microstack/assets/scripts/docker/start_all.sh +46 -0
  42. cancan_microstack/assets/scripts/docker/start_compose.sh +66 -0
  43. cancan_microstack/assets/scripts/docker/stop.sh +67 -0
  44. cancan_microstack/assets/scripts/docker/stop_all.sh +38 -0
  45. cancan_microstack/assets/scripts/docker/stop_compose.sh +38 -0
  46. cancan_microstack/assets/scripts/podman/build_images_podman.sh +59 -0
  47. cancan_microstack/assets/scripts/podman/cleanup_podman.sh +25 -0
  48. cancan_microstack/assets/scripts/podman/force_rebuild_images_podman.sh +56 -0
  49. cancan_microstack/assets/scripts/podman/rebuild_all_podman.sh +37 -0
  50. cancan_microstack/assets/scripts/podman/rebuild_compose_podman.sh +60 -0
  51. cancan_microstack/assets/scripts/podman/restart_compose_podman.sh +73 -0
  52. cancan_microstack/assets/scripts/podman/start_all_podman.sh +66 -0
  53. cancan_microstack/assets/scripts/podman/start_compose_podman.sh +80 -0
  54. cancan_microstack/assets/scripts/podman/start_podman.sh +91 -0
  55. cancan_microstack/assets/scripts/podman/stop.sh +73 -0
  56. cancan_microstack/assets/scripts/podman/stop_all_podman.sh +34 -0
  57. cancan_microstack/assets/scripts/podman/stop_compose_podman.sh +58 -0
  58. cancan_microstack/assets/scripts/start_controllersrv.sh +9 -0
  59. cancan_microstack/assets/scripts/utils/check_all_db_tables.sh +104 -0
  60. cancan_microstack/assets/scripts/utils/check_env.sh +177 -0
  61. cancan_microstack/assets/scripts/utils/check_service_management_deployment.sh +225 -0
  62. cancan_microstack/assets/scripts/utils/deploy_service_management.sh +176 -0
  63. cancan_microstack/assets/scripts/utils/force_reload_infrasrv.sh +52 -0
  64. cancan_microstack/assets/scripts/utils/monitor_service_management.sh +187 -0
  65. cancan_microstack/assets/scripts/utils/reset_postgres_volume.sh +68 -0
  66. cancan_microstack/assets/scripts/utils/test_async_operations.sh +141 -0
  67. cancan_microstack/assets/scripts/utils/verify_real_operations.sh +76 -0
  68. cancan_microstack/assets/service/Dockerfile +65 -0
  69. cancan_microstack/assets/www/adminops/assets/AppEmpty.vue_vue_type_script_setup_true_lang-BOKUurnM.js +1 -0
  70. cancan_microstack/assets/www/adminops/assets/ConfigManage-DKV5YOUz.js +1 -0
  71. cancan_microstack/assets/www/adminops/assets/ConfigManage-Y5bhy7wG.css +1 -0
  72. cancan_microstack/assets/www/adminops/assets/ConsoleManage-8ljYvCW2.js +1 -0
  73. cancan_microstack/assets/www/adminops/assets/ConsoleManage-BWpyqbuQ.css +1 -0
  74. cancan_microstack/assets/www/adminops/assets/DashboardNew-B9Nf1OPl.js +1 -0
  75. cancan_microstack/assets/www/adminops/assets/DashboardNew-DYWZKQ1V.css +1 -0
  76. cancan_microstack/assets/www/adminops/assets/LogSearch-CA0Jhe78.js +1 -0
  77. cancan_microstack/assets/www/adminops/assets/LogSearch-CCZfTNPF.css +1 -0
  78. cancan_microstack/assets/www/adminops/assets/LoginView-BId3kP3M.css +1 -0
  79. cancan_microstack/assets/www/adminops/assets/LoginView-BQZTV_Qy.js +1 -0
  80. cancan_microstack/assets/www/adminops/assets/OperationProgressDialog-BdEYwqFq.js +1 -0
  81. cancan_microstack/assets/www/adminops/assets/OperationProgressDialog-D-pASR8G.css +1 -0
  82. cancan_microstack/assets/www/adminops/assets/PageContainer-Byss-yUC.js +1 -0
  83. cancan_microstack/assets/www/adminops/assets/PageContainer-C3nSZwM7.css +1 -0
  84. cancan_microstack/assets/www/adminops/assets/RateLimitManage-BDI8jLpC.css +1 -0
  85. cancan_microstack/assets/www/adminops/assets/RateLimitManage-DJY4NiF-.js +1 -0
  86. cancan_microstack/assets/www/adminops/assets/RouteManage-DaUQ4QLw.css +1 -0
  87. cancan_microstack/assets/www/adminops/assets/RouteManage-w9XCU0UA.js +1 -0
  88. cancan_microstack/assets/www/adminops/assets/ServiceCard-BFzHe6Tw.css +1 -0
  89. cancan_microstack/assets/www/adminops/assets/ServiceCard-BJUhWnA-.js +1 -0
  90. cancan_microstack/assets/www/adminops/assets/ServiceDetail-Cw24WuKp.js +1 -0
  91. cancan_microstack/assets/www/adminops/assets/ServiceDetail-Yum47zdB.css +1 -0
  92. cancan_microstack/assets/www/adminops/assets/ServiceList-C7ryvbhE.js +1 -0
  93. cancan_microstack/assets/www/adminops/assets/ServiceList-Cgd01fUx.css +1 -0
  94. cancan_microstack/assets/www/adminops/assets/ServiceLogs-COpG9H0h.js +1 -0
  95. cancan_microstack/assets/www/adminops/assets/ServiceLogs-H_Alq0cf.css +1 -0
  96. cancan_microstack/assets/www/adminops/assets/StatsOverview-D0TwMQkA.js +39 -0
  97. cancan_microstack/assets/www/adminops/assets/StatsOverview-lqAN6pqM.css +1 -0
  98. cancan_microstack/assets/www/adminops/assets/TotpBindView-CWlAmzFt.js +1 -0
  99. cancan_microstack/assets/www/adminops/assets/TotpBindView-HoQC1lhx.css +1 -0
  100. cancan_microstack/assets/www/adminops/assets/TotpVerifyView-BHN1VtX1.css +1 -0
  101. cancan_microstack/assets/www/adminops/assets/TotpVerifyView-D3w_lZk8.js +1 -0
  102. cancan_microstack/assets/www/adminops/assets/WorkflowCenter-DU_mpIA0.css +1 -0
  103. cancan_microstack/assets/www/adminops/assets/WorkflowCenter-i50rZyxN.js +1 -0
  104. cancan_microstack/assets/www/adminops/assets/WorkflowDesigner-CnHokPL9.js +1 -0
  105. cancan_microstack/assets/www/adminops/assets/WorkflowDesigner-DaZaZpLd.css +1 -0
  106. cancan_microstack/assets/www/adminops/assets/WorkflowRuns-B09hK48c.js +1 -0
  107. cancan_microstack/assets/www/adminops/assets/WorkflowRuns-wGutKIIU.css +1 -0
  108. cancan_microstack/assets/www/adminops/assets/caddy-nnCKf8fG.js +1 -0
  109. cancan_microstack/assets/www/adminops/assets/format-Cuzxgna9.js +1 -0
  110. cancan_microstack/assets/www/adminops/assets/index-CiFlm8oc.js +64 -0
  111. cancan_microstack/assets/www/adminops/assets/index-UW0T1Dkc.css +1 -0
  112. cancan_microstack/assets/www/adminops/assets/service-BYlgGPs_.js +1 -0
  113. cancan_microstack/assets/www/adminops/assets/service-operation-6GzLw2Z1.js +1 -0
  114. cancan_microstack/assets/www/adminops/assets/style-CcIXnQ5y.css +1 -0
  115. cancan_microstack/assets/www/adminops/assets/style-lRnStdGu.js +39 -0
  116. cancan_microstack/assets/www/adminops/assets/useDebounce-BRlqfXqf.js +1 -0
  117. cancan_microstack/assets/www/adminops/assets/workflow-CUXs39Ac.js +1 -0
  118. cancan_microstack/assets/www/adminops/index.html +16 -0
  119. cancan_microstack/assets/www/adminops/vite.svg +1 -0
  120. cancan_microstack/cli/__init__.py +14 -0
  121. cancan_microstack/cli/__main__.py +9 -0
  122. cancan_microstack/cli/main.py +552 -0
  123. cancan_microstack/cmd/__init__.py +54 -0
  124. cancan_microstack/cmd/cancan/__init__.py +12 -0
  125. cancan_microstack/cmd/cancan/run.py +395 -0
  126. cancan_microstack/cmd/controllersrv/__init__.py +0 -0
  127. cancan_microstack/cmd/controllersrv/run.py +131 -0
  128. cancan_microstack/cmd/infrasrv/__init__.py +5 -0
  129. cancan_microstack/cmd/infrasrv/run.py +100 -0
  130. cancan_microstack/cmd/opsbffsrv/__init__.py +5 -0
  131. cancan_microstack/cmd/opsbffsrv/run.py +96 -0
  132. cancan_microstack/core/__init__.py +5 -0
  133. cancan_microstack/core/assets.py +123 -0
  134. cancan_microstack/core/compose_builder.py +102 -0
  135. cancan_microstack/core/doctor.py +152 -0
  136. cancan_microstack/core/microstack.py +71 -0
  137. cancan_microstack/core/runner.py +56 -0
  138. cancan_microstack/core/stack_manager.py +186 -0
  139. cancan_microstack/public/__init__.py +7 -0
  140. cancan_microstack/public/api/__init__.py +1 -0
  141. cancan_microstack/public/api/controllersrv_client.py +277 -0
  142. cancan_microstack/public/api/infrasrv_client.py +404 -0
  143. cancan_microstack/public/const/__init__.py +1 -0
  144. cancan_microstack/public/const/action_consts.py +18 -0
  145. cancan_microstack/public/const/app_consts.py +42 -0
  146. cancan_microstack/public/const/caddy_consts.py +22 -0
  147. cancan_microstack/public/const/controllersrv_consts.py +163 -0
  148. cancan_microstack/public/const/docker_consts.py +15 -0
  149. cancan_microstack/public/const/error.py +56 -0
  150. cancan_microstack/public/const/health_consts.py +52 -0
  151. cancan_microstack/public/const/hook_enums.py +56 -0
  152. cancan_microstack/public/const/logging_enums.py +13 -0
  153. cancan_microstack/public/const/metrics_enums.py +36 -0
  154. cancan_microstack/public/const/monitor_enums.py +26 -0
  155. cancan_microstack/public/const/operation_consts.py +53 -0
  156. cancan_microstack/public/const/opsbffsrv_error.py +92 -0
  157. cancan_microstack/public/const/overrides_consts.py +13 -0
  158. cancan_microstack/public/const/redis.py +17 -0
  159. cancan_microstack/public/const/service_consts.py +15 -0
  160. cancan_microstack/public/const/workflow_consts.py +65 -0
  161. cancan_microstack/public/error.py +41 -0
  162. cancan_microstack/public/logging/__init__.py +0 -0
  163. cancan_microstack/public/logging/initializer.py +109 -0
  164. cancan_microstack/public/logging/mq_handler.py +279 -0
  165. cancan_microstack/public/schemas/__init__.py +1 -0
  166. cancan_microstack/public/schemas/caddy/__init__.py +381 -0
  167. cancan_microstack/public/schemas/caddy/analysis.py +90 -0
  168. cancan_microstack/public/schemas/caddy/route.py +18 -0
  169. cancan_microstack/public/schemas/common.py +79 -0
  170. cancan_microstack/public/schemas/controllersrv/__init__.py +3 -0
  171. cancan_microstack/public/schemas/controllersrv/async_requests.py +30 -0
  172. cancan_microstack/public/schemas/controllersrv/compose_models.py +47 -0
  173. cancan_microstack/public/schemas/controllersrv/const.py +24 -0
  174. cancan_microstack/public/schemas/controllersrv/docker_models.py +45 -0
  175. cancan_microstack/public/schemas/controllersrv/docker_responses.py +104 -0
  176. cancan_microstack/public/schemas/controllersrv/requests.py +54 -0
  177. cancan_microstack/public/schemas/controllersrv/responses.py +124 -0
  178. cancan_microstack/public/schemas/controllersrv/task_models.py +102 -0
  179. cancan_microstack/public/schemas/controllersrv/validation.py +23 -0
  180. cancan_microstack/public/schemas/hook_metrics.py +124 -0
  181. cancan_microstack/public/schemas/hooks.py +39 -0
  182. cancan_microstack/public/schemas/infra/__init__.py +0 -0
  183. cancan_microstack/public/schemas/infra/cleanup.py +25 -0
  184. cancan_microstack/public/schemas/infra/container.py +74 -0
  185. cancan_microstack/public/schemas/infra/enums.py +135 -0
  186. cancan_microstack/public/schemas/infra/health_check.py +42 -0
  187. cancan_microstack/public/schemas/infra/hook_log.py +42 -0
  188. cancan_microstack/public/schemas/infra/operation.py +90 -0
  189. cancan_microstack/public/schemas/infra/overview.py +25 -0
  190. cancan_microstack/public/schemas/infra/push.py +33 -0
  191. cancan_microstack/public/schemas/infra/service_action_log.py +47 -0
  192. cancan_microstack/public/schemas/infra/service_config.py +10 -0
  193. cancan_microstack/public/schemas/infra/service_info.py +69 -0
  194. cancan_microstack/public/schemas/infra/service_instance.py +93 -0
  195. cancan_microstack/public/schemas/infra/service_management.py +152 -0
  196. cancan_microstack/public/schemas/infra/service_operation.py +79 -0
  197. cancan_microstack/public/schemas/infra/service_registry.py +158 -0
  198. cancan_microstack/public/schemas/infra/status_types.py +19 -0
  199. cancan_microstack/public/schemas/infra/workflow.py +566 -0
  200. cancan_microstack/public/schemas/logging/__init__.py +1 -0
  201. cancan_microstack/public/schemas/logging/log_event.py +121 -0
  202. cancan_microstack/public/schemas/opsbffsrv/__init__.py +1 -0
  203. cancan_microstack/public/schemas/opsbffsrv/async_ops.py +17 -0
  204. cancan_microstack/public/schemas/opsbffsrv/db_admin.py +147 -0
  205. cancan_microstack/public/schemas/opsbffsrv/db_init.py +48 -0
  206. cancan_microstack/public/schemas/opsbffsrv/service_config.py +89 -0
  207. cancan_microstack/public/schemas/opsbffsrv/service_logs.py +54 -0
  208. cancan_microstack/public/schemas/service_operation.py +24 -0
  209. cancan_microstack/public/schemas/service_registry.py +40 -0
  210. cancan_microstack/public/types/__init__.py +7 -0
  211. cancan_microstack/public/web/__init__.py +0 -0
  212. cancan_microstack/public/web/config_value.py +105 -0
  213. cancan_microstack/public/web/server.py +385 -0
  214. cancan_microstack/py.typed +0 -0
  215. cancan_microstack/runtime/__init__.py +0 -0
  216. cancan_microstack/runtime/compose_cmd.py +228 -0
  217. cancan_microstack/runtime/host_daemon.py +318 -0
  218. cancan_microstack/runtime/overrides.py +103 -0
  219. cancan_microstack/runtime/resources.py +25 -0
  220. cancan_microstack/runtime/workspace.py +94 -0
  221. cancan_microstack/services/__init__.py +0 -0
  222. cancan_microstack/services/controllersrv/__init__.py +8 -0
  223. cancan_microstack/services/controllersrv/application/__init__.py +0 -0
  224. cancan_microstack/services/controllersrv/application/docker_compose_app.py +427 -0
  225. cancan_microstack/services/controllersrv/conf/__init__.py +0 -0
  226. cancan_microstack/services/controllersrv/conf/config.py +76 -0
  227. cancan_microstack/services/controllersrv/conf/settings.py +54 -0
  228. cancan_microstack/services/controllersrv/domain/__init__.py +0 -0
  229. cancan_microstack/services/controllersrv/domain/docker_compose/__init__.py +0 -0
  230. cancan_microstack/services/controllersrv/domain/docker_compose/docker_compose_domain.py +278 -0
  231. cancan_microstack/services/controllersrv/domain/service_validator.py +327 -0
  232. cancan_microstack/services/controllersrv/domain/task/__init__.py +17 -0
  233. cancan_microstack/services/controllersrv/domain/task/task_queue.py +286 -0
  234. cancan_microstack/services/controllersrv/domain/task/task_worker.py +495 -0
  235. cancan_microstack/services/controllersrv/infrastructure/__init__.py +0 -0
  236. cancan_microstack/services/controllersrv/interface/__init__.py +0 -0
  237. cancan_microstack/services/controllersrv/interface/api/__init__.py +0 -0
  238. cancan_microstack/services/controllersrv/interface/api/docker_control_api.py +470 -0
  239. cancan_microstack/services/controllersrv/router.py +132 -0
  240. cancan_microstack/services/infrasrv/__init__.py +4 -0
  241. cancan_microstack/services/infrasrv/application/__init__.py +0 -0
  242. cancan_microstack/services/infrasrv/application/health_check_app.py +24 -0
  243. cancan_microstack/services/infrasrv/application/logging/__init__.py +1 -0
  244. cancan_microstack/services/infrasrv/application/logging/log_ingestion_service.py +183 -0
  245. cancan_microstack/services/infrasrv/application/service_config.py +22 -0
  246. cancan_microstack/services/infrasrv/application/service_logs_app.py +53 -0
  247. cancan_microstack/services/infrasrv/application/service_management_app.py +689 -0
  248. cancan_microstack/services/infrasrv/application/service_operation_tracker.py +251 -0
  249. cancan_microstack/services/infrasrv/application/service_registry.py +53 -0
  250. cancan_microstack/services/infrasrv/application/workflow/__init__.py +0 -0
  251. cancan_microstack/services/infrasrv/application/workflow/workflow_app.py +991 -0
  252. cancan_microstack/services/infrasrv/application/workflow/workflow_queue.py +302 -0
  253. cancan_microstack/services/infrasrv/application/workflow/workflow_tasks.py +46 -0
  254. cancan_microstack/services/infrasrv/application/workflow/workflow_worker_runtime.py +122 -0
  255. cancan_microstack/services/infrasrv/conf/__init__.py +0 -0
  256. cancan_microstack/services/infrasrv/conf/config.py +98 -0
  257. cancan_microstack/services/infrasrv/domain/__init__.py +0 -0
  258. cancan_microstack/services/infrasrv/domain/health_check/__init__.py +3 -0
  259. cancan_microstack/services/infrasrv/domain/health_check/health_check_domain.py +576 -0
  260. cancan_microstack/services/infrasrv/domain/hooks/__init__.py +19 -0
  261. cancan_microstack/services/infrasrv/domain/hooks/builtin_hooks.py +308 -0
  262. cancan_microstack/services/infrasrv/domain/hooks/hook_registry.py +43 -0
  263. cancan_microstack/services/infrasrv/domain/hooks/hooks_log_utils.py +275 -0
  264. cancan_microstack/services/infrasrv/domain/hooks/init.py +17 -0
  265. cancan_microstack/services/infrasrv/domain/hooks/metrics.py +205 -0
  266. cancan_microstack/services/infrasrv/domain/hooks/pre_registration_hooks.py +490 -0
  267. cancan_microstack/services/infrasrv/domain/registry/__init__.py +0 -0
  268. cancan_microstack/services/infrasrv/domain/registry/service_registry.py +509 -0
  269. cancan_microstack/services/infrasrv/domain/service_config/__init__.py +0 -0
  270. cancan_microstack/services/infrasrv/domain/service_config/service_config.py +50 -0
  271. cancan_microstack/services/infrasrv/domain/service_logs/__init__.py +0 -0
  272. cancan_microstack/services/infrasrv/domain/service_logs/service_logs_domain.py +51 -0
  273. cancan_microstack/services/infrasrv/domain/workflow/__init__.py +4 -0
  274. cancan_microstack/services/infrasrv/domain/workflow/engine.py +159 -0
  275. cancan_microstack/services/infrasrv/domain/workflow/node_handlers.py +509 -0
  276. cancan_microstack/services/infrasrv/domain/workflow/workflow_domain.py +164 -0
  277. cancan_microstack/services/infrasrv/infrastructure/__init__.py +0 -0
  278. cancan_microstack/services/infrasrv/infrastructure/api/__init__.py +0 -0
  279. cancan_microstack/services/infrasrv/infrastructure/api/controllersrv_api.py +165 -0
  280. cancan_microstack/services/infrasrv/infrastructure/cache/__init__.py +0 -0
  281. cancan_microstack/services/infrasrv/infrastructure/cache/service_registry_cache.py +174 -0
  282. cancan_microstack/services/infrasrv/infrastructure/db/__init__.py +0 -0
  283. cancan_microstack/services/infrasrv/infrastructure/db/model/__init__.py +0 -0
  284. cancan_microstack/services/infrasrv/infrastructure/db/model/execution_log_tbl.py +53 -0
  285. cancan_microstack/services/infrasrv/infrastructure/db/model/node_instance_tbl.py +55 -0
  286. cancan_microstack/services/infrasrv/infrastructure/db/model/service_action_log_tbl.py +44 -0
  287. cancan_microstack/services/infrasrv/infrastructure/db/model/service_config_tbl.py +30 -0
  288. cancan_microstack/services/infrasrv/infrastructure/db/model/service_info_tbl.py +59 -0
  289. cancan_microstack/services/infrasrv/infrastructure/db/model/service_instance_tbl.py +88 -0
  290. cancan_microstack/services/infrasrv/infrastructure/db/model/service_operation_tbl.py +73 -0
  291. cancan_microstack/services/infrasrv/infrastructure/db/model/workflow_definition_tbl.py +55 -0
  292. cancan_microstack/services/infrasrv/infrastructure/db/model/workflow_definition_version_tbl.py +43 -0
  293. cancan_microstack/services/infrasrv/infrastructure/db/model/workflow_engine_alert_tbl.py +57 -0
  294. cancan_microstack/services/infrasrv/infrastructure/db/model/workflow_run_tbl.py +56 -0
  295. cancan_microstack/services/infrasrv/infrastructure/db/operate/__init__.py +0 -0
  296. cancan_microstack/services/infrasrv/infrastructure/db/operate/service_action_log_op.py +239 -0
  297. cancan_microstack/services/infrasrv/infrastructure/db/operate/service_config.py +80 -0
  298. cancan_microstack/services/infrasrv/infrastructure/db/operate/service_config_manager.py +198 -0
  299. cancan_microstack/services/infrasrv/infrastructure/db/operate/service_info_op.py +297 -0
  300. cancan_microstack/services/infrasrv/infrastructure/db/operate/service_instance_op.py +688 -0
  301. cancan_microstack/services/infrasrv/infrastructure/db/operate/service_operation_op.py +387 -0
  302. cancan_microstack/services/infrasrv/infrastructure/db/operate/service_registry.py +124 -0
  303. cancan_microstack/services/infrasrv/infrastructure/db/operate/workflow_op.py +804 -0
  304. cancan_microstack/services/infrasrv/infrastructure/ddl_manager.py +31 -0
  305. cancan_microstack/services/infrasrv/infrastructure/mongo/__init__.py +1 -0
  306. cancan_microstack/services/infrasrv/infrastructure/mongo/log_repository.py +129 -0
  307. cancan_microstack/services/infrasrv/interface/__init__.py +0 -0
  308. cancan_microstack/services/infrasrv/interface/api/__init__.py +0 -0
  309. cancan_microstack/services/infrasrv/interface/api/health_check_api.py +29 -0
  310. cancan_microstack/services/infrasrv/interface/api/hooks.py +284 -0
  311. cancan_microstack/services/infrasrv/interface/api/internal.py +49 -0
  312. cancan_microstack/services/infrasrv/interface/api/internal_instance_api.py +265 -0
  313. cancan_microstack/services/infrasrv/interface/api/internal_operation_api.py +206 -0
  314. cancan_microstack/services/infrasrv/interface/api/service_config.py +50 -0
  315. cancan_microstack/services/infrasrv/interface/api/service_logs_api.py +49 -0
  316. cancan_microstack/services/infrasrv/interface/api/service_management_api.py +113 -0
  317. cancan_microstack/services/infrasrv/interface/api/service_registry.py +117 -0
  318. cancan_microstack/services/infrasrv/interface/api/workflow_api.py +303 -0
  319. cancan_microstack/services/infrasrv/interface/schedule/__init__.py +0 -0
  320. cancan_microstack/services/infrasrv/interface/schedule/cleanup.py +13 -0
  321. cancan_microstack/services/infrasrv/interface/schedule/health_check.py +27 -0
  322. cancan_microstack/services/infrasrv/interface/schedule/log_cleanup.py +26 -0
  323. cancan_microstack/services/infrasrv/interface/schedule/operation_tracker.py +25 -0
  324. cancan_microstack/services/infrasrv/interface/schedule/scheduler.py +39 -0
  325. cancan_microstack/services/infrasrv/interface/schedule/workflow_scheduler.py +115 -0
  326. cancan_microstack/services/infrasrv/router.py +341 -0
  327. cancan_microstack/services/opsbffsrv/__init__.py +4 -0
  328. cancan_microstack/services/opsbffsrv/application/__init__.py +0 -0
  329. cancan_microstack/services/opsbffsrv/application/async_operation_app.py +150 -0
  330. cancan_microstack/services/opsbffsrv/application/auth_app.py +285 -0
  331. cancan_microstack/services/opsbffsrv/application/caddy/__init__.py +0 -0
  332. cancan_microstack/services/opsbffsrv/application/caddy/access_log_analysis_app.py +344 -0
  333. cancan_microstack/services/opsbffsrv/application/caddy/access_log_ingestion_service.py +169 -0
  334. cancan_microstack/services/opsbffsrv/application/caddy/certificate_management_app.py +355 -0
  335. cancan_microstack/services/opsbffsrv/application/caddy/rate_limit_management_app.py +496 -0
  336. cancan_microstack/services/opsbffsrv/application/caddy/route_management_app.py +401 -0
  337. cancan_microstack/services/opsbffsrv/application/caddy/stats_aggregation_app.py +364 -0
  338. cancan_microstack/services/opsbffsrv/application/db_admin_app.py +103 -0
  339. cancan_microstack/services/opsbffsrv/application/db_init_app.py +283 -0
  340. cancan_microstack/services/opsbffsrv/application/logging/__init__.py +1 -0
  341. cancan_microstack/services/opsbffsrv/application/logging/log_query_app.py +28 -0
  342. cancan_microstack/services/opsbffsrv/application/service_config.py +158 -0
  343. cancan_microstack/services/opsbffsrv/application/service_logs_app.py +74 -0
  344. cancan_microstack/services/opsbffsrv/application/service_registry.py +36 -0
  345. cancan_microstack/services/opsbffsrv/application/workflow_ops_app.py +730 -0
  346. cancan_microstack/services/opsbffsrv/conf/__init__.py +0 -0
  347. cancan_microstack/services/opsbffsrv/conf/config.py +224 -0
  348. cancan_microstack/services/opsbffsrv/domain/__init__.py +0 -0
  349. cancan_microstack/services/opsbffsrv/domain/auth/__init__.py +0 -0
  350. cancan_microstack/services/opsbffsrv/domain/auth/admin_init.py +38 -0
  351. cancan_microstack/services/opsbffsrv/domain/auth/auth_domain.py +108 -0
  352. cancan_microstack/services/opsbffsrv/domain/caddy/__init__.py +0 -0
  353. cancan_microstack/services/opsbffsrv/domain/caddy/access_log_analysis.py +358 -0
  354. cancan_microstack/services/opsbffsrv/domain/caddy/certificate_management.py +325 -0
  355. cancan_microstack/services/opsbffsrv/domain/caddy/default_routes.py +53 -0
  356. cancan_microstack/services/opsbffsrv/domain/caddy/rate_limit_management.py +308 -0
  357. cancan_microstack/services/opsbffsrv/domain/caddy/route_management.py +279 -0
  358. cancan_microstack/services/opsbffsrv/domain/caddy/stats_aggregation.py +654 -0
  359. cancan_microstack/services/opsbffsrv/domain/db_admin/__init__.py +0 -0
  360. cancan_microstack/services/opsbffsrv/domain/db_admin/db_admin_domain.py +118 -0
  361. cancan_microstack/services/opsbffsrv/domain/db_init/__init__.py +3 -0
  362. cancan_microstack/services/opsbffsrv/domain/db_init/db_init_domain.py +358 -0
  363. cancan_microstack/services/opsbffsrv/domain/logging/__init__.py +1 -0
  364. cancan_microstack/services/opsbffsrv/domain/logging/log_query_domain.py +99 -0
  365. cancan_microstack/services/opsbffsrv/domain/service_config/__init__.py +0 -0
  366. cancan_microstack/services/opsbffsrv/domain/service_config/service_config.py +81 -0
  367. cancan_microstack/services/opsbffsrv/domain/service_registry/__init__.py +0 -0
  368. cancan_microstack/services/opsbffsrv/domain/service_registry/service_registry.py +292 -0
  369. cancan_microstack/services/opsbffsrv/infrastructure/__init__.py +0 -0
  370. cancan_microstack/services/opsbffsrv/infrastructure/api/__init__.py +0 -0
  371. cancan_microstack/services/opsbffsrv/infrastructure/api/infrasrv_api.py +242 -0
  372. cancan_microstack/services/opsbffsrv/infrastructure/auth/__init__.py +0 -0
  373. cancan_microstack/services/opsbffsrv/infrastructure/auth/captcha_service.py +67 -0
  374. cancan_microstack/services/opsbffsrv/infrastructure/auth/password_service.py +12 -0
  375. cancan_microstack/services/opsbffsrv/infrastructure/auth/redis_store.py +131 -0
  376. cancan_microstack/services/opsbffsrv/infrastructure/auth/totp_service.py +59 -0
  377. cancan_microstack/services/opsbffsrv/infrastructure/caddy/__init__.py +0 -0
  378. cancan_microstack/services/opsbffsrv/infrastructure/caddy/access_log_parser.py +307 -0
  379. cancan_microstack/services/opsbffsrv/infrastructure/caddy/admin_api_client.py +678 -0
  380. cancan_microstack/services/opsbffsrv/infrastructure/caddy/ip_geo_locator.py +176 -0
  381. cancan_microstack/services/opsbffsrv/infrastructure/db/__init__.py +0 -0
  382. cancan_microstack/services/opsbffsrv/infrastructure/db/model/__init__.py +0 -0
  383. cancan_microstack/services/opsbffsrv/infrastructure/db/model/admin_user_tbl.py +33 -0
  384. cancan_microstack/services/opsbffsrv/infrastructure/db/model/caddy_access_log_tbl.py +90 -0
  385. cancan_microstack/services/opsbffsrv/infrastructure/db/model/caddy_certificate_tbl.py +65 -0
  386. cancan_microstack/services/opsbffsrv/infrastructure/db/model/caddy_rate_limit_tbl.py +69 -0
  387. cancan_microstack/services/opsbffsrv/infrastructure/db/model/caddy_route_tbl.py +66 -0
  388. cancan_microstack/services/opsbffsrv/infrastructure/db/model/caddy_stats_tbl.py +78 -0
  389. cancan_microstack/services/opsbffsrv/infrastructure/db/model/service_action_log_tbl.py +44 -0
  390. cancan_microstack/services/opsbffsrv/infrastructure/db/model/service_config_tbl.py +30 -0
  391. cancan_microstack/services/opsbffsrv/infrastructure/db/model/service_info_tbl.py +51 -0
  392. cancan_microstack/services/opsbffsrv/infrastructure/db/model/service_instance_tbl.py +68 -0
  393. cancan_microstack/services/opsbffsrv/infrastructure/db/operate/__init__.py +0 -0
  394. cancan_microstack/services/opsbffsrv/infrastructure/db/operate/admin_user_operate.py +59 -0
  395. cancan_microstack/services/opsbffsrv/infrastructure/db/operate/caddy_access_log.py +531 -0
  396. cancan_microstack/services/opsbffsrv/infrastructure/db/operate/caddy_certificate.py +451 -0
  397. cancan_microstack/services/opsbffsrv/infrastructure/db/operate/caddy_rate_limit.py +360 -0
  398. cancan_microstack/services/opsbffsrv/infrastructure/db/operate/caddy_route.py +271 -0
  399. cancan_microstack/services/opsbffsrv/infrastructure/db/operate/caddy_stats.py +343 -0
  400. cancan_microstack/services/opsbffsrv/infrastructure/db/operate/service_action_log_op.py +57 -0
  401. cancan_microstack/services/opsbffsrv/infrastructure/db/operate/service_config.py +86 -0
  402. cancan_microstack/services/opsbffsrv/infrastructure/db/operate/service_info_op.py +79 -0
  403. cancan_microstack/services/opsbffsrv/infrastructure/db/operate/service_instance.py +58 -0
  404. cancan_microstack/services/opsbffsrv/infrastructure/db/operate/service_registry.py +138 -0
  405. cancan_microstack/services/opsbffsrv/infrastructure/ddl_manager.py +31 -0
  406. cancan_microstack/services/opsbffsrv/infrastructure/mongo/__init__.py +1 -0
  407. cancan_microstack/services/opsbffsrv/infrastructure/mongo/log_query_repository.py +87 -0
  408. cancan_microstack/services/opsbffsrv/interface/__init__.py +0 -0
  409. cancan_microstack/services/opsbffsrv/interface/api/__init__.py +0 -0
  410. cancan_microstack/services/opsbffsrv/interface/api/async_operation_api.py +137 -0
  411. cancan_microstack/services/opsbffsrv/interface/api/auth_api.py +113 -0
  412. cancan_microstack/services/opsbffsrv/interface/api/caddy/__init__.py +3 -0
  413. cancan_microstack/services/opsbffsrv/interface/api/caddy/access_log_api.py +174 -0
  414. cancan_microstack/services/opsbffsrv/interface/api/caddy/certificate_api.py +235 -0
  415. cancan_microstack/services/opsbffsrv/interface/api/caddy/rate_limit_api.py +302 -0
  416. cancan_microstack/services/opsbffsrv/interface/api/caddy/route_api.py +250 -0
  417. cancan_microstack/services/opsbffsrv/interface/api/caddy/stats_api.py +243 -0
  418. cancan_microstack/services/opsbffsrv/interface/api/db_admin_api.py +62 -0
  419. cancan_microstack/services/opsbffsrv/interface/api/db_init_api.py +109 -0
  420. cancan_microstack/services/opsbffsrv/interface/api/instance_management_api.py +165 -0
  421. cancan_microstack/services/opsbffsrv/interface/api/log_query_api.py +41 -0
  422. cancan_microstack/services/opsbffsrv/interface/api/mongo_express_proxy_api.py +181 -0
  423. cancan_microstack/services/opsbffsrv/interface/api/pgweb_proxy_api.py +154 -0
  424. cancan_microstack/services/opsbffsrv/interface/api/rabbitmq_mgmt_proxy_api.py +518 -0
  425. cancan_microstack/services/opsbffsrv/interface/api/redis_commander_proxy_api.py +133 -0
  426. cancan_microstack/services/opsbffsrv/interface/api/service_config.py +146 -0
  427. cancan_microstack/services/opsbffsrv/interface/api/service_logs_api.py +81 -0
  428. cancan_microstack/services/opsbffsrv/interface/api/service_registry.py +66 -0
  429. cancan_microstack/services/opsbffsrv/interface/api/workflow_ops_api.py +413 -0
  430. cancan_microstack/services/opsbffsrv/interface/middleware/__init__.py +0 -0
  431. cancan_microstack/services/opsbffsrv/interface/middleware/auth_middleware.py +52 -0
  432. cancan_microstack/services/opsbffsrv/router.py +901 -0
  433. cancan_microstack/utils/__init__.py +1 -0
  434. cancan_microstack/utils/container_env.py +218 -0
  435. cancan_microstack-0.0.1.dist-info/METADATA +155 -0
  436. cancan_microstack-0.0.1.dist-info/RECORD +440 -0
  437. cancan_microstack-0.0.1.dist-info/WHEEL +5 -0
  438. cancan_microstack-0.0.1.dist-info/entry_points.txt +2 -0
  439. cancan_microstack-0.0.1.dist-info/licenses/LICENSE +21 -0
  440. cancan_microstack-0.0.1.dist-info/top_level.txt +1 -0
@@ -0,0 +1,39 @@
1
+ import{K as F0,r as si,E as Br,d as z0,v as H0,x as Ba,o as G0,H as V0,g as Na,b as sr,w as ct,c as Fa,h as W0,i as pt,y as tl,j as oe,e as Y,t as At,z as U0,A as Y0,l as za,F as Z0,B as X0,_ as q0}from"./index-CiFlm8oc.js";import{f as $0,h as K0,i as Q0,j as J0,k as j0,l as t_,m as e_}from"./caddy-nnCKf8fG.js";import{P as r_}from"./PageContainer-Byss-yUC.js";const i_=F0("caddyStats",()=>{const r=si(null),t=si(null),e=si(null),i=si(null),n=si(!1);return{realtimeStats:r,trendData:t,topCountries:e,topIPs:i,loading:n,fetchRealtimeGlobal:async()=>{n.value=!0;try{const c=await $0();return r.value=c,c}catch(c){throw Br.error("获取实时统计失败"),c}finally{n.value=!1}},fetchRealtimeService:async c=>{n.value=!0;try{return await K0(c)}catch(v){throw Br.error("获取服务统计失败"),v}finally{n.value=!1}},fetchGlobalTrend:async c=>{n.value=!0;try{const v=await Q0(c);return t.value=v,v}catch(v){throw Br.error("获取趋势数据失败"),v}finally{n.value=!1}},fetchServiceTrend:async(c,v)=>{n.value=!0;try{return await J0(c,v)}catch(d){throw Br.error("获取服务趋势失败"),d}finally{n.value=!1}},fetchRouteTrend:async(c,v)=>{n.value=!0;try{return await j0(c,v)}catch(d){throw Br.error("获取路由趋势失败"),d}finally{n.value=!1}},fetchTopCountries:async c=>{n.value=!0;try{const v=await t_(c);return e.value=v,v}catch(v){throw Br.error("获取 Top 国家失败"),v}finally{n.value=!1}},fetchTopIPs:async c=>{n.value=!0;try{const v=await e_(c);return i.value=v,v}catch(v){throw Br.error("获取 Top IP 失败"),v}finally{n.value=!1}}}});/*! *****************************************************************************
2
+ Copyright (c) Microsoft Corporation.
3
+
4
+ Permission to use, copy, modify, and/or distribute this software for any
5
+ purpose with or without fee is hereby granted.
6
+
7
+ THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
8
+ REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
9
+ AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
10
+ INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
11
+ LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
12
+ OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
13
+ PERFORMANCE OF THIS SOFTWARE.
14
+ ***************************************************************************** */var Tu=function(r,t){return Tu=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,i){e.__proto__=i}||function(e,i){for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])},Tu(r,t)};function B(r,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");Tu(r,t);function e(){this.constructor=r}r.prototype=t===null?Object.create(t):(e.prototype=t.prototype,new e)}var n_=(function(){function r(){this.firefox=!1,this.ie=!1,this.edge=!1,this.newEdge=!1,this.weChat=!1}return r})(),a_=(function(){function r(){this.browser=new n_,this.node=!1,this.wxa=!1,this.worker=!1,this.svgSupported=!1,this.touchEventsSupported=!1,this.pointerEventsSupported=!1,this.domSupported=!1,this.transformSupported=!1,this.transform3dSupported=!1,this.hasGlobalWindow=typeof window<"u"}return r})(),j=new a_;typeof wx=="object"&&typeof wx.getSystemInfoSync=="function"?(j.wxa=!0,j.touchEventsSupported=!0):typeof document>"u"&&typeof self<"u"?j.worker=!0:!j.hasGlobalWindow||"Deno"in window||typeof navigator<"u"&&typeof navigator.userAgent=="string"&&navigator.userAgent.indexOf("Node.js")>-1?(j.node=!0,j.svgSupported=!0):o_(navigator.userAgent,j);function o_(r,t){var e=t.browser,i=r.match(/Firefox\/([\d.]+)/),n=r.match(/MSIE\s([\d.]+)/)||r.match(/Trident\/.+?rv:(([\d.]+))/),a=r.match(/Edge?\/([\d.]+)/),o=/micromessenger/i.test(r);i&&(e.firefox=!0,e.version=i[1]),n&&(e.ie=!0,e.version=n[1]),a&&(e.edge=!0,e.version=a[1],e.newEdge=+a[1].split(".")[0]>18),o&&(e.weChat=!0),t.svgSupported=typeof SVGRect<"u",t.touchEventsSupported="ontouchstart"in window&&!e.ie&&!e.edge,t.pointerEventsSupported="onpointerdown"in window&&(e.edge||e.ie&&+e.version>=11);var s=t.domSupported=typeof document<"u";if(s){var l=document.documentElement.style;t.transform3dSupported=(e.ie&&"transition"in l||e.edge||"WebKitCSSMatrix"in window&&"m11"in new WebKitCSSMatrix||"MozPerspective"in l)&&!("OTransition"in l),t.transformSupported=t.transform3dSupported||e.ie&&+e.version>=9}}var Hf=12,s_="sans-serif",Mr=Hf+"px "+s_,l_=20,u_=100,f_="007LLmW'55;N0500LLLLLLLLLL00NNNLzWW\\\\WQb\\0FWLg\\bWb\\WQ\\WrWWQ000CL5LLFLL0LL**F*gLLLL5F0LF\\FFF5.5N";function h_(r){var t={};if(typeof JSON>"u")return t;for(var e=0;e<r.length;e++){var i=String.fromCharCode(e+32),n=(r.charCodeAt(e)-l_)/u_;t[i]=n}return t}var v_=h_(f_),ir={createCanvas:function(){return typeof document<"u"&&document.createElement("canvas")},measureText:(function(){var r,t;return function(e,i){if(!r){var n=ir.createCanvas();r=n&&n.getContext("2d")}if(r)return t!==i&&(t=r.font=i||Mr),r.measureText(e);e=e||"",i=i||Mr;var a=/((?:\d+)?\.?\d*)px/.exec(i),o=a&&+a[1]||Hf,s=0;if(i.indexOf("mono")>=0)s=o*e.length;else for(var l=0;l<e.length;l++){var u=v_[e[l]];s+=u==null?o:u*o}return{width:s}}})(),loadImage:function(r,t,e){var i=new Image;return i.onload=t,i.onerror=e,i.src=r,i}},Wp=vn(["Function","RegExp","Date","Error","CanvasGradient","CanvasPattern","Image","Canvas"],function(r,t){return r["[object "+t+"]"]=!0,r},{}),Up=vn(["Int8","Uint8","Uint8Clamped","Int16","Uint16","Int32","Uint32","Float32","Float64"],function(r,t){return r["[object "+t+"Array]"]=!0,r},{}),Aa=Object.prototype.toString,Ds=Array.prototype,c_=Ds.forEach,d_=Ds.filter,Gf=Ds.slice,p_=Ds.map,jh=(function(){}).constructor,Ha=jh?jh.prototype:null,Vf="__proto__",g_=2311;function Yp(){return g_++}function Wf(){for(var r=[],t=0;t<arguments.length;t++)r[t]=arguments[t];typeof console<"u"&&console.error.apply(console,r)}function it(r){if(r==null||typeof r!="object")return r;var t=r,e=Aa.call(r);if(e==="[object Array]"){if(!Xn(r)){t=[];for(var i=0,n=r.length;i<n;i++)t[i]=it(r[i])}}else if(Up[e]){if(!Xn(r)){var a=r.constructor;if(a.from)t=a.from(r);else{t=new a(r.length);for(var i=0,n=r.length;i<n;i++)t[i]=r[i]}}}else if(!Wp[e]&&!Xn(r)&&!oa(r)){t={};for(var o in r)r.hasOwnProperty(o)&&o!==Vf&&(t[o]=it(r[o]))}return t}function st(r,t,e){if(!Z(t)||!Z(r))return e?it(t):r;for(var i in t)if(t.hasOwnProperty(i)&&i!==Vf){var n=r[i],a=t[i];Z(a)&&Z(n)&&!V(a)&&!V(n)&&!oa(a)&&!oa(n)&&!tv(a)&&!tv(n)&&!Xn(a)&&!Xn(n)?st(n,a,e):(e||!(i in r))&&(r[i]=it(t[i]))}return r}function O(r,t){if(Object.assign)Object.assign(r,t);else for(var e in t)t.hasOwnProperty(e)&&e!==Vf&&(r[e]=t[e]);return r}function ht(r,t,e){for(var i=St(t),n=0,a=i.length;n<a;n++){var o=i[n];r[o]==null&&(r[o]=t[o])}return r}function at(r,t){if(r){if(r.indexOf)return r.indexOf(t);for(var e=0,i=r.length;e<i;e++)if(r[e]===t)return e}return-1}function m_(r,t){var e=r.prototype;function i(){}i.prototype=t.prototype,r.prototype=new i;for(var n in e)e.hasOwnProperty(n)&&(r.prototype[n]=e[n]);r.prototype.constructor=r,r.superClass=t}function Ye(r,t,e){if(r="prototype"in r?r.prototype:r,t="prototype"in t?t.prototype:t,Object.getOwnPropertyNames)for(var i=Object.getOwnPropertyNames(t),n=0;n<i.length;n++){var a=i[n];a!=="constructor"&&r[a]==null&&(r[a]=t[a])}else ht(r,t)}function Jt(r){return!r||typeof r=="string"?!1:typeof r.length=="number"}function T(r,t,e){if(r&&t)if(r.forEach&&r.forEach===c_)r.forEach(t,e);else if(r.length===+r.length)for(var i=0,n=r.length;i<n;i++)t.call(e,r[i],i,r);else for(var a in r)r.hasOwnProperty(a)&&t.call(e,r[a],a,r)}function K(r,t,e){if(!r)return[];if(!t)return Uf(r);if(r.map&&r.map===p_)return r.map(t,e);for(var i=[],n=0,a=r.length;n<a;n++)i.push(t.call(e,r[n],n,r));return i}function vn(r,t,e,i){if(r&&t){for(var n=0,a=r.length;n<a;n++)e=t.call(i,e,r[n],n,r);return e}}function Rt(r,t,e){if(!r)return[];if(!t)return Uf(r);if(r.filter&&r.filter===d_)return r.filter(t,e);for(var i=[],n=0,a=r.length;n<a;n++)t.call(e,r[n],n,r)&&i.push(r[n]);return i}function y_(r,t,e){if(r&&t){for(var i=0,n=r.length;i<n;i++)if(t.call(e,r[i],i,r))return r[i]}}function St(r){if(!r)return[];if(Object.keys)return Object.keys(r);var t=[];for(var e in r)r.hasOwnProperty(e)&&t.push(e);return t}function __(r,t){for(var e=[],i=2;i<arguments.length;i++)e[i-2]=arguments[i];return function(){return r.apply(t,e.concat(Gf.call(arguments)))}}var q=Ha&&J(Ha.bind)?Ha.call.bind(Ha.bind):__;function Mt(r){for(var t=[],e=1;e<arguments.length;e++)t[e-1]=arguments[e];return function(){return r.apply(this,t.concat(Gf.call(arguments)))}}function V(r){return Array.isArray?Array.isArray(r):Aa.call(r)==="[object Array]"}function J(r){return typeof r=="function"}function W(r){return typeof r=="string"}function Cu(r){return Aa.call(r)==="[object String]"}function mt(r){return typeof r=="number"}function Z(r){var t=typeof r;return t==="function"||!!r&&t==="object"}function tv(r){return!!Wp[Aa.call(r)]}function jt(r){return!!Up[Aa.call(r)]}function oa(r){return typeof r=="object"&&typeof r.nodeType=="number"&&typeof r.ownerDocument=="object"}function As(r){return r.colorStops!=null}function S_(r){return r.image!=null}function sa(r){return r!==r}function Uo(){for(var r=[],t=0;t<arguments.length;t++)r[t]=arguments[t];for(var e=0,i=r.length;e<i;e++)if(r[e]!=null)return r[e]}function $(r,t){return r??t}function en(r,t,e){return r??t??e}function Uf(r){for(var t=[],e=1;e<arguments.length;e++)t[e-1]=arguments[e];return Gf.apply(r,t)}function Yf(r){if(typeof r=="number")return[r,r,r,r];var t=r.length;return t===2?[r[0],r[1],r[0],r[1]]:t===3?[r[0],r[1],r[2],r[1]]:r}function nr(r,t){if(!r)throw new Error(t)}function ke(r){return r==null?null:typeof r.trim=="function"?r.trim():r.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")}var Zp="__ec_primitive__";function Mu(r){r[Zp]=!0}function Xn(r){return r[Zp]}var w_=(function(){function r(){this.data={}}return r.prototype.delete=function(t){var e=this.has(t);return e&&delete this.data[t],e},r.prototype.has=function(t){return this.data.hasOwnProperty(t)},r.prototype.get=function(t){return this.data[t]},r.prototype.set=function(t,e){return this.data[t]=e,this},r.prototype.keys=function(){return St(this.data)},r.prototype.forEach=function(t){var e=this.data;for(var i in e)e.hasOwnProperty(i)&&t(e[i],i)},r})(),Xp=typeof Map=="function";function x_(){return Xp?new Map:new w_}var b_=(function(){function r(t){var e=V(t);this.data=x_();var i=this;t instanceof r?t.each(n):t&&T(t,n);function n(a,o){e?i.set(a,o):i.set(o,a)}}return r.prototype.hasKey=function(t){return this.data.has(t)},r.prototype.get=function(t){return this.data.get(t)},r.prototype.set=function(t,e){return this.data.set(t,e),e},r.prototype.each=function(t,e){this.data.forEach(function(i,n){t.call(e,i,n)})},r.prototype.keys=function(){var t=this.data.keys();return Xp?Array.from(t):t},r.prototype.removeKey=function(t){this.data.delete(t)},r})();function Q(r){return new b_(r)}function T_(r,t){for(var e=new r.constructor(r.length+t.length),i=0;i<r.length;i++)e[i]=r[i];for(var n=r.length,i=0;i<t.length;i++)e[i+n]=t[i];return e}function Ls(r,t){var e;if(Object.create)e=Object.create(r);else{var i=function(){};i.prototype=r,e=new i}return t&&O(e,t),e}function qp(r){var t=r.style;t.webkitUserSelect="none",t.userSelect="none",t.webkitTapHighlightColor="rgba(0,0,0,0)",t["-webkit-touch-callout"]="none"}function xe(r,t){return r.hasOwnProperty(t)}function Ut(){}var C_=180/Math.PI;function cn(r,t){return r==null&&(r=0),t==null&&(t=0),[r,t]}function M_(r){return[r[0],r[1]]}function ev(r,t,e){return r[0]=t[0]+e[0],r[1]=t[1]+e[1],r}function D_(r,t,e){return r[0]=t[0]-e[0],r[1]=t[1]-e[1],r}function A_(r){return Math.sqrt(L_(r))}function L_(r){return r[0]*r[0]+r[1]*r[1]}function el(r,t,e){return r[0]=t[0]*e,r[1]=t[1]*e,r}function I_(r,t){var e=A_(t);return e===0?(r[0]=0,r[1]=0):(r[0]=t[0]/e,r[1]=t[1]/e),r}function Du(r,t){return Math.sqrt((r[0]-t[0])*(r[0]-t[0])+(r[1]-t[1])*(r[1]-t[1]))}var P_=Du;function R_(r,t){return(r[0]-t[0])*(r[0]-t[0])+(r[1]-t[1])*(r[1]-t[1])}var rn=R_;function ge(r,t,e){var i=t[0],n=t[1];return r[0]=e[0]*i+e[2]*n+e[4],r[1]=e[1]*i+e[3]*n+e[5],r}function qi(r,t,e){return r[0]=Math.min(t[0],e[0]),r[1]=Math.min(t[1],e[1]),r}function $i(r,t,e){return r[0]=Math.max(t[0],e[0]),r[1]=Math.max(t[1],e[1]),r}var Ai=(function(){function r(t,e){this.target=t,this.topTarget=e&&e.topTarget}return r})(),E_=(function(){function r(t){this.handler=t,t.on("mousedown",this._dragStart,this),t.on("mousemove",this._drag,this),t.on("mouseup",this._dragEnd,this)}return r.prototype._dragStart=function(t){for(var e=t.target;e&&!e.draggable;)e=e.parent||e.__hostTarget;e&&(this._draggingTarget=e,e.dragging=!0,this._x=t.offsetX,this._y=t.offsetY,this.handler.dispatchToElement(new Ai(e,t),"dragstart",t.event))},r.prototype._drag=function(t){var e=this._draggingTarget;if(e){var i=t.offsetX,n=t.offsetY,a=i-this._x,o=n-this._y;this._x=i,this._y=n,e.drift(a,o,t),this.handler.dispatchToElement(new Ai(e,t),"drag",t.event);var s=this.handler.findHover(i,n,e).target,l=this._dropTarget;this._dropTarget=s,e!==s&&(l&&s!==l&&this.handler.dispatchToElement(new Ai(l,t),"dragleave",t.event),s&&s!==l&&this.handler.dispatchToElement(new Ai(s,t),"dragenter",t.event))}},r.prototype._dragEnd=function(t){var e=this._draggingTarget;e&&(e.dragging=!1),this.handler.dispatchToElement(new Ai(e,t),"dragend",t.event),this._dropTarget&&this.handler.dispatchToElement(new Ai(this._dropTarget,t),"drop",t.event),this._draggingTarget=null,this._dropTarget=null},r})(),Te=(function(){function r(t){t&&(this._$eventProcessor=t)}return r.prototype.on=function(t,e,i,n){this._$handlers||(this._$handlers={});var a=this._$handlers;if(typeof e=="function"&&(n=i,i=e,e=null),!i||!t)return this;var o=this._$eventProcessor;e!=null&&o&&o.normalizeQuery&&(e=o.normalizeQuery(e)),a[t]||(a[t]=[]);for(var s=0;s<a[t].length;s++)if(a[t][s].h===i)return this;var l={h:i,query:e,ctx:n||this,callAtLast:i.zrEventfulCallAtLast},u=a[t].length-1,f=a[t][u];return f&&f.callAtLast?a[t].splice(u,0,l):a[t].push(l),this},r.prototype.isSilent=function(t){var e=this._$handlers;return!e||!e[t]||!e[t].length},r.prototype.off=function(t,e){var i=this._$handlers;if(!i)return this;if(!t)return this._$handlers={},this;if(e){if(i[t]){for(var n=[],a=0,o=i[t].length;a<o;a++)i[t][a].h!==e&&n.push(i[t][a]);i[t]=n}i[t]&&i[t].length===0&&delete i[t]}else delete i[t];return this},r.prototype.trigger=function(t){for(var e=[],i=1;i<arguments.length;i++)e[i-1]=arguments[i];if(!this._$handlers)return this;var n=this._$handlers[t],a=this._$eventProcessor;if(n)for(var o=e.length,s=n.length,l=0;l<s;l++){var u=n[l];if(!(a&&a.filter&&u.query!=null&&!a.filter(t,u.query)))switch(o){case 0:u.h.call(u.ctx);break;case 1:u.h.call(u.ctx,e[0]);break;case 2:u.h.call(u.ctx,e[0],e[1]);break;default:u.h.apply(u.ctx,e);break}}return a&&a.afterTrigger&&a.afterTrigger(t),this},r.prototype.triggerWithContext=function(t){for(var e=[],i=1;i<arguments.length;i++)e[i-1]=arguments[i];if(!this._$handlers)return this;var n=this._$handlers[t],a=this._$eventProcessor;if(n)for(var o=e.length,s=e[o-1],l=n.length,u=0;u<l;u++){var f=n[u];if(!(a&&a.filter&&f.query!=null&&!a.filter(t,f.query)))switch(o){case 0:f.h.call(s);break;case 1:f.h.call(s,e[0]);break;case 2:f.h.call(s,e[0],e[1]);break;default:f.h.apply(s,e.slice(1,o-1));break}}return a&&a.afterTrigger&&a.afterTrigger(t),this},r})(),k_=Math.log(2);function Au(r,t,e,i,n,a){var o=i+"-"+n,s=r.length;if(a.hasOwnProperty(o))return a[o];if(t===1){var l=Math.round(Math.log((1<<s)-1&~n)/k_);return r[e][l]}for(var u=i|1<<e,f=e+1;i&1<<f;)f++;for(var h=0,c=0,v=0;c<s;c++){var d=1<<c;d&n||(h+=(v%2?-1:1)*r[e][c]*Au(r,t-1,f,u,n|d,a),v++)}return a[o]=h,h}function rv(r,t){var e=[[r[0],r[1],1,0,0,0,-t[0]*r[0],-t[0]*r[1]],[0,0,0,r[0],r[1],1,-t[1]*r[0],-t[1]*r[1]],[r[2],r[3],1,0,0,0,-t[2]*r[2],-t[2]*r[3]],[0,0,0,r[2],r[3],1,-t[3]*r[2],-t[3]*r[3]],[r[4],r[5],1,0,0,0,-t[4]*r[4],-t[4]*r[5]],[0,0,0,r[4],r[5],1,-t[5]*r[4],-t[5]*r[5]],[r[6],r[7],1,0,0,0,-t[6]*r[6],-t[6]*r[7]],[0,0,0,r[6],r[7],1,-t[7]*r[6],-t[7]*r[7]]],i={},n=Au(e,8,0,0,0,i);if(n!==0){for(var a=[],o=0;o<8;o++)for(var s=0;s<8;s++)a[s]==null&&(a[s]=0),a[s]+=((o+s)%2?-1:1)*Au(e,7,o===0?1:0,1<<o,1<<s,i)/n*t[o];return function(l,u,f){var h=u*a[6]+f*a[7]+1;l[0]=(u*a[0]+f*a[1]+a[2])/h,l[1]=(u*a[3]+f*a[4]+a[5])/h}}}var Yo="___zrEVENTSAVED",rl=[];function O_(r,t,e,i,n){return Lu(rl,t,i,n,!0)&&Lu(r,e,rl[0],rl[1])}function B_(r,t){r&&e(r),t&&e(t);function e(i){var n=i[Yo];n&&(n.clearMarkers&&n.clearMarkers(),delete i[Yo])}}function Lu(r,t,e,i,n){if(t.getBoundingClientRect&&j.domSupported&&!$p(t)){var a=t[Yo]||(t[Yo]={}),o=N_(t,a),s=F_(o,a,n);if(s)return s(r,e,i),!0}return!1}function N_(r,t){var e=t.markers;if(e)return e;e=t.markers=[];for(var i=["left","right"],n=["top","bottom"],a=0;a<4;a++){var o=document.createElement("div"),s=o.style,l=a%2,u=(a>>1)%2;s.cssText=["position: absolute","visibility: hidden","padding: 0","margin: 0","border-width: 0","user-select: none","width:0","height:0",i[l]+":0",n[u]+":0",i[1-l]+":auto",n[1-u]+":auto",""].join("!important;"),r.appendChild(o),e.push(o)}return t.clearMarkers=function(){T(e,function(f){f.parentNode&&f.parentNode.removeChild(f)})},e}function F_(r,t,e){for(var i=e?"invTrans":"trans",n=t[i],a=t.srcCoords,o=[],s=[],l=!0,u=0;u<4;u++){var f=r[u].getBoundingClientRect(),h=2*u,c=f.left,v=f.top;o.push(c,v),l=l&&a&&c===a[h]&&v===a[h+1],s.push(r[u].offsetLeft,r[u].offsetTop)}return l&&n?n:(t.srcCoords=o,t[i]=e?rv(s,o):rv(o,s))}function $p(r){return r.nodeName.toUpperCase()==="CANVAS"}var z_=/([&<>"'])/g,H_={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"};function qt(r){return r==null?"":(r+"").replace(z_,function(t,e){return H_[e]})}var G_=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,il=[],V_=j.browser.firefox&&+j.browser.version.split(".")[0]<39;function Iu(r,t,e,i){return e=e||{},i?iv(r,t,e):V_&&t.layerX!=null&&t.layerX!==t.offsetX?(e.zrX=t.layerX,e.zrY=t.layerY):t.offsetX!=null?(e.zrX=t.offsetX,e.zrY=t.offsetY):iv(r,t,e),e}function iv(r,t,e){if(j.domSupported&&r.getBoundingClientRect){var i=t.clientX,n=t.clientY;if($p(r)){var a=r.getBoundingClientRect();e.zrX=i-a.left,e.zrY=n-a.top;return}else if(Lu(il,r,i,n)){e.zrX=il[0],e.zrY=il[1];return}}e.zrX=e.zrY=0}function Zf(r){return r||window.event}function ue(r,t,e){if(t=Zf(t),t.zrX!=null)return t;var i=t.type,n=i&&i.indexOf("touch")>=0;if(n){var o=i!=="touchend"?t.targetTouches[0]:t.changedTouches[0];o&&Iu(r,o,t,e)}else{Iu(r,t,t,e);var a=W_(t);t.zrDelta=a?a/120:-(t.detail||0)/3}var s=t.button;return t.which==null&&s!==void 0&&G_.test(t.type)&&(t.which=s&1?1:s&2?3:s&4?2:0),t}function W_(r){var t=r.wheelDelta;if(t)return t;var e=r.deltaX,i=r.deltaY;if(e==null||i==null)return t;var n=Math.abs(i!==0?i:e),a=i>0?-1:i<0?1:e>0?-1:1;return 3*n*a}function U_(r,t,e,i){r.addEventListener(t,e,i)}function Y_(r,t,e,i){r.removeEventListener(t,e,i)}var on=function(r){r.preventDefault(),r.stopPropagation(),r.cancelBubble=!0};function nv(r){return r.which===2||r.which===3}var Z_=(function(){function r(){this._track=[]}return r.prototype.recognize=function(t,e,i){return this._doTrack(t,e,i),this._recognize(t)},r.prototype.clear=function(){return this._track.length=0,this},r.prototype._doTrack=function(t,e,i){var n=t.touches;if(n){for(var a={points:[],touches:[],target:e,event:t},o=0,s=n.length;o<s;o++){var l=n[o],u=Iu(i,l,{});a.points.push([u.zrX,u.zrY]),a.touches.push(l)}this._track.push(a)}},r.prototype._recognize=function(t){for(var e in nl)if(nl.hasOwnProperty(e)){var i=nl[e](this._track,t);if(i)return i}},r})();function av(r){var t=r[1][0]-r[0][0],e=r[1][1]-r[0][1];return Math.sqrt(t*t+e*e)}function X_(r){return[(r[0][0]+r[1][0])/2,(r[0][1]+r[1][1])/2]}var nl={pinch:function(r,t){var e=r.length;if(e){var i=(r[e-1]||{}).points,n=(r[e-2]||{}).points||i;if(n&&n.length>1&&i&&i.length>1){var a=av(i)/av(n);!isFinite(a)&&(a=1),t.pinchScale=a;var o=X_(i);return t.pinchX=o[0],t.pinchY=o[1],{type:"pinch",target:r[0].target,event:t}}}}};function rr(){return[1,0,0,1,0,0]}function Xf(r){return r[0]=1,r[1]=0,r[2]=0,r[3]=1,r[4]=0,r[5]=0,r}function Kp(r,t){return r[0]=t[0],r[1]=t[1],r[2]=t[2],r[3]=t[3],r[4]=t[4],r[5]=t[5],r}function qn(r,t,e){var i=t[0]*e[0]+t[2]*e[1],n=t[1]*e[0]+t[3]*e[1],a=t[0]*e[2]+t[2]*e[3],o=t[1]*e[2]+t[3]*e[3],s=t[0]*e[4]+t[2]*e[5]+t[4],l=t[1]*e[4]+t[3]*e[5]+t[5];return r[0]=i,r[1]=n,r[2]=a,r[3]=o,r[4]=s,r[5]=l,r}function Pu(r,t,e){return r[0]=t[0],r[1]=t[1],r[2]=t[2],r[3]=t[3],r[4]=t[4]+e[0],r[5]=t[5]+e[1],r}function qf(r,t,e,i){i===void 0&&(i=[0,0]);var n=t[0],a=t[2],o=t[4],s=t[1],l=t[3],u=t[5],f=Math.sin(e),h=Math.cos(e);return r[0]=n*h+s*f,r[1]=-n*f+s*h,r[2]=a*h+l*f,r[3]=-a*f+h*l,r[4]=h*(o-i[0])+f*(u-i[1])+i[0],r[5]=h*(u-i[1])-f*(o-i[0])+i[1],r}function q_(r,t,e){var i=e[0],n=e[1];return r[0]=t[0]*i,r[1]=t[1]*n,r[2]=t[2]*i,r[3]=t[3]*n,r[4]=t[4]*i,r[5]=t[5]*n,r}function La(r,t){var e=t[0],i=t[2],n=t[4],a=t[1],o=t[3],s=t[5],l=e*o-a*i;return l?(l=1/l,r[0]=o*l,r[1]=-a*l,r[2]=-i*l,r[3]=e*l,r[4]=(i*s-o*n)*l,r[5]=(a*n-e*s)*l,r):null}var vt=(function(){function r(t,e){this.x=t||0,this.y=e||0}return r.prototype.copy=function(t){return this.x=t.x,this.y=t.y,this},r.prototype.clone=function(){return new r(this.x,this.y)},r.prototype.set=function(t,e){return this.x=t,this.y=e,this},r.prototype.equal=function(t){return t.x===this.x&&t.y===this.y},r.prototype.add=function(t){return this.x+=t.x,this.y+=t.y,this},r.prototype.scale=function(t){this.x*=t,this.y*=t},r.prototype.scaleAndAdd=function(t,e){this.x+=t.x*e,this.y+=t.y*e},r.prototype.sub=function(t){return this.x-=t.x,this.y-=t.y,this},r.prototype.dot=function(t){return this.x*t.x+this.y*t.y},r.prototype.len=function(){return Math.sqrt(this.x*this.x+this.y*this.y)},r.prototype.lenSquare=function(){return this.x*this.x+this.y*this.y},r.prototype.normalize=function(){var t=this.len();return this.x/=t,this.y/=t,this},r.prototype.distance=function(t){var e=this.x-t.x,i=this.y-t.y;return Math.sqrt(e*e+i*i)},r.prototype.distanceSquare=function(t){var e=this.x-t.x,i=this.y-t.y;return e*e+i*i},r.prototype.negate=function(){return this.x=-this.x,this.y=-this.y,this},r.prototype.transform=function(t){if(t){var e=this.x,i=this.y;return this.x=t[0]*e+t[2]*i+t[4],this.y=t[1]*e+t[3]*i+t[5],this}},r.prototype.toArray=function(t){return t[0]=this.x,t[1]=this.y,t},r.prototype.fromArray=function(t){this.x=t[0],this.y=t[1]},r.set=function(t,e,i){t.x=e,t.y=i},r.copy=function(t,e){t.x=e.x,t.y=e.y},r.len=function(t){return Math.sqrt(t.x*t.x+t.y*t.y)},r.lenSquare=function(t){return t.x*t.x+t.y*t.y},r.dot=function(t,e){return t.x*e.x+t.y*e.y},r.add=function(t,e,i){t.x=e.x+i.x,t.y=e.y+i.y},r.sub=function(t,e,i){t.x=e.x-i.x,t.y=e.y-i.y},r.scale=function(t,e,i){t.x=e.x*i,t.y=e.y*i},r.scaleAndAdd=function(t,e,i,n){t.x=e.x+i.x*n,t.y=e.y+i.y*n},r.lerp=function(t,e,i,n){var a=1-n;t.x=a*e.x+n*i.x,t.y=a*e.y+n*i.y},r})(),fi=Math.min,Ki=Math.max,Ru=Math.abs,ov=["x","y"],$_=["width","height"],Nr=new vt,Fr=new vt,zr=new vt,Hr=new vt,re=Qp(),zn=re.minTv,Eu=re.maxTv,$n=[0,0],rt=(function(){function r(t,e,i,n){r.set(this,t,e,i,n)}return r.set=function(t,e,i,n,a){return n<0&&(e=e+n,n=-n),a<0&&(i=i+a,a=-a),t.x=e,t.y=i,t.width=n,t.height=a,t},r.prototype.union=function(t){var e=fi(t.x,this.x),i=fi(t.y,this.y);isFinite(this.x)&&isFinite(this.width)?this.width=Ki(t.x+t.width,this.x+this.width)-e:this.width=t.width,isFinite(this.y)&&isFinite(this.height)?this.height=Ki(t.y+t.height,this.y+this.height)-i:this.height=t.height,this.x=e,this.y=i},r.prototype.applyTransform=function(t){r.applyTransform(this,this,t)},r.prototype.calculateTransform=function(t){var e=this,i=t.width/e.width,n=t.height/e.height,a=rr();return Pu(a,a,[-e.x,-e.y]),q_(a,a,[i,n]),Pu(a,a,[t.x,t.y]),a},r.prototype.intersect=function(t,e,i){return r.intersect(this,t,e,i)},r.intersect=function(t,e,i,n){i&&vt.set(i,0,0);var a=n&&n.outIntersectRect||null,o=n&&n.clamp;if(a&&(a.x=a.y=a.width=a.height=NaN),!t||!e)return!1;t instanceof r||(t=r.set(K_,t.x,t.y,t.width,t.height)),e instanceof r||(e=r.set(Q_,e.x,e.y,e.width,e.height));var s=!!i;re.reset(n,s);var l=re.touchThreshold,u=t.x+l,f=t.x+t.width-l,h=t.y+l,c=t.y+t.height-l,v=e.x+l,d=e.x+e.width-l,g=e.y+l,m=e.y+e.height-l;if(u>f||h>c||v>d||g>m)return!1;var p=!(f<v||d<u||c<g||m<h);return(s||a)&&($n[0]=1/0,$n[1]=0,sv(u,f,v,d,0,s,a,o),sv(h,c,g,m,1,s,a,o),s&&vt.copy(i,p?re.useDir?re.dirMinTv:zn:Eu)),p},r.contain=function(t,e,i){return e>=t.x&&e<=t.x+t.width&&i>=t.y&&i<=t.y+t.height},r.prototype.contain=function(t,e){return r.contain(this,t,e)},r.prototype.clone=function(){return new r(this.x,this.y,this.width,this.height)},r.prototype.copy=function(t){r.copy(this,t)},r.prototype.plain=function(){return{x:this.x,y:this.y,width:this.width,height:this.height}},r.prototype.isFinite=function(){return isFinite(this.x)&&isFinite(this.y)&&isFinite(this.width)&&isFinite(this.height)},r.prototype.isZero=function(){return this.width===0||this.height===0},r.create=function(t){return new r(t.x,t.y,t.width,t.height)},r.copy=function(t,e){return t.x=e.x,t.y=e.y,t.width=e.width,t.height=e.height,t},r.applyTransform=function(t,e,i){if(!i){t!==e&&r.copy(t,e);return}if(i[1]<1e-5&&i[1]>-1e-5&&i[2]<1e-5&&i[2]>-1e-5){var n=i[0],a=i[3],o=i[4],s=i[5];t.x=e.x*n+o,t.y=e.y*a+s,t.width=e.width*n,t.height=e.height*a,t.width<0&&(t.x+=t.width,t.width=-t.width),t.height<0&&(t.y+=t.height,t.height=-t.height);return}Nr.x=zr.x=e.x,Nr.y=Hr.y=e.y,Fr.x=Hr.x=e.x+e.width,Fr.y=zr.y=e.y+e.height,Nr.transform(i),Hr.transform(i),Fr.transform(i),zr.transform(i),t.x=fi(Nr.x,Fr.x,zr.x,Hr.x),t.y=fi(Nr.y,Fr.y,zr.y,Hr.y);var l=Ki(Nr.x,Fr.x,zr.x,Hr.x),u=Ki(Nr.y,Fr.y,zr.y,Hr.y);t.width=l-t.x,t.height=u-t.y},r})(),K_=new rt(0,0,0,0),Q_=new rt(0,0,0,0);function sv(r,t,e,i,n,a,o,s){var l=Ru(t-e),u=Ru(i-r),f=fi(l,u),h=ov[n],c=ov[1-n],v=$_[n];t<e||i<r?l<u?(a&&(Eu[h]=-l),s&&(o[h]=t,o[v]=0)):(a&&(Eu[h]=u),s&&(o[h]=r,o[v]=0)):(o&&(o[h]=Ki(r,e),o[v]=fi(t,i)-o[h]),a&&(f<$n[0]||re.useDir)&&($n[0]=fi(f,$n[0]),(l<u||!re.bidirectional)&&(zn[h]=l,zn[c]=0,re.useDir&&re.calcDirMTV()),(l>=u||!re.bidirectional)&&(zn[h]=-u,zn[c]=0,re.useDir&&re.calcDirMTV())))}function Qp(){var r=0,t=new vt,e=new vt,i={minTv:new vt,maxTv:new vt,useDir:!1,dirMinTv:new vt,touchThreshold:0,bidirectional:!0,negativeSize:!1,reset:function(a,o){i.touchThreshold=0,a&&a.touchThreshold!=null&&(i.touchThreshold=Ki(0,a.touchThreshold)),i.negativeSize=!1,o&&(i.minTv.set(1/0,1/0),i.maxTv.set(0,0),i.useDir=!1,a&&a.direction!=null&&(i.useDir=!0,i.dirMinTv.copy(i.minTv),e.copy(i.minTv),r=a.direction,i.bidirectional=a.bidirectional==null||!!a.bidirectional,i.bidirectional||t.set(Math.cos(r),Math.sin(r))))},calcDirMTV:function(){var a=i.minTv,o=i.dirMinTv,s=a.y*a.y+a.x*a.x,l=Math.sin(r),u=Math.cos(r),f=l*a.y+u*a.x;if(n(f)){n(a.x)&&n(a.y)&&o.set(0,0);return}if(e.x=s*u/f,e.y=s*l/f,n(e.x)&&n(e.y)){o.set(0,0);return}(i.bidirectional||t.dot(e)>0)&&e.len()<o.len()&&o.copy(e)}};function n(a){return Ru(a)<1e-10}return i}var Jp="silent";function J_(r,t,e){return{type:r,event:e,target:t.target,topTarget:t.topTarget,cancelBubble:!1,offsetX:e.zrX,offsetY:e.zrY,gestureEvent:e.gestureEvent,pinchX:e.pinchX,pinchY:e.pinchY,pinchScale:e.pinchScale,wheelDelta:e.zrDelta,zrByTouch:e.zrByTouch,which:e.which,stop:j_}}function j_(){on(this.event)}var t1=(function(r){B(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.handler=null,e}return t.prototype.dispose=function(){},t.prototype.setCursor=function(){},t})(Te),gn=(function(){function r(t,e){this.x=t,this.y=e}return r})(),e1=["click","dblclick","mousewheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],al=new rt(0,0,0,0),jp=(function(r){B(t,r);function t(e,i,n,a,o){var s=r.call(this)||this;return s._hovered=new gn(0,0),s.storage=e,s.painter=i,s.painterRoot=a,s._pointerSize=o,n=n||new t1,s.proxy=null,s.setHandlerProxy(n),s._draggingMgr=new E_(s),s}return t.prototype.setHandlerProxy=function(e){this.proxy&&this.proxy.dispose(),e&&(T(e1,function(i){e.on&&e.on(i,this[i],this)},this),e.handler=this),this.proxy=e},t.prototype.mousemove=function(e){var i=e.zrX,n=e.zrY,a=tg(this,i,n),o=this._hovered,s=o.target;s&&!s.__zr&&(o=this.findHover(o.x,o.y),s=o.target);var l=this._hovered=a?new gn(i,n):this.findHover(i,n),u=l.target,f=this.proxy;f.setCursor&&f.setCursor(u?u.cursor:"default"),s&&u!==s&&this.dispatchToElement(o,"mouseout",e),this.dispatchToElement(l,"mousemove",e),u&&u!==s&&this.dispatchToElement(l,"mouseover",e)},t.prototype.mouseout=function(e){var i=e.zrEventControl;i!=="only_globalout"&&this.dispatchToElement(this._hovered,"mouseout",e),i!=="no_globalout"&&this.trigger("globalout",{type:"globalout",event:e})},t.prototype.resize=function(){this._hovered=new gn(0,0)},t.prototype.dispatch=function(e,i){var n=this[e];n&&n.call(this,i)},t.prototype.dispose=function(){this.proxy.dispose(),this.storage=null,this.proxy=null,this.painter=null},t.prototype.setCursorStyle=function(e){var i=this.proxy;i.setCursor&&i.setCursor(e)},t.prototype.dispatchToElement=function(e,i,n){e=e||{};var a=e.target;if(!(a&&a.silent)){for(var o="on"+i,s=J_(i,e,n);a&&(a[o]&&(s.cancelBubble=!!a[o].call(a,s)),a.trigger(i,s),a=a.__hostTarget?a.__hostTarget:a.parent,!s.cancelBubble););s.cancelBubble||(this.trigger(i,s),this.painter&&this.painter.eachOtherLayer&&this.painter.eachOtherLayer(function(l){typeof l[o]=="function"&&l[o].call(l,s),l.trigger&&l.trigger(i,s)}))}},t.prototype.findHover=function(e,i,n){var a=this.storage.getDisplayList(),o=new gn(e,i);if(lv(a,o,e,i,n),this._pointerSize&&!o.target){for(var s=[],l=this._pointerSize,u=l/2,f=new rt(e-u,i-u,l,l),h=a.length-1;h>=0;h--){var c=a[h];c!==n&&!c.ignore&&!c.ignoreCoarsePointer&&(!c.parent||!c.parent.ignoreCoarsePointer)&&(al.copy(c.getBoundingRect()),c.transform&&al.applyTransform(c.transform),al.intersect(f)&&s.push(c))}if(s.length)for(var v=4,d=Math.PI/12,g=Math.PI*2,m=0;m<u;m+=v)for(var p=0;p<g;p+=d){var y=e+m*Math.cos(p),_=i+m*Math.sin(p);if(lv(s,o,y,_,n),o.target)return o}}return o},t.prototype.processGesture=function(e,i){this._gestureMgr||(this._gestureMgr=new Z_);var n=this._gestureMgr;i==="start"&&n.clear();var a=n.recognize(e,this.findHover(e.zrX,e.zrY,null).target,this.proxy.dom);if(i==="end"&&n.clear(),a){var o=a.type;e.gestureEvent=o;var s=new gn;s.target=a.target,this.dispatchToElement(s,o,a.event)}},t})(Te);T(["click","mousedown","mouseup","mousewheel","dblclick","contextmenu"],function(r){jp.prototype[r]=function(t){var e=t.zrX,i=t.zrY,n=tg(this,e,i),a,o;if((r!=="mouseup"||!n)&&(a=this.findHover(e,i),o=a.target),r==="mousedown")this._downEl=o,this._downPoint=[t.zrX,t.zrY],this._upEl=o;else if(r==="mouseup")this._upEl=o;else if(r==="click"){if(this._downEl!==this._upEl||!this._downPoint||P_(this._downPoint,[t.zrX,t.zrY])>4)return;this._downPoint=null}this.dispatchToElement(a,r,t)}});function r1(r,t,e){if(r[r.rectHover?"rectContain":"contain"](t,e)){for(var i=r,n=void 0,a=!1;i;){if(i.ignoreClip&&(a=!0),!a){var o=i.getClipPath();if(o&&!o.contain(t,e))return!1}i.silent&&(n=!0);var s=i.__hostTarget;i=s?i.ignoreHostSilent?null:s:i.parent}return n?Jp:!0}return!1}function lv(r,t,e,i,n){for(var a=r.length-1;a>=0;a--){var o=r[a],s=void 0;if(o!==n&&!o.ignore&&(s=r1(o,e,i))&&(!t.topTarget&&(t.topTarget=o),s!==Jp)){t.target=o;break}}}function tg(r,t,e){var i=r.painter;return t<0||t>i.getWidth()||e<0||e>i.getHeight()}var eg=32,mn=7;function i1(r){for(var t=0;r>=eg;)t|=r&1,r>>=1;return r+t}function uv(r,t,e,i){var n=t+1;if(n===e)return 1;if(i(r[n++],r[t])<0){for(;n<e&&i(r[n],r[n-1])<0;)n++;n1(r,t,n)}else for(;n<e&&i(r[n],r[n-1])>=0;)n++;return n-t}function n1(r,t,e){for(e--;t<e;){var i=r[t];r[t++]=r[e],r[e--]=i}}function fv(r,t,e,i,n){for(i===t&&i++;i<e;i++){for(var a=r[i],o=t,s=i,l;o<s;)l=o+s>>>1,n(a,r[l])<0?s=l:o=l+1;var u=i-o;switch(u){case 3:r[o+3]=r[o+2];case 2:r[o+2]=r[o+1];case 1:r[o+1]=r[o];break;default:for(;u>0;)r[o+u]=r[o+u-1],u--}r[o]=a}}function ol(r,t,e,i,n,a){var o=0,s=0,l=1;if(a(r,t[e+n])>0){for(s=i-n;l<s&&a(r,t[e+n+l])>0;)o=l,l=(l<<1)+1,l<=0&&(l=s);l>s&&(l=s),o+=n,l+=n}else{for(s=n+1;l<s&&a(r,t[e+n-l])<=0;)o=l,l=(l<<1)+1,l<=0&&(l=s);l>s&&(l=s);var u=o;o=n-l,l=n-u}for(o++;o<l;){var f=o+(l-o>>>1);a(r,t[e+f])>0?o=f+1:l=f}return l}function sl(r,t,e,i,n,a){var o=0,s=0,l=1;if(a(r,t[e+n])<0){for(s=n+1;l<s&&a(r,t[e+n-l])<0;)o=l,l=(l<<1)+1,l<=0&&(l=s);l>s&&(l=s);var u=o;o=n-l,l=n-u}else{for(s=i-n;l<s&&a(r,t[e+n+l])>=0;)o=l,l=(l<<1)+1,l<=0&&(l=s);l>s&&(l=s),o+=n,l+=n}for(o++;o<l;){var f=o+(l-o>>>1);a(r,t[e+f])<0?l=f:o=f+1}return l}function a1(r,t){var e=mn,i,n,a=0,o=[];i=[],n=[];function s(v,d){i[a]=v,n[a]=d,a+=1}function l(){for(;a>1;){var v=a-2;if(v>=1&&n[v-1]<=n[v]+n[v+1]||v>=2&&n[v-2]<=n[v]+n[v-1])n[v-1]<n[v+1]&&v--;else if(n[v]>n[v+1])break;f(v)}}function u(){for(;a>1;){var v=a-2;v>0&&n[v-1]<n[v+1]&&v--,f(v)}}function f(v){var d=i[v],g=n[v],m=i[v+1],p=n[v+1];n[v]=g+p,v===a-3&&(i[v+1]=i[v+2],n[v+1]=n[v+2]),a--;var y=sl(r[m],r,d,g,0,t);d+=y,g-=y,g!==0&&(p=ol(r[d+g-1],r,m,p,p-1,t),p!==0&&(g<=p?h(d,g,m,p):c(d,g,m,p)))}function h(v,d,g,m){var p=0;for(p=0;p<d;p++)o[p]=r[v+p];var y=0,_=g,S=v;if(r[S++]=r[_++],--m===0){for(p=0;p<d;p++)r[S+p]=o[y+p];return}if(d===1){for(p=0;p<m;p++)r[S+p]=r[_+p];r[S+m]=o[y];return}for(var x=e,w,b,D;;){w=0,b=0,D=!1;do if(t(r[_],o[y])<0){if(r[S++]=r[_++],b++,w=0,--m===0){D=!0;break}}else if(r[S++]=o[y++],w++,b=0,--d===1){D=!0;break}while((w|b)<x);if(D)break;do{if(w=sl(r[_],o,y,d,0,t),w!==0){for(p=0;p<w;p++)r[S+p]=o[y+p];if(S+=w,y+=w,d-=w,d<=1){D=!0;break}}if(r[S++]=r[_++],--m===0){D=!0;break}if(b=ol(o[y],r,_,m,0,t),b!==0){for(p=0;p<b;p++)r[S+p]=r[_+p];if(S+=b,_+=b,m-=b,m===0){D=!0;break}}if(r[S++]=o[y++],--d===1){D=!0;break}x--}while(w>=mn||b>=mn);if(D)break;x<0&&(x=0),x+=2}if(e=x,e<1&&(e=1),d===1){for(p=0;p<m;p++)r[S+p]=r[_+p];r[S+m]=o[y]}else{if(d===0)throw new Error;for(p=0;p<d;p++)r[S+p]=o[y+p]}}function c(v,d,g,m){var p=0;for(p=0;p<m;p++)o[p]=r[g+p];var y=v+d-1,_=m-1,S=g+m-1,x=0,w=0;if(r[S--]=r[y--],--d===0){for(x=S-(m-1),p=0;p<m;p++)r[x+p]=o[p];return}if(m===1){for(S-=d,y-=d,w=S+1,x=y+1,p=d-1;p>=0;p--)r[w+p]=r[x+p];r[S]=o[_];return}for(var b=e;;){var D=0,C=0,M=!1;do if(t(o[_],r[y])<0){if(r[S--]=r[y--],D++,C=0,--d===0){M=!0;break}}else if(r[S--]=o[_--],C++,D=0,--m===1){M=!0;break}while((D|C)<b);if(M)break;do{if(D=d-sl(o[_],r,v,d,d-1,t),D!==0){for(S-=D,y-=D,d-=D,w=S+1,x=y+1,p=D-1;p>=0;p--)r[w+p]=r[x+p];if(d===0){M=!0;break}}if(r[S--]=o[_--],--m===1){M=!0;break}if(C=m-ol(r[y],o,0,m,m-1,t),C!==0){for(S-=C,_-=C,m-=C,w=S+1,x=_+1,p=0;p<C;p++)r[w+p]=o[x+p];if(m<=1){M=!0;break}}if(r[S--]=r[y--],--d===0){M=!0;break}b--}while(D>=mn||C>=mn);if(M)break;b<0&&(b=0),b+=2}if(e=b,e<1&&(e=1),m===1){for(S-=d,y-=d,w=S+1,x=y+1,p=d-1;p>=0;p--)r[w+p]=r[x+p];r[S]=o[_]}else{if(m===0)throw new Error;for(x=S-(m-1),p=0;p<m;p++)r[x+p]=o[p]}}return{mergeRuns:l,forceMergeRuns:u,pushRun:s}}function Lo(r,t,e,i){e||(e=0),i||(i=r.length);var n=i-e;if(!(n<2)){var a=0;if(n<eg){a=uv(r,e,i,t),fv(r,e,i,e+a,t);return}var o=a1(r,t),s=i1(n);do{if(a=uv(r,e,i,t),a<s){var l=n;l>s&&(l=s),fv(r,e,e+l,e+a,t),a=l}o.pushRun(e,a),o.mergeRuns(),n-=a,e+=a}while(n!==0);o.forceMergeRuns()}}var ie=1,Hn=2,Zi=4,hv=!1;function ll(){hv||(hv=!0,console.warn("z / z2 / zlevel of displayable is invalid, which may cause unexpected errors"))}function vv(r,t){return r.zlevel===t.zlevel?r.z===t.z?r.z2-t.z2:r.z-t.z:r.zlevel-t.zlevel}var o1=(function(){function r(){this._roots=[],this._displayList=[],this._displayListLen=0,this.displayableSortFunc=vv}return r.prototype.traverse=function(t,e){for(var i=0;i<this._roots.length;i++)this._roots[i].traverse(t,e)},r.prototype.getDisplayList=function(t,e){e=e||!1;var i=this._displayList;return(t||!i.length)&&this.updateDisplayList(e),i},r.prototype.updateDisplayList=function(t){this._displayListLen=0;for(var e=this._roots,i=this._displayList,n=0,a=e.length;n<a;n++)this._updateAndAddDisplayable(e[n],null,t);i.length=this._displayListLen,Lo(i,vv)},r.prototype._updateAndAddDisplayable=function(t,e,i){if(!(t.ignore&&!i)){t.beforeUpdate(),t.update(),t.afterUpdate();var n=t.getClipPath(),a=e&&e.length,o=0,s=t.__clipPaths;if(!t.ignoreClip&&(a||n)){if(s||(s=t.__clipPaths=[]),a)for(var l=0;l<e.length;l++)s[o++]=e[l];for(var u=n,f=t;u;)u.parent=f,u.updateTransform(),s[o++]=u,f=u,u=u.getClipPath()}if(s&&(s.length=o),t.childrenRef){for(var h=t.childrenRef(),c=0;c<h.length;c++){var v=h[c];t.__dirty&&(v.__dirty|=ie),this._updateAndAddDisplayable(v,s,i)}t.__dirty=0}else{var d=t;isNaN(d.z)&&(ll(),d.z=0),isNaN(d.z2)&&(ll(),d.z2=0),isNaN(d.zlevel)&&(ll(),d.zlevel=0),this._displayList[this._displayListLen++]=d}var g=t.getDecalElement&&t.getDecalElement();g&&this._updateAndAddDisplayable(g,s,i);var m=t.getTextGuideLine();m&&this._updateAndAddDisplayable(m,s,i);var p=t.getTextContent();p&&this._updateAndAddDisplayable(p,s,i)}},r.prototype.addRoot=function(t){t.__zr&&t.__zr.storage===this||this._roots.push(t)},r.prototype.delRoot=function(t){if(t instanceof Array){for(var e=0,i=t.length;e<i;e++)this.delRoot(t[e]);return}var n=at(this._roots,t);n>=0&&this._roots.splice(n,1)},r.prototype.delAllRoots=function(){this._roots=[],this._displayList=[],this._displayListLen=0},r.prototype.getRoots=function(){return this._roots},r.prototype.dispose=function(){this._displayList=null,this._roots=null},r})(),Zo;Zo=j.hasGlobalWindow&&(window.requestAnimationFrame&&window.requestAnimationFrame.bind(window)||window.msRequestAnimationFrame&&window.msRequestAnimationFrame.bind(window)||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame)||function(r){return setTimeout(r,16)};var Kn={linear:function(r){return r},quadraticIn:function(r){return r*r},quadraticOut:function(r){return r*(2-r)},quadraticInOut:function(r){return(r*=2)<1?.5*r*r:-.5*(--r*(r-2)-1)},cubicIn:function(r){return r*r*r},cubicOut:function(r){return--r*r*r+1},cubicInOut:function(r){return(r*=2)<1?.5*r*r*r:.5*((r-=2)*r*r+2)},quarticIn:function(r){return r*r*r*r},quarticOut:function(r){return 1- --r*r*r*r},quarticInOut:function(r){return(r*=2)<1?.5*r*r*r*r:-.5*((r-=2)*r*r*r-2)},quinticIn:function(r){return r*r*r*r*r},quinticOut:function(r){return--r*r*r*r*r+1},quinticInOut:function(r){return(r*=2)<1?.5*r*r*r*r*r:.5*((r-=2)*r*r*r*r+2)},sinusoidalIn:function(r){return 1-Math.cos(r*Math.PI/2)},sinusoidalOut:function(r){return Math.sin(r*Math.PI/2)},sinusoidalInOut:function(r){return .5*(1-Math.cos(Math.PI*r))},exponentialIn:function(r){return r===0?0:Math.pow(1024,r-1)},exponentialOut:function(r){return r===1?1:1-Math.pow(2,-10*r)},exponentialInOut:function(r){return r===0?0:r===1?1:(r*=2)<1?.5*Math.pow(1024,r-1):.5*(-Math.pow(2,-10*(r-1))+2)},circularIn:function(r){return 1-Math.sqrt(1-r*r)},circularOut:function(r){return Math.sqrt(1- --r*r)},circularInOut:function(r){return(r*=2)<1?-.5*(Math.sqrt(1-r*r)-1):.5*(Math.sqrt(1-(r-=2)*r)+1)},elasticIn:function(r){var t,e=.1,i=.4;return r===0?0:r===1?1:(!e||e<1?(e=1,t=i/4):t=i*Math.asin(1/e)/(2*Math.PI),-(e*Math.pow(2,10*(r-=1))*Math.sin((r-t)*(2*Math.PI)/i)))},elasticOut:function(r){var t,e=.1,i=.4;return r===0?0:r===1?1:(!e||e<1?(e=1,t=i/4):t=i*Math.asin(1/e)/(2*Math.PI),e*Math.pow(2,-10*r)*Math.sin((r-t)*(2*Math.PI)/i)+1)},elasticInOut:function(r){var t,e=.1,i=.4;return r===0?0:r===1?1:(!e||e<1?(e=1,t=i/4):t=i*Math.asin(1/e)/(2*Math.PI),(r*=2)<1?-.5*(e*Math.pow(2,10*(r-=1))*Math.sin((r-t)*(2*Math.PI)/i)):e*Math.pow(2,-10*(r-=1))*Math.sin((r-t)*(2*Math.PI)/i)*.5+1)},backIn:function(r){var t=1.70158;return r*r*((t+1)*r-t)},backOut:function(r){var t=1.70158;return--r*r*((t+1)*r+t)+1},backInOut:function(r){var t=2.5949095;return(r*=2)<1?.5*(r*r*((t+1)*r-t)):.5*((r-=2)*r*((t+1)*r+t)+2)},bounceIn:function(r){return 1-Kn.bounceOut(1-r)},bounceOut:function(r){return r<1/2.75?7.5625*r*r:r<2/2.75?7.5625*(r-=1.5/2.75)*r+.75:r<2.5/2.75?7.5625*(r-=2.25/2.75)*r+.9375:7.5625*(r-=2.625/2.75)*r+.984375},bounceInOut:function(r){return r<.5?Kn.bounceIn(r*2)*.5:Kn.bounceOut(r*2-1)*.5+.5}},Ga=Math.pow,xr=Math.sqrt,Xo=1e-8,rg=1e-4,cv=xr(3),Va=1/3,Ee=cn(),ve=cn(),nn=cn();function _r(r){return r>-Xo&&r<Xo}function ig(r){return r>Xo||r<-Xo}function kt(r,t,e,i,n){var a=1-n;return a*a*(a*r+3*n*t)+n*n*(n*i+3*a*e)}function dv(r,t,e,i,n){var a=1-n;return 3*(((t-r)*a+2*(e-t)*n)*a+(i-e)*n*n)}function qo(r,t,e,i,n,a){var o=i+3*(t-e)-r,s=3*(e-t*2+r),l=3*(t-r),u=r-n,f=s*s-3*o*l,h=s*l-9*o*u,c=l*l-3*s*u,v=0;if(_r(f)&&_r(h))if(_r(s))a[0]=0;else{var d=-l/s;d>=0&&d<=1&&(a[v++]=d)}else{var g=h*h-4*f*c;if(_r(g)){var m=h/f,d=-s/o+m,p=-m/2;d>=0&&d<=1&&(a[v++]=d),p>=0&&p<=1&&(a[v++]=p)}else if(g>0){var y=xr(g),_=f*s+1.5*o*(-h+y),S=f*s+1.5*o*(-h-y);_<0?_=-Ga(-_,Va):_=Ga(_,Va),S<0?S=-Ga(-S,Va):S=Ga(S,Va);var d=(-s-(_+S))/(3*o);d>=0&&d<=1&&(a[v++]=d)}else{var x=(2*f*s-3*o*h)/(2*xr(f*f*f)),w=Math.acos(x)/3,b=xr(f),D=Math.cos(w),d=(-s-2*b*D)/(3*o),p=(-s+b*(D+cv*Math.sin(w)))/(3*o),C=(-s+b*(D-cv*Math.sin(w)))/(3*o);d>=0&&d<=1&&(a[v++]=d),p>=0&&p<=1&&(a[v++]=p),C>=0&&C<=1&&(a[v++]=C)}}return v}function ng(r,t,e,i,n){var a=6*e-12*t+6*r,o=9*t+3*i-3*r-9*e,s=3*t-3*r,l=0;if(_r(o)){if(ig(a)){var u=-s/a;u>=0&&u<=1&&(n[l++]=u)}}else{var f=a*a-4*o*s;if(_r(f))n[0]=-a/(2*o);else if(f>0){var h=xr(f),u=(-a+h)/(2*o),c=(-a-h)/(2*o);u>=0&&u<=1&&(n[l++]=u),c>=0&&c<=1&&(n[l++]=c)}}return l}function $o(r,t,e,i,n,a){var o=(t-r)*n+r,s=(e-t)*n+t,l=(i-e)*n+e,u=(s-o)*n+o,f=(l-s)*n+s,h=(f-u)*n+u;a[0]=r,a[1]=o,a[2]=u,a[3]=h,a[4]=h,a[5]=f,a[6]=l,a[7]=i}function s1(r,t,e,i,n,a,o,s,l,u,f){var h,c=.005,v=1/0,d,g,m,p;Ee[0]=l,Ee[1]=u;for(var y=0;y<1;y+=.05)ve[0]=kt(r,e,n,o,y),ve[1]=kt(t,i,a,s,y),m=rn(Ee,ve),m<v&&(h=y,v=m);v=1/0;for(var _=0;_<32&&!(c<rg);_++)d=h-c,g=h+c,ve[0]=kt(r,e,n,o,d),ve[1]=kt(t,i,a,s,d),m=rn(ve,Ee),d>=0&&m<v?(h=d,v=m):(nn[0]=kt(r,e,n,o,g),nn[1]=kt(t,i,a,s,g),p=rn(nn,Ee),g<=1&&p<v?(h=g,v=p):c*=.5);return xr(v)}function l1(r,t,e,i,n,a,o,s,l){for(var u=r,f=t,h=0,c=1/l,v=1;v<=l;v++){var d=v*c,g=kt(r,e,n,o,d),m=kt(t,i,a,s,d),p=g-u,y=m-f;h+=Math.sqrt(p*p+y*y),u=g,f=m}return h}function $t(r,t,e,i){var n=1-i;return n*(n*r+2*i*t)+i*i*e}function pv(r,t,e,i){return 2*((1-i)*(t-r)+i*(e-t))}function u1(r,t,e,i,n){var a=r-2*t+e,o=2*(t-r),s=r-i,l=0;if(_r(a)){if(ig(o)){var u=-s/o;u>=0&&u<=1&&(n[l++]=u)}}else{var f=o*o-4*a*s;if(_r(f)){var u=-o/(2*a);u>=0&&u<=1&&(n[l++]=u)}else if(f>0){var h=xr(f),u=(-o+h)/(2*a),c=(-o-h)/(2*a);u>=0&&u<=1&&(n[l++]=u),c>=0&&c<=1&&(n[l++]=c)}}return l}function ag(r,t,e){var i=r+e-2*t;return i===0?.5:(r-t)/i}function Ko(r,t,e,i,n){var a=(t-r)*i+r,o=(e-t)*i+t,s=(o-a)*i+a;n[0]=r,n[1]=a,n[2]=s,n[3]=s,n[4]=o,n[5]=e}function f1(r,t,e,i,n,a,o,s,l){var u,f=.005,h=1/0;Ee[0]=o,Ee[1]=s;for(var c=0;c<1;c+=.05){ve[0]=$t(r,e,n,c),ve[1]=$t(t,i,a,c);var v=rn(Ee,ve);v<h&&(u=c,h=v)}h=1/0;for(var d=0;d<32&&!(f<rg);d++){var g=u-f,m=u+f;ve[0]=$t(r,e,n,g),ve[1]=$t(t,i,a,g);var v=rn(ve,Ee);if(g>=0&&v<h)u=g,h=v;else{nn[0]=$t(r,e,n,m),nn[1]=$t(t,i,a,m);var p=rn(nn,Ee);m<=1&&p<h?(u=m,h=p):f*=.5}}return xr(h)}function h1(r,t,e,i,n,a,o){for(var s=r,l=t,u=0,f=1/o,h=1;h<=o;h++){var c=h*f,v=$t(r,e,n,c),d=$t(t,i,a,c),g=v-s,m=d-l;u+=Math.sqrt(g*g+m*m),s=v,l=d}return u}var v1=/cubic-bezier\(([0-9,\.e ]+)\)/;function og(r){var t=r&&v1.exec(r);if(t){var e=t[1].split(","),i=+ke(e[0]),n=+ke(e[1]),a=+ke(e[2]),o=+ke(e[3]);if(isNaN(i+n+a+o))return;var s=[];return function(l){return l<=0?0:l>=1?1:qo(0,i,a,1,l,s)&&kt(0,n,o,1,s[0])}}}var c1=(function(){function r(t){this._inited=!1,this._startTime=0,this._pausedTime=0,this._paused=!1,this._life=t.life||1e3,this._delay=t.delay||0,this.loop=t.loop||!1,this.onframe=t.onframe||Ut,this.ondestroy=t.ondestroy||Ut,this.onrestart=t.onrestart||Ut,t.easing&&this.setEasing(t.easing)}return r.prototype.step=function(t,e){if(this._inited||(this._startTime=t+this._delay,this._inited=!0),this._paused){this._pausedTime+=e;return}var i=this._life,n=t-this._startTime-this._pausedTime,a=n/i;a<0&&(a=0),a=Math.min(a,1);var o=this.easingFunc,s=o?o(a):a;if(this.onframe(s),a===1)if(this.loop){var l=n%i;this._startTime=t-l,this._pausedTime=0,this.onrestart()}else return!0;return!1},r.prototype.pause=function(){this._paused=!0},r.prototype.resume=function(){this._paused=!1},r.prototype.setEasing=function(t){this.easing=t,this.easingFunc=J(t)?t:Kn[t]||og(t)},r})(),sg=(function(){function r(t){this.value=t}return r})(),d1=(function(){function r(){this._len=0}return r.prototype.insert=function(t){var e=new sg(t);return this.insertEntry(e),e},r.prototype.insertEntry=function(t){this.head?(this.tail.next=t,t.prev=this.tail,t.next=null,this.tail=t):this.head=this.tail=t,this._len++},r.prototype.remove=function(t){var e=t.prev,i=t.next;e?e.next=i:this.head=i,i?i.prev=e:this.tail=e,t.next=t.prev=null,this._len--},r.prototype.len=function(){return this._len},r.prototype.clear=function(){this.head=this.tail=null,this._len=0},r})(),sn=(function(){function r(t){this._list=new d1,this._maxSize=10,this._map={},this._maxSize=t}return r.prototype.put=function(t,e){var i=this._list,n=this._map,a=null;if(n[t]==null){var o=i.len(),s=this._lastRemovedEntry;if(o>=this._maxSize&&o>0){var l=i.head;i.remove(l),delete n[l.key],a=l.value,this._lastRemovedEntry=l}s?s.value=e:s=new sg(e),s.key=t,i.insertEntry(s),n[t]=s}return a},r.prototype.get=function(t){var e=this._map[t],i=this._list;if(e!=null)return e!==i.tail&&(i.remove(e),i.insertEntry(e)),e.value},r.prototype.clear=function(){this._list.clear(),this._map={}},r.prototype.len=function(){return this._list.len()},r})(),gv={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 br(r){return r=Math.round(r),r<0?0:r>255?255:r}function ku(r){return r<0?0:r>1?1:r}function ul(r){var t=r;return t.length&&t.charAt(t.length-1)==="%"?br(parseFloat(t)/100*255):br(parseInt(t,10))}function di(r){var t=r;return t.length&&t.charAt(t.length-1)==="%"?ku(parseFloat(t)/100):ku(parseFloat(t))}function fl(r,t,e){return e<0?e+=1:e>1&&(e-=1),e*6<1?r+(t-r)*e*6:e*2<1?t:e*3<2?r+(t-r)*(2/3-e)*6:r}function Wa(r,t,e){return r+(t-r)*e}function le(r,t,e,i,n){return r[0]=t,r[1]=e,r[2]=i,r[3]=n,r}function Ou(r,t){return r[0]=t[0],r[1]=t[1],r[2]=t[2],r[3]=t[3],r}var lg=new sn(20),Ua=null;function Li(r,t){Ua&&Ou(Ua,t),Ua=lg.put(r,Ua||t.slice())}function Ne(r,t){if(r){t=t||[];var e=lg.get(r);if(e)return Ou(t,e);r=r+"";var i=r.replace(/ /g,"").toLowerCase();if(i in gv)return Ou(t,gv[i]),Li(r,t),t;var n=i.length;if(i.charAt(0)==="#"){if(n===4||n===5){var a=parseInt(i.slice(1,4),16);if(!(a>=0&&a<=4095)){le(t,0,0,0,1);return}return le(t,(a&3840)>>4|(a&3840)>>8,a&240|(a&240)>>4,a&15|(a&15)<<4,n===5?parseInt(i.slice(4),16)/15:1),Li(r,t),t}else if(n===7||n===9){var a=parseInt(i.slice(1,7),16);if(!(a>=0&&a<=16777215)){le(t,0,0,0,1);return}return le(t,(a&16711680)>>16,(a&65280)>>8,a&255,n===9?parseInt(i.slice(7),16)/255:1),Li(r,t),t}return}var o=i.indexOf("("),s=i.indexOf(")");if(o!==-1&&s+1===n){var l=i.substr(0,o),u=i.substr(o+1,s-(o+1)).split(","),f=1;switch(l){case"rgba":if(u.length!==4)return u.length===3?le(t,+u[0],+u[1],+u[2],1):le(t,0,0,0,1);f=di(u.pop());case"rgb":if(u.length>=3)return le(t,ul(u[0]),ul(u[1]),ul(u[2]),u.length===3?f:di(u[3])),Li(r,t),t;le(t,0,0,0,1);return;case"hsla":if(u.length!==4){le(t,0,0,0,1);return}return u[3]=di(u[3]),Bu(u,t),Li(r,t),t;case"hsl":if(u.length!==3){le(t,0,0,0,1);return}return Bu(u,t),Li(r,t),t;default:return}}le(t,0,0,0,1)}}function Bu(r,t){var e=(parseFloat(r[0])%360+360)%360/360,i=di(r[1]),n=di(r[2]),a=n<=.5?n*(i+1):n+i-n*i,o=n*2-a;return t=t||[],le(t,br(fl(o,a,e+1/3)*255),br(fl(o,a,e)*255),br(fl(o,a,e-1/3)*255),1),r.length===4&&(t[3]=r[3]),t}function p1(r){if(r){var t=r[0]/255,e=r[1]/255,i=r[2]/255,n=Math.min(t,e,i),a=Math.max(t,e,i),o=a-n,s=(a+n)/2,l,u;if(o===0)l=0,u=0;else{s<.5?u=o/(a+n):u=o/(2-a-n);var f=((a-t)/6+o/2)/o,h=((a-e)/6+o/2)/o,c=((a-i)/6+o/2)/o;t===a?l=c-h:e===a?l=1/3+f-c:i===a&&(l=2/3+h-f),l<0&&(l+=1),l>1&&(l-=1)}var v=[l*360,u,s];return r[3]!=null&&v.push(r[3]),v}}function mv(r,t){var e=Ne(r);if(e){for(var i=0;i<3;i++)e[i]=e[i]*(1-t)|0,e[i]>255?e[i]=255:e[i]<0&&(e[i]=0);return Ia(e,e.length===4?"rgba":"rgb")}}function g1(r,t,e){if(!(!(t&&t.length)||!(r>=0&&r<=1))){var i=r*(t.length-1),n=Math.floor(i),a=Math.ceil(i),o=Ne(t[n]),s=Ne(t[a]),l=i-n,u=Ia([br(Wa(o[0],s[0],l)),br(Wa(o[1],s[1],l)),br(Wa(o[2],s[2],l)),ku(Wa(o[3],s[3],l))],"rgba");return e?{color:u,leftIndex:n,rightIndex:a,value:i}:u}}function Nu(r,t,e,i){var n=Ne(r);if(r)return n=p1(n),e!=null&&(n[1]=di(J(e)?e(n[1]):e)),i!=null&&(n[2]=di(J(i)?i(n[2]):i)),Ia(Bu(n),"rgba")}function Ia(r,t){if(!(!r||!r.length)){var e=r[0]+","+r[1]+","+r[2];return(t==="rgba"||t==="hsva"||t==="hsla")&&(e+=","+r[3]),t+"("+e+")"}}function Qo(r,t){var e=Ne(r);return e?(.299*e[0]+.587*e[1]+.114*e[2])*e[3]/255+(1-e[3])*t:0}var yv=new sn(100);function _v(r){if(W(r)){var t=yv.get(r);return t||(t=mv(r,-.1),yv.put(r,t)),t}else if(As(r)){var e=O({},r);return e.colorStops=K(r.colorStops,function(i){return{offset:i.offset,color:mv(i.color,-.1)}}),e}return r}function m1(r){return r.type==="linear"}function y1(r){return r.type==="radial"}(function(){return j.hasGlobalWindow&&J(window.btoa)?function(r){return window.btoa(unescape(encodeURIComponent(r)))}:typeof Buffer<"u"?function(r){return Buffer.from(r).toString("base64")}:function(r){return null}})();var Fu=Array.prototype.slice;function Je(r,t,e){return(t-r)*e+r}function hl(r,t,e,i){for(var n=t.length,a=0;a<n;a++)r[a]=Je(t[a],e[a],i);return r}function _1(r,t,e,i){for(var n=t.length,a=n&&t[0].length,o=0;o<n;o++){r[o]||(r[o]=[]);for(var s=0;s<a;s++)r[o][s]=Je(t[o][s],e[o][s],i)}return r}function Ya(r,t,e,i){for(var n=t.length,a=0;a<n;a++)r[a]=t[a]+e[a]*i;return r}function Sv(r,t,e,i){for(var n=t.length,a=n&&t[0].length,o=0;o<n;o++){r[o]||(r[o]=[]);for(var s=0;s<a;s++)r[o][s]=t[o][s]+e[o][s]*i}return r}function S1(r,t){for(var e=r.length,i=t.length,n=e>i?t:r,a=Math.min(e,i),o=n[a-1]||{color:[0,0,0,0],offset:0},s=a;s<Math.max(e,i);s++)n.push({offset:o.offset,color:o.color.slice()})}function w1(r,t,e){var i=r,n=t;if(!(!i.push||!n.push)){var a=i.length,o=n.length;if(a!==o){var s=a>o;if(s)i.length=o;else for(var l=a;l<o;l++)i.push(e===1?n[l]:Fu.call(n[l]))}for(var u=i[0]&&i[0].length,l=0;l<i.length;l++)if(e===1)isNaN(i[l])&&(i[l]=n[l]);else for(var f=0;f<u;f++)isNaN(i[l][f])&&(i[l][f]=n[l][f])}}function Io(r){if(Jt(r)){var t=r.length;if(Jt(r[0])){for(var e=[],i=0;i<t;i++)e.push(Fu.call(r[i]));return e}return Fu.call(r)}return r}function Po(r){return r[0]=Math.floor(r[0])||0,r[1]=Math.floor(r[1])||0,r[2]=Math.floor(r[2])||0,r[3]=r[3]==null?1:r[3],"rgba("+r.join(",")+")"}function x1(r){return Jt(r&&r[0])?2:1}var Za=0,Ro=1,ug=2,Gn=3,zu=4,Hu=5,wv=6;function xv(r){return r===zu||r===Hu}function Xa(r){return r===Ro||r===ug}var yn=[0,0,0,0],b1=(function(){function r(t){this.keyframes=[],this.discrete=!1,this._invalid=!1,this._needsSort=!1,this._lastFr=0,this._lastFrP=0,this.propName=t}return r.prototype.isFinished=function(){return this._finished},r.prototype.setFinished=function(){this._finished=!0,this._additiveTrack&&this._additiveTrack.setFinished()},r.prototype.needsAnimate=function(){return this.keyframes.length>=1},r.prototype.getAdditiveTrack=function(){return this._additiveTrack},r.prototype.addKeyframe=function(t,e,i){this._needsSort=!0;var n=this.keyframes,a=n.length,o=!1,s=wv,l=e;if(Jt(e)){var u=x1(e);s=u,(u===1&&!mt(e[0])||u===2&&!mt(e[0][0]))&&(o=!0)}else if(mt(e)&&!sa(e))s=Za;else if(W(e))if(!isNaN(+e))s=Za;else{var f=Ne(e);f&&(l=f,s=Gn)}else if(As(e)){var h=O({},l);h.colorStops=K(e.colorStops,function(v){return{offset:v.offset,color:Ne(v.color)}}),m1(e)?s=zu:y1(e)&&(s=Hu),l=h}a===0?this.valType=s:(s!==this.valType||s===wv)&&(o=!0),this.discrete=this.discrete||o;var c={time:t,value:l,rawValue:e,percent:0};return i&&(c.easing=i,c.easingFunc=J(i)?i:Kn[i]||og(i)),n.push(c),c},r.prototype.prepare=function(t,e){var i=this.keyframes;this._needsSort&&i.sort(function(g,m){return g.time-m.time});for(var n=this.valType,a=i.length,o=i[a-1],s=this.discrete,l=Xa(n),u=xv(n),f=0;f<a;f++){var h=i[f],c=h.value,v=o.value;h.percent=h.time/t,s||(l&&f!==a-1?w1(c,v,n):u&&S1(c.colorStops,v.colorStops))}if(!s&&n!==Hu&&e&&this.needsAnimate()&&e.needsAnimate()&&n===e.valType&&!e._finished){this._additiveTrack=e;for(var d=i[0].value,f=0;f<a;f++)n===Za?i[f].additiveValue=i[f].value-d:n===Gn?i[f].additiveValue=Ya([],i[f].value,d,-1):Xa(n)&&(i[f].additiveValue=n===Ro?Ya([],i[f].value,d,-1):Sv([],i[f].value,d,-1))}},r.prototype.step=function(t,e){if(!this._finished){this._additiveTrack&&this._additiveTrack._finished&&(this._additiveTrack=null);var i=this._additiveTrack!=null,n=i?"additiveValue":"value",a=this.valType,o=this.keyframes,s=o.length,l=this.propName,u=a===Gn,f,h=this._lastFr,c=Math.min,v,d;if(s===1)v=d=o[0];else{if(e<0)f=0;else if(e<this._lastFrP){var g=c(h+1,s-1);for(f=g;f>=0&&!(o[f].percent<=e);f--);f=c(f,s-2)}else{for(f=h;f<s&&!(o[f].percent>e);f++);f=c(f-1,s-2)}d=o[f+1],v=o[f]}if(v&&d){this._lastFr=f,this._lastFrP=e;var m=d.percent-v.percent,p=m===0?1:c((e-v.percent)/m,1);d.easingFunc&&(p=d.easingFunc(p));var y=i?this._additiveValue:u?yn:t[l];if((Xa(a)||u)&&!y&&(y=this._additiveValue=[]),this.discrete)t[l]=p<1?v.rawValue:d.rawValue;else if(Xa(a))a===Ro?hl(y,v[n],d[n],p):_1(y,v[n],d[n],p);else if(xv(a)){var _=v[n],S=d[n],x=a===zu;t[l]={type:x?"linear":"radial",x:Je(_.x,S.x,p),y:Je(_.y,S.y,p),colorStops:K(_.colorStops,function(b,D){var C=S.colorStops[D];return{offset:Je(b.offset,C.offset,p),color:Po(hl([],b.color,C.color,p))}}),global:S.global},x?(t[l].x2=Je(_.x2,S.x2,p),t[l].y2=Je(_.y2,S.y2,p)):t[l].r=Je(_.r,S.r,p)}else if(u)hl(y,v[n],d[n],p),i||(t[l]=Po(y));else{var w=Je(v[n],d[n],p);i?this._additiveValue=w:t[l]=w}i&&this._addToTarget(t)}}},r.prototype._addToTarget=function(t){var e=this.valType,i=this.propName,n=this._additiveValue;e===Za?t[i]=t[i]+n:e===Gn?(Ne(t[i],yn),Ya(yn,yn,n,1),t[i]=Po(yn)):e===Ro?Ya(t[i],t[i],n,1):e===ug&&Sv(t[i],t[i],n,1)},r})(),$f=(function(){function r(t,e,i,n){if(this._tracks={},this._trackKeys=[],this._maxTime=0,this._started=0,this._clip=null,this._target=t,this._loop=e,e&&n){Wf("Can' use additive animation on looped animation.");return}this._additiveAnimators=n,this._allowDiscrete=i}return r.prototype.getMaxTime=function(){return this._maxTime},r.prototype.getDelay=function(){return this._delay},r.prototype.getLoop=function(){return this._loop},r.prototype.getTarget=function(){return this._target},r.prototype.changeTarget=function(t){this._target=t},r.prototype.when=function(t,e,i){return this.whenWithKeys(t,e,St(e),i)},r.prototype.whenWithKeys=function(t,e,i,n){for(var a=this._tracks,o=0;o<i.length;o++){var s=i[o],l=a[s];if(!l){l=a[s]=new b1(s);var u=void 0,f=this._getAdditiveTrack(s);if(f){var h=f.keyframes,c=h[h.length-1];u=c&&c.value,f.valType===Gn&&u&&(u=Po(u))}else u=this._target[s];if(u==null)continue;t>0&&l.addKeyframe(0,Io(u),n),this._trackKeys.push(s)}l.addKeyframe(t,Io(e[s]),n)}return this._maxTime=Math.max(this._maxTime,t),this},r.prototype.pause=function(){this._clip.pause(),this._paused=!0},r.prototype.resume=function(){this._clip.resume(),this._paused=!1},r.prototype.isPaused=function(){return!!this._paused},r.prototype.duration=function(t){return this._maxTime=t,this._force=!0,this},r.prototype._doneCallback=function(){this._setTracksFinished(),this._clip=null;var t=this._doneCbs;if(t)for(var e=t.length,i=0;i<e;i++)t[i].call(this)},r.prototype._abortedCallback=function(){this._setTracksFinished();var t=this.animation,e=this._abortedCbs;if(t&&t.removeClip(this._clip),this._clip=null,e)for(var i=0;i<e.length;i++)e[i].call(this)},r.prototype._setTracksFinished=function(){for(var t=this._tracks,e=this._trackKeys,i=0;i<e.length;i++)t[e[i]].setFinished()},r.prototype._getAdditiveTrack=function(t){var e,i=this._additiveAnimators;if(i)for(var n=0;n<i.length;n++){var a=i[n].getTrack(t);a&&(e=a)}return e},r.prototype.start=function(t){if(!(this._started>0)){this._started=1;for(var e=this,i=[],n=this._maxTime||0,a=0;a<this._trackKeys.length;a++){var o=this._trackKeys[a],s=this._tracks[o],l=this._getAdditiveTrack(o),u=s.keyframes,f=u.length;if(s.prepare(n,l),s.needsAnimate())if(!this._allowDiscrete&&s.discrete){var h=u[f-1];h&&(e._target[s.propName]=h.rawValue),s.setFinished()}else i.push(s)}if(i.length||this._force){var c=new c1({life:n,loop:this._loop,delay:this._delay||0,onframe:function(v){e._started=2;var d=e._additiveAnimators;if(d){for(var g=!1,m=0;m<d.length;m++)if(d[m]._clip){g=!0;break}g||(e._additiveAnimators=null)}for(var m=0;m<i.length;m++)i[m].step(e._target,v);var p=e._onframeCbs;if(p)for(var m=0;m<p.length;m++)p[m](e._target,v)},ondestroy:function(){e._doneCallback()}});this._clip=c,this.animation&&this.animation.addClip(c),t&&c.setEasing(t)}else this._doneCallback();return this}},r.prototype.stop=function(t){if(this._clip){var e=this._clip;t&&e.onframe(1),this._abortedCallback()}},r.prototype.delay=function(t){return this._delay=t,this},r.prototype.during=function(t){return t&&(this._onframeCbs||(this._onframeCbs=[]),this._onframeCbs.push(t)),this},r.prototype.done=function(t){return t&&(this._doneCbs||(this._doneCbs=[]),this._doneCbs.push(t)),this},r.prototype.aborted=function(t){return t&&(this._abortedCbs||(this._abortedCbs=[]),this._abortedCbs.push(t)),this},r.prototype.getClip=function(){return this._clip},r.prototype.getTrack=function(t){return this._tracks[t]},r.prototype.getTracks=function(){var t=this;return K(this._trackKeys,function(e){return t._tracks[e]})},r.prototype.stopTracks=function(t,e){if(!t.length||!this._clip)return!0;for(var i=this._tracks,n=this._trackKeys,a=0;a<t.length;a++){var o=i[t[a]];o&&!o.isFinished()&&(e?o.step(this._target,1):this._started===1&&o.step(this._target,0),o.setFinished())}for(var s=!0,a=0;a<n.length;a++)if(!i[n[a]].isFinished()){s=!1;break}return s&&this._abortedCallback(),s},r.prototype.saveTo=function(t,e,i){if(t){e=e||this._trackKeys;for(var n=0;n<e.length;n++){var a=e[n],o=this._tracks[a];if(!(!o||o.isFinished())){var s=o.keyframes,l=s[i?0:s.length-1];l&&(t[a]=Io(l.rawValue))}}}},r.prototype.__changeFinalValue=function(t,e){e=e||St(t);for(var i=0;i<e.length;i++){var n=e[i],a=this._tracks[n];if(a){var o=a.keyframes;if(o.length>1){var s=o.pop();a.addKeyframe(s.time,t[n]),a.prepare(this._maxTime,a.getAdditiveTrack())}}}},r})();function Qi(){return new Date().getTime()}var T1=(function(r){B(t,r);function t(e){var i=r.call(this)||this;return i._running=!1,i._time=0,i._pausedTime=0,i._pauseStart=0,i._paused=!1,e=e||{},i.stage=e.stage||{},i}return t.prototype.addClip=function(e){e.animation&&this.removeClip(e),this._head?(this._tail.next=e,e.prev=this._tail,e.next=null,this._tail=e):this._head=this._tail=e,e.animation=this},t.prototype.addAnimator=function(e){e.animation=this;var i=e.getClip();i&&this.addClip(i)},t.prototype.removeClip=function(e){if(e.animation){var i=e.prev,n=e.next;i?i.next=n:this._head=n,n?n.prev=i:this._tail=i,e.next=e.prev=e.animation=null}},t.prototype.removeAnimator=function(e){var i=e.getClip();i&&this.removeClip(i),e.animation=null},t.prototype.update=function(e){for(var i=Qi()-this._pausedTime,n=i-this._time,a=this._head;a;){var o=a.next,s=a.step(i,n);s&&(a.ondestroy(),this.removeClip(a)),a=o}this._time=i,e||(this.trigger("frame",n),this.stage.update&&this.stage.update())},t.prototype._startLoop=function(){var e=this;this._running=!0;function i(){e._running&&(Zo(i),!e._paused&&e.update())}Zo(i)},t.prototype.start=function(){this._running||(this._time=Qi(),this._pausedTime=0,this._startLoop())},t.prototype.stop=function(){this._running=!1},t.prototype.pause=function(){this._paused||(this._pauseStart=Qi(),this._paused=!0)},t.prototype.resume=function(){this._paused&&(this._pausedTime+=Qi()-this._pauseStart,this._paused=!1)},t.prototype.clear=function(){for(var e=this._head;e;){var i=e.next;e.prev=e.next=e.animation=null,e=i}this._head=this._tail=null},t.prototype.isFinished=function(){return this._head==null},t.prototype.animate=function(e,i){i=i||{},this.start();var n=new $f(e,i.loop);return this.addAnimator(n),n},t})(Te),C1=300,vl=j.domSupported,cl=(function(){var r=["click","dblclick","mousewheel","wheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],t=["touchstart","touchend","touchmove"],e={pointerdown:1,pointerup:1,pointermove:1,pointerout:1},i=K(r,function(n){var a=n.replace("mouse","pointer");return e.hasOwnProperty(a)?a:n});return{mouse:r,touch:t,pointer:i}})(),bv={mouse:["mousemove","mouseup"],pointer:["pointermove","pointerup"]},Tv=!1;function Gu(r){var t=r.pointerType;return t==="pen"||t==="touch"}function M1(r){r.touching=!0,r.touchTimer!=null&&(clearTimeout(r.touchTimer),r.touchTimer=null),r.touchTimer=setTimeout(function(){r.touching=!1,r.touchTimer=null},700)}function dl(r){r&&(r.zrByTouch=!0)}function D1(r,t){return ue(r.dom,new A1(r,t),!0)}function fg(r,t){for(var e=t,i=!1;e&&e.nodeType!==9&&!(i=e.domBelongToZr||e!==t&&e===r.painterRoot);)e=e.parentNode;return i}var A1=(function(){function r(t,e){this.stopPropagation=Ut,this.stopImmediatePropagation=Ut,this.preventDefault=Ut,this.type=e.type,this.target=this.currentTarget=t.dom,this.pointerType=e.pointerType,this.clientX=e.clientX,this.clientY=e.clientY}return r})(),Se={mousedown:function(r){r=ue(this.dom,r),this.__mayPointerCapture=[r.zrX,r.zrY],this.trigger("mousedown",r)},mousemove:function(r){r=ue(this.dom,r);var t=this.__mayPointerCapture;t&&(r.zrX!==t[0]||r.zrY!==t[1])&&this.__togglePointerCapture(!0),this.trigger("mousemove",r)},mouseup:function(r){r=ue(this.dom,r),this.__togglePointerCapture(!1),this.trigger("mouseup",r)},mouseout:function(r){r=ue(this.dom,r);var t=r.toElement||r.relatedTarget;fg(this,t)||(this.__pointerCapturing&&(r.zrEventControl="no_globalout"),this.trigger("mouseout",r))},wheel:function(r){Tv=!0,r=ue(this.dom,r),this.trigger("mousewheel",r)},mousewheel:function(r){Tv||(r=ue(this.dom,r),this.trigger("mousewheel",r))},touchstart:function(r){r=ue(this.dom,r),dl(r),this.__lastTouchMoment=new Date,this.handler.processGesture(r,"start"),Se.mousemove.call(this,r),Se.mousedown.call(this,r)},touchmove:function(r){r=ue(this.dom,r),dl(r),this.handler.processGesture(r,"change"),Se.mousemove.call(this,r)},touchend:function(r){r=ue(this.dom,r),dl(r),this.handler.processGesture(r,"end"),Se.mouseup.call(this,r),+new Date-+this.__lastTouchMoment<C1&&Se.click.call(this,r)},pointerdown:function(r){Se.mousedown.call(this,r)},pointermove:function(r){Gu(r)||Se.mousemove.call(this,r)},pointerup:function(r){Se.mouseup.call(this,r)},pointerout:function(r){Gu(r)||Se.mouseout.call(this,r)}};T(["click","dblclick","contextmenu"],function(r){Se[r]=function(t){t=ue(this.dom,t),this.trigger(r,t)}});var Vu={pointermove:function(r){Gu(r)||Vu.mousemove.call(this,r)},pointerup:function(r){Vu.mouseup.call(this,r)},mousemove:function(r){this.trigger("mousemove",r)},mouseup:function(r){var t=this.__pointerCapturing;this.__togglePointerCapture(!1),this.trigger("mouseup",r),t&&(r.zrEventControl="only_globalout",this.trigger("mouseout",r))}};function L1(r,t){var e=t.domHandlers;j.pointerEventsSupported?T(cl.pointer,function(i){Eo(t,i,function(n){e[i].call(r,n)})}):(j.touchEventsSupported&&T(cl.touch,function(i){Eo(t,i,function(n){e[i].call(r,n),M1(t)})}),T(cl.mouse,function(i){Eo(t,i,function(n){n=Zf(n),t.touching||e[i].call(r,n)})}))}function I1(r,t){j.pointerEventsSupported?T(bv.pointer,e):j.touchEventsSupported||T(bv.mouse,e);function e(i){function n(a){a=Zf(a),fg(r,a.target)||(a=D1(r,a),t.domHandlers[i].call(r,a))}Eo(t,i,n,{capture:!0})}}function Eo(r,t,e,i){r.mounted[t]=e,r.listenerOpts[t]=i,U_(r.domTarget,t,e,i)}function pl(r){var t=r.mounted;for(var e in t)t.hasOwnProperty(e)&&Y_(r.domTarget,e,t[e],r.listenerOpts[e]);r.mounted={}}var Cv=(function(){function r(t,e){this.mounted={},this.listenerOpts={},this.touching=!1,this.domTarget=t,this.domHandlers=e}return r})(),P1=(function(r){B(t,r);function t(e,i){var n=r.call(this)||this;return n.__pointerCapturing=!1,n.dom=e,n.painterRoot=i,n._localHandlerScope=new Cv(e,Se),vl&&(n._globalHandlerScope=new Cv(document,Vu)),L1(n,n._localHandlerScope),n}return t.prototype.dispose=function(){pl(this._localHandlerScope),vl&&pl(this._globalHandlerScope)},t.prototype.setCursor=function(e){this.dom.style&&(this.dom.style.cursor=e||"default")},t.prototype.__togglePointerCapture=function(e){if(this.__mayPointerCapture=null,vl&&+this.__pointerCapturing^+e){this.__pointerCapturing=e;var i=this._globalHandlerScope;e?I1(this,i):pl(i)}},t})(Te),hg=1;j.hasGlobalWindow&&(hg=Math.max(window.devicePixelRatio||window.screen&&window.screen.deviceXDPI/window.screen.logicalXDPI||1,1));var Jo=hg,Wu=.4,Uu="#333",Yu="#ccc",R1="#eee",Mv=Xf,Dv=5e-5;function Gr(r){return r>Dv||r<-Dv}var Vr=[],Ii=[],gl=rr(),ml=Math.abs,Kf=(function(){function r(){}return r.prototype.getLocalTransform=function(t){return r.getLocalTransform(this,t)},r.prototype.setPosition=function(t){this.x=t[0],this.y=t[1]},r.prototype.setScale=function(t){this.scaleX=t[0],this.scaleY=t[1]},r.prototype.setSkew=function(t){this.skewX=t[0],this.skewY=t[1]},r.prototype.setOrigin=function(t){this.originX=t[0],this.originY=t[1]},r.prototype.needLocalTransform=function(){return Gr(this.rotation)||Gr(this.x)||Gr(this.y)||Gr(this.scaleX-1)||Gr(this.scaleY-1)||Gr(this.skewX)||Gr(this.skewY)},r.prototype.updateTransform=function(){var t=this.parent&&this.parent.transform,e=this.needLocalTransform(),i=this.transform;if(!(e||t)){i&&(Mv(i),this.invTransform=null);return}i=i||rr(),e?this.getLocalTransform(i):Mv(i),t&&(e?qn(i,t,i):Kp(i,t)),this.transform=i,this._resolveGlobalScaleRatio(i)},r.prototype._resolveGlobalScaleRatio=function(t){var e=this.globalScaleRatio;if(e!=null&&e!==1){this.getGlobalScale(Vr);var i=Vr[0]<0?-1:1,n=Vr[1]<0?-1:1,a=((Vr[0]-i)*e+i)/Vr[0]||0,o=((Vr[1]-n)*e+n)/Vr[1]||0;t[0]*=a,t[1]*=a,t[2]*=o,t[3]*=o}this.invTransform=this.invTransform||rr(),La(this.invTransform,t)},r.prototype.getComputedTransform=function(){for(var t=this,e=[];t;)e.push(t),t=t.parent;for(;t=e.pop();)t.updateTransform();return this.transform},r.prototype.setLocalTransform=function(t){if(t){var e=t[0]*t[0]+t[1]*t[1],i=t[2]*t[2]+t[3]*t[3],n=Math.atan2(t[1],t[0]),a=Math.PI/2+n-Math.atan2(t[3],t[2]);i=Math.sqrt(i)*Math.cos(a),e=Math.sqrt(e),this.skewX=a,this.skewY=0,this.rotation=-n,this.x=+t[4],this.y=+t[5],this.scaleX=e,this.scaleY=i,this.originX=0,this.originY=0}},r.prototype.decomposeTransform=function(){if(this.transform){var t=this.parent,e=this.transform;t&&t.transform&&(t.invTransform=t.invTransform||rr(),qn(Ii,t.invTransform,e),e=Ii);var i=this.originX,n=this.originY;(i||n)&&(gl[4]=i,gl[5]=n,qn(Ii,e,gl),Ii[4]-=i,Ii[5]-=n,e=Ii),this.setLocalTransform(e)}},r.prototype.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):(t[0]=1,t[1]=1,t)},r.prototype.transformCoordToLocal=function(t,e){var i=[t,e],n=this.invTransform;return n&&ge(i,i,n),i},r.prototype.transformCoordToGlobal=function(t,e){var i=[t,e],n=this.transform;return n&&ge(i,i,n),i},r.prototype.getLineScale=function(){var t=this.transform;return t&&ml(t[0]-1)>1e-10&&ml(t[3]-1)>1e-10?Math.sqrt(ml(t[0]*t[3]-t[2]*t[1])):1},r.prototype.copyTransform=function(t){Zu(this,t)},r.getLocalTransform=function(t,e){e=e||[];var i=t.originX||0,n=t.originY||0,a=t.scaleX,o=t.scaleY,s=t.anchorX,l=t.anchorY,u=t.rotation||0,f=t.x,h=t.y,c=t.skewX?Math.tan(t.skewX):0,v=t.skewY?Math.tan(-t.skewY):0;if(i||n||s||l){var d=i+s,g=n+l;e[4]=-d*a-c*g*o,e[5]=-g*o-v*d*a}else e[4]=e[5]=0;return e[0]=a,e[3]=o,e[1]=v*a,e[2]=c*o,u&&qf(e,e,u),e[4]+=i+f,e[5]+=n+h,e},r.initDefaultProps=(function(){var t=r.prototype;t.scaleX=t.scaleY=t.globalScaleRatio=1,t.x=t.y=t.originX=t.originY=t.skewX=t.skewY=t.rotation=t.anchorX=t.anchorY=0})(),r})(),la=["x","y","originX","originY","anchorX","anchorY","rotation","scaleX","scaleY","skewX","skewY"];function Zu(r,t){for(var e=0;e<la.length;e++){var i=la[e];r[i]=t[i]}}function Fe(r){qa||(qa=new sn(100)),r=r||Mr;var t=qa.get(r);return t||(t={font:r,strWidthCache:new sn(500),asciiWidthMap:null,asciiWidthMapTried:!1,stWideCharWidth:ir.measureText("国",r).width,asciiCharWidth:ir.measureText("a",r).width},qa.put(r,t)),t}var qa;function E1(r){if(!(yl>=Av)){r=r||Mr;for(var t=[],e=+new Date,i=0;i<=127;i++)t[i]=ir.measureText(String.fromCharCode(i),r).width;var n=+new Date-e;return n>16?yl=Av:n>2&&yl++,t}}var yl=0,Av=5;function vg(r,t){return r.asciiWidthMapTried||(r.asciiWidthMap=E1(r.font),r.asciiWidthMapTried=!0),0<=t&&t<=127?r.asciiWidthMap!=null?r.asciiWidthMap[t]:r.asciiCharWidth:r.stWideCharWidth}function ze(r,t){var e=r.strWidthCache,i=e.get(t);return i==null&&(i=ir.measureText(t,r.font).width,e.put(t,i)),i}function Lv(r,t,e,i){var n=ze(Fe(t),r),a=Is(t),o=ln(0,n,e),s=pi(0,a,i),l=new rt(o,s,n,a);return l}function cg(r,t,e,i){var n=((r||"")+"").split(`
15
+ `),a=n.length;if(a===1)return Lv(n[0],t,e,i);for(var o=new rt(0,0,0,0),s=0;s<n.length;s++){var l=Lv(n[s],t,e,i);s===0?o.copy(l):o.union(l)}return o}function ln(r,t,e,i){return e==="right"?i?r+=t:r-=t:e==="center"&&(i?r+=t/2:r-=t/2),r}function pi(r,t,e,i){return e==="middle"?i?r+=t/2:r-=t/2:e==="bottom"&&(i?r+=t:r-=t),r}function Is(r){return Fe(r).stWideCharWidth}function Si(r,t){return typeof r=="string"?r.lastIndexOf("%")>=0?parseFloat(r)/100*t:parseFloat(r):r}function dg(r,t,e){var i=t.position||"inside",n=t.distance!=null?t.distance:5,a=e.height,o=e.width,s=a/2,l=e.x,u=e.y,f="left",h="top";if(i instanceof Array)l+=Si(i[0],e.width),u+=Si(i[1],e.height),f=null,h=null;else switch(i){case"left":l-=n,u+=s,f="right",h="middle";break;case"right":l+=n+o,u+=s,h="middle";break;case"top":l+=o/2,u-=n,f="center",h="bottom";break;case"bottom":l+=o/2,u+=a+n,f="center";break;case"inside":l+=o/2,u+=s,f="center",h="middle";break;case"insideLeft":l+=n,u+=s,h="middle";break;case"insideRight":l+=o-n,u+=s,f="right",h="middle";break;case"insideTop":l+=o/2,u+=n,f="center";break;case"insideBottom":l+=o/2,u+=a-n,f="center",h="bottom";break;case"insideTopLeft":l+=n,u+=n;break;case"insideTopRight":l+=o-n,u+=n,f="right";break;case"insideBottomLeft":l+=n,u+=a-n,h="bottom";break;case"insideBottomRight":l+=o-n,u+=a-n,f="right",h="bottom";break}return r=r||{},r.x=l,r.y=u,r.align=f,r.verticalAlign=h,r}var _l="__zr_normal__",Sl=la.concat(["ignore"]),k1=vn(la,function(r,t){return r[t]=!0,r},{ignore:!1}),Pi={},O1=new rt(0,0,0,0),$a=[],Ps=(function(){function r(t){this.id=Yp(),this.animators=[],this.currentStates=[],this.states={},this._init(t)}return r.prototype._init=function(t){this.attr(t)},r.prototype.drift=function(t,e,i){switch(this.draggable){case"horizontal":e=0;break;case"vertical":t=0;break}var n=this.transform;n||(n=this.transform=[1,0,0,1,0,0]),n[4]+=t,n[5]+=e,this.decomposeTransform(),this.markRedraw()},r.prototype.beforeUpdate=function(){},r.prototype.afterUpdate=function(){},r.prototype.update=function(){this.updateTransform(),this.__dirty&&this.updateInnerText()},r.prototype.updateInnerText=function(t){var e=this._textContent;if(e&&(!e.ignore||t)){this.textConfig||(this.textConfig={});var i=this.textConfig,n=i.local,a=e.innerTransformable,o=void 0,s=void 0,l=!1;a.parent=n?this:null;var u=!1;a.copyTransform(e);var f=i.position!=null,h=i.autoOverflowArea,c=void 0;if((h||f)&&(c=O1,i.layoutRect?c.copy(i.layoutRect):c.copy(this.getBoundingRect()),n||c.applyTransform(this.transform)),f){this.calculateTextPosition?this.calculateTextPosition(Pi,i,c):dg(Pi,i,c),a.x=Pi.x,a.y=Pi.y,o=Pi.align,s=Pi.verticalAlign;var v=i.origin;if(v&&i.rotation!=null){var d=void 0,g=void 0;v==="center"?(d=c.width*.5,g=c.height*.5):(d=Si(v[0],c.width),g=Si(v[1],c.height)),u=!0,a.originX=-a.x+d+(n?0:c.x),a.originY=-a.y+g+(n?0:c.y)}}i.rotation!=null&&(a.rotation=i.rotation);var m=i.offset;m&&(a.x+=m[0],a.y+=m[1],u||(a.originX=-m[0],a.originY=-m[1]));var p=this._innerTextDefaultStyle||(this._innerTextDefaultStyle={});if(h){var y=p.overflowRect=p.overflowRect||new rt(0,0,0,0);a.getLocalTransform($a),La($a,$a),rt.copy(y,c),y.applyTransform($a)}else p.overflowRect=null;var _=i.inside==null?typeof i.position=="string"&&i.position.indexOf("inside")>=0:i.inside,S=void 0,x=void 0,w=void 0;_&&this.canBeInsideText()?(S=i.insideFill,x=i.insideStroke,(S==null||S==="auto")&&(S=this.getInsideTextFill()),(x==null||x==="auto")&&(x=this.getInsideTextStroke(S),w=!0)):(S=i.outsideFill,x=i.outsideStroke,(S==null||S==="auto")&&(S=this.getOutsideFill()),(x==null||x==="auto")&&(x=this.getOutsideStroke(S),w=!0)),S=S||"#000",(S!==p.fill||x!==p.stroke||w!==p.autoStroke||o!==p.align||s!==p.verticalAlign)&&(l=!0,p.fill=S,p.stroke=x,p.autoStroke=w,p.align=o,p.verticalAlign=s,e.setDefaultTextStyle(p)),e.__dirty|=ie,l&&e.dirtyStyle(!0)}},r.prototype.canBeInsideText=function(){return!0},r.prototype.getInsideTextFill=function(){return"#fff"},r.prototype.getInsideTextStroke=function(t){return"#000"},r.prototype.getOutsideFill=function(){return this.__zr&&this.__zr.isDarkMode()?Yu:Uu},r.prototype.getOutsideStroke=function(t){var e=this.__zr&&this.__zr.getBackgroundColor(),i=typeof e=="string"&&Ne(e);i||(i=[255,255,255,1]);for(var n=i[3],a=this.__zr.isDarkMode(),o=0;o<3;o++)i[o]=i[o]*n+(a?0:255)*(1-n);return i[3]=1,Ia(i,"rgba")},r.prototype.traverse=function(t,e){},r.prototype.attrKV=function(t,e){t==="textConfig"?this.setTextConfig(e):t==="textContent"?this.setTextContent(e):t==="clipPath"?this.setClipPath(e):t==="extra"?(this.extra=this.extra||{},O(this.extra,e)):this[t]=e},r.prototype.hide=function(){this.ignore=!0,this.markRedraw()},r.prototype.show=function(){this.ignore=!1,this.markRedraw()},r.prototype.attr=function(t,e){if(typeof t=="string")this.attrKV(t,e);else if(Z(t))for(var i=t,n=St(i),a=0;a<n.length;a++){var o=n[a];this.attrKV(o,t[o])}return this.markRedraw(),this},r.prototype.saveCurrentToNormalState=function(t){this._innerSaveToNormal(t);for(var e=this._normalState,i=0;i<this.animators.length;i++){var n=this.animators[i],a=n.__fromStateTransition;if(!(n.getLoop()||a&&a!==_l)){var o=n.targetName,s=o?e[o]:e;n.saveTo(s)}}},r.prototype._innerSaveToNormal=function(t){var e=this._normalState;e||(e=this._normalState={}),t.textConfig&&!e.textConfig&&(e.textConfig=this.textConfig),this._savePrimaryToNormal(t,e,Sl)},r.prototype._savePrimaryToNormal=function(t,e,i){for(var n=0;n<i.length;n++){var a=i[n];t[a]!=null&&!(a in e)&&(e[a]=this[a])}},r.prototype.hasState=function(){return this.currentStates.length>0},r.prototype.getState=function(t){return this.states[t]},r.prototype.ensureState=function(t){var e=this.states;return e[t]||(e[t]={}),e[t]},r.prototype.clearStates=function(t){this.useState(_l,!1,t)},r.prototype.useState=function(t,e,i,n){var a=t===_l,o=this.hasState();if(!(!o&&a)){var s=this.currentStates,l=this.stateTransition;if(!(at(s,t)>=0&&(e||s.length===1))){var u;if(this.stateProxy&&!a&&(u=this.stateProxy(t)),u||(u=this.states&&this.states[t]),!u&&!a){Wf("State "+t+" not exists.");return}a||this.saveCurrentToNormalState(u);var f=!!(u&&u.hoverLayer||n);f&&this._toggleHoverLayerFlag(!0),this._applyStateObj(t,u,this._normalState,e,!i&&!this.__inHover&&l&&l.duration>0,l);var h=this._textContent,c=this._textGuide;return h&&h.useState(t,e,i,f),c&&c.useState(t,e,i,f),a?(this.currentStates=[],this._normalState={}):e?this.currentStates.push(t):this.currentStates=[t],this._updateAnimationTargets(),this.markRedraw(),!f&&this.__inHover&&(this._toggleHoverLayerFlag(!1),this.__dirty&=~ie),u}}},r.prototype.useStates=function(t,e,i){if(!t.length)this.clearStates();else{var n=[],a=this.currentStates,o=t.length,s=o===a.length;if(s){for(var l=0;l<o;l++)if(t[l]!==a[l]){s=!1;break}}if(s)return;for(var l=0;l<o;l++){var u=t[l],f=void 0;this.stateProxy&&(f=this.stateProxy(u,t)),f||(f=this.states[u]),f&&n.push(f)}var h=n[o-1],c=!!(h&&h.hoverLayer||i);c&&this._toggleHoverLayerFlag(!0);var v=this._mergeStates(n),d=this.stateTransition;this.saveCurrentToNormalState(v),this._applyStateObj(t.join(","),v,this._normalState,!1,!e&&!this.__inHover&&d&&d.duration>0,d);var g=this._textContent,m=this._textGuide;g&&g.useStates(t,e,c),m&&m.useStates(t,e,c),this._updateAnimationTargets(),this.currentStates=t.slice(),this.markRedraw(),!c&&this.__inHover&&(this._toggleHoverLayerFlag(!1),this.__dirty&=~ie)}},r.prototype.isSilent=function(){for(var t=this;t;){if(t.silent)return!0;var e=t.__hostTarget;t=e?t.ignoreHostSilent?null:e:t.parent}return!1},r.prototype._updateAnimationTargets=function(){for(var t=0;t<this.animators.length;t++){var e=this.animators[t];e.targetName&&e.changeTarget(this[e.targetName])}},r.prototype.removeState=function(t){var e=at(this.currentStates,t);if(e>=0){var i=this.currentStates.slice();i.splice(e,1),this.useStates(i)}},r.prototype.replaceState=function(t,e,i){var n=this.currentStates.slice(),a=at(n,t),o=at(n,e)>=0;a>=0?o?n.splice(a,1):n[a]=e:i&&!o&&n.push(e),this.useStates(n)},r.prototype.toggleState=function(t,e){e?this.useState(t,!0):this.removeState(t)},r.prototype._mergeStates=function(t){for(var e={},i,n=0;n<t.length;n++){var a=t[n];O(e,a),a.textConfig&&(i=i||{},O(i,a.textConfig))}return i&&(e.textConfig=i),e},r.prototype._applyStateObj=function(t,e,i,n,a,o){var s=!(e&&n);e&&e.textConfig?(this.textConfig=O({},n?this.textConfig:i.textConfig),O(this.textConfig,e.textConfig)):s&&i.textConfig&&(this.textConfig=i.textConfig);for(var l={},u=!1,f=0;f<Sl.length;f++){var h=Sl[f],c=a&&k1[h];e&&e[h]!=null?c?(u=!0,l[h]=e[h]):this[h]=e[h]:s&&i[h]!=null&&(c?(u=!0,l[h]=i[h]):this[h]=i[h])}if(!a)for(var f=0;f<this.animators.length;f++){var v=this.animators[f],d=v.targetName;v.getLoop()||v.__changeFinalValue(d?(e||i)[d]:e||i)}u&&this._transitionState(t,l,o)},r.prototype._attachComponent=function(t){if(!(t.__zr&&!t.__hostTarget)&&t!==this){var e=this.__zr;e&&t.addSelfToZr(e),t.__zr=e,t.__hostTarget=this}},r.prototype._detachComponent=function(t){t.__zr&&t.removeSelfFromZr(t.__zr),t.__zr=null,t.__hostTarget=null},r.prototype.getClipPath=function(){return this._clipPath},r.prototype.setClipPath=function(t){this._clipPath&&this._clipPath!==t&&this.removeClipPath(),this._attachComponent(t),this._clipPath=t,this.markRedraw()},r.prototype.removeClipPath=function(){var t=this._clipPath;t&&(this._detachComponent(t),this._clipPath=null,this.markRedraw())},r.prototype.getTextContent=function(){return this._textContent},r.prototype.setTextContent=function(t){var e=this._textContent;e!==t&&(e&&e!==t&&this.removeTextContent(),t.innerTransformable=new Kf,this._attachComponent(t),this._textContent=t,this.markRedraw())},r.prototype.setTextConfig=function(t){this.textConfig||(this.textConfig={}),O(this.textConfig,t),this.markRedraw()},r.prototype.removeTextConfig=function(){this.textConfig=null,this.markRedraw()},r.prototype.removeTextContent=function(){var t=this._textContent;t&&(t.innerTransformable=null,this._detachComponent(t),this._textContent=null,this._innerTextDefaultStyle=null,this.markRedraw())},r.prototype.getTextGuideLine=function(){return this._textGuide},r.prototype.setTextGuideLine=function(t){this._textGuide&&this._textGuide!==t&&this.removeTextGuideLine(),this._attachComponent(t),this._textGuide=t,this.markRedraw()},r.prototype.removeTextGuideLine=function(){var t=this._textGuide;t&&(this._detachComponent(t),this._textGuide=null,this.markRedraw())},r.prototype.markRedraw=function(){this.__dirty|=ie;var t=this.__zr;t&&(this.__inHover?t.refreshHover():t.refresh()),this.__hostTarget&&this.__hostTarget.markRedraw()},r.prototype.dirty=function(){this.markRedraw()},r.prototype._toggleHoverLayerFlag=function(t){this.__inHover=t;var e=this._textContent,i=this._textGuide;e&&(e.__inHover=t),i&&(i.__inHover=t)},r.prototype.addSelfToZr=function(t){if(this.__zr!==t){this.__zr=t;var e=this.animators;if(e)for(var i=0;i<e.length;i++)t.animation.addAnimator(e[i]);this._clipPath&&this._clipPath.addSelfToZr(t),this._textContent&&this._textContent.addSelfToZr(t),this._textGuide&&this._textGuide.addSelfToZr(t)}},r.prototype.removeSelfFromZr=function(t){if(this.__zr){this.__zr=null;var e=this.animators;if(e)for(var i=0;i<e.length;i++)t.animation.removeAnimator(e[i]);this._clipPath&&this._clipPath.removeSelfFromZr(t),this._textContent&&this._textContent.removeSelfFromZr(t),this._textGuide&&this._textGuide.removeSelfFromZr(t)}},r.prototype.animate=function(t,e,i){var n=t?this[t]:this,a=new $f(n,e,i);return t&&(a.targetName=t),this.addAnimator(a,t),a},r.prototype.addAnimator=function(t,e){var i=this.__zr,n=this;t.during(function(){n.updateDuringAnimation(e)}).done(function(){var a=n.animators,o=at(a,t);o>=0&&a.splice(o,1)}),this.animators.push(t),i&&i.animation.addAnimator(t),i&&i.wakeUp()},r.prototype.updateDuringAnimation=function(t){this.markRedraw()},r.prototype.stopAnimation=function(t,e){for(var i=this.animators,n=i.length,a=[],o=0;o<n;o++){var s=i[o];!t||t===s.scope?s.stop(e):a.push(s)}return this.animators=a,this},r.prototype.animateTo=function(t,e,i){wl(this,t,e,i)},r.prototype.animateFrom=function(t,e,i){wl(this,t,e,i,!0)},r.prototype._transitionState=function(t,e,i,n){for(var a=wl(this,e,i,n),o=0;o<a.length;o++)a[o].__fromStateTransition=t},r.prototype.getBoundingRect=function(){return null},r.prototype.getPaintRect=function(){return null},r.initDefaultProps=(function(){var t=r.prototype;t.type="element",t.name="",t.ignore=t.silent=t.ignoreHostSilent=t.isGroup=t.draggable=t.dragging=t.ignoreClip=t.__inHover=!1,t.__dirty=ie;function e(i,n,a,o){Object.defineProperty(t,i,{get:function(){if(!this[n]){var l=this[n]=[];s(this,l)}return this[n]},set:function(l){this[a]=l[0],this[o]=l[1],this[n]=l,s(this,l)}});function s(l,u){Object.defineProperty(u,0,{get:function(){return l[a]},set:function(f){l[a]=f}}),Object.defineProperty(u,1,{get:function(){return l[o]},set:function(f){l[o]=f}})}}Object.defineProperty&&(e("position","_legacyPos","x","y"),e("scale","_legacyScale","scaleX","scaleY"),e("origin","_legacyOrigin","originX","originY"))})(),r})();Ye(Ps,Te);Ye(Ps,Kf);function wl(r,t,e,i,n){e=e||{};var a=[];pg(r,"",r,t,e,i,a,n);var o=a.length,s=!1,l=e.done,u=e.aborted,f=function(){s=!0,o--,o<=0&&(s?l&&l():u&&u())},h=function(){o--,o<=0&&(s?l&&l():u&&u())};o||l&&l(),a.length>0&&e.during&&a[0].during(function(d,g){e.during(g)});for(var c=0;c<a.length;c++){var v=a[c];f&&v.done(f),h&&v.aborted(h),e.force&&v.duration(e.duration),v.start(e.easing)}return a}function xl(r,t,e){for(var i=0;i<e;i++)r[i]=t[i]}function B1(r){return Jt(r[0])}function N1(r,t,e){if(Jt(t[e]))if(Jt(r[e])||(r[e]=[]),jt(t[e])){var i=t[e].length;r[e].length!==i&&(r[e]=new t[e].constructor(i),xl(r[e],t[e],i))}else{var n=t[e],a=r[e],o=n.length;if(B1(n))for(var s=n[0].length,l=0;l<o;l++)a[l]?xl(a[l],n[l],s):a[l]=Array.prototype.slice.call(n[l]);else xl(a,n,o);a.length=n.length}else r[e]=t[e]}function F1(r,t){return r===t||Jt(r)&&Jt(t)&&z1(r,t)}function z1(r,t){var e=r.length;if(e!==t.length)return!1;for(var i=0;i<e;i++)if(r[i]!==t[i])return!1;return!0}function pg(r,t,e,i,n,a,o,s){for(var l=St(i),u=n.duration,f=n.delay,h=n.additive,c=n.setToFinal,v=!Z(a),d=r.animators,g=[],m=0;m<l.length;m++){var p=l[m],y=i[p];if(y!=null&&e[p]!=null&&(v||a[p]))if(Z(y)&&!Jt(y)&&!As(y)){if(t){s||(e[p]=y,r.updateDuringAnimation(t));continue}pg(r,p,e[p],y,n,a&&a[p],o,s)}else g.push(p);else s||(e[p]=y,r.updateDuringAnimation(t),g.push(p))}var _=g.length;if(!h&&_)for(var S=0;S<d.length;S++){var x=d[S];if(x.targetName===t){var w=x.stopTracks(g);if(w){var b=at(d,x);d.splice(b,1)}}}if(n.force||(g=Rt(g,function(A){return!F1(i[A],e[A])}),_=g.length),_>0||n.force&&!o.length){var D=void 0,C=void 0,M=void 0;if(s){C={},c&&(D={});for(var S=0;S<_;S++){var p=g[S];C[p]=e[p],c?D[p]=i[p]:e[p]=i[p]}}else if(c){M={};for(var S=0;S<_;S++){var p=g[S];M[p]=Io(e[p]),N1(e,i,p)}}var x=new $f(e,!1,!1,h?Rt(d,function(P){return P.targetName===t}):null);x.targetName=t,n.scope&&(x.scope=n.scope),c&&D&&x.whenWithKeys(0,D,g),M&&x.whenWithKeys(0,M,g),x.whenWithKeys(u??500,s?C:i,g).delay(f||0),r.addAnimator(x,t),o.push(x)}}var Dt=(function(r){B(t,r);function t(e){var i=r.call(this)||this;return i.isGroup=!0,i._children=[],i.attr(e),i}return t.prototype.childrenRef=function(){return this._children},t.prototype.children=function(){return this._children.slice()},t.prototype.childAt=function(e){return this._children[e]},t.prototype.childOfName=function(e){for(var i=this._children,n=0;n<i.length;n++)if(i[n].name===e)return i[n]},t.prototype.childCount=function(){return this._children.length},t.prototype.add=function(e){return e&&e!==this&&e.parent!==this&&(this._children.push(e),this._doAdd(e)),this},t.prototype.addBefore=function(e,i){if(e&&e!==this&&e.parent!==this&&i&&i.parent===this){var n=this._children,a=n.indexOf(i);a>=0&&(n.splice(a,0,e),this._doAdd(e))}return this},t.prototype.replace=function(e,i){var n=at(this._children,e);return n>=0&&this.replaceAt(i,n),this},t.prototype.replaceAt=function(e,i){var n=this._children,a=n[i];if(e&&e!==this&&e.parent!==this&&e!==a){n[i]=e,a.parent=null;var o=this.__zr;o&&a.removeSelfFromZr(o),this._doAdd(e)}return this},t.prototype._doAdd=function(e){e.parent&&e.parent.remove(e),e.parent=this;var i=this.__zr;i&&i!==e.__zr&&e.addSelfToZr(i),i&&i.refresh()},t.prototype.remove=function(e){var i=this.__zr,n=this._children,a=at(n,e);return a<0?this:(n.splice(a,1),e.parent=null,i&&e.removeSelfFromZr(i),i&&i.refresh(),this)},t.prototype.removeAll=function(){for(var e=this._children,i=this.__zr,n=0;n<e.length;n++){var a=e[n];i&&a.removeSelfFromZr(i),a.parent=null}return e.length=0,this},t.prototype.eachChild=function(e,i){for(var n=this._children,a=0;a<n.length;a++){var o=n[a];e.call(i,o,a)}return this},t.prototype.traverse=function(e,i){for(var n=0;n<this._children.length;n++){var a=this._children[n],o=e.call(i,a);a.isGroup&&!o&&a.traverse(e,i)}return this},t.prototype.addSelfToZr=function(e){r.prototype.addSelfToZr.call(this,e);for(var i=0;i<this._children.length;i++){var n=this._children[i];n.addSelfToZr(e)}},t.prototype.removeSelfFromZr=function(e){r.prototype.removeSelfFromZr.call(this,e);for(var i=0;i<this._children.length;i++){var n=this._children[i];n.removeSelfFromZr(e)}},t.prototype.getBoundingRect=function(e){for(var i=new rt(0,0,0,0),n=e||this._children,a=[],o=null,s=0;s<n.length;s++){var l=n[s];if(!(l.ignore||l.invisible)){var u=l.getBoundingRect(),f=l.getLocalTransform(a);f?(rt.applyTransform(i,u,f),o=o||i.clone(),o.union(i)):(o=o||u.clone(),o.union(u))}}return o||i},t})(Ps);Dt.prototype.type="group";/*!
16
+ * ZRender, a high performance 2d drawing library.
17
+ *
18
+ * Copyright (c) 2013, Baidu Inc.
19
+ * All rights reserved.
20
+ *
21
+ * LICENSE
22
+ * https://github.com/ecomfe/zrender/blob/master/LICENSE.txt
23
+ */var ko={},gg={};function H1(r){delete gg[r]}function G1(r){if(!r)return!1;if(typeof r=="string")return Qo(r,1)<Wu;if(r.colorStops){for(var t=r.colorStops,e=0,i=t.length,n=0;n<i;n++)e+=Qo(t[n].color,1);return e/=i,e<Wu}return!1}var V1=(function(){function r(t,e,i){var n=this;this._sleepAfterStill=10,this._stillFrameAccum=0,this._needsRefresh=!0,this._needsRefreshHover=!0,this._darkMode=!1,i=i||{},this.dom=e,this.id=t;var a=new o1,o=i.renderer||"canvas";ko[o]||(o=St(ko)[0]),i.useDirtyRect=i.useDirtyRect==null?!1:i.useDirtyRect;var s=new ko[o](e,a,i,t),l=i.ssr||s.ssrOnly;this.storage=a,this.painter=s;var u=!j.node&&!j.worker&&!l?new P1(s.getViewportRoot(),s.root):null,f=i.useCoarsePointer,h=f==null||f==="auto"?j.touchEventsSupported:!!f,c=44,v;h&&(v=$(i.pointerSize,c)),this.handler=new jp(a,s,u,s.root,v),this.animation=new T1({stage:{update:l?null:function(){return n._flush(!0)}}}),l||this.animation.start()}return r.prototype.add=function(t){this._disposed||!t||(this.storage.addRoot(t),t.addSelfToZr(this),this.refresh())},r.prototype.remove=function(t){this._disposed||!t||(this.storage.delRoot(t),t.removeSelfFromZr(this),this.refresh())},r.prototype.configLayer=function(t,e){this._disposed||(this.painter.configLayer&&this.painter.configLayer(t,e),this.refresh())},r.prototype.setBackgroundColor=function(t){this._disposed||(this.painter.setBackgroundColor&&this.painter.setBackgroundColor(t),this.refresh(),this._backgroundColor=t,this._darkMode=G1(t))},r.prototype.getBackgroundColor=function(){return this._backgroundColor},r.prototype.setDarkMode=function(t){this._darkMode=t},r.prototype.isDarkMode=function(){return this._darkMode},r.prototype.refreshImmediately=function(t){this._disposed||(t||this.animation.update(!0),this._needsRefresh=!1,this.painter.refresh(),this._needsRefresh=!1)},r.prototype.refresh=function(){this._disposed||(this._needsRefresh=!0,this.animation.start())},r.prototype.flush=function(){this._disposed||this._flush(!1)},r.prototype._flush=function(t){var e,i=Qi();this._needsRefresh&&(e=!0,this.refreshImmediately(t)),this._needsRefreshHover&&(e=!0,this.refreshHoverImmediately());var n=Qi();e?(this._stillFrameAccum=0,this.trigger("rendered",{elapsedTime:n-i})):this._sleepAfterStill>0&&(this._stillFrameAccum++,this._stillFrameAccum>this._sleepAfterStill&&this.animation.stop())},r.prototype.setSleepAfterStill=function(t){this._sleepAfterStill=t},r.prototype.wakeUp=function(){this._disposed||(this.animation.start(),this._stillFrameAccum=0)},r.prototype.refreshHover=function(){this._needsRefreshHover=!0},r.prototype.refreshHoverImmediately=function(){this._disposed||(this._needsRefreshHover=!1,this.painter.refreshHover&&this.painter.getType()==="canvas"&&this.painter.refreshHover())},r.prototype.resize=function(t){this._disposed||(t=t||{},this.painter.resize(t.width,t.height),this.handler.resize())},r.prototype.clearAnimation=function(){this._disposed||this.animation.clear()},r.prototype.getWidth=function(){if(!this._disposed)return this.painter.getWidth()},r.prototype.getHeight=function(){if(!this._disposed)return this.painter.getHeight()},r.prototype.setCursorStyle=function(t){this._disposed||this.handler.setCursorStyle(t)},r.prototype.findHover=function(t,e){if(!this._disposed)return this.handler.findHover(t,e)},r.prototype.on=function(t,e,i){return this._disposed||this.handler.on(t,e,i),this},r.prototype.off=function(t,e){this._disposed||this.handler.off(t,e)},r.prototype.trigger=function(t,e){this._disposed||this.handler.trigger(t,e)},r.prototype.clear=function(){if(!this._disposed){for(var t=this.storage.getRoots(),e=0;e<t.length;e++)t[e]instanceof Dt&&t[e].removeSelfFromZr(this);this.storage.delAllRoots(),this.painter.clear()}},r.prototype.dispose=function(){this._disposed||(this.animation.stop(),this.clear(),this.storage.dispose(),this.painter.dispose(),this.handler.dispose(),this.animation=this.storage=this.painter=this.handler=null,this._disposed=!0,H1(this.id))},r})();function Iv(r,t){var e=new V1(Yp(),r,t);return gg[e.id]=e,e}function W1(r,t){ko[r]=t}var Pv=1e-4,mg=20;function U1(r){return r.replace(/^\s+|\s+$/g,"")}var ua=Math.min,ne=Math.max,Oe=Math.abs;function Pt(r,t,e,i){var n=t[0],a=t[1],o=e[0],s=e[1],l=a-n,u=s-o;if(l===0)return u===0?o:(o+s)/2;if(i)if(l>0){if(r<=n)return o;if(r>=a)return s}else{if(r>=n)return o;if(r<=a)return s}else{if(r===n)return o;if(r===a)return s}return(r-n)/l*u+o}var Ot=Y1;function Y1(r,t,e){switch(r){case"center":case"middle":r="50%";break;case"left":case"top":r="0%";break;case"right":case"bottom":r="100%";break}return Xu(r,t,e)}function Xu(r,t,e){return W(r)?U1(r).match(/%$/)?parseFloat(r)/100*t+(e||0):parseFloat(r):r==null?NaN:+r}function Bt(r,t,e){return t==null&&(t=10),t=Math.min(Math.max(0,t),mg),r=(+r).toFixed(t),e?r:+r}function Vn(r){return r.sort(function(t,e){return t-e}),r}function tr(r){if(r=+r,isNaN(r))return 0;if(r>1e-14){for(var t=1,e=0;e<15;e++,t*=10)if(Math.round(r*t)/t===r)return e}return Z1(r)}function Z1(r){var t=r.toString().toLowerCase(),e=t.indexOf("e"),i=e>0?+t.slice(e+1):0,n=e>0?e:t.length,a=t.indexOf("."),o=a<0?0:n-1-a;return Math.max(0,o-i)}function yg(r,t){var e=Math.log,i=Math.LN10,n=Math.floor(e(r[1]-r[0])/i),a=Math.round(e(Oe(t[1]-t[0]))/i),o=Math.min(Math.max(-n+a,0),20);return isFinite(o)?o:20}function X1(r,t){var e=Math.max(tr(r),tr(t)),i=r+t;return e>mg?i:Bt(i,e)}function _g(r){var t=Math.PI*2;return(r%t+t)%t}function jo(r){return r>-Pv&&r<Pv}var q1=/^(?:(\d{4})(?:[-\/](\d{1,2})(?:[-\/](\d{1,2})(?:[T ](\d{1,2})(?::(\d{1,2})(?::(\d{1,2})(?:[.,](\d+))?)?)?(Z|[\+\-]\d\d:?\d\d)?)?)?)?)?$/;function dn(r){if(r instanceof Date)return r;if(W(r)){var t=q1.exec(r);if(!t)return new Date(NaN);if(t[8]){var e=+t[4]||0;return t[8].toUpperCase()!=="Z"&&(e-=+t[8].slice(0,3)),new Date(Date.UTC(+t[1],+(t[2]||1)-1,+t[3]||1,e,+(t[5]||0),+t[6]||0,t[7]?+t[7].substring(0,3):0))}else return new Date(+t[1],+(t[2]||1)-1,+t[3]||1,+t[4]||0,+(t[5]||0),+t[6]||0,t[7]?+t[7].substring(0,3):0)}else if(r==null)return new Date(NaN);return new Date(Math.round(r))}function $1(r){return Math.pow(10,Qf(r))}function Qf(r){if(r===0)return 0;var t=Math.floor(Math.log(r)/Math.LN10);return r/Math.pow(10,t)>=10&&t++,t}function Sg(r,t){var e=Qf(r),i=Math.pow(10,e),n=r/i,a;return n<1.5?a=1:n<2.5?a=2:n<4?a=3:n<7?a=5:a=10,r=a*i,e>=-20?+r.toFixed(e<0?-e:0):r}function ts(r){var t=parseFloat(r);return t==r&&(t!==0||!W(r)||r.indexOf("x")<=0)?t:NaN}function K1(r){return!isNaN(ts(r))}function wg(){return Math.round(Math.random()*9)}function xg(r,t){return t===0?r:xg(t,r%t)}function Rv(r,t){return r==null?t:t==null?r:r*t/xg(r,t)}var Q1="[ECharts] ",J1=typeof console<"u"&&console.warn&&console.log;function j1(r,t,e){J1&&console[r](Q1+t)}function bg(r,t){j1("error",r)}function Kt(r){throw new Error(r)}function Ev(r,t,e){return(t-r)*e+r}var Tg="series\0",tS="\0_ec_\0";function Yt(r){return r instanceof Array?r:r==null?[]:[r]}function kv(r,t,e){if(r){r[t]=r[t]||{},r.emphasis=r.emphasis||{},r.emphasis[t]=r.emphasis[t]||{};for(var i=0,n=e.length;i<n;i++){var a=e[i];!r.emphasis[t].hasOwnProperty(a)&&r[t].hasOwnProperty(a)&&(r.emphasis[t][a]=r[t][a])}}}var Ov=["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 Pa(r){return Z(r)&&!V(r)&&!(r instanceof Date)?r.value:r}function eS(r){return Z(r)&&!(r instanceof Array)}function rS(r,t,e){var i=e==="normalMerge",n=e==="replaceMerge",a=e==="replaceAll";r=r||[],t=(t||[]).slice();var o=Q();T(t,function(l,u){if(!Z(l)){t[u]=null;return}});var s=iS(r,o,e);return(i||n)&&nS(s,r,o,t),i&&aS(s,t),i||n?oS(s,t,n):a&&sS(s,t),lS(s),s}function iS(r,t,e){var i=[];if(e==="replaceAll")return i;for(var n=0;n<r.length;n++){var a=r[n];a&&a.id!=null&&t.set(a.id,n),i.push({existing:e==="replaceMerge"||fa(a)?null:a,newOption:null,keyInfo:null,brandNew:null})}return i}function nS(r,t,e,i){T(i,function(n,a){if(!(!n||n.id==null)){var o=Qn(n.id),s=e.get(o);if(s!=null){var l=r[s];nr(!l.newOption,'Duplicated option on id "'+o+'".'),l.newOption=n,l.existing=t[s],i[a]=null}}})}function aS(r,t){T(t,function(e,i){if(!(!e||e.name==null))for(var n=0;n<r.length;n++){var a=r[n].existing;if(!r[n].newOption&&a&&(a.id==null||e.id==null)&&!fa(e)&&!fa(a)&&Cg("name",a,e)){r[n].newOption=e,t[i]=null;return}}})}function oS(r,t,e){T(t,function(i){if(i){for(var n,a=0;(n=r[a])&&(n.newOption||fa(n.existing)||n.existing&&i.id!=null&&!Cg("id",i,n.existing));)a++;n?(n.newOption=i,n.brandNew=e):r.push({newOption:i,brandNew:e,existing:null,keyInfo:null}),a++}})}function sS(r,t){T(t,function(e){r.push({newOption:e,brandNew:!0,existing:null,keyInfo:null})})}function lS(r){var t=Q();T(r,function(e){var i=e.existing;i&&t.set(i.id,e)}),T(r,function(e){var i=e.newOption;nr(!i||i.id==null||!t.get(i.id)||t.get(i.id)===e,"id duplicates: "+(i&&i.id)),i&&i.id!=null&&t.set(i.id,e),!e.keyInfo&&(e.keyInfo={})}),T(r,function(e,i){var n=e.existing,a=e.newOption,o=e.keyInfo;if(Z(a)){if(o.name=a.name!=null?Qn(a.name):n?n.name:Tg+i,n)o.id=Qn(n.id);else if(a.id!=null)o.id=Qn(a.id);else{var s=0;do o.id="\0"+o.name+"\0"+s++;while(t.get(o.id))}t.set(o.id,e)}})}function Cg(r,t,e){var i=He(t[r],null),n=He(e[r],null);return i!=null&&n!=null&&i===n}function Qn(r){return He(r,"")}function He(r,t){return r==null?t:W(r)?r:mt(r)||Cu(r)?r+"":t}function Jf(r){var t=r.name;return!!(t&&t.indexOf(Tg))}function fa(r){return r&&r.id!=null&&Qn(r.id).indexOf(tS)===0}function uS(r,t,e){T(r,function(i){var n=i.newOption;Z(n)&&(i.keyInfo.mainType=t,i.keyInfo.subType=fS(t,n,i.existing,e))})}function fS(r,t,e,i){var n=t.type?t.type:e?e.subType:i.determineSubType(r,t);return n}function wi(r,t){if(t.dataIndexInside!=null)return t.dataIndexInside;if(t.dataIndex!=null)return V(t.dataIndex)?K(t.dataIndex,function(e){return r.indexOfRawIndex(e)}):r.indexOfRawIndex(t.dataIndex);if(t.name!=null)return V(t.name)?K(t.name,function(e){return r.indexOfName(e)}):r.indexOfName(t.name)}function yt(){var r="__ec_inner_"+hS++;return function(t){return t[r]||(t[r]={})}}var hS=wg();function bl(r,t,e){var i=jf(t,e),n=i.mainTypeSpecified,a=i.queryOptionMap,o=i.others,s=o,l=e?e.defaultMainType:null;return!n&&l&&a.set(l,{}),a.each(function(u,f){var h=Ra(r,f,u,{useDefault:l===f,enableAll:e&&e.enableAll!=null?e.enableAll:!0,enableNone:e&&e.enableNone!=null?e.enableNone:!0});s[f+"Models"]=h.models,s[f+"Model"]=h.models[0]}),s}function jf(r,t){var e;if(W(r)){var i={};i[r+"Index"]=0,e=i}else e=r;var n=Q(),a={},o=!1;return T(e,function(s,l){if(l==="dataIndex"||l==="dataIndexInside"){a[l]=s;return}var u=l.match(/^(\w+)(Index|Id|Name)$/)||[],f=u[1],h=(u[2]||"").toLowerCase();if(!(!f||!h||t&&t.includeMainTypes&&at(t.includeMainTypes,f)<0)){o=o||!!f;var c=n.get(f)||n.set(f,{});c[h]=s}}),{mainTypeSpecified:o,queryOptionMap:n,others:a}}var Wt={useDefault:!0,enableAll:!1,enableNone:!1},vS={useDefault:!1,enableAll:!0,enableNone:!0};function Ra(r,t,e,i){i=i||Wt;var n=e.index,a=e.id,o=e.name,s={models:null,specified:n!=null||a!=null||o!=null};if(!s.specified){var l=void 0;return s.models=i.useDefault&&(l=r.getComponent(t))?[l]:[],s}if(n==="none"||n===!1){if(i.enableNone)return s.models=[],s;n=-1}return n==="all"&&(i.enableAll?n=a=o=null:n=-1),s.models=r.queryComponents({mainType:t,index:n,id:a,name:o}),s}function Mg(r,t,e){r.setAttribute?r.setAttribute(t,e):r[t]=e}function cS(r,t){return r.getAttribute?r.getAttribute(t):r[t]}function dS(r){return r==="auto"?j.domSupported?"html":"richText":r||"html"}function pS(r,t,e,i,n){var a=t==null||t==="auto";if(i==null)return i;if(mt(i)){var o=Ev(e||0,i,n);return Bt(o,a?Math.max(tr(e||0),tr(i)):t)}else{if(W(i))return n<1?e:i;for(var s=[],l=e,u=i,f=Math.max(l?l.length:0,u.length),h=0;h<f;++h){var c=r.getDimensionInfo(h);if(c&&c.type==="ordinal")s[h]=(n<1&&l?l:u)[h];else{var v=l&&l[h]?l[h]:0,d=u[h],o=Ev(v,d,n);s[h]=Bt(o,a?Math.max(tr(v),tr(d)):t)}}return s}}var gS=".",Wr="___EC__COMPONENT__CONTAINER___",Dg="___EC__EXTENDED_CLASS___";function Be(r){var t={main:"",sub:""};if(r){var e=r.split(gS);t.main=e[0]||"",t.sub=e[1]||""}return t}function mS(r){nr(/^[a-zA-Z0-9_]+([.][a-zA-Z0-9_]+)?$/.test(r),'componentType "'+r+'" illegal')}function yS(r){return!!(r&&r[Dg])}function th(r,t){r.$constructor=r,r.extend=function(e){var i=this,n;return _S(i)?n=(function(a){B(o,a);function o(){return a.apply(this,arguments)||this}return o})(i):(n=function(){(e.$constructor||i).apply(this,arguments)},m_(n,this)),O(n.prototype,e),n[Dg]=!0,n.extend=this.extend,n.superCall=xS,n.superApply=bS,n.superClass=i,n}}function _S(r){return J(r)&&/^class\s/.test(Function.prototype.toString.call(r))}function Ag(r,t){r.extend=t.extend}var SS=Math.round(Math.random()*10);function wS(r){var t=["__\0is_clz",SS++].join("_");r.prototype[t]=!0,r.isInstance=function(e){return!!(e&&e[t])}}function xS(r,t){for(var e=[],i=2;i<arguments.length;i++)e[i-2]=arguments[i];return this.superClass.prototype[t].apply(r,e)}function bS(r,t,e){return this.superClass.prototype[t].apply(r,e)}function Rs(r){var t={};r.registerClass=function(i){var n=i.type||i.prototype.type;if(n){mS(n),i.prototype.type=n;var a=Be(n);if(!a.sub)t[a.main]=i;else if(a.sub!==Wr){var o=e(a);o[a.sub]=i}}return i},r.getClass=function(i,n,a){var o=t[i];if(o&&o[Wr]&&(o=n?o[n]:null),a&&!o)throw new Error(n?"Component "+i+"."+(n||"")+" is used but not imported.":i+".type should be specified.");return o},r.getClassesByMainType=function(i){var n=Be(i),a=[],o=t[n.main];return o&&o[Wr]?T(o,function(s,l){l!==Wr&&a.push(s)}):a.push(o),a},r.hasClass=function(i){var n=Be(i);return!!t[n.main]},r.getAllClassMainTypes=function(){var i=[];return T(t,function(n,a){i.push(a)}),i},r.hasSubTypes=function(i){var n=Be(i),a=t[n.main];return a&&a[Wr]};function e(i){var n=t[i.main];return(!n||!n[Wr])&&(n=t[i.main]={},n[Wr]=!0),n}}function ha(r,t){for(var e=0;e<r.length;e++)r[e][1]||(r[e][1]=r[e][0]);return t=t||!1,function(i,n,a){for(var o={},s=0;s<r.length;s++){var l=r[s][1];if(!(n&&at(n,l)>=0||a&&at(a,l)<0)){var u=i.getShallow(l,t);u!=null&&(o[r[s][0]]=u)}}return o}}var TS=[["fill","color"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["opacity"],["shadowColor"]],CS=ha(TS),MS=(function(){function r(){}return r.prototype.getAreaStyle=function(t,e){return CS(this,t,e)},r})(),qu=new sn(50);function DS(r){if(typeof r=="string"){var t=qu.get(r);return t&&t.image}else return r}function Lg(r,t,e,i,n){if(r)if(typeof r=="string"){if(t&&t.__zrImageSrc===r||!e)return t;var a=qu.get(r),o={hostEl:e,cb:i,cbPayload:n};return a?(t=a.image,!Es(t)&&a.pending.push(o)):(t=ir.loadImage(r,Bv,Bv),t.__zrImageSrc=r,qu.put(r,t.__cachedImgObj={image:t,pending:[o]})),t}else return r;else return t}function Bv(){var r=this.__cachedImgObj;this.onload=this.onerror=this.__cachedImgObj=null;for(var t=0;t<r.pending.length;t++){var e=r.pending[t],i=e.cb;i&&i(this,e.cbPayload),e.hostEl.dirty()}r.pending.length=0}function Es(r){return r&&r.width&&r.height}var Tl=/\{([a-zA-Z0-9_]+)\|([^}]*)\}/g;function AS(r,t,e,i,n,a){if(!e){r.text="",r.isTruncated=!1;return}var o=(t+"").split(`
24
+ `);a=Ig(e,i,n,a);for(var s=!1,l={},u=0,f=o.length;u<f;u++)Pg(l,o[u],a),o[u]=l.textLine,s=s||l.isTruncated;r.text=o.join(`
25
+ `),r.isTruncated=s}function Ig(r,t,e,i){i=i||{};var n=O({},i);e=$(e,"..."),n.maxIterations=$(i.maxIterations,2);var a=n.minChar=$(i.minChar,0),o=n.fontMeasureInfo=Fe(t),s=o.asciiCharWidth;n.placeholder=$(i.placeholder,"");for(var l=r=Math.max(0,r-1),u=0;u<a&&l>=s;u++)l-=s;var f=ze(o,e);return f>l&&(e="",f=0),l=r-f,n.ellipsis=e,n.ellipsisWidth=f,n.contentWidth=l,n.containerWidth=r,n}function Pg(r,t,e){var i=e.containerWidth,n=e.contentWidth,a=e.fontMeasureInfo;if(!i){r.textLine="",r.isTruncated=!1;return}var o=ze(a,t);if(o<=i){r.textLine=t,r.isTruncated=!1;return}for(var s=0;;s++){if(o<=n||s>=e.maxIterations){t+=e.ellipsis;break}var l=s===0?LS(t,n,a):o>0?Math.floor(t.length*n/o):0;t=t.substr(0,l),o=ze(a,t)}t===""&&(t=e.placeholder),r.textLine=t,r.isTruncated=!0}function LS(r,t,e){for(var i=0,n=0,a=r.length;n<a&&i<t;n++)i+=vg(e,r.charCodeAt(n));return n}function IS(r,t,e,i){var n=eh(r),a=t.overflow,o=t.padding,s=o?o[1]+o[3]:0,l=o?o[0]+o[2]:0,u=t.font,f=a==="truncate",h=Is(u),c=$(t.lineHeight,h),v=t.lineOverflow==="truncate",d=!1,g=t.width;g==null&&e!=null&&(g=e-s);var m=t.height;m==null&&i!=null&&(m=i-l);var p;g!=null&&(a==="break"||a==="breakAll")?p=n?Rg(n,t.font,g,a==="breakAll",0).lines:[]:p=n?n.split(`
26
+ `):[];var y=p.length*c;if(m==null&&(m=y),y>m&&v){var _=Math.floor(m/c);d=d||p.length>_,p=p.slice(0,_),y=p.length*c}if(n&&f&&g!=null)for(var S=Ig(g,u,t.ellipsis,{minChar:t.truncateMinChar,placeholder:t.placeholder}),x={},w=0;w<p.length;w++)Pg(x,p[w],S),p[w]=x.textLine,d=d||x.isTruncated;for(var b=m,D=0,C=Fe(u),w=0;w<p.length;w++)D=Math.max(ze(C,p[w]),D);g==null&&(g=D);var M=g;return b+=l,M+=s,{lines:p,height:m,outerWidth:M,outerHeight:b,lineHeight:c,calculatedLineHeight:h,contentWidth:D,contentHeight:y,width:g,isTruncated:d}}var PS=(function(){function r(){}return r})(),Nv=(function(){function r(t){this.tokens=[],t&&(this.tokens=t)}return r})(),RS=(function(){function r(){this.width=0,this.height=0,this.contentWidth=0,this.contentHeight=0,this.outerWidth=0,this.outerHeight=0,this.lines=[],this.isTruncated=!1}return r})();function ES(r,t,e,i,n){var a=new RS,o=eh(r);if(!o)return a;var s=t.padding,l=s?s[1]+s[3]:0,u=s?s[0]+s[2]:0,f=t.width;f==null&&e!=null&&(f=e-l);var h=t.height;h==null&&i!=null&&(h=i-u);for(var c=t.overflow,v=(c==="break"||c==="breakAll")&&f!=null?{width:f,accumWidth:0,breakAll:c==="breakAll"}:null,d=Tl.lastIndex=0,g;(g=Tl.exec(o))!=null;){var m=g.index;m>d&&Cl(a,o.substring(d,m),t,v),Cl(a,g[2],t,v,g[1]),d=Tl.lastIndex}d<o.length&&Cl(a,o.substring(d,o.length),t,v);var p=[],y=0,_=0,S=c==="truncate",x=t.lineOverflow==="truncate",w={};function b(Zt,De,Xe){Zt.width=De,Zt.lineHeight=Xe,y+=Xe,_=Math.max(_,De)}t:for(var D=0;D<a.lines.length;D++){for(var C=a.lines[D],M=0,A=0,P=0;P<C.tokens.length;P++){var L=C.tokens[P],I=L.styleName&&t.rich[L.styleName]||{},E=L.textPadding=I.padding,k=E?E[1]+E[3]:0,U=L.font=I.font||t.font;L.contentHeight=Is(U);var z=$(I.height,L.contentHeight);if(L.innerHeight=z,E&&(z+=E[0]+E[2]),L.height=z,L.lineHeight=en(I.lineHeight,t.lineHeight,z),L.align=I&&I.align||n,L.verticalAlign=I&&I.verticalAlign||"middle",x&&h!=null&&y+L.lineHeight>h){var R=a.lines.length;P>0?(C.tokens=C.tokens.slice(0,P),b(C,A,M),a.lines=a.lines.slice(0,D+1)):a.lines=a.lines.slice(0,D),a.isTruncated=a.isTruncated||a.lines.length<R;break t}var F=I.width,G=F==null||F==="auto";if(typeof F=="string"&&F.charAt(F.length-1)==="%")L.percentWidth=F,p.push(L),L.contentWidth=ze(Fe(U),L.text);else{if(G){var X=I.backgroundColor,tt=X&&X.image;tt&&(tt=DS(tt),Es(tt)&&(L.width=Math.max(L.width,tt.width*z/tt.height)))}var ot=S&&f!=null?f-A:null;ot!=null&&ot<L.width?!G||ot<k?(L.text="",L.width=L.contentWidth=0):(AS(w,L.text,ot-k,U,t.ellipsis,{minChar:t.truncateMinChar}),L.text=w.text,a.isTruncated=a.isTruncated||w.isTruncated,L.width=L.contentWidth=ze(Fe(U),L.text)):L.contentWidth=ze(Fe(U),L.text)}L.width+=k,A+=L.width,I&&(M=Math.max(M,L.lineHeight))}b(C,A,M)}a.outerWidth=a.width=$(f,_),a.outerHeight=a.height=$(h,y),a.contentHeight=y,a.contentWidth=_,a.outerWidth+=l,a.outerHeight+=u;for(var D=0;D<p.length;D++){var L=p[D],_t=L.percentWidth;L.width=parseInt(_t,10)/100*a.width}return a}function Cl(r,t,e,i,n){var a=t==="",o=n&&e.rich[n]||{},s=r.lines,l=o.font||e.font,u=!1,f,h;if(i){var c=o.padding,v=c?c[1]+c[3]:0;if(o.width!=null&&o.width!=="auto"){var d=Si(o.width,i.width)+v;s.length>0&&d+i.accumWidth>i.width&&(f=t.split(`
27
+ `),u=!0),i.accumWidth=d}else{var g=Rg(t,l,i.width,i.breakAll,i.accumWidth);i.accumWidth=g.accumWidth+v,h=g.linesWidths,f=g.lines}}f||(f=t.split(`
28
+ `));for(var m=Fe(l),p=0;p<f.length;p++){var y=f[p],_=new PS;if(_.styleName=n,_.text=y,_.isLineHolder=!y&&!a,typeof o.width=="number"?_.width=o.width:_.width=h?h[p]:ze(m,y),!p&&!u){var S=(s[s.length-1]||(s[0]=new Nv)).tokens,x=S.length;x===1&&S[0].isLineHolder?S[0]=_:(y||!x||a)&&S.push(_)}else s.push(new Nv([_]))}}function kS(r){var t=r.charCodeAt(0);return t>=32&&t<=591||t>=880&&t<=4351||t>=4608&&t<=5119||t>=7680&&t<=8303}var OS=vn(",&?/;] ".split(""),function(r,t){return r[t]=!0,r},{});function BS(r){return kS(r)?!!OS[r]:!0}function Rg(r,t,e,i,n){for(var a=[],o=[],s="",l="",u=0,f=0,h=Fe(t),c=0;c<r.length;c++){var v=r.charAt(c);if(v===`
29
+ `){l&&(s+=l,f+=u),a.push(s),o.push(f),s="",l="",u=0,f=0;continue}var d=vg(h,v.charCodeAt(0)),g=i?!1:!BS(v);if(a.length?f+d>e:n+f+d>e){f?(s||l)&&(g?(s||(s=l,l="",u=0,f=u),a.push(s),o.push(f-u),l+=v,u+=d,s="",f=u):(l&&(s+=l,l="",u=0),a.push(s),o.push(f),s=v,f=d)):g?(a.push(l),o.push(u),l=v,u=d):(a.push(v),o.push(d));continue}f+=d,g?(l+=v,u+=d):(l&&(s+=l,l="",u=0),s+=v)}return l&&(s+=l),s&&(a.push(s),o.push(f)),a.length===1&&(f+=n),{accumWidth:f,lines:a,linesWidths:o}}function Fv(r,t,e,i,n,a){if(r.baseX=e,r.baseY=i,r.outerWidth=r.outerHeight=null,!!t){var o=t.width*2,s=t.height*2;rt.set(zv,ln(e,o,n),pi(i,s,a),o,s),rt.intersect(t,zv,null,Hv);var l=Hv.outIntersectRect;r.outerWidth=l.width,r.outerHeight=l.height,r.baseX=ln(l.x,l.width,n,!0),r.baseY=pi(l.y,l.height,a,!0)}}var zv=new rt(0,0,0,0),Hv={outIntersectRect:{},clamp:!0};function eh(r){return r!=null?r+="":r=""}function NS(r){var t=eh(r.text),e=r.font,i=ze(Fe(e),t),n=Is(e);return $u(r,i,n,null)}function $u(r,t,e,i){var n=new rt(ln(r.x||0,t,r.textAlign),pi(r.y||0,e,r.textBaseline),t,e),a=i??(Eg(r)?r.lineWidth:0);return a>0&&(n.x-=a/2,n.y-=a/2,n.width+=a,n.height+=a),n}function Eg(r){var t=r.stroke;return t!=null&&t!=="none"&&r.lineWidth>0}var Ku="__zr_style_"+Math.round(Math.random()*10),gi={shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,shadowColor:"#000",opacity:1,blend:"source-over"},ks={style:{shadowBlur:!0,shadowOffsetX:!0,shadowOffsetY:!0,shadowColor:!0,opacity:!0}};gi[Ku]=!0;var Gv=["z","z2","invisible"],FS=["invisible"],Ea=(function(r){B(t,r);function t(e){return r.call(this,e)||this}return t.prototype._init=function(e){for(var i=St(e),n=0;n<i.length;n++){var a=i[n];a==="style"?this.useStyle(e[a]):r.prototype.attrKV.call(this,a,e[a])}this.style||this.useStyle({})},t.prototype.beforeBrush=function(){},t.prototype.afterBrush=function(){},t.prototype.innerBeforeBrush=function(){},t.prototype.innerAfterBrush=function(){},t.prototype.shouldBePainted=function(e,i,n,a){var o=this.transform;if(this.ignore||this.invisible||this.style.opacity===0||this.culling&&zS(this,e,i)||o&&!o[0]&&!o[3])return!1;if(n&&this.__clipPaths&&this.__clipPaths.length){for(var s=0;s<this.__clipPaths.length;++s)if(this.__clipPaths[s].isZeroArea())return!1}if(a&&this.parent)for(var l=this.parent;l;){if(l.ignore)return!1;l=l.parent}return!0},t.prototype.contain=function(e,i){return this.rectContain(e,i)},t.prototype.traverse=function(e,i){e.call(i,this)},t.prototype.rectContain=function(e,i){var n=this.transformCoordToLocal(e,i),a=this.getBoundingRect();return a.contain(n[0],n[1])},t.prototype.getPaintRect=function(){var e=this._paintRect;if(!this._paintRect||this.__dirty){var i=this.transform,n=this.getBoundingRect(),a=this.style,o=a.shadowBlur||0,s=a.shadowOffsetX||0,l=a.shadowOffsetY||0;e=this._paintRect||(this._paintRect=new rt(0,0,0,0)),i?rt.applyTransform(e,n,i):e.copy(n),(o||s||l)&&(e.width+=o*2+Math.abs(s),e.height+=o*2+Math.abs(l),e.x=Math.min(e.x,e.x+s-o),e.y=Math.min(e.y,e.y+l-o));var u=this.dirtyRectTolerance;e.isZero()||(e.x=Math.floor(e.x-u),e.y=Math.floor(e.y-u),e.width=Math.ceil(e.width+1+u*2),e.height=Math.ceil(e.height+1+u*2))}return e},t.prototype.setPrevPaintRect=function(e){e?(this._prevPaintRect=this._prevPaintRect||new rt(0,0,0,0),this._prevPaintRect.copy(e)):this._prevPaintRect=null},t.prototype.getPrevPaintRect=function(){return this._prevPaintRect},t.prototype.animateStyle=function(e){return this.animate("style",e)},t.prototype.updateDuringAnimation=function(e){e==="style"?this.dirtyStyle():this.markRedraw()},t.prototype.attrKV=function(e,i){e!=="style"?r.prototype.attrKV.call(this,e,i):this.style?this.setStyle(i):this.useStyle(i)},t.prototype.setStyle=function(e,i){return typeof e=="string"?this.style[e]=i:O(this.style,e),this.dirtyStyle(),this},t.prototype.dirtyStyle=function(e){e||this.markRedraw(),this.__dirty|=Hn,this._rect&&(this._rect=null)},t.prototype.dirty=function(){this.dirtyStyle()},t.prototype.styleChanged=function(){return!!(this.__dirty&Hn)},t.prototype.styleUpdated=function(){this.__dirty&=~Hn},t.prototype.createStyle=function(e){return Ls(gi,e)},t.prototype.useStyle=function(e){e[Ku]||(e=this.createStyle(e)),this.__inHover?this.__hoverStyle=e:this.style=e,this.dirtyStyle()},t.prototype.isStyleObject=function(e){return e[Ku]},t.prototype._innerSaveToNormal=function(e){r.prototype._innerSaveToNormal.call(this,e);var i=this._normalState;e.style&&!i.style&&(i.style=this._mergeStyle(this.createStyle(),this.style)),this._savePrimaryToNormal(e,i,Gv)},t.prototype._applyStateObj=function(e,i,n,a,o,s){r.prototype._applyStateObj.call(this,e,i,n,a,o,s);var l=!(i&&a),u;if(i&&i.style?o?a?u=i.style:(u=this._mergeStyle(this.createStyle(),n.style),this._mergeStyle(u,i.style)):(u=this._mergeStyle(this.createStyle(),a?this.style:n.style),this._mergeStyle(u,i.style)):l&&(u=n.style),u)if(o){var f=this.style;if(this.style=this.createStyle(l?{}:f),l)for(var h=St(f),c=0;c<h.length;c++){var v=h[c];v in u&&(u[v]=u[v],this.style[v]=f[v])}for(var d=St(u),c=0;c<d.length;c++){var v=d[c];this.style[v]=this.style[v]}this._transitionState(e,{style:u},s,this.getAnimationStyleProps())}else this.useStyle(u);for(var g=this.__inHover?FS:Gv,c=0;c<g.length;c++){var v=g[c];i&&i[v]!=null?this[v]=i[v]:l&&n[v]!=null&&(this[v]=n[v])}},t.prototype._mergeStates=function(e){for(var i=r.prototype._mergeStates.call(this,e),n,a=0;a<e.length;a++){var o=e[a];o.style&&(n=n||{},this._mergeStyle(n,o.style))}return n&&(i.style=n),i},t.prototype._mergeStyle=function(e,i){return O(e,i),e},t.prototype.getAnimationStyleProps=function(){return ks},t.initDefaultProps=(function(){var e=t.prototype;e.type="displayable",e.invisible=!1,e.z=0,e.z2=0,e.zlevel=0,e.culling=!1,e.cursor="pointer",e.rectHover=!1,e.incremental=!1,e._rect=null,e.dirtyRectTolerance=0,e.__dirty=ie|Hn})(),t})(Ps),Ml=new rt(0,0,0,0),Dl=new rt(0,0,0,0);function zS(r,t,e){return Ml.copy(r.getBoundingRect()),r.transform&&Ml.applyTransform(r.transform),Dl.width=t,Dl.height=e,!Ml.intersect(Dl)}var ce=Math.min,de=Math.max,Al=Math.sin,Ll=Math.cos,Ur=Math.PI*2,Ka=cn(),Qa=cn(),Ja=cn();function Vv(r,t,e,i,n,a){n[0]=ce(r,e),n[1]=ce(t,i),a[0]=de(r,e),a[1]=de(t,i)}var Wv=[],Uv=[];function HS(r,t,e,i,n,a,o,s,l,u){var f=ng,h=kt,c=f(r,e,n,o,Wv);l[0]=1/0,l[1]=1/0,u[0]=-1/0,u[1]=-1/0;for(var v=0;v<c;v++){var d=h(r,e,n,o,Wv[v]);l[0]=ce(d,l[0]),u[0]=de(d,u[0])}c=f(t,i,a,s,Uv);for(var v=0;v<c;v++){var g=h(t,i,a,s,Uv[v]);l[1]=ce(g,l[1]),u[1]=de(g,u[1])}l[0]=ce(r,l[0]),u[0]=de(r,u[0]),l[0]=ce(o,l[0]),u[0]=de(o,u[0]),l[1]=ce(t,l[1]),u[1]=de(t,u[1]),l[1]=ce(s,l[1]),u[1]=de(s,u[1])}function GS(r,t,e,i,n,a,o,s){var l=ag,u=$t,f=de(ce(l(r,e,n),1),0),h=de(ce(l(t,i,a),1),0),c=u(r,e,n,f),v=u(t,i,a,h);o[0]=ce(r,n,c),o[1]=ce(t,a,v),s[0]=de(r,n,c),s[1]=de(t,a,v)}function VS(r,t,e,i,n,a,o,s,l){var u=qi,f=$i,h=Math.abs(n-a);if(h%Ur<1e-4&&h>1e-4){s[0]=r-e,s[1]=t-i,l[0]=r+e,l[1]=t+i;return}if(Ka[0]=Ll(n)*e+r,Ka[1]=Al(n)*i+t,Qa[0]=Ll(a)*e+r,Qa[1]=Al(a)*i+t,u(s,Ka,Qa),f(l,Ka,Qa),n=n%Ur,n<0&&(n=n+Ur),a=a%Ur,a<0&&(a=a+Ur),n>a&&!o?a+=Ur:n<a&&o&&(n+=Ur),o){var c=a;a=n,n=c}for(var v=0;v<a;v+=Math.PI/2)v>n&&(Ja[0]=Ll(v)*e+r,Ja[1]=Al(v)*i+t,u(s,Ja,s),f(l,Ja,l))}var lt={M:1,L:2,C:3,Q:4,A:5,Z:6,R:7},Yr=[],Zr=[],Ae=[],lr=[],Le=[],Ie=[],Il=Math.min,Pl=Math.max,Xr=Math.cos,qr=Math.sin,qe=Math.abs,Qu=Math.PI,mr=Qu*2,Rl=typeof Float32Array<"u",_n=[];function El(r){var t=Math.round(r/Qu*1e8)/1e8;return t%2*Qu}function WS(r,t){var e=El(r[0]);e<0&&(e+=mr);var i=e-r[0],n=r[1];n+=i,!t&&n-e>=mr?n=e+mr:t&&e-n>=mr?n=e-mr:!t&&e>n?n=e+(mr-El(e-n)):t&&e<n&&(n=e-(mr-El(n-e))),r[0]=e,r[1]=n}var xi=(function(){function r(t){this.dpr=1,this._xi=0,this._yi=0,this._x0=0,this._y0=0,this._len=0,t&&(this._saveData=!1),this._saveData&&(this.data=[])}return r.prototype.increaseVersion=function(){this._version++},r.prototype.getVersion=function(){return this._version},r.prototype.setScale=function(t,e,i){i=i||0,i>0&&(this._ux=qe(i/Jo/t)||0,this._uy=qe(i/Jo/e)||0)},r.prototype.setDPR=function(t){this.dpr=t},r.prototype.setContext=function(t){this._ctx=t},r.prototype.getContext=function(){return this._ctx},r.prototype.beginPath=function(){return this._ctx&&this._ctx.beginPath(),this.reset(),this},r.prototype.reset=function(){this._saveData&&(this._len=0),this._pathSegLen&&(this._pathSegLen=null,this._pathLen=0),this._version++},r.prototype.moveTo=function(t,e){return this._drawPendingPt(),this.addData(lt.M,t,e),this._ctx&&this._ctx.moveTo(t,e),this._x0=t,this._y0=e,this._xi=t,this._yi=e,this},r.prototype.lineTo=function(t,e){var i=qe(t-this._xi),n=qe(e-this._yi),a=i>this._ux||n>this._uy;if(this.addData(lt.L,t,e),this._ctx&&a&&this._ctx.lineTo(t,e),a)this._xi=t,this._yi=e,this._pendingPtDist=0;else{var o=i*i+n*n;o>this._pendingPtDist&&(this._pendingPtX=t,this._pendingPtY=e,this._pendingPtDist=o)}return this},r.prototype.bezierCurveTo=function(t,e,i,n,a,o){return this._drawPendingPt(),this.addData(lt.C,t,e,i,n,a,o),this._ctx&&this._ctx.bezierCurveTo(t,e,i,n,a,o),this._xi=a,this._yi=o,this},r.prototype.quadraticCurveTo=function(t,e,i,n){return this._drawPendingPt(),this.addData(lt.Q,t,e,i,n),this._ctx&&this._ctx.quadraticCurveTo(t,e,i,n),this._xi=i,this._yi=n,this},r.prototype.arc=function(t,e,i,n,a,o){this._drawPendingPt(),_n[0]=n,_n[1]=a,WS(_n,o),n=_n[0],a=_n[1];var s=a-n;return this.addData(lt.A,t,e,i,i,n,s,0,o?0:1),this._ctx&&this._ctx.arc(t,e,i,n,a,o),this._xi=Xr(a)*i+t,this._yi=qr(a)*i+e,this},r.prototype.arcTo=function(t,e,i,n,a){return this._drawPendingPt(),this._ctx&&this._ctx.arcTo(t,e,i,n,a),this},r.prototype.rect=function(t,e,i,n){return this._drawPendingPt(),this._ctx&&this._ctx.rect(t,e,i,n),this.addData(lt.R,t,e,i,n),this},r.prototype.closePath=function(){this._drawPendingPt(),this.addData(lt.Z);var t=this._ctx,e=this._x0,i=this._y0;return t&&t.closePath(),this._xi=e,this._yi=i,this},r.prototype.fill=function(t){t&&t.fill(),this.toStatic()},r.prototype.stroke=function(t){t&&t.stroke(),this.toStatic()},r.prototype.len=function(){return this._len},r.prototype.setData=function(t){if(this._saveData){var e=t.length;!(this.data&&this.data.length===e)&&Rl&&(this.data=new Float32Array(e));for(var i=0;i<e;i++)this.data[i]=t[i];this._len=e}},r.prototype.appendPath=function(t){if(this._saveData){t instanceof Array||(t=[t]);for(var e=t.length,i=0,n=this._len,a=0;a<e;a++)i+=t[a].len();var o=this.data;if(Rl&&(o instanceof Float32Array||!o)&&(this.data=new Float32Array(n+i),n>0&&o))for(var s=0;s<n;s++)this.data[s]=o[s];for(var a=0;a<e;a++)for(var l=t[a].data,s=0;s<l.length;s++)this.data[n++]=l[s];this._len=n}},r.prototype.addData=function(t,e,i,n,a,o,s,l,u){if(this._saveData){var f=this.data;this._len+arguments.length>f.length&&(this._expandData(),f=this.data);for(var h=0;h<arguments.length;h++)f[this._len++]=arguments[h]}},r.prototype._drawPendingPt=function(){this._pendingPtDist>0&&(this._ctx&&this._ctx.lineTo(this._pendingPtX,this._pendingPtY),this._pendingPtDist=0)},r.prototype._expandData=function(){if(!(this.data instanceof Array)){for(var t=[],e=0;e<this._len;e++)t[e]=this.data[e];this.data=t}},r.prototype.toStatic=function(){if(this._saveData){this._drawPendingPt();var t=this.data;t instanceof Array&&(t.length=this._len,Rl&&this._len>11&&(this.data=new Float32Array(t)))}},r.prototype.getBoundingRect=function(){Ae[0]=Ae[1]=Le[0]=Le[1]=Number.MAX_VALUE,lr[0]=lr[1]=Ie[0]=Ie[1]=-Number.MAX_VALUE;var t=this.data,e=0,i=0,n=0,a=0,o;for(o=0;o<this._len;){var s=t[o++],l=o===1;switch(l&&(e=t[o],i=t[o+1],n=e,a=i),s){case lt.M:e=n=t[o++],i=a=t[o++],Le[0]=n,Le[1]=a,Ie[0]=n,Ie[1]=a;break;case lt.L:Vv(e,i,t[o],t[o+1],Le,Ie),e=t[o++],i=t[o++];break;case lt.C:HS(e,i,t[o++],t[o++],t[o++],t[o++],t[o],t[o+1],Le,Ie),e=t[o++],i=t[o++];break;case lt.Q:GS(e,i,t[o++],t[o++],t[o],t[o+1],Le,Ie),e=t[o++],i=t[o++];break;case lt.A:var u=t[o++],f=t[o++],h=t[o++],c=t[o++],v=t[o++],d=t[o++]+v;o+=1;var g=!t[o++];l&&(n=Xr(v)*h+u,a=qr(v)*c+f),VS(u,f,h,c,v,d,g,Le,Ie),e=Xr(d)*h+u,i=qr(d)*c+f;break;case lt.R:n=e=t[o++],a=i=t[o++];var m=t[o++],p=t[o++];Vv(n,a,n+m,a+p,Le,Ie);break;case lt.Z:e=n,i=a;break}qi(Ae,Ae,Le),$i(lr,lr,Ie)}return o===0&&(Ae[0]=Ae[1]=lr[0]=lr[1]=0),new rt(Ae[0],Ae[1],lr[0]-Ae[0],lr[1]-Ae[1])},r.prototype._calculateLength=function(){var t=this.data,e=this._len,i=this._ux,n=this._uy,a=0,o=0,s=0,l=0;this._pathSegLen||(this._pathSegLen=[]);for(var u=this._pathSegLen,f=0,h=0,c=0;c<e;){var v=t[c++],d=c===1;d&&(a=t[c],o=t[c+1],s=a,l=o);var g=-1;switch(v){case lt.M:a=s=t[c++],o=l=t[c++];break;case lt.L:{var m=t[c++],p=t[c++],y=m-a,_=p-o;(qe(y)>i||qe(_)>n||c===e-1)&&(g=Math.sqrt(y*y+_*_),a=m,o=p);break}case lt.C:{var S=t[c++],x=t[c++],m=t[c++],p=t[c++],w=t[c++],b=t[c++];g=l1(a,o,S,x,m,p,w,b,10),a=w,o=b;break}case lt.Q:{var S=t[c++],x=t[c++],m=t[c++],p=t[c++];g=h1(a,o,S,x,m,p,10),a=m,o=p;break}case lt.A:var D=t[c++],C=t[c++],M=t[c++],A=t[c++],P=t[c++],L=t[c++],I=L+P;c+=1,d&&(s=Xr(P)*M+D,l=qr(P)*A+C),g=Pl(M,A)*Il(mr,Math.abs(L)),a=Xr(I)*M+D,o=qr(I)*A+C;break;case lt.R:{s=a=t[c++],l=o=t[c++];var E=t[c++],k=t[c++];g=E*2+k*2;break}case lt.Z:{var y=s-a,_=l-o;g=Math.sqrt(y*y+_*_),a=s,o=l;break}}g>=0&&(u[h++]=g,f+=g)}return this._pathLen=f,f},r.prototype.rebuildPath=function(t,e){var i=this.data,n=this._ux,a=this._uy,o=this._len,s,l,u,f,h,c,v=e<1,d,g,m=0,p=0,y,_=0,S,x;if(!(v&&(this._pathSegLen||this._calculateLength(),d=this._pathSegLen,g=this._pathLen,y=e*g,!y)))t:for(var w=0;w<o;){var b=i[w++],D=w===1;switch(D&&(u=i[w],f=i[w+1],s=u,l=f),b!==lt.L&&_>0&&(t.lineTo(S,x),_=0),b){case lt.M:s=u=i[w++],l=f=i[w++],t.moveTo(u,f);break;case lt.L:{h=i[w++],c=i[w++];var C=qe(h-u),M=qe(c-f);if(C>n||M>a){if(v){var A=d[p++];if(m+A>y){var P=(y-m)/A;t.lineTo(u*(1-P)+h*P,f*(1-P)+c*P);break t}m+=A}t.lineTo(h,c),u=h,f=c,_=0}else{var L=C*C+M*M;L>_&&(S=h,x=c,_=L)}break}case lt.C:{var I=i[w++],E=i[w++],k=i[w++],U=i[w++],z=i[w++],R=i[w++];if(v){var A=d[p++];if(m+A>y){var P=(y-m)/A;$o(u,I,k,z,P,Yr),$o(f,E,U,R,P,Zr),t.bezierCurveTo(Yr[1],Zr[1],Yr[2],Zr[2],Yr[3],Zr[3]);break t}m+=A}t.bezierCurveTo(I,E,k,U,z,R),u=z,f=R;break}case lt.Q:{var I=i[w++],E=i[w++],k=i[w++],U=i[w++];if(v){var A=d[p++];if(m+A>y){var P=(y-m)/A;Ko(u,I,k,P,Yr),Ko(f,E,U,P,Zr),t.quadraticCurveTo(Yr[1],Zr[1],Yr[2],Zr[2]);break t}m+=A}t.quadraticCurveTo(I,E,k,U),u=k,f=U;break}case lt.A:var F=i[w++],G=i[w++],X=i[w++],tt=i[w++],ot=i[w++],_t=i[w++],Zt=i[w++],De=!i[w++],Xe=X>tt?X:tt,te=qe(X-tt)>.001,Et=ot+_t,et=!1;if(v){var A=d[p++];m+A>y&&(Et=ot+_t*(y-m)/A,et=!0),m+=A}if(te&&t.ellipse?t.ellipse(F,G,X,tt,Zt,ot,Et,De):t.arc(F,G,Xe,ot,Et,De),et)break t;D&&(s=Xr(ot)*X+F,l=qr(ot)*tt+G),u=Xr(Et)*X+F,f=qr(Et)*tt+G;break;case lt.R:s=u=i[w],l=f=i[w+1],h=i[w++],c=i[w++];var nt=i[w++],Or=i[w++];if(v){var A=d[p++];if(m+A>y){var Gt=y-m;t.moveTo(h,c),t.lineTo(h+Il(Gt,nt),c),Gt-=nt,Gt>0&&t.lineTo(h+nt,c+Il(Gt,Or)),Gt-=Or,Gt>0&&t.lineTo(h+Pl(nt-Gt,0),c+Or),Gt-=nt,Gt>0&&t.lineTo(h,c+Pl(Or-Gt,0));break t}m+=A}t.rect(h,c,nt,Or);break;case lt.Z:if(v){var A=d[p++];if(m+A>y){var P=(y-m)/A;t.lineTo(u*(1-P)+s*P,f*(1-P)+l*P);break t}m+=A}t.closePath(),u=s,f=l}}},r.prototype.clone=function(){var t=new r,e=this.data;return t.data=e.slice?e.slice():Array.prototype.slice.call(e),t._len=this._len,t},r.prototype.canSave=function(){return!!this._saveData},r.CMD=lt,r.initDefaultProps=(function(){var t=r.prototype;t._saveData=!0,t._ux=0,t._uy=0,t._pendingPtDist=0,t._version=0})(),r})();function Ri(r,t,e,i,n,a,o){if(n===0)return!1;var s=n,l=0,u=r;if(o>t+s&&o>i+s||o<t-s&&o<i-s||a>r+s&&a>e+s||a<r-s&&a<e-s)return!1;if(r!==e)l=(t-i)/(r-e),u=(r*i-e*t)/(r-e);else return Math.abs(a-r)<=s/2;var f=l*a-o+u,h=f*f/(l*l+1);return h<=s/2*s/2}function US(r,t,e,i,n,a,o,s,l,u,f){if(l===0)return!1;var h=l;if(f>t+h&&f>i+h&&f>a+h&&f>s+h||f<t-h&&f<i-h&&f<a-h&&f<s-h||u>r+h&&u>e+h&&u>n+h&&u>o+h||u<r-h&&u<e-h&&u<n-h&&u<o-h)return!1;var c=s1(r,t,e,i,n,a,o,s,u,f);return c<=h/2}function YS(r,t,e,i,n,a,o,s,l){if(o===0)return!1;var u=o;if(l>t+u&&l>i+u&&l>a+u||l<t-u&&l<i-u&&l<a-u||s>r+u&&s>e+u&&s>n+u||s<r-u&&s<e-u&&s<n-u)return!1;var f=f1(r,t,e,i,n,a,s,l);return f<=u/2}var Yv=Math.PI*2;function ja(r){return r%=Yv,r<0&&(r+=Yv),r}var Sn=Math.PI*2;function ZS(r,t,e,i,n,a,o,s,l){if(o===0)return!1;var u=o;s-=r,l-=t;var f=Math.sqrt(s*s+l*l);if(f-u>e||f+u<e)return!1;if(Math.abs(i-n)%Sn<1e-4)return!0;if(a){var h=i;i=ja(n),n=ja(h)}else i=ja(i),n=ja(n);i>n&&(n+=Sn);var c=Math.atan2(l,s);return c<0&&(c+=Sn),c>=i&&c<=n||c+Sn>=i&&c+Sn<=n}function $r(r,t,e,i,n,a){if(a>t&&a>i||a<t&&a<i||i===t)return 0;var o=(a-t)/(i-t),s=i<t?1:-1;(o===1||o===0)&&(s=i<t?.5:-.5);var l=o*(e-r)+r;return l===n?1/0:l>n?s:0}var ur=xi.CMD,Kr=Math.PI*2,XS=1e-4;function qS(r,t){return Math.abs(r-t)<XS}var Vt=[-1,-1,-1],he=[-1,-1];function $S(){var r=he[0];he[0]=he[1],he[1]=r}function KS(r,t,e,i,n,a,o,s,l,u){if(u>t&&u>i&&u>a&&u>s||u<t&&u<i&&u<a&&u<s)return 0;var f=qo(t,i,a,s,u,Vt);if(f===0)return 0;for(var h=0,c=-1,v=void 0,d=void 0,g=0;g<f;g++){var m=Vt[g],p=m===0||m===1?.5:1,y=kt(r,e,n,o,m);y<l||(c<0&&(c=ng(t,i,a,s,he),he[1]<he[0]&&c>1&&$S(),v=kt(t,i,a,s,he[0]),c>1&&(d=kt(t,i,a,s,he[1]))),c===2?m<he[0]?h+=v<t?p:-p:m<he[1]?h+=d<v?p:-p:h+=s<d?p:-p:m<he[0]?h+=v<t?p:-p:h+=s<v?p:-p)}return h}function QS(r,t,e,i,n,a,o,s){if(s>t&&s>i&&s>a||s<t&&s<i&&s<a)return 0;var l=u1(t,i,a,s,Vt);if(l===0)return 0;var u=ag(t,i,a);if(u>=0&&u<=1){for(var f=0,h=$t(t,i,a,u),c=0;c<l;c++){var v=Vt[c]===0||Vt[c]===1?.5:1,d=$t(r,e,n,Vt[c]);d<o||(Vt[c]<u?f+=h<t?v:-v:f+=a<h?v:-v)}return f}else{var v=Vt[0]===0||Vt[0]===1?.5:1,d=$t(r,e,n,Vt[0]);return d<o?0:a<t?v:-v}}function JS(r,t,e,i,n,a,o,s){if(s-=t,s>e||s<-e)return 0;var l=Math.sqrt(e*e-s*s);Vt[0]=-l,Vt[1]=l;var u=Math.abs(i-n);if(u<1e-4)return 0;if(u>=Kr-1e-4){i=0,n=Kr;var f=a?1:-1;return o>=Vt[0]+r&&o<=Vt[1]+r?f:0}if(i>n){var h=i;i=n,n=h}i<0&&(i+=Kr,n+=Kr);for(var c=0,v=0;v<2;v++){var d=Vt[v];if(d+r>o){var g=Math.atan2(s,d),f=a?1:-1;g<0&&(g=Kr+g),(g>=i&&g<=n||g+Kr>=i&&g+Kr<=n)&&(g>Math.PI/2&&g<Math.PI*1.5&&(f=-f),c+=f)}}return c}function kg(r,t,e,i,n){for(var a=r.data,o=r.len(),s=0,l=0,u=0,f=0,h=0,c,v,d=0;d<o;){var g=a[d++],m=d===1;switch(g===ur.M&&d>1&&(e||(s+=$r(l,u,f,h,i,n))),m&&(l=a[d],u=a[d+1],f=l,h=u),g){case ur.M:f=a[d++],h=a[d++],l=f,u=h;break;case ur.L:if(e){if(Ri(l,u,a[d],a[d+1],t,i,n))return!0}else s+=$r(l,u,a[d],a[d+1],i,n)||0;l=a[d++],u=a[d++];break;case ur.C:if(e){if(US(l,u,a[d++],a[d++],a[d++],a[d++],a[d],a[d+1],t,i,n))return!0}else s+=KS(l,u,a[d++],a[d++],a[d++],a[d++],a[d],a[d+1],i,n)||0;l=a[d++],u=a[d++];break;case ur.Q:if(e){if(YS(l,u,a[d++],a[d++],a[d],a[d+1],t,i,n))return!0}else s+=QS(l,u,a[d++],a[d++],a[d],a[d+1],i,n)||0;l=a[d++],u=a[d++];break;case ur.A:var p=a[d++],y=a[d++],_=a[d++],S=a[d++],x=a[d++],w=a[d++];d+=1;var b=!!(1-a[d++]);c=Math.cos(x)*_+p,v=Math.sin(x)*S+y,m?(f=c,h=v):s+=$r(l,u,c,v,i,n);var D=(i-p)*S/_+p;if(e){if(ZS(p,y,S,x,x+w,b,t,D,n))return!0}else s+=JS(p,y,S,x,x+w,b,D,n);l=Math.cos(x+w)*_+p,u=Math.sin(x+w)*S+y;break;case ur.R:f=l=a[d++],h=u=a[d++];var C=a[d++],M=a[d++];if(c=f+C,v=h+M,e){if(Ri(f,h,c,h,t,i,n)||Ri(c,h,c,v,t,i,n)||Ri(c,v,f,v,t,i,n)||Ri(f,v,f,h,t,i,n))return!0}else s+=$r(c,h,c,v,i,n),s+=$r(f,v,f,h,i,n);break;case ur.Z:if(e){if(Ri(l,u,f,h,t,i,n))return!0}else s+=$r(l,u,f,h,i,n);l=f,u=h;break}}return!e&&!qS(u,h)&&(s+=$r(l,u,f,h,i,n)||0),s!==0}function jS(r,t,e){return kg(r,0,!1,t,e)}function tw(r,t,e,i){return kg(r,t,!0,e,i)}var Og=ht({fill:"#000",stroke:null,strokePercent:1,fillOpacity:1,strokeOpacity:1,lineDashOffset:0,lineWidth:1,lineCap:"butt",miterLimit:10,strokeNoScale:!1,strokeFirst:!1},gi),ew={style:ht({fill:!0,stroke:!0,strokePercent:!0,fillOpacity:!0,strokeOpacity:!0,lineDashOffset:!0,lineWidth:!0,miterLimit:!0},ks.style)},kl=la.concat(["invisible","culling","z","z2","zlevel","parent"]),dt=(function(r){B(t,r);function t(e){return r.call(this,e)||this}return t.prototype.update=function(){var e=this;r.prototype.update.call(this);var i=this.style;if(i.decal){var n=this._decalEl=this._decalEl||new t;n.buildPath===t.prototype.buildPath&&(n.buildPath=function(l){e.buildPath(l,e.shape)}),n.silent=!0;var a=n.style;for(var o in i)a[o]!==i[o]&&(a[o]=i[o]);a.fill=i.fill?i.decal:null,a.decal=null,a.shadowColor=null,i.strokeFirst&&(a.stroke=null);for(var s=0;s<kl.length;++s)n[kl[s]]=this[kl[s]];n.__dirty|=ie}else this._decalEl&&(this._decalEl=null)},t.prototype.getDecalElement=function(){return this._decalEl},t.prototype._init=function(e){var i=St(e);this.shape=this.getDefaultShape();var n=this.getDefaultStyle();n&&this.useStyle(n);for(var a=0;a<i.length;a++){var o=i[a],s=e[o];o==="style"?this.style?O(this.style,s):this.useStyle(s):o==="shape"?O(this.shape,s):r.prototype.attrKV.call(this,o,s)}this.style||this.useStyle({})},t.prototype.getDefaultStyle=function(){return null},t.prototype.getDefaultShape=function(){return{}},t.prototype.canBeInsideText=function(){return this.hasFill()},t.prototype.getInsideTextFill=function(){var e=this.style.fill;if(e!=="none"){if(W(e)){var i=Qo(e,0);return i>.5?Uu:i>.2?R1:Yu}else if(e)return Yu}return Uu},t.prototype.getInsideTextStroke=function(e){var i=this.style.fill;if(W(i)){var n=this.__zr,a=!!(n&&n.isDarkMode()),o=Qo(e,0)<Wu;if(a===o)return i}},t.prototype.buildPath=function(e,i,n){},t.prototype.pathUpdated=function(){this.__dirty&=~Zi},t.prototype.getUpdatedPathProxy=function(e){return!this.path&&this.createPathProxy(),this.path.beginPath(),this.buildPath(this.path,this.shape,e),this.path},t.prototype.createPathProxy=function(){this.path=new xi(!1)},t.prototype.hasStroke=function(){var e=this.style,i=e.stroke;return!(i==null||i==="none"||!(e.lineWidth>0))},t.prototype.hasFill=function(){var e=this.style,i=e.fill;return i!=null&&i!=="none"},t.prototype.getBoundingRect=function(){var e=this._rect,i=this.style,n=!e;if(n){var a=!1;this.path||(a=!0,this.createPathProxy());var o=this.path;(a||this.__dirty&Zi)&&(o.beginPath(),this.buildPath(o,this.shape,!1),this.pathUpdated()),e=o.getBoundingRect()}if(this._rect=e,this.hasStroke()&&this.path&&this.path.len()>0){var s=this._rectStroke||(this._rectStroke=e.clone());if(this.__dirty||n){s.copy(e);var l=i.strokeNoScale?this.getLineScale():1,u=i.lineWidth;if(!this.hasFill()){var f=this.strokeContainThreshold;u=Math.max(u,f??4)}l>1e-10&&(s.width+=u/l,s.height+=u/l,s.x-=u/l/2,s.y-=u/l/2)}return s}return e},t.prototype.contain=function(e,i){var n=this.transformCoordToLocal(e,i),a=this.getBoundingRect(),o=this.style;if(e=n[0],i=n[1],a.contain(e,i)){var s=this.path;if(this.hasStroke()){var l=o.lineWidth,u=o.strokeNoScale?this.getLineScale():1;if(u>1e-10&&(this.hasFill()||(l=Math.max(l,this.strokeContainThreshold)),tw(s,l/u,e,i)))return!0}if(this.hasFill())return jS(s,e,i)}return!1},t.prototype.dirtyShape=function(){this.__dirty|=Zi,this._rect&&(this._rect=null),this._decalEl&&this._decalEl.dirtyShape(),this.markRedraw()},t.prototype.dirty=function(){this.dirtyStyle(),this.dirtyShape()},t.prototype.animateShape=function(e){return this.animate("shape",e)},t.prototype.updateDuringAnimation=function(e){e==="style"?this.dirtyStyle():e==="shape"?this.dirtyShape():this.markRedraw()},t.prototype.attrKV=function(e,i){e==="shape"?this.setShape(i):r.prototype.attrKV.call(this,e,i)},t.prototype.setShape=function(e,i){var n=this.shape;return n||(n=this.shape={}),typeof e=="string"?n[e]=i:O(n,e),this.dirtyShape(),this},t.prototype.shapeChanged=function(){return!!(this.__dirty&Zi)},t.prototype.createStyle=function(e){return Ls(Og,e)},t.prototype._innerSaveToNormal=function(e){r.prototype._innerSaveToNormal.call(this,e);var i=this._normalState;e.shape&&!i.shape&&(i.shape=O({},this.shape))},t.prototype._applyStateObj=function(e,i,n,a,o,s){r.prototype._applyStateObj.call(this,e,i,n,a,o,s);var l=!(i&&a),u;if(i&&i.shape?o?a?u=i.shape:(u=O({},n.shape),O(u,i.shape)):(u=O({},a?this.shape:n.shape),O(u,i.shape)):l&&(u=n.shape),u)if(o){this.shape=O({},this.shape);for(var f={},h=St(u),c=0;c<h.length;c++){var v=h[c];typeof u[v]=="object"?this.shape[v]=u[v]:f[v]=u[v]}this._transitionState(e,{shape:f},s)}else this.shape=u,this.dirtyShape()},t.prototype._mergeStates=function(e){for(var i=r.prototype._mergeStates.call(this,e),n,a=0;a<e.length;a++){var o=e[a];o.shape&&(n=n||{},this._mergeStyle(n,o.shape))}return n&&(i.shape=n),i},t.prototype.getAnimationStyleProps=function(){return ew},t.prototype.isZeroArea=function(){return!1},t.extend=function(e){var i=(function(a){B(o,a);function o(s){var l=a.call(this,s)||this;return e.init&&e.init.call(l,s),l}return o.prototype.getDefaultStyle=function(){return it(e.style)},o.prototype.getDefaultShape=function(){return it(e.shape)},o})(t);for(var n in e)typeof e[n]=="function"&&(i.prototype[n]=e[n]);return i},t.initDefaultProps=(function(){var e=t.prototype;e.type="path",e.strokeContainThreshold=5,e.segmentIgnoreThreshold=0,e.subPixelOptimize=!1,e.autoBatch=!1,e.__dirty=ie|Hn|Zi})(),t})(Ea),rw=ht({strokeFirst:!0,font:Mr,x:0,y:0,textAlign:"left",textBaseline:"top",miterLimit:2},Og),es=(function(r){B(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t.prototype.hasStroke=function(){return Eg(this.style)},t.prototype.hasFill=function(){var e=this.style,i=e.fill;return i!=null&&i!=="none"},t.prototype.createStyle=function(e){return Ls(rw,e)},t.prototype.setBoundingRect=function(e){this._rect=e},t.prototype.getBoundingRect=function(){return this._rect||(this._rect=NS(this.style)),this._rect},t.initDefaultProps=(function(){var e=t.prototype;e.dirtyRectTolerance=10})(),t})(Ea);es.prototype.type="tspan";var iw=ht({x:0,y:0},gi),nw={style:ht({x:!0,y:!0,width:!0,height:!0,sx:!0,sy:!0,sWidth:!0,sHeight:!0},ks.style)};function aw(r){return!!(r&&typeof r!="string"&&r.width&&r.height)}var Er=(function(r){B(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t.prototype.createStyle=function(e){return Ls(iw,e)},t.prototype._getSize=function(e){var i=this.style,n=i[e];if(n!=null)return n;var a=aw(i.image)?i.image:this.__image;if(!a)return 0;var o=e==="width"?"height":"width",s=i[o];return s==null?a[e]:a[e]/a[o]*s},t.prototype.getWidth=function(){return this._getSize("width")},t.prototype.getHeight=function(){return this._getSize("height")},t.prototype.getAnimationStyleProps=function(){return nw},t.prototype.getBoundingRect=function(){var e=this.style;return this._rect||(this._rect=new rt(e.x||0,e.y||0,this.getWidth(),this.getHeight())),this._rect},t})(Ea);Er.prototype.type="image";function ow(r,t){var e=t.x,i=t.y,n=t.width,a=t.height,o=t.r,s,l,u,f;n<0&&(e=e+n,n=-n),a<0&&(i=i+a,a=-a),typeof o=="number"?s=l=u=f=o:o instanceof Array?o.length===1?s=l=u=f=o[0]:o.length===2?(s=u=o[0],l=f=o[1]):o.length===3?(s=o[0],l=f=o[1],u=o[2]):(s=o[0],l=o[1],u=o[2],f=o[3]):s=l=u=f=0;var h;s+l>n&&(h=s+l,s*=n/h,l*=n/h),u+f>n&&(h=u+f,u*=n/h,f*=n/h),l+u>a&&(h=l+u,l*=a/h,u*=a/h),s+f>a&&(h=s+f,s*=a/h,f*=a/h),r.moveTo(e+s,i),r.lineTo(e+n-l,i),l!==0&&r.arc(e+n-l,i+l,l,-Math.PI/2,0),r.lineTo(e+n,i+a-u),u!==0&&r.arc(e+n-u,i+a-u,u,0,Math.PI/2),r.lineTo(e+f,i+a),f!==0&&r.arc(e+f,i+a-f,f,Math.PI/2,Math.PI),r.lineTo(e,i+s),s!==0&&r.arc(e+s,i+s,s,Math.PI,Math.PI*1.5)}var Ji=Math.round;function Bg(r,t,e){if(t){var i=t.x1,n=t.x2,a=t.y1,o=t.y2;r.x1=i,r.x2=n,r.y1=a,r.y2=o;var s=e&&e.lineWidth;return s&&(Ji(i*2)===Ji(n*2)&&(r.x1=r.x2=hi(i,s,!0)),Ji(a*2)===Ji(o*2)&&(r.y1=r.y2=hi(a,s,!0))),r}}function Ng(r,t,e){if(t){var i=t.x,n=t.y,a=t.width,o=t.height;r.x=i,r.y=n,r.width=a,r.height=o;var s=e&&e.lineWidth;return s&&(r.x=hi(i,s,!0),r.y=hi(n,s,!0),r.width=Math.max(hi(i+a,s,!1)-r.x,a===0?0:1),r.height=Math.max(hi(n+o,s,!1)-r.y,o===0?0:1)),r}}function hi(r,t,e){if(!t)return r;var i=Ji(r*2);return(i+Ji(t))%2===0?i/2:(i+(e?1:-1))/2}var sw=(function(){function r(){this.x=0,this.y=0,this.width=0,this.height=0}return r})(),lw={},wt=(function(r){B(t,r);function t(e){return r.call(this,e)||this}return t.prototype.getDefaultShape=function(){return new sw},t.prototype.buildPath=function(e,i){var n,a,o,s;if(this.subPixelOptimize){var l=Ng(lw,i,this.style);n=l.x,a=l.y,o=l.width,s=l.height,l.r=i.r,i=l}else n=i.x,a=i.y,o=i.width,s=i.height;i.r?ow(e,i):e.rect(n,a,o,s)},t.prototype.isZeroArea=function(){return!this.shape.width||!this.shape.height},t})(dt);wt.prototype.type="rect";var Zv={fill:"#000"},Xv=2,Pe={},uw={style:ht({fill:!0,stroke:!0,fillOpacity:!0,strokeOpacity:!0,lineWidth:!0,fontSize:!0,lineHeight:!0,width:!0,height:!0,textShadowColor:!0,textShadowBlur:!0,textShadowOffsetX:!0,textShadowOffsetY:!0,backgroundColor:!0,padding:!0,borderColor:!0,borderWidth:!0,borderRadius:!0},ks.style)},Nt=(function(r){B(t,r);function t(e){var i=r.call(this)||this;return i.type="text",i._children=[],i._defaultStyle=Zv,i.attr(e),i}return t.prototype.childrenRef=function(){return this._children},t.prototype.update=function(){r.prototype.update.call(this),this.styleChanged()&&this._updateSubTexts();for(var e=0;e<this._children.length;e++){var i=this._children[e];i.zlevel=this.zlevel,i.z=this.z,i.z2=this.z2,i.culling=this.culling,i.cursor=this.cursor,i.invisible=this.invisible}},t.prototype.updateTransform=function(){var e=this.innerTransformable;e?(e.updateTransform(),e.transform&&(this.transform=e.transform)):r.prototype.updateTransform.call(this)},t.prototype.getLocalTransform=function(e){var i=this.innerTransformable;return i?i.getLocalTransform(e):r.prototype.getLocalTransform.call(this,e)},t.prototype.getComputedTransform=function(){return this.__hostTarget&&(this.__hostTarget.getComputedTransform(),this.__hostTarget.updateInnerText(!0)),r.prototype.getComputedTransform.call(this)},t.prototype._updateSubTexts=function(){this._childCursor=0,dw(this.style),this.style.rich?this._updateRichTexts():this._updatePlainTexts(),this._children.length=this._childCursor,this.styleUpdated()},t.prototype.addSelfToZr=function(e){r.prototype.addSelfToZr.call(this,e);for(var i=0;i<this._children.length;i++)this._children[i].__zr=e},t.prototype.removeSelfFromZr=function(e){r.prototype.removeSelfFromZr.call(this,e);for(var i=0;i<this._children.length;i++)this._children[i].__zr=null},t.prototype.getBoundingRect=function(){if(this.styleChanged()&&this._updateSubTexts(),!this._rect){for(var e=new rt(0,0,0,0),i=this._children,n=[],a=null,o=0;o<i.length;o++){var s=i[o],l=s.getBoundingRect(),u=s.getLocalTransform(n);u?(e.copy(l),e.applyTransform(u),a=a||e.clone(),a.union(e)):(a=a||l.clone(),a.union(l))}this._rect=a||e}return this._rect},t.prototype.setDefaultTextStyle=function(e){this._defaultStyle=e||Zv},t.prototype.setTextContent=function(e){},t.prototype._mergeStyle=function(e,i){if(!i)return e;var n=i.rich,a=e.rich||n&&{};return O(e,i),n&&a?(this._mergeRich(a,n),e.rich=a):a&&(e.rich=a),e},t.prototype._mergeRich=function(e,i){for(var n=St(i),a=0;a<n.length;a++){var o=n[a];e[o]=e[o]||{},O(e[o],i[o])}},t.prototype.getAnimationStyleProps=function(){return uw},t.prototype._getOrCreateChild=function(e){var i=this._children[this._childCursor];return(!i||!(i instanceof e))&&(i=new e),this._children[this._childCursor++]=i,i.__zr=this.__zr,i.parent=this,i},t.prototype._updatePlainTexts=function(){var e=this.style,i=e.font||Mr,n=e.padding,a=this._defaultStyle,o=e.x||0,s=e.y||0,l=e.align||a.align||"left",u=e.verticalAlign||a.verticalAlign||"top";Fv(Pe,a.overflowRect,o,s,l,u),o=Pe.baseX,s=Pe.baseY;var f=tc(e),h=IS(f,e,Pe.outerWidth,Pe.outerHeight),c=Ol(e),v=!!e.backgroundColor,d=h.outerHeight,g=h.outerWidth,m=h.lines,p=h.lineHeight;this.isTruncated=!!h.isTruncated;var y=o,_=pi(s,h.contentHeight,u);if(c||n){var S=ln(o,g,l),x=pi(s,d,u);c&&this._renderBackground(e,e,S,x,g,d)}_+=p/2,n&&(y=jv(o,l,n),u==="top"?_+=n[0]:u==="bottom"&&(_-=n[2]));for(var w=0,b=!1,D=!1,C=Jv("fill"in e?e.fill:(D=!0,a.fill)),M=Qv("stroke"in e?e.stroke:!v&&(!a.autoStroke||D)?(w=Xv,b=!0,a.stroke):null),A=e.textShadowBlur>0,P=0;P<m.length;P++){var L=this._getOrCreateChild(es),I=L.createStyle();L.useStyle(I),I.text=m[P],I.x=y,I.y=_,I.textAlign=l,I.textBaseline="middle",I.opacity=e.opacity,I.strokeFirst=!0,A&&(I.shadowBlur=e.textShadowBlur||0,I.shadowColor=e.textShadowColor||"transparent",I.shadowOffsetX=e.textShadowOffsetX||0,I.shadowOffsetY=e.textShadowOffsetY||0),I.stroke=M,I.fill=C,M&&(I.lineWidth=e.lineWidth||w,I.lineDash=e.lineDash,I.lineDashOffset=e.lineDashOffset||0),I.font=i,$v(I,e),_+=p,L.setBoundingRect($u(I,h.contentWidth,h.calculatedLineHeight,b?0:null))}},t.prototype._updateRichTexts=function(){var e=this.style,i=this._defaultStyle,n=e.align||i.align,a=e.verticalAlign||i.verticalAlign,o=e.x||0,s=e.y||0;Fv(Pe,i.overflowRect,o,s,n,a),o=Pe.baseX,s=Pe.baseY;var l=tc(e),u=ES(l,e,Pe.outerWidth,Pe.outerHeight,n),f=u.width,h=u.outerWidth,c=u.outerHeight,v=e.padding;this.isTruncated=!!u.isTruncated;var d=ln(o,h,n),g=pi(s,c,a),m=d,p=g;v&&(m+=v[3],p+=v[0]);var y=m+f;Ol(e)&&this._renderBackground(e,e,d,g,h,c);for(var _=!!e.backgroundColor,S=0;S<u.lines.length;S++){for(var x=u.lines[S],w=x.tokens,b=w.length,D=x.lineHeight,C=x.width,M=0,A=m,P=y,L=b-1,I=void 0;M<b&&(I=w[M],!I.align||I.align==="left");)this._placeToken(I,e,D,p,A,"left",_),C-=I.width,A+=I.width,M++;for(;L>=0&&(I=w[L],I.align==="right");)this._placeToken(I,e,D,p,P,"right",_),C-=I.width,P-=I.width,L--;for(A+=(f-(A-m)-(y-P)-C)/2;M<=L;)I=w[M],this._placeToken(I,e,D,p,A+I.width/2,"center",_),A+=I.width,M++;p+=D}},t.prototype._placeToken=function(e,i,n,a,o,s,l){var u=i.rich[e.styleName]||{};u.text=e.text;var f=e.verticalAlign,h=a+n/2;f==="top"?h=a+e.height/2:f==="bottom"&&(h=a+n-e.height/2);var c=!e.isLineHolder&&Ol(u);c&&this._renderBackground(u,i,s==="right"?o-e.width:s==="center"?o-e.width/2:o,h-e.height/2,e.width,e.height);var v=!!u.backgroundColor,d=e.textPadding;d&&(o=jv(o,s,d),h-=e.height/2-d[0]-e.innerHeight/2);var g=this._getOrCreateChild(es),m=g.createStyle();g.useStyle(m);var p=this._defaultStyle,y=!1,_=0,S=!1,x=Jv("fill"in u?u.fill:"fill"in i?i.fill:(y=!0,p.fill)),w=Qv("stroke"in u?u.stroke:"stroke"in i?i.stroke:!v&&!l&&(!p.autoStroke||y)?(_=Xv,S=!0,p.stroke):null),b=u.textShadowBlur>0||i.textShadowBlur>0;m.text=e.text,m.x=o,m.y=h,b&&(m.shadowBlur=u.textShadowBlur||i.textShadowBlur||0,m.shadowColor=u.textShadowColor||i.textShadowColor||"transparent",m.shadowOffsetX=u.textShadowOffsetX||i.textShadowOffsetX||0,m.shadowOffsetY=u.textShadowOffsetY||i.textShadowOffsetY||0),m.textAlign=s,m.textBaseline="middle",m.font=e.font||Mr,m.opacity=en(u.opacity,i.opacity,1),$v(m,u),w&&(m.lineWidth=en(u.lineWidth,i.lineWidth,_),m.lineDash=$(u.lineDash,i.lineDash),m.lineDashOffset=i.lineDashOffset||0,m.stroke=w),x&&(m.fill=x),g.setBoundingRect($u(m,e.contentWidth,e.contentHeight,S?0:null))},t.prototype._renderBackground=function(e,i,n,a,o,s){var l=e.backgroundColor,u=e.borderWidth,f=e.borderColor,h=l&&l.image,c=l&&!h,v=e.borderRadius,d=this,g,m;if(c||e.lineHeight||u&&f){g=this._getOrCreateChild(wt),g.useStyle(g.createStyle()),g.style.fill=null;var p=g.shape;p.x=n,p.y=a,p.width=o,p.height=s,p.r=v,g.dirtyShape()}if(c){var y=g.style;y.fill=l||null,y.fillOpacity=$(e.fillOpacity,1)}else if(h){m=this._getOrCreateChild(Er),m.onload=function(){d.dirtyStyle()};var _=m.style;_.image=l.image,_.x=n,_.y=a,_.width=o,_.height=s}if(u&&f){var y=g.style;y.lineWidth=u,y.stroke=f,y.strokeOpacity=$(e.strokeOpacity,1),y.lineDash=e.borderDash,y.lineDashOffset=e.borderDashOffset||0,g.strokeContainThreshold=0,g.hasFill()&&g.hasStroke()&&(y.strokeFirst=!0,y.lineWidth*=2)}var S=(g||m).style;S.shadowBlur=e.shadowBlur||0,S.shadowColor=e.shadowColor||"transparent",S.shadowOffsetX=e.shadowOffsetX||0,S.shadowOffsetY=e.shadowOffsetY||0,S.opacity=en(e.opacity,i.opacity,1)},t.makeFont=function(e){var i="";return cw(e)&&(i=[e.fontStyle,e.fontWeight,vw(e.fontSize),e.fontFamily||"sans-serif"].join(" ")),i&&ke(i)||e.textFont||e.font},t})(Ea),fw={left:!0,right:1,center:1},hw={top:1,bottom:1,middle:1},qv=["fontStyle","fontWeight","fontSize","fontFamily"];function vw(r){return typeof r=="string"&&(r.indexOf("px")!==-1||r.indexOf("rem")!==-1||r.indexOf("em")!==-1)?r:isNaN(+r)?Hf+"px":r+"px"}function $v(r,t){for(var e=0;e<qv.length;e++){var i=qv[e],n=t[i];n!=null&&(r[i]=n)}}function cw(r){return r.fontSize!=null||r.fontFamily||r.fontWeight}function dw(r){return Kv(r),T(r.rich,Kv),r}function Kv(r){if(r){r.font=Nt.makeFont(r);var t=r.align;t==="middle"&&(t="center"),r.align=t==null||fw[t]?t:"left";var e=r.verticalAlign;e==="center"&&(e="middle"),r.verticalAlign=e==null||hw[e]?e:"top";var i=r.padding;i&&(r.padding=Yf(r.padding))}}function Qv(r,t){return r==null||t<=0||r==="transparent"||r==="none"?null:r.image||r.colorStops?"#000":r}function Jv(r){return r==null||r==="none"?null:r.image||r.colorStops?"#000":r}function jv(r,t,e){return t==="right"?r-e[1]:t==="center"?r+e[3]/2-e[1]/2:r+e[3]}function tc(r){var t=r.text;return t!=null&&(t+=""),t}function Ol(r){return!!(r.backgroundColor||r.lineHeight||r.borderWidth&&r.borderColor)}var ft=yt(),pw=function(r,t,e,i){if(i){var n=ft(i);n.dataIndex=e,n.dataType=t,n.seriesIndex=r,n.ssrType="chart",i.type==="group"&&i.traverse(function(a){var o=ft(a);o.seriesIndex=r,o.dataIndex=e,o.dataType=t,o.ssrType="chart"})}},ec=1,rc={},Fg=yt(),rh=yt(),ih=0,Os=1,Bs=2,We=["emphasis","blur","select"],ic=["normal","emphasis","blur","select"],gw=10,mw=9,mi="highlight",Oo="downplay",rs="select",Ju="unselect",is="toggleSelect",nh="selectchanged";function Ei(r){return r!=null&&r!=="none"}function Ns(r,t,e){r.onHoverStateChange&&(r.hoverState||0)!==e&&r.onHoverStateChange(t),r.hoverState=e}function zg(r){Ns(r,"emphasis",Bs)}function Hg(r){r.hoverState===Bs&&Ns(r,"normal",ih)}function ah(r){Ns(r,"blur",Os)}function Gg(r){r.hoverState===Os&&Ns(r,"normal",ih)}function yw(r){r.selected=!0}function _w(r){r.selected=!1}function nc(r,t,e){t(r,e)}function or(r,t,e){nc(r,t,e),r.isGroup&&r.traverse(function(i){nc(i,t,e)})}function ac(r,t){switch(t){case"emphasis":r.hoverState=Bs;break;case"normal":r.hoverState=ih;break;case"blur":r.hoverState=Os;break;case"select":r.selected=!0}}function Sw(r,t,e,i){for(var n=r.style,a={},o=0;o<t.length;o++){var s=t[o],l=n[s];a[s]=l??(i&&i[s])}for(var o=0;o<r.animators.length;o++){var u=r.animators[o];u.__fromStateTransition&&u.__fromStateTransition.indexOf(e)<0&&u.targetName==="style"&&u.saveTo(a,t)}return a}function ww(r,t,e,i){var n=e&&at(e,"select")>=0,a=!1;if(r instanceof dt){var o=Fg(r),s=n&&o.selectFill||o.normalFill,l=n&&o.selectStroke||o.normalStroke;if(Ei(s)||Ei(l)){i=i||{};var u=i.style||{};u.fill==="inherit"?(a=!0,i=O({},i),u=O({},u),u.fill=s):!Ei(u.fill)&&Ei(s)?(a=!0,i=O({},i),u=O({},u),u.fill=_v(s)):!Ei(u.stroke)&&Ei(l)&&(a||(i=O({},i),u=O({},u)),u.stroke=_v(l)),i.style=u}}if(i&&i.z2==null){a||(i=O({},i));var f=r.z2EmphasisLift;i.z2=r.z2+(f??gw)}return i}function xw(r,t,e){if(e&&e.z2==null){e=O({},e);var i=r.z2SelectLift;e.z2=r.z2+(i??mw)}return e}function bw(r,t,e){var i=at(r.currentStates,t)>=0,n=r.style.opacity,a=i?null:Sw(r,["opacity"],t,{opacity:1});e=e||{};var o=e.style||{};return o.opacity==null&&(e=O({},e),o=O({opacity:i?n:a.opacity*.1},o),e.style=o),e}function Bl(r,t){var e=this.states[r];if(this.style){if(r==="emphasis")return ww(this,r,t,e);if(r==="blur")return bw(this,r,e);if(r==="select")return xw(this,r,e)}return e}function Tw(r){r.stateProxy=Bl;var t=r.getTextContent(),e=r.getTextGuideLine();t&&(t.stateProxy=Bl),e&&(e.stateProxy=Bl)}function oc(r,t){!Yg(r,t)&&!r.__highByOuter&&or(r,zg)}function sc(r,t){!Yg(r,t)&&!r.__highByOuter&&or(r,Hg)}function ns(r,t){r.__highByOuter|=1<<(t||0),or(r,zg)}function as(r,t){!(r.__highByOuter&=~(1<<(t||0)))&&or(r,Hg)}function Cw(r){or(r,ah)}function Vg(r){or(r,Gg)}function Wg(r){or(r,yw)}function Ug(r){or(r,_w)}function Yg(r,t){return r.__highDownSilentOnTouch&&t.zrByTouch}function Zg(r){var t=r.getModel(),e=[],i=[];t.eachComponent(function(n,a){var o=rh(a),s=n==="series",l=s?r.getViewOfSeriesModel(a):r.getViewOfComponentModel(a);!s&&i.push(l),o.isBlured&&(l.group.traverse(function(u){Gg(u)}),s&&e.push(a)),o.isBlured=!1}),T(i,function(n){n&&n.toggleBlurSeries&&n.toggleBlurSeries(e,!1,t)})}function ju(r,t,e,i){var n=i.getModel();e=e||"coordinateSystem";function a(u,f){for(var h=0;h<f.length;h++){var c=u.getItemGraphicEl(f[h]);c&&Vg(c)}}if(r!=null&&!(!t||t==="none")){var o=n.getSeriesByIndex(r),s=o.coordinateSystem;s&&s.master&&(s=s.master);var l=[];n.eachSeries(function(u){var f=o===u,h=u.coordinateSystem;h&&h.master&&(h=h.master);var c=h&&s?h===s:f;if(!(e==="series"&&!f||e==="coordinateSystem"&&!c||t==="series"&&f)){var v=i.getViewOfSeriesModel(u);if(v.group.traverse(function(m){m.__highByOuter&&f&&t==="self"||ah(m)}),Jt(t))a(u.getData(),t);else if(Z(t))for(var d=St(t),g=0;g<d.length;g++)a(u.getData(d[g]),t[d[g]]);l.push(u),rh(u).isBlured=!0}}),n.eachComponent(function(u,f){if(u!=="series"){var h=i.getViewOfComponentModel(f);h&&h.toggleBlurSeries&&h.toggleBlurSeries(l,!0,n)}})}}function tf(r,t,e){if(!(r==null||t==null)){var i=e.getModel().getComponent(r,t);if(i){rh(i).isBlured=!0;var n=e.getViewOfComponentModel(i);!n||!n.focusBlurEnabled||n.group.traverse(function(a){ah(a)})}}}function Mw(r,t,e){var i=r.seriesIndex,n=r.getData(t.dataType);if(n){var a=wi(n,t);a=(V(a)?a[0]:a)||0;var o=n.getItemGraphicEl(a);if(!o)for(var s=n.count(),l=0;!o&&l<s;)o=n.getItemGraphicEl(l++);if(o){var u=ft(o);ju(i,u.focus,u.blurScope,e)}else{var f=r.get(["emphasis","focus"]),h=r.get(["emphasis","blurScope"]);f!=null&&ju(i,f,h,e)}}}function oh(r,t,e,i){var n={focusSelf:!1,dispatchers:null};if(r==null||r==="series"||t==null||e==null)return n;var a=i.getModel().getComponent(r,t);if(!a)return n;var o=i.getViewOfComponentModel(a);if(!o||!o.findHighDownDispatchers)return n;for(var s=o.findHighDownDispatchers(e),l,u=0;u<s.length;u++)if(ft(s[u]).focus==="self"){l=!0;break}return{focusSelf:l,dispatchers:s}}function Dw(r,t,e){var i=ft(r),n=oh(i.componentMainType,i.componentIndex,i.componentHighDownName,e),a=n.dispatchers,o=n.focusSelf;a?(o&&tf(i.componentMainType,i.componentIndex,e),T(a,function(s){return oc(s,t)})):(ju(i.seriesIndex,i.focus,i.blurScope,e),i.focus==="self"&&tf(i.componentMainType,i.componentIndex,e),oc(r,t))}function Aw(r,t,e){Zg(e);var i=ft(r),n=oh(i.componentMainType,i.componentIndex,i.componentHighDownName,e).dispatchers;n?T(n,function(a){return sc(a,t)}):sc(r,t)}function Lw(r,t,e){if(nf(t)){var i=t.dataType,n=r.getData(i),a=wi(n,t);V(a)||(a=[a]),r[t.type===is?"toggleSelect":t.type===rs?"select":"unselect"](a,i)}}function lc(r){var t=r.getAllData();T(t,function(e){var i=e.data,n=e.type;i.eachItemGraphicEl(function(a,o){r.isSelected(o,n)?Wg(a):Ug(a)})})}function Iw(r){var t=[];return r.eachSeries(function(e){var i=e.getAllData();T(i,function(n){n.data;var a=n.type,o=e.getSelectedDataIndices();if(o.length>0){var s={dataIndex:o,seriesIndex:e.seriesIndex};a!=null&&(s.dataType=a),t.push(s)}})}),t}function os(r,t,e){Xg(r,!0),or(r,Tw),Rw(r,t,e)}function Pw(r){Xg(r,!1)}function ef(r,t,e,i){i?Pw(r):os(r,t,e)}function Rw(r,t,e){var i=ft(r);t!=null?(i.focus=t,i.blurScope=e):i.focus&&(i.focus=null)}var uc=["emphasis","blur","select"],Ew={itemStyle:"getItemStyle",lineStyle:"getLineStyle",areaStyle:"getAreaStyle"};function fc(r,t,e,i){e=e||"itemStyle";for(var n=0;n<uc.length;n++){var a=uc[n],o=t.getModel([a,e]),s=r.ensureState(a);s.style=o[Ew[e]]()}}function Xg(r,t){var e=t===!1,i=r;r.highDownSilentOnTouch&&(i.__highDownSilentOnTouch=r.highDownSilentOnTouch),(!e||i.__highDownDispatcher)&&(i.__highByOuter=i.__highByOuter||0,i.__highDownDispatcher=!e)}function rf(r){return!!(r&&r.__highDownDispatcher)}function kw(r){var t=rc[r];return t==null&&ec<=32&&(t=rc[r]=ec++),t}function nf(r){var t=r.type;return t===rs||t===Ju||t===is}function hc(r){var t=r.type;return t===mi||t===Oo}function Ow(r){var t=Fg(r);t.normalFill=r.style.fill,t.normalStroke=r.style.stroke;var e=r.states.select||{};t.selectFill=e.style&&e.style.fill||null,t.selectStroke=e.style&&e.style.stroke||null}var ki=xi.CMD,Bw=[[],[],[]],vc=Math.sqrt,Nw=Math.atan2;function Fw(r,t){if(t){var e=r.data,i=r.len(),n,a,o,s,l,u,f=ki.M,h=ki.C,c=ki.L,v=ki.R,d=ki.A,g=ki.Q;for(o=0,s=0;o<i;){switch(n=e[o++],s=o,a=0,n){case f:a=1;break;case c:a=1;break;case h:a=3;break;case g:a=2;break;case d:var m=t[4],p=t[5],y=vc(t[0]*t[0]+t[1]*t[1]),_=vc(t[2]*t[2]+t[3]*t[3]),S=Nw(-t[1]/_,t[0]/y);e[o]*=y,e[o++]+=m,e[o]*=_,e[o++]+=p,e[o++]*=y,e[o++]*=_,e[o++]+=S,e[o++]+=S,o+=2,s=o;break;case v:u[0]=e[o++],u[1]=e[o++],ge(u,u,t),e[s++]=u[0],e[s++]=u[1],u[0]+=e[o++],u[1]+=e[o++],ge(u,u,t),e[s++]=u[0],e[s++]=u[1]}for(l=0;l<a;l++){var x=Bw[l];x[0]=e[o++],x[1]=e[o++],ge(x,x,t),e[s++]=x[0],e[s++]=x[1]}}r.increaseVersion()}}var Nl=Math.sqrt,to=Math.sin,eo=Math.cos,wn=Math.PI;function cc(r){return Math.sqrt(r[0]*r[0]+r[1]*r[1])}function af(r,t){return(r[0]*t[0]+r[1]*t[1])/(cc(r)*cc(t))}function dc(r,t){return(r[0]*t[1]<r[1]*t[0]?-1:1)*Math.acos(af(r,t))}function pc(r,t,e,i,n,a,o,s,l,u,f){var h=l*(wn/180),c=eo(h)*(r-e)/2+to(h)*(t-i)/2,v=-1*to(h)*(r-e)/2+eo(h)*(t-i)/2,d=c*c/(o*o)+v*v/(s*s);d>1&&(o*=Nl(d),s*=Nl(d));var g=(n===a?-1:1)*Nl((o*o*(s*s)-o*o*(v*v)-s*s*(c*c))/(o*o*(v*v)+s*s*(c*c)))||0,m=g*o*v/s,p=g*-s*c/o,y=(r+e)/2+eo(h)*m-to(h)*p,_=(t+i)/2+to(h)*m+eo(h)*p,S=dc([1,0],[(c-m)/o,(v-p)/s]),x=[(c-m)/o,(v-p)/s],w=[(-1*c-m)/o,(-1*v-p)/s],b=dc(x,w);if(af(x,w)<=-1&&(b=wn),af(x,w)>=1&&(b=0),b<0){var D=Math.round(b/wn*1e6)/1e6;b=wn*2+D%2*wn}f.addData(u,y,_,o,s,S,b,h,a)}var zw=/([mlvhzcqtsa])([^mlvhzcqtsa]*)/ig,Hw=/-?([0-9]*\.)?[0-9]+([eE]-?[0-9]+)?/g;function Gw(r){var t=new xi;if(!r)return t;var e=0,i=0,n=e,a=i,o,s=xi.CMD,l=r.match(zw);if(!l)return t;for(var u=0;u<l.length;u++){for(var f=l[u],h=f.charAt(0),c=void 0,v=f.match(Hw)||[],d=v.length,g=0;g<d;g++)v[g]=parseFloat(v[g]);for(var m=0;m<d;){var p=void 0,y=void 0,_=void 0,S=void 0,x=void 0,w=void 0,b=void 0,D=e,C=i,M=void 0,A=void 0;switch(h){case"l":e+=v[m++],i+=v[m++],c=s.L,t.addData(c,e,i);break;case"L":e=v[m++],i=v[m++],c=s.L,t.addData(c,e,i);break;case"m":e+=v[m++],i+=v[m++],c=s.M,t.addData(c,e,i),n=e,a=i,h="l";break;case"M":e=v[m++],i=v[m++],c=s.M,t.addData(c,e,i),n=e,a=i,h="L";break;case"h":e+=v[m++],c=s.L,t.addData(c,e,i);break;case"H":e=v[m++],c=s.L,t.addData(c,e,i);break;case"v":i+=v[m++],c=s.L,t.addData(c,e,i);break;case"V":i=v[m++],c=s.L,t.addData(c,e,i);break;case"C":c=s.C,t.addData(c,v[m++],v[m++],v[m++],v[m++],v[m++],v[m++]),e=v[m-2],i=v[m-1];break;case"c":c=s.C,t.addData(c,v[m++]+e,v[m++]+i,v[m++]+e,v[m++]+i,v[m++]+e,v[m++]+i),e+=v[m-2],i+=v[m-1];break;case"S":p=e,y=i,M=t.len(),A=t.data,o===s.C&&(p+=e-A[M-4],y+=i-A[M-3]),c=s.C,D=v[m++],C=v[m++],e=v[m++],i=v[m++],t.addData(c,p,y,D,C,e,i);break;case"s":p=e,y=i,M=t.len(),A=t.data,o===s.C&&(p+=e-A[M-4],y+=i-A[M-3]),c=s.C,D=e+v[m++],C=i+v[m++],e+=v[m++],i+=v[m++],t.addData(c,p,y,D,C,e,i);break;case"Q":D=v[m++],C=v[m++],e=v[m++],i=v[m++],c=s.Q,t.addData(c,D,C,e,i);break;case"q":D=v[m++]+e,C=v[m++]+i,e+=v[m++],i+=v[m++],c=s.Q,t.addData(c,D,C,e,i);break;case"T":p=e,y=i,M=t.len(),A=t.data,o===s.Q&&(p+=e-A[M-4],y+=i-A[M-3]),e=v[m++],i=v[m++],c=s.Q,t.addData(c,p,y,e,i);break;case"t":p=e,y=i,M=t.len(),A=t.data,o===s.Q&&(p+=e-A[M-4],y+=i-A[M-3]),e+=v[m++],i+=v[m++],c=s.Q,t.addData(c,p,y,e,i);break;case"A":_=v[m++],S=v[m++],x=v[m++],w=v[m++],b=v[m++],D=e,C=i,e=v[m++],i=v[m++],c=s.A,pc(D,C,e,i,w,b,_,S,x,c,t);break;case"a":_=v[m++],S=v[m++],x=v[m++],w=v[m++],b=v[m++],D=e,C=i,e+=v[m++],i+=v[m++],c=s.A,pc(D,C,e,i,w,b,_,S,x,c,t);break}}(h==="z"||h==="Z")&&(c=s.Z,t.addData(c),e=n,i=a),o=c}return t.toStatic(),t}var qg=(function(r){B(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t.prototype.applyTransform=function(e){},t})(dt);function $g(r){return r.setData!=null}function Kg(r,t){var e=Gw(r),i=O({},t);return i.buildPath=function(n){var a=$g(n);if(a&&n.canSave()){n.appendPath(e);var o=n.getContext();o&&n.rebuildPath(o,1)}else{var o=a?n.getContext():n;o&&e.rebuildPath(o,1)}},i.applyTransform=function(n){Fw(e,n),this.dirtyShape()},i}function Vw(r,t){return new qg(Kg(r,t))}function Ww(r,t){var e=Kg(r,t),i=(function(n){B(a,n);function a(o){var s=n.call(this,o)||this;return s.applyTransform=e.applyTransform,s.buildPath=e.buildPath,s}return a})(qg);return i}function Uw(r,t){for(var e=[],i=r.length,n=0;n<i;n++){var a=r[n];e.push(a.getUpdatedPathProxy(!0))}var o=new dt(t);return o.createPathProxy(),o.buildPath=function(s){if($g(s)){s.appendPath(e);var l=s.getContext();l&&s.rebuildPath(l,1)}},o}var Yw=(function(){function r(){this.cx=0,this.cy=0,this.r=0}return r})(),Fs=(function(r){B(t,r);function t(e){return r.call(this,e)||this}return t.prototype.getDefaultShape=function(){return new Yw},t.prototype.buildPath=function(e,i){e.moveTo(i.cx+i.r,i.cy),e.arc(i.cx,i.cy,i.r,0,Math.PI*2)},t})(dt);Fs.prototype.type="circle";var Zw=(function(){function r(){this.cx=0,this.cy=0,this.rx=0,this.ry=0}return r})(),sh=(function(r){B(t,r);function t(e){return r.call(this,e)||this}return t.prototype.getDefaultShape=function(){return new Zw},t.prototype.buildPath=function(e,i){var n=.5522848,a=i.cx,o=i.cy,s=i.rx,l=i.ry,u=s*n,f=l*n;e.moveTo(a-s,o),e.bezierCurveTo(a-s,o-f,a-u,o-l,a,o-l),e.bezierCurveTo(a+u,o-l,a+s,o-f,a+s,o),e.bezierCurveTo(a+s,o+f,a+u,o+l,a,o+l),e.bezierCurveTo(a-u,o+l,a-s,o+f,a-s,o),e.closePath()},t})(dt);sh.prototype.type="ellipse";var Qg=Math.PI,Fl=Qg*2,Qr=Math.sin,Oi=Math.cos,Xw=Math.acos,Ft=Math.atan2,gc=Math.abs,Jn=Math.sqrt,Wn=Math.max,Re=Math.min,_e=1e-4;function qw(r,t,e,i,n,a,o,s){var l=e-r,u=i-t,f=o-n,h=s-a,c=h*l-f*u;if(!(c*c<_e))return c=(f*(t-a)-h*(r-n))/c,[r+c*l,t+c*u]}function ro(r,t,e,i,n,a,o){var s=r-e,l=t-i,u=(o?a:-a)/Jn(s*s+l*l),f=u*l,h=-u*s,c=r+f,v=t+h,d=e+f,g=i+h,m=(c+d)/2,p=(v+g)/2,y=d-c,_=g-v,S=y*y+_*_,x=n-a,w=c*g-d*v,b=(_<0?-1:1)*Jn(Wn(0,x*x*S-w*w)),D=(w*_-y*b)/S,C=(-w*y-_*b)/S,M=(w*_+y*b)/S,A=(-w*y+_*b)/S,P=D-m,L=C-p,I=M-m,E=A-p;return P*P+L*L>I*I+E*E&&(D=M,C=A),{cx:D,cy:C,x0:-f,y0:-h,x1:D*(n/x-1),y1:C*(n/x-1)}}function $w(r){var t;if(V(r)){var e=r.length;if(!e)return r;e===1?t=[r[0],r[0],0,0]:e===2?t=[r[0],r[0],r[1],r[1]]:e===3?t=r.concat(r[2]):t=r}else t=[r,r,r,r];return t}function Kw(r,t){var e,i=Wn(t.r,0),n=Wn(t.r0||0,0),a=i>0,o=n>0;if(!(!a&&!o)){if(a||(i=n,n=0),n>i){var s=i;i=n,n=s}var l=t.startAngle,u=t.endAngle;if(!(isNaN(l)||isNaN(u))){var f=t.cx,h=t.cy,c=!!t.clockwise,v=gc(u-l),d=v>Fl&&v%Fl;if(d>_e&&(v=d),!(i>_e))r.moveTo(f,h);else if(v>Fl-_e)r.moveTo(f+i*Oi(l),h+i*Qr(l)),r.arc(f,h,i,l,u,!c),n>_e&&(r.moveTo(f+n*Oi(u),h+n*Qr(u)),r.arc(f,h,n,u,l,c));else{var g=void 0,m=void 0,p=void 0,y=void 0,_=void 0,S=void 0,x=void 0,w=void 0,b=void 0,D=void 0,C=void 0,M=void 0,A=void 0,P=void 0,L=void 0,I=void 0,E=i*Oi(l),k=i*Qr(l),U=n*Oi(u),z=n*Qr(u),R=v>_e;if(R){var F=t.cornerRadius;F&&(e=$w(F),g=e[0],m=e[1],p=e[2],y=e[3]);var G=gc(i-n)/2;if(_=Re(G,p),S=Re(G,y),x=Re(G,g),w=Re(G,m),C=b=Wn(_,S),M=D=Wn(x,w),(b>_e||D>_e)&&(A=i*Oi(u),P=i*Qr(u),L=n*Oi(l),I=n*Qr(l),v<Qg)){var X=qw(E,k,L,I,A,P,U,z);if(X){var tt=E-X[0],ot=k-X[1],_t=A-X[0],Zt=P-X[1],De=1/Qr(Xw((tt*_t+ot*Zt)/(Jn(tt*tt+ot*ot)*Jn(_t*_t+Zt*Zt)))/2),Xe=Jn(X[0]*X[0]+X[1]*X[1]);C=Re(b,(i-Xe)/(De+1)),M=Re(D,(n-Xe)/(De-1))}}}if(!R)r.moveTo(f+E,h+k);else if(C>_e){var te=Re(p,C),Et=Re(y,C),et=ro(L,I,E,k,i,te,c),nt=ro(A,P,U,z,i,Et,c);r.moveTo(f+et.cx+et.x0,h+et.cy+et.y0),C<b&&te===Et?r.arc(f+et.cx,h+et.cy,C,Ft(et.y0,et.x0),Ft(nt.y0,nt.x0),!c):(te>0&&r.arc(f+et.cx,h+et.cy,te,Ft(et.y0,et.x0),Ft(et.y1,et.x1),!c),r.arc(f,h,i,Ft(et.cy+et.y1,et.cx+et.x1),Ft(nt.cy+nt.y1,nt.cx+nt.x1),!c),Et>0&&r.arc(f+nt.cx,h+nt.cy,Et,Ft(nt.y1,nt.x1),Ft(nt.y0,nt.x0),!c))}else r.moveTo(f+E,h+k),r.arc(f,h,i,l,u,!c);if(!(n>_e)||!R)r.lineTo(f+U,h+z);else if(M>_e){var te=Re(g,M),Et=Re(m,M),et=ro(U,z,A,P,n,-Et,c),nt=ro(E,k,L,I,n,-te,c);r.lineTo(f+et.cx+et.x0,h+et.cy+et.y0),M<D&&te===Et?r.arc(f+et.cx,h+et.cy,M,Ft(et.y0,et.x0),Ft(nt.y0,nt.x0),!c):(Et>0&&r.arc(f+et.cx,h+et.cy,Et,Ft(et.y0,et.x0),Ft(et.y1,et.x1),!c),r.arc(f,h,n,Ft(et.cy+et.y1,et.cx+et.x1),Ft(nt.cy+nt.y1,nt.cx+nt.x1),c),te>0&&r.arc(f+nt.cx,h+nt.cy,te,Ft(nt.y1,nt.x1),Ft(nt.y0,nt.x0),!c))}else r.lineTo(f+U,h+z),r.arc(f,h,n,u,l,c)}r.closePath()}}}var Qw=(function(){function r(){this.cx=0,this.cy=0,this.r0=0,this.r=0,this.startAngle=0,this.endAngle=Math.PI*2,this.clockwise=!0,this.cornerRadius=0}return r})(),zs=(function(r){B(t,r);function t(e){return r.call(this,e)||this}return t.prototype.getDefaultShape=function(){return new Qw},t.prototype.buildPath=function(e,i){Kw(e,i)},t.prototype.isZeroArea=function(){return this.shape.startAngle===this.shape.endAngle||this.shape.r===this.shape.r0},t})(dt);zs.prototype.type="sector";var Jw=(function(){function r(){this.cx=0,this.cy=0,this.r=0,this.r0=0}return r})(),lh=(function(r){B(t,r);function t(e){return r.call(this,e)||this}return t.prototype.getDefaultShape=function(){return new Jw},t.prototype.buildPath=function(e,i){var n=i.cx,a=i.cy,o=Math.PI*2;e.moveTo(n+i.r,a),e.arc(n,a,i.r,0,o,!1),e.moveTo(n+i.r0,a),e.arc(n,a,i.r0,0,o,!0)},t})(dt);lh.prototype.type="ring";function jw(r,t,e,i){var n=[],a=[],o=[],s=[],l,u,f,h;if(i){f=[1/0,1/0],h=[-1/0,-1/0];for(var c=0,v=r.length;c<v;c++)qi(f,f,r[c]),$i(h,h,r[c]);qi(f,f,i[0]),$i(h,h,i[1])}for(var c=0,v=r.length;c<v;c++){var d=r[c];if(e)l=r[c?c-1:v-1],u=r[(c+1)%v];else if(c===0||c===v-1){n.push(M_(r[c]));continue}else l=r[c-1],u=r[c+1];D_(a,u,l),el(a,a,t);var g=Du(d,l),m=Du(d,u),p=g+m;p!==0&&(g/=p,m/=p),el(o,a,-g),el(s,a,m);var y=ev([],d,o),_=ev([],d,s);i&&($i(y,y,f),qi(y,y,h),$i(_,_,f),qi(_,_,h)),n.push(y),n.push(_)}return e&&n.push(n.shift()),n}function Jg(r,t,e){var i=t.smooth,n=t.points;if(n&&n.length>=2){if(i){var a=jw(n,i,e,t.smoothConstraint);r.moveTo(n[0][0],n[0][1]);for(var o=n.length,s=0;s<(e?o:o-1);s++){var l=a[s*2],u=a[s*2+1],f=n[(s+1)%o];r.bezierCurveTo(l[0],l[1],u[0],u[1],f[0],f[1])}}else{r.moveTo(n[0][0],n[0][1]);for(var s=1,h=n.length;s<h;s++)r.lineTo(n[s][0],n[s][1])}e&&r.closePath()}}var tx=(function(){function r(){this.points=null,this.smooth=0,this.smoothConstraint=null}return r})(),Hs=(function(r){B(t,r);function t(e){return r.call(this,e)||this}return t.prototype.getDefaultShape=function(){return new tx},t.prototype.buildPath=function(e,i){Jg(e,i,!0)},t})(dt);Hs.prototype.type="polygon";var ex=(function(){function r(){this.points=null,this.percent=1,this.smooth=0,this.smoothConstraint=null}return r})(),Gs=(function(r){B(t,r);function t(e){return r.call(this,e)||this}return t.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},t.prototype.getDefaultShape=function(){return new ex},t.prototype.buildPath=function(e,i){Jg(e,i,!1)},t})(dt);Gs.prototype.type="polyline";var rx={},ix=(function(){function r(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.percent=1}return r})(),Dr=(function(r){B(t,r);function t(e){return r.call(this,e)||this}return t.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},t.prototype.getDefaultShape=function(){return new ix},t.prototype.buildPath=function(e,i){var n,a,o,s;if(this.subPixelOptimize){var l=Bg(rx,i,this.style);n=l.x1,a=l.y1,o=l.x2,s=l.y2}else n=i.x1,a=i.y1,o=i.x2,s=i.y2;var u=i.percent;u!==0&&(e.moveTo(n,a),u<1&&(o=n*(1-u)+o*u,s=a*(1-u)+s*u),e.lineTo(o,s))},t.prototype.pointAt=function(e){var i=this.shape;return[i.x1*(1-e)+i.x2*e,i.y1*(1-e)+i.y2*e]},t})(dt);Dr.prototype.type="line";var Xt=[],nx=(function(){function r(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.cpx1=0,this.cpy1=0,this.percent=1}return r})();function mc(r,t,e){var i=r.cpx2,n=r.cpy2;return i!=null||n!=null?[(e?dv:kt)(r.x1,r.cpx1,r.cpx2,r.x2,t),(e?dv:kt)(r.y1,r.cpy1,r.cpy2,r.y2,t)]:[(e?pv:$t)(r.x1,r.cpx1,r.x2,t),(e?pv:$t)(r.y1,r.cpy1,r.y2,t)]}var uh=(function(r){B(t,r);function t(e){return r.call(this,e)||this}return t.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},t.prototype.getDefaultShape=function(){return new nx},t.prototype.buildPath=function(e,i){var n=i.x1,a=i.y1,o=i.x2,s=i.y2,l=i.cpx1,u=i.cpy1,f=i.cpx2,h=i.cpy2,c=i.percent;c!==0&&(e.moveTo(n,a),f==null||h==null?(c<1&&(Ko(n,l,o,c,Xt),l=Xt[1],o=Xt[2],Ko(a,u,s,c,Xt),u=Xt[1],s=Xt[2]),e.quadraticCurveTo(l,u,o,s)):(c<1&&($o(n,l,f,o,c,Xt),l=Xt[1],f=Xt[2],o=Xt[3],$o(a,u,h,s,c,Xt),u=Xt[1],h=Xt[2],s=Xt[3]),e.bezierCurveTo(l,u,f,h,o,s)))},t.prototype.pointAt=function(e){return mc(this.shape,e,!1)},t.prototype.tangentAt=function(e){var i=mc(this.shape,e,!0);return I_(i,i)},t})(dt);uh.prototype.type="bezier-curve";var ax=(function(){function r(){this.cx=0,this.cy=0,this.r=0,this.startAngle=0,this.endAngle=Math.PI*2,this.clockwise=!0}return r})(),Vs=(function(r){B(t,r);function t(e){return r.call(this,e)||this}return t.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},t.prototype.getDefaultShape=function(){return new ax},t.prototype.buildPath=function(e,i){var n=i.cx,a=i.cy,o=Math.max(i.r,0),s=i.startAngle,l=i.endAngle,u=i.clockwise,f=Math.cos(s),h=Math.sin(s);e.moveTo(f*o+n,h*o+a),e.arc(n,a,o,s,l,!u)},t})(dt);Vs.prototype.type="arc";var ox=(function(r){B(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type="compound",e}return t.prototype._updatePathDirty=function(){for(var e=this.shape.paths,i=this.shapeChanged(),n=0;n<e.length;n++)i=i||e[n].shapeChanged();i&&this.dirtyShape()},t.prototype.beforeBrush=function(){this._updatePathDirty();for(var e=this.shape.paths||[],i=this.getGlobalScale(),n=0;n<e.length;n++)e[n].path||e[n].createPathProxy(),e[n].path.setScale(i[0],i[1],e[n].segmentIgnoreThreshold)},t.prototype.buildPath=function(e,i){for(var n=i.paths||[],a=0;a<n.length;a++)n[a].buildPath(e,n[a].shape,!0)},t.prototype.afterBrush=function(){for(var e=this.shape.paths||[],i=0;i<e.length;i++)e[i].pathUpdated()},t.prototype.getBoundingRect=function(){return this._updatePathDirty.call(this),dt.prototype.getBoundingRect.call(this)},t})(dt),jg=(function(){function r(t){this.colorStops=t||[]}return r.prototype.addColorStop=function(t,e){this.colorStops.push({offset:t,color:e})},r})(),tm=(function(r){B(t,r);function t(e,i,n,a,o,s){var l=r.call(this,o)||this;return l.x=e??0,l.y=i??0,l.x2=n??1,l.y2=a??0,l.type="linear",l.global=s||!1,l}return t})(jg),sx=(function(r){B(t,r);function t(e,i,n,a,o){var s=r.call(this,a)||this;return s.x=e??.5,s.y=i??.5,s.r=n??.5,s.type="radial",s.global=o||!1,s}return t})(jg),zl=Math.min,lx=Math.max,io=Math.abs,Jr=[0,0],jr=[0,0],It=Qp(),no=It.minTv,ao=It.maxTv,em=(function(){function r(t,e){this._corners=[],this._axes=[],this._origin=[0,0];for(var i=0;i<4;i++)this._corners[i]=new vt;for(var i=0;i<2;i++)this._axes[i]=new vt;t&&this.fromBoundingRect(t,e)}return r.prototype.fromBoundingRect=function(t,e){var i=this._corners,n=this._axes,a=t.x,o=t.y,s=a+t.width,l=o+t.height;if(i[0].set(a,o),i[1].set(s,o),i[2].set(s,l),i[3].set(a,l),e)for(var u=0;u<4;u++)i[u].transform(e);vt.sub(n[0],i[1],i[0]),vt.sub(n[1],i[3],i[0]),n[0].normalize(),n[1].normalize();for(var u=0;u<2;u++)this._origin[u]=n[u].dot(i[0])},r.prototype.intersect=function(t,e,i){var n=!0,a=!e;return e&&vt.set(e,0,0),It.reset(i,!a),!this._intersectCheckOneSide(this,t,a,1)&&(n=!1,a)||!this._intersectCheckOneSide(t,this,a,-1)&&(n=!1,a)||!a&&!It.negativeSize&&vt.copy(e,n?It.useDir?It.dirMinTv:no:ao),n},r.prototype._intersectCheckOneSide=function(t,e,i,n){for(var a=!0,o=0;o<2;o++){var s=t._axes[o];if(t._getProjMinMaxOnAxis(o,t._corners,Jr),t._getProjMinMaxOnAxis(o,e._corners,jr),It.negativeSize||Jr[1]<jr[0]||Jr[0]>jr[1]){if(a=!1,It.negativeSize||i)return a;var l=io(jr[0]-Jr[1]),u=io(Jr[0]-jr[1]);zl(l,u)>ao.len()&&(l<u?vt.scale(ao,s,-l*n):vt.scale(ao,s,u*n))}else if(!i){var l=io(jr[0]-Jr[1]),u=io(Jr[0]-jr[1]);(It.useDir||zl(l,u)<no.len())&&((l<u||!It.bidirectional)&&(vt.scale(no,s,l*n),It.useDir&&It.calcDirMTV()),(l>=u||!It.bidirectional)&&(vt.scale(no,s,-u*n),It.useDir&&It.calcDirMTV()))}}return a},r.prototype._getProjMinMaxOnAxis=function(t,e,i){for(var n=this._axes[t],a=this._origin,o=e[0].dot(n)+a[t],s=o,l=o,u=1;u<e.length;u++){var f=e[u].dot(n)+a[t];s=zl(f,s),l=lx(f,l)}i[0]=s+It.touchThreshold,i[1]=l-It.touchThreshold,It.negativeSize=i[1]<i[0]},r})(),ux=[],fx=(function(r){B(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.notClear=!0,e.incremental=!0,e._displayables=[],e._temporaryDisplayables=[],e._cursor=0,e}return t.prototype.traverse=function(e,i){e.call(i,this)},t.prototype.useStyle=function(){this.style={}},t.prototype.getCursor=function(){return this._cursor},t.prototype.innerAfterBrush=function(){this._cursor=this._displayables.length},t.prototype.clearDisplaybles=function(){this._displayables=[],this._temporaryDisplayables=[],this._cursor=0,this.markRedraw(),this.notClear=!1},t.prototype.clearTemporalDisplayables=function(){this._temporaryDisplayables=[]},t.prototype.addDisplayable=function(e,i){i?this._temporaryDisplayables.push(e):this._displayables.push(e),this.markRedraw()},t.prototype.addDisplayables=function(e,i){i=i||!1;for(var n=0;n<e.length;n++)this.addDisplayable(e[n],i)},t.prototype.getDisplayables=function(){return this._displayables},t.prototype.getTemporalDisplayables=function(){return this._temporaryDisplayables},t.prototype.eachPendingDisplayable=function(e){for(var i=this._cursor;i<this._displayables.length;i++)e&&e(this._displayables[i]);for(var i=0;i<this._temporaryDisplayables.length;i++)e&&e(this._temporaryDisplayables[i])},t.prototype.update=function(){this.updateTransform();for(var e=this._cursor;e<this._displayables.length;e++){var i=this._displayables[e];i.parent=this,i.update(),i.parent=null}for(var e=0;e<this._temporaryDisplayables.length;e++){var i=this._temporaryDisplayables[e];i.parent=this,i.update(),i.parent=null}},t.prototype.getBoundingRect=function(){if(!this._rect){for(var e=new rt(1/0,1/0,-1/0,-1/0),i=0;i<this._displayables.length;i++){var n=this._displayables[i],a=n.getBoundingRect().clone();n.needLocalTransform()&&a.applyTransform(n.getLocalTransform(ux)),e.union(a)}this._rect=e}return this._rect},t.prototype.contain=function(e,i){var n=this.transformCoordToLocal(e,i),a=this.getBoundingRect();if(a.contain(n[0],n[1]))for(var o=0;o<this._displayables.length;o++){var s=this._displayables[o];if(s.contain(e,i))return!0}return!1},t})(Ea),hx=yt();function vx(r,t,e,i,n){var a;if(t&&t.ecModel){var o=t.ecModel.getUpdatePayload();a=o&&o.animation}var s=t&&t.isAnimationEnabled(),l=r==="update";if(s){var u=void 0,f=void 0,h=void 0;i?(u=$(i.duration,200),f=$(i.easing,"cubicOut"),h=0):(u=t.getShallow(l?"animationDurationUpdate":"animationDuration"),f=t.getShallow(l?"animationEasingUpdate":"animationEasing"),h=t.getShallow(l?"animationDelayUpdate":"animationDelay")),a&&(a.duration!=null&&(u=a.duration),a.easing!=null&&(f=a.easing),a.delay!=null&&(h=a.delay)),J(h)&&(h=h(e,n)),J(u)&&(u=u(e));var c={duration:u||0,delay:h,easing:f};return c}else return null}function fh(r,t,e,i,n,a,o){var s=!1,l;J(n)?(o=a,a=n,n=null):Z(n)&&(a=n.cb,o=n.during,s=n.isFrom,l=n.removeOpt,n=n.dataIndex);var u=r==="leave";u||t.stopAnimation("leave");var f=vx(r,i,n,u?l||{}:null,i&&i.getAnimationDelayParams?i.getAnimationDelayParams(t,n):null);if(f&&f.duration>0){var h=f.duration,c=f.delay,v=f.easing,d={duration:h,delay:c||0,easing:v,done:a,force:!!a||!!o,setToFinal:!u,scope:r,during:o};s?t.animateFrom(e,d):t.animateTo(e,d)}else t.stopAnimation(),!s&&t.attr(e),o&&o(1),a&&a()}function Ar(r,t,e,i,n,a){fh("update",r,t,e,i,n,a)}function ka(r,t,e,i,n,a){fh("enter",r,t,e,i,n,a)}function jn(r){if(!r.__zr)return!0;for(var t=0;t<r.animators.length;t++){var e=r.animators[t];if(e.scope==="leave")return!0}return!1}function ss(r,t,e,i,n,a){jn(r)||fh("leave",r,t,e,i,n,a)}function yc(r,t,e,i){r.removeTextContent(),r.removeTextGuideLine(),ss(r,{style:{opacity:0}},t,e,i)}function cx(r,t,e){function i(){r.parent&&r.parent.remove(r)}r.isGroup?r.traverse(function(n){n.isGroup||yc(n,t,e,i)}):yc(r,t,e,i)}function dx(r){hx(r).oldStyle=r.style}var of={},li=["x","y"],va=["width","height"];function px(r){return dt.extend(r)}var gx=Ww;function mx(r,t){return gx(r,t)}function Ce(r,t){of[r]=t}function yx(r){if(of.hasOwnProperty(r))return of[r]}function hh(r,t,e,i){var n=Vw(r,t);return e&&(i==="center"&&(e=im(e,n.getBoundingRect())),nm(n,e)),n}function rm(r,t,e){var i=new Er({style:{image:r,x:t.x,y:t.y,width:t.width,height:t.height},onload:function(n){if(e==="center"){var a={width:n.width,height:n.height};i.setStyle(im(t,a))}}});return i}function im(r,t){var e=t.width/t.height,i=r.height*e,n;i<=r.width?n=r.height:(i=r.width,n=i/e);var a=r.x+r.width/2,o=r.y+r.height/2;return{x:a-i/2,y:o-n/2,width:i,height:n}}var _x=Uw;function nm(r,t){if(r.applyTransform){var e=r.getBoundingRect(),i=e.calculateTransform(t);r.applyTransform(i)}}function ca(r,t){return Bg(r,r,{lineWidth:t}),r}function Sx(r,t){return Ng(r,r,t),r}var xx=hi;function am(r,t){for(var e=Xf([]);r&&r!==t;)qn(e,r.getLocalTransform(),e),r=r.parent;return e}function da(r,t,e){return t&&!Jt(t)&&(t=Kf.getLocalTransform(t)),e&&(t=La([],t)),ge([],r,t)}function om(r,t,e){var i=t[4]===0||t[5]===0||t[0]===0?1:Oe(2*t[4]/t[0]),n=t[4]===0||t[5]===0||t[2]===0?1:Oe(2*t[4]/t[2]),a=[r==="left"?-i:r==="right"?i:0,r==="top"?-n:r==="bottom"?n:0];return a=da(a,t,e),Oe(a[0])>Oe(a[1])?a[0]>0?"right":"left":a[1]>0?"bottom":"top"}function _c(r){return!r.isGroup}function bx(r){return r.shape!=null}function sm(r,t,e){if(!r||!t)return;function i(o){var s={};return o.traverse(function(l){_c(l)&&l.anid&&(s[l.anid]=l)}),s}function n(o){var s={x:o.x,y:o.y,rotation:o.rotation};return bx(o)&&(s.shape=it(o.shape)),s}var a=i(r);t.traverse(function(o){if(_c(o)&&o.anid){var s=a[o.anid];if(s){var l=n(o);o.attr(n(s)),Ar(o,l,e,ft(o).dataIndex)}}})}function Tx(r,t){return K(r,function(e){var i=e[0];i=ne(i,t.x),i=ua(i,t.x+t.width);var n=e[1];return n=ne(n,t.y),n=ua(n,t.y+t.height),[i,n]})}function Cx(r,t){var e=ne(r.x,t.x),i=ua(r.x+r.width,t.x+t.width),n=ne(r.y,t.y),a=ua(r.y+r.height,t.y+t.height);if(i>=e&&a>=n)return{x:e,y:n,width:i-e,height:a-n}}function vh(r,t,e){var i=O({rectHover:!0},t),n=i.style={strokeNoScale:!0};if(e=e||{x:-1,y:-1,width:2,height:2},r)return r.indexOf("image://")===0?(n.image=r.slice(8),ht(n,e),new Er(i)):hh(r.replace("path://",""),i,e,"center")}function Mx(r,t,e,i,n){for(var a=0,o=n[n.length-1];a<n.length;a++){var s=n[a];if(lm(r,t,e,i,s[0],s[1],o[0],o[1]))return!0;o=s}}function lm(r,t,e,i,n,a,o,s){var l=e-r,u=i-t,f=o-n,h=s-a,c=Hl(f,h,l,u);if(Dx(c))return!1;var v=r-n,d=t-a,g=Hl(v,d,l,u)/c;if(g<0||g>1)return!1;var m=Hl(v,d,f,h)/c;return!(m<0||m>1)}function Hl(r,t,e,i){return r*i-e*t}function Dx(r){return r<=1e-6&&r>=-1e-6}function ls(r,t,e,i,n){return t==null||(mt(t)?gt[0]=gt[1]=gt[2]=gt[3]=t:(gt[0]=t[0],gt[1]=t[1],gt[2]=t[2],gt[3]=t[3]),i&&(gt[0]=ne(0,gt[0]),gt[1]=ne(0,gt[1]),gt[2]=ne(0,gt[2]),gt[3]=ne(0,gt[3])),e&&(gt[0]=-gt[0],gt[1]=-gt[1],gt[2]=-gt[2],gt[3]=-gt[3]),Sc(r,gt,"x","width",3,1,n&&n[0]||0),Sc(r,gt,"y","height",0,2,n&&n[1]||0)),r}var gt=[0,0,0,0];function Sc(r,t,e,i,n,a,o){var s=t[a]+t[n],l=r[i];r[i]+=s,o=ne(0,ua(o,l)),r[i]<o?(r[i]=o,r[e]+=t[n]>=0?-t[n]:t[a]>=0?l+t[a]:Oe(s)>1e-8?(l-o)*t[n]/s:0):r[e]-=t[n]}function Ws(r){var t=r.itemTooltipOption,e=r.componentModel,i=r.itemName,n=W(t)?{formatter:t}:t,a=e.mainType,o=e.componentIndex,s={componentType:a,name:i,$vars:["name"]};s[a+"Index"]=o;var l=r.formatterParamsExtra;l&&T(St(l),function(f){xe(s,f)||(s[f]=l[f],s.$vars.push(f))});var u=ft(r.el);u.componentMainType=a,u.componentIndex=o,u.tooltipConfig={name:i,option:ht({content:i,encodeHTMLContent:!0,formatterParams:s},n)}}function sf(r,t){var e;r.isGroup&&(e=t(r)),e||r.traverse(t)}function ch(r,t){if(r)if(V(r))for(var e=0;e<r.length;e++)sf(r[e],t);else sf(r,t)}function dh(r){return!r||Oe(r[1])<oo&&Oe(r[2])<oo||Oe(r[0])<oo&&Oe(r[3])<oo}var oo=1e-5;function pa(r,t){return r?rt.copy(r,t):t.clone()}function ph(r,t){return t?Kp(r||rr(),t):void 0}function ga(r){return{z:r.get("z")||0,zlevel:r.get("zlevel")||0}}function Ax(r){var t=-1/0,e=1/0;sf(r,function(a){i(a),i(a.getTextContent()),i(a.getTextGuideLine())});function i(a){if(!(!a||a.isGroup)){var o=a.currentStates;if(o.length)for(var s=0;s<o.length;s++)n(a.states[o[s]]);n(a)}}function n(a){if(a){var o=a.z2;o>t&&(t=o),o<e&&(e=o)}}return e>t&&(e=t=0),{min:e,max:t}}function um(r,t,e){fm(r,t,e,-1/0)}function fm(r,t,e,i){if(r.ignoreModelZ)return i;var n=r.getTextContent(),a=r.getTextGuideLine(),o=r.isGroup;if(o)for(var s=r.childrenRef(),l=0;l<s.length;l++)i=ne(fm(s[l],t,e,i),i);else r.z=t,r.zlevel=e,i=ne(r.z2||0,i);if(n&&(n.z=t,n.zlevel=e,isFinite(i)&&(n.z2=i+2)),a){var u=r.textGuideLineConfig;a.z=t,a.zlevel=e,isFinite(i)&&(a.z2=i+(u&&u.showAbove?1:-1))}return i}Ce("circle",Fs);Ce("ellipse",sh);Ce("sector",zs);Ce("ring",lh);Ce("polygon",Hs);Ce("polyline",Gs);Ce("rect",wt);Ce("line",Dr);Ce("bezierCurve",uh);Ce("arc",Vs);const Lx=Object.freeze(Object.defineProperty({__proto__:null,Arc:Vs,BezierCurve:uh,BoundingRect:rt,Circle:Fs,CompoundPath:ox,Ellipse:sh,Group:Dt,Image:Er,IncrementalDisplayable:fx,Line:Dr,LinearGradient:tm,OrientedBoundingRect:em,Path:dt,Point:vt,Polygon:Hs,Polyline:Gs,RadialGradient:sx,Rect:wt,Ring:lh,Sector:zs,Text:Nt,WH:va,XY:li,applyTransform:da,calcZ2Range:Ax,clipPointsByRect:Tx,clipRectByRect:Cx,createIcon:vh,ensureCopyRect:pa,ensureCopyTransform:ph,expandOrShrinkRect:ls,extendPath:mx,extendShape:px,getShapeClass:yx,getTransform:am,groupTransition:sm,initProps:ka,isBoundingRectAxisAligned:dh,isElementRemoved:jn,lineLineIntersect:lm,linePolygonIntersect:Mx,makeImage:rm,makePath:hh,mergePath:_x,registerShape:Ce,removeElement:ss,removeElementWithFadeOut:cx,resizePath:nm,retrieveZInfo:ga,setTooltipConfig:Ws,subPixelOptimize:xx,subPixelOptimizeLine:ca,subPixelOptimizeRect:Sx,transformDirection:om,traverseElements:ch,traverseUpdateZ:um,updateProps:Ar},Symbol.toStringTag,{value:"Module"}));var Us={};function Ix(r,t){for(var e=0;e<We.length;e++){var i=We[e],n=t[i],a=r.ensureState(i);a.style=a.style||{},a.style.text=n}var o=r.currentStates.slice();r.clearStates(!0),r.setStyle({text:t.normal}),r.useStates(o,!0)}function wc(r,t,e){var i=r.labelFetcher,n=r.labelDataIndex,a=r.labelDimIndex,o=t.normal,s;i&&(s=i.getFormattedLabel(n,"normal",null,a,o&&o.get("formatter"),e!=null?{interpolatedValue:e}:null)),s==null&&(s=J(r.defaultText)?r.defaultText(n,r,e):r.defaultText);for(var l={normal:s},u=0;u<We.length;u++){var f=We[u],h=t[f];l[f]=$(i?i.getFormattedLabel(n,f,null,a,h&&h.get("formatter")):null,s)}return l}function gh(r,t,e,i){e=e||Us;for(var n=r instanceof Nt,a=!1,o=0;o<ic.length;o++){var s=t[ic[o]];if(s&&s.getShallow("show")){a=!0;break}}var l=n?r:r.getTextContent();if(a){n||(l||(l=new Nt,r.setTextContent(l)),r.stateProxy&&(l.stateProxy=r.stateProxy));var u=wc(e,t),f=t.normal,h=!!f.getShallow("show"),c=ar(f,i&&i.normal,e,!1,!n);c.text=u.normal,n||r.setTextConfig(xc(f,e,!1));for(var o=0;o<We.length;o++){var v=We[o],s=t[v];if(s){var d=l.ensureState(v),g=!!$(s.getShallow("show"),h);if(g!==h&&(d.ignore=!g),d.style=ar(s,i&&i[v],e,!0,!n),d.style.text=u[v],!n){var m=r.ensureState(v);m.textConfig=xc(s,e,!0)}}}l.silent=!!f.getShallow("silent"),l.style.x!=null&&(c.x=l.style.x),l.style.y!=null&&(c.y=l.style.y),l.ignore=!h,l.useStyle(c),l.dirty(),e.enableTextSetter&&(hm(l).setLabelText=function(p){var y=wc(e,t,p);Ix(l,y)})}else l&&(l.ignore=!0);r.dirty()}function mh(r,t){t=t||"label";for(var e={normal:r.getModel(t)},i=0;i<We.length;i++){var n=We[i];e[n]=r.getModel([n,t])}return e}function ar(r,t,e,i,n){var a={};return Px(a,r,e,i,n),t&&O(a,t),a}function xc(r,t,e){t=t||{};var i={},n,a=r.getShallow("rotate"),o=$(r.getShallow("distance"),e?null:5),s=r.getShallow("offset");return n=r.getShallow("position")||(e?null:"inside"),n==="outside"&&(n=t.defaultOutsidePosition||"top"),n!=null&&(i.position=n),s!=null&&(i.offset=s),a!=null&&(a*=Math.PI/180,i.rotation=a),o!=null&&(i.distance=o),i.outsideFill=r.get("color")==="inherit"?t.inheritColor||null:"auto",t.autoOverflowArea!=null&&(i.autoOverflowArea=t.autoOverflowArea),t.layoutRect!=null&&(i.layoutRect=t.layoutRect),i}function Px(r,t,e,i,n){e=e||Us;var a=t.ecModel,o=a&&a.option.textStyle,s=Rx(t),l;if(s){l={};var u="richInheritPlainLabel",f=$(t.get(u),a?a.get(u):void 0);for(var h in s)if(s.hasOwnProperty(h)){var c=t.getModel(["rich",h]);Mc(l[h]={},c,o,t,f,e,i,n,!1,!0)}}l&&(r.rich=l);var v=t.get("overflow");v&&(r.overflow=v);var d=t.get("lineOverflow");d&&(r.lineOverflow=d);var g=r,m=t.get("minMargin");if(m!=null)m=mt(m)?m/2:0,g.margin=[m,m,m,m],g.__marginType=ji.minMargin;else{var p=t.get("textMargin");p!=null&&(g.margin=Yf(p),g.__marginType=ji.textMargin)}Mc(r,t,o,null,null,e,i,n,!0,!1)}function Rx(r){for(var t;r&&r!==r.ecModel;){var e=(r.option||Us).rich;if(e){t=t||{};for(var i=St(e),n=0;n<i.length;n++){var a=i[n];t[a]=1}}r=r.parentModel}return t}var bc=["fontStyle","fontWeight","fontSize","fontFamily","textShadowColor","textShadowBlur","textShadowOffsetX","textShadowOffsetY"],Tc=["align","lineHeight","width","height","tag","verticalAlign","ellipsis"],Cc=["padding","borderWidth","borderRadius","borderDashOffset","backgroundColor","borderColor","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"];function Mc(r,t,e,i,n,a,o,s,l,u){e=!o&&e||Us;var f=a&&a.inheritColor,h=t.getShallow("color"),c=t.getShallow("textBorderColor"),v=$(t.getShallow("opacity"),e.opacity);(h==="inherit"||h==="auto")&&(f?h=f:h=null),(c==="inherit"||c==="auto")&&(f?c=f:c=null),s||(h=h||e.color,c=c||e.textBorderColor),h!=null&&(r.fill=h),c!=null&&(r.stroke=c);var d=$(t.getShallow("textBorderWidth"),e.textBorderWidth);d!=null&&(r.lineWidth=d);var g=$(t.getShallow("textBorderType"),e.textBorderType);g!=null&&(r.lineDash=g);var m=$(t.getShallow("textBorderDashOffset"),e.textBorderDashOffset);m!=null&&(r.lineDashOffset=m),!o&&v==null&&!u&&(v=a&&a.defaultOpacity),v!=null&&(r.opacity=v),!o&&!s&&r.fill==null&&a.inheritColor&&(r.fill=a.inheritColor);for(var p=0;p<bc.length;p++){var y=bc[p],_=n!==!1&&i?en(t.getShallow(y),i.getShallow(y),e[y]):$(t.getShallow(y),e[y]);_!=null&&(r[y]=_)}for(var p=0;p<Tc.length;p++){var y=Tc[p],_=t.getShallow(y);_!=null&&(r[y]=_)}if(r.verticalAlign==null){var S=t.getShallow("baseline");S!=null&&(r.verticalAlign=S)}if(!l||!a.disableBox){for(var p=0;p<Cc.length;p++){var y=Cc[p],_=t.getShallow(y);_!=null&&(r[y]=_)}var x=t.getShallow("borderType");x!=null&&(r.borderDash=x),(r.backgroundColor==="auto"||r.backgroundColor==="inherit")&&f&&(r.backgroundColor=f),(r.borderColor==="auto"||r.borderColor==="inherit")&&f&&(r.borderColor=f)}}function Ex(r,t){var e=t&&t.getModel("textStyle");return ke([r.fontStyle||e&&e.getShallow("fontStyle")||"",r.fontWeight||e&&e.getShallow("fontWeight")||"",(r.fontSize||e&&e.getShallow("fontSize")||12)+"px",r.fontFamily||e&&e.getShallow("fontFamily")||"sans-serif"].join(" "))}var hm=yt(),ji={minMargin:1,textMargin:2},kx=["textStyle","color"],Gl=["fontStyle","fontWeight","fontSize","fontFamily","padding","lineHeight","rich","width","height","overflow"],Vl=new Nt,Ox=(function(){function r(){}return r.prototype.getTextColor=function(t){var e=this.ecModel;return this.getShallow("color")||(!t&&e?e.get(kx):null)},r.prototype.getFont=function(){return Ex({fontStyle:this.getShallow("fontStyle"),fontWeight:this.getShallow("fontWeight"),fontSize:this.getShallow("fontSize"),fontFamily:this.getShallow("fontFamily")},this.ecModel)},r.prototype.getTextRect=function(t){for(var e={text:t,verticalAlign:this.getShallow("verticalAlign")||this.getShallow("baseline")},i=0;i<Gl.length;i++)e[Gl[i]]=this.getShallow(Gl[i]);return Vl.useStyle(e),Vl.update(),Vl.getBoundingRect()},r})(),vm=[["lineWidth","width"],["stroke","color"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"],["lineDash","type"],["lineDashOffset","dashOffset"],["lineCap","cap"],["lineJoin","join"],["miterLimit"]],Bx=ha(vm),Nx=(function(){function r(){}return r.prototype.getLineStyle=function(t){return Bx(this,t)},r})(),cm=[["fill","color"],["stroke","borderColor"],["lineWidth","borderWidth"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"],["lineDash","borderType"],["lineDashOffset","borderDashOffset"],["lineCap","borderCap"],["lineJoin","borderJoin"],["miterLimit","borderMiterLimit"]],Fx=ha(cm),zx=(function(){function r(){}return r.prototype.getItemStyle=function(t,e){return Fx(this,t,e)},r})(),xt=(function(){function r(t,e,i){this.parentModel=e,this.ecModel=i,this.option=t}return r.prototype.init=function(t,e,i){},r.prototype.mergeOption=function(t,e){st(this.option,t,!0)},r.prototype.get=function(t,e){return t==null?this.option:this._doGet(this.parsePath(t),!e&&this.parentModel)},r.prototype.getShallow=function(t,e){var i=this.option,n=i==null?i:i[t];if(n==null&&!e){var a=this.parentModel;a&&(n=a.getShallow(t))}return n},r.prototype.getModel=function(t,e){var i=t!=null,n=i?this.parsePath(t):null,a=i?this._doGet(n):this.option;return e=e||this.parentModel&&this.parentModel.getModel(this.resolveParentPath(n)),new r(a,e,this.ecModel)},r.prototype.isEmpty=function(){return this.option==null},r.prototype.restoreData=function(){},r.prototype.clone=function(){var t=this.constructor;return new t(it(this.option))},r.prototype.parsePath=function(t){return typeof t=="string"?t.split("."):t},r.prototype.resolveParentPath=function(t){return t},r.prototype.isAnimationEnabled=function(){if(!j.node&&this.option){if(this.option.animation!=null)return!!this.option.animation;if(this.parentModel)return this.parentModel.isAnimationEnabled()}},r.prototype._doGet=function(t,e){var i=this.option;if(!t)return i;for(var n=0;n<t.length&&!(t[n]&&(i=i&&typeof i=="object"?i[t[n]]:null,i==null));n++);return i==null&&e&&(i=e._doGet(this.resolveParentPath(t),e.parentModel)),i},r})();th(xt);wS(xt);Ye(xt,Nx);Ye(xt,zx);Ye(xt,MS);Ye(xt,Ox);var Hx=Math.round(Math.random()*10);function Ys(r){return[r||"",Hx++].join("_")}function Gx(r){var t={};r.registerSubTypeDefaulter=function(e,i){var n=Be(e);t[n.main]=i},r.determineSubType=function(e,i){var n=i.type;if(!n){var a=Be(e).main;r.hasSubTypes(e)&&t[a]&&(n=t[a](i))}return n}}function Vx(r,t){r.topologicalTravel=function(a,o,s,l){if(!a.length)return;var u=e(o),f=u.graph,h=u.noEntryList,c={};for(T(a,function(y){c[y]=!0});h.length;){var v=h.pop(),d=f[v],g=!!c[v];g&&(s.call(l,v,d.originalDeps.slice()),delete c[v]),T(d.successor,g?p:m)}T(c,function(){var y="";throw new Error(y)});function m(y){f[y].entryCount--,f[y].entryCount===0&&h.push(y)}function p(y){c[y]=!0,m(y)}};function e(a){var o={},s=[];return T(a,function(l){var u=i(o,l),f=u.originalDeps=t(l),h=n(f,a);u.entryCount=h.length,u.entryCount===0&&s.push(l),T(h,function(c){at(u.predecessor,c)<0&&u.predecessor.push(c);var v=i(o,c);at(v.successor,c)<0&&v.successor.push(l)})}),{graph:o,noEntryList:s}}function i(a,o){return a[o]||(a[o]={predecessor:[],successor:[]}),a[o]}function n(a,o){var s=[];return T(a,function(l){at(o,l)>=0&&s.push(l)}),s}}function yh(r,t){return st(st({},r,!0),t,!0)}const Wx={time:{month:["January","February","March","April","May","June","July","August","September","October","November","December"],monthAbbr:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],dayOfWeek:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],dayOfWeekAbbr:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"]},legend:{selector:{all:"All",inverse:"Inv"}},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"]}},series:{typeNames:{pie:"Pie chart",bar:"Bar chart",line:"Line chart",scatter:"Scatter plot",effectScatter:"Ripple scatter plot",radar:"Radar chart",tree:"Tree",treemap:"Treemap",boxplot:"Boxplot",candlestick:"Candlestick",k:"K line chart",heatmap:"Heat map",map:"Map",parallel:"Parallel coordinate map",lines:"Line graph",graph:"Relationship graph",sankey:"Sankey diagram",funnel:"Funnel chart",gauge:"Gauge",pictorialBar:"Pictorial bar",themeRiver:"Theme River Map",sunburst:"Sunburst",custom:"Custom chart",chart:"Chart"}},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:". "}}}},Ux={time:{month:["一月","二月","三月","四月","五月","六月","七月","八月","九月","十月","十一月","十二月"],monthAbbr:["1月","2月","3月","4月","5月","6月","7月","8月","9月","10月","11月","12月"],dayOfWeek:["星期日","星期一","星期二","星期三","星期四","星期五","星期六"],dayOfWeekAbbr:["日","一","二","三","四","五","六"]},legend:{selector:{all:"全选",inverse:"反选"}},toolbox:{brush:{title:{rect:"矩形选择",polygon:"圈选",lineX:"横向选择",lineY:"纵向选择",keep:"保持选择",clear:"清除选择"}},dataView:{title:"数据视图",lang:["数据视图","关闭","刷新"]},dataZoom:{title:{zoom:"区域缩放",back:"区域缩放还原"}},magicType:{title:{line:"切换为折线图",bar:"切换为柱状图",stack:"切换为堆叠",tiled:"切换为平铺"}},restore:{title:"还原"},saveAsImage:{title:"保存为图片",lang:["右键另存为图片"]}},series:{typeNames:{pie:"饼图",bar:"柱状图",line:"折线图",scatter:"散点图",effectScatter:"涟漪散点图",radar:"雷达图",tree:"树图",treemap:"矩形树图",boxplot:"箱型图",candlestick:"K线图",k:"K线图",heatmap:"热力图",map:"地图",parallel:"平行坐标图",lines:"线图",graph:"关系图",sankey:"桑基图",funnel:"漏斗图",gauge:"仪表盘图",pictorialBar:"象形柱图",themeRiver:"主题河流图",sunburst:"旭日图",custom:"自定义图表",chart:"图表"}},aria:{general:{withTitle:"这是一个关于“{title}”的图表。",withoutTitle:"这是一个图表,"},series:{single:{prefix:"",withName:"图表类型是{seriesType},表示{seriesName}。",withoutName:"图表类型是{seriesType}。"},multiple:{prefix:"它由{seriesCount}个图表系列组成。",withName:"第{seriesId}个系列是一个表示{seriesName}的{seriesType},",withoutName:"第{seriesId}个系列是一个{seriesType},",separator:{middle:";",end:"。"}}},data:{allData:"其数据是——",partialData:"其中,前{displayCnt}项是——",withName:"{name}的数据是{value}",withoutName:"{value}",separator:{middle:",",end:""}}}};var us="ZH",_h="EN",an=_h,Bo={},Sh={},dm=j.domSupported?(function(){var r=(document.documentElement.lang||navigator.language||navigator.browserLanguage||an).toUpperCase();return r.indexOf(us)>-1?us:an})():an;function pm(r,t){r=r.toUpperCase(),Sh[r]=new xt(t),Bo[r]=t}function Yx(r){if(W(r)){var t=Bo[r.toUpperCase()]||{};return r===us||r===_h?it(t):st(it(t),it(Bo[an]),!1)}else return st(it(r),it(Bo[an]),!1)}function Zx(r){return Sh[r]}function Xx(){return Sh[an]}pm(_h,Wx);pm(us,Ux);var qx=null;function fs(){return qx}var wh=1e3,xh=wh*60,ta=xh*60,pe=ta*24,Dc=pe*365,$x={year:/({yyyy}|{yy})/,month:/({MMMM}|{MMM}|{MM}|{M})/,day:/({dd}|{d})/,hour:/({HH}|{H}|{hh}|{h})/,minute:/({mm}|{m})/,second:/({ss}|{s})/,millisecond:/({SSS}|{S})/},No={year:"{yyyy}",month:"{MMM}",day:"{d}",hour:"{HH}:{mm}",minute:"{HH}:{mm}",second:"{HH}:{mm}:{ss}",millisecond:"{HH}:{mm}:{ss} {SSS}"},Kx="{yyyy}-{MM}-{dd} {HH}:{mm}:{ss} {SSS}",so="{yyyy}-{MM}-{dd}",Ac={year:"{yyyy}",month:"{yyyy}-{MM}",day:so,hour:so+" "+No.hour,minute:so+" "+No.minute,second:so+" "+No.second,millisecond:Kx},yi=["year","month","day","hour","minute","second","millisecond"],Qx=["year","half-year","quarter","month","week","half-week","day","half-day","quarter-day","hour","minute","second","millisecond"];function Jx(r){return!W(r)&&!J(r)?jx(r):r}function jx(r){r=r||{};var t={},e=!0;return T(yi,function(i){e&&(e=r[i]==null)}),T(yi,function(i,n){var a=r[i];t[i]={};for(var o=null,s=n;s>=0;s--){var l=yi[s],u=Z(a)&&!V(a)?a[l]:a,f=void 0;V(u)?(f=u.slice(),o=f[0]||""):W(u)?(o=u,f=[o]):(o==null?o=No[i]:$x[l].test(o)||(o=t[l][l][0]+" "+o),f=[o],e&&(f[1]="{primary|"+o+"}")),t[i][l]=f}}),t}function fr(r,t){return r+="","0000".substr(0,t-r.length)+r}function ea(r){switch(r){case"half-year":case"quarter":return"month";case"week":case"half-week":return"day";case"half-day":case"quarter-day":return"hour";default:return r}}function tb(r){return r===ea(r)}function eb(r){switch(r){case"year":case"month":return"day";case"millisecond":return"millisecond";default:return"second"}}function Zs(r,t,e,i){var n=dn(r),a=n[gm(e)](),o=n[bh(e)]()+1,s=Math.floor((o-1)/3)+1,l=n[Th(e)](),u=n["get"+(e?"UTC":"")+"Day"](),f=n[Ch(e)](),h=(f-1)%12+1,c=n[Mh(e)](),v=n[Dh(e)](),d=n[Ah(e)](),g=f>=12?"pm":"am",m=g.toUpperCase(),p=i instanceof xt?i:Zx(i||dm)||Xx(),y=p.getModel("time"),_=y.get("month"),S=y.get("monthAbbr"),x=y.get("dayOfWeek"),w=y.get("dayOfWeekAbbr");return(t||"").replace(/{a}/g,g+"").replace(/{A}/g,m+"").replace(/{yyyy}/g,a+"").replace(/{yy}/g,fr(a%100+"",2)).replace(/{Q}/g,s+"").replace(/{MMMM}/g,_[o-1]).replace(/{MMM}/g,S[o-1]).replace(/{MM}/g,fr(o,2)).replace(/{M}/g,o+"").replace(/{dd}/g,fr(l,2)).replace(/{d}/g,l+"").replace(/{eeee}/g,x[u]).replace(/{ee}/g,w[u]).replace(/{e}/g,u+"").replace(/{HH}/g,fr(f,2)).replace(/{H}/g,f+"").replace(/{hh}/g,fr(h+"",2)).replace(/{h}/g,h+"").replace(/{mm}/g,fr(c,2)).replace(/{m}/g,c+"").replace(/{ss}/g,fr(v,2)).replace(/{s}/g,v+"").replace(/{SSS}/g,fr(d,3)).replace(/{S}/g,d+"")}function rb(r,t,e,i,n){var a=null;if(W(e))a=e;else if(J(e)){var o={time:r.time,level:r.time.level},s=fs();s&&s.makeAxisLabelFormatterParamBreak(o,r.break),a=e(r.value,t,o)}else{var l=r.time;if(l){var u=e[l.lowerTimeUnit][l.upperTimeUnit];a=u[Math.min(l.level,u.length-1)]||""}else{var f=hs(r.value,n);a=e[f][f][0]}}return Zs(new Date(r.value),a,n,i)}function hs(r,t){var e=dn(r),i=e[bh(t)]()+1,n=e[Th(t)](),a=e[Ch(t)](),o=e[Mh(t)](),s=e[Dh(t)](),l=e[Ah(t)](),u=l===0,f=u&&s===0,h=f&&o===0,c=h&&a===0,v=c&&n===1,d=v&&i===1;return d?"year":v?"month":c?"day":h?"hour":f?"minute":u?"second":"millisecond"}function lf(r,t,e){switch(t){case"year":r[mm(e)](0);case"month":r[ym(e)](1);case"day":r[_m(e)](0);case"hour":r[Sm(e)](0);case"minute":r[wm(e)](0);case"second":r[xm(e)](0)}return r}function gm(r){return r?"getUTCFullYear":"getFullYear"}function bh(r){return r?"getUTCMonth":"getMonth"}function Th(r){return r?"getUTCDate":"getDate"}function Ch(r){return r?"getUTCHours":"getHours"}function Mh(r){return r?"getUTCMinutes":"getMinutes"}function Dh(r){return r?"getUTCSeconds":"getSeconds"}function Ah(r){return r?"getUTCMilliseconds":"getMilliseconds"}function ib(r){return r?"setUTCFullYear":"setFullYear"}function mm(r){return r?"setUTCMonth":"setMonth"}function ym(r){return r?"setUTCDate":"setDate"}function _m(r){return r?"setUTCHours":"setHours"}function Sm(r){return r?"setUTCMinutes":"setMinutes"}function wm(r){return r?"setUTCSeconds":"setSeconds"}function xm(r){return r?"setUTCMilliseconds":"setMilliseconds"}function bm(r){if(!K1(r))return W(r)?r:"-";var t=(r+"").split(".");return t[0].replace(/(\d{1,3})(?=(?:\d{3})+(?!\d))/g,"$1,")+(t.length>1?"."+t[1]:"")}function Tm(r,t){return r=(r||"").toLowerCase().replace(/-(.)/g,function(e,i){return i.toUpperCase()}),t&&r&&(r=r.charAt(0).toUpperCase()+r.slice(1)),r}var Xs=Yf;function uf(r,t,e){var i="{yyyy}-{MM}-{dd} {HH}:{mm}:{ss}";function n(f){return f&&ke(f)?f:"-"}function a(f){return!!(f!=null&&!isNaN(f)&&isFinite(f))}var o=t==="time",s=r instanceof Date;if(o||s){var l=o?dn(r):r;if(isNaN(+l)){if(s)return"-"}else return Zs(l,i,e)}if(t==="ordinal")return Cu(r)?n(r):mt(r)&&a(r)?r+"":"-";var u=ts(r);return a(u)?bm(u):Cu(r)?n(r):typeof r=="boolean"?r+"":"-"}var Lc=["a","b","c","d","e","f","g"],Wl=function(r,t){return"{"+r+(t??"")+"}"};function Cm(r,t,e){V(t)||(t=[t]);var i=t.length;if(!i)return"";for(var n=t[0].$vars||[],a=0;a<n.length;a++){var o=Lc[a];r=r.replace(Wl(o),Wl(o,0))}for(var s=0;s<i;s++)for(var l=0;l<n.length;l++){var u=t[s][n[l]];r=r.replace(Wl(Lc[l],s),e?qt(u):u)}return r}function nb(r,t){var e=W(r)?{color:r,extraCssText:t}:r||{},i=e.color,n=e.type;t=e.extraCssText;var a=e.renderMode||"html";if(!i)return"";if(a==="html")return n==="subItem"?'<span style="display:inline-block;vertical-align:middle;margin-right:8px;margin-left:3px;border-radius:4px;width:4px;height:4px;background-color:'+qt(i)+";"+(t||"")+'"></span>':'<span style="display:inline-block;margin-right:4px;border-radius:10px;width:10px;height:10px;background-color:'+qt(i)+";"+(t||"")+'"></span>';var o=e.markerId||"markerX";return{renderMode:a,content:"{"+o+"|} ",style:n==="subItem"?{width:4,height:4,borderRadius:2,backgroundColor:i}:{width:10,height:10,borderRadius:5,backgroundColor:i}}}function bi(r,t){return t=t||"transparent",W(r)?r:Z(r)&&r.colorStops&&(r.colorStops[0]||{}).color||t}function Ic(r,t){if(t==="_blank"||t==="blank"){var e=window.open();e.opener=null,e.location.href=r}else window.open(r,t)}var Fo={},Ul={},Lh=(function(){function r(){this._normalMasterList=[],this._nonSeriesBoxMasterList=[]}return r.prototype.create=function(t,e){this._nonSeriesBoxMasterList=i(Fo),this._normalMasterList=i(Ul);function i(n,a){var o=[];return T(n,function(s,l){var u=s.create(t,e);o=o.concat(u||[])}),o}},r.prototype.update=function(t,e){T(this._normalMasterList,function(i){i.update&&i.update(t,e)})},r.prototype.getCoordinateSystems=function(){return this._normalMasterList.concat(this._nonSeriesBoxMasterList)},r.register=function(t,e){if(t==="matrix"||t==="calendar"){Fo[t]=e;return}Ul[t]=e},r.get=function(t){return Ul[t]||Fo[t]},r})();function ab(r){return!!Fo[r]}var Pc={coord:1,coord2:2},ob=Q();function sb(r){var t=r.getShallow("coord",!0),e=Pc.coord;if(t==null){var i=ob.get(r.type);i&&i.getCoord2&&(e=Pc.coord2,t=i.getCoord2(r))}return{coord:t,from:e}}var je={none:0,dataCoordSys:1,boxCoordSys:2};function lb(r,t){var e=r.getShallow("coordinateSystem"),i=r.getShallow("coordinateSystemUsage",!0),n=je.none;if(e){var a=r.mainType==="series";i==null&&(i=a?"data":"box"),i==="data"?(n=je.dataCoordSys,a||(n=je.none)):i==="box"&&(n=je.boxCoordSys,!a&&!ab(e)&&(n=je.none))}return{coordSysType:e,kind:n}}function ub(r){var t=r.targetModel,e=r.coordSysType,i=r.coordSysProvider,n=r.isDefaultDataCoordSys,a=lb(t),o=a.kind,s=a.coordSysType;if(n&&o!==je.dataCoordSys&&(o=je.dataCoordSys,s=e),o===je.none||s!==e)return!1;var l=i(e,t);return l?(o===je.dataCoordSys?t.coordinateSystem=l:t.boxCoordinateSystem=l,!0):!1}var zo=T,fb=["left","right","top","bottom","width","height"],lo=[["width","left","right"],["height","top","bottom"]];function Ih(r,t,e,i,n){var a=0,o=0;i==null&&(i=1/0),n==null&&(n=1/0);var s=0;t.eachChild(function(l,u){var f=l.getBoundingRect(),h=t.childAt(u+1),c=h&&h.getBoundingRect(),v,d;if(r==="horizontal"){var g=f.width+(c?-c.x+f.x:0);v=a+g,v>i||l.newline?(a=0,v=g,o+=s+e,s=f.height):s=Math.max(s,f.height)}else{var m=f.height+(c?-c.y+f.y:0);d=o+m,d>n||l.newline?(a+=s+e,o=0,d=m,s=f.width):s=Math.max(s,f.width)}l.newline||(l.x=a,l.y=o,l.markRedraw(),r==="horizontal"?a=v+e:o=d+e)})}var ra=Ih;Mt(Ih,"vertical");Mt(Ih,"horizontal");function hb(r,t){return{left:r.getShallow("left",t),top:r.getShallow("top",t),right:r.getShallow("right",t),bottom:r.getShallow("bottom",t),width:r.getShallow("width",t),height:r.getShallow("height",t)}}function Ti(r,t,e){e=Xs(e||0);var i=t.width,n=t.height,a=Ot(r.left,i),o=Ot(r.top,n),s=Ot(r.right,i),l=Ot(r.bottom,n),u=Ot(r.width,i),f=Ot(r.height,n),h=e[2]+e[0],c=e[1]+e[3],v=r.aspect;switch(isNaN(u)&&(u=i-s-c-a),isNaN(f)&&(f=n-l-h-o),v!=null&&(isNaN(u)&&isNaN(f)&&(v>i/n?u=i*.8:f=n*.8),isNaN(u)&&(u=v*f),isNaN(f)&&(f=u/v)),isNaN(a)&&(a=i-s-u-c),isNaN(o)&&(o=n-l-f-h),r.left||r.right){case"center":a=i/2-u/2-e[3];break;case"right":a=i-u-c;break}switch(r.top||r.bottom){case"middle":case"center":o=n/2-f/2-e[0];break;case"bottom":o=n-f-h;break}a=a||0,o=o||0,isNaN(u)&&(u=i-c-a-(s||0)),isNaN(f)&&(f=n-h-o-(l||0));var d=new rt((t.x||0)+a+e[3],(t.y||0)+o+e[0],u,f);return d.margin=e,d}var Yl={rect:1};function qs(r,t,e){var i,n,a,o=r.boxCoordinateSystem,s;if(o){var l=sb(r),u=l.coord,f=l.from;if(o.dataToLayout){a=Yl.rect,s=f;var h=o.dataToLayout(u);i=h.contentRect||h.rect}}return a==null&&(a=Yl.rect),a===Yl.rect&&(i||(i={x:0,y:0,width:t.getWidth(),height:t.getHeight()}),n=[i.x+i.width/2,i.y+i.height/2]),{type:a,refContainer:i,refPoint:n,boxCoordFrom:s}}function ma(r){var t=r.layoutMode||r.constructor.layoutMode;return Z(t)?t:t?{type:t}:null}function Lr(r,t,e){var i=e&&e.ignoreSize;!V(i)&&(i=[i,i]);var n=o(lo[0],0),a=o(lo[1],1);l(lo[0],r,n),l(lo[1],r,a);function o(u,f){var h={},c=0,v={},d=0,g=2;if(zo(u,function(y){v[y]=r[y]}),zo(u,function(y){xe(t,y)&&(h[y]=v[y]=t[y]),s(h,y)&&c++,s(v,y)&&d++}),i[f])return s(t,u[1])?v[u[2]]=null:s(t,u[2])&&(v[u[1]]=null),v;if(d===g||!c)return v;if(c>=g)return h;for(var m=0;m<u.length;m++){var p=u[m];if(!xe(h,p)&&xe(r,p)){h[p]=r[p];break}}return h}function s(u,f){return u[f]!=null&&u[f]!=="auto"}function l(u,f,h){zo(u,function(c){f[c]=h[c]})}}function pn(r){return vb({},r)}function vb(r,t){return t&&r&&zo(fb,function(e){xe(t,e)&&(r[e]=t[e])}),r}var cb=yt(),ut=(function(r){B(t,r);function t(e,i,n){var a=r.call(this,e,i,n)||this;return a.uid=Ys("ec_cpt_model"),a}return t.prototype.init=function(e,i,n){this.mergeDefaultAndTheme(e,n)},t.prototype.mergeDefaultAndTheme=function(e,i){var n=ma(this),a=n?pn(e):{},o=i.getTheme();st(e,o.get(this.mainType)),st(e,this.getDefaultOption()),n&&Lr(e,a,n)},t.prototype.mergeOption=function(e,i){st(this.option,e,!0);var n=ma(this);n&&Lr(this.option,e,n)},t.prototype.optionUpdated=function(e,i){},t.prototype.getDefaultOption=function(){var e=this.constructor;if(!yS(e))return e.defaultOption;var i=cb(this);if(!i.defaultOption){for(var n=[],a=e;a;){var o=a.prototype.defaultOption;o&&n.push(o),a=a.superClass}for(var s={},l=n.length-1;l>=0;l--)s=st(s,n[l],!0);i.defaultOption=s}return i.defaultOption},t.prototype.getReferringComponents=function(e,i){var n=e+"Index",a=e+"Id";return Ra(this.ecModel,e,{index:this.get(n,!0),id:this.get(a,!0)},i)},t.prototype.getBoxLayoutParams=function(){return hb(this,!1)},t.prototype.getZLevelKey=function(){return""},t.prototype.setZLevel=function(e){this.option.zlevel=e},t.protoInitialize=(function(){var e=t.prototype;e.type="component",e.id="",e.name="",e.mainType="",e.subType="",e.componentIndex=0})(),t})(xt);Ag(ut,xt);Rs(ut);Gx(ut);Vx(ut,db);function db(r){var t=[];return T(ut.getClassesByMainType(r),function(e){t=t.concat(e.dependencies||e.prototype.dependencies||[])}),t=K(t,function(e){return Be(e).main}),r!=="dataset"&&at(t,"dataset")<=0&&t.unshift("dataset"),t}var H={color:{},darkColor:{},size:{}},bt=H.color={theme:["#5070dd","#b6d634","#505372","#ff994d","#0ca8df","#ffd10a","#fb628b","#785db0","#3fbe95"],neutral00:"#fff",neutral05:"#f4f7fd",neutral10:"#e8ebf0",neutral15:"#dbdee4",neutral20:"#cfd2d7",neutral25:"#c3c5cb",neutral30:"#b7b9be",neutral35:"#aaacb2",neutral40:"#9ea0a5",neutral45:"#929399",neutral50:"#86878c",neutral55:"#797b7f",neutral60:"#6d6e73",neutral65:"#616266",neutral70:"#54555a",neutral75:"#48494d",neutral80:"#3c3c41",neutral85:"#303034",neutral90:"#232328",neutral95:"#17171b",neutral99:"#000",accent05:"#eff1f9",accent10:"#e0e4f2",accent15:"#d0d6ec",accent20:"#c0c9e6",accent25:"#b1bbdf",accent30:"#a1aed9",accent35:"#91a0d3",accent40:"#8292cc",accent45:"#7285c6",accent50:"#6578ba",accent55:"#5c6da9",accent60:"#536298",accent65:"#4a5787",accent70:"#404c76",accent75:"#374165",accent80:"#2e3654",accent85:"#252b43",accent90:"#1b2032",accent95:"#121521",transparent:"rgba(0,0,0,0)",highlight:"rgba(255,231,130,0.8)"};O(bt,{primary:bt.neutral80,secondary:bt.neutral70,tertiary:bt.neutral60,quaternary:bt.neutral50,disabled:bt.neutral20,border:bt.neutral30,borderTint:bt.neutral20,borderShade:bt.neutral40,background:bt.neutral05,backgroundTint:"rgba(234,237,245,0.5)",backgroundTransparent:"rgba(255,255,255,0)",backgroundShade:bt.neutral10,shadow:"rgba(0,0,0,0.2)",shadowTint:"rgba(129,130,136,0.2)",axisLine:bt.neutral70,axisLineTint:bt.neutral40,axisTick:bt.neutral70,axisTickMinor:bt.neutral60,axisLabel:bt.neutral70,axisSplitLine:bt.neutral15,axisMinorSplitLine:bt.neutral05});for(var ti in bt)if(bt.hasOwnProperty(ti)){var Rc=bt[ti];ti==="theme"?H.darkColor.theme=bt.theme.slice():ti==="highlight"?H.darkColor.highlight="rgba(255,231,130,0.4)":ti.indexOf("accent")===0?H.darkColor[ti]=Nu(Rc,null,function(r){return r*.5},function(r){return Math.min(1,1.3-r)}):H.darkColor[ti]=Nu(Rc,null,function(r){return r*.9},function(r){return 1-Math.pow(r,1.5)})}H.size={xxs:2,xs:5,s:10,m:15,l:20,xl:30,xxl:40,xxxl:50};var Mm="";typeof navigator<"u"&&(Mm=navigator.platform||"");var Bi="rgba(0, 0, 0, 0.2)",Dm=H.color.theme[0],pb=Nu(Dm,null,null,.9);const gb={darkMode:"auto",colorBy:"series",color:H.color.theme,gradientColor:[pb,Dm],aria:{decal:{decals:[{color:Bi,dashArrayX:[1,0],dashArrayY:[2,5],symbolSize:1,rotation:Math.PI/6},{color:Bi,symbol:"circle",dashArrayX:[[8,8],[0,8,8,0]],dashArrayY:[6,0],symbolSize:.8},{color:Bi,dashArrayX:[1,0],dashArrayY:[4,3],rotation:-Math.PI/4},{color:Bi,dashArrayX:[[6,6],[0,6,6,0]],dashArrayY:[6,0]},{color:Bi,dashArrayX:[[1,0],[1,6]],dashArrayY:[1,0,6,0],rotation:Math.PI/4},{color:Bi,symbol:"triangle",dashArrayX:[[9,9],[0,9,9,0]],dashArrayY:[7,2],symbolSize:.75}]}},textStyle:{fontFamily:Mm.match(/^Win/)?"Microsoft YaHei":"sans-serif",fontSize:12,fontStyle:"normal",fontWeight:"normal"},blendMode:null,stateAnimation:{duration:300,easing:"cubicOut"},animation:"auto",animationDuration:1e3,animationDurationUpdate:500,animationEasing:"cubicInOut",animationEasingUpdate:"cubicInOut",animationThreshold:2e3,progressiveThreshold:3e3,progressive:400,hoverLayerThreshold:3e3,useUTC:!1};var Am=Q(["tooltip","label","itemName","itemId","itemGroupId","itemChildGroupId","seriesName"]),ae="original",Ht="arrayRows",Me="objectRows",Ze="keyedColumns",Tr="typedArray",Lm="unknown",Ge="column",Ci="row",ee={Must:1,Might:2,Not:3},Im=yt();function mb(r){Im(r).datasetMap=Q()}function yb(r,t,e){var i={},n=Pm(t);if(!n||!r)return i;var a=[],o=[],s=t.ecModel,l=Im(s).datasetMap,u=n.uid+"_"+e.seriesLayoutBy,f,h;r=r.slice(),T(r,function(g,m){var p=Z(g)?g:r[m]={name:g};p.type==="ordinal"&&f==null&&(f=m,h=d(p)),i[p.name]=[]});var c=l.get(u)||l.set(u,{categoryWayDim:h,valueWayDim:0});T(r,function(g,m){var p=g.name,y=d(g);if(f==null){var _=c.valueWayDim;v(i[p],_,y),v(o,_,y),c.valueWayDim+=y}else if(f===m)v(i[p],0,y),v(a,0,y);else{var _=c.categoryWayDim;v(i[p],_,y),v(o,_,y),c.categoryWayDim+=y}});function v(g,m,p){for(var y=0;y<p;y++)g.push(m+y)}function d(g){var m=g.dimsDef;return m?m.length:1}return a.length&&(i.itemName=a),o.length&&(i.seriesName=o),i}function Pm(r){var t=r.get("data",!0);if(!t)return Ra(r.ecModel,"dataset",{index:r.get("datasetIndex",!0),id:r.get("datasetId",!0)},Wt).models[0]}function _b(r){return!r.get("transform",!0)&&!r.get("fromTransformResult",!0)?[]:Ra(r.ecModel,"dataset",{index:r.get("fromDatasetIndex",!0),id:r.get("fromDatasetId",!0)},Wt).models}function Rm(r,t){return Sb(r.data,r.sourceFormat,r.seriesLayoutBy,r.dimensionsDefine,r.startIndex,t)}function Sb(r,t,e,i,n,a){var o,s=5;if(jt(r))return ee.Not;var l,u;if(i){var f=i[a];Z(f)?(l=f.name,u=f.type):W(f)&&(l=f)}if(u!=null)return u==="ordinal"?ee.Must:ee.Not;if(t===Ht){var h=r;if(e===Ci){for(var c=h[a],v=0;v<(c||[]).length&&v<s;v++)if((o=S(c[n+v]))!=null)return o}else for(var v=0;v<h.length&&v<s;v++){var d=h[n+v];if(d&&(o=S(d[a]))!=null)return o}}else if(t===Me){var g=r;if(!l)return ee.Not;for(var v=0;v<g.length&&v<s;v++){var m=g[v];if(m&&(o=S(m[l]))!=null)return o}}else if(t===Ze){var p=r;if(!l)return ee.Not;var c=p[l];if(!c||jt(c))return ee.Not;for(var v=0;v<c.length&&v<s;v++)if((o=S(c[v]))!=null)return o}else if(t===ae)for(var y=r,v=0;v<y.length&&v<s;v++){var m=y[v],_=Pa(m);if(!V(_))return ee.Not;if((o=S(_[a]))!=null)return o}function S(x){var w=W(x);if(x!=null&&Number.isFinite(Number(x))&&x!=="")return w?ee.Might:ee.Not;if(w&&x!=="-")return ee.Must}return ee.Not}var wb=Q();function xb(r,t,e){var i=wb.get(t);if(!i)return e;var n=i(r);return n?e.concat(n):e}var Ec=yt();yt();var Ph=(function(){function r(){}return r.prototype.getColorFromPalette=function(t,e,i){var n=Yt(this.get("color",!0)),a=this.get("colorLayer",!0);return Tb(this,Ec,n,a,t,e,i)},r.prototype.clearColorPalette=function(){Cb(this,Ec)},r})();function bb(r,t){for(var e=r.length,i=0;i<e;i++)if(r[i].length>t)return r[i];return r[e-1]}function Tb(r,t,e,i,n,a,o){a=a||r;var s=t(a),l=s.paletteIdx||0,u=s.paletteNameMap=s.paletteNameMap||{};if(u.hasOwnProperty(n))return u[n];var f=o==null||!i?e:bb(i,o);if(f=f||e,!(!f||!f.length)){var h=f[l];return n&&(u[n]=h),s.paletteIdx=(l+1)%f.length,h}}function Cb(r,t){t(r).paletteIdx=0,t(r).paletteNameMap={}}var uo,xn,kc,Oc="\0_ec_inner",Mb=1,Rh=(function(r){B(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t.prototype.init=function(e,i,n,a,o,s){a=a||{},this.option=null,this._theme=new xt(a),this._locale=new xt(o),this._optionManager=s},t.prototype.setOption=function(e,i,n){var a=Fc(i);this._optionManager.setOption(e,n,a),this._resetOption(null,a)},t.prototype.resetOption=function(e,i){return this._resetOption(e,Fc(i))},t.prototype._resetOption=function(e,i){var n=!1,a=this._optionManager;if(!e||e==="recreate"){var o=a.mountOption(e==="recreate");!this.option||e==="recreate"?kc(this,o):(this.restoreData(),this._mergeOption(o,i)),n=!0}if((e==="timeline"||e==="media")&&this.restoreData(),!e||e==="recreate"||e==="timeline"){var s=a.getTimelineOption(this);s&&(n=!0,this._mergeOption(s,i))}if(!e||e==="recreate"||e==="media"){var l=a.getMediaOption(this);l.length&&T(l,function(u){n=!0,this._mergeOption(u,i)},this)}return n},t.prototype.mergeOption=function(e){this._mergeOption(e,null)},t.prototype._mergeOption=function(e,i){var n=this.option,a=this._componentsMap,o=this._componentsCount,s=[],l=Q(),u=i&&i.replaceMergeMainTypeMap;mb(this),T(e,function(h,c){h!=null&&(ut.hasClass(c)?c&&(s.push(c),l.set(c,!0)):n[c]=n[c]==null?it(h):st(n[c],h,!0))}),u&&u.each(function(h,c){ut.hasClass(c)&&!l.get(c)&&(s.push(c),l.set(c,!0))}),ut.topologicalTravel(s,ut.getAllClassMainTypes(),f,this);function f(h){var c=xb(this,h,Yt(e[h])),v=a.get(h),d=v?u&&u.get(h)?"replaceMerge":"normalMerge":"replaceAll",g=rS(v,c,d);uS(g,h,ut),n[h]=null,a.set(h,null),o.set(h,0);var m=[],p=[],y=0,_;T(g,function(S,x){var w=S.existing,b=S.newOption;if(!b)w&&(w.mergeOption({},this),w.optionUpdated({},!1));else{var D=h==="series",C=ut.getClass(h,S.keyInfo.subType,!D);if(!C)return;if(h==="tooltip"){if(_)return;_=!0}if(w&&w.constructor===C)w.name=S.keyInfo.name,w.mergeOption(b,this),w.optionUpdated(b,!1);else{var M=O({componentIndex:x},S.keyInfo);w=new C(b,this,this,M),O(w,M),S.brandNew&&(w.__requireNewView=!0),w.init(b,this,this),w.optionUpdated(null,!0)}}w?(m.push(w.option),p.push(w),y++):(m.push(void 0),p.push(void 0))},this),n[h]=m,a.set(h,p),o.set(h,y),h==="series"&&uo(this)}this._seriesIndices||uo(this)},t.prototype.getOption=function(){var e=it(this.option);return T(e,function(i,n){if(ut.hasClass(n)){for(var a=Yt(i),o=a.length,s=!1,l=o-1;l>=0;l--)a[l]&&!fa(a[l])?s=!0:(a[l]=null,!s&&o--);a.length=o,e[n]=a}}),delete e[Oc],e},t.prototype.setTheme=function(e){this._theme=new xt(e),this._resetOption("recreate",null)},t.prototype.getTheme=function(){return this._theme},t.prototype.getLocaleModel=function(){return this._locale},t.prototype.setUpdatePayload=function(e){this._payload=e},t.prototype.getUpdatePayload=function(){return this._payload},t.prototype.getComponent=function(e,i){var n=this._componentsMap.get(e);if(n){var a=n[i||0];if(a)return a;if(i==null){for(var o=0;o<n.length;o++)if(n[o])return n[o]}}},t.prototype.queryComponents=function(e){var i=e.mainType;if(!i)return[];var n=e.index,a=e.id,o=e.name,s=this._componentsMap.get(i);if(!s||!s.length)return[];var l;return n!=null?(l=[],T(Yt(n),function(u){s[u]&&l.push(s[u])})):a!=null?l=Bc("id",a,s):o!=null?l=Bc("name",o,s):l=Rt(s,function(u){return!!u}),Nc(l,e)},t.prototype.findComponents=function(e){var i=e.query,n=e.mainType,a=s(i),o=a?this.queryComponents(a):Rt(this._componentsMap.get(n),function(u){return!!u});return l(Nc(o,e));function s(u){var f=n+"Index",h=n+"Id",c=n+"Name";return u&&(u[f]!=null||u[h]!=null||u[c]!=null)?{mainType:n,index:u[f],id:u[h],name:u[c]}:null}function l(u){return e.filter?Rt(u,e.filter):u}},t.prototype.eachComponent=function(e,i,n){var a=this._componentsMap;if(J(e)){var o=i,s=e;a.each(function(h,c){for(var v=0;h&&v<h.length;v++){var d=h[v];d&&s.call(o,c,d,d.componentIndex)}})}else for(var l=W(e)?a.get(e):Z(e)?this.findComponents(e):null,u=0;l&&u<l.length;u++){var f=l[u];f&&i.call(n,f,f.componentIndex)}},t.prototype.getSeriesByName=function(e){var i=He(e,null);return Rt(this._componentsMap.get("series"),function(n){return!!n&&i!=null&&n.name===i})},t.prototype.getSeriesByIndex=function(e){return this._componentsMap.get("series")[e]},t.prototype.getSeriesByType=function(e){return Rt(this._componentsMap.get("series"),function(i){return!!i&&i.subType===e})},t.prototype.getSeries=function(){return Rt(this._componentsMap.get("series"),function(e){return!!e})},t.prototype.getSeriesCount=function(){return this._componentsCount.get("series")},t.prototype.eachSeries=function(e,i){xn(this),T(this._seriesIndices,function(n){var a=this._componentsMap.get("series")[n];e.call(i,a,n)},this)},t.prototype.eachRawSeries=function(e,i){T(this._componentsMap.get("series"),function(n){n&&e.call(i,n,n.componentIndex)})},t.prototype.eachSeriesByType=function(e,i,n){xn(this),T(this._seriesIndices,function(a){var o=this._componentsMap.get("series")[a];o.subType===e&&i.call(n,o,a)},this)},t.prototype.eachRawSeriesByType=function(e,i,n){return T(this.getSeriesByType(e),i,n)},t.prototype.isSeriesFiltered=function(e){return xn(this),this._seriesIndicesMap.get(e.componentIndex)==null},t.prototype.getCurrentSeriesIndices=function(){return(this._seriesIndices||[]).slice()},t.prototype.filterSeries=function(e,i){xn(this);var n=[];T(this._seriesIndices,function(a){var o=this._componentsMap.get("series")[a];e.call(i,o,a)&&n.push(a)},this),this._seriesIndices=n,this._seriesIndicesMap=Q(n)},t.prototype.restoreData=function(e){uo(this);var i=this._componentsMap,n=[];i.each(function(a,o){ut.hasClass(o)&&n.push(o)}),ut.topologicalTravel(n,ut.getAllClassMainTypes(),function(a){T(i.get(a),function(o){o&&(a!=="series"||!Db(o,e))&&o.restoreData()})})},t.internalField=(function(){uo=function(e){var i=e._seriesIndices=[];T(e._componentsMap.get("series"),function(n){n&&i.push(n.componentIndex)}),e._seriesIndicesMap=Q(i)},xn=function(e){},kc=function(e,i){e.option={},e.option[Oc]=Mb,e._componentsMap=Q({series:[]}),e._componentsCount=Q();var n=i.aria;Z(n)&&n.enabled==null&&(n.enabled=!0),Ab(i,e._theme.option),st(i,gb,!1),e._mergeOption(i,null)}})(),t})(xt);function Db(r,t){if(t){var e=t.seriesIndex,i=t.seriesId,n=t.seriesName;return e!=null&&r.componentIndex!==e||i!=null&&r.id!==i||n!=null&&r.name!==n}}function Ab(r,t){var e=r.color&&!r.colorLayer;T(t,function(i,n){n==="colorLayer"&&e||n==="color"&&r.color||ut.hasClass(n)||(typeof i=="object"?r[n]=r[n]?st(r[n],i,!1):it(i):r[n]==null&&(r[n]=i))})}function Bc(r,t,e){if(V(t)){var i=Q();return T(t,function(a){if(a!=null){var o=He(a,null);o!=null&&i.set(a,!0)}}),Rt(e,function(a){return a&&i.get(a[r])})}else{var n=He(t,null);return Rt(e,function(a){return a&&n!=null&&a[r]===n})}}function Nc(r,t){return t.hasOwnProperty("subType")?Rt(r,function(e){return e&&e.subType===t.subType}):r}function Fc(r){var t=Q();return r&&T(Yt(r.replaceMerge),function(e){t.set(e,!0)}),{replaceMergeMainTypeMap:t}}Ye(Rh,Ph);var Lb=["getDom","getZr","getWidth","getHeight","getDevicePixelRatio","dispatchAction","isSSR","isDisposed","on","off","getDataURL","getConnectedDataURL","getOption","getId","updateLabelLayout"],Em=(function(){function r(t){T(Lb,function(e){this[e]=q(t[e],t)},this)}return r})(),Ib=/^(min|max)?(.+)$/,Pb=(function(){function r(t){this._timelineOptions=[],this._mediaList=[],this._currentMediaIndices=[],this._api=t}return r.prototype.setOption=function(t,e,i){t&&(T(Yt(t.series),function(o){o&&o.data&&jt(o.data)&&Mu(o.data)}),T(Yt(t.dataset),function(o){o&&o.source&&jt(o.source)&&Mu(o.source)})),t=it(t);var n=this._optionBackup,a=Rb(t,e,!n);this._newBaseOption=a.baseOption,n?(a.timelineOptions.length&&(n.timelineOptions=a.timelineOptions),a.mediaList.length&&(n.mediaList=a.mediaList),a.mediaDefault&&(n.mediaDefault=a.mediaDefault)):this._optionBackup=a},r.prototype.mountOption=function(t){var e=this._optionBackup;return this._timelineOptions=e.timelineOptions,this._mediaList=e.mediaList,this._mediaDefault=e.mediaDefault,this._currentMediaIndices=[],it(t?e.baseOption:this._newBaseOption)},r.prototype.getTimelineOption=function(t){var e,i=this._timelineOptions;if(i.length){var n=t.getComponent("timeline");n&&(e=it(i[n.getCurrentIndex()]))}return e},r.prototype.getMediaOption=function(t){var e=this._api.getWidth(),i=this._api.getHeight(),n=this._mediaList,a=this._mediaDefault,o=[],s=[];if(!n.length&&!a)return s;for(var l=0,u=n.length;l<u;l++)Eb(n[l].query,e,i)&&o.push(l);return!o.length&&a&&(o=[-1]),o.length&&!Ob(o,this._currentMediaIndices)&&(s=K(o,function(f){return it(f===-1?a.option:n[f].option)})),this._currentMediaIndices=o,s},r})();function Rb(r,t,e){var i=[],n,a,o=r.baseOption,s=r.timeline,l=r.options,u=r.media,f=!!r.media,h=!!(l||s||o&&o.timeline);o?(a=o,a.timeline||(a.timeline=s)):((h||f)&&(r.options=r.media=null),a=r),f&&V(u)&&T(u,function(v){v&&v.option&&(v.query?i.push(v):n||(n=v))}),c(a),T(l,function(v){return c(v)}),T(i,function(v){return c(v.option)});function c(v){T(t,function(d){d(v,e)})}return{baseOption:a,timelineOptions:l||[],mediaDefault:n,mediaList:i}}function Eb(r,t,e){var i={width:t,height:e,aspectratio:t/e},n=!0;return T(r,function(a,o){var s=o.match(Ib);if(!(!s||!s[1]||!s[2])){var l=s[1],u=s[2].toLowerCase();kb(i[u],a,l)||(n=!1)}}),n}function kb(r,t,e){return e==="min"?r>=t:e==="max"?r<=t:r===t}function Ob(r,t){return r.join(",")===t.join(",")}var ye=T,ya=Z,zc=["areaStyle","lineStyle","nodeStyle","linkStyle","chordStyle","label","labelLine"];function Zl(r){var t=r&&r.itemStyle;if(t)for(var e=0,i=zc.length;e<i;e++){var n=zc[e],a=t.normal,o=t.emphasis;a&&a[n]&&(r[n]=r[n]||{},r[n].normal?st(r[n].normal,a[n]):r[n].normal=a[n],a[n]=null),o&&o[n]&&(r[n]=r[n]||{},r[n].emphasis?st(r[n].emphasis,o[n]):r[n].emphasis=o[n],o[n]=null)}}function zt(r,t,e){if(r&&r[t]&&(r[t].normal||r[t].emphasis)){var i=r[t].normal,n=r[t].emphasis;i&&(e?(r[t].normal=r[t].emphasis=null,ht(r[t],i)):r[t]=i),n&&(r.emphasis=r.emphasis||{},r.emphasis[t]=n,n.focus&&(r.emphasis.focus=n.focus),n.blurScope&&(r.emphasis.blurScope=n.blurScope))}}function Un(r){zt(r,"itemStyle"),zt(r,"lineStyle"),zt(r,"areaStyle"),zt(r,"label"),zt(r,"labelLine"),zt(r,"upperLabel"),zt(r,"edgeLabel")}function Tt(r,t){var e=ya(r)&&r[t],i=ya(e)&&e.textStyle;if(i)for(var n=0,a=Ov.length;n<a;n++){var o=Ov[n];i.hasOwnProperty(o)&&(e[o]=i[o])}}function fe(r){r&&(Un(r),Tt(r,"label"),r.emphasis&&Tt(r.emphasis,"label"))}function Bb(r){if(ya(r)){Zl(r),Un(r),Tt(r,"label"),Tt(r,"upperLabel"),Tt(r,"edgeLabel"),r.emphasis&&(Tt(r.emphasis,"label"),Tt(r.emphasis,"upperLabel"),Tt(r.emphasis,"edgeLabel"));var t=r.markPoint;t&&(Zl(t),fe(t));var e=r.markLine;e&&(Zl(e),fe(e));var i=r.markArea;i&&fe(i);var n=r.data;if(r.type==="graph"){n=n||r.nodes;var a=r.links||r.edges;if(a&&!jt(a))for(var o=0;o<a.length;o++)fe(a[o]);T(r.categories,function(u){Un(u)})}if(n&&!jt(n))for(var o=0;o<n.length;o++)fe(n[o]);if(t=r.markPoint,t&&t.data)for(var s=t.data,o=0;o<s.length;o++)fe(s[o]);if(e=r.markLine,e&&e.data)for(var l=e.data,o=0;o<l.length;o++)V(l[o])?(fe(l[o][0]),fe(l[o][1])):fe(l[o]);r.type==="gauge"?(Tt(r,"axisLabel"),Tt(r,"title"),Tt(r,"detail")):r.type==="treemap"?(zt(r.breadcrumb,"itemStyle"),T(r.levels,function(u){Un(u)})):r.type==="tree"&&Un(r.leaves)}}function $e(r){return V(r)?r:r?[r]:[]}function Hc(r){return(V(r)?r[0]:r)||{}}function Nb(r,t){ye($e(r.series),function(i){ya(i)&&Bb(i)});var e=["xAxis","yAxis","radiusAxis","angleAxis","singleAxis","parallelAxis","radar"];t&&e.push("valueAxis","categoryAxis","logAxis","timeAxis"),ye(e,function(i){ye($e(r[i]),function(n){n&&(Tt(n,"axisLabel"),Tt(n.axisPointer,"label"))})}),ye($e(r.parallel),function(i){var n=i&&i.parallelAxisDefault;Tt(n,"axisLabel"),Tt(n&&n.axisPointer,"label")}),ye($e(r.calendar),function(i){zt(i,"itemStyle"),Tt(i,"dayLabel"),Tt(i,"monthLabel"),Tt(i,"yearLabel")}),ye($e(r.radar),function(i){Tt(i,"name"),i.name&&i.axisName==null&&(i.axisName=i.name,delete i.name),i.nameGap!=null&&i.axisNameGap==null&&(i.axisNameGap=i.nameGap,delete i.nameGap)}),ye($e(r.geo),function(i){ya(i)&&(fe(i),ye($e(i.regions),function(n){fe(n)}))}),ye($e(r.timeline),function(i){fe(i),zt(i,"label"),zt(i,"itemStyle"),zt(i,"controlStyle",!0);var n=i.data;V(n)&&T(n,function(a){Z(a)&&(zt(a,"label"),zt(a,"itemStyle"))})}),ye($e(r.toolbox),function(i){zt(i,"iconStyle"),ye(i.feature,function(n){zt(n,"iconStyle")})}),Tt(Hc(r.axisPointer),"label"),Tt(Hc(r.tooltip).axisPointer,"label")}function Fb(r,t){for(var e=t.split(","),i=r,n=0;n<e.length&&(i=i&&i[e[n]],i!=null);n++);return i}function zb(r,t,e,i){for(var n=t.split(","),a=r,o,s=0;s<n.length-1;s++)o=n[s],a[o]==null&&(a[o]={}),a=a[o];a[n[s]]==null&&(a[n[s]]=e)}function Gc(r){r&&T(Hb,function(t){t[0]in r&&!(t[1]in r)&&(r[t[1]]=r[t[0]])})}var Hb=[["x","left"],["y","top"],["x2","right"],["y2","bottom"]],Gb=["grid","geo","parallel","legend","toolbox","title","visualMap","dataZoom","timeline"],Xl=[["borderRadius","barBorderRadius"],["borderColor","barBorderColor"],["borderWidth","barBorderWidth"]];function bn(r){var t=r&&r.itemStyle;if(t)for(var e=0;e<Xl.length;e++){var i=Xl[e][1],n=Xl[e][0];t[i]!=null&&(t[n]=t[i])}}function Vc(r){r&&r.alignTo==="edge"&&r.margin!=null&&r.edgeDistance==null&&(r.edgeDistance=r.margin)}function Wc(r){r&&r.downplay&&!r.blur&&(r.blur=r.downplay)}function Vb(r){r&&r.focusNodeAdjacency!=null&&(r.emphasis=r.emphasis||{},r.emphasis.focus==null&&(r.emphasis.focus="adjacency"))}function km(r,t){if(r)for(var e=0;e<r.length;e++)t(r[e]),r[e]&&km(r[e].children,t)}function Om(r,t){Nb(r,t),r.series=Yt(r.series),T(r.series,function(e){if(Z(e)){var i=e.type;if(i==="line")e.clipOverflow!=null&&(e.clip=e.clipOverflow);else if(i==="pie"||i==="gauge"){e.clockWise!=null&&(e.clockwise=e.clockWise),Vc(e.label);var n=e.data;if(n&&!jt(n))for(var a=0;a<n.length;a++)Vc(n[a]);e.hoverOffset!=null&&(e.emphasis=e.emphasis||{},(e.emphasis.scaleSize=null)&&(e.emphasis.scaleSize=e.hoverOffset))}else if(i==="gauge"){var o=Fb(e,"pointer.color");o!=null&&zb(e,"itemStyle.color",o)}else if(i==="bar"){bn(e),bn(e.backgroundStyle),bn(e.emphasis);var n=e.data;if(n&&!jt(n))for(var a=0;a<n.length;a++)typeof n[a]=="object"&&(bn(n[a]),bn(n[a]&&n[a].emphasis))}else if(i==="sunburst"){var s=e.highlightPolicy;s&&(e.emphasis=e.emphasis||{},e.emphasis.focus||(e.emphasis.focus=s)),Wc(e),km(e.data,Wc)}else i==="graph"||i==="sankey"?Vb(e):i==="map"&&(e.mapType&&!e.map&&(e.map=e.mapType),e.mapLocation&&ht(e,e.mapLocation));e.hoverAnimation!=null&&(e.emphasis=e.emphasis||{},e.emphasis&&e.emphasis.scale==null&&(e.emphasis.scale=e.hoverAnimation)),Gc(e)}}),r.dataRange&&(r.visualMap=r.dataRange),T(Gb,function(e){var i=r[e];i&&(V(i)||(i=[i]),T(i,function(n){Gc(n)}))})}function Wb(r){var t=Q();r.eachSeries(function(e){var i=e.get("stack");if(i){var n=t.get(i)||t.set(i,[]),a=e.getData(),o={stackResultDimension:a.getCalculationInfo("stackResultDimension"),stackedOverDimension:a.getCalculationInfo("stackedOverDimension"),stackedDimension:a.getCalculationInfo("stackedDimension"),stackedByDimension:a.getCalculationInfo("stackedByDimension"),isStackedByIndex:a.getCalculationInfo("isStackedByIndex"),data:a,seriesModel:e};if(!o.stackedDimension||!(o.isStackedByIndex||o.stackedByDimension))return;n.push(o)}}),t.each(function(e){if(e.length!==0){var i=e[0].seriesModel,n=i.get("stackOrder")||"seriesAsc";n==="seriesDesc"&&e.reverse(),T(e,function(a,o){a.data.setCalculationInfo("stackedOnSeries",o>0?e[o-1].seriesModel:null)}),Ub(e)}})}function Ub(r){T(r,function(t,e){var i=[],n=[NaN,NaN],a=[t.stackResultDimension,t.stackedOverDimension],o=t.data,s=t.isStackedByIndex,l=t.seriesModel.get("stackStrategy")||"samesign";o.modify(a,function(u,f,h){var c=o.get(t.stackedDimension,h);if(isNaN(c))return n;var v,d;s?d=o.getRawIndex(h):v=o.get(t.stackedByDimension,h);for(var g=NaN,m=e-1;m>=0;m--){var p=r[m];if(s||(d=p.data.rawIndexOf(p.stackedByDimension,v)),d>=0){var y=p.data.getByRawIndex(p.stackResultDimension,d);if(l==="all"||l==="positive"&&y>0||l==="negative"&&y<0||l==="samesign"&&c>=0&&y>0||l==="samesign"&&c<=0&&y<0){c=X1(c,y),g=y;break}}}return i[0]=c,i[1]=g,i})})}var $s=(function(){function r(t){this.data=t.data||(t.sourceFormat===Ze?{}:[]),this.sourceFormat=t.sourceFormat||Lm,this.seriesLayoutBy=t.seriesLayoutBy||Ge,this.startIndex=t.startIndex||0,this.dimensionsDetectedCount=t.dimensionsDetectedCount,this.metaRawOption=t.metaRawOption;var e=this.dimensionsDefine=t.dimensionsDefine;if(e)for(var i=0;i<e.length;i++){var n=e[i];n.type==null&&Rm(this,i)===ee.Must&&(n.type="ordinal")}}return r})();function Eh(r){return r instanceof $s}function ff(r,t,e){e=e||Nm(r);var i=t.seriesLayoutBy,n=Zb(r,e,i,t.sourceHeader,t.dimensions),a=new $s({data:r,sourceFormat:e,seriesLayoutBy:i,dimensionsDefine:n.dimensionsDefine,startIndex:n.startIndex,dimensionsDetectedCount:n.dimensionsDetectedCount,metaRawOption:it(t)});return a}function Bm(r){return new $s({data:r,sourceFormat:jt(r)?Tr:ae})}function Yb(r){return new $s({data:r.data,sourceFormat:r.sourceFormat,seriesLayoutBy:r.seriesLayoutBy,dimensionsDefine:it(r.dimensionsDefine),startIndex:r.startIndex,dimensionsDetectedCount:r.dimensionsDetectedCount})}function Nm(r){var t=Lm;if(jt(r))t=Tr;else if(V(r)){r.length===0&&(t=Ht);for(var e=0,i=r.length;e<i;e++){var n=r[e];if(n!=null){if(V(n)||jt(n)){t=Ht;break}else if(Z(n)){t=Me;break}}}}else if(Z(r)){for(var a in r)if(xe(r,a)&&Jt(r[a])){t=Ze;break}}return t}function Zb(r,t,e,i,n){var a,o;if(!r)return{dimensionsDefine:Uc(n),startIndex:o,dimensionsDetectedCount:a};if(t===Ht){var s=r;i==="auto"||i==null?Yc(function(u){u!=null&&u!=="-"&&(W(u)?o==null&&(o=1):o=0)},e,s,10):o=mt(i)?i:i?1:0,!n&&o===1&&(n=[],Yc(function(u,f){n[f]=u!=null?u+"":""},e,s,1/0)),a=n?n.length:e===Ci?s.length:s[0]?s[0].length:null}else if(t===Me)n||(n=Xb(r));else if(t===Ze)n||(n=[],T(r,function(u,f){n.push(f)}));else if(t===ae){var l=Pa(r[0]);a=V(l)&&l.length||1}return{startIndex:o,dimensionsDefine:Uc(n),dimensionsDetectedCount:a}}function Xb(r){for(var t=0,e;t<r.length&&!(e=r[t++]););if(e)return St(e)}function Uc(r){if(r){var t=Q();return K(r,function(e,i){e=Z(e)?e:{name:e};var n={name:e.name,displayName:e.displayName,type:e.type};if(n.name==null)return n;n.name+="",n.displayName==null&&(n.displayName=n.name);var a=t.get(n.name);return a?n.name+="-"+a.count++:t.set(n.name,{count:1}),n})}}function Yc(r,t,e,i){if(t===Ci)for(var n=0;n<e.length&&n<i;n++)r(e[n]?e[n][0]:null,n);else for(var a=e[0]||[],n=0;n<a.length&&n<i;n++)r(a[n],n)}function Fm(r){var t=r.sourceFormat;return t===Me||t===Ze}var ei,ri,ii,ni,Zc,Xc,zm=(function(){function r(t,e){var i=Eh(t)?t:Bm(t);this._source=i;var n=this._data=i.data,a=i.sourceFormat;i.seriesLayoutBy,a===Tr&&(this._offset=0,this._dimSize=e,this._data=n),Xc(this,n,i)}return r.prototype.getSource=function(){return this._source},r.prototype.count=function(){return 0},r.prototype.getItem=function(t,e){},r.prototype.appendData=function(t){},r.prototype.clean=function(){},r.protoInitialize=(function(){var t=r.prototype;t.pure=!1,t.persistent=!0})(),r.internalField=(function(){var t;Xc=function(o,s,l){var u=l.sourceFormat,f=l.seriesLayoutBy,h=l.startIndex,c=l.dimensionsDefine,v=Zc[kh(u,f)];if(O(o,v),u===Tr)o.getItem=e,o.count=n,o.fillStorage=i;else{var d=Hm(u,f);o.getItem=q(d,null,s,h,c);var g=Gm(u,f);o.count=q(g,null,s,h,c)}};var e=function(o,s){o=o-this._offset,s=s||[];for(var l=this._data,u=this._dimSize,f=u*o,h=0;h<u;h++)s[h]=l[f+h];return s},i=function(o,s,l,u){for(var f=this._data,h=this._dimSize,c=0;c<h;c++){for(var v=u[c],d=v[0]==null?1/0:v[0],g=v[1]==null?-1/0:v[1],m=s-o,p=l[c],y=0;y<m;y++){var _=f[y*h+c];p[o+y]=_,_<d&&(d=_),_>g&&(g=_)}v[0]=d,v[1]=g}},n=function(){return this._data?this._data.length/this._dimSize:0};Zc=(t={},t[Ht+"_"+Ge]={pure:!0,appendData:a},t[Ht+"_"+Ci]={pure:!0,appendData:function(){throw new Error('Do not support appendData when set seriesLayoutBy: "row".')}},t[Me]={pure:!0,appendData:a},t[Ze]={pure:!0,appendData:function(o){var s=this._data;T(o,function(l,u){for(var f=s[u]||(s[u]=[]),h=0;h<(l||[]).length;h++)f.push(l[h])})}},t[ae]={appendData:a},t[Tr]={persistent:!1,pure:!0,appendData:function(o){this._data=o},clean:function(){this._offset+=this.count(),this._data=null}},t);function a(o){for(var s=0;s<o.length;s++)this._data.push(o[s])}})(),r})(),fo=function(r){V(r)||bg("series.data or dataset.source must be an array.")};ei={},ei[Ht+"_"+Ge]=fo,ei[Ht+"_"+Ci]=fo,ei[Me]=fo,ei[Ze]=function(r,t){for(var e=0;e<t.length;e++){var i=t[e].name;i==null&&bg("dimension name must not be null/undefined.")}},ei[ae]=fo;var qc=function(r,t,e,i){return r[i]},qb=(ri={},ri[Ht+"_"+Ge]=function(r,t,e,i){return r[i+t]},ri[Ht+"_"+Ci]=function(r,t,e,i,n){i+=t;for(var a=n||[],o=r,s=0;s<o.length;s++){var l=o[s];a[s]=l?l[i]:null}return a},ri[Me]=qc,ri[Ze]=function(r,t,e,i,n){for(var a=n||[],o=0;o<e.length;o++){var s=e[o].name,l=s!=null?r[s]:null;a[o]=l?l[i]:null}return a},ri[ae]=qc,ri);function Hm(r,t){var e=qb[kh(r,t)];return e}var $c=function(r,t,e){return r.length},$b=(ii={},ii[Ht+"_"+Ge]=function(r,t,e){return Math.max(0,r.length-t)},ii[Ht+"_"+Ci]=function(r,t,e){var i=r[0];return i?Math.max(0,i.length-t):0},ii[Me]=$c,ii[Ze]=function(r,t,e){var i=e[0].name,n=i!=null?r[i]:null;return n?n.length:0},ii[ae]=$c,ii);function Gm(r,t){var e=$b[kh(r,t)];return e}var ql=function(r,t,e){return r[t]},Kb=(ni={},ni[Ht]=ql,ni[Me]=function(r,t,e){return r[e]},ni[Ze]=ql,ni[ae]=function(r,t,e){var i=Pa(r);return i instanceof Array?i[t]:i},ni[Tr]=ql,ni);function Vm(r){var t=Kb[r];return t}function kh(r,t){return r===Ht?r+"_"+t:r}function un(r,t,e){if(r){var i=r.getRawDataItem(t);if(i!=null){var n=r.getStore(),a=n.getSource().sourceFormat;if(e!=null){var o=r.getDimensionIndex(e),s=n.getDimensionProperty(o);return Vm(a)(i,o,s)}else{var l=i;return a===ae&&(l=Pa(i)),l}}}}var Qb=/\{@(.+?)\}/g,Jb=(function(){function r(){}return r.prototype.getDataParams=function(t,e){var i=this.getData(e),n=this.getRawValue(t,e),a=i.getRawIndex(t),o=i.getName(t),s=i.getRawDataItem(t),l=i.getItemVisual(t,"style"),u=l&&l[i.getItemVisual(t,"drawType")||"fill"],f=l&&l.stroke,h=this.mainType,c=h==="series",v=i.userOutput&&i.userOutput.get();return{componentType:h,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:o,dataIndex:a,data:s,dataType:e,value:n,color:u,borderColor:f,dimensionNames:v?v.fullDimensions:null,encode:v?v.encode:null,$vars:["seriesName","name","value"]}},r.prototype.getFormattedLabel=function(t,e,i,n,a,o){e=e||"normal";var s=this.getData(i),l=this.getDataParams(t,i);if(o&&(l.value=o.interpolatedValue),n!=null&&V(l.value)&&(l.value=l.value[n]),!a){var u=s.getItemModel(t);a=u.get(e==="normal"?["label","formatter"]:[e,"label","formatter"])}if(J(a))return l.status=e,l.dimensionIndex=n,a(l);if(W(a)){var f=Cm(a,l);return f.replace(Qb,function(h,c){var v=c.length,d=c;d.charAt(0)==="["&&d.charAt(v-1)==="]"&&(d=+d.slice(1,v-1));var g=un(s,t,d);if(o&&V(o.interpolatedValue)){var m=s.getDimensionIndex(d);m>=0&&(g=o.interpolatedValue[m])}return g!=null?g+"":""})}},r.prototype.getRawValue=function(t,e){return un(this.getData(e),t)},r.prototype.formatTooltip=function(t,e,i){},r})();function Kc(r){var t,e;return Z(r)?r.type&&(e=r):t=r,{text:t,frag:e}}function ia(r){return new jb(r)}var jb=(function(){function r(t){t=t||{},this._reset=t.reset,this._plan=t.plan,this._count=t.count,this._onDirty=t.onDirty,this._dirty=!0}return r.prototype.perform=function(t){var e=this._upstream,i=t&&t.skip;if(this._dirty&&e){var n=this.context;n.data=n.outputData=e.context.outputData}this.__pipeline&&(this.__pipeline.currentTask=this);var a;this._plan&&!i&&(a=this._plan(this.context));var o=f(this._modBy),s=this._modDataCount||0,l=f(t&&t.modBy),u=t&&t.modDataCount||0;(o!==l||s!==u)&&(a="reset");function f(y){return!(y>=1)&&(y=1),y}var h;(this._dirty||a==="reset")&&(this._dirty=!1,h=this._doReset(i)),this._modBy=l,this._modDataCount=u;var c=t&&t.step;if(e?this._dueEnd=e._outputDueEnd:this._dueEnd=this._count?this._count(this.context):1/0,this._progress){var v=this._dueIndex,d=Math.min(c!=null?this._dueIndex+c:1/0,this._dueEnd);if(!i&&(h||v<d)){var g=this._progress;if(V(g))for(var m=0;m<g.length;m++)this._doProgress(g[m],v,d,l,u);else this._doProgress(g,v,d,l,u)}this._dueIndex=d;var p=this._settedOutputEnd!=null?this._settedOutputEnd:d;this._outputDueEnd=p}else this._dueIndex=this._outputDueEnd=this._settedOutputEnd!=null?this._settedOutputEnd:this._dueEnd;return this.unfinished()},r.prototype.dirty=function(){this._dirty=!0,this._onDirty&&this._onDirty(this.context)},r.prototype._doProgress=function(t,e,i,n,a){Qc.reset(e,i,n,a),this._callingProgress=t,this._callingProgress({start:e,end:i,count:i-e,next:Qc.next},this.context)},r.prototype._doReset=function(t){this._dueIndex=this._outputDueEnd=this._dueEnd=0,this._settedOutputEnd=null;var e,i;!t&&this._reset&&(e=this._reset(this.context),e&&e.progress&&(i=e.forceFirstProgress,e=e.progress),V(e)&&!e.length&&(e=null)),this._progress=e,this._modBy=this._modDataCount=null;var n=this._downstream;return n&&n.dirty(),i},r.prototype.unfinished=function(){return this._progress&&this._dueIndex<this._dueEnd},r.prototype.pipe=function(t){(this._downstream!==t||this._dirty)&&(this._downstream=t,t._upstream=this,t.dirty())},r.prototype.dispose=function(){this._disposed||(this._upstream&&(this._upstream._downstream=null),this._downstream&&(this._downstream._upstream=null),this._dirty=!1,this._disposed=!0)},r.prototype.getUpstream=function(){return this._upstream},r.prototype.getDownstream=function(){return this._downstream},r.prototype.setOutputEnd=function(t){this._outputDueEnd=this._settedOutputEnd=t},r})(),Qc=(function(){var r,t,e,i,n,a={reset:function(l,u,f,h){t=l,r=u,e=f,i=h,n=Math.ceil(i/e),a.next=e>1&&i>0?s:o}};return a;function o(){return t<r?t++:null}function s(){var l=t%n*e+Math.ceil(t/n),u=t>=r?null:l<i?l:t;return t++,u}})();function Ho(r,t){var e=t&&t.type;return e==="ordinal"?r:(e==="time"&&!mt(r)&&r!=null&&r!=="-"&&(r=+dn(r)),r==null||r===""?NaN:Number(r))}Q({number:function(r){return parseFloat(r)},time:function(r){return+dn(r)},trim:function(r){return W(r)?ke(r):r}});var tT=(function(){function r(t,e){var i=t==="desc";this._resultLT=i?1:-1,e==null&&(e=i?"min":"max"),this._incomparable=e==="min"?-1/0:1/0}return r.prototype.evaluate=function(t,e){var i=mt(t)?t:ts(t),n=mt(e)?e:ts(e),a=isNaN(i),o=isNaN(n);if(a&&(i=this._incomparable),o&&(n=this._incomparable),a&&o){var s=W(t),l=W(e);s&&(i=l?t:0),l&&(n=s?e:0)}return i<n?this._resultLT:i>n?-this._resultLT:0},r})(),eT=(function(){function r(){}return r.prototype.getRawData=function(){throw new Error("not supported")},r.prototype.getRawDataItem=function(t){throw new Error("not supported")},r.prototype.cloneRawData=function(){},r.prototype.getDimensionInfo=function(t){},r.prototype.cloneAllDimensionInfo=function(){},r.prototype.count=function(){},r.prototype.retrieveValue=function(t,e){},r.prototype.retrieveValueFromItem=function(t,e){},r.prototype.convertValue=function(t,e){return Ho(t,e)},r})();function rT(r,t){var e=new eT,i=r.data,n=e.sourceFormat=r.sourceFormat,a=r.startIndex,o="";r.seriesLayoutBy!==Ge&&Kt(o);var s=[],l={},u=r.dimensionsDefine;if(u)T(u,function(g,m){var p=g.name,y={index:m,name:p,displayName:g.displayName};if(s.push(y),p!=null){var _="";xe(l,p)&&Kt(_),l[p]=y}});else for(var f=0;f<r.dimensionsDetectedCount;f++)s.push({index:f});var h=Hm(n,Ge);t.__isBuiltIn&&(e.getRawDataItem=function(g){return h(i,a,s,g)},e.getRawData=q(iT,null,r)),e.cloneRawData=q(nT,null,r);var c=Gm(n,Ge);e.count=q(c,null,i,a,s);var v=Vm(n);e.retrieveValue=function(g,m){var p=h(i,a,s,g);return d(p,m)};var d=e.retrieveValueFromItem=function(g,m){if(g!=null){var p=s[m];if(p)return v(g,m,p.name)}};return e.getDimensionInfo=q(aT,null,s,l),e.cloneAllDimensionInfo=q(oT,null,s),e}function iT(r){var t=r.sourceFormat;if(!Oh(t)){var e="";Kt(e)}return r.data}function nT(r){var t=r.sourceFormat,e=r.data;if(!Oh(t)){var i="";Kt(i)}if(t===Ht){for(var n=[],a=0,o=e.length;a<o;a++)n.push(e[a].slice());return n}else if(t===Me){for(var n=[],a=0,o=e.length;a<o;a++)n.push(O({},e[a]));return n}}function aT(r,t,e){if(e!=null){if(mt(e)||!isNaN(e)&&!xe(t,e))return r[e];if(xe(t,e))return t[e]}}function oT(r){return it(r)}var Wm=Q();function sT(r){r=it(r);var t=r.type,e="";t||Kt(e);var i=t.split(":");i.length!==2&&Kt(e);var n=!1;i[0]==="echarts"&&(t=i[1],n=!0),r.__isBuiltIn=n,Wm.set(t,r)}function lT(r,t,e){var i=Yt(r),n=i.length,a="";n||Kt(a);for(var o=0,s=n;o<s;o++){var l=i[o];t=uT(l,t),o!==s-1&&(t.length=Math.max(t.length,1))}return t}function uT(r,t,e,i){var n="";t.length||Kt(n),Z(r)||Kt(n);var a=r.type,o=Wm.get(a);o||Kt(n);var s=K(t,function(u){return rT(u,o)}),l=Yt(o.transform({upstream:s[0],upstreamList:s,config:it(r.config)}));return K(l,function(u,f){var h="";Z(u)||Kt(h),u.data||Kt(h);var c=Nm(u.data);Oh(c)||Kt(h);var v,d=t[0];if(d&&f===0&&!u.dimensions){var g=d.startIndex;g&&(u.data=d.data.slice(0,g).concat(u.data)),v={seriesLayoutBy:Ge,sourceHeader:g,dimensions:d.metaRawOption.dimensions}}else v={seriesLayoutBy:Ge,sourceHeader:0,dimensions:u.dimensions};return ff(u.data,v,null)})}function Oh(r){return r===Ht||r===Me}var Ks="undefined",fT=typeof Uint32Array===Ks?Array:Uint32Array,hT=typeof Uint16Array===Ks?Array:Uint16Array,Um=typeof Int32Array===Ks?Array:Int32Array,Jc=typeof Float64Array===Ks?Array:Float64Array,Ym={float:Jc,int:Um,ordinal:Array,number:Array,time:Jc},$l;function Ni(r){return r>65535?fT:hT}function Fi(){return[1/0,-1/0]}function vT(r){var t=r.constructor;return t===Array?r.slice():new t(r)}function jc(r,t,e,i,n){var a=Ym[e||"float"];if(n){var o=r[t],s=o&&o.length;if(s!==i){for(var l=new a(i),u=0;u<s;u++)l[u]=o[u];r[t]=l}}else r[t]=new a(i)}var hf=(function(){function r(){this._chunks=[],this._rawExtent=[],this._extent=[],this._count=0,this._rawCount=0,this._calcDimNameToIdx=Q()}return r.prototype.initData=function(t,e,i){this._provider=t,this._chunks=[],this._indices=null,this.getRawIndex=this._getRawIdxIdentity;var n=t.getSource(),a=this.defaultDimValueGetter=$l[n.sourceFormat];this._dimValueGetter=i||a,this._rawExtent=[],Fm(n),this._dimensions=K(e,function(o){return{type:o.type,property:o.property}}),this._initDataFromProvider(0,t.count())},r.prototype.getProvider=function(){return this._provider},r.prototype.getSource=function(){return this._provider.getSource()},r.prototype.ensureCalculationDimension=function(t,e){var i=this._calcDimNameToIdx,n=this._dimensions,a=i.get(t);if(a!=null){if(n[a].type===e)return a}else a=n.length;return n[a]={type:e},i.set(t,a),this._chunks[a]=new Ym[e||"float"](this._rawCount),this._rawExtent[a]=Fi(),a},r.prototype.collectOrdinalMeta=function(t,e){var i=this._chunks[t],n=this._dimensions[t],a=this._rawExtent,o=n.ordinalOffset||0,s=i.length;o===0&&(a[t]=Fi());for(var l=a[t],u=o;u<s;u++){var f=i[u]=e.parseAndCollect(i[u]);isNaN(f)||(l[0]=Math.min(f,l[0]),l[1]=Math.max(f,l[1]))}n.ordinalMeta=e,n.ordinalOffset=s,n.type="ordinal"},r.prototype.getOrdinalMeta=function(t){var e=this._dimensions[t],i=e.ordinalMeta;return i},r.prototype.getDimensionProperty=function(t){var e=this._dimensions[t];return e&&e.property},r.prototype.appendData=function(t){var e=this._provider,i=this.count();e.appendData(t);var n=e.count();return e.persistent||(n+=i),i<n&&this._initDataFromProvider(i,n,!0),[i,n]},r.prototype.appendValues=function(t,e){for(var i=this._chunks,n=this._dimensions,a=n.length,o=this._rawExtent,s=this.count(),l=s+Math.max(t.length,e||0),u=0;u<a;u++){var f=n[u];jc(i,u,f.type,l,!0)}for(var h=[],c=s;c<l;c++)for(var v=c-s,d=0;d<a;d++){var f=n[d],g=$l.arrayRows.call(this,t[v]||h,f.property,v,d);i[d][c]=g;var m=o[d];g<m[0]&&(m[0]=g),g>m[1]&&(m[1]=g)}return this._rawCount=this._count=l,{start:s,end:l}},r.prototype._initDataFromProvider=function(t,e,i){for(var n=this._provider,a=this._chunks,o=this._dimensions,s=o.length,l=this._rawExtent,u=K(o,function(y){return y.property}),f=0;f<s;f++){var h=o[f];l[f]||(l[f]=Fi()),jc(a,f,h.type,e,i)}if(n.fillStorage)n.fillStorage(t,e,a,l);else for(var c=[],v=t;v<e;v++){c=n.getItem(v,c);for(var d=0;d<s;d++){var g=a[d],m=this._dimValueGetter(c,u[d],v,d);g[v]=m;var p=l[d];m<p[0]&&(p[0]=m),m>p[1]&&(p[1]=m)}}!n.persistent&&n.clean&&n.clean(),this._rawCount=this._count=e,this._extent=[]},r.prototype.count=function(){return this._count},r.prototype.get=function(t,e){if(!(e>=0&&e<this._count))return NaN;var i=this._chunks[t];return i?i[this.getRawIndex(e)]:NaN},r.prototype.getValues=function(t,e){var i=[],n=[];if(e==null){e=t,t=[];for(var a=0;a<this._dimensions.length;a++)n.push(a)}else n=t;for(var a=0,o=n.length;a<o;a++)i.push(this.get(n[a],e));return i},r.prototype.getByRawIndex=function(t,e){if(!(e>=0&&e<this._rawCount))return NaN;var i=this._chunks[t];return i?i[e]:NaN},r.prototype.getSum=function(t){var e=this._chunks[t],i=0;if(e)for(var n=0,a=this.count();n<a;n++){var o=this.get(t,n);isNaN(o)||(i+=o)}return i},r.prototype.getMedian=function(t){var e=[];this.each([t],function(a){isNaN(a)||e.push(a)});var i=e.sort(function(a,o){return a-o}),n=this.count();return n===0?0:n%2===1?i[(n-1)/2]:(i[n/2]+i[n/2-1])/2},r.prototype.indexOfRawIndex=function(t){if(t>=this._rawCount||t<0)return-1;if(!this._indices)return t;var e=this._indices,i=e[t];if(i!=null&&i<this._count&&i===t)return t;for(var n=0,a=this._count-1;n<=a;){var o=(n+a)/2|0;if(e[o]<t)n=o+1;else if(e[o]>t)a=o-1;else return o}return-1},r.prototype.getIndices=function(){var t,e=this._indices;if(e){var i=e.constructor,n=this._count;if(i===Array){t=new i(n);for(var a=0;a<n;a++)t[a]=e[a]}else t=new i(e.buffer,0,n)}else{var i=Ni(this._rawCount);t=new i(this.count());for(var a=0;a<t.length;a++)t[a]=a}return t},r.prototype.filter=function(t,e){if(!this._count)return this;for(var i=this.clone(),n=i.count(),a=Ni(i._rawCount),o=new a(n),s=[],l=t.length,u=0,f=t[0],h=i._chunks,c=0;c<n;c++){var v=void 0,d=i.getRawIndex(c);if(l===0)v=e(c);else if(l===1){var g=h[f][d];v=e(g,c)}else{for(var m=0;m<l;m++)s[m]=h[t[m]][d];s[m]=c,v=e.apply(null,s)}v&&(o[u++]=d)}return u<n&&(i._indices=o),i._count=u,i._extent=[],i._updateGetRawIdx(),i},r.prototype.selectRange=function(t){var e=this.clone(),i=e._count;if(!i)return this;var n=St(t),a=n.length;if(!a)return this;var o=e.count(),s=Ni(e._rawCount),l=new s(o),u=0,f=n[0],h=t[f][0],c=t[f][1],v=e._chunks,d=!1;if(!e._indices){var g=0;if(a===1){for(var m=v[n[0]],p=0;p<i;p++){var y=m[p];(y>=h&&y<=c||isNaN(y))&&(l[u++]=g),g++}d=!0}else if(a===2){for(var m=v[n[0]],_=v[n[1]],S=t[n[1]][0],x=t[n[1]][1],p=0;p<i;p++){var y=m[p],w=_[p];(y>=h&&y<=c||isNaN(y))&&(w>=S&&w<=x||isNaN(w))&&(l[u++]=g),g++}d=!0}}if(!d)if(a===1)for(var p=0;p<o;p++){var b=e.getRawIndex(p),y=v[n[0]][b];(y>=h&&y<=c||isNaN(y))&&(l[u++]=b)}else for(var p=0;p<o;p++){for(var D=!0,b=e.getRawIndex(p),C=0;C<a;C++){var M=n[C],y=v[M][b];(y<t[M][0]||y>t[M][1])&&(D=!1)}D&&(l[u++]=e.getRawIndex(p))}return u<o&&(e._indices=l),e._count=u,e._extent=[],e._updateGetRawIdx(),e},r.prototype.map=function(t,e){var i=this.clone(t);return this._updateDims(i,t,e),i},r.prototype.modify=function(t,e){this._updateDims(this,t,e)},r.prototype._updateDims=function(t,e,i){for(var n=t._chunks,a=[],o=e.length,s=t.count(),l=[],u=t._rawExtent,f=0;f<e.length;f++)u[e[f]]=Fi();for(var h=0;h<s;h++){for(var c=t.getRawIndex(h),v=0;v<o;v++)l[v]=n[e[v]][c];l[o]=h;var d=i&&i.apply(null,l);if(d!=null){typeof d!="object"&&(a[0]=d,d=a);for(var f=0;f<d.length;f++){var g=e[f],m=d[f],p=u[g],y=n[g];y&&(y[c]=m),m<p[0]&&(p[0]=m),m>p[1]&&(p[1]=m)}}}},r.prototype.lttbDownSample=function(t,e){var i=this.clone([t],!0),n=i._chunks,a=n[t],o=this.count(),s=0,l=Math.floor(1/e),u=this.getRawIndex(0),f,h,c,v=new(Ni(this._rawCount))(Math.min((Math.ceil(o/l)+2)*2,o));v[s++]=u;for(var d=1;d<o-1;d+=l){for(var g=Math.min(d+l,o-1),m=Math.min(d+l*2,o),p=(m+g)/2,y=0,_=g;_<m;_++){var S=this.getRawIndex(_),x=a[S];isNaN(x)||(y+=x)}y/=m-g;var w=d,b=Math.min(d+l,o),D=d-1,C=a[u];f=-1,c=w;for(var M=-1,A=0,_=w;_<b;_++){var S=this.getRawIndex(_),x=a[S];if(isNaN(x)){A++,M<0&&(M=S);continue}h=Math.abs((D-p)*(x-C)-(D-_)*(y-C)),h>f&&(f=h,c=S)}A>0&&A<b-w&&(v[s++]=Math.min(M,c),c=Math.max(M,c)),v[s++]=c,u=c}return v[s++]=this.getRawIndex(o-1),i._count=s,i._indices=v,i.getRawIndex=this._getRawIdx,i},r.prototype.minmaxDownSample=function(t,e){for(var i=this.clone([t],!0),n=i._chunks,a=Math.floor(1/e),o=n[t],s=this.count(),l=new(Ni(this._rawCount))(Math.ceil(s/a)*2),u=0,f=0;f<s;f+=a){var h=f,c=o[this.getRawIndex(h)],v=f,d=o[this.getRawIndex(v)],g=a;f+a>s&&(g=s-f);for(var m=0;m<g;m++){var p=this.getRawIndex(f+m),y=o[p];y<c&&(c=y,h=f+m),y>d&&(d=y,v=f+m)}var _=this.getRawIndex(h),S=this.getRawIndex(v);h<v?(l[u++]=_,l[u++]=S):(l[u++]=S,l[u++]=_)}return i._count=u,i._indices=l,i._updateGetRawIdx(),i},r.prototype.downSample=function(t,e,i,n){for(var a=this.clone([t],!0),o=a._chunks,s=[],l=Math.floor(1/e),u=o[t],f=this.count(),h=a._rawExtent[t]=Fi(),c=new(Ni(this._rawCount))(Math.ceil(f/l)),v=0,d=0;d<f;d+=l){l>f-d&&(l=f-d,s.length=l);for(var g=0;g<l;g++){var m=this.getRawIndex(d+g);s[g]=u[m]}var p=i(s),y=this.getRawIndex(Math.min(d+n(s,p)||0,f-1));u[y]=p,p<h[0]&&(h[0]=p),p>h[1]&&(h[1]=p),c[v++]=y}return a._count=v,a._indices=c,a._updateGetRawIdx(),a},r.prototype.each=function(t,e){if(this._count)for(var i=t.length,n=this._chunks,a=0,o=this.count();a<o;a++){var s=this.getRawIndex(a);switch(i){case 0:e(a);break;case 1:e(n[t[0]][s],a);break;case 2:e(n[t[0]][s],n[t[1]][s],a);break;default:for(var l=0,u=[];l<i;l++)u[l]=n[t[l]][s];u[l]=a,e.apply(null,u)}}},r.prototype.getDataExtent=function(t){var e=this._chunks[t],i=Fi();if(!e)return i;var n=this.count(),a=!this._indices,o;if(a)return this._rawExtent[t].slice();if(o=this._extent[t],o)return o.slice();o=i;for(var s=o[0],l=o[1],u=0;u<n;u++){var f=this.getRawIndex(u),h=e[f];h<s&&(s=h),h>l&&(l=h)}return o=[s,l],this._extent[t]=o,o},r.prototype.getRawDataItem=function(t){var e=this.getRawIndex(t);if(this._provider.persistent)return this._provider.getItem(e);for(var i=[],n=this._chunks,a=0;a<n.length;a++)i.push(n[a][e]);return i},r.prototype.clone=function(t,e){var i=new r,n=this._chunks,a=t&&vn(t,function(s,l){return s[l]=!0,s},{});if(a)for(var o=0;o<n.length;o++)i._chunks[o]=a[o]?vT(n[o]):n[o];else i._chunks=n;return this._copyCommonProps(i),e||(i._indices=this._cloneIndices()),i._updateGetRawIdx(),i},r.prototype._copyCommonProps=function(t){t._count=this._count,t._rawCount=this._rawCount,t._provider=this._provider,t._dimensions=this._dimensions,t._extent=it(this._extent),t._rawExtent=it(this._rawExtent)},r.prototype._cloneIndices=function(){if(this._indices){var t=this._indices.constructor,e=void 0;if(t===Array){var i=this._indices.length;e=new t(i);for(var n=0;n<i;n++)e[n]=this._indices[n]}else e=new t(this._indices);return e}return null},r.prototype._getRawIdxIdentity=function(t){return t},r.prototype._getRawIdx=function(t){return t<this._count&&t>=0?this._indices[t]:-1},r.prototype._updateGetRawIdx=function(){this.getRawIndex=this._indices?this._getRawIdx:this._getRawIdxIdentity},r.internalField=(function(){function t(e,i,n,a){return Ho(e[a],this._dimensions[a])}$l={arrayRows:t,objectRows:function(e,i,n,a){return Ho(e[i],this._dimensions[a])},keyedColumns:t,original:function(e,i,n,a){var o=e&&(e.value==null?e:e.value);return Ho(o instanceof Array?o[a]:o,this._dimensions[a])},typedArray:function(e,i,n,a){return e[a]}}})(),r})(),cT=(function(){function r(t){this._sourceList=[],this._storeList=[],this._upstreamSignList=[],this._versionSignBase=0,this._dirty=!0,this._sourceHost=t}return r.prototype.dirty=function(){this._setLocalSource([],[]),this._storeList=[],this._dirty=!0},r.prototype._setLocalSource=function(t,e){this._sourceList=t,this._upstreamSignList=e,this._versionSignBase++,this._versionSignBase>9e10&&(this._versionSignBase=0)},r.prototype._getVersionSign=function(){return this._sourceHost.uid+"_"+this._versionSignBase},r.prototype.prepareSource=function(){this._isDirty()&&(this._createSource(),this._dirty=!1)},r.prototype._createSource=function(){this._setLocalSource([],[]);var t=this._sourceHost,e=this._getUpstreamSourceManagers(),i=!!e.length,n,a;if(ho(t)){var o=t,s=void 0,l=void 0,u=void 0;if(i){var f=e[0];f.prepareSource(),u=f.getSource(),s=u.data,l=u.sourceFormat,a=[f._getVersionSign()]}else s=o.get("data",!0),l=jt(s)?Tr:ae,a=[];var h=this._getSourceMetaRawOption()||{},c=u&&u.metaRawOption||{},v=$(h.seriesLayoutBy,c.seriesLayoutBy)||null,d=$(h.sourceHeader,c.sourceHeader),g=$(h.dimensions,c.dimensions),m=v!==c.seriesLayoutBy||!!d!=!!c.sourceHeader||g;n=m?[ff(s,{seriesLayoutBy:v,sourceHeader:d,dimensions:g},l)]:[]}else{var p=t;if(i){var y=this._applyTransform(e);n=y.sourceList,a=y.upstreamSignList}else{var _=p.get("source",!0);n=[ff(_,this._getSourceMetaRawOption(),null)],a=[]}}this._setLocalSource(n,a)},r.prototype._applyTransform=function(t){var e=this._sourceHost,i=e.get("transform",!0),n=e.get("fromTransformResult",!0);if(n!=null){var a="";t.length!==1&&td(a)}var o,s=[],l=[];return T(t,function(u){u.prepareSource();var f=u.getSource(n||0),h="";n!=null&&!f&&td(h),s.push(f),l.push(u._getVersionSign())}),i?o=lT(i,s,{datasetIndex:e.componentIndex}):n!=null&&(o=[Yb(s[0])]),{sourceList:o,upstreamSignList:l}},r.prototype._isDirty=function(){if(this._dirty)return!0;for(var t=this._getUpstreamSourceManagers(),e=0;e<t.length;e++){var i=t[e];if(i._isDirty()||this._upstreamSignList[e]!==i._getVersionSign())return!0}},r.prototype.getSource=function(t){t=t||0;var e=this._sourceList[t];if(!e){var i=this._getUpstreamSourceManagers();return i[0]&&i[0].getSource(t)}return e},r.prototype.getSharedDataStore=function(t){var e=t.makeStoreSchema();return this._innerGetDataStore(e.dimensions,t.source,e.hash)},r.prototype._innerGetDataStore=function(t,e,i){var n=0,a=this._storeList,o=a[n];o||(o=a[n]={});var s=o[i];if(!s){var l=this._getUpstreamSourceManagers()[0];ho(this._sourceHost)&&l?s=l._innerGetDataStore(t,e,i):(s=new hf,s.initData(new zm(e,t.length),t)),o[i]=s}return s},r.prototype._getUpstreamSourceManagers=function(){var t=this._sourceHost;if(ho(t)){var e=Pm(t);return e?[e.getSourceManager()]:[]}else return K(_b(t),function(i){return i.getSourceManager()})},r.prototype._getSourceMetaRawOption=function(){var t=this._sourceHost,e,i,n;if(ho(t))e=t.get("seriesLayoutBy",!0),i=t.get("sourceHeader",!0),n=t.get("dimensions",!0);else if(!this._getUpstreamSourceManagers().length){var a=t;e=a.get("seriesLayoutBy",!0),i=a.get("sourceHeader",!0),n=a.get("dimensions",!0)}return{seriesLayoutBy:e,sourceHeader:i,dimensions:n}},r})();function ho(r){return r.mainType==="series"}function td(r){throw new Error(r)}var dT="line-height:1";function Zm(r){var t=r.lineHeight;return t==null?dT:"line-height:"+qt(t+"")+"px"}function Xm(r,t){var e=r.color||H.color.tertiary,i=r.fontSize||12,n=r.fontWeight||"400",a=r.color||H.color.secondary,o=r.fontSize||14,s=r.fontWeight||"900";return t==="html"?{nameStyle:"font-size:"+qt(i+"")+"px;color:"+qt(e)+";font-weight:"+qt(n+""),valueStyle:"font-size:"+qt(o+"")+"px;color:"+qt(a)+";font-weight:"+qt(s+"")}:{nameStyle:{fontSize:i,fill:e,fontWeight:n},valueStyle:{fontSize:o,fill:a,fontWeight:s}}}var pT=[0,10,20,30],gT=["",`
30
+ `,`
31
+
32
+ `,`
33
+
34
+
35
+ `];function _a(r,t){return t.type=r,t}function vf(r){return r.type==="section"}function qm(r){return vf(r)?mT:yT}function $m(r){if(vf(r)){var t=0,e=r.blocks.length,i=e>1||e>0&&!r.noHeader;return T(r.blocks,function(n){var a=$m(n);a>=t&&(t=a+ +(i&&(!a||vf(n)&&!n.noHeader)))}),t}return 0}function mT(r,t,e,i){var n=t.noHeader,a=_T($m(t)),o=[],s=t.blocks||[];nr(!s||V(s)),s=s||[];var l=r.orderMode;if(t.sortBlocks&&l){s=s.slice();var u={valueAsc:"asc",valueDesc:"desc"};if(xe(u,l)){var f=new tT(u[l],null);s.sort(function(g,m){return f.evaluate(g.sortParam,m.sortParam)})}else l==="seriesDesc"&&s.reverse()}T(s,function(g,m){var p=t.valueFormatter,y=qm(g)(p?O(O({},r),{valueFormatter:p}):r,g,m>0?a.html:0,i);y!=null&&o.push(y)});var h=r.renderMode==="richText"?o.join(a.richText):cf(i,o.join(""),n?e:a.html);if(n)return h;var c=uf(t.header,"ordinal",r.useUTC),v=Xm(i,r.renderMode).nameStyle,d=Zm(i);return r.renderMode==="richText"?Km(r,c,v)+a.richText+h:cf(i,'<div style="'+v+";"+d+';">'+qt(c)+"</div>"+h,e)}function yT(r,t,e,i){var n=r.renderMode,a=t.noName,o=t.noValue,s=!t.markerType,l=t.name,u=r.useUTC,f=t.valueFormatter||r.valueFormatter||function(S){return S=V(S)?S:[S],K(S,function(x,w){return uf(x,V(v)?v[w]:v,u)})};if(!(a&&o)){var h=s?"":r.markupStyleCreator.makeTooltipMarker(t.markerType,t.markerColor||H.color.secondary,n),c=a?"":uf(l,"ordinal",u),v=t.valueType,d=o?[]:f(t.value,t.dataIndex),g=!s||!a,m=!s&&a,p=Xm(i,n),y=p.nameStyle,_=p.valueStyle;return n==="richText"?(s?"":h)+(a?"":Km(r,c,y))+(o?"":xT(r,d,g,m,_)):cf(i,(s?"":h)+(a?"":ST(c,!s,y))+(o?"":wT(d,g,m,_)),e)}}function ed(r,t,e,i,n,a){if(r){var o=qm(r),s={useUTC:n,renderMode:e,orderMode:i,markupStyleCreator:t,valueFormatter:r.valueFormatter};return o(s,r,0,a)}}function _T(r){return{html:pT[r],richText:gT[r]}}function cf(r,t,e){var i='<div style="clear:both"></div>',n="margin: "+e+"px 0 0",a=Zm(r);return'<div style="'+n+";"+a+';">'+t+i+"</div>"}function ST(r,t,e){var i=t?"margin-left:2px":"";return'<span style="'+e+";"+i+'">'+qt(r)+"</span>"}function wT(r,t,e,i){var n=e?"10px":"20px",a=t?"float:right;margin-left:"+n:"";return r=V(r)?r:[r],'<span style="'+a+";"+i+'">'+K(r,function(o){return qt(o)}).join("&nbsp;&nbsp;")+"</span>"}function Km(r,t,e){return r.markupStyleCreator.wrapRichTextStyle(t,e)}function xT(r,t,e,i,n){var a=[n],o=i?10:20;return e&&a.push({padding:[0,0,0,o],align:"right"}),r.markupStyleCreator.wrapRichTextStyle(V(t)?t.join(" "):t,a)}function bT(r,t){var e=r.getData().getItemVisual(t,"style"),i=e[r.visualDrawType];return bi(i)}function Qm(r,t){var e=r.get("padding");return e??(t==="richText"?[8,10]:10)}var Kl=(function(){function r(){this.richTextStyles={},this._nextStyleNameId=wg()}return r.prototype._generateStyleName=function(){return"__EC_aUTo_"+this._nextStyleNameId++},r.prototype.makeTooltipMarker=function(t,e,i){var n=i==="richText"?this._generateStyleName():null,a=nb({color:e,type:t,renderMode:i,markerId:n});return W(a)?a:(this.richTextStyles[n]=a.style,a.content)},r.prototype.wrapRichTextStyle=function(t,e){var i={};V(e)?T(e,function(a){return O(i,a)}):O(i,e);var n=this._generateStyleName();return this.richTextStyles[n]=i,"{"+n+"|"+t+"}"},r})();function TT(r){var t=r.series,e=r.dataIndex,i=r.multipleSeries,n=t.getData(),a=n.mapDimensionsAll("defaultedTooltip"),o=a.length,s=t.getRawValue(e),l=V(s),u=bT(t,e),f,h,c,v;if(o>1||l&&!o){var d=CT(s,t,e,a,u);f=d.inlineValues,h=d.inlineValueTypes,c=d.blocks,v=d.inlineValues[0]}else if(o){var g=n.getDimensionInfo(a[0]);v=f=un(n,e,a[0]),h=g.type}else v=f=l?s[0]:s;var m=Jf(t),p=m&&t.name||"",y=n.getName(e),_=i?p:y;return _a("section",{header:p,noHeader:i||!m,sortParam:v,blocks:[_a("nameValue",{markerType:"item",markerColor:u,name:_,noName:!ke(_),value:f,valueType:h,dataIndex:e})].concat(c||[])})}function CT(r,t,e,i,n){var a=t.getData(),o=vn(r,function(h,c,v){var d=a.getDimensionInfo(v);return h=h||d&&d.tooltip!==!1&&d.displayName!=null},!1),s=[],l=[],u=[];i.length?T(i,function(h){f(un(a,e,h),h)}):T(r,f);function f(h,c){var v=a.getDimensionInfo(c);!v||v.otherDims.tooltip===!1||(o?u.push(_a("nameValue",{markerType:"subItem",markerColor:n,name:v.displayName,value:h,valueType:v.type})):(s.push(h),l.push(v.type)))}return{inlineValues:s,inlineValueTypes:l,blocks:u}}var hr=yt();function vo(r,t){return r.getName(t)||r.getId(t)}var MT="__universalTransitionEnabled",Ir=(function(r){B(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e._selectedDataIndicesMap={},e}return t.prototype.init=function(e,i,n){this.seriesIndex=this.componentIndex,this.dataTask=ia({count:AT,reset:LT}),this.dataTask.context={model:this},this.mergeDefaultAndTheme(e,n);var a=hr(this).sourceManager=new cT(this);a.prepareSource();var o=this.getInitialData(e,n);id(o,this),this.dataTask.context.data=o,hr(this).dataBeforeProcessed=o,rd(this),this._initSelectedMapFromData(o)},t.prototype.mergeDefaultAndTheme=function(e,i){var n=ma(this),a=n?pn(e):{},o=this.subType;ut.hasClass(o)&&(o+="Series"),st(e,i.getTheme().get(this.subType)),st(e,this.getDefaultOption()),kv(e,"label",["show"]),this.fillDataTextStyle(e.data),n&&Lr(e,a,n)},t.prototype.mergeOption=function(e,i){e=st(this.option,e,!0),this.fillDataTextStyle(e.data);var n=ma(this);n&&Lr(this.option,e,n);var a=hr(this).sourceManager;a.dirty(),a.prepareSource();var o=this.getInitialData(e,i);id(o,this),this.dataTask.dirty(),this.dataTask.context.data=o,hr(this).dataBeforeProcessed=o,rd(this),this._initSelectedMapFromData(o)},t.prototype.fillDataTextStyle=function(e){if(e&&!jt(e))for(var i=["show"],n=0;n<e.length;n++)e[n]&&e[n].label&&kv(e[n],"label",i)},t.prototype.getInitialData=function(e,i){},t.prototype.appendData=function(e){var i=this.getRawData();i.appendData(e.data)},t.prototype.getData=function(e){var i=df(this);if(i){var n=i.context.data;return e==null||!n.getLinkedData?n:n.getLinkedData(e)}else return hr(this).data},t.prototype.getAllData=function(){var e=this.getData();return e&&e.getLinkedDataAll?e.getLinkedDataAll():[{data:e}]},t.prototype.setData=function(e){var i=df(this);if(i){var n=i.context;n.outputData=e,i!==this.dataTask&&(n.data=e)}hr(this).data=e},t.prototype.getEncode=function(){var e=this.get("encode",!0);if(e)return Q(e)},t.prototype.getSourceManager=function(){return hr(this).sourceManager},t.prototype.getSource=function(){return this.getSourceManager().getSource()},t.prototype.getRawData=function(){return hr(this).dataBeforeProcessed},t.prototype.getColorBy=function(){var e=this.get("colorBy");return e||"series"},t.prototype.isColorBySeries=function(){return this.getColorBy()==="series"},t.prototype.getBaseAxis=function(){var e=this.coordinateSystem;return e&&e.getBaseAxis&&e.getBaseAxis()},t.prototype.indicesOfNearest=function(e,i,n,a){var o=this.getData(),s=this.coordinateSystem,l=s&&s.getAxis(e);if(!s||!l)return[];var u=l.dataToCoord(n);a==null&&(a=1/0);var f=[],h=1/0,c=-1,v=0;return o.each(i,function(d,g){var m=l.dataToCoord(d),p=u-m,y=Math.abs(p);y<=a&&((y<h||y===h&&p>=0&&c<0)&&(h=y,c=p,v=0),p===c&&(f[v++]=g))}),f.length=v,f},t.prototype.formatTooltip=function(e,i,n){return TT({series:this,dataIndex:e,multipleSeries:i})},t.prototype.isAnimationEnabled=function(){var e=this.ecModel;if(j.node&&!(e&&e.ssr))return!1;var i=this.getShallow("animation");return i&&this.getData().count()>this.getShallow("animationThreshold")&&(i=!1),!!i},t.prototype.restoreData=function(){this.dataTask.dirty()},t.prototype.getColorFromPalette=function(e,i,n){var a=this.ecModel,o=Ph.prototype.getColorFromPalette.call(this,e,i,n);return o||(o=a.getColorFromPalette(e,i,n)),o},t.prototype.coordDimToDataDim=function(e){return this.getRawData().mapDimensionsAll(e)},t.prototype.getProgressive=function(){return this.get("progressive")},t.prototype.getProgressiveThreshold=function(){return this.get("progressiveThreshold")},t.prototype.select=function(e,i){this._innerSelect(this.getData(i),e)},t.prototype.unselect=function(e,i){var n=this.option.selectedMap;if(n){var a=this.option.selectedMode,o=this.getData(i);if(a==="series"||n==="all"){this.option.selectedMap={},this._selectedDataIndicesMap={};return}for(var s=0;s<e.length;s++){var l=e[s],u=vo(o,l);n[u]=!1,this._selectedDataIndicesMap[u]=-1}}},t.prototype.toggleSelect=function(e,i){for(var n=[],a=0;a<e.length;a++)n[0]=e[a],this.isSelected(e[a],i)?this.unselect(n,i):this.select(n,i)},t.prototype.getSelectedDataIndices=function(){if(this.option.selectedMap==="all")return[].slice.call(this.getData().getIndices());for(var e=this._selectedDataIndicesMap,i=St(e),n=[],a=0;a<i.length;a++){var o=e[i[a]];o>=0&&n.push(o)}return n},t.prototype.isSelected=function(e,i){var n=this.option.selectedMap;if(!n)return!1;var a=this.getData(i);return(n==="all"||n[vo(a,e)])&&!a.getItemModel(e).get(["select","disabled"])},t.prototype.isUniversalTransitionEnabled=function(){if(this[MT])return!0;var e=this.option.universalTransition;return e?e===!0?!0:e&&e.enabled:!1},t.prototype._innerSelect=function(e,i){var n,a,o=this.option,s=o.selectedMode,l=i.length;if(!(!s||!l)){if(s==="series")o.selectedMap="all";else if(s==="multiple"){Z(o.selectedMap)||(o.selectedMap={});for(var u=o.selectedMap,f=0;f<l;f++){var h=i[f],c=vo(e,h);u[c]=!0,this._selectedDataIndicesMap[c]=e.getRawIndex(h)}}else if(s==="single"||s===!0){var v=i[l-1],c=vo(e,v);o.selectedMap=(n={},n[c]=!0,n),this._selectedDataIndicesMap=(a={},a[c]=e.getRawIndex(v),a)}}},t.prototype._initSelectedMapFromData=function(e){if(!this.option.selectedMap){var i=[];e.hasItemOption&&e.each(function(n){var a=e.getRawDataItem(n);a&&a.selected&&i.push(n)}),i.length>0&&this._innerSelect(e,i)}},t.registerClass=function(e){return ut.registerClass(e)},t.protoInitialize=(function(){var e=t.prototype;e.type="series.__base__",e.seriesIndex=0,e.ignoreStyleOnData=!1,e.hasSymbolVisual=!1,e.defaultSymbol="circle",e.visualStyleAccessPath="itemStyle",e.visualDrawType="fill"})(),t})(ut);Ye(Ir,Jb);Ye(Ir,Ph);Ag(Ir,ut);function rd(r){var t=r.name;Jf(r)||(r.name=DT(r)||t)}function DT(r){var t=r.getRawData(),e=t.mapDimensionsAll("seriesName"),i=[];return T(e,function(n){var a=t.getDimensionInfo(n);a.displayName&&i.push(a.displayName)}),i.join(" ")}function AT(r){return r.model.getRawData().count()}function LT(r){var t=r.model;return t.setData(t.getRawData().cloneShallow()),IT}function IT(r,t){t.outputData&&r.end>t.outputData.count()&&t.model.getRawData().cloneShallow(t.outputData)}function id(r,t){T(T_(r.CHANGABLE_METHODS,r.DOWNSAMPLE_METHODS),function(e){r.wrapMethod(e,Mt(PT,t))})}function PT(r,t){var e=df(r);return e&&e.setOutputEnd((t||this).count()),t}function df(r){var t=(r.ecModel||{}).scheduler,e=t&&t.getPipeline(r.uid);if(e){var i=e.currentTask;if(i){var n=i.agentStubMap;n&&(i=n.get(r.uid))}return i}}var me=(function(){function r(){this.group=new Dt,this.uid=Ys("viewComponent")}return r.prototype.init=function(t,e){},r.prototype.render=function(t,e,i,n){},r.prototype.dispose=function(t,e){},r.prototype.updateView=function(t,e,i,n){},r.prototype.updateLayout=function(t,e,i,n){},r.prototype.updateVisual=function(t,e,i,n){},r.prototype.toggleBlurSeries=function(t,e,i){},r.prototype.eachRendered=function(t){var e=this.group;e&&e.traverse(t)},r})();th(me);Rs(me);function Jm(){var r=yt();return function(t){var e=r(t),i=t.pipelineContext,n=!!e.large,a=!!e.progressiveRender,o=e.large=!!(i&&i.large),s=e.progressiveRender=!!(i&&i.progressiveRender);return(n!==o||a!==s)&&"reset"}}var jm=yt(),RT=Jm(),Ve=(function(){function r(){this.group=new Dt,this.uid=Ys("viewChart"),this.renderTask=ia({plan:ET,reset:kT}),this.renderTask.context={view:this}}return r.prototype.init=function(t,e){},r.prototype.render=function(t,e,i,n){},r.prototype.highlight=function(t,e,i,n){var a=t.getData(n&&n.dataType);a&&ad(a,n,"emphasis")},r.prototype.downplay=function(t,e,i,n){var a=t.getData(n&&n.dataType);a&&ad(a,n,"normal")},r.prototype.remove=function(t,e){this.group.removeAll()},r.prototype.dispose=function(t,e){},r.prototype.updateView=function(t,e,i,n){this.render(t,e,i,n)},r.prototype.updateLayout=function(t,e,i,n){this.render(t,e,i,n)},r.prototype.updateVisual=function(t,e,i,n){this.render(t,e,i,n)},r.prototype.eachRendered=function(t){ch(this.group,t)},r.markUpdateMethod=function(t,e){jm(t).updateMethod=e},r.protoInitialize=(function(){var t=r.prototype;t.type="chart"})(),r})();function nd(r,t,e){r&&rf(r)&&(t==="emphasis"?ns:as)(r,e)}function ad(r,t,e){var i=wi(r,t),n=t&&t.highlightKey!=null?kw(t.highlightKey):null;i!=null?T(Yt(i),function(a){nd(r.getItemGraphicEl(a),e,n)}):r.eachItemGraphicEl(function(a){nd(a,e,n)})}th(Ve);Rs(Ve);function ET(r){return RT(r.model)}function kT(r){var t=r.model,e=r.ecModel,i=r.api,n=r.payload,a=t.pipelineContext.progressiveRender,o=r.view,s=n&&jm(n).updateMethod,l=a?"incrementalPrepareRender":s&&o[s]?s:"render";return l!=="render"&&o[l](t,e,i,n),OT[l]}var OT={incrementalPrepareRender:{progress:function(r,t){t.view.incrementalRender(r,t.model,t.ecModel,t.api,t.payload)}},render:{forceFirstProgress:!0,progress:function(r,t){t.view.render(t.model,t.ecModel,t.api,t.payload)}}},vs="\0__throttleOriginMethod",od="\0__throttleRate",sd="\0__throttleType";function ty(r,t,e){var i,n=0,a=0,o=null,s,l,u,f;t=t||0;function h(){a=new Date().getTime(),o=null,r.apply(l,u||[])}var c=function(){for(var v=[],d=0;d<arguments.length;d++)v[d]=arguments[d];i=new Date().getTime(),l=this,u=v;var g=f||t,m=f||e;f=null,s=i-(m?n:a)-g,clearTimeout(o),m?o=setTimeout(h,g):s>=0?h():o=setTimeout(h,-s),n=i};return c.clear=function(){o&&(clearTimeout(o),o=null)},c.debounceNextCall=function(v){f=v},c}function Qs(r,t,e,i){var n=r[t];if(n){var a=n[vs]||n,o=n[sd],s=n[od];if(s!==e||o!==i){if(e==null||!i)return r[t]=a;n=r[t]=ty(a,e,i==="debounce"),n[vs]=a,n[sd]=i,n[od]=e}return n}}function cs(r,t){var e=r[t];e&&e[vs]&&(e.clear&&e.clear(),r[t]=e[vs])}var ld=yt(),ud={itemStyle:ha(cm,!0),lineStyle:ha(vm,!0)},BT={lineStyle:"stroke",itemStyle:"fill"};function ey(r,t){var e=r.visualStyleMapper||ud[t];return e||(console.warn("Unknown style type '"+t+"'."),ud.itemStyle)}function ry(r,t){var e=r.visualDrawType||BT[t];return e||(console.warn("Unknown style type '"+t+"'."),"fill")}var NT={createOnAllSeries:!0,performRawSeries:!0,reset:function(r,t){var e=r.getData(),i=r.visualStyleAccessPath||"itemStyle",n=r.getModel(i),a=ey(r,i),o=a(n),s=n.getShallow("decal");s&&(e.setVisual("decal",s),s.dirty=!0);var l=ry(r,i),u=o[l],f=J(u)?u:null,h=o.fill==="auto"||o.stroke==="auto";if(!o[l]||f||h){var c=r.getColorFromPalette(r.name,null,t.getSeriesCount());o[l]||(o[l]=c,e.setVisual("colorFromPalette",!0)),o.fill=o.fill==="auto"||J(o.fill)?c:o.fill,o.stroke=o.stroke==="auto"||J(o.stroke)?c:o.stroke}if(e.setVisual("style",o),e.setVisual("drawType",l),!t.isSeriesFiltered(r)&&f)return e.setVisual("colorFromPalette",!1),{dataEach:function(v,d){var g=r.getDataParams(d),m=O({},o);m[l]=f(g),v.setItemVisual(d,"style",m)}}}},Tn=new xt,FT={createOnAllSeries:!0,performRawSeries:!0,reset:function(r,t){if(!(r.ignoreStyleOnData||t.isSeriesFiltered(r))){var e=r.getData(),i=r.visualStyleAccessPath||"itemStyle",n=ey(r,i),a=e.getVisual("drawType");return{dataEach:e.hasItemOption?function(o,s){var l=o.getRawDataItem(s);if(l&&l[i]){Tn.option=l[i];var u=n(Tn),f=o.ensureUniqueItemVisual(s,"style");O(f,u),Tn.option.decal&&(o.setItemVisual(s,"decal",Tn.option.decal),Tn.option.decal.dirty=!0),a in u&&o.setItemVisual(s,"colorFromPalette",!1)}}:null}}}},zT={performRawSeries:!0,overallReset:function(r){var t=Q();r.eachSeries(function(e){var i=e.getColorBy();if(!e.isColorBySeries()){var n=e.type+"-"+i,a=t.get(n);a||(a={},t.set(n,a)),ld(e).scope=a}}),r.eachSeries(function(e){if(!(e.isColorBySeries()||r.isSeriesFiltered(e))){var i=e.getRawData(),n={},a=e.getData(),o=ld(e).scope,s=e.visualStyleAccessPath||"itemStyle",l=ry(e,s);a.each(function(u){var f=a.getRawIndex(u);n[f]=u}),i.each(function(u){var f=n[u],h=a.getItemVisual(f,"colorFromPalette");if(h){var c=a.ensureUniqueItemVisual(f,"style"),v=i.getName(u)||u+"",d=i.count();c[l]=e.getColorFromPalette(v,o,d)}})}})}},co=Math.PI;function HT(r,t){t=t||{},ht(t,{text:"loading",textColor:H.color.primary,fontSize:12,fontWeight:"normal",fontStyle:"normal",fontFamily:"sans-serif",maskColor:"rgba(255,255,255,0.8)",showSpinner:!0,color:H.color.theme[0],spinnerRadius:10,lineWidth:5,zlevel:0});var e=new Dt,i=new wt({style:{fill:t.maskColor},zlevel:t.zlevel,z:1e4});e.add(i);var n=new Nt({style:{text:t.text,fill:t.textColor,fontSize:t.fontSize,fontWeight:t.fontWeight,fontStyle:t.fontStyle,fontFamily:t.fontFamily},zlevel:t.zlevel,z:10001}),a=new wt({style:{fill:"none"},textContent:n,textConfig:{position:"right",distance:10},zlevel:t.zlevel,z:10001});e.add(a);var o;return t.showSpinner&&(o=new Vs({shape:{startAngle:-co/2,endAngle:-co/2+.1,r:t.spinnerRadius},style:{stroke:t.color,lineCap:"round",lineWidth:t.lineWidth},zlevel:t.zlevel,z:10001}),o.animateShape(!0).when(1e3,{endAngle:co*3/2}).start("circularInOut"),o.animateShape(!0).when(1e3,{startAngle:co*3/2}).delay(300).start("circularInOut"),e.add(o)),e.resize=function(){var s=n.getBoundingRect().width,l=t.showSpinner?t.spinnerRadius:0,u=(r.getWidth()-l*2-(t.showSpinner&&s?10:0)-s)/2-(t.showSpinner&&s?0:5+s/2)+(t.showSpinner?0:s/2)+(s?0:l),f=r.getHeight()/2;t.showSpinner&&o.setShape({cx:u,cy:f}),a.setShape({x:u-l,y:f-l,width:l*2,height:l*2}),i.setShape({x:0,y:0,width:r.getWidth(),height:r.getHeight()})},e.resize(),e}var iy=(function(){function r(t,e,i,n){this._stageTaskMap=Q(),this.ecInstance=t,this.api=e,i=this._dataProcessorHandlers=i.slice(),n=this._visualHandlers=n.slice(),this._allHandlers=i.concat(n)}return r.prototype.restoreData=function(t,e){t.restoreData(e),this._stageTaskMap.each(function(i){var n=i.overallTask;n&&n.dirty()})},r.prototype.getPerformArgs=function(t,e){if(t.__pipeline){var i=this._pipelineMap.get(t.__pipeline.id),n=i.context,a=!e&&i.progressiveEnabled&&(!n||n.progressiveRender)&&t.__idxInPipeline>i.blockIndex,o=a?i.step:null,s=n&&n.modDataCount,l=s!=null?Math.ceil(s/o):null;return{step:o,modBy:l,modDataCount:s}}},r.prototype.getPipeline=function(t){return this._pipelineMap.get(t)},r.prototype.updateStreamModes=function(t,e){var i=this._pipelineMap.get(t.uid),n=t.getData(),a=n.count(),o=i.progressiveEnabled&&e.incrementalPrepareRender&&a>=i.threshold,s=t.get("large")&&a>=t.get("largeThreshold"),l=t.get("progressiveChunkMode")==="mod"?a:null;t.pipelineContext=i.context={progressiveRender:o,modDataCount:l,large:s}},r.prototype.restorePipelines=function(t){var e=this,i=e._pipelineMap=Q();t.eachSeries(function(n){var a=n.getProgressive(),o=n.uid;i.set(o,{id:o,head:null,tail:null,threshold:n.getProgressiveThreshold(),progressiveEnabled:a&&!(n.preventIncremental&&n.preventIncremental()),blockIndex:-1,step:Math.round(a||700),count:0}),e._pipe(n,n.dataTask)})},r.prototype.prepareStageTasks=function(){var t=this._stageTaskMap,e=this.api.getModel(),i=this.api;T(this._allHandlers,function(n){var a=t.get(n.uid)||t.set(n.uid,{}),o="";nr(!(n.reset&&n.overallReset),o),n.reset&&this._createSeriesStageTask(n,a,e,i),n.overallReset&&this._createOverallStageTask(n,a,e,i)},this)},r.prototype.prepareView=function(t,e,i,n){var a=t.renderTask,o=a.context;o.model=e,o.ecModel=i,o.api=n,a.__block=!t.incrementalPrepareRender,this._pipe(e,a)},r.prototype.performDataProcessorTasks=function(t,e){this._performStageTasks(this._dataProcessorHandlers,t,e,{block:!0})},r.prototype.performVisualTasks=function(t,e,i){this._performStageTasks(this._visualHandlers,t,e,i)},r.prototype._performStageTasks=function(t,e,i,n){n=n||{};var a=!1,o=this;T(t,function(l,u){if(!(n.visualType&&n.visualType!==l.visualType)){var f=o._stageTaskMap.get(l.uid),h=f.seriesTaskMap,c=f.overallTask;if(c){var v,d=c.agentStubMap;d.each(function(m){s(n,m)&&(m.dirty(),v=!0)}),v&&c.dirty(),o.updatePayload(c,i);var g=o.getPerformArgs(c,n.block);d.each(function(m){m.perform(g)}),c.perform(g)&&(a=!0)}else h&&h.each(function(m,p){s(n,m)&&m.dirty();var y=o.getPerformArgs(m,n.block);y.skip=!l.performRawSeries&&e.isSeriesFiltered(m.context.model),o.updatePayload(m,i),m.perform(y)&&(a=!0)})}});function s(l,u){return l.setDirty&&(!l.dirtyMap||l.dirtyMap.get(u.__pipeline.id))}this.unfinished=a||this.unfinished},r.prototype.performSeriesTasks=function(t){var e;t.eachSeries(function(i){e=i.dataTask.perform()||e}),this.unfinished=e||this.unfinished},r.prototype.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)})},r.prototype.updatePayload=function(t,e){e!=="remain"&&(t.context.payload=e)},r.prototype._createSeriesStageTask=function(t,e,i,n){var a=this,o=e.seriesTaskMap,s=e.seriesTaskMap=Q(),l=t.seriesType,u=t.getTargetSeries;t.createOnAllSeries?i.eachRawSeries(f):l?i.eachRawSeriesByType(l,f):u&&u(i,n).each(f);function f(h){var c=h.uid,v=s.set(c,o&&o.get(c)||ia({plan:YT,reset:ZT,count:qT}));v.context={model:h,ecModel:i,api:n,useClearVisual:t.isVisual&&!t.isLayout,plan:t.plan,reset:t.reset,scheduler:a},a._pipe(h,v)}},r.prototype._createOverallStageTask=function(t,e,i,n){var a=this,o=e.overallTask=e.overallTask||ia({reset:GT});o.context={ecModel:i,api:n,overallReset:t.overallReset,scheduler:a};var s=o.agentStubMap,l=o.agentStubMap=Q(),u=t.seriesType,f=t.getTargetSeries,h=!0,c=!1,v="";nr(!t.createOnAllSeries,v),u?i.eachRawSeriesByType(u,d):f?f(i,n).each(d):(h=!1,T(i.getSeries(),d));function d(g){var m=g.uid,p=l.set(m,s&&s.get(m)||(c=!0,ia({reset:VT,onDirty:UT})));p.context={model:g,overallProgress:h},p.agent=o,p.__block=h,a._pipe(g,p)}c&&o.dirty()},r.prototype._pipe=function(t,e){var i=t.uid,n=this._pipelineMap.get(i);!n.head&&(n.head=e),n.tail&&n.tail.pipe(e),n.tail=e,e.__idxInPipeline=n.count++,e.__pipeline=n},r.wrapStageHandler=function(t,e){return J(t)&&(t={overallReset:t,seriesType:$T(t)}),t.uid=Ys("stageHandler"),e&&(t.visualType=e),t},r})();function GT(r){r.overallReset(r.ecModel,r.api,r.payload)}function VT(r){return r.overallProgress&&WT}function WT(){this.agent.dirty(),this.getDownstream().dirty()}function UT(){this.agent&&this.agent.dirty()}function YT(r){return r.plan?r.plan(r.model,r.ecModel,r.api,r.payload):null}function ZT(r){r.useClearVisual&&r.data.clearAllVisual();var t=r.resetDefines=Yt(r.reset(r.model,r.ecModel,r.api,r.payload));return t.length>1?K(t,function(e,i){return ny(i)}):XT}var XT=ny(0);function ny(r){return function(t,e){var i=e.data,n=e.resetDefines[r];if(n&&n.dataEach)for(var a=t.start;a<t.end;a++)n.dataEach(i,a);else n&&n.progress&&n.progress(t,i)}}function qT(r){return r.data.count()}function $T(r){ds=null;try{r(Sa,ay)}catch{}return ds}var Sa={},ay={},ds;oy(Sa,Rh);oy(ay,Em);Sa.eachSeriesByType=Sa.eachRawSeriesByType=function(r){ds=r};Sa.eachComponent=function(r){r.mainType==="series"&&r.subType&&(ds=r.subType)};function oy(r,t){for(var e in t.prototype)r[e]=Ut}var N=H.darkColor,KT=N.background,Cn=function(){return{axisLine:{lineStyle:{color:N.axisLine}},splitLine:{lineStyle:{color:N.axisSplitLine}},splitArea:{areaStyle:{color:[N.backgroundTint,N.backgroundTransparent]}},minorSplitLine:{lineStyle:{color:N.axisMinorSplitLine}},axisLabel:{color:N.axisLabel},axisName:{}}},fd={label:{color:N.secondary},itemStyle:{borderColor:N.borderTint},dividerLineStyle:{color:N.border}},sy={darkMode:!0,color:N.theme,backgroundColor:KT,axisPointer:{lineStyle:{color:N.border},crossStyle:{color:N.borderShade},label:{color:N.tertiary}},legend:{textStyle:{color:N.secondary},pageTextStyle:{color:N.tertiary}},textStyle:{color:N.secondary},title:{textStyle:{color:N.primary},subtextStyle:{color:N.quaternary}},toolbox:{iconStyle:{borderColor:N.accent50}},tooltip:{backgroundColor:N.neutral20,defaultBorderColor:N.border,textStyle:{color:N.tertiary}},dataZoom:{borderColor:N.accent10,textStyle:{color:N.tertiary},brushStyle:{color:N.backgroundTint},handleStyle:{color:N.neutral00,borderColor:N.accent20},moveHandleStyle:{color:N.accent40},emphasis:{handleStyle:{borderColor:N.accent50}},dataBackground:{lineStyle:{color:N.accent30},areaStyle:{color:N.accent20}},selectedDataBackground:{lineStyle:{color:N.accent50},areaStyle:{color:N.accent30}}},visualMap:{textStyle:{color:N.secondary},handleStyle:{borderColor:N.neutral30}},timeline:{lineStyle:{color:N.accent10},label:{color:N.tertiary},controlStyle:{color:N.accent30,borderColor:N.accent30}},calendar:{itemStyle:{color:N.neutral00,borderColor:N.neutral20},dayLabel:{color:N.tertiary},monthLabel:{color:N.secondary},yearLabel:{color:N.secondary}},matrix:{x:fd,y:fd,backgroundColor:{borderColor:N.axisLine},body:{itemStyle:{borderColor:N.borderTint}}},timeAxis:Cn(),logAxis:Cn(),valueAxis:Cn(),categoryAxis:Cn(),line:{symbol:"circle"},graph:{color:N.theme},gauge:{title:{color:N.secondary},axisLine:{lineStyle:{color:[[1,N.neutral05]]}},axisLabel:{color:N.axisLabel},detail:{color:N.primary}},candlestick:{itemStyle:{color:"#f64e56",color0:"#54ea92",borderColor:"#f64e56",borderColor0:"#54ea92"}},funnel:{itemStyle:{borderColor:N.background}},radar:(function(){var r=Cn();return r.axisName={color:N.axisLabel},r.axisLine.lineStyle.color=N.neutral20,r})(),treemap:{breadcrumb:{itemStyle:{color:N.neutral20,textStyle:{color:N.secondary}},emphasis:{itemStyle:{color:N.neutral30}}}},sunburst:{itemStyle:{borderColor:N.background}},map:{itemStyle:{borderColor:N.border,areaColor:N.neutral10},label:{color:N.tertiary},emphasis:{label:{color:N.primary},itemStyle:{areaColor:N.highlight}},select:{label:{color:N.primary},itemStyle:{areaColor:N.highlight}}},geo:{itemStyle:{borderColor:N.border,areaColor:N.neutral10},emphasis:{label:{color:N.primary},itemStyle:{areaColor:N.highlight}},select:{label:{color:N.primary},itemStyle:{color:N.highlight}}}};sy.categoryAxis.splitLine.show=!1;var QT=(function(){function r(){}return r.prototype.normalizeQuery=function(t){var e={},i={},n={};if(W(t)){var a=Be(t);e.mainType=a.main||null,e.subType=a.sub||null}else{var o=["Index","Name","Id"],s={name:1,dataIndex:1,dataType:1};T(t,function(l,u){for(var f=!1,h=0;h<o.length;h++){var c=o[h],v=u.lastIndexOf(c);if(v>0&&v===u.length-c.length){var d=u.slice(0,v);d!=="data"&&(e.mainType=d,e[c.toLowerCase()]=l,f=!0)}}s.hasOwnProperty(u)&&(i[u]=l,f=!0),f||(n[u]=l)})}return{cptQuery:e,dataQuery:i,otherQuery:n}},r.prototype.filter=function(t,e){var i=this.eventInfo;if(!i)return!0;var n=i.targetEl,a=i.packedEvent,o=i.model,s=i.view;if(!o||!s)return!0;var l=e.cptQuery,u=e.dataQuery;return f(l,o,"mainType")&&f(l,o,"subType")&&f(l,o,"index","componentIndex")&&f(l,o,"name")&&f(l,o,"id")&&f(u,a,"name")&&f(u,a,"dataIndex")&&f(u,a,"dataType")&&(!s.filterForExposedEvent||s.filterForExposedEvent(t,e.otherQuery,n,a));function f(h,c,v,d){return h[v]==null||c[d||v]===h[v]}},r.prototype.afterTrigger=function(){this.eventInfo=null},r})(),pf=["symbol","symbolSize","symbolRotate","symbolOffset"],hd=pf.concat(["symbolKeepAspect"]),JT={createOnAllSeries:!0,performRawSeries:!0,reset:function(r,t){var e=r.getData();if(r.legendIcon&&e.setVisual("legendIcon",r.legendIcon),!r.hasSymbolVisual)return;for(var i={},n={},a=!1,o=0;o<pf.length;o++){var s=pf[o],l=r.get(s);J(l)?(a=!0,n[s]=l):i[s]=l}if(i.symbol=i.symbol||r.defaultSymbol,e.setVisual(O({legendIcon:r.legendIcon||i.symbol,symbolKeepAspect:r.get("symbolKeepAspect")},i)),t.isSeriesFiltered(r))return;var u=St(n);function f(h,c){for(var v=r.getRawValue(c),d=r.getDataParams(c),g=0;g<u.length;g++){var m=u[g];h.setItemVisual(c,m,n[m](v,d))}}return{dataEach:a?f:null}}},jT={createOnAllSeries:!0,performRawSeries:!0,reset:function(r,t){if(!r.hasSymbolVisual||t.isSeriesFiltered(r))return;var e=r.getData();function i(n,a){for(var o=n.getItemModel(a),s=0;s<hd.length;s++){var l=hd[s],u=o.getShallow(l,!0);u!=null&&n.setItemVisual(a,l,u)}}return{dataEach:e.hasItemOption?i:null}}};function tC(r,t,e){switch(e){case"color":var i=r.getItemVisual(t,"style");return i[r.getVisual("drawType")];case"opacity":return r.getItemVisual(t,"style").opacity;case"symbol":case"symbolSize":case"liftZ":return r.getItemVisual(t,e)}}function eC(r,t){switch(t){case"color":var e=r.getVisual("style");return e[r.getVisual("drawType")];case"opacity":return r.getVisual("style").opacity;case"symbol":case"symbolSize":case"liftZ":return r.getVisual(t)}}function zi(r,t,e,i,n){var a=r+t;e.isSilent(a)||i.eachComponent({mainType:"series",subType:"pie"},function(o){for(var s=o.seriesIndex,l=o.option.selectedMap,u=n.selected,f=0;f<u.length;f++)if(u[f].seriesIndex===s){var h=o.getData(),c=wi(h,n.fromActionPayload);e.trigger(a,{type:a,seriesId:o.id,name:V(c)?h.getName(c[0]):h.getName(c),selected:W(l)?l:O({},l)})}})}function rC(r,t,e){r.on("selectchanged",function(i){var n=e.getModel();i.isFromClick?(zi("map","selectchanged",t,n,i),zi("pie","selectchanged",t,n,i)):i.fromAction==="select"?(zi("map","selected",t,n,i),zi("pie","selected",t,n,i)):i.fromAction==="unselect"&&(zi("map","unselected",t,n,i),zi("pie","unselected",t,n,i))})}function Yn(r,t,e){for(var i;r&&!(t(r)&&(i=r,e));)r=r.__hostTarget||r.parent;return i}var iC=Math.round(Math.random()*9),nC=typeof Object.defineProperty=="function",aC=(function(){function r(){this._id="__ec_inner_"+iC++}return r.prototype.get=function(t){return this._guard(t)[this._id]},r.prototype.set=function(t,e){var i=this._guard(t);return nC?Object.defineProperty(i,this._id,{value:e,enumerable:!1,configurable:!0}):i[this._id]=e,this},r.prototype.delete=function(t){return this.has(t)?(delete this._guard(t)[this._id],!0):!1},r.prototype.has=function(t){return!!this._guard(t)[this._id]},r.prototype._guard=function(t){if(t!==Object(t))throw TypeError("Value of WeakMap is not a non-null object.");return t},r})(),oC=dt.extend({type:"triangle",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(r,t){var e=t.cx,i=t.cy,n=t.width/2,a=t.height/2;r.moveTo(e,i-a),r.lineTo(e+n,i+a),r.lineTo(e-n,i+a),r.closePath()}}),sC=dt.extend({type:"diamond",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(r,t){var e=t.cx,i=t.cy,n=t.width/2,a=t.height/2;r.moveTo(e,i-a),r.lineTo(e+n,i),r.lineTo(e,i+a),r.lineTo(e-n,i),r.closePath()}}),lC=dt.extend({type:"pin",shape:{x:0,y:0,width:0,height:0},buildPath:function(r,t){var e=t.x,i=t.y,n=t.width/5*3,a=Math.max(n,t.height),o=n/2,s=o*o/(a-o),l=i-a+o+s,u=Math.asin(s/o),f=Math.cos(u)*o,h=Math.sin(u),c=Math.cos(u),v=o*.6,d=o*.7;r.moveTo(e-f,l+s),r.arc(e,l,o,Math.PI-u,Math.PI*2+u),r.bezierCurveTo(e+f-h*v,l+s+c*v,e,i-d,e,i),r.bezierCurveTo(e,i-d,e-f+h*v,l+s+c*v,e-f,l+s),r.closePath()}}),uC=dt.extend({type:"arrow",shape:{x:0,y:0,width:0,height:0},buildPath:function(r,t){var e=t.height,i=t.width,n=t.x,a=t.y,o=i/3*2;r.moveTo(n,a),r.lineTo(n+o,a+e),r.lineTo(n,a+e/4*3),r.lineTo(n-o,a+e),r.lineTo(n,a),r.closePath()}}),fC={line:Dr,rect:wt,roundRect:wt,square:wt,circle:Fs,diamond:sC,pin:lC,arrow:uC,triangle:oC},hC={line:function(r,t,e,i,n){n.x1=r,n.y1=t+i/2,n.x2=r+e,n.y2=t+i/2},rect:function(r,t,e,i,n){n.x=r,n.y=t,n.width=e,n.height=i},roundRect:function(r,t,e,i,n){n.x=r,n.y=t,n.width=e,n.height=i,n.r=Math.min(e,i)/4},square:function(r,t,e,i,n){var a=Math.min(e,i);n.x=r,n.y=t,n.width=a,n.height=a},circle:function(r,t,e,i,n){n.cx=r+e/2,n.cy=t+i/2,n.r=Math.min(e,i)/2},diamond:function(r,t,e,i,n){n.cx=r+e/2,n.cy=t+i/2,n.width=e,n.height=i},pin:function(r,t,e,i,n){n.x=r+e/2,n.y=t+i/2,n.width=e,n.height=i},arrow:function(r,t,e,i,n){n.x=r+e/2,n.y=t+i/2,n.width=e,n.height=i},triangle:function(r,t,e,i,n){n.cx=r+e/2,n.cy=t+i/2,n.width=e,n.height=i}},ps={};T(fC,function(r,t){ps[t]=new r});var vC=dt.extend({type:"symbol",shape:{symbolType:"",x:0,y:0,width:0,height:0},calculateTextPosition:function(r,t,e){var i=dg(r,t,e),n=this.shape;return n&&n.symbolType==="pin"&&t.position==="inside"&&(i.y=e.y+e.height*.4),i},buildPath:function(r,t,e){var i=t.symbolType;if(i!=="none"){var n=ps[i];n||(i="rect",n=ps[i]),hC[i](t.x,t.y,t.width,t.height,n.shape),n.buildPath(r,n.shape,e)}}});function cC(r,t){if(this.type!=="image"){var e=this.style;this.__isEmptyBrush?(e.stroke=r,e.fill=t||H.color.neutral00,e.lineWidth=2):this.shape.symbolType==="line"?e.stroke=r:e.fill=r,this.markRedraw()}}function Pr(r,t,e,i,n,a,o){var s=r.indexOf("empty")===0;s&&(r=r.substr(5,1).toLowerCase()+r.substr(6));var l;return r.indexOf("image://")===0?l=rm(r.slice(8),new rt(t,e,i,n),o?"center":"cover"):r.indexOf("path://")===0?l=hh(r.slice(7),{},new rt(t,e,i,n),o?"center":"cover"):l=new vC({shape:{symbolType:r,x:t,y:e,width:i,height:n}}),l.__isEmptyBrush=s,l.setColor=cC,a&&l.setColor(a),l}function dC(r){return V(r)||(r=[+r,+r]),[r[0]||0,r[1]||0]}function ly(r,t){if(r!=null)return V(r)||(r=[r,r]),[Ot(r[0],t[0])||0,Ot($(r[1],r[0]),t[1])||0]}function vi(r){return isFinite(r)}function pC(r,t,e){var i=t.x==null?0:t.x,n=t.x2==null?1:t.x2,a=t.y==null?0:t.y,o=t.y2==null?0:t.y2;t.global||(i=i*e.width+e.x,n=n*e.width+e.x,a=a*e.height+e.y,o=o*e.height+e.y),i=vi(i)?i:0,n=vi(n)?n:1,a=vi(a)?a:0,o=vi(o)?o:0;var s=r.createLinearGradient(i,a,n,o);return s}function gC(r,t,e){var i=e.width,n=e.height,a=Math.min(i,n),o=t.x==null?.5:t.x,s=t.y==null?.5:t.y,l=t.r==null?.5:t.r;t.global||(o=o*i+e.x,s=s*n+e.y,l=l*a),o=vi(o)?o:.5,s=vi(s)?s:.5,l=l>=0&&vi(l)?l:.5;var u=r.createRadialGradient(o,s,0,o,s,l);return u}function gf(r,t,e){for(var i=t.type==="radial"?gC(r,t,e):pC(r,t,e),n=t.colorStops,a=0;a<n.length;a++)i.addColorStop(n[a].offset,n[a].color);return i}function mC(r,t){if(r===t||!r&&!t)return!1;if(!r||!t||r.length!==t.length)return!0;for(var e=0;e<r.length;e++)if(r[e]!==t[e])return!0;return!1}function po(r){return parseInt(r,10)}function go(r,t,e){var i=["width","height"][t],n=["clientWidth","clientHeight"][t],a=["paddingLeft","paddingTop"][t],o=["paddingRight","paddingBottom"][t];if(e[i]!=null&&e[i]!=="auto")return parseFloat(e[i]);var s=document.defaultView.getComputedStyle(r);return(r[n]||po(s[i])||po(r.style[i]))-(po(s[a])||0)-(po(s[o])||0)|0}function yC(r,t){return!r||r==="solid"||!(t>0)?null:r==="dashed"?[4*t,2*t]:r==="dotted"?[t]:mt(r)?[r]:V(r)?r:null}function uy(r){var t=r.style,e=t.lineDash&&t.lineWidth>0&&yC(t.lineDash,t.lineWidth),i=t.lineDashOffset;if(e){var n=t.strokeNoScale&&r.getLineScale?r.getLineScale():1;n&&n!==1&&(e=K(e,function(a){return a/n}),i/=n)}return[e,i]}var _C=new xi(!0);function gs(r){var t=r.stroke;return!(t==null||t==="none"||!(r.lineWidth>0))}function vd(r){return typeof r=="string"&&r!=="none"}function ms(r){var t=r.fill;return t!=null&&t!=="none"}function cd(r,t){if(t.fillOpacity!=null&&t.fillOpacity!==1){var e=r.globalAlpha;r.globalAlpha=t.fillOpacity*t.opacity,r.fill(),r.globalAlpha=e}else r.fill()}function dd(r,t){if(t.strokeOpacity!=null&&t.strokeOpacity!==1){var e=r.globalAlpha;r.globalAlpha=t.strokeOpacity*t.opacity,r.stroke(),r.globalAlpha=e}else r.stroke()}function mf(r,t,e){var i=Lg(t.image,t.__image,e);if(Es(i)){var n=r.createPattern(i,t.repeat||"repeat");if(typeof DOMMatrix=="function"&&n&&n.setTransform){var a=new DOMMatrix;a.translateSelf(t.x||0,t.y||0),a.rotateSelf(0,0,(t.rotation||0)*C_),a.scaleSelf(t.scaleX||1,t.scaleY||1),n.setTransform(a)}return n}}function SC(r,t,e,i){var n,a=gs(e),o=ms(e),s=e.strokePercent,l=s<1,u=!t.path;(!t.silent||l)&&u&&t.createPathProxy();var f=t.path||_C,h=t.__dirty;if(!i){var c=e.fill,v=e.stroke,d=o&&!!c.colorStops,g=a&&!!v.colorStops,m=o&&!!c.image,p=a&&!!v.image,y=void 0,_=void 0,S=void 0,x=void 0,w=void 0;(d||g)&&(w=t.getBoundingRect()),d&&(y=h?gf(r,c,w):t.__canvasFillGradient,t.__canvasFillGradient=y),g&&(_=h?gf(r,v,w):t.__canvasStrokeGradient,t.__canvasStrokeGradient=_),m&&(S=h||!t.__canvasFillPattern?mf(r,c,t):t.__canvasFillPattern,t.__canvasFillPattern=S),p&&(x=h||!t.__canvasStrokePattern?mf(r,v,t):t.__canvasStrokePattern,t.__canvasStrokePattern=x),d?r.fillStyle=y:m&&(S?r.fillStyle=S:o=!1),g?r.strokeStyle=_:p&&(x?r.strokeStyle=x:a=!1)}var b=t.getGlobalScale();f.setScale(b[0],b[1],t.segmentIgnoreThreshold);var D,C;r.setLineDash&&e.lineDash&&(n=uy(t),D=n[0],C=n[1]);var M=!0;(u||h&Zi)&&(f.setDPR(r.dpr),l?f.setContext(null):(f.setContext(r),M=!1),f.reset(),t.buildPath(f,t.shape,i),f.toStatic(),t.pathUpdated()),M&&f.rebuildPath(r,l?s:1),D&&(r.setLineDash(D),r.lineDashOffset=C),i||(e.strokeFirst?(a&&dd(r,e),o&&cd(r,e)):(o&&cd(r,e),a&&dd(r,e))),D&&r.setLineDash([])}function wC(r,t,e){var i=t.__image=Lg(e.image,t.__image,t,t.onload);if(!(!i||!Es(i))){var n=e.x||0,a=e.y||0,o=t.getWidth(),s=t.getHeight(),l=i.width/i.height;if(o==null&&s!=null?o=s*l:s==null&&o!=null?s=o/l:o==null&&s==null&&(o=i.width,s=i.height),e.sWidth&&e.sHeight){var u=e.sx||0,f=e.sy||0;r.drawImage(i,u,f,e.sWidth,e.sHeight,n,a,o,s)}else if(e.sx&&e.sy){var u=e.sx,f=e.sy,h=o-u,c=s-f;r.drawImage(i,u,f,h,c,n,a,o,s)}else r.drawImage(i,n,a,o,s)}}function xC(r,t,e){var i,n=e.text;if(n!=null&&(n+=""),n){r.font=e.font||Mr,r.textAlign=e.textAlign,r.textBaseline=e.textBaseline;var a=void 0,o=void 0;r.setLineDash&&e.lineDash&&(i=uy(t),a=i[0],o=i[1]),a&&(r.setLineDash(a),r.lineDashOffset=o),e.strokeFirst?(gs(e)&&r.strokeText(n,e.x,e.y),ms(e)&&r.fillText(n,e.x,e.y)):(ms(e)&&r.fillText(n,e.x,e.y),gs(e)&&r.strokeText(n,e.x,e.y)),a&&r.setLineDash([])}}var pd=["shadowBlur","shadowOffsetX","shadowOffsetY"],gd=[["lineCap","butt"],["lineJoin","miter"],["miterLimit",10]];function fy(r,t,e,i,n){var a=!1;if(!i&&(e=e||{},t===e))return!1;if(i||t.opacity!==e.opacity){Qt(r,n),a=!0;var o=Math.max(Math.min(t.opacity,1),0);r.globalAlpha=isNaN(o)?gi.opacity:o}(i||t.blend!==e.blend)&&(a||(Qt(r,n),a=!0),r.globalCompositeOperation=t.blend||gi.blend);for(var s=0;s<pd.length;s++){var l=pd[s];(i||t[l]!==e[l])&&(a||(Qt(r,n),a=!0),r[l]=r.dpr*(t[l]||0))}return(i||t.shadowColor!==e.shadowColor)&&(a||(Qt(r,n),a=!0),r.shadowColor=t.shadowColor||gi.shadowColor),a}function md(r,t,e,i,n){var a=wa(t,n.inHover),o=i?null:e&&wa(e,n.inHover)||{};if(a===o)return!1;var s=fy(r,a,o,i,n);if((i||a.fill!==o.fill)&&(s||(Qt(r,n),s=!0),vd(a.fill)&&(r.fillStyle=a.fill)),(i||a.stroke!==o.stroke)&&(s||(Qt(r,n),s=!0),vd(a.stroke)&&(r.strokeStyle=a.stroke)),(i||a.opacity!==o.opacity)&&(s||(Qt(r,n),s=!0),r.globalAlpha=a.opacity==null?1:a.opacity),t.hasStroke()){var l=a.lineWidth,u=l/(a.strokeNoScale&&t.getLineScale?t.getLineScale():1);r.lineWidth!==u&&(s||(Qt(r,n),s=!0),r.lineWidth=u)}for(var f=0;f<gd.length;f++){var h=gd[f],c=h[0];(i||a[c]!==o[c])&&(s||(Qt(r,n),s=!0),r[c]=a[c]||h[1])}return s}function bC(r,t,e,i,n){return fy(r,wa(t,n.inHover),e&&wa(e,n.inHover),i,n)}function hy(r,t){var e=t.transform,i=r.dpr||1;e?r.setTransform(i*e[0],i*e[1],i*e[2],i*e[3],i*e[4],i*e[5]):r.setTransform(i,0,0,i,0,0)}function TC(r,t,e){for(var i=!1,n=0;n<r.length;n++){var a=r[n];i=i||a.isZeroArea(),hy(t,a),t.beginPath(),a.buildPath(t,a.shape),t.clip()}e.allClipped=i}function CC(r,t){return r&&t?r[0]!==t[0]||r[1]!==t[1]||r[2]!==t[2]||r[3]!==t[3]||r[4]!==t[4]||r[5]!==t[5]:!(!r&&!t)}var yd=1,_d=2,Sd=3,wd=4;function MC(r){var t=ms(r),e=gs(r);return!(r.lineDash||!(+t^+e)||t&&typeof r.fill!="string"||e&&typeof r.stroke!="string"||r.strokePercent<1||r.strokeOpacity<1||r.fillOpacity<1)}function Qt(r,t){t.batchFill&&r.fill(),t.batchStroke&&r.stroke(),t.batchFill="",t.batchStroke=""}function wa(r,t){return t&&r.__hoverStyle||r.style}function vy(r,t){ci(r,t,{inHover:!1,viewWidth:0,viewHeight:0},!0)}function ci(r,t,e,i){var n=t.transform;if(!t.shouldBePainted(e.viewWidth,e.viewHeight,!1,!1)){t.__dirty&=~ie,t.__isRendered=!1;return}var a=t.__clipPaths,o=e.prevElClipPaths,s=!1,l=!1;if((!o||mC(a,o))&&(o&&o.length&&(Qt(r,e),r.restore(),l=s=!0,e.prevElClipPaths=null,e.allClipped=!1,e.prevEl=null),a&&a.length&&(Qt(r,e),r.save(),TC(a,r,e),s=!0),e.prevElClipPaths=a),e.allClipped){t.__isRendered=!1;return}t.beforeBrush&&t.beforeBrush(),t.innerBeforeBrush();var u=e.prevEl;u||(l=s=!0);var f=t instanceof dt&&t.autoBatch&&MC(t.style);s||CC(n,u.transform)?(Qt(r,e),hy(r,t)):f||Qt(r,e);var h=wa(t,e.inHover);t instanceof dt?(e.lastDrawType!==yd&&(l=!0,e.lastDrawType=yd),md(r,t,u,l,e),(!f||!e.batchFill&&!e.batchStroke)&&r.beginPath(),SC(r,t,h,f),f&&(e.batchFill=h.fill||"",e.batchStroke=h.stroke||"")):t instanceof es?(e.lastDrawType!==Sd&&(l=!0,e.lastDrawType=Sd),md(r,t,u,l,e),xC(r,t,h)):t instanceof Er?(e.lastDrawType!==_d&&(l=!0,e.lastDrawType=_d),bC(r,t,u,l,e),wC(r,t,h)):t.getTemporalDisplayables&&(e.lastDrawType!==wd&&(l=!0,e.lastDrawType=wd),DC(r,t,e)),f&&i&&Qt(r,e),t.innerAfterBrush(),t.afterBrush&&t.afterBrush(),e.prevEl=t,t.__dirty=0,t.__isRendered=!0}function DC(r,t,e){var i=t.getDisplayables(),n=t.getTemporalDisplayables();r.save();var a={prevElClipPaths:null,prevEl:null,allClipped:!1,viewWidth:e.viewWidth,viewHeight:e.viewHeight,inHover:e.inHover},o,s;for(o=t.getCursor(),s=i.length;o<s;o++){var l=i[o];l.beforeBrush&&l.beforeBrush(),l.innerBeforeBrush(),ci(r,l,a,o===s-1),l.innerAfterBrush(),l.afterBrush&&l.afterBrush(),a.prevEl=l}for(var u=0,f=n.length;u<f;u++){var l=n[u];l.beforeBrush&&l.beforeBrush(),l.innerBeforeBrush(),ci(r,l,a,u===f-1),l.innerAfterBrush(),l.afterBrush&&l.afterBrush(),a.prevEl=l}t.clearTemporalDisplayables(),t.notClear=!0,r.restore()}var Ql=new aC,xd=new sn(100),bd=["symbol","symbolSize","symbolKeepAspect","color","backgroundColor","dashArrayX","dashArrayY","maxTileWidth","maxTileHeight"];function yf(r,t){if(r==="none")return null;var e=t.getDevicePixelRatio(),i=t.getZr(),n=i.painter.type==="svg";r.dirty&&Ql.delete(r);var a=Ql.get(r);if(a)return a;var o=ht(r,{symbol:"rect",symbolSize:1,symbolKeepAspect:!0,color:"rgba(0, 0, 0, 0.2)",backgroundColor:null,dashArrayX:5,dashArrayY:5,rotation:0,maxTileWidth:512,maxTileHeight:512});o.backgroundColor==="none"&&(o.backgroundColor=null);var s={repeat:"repeat"};return l(s),s.rotation=o.rotation,s.scaleX=s.scaleY=n?1:1/e,Ql.set(r,s),r.dirty=!1,s;function l(u){for(var f=[e],h=!0,c=0;c<bd.length;++c){var v=o[bd[c]];if(v!=null&&!V(v)&&!W(v)&&!mt(v)&&typeof v!="boolean"){h=!1;break}f.push(v)}var d;if(h){d=f.join(",")+(n?"-svg":"");var g=xd.get(d);g&&(n?u.svgElement=g:u.image=g)}var m=dy(o.dashArrayX),p=AC(o.dashArrayY),y=cy(o.symbol),_=LC(m),S=py(p),x=!n&&ir.createCanvas(),w=n&&{tag:"g",attrs:{},key:"dcl",children:[]},b=C(),D;x&&(x.width=b.width*e,x.height=b.height*e,D=x.getContext("2d")),M(),h&&xd.put(d,x||w),u.image=x,u.svgElement=w,u.svgWidth=b.width,u.svgHeight=b.height;function C(){for(var A=1,P=0,L=_.length;P<L;++P)A=Rv(A,_[P]);for(var I=1,P=0,L=y.length;P<L;++P)I=Rv(I,y[P].length);A*=I;var E=S*_.length*y.length;return{width:Math.max(1,Math.min(A,o.maxTileWidth)),height:Math.max(1,Math.min(E,o.maxTileHeight))}}function M(){D&&(D.clearRect(0,0,x.width,x.height),o.backgroundColor&&(D.fillStyle=o.backgroundColor,D.fillRect(0,0,x.width,x.height)));for(var A=0,P=0;P<p.length;++P)A+=p[P];if(A<=0)return;for(var L=-S,I=0,E=0,k=0;L<b.height;){if(I%2===0){for(var U=E/2%y.length,z=0,R=0,F=0;z<b.width*2;){for(var G=0,P=0;P<m[k].length;++P)G+=m[k][P];if(G<=0)break;if(R%2===0){var X=(1-o.symbolSize)*.5,tt=z+m[k][R]*X,ot=L+p[I]*X,_t=m[k][R]*o.symbolSize,Zt=p[I]*o.symbolSize,De=F/2%y[U].length;Xe(tt,ot,_t,Zt,y[U][De])}z+=m[k][R],++F,++R,R===m[k].length&&(R=0)}++k,k===m.length&&(k=0)}L+=p[I],++E,++I,I===p.length&&(I=0)}function Xe(te,Et,et,nt,Or){var Gt=n?1:e,Qh=Pr(Or,te*Gt,Et*Gt,et*Gt,nt*Gt,o.color,o.symbolKeepAspect);if(n){var Jh=i.painter.renderOneToVNode(Qh);Jh&&w.children.push(Jh)}else vy(D,Qh)}}}}function cy(r){if(!r||r.length===0)return[["rect"]];if(W(r))return[[r]];for(var t=!0,e=0;e<r.length;++e)if(!W(r[e])){t=!1;break}if(t)return cy([r]);for(var i=[],e=0;e<r.length;++e)W(r[e])?i.push([r[e]]):i.push(r[e]);return i}function dy(r){if(!r||r.length===0)return[[0,0]];if(mt(r)){var t=Math.ceil(r);return[[t,t]]}for(var e=!0,i=0;i<r.length;++i)if(!mt(r[i])){e=!1;break}if(e)return dy([r]);for(var n=[],i=0;i<r.length;++i)if(mt(r[i])){var t=Math.ceil(r[i]);n.push([t,t])}else{var t=K(r[i],function(s){return Math.ceil(s)});t.length%2===1?n.push(t.concat(t)):n.push(t)}return n}function AC(r){if(!r||typeof r=="object"&&r.length===0)return[0,0];if(mt(r)){var t=Math.ceil(r);return[t,t]}var e=K(r,function(i){return Math.ceil(i)});return r.length%2?e.concat(e):e}function LC(r){return K(r,function(t){return py(t)})}function py(r){for(var t=0,e=0;e<r.length;++e)t+=r[e];return r.length%2===1?t*2:t}function IC(r,t){r.eachRawSeries(function(e){if(!r.isSeriesFiltered(e)){var i=e.getData();i.hasItemVisual()&&i.each(function(o){var s=i.getItemVisual(o,"decal");if(s){var l=i.ensureUniqueItemVisual(o,"style");l.decal=yf(s,t)}});var n=i.getVisual("decal");if(n){var a=i.getVisual("style");a.decal=yf(n,t)}}})}var we=new Te,gy={};function PC(r,t){gy[r]=t}function RC(r){return gy[r]}var EC=1,kC=800,OC=900,BC=1e3,NC=2e3,FC=5e3,my=1e3,zC=1100,Bh=2e3,yy=3e3,HC=4e3,Js=4500,GC=4600,VC=5e3,WC=6e3,_y=7e3,UC={PROCESSOR:{FILTER:BC,SERIES_FILTER:kC,STATISTIC:FC},VISUAL:{LAYOUT:my,PROGRESSIVE_LAYOUT:zC,GLOBAL:Bh,CHART:yy,POST_CHART_LAYOUT:GC,COMPONENT:HC,BRUSH:VC,CHART_ITEM:Js,ARIA:WC,DECAL:_y}},Ct="__flagInMainProcess",mo="__mainProcessVersion",Lt="__pendingUpdate",Jl="__needsUpdateStatus",Td=/^[a-zA-Z0-9_]+$/,jl="__connectUpdateStatus",Cd=0,YC=1,ZC=2;function Sy(r){return function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];if(this.isDisposed()){this.id;return}return xy(this,r,t)}}function wy(r){return function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return xy(this,r,t)}}function xy(r,t,e){return e[0]=e[0]&&e[0].toLowerCase(),Te.prototype[t].apply(r,e)}var by=(function(r){B(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t})(Te),Ty=by.prototype;Ty.on=wy("on");Ty.off=wy("off");var ai,tu,yo,Ke,_o,eu,ru,Hi,Gi,Md,Dd,iu,Ad,So,Ld,Cy,se,Id,Vi,My=(function(r){B(t,r);function t(e,i,n){var a=r.call(this,new QT)||this;a._chartsViews=[],a._chartsMap={},a._componentsViews=[],a._componentsMap={},a._pendingActions=[],n=n||{},a._dom=e;var o="canvas",s="auto",l=!1;a[mo]=1,n.ssr;var u=a._zr=Iv(e,{renderer:n.renderer||o,devicePixelRatio:n.devicePixelRatio,width:n.width,height:n.height,ssr:n.ssr,useDirtyRect:$(n.useDirtyRect,l),useCoarsePointer:$(n.useCoarsePointer,s),pointerSize:n.pointerSize});a._ssr=n.ssr,a._throttledZrFlush=ty(q(u.flush,u),17),a._updateTheme(i),a._locale=Yx(n.locale||dm),a._coordSysMgr=new Lh;var f=a._api=Ld(a);function h(c,v){return c.__prio-v.__prio}return Lo(_s,h),Lo(wf,h),a._scheduler=new iy(a,f,wf,_s),a._messageCenter=new by,a._initEvents(),a.resize=q(a.resize,a),u.animation.on("frame",a._onframe,a),Md(u,a),Dd(u,a),Mu(a),a}return t.prototype._onframe=function(){if(!this._disposed){Id(this);var e=this._scheduler;if(this[Lt]){var i=this[Lt].silent;this[Ct]=!0,Vi(this);try{ai(this),Ke.update.call(this,null,this[Lt].updateParams)}catch(l){throw this[Ct]=!1,this[Lt]=null,l}this._zr.flush(),this[Ct]=!1,this[Lt]=null,Hi.call(this,i),Gi.call(this,i)}else if(e.unfinished){var n=EC,a=this._model,o=this._api;e.unfinished=!1;do{var s=+new Date;e.performSeriesTasks(a),e.performDataProcessorTasks(a),eu(this,a),e.performVisualTasks(a),So(this,this._model,o,"remain",{}),n-=+new Date-s}while(n>0&&e.unfinished);e.unfinished||this._zr.flush()}}},t.prototype.getDom=function(){return this._dom},t.prototype.getId=function(){return this.id},t.prototype.getZr=function(){return this._zr},t.prototype.isSSR=function(){return this._ssr},t.prototype.setOption=function(e,i,n){if(!this[Ct]){if(this._disposed){this.id;return}var a,o,s;if(Z(i)&&(n=i.lazyUpdate,a=i.silent,o=i.replaceMerge,s=i.transition,i=i.notMerge),this[Ct]=!0,Vi(this),!this._model||i){var l=new Pb(this._api),u=this._theme,f=this._model=new Rh;f.scheduler=this._scheduler,f.ssr=this._ssr,f.init(null,null,null,u,this._locale,l)}this._model.setOption(e,{replaceMerge:o},xf);var h={seriesTransition:s,optionChanged:!0};if(n)this[Lt]={silent:a,updateParams:h},this[Ct]=!1,this.getZr().wakeUp();else{try{ai(this),Ke.update.call(this,null,h)}catch(c){throw this[Lt]=null,this[Ct]=!1,c}this._ssr||this._zr.flush(),this[Lt]=null,this[Ct]=!1,Hi.call(this,a),Gi.call(this,a)}}},t.prototype.setTheme=function(e,i){if(!this[Ct]){if(this._disposed){this.id;return}var n=this._model;if(n){var a=i&&i.silent,o=null;this[Lt]&&(a==null&&(a=this[Lt].silent),o=this[Lt].updateParams,this[Lt]=null),this[Ct]=!0,Vi(this);try{this._updateTheme(e),n.setTheme(this._theme),ai(this),Ke.update.call(this,{type:"setTheme"},o)}catch(s){throw this[Ct]=!1,s}this[Ct]=!1,Hi.call(this,a),Gi.call(this,a)}}},t.prototype._updateTheme=function(e){W(e)&&(e=Dy[e]),e&&(e=it(e),e&&Om(e,!0),this._theme=e)},t.prototype.getModel=function(){return this._model},t.prototype.getOption=function(){return this._model&&this._model.getOption()},t.prototype.getWidth=function(){return this._zr.getWidth()},t.prototype.getHeight=function(){return this._zr.getHeight()},t.prototype.getDevicePixelRatio=function(){return this._zr.painter.dpr||j.hasGlobalWindow&&window.devicePixelRatio||1},t.prototype.getRenderedCanvas=function(e){return this.renderToCanvas(e)},t.prototype.renderToCanvas=function(e){e=e||{};var i=this._zr.painter;return i.getRenderedCanvas({backgroundColor:e.backgroundColor||this._model.get("backgroundColor"),pixelRatio:e.pixelRatio||this.getDevicePixelRatio()})},t.prototype.renderToSVGString=function(e){e=e||{};var i=this._zr.painter;return i.renderToString({useViewBox:e.useViewBox})},t.prototype.getSvgDataURL=function(){var e=this._zr,i=e.storage.getDisplayList();return T(i,function(n){n.stopAnimation(null,!0)}),e.painter.toDataURL()},t.prototype.getDataURL=function(e){if(this._disposed){this.id;return}e=e||{};var i=e.excludeComponents,n=this._model,a=[],o=this;T(i,function(l){n.eachComponent({mainType:l},function(u){var f=o._componentsMap[u.__viewId];f.group.ignore||(a.push(f),f.group.ignore=!0)})});var s=this._zr.painter.getType()==="svg"?this.getSvgDataURL():this.renderToCanvas(e).toDataURL("image/"+(e&&e.type||"png"));return T(a,function(l){l.group.ignore=!1}),s},t.prototype.getConnectedDataURL=function(e){if(this._disposed){this.id;return}var i=e.type==="svg",n=this.group,a=Math.min,o=Math.max,s=1/0;if(Pd[n]){var l=s,u=s,f=-s,h=-s,c=[],v=e&&e.pixelRatio||this.getDevicePixelRatio();T(na,function(_,S){if(_.group===n){var x=i?_.getZr().painter.getSvgDom().innerHTML:_.renderToCanvas(it(e)),w=_.getDom().getBoundingClientRect();l=a(w.left,l),u=a(w.top,u),f=o(w.right,f),h=o(w.bottom,h),c.push({dom:x,left:w.left,top:w.top})}}),l*=v,u*=v,f*=v,h*=v;var d=f-l,g=h-u,m=ir.createCanvas(),p=Iv(m,{renderer:i?"svg":"canvas"});if(p.resize({width:d,height:g}),i){var y="";return T(c,function(_){var S=_.left-l,x=_.top-u;y+='<g transform="translate('+S+","+x+')">'+_.dom+"</g>"}),p.painter.getSvgRoot().innerHTML=y,e.connectedBackgroundColor&&p.painter.setBackgroundColor(e.connectedBackgroundColor),p.refreshImmediately(),p.painter.toDataURL()}else return e.connectedBackgroundColor&&p.add(new wt({shape:{x:0,y:0,width:d,height:g},style:{fill:e.connectedBackgroundColor}})),T(c,function(_){var S=new Er({style:{x:_.left*v-l,y:_.top*v-u,image:_.dom}});p.add(S)}),p.refreshImmediately(),m.toDataURL("image/"+(e&&e.type||"png"))}else return this.getDataURL(e)},t.prototype.convertToPixel=function(e,i,n){return _o(this,"convertToPixel",e,i,n)},t.prototype.convertToLayout=function(e,i,n){return _o(this,"convertToLayout",e,i,n)},t.prototype.convertFromPixel=function(e,i,n){return _o(this,"convertFromPixel",e,i,n)},t.prototype.containPixel=function(e,i){if(this._disposed){this.id;return}var n=this._model,a,o=bl(n,e);return T(o,function(s,l){l.indexOf("Models")>=0&&T(s,function(u){var f=u.coordinateSystem;if(f&&f.containPoint)a=a||!!f.containPoint(i);else if(l==="seriesModels"){var h=this._chartsMap[u.__viewId];h&&h.containPoint&&(a=a||h.containPoint(i,u))}},this)},this),!!a},t.prototype.getVisual=function(e,i){var n=this._model,a=bl(n,e,{defaultMainType:"series"}),o=a.seriesModel,s=o.getData(),l=a.hasOwnProperty("dataIndexInside")?a.dataIndexInside:a.hasOwnProperty("dataIndex")?s.indexOfRawIndex(a.dataIndex):null;return l!=null?tC(s,l,i):eC(s,i)},t.prototype.getViewOfComponentModel=function(e){return this._componentsMap[e.__viewId]},t.prototype.getViewOfSeriesModel=function(e){return this._chartsMap[e.__viewId]},t.prototype._initEvents=function(){var e=this;T(XC,function(n){var a=function(o){var s=e.getModel(),l=o.target,u,f=n==="globalout";if(f?u={}:l&&Yn(l,function(g){var m=ft(g);if(m&&m.dataIndex!=null){var p=m.dataModel||s.getSeriesByIndex(m.seriesIndex);return u=p&&p.getDataParams(m.dataIndex,m.dataType,l)||{},!0}else if(m.eventData)return u=O({},m.eventData),!0},!0),u){var h=u.componentType,c=u.componentIndex;(h==="markLine"||h==="markPoint"||h==="markArea")&&(h="series",c=u.seriesIndex);var v=h&&c!=null&&s.getComponent(h,c),d=v&&e[v.mainType==="series"?"_chartsMap":"_componentsMap"][v.__viewId];u.event=o,u.type=n,e._$eventProcessor.eventInfo={targetEl:l,packedEvent:u,model:v,view:d},e.trigger(n,u)}};a.zrEventfulCallAtLast=!0,e._zr.on(n,a,e)});var i=this._messageCenter;T(Sf,function(n,a){i.on(a,function(o){e.trigger(a,o)})}),rC(i,this,this._api)},t.prototype.isDisposed=function(){return this._disposed},t.prototype.clear=function(){if(this._disposed){this.id;return}this.setOption({series:[]},!0)},t.prototype.dispose=function(){if(this._disposed){this.id;return}this._disposed=!0;var e=this.getDom();e&&Mg(this.getDom(),Fh,"");var i=this,n=i._api,a=i._model;T(i._componentsViews,function(o){o.dispose(a,n)}),T(i._chartsViews,function(o){o.dispose(a,n)}),i._zr.dispose(),i._dom=i._model=i._chartsMap=i._componentsMap=i._chartsViews=i._componentsViews=i._scheduler=i._api=i._zr=i._throttledZrFlush=i._theme=i._coordSysMgr=i._messageCenter=null,delete na[i.id]},t.prototype.resize=function(e){if(!this[Ct]){if(this._disposed){this.id;return}this._zr.resize(e);var i=this._model;if(this._loadingFX&&this._loadingFX.resize(),!!i){var n=i.resetOption("media"),a=e&&e.silent;this[Lt]&&(a==null&&(a=this[Lt].silent),n=!0,this[Lt]=null),this[Ct]=!0,Vi(this);try{n&&ai(this),Ke.update.call(this,{type:"resize",animation:O({duration:0},e&&e.animation)})}catch(o){throw this[Ct]=!1,o}this[Ct]=!1,Hi.call(this,a),Gi.call(this,a)}}},t.prototype.showLoading=function(e,i){if(this._disposed){this.id;return}if(Z(e)&&(i=e,e=""),e=e||"default",this.hideLoading(),!!bf[e]){var n=bf[e](this._api,i),a=this._zr;this._loadingFX=n,a.add(n)}},t.prototype.hideLoading=function(){if(this._disposed){this.id;return}this._loadingFX&&this._zr.remove(this._loadingFX),this._loadingFX=null},t.prototype.makeActionFromEvent=function(e){var i=O({},e);return i.type=_f[e.type],i},t.prototype.dispatchAction=function(e,i){if(this._disposed){this.id;return}if(Z(i)||(i={silent:!!i}),!!ys[e.type]&&this._model){if(this[Ct]){this._pendingActions.push(e);return}var n=i.silent;ru.call(this,e,n);var a=i.flush;a?this._zr.flush():a!==!1&&j.browser.weChat&&this._throttledZrFlush(),Hi.call(this,n),Gi.call(this,n)}},t.prototype.updateLabelLayout=function(){we.trigger("series:layoutlabels",this._model,this._api,{updatedSeries:[]})},t.prototype.appendData=function(e){if(this._disposed){this.id;return}var i=e.seriesIndex,n=this.getModel(),a=n.getSeriesByIndex(i);a.appendData(e),this._scheduler.unfinished=!0,this.getZr().wakeUp()},t.internalField=(function(){ai=function(h){var c=h._scheduler;c.restorePipelines(h._model),c.prepareStageTasks(),tu(h,!0),tu(h,!1),c.plan()},tu=function(h,c){for(var v=h._model,d=h._scheduler,g=c?h._componentsViews:h._chartsViews,m=c?h._componentsMap:h._chartsMap,p=h._zr,y=h._api,_=0;_<g.length;_++)g[_].__alive=!1;c?v.eachComponent(function(w,b){w!=="series"&&S(b)}):v.eachSeries(S);function S(w){var b=w.__requireNewView;w.__requireNewView=!1;var D="_ec_"+w.id+"_"+w.type,C=!b&&m[D];if(!C){var M=Be(w.type),A=c?me.getClass(M.main,M.sub):Ve.getClass(M.sub);C=new A,C.init(v,y),m[D]=C,g.push(C),p.add(C.group)}w.__viewId=C.__id=D,C.__alive=!0,C.__model=w,C.group.__ecComponentInfo={mainType:w.mainType,index:w.componentIndex},!c&&d.prepareView(C,w,v,y)}for(var _=0;_<g.length;){var x=g[_];x.__alive?_++:(!c&&x.renderTask.dispose(),p.remove(x.group),x.dispose(v,y),g.splice(_,1),m[x.__id]===x&&delete m[x.__id],x.__id=x.group.__ecComponentInfo=null)}},yo=function(h,c,v,d,g){var m=h._model;if(m.setUpdatePayload(v),!d){T([].concat(h._componentsViews).concat(h._chartsViews),x);return}var p={};p[d+"Id"]=v[d+"Id"],p[d+"Index"]=v[d+"Index"],p[d+"Name"]=v[d+"Name"];var y={mainType:d,query:p};g&&(y.subType=g);var _=v.excludeSeriesId,S;_!=null&&(S=Q(),T(Yt(_),function(w){var b=He(w,null);b!=null&&S.set(b,!0)})),m&&m.eachComponent(y,function(w){var b=S&&S.get(w.id)!=null;if(!b)if(hc(v))if(w instanceof Ir)v.type===mi&&!v.notBlur&&!w.get(["emphasis","disabled"])&&Mw(w,v,h._api);else{var D=oh(w.mainType,w.componentIndex,v.name,h._api),C=D.focusSelf,M=D.dispatchers;v.type===mi&&C&&!v.notBlur&&tf(w.mainType,w.componentIndex,h._api),M&&T(M,function(A){v.type===mi?ns(A):as(A)})}else nf(v)&&w instanceof Ir&&(Lw(w,v,h._api),lc(w),se(h))},h),m&&m.eachComponent(y,function(w){var b=S&&S.get(w.id)!=null;b||x(h[d==="series"?"_chartsMap":"_componentsMap"][w.__viewId])},h);function x(w){w&&w.__alive&&w[c]&&w[c](w.__model,m,h._api,v)}},Ke={prepareAndUpdate:function(h){ai(this),Ke.update.call(this,h,h&&{optionChanged:h.newOption!=null})},update:function(h,c){var v=this._model,d=this._api,g=this._zr,m=this._coordSysMgr,p=this._scheduler;if(v){v.setUpdatePayload(h),p.restoreData(v,h),p.performSeriesTasks(v),m.create(v,d),p.performDataProcessorTasks(v,h),eu(this,v),m.update(v,d),i(v),p.performVisualTasks(v,h);var y=v.get("backgroundColor")||"transparent";g.setBackgroundColor(y);var _=v.get("darkMode");_!=null&&_!=="auto"&&g.setDarkMode(_),iu(this,v,d,h,c),we.trigger("afterupdate",v,d)}},updateTransform:function(h){var c=this,v=this._model,d=this._api;if(v){v.setUpdatePayload(h);var g=[];v.eachComponent(function(p,y){if(p!=="series"){var _=c.getViewOfComponentModel(y);if(_&&_.__alive)if(_.updateTransform){var S=_.updateTransform(y,v,d,h);S&&S.update&&g.push(_)}else g.push(_)}});var m=Q();v.eachSeries(function(p){var y=c._chartsMap[p.__viewId];if(y.updateTransform){var _=y.updateTransform(p,v,d,h);_&&_.update&&m.set(p.uid,1)}else m.set(p.uid,1)}),i(v),this._scheduler.performVisualTasks(v,h,{setDirty:!0,dirtyMap:m}),So(this,v,d,h,{},m),we.trigger("afterupdate",v,d)}},updateView:function(h){var c=this._model;c&&(c.setUpdatePayload(h),Ve.markUpdateMethod(h,"updateView"),i(c),this._scheduler.performVisualTasks(c,h,{setDirty:!0}),iu(this,c,this._api,h,{}),we.trigger("afterupdate",c,this._api))},updateVisual:function(h){var c=this,v=this._model;v&&(v.setUpdatePayload(h),v.eachSeries(function(d){d.getData().clearAllVisual()}),Ve.markUpdateMethod(h,"updateVisual"),i(v),this._scheduler.performVisualTasks(v,h,{visualType:"visual",setDirty:!0}),v.eachComponent(function(d,g){if(d!=="series"){var m=c.getViewOfComponentModel(g);m&&m.__alive&&m.updateVisual(g,v,c._api,h)}}),v.eachSeries(function(d){var g=c._chartsMap[d.__viewId];g.updateVisual(d,v,c._api,h)}),we.trigger("afterupdate",v,this._api))},updateLayout:function(h){Ke.update.call(this,h)}};function e(h,c,v,d,g){if(h._disposed){h.id;return}for(var m=h._model,p=h._coordSysMgr.getCoordinateSystems(),y,_=bl(m,v),S=0;S<p.length;S++){var x=p[S];if(x[c]&&(y=x[c](m,_,d,g))!=null)return y}}_o=e,eu=function(h,c){var v=h._chartsMap,d=h._scheduler;c.eachSeries(function(g){d.updateStreamModes(g,v[g.__viewId])})},ru=function(h,c){var v=this,d=this.getModel(),g=h.type,m=h.escapeConnect,p=ys[g],y=(p.update||"update").split(":"),_=y.pop(),S=y[0]!=null&&Be(y[0]);this[Ct]=!0,Vi(this);var x=[h],w=!1;h.batch&&(w=!0,x=K(h.batch,function(k){return k=ht(O({},k),h),k.batch=null,k}));var b=[],D,C=[],M=p.nonRefinedEventType,A=nf(h),P=hc(h);if(P&&Zg(this._api),T(x,function(k){var U=p.action(k,d,v._api);if(p.refineEvent?C.push(U):D=U,D=D||O({},k),D.type=M,b.push(D),P){var z=jf(h),R=z.queryOptionMap,F=z.mainTypeSpecified,G=F?R.keys()[0]:"series";yo(v,_,k,G),se(v)}else A?(yo(v,_,k,"series"),se(v)):S&&yo(v,_,k,S.main,S.sub)}),_!=="none"&&!P&&!A&&!S)try{this[Lt]?(ai(this),Ke.update.call(this,h),this[Lt]=null):Ke[_].call(this,h)}catch(k){throw this[Ct]=!1,k}if(w?D={type:M,escapeConnect:m,batch:b}:D=b[0],this[Ct]=!1,!c){var L=void 0;if(p.refineEvent){var I=p.refineEvent(C,h,d,this._api).eventContent;nr(Z(I)),L=ht({type:p.refinedEventType},I),L.fromAction=h.type,L.fromActionPayload=h,L.escapeConnect=!0}var E=this._messageCenter;E.trigger(D.type,D),L&&E.trigger(L.type,L)}},Hi=function(h){for(var c=this._pendingActions;c.length;){var v=c.shift();ru.call(this,v,h)}},Gi=function(h){!h&&this.trigger("updated")},Md=function(h,c){h.on("rendered",function(v){c.trigger("rendered",v),h.animation.isFinished()&&!c[Lt]&&!c._scheduler.unfinished&&!c._pendingActions.length&&c.trigger("finished")})},Dd=function(h,c){h.on("mouseover",function(v){var d=v.target,g=Yn(d,rf);g&&(Dw(g,v,c._api),se(c))}).on("mouseout",function(v){var d=v.target,g=Yn(d,rf);g&&(Aw(g,v,c._api),se(c))}).on("click",function(v){var d=v.target,g=Yn(d,function(y){return ft(y).dataIndex!=null},!0);if(g){var m=g.selected?"unselect":"select",p=ft(g);c._api.dispatchAction({type:m,dataType:p.dataType,dataIndexInside:p.dataIndex,seriesIndex:p.seriesIndex,isFromClick:!0})}})};function i(h){h.clearColorPalette(),h.eachSeries(function(c){c.clearColorPalette()})}function n(h){var c=[],v=[],d=!1;if(h.eachComponent(function(y,_){var S=_.get("zlevel")||0,x=_.get("z")||0,w=_.getZLevelKey();d=d||!!w,(y==="series"?v:c).push({zlevel:S,z:x,idx:_.componentIndex,type:y,key:w})}),d){var g=c.concat(v),m,p;Lo(g,function(y,_){return y.zlevel===_.zlevel?y.z-_.z:y.zlevel-_.zlevel}),T(g,function(y){var _=h.getComponent(y.type,y.idx),S=y.zlevel,x=y.key;m!=null&&(S=Math.max(m,S)),x?(S===m&&x!==p&&S++,p=x):p&&(S===m&&S++,p=""),m=S,_.setZLevel(S)})}}iu=function(h,c,v,d,g){n(c),Ad(h,c,v,d,g),T(h._chartsViews,function(m){m.__alive=!1}),So(h,c,v,d,g),T(h._chartsViews,function(m){m.__alive||m.remove(c,v)})},Ad=function(h,c,v,d,g,m){T(m||h._componentsViews,function(p){var y=p.__model;u(y,p),p.render(y,c,v,d),l(y,p),f(y,p)})},So=function(h,c,v,d,g,m){var p=h._scheduler;g=O(g||{},{updatedSeries:c.getSeries()}),we.trigger("series:beforeupdate",c,v,g);var y=!1;c.eachSeries(function(_){var S=h._chartsMap[_.__viewId];S.__alive=!0;var x=S.renderTask;p.updatePayload(x,d),u(_,S),m&&m.get(_.uid)&&x.dirty(),x.perform(p.getPerformArgs(x))&&(y=!0),S.group.silent=!!_.get("silent"),s(_,S),lc(_)}),p.unfinished=y||p.unfinished,we.trigger("series:layoutlabels",c,v,g),we.trigger("series:transition",c,v,g),c.eachSeries(function(_){var S=h._chartsMap[_.__viewId];l(_,S),f(_,S)}),o(h,c),we.trigger("series:afterupdate",c,v,g)},se=function(h){h[Jl]=!0,h.getZr().wakeUp()},Vi=function(h){h[mo]=(h[mo]+1)%1e3},Id=function(h){h[Jl]&&(h.getZr().storage.traverse(function(c){jn(c)||a(c)}),h[Jl]=!1)};function a(h){for(var c=[],v=h.currentStates,d=0;d<v.length;d++){var g=v[d];g==="emphasis"||g==="blur"||g==="select"||c.push(g)}h.selected&&h.states.select&&c.push("select"),h.hoverState===Bs&&h.states.emphasis?c.push("emphasis"):h.hoverState===Os&&h.states.blur&&c.push("blur"),h.useStates(c)}function o(h,c){var v=h._zr,d=v.storage,g=0;d.traverse(function(m){m.isGroup||g++}),g>c.get("hoverLayerThreshold")&&!j.node&&!j.worker&&c.eachSeries(function(m){if(!m.preventUsingHoverLayer){var p=h._chartsMap[m.__viewId];p.__alive&&p.eachRendered(function(y){y.states.emphasis&&(y.states.emphasis.hoverLayer=!0)})}})}function s(h,c){var v=h.get("blendMode")||null;c.eachRendered(function(d){d.isGroup||(d.style.blend=v)})}function l(h,c){if(!h.preventAutoZ){var v=ga(h);c.eachRendered(function(d){return um(d,v.z,v.zlevel),!0})}}function u(h,c){c.eachRendered(function(v){if(!jn(v)){var d=v.getTextContent(),g=v.getTextGuideLine();v.stateTransition&&(v.stateTransition=null),d&&d.stateTransition&&(d.stateTransition=null),g&&g.stateTransition&&(g.stateTransition=null),v.hasState()?(v.prevStates=v.currentStates,v.clearStates()):v.prevStates&&(v.prevStates=null)}})}function f(h,c){var v=h.getModel("stateAnimation"),d=h.isAnimationEnabled(),g=v.get("duration"),m=g>0?{duration:g,delay:v.get("delay"),easing:v.get("easing")}:null;c.eachRendered(function(p){if(p.states&&p.states.emphasis){if(jn(p))return;if(p instanceof dt&&Ow(p),p.__dirty){var y=p.prevStates;y&&p.useStates(y)}if(d){p.stateTransition=m;var _=p.getTextContent(),S=p.getTextGuideLine();_&&(_.stateTransition=m),S&&(S.stateTransition=m)}p.__dirty&&a(p)}})}Ld=function(h){return new((function(c){B(v,c);function v(){return c!==null&&c.apply(this,arguments)||this}return v.prototype.getCoordinateSystems=function(){return h._coordSysMgr.getCoordinateSystems()},v.prototype.getComponentByElement=function(d){for(;d;){var g=d.__ecComponentInfo;if(g!=null)return h._model.getComponent(g.mainType,g.index);d=d.parent}},v.prototype.enterEmphasis=function(d,g){ns(d,g),se(h)},v.prototype.leaveEmphasis=function(d,g){as(d,g),se(h)},v.prototype.enterBlur=function(d){Cw(d),se(h)},v.prototype.leaveBlur=function(d){Vg(d),se(h)},v.prototype.enterSelect=function(d){Wg(d),se(h)},v.prototype.leaveSelect=function(d){Ug(d),se(h)},v.prototype.getModel=function(){return h.getModel()},v.prototype.getViewOfComponentModel=function(d){return h.getViewOfComponentModel(d)},v.prototype.getViewOfSeriesModel=function(d){return h.getViewOfSeriesModel(d)},v.prototype.getMainProcessVersion=function(){return h[mo]},v})(Em))(h)},Cy=function(h){function c(v,d){for(var g=0;g<v.length;g++){var m=v[g];m[jl]=d}}T(_f,function(v,d){h._messageCenter.on(d,function(g){if(Pd[h.group]&&h[jl]!==Cd){if(g&&g.escapeConnect)return;var m=h.makeActionFromEvent(g),p=[];T(na,function(y){y!==h&&y.group===h.group&&p.push(y)}),c(p,Cd),T(p,function(y){y[jl]!==YC&&y.dispatchAction(m)}),c(p,ZC)}})})}})(),t})(Te),Nh=My.prototype;Nh.on=Sy("on");Nh.off=Sy("off");Nh.one=function(r,t,e){var i=this;function n(){for(var a=[],o=0;o<arguments.length;o++)a[o]=arguments[o];t&&t.apply&&t.apply(this,a),i.off(r,n)}this.on.call(this,r,n,e)};var XC=["click","dblclick","mouseover","mouseout","mousemove","mousedown","mouseup","globalout","contextmenu"];var ys={},_f={},Sf={},wf=[],xf=[],_s=[],Dy={},bf={},na={},Pd={},qC=+new Date-0,Fh="_echarts_instance_";function $C(r,t,e){{var i=KC(r);if(i)return i}var n=new My(r,t,e);return n.id="ec_"+qC++,na[n.id]=n,Mg(r,Fh,n.id),Cy(n),we.trigger("afterinit",n),n}function KC(r){return na[cS(r,Fh)]}function Ay(r,t){Dy[r]=t}function Ly(r){at(xf,r)<0&&xf.push(r)}function Iy(r,t){Hh(wf,r,t,NC)}function QC(r){zh("afterinit",r)}function JC(r){zh("afterupdate",r)}function zh(r,t){we.on(r,t)}function Mi(r,t,e){var i,n,a,o,s;J(t)&&(e=t,t=""),Z(r)?(i=r.type,n=r.event,o=r.update,s=r.publishNonRefinedEvent,e||(e=r.action),a=r.refineEvent):(i=r,n=t);function l(f){return f.toLowerCase()}n=l(n||i);var u=a?l(i):n;ys[i]||(nr(Td.test(i)&&Td.test(n)),a&&nr(n!==i),ys[i]={actionType:i,refinedEventType:n,nonRefinedEventType:u,update:o,action:e,refineEvent:a},Sf[n]=1,a&&s&&(Sf[u]=1),_f[u]=i)}function jC(r,t){Lh.register(r,t)}function tM(r,t){Hh(_s,r,t,my,"layout")}function Di(r,t){Hh(_s,r,t,yy,"visual")}var Rd=[];function Hh(r,t,e,i,n){if((J(t)||Z(t))&&(e=t,t=i),!(at(Rd,e)>=0)){Rd.push(e);var a=iy.wrapStageHandler(e,n);a.__prio=t,a.__raw=e,r.push(a)}}function Py(r,t){bf[r]=t}function eM(r,t,e){var i=RC("registerMap");i&&i(r,t,e)}var rM=sT;Di(Bh,NT);Di(Js,FT);Di(Js,zT);Di(Bh,JT);Di(Js,jT);Di(_y,IC);Ly(Om);Iy(OC,Wb);Py("default",HT);Mi({type:mi,event:mi,update:mi},Ut);Mi({type:Oo,event:Oo,update:Oo},Ut);Mi({type:rs,event:nh,update:rs,action:Ut,refineEvent:Gh,publishNonRefinedEvent:!0});Mi({type:Ju,event:nh,update:Ju,action:Ut,refineEvent:Gh,publishNonRefinedEvent:!0});Mi({type:is,event:nh,update:is,action:Ut,refineEvent:Gh,publishNonRefinedEvent:!0});function Gh(r,t,e,i){return{eventContent:{selected:Iw(e),isFromClick:t.isFromClick||!1}}}Ay("default",{});Ay("dark",sy);function Mn(r){return r==null?0:r.length||1}function Ed(r){return r}var iM=(function(){function r(t,e,i,n,a,o){this._old=t,this._new=e,this._oldKeyGetter=i||Ed,this._newKeyGetter=n||Ed,this.context=a,this._diffModeMultiple=o==="multiple"}return r.prototype.add=function(t){return this._add=t,this},r.prototype.update=function(t){return this._update=t,this},r.prototype.updateManyToOne=function(t){return this._updateManyToOne=t,this},r.prototype.updateOneToMany=function(t){return this._updateOneToMany=t,this},r.prototype.updateManyToMany=function(t){return this._updateManyToMany=t,this},r.prototype.remove=function(t){return this._remove=t,this},r.prototype.execute=function(){this[this._diffModeMultiple?"_executeMultiple":"_executeOneToOne"]()},r.prototype._executeOneToOne=function(){var t=this._old,e=this._new,i={},n=new Array(t.length),a=new Array(e.length);this._initIndexMap(t,null,n,"_oldKeyGetter"),this._initIndexMap(e,i,a,"_newKeyGetter");for(var o=0;o<t.length;o++){var s=n[o],l=i[s],u=Mn(l);if(u>1){var f=l.shift();l.length===1&&(i[s]=l[0]),this._update&&this._update(f,o)}else u===1?(i[s]=null,this._update&&this._update(l,o)):this._remove&&this._remove(o)}this._performRestAdd(a,i)},r.prototype._executeMultiple=function(){var t=this._old,e=this._new,i={},n={},a=[],o=[];this._initIndexMap(t,i,a,"_oldKeyGetter"),this._initIndexMap(e,n,o,"_newKeyGetter");for(var s=0;s<a.length;s++){var l=a[s],u=i[l],f=n[l],h=Mn(u),c=Mn(f);if(h>1&&c===1)this._updateManyToOne&&this._updateManyToOne(f,u),n[l]=null;else if(h===1&&c>1)this._updateOneToMany&&this._updateOneToMany(f,u),n[l]=null;else if(h===1&&c===1)this._update&&this._update(f,u),n[l]=null;else if(h>1&&c>1)this._updateManyToMany&&this._updateManyToMany(f,u),n[l]=null;else if(h>1)for(var v=0;v<h;v++)this._remove&&this._remove(u[v]);else this._remove&&this._remove(u)}this._performRestAdd(o,n)},r.prototype._performRestAdd=function(t,e){for(var i=0;i<t.length;i++){var n=t[i],a=e[n],o=Mn(a);if(o>1)for(var s=0;s<o;s++)this._add&&this._add(a[s]);else o===1&&this._add&&this._add(a);e[n]=null}},r.prototype._initIndexMap=function(t,e,i,n){for(var a=this._diffModeMultiple,o=0;o<t.length;o++){var s="_ec_"+this[n](t[o],o);if(a||(i[o]=s),!!e){var l=e[s],u=Mn(l);u===0?(e[s]=o,a&&i.push(s)):u===1?e[s]=[l,o]:l.push(o)}}},r})(),nM=(function(){function r(t,e){this._encode=t,this._schema=e}return r.prototype.get=function(){return{fullDimensions:this._getFullDimensionNames(),encode:this._encode}},r.prototype._getFullDimensionNames=function(){return this._cachedDimNames||(this._cachedDimNames=this._schema?this._schema.makeOutputDimensionNames():[]),this._cachedDimNames},r})();function aM(r,t){var e={},i=e.encode={},n=Q(),a=[],o=[],s={};T(r.dimensions,function(c){var v=r.getDimensionInfo(c),d=v.coordDim;if(d){var g=v.coordDimIndex;nu(i,d)[g]=c,v.isExtraCoord||(n.set(d,1),sM(v.type)&&(a[0]=c),nu(s,d)[g]=r.getDimensionIndex(v.name)),v.defaultTooltip&&o.push(c)}Am.each(function(m,p){var y=nu(i,p),_=v.otherDims[p];_!=null&&_!==!1&&(y[_]=v.name)})});var l=[],u={};n.each(function(c,v){var d=i[v];u[v]=d[0],l=l.concat(d)}),e.dataDimsOnCoord=l,e.dataDimIndicesOnCoord=K(l,function(c){return r.getDimensionInfo(c).storeDimIndex}),e.encodeFirstDimNotExtra=u;var f=i.label;f&&f.length&&(a=f.slice());var h=i.tooltip;return h&&h.length?o=h.slice():o.length||(o=a.slice()),i.defaultedLabel=a,i.defaultedTooltip=o,e.userOutput=new nM(s,t),e}function nu(r,t){return r.hasOwnProperty(t)||(r[t]=[]),r[t]}function oM(r){return r==="category"?"ordinal":r==="time"?"time":"float"}function sM(r){return!(r==="ordinal"||r==="time")}var Go=(function(){function r(t){this.otherDims={},t!=null&&O(this,t)}return r})(),lM=yt(),uM={float:"f",int:"i",ordinal:"o",number:"n",time:"t"},Ry=(function(){function r(t){this.dimensions=t.dimensions,this._dimOmitted=t.dimensionOmitted,this.source=t.source,this._fullDimCount=t.fullDimensionCount,this._updateDimOmitted(t.dimensionOmitted)}return r.prototype.isDimensionOmitted=function(){return this._dimOmitted},r.prototype._updateDimOmitted=function(t){this._dimOmitted=t,t&&(this._dimNameMap||(this._dimNameMap=Oy(this.source)))},r.prototype.getSourceDimensionIndex=function(t){return $(this._dimNameMap.get(t),-1)},r.prototype.getSourceDimension=function(t){var e=this.source.dimensionsDefine;if(e)return e[t]},r.prototype.makeStoreSchema=function(){for(var t=this._fullDimCount,e=Fm(this.source),i=!By(t),n="",a=[],o=0,s=0;o<t;o++){var l=void 0,u=void 0,f=void 0,h=this.dimensions[s];if(h&&h.storeDimIndex===o)l=e?h.name:null,u=h.type,f=h.ordinalMeta,s++;else{var c=this.getSourceDimension(o);c&&(l=e?c.name:null,u=c.type)}a.push({property:l,type:u,ordinalMeta:f}),e&&l!=null&&(!h||!h.isCalculationCoord)&&(n+=i?l.replace(/\`/g,"`1").replace(/\$/g,"`2"):l),n+="$",n+=uM[u]||"f",f&&(n+=f.uid),n+="$"}var v=this.source,d=[v.seriesLayoutBy,v.startIndex,n].join("$$");return{dimensions:a,hash:d}},r.prototype.makeOutputDimensionNames=function(){for(var t=[],e=0,i=0;e<this._fullDimCount;e++){var n=void 0,a=this.dimensions[i];if(a&&a.storeDimIndex===e)a.isCalculationCoord||(n=a.name),i++;else{var o=this.getSourceDimension(e);o&&(n=o.name)}t.push(n)}return t},r.prototype.appendCalculationDimension=function(t){this.dimensions.push(t),t.isCalculationCoord=!0,this._fullDimCount++,this._updateDimOmitted(!0)},r})();function Ey(r){return r instanceof Ry}function ky(r){for(var t=Q(),e=0;e<(r||[]).length;e++){var i=r[e],n=Z(i)?i.name:i;n!=null&&t.get(n)==null&&t.set(n,e)}return t}function Oy(r){var t=lM(r);return t.dimNameMap||(t.dimNameMap=ky(r.dimensionsDefine))}function By(r){return r>30}var Dn=Z,vr=K,fM=typeof Int32Array>"u"?Array:Int32Array,hM="e\0\0",kd=-1,vM=["hasItemOption","_nameList","_idList","_invertedIndicesMap","_dimSummary","userOutput","_rawData","_dimValueGetter","_nameDimIdx","_idDimIdx","_nameRepeatCount"],cM=["_approximateExtent"],Od,wo,An,Ln,au,In,ou,dM=(function(){function r(t,e){this.type="list",this._dimOmitted=!1,this._nameList=[],this._idList=[],this._visual={},this._layout={},this._itemVisuals=[],this._itemLayouts=[],this._graphicEls=[],this._approximateExtent={},this._calculationInfo={},this.hasItemOption=!1,this.TRANSFERABLE_METHODS=["cloneShallow","downSample","minmaxDownSample","lttbDownSample","map"],this.CHANGABLE_METHODS=["filterSelf","selectRange"],this.DOWNSAMPLE_METHODS=["downSample","minmaxDownSample","lttbDownSample"];var i,n=!1;Ey(t)?(i=t.dimensions,this._dimOmitted=t.isDimensionOmitted(),this._schema=t):(n=!0,i=t),i=i||["x","y"];for(var a={},o=[],s={},l=!1,u={},f=0;f<i.length;f++){var h=i[f],c=W(h)?new Go({name:h}):h instanceof Go?h:new Go(h),v=c.name;c.type=c.type||"float",c.coordDim||(c.coordDim=v,c.coordDimIndex=0);var d=c.otherDims=c.otherDims||{};o.push(v),a[v]=c,u[v]!=null&&(l=!0),c.createInvertedIndices&&(s[v]=[]);var g=f;mt(c.storeDimIndex)&&(g=c.storeDimIndex),d.itemName===0&&(this._nameDimIdx=g),d.itemId===0&&(this._idDimIdx=g),n&&(c.storeDimIndex=f)}if(this.dimensions=o,this._dimInfos=a,this._initGetDimensionInfo(l),this.hostModel=e,this._invertedIndicesMap=s,this._dimOmitted){var m=this._dimIdxToName=Q();T(o,function(p){m.set(a[p].storeDimIndex,p)})}}return r.prototype.getDimension=function(t){var e=this._recognizeDimIndex(t);if(e==null)return t;if(e=t,!this._dimOmitted)return this.dimensions[e];var i=this._dimIdxToName.get(e);if(i!=null)return i;var n=this._schema.getSourceDimension(e);if(n)return n.name},r.prototype.getDimensionIndex=function(t){var e=this._recognizeDimIndex(t);if(e!=null)return e;if(t==null)return-1;var i=this._getDimInfo(t);return i?i.storeDimIndex:this._dimOmitted?this._schema.getSourceDimensionIndex(t):-1},r.prototype._recognizeDimIndex=function(t){if(mt(t)||t!=null&&!isNaN(t)&&!this._getDimInfo(t)&&(!this._dimOmitted||this._schema.getSourceDimensionIndex(t)<0))return+t},r.prototype._getStoreDimIndex=function(t){var e=this.getDimensionIndex(t);return e},r.prototype.getDimensionInfo=function(t){return this._getDimInfo(this.getDimension(t))},r.prototype._initGetDimensionInfo=function(t){var e=this._dimInfos;this._getDimInfo=t?function(i){return e.hasOwnProperty(i)?e[i]:void 0}:function(i){return e[i]}},r.prototype.getDimensionsOnCoord=function(){return this._dimSummary.dataDimsOnCoord.slice()},r.prototype.mapDimension=function(t,e){var i=this._dimSummary;if(e==null)return i.encodeFirstDimNotExtra[t];var n=i.encode[t];return n?n[e]:null},r.prototype.mapDimensionsAll=function(t){var e=this._dimSummary,i=e.encode[t];return(i||[]).slice()},r.prototype.getStore=function(){return this._store},r.prototype.initData=function(t,e,i){var n=this,a;if(t instanceof hf&&(a=t),!a){var o=this.dimensions,s=Eh(t)||Jt(t)?new zm(t,o.length):t;a=new hf;var l=vr(o,function(u){return{type:n._dimInfos[u].type,property:u}});a.initData(s,l,i)}this._store=a,this._nameList=(e||[]).slice(),this._idList=[],this._nameRepeatCount={},this._doInit(0,a.count()),this._dimSummary=aM(this,this._schema),this.userOutput=this._dimSummary.userOutput},r.prototype.appendData=function(t){var e=this._store.appendData(t);this._doInit(e[0],e[1])},r.prototype.appendValues=function(t,e){var i=this._store.appendValues(t,e&&e.length),n=i.start,a=i.end,o=this._shouldMakeIdFromName();if(this._updateOrdinalMeta(),e)for(var s=n;s<a;s++){var l=s-n;this._nameList[s]=e[l],o&&ou(this,s)}},r.prototype._updateOrdinalMeta=function(){for(var t=this._store,e=this.dimensions,i=0;i<e.length;i++){var n=this._dimInfos[e[i]];n.ordinalMeta&&t.collectOrdinalMeta(n.storeDimIndex,n.ordinalMeta)}},r.prototype._shouldMakeIdFromName=function(){var t=this._store.getProvider();return this._idDimIdx==null&&t.getSource().sourceFormat!==Tr&&!t.fillStorage},r.prototype._doInit=function(t,e){if(!(t>=e)){var i=this._store,n=i.getProvider();this._updateOrdinalMeta();var a=this._nameList,o=this._idList,s=n.getSource().sourceFormat,l=s===ae;if(l&&!n.pure)for(var u=[],f=t;f<e;f++){var h=n.getItem(f,u);if(!this.hasItemOption&&eS(h)&&(this.hasItemOption=!0),h){var c=h.name;a[f]==null&&c!=null&&(a[f]=He(c,null));var v=h.id;o[f]==null&&v!=null&&(o[f]=He(v,null))}}if(this._shouldMakeIdFromName())for(var f=t;f<e;f++)ou(this,f);Od(this)}},r.prototype.getApproximateExtent=function(t){return this._approximateExtent[t]||this._store.getDataExtent(this._getStoreDimIndex(t))},r.prototype.setApproximateExtent=function(t,e){e=this.getDimension(e),this._approximateExtent[e]=t.slice()},r.prototype.getCalculationInfo=function(t){return this._calculationInfo[t]},r.prototype.setCalculationInfo=function(t,e){Dn(t)?O(this._calculationInfo,t):this._calculationInfo[t]=e},r.prototype.getName=function(t){var e=this.getRawIndex(t),i=this._nameList[e];return i==null&&this._nameDimIdx!=null&&(i=An(this,this._nameDimIdx,e)),i==null&&(i=""),i},r.prototype._getCategory=function(t,e){var i=this._store.get(t,e),n=this._store.getOrdinalMeta(t);return n?n.categories[i]:i},r.prototype.getId=function(t){return wo(this,this.getRawIndex(t))},r.prototype.count=function(){return this._store.count()},r.prototype.get=function(t,e){var i=this._store,n=this._dimInfos[t];if(n)return i.get(n.storeDimIndex,e)},r.prototype.getByRawIndex=function(t,e){var i=this._store,n=this._dimInfos[t];if(n)return i.getByRawIndex(n.storeDimIndex,e)},r.prototype.getIndices=function(){return this._store.getIndices()},r.prototype.getDataExtent=function(t){return this._store.getDataExtent(this._getStoreDimIndex(t))},r.prototype.getSum=function(t){return this._store.getSum(this._getStoreDimIndex(t))},r.prototype.getMedian=function(t){return this._store.getMedian(this._getStoreDimIndex(t))},r.prototype.getValues=function(t,e){var i=this,n=this._store;return V(t)?n.getValues(vr(t,function(a){return i._getStoreDimIndex(a)}),e):n.getValues(t)},r.prototype.hasValue=function(t){for(var e=this._dimSummary.dataDimIndicesOnCoord,i=0,n=e.length;i<n;i++)if(isNaN(this._store.get(e[i],t)))return!1;return!0},r.prototype.indexOfName=function(t){for(var e=0,i=this._store.count();e<i;e++)if(this.getName(e)===t)return e;return-1},r.prototype.getRawIndex=function(t){return this._store.getRawIndex(t)},r.prototype.indexOfRawIndex=function(t){return this._store.indexOfRawIndex(t)},r.prototype.rawIndexOf=function(t,e){var i=t&&this._invertedIndicesMap[t],n=i&&i[e];return n==null||isNaN(n)?kd:n},r.prototype.each=function(t,e,i){J(t)&&(i=e,e=t,t=[]);var n=i||this,a=vr(Ln(t),this._getStoreDimIndex,this);this._store.each(a,n?q(e,n):e)},r.prototype.filterSelf=function(t,e,i){J(t)&&(i=e,e=t,t=[]);var n=i||this,a=vr(Ln(t),this._getStoreDimIndex,this);return this._store=this._store.filter(a,n?q(e,n):e),this},r.prototype.selectRange=function(t){var e=this,i={},n=St(t);return T(n,function(a){var o=e._getStoreDimIndex(a);i[o]=t[a]}),this._store=this._store.selectRange(i),this},r.prototype.mapArray=function(t,e,i){J(t)&&(i=e,e=t,t=[]),i=i||this;var n=[];return this.each(t,function(){n.push(e&&e.apply(this,arguments))},i),n},r.prototype.map=function(t,e,i,n){var a=i||n||this,o=vr(Ln(t),this._getStoreDimIndex,this),s=In(this);return s._store=this._store.map(o,a?q(e,a):e),s},r.prototype.modify=function(t,e,i,n){var a=i||n||this,o=vr(Ln(t),this._getStoreDimIndex,this);this._store.modify(o,a?q(e,a):e)},r.prototype.downSample=function(t,e,i,n){var a=In(this);return a._store=this._store.downSample(this._getStoreDimIndex(t),e,i,n),a},r.prototype.minmaxDownSample=function(t,e){var i=In(this);return i._store=this._store.minmaxDownSample(this._getStoreDimIndex(t),e),i},r.prototype.lttbDownSample=function(t,e){var i=In(this);return i._store=this._store.lttbDownSample(this._getStoreDimIndex(t),e),i},r.prototype.getRawDataItem=function(t){return this._store.getRawDataItem(t)},r.prototype.getItemModel=function(t){var e=this.hostModel,i=this.getRawDataItem(t);return new xt(i,e,e&&e.ecModel)},r.prototype.diff=function(t){var e=this;return new iM(t?t.getStore().getIndices():[],this.getStore().getIndices(),function(i){return wo(t,i)},function(i){return wo(e,i)})},r.prototype.getVisual=function(t){var e=this._visual;return e&&e[t]},r.prototype.setVisual=function(t,e){this._visual=this._visual||{},Dn(t)?O(this._visual,t):this._visual[t]=e},r.prototype.getItemVisual=function(t,e){var i=this._itemVisuals[t],n=i&&i[e];return n??this.getVisual(e)},r.prototype.hasItemVisual=function(){return this._itemVisuals.length>0},r.prototype.ensureUniqueItemVisual=function(t,e){var i=this._itemVisuals,n=i[t];n||(n=i[t]={});var a=n[e];return a==null&&(a=this.getVisual(e),V(a)?a=a.slice():Dn(a)&&(a=O({},a)),n[e]=a),a},r.prototype.setItemVisual=function(t,e,i){var n=this._itemVisuals[t]||{};this._itemVisuals[t]=n,Dn(e)?O(n,e):n[e]=i},r.prototype.clearAllVisual=function(){this._visual={},this._itemVisuals=[]},r.prototype.setLayout=function(t,e){Dn(t)?O(this._layout,t):this._layout[t]=e},r.prototype.getLayout=function(t){return this._layout[t]},r.prototype.getItemLayout=function(t){return this._itemLayouts[t]},r.prototype.setItemLayout=function(t,e,i){this._itemLayouts[t]=i?O(this._itemLayouts[t]||{},e):e},r.prototype.clearItemLayouts=function(){this._itemLayouts.length=0},r.prototype.setItemGraphicEl=function(t,e){var i=this.hostModel&&this.hostModel.seriesIndex;pw(i,this.dataType,t,e),this._graphicEls[t]=e},r.prototype.getItemGraphicEl=function(t){return this._graphicEls[t]},r.prototype.eachItemGraphicEl=function(t,e){T(this._graphicEls,function(i,n){i&&t&&t.call(e,i,n)})},r.prototype.cloneShallow=function(t){return t||(t=new r(this._schema?this._schema:vr(this.dimensions,this._getDimInfo,this),this.hostModel)),au(t,this),t._store=this._store,t},r.prototype.wrapMethod=function(t,e){var i=this[t];J(i)&&(this.__wrappedMethods=this.__wrappedMethods||[],this.__wrappedMethods.push(t),this[t]=function(){var n=i.apply(this,arguments);return e.apply(this,[n].concat(Uf(arguments)))})},r.internalField=(function(){Od=function(t){var e=t._invertedIndicesMap;T(e,function(i,n){var a=t._dimInfos[n],o=a.ordinalMeta,s=t._store;if(o){i=e[n]=new fM(o.categories.length);for(var l=0;l<i.length;l++)i[l]=kd;for(var l=0;l<s.count();l++)i[s.get(a.storeDimIndex,l)]=l}})},An=function(t,e,i){return He(t._getCategory(e,i),null)},wo=function(t,e){var i=t._idList[e];return i==null&&t._idDimIdx!=null&&(i=An(t,t._idDimIdx,e)),i==null&&(i=hM+e),i},Ln=function(t){return V(t)||(t=t!=null?[t]:[]),t},In=function(t){var e=new r(t._schema?t._schema:vr(t.dimensions,t._getDimInfo,t),t.hostModel);return au(e,t),e},au=function(t,e){T(vM.concat(e.__wrappedMethods||[]),function(i){e.hasOwnProperty(i)&&(t[i]=e[i])}),t.__wrappedMethods=e.__wrappedMethods,T(cM,function(i){t[i]=it(e[i])}),t._calculationInfo=O({},e._calculationInfo)},ou=function(t,e){var i=t._nameList,n=t._idList,a=t._nameDimIdx,o=t._idDimIdx,s=i[e],l=n[e];if(s==null&&a!=null&&(i[e]=s=An(t,a,e)),l==null&&o!=null&&(n[e]=l=An(t,o,e)),l==null&&s!=null){var u=t._nameRepeatCount,f=u[s]=(u[s]||0)+1;l=s,f>1&&(l+="__ec__"+f),n[e]=l}}})(),r})();function pM(r,t){Eh(r)||(r=Bm(r)),t=t||{};var e=t.coordDimensions||[],i=t.dimensionsDefine||r.dimensionsDefine||[],n=Q(),a=[],o=mM(r,e,i,t.dimensionsCount),s=t.canOmitUnusedDimensions&&By(o),l=i===r.dimensionsDefine,u=l?Oy(r):ky(i),f=t.encodeDefine;!f&&t.encodeDefaulter&&(f=t.encodeDefaulter(r,o));for(var h=Q(f),c=new Um(o),v=0;v<c.length;v++)c[v]=-1;function d(C){var M=c[C];if(M<0){var A=i[C],P=Z(A)?A:{name:A},L=new Go,I=P.name;I!=null&&u.get(I)!=null&&(L.name=L.displayName=I),P.type!=null&&(L.type=P.type),P.displayName!=null&&(L.displayName=P.displayName);var E=a.length;return c[C]=E,L.storeDimIndex=C,a.push(L),L}return a[M]}if(!s)for(var v=0;v<o;v++)d(v);h.each(function(C,M){var A=Yt(C).slice();if(A.length===1&&!W(A[0])&&A[0]<0){h.set(M,!1);return}var P=h.set(M,[]);T(A,function(L,I){var E=W(L)?u.get(L):L;E!=null&&E<o&&(P[I]=E,m(d(E),M,I))})});var g=0;T(e,function(C){var M,A,P,L;if(W(C))M=C,L={};else{L=C,M=L.name;var I=L.ordinalMeta;L.ordinalMeta=null,L=O({},L),L.ordinalMeta=I,A=L.dimsDef,P=L.otherDims,L.name=L.coordDim=L.coordDimIndex=L.dimsDef=L.otherDims=null}var E=h.get(M);if(E!==!1){if(E=Yt(E),!E.length)for(var k=0;k<(A&&A.length||1);k++){for(;g<o&&d(g).coordDim!=null;)g++;g<o&&E.push(g++)}T(E,function(U,z){var R=d(U);if(l&&L.type!=null&&(R.type=L.type),m(ht(R,L),M,z),R.name==null&&A){var F=A[z];!Z(F)&&(F={name:F}),R.name=R.displayName=F.name,R.defaultTooltip=F.defaultTooltip}P&&ht(R.otherDims,P)})}});function m(C,M,A){Am.get(M)!=null?C.otherDims[M]=A:(C.coordDim=M,C.coordDimIndex=A,n.set(M,!0))}var p=t.generateCoord,y=t.generateCoordCount,_=y!=null;y=p?y||1:0;var S=p||"value";function x(C){C.name==null&&(C.name=C.coordDim)}if(s)T(a,function(C){x(C)}),a.sort(function(C,M){return C.storeDimIndex-M.storeDimIndex});else for(var w=0;w<o;w++){var b=d(w),D=b.coordDim;D==null&&(b.coordDim=yM(S,n,_),b.coordDimIndex=0,(!p||y<=0)&&(b.isExtraCoord=!0),y--),x(b),b.type==null&&(Rm(r,w)===ee.Must||b.isExtraCoord&&(b.otherDims.itemName!=null||b.otherDims.seriesName!=null))&&(b.type="ordinal")}return gM(a),new Ry({source:r,dimensions:a,fullDimensionCount:o,dimensionOmitted:s})}function gM(r){for(var t=Q(),e=0;e<r.length;e++){var i=r[e],n=i.name,a=t.get(n)||0;a>0&&(i.name=n+(a-1)),a++,t.set(n,a)}}function mM(r,t,e,i){var n=Math.max(r.dimensionsDetectedCount||1,t.length,e.length,i||0);return T(t,function(a){var o;Z(a)&&(o=a.dimsDef)&&(n=Math.max(n,o.length))}),n}function yM(r,t,e){if(e||t.hasKey(r)){for(var i=0;t.hasKey(r+i);)i++;r+=i}return t.set(r,!0),r}var _M=(function(){function r(t){this.coordSysDims=[],this.axisMap=Q(),this.categoryAxisMap=Q(),this.coordSysName=t}return r})();function SM(r){var t=r.get("coordinateSystem"),e=new _M(t),i=wM[t];if(i)return i(r,e,e.axisMap,e.categoryAxisMap),e}var wM={cartesian2d:function(r,t,e,i){var n=r.getReferringComponents("xAxis",Wt).models[0],a=r.getReferringComponents("yAxis",Wt).models[0];t.coordSysDims=["x","y"],e.set("x",n),e.set("y",a),Wi(n)&&(i.set("x",n),t.firstCategoryDimIndex=0),Wi(a)&&(i.set("y",a),t.firstCategoryDimIndex==null&&(t.firstCategoryDimIndex=1))},singleAxis:function(r,t,e,i){var n=r.getReferringComponents("singleAxis",Wt).models[0];t.coordSysDims=["single"],e.set("single",n),Wi(n)&&(i.set("single",n),t.firstCategoryDimIndex=0)},polar:function(r,t,e,i){var n=r.getReferringComponents("polar",Wt).models[0],a=n.findAxisModel("radiusAxis"),o=n.findAxisModel("angleAxis");t.coordSysDims=["radius","angle"],e.set("radius",a),e.set("angle",o),Wi(a)&&(i.set("radius",a),t.firstCategoryDimIndex=0),Wi(o)&&(i.set("angle",o),t.firstCategoryDimIndex==null&&(t.firstCategoryDimIndex=1))},geo:function(r,t,e,i){t.coordSysDims=["lng","lat"]},parallel:function(r,t,e,i){var n=r.ecModel,a=n.getComponent("parallel",r.get("parallelIndex")),o=t.coordSysDims=a.dimensions.slice();T(a.parallelAxisIndex,function(s,l){var u=n.getComponent("parallelAxis",s),f=o[l];e.set(f,u),Wi(u)&&(i.set(f,u),t.firstCategoryDimIndex==null&&(t.firstCategoryDimIndex=l))})},matrix:function(r,t,e,i){var n=r.getReferringComponents("matrix",Wt).models[0];t.coordSysDims=["x","y"];var a=n.getDimensionModel("x"),o=n.getDimensionModel("y");e.set("x",a),e.set("y",o),i.set("x",a),i.set("y",o)}};function Wi(r){return r.get("type")==="category"}function xM(r,t,e){e=e||{};var i=e.byIndex,n=e.stackedCoordDimension,a,o,s;bM(t)?a=t:(o=t.schema,a=o.dimensions,s=t.store);var l=!!(r&&r.get("stack")),u,f,h,c;if(T(a,function(y,_){W(y)&&(a[_]=y={name:y}),l&&!y.isExtraCoord&&(!i&&!u&&y.ordinalMeta&&(u=y),!f&&y.type!=="ordinal"&&y.type!=="time"&&(!n||n===y.coordDim)&&(f=y))}),f&&!i&&!u&&(i=!0),f){h="__\0ecstackresult_"+r.id,c="__\0ecstackedover_"+r.id,u&&(u.createInvertedIndices=!0);var v=f.coordDim,d=f.type,g=0;T(a,function(y){y.coordDim===v&&g++});var m={name:h,coordDim:v,coordDimIndex:g,type:d,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:a.length},p={name:c,coordDim:c,coordDimIndex:g+1,type:d,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:a.length+1};o?(s&&(m.storeDimIndex=s.ensureCalculationDimension(c,d),p.storeDimIndex=s.ensureCalculationDimension(h,d)),o.appendCalculationDimension(m),o.appendCalculationDimension(p)):(a.push(m),a.push(p))}return{stackedDimension:f&&f.name,stackedByDimension:u&&u.name,isStackedByIndex:i,stackedOverDimension:c,stackResultDimension:h}}function bM(r){return!Ey(r.schema)}function xa(r,t){return!!t&&t===r.getCalculationInfo("stackedDimension")}function TM(r,t){return xa(r,t)?r.getCalculationInfo("stackResultDimension"):t}function CM(r,t){var e=r.get("coordinateSystem"),i=Lh.get(e),n;return t&&t.coordSysDims&&(n=K(t.coordSysDims,function(a){var o={name:a},s=t.axisMap.get(a);if(s){var l=s.get("type");o.type=oM(l)}return o})),n||(n=i&&(i.getDimensionsInfo?i.getDimensionsInfo():i.dimensions.slice())||["x","y"]),n}function MM(r,t,e){var i,n;return e&&T(r,function(a,o){var s=a.coordDim,l=e.categoryAxisMap.get(s);l&&(i==null&&(i=o),a.ordinalMeta=l.getOrdinalMeta(),t&&(a.createInvertedIndices=!0)),a.otherDims.itemName!=null&&(n=!0)}),!n&&i!=null&&(r[i].otherDims.itemName=0),i}function DM(r,t,e){e=e||{};var i=t.getSourceManager(),n,a=!1;n=i.getSource(),a=n.sourceFormat===ae;var o=SM(t),s=CM(t,o),l=e.useEncodeDefaulter,u=J(l)?l:l?Mt(yb,s,t):null,f={coordDimensions:s,generateCoord:e.generateCoord,encodeDefine:t.getEncode(),encodeDefaulter:u,canOmitUnusedDimensions:!a},h=pM(n,f),c=MM(h.dimensions,e.createInvertedIndices,o),v=a?null:i.getSharedDataStore(h),d=xM(t,{schema:h,store:v}),g=new dM(h,t);g.setCalculationInfo(d);var m=c!=null&&AM(n)?function(p,y,_,S){return S===c?_:this.defaultDimValueGetter(p,y,_,S)}:null;return g.hasItemOption=!1,g.initData(a?n:v,null,m),g}function AM(r){if(r.sourceFormat===ae){var t=LM(r.data||[]);return!V(Pa(t))}}function LM(r){for(var t=0;t<r.length&&r[t]==null;)t++;return r[t]}function Tf(r){return r.type==="interval"||r.type==="log"}function IM(r,t,e,i,n){var a={},o=a.interval=Sg(t/e);i!=null&&o<i&&(o=a.interval=i),n!=null&&o>n&&(o=a.interval=n);var s=a.intervalPrecision=ba(o),l=a.niceTickExtent=[Bt(Math.ceil(r[0]/o)*o,s),Bt(Math.floor(r[1]/o)*o,s)];return PM(l,r),a}function su(r){var t=Math.pow(10,Qf(r)),e=r/t;return e?e===2?e=3:e===3?e=5:e*=2:e=1,Bt(e*t)}function ba(r){return tr(r)+2}function Bd(r,t,e){r[t]=Math.max(Math.min(r[t],e[1]),e[0])}function PM(r,t){!isFinite(r[0])&&(r[0]=t[0]),!isFinite(r[1])&&(r[1]=t[1]),Bd(r,0,t),Bd(r,1,t),r[0]>r[1]&&(r[0]=r[1])}function Vh(r,t){return r>=t[0]&&r<=t[1]}var RM=(function(){function r(){this.normalize=Nd,this.scale=Fd}return r.prototype.updateMethods=function(t){t.hasBreaks()?(this.normalize=q(t.normalize,t),this.scale=q(t.scale,t)):(this.normalize=Nd,this.scale=Fd)},r})();function Nd(r,t){return t[1]===t[0]?.5:(r-t[0])/(t[1]-t[0])}function Fd(r,t){return r*(t[1]-t[0])+t[0]}function Cf(r,t,e){var i=Math.log(r);return[Math.log(e?t[0]:Math.max(0,t[0]))/i,Math.log(e?t[1]:Math.max(0,t[1]))/i]}var kr=(function(){function r(t){this._calculator=new RM,this._setting=t||{},this._extent=[1/0,-1/0]}return r.prototype.getSetting=function(t){return this._setting[t]},r.prototype._innerUnionExtent=function(t){var e=this._extent;this._innerSetExtent(t[0]<e[0]?t[0]:e[0],t[1]>e[1]?t[1]:e[1])},r.prototype.unionExtentFromData=function(t,e){this._innerUnionExtent(t.getApproximateExtent(e))},r.prototype.getExtent=function(){return this._extent.slice()},r.prototype.setExtent=function(t,e){this._innerSetExtent(t,e)},r.prototype._innerSetExtent=function(t,e){var i=this._extent;isNaN(t)||(i[0]=t),isNaN(e)||(i[1]=e),this._brkCtx&&this._brkCtx.update(i)},r.prototype.setBreaksFromOption=function(t){},r.prototype._innerSetBreak=function(t){this._brkCtx&&(this._brkCtx.setBreaks(t),this._calculator.updateMethods(this._brkCtx),this._brkCtx.update(this._extent))},r.prototype._innerGetBreaks=function(){return this._brkCtx?this._brkCtx.breaks:[]},r.prototype.hasBreaks=function(){return this._brkCtx?this._brkCtx.hasBreaks():!1},r.prototype._getExtentSpanWithBreaks=function(){return this._brkCtx&&this._brkCtx.hasBreaks()?this._brkCtx.getExtentSpan():this._extent[1]-this._extent[0]},r.prototype.isInExtentRange=function(t){return this._extent[0]<=t&&this._extent[1]>=t},r.prototype.isBlank=function(){return this._isBlank},r.prototype.setBlank=function(t){this._isBlank=t},r})();Rs(kr);var EM=0,Mf=(function(){function r(t){this.categories=t.categories||[],this._needCollect=t.needCollect,this._deduplication=t.deduplication,this.uid=++EM,this._onCollect=t.onCollect}return r.createByAxisModel=function(t){var e=t.option,i=e.data,n=i&&K(i,kM);return new r({categories:n,needCollect:!n,deduplication:e.dedplication!==!1})},r.prototype.getOrdinal=function(t){return this._getOrCreateMap().get(t)},r.prototype.parseAndCollect=function(t){var e,i=this._needCollect;if(!W(t)&&!i)return t;if(i&&!this._deduplication)return e=this.categories.length,this.categories[e]=t,this._onCollect&&this._onCollect(t,e),e;var n=this._getOrCreateMap();return e=n.get(t),e==null&&(i?(e=this.categories.length,this.categories[e]=t,n.set(t,e),this._onCollect&&this._onCollect(t,e)):e=NaN),e},r.prototype._getOrCreateMap=function(){return this._map||(this._map=Q(this.categories))},r})();function kM(r){return Z(r)&&r.value!=null?r.value:r+""}var Ny=(function(r){B(t,r);function t(e){var i=r.call(this,e)||this;i.type="ordinal";var n=i.getSetting("ordinalMeta");return n||(n=new Mf({})),V(n)&&(n=new Mf({categories:K(n,function(a){return Z(a)?a.value:a})})),i._ordinalMeta=n,i._extent=i.getSetting("extent")||[0,n.categories.length-1],i}return t.prototype.parse=function(e){return e==null?NaN:W(e)?this._ordinalMeta.getOrdinal(e):Math.round(e)},t.prototype.contain=function(e){return Vh(e,this._extent)&&e>=0&&e<this._ordinalMeta.categories.length},t.prototype.normalize=function(e){return e=this._getTickNumber(e),this._calculator.normalize(e,this._extent)},t.prototype.scale=function(e){return e=Math.round(this._calculator.scale(e,this._extent)),this.getRawOrdinalNumber(e)},t.prototype.getTicks=function(){for(var e=[],i=this._extent,n=i[0];n<=i[1];)e.push({value:n}),n++;return e},t.prototype.getMinorTicks=function(e){},t.prototype.setSortInfo=function(e){if(e==null){this._ordinalNumbersByTick=this._ticksByOrdinalNumber=null;return}for(var i=e.ordinalNumbers,n=this._ordinalNumbersByTick=[],a=this._ticksByOrdinalNumber=[],o=0,s=this._ordinalMeta.categories.length,l=Math.min(s,i.length);o<l;++o){var u=i[o];n[o]=u,a[u]=o}for(var f=0;o<s;++o){for(;a[f]!=null;)f++;n.push(f),a[f]=o}},t.prototype._getTickNumber=function(e){var i=this._ticksByOrdinalNumber;return i&&e>=0&&e<i.length?i[e]:e},t.prototype.getRawOrdinalNumber=function(e){var i=this._ordinalNumbersByTick;return i&&e>=0&&e<i.length?i[e]:e},t.prototype.getLabel=function(e){if(!this.isBlank()){var i=this.getRawOrdinalNumber(e.value),n=this._ordinalMeta.categories[i];return n==null?"":n+""}},t.prototype.count=function(){return this._extent[1]-this._extent[0]+1},t.prototype.isInExtentRange=function(e){return e=this._getTickNumber(e),this._extent[0]<=e&&this._extent[1]>=e},t.prototype.getOrdinalMeta=function(){return this._ordinalMeta},t.prototype.calcNiceTicks=function(){},t.prototype.calcNiceExtent=function(){},t.type="ordinal",t})(kr);kr.registerClass(Ny);var cr=Bt,fn=(function(r){B(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type="interval",e._interval=0,e._intervalPrecision=2,e}return t.prototype.parse=function(e){return e==null||e===""?NaN:Number(e)},t.prototype.contain=function(e){return Vh(e,this._extent)},t.prototype.normalize=function(e){return this._calculator.normalize(e,this._extent)},t.prototype.scale=function(e){return this._calculator.scale(e,this._extent)},t.prototype.getInterval=function(){return this._interval},t.prototype.setInterval=function(e){this._interval=e,this._niceExtent=this._extent.slice(),this._intervalPrecision=ba(e)},t.prototype.getTicks=function(e){e=e||{};var i=this._interval,n=this._extent,a=this._niceExtent,o=this._intervalPrecision,s=fs(),l=[];if(!i)return l;e.breakTicks;var u=1e4;n[0]<a[0]&&(e.expandToNicedExtent?l.push({value:cr(a[0]-i,o)}):l.push({value:n[0]}));for(var f=function(d,g){return Math.round((g-d)/i)},h=a[0];h<=a[1];){if(l.push({value:h}),h=cr(h+i,o),this._brkCtx){var c=this._brkCtx.calcNiceTickMultiple(h,f);c>=0&&(h=cr(h+c*i,o))}if(l.length>0&&h===l[l.length-1].value)break;if(l.length>u)return[]}var v=l.length?l[l.length-1].value:a[1];return n[1]>v&&(e.expandToNicedExtent?l.push({value:cr(v+i,o)}):l.push({value:n[1]})),e.breakTicks,l},t.prototype.getMinorTicks=function(e){for(var i=this.getTicks({expandToNicedExtent:!0}),n=[],a=this.getExtent(),o=1;o<i.length;o++){var s=i[o],l=i[o-1];if(!(l.break||s.break)){for(var u=0,f=[],h=s.value-l.value,c=h/e,v=ba(c);u<e-1;){var d=cr(l.value+(u+1)*c,v);d>a[0]&&d<a[1]&&f.push(d),u++}var g=fs();g&&g.pruneTicksByBreak("auto",f,this._getNonTransBreaks(),function(m){return m},this._interval,a),n.push(f)}}return n},t.prototype._getNonTransBreaks=function(){return this._brkCtx?this._brkCtx.breaks:[]},t.prototype.getLabel=function(e,i){if(e==null)return"";var n=i&&i.precision;n==null?n=tr(e.value)||0:n==="auto"&&(n=this._intervalPrecision);var a=cr(e.value,n,!0);return bm(a)},t.prototype.calcNiceTicks=function(e,i,n){e=e||5;var a=this._extent.slice(),o=this._getExtentSpanWithBreaks();if(isFinite(o)){o<0&&(o=-o,a.reverse(),this._innerSetExtent(a[0],a[1]),a=this._extent.slice());var s=IM(a,o,e,i,n);this._intervalPrecision=s.intervalPrecision,this._interval=s.interval,this._niceExtent=s.niceTickExtent}},t.prototype.calcNiceExtent=function(e){var i=this._extent.slice();if(i[0]===i[1])if(i[0]!==0){var n=Math.abs(i[0]);e.fixMax||(i[1]+=n/2),i[0]-=n/2}else i[1]=1;var a=i[1]-i[0];isFinite(a)||(i[0]=0,i[1]=1),this._innerSetExtent(i[0],i[1]),i=this._extent.slice(),this.calcNiceTicks(e.splitNumber,e.minInterval,e.maxInterval);var o=this._interval,s=this._intervalPrecision;e.fixMin||(i[0]=cr(Math.floor(i[0]/o)*o,s)),e.fixMax||(i[1]=cr(Math.ceil(i[1]/o)*o,s)),this._innerSetExtent(i[0],i[1])},t.prototype.setNiceExtent=function(e,i){this._niceExtent=[e,i]},t.type="interval",t})(kr);kr.registerClass(fn);var Fy=typeof Float32Array<"u",OM=Fy?Float32Array:Array;function tn(r){return V(r)?Fy?new Float32Array(r):r:new OM(r)}var BM="__ec_stack_";function NM(r){return r.get("stack")||BM+r.seriesIndex}function zy(r){return r.dim+r.index}function FM(r,t){var e=[];return t.eachSeriesByType(r,function(i){WM(i)&&e.push(i)}),e}function zM(r){var t={};T(r,function(l){var u=l.coordinateSystem,f=u.getBaseAxis();if(!(f.type!=="time"&&f.type!=="value"))for(var h=l.getData(),c=f.dim+"_"+f.index,v=h.getDimensionIndex(h.mapDimension(f.dim)),d=h.getStore(),g=0,m=d.count();g<m;++g){var p=d.get(v,g);t[c]?t[c].push(p):t[c]=[p]}});var e={};for(var i in t)if(t.hasOwnProperty(i)){var n=t[i];if(n){n.sort(function(l,u){return l-u});for(var a=null,o=1;o<n.length;++o){var s=n[o]-n[o-1];s>0&&(a=a===null?s:Math.min(a,s))}e[i]=a}}return e}function HM(r){var t=zM(r),e=[];return T(r,function(i){var n=i.coordinateSystem,a=n.getBaseAxis(),o=a.getExtent(),s;if(a.type==="category")s=a.getBandWidth();else if(a.type==="value"||a.type==="time"){var l=a.dim+"_"+a.index,u=t[l],f=Math.abs(o[1]-o[0]),h=a.scale.getExtent(),c=Math.abs(h[1]-h[0]);s=u?f/c*u:f}else{var v=i.getData();s=Math.abs(o[1]-o[0])/v.count()}var d=Ot(i.get("barWidth"),s),g=Ot(i.get("barMaxWidth"),s),m=Ot(i.get("barMinWidth")||(UM(i)?.5:1),s),p=i.get("barGap"),y=i.get("barCategoryGap"),_=i.get("defaultBarGap");e.push({bandWidth:s,barWidth:d,barMaxWidth:g,barMinWidth:m,barGap:p,barCategoryGap:y,defaultBarGap:_,axisKey:zy(a),stackId:NM(i)})}),GM(e)}function GM(r){var t={};T(r,function(i,n){var a=i.axisKey,o=i.bandWidth,s=t[a]||{bandWidth:o,remainedWidth:o,autoWidthCount:0,categoryGap:null,gap:i.defaultBarGap||0,stacks:{}},l=s.stacks;t[a]=s;var u=i.stackId;l[u]||s.autoWidthCount++,l[u]=l[u]||{width:0,maxWidth:0};var f=i.barWidth;f&&!l[u].width&&(l[u].width=f,f=Math.min(s.remainedWidth,f),s.remainedWidth-=f);var h=i.barMaxWidth;h&&(l[u].maxWidth=h);var c=i.barMinWidth;c&&(l[u].minWidth=c);var v=i.barGap;v!=null&&(s.gap=v);var d=i.barCategoryGap;d!=null&&(s.categoryGap=d)});var e={};return T(t,function(i,n){e[n]={};var a=i.stacks,o=i.bandWidth,s=i.categoryGap;if(s==null){var l=St(a).length;s=Math.max(35-l*4,15)+"%"}var u=Ot(s,o),f=Ot(i.gap,1),h=i.remainedWidth,c=i.autoWidthCount,v=(h-u)/(c+(c-1)*f);v=Math.max(v,0),T(a,function(p){var y=p.maxWidth,_=p.minWidth;if(p.width){var S=p.width;y&&(S=Math.min(S,y)),_&&(S=Math.max(S,_)),p.width=S,h-=S+f*S,c--}else{var S=v;y&&y<S&&(S=Math.min(y,h)),_&&_>S&&(S=_),S!==v&&(p.width=S,h-=S+f*S,c--)}}),v=(h-u)/(c+(c-1)*f),v=Math.max(v,0);var d=0,g;T(a,function(p,y){p.width||(p.width=v),g=p,d+=p.width*(1+f)}),g&&(d-=g.width*f);var m=-d/2;T(a,function(p,y){e[n][y]=e[n][y]||{bandWidth:o,offset:m,width:p.width},m+=p.width*(1+f)})}),e}function VM(r,t,e){if(r&&t){var i=r[zy(t)];return i}}function WM(r){return r.coordinateSystem&&r.coordinateSystem.type==="cartesian2d"}function UM(r){return r.pipelineContext&&r.pipelineContext.large}var YM=function(r,t,e,i){for(;e<i;){var n=e+i>>>1;r[n][1]<t?e=n+1:i=n}return e},Hy=(function(r){B(t,r);function t(e){var i=r.call(this,e)||this;return i.type="time",i}return t.prototype.getLabel=function(e){var i=this.getSetting("useUTC");return Zs(e.value,Ac[eb(ea(this._minLevelUnit))]||Ac.second,i,this.getSetting("locale"))},t.prototype.getFormattedLabel=function(e,i,n){var a=this.getSetting("useUTC"),o=this.getSetting("locale");return rb(e,i,n,o,a)},t.prototype.getTicks=function(e){var i=this._interval,n=this._extent,a=[];if(!i)return a;var o=this.getSetting("useUTC"),s=hs(n[1],o);a.push({value:n[0],time:{level:0,upperTimeUnit:s,lowerTimeUnit:s}});var l=jM(this._minLevelUnit,this._approxInterval,o,n,this._getExtentSpanWithBreaks(),this._brkCtx);a=a.concat(l);var u=hs(n[1],o);a.push({value:n[1],time:{level:0,upperTimeUnit:u,lowerTimeUnit:u}}),this.getSetting("useUTC");var f=yi.length-1,h=0;return T(a,function(c){f=Math.min(f,at(yi,c.time.upperTimeUnit)),h=Math.max(h,c.time.level)}),a},t.prototype.calcNiceExtent=function(e){var i=this.getExtent();if(i[0]===i[1]&&(i[0]-=pe,i[1]+=pe),i[1]===-1/0&&i[0]===1/0){var n=new Date;i[1]=+new Date(n.getFullYear(),n.getMonth(),n.getDate()),i[0]=i[1]-pe}this._innerSetExtent(i[0],i[1]),this.calcNiceTicks(e.splitNumber,e.minInterval,e.maxInterval)},t.prototype.calcNiceTicks=function(e,i,n){e=e||10;var a=this._getExtentSpanWithBreaks();this._approxInterval=a/e,i!=null&&this._approxInterval<i&&(this._approxInterval=i),n!=null&&this._approxInterval>n&&(this._approxInterval=n);var o=xo.length,s=Math.min(YM(xo,this._approxInterval,0,o),o-1);this._interval=xo[s][1],this._intervalPrecision=ba(this._interval),this._minLevelUnit=xo[Math.max(s-1,0)][0]},t.prototype.parse=function(e){return mt(e)?e:+dn(e)},t.prototype.contain=function(e){return Vh(e,this._extent)},t.prototype.normalize=function(e){return this._calculator.normalize(e,this._extent)},t.prototype.scale=function(e){return this._calculator.scale(e,this._extent)},t.type="time",t})(fn),xo=[["second",wh],["minute",xh],["hour",ta],["quarter-day",ta*6],["half-day",ta*12],["day",pe*1.2],["half-week",pe*3.5],["week",pe*7],["month",pe*31],["quarter",pe*95],["half-year",Dc/2],["year",Dc]];function ZM(r,t,e,i){return lf(new Date(t),r,i).getTime()===lf(new Date(e),r,i).getTime()}function XM(r,t){return r/=pe,r>16?16:r>7.5?7:r>3.5?4:r>1.5?2:1}function qM(r){var t=30*pe;return r/=t,r>6?6:r>3?3:r>2?2:1}function $M(r){return r/=ta,r>12?12:r>6?6:r>3.5?4:r>2?2:1}function zd(r,t){return r/=t?xh:wh,r>30?30:r>20?20:r>15?15:r>10?10:r>5?5:r>2?2:1}function KM(r){return Sg(r)}function QM(r,t,e){var i=Math.max(0,at(yi,t)-1);return lf(new Date(r),yi[i],e).getTime()}function JM(r,t){var e=new Date(0);e[r](1);var i=e.getTime();e[r](1+t);var n=e.getTime()-i;return function(a,o){return Math.max(0,Math.round((o-a)/n))}}function jM(r,t,e,i,n,a){var o=1e4,s=Qx,l=0;function u(L,I,E,k,U,z,R){for(var F=JM(U,L),G=I,X=new Date(G);G<E&&G<=i[1]&&(R.push({value:G}),!(l++>o));)if(X[U](X[k]()+L),G=X.getTime(),a){var tt=a.calcNiceTickMultiple(G,F);tt>0&&(X[U](X[k]()+tt*L),G=X.getTime())}R.push({value:G,notAdd:!0})}function f(L,I,E){var k=[],U=!I.length;if(!ZM(ea(L),i[0],i[1],e)){U&&(I=[{value:QM(i[0],L,e)},{value:i[1]}]);for(var z=0;z<I.length-1;z++){var R=I[z].value,F=I[z+1].value;if(R!==F){var G=void 0,X=void 0,tt=void 0,ot=!1;switch(L){case"year":G=Math.max(1,Math.round(t/pe/365)),X=gm(e),tt=ib(e);break;case"half-year":case"quarter":case"month":G=qM(t),X=bh(e),tt=mm(e);break;case"week":case"half-week":case"day":G=XM(t),X=Th(e),tt=ym(e),ot=!0;break;case"half-day":case"quarter-day":case"hour":G=$M(t),X=Ch(e),tt=_m(e);break;case"minute":G=zd(t,!0),X=Mh(e),tt=Sm(e);break;case"second":G=zd(t,!1),X=Dh(e),tt=wm(e);break;case"millisecond":G=KM(t),X=Ah(e),tt=xm(e);break}F>=i[0]&&R<=i[1]&&u(G,R,F,X,tt,ot,k),L==="year"&&E.length>1&&z===0&&E.unshift({value:E[0].value-G})}}for(var z=0;z<k.length;z++)E.push(k[z])}}for(var h=[],c=[],v=0,d=0,g=0;g<s.length;++g){var m=ea(s[g]);if(tb(s[g])){f(s[g],h[h.length-1]||[],c);var p=s[g+1]?ea(s[g+1]):null;if(m!==p){if(c.length){d=v,c.sort(function(L,I){return L.value-I.value});for(var y=[],_=0;_<c.length;++_){var S=c[_].value;(_===0||c[_-1].value!==S)&&(y.push(c[_]),S>=i[0]&&S<=i[1]&&v++)}var x=n/t;if(v>x*1.5&&d>x/1.5||(h.push(y),v>x||r===s[g]))break}c=[]}}}for(var w=Rt(K(h,function(L){return Rt(L,function(I){return I.value>=i[0]&&I.value<=i[1]&&!I.notAdd})}),function(L){return L.length>0}),b=[],D=w.length-1,g=0;g<w.length;++g)for(var C=w[g],M=0;M<C.length;++M){var A=hs(C[M].value,e);b.push({value:C[M].value,time:{level:D-g,upperTimeUnit:A,lowerTimeUnit:A}})}b.sort(function(L,I){return L.value-I.value});for(var P=[],g=0;g<b.length;++g)(g===0||b[g].value!==b[g-1].value)&&P.push(b[g]);return P}kr.registerClass(Hy);var Df=Bt,tD=Math.floor,eD=Math.ceil,bo=Math.pow,To=Math.log,Gy=(function(r){B(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type="log",e.base=10,e._originalScale=new fn,e}return t.prototype.getTicks=function(e){e=e||{};var i=this._extent.slice(),n=this._originalScale.getExtent(),a=r.prototype.getTicks.call(this,e),o=this.base;return this._originalScale._innerGetBreaks(),K(a,function(s){var l=s.value,u=null,f=bo(o,l);l===i[0]&&this._fixMin?u=n[0]:l===i[1]&&this._fixMax&&(u=n[1]);var h;return u!=null&&(f=lu(f,u)),{value:f,break:h}},this)},t.prototype._getNonTransBreaks=function(){return this._originalScale._innerGetBreaks()},t.prototype.setExtent=function(e,i){this._originalScale.setExtent(e,i);var n=Cf(this.base,[e,i]);r.prototype.setExtent.call(this,n[0],n[1])},t.prototype.getExtent=function(){var e=this.base,i=r.prototype.getExtent.call(this);i[0]=bo(e,i[0]),i[1]=bo(e,i[1]);var n=this._originalScale.getExtent();return this._fixMin&&(i[0]=lu(i[0],n[0])),this._fixMax&&(i[1]=lu(i[1],n[1])),i},t.prototype.unionExtentFromData=function(e,i){this._originalScale.unionExtentFromData(e,i);var n=Cf(this.base,e.getApproximateExtent(i),!0);this._innerUnionExtent(n)},t.prototype.calcNiceTicks=function(e){e=e||10;var i=this._extent.slice(),n=this._getExtentSpanWithBreaks();if(!(!isFinite(n)||n<=0)){var a=$1(n),o=e/n*a;for(o<=.5&&(a*=10);!isNaN(a)&&Math.abs(a)<1&&Math.abs(a)>0;)a*=10;var s=[Df(eD(i[0]/a)*a),Df(tD(i[1]/a)*a)];this._interval=a,this._intervalPrecision=ba(a),this._niceExtent=s}},t.prototype.calcNiceExtent=function(e){r.prototype.calcNiceExtent.call(this,e),this._fixMin=e.fixMin,this._fixMax=e.fixMax},t.prototype.contain=function(e){return e=To(e)/To(this.base),r.prototype.contain.call(this,e)},t.prototype.normalize=function(e){return e=To(e)/To(this.base),r.prototype.normalize.call(this,e)},t.prototype.scale=function(e){return e=r.prototype.scale.call(this,e),bo(this.base,e)},t.prototype.setBreaksFromOption=function(e){},t.type="log",t})(fn);function lu(r,t){return Df(r,tr(t))}kr.registerClass(Gy);var rD=(function(){function r(t,e,i){this._prepareParams(t,e,i)}return r.prototype._prepareParams=function(t,e,i){i[1]<i[0]&&(i=[NaN,NaN]),this._dataMin=i[0],this._dataMax=i[1];var n=this._isOrdinal=t.type==="ordinal";this._needCrossZero=t.type==="interval"&&e.getNeedCrossZero&&e.getNeedCrossZero();var a=e.get("min",!0);a==null&&(a=e.get("startValue",!0));var o=this._modelMinRaw=a;J(o)?this._modelMinNum=Co(t,o({min:i[0],max:i[1]})):o!=="dataMin"&&(this._modelMinNum=Co(t,o));var s=this._modelMaxRaw=e.get("max",!0);if(J(s)?this._modelMaxNum=Co(t,s({min:i[0],max:i[1]})):s!=="dataMax"&&(this._modelMaxNum=Co(t,s)),n)this._axisDataLen=e.getCategories().length;else{var l=e.get("boundaryGap"),u=V(l)?l:[l||0,l||0];typeof u[0]=="boolean"||typeof u[1]=="boolean"?this._boundaryGapInner=[0,0]:this._boundaryGapInner=[Si(u[0],1),Si(u[1],1)]}},r.prototype.calculate=function(){var t=this._isOrdinal,e=this._dataMin,i=this._dataMax,n=this._axisDataLen,a=this._boundaryGapInner,o=t?null:i-e||Math.abs(e),s=this._modelMinRaw==="dataMin"?e:this._modelMinNum,l=this._modelMaxRaw==="dataMax"?i:this._modelMaxNum,u=s!=null,f=l!=null;s==null&&(s=t?n?0:NaN:e-a[0]*o),l==null&&(l=t?n?n-1:NaN:i+a[1]*o),(s==null||!isFinite(s))&&(s=NaN),(l==null||!isFinite(l))&&(l=NaN);var h=sa(s)||sa(l)||t&&!n;this._needCrossZero&&(s>0&&l>0&&!u&&(s=0),s<0&&l<0&&!f&&(l=0));var c=this._determinedMin,v=this._determinedMax;return c!=null&&(s=c,u=!0),v!=null&&(l=v,f=!0),{min:s,max:l,minFixed:u,maxFixed:f,isBlank:h}},r.prototype.modifyDataMinMax=function(t,e){this[nD[t]]=e},r.prototype.setDeterminedMinMax=function(t,e){var i=iD[t];this[i]=e},r.prototype.freeze=function(){this.frozen=!0},r})(),iD={min:"_determinedMin",max:"_determinedMax"},nD={min:"_dataMin",max:"_dataMax"};function Vy(r,t,e){var i=r.rawExtentInfo;return i||(i=new rD(r,t,e),r.rawExtentInfo=i,i)}function Co(r,t){return t==null?null:sa(t)?NaN:r.parse(t)}function Wy(r,t){var e=r.type,i=Vy(r,t,r.getExtent()).calculate();r.setBlank(i.isBlank);var n=i.min,a=i.max,o=t.ecModel;if(o&&e==="time"){var s=FM("bar",o),l=!1;if(T(s,function(h){l=l||h.getBaseAxis()===t.axis}),l){var u=HM(s),f=aD(n,a,t,u);n=f.min,a=f.max}}return{extent:[n,a],fixMin:i.minFixed,fixMax:i.maxFixed}}function aD(r,t,e,i){var n=e.axis.getExtent(),a=Math.abs(n[1]-n[0]),o=VM(i,e.axis);if(o===void 0)return{min:r,max:t};var s=1/0;T(o,function(v){s=Math.min(v.offset,s)});var l=-1/0;T(o,function(v){l=Math.max(v.offset+v.width,l)}),s=Math.abs(s),l=Math.abs(l);var u=s+l,f=t-r,h=1-(s+l)/a,c=f/h-f;return t+=c*(l/u),r-=c*(s/u),{min:r,max:t}}function Hd(r,t){var e=t,i=Wy(r,e),n=i.extent,a=e.get("splitNumber");r instanceof Gy&&(r.base=e.get("logBase"));var o=r.type,s=e.get("interval"),l=o==="interval"||o==="time";r.setBreaksFromOption(Zy(e)),r.setExtent(n[0],n[1]),r.calcNiceExtent({splitNumber:a,fixMin:i.fixMin,fixMax:i.fixMax,minInterval:l?e.get("minInterval"):null,maxInterval:l?e.get("maxInterval"):null}),s!=null&&r.setInterval&&r.setInterval(s)}function oD(r,t){if(t=t||r.get("type"),t)switch(t){case"category":return new Ny({ordinalMeta:r.getOrdinalMeta?r.getOrdinalMeta():r.getCategories(),extent:[1/0,-1/0]});case"time":return new Hy({locale:r.ecModel.getLocaleModel(),useUTC:r.ecModel.get("useUTC")});default:return new(kr.getClass(t)||fn)}}function sD(r){var t=r.scale.getExtent(),e=t[0],i=t[1];return!(e>0&&i>0||e<0&&i<0)}function Oa(r){var t=r.getLabelModel().get("formatter");if(r.type==="time"){var e=Jx(t);return function(n,a){return r.scale.getFormattedLabel(n,a,e)}}else{if(W(t))return function(n){var a=r.scale.getLabel(n),o=t.replace("{value}",a??"");return o};if(J(t)){if(r.type==="category")return function(n,a){return t(Ss(r,n),n.value-r.scale.getExtent()[0],null)};var i=fs();return function(n,a){var o=null;return i&&(o=i.makeAxisLabelFormatterParamBreak(o,n.break)),t(Ss(r,n),a,o)}}else return function(n){return r.scale.getLabel(n)}}}function Ss(r,t){return r.type==="category"?r.scale.getLabel(t):t.value}function Wh(r){var t=r.get("interval");return t??"auto"}function Uy(r){return r.type==="category"&&Wh(r.getLabelModel())===0}function Yy(r,t){var e={};return T(r.mapDimensionsAll(t),function(i){e[TM(r,i)]=!0}),St(e)}function lD(r,t,e){t&&T(Yy(t,e),function(i){var n=t.getApproximateExtent(i);n[0]<r[0]&&(r[0]=n[0]),n[1]>r[1]&&(r[1]=n[1])})}function hn(r){return r==="middle"||r==="center"}function Ta(r){return r.getShallow("show")}function Zy(r){var t=r.get("breaks",!0);t==null}var uD=(function(){function r(){}return r.prototype.getNeedCrossZero=function(){var t=this.option;return!t.scale},r.prototype.getCoordSysModel=function(){},r})(),Gd=[],fD={registerPreprocessor:Ly,registerProcessor:Iy,registerPostInit:QC,registerPostUpdate:JC,registerUpdateLifecycle:zh,registerAction:Mi,registerCoordinateSystem:jC,registerLayout:tM,registerVisual:Di,registerTransform:rM,registerLoading:Py,registerMap:eM,registerImpl:PC,PRIORITY:UC,ComponentModel:ut,ComponentView:me,SeriesModel:Ir,ChartView:Ve,registerComponentModel:function(r){ut.registerClass(r)},registerComponentView:function(r){me.registerClass(r)},registerSeriesModel:function(r){Ir.registerClass(r)},registerChartView:function(r){Ve.registerClass(r)},registerCustomSeries:function(r,t){},registerSubTypeDefaulter:function(r,t){ut.registerSubTypeDefaulter(r,t)},registerPainter:function(r,t){W1(r,t)}};function Ue(r){if(V(r)){T(r,function(t){Ue(t)});return}at(Gd,r)>=0||(Gd.push(r),J(r)&&(r={install:r}),r.install(fD))}var hD=yt(),aa=yt(),be={estimate:1,determine:2};function ws(r){return{out:{noPxChangeTryDetermine:[]},kind:r}}function Xy(r,t){var e=K(t,function(i){return r.scale.parse(i)});return r.type==="time"&&e.length>0&&(e.sort(),e.unshift(e[0]),e.push(e[e.length-1])),e}function vD(r,t){var e=r.getLabelModel().get("customValues");if(e){var i=Oa(r),n=r.scale.getExtent(),a=Xy(r,e),o=Rt(a,function(s){return s>=n[0]&&s<=n[1]});return{labels:K(o,function(s){var l={value:s};return{formattedLabel:i(l),rawLabel:r.scale.getLabel(l),tickValue:s,time:void 0,break:void 0}})}}return r.type==="category"?dD(r,t):gD(r)}function cD(r,t,e){var i=r.getTickModel().get("customValues");if(i){var n=r.scale.getExtent(),a=Xy(r,i);return{ticks:Rt(a,function(o){return o>=n[0]&&o<=n[1]})}}return r.type==="category"?pD(r,t):{ticks:K(r.scale.getTicks(e),function(o){return o.value})}}function dD(r,t){var e=r.getLabelModel(),i=qy(r,e,t);return!e.get("show")||r.scale.isBlank()?{labels:[]}:i}function qy(r,t,e){var i=yD(r),n=Wh(t),a=e.kind===be.estimate;if(!a){var o=Ky(i,n);if(o)return o}var s,l;J(n)?s=jy(r,n):(l=n==="auto"?_D(r,e):n,s=Jy(r,l));var u={labels:s,labelCategoryInterval:l};return a?e.out.noPxChangeTryDetermine.push(function(){return Af(i,n,u),!0}):Af(i,n,u),u}function pD(r,t){var e=mD(r),i=Wh(t),n=Ky(e,i);if(n)return n;var a,o;if((!t.get("show")||r.scale.isBlank())&&(a=[]),J(i))a=jy(r,i,!0);else if(i==="auto"){var s=qy(r,r.getLabelModel(),ws(be.determine));o=s.labelCategoryInterval,a=K(s.labels,function(l){return l.tickValue})}else o=i,a=Jy(r,o,!0);return Af(e,i,{ticks:a,tickCategoryInterval:o})}function gD(r){var t=r.scale.getTicks(),e=Oa(r);return{labels:K(t,function(i,n){return{formattedLabel:e(i,n),rawLabel:r.scale.getLabel(i),tickValue:i.value,time:i.time,break:i.break}})}}var mD=$y("axisTick"),yD=$y("axisLabel");function $y(r){return function(e){return aa(e)[r]||(aa(e)[r]={list:[]})}}function Ky(r,t){for(var e=0;e<r.list.length;e++)if(r.list[e].key===t)return r.list[e].value}function Af(r,t,e){return r.list.push({key:t,value:e}),e}function _D(r,t){if(t.kind===be.estimate){var e=r.calculateCategoryInterval(t);return t.out.noPxChangeTryDetermine.push(function(){return aa(r).autoInterval=e,!0}),e}var i=aa(r).autoInterval;return i??(aa(r).autoInterval=r.calculateCategoryInterval(t))}function SD(r,t){var e=t.kind,i=xD(r),n=Oa(r),a=(i.axisRotate-i.labelRotate)/180*Math.PI,o=r.scale,s=o.getExtent(),l=o.count();if(s[1]-s[0]<1)return 0;var u=1,f=40;l>f&&(u=Math.max(1,Math.floor(l/f)));for(var h=s[0],c=r.dataToCoord(h+1)-r.dataToCoord(h),v=Math.abs(c*Math.cos(a)),d=Math.abs(c*Math.sin(a)),g=0,m=0;h<=s[1];h+=u){var p=0,y=0,_=cg(n({value:h}),i.font,"center","top");p=_.width*1.3,y=_.height*1.3,g=Math.max(g,p,7),m=Math.max(m,y,7)}var S=g/v,x=m/d;isNaN(S)&&(S=1/0),isNaN(x)&&(x=1/0);var w=Math.max(0,Math.floor(Math.min(S,x)));if(e===be.estimate)return t.out.noPxChangeTryDetermine.push(q(wD,null,r,w,l)),w;var b=Qy(r,w,l);return b??w}function wD(r,t,e){return Qy(r,t,e)==null}function Qy(r,t,e){var i=hD(r.model),n=r.getExtent(),a=i.lastAutoInterval,o=i.lastTickCount;if(a!=null&&o!=null&&Math.abs(a-t)<=1&&Math.abs(o-e)<=1&&a>t&&i.axisExtent0===n[0]&&i.axisExtent1===n[1])return a;i.lastTickCount=e,i.lastAutoInterval=t,i.axisExtent0=n[0],i.axisExtent1=n[1]}function xD(r){var t=r.getLabelModel();return{axisRotate:r.getRotate?r.getRotate():r.isHorizontal&&!r.isHorizontal()?90:0,labelRotate:t.get("rotate")||0,font:t.getFont()}}function Jy(r,t,e){var i=Oa(r),n=r.scale,a=n.getExtent(),o=r.getLabelModel(),s=[],l=Math.max((t||0)+1,1),u=a[0],f=n.count();u!==0&&l>1&&f/l>2&&(u=Math.round(Math.ceil(u/l)*l));var h=Uy(r),c=o.get("showMinLabel")||h,v=o.get("showMaxLabel")||h;c&&u!==a[0]&&g(a[0]);for(var d=u;d<=a[1];d+=l)g(d);v&&d-l!==a[1]&&g(a[1]);function g(m){var p={value:m};s.push(e?m:{formattedLabel:i(p),rawLabel:n.getLabel(p),tickValue:m,time:void 0,break:void 0})}return s}function jy(r,t,e){var i=r.scale,n=Oa(r),a=[];return T(i.getTicks(),function(o){var s=i.getLabel(o),l=o.value;t(o.value,s)&&a.push(e?l:{formattedLabel:n(o),rawLabel:s,tickValue:l,time:void 0,break:void 0})}),a}var Vd=[0,1],bD=(function(){function r(t,e,i){this.onBand=!1,this.inverse=!1,this.dim=t,this.scale=e,this._extent=i||[0,0]}return r.prototype.contain=function(t){var e=this._extent,i=Math.min(e[0],e[1]),n=Math.max(e[0],e[1]);return t>=i&&t<=n},r.prototype.containData=function(t){return this.scale.contain(this.scale.parse(t))},r.prototype.getExtent=function(){return this._extent.slice()},r.prototype.getPixelPrecision=function(t){return yg(t||this.scale.getExtent(),this._extent)},r.prototype.setExtent=function(t,e){var i=this._extent;i[0]=t,i[1]=e},r.prototype.dataToCoord=function(t,e){var i=this._extent,n=this.scale;return t=n.normalize(n.parse(t)),this.onBand&&n.type==="ordinal"&&(i=i.slice(),Wd(i,n.count())),Pt(t,Vd,i,e)},r.prototype.coordToData=function(t,e){var i=this._extent,n=this.scale;this.onBand&&n.type==="ordinal"&&(i=i.slice(),Wd(i,n.count()));var a=Pt(t,i,Vd,e);return this.scale.scale(a)},r.prototype.pointToData=function(t,e){},r.prototype.getTicksCoords=function(t){t=t||{};var e=t.tickModel||this.getTickModel(),i=cD(this,e,{breakTicks:t.breakTicks,pruneByBreak:t.pruneByBreak}),n=i.ticks,a=K(n,function(s){return{coord:this.dataToCoord(this.scale.type==="ordinal"?this.scale.getRawOrdinalNumber(s):s),tickValue:s}},this),o=e.get("alignWithLabel");return TD(this,a,o,t.clamp),a},r.prototype.getMinorTicksCoords=function(){if(this.scale.type==="ordinal")return[];var t=this.model.getModel("minorTick"),e=t.get("splitNumber");e>0&&e<100||(e=5);var i=this.scale.getMinorTicks(e),n=K(i,function(a){return K(a,function(o){return{coord:this.dataToCoord(o),tickValue:o}},this)},this);return n},r.prototype.getViewLabels=function(t){return t=t||ws(be.determine),vD(this,t).labels},r.prototype.getLabelModel=function(){return this.model.getModel("axisLabel")},r.prototype.getTickModel=function(){return this.model.getModel("axisTick")},r.prototype.getBandWidth=function(){var t=this._extent,e=this.scale.getExtent(),i=e[1]-e[0]+(this.onBand?1:0);i===0&&(i=1);var n=Math.abs(t[1]-t[0]);return Math.abs(n)/i},r.prototype.calculateCategoryInterval=function(t){return t=t||ws(be.determine),SD(this,t)},r})();function Wd(r,t){var e=r[1]-r[0],i=t,n=e/i/2;r[0]+=n,r[1]-=n}function TD(r,t,e,i){var n=t.length;if(!r.onBand||e||!n)return;var a=r.getExtent(),o,s;if(n===1)t[0].coord=a[0],t[0].onBand=!0,o=t[1]={coord:a[1],tickValue:t[0].tickValue,onBand:!0};else{var l=t[n-1].tickValue-t[0].tickValue,u=(t[n-1].coord-t[0].coord)/l;T(t,function(v){v.coord-=u/2,v.onBand=!0});var f=r.scale.getExtent();s=1+f[1]-t[n-1].tickValue,o={coord:t[n-1].coord+u*s,tickValue:f[1]+1,onBand:!0},t.push(o)}var h=a[0]>a[1];c(t[0].coord,a[0])&&(i?t[0].coord=a[0]:t.shift()),i&&c(a[0],t[0].coord)&&t.unshift({coord:a[0],onBand:!0}),c(a[1],o.coord)&&(i?o.coord=a[1]:t.pop()),i&&c(o.coord,a[1])&&t.push({coord:a[1],onBand:!0});function c(v,d){return v=Bt(v),d=Bt(d),h?v>d:v<d}}var Ud=["label","labelLine","layoutOption","priority","defaultAttr","marginForce","minMarginForce","marginDefault","suggestIgnore"],CD=1,xs=2,t0=CD|xs;function bs(r,t,e){e=e||t0,t?r.dirty|=e:r.dirty&=~e}function e0(r,t){return t=t||t0,r.dirty==null||!!(r.dirty&t)}function Rr(r){if(r)return e0(r)&&MD(r,r.label,r),r}function MD(r,t,e){var i=t.getComputedTransform();r.transform=ph(r.transform,i);var n=r.localRect=pa(r.localRect,t.getBoundingRect()),a=t.style,o=a.margin,s=e&&e.marginForce,l=e&&e.minMarginForce,u=e&&e.marginDefault,f=a.__marginType;f==null&&u&&(o=u,f=ji.textMargin);for(var h=0;h<4;h++)uu[h]=f===ji.minMargin&&l&&l[h]!=null?l[h]:s&&s[h]!=null?s[h]:o?o[h]:0;f===ji.textMargin&&ls(n,uu,!1,!1);var c=r.rect=pa(r.rect,n);return i&&c.applyTransform(i),f===ji.minMargin&&ls(c,uu,!1,!1),r.axisAligned=dh(i),(r.label=r.label||{}).ignore=t.ignore,bs(r,!1),bs(r,!0,xs),r}var uu=[0,0,0,0];function DD(r,t,e){return r.transform=ph(r.transform,e),r.localRect=pa(r.localRect,t),r.rect=pa(r.rect,t),e&&r.rect.applyTransform(e),r.axisAligned=dh(e),r.obb=void 0,(r.label=r.label||{}).ignore=!1,r}function AD(r,t){if(r){r.label.x+=t.x,r.label.y+=t.y,r.label.markRedraw();var e=r.transform;e&&(e[4]+=t.x,e[5]+=t.y);var i=r.rect;i&&(i.x+=t.x,i.y+=t.y);var n=r.obb;n&&n.fromBoundingRect(r.localRect,e)}}function Yd(r,t){for(var e=0;e<Ud.length;e++){var i=Ud[e];r[i]==null&&(r[i]=t[i])}return Rr(r)}function Zd(r){var t=r.obb;return(!t||e0(r,xs))&&(r.obb=t=t||new em,t.fromBoundingRect(r.localRect,r.transform),bs(r,!1,xs)),t}function LD(r){var t=[];r.sort(function(u,f){return(f.suggestIgnore?1:0)-(u.suggestIgnore?1:0)||f.priority-u.priority});function e(u){if(!u.ignore){var f=u.ensureState("emphasis");f.ignore==null&&(f.ignore=!1)}u.ignore=!0}for(var i=0;i<r.length;i++){var n=Rr(r[i]);if(!n.label.ignore){for(var a=n.label,o=n.labelLine,s=!1,l=0;l<t.length;l++)if(Uh(n,t[l],null,{touchThreshold:.05})){s=!0;break}s?(e(a),o&&e(o)):t.push(n)}}}function Uh(r,t,e,i){return!r||!t||r.label&&r.label.ignore||t.label&&t.label.ignore||!r.rect.intersect(t.rect,e,i)?!1:r.axisAligned&&t.axisAligned?!0:Zd(r).intersect(Zd(t),e,i)}var r0={left:0,right:0,top:0,bottom:0},Ts=["25%","25%"],ID=(function(r){B(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t.prototype.mergeDefaultAndTheme=function(e,i){var n=pn(e.outerBounds);r.prototype.mergeDefaultAndTheme.apply(this,arguments),n&&e.outerBounds&&Lr(e.outerBounds,n)},t.prototype.mergeOption=function(e,i){r.prototype.mergeOption.apply(this,arguments),this.option.outerBounds&&e.outerBounds&&Lr(this.option.outerBounds,e.outerBounds)},t.type="grid",t.dependencies=["xAxis","yAxis"],t.layoutMode="box",t.defaultOption={show:!1,z:0,left:"15%",top:65,right:"10%",bottom:80,containLabel:!1,outerBoundsMode:"auto",outerBounds:r0,outerBoundsContain:"all",outerBoundsClampWidth:Ts[0],outerBoundsClampHeight:Ts[1],backgroundColor:H.color.transparent,borderWidth:1,borderColor:H.color.neutral30},t})(ut),Lf=(function(r){B(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t.prototype.getCoordSysModel=function(){return this.getReferringComponents("grid",Wt).models[0]},t.type="cartesian2dAxis",t})(ut);Ye(Lf,uD);var i0={show:!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:H.color.axisLine,width:1,type:"solid"},symbol:["none","none"],symbolSize:[10,15],breakLine:!0},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,color:H.color.axisLabel,textMargin:[0,3]},splitLine:{show:!0,showMinLine:!0,showMaxLine:!0,lineStyle:{color:H.color.axisSplitLine,width:1,type:"solid"}},splitArea:{show:!1,areaStyle:{color:[H.color.backgroundTint,H.color.backgroundTransparent]}},breakArea:{show:!0,itemStyle:{color:H.color.neutral00,borderColor:H.color.border,borderWidth:1,borderType:[3,3],opacity:.6},zigzagAmplitude:4,zigzagMinSpan:4,zigzagMaxSpan:20,zigzagZ:100,expandOnClick:!0},breakLabelLayout:{moveOverlap:"auto"}},PD=st({boundaryGap:!0,deduplication:null,jitter:0,jitterOverlap:!0,jitterMargin:2,splitLine:{show:!1},axisTick:{alignWithLabel:!1,interval:"auto",show:"auto"},axisLabel:{interval:"auto"}},i0),Yh=st({boundaryGap:[0,0],axisLine:{show:"auto"},axisTick:{show:"auto"},splitNumber:5,minorTick:{show:!1,splitNumber:5,length:3,lineStyle:{}},minorSplitLine:{show:!1,lineStyle:{color:H.color.axisMinorSplitLine,width:1}}},i0),RD=st({splitNumber:6,axisLabel:{showMinLabel:!1,showMaxLabel:!1,rich:{primary:{fontWeight:"bold"}}},splitLine:{show:!1}},Yh),ED=ht({logBase:10},Yh);const kD={category:PD,value:Yh,time:RD,log:ED};var OD={value:1,category:1,time:1,log:1},BD=null;function ND(){return BD}function Xd(r,t,e,i){T(OD,function(n,a){var o=st(st({},kD[a],!0),i,!0),s=(function(l){B(u,l);function u(){var f=l!==null&&l.apply(this,arguments)||this;return f.type=t+"Axis."+a,f}return u.prototype.mergeDefaultAndTheme=function(f,h){var c=ma(this),v=c?pn(f):{},d=h.getTheme();st(f,d.get(a+"Axis")),st(f,this.getDefaultOption()),f.type=qd(f),c&&Lr(f,v,c)},u.prototype.optionUpdated=function(){var f=this.option;f.type==="category"&&(this.__ordinalMeta=Mf.createByAxisModel(this))},u.prototype.getCategories=function(f){var h=this.option;if(h.type==="category")return f?h.data:this.__ordinalMeta.categories},u.prototype.getOrdinalMeta=function(){return this.__ordinalMeta},u.prototype.updateAxisBreaks=function(f){return{breaks:[]}},u.type=t+"Axis."+a,u.defaultOption=o,u})(e);r.registerComponentModel(s)}),r.registerSubTypeDefaulter(t+"Axis",qd)}function qd(r){return r.type||(r.data?"category":"value")}var FD=(function(){function r(t){this.type="cartesian",this._dimList=[],this._axes={},this.name=t||""}return r.prototype.getAxis=function(t){return this._axes[t]},r.prototype.getAxes=function(){return K(this._dimList,function(t){return this._axes[t]},this)},r.prototype.getAxesByScale=function(t){return t=t.toLowerCase(),Rt(this.getAxes(),function(e){return e.scale.type===t})},r.prototype.addAxis=function(t){var e=t.dim;this._axes[e]=t,this._dimList.push(e)},r})(),If=["x","y"];function $d(r){return(r.type==="interval"||r.type==="time")&&!r.hasBreaks()}var zD=(function(r){B(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type="cartesian2d",e.dimensions=If,e}return t.prototype.calcAffineTransform=function(){this._transform=this._invTransform=null;var e=this.getAxis("x").scale,i=this.getAxis("y").scale;if(!(!$d(e)||!$d(i))){var n=e.getExtent(),a=i.getExtent(),o=this.dataToPoint([n[0],a[0]]),s=this.dataToPoint([n[1],a[1]]),l=n[1]-n[0],u=a[1]-a[0];if(!(!l||!u)){var f=(s[0]-o[0])/l,h=(s[1]-o[1])/u,c=o[0]-n[0]*f,v=o[1]-a[0]*h,d=this._transform=[f,0,0,h,c,v];this._invTransform=La([],d)}}},t.prototype.getBaseAxis=function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAxis("x")},t.prototype.containPoint=function(e){var i=this.getAxis("x"),n=this.getAxis("y");return i.contain(i.toLocalCoord(e[0]))&&n.contain(n.toLocalCoord(e[1]))},t.prototype.containData=function(e){return this.getAxis("x").containData(e[0])&&this.getAxis("y").containData(e[1])},t.prototype.containZone=function(e,i){var n=this.dataToPoint(e),a=this.dataToPoint(i),o=this.getArea(),s=new rt(n[0],n[1],a[0]-n[0],a[1]-n[1]);return o.intersect(s)},t.prototype.dataToPoint=function(e,i,n){n=n||[];var a=e[0],o=e[1];if(this._transform&&a!=null&&isFinite(a)&&o!=null&&isFinite(o))return ge(n,e,this._transform);var s=this.getAxis("x"),l=this.getAxis("y");return n[0]=s.toGlobalCoord(s.dataToCoord(a,i)),n[1]=l.toGlobalCoord(l.dataToCoord(o,i)),n},t.prototype.clampData=function(e,i){var n=this.getAxis("x").scale,a=this.getAxis("y").scale,o=n.getExtent(),s=a.getExtent(),l=n.parse(e[0]),u=a.parse(e[1]);return i=i||[],i[0]=Math.min(Math.max(Math.min(o[0],o[1]),l),Math.max(o[0],o[1])),i[1]=Math.min(Math.max(Math.min(s[0],s[1]),u),Math.max(s[0],s[1])),i},t.prototype.pointToData=function(e,i,n){if(n=n||[],this._invTransform)return ge(n,e,this._invTransform);var a=this.getAxis("x"),o=this.getAxis("y");return n[0]=a.coordToData(a.toLocalCoord(e[0]),i),n[1]=o.coordToData(o.toLocalCoord(e[1]),i),n},t.prototype.getOtherAxis=function(e){return this.getAxis(e.dim==="x"?"y":"x")},t.prototype.getArea=function(e){e=e||0;var i=this.getAxis("x").getGlobalExtent(),n=this.getAxis("y").getGlobalExtent(),a=Math.min(i[0],i[1])-e,o=Math.min(n[0],n[1])-e,s=Math.max(i[0],i[1])-a+e,l=Math.max(n[0],n[1])-o+e;return new rt(a,o,s,l)},t})(FD),HD=(function(r){B(t,r);function t(e,i,n,a,o){var s=r.call(this,e,i,n)||this;return s.index=0,s.type=a||"value",s.position=o||"bottom",s}return t.prototype.isHorizontal=function(){var e=this.position;return e==="top"||e==="bottom"},t.prototype.getGlobalExtent=function(e){var i=this.getExtent();return i[0]=this.toGlobalCoord(i[0]),i[1]=this.toGlobalCoord(i[1]),e&&i[0]>i[1]&&i.reverse(),i},t.prototype.pointToData=function(e,i){return this.coordToData(this.toLocalCoord(e[this.dim==="x"?0:1]),i)},t.prototype.setCategorySortInfo=function(e){if(this.type!=="category")return!1;this.model.option.categorySortInfo=e,this.scale.setSortInfo(e)},t})(bD),GD="expandAxisBreak",Sr=Math.PI,VD=[[1,2,1,2],[5,3,5,3],[8,3,8,3]],WD=[[0,1,0,1],[0,3,0,3],[0,3,0,3]],Ca=yt(),n0=yt(),a0=(function(){function r(t){this.recordMap={},this.resolveAxisNameOverlap=t}return r.prototype.ensureRecord=function(t){var e=t.axis.dim,i=t.componentIndex,n=this.recordMap,a=n[e]||(n[e]=[]);return a[i]||(a[i]={ready:{}})},r})();function UD(r,t,e,i){var n=e.axis,a=t.ensureRecord(e),o=[],s,l=Zh(r.axisName)&&hn(r.nameLocation);T(i,function(d){var g=Rr(d);if(!(!g||g.label.ignore)){o.push(g);var m=a.transGroup;l&&(m.transform?La(Pn,m.transform):Xf(Pn),g.transform&&qn(Pn,Pn,g.transform),rt.copy(Mo,g.localRect),Mo.applyTransform(Pn),s?s.union(Mo):rt.copy(s=new rt(0,0,0,0),Mo))}});var u=Math.abs(a.dirVec.x)>.1?"x":"y",f=a.transGroup[u];if(o.sort(function(d,g){return Math.abs(d.label[u]-f)-Math.abs(g.label[u]-f)}),l&&s){var h=n.getExtent(),c=Math.min(h[0],h[1]),v=Math.max(h[0],h[1])-c;s.union(new rt(c,0,v,1))}a.stOccupiedRect=s,a.labelInfoList=o}var Pn=rr(),Mo=new rt(0,0,0,0),o0=function(r,t,e,i,n,a){if(hn(r.nameLocation)){var o=a.stOccupiedRect;o&&s0(DD({},o,a.transGroup.transform),i,n)}else l0(a.labelInfoList,a.dirVec,i,n)};function s0(r,t,e){var i=new vt;Uh(r,t,i,{direction:Math.atan2(e.y,e.x),bidirectional:!1,touchThreshold:.05})&&AD(t,i)}function l0(r,t,e,i){for(var n=vt.dot(i,t)>=0,a=0,o=r.length;a<o;a++){var s=r[n?a:o-1-a];s.label.ignore||s0(s,e,i)}}var Cr=(function(){function r(t,e,i,n){this.group=new Dt,this._axisModel=t,this._api=e,this._local={},this._shared=n||new a0(o0),this._resetCfgDetermined(i)}return r.prototype.updateCfg=function(t){var e=this._cfg.raw;e.position=t.position,e.labelOffset=t.labelOffset,this._resetCfgDetermined(e)},r.prototype.__getRawCfg=function(){return this._cfg.raw},r.prototype._resetCfgDetermined=function(t){var e=this._axisModel,i=e.getDefaultOption?e.getDefaultOption():{},n=$(t.axisName,e.get("name")),a=e.get("nameMoveOverlap");(a==null||a==="auto")&&(a=$(t.defaultNameMoveOverlap,!0));var o={raw:t,position:t.position,rotation:t.rotation,nameDirection:$(t.nameDirection,1),tickDirection:$(t.tickDirection,1),labelDirection:$(t.labelDirection,1),labelOffset:$(t.labelOffset,0),silent:$(t.silent,!0),axisName:n,nameLocation:en(e.get("nameLocation"),i.nameLocation,"end"),shouldNameMoveOverlap:Zh(n)&&a,optionHideOverlap:e.get(["axisLabel","hideOverlap"]),showMinorTicks:e.get(["minorTick","show"])};this._cfg=o;var s=new Dt({x:o.position[0],y:o.position[1],rotation:o.rotation});s.updateTransform(),this._transformGroup=s;var l=this._shared.ensureRecord(e);l.transGroup=this._transformGroup,l.dirVec=new vt(Math.cos(-o.rotation),Math.sin(-o.rotation))},r.prototype.build=function(t,e){var i=this;return t||(t={axisLine:!0,axisTickLabelEstimate:!1,axisTickLabelDetermine:!0,axisName:!0}),T(YD,function(n){t[n]&&ZD[n](i._cfg,i._local,i._shared,i._axisModel,i.group,i._transformGroup,i._api,e||{})}),this},r.innerTextLayout=function(t,e,i){var n=_g(e-t),a,o;return jo(n)?(o=i>0?"top":"bottom",a="center"):jo(n-Sr)?(o=i>0?"bottom":"top",a="center"):(o="middle",n>0&&n<Sr?a=i>0?"right":"left":a=i>0?"left":"right"),{rotation:n,textAlign:a,textVerticalAlign:o}},r.makeAxisEventDataBase=function(t){var e={componentType:t.mainType,componentIndex:t.componentIndex};return e[t.mainType+"Index"]=t.componentIndex,e},r.isLabelSilent=function(t){var e=t.get("tooltip");return t.get("silent")||!(t.get("triggerEvent")||e&&e.show)},r})(),YD=["axisLine","axisTickLabelEstimate","axisTickLabelDetermine","axisName"],ZD={axisLine:function(r,t,e,i,n,a,o){var s=i.get(["axisLine","show"]);if(s==="auto"&&(s=!0,r.raw.axisLineAutoShow!=null&&(s=!!r.raw.axisLineAutoShow)),!!s){var l=i.axis.getExtent(),u=a.transform,f=[l[0],0],h=[l[1],0],c=f[0]>h[0];u&&(ge(f,f,u),ge(h,h,u));var v=O({lineCap:"round"},i.getModel(["axisLine","lineStyle"]).getLineStyle()),d={strokeContainThreshold:r.raw.strokeContainThreshold||5,silent:!0,z2:1,style:v};if(i.get(["axisLine","breakLine"])&&i.axis.scale.hasBreaks())ND().buildAxisBreakLine(i,n,a,d);else{var g=new Dr(O({shape:{x1:f[0],y1:f[1],x2:h[0],y2:h[1]}},d));ca(g.shape,g.style.lineWidth),g.anid="line",n.add(g)}var m=i.get(["axisLine","symbol"]);if(m!=null){var p=i.get(["axisLine","symbolSize"]);W(m)&&(m=[m,m]),(W(p)||mt(p))&&(p=[p,p]);var y=ly(i.get(["axisLine","symbolOffset"])||0,p),_=p[0],S=p[1];T([{rotate:r.rotation+Math.PI/2,offset:y[0],r:0},{rotate:r.rotation-Math.PI/2,offset:y[1],r:Math.sqrt((f[0]-h[0])*(f[0]-h[0])+(f[1]-h[1])*(f[1]-h[1]))}],function(x,w){if(m[w]!=="none"&&m[w]!=null){var b=Pr(m[w],-_/2,-S/2,_,S,v.stroke,!0),D=x.r+x.offset,C=c?h:f;b.attr({rotation:x.rotate,x:C[0]+D*Math.cos(r.rotation),y:C[1]-D*Math.sin(r.rotation),silent:!0,z2:11}),n.add(b)}})}}},axisTickLabelEstimate:function(r,t,e,i,n,a,o,s){var l=Qd(t,n,s);l&&Kd(r,t,e,i,n,a,o,be.estimate)},axisTickLabelDetermine:function(r,t,e,i,n,a,o,s){var l=Qd(t,n,s);l&&Kd(r,t,e,i,n,a,o,be.determine);var u=KD(r,n,a,i);$D(r,t.labelLayoutList,u),QD(r,n,a,i,r.tickDirection)},axisName:function(r,t,e,i,n,a,o,s){var l=e.ensureRecord(i);t.nameEl&&(n.remove(t.nameEl),t.nameEl=l.nameLayout=l.nameLocation=null);var u=r.axisName;if(Zh(u)){var f=r.nameLocation,h=r.nameDirection,c=i.getModel("nameTextStyle"),v=i.get("nameGap")||0,d=i.axis.getExtent(),g=i.axis.inverse?-1:1,m=new vt(0,0),p=new vt(0,0);f==="start"?(m.x=d[0]-g*v,p.x=-g):f==="end"?(m.x=d[1]+g*v,p.x=g):(m.x=(d[0]+d[1])/2,m.y=r.labelOffset+h*v,p.y=h);var y=rr();p.transform(qf(y,y,r.rotation));var _=i.get("nameRotate");_!=null&&(_=_*Sr/180);var S,x;hn(f)?S=Cr.innerTextLayout(r.rotation,_??r.rotation,h):(S=XD(r.rotation,f,_||0,d),x=r.raw.axisNameAvailableWidth,x!=null&&(x=Math.abs(x/Math.sin(S.rotation)),!isFinite(x)&&(x=null)));var w=c.getFont(),b=i.get("nameTruncate",!0)||{},D=b.ellipsis,C=Uo(r.raw.nameTruncateMaxWidth,b.maxWidth,x),M=s.nameMarginLevel||0,A=new Nt({x:m.x,y:m.y,rotation:S.rotation,silent:Cr.isLabelSilent(i),style:ar(c,{text:u,font:w,overflow:"truncate",width:C,ellipsis:D,fill:c.getTextColor()||i.get(["axisLine","lineStyle","color"]),align:c.get("align")||S.textAlign,verticalAlign:c.get("verticalAlign")||S.textVerticalAlign}),z2:1});if(Ws({el:A,componentModel:i,itemName:u}),A.__fullText=u,A.anid="name",i.get("triggerEvent")){var P=Cr.makeAxisEventDataBase(i);P.targetType="axisName",P.name=u,ft(A).eventData=P}a.add(A),A.updateTransform(),t.nameEl=A;var L=l.nameLayout=Rr({label:A,priority:A.z2,defaultAttr:{ignore:A.ignore},marginDefault:hn(f)?VD[M]:WD[M]});if(l.nameLocation=f,n.add(A),A.decomposeTransform(),r.shouldNameMoveOverlap&&L){var I=e.ensureRecord(i);e.resolveAxisNameOverlap(r,e,i,L,p,I)}}}};function Kd(r,t,e,i,n,a,o,s){f0(t)||JD(r,t,n,s,i,o);var l=t.labelLayoutList;jD(r,i,l,a),r.rotation;var u=r.optionHideOverlap;qD(i,l,u),u&&LD(Rt(l,function(f){return f&&!f.label.ignore})),UD(r,e,i,l)}function XD(r,t,e,i){var n=_g(e-r),a,o,s=i[0]>i[1],l=t==="start"&&!s||t!=="start"&&s;return jo(n-Sr/2)?(o=l?"bottom":"top",a="center"):jo(n-Sr*1.5)?(o=l?"top":"bottom",a="center"):(o="middle",n<Sr*1.5&&n>Sr/2?a=l?"left":"right":a=l?"right":"left"),{rotation:n,textAlign:a,textVerticalAlign:o}}function qD(r,t,e){if(Uy(r.axis))return;function i(s,l,u){var f=Rr(t[l]),h=Rr(t[u]);if(!(!f||!h)){if(s===!1||f.suggestIgnore){Zn(f.label);return}if(h.suggestIgnore){Zn(h.label);return}var c=.1;if(!e){var v=[0,0,0,0];f=Yd({marginForce:v},f),h=Yd({marginForce:v},h)}Uh(f,h,null,{touchThreshold:c})&&Zn(s?h.label:f.label)}}var n=r.get(["axisLabel","showMinLabel"]),a=r.get(["axisLabel","showMaxLabel"]),o=t.length;i(n,0,1),i(a,o-1,o-2)}function $D(r,t,e){r.showMinorTicks||T(t,function(i){if(i&&i.label.ignore)for(var n=0;n<e.length;n++){var a=e[n],o=n0(a),s=Ca(i.label);if(o.tickValue!=null&&!o.onBand&&o.tickValue===s.tickValue){Zn(a);return}}})}function Zn(r){r&&(r.ignore=!0)}function u0(r,t,e,i,n){for(var a=[],o=[],s=[],l=0;l<r.length;l++){var u=r[l].coord;o[0]=u,o[1]=0,s[0]=u,s[1]=e,t&&(ge(o,o,t),ge(s,s,t));var f=new Dr({shape:{x1:o[0],y1:o[1],x2:s[0],y2:s[1]},style:i,z2:2,autoBatch:!0,silent:!0});ca(f.shape,f.style.lineWidth),f.anid=n+"_"+r[l].tickValue,a.push(f);var h=n0(f);h.onBand=!!r[l].onBand,h.tickValue=r[l].tickValue}return a}function KD(r,t,e,i){var n=i.axis,a=i.getModel("axisTick"),o=a.get("show");if(o==="auto"&&(o=!0,r.raw.axisTickAutoShow!=null&&(o=!!r.raw.axisTickAutoShow)),!o||n.scale.isBlank())return[];for(var s=a.getModel("lineStyle"),l=r.tickDirection*a.get("length"),u=n.getTicksCoords(),f=u0(u,e.transform,l,ht(s.getLineStyle(),{stroke:i.get(["axisLine","lineStyle","color"])}),"ticks"),h=0;h<f.length;h++)t.add(f[h]);return f}function QD(r,t,e,i,n){var a=i.axis,o=i.getModel("minorTick");if(!(!r.showMinorTicks||a.scale.isBlank())){var s=a.getMinorTicksCoords();if(s.length)for(var l=o.getModel("lineStyle"),u=n*o.get("length"),f=ht(l.getLineStyle(),ht(i.getModel("axisTick").getLineStyle(),{stroke:i.get(["axisLine","lineStyle","color"])})),h=0;h<s.length;h++)for(var c=u0(s[h],e.transform,u,f,"minorticks_"+h),v=0;v<c.length;v++)t.add(c[v])}}function Qd(r,t,e){if(f0(r)){var i=r.axisLabelsCreationContext,n=i.out.noPxChangeTryDetermine;if(e.noPxChange){for(var a=!0,o=0;o<n.length;o++)a=a&&n[o]();if(a)return!1}n.length&&(t.remove(r.labelGroup),Pf(r,null,null,null))}return!0}function JD(r,t,e,i,n,a){var o=n.axis,s=Uo(r.raw.axisLabelShow,n.get(["axisLabel","show"])),l=new Dt;e.add(l);var u=ws(i);if(!s||o.scale.isBlank()){Pf(t,[],l,u);return}var f=n.getModel("axisLabel"),h=o.getViewLabels(u),c=(Uo(r.raw.labelRotate,f.get("rotate"))||0)*Sr/180,v=Cr.innerTextLayout(r.rotation,c,r.labelDirection),d=n.getCategories&&n.getCategories(!0),g=[],m=n.get("triggerEvent"),p=1/0,y=-1/0;T(h,function(S,x){var w,b=o.scale.type==="ordinal"?o.scale.getRawOrdinalNumber(S.tickValue):S.tickValue,D=S.formattedLabel,C=S.rawLabel,M=f;if(d&&d[b]){var A=d[b];Z(A)&&A.textStyle&&(M=new xt(A.textStyle,f,n.ecModel))}var P=M.getTextColor()||n.get(["axisLine","lineStyle","color"]),L=M.getShallow("align",!0)||v.textAlign,I=$(M.getShallow("alignMinLabel",!0),L),E=$(M.getShallow("alignMaxLabel",!0),L),k=M.getShallow("verticalAlign",!0)||M.getShallow("baseline",!0)||v.textVerticalAlign,U=$(M.getShallow("verticalAlignMinLabel",!0),k),z=$(M.getShallow("verticalAlignMaxLabel",!0),k),R=10+(((w=S.time)===null||w===void 0?void 0:w.level)||0);p=Math.min(p,R),y=Math.max(y,R);var F=new Nt({x:0,y:0,rotation:0,silent:Cr.isLabelSilent(n),z2:R,style:ar(M,{text:D,align:x===0?I:x===h.length-1?E:L,verticalAlign:x===0?U:x===h.length-1?z:k,fill:J(P)?P(o.type==="category"?C:o.type==="value"?b+"":b,x):P})});F.anid="label_"+b;var G=Ca(F);if(G.break=S.break,G.tickValue=b,G.layoutRotation=v.rotation,Ws({el:F,componentModel:n,itemName:D,formatterParamsExtra:{isTruncated:function(){return F.isTruncated},value:C,tickIndex:x}}),m){var X=Cr.makeAxisEventDataBase(n);X.targetType="axisLabel",X.value=C,X.tickIndex=x,S.break&&(X.break={start:S.break.parsedBreak.vmin,end:S.break.parsedBreak.vmax}),o.type==="category"&&(X.dataIndex=b),ft(F).eventData=X,S.break&&eA(n,a,F,S.break)}g.push(F),l.add(F)});var _=K(g,function(S){return{label:S,priority:Ca(S).break?S.z2+(y-p+1):S.z2,defaultAttr:{ignore:S.ignore}}});Pf(t,_,l,u)}function f0(r){return!!r.labelLayoutList}function Pf(r,t,e,i){r.labelLayoutList=t,r.labelGroup=e,r.axisLabelsCreationContext=i}function jD(r,t,e,i){var n=t.get(["axisLabel","margin"]);T(e,function(a,o){var s=Rr(a);if(s){var l=s.label,u=Ca(l);s.suggestIgnore=l.ignore,l.ignore=!1,Zu(Qe,tA),Qe.x=t.axis.dataToCoord(u.tickValue),Qe.y=r.labelOffset+r.labelDirection*n,Qe.rotation=u.layoutRotation,i.add(Qe),Qe.updateTransform(),i.remove(Qe),Qe.decomposeTransform(),Zu(l,Qe),l.markRedraw(),bs(s,!0),Rr(s)}})}var Qe=new wt,tA=new wt;function Zh(r){return!!r}function eA(r,t,e,i){e.on("click",function(n){var a={type:GD,breaks:[{start:i.parsedBreak.breakOption.start,end:i.parsedBreak.breakOption.end}]};a[r.axis.dim+"AxisIndex"]=r.componentIndex,t.dispatchAction(a)})}function Cs(r,t,e){e=e||{};var i=t.axis,n={},a=i.getAxesOnZeroOf()[0],o=i.position,s=a?"onZero":o,l=i.dim,u=[r.x,r.x+r.width,r.y,r.y+r.height],f={left:0,right:1,top:0,bottom:1,onZero:2},h=t.get("offset")||0,c=l==="x"?[u[2]-h,u[3]+h]:[u[0]-h,u[1]+h];if(a){var v=a.toGlobalCoord(a.dataToCoord(0));c[f.onZero]=Math.max(Math.min(v,c[1]),c[0])}n.position=[l==="y"?c[f[s]]:u[0],l==="x"?c[f[s]]:u[3]],n.rotation=Math.PI/2*(l==="x"?0:1);var d={top:-1,bottom:1,left:-1,right:1};n.labelDirection=n.tickDirection=n.nameDirection=d[o],n.labelOffset=a?c[f[o]]-c[f.onZero]:0,t.get(["axisTick","inside"])&&(n.tickDirection=-n.tickDirection),Uo(e.labelInside,t.get(["axisLabel","inside"]))&&(n.labelDirection=-n.labelDirection);var g=t.get(["axisLabel","rotate"]);return n.labelRotate=s==="top"?-g:g,n.z2=1,n}function rA(r){return r.coordinateSystem&&r.coordinateSystem.type==="cartesian2d"}function Jd(r){var t={xAxisModel:null,yAxisModel:null};return T(t,function(e,i){var n=i.replace(/Model$/,""),a=r.getReferringComponents(n,Wt).models[0];t[i]=a}),t}function iA(r,t,e,i,n,a){for(var o=Cs(r,e),s=!1,l=!1,u=0;u<t.length;u++)Tf(t[u].getOtherAxis(e.axis).scale)&&(s=l=!0,e.axis.type==="category"&&e.axis.onBand&&(l=!1));return o.axisLineAutoShow=s,o.axisTickAutoShow=l,o.defaultNameMoveOverlap=a,new Cr(e,i,o,n)}function nA(r,t,e){var i=Cs(t,e);r.updateCfg(i)}function aA(r,t,e){var i=fn.prototype,n=i.getTicks.call(e),a=i.getTicks.call(e,{expandToNicedExtent:!0}),o=n.length-1,s=i.getInterval.call(e),l=Wy(r,t),u=l.extent,f=l.fixMin,h=l.fixMax;r.type==="log"&&(u=Cf(r.base,u,!0)),r.setBreaksFromOption(Zy(t)),r.setExtent(u[0],u[1]),r.calcNiceExtent({splitNumber:o,fixMin:f,fixMax:h});var c=i.getExtent.call(r);f&&(u[0]=c[0]),h&&(u[1]=c[1]);var v=i.getInterval.call(r),d=u[0],g=u[1];if(f&&h)v=(g-d)/o;else if(f)for(g=u[0]+v*o;g<u[1]&&isFinite(g)&&isFinite(u[1]);)v=su(v),g=u[0]+v*o;else if(h)for(d=u[1]-v*o;d>u[0]&&isFinite(d)&&isFinite(u[0]);)v=su(v),d=u[1]-v*o;else{var m=r.getTicks().length-1;m>o&&(v=su(v));var p=v*o;g=Math.ceil(u[1]/v)*v,d=Bt(g-p),d<0&&u[0]>=0?(d=0,g=Bt(p)):g>0&&u[1]<=0&&(g=0,d=-Bt(p))}var y=(n[0].value-a[0].value)/s,_=(n[o].value-a[o].value)/s;i.setExtent.call(r,d+v*y,g+v*_),i.setInterval.call(r,v),(y||_)&&i.setNiceExtent.call(r,d+v,g-v)}var jd=[[3,1],[0,2]],oA=(function(){function r(t,e,i){this.type="grid",this._coordsMap={},this._coordsList=[],this._axesMap={},this._axesList=[],this.axisPointerEnabled=!0,this.dimensions=If,this._initCartesian(t,e,i),this.model=t}return r.prototype.getRect=function(){return this._rect},r.prototype.update=function(t,e){var i=this._axesMap;this._updateScale(t,this.model);function n(o){var s,l=St(o),u=l.length;if(u){for(var f=[],h=u-1;h>=0;h--){var c=+l[h],v=o[c],d=v.model,g=v.scale;Tf(g)&&d.get("alignTicks")&&d.get("interval")==null?f.push(v):(Hd(g,d),Tf(g)&&(s=v))}f.length&&(s||(s=f.pop(),Hd(s.scale,s.model)),T(f,function(m){aA(m.scale,m.model,s.scale)}))}}n(i.x),n(i.y);var a={};T(i.x,function(o){tp(i,"y",o,a)}),T(i.y,function(o){tp(i,"x",o,a)}),this.resize(this.model,e)},r.prototype.resize=function(t,e,i){var n=qs(t,e),a=this._rect=Ti(t.getBoxLayoutParams(),n.refContainer),o=this._axesMap,s=this._coordsList,l=t.get("containLabel");if(h0(o,a),!i){var u=lA(a,s,o,l,e),f=void 0;if(l)f=ip(a.clone(),"axisLabel",null,a,o,u,n);else{var h=uA(t,a,n),c=h.outerBoundsRect,v=h.parsedOuterBoundsContain,d=h.outerBoundsClamp;c&&(f=ip(c,v,d,a,o,u,n))}v0(a,o,be.determine,null,f,n)}T(this._coordsList,function(g){g.calcAffineTransform()})},r.prototype.getAxis=function(t,e){var i=this._axesMap[t];if(i!=null)return i[e||0]},r.prototype.getAxes=function(){return this._axesList.slice()},r.prototype.getCartesian=function(t,e){if(t!=null&&e!=null){var i="x"+t+"y"+e;return this._coordsMap[i]}Z(t)&&(e=t.yAxisIndex,t=t.xAxisIndex);for(var n=0,a=this._coordsList;n<a.length;n++)if(a[n].getAxis("x").index===t||a[n].getAxis("y").index===e)return a[n]},r.prototype.getCartesians=function(){return this._coordsList.slice()},r.prototype.convertToPixel=function(t,e,i){var n=this._findConvertTarget(e);return n.cartesian?n.cartesian.dataToPoint(i):n.axis?n.axis.toGlobalCoord(n.axis.dataToCoord(i)):null},r.prototype.convertFromPixel=function(t,e,i){var n=this._findConvertTarget(e);return n.cartesian?n.cartesian.pointToData(i):n.axis?n.axis.coordToData(n.axis.toLocalCoord(i)):null},r.prototype._findConvertTarget=function(t){var e=t.seriesModel,i=t.xAxisModel||e&&e.getReferringComponents("xAxis",Wt).models[0],n=t.yAxisModel||e&&e.getReferringComponents("yAxis",Wt).models[0],a=t.gridModel,o=this._coordsList,s,l;if(e)s=e.coordinateSystem,at(o,s)<0&&(s=null);else if(i&&n)s=this.getCartesian(i.componentIndex,n.componentIndex);else if(i)l=this.getAxis("x",i.componentIndex);else if(n)l=this.getAxis("y",n.componentIndex);else if(a){var u=a.coordinateSystem;u===this&&(s=this._coordsList[0])}return{cartesian:s,axis:l}},r.prototype.containPoint=function(t){var e=this._coordsList[0];if(e)return e.containPoint(t)},r.prototype._initCartesian=function(t,e,i){var n=this,a=this,o={left:!1,right:!1,top:!1,bottom:!1},s={x:{},y:{}},l={x:0,y:0};if(e.eachComponent("xAxis",u("x"),this),e.eachComponent("yAxis",u("y"),this),!l.x||!l.y){this._axesMap={},this._axesList=[];return}this._axesMap=s,T(s.x,function(f,h){T(s.y,function(c,v){var d="x"+h+"y"+v,g=new zD(d);g.master=n,g.model=t,n._coordsMap[d]=g,n._coordsList.push(g),g.addAxis(f),g.addAxis(c)})});function u(f){return function(h,c){if(fu(h,t)){var v=h.get("position");f==="x"?v!=="top"&&v!=="bottom"&&(v=o.bottom?"top":"bottom"):v!=="left"&&v!=="right"&&(v=o.left?"right":"left"),o[v]=!0;var d=new HD(f,oD(h),[0,0],h.get("type"),v),g=d.type==="category";d.onBand=g&&h.get("boundaryGap"),d.inverse=h.get("inverse"),h.axis=d,d.model=h,d.grid=a,d.index=c,a._axesList.push(d),s[f][c]=d,l[f]++}}}},r.prototype._updateScale=function(t,e){T(this._axesList,function(n){if(n.scale.setExtent(1/0,-1/0),n.type==="category"){var a=n.model.get("categorySortInfo");n.scale.setSortInfo(a)}}),t.eachSeries(function(n){if(rA(n)){var a=Jd(n),o=a.xAxisModel,s=a.yAxisModel;if(!fu(o,e)||!fu(s,e))return;var l=this.getCartesian(o.componentIndex,s.componentIndex),u=n.getData(),f=l.getAxis("x"),h=l.getAxis("y");i(u,f),i(u,h)}},this);function i(n,a){T(Yy(n,a.dim),function(o){a.scale.unionExtentFromData(n,o)})}},r.prototype.getTooltipAxes=function(t){var e=[],i=[];return T(this.getCartesians(),function(n){var a=t!=null&&t!=="auto"?n.getAxis(t):n.getBaseAxis(),o=n.getOtherAxis(a);at(e,a)<0&&e.push(a),at(i,o)<0&&i.push(o)}),{baseAxes:e,otherAxes:i}},r.create=function(t,e){var i=[];return t.eachComponent("grid",function(n,a){var o=new r(n,t,e);o.name="grid_"+a,o.resize(n,e,!0),n.coordinateSystem=o,i.push(o)}),t.eachSeries(function(n){ub({targetModel:n,coordSysType:"cartesian2d",coordSysProvider:a});function a(){var o=Jd(n),s=o.xAxisModel,l=o.yAxisModel,u=s.getCoordSysModel(),f=u.coordinateSystem;return f.getCartesian(s.componentIndex,l.componentIndex)}}),i},r.dimensions=If,r})();function fu(r,t){return r.getCoordSysModel()===t}function tp(r,t,e,i){e.getAxesOnZeroOf=function(){return a?[a]:[]};var n=r[t],a,o=e.model,s=o.get(["axisLine","onZero"]),l=o.get(["axisLine","onZeroAxisIndex"]);if(!s)return;if(l!=null)ep(n[l])&&(a=n[l]);else for(var u in n)if(n.hasOwnProperty(u)&&ep(n[u])&&!i[f(n[u])]){a=n[u];break}a&&(i[f(a)]=!0);function f(h){return h.dim+"_"+h.index}}function ep(r){return r&&r.type!=="category"&&r.type!=="time"&&sD(r)}function sA(r,t){var e=r.getExtent(),i=e[0]+e[1];r.toGlobalCoord=r.dim==="x"?function(n){return n+t}:function(n){return i-n+t},r.toLocalCoord=r.dim==="x"?function(n){return n-t}:function(n){return i-n+t}}function h0(r,t){T(r.x,function(e){return rp(e,t.x,t.width)}),T(r.y,function(e){return rp(e,t.y,t.height)})}function rp(r,t,e){var i=[0,e],n=r.inverse?1:0;r.setExtent(i[n],i[1-n]),sA(r,t)}function ip(r,t,e,i,n,a,o){v0(i,n,be.estimate,t,!1,o);var s=[0,0,0,0];u(0),u(1),f(i,0,NaN),f(i,1,NaN);var l=y_(s,function(c){return c>0})==null;return ls(i,s,!0,!0,e),h0(n,i),l;function u(c){T(n[li[c]],function(v){if(Ta(v.model)){var d=a.ensureRecord(v.model),g=d.labelInfoList;if(g)for(var m=0;m<g.length;m++){var p=g[m],y=v.scale.normalize(Ca(p.label).tickValue);y=c===1?1-y:y,f(p.rect,c,y),f(p.rect,1-c,NaN)}var _=d.nameLayout;if(_){var y=hn(d.nameLocation)?.5:NaN;f(_.rect,c,y),f(_.rect,1-c,NaN)}}})}function f(c,v,d){var g=r[li[v]]-c[li[v]],m=c[va[v]]+c[li[v]]-(r[va[v]]+r[li[v]]);g=h(g,1-d),m=h(m,d);var p=jd[v][0],y=jd[v][1];s[p]=ne(s[p],g),s[y]=ne(s[y],m)}function h(c,v){return c>0&&!sa(v)&&v>1e-4&&(c/=v),c}}function lA(r,t,e,i,n){var a=new a0(fA);return T(e,function(o){return T(o,function(s){if(Ta(s.model)){var l=!i;s.axisBuilder=iA(r,t,s.model,n,a,l)}})}),a}function v0(r,t,e,i,n,a){var o=e===be.determine;T(t,function(u){return T(u,function(f){Ta(f.model)&&(nA(f.axisBuilder,r,f.model),f.axisBuilder.build(o?{axisTickLabelDetermine:!0}:{axisTickLabelEstimate:!0},{noPxChange:n}))})});var s={x:0,y:0};l(0),l(1);function l(u){s[li[1-u]]=r[va[u]]<=a.refContainer[va[u]]*.5?0:1-u===1?2:1}T(t,function(u,f){return T(u,function(h){Ta(h.model)&&((i==="all"||o)&&h.axisBuilder.build({axisName:!0},{nameMarginLevel:s[f]}),o&&h.axisBuilder.build({axisLine:!0}))})})}function uA(r,t,e){var i,n=r.get("outerBoundsMode",!0);n==="same"?i=t.clone():(n==null||n==="auto")&&(i=Ti(r.get("outerBounds",!0)||r0,e.refContainer));var a=r.get("outerBoundsContain",!0),o;a==null||a==="auto"||at(["all","axisLabel"],a)<0?o="all":o=a;var s=[Xu($(r.get("outerBoundsClampWidth",!0),Ts[0]),t.width),Xu($(r.get("outerBoundsClampHeight",!0),Ts[1]),t.height)];return{outerBoundsRect:i,parsedOuterBoundsContain:o,outerBoundsClamp:s}}var fA=function(r,t,e,i,n,a){var o=e.axis.dim==="x"?"y":"x";o0(r,t,e,i,n,a),hn(r.nameLocation)||T(t.recordMap[o],function(s){s&&s.labelInfoList&&s.dirVec&&l0(s.labelInfoList,s.dirVec,i,n)})};function hA(r,t){var e={axesInfo:{},seriesInvolved:!1,coordSysAxesInfo:{},coordSysMap:{}};return vA(e,r,t),e.seriesInvolved&&dA(e,r),e}function vA(r,t,e){var i=t.getComponent("tooltip"),n=t.getComponent("axisPointer"),a=n.get("link",!0)||[],o=[];T(e.getCoordinateSystems(),function(s){if(!s.axisPointerEnabled)return;var l=Ma(s.model),u=r.coordSysAxesInfo[l]={};r.coordSysMap[l]=s;var f=s.model,h=f.getModel("tooltip",i);if(T(s.getAxes(),Mt(g,!1,null)),s.getTooltipAxes&&i&&h.get("show")){var c=h.get("trigger")==="axis",v=h.get(["axisPointer","type"])==="cross",d=s.getTooltipAxes(h.get(["axisPointer","axis"]));(c||v)&&T(d.baseAxes,Mt(g,v?"cross":!0,c)),v&&T(d.otherAxes,Mt(g,"cross",!1))}function g(m,p,y){var _=y.model.getModel("axisPointer",n),S=_.get("show");if(!(!S||S==="auto"&&!m&&!Rf(_))){p==null&&(p=_.get("triggerTooltip")),_=m?cA(y,h,n,t,m,p):_;var x=_.get("snap"),w=_.get("triggerEmphasis"),b=Ma(y.model),D=p||x||y.type==="category",C=r.axesInfo[b]={key:b,axis:y,coordSys:s,axisPointerModel:_,triggerTooltip:p,triggerEmphasis:w,involveSeries:D,snap:x,useHandle:Rf(_),seriesModels:[],linkGroup:null};u[b]=C,r.seriesInvolved=r.seriesInvolved||D;var M=pA(a,y);if(M!=null){var A=o[M]||(o[M]={axesInfo:{}});A.axesInfo[b]=C,A.mapper=a[M].mapper,C.linkGroup=A}}}})}function cA(r,t,e,i,n,a){var o=t.getModel("axisPointer"),s=["type","snap","lineStyle","shadowStyle","label","animation","animationDurationUpdate","animationEasingUpdate","z"],l={};T(s,function(c){l[c]=it(o.get(c))}),l.snap=r.type!=="category"&&!!a,o.get("type")==="cross"&&(l.type="line");var u=l.label||(l.label={});if(u.show==null&&(u.show=!1),n==="cross"){var f=o.get(["label","show"]);if(u.show=f??!0,!a){var h=l.lineStyle=o.get("crossStyle");h&&ht(u,h.textStyle)}}return r.model.getModel("axisPointer",new xt(l,e,i))}function dA(r,t){t.eachSeries(function(e){var i=e.coordinateSystem,n=e.get(["tooltip","trigger"],!0),a=e.get(["tooltip","show"],!0);!i||!i.model||n==="none"||n===!1||n==="item"||a===!1||e.get(["axisPointer","show"],!0)===!1||T(r.coordSysAxesInfo[Ma(i.model)],function(o){var s=o.axis;i.getAxis(s.dim)===s&&(o.seriesModels.push(e),o.seriesDataCount==null&&(o.seriesDataCount=0),o.seriesDataCount+=e.getData().count())})})}function pA(r,t){for(var e=t.model,i=t.dim,n=0;n<r.length;n++){var a=r[n]||{};if(hu(a[i+"AxisId"],e.id)||hu(a[i+"AxisIndex"],e.componentIndex)||hu(a[i+"AxisName"],e.name))return n}}function hu(r,t){return r==="all"||V(r)&&at(r,t)>=0||r===t}function gA(r){var t=Xh(r);if(t){var e=t.axisPointerModel,i=t.axis.scale,n=e.option,a=e.get("status"),o=e.get("value");o!=null&&(o=i.parse(o));var s=Rf(e);a==null&&(n.status=s?"show":"hide");var l=i.getExtent().slice();l[0]>l[1]&&l.reverse(),(o==null||o>l[1])&&(o=l[1]),o<l[0]&&(o=l[0]),n.value=o,s&&(n.status=t.axis.scale.isBlank()?"hide":"show")}}function Xh(r){var t=(r.ecModel.getComponent("axisPointer")||{}).coordSysAxesInfo;return t&&t.axesInfo[Ma(r)]}function mA(r){var t=Xh(r);return t&&t.axisPointerModel}function Rf(r){return!!r.get(["handle","show"])}function Ma(r){return r.type+"||"+r.id}var np={},c0=(function(r){B(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.render=function(e,i,n,a){this.axisPointerClass&&gA(e),r.prototype.render.apply(this,arguments),this._doUpdateAxisPointerClass(e,n,!0)},t.prototype.updateAxisPointer=function(e,i,n,a){this._doUpdateAxisPointerClass(e,n,!1)},t.prototype.remove=function(e,i){var n=this._axisPointer;n&&n.remove(i)},t.prototype.dispose=function(e,i){this._disposeAxisPointer(i),r.prototype.dispose.apply(this,arguments)},t.prototype._doUpdateAxisPointerClass=function(e,i,n){var a=t.getAxisPointerClass(this.axisPointerClass);if(a){var o=mA(e);o?(this._axisPointer||(this._axisPointer=new a)).render(e,o,i,n):this._disposeAxisPointer(i)}},t.prototype._disposeAxisPointer=function(e){this._axisPointer&&this._axisPointer.dispose(e),this._axisPointer=null},t.registerAxisPointerClass=function(e,i){np[e]=i},t.getAxisPointerClass=function(e){return e&&np[e]},t.type="axis",t})(me),Ef=yt();function yA(r,t,e,i){var n=e.axis;if(!n.scale.isBlank()){var a=e.getModel("splitArea"),o=a.getModel("areaStyle"),s=o.get("color"),l=i.coordinateSystem.getRect(),u=n.getTicksCoords({tickModel:a,clamp:!0,breakTicks:"none",pruneByBreak:"preserve_extent_bound"});if(u.length){var f=s.length,h=Ef(r).splitAreaColors,c=Q(),v=0;if(h)for(var d=0;d<u.length;d++){var g=h.get(u[d].tickValue);if(g!=null){v=(g+(f-1)*d)%f;break}}var m=n.toGlobalCoord(u[0].coord),p=o.getAreaStyle();s=V(s)?s:[s];for(var d=1;d<u.length;d++){var y=n.toGlobalCoord(u[d].coord),_=void 0,S=void 0,x=void 0,w=void 0;n.isHorizontal()?(_=m,S=l.y,x=y-_,w=l.height,m=_+x):(_=l.x,S=m,x=l.width,w=y-S,m=S+w);var b=u[d-1].tickValue;b!=null&&c.set(b,v),t.add(new wt({anid:b!=null?"area_"+b:null,shape:{x:_,y:S,width:x,height:w},style:ht({fill:s[v]},p),autoBatch:!0,silent:!0})),v=(v+1)%f}Ef(r).splitAreaColors=c}}}function _A(r){Ef(r).splitAreaColors=null}var SA=["splitArea","splitLine","minorSplitLine","breakArea"],d0=(function(r){B(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e.axisPointerClass="CartesianAxisPointer",e}return t.prototype.render=function(e,i,n,a){this.group.removeAll();var o=this._axisGroup;if(this._axisGroup=new Dt,this.group.add(this._axisGroup),!!Ta(e)){this._axisGroup.add(e.axis.axisBuilder.group),T(SA,function(l){e.get([l,"show"])&&wA[l](this,this._axisGroup,e,e.getCoordSysModel(),n)},this);var s=a&&a.type==="changeAxisOrder"&&a.isInitSort;s||sm(o,this._axisGroup,e),r.prototype.render.call(this,e,i,n,a)}},t.prototype.remove=function(){_A(this)},t.type="cartesianAxis",t})(c0),wA={splitLine:function(r,t,e,i,n){var a=e.axis;if(!a.scale.isBlank()){var o=e.getModel("splitLine"),s=o.getModel("lineStyle"),l=s.get("color"),u=o.get("showMinLine")!==!1,f=o.get("showMaxLine")!==!1;l=V(l)?l:[l];for(var h=i.coordinateSystem.getRect(),c=a.isHorizontal(),v=0,d=a.getTicksCoords({tickModel:o,breakTicks:"none",pruneByBreak:"preserve_extent_bound"}),g=[],m=[],p=s.getLineStyle(),y=0;y<d.length;y++){var _=a.toGlobalCoord(d[y].coord);if(!(y===0&&!u||y===d.length-1&&!f)){var S=d[y].tickValue;c?(g[0]=_,g[1]=h.y,m[0]=_,m[1]=h.y+h.height):(g[0]=h.x,g[1]=_,m[0]=h.x+h.width,m[1]=_);var x=v++%l.length,w=new Dr({anid:S!=null?"line_"+S:null,autoBatch:!0,shape:{x1:g[0],y1:g[1],x2:m[0],y2:m[1]},style:ht({stroke:l[x]},p),silent:!0});ca(w.shape,p.lineWidth),t.add(w)}}}},minorSplitLine:function(r,t,e,i,n){var a=e.axis,o=e.getModel("minorSplitLine"),s=o.getModel("lineStyle"),l=i.coordinateSystem.getRect(),u=a.isHorizontal(),f=a.getMinorTicksCoords();if(f.length)for(var h=[],c=[],v=s.getLineStyle(),d=0;d<f.length;d++)for(var g=0;g<f[d].length;g++){var m=a.toGlobalCoord(f[d][g].coord);u?(h[0]=m,h[1]=l.y,c[0]=m,c[1]=l.y+l.height):(h[0]=l.x,h[1]=m,c[0]=l.x+l.width,c[1]=m);var p=new Dr({anid:"minor_line_"+f[d][g].tickValue,autoBatch:!0,shape:{x1:h[0],y1:h[1],x2:c[0],y2:c[1]},style:v,silent:!0});ca(p.shape,v.lineWidth),t.add(p)}},splitArea:function(r,t,e,i,n){yA(r,t,e,i)},breakArea:function(r,t,e,i,n){e.axis.scale}},p0=(function(r){B(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.type="xAxis",t})(d0),xA=(function(r){B(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=p0.type,e}return t.type="yAxis",t})(d0),bA=(function(r){B(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type="grid",e}return t.prototype.render=function(e,i){this.group.removeAll(),e.get("show")&&this.group.add(new wt({shape:e.coordinateSystem.getRect(),style:ht({fill:e.get("backgroundColor")},e.getItemStyle()),silent:!0,z2:-1}))},t.type="grid",t})(me),ap={offset:0};function TA(r){r.registerComponentView(bA),r.registerComponentModel(ID),r.registerCoordinateSystem("cartesian2d",oA),Xd(r,"x",Lf,ap),Xd(r,"y",Lf,ap),r.registerComponentView(p0),r.registerComponentView(xA),r.registerPreprocessor(function(t){t.xAxis&&t.yAxis&&!t.grid&&(t.grid={})})}var ui=yt(),op=it,vu=q,CA=(function(){function r(){this._dragging=!1,this.animationThreshold=15}return r.prototype.render=function(t,e,i,n){var a=e.get("value"),o=e.get("status");if(this._axisModel=t,this._axisPointerModel=e,this._api=i,!(!n&&this._lastValue===a&&this._lastStatus===o)){this._lastValue=a,this._lastStatus=o;var s=this._group,l=this._handle;if(!o||o==="hide"){s&&s.hide(),l&&l.hide();return}s&&s.show(),l&&l.show();var u={};this.makeElOption(u,a,t,e,i);var f=u.graphicKey;f!==this._lastGraphicKey&&this.clear(i),this._lastGraphicKey=f;var h=this._moveAnimation=this.determineAnimation(t,e);if(!s)s=this._group=new Dt,this.createPointerEl(s,u,t,e),this.createLabelEl(s,u,t,e),i.getZr().add(s);else{var c=Mt(sp,e,h);this.updatePointerEl(s,u,c),this.updateLabelEl(s,u,c,e)}up(s,e,!0),this._renderHandle(a)}},r.prototype.remove=function(t){this.clear(t)},r.prototype.dispose=function(t){this.clear(t)},r.prototype.determineAnimation=function(t,e){var i=e.get("animation"),n=t.axis,a=n.type==="category",o=e.get("snap");if(!o&&!a)return!1;if(i==="auto"||i==null){var s=this.animationThreshold;if(a&&n.getBandWidth()>s)return!0;if(o){var l=Xh(t).seriesDataCount,u=n.getExtent();return Math.abs(u[0]-u[1])/l>s}return!1}return i===!0},r.prototype.makeElOption=function(t,e,i,n,a){},r.prototype.createPointerEl=function(t,e,i,n){var a=e.pointer;if(a){var o=ui(t).pointerEl=new Lx[a.type](op(e.pointer));t.add(o)}},r.prototype.createLabelEl=function(t,e,i,n){if(e.label){var a=ui(t).labelEl=new Nt(op(e.label));t.add(a),lp(a,n)}},r.prototype.updatePointerEl=function(t,e,i){var n=ui(t).pointerEl;n&&e.pointer&&(n.setStyle(e.pointer.style),i(n,{shape:e.pointer.shape}))},r.prototype.updateLabelEl=function(t,e,i,n){var a=ui(t).labelEl;a&&(a.setStyle(e.label.style),i(a,{x:e.label.x,y:e.label.y}),lp(a,n))},r.prototype._renderHandle=function(t){if(!(this._dragging||!this.updateHandleTransform)){var e=this._axisPointerModel,i=this._api.getZr(),n=this._handle,a=e.getModel("handle"),o=e.get("status");if(!a.get("show")||!o||o==="hide"){n&&i.remove(n),this._handle=null;return}var s;this._handle||(s=!0,n=this._handle=vh(a.get("icon"),{cursor:"move",draggable:!0,onmousemove:function(u){on(u.event)},onmousedown:vu(this._onHandleDragMove,this,0,0),drift:vu(this._onHandleDragMove,this),ondragend:vu(this._onHandleDragEnd,this)}),i.add(n)),up(n,e,!1),n.setStyle(a.getItemStyle(null,["color","borderColor","borderWidth","opacity","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"]));var l=a.get("size");V(l)||(l=[l,l]),n.scaleX=l[0]/2,n.scaleY=l[1]/2,Qs(this,"_doDispatchAxisPointer",a.get("throttle")||0,"fixRate"),this._moveHandleToValue(t,s)}},r.prototype._moveHandleToValue=function(t,e){sp(this._axisPointerModel,!e&&this._moveAnimation,this._handle,cu(this.getHandleTransform(t,this._axisModel,this._axisPointerModel)))},r.prototype._onHandleDragMove=function(t,e){var i=this._handle;if(i){this._dragging=!0;var n=this.updateHandleTransform(cu(i),[t,e],this._axisModel,this._axisPointerModel);this._payloadInfo=n,i.stopAnimation(),i.attr(cu(n)),ui(i).lastProp=null,this._doDispatchAxisPointer()}},r.prototype._doDispatchAxisPointer=function(){var t=this._handle;if(t){var e=this._payloadInfo,i=this._axisModel;this._api.dispatchAction({type:"updateAxisPointer",x:e.cursorPoint[0],y:e.cursorPoint[1],tooltipOption:e.tooltipOption,axesInfo:[{axisDim:i.axis.dim,axisIndex:i.componentIndex}]})}},r.prototype._onHandleDragEnd=function(){this._dragging=!1;var t=this._handle;if(t){var e=this._axisPointerModel.get("value");this._moveHandleToValue(e),this._api.dispatchAction({type:"hideTip"})}},r.prototype.clear=function(t){this._lastValue=null,this._lastStatus=null;var e=t.getZr(),i=this._group,n=this._handle;e&&i&&(this._lastGraphicKey=null,i&&e.remove(i),n&&e.remove(n),this._group=null,this._handle=null,this._payloadInfo=null),cs(this,"_doDispatchAxisPointer")},r.prototype.doClear=function(){},r.prototype.buildLabel=function(t,e,i){return i=i||0,{x:t[i],y:t[1-i],width:e[i],height:e[1-i]}},r})();function sp(r,t,e,i){g0(ui(e).lastProp,i)||(ui(e).lastProp=i,t?Ar(e,i,r):(e.stopAnimation(),e.attr(i)))}function g0(r,t){if(Z(r)&&Z(t)){var e=!0;return T(t,function(i,n){e=e&&g0(r[n],i)}),!!e}else return r===t}function lp(r,t){r[t.get(["label","show"])?"show":"hide"]()}function cu(r){return{x:r.x||0,y:r.y||0,rotation:r.rotation||0}}function up(r,t,e){var i=t.get("z"),n=t.get("zlevel");r&&r.traverse(function(a){a.type!=="group"&&(i!=null&&(a.z=i),n!=null&&(a.zlevel=n),a.silent=e)})}function MA(r){var t=r.get("type"),e=r.getModel(t+"Style"),i;return t==="line"?(i=e.getLineStyle(),i.fill=null):t==="shadow"&&(i=e.getAreaStyle(),i.stroke=null),i}function DA(r,t,e,i,n){var a=e.get("value"),o=m0(a,t.axis,t.ecModel,e.get("seriesDataIndices"),{precision:e.get(["label","precision"]),formatter:e.get(["label","formatter"])}),s=e.getModel("label"),l=Xs(s.get("padding")||0),u=s.getFont(),f=cg(o,u),h=n.position,c=f.width+l[1]+l[3],v=f.height+l[0]+l[2],d=n.align;d==="right"&&(h[0]-=c),d==="center"&&(h[0]-=c/2);var g=n.verticalAlign;g==="bottom"&&(h[1]-=v),g==="middle"&&(h[1]-=v/2),AA(h,c,v,i);var m=s.get("backgroundColor");(!m||m==="auto")&&(m=t.get(["axisLine","lineStyle","color"])),r.label={x:h[0],y:h[1],style:ar(s,{text:o,font:u,fill:s.getTextColor(),padding:l,backgroundColor:m}),z2:10}}function AA(r,t,e,i){var n=i.getWidth(),a=i.getHeight();r[0]=Math.min(r[0]+t,n)-t,r[1]=Math.min(r[1]+e,a)-e,r[0]=Math.max(r[0],0),r[1]=Math.max(r[1],0)}function m0(r,t,e,i,n){r=t.scale.parse(r);var a=t.scale.getLabel({value:r},{precision:n.precision}),o=n.formatter;if(o){var s={value:Ss(t,{value:r}),axisDimension:t.dim,axisIndex:t.index,seriesData:[]};T(i,function(l){var u=e.getSeriesByIndex(l.seriesIndex),f=l.dataIndexInside,h=u&&u.getDataParams(f);h&&s.seriesData.push(h)}),W(o)?a=o.replace("{value}",a):J(o)&&(a=o(s))}return a}function y0(r,t,e){var i=rr();return qf(i,i,e.rotation),Pu(i,i,e.position),da([r.dataToCoord(t),(e.labelOffset||0)+(e.labelDirection||1)*(e.labelMargin||0)],i)}function LA(r,t,e,i,n,a){var o=Cr.innerTextLayout(e.rotation,0,e.labelDirection);e.labelMargin=n.get(["label","margin"]),DA(t,i,n,a,{position:y0(i.axis,r,e),align:o.textAlign,verticalAlign:o.textVerticalAlign})}function IA(r,t,e){return e=e||0,{x1:r[e],y1:r[1-e],x2:t[e],y2:t[1-e]}}function PA(r,t,e){return e=e||0,{x:r[e],y:r[1-e],width:t[e],height:t[1-e]}}var RA=(function(r){B(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t.prototype.makeElOption=function(e,i,n,a,o){var s=n.axis,l=s.grid,u=a.get("type"),f=fp(l,s).getOtherAxis(s).getGlobalExtent(),h=s.toGlobalCoord(s.dataToCoord(i,!0));if(u&&u!=="none"){var c=MA(a),v=EA[u](s,h,f);v.style=c,e.graphicKey=v.type,e.pointer=v}var d=Cs(l.getRect(),n);LA(i,e,d,n,a,o)},t.prototype.getHandleTransform=function(e,i,n){var a=Cs(i.axis.grid.getRect(),i,{labelInside:!1});a.labelMargin=n.get(["handle","margin"]);var o=y0(i.axis,e,a);return{x:o[0],y:o[1],rotation:a.rotation+(a.labelDirection<0?Math.PI:0)}},t.prototype.updateHandleTransform=function(e,i,n,a){var o=n.axis,s=o.grid,l=o.getGlobalExtent(!0),u=fp(s,o).getOtherAxis(o).getGlobalExtent(),f=o.dim==="x"?0:1,h=[e.x,e.y];h[f]+=i[f],h[f]=Math.min(l[1],h[f]),h[f]=Math.max(l[0],h[f]);var c=(u[1]+u[0])/2,v=[c,c];v[f]=h[f];var d=[{verticalAlign:"middle"},{align:"center"}];return{x:h[0],y:h[1],rotation:e.rotation,cursorPoint:v,tooltipOption:d[f]}},t})(CA);function fp(r,t){var e={};return e[t.dim+"AxisIndex"]=t.index,r.getCartesian(e)}var EA={line:function(r,t,e){var i=IA([t,e[0]],[t,e[1]],hp(r));return{type:"Line",subPixelOptimize:!0,shape:i}},shadow:function(r,t,e){var i=Math.max(1,r.getBandWidth()),n=e[1]-e[0];return{type:"Rect",shape:PA([t-i/2,e[0]],[i,n],hp(r))}}};function hp(r){return r.dim==="x"?0:1}var kA=(function(r){B(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.type="axisPointer",t.defaultOption={show:"auto",z:50,type:"line",snap:!1,triggerTooltip:!0,triggerEmphasis:!0,value:null,status:null,link:[],animation:null,animationDurationUpdate:200,lineStyle:{color:H.color.border,width:1,type:"dashed"},shadowStyle:{color:H.color.shadowTint},label:{show:!0,formatter:null,precision:"auto",margin:3,color:H.color.neutral00,padding:[5,7,5,7],backgroundColor:H.color.accent60,borderColor:null,borderWidth:0,borderRadius:3},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:H.color.accent40,throttle:40}},t})(ut),er=yt(),OA=T;function _0(r,t,e){if(!j.node){var i=t.getZr();er(i).records||(er(i).records={}),BA(i,t);var n=er(i).records[r]||(er(i).records[r]={});n.handler=e}}function BA(r,t){if(er(r).initialized)return;er(r).initialized=!0,e("click",Mt(vp,"click")),e("mousemove",Mt(vp,"mousemove")),e("globalout",FA);function e(i,n){r.on(i,function(a){var o=zA(t);OA(er(r).records,function(s){s&&n(s,a,o.dispatchAction)}),NA(o.pendings,t)})}}function NA(r,t){var e=r.showTip.length,i=r.hideTip.length,n;e?n=r.showTip[e-1]:i&&(n=r.hideTip[i-1]),n&&(n.dispatchAction=null,t.dispatchAction(n))}function FA(r,t,e){r.handler("leave",null,e)}function vp(r,t,e,i){t.handler(r,e,i)}function zA(r){var t={showTip:[],hideTip:[]},e=function(i){var n=t[i.type];n?n.push(i):(i.dispatchAction=e,r.dispatchAction(i))};return{dispatchAction:e,pendings:t}}function kf(r,t){if(!j.node){var e=t.getZr(),i=(er(e).records||{})[r];i&&(er(e).records[r]=null)}}var HA=(function(r){B(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.render=function(e,i,n){var a=i.getComponent("tooltip"),o=e.get("triggerOn")||a&&a.get("triggerOn")||"mousemove|click";_0("axisPointer",n,function(s,l,u){o!=="none"&&(s==="leave"||o.indexOf(s)>=0)&&u({type:"updateAxisPointer",currTrigger:s,x:l&&l.offsetX,y:l&&l.offsetY})})},t.prototype.remove=function(e,i){kf("axisPointer",i)},t.prototype.dispose=function(e,i){kf("axisPointer",i)},t.type="axisPointer",t})(me);function S0(r,t){var e=[],i=r.seriesIndex,n;if(i==null||!(n=t.getSeriesByIndex(i)))return{point:[]};var a=n.getData(),o=wi(a,r);if(o==null||o<0||V(o))return{point:[]};var s=a.getItemGraphicEl(o),l=n.coordinateSystem;if(n.getTooltipPosition)e=n.getTooltipPosition(o)||[];else if(l&&l.dataToPoint)if(r.isStacked){var u=l.getBaseAxis(),f=l.getOtherAxis(u),h=f.dim,c=u.dim,v=h==="x"||h==="radius"?1:0,d=a.mapDimension(c),g=[];g[v]=a.get(d,o),g[1-v]=a.get(a.getCalculationInfo("stackResultDimension"),o),e=l.dataToPoint(g)||[]}else e=l.dataToPoint(a.getValues(K(l.dimensions,function(p){return a.mapDimension(p)}),o))||[];else if(s){var m=s.getBoundingRect().clone();m.applyTransform(s.transform),e=[m.x+m.width/2,m.y+m.height/2]}return{point:e,el:s}}var cp=yt();function GA(r,t,e){var i=r.currTrigger,n=[r.x,r.y],a=r,o=r.dispatchAction||q(e.dispatchAction,e),s=t.getComponent("axisPointer").coordSysAxesInfo;if(s){Vo(n)&&(n=S0({seriesIndex:a.seriesIndex,dataIndex:a.dataIndex},t).point);var l=Vo(n),u=a.axesInfo,f=s.axesInfo,h=i==="leave"||Vo(n),c={},v={},d={list:[],map:{}},g={showPointer:Mt(WA,v),showTooltip:Mt(UA,d)};T(s.coordSysMap,function(p,y){var _=l||p.containPoint(n);T(s.coordSysAxesInfo[y],function(S,x){var w=S.axis,b=qA(u,S);if(!h&&_&&(!u||b)){var D=b&&b.value;D==null&&!l&&(D=w.pointToData(n)),D!=null&&dp(S,D,g,!1,c)}})});var m={};return T(f,function(p,y){var _=p.linkGroup;_&&!v[y]&&T(_.axesInfo,function(S,x){var w=v[x];if(S!==p&&w){var b=w.value;_.mapper&&(b=p.axis.scale.parse(_.mapper(b,pp(S),pp(p)))),m[p.key]=b}})}),T(m,function(p,y){dp(f[y],p,g,!0,c)}),YA(v,f,c),ZA(d,n,r,o),XA(f,o,e),c}}function dp(r,t,e,i,n){var a=r.axis;if(!(a.scale.isBlank()||!a.containData(t))){if(!r.involveSeries){e.showPointer(r,t);return}var o=VA(t,r),s=o.payloadBatch,l=o.snapToValue;s[0]&&n.seriesIndex==null&&O(n,s[0]),!i&&r.snap&&a.containData(l)&&l!=null&&(t=l),e.showPointer(r,t,s),e.showTooltip(r,o,l)}}function VA(r,t){var e=t.axis,i=e.dim,n=r,a=[],o=Number.MAX_VALUE,s=-1;return T(t.seriesModels,function(l,u){var f=l.getData().mapDimensionsAll(i),h,c;if(l.getAxisTooltipData){var v=l.getAxisTooltipData(f,r,e);c=v.dataIndices,h=v.nestestValue}else{if(c=l.indicesOfNearest(i,f[0],r,e.type==="category"?.5:null),!c.length)return;h=l.getData().get(f[0],c[0])}if(!(h==null||!isFinite(h))){var d=r-h,g=Math.abs(d);g<=o&&((g<o||d>=0&&s<0)&&(o=g,s=d,n=h,a.length=0),T(c,function(m){a.push({seriesIndex:l.seriesIndex,dataIndexInside:m,dataIndex:l.getData().getRawIndex(m)})}))}}),{payloadBatch:a,snapToValue:n}}function WA(r,t,e,i){r[t.key]={value:e,payloadBatch:i}}function UA(r,t,e,i){var n=e.payloadBatch,a=t.axis,o=a.model,s=t.axisPointerModel;if(!(!t.triggerTooltip||!n.length)){var l=t.coordSys.model,u=Ma(l),f=r.map[u];f||(f=r.map[u]={coordSysId:l.id,coordSysIndex:l.componentIndex,coordSysType:l.type,coordSysMainType:l.mainType,dataByAxis:[]},r.list.push(f)),f.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:n.slice()})}}function YA(r,t,e){var i=e.axesInfo=[];T(t,function(n,a){var o=n.axisPointerModel.option,s=r[a];s?(!n.useHandle&&(o.status="show"),o.value=s.value,o.seriesDataIndices=(s.payloadBatch||[]).slice()):!n.useHandle&&(o.status="hide"),o.status==="show"&&i.push({axisDim:n.axis.dim,axisIndex:n.axis.model.componentIndex,value:o.value})})}function ZA(r,t,e,i){if(Vo(t)||!r.list.length){i({type:"hideTip"});return}var n=((r.list[0].dataByAxis[0]||{}).seriesDataIndices||[])[0]||{};i({type:"showTip",escapeConnect:!0,x:t[0],y:t[1],tooltipOption:e.tooltipOption,position:e.position,dataIndexInside:n.dataIndexInside,dataIndex:n.dataIndex,seriesIndex:n.seriesIndex,dataByCoordSys:r.list})}function XA(r,t,e){var i=e.getZr(),n="axisPointerLastHighlights",a=cp(i)[n]||{},o=cp(i)[n]={};T(r,function(u,f){var h=u.axisPointerModel.option;h.status==="show"&&u.triggerEmphasis&&T(h.seriesDataIndices,function(c){var v=c.seriesIndex+" | "+c.dataIndex;o[v]=c})});var s=[],l=[];T(a,function(u,f){!o[f]&&l.push(u)}),T(o,function(u,f){!a[f]&&s.push(u)}),l.length&&e.dispatchAction({type:"downplay",escapeConnect:!0,notBlur:!0,batch:l}),s.length&&e.dispatchAction({type:"highlight",escapeConnect:!0,notBlur:!0,batch:s})}function qA(r,t){for(var e=0;e<(r||[]).length;e++){var i=r[e];if(t.axis.dim===i.axisDim&&t.axis.model.componentIndex===i.axisIndex)return i}}function pp(r){var t=r.axis.model,e={},i=e.axisDim=r.axis.dim;return e.axisIndex=e[i+"AxisIndex"]=t.componentIndex,e.axisName=e[i+"AxisName"]=t.name,e.axisId=e[i+"AxisId"]=t.id,e}function Vo(r){return!r||r[0]==null||isNaN(r[0])||r[1]==null||isNaN(r[1])}function w0(r){c0.registerAxisPointerClass("CartesianAxisPointer",RA),r.registerComponentModel(kA),r.registerComponentView(HA),r.registerPreprocessor(function(t){if(t){(!t.axisPointer||t.axisPointer.length===0)&&(t.axisPointer={});var e=t.axisPointer.link;e&&!V(e)&&(t.axisPointer.link=[e])}}),r.registerProcessor(r.PRIORITY.PROCESSOR.STATISTIC,function(t,e){t.getComponent("axisPointer").coordSysAxesInfo=hA(t,e)}),r.registerAction({type:"updateAxisPointer",event:"updateAxisPointer",update:":updateAxisPointer"},GA)}function $A(r){Ue(TA),Ue(w0)}var KA=yt();function gp(r,t){return!!KA(r)[t]}Mi({type:"takeGlobalCursor",event:"globalCursorTaken",update:"update"},Ut);var QA={axisPointer:1,tooltip:1,brush:1};function JA(r,t,e){var i=t.getComponentByElement(r.topTarget);if(!i||i===e||QA.hasOwnProperty(i.mainType))return!1;var n=i.coordinateSystem;if(!n||n.model===e)return!1;var a=ga(i),o=ga(e);return!((a.zlevel-o.zlevel||a.z-o.z)<=0)}var jA=(function(r){B(t,r);function t(e){var i=r.call(this)||this;i._zr=e;var n=q(i._mousedownHandler,i),a=q(i._mousemoveHandler,i),o=q(i._mouseupHandler,i),s=q(i._mousewheelHandler,i),l=q(i._pinchHandler,i);return i.enable=function(u,f){var h=f.zInfo,c=ga(h.component),v=c.z,d=c.zlevel,g={component:h.component,z:v,zlevel:d,z2:$(h.z2,-1/0)},m=O({},f.triggerInfo);this._opt=ht(O({},f),{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0,zInfoParsed:g,triggerInfo:m}),u==null&&(u=!0),(!this._enabled||this._controlType!==u)&&(this._enabled=!0,this.disable(),(u===!0||u==="move"||u==="pan")&&(En(e,"mousedown",n,g),En(e,"mousemove",a,g),En(e,"mouseup",o,g)),(u===!0||u==="scale"||u==="zoom")&&(En(e,"mousewheel",s,g),En(e,"pinch",l,g)))},i.disable=function(){this._enabled=!1,kn(e,"mousedown",n),kn(e,"mousemove",a),kn(e,"mouseup",o),kn(e,"mousewheel",s),kn(e,"pinch",l)},i}return t.prototype.isDragging=function(){return this._dragging},t.prototype.isPinching=function(){return this._pinching},t.prototype._checkPointer=function(e,i,n){var a=this._opt,o=a.zInfoParsed;if(JA(e,a.api,o.component))return!1;var s=a.triggerInfo,l=s.roamTrigger,u=!1;return l==="global"&&(u=!0),u||(u=s.isInSelf(e,i,n)),u&&s.isInClip&&!s.isInClip(e,i,n)&&(u=!1),u},t.prototype._decideCursorStyle=function(e,i,n,a){var o=e.target;if(!o&&this._checkPointer(e,i,n))return"grab";if(a)return o&&o.cursor||"default"},t.prototype.dispose=function(){this.disable()},t.prototype._mousedownHandler=function(e){if(!(nv(e)||Rn(e))){for(var i=e.target;i;){if(i.draggable)return;i=i.__hostTarget||i.parent}var n=e.offsetX,a=e.offsetY;this._checkPointer(e,n,a)&&(this._x=n,this._y=a,this._dragging=!0)}},t.prototype._mousemoveHandler=function(e){var i=this._zr;if(!(e.gestureEvent==="pinch"||gp(i,"globalPan")||Rn(e))){var n=e.offsetX,a=e.offsetY;if(!this._dragging||!Wo("moveOnMouseMove",e,this._opt)){var o=this._decideCursorStyle(e,n,a,!1);o&&i.setCursorStyle(o);return}i.setCursorStyle("grabbing");var s=this._x,l=this._y,u=n-s,f=a-l;this._x=n,this._y=a,this._opt.preventDefaultMouseMove&&on(e.event),e.__ecRoamConsumed=!0,mp(this,"pan","moveOnMouseMove",e,{dx:u,dy:f,oldX:s,oldY:l,newX:n,newY:a,isAvailableBehavior:null})}},t.prototype._mouseupHandler=function(e){if(!Rn(e)){var i=this._zr;if(!nv(e)){this._dragging=!1;var n=this._decideCursorStyle(e,e.offsetX,e.offsetY,!0);n&&i.setCursorStyle(n)}}},t.prototype._mousewheelHandler=function(e){if(!Rn(e)){var i=Wo("zoomOnMouseWheel",e,this._opt),n=Wo("moveOnMouseWheel",e,this._opt),a=e.wheelDelta,o=Math.abs(a),s=e.offsetX,l=e.offsetY;if(!(a===0||!i&&!n)){if(i){var u=o>3?1.4:o>1?1.2:1.1,f=a>0?u:1/u;this._checkTriggerMoveZoom(this,"zoom","zoomOnMouseWheel",e,{scale:f,originX:s,originY:l,isAvailableBehavior:null})}if(n){var h=Math.abs(a),c=(a>0?1:-1)*(h>3?.4:h>1?.15:.05);this._checkTriggerMoveZoom(this,"scrollMove","moveOnMouseWheel",e,{scrollDelta:c,originX:s,originY:l,isAvailableBehavior:null})}}}},t.prototype._pinchHandler=function(e){if(!(gp(this._zr,"globalPan")||Rn(e))){var i=e.pinchScale>1?1.1:1/1.1;this._checkTriggerMoveZoom(this,"zoom",null,e,{scale:i,originX:e.pinchX,originY:e.pinchY,isAvailableBehavior:null})}},t.prototype._checkTriggerMoveZoom=function(e,i,n,a,o){e._checkPointer(a,o.originX,o.originY)&&(on(a.event),a.__ecRoamConsumed=!0,mp(e,i,n,a,o))},t})(Te);function Rn(r){return r.__ecRoamConsumed}var t2=yt();function js(r){var t=t2(r);return t.roam=t.roam||{},t.uniform=t.uniform||{},t}function En(r,t,e,i){for(var n=js(r),a=n.roam,o=a[t]=a[t]||[],s=0;s<o.length;s++){var l=o[s].zInfoParsed;if((l.zlevel-i.zlevel||l.z-i.z||l.z2-i.z2)<=0)break}o.splice(s,0,{listener:e,zInfoParsed:i}),e2(r,t)}function kn(r,t,e){for(var i=js(r),n=i.roam[t]||[],a=0;a<n.length;a++)if(n[a].listener===e){n.splice(a,1),n.length||r2(r,t);return}}function e2(r,t){var e=js(r);e.uniform[t]||r.on(t,e.uniform[t]=function(i){var n=e.roam[t];if(n)for(var a=0;a<n.length;a++)n[a].listener(i)})}function r2(r,t){var e=js(r),i=e.uniform;i[t]&&(r.off(t,i[t]),i[t]=null)}function mp(r,t,e,i,n){n.isAvailableBehavior=q(Wo,null,e,i),r.trigger(t,n)}function Wo(r,t,e){var i=e[r];return!r||i&&(!W(i)||t.event[i+"Key"])}function Da(r,t,e,i,n,a){r=r||0;var o=e[1]-e[0];if(n!=null&&(n=Ui(n,[0,o])),a!=null&&(a=Math.max(a,n??0)),i==="all"){var s=Math.abs(t[1]-t[0]);s=Ui(s,[0,o]),n=a=Ui(s,[n,a]),i=0}t[0]=Ui(t[0],e),t[1]=Ui(t[1],e);var l=du(t,i);t[i]+=r;var u=n||0,f=e.slice();l.sign<0?f[0]+=u:f[1]-=u,t[i]=Ui(t[i],f);var h;return h=du(t,i),n!=null&&(h.sign!==l.sign||h.span<n)&&(t[1-i]=t[i]+l.sign*n),h=du(t,i),a!=null&&h.span>a&&(t[1-i]=t[i]+h.sign*a),t}function du(r,t){var e=r[t]-r[1-t];return{span:Math.abs(e),sign:e>0?-1:e<0?1:t?-1:1}}function Ui(r,t){return Math.min(t[1]!=null?t[1]:1/0,Math.max(t[0]!=null?t[0]:-1/0,r))}var yp=["x","y","radius","angle","single"],i2=["cartesian2d","polar","singleAxis"];function n2(r){var t=r.get("coordinateSystem");return at(i2,t)>=0}function wr(r){return r+"Axis"}function a2(r,t){var e=Q(),i=[],n=Q();r.eachComponent({mainType:"dataZoom",query:t},function(f){n.get(f.uid)||s(f)});var a;do a=!1,r.eachComponent("dataZoom",o);while(a);function o(f){!n.get(f.uid)&&l(f)&&(s(f),a=!0)}function s(f){n.set(f.uid,!0),i.push(f),u(f)}function l(f){var h=!1;return f.eachTargetAxis(function(c,v){var d=e.get(c);d&&d[v]&&(h=!0)}),h}function u(f){f.eachTargetAxis(function(h,c){(e.get(h)||e.set(h,[]))[c]=!0})}return i}function x0(r){var t=r.ecModel,e={infoList:[],infoMap:Q()};return r.eachTargetAxis(function(i,n){var a=t.getComponent(wr(i),n);if(a){var o=a.getCoordSysModel();if(o){var s=o.uid,l=e.infoMap.get(s);l||(l={model:o,axisModels:[]},e.infoList.push(l),e.infoMap.set(s,l)),l.axisModels.push(a)}}}),e}var pu=(function(){function r(){this.indexList=[],this.indexMap=[]}return r.prototype.add=function(t){this.indexMap[t]||(this.indexList.push(t),this.indexMap[t]=!0)},r})(),Ms=(function(r){B(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e._autoThrottle=!0,e._noTarget=!0,e._rangePropMode=["percent","percent"],e}return t.prototype.init=function(e,i,n){var a=_p(e);this.settledOption=a,this.mergeDefaultAndTheme(e,n),this._doInit(a)},t.prototype.mergeOption=function(e){var i=_p(e);st(this.option,e,!0),st(this.settledOption,i,!0),this._doInit(i)},t.prototype._doInit=function(e){var i=this.option;this._setDefaultThrottle(e),this._updateRangeUse(e);var n=this.settledOption;T([["start","startValue"],["end","endValue"]],function(a,o){this._rangePropMode[o]==="value"&&(i[a[0]]=n[a[0]]=null)},this),this._resetTarget()},t.prototype._resetTarget=function(){var e=this.get("orient",!0),i=this._targetAxisInfoMap=Q(),n=this._fillSpecifiedTargetAxis(i);n?this._orient=e||this._makeAutoOrientByTargetAxis():(this._orient=e||"horizontal",this._fillAutoTargetAxisByOrient(i,this._orient)),this._noTarget=!0,i.each(function(a){a.indexList.length&&(this._noTarget=!1)},this)},t.prototype._fillSpecifiedTargetAxis=function(e){var i=!1;return T(yp,function(n){var a=this.getReferringComponents(wr(n),vS);if(a.specified){i=!0;var o=new pu;T(a.models,function(s){o.add(s.componentIndex)}),e.set(n,o)}},this),i},t.prototype._fillAutoTargetAxisByOrient=function(e,i){var n=this.ecModel,a=!0;if(a){var o=i==="vertical"?"y":"x",s=n.findComponents({mainType:o+"Axis"});l(s,o)}if(a){var s=n.findComponents({mainType:"singleAxis",filter:function(f){return f.get("orient",!0)===i}});l(s,"single")}function l(u,f){var h=u[0];if(h){var c=new pu;if(c.add(h.componentIndex),e.set(f,c),a=!1,f==="x"||f==="y"){var v=h.getReferringComponents("grid",Wt).models[0];v&&T(u,function(d){h.componentIndex!==d.componentIndex&&v===d.getReferringComponents("grid",Wt).models[0]&&c.add(d.componentIndex)})}}}a&&T(yp,function(u){if(a){var f=n.findComponents({mainType:wr(u),filter:function(c){return c.get("type",!0)==="category"}});if(f[0]){var h=new pu;h.add(f[0].componentIndex),e.set(u,h),a=!1}}},this)},t.prototype._makeAutoOrientByTargetAxis=function(){var e;return this.eachTargetAxis(function(i){!e&&(e=i)},this),e==="y"?"vertical":"horizontal"},t.prototype._setDefaultThrottle=function(e){if(e.hasOwnProperty("throttle")&&(this._autoThrottle=!1),this._autoThrottle){var i=this.ecModel.option;this.option.throttle=i.animation&&i.animationDurationUpdate>0?100:20}},t.prototype._updateRangeUse=function(e){var i=this._rangePropMode,n=this.get("rangeMode");T([["start","startValue"],["end","endValue"]],function(a,o){var s=e[a[0]]!=null,l=e[a[1]]!=null;s&&!l?i[o]="percent":!s&&l?i[o]="value":n?i[o]=n[o]:s&&(i[o]="percent")})},t.prototype.noTarget=function(){return this._noTarget},t.prototype.getFirstTargetAxisModel=function(){var e;return this.eachTargetAxis(function(i,n){e==null&&(e=this.ecModel.getComponent(wr(i),n))},this),e},t.prototype.eachTargetAxis=function(e,i){this._targetAxisInfoMap.each(function(n,a){T(n.indexList,function(o){e.call(i,a,o)})})},t.prototype.getAxisProxy=function(e,i){var n=this.getAxisModel(e,i);if(n)return n.__dzAxisProxy},t.prototype.getAxisModel=function(e,i){var n=this._targetAxisInfoMap.get(e);if(n&&n.indexMap[i])return this.ecModel.getComponent(wr(e),i)},t.prototype.setRawRange=function(e){var i=this.option,n=this.settledOption;T([["start","startValue"],["end","endValue"]],function(a){(e[a[0]]!=null||e[a[1]]!=null)&&(i[a[0]]=n[a[0]]=e[a[0]],i[a[1]]=n[a[1]]=e[a[1]])},this),this._updateRangeUse(e)},t.prototype.setCalculatedRange=function(e){var i=this.option;T(["start","startValue","end","endValue"],function(n){i[n]=e[n]})},t.prototype.getPercentRange=function(){var e=this.findRepresentativeAxisProxy();if(e)return e.getDataPercentWindow()},t.prototype.getValueRange=function(e,i){if(e==null&&i==null){var n=this.findRepresentativeAxisProxy();if(n)return n.getDataValueWindow()}else return this.getAxisProxy(e,i).getDataValueWindow()},t.prototype.findRepresentativeAxisProxy=function(e){if(e)return e.__dzAxisProxy;for(var i,n=this._targetAxisInfoMap.keys(),a=0;a<n.length;a++)for(var o=n[a],s=this._targetAxisInfoMap.get(o),l=0;l<s.indexList.length;l++){var u=this.getAxisProxy(o,s.indexList[l]);if(u.hostedBy(this))return u;i||(i=u)}return i},t.prototype.getRangePropMode=function(){return this._rangePropMode.slice()},t.prototype.getOrient=function(){return this._orient},t.type="dataZoom",t.dependencies=["xAxis","yAxis","radiusAxis","angleAxis","singleAxis","series","toolbox"],t.defaultOption={z:4,filterMode:"filter",start:0,end:100},t})(ut);function _p(r){var t={};return T(["start","end","startValue","endValue","throttle"],function(e){r.hasOwnProperty(e)&&(t[e]=r[e])}),t}var b0=(function(r){B(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.render=function(e,i,n,a){this.dataZoomModel=e,this.ecModel=i,this.api=n},t.type="dataZoom",t})(me),Xi=T,Sp=Vn,o2=(function(){function r(t,e,i,n){this._dimName=t,this._axisIndex=e,this.ecModel=n,this._dataZoomModel=i}return r.prototype.hostedBy=function(t){return this._dataZoomModel===t},r.prototype.getDataValueWindow=function(){return this._valueWindow.slice()},r.prototype.getDataPercentWindow=function(){return this._percentWindow.slice()},r.prototype.getTargetSeriesModels=function(){var t=[];return this.ecModel.eachSeries(function(e){if(n2(e)){var i=wr(this._dimName),n=e.getReferringComponents(i,Wt).models[0];n&&this._axisIndex===n.componentIndex&&t.push(e)}},this),t},r.prototype.getAxisModel=function(){return this.ecModel.getComponent(this._dimName+"Axis",this._axisIndex)},r.prototype.getMinMaxSpan=function(){return it(this._minMaxSpan)},r.prototype.calculateDataWindow=function(t){var e=this._dataExtent,i=this.getAxisModel(),n=i.axis.scale,a=this._dataZoomModel.getRangePropMode(),o=[0,100],s=[],l=[],u;Xi(["start","end"],function(c,v){var d=t[c],g=t[c+"Value"];a[v]==="percent"?(d==null&&(d=o[v]),g=n.parse(Pt(d,o,e))):(u=!0,g=g==null?e[v]:n.parse(g),d=Pt(g,e,o)),l[v]=g==null||isNaN(g)?e[v]:g,s[v]=d==null||isNaN(d)?o[v]:d}),Sp(l),Sp(s);var f=this._minMaxSpan;u?h(l,s,e,o,!1):h(s,l,o,e,!0);function h(c,v,d,g,m){var p=m?"Span":"ValueSpan";Da(0,c,d,"all",f["min"+p],f["max"+p]);for(var y=0;y<2;y++)v[y]=Pt(c[y],d,g,!0),m&&(v[y]=n.parse(v[y]))}return{valueWindow:l,percentWindow:s}},r.prototype.reset=function(t){if(t===this._dataZoomModel){var e=this.getTargetSeriesModels();this._dataExtent=s2(this,this._dimName,e),this._updateMinMaxSpan();var i=this.calculateDataWindow(t.settledOption);this._valueWindow=i.valueWindow,this._percentWindow=i.percentWindow,this._setAxisModel()}},r.prototype.filterData=function(t,e){if(t!==this._dataZoomModel)return;var i=this._dimName,n=this.getTargetSeriesModels(),a=t.get("filterMode"),o=this._valueWindow;if(a==="none")return;Xi(n,function(l){var u=l.getData(),f=u.mapDimensionsAll(i);if(f.length){if(a==="weakFilter"){var h=u.getStore(),c=K(f,function(v){return u.getDimensionIndex(v)},u);u.filterSelf(function(v){for(var d,g,m,p=0;p<f.length;p++){var y=h.get(c[p],v),_=!isNaN(y),S=y<o[0],x=y>o[1];if(_&&!S&&!x)return!0;_&&(m=!0),S&&(d=!0),x&&(g=!0)}return m&&d&&g})}else Xi(f,function(v){if(a==="empty")l.setData(u=u.map(v,function(g){return s(g)?g:NaN}));else{var d={};d[v]=o,u.selectRange(d)}});Xi(f,function(v){u.setApproximateExtent(o,v)})}});function s(l){return l>=o[0]&&l<=o[1]}},r.prototype._updateMinMaxSpan=function(){var t=this._minMaxSpan={},e=this._dataZoomModel,i=this._dataExtent;Xi(["min","max"],function(n){var a=e.get(n+"Span"),o=e.get(n+"ValueSpan");o!=null&&(o=this.getAxisModel().axis.scale.parse(o)),o!=null?a=Pt(i[0]+o,i,[0,100],!0):a!=null&&(o=Pt(a,[0,100],i,!0)-i[0]),t[n+"Span"]=a,t[n+"ValueSpan"]=o},this)},r.prototype._setAxisModel=function(){var t=this.getAxisModel(),e=this._percentWindow,i=this._valueWindow;if(e){var n=yg(i,[0,500]);n=Math.min(n,20);var a=t.axis.scale.rawExtentInfo;e[0]!==0&&a.setDeterminedMinMax("min",+i[0].toFixed(n)),e[1]!==100&&a.setDeterminedMinMax("max",+i[1].toFixed(n)),a.freeze()}},r})();function s2(r,t,e){var i=[1/0,-1/0];Xi(e,function(o){lD(i,o.getData(),t)});var n=r.getAxisModel(),a=Vy(n.axis.scale,n,i).calculate();return[a.min,a.max]}var l2={getTargetSeries:function(r){function t(n){r.eachComponent("dataZoom",function(a){a.eachTargetAxis(function(o,s){var l=r.getComponent(wr(o),s);n(o,s,l,a)})})}t(function(n,a,o,s){o.__dzAxisProxy=null});var e=[];t(function(n,a,o,s){o.__dzAxisProxy||(o.__dzAxisProxy=new o2(n,a,s,r),e.push(o.__dzAxisProxy))});var i=Q();return T(e,function(n){T(n.getTargetSeriesModels(),function(a){i.set(a.uid,a)})}),i},overallReset:function(r,t){r.eachComponent("dataZoom",function(e){e.eachTargetAxis(function(i,n){e.getAxisProxy(i,n).reset(e)}),e.eachTargetAxis(function(i,n){e.getAxisProxy(i,n).filterData(e,t)})}),r.eachComponent("dataZoom",function(e){var i=e.findRepresentativeAxisProxy();if(i){var n=i.getDataPercentWindow(),a=i.getDataValueWindow();e.setCalculatedRange({start:n[0],end:n[1],startValue:a[0],endValue:a[1]})}})}};function u2(r){r.registerAction("dataZoom",function(t,e){var i=a2(e,t);T(i,function(n){n.setRawRange({start:t.start,end:t.end,startValue:t.startValue,endValue:t.endValue})})})}var wp=!1;function T0(r){wp||(wp=!0,r.registerProcessor(r.PRIORITY.PROCESSOR.FILTER,l2),u2(r),r.registerSubTypeDefaulter("dataZoom",function(){return"slider"}))}function f2(r,t){var e=Xs(t.get("padding")),i=t.getItemStyle(["color","opacity"]);i.fill=t.get("backgroundColor");var n=new wt({shape:{x:r.x-e[3],y:r.y-e[0],width:r.width+e[1]+e[3],height:r.height+e[0]+e[2],r:t.get("borderRadius")},style:i,silent:!0,z2:-1});return n}var h2=(function(r){B(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.type="tooltip",t.dependencies=["axisPointer"],t.defaultOption={z:60,show:!0,showContent:!0,trigger:"item",triggerOn:"mousemove|click",alwaysShowContent:!1,renderMode:"auto",confine:null,showDelay:0,hideDelay:100,transitionDuration:.4,displayTransition:!0,enterable:!1,backgroundColor:H.color.neutral00,shadowBlur:10,shadowColor:"rgba(0, 0, 0, .2)",shadowOffsetX:1,shadowOffsetY:2,borderRadius:4,borderWidth:1,defaultBorderColor:H.color.border,padding:null,extraCssText:"",axisPointer:{type:"line",axis:"auto",animation:"auto",animationDurationUpdate:200,animationEasingUpdate:"exponentialOut",crossStyle:{color:H.color.borderShade,width:1,type:"dashed",textStyle:{}}},textStyle:{color:H.color.tertiary,fontSize:14}},t})(ut);function C0(r){var t=r.get("confine");return t!=null?!!t:r.get("renderMode")==="richText"}function M0(r){if(j.domSupported){for(var t=document.documentElement.style,e=0,i=r.length;e<i;e++)if(r[e]in t)return r[e]}}var D0=M0(["transform","webkitTransform","OTransform","MozTransform","msTransform"]),v2=M0(["webkitTransition","transition","OTransition","MozTransition","msTransition"]);function A0(r,t){if(!r)return t;t=Tm(t,!0);var e=r.indexOf(t);return r=e===-1?t:"-"+r.slice(0,e)+"-"+t,r.toLowerCase()}function c2(r,t){var e=r.currentStyle||document.defaultView&&document.defaultView.getComputedStyle(r);return e?e[t]:null}var d2=A0(v2,"transition"),qh=A0(D0,"transform"),p2="position:absolute;display:block;border-style:solid;white-space:nowrap;z-index:9999999;"+(j.transform3dSupported?"will-change:transform;":"");function g2(r){return r=r==="left"?"right":r==="right"?"left":r==="top"?"bottom":"top",r}function m2(r,t,e){if(!W(e)||e==="inside")return"";var i=r.get("backgroundColor"),n=r.get("borderWidth");t=bi(t);var a=g2(e),o=Math.max(Math.round(n)*1.5,6),s="",l=qh+":",u;at(["left","right"],a)>-1?(s+="top:50%",l+="translateY(-50%) rotate("+(u=a==="left"?-225:-45)+"deg)"):(s+="left:50%",l+="translateX(-50%) rotate("+(u=a==="top"?225:45)+"deg)");var f=u*Math.PI/180,h=o+n,c=h*Math.abs(Math.cos(f))+h*Math.abs(Math.sin(f)),v=Math.round(((c-Math.SQRT2*n)/2+Math.SQRT2*n-(c-h)/2)*100)/100;s+=";"+a+":-"+v+"px";var d=t+" solid "+n+"px;",g=["position:absolute;width:"+o+"px;height:"+o+"px;z-index:-1;",s+";"+l+";","border-bottom:"+d,"border-right:"+d,"background-color:"+i+";"];return'<div style="'+g.join("")+'"></div>'}function y2(r,t,e){var i="cubic-bezier(0.23,1,0.32,1)",n="",a="";return e&&(n=" "+r/2+"s "+i,a="opacity"+n+",visibility"+n),t||(n=" "+r+"s "+i,a+=(a.length?",":"")+(j.transformSupported?""+qh+n:",left"+n+",top"+n)),d2+":"+a}function xp(r,t,e){var i=r.toFixed(0)+"px",n=t.toFixed(0)+"px";if(!j.transformSupported)return e?"top:"+n+";left:"+i+";":[["top",n],["left",i]];var a=j.transform3dSupported,o="translate"+(a?"3d":"")+"("+i+","+n+(a?",0":"")+")";return e?"top:0;left:0;"+qh+":"+o+";":[["top",0],["left",0],[D0,o]]}function _2(r){var t=[],e=r.get("fontSize"),i=r.getTextColor();i&&t.push("color:"+i),t.push("font:"+r.getFont());var n=$(r.get("lineHeight"),Math.round(e*3/2));e&&t.push("line-height:"+n+"px");var a=r.get("textShadowColor"),o=r.get("textShadowBlur")||0,s=r.get("textShadowOffsetX")||0,l=r.get("textShadowOffsetY")||0;return a&&o&&t.push("text-shadow:"+s+"px "+l+"px "+o+"px "+a),T(["decoration","align"],function(u){var f=r.get(u);f&&t.push("text-"+u+":"+f)}),t.join(";")}function S2(r,t,e,i){var n=[],a=r.get("transitionDuration"),o=r.get("backgroundColor"),s=r.get("shadowBlur"),l=r.get("shadowColor"),u=r.get("shadowOffsetX"),f=r.get("shadowOffsetY"),h=r.getModel("textStyle"),c=Qm(r,"html"),v=u+"px "+f+"px "+s+"px "+l;return n.push("box-shadow:"+v),t&&a>0&&n.push(y2(a,e,i)),o&&n.push("background-color:"+o),T(["width","color","radius"],function(d){var g="border-"+d,m=Tm(g),p=r.get(m);p!=null&&n.push(g+":"+p+(d==="color"?"":"px"))}),n.push(_2(h)),c!=null&&n.push("padding:"+Xs(c).join("px ")+"px"),n.join(";")+";"}function bp(r,t,e,i,n){var a=t&&t.painter;if(e){var o=a&&a.getViewportRoot();o&&O_(r,o,e,i,n)}else{r[0]=i,r[1]=n;var s=a&&a.getViewportRootOffset();s&&(r[0]+=s.offsetLeft,r[1]+=s.offsetTop)}r[2]=r[0]/t.getWidth(),r[3]=r[1]/t.getHeight()}var w2=(function(){function r(t,e){if(this._show=!1,this._styleCoord=[0,0,0,0],this._enterable=!0,this._alwaysShowContent=!1,this._firstShow=!0,this._longHide=!0,j.wxa)return null;var i=document.createElement("div");i.domBelongToZr=!0,this.el=i;var n=this._zr=t.getZr(),a=e.appendTo,o=a&&(W(a)?document.querySelector(a):oa(a)?a:J(a)&&a(t.getDom()));bp(this._styleCoord,n,o,t.getWidth()/2,t.getHeight()/2),(o||t.getDom()).appendChild(i),this._api=t,this._container=o;var s=this;i.onmouseenter=function(){s._enterable&&(clearTimeout(s._hideTimeout),s._show=!0),s._inContent=!0},i.onmousemove=function(l){if(l=l||window.event,!s._enterable){var u=n.handler,f=n.painter.getViewportRoot();ue(f,l,!0),u.dispatch("mousemove",l)}},i.onmouseleave=function(){s._inContent=!1,s._enterable&&s._show&&s.hideLater(s._hideDelay)}}return r.prototype.update=function(t){if(!this._container){var e=this._api.getDom(),i=c2(e,"position"),n=e.style;n.position!=="absolute"&&i!=="absolute"&&(n.position="relative")}var a=t.get("alwaysShowContent");a&&this._moveIfResized(),this._alwaysShowContent=a,this._enableDisplayTransition=t.get("displayTransition")&&t.get("transitionDuration")>0,this.el.className=t.get("className")||""},r.prototype.show=function(t,e){clearTimeout(this._hideTimeout),clearTimeout(this._longHideTimeout);var i=this.el,n=i.style,a=this._styleCoord;i.innerHTML?n.cssText=p2+S2(t,!this._firstShow,this._longHide,this._enableDisplayTransition)+xp(a[0],a[1],!0)+("border-color:"+bi(e)+";")+(t.get("extraCssText")||"")+(";pointer-events:"+(this._enterable?"auto":"none")):n.display="none",this._show=!0,this._firstShow=!1,this._longHide=!1},r.prototype.setContent=function(t,e,i,n,a){var o=this.el;if(t==null){o.innerHTML="";return}var s="";if(W(a)&&i.get("trigger")==="item"&&!C0(i)&&(s=m2(i,n,a)),W(t))o.innerHTML=t+s;else if(t){o.innerHTML="",V(t)||(t=[t]);for(var l=0;l<t.length;l++)oa(t[l])&&t[l].parentNode!==o&&o.appendChild(t[l]);if(s&&o.childNodes.length){var u=document.createElement("div");u.innerHTML=s,o.appendChild(u)}}},r.prototype.setEnterable=function(t){this._enterable=t},r.prototype.getSize=function(){var t=this.el;return t?[t.offsetWidth,t.offsetHeight]:[0,0]},r.prototype.moveTo=function(t,e){if(this.el){var i=this._styleCoord;if(bp(i,this._zr,this._container,t,e),i[0]!=null&&i[1]!=null){var n=this.el.style,a=xp(i[0],i[1]);T(a,function(o){n[o[0]]=o[1]})}}},r.prototype._moveIfResized=function(){var t=this._styleCoord[2],e=this._styleCoord[3];this.moveTo(t*this._zr.getWidth(),e*this._zr.getHeight())},r.prototype.hide=function(){var t=this,e=this.el.style;this._enableDisplayTransition?(e.visibility="hidden",e.opacity="0"):e.display="none",j.transform3dSupported&&(e.willChange=""),this._show=!1,this._longHideTimeout=setTimeout(function(){return t._longHide=!0},500)},r.prototype.hideLater=function(t){this._show&&!(this._inContent&&this._enterable)&&!this._alwaysShowContent&&(t?(this._hideDelay=t,this._show=!1,this._hideTimeout=setTimeout(q(this.hide,this),t)):this.hide())},r.prototype.isShow=function(){return this._show},r.prototype.dispose=function(){clearTimeout(this._hideTimeout),clearTimeout(this._longHideTimeout);var t=this._zr;B_(t&&t.painter&&t.painter.getViewportRoot(),this._container);var e=this.el;if(e){e.onmouseenter=e.onmousemove=e.onmouseleave=null;var i=e.parentNode;i&&i.removeChild(e)}this.el=this._container=null},r})(),x2=(function(){function r(t){this._show=!1,this._styleCoord=[0,0,0,0],this._alwaysShowContent=!1,this._enterable=!0,this._zr=t.getZr(),Cp(this._styleCoord,this._zr,t.getWidth()/2,t.getHeight()/2)}return r.prototype.update=function(t){var e=t.get("alwaysShowContent");e&&this._moveIfResized(),this._alwaysShowContent=e},r.prototype.show=function(){this._hideTimeout&&clearTimeout(this._hideTimeout),this.el.show(),this._show=!0},r.prototype.setContent=function(t,e,i,n,a){var o=this;Z(t)&&Kt(""),this.el&&this._zr.remove(this.el);var s=i.getModel("textStyle");this.el=new Nt({style:{rich:e.richTextStyles,text:t,lineHeight:22,borderWidth:1,borderColor:n,textShadowColor:s.get("textShadowColor"),fill:i.get(["textStyle","color"]),padding:Qm(i,"richText"),verticalAlign:"top",align:"left"},z:i.get("z")}),T(["backgroundColor","borderRadius","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"],function(u){o.el.style[u]=i.get(u)}),T(["textShadowBlur","textShadowOffsetX","textShadowOffsetY"],function(u){o.el.style[u]=s.get(u)||0}),this._zr.add(this.el);var l=this;this.el.on("mouseover",function(){l._enterable&&(clearTimeout(l._hideTimeout),l._show=!0),l._inContent=!0}),this.el.on("mouseout",function(){l._enterable&&l._show&&l.hideLater(l._hideDelay),l._inContent=!1})},r.prototype.setEnterable=function(t){this._enterable=t},r.prototype.getSize=function(){var t=this.el,e=this.el.getBoundingRect(),i=Tp(t.style);return[e.width+i.left+i.right,e.height+i.top+i.bottom]},r.prototype.moveTo=function(t,e){var i=this.el;if(i){var n=this._styleCoord;Cp(n,this._zr,t,e),t=n[0],e=n[1];var a=i.style,o=yr(a.borderWidth||0),s=Tp(a);i.x=t+o+s.left,i.y=e+o+s.top,i.markRedraw()}},r.prototype._moveIfResized=function(){var t=this._styleCoord[2],e=this._styleCoord[3];this.moveTo(t*this._zr.getWidth(),e*this._zr.getHeight())},r.prototype.hide=function(){this.el&&this.el.hide(),this._show=!1},r.prototype.hideLater=function(t){this._show&&!(this._inContent&&this._enterable)&&!this._alwaysShowContent&&(t?(this._hideDelay=t,this._show=!1,this._hideTimeout=setTimeout(q(this.hide,this),t)):this.hide())},r.prototype.isShow=function(){return this._show},r.prototype.dispose=function(){this._zr.remove(this.el)},r})();function yr(r){return Math.max(0,r)}function Tp(r){var t=yr(r.shadowBlur||0),e=yr(r.shadowOffsetX||0),i=yr(r.shadowOffsetY||0);return{left:yr(t-e),right:yr(t+e),top:yr(t-i),bottom:yr(t+i)}}function Cp(r,t,e,i){r[0]=e,r[1]=i,r[2]=r[0]/t.getWidth(),r[3]=r[1]/t.getHeight()}var b2=new wt({shape:{x:-1,y:-1,width:2,height:2}}),T2=(function(r){B(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.init=function(e,i){if(!(j.node||!i.getDom())){var n=e.getComponent("tooltip"),a=this._renderMode=dS(n.get("renderMode"));this._tooltipContent=a==="richText"?new x2(i):new w2(i,{appendTo:n.get("appendToBody",!0)?"body":n.get("appendTo",!0)})}},t.prototype.render=function(e,i,n){if(!(j.node||!n.getDom())){this.group.removeAll(),this._tooltipModel=e,this._ecModel=i,this._api=n;var a=this._tooltipContent;a.update(e),a.setEnterable(e.get("enterable")),this._initGlobalListener(),this._keepShow(),this._renderMode!=="richText"&&e.get("transitionDuration")?Qs(this,"_updatePosition",50,"fixRate"):cs(this,"_updatePosition")}},t.prototype._initGlobalListener=function(){var e=this._tooltipModel,i=e.get("triggerOn");_0("itemTooltip",this._api,q(function(n,a,o){i!=="none"&&(i.indexOf(n)>=0?this._tryShow(a,o):n==="leave"&&this._hide(o))},this))},t.prototype._keepShow=function(){var e=this._tooltipModel,i=this._ecModel,n=this._api,a=e.get("triggerOn");if(this._lastX!=null&&this._lastY!=null&&a!=="none"&&a!=="click"){var o=this;clearTimeout(this._refreshUpdateTimeout),this._refreshUpdateTimeout=setTimeout(function(){!n.isDisposed()&&o.manuallyShowTip(e,i,n,{x:o._lastX,y:o._lastY,dataByCoordSys:o._lastDataByCoordSys})})}},t.prototype.manuallyShowTip=function(e,i,n,a){if(!(a.from===this.uid||j.node||!n.getDom())){var o=Mp(a,n);this._ticket="";var s=a.dataByCoordSys,l=A2(a,i,n);if(l){var u=l.el.getBoundingRect().clone();u.applyTransform(l.el.transform),this._tryShow({offsetX:u.x+u.width/2,offsetY:u.y+u.height/2,target:l.el,position:a.position,positionDefault:"bottom"},o)}else if(a.tooltip&&a.x!=null&&a.y!=null){var f=b2;f.x=a.x,f.y=a.y,f.update(),ft(f).tooltipConfig={name:null,option:a.tooltip},this._tryShow({offsetX:a.x,offsetY:a.y,target:f},o)}else if(s)this._tryShow({offsetX:a.x,offsetY:a.y,position:a.position,dataByCoordSys:s,tooltipOption:a.tooltipOption},o);else if(a.seriesIndex!=null){if(this._manuallyAxisShowTip(e,i,n,a))return;var h=S0(a,i),c=h.point[0],v=h.point[1];c!=null&&v!=null&&this._tryShow({offsetX:c,offsetY:v,target:h.el,position:a.position,positionDefault:"bottom"},o)}else a.x!=null&&a.y!=null&&(n.dispatchAction({type:"updateAxisPointer",x:a.x,y:a.y}),this._tryShow({offsetX:a.x,offsetY:a.y,position:a.position,target:n.getZr().findHover(a.x,a.y).target},o))}},t.prototype.manuallyHideTip=function(e,i,n,a){var o=this._tooltipContent;this._tooltipModel&&o.hideLater(this._tooltipModel.get("hideDelay")),this._lastX=this._lastY=this._lastDataByCoordSys=null,a.from!==this.uid&&this._hide(Mp(a,n))},t.prototype._manuallyAxisShowTip=function(e,i,n,a){var o=a.seriesIndex,s=a.dataIndex,l=i.getComponent("axisPointer").coordSysAxesInfo;if(!(o==null||s==null||l==null)){var u=i.getSeriesByIndex(o);if(u){var f=u.getData(),h=On([f.getItemModel(s),u,(u.coordinateSystem||{}).model],this._tooltipModel);if(h.get("trigger")==="axis")return n.dispatchAction({type:"updateAxisPointer",seriesIndex:o,dataIndex:s,position:a.position}),!0}}},t.prototype._tryShow=function(e,i){var n=e.target,a=this._tooltipModel;if(a){this._lastX=e.offsetX,this._lastY=e.offsetY;var o=e.dataByCoordSys;if(o&&o.length)this._showAxisTooltip(o,e);else if(n){var s=ft(n);if(s.ssrType==="legend")return;this._lastDataByCoordSys=null;var l,u;Yn(n,function(f){if(f.tooltipDisabled)return l=u=null,!0;l||u||(ft(f).dataIndex!=null?l=f:ft(f).tooltipConfig!=null&&(u=f))},!0),l?this._showSeriesItemTooltip(e,l,i):u?this._showComponentItemTooltip(e,u,i):this._hide(i)}else this._lastDataByCoordSys=null,this._hide(i)}},t.prototype._showOrMove=function(e,i){var n=e.get("showDelay");i=q(i,this),clearTimeout(this._showTimout),n>0?this._showTimout=setTimeout(i,n):i()},t.prototype._showAxisTooltip=function(e,i){var n=this._ecModel,a=this._tooltipModel,o=[i.offsetX,i.offsetY],s=On([i.tooltipOption],a),l=this._renderMode,u=[],f=_a("section",{blocks:[],noHeader:!0}),h=[],c=new Kl;T(e,function(y){T(y.dataByAxis,function(_){var S=n.getComponent(_.axisDim+"Axis",_.axisIndex),x=_.value;if(!(!S||x==null)){var w=m0(x,S.axis,n,_.seriesDataIndices,_.valueLabelOpt),b=_a("section",{header:w,noHeader:!ke(w),sortBlocks:!0,blocks:[]});f.blocks.push(b),T(_.seriesDataIndices,function(D){var C=n.getSeriesByIndex(D.seriesIndex),M=D.dataIndexInside,A=C.getDataParams(M);if(!(A.dataIndex<0)){A.axisDim=_.axisDim,A.axisIndex=_.axisIndex,A.axisType=_.axisType,A.axisId=_.axisId,A.axisValue=Ss(S.axis,{value:x}),A.axisValueLabel=w,A.marker=c.makeTooltipMarker("item",bi(A.color),l);var P=Kc(C.formatTooltip(M,!0,null)),L=P.frag;if(L){var I=On([C],a).get("valueFormatter");b.blocks.push(I?O({valueFormatter:I},L):L)}P.text&&h.push(P.text),u.push(A)}})}})}),f.blocks.reverse(),h.reverse();var v=i.position,d=s.get("order"),g=ed(f,c,l,d,n.get("useUTC"),s.get("textStyle"));g&&h.unshift(g);var m=l==="richText"?`
36
+
37
+ `:"<br/>",p=h.join(m);this._showOrMove(s,function(){this._updateContentNotChangedOnAxis(e,u)?this._updatePosition(s,v,o[0],o[1],this._tooltipContent,u):this._showTooltipContent(s,p,u,Math.random()+"",o[0],o[1],v,null,c)})},t.prototype._showSeriesItemTooltip=function(e,i,n){var a=this._ecModel,o=ft(i),s=o.seriesIndex,l=a.getSeriesByIndex(s),u=o.dataModel||l,f=o.dataIndex,h=o.dataType,c=u.getData(h),v=this._renderMode,d=e.positionDefault,g=On([c.getItemModel(f),u,l&&(l.coordinateSystem||{}).model],this._tooltipModel,d?{position:d}:null),m=g.get("trigger");if(!(m!=null&&m!=="item")){var p=u.getDataParams(f,h),y=new Kl;p.marker=y.makeTooltipMarker("item",bi(p.color),v);var _=Kc(u.formatTooltip(f,!1,h)),S=g.get("order"),x=g.get("valueFormatter"),w=_.frag,b=w?ed(x?O({valueFormatter:x},w):w,y,v,S,a.get("useUTC"),g.get("textStyle")):_.text,D="item_"+u.name+"_"+f;this._showOrMove(g,function(){this._showTooltipContent(g,b,p,D,e.offsetX,e.offsetY,e.position,e.target,y)}),n({type:"showTip",dataIndexInside:f,dataIndex:c.getRawIndex(f),seriesIndex:s,from:this.uid})}},t.prototype._showComponentItemTooltip=function(e,i,n){var a=this._renderMode==="html",o=ft(i),s=o.tooltipConfig,l=s.option||{},u=l.encodeHTMLContent;if(W(l)){var f=l;l={content:f,formatter:f},u=!0}u&&a&&l.content&&(l=it(l),l.content=qt(l.content));var h=[l],c=this._ecModel.getComponent(o.componentMainType,o.componentIndex);c&&h.push(c),h.push({formatter:l.content});var v=e.positionDefault,d=On(h,this._tooltipModel,v?{position:v}:null),g=d.get("content"),m=Math.random()+"",p=new Kl;this._showOrMove(d,function(){var y=it(d.get("formatterParams")||{});this._showTooltipContent(d,g,y,m,e.offsetX,e.offsetY,e.position,i,p)}),n({type:"showTip",from:this.uid})},t.prototype._showTooltipContent=function(e,i,n,a,o,s,l,u,f){if(this._ticket="",!(!e.get("showContent")||!e.get("show"))){var h=this._tooltipContent;h.setEnterable(e.get("enterable"));var c=e.get("formatter");l=l||e.get("position");var v=i,d=this._getNearestPoint([o,s],n,e.get("trigger"),e.get("borderColor"),e.get("defaultBorderColor",!0)),g=d.color;if(c)if(W(c)){var m=e.ecModel.get("useUTC"),p=V(n)?n[0]:n,y=p&&p.axisType&&p.axisType.indexOf("time")>=0;v=c,y&&(v=Zs(p.axisValue,v,m)),v=Cm(v,n,!0)}else if(J(c)){var _=q(function(S,x){S===this._ticket&&(h.setContent(x,f,e,g,l),this._updatePosition(e,l,o,s,h,n,u))},this);this._ticket=a,v=c(n,a,_)}else v=c;h.setContent(v,f,e,g,l),h.show(e,g),this._updatePosition(e,l,o,s,h,n,u)}},t.prototype._getNearestPoint=function(e,i,n,a,o){if(n==="axis"||V(i))return{color:a||o};if(!V(i))return{color:a||i.color||i.borderColor}},t.prototype._updatePosition=function(e,i,n,a,o,s,l){var u=this._api.getWidth(),f=this._api.getHeight();i=i||e.get("position");var h=o.getSize(),c=e.get("align"),v=e.get("verticalAlign"),d=l&&l.getBoundingRect().clone();if(l&&d.applyTransform(l.transform),J(i)&&(i=i([n,a],s,o.el,d,{viewSize:[u,f],contentSize:h.slice()})),V(i))n=Ot(i[0],u),a=Ot(i[1],f);else if(Z(i)){var g=i;g.width=h[0],g.height=h[1];var m=Ti(g,{width:u,height:f});n=m.x,a=m.y,c=null,v=null}else if(W(i)&&l){var p=D2(i,d,h,e.get("borderWidth"));n=p[0],a=p[1]}else{var p=C2(n,a,o,u,f,c?null:20,v?null:20);n=p[0],a=p[1]}if(c&&(n-=Dp(c)?h[0]/2:c==="right"?h[0]:0),v&&(a-=Dp(v)?h[1]/2:v==="bottom"?h[1]:0),C0(e)){var p=M2(n,a,o,u,f);n=p[0],a=p[1]}o.moveTo(n,a)},t.prototype._updateContentNotChangedOnAxis=function(e,i){var n=this._lastDataByCoordSys,a=this._cbParamsList,o=!!n&&n.length===e.length;return o&&T(n,function(s,l){var u=s.dataByAxis||[],f=e[l]||{},h=f.dataByAxis||[];o=o&&u.length===h.length,o&&T(u,function(c,v){var d=h[v]||{},g=c.seriesDataIndices||[],m=d.seriesDataIndices||[];o=o&&c.value===d.value&&c.axisType===d.axisType&&c.axisId===d.axisId&&g.length===m.length,o&&T(g,function(p,y){var _=m[y];o=o&&p.seriesIndex===_.seriesIndex&&p.dataIndex===_.dataIndex}),a&&T(c.seriesDataIndices,function(p){var y=p.seriesIndex,_=i[y],S=a[y];_&&S&&S.data!==_.data&&(o=!1)})})}),this._lastDataByCoordSys=e,this._cbParamsList=i,!!o},t.prototype._hide=function(e){this._lastDataByCoordSys=null,e({type:"hideTip",from:this.uid})},t.prototype.dispose=function(e,i){j.node||!i.getDom()||(cs(this,"_updatePosition"),this._tooltipContent.dispose(),kf("itemTooltip",i))},t.type="tooltip",t})(me);function On(r,t,e){var i=t.ecModel,n;e?(n=new xt(e,i,i),n=new xt(t.option,n,i)):n=t;for(var a=r.length-1;a>=0;a--){var o=r[a];o&&(o instanceof xt&&(o=o.get("tooltip",!0)),W(o)&&(o={formatter:o}),o&&(n=new xt(o,n,i)))}return n}function Mp(r,t){return r.dispatchAction||q(t.dispatchAction,t)}function C2(r,t,e,i,n,a,o){var s=e.getSize(),l=s[0],u=s[1];return a!=null&&(r+l+a+2>i?r-=l+a:r+=a),o!=null&&(t+u+o>n?t-=u+o:t+=o),[r,t]}function M2(r,t,e,i,n){var a=e.getSize(),o=a[0],s=a[1];return r=Math.min(r+o,i)-o,t=Math.min(t+s,n)-s,r=Math.max(r,0),t=Math.max(t,0),[r,t]}function D2(r,t,e,i){var n=e[0],a=e[1],o=Math.ceil(Math.SQRT2*i)+8,s=0,l=0,u=t.width,f=t.height;switch(r){case"inside":s=t.x+u/2-n/2,l=t.y+f/2-a/2;break;case"top":s=t.x+u/2-n/2,l=t.y-a-o;break;case"bottom":s=t.x+u/2-n/2,l=t.y+f+o;break;case"left":s=t.x-n-o,l=t.y+f/2-a/2;break;case"right":s=t.x+u+o,l=t.y+f/2-a/2}return[s,l]}function Dp(r){return r==="center"||r==="middle"}function A2(r,t,e){var i=jf(r).queryOptionMap,n=i.keys()[0];if(!(!n||n==="series")){var a=Ra(t,n,i.get(n),{useDefault:!1,enableAll:!1,enableNone:!1}),o=a.models[0];if(o){var s=e.getViewOfComponentModel(o),l;if(s.group.traverse(function(u){var f=ft(u).tooltipConfig;if(f&&f.name===r.name)return l=u,!0}),l)return{componentMainType:n,componentIndex:o.componentIndex,el:l}}}}function L2(r){Ue(w0),r.registerComponentModel(h2),r.registerComponentView(T2),r.registerAction({type:"showTip",event:"showTip",update:"tooltip:manuallyShowTip"},Ut),r.registerAction({type:"hideTip",event:"hideTip",update:"tooltip:manuallyHideTip"},Ut)}var I2=(function(r){B(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e.layoutMode={type:"box",ignoreSize:!0},e}return t.type="title",t.defaultOption={z:6,show:!0,text:"",target:"blank",subtext:"",subtarget:"blank",left:"center",top:H.size.m,backgroundColor:H.color.transparent,borderColor:H.color.primary,borderWidth:0,padding:5,itemGap:10,textStyle:{fontSize:18,fontWeight:"bold",color:H.color.primary},subtextStyle:{fontSize:12,color:H.color.quaternary}},t})(ut),P2=(function(r){B(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.render=function(e,i,n){if(this.group.removeAll(),!!e.get("show")){var a=this.group,o=e.getModel("textStyle"),s=e.getModel("subtextStyle"),l=e.get("textAlign"),u=$(e.get("textBaseline"),e.get("textVerticalAlign")),f=new Nt({style:ar(o,{text:e.get("text"),fill:o.getTextColor()},{disableBox:!0}),z2:10}),h=f.getBoundingRect(),c=e.get("subtext"),v=new Nt({style:ar(s,{text:c,fill:s.getTextColor(),y:h.height+e.get("itemGap"),verticalAlign:"top"},{disableBox:!0}),z2:10}),d=e.get("link"),g=e.get("sublink"),m=e.get("triggerEvent",!0);f.silent=!d&&!m,v.silent=!g&&!m,d&&f.on("click",function(){Ic(d,"_"+e.get("target"))}),g&&v.on("click",function(){Ic(g,"_"+e.get("subtarget"))}),ft(f).eventData=ft(v).eventData=m?{componentType:"title",componentIndex:e.componentIndex}:null,a.add(f),c&&a.add(v);var p=a.getBoundingRect(),y=e.getBoxLayoutParams();y.width=p.width,y.height=p.height;var _=qs(e,n),S=Ti(y,_.refContainer,e.get("padding"));l||(l=e.get("left")||e.get("right"),l==="middle"&&(l="center"),l==="right"?S.x+=S.width:l==="center"&&(S.x+=S.width/2)),u||(u=e.get("top")||e.get("bottom"),u==="center"&&(u="middle"),u==="bottom"?S.y+=S.height:u==="middle"&&(S.y+=S.height/2),u=u||"top"),a.x=S.x,a.y=S.y,a.markRedraw();var x={align:l,verticalAlign:u};f.setStyle(x),v.setStyle(x),p=a.getBoundingRect();var w=S.margin,b=e.getItemStyle(["color","opacity"]);b.fill=e.get("backgroundColor");var D=new wt({shape:{x:p.x-w[3],y:p.y-w[0],width:p.width+w[1]+w[3],height:p.height+w[0]+w[2],r:e.get("borderRadius")},style:b,subPixelOptimize:!0,silent:!0});a.add(D)}},t.type="title",t})(me);function R2(r){r.registerComponentModel(I2),r.registerComponentView(P2)}function L0(r,t){var e=r.mapDimensionsAll("defaultedLabel"),i=e.length;if(i===1){var n=un(r,t,e[0]);return n!=null?n+"":null}else if(i){for(var a=[],o=0;o<e.length;o++)a.push(un(r,t,e[o]));return a.join(" ")}}function E2(r,t){var e=r.mapDimensionsAll("defaultedLabel");if(!V(t))return t+"";for(var i=[],n=0;n<e.length;n++){var a=r.getDimensionIndex(e[n]);a>=0&&i.push(t[a])}return i.join(" ")}var $h=(function(r){B(t,r);function t(e,i,n,a){var o=r.call(this)||this;return o.updateData(e,i,n,a),o}return t.prototype._createSymbol=function(e,i,n,a,o,s){this.removeAll();var l=Pr(e,-1,-1,2,2,null,s);l.attr({z2:$(o,100),culling:!0,scaleX:a[0]/2,scaleY:a[1]/2}),l.drift=k2,this._symbolType=e,this.add(l)},t.prototype.stopSymbolAnimation=function(e){this.childAt(0).stopAnimation(null,e)},t.prototype.getSymbolType=function(){return this._symbolType},t.prototype.getSymbolPath=function(){return this.childAt(0)},t.prototype.highlight=function(){ns(this.childAt(0))},t.prototype.downplay=function(){as(this.childAt(0))},t.prototype.setZ=function(e,i){var n=this.childAt(0);n.zlevel=e,n.z=i},t.prototype.setDraggable=function(e,i){var n=this.childAt(0);n.draggable=e,n.cursor=!i&&e?"move":n.cursor},t.prototype.updateData=function(e,i,n,a){this.silent=!1;var o=e.getItemVisual(i,"symbol")||"circle",s=e.hostModel,l=t.getSymbolSize(e,i),u=t.getSymbolZ2(e,i),f=o!==this._symbolType,h=a&&a.disableAnimation;if(f){var c=e.getItemVisual(i,"symbolKeepAspect");this._createSymbol(o,e,i,l,u,c)}else{var v=this.childAt(0);v.silent=!1;var d={scaleX:l[0]/2,scaleY:l[1]/2};h?v.attr(d):Ar(v,d,s,i),dx(v)}if(this._updateCommon(e,i,l,n,a),f){var v=this.childAt(0);if(!h){var d={scaleX:this._sizeX,scaleY:this._sizeY,style:{opacity:v.style.opacity}};v.scaleX=v.scaleY=0,v.style.opacity=0,ka(v,d,s,i)}}h&&this.childAt(0).stopAnimation("leave")},t.prototype._updateCommon=function(e,i,n,a,o){var s=this.childAt(0),l=e.hostModel,u,f,h,c,v,d,g,m,p;if(a&&(u=a.emphasisItemStyle,f=a.blurItemStyle,h=a.selectItemStyle,c=a.focus,v=a.blurScope,g=a.labelStatesModels,m=a.hoverScale,p=a.cursorStyle,d=a.emphasisDisabled),!a||e.hasItemOption){var y=a&&a.itemModel?a.itemModel:e.getItemModel(i),_=y.getModel("emphasis");u=_.getModel("itemStyle").getItemStyle(),h=y.getModel(["select","itemStyle"]).getItemStyle(),f=y.getModel(["blur","itemStyle"]).getItemStyle(),c=_.get("focus"),v=_.get("blurScope"),d=_.get("disabled"),g=mh(y),m=_.getShallow("scale"),p=y.getShallow("cursor")}var S=e.getItemVisual(i,"symbolRotate");s.attr("rotation",(S||0)*Math.PI/180||0);var x=ly(e.getItemVisual(i,"symbolOffset"),n);x&&(s.x=x[0],s.y=x[1]),p&&s.attr("cursor",p);var w=e.getItemVisual(i,"style"),b=w.fill;if(s instanceof Er){var D=s.style;s.useStyle(O({image:D.image,x:D.x,y:D.y,width:D.width,height:D.height},w))}else s.__isEmptyBrush?s.useStyle(O({},w)):s.useStyle(w),s.style.decal=null,s.setColor(b,o&&o.symbolInnerColor),s.style.strokeNoScale=!0;var C=e.getItemVisual(i,"liftZ"),M=this._z2;C!=null?M==null&&(this._z2=s.z2,s.z2+=C):M!=null&&(s.z2=M,this._z2=null);var A=o&&o.useNameLabel;gh(s,g,{labelFetcher:l,labelDataIndex:i,defaultText:P,inheritColor:b,defaultOpacity:w.opacity});function P(E){return A?e.getName(E):L0(e,E)}this._sizeX=n[0]/2,this._sizeY=n[1]/2;var L=s.ensureState("emphasis");L.style=u,s.ensureState("select").style=h,s.ensureState("blur").style=f;var I=m==null||m===!0?Math.max(1.1,3/this._sizeY):isFinite(m)&&m>0?+m:1;L.scaleX=this._sizeX*I,L.scaleY=this._sizeY*I,this.setSymbolScale(1),ef(this,c,v,d)},t.prototype.setSymbolScale=function(e){this.scaleX=this.scaleY=e},t.prototype.fadeOut=function(e,i,n){var a=this.childAt(0),o=ft(this).dataIndex,s=n&&n.animation;if(this.silent=a.silent=!0,n&&n.fadeLabel){var l=a.getTextContent();l&&ss(l,{style:{opacity:0}},i,{dataIndex:o,removeOpt:s,cb:function(){a.removeTextContent()}})}else a.removeTextContent();ss(a,{style:{opacity:0},scaleX:0,scaleY:0},i,{dataIndex:o,cb:e,removeOpt:s})},t.getSymbolSize=function(e,i){return dC(e.getItemVisual(i,"symbolSize"))},t.getSymbolZ2=function(e,i){return e.getItemVisual(i,"z2")},t})(Dt);function k2(r,t){this.parent.drift(r,t)}function gu(r,t,e,i){return t&&!isNaN(t[0])&&!isNaN(t[1])&&!(i.isIgnore&&i.isIgnore(e))&&!(i.clipShape&&!i.clipShape.contain(t[0],t[1]))&&r.getItemVisual(e,"symbol")!=="none"}function Ap(r){return r!=null&&!Z(r)&&(r={isIgnore:r}),r||{}}function Lp(r){var t=r.hostModel,e=t.getModel("emphasis");return{emphasisItemStyle:e.getModel("itemStyle").getItemStyle(),blurItemStyle:t.getModel(["blur","itemStyle"]).getItemStyle(),selectItemStyle:t.getModel(["select","itemStyle"]).getItemStyle(),focus:e.get("focus"),blurScope:e.get("blurScope"),emphasisDisabled:e.get("disabled"),hoverScale:e.get("scale"),labelStatesModels:mh(t),cursorStyle:t.get("cursor")}}var O2=(function(){function r(t){this.group=new Dt,this._SymbolCtor=t||$h}return r.prototype.updateData=function(t,e){this._progressiveEls=null,e=Ap(e);var i=this.group,n=t.hostModel,a=this._data,o=this._SymbolCtor,s=e.disableAnimation,l=Lp(t),u={disableAnimation:s},f=e.getSymbolPoint||function(h){return t.getItemLayout(h)};a||i.removeAll(),t.diff(a).add(function(h){var c=f(h);if(gu(t,c,h,e)){var v=new o(t,h,l,u);v.setPosition(c),t.setItemGraphicEl(h,v),i.add(v)}}).update(function(h,c){var v=a.getItemGraphicEl(c),d=f(h);if(!gu(t,d,h,e)){i.remove(v);return}var g=t.getItemVisual(h,"symbol")||"circle",m=v&&v.getSymbolType&&v.getSymbolType();if(!v||m&&m!==g)i.remove(v),v=new o(t,h,l,u),v.setPosition(d);else{v.updateData(t,h,l,u);var p={x:d[0],y:d[1]};s?v.attr(p):Ar(v,p,n)}i.add(v),t.setItemGraphicEl(h,v)}).remove(function(h){var c=a.getItemGraphicEl(h);c&&c.fadeOut(function(){i.remove(c)},n)}).execute(),this._getSymbolPoint=f,this._data=t},r.prototype.updateLayout=function(){var t=this,e=this._data;e&&e.eachItemGraphicEl(function(i,n){var a=t._getSymbolPoint(n);i.setPosition(a),i.markRedraw()})},r.prototype.incrementalPrepareUpdate=function(t){this._seriesScope=Lp(t),this._data=null,this.group.removeAll()},r.prototype.incrementalUpdate=function(t,e,i){this._progressiveEls=[],i=Ap(i);function n(l){l.isGroup||(l.incremental=!0,l.ensureState("emphasis").hoverLayer=!0)}for(var a=t.start;a<t.end;a++){var o=e.getItemLayout(a);if(gu(e,o,a,i)){var s=new this._SymbolCtor(e,a,this._seriesScope);s.traverse(n),s.setPosition(o),this.group.add(s),e.setItemGraphicEl(a,s),this._progressiveEls.push(s)}}},r.prototype.eachRendered=function(t){ch(this._progressiveEls||this.group,t)},r.prototype.remove=function(t){var e=this.group,i=this._data;i&&t?i.eachItemGraphicEl(function(n){n.fadeOut(function(){e.remove(n)},i.hostModel)}):e.removeAll()},r})();function B2(r,t){return r.type===t}var N2=function(r,t){if(t==="all")return{type:"all",title:r.getLocaleModel().get(["legend","selector","all"])};if(t==="inverse")return{type:"inverse",title:r.getLocaleModel().get(["legend","selector","inverse"])}},Of=(function(r){B(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e.layoutMode={type:"box",ignoreSize:!0},e}return t.prototype.init=function(e,i,n){this.mergeDefaultAndTheme(e,n),e.selected=e.selected||{},this._updateSelector(e)},t.prototype.mergeOption=function(e,i){r.prototype.mergeOption.call(this,e,i),this._updateSelector(e)},t.prototype._updateSelector=function(e){var i=e.selector,n=this.ecModel;i===!0&&(i=e.selector=["all","inverse"]),V(i)&&T(i,function(a,o){W(a)&&(a={type:a}),i[o]=st(a,N2(n,a.type))})},t.prototype.optionUpdated=function(){this._updateData(this.ecModel);var e=this._data;if(e[0]&&this.get("selectedMode")==="single"){for(var i=!1,n=0;n<e.length;n++){var a=e[n].get("name");if(this.isSelected(a)){this.select(a),i=!0;break}}!i&&this.select(e[0].get("name"))}},t.prototype._updateData=function(e){var i=[],n=[];e.eachRawSeries(function(l){var u=l.name;n.push(u);var f;if(l.legendVisualProvider){var h=l.legendVisualProvider,c=h.getAllNames();e.isSeriesFiltered(l)||(n=n.concat(c)),c.length?i=i.concat(c):f=!0}else f=!0;f&&Jf(l)&&i.push(l.name)}),this._availableNames=n;var a=this.get("data")||i,o=Q(),s=K(a,function(l){return(W(l)||mt(l))&&(l={name:l}),o.get(l.name)?null:(o.set(l.name,!0),new xt(l,this,this.ecModel))},this);this._data=Rt(s,function(l){return!!l})},t.prototype.getData=function(){return this._data},t.prototype.select=function(e){var i=this.option.selected,n=this.get("selectedMode");if(n==="single"){var a=this._data;T(a,function(o){i[o.get("name")]=!1})}i[e]=!0},t.prototype.unSelect=function(e){this.get("selectedMode")!=="single"&&(this.option.selected[e]=!1)},t.prototype.toggleSelected=function(e){var i=this.option.selected;i.hasOwnProperty(e)||(i[e]=!0),this[i[e]?"unSelect":"select"](e)},t.prototype.allSelect=function(){var e=this._data,i=this.option.selected;T(e,function(n){i[n.get("name",!0)]=!0})},t.prototype.inverseSelect=function(){var e=this._data,i=this.option.selected;T(e,function(n){var a=n.get("name",!0);i.hasOwnProperty(a)||(i[a]=!0),i[a]=!i[a]})},t.prototype.isSelected=function(e){var i=this.option.selected;return!(i.hasOwnProperty(e)&&!i[e])&&at(this._availableNames,e)>=0},t.prototype.getOrient=function(){return this.get("orient")==="vertical"?{index:1,name:"vertical"}:{index:0,name:"horizontal"}},t.type="legend.plain",t.dependencies=["series"],t.defaultOption={z:4,show:!0,orient:"horizontal",left:"center",bottom:H.size.m,align:"auto",backgroundColor:H.color.transparent,borderColor:H.color.border,borderRadius:0,borderWidth:0,padding:5,itemGap:8,itemWidth:25,itemHeight:14,symbolRotate:"inherit",symbolKeepAspect:!0,inactiveColor:H.color.disabled,inactiveBorderColor:H.color.disabled,inactiveBorderWidth:"auto",itemStyle:{color:"inherit",opacity:"inherit",borderColor:"inherit",borderWidth:"auto",borderCap:"inherit",borderJoin:"inherit",borderDashOffset:"inherit",borderMiterLimit:"inherit"},lineStyle:{width:"auto",color:"inherit",inactiveColor:H.color.disabled,inactiveWidth:2,opacity:"inherit",type:"inherit",cap:"inherit",join:"inherit",dashOffset:"inherit",miterLimit:"inherit"},textStyle:{color:H.color.secondary},selectedMode:!0,selector:!1,selectorLabel:{show:!0,borderRadius:10,padding:[3,5,3,5],fontSize:12,fontFamily:"sans-serif",color:H.color.tertiary,borderWidth:1,borderColor:H.color.border},emphasis:{selectorLabel:{show:!0,color:H.color.quaternary}},selectorPosition:"auto",selectorItemGap:7,selectorButtonGap:10,tooltip:{show:!1},triggerEvent:!1},t})(ut),Yi=Mt,Bf=T,Do=Dt,I0=(function(r){B(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e.newlineDisabled=!1,e}return t.prototype.init=function(){this.group.add(this._contentGroup=new Do),this.group.add(this._selectorGroup=new Do),this._isFirstRender=!0},t.prototype.getContentGroup=function(){return this._contentGroup},t.prototype.getSelectorGroup=function(){return this._selectorGroup},t.prototype.render=function(e,i,n){var a=this._isFirstRender;if(this._isFirstRender=!1,this.resetInner(),!!e.get("show",!0)){var o=e.get("align"),s=e.get("orient");(!o||o==="auto")&&(o=e.get("left")==="right"&&s==="vertical"?"right":"left");var l=e.get("selector",!0),u=e.get("selectorPosition",!0);l&&(!u||u==="auto")&&(u=s==="horizontal"?"end":"start"),this.renderInner(o,e,i,n,l,s,u);var f=qs(e,n).refContainer,h=e.getBoxLayoutParams(),c=e.get("padding"),v=Ti(h,f,c),d=this.layoutInner(e,o,v,a,l,u),g=Ti(ht({width:d.width,height:d.height},h),f,c);this.group.x=g.x-d.x,this.group.y=g.y-d.y,this.group.markRedraw(),this.group.add(this._backgroundEl=f2(d,e))}},t.prototype.resetInner=function(){this.getContentGroup().removeAll(),this._backgroundEl&&this.group.remove(this._backgroundEl),this.getSelectorGroup().removeAll()},t.prototype.renderInner=function(e,i,n,a,o,s,l){var u=this.getContentGroup(),f=Q(),h=i.get("selectedMode"),c=i.get("triggerEvent"),v=[];n.eachRawSeries(function(d){!d.get("legendHoverLink")&&v.push(d.id)}),Bf(i.getData(),function(d,g){var m=this,p=d.get("name");if(!this.newlineDisabled&&(p===""||p===`
38
+ `)){var y=new Do;y.newline=!0,u.add(y);return}var _=n.getSeriesByName(p)[0];if(!f.get(p))if(_){var S=_.getData(),x=S.getVisual("legendLineStyle")||{},w=S.getVisual("legendIcon"),b=S.getVisual("style"),D=this._createItem(_,p,g,d,i,e,x,b,w,h,a);D.on("click",Yi(Ip,p,null,a,v)).on("mouseover",Yi(Nf,_.name,null,a,v)).on("mouseout",Yi(Ff,_.name,null,a,v)),n.ssr&&D.eachChild(function(C){var M=ft(C);M.seriesIndex=_.seriesIndex,M.dataIndex=g,M.ssrType="legend"}),c&&D.eachChild(function(C){m.packEventData(C,i,_,g,p)}),f.set(p,!0)}else n.eachRawSeries(function(C){var M=this;if(!f.get(p)&&C.legendVisualProvider){var A=C.legendVisualProvider;if(!A.containName(p))return;var P=A.indexOfName(p),L=A.getItemVisual(P,"style"),I=A.getItemVisual(P,"legendIcon"),E=Ne(L.fill);E&&E[3]===0&&(E[3]=.2,L=O(O({},L),{fill:Ia(E,"rgba")}));var k=this._createItem(C,p,g,d,i,e,{},L,I,h,a);k.on("click",Yi(Ip,null,p,a,v)).on("mouseover",Yi(Nf,null,p,a,v)).on("mouseout",Yi(Ff,null,p,a,v)),n.ssr&&k.eachChild(function(U){var z=ft(U);z.seriesIndex=C.seriesIndex,z.dataIndex=g,z.ssrType="legend"}),c&&k.eachChild(function(U){M.packEventData(U,i,C,g,p)}),f.set(p,!0)}},this)},this),o&&this._createSelector(o,i,a,s,l)},t.prototype.packEventData=function(e,i,n,a,o){var s={componentType:"legend",componentIndex:i.componentIndex,dataIndex:a,value:o,seriesIndex:n.seriesIndex};ft(e).eventData=s},t.prototype._createSelector=function(e,i,n,a,o){var s=this.getSelectorGroup();Bf(e,function(u){var f=u.type,h=new Nt({style:{x:0,y:0,align:"center",verticalAlign:"middle"},onclick:function(){n.dispatchAction({type:f==="all"?"legendAllSelect":"legendInverseSelect",legendId:i.id})}});s.add(h);var c=i.getModel("selectorLabel"),v=i.getModel(["emphasis","selectorLabel"]);gh(h,{normal:c,emphasis:v},{defaultText:u.title}),os(h)})},t.prototype._createItem=function(e,i,n,a,o,s,l,u,f,h,c){var v=e.visualDrawType,d=o.get("itemWidth"),g=o.get("itemHeight"),m=o.isSelected(i),p=a.get("symbolRotate"),y=a.get("symbolKeepAspect"),_=a.get("icon");f=_||f||"roundRect";var S=F2(f,a,l,u,v,m,c),x=new Do,w=a.getModel("textStyle");if(J(e.getLegendIcon)&&(!_||_==="inherit"))x.add(e.getLegendIcon({itemWidth:d,itemHeight:g,icon:f,iconRotate:p,itemStyle:S.itemStyle,lineStyle:S.lineStyle,symbolKeepAspect:y}));else{var b=_==="inherit"&&e.getData().getVisual("symbol")?p==="inherit"?e.getData().getVisual("symbolRotate"):p:0;x.add(z2({itemWidth:d,itemHeight:g,icon:f,iconRotate:b,itemStyle:S.itemStyle,symbolKeepAspect:y}))}var D=s==="left"?d+5:-5,C=s,M=o.get("formatter"),A=i;W(M)&&M?A=M.replace("{name}",i??""):J(M)&&(A=M(i));var P=m?w.getTextColor():a.get("inactiveColor");x.add(new Nt({style:ar(w,{text:A,x:D,y:g/2,fill:P,align:C,verticalAlign:"middle"},{inheritColor:P})}));var L=new wt({shape:x.getBoundingRect(),style:{fill:"transparent"}}),I=a.getModel("tooltip");return I.get("show")&&Ws({el:L,componentModel:o,itemName:i,itemTooltipOption:I.option}),x.add(L),x.eachChild(function(E){E.silent=!0}),L.silent=!h,this.getContentGroup().add(x),os(x),x.__legendDataIndex=n,x},t.prototype.layoutInner=function(e,i,n,a,o,s){var l=this.getContentGroup(),u=this.getSelectorGroup();ra(e.get("orient"),l,e.get("itemGap"),n.width,n.height);var f=l.getBoundingRect(),h=[-f.x,-f.y];if(u.markRedraw(),l.markRedraw(),o){ra("horizontal",u,e.get("selectorItemGap",!0));var c=u.getBoundingRect(),v=[-c.x,-c.y],d=e.get("selectorButtonGap",!0),g=e.getOrient().index,m=g===0?"width":"height",p=g===0?"height":"width",y=g===0?"y":"x";s==="end"?v[g]+=f[m]+d:h[g]+=c[m]+d,v[1-g]+=f[p]/2-c[p]/2,u.x=v[0],u.y=v[1],l.x=h[0],l.y=h[1];var _={x:0,y:0};return _[m]=f[m]+d+c[m],_[p]=Math.max(f[p],c[p]),_[y]=Math.min(0,c[y]+v[1-g]),_}else return l.x=h[0],l.y=h[1],this.group.getBoundingRect()},t.prototype.remove=function(){this.getContentGroup().removeAll(),this._isFirstRender=!0},t.type="legend.plain",t})(me);function F2(r,t,e,i,n,a,o){function s(m,p){m.lineWidth==="auto"&&(m.lineWidth=p.lineWidth>0?2:0),Bf(m,function(y,_){m[_]==="inherit"&&(m[_]=p[_])})}var l=t.getModel("itemStyle"),u=l.getItemStyle(),f=r.lastIndexOf("empty",0)===0?"fill":"stroke",h=l.getShallow("decal");u.decal=!h||h==="inherit"?i.decal:yf(h,o),u.fill==="inherit"&&(u.fill=i[n]),u.stroke==="inherit"&&(u.stroke=i[f]),u.opacity==="inherit"&&(u.opacity=(n==="fill"?i:e).opacity),s(u,i);var c=t.getModel("lineStyle"),v=c.getLineStyle();if(s(v,e),u.fill==="auto"&&(u.fill=i.fill),u.stroke==="auto"&&(u.stroke=i.fill),v.stroke==="auto"&&(v.stroke=i.fill),!a){var d=t.get("inactiveBorderWidth"),g=u[f];u.lineWidth=d==="auto"?i.lineWidth>0&&g?2:0:u.lineWidth,u.fill=t.get("inactiveColor"),u.stroke=t.get("inactiveBorderColor"),v.stroke=c.get("inactiveColor"),v.lineWidth=c.get("inactiveWidth")}return{itemStyle:u,lineStyle:v}}function z2(r){var t=r.icon||"roundRect",e=Pr(t,0,0,r.itemWidth,r.itemHeight,r.itemStyle.fill,r.symbolKeepAspect);return e.setStyle(r.itemStyle),e.rotation=(r.iconRotate||0)*Math.PI/180,e.setOrigin([r.itemWidth/2,r.itemHeight/2]),t.indexOf("empty")>-1&&(e.style.stroke=e.style.fill,e.style.fill=H.color.neutral00,e.style.lineWidth=2),e}function Ip(r,t,e,i){Ff(r,t,e,i),e.dispatchAction({type:"legendToggleSelect",name:r??t}),Nf(r,t,e,i)}function P0(r){for(var t=r.getZr().storage.getDisplayList(),e,i=0,n=t.length;i<n&&!(e=t[i].states.emphasis);)i++;return e&&e.hoverLayer}function Nf(r,t,e,i){P0(e)||e.dispatchAction({type:"highlight",seriesName:r,name:t,excludeSeriesId:i})}function Ff(r,t,e,i){P0(e)||e.dispatchAction({type:"downplay",seriesName:r,name:t,excludeSeriesId:i})}function H2(r){var t=r.findComponents({mainType:"legend"});t&&t.length&&r.filterSeries(function(e){for(var i=0;i<t.length;i++)if(!t[i].isSelected(e.name))return!1;return!0})}function Bn(r,t,e){var i=r==="allSelect"||r==="inverseSelect",n={},a=[];e.eachComponent({mainType:"legend",query:t},function(s){i?s[r]():s[r](t.name),Pp(s,n),a.push(s.componentIndex)});var o={};return e.eachComponent("legend",function(s){T(n,function(l,u){s[l?"select":"unSelect"](u)}),Pp(s,o)}),i?{selected:o,legendIndex:a}:{name:t.name,selected:o}}function Pp(r,t){var e=t||{};return T(r.getData(),function(i){var n=i.get("name");if(!(n===`
39
+ `||n==="")){var a=r.isSelected(n);xe(e,n)?e[n]=e[n]&&a:e[n]=a}}),e}function G2(r){r.registerAction("legendToggleSelect","legendselectchanged",Mt(Bn,"toggleSelected")),r.registerAction("legendAllSelect","legendselectall",Mt(Bn,"allSelect")),r.registerAction("legendInverseSelect","legendinverseselect",Mt(Bn,"inverseSelect")),r.registerAction("legendSelect","legendselected",Mt(Bn,"select")),r.registerAction("legendUnSelect","legendunselected",Mt(Bn,"unSelect"))}function R0(r){r.registerComponentModel(Of),r.registerComponentView(I0),r.registerProcessor(r.PRIORITY.PROCESSOR.SERIES_FILTER,H2),r.registerSubTypeDefaulter("legend",function(){return"plain"}),G2(r)}var V2=(function(r){B(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.setScrollDataIndex=function(e){this.option.scrollDataIndex=e},t.prototype.init=function(e,i,n){var a=pn(e);r.prototype.init.call(this,e,i,n),Rp(this,e,a)},t.prototype.mergeOption=function(e,i){r.prototype.mergeOption.call(this,e,i),Rp(this,this.option,e)},t.type="legend.scroll",t.defaultOption=yh(Of.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:H.color.accent50,pageIconInactiveColor:H.color.accent10,pageIconSize:15,pageTextStyle:{color:H.color.tertiary},animationDurationUpdate:800}),t})(Of);function Rp(r,t,e){var i=r.getOrient(),n=[1,1];n[i.index]=0,Lr(t,e,{type:"box",ignoreSize:!!n})}var Ep=Dt,mu=["width","height"],yu=["x","y"],W2=(function(r){B(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e.newlineDisabled=!0,e._currentIndex=0,e}return t.prototype.init=function(){r.prototype.init.call(this),this.group.add(this._containerGroup=new Ep),this._containerGroup.add(this.getContentGroup()),this.group.add(this._controllerGroup=new Ep)},t.prototype.resetInner=function(){r.prototype.resetInner.call(this),this._controllerGroup.removeAll(),this._containerGroup.removeClipPath(),this._containerGroup.__rectSize=null},t.prototype.renderInner=function(e,i,n,a,o,s,l){var u=this;r.prototype.renderInner.call(this,e,i,n,a,o,s,l);var f=this._controllerGroup,h=i.get("pageIconSize",!0),c=V(h)?h:[h,h];d("pagePrev",0);var v=i.getModel("pageTextStyle");f.add(new Nt({name:"pageText",style:{text:"xx/xx",fill:v.getTextColor(),font:v.getFont(),verticalAlign:"middle",align:"center"},silent:!0})),d("pageNext",1);function d(g,m){var p=g+"DataIndex",y=vh(i.get("pageIcons",!0)[i.getOrient().name][m],{onclick:q(u._pageGo,u,p,i,a)},{x:-c[0]/2,y:-c[1]/2,width:c[0],height:c[1]});y.name=g,f.add(y)}},t.prototype.layoutInner=function(e,i,n,a,o,s){var l=this.getSelectorGroup(),u=e.getOrient().index,f=mu[u],h=yu[u],c=mu[1-u],v=yu[1-u];o&&ra("horizontal",l,e.get("selectorItemGap",!0));var d=e.get("selectorButtonGap",!0),g=l.getBoundingRect(),m=[-g.x,-g.y],p=it(n);o&&(p[f]=n[f]-g[f]-d);var y=this._layoutContentAndController(e,a,p,u,f,c,v,h);if(o){if(s==="end")m[u]+=y[f]+d;else{var _=g[f]+d;m[u]-=_,y[h]-=_}y[f]+=g[f]+d,m[1-u]+=y[v]+y[c]/2-g[c]/2,y[c]=Math.max(y[c],g[c]),y[v]=Math.min(y[v],g[v]+m[1-u]),l.x=m[0],l.y=m[1],l.markRedraw()}return y},t.prototype._layoutContentAndController=function(e,i,n,a,o,s,l,u){var f=this.getContentGroup(),h=this._containerGroup,c=this._controllerGroup;ra(e.get("orient"),f,e.get("itemGap"),a?n.width:null,a?null:n.height),ra("horizontal",c,e.get("pageButtonItemGap",!0));var v=f.getBoundingRect(),d=c.getBoundingRect(),g=this._showController=v[o]>n[o],m=[-v.x,-v.y];i||(m[a]=f[u]);var p=[0,0],y=[-d.x,-d.y],_=$(e.get("pageButtonGap",!0),e.get("itemGap",!0));if(g){var S=e.get("pageButtonPosition",!0);S==="end"?y[a]+=n[o]-d[o]:p[a]+=d[o]+_}y[1-a]+=v[s]/2-d[s]/2,f.setPosition(m),h.setPosition(p),c.setPosition(y);var x={x:0,y:0};if(x[o]=g?n[o]:v[o],x[s]=Math.max(v[s],d[s]),x[l]=Math.min(0,d[l]+y[1-a]),h.__rectSize=n[o],g){var w={x:0,y:0};w[o]=Math.max(n[o]-d[o]-_,0),w[s]=x[s],h.setClipPath(new wt({shape:w})),h.__rectSize=w[o]}else c.eachChild(function(D){D.attr({invisible:!0,silent:!0})});var b=this._getPageInfo(e);return b.pageIndex!=null&&Ar(f,{x:b.contentPosition[0],y:b.contentPosition[1]},g?e:null),this._updatePageInfoView(e,b),x},t.prototype._pageGo=function(e,i,n){var a=this._getPageInfo(i)[e];a!=null&&n.dispatchAction({type:"legendScroll",scrollDataIndex:a,legendId:i.id})},t.prototype._updatePageInfoView=function(e,i){var n=this._controllerGroup;T(["pagePrev","pageNext"],function(f){var h=f+"DataIndex",c=i[h]!=null,v=n.childOfName(f);v&&(v.setStyle("fill",c?e.get("pageIconColor",!0):e.get("pageIconInactiveColor",!0)),v.cursor=c?"pointer":"default")});var a=n.childOfName("pageText"),o=e.get("pageFormatter"),s=i.pageIndex,l=s!=null?s+1:0,u=i.pageCount;a&&o&&a.setStyle("text",W(o)?o.replace("{current}",l==null?"":l+"").replace("{total}",u==null?"":u+""):o({current:l,total:u}))},t.prototype._getPageInfo=function(e){var i=e.get("scrollDataIndex",!0),n=this.getContentGroup(),a=this._containerGroup.__rectSize,o=e.getOrient().index,s=mu[o],l=yu[o],u=this._findTargetItemIndex(i),f=n.children(),h=f[u],c=f.length,v=c?1:0,d={contentPosition:[n.x,n.y],pageCount:v,pageIndex:v-1,pagePrevDataIndex:null,pageNextDataIndex:null};if(!h)return d;var g=S(h);d.contentPosition[o]=-g.s;for(var m=u+1,p=g,y=g,_=null;m<=c;++m)_=S(f[m]),(!_&&y.e>p.s+a||_&&!x(_,p.s))&&(y.i>p.i?p=y:p=_,p&&(d.pageNextDataIndex==null&&(d.pageNextDataIndex=p.i),++d.pageCount)),y=_;for(var m=u-1,p=g,y=g,_=null;m>=-1;--m)_=S(f[m]),(!_||!x(y,_.s))&&p.i<y.i&&(y=p,d.pagePrevDataIndex==null&&(d.pagePrevDataIndex=p.i),++d.pageCount,++d.pageIndex),p=_;return d;function S(w){if(w){var b=w.getBoundingRect(),D=b[l]+w[l];return{s:D,e:D+b[s],i:w.__legendDataIndex}}}function x(w,b){return w.e>=b&&w.s<=b+a}},t.prototype._findTargetItemIndex=function(e){if(!this._showController)return 0;var i,n=this.getContentGroup(),a;return n.eachChild(function(o,s){var l=o.__legendDataIndex;a==null&&l!=null&&(a=s),l===e&&(i=s)}),i??a},t.type="legend.scroll",t})(I0);function U2(r){r.registerAction("legendScroll","legendscroll",function(t,e){var i=t.scrollDataIndex;i!=null&&e.eachComponent({mainType:"legend",subType:"scroll",query:t},function(n){n.setScrollDataIndex(i)})})}function Y2(r){Ue(R0),r.registerComponentModel(V2),r.registerComponentView(W2),U2(r)}function Z2(r){Ue(R0),Ue(Y2)}var X2=(function(r){B(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.type="dataZoom.inside",t.defaultOption=yh(Ms.defaultOption,{disabled:!1,zoomLock:!1,zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0}),t})(Ms),Kh=yt();function q2(r,t,e){Kh(r).coordSysRecordMap.each(function(i){var n=i.dataZoomInfoMap.get(t.uid);n&&(n.getRange=e)})}function $2(r,t){for(var e=Kh(r).coordSysRecordMap,i=e.keys(),n=0;n<i.length;n++){var a=i[n],o=e.get(a),s=o.dataZoomInfoMap;if(s){var l=t.uid,u=s.get(l);u&&(s.removeKey(l),s.keys().length||E0(e,o))}}}function E0(r,t){if(t){r.removeKey(t.model.uid);var e=t.controller;e&&e.dispose()}}function K2(r,t){var e={model:t,containsPoint:Mt(J2,t),dispatchAction:Mt(Q2,r),dataZoomInfoMap:null,controller:null},i=e.controller=new jA(r.getZr());return T(["pan","zoom","scrollMove"],function(n){i.on(n,function(a){var o=[];e.dataZoomInfoMap.each(function(s){if(a.isAvailableBehavior(s.model.option)){var l=(s.getRange||{})[n],u=l&&l(s.dzReferCoordSysInfo,e.model.mainType,e.controller,a);!s.model.get("disabled",!0)&&u&&o.push({dataZoomId:s.model.id,start:u[0],end:u[1]})}}),o.length&&e.dispatchAction(o)})}),e}function Q2(r,t){r.isDisposed()||r.dispatchAction({type:"dataZoom",animation:{easing:"cubicOut",duration:100},batch:t})}function J2(r,t,e,i){return r.coordinateSystem.containPoint([e,i])}function j2(r,t,e){var i,n="type_",a={type_true:2,type_move:1,type_false:0,type_undefined:-1},o=!0;return r.each(function(s){var l=s.model,u=l.get("disabled",!0)?!1:l.get("zoomLock",!0)?"move":!0;a[n+u]>a[n+i]&&(i=u),o=o&&l.get("preventDefaultMouseMove",!0)}),{controlType:i,opt:{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!0,preventDefaultMouseMove:!!o,api:e,zInfo:{component:t.model},triggerInfo:{roamTrigger:null,isInSelf:t.containsPoint}}}}function tL(r){r.registerProcessor(r.PRIORITY.PROCESSOR.FILTER,function(t,e){var i=Kh(e),n=i.coordSysRecordMap||(i.coordSysRecordMap=Q());n.each(function(a){a.dataZoomInfoMap=null}),t.eachComponent({mainType:"dataZoom",subType:"inside"},function(a){var o=x0(a);T(o.infoList,function(s){var l=s.model.uid,u=n.get(l)||n.set(l,K2(e,s.model)),f=u.dataZoomInfoMap||(u.dataZoomInfoMap=Q());f.set(a.uid,{dzReferCoordSysInfo:s,model:a,getRange:null})})}),n.each(function(a){var o=a.controller,s,l=a.dataZoomInfoMap;if(l){var u=l.keys()[0];u!=null&&(s=l.get(u))}if(!s){E0(n,a);return}var f=j2(l,a,e);o.enable(f.controlType,f.opt),Qs(a,"dispatchAction",s.model.get("throttle",!0),"fixRate")})})}var eL=(function(r){B(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type="dataZoom.inside",e}return t.prototype.render=function(e,i,n){if(r.prototype.render.apply(this,arguments),e.noTarget()){this._clear();return}this.range=e.getPercentRange(),q2(n,e,{pan:q(_u.pan,this),zoom:q(_u.zoom,this),scrollMove:q(_u.scrollMove,this)})},t.prototype.dispose=function(){this._clear(),r.prototype.dispose.apply(this,arguments)},t.prototype._clear=function(){$2(this.api,this.dataZoomModel),this.range=null},t.type="dataZoom.inside",t})(b0),_u={zoom:function(r,t,e,i){var n=this.range,a=n.slice(),o=r.axisModels[0];if(o){var s=Su[t](null,[i.originX,i.originY],o,e,r),l=(s.signal>0?s.pixelStart+s.pixelLength-s.pixel:s.pixel-s.pixelStart)/s.pixelLength*(a[1]-a[0])+a[0],u=Math.max(1/i.scale,0);a[0]=(a[0]-l)*u+l,a[1]=(a[1]-l)*u+l;var f=this.dataZoomModel.findRepresentativeAxisProxy().getMinMaxSpan();if(Da(0,a,[0,100],0,f.minSpan,f.maxSpan),this.range=a,n[0]!==a[0]||n[1]!==a[1])return a}},pan:kp(function(r,t,e,i,n,a){var o=Su[i]([a.oldX,a.oldY],[a.newX,a.newY],t,n,e);return o.signal*(r[1]-r[0])*o.pixel/o.pixelLength}),scrollMove:kp(function(r,t,e,i,n,a){var o=Su[i]([0,0],[a.scrollDelta,a.scrollDelta],t,n,e);return o.signal*(r[1]-r[0])*a.scrollDelta})};function kp(r){return function(t,e,i,n){var a=this.range,o=a.slice(),s=t.axisModels[0];if(s){var l=r(o,s,t,e,i,n);if(Da(l,o,[0,100],"all"),this.range=o,a[0]!==o[0]||a[1]!==o[1])return o}}}var Su={grid:function(r,t,e,i,n){var a=e.axis,o={},s=n.model.coordinateSystem.getRect();return r=r||[0,0],a.dim==="x"?(o.pixel=t[0]-r[0],o.pixelLength=s.width,o.pixelStart=s.x,o.signal=a.inverse?1:-1):(o.pixel=t[1]-r[1],o.pixelLength=s.height,o.pixelStart=s.y,o.signal=a.inverse?-1:1),o},polar:function(r,t,e,i,n){var a=e.axis,o={},s=n.model.coordinateSystem,l=s.getRadiusAxis().getExtent(),u=s.getAngleAxis().getExtent();return r=r?s.pointToCoord(r):[0,0],t=s.pointToCoord(t),e.mainType==="radiusAxis"?(o.pixel=t[0]-r[0],o.pixelLength=l[1]-l[0],o.pixelStart=l[0],o.signal=a.inverse?1:-1):(o.pixel=t[1]-r[1],o.pixelLength=u[1]-u[0],o.pixelStart=u[0],o.signal=a.inverse?-1:1),o},singleAxis:function(r,t,e,i,n){var a=e.axis,o=n.model.coordinateSystem.getRect(),s={};return r=r||[0,0],a.orient==="horizontal"?(s.pixel=t[0]-r[0],s.pixelLength=o.width,s.pixelStart=o.x,s.signal=a.inverse?1:-1):(s.pixel=t[1]-r[1],s.pixelLength=o.height,s.pixelStart=o.y,s.signal=a.inverse?-1:1),s}};function rL(r){T0(r),r.registerComponentModel(X2),r.registerComponentView(eL),tL(r)}var iL=(function(r){B(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.type="dataZoom.slider",t.layoutMode="box",t.defaultOption=yh(Ms.defaultOption,{show:!0,right:"ph",top:"ph",width:"ph",height:"ph",left:null,bottom:null,borderColor:H.color.accent10,borderRadius:0,backgroundColor:H.color.transparent,dataBackground:{lineStyle:{color:H.color.accent30,width:.5},areaStyle:{color:H.color.accent20,opacity:.2}},selectedDataBackground:{lineStyle:{color:H.color.accent40,width:.5},areaStyle:{color:H.color.accent20,opacity:.3}},fillerColor:"rgba(135,175,274,0.2)",handleIcon:"path://M-9.35,34.56V42m0-40V9.5m-2,0h4a2,2,0,0,1,2,2v21a2,2,0,0,1-2,2h-4a2,2,0,0,1-2-2v-21A2,2,0,0,1-11.35,9.5Z",handleSize:"100%",handleStyle:{color:H.color.neutral00,borderColor:H.color.accent20},moveHandleSize:7,moveHandleIcon:"path://M-320.9-50L-320.9-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-348-41-339-50-320.9-50z M-212.3-50L-212.3-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-239.4-41-230.4-50-212.3-50z M-103.7-50L-103.7-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-130.9-41-121.8-50-103.7-50z",moveHandleStyle:{color:H.color.accent40,opacity:.5},showDetail:!0,showDataShadow:"auto",realtime:!0,zoomLock:!1,textStyle:{color:H.color.tertiary},brushSelect:!0,brushStyle:{color:H.color.accent30,opacity:.3},emphasis:{handleLabel:{show:!0},handleStyle:{borderColor:H.color.accent40},moveHandleStyle:{opacity:.8}},defaultLocationEdgeGap:15}),t})(Ms),Nn=wt,nL=1,wu=30,aL=7,Fn="horizontal",Op="vertical",oL=5,sL=["line","bar","candlestick","scatter"],lL={easing:"cubicOut",duration:100,delay:0},uL=(function(r){B(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e._displayables={},e}return t.prototype.init=function(e,i){this.api=i,this._onBrush=q(this._onBrush,this),this._onBrushEnd=q(this._onBrushEnd,this)},t.prototype.render=function(e,i,n,a){if(r.prototype.render.apply(this,arguments),Qs(this,"_dispatchZoomAction",e.get("throttle"),"fixRate"),this._orient=e.getOrient(),e.get("show")===!1){this.group.removeAll();return}if(e.noTarget()){this._clear(),this.group.removeAll();return}(!a||a.type!=="dataZoom"||a.from!==this.uid)&&this._buildView(),this._updateView()},t.prototype.dispose=function(){this._clear(),r.prototype.dispose.apply(this,arguments)},t.prototype._clear=function(){cs(this,"_dispatchZoomAction");var e=this.api.getZr();e.off("mousemove",this._onBrush),e.off("mouseup",this._onBrushEnd)},t.prototype._buildView=function(){var e=this.group;e.removeAll(),this._brushing=!1,this._displayables.brushRect=null,this._resetLocation(),this._resetInterval();var i=this._displayables.sliderGroup=new Dt;this._renderBackground(),this._renderHandle(),this._renderDataShadow(),e.add(i),this._positionGroup()},t.prototype._resetLocation=function(){var e=this.dataZoomModel,i=this.api,n=e.get("brushSelect"),a=n?aL:0,o=qs(e,i).refContainer,s=this._findCoordRect(),l=e.get("defaultLocationEdgeGap",!0)||0,u=this._orient===Fn?{right:o.width-s.x-s.width,top:o.height-wu-l-a,width:s.width,height:wu}:{right:l,top:s.y,width:wu,height:s.height},f=pn(e.option);T(["right","top","width","height"],function(c){f[c]==="ph"&&(f[c]=u[c])});var h=Ti(f,o);this._location={x:h.x,y:h.y},this._size=[h.width,h.height],this._orient===Op&&this._size.reverse()},t.prototype._positionGroup=function(){var e=this.group,i=this._location,n=this._orient,a=this.dataZoomModel.getFirstTargetAxisModel(),o=a&&a.get("inverse"),s=this._displayables.sliderGroup,l=(this._dataShadowInfo||{}).otherAxisInverse;s.attr(n===Fn&&!o?{scaleY:l?1:-1,scaleX:1}:n===Fn&&o?{scaleY:l?1:-1,scaleX:-1}:n===Op&&!o?{scaleY:l?-1:1,scaleX:1,rotation:Math.PI/2}:{scaleY:l?-1:1,scaleX:-1,rotation:Math.PI/2});var u=e.getBoundingRect([s]);e.x=i.x-u.x,e.y=i.y-u.y,e.markRedraw()},t.prototype._getViewExtent=function(){return[0,this._size[0]]},t.prototype._renderBackground=function(){var e=this.dataZoomModel,i=this._size,n=this._displayables.sliderGroup,a=e.get("brushSelect");n.add(new Nn({silent:!0,shape:{x:0,y:0,width:i[0],height:i[1]},style:{fill:e.get("backgroundColor")},z2:-40}));var o=new Nn({shape:{x:0,y:0,width:i[0],height:i[1]},style:{fill:"transparent"},z2:0,onclick:q(this._onClickPanel,this)}),s=this.api.getZr();a?(o.on("mousedown",this._onBrushStart,this),o.cursor="crosshair",s.on("mousemove",this._onBrush),s.on("mouseup",this._onBrushEnd)):(s.off("mousemove",this._onBrush),s.off("mouseup",this._onBrushEnd)),n.add(o)},t.prototype._renderDataShadow=function(){var e=this._dataShadowInfo=this._prepareDataShadowInfo();if(this._displayables.dataShadowSegs=[],!e)return;var i=this._size,n=this._shadowSize||[],a=e.series,o=a.getRawData(),s=a.getShadowDim&&a.getShadowDim(),l=s&&o.getDimensionInfo(s)?a.getShadowDim():e.otherDim;if(l==null)return;var u=this._shadowPolygonPts,f=this._shadowPolylinePts;if(o!==this._shadowData||l!==this._shadowDim||i[0]!==n[0]||i[1]!==n[1]){var h=o.getDataExtent(e.thisDim),c=o.getDataExtent(l),v=(c[1]-c[0])*.3;c=[c[0]-v,c[1]+v];var d=[0,i[1]],g=[0,i[0]],m=[[i[0],0],[0,0]],p=[],y=g[1]/Math.max(1,o.count()-1),_=i[0]/(h[1]-h[0]),S=e.thisAxis.type==="time",x=-y,w=Math.round(o.count()/i[0]),b;o.each([e.thisDim,l],function(P,L,I){if(w>0&&I%w){S||(x+=y);return}x=S?(+P-h[0])*_:x+y;var E=L==null||isNaN(L)||L==="",k=E?0:Pt(L,c,d,!0);E&&!b&&I?(m.push([m[m.length-1][0],0]),p.push([p[p.length-1][0],0])):!E&&b&&(m.push([x,0]),p.push([x,0])),E||(m.push([x,k]),p.push([x,k])),b=E}),u=this._shadowPolygonPts=m,f=this._shadowPolylinePts=p}this._shadowData=o,this._shadowDim=l,this._shadowSize=[i[0],i[1]];var D=this.dataZoomModel;function C(P){var L=D.getModel(P?"selectedDataBackground":"dataBackground"),I=new Dt,E=new Hs({shape:{points:u},segmentIgnoreThreshold:1,style:L.getModel("areaStyle").getAreaStyle(),silent:!0,z2:-20}),k=new Gs({shape:{points:f},segmentIgnoreThreshold:1,style:L.getModel("lineStyle").getLineStyle(),silent:!0,z2:-19});return I.add(E),I.add(k),I}for(var M=0;M<3;M++){var A=C(M===1);this._displayables.sliderGroup.add(A),this._displayables.dataShadowSegs.push(A)}},t.prototype._prepareDataShadowInfo=function(){var e=this.dataZoomModel,i=e.get("showDataShadow");if(i!==!1){var n,a=this.ecModel;return e.eachTargetAxis(function(o,s){var l=e.getAxisProxy(o,s).getTargetSeriesModels();T(l,function(u){if(!n&&!(i!==!0&&at(sL,u.get("type"))<0)){var f=a.getComponent(wr(o),s).axis,h=fL(o),c,v=u.coordinateSystem;h!=null&&v.getOtherAxis&&(c=v.getOtherAxis(f).inverse),h=u.getData().mapDimension(h);var d=u.getData().mapDimension(o);n={thisAxis:f,series:u,thisDim:d,otherDim:h,otherAxisInverse:c}}},this)},this),n}},t.prototype._renderHandle=function(){var e=this.group,i=this._displayables,n=i.handles=[null,null],a=i.handleLabels=[null,null],o=this._displayables.sliderGroup,s=this._size,l=this.dataZoomModel,u=this.api,f=l.get("borderRadius")||0,h=l.get("brushSelect"),c=i.filler=new Nn({silent:h,style:{fill:l.get("fillerColor")},textConfig:{position:"inside"}});o.add(c),o.add(new Nn({silent:!0,subPixelOptimize:!0,shape:{x:0,y:0,width:s[0],height:s[1],r:f},style:{stroke:l.get("dataBackgroundColor")||l.get("borderColor"),lineWidth:nL,fill:H.color.transparent}})),T([0,1],function(_){var S=l.get("handleIcon");!ps[S]&&S.indexOf("path://")<0&&S.indexOf("image://")<0&&(S="path://"+S);var x=Pr(S,-1,0,2,2,null,!0);x.attr({cursor:hL(this._orient),draggable:!0,drift:q(this._onDragMove,this,_),ondragend:q(this._onDragEnd,this),onmouseover:q(this._showDataInfo,this,!0),onmouseout:q(this._showDataInfo,this,!1),z2:5});var w=x.getBoundingRect(),b=l.get("handleSize");this._handleHeight=Ot(b,this._size[1]),this._handleWidth=w.width/w.height*this._handleHeight,x.setStyle(l.getModel("handleStyle").getItemStyle()),x.style.strokeNoScale=!0,x.rectHover=!0,x.ensureState("emphasis").style=l.getModel(["emphasis","handleStyle"]).getItemStyle(),os(x);var D=l.get("handleColor");D!=null&&(x.style.fill=D),o.add(n[_]=x);var C=l.getModel("textStyle"),M=l.get("handleLabel")||{},A=M.show||!1;e.add(a[_]=new Nt({silent:!0,invisible:!A,style:ar(C,{x:0,y:0,text:"",verticalAlign:"middle",align:"center",fill:C.getTextColor(),font:C.getFont()}),z2:10}))},this);var v=c;if(h){var d=Ot(l.get("moveHandleSize"),s[1]),g=i.moveHandle=new wt({style:l.getModel("moveHandleStyle").getItemStyle(),silent:!0,shape:{r:[0,0,2,2],y:s[1]-.5,height:d}}),m=d*.8,p=i.moveHandleIcon=Pr(l.get("moveHandleIcon"),-m/2,-m/2,m,m,H.color.neutral00,!0);p.silent=!0,p.y=s[1]+d/2-.5,g.ensureState("emphasis").style=l.getModel(["emphasis","moveHandleStyle"]).getItemStyle();var y=Math.min(s[1]/2,Math.max(d,10));v=i.moveZone=new wt({invisible:!0,shape:{y:s[1]-y,height:d+y}}),v.on("mouseover",function(){u.enterEmphasis(g)}).on("mouseout",function(){u.leaveEmphasis(g)}),o.add(g),o.add(p),o.add(v)}v.attr({draggable:!0,cursor:"default",drift:q(this._onDragMove,this,"all"),ondragstart:q(this._showDataInfo,this,!0),ondragend:q(this._onDragEnd,this),onmouseover:q(this._showDataInfo,this,!0),onmouseout:q(this._showDataInfo,this,!1)})},t.prototype._resetInterval=function(){var e=this._range=this.dataZoomModel.getPercentRange(),i=this._getViewExtent();this._handleEnds=[Pt(e[0],[0,100],i,!0),Pt(e[1],[0,100],i,!0)]},t.prototype._updateInterval=function(e,i){var n=this.dataZoomModel,a=this._handleEnds,o=this._getViewExtent(),s=n.findRepresentativeAxisProxy().getMinMaxSpan(),l=[0,100];Da(i,a,o,n.get("zoomLock")?"all":e,s.minSpan!=null?Pt(s.minSpan,l,o,!0):null,s.maxSpan!=null?Pt(s.maxSpan,l,o,!0):null);var u=this._range,f=this._range=Vn([Pt(a[0],o,l,!0),Pt(a[1],o,l,!0)]);return!u||u[0]!==f[0]||u[1]!==f[1]},t.prototype._updateView=function(e){var i=this._displayables,n=this._handleEnds,a=Vn(n.slice()),o=this._size;T([0,1],function(v){var d=i.handles[v],g=this._handleHeight;d.attr({scaleX:g/2,scaleY:g/2,x:n[v]+(v?-1:1),y:o[1]/2-g/2})},this),i.filler.setShape({x:a[0],y:0,width:a[1]-a[0],height:o[1]});var s={x:a[0],width:a[1]-a[0]};i.moveHandle&&(i.moveHandle.setShape(s),i.moveZone.setShape(s),i.moveZone.getBoundingRect(),i.moveHandleIcon&&i.moveHandleIcon.attr("x",s.x+s.width/2));for(var l=i.dataShadowSegs,u=[0,a[0],a[1],o[0]],f=0;f<l.length;f++){var h=l[f],c=h.getClipPath();c||(c=new wt,h.setClipPath(c)),c.setShape({x:u[f],y:0,width:u[f+1]-u[f],height:o[1]})}this._updateDataInfo(e)},t.prototype._updateDataInfo=function(e){var i=this.dataZoomModel,n=this._displayables,a=n.handleLabels,o=this._orient,s=["",""];if(i.get("showDetail")){var l=i.findRepresentativeAxisProxy();if(l){var u=l.getAxisModel().axis,f=this._range,h=e?l.calculateDataWindow({start:f[0],end:f[1]}).valueWindow:l.getDataValueWindow();s=[this._formatLabel(h[0],u),this._formatLabel(h[1],u)]}}var c=Vn(this._handleEnds.slice());v.call(this,0),v.call(this,1);function v(d){var g=am(n.handles[d].parent,this.group),m=om(d===0?"right":"left",g),p=this._handleWidth/2+oL,y=da([c[d]+(d===0?-p:p),this._size[1]/2],g);a[d].setStyle({x:y[0],y:y[1],verticalAlign:o===Fn?"middle":m,align:o===Fn?m:"center",text:s[d]})}},t.prototype._formatLabel=function(e,i){var n=this.dataZoomModel,a=n.get("labelFormatter"),o=n.get("labelPrecision");(o==null||o==="auto")&&(o=i.getPixelPrecision());var s=e==null||isNaN(e)?"":i.type==="category"||i.type==="time"?i.scale.getLabel({value:Math.round(e)}):e.toFixed(Math.min(o,20));return J(a)?a(e,s):W(a)?a.replace("{value}",s):s},t.prototype._showDataInfo=function(e){var i=this.dataZoomModel.get("handleLabel")||{},n=i.show||!1,a=this.dataZoomModel.getModel(["emphasis","handleLabel"]),o=a.get("show")||!1,s=e||this._dragging?o:n,l=this._displayables,u=l.handleLabels;u[0].attr("invisible",!s),u[1].attr("invisible",!s),l.moveHandle&&this.api[s?"enterEmphasis":"leaveEmphasis"](l.moveHandle,1)},t.prototype._onDragMove=function(e,i,n,a){this._dragging=!0,on(a.event);var o=this._displayables.sliderGroup.getLocalTransform(),s=da([i,n],o,!0),l=this._updateInterval(e,s[0]),u=this.dataZoomModel.get("realtime");this._updateView(!u),l&&u&&this._dispatchZoomAction(!0)},t.prototype._onDragEnd=function(){this._dragging=!1,this._showDataInfo(!1);var e=this.dataZoomModel.get("realtime");!e&&this._dispatchZoomAction(!1)},t.prototype._onClickPanel=function(e){var i=this._size,n=this._displayables.sliderGroup.transformCoordToLocal(e.offsetX,e.offsetY);if(!(n[0]<0||n[0]>i[0]||n[1]<0||n[1]>i[1])){var a=this._handleEnds,o=(a[0]+a[1])/2,s=this._updateInterval("all",n[0]-o);this._updateView(),s&&this._dispatchZoomAction(!1)}},t.prototype._onBrushStart=function(e){var i=e.offsetX,n=e.offsetY;this._brushStart=new vt(i,n),this._brushing=!0,this._brushStartTime=+new Date},t.prototype._onBrushEnd=function(e){if(this._brushing){var i=this._displayables.brushRect;if(this._brushing=!1,!!i){i.attr("ignore",!0);var n=i.shape,a=+new Date;if(!(a-this._brushStartTime<200&&Math.abs(n.width)<5)){var o=this._getViewExtent(),s=[0,100],l=this._handleEnds=[n.x,n.x+n.width],u=this.dataZoomModel.findRepresentativeAxisProxy().getMinMaxSpan();Da(0,l,o,0,u.minSpan!=null?Pt(u.minSpan,s,o,!0):null,u.maxSpan!=null?Pt(u.maxSpan,s,o,!0):null),this._range=Vn([Pt(l[0],o,s,!0),Pt(l[1],o,s,!0)]),this._updateView(),this._dispatchZoomAction(!1)}}}},t.prototype._onBrush=function(e){this._brushing&&(on(e.event),this._updateBrushRect(e.offsetX,e.offsetY))},t.prototype._updateBrushRect=function(e,i){var n=this._displayables,a=this.dataZoomModel,o=n.brushRect;o||(o=n.brushRect=new Nn({silent:!0,style:a.getModel("brushStyle").getItemStyle()}),n.sliderGroup.add(o)),o.attr("ignore",!1);var s=this._brushStart,l=this._displayables.sliderGroup,u=l.transformCoordToLocal(e,i),f=l.transformCoordToLocal(s.x,s.y),h=this._size;u[0]=Math.max(Math.min(h[0],u[0]),0),o.setShape({x:f[0],y:0,width:u[0]-f[0],height:h[1]})},t.prototype._dispatchZoomAction=function(e){var i=this._range;this.api.dispatchAction({type:"dataZoom",from:this.uid,dataZoomId:this.dataZoomModel.id,animation:e?lL:null,start:i[0],end:i[1]})},t.prototype._findCoordRect=function(){var e,i=x0(this.dataZoomModel).infoList;if(!e&&i.length){var n=i[0].model.coordinateSystem;e=n.getRect&&n.getRect()}if(!e){var a=this.api.getWidth(),o=this.api.getHeight();e={x:a*.2,y:o*.2,width:a*.6,height:o*.6}}return e},t.type="dataZoom.slider",t})(b0);function fL(r){var t={x:"y",y:"x",radius:"angle",angle:"radius"};return t[r]}function hL(r){return r==="vertical"?"ns-resize":"ew-resize"}function vL(r){r.registerComponentModel(iL),r.registerComponentView(uL),T0(r)}function cL(r){Ue(rL),Ue(vL)}var dL=(function(r){B(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e.hasSymbolVisual=!0,e}return t.prototype.getInitialData=function(e){return DM(null,this,{useEncodeDefaulter:!0})},t.prototype.getLegendIcon=function(e){var i=new Dt,n=Pr("line",0,e.itemHeight/2,e.itemWidth,0,e.lineStyle.stroke,!1);i.add(n),n.setStyle(e.lineStyle);var a=this.getData().getVisual("symbol"),o=this.getData().getVisual("symbolRotate"),s=a==="none"?"circle":a,l=e.itemHeight*.8,u=Pr(s,(e.itemWidth-l)/2,(e.itemHeight-l)/2,l,l,e.itemStyle.fill);i.add(u),u.setStyle(e.itemStyle);var f=e.iconRotate==="inherit"?o:e.iconRotate||0;return u.rotation=f*Math.PI/180,u.setOrigin([e.itemWidth/2,e.itemHeight/2]),s.indexOf("empty")>-1&&(u.style.stroke=u.style.fill,u.style.fill=H.color.neutral00,u.style.lineWidth=2),i},t.type="series.line",t.dependencies=["grid","polar"],t.defaultOption={z:3,coordinateSystem:"cartesian2d",legendHoverLink:!0,clip:!0,label:{position:"top"},endLabel:{show:!1,valueAnimation:!0,distance:8},lineStyle:{width:2,type:"solid"},emphasis:{scale:!0},step:!1,smooth:!1,smoothMonotone:null,symbol:"emptyCircle",symbolSize:6,symbolRotate:null,showSymbol:!0,showAllSymbol:"auto",connectNulls:!1,sampling:"none",animationEasing:"linear",progressive:0,hoverLayerThreshold:1/0,universalTransition:{divideShape:"clone"},triggerLineEvent:!1},t})(Ir);function k0(r,t,e){var i=r.getBaseAxis(),n=r.getOtherAxis(i),a=pL(n,e),o=i.dim,s=n.dim,l=t.mapDimension(s),u=t.mapDimension(o),f=s==="x"||s==="radius"?1:0,h=K(r.dimensions,function(d){return t.mapDimension(d)}),c=!1,v=t.getCalculationInfo("stackResultDimension");return xa(t,h[0])&&(c=!0,h[0]=v),xa(t,h[1])&&(c=!0,h[1]=v),{dataDimsForPoint:h,valueStart:a,valueAxisDim:s,baseAxisDim:o,stacked:!!c,valueDim:l,baseDim:u,baseDataOffset:f,stackedOverDimension:t.getCalculationInfo("stackedOverDimension")}}function pL(r,t){var e=0,i=r.scale.getExtent();return t==="start"?e=i[0]:t==="end"?e=i[1]:mt(t)&&!isNaN(t)?e=t:i[0]>0?e=i[0]:i[1]<0&&(e=i[1]),e}function O0(r,t,e,i){var n=NaN;r.stacked&&(n=e.get(e.getCalculationInfo("stackedOverDimension"),i)),isNaN(n)&&(n=r.valueStart);var a=r.baseDataOffset,o=[];return o[a]=e.get(r.baseDim,i),o[1-a]=n,t.dataToPoint(o)}function gL(r,t){var e=[];return t.diff(r).add(function(i){e.push({cmd:"+",idx:i})}).update(function(i,n){e.push({cmd:"=",idx:n,idx1:i})}).remove(function(i){e.push({cmd:"-",idx:i})}).execute(),e}function mL(r,t,e,i,n,a,o,s){for(var l=gL(r,t),u=[],f=[],h=[],c=[],v=[],d=[],g=[],m=k0(n,t,o),p=r.getLayout("points")||[],y=t.getLayout("points")||[],_=0;_<l.length;_++){var S=l[_],x=!0,w=void 0,b=void 0;switch(S.cmd){case"=":w=S.idx*2,b=S.idx1*2;var D=p[w],C=p[w+1],M=y[b],A=y[b+1];(isNaN(D)||isNaN(C))&&(D=M,C=A),u.push(D,C),f.push(M,A),h.push(e[w],e[w+1]),c.push(i[b],i[b+1]),g.push(t.getRawIndex(S.idx1));break;case"+":var P=S.idx,L=m.dataDimsForPoint,I=n.dataToPoint([t.get(L[0],P),t.get(L[1],P)]);b=P*2,u.push(I[0],I[1]),f.push(y[b],y[b+1]);var E=O0(m,n,t,P);h.push(E[0],E[1]),c.push(i[b],i[b+1]),g.push(t.getRawIndex(P));break;case"-":x=!1}x&&(v.push(S),d.push(d.length))}d.sort(function(_t,Zt){return g[_t]-g[Zt]});for(var k=u.length,U=tn(k),z=tn(k),R=tn(k),F=tn(k),G=[],_=0;_<d.length;_++){var X=d[_],tt=_*2,ot=X*2;U[tt]=u[ot],U[tt+1]=u[ot+1],z[tt]=f[ot],z[tt+1]=f[ot+1],R[tt]=h[ot],R[tt+1]=h[ot+1],F[tt]=c[ot],F[tt+1]=c[ot+1],G[_]=v[X]}return{current:U,next:z,stackedOnCurrent:R,stackedOnNext:F,status:G}}var dr=Math.min,pr=Math.max;function _i(r,t){return isNaN(r)||isNaN(t)}function zf(r,t,e,i,n,a,o,s,l){for(var u,f,h,c,v,d,g=e,m=0;m<i;m++){var p=t[g*2],y=t[g*2+1];if(g>=n||g<0)break;if(_i(p,y)){if(l){g+=a;continue}break}if(g===e)r[a>0?"moveTo":"lineTo"](p,y),h=p,c=y;else{var _=p-u,S=y-f;if(_*_+S*S<.5){g+=a;continue}if(o>0){for(var x=g+a,w=t[x*2],b=t[x*2+1];w===p&&b===y&&m<i;)m++,x+=a,g+=a,w=t[x*2],b=t[x*2+1],p=t[g*2],y=t[g*2+1],_=p-u,S=y-f;var D=m+1;if(l)for(;_i(w,b)&&D<i;)D++,x+=a,w=t[x*2],b=t[x*2+1];var C=.5,M=0,A=0,P=void 0,L=void 0;if(D>=i||_i(w,b))v=p,d=y;else{M=w-u,A=b-f;var I=p-u,E=w-p,k=y-f,U=b-y,z=void 0,R=void 0;if(s==="x"){z=Math.abs(I),R=Math.abs(E);var F=M>0?1:-1;v=p-F*z*o,d=y,P=p+F*R*o,L=y}else if(s==="y"){z=Math.abs(k),R=Math.abs(U);var G=A>0?1:-1;v=p,d=y-G*z*o,P=p,L=y+G*R*o}else z=Math.sqrt(I*I+k*k),R=Math.sqrt(E*E+U*U),C=R/(R+z),v=p-M*o*(1-C),d=y-A*o*(1-C),P=p+M*o*C,L=y+A*o*C,P=dr(P,pr(w,p)),L=dr(L,pr(b,y)),P=pr(P,dr(w,p)),L=pr(L,dr(b,y)),M=P-p,A=L-y,v=p-M*z/R,d=y-A*z/R,v=dr(v,pr(u,p)),d=dr(d,pr(f,y)),v=pr(v,dr(u,p)),d=pr(d,dr(f,y)),M=p-v,A=y-d,P=p+M*R/z,L=y+A*R/z}r.bezierCurveTo(h,c,v,d,p,y),h=P,c=L}else r.lineTo(p,y)}u=p,f=y,g+=a}return m}var B0=(function(){function r(){this.smooth=0,this.smoothConstraint=!0}return r})(),yL=(function(r){B(t,r);function t(e){var i=r.call(this,e)||this;return i.type="ec-polyline",i}return t.prototype.getDefaultStyle=function(){return{stroke:H.color.neutral99,fill:null}},t.prototype.getDefaultShape=function(){return new B0},t.prototype.buildPath=function(e,i){var n=i.points,a=0,o=n.length/2;if(i.connectNulls){for(;o>0&&_i(n[o*2-2],n[o*2-1]);o--);for(;a<o&&_i(n[a*2],n[a*2+1]);a++);}for(;a<o;)a+=zf(e,n,a,o,o,1,i.smooth,i.smoothMonotone,i.connectNulls)+1},t.prototype.getPointOn=function(e,i){this.path||(this.createPathProxy(),this.buildPath(this.path,this.shape));for(var n=this.path,a=n.data,o=xi.CMD,s,l,u=i==="x",f=[],h=0;h<a.length;){var c=a[h++],v=void 0,d=void 0,g=void 0,m=void 0,p=void 0,y=void 0,_=void 0;switch(c){case o.M:s=a[h++],l=a[h++];break;case o.L:if(v=a[h++],d=a[h++],_=u?(e-s)/(v-s):(e-l)/(d-l),_<=1&&_>=0){var S=u?(d-l)*_+l:(v-s)*_+s;return u?[e,S]:[S,e]}s=v,l=d;break;case o.C:v=a[h++],d=a[h++],g=a[h++],m=a[h++],p=a[h++],y=a[h++];var x=u?qo(s,v,g,p,e,f):qo(l,d,m,y,e,f);if(x>0)for(var w=0;w<x;w++){var b=f[w];if(b<=1&&b>=0){var S=u?kt(l,d,m,y,b):kt(s,v,g,p,b);return u?[e,S]:[S,e]}}s=p,l=y;break}}},t})(dt),_L=(function(r){B(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t})(B0),SL=(function(r){B(t,r);function t(e){var i=r.call(this,e)||this;return i.type="ec-polygon",i}return t.prototype.getDefaultShape=function(){return new _L},t.prototype.buildPath=function(e,i){var n=i.points,a=i.stackedOnPoints,o=0,s=n.length/2,l=i.smoothMonotone;if(i.connectNulls){for(;s>0&&_i(n[s*2-2],n[s*2-1]);s--);for(;o<s&&_i(n[o*2],n[o*2+1]);o++);}for(;o<s;){var u=zf(e,n,o,s,s,1,i.smooth,l,i.connectNulls);zf(e,a,o+u-1,u,s,-1,i.stackedOnSmooth,l,i.connectNulls),o+=u+1,e.closePath()}},t})(dt);function wL(r,t,e,i,n){var a=r.getArea(),o=a.x,s=a.y,l=a.width,u=a.height,f=e.get(["lineStyle","width"])||0;o-=f/2,s-=f/2,l+=f,u+=f,l=Math.ceil(l),o!==Math.floor(o)&&(o=Math.floor(o),l++);var h=new wt({shape:{x:o,y:s,width:l,height:u}});if(t){var c=r.getBaseAxis(),v=c.isHorizontal(),d=c.inverse;v?(d&&(h.shape.x+=l),h.shape.width=0):(d||(h.shape.y+=u),h.shape.height=0);var g=J(n)?function(m){n(m,h)}:null;ka(h,{shape:{width:l,height:u,x:o,y:s}},e,null,i,g)}return h}function xL(r,t,e){var i=r.getArea(),n=Bt(i.r0,1),a=Bt(i.r,1),o=new zs({shape:{cx:Bt(r.cx,1),cy:Bt(r.cy,1),r0:n,r:a,startAngle:i.startAngle,endAngle:i.endAngle,clockwise:i.clockwise}});if(t){var s=r.getBaseAxis().dim==="angle";s?o.shape.endAngle=i.startAngle:o.shape.r=n,ka(o,{shape:{endAngle:i.endAngle,r:a}},e)}return o}function Bp(r,t){if(r.length===t.length){for(var e=0;e<r.length;e++)if(r[e]!==t[e])return;return!0}}function Np(r){for(var t=1/0,e=1/0,i=-1/0,n=-1/0,a=0;a<r.length;){var o=r[a++],s=r[a++];isNaN(o)||(t=Math.min(o,t),i=Math.max(o,i)),isNaN(s)||(e=Math.min(s,e),n=Math.max(s,n))}return[[t,e],[i,n]]}function Fp(r,t){var e=Np(r),i=e[0],n=e[1],a=Np(t),o=a[0],s=a[1];return Math.max(Math.abs(i[0]-o[0]),Math.abs(i[1]-o[1]),Math.abs(n[0]-s[0]),Math.abs(n[1]-s[1]))}function zp(r){return mt(r)?r:r?.5:0}function bL(r,t,e){if(!e.valueDim)return[];for(var i=t.count(),n=tn(i*2),a=0;a<i;a++){var o=O0(e,r,t,a);n[a*2]=o[0],n[a*2+1]=o[1]}return n}function gr(r,t,e,i,n){var a=e.getBaseAxis(),o=a.dim==="x"||a.dim==="radius"?0:1,s=[],l=0,u=[],f=[],h=[],c=[];if(n){for(l=0;l<r.length;l+=2){var v=t||r;!isNaN(v[l])&&!isNaN(v[l+1])&&c.push(r[l],r[l+1])}r=c}for(l=0;l<r.length-2;l+=2)switch(h[0]=r[l+2],h[1]=r[l+3],f[0]=r[l],f[1]=r[l+1],s.push(f[0],f[1]),i){case"end":u[o]=h[o],u[1-o]=f[1-o],s.push(u[0],u[1]);break;case"middle":var d=(f[o]+h[o])/2,g=[];u[o]=g[o]=d,u[1-o]=f[1-o],g[1-o]=h[1-o],s.push(u[0],u[1]),s.push(g[0],g[1]);break;default:u[o]=f[o],u[1-o]=h[1-o],s.push(u[0],u[1])}return s.push(r[l++],r[l++]),s}function TL(r,t){var e=[],i=r.length,n,a;function o(f,h,c){var v=f.coord,d=(c-v)/(h.coord-v),g=g1(d,[f.color,h.color]);return{coord:c,color:g}}for(var s=0;s<i;s++){var l=r[s],u=l.coord;if(u<0)n=l;else if(u>t){a?e.push(o(a,l,t)):n&&e.push(o(n,l,0),o(n,l,t));break}else n&&(e.push(o(n,l,0)),n=null),e.push(l),a=l}return e}function CL(r,t,e){var i=r.getVisual("visualMeta");if(!(!i||!i.length||!r.count())&&t.type==="cartesian2d"){for(var n,a,o=i.length-1;o>=0;o--){var s=r.getDimensionInfo(i[o].dimension);if(n=s&&s.coordDim,n==="x"||n==="y"){a=i[o];break}}if(a){var l=t.getAxis(n),u=K(a.stops,function(_){return{coord:l.toGlobalCoord(l.dataToCoord(_.value)),color:_.color}}),f=u.length,h=a.outerColors.slice();f&&u[0].coord>u[f-1].coord&&(u.reverse(),h.reverse());var c=TL(u,n==="x"?e.getWidth():e.getHeight()),v=c.length;if(!v&&f)return u[0].coord<0?h[1]?h[1]:u[f-1].color:h[0]?h[0]:u[0].color;var d=10,g=c[0].coord-d,m=c[v-1].coord+d,p=m-g;if(p<.001)return"transparent";T(c,function(_){_.offset=(_.coord-g)/p}),c.push({offset:v?c[v-1].offset:.5,color:h[1]||"transparent"}),c.unshift({offset:v?c[0].offset:.5,color:h[0]||"transparent"});var y=new tm(0,0,0,0,c,!0);return y[n]=g,y[n+"2"]=m,y}}}function ML(r,t,e){var i=r.get("showAllSymbol"),n=i==="auto";if(!(i&&!n)){var a=e.getAxesByScale("ordinal")[0];if(a&&!(n&&DL(a,t))){var o=t.mapDimension(a.dim),s={};return T(a.getViewLabels(),function(l){var u=a.scale.getRawOrdinalNumber(l.tickValue);s[u]=1}),function(l){return!s.hasOwnProperty(t.get(o,l))}}}}function DL(r,t){var e=r.getExtent(),i=Math.abs(e[1]-e[0])/r.scale.count();isNaN(i)&&(i=0);for(var n=t.count(),a=Math.max(1,Math.round(n/5)),o=0;o<n;o+=a)if($h.getSymbolSize(t,o)[r.isHorizontal()?1:0]*1.5>i)return!1;return!0}function AL(r,t){return isNaN(r)||isNaN(t)}function LL(r){for(var t=r.length/2;t>0&&AL(r[t*2-2],r[t*2-1]);t--);return t-1}function Hp(r,t){return[r[t*2],r[t*2+1]]}function IL(r,t,e){for(var i=r.length/2,n=e==="x"?0:1,a,o,s=0,l=-1,u=0;u<i;u++)if(o=r[u*2+n],!(isNaN(o)||isNaN(r[u*2+1-n]))){if(u===0){a=o;continue}if(a<=t&&o>=t||a>=t&&o<=t){l=u;break}s=u,a=o}return{range:[s,l],t:(t-a)/(o-a)}}function N0(r){if(r.get(["endLabel","show"]))return!0;for(var t=0;t<We.length;t++)if(r.get([We[t],"endLabel","show"]))return!0;return!1}function xu(r,t,e,i){if(B2(t,"cartesian2d")){var n=i.getModel("endLabel"),a=n.get("valueAnimation"),o=i.getData(),s={lastFrameIndex:0},l=N0(i)?function(v,d){r._endLabelOnDuring(v,d,o,s,a,n,t)}:null,u=t.getBaseAxis().isHorizontal(),f=wL(t,e,i,function(){var v=r._endLabel;v&&e&&s.originalX!=null&&v.attr({x:s.originalX,y:s.originalY})},l);if(!i.get("clip",!0)){var h=f.shape,c=Math.max(h.width,h.height);u?(h.y-=c,h.height+=c*2):(h.x-=c,h.width+=c*2)}return l&&l(1,f),f}else return xL(t,e,i)}function PL(r,t){var e=t.getBaseAxis(),i=e.isHorizontal(),n=e.inverse,a=i?n?"right":"left":"center",o=i?"middle":n?"top":"bottom";return{normal:{align:r.get("align")||a,verticalAlign:r.get("verticalAlign")||o}}}var RL=(function(r){B(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t.prototype.init=function(){var e=new Dt,i=new O2;this.group.add(i.group),this._symbolDraw=i,this._lineGroup=e,this._changePolyState=q(this._changePolyState,this)},t.prototype.render=function(e,i,n){var a=e.coordinateSystem,o=this.group,s=e.getData(),l=e.getModel("lineStyle"),u=e.getModel("areaStyle"),f=s.getLayout("points")||[],h=a.type==="polar",c=this._coordSys,v=this._symbolDraw,d=this._polyline,g=this._polygon,m=this._lineGroup,p=!i.ssr&&e.get("animation"),y=!u.isEmpty(),_=u.get("origin"),S=k0(a,s,_),x=y&&bL(a,s,S),w=e.get("showSymbol"),b=e.get("connectNulls"),D=w&&!h&&ML(e,s,a),C=this._data;C&&C.eachItemGraphicEl(function(_t,Zt){_t.__temp&&(o.remove(_t),C.setItemGraphicEl(Zt,null))}),w||v.remove(),o.add(m);var M=h?!1:e.get("step"),A;a&&a.getArea&&e.get("clip",!0)&&(A=a.getArea(),A.width!=null?(A.x-=.1,A.y-=.1,A.width+=.2,A.height+=.2):A.r0&&(A.r0-=.5,A.r+=.5)),this._clipShapeForSymbol=A;var P=CL(s,a,n)||s.getVisual("style")[s.getVisual("drawType")];if(!(d&&c.type===a.type&&M===this._step))w&&v.updateData(s,{isIgnore:D,clipShape:A,disableAnimation:!0,getSymbolPoint:function(_t){return[f[_t*2],f[_t*2+1]]}}),p&&this._initSymbolLabelAnimation(s,a,A),M&&(x&&(x=gr(x,f,a,M,b)),f=gr(f,null,a,M,b)),d=this._newPolyline(f),y?g=this._newPolygon(f,x):g&&(m.remove(g),g=this._polygon=null),h||this._initOrUpdateEndLabel(e,a,bi(P)),m.setClipPath(xu(this,a,!0,e));else{y&&!g?g=this._newPolygon(f,x):g&&!y&&(m.remove(g),g=this._polygon=null),h||this._initOrUpdateEndLabel(e,a,bi(P));var L=m.getClipPath();if(L){var I=xu(this,a,!1,e);ka(L,{shape:I.shape},e)}else m.setClipPath(xu(this,a,!0,e));w&&v.updateData(s,{isIgnore:D,clipShape:A,disableAnimation:!0,getSymbolPoint:function(_t){return[f[_t*2],f[_t*2+1]]}}),(!Bp(this._stackedOnPoints,x)||!Bp(this._points,f))&&(p?this._doUpdateAnimation(s,x,a,n,M,_,b):(M&&(x&&(x=gr(x,f,a,M,b)),f=gr(f,null,a,M,b)),d.setShape({points:f}),g&&g.setShape({points:f,stackedOnPoints:x})))}var E=e.getModel("emphasis"),k=E.get("focus"),U=E.get("blurScope"),z=E.get("disabled");if(d.useStyle(ht(l.getLineStyle(),{fill:"none",stroke:P,lineJoin:"bevel"})),fc(d,e,"lineStyle"),d.style.lineWidth>0&&e.get(["emphasis","lineStyle","width"])==="bolder"){var R=d.getState("emphasis").style;R.lineWidth=+d.style.lineWidth+1}ft(d).seriesIndex=e.seriesIndex,ef(d,k,U,z);var F=zp(e.get("smooth")),G=e.get("smoothMonotone");if(d.setShape({smooth:F,smoothMonotone:G,connectNulls:b}),g){var X=s.getCalculationInfo("stackedOnSeries"),tt=0;g.useStyle(ht(u.getAreaStyle(),{fill:P,opacity:.7,lineJoin:"bevel",decal:s.getVisual("style").decal})),X&&(tt=zp(X.get("smooth"))),g.setShape({smooth:F,stackedOnSmooth:tt,smoothMonotone:G,connectNulls:b}),fc(g,e,"areaStyle"),ft(g).seriesIndex=e.seriesIndex,ef(g,k,U,z)}var ot=this._changePolyState;s.eachItemGraphicEl(function(_t){_t&&(_t.onHoverStateChange=ot)}),this._polyline.onHoverStateChange=ot,this._data=s,this._coordSys=a,this._stackedOnPoints=x,this._points=f,this._step=M,this._valueOrigin=_,e.get("triggerLineEvent")&&(this.packEventData(e,d),g&&this.packEventData(e,g))},t.prototype.packEventData=function(e,i){ft(i).eventData={componentType:"series",componentSubType:"line",componentIndex:e.componentIndex,seriesIndex:e.seriesIndex,seriesName:e.name,seriesType:"line"}},t.prototype.highlight=function(e,i,n,a){var o=e.getData(),s=wi(o,a);if(this._changePolyState("emphasis"),!(s instanceof Array)&&s!=null&&s>=0){var l=o.getLayout("points"),u=o.getItemGraphicEl(s);if(!u){var f=l[s*2],h=l[s*2+1];if(isNaN(f)||isNaN(h)||this._clipShapeForSymbol&&!this._clipShapeForSymbol.contain(f,h))return;var c=e.get("zlevel")||0,v=e.get("z")||0;u=new $h(o,s),u.x=f,u.y=h,u.setZ(c,v);var d=u.getSymbolPath().getTextContent();d&&(d.zlevel=c,d.z=v,d.z2=this._polyline.z2+1),u.__temp=!0,o.setItemGraphicEl(s,u),u.stopSymbolAnimation(!0),this.group.add(u)}u.highlight()}else Ve.prototype.highlight.call(this,e,i,n,a)},t.prototype.downplay=function(e,i,n,a){var o=e.getData(),s=wi(o,a);if(this._changePolyState("normal"),s!=null&&s>=0){var l=o.getItemGraphicEl(s);l&&(l.__temp?(o.setItemGraphicEl(s,null),this.group.remove(l)):l.downplay())}else Ve.prototype.downplay.call(this,e,i,n,a)},t.prototype._changePolyState=function(e){var i=this._polygon;ac(this._polyline,e),i&&ac(i,e)},t.prototype._newPolyline=function(e){var i=this._polyline;return i&&this._lineGroup.remove(i),i=new yL({shape:{points:e},segmentIgnoreThreshold:2,z2:10}),this._lineGroup.add(i),this._polyline=i,i},t.prototype._newPolygon=function(e,i){var n=this._polygon;return n&&this._lineGroup.remove(n),n=new SL({shape:{points:e,stackedOnPoints:i},segmentIgnoreThreshold:2}),this._lineGroup.add(n),this._polygon=n,n},t.prototype._initSymbolLabelAnimation=function(e,i,n){var a,o,s=i.getBaseAxis(),l=s.inverse;i.type==="cartesian2d"?(a=s.isHorizontal(),o=!1):i.type==="polar"&&(a=s.dim==="angle",o=!0);var u=e.hostModel,f=u.get("animationDuration");J(f)&&(f=f(null));var h=u.get("animationDelay")||0,c=J(h)?h(null):h;e.eachItemGraphicEl(function(v,d){var g=v;if(g){var m=[v.x,v.y],p=void 0,y=void 0,_=void 0;if(n)if(o){var S=n,x=i.pointToCoord(m);a?(p=S.startAngle,y=S.endAngle,_=-x[1]/180*Math.PI):(p=S.r0,y=S.r,_=x[0])}else{var w=n;a?(p=w.x,y=w.x+w.width,_=v.x):(p=w.y+w.height,y=w.y,_=v.y)}var b=y===p?0:(_-p)/(y-p);l&&(b=1-b);var D=J(h)?h(d):f*b+c,C=g.getSymbolPath(),M=C.getTextContent();g.attr({scaleX:0,scaleY:0}),g.animateTo({scaleX:1,scaleY:1},{duration:200,setToFinal:!0,delay:D}),M&&M.animateFrom({style:{opacity:0}},{duration:300,delay:D}),C.disableLabelAnimation=!0}})},t.prototype._initOrUpdateEndLabel=function(e,i,n){var a=e.getModel("endLabel");if(N0(e)){var o=e.getData(),s=this._polyline,l=o.getLayout("points");if(!l){s.removeTextContent(),this._endLabel=null;return}var u=this._endLabel;u||(u=this._endLabel=new Nt({z2:200}),u.ignoreClip=!0,s.setTextContent(this._endLabel),s.disableLabelAnimation=!0);var f=LL(l);f>=0&&(gh(s,mh(e,"endLabel"),{inheritColor:n,labelFetcher:e,labelDataIndex:f,defaultText:function(h,c,v){return v!=null?E2(o,v):L0(o,h)},enableTextSetter:!0},PL(a,i)),s.textConfig.position=null)}else this._endLabel&&(this._polyline.removeTextContent(),this._endLabel=null)},t.prototype._endLabelOnDuring=function(e,i,n,a,o,s,l){var u=this._endLabel,f=this._polyline;if(u){e<1&&a.originalX==null&&(a.originalX=u.x,a.originalY=u.y);var h=n.getLayout("points"),c=n.hostModel,v=c.get("connectNulls"),d=s.get("precision"),g=s.get("distance")||0,m=l.getBaseAxis(),p=m.isHorizontal(),y=m.inverse,_=i.shape,S=y?p?_.x:_.y+_.height:p?_.x+_.width:_.y,x=(p?g:0)*(y?-1:1),w=(p?0:-g)*(y?-1:1),b=p?"x":"y",D=IL(h,S,b),C=D.range,M=C[1]-C[0],A=void 0;if(M>=1){if(M>1&&!v){var P=Hp(h,C[0]);u.attr({x:P[0]+x,y:P[1]+w}),o&&(A=c.getRawValue(C[0]))}else{var P=f.getPointOn(S,b);P&&u.attr({x:P[0]+x,y:P[1]+w});var L=c.getRawValue(C[0]),I=c.getRawValue(C[1]);o&&(A=pS(n,d,L,I,D.t))}a.lastFrameIndex=C[0]}else{var E=e===1||a.lastFrameIndex>0?C[0]:0,P=Hp(h,E);o&&(A=c.getRawValue(E)),u.attr({x:P[0]+x,y:P[1]+w})}if(o){var k=hm(u);typeof k.setLabelText=="function"&&k.setLabelText(A)}}},t.prototype._doUpdateAnimation=function(e,i,n,a,o,s,l){var u=this._polyline,f=this._polygon,h=e.hostModel,c=mL(this._data,e,this._stackedOnPoints,i,this._coordSys,n,this._valueOrigin),v=c.current,d=c.stackedOnCurrent,g=c.next,m=c.stackedOnNext;if(o&&(d=gr(c.stackedOnCurrent,c.current,n,o,l),v=gr(c.current,null,n,o,l),m=gr(c.stackedOnNext,c.next,n,o,l),g=gr(c.next,null,n,o,l)),Fp(v,g)>3e3||f&&Fp(d,m)>3e3){u.stopAnimation(),u.setShape({points:g}),f&&(f.stopAnimation(),f.setShape({points:g,stackedOnPoints:m}));return}u.shape.__points=c.current,u.shape.points=v;var p={shape:{points:g}};c.current!==v&&(p.shape.__points=c.next),u.stopAnimation(),Ar(u,p,h),f&&(f.setShape({points:v,stackedOnPoints:d}),f.stopAnimation(),Ar(f,{shape:{stackedOnPoints:m}},h),u.shape.points!==f.shape.points&&(f.shape.points=u.shape.points));for(var y=[],_=c.status,S=0;S<_.length;S++){var x=_[S].cmd;if(x==="="){var w=e.getItemGraphicEl(_[S].idx1);w&&y.push({el:w,ptIdx:S})}}u.animators&&u.animators.length&&u.animators[0].during(function(){f&&f.dirtyShape();for(var b=u.shape.__points,D=0;D<y.length;D++){var C=y[D].el,M=y[D].ptIdx*2;C.x=b[M],C.y=b[M+1],C.markRedraw()}})},t.prototype.remove=function(e){var i=this.group,n=this._data;this._lineGroup.removeAll(),this._symbolDraw.remove(!0),n&&n.eachItemGraphicEl(function(a,o){a.__temp&&(i.remove(a),n.setItemGraphicEl(o,null))}),this._polyline=this._polygon=this._coordSys=this._points=this._stackedOnPoints=this._endLabel=this._data=null},t.type="line",t})(Ve);function EL(r,t){return{seriesType:r,plan:Jm(),reset:function(e){var i=e.getData(),n=e.coordinateSystem;if(e.pipelineContext,!!n){var a=K(n.dimensions,function(h){return i.mapDimension(h)}).slice(0,2),o=a.length,s=i.getCalculationInfo("stackResultDimension");xa(i,a[0])&&(a[0]=s),xa(i,a[1])&&(a[1]=s);var l=i.getStore(),u=i.getDimensionIndex(a[0]),f=i.getDimensionIndex(a[1]);return o&&{progress:function(h,c){for(var v=h.end-h.start,d=tn(v*o),g=[],m=[],p=h.start,y=0;p<h.end;p++){var _=void 0;if(o===1){var S=l.get(u,p);_=n.dataToPoint(S,null,m)}else g[0]=l.get(u,p),g[1]=l.get(f,p),_=n.dataToPoint(g,null,m);d[y++]=_[0],d[y++]=_[1]}c.setLayout("points",d)}}}}}}var kL={average:function(r){for(var t=0,e=0,i=0;i<r.length;i++)isNaN(r[i])||(t+=r[i],e++);return e===0?NaN:t/e},sum:function(r){for(var t=0,e=0;e<r.length;e++)t+=r[e]||0;return t},max:function(r){for(var t=-1/0,e=0;e<r.length;e++)r[e]>t&&(t=r[e]);return isFinite(t)?t:NaN},min:function(r){for(var t=1/0,e=0;e<r.length;e++)r[e]<t&&(t=r[e]);return isFinite(t)?t:NaN},nearest:function(r){return r[0]}},OL=function(r){return Math.round(r.length/2)};function BL(r){return{seriesType:r,reset:function(t,e,i){var n=t.getData(),a=t.get("sampling"),o=t.coordinateSystem,s=n.count();if(s>10&&o.type==="cartesian2d"&&a){var l=o.getBaseAxis(),u=o.getOtherAxis(l),f=l.getExtent(),h=i.getDevicePixelRatio(),c=Math.abs(f[1]-f[0])*(h||1),v=Math.round(s/c);if(isFinite(v)&&v>1){a==="lttb"?t.setData(n.lttbDownSample(n.mapDimension(u.dim),1/v)):a==="minmax"&&t.setData(n.minmaxDownSample(n.mapDimension(u.dim),1/v));var d=void 0;W(a)?d=kL[a]:J(a)&&(d=a),d&&t.setData(n.downSample(n.mapDimension(u.dim),1/v,d,OL))}}}}}function NL(r){r.registerChartView(RL),r.registerSeriesModel(dL),r.registerLayout(EL("line")),r.registerVisual({seriesType:"line",reset:function(t){var e=t.getData(),i=t.getModel("lineStyle").getLineStyle();i&&!i.stroke&&(i.stroke=e.getVisual("style").fill),e.setVisual("legendLineStyle",i)}}),r.registerProcessor(r.PRIORITY.PROCESSOR.STATISTIC,BL("line"))}function Gp(r,t,e){var i=ir.createCanvas(),n=t.getWidth(),a=t.getHeight(),o=i.style;return o&&(o.position="absolute",o.left="0",o.top="0",o.width=n+"px",o.height=a+"px",i.setAttribute("data-zr-dom-id",r)),i.width=n*e,i.height=a*e,i}var bu=(function(r){B(t,r);function t(e,i,n){var a=r.call(this)||this;a.motionBlur=!1,a.lastFrameAlpha=.7,a.dpr=1,a.virtual=!1,a.config={},a.incremental=!1,a.zlevel=0,a.maxRepaintRectCount=5,a.__dirty=!0,a.__firstTimePaint=!0,a.__used=!1,a.__drawIndex=0,a.__startIndex=0,a.__endIndex=0,a.__prevStartIndex=null,a.__prevEndIndex=null;var o;n=n||Jo,typeof e=="string"?o=Gp(e,i,n):Z(e)&&(o=e,e=o.id),a.id=e,a.dom=o;var s=o.style;return s&&(qp(o),o.onselectstart=function(){return!1},s.padding="0",s.margin="0",s.borderWidth="0"),a.painter=i,a.dpr=n,a}return t.prototype.getElementCount=function(){return this.__endIndex-this.__startIndex},t.prototype.afterBrush=function(){this.__prevStartIndex=this.__startIndex,this.__prevEndIndex=this.__endIndex},t.prototype.initContext=function(){this.ctx=this.dom.getContext("2d"),this.ctx.dpr=this.dpr},t.prototype.setUnpainted=function(){this.__firstTimePaint=!0},t.prototype.createBackBuffer=function(){var e=this.dpr;this.domBack=Gp("back-"+this.id,this.painter,e),this.ctxBack=this.domBack.getContext("2d"),e!==1&&this.ctxBack.scale(e,e)},t.prototype.createRepaintRects=function(e,i,n,a){if(this.__firstTimePaint)return this.__firstTimePaint=!1,null;var o=[],s=this.maxRepaintRectCount,l=!1,u=new rt(0,0,0,0);function f(y){if(!(!y.isFinite()||y.isZero()))if(o.length===0){var _=new rt(0,0,0,0);_.copy(y),o.push(_)}else{for(var S=!1,x=1/0,w=0,b=0;b<o.length;++b){var D=o[b];if(D.intersect(y)){var C=new rt(0,0,0,0);C.copy(D),C.union(y),o[b]=C,S=!0;break}else if(l){u.copy(y),u.union(D);var M=y.width*y.height,A=D.width*D.height,P=u.width*u.height,L=P-M-A;L<x&&(x=L,w=b)}}if(l&&(o[w].union(y),S=!0),!S){var _=new rt(0,0,0,0);_.copy(y),o.push(_)}l||(l=o.length>=s)}}for(var h=this.__startIndex;h<this.__endIndex;++h){var c=e[h];if(c){var v=c.shouldBePainted(n,a,!0,!0),d=c.__isRendered&&(c.__dirty&ie||!v)?c.getPrevPaintRect():null;d&&f(d);var g=v&&(c.__dirty&ie||!c.__isRendered)?c.getPaintRect():null;g&&f(g)}}for(var h=this.__prevStartIndex;h<this.__prevEndIndex;++h){var c=i[h],v=c&&c.shouldBePainted(n,a,!0,!0);if(c&&(!v||!c.__zr)&&c.__isRendered){var d=c.getPrevPaintRect();d&&f(d)}}var m;do{m=!1;for(var h=0;h<o.length;){if(o[h].isZero()){o.splice(h,1);continue}for(var p=h+1;p<o.length;)o[h].intersect(o[p])?(m=!0,o[h].union(o[p]),o.splice(p,1)):p++;h++}}while(m);return this._paintRects=o,o},t.prototype.debugGetPaintRects=function(){return(this._paintRects||[]).slice()},t.prototype.resize=function(e,i){var n=this.dpr,a=this.dom,o=a.style,s=this.domBack;o&&(o.width=e+"px",o.height=i+"px"),a.width=e*n,a.height=i*n,s&&(s.width=e*n,s.height=i*n,n!==1&&this.ctxBack.scale(n,n))},t.prototype.clear=function(e,i,n){var a=this.dom,o=this.ctx,s=a.width,l=a.height;i=i||this.clearColor;var u=this.motionBlur&&!e,f=this.lastFrameAlpha,h=this.dpr,c=this;u&&(this.domBack||this.createBackBuffer(),this.ctxBack.globalCompositeOperation="copy",this.ctxBack.drawImage(a,0,0,s/h,l/h));var v=this.domBack;function d(g,m,p,y){if(o.clearRect(g,m,p,y),i&&i!=="transparent"){var _=void 0;if(As(i)){var S=i.global||i.__width===p&&i.__height===y;_=S&&i.__canvasGradient||gf(o,i,{x:0,y:0,width:p,height:y}),i.__canvasGradient=_,i.__width=p,i.__height=y}else S_(i)&&(i.scaleX=i.scaleX||h,i.scaleY=i.scaleY||h,_=mf(o,i,{dirty:function(){c.setUnpainted(),c.painter.refresh()}}));o.save(),o.fillStyle=_||i,o.fillRect(g,m,p,y),o.restore()}u&&(o.save(),o.globalAlpha=f,o.drawImage(v,g,m,p,y),o.restore())}!n||u?d(0,0,s,l):n.length&&T(n,function(g){d(g.x*h,g.y*h,g.width*h,g.height*h)})},t})(Te),Vp=1e5,oi=314159,Ao=.01,FL=.001;function zL(r){return r?r.__builtin__?!0:!(typeof r.resize!="function"||typeof r.refresh!="function"):!1}function HL(r,t){var e=document.createElement("div");return e.style.cssText=["position:relative","width:"+r+"px","height:"+t+"px","padding:0","margin:0","border-width:0"].join(";")+";",e}var GL=(function(){function r(t,e,i,n){this.type="canvas",this._zlevelList=[],this._prevDisplayList=[],this._layers={},this._layerConfig={},this._needsManuallyCompositing=!1,this.type="canvas";var a=!t.nodeName||t.nodeName.toUpperCase()==="CANVAS";this._opts=i=O({},i||{}),this.dpr=i.devicePixelRatio||Jo,this._singleCanvas=a,this.root=t;var o=t.style;o&&(qp(t),t.innerHTML=""),this.storage=e;var s=this._zlevelList;this._prevDisplayList=[];var l=this._layers;if(a){var f=t,h=f.width,c=f.height;i.width!=null&&(h=i.width),i.height!=null&&(c=i.height),this.dpr=i.devicePixelRatio||1,f.width=h*this.dpr,f.height=c*this.dpr,this._width=h,this._height=c;var v=new bu(f,this,this.dpr);v.__builtin__=!0,v.initContext(),l[oi]=v,v.zlevel=oi,s.push(oi),this._domRoot=t}else{this._width=go(t,0,i),this._height=go(t,1,i);var u=this._domRoot=HL(this._width,this._height);t.appendChild(u)}}return r.prototype.getType=function(){return"canvas"},r.prototype.isSingleCanvas=function(){return this._singleCanvas},r.prototype.getViewportRoot=function(){return this._domRoot},r.prototype.getViewportRootOffset=function(){var t=this.getViewportRoot();if(t)return{offsetLeft:t.offsetLeft||0,offsetTop:t.offsetTop||0}},r.prototype.refresh=function(t){var e=this.storage.getDisplayList(!0),i=this._prevDisplayList,n=this._zlevelList;this._redrawId=Math.random(),this._paintList(e,i,t,this._redrawId);for(var a=0;a<n.length;a++){var o=n[a],s=this._layers[o];if(!s.__builtin__&&s.refresh){var l=a===0?this._backgroundColor:null;s.refresh(l)}}return this._opts.useDirtyRect&&(this._prevDisplayList=e.slice()),this},r.prototype.refreshHover=function(){this._paintHoverList(this.storage.getDisplayList(!1))},r.prototype._paintHoverList=function(t){var e=t.length,i=this._hoverlayer;if(i&&i.clear(),!!e){for(var n={inHover:!0,viewWidth:this._width,viewHeight:this._height},a,o=0;o<e;o++){var s=t[o];s.__inHover&&(i||(i=this._hoverlayer=this.getLayer(Vp)),a||(a=i.ctx,a.save()),ci(a,s,n,o===e-1))}a&&a.restore()}},r.prototype.getHoverLayer=function(){return this.getLayer(Vp)},r.prototype.paintOne=function(t,e){vy(t,e)},r.prototype._paintList=function(t,e,i,n){if(this._redrawId===n){i=i||!1,this._updateLayerStatus(t);var a=this._doPaintList(t,e,i),o=a.finished,s=a.needsRefreshHover;if(this._needsManuallyCompositing&&this._compositeManually(),s&&this._paintHoverList(t),o)this.eachLayer(function(u){u.afterBrush&&u.afterBrush()});else{var l=this;Zo(function(){l._paintList(t,e,i,n)})}}},r.prototype._compositeManually=function(){var t=this.getLayer(oi).ctx,e=this._domRoot.width,i=this._domRoot.height;t.clearRect(0,0,e,i),this.eachBuiltinLayer(function(n){n.virtual&&t.drawImage(n.dom,0,0,e,i)})},r.prototype._doPaintList=function(t,e,i){for(var n=this,a=[],o=this._opts.useDirtyRect,s=0;s<this._zlevelList.length;s++){var l=this._zlevelList[s],u=this._layers[l];u.__builtin__&&u!==this._hoverlayer&&(u.__dirty||i)&&a.push(u)}for(var f=!0,h=!1,c=function(g){var m=a[g],p=m.ctx,y=o&&m.createRepaintRects(t,e,v._width,v._height),_=i?m.__startIndex:m.__drawIndex,S=!i&&m.incremental&&Date.now,x=S&&Date.now(),w=m.zlevel===v._zlevelList[0]?v._backgroundColor:null;if(m.__startIndex===m.__endIndex)m.clear(!1,w,y);else if(_===m.__startIndex){var b=t[_];(!b.incremental||!b.notClear||i)&&m.clear(!1,w,y)}_===-1&&(console.error("For some unknown reason. drawIndex is -1"),_=m.__startIndex);var D,C=function(L){var I={inHover:!1,allClipped:!1,prevEl:null,viewWidth:n._width,viewHeight:n._height};for(D=_;D<m.__endIndex;D++){var E=t[D];if(E.__inHover&&(h=!0),n._doPaintEl(E,m,o,L,I,D===m.__endIndex-1),S){var k=Date.now()-x;if(k>15)break}}I.prevElClipPaths&&p.restore()};if(y)if(y.length===0)D=m.__endIndex;else for(var M=v.dpr,A=0;A<y.length;++A){var P=y[A];p.save(),p.beginPath(),p.rect(P.x*M,P.y*M,P.width*M,P.height*M),p.clip(),C(P),p.restore()}else p.save(),C(),p.restore();m.__drawIndex=D,m.__drawIndex<m.__endIndex&&(f=!1)},v=this,d=0;d<a.length;d++)c(d);return j.wxa&&T(this._layers,function(g){g&&g.ctx&&g.ctx.draw&&g.ctx.draw()}),{finished:f,needsRefreshHover:h}},r.prototype._doPaintEl=function(t,e,i,n,a,o){var s=e.ctx;if(i){var l=t.getPaintRect();(!n||l&&l.intersect(n))&&(ci(s,t,a,o),t.setPrevPaintRect(l))}else ci(s,t,a,o)},r.prototype.getLayer=function(t,e){this._singleCanvas&&!this._needsManuallyCompositing&&(t=oi);var i=this._layers[t];return i||(i=new bu("zr_"+t,this,this.dpr),i.zlevel=t,i.__builtin__=!0,this._layerConfig[t]?st(i,this._layerConfig[t],!0):this._layerConfig[t-Ao]&&st(i,this._layerConfig[t-Ao],!0),e&&(i.virtual=e),this.insertLayer(t,i),i.initContext()),i},r.prototype.insertLayer=function(t,e){var i=this._layers,n=this._zlevelList,a=n.length,o=this._domRoot,s=null,l=-1;if(!i[t]&&zL(e)){if(a>0&&t>n[0]){for(l=0;l<a-1&&!(n[l]<t&&n[l+1]>t);l++);s=i[n[l]]}if(n.splice(l+1,0,t),i[t]=e,!e.virtual)if(s){var u=s.dom;u.nextSibling?o.insertBefore(e.dom,u.nextSibling):o.appendChild(e.dom)}else o.firstChild?o.insertBefore(e.dom,o.firstChild):o.appendChild(e.dom);e.painter||(e.painter=this)}},r.prototype.eachLayer=function(t,e){for(var i=this._zlevelList,n=0;n<i.length;n++){var a=i[n];t.call(e,this._layers[a],a)}},r.prototype.eachBuiltinLayer=function(t,e){for(var i=this._zlevelList,n=0;n<i.length;n++){var a=i[n],o=this._layers[a];o.__builtin__&&t.call(e,o,a)}},r.prototype.eachOtherLayer=function(t,e){for(var i=this._zlevelList,n=0;n<i.length;n++){var a=i[n],o=this._layers[a];o.__builtin__||t.call(e,o,a)}},r.prototype.getLayers=function(){return this._layers},r.prototype._updateLayerStatus=function(t){this.eachBuiltinLayer(function(h,c){h.__dirty=h.__used=!1});function e(h){a&&(a.__endIndex!==h&&(a.__dirty=!0),a.__endIndex=h)}if(this._singleCanvas)for(var i=1;i<t.length;i++){var n=t[i];if(n.zlevel!==t[i-1].zlevel||n.incremental){this._needsManuallyCompositing=!0;break}}var a=null,o=0,s,l;for(l=0;l<t.length;l++){var n=t[l],u=n.zlevel,f=void 0;s!==u&&(s=u,o=0),n.incremental?(f=this.getLayer(u+FL,this._needsManuallyCompositing),f.incremental=!0,o=1):f=this.getLayer(u+(o>0?Ao:0),this._needsManuallyCompositing),f.__builtin__||Wf("ZLevel "+u+" has been used by unkown layer "+f.id),f!==a&&(f.__used=!0,f.__startIndex!==l&&(f.__dirty=!0),f.__startIndex=l,f.incremental?f.__drawIndex=-1:f.__drawIndex=l,e(l),a=f),n.__dirty&ie&&!n.__inHover&&(f.__dirty=!0,f.incremental&&f.__drawIndex<0&&(f.__drawIndex=l))}e(l),this.eachBuiltinLayer(function(h,c){!h.__used&&h.getElementCount()>0&&(h.__dirty=!0,h.__startIndex=h.__endIndex=h.__drawIndex=0),h.__dirty&&h.__drawIndex<0&&(h.__drawIndex=h.__startIndex)})},r.prototype.clear=function(){return this.eachBuiltinLayer(this._clearLayer),this},r.prototype._clearLayer=function(t){t.clear()},r.prototype.setBackgroundColor=function(t){this._backgroundColor=t,T(this._layers,function(e){e.setUnpainted()})},r.prototype.configLayer=function(t,e){if(e){var i=this._layerConfig;i[t]?st(i[t],e,!0):i[t]=e;for(var n=0;n<this._zlevelList.length;n++){var a=this._zlevelList[n];if(a===t||a===t+Ao){var o=this._layers[a];st(o,i[t],!0)}}}},r.prototype.delLayer=function(t){var e=this._layers,i=this._zlevelList,n=e[t];n&&(n.dom.parentNode.removeChild(n.dom),delete e[t],i.splice(at(i,t),1))},r.prototype.resize=function(t,e){if(this._domRoot.style){var i=this._domRoot;i.style.display="none";var n=this._opts,a=this.root;if(t!=null&&(n.width=t),e!=null&&(n.height=e),t=go(a,0,n),e=go(a,1,n),i.style.display="",this._width!==t||e!==this._height){i.style.width=t+"px",i.style.height=e+"px";for(var o in this._layers)this._layers.hasOwnProperty(o)&&this._layers[o].resize(t,e);this.refresh(!0)}this._width=t,this._height=e}else{if(t==null||e==null)return;this._width=t,this._height=e,this.getLayer(oi).resize(t,e)}return this},r.prototype.clearLayer=function(t){var e=this._layers[t];e&&e.clear()},r.prototype.dispose=function(){this.root.innerHTML="",this.root=this.storage=this._domRoot=this._layers=null},r.prototype.getRenderedCanvas=function(t){if(t=t||{},this._singleCanvas&&!this._compositeManually)return this._layers[oi].dom;var e=new bu("image",this,t.pixelRatio||this.dpr);e.initContext(),e.clear(!1,t.backgroundColor||this._backgroundColor);var i=e.ctx;if(t.pixelRatio<=this.dpr){this.refresh();var n=e.dom.width,a=e.dom.height;this.eachLayer(function(h){h.__builtin__?i.drawImage(h.dom,0,0,n,a):h.renderToCanvas&&(i.save(),h.renderToCanvas(i),i.restore())})}else for(var o={inHover:!1,viewWidth:this._width,viewHeight:this._height},s=this.storage.getDisplayList(!0),l=0,u=s.length;l<u;l++){var f=s[l];ci(i,f,o,l===u-1)}return e.dom},r.prototype.getWidth=function(){return this._width},r.prototype.getHeight=function(){return this._height},r})();function VL(r){r.registerPainter("canvas",GL)}const WL={key:1,class:"stats-overview mb-6"},UL={class:"stat-content"},YL={class:"stat-info"},ZL={class:"stat-value"},XL={class:"stat-trend success"},qL={class:"stat-content"},$L={class:"stat-info"},KL={class:"stat-value"},QL={class:"stat-trend"},JL={class:"stat-content"},jL={class:"stat-info"},tI={class:"stat-value"},eI={class:"stat-trend"},rI={class:"stat-content"},iI={class:"stat-info"},nI={class:"stat-value"},aI={class:"stat-trend"},oI={class:"stat-content"},sI={class:"stat-info"},lI={class:"stat-value"},uI={class:"stat-trend"},fI={class:"stat-content"},hI={class:"stat-info"},vI={class:"stat-value"},cI={class:"stat-trend"},dI={class:"card-header"},pI={key:0},gI={class:"top-item-info"},mI={class:"country-name"},yI={class:"country-code text-secondary"},_I={class:"top-item-stats"},SI={class:"request-count"},wI=z0({__name:"StatsOverview",setup(r){Ue([$A,L2,Z2,cL,R2,NL,VL]);const t=i_(),{trendData:e,topCountries:i,topIPs:n,loading:a}=H0(t),o=si("hourly"),s=si();let l=null;const u=Ba(()=>{const w=Array.isArray(e.value?.trend)?e.value.trend:[];if(w.length===0)return null;const b=w.reduce((R,F)=>R+(F.total_requests||0),0),D=w.reduce((R,F)=>R+(F.success_requests||0),0),C=w.reduce((R,F)=>R+(F.client_error_requests||0),0),M=w.reduce((R,F)=>R+(F.server_error_requests||0),0),A=w.reduce((R,F)=>R+(F.total_bytes_sent||0),0),P=w.reduce((R,F)=>R+(F.waf_blocked_requests||0),0),L=w.reduce((R,F)=>R+(F.rate_limited_requests||0),0),I=w.map(R=>R.avg_response_time).filter(R=>R!=null),E=w.map(R=>R.p50_response_time).filter(R=>R!=null),k=w.map(R=>R.p95_response_time).filter(R=>R!=null),U=w.map(R=>R.p99_response_time).filter(R=>R!=null),z=w.reduce((R,F)=>{const G=F.unique_ips||0;return G>R?G:R},0);return{total_requests:b,success_requests:D,client_error_requests:C,server_error_requests:M,total_bytes_sent:A,unique_ips:z,waf_blocked_requests:P,rate_limited_requests:L,avg_response_time:I.length>0?I.reduce((R,F)=>R+F,0)/I.length:0,p50_response_time:E.length>0?E[E.length-1]:0,p95_response_time:k.length>0?k[k.length-1]:0,p99_response_time:U.length>0?U[U.length-1]:0}}),f=Ba(()=>{if(!n.value||!Array.isArray(n.value.items))return[];const w=n.value.items.map(C=>{const M=C.stats_metadata||{};return{ip:C.dimension_value||M.client_ip||"unknown",request_count:M.count||C.total_requests||0,country:M.country||M.country_name||"Unknown",city:M.city||"Unknown",percentage:typeof M.percentage=="number"?M.percentage:null}}),b=w.reduce((C,M)=>C+M.request_count,0),D=b>0?b:1;return w.map(C=>({...C,percentage:C.percentage??Number((C.request_count/D*100).toFixed(2))}))}),h=Ba(()=>{if(!i.value||!Array.isArray(i.value.items))return[];const w=i.value.items.map(C=>{const M=C.stats_metadata||{};return{country_code:C.dimension_value||M.country_code||"UNKNOWN",country_name:M.country_name||M.country||C.dimension_value||"Unknown",request_count:M.count||C.total_requests||0}}),b=w.reduce((C,M)=>C+M.request_count,0),D=b>0?b:1;return w.map(C=>({...C,percentage:Number((C.request_count/D*100).toFixed(2))}))}),c=Ba(()=>{if(!u.value)return 0;const w=u.value.total_requests;return w===0?0:(u.value.success_requests/w*100).toFixed(2)}),v=w=>!w&&w!==0?"0":w>=1e6?(w/1e6).toFixed(1)+"M":w>=1e3?(w/1e3).toFixed(1)+"K":w.toString(),d=w=>w>=1024*1024*1024?(w/(1024*1024*1024)).toFixed(2)+" GB":w>=1024*1024?(w/(1024*1024)).toFixed(2)+" MB":w>=1024?(w/1024).toFixed(2)+" KB":w+" B",g=async()=>{const{start_time:w,end_time:b}=m(o.value);await Promise.all([t.fetchGlobalTrend({period:o.value,start_time:w,end_time:b}),t.fetchTopCountries({limit:10,start_time:w,end_time:b}),t.fetchTopIPs({limit:10,start_time:w,end_time:b})]),p()},m=w=>{const b=new Date,D=new Date(b);return w==="hourly"?D.setHours(D.getHours()-24):w==="daily"?D.setDate(D.getDate()-7):D.setDate(D.getDate()-30),{start_time:D.toISOString(),end_time:b.toISOString()}},p=()=>{if(!s.value)return;if(l||(l=$C(s.value)),!e.value||!e.value.trend){l.setOption({title:{text:"暂无数据",left:"center",top:"center",textStyle:{color:"#999",fontSize:14}},xAxis:{type:"category",data:[]},yAxis:[{type:"value"},{type:"value"}],series:[]},!0);return}const w=Array.isArray(e.value.trend)?e.value.trend:[];if(w.length===0){l.setOption({title:{text:"暂无数据",left:"center",top:"center",textStyle:{color:"#999",fontSize:14}},xAxis:{type:"category",data:[]},yAxis:[{type:"value"},{type:"value"}],series:[]},!0);return}const b=w.map(C=>{const M=new Date(C.stat_time);return o.value==="hourly"?M.toLocaleTimeString("zh-CN",{hour:"2-digit",minute:"2-digit"}):o.value==="daily"?M.toLocaleDateString("zh-CN",{month:"2-digit",day:"2-digit"}):M.toLocaleDateString("zh-CN",{year:"numeric",month:"2-digit"})}),D={title:{text:""},tooltip:{trigger:"axis",axisPointer:{type:"cross"}},legend:{data:["总请求","成功请求","失败请求","平均响应时间"]},grid:{left:"3%",right:"4%",bottom:"3%",containLabel:!0},xAxis:{type:"category",boundaryGap:!1,data:b},yAxis:[{type:"value",name:"请求数",position:"left"},{type:"value",name:"响应时间(ms)",position:"right"}],series:[{name:"总请求",type:"line",data:w.map(C=>C.total_requests||0),smooth:!0,itemStyle:{color:"#1677ff"}},{name:"成功请求",type:"line",data:w.map(C=>C.success_requests||0),smooth:!0,itemStyle:{color:"#52c41a"}},{name:"失败请求",type:"line",data:w.map(C=>(C.client_error_requests||0)+(C.server_error_requests||0)),smooth:!0,itemStyle:{color:"#ff4d4f"}},{name:"平均响应时间",type:"line",yAxisIndex:1,data:w.map(C=>C.avg_response_time),smooth:!0,itemStyle:{color:"#faad14"}}]};l.setOption(D,!0)},y=async()=>{await g()};let _=null;const S=()=>{_=window.setInterval(()=>{y()},3e4)},x=()=>{_&&(clearInterval(_),_=null)};return G0(async()=>{await y(),S(),window.addEventListener("resize",()=>{l?.resize()})}),V0(()=>{x(),l?.dispose()}),(w,b)=>{const D=oe("el-button"),C=oe("el-skeleton"),M=oe("el-card"),A=oe("el-radio-button"),P=oe("el-radio-group"),L=oe("el-col"),I=oe("el-progress"),E=oe("el-empty"),k=oe("el-row"),U=oe("el-tag"),z=oe("el-table-column"),R=oe("el-table"),F=Y0("loading");return sr(),Na(r_,{title:"统计概览",icon:"i-carbon-analytics"},{actions:ct(()=>[pt(D,{onClick:y,loading:tl(a)},{default:ct(()=>[...b[1]||(b[1]=[Y("i",{class:"i-carbon-renew mr-2"},null,-1),Y("span",null,"刷新",-1)])]),_:1},8,["loading"])]),default:ct(()=>[!u.value&&tl(a)?(sr(),Na(C,{key:0,rows:6,animated:""})):u.value?(sr(),Fa("div",WL,[pt(M,{class:"stat-card"},{default:ct(()=>[Y("div",UL,[b[3]||(b[3]=Y("div",{class:"stat-icon stat-icon-primary"},[Y("i",{class:"i-carbon-network-4"})],-1)),Y("div",YL,[b[2]||(b[2]=Y("p",{class:"stat-label"},"总请求数",-1)),Y("h3",ZL,At(v(u.value.total_requests)),1),Y("p",XL," 成功: "+At(u.value.success_requests),1)])])]),_:1}),pt(M,{class:"stat-card"},{default:ct(()=>[Y("div",qL,[b[5]||(b[5]=Y("div",{class:"stat-icon stat-icon-success"},[Y("i",{class:"i-carbon-checkmark"})],-1)),Y("div",$L,[b[4]||(b[4]=Y("p",{class:"stat-label"},"成功率",-1)),Y("h3",KL,At(c.value)+"%",1),Y("p",QL," 错误: "+At(u.value.client_error_requests+u.value.server_error_requests),1)])])]),_:1}),pt(M,{class:"stat-card"},{default:ct(()=>[Y("div",JL,[b[7]||(b[7]=Y("div",{class:"stat-icon stat-icon-warning"},[Y("i",{class:"i-carbon-time"})],-1)),Y("div",jL,[b[6]||(b[6]=Y("p",{class:"stat-label"},"平均响应时间",-1)),Y("h3",tI,At((u.value.avg_response_time||0).toFixed(1))+"ms",1),Y("p",eI," P95: "+At((u.value.p95_response_time||0).toFixed(1))+"ms ",1)])])]),_:1}),pt(M,{class:"stat-card"},{default:ct(()=>[Y("div",rI,[b[9]||(b[9]=Y("div",{class:"stat-icon stat-icon-info"},[Y("i",{class:"i-carbon-user-multiple"})],-1)),Y("div",iI,[b[8]||(b[8]=Y("p",{class:"stat-label"},"独立IP数",-1)),Y("h3",nI,At(v(u.value.unique_ips)),1),Y("p",aI," 数据传输: "+At(d(u.value.total_bytes_sent)),1)])])]),_:1}),pt(M,{class:"stat-card"},{default:ct(()=>[Y("div",oI,[b[11]||(b[11]=Y("div",{class:"stat-icon stat-icon-danger"},[Y("i",{class:"i-carbon-security"})],-1)),Y("div",sI,[b[10]||(b[10]=Y("p",{class:"stat-label"},"安全拦截",-1)),Y("h3",lI,At(u.value.waf_blocked_requests+u.value.rate_limited_requests),1),Y("p",uI," WAF: "+At(u.value.waf_blocked_requests)+" | 限流: "+At(u.value.rate_limited_requests),1)])])]),_:1}),pt(M,{class:"stat-card"},{default:ct(()=>[Y("div",fI,[b[13]||(b[13]=Y("div",{class:"stat-icon stat-icon-secondary"},[Y("i",{class:"i-carbon-download"})],-1)),Y("div",hI,[b[12]||(b[12]=Y("p",{class:"stat-label"},"P99响应时间",-1)),Y("h3",vI,At((u.value.p99_response_time||0).toFixed(1))+"ms",1),Y("p",cI," P50: "+At((u.value.p50_response_time||0).toFixed(1))+"ms ",1)])])]),_:1})])):W0("",!0),pt(k,{gutter:16,class:"mb-6"},{default:ct(()=>[pt(L,{xs:24,lg:16},{default:ct(()=>[U0((sr(),Na(M,null,{header:ct(()=>[Y("div",dI,[b[17]||(b[17]=Y("span",null,"请求趋势",-1)),pt(P,{modelValue:o.value,"onUpdate:modelValue":b[0]||(b[0]=G=>o.value=G),size:"small",onChange:g},{default:ct(()=>[pt(A,{value:"hourly"},{default:ct(()=>[...b[14]||(b[14]=[za("小时",-1)])]),_:1}),pt(A,{value:"daily"},{default:ct(()=>[...b[15]||(b[15]=[za("天",-1)])]),_:1}),pt(A,{value:"monthly"},{default:ct(()=>[...b[16]||(b[16]=[za("月",-1)])]),_:1})]),_:1},8,["modelValue"])])]),default:ct(()=>[Y("div",{class:"chart-container",ref_key:"trendChartRef",ref:s},null,512)]),_:1})),[[F,tl(a)]])]),_:1}),pt(L,{xs:24,lg:8},{default:ct(()=>[pt(M,null,{header:ct(()=>[...b[18]||(b[18]=[Y("span",null,"Top 国家/地区",-1)])]),default:ct(()=>[h.value.length>0?(sr(),Fa("div",pI,[(sr(!0),Fa(Z0,null,X0(h.value,G=>(sr(),Fa("div",{key:G.country_code,class:"top-item"},[Y("div",gI,[Y("span",mI,At(G.country_name),1),Y("span",yI,At(G.country_code),1)]),Y("div",_I,[Y("span",SI,At(v(G.request_count)),1),pt(I,{percentage:G.percentage,"show-text":!1,"stroke-width":6},null,8,["percentage"])])]))),128))])):(sr(),Na(E,{key:1,description:"暂无数据","image-size":100}))]),_:1})]),_:1})]),_:1}),pt(M,null,{header:ct(()=>[...b[19]||(b[19]=[Y("span",null,"Top IP 地址",-1)])]),default:ct(()=>[pt(R,{data:f.value,stripe:"",style:{width:"100%"}},{default:ct(()=>[pt(z,{label:"排名",width:"80",align:"center"},{default:ct(({$index:G})=>[pt(U,{type:G===0?"danger":G===1?"warning":"info",size:"small"},{default:ct(()=>[za(At(G+1),1)]),_:2},1032,["type"])]),_:1}),pt(z,{prop:"ip",label:"IP地址",width:"150"}),pt(z,{prop:"country",label:"国家",width:"120"}),pt(z,{prop:"city",label:"城市",width:"120"}),pt(z,{label:"请求数",width:"150",align:"right"},{default:ct(({row:G})=>[Y("strong",null,At(v(G.request_count)),1)]),_:1}),pt(z,{label:"占比",align:"right"},{default:ct(({row:G})=>[pt(I,{percentage:G.percentage,"show-text":!0,"stroke-width":12},null,8,["percentage"])]),_:1})]),_:1},8,["data"])]),_:1})]),_:1})}}}),CI=q0(wI,[["__scopeId","data-v-6836137c"]]);export{CI as default};