@limetech/lime-elements 40.24.0 → 40.25.0

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 (244) hide show
  1. package/CHANGELOG.md +8 -0
  2. package/dist/cjs/{checkbox.template-CNJ29zDR.js → checkbox.template-DgiUCPna.js} +1 -1
  3. package/dist/cjs/{image.template-DlF-f23b.js → image.template-B_HZH9t-.js} +1 -1
  4. package/dist/cjs/{index-BlsqxTB1.js → index-CQn9p_mp.js} +12 -0
  5. package/dist/cjs/lime-elements.cjs.js +2 -2
  6. package/dist/cjs/limel-3d-hover-effect-glow.cjs.entry.js +1 -1
  7. package/dist/cjs/limel-action-bar_3.cjs.entry.js +1 -1
  8. package/dist/cjs/limel-ai-avatar.cjs.entry.js +1 -1
  9. package/dist/cjs/limel-badge_7.cjs.entry.js +1 -1
  10. package/dist/cjs/limel-banner.cjs.entry.js +1 -1
  11. package/dist/cjs/limel-button-group.cjs.entry.js +1 -1
  12. package/dist/cjs/limel-button.cjs.entry.js +1 -1
  13. package/dist/cjs/limel-callout.cjs.entry.js +1 -1
  14. package/dist/cjs/limel-card.cjs.entry.js +2 -2
  15. package/dist/cjs/limel-chart.cjs.entry.js +777 -174
  16. package/dist/cjs/limel-checkbox.cjs.entry.js +2 -2
  17. package/dist/cjs/limel-chip-set.cjs.entry.js +1 -1
  18. package/dist/cjs/limel-chip_2.cjs.entry.js +2 -2
  19. package/dist/cjs/limel-circular-progress.cjs.entry.js +1 -1
  20. package/dist/cjs/limel-code-diff.cjs.entry.js +1 -1
  21. package/dist/cjs/limel-code-editor.cjs.entry.js +1 -1
  22. package/dist/cjs/limel-collapsible-section.cjs.entry.js +1 -1
  23. package/dist/cjs/limel-color-picker-palette.cjs.entry.js +1 -1
  24. package/dist/cjs/limel-color-picker.cjs.entry.js +1 -1
  25. package/dist/cjs/limel-config.cjs.entry.js +1 -1
  26. package/dist/cjs/limel-date-picker.cjs.entry.js +1 -1
  27. package/dist/cjs/limel-dialog.cjs.entry.js +1 -1
  28. package/dist/cjs/limel-dock-button.cjs.entry.js +1 -1
  29. package/dist/cjs/limel-dock.cjs.entry.js +1 -1
  30. package/dist/cjs/limel-drag-handle_2.cjs.entry.js +1 -1
  31. package/dist/cjs/limel-dynamic-label.cjs.entry.js +1 -1
  32. package/dist/cjs/limel-email-viewer.cjs.entry.js +1 -1
  33. package/dist/cjs/limel-file-dropzone_2.cjs.entry.js +1 -1
  34. package/dist/cjs/limel-file-viewer.cjs.entry.js +2 -2
  35. package/dist/cjs/limel-file.cjs.entry.js +1 -1
  36. package/dist/cjs/limel-flatpickr-adapter.cjs.entry.js +1 -1
  37. package/dist/cjs/limel-flex-container.cjs.entry.js +1 -1
  38. package/dist/cjs/limel-form-header.cjs.entry.js +1 -1
  39. package/dist/cjs/limel-form.cjs.entry.js +1 -1
  40. package/dist/cjs/limel-grid.cjs.entry.js +1 -1
  41. package/dist/cjs/limel-header.cjs.entry.js +1 -1
  42. package/dist/cjs/limel-help_2.cjs.entry.js +1 -1
  43. package/dist/cjs/limel-helper-line_3.cjs.entry.js +1 -1
  44. package/dist/cjs/limel-hotkey_4.cjs.entry.js +1 -1
  45. package/dist/cjs/limel-icon-button.cjs.entry.js +1 -1
  46. package/dist/cjs/limel-icon.cjs.entry.js +1 -1
  47. package/dist/cjs/limel-info-tile.cjs.entry.js +1 -1
  48. package/dist/cjs/limel-list-item.cjs.entry.js +4 -4
  49. package/dist/cjs/limel-markdown.cjs.entry.js +1 -1
  50. package/dist/cjs/limel-masonry-layout.cjs.entry.js +1 -1
  51. package/dist/cjs/limel-menu-item-meta.cjs.entry.js +1 -1
  52. package/dist/cjs/limel-pagination-jump.cjs.entry.js +1 -1
  53. package/dist/cjs/limel-pagination.cjs.entry.js +1 -1
  54. package/dist/cjs/limel-picker.cjs.entry.js +1 -1
  55. package/dist/cjs/limel-popover_2.cjs.entry.js +1 -1
  56. package/dist/cjs/limel-profile-picture.cjs.entry.js +2 -2
  57. package/dist/cjs/limel-progress-flow-item.cjs.entry.js +1 -1
  58. package/dist/cjs/limel-progress-flow.cjs.entry.js +1 -1
  59. package/dist/cjs/limel-prosemirror-adapter.cjs.entry.js +1 -1
  60. package/dist/cjs/limel-radio-button-group.cjs.entry.js +1 -1
  61. package/dist/cjs/limel-radio-button.cjs.entry.js +1 -1
  62. package/dist/cjs/limel-resize-handle.cjs.entry.js +1 -1
  63. package/dist/cjs/limel-select.cjs.entry.js +2 -2
  64. package/dist/cjs/limel-shortcut.cjs.entry.js +1 -1
  65. package/dist/cjs/limel-side-panel.cjs.entry.js +1 -1
  66. package/dist/cjs/limel-slider.cjs.entry.js +1 -1
  67. package/dist/cjs/limel-snackbar.cjs.entry.js +1 -1
  68. package/dist/cjs/limel-split-button.cjs.entry.js +1 -1
  69. package/dist/cjs/limel-switch.cjs.entry.js +1 -1
  70. package/dist/cjs/limel-tab-bar.cjs.entry.js +1 -1
  71. package/dist/cjs/limel-tab-panel.cjs.entry.js +1 -1
  72. package/dist/cjs/limel-table.cjs.entry.js +1 -1
  73. package/dist/cjs/limel-text-editor-link-menu.cjs.entry.js +1 -1
  74. package/dist/cjs/limel-text-editor.cjs.entry.js +1 -1
  75. package/dist/cjs/loader.cjs.js +2 -2
  76. package/dist/cjs/{render-list-component-BtAliHQp.js → render-list-component-BOYFHMFE.js} +1 -1
  77. package/dist/collection/components/chart/chart.css +29 -0
  78. package/dist/collection/components/chart/chart.js +352 -67
  79. package/dist/collection/components/chart/options.js +342 -109
  80. package/dist/collection/components/chart/scale.js +25 -2
  81. package/dist/collection/components/chart/series.js +110 -0
  82. package/dist/esm/{checkbox.template-CAja2LKZ.js → checkbox.template-BJJmiDJP.js} +1 -1
  83. package/dist/esm/{image.template-BGjw97m_.js → image.template-Cw2q5IS7.js} +1 -1
  84. package/dist/esm/{index-BU9IJqli.js → index-D3SUrFhp.js} +12 -1
  85. package/dist/esm/{keyboard-navigation-BF7IKmnG.js → keyboard-navigation-DeMxdkNf.js} +1 -1
  86. package/dist/esm/lime-elements.js +3 -3
  87. package/dist/esm/limel-3d-hover-effect-glow.entry.js +1 -1
  88. package/dist/esm/limel-action-bar_3.entry.js +1 -1
  89. package/dist/esm/limel-ai-avatar.entry.js +1 -1
  90. package/dist/esm/limel-badge_7.entry.js +1 -1
  91. package/dist/esm/limel-banner.entry.js +1 -1
  92. package/dist/esm/limel-button-group.entry.js +1 -1
  93. package/dist/esm/limel-button.entry.js +1 -1
  94. package/dist/esm/limel-callout.entry.js +1 -1
  95. package/dist/esm/limel-card.entry.js +2 -2
  96. package/dist/esm/limel-chart.entry.js +778 -175
  97. package/dist/esm/limel-checkbox.entry.js +2 -2
  98. package/dist/esm/limel-chip-set.entry.js +1 -1
  99. package/dist/esm/limel-chip_2.entry.js +2 -2
  100. package/dist/esm/limel-circular-progress.entry.js +1 -1
  101. package/dist/esm/limel-code-diff.entry.js +1 -1
  102. package/dist/esm/limel-code-editor.entry.js +1 -1
  103. package/dist/esm/limel-collapsible-section.entry.js +1 -1
  104. package/dist/esm/limel-color-picker-palette.entry.js +1 -1
  105. package/dist/esm/limel-color-picker.entry.js +1 -1
  106. package/dist/esm/limel-config.entry.js +1 -1
  107. package/dist/esm/limel-date-picker.entry.js +1 -1
  108. package/dist/esm/limel-dialog.entry.js +1 -1
  109. package/dist/esm/limel-dock-button.entry.js +1 -1
  110. package/dist/esm/limel-dock.entry.js +1 -1
  111. package/dist/esm/limel-drag-handle_2.entry.js +1 -1
  112. package/dist/esm/limel-dynamic-label.entry.js +1 -1
  113. package/dist/esm/limel-email-viewer.entry.js +1 -1
  114. package/dist/esm/limel-file-dropzone_2.entry.js +1 -1
  115. package/dist/esm/limel-file-viewer.entry.js +2 -2
  116. package/dist/esm/limel-file.entry.js +1 -1
  117. package/dist/esm/limel-flatpickr-adapter.entry.js +1 -1
  118. package/dist/esm/limel-flex-container.entry.js +1 -1
  119. package/dist/esm/limel-form-header.entry.js +1 -1
  120. package/dist/esm/limel-form.entry.js +1 -1
  121. package/dist/esm/limel-grid.entry.js +1 -1
  122. package/dist/esm/limel-header.entry.js +1 -1
  123. package/dist/esm/limel-help_2.entry.js +1 -1
  124. package/dist/esm/limel-helper-line_3.entry.js +1 -1
  125. package/dist/esm/limel-hotkey_4.entry.js +1 -1
  126. package/dist/esm/limel-icon-button.entry.js +1 -1
  127. package/dist/esm/limel-icon.entry.js +1 -1
  128. package/dist/esm/limel-info-tile.entry.js +1 -1
  129. package/dist/esm/limel-list-item.entry.js +4 -4
  130. package/dist/esm/limel-markdown.entry.js +1 -1
  131. package/dist/esm/limel-masonry-layout.entry.js +1 -1
  132. package/dist/esm/limel-menu-item-meta.entry.js +1 -1
  133. package/dist/esm/limel-pagination-jump.entry.js +1 -1
  134. package/dist/esm/limel-pagination.entry.js +1 -1
  135. package/dist/esm/limel-picker.entry.js +1 -1
  136. package/dist/esm/limel-popover_2.entry.js +1 -1
  137. package/dist/esm/limel-profile-picture.entry.js +2 -2
  138. package/dist/esm/limel-progress-flow-item.entry.js +1 -1
  139. package/dist/esm/limel-progress-flow.entry.js +1 -1
  140. package/dist/esm/limel-prosemirror-adapter.entry.js +1 -1
  141. package/dist/esm/limel-radio-button-group.entry.js +1 -1
  142. package/dist/esm/limel-radio-button.entry.js +1 -1
  143. package/dist/esm/limel-resize-handle.entry.js +1 -1
  144. package/dist/esm/limel-select.entry.js +2 -2
  145. package/dist/esm/limel-shortcut.entry.js +1 -1
  146. package/dist/esm/limel-side-panel.entry.js +1 -1
  147. package/dist/esm/limel-slider.entry.js +1 -1
  148. package/dist/esm/limel-snackbar.entry.js +1 -1
  149. package/dist/esm/limel-split-button.entry.js +1 -1
  150. package/dist/esm/limel-switch.entry.js +1 -1
  151. package/dist/esm/limel-tab-bar.entry.js +2 -2
  152. package/dist/esm/limel-tab-panel.entry.js +1 -1
  153. package/dist/esm/limel-table.entry.js +1 -1
  154. package/dist/esm/limel-text-editor-link-menu.entry.js +1 -1
  155. package/dist/esm/limel-text-editor.entry.js +1 -1
  156. package/dist/esm/loader.js +3 -3
  157. package/dist/esm/{render-list-component-J1IzNpbv.js → render-list-component-CnMNjOaj.js} +1 -1
  158. package/dist/lime-elements/lime-elements.esm.js +1 -1
  159. package/dist/lime-elements/{p-6f8305ac.entry.js → p-07961d4f.entry.js} +1 -1
  160. package/dist/lime-elements/{p-a5aa8c06.entry.js → p-099e9e1a.entry.js} +1 -1
  161. package/dist/lime-elements/{p-6567de01.entry.js → p-0dd5cb25.entry.js} +1 -1
  162. package/dist/lime-elements/{p-bfb98b0e.entry.js → p-1d57370e.entry.js} +1 -1
  163. package/dist/lime-elements/{p-391a227e.entry.js → p-1ef92aa3.entry.js} +1 -1
  164. package/dist/lime-elements/p-1eff9347.entry.js +56 -0
  165. package/dist/lime-elements/{p-d078ea89.entry.js → p-22458db2.entry.js} +1 -1
  166. package/dist/lime-elements/{p-557f0e46.entry.js → p-2520a91b.entry.js} +1 -1
  167. package/dist/lime-elements/{p-85318636.entry.js → p-25473848.entry.js} +1 -1
  168. package/dist/lime-elements/{p-51fde63a.entry.js → p-27000dfb.entry.js} +1 -1
  169. package/dist/lime-elements/{p-65199efa.entry.js → p-29800b71.entry.js} +1 -1
  170. package/dist/lime-elements/{p-4de3b35b.entry.js → p-2e1fd8c4.entry.js} +1 -1
  171. package/dist/lime-elements/{p-558a7e27.entry.js → p-2f6ee1b0.entry.js} +1 -1
  172. package/dist/lime-elements/{p-ae634a68.entry.js → p-427a3da3.entry.js} +1 -1
  173. package/dist/lime-elements/{p-46695dd3.entry.js → p-447a2633.entry.js} +1 -1
  174. package/dist/lime-elements/{p-e481fb53.entry.js → p-4c54780d.entry.js} +1 -1
  175. package/dist/lime-elements/{p-08b1bfad.entry.js → p-4f81f0b4.entry.js} +1 -1
  176. package/dist/lime-elements/{p-81c43fe9.entry.js → p-5062b51a.entry.js} +1 -1
  177. package/dist/lime-elements/{p-71ed9466.entry.js → p-5295b4c7.entry.js} +1 -1
  178. package/dist/lime-elements/{p-c63d294b.entry.js → p-5a1b7f4d.entry.js} +1 -1
  179. package/dist/lime-elements/{p-664dbc43.entry.js → p-5b9c1f8f.entry.js} +1 -1
  180. package/dist/lime-elements/{p-ce418df1.entry.js → p-5be1e9e8.entry.js} +1 -1
  181. package/dist/lime-elements/{p-da9be21e.entry.js → p-5c6589aa.entry.js} +1 -1
  182. package/dist/lime-elements/{p-c1dbad1e.entry.js → p-5e7ca1fd.entry.js} +1 -1
  183. package/dist/lime-elements/{p-083aa41f.entry.js → p-5f66e497.entry.js} +1 -1
  184. package/dist/lime-elements/{p-4bc550e5.entry.js → p-667759da.entry.js} +1 -1
  185. package/dist/lime-elements/{p-d51bf98b.entry.js → p-6a340609.entry.js} +1 -1
  186. package/dist/lime-elements/{p-e3cf45ed.entry.js → p-6d3cde2e.entry.js} +1 -1
  187. package/dist/lime-elements/{p-63f2f0b7.entry.js → p-6e529563.entry.js} +1 -1
  188. package/dist/lime-elements/{p-b6334f4b.entry.js → p-743f014f.entry.js} +1 -1
  189. package/dist/lime-elements/{p-5fcb39b8.entry.js → p-7aa034e2.entry.js} +1 -1
  190. package/dist/lime-elements/{p-507965d9.entry.js → p-7b2ec934.entry.js} +1 -1
  191. package/dist/lime-elements/p-7b99624f.entry.js +1 -0
  192. package/dist/lime-elements/{p-1c7fcafc.entry.js → p-7ea96b80.entry.js} +1 -1
  193. package/dist/lime-elements/{p-a1cd0dc0.entry.js → p-7fe1d9ad.entry.js} +1 -1
  194. package/dist/lime-elements/{p-9e5a15d1.entry.js → p-842694af.entry.js} +1 -1
  195. package/dist/lime-elements/{p-9cbfedad.entry.js → p-848aeaa6.entry.js} +1 -1
  196. package/dist/lime-elements/{p-15f5e45e.entry.js → p-868a8b12.entry.js} +1 -1
  197. package/dist/lime-elements/{p-4eee17f7.entry.js → p-891f6a07.entry.js} +1 -1
  198. package/dist/lime-elements/{p-b810b854.entry.js → p-8dcb9ef1.entry.js} +1 -1
  199. package/dist/lime-elements/{p-2a5113ef.entry.js → p-92f79a62.entry.js} +1 -1
  200. package/dist/lime-elements/{p-61c81d09.entry.js → p-93907698.entry.js} +2 -2
  201. package/dist/lime-elements/{p-718431c1.entry.js → p-9b3c7341.entry.js} +1 -1
  202. package/dist/lime-elements/{p-_1yBt1pG.js → p-BJrZuSu3.js} +1 -1
  203. package/dist/lime-elements/{p-Cadm4-WZ.js → p-BzHrLZdr.js} +1 -1
  204. package/dist/lime-elements/{p-BU9IJqli.js → p-D3SUrFhp.js} +2 -2
  205. package/dist/lime-elements/p-DpXrxCh5.js +1 -0
  206. package/dist/lime-elements/p-DwxRLqY6.js +1 -0
  207. package/dist/lime-elements/{p-3f9acb22.entry.js → p-a0501e84.entry.js} +1 -1
  208. package/dist/lime-elements/{p-3a421be9.entry.js → p-a5419b44.entry.js} +1 -1
  209. package/dist/lime-elements/{p-22aaa1ae.entry.js → p-abd612b3.entry.js} +1 -1
  210. package/dist/lime-elements/{p-c6eed240.entry.js → p-aeac9588.entry.js} +2 -2
  211. package/dist/lime-elements/p-b01e8af9.entry.js +1 -0
  212. package/dist/lime-elements/{p-f97ec7a5.entry.js → p-b08c9b52.entry.js} +1 -1
  213. package/dist/lime-elements/{p-be653ca9.entry.js → p-b1f6412e.entry.js} +1 -1
  214. package/dist/lime-elements/{p-6b6b8ffe.entry.js → p-b3967ab3.entry.js} +1 -1
  215. package/dist/lime-elements/{p-eb812303.entry.js → p-b8bfec0e.entry.js} +1 -1
  216. package/dist/lime-elements/{p-490ac19d.entry.js → p-ba4b44ad.entry.js} +1 -1
  217. package/dist/lime-elements/{p-783fd221.entry.js → p-bf726f16.entry.js} +1 -1
  218. package/dist/lime-elements/{p-1e699935.entry.js → p-c2f27d2a.entry.js} +1 -1
  219. package/dist/lime-elements/{p-271662d4.entry.js → p-c3bd19ea.entry.js} +1 -1
  220. package/dist/lime-elements/{p-8e46d111.entry.js → p-cc560bbd.entry.js} +1 -1
  221. package/dist/lime-elements/{p-e8665e99.entry.js → p-d2953c11.entry.js} +1 -1
  222. package/dist/lime-elements/{p-156ea100.entry.js → p-d3d01dd4.entry.js} +1 -1
  223. package/dist/lime-elements/{p-4b75e653.entry.js → p-d9e6175b.entry.js} +1 -1
  224. package/dist/lime-elements/{p-373032c0.entry.js → p-dab5421d.entry.js} +1 -1
  225. package/dist/lime-elements/{p-c3d1aa57.entry.js → p-dcaeefc9.entry.js} +1 -1
  226. package/dist/lime-elements/{p-1fa0fd7a.entry.js → p-df8aa135.entry.js} +1 -1
  227. package/dist/lime-elements/{p-d2f784a8.entry.js → p-e2fb2af4.entry.js} +1 -1
  228. package/dist/lime-elements/{p-c7bcae67.entry.js → p-e929fc64.entry.js} +1 -1
  229. package/dist/lime-elements/{p-3d6ba932.entry.js → p-ea02dade.entry.js} +1 -1
  230. package/dist/lime-elements/{p-0700e83f.entry.js → p-ecd633cb.entry.js} +1 -1
  231. package/dist/lime-elements/{p-c3b86df2.entry.js → p-f5cd53e8.entry.js} +1 -1
  232. package/dist/lime-elements/{p-127ff801.entry.js → p-f7cae25a.entry.js} +1 -1
  233. package/dist/types/components/chart/chart.d.ts +59 -8
  234. package/dist/types/components/chart/chart.types.d.ts +23 -0
  235. package/dist/types/components/chart/options.d.ts +83 -8
  236. package/dist/types/components/chart/scale.d.ts +10 -0
  237. package/dist/types/components/chart/series.d.ts +71 -0
  238. package/dist/types/components.d.ts +42 -15
  239. package/package.json +2 -2
  240. package/dist/lime-elements/p-2d698983.entry.js +0 -1
  241. package/dist/lime-elements/p-391305a7.entry.js +0 -56
  242. package/dist/lime-elements/p-N9vxZMhe.js +0 -1
  243. package/dist/lime-elements/p-bb45a5bb.entry.js +0 -1
  244. package/dist/lime-elements/p-eF09GxA_.js +0 -1
@@ -0,0 +1,56 @@
1
+ import{r as t,c as n,h as i,H as r,f as e,a}from"./p-D3SUrFhp.js";import{g as o,t as u}from"./p--i932i_D.js";import{i as s,f as l,a as f,N as h}from"./p-BJrZuSu3.js";import"./p-DQ5DmW_Y.js";
2
+ /*! *****************************************************************************
3
+ Copyright (c) Microsoft Corporation.
4
+
5
+ Permission to use, copy, modify, and/or distribute this software for any
6
+ purpose with or without fee is hereby granted.
7
+
8
+ THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
9
+ REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
10
+ AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
11
+ INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
12
+ LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
13
+ OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
14
+ PERFORMANCE OF THIS SOFTWARE.
15
+ ***************************************************************************** */var c=function(t,n){return c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,n){t.__proto__=n}||function(t,n){for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(t[i]=n[i])},c(t,n)};function v(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function i(){this.constructor=t}c(t,n),t.prototype=null===n?Object.create(n):(i.prototype=n.prototype,new i)}var d,p,m="sans-serif",y="12px "+m,g=function(t){var n={};if("undefined"==typeof JSON)return n;for(var i=0;i<95;i++){var r=String.fromCharCode(i+32),e=(t.charCodeAt(i)-20)/100;n[r]=e}return n}("007LLmW'55;N0500LLLLLLLLLL00NNNLzWW\\\\WQb\\0FWLg\\bWb\\WQ\\WrWWQ000CL5LLFLL0LL**F*gLLLL5F0LF\\FFF5.5N"),b={createCanvas:function(){return"undefined"!=typeof document&&document.createElement("canvas")},measureText:function(t,n){if(!d){var i=b.createCanvas();d=i&&i.getContext("2d")}if(d)return p!==n&&(p=d.font=n||y),d.measureText(t);t=t||"";var r=/((?:\d+)?\.?\d*)px/.exec(n=n||y),e=r&&+r[1]||12,a=0;if(n.indexOf("mono")>=0)a=e*t.length;else for(var o=0;o<t.length;o++){var u=g[t[o]];a+=null==u?e:u*e}return{width:a}},loadImage:function(t,n,i){var r=new Image;return r.onload=n,r.onerror=i,r.src=t,r},getTime:function(){return Date.now?Date.now():+new Date}},w=V(["Function","RegExp","Date","Error","CanvasGradient","CanvasPattern","Image","Canvas"],(function(t,n){return t["[object "+n+"]"]=!0,t}),{}),x=V(["Int8","Uint8","Uint8Clamped","Int16","Uint16","Int32","Uint32","Float32","Float64"],(function(t,n){return t["[object "+n+"Array]"]=!0,t}),{}),M=Object.prototype.toString,k=Array.prototype,S=k.forEach,A=k.filter,T=k.slice,N=k.map,C=function(){}.constructor,O=C?C.prototype:null,I="__proto__",L=2311,D=Math.pow(2,53)-1;function _(){return L>=D&&(L=0),L++}function z(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];"undefined"!=typeof console&&console.error.apply(console,t)}function R(t){if(null==t||"object"!=typeof t)return t;var n=t,i=M.call(t);if("[object Array]"===i){if(!pt(t)){n=[];for(var r=0,e=t.length;r<e;r++)n[r]=R(t[r])}}else if(x[i]){if(!pt(t)){var a=t.constructor;if(a.from)n=a.from(t);else for(n=new a(t.length),r=0,e=t.length;r<e;r++)n[r]=t[r]}}else if(!w[i]&&!pt(t)&&!rt(t))for(var o in n={},t)t.hasOwnProperty(o)&&o!==I&&(n[o]=R(t[o]));return n}function F(t,n,i){if(!tt(n)||!tt(t))return i?R(n):t;for(var r in n)if(n.hasOwnProperty(r)&&r!==I){var e=t[r],a=n[r];!tt(a)||!tt(e)||G(a)||G(e)||rt(a)||rt(e)||nt(a)||nt(e)||pt(a)||pt(e)?!i&&r in t||(t[r]=R(n[r])):F(e,a,i)}return t}function P(t,n){if(Object.assign)Object.assign(t,n);else for(var i in n)n.hasOwnProperty(i)&&i!==I&&(t[i]=n[i]);return t}function B(t,n){for(var i=Y(n),r=0,e=i.length;r<e;r++){var a=i[r];null==t[a]&&(t[a]=n[a])}return t}function E(t,n){if(t){if(t.indexOf)return t.indexOf(n);for(var i=0,r=t.length;i<r;i++)if(t[i]===n)return i}return-1}function W(t,n){if(t="prototype"in t?t.prototype:t,n="prototype"in n?n.prototype:n,Object.getOwnPropertyNames)for(var i=Object.getOwnPropertyNames(n),r=0;r<i.length;r++){var e=i[r];"constructor"!==e&&null==t[e]&&(t[e]=n[e])}else B(t,n)}function j(t){return!!t&&"string"!=typeof t&&"number"==typeof t.length}function H(t,n,i){if(t&&n)if(t.forEach&&t.forEach===S)t.forEach(n,i);else if(t.length===+t.length)for(var r=0,e=t.length;r<e;r++)n.call(i,t[r],r,t);else for(var a in t)t.hasOwnProperty(a)&&n.call(i,t[a],a,t)}function U(t,n,i){if(!t)return[];if(!n)return lt(t);if(t.map&&t.map===N)return t.map(n,i);for(var r=[],e=0,a=t.length;e<a;e++)r.push(n.call(i,t[e],e,t));return r}function V(t,n,i,r){if(t&&n){for(var e=0,a=t.length;e<a;e++)i=n.call(r,i,t[e],e,t);return i}}function $(t,n,i){if(!t)return[];if(!n)return lt(t);if(t.filter&&t.filter===A)return t.filter(n,i);for(var r=[],e=0,a=t.length;e<a;e++)n.call(i,t[e],e,t)&&r.push(t[e]);return r}function Y(t){if(!t)return[];if(Object.keys)return Object.keys(t);var n=[];for(var i in t)t.hasOwnProperty(i)&&n.push(i);return n}var X=O&&Z(O.bind)?O.call.bind(O.bind):function(t,n){for(var i=[],r=2;r<arguments.length;r++)i[r-2]=arguments[r];return function(){return t.apply(n,i.concat(T.call(arguments)))}};function q(t){for(var n=[],i=1;i<arguments.length;i++)n[i-1]=arguments[i];return function(){return t.apply(this,n.concat(T.call(arguments)))}}function G(t){return Array.isArray?Array.isArray(t):"[object Array]"===M.call(t)}function Z(t){return"function"==typeof t}function J(t){return"string"==typeof t}function K(t){return"[object String]"===M.call(t)}function Q(t){return"number"==typeof t}function tt(t){var n=typeof t;return"function"===n||!!t&&"object"===n}function nt(t){return!!w[M.call(t)]}function it(t){return!!x[M.call(t)]}function rt(t){return"object"==typeof t&&"number"==typeof t.nodeType&&"object"==typeof t.ownerDocument}function et(t){return null!=t.colorStops}function at(t){return t!=t}function ot(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];for(var i=0,r=t.length;i<r;i++)if(null!=t[i])return t[i]}function ut(t,n){return null!=t?t:n}function st(t,n,i){return null!=t?t:null!=n?n:i}function lt(t){for(var n=[],i=1;i<arguments.length;i++)n[i-1]=arguments[i];return T.apply(t,n)}function ft(t){if("number"==typeof t)return[t,t,t,t];var n=t.length;return 2===n?[t[0],t[1],t[0],t[1]]:3===n?[t[0],t[1],t[2],t[1]]:t}function ht(t,n){if(!t)throw new Error(n)}function ct(t){return null==t?null:"function"==typeof t.trim?t.trim():t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")}var vt="__ec_primitive__";function dt(t){t[vt]=!0}function pt(t){return t[vt]}var mt=function(){function t(){this.data={}}return t.prototype.delete=function(t){var n=this.has(t);return n&&delete this.data[t],n},t.prototype.has=function(t){return this.data.hasOwnProperty(t)},t.prototype.get=function(t){return this.data[t]},t.prototype.set=function(t,n){return this.data[t]=n,this},t.prototype.keys=function(){return Y(this.data)},t.prototype.forEach=function(t){var n=this.data;for(var i in n)n.hasOwnProperty(i)&&t(n[i],i)},t}(),yt="function"==typeof Map,gt=function(){function t(n){var i=G(n);this.data=yt?new Map:new mt;var r=this;function e(t,n){i?r.set(t,n):r.set(n,t)}n instanceof t?n.each(e):n&&H(n,e)}return t.prototype.hasKey=function(t){return this.data.has(t)},t.prototype.get=function(t){return this.data.get(t)},t.prototype.set=function(t,n){return this.data.set(t,n),n},t.prototype.each=function(t,n){this.data.forEach((function(i,r){t.call(n,i,r)}))},t.prototype.keys=function(){var t=this.data.keys();return yt?Array.from(t):t},t.prototype.removeKey=function(t){this.data.delete(t)},t}();function bt(t){return new gt(t)}function wt(t,n){var i;if(Object.create)i=Object.create(t);else{var r=function(){};r.prototype=t,i=new r}return n&&P(i,n),i}function xt(t,n){return t.hasOwnProperty(n)}function Mt(){}var kt=180/Math.PI,St=function(){this.firefox=!1,this.ie=!1,this.edge=!1,this.newEdge=!1,this.weChat=!1},At=new function(){this.browser=new St,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="undefined"!=typeof window};"object"==typeof wx&&"function"==typeof wx.getSystemInfoSync?(At.wxa=!0,At.touchEventsSupported=!0):"undefined"==typeof document&&"undefined"!=typeof self?At.worker=!0:!At.hasGlobalWindow||"Deno"in window||"undefined"!=typeof navigator&&"string"==typeof navigator.userAgent&&navigator.userAgent.indexOf("Node.js")>-1?(At.node=!0,At.svgSupported=!0):function(t,n){var i=n.browser,r=t.match(/Firefox\/([\d.]+)/),e=t.match(/MSIE\s([\d.]+)/)||t.match(/Trident\/.+?rv:(([\d.]+))/),a=t.match(/Edge?\/([\d.]+)/),o=/micromessenger/i.test(t);if(r&&(i.firefox=!0,i.version=r[1]),e&&(i.ie=!0,i.version=e[1]),a&&(i.edge=!0,i.version=a[1],i.newEdge=+a[1].split(".")[0]>18),o&&(i.weChat=!0),n.svgSupported="undefined"!=typeof SVGRect,n.touchEventsSupported="ontouchstart"in window&&!i.ie&&!i.edge,n.pointerEventsSupported="onpointerdown"in window&&(i.edge||i.ie&&+i.version>=11),n.domSupported="undefined"!=typeof document){var u=document.documentElement.style;n.transform3dSupported=(i.ie&&"transition"in u||i.edge||"WebKitCSSMatrix"in window&&"m11"in new WebKitCSSMatrix||"MozPerspective"in u)&&!("OTransition"in u),n.transformSupported=n.transform3dSupported||i.ie&&+i.version>=9}}(navigator.userAgent,At);var Tt="___EC__COMPONENT__CONTAINER___",Nt="___EC__EXTENDED_CLASS___";function Ct(t){var n={main:"",sub:""};if(t){var i=t.split(".");n.main=i[0]||"",n.sub=i[1]||""}return n}function Ot(t){t.$constructor=t,t.extend=function(t){var n,i,r=this;return Z(i=r)&&/^class\s/.test(Function.prototype.toString.call(i))?n=function(t){function n(){return t.apply(this,arguments)||this}return v(n,t),n}(r):(n=function(){(t.$constructor||r).apply(this,arguments)},function(t,n){var i=t.prototype;function r(){}for(var e in r.prototype=n.prototype,t.prototype=new r,i)i.hasOwnProperty(e)&&(t.prototype[e]=i[e]);t.prototype.constructor=t,t.superClass=n}(n,this)),P(n.prototype,t),n[Nt]=!0,n.extend=this.extend,n.superCall=Dt,n.superApply=_t,n.superClass=r,n}}function It(t,n){t.extend=n.extend}var Lt=Math.round(10*Math.random());function Dt(t,n){for(var i=[],r=2;r<arguments.length;r++)i[r-2]=arguments[r];return this.superClass.prototype[n].apply(t,i)}function _t(t,n,i){return this.superClass.prototype[n].apply(t,i)}function zt(t){var n={};t.registerClass=function(t){var i,r=t.type||t.prototype.type;if(r){ht(/^[a-zA-Z0-9_]+([.][a-zA-Z0-9_]+)?$/.test(i=r),'componentType "'+i+'" illegal'),t.prototype.type=r;var e=Ct(r);if(e.sub){if(e.sub!==Tt){var a=function(t){var i=n[t.main];return i&&i[Tt]||((i=n[t.main]={})[Tt]=!0),i}(e);a[e.sub]=t}}else n[e.main]=t}return t},t.getClass=function(t,i,r){var e=n[t];if(e&&e[Tt]&&(e=i?e[i]:null),r&&!e)throw new Error(i?"Component "+t+"."+(i||"")+" is used but not imported.":t+".type should be specified.");return e},t.getClassesByMainType=function(t){var i=Ct(t),r=[],e=n[i.main];return e&&e[Tt]?H(e,(function(t,n){n!==Tt&&r.push(t)})):r.push(e),r},t.hasClass=function(t){var i=Ct(t);return!!n[i.main]},t.getAllClassMainTypes=function(){var t=[];return H(n,(function(n,i){t.push(i)})),t},t.hasSubTypes=function(t){var i=Ct(t),r=n[i.main];return r&&r[Tt]}}function Rt(t,n){for(var i=0;i<t.length;i++)t[i][1]||(t[i][1]=t[i][0]);return n=n||!1,function(i,r,e){for(var a={},o=0;o<t.length;o++){var u=t[o][1];if(!(r&&E(r,u)>=0||e&&E(e,u)<0)){var s=i.getShallow(u,n);null!=s&&(a[t[o][0]]=s)}}return a}}var Ft=Rt([["fill","color"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["opacity"],["shadowColor"]]),Pt=function(){function t(){}return t.prototype.getAreaStyle=function(t,n){return Ft(this,t,n)},t}(),Bt=function(t,n){return Bt=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,n){t.__proto__=n}||function(t,n){for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(t[i]=n[i])},Bt(t,n)};function Et(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function i(){this.constructor=t}Bt(t,n),t.prototype=null===n?Object.create(n):(i.prototype=n.prototype,new i)}var Wt=function(t){this.value=t},jt=function(){function t(){this._len=0}return t.prototype.insert=function(t){var n=new Wt(t);return this.insertEntry(n),n},t.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++},t.prototype.remove=function(t){var n=t.prev,i=t.next;n?n.next=i:this.head=i,i?i.prev=n:this.tail=n,t.next=t.prev=null,this._len--},t.prototype.len=function(){return this._len},t.prototype.clear=function(){this.head=this.tail=null,this._len=0},t}(),Ht=function(){function t(t){this._list=new jt,this._maxSize=10,this._map={},this._maxSize=t}return t.prototype.put=function(t,n){var i=this._list,r=this._map,e=null;if(null==r[t]){var a=i.len(),o=this._lastRemovedEntry;if(a>=this._maxSize&&a>0){var u=i.head;i.remove(u),delete r[u.key],e=u.value,this._lastRemovedEntry=u}o?o.value=n:o=new Wt(n),o.key=t,i.insertEntry(o),r[t]=o}return e},t.prototype.get=function(t){var n=this._map[t],i=this._list;if(null!=n)return n!==i.tail&&(i.remove(n),i.insertEntry(n)),n.value},t.prototype.clear=function(){this._list.clear(),this._map={}},t.prototype.len=function(){return this._list.len()},t}(),Ut=new Ht(50);function Vt(t){if("string"==typeof t){var n=Ut.get(t);return n&&n.image}return t}function $t(t,n,i,r,e){if(t){if("string"==typeof t){if(n&&n.__zrImageSrc===t||!i)return n;var a=Ut.get(t),o={hostEl:i,cb:r,cbPayload:e};return a?!Xt(n=a.image)&&a.pending.push(o):((n=b.loadImage(t,Yt,Yt)).__zrImageSrc=t,Ut.put(t,n.__cachedImgObj={image:n,pending:[o]})),n}return t}return n}function Yt(){var t=this.__cachedImgObj;this.onload=this.onerror=this.__cachedImgObj=null;for(var n=0;n<t.pending.length;n++){var i=t.pending[n],r=i.cb;r&&r(this,i.cbPayload),i.hostEl.dirty()}t.pending.length=0}function Xt(t){return t&&t.width&&t.height}function qt(t){return t[0]=1,t[1]=0,t[2]=0,t[3]=1,t[4]=0,t[5]=0,t}function Gt(t,n){return t[0]=n[0],t[1]=n[1],t[2]=n[2],t[3]=n[3],t[4]=n[4],t[5]=n[5],t}function Zt(t,n,i){var r=n[1]*i[0]+n[3]*i[1],e=n[0]*i[2]+n[2]*i[3],a=n[1]*i[2]+n[3]*i[3],o=n[0]*i[4]+n[2]*i[5]+n[4],u=n[1]*i[4]+n[3]*i[5]+n[5];return t[0]=n[0]*i[0]+n[2]*i[1],t[1]=r,t[2]=e,t[3]=a,t[4]=o,t[5]=u,t}function Jt(t,n,i){return t[0]=n[0],t[1]=n[1],t[2]=n[2],t[3]=n[3],t[4]=n[4]+i[0],t[5]=n[5]+i[1],t}function Kt(t,n,i,r){void 0===r&&(r=[0,0]);var e=n[0],a=n[2],o=n[4],u=n[1],s=n[3],l=n[5],f=Math.sin(i),h=Math.cos(i);return t[0]=e*h+u*f,t[1]=-e*f+u*h,t[2]=a*h+s*f,t[3]=-a*f+h*s,t[4]=h*(o-r[0])+f*(l-r[1])+r[0],t[5]=h*(l-r[1])-f*(o-r[0])+r[1],t}function Qt(t,n){var i=n[0],r=n[2],e=n[4],a=n[1],o=n[3],u=n[5],s=i*o-a*r;return s?(t[0]=o*(s=1/s),t[1]=-a*s,t[2]=-r*s,t[3]=i*s,t[4]=(r*u-o*e)*s,t[5]=(a*e-i*u)*s,t):null}function tn(t,n){return null==t&&(t=0),null==n&&(n=0),[t,n]}function nn(t){return[t[0],t[1]]}function rn(t,n,i){return t[0]=n,t[1]=i,t}function en(t,n,i){return t[0]=n[0]+i[0],t[1]=n[1]+i[1],t}function an(t,n,i){return t[0]=n[0]-i[0],t[1]=n[1]-i[1],t}function on(t,n,i){return t[0]=n[0]*i,t[1]=n[1]*i,t}function un(t,n){return Math.sqrt((t[0]-n[0])*(t[0]-n[0])+(t[1]-n[1])*(t[1]-n[1]))}var sn=un,ln=function(t,n){return(t[0]-n[0])*(t[0]-n[0])+(t[1]-n[1])*(t[1]-n[1])};function fn(t,n,i,r){return t[0]=n[0]+r*(i[0]-n[0]),t[1]=n[1]+r*(i[1]-n[1]),t}function hn(t,n,i){var r=n[0],e=n[1];return t[0]=i[0]*r+i[2]*e+i[4],t[1]=i[1]*r+i[3]*e+i[5],t}function cn(t,n,i){return t[0]=Math.min(n[0],i[0]),t[1]=Math.min(n[1],i[1]),t}function vn(t,n,i){return t[0]=Math.max(n[0],i[0]),t[1]=Math.max(n[1],i[1]),t}var dn,pn=function(){function t(t,n){this.x=t||0,this.y=n||0}return t.prototype.copy=function(t){return this.x=t.x,this.y=t.y,this},t.prototype.clone=function(){return new t(this.x,this.y)},t.prototype.set=function(t,n){return this.x=t,this.y=n,this},t.prototype.equal=function(t){return t.x===this.x&&t.y===this.y},t.prototype.add=function(t){return this.x+=t.x,this.y+=t.y,this},t.prototype.scale=function(t){this.x*=t,this.y*=t},t.prototype.scaleAndAdd=function(t,n){this.x+=t.x*n,this.y+=t.y*n},t.prototype.sub=function(t){return this.x-=t.x,this.y-=t.y,this},t.prototype.dot=function(t){return this.x*t.x+this.y*t.y},t.prototype.len=function(){return Math.sqrt(this.x*this.x+this.y*this.y)},t.prototype.lenSquare=function(){return this.x*this.x+this.y*this.y},t.prototype.normalize=function(){var t=this.len();return this.x/=t,this.y/=t,this},t.prototype.distance=function(t){var n=this.x-t.x,i=this.y-t.y;return Math.sqrt(n*n+i*i)},t.prototype.distanceSquare=function(t){var n=this.x-t.x,i=this.y-t.y;return n*n+i*i},t.prototype.negate=function(){return this.x=-this.x,this.y=-this.y,this},t.prototype.transform=function(t){if(t){var n=this.x,i=this.y;return this.x=t[0]*n+t[2]*i+t[4],this.y=t[1]*n+t[3]*i+t[5],this}},t.prototype.toArray=function(t){return t[0]=this.x,t[1]=this.y,t},t.prototype.fromArray=function(t){this.x=t[0],this.y=t[1]},t.set=function(t,n,i){t.x=n,t.y=i},t.copy=function(t,n){t.x=n.x,t.y=n.y},t.len=function(t){return Math.sqrt(t.x*t.x+t.y*t.y)},t.lenSquare=function(t){return t.x*t.x+t.y*t.y},t.dot=function(t,n){return t.x*n.x+t.y*n.y},t.add=function(t,n,i){t.x=n.x+i.x,t.y=n.y+i.y},t.sub=function(t,n,i){t.x=n.x-i.x,t.y=n.y-i.y},t.scale=function(t,n,i){t.x=n.x*i,t.y=n.y*i},t.scaleAndAdd=function(t,n,i,r){t.x=n.x+i.x*r,t.y=n.y+i.y*r},t.lerp=function(t,n,i,r){var e=1-r;t.x=e*n.x+r*i.x,t.y=e*n.y+r*i.y},t}(),mn=Math.min,yn=Math.max,gn=Math.abs,bn=["x","y"],wn=["width","height"],xn=new pn,Mn=new pn,kn=new pn,Sn=new pn,An=Pn(),Tn=An.minTv,Nn=An.maxTv,Cn=[0,0],On=function(){function t(t,n,i,r){In(this,t,n,i,r)}return t.set=function(t,n,i,r,e){return r<0&&(n+=r,r=-r),e<0&&(i+=e,e=-e),t.x=n,t.y=i,t.width=r,t.height=e,t},t.prototype.union=function(t){var n=mn(t.x,this.x),i=mn(t.y,this.y);this.width=isFinite(this.x)&&isFinite(this.width)?yn(t.x+t.width,this.x+this.width)-n:t.width,this.height=isFinite(this.y)&&isFinite(this.height)?yn(t.y+t.height,this.y+this.height)-i:t.height,this.x=n,this.y=i},t.prototype.applyTransform=function(n){t.applyTransform(this,this,n)},t.prototype.calculateTransform=function(t){return Dn([1,0,0,1,0,0],this,t)},t.prototype.intersect=function(n,i,r){return t.intersect(this,n,i,r)},t.intersect=function(n,i,r,e){r&&pn.set(r,0,0);var a=e&&e.outIntersectRect||null,o=e&&e.clamp;if(a&&(a.x=a.y=a.width=a.height=NaN),!n||!i)return!1;n instanceof t||(n=In(_n,n.x,n.y,n.width,n.height)),i instanceof t||(i=In(zn,i.x,i.y,i.width,i.height));var u=!!r;An.reset(e,u);var s=An.touchThreshold,l=n.x+s,f=n.x+n.width-s,h=n.y+s,c=n.y+n.height-s,v=i.x+s,d=i.x+i.width-s,p=i.y+s,m=i.y+i.height-s;if(l>f||h>c||v>d||p>m)return!1;var y=!(f<v||d<l||c<p||m<h);return(u||a)&&(Cn[0]=1/0,Cn[1]=0,Fn(l,f,v,d,0,u,a,o),Fn(h,c,p,m,1,u,a,o),u&&pn.copy(r,y?An.useDir?An.dirMinTv:Tn:Nn)),y},t.contain=function(t,n,i){return n>=t.x&&n<=t.x+t.width&&i>=t.y&&i<=t.y+t.height},t.prototype.contain=function(n,i){return t.contain(this,n,i)},t.prototype.clone=function(){return new t(this.x,this.y,this.width,this.height)},t.prototype.copy=function(t){Ln(this,t)},t.prototype.plain=function(){return{x:this.x,y:this.y,width:this.width,height:this.height}},t.prototype.isFinite=function(){return isFinite(this.x)&&isFinite(this.y)&&isFinite(this.width)&&isFinite(this.height)},t.prototype.isZero=function(){return 0===this.width||0===this.height},t.create=function(n){return new t(n?n.x:0,n?n.y:0,n?n.width:0,n?n.height:0)},t.copy=function(t,n){return t.x=n.x,t.y=n.y,t.width=n.width,t.height=n.height,t},t.applyTransform=function(t,n,i){if(i){if(i[1]<1e-5&&i[1]>-1e-5&&i[2]<1e-5&&i[2]>-1e-5){var r=i[0],e=i[3],a=i[5];return t.x=n.x*r+i[4],t.y=n.y*e+a,t.width=n.width*r,t.height=n.height*e,t.width<0&&(t.x+=t.width,t.width=-t.width),void(t.height<0&&(t.y+=t.height,t.height=-t.height))}xn.x=kn.x=n.x,xn.y=Sn.y=n.y,Mn.x=Sn.x=n.x+n.width,Mn.y=kn.y=n.y+n.height,xn.transform(i),Sn.transform(i),Mn.transform(i),kn.transform(i),t.x=mn(xn.x,Mn.x,kn.x,Sn.x),t.y=mn(xn.y,Mn.y,kn.y,Sn.y);var o=yn(xn.x,Mn.x,kn.x,Sn.x),u=yn(xn.y,Mn.y,kn.y,Sn.y);t.width=o-t.x,t.height=u-t.y}else t!==n&&Ln(t,n)},t.calculateTransform=function(t,n,i){var r=i.width/n.width,e=i.height/n.height;return Jt(t=qt(t||[]),t,rn(Rn,-n.x,-n.y)),function(t,n,i){var r=i[0],e=i[1];t[0]=n[0]*r,t[1]=n[1]*e,t[2]=n[2]*r,t[3]=n[3]*e,t[4]=n[4]*r,t[5]=n[5]*e}(t,t,rn(Rn,r,e)),Jt(t,t,rn(Rn,i.x,i.y)),t},t}(),In=On.set,Ln=On.copy,Dn=On.calculateTransform,_n=new On(0,0,0,0),zn=new On(0,0,0,0),Rn=[];function Fn(t,n,i,r,e,a,o,u){var s=gn(n-i),l=gn(r-t),f=mn(s,l),h=bn[e],c=bn[1-e],v=wn[e];n<i||r<t?s<l?(a&&(Nn[h]=-s),u&&(o[h]=n,o[v]=0)):(a&&(Nn[h]=l),u&&(o[h]=t,o[v]=0)):(o&&(o[h]=yn(t,i),o[v]=mn(n,r)-o[h]),a&&(f<Cn[0]||An.useDir)&&(Cn[0]=mn(f,Cn[0]),(s<l||!An.bidirectional)&&(Tn[h]=s,Tn[c]=0,An.useDir&&An.calcDirMTV()),(s>=l||!An.bidirectional)&&(Tn[h]=-l,Tn[c]=0,An.useDir&&An.calcDirMTV())))}function Pn(){var t=0,n=new pn,i=new pn,r={minTv:new pn,maxTv:new pn,useDir:!1,dirMinTv:new pn,touchThreshold:0,bidirectional:!0,negativeSize:!1,reset:function(e,a){r.touchThreshold=0,e&&null!=e.touchThreshold&&(r.touchThreshold=yn(0,e.touchThreshold)),r.negativeSize=!1,a&&(r.minTv.set(1/0,1/0),r.maxTv.set(0,0),r.useDir=!1,e&&null!=e.direction&&(r.useDir=!0,r.dirMinTv.copy(r.minTv),i.copy(r.minTv),t=e.direction,r.bidirectional=null==e.bidirectional||!!e.bidirectional,r.bidirectional||n.set(Math.cos(t),Math.sin(t))))},calcDirMTV:function(){var a=r.minTv,o=r.dirMinTv,u=a.y*a.y+a.x*a.x,s=Math.sin(t),l=Math.cos(t),f=s*a.y+l*a.x;e(f)?e(a.x)&&e(a.y)&&o.set(0,0):(i.x=u*l/f,i.y=u*s/f,e(i.x)&&e(i.y)?o.set(0,0):(r.bidirectional||n.dot(i)>0)&&i.len()<o.len()&&o.copy(i))}};function e(t){return gn(t)<1e-10}return r}function Bn(t){dn||(dn=new Ht(100));var n=dn.get(t=t||y);return n||(n={font:t,strWidthCache:new Ht(500),asciiWidthMap:null,asciiWidthMapTried:!1,stWideCharWidth:b.measureText("国",t).width,asciiCharWidth:b.measureText("a",t).width},dn.put(t,n)),n}var En=0;function Wn(t,n){return t.asciiWidthMapTried||(t.asciiWidthMap=function(t){if(!(En>=5)){t=t||y;for(var n=[],i=+new Date,r=0;r<=127;r++)n[r]=b.measureText(String.fromCharCode(r),t).width;var e=+new Date-i;return e>16?En=5:e>2&&En++,n}}(t.font),t.asciiWidthMapTried=!0),0<=n&&n<=127?null!=t.asciiWidthMap?t.asciiWidthMap[n]:t.asciiCharWidth:t.stWideCharWidth}function jn(t,n){var i=t.strWidthCache,r=i.get(n);return null==r&&(r=b.measureText(n,t.font).width,i.put(n,r)),r}function Hn(t,n,i,r){var e=jn(Bn(n),t),a=Yn(n),o=Vn(0,e,i),u=$n(0,a,r);return new On(o,u,e,a)}function Un(t,n,i,r){var e=((t||"")+"").split("\n");if(1===e.length)return Hn(e[0],n,i,r);for(var a=new On(0,0,0,0),o=0;o<e.length;o++){var u=Hn(e[o],n,i,r);0===o?a.copy(u):a.union(u)}return a}function Vn(t,n,i,r){return"right"===i?r?t+=n:t-=n:"center"===i&&(r?t+=n/2:t-=n/2),t}function $n(t,n,i,r){return"middle"===i?r?t+=n/2:t-=n/2:"bottom"===i&&(r?t+=n:t-=n),t}function Yn(t){return Bn(t).stWideCharWidth}function Xn(t,n){return"string"==typeof t?t.lastIndexOf("%")>=0?parseFloat(t)/100*n:parseFloat(t):t}function qn(t,n,i){var r=n.position||"inside",e=null!=n.distance?n.distance:5,a=i.height,o=i.width,u=a/2,s=i.x,l=i.y,f="left",h="top";if(r instanceof Array)s+=Xn(r[0],i.width),l+=Xn(r[1],i.height),f=null,h=null;else switch(r){case"left":s-=e,l+=u,f="right",h="middle";break;case"right":s+=e+o,l+=u,h="middle";break;case"top":s+=o/2,l-=e,f="center",h="bottom";break;case"bottom":s+=o/2,l+=a+e,f="center";break;case"inside":s+=o/2,l+=u,f="center",h="middle";break;case"insideLeft":s+=e,l+=u,h="middle";break;case"insideRight":s+=o-e,l+=u,f="right",h="middle";break;case"insideTop":s+=o/2,l+=e,f="center";break;case"insideBottom":s+=o/2,l+=a-e,f="center",h="bottom";break;case"insideTopLeft":s+=e,l+=e;break;case"insideTopRight":s+=o-e,l+=e,f="right";break;case"insideBottomLeft":s+=e,l+=a-e,h="bottom";break;case"insideBottomRight":s+=o-e,l+=a-e,f="right",h="bottom"}return(t=t||{}).x=s,t.y=l,t.align=f,t.verticalAlign=h,t}var Gn=/\{([a-zA-Z0-9_]+)\|([^}]*)\}/g;function Zn(t,n,i,r,e,a){if(!i)return t.text="",void(t.isTruncated=!1);var o=(n+"").split("\n");a=Jn(i,r,e,a);for(var u=!1,s={},l=0,f=o.length;l<f;l++)Kn(s,o[l],a),o[l]=s.textLine,u=u||s.isTruncated;t.text=o.join("\n"),t.isTruncated=u}function Jn(t,n,i,r){var e=P({},r=r||{});i=ut(i,"..."),e.maxIterations=ut(r.maxIterations,2);var a=e.minChar=ut(r.minChar,0),o=e.fontMeasureInfo=Bn(n),u=o.asciiCharWidth;e.placeholder=ut(r.placeholder,"");for(var s=t=Math.max(0,t-1),l=0;l<a&&s>=u;l++)s-=u;var f=jn(o,i);return f>s&&(i="",f=0),s=t-f,e.ellipsis=i,e.ellipsisWidth=f,e.contentWidth=s,e.containerWidth=t,e}function Kn(t,n,i){var r=i.containerWidth,e=i.contentWidth,a=i.fontMeasureInfo;if(!r)return t.textLine="",void(t.isTruncated=!1);var o=jn(a,n);if(o<=r)return t.textLine=n,void(t.isTruncated=!1);for(var u=0;;u++){if(o<=e||u>=i.maxIterations){n+=i.ellipsis;break}var s=0===u?Qn(n,e,a):o>0?Math.floor(n.length*e/o):0;o=jn(a,n=n.substr(0,s))}""===n&&(n=i.placeholder),t.textLine=n,t.isTruncated=!0}function Qn(t,n,i){for(var r=0,e=0,a=t.length;e<a&&r<n;e++)r+=Wn(i,t.charCodeAt(e));return e}var ti=function(){},ni=function(t){this.tokens=[],t&&(this.tokens=t)},ii=function(){this.width=0,this.height=0,this.contentWidth=0,this.contentHeight=0,this.outerWidth=0,this.outerHeight=0,this.lines=[],this.isTruncated=!1};function ri(t,n,i,r,e){var a,o,u=""===n,s=e&&i.rich[e]||{},l=t.lines,f=s.font||i.font,h=!1;if(r){var c=s.padding,v=c?c[1]+c[3]:0;if(null!=s.width&&"auto"!==s.width){var d=Xn(s.width,r.width)+v;l.length>0&&d+r.accumWidth>r.width&&(a=n.split("\n"),h=!0),r.accumWidth=d}else{var p=oi(n,f,r.width,r.breakAll,r.accumWidth);r.accumWidth=p.accumWidth+v,o=p.linesWidths,a=p.lines}}a||(a=n.split("\n"));for(var m=Bn(f),y=0;y<a.length;y++){var g=a[y],b=new ti;if(b.styleName=e,b.text=g,b.isLineHolder=!g&&!u,b.width="number"==typeof s.width?s.width:o?o[y]:jn(m,g),y||h)l.push(new ni([b]));else{var w=(l[l.length-1]||(l[0]=new ni)).tokens,x=w.length;1===x&&w[0].isLineHolder?w[0]=b:(g||!x||u)&&w.push(b)}}}var ei=V(",&?/;] ".split(""),(function(t,n){return t[n]=!0,t}),{});function ai(t){return!function(t){var n=t.charCodeAt(0);return n>=32&&n<=591||n>=880&&n<=4351||n>=4608&&n<=5119||n>=7680&&n<=8303}(t)||!!ei[t]}function oi(t,n,i,r,e){for(var a=[],o=[],u="",s="",l=0,f=0,h=Bn(n),c=0;c<t.length;c++){var v=t.charAt(c);if("\n"!==v){var d=Wn(h,v.charCodeAt(0)),p=!r&&!ai(v);(a.length?f+d>i:e+f+d>i)?f?(u||s)&&(p?(u||(u=s,s="",f=l=0),a.push(u),o.push(f-l),s+=v,u="",f=l+=d):(s&&(u+=s,s="",l=0),a.push(u),o.push(f),u=v,f=d)):p?(a.push(s),o.push(l),s=v,l=d):(a.push(v),o.push(d)):(f+=d,p?(s+=v,l+=d):(s&&(u+=s,s="",l=0),u+=v))}else s&&(u+=s,f+=l),a.push(u),o.push(f),u="",s="",l=0,f=0}return s&&(u+=s),u&&(a.push(u),o.push(f)),1===a.length&&(f+=e),{accumWidth:f,lines:a,linesWidths:o}}function ui(t,n,i,r,e,a){if(t.baseX=i,t.baseY=r,t.outerWidth=t.outerHeight=null,n){var o=2*n.width,u=2*n.height;On.set(si,Vn(i,o,e),$n(r,u,a),o,u),On.intersect(n,si,null,li);var s=li.outIntersectRect;t.outerWidth=s.width,t.outerHeight=s.height,t.baseX=Vn(s.x,s.width,e,!0),t.baseY=$n(s.y,s.height,a,!0)}}var si=new On(0,0,0,0),li={outIntersectRect:{},clamp:!0};function fi(t){return null!=t?t+="":t=""}function hi(t,n,i,r){var e=new On(Vn(t.x||0,n,t.textAlign),$n(t.y||0,i,t.textBaseline),n,i),a=null!=r?r:ci(t)?t.lineWidth:0;return a>0&&(e.x-=a/2,e.y-=a/2,e.width+=a,e.height+=a),e}function ci(t){var n=t.stroke;return null!=n&&"none"!==n&&t.lineWidth>0}var vi=qt;function di(t){return t>5e-5||t<-5e-5}var pi=[],mi=[],yi=[1,0,0,1,0,0],gi=Math.abs,bi=function(){function t(){}var n;return t.prototype.getLocalTransform=function(t){return wi(this,t)},t.prototype.setPosition=function(t){this.x=t[0],this.y=t[1]},t.prototype.setScale=function(t){this.scaleX=t[0],this.scaleY=t[1]},t.prototype.setSkew=function(t){this.skewX=t[0],this.skewY=t[1]},t.prototype.setOrigin=function(t){this.originX=t[0],this.originY=t[1]},t.prototype.needLocalTransform=function(){return di(this.rotation)||di(this.x)||di(this.y)||di(this.scaleX-1)||di(this.scaleY-1)||di(this.skewX)||di(this.skewY)},t.prototype.updateTransform=function(){var t=this.parent&&this.parent.transform,n=this.needLocalTransform(),i=this.transform;n||t?(i=i||[1,0,0,1,0,0],n?this.getLocalTransform(i):vi(i),t&&(n?Zt(i,t,i):Gt(i,t)),this.transform=i,this._resolveGlobalScaleRatio(i),this.invTransform=this.invTransform||[1,0,0,1,0,0],Qt(this.invTransform,i)):i&&(vi(i),this.invTransform=null)},t.prototype._resolveGlobalScaleRatio=function(t){var n=this.globalScaleRatio;if(null!=n&&1!==n){this.getGlobalScale(pi);var i=pi[0]<0?-1:1,r=pi[1]<0?-1:1,e=((pi[0]-i)*n+i)/pi[0]||0,a=((pi[1]-r)*n+r)/pi[1]||0;t[0]*=e,t[1]*=e,t[2]*=a,t[3]*=a}},t.prototype.getComputedTransform=function(){for(var t=this,n=[];t;)n.push(t),t=t.parent;for(;t=n.pop();)t.updateTransform();return this.transform},t.prototype.setLocalTransform=function(t){if(t){var n=t[0]*t[0]+t[1]*t[1],i=t[2]*t[2]+t[3]*t[3],r=Math.atan2(t[1],t[0]),e=Math.PI/2+r-Math.atan2(t[3],t[2]);i=Math.sqrt(i)*Math.cos(e),n=Math.sqrt(n),this.skewX=e,this.skewY=0,this.rotation=-r,this.x=+t[4],this.y=+t[5],this.scaleX=n,this.scaleY=i,this.originX=0,this.originY=0}},t.prototype.decomposeTransform=function(){if(this.transform){var t=this.parent,n=this.transform;t&&t.transform&&(t.invTransform=t.invTransform||[1,0,0,1,0,0],Zt(mi,t.invTransform,n),n=mi);var i=this.originX,r=this.originY;(i||r)&&(yi[4]=i,yi[5]=r,Zt(mi,n,yi),mi[4]-=i,mi[5]-=r,n=mi),this.setLocalTransform(n)}},t.prototype.getGlobalScale=function(t){var n=this.transform;return t=t||[],n?(t[0]=Math.sqrt(n[0]*n[0]+n[1]*n[1]),t[1]=Math.sqrt(n[2]*n[2]+n[3]*n[3]),n[0]<0&&(t[0]=-t[0]),n[3]<0&&(t[1]=-t[1]),t):(t[0]=1,t[1]=1,t)},t.prototype.transformCoordToLocal=function(t,n){var i=[t,n],r=this.invTransform;return r&&hn(i,i,r),i},t.prototype.transformCoordToGlobal=function(t,n){var i=[t,n],r=this.transform;return r&&hn(i,i,r),i},t.prototype.getLineScale=function(){var t=this.transform;return t&&gi(t[0]-1)>1e-10&&gi(t[3]-1)>1e-10?Math.sqrt(gi(t[0]*t[3]-t[2]*t[1])):1},t.prototype.copyTransform=function(t){Mi(this,t)},t.getLocalTransform=function(t,n){n=n||[];var i=t.originX||0,r=t.originY||0,e=t.scaleX,a=t.scaleY,o=t.anchorX,u=t.anchorY,s=t.rotation||0,l=t.x,f=t.y,h=t.skewX?Math.tan(t.skewX):0,c=t.skewY?Math.tan(-t.skewY):0;if(i||r||o||u){var v=i+o,d=r+u;n[4]=-v*e-h*d*a,n[5]=-d*a-c*v*e}else n[4]=n[5]=0;return n[0]=e,n[3]=a,n[1]=c*e,n[2]=h*a,s&&Kt(n,n,s),n[4]+=i+l,n[5]+=r+f,n},t.initDefaultProps=((n=t.prototype).scaleX=n.scaleY=n.globalScaleRatio=1,void(n.x=n.y=n.originX=n.originY=n.skewX=n.skewY=n.rotation=n.anchorX=n.anchorY=0)),t}(),wi=bi.getLocalTransform,xi=["x","y","originX","originY","anchorX","anchorY","rotation","scaleX","scaleY","skewX","skewY"];function Mi(t,n){return function(t,n,i){t=t||{};for(var r=0;r<i.length;r++){var e=i[r];t[e]=n[e]}return t}(t,n,xi)}var ki={linear:function(t){return t},quadraticIn:function(t){return t*t},quadraticOut:function(t){return t*(2-t)},quadraticInOut:function(t){return(t*=2)<1?.5*t*t:-.5*(--t*(t-2)-1)},cubicIn:function(t){return t*t*t},cubicOut:function(t){return--t*t*t+1},cubicInOut:function(t){return(t*=2)<1?.5*t*t*t:.5*((t-=2)*t*t+2)},quarticIn:function(t){return t*t*t*t},quarticOut:function(t){return 1- --t*t*t*t},quarticInOut:function(t){return(t*=2)<1?.5*t*t*t*t:-.5*((t-=2)*t*t*t-2)},quinticIn:function(t){return t*t*t*t*t},quinticOut:function(t){return--t*t*t*t*t+1},quinticInOut:function(t){return(t*=2)<1?.5*t*t*t*t*t:.5*((t-=2)*t*t*t*t+2)},sinusoidalIn:function(t){return 1-Math.cos(t*Math.PI/2)},sinusoidalOut:function(t){return Math.sin(t*Math.PI/2)},sinusoidalInOut:function(t){return.5*(1-Math.cos(Math.PI*t))},exponentialIn:function(t){return 0===t?0:Math.pow(1024,t-1)},exponentialOut:function(t){return 1===t?1:1-Math.pow(2,-10*t)},exponentialInOut:function(t){return 0===t?0:1===t?1:(t*=2)<1?.5*Math.pow(1024,t-1):.5*(2-Math.pow(2,-10*(t-1)))},circularIn:function(t){return 1-Math.sqrt(1-t*t)},circularOut:function(t){return Math.sqrt(1- --t*t)},circularInOut:function(t){return(t*=2)<1?-.5*(Math.sqrt(1-t*t)-1):.5*(Math.sqrt(1-(t-=2)*t)+1)},elasticIn:function(t){var n,i=.1;return 0===t?0:1===t?1:(!i||i<1?(i=1,n=.1):n=.4*Math.asin(1/i)/(2*Math.PI),-i*Math.pow(2,10*(t-=1))*Math.sin((t-n)*(2*Math.PI)/.4))},elasticOut:function(t){var n,i=.1;return 0===t?0:1===t?1:(!i||i<1?(i=1,n=.1):n=.4*Math.asin(1/i)/(2*Math.PI),i*Math.pow(2,-10*t)*Math.sin((t-n)*(2*Math.PI)/.4)+1)},elasticInOut:function(t){var n,i=.1;return 0===t?0:1===t?1:(!i||i<1?(i=1,n=.1):n=.4*Math.asin(1/i)/(2*Math.PI),(t*=2)<1?i*Math.pow(2,10*(t-=1))*Math.sin((t-n)*(2*Math.PI)/.4)*-.5:i*Math.pow(2,-10*(t-=1))*Math.sin((t-n)*(2*Math.PI)/.4)*.5+1)},backIn:function(t){var n=1.70158;return t*t*((n+1)*t-n)},backOut:function(t){var n=1.70158;return--t*t*((n+1)*t+n)+1},backInOut:function(t){var n=2.5949095;return(t*=2)<1?t*t*((n+1)*t-n)*.5:.5*((t-=2)*t*((n+1)*t+n)+2)},bounceIn:function(t){return 1-ki.bounceOut(1-t)},bounceOut:function(t){return t<1/2.75?7.5625*t*t:t<2/2.75?7.5625*(t-=1.5/2.75)*t+.75:t<2.5/2.75?7.5625*(t-=2.25/2.75)*t+.9375:7.5625*(t-=2.625/2.75)*t+.984375},bounceInOut:function(t){return t<.5?.5*ki.bounceIn(2*t):.5*ki.bounceOut(2*t-1)+.5}},Si=Math.pow,Ai=Math.sqrt,Ti=1e-4,Ni=Ai(3),Ci=1/3,Oi=tn(),Ii=tn(),Li=tn();function Di(t){return t>-1e-8&&t<1e-8}function _i(t){return t>1e-8||t<-1e-8}function zi(t,n,i,r,e){var a=1-e;return a*a*(a*t+3*e*n)+e*e*(e*r+3*a*i)}function Ri(t,n,i,r,e){var a=1-e;return 3*(((n-t)*a+2*(i-n)*e)*a+(r-i)*e*e)}function Fi(t,n,i,r,e,a){var o=r+3*(n-i)-t,u=3*(i-2*n+t),s=3*(n-t),l=t-e,f=u*u-3*o*s,h=u*s-9*o*l,c=s*s-3*u*l,v=0;if(Di(f)&&Di(h))Di(u)?a[0]=0:(S=-s/u)>=0&&S<=1&&(a[v++]=S);else{var d=h*h-4*f*c;if(Di(d)){var p=h/f,m=-p/2;(S=-u/o+p)>=0&&S<=1&&(a[v++]=S),m>=0&&m<=1&&(a[v++]=m)}else if(d>0){var y=Ai(d),g=f*u+1.5*o*(-h+y),b=f*u+1.5*o*(-h-y);(S=(-u-((g=g<0?-Si(-g,Ci):Si(g,Ci))+(b=b<0?-Si(-b,Ci):Si(b,Ci))))/(3*o))>=0&&S<=1&&(a[v++]=S)}else{var w=(2*f*u-3*o*h)/(2*Ai(f*f*f)),x=Math.acos(w)/3,M=Ai(f),k=Math.cos(x),S=(-u-2*M*k)/(3*o),A=(m=(-u+M*(k+Ni*Math.sin(x)))/(3*o),(-u+M*(k-Ni*Math.sin(x)))/(3*o));S>=0&&S<=1&&(a[v++]=S),m>=0&&m<=1&&(a[v++]=m),A>=0&&A<=1&&(a[v++]=A)}}return v}function Pi(t,n,i,r,e){var a=6*i-12*n+6*t,o=9*n+3*r-3*t-9*i,u=3*n-3*t,s=0;if(Di(o))_i(a)&&(f=-u/a)>=0&&f<=1&&(e[s++]=f);else{var l=a*a-4*o*u;if(Di(l))e[0]=-a/(2*o);else if(l>0){var f,h=Ai(l),c=(-a-h)/(2*o);(f=(-a+h)/(2*o))>=0&&f<=1&&(e[s++]=f),c>=0&&c<=1&&(e[s++]=c)}}return s}function Bi(t,n,i,r,e,a){var o=(n-t)*e+t,u=(i-n)*e+n,s=(r-i)*e+i,l=(u-o)*e+o,f=(s-u)*e+u,h=(f-l)*e+l;a[0]=t,a[1]=o,a[2]=l,a[3]=h,a[4]=h,a[5]=f,a[6]=s,a[7]=r}function Ei(t,n,i,r,e,a,o,u,s){for(var l=t,f=n,h=0,c=1/s,v=1;v<=s;v++){var d=v*c,p=zi(t,i,e,o,d),m=zi(n,r,a,u,d),y=p-l,g=m-f;h+=Math.sqrt(y*y+g*g),l=p,f=m}return h}function Wi(t,n,i,r){var e=1-r;return e*(e*t+2*r*n)+r*r*i}function ji(t,n,i,r){return 2*((1-r)*(n-t)+r*(i-n))}function Hi(t,n,i){var r=t+i-2*n;return 0===r?.5:(t-n)/r}function Ui(t,n,i,r,e){var a=(n-t)*r+t,o=(i-n)*r+n,u=(o-a)*r+a;e[0]=t,e[1]=a,e[2]=u,e[3]=u,e[4]=o,e[5]=i}function Vi(t,n,i,r,e,a,o){for(var u=t,s=n,l=0,f=1/o,h=1;h<=o;h++){var c=h*f,v=Wi(t,i,e,c),d=Wi(n,r,a,c),p=v-u,m=d-s;l+=Math.sqrt(p*p+m*m),u=v,s=d}return l}var $i=/cubic-bezier\(([0-9,\.e ]+)\)/;function Yi(t){var n=t&&$i.exec(t);if(n){var i=n[1].split(","),r=+ct(i[0]),e=+ct(i[1]),a=+ct(i[2]),o=+ct(i[3]);if(isNaN(r+e+a+o))return;var u=[];return function(t){return t<=0?0:t>=1?1:Fi(0,r,a,1,t,u)&&zi(0,e,o,1,u[0])}}}var Xi=function(){function t(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||Mt,this.ondestroy=t.ondestroy||Mt,this.onrestart=t.onrestart||Mt,t.easing&&this.setEasing(t.easing)}return t.prototype.step=function(t,n){if(this._inited||(this._startTime=t+this._delay,this._inited=!0),!this._paused){var i=this._life,r=t-this._startTime-this._pausedTime,e=r/i;e<0&&(e=0),e=Math.min(e,1);var a=this.easingFunc,o=a?a(e):e;if(this.onframe(o),1===e){if(!this.loop)return!0;this._startTime=t-r%i,this._pausedTime=0,this.onrestart()}return!1}this._pausedTime+=n},t.prototype.pause=function(){this._paused=!0},t.prototype.resume=function(){this._paused=!1},t.prototype.setEasing=function(t){this.easing=t,this.easingFunc=Z(t)?t:ki[t]||Yi(t)},t}(),qi={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 Gi(t){return(t=Math.round(t))<0?0:t>255?255:t}function Zi(t){return t<0?0:t>1?1:t}function Ji(t){var n=t;return n.length&&"%"===n.charAt(n.length-1)?Gi(parseFloat(n)/100*255):Gi(parseInt(n,10))}function Ki(t){var n=t;return n.length&&"%"===n.charAt(n.length-1)?Zi(parseFloat(n)/100):Zi(parseFloat(n))}function Qi(t,n,i){return i<0?i+=1:i>1&&(i-=1),6*i<1?t+(n-t)*i*6:2*i<1?n:3*i<2?t+(n-t)*(2/3-i)*6:t}function tr(t,n,i){return t+(n-t)*i}function nr(t,n,i,r,e){return t[0]=n,t[1]=i,t[2]=r,t[3]=e,t}function ir(t,n){return t[0]=n[0],t[1]=n[1],t[2]=n[2],t[3]=n[3],t}var rr=new Ht(20),er=null;function ar(t,n){er&&ir(er,n),er=rr.put(t,er||n.slice())}function or(t,n){if(t){n=n||[];var i=rr.get(t);if(i)return ir(n,i);var r=(t+="").replace(/ /g,"").toLowerCase();if(r in qi)return ir(n,qi[r]),ar(t,n),n;var e,a=r.length;if("#"===r.charAt(0))return 4===a||5===a?(e=parseInt(r.slice(1,4),16))>=0&&e<=4095?(nr(n,(3840&e)>>4|(3840&e)>>8,240&e|(240&e)>>4,15&e|(15&e)<<4,5===a?parseInt(r.slice(4),16)/15:1),ar(t,n),n):void nr(n,0,0,0,1):7===a||9===a?(e=parseInt(r.slice(1,7),16))>=0&&e<=16777215?(nr(n,(16711680&e)>>16,(65280&e)>>8,255&e,9===a?parseInt(r.slice(7),16)/255:1),ar(t,n),n):void nr(n,0,0,0,1):void 0;var o=r.indexOf("("),u=r.indexOf(")");if(-1!==o&&u+1===a){var s=r.substr(0,o),l=r.substr(o+1,u-(o+1)).split(","),f=1;switch(s){case"rgba":if(4!==l.length)return 3===l.length?nr(n,+l[0],+l[1],+l[2],1):nr(n,0,0,0,1);f=Ki(l.pop());case"rgb":return l.length>=3?(nr(n,Ji(l[0]),Ji(l[1]),Ji(l[2]),3===l.length?f:Ki(l[3])),ar(t,n),n):void nr(n,0,0,0,1);case"hsla":return 4!==l.length?void nr(n,0,0,0,1):(l[3]=Ki(l[3]),ur(l,n),ar(t,n),n);case"hsl":return 3!==l.length?void nr(n,0,0,0,1):(ur(l,n),ar(t,n),n);default:return}}nr(n,0,0,0,1)}}function ur(t,n){var i=(parseFloat(t[0])%360+360)%360/360,r=Ki(t[1]),e=Ki(t[2]),a=e<=.5?e*(r+1):e+r-e*r,o=2*e-a;return nr(n=n||[],Gi(255*Qi(o,a,i+1/3)),Gi(255*Qi(o,a,i)),Gi(255*Qi(o,a,i-1/3)),1),4===t.length&&(n[3]=t[3]),n}function sr(t,n){var i=or(t);if(i){for(var r=0;r<3;r++)i[r]=i[r]*(1-n)|0,i[r]>255?i[r]=255:i[r]<0&&(i[r]=0);return fr(i,4===i.length?"rgba":"rgb")}}function lr(t,n,i,r){var e=or(t);if(t)return e=function(t){if(t){var n,i,r=t[0]/255,e=t[1]/255,a=t[2]/255,o=Math.min(r,e,a),u=Math.max(r,e,a),s=u-o,l=(u+o)/2;if(0===s)n=0,i=0;else{i=l<.5?s/(u+o):s/(2-u-o);var f=((u-r)/6+s/2)/s,h=((u-e)/6+s/2)/s,c=((u-a)/6+s/2)/s;r===u?n=c-h:e===u?n=1/3+f-c:a===u&&(n=2/3+h-f),n<0&&(n+=1),n>1&&(n-=1)}var v=[360*n,i,l];return null!=t[3]&&v.push(t[3]),v}}(e),null!=i&&(e[1]=Ki(Z(i)?i(e[1]):i)),null!=r&&(e[2]=Ki(Z(r)?r(e[2]):r)),fr(ur(e),"rgba")}function fr(t,n){if(t&&t.length){var i=t[0]+","+t[1]+","+t[2];return"rgba"!==n&&"hsva"!==n&&"hsla"!==n||(i+=","+t[3]),n+"("+i+")"}}function hr(t,n){var i=or(t);return i?(.299*i[0]+.587*i[1]+.114*i[2])*i[3]/255+(1-i[3])*n:0}var cr=new Ht(100);function vr(t){if(J(t)){var n=cr.get(t);return n||(n=sr(t,-.1),cr.put(t,n)),n}if(et(t)){var i=P({},t);return i.colorStops=U(t.colorStops,(function(t){return{offset:t.offset,color:sr(t.color,-.1)}})),i}return t}var dr=Math.round;function pr(t){var n;if(t&&"transparent"!==t){if("string"==typeof t&&t.indexOf("rgba")>-1){var i=or(t);i&&(t="rgb("+i[0]+","+i[1]+","+i[2]+")",n=i[3])}}else t="none";return{color:t,opacity:null==n?1:n}}function mr(t){return t<1e-4&&t>-1e-4}function yr(t){return dr(1e3*t)/1e3}function gr(t){return dr(1e4*t)/1e4}var br={left:"start",right:"end",center:"middle",middle:"middle"};function wr(t){return t&&!!t.image}function xr(t){return wr(t)||function(t){return t&&!!t.svgElement}(t)}function Mr(t){return"linear"===t.type}function kr(t){return"radial"===t.type}function Sr(t){return t&&("linear"===t.type||"radial"===t.type)}function Ar(t){return"url(#"+t+")"}function Tr(t){var n=t.getGlobalScale(),i=Math.max(n[0],n[1]);return Math.max(Math.ceil(Math.log(i)/Math.log(10)),1)}function Nr(t){var n=t.x||0,i=t.y||0,r=(t.rotation||0)*kt,e=ut(t.scaleX,1),a=ut(t.scaleY,1),o=t.skewX||0,u=t.skewY||0,s=[];return(n||i)&&s.push("translate("+n+"px,"+i+"px)"),r&&s.push("rotate("+r+")"),1===e&&1===a||s.push("scale("+e+","+a+")"),(o||u)&&s.push("skew("+dr(o*kt)+"deg, "+dr(u*kt)+"deg)"),s.join(" ")}var Cr="undefined"!=typeof Buffer&&"function"==typeof Buffer.from?function(t){return Buffer.from(t).toString("base64")}:"function"==typeof btoa&&"function"==typeof unescape&&"function"==typeof encodeURIComponent?function(t){return btoa(unescape(encodeURIComponent(t)))}:function(){return null},Or=Array.prototype.slice;function Ir(t,n,i){return(n-t)*i+t}function Lr(t,n,i,r){for(var e=n.length,a=0;a<e;a++)t[a]=Ir(n[a],i[a],r);return t}function Dr(t,n,i,r){for(var e=n.length,a=0;a<e;a++)t[a]=n[a]+i[a]*r;return t}function _r(t,n,i,r){for(var e=n.length,a=e&&n[0].length,o=0;o<e;o++){t[o]||(t[o]=[]);for(var u=0;u<a;u++)t[o][u]=n[o][u]+i[o][u]*r}return t}function zr(t,n){for(var i=t.length,r=n.length,e=i>r?n:t,a=Math.min(i,r),o=e[a-1]||{color:[0,0,0,0],offset:0},u=a;u<Math.max(i,r);u++)e.push({offset:o.offset,color:o.color.slice()})}function Rr(t,n,i){var r=t,e=n;if(r.push&&e.push){var a=r.length,o=e.length;if(a!==o)if(a>o)r.length=o;else for(var u=a;u<o;u++)r.push(1===i?e[u]:Or.call(e[u]));var s=r[0]&&r[0].length;for(u=0;u<r.length;u++)if(1===i)isNaN(r[u])&&(r[u]=e[u]);else for(var l=0;l<s;l++)isNaN(r[u][l])&&(r[u][l]=e[u][l])}}function Fr(t){if(j(t)){var n=t.length;if(j(t[0])){for(var i=[],r=0;r<n;r++)i.push(Or.call(t[r]));return i}return Or.call(t)}return t}function Pr(t){return t[0]=Math.floor(t[0])||0,t[1]=Math.floor(t[1])||0,t[2]=Math.floor(t[2])||0,t[3]=null==t[3]?1:t[3],"rgba("+t.join(",")+")"}function Br(t){return 4===t||5===t}function Er(t){return 1===t||2===t}var Wr=[0,0,0,0],jr=function(){function t(t){this.keyframes=[],this.discrete=!1,this._invalid=!1,this._needsSort=!1,this._lastFr=0,this._lastFrP=0,this.propName=t}return t.prototype.isFinished=function(){return this._finished},t.prototype.setFinished=function(){this._finished=!0,this._additiveTrack&&this._additiveTrack.setFinished()},t.prototype.needsAnimate=function(){return this.keyframes.length>=1},t.prototype.getAdditiveTrack=function(){return this._additiveTrack},t.prototype.addKeyframe=function(t,n,i){this._needsSort=!0;var r=this.keyframes,e=r.length,a=!1,o=6,u=n;if(j(n)){var s=function(t){return j(t&&t[0])?2:1}(n);o=s,(1===s&&!Q(n[0])||2===s&&!Q(n[0][0]))&&(a=!0)}else if(Q(n)&&!at(n))o=0;else if(J(n))if(isNaN(+n)){var l=or(n);l&&(u=l,o=3)}else o=0;else if(et(n)){var f=P({},u);f.colorStops=U(n.colorStops,(function(t){return{offset:t.offset,color:or(t.color)}})),Mr(n)?o=4:kr(n)&&(o=5),u=f}0===e?this.valType=o:o===this.valType&&6!==o||(a=!0),this.discrete=this.discrete||a;var h={time:t,value:u,rawValue:n,percent:0};return i&&(h.easing=i,h.easingFunc=Z(i)?i:ki[i]||Yi(i)),r.push(h),h},t.prototype.prepare=function(t,n){var i=this.keyframes;this._needsSort&&i.sort((function(t,n){return t.time-n.time}));for(var r=this.valType,e=i.length,a=i[e-1],o=this.discrete,u=Er(r),s=Br(r),l=0;l<e;l++){var f=i[l],h=f.value,c=a.value;f.percent=f.time/t,o||(u&&l!==e-1?Rr(h,c,r):s&&zr(h.colorStops,c.colorStops))}if(!o&&5!==r&&n&&this.needsAnimate()&&n.needsAnimate()&&r===n.valType&&!n._finished){this._additiveTrack=n;var v=i[0].value;for(l=0;l<e;l++)0===r?i[l].additiveValue=i[l].value-v:3===r?i[l].additiveValue=Dr([],i[l].value,v,-1):Er(r)&&(i[l].additiveValue=1===r?Dr([],i[l].value,v,-1):_r([],i[l].value,v,-1))}},t.prototype.step=function(t,n){if(!this._finished){this._additiveTrack&&this._additiveTrack._finished&&(this._additiveTrack=null);var i,r,e,a=null!=this._additiveTrack,o=a?"additiveValue":"value",u=this.valType,s=this.keyframes,l=s.length,f=this.propName,h=3===u,c=this._lastFr,v=Math.min;if(1===l)r=e=s[0];else{if(n<0)i=0;else if(n<this._lastFrP){for(i=v(c+1,l-1);i>=0&&!(s[i].percent<=n);i--);i=v(i,l-2)}else{for(i=c;i<l&&!(s[i].percent>n);i++);i=v(i-1,l-2)}e=s[i+1],r=s[i]}if(r&&e){this._lastFr=i,this._lastFrP=n;var d=e.percent-r.percent,p=0===d?1:v((n-r.percent)/d,1);e.easingFunc&&(p=e.easingFunc(p));var m=a?this._additiveValue:h?Wr:t[f];if(!Er(u)&&!h||m||(m=this._additiveValue=[]),this.discrete)t[f]=p<1?r.rawValue:e.rawValue;else if(Er(u))1===u?Lr(m,r[o],e[o],p):function(t,n,i,r){for(var e=n.length,a=e&&n[0].length,o=0;o<e;o++){t[o]||(t[o]=[]);for(var u=0;u<a;u++)t[o][u]=Ir(n[o][u],i[o][u],r)}}(m,r[o],e[o],p);else if(Br(u)){var y=r[o],g=e[o],b=4===u;t[f]={type:b?"linear":"radial",x:Ir(y.x,g.x,p),y:Ir(y.y,g.y,p),colorStops:U(y.colorStops,(function(t,n){var i=g.colorStops[n];return{offset:Ir(t.offset,i.offset,p),color:Pr(Lr([],t.color,i.color,p))}})),global:g.global},b?(t[f].x2=Ir(y.x2,g.x2,p),t[f].y2=Ir(y.y2,g.y2,p)):t[f].r=Ir(y.r,g.r,p)}else if(h)Lr(m,r[o],e[o],p),a||(t[f]=Pr(m));else{var w=Ir(r[o],e[o],p);a?this._additiveValue=w:t[f]=w}a&&this._addToTarget(t)}}},t.prototype._addToTarget=function(t){var n=this.valType,i=this.propName,r=this._additiveValue;0===n?t[i]=t[i]+r:3===n?(or(t[i],Wr),Dr(Wr,Wr,r,1),t[i]=Pr(Wr)):1===n?Dr(t[i],t[i],r,1):2===n&&_r(t[i],t[i],r,1)},t}(),Hr=function(){function t(t,n,i,r){this._tracks={},this._trackKeys=[],this._maxTime=0,this._started=0,this._clip=null,this._target=t,this._loop=n,n&&r?z("Can' use additive animation on looped animation."):(this._additiveAnimators=r,this._allowDiscrete=i)}return t.prototype.getMaxTime=function(){return this._maxTime},t.prototype.getDelay=function(){return this._delay},t.prototype.getLoop=function(){return this._loop},t.prototype.getTarget=function(){return this._target},t.prototype.changeTarget=function(t){this._target=t},t.prototype.when=function(t,n,i){return this.whenWithKeys(t,n,Y(n),i)},t.prototype.whenWithKeys=function(t,n,i,r){for(var e=this._tracks,a=0;a<i.length;a++){var o=i[a],u=e[o];if(!u){u=e[o]=new jr(o);var s=void 0,l=this._getAdditiveTrack(o);if(l){var f=l.keyframes,h=f[f.length-1];s=h&&h.value,3===l.valType&&s&&(s=Pr(s))}else s=this._target[o];if(null==s)continue;t>0&&u.addKeyframe(0,Fr(s),r),this._trackKeys.push(o)}u.addKeyframe(t,Fr(n[o]),r)}return this._maxTime=Math.max(this._maxTime,t),this},t.prototype.pause=function(){this._clip.pause(),this._paused=!0},t.prototype.resume=function(){this._clip.resume(),this._paused=!1},t.prototype.isPaused=function(){return!!this._paused},t.prototype.duration=function(t){return this._maxTime=t,this._force=!0,this},t.prototype._doneCallback=function(){this._setTracksFinished(),this._clip=null;var t=this._doneCbs;if(t)for(var n=t.length,i=0;i<n;i++)t[i].call(this)},t.prototype._abortedCallback=function(){this._setTracksFinished();var t=this.animation,n=this._abortedCbs;if(t&&t.removeClip(this._clip),this._clip=null,n)for(var i=0;i<n.length;i++)n[i].call(this)},t.prototype._setTracksFinished=function(){for(var t=this._tracks,n=this._trackKeys,i=0;i<n.length;i++)t[n[i]].setFinished()},t.prototype._getAdditiveTrack=function(t){var n,i=this._additiveAnimators;if(i)for(var r=0;r<i.length;r++){var e=i[r].getTrack(t);e&&(n=e)}return n},t.prototype.start=function(t){if(!(this._started>0)){this._started=1;for(var n=this,i=[],r=this._maxTime||0,e=0;e<this._trackKeys.length;e++){var a=this._trackKeys[e],o=this._tracks[a],u=this._getAdditiveTrack(a),s=o.keyframes,l=s.length;if(o.prepare(r,u),o.needsAnimate())if(!this._allowDiscrete&&o.discrete){var f=s[l-1];f&&(n._target[o.propName]=f.rawValue),o.setFinished()}else i.push(o)}if(i.length||this._force){var h=new Xi({life:r,loop:this._loop,delay:this._delay||0,onframe:function(t){n._started=2;var r=n._additiveAnimators;if(r){for(var e=!1,a=0;a<r.length;a++)if(r[a]._clip){e=!0;break}e||(n._additiveAnimators=null)}for(a=0;a<i.length;a++)i[a].step(n._target,t);var o=n._onframeCbs;if(o)for(a=0;a<o.length;a++)o[a](n._target,t)},ondestroy:function(){n._doneCallback()}});this._clip=h,this.animation&&this.animation.addClip(h),t&&h.setEasing(t)}else this._doneCallback();return this}},t.prototype.stop=function(t){this._clip&&(t&&this._clip.onframe(1),this._abortedCallback())},t.prototype.delay=function(t){return this._delay=t,this},t.prototype.during=function(t){return t&&(this._onframeCbs||(this._onframeCbs=[]),this._onframeCbs.push(t)),this},t.prototype.done=function(t){return t&&(this._doneCbs||(this._doneCbs=[]),this._doneCbs.push(t)),this},t.prototype.aborted=function(t){return t&&(this._abortedCbs||(this._abortedCbs=[]),this._abortedCbs.push(t)),this},t.prototype.getClip=function(){return this._clip},t.prototype.getTrack=function(t){return this._tracks[t]},t.prototype.getTracks=function(){var t=this;return U(this._trackKeys,(function(n){return t._tracks[n]}))},t.prototype.stopTracks=function(t,n){if(!t.length||!this._clip)return!0;for(var i=this._tracks,r=this._trackKeys,e=0;e<t.length;e++){var a=i[t[e]];a&&!a.isFinished()&&(n?a.step(this._target,1):1===this._started&&a.step(this._target,0),a.setFinished())}var o=!0;for(e=0;e<r.length;e++)if(!i[r[e]].isFinished()){o=!1;break}return o&&this._abortedCallback(),o},t.prototype.saveTo=function(t,n,i){if(t){n=n||this._trackKeys;for(var r=0;r<n.length;r++){var e=n[r],a=this._tracks[e];if(a&&!a.isFinished()){var o=a.keyframes,u=o[i?0:o.length-1];u&&(t[e]=Fr(u.rawValue))}}}},t.prototype.__changeFinalValue=function(t,n){n=n||Y(t);for(var i=0;i<n.length;i++){var r=n[i],e=this._tracks[r];if(e){var a=e.keyframes;if(a.length>1){var o=a.pop();e.addKeyframe(o.time,t[r]),e.prepare(this._maxTime,e.getAdditiveTrack())}}}},t}(),Ur=function(){function t(t){t&&(this._$eventProcessor=t)}return t.prototype.on=function(t,n,i,r){this._$handlers||(this._$handlers={});var e=this._$handlers;if("function"==typeof n&&(r=i,i=n,n=null),!i||!t)return this;var a=this._$eventProcessor;null!=n&&a&&a.normalizeQuery&&(n=a.normalizeQuery(n)),e[t]||(e[t]=[]);for(var o=0;o<e[t].length;o++)if(e[t][o].h===i)return this;var u={h:i,query:n,ctx:r||this,callAtLast:i.zrEventfulCallAtLast},s=e[t].length-1,l=e[t][s];return l&&l.callAtLast?e[t].splice(s,0,u):e[t].push(u),this},t.prototype.isSilent=function(t){var n=this._$handlers;return!n||!n[t]||!n[t].length},t.prototype.off=function(t,n){var i=this._$handlers;if(!i)return this;if(!t)return this._$handlers={},this;if(n){if(i[t]){for(var r=[],e=0,a=i[t].length;e<a;e++)i[t][e].h!==n&&r.push(i[t][e]);i[t]=r}i[t]&&0===i[t].length&&delete i[t]}else delete i[t];return this},t.prototype.trigger=function(t){for(var n=[],i=1;i<arguments.length;i++)n[i-1]=arguments[i];if(!this._$handlers)return this;var r=this._$handlers[t],e=this._$eventProcessor;if(r)for(var a=n.length,o=r.length,u=0;u<o;u++){var s=r[u];if(!e||!e.filter||null==s.query||e.filter(t,s.query))switch(a){case 0:s.h.call(s.ctx);break;case 1:s.h.call(s.ctx,n[0]);break;case 2:s.h.call(s.ctx,n[0],n[1]);break;default:s.h.apply(s.ctx,n)}}return e&&e.afterTrigger&&e.afterTrigger(t),this},t.prototype.triggerWithContext=function(t){for(var n=[],i=1;i<arguments.length;i++)n[i-1]=arguments[i];if(!this._$handlers)return this;var r=this._$handlers[t],e=this._$eventProcessor;if(r)for(var a=n.length,o=n[a-1],u=r.length,s=0;s<u;s++){var l=r[s];if(!e||!e.filter||null==l.query||e.filter(t,l.query))switch(a){case 0:l.h.call(o);break;case 1:l.h.call(o,n[0]);break;case 2:l.h.call(o,n[0],n[1]);break;default:l.h.apply(o,n.slice(1,a-1))}}return e&&e.afterTrigger&&e.afterTrigger(t),this},t}(),Vr=1;At.hasGlobalWindow&&(Vr=Math.max(window.devicePixelRatio||window.screen&&window.screen.deviceXDPI/window.screen.logicalXDPI||1,1));var $r=Vr,Yr="#333",Xr="#ccc",qr="__zr_normal__",Gr=xi.concat(["ignore"]),Zr=V(xi,(function(t,n){return t[n]=!0,t}),{ignore:!1}),Jr={},Kr=new On(0,0,0,0),Qr=[],te=function(){function t(t){this.id=_(),this.animators=[],this.currentStates=[],this.states={},this._init(t)}return t.prototype._init=function(t){this.attr(t)},t.prototype.drift=function(t,n){switch(this.draggable){case"horizontal":n=0;break;case"vertical":t=0}var i=this.transform;i||(i=this.transform=[1,0,0,1,0,0]),i[4]+=t,i[5]+=n,this.decomposeTransform(),this.markRedraw()},t.prototype.beforeUpdate=function(){},t.prototype.afterUpdate=function(){},t.prototype.update=function(){this.updateTransform(),this.__dirty&&this.updateInnerText()},t.prototype.updateInnerText=function(t){var n=this._textContent;if(n&&(!n.ignore||t)){this.textConfig||(this.textConfig={});var i=this.textConfig,r=i.local,e=n.innerTransformable,a=void 0,o=void 0,u=!1;e.parent=r?this:null;var s=!1;e.copyTransform(n);var l=null!=i.position,f=i.autoOverflowArea,h=void 0;if((f||l)&&((h=Kr).copy(i.layoutRect?i.layoutRect:this.getBoundingRect()),r||h.applyTransform(this.transform)),l){this.calculateTextPosition?this.calculateTextPosition(Jr,i,h):qn(Jr,i,h),e.x=Jr.x,e.y=Jr.y,a=Jr.align,o=Jr.verticalAlign;var c=i.origin;if(c&&null!=i.rotation){var v=void 0,d=void 0;"center"===c?(v=.5*h.width,d=.5*h.height):(v=Xn(c[0],h.width),d=Xn(c[1],h.height)),s=!0,e.originX=-e.x+v+(r?0:h.x),e.originY=-e.y+d+(r?0:h.y)}}null!=i.rotation&&(e.rotation=i.rotation);var p=i.offset;p&&(e.x+=p[0],e.y+=p[1],s||(e.originX=-p[0],e.originY=-p[1]));var m=this._innerTextDefaultStyle||(this._innerTextDefaultStyle={});if(f){var y=m.overflowRect=m.overflowRect||new On(0,0,0,0);e.getLocalTransform(Qr),Qt(Qr,Qr),On.copy(y,h),y.applyTransform(Qr)}else m.overflowRect=null;var g=void 0,b=void 0,w=void 0;(null==i.inside?"string"==typeof i.position&&i.position.indexOf("inside")>=0:i.inside)&&this.canBeInsideText()?(b=i.insideStroke,null!=(g=i.insideFill)&&"auto"!==g||(g=this.getInsideTextFill()),null!=b&&"auto"!==b||(b=this.getInsideTextStroke(g),w=!0)):(b=i.outsideStroke,null!=(g=i.outsideFill)&&"auto"!==g||(g=this.getOutsideFill()),null!=b&&"auto"!==b||(b=this.getOutsideStroke(g),w=!0)),(g=g||"#000")===m.fill&&b===m.stroke&&w===m.autoStroke&&a===m.align&&o===m.verticalAlign||(u=!0,m.fill=g,m.stroke=b,m.autoStroke=w,m.align=a,m.verticalAlign=o,n.setDefaultTextStyle(m)),n.__dirty|=1,u&&n.dirtyStyle(!0)}},t.prototype.canBeInsideText=function(){return!0},t.prototype.getInsideTextFill=function(){return"#fff"},t.prototype.getInsideTextStroke=function(){return"#000"},t.prototype.getOutsideFill=function(){return this.__zr&&this.__zr.isDarkMode()?Xr:Yr},t.prototype.getOutsideStroke=function(){var t=this.__zr&&this.__zr.getBackgroundColor(),n="string"==typeof t&&or(t);n||(n=[255,255,255,1]);for(var i=n[3],r=this.__zr.isDarkMode(),e=0;e<3;e++)n[e]=n[e]*i+(r?0:255)*(1-i);return n[3]=1,fr(n,"rgba")},t.prototype.traverse=function(){},t.prototype.attrKV=function(t,n){"textConfig"===t?this.setTextConfig(n):"textContent"===t?this.setTextContent(n):"clipPath"===t?this.setClipPath(n):"extra"===t?(this.extra=this.extra||{},P(this.extra,n)):this[t]=n},t.prototype.hide=function(){this.ignore=!0,this.markRedraw()},t.prototype.show=function(){this.ignore=!1,this.markRedraw()},t.prototype.attr=function(t,n){if("string"==typeof t)this.attrKV(t,n);else if(tt(t))for(var i=Y(t),r=0;r<i.length;r++){var e=i[r];this.attrKV(e,t[e])}return this.markRedraw(),this},t.prototype.saveCurrentToNormalState=function(t){this._innerSaveToNormal(t);for(var n=this._normalState,i=0;i<this.animators.length;i++){var r=this.animators[i],e=r.__fromStateTransition;if(!(r.getLoop()||e&&e!==qr)){var a=r.targetName;r.saveTo(a?n[a]:n)}}},t.prototype._innerSaveToNormal=function(t){var n=this._normalState;n||(n=this._normalState={}),t.textConfig&&!n.textConfig&&(n.textConfig=this.textConfig),this._savePrimaryToNormal(t,n,Gr)},t.prototype._savePrimaryToNormal=function(t,n,i){for(var r=0;r<i.length;r++){var e=i[r];null==t[e]||e in n||(n[e]=this[e])}},t.prototype.hasState=function(){return this.currentStates.length>0},t.prototype.getState=function(t){return this.states[t]},t.prototype.ensureState=function(t){var n=this.states;return n[t]||(n[t]={}),n[t]},t.prototype.clearStates=function(t){this.useState(qr,!1,t)},t.prototype.useState=function(t,n,i,r){var e=t===qr;if(this.hasState()||!e){var a=this.currentStates,o=this.stateTransition;if(!(E(a,t)>=0)||!n&&1!==a.length){var u;if(this.stateProxy&&!e&&(u=this.stateProxy(t)),u||(u=this.states&&this.states[t]),u||e){e||this.saveCurrentToNormalState(u);var s=this._textContent,l=ae(this,s,u,r);l&&!this.__inHover&&(this.__inHover=l),this._applyStateObj(t,u,this._normalState,n,ue(this,i,o),o);var f=this._textGuide;return s&&s.useState(t,n,i,!!l),f&&f.useState(t,n,i,!!l),e?(this.currentStates=[],this._normalState={}):n?this.currentStates.push(t):this.currentStates=[t],this._updateAnimationTargets(),this.markRedraw(),!l&&this.__inHover&&(this.__inHover=0,this.__dirty&=-2),u}z("State "+t+" not exists.")}}},t.prototype.useStates=function(t,n,i){if(t.length){var r=[],e=this.currentStates,a=t.length,o=a===e.length;if(o)for(var u=0;u<a;u++)if(t[u]!==e[u]){o=!1;break}if(o)return;for(u=0;u<a;u++){var s=t[u],l=void 0;this.stateProxy&&(l=this.stateProxy(s,t)),l||(l=this.states[s]),l&&r.push(l)}var f=this._textContent,h=ae(this,f,r[a-1],i);h&&!this.__inHover&&(this.__inHover=h);var c=this._mergeStates(r),v=this.stateTransition;this.saveCurrentToNormalState(c),this._applyStateObj(t.join(","),c,this._normalState,!1,ue(this,n,v),v);var d=this._textGuide;f&&f.useStates(t,n,!!h),d&&d.useStates(t,n,!!h),this._updateAnimationTargets(),this.currentStates=t.slice(),this.markRedraw(),!h&&this.__inHover&&(this.__inHover=0,this.__dirty&=-2)}else this.clearStates()},t.prototype.isSilent=function(){for(var t=this;t;){if(t.silent)return!0;var n=t.__hostTarget;t=n?t.ignoreHostSilent?null:n:t.parent}return!1},t.prototype._updateAnimationTargets=function(){for(var t=0;t<this.animators.length;t++){var n=this.animators[t];n.targetName&&n.changeTarget(this[n.targetName])}},t.prototype.removeState=function(t){var n=E(this.currentStates,t);if(n>=0){var i=this.currentStates.slice();i.splice(n,1),this.useStates(i)}},t.prototype.replaceState=function(t,n,i){var r=this.currentStates.slice(),e=E(r,t),a=E(r,n)>=0;e>=0?a?r.splice(e,1):r[e]=n:i&&!a&&r.push(n),this.useStates(r)},t.prototype.toggleState=function(t,n){n?this.useState(t,!0):this.removeState(t)},t.prototype._mergeStates=function(t){for(var n,i={},r=0;r<t.length;r++){var e=t[r];P(i,e),e.textConfig&&P(n=n||{},e.textConfig)}return n&&(i.textConfig=n),i},t.prototype._applyStateObj=function(t,n,i,r,e,a){if(1!==this.__inHover){var o=!(n&&r);n&&n.textConfig?(this.textConfig=P({},r?this.textConfig:i.textConfig),P(this.textConfig,n.textConfig)):o&&i.textConfig&&(this.textConfig=i.textConfig);for(var u={},s=!1,l=0;l<Gr.length;l++){var f=Gr[l],h=e&&Zr[f];n&&null!=n[f]?h?(s=!0,u[f]=n[f]):this[f]=n[f]:o&&null!=i[f]&&(h?(s=!0,u[f]=i[f]):this[f]=i[f])}if(!e)for(l=0;l<this.animators.length;l++){var c=this.animators[l],v=c.targetName;c.getLoop()||c.__changeFinalValue(v?(n||i)[v]:n||i)}s&&this._transitionState(t,u,a)}},t.prototype._attachComponent=function(t){if((!t.__zr||t.__hostTarget)&&t!==this){var n=this.__zr;n&&t.addSelfToZr(n),t.__zr=n,t.__hostTarget=this}},t.prototype._detachComponent=function(t){t.__zr&&t.removeSelfFromZr(t.__zr),t.__zr=null,t.__hostTarget=null},t.prototype.getClipPath=function(){return this._clipPath},t.prototype.setClipPath=function(t){this._clipPath&&this._clipPath!==t&&this.removeClipPath(),this._attachComponent(t),this._clipPath=t,this.markRedraw()},t.prototype.removeClipPath=function(){var t=this._clipPath;t&&(this._detachComponent(t),this._clipPath=null,this.markRedraw())},t.prototype.getTextContent=function(){return this._textContent},t.prototype.setTextContent=function(t){var n=this._textContent;n!==t&&(n&&n!==t&&this.removeTextContent(),t.innerTransformable=new bi,this._attachComponent(t),this._textContent=t,this.markRedraw())},t.prototype.setTextConfig=function(t){this.textConfig||(this.textConfig={}),P(this.textConfig,t),this.markRedraw()},t.prototype.removeTextConfig=function(){this.textConfig=null,this.markRedraw()},t.prototype.removeTextContent=function(){var t=this._textContent;t&&(t.innerTransformable=null,this._detachComponent(t),this._textContent=null,this._innerTextDefaultStyle=null,this.markRedraw())},t.prototype.getTextGuideLine=function(){return this._textGuide},t.prototype.setTextGuideLine=function(t){this._textGuide&&this._textGuide!==t&&this.removeTextGuideLine(),this._attachComponent(t),this._textGuide=t,this.markRedraw()},t.prototype.removeTextGuideLine=function(){var t=this._textGuide;t&&(this._detachComponent(t),this._textGuide=null,this.markRedraw())},t.prototype.markRedraw=function(){this.__dirty|=1;var t=this.__zr;t&&(this.__inHover?t.refreshHover():t.refresh()),this.__hostTarget&&this.__hostTarget.markRedraw()},t.prototype.dirty=function(){this.markRedraw()},t.prototype.addSelfToZr=function(t){if(this.__zr!==t){this.__zr=t;var n=this.animators;if(n)for(var i=0;i<n.length;i++)t.animation.addAnimator(n[i]);this._clipPath&&this._clipPath.addSelfToZr(t),this._textContent&&this._textContent.addSelfToZr(t),this._textGuide&&this._textGuide.addSelfToZr(t)}},t.prototype.removeSelfFromZr=function(t){if(this.__zr){this.__zr=null;var n=this.animators;if(n)for(var i=0;i<n.length;i++)t.animation.removeAnimator(n[i]);this._clipPath&&this._clipPath.removeSelfFromZr(t),this._textContent&&this._textContent.removeSelfFromZr(t),this._textGuide&&this._textGuide.removeSelfFromZr(t)}},t.prototype.animate=function(t,n,i){var r=new Hr(t?this[t]:this,n,i);return t&&(r.targetName=t),this.addAnimator(r,t),r},t.prototype.addAnimator=function(t,n){var i=this.__zr,r=this;t.during((function(){r.updateDuringAnimation(n)})).done((function(){var n=r.animators,i=E(n,t);i>=0&&n.splice(i,1)})),this.animators.push(t),i&&i.animation.addAnimator(t),i&&i.wakeUp()},t.prototype.updateDuringAnimation=function(){this.markRedraw()},t.prototype.stopAnimation=function(t,n){for(var i=this.animators,r=i.length,e=[],a=0;a<r;a++){var o=i[a];t&&t!==o.scope?e.push(o):o.stop(n)}return this.animators=e,this},t.prototype.animateTo=function(t,n,i){ne(this,t,n,i)},t.prototype.animateFrom=function(t,n,i){ne(this,t,n,i,!0)},t.prototype._transitionState=function(t,n,i,r){for(var e=ne(this,n,i,r),a=0;a<e.length;a++)e[a].__fromStateTransition=t},t.prototype.getBoundingRect=function(){return null},t.prototype.getPaintRect=function(){return null},t.initDefaultProps=function(){var n=t.prototype;function i(t,i,r,e){function a(t,n){Object.defineProperty(n,0,{get:function(){return t[r]},set:function(n){t[r]=n}}),Object.defineProperty(n,1,{get:function(){return t[e]},set:function(n){t[e]=n}})}Object.defineProperty(n,t,{get:function(){return this[i]||a(this,this[i]=[]),this[i]},set:function(t){this[r]=t[0],this[e]=t[1],this[i]=t,a(this,t)}})}n.type="element",n.name="",n.ignore=n.silent=n.ignoreHostSilent=n.isGroup=n.draggable=n.dragging=n.ignoreClip=!1,n.__inHover=0,n.__dirty=1,Object.defineProperty&&(i("position","_legacyPos","x","y"),i("scale","_legacyScale","scaleX","scaleY"),i("origin","_legacyOrigin","originX","originY"))}(),t}();function ne(t,n,i,r,e){var a=[];ee(t,"",t,n,i=i||{},r,a,e);var o=a.length,u=!1,s=i.done,l=i.aborted,f=function(){u=!0,--o<=0&&(u?s&&s():l&&l())},h=function(){--o<=0&&(u?s&&s():l&&l())};o||s&&s(),a.length>0&&i.during&&a[0].during((function(t,n){i.during(n)}));for(var c=0;c<a.length;c++){var v=a[c];f&&v.done(f),h&&v.aborted(h),i.force&&v.duration(i.duration),v.start(i.easing)}return a}function ie(t,n,i){for(var r=0;r<i;r++)t[r]=n[r]}function re(t,n,i){if(j(n[i]))if(j(t[i])||(t[i]=[]),it(n[i])){var r=n[i].length;t[i].length!==r&&(t[i]=new n[i].constructor(r),ie(t[i],n[i],r))}else{var e=n[i],a=t[i],o=e.length;if(j(e[0]))for(var u=e[0].length,s=0;s<o;s++)a[s]?ie(a[s],e[s],u):a[s]=Array.prototype.slice.call(e[s]);else ie(a,e,o);a.length=e.length}else t[i]=n[i]}function ee(t,n,i,r,e,a,o,u){for(var s=Y(r),l=e.duration,f=e.delay,h=e.additive,c=e.setToFinal,v=!tt(a),d=t.animators,p=[],m=0;m<s.length;m++){var y=r[A=s[m]];if(null!=y&&null!=i[A]&&(v||a[A]))if(!tt(y)||j(y)||et(y))p.push(A);else{if(n){u||(i[A]=y,t.updateDuringAnimation(n));continue}ee(t,A,i[A],y,e,a&&a[A],o,u)}else u||(i[A]=y,t.updateDuringAnimation(n),p.push(A))}var g=p.length;if(!h&&g)for(var b=0;b<d.length;b++)if((x=d[b]).targetName===n&&x.stopTracks(p)){var w=E(d,x);d.splice(w,1)}if(e.force||(p=$(p,(function(t){return!((n=r[t])===(e=i[t])||j(n)&&j(e)&&function(t,n){var i=t.length;if(i!==n.length)return!1;for(var r=0;r<i;r++)if(t[r]!==n[r])return!1;return!0}(n,e));var n,e})),g=p.length),g>0||e.force&&!o.length){var x,M=void 0,k=void 0,S=void 0;if(u)for(k={},c&&(M={}),b=0;b<g;b++)k[A=p[b]]=i[A],c?M[A]=r[A]:i[A]=r[A];else if(c)for(S={},b=0;b<g;b++){var A;S[A=p[b]]=Fr(i[A]),re(i,r,A)}(x=new Hr(i,!1,!1,h?$(d,(function(t){return t.targetName===n})):null)).targetName=n,e.scope&&(x.scope=e.scope),c&&M&&x.whenWithKeys(0,M,p),S&&x.whenWithKeys(0,S,p),x.whenWithKeys(null==l?500:l,u?k:r,p).delay(f||0),t.addAnimator(x,n),o.push(x)}}function ae(t,n,i,r){return!(i&&i.hoverLayer||r)||oe(t)||n&&oe(n)?0:1}function oe(t){return"text"===t.type||"tspan"===t.type}function ue(t,n,i){return!n&&!t.__inHover&&i&&i.duration>0}W(te,Ur),W(te,bi);var se="__zr_style_"+Math.round(10*Math.random()),le={shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,shadowColor:"#000",opacity:1,blend:"source-over"},fe={style:{shadowBlur:!0,shadowOffsetX:!0,shadowOffsetY:!0,shadowColor:!0,opacity:!0}};le[se]=!0;var he=["z","z2","invisible"],ce=["invisible"],ve=function(t){function n(n){return t.call(this,n)||this}var i;return Et(n,t),n.prototype._init=function(n){for(var i=Y(n),r=0;r<i.length;r++){var e=i[r];"style"===e?this.useStyle(n[e]):t.prototype.attrKV.call(this,e,n[e])}this.style||this.useStyle({})},n.prototype.beforeBrush=function(){},n.prototype.afterBrush=function(){},n.prototype.innerBeforeBrush=function(){},n.prototype.innerAfterBrush=function(){},n.prototype.shouldBePainted=function(t,n,i,r){var e,a,o,u=this.transform;if(this.ignore||this.invisible||0===this.style.opacity||this.culling&&(a=t,o=n,de.copy((e=this).getBoundingRect()),e.transform&&de.applyTransform(e.transform),pe.width=a,pe.height=o,!de.intersect(pe))||u&&!u[0]&&!u[3])return!1;if(i&&this.__clipPaths&&this.__clipPaths.length)for(var s=0;s<this.__clipPaths.length;++s)if(this.__clipPaths[s].isZeroArea())return!1;if(r&&this.parent)for(var l=this.parent;l;){if(l.ignore)return!1;l=l.parent}return!0},n.prototype.contain=function(t,n){return this.rectContain(t,n)},n.prototype.traverse=function(t,n){t.call(n,this)},n.prototype.rectContain=function(t,n){var i=this.transformCoordToLocal(t,n);return this.getBoundingRect().contain(i[0],i[1])},n.prototype.getPaintRect=function(){var t=this._paintRect;if(!this._paintRect||this.__dirty){var n=this.transform,i=this.getBoundingRect(),r=this.style,e=r.shadowBlur||0,a=r.shadowOffsetX||0,o=r.shadowOffsetY||0;t=this._paintRect||(this._paintRect=new On(0,0,0,0)),n?On.applyTransform(t,i,n):t.copy(i),(e||a||o)&&(t.width+=2*e+Math.abs(a),t.height+=2*e+Math.abs(o),t.x=Math.min(t.x,t.x+a-e),t.y=Math.min(t.y,t.y+o-e));var u=this.dirtyRectTolerance;t.isZero()||(t.x=Math.floor(t.x-u),t.y=Math.floor(t.y-u),t.width=Math.ceil(t.width+1+2*u),t.height=Math.ceil(t.height+1+2*u))}return t},n.prototype.setPrevPaintRect=function(t){t?(this._prevPaintRect=this._prevPaintRect||new On(0,0,0,0),this._prevPaintRect.copy(t)):this._prevPaintRect=null},n.prototype.getPrevPaintRect=function(){return this._prevPaintRect},n.prototype.animateStyle=function(t){return this.animate("style",t)},n.prototype.updateDuringAnimation=function(t){"style"===t?this.dirtyStyle():this.markRedraw()},n.prototype.attrKV=function(n,i){"style"!==n?t.prototype.attrKV.call(this,n,i):this.style?this.setStyle(i):this.useStyle(i)},n.prototype.setStyle=function(t,n){return"string"==typeof t?this.style[t]=n:P(this.style,t),this.dirtyStyle(),this},n.prototype.dirtyStyle=function(t){t||this.markRedraw(),this.__dirty|=2,this._rect&&(this._rect=null)},n.prototype.dirty=function(){this.dirtyStyle()},n.prototype.styleChanged=function(){return!!(2&this.__dirty)},n.prototype.styleUpdated=function(){this.__dirty&=-3},n.prototype.createStyle=function(t){return wt(le,t)},n.prototype.useStyle=function(t){t[se]||(t=this.createStyle(t)),this.style=t,this.dirtyStyle()},n.prototype._useHoverStyle=function(t){this.__hoverStyle=t},n.prototype.isStyleObject=function(t){return t[se]},n.prototype._innerSaveToNormal=function(n){t.prototype._innerSaveToNormal.call(this,n);var i=this._normalState;n.style&&!i.style&&(i.style=this._mergeStyle(this.createStyle(),this.style)),this._savePrimaryToNormal(n,i,he)},n.prototype._applyStateObj=function(n,i,r,e,a,o){t.prototype._applyStateObj.call(this,n,i,r,e,a,o);var u,s=!(i&&e),l=1===this.__inHover;if(i&&i.style?a?e?u=i.style:(u=this._mergeStyle(this.createStyle(),r.style),this._mergeStyle(u,i.style)):(u=this._mergeStyle(this.createStyle(),e?this.style:r.style),this._mergeStyle(u,i.style)):s&&(u=r.style),u)if(a){var f=this.style;if(this.style=this.createStyle(s?{}:f),s)for(var h=Y(f),c=0;c<h.length;c++)(p=h[c])in u&&(u[p]=u[p],this.style[p]=f[p]);var v=Y(u);for(c=0;c<v.length;c++)this.style[p=v[c]]=this.style[p];this._transitionState(n,{style:u},o,this.getAnimationStyleProps())}else l?this._useHoverStyle(u):this.useStyle(u);if(!l){var d=this.__inHover?ce:he;for(c=0;c<d.length;c++){var p=d[c];i&&null!=i[p]?this[p]=i[p]:s&&null!=r[p]&&(this[p]=r[p])}}},n.prototype._mergeStates=function(n){for(var i,r=t.prototype._mergeStates.call(this,n),e=0;e<n.length;e++){var a=n[e];a.style&&this._mergeStyle(i=i||{},a.style)}return i&&(r.style=i),r},n.prototype._mergeStyle=function(t,n){return P(t,n),t},n.prototype.getAnimationStyleProps=function(){return fe},n.initDefaultProps=((i=n.prototype).type="displayable",i.invisible=!1,i.z=0,i.z2=0,i.zlevel=0,i.culling=!1,i.cursor="pointer",i.rectHover=!1,i.incremental=0,i._rect=null,i.dirtyRectTolerance=0,void(i.__dirty=3)),n}(te),de=new On(0,0,0,0),pe=new On(0,0,0,0),me=Math.min,ye=Math.max,ge=Math.sin,be=Math.cos,we=2*Math.PI,xe=tn(),Me=tn(),ke=tn();function Se(t,n,i,r,e,a){e[0]=me(t,i),e[1]=me(n,r),a[0]=ye(t,i),a[1]=ye(n,r)}var Ae=[],Te=[];function Ne(t,n,i,r,e,a,o,u,s,l){var f=Pi,h=zi,c=f(t,i,e,o,Ae);s[0]=1/0,s[1]=1/0,l[0]=-1/0,l[1]=-1/0;for(var v=0;v<c;v++){var d=h(t,i,e,o,Ae[v]);s[0]=me(d,s[0]),l[0]=ye(d,l[0])}for(c=f(n,r,a,u,Te),v=0;v<c;v++){var p=h(n,r,a,u,Te[v]);s[1]=me(p,s[1]),l[1]=ye(p,l[1])}s[0]=me(t,s[0]),l[0]=ye(t,l[0]),s[0]=me(o,s[0]),l[0]=ye(o,l[0]),s[1]=me(n,s[1]),l[1]=ye(n,l[1]),s[1]=me(u,s[1]),l[1]=ye(u,l[1])}function Ce(t,n,i,r,e,a,o,u){var s=Hi,l=Wi,f=ye(me(s(t,i,e),1),0),h=ye(me(s(n,r,a),1),0),c=l(t,i,e,f),v=l(n,r,a,h);o[0]=me(t,e,c),o[1]=me(n,a,v),u[0]=ye(t,e,c),u[1]=ye(n,a,v)}function Oe(t,n,i,r,e,a,o,u,s){var l=cn,f=vn,h=Math.abs(e-a);if(h%we<1e-4&&h>1e-4)return u[0]=t-i,u[1]=n-r,s[0]=t+i,void(s[1]=n+r);if(xe[0]=be(e)*i+t,xe[1]=ge(e)*r+n,Me[0]=be(a)*i+t,Me[1]=ge(a)*r+n,l(u,xe,Me),f(s,xe,Me),(e%=we)<0&&(e+=we),(a%=we)<0&&(a+=we),e>a&&!o?a+=we:e<a&&o&&(e+=we),o){var c=a;a=e,e=c}for(var v=0;v<a;v+=Math.PI/2)v>e&&(ke[0]=be(v)*i+t,ke[1]=ge(v)*r+n,l(u,ke,u),f(s,ke,s))}var Ie={M:1,L:2,C:3,Q:4,A:5,Z:6,R:7},Le=[],De=[],_e=[],ze=[],Re=[],Fe=[],Pe=Math.min,Be=Math.max,Ee=Math.cos,We=Math.sin,je=Math.abs,He=Math.PI,Ue=2*He,Ve="undefined"!=typeof Float32Array,$e=[];function Ye(t){return Math.round(t/He*1e8)/1e8%2*He}function Xe(t,n){var i=Ye(t[0]);i<0&&(i+=Ue);var r=t[1];r+=i-t[0],!n&&r-i>=Ue?r=i+Ue:n&&i-r>=Ue?r=i-Ue:!n&&i>r?r=i+(Ue-Ye(i-r)):n&&i<r&&(r=i-(Ue-Ye(r-i))),t[0]=i,t[1]=r}var qe=function(){function t(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=[])}var n;return t.prototype.increaseVersion=function(){this._version++},t.prototype.getVersion=function(){return this._version},t.prototype.setScale=function(t,n,i){(i=i||0)>0&&(this._ux=je(i/$r/t)||0,this._uy=je(i/$r/n)||0)},t.prototype.setDPR=function(t){this.dpr=t},t.prototype.setContext=function(t){this._ctx=t},t.prototype.getContext=function(){return this._ctx},t.prototype.beginPath=function(){return this._ctx&&this._ctx.beginPath(),this.reset(),this},t.prototype.reset=function(){this._saveData&&(this._len=0),this._pathSegLen&&(this._pathSegLen=null,this._pathLen=0),this._version++},t.prototype.moveTo=function(t,n){return this._drawPendingPt(),this.addData(Ie.M,t,n),this._ctx&&this._ctx.moveTo(t,n),this._x0=t,this._y0=n,this._xi=t,this._yi=n,this},t.prototype.lineTo=function(t,n){var i=je(t-this._xi),r=je(n-this._yi),e=i>this._ux||r>this._uy;if(this.addData(Ie.L,t,n),this._ctx&&e&&this._ctx.lineTo(t,n),e)this._xi=t,this._yi=n,this._pendingPtDist=0;else{var a=i*i+r*r;a>this._pendingPtDist&&(this._pendingPtX=t,this._pendingPtY=n,this._pendingPtDist=a)}return this},t.prototype.bezierCurveTo=function(t,n,i,r,e,a){return this._drawPendingPt(),this.addData(Ie.C,t,n,i,r,e,a),this._ctx&&this._ctx.bezierCurveTo(t,n,i,r,e,a),this._xi=e,this._yi=a,this},t.prototype.quadraticCurveTo=function(t,n,i,r){return this._drawPendingPt(),this.addData(Ie.Q,t,n,i,r),this._ctx&&this._ctx.quadraticCurveTo(t,n,i,r),this._xi=i,this._yi=r,this},t.prototype.arc=function(t,n,i,r,e,a){return this._drawPendingPt(),$e[0]=r,$e[1]=e,Xe($e,a),this.addData(Ie.A,t,n,i,i,r=$e[0],(e=$e[1])-r,0,a?0:1),this._ctx&&this._ctx.arc(t,n,i,r,e,a),this._xi=Ee(e)*i+t,this._yi=We(e)*i+n,this},t.prototype.arcTo=function(t,n,i,r,e){return this._drawPendingPt(),this._ctx&&this._ctx.arcTo(t,n,i,r,e),this},t.prototype.rect=function(t,n,i,r){return this._drawPendingPt(),this._ctx&&this._ctx.rect(t,n,i,r),this.addData(Ie.R,t,n,i,r),this},t.prototype.closePath=function(){this._drawPendingPt(),this.addData(Ie.Z);var t=this._ctx,n=this._x0,i=this._y0;return t&&t.closePath(),this._xi=n,this._yi=i,this},t.prototype.fill=function(t){t&&t.fill(),this.toStatic()},t.prototype.stroke=function(t){t&&t.stroke(),this.toStatic()},t.prototype.len=function(){return this._len},t.prototype.setData=function(t){if(this._saveData){var n=t.length;this.data&&this.data.length===n||!Ve||(this.data=new Float32Array(n));for(var i=0;i<n;i++)this.data[i]=t[i];this._len=n}},t.prototype.appendPath=function(t){if(this._saveData){t instanceof Array||(t=[t]);for(var n=t.length,i=0,r=this._len,e=0;e<n;e++)i+=t[e].len();var a=this.data;if(Ve&&(a instanceof Float32Array||!a)&&(this.data=new Float32Array(r+i),r>0&&a))for(var o=0;o<r;o++)this.data[o]=a[o];for(e=0;e<n;e++){var u=t[e].data;for(o=0;o<u.length;o++)this.data[r++]=u[o]}this._len=r}},t.prototype.addData=function(t,n,i,r,e,a,o,u,s){if(this._saveData){var l=this.data;this._len+arguments.length>l.length&&(this._expandData(),l=this.data);for(var f=0;f<arguments.length;f++)l[this._len++]=arguments[f]}},t.prototype._drawPendingPt=function(){this._pendingPtDist>0&&(this._ctx&&this._ctx.lineTo(this._pendingPtX,this._pendingPtY),this._pendingPtDist=0)},t.prototype._expandData=function(){if(!(this.data instanceof Array)){for(var t=[],n=0;n<this._len;n++)t[n]=this.data[n];this.data=t}},t.prototype.toStatic=function(){if(this._saveData){this._drawPendingPt();var t=this.data;t instanceof Array&&(t.length=this._len,Ve&&this._len>11&&(this.data=new Float32Array(t)))}},t.prototype.getBoundingRect=function(){_e[0]=_e[1]=Re[0]=Re[1]=Number.MAX_VALUE,ze[0]=ze[1]=Fe[0]=Fe[1]=-Number.MAX_VALUE;var t,n=this.data,i=0,r=0,e=0,a=0;for(t=0;t<this._len;){var o=n[t++],u=1===t;switch(u&&(e=i=n[t],a=r=n[t+1]),o){case Ie.M:i=e=n[t++],r=a=n[t++],Re[0]=e,Re[1]=a,Fe[0]=e,Fe[1]=a;break;case Ie.L:Se(i,r,n[t],n[t+1],Re,Fe),i=n[t++],r=n[t++];break;case Ie.C:Ne(i,r,n[t++],n[t++],n[t++],n[t++],n[t],n[t+1],Re,Fe),i=n[t++],r=n[t++];break;case Ie.Q:Ce(i,r,n[t++],n[t++],n[t],n[t+1],Re,Fe),i=n[t++],r=n[t++];break;case Ie.A:var s=n[t++],l=n[t++],f=n[t++],h=n[t++],c=n[t++],v=n[t++]+c;t+=1;var d=!n[t++];u&&(e=Ee(c)*f+s,a=We(c)*h+l),Oe(s,l,f,h,c,v,d,Re,Fe),i=Ee(v)*f+s,r=We(v)*h+l;break;case Ie.R:Se(e=i=n[t++],a=r=n[t++],e+n[t++],a+n[t++],Re,Fe);break;case Ie.Z:i=e,r=a}cn(_e,_e,Re),vn(ze,ze,Fe)}return 0===t&&(_e[0]=_e[1]=ze[0]=ze[1]=0),new On(_e[0],_e[1],ze[0]-_e[0],ze[1]-_e[1])},t.prototype._calculateLength=function(){var t=this.data,n=this._len,i=this._ux,r=this._uy,e=0,a=0,o=0,u=0;this._pathSegLen||(this._pathSegLen=[]);for(var s=this._pathSegLen,l=0,f=0,h=0;h<n;){var c=t[h++],v=1===h;v&&(o=e=t[h],u=a=t[h+1]);var d=-1;switch(c){case Ie.M:e=o=t[h++],a=u=t[h++];break;case Ie.L:var p=t[h++],m=(b=t[h++])-a;(je(O=p-e)>i||je(m)>r||h===n-1)&&(d=Math.sqrt(O*O+m*m),e=p,a=b);break;case Ie.C:var y=t[h++],g=t[h++],b=(p=t[h++],t[h++]),w=t[h++],x=t[h++];d=Ei(e,a,y,g,p,b,w,x,10),e=w,a=x;break;case Ie.Q:d=Vi(e,a,y=t[h++],g=t[h++],p=t[h++],b=t[h++],10),e=p,a=b;break;case Ie.A:var M=t[h++],k=t[h++],S=t[h++],A=t[h++],T=t[h++],N=t[h++],C=N+T;h+=1,v&&(o=Ee(T)*S+M,u=We(T)*A+k),d=Be(S,A)*Pe(Ue,Math.abs(N)),e=Ee(C)*S+M,a=We(C)*A+k;break;case Ie.R:o=e=t[h++],u=a=t[h++],d=2*t[h++]+2*t[h++];break;case Ie.Z:var O=o-e;m=u-a,d=Math.sqrt(O*O+m*m),e=o,a=u}d>=0&&(s[f++]=d,l+=d)}return this._pathLen=l,l},t.prototype.rebuildPath=function(t,n){var i,r,e,a,o,u,s,l,f,h,c=this.data,v=this._ux,d=this._uy,p=this._len,m=n<1,y=0,g=0,b=0;if(!m||(this._pathSegLen||this._calculateLength(),s=this._pathSegLen,l=n*this._pathLen))t:for(var w=0;w<p;){var x=c[w++],M=1===w;switch(M&&(i=e=c[w],r=a=c[w+1]),x!==Ie.L&&b>0&&(t.lineTo(f,h),b=0),x){case Ie.M:i=e=c[w++],r=a=c[w++],t.moveTo(e,a);break;case Ie.L:o=c[w++],u=c[w++];var k=je(o-e),S=je(u-a);if(k>v||S>d){if(m){if(y+(X=s[g++])>l){t.lineTo(e*(1-(q=(l-y)/X))+o*q,a*(1-q)+u*q);break t}y+=X}t.lineTo(o,u),e=o,a=u,b=0}else{var A=k*k+S*S;A>b&&(f=o,h=u,b=A)}break;case Ie.C:var T=c[w++],N=c[w++],C=c[w++],O=c[w++],I=c[w++],L=c[w++];if(m){if(y+(X=s[g++])>l){Bi(e,T,C,I,q=(l-y)/X,Le),Bi(a,N,O,L,q,De),t.bezierCurveTo(Le[1],De[1],Le[2],De[2],Le[3],De[3]);break t}y+=X}t.bezierCurveTo(T,N,C,O,I,L),e=I,a=L;break;case Ie.Q:if(T=c[w++],N=c[w++],C=c[w++],O=c[w++],m){if(y+(X=s[g++])>l){Ui(e,T,C,q=(l-y)/X,Le),Ui(a,N,O,q,De),t.quadraticCurveTo(Le[1],De[1],Le[2],De[2]);break t}y+=X}t.quadraticCurveTo(T,N,C,O),e=C,a=O;break;case Ie.A:var D=c[w++],_=c[w++],z=c[w++],R=c[w++],F=c[w++],P=c[w++],B=c[w++],E=!c[w++],W=z>R?z:R,j=je(z-R)>.001,H=F+P,U=!1;if(m&&(y+(X=s[g++])>l&&(H=F+P*(l-y)/X,U=!0),y+=X),j&&t.ellipse?t.ellipse(D,_,z,R,B,F,H,E):t.arc(D,_,W,F,H,E),U)break t;M&&(i=Ee(F)*z+D,r=We(F)*R+_),e=Ee(H)*z+D,a=We(H)*R+_;break;case Ie.R:i=e=c[w],r=a=c[w+1],o=c[w++],u=c[w++];var V=c[w++],$=c[w++];if(m){if(y+(X=s[g++])>l){var Y=l-y;t.moveTo(o,u),t.lineTo(o+Pe(Y,V),u),(Y-=V)>0&&t.lineTo(o+V,u+Pe(Y,$)),(Y-=$)>0&&t.lineTo(o+Be(V-Y,0),u+$),(Y-=V)>0&&t.lineTo(o,u+Be($-Y,0));break t}y+=X}t.rect(o,u,V,$);break;case Ie.Z:if(m){var X;if(y+(X=s[g++])>l){var q;t.lineTo(e*(1-(q=(l-y)/X))+i*q,a*(1-q)+r*q);break t}y+=X}t.closePath(),e=i,a=r}}},t.prototype.clone=function(){var n=new t,i=this.data;return n.data=i.slice?i.slice():Array.prototype.slice.call(i),n._len=this._len,n},t.prototype.canSave=function(){return!!this._saveData},t.CMD=Ie,t.initDefaultProps=((n=t.prototype)._saveData=!0,n._ux=0,n._uy=0,n._pendingPtDist=0,void(n._version=0)),t}();function Ge(t,n,i,r,e,a,o){if(0===e)return!1;var u,s=e;if(o>n+s&&o>r+s||o<n-s&&o<r-s||a>t+s&&a>i+s||a<t-s&&a<i-s)return!1;if(t===i)return Math.abs(a-t)<=s/2;var l=(u=(n-r)/(t-i))*a-o+(t*r-i*n)/(t-i);return l*l/(u*u+1)<=s/2*s/2}function Ze(t,n,i,r,e,a,o,u,s,l,f){if(0===s)return!1;var h=s;if(f>n+h&&f>r+h&&f>a+h&&f>u+h||f<n-h&&f<r-h&&f<a-h&&f<u-h||l>t+h&&l>i+h&&l>e+h&&l>o+h||l<t-h&&l<i-h&&l<e-h&&l<o-h)return!1;var c=function(t,n,i,r,e,a,o,u,s,l){var f,h,c,v,d,p=.005,m=1/0;Oi[0]=s,Oi[1]=l;for(var y=0;y<1;y+=.05)Ii[0]=zi(t,i,e,o,y),Ii[1]=zi(n,r,a,u,y),(v=ln(Oi,Ii))<m&&(f=y,m=v);m=1/0;for(var g=0;g<32&&!(p<Ti);g++)c=f+p,Ii[0]=zi(t,i,e,o,h=f-p),Ii[1]=zi(n,r,a,u,h),v=ln(Ii,Oi),h>=0&&v<m?(f=h,m=v):(Li[0]=zi(t,i,e,o,c),Li[1]=zi(n,r,a,u,c),d=ln(Li,Oi),c<=1&&d<m?(f=c,m=d):p*=.5);return Ai(m)}(t,n,i,r,e,a,o,u,l,f);return c<=h/2}function Je(t,n,i,r,e,a,o,u,s){if(0===o)return!1;var l=o;if(s>n+l&&s>r+l&&s>a+l||s<n-l&&s<r-l&&s<a-l||u>t+l&&u>i+l&&u>e+l||u<t-l&&u<i-l&&u<e-l)return!1;var f=function(t,n,i,r,e,a,o,u){var s,l=.005,f=1/0;Oi[0]=o,Oi[1]=u;for(var h=0;h<1;h+=.05)Ii[0]=Wi(t,i,e,h),Ii[1]=Wi(n,r,a,h),(p=ln(Oi,Ii))<f&&(s=h,f=p);f=1/0;for(var c=0;c<32&&!(l<Ti);c++){var v=s-l,d=s+l;Ii[0]=Wi(t,i,e,v),Ii[1]=Wi(n,r,a,v);var p=ln(Ii,Oi);if(v>=0&&p<f)s=v,f=p;else{Li[0]=Wi(t,i,e,d),Li[1]=Wi(n,r,a,d);var m=ln(Li,Oi);d<=1&&m<f?(s=d,f=m):l*=.5}}return Ai(f)}(t,n,i,r,e,a,u,s);return f<=l/2}var Ke=2*Math.PI;function Qe(t){return(t%=Ke)<0&&(t+=Ke),t}var ta=2*Math.PI;function na(t,n,i,r,e,a,o,u,s){if(0===o)return!1;var l=o;u-=t,s-=n;var f=Math.sqrt(u*u+s*s);if(f-l>i||f+l<i)return!1;if(Math.abs(r-e)%ta<1e-4)return!0;if(a){var h=r;r=Qe(e),e=Qe(h)}else r=Qe(r),e=Qe(e);r>e&&(e+=ta);var c=Math.atan2(s,u);return c<0&&(c+=ta),c>=r&&c<=e||c+ta>=r&&c+ta<=e}function ia(t,n,i,r,e,a){if(a>n&&a>r||a<n&&a<r)return 0;if(r===n)return 0;var o=(a-n)/(r-n),u=r<n?1:-1;1!==o&&0!==o||(u=r<n?.5:-.5);var s=o*(i-t)+t;return s===e?1/0:s>e?u:0}var ra=qe.CMD,ea=2*Math.PI,aa=[-1,-1,-1],oa=[-1,-1];function ua(t,n,i,r,e,a,o,u,s,l){if(l>n&&l>r&&l>a&&l>u||l<n&&l<r&&l<a&&l<u)return 0;var f,h=Fi(n,r,a,u,l,aa);if(0===h)return 0;for(var c=0,v=-1,d=void 0,p=void 0,m=0;m<h;m++){var y=aa[m],g=0===y||1===y?.5:1;zi(t,i,e,o,y)<s||(v<0&&(v=Pi(n,r,a,u,oa),oa[1]<oa[0]&&v>1&&(void 0,f=oa[0],oa[0]=oa[1],oa[1]=f),d=zi(n,r,a,u,oa[0]),v>1&&(p=zi(n,r,a,u,oa[1]))),c+=2===v?y<oa[0]?d<n?g:-g:y<oa[1]?p<d?g:-g:u<p?g:-g:y<oa[0]?d<n?g:-g:u<d?g:-g)}return c}function sa(t,n,i,r,e,a,o,u){if(u>n&&u>r&&u>a||u<n&&u<r&&u<a)return 0;var s=function(t,n,i,r,e){var a=t-2*n+i,o=2*(n-t),u=t-r,s=0;if(Di(a))_i(o)&&(f=-u/o)>=0&&f<=1&&(e[s++]=f);else{var l=o*o-4*a*u;if(Di(l))(f=-o/(2*a))>=0&&f<=1&&(e[s++]=f);else if(l>0){var f,h=Ai(l),c=(-o-h)/(2*a);(f=(-o+h)/(2*a))>=0&&f<=1&&(e[s++]=f),c>=0&&c<=1&&(e[s++]=c)}}return s}(n,r,a,u,aa);if(0===s)return 0;var l=Hi(n,r,a);if(l>=0&&l<=1){for(var f=0,h=Wi(n,r,a,l),c=0;c<s;c++){var v=0===aa[c]||1===aa[c]?.5:1;Wi(t,i,e,aa[c])<o||(f+=aa[c]<l?h<n?v:-v:a<h?v:-v)}return f}return v=0===aa[0]||1===aa[0]?.5:1,Wi(t,i,e,aa[0])<o?0:a<n?v:-v}function la(t,n,i,r,e,a,o,u){if((u-=n)>i||u<-i)return 0;var s=Math.sqrt(i*i-u*u);aa[0]=-s,aa[1]=s;var l=Math.abs(r-e);if(l<1e-4)return 0;if(l>=ea-1e-4){r=0,e=ea;var f=a?1:-1;return o>=aa[0]+t&&o<=aa[1]+t?f:0}if(r>e){var h=r;r=e,e=h}r<0&&(r+=ea,e+=ea);for(var c=0,v=0;v<2;v++){var d=aa[v];if(d+t>o){var p=Math.atan2(u,d);f=a?1:-1,p<0&&(p=ea+p),(p>=r&&p<=e||p+ea>=r&&p+ea<=e)&&(p>Math.PI/2&&p<1.5*Math.PI&&(f=-f),c+=f)}}return c}function fa(t,n,i,r,e){for(var a,o,u=t.data,s=t.len(),l=0,f=0,h=0,c=0,v=0,d=0;d<s;){var p=u[d++],m=1===d;switch(p===ra.M&&d>1&&(i||(l+=ia(f,h,c,v,r,e))),m&&(c=f=u[d],v=h=u[d+1]),p){case ra.M:f=c=u[d++],h=v=u[d++];break;case ra.L:if(i){if(Ge(f,h,u[d],u[d+1],n,r,e))return!0}else l+=ia(f,h,u[d],u[d+1],r,e)||0;f=u[d++],h=u[d++];break;case ra.C:if(i){if(Ze(f,h,u[d++],u[d++],u[d++],u[d++],u[d],u[d+1],n,r,e))return!0}else l+=ua(f,h,u[d++],u[d++],u[d++],u[d++],u[d],u[d+1],r,e)||0;f=u[d++],h=u[d++];break;case ra.Q:if(i){if(Je(f,h,u[d++],u[d++],u[d],u[d+1],n,r,e))return!0}else l+=sa(f,h,u[d++],u[d++],u[d],u[d+1],r,e)||0;f=u[d++],h=u[d++];break;case ra.A:var y=u[d++],g=u[d++],b=u[d++],w=u[d++],x=u[d++],M=u[d++];d+=1;var k=!!(1-u[d++]);a=Math.cos(x)*b+y,o=Math.sin(x)*w+g,m?(c=a,v=o):l+=ia(f,h,a,o,r,e);var S=(r-y)*w/b+y;if(i){if(na(y,g,w,x,x+M,k,n,S,e))return!0}else l+=la(y,g,w,x,x+M,k,S,e);f=Math.cos(x+M)*b+y,h=Math.sin(x+M)*w+g;break;case ra.R:if(c=f=u[d++],v=h=u[d++],a=c+u[d++],o=v+u[d++],i){if(Ge(c,v,a,v,n,r,e)||Ge(a,v,a,o,n,r,e)||Ge(a,o,c,o,n,r,e)||Ge(c,o,c,v,n,r,e))return!0}else l+=ia(a,v,a,o,r,e),l+=ia(c,o,c,v,r,e);break;case ra.Z:if(i){if(Ge(f,h,c,v,n,r,e))return!0}else l+=ia(f,h,c,v,r,e);f=c,h=v}}return i||Math.abs(h-v)<1e-4||(l+=ia(f,h,c,v,r,e)||0),0!==l}var ha=B({fill:"#000",stroke:null,strokePercent:1,fillOpacity:1,strokeOpacity:1,lineDashOffset:0,lineWidth:1,lineCap:"butt",miterLimit:10,strokeNoScale:!1,strokeFirst:!1},le),ca={style:B({fill:!0,stroke:!0,strokePercent:!0,fillOpacity:!0,strokeOpacity:!0,lineDashOffset:!0,lineWidth:!0,miterLimit:!0},fe.style)},va=xi.concat(["invisible","culling","z","z2","zlevel","parent"]),da=function(t){function n(n){return t.call(this,n)||this}var i;return Et(n,t),n.prototype.update=function(){var i=this;t.prototype.update.call(this);var r=this.style;if(r.decal){var e=this._decalEl=this._decalEl||new n;e.buildPath===n.prototype.buildPath&&(e.buildPath=function(t){i.buildPath(t,i.shape)}),e.silent=!0;var a=e.style;for(var o in r)a[o]!==r[o]&&(a[o]=r[o]);a.fill=r.fill?r.decal:null,a.decal=null,a.shadowColor=null,r.strokeFirst&&(a.stroke=null);for(var u=0;u<va.length;++u)e[va[u]]=this[va[u]];e.__dirty|=1}else this._decalEl&&(this._decalEl=null)},n.prototype.getDecalElement=function(){return this._decalEl},n.prototype._init=function(n){var i=Y(n);this.shape=this.getDefaultShape();var r=this.getDefaultStyle();r&&this.useStyle(r);for(var e=0;e<i.length;e++){var a=i[e],o=n[a];"style"===a?this.style?P(this.style,o):this.useStyle(o):"shape"===a?P(this.shape,o):t.prototype.attrKV.call(this,a,o)}this.style||this.useStyle({})},n.prototype.getDefaultStyle=function(){return null},n.prototype.getDefaultShape=function(){return{}},n.prototype.canBeInsideText=function(){return this.hasFill()},n.prototype.getInsideTextFill=function(){var t=this.style.fill;if("none"!==t){if(J(t)){var n=hr(t,0);return n>.5?Yr:n>.2?"#eee":Xr}if(t)return Xr}return Yr},n.prototype.getInsideTextStroke=function(t){var n=this.style.fill;if(J(n)){var i=this.__zr;if(!(!i||!i.isDarkMode())==hr(t,0)<.4)return n}},n.prototype.buildPath=function(){},n.prototype.pathUpdated=function(){this.__dirty&=-5},n.prototype.getUpdatedPathProxy=function(t){return!this.path&&this.createPathProxy(),this.path.beginPath(),this.buildPath(this.path,this.shape,t),this.path},n.prototype.createPathProxy=function(){this.path=new qe(!1)},n.prototype.hasStroke=function(){var t=this.style,n=t.stroke;return!(null==n||"none"===n||!(t.lineWidth>0))},n.prototype.hasFill=function(){var t=this.style.fill;return null!=t&&"none"!==t},n.prototype.getBoundingRect=function(){var t=this._rect,n=this.style,i=!t;if(i){var r=!1;this.path||(r=!0,this.createPathProxy());var e=this.path;(r||4&this.__dirty)&&(e.beginPath(),this.buildPath(e,this.shape,!1),this.pathUpdated()),t=e.getBoundingRect()}if(this._rect=t,this.hasStroke()&&this.path&&this.path.len()>0){var a=this._rectStroke||(this._rectStroke=t.clone());if(this.__dirty||i){a.copy(t);var o=n.strokeNoScale?this.getLineScale():1,u=n.lineWidth;if(!this.hasFill()){var s=this.strokeContainThreshold;u=Math.max(u,null==s?4:s)}o>1e-10&&(a.width+=u/o,a.height+=u/o,a.x-=u/o/2,a.y-=u/o/2)}return a}return t},n.prototype.contain=function(t,n){var i=this.transformCoordToLocal(t,n),r=this.getBoundingRect(),e=this.style;if(r.contain(t=i[0],n=i[1])){var a=this.path;if(this.hasStroke()){var o=e.lineWidth,u=e.strokeNoScale?this.getLineScale():1;if(u>1e-10&&(this.hasFill()||(o=Math.max(o,this.strokeContainThreshold)),function(t,n,i,r){return fa(t,n,!0,i,r)}(a,o/u,t,n)))return!0}if(this.hasFill())return function(t,n,i){return fa(t,0,!1,n,i)}(a,t,n)}return!1},n.prototype.dirtyShape=function(){this.__dirty|=4,this._rect&&(this._rect=null),this._decalEl&&this._decalEl.dirtyShape(),this.markRedraw()},n.prototype.dirty=function(){this.dirtyStyle(),this.dirtyShape()},n.prototype.animateShape=function(t){return this.animate("shape",t)},n.prototype.updateDuringAnimation=function(t){"style"===t?this.dirtyStyle():"shape"===t?this.dirtyShape():this.markRedraw()},n.prototype.attrKV=function(n,i){"shape"===n?this.setShape(i):t.prototype.attrKV.call(this,n,i)},n.prototype.setShape=function(t,n){var i=this.shape;return i||(i=this.shape={}),"string"==typeof t?i[t]=n:P(i,t),this.dirtyShape(),this},n.prototype.shapeChanged=function(){return!!(4&this.__dirty)},n.prototype.createStyle=function(t){return wt(ha,t)},n.prototype._innerSaveToNormal=function(n){t.prototype._innerSaveToNormal.call(this,n);var i=this._normalState;n.shape&&!i.shape&&(i.shape=P({},this.shape))},n.prototype._applyStateObj=function(n,i,r,e,a,o){if(t.prototype._applyStateObj.call(this,n,i,r,e,a,o),1!==this.__inHover){var u,s=!(i&&e);if(i&&i.shape?a?e?u=i.shape:(u=P({},r.shape),P(u,i.shape)):(u=P({},e?this.shape:r.shape),P(u,i.shape)):s&&(u=r.shape),u)if(a){this.shape=P({},this.shape);for(var l={},f=Y(u),h=0;h<f.length;h++){var c=f[h];"object"==typeof u[c]?this.shape[c]=u[c]:l[c]=u[c]}this._transitionState(n,{shape:l},o)}else this.shape=u,this.dirtyShape()}},n.prototype._mergeStates=function(n){for(var i,r=t.prototype._mergeStates.call(this,n),e=0;e<n.length;e++){var a=n[e];a.shape&&this._mergeStyle(i=i||{},a.shape)}return i&&(r.shape=i),r},n.prototype.getAnimationStyleProps=function(){return ca},n.prototype.isZeroArea=function(){return!1},n.extend=function(t){var i=function(n){function i(i){var r=n.call(this,i)||this;return t.init&&t.init.call(r,i),r}return Et(i,n),i.prototype.getDefaultStyle=function(){return R(t.style)},i.prototype.getDefaultShape=function(){return R(t.shape)},i}(n);for(var r in t)"function"==typeof t[r]&&(i.prototype[r]=t[r]);return i},n.initDefaultProps=((i=n.prototype).type="path",i.strokeContainThreshold=5,i.segmentIgnoreThreshold=0,i.subPixelOptimize=!1,i.autoBatch=!1,void(i.__dirty=7)),n}(ve),pa=B({strokeFirst:!0,font:y,x:0,y:0,textAlign:"left",textBaseline:"top",miterLimit:2},ha),ma=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return Et(n,t),n.prototype.hasStroke=function(){return ci(this.style)},n.prototype.hasFill=function(){var t=this.style.fill;return null!=t&&"none"!==t},n.prototype.createStyle=function(t){return wt(pa,t)},n.prototype.setBoundingRect=function(t){this._rect=t},n.prototype.getBoundingRect=function(){var t,n,i;return this._rect||(this._rect=(n=fi((t=this.style).text),hi(t,jn(Bn(i=t.font),n),Yn(i),null))),this._rect},n.initDefaultProps=void(n.prototype.dirtyRectTolerance=10),n}(ve);ma.prototype.type="tspan";var ya=B({x:0,y:0},le),ga={style:B({x:!0,y:!0,width:!0,height:!0,sx:!0,sy:!0,sWidth:!0,sHeight:!0},fe.style)},ba=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return Et(n,t),n.prototype.createStyle=function(t){return wt(ya,t)},n.prototype._getSize=function(t){var n=this.style,i=n[t];if(null!=i)return i;var r,e=(r=n.image)&&"string"!=typeof r&&r.width&&r.height?n.image:this.__image;if(!e)return 0;var a="width"===t?"height":"width",o=n[a];return null==o?e[t]:e[t]/e[a]*o},n.prototype.getWidth=function(){return this._getSize("width")},n.prototype.getHeight=function(){return this._getSize("height")},n.prototype.getAnimationStyleProps=function(){return ga},n.prototype.getBoundingRect=function(){var t=this.style;return this._rect||(this._rect=new On(t.x||0,t.y||0,this.getWidth(),this.getHeight())),this._rect},n}(ve);ba.prototype.type="image";var wa=Math.round;function xa(t,n,i){if(n){var r=n.x1,e=n.x2,a=n.y1,o=n.y2;t.x1=r,t.x2=e,t.y1=a,t.y2=o;var u=i&&i.lineWidth;return u?(wa(2*r)===wa(2*e)&&(t.x1=t.x2=ka(r,u,!0)),wa(2*a)===wa(2*o)&&(t.y1=t.y2=ka(a,u,!0)),t):t}}function Ma(t,n,i){if(n){var r=n.x,e=n.y,a=n.width,o=n.height;t.x=r,t.y=e,t.width=a,t.height=o;var u=i&&i.lineWidth;return u?(t.x=ka(r,u,!0),t.y=ka(e,u,!0),t.width=Math.max(ka(r+a,u,!1)-t.x,0===a?0:1),t.height=Math.max(ka(e+o,u,!1)-t.y,0===o?0:1),t):t}}function ka(t,n,i){if(!n)return t;var r=wa(2*t);return(r+wa(n))%2==0?r/2:(r+(i?1:-1))/2}var Sa=function(){this.x=0,this.y=0,this.width=0,this.height=0},Aa={},Ta=function(t){function n(n){return t.call(this,n)||this}return Et(n,t),n.prototype.getDefaultShape=function(){return new Sa},n.prototype.buildPath=function(t,n){var i,r,e,a;if(this.subPixelOptimize){var o=Ma(Aa,n,this.style);i=o.x,r=o.y,e=o.width,a=o.height,o.r=n.r,n=o}else i=n.x,r=n.y,e=n.width,a=n.height;n.r?function(t,n){var i,r,e,a,o,u=n.x,s=n.y,l=n.width,f=n.height,h=n.r;l<0&&(u+=l,l=-l),f<0&&(s+=f,f=-f),"number"==typeof h?i=r=e=a=h:h instanceof Array?1===h.length?i=r=e=a=h[0]:2===h.length?(i=e=h[0],r=a=h[1]):3===h.length?(i=h[0],r=a=h[1],e=h[2]):(i=h[0],r=h[1],e=h[2],a=h[3]):i=r=e=a=0,i+r>l&&(i*=l/(o=i+r),r*=l/o),e+a>l&&(e*=l/(o=e+a),a*=l/o),r+e>f&&(r*=f/(o=r+e),e*=f/o),i+a>f&&(i*=f/(o=i+a),a*=f/o),t.moveTo(u+i,s),t.lineTo(u+l-r,s),0!==r&&t.arc(u+l-r,s+r,r,-Math.PI/2,0),t.lineTo(u+l,s+f-e),0!==e&&t.arc(u+l-e,s+f-e,e,0,Math.PI/2),t.lineTo(u+a,s+f),0!==a&&t.arc(u+a,s+f-a,a,Math.PI/2,Math.PI),t.lineTo(u,s+i),0!==i&&t.arc(u+i,s+i,i,Math.PI,1.5*Math.PI),t.closePath()}(t,n):t.rect(i,r,e,a)},n.prototype.isZeroArea=function(){return!this.shape.width||!this.shape.height},n}(da);Ta.prototype.type="rect";var Na={fill:"#000"},Ca={},Oa={style:B({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},fe.style)},Ia=function(t){function n(n){var i=t.call(this)||this;return i.type="text",i._children=[],i._defaultStyle=Na,i.attr(n),i}return Et(n,t),n.prototype.childrenRef=function(){return this._children},n.prototype.update=function(){t.prototype.update.call(this),this.styleChanged()&&this._updateSubTexts();for(var n=0;n<this._children.length;n++){var i=this._children[n];i.zlevel=this.zlevel,i.z=this.z,i.z2=this.z2,i.culling=this.culling,i.cursor=this.cursor,i.invisible=this.invisible}},n.prototype.updateTransform=function(){var n=this.innerTransformable;n?(n.updateTransform(),n.transform&&(this.transform=n.transform)):t.prototype.updateTransform.call(this)},n.prototype.getLocalTransform=function(n){var i=this.innerTransformable;return i?i.getLocalTransform(n):t.prototype.getLocalTransform.call(this,n)},n.prototype.getComputedTransform=function(){return this.__hostTarget&&(this.__hostTarget.getComputedTransform(),this.__hostTarget.updateInnerText(!0)),t.prototype.getComputedTransform.call(this)},n.prototype._updateSubTexts=function(){var t;this._childCursor=0,Pa(t=this.style),H(t.rich,Pa),this.style.rich?this._updateRichTexts():this._updatePlainTexts(),this._children.length=this._childCursor,this.styleUpdated()},n.prototype.addSelfToZr=function(n){t.prototype.addSelfToZr.call(this,n);for(var i=0;i<this._children.length;i++)this._children[i].__zr=n},n.prototype.removeSelfFromZr=function(n){t.prototype.removeSelfFromZr.call(this,n);for(var i=0;i<this._children.length;i++)this._children[i].__zr=null},n.prototype.getBoundingRect=function(){if(this.styleChanged()&&this._updateSubTexts(),!this._rect){for(var t=new On(0,0,0,0),n=this._children,i=[],r=null,e=0;e<n.length;e++){var a=n[e],o=a.getBoundingRect(),u=a.getLocalTransform(i);u?(t.copy(o),t.applyTransform(u),(r=r||t.clone()).union(t)):(r=r||o.clone()).union(o)}this._rect=r||t}return this._rect},n.prototype.setDefaultTextStyle=function(t){this._defaultStyle=t||Na},n.prototype.setTextContent=function(){},n.prototype._mergeStyle=function(t,n){if(!n)return t;var i=n.rich,r=t.rich||i&&{};return P(t,n),i&&r?(this._mergeRich(r,i),t.rich=r):r&&(t.rich=r),t},n.prototype._mergeRich=function(t,n){for(var i=Y(n),r=0;r<i.length;r++){var e=i[r];t[e]=t[e]||{},P(t[e],n[e])}},n.prototype.getAnimationStyleProps=function(){return Oa},n.prototype._getOrCreateChild=function(t){var n=this._children[this._childCursor];return n&&n instanceof t||(n=new t),this._children[this._childCursor++]=n,n.__zr=this.__zr,n.parent=this,n},n.prototype._updatePlainTexts=function(){var t=this.style,n=t.font||y,i=t.padding,r=this._defaultStyle,e=t.x||0,a=t.y||0,o=t.align||r.align||"left",u=t.verticalAlign||r.verticalAlign||"top";ui(Ca,r.overflowRect,e,a,o,u),e=Ca.baseX,a=Ca.baseY;var s=function(t,n,i,r){var e=fi(t),a=n.overflow,o=n.padding,u=o?o[1]+o[3]:0,s=o?o[0]+o[2]:0,l=n.font,f="truncate"===a,h=Yn(l),c=ut(n.lineHeight,h),v="truncate"===n.lineOverflow,d=!1,p=n.width;null==p&&null!=i&&(p=i-u);var m,y=n.height;null==y&&null!=r&&(y=r-s);var g=(m=null==p||"break"!==a&&"breakAll"!==a?e?e.split("\n"):[]:e?oi(e,n.font,p,"breakAll"===a,0).lines:[]).length*c;if(null==y&&(y=g),g>y&&v){var b=Math.floor(y/c);d=d||m.length>b,g=(m=m.slice(0,b)).length*c}if(e&&f&&null!=p)for(var w=Jn(p,l,n.ellipsis,{minChar:n.truncateMinChar,placeholder:n.placeholder}),x={},M=0;M<m.length;M++)Kn(x,m[M],w),m[M]=x.textLine,d=d||x.isTruncated;var k=y,S=0,A=Bn(l);for(M=0;M<m.length;M++)S=Math.max(jn(A,m[M]),S);null==p&&(p=S);var T=p;return{lines:m,height:y,outerWidth:T+=u,outerHeight:k+=s,lineHeight:c,calculatedLineHeight:h,contentWidth:S,contentHeight:g,width:p,isTruncated:d}}(ja(t),t,Ca.outerWidth,Ca.outerHeight),l=Ha(t),f=!!t.backgroundColor,h=s.outerHeight,c=s.outerWidth,v=s.lines,d=s.lineHeight;this.isTruncated=!!s.isTruncated;var p=e,m=$n(a,s.contentHeight,u);if(l||i){var g=Vn(e,c,o),b=$n(a,h,u);l&&this._renderBackground(t,t,g,b,c,h)}m+=d/2,i&&(p=Wa(e,o,i),"top"===u?m+=i[0]:"bottom"===u&&(m-=i[2]));for(var w=0,x=!1,M=!1,k=(Ea("fill"in t?t.fill:(M=!0,r.fill))),S=(Ba("stroke"in t?t.stroke:f||r.autoStroke&&!M?null:(w=2,x=!0,r.stroke))),A=t.textShadowBlur>0,T=0;T<v.length;T++){var N=this._getOrCreateChild(ma),C=N.createStyle();N.useStyle(C),C.text=v[T],C.x=p,C.y=m,C.textAlign=o,C.textBaseline="middle",C.opacity=t.opacity,C.strokeFirst=!0,A&&(C.shadowBlur=t.textShadowBlur||0,C.shadowColor=t.textShadowColor||"transparent",C.shadowOffsetX=t.textShadowOffsetX||0,C.shadowOffsetY=t.textShadowOffsetY||0),C.stroke=S,C.fill=k,S&&(C.lineWidth=t.lineWidth||w,C.lineDash=t.lineDash,C.lineDashOffset=t.lineDashOffset||0),C.font=n,Ra(C,t),m+=d,N.setBoundingRect(hi(C,s.contentWidth,s.calculatedLineHeight,x?0:null))}},n.prototype._updateRichTexts=function(){var t=this.style,n=this._defaultStyle,i=t.align||n.align,r=t.verticalAlign||n.verticalAlign,e=t.x||0,a=t.y||0;ui(Ca,n.overflowRect,e,a,i,r),e=Ca.baseX,a=Ca.baseY;var o=function(t,n,i,r,e){var a=new ii,o=fi(t);if(!o)return a;var u=n.padding,s=u?u[1]+u[3]:0,l=u?u[0]+u[2]:0,f=n.width;null==f&&null!=i&&(f=i-s);var h=n.height;null==h&&null!=r&&(h=r-l);for(var c,v=n.overflow,d="break"!==v&&"breakAll"!==v||null==f?null:{width:f,accumWidth:0,breakAll:"breakAll"===v},p=Gn.lastIndex=0;null!=(c=Gn.exec(o));){var m=c.index;m>p&&ri(a,o.substring(p,m),n,d),ri(a,c[2],n,d,c[1]),p=Gn.lastIndex}p<o.length&&ri(a,o.substring(p,o.length),n,d);var y=[],g=0,b=0,w="truncate"===v,x="truncate"===n.lineOverflow,M={};function k(t,n,i){t.width=n,t.lineHeight=i,g+=i,b=Math.max(b,n)}t:for(var S=0;S<a.lines.length;S++){for(var A=a.lines[S],T=0,N=0,C=0;C<A.tokens.length;C++){var O=(W=A.tokens[C]).styleName&&n.rich[W.styleName]||{},I=W.textPadding=O.padding,L=I?I[1]+I[3]:0,D=W.font=O.font||n.font;W.contentHeight=Yn(D);var _=ut(O.height,W.contentHeight);if(W.innerHeight=_,I&&(_+=I[0]+I[2]),W.height=_,W.lineHeight=st(O.lineHeight,n.lineHeight,_),W.align=O&&O.align||e,W.verticalAlign=O&&O.verticalAlign||"middle",x&&null!=h&&g+W.lineHeight>h){var z=a.lines.length;C>0?(A.tokens=A.tokens.slice(0,C),k(A,N,T),a.lines=a.lines.slice(0,S+1)):a.lines=a.lines.slice(0,S),a.isTruncated=a.isTruncated||a.lines.length<z;break t}var R=O.width,F=null==R||"auto"===R;if("string"==typeof R&&"%"===R.charAt(R.length-1))W.percentWidth=R,y.push(W),W.contentWidth=jn(Bn(D),W.text);else{if(F){var P=O.backgroundColor,B=P&&P.image;B&&Xt(B=Vt(B))&&(W.width=Math.max(W.width,B.width*_/B.height))}var E=w&&null!=f?f-N:null;null!=E&&E<W.width?!F||E<L?(W.text="",W.width=W.contentWidth=0):(Zn(M,W.text,E-L,D,n.ellipsis,{minChar:n.truncateMinChar}),W.text=M.text,a.isTruncated=a.isTruncated||M.isTruncated,W.width=W.contentWidth=jn(Bn(D),W.text)):W.contentWidth=jn(Bn(D),W.text)}W.width+=L,N+=W.width,O&&(T=Math.max(T,W.lineHeight))}k(A,N,T)}for(a.outerWidth=a.width=ut(f,b),a.outerHeight=a.height=ut(h,g),a.contentHeight=g,a.contentWidth=b,a.outerWidth+=s,a.outerHeight+=l,S=0;S<y.length;S++){var W;(W=y[S]).width=parseInt(W.percentWidth,10)/100*a.width}return a}(ja(t),t,Ca.outerWidth,Ca.outerHeight,i),u=o.width,s=o.outerWidth,l=o.outerHeight,f=t.padding;this.isTruncated=!!o.isTruncated;var h=Vn(e,s,i),c=$n(a,l,r),v=h,d=c;f&&(v+=f[3],d+=f[0]);var p=v+u;Ha(t)&&this._renderBackground(t,t,h,c,s,l);for(var m=!!t.backgroundColor,y=0;y<o.lines.length;y++){for(var g=o.lines[y],b=g.tokens,w=b.length,x=g.lineHeight,M=g.width,k=0,S=v,A=p,T=w-1,N=void 0;k<w&&(!(N=b[k]).align||"left"===N.align);)this._placeToken(N,t,x,d,S,"left",m),M-=N.width,S+=N.width,k++;for(;T>=0&&"right"===(N=b[T]).align;)this._placeToken(N,t,x,d,A,"right",m),M-=N.width,A-=N.width,T--;for(S+=(u-(S-v)-(p-A)-M)/2;k<=T;)this._placeToken(N=b[k],t,x,d,S+N.width/2,"center",m),S+=N.width,k++;d+=x}},n.prototype._placeToken=function(t,n,i,r,e,a,o){var u=n.rich[t.styleName]||{};u.text=t.text;var s=t.verticalAlign,l=r+i/2;"top"===s?l=r+t.height/2:"bottom"===s&&(l=r+i-t.height/2),!t.isLineHolder&&Ha(u)&&this._renderBackground(u,n,"right"===a?e-t.width:"center"===a?e-t.width/2:e,l-t.height/2,t.width,t.height);var f=!!u.backgroundColor,h=t.textPadding;h&&(e=Wa(e,a,h),l-=t.height/2-h[0]-t.innerHeight/2);var c=this._getOrCreateChild(ma),v=c.createStyle();c.useStyle(v);var d=this._defaultStyle,p=!1,m=0,g=!1,b=Ea("fill"in u?u.fill:"fill"in n?n.fill:(p=!0,d.fill)),w=Ba("stroke"in u?u.stroke:"stroke"in n?n.stroke:f||o||d.autoStroke&&!p?null:(m=2,g=!0,d.stroke)),x=u.textShadowBlur>0||n.textShadowBlur>0;v.text=t.text,v.x=e,v.y=l,x&&(v.shadowBlur=u.textShadowBlur||n.textShadowBlur||0,v.shadowColor=u.textShadowColor||n.textShadowColor||"transparent",v.shadowOffsetX=u.textShadowOffsetX||n.textShadowOffsetX||0,v.shadowOffsetY=u.textShadowOffsetY||n.textShadowOffsetY||0),v.textAlign=a,v.textBaseline="middle",v.font=t.font||y,v.opacity=st(u.opacity,n.opacity,1),Ra(v,u),w&&(v.lineWidth=st(u.lineWidth,n.lineWidth,m),v.lineDash=ut(u.lineDash,n.lineDash),v.lineDashOffset=n.lineDashOffset||0,v.stroke=w),b&&(v.fill=b),c.setBoundingRect(hi(v,t.contentWidth,t.contentHeight,g?0:null))},n.prototype._renderBackground=function(t,n,i,r,e,a){var o,u,s,l=t.backgroundColor,f=t.borderWidth,h=t.borderColor,c=l&&l.image,v=l&&!c,d=t.borderRadius,p=this;if(v||t.lineHeight||f&&h){(o=this._getOrCreateChild(Ta)).useStyle(o.createStyle()),o.style.fill=null;var m=o.shape;m.x=i,m.y=r,m.width=e,m.height=a,m.r=d,o.dirtyShape()}if(v)(s=o.style).fill=l||null,s.fillOpacity=ut(t.fillOpacity,1);else if(c){(u=this._getOrCreateChild(ba)).onload=function(){p.dirtyStyle()};var y=u.style;y.image=l.image,y.x=i,y.y=r,y.width=e,y.height=a}f&&h&&((s=o.style).lineWidth=f,s.stroke=h,s.strokeOpacity=ut(t.strokeOpacity,1),s.lineDash=t.borderDash,s.lineDashOffset=t.borderDashOffset||0,o.strokeContainThreshold=0,o.hasFill()&&o.hasStroke()&&(s.strokeFirst=!0,s.lineWidth*=2));var g=(o||u).style;g.shadowBlur=t.shadowBlur||0,g.shadowColor=t.shadowColor||"transparent",g.shadowOffsetX=t.shadowOffsetX||0,g.shadowOffsetY=t.shadowOffsetY||0,g.opacity=st(t.opacity,n.opacity,1)},n.makeFont=function(t){var n="";return Fa(t)&&(n=[t.fontStyle,t.fontWeight,za(t.fontSize),t.fontFamily||"sans-serif"].join(" ")),n&&ct(n)||t.textFont||t.font},n}(ve),La={left:!0,right:1,center:1},Da={top:1,bottom:1,middle:1},_a=["fontStyle","fontWeight","fontSize","fontFamily"];function za(t){return"string"!=typeof t||-1===t.indexOf("px")&&-1===t.indexOf("rem")&&-1===t.indexOf("em")?isNaN(+t)?"12px":t+"px":t}function Ra(t,n){for(var i=0;i<_a.length;i++){var r=_a[i],e=n[r];null!=e&&(t[r]=e)}}function Fa(t){return null!=t.fontSize||t.fontFamily||t.fontWeight}function Pa(t){if(t){t.font=Ia.makeFont(t);var n=t.align;"middle"===n&&(n="center"),t.align=null==n||La[n]?n:"left";var i=t.verticalAlign;"center"===i&&(i="middle"),t.verticalAlign=null==i||Da[i]?i:"top",t.padding&&(t.padding=ft(t.padding))}}function Ba(t,n){return null==t||n<=0||"transparent"===t||"none"===t?null:t.image||t.colorStops?"#000":t}function Ea(t){return null==t||"none"===t?null:t.image||t.colorStops?"#000":t}function Wa(t,n,i){return"right"===n?t-i[1]:"center"===n?t+i[3]/2-i[1]/2:t+i[3]}function ja(t){var n=t.text;return null!=n&&(n+=""),n}function Ha(t){return!!(t.backgroundColor||t.lineHeight||t.borderWidth&&t.borderColor)}var Ua=Math.min,Va=Math.max,$a=Math.abs,Ya=Math.round,Xa=Math.floor,qa=Math.ceil,Ga=Math.pow,Za=Math.log,Ja=Math.LN10,Ka=Math.PI,Qa=Math.random;function to(t,n,i,r){var e=n[0],a=n[1],o=i[0],u=i[1],s=a-e,l=u-o;if(0===s)return 0===l?o:(o+u)/2;if(r)if(s>0){if(t<=e)return o;if(t>=a)return u}else{if(t>=e)return o;if(t<=a)return u}else{if(t===e)return o;if(t===a)return u}return(t-e)/s*l+o}var no=function(t,n,i){switch(t){case"center":case"middle":t="50%";break;case"left":case"top":t="0%";break;case"right":case"bottom":t="100%"}return io(t,n,i)};function io(t,n,i){return J(t)?function(t){return!!(n=t,n.replace(/^\s+|\s+$/g,"")).match(/%$/);var n}(t)?parseFloat(t)/100*n+(i||0):parseFloat(t):null==t?NaN:+t}function ro(t,n,i){return isNaN(n)?i?""+t:+t:(n=Ua(Va(0,n),20),t=(+t).toFixed(n),i?t:+t)}function eo(t){return t.sort((function(t,n){return t-n})),t}function ao(t){if(t=+t,isNaN(t))return 0;if(t>1e-14)for(var n=1,i=0;i<15;i++,n*=10)if(Ya(t*n)/n===t)return i;return function(t){var n=t.toString().toLowerCase(),i=n.indexOf("e"),r=i>0?+n.slice(i+1):0,e=i>0?i:n.length,a=n.indexOf(".");return Va(0,(a<0?0:e-1-a)-r)}(t)}function oo(t,n){var i=Va(ao(t),ao(n)),r=t+n;return i>20?r:ro(r,i)}var uo=Ga(2,53)-1;function so(t){var n=2*Ka;return(t%n+n)%n}function lo(t){return t>-1e-4&&t<1e-4}var fo=/^(?:(\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 ho(t){if(t instanceof Date)return t;if(J(t)){var n=fo.exec(t);if(!n)return new Date(NaN);if(n[8]){var i=+n[4]||0;return"Z"!==n[8].toUpperCase()&&(i-=+n[8].slice(0,3)),new Date(Date.UTC(+n[1],+(n[2]||1)-1,+n[3]||1,i,+(n[5]||0),+n[6]||0,n[7]?+n[7].substring(0,3):0))}return new Date(+n[1],+(n[2]||1)-1,+n[3]||1,+n[4]||0,+(n[5]||0),+n[6]||0,n[7]?+n[7].substring(0,3):0)}return null==t?new Date(NaN):new Date(Ya(t))}function co(t){return Ga(10,vo(t))}function vo(t){if(0===t)return 0;var n=Xa(Za(t)/Ja);return t/Ga(10,n)>=10&&n++,n}function po(t,n){var i=vo(t),r=Ga(10,i),e=t/r;return ro(t=(2===n?1:n?e<1.5?1:e<2.5?2:e<4?3:e<7?5:10:e<1?1:e<2?2:e<3?3:e<5?5:10)*r,-i)}function mo(t){var n=parseFloat(t);return n==t&&(0!==n||!J(t)||t.indexOf("x")<=0)?n:NaN}function yo(){return Ya(9*Qa())}function go(t,n){return 0===n?t:go(n,t%n)}function bo(t,n){return null==t?n:null==n?t:t*n/go(t,n)}function wo(t){return null!=t&&isFinite(t)}var xo="undefined"!=typeof console&&console.warn&&console.log;function Mo(t){!function(t,n){xo&&console.error("[ECharts] "+n)}(0,t)}function ko(t){throw new Error(t)}function So(t,n,i){return(n-t)*i+t}var Ao="series\0";function To(t){return t instanceof Array?t:null==t?[]:[t]}function No(t,n,i){if(t){t[n]=t[n]||{},t.emphasis=t.emphasis||{},t.emphasis[n]=t.emphasis[n]||{};for(var r=0,e=i.length;r<e;r++){var a=i[r];!t.emphasis[n].hasOwnProperty(a)&&t[n].hasOwnProperty(a)&&(t.emphasis[n][a]=t[n][a])}}}var Co=["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 Oo(t){return!tt(t)||G(t)||t instanceof Date?t:t.value}function Io(t){return tt(t)&&!(t instanceof Array)}function Lo(t,n,i){var r=_o(n[t],null),e=_o(i[t],null);return null!=r&&null!=e&&r===e}function Do(t){return _o(t,"")}function _o(t,n){return null==t?n:J(t)?t:Q(t)||K(t)?t+"":n}function zo(t){var n=t.name;return!(!n||!n.indexOf(Ao))}function Ro(t){return t&&null!=t.id&&0===Do(t.id).indexOf("\0_ec_\0")}function Fo(t,n){return null!=n.dataIndexInside?n.dataIndexInside:null!=n.dataIndex?G(n.dataIndex)?U(n.dataIndex,(function(n){return t.indexOfRawIndex(n)})):t.indexOfRawIndex(n.dataIndex):null!=n.name?G(n.name)?U(n.name,(function(n){return t.indexOfName(n)})):t.indexOfName(n.name):void 0}function Po(){var t="__ec_inner_"+Bo++;return function(n){return n[t]||(n[t]={})}}var Bo=yo();function Eo(t,n,i){var r=Wo(n,i),e=r.queryOptionMap,a=r.others,o=i?i.defaultMainType:null;return!r.mainTypeSpecified&&o&&e.set(o,{}),e.each((function(n,r){var e=Ho(t,r,n,{useDefault:o===r,enableAll:!i||null==i.enableAll||i.enableAll,enableNone:!i||null==i.enableNone||i.enableNone});a[r+"Models"]=e.models,a[r+"Model"]=e.models[0]})),a}function Wo(t,n){var i;if(J(t)){var r={};r[t+"Index"]=0,i=r}else i=t;var e=bt(),a={},o=!1;return H(i,(function(t,i){if("dataIndex"!==i&&"dataIndexInside"!==i){var r=i.match(/^(\w+)(Index|Id|Name)$/)||[],u=r[1],s=(r[2]||"").toLowerCase();!u||!s||n&&n.includeMainTypes&&E(n.includeMainTypes,u)<0||(o=o||!!u,(e.get(u)||e.set(u,{}))[s]=t)}else a[i]=t})),{mainTypeSpecified:o,queryOptionMap:e,others:a}}var jo={useDefault:!0,enableAll:!1,enableNone:!1};function Ho(t,n,i,r){r=r||jo;var e=i.index,a=i.id,o=i.name,u={models:null,specified:null!=e||null!=a||null!=o};if(!u.specified){var s=void 0;return u.models=r.useDefault&&(s=t.getComponent(n))?[s]:[],u}if("none"===e||!1===e){if(r.enableNone)return u.models=[],u;e=-1}return"all"===e&&(e=r.enableAll?a=o=null:-1),u.models=t.queryComponents({mainType:n,index:e,id:a,name:o}),u}function Uo(t,n,i){t.setAttribute?t.setAttribute(n,i):t[n]=i}function Vo(t,n,i,r,e){var a=null==n||"auto"===n;if(null==r)return r;if(Q(r))return ro(d=So(i||0,r,e),a?Math.max(ao(i||0),ao(r)):n);if(J(r))return e<1?i:r;for(var o=[],u=i,s=r,l=Math.max(u?u.length:0,s.length),f=0;f<l;++f){var h=t.getDimensionInfo(f);if(h&&"ordinal"===h.type)o[f]=(e<1&&u?u:s)[f];else{var c=u&&u[f]?u[f]:0,v=s[f],d=So(c,v,e);o[f]=ro(d,a?Math.max(ao(c),ao(v)):n)}}return o}function $o(t,n){qo(n)&&(n<t[0]&&(t[0]=n),n>t[1]&&(t[1]=n))}function Yo(t,n){qo(n)&&n<t[0]&&(t[0]=n)}function Xo(t,n){qo(n)&&n>t[1]&&(t[1]=n)}function qo(t){return null!=t&&isFinite(t)}function Go(t,n){return qo(t)&&qo(n)&&t<=n}function Zo(){var t="__ec_once_"+Jo++;return function(n,i){xt(n,t)||(n[t]=1,i())}}var Jo=yo();function Ko(t,n,i){var r=bt(),e=0;H(t,(function(a){var o=n(a),u=r.get(o)||0;i&&i(a,u),u||i||(t[e++]=a),r.set(o,u+1)})),i||(t.length=e)}function Qo(t){return t.value+""}function tu(t){return t+""}function nu(t,n){return ut(n,!0)?t.seriesIndex+2:0}function iu(t,n,i){var r=t.getData().count();return{progressiveRender:i.progressiveEnabled&&n.incrementalPrepareRender&&r>=i.threshold,large:t.get("large")&&r>=t.get("largeThreshold"),modDataCount:"mod"===t.get("progressiveChunkMode")?t.getData().count():null}}function ru(t,n){return{seriesType:t,overallReset:n}}function eu(t){return{overallReset:t}}var au=Po(),ou=function(t,n,i,r){if(r){var e=au(r);e.dataIndex=i,e.dataType=n,e.seriesIndex=t,e.ssrType="chart","group"===r.type&&r.traverse((function(r){var e=au(r);e.seriesIndex=t,e.dataIndex=i,e.dataType=n,e.ssrType="chart"}))}},uu="undefined",su="series",lu=bt(["tooltip","label","itemName","itemId","itemGroupId","itemChildGroupId","seriesName"]),fu="original",hu="arrayRows",cu="objectRows",vu="keyedColumns",du="typedArray",pu="unknown",mu="column",yu="row",gu=["getDom","getZr","getWidth","getHeight","getDevicePixelRatio","dispatchAction","isSSR","isDisposed","on","off","getDataURL","getConnectedDataURL","getOption","getId","updateLabelLayout"],bu=function(t){H(gu,(function(n){this[n]=X(t[n],t)}),this)},wu=1,xu={},Mu=Po(),ku=Po(),Su=["emphasis","blur","select"],Au=["normal","emphasis","blur","select"],Tu="highlight",Nu="downplay",Cu="select",Ou="unselect",Iu="toggleSelect",Lu="selectchanged";function Du(t){return null!=t&&"none"!==t}function _u(t,n,i){t.onHoverStateChange&&(t.hoverState||0)!==i&&t.onHoverStateChange(n),t.hoverState=i}function zu(t){_u(t,"emphasis",2)}function Ru(t){2===t.hoverState&&_u(t,"normal",0)}function Fu(t){_u(t,"blur",1)}function Pu(t){1===t.hoverState&&_u(t,"normal",0)}function Bu(t){t.selected=!0}function Eu(t){t.selected=!1}function Wu(t,n,i){n(t,i)}function ju(t,n,i){Wu(t,n,i),t.isGroup&&t.traverse((function(t){Wu(t,n,i)}))}function Hu(t,n){switch(n){case"emphasis":t.hoverState=2;break;case"normal":t.hoverState=0;break;case"blur":t.hoverState=1;break;case"select":t.selected=!0}}function Uu(t,n){var i=this.states[t];if(this.style){if("emphasis"===t)return function(t,n,i,r){var e=i&&E(i,"select")>=0,a=!1;if(t instanceof da){var o=Mu(t),u=e&&o.selectFill||o.normalFill,s=e&&o.selectStroke||o.normalStroke;if(Du(u)||Du(s)){var l=(r=r||{}).style||{};"inherit"===l.fill?(a=!0,r=P({},r),(l=P({},l)).fill=u):!Du(l.fill)&&Du(u)?(a=!0,r=P({},r),(l=P({},l)).fill=vr(u)):!Du(l.stroke)&&Du(s)&&(a||(r=P({},r),l=P({},l)),l.stroke=vr(s)),r.style=l}}if(r&&null==r.z2){a||(r=P({},r));var f=t.z2EmphasisLift;r.z2=t.z2+(null!=f?f:10)}return r}(this,0,n,i);if("blur"===t)return function(t,n,i){var r=E(t.currentStates,n)>=0,e=t.style.opacity,a=r?null:function(t,n,i,r){for(var e=t.style,a={},o=0;o<n.length;o++){var u=n[o],s=e[u];a[u]=null==s?r&&r[u]:s}for(o=0;o<t.animators.length;o++){var l=t.animators[o];l.__fromStateTransition&&l.__fromStateTransition.indexOf(i)<0&&"style"===l.targetName&&l.saveTo(a,n)}return a}(t,["opacity"],n,{opacity:1}),o=(i=i||{}).style||{};return null==o.opacity&&(i=P({},i),o=P({opacity:r?e:.1*a.opacity},o),i.style=o),i}(this,t,i);if("select"===t)return function(t,n,i){if(i&&null==i.z2){i=P({},i);var r=t.z2SelectLift;i.z2=t.z2+(null!=r?r:9)}return i}(this,0,i)}return i}function Vu(t){t.stateProxy=Uu;var n=t.getTextContent(),i=t.getTextGuideLine();n&&(n.stateProxy=Uu),i&&(i.stateProxy=Uu)}function $u(t,n){!Ku(t,n)&&!t.__highByOuter&&ju(t,zu)}function Yu(t,n){!Ku(t,n)&&!t.__highByOuter&&ju(t,Ru)}function Xu(t,n){t.__highByOuter|=1<<(n||0),ju(t,zu)}function qu(t,n){!(t.__highByOuter&=~(1<<(n||0)))&&ju(t,Ru)}function Gu(t){ju(t,Pu)}function Zu(t){ju(t,Bu)}function Ju(t){ju(t,Eu)}function Ku(t,n){return t.__highDownSilentOnTouch&&n.zrByTouch}function Qu(t){var n=t.getModel(),i=[],r=[];n.eachComponent((function(n,e){var a=ku(e),o=function(t,n){return n.mainType===su?t.getViewOfSeriesModel(n):t.getViewOfComponentModel(n)}(t,e),u="series"===n;!u&&r.push(o),a.isBlured&&(o.group.traverse((function(t){Pu(t)})),u&&i.push(e)),a.isBlured=!1})),H(r,(function(t){t&&t.toggleBlurSeries&&t.toggleBlurSeries(i,!1,n)}))}function ts(t,n,i,r){var e=r.getModel();function a(t,n){for(var i=0;i<n.length;i++){var r=t.getItemGraphicEl(n[i]);r&&Gu(r)}}if(i=i||"coordinateSystem",null!=t&&n&&"none"!==n){var o=e.getSeriesByIndex(t),u=o.coordinateSystem;u&&u.master&&(u=u.master);var s=[];e.eachSeries((function(t){var e=o===t,l=t.coordinateSystem;if(l&&l.master&&(l=l.master),!("series"===i&&!e||"coordinateSystem"===i&&!(l&&u?l===u:e)||"series"===n&&e)){if(r.getViewOfSeriesModel(t).group.traverse((function(t){t.__highByOuter&&e&&"self"===n||Fu(t)})),j(n))a(t.getData(),n);else if(tt(n))for(var f=Y(n),h=0;h<f.length;h++)a(t.getData(f[h]),n[f[h]]);s.push(t),ku(t).isBlured=!0}})),e.eachComponent((function(t,n){if("series"!==t){var i=r.getViewOfComponentModel(n);i&&i.toggleBlurSeries&&i.toggleBlurSeries(s,!0,e)}}))}}function ns(t,n,i){if(null!=t&&null!=n){var r=i.getModel().getComponent(t,n);if(r){ku(r).isBlured=!0;var e=i.getViewOfComponentModel(r);e&&e.focusBlurEnabled&&e.group.traverse((function(t){Fu(t)}))}}}function is(t,n,i,r){var e={focusSelf:!1,dispatchers:null};if(null==t||"series"===t||null==n||null==i)return e;var a=r.getModel().getComponent(t,n);if(!a)return e;var o=r.getViewOfComponentModel(a);if(!o||!o.findHighDownDispatchers)return e;for(var u,s=o.findHighDownDispatchers(i),l=0;l<s.length;l++)if("self"===au(s[l]).focus){u=!0;break}return{focusSelf:u,dispatchers:s}}function rs(t){H(t.getAllData(),(function(n){var i=n.type;n.data.eachItemGraphicEl((function(n,r){t.isSelected(r,i)?Zu(n):Ju(n)}))}))}function es(t){var n=[];return t.eachSeries((function(t){H(t.getAllData(),(function(i){var r=i.type,e=t.getSelectedDataIndices();if(e.length>0){var a={dataIndex:e,seriesIndex:t.seriesIndex};null!=r&&(a.dataType=r),n.push(a)}}))})),n}function as(t,n,i,r){r?function(t){ls(t,!1)}(t):function(t,n,i){ls(t,!0),ju(t,Vu),function(t,n,i){var r=au(t);null!=n?(r.focus=n,r.blurScope=i):r.focus&&(r.focus=null)}(t,n,i)}(t,n,i)}var os=["emphasis","blur","select"],us={itemStyle:"getItemStyle",lineStyle:"getLineStyle",areaStyle:"getAreaStyle"};function ss(t,n,i){i=i||"itemStyle";for(var r=0;r<os.length;r++){var e=os[r],a=n.getModel([e,i]);t.ensureState(e).style=a[us[i]]()}}function ls(t,n){var i=!1===n,r=t;t.highDownSilentOnTouch&&(r.__highDownSilentOnTouch=t.highDownSilentOnTouch),i&&!r.__highDownDispatcher||(r.__highByOuter=r.__highByOuter||0,r.__highDownDispatcher=!i)}function fs(t){return!(!t||!t.__highDownDispatcher)}function hs(t){var n=t.type;return n===Cu||n===Ou||n===Iu}function cs(t){var n=t.type;return n===Tu||n===Nu}var vs=qe.CMD,ds=[[],[],[]],ps=Math.sqrt,ms=Math.atan2,ys=Math.sqrt,gs=Math.sin,bs=Math.cos,ws=Math.PI;function xs(t){return Math.sqrt(t[0]*t[0]+t[1]*t[1])}function Ms(t,n){return(t[0]*n[0]+t[1]*n[1])/(xs(t)*xs(n))}function ks(t,n){return(t[0]*n[1]<t[1]*n[0]?-1:1)*Math.acos(Ms(t,n))}function Ss(t,n,i,r,e,a,o,u,s,l,f){var h=s*(ws/180),c=bs(h)*(t-i)/2+gs(h)*(n-r)/2,v=-1*gs(h)*(t-i)/2+bs(h)*(n-r)/2,d=c*c/(o*o)+v*v/(u*u);d>1&&(o*=ys(d),u*=ys(d));var p=(e===a?-1:1)*ys((o*o*(u*u)-o*o*(v*v)-u*u*(c*c))/(o*o*(v*v)+u*u*(c*c)))||0,m=p*o*v/u,y=p*-u*c/o,g=(t+i)/2+bs(h)*m-gs(h)*y,b=(n+r)/2+gs(h)*m+bs(h)*y,w=ks([1,0],[(c-m)/o,(v-y)/u]),x=[(c-m)/o,(v-y)/u],M=[(-1*c-m)/o,(-1*v-y)/u],k=ks(x,M);if(Ms(x,M)<=-1&&(k=ws),Ms(x,M)>=1&&(k=0),k<0){var S=Math.round(k/ws*1e6)/1e6;k=2*ws+S%2*ws}f.addData(l,g,b,o,u,w,k,h,a)}var As=/([mlvhzcqtsa])([^mlvhzcqtsa]*)/gi,Ts=/-?([0-9]*\.)?[0-9]+([eE]-?[0-9]+)?/g,Ns=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return Et(n,t),n.prototype.applyTransform=function(){},n}(da);function Cs(t){return null!=t.setData}function Os(t,n){var i=function(t){var n=new qe;if(!t)return n;var i,r=0,e=0,a=r,o=e,u=qe.CMD,s=t.match(As);if(!s)return n;for(var l=0;l<s.length;l++){for(var f=s[l],h=f.charAt(0),c=void 0,v=f.match(Ts)||[],d=v.length,p=0;p<d;p++)v[p]=parseFloat(v[p]);for(var m=0;m<d;){var y=void 0,g=void 0,b=void 0,w=void 0,x=void 0,M=void 0,k=void 0,S=r,A=e,T=void 0,N=void 0;switch(h){case"l":r+=v[m++],e+=v[m++],n.addData(c=u.L,r,e);break;case"L":r=v[m++],e=v[m++],n.addData(c=u.L,r,e);break;case"m":r+=v[m++],e+=v[m++],n.addData(c=u.M,r,e),a=r,o=e,h="l";break;case"M":r=v[m++],e=v[m++],n.addData(c=u.M,r,e),a=r,o=e,h="L";break;case"h":r+=v[m++],n.addData(c=u.L,r,e);break;case"H":r=v[m++],n.addData(c=u.L,r,e);break;case"v":e+=v[m++],n.addData(c=u.L,r,e);break;case"V":e=v[m++],n.addData(c=u.L,r,e);break;case"C":n.addData(c=u.C,v[m++],v[m++],v[m++],v[m++],v[m++],v[m++]),r=v[m-2],e=v[m-1];break;case"c":n.addData(c=u.C,v[m++]+r,v[m++]+e,v[m++]+r,v[m++]+e,v[m++]+r,v[m++]+e),r+=v[m-2],e+=v[m-1];break;case"S":y=r,g=e,T=n.len(),N=n.data,i===u.C&&(y+=r-N[T-4],g+=e-N[T-3]),S=v[m++],A=v[m++],r=v[m++],e=v[m++],n.addData(c=u.C,y,g,S,A,r,e);break;case"s":y=r,g=e,T=n.len(),N=n.data,i===u.C&&(y+=r-N[T-4],g+=e-N[T-3]),S=r+v[m++],A=e+v[m++],r+=v[m++],e+=v[m++],n.addData(c=u.C,y,g,S,A,r,e);break;case"Q":S=v[m++],A=v[m++],r=v[m++],e=v[m++],n.addData(c=u.Q,S,A,r,e);break;case"q":S=v[m++]+r,A=v[m++]+e,r+=v[m++],e+=v[m++],n.addData(c=u.Q,S,A,r,e);break;case"T":y=r,g=e,T=n.len(),N=n.data,i===u.Q&&(y+=r-N[T-4],g+=e-N[T-3]),r=v[m++],e=v[m++],n.addData(c=u.Q,y,g,r,e);break;case"t":y=r,g=e,T=n.len(),N=n.data,i===u.Q&&(y+=r-N[T-4],g+=e-N[T-3]),r+=v[m++],e+=v[m++],n.addData(c=u.Q,y,g,r,e);break;case"A":b=v[m++],w=v[m++],x=v[m++],M=v[m++],k=v[m++],Ss(S=r,A=e,r=v[m++],e=v[m++],M,k,b,w,x,c=u.A,n);break;case"a":b=v[m++],w=v[m++],x=v[m++],M=v[m++],k=v[m++],Ss(S=r,A=e,r+=v[m++],e+=v[m++],M,k,b,w,x,c=u.A,n)}}"z"!==h&&"Z"!==h||(n.addData(c=u.Z),r=a,e=o),i=c}return n.toStatic(),n}(t),r=P({},n);return r.buildPath=function(t){var n,r=Cs(t);r&&t.canSave()?(t.appendPath(i),(n=t.getContext())&&t.rebuildPath(n,1)):(n=r?t.getContext():t)&&i.rebuildPath(n,1)},r.applyTransform=function(t){!function(t,n){if(n){var i,r,e,a,o,u,s=t.data,l=t.len(),f=vs.M,h=vs.C,c=vs.L,v=vs.R,d=vs.A,p=vs.Q;for(e=0,a=0;e<l;){switch(i=s[e++],a=e,r=0,i){case f:case c:r=1;break;case h:r=3;break;case p:r=2;break;case d:var m=n[4],y=n[5],g=ps(n[0]*n[0]+n[1]*n[1]),b=ps(n[2]*n[2]+n[3]*n[3]),w=ms(-n[1]/b,n[0]/g);s[e]*=g,s[e++]+=m,s[e]*=b,s[e++]+=y,s[e++]*=g,s[e++]*=b,s[e++]+=w,s[e++]+=w,a=e+=2;break;case v:u[0]=s[e++],u[1]=s[e++],hn(u,u,n),s[a++]=u[0],s[a++]=u[1],u[0]+=s[e++],u[1]+=s[e++],hn(u,u,n),s[a++]=u[0],s[a++]=u[1]}for(o=0;o<r;o++){var x=ds[o];x[0]=s[e++],x[1]=s[e++],hn(x,x,n),s[a++]=x[0],s[a++]=x[1]}}t.increaseVersion()}}(i,t),this.dirtyShape()},r}var Is=function(t){function n(n){var i=t.call(this)||this;return i.isGroup=!0,i._children=[],i.attr(n),i}return Et(n,t),n.prototype.childrenRef=function(){return this._children},n.prototype.children=function(){return this._children.slice()},n.prototype.childAt=function(t){return this._children[t]},n.prototype.childOfName=function(t){for(var n=this._children,i=0;i<n.length;i++)if(n[i].name===t)return n[i]},n.prototype.childCount=function(){return this._children.length},n.prototype.add=function(t){return t&&t!==this&&t.parent!==this&&(this._children.push(t),this._doAdd(t)),this},n.prototype.addBefore=function(t,n){if(t&&t!==this&&t.parent!==this&&n&&n.parent===this){var i=this._children,r=i.indexOf(n);r>=0&&(i.splice(r,0,t),this._doAdd(t))}return this},n.prototype.replace=function(t,n){var i=E(this._children,t);return i>=0&&this.replaceAt(n,i),this},n.prototype.replaceAt=function(t,n){var i=this._children,r=i[n];if(t&&t!==this&&t.parent!==this&&t!==r){i[n]=t,r.parent=null;var e=this.__zr;e&&r.removeSelfFromZr(e),this._doAdd(t)}return this},n.prototype._doAdd=function(t){t.parent&&t.parent.remove(t),t.parent=this;var n=this.__zr;n&&n!==t.__zr&&t.addSelfToZr(n),n&&n.refresh()},n.prototype.remove=function(t){var n=this.__zr,i=this._children,r=E(i,t);return r<0||(i.splice(r,1),t.parent=null,n&&t.removeSelfFromZr(n),n&&n.refresh()),this},n.prototype.removeAll=function(){for(var t=this._children,n=this.__zr,i=0;i<t.length;i++){var r=t[i];n&&r.removeSelfFromZr(n),r.parent=null}return t.length=0,this},n.prototype.eachChild=function(t,n){for(var i=this._children,r=0;r<i.length;r++)t.call(n,i[r],r);return this},n.prototype.traverse=function(t,n){for(var i=0;i<this._children.length;i++){var r=this._children[i],e=t.call(n,r);r.isGroup&&!e&&r.traverse(t,n)}return this},n.prototype.addSelfToZr=function(n){t.prototype.addSelfToZr.call(this,n);for(var i=0;i<this._children.length;i++)this._children[i].addSelfToZr(n)},n.prototype.removeSelfFromZr=function(n){t.prototype.removeSelfFromZr.call(this,n);for(var i=0;i<this._children.length;i++)this._children[i].removeSelfFromZr(n)},n.prototype.getBoundingRect=function(t){for(var n=new On(0,0,0,0),i=t||this._children,r=[],e=null,a=0;a<i.length;a++){var o=i[a];if(!o.ignore&&!o.invisible){var u=o.getBoundingRect(),s=o.getLocalTransform(r);s?(On.applyTransform(n,u,s),(e=e||n.clone()).union(n)):(e=e||u.clone()).union(u)}}return e||n},n}(te);Is.prototype.type="group";var Ls=function(){this.cx=0,this.cy=0,this.r=0},Ds=function(t){function n(n){return t.call(this,n)||this}return Et(n,t),n.prototype.getDefaultShape=function(){return new Ls},n.prototype.buildPath=function(t,n){t.moveTo(n.cx+n.r,n.cy),t.arc(n.cx,n.cy,n.r,0,2*Math.PI)},n}(da);Ds.prototype.type="circle";var _s=function(){this.cx=0,this.cy=0,this.rx=0,this.ry=0},zs=function(t){function n(n){return t.call(this,n)||this}return Et(n,t),n.prototype.getDefaultShape=function(){return new _s},n.prototype.buildPath=function(t,n){var i=.5522848,r=n.cx,e=n.cy,a=n.rx,o=n.ry,u=a*i,s=o*i;t.moveTo(r-a,e),t.bezierCurveTo(r-a,e-s,r-u,e-o,r,e-o),t.bezierCurveTo(r+u,e-o,r+a,e-s,r+a,e),t.bezierCurveTo(r+a,e+s,r+u,e+o,r,e+o),t.bezierCurveTo(r-u,e+o,r-a,e+s,r-a,e),t.closePath()},n}(da);zs.prototype.type="ellipse";var Rs=Math.PI,Fs=2*Rs,Ps=Math.sin,Bs=Math.cos,Es=Math.acos,Ws=Math.atan2,js=Math.abs,Hs=Math.sqrt,Us=Math.max,Vs=Math.min,$s=1e-4;function Ys(t,n,i,r,e,a,o){var u=t-i,s=n-r,l=(o?a:-a)/Hs(u*u+s*s),f=l*s,h=-l*u,c=t+f,v=n+h,d=i+f,p=r+h,m=(c+d)/2,y=(v+p)/2,g=d-c,b=p-v,w=g*g+b*b,x=e-a,M=c*p-d*v,k=(b<0?-1:1)*Hs(Us(0,x*x*w-M*M)),S=(M*b-g*k)/w,A=(-M*g-b*k)/w,T=(M*b+g*k)/w,N=(-M*g+b*k)/w,C=S-m,O=A-y,I=T-m,L=N-y;return C*C+O*O>I*I+L*L&&(S=T,A=N),{cx:S,cy:A,x0:-f,y0:-h,x1:S*(e/x-1),y1:A*(e/x-1)}}var Xs=function(){this.cx=0,this.cy=0,this.r0=0,this.r=0,this.startAngle=0,this.endAngle=2*Math.PI,this.clockwise=!0,this.cornerRadius=0},qs=function(t){function n(n){return t.call(this,n)||this}return Et(n,t),n.prototype.getDefaultShape=function(){return new Xs},n.prototype.buildPath=function(t,n){!function(t,n){var i,r=Us(n.r,0),e=Us(n.r0||0,0),a=r>0;if(a||e>0){if(a||(r=e,e=0),e>r){var o=r;r=e,e=o}var u=n.startAngle,s=n.endAngle;if(!isNaN(u)&&!isNaN(s)){var l=n.cx,f=n.cy,h=!!n.clockwise,c=js(s-u),v=c>Fs&&c%Fs;if(v>$s&&(c=v),r>$s)if(c>Fs-$s)t.moveTo(l+r*Bs(u),f+r*Ps(u)),t.arc(l,f,r,u,s,!h),e>$s&&(t.moveTo(l+e*Bs(s),f+e*Ps(s)),t.arc(l,f,e,s,u,h));else{var d=void 0,p=void 0,m=void 0,y=void 0,g=void 0,b=void 0,w=void 0,x=void 0,M=void 0,k=void 0,S=void 0,A=void 0,T=void 0,N=void 0,C=void 0,O=void 0,I=r*Bs(u),L=r*Ps(u),D=e*Bs(s),_=e*Ps(s),z=c>$s;if(z){var R=n.cornerRadius;R&&(d=(i=function(t){var n;if(G(t)){var i=t.length;if(!i)return t;n=1===i?[t[0],t[0],0,0]:2===i?[t[0],t[0],t[1],t[1]]:3===i?t.concat(t[2]):t}else n=[t,t,t,t];return n}(R))[0],p=i[1],m=i[2],y=i[3]);var F=js(r-e)/2;if(g=Vs(F,m),b=Vs(F,y),w=Vs(F,d),x=Vs(F,p),S=M=Us(g,b),A=k=Us(w,x),(M>$s||k>$s)&&(T=r*Bs(s),N=r*Ps(s),C=e*Bs(u),O=e*Ps(u),c<Rs)){var P=function(t,n,i,r,e,a,o,u){var s=i-t,l=r-n,f=o-e,h=u-a,c=h*s-f*l;if(!(c*c<$s))return[t+(c=(f*(n-a)-h*(t-e))/c)*s,n+c*l]}(I,L,C,O,T,N,D,_);if(P){var B=I-P[0],E=L-P[1],W=T-P[0],j=N-P[1],H=1/Ps(Es((B*W+E*j)/(Hs(B*B+E*E)*Hs(W*W+j*j)))/2),U=Hs(P[0]*P[0]+P[1]*P[1]);S=Vs(M,(r-U)/(H+1)),A=Vs(k,(e-U)/(H-1))}}}if(z)if(S>$s){var V=Vs(m,S),$=Vs(y,S),Y=Ys(C,O,I,L,r,V,h),X=Ys(T,N,D,_,r,$,h);t.moveTo(l+Y.cx+Y.x0,f+Y.cy+Y.y0),S<M&&V===$?t.arc(l+Y.cx,f+Y.cy,S,Ws(Y.y0,Y.x0),Ws(X.y0,X.x0),!h):(V>0&&t.arc(l+Y.cx,f+Y.cy,V,Ws(Y.y0,Y.x0),Ws(Y.y1,Y.x1),!h),t.arc(l,f,r,Ws(Y.cy+Y.y1,Y.cx+Y.x1),Ws(X.cy+X.y1,X.cx+X.x1),!h),$>0&&t.arc(l+X.cx,f+X.cy,$,Ws(X.y1,X.x1),Ws(X.y0,X.x0),!h))}else t.moveTo(l+I,f+L),t.arc(l,f,r,u,s,!h);else t.moveTo(l+I,f+L);e>$s&&z?A>$s?(V=Vs(d,A),Y=Ys(D,_,T,N,e,-($=Vs(p,A)),h),X=Ys(I,L,C,O,e,-V,h),t.lineTo(l+Y.cx+Y.x0,f+Y.cy+Y.y0),A<k&&V===$?t.arc(l+Y.cx,f+Y.cy,A,Ws(Y.y0,Y.x0),Ws(X.y0,X.x0),!h):($>0&&t.arc(l+Y.cx,f+Y.cy,$,Ws(Y.y0,Y.x0),Ws(Y.y1,Y.x1),!h),t.arc(l,f,e,Ws(Y.cy+Y.y1,Y.cx+Y.x1),Ws(X.cy+X.y1,X.cx+X.x1),h),V>0&&t.arc(l+X.cx,f+X.cy,V,Ws(X.y1,X.x1),Ws(X.y0,X.x0),!h))):(t.lineTo(l+D,f+_),t.arc(l,f,e,s,u,h)):t.lineTo(l+D,f+_)}else t.moveTo(l,f);t.closePath()}}}(t,n)},n.prototype.isZeroArea=function(){return this.shape.startAngle===this.shape.endAngle||this.shape.r===this.shape.r0},n}(da);qs.prototype.type="sector";var Gs=function(){this.cx=0,this.cy=0,this.r=0,this.r0=0},Zs=function(t){function n(n){return t.call(this,n)||this}return Et(n,t),n.prototype.getDefaultShape=function(){return new Gs},n.prototype.buildPath=function(t,n){var i=n.cx,r=n.cy,e=2*Math.PI;t.moveTo(i+n.r,r),t.arc(i,r,n.r,0,e,!1),t.moveTo(i+n.r0,r),t.arc(i,r,n.r0,0,e,!0)},n}(da);function Js(t,n,i){var r=n.smooth,e=n.points;if(e&&e.length>=2){if(r){var a=function(t,n,i,r){var e,a,o,u,s=[],l=[],f=[],h=[];if(r){o=[1/0,1/0],u=[-1/0,-1/0];for(var c=0,v=t.length;c<v;c++)cn(o,o,t[c]),vn(u,u,t[c]);cn(o,o,r[0]),vn(u,u,r[1])}for(c=0,v=t.length;c<v;c++){var d=t[c];if(i)e=t[c?c-1:v-1],a=t[(c+1)%v];else{if(0===c||c===v-1){s.push(nn(t[c]));continue}e=t[c-1],a=t[c+1]}an(l,a,e),on(l,l,n);var p=un(d,e),m=un(d,a),y=p+m;0!==y&&(p/=y,m/=y),on(f,l,-p),on(h,l,m);var g=en([],d,f),b=en([],d,h);r&&(vn(g,g,o),cn(g,g,u),vn(b,b,o),cn(b,b,u)),s.push(g),s.push(b)}return i&&s.push(s.shift()),s}(e,r,i,n.smoothConstraint);t.moveTo(e[0][0],e[0][1]);for(var o=e.length,u=0;u<(i?o:o-1);u++){var s=a[2*u],l=a[2*u+1],f=e[(u+1)%o];t.bezierCurveTo(s[0],s[1],l[0],l[1],f[0],f[1])}}else{t.moveTo(e[0][0],e[0][1]),u=1;for(var h=e.length;u<h;u++)t.lineTo(e[u][0],e[u][1])}i&&t.closePath()}}Zs.prototype.type="ring";var Ks=function(){this.points=null,this.smooth=0,this.smoothConstraint=null},Qs=function(t){function n(n){return t.call(this,n)||this}return Et(n,t),n.prototype.getDefaultShape=function(){return new Ks},n.prototype.buildPath=function(t,n){Js(t,n,!0)},n}(da);Qs.prototype.type="polygon";var tl=function(){this.points=null,this.percent=1,this.smooth=0,this.smoothConstraint=null},nl=function(t){function n(n){return t.call(this,n)||this}return Et(n,t),n.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},n.prototype.getDefaultShape=function(){return new tl},n.prototype.buildPath=function(t,n){Js(t,n,!1)},n}(da);nl.prototype.type="polyline";var il={},rl=function(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.percent=1},el=function(t){function n(n){return t.call(this,n)||this}return Et(n,t),n.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},n.prototype.getDefaultShape=function(){return new rl},n.prototype.buildPath=function(t,n){var i,r,e,a;if(this.subPixelOptimize){var o=xa(il,n,this.style);i=o.x1,r=o.y1,e=o.x2,a=o.y2}else i=n.x1,r=n.y1,e=n.x2,a=n.y2;var u=n.percent;0!==u&&(t.moveTo(i,r),u<1&&(e=i*(1-u)+e*u,a=r*(1-u)+a*u),t.lineTo(e,a))},n.prototype.pointAt=function(t){var n=this.shape;return[n.x1*(1-t)+n.x2*t,n.y1*(1-t)+n.y2*t]},n}(da);el.prototype.type="line";var al=[],ol=function(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.cpx1=0,this.cpy1=0,this.percent=1};function ul(t,n,i){return null!=t.cpx2||null!=t.cpy2?[(i?Ri:zi)(t.x1,t.cpx1,t.cpx2,t.x2,n),(i?Ri:zi)(t.y1,t.cpy1,t.cpy2,t.y2,n)]:[(i?ji:Wi)(t.x1,t.cpx1,t.x2,n),(i?ji:Wi)(t.y1,t.cpy1,t.y2,n)]}var sl=function(t){function n(n){return t.call(this,n)||this}return Et(n,t),n.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},n.prototype.getDefaultShape=function(){return new ol},n.prototype.buildPath=function(t,n){var i=n.x1,r=n.y1,e=n.x2,a=n.y2,o=n.cpx1,u=n.cpy1,s=n.cpx2,l=n.cpy2,f=n.percent;0!==f&&(t.moveTo(i,r),null==s||null==l?(f<1&&(Ui(i,o,e,f,al),o=al[1],e=al[2],Ui(r,u,a,f,al),u=al[1],a=al[2]),t.quadraticCurveTo(o,u,e,a)):(f<1&&(Bi(i,o,s,e,f,al),o=al[1],s=al[2],e=al[3],Bi(r,u,l,a,f,al),u=al[1],l=al[2],a=al[3]),t.bezierCurveTo(o,u,s,l,e,a)))},n.prototype.pointAt=function(t){return ul(this.shape,t,!1)},n.prototype.tangentAt=function(t){var n=ul(this.shape,t,!0);return function(t,n){var i=function(t){return Math.sqrt(function(t){return t[0]*t[0]+t[1]*t[1]}(t))}(n);return 0===i?(t[0]=0,t[1]=0):(t[0]=n[0]/i,t[1]=n[1]/i),t}(n,n)},n}(da);sl.prototype.type="bezier-curve";var ll=function(){this.cx=0,this.cy=0,this.r=0,this.startAngle=0,this.endAngle=2*Math.PI,this.clockwise=!0},fl=function(t){function n(n){return t.call(this,n)||this}return Et(n,t),n.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},n.prototype.getDefaultShape=function(){return new ll},n.prototype.buildPath=function(t,n){var i=n.cx,r=n.cy,e=Math.max(n.r,0),a=n.startAngle,o=n.endAngle,u=n.clockwise,s=Math.cos(a),l=Math.sin(a);t.moveTo(s*e+i,l*e+r),t.arc(i,r,e,a,o,!u)},n}(da);fl.prototype.type="arc";var hl=function(t){function n(){var n=null!==t&&t.apply(this,arguments)||this;return n.type="compound",n}return Et(n,t),n.prototype._updatePathDirty=function(){for(var t=this.shape.paths,n=this.shapeChanged(),i=0;i<t.length;i++)n=n||t[i].shapeChanged();n&&this.dirtyShape()},n.prototype.beforeBrush=function(){this._updatePathDirty();for(var t=this.shape.paths||[],n=this.getGlobalScale(),i=0;i<t.length;i++)t[i].path||t[i].createPathProxy(),t[i].path.setScale(n[0],n[1],t[i].segmentIgnoreThreshold)},n.prototype.buildPath=function(t,n){for(var i=n.paths||[],r=0;r<i.length;r++)i[r].buildPath(t,i[r].shape,!0)},n.prototype.afterBrush=function(){for(var t=this.shape.paths||[],n=0;n<t.length;n++)t[n].pathUpdated()},n.prototype.getBoundingRect=function(){return this._updatePathDirty.call(this),da.prototype.getBoundingRect.call(this)},n}(da),cl=function(){function t(t){this.colorStops=t||[]}return t.prototype.addColorStop=function(t,n){this.colorStops.push({offset:t,color:n})},t}(),vl=function(t){function n(n,i,r,e,a,o){var u=t.call(this,a)||this;return u.x=null==n?0:n,u.y=null==i?0:i,u.x2=null==r?1:r,u.y2=null==e?0:e,u.type="linear",u.global=o||!1,u}return Et(n,t),n}(cl),dl=function(t){function n(n,i,r,e,a){var o=t.call(this,e)||this;return o.x=null==n?.5:n,o.y=null==i?.5:i,o.r=null==r?.5:r,o.type="radial",o.global=a||!1,o}return Et(n,t),n}(cl),pl=Math.min,ml=Math.max,yl=Math.abs,gl=[0,0],bl=[0,0],wl=Pn(),xl=wl.minTv,Ml=wl.maxTv,kl=function(){function t(t,n){this._corners=[],this._axes=[],this._origin=[0,0];for(var i=0;i<4;i++)this._corners[i]=new pn;for(i=0;i<2;i++)this._axes[i]=new pn;t&&this.fromBoundingRect(t,n)}return t.prototype.fromBoundingRect=function(t,n){var i=this._corners,r=this._axes,e=t.x,a=t.y,o=e+t.width,u=a+t.height;if(i[0].set(e,a),i[1].set(o,a),i[2].set(o,u),i[3].set(e,u),n)for(var s=0;s<4;s++)i[s].transform(n);for(pn.sub(r[0],i[1],i[0]),pn.sub(r[1],i[3],i[0]),r[0].normalize(),r[1].normalize(),s=0;s<2;s++)this._origin[s]=r[s].dot(i[0])},t.prototype.intersect=function(t,n,i){var r=!0,e=!n;return n&&pn.set(n,0,0),wl.reset(i,!e),!this._intersectCheckOneSide(this,t,e,1)&&(r=!1,e)||!this._intersectCheckOneSide(t,this,e,-1)&&(r=!1,e)||e||wl.negativeSize||pn.copy(n,r?wl.useDir?wl.dirMinTv:xl:Ml),r},t.prototype._intersectCheckOneSide=function(t,n,i,r){for(var e=!0,a=0;a<2;a++){var o=t._axes[a];if(t._getProjMinMaxOnAxis(a,t._corners,gl),t._getProjMinMaxOnAxis(a,n._corners,bl),wl.negativeSize||gl[1]<bl[0]||gl[0]>bl[1]){if(e=!1,wl.negativeSize||i)return e;var u=yl(bl[0]-gl[1]),s=yl(gl[0]-bl[1]);pl(u,s)>Ml.len()&&pn.scale(Ml,o,u<s?-u*r:s*r)}else i||(u=yl(bl[0]-gl[1]),s=yl(gl[0]-bl[1]),(wl.useDir||pl(u,s)<xl.len())&&((u<s||!wl.bidirectional)&&(pn.scale(xl,o,u*r),wl.useDir&&wl.calcDirMTV()),(u>=s||!wl.bidirectional)&&(pn.scale(xl,o,-s*r),wl.useDir&&wl.calcDirMTV())))}return e},t.prototype._getProjMinMaxOnAxis=function(t,n,i){for(var r=this._axes[t],e=this._origin,a=n[0].dot(r)+e[t],o=a,u=a,s=1;s<n.length;s++){var l=n[s].dot(r)+e[t];o=pl(l,o),u=ml(l,u)}i[0]=o+wl.touchThreshold,i[1]=u-wl.touchThreshold,wl.negativeSize=i[1]<i[0]},t}(),Sl=[],Al=function(t){function n(){var n=null!==t&&t.apply(this,arguments)||this;return n.notClear=!0,n.incremental=1,n._displayables=[],n._temporaryDisplayables=[],n._cursor=0,n}return Et(n,t),n.prototype.traverse=function(t,n){t.call(n,this)},n.prototype.useStyle=function(){this.style={}},n.prototype._useHoverStyle=function(){this.__hoverStyle=null},n.prototype.getCursor=function(){return this._cursor},n.prototype.innerAfterBrush=function(){this._cursor=this._displayables.length},n.prototype.clearDisplaybles=function(){this._displayables=[],this._temporaryDisplayables=[],this._cursor=0,this.markRedraw(),this.notClear=!1},n.prototype.clearTemporalDisplayables=function(){this._temporaryDisplayables=[]},n.prototype.addDisplayable=function(t,n){n?this._temporaryDisplayables.push(t):this._displayables.push(t),this.markRedraw()},n.prototype.addDisplayables=function(t,n){n=n||!1;for(var i=0;i<t.length;i++)this.addDisplayable(t[i],n)},n.prototype.getDisplayables=function(){return this._displayables},n.prototype.getTemporalDisplayables=function(){return this._temporaryDisplayables},n.prototype.eachPendingDisplayable=function(t){for(var n=this._cursor;n<this._displayables.length;n++)t&&t(this._displayables[n]);for(n=0;n<this._temporaryDisplayables.length;n++)t&&t(this._temporaryDisplayables[n])},n.prototype.update=function(){this.updateTransform();for(var t=this._cursor;t<this._displayables.length;t++)(n=this._displayables[t]).parent=this,n.update(),n.parent=null;for(t=0;t<this._temporaryDisplayables.length;t++){var n;(n=this._temporaryDisplayables[t]).parent=this,n.update(),n.parent=null}},n.prototype.getBoundingRect=function(){if(!this._rect){for(var t=new On(1/0,1/0,-1/0,-1/0),n=0;n<this._displayables.length;n++){var i=this._displayables[n],r=i.getBoundingRect().clone();i.needLocalTransform()&&r.applyTransform(i.getLocalTransform(Sl)),t.union(r)}this._rect=t}return this._rect},n.prototype.contain=function(t,n){var i=this.transformCoordToLocal(t,n);if(this.getBoundingRect().contain(i[0],i[1]))for(var r=0;r<this._displayables.length;r++)if(this._displayables[r].contain(t,n))return!0;return!1},n}(ve),Tl=Po();function Nl(t,n,i,r,e,a,o){var u,s=!1;Z(e)?(o=a,a=e,e=null):tt(e)&&(a=e.cb,o=e.during,s=e.isFrom,u=e.removeOpt,e=e.dataIndex);var l="leave"===t;l||n.stopAnimation("leave");var f=function(t,n,i,r,e){var a;if(n&&n.ecModel){var o=n.ecModel.getUpdatePayload();a=o&&o.animation}var u="update"===t;if(n&&n.isAnimationEnabled()){var s=void 0,l=void 0,f=void 0;return r?(s=ut(r.duration,200),l=ut(r.easing,"cubicOut"),f=0):(s=n.getShallow(u?"animationDurationUpdate":"animationDuration"),l=n.getShallow(u?"animationEasingUpdate":"animationEasing"),f=n.getShallow(u?"animationDelayUpdate":"animationDelay")),a&&(null!=a.duration&&(s=a.duration),null!=a.easing&&(l=a.easing),null!=a.delay&&(f=a.delay)),Z(f)&&(f=f(i,e)),Z(s)&&(s=s(i)),{duration:s||0,delay:f,easing:l}}return null}(t,r,e,l?u||{}:null,r&&r.getAnimationDelayParams?r.getAnimationDelayParams(n,e):null);if(f&&f.duration>0){var h={duration:f.duration,delay:f.delay||0,easing:f.easing,done:a,force:!!a||!!o,setToFinal:!l,scope:t,during:o};s?n.animateFrom(i,h):n.animateTo(i,h)}else n.stopAnimation(),!s&&n.attr(i),o&&o(1),a&&a()}function Cl(t,n,i,r,e,a){Nl("update",t,n,i,r,e,a)}function Ol(t,n,i,r,e,a){Nl("enter",t,n,i,r,e,a)}function Il(t){if(!t.__zr)return!0;for(var n=0;n<t.animators.length;n++)if("leave"===t.animators[n].scope)return!0;return!1}function Ll(t,n,i,r,e,a){Il(t)||Nl("leave",t,n,i,r,e,a)}function Dl(t,n,i,r){t.removeTextContent(),t.removeTextGuideLine(),Ll(t,{style:{opacity:0}},n,i,r)}function _l(t,n,i){function r(){t.parent&&t.parent.remove(t)}t.isGroup?t.traverse((function(t){t.isGroup||Dl(t,n,i,r)})):Dl(t,n,i,r)}function zl(t){Tl(t).oldStyle=t.style}var Rl={},Fl=["x","y"],Pl=["width","height"];function Bl(t,n){Rl[t]=n}function El(t,n,i,r){var e=function(t,n){return new Ns(Os(t,n))}(t,n);return i&&("center"===r&&(i=jl(i,e.getBoundingRect())),Ul(e,i)),e}function Wl(t,n,i){var r=new ba({style:{image:t,x:n.x,y:n.y,width:n.width,height:n.height},onload:function(t){"center"===i&&r.setStyle(jl(n,{width:t.width,height:t.height}))}});return r}function jl(t,n){var i,r=n.width/n.height,e=t.height*r;return i=e<=t.width?t.height:(e=t.width)/r,{x:t.x+t.width/2-e/2,y:t.y+t.height/2-i/2,width:e,height:i}}var Hl=function(t,n){for(var i=[],r=t.length,e=0;e<r;e++)i.push(t[e].getUpdatedPathProxy(!0));var a=new da(n);return a.createPathProxy(),a.buildPath=function(t){if(Cs(t)){t.appendPath(i);var n=t.getContext();n&&t.rebuildPath(n,1)}},a};function Ul(t,n){if(t.applyTransform){var i=t.getBoundingRect().calculateTransform(n);t.applyTransform(i)}}function Vl(t,n){return xa(t,t,{lineWidth:n}),t}var $l=ka;function Yl(t,n,i){return n&&!j(n)&&(n=bi.getLocalTransform(n)),i&&(n=Qt([],n)),hn([],t,n)}function Xl(t){return!t.isGroup}function ql(t,n,i){if(t&&n){var r,e=(r={},t.traverse((function(t){Xl(t)&&t.anid&&(r[t.anid]=t)})),r);n.traverse((function(t){if(Xl(t)&&t.anid){var n=e[t.anid];if(n){var r=a(t);t.attr(a(n)),Cl(t,r,i,au(t).dataIndex)}}}))}function a(t){var n={x:t.x,y:t.y,rotation:t.rotation};return function(t){return null!=t.shape}(t)&&(n.shape=R(t.shape)),n}}function Gl(t,n,i){var r=P({rectHover:!0},n),e=r.style={strokeNoScale:!0};if(i=i||{x:-1,y:-1,width:2,height:2},t)return 0===t.indexOf("image://")?(e.image=t.slice(8),B(e,i),new ba(r)):El(t.replace("path://",""),r,i,"center")}function Zl(t,n,i,r,e,a,o,u){var s,l=i-t,f=r-n,h=o-e,c=u-a,v=Jl(h,c,l,f);if((s=v)<=1e-6&&s>=-1e-6)return!1;var d=t-e,p=n-a,m=Jl(d,p,l,f)/v;if(m<0||m>1)return!1;var y=Jl(d,p,h,c)/v;return!(y<0||y>1)}function Jl(t,n,i,r){return t*r-i*n}function Kl(t,n,i,r,e){return null==n||(Q(n)?Ql[0]=Ql[1]=Ql[2]=Ql[3]=n:(Ql[0]=n[0],Ql[1]=n[1],Ql[2]=n[2],Ql[3]=n[3]),r&&(Ql[0]=Va(0,Ql[0]),Ql[1]=Va(0,Ql[1]),Ql[2]=Va(0,Ql[2]),Ql[3]=Va(0,Ql[3])),i&&(Ql[0]=-Ql[0],Ql[1]=-Ql[1],Ql[2]=-Ql[2],Ql[3]=-Ql[3]),tf(t,Ql,"x","width",3,1,e&&e[0]||0),tf(t,Ql,"y","height",0,2,e&&e[1]||0)),t}var Ql=[0,0,0,0];function tf(t,n,i,r,e,a,o){var u=n[a]+n[e],s=t[r];t[r]+=u,o=Va(0,Ua(o,s)),t[r]<o?(t[r]=o,t[i]+=n[e]>=0?-n[e]:n[a]>=0?s+n[a]:$a(u)>1e-8?(s-o)*n[e]/u:0):t[i]-=n[e]}function nf(t){var n=t.itemTooltipOption,i=t.componentModel,r=t.itemName,e=J(n)?{formatter:n}:n,a=i.mainType,o=i.componentIndex,u={componentType:a,name:r,$vars:["name"]};u[a+"Index"]=o;var s=t.formatterParamsExtra;s&&H(Y(s),(function(t){xt(u,t)||(u[t]=s[t],u.$vars.push(t))}));var l=au(t.el);l.componentMainType=a,l.componentIndex=o,l.tooltipConfig={name:r,option:B({content:r,encodeHTMLContent:!0,formatterParams:u},e)}}function rf(t,n){var i;t.isGroup&&(i=n(t)),i||t.traverse(n)}function ef(t,n){if(t)if(G(t))for(var i=0;i<t.length;i++)rf(t[i],n);else rf(t,n)}function af(t){return!t||$a(t[1])<of&&$a(t[2])<of||$a(t[0])<of&&$a(t[3])<of}var of=1e-5;function uf(t,n){return t?On.copy(t,n):n.clone()}function sf(t,n){return n?Gt(t||[1,0,0,1,0,0],n):void 0}function lf(t){return{z:t.get("z")||0,zlevel:t.get("zlevel")||0}}function ff(t,n,i){hf(t,n,i,-1/0)}function hf(t,n,i,r){if(t.ignoreModelZ)return r;var e=t.getTextContent(),a=t.getTextGuideLine();if(t.isGroup)for(var o=t.childrenRef(),u=0;u<o.length;u++)r=Va(hf(o[u],n,i,r),r);else t.z=n,t.zlevel=i,r=Va(t.z2||0,r);if(e&&(e.z=n,e.zlevel=i,isFinite(r)&&(e.z2=r+2)),a){var s=t.textGuideLineConfig;a.z=n,a.zlevel=i,isFinite(r)&&(a.z2=r+(s&&s.showAbove?1:-1))}return r}var cf=new bi;cf.transform=[1,0,0,1,0,0],Bl("circle",Ds),Bl("ellipse",zs),Bl("sector",qs),Bl("ring",Zs),Bl("polygon",Qs),Bl("polyline",nl),Bl("rect",Ta),Bl("line",el),Bl("bezierCurve",sl),Bl("arc",fl);var vf=Object.freeze({__proto__:null,Arc:fl,BezierCurve:sl,BoundingRect:On,Circle:Ds,CompoundPath:hl,Ellipse:zs,Group:Is,HOVER_LAYER_FOR_INCREMENTAL:2,HOVER_LAYER_FROM_THRESHOLD:1,HOVER_LAYER_NO:0,Image:ba,IncrementalDisplayable:Al,Line:el,LinearGradient:vl,OrientedBoundingRect:kl,Path:da,Point:pn,Polygon:Qs,Polyline:nl,RadialGradient:dl,Rect:Ta,Ring:Zs,Sector:qs,Text:Ia,WH:Pl,XY:Fl,applyTransform:Yl,calcZ2Range:function(t){var n=-1/0,i=1/0;function r(t){if(t&&!t.isGroup){var n=t.currentStates;if(n.length)for(var i=0;i<n.length;i++)e(t.states[n[i]]);e(t)}}function e(t){if(t){var r=t.z2;r>n&&(n=r),r<i&&(i=r)}}return rf(t,(function(t){r(t),r(t.getTextContent()),r(t.getTextGuideLine())})),i>n&&(i=n=0),{min:i,max:n}},clipPointsByRect:function(t,n){return U(t,(function(t){var i=t[0];i=Va(i,n.x),i=Ua(i,n.x+n.width);var r=t[1];return r=Va(r,n.y),[i,r=Ua(r,n.y+n.height)]}))},clipRectByRect:function(t,n){var i=Va(t.x,n.x),r=Ua(t.x+t.width,n.x+n.width),e=Va(t.y,n.y),a=Ua(t.y+t.height,n.y+n.height);if(r>=i&&a>=e)return{x:i,y:e,width:r-i,height:a-e}},createIcon:Gl,decomposeTransform:function(t,n){return n?Gt(cf.transform,n):qt(cf.transform),cf.decomposeTransform(),Mi(t,cf),t},ensureCopyRect:uf,ensureCopyTransform:sf,expandOrShrinkRect:Kl,extendPath:function(t,n){return i=Os(t,n),function(t){function n(n){var r=t.call(this,n)||this;return r.applyTransform=i.applyTransform,r.buildPath=i.buildPath,r}return Et(n,t),n}(Ns);var i},extendShape:function(t){return da.extend(t)},getCurrentCanvasPainter:function(t){var n=t.getZr().painter;return"canvas"===n.getType()?n:null},getShapeClass:function(t){if(Rl.hasOwnProperty(t))return Rl[t]},getTransform:function(t,n){for(var i=qt([]);t&&t!==n;)Zt(i,t.getLocalTransform(),i),t=t.parent;return i},groupTransition:ql,initProps:Ol,isBoundingRectAxisAligned:af,isElementRemoved:Il,lineLineIntersect:Zl,linePolygonIntersect:function(t,n,i,r,e){for(var a=0,o=e[e.length-1];a<e.length;a++){var u=e[a];if(Zl(t,n,i,r,u[0],u[1],o[0],o[1]))return!0;o=u}},makeImage:Wl,makePath:El,mergePath:Hl,payloadDisableAnimation:function(t){return t.animation={duration:0},t},registerShape:Bl,removeElement:Ll,removeElementWithFadeOut:_l,resizePath:Ul,retrieveZInfo:lf,setTooltipConfig:nf,subPixelOptimize:$l,subPixelOptimizeLine:Vl,subPixelOptimizeRect:function(t,n){return Ma(t,t,n),t},transformDirection:function(t,n,i){var r=0===n[4]||0===n[5]||0===n[0]?1:$a(2*n[4]/n[0]),e=0===n[4]||0===n[5]||0===n[2]?1:$a(2*n[4]/n[2]),a=["left"===t?-r:"right"===t?r:0,"top"===t?-e:"bottom"===t?e:0];return a=Yl(a,n,i),$a(a[0])>$a(a[1])?a[0]>0?"right":"left":a[1]>0?"bottom":"top"},traverseElements:ef,traverseUpdateZ:ff,updateProps:Cl}),df={};function pf(t,n){for(var i=0;i<Su.length;i++){var r=Su[i],e=n[r],a=t.ensureState(r);a.style=a.style||{},a.style.text=e}var o=t.currentStates.slice();t.clearStates(!0),t.setStyle({text:n.normal}),t.useStates(o,!0)}function mf(t,n,i){var r,e=t.labelFetcher,a=t.labelDataIndex,o=t.labelDimIndex,u=n.normal;e&&(r=e.getFormattedLabel(a,"normal",null,o,u&&u.get("formatter"),null!=i?{interpolatedValue:i}:null)),null==r&&(r=Z(t.defaultText)?t.defaultText(a,t,i):t.defaultText);for(var s={normal:r},l=0;l<Su.length;l++){var f=Su[l],h=n[f];s[f]=ut(e?e.getFormattedLabel(a,f,null,o,h&&h.get("formatter")):null,r)}return s}function yf(t,n,i,r){i=i||df;for(var e=t instanceof Ia,a=!1,o=0;o<Au.length;o++)if((c=n[Au[o]])&&c.getShallow("show")){a=!0;break}var u=e?t:t.getTextContent();if(a){e||(u||(u=new Ia,t.setTextContent(u)),t.stateProxy&&(u.stateProxy=t.stateProxy));var s=mf(i,n),l=n.normal,f=!!l.getShallow("show"),h=bf(l,r&&r.normal,i,!1,!e);for(h.text=s.normal,e||t.setTextConfig(wf(l,i,!1)),o=0;o<Su.length;o++){var c,v=Su[o];if(c=n[v]){var d=u.ensureState(v),p=!!ut(c.getShallow("show"),f);p!==f&&(d.ignore=!p),d.style=bf(c,r&&r[v],i,!0,!e),d.style.text=s[v],e||(t.ensureState(v).textConfig=wf(c,i,!0))}}u.silent=!!l.getShallow("silent"),null!=u.style.x&&(h.x=u.style.x),null!=u.style.y&&(h.y=u.style.y),u.ignore=!f,u.useStyle(h),u.dirty(),i.enableTextSetter&&(Af(u).setLabelText=function(t){var r=mf(i,n,t);pf(u,r)})}else u&&(u.ignore=!0);t.dirty()}function gf(t,n){for(var i={normal:t.getModel(n=n||"label")},r=0;r<Su.length;r++){var e=Su[r];i[e]=t.getModel([e,n])}return i}function bf(t,n,i,r,e){var a={};return function(t,n,i,r,e){i=i||df;var a,o=n.ecModel,u=o&&o.option.textStyle,s=function(t){for(var n;t&&t!==t.ecModel;){var i=(t.option||df).rich;if(i){n=n||{};for(var r=Y(i),e=0;e<r.length;e++)n[r[e]]=1}t=t.parentModel}return n}(n);if(s){a={};var l="richInheritPlainLabel",f=ut(n.get(l),o?o.get(l):void 0);for(var h in s)if(s.hasOwnProperty(h)){var c=n.getModel(["rich",h]);Sf(a[h]={},c,u,n,f,i,r,e,!1,!0)}}a&&(t.rich=a);var v=n.get("overflow");v&&(t.overflow=v);var d=n.get("lineOverflow");d&&(t.lineOverflow=d);var p=t,m=n.get("minMargin");if(null!=m)m=Q(m)?m/2:0,p.margin=[m,m,m,m],p.__marginType=Of.minMargin;else{var y=n.get("textMargin");null!=y&&(p.margin=ft(y),p.__marginType=Of.textMargin)}Sf(t,n,u,null,null,i,r,e,!0,!1)}(a,t,i,r,e),n&&P(a,n),a}function wf(t,n,i){n=n||{};var r,e={},a=t.getShallow("rotate"),o=ut(t.getShallow("distance"),i?null:5),u=t.getShallow("offset");return"outside"===(r=t.getShallow("position")||(i?null:"inside"))&&(r=n.defaultOutsidePosition||"top"),null!=r&&(e.position=r),null!=u&&(e.offset=u),null!=a&&(a*=Math.PI/180,e.rotation=a),null!=o&&(e.distance=o),e.outsideFill="inherit"===t.get("color")?n.inheritColor||null:"auto",null!=n.autoOverflowArea&&(e.autoOverflowArea=n.autoOverflowArea),null!=n.layoutRect&&(e.layoutRect=n.layoutRect),e}var xf=["fontStyle","fontWeight","fontSize","fontFamily","textShadowColor","textShadowBlur","textShadowOffsetX","textShadowOffsetY"],Mf=["align","lineHeight","width","height","tag","verticalAlign","ellipsis"],kf=["padding","borderWidth","borderRadius","borderDashOffset","backgroundColor","borderColor","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"];function Sf(t,n,i,r,e,a,o,u,s,l){i=!o&&i||df;var f=a&&a.inheritColor,h=n.getShallow("color"),c=n.getShallow("textBorderColor"),v=ut(n.getShallow("opacity"),i.opacity);"inherit"!==h&&"auto"!==h||(h=f||null),"inherit"!==c&&"auto"!==c||(c=f||null),u||(h=h||i.color,c=c||i.textBorderColor),null!=h&&(t.fill=h),null!=c&&(t.stroke=c);var d=ut(n.getShallow("textBorderWidth"),i.textBorderWidth);null!=d&&(t.lineWidth=d);var p=ut(n.getShallow("textBorderType"),i.textBorderType);null!=p&&(t.lineDash=p);var m=ut(n.getShallow("textBorderDashOffset"),i.textBorderDashOffset);null!=m&&(t.lineDashOffset=m),o||null!=v||l||(v=a&&a.defaultOpacity),null!=v&&(t.opacity=v),o||u||null==t.fill&&a.inheritColor&&(t.fill=a.inheritColor);for(var y=0;y<xf.length;y++){var g=xf[y];null!=(w=!1!==e&&r?st(n.getShallow(g),r.getShallow(g),i[g]):ut(n.getShallow(g),i[g]))&&(t[g]=w)}for(y=0;y<Mf.length;y++)null!=(w=n.getShallow(g=Mf[y]))&&(t[g]=w);if(null==t.verticalAlign){var b=n.getShallow("baseline");null!=b&&(t.verticalAlign=b)}if(!s||!a.disableBox){for(y=0;y<kf.length;y++){var w;null!=(w=n.getShallow(g=kf[y]))&&(t[g]=w)}var x=n.getShallow("borderType");null!=x&&(t.borderDash=x),"auto"!==t.backgroundColor&&"inherit"!==t.backgroundColor||!f||(t.backgroundColor=f),"auto"!==t.borderColor&&"inherit"!==t.borderColor||!f||(t.borderColor=f)}}var Af=Po();function Tf(t,n,i,r){if(t){var e=Af(t);e.prevValue=e.value,e.value=i;var a=n.normal;e.valueAnimation=a.get("valueAnimation"),e.valueAnimation&&(e.precision=a.get("precision"),e.defaultInterpolatedText=r,e.statesModels=n)}}var Nf,Cf,Of={minMargin:1,textMargin:2},If=["textStyle","color"],Lf=["fontStyle","fontWeight","fontSize","fontFamily","padding","lineHeight","rich","width","height","overflow"],Df=new Ia,_f=function(){function t(){}return t.prototype.getTextColor=function(t){var n=this.ecModel;return this.getShallow("color")||(!t&&n?n.get(If):null)},t.prototype.getFont=function(){return t={fontStyle:this.getShallow("fontStyle"),fontWeight:this.getShallow("fontWeight"),fontSize:this.getShallow("fontSize"),fontFamily:this.getShallow("fontFamily")},i=(n=this.ecModel)&&n.getModel("textStyle"),ct([t.fontStyle||i&&i.getShallow("fontStyle")||"",t.fontWeight||i&&i.getShallow("fontWeight")||"",(t.fontSize||i&&i.getShallow("fontSize")||12)+"px",t.fontFamily||i&&i.getShallow("fontFamily")||"sans-serif"].join(" "));var t,n,i},t.prototype.getTextRect=function(t){for(var n={text:t,verticalAlign:this.getShallow("verticalAlign")||this.getShallow("baseline")},i=0;i<Lf.length;i++)n[Lf[i]]=this.getShallow(Lf[i]);return Df.useStyle(n),Df.update(),Df.getBoundingRect()},t}(),zf=[["lineWidth","width"],["stroke","color"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"],["lineDash","type"],["lineDashOffset","dashOffset"],["lineCap","cap"],["lineJoin","join"],["miterLimit"]],Rf=Rt(zf),Ff=function(){function t(){}return t.prototype.getLineStyle=function(t){return Rf(this,t)},t}(),Pf=[["fill","color"],["stroke","borderColor"],["lineWidth","borderWidth"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"],["lineDash","borderType"],["lineDashOffset","borderDashOffset"],["lineCap","borderCap"],["lineJoin","borderJoin"],["miterLimit","borderMiterLimit"]],Bf=Rt(Pf),Ef=function(){function t(){}return t.prototype.getItemStyle=function(t,n){return Bf(this,t,n)},t}(),Wf=function(){function t(t,n,i){this.parentModel=n,this.ecModel=i,this.option=t}return t.prototype.init=function(){},t.prototype.mergeOption=function(t){F(this.option,t,!0)},t.prototype.get=function(t,n){return null==t?this.option:this._doGet(this.parsePath(t),!n&&this.parentModel)},t.prototype.getShallow=function(t,n){var i=this.option,r=null==i?i:i[t];if(null==r&&!n){var e=this.parentModel;e&&(r=e.getShallow(t))}return r},t.prototype.getModel=function(n,i){var r=null!=n,e=r?this.parsePath(n):null;return new t(r?this._doGet(e):this.option,i=i||this.parentModel&&this.parentModel.getModel(this.resolveParentPath(e)),this.ecModel)},t.prototype.isEmpty=function(){return null==this.option},t.prototype.restoreData=function(){},t.prototype.clone=function(){return new(0,this.constructor)(R(this.option))},t.prototype.parsePath=function(t){return"string"==typeof t?t.split("."):t},t.prototype.resolveParentPath=function(t){return t},t.prototype.isAnimationEnabled=function(){if(!At.node&&this.option){if(null!=this.option.animation)return!!this.option.animation;if(this.parentModel)return this.parentModel.isAnimationEnabled()}},t.prototype._doGet=function(t,n){var i=this.option;if(!t)return i;for(var r=0;r<t.length&&(!t[r]||null!=(i=i&&"object"==typeof i?i[t[r]]:null));r++);return null==i&&n&&(i=n._doGet(this.resolveParentPath(t),n.parentModel)),i},t}();function jf(t){return null==t?0:t.length||1}function Hf(t){return t}Ot(Wf),Nf=Wf,Cf=["__\0is_clz",Lt++].join("_"),Nf.prototype[Cf]=!0,Nf.isInstance=function(t){return!(!t||!t[Cf])},W(Wf,Ff),W(Wf,Ef),W(Wf,Pt),W(Wf,_f);var Uf=function(){function t(t,n,i,r,e,a){this._old=t,this._new=n,this._oldKeyGetter=i||Hf,this._newKeyGetter=r||Hf,this.context=e,this._diffModeMultiple="multiple"===a}return t.prototype.add=function(t){return this._add=t,this},t.prototype.update=function(t){return this._update=t,this},t.prototype.updateManyToOne=function(t){return this._updateManyToOne=t,this},t.prototype.updateOneToMany=function(t){return this._updateOneToMany=t,this},t.prototype.updateManyToMany=function(t){return this._updateManyToMany=t,this},t.prototype.remove=function(t){return this._remove=t,this},t.prototype.execute=function(){this[this._diffModeMultiple?"_executeMultiple":"_executeOneToOne"]()},t.prototype._executeOneToOne=function(){var t=this._old,n=this._new,i={},r=new Array(t.length),e=new Array(n.length);this._initIndexMap(t,null,r,"_oldKeyGetter"),this._initIndexMap(n,i,e,"_newKeyGetter");for(var a=0;a<t.length;a++){var o=r[a],u=i[o],s=jf(u);if(s>1){var l=u.shift();1===u.length&&(i[o]=u[0]),this._update&&this._update(l,a)}else 1===s?(i[o]=null,this._update&&this._update(u,a)):this._remove&&this._remove(a)}this._performRestAdd(e,i)},t.prototype._executeMultiple=function(){var t=this._new,n={},i={},r=[],e=[];this._initIndexMap(this._old,n,r,"_oldKeyGetter"),this._initIndexMap(t,i,e,"_newKeyGetter");for(var a=0;a<r.length;a++){var o=r[a],u=n[o],s=i[o],l=jf(u),f=jf(s);if(l>1&&1===f)this._updateManyToOne&&this._updateManyToOne(s,u),i[o]=null;else if(1===l&&f>1)this._updateOneToMany&&this._updateOneToMany(s,u),i[o]=null;else if(1===l&&1===f)this._update&&this._update(s,u),i[o]=null;else if(l>1&&f>1)this._updateManyToMany&&this._updateManyToMany(s,u),i[o]=null;else if(l>1)for(var h=0;h<l;h++)this._remove&&this._remove(u[h]);else this._remove&&this._remove(u)}this._performRestAdd(e,i)},t.prototype._performRestAdd=function(t,n){for(var i=0;i<t.length;i++){var r=t[i],e=n[r],a=jf(e);if(a>1)for(var o=0;o<a;o++)this._add&&this._add(e[o]);else 1===a&&this._add&&this._add(e);n[r]=null}},t.prototype._initIndexMap=function(t,n,i,r){for(var e=this._diffModeMultiple,a=0;a<t.length;a++){var o="_ec_"+this[r](t[a],a);if(e||(i[a]=o),n){var u=n[o],s=jf(u);0===s?(n[o]=a,e&&i.push(o)):1===s?n[o]=[u,a]:u.push(a)}}},t}(),Vf=Po();function $f(t,n,i){var r={},e=Xf(n);if(!e||!t)return r;var a,o,u=[],s=[],l=Vf(n.ecModel).datasetMap,f=e.uid+"_"+i.seriesLayoutBy;H(t=t.slice(),(function(n,i){var e=tt(n)?n:t[i]={name:n};"ordinal"===e.type&&null==a&&(a=i,o=v(e)),r[e.name]=[]}));var h=l.get(f)||l.set(f,{categoryWayDim:o,valueWayDim:0});function c(t,n,i){for(var r=0;r<i;r++)t.push(n+r)}function v(t){var n=t.dimsDef;return n?n.length:1}return H(t,(function(t,n){var i=t.name,e=v(t);if(null==a)c(r[i],o=h.valueWayDim,e),c(s,o,e),h.valueWayDim+=e;else if(a===n)c(r[i],0,e),c(u,0,e);else{var o;c(r[i],o=h.categoryWayDim,e),c(s,o,e),h.categoryWayDim+=e}})),u.length&&(r.itemName=u),s.length&&(r.seriesName=s),r}function Yf(t,n,i){var r={};if(!Xf(t))return r;var e,a=n.sourceFormat,o=n.dimensionsDefine;a!==cu&&a!==vu||H(o,(function(t,n){"name"===(tt(t)?t.name:t)&&(e=n)}));var u=function(){for(var t={},r={},u=[],s=0,l=Math.min(5,i);s<l;s++){var f=Gf(n.data,a,n.seriesLayoutBy,o,n.startIndex,s);u.push(f);var h=3===f;if(h&&null==t.v&&s!==e&&(t.v=s),(null==t.n||t.n===t.v||!h&&3===u[t.n])&&(t.n=s),c(t)&&3!==u[t.n])return t;h||(2===f&&null==r.v&&s!==e&&(r.v=s),null!=r.n&&r.n!==r.v||(r.n=s))}function c(t){return null!=t.v&&null!=t.n}return c(t)?t:c(r)?r:null}();if(u){r.value=[u.v];var s=null!=e?e:u.n;r.itemName=[s],r.seriesName=[s]}return r}function Xf(t){if(!t.get("data",!0))return Ho(t.ecModel,"dataset",{index:t.get("datasetIndex",!0),id:t.get("datasetId",!0)},jo).models[0]}function qf(t,n){return Gf(t.data,t.sourceFormat,t.seriesLayoutBy,t.dimensionsDefine,t.startIndex,n)}function Gf(t,n,i,r,e,a){var o,u,s;if(it(t))return 3;if(r){var l=r[a];tt(l)?(u=l.name,s=l.type):J(l)&&(u=l)}if(null!=s)return"ordinal"===s?1:3;if(n===hu){var f=t;if(i===yu){for(var h=f[a],c=0;c<(h||[]).length&&c<5;c++)if(null!=(o=g(h[e+c])))return o}else for(c=0;c<f.length&&c<5;c++){var v=f[e+c];if(v&&null!=(o=g(v[a])))return o}}else if(n===cu){var d=t;if(!u)return 3;for(c=0;c<d.length&&c<5;c++)if((m=d[c])&&null!=(o=g(m[u])))return o}else if(n===vu){if(!u)return 3;if(!(h=t[u])||it(h))return 3;for(c=0;c<h.length&&c<5;c++)if(null!=(o=g(h[c])))return o}else if(n===fu){var p=t;for(c=0;c<p.length&&c<5;c++){var m,y=Oo(m=p[c]);if(!G(y))return 3;if(null!=(o=g(y[a])))return o}}function g(t){var n=J(t);return null!=t&&isFinite(Number(t))&&""!==t?n?2:3:n&&"-"!==t?1:void 0}return 3}var Zf,Jf,Kf,Qf,th,nh,ih=function(t){this.data=t.data||(t.sourceFormat===vu?{}:[]),this.sourceFormat=t.sourceFormat||pu,this.seriesLayoutBy=t.seriesLayoutBy||mu,this.startIndex=t.startIndex||0,this.dimensionsDetectedCount=t.dimensionsDetectedCount,this.metaRawOption=t.metaRawOption;var n=this.dimensionsDefine=t.dimensionsDefine;if(n)for(var i=0;i<n.length;i++){var r=n[i];null==r.type&&1===qf(this,i)&&(r.type="ordinal")}};function rh(t){return t instanceof ih}function eh(t,n,i){i=i||oh(t);var r=n.seriesLayoutBy,e=function(t,n,i,r,e){var a,o;if(!t)return{dimensionsDefine:uh(e),startIndex:o,dimensionsDetectedCount:a};if(n===hu){var u=t;"auto"===r||null==r?sh((function(t){null!=t&&"-"!==t&&(J(t)?null==o&&(o=1):o=0)}),i,u,10):o=Q(r)?r:r?1:0,e||1!==o||(e=[],sh((function(t,n){e[n]=null!=t?t+"":""}),i,u,1/0)),a=e?e.length:i===yu?u.length:u[0]?u[0].length:null}else if(n===cu)e||(e=function(t){for(var n,i=0;i<t.length&&!(n=t[i++]););if(n)return Y(n)}(t));else if(n===vu)e||(e=[],H(t,(function(t,n){e.push(n)})));else if(n===fu){var s=Oo(t[0]);a=G(s)&&s.length||1}return{startIndex:o,dimensionsDefine:uh(e),dimensionsDetectedCount:a}}(t,i,r,n.sourceHeader,n.dimensions);return new ih({data:t,sourceFormat:i,seriesLayoutBy:r,dimensionsDefine:e.dimensionsDefine,startIndex:e.startIndex,dimensionsDetectedCount:e.dimensionsDetectedCount,metaRawOption:R(n)})}function ah(t){return new ih({data:t,sourceFormat:it(t)?du:fu})}function oh(t){var n=pu;if(it(t))n=du;else if(G(t)){0===t.length&&(n=hu);for(var i=0,r=t.length;i<r;i++){var e=t[i];if(null!=e){if(G(e)||it(e)){n=hu;break}if(tt(e)){n=cu;break}}}}else if(tt(t))for(var a in t)if(xt(t,a)&&j(t[a])){n=vu;break}return n}function uh(t){if(t){var n=bt();return U(t,(function(t){var i={name:(t=tt(t)?t:{name:t}).name,displayName:t.displayName,type:t.type};if(null==i.name)return i;i.name+="",null==i.displayName&&(i.displayName=i.name);var r=n.get(i.name);return r?i.name+="-"+r.count++:n.set(i.name,{count:1}),i}))}}function sh(t,n,i,r){if(n===yu)for(var e=0;e<i.length&&e<r;e++)t(i[e]?i[e][0]:null,e);else{var a=i[0]||[];for(e=0;e<a.length&&e<r;e++)t(a[e],e)}}var lh=function(){function t(t,n){var i=rh(t)?t:ah(t);this._source=i;var r=this._data=i.data;i.sourceFormat===du&&(this._offset=0,this._dimSize=n,this._data=r),nh(this,r,i)}var n;return t.prototype.getSource=function(){return this._source},t.prototype.count=function(){return 0},t.prototype.getItem=function(){},t.prototype.appendData=function(){},t.prototype.clean=function(){},t.protoInitialize=((n=t.prototype).pure=!1,void(n.persistent=!0)),t.internalField=function(){var t;nh=function(t,e,a){var o=a.sourceFormat,u=a.seriesLayoutBy,s=a.startIndex,l=a.dimensionsDefine;if(P(t,th[wh(o,u)]),o===du)t.getItem=n,t.count=r,t.fillStorage=i;else{var f=vh(o,u);t.getItem=X(f,null,e,s,l);var h=mh(o,u);t.count=X(h,null,e,s,l)}};var n=function(t,n){n=n||[];for(var i=this._data,r=this._dimSize,e=r*(t-=this._offset),a=0;a<r;a++)n[a]=i[e+a];return n},i=function(t,n,i,r){for(var e=this._data,a=this._dimSize,o=0;o<a;o++){for(var u=r[o],s=null==u[0]?1/0:u[0],l=null==u[1]?-1/0:u[1],f=n-t,h=i[o],c=0;c<f;c++){var v=e[c*a+o];h[t+c]=v,v<s&&(s=v),v>l&&(l=v)}u[0]=s,u[1]=l}},r=function(){return this._data?this._data.length/this._dimSize:0};function e(t){for(var n=0;n<t.length;n++)this._data.push(t[n])}(t={})[hu+"_"+mu]={pure:!0,appendData:e},t[hu+"_"+yu]={pure:!0,appendData:function(){throw new Error('Do not support appendData when set seriesLayoutBy: "row".')}},t[cu]={pure:!0,appendData:e},t[vu]={pure:!0,appendData:function(t){var n=this._data;H(t,(function(t,i){for(var r=n[i]||(n[i]=[]),e=0;e<(t||[]).length;e++)r.push(t[e])}))}},t[fu]={appendData:e},t[du]={persistent:!1,pure:!0,appendData:function(t){this._data=t},clean:function(){this._offset+=this.count(),this._data=null}},th=t}(),t}(),fh=function(t){G(t)||Mo("series.data or dataset.source must be an array.")};(Zf={})[hu+"_"+mu]=fh,Zf[hu+"_"+yu]=fh,Zf[cu]=fh,Zf[vu]=function(t,n){for(var i=0;i<n.length;i++)null==n[i].name&&Mo("dimension name must not be null/undefined.")},Zf[fu]=fh;var hh=function(t,n,i,r){return t[r]},ch=((Jf={})[hu+"_"+mu]=function(t,n,i,r){return t[r+n]},Jf[hu+"_"+yu]=function(t,n,i,r,e){r+=n;for(var a=e||[],o=t,u=0;u<o.length;u++){var s=o[u];a[u]=s?s[r]:null}return a},Jf[cu]=hh,Jf[vu]=function(t,n,i,r,e){for(var a=e||[],o=0;o<i.length;o++){var u=i[o].name,s=null!=u?t[u]:null;a[o]=s?s[r]:null}return a},Jf[fu]=hh,Jf);function vh(t,n){return ch[wh(t,n)]}var dh=function(t){return t.length},ph=((Kf={})[hu+"_"+mu]=function(t,n){return Math.max(0,t.length-n)},Kf[hu+"_"+yu]=function(t,n){var i=t[0];return i?Math.max(0,i.length-n):0},Kf[cu]=dh,Kf[vu]=function(t,n,i){var r=i[0].name,e=null!=r?t[r]:null;return e?e.length:0},Kf[fu]=dh,Kf);function mh(t,n){return ph[wh(t,n)]}var yh=function(t,n){return t[n]},gh=((Qf={})[hu]=yh,Qf[cu]=function(t,n,i){return t[i]},Qf[vu]=yh,Qf[fu]=function(t,n){var i=Oo(t);return i instanceof Array?i[n]:i},Qf[du]=yh,Qf);function bh(t){return gh[t]}function wh(t,n){return t===hu?t+"_"+n:t}function xh(t,n,i){if(t){var r=t.getRawDataItem(n);if(null!=r){var e=t.getStore(),a=e.getSource().sourceFormat;if(null!=i){var o=t.getDimensionIndex(i),u=e.getDimensionProperty(o);return bh(a)(r,o,u)}var s=r;return a===fu&&(s=Oo(r)),s}}}var Mh=function(){function t(t,n){this._encode=t,this._schema=n}return t.prototype.get=function(){return{fullDimensions:this._getFullDimensionNames(),encode:this._encode}},t.prototype._getFullDimensionNames=function(){return this._cachedDimNames||(this._cachedDimNames=this._schema?this._schema.makeOutputDimensionNames():[]),this._cachedDimNames},t}();function kh(t,n){return t.hasOwnProperty(n)||(t[n]=[]),t[n]}var Sh=function(t){this.otherDims={},null!=t&&P(this,t)};function Ah(t,n){var i=n&&n.type;return"ordinal"===i?t:("time"!==i||Q(t)||null==t||"-"===t||(t=+ho(t)),null==t||""===t?NaN:Number(t))}bt({number:function(t){return parseFloat(t)},time:function(t){return+ho(t)},trim:function(t){return J(t)?ct(t):t}});var Th=function(){function t(t,n){var i="desc"===t;this._resultLT=i?1:-1,null==n&&(n=i?"min":"max"),this._incomparable="min"===n?-1/0:1/0}return t.prototype.evaluate=function(t,n){var i=Q(t)?t:mo(t),r=Q(n)?n:mo(n),e=isNaN(i),a=isNaN(r);if(e&&(i=this._incomparable),a&&(r=this._incomparable),e&&a){var o=J(t),u=J(n);o&&(i=u?t:0),u&&(r=o?n:0)}return i<r?this._resultLT:i>r?-this._resultLT:0},t}();function Nh(t){var n="",i=-1/0,r=-1/0,e=1/0,a=1/0;return t&&(null!=t.g&&(n+="G"+t.g,i=t.g),null!=t.ge&&(n+="GE"+t.ge,r=t.ge),null!=t.l&&(n+="L"+t.l,e=t.l),null!=t.le&&(n+="LE"+t.le,a=t.le)),{key:n,g:i,ge:r,l:e,le:a}}function Ch(t,n){return n>t.g&&n>=t.ge&&n<t.l&&n<=t.le}var Oh,Ih=typeof Uint32Array===uu?Array:Uint32Array,Lh=typeof Uint16Array===uu?Array:Uint16Array,Dh=typeof Int32Array===uu?Array:Int32Array,_h=typeof Float64Array===uu?Array:Float64Array,zh={float:_h,int:Dh,ordinal:Array,number:Array,time:_h};function Rh(t){return t>65535?Ih:Lh}function Fh(t,n,i,r,e){var a=zh[i||"float"];if(e){var o=t[n],u=o&&o.length;if(u!==r){for(var s=new a(r),l=0;l<u;l++)s[l]=o[l];t[n]=s}}else t[n]=new a(r)}var Ph=function(){function t(){this._chunks=[],this._rawExtent=[],this._extent=[],this._count=0,this._rawCount=0,this._calcDimNameToIdx=bt()}return t.prototype.initData=function(t,n,i){this._provider=t,this._chunks=[],this._indices=null,this.getRawIndex=this._getRawIdxIdentity;var r=t.getSource(),e=this.defaultDimValueGetter=Oh[r.sourceFormat];this._dimValueGetter=i||e,this._rawExtent=[],this._dimensions=U(n,(function(t){return{type:t.type,property:t.property}})),this._initDataFromProvider(0,t.count())},t.prototype.getProvider=function(){return this._provider},t.prototype.getSource=function(){return this._provider.getSource()},t.prototype.ensureCalculationDimension=function(t,n){var i=this._calcDimNameToIdx,r=this._dimensions,e=i.get(t);if(null!=e){if(r[e].type===n)return e}else e=r.length;return r[e]={type:n},i.set(t,e),this._chunks[e]=new zh[n||"float"](this._rawCount),this._rawExtent[e]=[1/0,-1/0],e},t.prototype.collectOrdinalMeta=function(t,n){var i=this._chunks[t],r=this._dimensions[t],e=this._rawExtent,a=r.ordinalOffset||0,o=i.length;0===a&&(e[t]=[1/0,-1/0]);for(var u=e[t],s=a;s<o;s++){var l=i[s]=n.parseAndCollect(i[s]);isNaN(l)||(u[0]=Math.min(l,u[0]),u[1]=Math.max(l,u[1]))}r.ordinalMeta=n,r.ordinalOffset=o,r.type="ordinal"},t.prototype.getOrdinalMeta=function(t){return this._dimensions[t].ordinalMeta},t.prototype.getDimensionProperty=function(t){var n=this._dimensions[t];return n&&n.property},t.prototype.appendData=function(t){var n=this._provider,i=this.count();n.appendData(t);var r=n.count();return n.persistent||(r+=i),i<r&&this._initDataFromProvider(i,r,!0),[i,r]},t.prototype.appendValues=function(t,n){for(var i=this._chunks,r=this._dimensions,e=r.length,a=this._rawExtent,o=this.count(),u=o+Math.max(t.length,n||0),s=0;s<e;s++)Fh(i,s,r[s].type,u,!0);for(var l=[],f=o;f<u;f++)for(var h=f-o,c=0;c<e;c++){var v=Oh.arrayRows.call(this,t[h]||l,r[c].property,h,c);i[c][f]=v;var d=a[c];v<d[0]&&(d[0]=v),v>d[1]&&(d[1]=v)}return this._rawCount=this._count=u,{start:o,end:u}},t.prototype._initDataFromProvider=function(t,n,i){for(var r=this._provider,e=this._chunks,a=this._dimensions,o=a.length,u=this._rawExtent,s=U(a,(function(t){return t.property})),l=0;l<o;l++){var f=a[l];u[l]||(u[l]=[1/0,-1/0]),Fh(e,l,f.type,n,i)}if(r.fillStorage)r.fillStorage(t,n,e,u);else for(var h=[],c=t;c<n;c++){h=r.getItem(c,h);for(var v=0;v<o;v++){var d=e[v],p=this._dimValueGetter(h,s[v],c,v);d[c]=p;var m=u[v];p<m[0]&&(m[0]=p),p>m[1]&&(m[1]=p)}}!r.persistent&&r.clean&&r.clean(),this._rawCount=this._count=n,this._extent=[]},t.prototype.count=function(){return this._count},t.prototype.get=function(t,n){if(!(n>=0&&n<this._count))return NaN;var i=this._chunks[t];return i?i[this.getRawIndex(n)]:NaN},t.prototype.getValues=function(t,n){var i=[],r=[];if(null==n){n=t,t=[];for(var e=0;e<this._dimensions.length;e++)r.push(e)}else r=t;e=0;for(var a=r.length;e<a;e++)i.push(this.get(r[e],n));return i},t.prototype.getByRawIndex=function(t,n){if(!(n>=0&&n<this._rawCount))return NaN;var i=this._chunks[t];return i?i[n]:NaN},t.prototype.getSum=function(t){var n=0;if(this._chunks[t])for(var i=0,r=this.count();i<r;i++){var e=this.get(t,i);isNaN(e)||(n+=e)}return n},t.prototype.getMedian=function(t){var n=[];this.each([t],(function(t){isNaN(t)||n.push(t)})),eo(n);var i=this.count();return 0===i?0:i%2==1?n[(i-1)/2]:(n[i/2]+n[i/2-1])/2},t.prototype.indexOfRawIndex=function(t){if(t>=this._rawCount||t<0)return-1;if(!this._indices)return t;var n=this._indices,i=n[t];if(null!=i&&i<this._count&&i===t)return t;for(var r=0,e=this._count-1;r<=e;){var a=(r+e)/2|0;if(n[a]<t)r=a+1;else{if(!(n[a]>t))return a;e=a-1}}return-1},t.prototype.getIndices=function(){var t,n=this._indices;if(n){var i=this._count;if((e=n.constructor)===Array){t=new e(i);for(var r=0;r<i;r++)t[r]=n[r]}else t=new e(n.buffer,0,i)}else{var e;for(t=new(e=Rh(this._rawCount))(this.count()),r=0;r<t.length;r++)t[r]=r}return t},t.prototype.filter=function(t,n){if(!this._count)return this;for(var i=this.clone(),r=i.count(),e=new(Rh(i._rawCount))(r),a=[],o=t.length,u=0,s=t[0],l=i._chunks,f=0;f<r;f++){var h=void 0,c=i.getRawIndex(f);if(0===o)h=n(f);else if(1===o)h=n(l[s][c],f);else{for(var v=0;v<o;v++)a[v]=l[t[v]][c];a[v]=f,h=n.apply(null,a)}h&&(e[u++]=c)}return u<r&&(i._indices=e),i._count=u,i._extent=[],i._updateGetRawIdx(),i},t.prototype.selectRange=function(t){var n=this.clone(),i=n._count;if(!i)return this;var r=Y(t),e=r.length;if(!e)return this;var a=n.count(),o=new(Rh(n._rawCount))(a),u=0,s=r[0],l=t[s][0],f=t[s][1],h=n._chunks,c=!1;if(!n._indices){var v=0;if(1===e){for(var d=h[r[0]],p=0;p<i;p++)((k=d[p])>=l&&k<=f||isNaN(k))&&(o[u++]=v),v++;c=!0}else if(2===e){d=h[r[0]];var m=h[r[1]],y=t[r[1]][0],g=t[r[1]][1];for(p=0;p<i;p++){var b=m[p];((k=d[p])>=l&&k<=f||isNaN(k))&&(b>=y&&b<=g||isNaN(b))&&(o[u++]=v),v++}c=!0}}if(!c)if(1===e)for(p=0;p<a;p++){var w=n.getRawIndex(p);((k=h[r[0]][w])>=l&&k<=f||isNaN(k))&&(o[u++]=w)}else for(p=0;p<a;p++){for(var x=!0,M=(w=n.getRawIndex(p),0);M<e;M++){var k,S=r[M];((k=h[S][w])<t[S][0]||k>t[S][1])&&(x=!1)}x&&(o[u++]=n.getRawIndex(p))}return u<a&&(n._indices=o),n._count=u,n._extent=[],n._updateGetRawIdx(),n},t.prototype.map=function(t,n){var i=this.clone(t);return this._updateDims(i,t,n),i},t.prototype.modify=function(t,n){this._updateDims(this,t,n)},t.prototype._updateDims=function(t,n,i){for(var r=t._chunks,e=[],a=n.length,o=t.count(),u=[],s=t._rawExtent,l=0;l<n.length;l++)s[n[l]]=[1/0,-1/0];for(var f=0;f<o;f++){for(var h=t.getRawIndex(f),c=0;c<a;c++)u[c]=r[n[c]][h];u[a]=f;var v=i&&i.apply(null,u);if(null!=v)for("object"!=typeof v&&(e[0]=v,v=e),l=0;l<v.length;l++){var d=n[l],p=v[l],m=s[d],y=r[d];y&&(y[h]=p),p<m[0]&&(m[0]=p),p>m[1]&&(m[1]=p)}}},t.prototype.lttbDownSample=function(t,n){var i,r,e,a=this.clone([t],!0),o=a._chunks[t],u=this.count(),s=0,l=Math.floor(1/n),f=this.getRawIndex(0),h=new(Rh(this._rawCount))(Math.min(2*(Math.ceil(u/l)+2),u));h[s++]=f;for(var c=1;c<u-1;c+=l){for(var v=Math.min(c+l,u-1),d=Math.min(c+2*l,u),p=(d+v)/2,m=0,y=v;y<d;y++){var g=o[A=this.getRawIndex(y)];isNaN(g)||(m+=g)}m/=d-v;var b=c,w=Math.min(c+l,u),x=c-1,M=o[f];i=-1,e=b;var k=-1,S=0;for(y=b;y<w;y++){var A;g=o[A=this.getRawIndex(y)],isNaN(g)?(S++,k<0&&(k=A)):(r=Math.abs((x-p)*(g-M)-(x-y)*(m-M)))>i&&(i=r,e=A)}S>0&&S<w-b&&(h[s++]=Math.min(k,e),e=Math.max(k,e)),h[s++]=e,f=e}return h[s++]=this.getRawIndex(u-1),a._count=s,a._indices=h,a.getRawIndex=this._getRawIdx,a},t.prototype.minmaxDownSample=function(t,n){for(var i=this.clone([t],!0),r=i._chunks,e=Math.floor(1/n),a=r[t],o=this.count(),u=new(Rh(this._rawCount))(2*Math.ceil(o/e)),s=0,l=0;l<o;l+=e){var f=l,h=a[this.getRawIndex(f)],c=l,v=a[this.getRawIndex(c)],d=e;l+e>o&&(d=o-l);for(var p=0;p<d;p++){var m=a[this.getRawIndex(l+p)];m<h&&(h=m,f=l+p),m>v&&(v=m,c=l+p)}var y=this.getRawIndex(f),g=this.getRawIndex(c);f<c?(u[s++]=y,u[s++]=g):(u[s++]=g,u[s++]=y)}return i._count=s,i._indices=u,i._updateGetRawIdx(),i},t.prototype.downSample=function(t,n,i,r){for(var e=this.clone([t],!0),a=e._chunks,o=[],u=Math.floor(1/n),s=a[t],l=this.count(),f=e._rawExtent[t]=[1/0,-1/0],h=new(Rh(this._rawCount))(Math.ceil(l/u)),c=0,v=0;v<l;v+=u){u>l-v&&(o.length=u=l-v);for(var d=0;d<u;d++){var p=this.getRawIndex(v+d);o[d]=s[p]}var m=i(o),y=this.getRawIndex(Math.min(v+r(o,m)||0,l-1));s[y]=m,m<f[0]&&(f[0]=m),m>f[1]&&(f[1]=m),h[c++]=y}return e._count=c,e._indices=h,e._updateGetRawIdx(),e},t.prototype.each=function(t,n){if(this._count)for(var i=t.length,r=this._chunks,e=0,a=this.count();e<a;e++){var o=this.getRawIndex(e);switch(i){case 0:n(e);break;case 1:n(r[t[0]][o],e);break;case 2:n(r[t[0]][o],r[t[1]][o],e);break;default:for(var u=0,s=[];u<i;u++)s[u]=r[t[u]][o];s[u]=e,n.apply(null,s)}}},t.prototype.getDataExtent=function(t,n){var i=this._chunks[t],r=[1/0,-1/0];if(!i)return r;var e=this.count();if(!this._indices&&!n)return this._rawExtent[t].slice();var a=this._extent,o=a[t]||(a[t]={}),u=Nh(n),s=u.key,l=o[s];if(l)return l.slice();for(var f=r[0],h=r[1],c=0;c<e;c++){var v=i[this.getRawIndex(c)];n&&!Ch(u,v)||(v<f&&(f=v),v>h&&(h=v))}return o[s]=[f,h]},t.prototype.getRawDataItem=function(t){var n=this.getRawIndex(t);if(this._provider.persistent)return this._provider.getItem(n);for(var i=[],r=this._chunks,e=0;e<r.length;e++)i.push(r[e][n]);return i},t.prototype.clone=function(n,i){var r,e,a=new t,o=this._chunks,u=n&&V(n,(function(t,n){return t[n]=!0,t}),{});if(u)for(var s=0;s<o.length;s++)a._chunks[s]=u[s]?(e=void 0,(e=(r=o[s]).constructor)===Array?r.slice():new e(r)):o[s];else a._chunks=o;return this._copyCommonProps(a),i||(a._indices=this._cloneIndices()),a._updateGetRawIdx(),a},t.prototype._copyCommonProps=function(t){t._count=this._count,t._rawCount=this._rawCount,t._provider=this._provider,t._dimensions=this._dimensions,t._extent=R(this._extent),t._rawExtent=R(this._rawExtent)},t.prototype._cloneIndices=function(){if(this._indices){var t=this._indices.constructor,n=void 0;if(t===Array){var i=this._indices.length;n=new t(i);for(var r=0;r<i;r++)n[r]=this._indices[r]}else n=new t(this._indices);return n}return null},t.prototype._getRawIdxIdentity=function(t){return t},t.prototype._getRawIdx=function(t){return t<this._count&&t>=0?this._indices[t]:-1},t.prototype._updateGetRawIdx=function(){this.getRawIndex=this._indices?this._getRawIdx:this._getRawIdxIdentity},t.internalField=function(){function t(t,n,i,r){return Ah(t[r],this._dimensions[r])}Oh={arrayRows:t,objectRows:function(t,n,i,r){return Ah(t[n],this._dimensions[r])},keyedColumns:t,original:function(t,n,i,r){var e=t&&(null==t.value?t:t.value);return Ah(e instanceof Array?e[r]:e,this._dimensions[r])},typedArray:function(t,n,i,r){return t[r]}}}(),t}(),Bh=Po(),Eh={float:"f",int:"i",ordinal:"o",number:"n",time:"t"},Wh=function(){function t(t){this.dimensions=t.dimensions,this._dimOmitted=t.dimensionOmitted,this.source=t.source,this._fullDimCount=t.fullDimensionCount,this._updateDimOmitted(t.dimensionOmitted)}return t.prototype.isDimensionOmitted=function(){return this._dimOmitted},t.prototype._updateDimOmitted=function(t){this._dimOmitted=t,t&&(this._dimNameMap||(this._dimNameMap=Uh(this.source)))},t.prototype.getSourceDimensionIndex=function(t){return ut(this._dimNameMap.get(t),-1)},t.prototype.getSourceDimension=function(t){var n=this.source.dimensionsDefine;if(n)return n[t]},t.prototype.makeStoreSchema=function(){for(var t=this._fullDimCount,n=function(t){var n=t.sourceFormat;return n===cu||n===vu}(this.source),i=!Vh(t),r="",e=[],a=0,o=0;a<t;a++){var u=void 0,s=void 0,l=void 0,f=this.dimensions[o];if(f&&f.storeDimIndex===a)u=n?f.name:null,s=f.type,l=f.ordinalMeta,o++;else{var h=this.getSourceDimension(a);h&&(u=n?h.name:null,s=h.type)}e.push({property:u,type:s,ordinalMeta:l}),!n||null==u||f&&f.isCalculationCoord||(r+=i?u.replace(/\`/g,"`1").replace(/\$/g,"`2"):u),r+="$",r+=Eh[s]||"f",l&&(r+=l.uid),r+="$"}var c=this.source;return{dimensions:e,hash:[c.seriesLayoutBy,c.startIndex,r].join("$$")}},t.prototype.makeOutputDimensionNames=function(){for(var t=[],n=0,i=0;n<this._fullDimCount;n++){var r=void 0,e=this.dimensions[i];if(e&&e.storeDimIndex===n)e.isCalculationCoord||(r=e.name),i++;else{var a=this.getSourceDimension(n);a&&(r=a.name)}t.push(r)}return t},t.prototype.appendCalculationDimension=function(t){this.dimensions.push(t),t.isCalculationCoord=!0,this._fullDimCount++,this._updateDimOmitted(!0)},t}();function jh(t){return t instanceof Wh}function Hh(t){for(var n=bt(),i=0;i<(t||[]).length;i++){var r=t[i],e=tt(r)?r.name:r;null!=e&&null==n.get(e)&&n.set(e,i)}return n}function Uh(t){var n=Bh(t);return n.dimNameMap||(n.dimNameMap=Hh(t.dimensionsDefine))}function Vh(t){return t>30}var $h,Yh,Xh,qh,Gh,Zh,Jh,Kh=tt,Qh=U,tc="undefined"==typeof Int32Array?Array:Int32Array,nc=["hasItemOption","_nameList","_idList","_invertedIndicesMap","_dimSummary","userOutput","_rawData","_dimValueGetter","_nameDimIdx","_idDimIdx","_nameRepeatCount"],ic=["_approximateExtent"],rc=function(){function t(t,n){var i;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 r=!1;jh(t)?(i=t.dimensions,this._dimOmitted=t.isDimensionOmitted(),this._schema=t):(r=!0,i=t),i=i||["x","y"];for(var e={},a=[],o={},u=!1,s={},l=0;l<i.length;l++){var f=i[l],h=J(f)?new Sh({name:f}):f instanceof Sh?f:new Sh(f),c=h.name;h.type=h.type||"float",h.coordDim||(h.coordDim=c,h.coordDimIndex=0);var v=h.otherDims=h.otherDims||{};a.push(c),e[c]=h,null!=s[c]&&(u=!0),h.createInvertedIndices&&(o[c]=[]),r&&(h.storeDimIndex=l),0===v.itemName&&(this._nameDimIdx=h.storeDimIndex),0===v.itemId&&(this._idDimIdx=h.storeDimIndex)}if(this.dimensions=a,this._dimInfos=e,this._initGetDimensionInfo(u),this.hostModel=n,this._invertedIndicesMap=o,this._dimOmitted){var d=this._dimIdxToName=bt();H(a,(function(t){d.set(e[t].storeDimIndex,t)}))}}return t.prototype.getDimension=function(t){var n=this._recognizeDimIndex(t);if(null==n)return t;if(n=t,!this._dimOmitted)return this.dimensions[n];var i=this._dimIdxToName.get(n);if(null!=i)return i;var r=this._schema.getSourceDimension(n);return r?r.name:void 0},t.prototype.getDimensionIndex=function(t){var n=this._recognizeDimIndex(t);if(null!=n)return n;if(null==t)return-1;var i=this._getDimInfo(t);return i?i.storeDimIndex:this._dimOmitted?this._schema.getSourceDimensionIndex(t):-1},t.prototype._recognizeDimIndex=function(t){if(Q(t)||null!=t&&!isNaN(t)&&!this._getDimInfo(t)&&(!this._dimOmitted||this._schema.getSourceDimensionIndex(t)<0))return+t},t.prototype._getStoreDimIndex=function(t){return this.getDimensionIndex(t)},t.prototype.getDimensionInfo=function(t){return this._getDimInfo(this.getDimension(t))},t.prototype._initGetDimensionInfo=function(t){var n=this._dimInfos;this._getDimInfo=t?function(t){return n.hasOwnProperty(t)?n[t]:void 0}:function(t){return n[t]}},t.prototype.getDimensionsOnCoord=function(){return this._dimSummary.dataDimsOnCoord.slice()},t.prototype.mapDimension=function(t,n){var i=this._dimSummary;if(null==n)return i.encodeFirstDimNotExtra[t];var r=i.encode[t];return r?r[n]:null},t.prototype.mapDimensionsAll=function(t){return(this._dimSummary.encode[t]||[]).slice()},t.prototype.getStore=function(){return this._store},t.prototype.initData=function(t,n,i){var r,e=this;if(t instanceof Ph&&(r=t),!r){var a=this.dimensions,o=rh(t)||j(t)?new lh(t,a.length):t;r=new Ph;var u=Qh(a,(function(t){return{type:e._dimInfos[t].type,property:t}}));r.initData(o,u,i)}this._store=r,this._nameList=(n||[]).slice(),this._idList=[],this._nameRepeatCount={},this._doInit(0,r.count()),this._dimSummary=function(t,n){var i={},r=i.encode={},e=bt(),a=[],o=[],u={};H(t.dimensions,(function(n){var i,s=t.getDimensionInfo(n),l=s.coordDim;if(l){var f=s.coordDimIndex;kh(r,l)[f]=n,s.isExtraCoord||(e.set(l,1),"ordinal"!==(i=s.type)&&"time"!==i&&(a[0]=n),kh(u,l)[f]=t.getDimensionIndex(s.name)),s.defaultTooltip&&o.push(n)}lu.each((function(t,n){var i=kh(r,n),e=s.otherDims[n];null!=e&&!1!==e&&(i[e]=s.name)}))}));var s=[],l={};e.each((function(t,n){var i=r[n];l[n]=i[0],s=s.concat(i)})),i.dataDimsOnCoord=s,i.dataDimIndicesOnCoord=U(s,(function(n){return t.getDimensionInfo(n).storeDimIndex})),i.encodeFirstDimNotExtra=l;var f=r.label;f&&f.length&&(a=f.slice());var h=r.tooltip;return h&&h.length?o=h.slice():o.length||(o=a.slice()),r.defaultedLabel=a,r.defaultedTooltip=o,i.userOutput=new Mh(u,n),i}(this,this._schema),this.userOutput=this._dimSummary.userOutput},t.prototype.appendData=function(t){var n=this._store.appendData(t);this._doInit(n[0],n[1])},t.prototype.appendValues=function(t,n){var i=this._store.appendValues(t,n&&n.length),r=i.start,e=i.end,a=this._shouldMakeIdFromName();if(this._updateOrdinalMeta(),n)for(var o=r;o<e;o++)this._nameList[o]=n[o-r],a&&Jh(this,o)},t.prototype._updateOrdinalMeta=function(){for(var t=this._store,n=this.dimensions,i=0;i<n.length;i++){var r=this._dimInfos[n[i]];r.ordinalMeta&&t.collectOrdinalMeta(r.storeDimIndex,r.ordinalMeta)}},t.prototype._shouldMakeIdFromName=function(){var t=this._store.getProvider();return null==this._idDimIdx&&t.getSource().sourceFormat!==du&&!t.fillStorage},t.prototype._doInit=function(t,n){if(!(t>=n)){var i=this._store.getProvider();this._updateOrdinalMeta();var r=this._nameList,e=this._idList;if(i.getSource().sourceFormat===fu&&!i.pure)for(var a=[],o=t;o<n;o++){var u=i.getItem(o,a);if(!this.hasItemOption&&Io(u)&&(this.hasItemOption=!0),u){var s=u.name;null==r[o]&&null!=s&&(r[o]=_o(s,null));var l=u.id;null==e[o]&&null!=l&&(e[o]=_o(l,null))}}if(this._shouldMakeIdFromName())for(o=t;o<n;o++)Jh(this,o);$h(this)}},t.prototype.getApproximateExtent=function(t,n){return this._approximateExtent[t]||this._store.getDataExtent(this._getStoreDimIndex(t),n)},t.prototype.setApproximateExtent=function(t,n){n=this.getDimension(n),this._approximateExtent[n]=t.slice()},t.prototype.getCalculationInfo=function(t){return this._calculationInfo[t]},t.prototype.setCalculationInfo=function(t,n){Kh(t)?P(this._calculationInfo,t):this._calculationInfo[t]=n},t.prototype.getName=function(t){var n=this.getRawIndex(t),i=this._nameList[n];return null==i&&null!=this._nameDimIdx&&(i=Xh(this,this._nameDimIdx,n)),null==i&&(i=""),i},t.prototype._getCategory=function(t,n){var i=this._store.get(t,n),r=this._store.getOrdinalMeta(t);return r?r.categories[i]:i},t.prototype.getId=function(t){return Yh(this,this.getRawIndex(t))},t.prototype.count=function(){return this._store.count()},t.prototype.get=function(t,n){var i=this._dimInfos[t];if(i)return this._store.get(i.storeDimIndex,n)},t.prototype.getByRawIndex=function(t,n){var i=this._dimInfos[t];if(i)return this._store.getByRawIndex(i.storeDimIndex,n)},t.prototype.getIndices=function(){return this._store.getIndices()},t.prototype.getDataExtent=function(t){return this._store.getDataExtent(this._getStoreDimIndex(t),null)},t.prototype.getSum=function(t){return this._store.getSum(this._getStoreDimIndex(t))},t.prototype.getMedian=function(t){return this._store.getMedian(this._getStoreDimIndex(t))},t.prototype.getValues=function(t,n){var i=this,r=this._store;return G(t)?r.getValues(Qh(t,(function(t){return i._getStoreDimIndex(t)})),n):r.getValues(t)},t.prototype.hasValue=function(t){for(var n=this._dimSummary.dataDimIndicesOnCoord,i=0,r=n.length;i<r;i++)if(isNaN(this._store.get(n[i],t)))return!1;return!0},t.prototype.indexOfName=function(t){for(var n=0,i=this._store.count();n<i;n++)if(this.getName(n)===t)return n;return-1},t.prototype.getRawIndex=function(t){return this._store.getRawIndex(t)},t.prototype.indexOfRawIndex=function(t){return this._store.indexOfRawIndex(t)},t.prototype.rawIndexOf=function(t,n){var i=t&&this._invertedIndicesMap[t],r=i&&i[n];return null==r||isNaN(r)?-1:r},t.prototype.each=function(t,n,i){Z(t)&&(i=n,n=t,t=[]);var r=i||this,e=Qh(qh(t),this._getStoreDimIndex,this);this._store.each(e,r?X(n,r):n)},t.prototype.filterSelf=function(t,n,i){Z(t)&&(i=n,n=t,t=[]);var r=i||this,e=Qh(qh(t),this._getStoreDimIndex,this);return this._store=this._store.filter(e,r?X(n,r):n),this},t.prototype.selectRange=function(t){var n=this,i={};return H(Y(t),(function(r){var e=n._getStoreDimIndex(r);i[e]=t[r]})),this._store=this._store.selectRange(i),this},t.prototype.mapArray=function(t,n,i){Z(t)&&(i=n,n=t,t=[]);var r=[];return this.each(t,(function(){r.push(n&&n.apply(this,arguments))}),i=i||this),r},t.prototype.map=function(t,n,i,r){var e=i||r||this,a=Qh(qh(t),this._getStoreDimIndex,this),o=Zh(this);return o._store=this._store.map(a,e?X(n,e):n),o},t.prototype.modify=function(t,n,i,r){var e=i||r||this,a=Qh(qh(t),this._getStoreDimIndex,this);this._store.modify(a,e?X(n,e):n)},t.prototype.downSample=function(t,n,i,r){var e=Zh(this);return e._store=this._store.downSample(this._getStoreDimIndex(t),n,i,r),e},t.prototype.minmaxDownSample=function(t,n){var i=Zh(this);return i._store=this._store.minmaxDownSample(this._getStoreDimIndex(t),n),i},t.prototype.lttbDownSample=function(t,n){var i=Zh(this);return i._store=this._store.lttbDownSample(this._getStoreDimIndex(t),n),i},t.prototype.getRawDataItem=function(t){return this._store.getRawDataItem(t)},t.prototype.getItemModel=function(t){var n=this.hostModel,i=this.getRawDataItem(t);return new Wf(i,n,n&&n.ecModel)},t.prototype.diff=function(t){var n=this;return new Uf(t?t.getStore().getIndices():[],this.getStore().getIndices(),(function(n){return Yh(t,n)}),(function(t){return Yh(n,t)}))},t.prototype.getVisual=function(t){var n=this._visual;return n&&n[t]},t.prototype.setVisual=function(t,n){this._visual=this._visual||{},Kh(t)?P(this._visual,t):this._visual[t]=n},t.prototype.getItemVisual=function(t,n){var i=this._itemVisuals[t],r=i&&i[n];return null==r?this.getVisual(n):r},t.prototype.hasItemVisual=function(){return this._itemVisuals.length>0},t.prototype.ensureUniqueItemVisual=function(t,n){var i=this._itemVisuals,r=i[t];r||(r=i[t]={});var e=r[n];return null==e&&(G(e=this.getVisual(n))?e=e.slice():Kh(e)&&(e=P({},e)),r[n]=e),e},t.prototype.setItemVisual=function(t,n,i){var r=this._itemVisuals[t]||{};this._itemVisuals[t]=r,Kh(n)?P(r,n):r[n]=i},t.prototype.clearAllVisual=function(){this._visual={},this._itemVisuals=[]},t.prototype.setLayout=function(t,n){Kh(t)?P(this._layout,t):this._layout[t]=n},t.prototype.getLayout=function(t){return this._layout[t]},t.prototype.getItemLayout=function(t){return this._itemLayouts[t]},t.prototype.setItemLayout=function(t,n,i){this._itemLayouts[t]=i?P(this._itemLayouts[t]||{},n):n},t.prototype.clearItemLayouts=function(){this._itemLayouts.length=0},t.prototype.setItemGraphicEl=function(t,n){ou(this.hostModel&&this.hostModel.seriesIndex,this.dataType,t,n),this._graphicEls[t]=n},t.prototype.getItemGraphicEl=function(t){return this._graphicEls[t]},t.prototype.eachItemGraphicEl=function(t,n){H(this._graphicEls,(function(i,r){i&&t&&t.call(n,i,r)}))},t.prototype.cloneShallow=function(n){return n||(n=new t(this._schema?this._schema:Qh(this.dimensions,this._getDimInfo,this),this.hostModel)),Gh(n,this),n._store=this._store,n},t.prototype.wrapMethod=function(t,n){var i=this[t];Z(i)&&(this.__wrappedMethods=this.__wrappedMethods||[],this.__wrappedMethods.push(t),this[t]=function(){var t=i.apply(this,arguments);return n.apply(this,[t].concat(lt(arguments)))})},t.internalField=($h=function(t){var n=t._invertedIndicesMap;H(n,(function(i,r){var e=t._dimInfos[r],a=e.ordinalMeta,o=t._store;if(a){i=n[r]=new tc(a.categories.length);for(var u=0;u<i.length;u++)i[u]=-1;for(u=0;u<o.count();u++)i[o.get(e.storeDimIndex,u)]=u}}))},Xh=function(t,n,i){return _o(t._getCategory(n,i),null)},Yh=function(t,n){var i=t._idList[n];return null==i&&null!=t._idDimIdx&&(i=Xh(t,t._idDimIdx,n)),null==i&&(i="e\0\0"+n),i},qh=function(t){return G(t)||(t=null!=t?[t]:[]),t},Zh=function(n){var i=new t(n._schema?n._schema:Qh(n.dimensions,n._getDimInfo,n),n.hostModel);return Gh(i,n),i},Gh=function(t,n){H(nc.concat(n.__wrappedMethods||[]),(function(i){n.hasOwnProperty(i)&&(t[i]=n[i])})),t.__wrappedMethods=n.__wrappedMethods,H(ic,(function(i){t[i]=R(n[i])})),t._calculationInfo=P({},n._calculationInfo)},void(Jh=function(t,n){var i=t._nameList,r=t._idList,e=t._nameDimIdx,a=t._idDimIdx,o=i[n],u=r[n];if(null==o&&null!=e&&(i[n]=o=Xh(t,e,n)),null==u&&null!=a&&(r[n]=u=Xh(t,a,n)),null==u&&null!=o){var s=t._nameRepeatCount,l=s[o]=(s[o]||0)+1;u=o,l>1&&(u+="__ec__"+l),r[n]=u}})),t}();function ec(t,n){rh(t)||(t=ah(t));var i=(n=n||{}).coordDimensions||[],r=n.dimensionsDefine||t.dimensionsDefine||[],e=bt(),a=[],o=function(t,n,i,r){var e=Math.max(t.dimensionsDetectedCount||1,n.length,i.length,r||0);return H(n,(function(t){var n;tt(t)&&(n=t.dimsDef)&&(e=Math.max(e,n.length))})),e}(t,i,r,n.dimensionsCount),u=n.canOmitUnusedDimensions&&Vh(o),s=r===t.dimensionsDefine,l=s?Uh(t):Hh(r),f=n.encodeDefine;!f&&n.encodeDefaulter&&(f=n.encodeDefaulter(t,o));for(var h=bt(f),c=new Dh(o),v=0;v<c.length;v++)c[v]=-1;function d(t){var n=c[t];if(n<0){var i=r[t],e=tt(i)?i:{name:i},o=new Sh,u=e.name;return null!=u&&null!=l.get(u)&&(o.name=o.displayName=u),null!=e.type&&(o.type=e.type),null!=e.displayName&&(o.displayName=e.displayName),c[t]=a.length,o.storeDimIndex=t,a.push(o),o}return a[n]}if(!u)for(v=0;v<o;v++)d(v);h.each((function(t,n){var i=To(t).slice();if(1===i.length&&!J(i[0])&&i[0]<0)h.set(n,!1);else{var r=h.set(n,[]);H(i,(function(t,i){var e=J(t)?l.get(t):t;null!=e&&e<o&&(r[i]=e,m(d(e),n,i))}))}}));var p=0;function m(t,n,i){null!=lu.get(n)?t.otherDims[n]=i:(t.coordDim=n,t.coordDimIndex=i,e.set(n,!0))}H(i,(function(t){var n,i,r,e;if(J(t))n=t,e={};else{n=(e=t).name;var a=e.ordinalMeta;e.ordinalMeta=null,(e=P({},e)).ordinalMeta=a,i=e.dimsDef,r=e.otherDims,e.name=e.coordDim=e.coordDimIndex=e.dimsDef=e.otherDims=null}var u=h.get(n);if(!1!==u){if(!(u=To(u)).length)for(var l=0;l<(i&&i.length||1);l++){for(;p<o&&null!=d(p).coordDim;)p++;p<o&&u.push(p++)}H(u,(function(t,a){var o=d(t);if(s&&null!=e.type&&(o.type=e.type),m(B(o,e),n,a),null==o.name&&i){var u=i[a];!tt(u)&&(u={name:u}),o.name=o.displayName=u.name,o.defaultTooltip=u.defaultTooltip}r&&B(o.otherDims,r)}))}}));var y=n.generateCoord,g=n.generateCoordCount,b=null!=g;g=y?g||1:0;var w=y||"value";function x(t){null==t.name&&(t.name=t.coordDim)}if(u)H(a,(function(t){x(t)})),a.sort((function(t,n){return t.storeDimIndex-n.storeDimIndex}));else for(var M=0;M<o;M++){var k=d(M);null==k.coordDim&&(k.coordDim=ac(w,e,b),k.coordDimIndex=0,(!y||g<=0)&&(k.isExtraCoord=!0),g--),x(k),null!=k.type||1!==qf(t,M)&&(!k.isExtraCoord||null==k.otherDims.itemName&&null==k.otherDims.seriesName)||(k.type="ordinal")}return Ko(a,(function(t){return t.name}),(function(t,n){n>0&&(t.name=t.name+(n-1))})),new Wh({source:t,dimensions:a,fullDimensionCount:o,dimensionOmitted:u})}function ac(t,n,i){if(i||n.hasKey(t)){for(var r=0;n.hasKey(t+r);)r++;t+=r}return n.set(t,!0),t}var oc={},uc={},sc=function(){function t(){this._normalMasterList=[],this._nonSeriesBoxMasterList=[]}return t.prototype.create=function(t,n){function i(i){var r=[];return H(i,(function(i){var e=i.create(t,n);r=r.concat(e||[])})),r}this._nonSeriesBoxMasterList=i(oc),this._normalMasterList=i(uc)},t.prototype.update=function(t,n){H(this._normalMasterList,(function(i){i.update&&i.update(t,n)}))},t.prototype.getCoordinateSystems=function(){return this._normalMasterList.concat(this._nonSeriesBoxMasterList)},t.register=function(t,n){"matrix"!==t&&"calendar"!==t?uc[t]=n:oc[t]=n},t.get=function(t){return uc[t]||oc[t]},t}(),lc=bt();function fc(t){var n=t.getShallow("coord",!0),i=1;if(null==n){var r=lc.get(t.type);r&&r.getCoord2&&(i=2,n=r.getCoord2(t))}return{coord:n,from:i}}var hc=function(t){this.coordSysDims=[],this.axisMap=bt(),this.categoryAxisMap=bt(),this.coordSysName=t},cc={cartesian2d:function(t,n,i,r){var e=t.getReferringComponents("xAxis",jo).models[0],a=t.getReferringComponents("yAxis",jo).models[0];n.coordSysDims=["x","y"],i.set("x",e),i.set("y",a),vc(e)&&(r.set("x",e),n.firstCategoryDimIndex=0),vc(a)&&(r.set("y",a),null==n.firstCategoryDimIndex&&(n.firstCategoryDimIndex=1))},singleAxis:function(t,n,i,r){var e=t.getReferringComponents("singleAxis",jo).models[0];n.coordSysDims=["single"],i.set("single",e),vc(e)&&(r.set("single",e),n.firstCategoryDimIndex=0)},polar:function(t,n,i,r){var e=t.getReferringComponents("polar",jo).models[0],a=e.findAxisModel("radiusAxis"),o=e.findAxisModel("angleAxis");n.coordSysDims=["radius","angle"],i.set("radius",a),i.set("angle",o),vc(a)&&(r.set("radius",a),n.firstCategoryDimIndex=0),vc(o)&&(r.set("angle",o),null==n.firstCategoryDimIndex&&(n.firstCategoryDimIndex=1))},geo:function(t,n){n.coordSysDims=["lng","lat"]},parallel:function(t,n,i,r){var e=t.ecModel,a=e.getComponent("parallel",t.get("parallelIndex")),o=n.coordSysDims=a.dimensions.slice();H(a.parallelAxisIndex,(function(t,a){var u=e.getComponent("parallelAxis",t),s=o[a];i.set(s,u),vc(u)&&(r.set(s,u),null==n.firstCategoryDimIndex&&(n.firstCategoryDimIndex=a))}))},matrix:function(t,n,i,r){var e=t.getReferringComponents("matrix",jo).models[0];n.coordSysDims=["x","y"];var a=e.getDimensionModel("x"),o=e.getDimensionModel("y");i.set("x",a),i.set("y",o),r.set("x",a),r.set("y",o)}};function vc(t){return"category"===t.get("type")}function dc(t,n){return!!n&&n===t.getCalculationInfo("stackedDimension")}function pc(t,n,i){i=i||{};var r,e,a=n.getSourceManager();e=(r=a.getSource()).sourceFormat===fu;var o=function(t){var n=t.get("coordinateSystem"),i=new hc(n),r=cc[n];if(r)return r(t,i,i.axisMap,i.categoryAxisMap),i}(n),u=function(t,n){var i,r=t.get("coordinateSystem"),e=sc.get(r);return n&&n.coordSysDims&&(i=U(n.coordSysDims,(function(t){var i={name:t},r=n.axisMap.get(t);if(r){var e=r.get("type");i.type=function(t){return"category"===t?"ordinal":"time"===t?"time":"float"}(e)}return i}))),i||(i=e&&(e.getDimensionsInfo?e.getDimensionsInfo():e.dimensions.slice())||["x","y"]),i}(n,o),s=i.useEncodeDefaulter,l=Z(s)?s:s?q($f,u,n):null,f=ec(r,{coordDimensions:u,generateCoord:i.generateCoord,encodeDefine:n.getEncode(),encodeDefaulter:l,canOmitUnusedDimensions:!e}),h=function(t,n,i){var r,e;return i&&H(t,(function(t,a){var o=i.categoryAxisMap.get(t.coordDim);o&&(null==r&&(r=a),t.ordinalMeta=o.getOrdinalMeta(),n&&(t.createInvertedIndices=!0)),null!=t.otherDims.itemName&&(e=!0)})),e||null==r||(t[r].otherDims.itemName=0),r}(f.dimensions,i.createInvertedIndices,o),c=e?null:a.getSharedDataStore(f),v=function(t,n,i){var r,e,a,o=(i=i||{}).byIndex,u=i.stackedCoordDimension;!function(t){return!jh(t.schema)}(n)?(r=(e=n.schema).dimensions,a=n.store):r=n;var s,l,f,h,c=!(!t||!t.get("stack")),v=!0;function d(t){return"ordinal"!==t.type&&"time"!==t.type}if(H(r,(function(t,n){J(t)&&(r[n]=t={name:t}),d(t)||(v=!1)})),H(r,(function(t){c&&!t.isExtraCoord&&(o||s||!t.ordinalMeta||(s=t),l||!d(t)||v&&("x"===t.coordDim||"angle"===t.coordDim)||u&&u!==t.coordDim||(l=t))})),!l||o||s||(o=!0),l){f="__\0ecstackresult_"+t.id,h="__\0ecstackedover_"+t.id,s&&(s.createInvertedIndices=!0);var p=l.coordDim,m=l.type,y=0;H(r,(function(t){t.coordDim===p&&y++}));var g={name:f,coordDim:p,coordDimIndex:y,type:m,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:r.length},b={name:h,coordDim:h,coordDimIndex:y+1,type:m,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:r.length+1};e?(a&&(g.storeDimIndex=a.ensureCalculationDimension(h,m),b.storeDimIndex=a.ensureCalculationDimension(f,m)),e.appendCalculationDimension(g),e.appendCalculationDimension(b)):(r.push(g),r.push(b))}return{stackedDimension:l&&l.name,stackedByDimension:s&&s.name,isStackedByIndex:o,stackedOverDimension:h,stackResultDimension:f}}(n,{schema:f,store:c}),d=new rc(f,n);d.setCalculationInfo(v);var p=null!=h&&function(t){if(t.sourceFormat===fu)return!G(Oo(function(t){for(var n=0;n<t.length&&null==t[n];)n++;return t[n]}(t.data||[])))}(r)?function(t,n,i,r){return r===h?i:this.defaultDimValueGetter(t,n,i,r)}:null;return d.hasItemOption=!1,d.initData(e?r:c,null,p),d}var mc=Math.round(10*Math.random());function yc(t){return[t||"",mc++].join("_")}var gc=Math.log(2);function bc(t,n,i,r,e,a){var o=r+"-"+e,u=t.length;if(a.hasOwnProperty(o))return a[o];if(1===n){var s=Math.round(Math.log((1<<u)-1&~e)/gc);return t[i][s]}for(var l=r|1<<i,f=i+1;r&1<<f;)f++;for(var h=0,c=0,v=0;c<u;c++){var d=1<<c;d&e||(h+=(v%2?-1:1)*t[i][c]*bc(t,n-1,f,l,e|d,a),v++)}return a[o]=h,h}function wc(t,n){var i=[[t[0],t[1],1,0,0,0,-n[0]*t[0],-n[0]*t[1]],[0,0,0,t[0],t[1],1,-n[1]*t[0],-n[1]*t[1]],[t[2],t[3],1,0,0,0,-n[2]*t[2],-n[2]*t[3]],[0,0,0,t[2],t[3],1,-n[3]*t[2],-n[3]*t[3]],[t[4],t[5],1,0,0,0,-n[4]*t[4],-n[4]*t[5]],[0,0,0,t[4],t[5],1,-n[5]*t[4],-n[5]*t[5]],[t[6],t[7],1,0,0,0,-n[6]*t[6],-n[6]*t[7]],[0,0,0,t[6],t[7],1,-n[7]*t[6],-n[7]*t[7]]],r={},e=bc(i,8,0,0,0,r);if(0!==e){for(var a=[],o=0;o<8;o++)for(var u=0;u<8;u++)null==a[u]&&(a[u]=0),a[u]+=((o+u)%2?-1:1)*bc(i,7,0===o?1:0,1<<o,1<<u,r)/e*n[o];return function(t,n,i){var r=n*a[6]+i*a[7]+1;t[0]=(n*a[0]+i*a[1]+a[2])/r,t[1]=(n*a[3]+i*a[4]+a[5])/r}}}var xc="___zrEVENTSAVED",Mc=[];function kc(t,n,i,r,e){if(n.getBoundingClientRect&&At.domSupported&&!Sc(n)){var a=n[xc]||(n[xc]={}),o=function(t,n){var i=n.markers;if(i)return i;i=n.markers=[];for(var r=["left","right"],e=["top","bottom"],a=0;a<4;a++){var o=document.createElement("div"),u=a%2,s=(a>>1)%2;o.style.cssText=["position: absolute","visibility: hidden","padding: 0","margin: 0","border-width: 0","user-select: none","width:0","height:0",r[u]+":0",e[s]+":0",r[1-u]+":auto",e[1-s]+":auto",""].join("!important;"),t.appendChild(o),i.push(o)}return n.clearMarkers=function(){H(i,(function(t){t.parentNode&&t.parentNode.removeChild(t)}))},i}(n,a),u=function(t,n,i){for(var r=i?"invTrans":"trans",e=n[r],a=n.srcCoords,o=[],u=[],s=!0,l=0;l<4;l++){var f=t[l].getBoundingClientRect(),h=2*l,c=f.left,v=f.top;o.push(c,v),s=s&&a&&c===a[h]&&v===a[h+1],u.push(t[l].offsetLeft,t[l].offsetTop)}return s&&e?e:(n.srcCoords=o,n[r]=i?wc(u,o):wc(o,u))}(o,a,e);if(u)return u(t,i,r),!0}return!1}function Sc(t){return"CANVAS"===t.nodeName.toUpperCase()}var Ac=/([&<>"'])/g,Tc={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"};function Nc(t){return null==t?"":(t+"").replace(Ac,(function(t,n){return Tc[n]}))}var Cc="ZH",Oc="EN",Ic=Oc,Lc={},Dc={},_c=At.domSupported&&(document.documentElement.lang||navigator.language||navigator.browserLanguage||Ic).toUpperCase().indexOf(Cc)>-1?Cc:Ic;function zc(t,n){t=t.toUpperCase(),Dc[t]=new Wf(n),Lc[t]=n}function Rc(t,n){var i=n.breakParsed;return i}function Fc(t){var n=t.brk;return n?n.breaks:[]}function Pc(t){var n=t.brk;return!!n&&n.hasBreaks()}zc(Oc,{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:". "}}}}),zc(Cc,{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 Bc=36e5,Ec=864e5,Wc=31536e6,jc={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})/},Hc={year:"{yyyy}",month:"{MMM}",day:"{d}",hour:"{HH}:{mm}",minute:"{HH}:{mm}",second:"{HH}:{mm}:{ss}",millisecond:"{HH}:{mm}:{ss} {SSS}"},Uc="{yyyy}-{MM}-{dd}",Vc={year:"{yyyy}",month:"{yyyy}-{MM}",day:Uc,hour:Uc+" "+Hc.hour,minute:Uc+" "+Hc.minute,second:Uc+" "+Hc.second,millisecond:"{yyyy}-{MM}-{dd} {HH}:{mm}:{ss} {SSS}"},$c=["year","month","day","hour","minute","second","millisecond"],Yc=["year","half-year","quarter","month","week","half-week","day","half-day","quarter-day","hour","minute","second","millisecond"];function Xc(t,n){return"0000".substr(0,n-(t+="").length)+t}function qc(t){switch(t){case"half-year":case"quarter":return"month";case"week":case"half-week":return"day";case"half-day":case"quarter-day":return"hour";default:return t}}function Gc(t,n,i,r){var e=ho(t),a=e[Kc(i)](),o=e[Qc(i)]()+1,u=Math.floor((o-1)/3)+1,s=e[tv(i)](),l=e["get"+(i?"UTC":"")+"Day"](),f=e[nv(i)](),h=(f-1)%12+1,c=e[iv(i)](),v=e[rv(i)](),d=e[ev(i)](),p=f>=12?"pm":"am",m=p.toUpperCase(),y=r instanceof Wf?r:function(t){return Dc[t]}(r||_c)||Dc[Ic],g=y.getModel("time"),b=g.get("month"),w=g.get("monthAbbr"),x=g.get("dayOfWeek"),M=g.get("dayOfWeekAbbr");return(n||"").replace(/{a}/g,p+"").replace(/{A}/g,m+"").replace(/{yyyy}/g,a+"").replace(/{yy}/g,Xc(a%100+"",2)).replace(/{Q}/g,u+"").replace(/{MMMM}/g,b[o-1]).replace(/{MMM}/g,w[o-1]).replace(/{MM}/g,Xc(o,2)).replace(/{M}/g,o+"").replace(/{dd}/g,Xc(s,2)).replace(/{d}/g,s+"").replace(/{eeee}/g,x[l]).replace(/{ee}/g,M[l]).replace(/{e}/g,l+"").replace(/{HH}/g,Xc(f,2)).replace(/{H}/g,f+"").replace(/{hh}/g,Xc(h+"",2)).replace(/{h}/g,h+"").replace(/{mm}/g,Xc(c,2)).replace(/{m}/g,c+"").replace(/{ss}/g,Xc(v,2)).replace(/{s}/g,v+"").replace(/{SSS}/g,Xc(d,3)).replace(/{S}/g,d+"")}function Zc(t,n){var i=ho(t),r=i[Qc(n)]()+1,e=i[tv(n)](),a=i[nv(n)](),o=i[iv(n)](),u=i[rv(n)](),s=0===i[ev(n)](),l=s&&0===u,f=l&&0===o,h=f&&0===a,c=h&&1===e;return c&&1===r?"year":c?"month":h?"day":f?"hour":l?"minute":s?"second":"millisecond"}function Jc(t,n,i){switch(n){case"year":t[ov(i)](0);case"month":t[uv(i)](1);case"day":t[sv(i)](0);case"hour":t[lv(i)](0);case"minute":t[fv(i)](0);case"second":t[hv(i)](0)}return t}function Kc(t){return t?"getUTCFullYear":"getFullYear"}function Qc(t){return t?"getUTCMonth":"getMonth"}function tv(t){return t?"getUTCDate":"getDate"}function nv(t){return t?"getUTCHours":"getHours"}function iv(t){return t?"getUTCMinutes":"getMinutes"}function rv(t){return t?"getUTCSeconds":"getSeconds"}function ev(t){return t?"getUTCMilliseconds":"getMilliseconds"}function av(t){return t?"setUTCFullYear":"setFullYear"}function ov(t){return t?"setUTCMonth":"setMonth"}function uv(t){return t?"setUTCDate":"setDate"}function sv(t){return t?"setUTCHours":"setHours"}function lv(t){return t?"setUTCMinutes":"setMinutes"}function fv(t){return t?"setUTCSeconds":"setSeconds"}function hv(t){return t?"setUTCMilliseconds":"setMilliseconds"}function cv(t){if(isNaN(mo(t)))return J(t)?t:"-";var n=(t+"").split(".");return n[0].replace(/(\d{1,3})(?=(?:\d{3})+(?!\d))/g,"$1,")+(n.length>1?"."+n[1]:"")}function vv(t,n){return t=(t||"").toLowerCase().replace(/-(.)/g,(function(t,n){return n.toUpperCase()})),n&&t&&(t=t.charAt(0).toUpperCase()+t.slice(1)),t}var dv=ft;function pv(t,n,i){function r(t){return t&&ct(t)?t:"-"}function e(t){return wo(t)}var a="time"===n,o=t instanceof Date;if(a||o){var u=a?ho(t):t;if(!isNaN(+u))return Gc(u,"{yyyy}-{MM}-{dd} {HH}:{mm}:{ss}",i);if(o)return"-"}if("ordinal"===n)return K(t)?r(t):Q(t)&&e(t)?t+"":"-";var s=mo(t);return e(s)?cv(s):K(t)?r(t):"boolean"==typeof t?t+"":"-"}var mv=["a","b","c","d","e","f","g"],yv=function(t,n){return"{"+t+(null==n?"":n)+"}"};function gv(t,n,i){G(n)||(n=[n]);var r=n.length;if(!r)return"";for(var e=n[0].$vars||[],a=0;a<e.length;a++){var o=mv[a];t=t.replace(yv(o),yv(o,0))}for(var u=0;u<r;u++)for(var s=0;s<e.length;s++){var l=n[u][e[s]];t=t.replace(yv(mv[s],u),i?Nc(l):l)}return t}function bv(t,n){return n=n||"transparent",J(t)?t:tt(t)&&t.colorStops&&(t.colorStops[0]||{}).color||n}var wv=H,xv=["left","right","top","bottom","width","height"],Mv=[["width","left","right"],["height","top","bottom"]];function kv(t,n,i,r,e){var a=0,o=0;null==r&&(r=1/0),null==e&&(e=1/0);var u=0;n.eachChild((function(s,l){var f,h,c=s.getBoundingRect(),v=n.childAt(l+1),d=v&&v.getBoundingRect();if("horizontal"===t){var p=c.width+(d?-d.x+c.x:0);(f=a+p)>r||s.newline?(a=0,f=p,o+=u+i,u=c.height):u=Math.max(u,c.height)}else{var m=c.height+(d?-d.y+c.y:0);(h=o+m)>e||s.newline?(a+=u+i,o=0,h=m,u=c.width):u=Math.max(u,c.width)}s.newline||(s.x=a,s.y=o,s.markRedraw(),"horizontal"===t?a=f+i:o=h+i)}))}function Sv(t,n,i){i=dv(i||0);var r=n.width,e=n.height,a=no(t.left,r),o=no(t.top,e),u=no(t.right,r),s=no(t.bottom,e),l=no(t.width,r),f=no(t.height,e),h=i[2]+i[0],c=i[1]+i[3],v=t.aspect;switch(isNaN(l)&&(l=r-u-c-a),isNaN(f)&&(f=e-s-h-o),null!=v&&(isNaN(l)&&isNaN(f)&&(v>r/e?l=.8*r:f=.8*e),isNaN(l)&&(l=v*f),isNaN(f)&&(f=l/v)),isNaN(a)&&(a=r-u-l-c),isNaN(o)&&(o=e-s-f-h),t.left||t.right){case"center":a=r/2-l/2-i[3];break;case"right":a=r-l-c}switch(t.top||t.bottom){case"middle":case"center":o=e/2-f/2-i[0];break;case"bottom":o=e-f-h}a=a||0,o=o||0,isNaN(l)&&(l=r-c-a-(u||0)),isNaN(f)&&(f=e-h-o-(s||0));var d=new On((n.x||0)+a+i[3],(n.y||0)+o+i[0],l,f);return d.margin=i,d}q(kv,"vertical"),q(kv,"horizontal");var Av={rect:1,point:2};function Tv(t,n,i){var r,e,a,o,u=t.boxCoordinateSystem;if(u){var s=fc(t),l=s.coord,f=s.from;if(u.dataToLayout){a=Av.rect,o=f;var h=u.dataToLayout(l);r=h.contentRect||h.rect}else i&&i.enableLayoutOnlyByCenter&&u.dataToPoint&&(a=Av.point,o=f,e=u.dataToPoint(l))}return null==a&&(a=Av.rect),a===Av.rect&&(r||(r={x:0,y:0,width:n.getWidth(),height:n.getHeight()}),e=[r.x+r.width/2,r.y+r.height/2]),{type:a,refContainer:r,refPoint:e,boxCoordFrom:o}}function Nv(t){var n=t.layoutMode||t.constructor.layoutMode;return tt(n)?n:n?{type:n}:null}function Cv(t,n,i){var r=i&&i.ignoreSize;!G(r)&&(r=[r,r]);var e=o(Mv[0],0),a=o(Mv[1],1);function o(i,e){var a={},o=0,s={},l=0;if(wv(i,(function(n){s[n]=t[n]})),wv(i,(function(t){xt(n,t)&&(a[t]=s[t]=n[t]),u(a,t)&&o++,u(s,t)&&l++})),r[e])return u(n,i[1])?s[i[2]]=null:u(n,i[2])&&(s[i[1]]=null),s;if(2!==l&&o){if(o>=2)return a;for(var f=0;f<i.length;f++){var h=i[f];if(!xt(a,h)&&xt(t,h)){a[h]=t[h];break}}return a}return s}function u(t,n){return null!=t[n]&&"auto"!==t[n]}function s(t,n,i){wv(t,(function(t){n[t]=i[t]}))}s(Mv[0],t,e),s(Mv[1],t,a)}function Ov(t){return function(t,n){return n&&t&&wv(xv,(function(i){xt(n,i)&&(t[i]=n[i])})),t}({},t)}var Iv=Po(),Lv=function(t){function n(n,i,r){var e=t.call(this,n,i,r)||this;return e.uid=yc("ec_cpt_model"),e}var i;return v(n,t),n.prototype.init=function(t,n,i){this.mergeDefaultAndTheme(t,i)},n.prototype.mergeDefaultAndTheme=function(t,n){var i=Nv(this),r=i?Ov(t):{};F(t,n.getTheme().get(this.mainType)),F(t,this.getDefaultOption()),i&&Cv(t,r,i)},n.prototype.mergeOption=function(t){F(this.option,t,!0);var n=Nv(this);n&&Cv(this.option,t,n)},n.prototype.optionUpdated=function(){},n.prototype.getDefaultOption=function(){var t=this.constructor;if(!function(t){return!(!t||!t[Nt])}(t))return t.defaultOption;var n=Iv(this);if(!n.defaultOption){for(var i=[],r=t;r;){var e=r.prototype.defaultOption;e&&i.push(e),r=r.superClass}for(var a={},o=i.length-1;o>=0;o--)a=F(a,i[o],!0);n.defaultOption=a}return n.defaultOption},n.prototype.getReferringComponents=function(t,n){var i=t+"Id";return Ho(this.ecModel,t,{index:this.get(t+"Index",!0),id:this.get(i,!0)},n)},n.prototype.getBoxLayoutParams=function(){return{left:(t=this).getShallow("left",n=!1),top:t.getShallow("top",n),right:t.getShallow("right",n),bottom:t.getShallow("bottom",n),width:t.getShallow("width",n),height:t.getShallow("height",n)};var t,n},n.prototype.getZLevelKey=function(){return""},n.prototype.setZLevel=function(t){this.option.zlevel=t},n.protoInitialize=((i=n.prototype).type="component",i.id="",i.name="",i.mainType="",i.subType="",void(i.componentIndex=0)),n}(Wf);It(Lv,Wf),zt(Lv),function(t){var n={};t.registerSubTypeDefaulter=function(t,i){var r=Ct(t);n[r.main]=i},t.determineSubType=function(i,r){var e=r.type;if(!e){var a=Ct(i).main;t.hasSubTypes(i)&&n[a]&&(e=n[a](r))}return e}}(Lv),function(){function t(t,n){return t[n]||(t[n]={predecessor:[],successor:[]}),t[n]}Lv.topologicalTravel=function(n,i,r,e){if(n.length){var a=function(n){var i={},r=[];return H(n,(function(e){var a,o,u=t(i,e),s=function(t,n){var i=[];return H(t,(function(t){E(n,t)>=0&&i.push(t)})),i}(u.originalDeps=(o=[],H(Lv.getClassesByMainType(a=e),(function(t){o=o.concat(t.dependencies||t.prototype.dependencies||[])})),o=U(o,(function(t){return Ct(t).main})),"dataset"!==a&&E(o,"dataset")<=0&&o.unshift("dataset"),o),n);u.entryCount=s.length,0===u.entryCount&&r.push(e),H(s,(function(n){E(u.predecessor,n)<0&&u.predecessor.push(n);var r=t(i,n);E(r.successor,n)<0&&r.successor.push(e)}))})),{graph:i,noEntryList:r}}(i),o=a.graph,u=a.noEntryList,s={};for(H(n,(function(t){s[t]=!0}));u.length;){var l=u.pop(),f=o[l],h=!!s[l];h&&(r.call(e,l,f.originalDeps.slice()),delete s[l]),H(f.successor,h?v:c)}H(s,(function(){throw new Error("")}))}function c(t){o[t].entryCount--,0===o[t].entryCount&&u.push(t)}function v(t){s[t]=!0,c(t)}}}();var Dv=Po();Po();var _v=function(){function t(){}return t.prototype.getColorFromPalette=function(t,n,i){return function(t,n,i,r,e,a,o){var u=Dv(a=a||t),s=u.paletteIdx||0,l=u.paletteNameMap=u.paletteNameMap||{};if(l.hasOwnProperty(e))return l[e];var f=null!=o&&r?function(t,n){for(var i=t.length,r=0;r<i;r++)if(t[r].length>n)return t[r];return t[i-1]}(r,o):i;if((f=f||i)&&f.length){var h=f[s];return e&&(l[e]=h),u.paletteIdx=(s+1)%f.length,h}}(this,0,To(this.get("color",!0)),this.get("colorLayer",!0),t,n,i)},t.prototype.clearColorPalette=function(){!function(t,n){n(t).paletteIdx=0,n(t).paletteNameMap={}}(this,Dv)},t}(),zv=/\{@(.+?)\}/g,Rv=function(){function t(){}return t.prototype.getDataParams=function(t,n){var i=this.getData(n),r=this.getRawValue(t,n),e=i.getRawIndex(t),a=i.getName(t),o=i.getRawDataItem(t),u=i.getItemVisual(t,"style"),s=u&&u[i.getItemVisual(t,"drawType")||"fill"],l=u&&u.stroke,f=this.mainType,h="series"===f,c=i.userOutput&&i.userOutput.get();return{componentType:f,componentSubType:this.subType,componentIndex:this.componentIndex,seriesType:h?this.subType:null,seriesIndex:this.seriesIndex,seriesId:h?this.id:null,seriesName:h?this.name:null,name:a,dataIndex:e,data:o,dataType:n,value:r,color:s,borderColor:l,dimensionNames:c?c.fullDimensions:null,encode:c?c.encode:null,$vars:["seriesName","name","value"]}},t.prototype.getFormattedLabel=function(t,n,i,r,e,a){n=n||"normal";var o=this.getData(i),u=this.getDataParams(t,i);return a&&(u.value=a.interpolatedValue),null!=r&&G(u.value)&&(u.value=u.value[r]),e||(e=o.getItemModel(t).get("normal"===n?["label","formatter"]:[n,"label","formatter"])),Z(e)?(u.status=n,u.dimensionIndex=r,e(u)):J(e)?gv(e,u).replace(zv,(function(n,i){var r=i.length,e=i;"["===e.charAt(0)&&"]"===e.charAt(r-1)&&(e=+e.slice(1,r-1));var u=xh(o,t,e);if(a&&G(a.interpolatedValue)){var s=o.getDimensionIndex(e);s>=0&&(u=a.interpolatedValue[s])}return null!=u?u+"":""})):void 0},t.prototype.getRawValue=function(t,n){return xh(this.getData(n),t)},t.prototype.formatTooltip=function(){},t}();function Fv(t){var n,i;return tt(t)?t.type&&(i=t):n=t,{text:n,frag:i}}function Pv(t){return new Bv(t)}var Bv=function(){function t(t){this._reset=(t=t||{}).reset,this._plan=t.plan,this._count=t.count,this._onDirty=t.onDirty,this._dirty=!0}return t.prototype.perform=function(t){var n,i=this._upstream,r=t&&t.skip;if(this._dirty&&i){var e=this.context;e.data=e.outputData=i.context.outputData}this.__pipeline&&(this.__pipeline.currentTask=this),this._plan&&!r&&(n=this._plan(this.context));var a,o=f(this._modBy),u=this._modDataCount||0,s=f(t&&t.modBy),l=t&&t.modDataCount||0;function f(t){return!(t>=1)&&(t=1),t}o===s&&u===l||(n="reset"),(this._dirty||"reset"===n)&&(this._dirty=!1,a=this._doReset(r)),this._modBy=s,this._modDataCount=l;var h=t&&t.step;if(this._dueEnd=i?i._outputDueEnd:this._count?this._count(this.context):1/0,this._progress){var c=this._dueIndex,v=Math.min(null!=h?this._dueIndex+h:1/0,this._dueEnd);if(!r&&(a||c<v)){var d=this._progress;if(G(d))for(var p=0;p<d.length;p++)this._doProgress(d[p],c,v,s,l);else this._doProgress(d,c,v,s,l)}this._dueIndex=v,this._outputDueEnd=null!=this._settedOutputEnd?this._settedOutputEnd:v}else this._dueIndex=this._outputDueEnd=null!=this._settedOutputEnd?this._settedOutputEnd:this._dueEnd;return this.unfinished()},t.prototype.dirty=function(){this._dirty=!0,this._onDirty&&this._onDirty(this.context)},t.prototype._doProgress=function(t,n,i,r,e){Ev.reset(n,i,r,e),this._callingProgress=t,this._callingProgress({start:n,end:i,count:i-n,next:Ev.next},this.context)},t.prototype._doReset=function(t){var n,i;this._dueIndex=this._outputDueEnd=this._dueEnd=0,this._settedOutputEnd=null,!t&&this._reset&&((n=this._reset(this.context))&&n.progress&&(i=n.forceFirstProgress,n=n.progress),G(n)&&!n.length&&(n=null)),this._progress=n,this._modBy=this._modDataCount=null;var r=this._downstream;return r&&r.dirty(),i},t.prototype.unfinished=function(){return this._progress&&this._dueIndex<this._dueEnd},t.prototype.pipe=function(t){(this._downstream!==t||this._dirty)&&(this._downstream=t,t._upstream=this,t.dirty())},t.prototype.dispose=function(){this._disposed||(this._upstream&&(this._upstream._downstream=null),this._downstream&&(this._downstream._upstream=null),this._dirty=!1,this._disposed=!0)},t.prototype.getUpstream=function(){return this._upstream},t.prototype.getDownstream=function(){return this._downstream},t.prototype.setOutputEnd=function(t){this._outputDueEnd=this._settedOutputEnd=t},t}(),Ev=function(){var t,n,i,r,e,a={reset:function(s,l,f,h){n=s,t=l,i=f,r=h,e=Math.ceil(r/i),a.next=i>1&&r>0?u:o}};return a;function o(){return n<t?n++:null}function u(){var a=n%e*i+Math.ceil(n/e),o=n>=t?null:a<r?a:n;return n++,o}}(),Wv=function(){function t(){}return t.prototype.getRawData=function(){throw new Error("not supported")},t.prototype.getRawDataItem=function(){throw new Error("not supported")},t.prototype.cloneRawData=function(){},t.prototype.getDimensionInfo=function(){},t.prototype.cloneAllDimensionInfo=function(){},t.prototype.count=function(){},t.prototype.retrieveValue=function(){},t.prototype.retrieveValueFromItem=function(){},t.prototype.convertValue=function(t,n){return Ah(t,n)},t}();function jv(t){return Xv(t.sourceFormat)||ko(""),t.data}function Hv(t){var n=t.sourceFormat,i=t.data;if(Xv(n)||ko(""),n===hu){for(var r=[],e=0,a=i.length;e<a;e++)r.push(i[e].slice());return r}if(n===cu){for(r=[],e=0,a=i.length;e<a;e++)r.push(P({},i[e]));return r}}function Uv(t,n,i){if(null!=i)return Q(i)||!isNaN(i)&&!xt(n,i)?t[i]:xt(n,i)?n[i]:void 0}function Vv(t){return R(t)}var $v=bt();function Yv(t,n){n.length||ko(""),tt(t)||ko("");var i=$v.get(t.type);i||ko("");var r=U(n,(function(t){return function(t,n){var i=new Wv,r=t.data,e=i.sourceFormat=t.sourceFormat,a=t.startIndex;t.seriesLayoutBy!==mu&&ko("");var o=[],u={},s=t.dimensionsDefine;if(s)H(s,(function(t,n){var i=t.name,r={index:n,name:i,displayName:t.displayName};o.push(r),null!=i&&(xt(u,i)&&ko(""),u[i]=r)}));else for(var l=0;l<t.dimensionsDetectedCount;l++)o.push({index:l});var f=vh(e,mu);n.__isBuiltIn&&(i.getRawDataItem=function(t){return f(r,a,o,t)},i.getRawData=X(jv,null,t)),i.cloneRawData=X(Hv,null,t);var h=mh(e,mu);i.count=X(h,null,r,a,o);var c=bh(e);i.retrieveValue=function(t,n){var i=f(r,a,o,t);return v(i,n)};var v=i.retrieveValueFromItem=function(t,n){if(null!=t){var i=o[n];return i?c(t,n,i.name):void 0}};return i.getDimensionInfo=X(Uv,null,o,u),i.cloneAllDimensionInfo=X(Vv,null,o),i}(t,i)}));return U(To(i.transform({upstream:r[0],upstreamList:r,config:R(t.config)})),(function(t,i){var r;tt(t)||ko(""),t.data||ko(""),Xv(oh(t.data))||ko("");var e=n[0];if(e&&0===i&&!t.dimensions){var a=e.startIndex;a&&(t.data=e.data.slice(0,a).concat(t.data)),r={seriesLayoutBy:mu,sourceHeader:a,dimensions:e.metaRawOption.dimensions}}else r={seriesLayoutBy:mu,sourceHeader:0,dimensions:t.dimensions};return eh(t.data,r,null)}))}function Xv(t){return t===hu||t===cu}var qv=function(){function t(t){this._sourceList=[],this._storeList=[],this._upstreamSignList=[],this._versionSignBase=0,this._dirty=!0,this._sourceHost=t}return t.prototype.dirty=function(){this._setLocalSource([],[]),this._storeList=[],this._dirty=!0},t.prototype._setLocalSource=function(t,n){this._sourceList=t,this._upstreamSignList=n,this._versionSignBase++,this._versionSignBase>9e10&&(this._versionSignBase=0)},t.prototype._getVersionSign=function(){return this._sourceHost.uid+"_"+this._versionSignBase},t.prototype.prepareSource=function(){this._isDirty()&&(this._createSource(),this._dirty=!1)},t.prototype._createSource=function(){this._setLocalSource([],[]);var t,n,i=this._sourceHost,r=this._getUpstreamSourceManagers(),e=!!r.length;if(Gv(i)){var a=i,o=void 0,u=void 0,s=void 0;if(e){var l=r[0];l.prepareSource(),o=(s=l.getSource()).data,u=s.sourceFormat,n=[l._getVersionSign()]}else u=it(o=a.get("data",!0))?du:fu,n=[];var f=this._getSourceMetaRawOption()||{},h=s&&s.metaRawOption||{},c=ut(f.seriesLayoutBy,h.seriesLayoutBy)||null,v=ut(f.sourceHeader,h.sourceHeader),d=ut(f.dimensions,h.dimensions);t=c!==h.seriesLayoutBy||!!v!=!!h.sourceHeader||d?[eh(o,{seriesLayoutBy:c,sourceHeader:v,dimensions:d},u)]:[]}else{var p=i;if(e){var m=this._applyTransform(r);t=m.sourceList,n=m.upstreamSignList}else t=[eh(p.get("source",!0),this._getSourceMetaRawOption(),null)],n=[]}this._setLocalSource(t,n)},t.prototype._applyTransform=function(t){var n,i=this._sourceHost,r=i.get("transform",!0),e=i.get("fromTransformResult",!0);null!=e&&1!==t.length&&Zv("");var a,o=[],u=[];return H(t,(function(t){t.prepareSource();var n=t.getSource(e||0);null==e||n||Zv(""),o.push(n),u.push(t._getVersionSign())})),r?n=function(t,n){var i=To(t),r=i.length;r||ko("");for(var e=0,a=r;e<a;e++)n=Yv(i[e],n),e!==a-1&&(n.length=Math.max(n.length,1));return n}(r,o):null!=e&&(n=[(a=o[0],new ih({data:a.data,sourceFormat:a.sourceFormat,seriesLayoutBy:a.seriesLayoutBy,dimensionsDefine:R(a.dimensionsDefine),startIndex:a.startIndex,dimensionsDetectedCount:a.dimensionsDetectedCount}))]),{sourceList:n,upstreamSignList:u}},t.prototype._isDirty=function(){if(this._dirty)return!0;for(var t=this._getUpstreamSourceManagers(),n=0;n<t.length;n++){var i=t[n];if(i._isDirty()||this._upstreamSignList[n]!==i._getVersionSign())return!0}},t.prototype.getSource=function(t){var n=this._sourceList[t=t||0];if(!n){var i=this._getUpstreamSourceManagers();return i[0]&&i[0].getSource(t)}return n},t.prototype.getSharedDataStore=function(t){var n=t.makeStoreSchema();return this._innerGetDataStore(n.dimensions,t.source,n.hash)},t.prototype._innerGetDataStore=function(t,n,i){var r=this._storeList,e=r[0];e||(e=r[0]={});var a=e[i];if(!a){var o=this._getUpstreamSourceManagers()[0];Gv(this._sourceHost)&&o?a=o._innerGetDataStore(t,n,i):(a=new Ph).initData(new lh(n,t.length),t),e[i]=a}return a},t.prototype._getUpstreamSourceManagers=function(){var t=this._sourceHost;if(Gv(t)){var n=Xf(t);return n?[n.getSourceManager()]:[]}return U(function(t){return t.get("transform",!0)||t.get("fromTransformResult",!0)?Ho(t.ecModel,"dataset",{index:t.get("fromDatasetIndex",!0),id:t.get("fromDatasetId",!0)},jo).models:[]}(t),(function(t){return t.getSourceManager()}))},t.prototype._getSourceMetaRawOption=function(){var t,n,i,r=this._sourceHost;if(Gv(r))t=r.get("seriesLayoutBy",!0),n=r.get("sourceHeader",!0),i=r.get("dimensions",!0);else if(!this._getUpstreamSourceManagers().length){var e=r;t=e.get("seriesLayoutBy",!0),n=e.get("sourceHeader",!0),i=e.get("dimensions",!0)}return{seriesLayoutBy:t,sourceHeader:n,dimensions:i}},t}();function Gv(t){return"series"===t.mainType}function Zv(t){throw new Error(t)}var Jv={color:{},darkColor:{},size:{}},Kv=Jv.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)"};for(var Qv in P(Kv,{primary:Kv.neutral80,secondary:Kv.neutral70,tertiary:Kv.neutral60,quaternary:Kv.neutral50,disabled:Kv.neutral20,border:Kv.neutral30,borderTint:Kv.neutral20,borderShade:Kv.neutral40,background:Kv.neutral05,backgroundTint:"rgba(234,237,245,0.5)",backgroundTransparent:"rgba(255,255,255,0)",backgroundShade:Kv.neutral10,shadow:"rgba(0,0,0,0.2)",shadowTint:"rgba(129,130,136,0.2)",axisLine:Kv.neutral70,axisLineTint:Kv.neutral40,axisTick:Kv.neutral70,axisTickMinor:Kv.neutral60,axisLabel:Kv.neutral70,axisSplitLine:Kv.neutral15,axisMinorSplitLine:Kv.neutral05}),Kv)if(Kv.hasOwnProperty(Qv)){var td=Kv[Qv];"theme"===Qv?Jv.darkColor.theme=Kv.theme.slice():"highlight"===Qv?Jv.darkColor.highlight="rgba(255,231,130,0.4)":Jv.darkColor[Qv]=0===Qv.indexOf("accent")?lr(td,0,(function(t){return.5*t}),(function(t){return Math.min(1,1.3-t)})):lr(td,0,(function(t){return.9*t}),(function(t){return 1-Math.pow(t,1.5)}))}function nd(t){var n=t.lineHeight;return null==n?"line-height:1":"line-height:"+Nc(n+"")+"px"}function id(t,n){var i=t.color||Jv.color.tertiary,r=t.fontSize||12,e=t.fontWeight||"400",a=t.color||Jv.color.secondary,o=t.fontSize||14,u=t.fontWeight||"900";return"html"===n?{nameStyle:"font-size:"+Nc(r+"")+"px;color:"+Nc(i)+";font-weight:"+Nc(e+""),valueStyle:"font-size:"+Nc(o+"")+"px;color:"+Nc(a)+";font-weight:"+Nc(u+"")}:{nameStyle:{fontSize:r,fill:i,fontWeight:e},valueStyle:{fontSize:o,fill:a,fontWeight:u}}}Jv.size={xxs:2,xs:5,s:10,m:15,l:20,xl:30,xxl:40,xxxl:50};var rd=[0,10,20,30],ed=["","\n","\n\n","\n\n\n"];function ad(t,n){return n.type=t,n}function od(t){return"section"===t.type}function ud(t){return od(t)?ld:fd}function sd(t){if(od(t)){var n=0,i=t.blocks.length,r=i>1||i>0&&!t.noHeader;return H(t.blocks,(function(t){var i=sd(t);i>=n&&(n=i+ +(r&&(!i||od(t)&&!t.noHeader)))})),n}return 0}function ld(t,n,i,r){var e,a=n.noHeader,o=(e=sd(n),{html:rd[e],richText:ed[e]}),u=[],s=n.blocks||[];ht(!s||G(s)),s=s||[];var l=t.orderMode;if(n.sortBlocks&&l){s=s.slice();var f={valueAsc:"asc",valueDesc:"desc"};if(xt(f,l)){var h=new Th(f[l],null);s.sort((function(t,n){return h.evaluate(t.sortParam,n.sortParam)}))}else"seriesDesc"===l&&s.reverse()}H(s,(function(i,e){var a=n.valueFormatter,s=ud(i)(a?P(P({},t),{valueFormatter:a}):t,i,e>0?o.html:0,r);null!=s&&u.push(s)}));var c="richText"===t.renderMode?u.join(o.richText):cd(r,u.join(""),a?i:o.html);if(a)return c;var v=pv(n.header,"ordinal",t.useUTC),d=id(r,t.renderMode).nameStyle,p=nd(r);return"richText"===t.renderMode?vd(t,v,d)+o.richText+c:cd(r,'<div style="'+d+";"+p+';">'+Nc(v)+"</div>"+c,i)}function fd(t,n,i,r){var e=t.renderMode,a=n.noName,o=n.noValue,u=!n.markerType,s=n.name,l=t.useUTC,f=n.valueFormatter||t.valueFormatter||function(t){return U(t=G(t)?t:[t],(function(t,n){return pv(t,G(v)?v[n]:v,l)}))};if(!a||!o){var h=u?"":t.markupStyleCreator.makeTooltipMarker(n.markerType,n.markerColor||Jv.color.secondary,e),c=a?"":pv(s,"ordinal",l),v=n.valueType,d=o?[]:f(n.value,n.rawDataIndex),p=!u||!a,m=!u&&a,y=id(r,e),g=y.nameStyle,b=y.valueStyle;return"richText"===e?(u?"":h)+(a?"":vd(t,c,g))+(o?"":function(t,n,i,r,e){var a=[e];return i&&a.push({padding:[0,0,0,r?10:20],align:"right"}),t.markupStyleCreator.wrapRichTextStyle(G(n)?n.join(" "):n,a)}(t,d,p,m,b)):cd(r,(u?"":h)+(a?"":function(t,n,i){return'<span style="'+i+";"+(n?"margin-left:2px":"")+'">'+Nc(t)+"</span>"}(c,!u,g))+(o?"":function(t,n,i,r){return'<span style="'+(n?"float:right;margin-left:"+(i?"10px":"20px"):"")+";"+r+'">'+U(t=G(t)?t:[t],(function(t){return Nc(t)})).join("&nbsp;&nbsp;")+"</span>"}(d,p,m,b)),i)}}function hd(t,n,i,r,e,a){if(t)return ud(t)({useUTC:e,renderMode:i,orderMode:r,markupStyleCreator:n,valueFormatter:t.valueFormatter},t,0,a)}function cd(t,n,i){return'<div style="margin: '+i+"px 0 0;"+nd(t)+';">'+n+'<div style="clear:both"></div></div>'}function vd(t,n,i){return t.markupStyleCreator.wrapRichTextStyle(n,i)}function dd(t,n){var i=t.get("padding");return null!=i?i:"richText"===n?[8,10]:10}var pd=function(){function t(){this.richTextStyles={},this._nextStyleNameId=yo()}return t.prototype._generateStyleName=function(){return"__EC_aUTo_"+this._nextStyleNameId++},t.prototype.makeTooltipMarker=function(t,n,i){var r="richText"===i?this._generateStyleName():null,e=function(t,n){var i=J(t)?{color:t,extraCssText:n}:t||{},r=i.color,e=i.type;n=i.extraCssText;var a=i.renderMode||"html";return r?"html"===a?"subItem"===e?'<span style="display:inline-block;vertical-align:middle;margin-right:8px;margin-left:3px;border-radius:4px;width:4px;height:4px;background-color:'+Nc(r)+";"+(n||"")+'"></span>':'<span style="display:inline-block;margin-right:4px;border-radius:10px;width:10px;height:10px;background-color:'+Nc(r)+";"+(n||"")+'"></span>':{renderMode:a,content:"{"+(i.markerId||"markerX")+"|} ",style:"subItem"===e?{width:4,height:4,borderRadius:2,backgroundColor:r}:{width:10,height:10,borderRadius:5,backgroundColor:r}}:""}({color:n,type:t,renderMode:i,markerId:r});return J(e)?e:(this.richTextStyles[r]=e.style,e.content)},t.prototype.wrapRichTextStyle=function(t,n){var i={};G(n)?H(n,(function(t){return P(i,t)})):P(i,n);var r=this._generateStyleName();return this.richTextStyles[r]=i,"{"+r+"|"+t+"}"},t}();var md=Po();function yd(t,n){return t.getName(n)||t.getId(n)}var gd=function(t){function n(){var n=null!==t&&t.apply(this,arguments)||this;return n._selectedDataIndicesMap={},n}var i;return v(n,t),n.prototype.init=function(t,n,i){this.seriesIndex=this.componentIndex,this.dataTask=Pv({count:wd,reset:xd}),this.dataTask.context={model:this},this.mergeDefaultAndTheme(t,i),(md(this).sourceManager=new qv(this)).prepareSource();var r=this.getInitialData(t,i);kd(r,this),this.dataTask.context.data=r,md(this).dataBeforeProcessed=r,bd(this),this._initSelectedMapFromData(r)},n.prototype.mergeDefaultAndTheme=function(t,n){var i=Nv(this),r=i?Ov(t):{},e=this.subType;Lv.hasClass(e)&&(e+="Series"),F(t,n.getTheme().get(this.subType)),F(t,this.getDefaultOption()),No(t,"label",["show"]),this.fillDataTextStyle(t.data),i&&Cv(t,r,i)},n.prototype.mergeOption=function(t,n){t=F(this.option,t,!0),this.fillDataTextStyle(t.data);var i=Nv(this);i&&Cv(this.option,t,i);var r=md(this).sourceManager;r.dirty(),r.prepareSource();var e=this.getInitialData(t,n);kd(e,this),this.dataTask.dirty(),this.dataTask.context.data=e,md(this).dataBeforeProcessed=e,bd(this),this._initSelectedMapFromData(e)},n.prototype.fillDataTextStyle=function(t){if(t&&!it(t))for(var n=["show"],i=0;i<t.length;i++)t[i]&&t[i].label&&No(t[i],"label",n)},n.prototype.getInitialData=function(){},n.prototype.appendData=function(t){this.getRawData().appendData(t.data)},n.prototype.getData=function(t){var n=Ad(this);if(n){var i=n.context.data;return null!=t&&i.getLinkedData?i.getLinkedData(t):i}return md(this).data},n.prototype.getAllData=function(){var t=this.getData();return t&&t.getLinkedDataAll?t.getLinkedDataAll():[{data:t}]},n.prototype.setData=function(t){var n=Ad(this);if(n){var i=n.context;i.outputData=t,n!==this.dataTask&&(i.data=t)}md(this).data=t},n.prototype.getEncode=function(){var t=this.get("encode",!0);if(t)return bt(t)},n.prototype.getSourceManager=function(){return md(this).sourceManager},n.prototype.getSource=function(){return this.getSourceManager().getSource()},n.prototype.getRawData=function(){return md(this).dataBeforeProcessed},n.prototype.getColorBy=function(){return this.get("colorBy")||"series"},n.prototype.isColorBySeries=function(){return"series"===this.getColorBy()},n.prototype.getBaseAxis=function(){var t=this.coordinateSystem;return t&&t.getBaseAxis&&t.getBaseAxis()},n.prototype.indicesOfNearest=function(t,n,i,r){var e=this.getData(),a=this.coordinateSystem,o=a&&a.getAxis(t);if(!a||!o)return[];var u=o.dataToCoord(i);null==r&&(r=1/0);for(var s=[],l=1/0,f=-1,h=0,c=e.getDimensionIndex(n),v=e.getStore(),d=0,p=v.count();d<p;d++){var m=v.get(c,d),y=u-o.dataToCoord(m),g=Math.abs(y);g<=r&&((g<l||g===l&&y>=0&&f<0)&&(l=g,f=y,h=0),y===f&&(s[h++]=d))}return s.length=h,s},n.prototype.formatTooltip=function(t,n){return function(t){var n,i,r,e,a=t.series,o=t.dataIndex,u=t.multipleSeries,s=a.getData(),l=s.mapDimensionsAll("defaultedTooltip"),f=l.length,h=a.getRawValue(o),c=G(h),v=function(t,n){return bv(t.getData().getItemVisual(n,"style")[t.visualDrawType])}(a,o);if(f>1||c&&!f){var d=function(t,n,i,r,e){var a=n.getData(),o=V(t,(function(t,n,i){var r=a.getDimensionInfo(i);return t||r&&!1!==r.tooltip&&null!=r.displayName}),!1),u=[],s=[],l=[];function f(t,n){var i=a.getDimensionInfo(n);i&&!1!==i.otherDims.tooltip&&(o?l.push(ad("nameValue",{markerType:"subItem",markerColor:e,name:i.displayName,value:t,valueType:i.type})):(u.push(t),s.push(i.type)))}return r.length?H(r,(function(t){f(xh(a,i,t),t)})):H(t,f),{inlineValues:u,inlineValueTypes:s,blocks:l}}(h,a,o,l,v);n=d.inlineValues,i=d.inlineValueTypes,r=d.blocks,e=d.inlineValues[0]}else if(f){var p=s.getDimensionInfo(l[0]);e=n=xh(s,o,l[0]),i=p.type}else e=n=c?h[0]:h;var m=zo(a),y=m&&a.name||"",g=s.getName(o),b=u?y:g;return ad("section",{header:y,noHeader:u||!m,sortParam:e,blocks:[ad("nameValue",{markerType:"item",markerColor:v,name:b,noName:!ct(b),value:n,valueType:i,rawDataIndex:s.getRawIndex(o)})].concat(r||[])})}({series:this,dataIndex:t,multipleSeries:n})},n.prototype.isAnimationEnabled=function(){var t=this.ecModel;if(At.node&&(!t||!t.ssr))return!1;var n=this.getShallow("animation");return n&&this.getData().count()>this.getShallow("animationThreshold")&&(n=!1),!!n},n.prototype.restoreData=function(){this.dataTask.dirty()},n.prototype.getColorFromPalette=function(t,n,i){var r=this.ecModel,e=_v.prototype.getColorFromPalette.call(this,t,n,i);return e||(e=r.getColorFromPalette(t,n,i)),e},n.prototype.coordDimToDataDim=function(t){return this.getRawData().mapDimensionsAll(t)},n.prototype.getProgressive=function(){return this.get("progressive")},n.prototype.getProgressiveThreshold=function(){return this.get("progressiveThreshold")},n.prototype.select=function(t,n){this._innerSelect(this.getData(n),t)},n.prototype.unselect=function(t,n){var i=this.option.selectedMap;if(i){var r=this.option.selectedMode,e=this.getData(n);if("series"===r||"all"===i)return this.option.selectedMap={},void(this._selectedDataIndicesMap={});for(var a=0;a<t.length;a++){var o=yd(e,t[a]);i[o]=!1,this._selectedDataIndicesMap[o]=-1}}},n.prototype.toggleSelect=function(t,n){for(var i=[],r=0;r<t.length;r++)i[0]=t[r],this.isSelected(t[r],n)?this.unselect(i,n):this.select(i,n)},n.prototype.getSelectedDataIndices=function(){if("all"===this.option.selectedMap)return[].slice.call(this.getData().getIndices());for(var t=this._selectedDataIndicesMap,n=Y(t),i=[],r=0;r<n.length;r++){var e=t[n[r]];e>=0&&i.push(e)}return i},n.prototype.isSelected=function(t,n){var i=this.option.selectedMap;if(!i)return!1;var r=this.getData(n);return("all"===i||i[yd(r,t)])&&!r.getItemModel(t).get(["select","disabled"])},n.prototype.isUniversalTransitionEnabled=function(){if(this.__universalTransitionEnabled)return!0;var t=this.option.universalTransition;return!!t&&(!0===t||t&&t.enabled)},n.prototype._innerSelect=function(t,n){var i,r,e=this.option,a=e.selectedMode,o=n.length;if(a&&o)if("series"===a)e.selectedMap="all";else if("multiple"===a){tt(e.selectedMap)||(e.selectedMap={});for(var u=e.selectedMap,s=0;s<o;s++){var l=n[s];u[h=yd(t,l)]=!0,this._selectedDataIndicesMap[h]=t.getRawIndex(l)}}else if("single"===a||!0===a){var f=n[o-1],h=yd(t,f);e.selectedMap=((i={})[h]=!0,i),this._selectedDataIndicesMap=((r={})[h]=t.getRawIndex(f),r)}},n.prototype._initSelectedMapFromData=function(t){if(!this.option.selectedMap){var n=[];t.hasItemOption&&t.each((function(i){var r=t.getRawDataItem(i);r&&r.selected&&n.push(i)})),n.length>0&&this._innerSelect(t,n)}},n.registerClass=function(t){return Lv.registerClass(t)},n.protoInitialize=((i=n.prototype).type="series.__base__",i.seriesIndex=0,i.ignoreStyleOnData=!1,i.hasSymbolVisual=!1,i.defaultSymbol="circle",i.visualStyleAccessPath="itemStyle",void(i.visualDrawType="fill")),n}(Lv);function bd(t){var n=t.name;zo(t)||(t.name=function(t){var n=t.getRawData(),i=n.mapDimensionsAll("seriesName"),r=[];return H(i,(function(t){var i=n.getDimensionInfo(t);i.displayName&&r.push(i.displayName)})),r.join(" ")}(t)||n)}function wd(t){return t.model.getRawData().count()}function xd(t){var n=t.model;return n.setData(n.getRawData().cloneShallow()),Md}function Md(t,n){n.outputData&&t.end>n.outputData.count()&&n.model.getRawData().cloneShallow(n.outputData)}function kd(t,n){H(function(t,n){for(var i=new t.constructor(t.length+n.length),r=0;r<t.length;r++)i[r]=t[r];var e=t.length;for(r=0;r<n.length;r++)i[r+e]=n[r];return i}(t.CHANGABLE_METHODS,t.DOWNSAMPLE_METHODS),(function(i){t.wrapMethod(i,q(Sd,n))}))}function Sd(t,n){var i=Ad(t);return i&&i.setOutputEnd((n||this).count()),n}function Ad(t){var n=(t.ecModel||{}).scheduler,i=n&&n.getPipeline(t.uid);if(i){var r=i.currentTask;if(r){var e=r.agentStubMap;e&&(r=e.get(t.uid))}return r}}W(gd,Rv),W(gd,_v),It(gd,Lv);var Td=da.extend({type:"triangle",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(t,n){var i=n.cx,r=n.cy,e=n.width/2,a=n.height/2;t.moveTo(i,r-a),t.lineTo(i+e,r+a),t.lineTo(i-e,r+a),t.closePath()}}),Nd=da.extend({type:"diamond",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(t,n){var i=n.cx,r=n.cy,e=n.width/2,a=n.height/2;t.moveTo(i,r-a),t.lineTo(i+e,r),t.lineTo(i,r+a),t.lineTo(i-e,r),t.closePath()}}),Cd=da.extend({type:"pin",shape:{x:0,y:0,width:0,height:0},buildPath:function(t,n){var i=n.x,r=n.y,e=n.width/5*3,a=Math.max(e,n.height),o=e/2,u=o*o/(a-o),s=r-a+o+u,l=Math.asin(u/o),f=Math.cos(l)*o,h=Math.sin(l),c=Math.cos(l),v=.6*o,d=.7*o;t.moveTo(i-f,s+u),t.arc(i,s,o,Math.PI-l,2*Math.PI+l),t.bezierCurveTo(i+f-h*v,s+u+c*v,i,r-d,i,r),t.bezierCurveTo(i,r-d,i-f+h*v,s+u+c*v,i-f,s+u),t.closePath()}}),Od=da.extend({type:"arrow",shape:{x:0,y:0,width:0,height:0},buildPath:function(t,n){var i=n.height,r=n.x,e=n.y,a=n.width/3*2;t.moveTo(r,e),t.lineTo(r+a,e+i),t.lineTo(r,e+i/4*3),t.lineTo(r-a,e+i),t.lineTo(r,e),t.closePath()}}),Id={line:function(t,n,i,r,e){e.x1=t,e.y1=n+r/2,e.x2=t+i,e.y2=n+r/2},rect:function(t,n,i,r,e){e.x=t,e.y=n,e.width=i,e.height=r},roundRect:function(t,n,i,r,e){e.x=t,e.y=n,e.width=i,e.height=r,e.r=Math.min(i,r)/4},square:function(t,n,i,r,e){var a=Math.min(i,r);e.x=t,e.y=n,e.width=a,e.height=a},circle:function(t,n,i,r,e){e.cx=t+i/2,e.cy=n+r/2,e.r=Math.min(i,r)/2},diamond:function(t,n,i,r,e){e.cx=t+i/2,e.cy=n+r/2,e.width=i,e.height=r},pin:function(t,n,i,r,e){e.x=t+i/2,e.y=n+r/2,e.width=i,e.height=r},arrow:function(t,n,i,r,e){e.x=t+i/2,e.y=n+r/2,e.width=i,e.height=r},triangle:function(t,n,i,r,e){e.cx=t+i/2,e.cy=n+r/2,e.width=i,e.height=r}},Ld={};H({line:el,rect:Ta,roundRect:Ta,square:Ta,circle:Ds,diamond:Nd,pin:Cd,arrow:Od,triangle:Td},(function(t,n){Ld[n]=new t}));var Dd=da.extend({type:"symbol",shape:{symbolType:"",x:0,y:0,width:0,height:0},calculateTextPosition:function(t,n,i){var r=qn(t,n,i),e=this.shape;return e&&"pin"===e.symbolType&&"inside"===n.position&&(r.y=i.y+.4*i.height),r},buildPath:function(t,n,i){var r=n.symbolType;if("none"!==r){var e=Ld[r];e||(e=Ld[r="rect"]),Id[r](n.x,n.y,n.width,n.height,e.shape),e.buildPath(t,e.shape,i)}}});function _d(t,n){if("image"!==this.type){var i=this.style;this.__isEmptyBrush?(i.stroke=t,i.fill=n||Jv.color.neutral00,i.lineWidth=2):"line"===this.shape.symbolType?i.stroke=t:i.fill=t,this.markRedraw()}}function zd(t,n,i,r,e,a,o){var u,s=0===t.indexOf("empty");return s&&(t=t.substr(5,1).toLowerCase()+t.substr(6)),(u=0===t.indexOf("image://")?Wl(t.slice(8),new On(n,i,r,e),o?"center":"cover"):0===t.indexOf("path://")?El(t.slice(7),{},new On(n,i,r,e),o?"center":"cover"):new Dd({shape:{symbolType:t,x:n,y:i,width:r,height:e}})).__isEmptyBrush=s,u.setColor=_d,a&&u.setColor(a),u}function Rd(t,n){if(null!=t)return G(t)||(t=[t,t]),[no(t[0],n[0])||0,no(ut(t[1],t[0]),n[1])||0]}var Fd=function(t){function n(){var i=null!==t&&t.apply(this,arguments)||this;return i.type=n.type,i.hasSymbolVisual=!0,i}return v(n,t),n.prototype.getInitialData=function(){return pc(0,this,{useEncodeDefaulter:!0})},n.prototype.getLegendIcon=function(t){var n=new Is,i=zd("line",0,t.itemHeight/2,t.itemWidth,0,t.lineStyle.stroke,!1);n.add(i),i.setStyle(t.lineStyle);var r=this.getData().getVisual("symbol"),e=this.getData().getVisual("symbolRotate"),a="none"===r?"circle":r,o=.8*t.itemHeight,u=zd(a,(t.itemWidth-o)/2,(t.itemHeight-o)/2,o,o,t.itemStyle.fill);return n.add(u),u.setStyle(t.itemStyle),u.rotation=("inherit"===t.iconRotate?e:t.iconRotate||0)*Math.PI/180,u.setOrigin([t.itemWidth/2,t.itemHeight/2]),a.indexOf("empty")>-1&&(u.style.stroke=u.style.fill,u.style.fill=Jv.color.neutral00,u.style.lineWidth=2),n},n.type="series.line",n.dependencies=["grid","polar"],n.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,triggerEvent:!1},n}(gd);function Pd(t,n){var i=t.mapDimensionsAll("defaultedLabel"),r=i.length;if(1===r){var e=xh(t,n,i[0]);return null!=e?e+"":null}if(r){for(var a=[],o=0;o<i.length;o++)a.push(xh(t,n,i[o]));return a.join(" ")}}function Bd(t,n){var i=t.mapDimensionsAll("defaultedLabel");if(!G(n))return n+"";for(var r=[],e=0;e<i.length;e++){var a=t.getDimensionIndex(i[e]);a>=0&&r.push(n[a])}return r.join(" ")}var Ed=function(t){function n(n,i,r,e){var a=t.call(this)||this;return a.updateData(n,i,r,e),a}return v(n,t),n.prototype._createSymbol=function(t,n,i,r,e,a){this.removeAll();var o=zd(t,-1,-1,2,2,null,a);o.attr({z2:ut(e,100),culling:!0,scaleX:r[0]/2,scaleY:r[1]/2}),o.drift=Wd,this._symbolType=t,this.add(o)},n.prototype.stopSymbolAnimation=function(t){this.childAt(0).stopAnimation(null,t)},n.prototype.getSymbolType=function(){return this._symbolType},n.prototype.getSymbolPath=function(){return this.childAt(0)},n.prototype.highlight=function(){Xu(this.childAt(0))},n.prototype.downplay=function(){qu(this.childAt(0))},n.prototype.setZ=function(t,n){var i=this.childAt(0);i.zlevel=t,i.z=n},n.prototype.setDraggable=function(t,n){var i=this.childAt(0);i.draggable=t,i.cursor=!n&&t?"move":i.cursor},n.prototype.updateData=function(t,i,r,e){this.silent=!1;var a=t.getItemVisual(i,"symbol")||"circle",o=t.hostModel,u=n.getSymbolSize(t,i),s=n.getSymbolZ2(t,i),l=a!==this._symbolType,f=e&&e.disableAnimation;if(l){var h=t.getItemVisual(i,"symbolKeepAspect");this._createSymbol(a,t,i,u,s,h)}else{(v=this.childAt(0)).silent=!1;var c={scaleX:u[0]/2,scaleY:u[1]/2};f?v.attr(c):Cl(v,c,o,i),zl(v)}if(this._updateCommon(t,i,u,r,e),l){var v=this.childAt(0);f||(c={scaleX:this._sizeX,scaleY:this._sizeY,style:{opacity:v.style.opacity}},v.scaleX=v.scaleY=0,v.style.opacity=0,Ol(v,c,o,i))}f&&this.childAt(0).stopAnimation("leave")},n.prototype._updateCommon=function(t,n,i,r,e){var a,o,u,s,l,f,h,c,v,d=this.childAt(0),p=t.hostModel;if(r&&(a=r.emphasisItemStyle,o=r.blurItemStyle,u=r.selectItemStyle,s=r.focus,l=r.blurScope,h=r.labelStatesModels,c=r.hoverScale,v=r.cursorStyle,f=r.emphasisDisabled),!r||t.hasItemOption){var m=r&&r.itemModel?r.itemModel:t.getItemModel(n),y=m.getModel("emphasis");a=y.getModel("itemStyle").getItemStyle(),u=m.getModel(["select","itemStyle"]).getItemStyle(),o=m.getModel(["blur","itemStyle"]).getItemStyle(),s=y.get("focus"),l=y.get("blurScope"),f=y.get("disabled"),h=gf(m),c=y.getShallow("scale"),v=m.getShallow("cursor")}var g=t.getItemVisual(n,"symbolRotate");d.attr("rotation",(g||0)*Math.PI/180||0);var b=Rd(t.getItemVisual(n,"symbolOffset"),i);b&&(d.x=b[0],d.y=b[1]),v&&d.attr("cursor",v);var w=t.getItemVisual(n,"style"),x=w.fill;if(d instanceof ba){var M=d.style;d.useStyle(P({image:M.image,x:M.x,y:M.y,width:M.width,height:M.height},w))}else d.useStyle(d.__isEmptyBrush?P({},w):w),d.style.decal=null,d.setColor(x,e&&e.symbolInnerColor),d.style.strokeNoScale=!0;var k=t.getItemVisual(n,"liftZ"),S=this._z2;null!=k?null==S&&(this._z2=d.z2,d.z2+=k):null!=S&&(d.z2=S,this._z2=null);var A=e&&e.useNameLabel;yf(d,h,{labelFetcher:p,labelDataIndex:n,defaultText:function(n){return A?t.getName(n):Pd(t,n)},inheritColor:x,defaultOpacity:w.opacity}),this._sizeX=i[0]/2,this._sizeY=i[1]/2;var T=d.ensureState("emphasis");T.style=a,d.ensureState("select").style=u,d.ensureState("blur").style=o;var N=null==c||!0===c?Math.max(1.1,3/this._sizeY):isFinite(c)&&c>0?+c:1;T.scaleX=this._sizeX*N,T.scaleY=this._sizeY*N,this.setSymbolScale(1),as(this,s,l,f)},n.prototype.setSymbolScale=function(t){this.scaleX=this.scaleY=t},n.prototype.fadeOut=function(t,n,i){var r=this.childAt(0),e=au(this).dataIndex,a=i&&i.animation;if(this.silent=r.silent=!0,i&&i.fadeLabel){var o=r.getTextContent();o&&Ll(o,{style:{opacity:0}},n,{dataIndex:e,removeOpt:a,cb:function(){r.removeTextContent()}})}else r.removeTextContent();Ll(r,{style:{opacity:0},scaleX:0,scaleY:0},n,{dataIndex:e,cb:t,removeOpt:a})},n.getSymbolSize=function(t,n){return G(i=t.getItemVisual(n,"symbolSize"))||(i=[+i,+i]),[i[0]||0,i[1]||0];var i},n.getSymbolZ2=function(t,n){return t.getItemVisual(n,"z2")},n}(Is);function Wd(t,n){this.parent.drift(t,n)}function jd(t,n,i,r){return n&&!isNaN(n[0])&&!isNaN(n[1])&&!(r&&r.isIgnore&&r.isIgnore(i))&&!(r&&r.clipShape&&!r.clipShape.contain(n[0],n[1]))&&"none"!==t.getItemVisual(i,"symbol")}function Hd(t){return null==t||tt(t)||(t={isIgnore:t}),t||{}}function Ud(t){var n=t.hostModel,i=n.getModel("emphasis");return{emphasisItemStyle:i.getModel("itemStyle").getItemStyle(),blurItemStyle:n.getModel(["blur","itemStyle"]).getItemStyle(),selectItemStyle:n.getModel(["select","itemStyle"]).getItemStyle(),focus:i.get("focus"),blurScope:i.get("blurScope"),emphasisDisabled:i.get("disabled"),hoverScale:i.get("scale"),labelStatesModels:gf(n),cursorStyle:n.get("cursor")}}function Vd(t,n,i,r,e,a,o){var u=new t(n,i,r,e);return u.setPosition(a),n.setItemGraphicEl(i,u),o.add(u),u}var $d=function(){function t(t){this.group=new Is,this._SymbolCtor=t||Ed}return t.prototype.updateData=function(t,n){this._progressiveEls=null,n=Hd(n);var i=this.group,r=t.hostModel,e=this._data,a=this._SymbolCtor,o=n.disableAnimation,u=this._seriesScope=Ud(t),s={disableAnimation:o},l=n.getSymbolPoint||function(n){return t.getItemLayout(n)};e||i.removeAll(),t.diff(e).add((function(r){var e=l(r);jd(t,e,r,n)&&Vd(a,t,r,u,s,e,i)})).update((function(f,h){var c=e.getItemGraphicEl(h),v=l(f);if(jd(t,v,f,n)){var d=t.getItemVisual(f,"symbol")||"circle",p=c&&c.getSymbolType&&c.getSymbolType();if(!c||p&&p!==d)i.remove(c),(c=new a(t,f,u,s)).setPosition(v);else{c.updateData(t,f,u,s);var m={x:v[0],y:v[1]};o?c.attr(m):Cl(c,m,r)}i.add(c),t.setItemGraphicEl(f,c)}else i.remove(c)})).remove((function(t){var n=e.getItemGraphicEl(t);n&&n.fadeOut((function(){i.remove(n)}),r)})).execute(),this._getSymbolPoint=l,this._data=t},t.prototype.updateLayout=function(t){var n=this._data;if(n)for(var i=this,r=0,e=n.getStore().count();r<e;r++){var a=n.getItemGraphicEl(r),o=i._getSymbolPoint(r);jd(n,o,r,t)?((a=a||Vd(i._SymbolCtor,n,r,i._seriesScope,{disableAnimation:!0},o,i.group)).stopAnimation(),a.setPosition(o),a.markRedraw()):a&&(i.group.remove(a),n.setItemGraphicEl(r,null))}},t.prototype.incrementalPrepareUpdate=function(t){this._seriesScope=Ud(t),this._data=null,this.group.removeAll()},t.prototype.incrementalUpdate=function(t,n,i,r){function e(t){t.isGroup||(t.incremental=i,t.ensureState("emphasis").hoverLayer=2)}this._progressiveEls=[],r=Hd(r);for(var a=t.start;a<t.end;a++){var o=n.getItemLayout(a);if(jd(n,o,a,r)){var u=new this._SymbolCtor(n,a,this._seriesScope);u.traverse(e),u.setPosition(o),this.group.add(u),n.setItemGraphicEl(a,u),this._progressiveEls.push(u)}}},t.prototype.eachRendered=function(t){ef(this._progressiveEls||this.group,t)},t.prototype.remove=function(t){var n=this.group,i=this._data;i&&t?i.eachItemGraphicEl((function(t){t.fadeOut((function(){n.remove(t)}),i.hostModel)})):n.removeAll()},t}();function Yd(t,n,i){var r=t.getBaseAxis(),e=t.getOtherAxis(r),a=function(t,n){var i=0,r=t.scale.getExtent();return"start"===n?i=r[0]:"end"===n?i=r[1]:Q(n)&&!isNaN(n)?i=n:r[0]>0?i=r[0]:r[1]<0&&(i=r[1]),i}(e,i),o=r.dim,u=e.dim,s=n.mapDimension(u),l=n.mapDimension(o),f="x"===u||"radius"===u?1:0,h=U(t.dimensions,(function(t){return n.mapDimension(t)})),c=!1,v=n.getCalculationInfo("stackResultDimension");return dc(n,h[0])&&(c=!0,h[0]=v),dc(n,h[1])&&(c=!0,h[1]=v),{dataDimsForPoint:h,valueStart:a,valueAxisDim:u,baseAxisDim:o,stacked:!!c,valueDim:s,baseDim:l,baseDataOffset:f,stackedOverDimension:n.getCalculationInfo("stackedOverDimension")}}function Xd(t,n,i,r){var e=NaN;t.stacked&&(e=i.get(i.getCalculationInfo("stackedOverDimension"),r)),isNaN(e)&&(e=t.valueStart);var a=t.baseDataOffset,o=[];return o[a]=i.get(t.baseDim,r),o[1-a]=e,n.dataToPoint(o)}function qd(t,n){return!isFinite(t)||!isFinite(n)}var Gd=typeof Float32Array!==uu?Float32Array:void 0,Zd=typeof Float64Array!==uu?Float64Array:void 0;function Jd(t){return Kd({ctor:Gd},t).arr}function Kd(t,n){var i=t.arr,r=t.ctor;if(n>uo&&(n=uo),!i||t.typed&&i.length<n){var e=void 0;if(r)try{e=new r(n),t.typed=!0,i&&e.set(i)}catch(t){}if(!e&&(e=[],t.typed=!1,i))for(var a=0,o=i.length;a<o;a++)e[a]=i[a];t.arr=e}return t}var Qd=Math.min,tp=Math.max;function np(t,n,i,r,e,a,o,u,s){for(var l,f,h,c,v,d,p=i,m=0;m<r;m++){var y=n[2*p],g=n[2*p+1];if(p>=e||p<0)break;if(qd(y,g)){if(s){p+=a;continue}break}if(p===i)t[a>0?"moveTo":"lineTo"](y,g),h=y,c=g;else{var b=y-l,w=g-f;if(b*b+w*w<.5){p+=a;continue}if(o>0){for(var x=p+a,M=n[2*x],k=n[2*x+1];M===y&&k===g&&m<r;)m++,M=n[2*(x+=a)],k=n[2*x+1],b=(y=n[2*(p+=a)])-l,w=(g=n[2*p+1])-f;var S=m+1;if(s)for(;qd(M,k)&&S<r;)S++,M=n[2*(x+=a)],k=n[2*x+1];var A=.5,T=0,N=0,C=void 0,O=void 0;if(S>=r||qd(M,k))v=y,d=g;else{T=M-l,N=k-f;var I=y-l,L=M-y,D=g-f,_=k-g,z=void 0,R=void 0;if("x"===u){var F=T>0?1:-1;v=y-F*(z=Math.abs(I))*o,d=g,C=y+F*(R=Math.abs(L))*o,O=g}else if("y"===u){var P=N>0?1:-1;v=y,d=g-P*(z=Math.abs(D))*o,C=y,O=g+P*(R=Math.abs(_))*o}else z=Math.sqrt(I*I+D*D),v=y-T*o*(1-(A=(R=Math.sqrt(L*L+_*_))/(R+z))),d=g-N*o*(1-A),O=g+N*o*A,C=Qd(C=y+T*o*A,tp(M,y)),O=Qd(O,tp(k,g)),C=tp(C,Qd(M,y)),d=g-(N=(O=tp(O,Qd(k,g)))-g)*z/R,v=Qd(v=y-(T=C-y)*z/R,tp(l,y)),d=Qd(d,tp(f,g)),C=y+(T=y-(v=tp(v,Qd(l,y))))*R/z,O=g+(N=g-(d=tp(d,Qd(f,g))))*R/z}t.bezierCurveTo(h,c,v,d,y,g),h=C,c=O}else t.lineTo(y,g)}l=y,f=g,p+=a}return m}var ip=function(){this.smooth=0,this.smoothConstraint=!0},rp=function(t){function n(n){var i=t.call(this,n)||this;return i.type="ec-polyline",i}return v(n,t),n.prototype.getDefaultStyle=function(){return{stroke:Jv.color.neutral99,fill:null}},n.prototype.getDefaultShape=function(){return new ip},n.prototype.buildPath=function(t,n){var i=n.points,r=0,e=i.length/2;if(n.connectNulls){for(;e>0&&qd(i[2*e-2],i[2*e-1]);e--);for(;r<e&&qd(i[2*r],i[2*r+1]);r++);}for(;r<e;)r+=np(t,i,r,e,e,1,n.smooth,n.smoothMonotone,n.connectNulls)+1},n.prototype.getPointOn=function(t,n){this.path||(this.createPathProxy(),this.buildPath(this.path,this.shape));for(var i,r,e=this.path.data,a=qe.CMD,o="x"===n,u=[],s=0;s<e.length;){var l=void 0,f=void 0,h=void 0,c=void 0,v=void 0,d=void 0,p=void 0;switch(e[s++]){case a.M:i=e[s++],r=e[s++];break;case a.L:if(l=e[s++],f=e[s++],(p=o?(t-i)/(l-i):(t-r)/(f-r))<=1&&p>=0){var m=o?(f-r)*p+r:(l-i)*p+i;return o?[t,m]:[m,t]}i=l,r=f;break;case a.C:l=e[s++],f=e[s++],h=e[s++],c=e[s++],v=e[s++],d=e[s++];var y=o?Fi(i,l,h,v,t,u):Fi(r,f,c,d,t,u);if(y>0)for(var g=0;g<y;g++){var b=u[g];if(b<=1&&b>=0)return m=o?zi(r,f,c,d,b):zi(i,l,h,v,b),o?[t,m]:[m,t]}i=v,r=d}}},n}(da),ep=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return v(n,t),n}(ip),ap=function(t){function n(n){var i=t.call(this,n)||this;return i.type="ec-polygon",i}return v(n,t),n.prototype.getDefaultShape=function(){return new ep},n.prototype.buildPath=function(t,n){var i=n.points,r=n.stackedOnPoints,e=0,a=i.length/2,o=n.smoothMonotone;if(n.connectNulls){for(;a>0&&qd(i[2*a-2],i[2*a-1]);a--);for(;e<a&&qd(i[2*e],i[2*e+1]);e++);}for(;e<a;){var u=np(t,i,e,a,a,1,n.smooth,o,n.connectNulls);np(t,r,e+u-1,u,a,-1,n.stackedOnSmooth,o,n.connectNulls),e+=u+1,t.closePath()}},n}(da);function op(){var t=Po();return function(n){var i=t(n),r=n.pipelineContext,e=!!i.large,a=!!i.progressiveRender,o=i.large=!(!r||!r.large),u=i.progressiveRender=!(!r||!r.progressiveRender);return!(e===o&&a===u)&&"reset"}}var up=Po(),sp=op(),lp=function(){function t(){this.group=new Is,this.uid=yc("viewChart"),this.renderTask=Pv({plan:cp,reset:vp}),this.renderTask.context={view:this}}return t.prototype.init=function(){},t.prototype.render=function(){},t.prototype.highlight=function(t,n,i,r){var e=t.getData(r&&r.dataType);e&&hp(e,r,"emphasis")},t.prototype.downplay=function(t,n,i,r){var e=t.getData(r&&r.dataType);e&&hp(e,r,"normal")},t.prototype.remove=function(){this.group.removeAll()},t.prototype.dispose=function(){},t.prototype.updateView=function(t,n,i,r){this.render(t,n,i,r)},t.prototype.updateVisual=function(t,n,i,r){this.render(t,n,i,r)},t.prototype.eachRendered=function(t){ef(this.group,t)},t.markUpdateMethod=function(t,n){up(t).updateMethod=n},t.protoInitialize=void(t.prototype.type="chart"),t}();function fp(t,n,i){t&&fs(t)&&("emphasis"===n?Xu:qu)(t,i)}function hp(t,n,i){var r=Fo(t,n),e=n&&null!=n.highlightKey?function(t){var n=xu[t];return null==n&&wu<=32&&(n=xu[t]=wu++),n}(n.highlightKey):null;null!=r?H(To(r),(function(n){fp(t.getItemGraphicEl(n),i,e)})):t.eachItemGraphicEl((function(t){fp(t,i,e)}))}function cp(t){return sp(t.model)}function vp(t){var n=t.model,i=t.ecModel,r=t.api,e=t.payload,a=n.pipelineContext.progressiveRender,o=t.view,u=e&&up(e).updateMethod,s=a?"incrementalPrepareRender":u&&o[u]?u:"render";return"render"!==s&&o[s](n,i,r,e),dp[s]}Ot(lp),zt(lp);var dp={incrementalPrepareRender:{progress:function(t,n){n.view.incrementalRender(t,n.model,n.ecModel,n.api,n.payload)}},render:{forceFirstProgress:!0,progress:function(t,n){n.view.render(n.model,n.ecModel,n.api,n.payload)}}};function pp(t,n,i,r,e){var a=t.getArea(),o=a.x,u=a.y,s=a.width,l=a.height,f=i.get(["lineStyle","width"])||0;o-=f/2,u-=f/2,s+=f,l+=f,s=Math.ceil(s),o!==Math.floor(o)&&(o=Math.floor(o),s++);var h=new Ta({shape:{x:o,y:u,width:s,height:l}});if(n){var c=t.getBaseAxis(),v=c.isHorizontal(),d=c.inverse;v?(d&&(h.shape.x+=s),h.shape.width=0):(d||(h.shape.y+=l),h.shape.height=0);var p=Z(e)?function(t){e(t,h)}:null;Ol(h,{shape:{width:s,height:l,x:o,y:u}},i,null,r,p)}return h}function mp(t,n,i){var r=t.getArea(),e=ro(r.r0,1),a=ro(r.r,1),o=new qs({shape:{cx:ro(t.cx,1),cy:ro(t.cy,1),r0:e,r:a,startAngle:r.startAngle,endAngle:r.endAngle,clockwise:r.clockwise}});return n&&("angle"===t.getBaseAxis().dim?o.shape.endAngle=r.startAngle:o.shape.r=e,Ol(o,{shape:{endAngle:r.endAngle,r:a}},i)),o}function yp(t){var n=t.coordinateSystem;if(t.get("clip",!0)&&n&&(!n.shouldClip||n.shouldClip()))return n.getArea&&n.getArea(.1)}function gp(t,n){return t.type===n}var bp=function(){function t(){}return t.prototype.isBlank=function(){return this._isBlank},t.prototype.setBlank=function(t){this._isBlank=t},t}();zt(bp);var wp=0,xp=function(){function t(t){this.categories=t.categories||[],this._needCollect=t.needCollect,this._deduplication=t.deduplication,this.uid=++wp,this._onCollect=t.onCollect}return t.createByAxisModel=function(n){var i=n.option,r=i.data,e=r&&U(r,Mp);return new t({categories:e,needCollect:!e,deduplication:!1!==i.dedplication})},t.prototype.getOrdinal=function(t){return this._getOrCreateMap().get(t)},t.prototype.parseAndCollect=function(t){var n,i=this._needCollect;if(!J(t)&&!i)return t;if(i&&!this._deduplication)return this.categories[n=this.categories.length]=t,this._onCollect&&this._onCollect(t,n),n;var r=this._getOrCreateMap();return null==(n=r.get(t))&&(i?(this.categories[n=this.categories.length]=t,r.set(t,n),this._onCollect&&this._onCollect(t,n)):n=NaN),n},t.prototype._getOrCreateMap=function(){return this._map||(this._map=bt(this.categories))},t}();function Mp(t){return tt(t)&&null!=t.value?t.value:t+""}var kp=Y({needTransform:1,normalize:1,scale:1,transformIn:1,transformOut:1,contain:1,getExtent:1,getExtentUnsafe:1,setExtent:1,setExtent2:1,getFilter:1,sanitize:1,getDefaultStartValue:1,freeze:1});function Sp(t,n,i){return function(t,n){var i=t||{},r=[];i._extents=r,r[0]=n?n.slice():[1/0,-1/0],P(i,Ip)}(t=t||{},i),{brk:void 0,mapper:t}}function Ap(t,n){H(kp,(function(i){t[i]=n[i]}))}function Tp(t){t.freeze=Mt}function Np(t){return t.getExtentUnsafe(0,2)}function Cp(t,n){return t.getExtentUnsafe(1,n)||t.getExtentUnsafe(0,n)}function Op(t){var n=t.getExtentUnsafe(0,3);return n[1]-n[0]}var Ip={needTransform:function(){return!1},normalize:function(t){var n=this._extents[1]||this._extents[0];return n[1]===n[0]?.5:(t-n[0])/(n[1]-n[0])},scale:function(t){var n=this._extents[1]||this._extents[0];return t*(n[1]-n[0])+n[0]},transformIn:function(t){return t},transformOut:function(t){return t},contain:function(t){var n=Cp(this,null);return t>=n[0]&&t<=n[1]},getExtent:function(){return this._extents[0].slice()},getExtentUnsafe:function(t){return this._extents[t]},setExtent:function(t,n){Lp(this._extents,0,t,n)},setExtent2:function(t,n,i){var r=this._extents;r[t]||(r[t]=r[0].slice()),Lp(r,t,n,i)},freeze:function(){}};function Lp(t,n,i,r){Go(i,r)&&(t[n][0]=i,t[n][1]=r)}function Dp(t){return _p(t)||Rp(t)}function _p(t){return"interval"===t.type}function zp(t){return"time"===t.type}function Rp(t){return"log"===t.type}function Fp(t){return"ordinal"===t.type}function Pp(t){return ao(t)+2}function Bp(t,n){return Za(t)/Za(n)}function Ep(t,n,i){var r=i&&i.lookup;if(r)for(var e=0;e<r.from.length;e++)if(t===r.from[e])return r.to[e];return Ga(n,t)}function Wp(t,n,i){var r=t.slice();if(r[0]===r[1]){var e=i&&i.ctnShp;if(0!==r[0]){var a=$a(r[0]);n[1]||(r[1]+=a/2),r[0]-=a/2}else e?(r[0]=-1,r[1]=1):r[1]=1}return qo(r[0])&&qo(r[1])||(r[0]=0,r[1]=1),r[1]<r[0]&&r.reverse(),r}function jp(t,n){return Ya(Va(t=t||n,1))}function Hp(t,n,i){var r=Np(t),e=r[0],a=t.count(),o=Math.max((n||0)+1,1);0!==e&&o>1&&a/o>2&&(e=Math.round(Math.ceil(e/o)*o)),e!==r[0]&&s(r[0],!0,!0);for(var u=e;u<=r[1];u+=o)s(u,!1,u===r[0]||u===r[1]);function s(t,n,r){i({value:t,offInterval:n},r)}u-o!==r[1]&&s(r[1],!0,!0)}var Up=function(t){function n(i){var r=t.call(this)||this;r.type="ordinal",r.parse=n.parse,Ap(r,n.decoratedMethods);var e=i.ordinalMeta;e||(e=new xp({})),G(e)&&(e=new xp({categories:U(e,(function(t){return tt(t)?t.value:t}))})),r._ordinalMeta=e;var a=Sp(null,0,i.extent||[0,e.categories.length-1]);return r._mapper=a.mapper,Tp(r),r}return v(n,t),n.parse=function(t){return null==t?t=NaN:J(t)?null==(t=this._ordinalMeta.getOrdinal(t))&&(t=NaN):t=Ya(t),t},n.prototype.getTicks=function(){var t=[];return Hp(this,0,(function(n){t.push(n)})),t},n.prototype.getMinorTicks=function(){},n.prototype.setSortInfo=function(t){if(null!=t){for(var n=t.ordinalNumbers,i=this._ordinalNumbersByTick=[],r=this._ticksByOrdinalNumber=[],e=0,a=this._ordinalMeta.categories.length,o=Ua(a,n.length);e<o;++e)r[i[e]=n[e]]=e;for(var u=0;e<a;++e){for(;null!=r[u];)u++;i[e]=u,r[u]=e}}else this._ordinalNumbersByTick=this._ticksByOrdinalNumber=null},n.prototype._getTickNumber=function(t){var n=this._ticksByOrdinalNumber;return n&&t>=0&&t<n.length?n[t]:t},n.prototype.getRawOrdinalNumber=function(t){var n=this._ordinalNumbersByTick;return n&&t>=0&&t<n.length?n[t]:t},n.prototype.getLabel=function(t){if(!this.isBlank()){var n=this.getRawOrdinalNumber(t.value),i=this._ordinalMeta.categories[n];return null==i?"":i+""}},n.prototype.count=function(){var t=Np(this._mapper);return t[1]-t[0]+1},n.prototype.getOrdinalMeta=function(){return this._ordinalMeta},n.type="ordinal",n.decoratedMethods={needTransform:function(){return this._mapper.needTransform()},contain:function(t){return this._mapper.contain(this._getTickNumber(t))&&t>=0&&t<this._ordinalMeta.categories.length},normalize:function(t){return this._mapper.normalize(this._getTickNumber(t))},scale:function(t){return this.getRawOrdinalNumber(Ya(this._mapper.scale(t)))},transformIn:function(t,n){return this._mapper.transformIn(this._getTickNumber(t),n)},transformOut:function(t,n){return this.getRawOrdinalNumber(this._mapper.transformOut(t,n))},getExtent:function(){return this._mapper.getExtent()},getExtentUnsafe:function(t,n){return this._mapper.getExtentUnsafe(t,n)},setExtent:function(t,n){return this._mapper.setExtent(t,n)},setExtent2:function(t,n,i){return this._mapper.setExtent2(t,n,i)}},n}(bp);function Vp(t,n){for(var i=t.getTicks({expandToNicedExtent:!0}),r=[],e=t.getExtent(),a=1;a<i.length;a++){var o=i[a],u=i[a-1];if(!u.break&&!o.break){for(var s=0,l=[],f=(o.value-u.value)/n,h=Pp(f);s<n-1;){var c=ro(u.value+(s+1)*f,h);c>e[0]&&c<e[1]&&l.push(c),s++}r.push(l)}}return r}bp.registerClass(Up);var $p=function(t){function n(i){var r=t.call(this)||this;r.type="interval",r.parse=n.parse,Rc(0,i=i||{});var e=Sp(r,0,null);return r.brk=e.brk,r._cfg={interval:0,intervalPrecision:2,intervalCount:void 0,niceExtent:void 0},r}return v(n,t),n.parse=function(t){return null==t||""===t?NaN:Number(t)},n.prototype.getConfig=function(){return R(this._cfg)},n.prototype.setConfig=function(t){var n=Np(this);this._cfg=t=R(t),null==t.niceExtent&&(t.niceExtent=n.slice()),null==t.intervalPrecision&&(t.intervalPrecision=Pp(t.interval))},n.prototype.getTicks=function(t){t=t||{};var n=this._cfg,i=n.interval,r=Np(this),e=n.niceExtent,a=n.intervalPrecision,o=this.brk,u=[];if(!i)return u;r[0]<e[0]&&u.push({value:t.expandToNicedExtent?ro(e[0]-i,a):r[0]});for(var s=function(t,n){return Ya((n-t)/i)},l=n.intervalCount,f=e[0],h=0;;h++){if(null==l){if(f>e[1]||!isFinite(f)||!isFinite(e[1]))break}else{if(h>l)break;f=Ua(f,e[1]),h===l&&(f=e[1])}if(u.push({value:f}),f=ro(f+i,a),o){var c=o.calcNiceTickMultiple(f,s);c>=0&&(f=ro(f+c*i,a))}if(u.length>0&&f===u[u.length-1].value)break;if(u.length>3e3)return[]}var v=u.length?u[u.length-1].value:e[1];return r[1]>v&&u.push({value:t.expandToNicedExtent?ro(v+i,a):r[1]}),u},n.prototype.getMinorTicks=function(t){return Vp(this,t,Fc(this))},n.prototype.getLabel=function(t,n){if(null==t)return"";var i=n&&n.precision;return null==i?i=ao(t.value)||0:"auto"===i&&(i=this._cfg.intervalPrecision),cv(ro(t.value,i,!0))},n.type="interval",n}(bp);bp.registerClass($p);var Yp=function(t){function n(i){var r=t.call(this)||this;r.type="time",r.parse=n.parse,r._locale=i.locale,r._useUTC=i.useUTC,r._interval=0,Rc(0,i);var e=Sp(r,0,null);return r.brk=e.brk,r}return v(n,t),n.prototype.getLabel=function(t){return Gc(t.value,Vc[function(t){switch(t){case"year":case"month":return"day";case"millisecond":return"millisecond";default:return"second"}}(qc(this._minLevelUnit))]||Vc.second,this._useUTC,this._locale)},n.prototype.getFormattedLabel=function(t,n,i){return function(t,n,i,r,e){var a=null;if(J(i))a=i;else if(Z(i)){var o={time:t.time,level:t.time?t.time.level:0};a=i(t.value,n,o)}else{var u=t.time;if(u){var s=i[u.lowerTimeUnit][u.upperTimeUnit];a=s[Math.min(u.level,s.length-1)]||""}else{var l=Zc(t.value,e);a=i[l][l][0]}}return Gc(new Date(t.value),a,e,r)}(t,n,i,this._locale,this._useUTC)},n.prototype.getTicks=function(){var t=this._interval,n=Np(this),i=this.brk,r=[];if(!t)return r;r=function(t,n,i,r,e,a){var o,u=Yc,s=0;function l(t,n,i,e,o,u,l){for(var f=function(t,n){var i=new Date(0);i[t](1);var r=i.getTime();i[t](1+n);var e=i.getTime()-r;return function(t,n){return Math.max(0,Math.round((n-t)/e))}}(o,t),h=n,c=new Date(h);h<i&&h<=r[1]&&(l.push({value:h}),!(s++>3e3));)if(c[o](c[e]()+t),h=c.getTime(),a){var v=a.calcNiceTickMultiple(h,f);v>0&&(c[o](c[e]()+v*t),h=c.getTime())}l.push({value:h,notAdd:h>r[1]})}function f(t,e,a){var o=[],u=!e.length;if(!function(t,n,i,r){return Jc(new Date(n),t,r).getTime()===Jc(new Date(i),t,r).getTime()}(qc(t),r[0],r[1],i)){u&&(e=[{value:Qp(r[0],t,i)},{value:r[1]}]);for(var s=0;s<e.length-1;s++){var f=e[s].value,h=e[s+1].value;if(f!==h){var c=void 0,v=void 0,d=void 0;switch(t){case"year":c=Math.max(1,Math.round(n/Ec/365)),v=Kc(i),d=av(i);break;case"half-year":case"quarter":case"month":c=Gp(n),v=Qc(i),d=ov(i);break;case"week":case"half-week":case"day":c=qp(n),v=tv(i),d=uv(i);break;case"half-day":case"quarter-day":case"hour":c=Zp(n),v=nv(i),d=sv(i);break;case"minute":c=Jp(n,!0),v=iv(i),d=lv(i);break;case"second":c=Jp(n,!1),v=rv(i),d=fv(i);break;case"millisecond":c=Kp(n),v=ev(i),d=hv(i)}h>=r[0]&&f<=r[1]&&l(c,f,h,v,d,0,o),"year"===t&&a.length>1&&0===s&&a.unshift({value:a[0].value-c})}}for(s=0;s<o.length;s++)a.push(o[s])}}for(var h=[],c=[],v=0,d=0,p=0;p<u.length;++p){var m=qc(u[p]);if((o=u[p])===qc(o)&&(f(u[p],h[h.length-1]||[],c),m!==(u[p+1]?qc(u[p+1]):null))){if(c.length){d=v,c.sort((function(t,n){return t.value-n.value}));for(var y=[],g=0;g<c.length;++g){var b=c[g].value;0!==g&&c[g-1].value===b||(y.push(c[g]),b>=r[0]&&b<=r[1]&&v++)}var w=e/n;if(v>1.5*w&&d>w/1.5)break;if(h.push(y),v>w||t===u[p])break}c=[]}}var x=$(U(h,(function(t){return $(t,(function(t){return t.value>=r[0]&&t.value<=r[1]&&!t.notAdd}))})),(function(t){return t.length>0})),M=x.length-1,k=[];for(p=0;p<x.length;++p)for(var S=x[p],A=0;A<S.length;++A){var T=Zc(S[A].value,i);k.push({value:S[A].value,time:{level:M-p,upperTimeUnit:T,lowerTimeUnit:T}})}Ko(k,Qo,null),k.sort((function(t,n){return t.value-n.value}));var N=k[0],C=k[k.length-1],O=Zc(r[0],i),I=Zc(r[1],i);return(!N||N.value>r[0])&&k.unshift({value:r[0],time:{level:0,upperTimeUnit:O,lowerTimeUnit:O},notNice:!0}),(!C||C.value<r[1])&&k.push({value:r[1],time:{level:0,upperTimeUnit:I,lowerTimeUnit:I},notNice:!0}),k}(this._minLevelUnit,this._approxInterval,this._useUTC,n,Op(this),i);var e=$c.length-1;return H(r,(function(t){t.time&&(e=Math.min(e,E($c,t.time.upperTimeUnit)))})),r},n.prototype.getMinorTicks=function(t){return Vp(this,t,Fc(this))},n.prototype.setTimeInterval=function(t){this._interval=t.interval,this._approxInterval=t.approxInterval,this._minLevelUnit=t.minLevelUnit},n.parse=function(t){return Q(t)?Math.round(t):+ho(t)},n.type="time",n}(bp),Xp=[["second",1e3],["minute",6e4],["hour",Bc],["quarter-day",216e5],["half-day",432e5],["day",10368e4],["half-week",3024e5],["week",6048e5],["month",26784e5],["quarter",8208e6],["half-year",Wc/2],["year",Wc]];function qp(t){return(t/=Ec)>16?16:t>7.5?7:t>3.5?4:t>1.5?2:1}function Gp(t){return(t/=2592e6)>6?6:t>3?3:t>2?2:1}function Zp(t){return(t/=Bc)>12?12:t>6?6:t>3.5?4:t>2?2:1}function Jp(t,n){return(t/=n?6e4:1e3)>30?30:t>20?20:t>15?15:t>10?10:t>5?5:t>2?2:1}function Kp(t){return Va(po(t,!0),1)}function Qp(t,n,i){var r=Math.max(0,E($c,n)-1);return Jc(new Date(t),$c[r],i).getTime()}bp.registerClass(Yp);var tm=function(t){function n(i){var r=t.call(this)||this;r.type="log",r.parse=$p.parse,r.base=i.logBase||10;var e=[],a=[];r._lookup={from:e,to:a},e[0]=e[1]=a[0]=a[1]=NaN,Ap(r,n.mapperMethods);var o={};return r.powStub=new $p({breakParsed:o.original}),r.intervalStub=new $p({breakParsed:o.transformed}),Tp(r),r}return v(n,t),n.prototype.getTicks=function(t){var n=this.base,i=this.powStub,r=this.intervalStub,e={lookup:{from:r.getExtent(),to:i.getExtent()}};return U(r.getTicks(t||{}),(function(t){return{value:Ep(t.value,n,e),break:void 0}}),this)},n.prototype.getMinorTicks=function(t){return Vp(this,t,Fc(this.powStub),this.intervalStub.getConfig())},n.prototype.getLabel=function(t,n){return this.intervalStub.getLabel(t,n)},n.type="log",n.mapperMethods={needTransform:function(){return!0},normalize:function(t){return this.intervalStub.normalize(Bp(t,this.base))},scale:function(t){return Ep(this.intervalStub.scale(t),this.base,null)},transformIn:function(t,n){return t=Bp(t,this.base),n&&2===n.depth?t:this.intervalStub.transformIn(t,n)},transformOut:function(t,n){var i=n?n.depth:null;return nm.depth=i,im.lookup=this._lookup,Ep(2===i?t:this.intervalStub.transformOut(t,nm),this.base,im)},contain:function(t){return this.powStub.contain(t)},setExtent:function(t,n){this.setExtent2(0,t,n)},setExtent2:function(t,n,i){if(!(!Go(n,i)||n<=0||i<=0)){var r=rm,e=rm;if(0===t){var a=this._lookup;r=a.to,e=a.from}this.powStub.setExtent2(t,r[0]=n,r[1]=i);var o=this.base;this.intervalStub.setExtent2(t,e[0]=Bp(n,o),e[1]=Bp(i,o))}},getFilter:function(){return{g:0}},sanitize:function(t,n){return Go(n[0],n[1])&&wo(t)&&t<=0&&(t=n[0]),t},getDefaultStartValue:function(){return 1},getExtent:function(){return this.powStub.getExtent()},getExtentUnsafe:function(t,n){return null===n?this.powStub.getExtentUnsafe(t,null):this.intervalStub.getExtentUnsafe(t,n)}},n}(bp);bp.registerClass(tm);var nm={},im={},rm=[],em={value:1,category:1,time:1,log:1},am=Po();function om(t){var n=t.get("type");return null!=n&&(xt(em,n)||bp.getClass(n))||(n="value"),n}function um(t,n){var i;switch(n){case"category":return new Up({ordinalMeta:t.getOrdinalMeta?t.getOrdinalMeta():t.getCategories(),extent:[1/0,-1/0]});case"time":return new Yp({locale:t.ecModel.getLocaleModel(),useUTC:t.ecModel.get("useUTC"),breakOption:i});case"log":return new tm({logBase:t.get("logBase"),breakOption:i});case"value":return new $p({breakOption:i});default:return new(bp.getClass(n)||$p)({})}}function sm(t){var n,i=t.getLabelModel().get("formatter");if("time"===t.type){var r=J(n=i)||Z(n)?n:function(t){t=t||{};var n={},i=!0;return H($c,(function(n){i&&(i=null==t[n])})),H($c,(function(r,e){var a=t[r];n[r]={};for(var o=null,u=e;u>=0;u--){var s=$c[u],l=tt(a)&&!G(a)?a[s]:a,f=void 0;G(l)?o=(f=l.slice())[0]||"":J(l)?f=[o=l]:(null==o?o=Hc[r]:jc[s].test(o)||(o=n[s][s][0]+" "+o),f=[o],i&&(f[1]="{primary|"+o+"}")),n[r][s]=f}})),n}(n);return function(n,i){return t.scale.getFormattedLabel(n,i,r)}}if(J(i))return function(n){var r=t.scale.getLabel(n);return i.replace("{value}",null!=r?r:"")};if(Z(i)){if("category"===t.type)return function(n){return i(lm(t,n),n.value-t.scale.getExtent()[0],null)};return function(n,r){var e=null;return i(lm(t,n),r,e)}}return function(n){return t.scale.getLabel(n)}}function lm(t,n){var i=t.scale;return Fp(i)?i.getLabel(n):n.value}function fm(t){var n=t.get("interval");return null==n?"auto":n}function hm(t){return"middle"===t||"center"===t}function cm(t){return t.getShallow("show")}function vm(t,n,i,r,e,a){var o,u,s=Rp(t),l=s?t.intervalStub:t;if(l.setExtent(r[0],r[1]),s){var f=t.powStub,h={depth:2},c=t.transformOut(r[0],h),v=t.transformOut(r[1],h),d=[(o=i)[0]!==(u=r)[0],o[1]!==u[1]];n[0]&&!d[0]&&(c=e[0]),n[1]&&!d[1]&&(v=e[1]),f.setExtent(c,v)}l.setConfig(a)}function dm(t,n){return Fp(t)?t.getRawOrdinalNumber(n.value):n.value}function pm(t,n){return Fp(t)&&!!n.get("boundaryGap")}function mm(t,n){if(t.length===n.length){for(var i=0;i<t.length;i++)if(t[i]!==n[i])return;return!0}}function ym(t){for(var n=[1/0,-1/0],i=[1/0,-1/0],r=0;r<t.length;){var e=t[r++],a=t[r++];qd(e,a)||($o(n,e),$o(i,a))}return[n,i]}function gm(t,n){var i=ym(t),r=i[0],e=i[1],a=ym(n),o=a[0],u=a[1];return Math.max(Math.abs(r[0]-o[0]),Math.abs(e[0]-u[0]),Math.abs(r[1]-o[1]),Math.abs(e[1]-u[1]))}function bm(t){return Q(t)?t:t?.5:0}function wm(t,n,i,r,e){var a=i.getBaseAxis(),o="x"===a.dim||"radius"===a.dim?0:1,u=[],s=0,l=[],f=[],h=[],c=[];if(e){for(s=0;s<t.length;s+=2){var v=n||t;qd(v[s],v[s+1])||c.push(t[s],t[s+1])}t=c}for(s=0;s<t.length-2;s+=2)switch(h[0]=t[s+2],h[1]=t[s+3],f[0]=t[s],f[1]=t[s+1],u.push(f[0],f[1]),r){case"end":l[o]=h[o],l[1-o]=f[1-o],u.push(l[0],l[1]);break;case"middle":var d=[];l[o]=d[o]=(f[o]+h[o])/2,l[1-o]=f[1-o],d[1-o]=h[1-o],u.push(l[0],l[1]),u.push(d[0],d[1]);break;default:l[o]=f[o],l[1-o]=h[1-o],u.push(l[0],l[1])}return u.push(t[s++],t[s++]),u}function xm(t,n){return[t[2*n],t[2*n+1]]}function Mm(t){if(t.get(["endLabel","show"]))return!0;for(var n=0;n<Su.length;n++)if(t.get([Su[n],"endLabel","show"]))return!0;return!1}function km(t,n,i,r){if(gp(n,"cartesian2d")){var e=r.getModel("endLabel"),a=e.get("valueAnimation"),o=r.getData(),u={lastFrameIndex:0},s=Mm(r)?function(i,r){t._endLabelOnDuring(i,r,o,u,a,e,n)}:null,l=n.getBaseAxis().isHorizontal(),f=pp(n,i,r,(function(){var n=t._endLabel;n&&i&&null!=u.originalX&&n.attr({x:u.originalX,y:u.originalY})}),s);if(!r.get("clip",!0)){var h=f.shape,c=Math.max(h.width,h.height);l?(h.y-=c,h.height+=2*c):(h.x-=c,h.width+=2*c)}return s&&s(1,f),f}return mp(n,i,r)}var Sm=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return v(n,t),n.prototype.init=function(){var t=new Is,n=new $d;this.group.add(n.group),this._symbolDraw=n,this._lineGroup=t,this._changePolyState=X(this._changePolyState,this)},n.prototype.render=function(t,n,i){var r=t.coordinateSystem,e=this.group,a=t.getData(),o=t.getModel("lineStyle"),u=t.getModel("areaStyle"),s=a.getLayout("points")||[],l="polar"===r.type,f=this._coordSys,h=this._symbolDraw,c=this._polyline,v=this._polygon,d=this._lineGroup,p=!n.ssr&&t.get("animation"),m=!u.isEmpty(),y=u.get("origin"),g=Yd(r,a,y),b=m&&function(t,n,i){if(null==i.valueDim)return[];for(var r=n.count(),e=Jd(2*r),a=0;a<r;a++){var o=Xd(i,t,n,a);e[2*a]=o[0],e[2*a+1]=o[1]}return e}(r,a,g),w=t.get("showSymbol"),x=t.get("connectNulls"),M=w&&!l&&function(t,n,i){var r=t.get("showAllSymbol"),e="auto"===r;if(!r||e){var a=i.getAxesByScale("ordinal")[0];if(a&&(!e||!function(t,n){var i=t.getExtent(),r=Math.abs(i[1]-i[0])/t.scale.count();isNaN(r)&&(r=0);for(var e=n.count(),a=Math.max(1,Math.round(e/5)),o=0;o<e;o+=a)if(1.5*Ed.getSymbolSize(n,o)[t.isHorizontal()?1:0]>r)return!1;return!0}(a,n))){var o=n.mapDimension(a.dim),u={};return H(a.getViewLabels(),(function(t){t.tick.offInterval||(u[dm(a.scale,t.tick)]=1)})),function(t){return!u.hasOwnProperty(n.get(o,t))}}}}(t,a,r),k=this._data;k&&k.eachItemGraphicEl((function(t,n){t.__temp&&(e.remove(t),k.setItemGraphicEl(n,null))})),w||h.remove(),e.add(d);var S,A=!l&&t.get("step");r&&r.getArea&&t.get("clip",!0)&&(null!=(S=r.getArea()).width?(S.x-=.1,S.y-=.1,S.width+=.2,S.height+=.2):S.r0&&(S.r0-=.5,S.r+=.5)),this._clipShapeForSymbol=S;var T=function(t,n,i){var r=t.getVisual("visualMeta");if(r&&r.length&&t.count()&&"cartesian2d"===n.type){for(var e,a,o=r.length-1;o>=0;o--){var u=t.getDimensionInfo(r[o].dimension);if("x"===(e=u&&u.coordDim)||"y"===e){a=r[o];break}}if(a){var s=n.getAxis(e),l=U(a.stops,(function(t){return{coord:s.toGlobalCoord(s.dataToCoord(t.value)),color:t.color}})),f=l.length,h=a.outerColors.slice();f&&l[0].coord>l[f-1].coord&&(l.reverse(),h.reverse());var c=function(t,n){var i,r,e=[],a=t.length;function o(t,n,i){var r=t.coord;return{coord:i,color:function(t,n){if(n&&n.length&&t>=0&&t<=1){var i=t*(n.length-1),r=Math.floor(i),e=Math.ceil(i),a=or(n[r]),o=or(n[e]),u=i-r;return fr([Gi(tr(a[0],o[0],u)),Gi(tr(a[1],o[1],u)),Gi(tr(a[2],o[2],u)),Zi(tr(a[3],o[3],u))],"rgba")}}((i-r)/(n.coord-r),[t.color,n.color])}}for(var u=0;u<a;u++){var s=t[u],l=s.coord;if(l<0)i=s;else{if(l>n){r?e.push(o(r,s,n)):i&&e.push(o(i,s,0),o(i,s,n));break}i&&(e.push(o(i,s,0)),i=null),e.push(s),r=s}}return e}(l,"x"===e?i.getWidth():i.getHeight()),v=c.length;if(!v&&f)return l[0].coord<0?h[1]?h[1]:l[f-1].color:h[0]?h[0]:l[0].color;var d=c[0].coord-10,p=c[v-1].coord+10,m=p-d;if(m<.001)return"transparent";H(c,(function(t){t.offset=(t.coord-d)/m})),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 vl(0,0,0,0,c,!0);return y[e]=d,y[e+"2"]=p,y}}}(a,r,i)||a.getVisual("style")[a.getVisual("drawType")];if(c&&f.type===r.type&&A===this._step){m&&!v?v=this._newPolygon(s,b):v&&!m&&(d.remove(v),v=this._polygon=null),l||this._initOrUpdateEndLabel(t,r,bv(T));var N=d.getClipPath();N?Ol(N,{shape:km(this,r,!1,t).shape},t):d.setClipPath(km(this,r,!0,t)),w&&h.updateData(a,{isIgnore:M,clipShape:S,disableAnimation:!0,getSymbolPoint:function(t){return[s[2*t],s[2*t+1]]}}),mm(this._stackedOnPoints,b)&&mm(this._points,s)||(p?this._doUpdateAnimation(a,b,r,i,A,y,x):(A&&(b&&(b=wm(b,s,r,A,x)),s=wm(s,null,r,A,x)),c.setShape({points:s}),v&&v.setShape({points:s,stackedOnPoints:b})))}else w&&h.updateData(a,{isIgnore:M,clipShape:S,disableAnimation:!0,getSymbolPoint:function(t){return[s[2*t],s[2*t+1]]}}),p&&this._initSymbolLabelAnimation(a,r,S),A&&(b&&(b=wm(b,s,r,A,x)),s=wm(s,null,r,A,x)),c=this._newPolyline(s),m?v=this._newPolygon(s,b):v&&(d.remove(v),v=this._polygon=null),l||this._initOrUpdateEndLabel(t,r,bv(T)),d.setClipPath(km(this,r,!0,t));var C=t.getModel("emphasis"),O=C.get("focus"),I=C.get("blurScope"),L=C.get("disabled");c.useStyle(B(o.getLineStyle(),{fill:"none",stroke:T,lineJoin:"bevel"})),ss(c,t,"lineStyle"),c.style.lineWidth>0&&"bolder"===t.get(["emphasis","lineStyle","width"])&&(c.getState("emphasis").style.lineWidth=+c.style.lineWidth+1),au(c).seriesIndex=t.seriesIndex,as(c,O,I,L);var D=bm(t.get("smooth")),_=t.get("smoothMonotone");if(c.setShape({smooth:D,smoothMonotone:_,connectNulls:x}),v){var z=a.getCalculationInfo("stackedOnSeries"),R=0;v.useStyle(B(u.getAreaStyle(),{fill:T,opacity:.7,lineJoin:"bevel",decal:a.getVisual("style").decal})),z&&(R=bm(z.get("smooth"))),v.setShape({smooth:D,stackedOnSmooth:R,smoothMonotone:_,connectNulls:x}),ss(v,t,"areaStyle"),au(v).seriesIndex=t.seriesIndex,as(v,O,I,L)}var F=this._changePolyState;a.eachItemGraphicEl((function(t){t&&(t.onHoverStateChange=F)})),this._polyline.onHoverStateChange=F,this._data=a,this._coordSys=r,this._stackedOnPoints=b,this._points=s,this._step=A,this._valueOrigin=y;var P=t.get("triggerEvent"),E=t.get("triggerLineEvent"),W=!0===E||!0===P||"area"===P;this.packEventData(t,c,!0===E||!0===P||"line"===P),v&&this.packEventData(t,v,W)},n.prototype.packEventData=function(t,n,i){au(n).eventData=i?{componentType:"series",componentSubType:"line",componentIndex:t.componentIndex,seriesIndex:t.seriesIndex,seriesName:t.name,seriesType:"line",selfType:n===this._polygon?"area":"line"}:null},n.prototype.highlight=function(t,n,i,r){var e=t.getData(),a=Fo(e,r);if(this._changePolyState("emphasis"),!(a instanceof Array)&&null!=a&&a>=0){var o=e.getLayout("points"),u=e.getItemGraphicEl(a);if(!u){var s=o[2*a],l=o[2*a+1];if(qd(s,l))return;if(this._clipShapeForSymbol&&!this._clipShapeForSymbol.contain(s,l))return;var f=t.get("zlevel")||0,h=t.get("z")||0;(u=new Ed(e,a)).x=s,u.y=l,u.setZ(f,h);var c=u.getSymbolPath().getTextContent();c&&(c.zlevel=f,c.z=h,c.z2=this._polyline.z2+1),u.__temp=!0,e.setItemGraphicEl(a,u),u.stopSymbolAnimation(!0),this.group.add(u)}u.highlight()}else lp.prototype.highlight.call(this,t,n,i,r)},n.prototype.downplay=function(t,n,i,r){var e=t.getData(),a=Fo(e,r);if(this._changePolyState("normal"),null!=a&&a>=0){var o=e.getItemGraphicEl(a);o&&(o.__temp?(e.setItemGraphicEl(a,null),this.group.remove(o)):o.downplay())}else lp.prototype.downplay.call(this,t,n,i,r)},n.prototype._changePolyState=function(t){var n=this._polygon;Hu(this._polyline,t),n&&Hu(n,t)},n.prototype._newPolyline=function(t){var n=this._polyline;return n&&this._lineGroup.remove(n),n=new rp({shape:{points:t},segmentIgnoreThreshold:2,z2:10}),this._lineGroup.add(n),this._polyline=n,n},n.prototype._newPolygon=function(t,n){var i=this._polygon;return i&&this._lineGroup.remove(i),i=new ap({shape:{points:t,stackedOnPoints:n},segmentIgnoreThreshold:2}),this._lineGroup.add(i),this._polygon=i,i},n.prototype._initSymbolLabelAnimation=function(t,n,i){var r,e,a=n.getBaseAxis(),o=a.inverse;"cartesian2d"===n.type?(r=a.isHorizontal(),e=!1):"polar"===n.type&&(r="angle"===a.dim,e=!0);var u=t.hostModel,s=u.get("animationDuration");Z(s)&&(s=s(null));var l=u.get("animationDelay")||0,f=Z(l)?l(null):l;t.eachItemGraphicEl((function(t,a){var u=t;if(u){var h=void 0,c=void 0,v=void 0;if(i)if(e){var d=i,p=n.pointToCoord([t.x,t.y]);r?(h=d.startAngle,c=d.endAngle,v=-p[1]/180*Math.PI):(h=d.r0,c=d.r,v=p[0])}else r?(h=i.x,c=i.x+i.width,v=t.x):(h=i.y+i.height,c=i.y,v=t.y);var m=c===h?0:(v-h)/(c-h);o&&(m=1-m);var y=Z(l)?l(a):s*m+f,g=u.getSymbolPath(),b=g.getTextContent();u.attr({scaleX:0,scaleY:0}),u.animateTo({scaleX:1,scaleY:1},{duration:200,setToFinal:!0,delay:y}),b&&b.animateFrom({style:{opacity:0}},{duration:300,delay:y}),g.disableLabelAnimation=!0}}))},n.prototype._initOrUpdateEndLabel=function(t,n,i){var r=t.getModel("endLabel");if(Mm(t)){var e=t.getData(),a=this._polyline,o=e.getLayout("points");if(!o)return a.removeTextContent(),void(this._endLabel=null);var u=this._endLabel;u||((u=this._endLabel=new Ia({z2:200})).ignoreClip=!0,a.setTextContent(this._endLabel),a.disableLabelAnimation=!0);var s=function(t){for(var n=t.length/2;n>0&&qd(t[2*n-2],t[2*n-1]);n--);return n-1}(o);s>=0&&(yf(a,gf(t,"endLabel"),{inheritColor:i,labelFetcher:t,labelDataIndex:s,defaultText:function(t,n,i){return null!=i?Bd(e,i):Pd(e,t)},enableTextSetter:!0},function(t,n){var i=n.getBaseAxis(),r=i.isHorizontal(),e=i.inverse,a=r?e?"right":"left":"center",o=r?"middle":e?"top":"bottom";return{normal:{align:t.get("align")||a,verticalAlign:t.get("verticalAlign")||o}}}(r,n)),a.textConfig.position=null)}else this._endLabel&&(this._polyline.removeTextContent(),this._endLabel=null)},n.prototype._endLabelOnDuring=function(t,n,i,r,e,a,o){var u=this._endLabel,s=this._polyline;if(u){t<1&&null==r.originalX&&(r.originalX=u.x,r.originalY=u.y);var l=i.getLayout("points"),f=i.hostModel,h=f.get("connectNulls"),c=a.get("precision"),v=a.get("distance")||0,d=o.getBaseAxis(),p=d.isHorizontal(),m=d.inverse,y=n.shape,g=m?p?y.x:y.y+y.height:p?y.x+y.width:y.y,b=(p?v:0)*(m?-1:1),w=(p?0:-v)*(m?-1:1),x=p?"x":"y",M=function(t,n,i){for(var r,e,a=t.length/2,o="x"===i?0:1,u=0,s=-1,l=0;l<a;l++)if(!qd(e=t[2*l+o],t[2*l+1-o]))if(0!==l){if(r<=n&&e>=n||r>=n&&e<=n){s=l;break}u=l,r=e}else r=e;return{range:[u,s],t:(n-r)/(e-r)}}(l,g,x),k=M.range,S=k[1]-k[0],A=void 0;if(S>=1){if(S>1&&!h){var T=xm(l,k[0]);u.attr({x:T[0]+b,y:T[1]+w}),e&&(A=f.getRawValue(k[0]))}else{(T=s.getPointOn(g,x))&&u.attr({x:T[0]+b,y:T[1]+w});var N=f.getRawValue(k[0]),C=f.getRawValue(k[1]);e&&(A=Vo(i,c,N,C,M.t))}r.lastFrameIndex=k[0]}else{var O=1===t||r.lastFrameIndex>0?k[0]:0;T=xm(l,O),e&&(A=f.getRawValue(O)),u.attr({x:T[0]+b,y:T[1]+w})}if(e){var I=Af(u);"function"==typeof I.setLabelText&&I.setLabelText(A)}}},n.prototype._doUpdateAnimation=function(t,n,i,r,e,a,o){var u=this._polyline,s=this._polygon,l=t.hostModel,f=function(t,n,i,r,e,a,o){for(var u=function(t,n){var i=[];return n.diff(t).add((function(t){i.push({cmd:"+",idx:t})})).update((function(t,n){i.push({cmd:"=",idx:n,idx1:t})})).remove((function(t){i.push({cmd:"-",idx:t})})).execute(),i}(t,n),s=[],l=[],f=[],h=[],c=[],v=[],d=[],p=Yd(e,n,o),m=t.getLayout("points")||[],y=n.getLayout("points")||[],g=0;g<u.length;g++){var b=u[g],w=!0,x=void 0,M=void 0;switch(b.cmd){case"=":var k=m[x=2*b.idx],S=m[x+1],A=y[M=2*b.idx1],T=y[M+1];(isNaN(k)||isNaN(S))&&(k=A,S=T),s.push(k,S),l.push(A,T),f.push(i[x],i[x+1]),h.push(r[M],r[M+1]),d.push(n.getRawIndex(b.idx1));break;case"+":var N=b.idx,C=p.dataDimsForPoint,O=e.dataToPoint([n.get(C[0],N),n.get(C[1],N)]);M=2*N,s.push(O[0],O[1]),l.push(y[M],y[M+1]);var I=Xd(p,e,n,N);f.push(I[0],I[1]),h.push(r[M],r[M+1]),d.push(n.getRawIndex(N));break;case"-":w=!1}w&&(c.push(b),v.push(v.length))}v.sort((function(t,n){return d[t]-d[n]}));var L=s.length,D=Jd(L),_=Jd(L),z=Jd(L),R=Jd(L),F=[];for(g=0;g<v.length;g++){var P=v[g],B=2*g,E=2*P;D[B]=s[E],D[B+1]=s[E+1],_[B]=l[E],_[B+1]=l[E+1],z[B]=f[E],z[B+1]=f[E+1],R[B]=h[E],R[B+1]=h[E+1],F[g]=c[P]}return{current:D,next:_,stackedOnCurrent:z,stackedOnNext:R,status:F}}(this._data,t,this._stackedOnPoints,n,this._coordSys,0,this._valueOrigin),h=f.current,c=f.stackedOnCurrent,v=f.next,d=f.stackedOnNext;if(e&&(c=wm(f.stackedOnCurrent,f.current,i,e,o),h=wm(f.current,null,i,e,o),d=wm(f.stackedOnNext,f.next,i,e,o),v=wm(f.next,null,i,e,o)),gm(h,v)>3e3||s&&gm(c,d)>3e3)return u.stopAnimation(),u.setShape({points:v}),void(s&&(s.stopAnimation(),s.setShape({points:v,stackedOnPoints:d})));u.shape.__points=f.current,u.shape.points=h;var p={shape:{points:v}};f.current!==h&&(p.shape.__points=f.next),u.stopAnimation(),Cl(u,p,l),s&&(s.setShape({points:h,stackedOnPoints:c}),s.stopAnimation(),Cl(s,{shape:{stackedOnPoints:d}},l),u.shape.points!==s.shape.points&&(s.shape.points=u.shape.points));for(var m=[],y=f.status,g=0;g<y.length;g++)if("="===y[g].cmd){var b=t.getItemGraphicEl(y[g].idx1);b&&m.push({el:b,ptIdx:g})}u.animators&&u.animators.length&&u.animators[0].during((function(){s&&s.dirtyShape();for(var t=u.shape.__points,n=0;n<m.length;n++){var i=m[n].el,r=2*m[n].ptIdx;i.x=t[r],i.y=t[r+1],i.markRedraw()}}))},n.prototype.remove=function(){var t=this.group,n=this._data;this._lineGroup.removeAll(),this._symbolDraw.remove(!0),n&&n.eachItemGraphicEl((function(i,r){i.__temp&&(t.remove(i),n.setItemGraphicEl(r,null))})),this._polyline=this._polygon=this._coordSys=this._points=this._stackedOnPoints=this._endLabel=this._data=null},n.type="line",n}(lp);function Am(t,n){return{seriesType:t,plan:op(),reset:function(t){var i=t.getData(),r=t.coordinateSystem,e=n||t.pipelineContext.large;if(r){var a=U(r.dimensions,(function(t){return i.mapDimension(t)})).slice(0,2),o=a.length,u=i.getCalculationInfo("stackResultDimension");dc(i,a[0])&&(a[0]=u),dc(i,a[1])&&(a[1]=u);var s=i.getStore(),l=i.getDimensionIndex(a[0]),f=i.getDimensionIndex(a[1]);return o&&{progress:function(t,n){for(var i=e&&Jd((t.end-t.start)*o),a=[],u=[],h=t.start,c=0;h<t.end;h++){var v=void 0;if(1===o){var d=s.get(l,h);v=r.dataToPoint(d,null,u)}else a[0]=s.get(l,h),a[1]=s.get(f,h),v=r.dataToPoint(a,null,u);e?(i[c++]=v[0],i[c++]=v[1]):n.setItemLayout(h,v.slice())}e&&(n.setLayout("points",i),n.setLayout("pointsRange",{start:t.start,end:t.end}))}}}}}}var Tm={average:function(t){for(var n=0,i=0,r=0;r<t.length;r++)isNaN(t[r])||(n+=t[r],i++);return 0===i?NaN:n/i},sum:function(t){for(var n=0,i=0;i<t.length;i++)n+=t[i]||0;return n},max:function(t){for(var n=-1/0,i=0;i<t.length;i++)t[i]>n&&(n=t[i]);return isFinite(n)?n:NaN},min:function(t){for(var n=1/0,i=0;i<t.length;i++)t[i]<n&&(n=t[i]);return isFinite(n)?n:NaN},nearest:function(t){return t[0]}},Nm=function(t){return Math.round(t.length/2)};function Cm(t){return{seriesType:t,reset:function(t,n,i){var r=t.getData(),e=t.get("sampling"),a=t.coordinateSystem,o=r.count();if(o>10&&"cartesian2d"===a.type&&e){var u=a.getBaseAxis(),s=a.getOtherAxis(u),l=u.getExtent(),f=i.getDevicePixelRatio(),h=Math.abs(l[1]-l[0])*(f||1),c=Math.round(o/h);if(isFinite(c)&&c>1){"lttb"===e?t.setData(r.lttbDownSample(r.mapDimension(s.dim),1/c)):"minmax"===e&&t.setData(r.minmaxDownSample(r.mapDimension(s.dim),1/c));var v=void 0;J(e)?v=Tm[e]:Z(e)&&(v=e),v&&t.setData(r.downSample(r.mapDimension(s.dim),1/c,v,Nm))}}}}}var Om=Po(),Im=Po();function Lm(t){return{out:{noPxChangeTryDetermine:[]},kind:t}}function Dm(t,n){var i=n.getExtent(),r=[];return H(t,(function(t){(t=n.parse(t))>=i[0]&&t<=i[1]&&r.push(t)})),Ko(r,tu,null),eo(r),U(r,(function(t){return{value:t}}))}function _m(t,n,i){var r,e,a=Rm(t),o=fm(n),u=1===i.kind;if(!u){var s=Pm(a,o);if(s)return s}Z(o)?r=jm(t,o,!1):(e="auto"===o?function(t,n){if(1===n.kind){var i=t.calculateCategoryInterval(n);return n.out.noPxChangeTryDetermine.push((function(){return Im(t).autoInterval=i,!0})),i}var r=Im(t).autoInterval;return null!=r?r:Im(t).autoInterval=t.calculateCategoryInterval(n)}(t,i):o,r=jm(t,e,!1));var l={labels:r,labelCategoryInterval:e};return u?i.out.noPxChangeTryDetermine.push((function(){return Bm(a,o,l),!0})):Bm(a,o,l),l}var zm=Fm("axisTick"),Rm=Fm("axisLabel");function Fm(t){return function(n){return Im(n)[t]||(Im(n)[t]={list:[]})}}function Pm(t,n){for(var i=0;i<t.list.length;i++)if(t.list[i].key===n)return t.list[i].value}function Bm(t,n,i){return t.list.push({key:n,value:i}),i}function Em(t,n,i){return null==Wm(t,n,i)}function Wm(t,n,i){var r=Om(t.model),e=t.getExtent(),a=r.lastAutoInterval,o=r.lastTickCount;if(null!=a&&null!=o&&Math.abs(a-n)<=1&&Math.abs(o-i)<=1&&a>n&&r.axisExtent0===e[0]&&r.axisExtent1===e[1])return a;r.lastTickCount=i,r.lastAutoInterval=n,r.axisExtent0=e[0],r.axisExtent1=e[1]}function jm(t,n,i){var r=sm(t),e=t.scale,a=[],o=Z(n);return Hp(e,o?0:n,(function(t,u){var s=e.getLabel(t);if(o){var l=!!n(t.value,s);if(t.offInterval=!l,!l&&!u)return}a.push(i?t:{formattedLabel:r(t),rawLabel:s,tick:t})})),a}var Hm=Po();function Um(t){return Hm(t).fullUpdate}var Vm=Zo(),$m="|&",Ym=Po(),Xm=Po();function qm(t,n){var i=t.model,r=Ym(Um(i.ecModel)).keyed,e=r&&r.get(n);return e&&e.get(i.uid)}function Gm(t,n){return Jm(qm(t,n))}function Zm(t,n){var i=Ym(Um(t)).keyed;i&&i.each((function(t,i){t.each((function(t,r){n(t,i,r)}))}))}function Jm(t){return{liPosMinGap:t?t.liPosMinGap:void 0}}function Km(t,n,i){var r=qm(t,n);r&&Qm(t.model.ecModel,r.sers,i)}function Qm(t,n,i){if(n)for(var r=0;r<n.length;r++){var e=n[r];t.isSeriesFiltered(e)||i(e)}}function ty(t,n,i){var r=Ym(Um(t)).keyed,e=r&&r.get(n);e&&e.each((function(t){i(t.axis)}))}function ny(t,n){var i=t.model,r=Ym(Um(i.ecModel)).keys;r&&H(r.get(i.uid),(function(t){n(t)}))}function iy(t){var n=Xm(function(t){return Hm(t).prepare}(t)),i=n.keyed||(n.keyed=bt());Zm(t,(function(n,r,e){var a=i.get(r)||i.set(r,bt()),o=a.get(e)||a.set(e,{});n.metrics.liPosMinGap&&ry.liPosMinGap(t,n,o)}))}var ry={};function ey(t,n,i){if(t){var r=Ym(Um(n.ecModel)),e=t.model.uid,a=r.axSer||(r.axSer=bt());(a.get(e)||a.set(e,[])).push(n);var o=n.subType,u=n.getBaseAxis()===t,s=oy.get(ay(o,u,i))||oy.get(ay(o,u,null));if(s){var l=r.keyed||(r.keyed=bt()),f=r.keys||(r.keys=bt()),h=s.key,c=l.get(h)||l.set(h,bt()),v=c.get(e);v||((v=c.set(e,{axis:t,sers:[],serByIdx:[]})).metrics=s.getMetrics(t),(f.get(e)||f.set(e,[])).push(h)),v.sers.push(n),v.serByIdx[n.seriesIndex]=n}}}function ay(t,n,i){return t+$m+ut(n,!0)+$m+(i||"")}var oy=bt();function uy(t,n){var i,r={w:NaN,w2:NaN},e=t.scale,a=(n=n||{}).fromStat,o=n.min,u=(i=Cp(e,3))[1]-i[0];wo(u)||(u=NaN);var s=t.getExtent(),l=$a(s[1]-s[0]);return Fp(e)?function(t,n,i,r){var e=n.onBand,a=i+(e?1:0);0===a&&(a=1),t.w=r/a,!e&&i&&r&&(t.w2=t.w*i/r)}(r,t,u,l):a&&function(t,n,i,r,e){var a=!1,o=-1/0;H(e.key?[Gm(n,e.key)]:function(t,n){var i=[];return Zm(t.model.ecModel,(function(t){for(var r=0;r<n.length;r++)n[r]&&t.serByIdx[n[r].seriesIndex]&&i.push(Jm(t))})),i}(n,e.sers||[]),(function(t){var n=t.liPosMinGap;null!=n&&(n>0?(n>o&&(o=n),a=!1):-2===n&&(a=!0))})),wo(i)&&i>0&&wo(o)?(t.w=r/i*o,t.w2=o):a&&(t.w=.8*r,t.w2=t.w*i/r)}(r,t,u,l,a),null!=o&&(r.w=wo(r.w)?Va(o,r.w):o),r}var sy=[0,1],ly=function(){function t(t,n,i){this.onBand=!1,this.inverse=!1,this.dim=t,this.scale=n,this._extent=i||[0,0]}return t.prototype.contain=function(t){var n=this._extent,i=Math.min(n[0],n[1]),r=Math.max(n[0],n[1]);return t>=i&&t<=r},t.prototype.containData=function(t){return this.scale.contain(this.scale.parse(t))},t.prototype.getExtent=function(){return this._extent.slice()},t.prototype.setExtent=function(t,n){var i=this._extent;i[0]=t,i[1]=n},t.prototype.dataToCoord=function(t,n){var i=this.scale;return to(t=i.normalize(i.parse(t)),sy,fy(this),n)},t.prototype.coordToData=function(t,n){var i=to(t,fy(this),sy,n);return this.scale.scale(i)},t.prototype.pointToData=function(){},t.prototype.getTicksCoords=function(t){var n=(t=t||{}).tickModel||this.getTickModel(),i=U(function(t,n,i){var r=t.scale,e=t.getTickModel().get("customValues");return e?{ticks:Dm(e,r)}:"category"===t.type?function(t,n){var i,r,e=zm(t),a=fm(n),o=Pm(e,a);if(o)return o;if(n.get("show")&&!t.scale.isBlank()||(i=[]),Z(a))i=jm(t,a,!0);else if("auto"===a){var u=_m(t,t.getLabelModel(),Lm(2));r=u.labelCategoryInterval,i=U(u.labels,(function(t){return t.tick}))}else i=jm(t,r=a,!0);return Bm(e,a,{ticks:i,tickCategoryInterval:r})}(t,n):{ticks:r.getTicks(i)}}(this,n,{breakTicks:t.breakTicks,pruneByBreak:t.pruneByBreak}).ticks,(function(t){return{coord:this.dataToCoord(dm(this.scale,t)),tick:t}}),this),r=function(t,n,i){var r=n.length;if(!t.onBand||i||!r)return!1;var e=uy(t).w;if(!e)return!1;H(n,(function(t){t.coord-=e/2}));var a=t.scale.getExtent(),o=n[r-1];return o.tick.offInterval&&n.pop(),n.push({coord:o.coord+e,tick:{value:a[1]+1}}),!0}(this,i,n.get("alignWithLabel"));return U(i,(function(t){return{coord:t.coord,tickValue:t.tick.value,onBand:r}}))},t.prototype.getMinorTicksCoords=function(){if(Fp(this.scale))return[];var t=this.model.getModel("minorTick").get("splitNumber");return t>0&&t<100||(t=5),U(this.scale.getMinorTicks(t),(function(t){return U(t,(function(t){return{coord:this.dataToCoord(t),tickValue:t}}),this)}),this)},t.prototype.getViewLabels=function(t){return function(t,n){var i=t.getLabelModel().get("customValues");if(i){var r=t.scale;return{labels:U(Dm(i,r),(function(n,i){return{formattedLabel:sm(t)(n,i),rawLabel:r.getLabel(n),tick:n}}))}}return"category"===t.type?function(t,n){var i=t.getLabelModel(),r=_m(t,i,n);return!i.get("show")||t.scale.isBlank()?{labels:[]}:r}(t,n):function(t){var n=t.scale.getTicks(),i=sm(t);return{labels:U(n,(function(n,r){return{formattedLabel:i(n,r),rawLabel:t.scale.getLabel(n),tick:n}}))}}(t)}(this,t=t||Lm(2)).labels},t.prototype.getLabelModel=function(){return this.model.getModel("axisLabel")},t.prototype.getTickModel=function(){return this.model.getModel("axisTick")},t.prototype.getBandWidth=function(){return uy(this,{min:1}).w},t.prototype.calculateCategoryInterval=function(t){return function(t,n){var i=n.kind,r=function(t){var n=t.getLabelModel();return{axisRotate:t.getRotate?t.getRotate():t.isHorizontal&&!t.isHorizontal()?90:0,labelRotate:n.get("rotate")||0,font:n.getFont()}}(t),e=sm(t),a=(r.axisRotate-r.labelRotate)/180*Math.PI,o=t.scale,u=o.getExtent(),s=o.count();if(u[1]-u[0]<1)return 0;var l=1;s>40&&(l=Math.max(1,Math.floor(s/40)));for(var f=u[0],h=t.dataToCoord(f+1)-t.dataToCoord(f),c=Math.abs(h*Math.cos(a)),v=Math.abs(h*Math.sin(a)),d=0,p=0;f<=u[1];f+=l){var m,y=Un(e({value:f}),r.font,"center","top");m=1.3*y.height,d=Math.max(d,1.3*y.width,7),p=Math.max(p,m,7)}var g=d/c,b=p/v;isNaN(g)&&(g=1/0),isNaN(b)&&(b=1/0);var w=Math.max(0,Math.floor(Math.min(g,b)));if(1===i)return n.out.noPxChangeTryDetermine.push(X(Em,null,t,w,s)),w;var x=Wm(t,w,s);return null!=x?x:w}(this,t=t||Lm(2))},t}();function fy(t){var n=t.getExtent();if(t.onBand){var i=(n[1]-n[0])/t.scale.count()/2;n[0]+=i,n[1]-=i}return n}var hy=function(t){function n(n,i,r,e,a){var o=t.call(this,n,i,r)||this;return o.index=0,o.type=e||"value",o.position=a||"bottom",o}return v(n,t),n.prototype.isHorizontal=function(){var t=this.position;return"top"===t||"bottom"===t},n.prototype.getGlobalExtent=function(t){var n=this.getExtent();return n[0]=this.toGlobalCoord(n[0]),n[1]=this.toGlobalCoord(n[1]),t&&n[0]>n[1]&&n.reverse(),n},n.prototype.pointToData=function(t,n){return this.coordToData(this.toLocalCoord(t["x"===this.dim?0:1]),n)},n.prototype.setCategorySortInfo=function(t){if("category"!==this.type)return!1;this.model.option.categorySortInfo=t,this.scale.setSortInfo(t)},n}(ly),cy=["label","labelLine","layoutOption","priority","defaultAttr","marginForce","minMarginForce","marginDefault","suggestIgnore"];function vy(t,n,i){i=i||3,n?t.dirty|=i:t.dirty&=~i}function dy(t,n){return n=n||3,null==t.dirty||!!(t.dirty&n)}function py(t){if(t)return dy(t)&&my(t,t.label,t),t}function my(t,n,i){var r=n.getComputedTransform();t.transform=sf(t.transform,r);var e=t.localRect=uf(t.localRect,n.getBoundingRect()),a=n.style,o=a.margin,u=i&&i.marginForce,s=i&&i.minMarginForce,l=i&&i.marginDefault,f=a.__marginType;null==f&&l&&(o=l,f=Of.textMargin);for(var h=0;h<4;h++)yy[h]=f===Of.minMargin&&s&&null!=s[h]?s[h]:u&&null!=u[h]?u[h]:o?o[h]:0;f===Of.textMargin&&Kl(e,yy,!1,!1);var c=t.rect=uf(t.rect,e);return r&&c.applyTransform(r),f===Of.minMargin&&Kl(c,yy,!1,!1),t.axisAligned=af(r),(t.label=t.label||{}).ignore=n.ignore,vy(t,!1),vy(t,!0,2),t}var yy=[0,0,0,0];function gy(t,n){for(var i=0;i<cy.length;i++){var r=cy[i];null==t[r]&&(t[r]=n[r])}return py(t)}function by(t){var n=t.obb;return n&&!dy(t,2)||(t.obb=n=n||new kl,n.fromBoundingRect(t.localRect,t.transform),vy(t,!1,2)),n}function wy(t,n,i,r){return!(!t||!n)&&!(t.label&&t.label.ignore||n.label&&n.label.ignore)&&!!t.rect.intersect(n.rect,i,r)&&(!(!t.axisAligned||!n.axisAligned)||by(t).intersect(by(n),i,r))}var xy=Math.PI,My=[[1,2,1,2],[5,3,5,3],[8,3,8,3]],ky=[[0,1,0,1],[0,3,0,3],[0,3,0,3]],Sy=Po(),Ay=Po(),Ty=function(){function t(t){this.recordMap={},this.resolveAxisNameOverlap=t}return t.prototype.ensureRecord=function(t){var n=t.axis.dim,i=t.componentIndex,r=this.recordMap,e=r[n]||(r[n]=[]);return e[i]||(e[i]={ready:{}})},t}(),Ny=[1,0,0,1,0,0],Cy=new On(0,0,0,0),Oy=function(t,n,i,r,e,a){if(hm(t.nameLocation)){var o=a.stOccupiedRect;o&&Iy(function(t,n,i){return t.transform=sf(t.transform,i),t.localRect=uf(t.localRect,n),t.rect=uf(t.rect,n),i&&t.rect.applyTransform(i),t.axisAligned=af(i),t.obb=void 0,(t.label=t.label||{}).ignore=!1,t}({},o,a.transGroup.transform),r,e)}else Ly(a.labelInfoList,a.dirVec,r,e)};function Iy(t,n,i){var r=new pn;wy(t,n,r,{direction:Math.atan2(i.y,i.x),bidirectional:!1,touchThreshold:.05})&&function(t,n){if(t){t.label.x+=n.x,t.label.y+=n.y,t.label.markRedraw();var i=t.transform;i&&(i[4]+=n.x,i[5]+=n.y);var r=t.rect;r&&(r.x+=n.x,r.y+=n.y);var e=t.obb;e&&e.fromBoundingRect(t.localRect,i)}}(n,r)}function Ly(t,n,i,r){for(var e=pn.dot(r,n)>=0,a=0,o=t.length;a<o;a++){var u=t[e?a:o-1-a];u.label.ignore||Iy(u,i,r)}}var Dy=function(){function t(t,n,i,r){this.group=new Is,this._axisModel=t,this._api=n,this._local={},this._shared=r||new Ty(Oy),this._resetCfgDetermined(i)}return t.prototype.updateCfg=function(t){var n=this._cfg.raw;n.position=t.position,n.labelOffset=t.labelOffset,this._resetCfgDetermined(n)},t.prototype.__getRawCfg=function(){return this._cfg.raw},t.prototype._resetCfgDetermined=function(t){var n=this._axisModel,i=n.getDefaultOption?n.getDefaultOption():{},r=ut(t.axisName,n.get("name")),e=n.get("nameMoveOverlap");null!=e&&"auto"!==e||(e=ut(t.defaultNameMoveOverlap,!0));var a={raw:t,position:t.position,rotation:t.rotation,nameDirection:ut(t.nameDirection,1),tickDirection:ut(t.tickDirection,1),labelDirection:ut(t.labelDirection,1),labelOffset:ut(t.labelOffset,0),silent:ut(t.silent,!0),axisName:r,nameLocation:st(n.get("nameLocation"),i.nameLocation,"end"),shouldNameMoveOverlap:Uy(r)&&e,optionHideOverlap:n.get(["axisLabel","hideOverlap"]),showMinorTicks:n.get(["minorTick","show"])};this._cfg=a;var o=new Is({x:a.position[0],y:a.position[1],rotation:a.rotation});o.updateTransform(),this._transformGroup=o;var u=this._shared.ensureRecord(n);u.transGroup=this._transformGroup,u.dirVec=new pn(Math.cos(-a.rotation),Math.sin(-a.rotation))},t.prototype.build=function(t,n){var i=this;return t||(t={axisLine:!0,axisTickLabelEstimate:!1,axisTickLabelDetermine:!0,axisName:!0}),H(_y,(function(r){t[r]&&zy[r](i._cfg,i._local,i._shared,i._axisModel,i.group,i._transformGroup,i._api,n||{})})),this},t.innerTextLayout=function(t,n,i){var r,e,a=so(n-t);return lo(a)?(e=i>0?"top":"bottom",r="center"):lo(a-xy)?(e=i>0?"bottom":"top",r="center"):(e="middle",r=a>0&&a<xy?i>0?"right":"left":i>0?"left":"right"),{rotation:a,textAlign:r,textVerticalAlign:e}},t.makeAxisEventDataBase=function(t){var n={componentType:t.mainType,componentIndex:t.componentIndex};return n[t.mainType+"Index"]=t.componentIndex,n},t.isLabelSilent=function(t){var n=t.get("tooltip");return t.get("silent")||!(t.get("triggerEvent")||n&&n.show)},t}(),_y=["axisLine","axisTickLabelEstimate","axisTickLabelDetermine","axisName"],zy={axisLine:function(t,n,i,r,e,a){var o=r.get(["axisLine","show"]);if("auto"===o&&(o=!0,null!=t.raw.axisLineAutoShow&&(o=!!t.raw.axisLineAutoShow)),o){var u=r.axis.getExtent(),s=a.transform,l=[u[0],0],f=[u[1],0],h=l[0]>f[0];s&&(hn(l,l,s),hn(f,f,s));var c=P({lineCap:"round"},r.getModel(["axisLine","lineStyle"]).getLineStyle()),v={strokeContainThreshold:t.raw.strokeContainThreshold||5,silent:!0,z2:1,style:c};if(r.get(["axisLine","breakLine"])&&Pc(r.axis.scale))null.buildAxisBreakLine(r,e,a,v);else{var d=new el(P({shape:{x1:l[0],y1:l[1],x2:f[0],y2:f[1]}},v));Vl(d.shape,d.style.lineWidth),d.anid="line",e.add(d)}var p=r.get(["axisLine","symbol"]);if(null!=p){var m=r.get(["axisLine","symbolSize"]);J(p)&&(p=[p,p]),(J(m)||Q(m))&&(m=[m,m]);var y=Rd(r.get(["axisLine","symbolOffset"])||0,m),g=m[0],b=m[1];H([{rotate:t.rotation+Math.PI/2,offset:y[0],r:0},{rotate:t.rotation-Math.PI/2,offset:y[1],r:Math.sqrt((l[0]-f[0])*(l[0]-f[0])+(l[1]-f[1])*(l[1]-f[1]))}],(function(n,i){if("none"!==p[i]&&null!=p[i]){var r=zd(p[i],-g/2,-b/2,g,b,c.stroke,!0),a=n.r+n.offset,o=h?f:l;r.attr({rotation:n.rotate,x:o[0]+a*Math.cos(t.rotation),y:o[1]-a*Math.sin(t.rotation),silent:!0,z2:11}),e.add(r)}}))}}},axisTickLabelEstimate:function(t,n,i,r,e,a,o,u){By(n,e,u)&&Ry(t,n,i,r,e,a,o,1)},axisTickLabelDetermine:function(t,n,i,r,e,a,o,u){By(n,e,u)&&Ry(t,n,i,r,e,a,o,2);var s=function(t,n,i,r){var e=r.axis,a=r.getModel("axisTick"),o=a.get("show");if("auto"===o&&(o=!0,null!=t.raw.axisTickAutoShow&&(o=!!t.raw.axisTickAutoShow)),!o||e.scale.isBlank())return[];for(var u=a.getModel("lineStyle"),s=t.tickDirection*a.get("length"),l=Py(e.getTicksCoords(),i.transform,s,B(u.getLineStyle(),{stroke:r.get(["axisLine","lineStyle","color"])}),"ticks"),f=0;f<l.length;f++)n.add(l[f]);return l}(t,e,a,r);!function(t,n,i){t.showMinorTicks||H(n,(function(t){if(t&&t.label.ignore)for(var n=0;n<i.length;n++){var r=i[n],e=Ay(r),a=Sy(t.label);if(null!=e.tickValue&&!e.onBand&&e.tickValue===a.labelInfo.tick.value)return void Fy(r)}}))}(t,n.labelLayoutList,s),function(t,n,i,r,e){var a=r.axis,o=r.getModel("minorTick");if(t.showMinorTicks&&!a.scale.isBlank()){var u=a.getMinorTicksCoords();if(u.length)for(var s=o.getModel("lineStyle"),l=e*o.get("length"),f=B(s.getLineStyle(),B(r.getModel("axisTick").getLineStyle(),{stroke:r.get(["axisLine","lineStyle","color"])})),h=0;h<u.length;h++)for(var c=Py(u[h],i.transform,l,f,"minorticks_"+h),v=0;v<c.length;v++)n.add(c[v])}}(t,e,a,r,t.tickDirection)},axisName:function(t,n,i,r,e,a,o,u){var s=i.ensureRecord(r);n.nameEl&&(e.remove(n.nameEl),n.nameEl=s.nameLayout=s.nameLocation=null);var l=t.axisName;if(Uy(l)){var f=t.nameLocation,h=t.nameDirection,c=r.getModel("nameTextStyle"),v=r.get("nameGap")||0,d=r.axis.getExtent(),p=r.axis.inverse?-1:1,m=new pn(0,0),y=new pn(0,0);"start"===f?(m.x=d[0]-p*v,y.x=-p):"end"===f?(m.x=d[1]+p*v,y.x=p):(m.x=(d[0]+d[1])/2,m.y=t.labelOffset+h*v,y.y=h);var g=[1,0,0,1,0,0];y.transform(Kt(g,g,t.rotation));var b,w,x=r.get("nameRotate");null!=x&&(x=x*xy/180),hm(f)?b=Dy.innerTextLayout(t.rotation,null!=x?x:t.rotation,h):(b=function(t,n,i,r){var e,a,o=so(i-t),u=r[0]>r[1],s="start"===n&&!u||"start"!==n&&u;return lo(o-xy/2)?(a=s?"bottom":"top",e="center"):lo(o-1.5*xy)?(a=s?"top":"bottom",e="center"):(a="middle",e=o<1.5*xy&&o>xy/2?s?"left":"right":s?"right":"left"),{rotation:o,textAlign:e,textVerticalAlign:a}}(t.rotation,f,x||0,d),null!=(w=t.raw.axisNameAvailableWidth)&&(w=Math.abs(w/Math.sin(b.rotation)),!isFinite(w)&&(w=null)));var M=c.getFont(),k=r.get("nameTruncate",!0)||{},S=k.ellipsis,A=ot(t.raw.nameTruncateMaxWidth,k.maxWidth,w),T=u.nameMarginLevel||0,N=new Ia({x:m.x,y:m.y,rotation:b.rotation,silent:Dy.isLabelSilent(r),style:bf(c,{text:l,font:M,overflow:"truncate",width:A,ellipsis:S,fill:c.getTextColor()||r.get(["axisLine","lineStyle","color"]),align:c.get("align")||b.textAlign,verticalAlign:c.get("verticalAlign")||b.textVerticalAlign}),z2:1});if(nf({el:N,componentModel:r,itemName:l}),N.__fullText=l,N.anid="name",r.get("triggerEvent")){var C=Dy.makeAxisEventDataBase(r);C.targetType="axisName",C.name=l,au(N).eventData=C}a.add(N),N.updateTransform(),n.nameEl=N;var O=s.nameLayout=py({label:N,priority:N.z2,defaultAttr:{ignore:N.ignore},marginDefault:hm(f)?My[T]:ky[T]});if(s.nameLocation=f,e.add(N),N.decomposeTransform(),t.shouldNameMoveOverlap&&O){var I=i.ensureRecord(r);i.resolveAxisNameOverlap(t,i,r,O,y,I)}}}};function Ry(t,n,i,r,e,a,o,u){Ey(n)||function(t,n,i,r,e,a){var o=e.axis,u=ot(t.raw.axisLabelShow,e.get(["axisLabel","show"])),s=new Is;i.add(s);var l=Lm(r);if(u&&!o.scale.isBlank()){var f=e.getModel("axisLabel"),h=o.getViewLabels(l),c=(ot(t.raw.labelRotate,f.get("rotate"))||0)*xy/180,v=Dy.innerTextLayout(t.rotation,c,t.labelDirection),d=e.getCategories&&e.getCategories(!0),p=[],m=e.get("triggerEvent"),y=1/0,g=-1/0;H(h,(function(t,n){var i,r=t.tick,u=t.formattedLabel,l=t.rawLabel,c=f,b=dm(o.scale,r);if(d&&d[b]){var w=d[b];tt(w)&&w.textStyle&&(c=new Wf(w.textStyle,f,e.ecModel))}var x=c.getTextColor()||e.get(["axisLine","lineStyle","color"]),M=c.getShallow("align",!0)||v.textAlign,k=ut(c.getShallow("alignMinLabel",!0),M),S=ut(c.getShallow("alignMaxLabel",!0),M),A=c.getShallow("verticalAlign",!0)||c.getShallow("baseline",!0)||v.textVerticalAlign,T=ut(c.getShallow("verticalAlignMinLabel",!0),A),N=ut(c.getShallow("verticalAlignMaxLabel",!0),A),C=10+((null===(i=r.time)||void 0===i?void 0:i.level)||0);y=Math.min(y,C),g=Math.max(g,C);var O=new Ia({x:0,y:0,rotation:0,silent:Dy.isLabelSilent(e),z2:C,style:bf(c,{text:u,align:0===n?k:n===h.length-1?S:M,verticalAlign:0===n?T:n===h.length-1?N:A,fill:Z(x)?x("category"===o.type?l:"value"===o.type?b+"":b,n):x})});O.anid="label_"+b;var I=Sy(O);if(I.labelInfo=t,I.layoutRotation=v.rotation,nf({el:O,componentModel:e,itemName:u,formatterParamsExtra:{isTruncated:function(){return O.isTruncated},value:l,tickIndex:n}}),m){var L=Dy.makeAxisEventDataBase(e);L.targetType="axisLabel",L.value=l,L.tickIndex=n;var D=t.tick.break;if(D){var _=D.parsedBreak;L.break={start:_.vmin,end:_.vmax}}"category"===o.type&&(L.dataIndex=b),au(O).eventData=L,D&&function(t,n,i,r){i.on("click",(function(){var i={type:"expandAxisBreak",breaks:[{start:r.parsedBreak.breakOption.start,end:r.parsedBreak.breakOption.end}]};i[t.axis.dim+"AxisIndex"]=t.componentIndex,n.dispatchAction(i)}))}(e,a,O,D)}p.push(O),s.add(O)})),Wy(n,U(p,(function(t){return{label:t,priority:Sy(t).labelInfo.tick.break?t.z2+(g-y+1):t.z2,defaultAttr:{ignore:t.ignore}}})),s,l)}else Wy(n,[],s,l)}(t,n,e,u,r,o);var s=n.labelLayoutList;!function(t,n,i,r){var e=n.get(["axisLabel","margin"]);H(i,(function(i){var a=py(i);if(a){var o=a.label,u=Sy(o);a.suggestIgnore=o.ignore,o.ignore=!1,Mi(jy,Hy);var s=n.axis;jy.x=s.dataToCoord(dm(s.scale,u.labelInfo.tick)),jy.y=t.labelOffset+t.labelDirection*e,jy.rotation=u.layoutRotation,r.add(jy),jy.updateTransform(),r.remove(jy),jy.decomposeTransform(),Mi(o,jy),o.markRedraw(),vy(a,!0),py(a)}}))}(t,r,s,a);var l=t.optionHideOverlap;!function(t,n,i){var r=t.axis,e=t.get(["axisLabel","customValues"]);if(!function(t){return"category"===t.type&&0===fm(t.getLabelModel())}(r)){var a=t.get(["axisLabel","showMinLabel"]),o=t.get(["axisLabel","showMaxLabel"]),u=n.length;s(a,0,1),s(o,u-1,u-2)}function s(t,a,o){var u=py(n[a]),s=py(n[o]),l=r.scale;if(u&&s){if(null==t){if(!i&&e)return;var f=Sy(u.label).labelInfo.tick;if(zp(l)&&f.notNice||Fp(l)&&f.offInterval)return void Fy(u.label)}if(!1===t||u.suggestIgnore)Fy(u.label);else if(s.suggestIgnore)Fy(s.label);else{if(!i){var h=[0,0,0,0];u=gy({marginForce:h},u),s=gy({marginForce:h},s)}wy(u,s,null,{touchThreshold:.1})&&Fy(t?s.label:u.label)}}}}(r,s,l),l&&function(t){var n=[];function i(t){if(!t.ignore){var n=t.ensureState("emphasis");null==n.ignore&&(n.ignore=!1)}t.ignore=!0}t.sort((function(t,n){return(n.suggestIgnore?1:0)-(t.suggestIgnore?1:0)||n.priority-t.priority}));for(var r=0;r<t.length;r++){var e=py(t[r]);if(!e.label.ignore){for(var a=e.label,o=e.labelLine,u=!1,s=0;s<n.length;s++)if(wy(e,n[s],null,{touchThreshold:.05})){u=!0;break}u?(i(a),o&&i(o)):n.push(e)}}}($(s,(function(t){return t&&!t.label.ignore}))),function(t,n,i,r){var e,a=i.axis,o=n.ensureRecord(i),u=[],s=Uy(t.axisName)&&hm(t.nameLocation);H(r,(function(t){var n=py(t);if(n&&!n.label.ignore){u.push(n);var i=o.transGroup;s&&(i.transform?Qt(Ny,i.transform):qt(Ny),n.transform&&Zt(Ny,Ny,n.transform),On.copy(Cy,n.localRect),Cy.applyTransform(Ny),e?e.union(Cy):On.copy(e=new On(0,0,0,0),Cy))}}));var l=Math.abs(o.dirVec.x)>.1?"x":"y",f=o.transGroup[l];if(u.sort((function(t,n){return Math.abs(t.label[l]-f)-Math.abs(n.label[l]-f)})),s&&e){var h=a.getExtent(),c=Math.min(h[0],h[1]),v=Math.max(h[0],h[1])-c;e.union(new On(c,0,v,1))}o.stOccupiedRect=e,o.labelInfoList=u}(t,i,r,s)}function Fy(t){t&&(t.ignore=!0)}function Py(t,n,i,r,e){for(var a=[],o=[],u=[],s=0;s<t.length;s++){var l=t[s].coord;o[0]=l,o[1]=0,u[0]=l,u[1]=i,n&&(hn(o,o,n),hn(u,u,n));var f=new el({shape:{x1:o[0],y1:o[1],x2:u[0],y2:u[1]},style:r,z2:2,autoBatch:!0,silent:!0});Vl(f.shape,f.style.lineWidth),f.anid=e+"_"+t[s].tickValue,a.push(f);var h=Ay(f);h.onBand=!!t[s].onBand,h.tickValue=t[s].tickValue}return a}function By(t,n,i){if(Ey(t)){var r=t.axisLabelsCreationContext.out.noPxChangeTryDetermine;if(i.noPxChange){for(var e=!0,a=0;a<r.length;a++)e=e&&r[a]();if(e)return!1}r.length&&(n.remove(t.labelGroup),Wy(t,null,null,null))}return!0}function Ey(t){return!!t.labelLayoutList}function Wy(t,n,i,r){t.labelLayoutList=n,t.labelGroup=i,t.axisLabelsCreationContext=r}var jy=new Ta,Hy=new Ta;function Uy(t){return!!t}function Vy(t,n,i){i=i||{};var r=n.axis,e={},a=r.getAxesOnZeroOf()[0],o=r.position,u=a?"onZero":o,s=r.dim,l=[t.x,t.x+t.width,t.y,t.y+t.height],f={left:0,right:1,top:0,bottom:1,onZero:2},h=n.get("offset")||0,c="x"===s?[l[2]-h,l[3]+h]:[l[0]-h,l[1]+h];if(a){var v=a.toGlobalCoord(a.dataToCoord(0));c[f.onZero]=Math.max(Math.min(v,c[1]),c[0])}e.position=["y"===s?c[f[u]]:l[0],"x"===s?c[f[u]]:l[3]],e.rotation=Math.PI/2*("x"===s?0:1),e.labelDirection=e.tickDirection=e.nameDirection={top:-1,bottom:1,left:-1,right:1}[o],e.labelOffset=a?c[f[o]]-c[f.onZero]:0,n.get(["axisTick","inside"])&&(e.tickDirection=-e.tickDirection),ot(i.labelInside,n.get(["axisLabel","inside"]))&&(e.labelDirection=-e.labelDirection);var d=n.get(["axisLabel","rotate"]);return e.labelRotate="top"===u?-d:d,e.z2=1,e}var $y=Po(),Yy=function(){function t(t,n,i,r,e){var a,o=Fp(t),u=o?n.getCategories().length:null;if(o){var s=n.getCategories(!0);a=s&&!s.length}var l=i.slice();(_p(t)||Rp(t)||zp(t))&&(Yo(l,qy(t,n.get("dataMin",!0))),Xo(l,qy(t,n.get("dataMax",!0)))),function(t){var n=t[1]-t[0];return isFinite(n)&&n>=0}(l)||(l[0]=l[1]=NaN);var f=[],h=[!1,!1],c=n.get("min",!0);"dataMin"===c?(f[0]=l[0],h[0]=!0):(f[0]=qy(t,Z(c)?c({min:l[0],max:l[1]}):c),h[0]=null!=f[0]);var v=n.get("max",!0);"dataMax"===v?(f[1]=l[1],h[1]=!0):(f[1]=qy(t,Z(v)?v({min:l[0],max:l[1]}):v),h[1]=null!=f[1]);var d=function(t,n){var i;if(Fp(t))i=[0,0];else{var r=n.get("boundaryGap");"boolean"==typeof r&&(r=null),i=G(r)?r:[r,r]}return[Gy(i[0]),Gy(i[1])]}(t,n),p=o?null:l[1]-l[0]||Math.abs(l[0]);null==f[0]&&(f[0]=o?a?l[0]:u?0:NaN:l[0]-d[0]*p),null==f[1]&&(f[1]=o?a?l[1]:u?u-1:NaN:l[1]+d[1]*p),!qo(f[0])&&(f[0]=NaN),!qo(f[1])&&(f[1]=NaN);var m=a||at(f[0])||at(f[1])||o&&!u,y=_p(t),g=y&&n.needIncludeZero&&n.needIncludeZero();g&&(f[0]>0&&f[1]>0&&!h[0]&&(f[0]=0),f[0]<0&&f[1]<0&&!h[1]&&(f[1]=0));var b=!1;f[0]>f[1]&&(f.reverse(),b=!0);var w=qy(t,n.get("startValue",!0)),x=null!=w;!wo(w)&&r&&(w=t.getDefaultStartValue?t.getDefaultStartValue():0),wo(w)&&(x||!y||g)&&(w<f[0]&&!h[0]?(f[0]=w,h[0]=!0):w>f[1]&&!h[1]&&(f[1]=w,h[1]=!0)),Xy(this._i={scale:t,dataMM:l,noZoomEffMM:f,zoomMM:[],fixMM:h,zoomFixMM:[!1,!1],startValue:w,isBlank:m,incl0:g,tggAxInv:b,ctnShp:e},f)}return t.prototype.makeNoZoom=function(){return this._i.noZoomEffMM.slice()},t.prototype.makeFinal=function(){var t=this._i,n=t.zoomMM,i=t.zoomFixMM,r=t.fixMM,e={fixMM:r,zoomFixMM:i,isBlank:t.isBlank,incl0:t.incl0,tggAxInv:t.tggAxInv,ctnShp:t.ctnShp,effMM:t.noZoomEffMM.slice()},a=e.effMM;return null!=n[0]&&(a[0]=n[0],r[0]=i[0]=!0),null!=n[1]&&(a[1]=n[1],r[1]=i[1]=!0),Xy(t,a),e},t.prototype.makeRenderInfo=function(){return{startValue:this._i.startValue}},t.prototype.setZoomMM=function(t,n){this._i.zoomMM[t]=n},t}();function Xy(t,n){var i,r=t.scale,e=t.dataMM;r.sanitize&&(n[0]=r.sanitize(n[0],e),n[1]=r.sanitize(n[1],e),Go((i=n)[0],i[1])&&i[0]>i[1]&&(i[0]=i[1]))}function qy(t,n){return null==n?null:at(n)?NaN:t.parse(n)}function Gy(t){return Xn("boolean"==typeof t?0:t,1)||0}function Zy(t){var n=$y(t.scale);return n.extent||(n.extent=[1/0,-1/0]),n}function Jy(t,n){var i=t.scale;i.rawExtentInfo||function(t,n,i,r,e){var a=Zy(n),o=a.extent,u=!1;!function(t,n){var i=t.model.ecModel,r=Ym(Um(i)).axSer;r&&Qm(i,r.get(t.model.uid),n)}(n,(function(r){if(r.boxCoordinateSystem){var e=fc(r).coord,s=a.dimIdxInCoord;if(s>=0&&G(e)){var l=e[s];null==l||G(l)||$o(o,t.parse(l))}}else if(r.coordinateSystem){var f=r.getData();if(f){var h=t.getFilter?t.getFilter():null;H(function(t,n){var i={};return H(t.mapDimensionsAll(n),(function(n){i[function(t,n){return dc(t,n)?t.getCalculationInfo("stackResultDimension"):n}(t,n)]=!0})),Y(i)}(f,i),(function(t){var n,i;n=o,Go((i=f.getApproximateExtent(t,h))[0],i[1])&&(i[0]<n[0]&&(n[0]=i[0]),i[1]>n[1]&&(n[1]=i[1]))}))}r.__requireStartValue&&r.__requireStartValue(n)&&(u=!0)}}));var s=function(t,n,i){var r=pm(t,i),e=i.get("containShape",!0);if(null!=e||r||(e=!0),!e)return!1;var a=!1;return ny(n,(function(t){a=!!tg.get(t)||a})),a}(t,n,r),l=new Yy(t,r,o,u,s);Ky(t,l,e),a.extent=null}(i,t,t.dim,t.model,n)}function Ky(t,n,i){t.rawExtentInfo=n,n.from=i}function Qy(t,n){tg.set(t,n)}var tg=bt();function ng(t,n,i,r){t.rawExtentInfo||function(t){var n=t.scale;Ky(n,new Yy(n,t.model,[1/0,-1/0],!1,!1),3)}({scale:t,model:n});var e=t.rawExtentInfo.makeFinal(),a=e.effMM;return t.setExtent(a[0],a[1]),t.setBlank(e.isBlank),r&&e.tggAxInv&&i&&!i.get("legacyMinMaxDontInverseAxis")&&(r.inverse=!r.inverse),e}function ig(t,n,i){var r,e=bt(),a=i.serUids,o=i.liPosMinGap,u=n.axis,s=u.scale,l=s.needTransform(),f=s.getFilter?s.getFilter():null,h=Nh(f);function c(i){Qm(t,n.sers,(function(t){var n=t.getRawData(),r=n.getDimensionIndex(n.mapDimension(u.dim));r>=0&&i(r,t,n.getStore())}))}var v=0;if(c((function(t,n,i){e.set(n.uid,1),a&&a.hasKey(n.uid)||(r=!0),v+=i.count()})),a&&a.keys().length===e.keys().length||(r=!0),r||null==o){Kd(rg,v);var d=0;c((function(t,n,i){for(var r=0,e=i.count();r<e;++r){var a=i.get(t,r);!isFinite(a)||f&&!Ch(h,a)||(l&&(a=s.transformIn(a,null)),rg.arr[d++]=a)}}));var p=rg.typed?rg.arr.subarray(0,d):(rg.arr.length=d,rg.arr);rg.typed?p.sort():eo(p);for(var m=1/0,y=1;y<d;++y){var g=p[y]-p[y-1];g>0&&g<m&&(m=g)}i.liPosMinGap=n.liPosMinGap=wo(m)?m:d>0?-2:-1,i.serUids=e}else n.liPosMinGap=o}var rg=Kd({ctor:Zd},50);function eg(t){return function(n){var i=uy(n,{fromStat:{key:t}});if(wo(i.w2))return[-i.w2/2,i.w2/2]}}function ag(t,n){return t+$m+n}function og(t){return ry.liPosMinGap=ig,{liPosMinGap:!Fp(t.scale)}}var ug="bar";function sg(t,n,i,r){!function(t,n){var i=ay(n.seriesType,n.baseAxis,n.coordSysType);oy.set(i,n),Vm(t,(function(){t.registerProcessor(t.PRIORITY.PROCESSOR.AXIS_STATISTICS,{overallReset:iy})}))}(t,{key:n,seriesType:i,coordSysType:r,getMetrics:og})}function lg(t){return t.scale.rawExtentInfo.makeRenderInfo().startValue}var fg={left:0,right:0,top:0,bottom:0},hg=["25%","25%"],cg="cartesian2d",vg=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return v(n,t),n.prototype.mergeDefaultAndTheme=function(n,i){var r=Ov(n.outerBounds);t.prototype.mergeDefaultAndTheme.apply(this,arguments),r&&n.outerBounds&&Cv(n.outerBounds,r)},n.prototype.mergeOption=function(n,i){t.prototype.mergeOption.apply(this,arguments),this.option.outerBounds&&n.outerBounds&&Cv(this.option.outerBounds,n.outerBounds)},n.type="grid",n.dependencies=["xAxis","yAxis"],n.layoutMode="box",n.defaultOption={show:!1,z:0,left:"15%",top:65,right:"10%",bottom:80,containLabel:!1,outerBoundsMode:"auto",outerBounds:fg,outerBoundsContain:"all",outerBoundsClampWidth:hg[0],outerBoundsClampHeight:hg[1],backgroundColor:Jv.color.transparent,borderWidth:1,borderColor:Jv.color.neutral30},n}(Lv),dg=Zo();function pg(t){return t.get("stack")||"__ec_stack_"+t.seriesIndex}function mg(t){return t.pipelineContext&&t.pipelineContext.large}var yg=function(t){function n(){var i=null!==t&&t.apply(this,arguments)||this;return i.type=n.type,i}return v(n,t),n.prototype.getInitialData=function(){return pc(0,this,{useEncodeDefaulter:!0})},n.prototype.getMarkerPosition=function(t,n,i){var r=this.coordinateSystem;if(r&&r.clampData){var e=r.clampData(t),a=r.dataToPoint(e);if(i)H(r.getAxes(),(function(t,i){if("category"===t.type&&null!=n){var r=t.getTicksCoords(),o=t.getTickModel().get("alignWithLabel"),u=e[i],s="x1"===n[i]||"y1"===n[i];if(s&&!o&&(u+=1),r.length<2)return;if(2===r.length)return void(a[i]=t.toGlobalCoord(t.getExtent()[s?1:0]));for(var l=void 0,f=void 0,h=1,c=0;c<r.length;c++){var v=r[c].coord,d=c===r.length-1?r[c-1].tickValue+h:r[c].tickValue;if(d===u){f=v;break}if(d<u)l=v;else if(null!=l&&d>u){f=(v+l)/2;break}1===c&&(h=d-r[0].tickValue)}null==f&&(l?l&&(f=r[r.length-1].coord):f=r[0].coord),a[i]=t.toGlobalCoord(f)}}));else{var o=this.getData(),u=o.getLayout("offset"),s=o.getLayout("size"),l=r.getBaseAxis().isHorizontal()?0:1;a[l]+=u+s/2}return a}return[NaN,NaN]},n.prototype.__requireStartValue=function(t){return this.getBaseAxis()!==t},n.type="series.__base_bar__",n.defaultOption={z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,barMinHeight:0,barMinAngle:0,large:!1,largeThreshold:400,progressive:3e3,progressiveChunkMode:"mod",defaultBarGap:"10%"},n}(gd);gd.registerClass(yg);var gg=function(t){function n(){var i=null!==t&&t.apply(this,arguments)||this;return i.type=n.type,i}var i;return v(n,t),n.prototype.getInitialData=function(){return pc(0,this,{useEncodeDefaulter:!0,createInvertedIndices:!!this.get("realtimeSort",!0)||null})},n.prototype.getProgressive=function(){return!!this.get("large")&&this.get("progressive")},n.prototype.__preparePipelineContext=function(t,n){var i=iu(this,t,n);return i.progressiveRender&&(i.large=!0),i},n.prototype.brushSelector=function(t,n,i){return i.rect(n.getItemLayout(t))},n.type="series."+ug,n.dependencies=["grid","polar"],n.defaultOption=(i={clip:!0,roundCap:!1,showBackground:!1,backgroundStyle:{color:"rgba(180, 180, 180, 0.2)",borderColor:null,borderWidth:0,borderType:"solid",borderRadius:0,shadowBlur:0,shadowColor:null,shadowOffsetX:0,shadowOffsetY:0,opacity:1},select:{itemStyle:{borderColor:Jv.color.primary,borderWidth:2}},realtimeSort:!1},F(F({},yg.defaultOption,!0),i,!0)),n}(yg),bg="\0__throttleOriginMethod",wg="\0__throttleRate",xg="\0__throttleType";function Mg(t,n,i){var r,e,a,o,u,s=0,l=0,f=null;function h(){l=(new Date).getTime(),f=null,t.apply(a,o||[])}n=n||0;var c=function(){for(var t=[],c=0;c<arguments.length;c++)t[c]=arguments[c];r=(new Date).getTime(),a=this,o=t;var v=u||n,d=u||i;u=null,e=r-(d?s:l)-v,clearTimeout(f),d?f=setTimeout(h,v):e>=0?h():f=setTimeout(h,-e),s=r};return c.clear=function(){f&&(clearTimeout(f),f=null)},c.debounceNextCall=function(t){u=t},c}function kg(t,n,i,r){var e=t[n];if(e){var a=e[bg]||e;if(e[wg]!==i||e[xg]!==r){if(null==i||!r)return t[n]=a;(e=t[n]=Mg(a,i,"debounce"===r))[bg]=a,e[xg]=r,e[wg]=i}return e}}function Sg(t,n){var i=t[n];i&&i[bg]&&(i.clear&&i.clear(),t[n]=i[bg])}var Ag=function(){this.cx=0,this.cy=0,this.r0=0,this.r=0,this.startAngle=0,this.endAngle=2*Math.PI,this.clockwise=!0},Tg=function(t){function n(n){var i=t.call(this,n)||this;return i.type="sausage",i}return v(n,t),n.prototype.getDefaultShape=function(){return new Ag},n.prototype.buildPath=function(t,n){var i=n.cx,r=n.cy,e=Math.max(n.r0||0,0),a=Math.max(n.r,0),o=.5*(a-e),u=e+o,s=n.startAngle,l=n.endAngle,f=n.clockwise,h=2*Math.PI,c=f?l-s<h:s-l<h;c||(s=l-(f?h:-h));var v=Math.cos(s),d=Math.sin(s),p=Math.cos(l),m=Math.sin(l);c?(t.moveTo(v*e+i,d*e+r),t.arc(v*u+i,d*u+r,o,-Math.PI+s,s,!f)):t.moveTo(v*a+i,d*a+r),t.arc(i,r,a,s,l,!f),t.arc(p*u+i,m*u+r,o,l-2*Math.PI,l-Math.PI,!f),0!==e&&t.arc(i,r,e,l,s,f)},n}(da);function Ng(t,n,i){return n*Math.sin(t)*(i?-1:1)}function Cg(t,n,i){return n*Math.cos(t)*(i?1:-1)}function Og(t,n,i){var r=t.get("borderRadius");if(null==r)return i?{cornerRadius:0}:null;G(r)||(r=[r,r,r,r]);var e=Math.abs(n.r||0-n.r0||0);return{cornerRadius:U(r,(function(t){return Xn(t,e)}))}}var Ig=Math.max,Lg=Math.min,Dg=function(t){function n(){var n=t.call(this)||this;return n.type=ug,n._isFirstFrame=!0,n}return v(n,t),n.prototype.render=function(t,n,i,r){this._model=t,this._removeOnRenderedListener(i),this._updateDrawMode(t);var e=t.get("coordinateSystem");"cartesian2d"!==e&&"polar"!==e||(this._progressiveEls=null,this._isLargeDraw?this._renderLarge(t,n,i):this._renderNormal(t,n,i,r))},n.prototype.incrementalPrepareRender=function(t){this._clear(),this._updateDrawMode(t),this._updateLargeClip(t)},n.prototype.incrementalRender=function(t,n){this._progressiveEls=[],this._incrementalRenderLarge(t,n)},n.prototype.eachRendered=function(t){ef(this._progressiveEls||this.group,t)},n.prototype._updateDrawMode=function(t){var n=t.pipelineContext.large;null!=this._isLargeDraw&&n===this._isLargeDraw||(this._isLargeDraw=n,this._clear())},n.prototype._renderNormal=function(t,n,i,r){var e,a=this.group,o=t.getData(),u=this._data,s=t.coordinateSystem,l=s.getBaseAxis();"cartesian2d"===s.type?e=l.isHorizontal():"polar"===s.type&&(e="angle"===l.dim);var f=t.isAnimationEnabled()?t:null,h=function(t,n){var i=t.get("realtimeSort",!0),r=n.getBaseAxis();if(i&&"category"===r.type&&"cartesian2d"===n.type)return{baseAxis:r,otherAxis:n.getOtherAxis(r)}}(t,s);h&&this._enableRealtimeSort(h,o,i);var c=t.get("clip",!0)||h,v=s.getArea();a.removeClipPath();var d=t.get("roundCap",!0),p=t.get("showBackground",!0),m=t.getModel("backgroundStyle"),y=m.get("borderRadius")||0,g=[],b=this._backgroundEls,w=r&&r.isInitSort,x=r&&"changeAxisOrder"===r.type;function M(t){var n=Wg[s.type](o,t);if(!n)return null;var i=function(t,n,i){return new("polar"===t.type?qs:Ta)({shape:Xg(n,i,t),silent:!0,z2:0})}(s,e,n);return i.useStyle(m.getItemStyle()),i.setShape("cartesian2d"===s.type?"r":"cornerRadius",y),g[t]=i,i}o.diff(u).add((function(n){var i=o.getItemModel(n),r=Wg[s.type](o,n,i);if(r&&(p&&M(n),o.hasValue(n)&&Eg[s.type](r))){var u=!1;c&&(u=_g[s.type](v,r));var m=zg[s.type](t,o,n,r,e,f,l.model,!1,d);h&&(m.forceLabelAnimation=!0),Hg(m,o,n,i,r,t,e,"polar"===s.type),w?m.attr({shape:r}):h?Rg(h,f,m,r,n,e,!1,!1):Ol(m,{shape:r},t,n),o.setItemGraphicEl(n,m),a.add(m),m.ignore=u}})).update((function(n,i){var r=o.getItemModel(n),k=Wg[s.type](o,n,r);if(k){if(p){var S=void 0;0===b.length?S=M(i):((S=b[i]).useStyle(m.getItemStyle()),S.setShape("cartesian2d"===s.type?"r":"cornerRadius",y),g[n]=S);var A=Wg[s.type](o,n);Cl(S,{shape:Xg(e,A,s)},f,n)}var T=u.getItemGraphicEl(i);if(o.hasValue(n)&&Eg[s.type](k)){var N=!1;if(c&&(N=_g[s.type](v,k))&&a.remove(T),T&&("sector"===T.type&&d||"sausage"===T.type&&!d)&&(T&&_l(T,t,i),T=null),T?zl(T):T=zg[s.type](t,o,n,k,e,f,l.model,!0,d),h&&(T.forceLabelAnimation=!0),x){var C=T.getTextContent();if(C){var O=Af(C);null!=O.prevValue&&(O.prevValue=O.value)}}else Hg(T,o,n,r,k,t,e,"polar"===s.type);w?T.attr({shape:k}):h?Rg(h,f,T,k,n,e,!0,x):Cl(T,{shape:k},t,n,null),o.setItemGraphicEl(n,T),T.ignore=N,a.add(T)}else a.remove(T)}})).remove((function(n){var i=u.getItemGraphicEl(n);i&&_l(i,t,n)})).execute();var k=this._backgroundGroup||(this._backgroundGroup=new Is);k.removeAll();for(var S=0;S<g.length;++S)k.add(g[S]);a.add(k),this._backgroundEls=g,this._data=o},n.prototype._renderLarge=function(t){this._clear(),$g(t,this.group),this._updateLargeClip(t)},n.prototype._incrementalRenderLarge=function(t,n){this._removeBackground(),$g(n,this.group,this._progressiveEls,!0)},n.prototype._updateLargeClip=function(t){var n=t.get("clip",!0)&&function(t,n,i){return t?"polar"===t.type?mp(t,n,i):"cartesian2d"===t.type?pp(t,n,i,void 0,void 0):null:null}(t.coordinateSystem,!1,t),i=this.group;n?i.setClipPath(n):i.removeClipPath()},n.prototype._enableRealtimeSort=function(t,n,i){var r=this;if(n.count()){var e=t.baseAxis;if(this._isFirstFrame)this._dispatchInitSort(n,t,i),this._isFirstFrame=!1;else{var a=function(t){var i=n.getItemGraphicEl(t),r=i&&i.shape;return r&&Math.abs(e.isHorizontal()?r.height:r.width)||0};this._onRendered=function(){r._updateSortWithinSameData(n,a,e,i)},i.getZr().on("rendered",this._onRendered)}}},n.prototype._dataSort=function(t,n,i){var r=[];return t.each(t.mapDimension(n.dim),(function(t,n){var e=i(n);r.push({dataIndex:n,mappedValue:e=null==e?NaN:e,ordinalNumber:t})})),r.sort((function(t,n){return n.mappedValue-t.mappedValue})),{ordinalNumbers:U(r,(function(t){return t.ordinalNumber}))}},n.prototype._isOrderChangedWithinSameData=function(t,n,i){for(var r=i.scale,e=t.mapDimension(i.dim),a=Number.MAX_VALUE,o=0,u=r.getOrdinalMeta().categories.length;o<u;++o){var s=t.rawIndexOf(e,r.getRawOrdinalNumber(o)),l=s<0?Number.MIN_VALUE:n(t.indexOfRawIndex(s));if(l>a)return!0;a=l}return!1},n.prototype._isOrderDifferentInView=function(t,n){for(var i=n.scale,r=i.getExtent(),e=Math.max(0,r[0]),a=Math.min(r[1],i.getOrdinalMeta().categories.length-1);e<=a;++e)if(t.ordinalNumbers[e]!==i.getRawOrdinalNumber(e))return!0},n.prototype._updateSortWithinSameData=function(t,n,i,r){if(this._isOrderChangedWithinSameData(t,n,i)){var e=this._dataSort(t,i,n);this._isOrderDifferentInView(e,i)&&(this._removeOnRenderedListener(r),r.dispatchAction({type:"changeAxisOrder",componentType:i.dim+"Axis",axisId:i.index,sortInfo:e}))}},n.prototype._dispatchInitSort=function(t,n,i){var r=n.baseAxis,e=this._dataSort(t,r,(function(i){return t.get(t.mapDimension(n.otherAxis.dim),i)}));i.dispatchAction({type:"changeAxisOrder",componentType:r.dim+"Axis",isInitSort:!0,axisId:r.index,sortInfo:e})},n.prototype.remove=function(t,n){this._clear(this._model),this._removeOnRenderedListener(n)},n.prototype.dispose=function(t,n){this._removeOnRenderedListener(n)},n.prototype._removeOnRenderedListener=function(t){this._onRendered&&(t.getZr().off("rendered",this._onRendered),this._onRendered=null)},n.prototype._clear=function(t){var n=this.group,i=this._data;t&&t.isAnimationEnabled()&&i&&!this._isLargeDraw?(this._removeBackground(),this._backgroundEls=[],i.eachItemGraphicEl((function(n){_l(n,t,au(n).dataIndex)}))):n.removeAll(),this._data=null,this._isFirstFrame=!0},n.prototype._removeBackground=function(){this.group.remove(this._backgroundGroup),this._backgroundGroup=null},n.type=ug,n}(lp),_g={cartesian2d:function(t,n){var i=n.width<0?-1:1,r=n.height<0?-1:1;i<0&&(n.x+=n.width,n.width=-n.width),r<0&&(n.y+=n.height,n.height=-n.height);var e=t.x+t.width,a=t.y+t.height,o=Ig(n.x,t.x),u=Lg(n.x+n.width,e),s=Ig(n.y,t.y),l=Lg(n.y+n.height,a),f=u<o,h=l<s;return n.x=f&&o>e?u:o,n.y=h&&s>a?l:s,n.width=f?0:u-o,n.height=h?0:l-s,i<0&&(n.x+=n.width,n.width=-n.width),r<0&&(n.y+=n.height,n.height=-n.height),f||h},polar:function(t,n){var i=n.r0<=n.r?1:-1;if(i<0){var r=n.r;n.r=n.r0,n.r0=r}var e=Lg(n.r,t.r),a=Ig(n.r0,t.r0);n.r=e,n.r0=a;var o=e-a<0;return i<0&&(r=n.r,n.r=n.r0,n.r0=r),o}},zg={cartesian2d:function(t,n,i,r,e,a){var o=new Ta({shape:P({},r),z2:1});return o.__dataIndex=i,o.name="item",a&&(o.shape[e?"height":"width"]=0),o},polar:function(t,n,i,r,e,a,o,u,s){var l=!e&&s?Tg:qs,f=new l({shape:r,z2:1});f.name="item";var h,c,v=jg(e);if(f.calculateTextPosition=(h=v,c=({isRoundCap:l===Tg}||{}).isRoundCap,function(t,n,i){var r=n.position;if(!r||r instanceof Array)return qn(t,n,i);var e=h(r),a=null!=n.distance?n.distance:5,o=this.shape,u=o.cx,s=o.cy,l=o.r,f=o.r0,v=(l+f)/2,d=o.startAngle,p=o.endAngle,m=(d+p)/2,y=c?Math.abs(l-f)/2:0,g=Math.cos,b=Math.sin,w=u+l*g(d),x=s+l*b(d),M="left",k="top";switch(e){case"startArc":w=u+(f-a)*g(m),x=s+(f-a)*b(m),M="center",k="top";break;case"insideStartArc":w=u+(f+a)*g(m),x=s+(f+a)*b(m),M="center",k="bottom";break;case"startAngle":w=u+v*g(d)+Ng(d,a+y,!1),x=s+v*b(d)+Cg(d,a+y,!1),M="right",k="middle";break;case"insideStartAngle":w=u+v*g(d)+Ng(d,-a+y,!1),x=s+v*b(d)+Cg(d,-a+y,!1),M="left",k="middle";break;case"middle":w=u+v*g(m),x=s+v*b(m),M="center",k="middle";break;case"endArc":w=u+(l+a)*g(m),x=s+(l+a)*b(m),M="center",k="bottom";break;case"insideEndArc":w=u+(l-a)*g(m),x=s+(l-a)*b(m),M="center",k="top";break;case"endAngle":w=u+v*g(p)+Ng(p,a+y,!0),x=s+v*b(p)+Cg(p,a+y,!0),M="left",k="middle";break;case"insideEndAngle":w=u+v*g(p)+Ng(p,-a+y,!0),x=s+v*b(p)+Cg(p,-a+y,!0),M="right",k="middle";break;default:return qn(t,n,i)}return(t=t||{}).x=w,t.y=x,t.align=M,t.verticalAlign=k,t}),a){var d=e?"r":"endAngle",p={};f.shape[d]=e?r.r0:r.startAngle,p[d]=r[d],(u?Cl:Ol)(f,{shape:p},a)}return f}};function Rg(t,n,i,r,e,a,o,u){var s,l;a?(l={x:r.x,width:r.width},s={y:r.y,height:r.height}):(l={y:r.y,height:r.height},s={x:r.x,width:r.width}),u||(o?Cl:Ol)(i,{shape:s},n,e,null),(o?Cl:Ol)(i,{shape:l},n?t.baseAxis.model:null,e)}function Fg(t,n){for(var i=0;i<n.length;i++)if(!isFinite(t[n[i]]))return!0;return!1}var Pg=["x","y","width","height"],Bg=["cx","cy","r","startAngle","endAngle"],Eg={cartesian2d:function(t){return!Fg(t,Pg)},polar:function(t){return!Fg(t,Bg)}},Wg={cartesian2d:function(t,n,i){var r=t.getItemLayout(n);if(!r)return null;var e=i?function(t,n){var i=t.get(["itemStyle","borderColor"]);if(!i||"none"===i)return 0;var r=t.get(["itemStyle","borderWidth"])||0,e=isNaN(n.width)?Number.MAX_VALUE:Math.abs(n.width),a=isNaN(n.height)?Number.MAX_VALUE:Math.abs(n.height);return Math.min(r,e,a)}(i,r):0,a=r.width>0?1:-1,o=r.height>0?1:-1;return{x:r.x+a*e/2,y:r.y+o*e/2,width:r.width-a*e,height:r.height-o*e}},polar:function(t,n){var i=t.getItemLayout(n);return{cx:i.cx,cy:i.cy,r0:i.r0,r:i.r,startAngle:i.startAngle,endAngle:i.endAngle,clockwise:i.clockwise}}};function jg(t){return function(t){var n=t?"Arc":"Angle";return function(t){switch(t){case"start":case"insideStart":case"end":case"insideEnd":return t+n;default:return t}}}(t)}function Hg(t,n,i,r,e,a,o,u){var s=n.getItemVisual(i,"style");if(u){if(!a.get("roundCap")){var l=t.shape;P(l,Og(r.getModel("itemStyle"),l,!0)),t.setShape(l)}}else{var f=r.get(["itemStyle","borderRadius"])||0;t.setShape("r",f)}t.useStyle(s);var h=r.getShallow("cursor");h&&t.attr("cursor",h);var c=u?o?e.r>=e.r0?"endArc":"startArc":e.endAngle>=e.startAngle?"endAngle":"startAngle":o?function(t,n){return 0===t.height?n.getOtherAxis(n.getBaseAxis()).inverse?"bottom":"top":t.height>0?"bottom":"top"}(e,a.coordinateSystem):function(t,n){return 0===t.width?n.getOtherAxis(n.getBaseAxis()).inverse?"left":"right":t.width>=0?"right":"left"}(e,a.coordinateSystem),v=gf(r);yf(t,v,{labelFetcher:a,labelDataIndex:i,defaultText:Pd(a.getData(),i),inheritColor:s.fill,defaultOpacity:s.opacity,defaultOutsidePosition:c});var d=t.getTextContent();if(u&&d){var p=r.get(["label","position"]);t.textConfig.inside="middle"===p||null,function(t,n,i,r){if(Q(r))t.setTextConfig({rotation:r});else if(G(n))t.setTextConfig({rotation:0});else{var e,a=t.shape,o=a.clockwise?a.startAngle:a.endAngle,u=a.clockwise?a.endAngle:a.startAngle,s=(o+u)/2,l=i(n);switch(l){case"startArc":case"insideStartArc":case"middle":case"insideEndArc":case"endArc":e=s;break;case"startAngle":case"insideStartAngle":e=o;break;case"endAngle":case"insideEndAngle":e=u;break;default:return void t.setTextConfig({rotation:0})}var f=1.5*Math.PI-e;"middle"===l&&f>Math.PI/2&&f<1.5*Math.PI&&(f-=Math.PI),t.setTextConfig({rotation:f})}}(t,"outside"===p?c:p,jg(o),r.get(["label","rotate"]))}Tf(d,v,a.getRawValue(i),(function(t){return Bd(n,t)}));var m=r.getModel(["emphasis"]);as(t,m.get("focus"),m.get("blurScope"),m.get("disabled")),ss(t,r),function(t){return null!=t.startAngle&&null!=t.endAngle&&t.startAngle===t.endAngle}(e)&&(t.style.fill="none",t.style.stroke="none",H(t.states,(function(t){t.style&&(t.style.fill=t.style.stroke="none")})))}var Ug=function(){},Vg=function(t){function n(n){var i=t.call(this,n)||this;return i.type="largeBar",i}return v(n,t),n.prototype.getDefaultShape=function(){return new Ug},n.prototype.buildPath=function(t,n){for(var i=n.points,r=this.baseDimIdx,e=1-this.baseDimIdx,a=[],o=[],u=this.barWidth,s=0;s<i.length;s+=3)o[r]=u,o[e]=i[s+2],a[r]=i[s+r],a[e]=i[s+e],t.rect(a[0],a[1],o[0],o[1])},n}(da);function $g(t,n,i,r){var e=t.getData(),a=e.getLayout("valueAxisHorizontal")?1:0,o=e.getLayout("largeDataIndices"),u=e.getLayout("size"),s=t.getModel("backgroundStyle"),l=e.getLayout("largeBackgroundPoints"),f=r?nu(t):0;if(l){var h=new Vg({shape:{points:l},incremental:f,silent:!0,z2:0});h.baseDimIdx=a,h.largeDataIndices=o,h.barWidth=u,h.useStyle(s.getItemStyle()),n.add(h),i&&i.push(h)}var c=new Vg({shape:{points:e.getLayout("largePoints")},incremental:f,ignoreCoarsePointer:!0,z2:1});c.baseDimIdx=a,c.largeDataIndices=o,c.barWidth=u,n.add(c),c.useStyle(e.getVisual("style")),c.style.stroke=null,au(c).seriesIndex=t.seriesIndex,t.get("silent")||(c.on("mousedown",Yg),c.on("mousemove",Yg)),i&&i.push(c)}var Yg=Mg((function(t){var n=function(t,n,i){for(var r=t.baseDimIdx,e=1-r,a=t.shape.points,o=t.largeDataIndices,u=[],s=[],l=t.barWidth,f=0,h=a.length/3;f<h;f++){var c=3*f;if(s[r]=l,s[e]=a[c+2],u[r]=a[c+r],u[e]=a[c+e],s[e]<0&&(u[e]+=s[e],s[e]=-s[e]),n>=u[0]&&n<=u[0]+s[0]&&i>=u[1]&&i<=u[1]+s[1])return o[f]}return-1}(this,t.offsetX,t.offsetY);au(this).dataIndex=n>=0?n:null}),30,!1);function Xg(t,n,i){if(gp(i,"cartesian2d")){var r=n,e=i.getArea();return{x:t?r.x:e.x,y:t?e.y:r.y,width:t?r.width:e.width,height:t?e.height:r.height}}return{cx:(e=i.getArea()).cx,cy:e.cy,r0:t?e.r0:n.r0,r:t?e.r:n.r,startAngle:t?n.startAngle:0,endAngle:t?n.endAngle:2*Math.PI}}function qg(t,n,i,r,e){var a=t+n;i.isSilent(a)||r.eachComponent({mainType:"series",subType:"pie"},(function(t){for(var n=t.seriesIndex,r=t.option.selectedMap,o=e.selected,u=0;u<o.length;u++)if(o[u].seriesIndex===n){var s=t.getData(),l=Fo(s,e.fromActionPayload);i.trigger(a,{type:a,seriesId:t.id,name:G(l)?s.getName(l[0]):s.getName(l),selected:J(r)?r:P({},r)})}}))}function Gg(t,n,i){n=G(n)&&{coordDimensions:n}||P({encodeDefine:t.getEncode()},n);var r=t.getSource(),e=ec(r,n).dimensions,a=new rc(e,t);return a.initData(r,i),a}var Zg,Jg=function(){function t(t,n){this._getDataWithEncodedVisual=t,this._getRawData=n}return t.prototype.getAllNames=function(){var t=this._getRawData();return t.mapArray(t.getName)},t.prototype.containName=function(t){return this._getRawData().indexOfName(t)>=0},t.prototype.indexOfName=function(t){return this._getDataWithEncodedVisual().indexOfName(t)},t.prototype.getItemVisual=function(t,n){return this._getDataWithEncodedVisual().getItemVisual(t,n)},t}(),Kg="pie",Qg=Po(),tb=function(t){function n(){var i=null!==t&&t.apply(this,arguments)||this;return i.type=n.type,i}return v(n,t),n.prototype.init=function(n){t.prototype.init.apply(this,arguments),this.legendVisualProvider=new Jg(X(this.getData,this),X(this.getRawData,this)),this._defaultLabelLine(n)},n.prototype.mergeOption=function(){t.prototype.mergeOption.apply(this,arguments)},n.prototype.getInitialData=function(){return Gg(this,{coordDimensions:["value"],encodeDefaulter:q(Yf,this)})},n.prototype.getDataParams=function(n){var i=this.getData(),r=Qg(i),e=r.seats;if(!e){var a=[];i.each(i.mapDimension("value"),(function(t){a.push(t)})),e=r.seats=function(t,n){var i=V(t,(function(t,n){return t+(isNaN(n)?0:n)}),0);if(0===i)return[];for(var r=Ga(10,n),e=U(t,(function(t){return(isNaN(t)?0:t)/i*r*100})),a=100*r,o=U(e,(function(t){return Xa(t)})),u=V(o,(function(t,n){return t+n}),0),s=U(e,(function(t,n){return t-o[n]}));u<a;){for(var l=Number.NEGATIVE_INFINITY,f=null,h=0,c=s.length;h<c;++h)s[h]>l&&(l=s[h],f=h);++o[f],s[f]=0,++u}return U(o,(function(t){return t/r}))}(a,i.hostModel.get("percentPrecision"))}var o=t.prototype.getDataParams.call(this,n);return o.percent=e[n]||0,o.$vars.push("percent"),o},n.prototype._defaultLabelLine=function(t){No(t,"labelLine",["show"]);var n=t.labelLine,i=t.emphasis.labelLine;n.show=n.show&&t.label.show,i.show=i.show&&t.emphasis.label.show},n.type="series."+Kg,n.defaultOption={z:2,legendHoverLink:!0,colorBy:"data",center:["50%","50%"],radius:[0,"50%"],clockwise:!0,startAngle:90,endAngle:"auto",padAngle:0,minAngle:0,minShowLabelAngle:0,selectedOffset:10,percentPrecision:2,stillShowZeroSum:!0,coordinateSystemUsage:"box",left:0,top:0,right:0,bottom:0,width:null,height:null,label:{rotate:0,show:!0,overflow:"truncate",position:"outer",alignTo:"none",edgeDistance:"25%",distanceToLabelLine:5},labelLine:{show:!0,length:15,length2:30,smooth:!1,minTurnAngle:90,maxSurfaceAngle:90,lineStyle:{width:1,type:"solid"}},itemStyle:{borderWidth:1,borderJoin:"round"},showEmptyCircle:!0,emptyCircleStyle:{color:"lightgray",opacity:1},labelLayout:{hideOverlap:!0},emphasis:{scale:!0,scaleSize:5},avoidLabelOverlap:!0,animationType:"expansion",animationDuration:1e3,animationTypeUpdate:"transition",animationEasingUpdate:"cubicInOut",animationDurationUpdate:500,animationEasing:"cubicInOut"},n}(gd);function nb(t,n,i,r,e,a,o){var u=e-t,s=a-n,l=i-t,f=r-n,h=Math.sqrt(l*l+f*f),c=(u*(l/=h)+s*(f/=h))/h,v=o[0]=t+(c*=h)*l,d=o[1]=n+c*f;return Math.sqrt((v-e)*(v-e)+(d-a)*(d-a))}lc.set((Zg={fullType:tb.type,getCoord2:function(t){return t.getShallow("center")}}).fullType,{getCoord2:void 0}).getCoord2=Zg.getCoord2;var ib=new pn,rb=new pn,eb=new pn,ab=new pn,ob=new pn,ub=[],sb=new pn;function lb(t,n){if(n<=180&&n>0){n=n/180*Math.PI,ib.fromArray(t[0]),rb.fromArray(t[1]),eb.fromArray(t[2]),pn.sub(ab,ib,rb),pn.sub(ob,eb,rb);var i=ab.len(),r=ob.len();if(!(i<.001||r<.001)){ab.scale(1/i),ob.scale(1/r);var e=ab.dot(ob);if(Math.cos(n)<e){var a=nb(rb.x,rb.y,eb.x,eb.y,ib.x,ib.y,ub);sb.fromArray(ub),sb.scaleAndAdd(ob,a/Math.tan(Math.PI-n));var o=eb.x!==rb.x?(sb.x-rb.x)/(eb.x-rb.x):(sb.y-rb.y)/(eb.y-rb.y);if(isNaN(o))return;o<0?pn.copy(sb,rb):o>1&&pn.copy(sb,eb),sb.toArray(t[1])}}}}function fb(t,n,i){if(i<=180&&i>0){i=i/180*Math.PI,ib.fromArray(t[0]),rb.fromArray(t[1]),eb.fromArray(t[2]),pn.sub(ab,rb,ib),pn.sub(ob,eb,rb);var r=ab.len(),e=ob.len();if(!(r<.001||e<.001)&&(ab.scale(1/r),ob.scale(1/e),ab.dot(n)<Math.cos(i))){var a=nb(rb.x,rb.y,eb.x,eb.y,ib.x,ib.y,ub);sb.fromArray(ub);var o=Math.PI/2,u=o+Math.acos(ob.dot(n))-i;if(u>=o)pn.copy(sb,eb);else{sb.scaleAndAdd(ob,a/Math.tan(Math.PI/2-u));var s=eb.x!==rb.x?(sb.x-rb.x)/(eb.x-rb.x):(sb.y-rb.y)/(eb.y-rb.y);if(isNaN(s))return;s<0?pn.copy(sb,rb):s>1&&pn.copy(sb,eb)}sb.toArray(t[1])}}}function hb(t,n,i,r){var e="normal"===i,a=e?t:t.ensureState(i);a.ignore=n;var o=r.get("smooth");o=!0===o?.3:Math.max(+o,0)||0,a.shape=a.shape||{},a.shape.smooth=o;var u=r.getModel("lineStyle").getLineStyle();e?t.useStyle(u):a.style=u}function cb(t,n){var i=n.smooth,r=n.points;if(r)if(t.moveTo(r[0][0],r[0][1]),i>0&&r.length>=3){var e=sn(r[0],r[1]),a=sn(r[1],r[2]);if(!e||!a)return t.lineTo(r[1][0],r[1][1]),void t.lineTo(r[2][0],r[2][1]);var o=Math.min(e,a)*i,u=fn([],r[1],r[0],o/e),s=fn([],r[1],r[2],o/a),l=fn([],u,s,.5);t.bezierCurveTo(u[0],u[1],u[0],u[1],l[0],l[1]),t.bezierCurveTo(s[0],s[1],s[0],s[1],r[2][0],r[2][1])}else for(var f=1;f<r.length;f++)t.lineTo(r[f][0],r[f][1])}var vb=Math.PI/180;function db(t,n,i,r,e,a,o,u,s,l){if(!(t.length<2)){for(var f=t.length,h=0;h<f;h++)"outer"===t[h].position&&"labelLine"===t[h].labelAlignTo&&(t[h].linePoints[1][0]+=t[h].label.x-l,t[h].label.x=l);(function(t,n,i,r){var e=t.length,a=Fl[1],o=Pl[1];if(e<2)return!1;t.sort((function(t,n){return t.rect[a]-n.rect[a]}));for(var u,s=0,l=!1,f=0;f<e;f++){var h=t[f],c=h.rect;(u=c[a]-s)<0&&(c[a]-=u,h.label[a]-=u,l=!0),s=c[a]+c[o]}var v,d,p=t[0],m=t[e-1];function y(){v=p.rect[a]-i,d=r-m.rect[a]-m.rect[o]}function g(t,n,i){if(t<0){var r=Math.min(n,-t);if(r>0){b(r*i,0,e);var a=r+t;a<0&&w(-a*i,1)}else w(-t*i,1)}}function b(n,i,r){0!==n&&(l=!0);for(var e=i;e<r;e++){var o=t[e];o.rect[a]+=n,o.label[a]+=n}}function w(n,i){for(var r=[],u=0,s=1;s<e;s++){var l=t[s-1].rect,f=Math.max(t[s].rect[a]-l[a]-l[o],0);r.push(f),u+=f}if(u){var h=Math.min(Math.abs(n)/u,i);if(n>0)for(s=0;s<e-1;s++)b(r[s]*h,0,s+1);else for(s=e-1;s>0;s--)b(-r[s-1]*h,s,e)}}function x(t){var n=t<0?-1:1;t=Math.abs(t);for(var i=Math.ceil(t/(e-1)),r=0;r<e-1;r++)if(n>0?b(i,0,r+1):b(-i,e-r-1,e),(t-=i)<=0)return}return y(),v<0&&w(-v,.8),d<0&&w(d,.8),y(),g(v,d,1),g(d,v,-1),y(),v<0&&x(-v),d<0&&x(d),l})(t,0,s,s+o)&&function(t){for(var a={list:[],maxY:0},o={list:[],maxY:0},u=0;u<t.length;u++)if("none"===t[u].labelAlignTo){var s=t[u],l=s.label.y>i?o:a,f=Math.abs(s.label.y-i);if(f>=l.maxY){var h=s.label.x-n-s.len2*e,v=r+s.len,d=Math.abs(h)<v?Math.sqrt(f*f/(1-h*h/v/v)):v;l.rB=d,l.maxY=f}l.list.push(s)}c(a),c(o)}(t)}function c(t){for(var a=t.rB,o=a*a,u=0;u<t.list.length;u++){var s=t.list[u],l=Math.abs(s.label.y-i),f=r+s.len,h=Math.sqrt(Math.abs(f*f*(1-l*l/o))),c=n+(h+s.len2)*e;pb(s,s.targetTextWidth-(c-s.label.x)*e,!0),s.label.x=c}}}function pb(t,n,i){if(null==t.labelStyleWidth){var r=t.label,e=r.style,a=t.rect,o=e.backgroundColor,u=e.padding,s=u?u[1]+u[3]:0,l=e.overflow,f=a.width+(o?0:s);if(n<f||i){if(l&&l.match("break")){r.setStyle("backgroundColor",null),r.setStyle("width",n-s);var h=r.getBoundingRect();r.setStyle("width",Math.ceil(h.width)),r.setStyle("backgroundColor",o)}else{var c=n-s;r.setStyle("width",n<f?c:i?c>t.unconstrainedWidth?null:c:null)}mb(a,r)}}}function mb(t,n){gb.rect=t,my(gb,n,yb)}var yb={minMarginForce:[null,0,null,0],marginDefault:[1,0,1,0]},gb={};function bb(t){return"center"===t.position}var wb=2*Math.PI,xb=Math.PI/180,Mb=ru(Kg,(function(t,n){t.eachSeriesByType(Kg,(function(t){var i=t.getData(),r=i.mapDimension("value"),e=function(t,n){var i=function(t,n){var i,r,e=Tv(t,n,{enableLayoutOnlyByCenter:!0}),a=t.getBoxLayoutParams();if(e.type===Av.point)r=e.refPoint,i=Sv(a,{width:n.getWidth(),height:n.getHeight()});else{var o=t.get("center"),u=G(o)?o:[o,o];i=Sv(a,e.refContainer),r=2===e.boxCoordFrom?e.refPoint:[no(u[0],i.width)+i.x,no(u[1],i.height)+i.y]}return{viewRect:i,center:r}}(t,n),r=i.viewRect,e=i.center,a=t.get("radius");G(a)||(a=[0,a]);var o=no(r.width,n.getWidth()),u=no(r.height,n.getHeight()),s=Math.min(o,u),l=no(a[0],s/2),f=no(a[1],s/2);return{cx:e[0],cy:e[1],r0:l,r:f,viewRect:r}}(t,n),a=e.cx,o=e.cy,u=e.r,s=e.r0,l=e.viewRect,f=-t.get("startAngle")*xb,h=t.get("endAngle"),c=t.get("padAngle")*xb;h="auto"===h?f-wb:-h*xb;var v=t.get("minAngle")*xb+c,d=0;i.each(r,(function(t){!isNaN(t)&&d++}));var p=i.getSum(r),m=Math.PI/(p||d)*2,y=t.get("clockwise"),g=t.get("roseType"),b=t.get("stillShowZeroSum"),w=i.getDataExtent(r);w[0]=0;var x=y?1:-1,M=[f,h],k=x*c/2;Xe(M,!y),f=M[0],h=M[1];var S=kb(t);S.startAngle=f,S.endAngle=h,S.clockwise=y,S.cx=a,S.cy=o,S.r=u,S.r0=s;var A=Math.abs(h-f),T=A,N=0,C=f;if(i.setLayout({viewRect:l,r:u}),i.each(r,(function(t,n){var r;if(isNaN(t))i.setItemLayout(n,{angle:NaN,startAngle:NaN,endAngle:NaN,clockwise:y,cx:a,cy:o,r0:s,r:g?NaN:u});else{(r="area"!==g?0===p&&b?m:t*m:A/d)<v?(r=v,T-=v):N+=t;var e=C+x*r,l=0,f=0;c>r?f=l=C+x*r/2:(l=C+k,f=e-k),i.setItemLayout(n,{angle:r,startAngle:l,endAngle:f,clockwise:y,cx:a,cy:o,r0:s,r:g?to(t,w,[s,u]):u}),C=e}})),T<wb&&d)if(T<=.001){var O=A/d;i.each(r,(function(t,n){if(!isNaN(t)){var r=i.getItemLayout(n);r.angle=O;var e=0,a=0;O<c?a=e=f+x*(n+.5)*O:(e=f+x*n*O+k,a=f+x*(n+1)*O-k),r.startAngle=e,r.endAngle=a}}))}else m=T/N,C=f,i.each(r,(function(t,n){if(!isNaN(t)){var r=i.getItemLayout(n),e=r.angle===v?v:t*m,a=0,o=0;e<c?o=a=C+x*e/2:(a=C+k,o=C+x*e-k),r.startAngle=a,r.endAngle=o,C+=x*e}}))}))})),kb=Po(),Sb=function(t){function n(n,i,r){var e=t.call(this)||this;e.z2=2;var a=new Ia;return e.setTextContent(a),e.updateData(n,i,r,!0),e}return v(n,t),n.prototype.updateData=function(t,n,i,r){var e=this,a=t.hostModel,o=t.getItemModel(n),u=o.getModel("emphasis"),s=t.getItemLayout(n),l=P(Og(o.getModel("itemStyle"),s,!0),s);if(isNaN(l.startAngle))e.setShape(l);else{if(r){e.setShape(l);var f=a.getShallow("animationType");a.ecModel.ssr?(Ol(e,{scaleX:0,scaleY:0},a,{dataIndex:n,isFrom:!0}),e.originX=l.cx,e.originY=l.cy):"scale"===f?(e.shape.r=s.r0,Ol(e,{shape:{r:s.r}},a,n)):null!=i?(e.setShape({startAngle:i,endAngle:i}),Ol(e,{shape:{startAngle:s.startAngle,endAngle:s.endAngle}},a,n)):(e.shape.endAngle=s.startAngle,Cl(e,{shape:{endAngle:s.endAngle}},a,n))}else zl(e),Cl(e,{shape:l},a,n);e.useStyle(t.getItemVisual(n,"style")),ss(e,o);var h=(s.startAngle+s.endAngle)/2,c=a.get("selectedOffset"),v=Math.cos(h)*c,d=Math.sin(h)*c,p=o.getShallow("cursor");p&&e.attr("cursor",p),this._updateLabel(a,t,n),e.ensureState("emphasis").shape=P({r:s.r+(u.get("scale")&&u.get("scaleSize")||0)},Og(u.getModel("itemStyle"),s)),P(e.ensureState("select"),{x:v,y:d,shape:Og(o.getModel(["select","itemStyle"]),s)}),P(e.ensureState("blur"),{shape:Og(o.getModel(["blur","itemStyle"]),s)});var m=e.getTextGuideLine(),y=e.getTextContent();m&&P(m.ensureState("select"),{x:v,y:d}),P(y.ensureState("select"),{x:v,y:d}),as(this,u.get("focus"),u.get("blurScope"),u.get("disabled"))}},n.prototype._updateLabel=function(t,n,i){var r=this,e=n.getItemModel(i),a=e.getModel("labelLine"),o=n.getItemVisual(i,"style"),u=o&&o.fill,s=o&&o.opacity;yf(r,gf(e),{labelFetcher:n.hostModel,labelDataIndex:i,inheritColor:u,defaultOpacity:s,defaultText:t.getFormattedLabel(i,"normal")||n.getName(i)});var l=r.getTextContent();r.setTextConfig({position:null,rotation:null}),l.attr({z2:10});var f=e.get(["label","position"]);if("outside"!==f&&"outer"!==f)r.removeTextGuideLine();else{var h=this.getTextGuideLine();h||(h=new nl,this.setTextGuideLine(h)),function(t,n,i){var r=t.getTextGuideLine(),e=t.getTextContent();if(e){for(var a=n.normal,o=a.get("show"),u=e.ignore,s=0;s<Au.length;s++){var l=Au[s],f=n[l],h="normal"===l;if(f){var c=f.get("show");if((h?u:ut(e.states[l]&&e.states[l].ignore,u))||!ut(c,o)){var v=h?r:r&&r.states[l];v&&(v.ignore=!0),r&&hb(r,!0,l,f);continue}r||(r=new nl,t.setTextGuideLine(r),h||!u&&o||hb(r,!0,"normal",n.normal),t.stateProxy&&(r.stateProxy=t.stateProxy)),hb(r,!1,l,f)}}if(r){B(r.style,i),r.style.fill=null;var d=a.get("showAbove");(t.textGuideLineConfig=t.textGuideLineConfig||{}).showAbove=d||!1,r.buildPath=cb}}else r&&t.removeTextGuideLine()}(this,function(t,n){for(var i={normal:t.getModel(n=n||"labelLine")},r=0;r<Su.length;r++){var e=Su[r];i[e]=t.getModel([e,n])}return i}(e),{stroke:u,opacity:st(a.get(["lineStyle","opacity"]),s,1)})}},n}(qs),Ab=function(t){function n(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=Kg,n.ignoreLabelLineUpdate=!0,n}return v(n,t),n.prototype.render=function(t){var n,i=t.getData(),r=this._data,e=this.group;if(!r&&i.count()>0){for(var a=i.getItemLayout(0),o=1;isNaN(a&&a.startAngle)&&o<i.count();++o)a=i.getItemLayout(o);a&&(n=a.startAngle)}if(this._emptyCircleSector&&e.remove(this._emptyCircleSector),0===i.count()&&t.get("showEmptyCircle")){var u=kb(t),s=new qs({shape:R(u)});s.useStyle(t.getModel("emptyCircleStyle").getItemStyle()),this._emptyCircleSector=s,e.add(s)}i.diff(r).add((function(t){var r=new Sb(i,t,n);i.setItemGraphicEl(t,r),e.add(r)})).update((function(t,a){var o=r.getItemGraphicEl(a);o.updateData(i,t,n),o.off("click"),e.add(o),i.setItemGraphicEl(t,o)})).remove((function(n){_l(r.getItemGraphicEl(n),t,n)})).execute(),function(t){var n,i,r=t.getData(),e=[],a=!1,o=(t.get("minShowLabelAngle")||0)*vb,u=r.getLayout("viewRect"),s=r.getLayout("r"),l=u.width,f=u.x,h=u.y,c=u.height;function v(t){t.ignore=!0}r.each((function(t){var u=r.getItemGraphicEl(t),h=u.shape,d=u.getTextContent(),p=u.getTextGuideLine(),m=r.getItemModel(t),y=m.getModel("label"),g=y.get("position")||m.get(["emphasis","label","position"]),b=y.get("distanceToLabelLine"),w=y.get("alignTo"),x=no(y.get("edgeDistance"),l),M=y.get("bleedMargin");null==M&&(M=Math.min(l,c)>200?10:2);var k=m.getModel("labelLine"),S=k.get("length");S=no(S,l);var A=k.get("length2");if(A=no(A,l),Math.abs(h.endAngle-h.startAngle)<o)return H(d.states,v),d.ignore=!0,void(p&&(H(p.states,v),p.ignore=!0));if(function(t){if(!t.ignore)return!0;for(var n in t.states)if(!1===t.states[n].ignore)return!0;return!1}(d)){var T,N,C,O,I=(h.startAngle+h.endAngle)/2,L=Math.cos(I),D=Math.sin(I);n=h.cx,i=h.cy;var _="inside"===g||"inner"===g;if("center"===g)T=h.cx,N=h.cy,O="center";else{var z=(_?(h.r+h.r0)/2*L:h.r*L)+n,R=(_?(h.r+h.r0)/2*D:h.r*D)+i;if(T=z+3*L,N=R+3*D,!_){var F=z+L*(S+s-h.r),P=R+D*(S+s-h.r),B=F+(L<0?-1:1)*A;T="edge"===w?L<0?f+x:f+l-x:B+(L<0?-b:b),N=P,C=[[z,R],[F,P],[B,P]]}O=_?"center":"edge"===w?L>0?"right":"left":L>0?"left":"right"}var E=Math.PI,W=0,j=y.get("rotate");if(Q(j))W=j*(E/180);else if("center"===g)W=0;else if("radial"===j||!0===j)W=L<0?-I+E:-I;else if("tangential"===j||"tangential-noflip"===j&&"outside"!==g&&"outer"!==g){var U=Math.atan2(L,D);U<0&&(U=2*E+U),D>0&&"tangential-noflip"!==j&&(U=E+U),W=U-E}if(a=!!W,d.x=T,d.y=N,d.rotation=W,d.setStyle({verticalAlign:"middle"}),_){d.setStyle({align:O});var V=d.states.select;V&&(V.x+=d.x,V.y+=d.y)}else{var $=new On(0,0,0,0);mb($,d),e.push({label:d,labelLine:p,position:g,len:S,len2:A,minTurnAngle:k.get("minTurnAngle"),maxSurfaceAngle:k.get("maxSurfaceAngle"),surfaceNormal:new pn(L,D),linePoints:C,textAlign:O,labelDistance:b,labelAlignTo:w,edgeDistance:x,bleedMargin:M,rect:$,unconstrainedWidth:$.width,labelStyleWidth:d.style.width})}u.setTextConfig({inside:_})}})),!a&&t.get("avoidLabelOverlap")&&function(t,n,i,r,e,a,o,u){for(var s=[],l=[],f=Number.MAX_VALUE,h=-Number.MAX_VALUE,c=0;c<t.length;c++){var v=t[c].label;bb(t[c])||(v.x<n?(f=Math.min(f,v.x),s.push(t[c])):(h=Math.max(h,v.x),l.push(t[c])))}for(c=0;c<t.length;c++)if(!bb(m=t[c])&&m.linePoints){if(null!=m.labelStyleWidth)continue;v=m.label;var d,p=m.linePoints;m.targetTextWidth=d="edge"===m.labelAlignTo?v.x<n?p[2][0]-m.labelDistance-o-m.edgeDistance:o+e-m.edgeDistance-p[2][0]-m.labelDistance:"labelLine"===m.labelAlignTo?v.x<n?f-o-m.bleedMargin:o+e-h-m.bleedMargin:v.x<n?v.x-o-m.bleedMargin:o+e-v.x-m.bleedMargin,pb(m,d,!1)}for(db(l,n,i,r,1,0,a,0,u,h),db(s,n,i,r,-1,0,a,0,u,f),c=0;c<t.length;c++){var m;if(!bb(m=t[c])&&m.linePoints){var y=(v=m.label).style.padding,g=m.rect.width+(v.style.backgroundColor?0:y?y[1]+y[3]:0),b=(p=m.linePoints)[1][0]-p[2][0];"edge"===m.labelAlignTo?p[2][0]=v.x<n?o+m.edgeDistance+g+m.labelDistance:o+e-m.edgeDistance-g-m.labelDistance:(p[2][0]=v.x<n?v.x+m.labelDistance:v.x-m.labelDistance,p[1][0]=p[2][0]+b),p[1][1]=p[2][1]=v.y}}}(e,n,i,s,l,c,f,h);for(var d=0;d<e.length;d++){var p=e[d],m=p.label,y=p.labelLine,g=isNaN(m.x)||isNaN(m.y);if(m){m.setStyle({align:p.textAlign}),g&&(H(m.states,v),m.ignore=!0);var b=m.states.select;b&&(b.x+=m.x,b.y+=m.y)}if(y){var w=p.linePoints;g||!w?(H(y.states,v),y.ignore=!0):(lb(w,p.minTurnAngle),fb(w,p.surfaceNormal,p.maxSurfaceAngle),y.setShape({points:w}),m.__hostTarget.textGuideLineConfig={anchor:new pn(w[0][0],w[0][1])})}}}(t),"expansion"!==t.get("animationTypeUpdate")&&(this._data=i)},n.prototype.dispose=function(){},n.prototype.containPoint=function(t,n){var i=n.getData().getItemLayout(0);if(i){var r=t[0]-i.cx,e=t[1]-i.cy,a=Math.sqrt(r*r+e*e);return a<=i.r&&a>=i.r0}},n.type=Kg,n}(lp),Tb=function(t,n){this.target=t,this.topTarget=n&&n.topTarget},Nb=function(){function t(t){this.handler=t,t.on("mousedown",this._dragStart,this),t.on("mousemove",this._drag,this),t.on("mouseup",this._dragEnd,this)}return t.prototype._dragStart=function(t){for(var n=t.target;n&&!n.draggable;)n=n.parent||n.__hostTarget;n&&(this._draggingTarget=n,n.dragging=!0,this._x=t.offsetX,this._y=t.offsetY,this.handler.dispatchToElement(new Tb(n,t),"dragstart",t.event))},t.prototype._drag=function(t){var n=this._draggingTarget;if(n){var i=t.offsetX,r=t.offsetY,e=i-this._x,a=r-this._y;this._x=i,this._y=r,n.drift(e,a,t),this.handler.dispatchToElement(new Tb(n,t),"drag",t.event);var o=this.handler.findHover(i,r,n).target,u=this._dropTarget;this._dropTarget=o,n!==o&&(u&&o!==u&&this.handler.dispatchToElement(new Tb(u,t),"dragleave",t.event),o&&o!==u&&this.handler.dispatchToElement(new Tb(o,t),"dragenter",t.event))}},t.prototype._dragEnd=function(t){var n=this._draggingTarget;n&&(n.dragging=!1),this.handler.dispatchToElement(new Tb(n,t),"dragend",t.event),this._dropTarget&&this.handler.dispatchToElement(new Tb(this._dropTarget,t),"drop",t.event),this._draggingTarget=null,this._dropTarget=null},t}(),Cb=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,Ob=[],Ib=At.browser.firefox&&+At.browser.version.split(".")[0]<39;function Lb(t,n,i,r){return i=i||{},r?Db(t,n,i):Ib&&null!=n.layerX&&n.layerX!==n.offsetX?(i.zrX=n.layerX,i.zrY=n.layerY):null!=n.offsetX?(i.zrX=n.offsetX,i.zrY=n.offsetY):Db(t,n,i),i}function Db(t,n,i){if(At.domSupported&&t.getBoundingClientRect){var r=n.clientX,e=n.clientY;if(Sc(t)){var a=t.getBoundingClientRect();return i.zrX=r-a.left,void(i.zrY=e-a.top)}if(kc(Ob,t,r,e))return i.zrX=Ob[0],void(i.zrY=Ob[1])}i.zrX=i.zrY=0}function _b(t){return t||window.event}function zb(t,n,i){if(null!=(n=_b(n)).zrX)return n;var r=n.type;if(r&&r.indexOf("touch")>=0){var e="touchend"!==r?n.targetTouches[0]:n.changedTouches[0];e&&Lb(t,e,n,i)}else{Lb(t,n,n,i);var a=function(t){var n=t.wheelDelta;if(n)return n;var i=t.deltaX,r=t.deltaY;return null==i||null==r?n:3*(0!==r?Math.abs(r):Math.abs(i))*(r>0?-1:r<0?1:i>0?-1:1)}(n);n.zrDelta=a?a/120:-(n.detail||0)/3}var o=n.button;return null==n.which&&void 0!==o&&Cb.test(n.type)&&(n.which=1&o?1:2&o?3:4&o?2:0),n}function Rb(t,n,i,r){t.removeEventListener(n,i,r)}var Fb=function(t){t.preventDefault(),t.stopPropagation(),t.cancelBubble=!0},Pb=function(){function t(){this._track=[]}return t.prototype.recognize=function(t,n,i){return this._doTrack(t,n,i),this._recognize(t)},t.prototype.clear=function(){return this._track.length=0,this},t.prototype._doTrack=function(t,n,i){var r=t.touches;if(r){for(var e={points:[],touches:[],target:n,event:t},a=0,o=r.length;a<o;a++){var u=r[a],s=Lb(i,u,{});e.points.push([s.zrX,s.zrY]),e.touches.push(u)}this._track.push(e)}},t.prototype._recognize=function(t){for(var n in Eb)if(Eb.hasOwnProperty(n)){var i=Eb[n](this._track,t);if(i)return i}},t}();function Bb(t){var n=t[1][0]-t[0][0],i=t[1][1]-t[0][1];return Math.sqrt(n*n+i*i)}var Eb={pinch:function(t,n){var i=t.length;if(i){var r,e=(t[i-1]||{}).points,a=(t[i-2]||{}).points||e;if(a&&a.length>1&&e&&e.length>1){var o=Bb(e)/Bb(a);!isFinite(o)&&(o=1),n.pinchScale=o;var u=[((r=e)[0][0]+r[1][0])/2,(r[0][1]+r[1][1])/2];return n.pinchX=u[0],n.pinchY=u[1],{type:"pinch",target:t[0].target,event:n}}}}},Wb="silent";function jb(){Fb(this.event)}var Hb=function(t){function n(){var n=null!==t&&t.apply(this,arguments)||this;return n.handler=null,n}return Et(n,t),n.prototype.dispose=function(){},n.prototype.setCursor=function(){},n}(Ur),Ub=function(t,n){this.x=t,this.y=n},Vb=["click","dblclick","mousewheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],$b=new On(0,0,0,0),Yb=function(t){function n(n,i,r,e,a){var o=t.call(this)||this;return o._hovered=new Ub(0,0),o.storage=n,o.painter=i,o.painterRoot=e,o._pointerSize=a,r=r||new Hb,o.proxy=null,o.setHandlerProxy(r),o._draggingMgr=new Nb(o),o}return Et(n,t),n.prototype.setHandlerProxy=function(t){this.proxy&&this.proxy.dispose(),t&&(H(Vb,(function(n){t.on&&t.on(n,this[n],this)}),this),t.handler=this),this.proxy=t},n.prototype.mousemove=function(t){var n=t.zrX,i=t.zrY,r=Gb(this,n,i),e=this._hovered,a=e.target;a&&!a.__zr&&(a=(e=this.findHover(e.x,e.y)).target);var o=this._hovered=r?new Ub(n,i):this.findHover(n,i),u=o.target,s=this.proxy;s.setCursor&&s.setCursor(u?u.cursor:"default"),a&&u!==a&&this.dispatchToElement(e,"mouseout",t),this.dispatchToElement(o,"mousemove",t),u&&u!==a&&this.dispatchToElement(o,"mouseover",t)},n.prototype.mouseout=function(t){var n=t.zrEventControl;"only_globalout"!==n&&this.dispatchToElement(this._hovered,"mouseout",t),"no_globalout"!==n&&this.trigger("globalout",{type:"globalout",event:t})},n.prototype.resize=function(){this._hovered=new Ub(0,0)},n.prototype.dispatch=function(t,n){var i=this[t];i&&i.call(this,n)},n.prototype.dispose=function(){this.proxy.dispose(),this.storage=null,this.proxy=null,this.painter=null},n.prototype.setCursorStyle=function(t){var n=this.proxy;n.setCursor&&n.setCursor(t)},n.prototype.dispatchToElement=function(t,n,i){var r=(t=t||{}).target;if(!r||!r.silent){for(var e="on"+n,a=function(t,n,i){return{type:t,event:i,target:n.target,topTarget:n.topTarget,cancelBubble:!1,offsetX:i.zrX,offsetY:i.zrY,gestureEvent:i.gestureEvent,pinchX:i.pinchX,pinchY:i.pinchY,pinchScale:i.pinchScale,wheelDelta:i.zrDelta,zrByTouch:i.zrByTouch,which:i.which,stop:jb}}(n,t,i);r&&(r[e]&&(a.cancelBubble=!!r[e].call(r,a)),r.trigger(n,a),r=r.__hostTarget?r.__hostTarget:r.parent,!a.cancelBubble););a.cancelBubble||(this.trigger(n,a),this.painter&&this.painter.eachOtherLayer&&this.painter.eachOtherLayer((function(t){"function"==typeof t[e]&&t[e].call(t,a),t.trigger&&t.trigger(n,a)})))}},n.prototype.findHover=function(t,n,i){var r=this.storage.getDisplayList(),e=new Ub(t,n);if(qb(r,e,t,n,i),this._pointerSize&&!e.target){for(var a=[],o=this._pointerSize,u=o/2,s=new On(t-u,n-u,o,o),l=r.length-1;l>=0;l--){var f=r[l];f===i||f.ignore||f.ignoreCoarsePointer||f.parent&&f.parent.ignoreCoarsePointer||($b.copy(f.getBoundingRect()),f.transform&&$b.applyTransform(f.transform),$b.intersect(s)&&a.push(f))}if(a.length)for(var h=Math.PI/12,c=2*Math.PI,v=0;v<u;v+=4)for(var d=0;d<c;d+=h)if(qb(a,e,t+v*Math.cos(d),n+v*Math.sin(d),i),e.target)return e}return e},n.prototype.processGesture=function(t,n){this._gestureMgr||(this._gestureMgr=new Pb);var i=this._gestureMgr;"start"===n&&i.clear();var r=i.recognize(t,this.findHover(t.zrX,t.zrY,null).target,this.proxy.dom);if("end"===n&&i.clear(),r){var e=r.type;t.gestureEvent=e;var a=new Ub;a.target=r.target,this.dispatchToElement(a,e,r.event)}},n}(Ur);function Xb(t,n,i){if(t[t.rectHover?"rectContain":"contain"](n,i)){for(var r=t,e=void 0,a=!1;r;){if(r.ignoreClip&&(a=!0),!a){var o=r.getClipPath();if(o&&!o.contain(n,i))return!1}r.silent&&(e=!0);var u=r.__hostTarget;r=u?r.ignoreHostSilent?null:u:r.parent}return!e||Wb}return!1}function qb(t,n,i,r,e){for(var a=t.length-1;a>=0;a--){var o=t[a],u=void 0;if(o!==e&&!o.ignore&&(u=Xb(o,i,r))&&(!n.topTarget&&(n.topTarget=o),u!==Wb)){n.target=o;break}}}function Gb(t,n,i){var r=t.painter;return n<0||n>r.getWidth()||i<0||i>r.getHeight()}function Zb(t,n,i,r){var e=n+1;if(e===i)return 1;if(r(t[e++],t[n])<0){for(;e<i&&r(t[e],t[e-1])<0;)e++;!function(t,n,i){for(i--;n<i;){var r=t[n];t[n++]=t[i],t[i--]=r}}(t,n,e)}else for(;e<i&&r(t[e],t[e-1])>=0;)e++;return e-n}function Jb(t,n,i,r,e){for(r===n&&r++;r<i;r++){for(var a,o=t[r],u=n,s=r;u<s;)e(o,t[a=u+s>>>1])<0?s=a:u=a+1;var l=r-u;switch(l){case 3:t[u+3]=t[u+2];case 2:t[u+2]=t[u+1];case 1:t[u+1]=t[u];break;default:for(;l>0;)t[u+l]=t[u+l-1],l--}t[u]=o}}function Kb(t,n,i,r,e,a){var o=0,u=0,s=1;if(a(t,n[i+e])>0){for(u=r-e;s<u&&a(t,n[i+e+s])>0;)o=s,(s=1+(s<<1))<=0&&(s=u);s>u&&(s=u),o+=e,s+=e}else{for(u=e+1;s<u&&a(t,n[i+e-s])<=0;)o=s,(s=1+(s<<1))<=0&&(s=u);s>u&&(s=u);var l=o;o=e-s,s=e-l}for(o++;o<s;){var f=o+(s-o>>>1);a(t,n[i+f])>0?o=f+1:s=f}return s}function Qb(t,n,i,r,e,a){var o=0,u=0,s=1;if(a(t,n[i+e])<0){for(u=e+1;s<u&&a(t,n[i+e-s])<0;)o=s,(s=1+(s<<1))<=0&&(s=u);s>u&&(s=u);var l=o;o=e-s,s=e-l}else{for(u=r-e;s<u&&a(t,n[i+e+s])>=0;)o=s,(s=1+(s<<1))<=0&&(s=u);s>u&&(s=u),o+=e,s+=e}for(o++;o<s;){var f=o+(s-o>>>1);a(t,n[i+f])<0?s=f:o=f+1}return s}function tw(t,n,i,r){i||(i=0),r||(r=t.length);var e=r-i;if(!(e<2)){var a=0;if(e<32)Jb(t,i,r,i+(a=Zb(t,i,r,n)),n);else{var o=function(t,n){var i,r,e=7,a=0,o=[];function u(u){var s=i[u],l=r[u],f=i[u+1],h=r[u+1];r[u]=l+h,u===a-3&&(i[u+1]=i[u+2],r[u+1]=r[u+2]),a--;var c=Qb(t[f],t,s,l,0,n);s+=c,0!=(l-=c)&&0!==(h=Kb(t[s+l-1],t,f,h,h-1,n))&&(l<=h?function(i,r,a,u){var s=0;for(s=0;s<r;s++)o[s]=t[i+s];var l=0,f=a,h=i;if(t[h++]=t[f++],0!=--u)if(1!==r){for(var c,v,d,p=e;;){c=0,v=0,d=!1;do{if(n(t[f],o[l])<0){if(t[h++]=t[f++],v++,c=0,0==--u){d=!0;break}}else if(t[h++]=o[l++],c++,v=0,1==--r){d=!0;break}}while((c|v)<p);if(d)break;do{if(0!==(c=Qb(t[f],o,l,r,0,n))){for(s=0;s<c;s++)t[h+s]=o[l+s];if(h+=c,l+=c,(r-=c)<=1){d=!0;break}}if(t[h++]=t[f++],0==--u){d=!0;break}if(0!==(v=Kb(o[l],t,f,u,0,n))){for(s=0;s<v;s++)t[h+s]=t[f+s];if(h+=v,f+=v,0==(u-=v)){d=!0;break}}if(t[h++]=o[l++],1==--r){d=!0;break}p--}while(c>=7||v>=7);if(d)break;p<0&&(p=0),p+=2}if((e=p)<1&&(e=1),1===r){for(s=0;s<u;s++)t[h+s]=t[f+s];t[h+u]=o[l]}else{if(0===r)throw new Error;for(s=0;s<r;s++)t[h+s]=o[l+s]}}else{for(s=0;s<u;s++)t[h+s]=t[f+s];t[h+u]=o[l]}else for(s=0;s<r;s++)t[h+s]=o[l+s]}(s,l,f,h):function(i,r,a,u){var s=0;for(s=0;s<u;s++)o[s]=t[a+s];var l=i+r-1,f=u-1,h=a+u-1,c=0,v=0;if(t[h--]=t[l--],0!=--r)if(1!==u){for(var d=e;;){var p=0,m=0,y=!1;do{if(n(o[f],t[l])<0){if(t[h--]=t[l--],p++,m=0,0==--r){y=!0;break}}else if(t[h--]=o[f--],m++,p=0,1==--u){y=!0;break}}while((p|m)<d);if(y)break;do{if(0!=(p=r-Qb(o[f],t,i,r,r-1,n))){for(r-=p,v=1+(h-=p),c=1+(l-=p),s=p-1;s>=0;s--)t[v+s]=t[c+s];if(0===r){y=!0;break}}if(t[h--]=o[f--],1==--u){y=!0;break}if(0!=(m=u-Kb(t[l],o,0,u,u-1,n))){for(u-=m,v=1+(h-=m),c=1+(f-=m),s=0;s<m;s++)t[v+s]=o[c+s];if(u<=1){y=!0;break}}if(t[h--]=t[l--],0==--r){y=!0;break}d--}while(p>=7||m>=7);if(y)break;d<0&&(d=0),d+=2}if((e=d)<1&&(e=1),1===u){for(v=1+(h-=r),c=1+(l-=r),s=r-1;s>=0;s--)t[v+s]=t[c+s];t[h]=o[f]}else{if(0===u)throw new Error;for(c=h-(u-1),s=0;s<u;s++)t[c+s]=o[s]}}else{for(v=1+(h-=r),c=1+(l-=r),s=r-1;s>=0;s--)t[v+s]=t[c+s];t[h]=o[f]}else for(c=h-(u-1),s=0;s<u;s++)t[c+s]=o[s]}(s,l,f,h))}return i=[],r=[],{mergeRuns:function(){for(;a>1;){var t=a-2;if(t>=1&&r[t-1]<=r[t]+r[t+1]||t>=2&&r[t-2]<=r[t]+r[t-1])r[t-1]<r[t+1]&&t--;else if(r[t]>r[t+1])break;u(t)}},forceMergeRuns:function(){for(;a>1;){var t=a-2;t>0&&r[t-1]<r[t+1]&&t--,u(t)}},pushRun:function(t,n){i[a]=t,r[a]=n,a+=1}}}(t,n),u=function(t){for(var n=0;t>=32;)n|=1&t,t>>=1;return t+n}(e);do{if((a=Zb(t,i,r,n))<u){var s=e;s>u&&(s=u),Jb(t,i,i+s,i+a,n),a=s}o.pushRun(i,a),o.mergeRuns(),e-=a,i+=a}while(0!==e);o.forceMergeRuns()}}}H(["click","mousedown","mouseup","mousewheel","dblclick","contextmenu"],(function(t){Yb.prototype[t]=function(n){var i,r,e=n.zrX,a=n.zrY,o=Gb(this,e,a);if("mouseup"===t&&o||(r=(i=this.findHover(e,a)).target),"mousedown"===t)this._downEl=r,this._downPoint=[n.zrX,n.zrY],this._upEl=r;else if("mouseup"===t)this._upEl=r;else if("click"===t){if(this._downEl!==this._upEl||!this._downPoint||sn(this._downPoint,[n.zrX,n.zrY])>4)return;this._downPoint=null}this.dispatchToElement(i,t,n)}}));var nw=!1;function iw(){nw||(nw=!0,console.warn("z / z2 / zlevel of displayable is invalid, which may cause unexpected errors"))}function rw(t,n){return t.zlevel===n.zlevel?t.z===n.z?t.z2-n.z2:t.z-n.z:t.zlevel-n.zlevel}var ew,aw=function(){function t(){this._roots=[],this._displayList=[],this._displayListLen=0,this.displayableSortFunc=rw}return t.prototype.traverse=function(t,n){for(var i=0;i<this._roots.length;i++)this._roots[i].traverse(t,n)},t.prototype.getDisplayList=function(t,n){n=n||!1;var i=this._displayList;return!t&&i.length||this.updateDisplayList(n),i},t.prototype.updateDisplayList=function(t){this._displayListLen=0;for(var n=this._roots,i=this._displayList,r=0,e=n.length;r<e;r++)this._updateAndAddDisplayable(n[r],null,t);i.length=this._displayListLen,tw(i,rw)},t.prototype._updateAndAddDisplayable=function(t,n,i){if(!t.ignore||i){t.beforeUpdate(),t.update(),t.afterUpdate();var r=t.getClipPath(),e=n&&n.length,a=0,o=t.__clipPaths;if(!t.ignoreClip&&(e||r)){if(o||(o=t.__clipPaths=[]),e)for(var u=0;u<n.length;u++)o[a++]=n[u];for(var s=r,l=t;s;)s.parent=l,s.updateTransform(),o[a++]=s,l=s,s=s.getClipPath()}if(o&&(o.length=a),t.childrenRef){for(var f=t.childrenRef(),h=0;h<f.length;h++){var c=f[h];t.__dirty&&(c.__dirty|=1),this._updateAndAddDisplayable(c,o,i)}t.__dirty=0}else{var v=t;isNaN(v.z)&&(iw(),v.z=0),isNaN(v.z2)&&(iw(),v.z2=0),isNaN(v.zlevel)&&(iw(),v.zlevel=0),this._displayList[this._displayListLen++]=v}var d=t.getDecalElement&&t.getDecalElement();d&&this._updateAndAddDisplayable(d,o,i);var p=t.getTextGuideLine();p&&this._updateAndAddDisplayable(p,o,i);var m=t.getTextContent();m&&this._updateAndAddDisplayable(m,o,i)}},t.prototype.addRoot=function(t){t.__zr&&t.__zr.storage===this||this._roots.push(t)},t.prototype.delRoot=function(t){if(t instanceof Array)for(var n=0,i=t.length;n<i;n++)this.delRoot(t[n]);else{var r=E(this._roots,t);r>=0&&this._roots.splice(r,1)}},t.prototype.delAllRoots=function(){this._roots=[],this._displayList=[],this._displayListLen=0},t.prototype.getRoots=function(){return this._roots},t.prototype.dispose=function(){this._displayList=null,this._roots=null},t}();function ow(){return(new Date).getTime()}ew=At.hasGlobalWindow&&(window.requestAnimationFrame&&window.requestAnimationFrame.bind(window)||window.msRequestAnimationFrame&&window.msRequestAnimationFrame.bind(window)||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame)||function(t){return setTimeout(t,16)};var uw,sw,lw=function(t){function n(n){var i=t.call(this)||this;return i._running=!1,i._time=0,i._pausedTime=0,i._pauseStart=0,i._paused=!1,i.stage=(n=n||{}).stage||{},i}return Et(n,t),n.prototype.addClip=function(t){t.animation&&this.removeClip(t),this._head?(this._tail.next=t,t.prev=this._tail,t.next=null,this._tail=t):this._head=this._tail=t,t.animation=this},n.prototype.addAnimator=function(t){t.animation=this;var n=t.getClip();n&&this.addClip(n)},n.prototype.removeClip=function(t){if(t.animation){var n=t.prev,i=t.next;n?n.next=i:this._head=i,i?i.prev=n:this._tail=n,t.next=t.prev=t.animation=null}},n.prototype.removeAnimator=function(t){var n=t.getClip();n&&this.removeClip(n),t.animation=null},n.prototype.update=function(t){for(var n=ow()-this._pausedTime,i=n-this._time,r=this._head;r;){var e=r.next;r.step(n,i)?(r.ondestroy(),this.removeClip(r),r=e):r=e}this._time=n,t||(this.trigger("frame",i),this.stage.update&&this.stage.update())},n.prototype._startLoop=function(){var t=this;this._running=!0,ew((function n(){t._running&&(ew(n),!t._paused&&t.update())}))},n.prototype.start=function(){this._running||(this._time=ow(),this._pausedTime=0,this._startLoop())},n.prototype.stop=function(){this._running=!1},n.prototype.pause=function(){this._paused||(this._pauseStart=ow(),this._paused=!0)},n.prototype.resume=function(){this._paused&&(this._pausedTime+=ow()-this._pauseStart,this._paused=!1)},n.prototype.clear=function(){for(var t=this._head;t;){var n=t.next;t.prev=t.next=t.animation=null,t=n}this._head=this._tail=null},n.prototype.isFinished=function(){return null==this._head},n.prototype.animate=function(t,n){n=n||{},this.start();var i=new Hr(t,n.loop);return this.addAnimator(i),i},n}(Ur),fw=At.domSupported,hw=(sw={pointerdown:1,pointerup:1,pointermove:1,pointerout:1},{mouse:uw=["click","dblclick","mousewheel","wheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],touch:["touchstart","touchend","touchmove"],pointer:U(uw,(function(t){var n=t.replace("mouse","pointer");return sw.hasOwnProperty(n)?n:t}))}),cw=["mousemove","mouseup"],vw=["pointermove","pointerup"],dw=!1;function pw(t){var n=t.pointerType;return"pen"===n||"touch"===n}function mw(t){t&&(t.zrByTouch=!0)}function yw(t,n){for(var i=n,r=!1;i&&9!==i.nodeType&&!(r=i.domBelongToZr||i!==n&&i===t.painterRoot);)i=i.parentNode;return r}var gw=function(t,n){this.stopPropagation=Mt,this.stopImmediatePropagation=Mt,this.preventDefault=Mt,this.type=n.type,this.target=this.currentTarget=t.dom,this.pointerType=n.pointerType,this.clientX=n.clientX,this.clientY=n.clientY},bw={mousedown:function(t){t=zb(this.dom,t),this.__mayPointerCapture=[t.zrX,t.zrY],this.trigger("mousedown",t)},mousemove:function(t){t=zb(this.dom,t);var n=this.__mayPointerCapture;!n||t.zrX===n[0]&&t.zrY===n[1]||this.__togglePointerCapture(!0),this.trigger("mousemove",t)},mouseup:function(t){t=zb(this.dom,t),this.__togglePointerCapture(!1),this.trigger("mouseup",t)},mouseout:function(t){yw(this,(t=zb(this.dom,t)).toElement||t.relatedTarget)||(this.__pointerCapturing&&(t.zrEventControl="no_globalout"),this.trigger("mouseout",t))},wheel:function(t){dw=!0,t=zb(this.dom,t),this.trigger("mousewheel",t)},mousewheel:function(t){dw||(t=zb(this.dom,t),this.trigger("mousewheel",t))},touchstart:function(t){mw(t=zb(this.dom,t)),this.__lastTouchMoment=new Date,this.handler.processGesture(t,"start"),bw.mousemove.call(this,t),bw.mousedown.call(this,t)},touchmove:function(t){mw(t=zb(this.dom,t)),this.handler.processGesture(t,"change"),bw.mousemove.call(this,t)},touchend:function(t){mw(t=zb(this.dom,t)),this.handler.processGesture(t,"end"),bw.mouseup.call(this,t),+new Date-+this.__lastTouchMoment<300&&bw.click.call(this,t)},pointerdown:function(t){bw.mousedown.call(this,t)},pointermove:function(t){pw(t)||bw.mousemove.call(this,t)},pointerup:function(t){bw.mouseup.call(this,t)},pointerout:function(t){pw(t)||bw.mouseout.call(this,t)}};H(["click","dblclick","contextmenu"],(function(t){bw[t]=function(n){n=zb(this.dom,n),this.trigger(t,n)}}));var ww={pointermove:function(t){pw(t)||ww.mousemove.call(this,t)},pointerup:function(t){ww.mouseup.call(this,t)},mousemove:function(t){this.trigger("mousemove",t)},mouseup:function(t){var n=this.__pointerCapturing;this.__togglePointerCapture(!1),this.trigger("mouseup",t),n&&(t.zrEventControl="only_globalout",this.trigger("mouseout",t))}};function xw(t,n,i,r){t.mounted[n]=i,t.listenerOpts[n]=r,function(t,n,i,r){t.addEventListener(n,i,r)}(t.domTarget,n,i,r)}function Mw(t){var n=t.mounted;for(var i in n)n.hasOwnProperty(i)&&Rb(t.domTarget,i,n[i],t.listenerOpts[i]);t.mounted={}}var kw,Sw=function(t,n){this.mounted={},this.listenerOpts={},this.touching=!1,this.domTarget=t,this.domHandlers=n},Aw=function(t){function n(n,i){var r,e,a,o=t.call(this)||this;return o.__pointerCapturing=!1,o.dom=n,o.painterRoot=i,o._localHandlerScope=new Sw(n,bw),fw&&(o._globalHandlerScope=new Sw(document,ww)),r=o,a=(e=o._localHandlerScope).domHandlers,At.pointerEventsSupported?H(hw.pointer,(function(t){xw(e,t,(function(n){a[t].call(r,n)}))})):(At.touchEventsSupported&&H(hw.touch,(function(t){xw(e,t,(function(n){a[t].call(r,n),function(t){t.touching=!0,null!=t.touchTimer&&(clearTimeout(t.touchTimer),t.touchTimer=null),t.touchTimer=setTimeout((function(){t.touching=!1,t.touchTimer=null}),700)}(e)}))})),H(hw.mouse,(function(t){xw(e,t,(function(n){n=_b(n),e.touching||a[t].call(r,n)}))}))),o}return Et(n,t),n.prototype.dispose=function(){Mw(this._localHandlerScope),fw&&Mw(this._globalHandlerScope)},n.prototype.setCursor=function(t){this.dom.style&&(this.dom.style.cursor=t||"default")},n.prototype.__togglePointerCapture=function(t){if(this.__mayPointerCapture=null,fw&&+this.__pointerCapturing^+t){this.__pointerCapturing=t;var n=this._globalHandlerScope;t?function(t,n){function i(i){xw(n,i,(function(r){r=_b(r),yw(t,r.target)||(r=function(t,n){return zb(t.dom,new gw(t,n),!0)}(t,r),n.domHandlers[i].call(t,r))}),{capture:!0})}At.pointerEventsSupported?H(vw,i):At.touchEventsSupported||H(cw,i)}(this,n):Mw(n)}},n}(Ur),Tw={},Nw=function(){function t(t,n,i){var r=this;this._sleepAfterStill=10,this._stillFrameAccum=0,this._needsRefresh=!0,this._needsRefreshHover=!1,this._darkMode=!1,i=i||{},this.dom=n,this.id=t;var e=new aw,a=i.renderer||"canvas";Tw[a]||(a=Y(Tw)[0]),i.useDirtyRect=null!=i.useDirtyRect&&i.useDirtyRect;var o=new Tw[a](n,e,i,t),u=i.ssr||o.ssrOnly;this.storage=e,this.painter=o;var s,l=At.node||At.worker||u?null:new Aw(o.getViewportRoot(),o.root),f=i.useCoarsePointer;(null==f||"auto"===f?At.touchEventsSupported:!!f)&&(s=ut(i.pointerSize,44)),this.handler=new Yb(e,o,l,o.root,s),this.animation=new lw({stage:{update:u?null:function(){return r._flush(!1)}}}),u||this.animation.start()}return t.prototype.add=function(t){!this._disposed&&t&&(this.storage.addRoot(t),t.addSelfToZr(this),this.refresh())},t.prototype.remove=function(t){!this._disposed&&t&&(this.storage.delRoot(t),t.removeSelfFromZr(this),this.refresh())},t.prototype.configLayer=function(t,n){this._disposed||(this.painter.configLayer&&this.painter.configLayer(t,n),this.refresh())},t.prototype.setBackgroundColor=function(t){this._disposed||(this.painter.setBackgroundColor&&this.painter.setBackgroundColor(t),this.refresh(),this._backgroundColor=t,this._darkMode=function(t){if(!t)return!1;if("string"==typeof t)return hr(t,1)<.4;if(t.colorStops){for(var n=t.colorStops,i=0,r=n.length,e=0;e<r;e++)i+=hr(n[e].color,1);return(i/=r)<.4}return!1}(t))},t.prototype.getBackgroundColor=function(){return this._backgroundColor},t.prototype.setDarkMode=function(t){this._darkMode=t},t.prototype.isDarkMode=function(){return this._darkMode},t.prototype.refreshImmediately=function(t){this._disposed||this._refresh({animUpdate:!t,refresh:!0,refreshHover:!1})},t.prototype._refresh=function(t){t.animUpdate&&this.animation.update(!0),this._needsRefresh=this._needsRefreshHover=!1,this.painter.refresh({refresh:t.refresh,refreshHover:t.refreshHover}),this._needsRefresh=this._needsRefreshHover=!1},t.prototype.refresh=function(){this._disposed||(this._needsRefresh=!0,this.animation.start())},t.prototype.flush=function(){this._disposed||this._flush(!0)},t.prototype._flush=function(t){var n,i=ow(),r=this._needsRefresh,e=this._needsRefreshHover;(r||e)&&(n=!0,this._refresh({animUpdate:t,refresh:r,refreshHover:e}));var a=ow();n?(this._stillFrameAccum=0,this.trigger("rendered",{elapsedTime:a-i})):this._sleepAfterStill>0&&(this._stillFrameAccum++,this._stillFrameAccum>this._sleepAfterStill&&this.animation.stop())},t.prototype.setSleepAfterStill=function(t){this._sleepAfterStill=t},t.prototype.wakeUp=function(){this._disposed||(this.animation.start(),this._stillFrameAccum=0)},t.prototype.refreshHover=function(){this._needsRefreshHover=!0},t.prototype.refreshHoverImmediately=function(){this._disposed||this._refresh({animUpdate:!1,refresh:!1,refreshHover:!0})},t.prototype.resize=function(t){this._disposed||(this.painter.resize((t=t||{}).width,t.height),this.handler.resize())},t.prototype.clearAnimation=function(){this._disposed||this.animation.clear()},t.prototype.getWidth=function(){if(!this._disposed)return this.painter.getWidth()},t.prototype.getHeight=function(){if(!this._disposed)return this.painter.getHeight()},t.prototype.setCursorStyle=function(t){this._disposed||this.handler.setCursorStyle(t)},t.prototype.findHover=function(t,n){if(!this._disposed)return this.handler.findHover(t,n)},t.prototype.on=function(t,n,i){return this._disposed||this.handler.on(t,n,i),this},t.prototype.off=function(t,n){this._disposed||this.handler.off(t,n)},t.prototype.trigger=function(t,n){this._disposed||this.handler.trigger(t,n)},t.prototype.clear=function(){if(!this._disposed){for(var t=this.storage.getRoots(),n=0;n<t.length;n++)t[n]instanceof Is&&t[n].removeSelfFromZr(this);this.storage.delAllRoots(),this.painter.clear()}},t.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)},t}();function Cw(t,n){return new Nw(_(),t,n)}var Ow="";"undefined"!=typeof navigator&&(Ow=navigator.platform||"");var Iw,Lw,Dw,_w="rgba(0, 0, 0, 0.2)",zw=Jv.color.theme[0],Rw=lr(zw,0,null,.9),Fw={darkMode:"auto",colorBy:"series",color:Jv.color.theme,gradientColor:[Rw,zw],aria:{decal:{decals:[{color:_w,dashArrayX:[1,0],dashArrayY:[2,5],symbolSize:1,rotation:Math.PI/6},{color:_w,symbol:"circle",dashArrayX:[[8,8],[0,8,8,0]],dashArrayY:[6,0],symbolSize:.8},{color:_w,dashArrayX:[1,0],dashArrayY:[4,3],rotation:-Math.PI/4},{color:_w,dashArrayX:[[6,6],[0,6,6,0]],dashArrayY:[6,0]},{color:_w,dashArrayX:[[1,0],[1,6]],dashArrayY:[1,0,6,0],rotation:Math.PI/4},{color:_w,symbol:"triangle",dashArrayX:[[9,9],[0,9,9,0]],dashArrayY:[7,2],symbolSize:.75}]}},textStyle:{fontFamily:Ow.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},Pw=bt(),Bw="\0_ec_inner",Ew=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return v(n,t),n.prototype.init=function(t,n,i,r,e,a){r=r||{},this.option=null,this._theme=new Wf(r),this._locale=new Wf(e),this._optionManager=a},n.prototype.setOption=function(t,n,i){var r=Hw(n);this._optionManager.setOption(t,i,r),this._resetOption(null,r)},n.prototype.resetOption=function(t,n){return this._resetOption(t,Hw(n))},n.prototype._resetOption=function(t,n){var i=!1,r=this._optionManager;if(!t||"recreate"===t){var e=r.mountOption("recreate"===t);this.option&&"recreate"!==t?(this.restoreData(),this._mergeOption(e,n)):Dw(this,e),i=!0}if("timeline"!==t&&"media"!==t||this.restoreData(),!t||"recreate"===t||"timeline"===t){var a=r.getTimelineOption(this);a&&(i=!0,this._mergeOption(a,n))}if(!t||"recreate"===t||"media"===t){var o=r.getMediaOption(this);o.length&&H(o,(function(t){i=!0,this._mergeOption(t,n)}),this)}return i},n.prototype.mergeOption=function(t){this._mergeOption(t,null)},n.prototype._mergeOption=function(t,n){var i=this.option,r=this._componentsMap,e=this._componentsCount,a=[],o=bt(),u=n&&n.replaceMergeMainTypeMap;Vf(this).datasetMap=bt(),H(t,(function(t,n){null!=t&&(Lv.hasClass(n)?n&&(a.push(n),o.set(n,!0)):i[n]=null==i[n]?R(t):F(i[n],t,!0))})),u&&u.each((function(t,n){Lv.hasClass(n)&&!o.get(n)&&(a.push(n),o.set(n,!0))})),Lv.topologicalTravel(a,Lv.getAllClassMainTypes(),(function(n){var a=function(t,n,i){var r=Pw.get(n);if(!r)return i;var e=r(t);return e?i.concat(e):i}(this,n,To(t[n])),o=r.get(n),s=function(t,n,i){var r="normalMerge"===i,e="replaceMerge"===i,a="replaceAll"===i;t=t||[],n=(n||[]).slice();var o=bt();H(n,(function(t,i){tt(t)||(n[i]=null)}));var u,s,l=function(t,n,i){var r=[];if("replaceAll"===i)return r;for(var e=0;e<t.length;e++){var a=t[e];a&&null!=a.id&&n.set(a.id,e),r.push({existing:"replaceMerge"===i||Ro(a)?null:a,newOption:null,keyInfo:null,brandNew:null})}return r}(t,o,i);return(r||e)&&function(t,n,i,r){H(r,(function(e,a){if(e&&null!=e.id){var o=Do(e.id),u=i.get(o);if(null!=u){var s=t[u];ht(!s.newOption,'Duplicated option on id "'+o+'".'),s.newOption=e,s.existing=n[u],r[a]=null}}}))}(l,t,o,n),r&&function(t,n){H(n,(function(i,r){if(i&&null!=i.name)for(var e=0;e<t.length;e++){var a=t[e].existing;if(!t[e].newOption&&a&&(null==a.id||null==i.id)&&!Ro(i)&&!Ro(a)&&Lo("name",a,i))return t[e].newOption=i,void(n[r]=null)}}))}(l,n),r||e?function(t,n,i){H(n,(function(n){if(n){for(var r,e=0;(r=t[e])&&(r.newOption||Ro(r.existing)||r.existing&&null!=n.id&&!Lo("id",n,r.existing));)e++;r?(r.newOption=n,r.brandNew=i):t.push({newOption:n,brandNew:i,existing:null,keyInfo:null}),e++}}))}(l,n,e):a&&function(t,n){H(n,(function(n){t.push({newOption:n,brandNew:!0,existing:null,keyInfo:null})}))}(l,n),u=l,s=bt(),H(u,(function(t){var n=t.existing;n&&s.set(n.id,t)})),H(u,(function(t){var n=t.newOption;ht(!n||null==n.id||!s.get(n.id)||s.get(n.id)===t,"id duplicates: "+(n&&n.id)),n&&null!=n.id&&s.set(n.id,t),!t.keyInfo&&(t.keyInfo={})})),H(u,(function(t,n){var i=t.existing,r=t.newOption,e=t.keyInfo;if(tt(r)){if(e.name=null!=r.name?Do(r.name):i?i.name:Ao+n,i)e.id=Do(i.id);else if(null!=r.id)e.id=Do(r.id);else{var a=0;do{e.id="\0"+e.name+"\0"+a++}while(s.get(e.id))}s.set(e.id,t)}})),l}(o,a,o?u&&u.get(n)?"replaceMerge":"normalMerge":"replaceAll");(function(t,n,i){H(t,(function(t){var r=t.newOption;tt(r)&&(t.keyInfo.mainType=n,t.keyInfo.subType=function(t,n,i,r){return n.type?n.type:i?i.subType:r.determineSubType(t,n)}(n,r,t.existing,i))}))})(s,n,Lv),i[n]=null,r.set(n,null),e.set(n,0);var l,f=[],h=[],c=0;H(s,(function(t,i){var r=t.existing,e=t.newOption;if(e){var a=Lv.getClass(n,t.keyInfo.subType,!("series"===n));if(!a)return;if("tooltip"===n){if(l)return;l=!0}if(r&&r.constructor===a)r.name=t.keyInfo.name,r.mergeOption(e,this),r.optionUpdated(e,!1);else{var o=P({componentIndex:i},t.keyInfo);P(r=new a(e,this,this,o),o),t.brandNew&&(r.__requireNewView=!0),r.init(e,this,this),r.optionUpdated(null,!0)}}else r&&(r.mergeOption({},this),r.optionUpdated({},!1));r?(f.push(r.option),h.push(r),c++):(f.push(void 0),h.push(void 0))}),this),i[n]=f,r.set(n,h),e.set(n,c),"series"===n&&Iw(this)}),this),this._seriesIndices||Iw(this)},n.prototype.getOption=function(){var t=R(this.option);return H(t,(function(n,i){if(Lv.hasClass(i)){for(var r=To(n),e=r.length,a=!1,o=e-1;o>=0;o--)r[o]&&!Ro(r[o])?a=!0:(r[o]=null,!a&&e--);r.length=e,t[i]=r}})),delete t[Bw],t},n.prototype.setTheme=function(t){this._theme=new Wf(t),this._resetOption("recreate",null)},n.prototype.getTheme=function(){return this._theme},n.prototype.getLocaleModel=function(){return this._locale},n.prototype.setUpdatePayload=function(t){this._payload=t},n.prototype.getUpdatePayload=function(){return this._payload},n.prototype.getComponent=function(t,n){var i=this._componentsMap.get(t);if(i){var r=i[n||0];if(r)return r;if(null==n)for(var e=0;e<i.length;e++)if(i[e])return i[e]}},n.prototype.queryComponents=function(t){var n=t.mainType;if(!n)return[];var i,r=t.index,e=t.id,a=t.name,o=this._componentsMap.get(n);return o&&o.length?(null!=r?(i=[],H(To(r),(function(t){o[t]&&i.push(o[t])}))):i=null!=e?Ww("id",e,o):null!=a?Ww("name",a,o):$(o,(function(t){return!!t})),jw(i,t)):[]},n.prototype.findComponents=function(t){var n,i,r,e,a,o=t.mainType,u=(i=o+"Index",r=o+"Id",e=o+"Name",!(n=t.query)||null==n[i]&&null==n[r]&&null==n[e]?null:{mainType:o,index:n[i],id:n[r],name:n[e]});return a=jw(u?this.queryComponents(u):$(this._componentsMap.get(o),(function(t){return!!t})),t),t.filter?$(a,t.filter):a},n.prototype.eachComponent=function(t,n,i){var r=this._componentsMap;if(Z(t)){var e=n,a=t;r.each((function(t,n){for(var i=0;t&&i<t.length;i++){var r=t[i];r&&a.call(e,n,r,r.componentIndex)}}))}else for(var o=J(t)?r.get(t):tt(t)?this.findComponents(t):null,u=0;o&&u<o.length;u++){var s=o[u];s&&n.call(i,s,s.componentIndex)}},n.prototype.getSeriesByName=function(t){var n=_o(t,null);return $(this._componentsMap.get("series"),(function(t){return!!t&&null!=n&&t.name===n}))},n.prototype.getSeriesByIndex=function(t){return this._componentsMap.get("series")[t]},n.prototype.getSeriesByType=function(t){return $(this._componentsMap.get("series"),(function(n){return!!n&&n.subType===t}))},n.prototype.getSeries=function(){return $(this._componentsMap.get("series"),(function(t){return!!t}))},n.prototype.getSeriesCount=function(){return this._componentsCount.get("series")},n.prototype.eachSeries=function(t,n){Lw(this),H(this._seriesIndices,(function(i){var r=this._componentsMap.get("series")[i];t.call(n,r,i)}),this)},n.prototype.eachRawSeries=function(t,n){H(this._componentsMap.get("series"),(function(i){i&&t.call(n,i,i.componentIndex)}))},n.prototype.eachSeriesByType=function(t,n,i){Lw(this),H(this._seriesIndices,(function(r){var e=this._componentsMap.get("series")[r];e.subType===t&&n.call(i,e,r)}),this)},n.prototype.eachRawSeriesByType=function(t,n,i){return H(this.getSeriesByType(t),n,i)},n.prototype.isSeriesFiltered=function(t){return Lw(this),null==this._seriesIndicesMap.get(t.componentIndex)},n.prototype.getCurrentSeriesIndices=function(){return(this._seriesIndices||[]).slice()},n.prototype.filterSeries=function(t,n){Lw(this);var i=[];H(this._seriesIndices,(function(r){var e=this._componentsMap.get("series")[r];t.call(n,e,r)&&i.push(r)}),this),this._seriesIndices=i,this._seriesIndicesMap=bt(i)},n.prototype.restoreData=function(t){Iw(this);var n=this._componentsMap,i=[];n.each((function(t,n){Lv.hasClass(n)&&i.push(n)})),Lv.topologicalTravel(i,Lv.getAllClassMainTypes(),(function(i){H(n.get(i),(function(n){!n||"series"===i&&function(t,n){if(n){var i=n.seriesIndex,r=n.seriesId,e=n.seriesName;return null!=i&&t.componentIndex!==i||null!=r&&t.id!==r||null!=e&&t.name!==e}}(n,t)||n.restoreData()}))}))},n.internalField=(Iw=function(t){var n=t._seriesIndices=[];H(t._componentsMap.get("series"),(function(t){t&&n.push(t.componentIndex)})),t._seriesIndicesMap=bt(n)},Lw=function(){},void(Dw=function(t,n){t.option={},t.option[Bw]=1,t._componentsMap=bt({series:[]}),t._componentsCount=bt();var i=n.aria;tt(i)&&null==i.enabled&&(i.enabled=!0),function(t,n){var i=t.color&&!t.colorLayer;H(n,(function(n,r){"colorLayer"===r&&i||"color"===r&&t.color||Lv.hasClass(r)||("object"==typeof n?t[r]=t[r]?F(t[r],n,!1):R(n):null==t[r]&&(t[r]=n))}))}(n,t._theme.option),F(n,Fw,!1),t._mergeOption(n,null)})),n}(Wf);function Ww(t,n,i){if(G(n)){var r=bt();return H(n,(function(t){null!=t&&null!=_o(t,null)&&r.set(t,!0)})),$(i,(function(n){return n&&r.get(n[t])}))}var e=_o(n,null);return $(i,(function(n){return n&&null!=e&&n[t]===e}))}function jw(t,n){return n.hasOwnProperty("subType")?$(t,(function(t){return t&&t.subType===n.subType})):t}function Hw(t){var n=bt();return t&&H(To(t.replaceMerge),(function(t){n.set(t,!0)})),{replaceMergeMainTypeMap:n}}W(Ew,_v);var Uw=/^(min|max)?(.+)$/,Vw=function(){function t(t){this._timelineOptions=[],this._mediaList=[],this._currentMediaIndices=[],this._api=t}return t.prototype.setOption=function(t,n){t&&(H(To(t.series),(function(t){t&&t.data&&it(t.data)&&dt(t.data)})),H(To(t.dataset),(function(t){t&&t.source&&it(t.source)&&dt(t.source)}))),t=R(t);var i=this._optionBackup,r=function(t,n,i){var r,e,a=[],o=t.baseOption,u=t.timeline,s=t.options,l=t.media,f=!!t.media,h=!!(s||u||o&&o.timeline);function c(t){H(n,(function(n){n(t,i)}))}return o?(e=o).timeline||(e.timeline=u):((h||f)&&(t.options=t.media=null),e=t),f&&G(l)&&H(l,(function(t){t&&t.option&&(t.query?a.push(t):r||(r=t))})),c(e),H(s,(function(t){return c(t)})),H(a,(function(t){return c(t.option)})),{baseOption:e,timelineOptions:s||[],mediaDefault:r,mediaList:a}}(t,n,!i);this._newBaseOption=r.baseOption,i?(r.timelineOptions.length&&(i.timelineOptions=r.timelineOptions),r.mediaList.length&&(i.mediaList=r.mediaList),r.mediaDefault&&(i.mediaDefault=r.mediaDefault)):this._optionBackup=r},t.prototype.mountOption=function(t){var n=this._optionBackup;return this._timelineOptions=n.timelineOptions,this._mediaList=n.mediaList,this._mediaDefault=n.mediaDefault,this._currentMediaIndices=[],R(t?n.baseOption:this._newBaseOption)},t.prototype.getTimelineOption=function(t){var n,i=this._timelineOptions;if(i.length){var r=t.getComponent("timeline");r&&(n=R(i[r.getCurrentIndex()]))}return n},t.prototype.getMediaOption=function(){var t,n=this._api.getWidth(),i=this._api.getHeight(),r=this._mediaList,e=this._mediaDefault,a=[],o=[];if(!r.length&&!e)return o;for(var u=0,s=r.length;u<s;u++)$w(r[u].query,n,i)&&a.push(u);return!a.length&&e&&(a=[-1]),a.length&&(t=this._currentMediaIndices,a.join(",")!==t.join(","))&&(o=U(a,(function(t){return R(-1===t?e.option:r[t].option)}))),this._currentMediaIndices=a,o},t}();function $w(t,n,i){var r={width:n,height:i,aspectratio:n/i},e=!0;return H(t,(function(t,n){var i=n.match(Uw);if(i&&i[1]&&i[2]){var a=i[1],o=i[2].toLowerCase();(function(t,n,i){return"min"===i?t>=n:"max"===i?t<=n:t===n})(r[o],t,a)||(e=!1)}})),e}var Yw=H,Xw=tt,qw=["areaStyle","lineStyle","nodeStyle","linkStyle","chordStyle","label","labelLine"];function Gw(t){var n=t&&t.itemStyle;if(n)for(var i=0,r=qw.length;i<r;i++){var e=qw[i],a=n.normal,o=n.emphasis;a&&a[e]&&(t[e]=t[e]||{},t[e].normal?F(t[e].normal,a[e]):t[e].normal=a[e],a[e]=null),o&&o[e]&&(t[e]=t[e]||{},t[e].emphasis?F(t[e].emphasis,o[e]):t[e].emphasis=o[e],o[e]=null)}}function Zw(t,n,i){if(t&&t[n]&&(t[n].normal||t[n].emphasis)){var r=t[n].normal,e=t[n].emphasis;r&&(i?(t[n].normal=t[n].emphasis=null,B(t[n],r)):t[n]=r),e&&(t.emphasis=t.emphasis||{},t.emphasis[n]=e,e.focus&&(t.emphasis.focus=e.focus),e.blurScope&&(t.emphasis.blurScope=e.blurScope))}}function Jw(t){Zw(t,"itemStyle"),Zw(t,"lineStyle"),Zw(t,"areaStyle"),Zw(t,"label"),Zw(t,"labelLine"),Zw(t,"upperLabel"),Zw(t,"edgeLabel")}function Kw(t,n){var i=Xw(t)&&t[n],r=Xw(i)&&i.textStyle;if(r)for(var e=0,a=Co.length;e<a;e++){var o=Co[e];r.hasOwnProperty(o)&&(i[o]=r[o])}}function Qw(t){t&&(Jw(t),Kw(t,"label"),t.emphasis&&Kw(t.emphasis,"label"))}function tx(t){return G(t)?t:t?[t]:[]}function nx(t){return(G(t)?t[0]:t)||{}}function ix(t){t&&H(rx,(function(n){n[0]in t&&!(n[1]in t)&&(t[n[1]]=t[n[0]])}))}var rx=[["x","left"],["y","top"],["x2","right"],["y2","bottom"]],ex=["grid","geo","parallel","legend","toolbox","title","visualMap","dataZoom","timeline"],ax=[["borderRadius","barBorderRadius"],["borderColor","barBorderColor"],["borderWidth","barBorderWidth"]];function ox(t){var n=t&&t.itemStyle;if(n)for(var i=0;i<ax.length;i++){var r=ax[i][1];null!=n[r]&&(n[ax[i][0]]=n[r])}}function ux(t){t&&"edge"===t.alignTo&&null!=t.margin&&null==t.edgeDistance&&(t.edgeDistance=t.margin)}function sx(t){t&&t.downplay&&!t.blur&&(t.blur=t.downplay)}function lx(t,n){if(t)for(var i=0;i<t.length;i++)n(t[i]),t[i]&&lx(t[i].children,n)}function fx(t,n){(function(t,n){Yw(tx(t.series),(function(t){Xw(t)&&function(t){if(Xw(t)){Gw(t),Jw(t),Kw(t,"label"),Kw(t,"upperLabel"),Kw(t,"edgeLabel"),t.emphasis&&(Kw(t.emphasis,"label"),Kw(t.emphasis,"upperLabel"),Kw(t.emphasis,"edgeLabel"));var n=t.markPoint;n&&(Gw(n),Qw(n));var i=t.markLine;i&&(Gw(i),Qw(i));var r=t.markArea;r&&Qw(r);var e=t.data;if("graph"===t.type){e=e||t.nodes;var a=t.links||t.edges;if(a&&!it(a))for(var o=0;o<a.length;o++)Qw(a[o]);H(t.categories,(function(t){Jw(t)}))}if(e&&!it(e))for(o=0;o<e.length;o++)Qw(e[o]);if((n=t.markPoint)&&n.data){var u=n.data;for(o=0;o<u.length;o++)Qw(u[o])}if((i=t.markLine)&&i.data){var s=i.data;for(o=0;o<s.length;o++)G(s[o])?(Qw(s[o][0]),Qw(s[o][1])):Qw(s[o])}"gauge"===t.type?(Kw(t,"axisLabel"),Kw(t,"title"),Kw(t,"detail")):"treemap"===t.type?(Zw(t.breadcrumb,"itemStyle"),H(t.levels,(function(t){Jw(t)}))):"tree"===t.type&&Jw(t.leaves)}}(t)}));var i=["xAxis","yAxis","radiusAxis","angleAxis","singleAxis","parallelAxis","radar"];n&&i.push("valueAxis","categoryAxis","logAxis","timeAxis"),Yw(i,(function(n){Yw(tx(t[n]),(function(t){t&&(Kw(t,"axisLabel"),Kw(t.axisPointer,"label"))}))})),Yw(tx(t.parallel),(function(t){var n=t&&t.parallelAxisDefault;Kw(n,"axisLabel"),Kw(n&&n.axisPointer,"label")})),Yw(tx(t.calendar),(function(t){Zw(t,"itemStyle"),Kw(t,"dayLabel"),Kw(t,"monthLabel"),Kw(t,"yearLabel")})),Yw(tx(t.radar),(function(t){Kw(t,"name"),t.name&&null==t.axisName&&(t.axisName=t.name,delete t.name),null!=t.nameGap&&null==t.axisNameGap&&(t.axisNameGap=t.nameGap,delete t.nameGap)})),Yw(tx(t.geo),(function(t){Xw(t)&&(Qw(t),Yw(tx(t.regions),(function(t){Qw(t)})))})),Yw(tx(t.timeline),(function(t){Qw(t),Zw(t,"label"),Zw(t,"itemStyle"),Zw(t,"controlStyle",!0);var n=t.data;G(n)&&H(n,(function(t){tt(t)&&(Zw(t,"label"),Zw(t,"itemStyle"))}))})),Yw(tx(t.toolbox),(function(t){Zw(t,"iconStyle"),Yw(t.feature,(function(t){Zw(t,"iconStyle")}))})),Kw(nx(t.axisPointer),"label"),Kw(nx(t.tooltip).axisPointer,"label")})(t,n),t.series=To(t.series),H(t.series,(function(t){if(tt(t)){var n=t.type;if("line"===n)null!=t.clipOverflow&&(t.clip=t.clipOverflow);else if("pie"===n||"gauge"===n){if(null!=t.clockWise&&(t.clockwise=t.clockWise),ux(t.label),(e=t.data)&&!it(e))for(var i=0;i<e.length;i++)ux(e[i]);null!=t.hoverOffset&&(t.emphasis=t.emphasis||{},(t.emphasis.scaleSize=null)&&(t.emphasis.scaleSize=t.hoverOffset))}else if("gauge"===n){var r=function(t){for(var n="pointer.color".split(","),i=t,r=0;r<n.length&&null!=(i=i&&i[n[r]]);r++);return i}(t);null!=r&&function(t,n,i){for(var r,e="itemStyle.color".split(","),a=t,o=0;o<e.length-1;o++)null==a[r=e[o]]&&(a[r]={}),a=a[r];null==a[e[o]]&&(a[e[o]]=i)}(t,0,r)}else if("bar"===n){var e;if(ox(t),ox(t.backgroundStyle),ox(t.emphasis),(e=t.data)&&!it(e))for(i=0;i<e.length;i++)"object"==typeof e[i]&&(ox(e[i]),ox(e[i]&&e[i].emphasis))}else if("sunburst"===n){var a=t.highlightPolicy;a&&(t.emphasis=t.emphasis||{},t.emphasis.focus||(t.emphasis.focus=a)),sx(t),lx(t.data,sx)}else"graph"===n||"sankey"===n?function(t){t&&null!=t.focusNodeAdjacency&&(t.emphasis=t.emphasis||{},null==t.emphasis.focus&&(t.emphasis.focus="adjacency"))}(t):"map"===n&&(t.mapType&&!t.map&&(t.map=t.mapType),t.mapLocation&&B(t,t.mapLocation));null!=t.hoverAnimation&&(t.emphasis=t.emphasis||{},t.emphasis&&null==t.emphasis.scale&&(t.emphasis.scale=t.hoverAnimation)),ix(t)}})),t.dataRange&&(t.visualMap=t.dataRange),H(ex,(function(n){var i=t[n];i&&(G(i)||(i=[i]),H(i,(function(t){ix(t)})))}))}var hx=eu((function(t){var n=bt();t.eachSeries((function(t){var i=t.get("stack");if(i){var r=n.get(i)||n.set(i,[]),e=t.getData(),a={stackResultDimension:e.getCalculationInfo("stackResultDimension"),stackedOverDimension:e.getCalculationInfo("stackedOverDimension"),stackedDimension:e.getCalculationInfo("stackedDimension"),stackedByDimension:e.getCalculationInfo("stackedByDimension"),isStackedByIndex:e.getCalculationInfo("isStackedByIndex"),data:e,seriesModel:t};if(!a.stackedDimension||!a.isStackedByIndex&&!a.stackedByDimension)return;r.push(a)}})),n.each((function(t){0!==t.length&&("seriesDesc"===(t[0].seriesModel.get("stackOrder")||"seriesAsc")&&t.reverse(),H(t,(function(n,i){n.data.setCalculationInfo("stackedOnSeries",i>0?t[i-1].seriesModel:null)})),function(t){H(t,(function(n,i){var r=[],e=[NaN,NaN],a=[n.stackResultDimension,n.stackedOverDimension],o=n.data,u=n.isStackedByIndex,s=n.seriesModel.get("stackStrategy")||"samesign";o.modify(a,(function(a,l,f){var h,c,v=o.get(n.stackedDimension,f);if(isNaN(v))return e;u?c=o.getRawIndex(f):h=o.get(n.stackedByDimension,f);for(var d=NaN,p=i-1;p>=0;p--){var m=t[p];if(u||(c=m.data.rawIndexOf(m.stackedByDimension,h)),c>=0){var y=m.data.getByRawIndex(m.stackResultDimension,c);if("all"===s||"positive"===s&&y>0||"negative"===s&&y<0||"samesign"===s&&v>=0&&y>0||"samesign"===s&&v<=0&&y<0){v=oo(v,y),d=y;break}}}return r[0]=v,r[1]=d,r}))}))}(t))}))})),cx=function(){function t(){this.group=new Is,this.uid=yc("viewComponent")}return t.prototype.init=function(){},t.prototype.render=function(){},t.prototype.dispose=function(){},t.prototype.updateView=function(){},t.prototype.updateLayout=function(){},t.prototype.updateVisual=function(){},t.prototype.toggleBlurSeries=function(){},t.prototype.eachRendered=function(t){var n=this.group;n&&n.traverse(t)},t}();Ot(cx),zt(cx);var vx=Po(),dx={itemStyle:Rt(Pf,!0),lineStyle:Rt(zf,!0)},px={lineStyle:"stroke",itemStyle:"fill"};function mx(t,n){return t.visualStyleMapper||dx[n]||(console.warn("Unknown style type '"+n+"'."),dx.itemStyle)}function yx(t,n){return t.visualDrawType||px[n]||(console.warn("Unknown style type '"+n+"'."),"fill")}var gx={createOnAllSeries:!0,performRawSeries:!0,reset:function(t,n){var i=t.getData(),r=t.visualStyleAccessPath||"itemStyle",e=t.getModel(r),a=mx(t,r)(e),o=e.getShallow("decal");o&&(i.setVisual("decal",o),o.dirty=!0);var u=yx(t,r),s=a[u],l=Z(s)?s:null;if(!a[u]||l||"auto"===a.fill||"auto"===a.stroke){var f=t.getColorFromPalette(t.name,null,n.getSeriesCount());a[u]||(a[u]=f,i.setVisual("colorFromPalette",!0)),a.fill="auto"===a.fill||Z(a.fill)?f:a.fill,a.stroke="auto"===a.stroke||Z(a.stroke)?f:a.stroke}if(i.setVisual("style",a),i.setVisual("drawType",u),!n.isSeriesFiltered(t)&&l)return i.setVisual("colorFromPalette",!1),{dataEach:function(n,i){var r=t.getDataParams(i),e=P({},a);e[u]=l(r),n.setItemVisual(i,"style",e)}}}},bx=new Wf,xx={createOnAllSeries:!0,reset:function(t){if(!t.ignoreStyleOnData){var n=t.getData(),i=t.visualStyleAccessPath||"itemStyle",r=mx(t,i),e=n.getVisual("drawType");return{dataEach:n.hasItemOption?function(t,n){var a=t.getRawDataItem(n);if(a&&a[i]){bx.option=a[i];var o=r(bx);P(t.ensureUniqueItemVisual(n,"style"),o),bx.option.decal&&(t.setItemVisual(n,"decal",bx.option.decal),bx.option.decal.dirty=!0),e in o&&t.setItemVisual(n,"colorFromPalette",!1)}}:null}}}},Mx={performRawSeries:!0,overallReset:function(t){var n=bt();t.eachSeries((function(t){if(!t.isColorBySeries()){var i=t.type+"-"+t.getColorBy();vx(t).scope=n.get(i)||n.set(i,{})}})),t.eachSeries((function(t){if(!t.isColorBySeries()){var n=t.getRawData(),i={},r=t.getData(),e=vx(t).scope,a=yx(t,t.visualStyleAccessPath||"itemStyle");r.each((function(t){var n=r.getRawIndex(t);i[n]=t})),n.each((function(o){var u=i[o];if(r.getItemVisual(u,"colorFromPalette")){var s=r.ensureUniqueItemVisual(u,"style"),l=n.getName(o)||o+"",f=n.count();s[a]=t.getColorFromPalette(l,e,f)}}))}}))}},kx=Math.PI,Sx=function(){function t(t,n,i,r){this._stageTaskMap=bt(),this.ecInstance=t,this.api=n,i=this._dataProcessorHandlers=i.slice(),r=this._visualHandlers=r.slice(),this._allHandlers=i.concat(r)}return t.prototype.restoreData=function(t,n){t.restoreData(n),this._stageTaskMap.each((function(t){var n=t.overallTask;n&&n.dirty()}))},t.prototype.getPerformArgs=function(t,n){if(t.__pipeline){var i=this._pipelineMap.get(t.__pipeline.id),r=i.context,e=!n&&i.progressiveEnabled&&(!r||r.progressiveRender)&&t.__idxInPipeline>i.blockIndex?i.step:null,a=r&&r.modDataCount;return{step:e,modBy:null!=a?Math.ceil(a/e):null,modDataCount:a}}},t.prototype.getPipeline=function(t){return this._pipelineMap.get(t)},t.prototype.updateStreamModes=function(t,n){var i=this._pipelineMap.get(t.uid),r=t.__preparePipelineContext?t.__preparePipelineContext(n,i):iu(t,n,i);t.pipelineContext=i.context=r},t.prototype.restorePipelines=function(t,n){var i=this,r=i._pipelineMap=bt();n.eachSeries((function(n){var e="canvas"===t.painter.type&&n.getProgressive(),a=n.uid;r.set(a,{id:a,head:null,tail:null,threshold:n.getProgressiveThreshold(),progressiveEnabled:e&&!(n.preventIncremental&&n.preventIncremental()),blockIndex:-1,step:Math.round(e||700),count:0}),i._pipe(n,n.dataTask)}))},t.prototype.prepareStageTasks=function(){var t=this._stageTaskMap,n=this.api.getModel(),i=this.api;H(this._allHandlers,(function(r){var e=t.get(r.uid)||t.set(r.uid,{});ht(!(r.reset&&r.overallReset),""),r.reset&&this._createSeriesStageTask(r,e,n,i),r.overallReset&&this._createOverallStageTask(r,e,n,i)}),this)},t.prototype.prepareView=function(t,n,i,r){var e=t.renderTask,a=e.context;a.model=n,a.ecModel=i,a.api=r,e.__block=!t.incrementalPrepareRender,this._pipe(n,e)},t.prototype.performDataProcessorTasks=function(t,n){this._performStageTasks(this._dataProcessorHandlers,t,n,{block:!0})},t.prototype.performVisualTasks=function(t,n,i){this._performStageTasks(this._visualHandlers,t,n,i)},t.prototype._performStageTasks=function(t,n,i,r){r=r||{};var e=!1,a=this;function o(t,n){return t.setDirty&&(!t.dirtyMap||t.dirtyMap.get(n.__pipeline.id))}H(t,(function(t){if(!r.visualType||r.visualType===t.visualType){var u=a._stageTaskMap.get(t.uid),s=u.seriesTaskMap,l=u.overallTask;if(l){var f,h=l.agentStubMap;h.each((function(t){o(r,t)&&(t.dirty(),f=!0)})),f&&l.dirty(),a.updatePayload(l,i);var c=a.getPerformArgs(l,r.block);h.each((function(t){t.perform(c)})),l.perform(c)&&(e=!0)}else s&&s.each((function(u){o(r,u)&&u.dirty();var s=a.getPerformArgs(u,r.block);s.skip=!t.performRawSeries&&n.isSeriesFiltered(u.context.model),a.updatePayload(u,i),u.perform(s)&&(e=!0)}))}})),this.unfinished=e||this.unfinished},t.prototype.performSeriesTasks=function(t){var n;t.eachSeries((function(t){n=t.dataTask.perform()||n})),this.unfinished=n||this.unfinished},t.prototype.plan=function(){this._pipelineMap.each((function(t){var n=t.tail;do{if(n.__block){t.blockIndex=n.__idxInPipeline;break}n=n.getUpstream()}while(n)}))},t.prototype.updatePayload=function(t,n){"remain"!==n&&(t.context.payload=n)},t.prototype._createSeriesStageTask=function(t,n,i,r){var e=this,a=n.seriesTaskMap,o=n.seriesTaskMap=bt(),u=t.seriesType,s=t.getTargetSeries;function l(n){var u=n.uid,s=o.set(u,a&&a.get(u)||Pv({plan:Ox,reset:Ix,count:_x}));s.context={model:n,ecModel:i,api:r,useClearVisual:t.isVisual&&!t.isLayout,plan:t.plan,reset:t.reset,scheduler:e},e._pipe(n,s)}t.createOnAllSeries?i.eachRawSeries(l):u?i.eachRawSeriesByType(u,l):s&&s(i,r).each(l)},t.prototype._createOverallStageTask=function(t,n,i,r){var e=this,a=n.overallTask=n.overallTask||Pv({reset:Ax});a.context={ecModel:i,api:r,overallReset:t.overallReset,scheduler:e};var o=a.agentStubMap,u=a.agentStubMap=bt(),s=t.seriesType,l=t.getTargetSeries,f=t.dirtyOnOverallProgress,h=!1;function c(t){var n=t.uid,i=u.set(n,o&&o.get(n)||(h=!0,Pv({reset:Tx,onDirty:Cx})));i.context={model:t,dirtyOnOverallProgress:f},i.agent=a,i.__block=f,e._pipe(t,i)}ht(!t.createOnAllSeries,""),s?i.eachRawSeriesByType(s,c):l?l(i,r).each(c):H(i.getSeries(),c),h&&a.dirty()},t.prototype._pipe=function(t,n){var i=this._pipelineMap.get(t.uid);!i.head&&(i.head=n),i.tail&&i.tail.pipe(n),i.tail=n,n.__idxInPipeline=i.count++,n.__pipeline=i},t.wrapStageHandler=function(t,n){return Z(t)&&(t={overallReset:t,seriesType:zx(t)}),t.uid=yc("stageHandler"),n&&(t.visualType=n),t},t}();function Ax(t){t.overallReset(t.ecModel,t.api,t.payload)}function Tx(t){return t.dirtyOnOverallProgress&&Nx}function Nx(){this.agent.dirty(),this.getDownstream().dirty()}function Cx(){this.agent&&this.agent.dirty()}function Ox(t){return t.plan?t.plan(t.model,t.ecModel,t.api,t.payload):null}function Ix(t){t.useClearVisual&&t.data.clearAllVisual();var n=t.resetDefines=To(t.reset(t.model,t.ecModel,t.api,t.payload));return n.length>1?U(n,(function(t,n){return Dx(n)})):Lx}var Lx=Dx(0);function Dx(t){return function(n,i){var r=i.data,e=i.resetDefines[t];if(e&&e.dataEach)for(var a=n.start;a<n.end;a++)e.dataEach(r,a);else e&&e.progress&&e.progress(n,r)}}function _x(t){return t.data.count()}function zx(t){Rx=null;try{t(Fx,Px)}catch(t){}return Rx}var Rx,Fx={},Px={};function Bx(t,n){for(var i in n.prototype)t[i]=Mt}Bx(Fx,Ew),Bx(Px,bu),Fx.eachSeriesByType=Fx.eachRawSeriesByType=function(t){Rx=t},Fx.eachComponent=function(t){"series"===t.mainType&&t.subType&&(Rx=t.subType)};var Ex,Wx=Jv.darkColor,jx=Wx.background,Hx=function(){return{axisLine:{lineStyle:{color:Wx.axisLine}},splitLine:{lineStyle:{color:Wx.axisSplitLine}},splitArea:{areaStyle:{color:[Wx.backgroundTint,Wx.backgroundTransparent]}},minorSplitLine:{lineStyle:{color:Wx.axisMinorSplitLine}},axisLabel:{color:Wx.axisLabel},axisName:{}}},Ux={label:{color:Wx.secondary},itemStyle:{borderColor:Wx.borderTint},dividerLineStyle:{color:Wx.border}},Vx={darkMode:!0,color:Wx.theme,backgroundColor:jx,axisPointer:{lineStyle:{color:Wx.border},crossStyle:{color:Wx.borderShade},label:{color:Wx.tertiary}},legend:{textStyle:{color:Wx.secondary},pageTextStyle:{color:Wx.tertiary}},textStyle:{color:Wx.secondary},title:{textStyle:{color:Wx.primary},subtextStyle:{color:Wx.quaternary}},toolbox:{iconStyle:{borderColor:Wx.accent50},feature:{dataView:{backgroundColor:jx,textColor:Wx.primary,textareaColor:Wx.background,textareaBorderColor:Wx.border,buttonColor:Wx.accent50,buttonTextColor:Wx.neutral00}}},tooltip:{backgroundColor:Wx.neutral20,defaultBorderColor:Wx.border,textStyle:{color:Wx.tertiary}},dataZoom:{borderColor:Wx.accent10,textStyle:{color:Wx.tertiary},brushStyle:{color:Wx.backgroundTint},handleStyle:{color:Wx.neutral00,borderColor:Wx.accent20},moveHandleStyle:{color:Wx.accent40},emphasis:{handleStyle:{borderColor:Wx.accent50}},dataBackground:{lineStyle:{color:Wx.accent30},areaStyle:{color:Wx.accent20}},selectedDataBackground:{lineStyle:{color:Wx.accent50},areaStyle:{color:Wx.accent30}}},visualMap:{textStyle:{color:Wx.secondary},handleStyle:{borderColor:Wx.neutral30}},timeline:{lineStyle:{color:Wx.accent10},label:{color:Wx.tertiary},controlStyle:{color:Wx.accent30,borderColor:Wx.accent30}},calendar:{itemStyle:{color:Wx.neutral00,borderColor:Wx.neutral20},dayLabel:{color:Wx.tertiary},monthLabel:{color:Wx.secondary},yearLabel:{color:Wx.secondary}},matrix:{x:Ux,y:Ux,backgroundColor:{borderColor:Wx.axisLine},body:{itemStyle:{borderColor:Wx.borderTint}}},timeAxis:Hx(),logAxis:Hx(),valueAxis:Hx(),categoryAxis:Hx(),line:{symbol:"circle"},graph:{color:Wx.theme},gauge:{title:{color:Wx.secondary},axisLine:{lineStyle:{color:[[1,Wx.neutral05]]}},axisLabel:{color:Wx.axisLabel},detail:{color:Wx.primary}},candlestick:{itemStyle:{color:"#f64e56",color0:"#54ea92",borderColor:"#f64e56",borderColor0:"#54ea92"}},funnel:{itemStyle:{borderColor:Wx.background}},radar:(Ex=Hx(),Ex.axisName={color:Wx.axisLabel},Ex.axisLine.lineStyle.color=Wx.neutral20,Ex),treemap:{breadcrumb:{itemStyle:{color:Wx.neutral20,textStyle:{color:Wx.secondary}},emphasis:{itemStyle:{color:Wx.neutral30}}}},sunburst:{itemStyle:{borderColor:Wx.background}},map:{itemStyle:{borderColor:Wx.border,areaColor:Wx.neutral10},label:{color:Wx.tertiary},emphasis:{label:{color:Wx.primary},itemStyle:{areaColor:Wx.highlight}},select:{label:{color:Wx.primary},itemStyle:{areaColor:Wx.highlight}}},geo:{itemStyle:{borderColor:Wx.border,areaColor:Wx.neutral10},emphasis:{label:{color:Wx.primary},itemStyle:{areaColor:Wx.highlight}},select:{label:{color:Wx.primary},itemStyle:{color:Wx.highlight}}}};Vx.categoryAxis.splitLine.show=!1;var $x=function(){function t(){}return t.prototype.normalizeQuery=function(t){var n={},i={},r={};if(J(t)){var e=Ct(t);n.mainType=e.main||null,n.subType=e.sub||null}else{var a=["Index","Name","Id"],o={name:1,dataIndex:1,dataType:1};H(t,(function(t,e){for(var u=!1,s=0;s<a.length;s++){var l=a[s],f=e.lastIndexOf(l);if(f>0&&f===e.length-l.length){var h=e.slice(0,f);"data"!==h&&(n.mainType=h,n[l.toLowerCase()]=t,u=!0)}}o.hasOwnProperty(e)&&(i[e]=t,u=!0),u||(r[e]=t)}))}return{cptQuery:n,dataQuery:i,otherQuery:r}},t.prototype.filter=function(t,n){var i=this.eventInfo;if(!i)return!0;var r=i.targetEl,e=i.packedEvent,a=i.model,o=i.view;if(!a||!o)return!0;var u=n.cptQuery,s=n.dataQuery;return l(u,a,"mainType")&&l(u,a,"subType")&&l(u,a,"index","componentIndex")&&l(u,a,"name")&&l(u,a,"id")&&l(s,e,"name")&&l(s,e,"dataIndex")&&l(s,e,"dataType")&&(!o.filterForExposedEvent||o.filterForExposedEvent(t,n.otherQuery,r,e));function l(t,n,i,r){return null==t[i]||n[r||i]===t[i]}},t.prototype.afterTrigger=function(){this.eventInfo=null},t}(),Yx=["symbol","symbolSize","symbolRotate","symbolOffset"],Xx=Yx.concat(["symbolKeepAspect"]),qx={createOnAllSeries:!0,performRawSeries:!0,reset:function(t,n){var i=t.getData();if(t.legendIcon&&i.setVisual("legendIcon",t.legendIcon),t.hasSymbolVisual){for(var r={},e={},a=!1,o=0;o<Yx.length;o++){var u=Yx[o],s=t.get(u);Z(s)?(a=!0,e[u]=s):r[u]=s}if(r.symbol=r.symbol||t.defaultSymbol,i.setVisual(P({legendIcon:t.legendIcon||r.symbol,symbolKeepAspect:t.get("symbolKeepAspect")},r)),!n.isSeriesFiltered(t)){var l=Y(e);return{dataEach:a?function(n,i){for(var r=t.getRawValue(i),a=t.getDataParams(i),o=0;o<l.length;o++){var u=l[o];n.setItemVisual(i,u,e[u](r,a))}}:null}}}}},Gx={createOnAllSeries:!0,performRawSeries:!0,reset:function(t,n){if(t.hasSymbolVisual&&!n.isSeriesFiltered(t))return{dataEach:t.getData().hasItemOption?function(t,n){for(var i=t.getItemModel(n),r=0;r<Xx.length;r++){var e=Xx[r],a=i.getShallow(e,!0);null!=a&&t.setItemVisual(n,e,a)}}:null}}};function Zx(t,n,i){for(var r;t&&(!n(t)||(r=t,!i));)t=t.__hostTarget||t.parent;return r}var Jx=new Ur,Kx={},Qx=Math.round(9*Math.random()),tM="function"==typeof Object.defineProperty,nM=function(){function t(){this._id="__ec_inner_"+Qx++}return t.prototype.get=function(t){return this._guard(t)[this._id]},t.prototype.set=function(t,n){var i=this._guard(t);return tM?Object.defineProperty(i,this._id,{value:n,enumerable:!1,configurable:!0}):i[this._id]=n,this},t.prototype.delete=function(t){return!!this.has(t)&&(delete this._guard(t)[this._id],!0)},t.prototype.has=function(t){return!!this._guard(t)[this._id]},t.prototype._guard=function(t){if(t!==Object(t))throw TypeError("Value of WeakMap is not a non-null object.");return t},t}();function iM(t){return isFinite(t)}function rM(t,n,i){for(var r="radial"===n.type?function(t,n,i){var r=i.width,e=i.height,a=Math.min(r,e),o=null==n.x?.5:n.x,u=null==n.y?.5:n.y,s=null==n.r?.5:n.r;return n.global||(o=o*r+i.x,u=u*e+i.y,s*=a),o=iM(o)?o:.5,u=iM(u)?u:.5,s=s>=0&&iM(s)?s:.5,t.createRadialGradient(o,u,0,o,u,s)}(t,n,i):function(t,n,i){var r=null==n.x?0:n.x,e=null==n.x2?1:n.x2,a=null==n.y?0:n.y,o=null==n.y2?0:n.y2;return n.global||(r=r*i.width+i.x,e=e*i.width+i.x,a=a*i.height+i.y,o=o*i.height+i.y),r=iM(r)?r:0,e=iM(e)?e:1,a=iM(a)?a:0,o=iM(o)?o:0,t.createLinearGradient(r,a,e,o)}(t,n,i),e=n.colorStops,a=0;a<e.length;a++)r.addColorStop(e[a].offset,e[a].color);return r}function eM(t){return parseInt(t,10)}function aM(t,n,i){var r=["width","height"][n],e=["clientWidth","clientHeight"][n],a=["paddingLeft","paddingTop"][n],o=["paddingRight","paddingBottom"][n];if(null!=i[r]&&"auto"!==i[r])return parseFloat(i[r]);var u=document.defaultView.getComputedStyle(t);return(t[e]||eM(u[r])||eM(t.style[r]))-(eM(u[a])||0)-(eM(u[o])||0)||0}function oM(t){var n,i,r=t.style,e=r.lineDash&&r.lineWidth>0&&(i=r.lineWidth,(n=r.lineDash)&&"solid"!==n&&i>0?"dashed"===n?[4*i,2*i]:"dotted"===n?[i]:Q(n)?[n]:G(n)?n:null:null),a=r.lineDashOffset;if(e){var o=r.strokeNoScale&&t.getLineScale?t.getLineScale():1;o&&1!==o&&(e=U(e,(function(t){return t/o})),a/=o)}return[e,a]}var uM=new qe(!0);function sM(t){var n=t.stroke;return!(null==n||"none"===n||!(t.lineWidth>0))}function lM(t){return"string"==typeof t&&"none"!==t}function fM(t){var n=t.fill;return null!=n&&"none"!==n}function hM(t,n){if(null!=n.fillOpacity&&1!==n.fillOpacity){var i=t.globalAlpha;t.globalAlpha=n.fillOpacity*n.opacity,t.fill(),t.globalAlpha=i}else t.fill()}function cM(t,n){if(null!=n.strokeOpacity&&1!==n.strokeOpacity){var i=t.globalAlpha;t.globalAlpha=n.strokeOpacity*n.opacity,t.stroke(),t.globalAlpha=i}else t.stroke()}function vM(t,n,i){var r=$t(n.image,n.__image,i);if(Xt(r)){var e=t.createPattern(r,n.repeat||"repeat");if("function"==typeof DOMMatrix&&e&&e.setTransform){var a=new DOMMatrix;a.translateSelf(n.x||0,n.y||0),a.rotateSelf(0,0,(n.rotation||0)*kt),a.scaleSelf(n.scaleX||1,n.scaleY||1),e.setTransform(a)}return e}}var dM=["shadowBlur","shadowOffsetX","shadowOffsetY"],pM=[["lineCap","butt"],["lineJoin","miter"],["miterLimit",10]];function mM(t,n,i,r,e){var a=!1;if(!r&&n===(i=i||{}))return!1;if(r||n.opacity!==i.opacity){bM(t,e),a=!0;var o=Math.max(Math.min(n.opacity,1),0);t.globalAlpha=isNaN(o)?le.opacity:o}(r||n.blend!==i.blend)&&(a||(bM(t,e),a=!0),t.globalCompositeOperation=n.blend||le.blend);for(var u=0;u<dM.length;u++){var s=dM[u];(r||n[s]!==i[s])&&(a||(bM(t,e),a=!0),t[s]=t.dpr*(n[s]||0))}return(r||n.shadowColor!==i.shadowColor)&&(a||(bM(t,e),a=!0),t.shadowColor=n.shadowColor||le.shadowColor),a}function yM(t,n,i,r,e){var a=n.style,o=r?null:i&&i.style||{};if(a===o)return!1;var u=mM(t,a,o,r,e);if((r||a.fill!==o.fill)&&(u||(bM(t,e),u=!0),lM(a.fill)&&(t.fillStyle=a.fill)),(r||a.stroke!==o.stroke)&&(u||(bM(t,e),u=!0),lM(a.stroke)&&(t.strokeStyle=a.stroke)),(r||a.opacity!==o.opacity)&&(u||(bM(t,e),u=!0),t.globalAlpha=null==a.opacity?1:a.opacity),n.hasStroke()){var s=a.lineWidth/(a.strokeNoScale&&n.getLineScale?n.getLineScale():1);t.lineWidth!==s&&(u||(bM(t,e),u=!0),t.lineWidth=s)}for(var l=0;l<pM.length;l++){var f=pM[l],h=f[0];(r||a[h]!==o[h])&&(u||(bM(t,e),u=!0),t[h]=a[h]||f[1])}return u}function gM(t,n){var i=n.transform,r=t.dpr||1;i?t.setTransform(r*i[0],r*i[1],r*i[2],r*i[3],r*i[4],r*i[5]):t.setTransform(r,0,0,r,0,0)}function bM(t,n){n.batchFill&&(n.batchFill=!1,t.fill()),n.batchStroke&&(n.batchStroke=!1,t.stroke())}function wM(t,n,i){var r=n.transform;if(!n.shouldBePainted(i.viewWidth,i.viewHeight,!1,!1))return n.__dirty&=-2,void(n.__isRendered=!1);var e=n.__clipPaths,a=i.prevElClipPaths,o=n.style,u=!1,s=!1;if(a&&!function(t,n){if(t===n||!t&&!n)return!1;if(!t||!n||t.length!==n.length)return!0;for(var i=0;i<t.length;i++)if(t[i]!==n[i])return!0;return!1}(e,a)||(a&&(bM(t,i),t.restore(),s=u=!0,i.prevElClipPaths=null,i.allClipped=!1,i.prevEl=null),e&&e.length&&(bM(t,i),t.save(),function(t,n,i){for(var r=!1,e=0;e<t.length;e++){var a=t[e];r=r||a.isZeroArea(),gM(n,a),n.beginPath(),a.buildPath(n,a.shape),n.clip()}i.allClipped=r}(e,t,i),u=!0,i.prevElClipPaths=e)),i.allClipped)return n.__dirty&=-2,void(n.__isRendered=!1);n.beforeBrush&&n.beforeBrush(i.beforeBrushParam),n.innerBeforeBrush();var l=i.prevEl;l||(s=u=!0);var f,h,c=n instanceof da&&n.autoBatch&&function(t){var n=fM(t),i=sM(t);return!(t.lineDash||!(+n^+i)||n&&"string"!=typeof t.fill||i&&"string"!=typeof t.stroke||t.strokePercent<1||t.strokeOpacity<1||t.fillOpacity<1)}(o);u||(h=l.transform,(f=r)&&h?f[0]!==h[0]||f[1]!==h[1]||f[2]!==h[2]||f[3]!==h[3]||f[4]!==h[4]||f[5]!==h[5]:f||h)?(bM(t,i),gM(t,n)):c||bM(t,i),n instanceof da?(1!==i.lastDrawType&&(s=!0,i.lastDrawType=1),yM(t,n,l,s,i),c&&(i.batchFill||i.batchStroke)||t.beginPath(),function(t,n,i,r,e){var a,o=sM(i),u=fM(i),s=i.strokePercent,l=s<1,f=!n.path;n.silent&&!l||!f||n.createPathProxy();var h=n.path||uM,c=n.__dirty;if(!r){var v=i.fill,d=i.stroke,p=u&&!!v.colorStops,m=o&&!!d.colorStops,y=u&&!!v.image,g=o&&!!d.image,b=void 0,w=void 0,x=void 0,M=void 0,k=void 0;(p||m)&&(k=n.getBoundingRect()),p&&(b=c?rM(t,v,k):n.__canvasFillGradient,n.__canvasFillGradient=b),m&&(w=c?rM(t,d,k):n.__canvasStrokeGradient,n.__canvasStrokeGradient=w),y&&(x=c||!n.__canvasFillPattern?vM(t,v,n):n.__canvasFillPattern,n.__canvasFillPattern=x),g&&(M=c||!n.__canvasStrokePattern?vM(t,d,n):n.__canvasStrokePattern,n.__canvasStrokePattern=M),p?t.fillStyle=b:y&&(x?t.fillStyle=x:u=!1),m?t.strokeStyle=w:g&&(M?t.strokeStyle=M:o=!1)}var S,A,T=n.getGlobalScale();h.setScale(T[0],T[1],n.segmentIgnoreThreshold),t.setLineDash&&i.lineDash&&(S=(a=oM(n))[0],A=a[1]);var N=!0;(f||4&c)&&(h.setDPR(t.dpr),l?h.setContext(null):(h.setContext(t),N=!1),h.reset(),n.buildPath(h,n.shape,r),h.toStatic(),n.pathUpdated()),N&&h.rebuildPath(t,l?s:1),S&&(t.setLineDash(S),t.lineDashOffset=A),r?(e.batchFill=u,e.batchStroke=o):i.strokeFirst?(o&&cM(t,i),u&&hM(t,i)):(u&&hM(t,i),o&&cM(t,i)),S&&t.setLineDash([])}(t,n,o,c,i)):n instanceof ma?(3!==i.lastDrawType&&(s=!0,i.lastDrawType=3),yM(t,n,l,s,i),function(t,n,i){var r,e=i.text;if(null!=e&&(e+=""),e){t.font=i.font||y,t.textAlign=i.textAlign,t.textBaseline=i.textBaseline;var a=void 0,o=void 0;t.setLineDash&&i.lineDash&&(a=(r=oM(n))[0],o=r[1]),a&&(t.setLineDash(a),t.lineDashOffset=o),i.strokeFirst?(sM(i)&&t.strokeText(e,i.x,i.y),fM(i)&&t.fillText(e,i.x,i.y)):(fM(i)&&t.fillText(e,i.x,i.y),sM(i)&&t.strokeText(e,i.x,i.y)),a&&t.setLineDash([])}}(t,n,o)):n instanceof ba?(2!==i.lastDrawType&&(s=!0,i.lastDrawType=2),function(t,n,i,r,e){mM(t,n.style,i&&i.style,r,e)}(t,n,l,s,i),function(t,n,i){var r=n.__image=$t(i.image,n.__image,n,n.onload);if(r&&Xt(r)){var e=i.x||0,a=i.y||0,o=n.getWidth(),u=n.getHeight(),s=r.width/r.height;if(null==o&&null!=u?o=u*s:null==u&&null!=o?u=o/s:null==o&&null==u&&(o=r.width,u=r.height),i.sWidth&&i.sHeight)t.drawImage(r,l=i.sx||0,f=i.sy||0,i.sWidth,i.sHeight,e,a,o,u);else if(i.sx&&i.sy){var l,f;t.drawImage(r,l=i.sx,f=i.sy,o-l,u-f,e,a,o,u)}else t.drawImage(r,e,a,o,u)}}(t,n,o)):n.getTemporalDisplayables&&(4!==i.lastDrawType&&(s=!0,i.lastDrawType=4),function(t,n,i){var r=n.getDisplayables(),e=n.getTemporalDisplayables();t.save();var a,o,u={prevElClipPaths:null,prevEl:null,allClipped:!1,viewWidth:i.viewWidth,viewHeight:i.viewHeight,beforeBrushParam:{}};for(a=n.getCursor(),o=r.length;a<o;a++)(f=r[a]).beforeBrush&&f.beforeBrush(i.beforeBrushParam),f.innerBeforeBrush(),wM(t,f,u),f.innerAfterBrush(),f.afterBrush&&f.afterBrush(),u.prevEl=f;xM(t,u);for(var s=0,l=e.length;s<l;s++){var f;(f=e[s]).beforeBrush&&f.beforeBrush(i.beforeBrushParam),f.innerBeforeBrush(),wM(t,f,u),f.innerAfterBrush(),f.afterBrush&&f.afterBrush(),u.prevEl=f}xM(t,u),n.clearTemporalDisplayables(),n.notClear=!0,t.restore()}(t,n,i)),n.innerAfterBrush(),n.afterBrush&&(c&&bM(t,i),n.afterBrush()),i.prevEl=n,n.__dirty=0,n.__isRendered=!0}function xM(t,n){bM(t,n),n.prevElClipPaths&&t.restore()}var MM=new nM,kM=new Ht(100),SM=["symbol","symbolSize","symbolKeepAspect","color","backgroundColor","dashArrayX","dashArrayY","maxTileWidth","maxTileHeight"];function AM(t,n){if("none"===t)return null;var i=n.getDevicePixelRatio(),r=n.getZr(),e="svg"===r.painter.type;t.dirty&&MM.delete(t);var a=MM.get(t);if(a)return a;var o=B(t,{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});"none"===o.backgroundColor&&(o.backgroundColor=null);var u={repeat:"repeat"};return function(t){for(var n,a=[i],u=!0,s=0;s<SM.length;++s){var l=o[SM[s]];if(null!=l&&!G(l)&&!J(l)&&!Q(l)&&"boolean"!=typeof l){u=!1;break}a.push(l)}if(u){n=a.join(",")+(e?"-svg":"");var f=kM.get(n);f&&(e?t.svgElement=f:t.image=f)}var h,c=NM(o.dashArrayX),v=function(t){if(!t||"object"==typeof t&&0===t.length)return[0,0];if(Q(t)){var n=Math.ceil(t);return[n,n]}var i=U(t,(function(t){return Math.ceil(t)}));return t.length%2?i.concat(i):i}(o.dashArrayY),d=TM(o.symbol),p=U(c,(function(t){return CM(t)})),m=CM(v),y=!e&&b.createCanvas(),g=e&&{tag:"g",attrs:{},key:"dcl",children:[]},w=function(){for(var t=1,n=0,i=p.length;n<i;++n)t=bo(t,p[n]);var r=1;for(n=0,i=d.length;n<i;++n)r=bo(r,d[n].length);t*=r;var e=m*p.length*d.length;return{width:Math.max(1,Math.min(t,o.maxTileWidth)),height:Math.max(1,Math.min(e,o.maxTileHeight))}}();y&&(y.width=w.width*i,y.height=w.height*i,h=y.getContext("2d")),function(){h&&(h.clearRect(0,0,y.width,y.height),o.backgroundColor&&(h.fillStyle=o.backgroundColor,h.fillRect(0,0,y.width,y.height)));for(var t=0,n=0;n<v.length;++n)t+=v[n];if(!(t<=0))for(var a=-m,u=0,s=0,l=0;a<w.height;){if(u%2==0){for(var f=s/2%d.length,p=0,b=0,x=0;p<2*w.width;){var M=0;for(n=0;n<c[l].length;++n)M+=c[l][n];if(M<=0)break;if(b%2==0){var k=.5*(1-o.symbolSize);S(p+c[l][b]*k,a+v[u]*k,c[l][b]*o.symbolSize,v[u]*o.symbolSize,d[f][x/2%d[f].length])}p+=c[l][b],++x,++b===c[l].length&&(b=0)}++l===c.length&&(l=0)}a+=v[u],++s,++u===v.length&&(u=0)}function S(t,n,a,u,s){var l=e?1:i,f=zd(s,t*l,n*l,a*l,u*l,o.color,o.symbolKeepAspect);if(e){var c=r.painter.renderOneToVNode(f);c&&g.children.push(c)}else!function(t,n){var i={viewWidth:0,viewHeight:0,beforeBrushParam:{}};wM(t,n,i),xM(t,i)}(h,f)}}(),u&&kM.put(n,y||g),t.image=y,t.svgElement=g,t.svgWidth=w.width,t.svgHeight=w.height}(u),u.rotation=o.rotation,u.scaleX=u.scaleY=e?1:1/i,MM.set(t,u),t.dirty=!1,u}function TM(t){if(!t||0===t.length)return[["rect"]];if(J(t))return[[t]];for(var n=!0,i=0;i<t.length;++i)if(!J(t[i])){n=!1;break}if(n)return TM([t]);var r=[];for(i=0;i<t.length;++i)J(t[i])?r.push([t[i]]):r.push(t[i]);return r}function NM(t){if(!t||0===t.length)return[[0,0]];if(Q(t))return[[e=Math.ceil(t),e]];for(var n=!0,i=0;i<t.length;++i)if(!Q(t[i])){n=!1;break}if(n)return NM([t]);var r=[];for(i=0;i<t.length;++i)if(Q(t[i])){var e=Math.ceil(t[i]);r.push([e,e])}else e=U(t[i],(function(t){return Math.ceil(t)})),r.push(e.length%2==1?e.concat(e):e);return r}function CM(t){for(var n=0,i=0;i<t.length;++i)n+=t[i];return t.length%2==1?2*n:n}var OM=eu((function(t,n){t.eachRawSeries((function(i){if(!t.isSeriesFiltered(i)){var r=i.getData();r.hasItemVisual()&&r.each((function(t){var i=r.getItemVisual(t,"decal");i&&(r.ensureUniqueItemVisual(t,"style").decal=AM(i,n))}));var e=r.getVisual("decal");e&&(r.getVisual("style").decal=AM(e,n))}}))})),IM=2e3,LM=4500,DM={PROCESSOR:{SERIES_FILTER:800,AXIS_STATISTICS:920,FILTER:1e3,STATISTIC:5e3,STATISTICS:5e3},VISUAL:{LAYOUT:1e3,PROGRESSIVE_LAYOUT:1100,GLOBAL:IM,CHART:3e3,POST_CHART_LAYOUT:4600,COMPONENT:4e3,BRUSH:5e3,CHART_ITEM:LM,ARIA:6e3,DECAL:7e3}},_M="__flagInMainProcess",zM="__mainProcessVersion",RM="__pendingUpdate",FM="__needsUpdateStatus",PM=/^[a-zA-Z0-9_]+$/,BM="__connectUpdateStatus";function EM(t){return function(){for(var n=[],i=0;i<arguments.length;i++)n[i]=arguments[i];if(!this.isDisposed())return jM(this,t,n)}}function WM(t){return function(){for(var n=[],i=0;i<arguments.length;i++)n[i]=arguments[i];return jM(this,t,n)}}function jM(t,n,i){return i[0]=i[0]&&i[0].toLowerCase(),Ur.prototype[n].apply(t,i)}var HM,UM,VM,$M,YM,XM,qM,GM,ZM,JM,KM,QM,tk,nk,ik,rk,ek,ak,ok,uk=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return v(n,t),n}(Ur),sk=uk.prototype;sk.on=WM("on"),sk.off=WM("off");var lk=function(t){function n(n,i,r){var e=t.call(this,new $x)||this;e._chartsViews=[],e._chartsMap={},e._componentsViews=[],e._componentsMap={},e._pendingActions=[],r=r||{},e.__v_skip=!0,e._dom=n,e[zM]=1,r.ssr&&(kw=function(t){var n=au(t),i=n.dataIndex;if(null!=i){var r=bt();return r.set("series_index",n.seriesIndex),r.set("data_index",i),n.ssrType&&r.set("ssr_type",n.ssrType),r}});var a=e._zr=Cw(n,{renderer:r.renderer||"canvas",devicePixelRatio:r.devicePixelRatio,width:r.width,height:r.height,ssr:r.ssr,useDirtyRect:ut(r.useDirtyRect,!1),useCoarsePointer:ut(r.useCoarsePointer,"auto"),pointerSize:r.pointerSize});e._ssr=r.ssr,e._throttledZrFlush=Mg(X(a.flush,a),17),e._updateTheme(i),e._locale=function(t){if(J(t)){var n=Lc[t.toUpperCase()]||{};return t===Cc||t===Oc?R(n):F(R(n),R(Lc[Ic]),!1)}return F(R(t),R(Lc[Ic]),!1)}(r.locale||_c),e._coordSysMgr=new sc;var o=e._api=ik(e);function u(t,n){return t.__prio-n.__prio}return tw(yk,u),tw(pk,u),e._scheduler=new Sx(e,o,pk,yk),e._messageCenter=new uk,e._initEvents(),e.resize=X(e.resize,e),a.animation.on("frame",e._onframe,e),JM(a,e),KM(a,e),dt(e),e}return v(n,t),n.prototype._onframe=function(){if(!this._disposed){var t=this._scheduler,n=this._model,i=this._api;if(ak(this),this[RM]){var r=this[RM].silent;this[_M]=!0,ok(this);try{HM(this),$M.update.call(this,null,this[RM].updateParams)}catch(t){throw this[_M]=!1,this[RM]=null,t}this._zr.flush(),this[_M]=!1,this[RM]=null,GM.call(this,r),ZM.call(this,r)}else if(t.unfinished){var e=1;do{t.unfinished=!1;var a=b.getTime();t.performSeriesTasks(n),t.performDataProcessorTasks(n),XM(this,n),t.performVisualTasks(n),nk(this,this._model,i,"remain",{}),e-=b.getTime()-a}while(e>0&&t.unfinished);t.unfinished||this._zr.flush()}}},n.prototype.getDom=function(){return this._dom},n.prototype.getId=function(){return this.id},n.prototype.getZr=function(){return this._zr},n.prototype.isSSR=function(){return this._ssr},n.prototype.setOption=function(t,n,i){if(!this[_M]&&!this._disposed){var r,e,a;if(tt(n)&&(i=n.lazyUpdate,r=n.silent,e=n.replaceMerge,a=n.transition,n=n.notMerge),this[_M]=!0,ok(this),!this._model||n){var o=new Vw(this._api),u=this._theme,s=this._model=new Ew;s.scheduler=this._scheduler,s.ssr=this._ssr,s.init(null,null,null,u,this._locale,o)}this._model.setOption(t,{replaceMerge:e},mk);var l={seriesTransition:a,optionChanged:!0};if(i)this[RM]={silent:r,updateParams:l},this[_M]=!1,this.getZr().wakeUp();else{try{HM(this),$M.update.call(this,null,l)}catch(t){throw this[RM]=null,this[_M]=!1,t}this._ssr||this._zr.flush(),this[RM]=null,this[_M]=!1,GM.call(this,r),ZM.call(this,r)}}},n.prototype.setTheme=function(t,n){if(!this[_M]&&!this._disposed){var i=this._model;if(i){var r=n&&n.silent,e=null;this[RM]&&(null==r&&(r=this[RM].silent),e=this[RM].updateParams,this[RM]=null),this[_M]=!0,ok(this);try{this._updateTheme(t),i.setTheme(this._theme),HM(this),$M.update.call(this,{type:"setTheme"},e)}catch(t){throw this[_M]=!1,t}this[_M]=!1,GM.call(this,r),ZM.call(this,r)}}},n.prototype._updateTheme=function(t){J(t)&&(t=gk[t]),t&&((t=R(t))&&fx(t,!0),this._theme=t)},n.prototype.getModel=function(){return this._model},n.prototype.getOption=function(){return this._model&&this._model.getOption()},n.prototype.getWidth=function(){return this._zr.getWidth()},n.prototype.getHeight=function(){return this._zr.getHeight()},n.prototype.getDevicePixelRatio=function(){return this._zr.painter.dpr||At.hasGlobalWindow&&window.devicePixelRatio||1},n.prototype.getRenderedCanvas=function(t){return this.renderToCanvas(t)},n.prototype.renderToCanvas=function(t){return this._zr.painter.getRenderedCanvas({backgroundColor:(t=t||{}).backgroundColor||this._model.get("backgroundColor"),pixelRatio:t.pixelRatio||this.getDevicePixelRatio()})},n.prototype.renderToSVGString=function(t){return this._zr.painter.renderToString({useViewBox:(t=t||{}).useViewBox})},n.prototype.getSvgDataURL=function(){var t=this._zr;return H(t.storage.getDisplayList(),(function(t){t.stopAnimation(null,!0)})),t.painter.toDataURL()},n.prototype.getDataURL=function(t){if(!this._disposed){var n=this._model,i=[],r=this;H((t=t||{}).excludeComponents,(function(t){n.eachComponent({mainType:t},(function(t){var n=r._componentsMap[t.__viewId];n.group.ignore||(i.push(n),n.group.ignore=!0)}))}));var e="svg"===this._zr.painter.getType()?this.getSvgDataURL():this.renderToCanvas(t).toDataURL("image/"+(t&&t.type||"png"));return H(i,(function(t){t.group.ignore=!1})),e}},n.prototype.getConnectedDataURL=function(t){if(!this._disposed){var n="svg"===t.type,i=this.group,r=Math.min,e=Math.max,a=1/0;if(xk[i]){var o=a,u=a,s=-1/0,l=-1/0,f=[],h=t&&t.pixelRatio||this.getDevicePixelRatio();H(wk,(function(a){if(a.group===i){var h=n?a.getZr().painter.getSvgDom().innerHTML:a.renderToCanvas(R(t)),c=a.getDom().getBoundingClientRect();o=r(c.left,o),u=r(c.top,u),s=e(c.right,s),l=e(c.bottom,l),f.push({dom:h,left:c.left,top:c.top})}}));var c=(s*=h)-(o*=h),v=(l*=h)-(u*=h),d=b.createCanvas(),p=Cw(d,{renderer:n?"svg":"canvas"});if(p.resize({width:c,height:v}),n){var m="";return H(f,(function(t){m+='<g transform="translate('+(t.left-o)+","+(t.top-u)+')">'+t.dom+"</g>"})),p.painter.getSvgRoot().innerHTML=m,t.connectedBackgroundColor&&p.painter.setBackgroundColor(t.connectedBackgroundColor),p.refreshImmediately(),p.painter.toDataURL()}return t.connectedBackgroundColor&&p.add(new Ta({shape:{x:0,y:0,width:c,height:v},style:{fill:t.connectedBackgroundColor}})),H(f,(function(t){var n=new ba({style:{x:t.left*h-o,y:t.top*h-u,image:t.dom}});p.add(n)})),p.refreshImmediately(),d.toDataURL("image/"+(t&&t.type||"png"))}return this.getDataURL(t)}},n.prototype.convertToPixel=function(t,n,i){return YM(this,"convertToPixel",t,n,i)},n.prototype.convertToLayout=function(t,n,i){return YM(this,"convertToLayout",t,n,i)},n.prototype.convertFromPixel=function(t,n,i){return YM(this,"convertFromPixel",t,n,i)},n.prototype.containPixel=function(t,n){var i;if(!this._disposed)return H(Eo(this._model,t),(function(t,r){r.indexOf("Models")>=0&&H(t,(function(t){var e=t.coordinateSystem;if(e&&e.containPoint)i=i||!!e.containPoint(n);else if("seriesModels"===r){var a=this._chartsMap[t.__viewId];a&&a.containPoint&&(i=i||a.containPoint(n,t))}}),this)}),this),!!i},n.prototype.getVisual=function(t,n){var i=Eo(this._model,t,{defaultMainType:"series"}),r=i.seriesModel.getData(),e=i.hasOwnProperty("dataIndexInside")?i.dataIndexInside:i.hasOwnProperty("dataIndex")?r.indexOfRawIndex(i.dataIndex):null;return null!=e?function(t,n,i){switch(i){case"color":return t.getItemVisual(n,"style")[t.getVisual("drawType")];case"opacity":return t.getItemVisual(n,"style").opacity;case"symbol":case"symbolSize":case"liftZ":return t.getItemVisual(n,i)}}(r,e,n):function(t,n){switch(n){case"color":return t.getVisual("style")[t.getVisual("drawType")];case"opacity":return t.getVisual("style").opacity;case"symbol":case"symbolSize":case"liftZ":return t.getVisual(n)}}(r,n)},n.prototype.getViewOfComponentModel=function(t){return this._componentsMap[t.__viewId]},n.prototype.getViewOfSeriesModel=function(t){return this._chartsMap[t.__viewId]},n.prototype._initEvents=function(){var t=this;H(hk,(function(n){var i=function(i){var r,e=t.getModel(),a=i.target;if("globalout"===n?r={}:a&&Zx(a,(function(t){var n=au(t);if(n&&null!=n.dataIndex){var i=n.dataModel||e.getSeriesByIndex(n.seriesIndex);return r=i&&i.getDataParams(n.dataIndex,n.dataType,a)||{},!0}if(n.eventData)return r=P({},n.eventData),!0}),!0),r){var o=r.componentType,u=r.componentIndex;"markLine"!==o&&"markPoint"!==o&&"markArea"!==o||(o="series",u=r.seriesIndex);var s=o&&null!=u&&e.getComponent(o,u),l=s&&t["series"===s.mainType?"_chartsMap":"_componentsMap"][s.__viewId];r.event=i,r.type=n,t._$eventProcessor.eventInfo={targetEl:a,packedEvent:r,model:s,view:l},t.trigger(n,r)}};i.zrEventfulCallAtLast=!0,t._zr.on(n,i,t)}));var n=this._messageCenter;H(dk,(function(i,r){n.on(r,(function(n){t.trigger(r,n)}))})),function(t,n,i){t.on("selectchanged",(function(t){var r=i.getModel();t.isFromClick?(qg("map","selectchanged",n,r,t),qg("pie","selectchanged",n,r,t)):"select"===t.fromAction?(qg("map","selected",n,r,t),qg("pie","selected",n,r,t)):"unselect"===t.fromAction&&(qg("map","unselected",n,r,t),qg("pie","unselected",n,r,t))}))}(n,this,this._api)},n.prototype.isDisposed=function(){return this._disposed},n.prototype.clear=function(){this._disposed||this.setOption({series:[]},!0)},n.prototype.dispose=function(){if(!this._disposed){this._disposed=!0,this.getDom()&&Uo(this.getDom(),kk,"");var t=this,n=t._api,i=t._model;H(t._componentsViews,(function(t){t.dispose(i,n)})),H(t._chartsViews,(function(t){t.dispose(i,n)})),t._zr.dispose(),t._dom=t._model=t._chartsMap=t._componentsMap=t._chartsViews=t._componentsViews=t._scheduler=t._api=t._zr=t._throttledZrFlush=t._theme=t._coordSysMgr=t._messageCenter=null,delete wk[t.id]}},n.prototype.resize=function(t){if(!this[_M]&&!this._disposed){this._zr.resize(t);var n=this._model;if(this._loadingFX&&this._loadingFX.resize(),n){var i=n.resetOption("media"),r=t&&t.silent;this[RM]&&(null==r&&(r=this[RM].silent),i=!0,this[RM]=null),this[_M]=!0,ok(this);try{i&&HM(this),$M.update.call(this,{type:"resize",animation:P({duration:0},t&&t.animation)})}catch(t){throw this[_M]=!1,t}this[_M]=!1,GM.call(this,r),ZM.call(this,r)}}},n.prototype.showLoading=function(t,n){if(!this._disposed&&(tt(t)&&(n=t,t=""),t=t||"default",this.hideLoading(),bk[t])){var i=bk[t](this._api,n),r=this._zr;this._loadingFX=i,r.add(i)}},n.prototype.hideLoading=function(){this._disposed||(this._loadingFX&&this._zr.remove(this._loadingFX),this._loadingFX=null)},n.prototype.makeActionFromEvent=function(t){var n=P({},t);return n.type=vk[t.type],n},n.prototype.dispatchAction=function(t,n){if(!this._disposed&&(tt(n)||(n={silent:!!n}),ck[t.type]&&this._model))if(this[_M])this._pendingActions.push(t);else{var i=n.silent;qM.call(this,t,i);var r=n.flush;r?this._zr.flush():!1!==r&&At.browser.weChat&&this._throttledZrFlush(),GM.call(this,i),ZM.call(this,i)}},n.prototype.updateLabelLayout=function(){Jx.trigger("series:layoutlabels",this._model,this._api,{updatedSeries:[]})},n.prototype.appendData=function(t){if(!this._disposed){var n=t.seriesIndex;this.getModel().getSeriesByIndex(n).appendData(t),this._scheduler.unfinished=!0,this.getZr().wakeUp()}},n.internalField=function(){function t(t){t.clearColorPalette(),t.eachSeries((function(t){t.clearColorPalette()}))}function n(t){for(var n=[],i=t.currentStates,r=0;r<i.length;r++){var e=i[r];"emphasis"!==e&&"blur"!==e&&"select"!==e&&n.push(e)}t.selected&&t.states.select&&n.push("select"),2===t.hoverState&&t.states.emphasis?n.push("emphasis"):1===t.hoverState&&t.states.blur&&n.push("blur"),t.useStates(n)}function i(t,n){if(!t.preventAutoZ){var i=lf(t);n.eachRendered((function(t){return ff(t,i.z,i.zlevel),!0}))}}function r(t,n){n.eachRendered((function(t){if(!Il(t)){var n=t.getTextContent(),i=t.getTextGuideLine();t.stateTransition&&(t.stateTransition=null),n&&n.stateTransition&&(n.stateTransition=null),i&&i.stateTransition&&(i.stateTransition=null),t.hasState()?(t.prevStates=t.currentStates,t.clearStates()):t.prevStates&&(t.prevStates=null)}}))}function e(t,i){var r=t.getModel("stateAnimation"),e=t.isAnimationEnabled(),a=r.get("duration"),o=a>0?{duration:a,delay:r.get("delay"),easing:r.get("easing")}:null;i.eachRendered((function(t){if(t.states&&t.states.emphasis){if(Il(t))return;if(t instanceof da&&function(t){var n=Mu(t);n.normalFill=t.style.fill,n.normalStroke=t.style.stroke;var i=t.states.select||{};n.selectFill=i.style&&i.style.fill||null,n.selectStroke=i.style&&i.style.stroke||null}(t),t.__dirty){var i=t.prevStates;i&&t.useStates(i)}if(e){t.stateTransition=o;var r=t.getTextContent(),a=t.getTextGuideLine();r&&(r.stateTransition=o),a&&(a.stateTransition=o)}t.__dirty&&n(t)}}))}HM=function(t){Hm(t._model).prepare={};var n=t._scheduler;n.restorePipelines(t._zr,t._model),n.prepareStageTasks(),UM(t,!0),UM(t,!1),n.plan()},UM=function(t,n){for(var i=t._model,r=t._scheduler,e=n?t._componentsViews:t._chartsViews,a=n?t._componentsMap:t._chartsMap,o=t._zr,u=t._api,s=0;s<e.length;s++)e[s].__alive=!1;function l(t){var s=t.__requireNewView;t.__requireNewView=!1;var l="_ec_"+t.id+"_"+t.type,f=!s&&a[l];if(!f){var h=Ct(t.type);(f=new(n?cx.getClass(h.main,h.sub):lp.getClass(h.sub))).init(i,u),a[l]=f,e.push(f),o.add(f.group)}t.__viewId=f.__id=l,f.__alive=!0,f.__model=t,f.group.__ecComponentInfo={mainType:t.mainType,index:t.componentIndex},!n&&r.prepareView(f,t,i,u)}for(n?i.eachComponent((function(t,n){"series"!==t&&l(n)})):i.eachSeries(l),s=0;s<e.length;){var f=e[s];f.__alive?s++:(!n&&f.renderTask.dispose(),o.remove(f.group),f.dispose(i,u),e.splice(s,1),a[f.__id]===f&&delete a[f.__id],f.__id=f.group.__ecComponentInfo=null)}},VM=function(t,n,i,r,e){var a=t._model;if(a.setUpdatePayload(i),r){var o,u=function(t,n,i){var r={};r[n+"Id"]=t[n+"Id"],r[n+"Index"]=t[n+"Index"],r[n+"Name"]=t[n+"Name"];var e={mainType:n,query:r};return i&&(e.subType=i),e}(i,r,e),s=i.excludeSeriesId;null!=s&&(o=bt(),H(To(s),(function(t){var n=_o(t,null);null!=n&&o.set(n,!0)}))),a&&a.eachComponent(u,(function(n){if(!o||null==o.get(n.id))if(cs(i))if(n instanceof gd)i.type!==Tu||i.notBlur||n.get(["emphasis","disabled"])||function(t,n,i){var r=t.seriesIndex,e=t.getData(n.dataType);if(e){var a=Fo(e,n);a=(G(a)?a[0]:a)||0;var o=e.getItemGraphicEl(a);if(!o)for(var u=e.count(),s=0;!o&&s<u;)o=e.getItemGraphicEl(s++);if(o){var l=au(o);ts(r,l.focus,l.blurScope,i)}else{var f=t.get(["emphasis","focus"]),h=t.get(["emphasis","blurScope"]);null!=f&&ts(r,f,h,i)}}}(n,i,t._api);else{var r=is(n.mainType,n.componentIndex,i.name,t._api),e=r.dispatchers;i.type===Tu&&r.focusSelf&&!i.notBlur&&ns(n.mainType,n.componentIndex,t._api),e&&H(e,(function(t){i.type===Tu?Xu(t):qu(t)}))}else hs(i)&&n instanceof gd&&(function(t,n){if(hs(n)){var i=n.dataType,r=Fo(t.getData(i),n);G(r)||(r=[r]),t[n.type===Iu?"toggleSelect":n.type===Cu?"select":"unselect"](r,i)}}(n,i),rs(n),ek(t))}),t),a&&a.eachComponent(u,(function(n){o&&null!=o.get(n.id)||l(t["series"===r?"_chartsMap":"_componentsMap"][n.__viewId])}),t)}else H([].concat(t._componentsViews).concat(t._chartsViews),l);function l(r){r&&r.__alive&&r[n]&&r[n](r.__model,a,t._api,i)}},$M={prepareAndUpdate:function(t){HM(this),$M.update.call(this,t,t&&{optionChanged:null!=t.newOption})},update:function(n,i){var r=this._model,e=this._api,a=this._zr,o=this._coordSysMgr,u=this._scheduler;if(r){!function(t){Hm(t).fullUpdate={}}(r),r.setUpdatePayload(n),u.restoreData(r,n),u.performSeriesTasks(r),o.create(r,e),Jx.trigger("coordsys:aftercreate",r,e),u.performDataProcessorTasks(r,n),XM(this,r),o.update(r,e),t(r),u.performVisualTasks(r,n);var s=r.get("backgroundColor")||"transparent";a.setBackgroundColor(s);var l=r.get("darkMode");null!=l&&"auto"!==l&&a.setDarkMode(l),QM(this,r,e,n,i),Jx.trigger("afterupdate",r,e)}},updateTransform:function(t){var n=this,i=n._model,r=n._api;if(i){i.setUpdatePayload(t),i.eachComponent((function(e,a){if(e!==su){var o=n.getViewOfComponentModel(a);o&&o.__alive&&o.updateTransform&&o.updateTransform(a,i,r,t)}}));var e=bt();i.eachSeries((function(a){var o=n._chartsMap[a.__viewId];if(o.updateTransform&&!a.pipelineContext.progressiveRender){var u=o.updateTransform(a,i,r,t);u&&u.update&&e.set(a.uid,1)}else e.set(a.uid,1)})),n._scheduler.performVisualTasks(i,t,{setDirty:!0,dirtyMap:e}),nk(n,i,r,t,{},e),Jx.trigger("afterupdate",i,r)}},updateView:function(n){var i=this._model;i&&(i.setUpdatePayload(n),lp.markUpdateMethod(n,"updateView"),t(i),this._scheduler.performVisualTasks(i,n,{setDirty:!0}),QM(this,i,this._api,n,{}),Jx.trigger("afterupdate",i,this._api))},updateVisual:function(n){var i=this,r=this._model;r&&(r.setUpdatePayload(n),r.eachSeries((function(t){t.getData().clearAllVisual()})),lp.markUpdateMethod(n,"updateVisual"),t(r),this._scheduler.performVisualTasks(r,n,{visualType:"visual",setDirty:!0}),r.eachComponent((function(t,e){if("series"!==t){var a=i.getViewOfComponentModel(e);a&&a.__alive&&a.updateVisual(e,r,i._api,n)}})),r.eachSeries((function(t){i._chartsMap[t.__viewId].updateVisual(t,r,i._api,n)})),Jx.trigger("afterupdate",r,this._api))},updateLayout:function(t){$M.update.call(this,t)}},YM=function(t,n,i,r,e){if(!t._disposed)for(var a,o=t._model,u=t._coordSysMgr.getCoordinateSystems(),s=Eo(o,i),l=0;l<u.length;l++){var f=u[l];if(f[n]&&null!=(a=f[n](o,s,r,e)))return a}},XM=function(t,n){var i=t._chartsMap,r=t._scheduler;n.eachSeries((function(t){r.updateStreamModes(t,i[t.__viewId])}))},qM=function(t,n){var i=this,r=this.getModel(),e=t.escapeConnect,a=ck[t.type],o=(a.update||"update").split(":"),u=o.pop(),s=null!=o[0]&&Ct(o[0]);this[_M]=!0,ok(this);var l=[t],f=!1;t.batch&&(f=!0,l=U(t.batch,(function(n){return(n=B(P({},n),t)).batch=null,n})));var h,c=[],v=[],d=a.nonRefinedEventType,p=hs(t),m=cs(t);if(m&&Qu(this._api),H(l,(function(n){var e=a.action(n,r,i._api);if(a.refineEvent?v.push(e):h=e,(h=h||P({},n)).type=d,c.push(h),m){var o=Wo(t),l=o.mainTypeSpecified?o.queryOptionMap.keys()[0]:"series";VM(i,u,n,l),ek(i)}else p?(VM(i,u,n,"series"),ek(i)):s&&VM(i,u,n,s.main,s.sub)})),"none"!==u&&!m&&!p&&!s)try{this[RM]?(HM(this),$M.update.call(this,t),this[RM]=null):$M[u].call(this,t)}catch(t){throw this[_M]=!1,t}if(h=f?{type:d,escapeConnect:e,batch:c}:c[0],this[_M]=!1,!n){var y=void 0;if(a.refineEvent){var g=a.refineEvent(v,t,r,this._api).eventContent;ht(tt(g)),(y=B({type:a.refinedEventType},g)).fromAction=t.type,y.fromActionPayload=t,y.escapeConnect=!0}var b=this._messageCenter;b.trigger(h.type,h),y&&b.trigger(y.type,y)}},GM=function(t){for(var n=this._pendingActions;n.length;){var i=n.shift();qM.call(this,i,t)}},ZM=function(t){!t&&this.trigger("updated")},JM=function(t,n){t.on("rendered",(function(i){n.trigger("rendered",i),!t.animation.isFinished()||n[RM]||n._scheduler.unfinished||n._pendingActions.length?t.refresh():n.trigger("finished")}))},KM=function(t,n){t.on("mouseover",(function(t){var i=Zx(t.target,fs);i&&(function(t,n,i){var r=au(t),e=is(r.componentMainType,r.componentIndex,r.componentHighDownName,i),a=e.dispatchers;a?(e.focusSelf&&ns(r.componentMainType,r.componentIndex,i),H(a,(function(t){return $u(t,n)}))):(ts(r.seriesIndex,r.focus,r.blurScope,i),"self"===r.focus&&ns(r.componentMainType,r.componentIndex,i),$u(t,n))}(i,t,n._api),ek(n))})).on("mouseout",(function(t){var i=Zx(t.target,fs);i&&(function(t,n,i){Qu(i);var r=au(t),e=is(r.componentMainType,r.componentIndex,r.componentHighDownName,i).dispatchers;e?H(e,(function(t){return Yu(t,n)})):Yu(t,n)}(i,t,n._api),ek(n))})).on("click",(function(t){var i=Zx(t.target,(function(t){return null!=au(t).dataIndex}),!0);if(i){var r=i.selected?"unselect":"select",e=au(i);n._api.dispatchAction({type:r,dataType:e.dataType,dataIndexInside:e.dataIndex,seriesIndex:e.seriesIndex,isFromClick:!0})}}))},QM=function(t,n,i,r,e){!function(t){var n=[],i=[],r=!1;if(t.eachComponent((function(t,e){var a=e.get("zlevel")||0,o=e.get("z")||0,u=e.getZLevelKey();r=r||!!u,("series"===t?i:n).push({zlevel:a,z:o,idx:e.componentIndex,type:t,key:u})})),r){var e,a,o=n.concat(i);tw(o,(function(t,n){return t.zlevel===n.zlevel?t.z-n.z:t.zlevel-n.zlevel})),H(o,(function(n){var i=t.getComponent(n.type,n.idx),r=n.zlevel,o=n.key;null!=e&&(r=Math.max(e,r)),o?(r===e&&o!==a&&r++,a=o):a&&(r===e&&r++,a=""),e=r,i.setZLevel(r)}))}}(n),tk(t,n,i,r,e),H(t._chartsViews,(function(t){t.__alive=!1})),nk(t,n,i,r,e),H(t._chartsViews,(function(t){t.__alive||t.remove(n,i)}))},tk=function(t,n,a,o,u,s){H(s||t._componentsViews,(function(t){var u=t.__model;r(0,t),t.render(u,n,a,o),i(u,t),e(u,t)}))},nk=function(t,n,a,o,u,s){var l=t._scheduler;u=P(u||{},{updatedSeries:n.getSeries()}),Jx.trigger("series:beforeupdate",n,a,u);var f=!1;n.eachSeries((function(n){var i=t._chartsMap[n.__viewId];i.__alive=!0;var e=i.renderTask;l.updatePayload(e,o),r(0,i),s&&s.get(n.uid)&&e.dirty(),e.perform(l.getPerformArgs(e))&&(f=!0),i.group.silent=!!n.get("silent"),function(t,n){var i=t.get("blendMode")||null;n.eachRendered((function(t){t.isGroup||(t.style.blend=i)}))}(n,i),rs(n)})),l.unfinished=f||l.unfinished,Jx.trigger("series:layoutlabels",n,a,u),Jx.trigger("series:transition",n,a,u),n.eachSeries((function(n){var r=t._chartsMap[n.__viewId];i(n,r),e(n,r)})),function(t,n){var i=t._zr;if("canvas"===i.painter.type){var r=0;i.storage.traverse((function(t){t.isGroup||r++}));var e=r>ut(n.get("hoverLayerThreshold"),Fw.hoverLayerThreshold)&&!At.node&&!At.worker;(t._usingTHL||e)&&(n.eachSeries((function(n){if(!n.preventUsingHoverLayer){var i=t._chartsMap[n.__viewId];i.__alive&&i.eachRendered((function(t){var n=t.states.emphasis;n&&2!==n.hoverLayer&&(n.hoverLayer=e?1:0)}))}})),t._usingTHL=e)}}(t,n),Jx.trigger("series:afterupdate",n,a,u)},ek=function(t){t[FM]=!0,t.getZr().wakeUp()},ok=function(t){t[zM]=(t[zM]+1)%1e6},ak=function(t){t[FM]&&(t.getZr().storage.traverse((function(t){Il(t)||n(t)})),t[FM]=!1)},ik=function(t){return new(function(n){function i(){return null!==n&&n.apply(this,arguments)||this}return v(i,n),i.prototype.getCoordinateSystems=function(){return t._coordSysMgr.getCoordinateSystems()},i.prototype.getComponentByElement=function(n){for(;n;){var i=n.__ecComponentInfo;if(null!=i)return t._model.getComponent(i.mainType,i.index);n=n.parent}},i.prototype.enterEmphasis=function(n,i){Xu(n,i),ek(t)},i.prototype.leaveEmphasis=function(n,i){qu(n,i),ek(t)},i.prototype.enterBlur=function(n){!function(t){ju(t,Fu)}(n),ek(t)},i.prototype.leaveBlur=function(n){Gu(n),ek(t)},i.prototype.enterSelect=function(n){Zu(n),ek(t)},i.prototype.leaveSelect=function(n){Ju(n),ek(t)},i.prototype.getModel=function(){return t.getModel()},i.prototype.getViewOfComponentModel=function(n){return t.getViewOfComponentModel(n)},i.prototype.getViewOfSeriesModel=function(n){return t.getViewOfSeriesModel(n)},i.prototype.getECUpdateCycleVersion=function(){return t[zM]},i.prototype.usingTHL=function(){return t._usingTHL},i}(bu))(t)},rk=function(t){function n(t,n){for(var i=0;i<t.length;i++)t[i][BM]=n}H(vk,(function(i,r){t._messageCenter.on(r,(function(i){if(xk[t.group]&&0!==t[BM]){if(i&&i.escapeConnect)return;var r=t.makeActionFromEvent(i),e=[];H(wk,(function(n){n!==t&&n.group===t.group&&e.push(n)})),n(e,0),H(e,(function(t){1!==t[BM]&&t.dispatchAction(r)})),n(e,2)}}))}))}}(),n}(Ur),fk=lk.prototype;fk.on=EM("on"),fk.off=EM("off"),fk.one=function(t,n,i){var r=this;this.on.call(this,t,(function i(){for(var e=[],a=0;a<arguments.length;a++)e[a]=arguments[a];n&&n.apply&&n.apply(this,e),r.off(t,i)}),i)};var hk=["click","dblclick","mouseover","mouseout","mousemove","mousedown","mouseup","globalout","contextmenu"],ck={},vk={},dk={},pk=[],mk=[],yk=[],gk={},bk={},wk={},xk={},Mk=+new Date-0,kk="_echarts_instance_";function Sk(t,n){gk[t]=n}function Ak(t){E(mk,t)<0&&mk.push(t)}function Tk(t,n){Lk(pk,t,n,2e3)}function Nk(t,n){Jx.on(t,n)}function Ck(t,n,i){var r,e,a,o,u;function s(t){return t.toLowerCase()}Z(n)&&(i=n,n=""),tt(t)?(r=t.type,e=t.event,o=t.update,u=t.publishNonRefinedEvent,i||(i=t.action),a=t.refineEvent):(r=t,e=n),e=s(e||r);var l=a?s(r):e;ck[r]||(ht(PM.test(r)&&PM.test(e)),a&&ht(e!==r),ck[r]={actionType:r,refinedEventType:e,nonRefinedEventType:l,update:o,action:i,refineEvent:a},dk[e]=1,a&&u&&(dk[l]=1),vk[l]=r)}function Ok(t,n){Lk(yk,t,n,3e3,"visual")}var Ik=[];function Lk(t,n,i,r,e){if((Z(n)||tt(n))&&(i=n,n=r),!(E(Ik,i)>=0)){Ik.push(i);var a=Sx.wrapStageHandler(i,e);a.__prio=n,a.__raw=i,t.push(a)}}function Dk(t,n){bk[t]=n}function _k(t,n,i){return{eventContent:{selected:es(i),isFromClick:n.isFromClick||!1}}}Ok(IM,gx),Ok(LM,xx),Ok(LM,Mx),Ok(IM,qx),Ok(LM,Gx),Ok(7e3,OM),Ak(fx),Tk(900,hx),Dk("default",(function(t,n){B(n=n||{},{text:"loading",textColor:Jv.color.primary,fontSize:12,fontWeight:"normal",fontStyle:"normal",fontFamily:"sans-serif",maskColor:"rgba(255,255,255,0.8)",showSpinner:!0,color:Jv.color.theme[0],spinnerRadius:10,lineWidth:5,zlevel:0});var i=new Is,r=new Ta({style:{fill:n.maskColor},zlevel:n.zlevel,z:1e4});i.add(r);var e,a=new Ia({style:{text:n.text,fill:n.textColor,fontSize:n.fontSize,fontWeight:n.fontWeight,fontStyle:n.fontStyle,fontFamily:n.fontFamily},zlevel:n.zlevel,z:10001}),o=new Ta({style:{fill:"none"},textContent:a,textConfig:{position:"right",distance:10},zlevel:n.zlevel,z:10001});return i.add(o),n.showSpinner&&((e=new fl({shape:{startAngle:-kx/2,endAngle:-kx/2+.1,r:n.spinnerRadius},style:{stroke:n.color,lineCap:"round",lineWidth:n.lineWidth},zlevel:n.zlevel,z:10001})).animateShape(!0).when(1e3,{endAngle:3*kx/2}).start("circularInOut"),e.animateShape(!0).when(1e3,{startAngle:3*kx/2}).delay(300).start("circularInOut"),i.add(e)),i.resize=function(){var i=a.getBoundingRect().width,u=n.showSpinner?n.spinnerRadius:0,s=(t.getWidth()-2*u-(n.showSpinner&&i?10:0)-i)/2-(n.showSpinner&&i?0:5+i/2)+(n.showSpinner?0:i/2)+(i?0:u),l=t.getHeight()/2;n.showSpinner&&e.setShape({cx:s,cy:l}),o.setShape({x:s-u,y:l-u,width:2*u,height:2*u}),r.setShape({x:0,y:0,width:t.getWidth(),height:t.getHeight()})},i.resize(),i})),Ck({type:Tu,event:Tu,update:Tu},Mt),Ck({type:Nu,event:Nu,update:Nu},Mt),Ck({type:Cu,event:Lu,update:Cu,action:Mt,refineEvent:_k,publishNonRefinedEvent:!0}),Ck({type:Ou,event:Lu,update:Ou,action:Mt,refineEvent:_k,publishNonRefinedEvent:!0}),Ck({type:Iu,event:Lu,update:Iu,action:Mt,refineEvent:_k,publishNonRefinedEvent:!0}),Sk("default",{}),Sk("dark",Vx);var zk=[],Rk={registerPreprocessor:Ak,registerProcessor:Tk,registerPostInit:function(t){Nk("afterinit",t)},registerPostUpdate:function(t){Nk("afterupdate",t)},registerUpdateLifecycle:Nk,registerAction:Ck,registerCoordinateSystem:function(t,n){sc.register(t,n)},registerLayout:function(t,n){Lk(yk,t,n,1e3,"layout")},registerVisual:Ok,registerTransform:function(t){var n=(t=R(t)).type;n||ko("");var i=n.split(":");2!==i.length&&ko("");var r=!1;"echarts"===i[0]&&(n=i[1],r=!0),t.__isBuiltIn=r,$v.set(n,t)},registerLoading:Dk,registerMap:function(t,n,i){var r=Kx.registerMap;r&&r(t,n,i)},registerImpl:function(t,n){Kx[t]=n},PRIORITY:DM,ComponentModel:Lv,ComponentView:cx,SeriesModel:gd,ChartView:lp,registerComponentModel:function(t){Lv.registerClass(t)},registerComponentView:function(t){cx.registerClass(t)},registerSeriesModel:function(t){gd.registerClass(t)},registerChartView:function(t){lp.registerClass(t)},registerCustomSeries:function(){},registerSubTypeDefaulter:function(t,n){Lv.registerSubTypeDefaulter(t,n)},registerPainter:function(t,n){Tw[t]=n}};function Fk(t){G(t)?H(t,(function(t){Fk(t)})):E(zk,t)>=0||(zk.push(t),Z(t)&&(t={install:t}),t.install(Rk))}var Pk=function(t){function n(){var i=null!==t&&t.apply(this,arguments)||this;return i.type=n.type,i.hasSymbolVisual=!0,i}return v(n,t),n.prototype.getInitialData=function(){return pc(0,this,{useEncodeDefaulter:!0})},n.prototype.getProgressive=function(){var t=this.option.progressive;return null==t?this.option.large?5e3:this.get("progressive"):t},n.prototype.getProgressiveThreshold=function(){var t=this.option.progressiveThreshold;return null==t?this.option.large?1e4:this.get("progressiveThreshold"):t},n.prototype.brushSelector=function(t,n,i){return i.point(n.getItemLayout(t))},n.prototype.getZLevelKey=function(){return this.getData().count()>this.getProgressiveThreshold()?this.id:""},n.type="series.scatter",n.dependencies=["grid","polar","geo","singleAxis","calendar","matrix"],n.defaultOption={coordinateSystem:"cartesian2d",z:2,legendHoverLink:!0,symbolSize:10,large:!1,largeThreshold:2e3,itemStyle:{opacity:.8},emphasis:{scale:!0},clip:!0,select:{itemStyle:{borderColor:Jv.color.primary}},universalTransition:{divideShape:"clone"}},n}(gd),Bk=function(){},Ek=function(t){function n(n){var i=t.call(this,n)||this;return i._off=0,i.hoverDataIdx=-1,i}return v(n,t),n.prototype.getDefaultShape=function(){return new Bk},n.prototype.reset=function(){this.notClear=!1,this._off=0},n.prototype.beforeBrush=function(t){t&&!t.contentRetained&&this.reset()},n.prototype.buildPath=function(t,n){var i,r=n.points,e=n.size,a=this.symbolProxy,o=a.shape,u=t.getContext?t.getContext():t,s=this.softClipShape;if(u&&e[0]<4)this._ctx=u;else{for(this._ctx=null,i=this._off;i<r.length;){var l=r[i++],f=r[i++];isNaN(l)||isNaN(f)||s&&!s.contain(l,f)||(o.x=l-e[0]/2,o.y=f-e[1]/2,o.width=e[0],o.height=e[1],a.buildPath(t,o,!0))}this.incremental&&(this._off=i,this.notClear=!0)}},n.prototype.afterBrush=function(){var t,n=this.shape,i=n.points,r=n.size,e=this._ctx,a=this.softClipShape;if(e){for(t=this._off;t<i.length;){var o=i[t++],u=i[t++];isNaN(o)||isNaN(u)||a&&!a.contain(o,u)||e.fillRect(o-r[0]/2,u-r[1]/2,r[0],r[1])}this.incremental&&(this._off=t,this.notClear=!0)}},n.prototype.findDataIndex=function(t,n){for(var i=this.shape,r=i.points,e=i.size,a=Math.max(e[0],4),o=Math.max(e[1],4),u=r.length/2-1;u>=0;u--){var s=2*u,l=r[s]-a/2,f=r[s+1]-o/2;if(t>=l&&n>=f&&t<=l+a&&n<=f+o)return u}return-1},n.prototype.contain=function(t,n){var i=this.transformCoordToLocal(t,n);return this.getBoundingRect().contain(t=i[0],n=i[1])?(this.hoverDataIdx=this.findDataIndex(t,n))>=0:(this.hoverDataIdx=-1,!1)},n.prototype.getBoundingRect=function(){var t=this._rect;if(!t){for(var n=this.shape,i=n.points,r=n.size,e=r[0],a=r[1],o=1/0,u=1/0,s=-1/0,l=-1/0,f=0;f<i.length;){var h=i[f++],c=i[f++];o=Math.min(h,o),s=Math.max(h,s),u=Math.min(c,u),l=Math.max(c,l)}t=this._rect=new On(o-e/2,u-a/2,s-o+e,l-u+a)}return t},n}(da),Wk=function(){function t(){this.group=new Is}return t.prototype.updateData=function(t,n){this._clear(),this._data=t;var i=this._create();i.setShape({points:t.getLayout("points")}),this._setCommon(i,t,n)},t.prototype.updateLayout=function(){var t=this._data;if(t){var n=t.getLayout("points");this.group.eachChild((function(t){null!=t.startIndex&&(n=new Float32Array(n.buffer,4*t.startIndex*2,2*(t.endIndex-t.startIndex))),t.setShape("points",n),t.reset(),t.stopAnimation()}))}},t.prototype.incrementalPrepareUpdate=function(){this._clear()},t.prototype.incrementalUpdate=function(t,n,i,r){var e=this._newAdded[0],a=n.getLayout("points"),o=e&&e.shape.points;if(o&&o.length<2e4){var u=o.length,s=new Float32Array(u+a.length);s.set(o),s.set(a,u),e.endIndex=t.end,e.setShape({points:s})}else{this._newAdded=[];var l=this._create();l.startIndex=t.start,l.endIndex=t.end,l.incremental=i,l.setShape({points:a}),this._setCommon(l,n,r)}},t.prototype.eachRendered=function(t){this._newAdded[0]&&t(this._newAdded[0])},t.prototype._create=function(){var t=new Ek({cursor:"default"});return t.ignoreCoarsePointer=!0,this.group.add(t),this._newAdded.push(t),t},t.prototype._setCommon=function(t,n,i){var r=n.hostModel;i=i||{};var e=n.getVisual("symbolSize");t.setShape("size",e instanceof Array?e:[e,e]),t.softClipShape=i.clipShape||null,t.symbolProxy=zd(n.getVisual("symbol"),0,0,0,0),t.setColor=t.symbolProxy.setColor;var a=t.shape.size[0]<4;t.useStyle(r.getModel("itemStyle").getItemStyle(a?["color","shadowBlur","shadowColor"]:["color"]));var o=n.getVisual("style"),u=o&&o.fill;u&&t.setColor(u);var s=au(t);s.seriesIndex=r.seriesIndex,t.on("mousemove",(function(){s.dataIndex=null;var n=t.hoverDataIdx;n>=0&&(s.dataIndex=n+(t.startIndex||0))}))},t.prototype.remove=function(){this._clear()},t.prototype._clear=function(){this._newAdded=[],this.group.removeAll()},t}(),jk=function(t){function n(){var i=null!==t&&t.apply(this,arguments)||this;return i.type=n.type,i}return v(n,t),n.prototype.render=function(t){var n=t.getData();this._updateSymbolDraw(n,t).updateData(n,Hk(t)),this._finished=!0},n.prototype.incrementalPrepareRender=function(t){var n=t.getData();this._updateSymbolDraw(n,t).incrementalPrepareUpdate(n),this._finished=!1},n.prototype.incrementalRender=function(t,n){this._symbolDraw.incrementalUpdate(t,n.getData(),nu(n),Hk(n)),this._finished=t.end===n.getData().count()},n.prototype.updateTransform=function(t,n,i){var r=t.getData();if(this.group.dirty(),!this._finished)return{update:!0};var e=Am("").reset(t,n,i);e.progress&&e.progress({start:0,end:r.count(),count:r.count()},r),this._symbolDraw.updateLayout(Hk(t))},n.prototype.eachRendered=function(t){this._symbolDraw&&this._symbolDraw.eachRendered(t)},n.prototype._updateSymbolDraw=function(t,n){var i=this._symbolDraw,r=n.pipelineContext.large;return i&&r===this._isLargeDraw||(i&&i.remove(),i=this._symbolDraw=r?new Wk:new $d,this._isLargeDraw=r,this.group.removeAll()),this.group.add(i.group),i},n.prototype.remove=function(){this._symbolDraw&&this._symbolDraw.remove(!0),this._symbolDraw=null},n.prototype.dispose=function(){},n.type="scatter",n}(lp);function Hk(t){return{clipShape:yp(t)}}var Uk=function(){function t(){}return t.prototype.needIncludeZero=function(){return!this.option.scale},t.prototype.getCoordSysModel=function(){},t}(),Vk=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return v(n,t),n.prototype.getCoordSysModel=function(){return this.getReferringComponents("grid",jo).models[0]},n.type="cartesian2dAxis",n}(Lv);W(Vk,Uk);var $k={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:"auto",onZeroAxisIndex:null,lineStyle:{color:Jv.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:Jv.color.axisLabel,textMargin:[0,3]},splitLine:{show:!0,showMinLine:!0,showMaxLine:!0,lineStyle:{color:Jv.color.axisSplitLine,width:1,type:"solid"}},splitArea:{show:!1,areaStyle:{color:[Jv.color.backgroundTint,Jv.color.backgroundTransparent]}},breakArea:{show:!0,itemStyle:{color:Jv.color.neutral00,borderColor:Jv.color.border,borderWidth:1,borderType:[3,3],opacity:.6},zigzagAmplitude:4,zigzagMinSpan:4,zigzagMaxSpan:20,zigzagZ:100,expandOnClick:!0},breakLabelLayout:{moveOverlap:"auto"}},Yk=F({boundaryGap:!0,deduplication:null,jitter:0,jitterOverlap:!0,jitterMargin:2,splitLine:{show:!1},axisTick:{alignWithLabel:!1,interval:"auto",show:"auto"},axisLabel:{interval:"auto"}},$k),Xk=F({boundaryGap:[0,0],axisLine:{show:"auto"},axisTick:{show:"auto"},splitNumber:5,minorTick:{show:!1,splitNumber:5,length:3,lineStyle:{}},minorSplitLine:{show:!1,lineStyle:{color:Jv.color.axisMinorSplitLine,width:1}}},$k),qk={category:Yk,value:Xk,time:F({splitNumber:6,axisLabel:{rich:{primary:{fontWeight:"bold"}}},splitLine:{show:!1}},Xk),log:B({logBase:10},Xk)};function Gk(t,n,i,r){H(em,(function(e,a){var o=F(F({},qk[a],!0),r,!0),u=function(t){function i(){var i=null!==t&&t.apply(this,arguments)||this;return i.type=n+"Axis."+a,i}return v(i,t),i.prototype.mergeDefaultAndTheme=function(t,n){var i=Nv(this),r=i?Ov(t):{};F(t,n.getTheme().get(a+"Axis")),F(t,this.getDefaultOption()),t.type=Zk(t),i&&Cv(t,r,i)},i.prototype.optionUpdated=function(){"category"===this.option.type&&(this.__ordinalMeta=xp.createByAxisModel(this))},i.prototype.getCategories=function(t){var n=this.option;if("category"===n.type)return t?n.data:this.__ordinalMeta.categories},i.prototype.getOrdinalMeta=function(){return this.__ordinalMeta},i.prototype.updateAxisBreaks=function(){return{breaks:[]}},i.type=n+"Axis."+a,i.defaultOption=o,i}(i);t.registerComponentModel(u)})),t.registerSubTypeDefaulter(n+"Axis",Zk)}function Zk(t){return t.type||(t.data?"category":"value")}var Jk=function(){function t(t){this.type="cartesian",this._dimList=[],this._axes={},this.name=t||""}return t.prototype.getAxis=function(t){return this._axes[t]},t.prototype.getAxes=function(){return U(this._dimList,(function(t){return this._axes[t]}),this)},t.prototype.getAxesByScale=function(t){return t=t.toLowerCase(),$(this.getAxes(),(function(n){return n.scale.type===t}))},t.prototype.addAxis=function(t){var n=t.dim;this._axes[n]=t,this._dimList.push(n)},t}(),Kk=["x","y"];function Qk(t){return("interval"===t.type||"time"===t.type)&&!Pc(t)}var tS=function(t){function n(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=cg,n.dimensions=Kk,n}return v(n,t),n.prototype.calcAffineTransform=function(){this._transform=this._invTransform=null;var t=this.getAxis("x").scale,n=this.getAxis("y").scale;if(Qk(t)&&Qk(n)){var i=Cp(t,null),r=Cp(n,null),e=this.dataToPoint([i[0],r[0]]),a=this.dataToPoint([i[1],r[1]]),o=i[1]-i[0],u=r[1]-r[0];if(o&&u){var s=(a[0]-e[0])/o,l=(a[1]-e[1])/u,f=this._transform=[s,0,0,l,e[0]-i[0]*s,e[1]-r[0]*l];this._invTransform=Qt([],f)}}},n.prototype.getBaseAxis=function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAxis("x")},n.prototype.containPoint=function(t){var n=this.getAxis("x"),i=this.getAxis("y");return n.contain(n.toLocalCoord(t[0]))&&i.contain(i.toLocalCoord(t[1]))},n.prototype.containData=function(t){return this.getAxis("x").containData(t[0])&&this.getAxis("y").containData(t[1])},n.prototype.containZone=function(t,n){var i=this.dataToPoint(t),r=this.dataToPoint(n),e=this.getArea(),a=new On(i[0],i[1],r[0]-i[0],r[1]-i[1]);return e.intersect(a)},n.prototype.dataToPoint=function(t,n,i){i=i||[];var r=t[0],e=t[1];if(this._transform&&null!=r&&isFinite(r)&&null!=e&&isFinite(e))return hn(i,t,this._transform);var a=this.getAxis("x"),o=this.getAxis("y");return i[0]=a.toGlobalCoord(a.dataToCoord(r,n)),i[1]=o.toGlobalCoord(o.dataToCoord(e,n)),i},n.prototype.clampData=function(t,n){var i=this.getAxis("x").scale,r=this.getAxis("y").scale,e=i.getExtent(),a=r.getExtent(),o=i.parse(t[0]),u=r.parse(t[1]);return(n=n||[])[0]=Math.min(Math.max(Math.min(e[0],e[1]),o),Math.max(e[0],e[1])),n[1]=Math.min(Math.max(Math.min(a[0],a[1]),u),Math.max(a[0],a[1])),n},n.prototype.pointToData=function(t,n,i){if(i=i||[],this._invTransform)return hn(i,t,this._invTransform);var r=this.getAxis("x"),e=this.getAxis("y");return i[0]=r.coordToData(r.toLocalCoord(t[0]),n),i[1]=e.coordToData(e.toLocalCoord(t[1]),n),i},n.prototype.getOtherAxis=function(t){return this.getAxis("x"===t.dim?"y":"x")},n.prototype.getArea=function(t){t=t||0;var n=this.getAxis("x").getGlobalExtent(),i=this.getAxis("y").getGlobalExtent(),r=Math.min(n[0],n[1])-t,e=Math.min(i[0],i[1])-t,a=Math.max(n[0],n[1])-r+t,o=Math.max(i[0],i[1])-e+t;return new On(r,e,a,o)},n}(Jk);function nS(t,n){var i=Rp(t),r=i?t.intervalStub:t,e=n.fixMinMax||[],a=i?t.getExtent():null,o=r.getExtent(),u=Wp(o,e,n.rawExtentResult);r.setExtent(u[0],u[1]),u=r.getExtent();var s=i?function(t,n){var i=jp(n.splitNumber,10),r=t.getExtent(),e=Op(t),a=Va(co(e),1);i/e*a<=.5&&(a*=10);var o=Pp(a);return{intervalPrecision:o,interval:a,niceExtent:[ro(qa(r[0]/a)*a,o),ro(Xa(r[1]/a)*a,o)]}}(r,n):function(t,n){var i=jp(n.splitNumber,5),r=Op(t),e=n.minInterval,a=n.maxInterval,o=po(r/i,!0);null!=e&&o<e&&(o=e),null!=a&&o>a&&(o=a);var u=Pp(o),s=t.getExtent();return{interval:o,intervalPrecision:u,niceExtent:[ro(qa(s[0]/o)*o,u),ro(Xa(s[1]/o)*o,u)]}}(r,n),l=s.intervalPrecision,f=s.interval,h=n.userInterval;null!=h&&(s.interval=h,s.intervalPrecision=Pp(h)),e[0]||(u[0]=ro(Xa(u[0]/f)*f,l)),e[1]||(u[1]=ro(qa(u[1]/f)*f,l)),null!=h&&(s.niceExtent=u.slice()),vm(t,e,o,u,a,s)}function iS(t){var n=t.model;!function(t,n,i,r){var e=ng(t,n,r,i),a=_p(t)||zp(t);(function(t,n){rS[t.type](t,n)})(t,{splitNumber:n.get("splitNumber"),fixMinMax:e.fixMM,userInterval:n.get("interval"),minInterval:a?n.get("minInterval"):null,maxInterval:a?n.get("maxInterval"):null,rawExtentResult:e}),i&&r&&function(t,n,i,r){var e;if(i.ctnShp&&(ny(t,(function(n){var i=tg.get(n);if(i){var a=i(t,r);a&&(Yo(e=e||[0,0],a[0]),Xo(e,a[1]),function(t){am(t).noOnMyZero=!0}(t))}})),e)){var a=n.getExtent();if(Fp(n))t.onBand||n.setExtent2(1,Ua(a[0],a[0]+e[0]),Va(a[1],a[1]+e[1]));else{var o=a.slice();i.zoomFixMM[0]||(o[0]=Ua(o[0],n.transformOut(n.transformIn(o[0],null)+e[0],null))),i.zoomFixMM[1]||(o[1]=Va(o[1],n.transformOut(n.transformIn(o[1],null)+e[1],null))),(o[0]<a[0]||o[1]>a[1])&&n.setExtent2(1,o[0],o[1])}}}(i,t,e,r)}(t.scale,n,n.axis,n.ecModel)}var rS={interval:nS,log:nS,time:function(t,n){var i=t.getExtent();if(i[0]===i[1]&&(i[0]-=Ec,i[1]+=Ec),i[1]===-1/0&&i[0]===1/0){var r=new Date;i[1]=+new Date(r.getFullYear(),r.getMonth(),r.getDate()),i[0]=i[1]-Ec}t.setExtent(i[0],i[1]);var e=jp(n.splitNumber,10),a=Op(t)/e,o=n.minInterval,u=n.maxInterval;null!=o&&a<o&&(a=o),null!=u&&a>u&&(a=u);var s=Xp.length,l=Math.min(function(t,n,i,r){for(;i<r;){var e=i+r>>>1;t[e][1]<n?i=e+1:r=e}return i}(Xp,a,0,s),s-1),f=Xp[l][1],h=Xp[Math.max(l-1,0)][0];t.setTimeInterval({approxInterval:a,interval:f,minLevelUnit:h})},ordinal:Mt},eS=[[3,1],[0,2]],aS=function(){function t(t,n,i){this.type="grid",this._coordsMap={},this._coordsList=[],this._axesMap={},this._axesList=[],this.axisPointerEnabled=!0,this.dimensions=Kk,this._initCartesian(t,n,i),this.model=t}return t.prototype.getRect=function(){return this._rect},t.prototype.update=function(t,n){var i=this._axesMap;function r(t){for(var n=Y(t),i=[],r=n.length-1;r>=0;r--){var e=t[+n[r]];e.__alignTo?i.push(e):iS(e)}H(i,(function(t){var n;n=t.__alignTo,Pc(t.scale)||Pc(n.scale)||n.scale.getTicks().length<2?iS(t):function(t,n){var i,r,e,a=t.scale,o=t.model,u=ng(a,o,o.ecModel,t),s=Rp(a),l=Rp(n)?n.intervalStub:n,f=s?a.intervalStub:a,h=a.base,c=l.getTicks(),v=l.getTicks({expandToNicedExtent:!0}),d=c.length-1;if(1===d)i=r=0,e=1;else if(2===d){var p=$a(c[0].value-c[1].value),m=$a(c[1].value-c[2].value);i=r=0,p===m?e=2:(e=1,p<m?i=p/m:r=m/p)}else{var y=l.getConfig().interval;e=d-((i=(1-(c[0].value-v[0].value)/y)%1)?1:0)-((r=(1-(v[d].value-c[d].value)/y)%1)?1:0)}var g,b,w,x,M,k,S=u.zoomFixMM,A=S[0]||S[1],T=[u.fixMM[0]||A,u.fixMM[1]||A],N=a.getExtent(),C=f.getExtent(),O=Wp(C,T);function I(t){for(var n,i,r,e,a=0;a<50&&!t();a++)w=s?w*Va(h,2):(e=void 0,i=vo(n=w),r=Ga(10,i),(e=Ya(n/r))?2===e?e=3:3===e?e=5:e*=2:e=1,ro(e*r,-i)),x=Pp(w)}function L(){g=ro(k-w*i,x)}function D(){b=ro(M+w*r,x)}function _(){k=i?ro(g+w*i,x):g}function z(){M=r?ro(b-w*r,x):b}if(T[0]&&T[1]){w=((b=O[1])-(g=O[0]))/(e+i+r);var R=t.getExtent(),F=$a(R[1]-R[0]);x=function(t,n,i){var r=$a(t[1]-t[0]);if(!isFinite(r)||0===r)return NaN;var e=Za(2*$a(i||1)*$a(r))/Ja,a=Za($a(n))/Ja,o=Va(0,qa(-e+a));return isFinite(o)||(o=NaN),o}([b,g],F,.5/e),_(),z(),wo(x)&&(w=ro(w,x))}else{var P=O[1]-O[0];w=s?Va(co(P),1):po(P/e,2),x=Pp(w),T[0]?(g=O[0],I((function(){if(_(),M=ro(k+w*e,x),D(),b>=O[1])return!0}))):T[1]?(b=O[1],I((function(){if(z(),k=ro(M-w*e,x),L(),g<=O[0])return!0}))):I((function(){k=ro(qa(O[0]/w)*w,x),M=ro(Xa(O[1]/w)*w,x);var t=Ya((M-k)/w);if(t<=e){var n=e-t,i=void 0,r=u.incl0||s;if(r&&0===O[0])i=[0,n];else if(r&&0===O[1])i=[n,0];else{var a=Xa(n/2);i=n%2==0?[a,a]:g+b<O[0]+O[1]?[a,a+1]:[a+1,a]}if(k=ro(k-w*i[0],x),M=ro(M+w*i[1],x),L(),D(),g<=O[0]&&b>=O[1])return!0}}))}vm(a,T,C,[g,b],N,{interval:w,intervalCount:e,intervalPrecision:x,niceExtent:[k,M]})}(t,t.__alignTo.scale)}))}H(this._axesList,(function(t){Jy(t,1);var n=t.scale;Fp(n)&&n.setSortInfo(t.model.get("categorySortInfo"))})),r(i.x),r(i.y);var e={};H(i.x,(function(t){oS(i,"y",t,e)})),H(i.y,(function(t){oS(i,"x",t,e)})),this.resize(this.model,n)},t.prototype.resize=function(t,n,i){var r=Tv(t,n),e=this._rect=Sv(t.getBoxLayoutParams(),r.refContainer),a=this._axesMap,o=this._coordsList,u=t.get("containLabel");if(lS(a,e),!i){var s=function(t,n,i,r,e){var a=new Ty(vS);return H(i,(function(i){return H(i,(function(i){cm(i.model)&&(i.axisBuilder=function(t,n,i,r,e,a){for(var o=Vy(t,i),u=!1,s=!1,l=0;l<n.length;l++)Dp(n[l].getOtherAxis(i.axis).scale)&&(u=s=!0,"category"===i.axis.type&&i.axis.onBand&&(s=!1));return o.axisLineAutoShow=u,o.axisTickAutoShow=s,o.defaultNameMoveOverlap=a,new Dy(i,r,o,e)}(t,n,i.model,e,a,!r))}))})),a}(e,o,a,u,n),l=void 0;if(u)l=hS(e.clone(),"axisLabel",null,e,a,s,r);else{var f=function(t,n,i){var r,e=t.get("outerBoundsMode",!0);"same"===e?r=n.clone():null!=e&&"auto"!==e||(r=Sv(t.get("outerBounds",!0)||fg,i.refContainer));var a=t.get("outerBoundsContain",!0);return{outerBoundsRect:r,parsedOuterBoundsContain:null==a||"auto"===a||E(["all","axisLabel"],a)<0?"all":a,outerBoundsClamp:[io(ut(t.get("outerBoundsClampWidth",!0),hg[0]),n.width),io(ut(t.get("outerBoundsClampHeight",!0),hg[1]),n.height)]}}(t,e,r),h=f.outerBoundsRect;h&&(l=hS(h,f.parsedOuterBoundsContain,f.outerBoundsClamp,e,a,s,r))}cS(e,a,2,null,l,r),H(this._coordsList,(function(t){t.calcAffineTransform()}))}},t.prototype.getAxis=function(t,n){var i=this._axesMap[t];if(null!=i)return i[n||0]},t.prototype.getAxes=function(){return this._axesList.slice()},t.prototype.getCartesian=function(t,n){if(null!=t&&null!=n)return this._coordsMap["x"+t+"y"+n];tt(t)&&(n=t.yAxisIndex,t=t.xAxisIndex);for(var i=0,r=this._coordsList;i<r.length;i++)if(r[i].getAxis("x").index===t||r[i].getAxis("y").index===n)return r[i]},t.prototype.getCartesians=function(){return this._coordsList.slice()},t.prototype.convertToPixel=function(t,n,i){var r=this._findConvertTarget(n);return r.cartesian?r.cartesian.dataToPoint(i):r.axis?r.axis.toGlobalCoord(r.axis.dataToCoord(i)):null},t.prototype.convertFromPixel=function(t,n,i){var r=this._findConvertTarget(n);return r.cartesian?r.cartesian.pointToData(i):r.axis?r.axis.coordToData(r.axis.toLocalCoord(i)):null},t.prototype._findConvertTarget=function(t){var n,i,r=t.seriesModel,e=t.xAxisModel||r&&r.getReferringComponents("xAxis",jo).models[0],a=t.yAxisModel||r&&r.getReferringComponents("yAxis",jo).models[0],o=t.gridModel;return r?E(this._coordsList,n=r.coordinateSystem)<0&&(n=null):e&&a?n=this.getCartesian(e.componentIndex,a.componentIndex):e?i=this.getAxis("x",e.componentIndex):a?i=this.getAxis("y",a.componentIndex):o&&o.coordinateSystem===this&&(n=this._coordsList[0]),{cartesian:n,axis:i}},t.prototype.containPoint=function(t){var n=this._coordsList[0];if(n)return n.containPoint(t)},t.prototype._initCartesian=function(t,n){var i=this,r=this,e={left:!1,right:!1,top:!1,bottom:!1},a={x:{},y:{}},o={x:0,y:0};if(n.eachComponent("xAxis",u("x"),this),n.eachComponent("yAxis",u("y"),this),!o.x||!o.y)return this._axesMap={},void(this._axesList=[]);function u(n){return function(i,u){if(function(t,n){return t.getCoordSysModel()===n}(i,t)){var s=i.get("position");"x"===n?"top"!==s&&"bottom"!==s&&(s=e.bottom?"top":"bottom"):"left"!==s&&"right"!==s&&(s=e.left?"right":"left"),e[s]=!0;var l=om(i),f=new hy(n,um(i,l),[0,0],l,s);f.onBand=pm(f.scale,i),f.inverse=i.get("inverse"),i.axis=f,f.model=i,f.grid=r,f.index=u,r._axesList.push(f),a[n][u]=f,o[n]++}}}this._axesMap=a,H(a.x,(function(n,r){H(a.y,(function(e,a){var o="x"+r+"y"+a,u=new tS(o);u.master=i,u.model=t,i._coordsMap[o]=u,i._coordsList.push(u),u.addAxis(n),u.addAxis(e)}))})),sS(a.x),sS(a.y)},t.prototype.getTooltipAxes=function(t){var n=[],i=[];return H(this.getCartesians(),(function(r){var e=null!=t&&"auto"!==t?r.getAxis(t):r.getBaseAxis(),a=r.getOtherAxis(e);E(n,e)<0&&n.push(e),E(i,a)<0&&i.push(a)})),{baseAxes:n,otherAxes:i}},t.create=function(n,i){var r=[];return n.eachComponent("grid",(function(e,a){var o=new t(e,n,i);o.name="grid_"+a,o.resize(e,i,!0),e.coordinateSystem=o,r.push(o),H(o._axesList,(function(n){var i,r;r=t.dimIdxMap,Zy(i=n).dimIdxInCoord=r.get(i.dim)}))})),n.eachSeries((function(t){var n,i;!function(t){var n=t.targetModel,i=t.coordSysType,r=t.coordSysProvider,e=t.isDefaultDataCoordSys,a=function(t){var n=t.getShallow("coordinateSystem"),i=t.getShallow("coordinateSystemUsage",!0),r=0;if(n){var e="series"===t.mainType;null==i&&(i=e?"data":"box"),"data"===i?(r=1,e||(r=0)):"box"===i&&(r=2,e||function(t){return!!oc[t]}(n)||(r=0))}return{coordSysType:n,kind:r}}(n),o=a.kind,u=a.coordSysType;if(e&&1!==o&&(o=1,u=i),0===o||u!==i)return 0;var s=r(i,n);s&&(1===o?n.coordinateSystem=s:n.boxCoordinateSystem=s)}({targetModel:t,coordSysType:cg,coordSysProvider:function(){var r=function(t){var n={xAxisModel:null,yAxisModel:null};return H(n,(function(i,r){var e=r.replace(/Model$/,""),a=t.getReferringComponents(e,jo).models[0];n[r]=a})),n}(t),e=r.xAxisModel,a=r.yAxisModel;return n=e.axis,i=a.axis,e.getCoordSysModel().coordinateSystem.getCartesian(e.componentIndex,a.componentIndex)}}),n&&i&&(ey(n,t,cg),ey(i,t,cg))}),this),r},t.dimensions=Kk,t.dimIdxMap=Hh(Kk),t}();function oS(t,n,i,r){i.getAxesOnZeroOf=function(){return e?[e]:[]};var e,a=t[n],o=i.model,u=o.get(["axisLine","onZero"]),s=o.get(["axisLine","onZeroAxisIndex"]);if(u){if(null!=s)uS(u,a[s])&&(e=a[s]);else for(var l in a)if(xt(a,l)&&uS(u,a[l])&&!r[f(a[l])]){e=a[l];break}e&&(r[f(e)]=!0)}function f(t){return t.dim+"_"+t.index}}function uS(t,n){if(!n)return!1;var i=function(t){var n=t.getExtentUnsafe(0,null),i=n[0],r=n[1];return Go(i,r)?0===i||0===r?2:i<0&&r>0?1:3:3}(n.scale),r=n&&"category"!==n.type&&"time"!==n.type&&3!==i;return r&&"auto"===t&&function(t){return am(t).noOnMyZero}(n)&&(r=!1),r}function sS(t){for(var n,i=Y(t),r=[],e=i.length-1;e>=0;e--){var a=t[+i[e]];Dp(a.scale)&&null==void a.model.get("breaks",!0)&&(a.model.get("alignTicks")&&null==a.model.get("interval")?r.push(a):n=a)}n||(n=r.pop()),n&&H(r,(function(t){t.__alignTo=n}))}function lS(t,n){H(t.x,(function(t){return fS(t,n.x,n.width)})),H(t.y,(function(t){return fS(t,n.y,n.height)}))}function fS(t,n,i){var r=[0,i],e=t.inverse?1:0;t.setExtent(r[e],r[1-e]),function(t,n){var i=t.getExtent(),r=i[0]+i[1];t.toGlobalCoord="x"===t.dim?function(t){return t+n}:function(t){return r-t+n},t.toLocalCoord="x"===t.dim?function(t){return t-n}:function(t){return r-t+n}}(t,n)}function hS(t,n,i,r,e,a,o){cS(r,e,1,n,!1,o);var u=[0,0,0,0];l(0),l(1),f(r,0,NaN),f(r,1,NaN);var s=null==function(t,n){if(t&&n)for(var i=0,r=t.length;i<r;i++)if(n.call(undefined,t[i],i,t))return t[i]}(u,(function(t){return t>0}));return Kl(r,u,!0,!0,i),lS(e,r),s;function l(t){H(e[Fl[t]],(function(n){if(cm(n.model)){var i=a.ensureRecord(n.model),r=i.labelInfoList;if(r)for(var e=0;e<r.length;e++){var o=r[e],u=n.scale.normalize(dm(n.scale,Sy(o.label).labelInfo.tick));f(o.rect,t,u=1===t?1-u:u),f(o.rect,1-t,NaN)}var s=i.nameLayout;s&&(u=hm(i.nameLocation)?.5:NaN,f(s.rect,t,u),f(s.rect,1-t,NaN))}}))}function f(n,i,r){var e=t[Fl[i]]-n[Fl[i]],a=n[Pl[i]]+n[Fl[i]]-(t[Pl[i]]+t[Fl[i]]);e=h(e,1-r),a=h(a,r);var o=eS[i][0],s=eS[i][1];u[o]=Va(u[o],e),u[s]=Va(u[s],a)}function h(t,n){return t>0&&!at(n)&&n>1e-4&&(t/=n),t}}function cS(t,n,i,r,e,a){var o=2===i;H(n,(function(n){return H(n,(function(n){cm(n.model)&&(function(t,n,i){var r=Vy(n,i);t.updateCfg(r)}(n.axisBuilder,t,n.model),n.axisBuilder.build(o?{axisTickLabelDetermine:!0}:{axisTickLabelEstimate:!0},{noPxChange:e}))}))}));var u={x:0,y:0};function s(n){u[Fl[1-n]]=t[Pl[n]]<=.5*a.refContainer[Pl[n]]?0:1-n==1?2:1}s(0),s(1),H(n,(function(t,n){return H(t,(function(t){cm(t.model)&&(("all"===r||o)&&t.axisBuilder.build({axisName:!0},{nameMarginLevel:u[n]}),o&&t.axisBuilder.build({axisLine:!0}))}))}))}var vS=function(t,n,i,r,e,a){var o="x"===i.axis.dim?"y":"x";Oy(t,0,0,r,e,a),hm(t.nameLocation)||H(n.recordMap[o],(function(t){t&&t.labelInfoList&&t.dirVec&&Ly(t.labelInfoList,t.dirVec,r,e)}))};function dS(t,n){return"all"===t||G(t)&&E(t,n)>=0||t===n}function pS(t){var n=(t.ecModel.getComponent("axisPointer")||{}).coordSysAxesInfo;return n&&n.axesInfo[yS(t)]}function mS(t){return!!t.get(["handle","show"])}function yS(t){return t.type+"||"+t.id}var gS={},bS=function(t){function n(){var i=null!==t&&t.apply(this,arguments)||this;return i.type=n.type,i}return v(n,t),n.prototype.render=function(n,i,r,e){this.axisPointerClass&&function(t){var n=pS(t);if(n){var i=n.axisPointerModel,r=n.axis.scale,e=i.option,a=i.get("status"),o=i.get("value");null!=o&&(o=r.parse(o));var u=mS(i);null==a&&(e.status=u?"show":"hide");var s=r.getExtent();(null==o||o>s[1])&&(o=s[1]),o<s[0]&&(o=s[0]),e.value=o,u&&(e.status=n.axis.scale.isBlank()?"hide":"show")}}(n),t.prototype.render.apply(this,arguments),this._doUpdateAxisPointerClass(n,r,!0)},n.prototype.updateAxisPointer=function(t,n,i){this._doUpdateAxisPointerClass(t,i,!1)},n.prototype.remove=function(t,n){var i=this._axisPointer;i&&i.remove(n)},n.prototype.dispose=function(n,i){this._disposeAxisPointer(i),t.prototype.dispose.apply(this,arguments)},n.prototype._doUpdateAxisPointerClass=function(t,i,r){var e=n.getAxisPointerClass(this.axisPointerClass);if(e){var a=function(t){var n=pS(t);return n&&n.axisPointerModel}(t);a?(this._axisPointer||(this._axisPointer=new e)).render(t,a,i,r):this._disposeAxisPointer(i)}},n.prototype._disposeAxisPointer=function(t){this._axisPointer&&this._axisPointer.dispose(t),this._axisPointer=null},n.registerAxisPointerClass=function(t,n){gS[t]=n},n.getAxisPointerClass=function(t){return t&&gS[t]},n.type="axis",n}(cx),wS=Po(),xS=["splitArea","splitLine","minorSplitLine","breakArea"],MS=function(t){function n(){var i=null!==t&&t.apply(this,arguments)||this;return i.type=n.type,i.axisPointerClass="CartesianAxisPointer",i}return v(n,t),n.prototype.render=function(n,i,r,e){this.group.removeAll();var a=this._axisGroup;this._axisGroup=new Is,this.group.add(this._axisGroup),cm(n)&&(this._axisGroup.add(n.axis.axisBuilder.group),H(xS,(function(t){n.get([t,"show"])&&kS[t](this,this._axisGroup,n,n.getCoordSysModel(),r)}),this),e&&"changeAxisOrder"===e.type&&e.isInitSort||ql(a,this._axisGroup,n),t.prototype.render.call(this,n,i,r,e))},n.prototype.remove=function(){wS(this).splitAreaColors=null},n.type="cartesianAxis",n}(bS),kS={splitLine:function(t,n,i,r){var e=i.axis;if(!e.scale.isBlank()){var a=i.getModel("splitLine"),o=a.getModel("lineStyle"),u=o.get("color"),s=!1!==a.get("showMinLine"),l=!1!==a.get("showMaxLine");u=G(u)?u:[u];for(var f=r.coordinateSystem.getRect(),h=e.isHorizontal(),c=0,v=e.getTicksCoords({tickModel:a,breakTicks:"none",pruneByBreak:"preserve_extent_bound"}),d=[],p=[],m=o.getLineStyle(),y=0;y<v.length;y++){var g=e.toGlobalCoord(v[y].coord);if((0!==y||s)&&(y!==v.length-1||l)){var b=v[y].tickValue;h?(d[0]=g,d[1]=f.y,p[0]=g,p[1]=f.y+f.height):(d[0]=f.x,d[1]=g,p[0]=f.x+f.width,p[1]=g);var w=c++%u.length,x=new el({anid:null!=b?"line_"+b:null,autoBatch:!0,shape:{x1:d[0],y1:d[1],x2:p[0],y2:p[1]},style:B({stroke:u[w]},m),silent:!0});Vl(x.shape,m.lineWidth),n.add(x)}}}},minorSplitLine:function(t,n,i,r){var e=i.axis,a=i.getModel("minorSplitLine").getModel("lineStyle"),o=r.coordinateSystem.getRect(),u=e.isHorizontal(),s=e.getMinorTicksCoords();if(s.length)for(var l=[],f=[],h=a.getLineStyle(),c=0;c<s.length;c++)for(var v=0;v<s[c].length;v++){var d=e.toGlobalCoord(s[c][v].coord);u?(l[0]=d,l[1]=o.y,f[0]=d,f[1]=o.y+o.height):(l[0]=o.x,l[1]=d,f[0]=o.x+o.width,f[1]=d);var p=new el({anid:"minor_line_"+s[c][v].tickValue,autoBatch:!0,shape:{x1:l[0],y1:l[1],x2:f[0],y2:f[1]},style:h,silent:!0});Vl(p.shape,h.lineWidth),n.add(p)}},splitArea:function(t,n,i,r){!function(t,n,i,r){var e=i.axis;if(!e.scale.isBlank()){var a=i.getModel("splitArea"),o=a.getModel("areaStyle"),u=o.get("color"),s=r.coordinateSystem.getRect(),l=e.getTicksCoords({tickModel:a,breakTicks:"none",pruneByBreak:"preserve_extent_bound"});if(l.length){var f=u.length,h=wS(t).splitAreaColors,c=bt(),v=0;if(h)for(var d=0;d<l.length;d++){var p=h.get(l[d].tickValue);if(null!=p){v=(p+(f-1)*d)%f;break}}var m=e.toGlobalCoord(l[0].coord),y=o.getAreaStyle();for(u=G(u)?u:[u],d=1;d<l.length;d++){var g=e.toGlobalCoord(l[d].coord),b=void 0,w=void 0,x=void 0,M=void 0;e.isHorizontal()?(w=s.y,M=s.height,m=(b=m)+(x=g-b)):(b=s.x,x=s.width,m=(w=m)+(M=g-w));var k=l[d-1].tickValue;null!=k&&c.set(k,v),n.add(new Ta({anid:null!=k?"area_"+k:null,shape:{x:b,y:w,width:x,height:M},style:B({fill:u[v]},y),autoBatch:!0,silent:!0})),v=(v+1)%f}wS(t).splitAreaColors=c}}}(t,n,i,r)},breakArea:function(){}},SS=function(t){function n(){var i=null!==t&&t.apply(this,arguments)||this;return i.type=n.type,i}return v(n,t),n.type="xAxis",n}(MS),AS=function(t){function n(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=SS.type,n}return v(n,t),n.type="yAxis",n}(MS),TS=function(t){function n(){var n=null!==t&&t.apply(this,arguments)||this;return n.type="grid",n}return v(n,t),n.prototype.render=function(t){this.group.removeAll(),t.get("show")&&this.group.add(new Ta({shape:t.coordinateSystem.getRect(),style:B({fill:t.get("backgroundColor")},t.getItemStyle()),silent:!0,z2:-1}))},n.type="grid",n}(cx),NS={offset:0};function CS(t){t.registerComponentView(TS),t.registerComponentModel(vg),t.registerCoordinateSystem("cartesian2d",aS),Gk(t,"x",Vk,NS),Gk(t,"y",Vk,NS),t.registerComponentView(SS),t.registerComponentView(AS),t.registerPreprocessor((function(t){t.xAxis&&t.yAxis&&!t.grid&&(t.grid={})}))}var OS=function(){this.angle=0,this.width=10,this.r=10,this.x=0,this.y=0},IS=function(t){function n(n){var i=t.call(this,n)||this;return i.type="pointer",i}return v(n,t),n.prototype.getDefaultShape=function(){return new OS},n.prototype.buildPath=function(t,n){var i=Math.cos,r=Math.sin,e=n.r,a=n.width,o=n.angle,u=n.x-i(o)*a*(a>=e/3?1:2),s=n.y-r(o)*a*(a>=e/3?1:2);o=n.angle-Math.PI/2,t.moveTo(u,s),t.lineTo(n.x+i(o)*a,n.y+r(o)*a),t.lineTo(n.x+i(n.angle)*e,n.y+r(n.angle)*e),t.lineTo(n.x-i(o)*a,n.y-r(o)*a),t.lineTo(u,s)},n}(da);function LS(t,n){var i=null==t?"":t+"";return n&&(J(n)?i=n.replace("{value}",i):Z(n)&&(i=n(t))),i}var DS=function(t){function n(){var i=null!==t&&t.apply(this,arguments)||this;return i.type=n.type,i}return v(n,t),n.prototype.render=function(t,n,i){this.group.removeAll();var r=t.get(["axisLine","lineStyle","color"]),e=function(t,n){var i=t.get("center"),r=n.getWidth(),e=n.getHeight(),a=Math.min(r,e);return{cx:no(i[0],n.getWidth()),cy:no(i[1],n.getHeight()),r:no(t.get("radius"),a/2)}}(t,i);this._renderMain(t,n,i,r,e),this._data=t.getData()},n.prototype.dispose=function(){},n.prototype._renderMain=function(t,n,i,r,e){var a=this.group,o=t.get("clockwise"),u=-t.get("startAngle")/180*Math.PI,s=-t.get("endAngle")/180*Math.PI,l=t.getModel("axisLine"),f=l.get("roundCap")?Tg:qs,h=l.get("show"),c=l.getModel("lineStyle"),v=c.get("width"),d=[u,s];Xe(d,!o);for(var p=(s=d[1])-(u=d[0]),m=u,y=[],g=0;h&&g<r.length;g++){var b=new f({shape:{startAngle:m,endAngle:s=u+p*Math.min(Math.max(r[g][0],0),1),cx:e.cx,cy:e.cy,clockwise:o,r0:e.r-v,r:e.r},silent:!0});b.setStyle({fill:r[g][1]}),b.setStyle(c.getLineStyle(["color","width"])),y.push(b),m=s}y.reverse(),H(y,(function(t){return a.add(t)}));var w=function(t){if(t<=0)return r[0][1];var n;for(n=0;n<r.length;n++)if(r[n][0]>=t&&(0===n?0:r[n-1][0])<t)return r[n][1];return r[n-1][1]};this._renderTicks(t,n,i,w,e,u,s,o,v),this._renderTitleAndDetail(t,n,i,w,e),this._renderAnchor(t,e),this._renderPointer(t,n,i,w,e,u,s,o,v)},n.prototype._renderTicks=function(t,n,i,r,e,a,o,u,s){for(var l,f,h=this.group,c=e.cx,v=e.cy,d=e.r,p=+t.get("min"),m=+t.get("max"),y=t.getModel("splitLine"),g=t.getModel("axisTick"),b=t.getModel("axisLabel"),w=t.get("splitNumber"),x=g.get("splitNumber"),M=no(y.get("length"),d),k=no(g.get("length"),d),S=a,A=(o-a)/w,T=A/x,N=y.getModel("lineStyle").getLineStyle(),C=g.getModel("lineStyle").getLineStyle(),O=y.get("distance"),I=0;I<=w;I++){if(l=Math.cos(S),f=Math.sin(S),y.get("show")){var L=new el({shape:{x1:l*(d-(D=O?O+s:s))+c,y1:f*(d-D)+v,x2:l*(d-M-D)+c,y2:f*(d-M-D)+v},style:N,silent:!0});"auto"===N.stroke&&L.setStyle({stroke:r(I/w)}),h.add(L)}if(b.get("show")){var D=b.get("distance")+O,_=LS(ro(I*(m-p)/w+p,14),b.get("formatter")),z=r(I/w),R=l*(d-M-D)+c,F=f*(d-M-D)+v,P=b.get("rotate"),B=0;"radial"===P?(B=-S+2*Math.PI)>Math.PI/2&&(B+=Math.PI):"tangential"===P?B=-S-Math.PI/2:Q(P)&&(B=P*Math.PI/180),h.add(new Ia(0===B?{style:bf(b,{text:_,x:R,y:F,verticalAlign:f<-.8?"top":f>.8?"bottom":"middle",align:l<-.4?"left":l>.4?"right":"center"},{inheritColor:z}),silent:!0}:{style:bf(b,{text:_,x:R,y:F,verticalAlign:"middle",align:"center"},{inheritColor:z}),silent:!0,originX:R,originY:F,rotation:B}))}if(g.get("show")&&I!==w){D=(D=g.get("distance"))?D+s:s;for(var E=0;E<=x;E++){l=Math.cos(S),f=Math.sin(S);var W=new el({shape:{x1:l*(d-D)+c,y1:f*(d-D)+v,x2:l*(d-k-D)+c,y2:f*(d-k-D)+v},silent:!0,style:C});"auto"===C.stroke&&W.setStyle({stroke:r((I+E/x)/w)}),h.add(W),S+=T}S-=T}else S+=A}},n.prototype._renderPointer=function(t,n,i,r,e,a,o,u,s){var l=this.group,f=this._data,h=this._progressEls,c=[],v=t.get(["pointer","show"]),d=t.getModel("progress"),p=d.get("show"),m=t.getData(),y=m.mapDimension("value"),g=+t.get("min"),b=+t.get("max"),w=[g,b],x=[a,o];function M(n,i){var r,a=m.getItemModel(n).getModel("pointer"),o=no(a.get("width"),e.r),u=no(a.get("length"),e.r),s=t.get(["pointer","icon"]),l=a.get("offsetCenter"),f=no(l[0],e.r),h=no(l[1],e.r),c=a.get("keepAspect");return(r=s?zd(s,f-o/2,h-u,o,u,null,c):new IS({shape:{angle:-Math.PI/2,width:o,r:u,x:f,y:h}})).rotation=-(i+Math.PI/2),r.x=e.cx,r.y=e.cy,r}function k(t,n){var i=d.get("roundCap")?Tg:qs,r=d.get("overlap"),o=r?d.get("width"):s/m.count(),l=new i({shape:{startAngle:a,endAngle:n,cx:e.cx,cy:e.cy,clockwise:u,r0:r?e.r-o:e.r-(t+1)*o,r:r?e.r:e.r-t*o}});return r&&(l.z2=to(m.get(y,t),[g,b],[100,0],!0)),l}(p||v)&&(m.diff(f).add((function(n){var i=m.get(y,n);if(v){var r=M(n,a);Ol(r,{rotation:-((isNaN(+i)?x[0]:to(i,w,x,!0))+Math.PI/2)},t),l.add(r),m.setItemGraphicEl(n,r)}if(p){var e=k(n,a),o=d.get("clip");Ol(e,{shape:{endAngle:to(i,w,x,o)}},t),l.add(e),ou(t.seriesIndex,m.dataType,n,e),c[n]=e}})).update((function(n,i){var r=m.get(y,n);if(v){var e=f.getItemGraphicEl(i),o=e?e.rotation:a,u=M(n,o);u.rotation=o,Cl(u,{rotation:-((isNaN(+r)?x[0]:to(r,w,x,!0))+Math.PI/2)},t),l.add(u),m.setItemGraphicEl(n,u)}if(p){var s=h[i],g=k(n,s?s.shape.endAngle:a),b=d.get("clip");Cl(g,{shape:{endAngle:to(r,w,x,b)}},t),l.add(g),ou(t.seriesIndex,m.dataType,n,g),c[n]=g}})).execute(),m.each((function(t){var n=m.getItemModel(t),i=n.getModel("emphasis"),e=i.get("focus"),a=i.get("blurScope"),o=i.get("disabled"),u=r(to(m.get(y,t),w,[0,1],!0));if(v){var s=m.getItemGraphicEl(t),l=m.getItemVisual(t,"style"),f=l.fill;if(s instanceof ba){var h=s.style;s.useStyle(P({image:h.image,x:h.x,y:h.y,width:h.width,height:h.height},l))}else s.useStyle(l),"pointer"!==s.type&&s.setColor(f);s.setStyle(n.getModel(["pointer","itemStyle"]).getItemStyle()),"auto"===s.style.fill&&s.setStyle("fill",u),s.z2EmphasisLift=0,ss(s,n),as(s,e,a,o)}if(p){var d=c[t];d.useStyle(m.getItemVisual(t,"style")),d.setStyle(n.getModel(["progress","itemStyle"]).getItemStyle()),"auto"===d.style.fill&&d.setStyle("fill",u),d.z2EmphasisLift=0,ss(d,n),as(d,e,a,o)}})),this._progressEls=c)},n.prototype._renderAnchor=function(t,n){var i=t.getModel("anchor");if(i.get("show")){var r=i.get("size"),e=i.get("icon"),a=i.get("offsetCenter"),o=i.get("keepAspect"),u=zd(e,n.cx-r/2+no(a[0],n.r),n.cy-r/2+no(a[1],n.r),r,r,null,o);u.z2=i.get("showAbove")?1:0,u.setStyle(i.getModel("itemStyle").getItemStyle()),this.group.add(u)}},n.prototype._renderTitleAndDetail=function(t,n,i,r,e){var a=this,o=t.getData(),u=o.mapDimension("value"),s=+t.get("min"),l=+t.get("max"),f=new Is,h=[],c=[],v=t.isAnimationEnabled(),d=t.get(["pointer","showAbove"]);o.diff(this._data).add((function(t){h[t]=new Ia({silent:!0}),c[t]=new Ia({silent:!0})})).update((function(t,n){h[t]=a._titleEls[n],c[t]=a._detailEls[n]})).execute(),o.each((function(n){var i=o.getItemModel(n),a=o.get(u,n),p=new Is,m=r(to(a,[s,l],[0,1],!0)),y=i.getModel("title");if(y.get("show")){var g=y.get("offsetCenter"),b=e.cx+no(g[0],e.r),w=e.cy+no(g[1],e.r);(C=h[n]).attr({z2:d?0:2,style:bf(y,{x:b,y:w,text:o.getName(n),align:"center",verticalAlign:"middle"},{inheritColor:m})}),p.add(C)}var x=i.getModel("detail");if(x.get("show")){var M=x.get("offsetCenter"),k=e.cx+no(M[0],e.r),S=e.cy+no(M[1],e.r),A=no(x.get("width"),e.r),T=no(x.get("height"),e.r),N=t.get(["progress","show"])?o.getItemVisual(n,"style").fill:m,C=c[n],O=x.get("formatter");C.attr({z2:d?0:2,style:bf(x,{x:k,y:S,text:LS(a,O),width:isNaN(A)?null:A,height:isNaN(T)?null:T,align:"center",verticalAlign:"middle"},{inheritColor:N})}),Tf(C,{normal:x},a,(function(t){return LS(t,O)})),v&&function(t,n,i,r,e){var a=Af(t);if(a.valueAnimation&&a.prevValue!==a.value){var o=a.defaultInterpolatedText,u=ut(a.interpolatedValue,a.prevValue),s=a.value;t.percent=0,(null==a.prevValue?Ol:Cl)(t,{percent:1},r,n,null,(function(r){var l=Vo(i,a.precision,u,s,r);a.interpolatedValue=1===r?null:l;var f=mf({labelDataIndex:n,labelFetcher:e,defaultText:o?o(l):l+""},a.statesModels,l);pf(t,f)}))}}(C,n,o,t,{getFormattedLabel:function(t,n,i,r,e,o){return LS(o?o.interpolatedValue:a,O)}}),p.add(C)}f.add(p)})),this.group.add(f),this._titleEls=h,this._detailEls=c},n.type="gauge",n}(lp),_S=function(t){function n(){var i=null!==t&&t.apply(this,arguments)||this;return i.type=n.type,i.visualStyleAccessPath="itemStyle",i}return v(n,t),n.prototype.getInitialData=function(){return Gg(this,["value"])},n.type="series.gauge",n.defaultOption={z:2,colorBy:"data",center:["50%","50%"],legendHoverLink:!0,radius:"75%",startAngle:225,endAngle:-45,clockwise:!0,min:0,max:100,splitNumber:10,axisLine:{show:!0,roundCap:!1,lineStyle:{color:[[1,Jv.color.neutral10]],width:10}},progress:{show:!1,overlap:!0,width:10,roundCap:!1,clip:!0},splitLine:{show:!0,length:10,distance:10,lineStyle:{color:Jv.color.axisTick,width:3,type:"solid"}},axisTick:{show:!0,splitNumber:5,length:6,distance:10,lineStyle:{color:Jv.color.axisTickMinor,width:1,type:"solid"}},axisLabel:{show:!0,distance:15,color:Jv.color.axisLabel,fontSize:12,rotate:0},pointer:{icon:null,offsetCenter:[0,0],show:!0,showAbove:!0,length:"60%",width:6,keepAspect:!1},anchor:{show:!1,showAbove:!1,size:6,icon:"circle",offsetCenter:[0,0],keepAspect:!1,itemStyle:{color:Jv.color.neutral00,borderWidth:0,borderColor:Jv.color.theme[0]}},title:{show:!0,offsetCenter:[0,"20%"],color:Jv.color.secondary,fontSize:16,valueAnimation:!1},detail:{show:!0,backgroundColor:Jv.color.transparent,borderWidth:0,borderColor:Jv.color.neutral40,width:100,height:null,padding:[5,10],offsetCenter:[0,"40%"],color:Jv.color.primary,fontSize:30,fontWeight:"bold",lineHeight:30,valueAnimation:!1}},n}(gd),zS=Po(),RS=R,FS=X,PS=function(){function t(){this._dragging=!1,this.animationThreshold=15}return t.prototype.render=function(t,n,i,r){var e=n.get("value"),a=n.get("status");if(this._axisModel=t,this._axisPointerModel=n,this._api=i,r||this._lastValue!==e||this._lastStatus!==a){this._lastValue=e,this._lastStatus=a;var o=this._group,u=this._handle;if(!a||"hide"===a)return o&&o.hide(),void(u&&u.hide());o&&o.show(),u&&u.show();var s={};this.makeElOption(s,e,t,n,i);var l=s.graphicKey;l!==this._lastGraphicKey&&this.clear(i),this._lastGraphicKey=l;var f=this._moveAnimation=this.determineAnimation(t,n);if(o){var h=q(BS,n,f);this.updatePointerEl(o,s,h),this.updateLabelEl(o,s,h,n)}else o=this._group=new Is,this.createPointerEl(o,s,t,n),this.createLabelEl(o,s,t,n),i.getZr().add(o);HS(o,n,!0),this._renderHandle(e)}},t.prototype.remove=function(t){this.clear(t)},t.prototype.dispose=function(t){this.clear(t)},t.prototype.determineAnimation=function(t,n){var i=n.get("animation"),r=t.axis,e="category"===r.type,a=n.get("snap");if(!a&&!e)return!1;if("auto"===i||null==i){var o=this.animationThreshold;if(e&&uy(r).w>o)return!0;if(a){var u=pS(t).seriesDataCount,s=r.getExtent();return Math.abs(s[0]-s[1])/u>o}return!1}return!0===i},t.prototype.makeElOption=function(){},t.prototype.createPointerEl=function(t,n){var i=n.pointer;if(i){var r=zS(t).pointerEl=new vf[i.type](RS(n.pointer));t.add(r)}},t.prototype.createLabelEl=function(t,n,i,r){if(n.label){var e=zS(t).labelEl=new Ia(RS(n.label));t.add(e),WS(e,r)}},t.prototype.updatePointerEl=function(t,n,i){var r=zS(t).pointerEl;r&&n.pointer&&(r.setStyle(n.pointer.style),i(r,{shape:n.pointer.shape}))},t.prototype.updateLabelEl=function(t,n,i,r){var e=zS(t).labelEl;e&&(e.setStyle(n.label.style),i(e,{x:n.label.x,y:n.label.y}),WS(e,r))},t.prototype._renderHandle=function(t){if(!this._dragging&&this.updateHandleTransform){var n,i=this._axisPointerModel,r=this._api.getZr(),e=this._handle,a=i.getModel("handle"),o=i.get("status");if(!a.get("show")||!o||"hide"===o)return e&&r.remove(e),void(this._handle=null);this._handle||(n=!0,e=this._handle=Gl(a.get("icon"),{cursor:"move",draggable:!0,onmousemove:function(t){Fb(t.event)},onmousedown:FS(this._onHandleDragMove,this,0,0),drift:FS(this._onHandleDragMove,this),ondragend:FS(this._onHandleDragEnd,this)}),r.add(e)),HS(e,i,!1),e.setStyle(a.getItemStyle(null,["color","borderColor","borderWidth","opacity","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"]));var u=a.get("size");G(u)||(u=[u,u]),e.scaleX=u[0]/2,e.scaleY=u[1]/2,kg(this,"_doDispatchAxisPointer",a.get("throttle")||0,"fixRate"),this._moveHandleToValue(t,n)}},t.prototype._moveHandleToValue=function(t,n){BS(this._axisPointerModel,!n&&this._moveAnimation,this._handle,jS(this.getHandleTransform(t,this._axisModel,this._axisPointerModel)))},t.prototype._onHandleDragMove=function(t,n){var i=this._handle;if(i){this._dragging=!0;var r=this.updateHandleTransform(jS(i),[t,n],this._axisModel,this._axisPointerModel);this._payloadInfo=r,i.stopAnimation(),i.attr(jS(r)),zS(i).lastProp=null,this._doDispatchAxisPointer()}},t.prototype._doDispatchAxisPointer=function(){if(this._handle){var t=this._payloadInfo,n=this._axisModel;this._api.dispatchAction({type:"updateAxisPointer",x:t.cursorPoint[0],y:t.cursorPoint[1],tooltipOption:t.tooltipOption,axesInfo:[{axisDim:n.axis.dim,axisIndex:n.componentIndex}]})}},t.prototype._onHandleDragEnd=function(){if(this._dragging=!1,this._handle){var t=this._axisPointerModel.get("value");this._moveHandleToValue(t),this._api.dispatchAction({type:"hideTip"})}},t.prototype.clear=function(t){this._lastValue=null,this._lastStatus=null;var n=t.getZr(),i=this._group,r=this._handle;n&&i&&(this._lastGraphicKey=null,i&&n.remove(i),r&&n.remove(r),this._group=null,this._handle=null,this._payloadInfo=null),Sg(this,"_doDispatchAxisPointer")},t.prototype.doClear=function(){},t.prototype.buildLabel=function(t,n,i){return{x:t[i=i||0],y:t[1-i],width:n[i],height:n[1-i]}},t}();function BS(t,n,i,r){ES(zS(i).lastProp,r)||(zS(i).lastProp=r,n?Cl(i,r,t):(i.stopAnimation(),i.attr(r)))}function ES(t,n){if(tt(t)&&tt(n)){var i=!0;return H(n,(function(n,r){i=i&&ES(t[r],n)})),!!i}return t===n}function WS(t,n){t[n.get(["label","show"])?"show":"hide"]()}function jS(t){return{x:t.x||0,y:t.y||0,rotation:t.rotation||0}}function HS(t,n,i){var r=n.get("z"),e=n.get("zlevel");t&&t.traverse((function(t){"group"!==t.type&&(null!=r&&(t.z=r),null!=e&&(t.zlevel=e),t.silent=i)}))}function US(t){var n,i=t.get("type"),r=t.getModel(i+"Style");return"line"===i?(n=r.getLineStyle()).fill=null:"shadow"===i&&((n=r.getAreaStyle()).stroke=null),n}function VS(t,n,i,r,e){var a=$S(i.get("value"),n.axis,n.ecModel,i.get("seriesDataIndices"),{precision:i.get(["label","precision"]),formatter:i.get(["label","formatter"])}),o=i.getModel("label"),u=dv(o.get("padding")||0),s=o.getFont(),l=Un(a,s),f=e.position,h=l.width+u[1]+u[3],c=l.height+u[0]+u[2],v=e.align;"right"===v&&(f[0]-=h),"center"===v&&(f[0]-=h/2);var d=e.verticalAlign;"bottom"===d&&(f[1]-=c),"middle"===d&&(f[1]-=c/2),function(t,n,i,r){var e=r.getWidth(),a=r.getHeight();t[0]=Math.min(t[0]+n,e)-n,t[1]=Math.min(t[1]+i,a)-i,t[0]=Math.max(t[0],0),t[1]=Math.max(t[1],0)}(f,h,c,r);var p=o.get("backgroundColor");p&&"auto"!==p||(p=n.get(["axisLine","lineStyle","color"])),t.label={x:f[0],y:f[1],style:bf(o,{text:a,font:s,fill:o.getTextColor(),padding:u,backgroundColor:p}),z2:10}}function $S(t,n,i,r,e){t=n.scale.parse(t);var a=n.scale.getLabel({value:t},{precision:e.precision}),o=e.formatter;if(o){var u={value:lm(n,{value:t}),axisDimension:n.dim,axisIndex:n.index,seriesData:[]};H(r,(function(t){var n=i.getSeriesByIndex(t.seriesIndex),r=n&&n.getDataParams(t.dataIndexInside);r&&u.seriesData.push(r)})),J(o)?a=o.replace("{value}",a):Z(o)&&(a=o(u))}return a}function YS(t,n,i){var r=[1,0,0,1,0,0];return Kt(r,r,i.rotation),Jt(r,r,i.position),Yl([t.dataToCoord(n),(i.labelOffset||0)+(i.labelDirection||1)*(i.labelMargin||0)],r)}function XS(t,n,i){return{x1:t[i=i||0],y1:t[1-i],x2:n[i],y2:n[1-i]}}function qS(t,n,i,r,e,a){return{cx:t,cy:n,r0:i,r,startAngle:e,endAngle:a,clockwise:!0}}function GS(t,n,i){return uy(t,{fromStat:{sers:U(n,(function(t){return i.getSeriesByIndex(t.seriesIndex)}))},min:1}).w}function ZS(t,n,i){return[Va(Ua(n[0],n[1]),t-i/2),Ua(t+i/2,Va(n[0],n[1]))]}var JS=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return v(n,t),n.prototype.makeElOption=function(t,n,i,r,e){var a=i.axis,o=a.grid,u=r.get("type"),s=a.getGlobalExtent(),l=KS(o,a).getOtherAxis(a).getGlobalExtent(),f=a.toGlobalCoord(a.dataToCoord(n,!0));if(u&&"none"!==u){var h=US(r),c=QS[u](a,f,s,l,r.get("seriesDataIndices"),r.ecModel);c.style=h,t.graphicKey=c.type,t.pointer=c}!function(t,n,i,r,e,a){var o=Dy.innerTextLayout(i.rotation,0,i.labelDirection);i.labelMargin=e.get(["label","margin"]),VS(n,r,e,a,{position:YS(r.axis,t,i),align:o.textAlign,verticalAlign:o.textVerticalAlign})}(n,t,Vy(o.getRect(),i),i,r,e)},n.prototype.getHandleTransform=function(t,n,i){var r=Vy(n.axis.grid.getRect(),n,{labelInside:!1});r.labelMargin=i.get(["handle","margin"]);var e=YS(n.axis,t,r);return{x:e[0],y:e[1],rotation:r.rotation+(r.labelDirection<0?Math.PI:0)}},n.prototype.updateHandleTransform=function(t,n,i){var r=i.axis,e=r.grid,a=r.getGlobalExtent(!0),o=KS(e,r).getOtherAxis(r).getGlobalExtent(),u="x"===r.dim?0:1,s=[t.x,t.y];s[u]+=n[u],s[u]=Ua(a[1],s[u]),s[u]=Va(a[0],s[u]);var l=(o[1]+o[0])/2,f=[l,l];return f[u]=s[u],{x:s[0],y:s[1],rotation:t.rotation,cursorPoint:f,tooltipOption:[{verticalAlign:"middle"},{align:"center"}][u]}},n}(PS);function KS(t,n){var i={};return i[n.dim+"AxisIndex"]=n.index,t.getCartesian(i)}var QS={line:function(t,n,i,r){return{type:"Line",subPixelOptimize:!0,shape:XS([n,r[0]],[n,r[1]],tA(t))}},shadow:function(t,n,i,r,e,a){var o,u,s,l=GS(t,e,a),f=r[1]-r[0],h=ZS(n,i,l),c=h[0];return{type:"Rect",shape:(o=[c,r[0]],u=[h[1]-c,f],s=tA(t),{x:o[s=s||0],y:o[1-s],width:u[s],height:u[1-s]})}}};function tA(t){return"x"===t.dim?0:1}var nA=function(t){function n(){var i=null!==t&&t.apply(this,arguments)||this;return i.type=n.type,i}return v(n,t),n.type="axisPointer",n.defaultOption={show:"auto",z:50,type:"line",snap:!1,triggerTooltip:!0,triggerEmphasis:!0,value:null,status:null,link:[],animation:null,animationDurationUpdate:200,lineStyle:{color:Jv.color.border,width:1,type:"dashed"},shadowStyle:{color:Jv.color.shadowTint},label:{show:!0,formatter:null,precision:"auto",margin:3,color:Jv.color.neutral00,padding:[5,7,5,7],backgroundColor:Jv.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:Jv.color.accent40,throttle:40}},n}(Lv),iA=Po(),rA=H;function eA(t,n,i){if(!At.node){var r=n.getZr();iA(r).records||(iA(r).records={}),function(t,n){function i(i,r){t.on(i,(function(i){var e=function(t){var n={showTip:[],hideTip:[]},i=function(r){var e=n[r.type];e?e.push(r):(r.dispatchAction=i,t.dispatchAction(r))};return{dispatchAction:i,pendings:n}}(n);rA(iA(t).records,(function(t){t&&r(t,i,e.dispatchAction)})),function(t,n){var i,r=t.showTip.length,e=t.hideTip.length;r?i=t.showTip[r-1]:e&&(i=t.hideTip[e-1]),i&&(i.dispatchAction=null,n.dispatchAction(i))}(e.pendings,n)}))}iA(t).initialized||(iA(t).initialized=!0,i("click",q(oA,"click")),i("mousemove",q(oA,"mousemove")),i("mousewheel",q(oA,"mousewheel")),i("globalout",aA))}(r,n),(iA(r).records[t]||(iA(r).records[t]={})).handler=i}}function aA(t,n,i){t.handler("leave",null,i)}function oA(t,n,i,r){n.handler(t,i,r)}function uA(t,n){if(!At.node){var i=n.getZr();(iA(i).records||{})[t]&&(iA(i).records[t]=null)}}var sA=function(t){function n(){var i=null!==t&&t.apply(this,arguments)||this;return i.type=n.type,i}return v(n,t),n.prototype.render=function(t,n,i){var r=n.getComponent("tooltip"),e=t.get("triggerOn")||r&&r.get("triggerOn")||"mousemove|click|mousewheel";eA("axisPointer",i,(function(t,n,i){"none"!==e&&("leave"===t||e.indexOf(t)>=0)&&i({type:"updateAxisPointer",currTrigger:t,x:n&&n.offsetX,y:n&&n.offsetY})}))},n.prototype.remove=function(t,n){uA("axisPointer",n)},n.prototype.dispose=function(t,n){uA("axisPointer",n)},n.type="axisPointer",n}(cx);function lA(t,n){var i,r=[],e=t.seriesIndex;if(null==e||!(i=n.getSeriesByIndex(e)))return{point:[]};var a=i.getData(),o=Fo(a,t);if(null==o||o<0||G(o))return{point:[]};var u=a.getItemGraphicEl(o),s=i.coordinateSystem;if(i.getTooltipPosition)r=i.getTooltipPosition(o)||[];else if(s&&s.dataToPoint)if(t.isStacked){var l=s.getBaseAxis(),f=s.getOtherAxis(l).dim,h="x"===f||"radius"===f?1:0,c=a.mapDimension(l.dim),v=[];v[h]=a.get(c,o),v[1-h]=a.get(a.getCalculationInfo("stackResultDimension"),o),r=s.dataToPoint(v)||[]}else r=s.dataToPoint(a.getValues(U(s.dimensions,(function(t){return a.mapDimension(t)})),o))||[];else if(u){var d=u.getBoundingRect().clone();d.applyTransform(u.transform),r=[d.x+d.width/2,d.y+d.height/2]}return{point:r,el:u}}var fA=Po();function hA(t,n,i){var r=t.currTrigger,e=[t.x,t.y],a=t,o=t.dispatchAction||X(i.dispatchAction,i),u=n.getComponent("axisPointer").coordSysAxesInfo;if(u){mA(e)&&(e=lA({seriesIndex:a.seriesIndex,dataIndex:a.dataIndex},n).point);var s=mA(e),l=a.axesInfo,f=u.axesInfo,h="leave"===r||mA(e),c={},v={},d={list:[],map:{}},p={showPointer:q(vA,v),showTooltip:q(dA,d)};H(u.coordSysMap,(function(t,n){var i=s||t.containPoint(e);H(u.coordSysAxesInfo[n],(function(t){var n=t.axis,r=function(t,n){for(var i=0;i<(t||[]).length;i++){var r=t[i];if(n.axis.dim===r.axisDim&&n.axis.model.componentIndex===r.axisIndex)return r}}(l,t);if(!h&&i&&(!l||r)){var a=r&&r.value;null!=a||s||(a=n.pointToData(e)),null!=a&&cA(t,a,p,!1,c)}}))}));var m={};return H(f,(function(t,n){var i=t.linkGroup;i&&!v[n]&&H(i.axesInfo,(function(n,r){var e=v[r];if(n!==t&&e){var a=e.value;i.mapper&&(a=t.axis.scale.parse(i.mapper(a,pA(n),pA(t)))),m[t.key]=a}}))})),H(m,(function(t,n){cA(f[n],t,p,!0,c)})),function(t,n,i){var r=i.axesInfo=[];H(n,(function(n,i){var e=n.axisPointerModel.option,a=t[i];a?(!n.useHandle&&(e.status="show"),e.value=a.value,e.seriesDataIndices=(a.payloadBatch||[]).slice()):!n.useHandle&&(e.status="hide"),"show"===e.status&&r.push({axisDim:n.axis.dim,axisIndex:n.axis.model.componentIndex,value:e.value})}))}(v,f,c),function(t,n,i,r){if(!mA(n)&&t.list.length){var e=((t.list[0].dataByAxis[0]||{}).seriesDataIndices||[])[0]||{};r({type:"showTip",escapeConnect:!0,x:n[0],y:n[1],tooltipOption:i.tooltipOption,position:i.position,dataIndexInside:e.dataIndexInside,dataIndex:e.dataIndex,seriesIndex:e.seriesIndex,dataByCoordSys:t.list})}else r({type:"hideTip"})}(d,e,t,o),function(t,n,i){var r=i.getZr(),e="axisPointerLastHighlights",a=fA(r)[e]||{},o=fA(r)[e]={};H(t,(function(t){var n=t.axisPointerModel.option;"show"===n.status&&t.triggerEmphasis&&H(n.seriesDataIndices,(function(t){o[t.seriesIndex+"|"+t.dataIndex]=t}))}));var u=[],s=[];function l(t){return{seriesIndex:t.seriesIndex,dataIndex:t.dataIndex}}H(a,(function(t,n){!o[n]&&s.push(l(t))})),H(o,(function(t,n){!a[n]&&u.push(l(t))})),s.length&&i.dispatchAction({type:"downplay",escapeConnect:!0,notBlur:!0,batch:s}),u.length&&i.dispatchAction({type:"highlight",escapeConnect:!0,notBlur:!0,batch:u})}(f,0,i),c}}function cA(t,n,i,r,e){var a=t.axis;if(!a.scale.isBlank()&&a.containData(n))if(t.involveSeries){var o=function(t,n){var i=n.axis,r=i.dim,e=t,a=[],o=Number.MAX_VALUE,u=-1;return H(n.seriesModels,(function(n){var s,l,f=n.getData().mapDimensionsAll(r);if(n.getAxisTooltipData){var h=n.getAxisTooltipData(f,t,i);l=h.dataIndices,s=h.nestestValue}else{if(!(l=n.indicesOfNearest(r,f[0],t,"category"===i.type?.5:null)).length)return;s=n.getData().get(f[0],l[0])}if(wo(s)){var c=t-s,v=Math.abs(c);v<=o&&((v<o||c>=0&&u<0)&&(o=v,u=c,e=s,a.length=0),H(l,(function(t){a.push({seriesIndex:n.seriesIndex,dataIndexInside:t,dataIndex:n.getData().getRawIndex(t)})})))}})),{payloadBatch:a,snapToValue:e}}(n,t),u=o.payloadBatch,s=o.snapToValue;u[0]&&null==e.seriesIndex&&P(e,u[0]),!r&&t.snap&&a.containData(s)&&null!=s&&(n=s),i.showPointer(t,n,u),i.showTooltip(t,o,s)}else i.showPointer(t,n)}function vA(t,n,i,r){t[n.key]={value:i,payloadBatch:r}}function dA(t,n,i,r){var e=i.payloadBatch,a=n.axis,o=a.model,u=n.axisPointerModel;if(n.triggerTooltip&&e.length){var s=n.coordSys.model,l=yS(s),f=t.map[l];f||(f=t.map[l]={coordSysId:s.id,coordSysIndex:s.componentIndex,coordSysType:s.type,coordSysMainType:s.mainType,dataByAxis:[]},t.list.push(f)),f.dataByAxis.push({axisDim:a.dim,axisIndex:o.componentIndex,axisType:o.type,axisId:o.id,value:r,valueLabelOpt:{precision:u.get(["label","precision"]),formatter:u.get(["label","formatter"])},seriesDataIndices:e.slice()})}}function pA(t){var n=t.axis.model,i={},r=i.axisDim=t.axis.dim;return i.axisIndex=i[r+"AxisIndex"]=n.componentIndex,i.axisName=i[r+"AxisName"]=n.name,i.axisId=i[r+"AxisId"]=n.id,i}function mA(t){return!t||null==t[0]||isNaN(t[0])||null==t[1]||isNaN(t[1])}function yA(t){bS.registerAxisPointerClass("CartesianAxisPointer",JS),t.registerComponentModel(nA),t.registerComponentView(sA),t.registerPreprocessor((function(t){if(t){(!t.axisPointer||0===t.axisPointer.length)&&(t.axisPointer={});var n=t.axisPointer.link;n&&!G(n)&&(t.axisPointer.link=[n])}})),t.registerProcessor(t.PRIORITY.PROCESSOR.STATISTIC,{overallReset:function(t,n){t.getComponent("axisPointer").coordSysAxesInfo=function(t,n){var i={axesInfo:{},seriesInvolved:!1,coordSysAxesInfo:{},coordSysMap:{}};return function(t,n,i){var r=n.getComponent("tooltip"),e=n.getComponent("axisPointer"),a=e.get("link",!0)||[],o=[];H(i.getCoordinateSystems(),(function(i){if(i.axisPointerEnabled){var u=yS(i.model),s=t.coordSysAxesInfo[u]={};t.coordSysMap[u]=i;var l=i.model.getModel("tooltip",r);if(H(i.getAxes(),q(v,!1,null)),i.getTooltipAxes&&r&&l.get("show")){var f="axis"===l.get("trigger"),h="cross"===l.get(["axisPointer","type"]),c=i.getTooltipAxes(l.get(["axisPointer","axis"]));(f||h)&&H(c.baseAxes,q(v,!h||"cross",f)),h&&H(c.otherAxes,q(v,"cross",!1))}}function v(r,u,f){var h=f.model.getModel("axisPointer",e),c=h.get("show");if(c&&("auto"!==c||r||mS(h))){null==u&&(u=h.get("triggerTooltip")),h=r?function(t,n,i,r,e,a){var o=n.getModel("axisPointer"),u={};H(["type","snap","lineStyle","shadowStyle","label","animation","animationDurationUpdate","animationEasingUpdate","z"],(function(t){u[t]=R(o.get(t))})),u.snap="category"!==t.type&&!!a,"cross"===o.get("type")&&(u.type="line");var s=u.label||(u.label={});if(null==s.show&&(s.show=!1),"cross"===e){var l=o.get(["label","show"]);if(s.show=null==l||l,!a){var f=u.lineStyle=o.get("crossStyle");f&&B(s,f.textStyle)}}return t.model.getModel("axisPointer",new Wf(u,i,r))}(f,l,e,n,r,u):h;var v=h.get("snap"),d=h.get("triggerEmphasis"),p=yS(f.model),m=u||v||"category"===f.type,y=t.axesInfo[p]={key:p,axis:f,coordSys:i,axisPointerModel:h,triggerTooltip:u,triggerEmphasis:d,involveSeries:m,snap:v,useHandle:mS(h),seriesModels:[],linkGroup:null};s[p]=y,t.seriesInvolved=t.seriesInvolved||m;var g=function(t,n){for(var i=n.model,r=n.dim,e=0;e<t.length;e++){var a=t[e]||{};if(dS(a[r+"AxisId"],i.id)||dS(a[r+"AxisIndex"],i.componentIndex)||dS(a[r+"AxisName"],i.name))return e}}(a,f);if(null!=g){var b=o[g]||(o[g]={axesInfo:{}});b.axesInfo[p]=y,b.mapper=a[g].mapper,y.linkGroup=b}}}}))}(i,t,n),i.seriesInvolved&&function(t,n){n.eachSeries((function(n){var i=n.coordinateSystem,r=n.get(["tooltip","trigger"],!0),e=n.get(["tooltip","show"],!0);i&&i.model&&"none"!==r&&!1!==r&&"item"!==r&&!1!==e&&!1!==n.get(["axisPointer","show"],!0)&&H(t.coordSysAxesInfo[yS(i.model)],(function(t){var r=t.axis;i.getAxis(r.dim)===r&&(t.seriesModels.push(n),null==t.seriesDataCount&&(t.seriesDataCount=0),t.seriesDataCount+=n.getData().count())}))}))}(i,t),i}(t,n)}}),t.registerAction({type:"updateAxisPointer",event:"updateAxisPointer",update:":updateAxisPointer"},hA)}var gA=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return v(n,t),n.prototype.makeElOption=function(t,n,i,r,e){var a=i.axis;"angle"===a.dim&&(this.animationThreshold=Math.PI/18);var o=a.polar,u=a.getExtent(),s=o.getOtherAxis(a).getExtent(),l=a.dataToCoord(n),f=r.get("type");if(f&&"none"!==f){var h=US(r),c=bA[f](a,o,l,u,s,r.get("seriesDataIndices"),r.ecModel);c.style=h,t.graphicKey=c.type,t.pointer=c}var v=function(t,n,i,r,e){var a=n.axis,o=a.dataToCoord(t),u=r.getAngleAxis().getExtent()[0];u=u/180*Math.PI;var s,l,f,h=r.getRadiusAxis().getExtent();if("radius"===a.dim){var c=[1,0,0,1,0,0];Kt(c,c,u),Jt(c,c,[r.cx,r.cy]),s=Yl([o,-e],c);var v=n.getModel("axisLabel").get("rotate")||0,d=Dy.innerTextLayout(u,v*Math.PI/180,-1);l=d.textAlign,f=d.textVerticalAlign}else{var p=h[1];s=r.coordToPoint([p+e,o]);var m=r.cx,y=r.cy;l=Math.abs(s[0]-m)/p<.3?"center":s[0]>m?"left":"right",f=Math.abs(s[1]-y)/p<.3?"middle":s[1]>y?"top":"bottom"}return{position:s,align:l,verticalAlign:f}}(n,i,0,o,r.get(["label","margin"]));VS(t,i,r,e,v)},n}(PS),bA={line:function(t,n,i,r,e){return"angle"===t.dim?{type:"Line",shape:XS(n.coordToPoint([e[0],i]),n.coordToPoint([e[1],i]))}:{type:"Circle",shape:{cx:n.cx,cy:n.cy,r:i}}},shadow:function(t,n,i,r,e,a,o){var u,s=Math.PI/180,l=GS(t,a,o);if("angle"===t.dim)u=qS(n.cx,n.cy,e[0],e[1],(-i-l/2)*s,(l/2-i)*s);else{var f=ZS(i,r,l);u=qS(n.cx,n.cy,f[0],f[1],0,2*Math.PI)}return{type:"Sector",shape:u}}},wA="polar",xA=wA,MA=function(t){function n(){var i=null!==t&&t.apply(this,arguments)||this;return i.type=n.type,i}return v(n,t),n.prototype.findAxisModel=function(t){var n;return this.ecModel.eachComponent(t,(function(t){t.getCoordSysModel()===this&&(n=t)}),this),n},n.type=wA,n.dependencies=["radiusAxis","angleAxis"],n.defaultOption={z:0,center:["50%","50%"],radius:"80%"},n}(Lv),kA=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return v(n,t),n.prototype.getCoordSysModel=function(){return this.getReferringComponents("polar",jo).models[0]},n.type="polarAxis",n}(Lv);W(kA,Uk);var SA=function(t){function n(){var i=null!==t&&t.apply(this,arguments)||this;return i.type=n.type,i}return v(n,t),n.type="angleAxis",n}(kA),AA=function(t){function n(){var i=null!==t&&t.apply(this,arguments)||this;return i.type=n.type,i}return v(n,t),n.type="radiusAxis",n}(kA),TA=function(t){function n(n,i){return t.call(this,"radius",n,i)||this}return v(n,t),n.prototype.pointToData=function(t,n){return this.polar.pointToData(t,n)["radius"===this.dim?0:1]},n}(ly);TA.prototype.dataToRadius=ly.prototype.dataToCoord,TA.prototype.radiusToData=ly.prototype.coordToData;var NA=Po(),CA=function(t){function n(n,i){return t.call(this,"angle",n,i||[0,360])||this}return v(n,t),n.prototype.pointToData=function(t,n){return this.polar.pointToData(t,n)["radius"===this.dim?0:1]},n.prototype.calculateCategoryInterval=function(){var t=this,n=t.getLabelModel(),i=t.scale,r=i.getExtent(),e=i.count();if(r[1]-r[0]<1)return 0;var a=r[0],o=t.dataToCoord(a+1)-t.dataToCoord(a),u=Math.abs(o),s=Un(null==a?"":a+"",n.getFont(),"center","top"),l=Math.max(s.height,7)/u;isNaN(l)&&(l=1/0);var f=Math.max(0,Math.floor(l)),h=NA(t.model),c=h.lastAutoInterval,v=h.lastTickCount;return null!=c&&null!=v&&Math.abs(c-f)<=1&&Math.abs(v-e)<=1&&c>f?f=c:(h.lastTickCount=e,h.lastAutoInterval=f),f},n}(ly);CA.prototype.dataToAngle=ly.prototype.dataToCoord,CA.prototype.angleToData=ly.prototype.coordToData;var OA=["radius","angle"],IA=function(){function t(t){this.dimensions=OA,this.type=wA,this.cx=0,this.cy=0,this._radiusAxis=new TA,this._angleAxis=new CA,this.axisPointerEnabled=!0,this.name=t||"",this._radiusAxis.polar=this._angleAxis.polar=this}return t.prototype.containPoint=function(t){var n=this.pointToCoord(t);return this._radiusAxis.contain(n[0])&&this._angleAxis.contain(n[1])},t.prototype.containData=function(t){return this._radiusAxis.containData(t[0])&&this._angleAxis.containData(t[1])},t.prototype.getAxis=function(t){return this["_"+t+"Axis"]},t.prototype.getAxes=function(){return[this._radiusAxis,this._angleAxis]},t.prototype.getAxesByScale=function(t){var n=[],i=this._angleAxis,r=this._radiusAxis;return i.scale.type===t&&n.push(i),r.scale.type===t&&n.push(r),n},t.prototype.getAngleAxis=function(){return this._angleAxis},t.prototype.getRadiusAxis=function(){return this._radiusAxis},t.prototype.getOtherAxis=function(t){var n=this._angleAxis;return t===n?this._radiusAxis:n},t.prototype.getBaseAxis=function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAngleAxis()},t.prototype.getTooltipAxes=function(t){var n=null!=t&&"auto"!==t?this.getAxis(t):this.getBaseAxis();return{baseAxes:[n],otherAxes:[this.getOtherAxis(n)]}},t.prototype.dataToPoint=function(t,n,i){return this.coordToPoint([this._radiusAxis.dataToRadius(t[0],n),this._angleAxis.dataToAngle(t[1],n)],i)},t.prototype.pointToData=function(t,n,i){i=i||[];var r=this.pointToCoord(t);return i[0]=this._radiusAxis.radiusToData(r[0],n),i[1]=this._angleAxis.angleToData(r[1],n),i},t.prototype.pointToCoord=function(t){var n=t[0]-this.cx,i=t[1]-this.cy,r=this.getAngleAxis(),e=r.getExtent(),a=Math.min(e[0],e[1]),o=Math.max(e[0],e[1]);r.inverse?a=o-360:o=a+360;var u=Math.sqrt(n*n+i*i);n/=u,i/=u;for(var s=Math.atan2(-i,n)/Math.PI*180,l=s<a?1:-1;s<a||s>o;)s+=360*l;return[u,s]},t.prototype.coordToPoint=function(t,n){n=n||[];var i=t[0],r=t[1]/180*Math.PI;return n[0]=Math.cos(r)*i+this.cx,n[1]=-Math.sin(r)*i+this.cy,n},t.prototype.getArea=function(){var t=this.getAngleAxis(),n=this.getRadiusAxis().getExtent().slice();n[0]>n[1]&&n.reverse();var i=t.getExtent(),r=Math.PI/180,e=1e-4;return{cx:this.cx,cy:this.cy,r0:n[0],r:n[1],startAngle:-i[0]*r,endAngle:-i[1]*r,clockwise:t.inverse,contain:function(t,n){var i=t-this.cx,r=n-this.cy,a=i*i+r*r,o=this.r,u=this.r0;return o!==u&&a-e<=o*o&&a+e>=u*u},x:this.cx-n[1],y:this.cy-n[1],width:2*n[1],height:2*n[1]}},t.prototype.convertToPixel=function(t,n,i){return LA(n)===this?this.dataToPoint(i):null},t.prototype.convertFromPixel=function(t,n,i){return LA(n)===this?this.pointToData(i):null},t}();function LA(t){var n=t.seriesModel,i=t.polarModel;return i&&i.coordinateSystem||n&&n.coordinateSystem}function DA(){var t=this.getAngleAxis(),n=this.getRadiusAxis();if(Jy(t,1),Jy(n,1),iS(t),iS(n),"category"===t.type&&!t.onBand){var i=t.getExtent(),r=360/t.scale.count();t.inverse?i[1]+=r:i[1]-=r,t.setExtent(i[0],i[1])}}function _A(t,n){var i;if(t.type=om(n),t.scale=um(n,t.type),t.onBand=pm(t.scale,n),t.inverse=n.get("inverse"),function(t){return"angleAxis"===t.mainType}(n)){t.inverse=t.inverse!==n.get("clockwise");var r=n.get("startAngle"),e=null!==(i=n.get("endAngle"))&&void 0!==i?i:r+(t.inverse?-360:360);t.setExtent(r,e)}n.axis=t,t.model=n}var zA={dimensions:OA,create:function(t,n){var i=[];return t.eachComponent(xA,(function(t,r){var e=new IA(r+"");e.update=DA;var a=e.getRadiusAxis(),o=e.getAngleAxis(),u=t.findAxisModel("radiusAxis"),s=t.findAxisModel("angleAxis");_A(a,u),_A(o,s),function(t,n,i){var r=n.get("center"),e=Tv(n,i).refContainer;t.cx=no(r[0],e.width)+e.x,t.cy=no(r[1],e.height)+e.y;var a=t.getRadiusAxis(),o=Math.min(e.width,e.height)/2,u=n.get("radius");null==u?u=[0,"100%"]:G(u)||(u=[0,u]);var s=[no(u[0],o),no(u[1],o)];a.inverse?a.setExtent(s[1],s[0]):a.setExtent(s[0],s[1])}(e,t,n),i.push(e),t.coordinateSystem=e,e.model=t})),t.eachSeries((function(t){if(t.get("coordinateSystem")===wA){var n=t.getReferringComponents(xA,jo).models[0],i=t.coordinateSystem=n.coordinateSystem;i&&(ey(i.getRadiusAxis(),t,wA),ey(i.getAngleAxis(),t,wA))}})),i}},RA=["axisLine","axisLabel","axisTick","minorTick","splitLine","minorSplitLine","splitArea"];function FA(t,n,i){n[1]>n[0]&&(n=n.slice().reverse());var r=t.coordToPoint([n[0],i]),e=t.coordToPoint([n[1],i]);return{x1:r[0],y1:r[1],x2:e[0],y2:e[1]}}function PA(t){return t.getRadiusAxis().inverse?0:1}function BA(t){var n=t[0],i=t[t.length-1];n&&i&&Math.abs(Math.abs(n.coord-i.coord)-360)<1e-4&&t.pop()}var EA=function(t){function n(){var i=null!==t&&t.apply(this,arguments)||this;return i.type=n.type,i.axisPointerClass="PolarAxisPointer",i}return v(n,t),n.prototype.render=function(t){if(this.group.removeAll(),t.get("show")){var n=t.axis,i=n.polar,r=i.getRadiusAxis().getExtent(),e=n.getTicksCoords({breakTicks:"none"}),a=n.getMinorTicksCoords(),o=[];H(n.getViewLabels(),(function(t){t.tick.offInterval||((t=R(t)).coord=n.dataToCoord(dm(n.scale,t.tick)),o.push(t))})),BA(o),BA(e),H(RA,(function(u){!t.get([u,"show"])||n.scale.isBlank()&&"axisLine"!==u||WA[u](this.group,t,i,e,a,r,o)}),this)}},n.type="angleAxis",n}(bS),WA={axisLine:function(t,n,i,r,e,a){var o,u=n.getModel(["axisLine","lineStyle"]),s=i.getAngleAxis(),l=Math.PI/180,f=s.getExtent(),h=PA(i),c=h?0:1,v=360===Math.abs(f[1]-f[0])?"Circle":"Arc";(o=0===a[c]?new vf[v]({shape:{cx:i.cx,cy:i.cy,r:a[h],startAngle:-f[0]*l,endAngle:-f[1]*l,clockwise:s.inverse},style:u.getLineStyle(),z2:1,silent:!0}):new Zs({shape:{cx:i.cx,cy:i.cy,r:a[h],r0:a[c]},style:u.getLineStyle(),z2:1,silent:!0})).style.fill=null,t.add(o)},axisTick:function(t,n,i,r,e,a){var o=n.getModel("axisTick"),u=(o.get("inside")?-1:1)*o.get("length"),s=a[PA(i)],l=U(r,(function(t){return new el({shape:FA(i,[s,s+u],t.coord)})}));t.add(Hl(l,{style:B(o.getModel("lineStyle").getLineStyle(),{stroke:n.get(["axisLine","lineStyle","color"])})}))},minorTick:function(t,n,i,r,e,a){if(e.length){for(var o=n.getModel("axisTick"),u=n.getModel("minorTick"),s=(o.get("inside")?-1:1)*u.get("length"),l=a[PA(i)],f=[],h=0;h<e.length;h++)for(var c=0;c<e[h].length;c++)f.push(new el({shape:FA(i,[l,l+s],e[h][c].coord)}));t.add(Hl(f,{style:B(u.getModel("lineStyle").getLineStyle(),B(o.getLineStyle(),{stroke:n.get(["axisLine","lineStyle","color"])}))}))}},axisLabel:function(t,n,i,r,e,a,o){var u=n.getCategories(!0),s=n.getModel("axisLabel"),l=s.get("margin"),f=n.get("triggerEvent");H(o,(function(r,e){var o=s,h=r.tick.value,c=a[PA(i)],v=i.coordToPoint([c+l,r.coord]),d=i.cx,p=i.cy,m=Math.abs(v[0]-d)/c<.3?"center":v[0]>d?"left":"right",y=Math.abs(v[1]-p)/c<.3?"middle":v[1]>p?"top":"bottom";if(u&&u[h]){var g=u[h];tt(g)&&g.textStyle&&(o=new Wf(g.textStyle,s,s.ecModel))}var b=new Ia({silent:Dy.isLabelSilent(n),style:bf(o,{x:v[0],y:v[1],fill:o.getTextColor()||n.get(["axisLine","lineStyle","color"]),text:r.formattedLabel,align:m,verticalAlign:y})});if(t.add(b),nf({el:b,componentModel:n,itemName:r.formattedLabel,formatterParamsExtra:{isTruncated:function(){return b.isTruncated},value:r.rawLabel,tickIndex:e}}),f){var w=Dy.makeAxisEventDataBase(n);w.targetType="axisLabel",w.value=r.rawLabel,au(b).eventData=w}}),this)},splitLine:function(t,n,i,r,e,a){var o=n.getModel("splitLine").getModel("lineStyle"),u=o.get("color"),s=0;u=u instanceof Array?u:[u];for(var l=[],f=0;f<r.length;f++){var h=s++%u.length;l[h]=l[h]||[],l[h].push(new el({shape:FA(i,a,r[f].coord)}))}for(f=0;f<l.length;f++)t.add(Hl(l[f],{style:B({stroke:u[f%u.length]},o.getLineStyle()),silent:!0,z:n.get("z")}))},minorSplitLine:function(t,n,i,r,e,a){if(e.length){for(var o=n.getModel("minorSplitLine").getModel("lineStyle"),u=[],s=0;s<e.length;s++)for(var l=0;l<e[s].length;l++)u.push(new el({shape:FA(i,a,e[s][l].coord)}));t.add(Hl(u,{style:o.getLineStyle(),silent:!0,z:n.get("z")}))}},splitArea:function(t,n,i,r,e,a){if(r.length){var o=n.getModel("splitArea").getModel("areaStyle"),u=o.get("color"),s=0;u=u instanceof Array?u:[u];for(var l=[],f=Math.PI/180,h=-r[0].coord*f,c=Math.min(a[0],a[1]),v=Math.max(a[0],a[1]),d=n.get("clockwise"),p=1,m=r.length;p<=m;p++){var y=p===m?r[0].coord:r[p].coord,g=s++%u.length;l[g]=l[g]||[],l[g].push(new qs({shape:{cx:i.cx,cy:i.cy,r0:c,r:v,startAngle:h,endAngle:-y*f,clockwise:d},silent:!0})),h=-y*f}for(p=0;p<l.length;p++)t.add(Hl(l[p],{style:B({fill:u[p%u.length]},o.getAreaStyle()),silent:!0}))}}},jA=["splitLine","splitArea","minorSplitLine"],HA=function(t){function n(){var i=null!==t&&t.apply(this,arguments)||this;return i.type=n.type,i.axisPointerClass="PolarAxisPointer",i}return v(n,t),n.prototype.render=function(t,n,i){if(this.group.removeAll(),t.get("show")){var r=this._axisGroup,e=this._axisGroup=new Is;this.group.add(e);var a=t.axis,o=a.polar,u=o.getAngleAxis(),s=a.getTicksCoords(),l=a.getMinorTicksCoords(),f=u.getExtent()[0],h=a.getExtent(),c=function(t,n,i){return{position:[t.cx,t.cy],rotation:i/180*Math.PI,labelDirection:-1,tickDirection:-1,nameDirection:1,labelRotate:n.getModel("axisLabel").get("rotate"),z2:1}}(o,t,f),v=new Dy(t,i,c);v.build(),e.add(v.group),ql(r,e,t),H(jA,(function(n){t.get([n,"show"])&&!a.scale.isBlank()&&UA[n](this.group,t,o,f,h,s,l)}),this)}},n.type="radiusAxis",n}(bS),UA={splitLine:function(t,n,i,r,e,a){var o=n.getModel("splitLine").getModel("lineStyle"),u=o.get("color"),s=0,l=i.getAngleAxis(),f=Math.PI/180,h=l.getExtent(),c=360===Math.abs(h[1]-h[0])?"Circle":"Arc";u=u instanceof Array?u:[u];for(var v=[],d=0;d<a.length;d++){var p=s++%u.length;v[p]=v[p]||[],v[p].push(new vf[c]({shape:{cx:i.cx,cy:i.cy,r:Math.max(a[d].coord,0),startAngle:-h[0]*f,endAngle:-h[1]*f,clockwise:l.inverse}}))}for(d=0;d<v.length;d++)t.add(Hl(v[d],{style:B({stroke:u[d%u.length],fill:null},o.getLineStyle()),silent:!0}))},minorSplitLine:function(t,n,i,r,e,a,o){if(o.length){for(var u=n.getModel("minorSplitLine").getModel("lineStyle"),s=[],l=0;l<o.length;l++)for(var f=0;f<o[l].length;f++)s.push(new Ds({shape:{cx:i.cx,cy:i.cy,r:o[l][f].coord}}));t.add(Hl(s,{style:B({fill:null},u.getLineStyle()),silent:!0}))}},splitArea:function(t,n,i,r,e,a){if(a.length){var o=n.getModel("splitArea").getModel("areaStyle"),u=o.get("color"),s=0;u=u instanceof Array?u:[u];for(var l=[],f=a[0].coord,h=1;h<a.length;h++){var c=s++%u.length;l[c]=l[c]||[],l[c].push(new qs({shape:{cx:i.cx,cy:i.cy,r0:f,r:a[h].coord,startAngle:0,endAngle:2*Math.PI},silent:!0})),f=a[h].coord}for(h=0;h<l.length;h++)t.add(Hl(l[h],{style:B({fill:u[h%u.length]},o.getAreaStyle()),silent:!0}))}}},VA=Zo();function $A(t){return t.get("stack")||"__ec_stack_"+t.seriesIndex}var YA=ru(ug,(function(t){var n=ag(ug,wA);ty(t,n,(function(t){var i=function(t){var n=ag(ug,wA),i=uy(t,{fromStat:{key:n},min:1}).w,r=i,e=0,a="20%",o="30%",u={};Km(t,n,(function(t){var n=$A(t);u[n]||e++,u[n]=u[n]||{width:0,maxWidth:0};var s=no(t.get("barWidth"),i),l=no(t.get("barMaxWidth"),i),f=t.get("barGap"),h=t.get("barCategoryGap");s&&!u[n].width&&(s=Ua(r,s),u[n].width=s,r-=s),l&&(u[n].maxWidth=l),null!=f&&(o=f),null!=h&&(a=h)}));var s={},l=no(a,i),f=no(o,1),h=(r-l)/(e+(e-1)*f);h=Va(h,0),H(u,(function(t){var n=t.maxWidth;n&&n<h&&(n=Ua(n,r),t.width&&(n=Ua(n,t.width)),r-=n,t.width=n,e--)})),h=Va(h=(r-l)/(e+(e-1)*f),0);var c,v=0;H(u,(function(t){t.width||(t.width=h),c=t,v+=t.width*(1+f)})),c&&(v-=c.width*f);var d=-v/2;return H(u,(function(t,n){s[n]=s[n]||{offset:d,width:t.width},d+=t.width*(1+f)})),s}(t),r={};Km(t,n,(function(n){!function(t,n,i,r){var e=n.getData(),a=$A(n),o=i[a],u=o.offset,s=o.width,l=n.coordinateSystem,f=l.getOtherAxis(t),h=l.cx,c=l.cy,v=n.get("barMinHeight")||0,d=n.get("barMinAngle")||0;r[a]=r[a]||[];for(var p=e.mapDimension(f.dim),m=e.mapDimension(t.dim),y=dc(e,p),g="radius"!==t.dim||!n.get("roundCap",!0),b=f.dataToCoord(lg(f)),w=0,x=e.count();w<x;w++){var M=e.get(p,w),k=e.get(m,w),S=M>=0?"p":"n",A=b;y&&(r[a][k]||(r[a][k]={p:b,n:b}),A=r[a][k][S]);var T=void 0,N=void 0,C=void 0,O=void 0;if("radius"===f.dim){var I=f.dataToCoord(M)-b,L=t.dataToCoord(k);$a(I)<v&&(I=(I<0?-1:1)*v),T=A,N=A+I,O=(C=L-u)-s,y&&(r[a][k][S]=N)}else{var D=f.dataToCoord(M,g)-b,_=t.dataToCoord(k);$a(D)<d&&(D=(D<0?-1:1)*d),N=(T=_+u)+s,C=A,O=A+D,y&&(r[a][k][S]=O)}e.setItemLayout(w,{cx:h,cy:c,r0:T,r:N,startAngle:-C*Ka/180,endAngle:-O*Ka/180,clockwise:C>=O})}}(t,n,i,r)}))}))})),XA={startAngle:90,clockwise:!0,splitNumber:12,containShape:!1,axisLabel:{rotate:0}},qA={splitNumber:5},GA=function(t){function n(){var i=null!==t&&t.apply(this,arguments)||this;return i.type=n.type,i}return v(n,t),n.type="polar",n}(cx),ZA=function(t){function n(){var i=null!==t&&t.apply(this,arguments)||this;return i.type=n.type,i}return v(n,t),n.type="tooltip",n.dependencies=["axisPointer"],n.defaultOption={z:60,show:!0,showContent:!0,trigger:"item",triggerOn:"mousemove|click|mousewheel",alwaysShowContent:!1,renderMode:"auto",confine:null,showDelay:0,hideDelay:100,transitionDuration:.4,displayTransition:!0,enterable:!1,backgroundColor:Jv.color.neutral00,shadowBlur:10,shadowColor:"rgba(0, 0, 0, .2)",shadowOffsetX:1,shadowOffsetY:2,borderRadius:4,borderWidth:1,defaultBorderColor:Jv.color.border,padding:null,extraCssText:"",axisPointer:{type:"line",axis:"auto",animation:"auto",animationDurationUpdate:200,animationEasingUpdate:"exponentialOut",crossStyle:{color:Jv.color.borderShade,width:1,type:"dashed",textStyle:{}}},textStyle:{color:Jv.color.tertiary,fontSize:14}},n}(Lv);function JA(t){var n=t.get("confine");return null!=n?!!n:"richText"===t.get("renderMode")}function KA(t){if(At.domSupported)for(var n=document.documentElement.style,i=0,r=t.length;i<r;i++)if(t[i]in n)return t[i]}var QA=KA(["transform","webkitTransform","OTransform","MozTransform","msTransform"]);function tT(t,n){if(!t)return n;n=vv(n,!0);var i=t.indexOf(n);return(t=-1===i?n:"-"+t.slice(0,i)+"-"+n).toLowerCase()}var nT=tT(KA(["webkitTransition","transition","OTransition","MozTransition","msTransition"]),"transition"),iT=tT(QA,"transform"),rT="position:absolute;display:block;border-style:solid;white-space:nowrap;z-index:9999999;"+(At.transform3dSupported?"will-change:transform;":"");function eT(t,n,i){var r=t.toFixed(0)+"px",e=n.toFixed(0)+"px";if(!At.transformSupported)return i?"top:"+e+";left:"+r+";":[["top",e],["left",r]];var a=At.transform3dSupported,o="translate"+(a?"3d":"")+"("+r+","+e+(a?",0":"")+")";return i?"top:0;left:0;"+iT+":"+o+";":[["top",0],["left",0],[QA,o]]}function aT(t,n,i,r,e){var a=n&&n.painter;if(i){var o=a&&a.getViewportRoot();o&&function(t,n,i,r,e){kc(Mc,n,r,e,!0)&&kc(t,i,Mc[0],Mc[1])}(t,o,i,r,e)}else{t[0]=r,t[1]=e;var u=a&&a.getViewportRootOffset();u&&(t[0]+=u.offsetLeft,t[1]+=u.offsetTop)}t[2]=t[0]/n.getWidth(),t[3]=t[1]/n.getHeight()}var oT=function(){function t(t,n){if(this._show=!1,this._styleCoord=[0,0,0,0],this._enterable=!0,this._alwaysShowContent=!1,this._firstShow=!0,this._longHide=!0,At.wxa)return null;var i=document.createElement("div");i.domBelongToZr=!0,this.el=i;var r=this._zr=t.getZr(),e=n.appendTo,a=e&&(J(e)?document.querySelector(e):rt(e)?e:Z(e)&&e(t.getDom()));aT(this._styleCoord,r,a,t.getWidth()/2,t.getHeight()/2),(a||t.getDom()).appendChild(i),this._api=t,this._container=a;var o=this;i.onmouseenter=function(){o._enterable&&(clearTimeout(o._hideTimeout),o._show=!0),o._inContent=!0},i.onmousemove=function(t){if(t=t||window.event,!o._enterable){var n=r.handler;zb(r.painter.getViewportRoot(),t,!0),n.dispatch("mousemove",t)}},i.onmouseleave=function(){o._inContent=!1,o._enterable&&o._show&&o.hideLater(o._hideDelay)}}return t.prototype.update=function(t){if(!this._container){var n=this._api.getDom(),i=(a=(e=n).currentStyle||document.defaultView&&document.defaultView.getComputedStyle(e))?a.position:null,r=n.style;"absolute"!==r.position&&"absolute"!==i&&(r.position="relative")}var e,a,o=t.get("alwaysShowContent");o&&this._moveIfResized(),this._alwaysShowContent=o,this._enableDisplayTransition=t.get("displayTransition")&&t.get("transitionDuration")>0,this.el.className=t.get("className")||""},t.prototype.show=function(t,n){clearTimeout(this._hideTimeout),clearTimeout(this._longHideTimeout);var i=this.el,r=i.style,e=this._styleCoord;i.innerHTML?r.cssText=rT+function(t,n,i,r){var e=[],a=t.get("transitionDuration"),o=t.get("backgroundColor"),u=t.get("shadowBlur"),s=t.get("shadowColor"),l=t.get("shadowOffsetX"),f=t.get("shadowOffsetY"),h=t.getModel("textStyle"),c=dd(t,"html");return e.push("box-shadow:"+l+"px "+f+"px "+u+"px "+s),n&&a>0&&e.push(function(t,n,i){var r="cubic-bezier(0.23,1,0.32,1)",e="",a="";return i&&(a="opacity"+(e=" "+t/2+"s "+r)+",visibility"+e),n||(e=" "+t+"s "+r,a+=(a.length?",":"")+(At.transformSupported?""+iT+e:",left"+e+",top"+e)),nT+":"+a}(a,i,r)),o&&e.push("background-color:"+o),H(["width","color","radius"],(function(n){var i="border-"+n,r=vv(i),a=t.get(r);null!=a&&e.push(i+":"+a+("color"===n?"":"px"))})),e.push(function(t){var n=[],i=t.get("fontSize"),r=t.getTextColor();r&&n.push("color:"+r),n.push("font:"+t.getFont());var e=ut(t.get("lineHeight"),Math.round(3*i/2));i&&n.push("line-height:"+e+"px");var a=t.get("textShadowColor"),o=t.get("textShadowBlur")||0,u=t.get("textShadowOffsetX")||0,s=t.get("textShadowOffsetY")||0;return a&&o&&n.push("text-shadow:"+u+"px "+s+"px "+o+"px "+a),H(["decoration","align"],(function(i){var r=t.get(i);r&&n.push("text-"+i+":"+r)})),n.join(";")}(h)),null!=c&&e.push("padding:"+dv(c).join("px ")+"px"),e.join(";")+";"}(t,!this._firstShow,this._longHide,this._enableDisplayTransition)+eT(e[0],e[1],!0)+"border-color:"+bv(n)+";"+(t.get("extraCssText")||"")+";pointer-events:"+(this._enterable?"auto":"none"):r.display="none",this._show=!0,this._firstShow=!1,this._longHide=!1},t.prototype.setContent=function(t,n,i,r,e){var a=this.el;if(null!=t){var o="";if(J(e)&&"item"===i.get("trigger")&&!JA(i)&&(o=function(t,n,i){if(!J(i)||"inside"===i)return"";var r=t.get("backgroundColor"),e=t.get("borderWidth");n=bv(n);var a,o,u="left"===(a=i)?"right":"right"===a?"left":"top"===a?"bottom":"top",s=Math.max(1.5*Math.round(e),6),l="",f=iT+":";E(["left","right"],u)>-1?(l+="top:50%",f+="translateY(-50%) rotate("+(o="left"===u?-225:-45)+"deg)"):(l+="left:50%",f+="translateX(-50%) rotate("+(o="top"===u?225:45)+"deg)");var h=o*Math.PI/180,c=s+e,v=c*Math.abs(Math.cos(h))+c*Math.abs(Math.sin(h)),d=n+" solid "+e+"px;";return'<div style="'+["position:absolute;width:"+s+"px;height:"+s+"px;z-index:-1;",(l+=";"+u+":-"+Math.round(100*((v-Math.SQRT2*e)/2+Math.SQRT2*e-(v-c)/2))/100+"px")+";"+f+";","border-bottom:"+d,"border-right:"+d,"background-color:"+r+";"].join("")+'"></div>'}(i,r,e)),J(t))a.innerHTML=t+o;else if(t){a.innerHTML="",G(t)||(t=[t]);for(var u=0;u<t.length;u++)rt(t[u])&&t[u].parentNode!==a&&a.appendChild(t[u]);if(o&&a.childNodes.length){var s=document.createElement("div");s.innerHTML=o,a.appendChild(s)}}}else a.innerHTML=""},t.prototype.setEnterable=function(t){this._enterable=t},t.prototype.getSize=function(){var t=this.el;return t?[t.offsetWidth,t.offsetHeight]:[0,0]},t.prototype.moveTo=function(t,n){if(this.el){var i=this._styleCoord;if(aT(i,this._zr,this._container,t,n),null!=i[0]&&null!=i[1]){var r=this.el.style;H(eT(i[0],i[1]),(function(t){r[t[0]]=t[1]}))}}},t.prototype._moveIfResized=function(){var t=this._styleCoord[3];this.moveTo(this._styleCoord[2]*this._zr.getWidth(),t*this._zr.getHeight())},t.prototype.hide=function(){var t=this,n=this.el.style;this._enableDisplayTransition?(n.visibility="hidden",n.opacity="0"):n.display="none",At.transform3dSupported&&(n.willChange=""),this._show=!1,this._longHideTimeout=setTimeout((function(){return t._longHide=!0}),500)},t.prototype.hideLater=function(t){!this._show||this._inContent&&this._enterable||this._alwaysShowContent||(t?(this._hideDelay=t,this._show=!1,this._hideTimeout=setTimeout(X(this.hide,this),t)):this.hide())},t.prototype.isShow=function(){return this._show},t.prototype.dispose=function(){clearTimeout(this._hideTimeout),clearTimeout(this._longHideTimeout);var t=this._zr;!function(t,n){function i(t){var n=t[xc];n&&(n.clearMarkers&&n.clearMarkers(),delete t[xc])}t&&i(t),n&&i(n)}(t&&t.painter&&t.painter.getViewportRoot(),this._container);var n=this.el;if(n){n.onmouseenter=n.onmousemove=n.onmouseleave=null;var i=n.parentNode;i&&i.removeChild(n)}this.el=this._container=null},t}(),uT=function(){function t(t){this._show=!1,this._styleCoord=[0,0,0,0],this._alwaysShowContent=!1,this._enterable=!0,this._zr=t.getZr(),fT(this._styleCoord,this._zr,t.getWidth()/2,t.getHeight()/2)}return t.prototype.update=function(t){var n=t.get("alwaysShowContent");n&&this._moveIfResized(),this._alwaysShowContent=n},t.prototype.show=function(){this._hideTimeout&&clearTimeout(this._hideTimeout),this.el.show(),this._show=!0},t.prototype.setContent=function(t,n,i,r){var e=this;tt(t)&&ko(""),this.el&&this._zr.remove(this.el);var a=i.getModel("textStyle");this.el=new Ia({style:{rich:n.richTextStyles,text:t,lineHeight:22,borderWidth:1,borderColor:r,textShadowColor:a.get("textShadowColor"),fill:i.get(["textStyle","color"]),padding:dd(i,"richText"),verticalAlign:"top",align:"left"},z:i.get("z")}),H(["backgroundColor","borderRadius","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"],(function(t){e.el.style[t]=i.get(t)})),H(["textShadowBlur","textShadowOffsetX","textShadowOffsetY"],(function(t){e.el.style[t]=a.get(t)||0})),this._zr.add(this.el);var o=this;this.el.on("mouseover",(function(){o._enterable&&(clearTimeout(o._hideTimeout),o._show=!0),o._inContent=!0})),this.el.on("mouseout",(function(){o._enterable&&o._show&&o.hideLater(o._hideDelay),o._inContent=!1}))},t.prototype.setEnterable=function(t){this._enterable=t},t.prototype.getSize=function(){var t=this.el,n=this.el.getBoundingRect(),i=lT(t.style);return[n.width+i.left+i.right,n.height+i.top+i.bottom]},t.prototype.moveTo=function(t,n){var i=this.el;if(i){var r=this._styleCoord;fT(r,this._zr,t,n),t=r[0],n=r[1];var e=i.style,a=sT(e.borderWidth||0),o=lT(e);i.x=t+a+o.left,i.y=n+a+o.top,i.markRedraw()}},t.prototype._moveIfResized=function(){var t=this._styleCoord[3];this.moveTo(this._styleCoord[2]*this._zr.getWidth(),t*this._zr.getHeight())},t.prototype.hide=function(){this.el&&this.el.hide(),this._show=!1},t.prototype.hideLater=function(t){!this._show||this._inContent&&this._enterable||this._alwaysShowContent||(t?(this._hideDelay=t,this._show=!1,this._hideTimeout=setTimeout(X(this.hide,this),t)):this.hide())},t.prototype.isShow=function(){return this._show},t.prototype.dispose=function(){this._zr.remove(this.el)},t}();function sT(t){return Math.max(0,t)}function lT(t){var n=sT(t.shadowBlur||0),i=sT(t.shadowOffsetX||0),r=sT(t.shadowOffsetY||0);return{left:sT(n-i),right:sT(n+i),top:sT(n-r),bottom:sT(n+r)}}function fT(t,n,i,r){t[0]=i,t[1]=r,t[2]=t[0]/n.getWidth(),t[3]=t[1]/n.getHeight()}var hT=new Ta({shape:{x:-1,y:-1,width:2,height:2}}),cT=function(t){function n(){var i=null!==t&&t.apply(this,arguments)||this;return i.type=n.type,i}return v(n,t),n.prototype.init=function(t,n){if(!At.node&&n.getDom()){var i,r=t.getComponent("tooltip"),e=this._renderMode="auto"===(i=r.get("renderMode"))?At.domSupported?"html":"richText":i||"html";this._tooltipContent="richText"===e?new uT(n):new oT(n,{appendTo:r.get("appendToBody",!0)?"body":r.get("appendTo",!0)})}},n.prototype.render=function(t,n,i){if(!At.node&&i.getDom()){this.group.removeAll(),this._tooltipModel=t,this._ecModel=n,this._api=i;var r=this._tooltipContent;r.update(t),r.setEnterable(t.get("enterable")),this._initGlobalListener(),this._keepShow(),"richText"!==this._renderMode&&t.get("transitionDuration")?kg(this,"_updatePosition",50,"fixRate"):Sg(this,"_updatePosition")}},n.prototype._initGlobalListener=function(){var t=this._tooltipModel.get("triggerOn");eA("itemTooltip",this._api,X((function(n,i,r){"none"!==t&&(t.indexOf(n)>=0?this._tryShow(i,r):"leave"===n&&this._hide(r))}),this))},n.prototype._keepShow=function(){var t=this._tooltipModel,n=this._ecModel,i=this._api,r=t.get("triggerOn");if("axis"!==t.get("trigger")&&(this._lastDataByCoordSys=null,this._cbParamsList=null),null!=this._lastX&&null!=this._lastY&&"none"!==r&&"click"!==r){var e=this;clearTimeout(this._refreshUpdateTimeout),this._refreshUpdateTimeout=setTimeout((function(){!i.isDisposed()&&e.manuallyShowTip(t,n,i,{x:e._lastX,y:e._lastY,dataByCoordSys:e._lastDataByCoordSys})}))}},n.prototype.manuallyShowTip=function(t,n,i,r){if(r.from!==this.uid&&!At.node&&i.getDom()){var e=dT(r,i);this._ticket="";var a=r.dataByCoordSys,o=function(t,n,i){var r=Wo(t).queryOptionMap,e=r.keys()[0];if(e&&"series"!==e){var a,o=Ho(n,e,r.get(e),{useDefault:!1,enableAll:!1,enableNone:!1}).models[0];if(o)return i.getViewOfComponentModel(o).group.traverse((function(n){var i=au(n).tooltipConfig;if(i&&i.name===t.name)return a=n,!0})),a?{componentMainType:e,componentIndex:o.componentIndex,el:a}:void 0}}(r,n,i);if(o){var u=o.el.getBoundingRect().clone();u.applyTransform(o.el.transform),this._tryShow({offsetX:u.x+u.width/2,offsetY:u.y+u.height/2,target:o.el,position:r.position,positionDefault:"bottom"},e)}else if(r.tooltip&&null!=r.x&&null!=r.y){var s=hT;s.x=r.x,s.y=r.y,s.update(),au(s).tooltipConfig={name:null,option:r.tooltip},this._tryShow({offsetX:r.x,offsetY:r.y,target:s},e)}else if(a)this._tryShow({offsetX:r.x,offsetY:r.y,position:r.position,dataByCoordSys:a,tooltipOption:r.tooltipOption},e);else if(null!=r.seriesIndex){if(this._manuallyAxisShowTip(t,n,i,r))return;var l=lA(r,n),f=l.point[0],h=l.point[1];null!=f&&null!=h&&this._tryShow({offsetX:f,offsetY:h,target:l.el,position:r.position,positionDefault:"bottom"},e)}else null!=r.x&&null!=r.y&&(i.dispatchAction({type:"updateAxisPointer",x:r.x,y:r.y}),this._tryShow({offsetX:r.x,offsetY:r.y,position:r.position,target:i.getZr().findHover(r.x,r.y).target},e))}},n.prototype.manuallyHideTip=function(t,n,i,r){this._tooltipModel&&this._tooltipContent.hideLater(this._tooltipModel.get("hideDelay")),this._lastX=this._lastY=this._lastDataByCoordSys=null,this._cbParamsList=null,r.from!==this.uid&&this._hide(dT(r,i))},n.prototype._manuallyAxisShowTip=function(t,n,i,r){var e=r.seriesIndex,a=r.dataIndex,o=n.getComponent("axisPointer").coordSysAxesInfo;if(null!=e&&null!=a&&null!=o){var u=n.getSeriesByIndex(e);if(u&&"axis"===vT([u.getData().getItemModel(a),u,(u.coordinateSystem||{}).model],this._tooltipModel).get("trigger"))return i.dispatchAction({type:"updateAxisPointer",seriesIndex:e,dataIndex:a,position:r.position}),!0}},n.prototype._tryShow=function(t,n){var i=t.target;if(this._tooltipModel){this._lastX=t.offsetX,this._lastY=t.offsetY;var r=t.dataByCoordSys;if(r&&r.length)this._showAxisTooltip(r,t);else if(i){var e,a;if("legend"===au(i).ssrType)return;this._lastDataByCoordSys=null,this._cbParamsList=null,Zx(i,(function(t){if(t.tooltipDisabled)return e=a=null,!0;e||a||(null!=au(t).dataIndex?e=t:null!=au(t).tooltipConfig&&(a=t))}),!0),e?this._showSeriesItemTooltip(t,e,n):a?this._showComponentItemTooltip(t,a,n):this._hide(n)}else this._lastDataByCoordSys=null,this._cbParamsList=null,this._hide(n)}},n.prototype._showOrMove=function(t,n){var i=t.get("showDelay");n=X(n,this),clearTimeout(this._showTimout),i>0?this._showTimout=setTimeout(n,i):n()},n.prototype._showAxisTooltip=function(t,n){var i=this._ecModel,r=this._tooltipModel,e=[n.offsetX,n.offsetY],a=vT([n.tooltipOption],r),o=this._renderMode,u=[],s=ad("section",{blocks:[],noHeader:!0}),l=[],f=new pd;H(t,(function(t){H(t.dataByAxis,(function(t){var n=i.getComponent(t.axisDim+"Axis",t.axisIndex),e=t.value,a=n.axis,h=a.scale.parse(e);if(n&&null!=e){var c=$S(e,a,i,t.seriesDataIndices,t.valueLabelOpt),v=ad("section",{header:c,noHeader:!ct(c),sortBlocks:!0,blocks:[]});s.blocks.push(v),H(t.seriesDataIndices,(function(e){var a=i.getSeriesByIndex(e.seriesIndex),s=e.dataIndexInside,d=a.getDataParams(s);if(!(d.dataIndex<0)){d.axisDim=t.axisDim,d.axisIndex=t.axisIndex,d.axisType=t.axisType,d.axisId=t.axisId,d.axisValue=lm(n.axis,{value:h}),d.axisValueLabel=c,d.marker=f.makeTooltipMarker("item",bv(d.color),o);var p=Fv(a.formatTooltip(s,!0,null)),m=p.frag;if(m){var y=vT([a],r).get("valueFormatter");v.blocks.push(y?P({valueFormatter:y},m):m)}p.text&&l.push(p.text),u.push(d)}}))}}))})),s.blocks.reverse(),l.reverse();var h=n.position,c=a.get("order"),v=hd(s,f,o,c,i.get("useUTC"),a.get("textStyle"));v&&l.unshift(v);var d=l.join("richText"===o?"\n\n":"<br/>");this._showOrMove(a,(function(){this._updateContentNotChangedOnAxis(t,u)?this._updatePosition(a,h,e[0],e[1],this._tooltipContent,u):this._showTooltipContent(a,d,u,Math.random()+"",e[0],e[1],h,null,f)}))},n.prototype._showSeriesItemTooltip=function(t,n,i){var r=this._ecModel,e=au(n),a=e.seriesIndex,o=r.getSeriesByIndex(a),u=e.dataModel||o,s=e.dataIndex,l=e.dataType,f=u.getData(l),h=this._renderMode,c=t.positionDefault,v=vT([f.getItemModel(s),u,o&&(o.coordinateSystem||{}).model],this._tooltipModel,c?{position:c}:null),d=v.get("trigger");if(null==d||"item"===d){var p=u.getDataParams(s,l),m=new pd;p.marker=m.makeTooltipMarker("item",bv(p.color),h);var y=Fv(u.formatTooltip(s,!1,l)),g=v.get("order"),b=v.get("valueFormatter"),w=y.frag,x=w?hd(b?P({valueFormatter:b},w):w,m,h,g,r.get("useUTC"),v.get("textStyle")):y.text,M="item_"+u.name+"_"+s;this._showOrMove(v,(function(){this._showTooltipContent(v,x,p,M,t.offsetX,t.offsetY,t.position,t.target,m)})),i({type:"showTip",dataIndexInside:s,dataIndex:f.getRawIndex(s),seriesIndex:a,from:this.uid})}},n.prototype._showComponentItemTooltip=function(t,n,i){var r="html"===this._renderMode,e=au(n),a=e.tooltipConfig.option||{},o=a.encodeHTMLContent;J(a)&&(a={content:a,formatter:a},o=!0),o&&r&&a.content&&((a=R(a)).content=Nc(a.content));var u=[a],s=this._ecModel.getComponent(e.componentMainType,e.componentIndex);s&&u.push(s),u.push({formatter:a.content});var l=t.positionDefault,f=vT(u,this._tooltipModel,l?{position:l}:null),h=f.get("content"),c=Math.random()+"",v=new pd;this._showOrMove(f,(function(){var i=R(f.get("formatterParams")||{});this._showTooltipContent(f,h,i,c,t.offsetX,t.offsetY,t.position,n,v)})),i({type:"showTip",from:this.uid})},n.prototype._showTooltipContent=function(t,n,i,r,e,a,o,u,s){if(this._ticket="",t.get("showContent")&&t.get("show")){var l=this._tooltipContent;l.setEnterable(t.get("enterable"));var f=t.get("formatter");o=o||t.get("position");var h=n,c=this._getNearestPoint([e,a],i,t.get("trigger"),t.get("borderColor"),t.get("defaultBorderColor",!0)).color;if(f)if(J(f)){var v=t.ecModel.get("useUTC"),d=G(i)?i[0]:i;h=f,d&&d.axisType&&d.axisType.indexOf("time")>=0&&(h=Gc(d.axisValue,h,v)),h=gv(h,i,!0)}else if(Z(f)){var p=X((function(n,r){n===this._ticket&&(l.setContent(r,s,t,c,o),this._updatePosition(t,o,e,a,l,i,u))}),this);this._ticket=r,h=f(i,r,p)}else h=f;l.setContent(h,s,t,c,o),l.show(t,c),this._updatePosition(t,o,e,a,l,i,u)}},n.prototype._getNearestPoint=function(t,n,i,r,e){return"axis"===i||G(n)?{color:r||e}:G(n)?void 0:{color:r||n.color||n.borderColor}},n.prototype._updatePosition=function(t,n,i,r,e,a,o){var u=this._api.getWidth(),s=this._api.getHeight();n=n||t.get("position");var l=e.getSize(),f=t.get("align"),h=t.get("verticalAlign"),c=o&&o.getBoundingRect().clone();if(o&&c.applyTransform(o.transform),Z(n)&&(n=n([i,r],a,e.el,c,{viewSize:[u,s],contentSize:l.slice()})),G(n))i=no(n[0],u),r=no(n[1],s);else if(tt(n)){var v=n;v.width=l[0],v.height=l[1];var d=Sv(v,{width:u,height:s});i=d.x,r=d.y,f=null,h=null}else if(J(n)&&o){var p=function(t,n,i,r){var e=i[0],a=i[1],o=Math.ceil(Math.SQRT2*r)+8,u=0,s=0,l=n.width,f=n.height;switch(t){case"inside":u=n.x+l/2-e/2,s=n.y+f/2-a/2;break;case"top":u=n.x+l/2-e/2,s=n.y-a-o;break;case"bottom":u=n.x+l/2-e/2,s=n.y+f+o;break;case"left":u=n.x-e-o,s=n.y+f/2-a/2;break;case"right":u=n.x+l+o,s=n.y+f/2-a/2}return[u,s]}(n,c,l,t.get("borderWidth"));i=p[0],r=p[1]}else p=function(t,n,i,r,e,a,o){var u=i.getSize(),s=u[0],l=u[1];return null!=a&&(t+s+a+2>r?t-=s+a:t+=a),null!=o&&(n+l+o>e?n-=l+o:n+=o),[t,n]}(i,r,e,u,s,f?null:20,h?null:20),i=p[0],r=p[1];f&&(i-=pT(f)?l[0]/2:"right"===f?l[0]:0),h&&(r-=pT(h)?l[1]/2:"bottom"===h?l[1]:0),JA(t)&&(p=function(t,n,i,r,e){var a=i.getSize(),o=a[0],u=a[1];return t=Math.min(t+o,r)-o,n=Math.min(n+u,e)-u,[t=Math.max(t,0),n=Math.max(n,0)]}(i,r,e,u,s),i=p[0],r=p[1]),e.moveTo(i,r)},n.prototype._updateContentNotChangedOnAxis=function(t,n){var i=this._lastDataByCoordSys,r=this._cbParamsList,e=!!i&&i.length===t.length;return e&&H(i,(function(i,a){var o=i.dataByAxis||[],u=(t[a]||{}).dataByAxis||[];(e=e&&o.length===u.length)&&H(o,(function(t,i){var a=u[i]||{},o=t.seriesDataIndices||[],s=a.seriesDataIndices||[];(e=e&&t.value===a.value&&t.axisType===a.axisType&&t.axisId===a.axisId&&o.length===s.length)&&H(o,(function(t,n){var i=s[n];e=e&&t.seriesIndex===i.seriesIndex&&t.dataIndex===i.dataIndex})),r&&H(t.seriesDataIndices,(function(t){var i=t.seriesIndex,a=n[i],o=r[i];a&&o&&o.data!==a.data&&(e=!1)}))}))})),this._lastDataByCoordSys=t,this._cbParamsList=n,!!e},n.prototype._hide=function(t){this._lastDataByCoordSys=null,this._cbParamsList=null,t({type:"hideTip",from:this.uid})},n.prototype.dispose=function(t,n){!At.node&&n.getDom()&&(Sg(this,"_updatePosition"),this._tooltipContent.dispose(),uA("itemTooltip",n),this._tooltipContent=null,this._tooltipModel=null,this._lastDataByCoordSys=null,this._cbParamsList=null)},n.type="tooltip",n}(cx);function vT(t,n,i){var r,e=n.ecModel;i?(r=new Wf(i,e,e),r=new Wf(n.option,r,e)):r=n;for(var a=t.length-1;a>=0;a--){var o=t[a];o&&(o instanceof Wf&&(o=o.get("tooltip",!0)),J(o)&&(o={formatter:o}),o&&(r=new Wf(o,r,e)))}return r}function dT(t,n){return t.dispatchAction||X(n.dispatchAction,n)}function pT(t){return"center"===t||"middle"===t}var mT=Math.sin,yT=Math.cos,gT=Math.PI,bT=2*Math.PI,wT=180/gT,xT=function(){function t(){}return t.prototype.reset=function(t){this._start=!0,this._d=[],this._str="",this._p=Math.pow(10,t||4)},t.prototype.moveTo=function(t,n){this._add("M",t,n)},t.prototype.lineTo=function(t,n){this._add("L",t,n)},t.prototype.bezierCurveTo=function(t,n,i,r,e,a){this._add("C",t,n,i,r,e,a)},t.prototype.quadraticCurveTo=function(t,n,i,r){this._add("Q",t,n,i,r)},t.prototype.arc=function(t,n,i,r,e,a){this.ellipse(t,n,i,i,0,r,e,a)},t.prototype.ellipse=function(t,n,i,r,e,a,o,u){var s,l=o-a,f=!u,h=Math.abs(l),c=mr(h-bT)||(f?l>=bT:-l>=bT),v=l>0?l%bT:l%bT+bT;s=!!c||!mr(h)&&v>=gT==!!f;var d=t+i*yT(a),p=n+r*mT(a);this._start&&this._add("M",d,p);var m=Math.round(e*wT);if(c){var y=1/this._p,g=(f?1:-1)*(bT-y);this._add("A",i,r,m,1,+f,t+i*yT(a+g),n+r*mT(a+g)),y>.01&&this._add("A",i,r,m,0,+f,d,p)}else{var b=t+i*yT(o),w=n+r*mT(o);this._add("A",i,r,m,+s,+f,b,w)}},t.prototype.rect=function(t,n,i,r){this._add("M",t,n),this._add("l",i,0),this._add("l",0,r),this._add("l",-i,0),this._add("Z")},t.prototype.closePath=function(){this._d.length>0&&this._add("Z")},t.prototype._add=function(t,n,i,r,e,a,o,u,s){for(var l=[],f=this._p,h=1;h<arguments.length;h++){var c=arguments[h];if(isNaN(c))return void(this._invalid=!0);l.push(Math.round(c*f)/f)}this._d.push(t+l.join(" ")),this._start="Z"===t},t.prototype.generateStr=function(){this._str=this._invalid?"":this._d.join(""),this._d=[]},t.prototype.getStr=function(){return this._str},t}(),MT="none",kT=Math.round,ST=["lineCap","miterLimit","lineJoin"],AT=U(ST,(function(t){return"stroke-"+t.toLowerCase()}));var TT="http://www.w3.org/2000/svg",NT="http://www.w3.org/1999/xlink",CT="ecmeta_";function OT(t){return document.createElementNS(TT,t)}function IT(t,n,i,r,e){return{tag:t,attrs:i||{},children:r,text:e,key:n}}function LT(t,n){var i=(n=n||{}).newline?"\n":"";return function t(n){var r=n.children,e=n.tag,a=n.text;return function(t,n){var i=[];if(n)for(var r in n){var e=n[r],a=r;!1!==e&&(!0!==e&&null!=e&&(a+='="'+e+'"'),i.push(a))}return"<"+t+" "+i.join(" ")+">"}(e,n.attrs)+("style"!==e?Nc(a):a||"")+(r?""+i+U(r,(function(n){return t(n)})).join(i)+i:"")+"</"+e+">"}(t)}function DT(t){return{zrId:t,shadowCache:{},patternCache:{},gradientCache:{},clipPathCache:{},defs:{},cssNodes:{},cssAnims:{},cssStyleCache:{},cssAnimIdx:0,shadowIdx:0,gradientIdx:0,patternIdx:0,clipPathIdx:0}}function _T(t,n,i,r){return IT("svg","root",{width:t,height:n,xmlns:TT,"xmlns:xlink":NT,version:"1.1",baseProfile:"full",viewBox:!!r&&"0 0 "+t+" "+n},i)}var zT=0;function RT(){return zT++}var FT={cubicIn:"0.32,0,0.67,0",cubicOut:"0.33,1,0.68,1",cubicInOut:"0.65,0,0.35,1",quadraticIn:"0.11,0,0.5,0",quadraticOut:"0.5,1,0.89,1",quadraticInOut:"0.45,0,0.55,1",quarticIn:"0.5,0,0.75,0",quarticOut:"0.25,1,0.5,1",quarticInOut:"0.76,0,0.24,1",quinticIn:"0.64,0,0.78,0",quinticOut:"0.22,1,0.36,1",quinticInOut:"0.83,0,0.17,1",sinusoidalIn:"0.12,0,0.39,0",sinusoidalOut:"0.61,1,0.88,1",sinusoidalInOut:"0.37,0,0.63,1",exponentialIn:"0.7,0,0.84,0",exponentialOut:"0.16,1,0.3,1",exponentialInOut:"0.87,0,0.13,1",circularIn:"0.55,0,1,0.45",circularOut:"0,0.55,0.45,1",circularInOut:"0.85,0,0.15,1"},PT="transform-origin";function BT(t,n,i){var r=P({},t.shape);P(r,n),t.buildPath(i,r);var e=new xT;return e.reset(Tr(t)),i.rebuildPath(e,1),e.generateStr(),e.getStr()}function ET(t,n){var i=n.originX,r=n.originY;(i||r)&&(t[PT]=i+"px "+r+"px")}var WT={fill:"fill",opacity:"opacity",lineWidth:"stroke-width",lineDashOffset:"stroke-dashoffset"};function jT(t,n){var i=n.zrId+"-ani-"+n.cssAnimIdx++;return n.cssAnims[i]=t,i}function HT(t){return J(t)?FT[t]?"cubic-bezier("+FT[t]+")":Yi(t)?t:"":""}function UT(t,n,i,r){var e=t.animators,a=e.length,o=[];if(t instanceof hl){var u=function(t,n,i){var r,e,a={};if(H(t.shape.paths,(function(t){var n=DT(i.zrId);n.animation=!0,UT(t,{},n,!0);var o=n.cssAnims,u=n.cssNodes,s=Y(o),l=s.length;if(l){var f=o[e=s[l-1]];for(var h in f){var c=f[h];a[h]=a[h]||{d:""},a[h].d+=c.d||""}for(var v in u){var d=u[v].animation;d.indexOf(e)>=0&&(r=d)}}})),r){n.d=!1;var o=jT(a,i);return r.replace(e,o)}}(t,n,i);if(u)o.push(u);else if(!a)return}else if(!a)return;for(var s={},l=0;l<a;l++){var f=e[l],h=[f.getMaxTime()/1e3+"s"],c=HT(f.getClip().easing),v=f.getDelay();h.push(c||"linear"),v&&h.push(v/1e3+"s"),f.getLoop()&&h.push("infinite");var d=h.join(" ");s[d]=s[d]||[d,[]],s[d][1].push(f)}function p(e){var a,o=e[1],u=o.length,s={},l={},f={},h="animation-timing-function";function c(t,n,i){for(var r=t.getTracks(),e=t.getMaxTime(),a=0;a<r.length;a++){var o=r[a];if(o.needsAnimate()){var u=o.keyframes,s=o.propName;if(i&&(s=i(s)),s)for(var l=0;l<u.length;l++){var f=u[l],c=Math.round(f.time/e*100)+"%",v=HT(f.easing),d=f.rawValue;(J(d)||Q(d))&&(n[c]=n[c]||{},n[c][s]=f.rawValue,v&&(n[c][h]=v))}}}}for(var v=0;v<u;v++)(k=(M=o[v]).targetName)?"shape"===k&&c(M,l):!r&&c(M,s);for(var d in s){var p={};Mi(p,t),P(p,s[d]);var m=Nr(p),y=s[d][h];f[d]=m?{transform:m}:{},ET(f[d],p),y&&(f[d][h]=y)}var g=!0;for(var d in l){f[d]=f[d]||{};var b=!a;y=l[d][h],b&&(a=new qe);var w=a.len();a.reset(),f[d].d=BT(t,l[d],a);var x=a.len();if(!b&&w!==x){g=!1;break}y&&(f[d][h]=y)}if(!g)for(var d in f)delete f[d].d;if(!r)for(v=0;v<u;v++){var M,k;"style"===(k=(M=o[v]).targetName)&&c(M,f,(function(t){return WT[t]}))}var S,A=Y(f),T=!0;for(v=1;v<A.length;v++){var N=A[v-1];if(f[N][PT]!==f[A[v]][PT]){T=!1;break}S=f[N][PT]}if(T&&S){for(var d in f)f[d][PT]&&delete f[d][PT];n[PT]=S}if($(A,(function(t){return Y(f[t]).length>0})).length)return jT(f,i)+" "+e[0]+" both"}for(var m in s)(u=p(s[m]))&&o.push(u);if(o.length){var y=i.zrId+"-cls-"+RT();i.cssNodes["."+y]={animation:o.join(",")},n.class=y}}function VT(t,n,i){var r=JSON.stringify(t),e=i.cssStyleCache[r];e||(e=i.zrId+"-cls-"+RT(),i.cssStyleCache[r]=e,i.cssNodes["."+e+":hover"]=t),n.class=n.class?n.class+" "+e:e}var $T=Math.round;function YT(t){return t&&J(t.src)}function XT(t){return t&&Z(t.toDataURL)}function qT(t,n,i,r){(function(t,n,i,r){var e=null==n.opacity?1:n.opacity;if(i instanceof ba)t("opacity",e);else{if(function(t){var n=t.fill;return null!=n&&n!==MT}(n)){var a=pr(n.fill);t("fill",a.color);var o=null!=n.fillOpacity?n.fillOpacity*a.opacity*e:a.opacity*e;o<1&&t("fill-opacity",o)}else t("fill",MT);if(function(t){var n=t.stroke;return null!=n&&n!==MT}(n)){var u=pr(n.stroke);t("stroke",u.color);var s=n.strokeNoScale?i.getLineScale():1,l=s?(n.lineWidth||0)/s:0,f=null!=n.strokeOpacity?n.strokeOpacity*u.opacity*e:u.opacity*e,h=n.strokeFirst;if(1!==l&&t("stroke-width",l),h&&t("paint-order",h?"stroke":"fill"),f<1&&t("stroke-opacity",f),n.lineDash){var c=oM(i),v=c[0],d=c[1];v&&(d=kT(d||0),t("stroke-dasharray",v.join(",")),(d||r)&&t("stroke-dashoffset",d))}for(var p=0;p<ST.length;p++){var m=ST[p];if(n[m]!==ha[m]){var y=n[m]||ha[m];y&&t(AT[p],y)}}}}})((function(e,a){var o="fill"===e||"stroke"===e;o&&Sr(a)?aN(n,t,e,r):o&&xr(a)?oN(i,t,e,r):t[e]=a,o&&r.ssr&&"none"===a&&(t["pointer-events"]="visible")}),n,i,!1),function(t,n,i){var r=t.style;if(function(t){return t&&(t.shadowBlur||t.shadowOffsetX||t.shadowOffsetY)}(r)){var e=function(t){var n=t.style,i=t.getGlobalScale();return[n.shadowColor,(n.shadowBlur||0).toFixed(2),(n.shadowOffsetX||0).toFixed(2),(n.shadowOffsetY||0).toFixed(2),i[0],i[1]].join(",")}(t),a=i.shadowCache,o=a[e];if(!o){var u=t.getGlobalScale(),s=u[0],l=u[1];if(!s||!l)return;var f=r.shadowOffsetX||0,h=r.shadowOffsetY||0,c=r.shadowBlur,v=pr(r.shadowColor),d=v.opacity,p=v.color,m=c/2/s+" "+c/2/l;o=i.zrId+"-s"+i.shadowIdx++,i.defs[o]=IT("filter",o,{id:o,x:"-100%",y:"-100%",width:"300%",height:"300%"},[IT("feDropShadow","",{dx:f/s,dy:h/l,stdDeviation:m,"flood-color":p,"flood-opacity":d})]),a[e]=o}n.filter=Ar(o)}}(i,t,r)}function GT(t,n){var i=function(t){if("function"==typeof kw)return kw(t)}(n);i&&(i.each((function(n,i){null!=n&&(t[(CT+i).toLowerCase()]=n+"")})),n.isSilent()&&(t[CT+"silent"]="true"))}function ZT(t){return mr(t[0]-1)&&mr(t[1])&&mr(t[2])&&mr(t[3]-1)}function JT(t,n){if(n&&(!function(t){return mr(t[4])&&mr(t[5])}(n)||!ZT(n))){var i=1e4;t.transform=ZT(n)?"translate("+$T(n[4]*i)/i+" "+$T(n[5]*i)/i+")":function(t){return"matrix("+yr(t[0])+","+yr(t[1])+","+yr(t[2])+","+yr(t[3])+","+gr(t[4])+","+gr(t[5])+")"}(n)}}function KT(t,n,i){for(var r=t.points,e=[],a=0;a<r.length;a++)e.push($T(r[a][0]*i)/i),e.push($T(r[a][1]*i)/i);n.points=e.join(" ")}function QT(t){return!t.smooth}var tN,nN,iN={circle:[(tN=["cx","cy","r"],nN=U(tN,(function(t){return"string"==typeof t?[t,t]:t})),function(t,n,i){for(var r=0;r<nN.length;r++){var e=nN[r],a=t[e[0]];null!=a&&(n[e[1]]=$T(a*i)/i)}})],polyline:[KT,QT],polygon:[KT,QT]};function rN(t,n){var i=t.style,r=t.shape,e=iN[t.type],a={},o=n.animation,u="path",s=t.style.strokePercent,l=n.compress&&Tr(t)||4;if(!e||n.willUpdate||e[1]&&!e[1](r)||o&&function(t){for(var n=t.animators,i=0;i<n.length;i++)if("shape"===n[i].targetName)return!0;return!1}(t)||s<1){var f=!t.path||t.shapeChanged();t.path||t.createPathProxy();var h=t.path;f&&(h.beginPath(),t.buildPath(h,t.shape),t.pathUpdated());var c=h.getVersion(),v=t,d=v.__svgPathBuilder;v.__svgPathVersion===c&&d&&s===v.__svgPathStrokePercent||(d||(d=v.__svgPathBuilder=new xT),d.reset(l),h.rebuildPath(d,s),d.generateStr(),v.__svgPathVersion=c,v.__svgPathStrokePercent=s),a.d=d.getStr()}else{u=t.type;var p=Math.pow(10,l);e[0](r,a,p)}return JT(a,t.transform),qT(a,i,t,n),GT(a,t),n.animation&&UT(t,a,n),n.emphasis&&function(t,n,i){if(!t.ignore)if(t.isSilent())VT(l={"pointer-events":"none"},n,i);else{var r=t.states.emphasis&&t.states.emphasis.style?t.states.emphasis.style:{},e=r.fill;if(!e){var a=t.style&&t.style.fill,o=t.states.select&&t.states.select.style&&t.states.select.style.fill,u=t.currentStates.indexOf("select")>=0&&o||a;u&&(e=vr(u))}var s=r.lineWidth;s&&(s/=!r.strokeNoScale&&t.transform?t.transform[0]:1);var l={cursor:"pointer"};e&&(l.fill=e),r.stroke&&(l.stroke=r.stroke),s&&(l["stroke-width"]=s),VT(l,n,i)}}(t,a,n),IT(u,t.id+"",a)}function eN(t,n){return t instanceof da?rN(t,n):t instanceof ba?function(t,n){var i=t.style,r=i.image;if(r&&!J(r)&&(YT(r)?r=r.src:XT(r)&&(r=r.toDataURL())),r){var e=i.x||0,a=i.y||0,o={href:r,width:i.width,height:i.height};return e&&(o.x=e),a&&(o.y=a),JT(o,t.transform),qT(o,i,t,n),GT(o,t),n.animation&&UT(t,o,n),IT("image",t.id+"",o)}}(t,n):t instanceof ma?function(t,n){var i=t.style,r=i.text;if(null!=r&&(r+=""),r&&!isNaN(i.x)&&!isNaN(i.y)){var e=i.font||y,a=i.x||0,o=function(t,n,i){return"top"===i?t+=n/2:"bottom"===i&&(t-=n/2),t}(i.y||0,Yn(e),i.textBaseline),u={"dominant-baseline":"central","text-anchor":br[i.textAlign]||i.textAlign};if(Fa(i)){var s="",l=i.fontStyle,f=za(i.fontSize);if(!parseFloat(f))return;var h=i.fontWeight;s+="font-size:"+f+";font-family:"+(i.fontFamily||m)+";",l&&"normal"!==l&&(s+="font-style:"+l+";"),h&&"normal"!==h&&(s+="font-weight:"+h+";"),u.style=s}else u.style="font: "+e;return r.match(/\s/)&&(u["xml:space"]="preserve"),a&&(u.x=a),o&&(u.y=o),JT(u,t.transform),qT(u,i,t,n),GT(u,t),n.animation&&UT(t,u,n),IT("text",t.id+"",u,void 0,r)}}(t,n):void 0}function aN(t,n,i,r){var e,a=t[i],o={gradientUnits:a.global?"userSpaceOnUse":"objectBoundingBox"};if(Mr(a))e="linearGradient",o.x1=a.x,o.y1=a.y,o.x2=a.x2,o.y2=a.y2;else{if(!kr(a))return;e="radialGradient",o.cx=ut(a.x,.5),o.cy=ut(a.y,.5),o.r=ut(a.r,.5)}for(var u=a.colorStops,s=[],l=0,f=u.length;l<f;++l){var h=100*gr(u[l].offset)+"%",c=pr(u[l].color),v=c.opacity,d={offset:h};d["stop-color"]=c.color,v<1&&(d["stop-opacity"]=v),s.push(IT("stop",l+"",d))}var p=LT(IT(e,"",o,s)),m=r.gradientCache,y=m[p];y||(y=r.zrId+"-g"+r.gradientIdx++,m[p]=y,o.id=y,r.defs[y]=IT(e,y,o,s)),n[i]=Ar(y)}function oN(t,n,i,r){var e,a=t.style[i],o=t.getBoundingRect(),u={},s=a.repeat,l="no-repeat"===s,f="repeat-x"===s,h="repeat-y"===s;if(wr(a)){var c=a.imageWidth,v=a.imageHeight,d=void 0,p=a.image;if(J(p)?d=p:YT(p)?d=p.src:XT(p)&&(d=p.toDataURL()),"undefined"==typeof Image){var m="Image width/height must been given explictly in svg-ssr renderer.";ht(c,m),ht(v,m)}else if(null==c||null==v){var y=function(t,n){if(t){var i=t.elm,r=c||n.width,e=v||n.height;"pattern"===t.tag&&(f?(e=1,r/=o.width):h&&(r=1,e/=o.height)),t.attrs.width=r,t.attrs.height=e,i&&(i.setAttribute("width",r),i.setAttribute("height",e))}},g=$t(d,null,t,(function(t){l||y(M,t),y(e,t)}));g&&g.width&&g.height&&(c=c||g.width,v=v||g.height)}e=IT("image","img",{href:d,width:c,height:v}),u.width=c,u.height=v}else a.svgElement&&(e=R(a.svgElement),u.width=a.svgWidth,u.height=a.svgHeight);if(e){var b,w;l?b=w=1:f?(w=1,b=u.width/o.width):h?(b=1,w=u.height/o.height):u.patternUnits="userSpaceOnUse",null==b||isNaN(b)||(u.width=b),null==w||isNaN(w)||(u.height=w);var x=Nr(a);x&&(u.patternTransform=x);var M=IT("pattern","",u,[e]),k=LT(M),S=r.patternCache,A=S[k];A||(A=r.zrId+"-p"+r.patternIdx++,S[k]=A,u.id=A,M=r.defs[A]=IT("pattern",A,u,[e])),n[i]=Ar(A)}}function uN(t,n,i){var r=i.clipPathCache,e=i.defs,a=r[t.id];if(!a){var o={id:a=i.zrId+"-c"+i.clipPathIdx++};r[t.id]=a,e[a]=IT("clipPath",a,o,[rN(t,i)])}n["clip-path"]=Ar(a)}function sN(t){return document.createTextNode(t)}function lN(t,n,i){t.insertBefore(n,i)}function fN(t,n){t.removeChild(n)}function hN(t,n){t.appendChild(n)}function cN(t){return t.parentNode}function vN(t){return t.nextSibling}function dN(t,n){t.textContent=n}var pN=IT("","");function mN(t){return void 0===t}function yN(t){return void 0!==t}function gN(t,n,i){for(var r={},e=n;e<=i;++e){var a=t[e].key;void 0!==a&&(r[a]=e)}return r}function bN(t,n){return t.tag===n.tag&&t.key===n.key}function wN(t){var n,i=t.children,r=t.tag;if(yN(r)){var e=t.elm=OT(r);if(kN(pN,t),G(i))for(n=0;n<i.length;++n){var a=i[n];null!=a&&hN(e,wN(a))}else yN(t.text)&&!tt(t.text)&&hN(e,sN(t.text))}else t.elm=sN(t.text);return t.elm}function xN(t,n,i,r,e){for(;r<=e;++r){var a=i[r];null!=a&&lN(t,wN(a),n)}}function MN(t,n,i,r){for(;i<=r;++i){var e=n[i];null!=e&&(yN(e.tag)?fN(cN(e.elm),e.elm):fN(t,e.elm))}}function kN(t,n){var i,r=n.elm,e=t&&t.attrs||{},a=n.attrs||{};if(e!==a){for(i in a){var o=a[i];e[i]!==o&&(!0===o?r.setAttribute(i,""):!1===o?r.removeAttribute(i):"style"===i?r.style.cssText=o:120!==i.charCodeAt(0)?r.setAttribute(i,o):"xmlns:xlink"===i||"xmlns"===i?r.setAttributeNS("http://www.w3.org/2000/xmlns/",i,o):58===i.charCodeAt(3)?r.setAttributeNS("http://www.w3.org/XML/1998/namespace",i,o):58===i.charCodeAt(5)?r.setAttributeNS(NT,i,o):r.setAttribute(i,o))}for(i in e)i in a||r.removeAttribute(i)}}function SN(t,n){var i=n.elm=t.elm,r=t.children,e=n.children;t!==n&&(kN(t,n),mN(n.text)?yN(r)&&yN(e)?r!==e&&function(t,n,i){for(var r,e,a,o=0,u=0,s=n.length-1,l=n[0],f=n[s],h=i.length-1,c=i[0],v=i[h];o<=s&&u<=h;)null==l?l=n[++o]:null==f?f=n[--s]:null==c?c=i[++u]:null==v?v=i[--h]:bN(l,c)?(SN(l,c),l=n[++o],c=i[++u]):bN(f,v)?(SN(f,v),f=n[--s],v=i[--h]):bN(l,v)?(SN(l,v),lN(t,l.elm,vN(f.elm)),l=n[++o],v=i[--h]):bN(f,c)?(SN(f,c),lN(t,f.elm,l.elm),f=n[--s],c=i[++u]):(mN(r)&&(r=gN(n,o,s)),mN(e=r[c.key])||(a=n[e]).tag!==c.tag?lN(t,wN(c),l.elm):(SN(a,c),n[e]=void 0,lN(t,a.elm,l.elm)),c=i[++u]);(o<=s||u<=h)&&(o>s?xN(t,null==i[h+1]?null:i[h+1].elm,i,u,h):MN(t,n,o,s))}(i,r,e):yN(e)?(yN(t.text)&&dN(i,""),xN(i,null,e,0,e.length-1)):yN(r)?MN(i,r,0,r.length-1):yN(t.text)&&dN(i,""):t.text!==n.text&&(yN(r)&&MN(i,r,0,r.length-1),dN(i,n.text)))}var AN=0,TN=function(){function t(t,n,i){if(this.type="svg",this.configLayer=function(){},this.storage=n,this._opts=i=P({},i),this.root=t,this._id="zr"+AN++,this._oldVNode=_T(i.width,i.height),t&&!i.ssr){var r=this._viewport=document.createElement("div");r.style.cssText="position:relative;overflow:hidden";var e=this._svgDom=this._oldVNode.elm=OT("svg");kN(null,this._oldVNode),r.appendChild(e),t.appendChild(r)}this.resize(i.width,i.height)}return t.prototype.getType=function(){return this.type},t.prototype.getViewportRoot=function(){return this._viewport},t.prototype.getViewportRootOffset=function(){var t=this.getViewportRoot();if(t)return{offsetLeft:t.offsetLeft||0,offsetTop:t.offsetTop||0}},t.prototype.getSvgDom=function(){return this._svgDom},t.prototype.refresh=function(){if(this.root){var t=this.renderToVNode({willUpdate:!0});t.attrs.style="position:absolute;left:0;top:0;user-select:none",function(t,n){if(bN(t,n))SN(t,n);else{var i=t.elm,r=cN(i);wN(n),null!==r&&(lN(r,n.elm,vN(i)),MN(r,[t],0,0))}}(this._oldVNode,t),this._oldVNode=t}},t.prototype.renderOneToVNode=function(t){return eN(t,DT(this._id))},t.prototype.renderToVNode=function(t){t=t||{};var n=this.storage.getDisplayList(!0),i=this._width,r=this._height,e=DT(this._id);e.animation=t.animation,e.willUpdate=t.willUpdate,e.compress=t.compress,e.emphasis=t.emphasis,e.ssr=this._opts.ssr;var a=[],o=this._bgVNode=function(t,n,i,r){var e;if(i&&"none"!==i)if(e=IT("rect","bg",{width:t,height:n,x:"0",y:"0"}),Sr(i))aN({fill:i},e.attrs,"fill",r);else if(xr(i))oN({style:{fill:i},dirty:Mt,getBoundingRect:function(){return{width:t,height:n}}},e.attrs,"fill",r);else{var a=pr(i),o=a.opacity;e.attrs.fill=a.color,o<1&&(e.attrs["fill-opacity"]=o)}return e}(i,r,this._backgroundColor,e);o&&a.push(o);var u=t.compress?null:this._mainVNode=IT("g","main",{},[]);this._paintList(n,e,u?u.children:a),u&&a.push(u);var s=U(Y(e.defs),(function(t){return e.defs[t]}));if(s.length&&a.push(IT("defs","defs",{},s)),t.animation){var l=function(t,n,i){var r=(i=i||{}).newline?"\n":"",e=" {"+r,a=r+"}",o=U(Y(t),(function(n){return n+e+U(Y(t[n]),(function(i){return i+":"+t[n][i]+";"})).join(r)+a})).join(r),u=U(Y(n),(function(t){return"@keyframes "+t+e+U(Y(n[t]),(function(i){return i+e+U(Y(n[t][i]),(function(r){var e=n[t][i][r];return"d"===r&&(e='path("'+e+'")'),r+":"+e+";"})).join(r)+a})).join(r)+a})).join(r);return o||u?["<![CDATA[",o,u,"]]>"].join(r):""}(e.cssNodes,e.cssAnims,{newline:!0});if(l){var f=IT("style","stl",{},[],l);a.push(f)}}return _T(i,r,a,t.useViewBox)},t.prototype.renderToString=function(t){return LT(this.renderToVNode({animation:ut((t=t||{}).cssAnimation,!0),emphasis:ut(t.cssEmphasis,!0),willUpdate:!1,compress:!0,useViewBox:ut(t.useViewBox,!0)}),{newline:!0})},t.prototype.setBackgroundColor=function(t){this._backgroundColor=t},t.prototype.getSvgRoot=function(){return this._mainVNode&&this._mainVNode.elm},t.prototype._paintList=function(t,n,i){for(var r,e,a=t.length,o=[],u=0,s=0,l=0;l<a;l++){var f=t[l];if(!f.invisible){var h=f.__clipPaths,c=h&&h.length||0,v=e&&e.length||0,d=void 0;for(d=Math.max(c-1,v-1);d>=0&&(!h||!e||h[d]!==e[d]);d--);for(var p=v-1;p>d;p--)r=o[--u-1];for(var m=d+1;m<c;m++){var y={};uN(h[m],y,n);var g=IT("g","clip-g-"+s++,y,[]);(r?r.children:i).push(g),o[u++]=g,r=g}e=h;var b=eN(f,n);b&&(r?r.children:i).push(b)}}},t.prototype.resize=function(t,n){var i=this._opts,r=this.root,e=this._viewport;if(null!=t&&(i.width=t),null!=n&&(i.height=n),r&&e&&(e.style.display="none",t=aM(r,0,i),n=aM(r,1,i),e.style.display=""),this._width!==t||this._height!==n){if(this._width=t,this._height=n,e){var a=e.style;a.width=t+"px",a.height=n+"px"}if(xr(this._backgroundColor))this.refresh();else{var o=this._svgDom;o&&(o.setAttribute("width",t),o.setAttribute("height",n));var u=this._bgVNode&&this._bgVNode.elm;u&&(u.setAttribute("width",t),u.setAttribute("height",n))}}},t.prototype.getWidth=function(){return this._width},t.prototype.getHeight=function(){return this._height},t.prototype.dispose=function(){this.root&&(this.root.innerHTML=""),this._svgDom=this._viewport=this.storage=this._oldVNode=this._bgVNode=this._mainVNode=null},t.prototype.clear=function(){this._svgDom&&(this._svgDom.innerHTML=null),this._oldVNode=null},t.prototype.toDataURL=function(t){var n=this.renderToString(),i="data:image/svg+xml;";return t?(n=Cr(n))&&i+"base64,"+n:i+"charset=UTF-8,"+encodeURIComponent(n)},t}();const NN=864e5,CN=new Set(["proportion-bar","pie","doughnut","ring"]),ON=new Set(["bar","dot","area","line"]),IN=new Set(["bar","area","line"]);function LN(t){return ON.has(t)}function DN(t){return IN.has(t)}function _N(t){return Array.isArray(t.value)}function zN(t){const n=t.value;return Array.isArray(n)?Math.min(...n):n}function RN(t){const n=t.value;return Array.isArray(n)?Math.max(...n):n}function FN(t){const n=_N(t)?zN(t):0;return RN(t)-n}function PN(t){return Array.isArray(t.value)?t.value[0]:t.value}function BN(t){return Array.isArray(t.value)?t.value[1]:t.value}function EN(t,n,i){const r=t.map((t=>RN(t))),e=Math.min(0,...t.map((t=>zN(t)))),a=null!=n?n:Math.max(e,...r),o=a-e;return nC(e,a,function(t,n){return t>0&&n/t<=100}(i,o)?i:GN(o))}function WN(t){return"number"==typeof t&&Number.isFinite(new Date(t).getTime())}function jN(t,n){const i=t.filter((t=>WN(t))),r=new Date(i.length>0?Math.min(...i):Date.now());r.setHours(0,0,0,0);const e=new Date(WN(n)?n:Math.max(r.getTime(),...i));return e.getTime()<=r.getTime()?e.setTime(JN(r,1).getTime()):e.getTime()>tC(e)&&e.setTime(JN(new Date(tC(e)),1).getTime()),{minValue:r.getTime(),maxValue:e.getTime(),totalRange:e.getTime()-r.getTime(),increment:NN}}const HN=365.25,UN=t=>({unit:"day",days:t,first:t=>t,next:n=>JN(n,t)}),VN=t=>({unit:"day",days:7*t,first:t=>JN(t,(8-t.getDay())%7),next:n=>JN(n,7*t)}),$N=t=>({unit:"month",days:30.44*t,first:n=>{let i=1===n.getDate()?n:KN(n,1);for(;i.getMonth()%t!=0;)i=KN(i,1);return i},next:n=>KN(n,t)}),YN=t=>({unit:"year",days:HN*t,first:n=>{let i=n.getFullYear();return n.getTime()>QN(i,0,1).getTime()&&(i+=1),QN(Math.ceil(i/t)*t,0,1)},next:n=>QN(n.getFullYear()+t,0,1)}),XN=[UN(1),UN(2),VN(1),VN(2),$N(1),$N(3),$N(6),YN(1),YN(2),YN(5),YN(10)];function qN(t,n){const i=t.reduce(((t,n)=>t+FN(n)),0),r=(null!=n?n:i>0?i:1)||1;return{minValue:0,maxValue:r,totalRange:r,increment:r}}function GN(t){if(t<=0)return 1;const n=t/10,i=10**Math.floor(Math.log10(n));return Math.ceil(n/i)*i}function ZN(t){const n=Math.min(0,...t),i=Math.max(0,...t);return nC(n,i,GN(i-n))}function JN(t,n){return QN(t.getFullYear(),t.getMonth(),t.getDate()+n)}function KN(t,n){return QN(t.getFullYear(),t.getMonth()+n,1)}function QN(t,n,i){const r=new Date(0);return r.setFullYear(t,n,i),r.setHours(0,0,0,0),r}function tC(t){return new Date(t).setHours(0,0,0,0)}function nC(t,n,i){const r=Math.floor(t/i)*i,e=Math.ceil(n/i)*i;return{minValue:r,maxValue:e,totalRange:e-r,increment:i}}const iC={options:{maximumFractionDigits:3},small:{maximumSignificantDigits:6},smallBelow:1},rC={options:{style:"percent",maximumFractionDigits:1},small:{style:"percent",maximumSignificantDigits:2},smallBelow:.01},eC={style:"percent",minimumFractionDigits:2,maximumFractionDigits:2},aC={values:[],unit:"day"},oC=new Map,uC=new Map,sC=new Map,lC=new Map;function fC(t,n){const{value:i,formattedValue:r}=t;if(r)return r;const e=function(t){if("date"===t.valueFormat){const n=vC(t.language);return t=>WN(t)?n.format(t):`${t}`}const n=function(t){const n=wC(t.language);return"percent"===t.valueFormat?yC(n,rC):"currency"===t.valueFormat&&cC(t.currency)?gC(n,{style:"currency",currency:t.currency,trailingZeroDisplay:"stripIfInteger"}):yC(n,iC)}(t);return t=>n.format(t)}(n);if(!Array.isArray(i))return e(i);const[a,o]=i.map((t=>e(t)));if("scatter"===n.type)return function(t,n){return`(${t}${`${t}${n}`.includes(",")?"; ":", "}${n})`}(a,o);const[u,s]=[zN(t),RN(t)];return"date"===n.valueFormat&&WN(u)&&WN(s)?vC(n.language).formatRange(u,s):`${a} — ${o}`}function hC(t,n,i){const r=wC(n.language);if("date"===n.valueFormat)return function(t,n=aC){const i=bC(t,{year:"numeric"});if("year"===n.unit)return t=>i.format(t);const r="month"===n.unit?{month:"short"}:{day:"numeric",month:"short"},e=bC(t,r),a=bC(t,Object.assign(Object.assign({},r),{year:"numeric"}));return t=>function(t,n){const i=n.indexOf(t);return i<=0||new Date(n[i-1]).getFullYear()!==new Date(t).getFullYear()}(t,n.values)?"month"===n.unit&&0===new Date(t).getMonth()?i.format(t):a.format(t):e.format(t)}(r,i);if("percent"===n.valueFormat){const n=gC(r,{style:"percent",maximumFractionDigits:dC(100*t.increment)});return t=>n.format(t)}const e=Math.max(Math.abs(t.minValue),Math.abs(t.maxValue)),a=gC(r,e>=1e4?{notation:"compact",maximumSignificantDigits:pC(e,t.increment)}:{maximumFractionDigits:dC(t.increment)});return t=>a.format(t)}function cC(t){let n=sC.get(t);return void 0===n&&(n=function(t){try{return gC("en",{style:"currency",currency:t}),!0}catch(t){return!1}}(t),sC.set(t,n)),n}function vC(t){return bC(wC(t),{dateStyle:"medium"})}function dC(t){return Number.isFinite(t)?Math.min(20,Math.max(0,-mC(t))):0}function pC(t,n){if(!Number.isFinite(n))return 21;const i=Math.floor(Math.log10(t))-mC(n);return Math.min(21,Math.max(1,i+1))}function mC(t){var n,i;const[r,e]=Number(t.toPrecision(12)).toExponential().split("e",2),a=null!==(i=null===(n=r.split(".",2)[1])||void 0===n?void 0:n.length)&&void 0!==i?i:0;return Number(e)-a}function yC(t,n){const i=gC(t,n.options),r=gC(t,n.small);return{format:t=>0!==t&&Math.abs(t)<n.smallBelow?r.format(t):i.format(t)}}function gC(t,n){const i=`${t} ${JSON.stringify(n)}`;let r=uC.get(i);return r||(r=new Intl.NumberFormat(t,n),uC.set(i,r)),r}function bC(t,n){const i=`${t} ${JSON.stringify(n)}`;let r=lC.get(i);return r||(r=new Intl.DateTimeFormat(t,n),lC.set(i,r)),r}function wC(t){var n;return null!==(n=xC(t))&&void 0!==n?n:"en"}function xC(t){return oC.has(t)||oC.set(t,o(t)),oC.get(t)}function MC(t,n){var i;return null===(i=t.series[n.series])||void 0===i?void 0:i.items[n.index]}function kC(t,n){const i=t=>Math.abs(t-n.series),[r]=[...t.series.keys()].filter((i=>MC(t,Object.assign(Object.assign({},n),{series:i})))).sort(((t,n)=>i(t)-i(n)));return r}function SC(t){return t.series.flatMap((t=>t.items.filter((t=>void 0!==t))))}function AC(t,n){return n?t.categories.flatMap(((n,i)=>{const r=t.series.map((t=>t.items[i])).filter((t=>void 0!==t)).map((t=>FN(t))),e=t=>r.filter((n=>t(n))).reduce(((t,n)=>t+n),0);return[{text:n,value:e((t=>t>0))},{text:n,value:e((t=>t<0))}]})):SC(t)}function TC(t,n){const i=Math.sign(NC(t,n));return t.series.slice(n.series+1).every(((r,e)=>Math.sign(NC(t,{series:n.series+1+e,index:n.index}))!==i))}function NC(t,n){const i=MC(t,n);return i?FN(i):0}const CC={stack:"series",stackStrategy:"samesign"},OC=[.5,.65,.85,1],IC={width:"0.625rem",height:"0.625rem","border-radius":"0.125rem"},LC={line:{height:"0.125rem"},dot:{"border-radius":"50%"}},DC={focus:"self"},_C={itemStyle:{opacity:.4}},zC={show:!1};function RC(t,n){var i,r;return t.itemsAreSeries?{series:0,index:n.seriesIndex}:{series:null!==(r=null===(i=t.partsOfSeries)||void 0===i?void 0:i[n.seriesIndex])&&void 0!==r?r:0,index:n.dataIndex}}function FC(t,n){return t.itemsAreSeries?{seriesIndex:n.index,dataIndex:0}:{seriesIndex:t.seriesIndexes[n.series],dataIndex:n.index}}function PC(t){var n;if((null===(n=t.series)||void 0===n?void 0:n.length)&&LN(t.type))return t.series}function BC(t){var n,i;if(!PC(t)&&!(null===(n=t.items)||void 0===n?void 0:n.length))return null===(i=t.series)||void 0===i?void 0:i[0]}function EC(t){var n,i,r;return PC(t)?[]:null!==(r=null!==(i=null===(n=BC(t))||void 0===n?void 0:n.items)&&void 0!==i?i:t.items)&&void 0!==r?r:[]}function WC(t){return Boolean(t.stacked&&PC(t)&&DN(t.type)&&"date"!==t.valueFormat)}function jC(t){var n;return function(t){const n=[],i=new Map,r=t.map((t=>{var r;const e=new Map;return(null!==(r=t.items)&&void 0!==r?r:[]).map((t=>{var r,a;const o=null!==(r=e.get(t.text))&&void 0!==r?r:0;e.set(t.text,o+1);const u=null!==(a=i.get(t.text))&&void 0!==a?a:[];return i.set(t.text,u),o===u.length&&(u.push(n.length),n.push(t.text)),{item:t,index:u[o]}}))}));return{categories:n,series:t.map(((t,i)=>{const e=new Map(r[i].map((t=>[t.index,t.item])));return{text:t.text,color:t.color,items:n.map(((t,n)=>e.get(n)))}}))}}(null!==(n=PC(t))&&void 0!==n?n:[{text:"",items:EC(t)}])}function HC(t,n=""){return Object.assign(Object.assign(Object.assign({},IC),LC[t]),{"background-color":n})}function UC(t,n){return"yAxis"===t?{interval:n>=14?0:"auto"}:n<40?{interval:"auto",overflow:"none"}:{interval:0,width:n-4,overflow:"truncate",ellipsis:"…"}}function VC(t,n){const i=t.items[n];if(!t.displayItemPercentage||!CN.has(t.type))return i.text;const r=function(t,n){return gC(wC(n),eC).format(t/100)}(function(t,n){return FN(t)/n.totalRange*100}(i,qN(t.items,t.maxValue)),t.language);return`${i.text} (${r})`}function $C(t,n,i){return{trigger:"axis",axisPointer:"bar"===t.type?{type:"shadow",shadowStyle:{color:i.axisLineColor,opacity:.2}}:{type:"line",lineStyle:{color:i.axisLineColor}},formatter:i=>{const[r]=[i].flat();return function(t,n,i){const r=t.categories[i];if(void 0===r)return"";const e=t.series.filter((t=>void 0!==t.items[i])).map((t=>{var r;const e=t.items[i];return a=function(t,n=""){const i=Object.assign({display:"inline-block","vertical-align":"middle","margin-right":"0.375rem"},HC(t,Nc(n))),r=Object.entries(i).map((([t,n])=>`${t}:${n}`));return`<span style="${r.join(";")}"></span>`}(n.type,null!==(r=e.color)&&void 0!==r?r:t.color),o=t.text,u=fC(e,n),`<div style="display:flex;justify-content:space-between;gap:1rem"><span>${a}${Nc(o)}</span><span>${Nc(u)}</span></div>`;var a,o,u}));return[`<div>${Nc(r)}</div>`,...e].join("")}(n,t,null==r?void 0:r.dataIndex)}}}function YC(t,n){return{type:"category",data:n.categories,inverse:"portrait"===t.orientation}}function XC(t,n,i){const{items:r,orientation:e}=n,a=Object.assign(Object.assign({},YC(n,i)),{show:!1}),o={type:"value",min:0,max:1,show:!1},u={type:"bar",xAxisIndex:1,yAxisIndex:1,barWidth:"100%",itemStyle:{color:"transparent"},data:r.map((()=>1)),cursor:sO(r),emphasis:{disabled:!0}},s="landscape"===e;return Object.assign(Object.assign({},t),{xAxis:[t.xAxis,s?a:o],yAxis:[t.yAxis,s?o:a],series:[...t.series,u]})}function qC(t,n,i,r){const e=n.series[i];return"line"===t.type||"area"===t.type?function(t,n,i,r){var e;const{items:a}=n,o=null!==(e=n.color)&&void 0!==e?e:r.lineColor,u="area"===t.type,s=Object.assign(Object.assign({type:"line",color:o,symbol:"circle",symbolSize:6},t.series&&KC(a)&&{showAllSymbol:!0,labelLayout:{hideOverlap:!0}}),{data:a.map((t=>t?{value:FN(t),itemStyle:{color:t.color}}:null)),areaStyle:u?{color:o,opacity:JC(t)}:void 0,label:oO(t,n,r),cursor:sO(a),emphasis:DC,blur:_C});if(t.stacked)return{series:[Object.assign(Object.assign({},s),CC)],seriesIndex:0};if(!QC(a))return{series:[s],seriesIndex:0};return{series:[Object.assign(Object.assign({type:"line"},nO(i)),{symbol:"none",color:o,lineStyle:{opacity:u?0:1},data:iO(a)}),Object.assign(Object.assign({},s),tO(i))],seriesIndex:1}}(t,e,i,r):"dot"===t.type?function(t,n,i,r){const{items:e}=n,{orientation:a}=t,o=(t,n)=>"landscape"===a?[t,n]:[n,t],u={type:"scatter",symbolSize:8,data:e.map(((t,n)=>t?{value:o(n,RN(t)),itemStyle:{color:t.color}}:null)),label:oO(t,n,r),cursor:sO(e),emphasis:DC,blur:_C};if(!QC(e))return{series:[u],seriesIndex:0};const s=Object.assign(Object.assign({type:"bar"},tO(i)),{cursor:sO(e),emphasis:{disabled:!0},barWidth:2,barGap:"-100%",data:e.map((t=>t&&_N(t)?{value:FN(t),itemStyle:{color:t.color}}:null))}),l={type:"scatter",cursor:sO(e),emphasis:{disabled:!0},symbolSize:8,data:e.map(((t,n)=>t&&_N(t)?{value:o(n,zN(t)),itemStyle:{color:t.color}}:null))};return{series:[Object.assign(Object.assign({type:"bar"},nO(i)),{barGap:"-100%",data:iO(e)}),s,l,u],seriesIndex:3}}(t,e,i,r):t.stacked?{series:[GC(t,n,i,r)],seriesIndex:0}:function(t,n,i,r){const{items:e}=n,a={type:"bar",data:e.map((t=>t?{value:FN(t),itemStyle:{color:t.color,borderRadius:r.itemBorderRadius}}:null)),label:oO(t,n,r),cursor:sO(e),emphasis:DC,blur:_C};return QC(e)?{series:[Object.assign(Object.assign({type:"bar"},nO(i)),{data:iO(e)}),Object.assign(Object.assign({},a),tO(i))],seriesIndex:1}:{series:[a],seriesIndex:0}}(t,e,i,r)}function GC(t,n,i,r){const e=n.series[i];return Object.assign(Object.assign({type:"bar"},CC),{data:e.items.map(((e,a)=>e?{value:FN(e),itemStyle:{color:e.color,borderRadius:TC(n,{series:i,index:a})?ZC(t,e,r):0,borderColor:r.dividerColor,borderWidth:1}}:null)),label:Object.assign(Object.assign({},oO(t,e,r)),{position:"inside",color:void 0}),cursor:sO(e.items),emphasis:DC,blur:_C})}function ZC(t,n,i){const[r,e,a,o]=i.itemBorderRadius,u=FN(n)>=0;return"portrait"===t.orientation?u?[0,e,a,0]:[r,0,0,o]:u?[r,e,0,0]:[0,0,a,o]}function JC(t){var n;return(null===(n=t.series)||void 0===n?void 0:n.length)>1&&!t.stacked?.15:.4}function KC(t){return t.some((t=>null==t?void 0:t.clickable))}function QC(t){return t.some((t=>t&&_N(t)))}function tO(t){return{stack:`range${t}`,stackStrategy:"all"}}function nO(t){return Object.assign(Object.assign({},tO(t)),{silent:!0,tooltip:zC,emphasis:{disabled:!0},itemStyle:{color:"transparent"}})}function iO(t){return t.map((t=>t?_N(t)?zN(t):0:null))}function rO(t){return{left:8,right:8,top:8,bottom:8,outerBoundsMode:"same",outerBoundsContain:"all",show:!0,backgroundColor:t.backgroundColor,borderWidth:0}}function eO(t,n,i,r){const e="date"===i.valueFormat&&function(t){var n;const i=(t.maxValue-t.minValue)/NN,r=i/HN/10,e=null!==(n=XN.find((t=>i/t.days<=6)))&&void 0!==n?n:YN(10*Math.ceil(r/6)),a=[];for(let n=e.first(new Date(t.minValue));n.getTime()<=t.maxValue;n=e.next(n))a.push(n.getTime());return{values:a,unit:e.unit}}(t),a=e&&{customValues:e.values};return Object.assign(Object.assign(Object.assign({type:"value",min:t.minValue,max:t.maxValue,interval:e?void 0:t.increment,axisLabel:Object.assign({show:!0,color:r.textColor,formatter:hC(t,i,e||void 0)},a)},a&&{axisTick:a}),{axisLine:{lineStyle:{color:r.axisLineColor}},splitLine:{lineStyle:{color:r.axisLineColor}}}),n)}function aO(t,n,i){return t.displayAxisLabels?{name:n,nameLocation:"middle",nameTextStyle:{color:i.textColor}}:{}}function oO(t,n,i){return Object.assign(Object.assign({show:t.displayItemValue,position:"landscape"===t.orientation?"top":"right"},uO(i)),{formatter:({dataIndex:i})=>fC(n.items[i],t)})}function uO(t){return{color:t.textColor,textBorderWidth:0}}function sO(t){return lO(KC(t))}function lO(t){return t?"pointer":"default"}const fO="--limel-chart-probe",hO={"--limel-chart-item-color":"--chart-item-color","--limel-chart-axis-line-color":"--chart-axis-line-color","--limel-chart-background-color":"--chart-background-color","--limel-chart-item-divider-color":"--chart-item-divider-color"};const cO=["horizontal","vertical"],vO=t=>({text:t.text,value:t.value,formattedValue:t.formattedValue,color:t.color,clickable:t.clickable}),dO=[function(t){t.registerChartView(Dg),t.registerSeriesModel(gg),t.registerLayout(t.PRIORITY.VISUAL.LAYOUT,function(t){return{seriesType:t,overallReset:function(n){var i=ag(t,cg);ty(n,i,(function(n){var r=function(t,n){var i=function(t,n){var i=ag(n,cg),r=[],e=uy(t,{fromStat:{key:i},min:1});return Km(t,i,(function(t){r.push({barWidth:no(t.get("barWidth"),e.w),barMaxWidth:no(t.get("barMaxWidth"),e.w),barMinWidth:no(t.get("barMinWidth")||(mg(t)?.5:1),e.w),barGap:t.get("barGap"),barCategoryGap:t.get("barCategoryGap"),defaultBarGap:t.get("defaultBarGap"),stackId:pg(t)})})),{bandWidthResult:e,seriesInfo:r}}(t,n);return i.columnMap=function(t){var n,i,r=t.bandWidthResult.w,e=r,a=0,o=[],u={};H(t.seriesInfo,(function(t,r){r||(i=t.defaultBarGap||0);var s=t.stackId;xt(u,s)||a++;var l=u[s];l||(l=u[s]={width:0,maxWidth:0},o.push(s));var f=t.barWidth;f&&!l.width&&(l.width=f,f=Ua(e,f),e-=f);var h=t.barMaxWidth;h&&(l.maxWidth=h);var c=t.barMinWidth;c&&(l.minWidth=c);var v=t.barGap;null!=v&&(i=v);var d=t.barCategoryGap;null!=d&&(n=d)})),null==n&&(n=Va(35-4*o.length,15)+"%");var s=no(n,r),l=no(i,1),f=(e-s)/(a+(a-1)*l);f=Va(f,0),H(o,(function(t){var n=u[t],i=n.maxWidth,r=n.minWidth;if(n.width)o=n.width,i&&(o=Ua(o,i)),r&&(o=Va(o,r)),n.width=o,e-=o+l*o,a--;else{var o=f;i&&i<o&&(o=Ua(i,e)),r&&r>o&&(o=r),o!==f&&(n.width=o,e-=o+l*o,a--)}})),f=Va(f=(e-s)/(a+(a-1)*l),0);var h,c=0;H(o,(function(t){var n=u[t];n.width||(n.width=f),h=n,c+=n.width*(1+l)})),h&&(c-=h.width*l);var v={},d=-c/2;return H(o,(function(t){var n=u[t];v[t]=v[t]||{bandWidth:r,offset:d,width:n.width},d+=n.width*(1+l)})),v}(i),i}(n,t);Km(n,i,(function(t){var n=r.columnMap[pg(t)];t.getData().setLayout({bandWidth:n.bandWidth,offset:n.offset,size:n.width})}))}))}}}(ug)),t.registerLayout(t.PRIORITY.VISUAL.PROGRESSIVE_LAYOUT,{seriesType:ug,plan:op(),reset:function(t){if(function(t){return t.coordinateSystem&&"cartesian2d"===t.coordinateSystem.type}(t)){var n=t.getData(),i=t.coordinateSystem,r=i.getBaseAxis(),e=i.getOtherAxis(r),a=n.getDimensionIndex(n.mapDimension(e.dim)),o=n.getDimensionIndex(n.mapDimension(r.dim)),u=t.get("showBackground",!0),s=n.mapDimension(e.dim),l=n.getCalculationInfo("stackResultDimension"),f=dc(n,s)&&!!n.getCalculationInfo("stackedOnSeries"),h=e.isHorizontal(),c=e.toGlobalCoord(e.dataToCoord(lg(e))),v=mg(t),d=t.get("barMinHeight")||0,p=l&&n.getDimensionIndex(l),m=n.getLayout("size"),y=n.getLayout("offset");return{progress:function(t,n){for(var r,e=t.count,s=v&&Jd(3*e),l=v&&u&&Jd(3*e),g=v&&Jd(e),b=i.master.getRect(),w=h?b.width:b.height,x=n.getStore(),M=0;null!=(r=t.next());){var k=x.get(f?p:a,r),S=x.get(o,r),A=c,T=void 0;f&&(T=+k-x.get(a,r));var N=void 0,C=void 0,O=void 0,I=void 0;if(h){var L=i.dataToPoint([k,S]);f&&(A=i.dataToPoint([T,S])[0]),N=A,C=L[1]+y,I=m,$a(O=L[0]-A)<d&&(O=(O<0?-1:1)*d)}else L=i.dataToPoint([S,k]),f&&(A=i.dataToPoint([S,T])[1]),N=L[0]+y,C=A,O=m,$a(I=L[1]-A)<d&&(I=(I<=0?-1:1)*d);v?(s[M]=N,s[M+1]=C,s[M+2]=h?O:I,l&&(l[M]=h?b.x:N,l[M+1]=h?C:b.y,l[M+2]=w),g[r]=r):n.setItemLayout(r,{x:N,y:C,width:O,height:I}),M+=3}v&&n.setLayout({largePoints:s,largeDataIndices:g,largeBackgroundPoints:l,valueAxisHorizontal:h})}}}}}),t.registerProcessor(t.PRIORITY.PROCESSOR.STATISTIC,Cm(ug)),t.registerAction({type:"changeAxisOrder",event:"changeAxisOrder",update:"update"},(function(t,n){n.eachComponent({mainType:t.componentType||"series",query:t},(function(n){t.sortInfo&&n.axis.setCategorySortInfo(t.sortInfo)}))})),function(t){dg(t,(function(){function n(n){var i=ag(n,cg);sg(t,i,n,cg),Qy(i,function(t){return eg(ag(t,cg))}(n))}n("bar"),n("pictorialBar")}))}(t)},function(t){t.registerChartView(DS),t.registerSeriesModel(_S)},function(t){t.registerChartView(Sm),t.registerSeriesModel(Fd),t.registerLayout(Am("line",!0)),t.registerVisual({seriesType:"line",reset:function(t){var n=t.getData(),i=t.getModel("lineStyle").getLineStyle();i&&!i.stroke&&(i.stroke=n.getVisual("style").fill),n.setVisual("legendLineStyle",i)}}),t.registerProcessor(t.PRIORITY.PROCESSOR.STATISTIC,Cm("line"))},function(t){t.registerChartView(Ab),t.registerSeriesModel(tb),function(t,n){function i(n,i){var r=[];return n.eachComponent({mainType:"series",subType:t,query:i},(function(t){r.push(t.seriesIndex)})),r}H([[t+"ToggleSelect","toggleSelect"],[t+"Select","select"],[t+"UnSelect","unselect"]],(function(t){n(t[0],(function(n,r,e){n=P({},n),e.dispatchAction(P(n,{type:t[1],seriesIndex:i(r,n)}))}))}))}(Kg,t.registerAction),t.registerLayout(Mb),t.registerProcessor({seriesType:Kg,reset:function(t,n){var i=n.findComponents({mainType:"legend"});if(i&&i.length){var r=t.getData();r.filterSelf((function(t){for(var n=r.getName(t),e=0;e<i.length;e++)if(!i[e].isSelected(n))return!1;return!0}))}}}),t.registerProcessor({seriesType:Kg,reset:function(t){var n=t.getData();n.filterSelf((function(t){var i=n.mapDimension("value"),r=n.get(i,t);return!(Q(r)&&!isNaN(r)&&r<0)}))}})},function(t){Fk(CS),t.registerSeriesModel(Pk),t.registerChartView(jk),t.registerLayout(Am("scatter"))},function(){Fk(CS),Fk(yA)},function(t){Fk(yA),bS.registerAxisPointerClass("PolarAxisPointer",gA),t.registerCoordinateSystem("polar",zA),t.registerComponentModel(MA),t.registerComponentView(GA),Gk(t,"angle",SA,XA),Gk(t,"radius",AA,qA),t.registerComponentView(EA),t.registerComponentView(HA),t.registerLayout(YA),function(t,n){VA(t,(function(){var i=ag(n,wA);sg(t,i,n,wA),Qy(i,eg(i))}))}(t,ug)},function(t){Fk(yA),t.registerComponentModel(ZA),t.registerComponentView(cT),t.registerAction({type:"showTip",event:"showTip",update:"tooltip:manuallyShowTip"},Mt),t.registerAction({type:"hideTip",event:"hideTip",update:"tooltip:manuallyHideTip"},Mt)},function(t){t.registerPainter("svg",TN)}],pO=class{constructor(i){t(this,i),this.interact=n(this,"interact",7),this.language="en",this.displayAxisLabels=!1,this.displayItemText=!1,this.displayItemValue=!1,this.displayItemPercentage=!0,this.stacked=!1,this.type="proportion-bar",this.orientation="landscape",this.valueFormat="number",this.loading=!1,this.focusedPosition={series:0,index:0},this.grid={categories:[],series:[]},this.seriesColors=[],this.themeMayHaveChanged=!1,this.warnings=new Map,this.invalidColors=new Set,this.setPlot=t=>{this.plot=t},this.handleResize=()=>{this.draw()},this.handleThemeChange=()=>{this.themeMayHaveChanged=!0,this.draw()},this.handleChartClick=t=>{var n,i;if(!this.drawing)return;const r=this.getClickableItem(this.getClickedPosition(t));r&&(null===(i=null===(n=t.event)||void 0===n?void 0:n.event)||void 0===i||i.stopPropagation(),this.interact.emit(r))},this.handleChartOver=t=>{this.highlightItemAt(t,!0)},this.handleChartOut=t=>{this.highlightItemAt(t,!1)},this.handleClick=t=>{const n=this.getClickableItem(this.getEventPosition(t));n&&(t.stopPropagation(),this.interact.emit(n))},this.handleKeyDown=t=>{const n=cO.find((n=>s(t,{orientation:n})));if(n)return t.preventDefault(),void this.focusItem(this.findTarget(t.key,this.getEventPosition(t),n));if("Enter"!==t.key&&" "!==t.key)return;const i=this.getClickableItem(this.getEventPosition(t));i&&(t.preventDefault(),this.interact.emit(i))},this.handleFocus=t=>{const n=t.currentTarget;this.focusedPosition=this.getPosition(n),this.showItem(n,!0)},this.handleBlur=t=>{this.showItem(t.currentTarget,!1)}}componentWillLoad(){this.warnAboutOldTypeName()}componentWillRender(){this.grid=jC({type:this.chartType,items:this.items,series:this.series}),this.warnOnChange("axisIncrement",this.getAxisIncrementWarning()),this.warnOnChange("language",this.getLanguageWarning()),this.warnOnChange("currency",this.getCurrencyWarning()),this.warnOnChange("items",this.getDateWarning()),this.warnOnChange("series",this.getSeriesWarning()),this.warnOnChange("stacked",this.getStackedWarning())}connectedCallback(){this.draw()}componentDidRender(){this.draw()}disconnectedCallback(){var t,n,i;this.disposeChart(),null===(t=this.resizeObserver)||void 0===t||t.disconnect(),this.resizeObserver=void 0,null===(n=this.stopWatchingTheme)||void 0===n||n.call(this),this.stopWatchingTheme=void 0,null===(i=this.themeReader)||void 0===i||i.dispose(),this.themeReader=void 0}warnOnChange(t,n){n&&n!==this.warnings.get(t)&&console.warn(n),this.warnings.set(t,n)}warnAboutOldTypeName(){"stacked-bar"===this.type&&console.warn("limel-chart: the type `stacked-bar` is now called `proportion-bar`. It draws the same chart, but please use the new name.")}getLanguageWarning(){if(void 0===xC(this.language))return`limel-chart: \`language\` must be one that this browser can write values in, such as \`sv\`, but was ${JSON.stringify(this.language)}. Writing the values in English instead.`}getCurrencyWarning(){if("currency"===this.valueFormat&&!cC(this.currency))return`limel-chart: \`currency\` must be a three-letter code such as \`SEK\` when \`valueFormat\` is \`currency\`, but was ${JSON.stringify(this.currency)}. Writing the values as numbers instead.`}getDateWarning(){if("date"!==this.valueFormat)return;const t=SC(this.grid).flatMap((t=>[t.value].flat())).find((t=>!WN(t)));return void 0!==t?`limel-chart: with \`valueFormat\` \`date\`, each value must be a date in milliseconds since 1970, as \`Date.getTime()\` gives, but was ${"number"==typeof t?t:JSON.stringify(t)}. Showing it as it is.`:void 0}getSeriesWarning(){var t,n,i;if(null===(t=this.series)||void 0===t?void 0:t.length){if(!LN(this.chartType)){const t=(null===(n=this.items)||void 0===n?void 0:n.length)?"`items`":"the items of the first series";return`limel-chart: \`series\` can only be drawn by \`bar\`, \`dot\`, \`line\`, and \`area\` charts, but \`type\` is \`${this.type}\`. Drawing ${t} instead.`}return(null===(i=this.items)||void 0===i?void 0:i.length)?"limel-chart: both `items` and `series` are set. Drawing `series`, and leaving out `items`.":void 0}}getStackedWarning(){if(this.stacked)return DN(this.chartType)?"date"===this.valueFormat?"limel-chart: `stacked` cannot stack dates. Ignoring `stacked`.":this.drawsSeries?void 0:"limel-chart: `stacked` stacks the `series` of a chart, but this chart has none. Ignoring `stacked`.":`limel-chart: \`stacked\` can only stack the series of \`bar\`, \`line\`, and \`area\` charts, but \`type\` is \`${this.type}\`. Ignoring \`stacked\`.`}get stacksSeries(){return WC({type:this.chartType,series:this.series,stacked:this.stacked,valueFormat:this.valueFormat})}get drawsSeries(){return Boolean(this.drawnSeries)}get drawnSeries(){return PC({type:this.chartType,series:this.series})}get drawnItems(){return EC({type:this.chartType,items:this.items,series:this.series})}get valueStyle(){return{type:this.chartType,language:this.language,valueFormat:this.valueFormat,currency:this.currency}}get chartType(){return"stacked-bar"===this.type?"proportion-bar":this.type}getAxisIncrementWarning(){const t=this.axisIncrement;if(null!=t&&"date"!==this.valueFormat){if(t<=0||Number.isNaN(t))return`limel-chart: \`axisIncrement\` must be above 0, but was ${t}. Working out a step from the values instead.`;if(ON.has(this.chartType))return EN(AC(this.grid,this.stacksSeries),this.maxValue,t).increment!==t?`limel-chart: \`axisIncrement\` ${t} would divide the axis into more than 100 steps. Working out a step from the values instead.`:void 0}}render(){return this.loading?i("limel-spinner",{limeBranded:!1}):i(r,null,this.renderLegend(),i("div",{class:"plot","aria-hidden":"true",ref:this.setPlot}),i("table",{"aria-live":"polite"},this.renderCaption(),this.renderTableHeader(),i("tbody",null,this.drawsSeries?this.renderCategories():this.renderItems())))}get hasLegend(){var t,n;return(null!==(n=null===(t=this.drawnSeries)||void 0===t?void 0:t.length)&&void 0!==n?n:0)>1}renderLegend(){if(this.hasLegend)return i("ul",{"aria-hidden":"true"},this.drawnSeries.map(((t,n)=>i("li",null,i("span",{style:HC(this.chartType,this.seriesColors[n])}),t.text))))}renderCaption(){if(this.accessibleLabel)return i("caption",null,this.accessibleLabel)}renderTableHeader(){var t,n;const r=null!==(n=null===(t=this.drawnSeries)||void 0===t?void 0:t.map((t=>t.text)))&&void 0!==n?n:[this.valuesLabel];return i("thead",null,this.renderSeriesGroupHeader(),i("tr",null,i("th",{scope:"col"},this.itemsLabel),r.map((t=>i("th",{scope:"col"},t)))))}renderSeriesGroupHeader(){const t=this.drawnSeries;if(t&&this.accessibleValuesLabel)return i("tr",null,i("td",null),i("th",{scope:"col",colSpan:t.length},this.accessibleValuesLabel))}get itemsLabel(){var t;return null!==(t=this.accessibleItemsLabel)&&void 0!==t?t:u.get("items",this.language)}get valuesLabel(){var t;return null!==(t=this.accessibleValuesLabel)&&void 0!==t?t:u.get("value",this.language)}renderItems(){const t=this.drawnItems,n=l(t,this.focusedPosition.index);return t.map(((t,r)=>i("tr",{"data-index":r,"aria-description":this.getRowDescription(r),tabIndex:r===n?0:-1,role:t.clickable?"button":null,onClick:this.handleClick,onKeyDown:this.handleKeyDown,onFocus:this.handleFocus,onBlur:this.handleBlur},i("td",null,t.text),i("td",null,fC(t,this.valueStyle)))))}getRowDescription(t){const n=this.drawnItems,i=VC(Object.assign(Object.assign({},this.valueStyle),{items:n,maxValue:this.maxValue,displayItemPercentage:this.displayItemPercentage}),t);return i===n[t].text?void 0:i}renderCategories(){const t=this.grid,n=this.findTabStopInGrid(t);return t.categories.map(((r,e)=>i("tr",null,i("th",{scope:"row"},r),t.series.map(((t,i)=>this.renderCell(t.items[e],{series:i,index:e},n))))))}renderCell(t,n,r){return t?i("td",{"data-series":n.series,"data-index":n.index,tabIndex:n.series===(null==r?void 0:r.series)&&n.index===(null==r?void 0:r.index)?0:-1,role:t.clickable?"button":void 0,"aria-label":t.clickable?this.getButtonLabel(t,n):null,onClick:this.handleClick,onKeyDown:this.handleKeyDown,onFocus:this.handleFocus,onBlur:this.handleBlur},fC(t,this.valueStyle)):i("td",null)}getButtonLabel(t,n){return[this.grid.categories[n.index],this.grid.series[n.series].text,fC(t,this.valueStyle)].join(", ")}findTabStopInGrid(t){const n=this.focusedPosition;if(MC(t,n))return n;const i={series:0,index:0},r=kC(t,i);return void 0!==r?Object.assign(Object.assign({},i),{series:r}):void 0}draw(){var t;if(!(null===(t=this.plot)||void 0===t?void 0:t.isConnected))return void this.disposeChart();this.observeSize();const{clientWidth:n,clientHeight:i}=this.plot;n&&!i&&this.host.toggleAttribute("data-fallback-height",!0),n&&i&&(this.createChart(),n===this.chart.getWidth()&&i===this.chart.getHeight()||this.chart.resize(),this.updateChart(),this.fitItemTextsToSize())}createChart(){var t;(null===(t=this.chart)||void 0===t?void 0:t.getDom())!==this.plot&&(this.disposeChart(),
16
+ /*!
17
+ * Apache ECharts
18
+ * Copyright 2017-2026 The Apache Software Foundation
19
+ *
20
+ * This product includes software developed at
21
+ * The Apache Software Foundation (https://www.apache.org/).
22
+ *
23
+ * Licensed under the Apache License, Version 2.0
24
+ * (https://www.apache.org/licenses/LICENSE-2.0).
25
+ *
26
+ *
27
+ * ZRender
28
+ * Copyright (c) 2017, Baidu Inc.
29
+ * All rights reserved.
30
+ *
31
+ * Redistribution and use in source and binary forms, with or without
32
+ * modification, are permitted provided that the following conditions are met:
33
+ *
34
+ * * Redistributions of source code must retain the above copyright notice, this
35
+ * list of conditions and the following disclaimer.
36
+ *
37
+ * * Redistributions in binary form must reproduce the above copyright notice,
38
+ * this list of conditions and the following disclaimer in the documentation
39
+ * and/or other materials provided with the distribution.
40
+ *
41
+ * * Neither the name of the copyright holder nor the names of its
42
+ * contributors may be used to endorse or promote products derived from
43
+ * this software without specific prior written permission.
44
+ *
45
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
46
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
47
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
48
+ * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
49
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
50
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
51
+ * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
52
+ * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
53
+ * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
54
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
55
+ */
56
+ Fk(dO),this.chart=function(t,n,i){var r=!(i&&i.ssr);if(r){var e=function(t){return wk[function(t,n){return t.getAttribute?t.getAttribute(n):t[n]}(t,kk)]}(t);if(e)return e}var a=new lk(t,n,i);return a.id="ec_"+Mk++,wk[a.id]=a,r&&Uo(t,kk,a.id),rk(a),Jx.trigger("afterinit",a),a}(this.plot,null,{renderer:"svg"}),this.chart.on("click",this.handleChartClick),this.chart.on("mouseover",this.handleChartOver),this.chart.on("mouseout",this.handleChartOut))}updateChart(){var t,n,i,r;const e=this.getSettings(),a=JSON.stringify(e);if(a===this.drawnSettings&&!this.themeMayHaveChanged)return;this.themeMayHaveChanged=!1,null!==(t=this.stopWatchingTheme)&&void 0!==t||(this.stopWatchingTheme=function(t,n){const i=[matchMedia("(prefers-color-scheme: dark)"),matchMedia("(prefers-reduced-motion: reduce)")];for(const t of i)t.addEventListener("change",n);const r=new MutationObserver(n);return r.observe(document.documentElement,{attributes:!0,attributeFilter:["data-theme"]}),r.observe(t,{attributes:!0,attributeFilter:["style","class"]}),()=>{for(const t of i)t.removeEventListener("change",n);r.disconnect()}}(this.host,this.handleThemeChange));const o=this.getThemeReader().theme(),u=this.withItemColors(e,o),s=JSON.stringify({theme:o,itemColors:u.items.map((t=>t.color)),seriesColors:null===(n=u.series)||void 0===n?void 0:n.map((t=>[t.color,...t.items.map((t=>t.color))]))});if(a===this.drawnSettings&&s===this.drawnTheme)return;this.drawnSettings=a,this.drawnTheme=s,this.drawing=function(t,n,i){const r=function(t){return Object.assign(Object.assign({},t),{items:EC(t),series:PC(t),stacked:WC(t)})}(t),e=jC(r),a=function(t,n,i,r){switch(t.type){case"pie":case"doughnut":return function(t,n){const{items:i}=t,r=qN(i,t.maxValue).totalRange,e=i.reduce(((t,n)=>t+FN(n)),0),a=i.map((t=>({value:FN(t),name:t.text,itemStyle:{color:t.color}})));return r>e&&a.push({value:r-e,itemStyle:{color:n.backgroundColor},emphasis:{disabled:!0},cursor:lO(!1)}),{seriesIndexes:[0],itemsAreSeries:!1,option:{series:[{type:"pie",radius:["doughnut"===t.type?"50%":0,"90%"],startAngle:90,label:zC,labelLine:zC,itemStyle:{borderColor:n.dividerColor,borderWidth:1},data:a,cursor:sO(i),emphasis:Object.assign(Object.assign({},DC),{scale:!1}),blur:_C}]}}}(t,i);case"proportion-bar":return function(t,n){const{items:i}=t,r={type:"value",min:0,max:qN(i,t.maxValue).totalRange,show:!1},e={type:"category",data:[""],show:!1},a="landscape"===t.orientation;return{seriesIndexes:[0],itemsAreSeries:!0,option:{backgroundColor:n.backgroundColor,grid:{left:0,right:0,top:0,bottom:0},xAxis:a?r:e,yAxis:a?e:r,series:i.map((t=>({type:"bar",stack:"whole",barWidth:"100%",cursor:lO(t.clickable),data:[FN(t)],itemStyle:{color:t.color,borderRadius:n.itemBorderRadius,borderColor:n.dividerColor,borderWidth:1},emphasis:DC,blur:_C})))}}}(t,i);case"ring":return function(t,n){const{items:i}=t;return{seriesIndexes:[0],itemsAreSeries:!1,option:{polar:{radius:["20%","90%"]},angleAxis:{type:"value",max:qN(i,t.maxValue).totalRange,startAngle:90,show:!1},radiusAxis:{type:"category",data:i.map((t=>t.text)),inverse:!0,show:!1},series:[{type:"bar",coordinateSystem:"polar",showBackground:!0,backgroundStyle:{color:n.backgroundColor},data:i.map((t=>({value:FN(t),itemStyle:{color:t.color}}))),cursor:sO(i),emphasis:DC,blur:_C}]}}}(t,i);case"scatter":return function(t,n){const{items:i}=t,r="date"===t.valueFormat?{x:jN(i.map((t=>PN(t)))),y:jN(i.map((t=>BN(t))))}:function(t){return{x:ZN(t.map((t=>PN(t)))),y:ZN(t.map((t=>BN(t))))}}(i),e="landscape"===t.orientation,a=eO(r.x,aO(t,t.itemsLabel,n),t,n),o=eO(r.y,aO(t,t.valuesLabel,n),t,n),u={type:"scatter",symbolSize:n.scatterItemSize,data:i.map((t=>{const n=PN(t),i=BN(t);return{value:e?[n,i]:[i,n],itemStyle:{color:t.color}}})),label:Object.assign(Object.assign({show:t.displayItemText||t.displayItemValue,position:"top"},uO(n)),{formatter:({dataIndex:n})=>function(t,n){const i=[];return t.displayItemText&&i.push(n.text),t.displayItemValue&&i.push(fC(n,t)),i.join(" ")}(t,i[n])}),cursor:sO(i),emphasis:DC,blur:_C};return{seriesIndexes:[0],itemsAreSeries:!1,option:{grid:rO(n),xAxis:e?a:o,yAxis:e?o:Object.assign(Object.assign({},a),{inverse:!0}),series:[u]}}}(t,i);case"nps":return function(t,n){const{items:i}=t;return{seriesIndexes:[0],itemsAreSeries:!1,option:{series:[{type:"gauge",min:-100,max:100,startAngle:200,endAngle:-20,radius:"90%",axisLine:{lineStyle:{width:16,color:OC.map(((t,i)=>[t,n.npsColors[i]]))}},splitLine:zC,axisTick:zC,axisLabel:zC,pointer:{width:6,length:"70%"},anchor:{show:!0,size:12,itemStyle:{color:n.textColor}},title:zC,detail:zC,data:i.map((t=>({value:RN(t),name:t.text,itemStyle:{color:t.color}}))),cursor:sO(i),emphasis:DC,blur:_C},{type:"pie",z:1,silent:!0,radius:[0,"90%"],startAngle:200,endAngle:-20,label:zC,labelLine:zC,tooltip:zC,data:[{value:1,itemStyle:{color:n.backgroundColor}}]}]}}}(t,i);default:return function(t,n,i,r){const{orientation:e}=t,a=function(t,n){const i=AC(n,Boolean(t.stacked));return"date"===t.valueFormat?jN(i.flatMap((t=>[zN(t),RN(t)])),t.maxValue):EN(i,t.maxValue,t.axisIncrement)}(t,n),o=function(t,n){if(t.displayItemText&&!(n.categories.length<2))return"landscape"===t.orientation?"xAxis":"yAxis"}(t,n),u=Object.assign(Object.assign(Object.assign({},YC(t,n)),{axisLabel:Object.assign({show:t.displayItemText,color:i.textColor},o&&r&&UC(o,r)),axisTick:zC,axisLine:{lineStyle:{color:i.axisLineColor}}}),aO(t,t.itemsLabel,i)),s=eO(a,aO(t,t.valuesLabel,i),t,i),{series:l,seriesIndexes:f,partsOfSeries:h}=function(t,n,i){const r=[],e=[],a=[];for(const o of n.series.keys()){const u=qC(t,n,o,i);e.push(r.length+u.seriesIndex),r.push(...u.series),a.push(...u.series.map((()=>o)))}return{series:r,seriesIndexes:e,partsOfSeries:a}}(t,n,i),c={grid:rO(i),xAxis:"landscape"===e?u:s,yAxis:"landscape"===e?s:u,series:l};return{seriesIndexes:f,partsOfSeries:h,itemsAreSeries:!1,itemTextAxis:o,valueRange:a,option:"bar"===t.type||t.series?c:XC(c,t,n)}}(t,n,i,r)}}(r,e,n,i);return Object.assign(Object.assign({},a),{option:Object.assign({animation:n.animate,textStyle:{fontFamily:n.fontFamily,color:n.textColor},tooltip:Object.assign({appendTo:"body",backgroundColor:n.surfaceColor,borderColor:n.axisLineColor,textStyle:{color:n.textColor}},r.series?$C(r,e,n):{trigger:"item",formatter:t=>function(t,n){const i=t.items[n];return i?[VC(t,n),fC(i,t)].map((t=>Nc(t))).join("<br/>"):""}(r,RC(a,t).index)})},a.option)})}(u,o,this.itemSpace),this.chart.setOption(this.drawing.option,{notMerge:!0}),this.showSeriesColors(null!==(r=null===(i=u.series)||void 0===i?void 0:i.map((t=>t.color)))&&void 0!==r?r:[]);const l=this.host.shadowRoot.activeElement;l instanceof HTMLElement&&l.dataset.index&&this.showItem(l,!0)}fitItemTextsToSize(){var t;const n=null===(t=this.drawing)||void 0===t?void 0:t.itemTextAxis;if(!n)return;const i={[`${n}Index`]:0},r=Math.floor(Math.abs(this.chart.convertToPixel(i,1)-this.chart.convertToPixel(i,0)));r!==this.itemSpace&&(this.itemSpace=r,this.chart.setOption(function(t,n){const i=t.itemTextAxis;return{[i]:[{axisLabel:UC(i,n)}]}}(this.drawing,r)))}getSettings(){var t;return Object.assign(Object.assign({items:this.drawnItems.map((t=>vO(t))),series:null===(t=this.drawnSeries)||void 0===t?void 0:t.map((t=>{var n;return{text:t.text,color:t.color,items:(null!==(n=t.items)&&void 0!==n?n:[]).map((t=>vO(t)))}})),stacked:this.stacksSeries},this.valueStyle),{orientation:this.orientation,maxValue:this.maxValue,axisIncrement:this.axisIncrement,displayAxisLabels:this.displayAxisLabels,itemsLabel:this.itemsLabel,valuesLabel:this.valuesLabel,displayItemText:this.displayItemText,displayItemValue:this.displayItemValue,displayItemPercentage:this.displayItemPercentage})}withItemColors(t,n){var i;const r=BC({type:this.chartType,items:this.items,series:this.series}),e=r?this.getSeriesColor(r,0,n):n.itemColor,a=r?"the color of its series":"the default item color";return Object.assign(Object.assign({},t),{items:t.items.map((t=>{var n;return Object.assign(Object.assign({},t),{color:null!==(n=this.readColor(t.color,"item",a))&&void 0!==n?n:e})})),series:null===(i=t.series)||void 0===i?void 0:i.map(((t,i)=>{const r=this.getSeriesColor(t,i,n);return Object.assign(Object.assign({},t),{color:r,items:t.items.map((t=>{var n;return Object.assign(Object.assign({},t),{color:null!==(n=this.readColor(t.color,"item","the color of its series"))&&void 0!==n?n:r})}))})}))})}getSeriesColor(t,n,i){var r,e;return null!==(e=null!==(r=this.readColor(t.color,"series","the default series color"))&&void 0!==r?r:this.getThemeReader().color((t=>`var(--limel-chart-series-color-${t%8+1})`)(n)))&&void 0!==e?e:i.itemColor}showSeriesColors(t){const n=this.seriesColors,i=t.length===n.length&&t.every(((t,i)=>t===n[i]));i||(this.seriesColors=t,this.hasLegend&&e(this))}readColor(t,n,i){if(!t)return;const r=this.getThemeReader().color(t);if(!r&&!this.invalidColors.has(t)){this.invalidColors.add(t);const r=t.includes("var(")?" Check that its variables are set, and that they make a color.":"";console.warn(`limel-chart: the color of ${"item"===n?"an":"a"} ${n} must be a CSS color, but was \`${t}\`.${r} Using ${i} instead.`)}return r}getThemeReader(){var t;return null!==(t=this.themeReader)&&void 0!==t||(this.themeReader=function(t){const n=document.createElement("span");let i;n.setAttribute("aria-hidden","true"),n.style.position="absolute",n.style.visibility="hidden",n.style.pointerEvents="none",t.append(n);const r=t=>{if(n.style.color="",n.style.color=t,n.style.color)return(t=>t.startsWith("rgb")?t:(null!=i||(i=document.createElement("canvas").getContext("2d",{willReadFrequently:!0})),i?function(t,n){t.clearRect(0,0,1,1),t.fillStyle=n,t.fillRect(0,0,1,1);const[i,r,e,a]=t.getImageData(0,0,1,1).data;return`rgba(${i}, ${r}, ${e}, ${a/255})`}(i,t):t))(getComputedStyle(n).color)},e=t=>{n.style.setProperty(fO,t);const i=getComputedStyle(n).getPropertyValue(fO);return n.style.removeProperty(fO),i.trim()},a=new Set,o=t=>{const n=e(`var(${t})`),i=`${t}:${n}`;return!n||CSS.supports("color",n)||a.has(i)||(a.add(i),console.warn(`limel-chart: \`${hO[t]}\` must be a CSS color, but was \`${n}\`. Using the color of the text instead.`)),r(`var(${t})`)},u=t=>{n.style.width=t;const i=Number.parseFloat(getComputedStyle(n).width);return n.style.width="",Number.isFinite(i)?i:0},s=t=>{n.style.borderRadius=t;const i=getComputedStyle(n),r=[i.borderTopLeftRadius,i.borderTopRightRadius,i.borderBottomRightRadius,i.borderBottomLeftRadius];return n.style.borderRadius="",r.map((t=>u(t)))};return{color:t=>(t=>CSS.supports("color",e(t)))(t)?r(t):void 0,theme:()=>({itemColor:o("--limel-chart-item-color"),lineColor:r("var(--limel-chart-line-color)"),axisLineColor:o("--limel-chart-axis-line-color"),textColor:r("var(--limel-chart-text-color)"),backgroundColor:o("--limel-chart-background-color"),dividerColor:o("--limel-chart-item-divider-color"),surfaceColor:r("var(--limel-chart-surface-color)"),itemBorderRadius:s("var(--limel-chart-item-border-radius)"),scatterItemSize:u("var(--limel-chart-scatter-item-size)"),fontFamily:getComputedStyle(t.host).fontFamily,npsColors:[r("var(--limel-chart-nps-detractors-color)"),r("var(--limel-chart-nps-passives-color)"),r("var(--limel-chart-nps-good-color)"),r("var(--limel-chart-nps-excellent-color)")],animate:!matchMedia("(prefers-reduced-motion: reduce)").matches}),dispose:()=>n.remove()}}(this.host.shadowRoot)),this.themeReader}observeSize(){this.resizeObserver||"undefined"==typeof ResizeObserver||(this.resizeObserver=new ResizeObserver(this.handleResize),this.resizeObserver.observe(this.host))}disposeChart(){var t;null===(t=this.chart)||void 0===t||t.dispose(),this.chart=void 0,this.drawing=void 0,this.drawnSettings=void 0,this.drawnTheme=void 0,this.itemSpace=void 0}getClickedPosition(t){const n=RC(this.drawing,t);return"line"===t.seriesType&&t.event?Object.assign(Object.assign({},n),{index:this.getNearestPlace(t.event)}):n}getNearestPlace(t){const n="landscape"===this.orientation,i=this.chart.convertFromPixel(n?{xAxisIndex:0}:{yAxisIndex:0},n?t.offsetX:t.offsetY);return Math.round(i)}highlightItemAt(t,n){if(!this.drawing)return;const i=FC(this.drawing,RC(this.drawing,t));i.seriesIndex!==t.seriesIndex&&this.chart.dispatchAction(Object.assign({type:n?"highlight":"downplay"},i))}getClickableItem(t){const n=MC(this.grid,t);if(null==n?void 0:n.clickable)return n}getPosition(t){var n;return{series:Number(null!==(n=t.dataset.series)&&void 0!==n?n:0),index:Number(t.dataset.index)}}getEventPosition(t){return this.getPosition(t.currentTarget)}findTarget(t,n,i){if(!this.drawsSeries)return{series:0,index:f(this.drawnItems,t,n.index,{orientation:i})};const r=this.grid;if("horizontal"===i){const e=r.series.map((t=>t.items[n.index]));return{series:f(e,t,n.series,{orientation:i,isDisabled:t=>!t}),index:n.index}}const e=f(r.categories,t,n.index,{orientation:i}),a=kC(r,{series:n.series,index:e});return{series:null!=a?a:h,index:e}}focusItem(t){if(t.series===h||t.index===h)return;const n=this.host.shadowRoot.querySelector(`tbody [data-index="${t.index}"]${this.drawsSeries?`[data-series="${t.series}"]`:""}`);null==n||n.focus()}showItem(t,n){if(!this.chart||!this.drawing)return;const i=this.getPosition(t),r=FC(this.drawing,i);this.chart.dispatchAction(Object.assign({type:n?"highlight":"downplay"},r)),this.chart.dispatchAction(n?Object.assign({type:"showTip"},this.drawsSeries?this.getMiddleOfPlace(i.index):r):this.drawsSeries?{type:"updateAxisPointer",currTrigger:"leave"}:{type:"hideTip"})}getMiddleOfPlace(t){const{minValue:n,maxValue:i}=this.drawing.valueRange,r=(n+i)/2,[e,a]=this.chart.convertToPixel({gridIndex:0},"landscape"===this.orientation?[t,r]:[r,t]);return{x:e,y:a}}get host(){return a(this)}static get watchers(){return{type:[{warnAboutOldTypeName:0}]}}};pO.style='@charset "UTF-8";:host(limel-chart){--limel-chart-item-color:var( --chart-item-color, rgb(var(--contrast-1100), 0.8) );--limel-chart-axis-line-color:var( --chart-axis-line-color, rgb(var(--contrast-900), 0.4) );--limel-chart-background-color:var(--chart-background-color, transparent);--limel-chart-item-divider-color:var( --chart-item-divider-color, rgb(var(--contrast-100), 0.6) );--limel-chart-item-border-radius:var(--chart-item-border-radius, 0);--limel-chart-scatter-item-size:var(--chart-scatter-item-size, 0.5rem);--limel-chart-text-color:rgb(var(--contrast-1000));--limel-chart-line-color:rgb(var(--contrast-900));--limel-chart-surface-color:rgb(var(--contrast-100));--limel-chart-nps-detractors-color:rgb(var(--color-coral-default));--limel-chart-nps-passives-color:rgb(var(--color-amber-light));--limel-chart-nps-good-color:rgb(var(--color-lime-light));--limel-chart-nps-excellent-color:rgb(var(--color-lime-default));--limel-chart-series-color-1:rgb(var(--color-blue-default));--limel-chart-series-color-2:rgb(var(--color-coral-default));--limel-chart-series-color-3:rgb(var(--color-teal-default));--limel-chart-series-color-4:rgb(var(--color-amber-default));--limel-chart-series-color-5:rgb(var(--color-magenta-default));--limel-chart-series-color-6:rgb(var(--color-green-default));--limel-chart-series-color-7:rgb(var(--color-violet-default));--limel-chart-series-color-8:rgb(var(--color-red-default));box-sizing:border-box;position:relative;display:flex;flex-direction:column;width:100%;height:100%;min-width:0;min-height:0}:host(limel-chart[type=bar]){--limel-chart-item-border-radius:var(--chart-item-border-radius, 0.125rem)}:host(limel-chart[type=proportion-bar]),:host(limel-chart[type=stacked-bar]){--limel-chart-background-color:var( --chart-background-color, rgb(var(--contrast-800), 0.2) )}:host(limel-chart[type=proportion-bar][orientation=landscape]),:host(limel-chart[type=proportion-bar][orientation=landscape]) .plot,:host(limel-chart[type=stacked-bar][orientation=landscape]),:host(limel-chart[type=stacked-bar][orientation=landscape]) .plot{min-height:0.5rem}:host(limel-chart[type=proportion-bar][orientation=portrait]),:host(limel-chart[type=proportion-bar][orientation=portrait]) .plot,:host(limel-chart[type=stacked-bar][orientation=portrait]),:host(limel-chart[type=stacked-bar][orientation=portrait]) .plot{min-width:0.5rem}:host(limel-chart[type=pie]),:host(limel-chart[type=doughnut]),:host(limel-chart[type=ring]){--limel-chart-background-color:var( --chart-background-color, rgb(var(--contrast-200)) )}:host(limel-chart[type=nps]){--limel-chart-background-color:var( --chart-background-color, rgb(var(--contrast-100)) )}:host(limel-chart[type=pie]),:host(limel-chart[type=doughnut]),:host(limel-chart[type=ring]),:host(limel-chart[type=nps]){aspect-ratio:1}:host(limel-chart[type=bar][data-fallback-height]),:host(limel-chart[type=dot][data-fallback-height]),:host(limel-chart[type=line][data-fallback-height]),:host(limel-chart[type=area][data-fallback-height]),:host(limel-chart[type=scatter][data-fallback-height]){aspect-ratio:2}.plot{flex-grow:1;contain:size}ul{display:flex;flex-wrap:wrap;gap:0.25rem 0.875rem;margin:0 0 0.5rem 0;padding:0;list-style:none;font-size:0.75rem;color:rgb(var(--contrast-1100))}li{display:inline-flex;align-items:center;gap:0.375rem}li>span{flex-shrink:0}:host(limel-chart[type=proportion-bar]) .plot,:host(limel-chart[type=stacked-bar]) .plot{border-radius:0.25rem;overflow:hidden}table{position:absolute;width:0;height:0;margin:-1px;padding:0;border:0;overflow:hidden;clip:rect(0, 0, 0, 0);clip-path:inset(50%);white-space:nowrap}limel-spinner{margin:auto}';export{pO as limel_chart}